* function.c (dump_stack_clash_frame_info): New function.
[official-gcc.git] / gcc / ChangeLog
blob9783313093768fa5e01007583d178fe48b3ec887
1 2017-09-19  Jeff Law  <law@redhat.com>
3         * function.c (dump_stack_clash_frame_info): New function.
4         * function.h (dump_stack_clash_frame_info): Prototype.
5         (enum stack_clash_probes): New enum.
7         * config/alpha/alpha.c (alpha_expand_prologue): Also check
8         flag_stack_clash_protection.
9         * config/arm/arm.c (arm_compute_static_chain_stack_bytes): Likewise.
10         (arm_expand_prologue, thumb1_expand_prologue): Likewise.
11         (arm_frame_pointer_required): Likewise.
12         * config/ia64/ia64.c (ia64_compute_frame_size): Likewise.
13         (ia64_expand_prologue): Likewise.
14         * config/mips/mips.c (mips_expand_prologue): Likewise.
15         * config/powerpcspe/powerpcspe.c (rs6000_expand_prologue): Likewise.
16         * config/sparc/sparc.c (sparc_expand_prologue): Likewise.
17         (sparc_flat_expand_prologue): Likewise.
18         * config/spu/spu.c (spu_expand_prologue): Likewise.
20         * explow.c: Include "params.h".
21         (anti_adjust_stack_and_probe_stack_clash): New function.
22         (get_stack_check_protect): Likewise.
23         (compute_stack_clash_protection_loop_data): Likewise.
24         (emit_stack_clash_protection_loop_start): Likewise.
25         (emit_stack_clash_protection_loop_end): Likewise.
26         (allocate_dynamic_stack_space): Use get_stack_check_protect.
27         Use anti_adjust_stack_and_probe_stack_clash.
28         * explow.h (compute_stack_clash_protection_loop_data): Prototype.
29         (emit_stack_clash_protection_loop_start): Likewise.
30         (emit_stack_clash_protection_loop_end): Likewise.
31         * rtl.h (get_stack_check_protect): Prototype.
32         * target.def (stack_clash_protection_final_dynamic_probe): New hook.
33         * targhooks.c (default_stack_clash_protection_final_dynamic_probe): New.
34         * targhooks.h (default_stack_clash_protection_final_dynamic_probe): 
35         Prototype.
36         * doc/tm.texi.in (TARGET_STACK_CLASH_PROTECTION_FINAL_DYNAMIC_PROBE):
37         Add @hook.
38         * doc/tm.texi: Rebuilt.
39         * config/aarch64/aarch64.c (aarch64_expand_prologue): Use
40         get_stack_check_protect.
41         * config/alpha/alpha.c (alpha_expand_prologue): Likewise.
42         * config/arm/arm.c (arm_expand_prologue): Likewise.
43         (arm_frame_pointer_required): Likewise.
44         * config/i386/i386.c (ix86_expand_prologue): Likewise.
45         * config/ia64/ia64.c (ia64_expand_prologue): Likewise.
46         * config/mips/mips.c (mips_expand_prologue): Likewise.
47         * config/powerpcspe/powerpcspe.c (rs6000_emit_prologue): Likewise.
48         * config/rs6000/rs6000.c (rs6000_emit_prologue): Likewise.
49         * config/sparc/sparc.c (sparc_expand_prologue): Likewise.
50         (sparc_flat_expand_prologue): Likewise.
52         * common.opt (-fstack-clash-protection): New option.
53         * flag-types.h (enum stack_check_type): Note difference between
54         -fstack-check= and -fstack-clash-protection.
55         * params.def (PARAM_STACK_CLASH_PROTECTION_GUARD_SIZE): New PARAM.
56         (PARAM_STACK_CLASH_PROTECTION_PROBE_INTERVAL): Likewise.
57         * toplev.c (process_options): Issue warnings/errors for cases
58         not handled with -fstack-clash-protection.
59         * doc/invoke.texi (-fstack-clash-protection): Document new option.
60         (-fstack-check): Note additional problem with -fstack-check=generic.
61         Note that -fstack-check is primarily for Ada and refer users
62         to -fstack-clash-protection for stack-clash-protection.
63         Document new params for stack clash protection.
65 2017-09-19  Uros Bizjak  <ubizjak@gmail.com>
67         * config/i386/i386.md (*scc_bt<mode>): New insn_and_split pattern.
68         (*scc_bt<mode>_1): Ditto.
69         (*scc_bt<mode>_mask): Ditto.
71 2017-09-19  Uros Bizjak  <ubizjak@gmail.com>
73         * config/i386/i386.c (ix86_split_long_move): Do not handle
74         address used for LEA in a special way.
76 2017-09-19  Segher Boessenkool  <segher@kernel.crashing.org>
78         * simplify-rtx.c (simplify_binary_operation_1): Fix typo in comment.
80 2017-09-19  Martin Sebor  <msebor@redhat.com>
82         PR c/81854
83         * cgraphunit.c (handle_alias_pairs): Reject aliases between functions
84         of incompatible types.
86 2017-09-19  Will Schmidt  <will_schmidt@vnet.ibm.com>
88         * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Add handling
89         for early folding of vector loads (ALTIVEC_BUILTIN_LVX_*).
90         * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin):
91         Remove obsoleted code for handling ALTIVEC_BUILTIN_VEC_LD.
93 2017-09-19  Richard Biener  <rguenther@suse.de>
95         PR tree-optimization/82244
96         * tree-vrp.c (remove_range_assertions): Do not propagate
97         a constant to abnormals but replace the assert with a copy.
99 2017-09-19  Alexander Monakov  <amonakov@ispras.ru>
101         PR rtl-optimization/57878
102         PR rtl-optimization/68988
103         * lra-assigns.c (reload_pseudo_compare_func): Remove fragmentation
104         avoidance test involving non_reload_pseudos.  Move frequency test
105         below the general fragmentation avoidance test.
107 2017-09-19  Richard Biener  <rguenther@suse.de>
109         PR tree-optimization/69728
110         * graphite-sese-to-poly.c (schedule_error): New global.
111         (add_loop_schedule): Handle empty domain by failing the
112         schedule.
113         (build_original_schedule): Handle schedule_error.
115 2017-09-19  Richard Biener  <rguenther@suse.de>
117         * graphite-scop-detection.c (scop_detection::can_represent_loop):
118         Do not iterate to sibling loops but only to siblings of inner
119         loops.
121 2017-09-18  Andreas Schwab  <schwab@linux-m68k.org>
123         PR target/81613
124         * config/m68k/m68k.md (moveq feeding equality comparison): Check
125         that the registers are different.
127 2017-09-18  Uros Bizjak  <ubizjak@gmail.com>
129         * config/i386/i386.c (fold_builtin_cpu): Add M_AMDFAM17H
130         to processor_model and "amdfam17h" to arch_names_table.
131         * doc/extend.texi (__builtin_cpu_is): Document amdfam17h CPU name.
133 2017-09-18  Jakub Jelinek  <jakub@redhat.com>
135         PR c/82234
136         * doc/extend.texi: Add @findex entry for __builtin_shuffle.
138 2017-09-18  Richard Sandiford  <richard.sandiford@linaro.org>
139             Alan Hayward  <alan.hayward@arm.com>
140             David Sherwood  <david.sherwood@arm.com>
142         * tree-vectorizer.h (vect_slp_analyze_operations): Replace parameters
143         with a vec_info *.
144         * tree-vect-loop.c (vect_analyze_loop_operations): Update call
145         accordingly.
146         * tree-vect-slp.c (vect_slp_analyze_node_operations): Add vec_info *
147         parameter.  Set SLP_TREE_NUMBER_OF_VEC_STMTS here rather than in
148         vect_schedule_slp_instance.
149         (vect_slp_analyze_operations): Replace parameters with a vec_info *.
150         Update call to vect_slp_analyze_node_operations.  Simplify return
151         value.
152         (vect_slp_analyze_bb_1): Update call accordingly.
153         (vect_schedule_slp_instance): Remove vectorization_factor parameter.
154         Don't calculate SLP_TREE_NUMBER_OF_VEC_STMTS here.
155         (vect_schedule_slp): Update call accordingly.
157 2017-09-18  Richard Sandiford  <richard.sandiford@linaro.org>
158             Alan Hayward  <alan.hayward@arm.com>
159             David Sherwood  <david.sherwood@arm.com>
161         * tree-vect-data-refs.c (vect_get_smallest_scalar_type): Cope
162         with types that aren't in fact scalar.
164 2017-09-18  Richard Sandiford  <richard.sandiford@linaro.org>
166         * tree-vect-slp.c (vect_record_max_nunits): New function,
167         split out from...
168         (vect_build_slp_tree_1): ...here.
169         (vect_build_slp_tree_2): Call it for phis too.
171 2017-09-18  Richard Sandiford  <richard.sandiford@linaro.org>
173         * tree-vect-stmts.c (vectorizable_mask_load_store): Pass mask_vectype
174         to vect_get_vec_def_for_operand when getting the mask operand.
176 2017-09-18  Richard Sandiford  <richard.sandiford@linaro.org>
177             Alan Hayward  <alan.hayward@arm.com>
178             David Sherwood  <david.sherwood@arm.com>
180         * tree-vect-loop.c (vectorizable_live_operation): Fix type of
181         bitstart.
183 2017-09-18  Richard Sandiford  <richard.sandiford@linaro.org>
184             Alan Hayward  <alan.hayward@arm.com>
185             David Sherwood  <david.sherwood@arm.com>
187         * tree-vect-loop.c (vectorizable_live_operation): Fix element size
188         calculation for vector booleans.
190 2017-09-18  Richard Sandiford  <richard.sandiford@linaro.org>
191             Alan Hayward  <alan.hayward@arm.com>
192             David Sherwood  <david.sherwood@arm.com>
194         * tree-vect-stmts.c (can_vectorize_live_stmts): New function,
195         split out from...
196         (vect_transform_stmt): ...here.
197         (vect_analyze_stmt): Use it instead of calling
198         vectorizable_live_operation directly.
200 2017-09-18  Cesar Philippidis  <cesar@codesourcery.com>
202         * omp-offload.c (oacc_xform_loop): Enable SIMD vectorization on
203         non-SIMT targets in acc vector loops.
205 2017-09-18  Claudiu Zissulescu  <claziss@synopsys.com>
207         * configure.ac: Add arc and check if assembler supports gdwarf2.
208         * configure: Regenerate.
210 2017-09-18  Richard Biener  <rguenther@suse.de>
212         PR tree-optimization/82220
213         * tree-vect-loop.c (vect_estimate_min_profitable_iters): Exclude
214         epilogue niters from the min_profitable_iters compute.
216 2017-09-18  Jakub Jelinek  <jakub@redhat.com>
218         PR target/82145
219         * config/i386/i386.c (ix86_init_large_pic_reg): Revert 2017-09-01
220         changes.  Turn CODE_LABEL into NOTE_INSN_DELETED_LABEL immediately.
221         (ix86_init_pic_reg): Revert 2017-09-01 changes.
223 2017-09-18  Eric Botcazou  <ebotcazou@adacore.com>
225         PR target/81361
226         * dwarf2cfi.c (add_cfis_to_fde): Do not generate DW_CFA_set_loc after
227         switching to a new text section.
229 2017-09-18  Richard Biener  <rguenther@suse.de>
231         * graphite-scop-detection.c (scop_detection::stmt_has_simple_data_ref):
232         Simplify.
233         (build_alias_set): Reject aliases with no access function.
235 2017-09-18  Richard Biener  <rguenther@suse.de>
237         PR tree-optimization/79622
238         * graphite-scop-detection.c (build_cross_bb_scalars_def): Properly
239         handle PHIs.
240         (build_cross_bb_scalars_use): Likewise.
242 2017-09-18  Pierre-Marie de Rodat  <derodat@adacore.com>
244         * cgraph.h (cgraph_thunk_info): Fix a typo in a comment.
246 2017-09-18  Alan Modra  <amodra@gmail.com>
248         PR target/81996
249         * gcc/config/rs6000/rs6000.c (rs6000_return_addr): Use
250         stack_pointer_rtx for count 0.  Update comments.  Break up
251         large rtl expression.
253 2017-09-17  Daniel Santos  <daniel.santos@pobox.com>
255         config/i386/i386.c: (xlogue_layout::STUB_NAME_MAX_LEN): Increase to 20
256         bytes.
257         (xlogue_layout::s_stub_names): Add an additional size-2 diminsion.
258         (xlogue_layout::get_stub_name): Modify to select the appropairate sse
259         or avx version of the stub.
261 2017-09-17  H.J. Lu  <hongjiu.lu@intel.com>
263         PR target/82166
264         * config/i386/i386.c (ix86_finalize_stack_frame_flags): Properly
265         compute the minimum stack alignment.  Also update preferred stack
266         boundary for leaf functions.
268 2017-09-16  Richard Sandiford  <richard.sandiford@linaro.org>
270         PR tree-optimization/82228
271         * tree-vect-loop.c (vectorizable_live_operation): Move initialization
272         of ncopies.
274 2017-09-16  Chung-Ju Wu  <jasonwucj@gmail.com>
276         * common/config/nds32/nds32-common.c
277         (nds32_option_optimization_table): Refine formatting.
278         (nds32_option_optimization_table): Use -fsched-pressure and
279         -fomit-frame-pointer for specific optimization level.
281 2017-09-16  Chung-Ju Wu  <jasonwucj@gmail.com>
283         * config/nds32/nds32.c: Refine formatting and comments.
284         * config/nds32/nds32.h: Likewise.
285         * config/nds32/nds32.md: Likewise.
286         * config/nds32/nds32-cost.c: Likewise.
287         * config/nds32/nds32-isr.c: Likewise.
288         * config/nds32/nds32-md-auxiliary.c: Likewise.
289         * config/nds32/nds32-multiple.md: Likewise.
290         * config/nds32/nds32-predicates.c: Likewise.
292 2017-09-15  Andrew Sutton  <andrew.n.sutton@gmail.com>
293             Jakub Jelinek  <jakub@redhat.com>
295         Add support for -std=c++2a.
296         * doc/cpp.texi (__cplusplus): Document value for -std=c++2a
297         or -std=gnu+2a.
298         * doc/invoke.texi: Document -std=c++2a and -std=gnu++2a.
300 2017-09-15  Steve Ellcey  <sellcey@cavium.com>
302         PR target/82066
303         * doc/extend.texi (Common Function Attributes): Add 
304         references to ARM, AArch64, and S/390 specific attributes.
305         (Function Specific Option Pragmas): Add AArch64 and S/390
306         to list of back ends that support the target pragma.
308 2017-09-15  Nathan Sidwell  <nathan@acm.org>
310         * doc/standards.texi: Fix C++17 description.  Update URLs for
311         C++11 & 14.
313 2017-09-15  Bernd Edlinger  <bernd.edlinger@hotmail.de>
315         * common.opt (Wcast-align=strict): New warning option.
316         * doc/invoke.texi: Document -Wcast-align=strict. 
318 2017-09-15  Pierre-Marie de Rodat  <derodat@adacore.com>
320         * cgraph.h (cgraph_thunk_info): Add comments.
321         * cgraph.c (cgraph_node::create_thunk): Adjust comment, make
322         assert for VIRTUAL_* arguments stricter.
324 2017-09-15  Jackson Woodruff  <jackson.woodruff@arm.com>
326         PR tree-optimization/71026
327         * match.pd: Move RDIV patterns from fold-const.c
328         * fold-const.c (distribute_real_division): Removed.
329         (fold_binary_loc): Remove calls to distribute_real_divison.
331 2017-09-15  Jakub Jelinek  <jakub@redhat.com>
333         * doc/invoke.texi: Document -std=c++17 and -std=gnu++17 and document
334         c++1z and gnu++1z as deprecated.  Change other references to
335         -std=c++1z to -std=c++17 and -std=gnu++1z to -std=gnu++17.
336         Change -Wc++1z-compat to -Wc++17-compat.
337         * doc/cpp.texi: Document -std=c++17 defines __cplusplus 201703L.
338         * dwarf2out.c (highest_c_language): Handle C++17.
339         (gen_compile_unit_die): Likewise.
341 2017-09-15  Jakub Jelinek  <jakub@redhat.com>
343         PR rtl-optimization/82192
344         * combine.c (make_extraction): Don't look through non-paradoxical
345         SUBREGs or TRUNCATE if pos + len is or might be bigger than
346         inner's mode.
348 2017-09-15  Richard Sandiford  <richard.sandiford@linaro.org>
349             Alan Hayward  <alan.hayward@arm.com>
350             David Sherwood  <david.sherwood@arm.com>
352         * target.def (function_arg_offset): New hook.
353         * targhooks.h (default_function_arg_offset): Declare.
354         * targhooks.c (default_function_arg_offset): New function.
355         * function.c (locate_and_pad_parm): Use
356         targetm.calls.function_arg_offset instead of FUNCTION_ARG_OFFSET.
357         * doc/tm.texi.in (FUNCTION_ARG_OFFSET): Replace with...
358         (TARGET_FUNCTION_ARG_OFFSET): ...this.
359         * doc/tm.texi: Regenerate.
360         * config/spu/spu.h (FUNCTION_ARG_OFFSET): Delete.
361         * config/spu/spu.c (spu_function_arg_offset): New function.
362         (TARGET_FUNCTION_ARG_OFFSET): Redefine.
363         * system.h (FUNCTION_ARG_OFFSET): Poison.
365 2017-09-15  Richard Sandiford  <richard.sandiford@linaro.org>
366             Alan Hayard  <alan.hayward@arm.com>
367             David Sherwood  <david.sherwood@arm.com>
369         * target.def (truly_noop_truncation): New hook.
370         (mode_rep_extended): Refer to TARGET_TRULY_NOOP_TRUNCATION rather
371         than TRULY_NOOP_TRUNCATION.
372         * hooks.h (hook_bool_uint_uint_true): Declare.
373         * hooks.c (hook_bool_uint_uint_true): New function.
374         * doc/tm.texi.in (TRULY_NOOP_TRUNCATION): Replace with...
375         (TARGET_TRULY_NOOP_TRUNCATION): ...this.
376         * doc/tm.texi: Regenerate.
377         * combine.c (make_extraction): Refer to TARGET_TRULY_NOOP_TRUNCATION
378         rather than TRULY_NOOP_TRUNCATION in comments.
379         (simplify_comparison): Likewise.
380         (record_truncated_value): Likewise.
381         * expmed.c (extract_bit_field_1): Likewise.
382         (extract_split_bit_field): Likewise.
383         * convert.c (convert_to_integer_1): Use targetm.truly_noop_truncation
384         instead of TRULY_NOOP_TRUNCATION.
385         * function.c (assign_parm_setup_block): Likewise.
386         * machmode.h (TRULY_NOOP_TRUNCATION_MODES_P): Likewise.
387         * rtlhooks.c: Include target.h.
388         * config/aarch64/aarch64.h (TRULY_NOOP_TRUNCATION): Delete.
389         * config/alpha/alpha.h (TRULY_NOOP_TRUNCATION): Delete.
390         * config/arc/arc.h (TRULY_NOOP_TRUNCATION): Delete.
391         * config/arm/arm.h (TRULY_NOOP_TRUNCATION): Delete.
392         * config/avr/avr.h (TRULY_NOOP_TRUNCATION): Delete.
393         * config/bfin/bfin.h (TRULY_NOOP_TRUNCATION): Delete.
394         * config/c6x/c6x.h (TRULY_NOOP_TRUNCATION): Delete.
395         * config/cr16/cr16.h (TRULY_NOOP_TRUNCATION): Delete.
396         * config/cris/cris.h (TRULY_NOOP_TRUNCATION): Delete.
397         * config/epiphany/epiphany.h (TRULY_NOOP_TRUNCATION): Delete.
398         * config/fr30/fr30.h (TRULY_NOOP_TRUNCATION): Delete.
399         * config/frv/frv.h (TRULY_NOOP_TRUNCATION): Delete.
400         * config/ft32/ft32.h (TRULY_NOOP_TRUNCATION): Delete.
401         * config/h8300/h8300.h (TRULY_NOOP_TRUNCATION): Delete.
402         * config/i386/i386.h (TRULY_NOOP_TRUNCATION): Delete.
403         * config/ia64/ia64.h (TRULY_NOOP_TRUNCATION): Delete.
404         * config/iq2000/iq2000.h (TRULY_NOOP_TRUNCATION): Delete.
405         * config/lm32/lm32.h (TRULY_NOOP_TRUNCATION): Delete.
406         * config/m32c/m32c.h (TRULY_NOOP_TRUNCATION): Delete.
407         * config/m32r/m32r.h (TRULY_NOOP_TRUNCATION): Delete.
408         * config/m68k/m68k.h (TRULY_NOOP_TRUNCATION): Delete.
409         * config/mcore/mcore.h (TRULY_NOOP_TRUNCATION): Delete.
410         * config/microblaze/microblaze.h (TRULY_NOOP_TRUNCATION): Delete.
411         * config/mips/mips.h (TRULY_NOOP_TRUNCATION): Delete.
412         * config/mips/mips.c (mips_truly_noop_truncation): New function.
413         (TARGET_TRULY_NOOP_TRUNCATION): Redefine.
414         * config/mips/mips.md: Refer to TARGET_TRULY_NOOP_TRUNCATION
415         rather than TRULY_NOOP_TRUNCATION in comments.
416         * config/mmix/mmix.h (TRULY_NOOP_TRUNCATION): Delete.
417         * config/mn10300/mn10300.h (TRULY_NOOP_TRUNCATION): Delete.
418         * config/moxie/moxie.h (TRULY_NOOP_TRUNCATION): Delete.
419         * config/msp430/msp430.h (TRULY_NOOP_TRUNCATION): Delete.
420         * config/nds32/nds32.h (TRULY_NOOP_TRUNCATION): Delete.
421         * config/nios2/nios2.h (TRULY_NOOP_TRUNCATION): Delete.
422         * config/nvptx/nvptx.h (TRULY_NOOP_TRUNCATION): Delete.
423         * config/pa/pa.h (TRULY_NOOP_TRUNCATION): Delete.
424         * config/pdp11/pdp11.h (TRULY_NOOP_TRUNCATION): Delete.
425         * config/powerpcspe/powerpcspe.h (TRULY_NOOP_TRUNCATION): Delete.
426         * config/riscv/riscv.h (TRULY_NOOP_TRUNCATION): Delete.
427         * config/riscv/riscv.md: Refer to TARGET_TRULY_NOOP_TRUNCATION
428         rather than TRULY_NOOP_TRUNCATION in comments.
429         * config/rl78/rl78.h (TRULY_NOOP_TRUNCATION): Delete.
430         * config/rs6000/rs6000.h (TRULY_NOOP_TRUNCATION): Delete.
431         * config/rx/rx.h (TRULY_NOOP_TRUNCATION): Delete.
432         * config/s390/s390.h (TRULY_NOOP_TRUNCATION): Delete.
433         * config/sh/sh.h (MAYBE_BASE_REGISTER_RTX_P): Remove
434         TRULY_NOOP_TRUNCATION condition.
435         (MAYBE_INDEX_REGISTER_RTX_P): Likewise.
436         (TRULY_NOOP_TRUNCATION): Delete.
437         * config/sparc/sparc.h (TRULY_NOOP_TRUNCATION): Delete.
438         * config/spu/spu.h (TRULY_NOOP_TRUNCATION): Delete.
439         * config/spu/spu.c (spu_truly_noop_truncation): New function.
440         (TARGET_TRULY_NOOP_TRUNCATION): Redefine.
441         * config/stormy16/stormy16.h (TRULY_NOOP_TRUNCATION): Delete.
442         * config/tilegx/tilegx.h (TRULY_NOOP_TRUNCATION): Delete.
443         * config/tilegx/tilegx.c (tilegx_truly_noop_truncation): New fuction.
444         (TARGET_TRULY_NOOP_TRUNCATION): Redefine.
445         * config/tilegx/tilegx.md: Refer to TARGET_TRULY_NOOP_TRUNCATION
446         rather than TRULY_NOOP_TRUNCATION in comments.
447         * config/tilepro/tilepro.h (TRULY_NOOP_TRUNCATION): Delete.
448         * config/v850/v850.h (TRULY_NOOP_TRUNCATION): Delete.
449         * config/vax/vax.h (TRULY_NOOP_TRUNCATION): Delete.
450         * config/visium/visium.h (TRULY_NOOP_TRUNCATION): Delete.
451         * config/xtensa/xtensa.h (TRULY_NOOP_TRUNCATION): Delete.
452         * system.h (TRULY_NOOP_TRUNCATION): Poison.
454 2017-09-15  Christophe Lyon  <christophe.lyon@linaro.org>
456         PR target/67591
457         * config/arm/arm.md (*cmp_and): Add enabled_for_depr_it attribute.
458         (*cmp_ior): Likewise.
459         (*ior_scc_scc): Add alternative for enabled_for_depr_it attribute.
460         (*ior_scc_scc_cmp): Likewise.
461         (*and_scc_scc): Likewise.
462         (*and_scc_scc_cmp): Likewise.
464 2017-09-15  Richard Sandiford  <richard.sandiford@linaro.org>
465             Alan Hayard  <alan.hayward@arm.com>
466             David Sherwood  <david.sherwood@arm.com>
468         * target.def (can_change_mode_class): New hook.
469         (mode_rep_extended): Refer to it instead of CANNOT_CHANGE_MODE_CLASS.
470         (hard_regno_nregs): Likewise.
471         * hooks.h (hook_bool_mode_mode_reg_class_t_true): Declare.
472         * hooks.c (hook_bool_mode_mode_reg_class_t_true): New function.
473         * doc/tm.texi.in (CANNOT_CHANGE_MODE_CLASS): Replace with...
474         (TARGET_CAN_CHANGE_MODE_CLASS): ...this.
475         (LOAD_EXTEND_OP): Update accordingly.
476         * doc/tm.texi: Regenerate.
477         * doc/rtl.texi: Refer to TARGET_CAN_CHANGE_MODE_CLASS instead of
478         CANNOT_CHANGE_MODE_CLASS.
479         * hard-reg-set.h (REG_CANNOT_CHANGE_MODE_P): Replace with...
480         (REG_CAN_CHANGE_MODE_P): ...this new macro.
481         * combine.c (simplify_set): Update accordingly.
482         * emit-rtl.c (validate_subreg): Likewise.
483         * recog.c (general_operand): Likewise.
484         * regcprop.c (mode_change_ok): Likewise.
485         * reload1.c (choose_reload_regs): Likewise.
486         (inherit_piecemeal_p): Likewise.
487         * rtlanal.c (simplify_subreg_regno): Likewise.
488         * postreload.c (reload_cse_simplify_set): Use REG_CAN_CHANGE_MODE_P
489         instead of CANNOT_CHANGE_MODE_CLASS.
490         (reload_cse_simplify_operands): Likewise.
491         * reload.c (push_reload): Use targetm.can_change_mode_class
492         instead of CANNOT_CHANGE_MODE_CLASS.
493         (push_reload): Likewise.  Also use REG_CAN_CHANGE_MODE_P instead of
494         REG_CANNOT_CHANGE_MODE_P.
495         * config/alpha/alpha.h (CANNOT_CHANGE_MODE_CLASS): Delete.
496         * config/alpha/alpha.c (alpha_can_change_mode_class): New function.
497         (TARGET_CAN_CHANGE_MODE_CLASS): Redefine.
498         * config/arm/arm.h (CANNOT_CHANGE_MODE_CLASS): Delete.
499         * config/arm/arm.c (TARGET_CAN_CHANGE_MODE_CLASS): Redefine.
500         (arm_can_change_mode_class): New function.
501         * config/arm/neon.md: Refer to TARGET_CAN_CHANGE_MODE_CLASS rather
502         than CANNOT_CHANGE_MODE_CLASS in comments.
503         * config/i386/i386.h (CANNOT_CHANGE_MODE_CLASS): Delete.
504         * config/i386/i386-protos.h (ix86_cannot_change_mode_class): Delete.
505         * config/i386/i386.c (ix86_cannot_change_mode_class): Replace with...
506         (ix86_can_change_mode_class): ...this new function, inverting the
507         sense of the return value.
508         (TARGET_CAN_CHANGE_MODE_CLASS): Redefine.
509         * config/ia64/ia64.h (CANNOT_CHANGE_MODE_CLASS): Delete.
510         * config/ia64/ia64.c (TARGET_CAN_CHANGE_MODE_CLASS): Redefine.
511         (ia64_can_change_mode_class): New function.
512         * config/m32c/m32c.h (CANNOT_CHANGE_MODE_CLASS): Delete.
513         * config/m32c/m32c-protos.h (m32c_cannot_change_mode_class): Delete.
514         * config/m32c/m32c.c (m32c_cannot_change_mode_class): Replace with...
515         (m32c_can_change_mode_class): ...this new function, inverting the
516         sense of the return value.
517         (TARGET_CAN_CHANGE_MODE_CLASS): Redefine.
518         * config/mips/mips.h (CANNOT_CHANGE_MODE_CLASS): Delete.
519         * config/mips/mips-protos.h (mips_cannot_change_mode_class): Delete.
520         * config/mips/mips.c (mips_cannot_change_mode_class): Replace with...
521         (mips_can_change_mode_class): ...this new function, inverting the
522         sense of the return value.
523         (TARGET_CAN_CHANGE_MODE_CLASS): Redefine.
524         * config/msp430/msp430.h (CANNOT_CHANGE_MODE_CLASS): Delete.
525         * config/msp430/msp430.c (TARGET_CAN_CHANGE_MODE_CLASS): Redefine.
526         (msp430_can_change_mode_class): New function.
527         * config/nvptx/nvptx.h (CANNOT_CHANGE_MODE_CLASS): Delete.
528         * config/nvptx/nvptx.c (nvptx_can_change_mode_class): New function.
529         (TARGET_CAN_CHANGE_MODE_CLASS): Redefine.
530         * config/pa/pa32-regs.h (CANNOT_CHANGE_MODE_CLASS): Delete.
531         * config/pa/pa64-regs.h (CANNOT_CHANGE_MODE_CLASS): Delete.
532         * config/pa/pa-protos.h (pa_cannot_change_mode_class): Delete.
533         * config/pa/pa.c (TARGET_CAN_CHANGE_MODE_CLASS): Redefine.
534         (pa_cannot_change_mode_class): Replace with...
535         (pa_can_change_mode_class): ...this new function, inverting the
536         sense of the return value.
537         (pa_modes_tieable_p): Refer to TARGET_CAN_CHANGE_MODE_CLASS rather
538         than CANNOT_CHANGE_MODE_CLASS in comments.
539         * config/pdp11/pdp11.h (CANNOT_CHANGE_MODE_CLASS): Delete.
540         * config/pdp11/pdp11-protos.h (pdp11_cannot_change_mode_class): Delete.
541         * config/pdp11/pdp11.c (TARGET_CAN_CHANGE_MODE_CLASS): Redefine.
542         (pdp11_cannot_change_mode_class): Replace with...
543         (pdp11_can_change_mode_class): ...this new function, inverting the
544         sense of the return value.
545         * config/powerpcspe/powerpcspe.h (CANNOT_CHANGE_MODE_CLASS): Delete.
546         * config/powerpcspe/powerpcspe-protos.h
547         (rs6000_cannot_change_mode_class_ptr): Delete.
548         * config/powerpcspe/powerpcspe.c
549         (rs6000_cannot_change_mode_class_ptr): Delete.
550         (TARGET_CAN_CHANGE_MODE_CLASS): Redefine.
551         (rs6000_option_override_internal): Assign to
552         targetm.can_change_mode_class instead of
553         rs6000_cannot_change_mode_class_ptr.
554         (rs6000_cannot_change_mode_class): Replace with...
555         (rs6000_can_change_mode_class): ...this new function, inverting the
556         sense of the return value.
557         (rs6000_debug_cannot_change_mode_class): Replace with...
558         (rs6000_debug_can_change_mode_class): ...this new function.
559         * config/riscv/riscv.h (CANNOT_CHANGE_MODE_CLASS): Delete.
560         * config/riscv/riscv.c (riscv_can_change_mode_class): New function.
561         (TARGET_CAN_CHANGE_MODE_CLASS): Redefine.
562         * config/rs6000/rs6000.h (CANNOT_CHANGE_MODE_CLASS): Delete.
563         * config/rs6000/rs6000-protos.h (rs6000_cannot_change_mode_class_ptr):
564         Delete.
565         * config/rs6000/rs6000.c (rs6000_cannot_change_mode_class_ptr): Delete.
566         (TARGET_CAN_CHANGE_MODE_CLASS): Redefine.
567         (rs6000_option_override_internal): Assign to
568         targetm.can_change_mode_class instead of
569         rs6000_cannot_change_mode_class_ptr.
570         (rs6000_cannot_change_mode_class): Replace with...
571         (rs6000_can_change_mode_class): ...this new function, inverting the
572         sense of the return value.
573         (rs6000_debug_cannot_change_mode_class): Replace with...
574         (rs6000_debug_can_change_mode_class): ...this new function.
575         * config/s390/s390.h (CANNOT_CHANGE_MODE_CLASS): Delete.
576         * config/s390/s390-protos.h (s390_cannot_change_mode_class): Delete.
577         * config/s390/s390.c (s390_cannot_change_mode_class): Replace with...
578         (s390_can_change_mode_class): ...this new function, inverting the
579         sense of the return value.
580         (TARGET_CAN_CHANGE_MODE_CLASS): Redefine.
581         * config/sh/sh.h (CANNOT_CHANGE_MODE_CLASS): Delete.
582         * config/sh/sh-protos.h (sh_cannot_change_mode_class): Delete.
583         * config/sh/sh.c (TARGET_CAN_CHANGE_MODE_CLASS): Redefine.
584         (sh_cannot_change_mode_class): Replace with...
585         (sh_can_change_mode_class): ...this new function, inverting the
586         sense of the return value.
587         * config/sparc/sparc.h (CANNOT_CHANGE_MODE_CLASS): Delete.
588         * config/sparc/sparc.c (TARGET_CAN_CHANGE_MODE_CLASS): Redefine.
589         (sparc_can_change_mode_class): New function.
590         * config/spu/spu.h (CANNOT_CHANGE_MODE_CLASS): Delete.
591         * config/spu/spu.c (spu_can_change_mode_class): New function.
592         (TARGET_CAN_CHANGE_MODE_CLASS): Redefine.
593         * config/visium/visium.h (CANNOT_CHANGE_MODE_CLASS): Delete.
594         * config/visium/visium.c (TARGET_CAN_CHANGE_MODE_CLASS): Redefine.
595         (visium_can_change_mode_class): New function.
596         * system.h (CANNOT_CHANGE_MODE_CLASS): Poison.
598 2017-09-15  Richard Biener  <rguenther@suse.de>
600         PR tree-optimization/82217
601         * tree-ssa-sccvn.c (visit_phi): Properly handle all VN_TOP
602         but not undefined case.
604 2017-09-15  Jakub Jelinek  <jakub@redhat.com>
606         PR target/82145
607         * postreload.c (reload_cse_simplify_operands): Skip
608         NOTE_INSN_DELETED_LABEL similarly to skipping CODE_LABEL.
610 2017-09-15  Richard Biener  <rguenther@suse.de>
612         PR tree-optimization/68823
613         * graphite-scop-detection.c (build_alias_set): If we have a
614         possible dependence check whether we can handle them by just
615         looking at the DRs DR_ACCESS_FNs.
616         (build_scops): If build_alias_set fails, fail the SCOP.
618 2017-09-14  Michael Meissner  <meissner@linux.vnet.ibm.com>
620         * config/rs6000/rs6000-builtin.def (BU_FLOAT128_1_HW): New macros
621         to support float128 built-in functions that require the ISA 3.0
622         hardware.
623         (BU_FLOAT128_3_HW): Likewise.
624         (SQRTF128): Add support for the IEEE 128-bit square root and fma
625         built-in functions.
626         (FMAF128): Likewise.
627         (FMAQ): Likewise.
628         * config/rs6000/rs6000.c (rs6000_builtin_mask_calculate): Add
629         support for built-in functions that need the ISA 3.0 IEEE 128-bit
630         floating point instructions.
631         (rs6000_invalid_builtin): Likewise.
632         (rs6000_builtin_mask_names): Likewise.
633         * config/rs6000/rs6000.h (MASK_FLOAT128_HW): Likewise.
634         (RS6000_BTM_FLOAT128_HW): Likewise.
635         (RS6000_BTM_COMMON): Likewise.
636         * config/rs6000/rs6000.md (fma<mode>4_hw): Add a generator
637         function.
638         * doc/extend.texi (RS/6000 built-in functions): Document the
639         IEEE 128-bit floating point square root and fused multiply-add
640         built-in functions.
642 2017-09-14  Pat Haugen  <pthaugen@us.ibm.com>
644         * config/rs6000/rs6000.c (rs6000_set_up_by_prologue): Make sure the TOC
645         reg (r2) isn't in the set of registers defined in the prologue.
647 2017-09-14  Richard Sandiford  <richard.sandiford@linaro.org>
648             Alan Hayward  <alan.hayward@arm.com>
649             David Sherwood  <david.sherwood@arm.com>
651         * tree-vectorizer.h (_loop_vec_info): Add max_vectorization_factor.
652         (LOOP_VINFO_MAX_VECT_FACTOR): New macro.
653         (LOOP_VINFO_ORIG_VECT_FACTOR): Replace with...
654         (LOOP_VINFO_ORIG_MAX_VECT_FACTOR): ...this new macro.
655         * tree-vect-data-refs.c (vect_analyze_data_ref_dependences): Update
656         accordingly.
657         * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Initialize
658         max_vectorization_factor.
659         (vect_analyze_loop_2): Set LOOP_VINFO_MAX_VECT_FACTOR.
661 2017-09-14  Richard Sandiford  <richard.sandiford@linaro.org>
662             Alan Hayward  <alan.hayward@arm.com>
663             David Sherwood  <david.sherwood@arm.com>
665         * tree-vectorizer.h (vect_min_worthwhile_factor): Delete.
666         (vect_worthwhile_without_simd_p): Declare.
667         * tree-vect-loop.c (vect_worthwhile_without_simd_p): New function.
668         (vectorizable_reduction): Use it.
669         * tree-vect-stmts.c (vectorizable_shift): Likewise.
670         (vectorizable_operation): Likewise.
672 2017-09-14  Richard Sandiford  <richard.sandiford@linaro.org>
673             Alan Hayward  <alan.hayward@arm.com>
674             David Sherwood  <david.sherwood@arm.com>
676         * tree-vectorizer.h (vect_get_num_copies): New function.
677         * tree-vect-data-refs.c (vect_get_data_access_cost): Use it.
678         * tree-vect-loop.c (vectorizable_reduction): Likewise.
679         (vectorizable_induction): Likewise.
680         (vectorizable_live_operation): Likewise.
681         * tree-vect-stmts.c (vectorizable_mask_load_store): Likewise.
682         (vectorizable_bswap): Likewise.
683         (vectorizable_call): Likewise.
684         (vectorizable_conversion): Likewise.
685         (vectorizable_assignment): Likewise.
686         (vectorizable_shift): Likewise.
687         (vectorizable_operation): Likewise.
688         (vectorizable_store): Likewise.
689         (vectorizable_load): Likewise.
690         (vectorizable_condition): Likewise.
691         (vectorizable_comparison): Likewise.
692         (vect_analyze_stmt): Pass the slp node to vectorizable_live_operation.
694 2017-09-14  Richard Sandiford  <richard.sandiford@linaro.org>
695             Alan Hayward  <alan.hayward@arm.com>
696             David Sherwood  <david.sherwood@arm.com>
698         * tree-vect-loop.c (vectorizable_induction): Use gimple_build instead
699         of vect_init_vector.
701 2017-09-14  Richard Sandiford  <richard.sandiford@linaro.org>
702             Alan Hayward  <alan.hayward@arm.com>
703             David Sherwood  <david.sherwood@arm.com>
705         * gimple-fold.h (gimple_build_vector_from_val): Declare, and provide
706         an inline wrapper that provides a location.
707         (gimple_build_vector): Likewise.
708         * gimple-fold.c (gimple_build_vector_from_val): New function.
709         (gimple_build_vector): Likewise.
710         * tree-vect-loop.c (get_initial_def_for_reduction): Use the new
711         functions to build the initial value.  Always return a gimple value.
712         (get_initial_defs_for_reduction): Likewise.  Only compute
713         neutral_vec once.
714         (vect_create_epilog_for_reduction): Don't call force_gimple_operand or
715         vect_init_vector on the results from get_initial_def(s)_for_reduction.
716         (vectorizable_induction): Use gimple_build_vector rather than
717         vect_init_vector.
719 2017-09-14  Richard Sandiford  <richard.sandiford@linaro.org>
720             Alan Hayward  <alan.hayward@arm.com>
721             David Sherwood  <david.sherwood@arm.com>
723         * target.h (vec_perm_indices): New typedef.
724         (auto_vec_perm_indices): Likewise.
725         * optabs-query.h: Include target.h
726         (can_vec_perm_p): Take a vec_perm_indices *.
727         * optabs-query.c (can_vec_perm_p): Likewise.
728         (can_mult_highpart_p): Update accordingly.  Use auto_vec_perm_indices.
729         * tree-ssa-forwprop.c (simplify_vector_constructor): Likewise.
730         * tree-vect-generic.c (lower_vec_perm): Likewise.
731         * tree-vect-data-refs.c (vect_grouped_store_supported): Likewise.
732         (vect_grouped_load_supported): Likewise.
733         (vect_shift_permute_load_chain): Likewise.
734         (vect_permute_store_chain): Use auto_vec_perm_indices.
735         (vect_permute_load_chain): Likewise.
736         * fold-const.c (fold_vec_perm): Take vec_perm_indices.
737         (fold_ternary_loc): Update accordingly.  Use auto_vec_perm_indices.
738         Update uses of can_vec_perm_p.
739         * tree-vect-loop.c (calc_vec_perm_mask_for_shift): Replace the
740         mode with a number of elements.  Take a vec_perm_indices *.
741         (vect_create_epilog_for_reduction): Update accordingly.
742         Use auto_vec_perm_indices.
743         (have_whole_vector_shift): Likewise.  Update call to can_vec_perm_p.
744         * tree-vect-slp.c (vect_build_slp_tree_1): Likewise.
745         (vect_transform_slp_perm_load): Likewise.
746         (vect_schedule_slp_instance): Use auto_vec_perm_indices.
747         * tree-vectorizer.h (vect_gen_perm_mask_any): Take a vec_perm_indices.
748         (vect_gen_perm_mask_checked): Likewise.
749         * tree-vect-stmts.c (vect_gen_perm_mask_any): Take a vec_perm_indices.
750         (vect_gen_perm_mask_checked): Likewise.
751         (vectorizable_mask_load_store): Use auto_vec_perm_indices.
752         (vectorizable_store): Likewise.
753         (vectorizable_load): Likewise.
754         (perm_mask_for_reverse): Likewise.  Update call to can_vec_perm_p.
755         (vectorizable_bswap): Likewise.
757 2017-09-14  Richard Sandiford  <richard.sandiford@linaro.org>
758             Alan Hayward  <alan.hayward@arm.com>
759             David Sherwood  <david.sherwood@arm.com>
761         * tree.h (build_vector): Take a vec<tree> instead of a tree *.
762         * tree.c (build_vector): Likewise.
763         (build_vector_from_ctor): Update accordingly.
764         (build_vector_from_val): Likewise.
765         * gimple-fold.c (gimple_fold_stmt_to_constant_1): Likewise.
766         * tree-ssa-forwprop.c (simplify_vector_constructor): Likewise.
767         * tree-vect-generic.c (add_rshift): Likewise.
768         (expand_vector_divmod): Likewise.
769         (optimize_vector_constructor): Likewise.
770         * tree-vect-slp.c (vect_get_constant_vectors): Likewise.
771         (vect_transform_slp_perm_load): Likewise.
772         (vect_schedule_slp_instance): Likewise.
773         * tree-vect-stmts.c (vectorizable_bswap): Likewise.
774         (vectorizable_call): Likewise.
775         (vect_gen_perm_mask_any): Likewise.  Add elements in order.
776         * expmed.c (make_tree): Likewise.
777         * fold-const.c (fold_negate_expr_1): Use auto_vec<tree> when building
778         a vector passed to build_vector.
779         (fold_convert_const): Likewise.
780         (exact_inverse): Likewise.
781         (fold_ternary_loc): Likewise.
782         (fold_relational_const): Likewise.
783         (const_binop): Likewise.  Use VECTOR_CST_ELT directly when operating
784         on VECTOR_CSTs, rather than going through vec_cst_ctor_to_array.
785         (const_unop): Likewise.  Store the reduction accumulator in a
786         variable rather than an array.
787         (vec_cst_ctor_to_array): Take the number of elements as a parameter.
788         (fold_vec_perm): Update calls accordingly.  Use auto_vec<tree> for
789         the new vector, rather than constructing it after the input arrays.
790         (native_interpret_vector): Use auto_vec<tree> when building
791         a vector passed to build_vector.  Add elements in order.
792         * tree-vect-loop.c (get_initial_defs_for_reduction): Use
793         auto_vec<tree> when building a vector passed to build_vector.
794         (vect_create_epilog_for_reduction): Likewise.
795         (vectorizable_induction): Likewise.
796         (get_initial_def_for_reduction): Likewise.  Fix indentation of
797         case statements.
798         * config/sparc/sparc.c (sparc_handle_vis_mul8x16): Change n_elts
799         to a vec<tree> *.
800         (sparc_fold_builtin): Use auto_vec<tree> when building a vector
801         passed to build_vector.
803 2017-09-14  Richard Sandiford  <richard.sandiford@linaro.org>
804             Alan Hayward  <alan.hayward@arm.com>
805             David Sherwood  <david.sherwood@arm.com>
807         * tree-core.h (tree_base::u): Add an "nelts" field.
808         (tree_vector): Use VECTOR_CST_NELTS as the length.
809         * tree.c (tree_size): Likewise.
810         (make_vector): Initialize VECTOR_CST_NELTS.
811         * tree.h (VECTOR_CST_NELTS): Use the u.nelts field.
812         * cfgexpand.c (expand_debug_expr): Use VECTOR_CST_NELTS instead of
813         TYPE_VECTOR_SUBPARTS.
814         * expr.c (const_vector_mask_from_tree): Consistently use "units"
815         as the number of units, setting it from VECTOR_CST_NELTS.
816         (const_vector_from_tree): Likewise.
817         * fold-const.c (negate_expr_p): Use VECTOR_CST_NELTS instead of
818         TYPE_VECTOR_SUBPARTS for the number of elements in a VECTOR_CST.
819         (fold_negate_expr_1): Likewise.
820         (fold_convert_const): Likewise.
821         (const_binop): Likewise.  Differentiate the number of output and
822         input elements.
823         (const_unop): Likewise.
824         (fold_ternary_loc): Use VECTOR_CST_NELTS for the number of elements
825         in a VECTOR_CST, asserting that it is the same as TYPE_VECTOR_SUBPARTS
826         in cases that did the opposite.
828 2017-09-14  Richard Biener  <rguenther@suse.de>
830         * tree-ssa-sccvn.c (visit_phi): Merge undefined values similar
831         to VN_TOP.
833 2017-09-14  Eric Botcazou  <ebotcazou@adacore.com>
835         * dwarf2out.c (dwarf2out_source_line): Remove superfluous test.
837 2017-09-14  Jakub Jelinek  <jakub@redhat.com>
839         PR target/81325
840         * cfgbuild.c (find_bb_boundaries): Ignore debug insns in decisions
841         if and where to split a bb, except for splitting before debug insn
842         sequences followed by non-label real insn.  Delete debug insns
843         in between basic blocks.
845         * combine.c (make_compound_operation_int): Formatting fixes.
847         * config/alpha/elf.h (LINK_EH_SPEC): Add -static-pie support.
848         * config/alpha/linux.h (LINK_GCC_C_SEQUENCE_SPEC): Likewise.
849         * config/netbsd.h (LINK_EH_SPEC): Likewise.
850         * config/sol2.h (LINK_EH_SPEC): Likewise.
851         * config/arm/uclinux-elf.h (LINK_GCC_C_SEQUENCE_SPEC): Likewise.
852         * config/s390/linux.h (LINK_SPEC): Likewise.
853         * config/freebsd.h (LINK_EH_SPEC): Likewise.
854         * config/openbsd.h (LINK_EH_SPEC): Likewise.
855         * config/lm32/uclinux-elf.h (LINK_GCC_C_SEQUENCE_SPEC): Likewise.
856         * config/aarch64/aarch64-linux.h (LINUX_TARGET_LINK_SPEC): Likewise.
857         * config/powerpcspe/sysv4.h (LINK_EH_SPEC): Likewise.
858         * config/bfin/linux.h (LINK_GCC_C_SEQUENCE_SPEC): Likewise.
859         * config/i386/gnu-user64.h (GNU_USER_TARGET_LINK_SPEC): Fix a typo.
860         * config/i386/gnu-user.h (GNU_USER_TARGET_LINK_SPEC): Formatting fix.
862 2017-09-13  Jakub Jelinek  <jakub@redhat.com>
864         * config/rs6000/sysv4.h (STARTFILE_LINUX_SPEC): Add -static-pie
865         support.
866         (ENDFILE_LINUX_SPEC): Likewise.
867         (LINK_EH_SPEC): Likewise.
868         * config/rs6000/linux64.h (LINK_SHLIB_SPEC): Likewise.
869         (LINK_OS_LINUX_SPEC32): Likewise.
870         (LINK_OS_LINUX_SPEC64): Likewise.
871         * config/rs6000/linux.h (LINK_SHLIB_SPEC): Likewise.
872         (LINK_OS_LINUX_SPEC): Likewise.
874 2017-09-13  Martin Liska  <mliska@suse.cz>
876         PR middle-end/82154
877         * stmt.c (expand_sjlj_dispatch_table): Use CASE_LOW when
878         CASE_HIGH is NULL_TREE.
880 2017-09-13  Richard Sandiford  <richard.sandiford@linaro.org>
881             Alan Hayward  <alan.hayward@arm.com>
882             David Sherwood  <david.sherwood@arm.com>
884         * target.def (secondary_memory_needed): New hook.
885         (secondary_reload): Refer to TARGET_SECONDARY_MEMORY_NEEDED
886         instead of SECONDARY_MEMORY_NEEDED.
887         (secondary_memory_needed_mode): Likewise.
888         * hooks.h (hook_bool_mode_reg_class_t_reg_class_t_false): Declare.
889         * hooks.c (hook_bool_mode_reg_class_t_reg_class_t_false): New function.
890         * doc/tm.texi.in (SECONDARY_MEMORY_NEEDED): Replace with...
891         (TARGET_SECONDARY_MEMORY_NEEDED): ...this.
892         (SECONDARY_MEMORY_NEEDED_RTX): Update reference accordingly.
893         * doc/tm.texi: Regenerate.
894         * config/alpha/alpha.h (SECONDARY_MEMORY_NEEDED): Delete.
895         * config/alpha/alpha.c (alpha_secondary_memory_needed): New function.
896         (TARGET_SECONDARY_MEMORY_NEEDED): Redefine.
897         * config/i386/i386.h (SECONDARY_MEMORY_NEEDED): Delete.
898         * config/i386/i386-protos.h (ix86_secondary_memory_needed): Delete.
899         * config/i386/i386.c (inline_secondary_memory_needed): Put the
900         mode argument first and change the reg_class arguments to reg_class_t.
901         (ix86_secondary_memory_needed): Likewise.  Remove the strict parameter.
902         Make static.  Update the call to inline_secondary_memory_needed.
903         (ix86_register_move_cost): Update the call to
904         inline_secondary_memory_needed.
905         (TARGET_SECONDARY_MEMORY_NEEDED): Redefine.
906         * config/ia64/ia64.h (SECONDARY_MEMORY_NEEDED): Delete commented-out
907         definition.
908         * config/ia64/ia64.c (spill_xfmode_rfmode_operand): Refer to
909         TARGET_SECONDARY_MEMORY_NEEDED rather than SECONDARY_MEMORY_NEEDED
910         in comment.
911         * config/mips/mips.h (SECONDARY_MEMORY_NEEDED): Delete.
912         * config/mips/mips-protos.h (mips_secondary_memory_needed): Delete.
913         * config/mips/mips.c (mips_secondary_memory_needed): Make static
914         and match hook interface.  Add comment from mips.h.
915         (TARGET_SECONDARY_MEMORY_NEEDED): Redefine.
916         * config/mmix/mmix.md (truncdfsf2): Refer to
917         TARGET_SECONDARY_MEMORY_NEEDED rather than SECONDARY_MEMORY_NEEDED
918         in comment.
919         * config/pa/pa-64.h (SECONDARY_MEMORY_NEEDED): Rename to...
920         (PA_SECONDARY_MEMORY_NEEDED): ...this, and put the mode argument first.
921         * config/pa/pa.c (TARGET_SECONDARY_MEMORY_NEEDED): Redefine.
922         (pa_secondary_memory_needed): New function.
923         * config/pdp11/pdp11.h (SECONDARY_MEMORY_NEEDED): Delete.
924         * config/pdp11/pdp11-protos.h (pdp11_secondary_memory_needed): Delete.
925         * config/pdp11/pdp11.c (TARGET_SECONDARY_MEMORY_NEEDED): Redefine.
926         (pdp11_secondary_memory_needed): Make static and match hook interface.
927         * config/powerpcspe/powerpcspe.h (SECONDARY_MEMORY_NEEDED): Delete.
928         * config/powerpcspe/powerpcspe-protos.h
929         (rs6000_secondary_memory_needed_ptr): Delete.
930         * config/powerpcspe/powerpcspe.c (rs6000_secondary_memory_needed_ptr):
931         Delete.
932         (TARGET_SECONDARY_MEMORY_NEEDED): Redefine.
933         (rs6000_option_override_internal): Assign to
934         targetm.secondary_memory_needed rather than
935         rs6000_secondary_memory_needed_ptr.
936         (rs6000_secondary_memory_needed): Match hook interface.
937         (rs6000_debug_secondary_memory_needed): Likewise.
938         * config/riscv/riscv.h (SECONDARY_MEMORY_NEEDED): Delete.
939         * config/riscv/riscv.c (riscv_secondary_memory_needed): New function.
940         (riscv_register_move_cost): Use it instead of SECONDARY_MEMORY_NEEDED.
941         (TARGET_SECONDARY_MEMORY_NEEDED): Redefine.
942         * config/rs6000/rs6000.h (SECONDARY_MEMORY_NEEDED): Delete.
943         * config/rs6000/rs6000-protos.h (rs6000_secondary_memory_needed_ptr):
944         Delete.
945         * config/rs6000/rs6000.c (rs6000_secondary_memory_needed_ptr): Delete.
946         (TARGET_SECONDARY_MEMORY_NEEDED): Redefine.
947         (rs6000_option_override_internal): Assign to
948         targetm.secondary_memory_needed rather than
949         rs6000_secondary_memory_needed_ptr.
950         (rs6000_secondary_memory_needed): Match hook interface.
951         (rs6000_debug_secondary_memory_needed): Likewise.
952         * config/s390/s390.h (SECONDARY_MEMORY_NEEDED): Delete.
953         * config/s390/s390.c (s390_secondary_memory_needed): New function.
954         (TARGET_SECONDARY_MEMORY_NEEDED): Redefine.
955         * config/sparc/sparc.h (SECONDARY_MEMORY_NEEDED): Delete.
956         * config/sparc/sparc.c (TARGET_SECONDARY_MEMORY_NEEDED): Redefine.
957         (sparc_secondary_memory_needed): New function.
958         * lra-constraints.c (check_and_process_move): Refer to
959         TARGET_SECONDARY_MEMORY_NEEDED rather than SECONDARY_MEMORY_NEEDED
960         in comment.
961         (curr_insn_transform): Likewise.
962         (process_alt_operands): Use targetm.secondary_memory_needed
963         instead of TARGET_SECONDARY_MEMORY_NEEDED.
964         (check_secondary_memory_needed_p): Likewise.
965         (choose_split_class): Likewise.
966         * reload.c: Unconditionally include code that was previously
967         conditional on SECONDARY_MEMORY_NEEDED.
968         (push_secondary_reload): Use targetm.secondary_memory_needed
969         instead of TARGET_SECONDARY_MEMORY_NEEDED.
970         (push_reload): Likewise.
971         * reload1.c: Unconditionally include code that was previously
972         conditional on SECONDARY_MEMORY_NEEDED.
973         (choose_reload_regs): Use targetm.secondary_memory_needed
974         instead of TARGET_SECONDARY_MEMORY_NEEDED.
975         (gen_reload): Likewise.
976         * system.h (SECONDARY_MEMORY_NEEDED): Poison.
978 2017-09-13  Richard Sandiford  <richard.sandiford@linaro.org>
979             Alan Hayward  <alan.hayward@arm.com>
980             David Sherwood  <david.sherwood@arm.com>
982         * target.def (secondary_memory_needed_mode): New hook:
983         * targhooks.c (default_secondary_memory_needed_mode): Declare.
984         * targhooks.h (default_secondary_memory_needed_mode): New function.
985         * doc/tm.texi.in (SECONDARY_MEMORY_NEEDED_MODE): Replace with...
986         (TARGET_SECONDARY_MEMORY_NEEDED_MODE): ...this.
987         * doc/tm.texi: Regenerate.
988         * lra-constraints.c (check_and_process_move): Use
989         targetm.secondary_memory_needed_mode instead of
990         TARGET_SECONDARY_MEMORY_NEEDED_MODE.
991         (curr_insn_transform): Likewise.
992         * reload.c (get_secondary_mem): Likewise.
993         * config/alpha/alpha.h (SECONDARY_MEMORY_NEEDED_MODE): Delete.
994         * config/alpha/alpha.c (alpha_secondary_memory_needed_mode): New
995         function.
996         (TARGET_SECONDARY_MEMORY_NEEDED_MODE): Redefine.
997         * config/i386/i386.h (SECONDARY_MEMORY_NEEDED_MODE): Delete.
998         * config/i386/i386.c (ix86_secondary_memory_needed_mode): New function.
999         (TARGET_SECONDARY_MEMORY_NEEDED_MODE): Redefine.
1000         * config/powerpcspe/powerpcspe.h (SECONDARY_MEMORY_NEEDED_MODE):
1001         Delete.
1002         * config/powerpcspe/powerpcspe-protos.h
1003         (rs6000_secondary_memory_needed_mode): Delete.
1004         * config/powerpcspe/powerpcspe.c
1005         (TARGET_SECONDARY_MEMORY_NEEDED_MODE): Redefine.
1006         (rs6000_secondary_memory_needed_mode): Make static.
1007         * config/rs6000/rs6000.h (SECONDARY_MEMORY_NEEDED_MODE): Delete.
1008         * config/rs6000/rs6000-protos.h (rs6000_secondary_memory_needed_mode):
1009         Delete.
1010         * config/rs6000/rs6000.c (TARGET_SECONDARY_MEMORY_NEEDED_MODE):
1011         Redefine.
1012         (rs6000_secondary_memory_needed_mode): Make static.
1013         * config/s390/s390.h (SECONDARY_MEMORY_NEEDED_MODE): Delete.
1014         * config/s390/s390.c (s390_secondary_memory_needed_mode): New function.
1015         (TARGET_SECONDARY_MEMORY_NEEDED_MODE): Redefine.
1016         * config/sparc/sparc.h (SECONDARY_MEMORY_NEEDED_MODE): Delete.
1017         * config/sparc/sparc.c (TARGET_SECONDARY_MEMORY_NEEDED_MODE):
1018         Redefine.
1019         (sparc_secondary_memory_needed_mode): New function.
1020         * system.h (TARGET_SECONDARY_MEMORY_NEEDED_MODE): Poison.
1022 2017-09-13  Jackson Woodruff  <jackson.woodruff@arm.com>
1024         * config/aarch64/constraints.md (Umq): New constraint.
1025         * config/aarch64/aarch64-simd.md (*aarch64_simd_mov<mode>):
1026         Change to use Umq.
1027         (mov<mode>): Update condition.
1029 2017-09-13  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
1031         * gimple-ssa-store-merging.c (sort_by_bitpos): Compare store order
1032         when bitposition is the same.
1034 2017-09-13  Richard Biener  <rguenther@suse.de>
1036         * dwarf2out.c (output_die_symbol): Remove.
1037         (output_die): Do not output a DIEs symbol.
1039 2017-09-13  Richard Biener  <rguenther@suse.de>
1041         PR middle-end/82128
1042         * gimple-fold.c (gimple_fold_call): Update SSA name in-place to
1043         default-def to avoid breaking iterator update with the weird
1044         interaction with cgraph_update_edges_for_call_stmt_node.
1046 2017-09-13  Richard Biener  <rguenther@suse.de>
1048         * tree-cfg.c (verify_gimple_assign_binary): Add verification
1049         for WIDEN_SUM_EXPR, VEC_WIDEN_MULT_{HI,LO,EVEN,ODD}_EXPR,
1050         VEC_PACK_{TRUNC,SAT,FIX_TRUNC}_EXPR.
1051         (verify_gimple_assign_ternary): Add verification for DOT_PROD_EXPR.
1053 2017-09-13  Kugan Vivekanandarajah  <kuganv@linaro.org>
1055         * config/aarch64/aarch64.c (aarch64_override_options_after_change_1):
1056         Disable pc relative literal load irrespective of
1057         TARGET_FIX_ERR_A53_84341 for default.
1059 2017-09-12  Eric Botcazou  <ebotcazou@adacore.com>
1061         * config/sparc/sparc.c (output_return): Output the source location of
1062         the insn in the delay slot, if any.
1063         (output_sibcall): Likewise.
1065 2017-09-12  H.J. Lu  <hongjiu.lu@intel.com>
1067         PR driver/81498
1068         * common.opt (-static-pie): New alias.
1069         (shared): Negate static-pie.
1070         (-no-pie): Update help text.
1071         (-pie): Likewise.
1072         (static-pie): New option.
1073         * config/gnu-user.h (GNU_USER_TARGET_STARTFILE_SPEC): Add
1074         -static-pie support.
1075         (GNU_USER_TARGET_ENDFILE_SPEC): Likewise.
1076         (LINK_EH_SPEC): Likewise.
1077         (LINK_GCC_C_SEQUENCE_SPEC): Likewise.
1078         * config/i386/gnu-user.h (GNU_USER_TARGET_LINK_SPEC): Likewise.
1079         * config/i386/gnu-user64.h (GNU_USER_TARGET_LINK_SPEC): Likewise.
1080         * gcc.c (LINK_COMMAND_SPEC): Likewise.
1081         (init_gcc_specs): Likewise.
1082         (init_spec): Likewise.
1083         (display_help): Update help message for -pie.
1084         * doc/invoke.texi: Update -pie, -no-pie and -static.  Document
1085         -static-pie.
1087 2017-09-12  Wilco Dijkstra  <wdijkstr@arm.com>
1089         * config/aarch64/aarch64.md (movsi_aarch64): Remove all '*'.
1090         (movdi_aarch64): Likewise.
1091         (movti_aarch64): Likewise.
1093 2017-09-12 Simon Wright <simon@pushface.org>
1095         PR target/80204
1096         * config/darwin-driver.c (darwin_find_version_from_kernel): Eliminate
1097         calculation of the minor version, always output as 0.
1099 2017-09-12  Jakub Jelinek  <jakub@redhat.com>
1101         PR target/82112
1102         * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin): For
1103         ALTIVEC_BUILTIN_VEC_LD if arg1 has array type call default_conversion
1104         on it early, rather than manual conversion late.  For
1105         ALTIVEC_BUILTIN_VEC_ST if arg2 has array type call default_conversion
1106         instead of performing manual conversion.
1108 2017-09-12  Carl Love  <cel@us.ibm.com>
1110         * config/rs6000/altivec.md (vec_widen_umult_even_v4si,
1111         vec_widen_smult_even_v4si): Add define expands for vmuleuw, vmulesw,
1112         vmulouw, vmulosw.
1113         * config/rs6000/rs6000-builtin.def (VMLEUW, VMULESW, VMULOUW,
1114         VMULOSW): Add definitions.
1115         * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Add
1116         ALTIVEC_BUILTIN_VMULESW, ALTIVEC_BUILTIN_VMULEUW,
1117         ALTIVEC_BUILTIN_VMULOSW, ALTIVEC_BUILTIN_VMULOUW entries.
1118         * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin,
1119         builtin_function_type): Add ALTIVEC_BUILTIN_* case statements.
1121 2017-09-12  James Greenhalgh  <james.greenhalgh@arm.com>
1123         * config/aarch64/aarch64.md (movdi_aarch64): Set load/store
1124         types correctly.
1125         (movti_aarch64): Likewise.
1126         (movdf_aarch64): Likewise.
1127         (movtf_aarch64): Likewise.
1128         (load_pairdi): Likewise.
1129         (store_pairdi): Likewise.
1130         (load_pairdf): Likewise.
1131         (store_pairdf): Likewise.
1132         (loadwb_pair<GPI:mode>_<P:mode>): Likewise.
1133         (storewb_pair<GPI:mode>_<P:mode>): Likewise.
1134         (ldr_got_small_<mode>): Likewise.
1135         (ldr_got_small_28k_<mode>): Likewise.
1136         (ldr_got_tiny): Likewise.
1137         * config/aarch64/iterators.md (ldst_sz): New.
1138         (ldpstp_sz): Likewise.
1139         * config/aarch64/thunderx.md (thunderx_storepair): Split store_8
1140         to store_16.
1141         (thunderx_load): Split load_8 to load_16.
1142         * config/aarch64/thunderx2t99.md (thunderx2t99_loadpair): Split
1143         load_8 to load_16.
1144         (thunderx2t99_storepair_basic): Split store_8 to store_16.
1145         * config/arm/xgene1.md (xgene1_load_pair): Split load_8 to load_16.
1146         (xgene1_store_pair): Split store_8 to store_16.
1147         * config/aarch64/falkor.md (falkor_ld_3_ld): Split load_8 to load_16.
1148         (falkor_st_0_st_sd): Split store_8 to store_16.
1150 2017-09-12  James Greenhalgh  <james.greenhalgh@arm.com>
1152         * config/arm/types.md (type): Rename load1/2/3/4 to load_4/8/12/16
1153         and store1/2/3/4 to store_4/8/12/16.
1154         * config/aarch64/aarch64.md: Update for rename.
1155         * config/arm/arm.md: Likewise.: Likewise.
1156         * config/arm/arm.c: Likewise.
1157         * config/arm/thumb1.md: Likewise.
1158         * config/arm/thumb2.md: Likewise.
1159         * config/arm/vfp.md: Likewise.
1160         * config/arm/arm-generic.md: Likewise.
1161         * config/arm/arm1020e.md: Likewise.
1162         * config/arm/arm1026ejs.md: Likewise.
1163         * config/arm/arm1136jfs.md: Likewise.
1164         * config/arm/arm926ejs.md: Likewise.
1165         * config/arm/cortex-a15.md: Likewise.
1166         * config/arm/cortex-a17.md: Likewise.
1167         * config/arm/cortex-a5.md: Likewise.
1168         * config/arm/cortex-a53.md: Likewise.
1169         * config/arm/cortex-a57.md: Likewise.
1170         * config/arm/cortex-a7.md: Likewise.
1171         * config/arm/cortex-a8.md: Likewise.
1172         * config/arm/cortex-a9.md: Likewise.
1173         * config/arm/cortex-m4.md: Likewise.
1174         * config/arm/cortex-m7.md: Likewise.
1175         * config/arm/cortex-r4.md: Likewise.
1176         * config/arm/exynos-m1.md: Likewise.
1177         * config/arm/fa526.md: Likewise.
1178         * config/arm/fa606te.md: Likewise.
1179         * config/arm/fa626te.md: Likewise.
1180         * config/arm/fa726te.md: Likewise.
1181         * config/arm/fmp626.md: Likewise.
1182         * config/arm/iwmmxt.md: Likewise.
1183         * config/arm/ldmstm.md: Likewise.
1184         * config/arm/marvell-pj4.md: Likewise.
1185         * config/arm/xgene1.md: Likewise.
1186         * config/aarch64/thunderx.md: Likewise.
1187         * config/aarch64/thunderx2t99.md: Likewise.
1188         * config/aarch64/falkor.md: Likewise.
1190 2017-09-12  Martin Liska  <mliska@suse.cz>
1192         * attribs.c (private_lookup_attribute): New function.
1193         * attribs.h (private_lookup_attribute): Declared here.
1194         (lookup_attribute): Called from this place.
1196 2017-09-12  Richard Biener  <rguenther@suse.de>
1198         PR tree-optimization/82157
1199         * tree-ssa-pre.c (remove_dead_inserted_code): Do not remove
1200         stmts with side-effects.
1202 2017-09-12  Richard Sandiford  <richard.sandiford@linaro.org>
1203             Alan Hayward  <alan.hayward@arm.com>
1204             David Sherwood <david.sherwood@arm.com>
1206         * target.def (hard_regno_nregs): New hook.
1207         (class_max_nregs): Refer to it instead of HARD_REGNO_NREGS.
1208         * targhooks.h (default_hard_regno_nregs): Declare.
1209         * targhooks.c (default_hard_regno_nregs): New function.
1210         * doc/tm.texi.in (HARD_REGNO_NREGS): Replace with...
1211         (TARGET_HARD_REGNO_NREGS): ...this hook.
1212         (HARD_REGNO_NREGS_HAS_PADDING): Update accordingly.
1213         (CLASS_MAX_NREGS): Likewise.
1214         * doc/tm.texi: Regenerate.
1215         * reginfo.c (init_reg_modes_target): Use targetm.hard_regno_nregs
1216         instead of HARD_REGNO_NREGS.
1217         * rtl.h (REG_NREGS): Refer to TARGET_HARD_REGNO_NREGS rather than
1218         HARD_REGNO_NREGS in the comment.
1219         * config/aarch64/aarch64.h (HARD_REGNO_NREGS): Delete.
1220         * config/aarch64/aarch64-protos.h (aarch64_hard_regno_nregs): Delete.
1221         * config/aarch64/aarch64.c (aarch64_hard_regno_nregs): Make static.
1222         Return an unsigned int.
1223         (TARGET_HARD_REGNO_NREGS): Redefine.
1224         * config/alpha/alpha.h (HARD_REGNO_NREGS): Delete.
1225         * config/arc/arc.h (HARD_REGNO_NREGS): Delete.
1226         * config/arc/arc.c (TARGET_HARD_REGNO_NREGS): Redefine.
1227         (arc_hard_regno_nregs): New function.
1228         * config/arm/arm.h (HARD_REGNO_NREGS): Delete.
1229         * config/arm/arm.c (TARGET_HARD_REGNO_NREGS): Redefine.
1230         (arm_hard_regno_nregs): New function.
1231         * config/avr/avr.h (HARD_REGNO_NREGS): Delete.
1232         * config/bfin/bfin.h (HARD_REGNO_NREGS): Delete.
1233         * config/bfin/bfin.c (bfin_hard_regno_nregs): New function.
1234         (TARGET_HARD_REGNO_NREGS): Redefine.
1235         * config/c6x/c6x.h (HARD_REGNO_NREGS): Delete.
1236         * config/cr16/cr16.h (LONG_REG_P): Use targetm.hard_regno_nregs.
1237         (HARD_REGNO_NREGS): Delete.
1238         * config/cr16/cr16.c (TARGET_HARD_REGNO_NREGS): Redefine.
1239         (cr16_hard_regno_nregs): New function.
1240         (cr16_memory_move_cost): Use it instead of HARD_REGNO_NREGS.
1241         * config/cris/cris.h (HARD_REGNO_NREGS): Delete.
1242         * config/cris/cris.c (TARGET_HARD_REGNO_NREGS): Redefine.
1243         (cris_hard_regno_nregs): New function.
1244         * config/epiphany/epiphany.h (HARD_REGNO_NREGS): Delete.
1245         * config/fr30/fr30.h (HARD_REGNO_NREGS): Delete.
1246         (CLASS_MAX_NREGS): Use targetm.hard_regno_nregs.
1247         * config/frv/frv.h (HARD_REGNO_NREGS): Delete.
1248         (CLASS_MAX_NREGS): Remove outdated copy of documentation.
1249         * config/frv/frv-protos.h (frv_hard_regno_nregs): Delete.
1250         * config/frv/frv.c (TARGET_HARD_REGNO_NREGS): Redefine.
1251         (frv_hard_regno_nregs): Make static.  Take and return an
1252         unsigned int.
1253         (frv_class_max_nregs): Remove outdated copy of documentation.
1254         * config/ft32/ft32.h (HARD_REGNO_NREGS): Delete.
1255         * config/h8300/h8300.h (HARD_REGNO_NREGS): Delete.
1256         * config/h8300/h8300-protos.h (h8300_hard_regno_nregs): Delete.
1257         * config/h8300/h8300.c (h8300_hard_regno_nregs): Delete.
1258         * config/i386/i386.h (HARD_REGNO_NREGS): Delete.
1259         * config/i386/i386.c (ix86_hard_regno_nregs): New function.
1260         (TARGET_HARD_REGNO_NREGS): Redefine.
1261         * config/ia64/ia64.h (HARD_REGNO_NREGS): Delete.
1262         (CLASS_MAX_NREGS): Update comment.
1263         * config/ia64/ia64.c (TARGET_HARD_REGNO_NREGS): Redefine.
1264         (ia64_hard_regno_nregs): New function.
1265         * config/iq2000/iq2000.h (HARD_REGNO_NREGS): Delete.
1266         * config/lm32/lm32.h (HARD_REGNO_NREGS): Delete.
1267         * config/m32c/m32c.h (HARD_REGNO_NREGS): Delete.
1268         * config/m32c/m32c-protos.h (m32c_hard_regno_nregs): Delete.
1269         * config/m32c/m32c.c (m32c_hard_regno_nregs_1): Take and return
1270         an unsigned int.
1271         (m32c_hard_regno_nregs): Likewise.  Make static.
1272         (TARGET_HARD_REGNO_NREGS): Redefine.
1273         * config/m32r/m32r.h (HARD_REGNO_NREGS): Delete.
1274         * config/m68k/m68k.h (HARD_REGNO_NREGS): Delete.
1275         * config/m68k/m68k.c (TARGET_HARD_REGNO_NREGS): Redefine.
1276         (m68k_hard_regno_nregs): New function.
1277         * config/mcore/mcore.h (HARD_REGNO_NREGS): Delete.
1278         * config/microblaze/microblaze.h (HARD_REGNO_NREGS): Delete.
1279         * config/mips/mips.h (HARD_REGNO_NREGS): Delete.
1280         * config/mips/mips-protos.h (mips_hard_regno_nregs): Delete.
1281         * config/mips/mips.c (mips_hard_regno_nregs): Make static.
1282         Take and return an unsigned int.
1283         (TARGET_HARD_REGNO_NREGS): Redefine.
1284         * config/mmix/mmix.h (HARD_REGNO_NREGS): Delete.
1285         (CLASS_MAX_NREGS): Use targetm.hard_regno_nregs.
1286         * config/mn10300/mn10300.h (HARD_REGNO_NREGS): Delete.
1287         * config/moxie/moxie.h (HARD_REGNO_NREGS): Delete.
1288         * config/msp430/msp430.h (HARD_REGNO_NREGS): Delete.
1289         * config/msp430/msp430-protos.h (msp430_hard_regno_nregs): Delete.
1290         * config/msp430/msp430.c (TARGET_HARD_REGNO_NREGS): Redefine.
1291         (msp430_hard_regno_nregs): Make static.  Take and return an
1292         unsigned int.
1293         * config/nds32/nds32.h (HARD_REGNO_NREGS): Delete.
1294         * config/nds32/nds32-protos.h (nds32_hard_regno_nregs): Delete.
1295         * config/nds32/nds32.c (nds32_hard_regno_nregs): Delete.
1296         (nds32_hard_regno_mode_ok): Use targetm.hard_regno_nregs.
1297         * config/nios2/nios2.h (HARD_REGNO_NREGS): Delete.
1298         * config/nvptx/nvptx.h (HARD_REGNO_NREGS): Delete.
1299         * config/nvptx/nvptx.c (nvptx_hard_regno_nregs): New function.
1300         (TARGET_HARD_REGNO_NREGS): Redefine.
1301         * config/pa/pa32-regs.h (HARD_REGNO_NREGS): Rename to...
1302         (PA_HARD_REGNO_NREGS): ...this.
1303         * config/pa/pa64-regs.h (HARD_REGNO_NREGS): Rename to...
1304         (PA_HARD_REGNO_NREGS): ...this.
1305         * config/pa/pa.c (TARGET_HARD_REGNO_NREGS): Redefine.
1306         (pa_hard_regno_nregs): New function.
1307         * config/pdp11/pdp11.h (HARD_REGNO_NREGS): Delete.
1308         * config/pdp11/pdp11.c (TARGET_HARD_REGNO_NREGS): Redefine.
1309         (pdp11_hard_regno_nregs): New function.
1310         * config/powerpcspe/powerpcspe.h (HARD_REGNO_NREGS): Delete.
1311         * config/powerpcspe/powerpcspe.c (TARGET_HARD_REGNO_NREGS): Redefine.
1312         (rs6000_hard_regno_nregs_hook): New function.
1313         * config/riscv/riscv.h (HARD_REGNO_NREGS): Delete.
1314         * config/riscv/riscv-protos.h (riscv_hard_regno_nregs): Delete.
1315         * config/riscv/riscv.c (riscv_hard_regno_nregs): Make static.
1316         Take and return an unsigned int.  Move earlier in file.
1317         (TARGET_HARD_REGNO_NREGS): Redefine.
1318         * config/rl78/rl78.h (HARD_REGNO_NREGS): Delete.
1319         * config/rl78/rl78-protos.h (rl78_hard_regno_nregs): Delete.
1320         * config/rl78/rl78.c (TARGET_HARD_REGNO_NREGS): Reefine.
1321         (rl78_hard_regno_nregs): Make static.  Take and return an
1322         unsigned int.
1323         * config/rs6000/rs6000.h (HARD_REGNO_NREGS): Delete.
1324         * config/rs6000/rs6000.c (TARGET_HARD_REGNO_NREGS): Redefine.
1325         (rs6000_hard_regno_nregs_hook): New function.
1326         * config/rx/rx.h (HARD_REGNO_NREGS): Delete.
1327         * config/rx/rx.c (rx_hard_regno_nregs): New function.
1328         (TARGET_HARD_REGNO_NREGS): Redefine.
1329         * config/s390/s390.h (HARD_REGNO_NREGS): Delete.
1330         * config/s390/s390.c (REGNO_PAIR_OK): Use s390_hard_regno_nregs
1331         instead of HARD_REGNO_NREGS.
1332         (s390_hard_regno_nregs): New function.
1333         (s390_hard_regno_mode_ok): Add comment from s390.h.
1334         (TARGET_HARD_REGNO_NREGS): Redefine.
1335         * config/sh/sh.h (HARD_REGNO_NREGS): Delete.
1336         * config/sh/sh.c (TARGET_HARD_REGNO_NREGS): Redefine.
1337         (sh_hard_regno_nregs): New function.
1338         (sh_pass_in_reg_p): Use it.
1339         * config/sparc/sparc.h (HARD_REGNO_NREGS): Delete.
1340         * config/sparc/sparc.c (TARGET_HARD_REGNO_NREGS): Redefine.
1341         (sparc_hard_regno_nregs): New function.
1342         * config/spu/spu.h (HARD_REGNO_NREGS): Delete.
1343         * config/spu/spu.c (spu_hard_regno_nregs): New function.
1344         (spu_function_arg_advance): Use it, supplying a valid register number.
1345         (TARGET_HARD_REGNO_NREGS): Redefine.
1346         * config/stormy16/stormy16.h (HARD_REGNO_NREGS): Delete.
1347         * config/tilegx/tilegx.h (HARD_REGNO_NREGS): Delete.
1348         * config/tilepro/tilepro.h (HARD_REGNO_NREGS): Delete.
1349         * config/v850/v850.h (HARD_REGNO_NREGS): Delete.
1350         * config/vax/vax.h (HARD_REGNO_NREGS): Delete.
1351         * config/visium/visium.h (HARD_REGNO_NREGS): Delete.
1352         (CLASS_MAX_NREGS): Remove copy of old documentation.
1353         * config/visium/visium.c (TARGET_HARD_REGNO_NREGS): Redefine.
1354         (visium_hard_regno_nregs): New function.
1355         (visium_hard_regno_mode_ok): Use it instead of HARD_REGNO_NREGS.
1356         * config/xtensa/xtensa.h (HARD_REGNO_NREGS): Delete.
1357         * config/xtensa/xtensa.c (TARGET_HARD_REGNO_NREGS): Redefine.
1358         xtensa_hard_regno_nregs): New function.
1359         * system.h (HARD_REGNO_NREGS): Poison.
1361 2017-09-12  Richard Sandiford  <richard.sandiford@linaro.org>
1363         * config/arm/arm.h (THUMB_SECONDARY_INPUT_RELOAD_CLASS): Use
1364         hard_regno_nregs instead of HARD_REGNO_NREGS.
1365         (THUMB_SECONDARY_OUTPUT_RELOAD_CLASS): Likewise.
1366         * config/c6x/c6x.c (c6x_expand_prologue): Likewise.
1367         (c6x_expand_epilogue): Likewise.
1368         * config/frv/frv.c (frv_alloc_temp_reg): Likewise.
1369         (frv_read_iacc_argument): Likewise.
1370         * config/sh/sh.c: Include regs.h.
1371         (sh_print_operand): Use hard_regno_nregs instead of HARD_REGNO_NREGS.
1372         (regs_used): Likewise.
1373         (output_stack_adjust): Likewise.
1374         * config/xtensa/xtensa.c (xtensa_copy_incoming_a7): Likewise.
1375         * expmed.c: Include regs.h.
1376         (store_bit_field_1): Use hard_regno_nregs instead of HARD_REGNO_NREGS.
1377         * ree.c: Include regs.h.
1378         (combine_reaching_defs): Use hard_regno_nregs instead of
1379         HARD_REGNO_NREGS.
1380         (add_removable_extension): Likewise.
1382 2017-09-12  Richard Sandiford  <richard.sandiford@linaro.org>
1384         * regs.h (hard_regno_nregs): Turn into a function.
1385         (end_hard_regno): Update accordingly.
1386         * caller-save.c (setup_save_areas): Likewise.
1387         (save_call_clobbered_regs): Likewise.
1388         (replace_reg_with_saved_mem): Likewise.
1389         (insert_restore): Likewise.
1390         (insert_save): Likewise.
1391         * combine.c (can_change_dest_mode): Likewise.
1392         (move_deaths): Likewise.
1393         (distribute_notes): Likewise.
1394         * config/mips/mips.c (mips_hard_regno_call_part_clobbered): Likewise.
1395         * config/powerpcspe/powerpcspe.c (rs6000_cannot_change_mode_class)
1396         (rs6000_split_multireg_move): Likewise.
1397         (rs6000_register_move_cost): Likewise.
1398         (rs6000_memory_move_cost): Likewise.
1399         * config/rs6000/rs6000.c (rs6000_cannot_change_mode_class): Likewise.
1400         (rs6000_split_multireg_move): Likewise.
1401         (rs6000_register_move_cost): Likewise.
1402         (rs6000_memory_move_cost): Likewise.
1403         * cselib.c (cselib_reset_table): Likewise.
1404         (cselib_lookup_1): Likewise.
1405         * emit-rtl.c (set_mode_and_regno): Likewise.
1406         * function.c (aggregate_value_p): Likewise.
1407         * ira-color.c (setup_profitable_hard_regs): Likewise.
1408         (check_hard_reg_p): Likewise.
1409         (calculate_saved_nregs): Likewise.
1410         (assign_hard_reg): Likewise.
1411         (improve_allocation): Likewise.
1412         (calculate_spill_cost): Likewise.
1413         * ira-emit.c (modify_move_list): Likewise.
1414         * ira-int.h (ira_hard_reg_set_intersection_p): Likewise.
1415         (ira_hard_reg_in_set_p): Likewise.
1416         * ira.c (setup_reg_mode_hard_regset): Likewise.
1417         (clarify_prohibited_class_mode_regs): Likewise.
1418         (check_allocation): Likewise.
1419         * lra-assigns.c (find_hard_regno_for_1): Likewise.
1420         (lra_setup_reg_renumber): Likewise.
1421         (setup_try_hard_regno_pseudos): Likewise.
1422         (spill_for): Likewise.
1423         (assign_hard_regno): Likewise.
1424         (setup_live_pseudos_and_spill_after_risky_transforms): Likewise.
1425         * lra-constraints.c (in_class_p): Likewise.
1426         (lra_constraint_offset): Likewise.
1427         (simplify_operand_subreg): Likewise.
1428         (lra_constraints): Likewise.
1429         (split_reg): Likewise.
1430         (split_if_necessary): Likewise.
1431         (invariant_p): Likewise.
1432         (inherit_in_ebb): Likewise.
1433         * lra-lives.c (process_bb_lives): Likewise.
1434         * lra-remat.c (reg_overlap_for_remat_p): Likewise.
1435         (get_hard_regs): Likewise.
1436         (do_remat): Likewise.
1437         * lra-spills.c (assign_spill_hard_regs): Likewise.
1438         * mode-switching.c (create_pre_exit): Likewise.
1439         * postreload.c (reload_combine_recognize_pattern): Likewise.
1440         * recog.c (peep2_find_free_register): Likewise.
1441         * regcprop.c (kill_value_regno): Likewise.
1442         (set_value_regno): Likewise.
1443         (copy_value): Likewise.
1444         (maybe_mode_change): Likewise.
1445         (find_oldest_value_reg): Likewise.
1446         (copyprop_hardreg_forward_1): Likewise.
1447         * regrename.c (check_new_reg_p): Likewise.
1448         (regrename_do_replace): Likewise.
1449         * reload.c (push_reload): Likewise.
1450         (combine_reloads): Likewise.
1451         (find_dummy_reload): Likewise.
1452         (operands_match_p): Likewise.
1453         (find_reloads): Likewise.
1454         (find_equiv_reg): Likewise.
1455         (reload_adjust_reg_for_mode): Likewise.
1456         * reload1.c (count_pseudo): Likewise.
1457         (count_spilled_pseudo): Likewise.
1458         (find_reg): Likewise.
1459         (clear_reload_reg_in_use): Likewise.
1460         (free_for_value_p): Likewise.
1461         (allocate_reload_reg): Likewise.
1462         (choose_reload_regs): Likewise.
1463         (reload_adjust_reg_for_temp): Likewise.
1464         (emit_reload_insns): Likewise.
1465         (delete_output_reload): Likewise.
1466         * rtlanal.c (subreg_get_info): Likewise.
1467         * sched-deps.c (sched_analyze_reg): Likewise.
1468         * sel-sched.c (init_regs_for_mode): Likewise.
1469         (mark_unavailable_hard_regs): Likewise.
1470         (choose_best_reg_1): Likewise.
1471         (verify_target_availability): Likewise.
1472         * valtrack.c (dead_debug_insert_temp): Likewise.
1473         * var-tracking.c (track_loc_p): Likewise.
1474         (emit_note_insn_var_location): Likewise.
1475         * varasm.c (make_decl_rtl): Likewise.
1476         * reginfo.c (choose_hard_reg_mode): Likewise.
1477         (init_reg_modes_target): Refer directly to
1478         this_target_regs->x_hard_regno_nregs.
1480 2017-09-12  Richard Sandiford  <richard.sandiford@linaro.org>
1482         * ira-costs.c (record_operand_costs): Use in_hard_reg_set_p
1483         instead of hard_regno_nregs.
1485 2017-09-12  Richard Sandiford  <richard.sandiford@linaro.org>
1487         * config/aarch64/aarch64.c (aarch64_hard_regno_mode_ok): Use
1488         end_hard_regno instead of hard_regno_nregs.
1489         * config/s390/s390.c (s390_reg_clobbered_rtx): Likewise.
1490         * config/sparc/sparc.h (ASM_DECLARE_REGISTER_GLOBAL): Likewise.
1491         * config/visium/visium.c (visium_hard_regno_mode_ok): Likewise.
1492         * ira-color.c (improve_allocation): Likewise.
1493         * lra-assigns.c (find_hard_regno_for_1): Likewise.
1494         * lra-lives.c (mark_regno_live): Likewise.
1495         (mark_regno_dead): Likewise.
1496         * lra-remat.c (operand_to_remat): Likewise.
1497         * lra.c (collect_non_operand_hard_regs): Likewise.
1498         * postreload.c (reload_combine_note_store): Likewise.
1499         (move2add_valid_value_p): Likewise.
1500         * reload.c (regno_clobbered_p): Likewise.
1502 2017-09-12  Richard Sandiford  <richard.sandiford@linaro.org>
1504         * config/frv/frv.c (FOR_EACH_REGNO): Use END_REGNO instead of
1505         hard_regno_nregs.
1506         * config/v850/v850.c (v850_reorg): Likewise.
1507         * reload.c (refers_to_regno_for_reload_p): Likewise.
1508         (find_equiv_reg): Likewise.
1509         * reload1.c (reload_reg_reaches_end_p): Likewise.
1511 2017-09-12  Richard Sandiford  <richard.sandiford@linaro.org>
1513         * caller-save.c (add_used_regs): Use REG_NREGS instead of
1514         hard_regno_nregs.
1515         * config/aarch64/aarch64.c (aarch64_split_combinev16qi): Likewise.
1516         * config/arm/arm.c (output_move_neon): Likewise.
1517         (arm_attr_length_move_neon): Likewise.
1518         (neon_split_vcombine): Likewise.
1519         * config/c6x/c6x.c (c6x_mark_reg_read): Likewise.
1520         (c6x_mark_reg_written): Likewise.
1521         (c6x_dwarf_register_span): Likewise.
1522         * config/i386/i386.c (ix86_save_reg): Likewise.
1523         * config/ia64/ia64.c (mark_reg_gr_used_mask): Likewise.
1524         (rws_access_reg): Likewise.
1525         * config/s390/s390.c (s390_call_saved_register_used): Likewise.
1526         * mode-switching.c (create_pre_exit): Likewise.
1527         * ree.c (combine_reaching_defs): Likewise.
1528         (add_removable_extension): Likewise.
1529         * regcprop.c (find_oldest_value_reg): Likewise.
1530         (copyprop_hardreg_forward_1): Likewise.
1531         * reload.c (reload_inner_reg_of_subreg): Likewise.
1532         (push_reload): Likewise.
1533         (combine_reloads): Likewise.
1534         (find_dummy_reload): Likewise.
1535         (reload_adjust_reg_for_mode): Likewise.
1536         * reload1.c (find_reload_regs): Likewise.
1537         (forget_old_reloads_1): Likewise.
1538         (reload_reg_free_for_value_p): Likewise.
1539         (reload_adjust_reg_for_temp): Likewise.
1540         (emit_reload_insns): Likewise.
1541         (delete_output_reload): Likewise.
1542         * sel-sched.c (choose_best_reg_1): Likewise.
1543         (choose_best_pseudo_reg): Likewise.
1545 2017-09-12  Richard Sandiford  <richard.sandiford@linaro.org>
1546             Alan Hayward  <alan.hayward@arm.com>
1547             David Sherwood <david.sherwood@arm.com>
1549         * defaults.h (SLOW_UNALIGNED_ACCESS): Delete.
1550         * target.def (slow_unaligned_access): New hook.
1551         * targhooks.h (default_slow_unaligned_access): Declare.
1552         * targhooks.c (default_slow_unaligned_access): New function.
1553         * doc/tm.texi.in (SLOW_UNALIGNED_ACCESS): Replace with...
1554         (TARGET_SLOW_UNALIGNED_ACCESS): ...this.
1555         * doc/tm.texi: Regenerate.
1556         * config/alpha/alpha.h (SLOW_UNALIGNED_ACCESS): Delete.
1557         * config/arm/arm.h (SLOW_UNALIGNED_ACCESS): Delete.
1558         * config/i386/i386.h (SLOW_UNALIGNED_ACCESS): Delete commented-out
1559         definition.
1560         * config/powerpcspe/powerpcspe.h (SLOW_UNALIGNED_ACCESS): Delete.
1561         * config/powerpcspe/powerpcspe.c (TARGET_SLOW_UNALIGNED_ACCESS):
1562         Redefine.
1563         (rs6000_slow_unaligned_access): New function.
1564         (rs6000_emit_move): Use it instead of SLOW_UNALIGNED_ACCESS.
1565         (expand_block_compare): Likewise.
1566         (expand_strn_compare): Likewise.
1567         (rs6000_rtx_costs): Likewise.
1568         * config/riscv/riscv.h (SLOW_UNALIGNED_ACCESS): Delete.
1569         (riscv_slow_unaligned_access): Likewise.
1570         * config/riscv/riscv.c (riscv_slow_unaligned_access): Rename to...
1571         (riscv_slow_unaligned_access_p): ...this and make static.
1572         (riscv_option_override): Update accordingly.
1573         (riscv_slow_unaligned_access): New function.
1574         (TARGET_SLOW_UNALIGNED_ACCESS): Redefine.
1575         * config/rs6000/rs6000.h (SLOW_UNALIGNED_ACCESS): Delete.
1576         * config/rs6000/rs6000.c (TARGET_SLOW_UNALIGNED_ACCESS): Redefine.
1577         (rs6000_slow_unaligned_access): New function.
1578         (rs6000_emit_move): Use it instead of SLOW_UNALIGNED_ACCESS.
1579         (rs6000_rtx_costs): Likewise.
1580         * config/rs6000/rs6000-string.c (expand_block_compare)
1581         (expand_strn_compare): Use targetm.slow_unaligned_access instead
1582         of SLOW_UNALIGNED_ACCESS.
1583         * config/tilegx/tilegx.h (SLOW_UNALIGNED_ACCESS): Delete.
1584         * config/tilepro/tilepro.h (SLOW_UNALIGNED_ACCESS): Delete.
1585         * calls.c (expand_call): Use targetm.slow_unaligned_access instead
1586         of SLOW_UNALIGNED_ACCESS.
1587         * expmed.c (simple_mem_bitfield_p): Likewise.
1588         * expr.c (alignment_for_piecewise_move): Likewise.
1589         (emit_group_load_1): Likewise.
1590         (emit_group_store): Likewise.
1591         (copy_blkmode_from_reg): Likewise.
1592         (emit_push_insn): Likewise.
1593         (expand_assignment): Likewise.
1594         (store_field): Likewise.
1595         (expand_expr_real_1): Likewise.
1596         * gimple-fold.c (gimple_fold_builtin_memory_op): Likewise.
1597         * lra-constraints.c (simplify_operand_subreg): Likewise.
1598         * stor-layout.c (bit_field_mode_iterator::next_mode): Likewise.
1599         * gimple-ssa-store-merging.c: Likewise in block comment at start
1600         of file.
1601         * tree-ssa-strlen.c: Include target.h.
1602         (handle_builtin_memcmp): Use targetm.slow_unaligned_access instead
1603         of SLOW_UNALIGNED_ACCESS.
1604         * system.h (SLOW_UNALIGNED_ACCESS): Poison.
1606 2017-09-12  Richard Sandiford  <richard.sandiford@linaro.org>
1608         PR rtl-optimization/82185
1609         * expmed.c (emit_store_flag_int): Only test tem if it has been
1610         initialized.
1612 2017-09-12  Richard Biener  <rguenther@suse.de>
1614         PR middle-end/82149
1615         * match.pd ((FTYPE) N CMP CST): Fix typo.
1617 2017-09-12  Simon Atanasyan  <simon.atanasyan@imgtec.com>
1619         * config/mips/mips.c (mips_attribute_table): Add 'short_call'
1620         attribute.
1621         (mips_near_type_p): Add 'short_call' attribute as a synonym
1622         for 'near'.
1623         * doc/extend.texi (short_call): Document new function attribute.
1625 2017-09-12  Jakub Jelinek  <jakub@redhat.com>
1627         PR target/82112
1628         * c-common.c (sync_resolve_size): Instead of c_dialect_cxx ()
1629         assertion check that in the condition.
1630         (get_atomic_generic_size): Likewise.  Before testing if parameter
1631         has pointer type, if it has array type, call for C++
1632         default_conversion to perform array-to-pointer conversion.
1634 2017-09-12  Richard Biener  <rguenther@suse.de>
1636         * tree-vect-generic.c (expand_vector_operations_1): Do nothing
1637         for operations we cannot scalarize.
1639 2017-09-12  Aldy Hernandez  <aldyh@redhat.com>
1641         * tree-ssa-threadbackward.c (fsm_find_thread_path): Make GC
1642         vectors heap vectors.  Clean up comments.
1643         Make visited_bbs a reference.
1644         (profitable_jump_thread_path): Make GC
1645         vectors heap vectors.  Clean up comments.
1646         Misc cleanups.
1647         (convert_and_register_jump_thread_path): Make GC vectors heap
1648         vectors.
1649         (check_subpath_and_update_thread_path): Same.  Clean up comments.
1650         Make visited_bbs a reference.
1651         (handle_phi): Abstract common code to to
1652         register_jump_thread_path_if_profitable.
1653         Rename VAR_BB to DEF_BB.
1654         Update comments.
1655         Make GC vectors heap vectors.
1656         Make visited_bbs a reference.
1657         (handle_assignment): Same.
1658         (register_jump_thread_path_if_profitable): New.
1659         (fsm_find_control_statement_thread_paths): Rename VAR_BB to
1660         DEF_BB.
1661         Make GC vectors heap vectors.  Clean up comments.
1662         Make visited_bbs a reference.
1663         (find_jump_threads_backwards): Make visited_bbs live in the stack.
1664         * tree-ssa-threadupdate.c (delete_jump_thread_path): Fix typo in
1665         comment.
1667 2017-09-11  Max Filippov  <jcmvbkbc@gmail.com>
1669         PR target/82181
1670         * config/xtensa/xtensa.c (xtensa_mem_offset): Check that both
1671         words of E_DImode object are reachable by xtensa_uimm8x4 access.
1673 2017-09-11  Vidya Praveen  <vidyapraveen@arm.com>
1675         Revert r251800 and r251799.
1677 2017-09-11  Martin Jambor  <mjambor@suse.cz>
1679         PR hsa/82119
1680         * hsa-gen.c (gen_hsa_phi_from_gimple_phi): Process ADDR_EXPRs in
1681         arguments in advance.
1682         * hsa-regalloc.c (naive_process_phi): New parameter predecessors,
1683         use it to find predecessor edges.
1684         (naive_outof_ssa): Collect vector of predecessors.
1686 2017-09-08  Jason Merrill  <jason@redhat.com>
1688         PR c++/70029 - ICE with ref-qualifier and -flto
1689         * langhooks.h (struct lang_hooks_for_types): Add
1690         copy_lang_qualifiers.
1691         * attribs.c (build_type_attribute_qual_variant): Use it.
1692         * langhooks-def.h (LANG_HOOKS_COPY_LANG_QUALIFIERS): Default to
1693         NULL.
1694         (LANG_HOOKS_FOR_TYPES_INITIALIZER): Use it.
1695         * tree.c (verify_type): Re-enable TYPE_CANONICAL main variant check.
1697 2017-09-08  Eric Botcazou  <ebotcazou@adacore.com>
1699         PR target/81988
1700         * config/sparc/sparc.md (mulsi3): Rename into *mulsi3_sp32.
1701         (*mulsi3_sp64): New instruction.
1702         (mulsi3): New expander.
1704 2017-09-08  Uros Bizjak  <ubizjak@gmail.com>
1706         * config/alpha/alpha.c (alpha_print_operand) <case 'S'>: Remove.
1708 2017-09-08  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
1710         * sancov.c: Include memmodel.h.
1712 2017-09-07  Eric Botcazou  <ebotcazou@adacore.com>
1714         PR target/80897
1715         * config/sparc/sparc.c (sparc_emit_set_symbolic_const64): Deal with too
1716         large offsets.
1718 2017-09-07  Carl Love  <cel@us.ibm.com>
1720         * config/rs6000/vsx.md (define_insn "*stxvl"): Add missing argument to
1721         the sldi instruction.
1723 2017-09-07  David Edelsohn  <dje.gcc@gmail.com>
1725         * sancov.c: Include tm_p.h.
1727 2017-09-07  Jakub Jelinek  <jakub@redhat.com>
1729         PR target/81979
1730         * output.h (switch_to_other_text_partition): New declaration.
1731         * varasm.c (switch_to_other_text_partition): New function.
1732         * config/rs6000/rs6000.c (uses_TOC): Return 2 if
1733         NOTE_INSN_SWITCH_TEXT_SECTIONS is seen before finding load_toc_* insn.
1734         (rs6000_elf_declare_function_name): If uses_TOC returned 2, switch
1735         to the other text partition before emitting LCL label and switch back
1736         after emitting the word after it.
1738 2017-09-07  Richard Biener  <rguenther@suse.de>
1740         * passes.def (pass_split_crit_edges): Remove instance before PRE.
1741         * tree-ssa-pre.c (pass_pre::execute): Instead manually split
1742         critical edges here, after loop init.
1743         (pass_data_pre): Remove PROP_no_crit_edges flags.
1744         * tree-ssa-sccvn.c (vn_reference_lookup_3): Use vn_valueize
1745         for valueization of call args to avoid leaking VN_TOP.
1746         (visit_use): Assert we do not visit default defs.
1747         (init_scc_vn): Use build_decl for VN_TOP to make name nicer.
1748         Use error_mark_node to more easily detect leaking VN_TOP.
1749         All default-defs are varying, not VN_TOP.  Mark them visited.
1750         (run_scc_vn): Make code match comment.
1752 2017-09-07  Michael Meissner  <meissner@linux.vnet.ibm.com>
1754         * config/rs6000/rs6000-cpus.def (OTHER_VSX_VECTOR_MASKS): Delete
1755         OPTION_MASK_FLOAT128_KEYWORD.
1756         (POWERPC_MASKS): Likewise.
1757         * config/rs6000/rs6000-c.c (rs6000_target_modify_macros): Delete
1758         support for the -mfloat128-type option, and make -mfloat128
1759         default on PowerPC Linux systems.  Define or undefine
1760         __FLOAT128__ and  __FLOAT128_HARDWARE__ for the current options.
1761         Define __float128 to be __ieee128 if IEEE 128-bit support is
1762         enabled, or undefine it.
1763         (rs6000_cpu_cpp_builtins): Delete defining __FLOAT128__ here.
1764         Delete defining __FLOAT128_TYPE__.
1765         * config/rs6000/rs6000.opt (x_TARGET_FLOAT128_TYPE): Delete the
1766         -mfloat128-type option and make -mfloat128 default on PowerPC
1767         Linux systems.
1768         (TARGET_FLOAT128_TYPE): Likewise.
1769         (-mfloat128-type): Likewise.
1770         * config/rs6000/rs6000.c (rs6000_option_override_internal):
1771         Delete the -mfloat128-type option and make -mfloat128 default on
1772         PowerPC Linux systems.  Always use __ieee128 to be the keyword for
1773         the IEEE 128-bit type, and map __float128 to __ieee128 if IEEE
1774         128-bit floating point is enabled.  Change tests from using
1775         -mfloat128-type to -mfloat128.
1776         (rs6000_mangle_type): Use the correct mangling for the __float128
1777         type even if normal long double is restricted to 64-bits.
1778         (floatn_mode): Enable the _Float128 type by default on VSX Linux
1779         systems.
1780         * config/rs6000/rs6000.h (MASK_FLOAT128_TYPE): Delete.
1781         (MASK_FLOAT128_KEYWORD): Define new shortcut macro.
1782         (RS6000BTM_FLOAT128): Define in terms of -mfloat128, not
1783         -mfloat128-type.
1784         * doc/invoke.texi (RS/6000 and PowerPC Options): Update
1785         documentation for -mfloat128.
1787 2017-09-06  Olivier Hainque  <hainque@adacore.com>
1789         * config.gcc (powerpc-wrs-vxworksspe): Now match as vxworks*spe.
1791 2017-09-06  Wish Wu  <wishwu007@gmail.com>
1792             Jakub Jelinek  <jakub@redhat.com>
1794         * asan.c (initialize_sanitizer_builtins): Add
1795         BT_FN_VOID_UINT8_UINT8, BT_FN_VOID_UINT16_UINT16,
1796         BT_FN_VOID_UINT32_UINT32, BT_FN_VOID_UINT64_UINT64,
1797         BT_FN_VOID_FLOAT_FLOAT, BT_FN_VOID_DOUBLE_DOUBLE and
1798         BT_FN_VOID_UINT64_PTR variables.
1799         * builtin-types.def (BT_FN_VOID_UINT8_UINT8): New fn type.
1800         (BT_FN_VOID_UINT16_UINT16): Likewise.
1801         (BT_FN_VOID_UINT32_UINT32): Likewise.
1802         (BT_FN_VOID_FLOAT_FLOAT): Likewise.
1803         (BT_FN_VOID_DOUBLE_DOUBLE): Likewise.
1804         (BT_FN_VOID_UINT64_PTR): Likewise.
1805         * common.opt (flag_sanitize_coverage): New variable.
1806         (fsanitize-coverage=trace-pc): Remove.
1807         (fsanitize-coverage=): Add.
1808         * flag-types.h (enum sanitize_coverage_code): New enum.
1809         * fold-const.c (fold_range_test): Disable non-short-circuit
1810         optimization if flag_sanitize_coverage.
1811         (fold_truth_andor): Likewise.
1812         * tree-ssa-ifcombine.c (ifcombine_ifandif): Likewise.
1813         * opts.c (COVERAGE_SANITIZER_OPT): Define.
1814         (coverage_sanitizer_opts): New array.
1815         (get_closest_sanitizer_option): Add OPTS argument, handle also
1816         OPT_fsanitize_coverage_.
1817         (parse_sanitizer_options): Adjusted to also handle
1818         OPT_fsanitize_coverage_.
1819         (common_handle_option): Add OPT_fsanitize_coverage_.
1820         * sancov.c (instrument_comparison, instrument_switch): New function.
1821         (sancov_pass): Add trace-cmp support.
1822         * sanitizer.def (BUILT_IN_SANITIZER_COV_TRACE_CMP1,
1823         BUILT_IN_SANITIZER_COV_TRACE_CMP2, BUILT_IN_SANITIZER_COV_TRACE_CMP4,
1824         BUILT_IN_SANITIZER_COV_TRACE_CMP8,
1825         BUILT_IN_SANITIZER_COV_TRACE_CONST_CMP1,
1826         BUILT_IN_SANITIZER_COV_TRACE_CONST_CMP2,
1827         BUILT_IN_SANITIZER_COV_TRACE_CONST_CMP4,
1828         BUILT_IN_SANITIZER_COV_TRACE_CONST_CMP8,
1829         BUILT_IN_SANITIZER_COV_TRACE_CMPF, BUILT_IN_SANITIZER_COV_TRACE_CMPD,
1830         BUILT_IN_SANITIZER_COV_TRACE_SWITCH): New builtins.
1831         * doc/invoke.texi: Document -fsanitize-coverage=trace-cmp.
1833 2017-09-06  Richard Earnshaw  <rearnsha@arm.com>
1835         * config/arm/parsecpu.awk (fatal): Note that we've encountered an
1836         error.  Only quit immediately if parsing is complete.
1837         (BEGIN): Initialize fatal_err and parse_done.
1838         (begin fpu, end fpu): Check number of arguments.
1839         (begin arch, end arch): Likewise.
1840         (begin cpu, end cpu): Likewise.
1841         (cname, tune for, tune flags, architecture, fpu, option): Likewise.
1842         (optalias): Likewise.
1844 2017-09-06  Richard Earnshaw  <rearnsha@arm.com>
1846         * config.gcc (arm*-*-*): Don't add arm-isa.h to tm_p_file.
1847         * config/arm/arm-isa.h: Delete.  Move definitions to ...
1848         * arm-cpus.in: ... here.  Use new feature and fgroup values.
1849         * config/arm/arm.c (arm_option_override): Use lower case for feature
1850         bit names.
1851         * config/arm/arm.h (TARGET_HARD_FLOAT): Likewise.
1852         (TARGET_VFP3, TARGET_VFP5, TARGET_FMA): Likewise.
1853         * config/arm/parsecpu.awk (END): Add new command 'isa'.
1854         (isa_pfx): Delete.
1855         (print_isa_bits_for): New function.
1856         (gen_isa): New function.
1857         (gen_comm_data): Use print_isa_bits_for.
1858         (define feature): New keyword.
1859         (define fgroup): New keyword.
1860         * config/arm/t-arm (OPTIONS_H_EXTRA): Add arm-isa.h
1861         (arm-isa.h): Add rule to generate file.
1862         * common/config/arm/arm-common.c: (arm_canon_arch_option): Use lower
1863         case for feature bit names.
1865 2017-09-06  Richard Biener  <rguenther@suse.de>
1867         * tree-ssa-pre.c (NECESSARY): Remove.
1868         (create_expression_by_pieces): Do not touch pass-local flags.
1869         (insert_into_preds_of_block): Likewise.
1870         (do_pre_regular_insertion): Likewise.
1871         (eliminate_insert): Likewise.
1872         (eliminate_dom_walker::before_dom_children): Likewise.
1873         (fini_eliminate): Do not look at inserted_exprs.
1874         (mark_operand_necessary): Remove.
1875         (remove_dead_inserted_code): Replace with simple work-list
1876         algorithm based on inserted_exprs and SSA uses.
1877         (pass_pre::execute): Re-order fini_eliminate and
1878         remove_dead_inserted_code.
1880 2017-09-06  Olivier Hainque  <hainque@adacore.com>
1882         * config/powerpcspe/vxworks.h (VXCPU_FOR_8548): Correct definition
1883         for VxWorks 7.  Adjust surrounding comments.
1885 2017-09-06  Richard Biener  <rguenther@suse.de>
1887         * gimple-ssa-strength-reduction.c
1888         (find_candidates_dom_walker::before_dom_children): Also allow
1889         pointer types.
1891 2017-09-06  Richard Biener  <rguenther@suse.de>
1893         PR tree-optimization/82108
1894         * tree-vect-stmts.c (vectorizable_load): Fix pointer adjustment
1895         for gap in the non-permutation SLP case.
1897 2017-09-06  Martin Jambor  <mjambor@suse.cz>
1899         PR tree-optimization/82078
1900         * tree-sra.c (sort_and_splice_var_accesses): Move call to
1901         add_access_to_work_queue...
1902         (build_accesses_from_assign): ...here.
1903         (propagate_all_subaccesses): Make sure racc is the group
1904         representative, if there is one.
1906 2017-09-06  Jakub Jelinek  <jakub@redhat.com>
1908         PR middle-end/82095
1909         * varasm.c (categorize_decl_for_section): Use SECCAT_TBSS for TLS vars with
1910         NULL DECL_INITIAL.
1912 2017-09-06  Richard Biener  <rguenther@suse.de>
1914         * gimple-ssa-strength-reduction.c
1915         (find_candidates_dom_walker::before_doom_children): Use a
1916         type and not a mode check.
1918 2017-09-06  Bernd Edlinger  <bernd.edlinger@hotmail.de>
1920         PR target/77308
1921         * config/arm/predicates.md (arm_general_adddi_operand): Create new
1922         non-vfp predicate.
1923         * config/arm/arm.md (*arm_adddi3, *arm_subdi3): Use new predicates.
1925 2017-09-05  Jeff Law  <law@redhat.com>
1927         PR tree-optimization/64910
1928         * tree-ssa-reassoc.c (reassociate_bb): Restrict last change to
1929         cases where we have 3 or more operands.
1931 2017-09-05  Jakub Jelinek  <jakub@redhat.com>
1933         PR middle-end/81768
1934         * omp-low.c (lower_omp_for): Recompute tree invariant if
1935         gimple_omp_for_initial/final is ADDR_EXPR.
1937         PR middle-end/81768
1938         * omp-expand.c (expand_omp_simd): Force second operands of COND_EXPR
1939         into gimple val before gimplification fo the COND_EXPR.
1941 2017-09-05  Aldy Hernandez  <aldyh@redhat.com>
1943         * tree-ssa-threadupdate.c (duplicate_thread_path): Remove unused
1944         REGION_COPY argument.
1945         (thread_through_all_blocks): Remove unused argument to
1946         duplicate_thread_path.
1948 2017-09-05  Richard Sandiford  <richard.sandiford@linaro.org>
1949             Alan Hayward  <alan.hayward@arm.com>
1950             David Sherwood  <david.sherwood@arm.com>
1952         * config/aarch64/aarch64-protos.h (aarch64_gen_adjusted_ldpstp):
1953         Take a scalar_mode rather than a machine_mode.
1954         (aarch64_operands_adjust_ok_for_ldpstp): Likewise.
1955         * config/aarch64/aarch64.c (aarch64_simd_container_mode): Likewise.
1956         (aarch64_operands_adjust_ok_for_ldpstp): Likewise.
1957         (aarch64_gen_adjusted_ldpstp): Likewise.
1958         (aarch64_expand_vector_init): Use scalar_mode instead of machine_mode.
1960 2017-09-05  Richard Sandiford  <richard.sandiford@linaro.org>
1961             Alan Hayward  <alan.hayward@arm.com>
1962             David Sherwood  <david.sherwood@arm.com>
1964         * config/aarch64/aarch64-protos.h (aarch64_is_extend_from_extract):
1965         Take a scalar_int_mode instead of a machine_mode.
1966         (aarch64_mask_and_shift_for_ubfiz_p): Likewise.
1967         (aarch64_output_scalar_simd_mov_immediate): Likewise.
1968         (aarch64_simd_scalar_immediate_valid_for_move): Likewise.
1969         (aarch64_simd_attr_length_rglist): Delete.
1970         * config/aarch64/aarch64.c (aarch64_is_extend_from_extract): Take
1971         a scalar_int_mode instead of a machine_mode.
1972         (aarch64_add_offset): Likewise.
1973         (aarch64_internal_mov_immediate): Likewise
1974         (aarch64_add_constant_internal): Likewise.
1975         (aarch64_add_constant): Likewise.
1976         (aarch64_movw_imm): Likewise.
1977         (aarch64_rtx_arith_op_extract_p): Likewise.
1978         (aarch64_mask_and_shift_for_ubfiz_p): Likewise.
1979         (aarch64_simd_scalar_immediate_valid_for_move): Likewise.
1980         Remove assert that the mode isn't a vector.
1981         (aarch64_output_scalar_simd_mov_immediate): Likewise.
1982         (aarch64_expand_mov_immediate): Update calls after above changes.
1983         (aarch64_output_casesi): Use as_a <scalar_int_mode>.
1984         (aarch64_and_bitmask_imm): Check for scalar integer modes.
1985         (aarch64_move_imm): Likewise.
1986         (aarch64_can_const_movi_rtx_p): Likewise.
1987         (aarch64_strip_extend): Likewise.
1988         (aarch64_extr_rtx_p): Likewise.
1989         (aarch64_rtx_costs): Likewise, using wode_mode as the mode of
1990         a CONST_INT when the mode parameter is VOIDmode.
1991         (aarch64_float_const_rtx_p): Use scalar_int_mode for a temporary.
1993 2017-09-05  Richard Sandiford  <richard.sandiford@linaro.org>
1995         * machmode.h (bitwise_mode_for_mode): Return opt_mode.
1996         * stor-layout.c (bitwise_mode_for_mode): Likewise.
1997         (bitwise_type_for_mode): Update accordingly.
1999 2017-09-05  Richard Sandiford  <richard.sandiford@linaro.org>
2001         * stor-layout.h (mode_for_size_tree): Return an opt_mode.
2002         * stor-layout.c (mode_for_size_tree): Likewise.
2003         (mode_for_array): Update accordingly.
2004         (layout_decl): Likewise.
2005         (compute_record_mode): Likewise.  Only set the mode once.
2007 2017-09-05  Richard Sandiford  <richard.sandiford@linaro.org>
2009         * target.def (get_mask_mode): Change return type to opt_mode.
2010         Expand commentary.
2011         * doc/tm.texi: Regenerate.
2012         * targhooks.h (default_get_mask_mode): Return an opt_mode.
2013         * targhooks.c (default_get_mask_mode): Likewise.
2014         * config/i386/i386.c (ix86_get_mask_mode): Likewise.
2015         * optabs-query.c (can_vec_mask_load_store_p): Update use of
2016         targetm.get_mask_mode.
2017         * tree.c (build_truth_vector_type): Likewise.
2019 2017-09-05  Richard Sandiford  <richard.sandiford@linaro.org>
2021         * machmode.h (mode_for_vector): Return an opt_mode.
2022         * stor-layout.c (mode_for_vector): Likewise.
2023         (mode_for_int_vector): Update accordingly.
2024         (layout_type): Likewise.
2025         * config/i386/i386.c (emit_memmov): Likewise.
2026         (ix86_expand_set_or_movmem): Likewise.
2027         (ix86_expand_vector_init): Likewise.
2028         (ix86_get_mask_mode): Likewise.
2029         * config/powerpcspe/powerpcspe.c (rs6000_expand_vec_perm_const_1):
2030         Likewise.
2031         * config/rs6000/rs6000.c (rs6000_expand_vec_perm_const_1): Likewise.
2032         * expmed.c (extract_bit_field_1): Likewise.
2033         * expr.c (expand_expr_real_2): Likewise.
2034         * optabs-query.c (can_vec_perm_p): Likewise.
2035         (can_vec_mask_load_store_p): Likewise.
2036         * optabs.c (expand_vec_perm): Likewise.
2037         * targhooks.c (default_get_mask_mode): Likewise.
2038         * tree-vect-stmts.c (vectorizable_store): Likewise.
2039         (vectorizable_load): Likewise.
2040         (get_vectype_for_scalar_type_and_size): Likewise.
2042 2017-09-05  Richard Sandiford  <richard.sandiford@linaro.org>
2044         * machmode.h (mode_for_int_vector): New function.
2045         * stor-layout.c (mode_for_int_vector): Likewise.
2046         * config/aarch64/aarch64.c (aarch64_emit_approx_sqrt): Use it.
2047         * config/powerpcspe/powerpcspe.c (rs6000_do_expand_vec_perm): Likewise.
2048         * config/rs6000/rs6000.c (rs6000_do_expand_vec_perm): Likewise.
2049         * config/s390/s390.c (s390_expand_vec_compare_cc): Likewise.
2050         (s390_expand_vcond): Likewise.
2052 2017-09-05  Richard Sandiford  <richard.sandiford@linaro.org>
2054         * machmode.h (opt_machine_mode): New type.
2055         (opt_mode<T>): Allow construction from anything that can be
2056         converted to a T.
2057         (is_a, as_a, dyn_cast): Add overloads for opt_mode.
2058         (mode_for_size): Return an opt_machine_mode.
2059         * stor-layout.c (mode_for_size): Likewise.
2060         (mode_for_size_tree): Update call accordingly.
2061         (bitwise_mode_for_mode): Likewise.
2062         (make_fract_type): Likewise.
2063         (make_accum_type): Likewise.
2064         * caller-save.c (replace_reg_with_saved_mem): Update call
2065         accordingly.
2066         * config/alpha/alpha.h (SECONDARY_MEMORY_NEEDED_MODE): Likewise.
2067         * config/i386/i386.h (SECONDARY_MEMORY_NEEDED_MODE): Likewise.
2068         * config/s390/s390.h (SECONDARY_MEMORY_NEEDED_MODE): Likewise.
2069         * config/sparc/sparc.h (SECONDARY_MEMORY_NEEDED_MODE): Likewise.
2070         * expmed.c (extract_bit_field_1): Likewise.
2071         * reload.c (get_secondary_mem): Likewise.
2072         * varasm.c (assemble_integer): Likewise.
2073         * lower-subreg.c (simplify_subreg_concatn): Likewise.  Move
2074         early-out.
2076 2017-09-05  Richard Sandiford  <richard.sandiford@linaro.org>
2078         * machmode.h (decimal_float_mode_for_size): New function.
2079         * real.h (REAL_VALUE_TO_TARGET_LONG_DOUBLE): Use float_mode_for_size.
2080         (REAL_VALUE_TO_TARGET_DOUBLE): Likewise.
2081         (REAL_VALUE_TO_TARGET_SINGLE): Likewise.
2082         (REAL_VALUE_TO_TARGET_DECIMAL128): Use decimal_float_mode_for_size.
2083         (REAL_VALUE_TO_TARGET_DECIMAL64): Likewise.
2084         (REAL_VALUE_TO_TARGET_DECIMAL32): Likewise.
2086 2017-09-05  Richard Sandiford  <richard.sandiford@linaro.org>
2088         * builtins.c (expand_builtin_powi): Use int_mode_for_size.
2089         (get_builtin_sync_mode): Likewise.
2090         (expand_ifn_atomic_compare_exchange): Likewise.
2091         (expand_builtin_atomic_clear): Likewise.
2092         (expand_builtin_atomic_test_and_set): Likewise.
2093         (fold_builtin_atomic_always_lock_free): Likewise.
2094         * calls.c (compute_argument_addresses): Likewise.
2095         (emit_library_call_value_1): Likewise.
2096         (store_one_arg): Likewise.
2097         * combine.c (combine_instructions): Likewise.
2098         * config/aarch64/aarch64.c (aarch64_function_value): Likewise.
2099         * config/arm/arm.c (arm_function_value): Likewise.
2100         (aapcs_allocate_return_reg): Likewise.
2101         * config/c6x/c6x.c (c6x_expand_movmem): Likewise.
2102         * config/i386/i386.c (construct_container): Likewise.
2103         (ix86_gimplify_va_arg): Likewise.
2104         (ix86_expand_sse_cmp): Likewise.
2105         (emit_memmov): Likewise.
2106         (emit_memset): Likewise.
2107         (expand_small_movmem_or_setmem): Likewise.
2108         (ix86_expand_pextr): Likewise.
2109         (ix86_expand_pinsr): Likewise.
2110         * config/lm32/lm32.c (lm32_block_move_inline): Likewise.
2111         * config/microblaze/microblaze.c (microblaze_block_move_straight):
2112         Likewise.
2113         * config/mips/mips.c (mips_function_value_1) Likewise.
2114         (mips_block_move_straight): Likewise.
2115         (mips_expand_ins_as_unaligned_store): Likewise.
2116         * config/powerpcspe/powerpcspe.c
2117         (rs6000_darwin64_record_arg_advance_flush): Likewise.
2118         (rs6000_darwin64_record_arg_flush): Likewise.
2119         * config/rs6000/rs6000.c
2120         (rs6000_darwin64_record_arg_advance_flush): Likewise.
2121         (rs6000_darwin64_record_arg_flush): Likewise.
2122         * config/sparc/sparc.c (sparc_function_arg_1): Likewise.
2123         (sparc_function_value_1): Likewise.
2124         * config/spu/spu.c (adjust_operand): Likewise.
2125         (spu_emit_branch_or_set): Likewise.
2126         (arith_immediate_p): Likewise.
2127         * emit-rtl.c (gen_lowpart_common): Likewise.
2128         * expr.c (expand_expr_real_1): Likewise.
2129         * function.c (assign_parm_setup_block): Likewise.
2130         * gimple-ssa-store-merging.c (encode_tree_to_bitpos): Likewise.
2131         * reload1.c (alter_reg): Likewise.
2132         * stor-layout.c (mode_for_vector): Likewise.
2133         (layout_type): Likewise.
2135 2017-09-05  Richard Sandiford  <richard.sandiford@linaro.org>
2137         * config/spu/spu.c (exp2_immediate_p): Use int_mode_for_mode.
2138         (spu_convert_move): Likewise.
2139         * lower-subreg.c (resolve_simple_move): Likewise.
2141 2017-09-05  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
2143         PR target/81833
2144         * config/rs6000/altivec.md (altivec_vsum2sws): Convert from a
2145         define_insn to a define_expand.
2146         (altivec_vsum2sws_direct): New define_insn.
2147         (altivec_vsumsws): Convert from a define_insn to a define_expand.
2149 2017-09-05  Wilco Dijkstra  <wdijkstr@arm.com>
2151         * config/arm/arm.c (arm_option_params_internal): Improve setting of
2152         max_insns_skipped.
2154 2017-09-05  H.J. Lu  <hongjiu.lu@intel.com>
2156         PR target/59501
2157         PR target/81624
2158         PR target/81769
2159         * config/i386/i386.c (ix86_finalize_stack_frame_flags): Don't
2160         realign stack if stack alignment needed is less than incoming
2161         stack boundary.
2163 2017-09-05  Marek Polacek  <polacek@redhat.com>
2165         PR sanitizer/82072
2166         * convert.c (convert_to_integer_1) <case NEGATE_EXPR>: Move the ubsan
2167         check earlier.
2169 2017-09-05  Wilco Dijkstra  <wdijkstr@arm.com>
2171         * explow.c (get_dynamic_stack_size): Improve dynamic alignment.
2173 2017-09-05  Richard Biener  <rguenther@suse.de>
2175         PR tree-optimization/82084
2176         * fold-const.c (can_native_encode_string_p): Handle wide characters.
2178 2017-09-05  Richard Biener  <rguenther@suse.de>
2180         PR tree-optimization/82102
2181         * tree-ssa-pre.c (fini_eliminate): Check if lhs is NULL.
2183 2017-09-05  Martin Liska  <mliska@suse.cz>
2185         PR tree-optimization/82032
2186         * tree-cfg.c (generate_range_test): New function.
2187         * tree-cfg.h (generate_range_test): Declared here.
2188         * tree-cfgcleanup.c (convert_single_case_switch): New function.
2189         (cleanup_control_expr_graph): Use it.
2190         * tree-switch-conversion.c (try_switch_expansion): Remove
2191         assert.
2192         (emit_case_nodes): Use generate_range_test.
2194 2017-09-04  Uros Bizjak  <ubizjak@gmail.com>
2196         PR target/82098
2197         * config/i386/i386.md (*<btsc><mode>_mask): Add
2198         TARGET_USE_BT to insn constraint.
2199         (*btr<mode>_mask): Ditto.
2201 2017-09-04  Wilco Dijkstra  <wdijkstr@arm.com>
2203         * config/arm/arm.c (arm_legitimate_index_p): Add comment.
2204         (thumb2_legitimate_index_p): Use correct range for DI/DF mode.
2206 2017-09-04  Bernd Edlinger  <bernd.edlinger@hotmail.de>
2208         PR target/77308
2209         * config/arm/arm.md (*arm_adddi3, *arm_subdi3): Split early except for
2210         TARGET_NEON and TARGET_IWMMXT.
2211         (anddi3, iordi3, xordi3, one_cmpldi2): Split while expanding except for
2212         TARGET_NEON and TARGET_IWMMXT.
2213         (*one_cmpldi2_insn): Moved the body of one_cmpldi2 here.
2215 2017-09-04  Uros Bizjak  <ubizjak@gmail.com>
2217         * config/i386/i386-protos.h (ix86_tls_address_pattern_p) New prototype.
2218         (ix86_rewrite_tls_address): Ditto.
2219         * config/i386/i386.c (ix86_tls_address_pattern_p) New function.
2220         (ix86_rewrite_tls_address_1): Ditto.
2221         (ix86_rewrite_tls_address): Ditto.
2222         * config/i386/predicates.md (tls_address_pattern): New predicate.
2223         * config/i386/i386.md (TLS address splitter): New splitter.
2225 2017-09-04  Richard Biener  <rguenther@suse.de>
2227         PR tree-optimization/82084
2228         * fold-const.h (can_native_encode_string_p): Declare.
2229         * fold-const.c (can_native_encode_string_p): Factor out from ...
2230         (native_encode_string): ... here.
2231         * tree-vect-stmts.c (vectorizable_store): Call it to avoid
2232         vectorizing stores from constants we later cannot handle.
2234 2017-09-04  Marek Polacek  <polacek@redhat.com>
2236         PR c/81783
2237         * doc/invoke.texi: Update -Wtautological-compare documentation.
2239 2017-09-04  Jeff Law  <law@redhat.com>
2241         PR tree-optimization/64910
2242         * tree-ssa-reassoc.c (reassociate_bb): For bitwise binary ops,
2243         swap the first and last operand if the last is a constant.
2245 2017-09-04  Marek Polacek  <polacek@redhat.com>
2247         PR sanitizer/82072
2248         * convert.c (do_narrow): When sanitizing signed integer overflows,
2249         bail out for signed types.
2250         (convert_to_integer_1) <case NEGATE_EXPR>: Likewise.
2252 2017-09-04  Richard Biener  <rguenther@suse.de>
2254         PR tree-optimization/82060
2255         * tree-ssa-pre.c (eliminate_dom_walker::before_dom_children):
2256         Move devirtualization after stmt folding and before EH/AB/noreturn
2257         cleanup to get the stmt refs canonicalized.  Use a bool instead
2258         of gimple_modified_p since that doesn't work for NOPs.  Schedule
2259         NOPs generated by folding for removal.
2261 2017-09-04  Richard Sandiford  <richard.sandiford@linaro.org>
2262             Alan Hayward  <alan.hayward@arm.com>
2263             David Sherwood  <david.sherwood@arm.com>
2265         * coretypes.h (pad_direction): New enum.
2266         * defaults.h (DEFAULT_FUNCTION_ARG_PADDING): Delete.
2267         (FUNCTION_ARG_PADDING): Likewise.
2268         * target.def (function_arg_padding): New hook.
2269         * targhooks.h (default_function_arg_padding): Declare.
2270         * targhooks.c (default_function_arg_padding): New function.
2271         * doc/tm.texi.in (FUNCTION_ARG_PADDING): Replace with...
2272         (TARGET_FUNCTION_ARG_PADDING): ...this.
2273         * doc/tm.texi: Regenerate.
2274         * calls.c (store_unaligned_arguments_into_pseudos): Use pad_direction
2275         instead of direction.
2276         (compute_argument_addresses): Likewise.
2277         (load_register_parameters): Likewise.
2278         (emit_library_call_value_1): Likewise.
2279         (store_one_arg): Use targetm.calls.function_arg_padding instead
2280         of FUNCTION_ARG_PADDING.
2281         (must_pass_in_stack_var_size_or_pad): Likewise.
2282         * expr.c (emit_group_load_1): Use pad_direction instead of direction.
2283         (emit_group_store): Likewise.
2284         (emit_single_push_insn_1): Use targetm.calls.function_arg_padding
2285         instead of FUNCTION_ARG_PADDING.
2286         (emit_push_insn): Likewise, and propagate enum change throughout
2287         function.
2288         * function.h (direction): Delete.
2289         (locate_and_pad_arg_data::where_pad): Use pad_direction instead
2290         of direction.
2291         * function.c (assign_parm_find_stack_rtl): Likewise.
2292         (assign_parm_setup_block_p): Likewise.
2293         (assign_parm_setup_block): Likewise.
2294         (gimplify_parameters): Likewise.
2295         (locate_and_pad_parm): Use targetm.calls.function_arg_padding
2296         instead of FUNCTION_ARG_PADDING, and propagate enum change throughout
2297         function.
2298         * config/aarch64/aarch64.h (FUNCTION_ARG_PADDING): Delete.
2299         (BLOCK_REG_PADDING): Use pad_direction instead of direction.
2300         * config/aarch64/aarch64-protos.h (aarch64_pad_arg_upward): Delete.
2301         * config/aarch64/aarch64.c (aarch64_pad_arg_upward): Replace with...
2302         (aarch64_function_arg_padding): ...this new function.
2303         (aarch64_gimplify_va_arg_expr): Use pad_direction instead of direction.
2304         (TARGET_FUNCTION_ARG_PADDING): Redefine.
2305         * config/arm/arm.h (FUNCTION_ARG_PADDING): Delete.
2306         (BLOCK_REG_PADDING): Use pad_direction instead of direction.
2307         * config/arm/arm-protos.h (arm_pad_arg_upward): Delete.
2308         * config/arm/arm.c (TARGET_FUNCTION_ARG_PADDING): Redefine.
2309         (arm_pad_arg_upward): Replace with...
2310         (arm_function_arg_padding): ...this new function.
2311         * config/c6x/c6x.h (BLOCK_REG_PADDING): Use pad_direction instead
2312         of direction.
2313         * config/ia64/hpux.h (FUNCTION_ARG_PADDING): Delete.
2314         * config/ia64/ia64-protos.h (ia64_hpux_function_arg_padding): Delete.
2315         * config/ia64/ia64.c (TARGET_FUNCTION_ARG_PADDING): Redefine.
2316         (ia64_hpux_function_arg_padding): Replace with...
2317         (ia64_function_arg_padding): ...this new function.  Use pad_direction
2318         instead of direction.  Check for TARGET_HPUX.
2319         * config/iq2000/iq2000.h (FUNCTION_ARG_PADDING): Delete.
2320         * config/iq2000/iq2000.c (TARGET_FUNCTION_ARG_PADDING): Redefine.
2321         (iq2000_function_arg_padding): New function.
2322         * config/mips/mips-protos.h (mips_pad_arg_upward): Delete.
2323         * config/mips/mips.c (mips_pad_arg_upward): Replace with...
2324         (mips_function_arg_padding): ...this new function.
2325         (mips_pad_reg_upward): Update accordingly.
2326         (TARGET_FUNCTION_ARG_PADDING): Redefine.
2327         * config/mips/mips.h (PAD_VARARGS_DOWN): Use
2328         targetm.calls.function_arg_padding.
2329         (FUNCTION_ARG_PADDING): Delete.
2330         (BLOCK_REG_PADDING): Use pad_direction instead of direction.
2331         * config/nios2/nios2.h (FUNCTION_ARG_PADDING): Delete.
2332         (PAD_VARARGS_DOWN): Use targetm.calls.function_arg_padding.
2333         * config/nios2/nios2-protos.h (nios2_function_arg_padding): Delete.
2334         (nios2_block_reg_padding): Return pad_direction instead of direction.
2335         * config/nios2/nios2.c (nios2_block_reg_padding): Return pad_direction
2336         instead of direction.
2337         (nios2_function_arg_padding): Likewise.  Make static.
2338         (TARGET_FUNCTION_ARG_PADDING): Redefine.
2339         * config/pa/pa.h (FUNCTION_ARG_PADDING): Delete.
2340         (BLOCK_REG_PADDING): Use targetm.calls.function_arg_padding.
2341         * config/pa/pa-protos.h (pa_function_arg_padding): Delete.
2342         * config/pa/pa.c (TARGET_FUNCTION_ARG_PADDING): Redefine.
2343         (pa_function_arg_padding): Make static.  Return pad_direction instead
2344         of direction.
2345         * config/powerpcspe/powerpcspe.h (FUNCTION_ARG_PADDING): Delete.
2346         (PAD_VARARGS_DOWN): Use targetm.calls.function_arg_padding.
2347         * config/powerpcspe/aix.h (BLOCK_REG_PADDING): Use pad_direction
2348         instead of direction.  Use targetm.calls.function_arg_padding.
2349         * config/powerpcspe/darwin.h (BLOCK_REG_PADDING): Likewise.
2350         * config/powerpcspe/freebsd64.h (BLOCK_REG_PADDING): Likewise.
2351         * config/powerpcspe/linux64.h (BLOCK_REG_PADDING): Likewise.
2352         * config/powerpcspe/powerpcspe-protos.h (function_arg_padding): Delete.
2353         * config/powerpcspe/powerpcspe.c (TARGET_FUNCTION_ARG_PADDING):
2354         Redefine.
2355         (function_arg_padding): Rename to...
2356         (rs6000_function_arg_padding): ...this.  Make static.  Return
2357         pad_direction instead of direction.
2358         (rs6000_return_in_msb): Use rs6000_function_arg_padding.
2359         * config/rs6000/rs6000.h (FUNCTION_ARG_PADDING): Delete.
2360         (PAD_VARARGS_DOWN): Use targetm.calls.function_arg_padding.
2361         * config/rs6000/aix.h (BLOCK_REG_PADDING): Use pad_direction
2362         instead of direction.  Use targetm.calls.function_arg_padding.
2363         * config/rs6000/darwin.h (BLOCK_REG_PADDING): Likewise.
2364         * config/rs6000/freebsd64.h (BLOCK_REG_PADDING): Likewise.
2365         * config/rs6000/linux64.h (BLOCK_REG_PADDING): Likewise.
2366         * config/rs6000/rs6000-protos.h (function_arg_padding): Delete.
2367         * config/rs6000/rs6000.c (TARGET_FUNCTION_ARG_PADDING): Redefine.
2368         (function_arg_padding): Rename to...
2369         (rs6000_function_arg_padding): ...this.  Make static.  Return
2370         pad_direction instead of direction.
2371         (rs6000_return_in_msb): Use rs6000_function_arg_padding.
2372         * config/s390/s390.h (FUNCTION_ARG_PADDING): Delete.
2373         * config/s390/s390.c (s390_function_arg_padding): New function.
2374         (TARGET_FUNCTION_ARG_PADDING): Redefine.
2375         * config/sparc/sparc.h (FUNCTION_ARG_PADDING): Delete.
2376         * config/sparc/sparc-protos.h (function_arg_padding): Delete.
2377         * config/sparc/sparc.c (TARGET_FUNCTION_ARG_PADDING): Redefine.
2378         (function_arg_padding): Rename to...
2379         (sparc_function_arg_padding): ...this.  Make static.  Return
2380         pad_direction instead of direction.
2381         * config/spu/spu.h (FUNCTION_ARG_PADDING): Delete.
2382         * config/spu/spu.c (spu_function_arg_padding): New function.
2383         (TARGET_FUNCTION_ARG_PADDING): Redefine.
2384         * system.h (FUNCTION_ARG_PADDING): Poison.
2386 2017-09-04  Richard Sandiford  <richard.sandiford@linaro.org>
2387             Alan Hayward  <alan.hayward@arm.com>
2388             David Sherwood  <david.sherwood@arm.com>
2390         * target.def (modes_tieable_p): New hook.
2391         * doc/tm.texi (MODES_TIEABLE_P): Replace with...
2392         (TARGET_MODES_TIEABLE_P): ...this.
2393         * doc/tm.texi.in: Regenerate.
2394         * hooks.h (hook_bool_mode_mode_true): Declare.
2395         * hooks.c (hook_bool_mode_mode_true): New function.
2396         * combine.c (subst): Use targetm.modes_tieable_p instead of
2397         MODES_TIEABLE_P.
2398         * dse.c (find_shift_sequence): Likewise.
2399         * expmed.c (extract_low_bits): Likewise.
2400         * lower-subreg.c: Include target.h.
2401         (find_decomposable_subregs): Use targetm.modes_tieable_p instead of
2402         MODES_TIEABLE_P.
2403         * rtlanal.c (rtx_cost): Likewise.
2404         * config/aarch64/aarch64.h (MODES_TIEABLE_P): Delete.
2405         * config/aarch64/aarch64-protos.h (aarch64_modes_tieable_p): Delete.
2406         * config/aarch64/aarch64.c (aarch64_modes_tieable_p): Make static.
2407         (TARGET_MODES_TIEABLE_P): Redefine.
2408         * config/alpha/alpha.h (MODES_TIEABLE_P): Delete.
2409         * config/alpha/alpha.c (alpha_modes_tieable_p): New function.
2410         (TARGET_MODES_TIEABLE_P): Redefine.
2411         * config/arc/arc.h (MODES_TIEABLE_P): Delete.
2412         * config/arc/arc.c (TARGET_MODES_TIEABLE_P): Redefine.
2413         (arc_modes_tieable_p): New function.
2414         * config/arm/arm.h (MODES_TIEABLE_P): Delete.
2415         * config/arm/arm-protos.h (arm_modes_tieable_p): Delete.
2416         * config/arm/arm.c (TARGET_MODES_TIEABLE_P): Redefine.
2417         (arm_modes_tieable_p): Make static.
2418         * config/avr/avr.h (MODES_TIEABLE_P): Delete.
2419         * config/bfin/bfin.h (MODES_TIEABLE_P): Delete.
2420         * config/bfin/bfin.c (bfin_modes_tieable_p): New function.
2421         (TARGET_MODES_TIEABLE_P): Redefine.
2422         * config/c6x/c6x.h (MODES_TIEABLE_P): Delete.
2423         * config/c6x/c6x.c (c6x_modes_tieable_p): New function.
2424         (TARGET_MODES_TIEABLE_P): Redefine.
2425         * config/cr16/cr16.h (MODES_TIEABLE_P): Delete.
2426         * config/cr16/cr16.c (TARGET_MODES_TIEABLE_P): Redefine.
2427         (cr16_modes_tieable_p): New function.
2428         * config/cris/cris.h (MODES_TIEABLE_P): Delete.
2429         * config/epiphany/epiphany.h (MODES_TIEABLE_P): Delete.
2430         * config/fr30/fr30.h (MODES_TIEABLE_P): Delete.
2431         (TRULY_NOOP_TRUNCATION): Update comment.
2432         * config/frv/frv.h (MODES_TIEABLE_P): Delete.
2433         (TRULY_NOOP_TRUNCATION): Update comment.
2434         * config/frv/frv.c (TARGET_MODES_TIEABLE_P): Redefine.
2435         (frv_modes_tieable_p): New function.
2436         * config/ft32/ft32.h (MODES_TIEABLE_P): Delete.
2437         * config/h8300/h8300.h (MODES_TIEABLE_P): Delete.
2438         * config/h8300/h8300.c (h8300_modes_tieable_p): New function.
2439         (TARGET_MODES_TIEABLE_P): Redefine.
2440         * config/i386/i386.h (MODES_TIEABLE_P): Delete.
2441         * config/i386/i386-protos.h (ix86_modes_tieable_p): Delete.
2442         * config/i386/i386.c (ix86_modes_tieable_p): Make static.
2443         (TARGET_MODES_TIEABLE_P): Redefine.
2444         * config/ia64/ia64.h (MODES_TIEABLE_P): Delete.
2445         * config/ia64/ia64.c (TARGET_MODES_TIEABLE_P): Redefine.
2446         (ia64_modes_tieable_p): New function.
2447         * config/iq2000/iq2000.h (MODES_TIEABLE_P): Delete.
2448         * config/iq2000/iq2000.c (TARGET_MODES_TIEABLE_P): Redefine.
2449         (iq2000_modes_tieable_p): New function.
2450         * config/lm32/lm32.h (MODES_TIEABLE_P): Delete.
2451         * config/lm32/lm32.c (TARGET_MODES_TIEABLE_P): Redefine.
2452         (lm32_modes_tieable_p): New function.
2453         * config/m32c/m32c.h (MODES_TIEABLE_P): Delete.
2454         * config/m32c/m32c-protos.h (m32c_modes_tieable_p): Delete.
2455         * config/m32c/m32c.c (m32c_modes_tieable_p): Make static.
2456         (TARGET_MODES_TIEABLE_P): Redefine.
2457         * config/m32r/m32r.h (MODES_TIEABLE_P): Delete.
2458         * config/m32r/m32r.c (TARGET_MODES_TIEABLE_P): Redefine.
2459         (m32r_modes_tieable_p): New function.
2460         * config/m68k/m68k.h (MODES_TIEABLE_P): Delete.
2461         * config/m68k/m68k.c (TARGET_MODES_TIEABLE_P): Redefine.
2462         (m68k_modes_tieable_p): New function.
2463         * config/mcore/mcore.h (MODES_TIEABLE_P): Delete.
2464         * config/mcore/mcore.c (TARGET_MODES_TIEABLE_P): Redefine.
2465         (mcore_modes_tieable_p): New function.
2466         * config/microblaze/microblaze.h (MODES_TIEABLE_P): Delete.
2467         * config/microblaze/microblaze.c (microblaze_modes_tieable_p): New
2468         function.
2469         (TARGET_MODES_TIEABLE_P): Redefine.
2470         * config/mips/mips.h (MODES_TIEABLE_P): Delete.
2471         * config/mips/mips-protos.h (mips_modes_tieable_p): Delete.
2472         * config/mips/mips.c (mips_modes_tieable_p): Make static.
2473         (TARGET_MODES_TIEABLE_P): Redefine.
2474         * config/mmix/mmix.h (MODES_TIEABLE_P): Delete.
2475         * config/mn10300/mn10300.h (MODES_TIEABLE_P): Delete.
2476         * config/mn10300/mn10300-protos.h (mn10300_modes_tieable): Delete.
2477         * config/mn10300/mn10300.c (mn10300_modes_tieable): Rename to...
2478         (mn10300_modes_tieable_p): ...this and make static.
2479         (TARGET_MODES_TIEABLE_P): Redefine.
2480         * config/moxie/moxie.h (MODES_TIEABLE_P): Delete.
2481         * config/msp430/msp430.h (MODES_TIEABLE_P): Delete.
2482         * config/msp430/msp430-protos.h (msp430_modes_tieable_p): Delete.
2483         * config/msp430/msp430.c (TARGET_MODES_TIEABLE_P): Redefine.
2484         (msp430_modes_tieable_p): Make static.
2485         * config/nds32/nds32.h (MODES_TIEABLE_P): Delete.
2486         * config/nds32/nds32.c (nds32_modes_tieable_p): New function.
2487         (TARGET_MODES_TIEABLE_P): Redefine.
2488         * config/nios2/nios2.h (MODES_TIEABLE_P): Delete.
2489         * config/nvptx/nvptx.h (MODES_TIEABLE_P): Delete.
2490         * config/nvptx/nvptx.c (nvptx_modes_tieable_p): New function.
2491         (TARGET_MODES_TIEABLE_P): Redefine.
2492         * config/pa/pa.h (MODES_TIEABLE_P): Delete.
2493         * config/pa/pa-protos.h (pa_modes_tieable_p): Delete.
2494         * config/pa/pa.c (pa_modes_tieable_p): Make static.
2495         (TARGET_MODES_TIEABLE_P): Redefine.
2496         * config/pdp11/pdp11.h (MODES_TIEABLE_P): Delete.
2497         * config/pdp11/pdp11.c (TARGET_MODES_TIEABLE_P): Redefine.
2498         (pdp11_modes_tieable_p): New function.
2499         * config/powerpcspe/powerpcspe.h (MODES_TIEABLE_P): Delete.
2500         * config/powerpcspe/powerpcspe.c (TARGET_MODES_TIEABLE_P): Redefine.
2501         (rs6000_modes_tieable_p): New function.
2502         (rs6000_debug_reg_global): Use it instead of MODES_TIEABLE_P.
2503         * config/powerpcspe/powerpcspe.md: Update comment.
2504         * config/riscv/riscv.h (MODES_TIEABLE_P): Delete.
2505         * config/riscv/riscv.c (riscv_modes_tieable_p): New function.
2506         (TARGET_MODES_TIEABLE_P): Redefine.
2507         * config/rl78/rl78.h (MODES_TIEABLE_P): Delete.
2508         * config/rl78/rl78.c (TARGET_MODES_TIEABLE_P): Redefine.
2509         (rl78_modes_tieable_p): New function.
2510         * config/rs6000/rs6000.h (MODES_TIEABLE_P): Delete.
2511         * config/rs6000/rs6000.c (TARGET_MODES_TIEABLE_P): Redefine.
2512         (rs6000_modes_tieable_p): New function.
2513         (rs6000_debug_reg_global): Use it instead of MODES_TIEABLE_P.
2514         * config/rs6000/rs6000.md: Update comment.
2515         * config/rx/rx.h (MODES_TIEABLE_P): Delete.
2516         * config/rx/rx.c (rx_modes_tieable_p): New function.
2517         (TARGET_MODES_TIEABLE_P): Redefine.
2518         * config/s390/s390.h (MODES_TIEABLE_P): Delete.
2519         * config/s390/s390.c (s390_modes_tieable_p): New function.
2520         (TARGET_MODES_TIEABLE_P): Redefine.
2521         * config/sh/sh.h (MODES_TIEABLE_P): Delete.
2522         * config/sh/sh.c (TARGET_MODES_TIEABLE_P): Redefine.
2523         (sh_modes_tieable_p): New function.
2524         * config/sparc/sparc.h (MODES_TIEABLE_P): Delete.
2525         * config/sparc/sparc-protos.h (sparc_modes_tieable_p): Delete.
2526         * config/sparc/sparc.c (TARGET_MODES_TIEABLE_P): Redefine.
2527         (sparc_modes_tieable_p): Make static.
2528         * config/spu/spu.h (MODES_TIEABLE_P): Delete.
2529         * config/spu/spu.c (spu_modes_tieable_p): New function.
2530         (TARGET_MODES_TIEABLE_P): Redefine.
2531         * config/stormy16/stormy16.h (MODES_TIEABLE_P): Delete.
2532         * config/stormy16/stormy16.c (xstormy16_modes_tieable_p): New function.
2533         (TARGET_MODES_TIEABLE_P): Redefine.
2534         * config/tilegx/tilegx.h (MODES_TIEABLE_P): Delete.
2535         * config/tilepro/tilepro.h (MODES_TIEABLE_P): Delete.
2536         * config/v850/v850.h (MODES_TIEABLE_P): Delete.
2537         * config/v850/v850.c (v850_modes_tieable_p): New function.
2538         (TARGET_MODES_TIEABLE_P): Redefine.
2539         * config/vax/vax.h (MODES_TIEABLE_P): Delete.
2540         * config/visium/visium.h (MODES_TIEABLE_P): Delete.
2541         * config/visium/visium.c (TARGET_MODES_TIEABLE_P): Redefine.
2542         (visium_modes_tieable_p): New function.
2543         * config/xtensa/xtensa.h (MODES_TIEABLE_P): Delete.
2544         * config/xtensa/xtensa.c (TARGET_MODES_TIEABLE_P): Redefine.
2545         (xtensa_modes_tieable_p): New function.
2546         * system.h (MODES_TIEABLE_P): Poison.
2548 2017-09-04  Richard Sandiford  <richard.sandiford@linaro.org>
2549             Alan Hayward  <alan.hayward@arm.com>
2550             David Sherwood  <david.sherwood@arm.com>
2552         * target.def (hard_regno_mode_ok): New hook.
2553         * doc/tm.texi (HARD_REGNO_MODE_OK): Replace with...
2554         (TARGET_HARD_REGNO_MODE_OK): ...this.
2555         * doc/tm.texi.in: Regenerate.
2556         * hooks.h (hook_bool_uint_mode_true): Declare.
2557         * hooks.c (hook_bool_uint_mode_true): New function.
2558         * doc/md.texi: Refer to targetm.hard_regno_mode_ok instead of
2559         HARD_REGNO_MODE_OK.
2560         * genpreds.c (write_insn_preds_c): Add an include of target.h.
2561         * alias.c (init_alias_target): Use targetm.hard_regno_mode_ok
2562         instead of HARD_REGNO_MODE_OK.
2563         * caller-save.c: Include target.h.
2564         (reg_save_code): Use targetm.hard_regno_mode_ok instead of
2565         HARD_REGNO_MODE_OK.
2566         * combine.c (can_combine_p): Likewise.
2567         (combinable_i3pat): Likewise.
2568         (can_change_dest_mode): Likewise.
2569         * expr.c (init_expr_target): Likewise.
2570         (convert_move): Likewise.
2571         (convert_modes): Likewise.
2572         * ira.c (setup_prohibited_class_mode_regs): Likewise.
2573         (setup_prohibited_mode_move_regs): Likewise.
2574         * ira.h (target_ira): Likewise.
2575         * lra-assigns.c (find_hard_regno_for_1): Likewise.
2576         * lra-constraints.c (process_alt_operands): Likewise.
2577         (split_reg): Likewise.
2578         * recog.c (peep2_find_free_register): Likewise.
2579         * ree.c (combine_reaching_defs): Likewise.
2580         * regcprop.c (maybe_mode_change): Likewise.
2581         * reginfo.c (init_reg_sets_1): Likewise.
2582         (choose_hard_reg_mode): Likewise.
2583         (simplifiable_subregs): Likewise.
2584         * regrename.c (check_new_reg_p): Likewise.
2585         * reload.c (find_valid_class): Likewise.
2586         (find_valid_class_1): Likewise.
2587         (reload_inner_reg_of_subreg): Likewise.
2588         (push_reload): Likewise.
2589         (combine_reloads): Likewise.
2590         (find_dummy_reload): Likewise.
2591         (find_reloads): Likewise.
2592         * reload1.c (find_reg): Likewise.
2593         (set_reload_reg): Likewise.
2594         (allocate_reload_reg): Likewise.
2595         (choose_reload_regs): Likewise.
2596         (reload_adjust_reg_for_temp): Likewise.
2597         * rtlanal.c (subreg_size_offset_from_lsb): Likewise.
2598         (simplify_subreg_regno): Likewise.
2599         * sel-sched.c (init_regs_for_mode): Likewise.
2600         * varasm.c (make_decl_rtl): Likewise.
2601         * config/aarch64/aarch64.h (HARD_REGNO_MODE_OK): Delete.
2602         (MODES_TIEABLE_P): Use targetm.hard_regno_mode_ok instead of
2603         HARD_REGNO_MODE_OK.
2604         * config/aarch64/aarch64-protos.h (aarch64_hard_regno_mode_ok): Delete.
2605         * config/aarch64/aarch64.c (aarch64_hard_regno_mode_ok): Make static.
2606         (TARGET_HARD_REGNO_MODE_OK): Redefine.
2607         * config/alpha/alpha.h (HARD_REGNO_MODE_OK): Delete.
2608         * config/alpha/alpha.c (alpha_hard_regno_mode_ok): New function.
2609         (TARGET_HARD_REGNO_MODE_OK): Redefine.
2610         * config/arc/arc.h (arc_hard_regno_mode_ok): Delete.
2611         (arc_mode_class): Delete.
2612         (HARD_REGNO_MODE_OK): Delete.
2613         * config/arc/arc.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
2614         (arc_hard_regno_mode_ok): Rename old array to...
2615         (arc_hard_regno_mode_ok_modes): ...this.
2616         (arc_conditional_register_usage): Update accordingly.
2617         (arc_mode_class): Make static.
2618         (arc_hard_regno_mode_ok): New function.
2619         * config/arm/arm.h (HARD_REGNO_MODE_OK): Delete.
2620         * config/arm/arm-protos.h (arm_hard_regno_mode_ok): Delete.
2621         * config/arm/arm.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
2622         (arm_hard_regno_mode_ok): Make static.
2623         * config/arm/arm.md (movdi): Use targetm.hard_regno_mode_ok instead of
2624         HARD_REGNO_MODE_OK.
2625         * config/avr/avr-protos.h (avr_hard_regno_mode_ok): Delete.
2626         * config/avr/avr.h (HARD_REGNO_MODE_OK): Delete.
2627         * config/avr/avr.c (avr_hard_regno_mode_ok): Make static and
2628         return a bool.
2629         (TARGET_HARD_REGNO_MODE_OK): Redefine.
2630         * config/bfin/bfin-protos.h (hard_regno_mode_ok): Delete.
2631         * config/bfin/bfin.h (HARD_REGNO_MODE_OK): Delete.
2632         * config/bfin/bfin.c (hard_regno_mode_ok): Rename to...
2633         (bfin_hard_regno_mode_ok): ...this.  Make static and return a bool.
2634         (TARGET_HARD_REGNO_MODE_OK): Redefine.
2635         * config/bfin/predicates.md (valid_reg_operand): Use
2636         targetm.hard_regno_mode_ok instead of HARD_REGNO_MODE_OK.
2637         * config/c6x/c6x.h (HARD_REGNO_MODE_OK): Delete.
2638         * config/c6x/c6x.c (c6x_hard_regno_mode_ok): New function.
2639         (TARGET_HARD_REGNO_MODE_OK): Redefine.
2640         * config/cr16/cr16.h (HARD_REGNO_MODE_OK): Delete.
2641         * config/cr16/cr16-protos.h (cr16_hard_regno_mode_ok): Delete.
2642         * config/cr16/cr16.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
2643         (cr16_hard_regno_mode_ok): Make static and return a bool.
2644         * config/cris/cris.h (HARD_REGNO_MODE_OK): Delete.
2645         * config/cris/cris.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
2646         (cris_hard_regno_mode_ok): New function.
2647         * config/epiphany/epiphany.h (epiphany_hard_regno_mode_ok): Delete.
2648         (epiphany_mode_class): Delete.
2649         (HARD_REGNO_MODE_OK): Delete.
2650         * config/epiphany/epiphany-protos.h (hard_regno_mode_ok): Delete.
2651         * config/epiphany/epiphany.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
2652         (hard_regno_mode_ok): Rename to...
2653         (epiphany_hard_regno_mode_ok): ...this.  Make static and return a bool.
2654         * config/fr30/fr30.h (HARD_REGNO_MODE_OK): Delete.
2655         * config/fr30/fr30.md: Refer to targetm.hard_regno_mode_ok instead of
2656         HARD_REGNO_MODE_OK.
2657         * config/frv/frv.h (HARD_REGNO_MODE_OK): Delete.
2658         * config/frv/frv-protos.h (frv_hard_regno_mode_ok): Delete.
2659         * config/frv/frv.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
2660         (frv_hard_regno_mode_ok): Make static and return a bool.
2661         * config/frv/frv.md: Refer to targetm.hard_regno_mode_ok instead of
2662         HARD_REGNO_MODE_OK.
2663         * config/ft32/ft32.h (HARD_REGNO_MODE_OK): Delete.
2664         * config/h8300/h8300.h (HARD_REGNO_MODE_OK): Delete.
2665         * config/h8300/h8300-protos.h (h8300_hard_regno_mode_ok): Delete.
2666         * config/h8300/h8300.c (h8300_hard_regno_mode_ok): Make static
2667         and return a bool.
2668         (TARGET_HARD_REGNO_MODE_OK): Redefine.
2669         * config/i386/i386.h (HARD_REGNO_MODE_OK): Delete.
2670         * config/i386/i386-protos.h (ix86_hard_regno_mode_ok): Delete.
2671         * config/i386/i386.c (ix86_hard_regno_mode_ok): Make static and
2672         return a bool.
2673         (TARGET_HARD_REGNO_MODE_OK): Redefine.
2674         * config/ia64/ia64.h (HARD_REGNO_MODE_OK): Delete.
2675         * config/ia64/ia64.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
2676         (ia64_hard_regno_mode_ok): New function.
2677         * config/iq2000/iq2000.h (HARD_REGNO_MODE_OK): Delete.
2678         * config/iq2000/iq2000.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
2679         (iq2000_hard_regno_mode_ok): New function.
2680         * config/lm32/lm32.h (HARD_REGNO_MODE_OK): Delete.
2681         * config/lm32/lm32.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
2682         (lm32_hard_regno_mode_ok): New function.
2683         * config/m32c/m32c.h (HARD_REGNO_MODE_OK): Delete.
2684         * config/m32c/m32c-protos.h (m32c_hard_regno_ok): Delete.
2685         * config/m32c/m32c.c (class_can_hold_mode): Use m32c_hard_regno_mode_ok
2686         instead of HARD_REGNO_MODE_OK.
2687         (m32c_hard_regno_ok): Rename to...
2688         (m32c_hard_regno_mode_ok): ...this.  Make static and return a bool.
2689         (m32c_cannot_change_mode_class): Update accordingly.
2690         (TARGET_HARD_REGNO_MODE_OK): Redefine.
2691         * config/m32r/m32r.h (m32r_hard_regno_mode_ok): Delete.
2692         (m32r_mode_class): Delete.
2693         (HARD_REGNO_MODE_OK): Delete.
2694         * config/m32r/m32r.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
2695         (m32r_hard_regno_mode_ok): Rename to...
2696         (m32r_hard_regno_modes): ...this.
2697         (m32r_mode_class): Make static.
2698         (m32r_hard_regno_mode_ok): New function.
2699         * config/m68k/m68k.h (HARD_REGNO_MODE_OK): Delete.
2700         * config/m68k/m68k-protos.h (m68k_regno_mode_ok): Delete.
2701         * config/m68k/m68k.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
2702         (m68k_hard_regno_mode_ok): Make static.
2703         * config/mcore/mcore.h (HARD_REGNO_MODE_OK): Delete.
2704         * config/mcore/mcore.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
2705         (mcore_hard_regno_mode_ok): New function.
2706         * config/microblaze/microblaze.h (microblaze_hard_regno_mode_ok)
2707         (HARD_REGNO_MODE_OK): Delete.
2708         * config/microblaze/microblaze.c (microblaze_hard_regno_mode_ok):
2709         Rename to...
2710         (microblaze_hard_regno_mode_ok_p): ...this and make static.
2711         (microblaze_hard_regno_mode_ok): New function.
2712         (TARGET_HARD_REGNO_MODE_OK): Redefine.
2713         * config/mips/mips.h (HARD_REGNO_MODE_OK): Delete.
2714         (mips_hard_regno_mode_ok): Delete.
2715         * config/mips/mips.c (mips_hard_regno_mode_ok): Rename to...
2716         (mips_hard_regno_mode_ok_p): ...this and make static.
2717         (mips_hard_regno_mode_ok_p): Rename to...
2718         (mips_hard_regno_mode_ok_uncached): ...this.
2719         (mips_hard_regno_mode_ok): New function.
2720         (mips_class_max_nregs): Use mips_hard_regno_mode_ok instead
2721         of HARD_REGNO_MODE_OK.
2722         (mips_option_override): Update after above name changes.
2723         (TARGET_HARD_REGNO_MODE_OK): Redefine.
2724         * config/mmix/mmix.h (HARD_REGNO_MODE_OK): Delete.
2725         * config/mn10300/mn10300.h (HARD_REGNO_MODE_OK): Delete.
2726         * config/mn10300/mn10300-protos.h (mn10300_hard_regno_mode_ok): Delete.
2727         * config/mn10300/mn10300.c (mn10300_hard_regno_mode_ok): Make static.
2728         (TARGET_HARD_REGNO_MODE_OK): Redefine.
2729         * config/moxie/moxie.h (HARD_REGNO_MODE_OK): Delete.
2730         * config/msp430/msp430.h (HARD_REGNO_MODE_OK): Delete.
2731         * config/msp430/msp430-protos.h (msp430_hard_regno_mode_ok): Delete.
2732         * config/msp430/msp430.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
2733         (msp430_hard_regno_mode_ok): Make static and return a bool.
2734         * config/nds32/nds32.h (HARD_REGNO_MODE_OK): Delete.
2735         * config/nds32/nds32-protos.h (nds32_hard_regno_mode_ok): Delete.
2736         * config/nds32/nds32.c (nds32_hard_regno_mode_ok): Make static
2737         and return a bool.
2738         (TARGET_HARD_REGNO_MODE_OK): Redefine.
2739         * config/nios2/nios2.h (HARD_REGNO_MODE_OK): Delete.
2740         * config/nvptx/nvptx.h (HARD_REGNO_MODE_OK): Delete.
2741         * config/pa/pa.h (MODES_TIEABLE_P): Update commentary.
2742         * config/pa/pa32-regs.h (HARD_REGNO_MODE_OK): Rename to...
2743         (PA_HARD_REGNO_MODE_OK): ...this
2744         * config/pa/pa64-regs.h (HARD_REGNO_MODE_OK): Rename to...
2745         (PA_HARD_REGNO_MODE_OK): ...this.
2746         * config/pa/pa.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
2747         (pa_hard_regno_mode_ok): New function.
2748         * config/pdp11/pdp11.h (HARD_REGNO_MODE_OK): Delete.
2749         * config/pdp11/pdp11.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
2750         (pdp11_hard_regno_mode_ok): New function.
2751         * config/powerpcspe/powerpcspe.h (HARD_REGNO_MODE_OK): Delete.
2752         * config/powerpcspe/powerpcspe-protos.h (rs6000_hard_regno_mode_ok_p):
2753         Delete.
2754         * config/powerpcspe/powerpcspe.c (rs6000_hard_regno_mode_ok_p):
2755         Make static.
2756         (TARGET_HARD_REGNO_MODE_OK): Redefine.
2757         (rs6000_hard_regno_mode_ok): Rename to...
2758         (rs6000_hard_regno_mode_ok_uncached): ...this.
2759         (rs6000_init_hard_regno_mode_ok): Update accordingly.
2760         (rs6000_hard_regno_mode_ok): New function.
2761         * config/riscv/riscv.h (HARD_REGNO_MODE_OK): Delete.
2762         * config/riscv/riscv-protos.h (riscv_hard_regno_mode_ok_p): Delete.
2763         * config/riscv/riscv.c (riscv_hard_regno_mode_ok_p): Rename to...
2764         (riscv_hard_regno_mode_ok): ...this and make static.
2765         (TARGET_HARD_REGNO_MODE_OK): Redefine.
2766         * config/rl78/rl78.h (HARD_REGNO_MODE_OK): Delete.
2767         * config/rl78/rl78-protos.h (rl78_hard_regno_mode_ok): Delete.
2768         * config/rl78/rl78.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
2769         (rl78_hard_regno_mode_ok): Make static and return bool.
2770         * config/rs6000/rs6000.h (HARD_REGNO_MODE_OK): Delete.
2771         * config/rs6000/rs6000-protos.h (rs6000_hard_regno_mode_ok_p):
2772         Delete.
2773         * config/rs6000/rs6000.c (rs6000_hard_regno_mode_ok_p): Make static.
2774         (TARGET_HARD_REGNO_MODE_OK): Redefine.
2775         (rs6000_hard_regno_mode_ok): Rename to...
2776         (rs6000_hard_regno_mode_ok_uncached): ...this.
2777         (rs6000_init_hard_regno_mode_ok): Update accordingly.
2778         (rs6000_hard_regno_mode_ok): New function.
2779         * config/rx/rx.h (HARD_REGNO_MODE_OK): Delete.
2780         * config/rx/rx.c (rx_hard_regno_mode_ok): New function.
2781         (TARGET_HARD_REGNO_MODE_OK): Redefine.
2782         * config/s390/s390.h (HARD_REGNO_MODE_OK): Delete.
2783         * config/s390/s390-protos.h (s390_hard_regno_mode_ok): Delete.
2784         * config/s390/s390.c (s390_hard_regno_mode_ok): Make static.
2785         (TARGET_HARD_REGNO_MODE_OK): Redefine.
2786         * config/sh/sh.h (HARD_REGNO_MODE_OK): Delete.
2787         * config/sh/sh-protos.h (sh_hard_regno_mode_ok): Delete.
2788         * config/sh/sh.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
2789         (sh_hard_regno_mode_ok): Make static.
2790         * config/sparc/constraints.md: Refer to targetm.hard_regno_mode_ok
2791         instead of HARD_REGNO_MODE_OK.
2792         * config/sparc/sparc.h (hard_regno_mode_classes): Delete.
2793         (sparc_mode_class): Delete.
2794         (HARD_REGNO_MODE_OK): Delete.
2795         * config/sparc/sparc.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
2796         (hard_regno_mode_classes): Make static.
2797         (sparc_mode_class): Likewise.
2798         (sparc_hard_regno_mode_ok): New function.
2799         * config/spu/spu.h (HARD_REGNO_MODE_OK): Delete.
2800         * config/stormy16/stormy16.h (HARD_REGNO_MODE_OK): Delete.
2801         * config/stormy16/stormy16.c (xstormy16_hard_regno_mode_ok): New
2802         function.
2803         (TARGET_HARD_REGNO_MODE_OK): Redefine.
2804         * config/tilegx/tilegx.h (HARD_REGNO_MODE_OK): Delete.
2805         * config/tilepro/tilepro.h (HARD_REGNO_MODE_OK): Delete.
2806         * config/v850/v850.h (HARD_REGNO_MODE_OK): Delete.
2807         * config/v850/v850.c (v850_hard_regno_mode_ok): New function.
2808         (TARGET_HARD_REGNO_MODE_OK): Redefine.
2809         * config/vax/vax.h (HARD_REGNO_MODE_OK): Delete.
2810         * config/visium/visium.h (HARD_REGNO_MODE_OK): Delete.
2811         * config/visium/visium.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
2812         (visium_hard_regno_mode_ok): New function.
2813         * config/visium/visium.md: Refer to targetm.hard_regno_mode_ok
2814         instead of HARD_REGNO_MODE_OK.
2815         * config/xtensa/xtensa.h (xtensa_hard_regno_mode_ok): Delete.
2816         (HARD_REGNO_MODE_OK): Delete.
2817         * config/xtensa/xtensa.c (xtensa_hard_regno_mode_ok): Rename to...
2818         (xtensa_hard_regno_mode_ok_p): ...this and make static.
2819         (xtensa_option_override): Update accordingly.
2820         (TARGET_HARD_REGNO_MODE_OK): Redefine.
2821         (xtensa_hard_regno_mode_ok): New function.
2822         * system.h (HARD_REGNO_MODE_OK): Poison.
2824 2017-09-04  Richard Sandiford  <richard.sandiford@linaro.org>
2825             Alan Hayward  <alan.hayward@arm.com>
2826             David Sherwood  <david.sherwood@arm.com>
2828         * target.def (hard_regno_call_part_clobbered): New hook.
2829         * doc/tm.texi.in (HARD_REGNO_CALL_PART_CLOBBERED): Replace with...
2830         (TARGET_HARD_REGNO_CALL_PART_CLOBBERED): ...this hook.
2831         * doc/tm.texi: Regenerate.
2832         * hooks.h (hook_bool_uint_mode_false): Declare.
2833         * hooks.c (hook_bool_uint_mode_false): New function.
2834         * regs.h (HARD_REGNO_CALL_PART_CLOBBERED): Delete.
2835         * cselib.c (cselib_process_insn): Use
2836         targetm.hard_regno_call_part_clobbered instead of
2837         HARD_REGNO_CALL_PART_CLOBBERED.
2838         * ira-conflicts.c (ira_build_conflicts): Likewise.
2839         * ira-costs.c (ira_tune_allocno_costs): Likewise.
2840         * lra-constraints.c (need_for_call_save_p): Likewise.
2841         * lra-lives.c: Include target.h.
2842         (check_pseudos_live_through_calls): Use
2843         targetm.hard_regno_call_part_clobbered instead of
2844         HARD_REGNO_CALL_PART_CLOBBERED.
2845         * regcprop.c: Include target.h.
2846         (copyprop_hardreg_forward_1): Use
2847         targetm.hard_regno_call_part_clobbered instead of
2848         HARD_REGNO_CALL_PART_CLOBBERED.
2849         * reginfo.c (choose_hard_reg_mode): Likewise.
2850         * regrename.c (check_new_reg_p): Likewise.
2851         * reload.c (find_equiv_reg): Likewise.
2852         * reload1.c (emit_reload_insns): Likewise.
2853         * sched-deps.c (deps_analyze_insn): Likewise.
2854         * sel-sched.c (init_regs_for_mode): Likewise.
2855         (mark_unavailable_hard_regs): Likewise.
2856         * targhooks.c (default_dwarf_frame_reg_mode): Likewise.
2857         * config/aarch64/aarch64.h (HARD_REGNO_CALL_PART_CLOBBERED): Delete.
2858         * config/aarch64/aarch64.c (aarch64_hard_regno_call_part_clobbered):
2859         New function.
2860         (TARGET_HARD_REGNO_CALL_PART_CLOBBERED): Redefine.
2861         * config/avr/avr.h (HARD_REGNO_CALL_PART_CLOBBERED): Delete.
2862         * config/avr/avr-protos.h (avr_hard_regno_call_part_clobbered):
2863         Delete.
2864         * config/avr/avr.c (avr_hard_regno_call_part_clobbered): Make static
2865         and return a bool.
2866         (TARGET_HARD_REGNO_CALL_PART_CLOBBERED): Redefine.
2867         * config/i386/i386.h (HARD_REGNO_CALL_PART_CLOBBERED): Delete.
2868         * config/i386/i386.c (ix86_hard_regno_call_part_clobbered): New
2869         function.
2870         (TARGET_HARD_REGNO_CALL_PART_CLOBBERED): Redefine.
2871         * config/mips/mips.h (HARD_REGNO_CALL_PART_CLOBBERED): Delete.
2872         * config/mips/mips.c (mips_hard_regno_call_part_clobbered): New
2873         function.
2874         (TARGET_HARD_REGNO_CALL_PART_CLOBBERED): Redefine.
2875         * config/powerpcspe/powerpcspe.h (HARD_REGNO_CALL_PART_CLOBBERED):
2876         Delete.
2877         * config/powerpcspe/powerpcspe.c
2878         (rs6000_hard_regno_call_part_clobbered): New function.
2879         (TARGET_HARD_REGNO_CALL_PART_CLOBBERED): Redefine.
2880         * config/rs6000/rs6000.h (HARD_REGNO_CALL_PART_CLOBBERED): Delete.
2881         * config/rs6000/rs6000.c (rs6000_hard_regno_call_part_clobbered):
2882         New function.
2883         (TARGET_HARD_REGNO_CALL_PART_CLOBBERED): Redefine.
2884         * config/s390/s390.h (HARD_REGNO_CALL_PART_CLOBBERED): Delete.
2885         * config/s390/s390.c (s390_hard_regno_call_part_clobbered): New
2886         function.
2887         (TARGET_HARD_REGNO_CALL_PART_CLOBBERED): Redefine.
2888         * config/sh/sh.h (HARD_REGNO_CALL_PART_CLOBBERED): Delete.
2889         * system.h (HARD_REGNO_CALL_PART_CLOBBERED): Poison.
2891 2017-09-04  Richard Sandiford  <richard.sandiford@linaro.org>
2892             Alan Hayward  <alan.hayward@arm.com>
2893             David Sherwood  <david.sherwood@arm.com>
2895         * rtl.h (subreg_memory_offset): Declare.
2896         * emit-rtl.c (subreg_memory_offset): New function.
2897         * expmed.c (store_bit_field_1): Use it.
2898         * expr.c (undefined_operand_subword_p): Likewise.
2899         * simplify-rtx.c (simplify_subreg): Likewise.
2901 2017-09-04  Alexander Monakov  <amonakov@ispras.ru>
2903         PR rtl-optimization/57448
2904         PR target/67458
2905         PR target/81316
2906         * optabs.c (expand_atomic_load): Place compiler memory barriers if
2907         using atomic_load pattern.
2908         (expand_atomic_store): Likewise.
2910 2017-09-04  Jakub Jelinek  <jakub@redhat.com>
2912         PR sanitizer/81981
2913         * gimple-fold.c (gimple_fold_call): Optimize away useless UBSAN_PTR
2914         and UBSAN_BOUNDS internal calls.  Clean up IFN_UBSAN_OBJECT_SIZE
2915         handling.  Use replace_call_with_value with NULL instead of
2916         gsi_replace, unlink_stmt_vdef and release_defs.
2918         * gdbhooks.py (OptMachineModePrinter.to_string): Use 8 spaces
2919         instead of tab.
2921         * lra-remat.c (reg_overlap_for_remat_p): Fix a pasto.
2923 2017-09-04  Richard Sandiford  <richard.sandiford@linaro.org>
2925         PR bootstrap/82045
2926         * rtl.h (emit_library_call_value_1): Declare.
2927         (emit_library_call): Replace declaration with a series of overloads.
2928         Remove the parameter count argument.
2929         (emit_library_call_value): Likewise.
2930         * calls.c (emit_library_call_value_1): Make global.  Replace varargs
2931         with an "rtx_mode_t *".
2932         (emit_library_call_value): Delete.
2933         (emit_library_call): Likewise.
2934         * asan.c (asan_emit_stack_protection): Update calls accordingly.
2935         (asan_emit_allocas_unpoison): Likewise.
2936         * builtins.c (expand_builtin_powi): Likewise.
2937         (expand_asan_emit_allocas_unpoison): Likewise.
2938         * cfgexpand.c (expand_main_function): Likewise.
2939         * config/aarch64/aarch64.c (aarch64_trampoline_init): Likewise.
2940         * config/aarch64/aarch64.h (PROFILE_HOOK): Likewise.
2941         * config/alpha/alpha.c (alpha_trampoline_init): Likewise.
2942         * config/arm/arm.c (arm_trampoline_init): Likewise.
2943         (arm_call_tls_get_addr): Likewise.
2944         (arm_expand_divmod_libfunc): Likewise.
2945         * config/bfin/bfin.md (umulsi3_highpart): Likewise.
2946         (smulsi3_highpart): Likewise.
2947         * config/c6x/c6x.c (c6x_initialize_trampoline): Likewise.
2948         (c6x_expand_compare): Likewise.
2949         (c6x_expand_movmem): Likewise.
2950         * config/frv/frv.c (frv_trampoline_init): Likewise.
2951         * config/i386/i386.c (ix86_trampoline_init): Likewise.
2952         (ix86_expand_divmod_libfunc): Likewise.
2953         * config/ia64/ia64.c (ia64_expand_tls_address): Likewise.
2954         (ia64_expand_compare): Likewise.
2955         (ia64_profile_hook): Likewise.
2956         * config/ia64/ia64.md (save_stack_nonlocal): Likewise.
2957         (nonlocal_goto): Likewise.
2958         (restore_stack_nonlocal): Likewise.
2959         * config/m32r/m32r.c (block_move_call): Likewise.
2960         (m32r_trampoline_init): Likewise.
2961         * config/m68k/linux.h (FINALIZE_TRAMPOLINE): Likewise.
2962         * config/m68k/m68k.c (m68k_call_tls_get_addr): Likewise.
2963         (m68k_call_m68k_read_tp): Likewise.
2964         * config/microblaze/microblaze.c (microblaze_call_tls_get_addr)
2965         (microblaze_expand_divide): Likewise.
2966         * config/mips/mips.h (mips_args): Likewise.
2967         * config/mips/sdemtk.h (mips_sync_icache): Likewise.
2968         (MIPS_ICACHE_SYNC): Likewise.
2969         * config/nios2/nios2.c (nios2_emit_expensive_div): Likewise.
2970         (nios2_trampoline_init): Likewise.
2971         * config/pa/pa.c (hppa_tls_call): Likewise.
2972         (pa_trampoline_init): Likewise.
2973         * config/pa/pa.md (canonicalize_funcptr_for_compare): Likewise.
2974         * config/powerpcspe/powerpcspe.c (rs6000_legitimize_tls_address)
2975         (expand_strn_compare): Likewise.
2976         (rs6000_generate_compare): Likewise.
2977         (rs6000_expand_float128_convert): Likewise.
2978         (output_profile_hook): Likewise.
2979         (rs6000_trampoline_init): Likewise.
2980         * config/powerpcspe/powerpcspe.md (neg<mode>2): Likewise.
2981         * config/riscv/riscv.h (PROFILE_HOOK): Likewise.
2982         * config/rs6000/rs6000-string.c (expand_strn_compare): Likewise.
2983         * config/rs6000/rs6000.c (rs6000_legitimize_tls_address): Likewise.
2984         (rs6000_generate_compare): Likewise.
2985         (rs6000_expand_float128_convert): Likewise.
2986         (output_profile_hook): Likewise.
2987         (rs6000_trampoline_init): Likewise.
2988         * config/rs6000/rs6000.md (neg<mode>2): Likewise.
2989         * config/sh/sh.c (sh_trampoline_init): Likewise.
2990         * config/sparc/sparc.c (emit_soft_tfmode_libcall): Likewise.
2991         (sparc_emit_float_lib_cmp): Likewise.
2992         (sparc32_initialize_trampoline): Likewise.
2993         (sparc64_initialize_trampoline): Likewise.
2994         (sparc_profile_hook): Likewise.
2995         * config/spu/spu.c (ea_load_store): Likewise.
2996         * config/spu/spu.md (floatunssidf2): Likewise.
2997         * config/tilegx/tilegx.c (tilegx_trampoline_init): Likewise.
2998         * config/tilepro/tilepro.c (tilepro_trampoline_init): Likewise.
2999         * config/visium/visium.c (expand_block_move_4): Likewise.
3000         (expand_block_move_2): Likewise.
3001         (expand_block_move_1): Likewise.
3002         (expand_block_set_4): Likewise.
3003         (expand_block_set_2): Likewise.
3004         (expand_block_set_1): Likewise.
3005         (visium_trampoline_init): Likewise.
3006         (visium_profile_hook): Likewise.
3007         * config/xtensa/xtensa.c (xtensa_expand_nonlocal_goto): Likewise.
3008         (xtensa_setup_frame_addresses): Likewise.
3009         (xtensa_trampoline_init): Likewise.
3010         * except.c (sjlj_emit_function_enter): Likewise.
3011         (sjlj_emit_function_exit): Likewise.
3012         * explow.c (allocate_dynamic_stack_space): Likewise.
3013         (probe_stack_range): Likewise.
3014         * expr.c (convert_mode_scalar): Likewise.
3015         * optabs.c (expand_binop): Likewise.
3016         (expand_twoval_binop_libfunc): Likewise.
3017         (expand_unop): Likewise.
3018         (prepare_cmp_insn): Likewise.
3019         (prepare_float_lib_cmp): Likewise.
3020         (expand_float): Likewise.
3021         (expand_fix): Likewise.
3022         (expand_fixed_convert): Likewise.
3023         (maybe_emit_sync_lock_test_and_set): Likewise.
3024         (expand_atomic_compare_and_swap): Likewise.
3025         (expand_mem_thread_fence): Likewise.
3026         (expand_atomic_fetch_op): Likewise.
3028 2017-09-03  Gerald Pfeifer  <gerald@pfeifer.com>
3030         * doc/generic.texi (OpenACC): Adjust URL.
3031         * doc/invoke.texi (C Dialect Options): Ditto.
3033 2017-09-03  Uros Bizjak  <ubizjak@gmail.com>
3035         * config/i386/i386.md (*bt<mode>): Use nonimmediate_operand
3036         predicate for operand 1.  Add (m,<S>) constraint.
3037         (*jcc_bt<mode>): Use nonimmediate_operand predicate for operand 1.
3038         Prevent memory operand 1 with register operand 2.
3040 2017-09-01  Segher Boessenkool  <segher@kernel.crashing.org>
3042         PR rtl-optimization/82024
3043         * combine.c (try_combine): If the combination result is a PARALLEL,
3044         and we only need to retain the SET in there that would be placed
3045         at I2, check that we can place that at I3 instead, before doing so.
3047 2017-09-01  Jakub Jelinek  <jakub@redhat.com>
3049         PR target/81766
3050         * config/i386/i386.c (ix86_init_large_pic_reg): Return label
3051         instead of void.
3052         (ix86_init_pic_reg): Remember label from ix86_init_large_pic_reg,
3053         if non-NULL and preceded by NOTE_INSN_BASIC_BLOCK, swap the note
3054         and label.
3056 2017-09-01  Joerg Sonnenberger  <joerg@bec.de>
3057             Jeff Law  <law@redhat.com>
3059         * varasm.c (bss_initializer_p): Do not put constants into .bss
3060         (categorize_decl_for_section): Handle bss_initializer_p returning
3061         false when DECL_INITIAL is NULL.
3063 2017-09-01  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
3065         PR target/82012
3066         * config/s390/s390.c (s390_can_inline_p): New function.
3068 2017-09-01  Jeff Law  <law@redhat.com>
3070         PR tree-optimization/82052
3071         * tree-ssa-scopedtables.c (avail_exprs_stack::lookup_avail_expr):
3072         Always initialize the returned slot after a hash table miss
3073         when INSERT is true.
3075 2017-09-01  Alexander Monakov  <amonakov@ispras.ru>
3077         * config/s390/s390.md (mem_signal_fence): Remove.
3078         * doc/md.texi (mem_signal_fence): Remove.
3079         * optabs.c (expand_mem_signal_fence): Remove uses of mem_signal_fence.
3080         Update comments.
3081         * target-insns.def (mem_signal_fence): Remove.
3083 2017-09-01  Jakub Jelinek  <jakub@redhat.com>
3085         PR sanitizer/81902
3086         * doc/invoke.texi: Document -fsanitize=pointer-overflow.
3088         PR sanitizer/81923
3089         * asan.c (create_odr_indicator): Strip name encoding from assembler
3090         name before appending it after __odr_asan_.
3092 2017-09-01  Martin Liska  <mliska@suse.cz>
3094         PR tree-optimization/82059
3095         * gimple-ssa-isolate-paths.c (isolate_path): Add profile and
3096         frequency only when an edge is redirected.
3098 2017-09-01  Claudiu Zissulescu  <claziss@synopsys.com>
3100         * config/arc/arc-c.c (__ARC_LPC_WIDTH__): Add builtin define.
3101         * config/arc/arc.c (ARC_MAX_LOOP_LENGTH): Define.
3102         (arc_conditional_register_usage): Remove ARC600 lp_count
3103         exception.
3104         (arc_file_start): Emit Tag_ARC_CPU_variation.
3105         (arc_can_use_doloop_p): New conditions to use ZOLs.
3106         (hwloop_fail): New function.
3107         (hwloop_optimize): Likewise.
3108         (hwloop_pattern_reg): Likewise.
3109         (arc_doloop_hooks): New struct, to be used with reorg_loops.
3110         (arc_reorg_loops): New function, calls reorg_loops.
3111         (arc_reorg): Call arc_reorg_loops.  Remove old ZOL handling.
3112         (arc600_corereg_hazard): Remove ZOL checking, case handled by
3113         hwloop_optimize.
3114         (arc_loop_hazard): Remove function, functionality moved into
3115         hwloop_optimize.
3116         (arc_hazard): Remove arc_loop_hazard call.
3117         (arc_adjust_insn_length): Remove ZOL handling, functionality moved
3118         into hwloop_optimize.
3119         (arc_label_align): Remove ZOL handling.
3120         * config/arc/arc.h (LOOP_ALIGN): Changed to 0.
3121         * config/arc/arc.md (doloop_begin): Remove pattern.
3122         (doloop_begin_i): Likewise.
3123         (doloop_end_i): Likewise.
3124         (doloop_fallback): Likewise.
3125         (doloop_fallback_m): Likewise.
3126         (doloop_end): Reimplement expand.
3127         (arc_lp): New pattern for LP instruction.
3128         (loop_end): New pattern.
3129         (loop_fail): Likewise.
3130         (decrement_and_branch_until_zero): Likewise.
3131         * config/arc/arc.opt (mlpc-width): New option.
3132         * doc/invoke.texi (mlpc-width): Document option.
3134 2017-09-01  Claudiu Zissulescu  <claziss@synopsys.com>
3136         * config/arc/arc.c (arc_ifcvt): Remove use of merge_blocks call.
3137         (arc_ccfsm_advance): Fix checking for delay slots.
3138         (arc_reorg): Add rtl dump after each call to arc_ifcvt.
3140 2017-09-01  Claudiu Zissulescu  <claziss@synopsys.com>
3142         * config/arc/arc.md (movqi_insn): Add stores to save constant long
3143         immediates.
3144         (movhi_insn): Update store instruction constraint which are saving
3145         6-bit short immediates.
3146         (movsi_insn): Consider also short scaled load operations.
3147         (zero_extendhisi2_i): Use Usd constraint instead of T.
3148         (extendhisi2_i): Add q constraint.
3149         (arc_clzsi2): Add type and length attributes.
3150         (arc_ctzsi2): Likewise.
3151         * config/arc/constraints.md (Usc): Update constraint, the
3152         assembler can parse two relocations for a single instruction.
3154 2017-09-01  Claudiu Zissulescu  <claziss@synopsys.com>
3156         * config/arc/arc.c (arc_use_anchors_for_symbol_p): New function.
3157         (TARGET_USE_ANCHORS_FOR_SYMBOL_P): Define.
3159 2017-08-31  Olivier Hainque  <hainque@adacore.com>
3161         * config.gcc (powerpc-wrs-vxworks|vxworksae|vxworksmils): Now
3162         match as powerpc-wrs-vxworks*.
3164 2017-08-31  James Greenhalgh  <james.greenhalgh@arm.com>
3166         * config/aarch64/aarch64-simd.md (aarch64_mla_elt_merge<mode>): Fix
3167         register constraint for by-element operand.
3168         (aarch64_mls_elt_merge<mode>): Likewise.
3170 2017-08-31  Claudiu Zissulescu  <claziss@synopsys.com>
3172         * config/arc/arc.c (arc_can_follow_jump): Check for short
3173         branches.
3175 2017-08-31  Claudiu Zissulescu  <claziss@synopsys.com>
3177         * config.gcc: Use g.opt for arc.
3178         * config/arc/arc.c (LEGITIMATE_SCALED_ADDRESS_P): Deleted,
3179         functionality moved to ...
3180         (legitimate_scaled_address_p): New function, ...here.
3181         (LEGITIMATE_SMALL_DATA_OFFSET_P): New define.
3182         (LEGITIMATE_SMALL_DATA_ADDRESS_P): Use the above define.
3183         (legitimate_offset_address_p): Delete TARGET_NO_SDATA_SET
3184         condition.
3185         (arc_override_options): Handle G option.
3186         (arc_output_pic_addr_const): Correct function definition.
3187         (arc_legitimate_address_p): Use legitimate_scaled_address_p.
3188         (arc_decl_anon_ns_mem_p): Delete.
3189         (arc_in_small_data_p): Overhaul this function to take into
3190         consideration the value given via G option.
3191         (arc_rewrite_small_data_1): Renamed and corrected old
3192         arc_rewrite_small_data function.
3193         (arc_rewrite_small_data): New function.
3194         (small_data_pattern): Don't use pic_offset_table_rtx.
3195         * config/arc/arc.h (CC1_SPEC): Recognize G option.
3196         * config/arc/simdext.md (movmisalignv2hi): Use
3197         prepare_move_operands function.
3198         (mov*): Likewise.
3199         (movmisalign*): Likewise.
3200         * doc/invoke.texi (ARC options): Document -G option.
3202 2017-08-31  Claudiu Zissulescu  <claziss@synopsys.com>
3204         * config/arc/arc-protos.h (compact_sda_memory_operand): Update
3205         prototype.
3206         * config/arc/arc.c (arc_print_operand): Output scalled address for
3207         sdata whenever is possible.
3208         (arc_in_small_data_p): Allow sdata for 64bit datum when double
3209         load/stores are available.
3210         (compact_sda_memory_operand): Check for the alignment required by
3211         code density instructions.
3212         * config/arc/arc.md (movsi_insn): Use newly introduced Us0
3213         constraint.
3214         * config/arc/constraints.md (Usd): Update constraint.
3215         (Us0): New constraint.
3216         (Usc): Update constraint.
3218 2017-08-31  Richard Biener  <rguenther@suse.de>
3220         PR middle-end/82054
3221         * dwarf2out.c (dwarf2out_early_global_decl): Process each
3222         function only once.
3224 2017-08-31  Tamar Christina  <tamar.christina@arm.com>
3226         * config/aarch64/aarch64-builtins.c (aarch64_init_simd_builtins):
3227         Resize type_signature.
3229 2017-08-31  Richard Sandiford  <richard.sandiford@linaro.org>
3230             Alan Hayward  <alan.hayward@arm.com>
3231             David Sherwood  <david.sherwood@arm.com>
3233         * config/aarch64/aarch64.c (aarch64_base_register_rtx_p): Only allow
3234         subregs whose inner modes can be stored in GPRs.
3235         (aarch64_classify_index): Likewise.
3237 2017-08-31  Richard Sandiford  <richard.sandiford@linaro.org>
3238             Alan Hayward  <alan.hayward@arm.com>
3239             David Sherwood  <david.sherwood@arm.com>
3241         * config/aarch64/iterators.md (V_cmp_result): Rename to...
3242         (V_INT_EQUIV): ...this.
3243         (v_cmp_result): Rename to...
3244         (v_int_equiv): ...this.
3245         * config/aarch64/aarch64.md (xorsign<mode>3): Update accordingly.
3246         * config/aarch64/aarch64-simd.md (xorsign<mode>3): Likewise.
3247         (copysign<mode>3): Likewise.
3248         (aarch64_simd_bsl<mode>_internal): Likewise.
3249         (aarch64_simd_bsl<mode>): Likewise.
3250         (vec_cmp<mode><mode>): Likewise.
3251         (vcond<mode><mode>): Likewise.
3252         (vcond<v_cmp_mixed><mode>): Likewise.
3253         (vcondu<mode><v_cmp_mixed>): Likewise.
3254         (aarch64_cm<optab><mode>): Likewise.
3255         (aarch64_cmtst<mode>): Likewise.
3256         (aarch64_fac<optab><mode>): Likewise.
3257         (vec_perm_const<mode>): Likewise.
3258         (vcond_mask_<mode><v_cmp_result>): Rename to...
3259         (vcond_mask_<mode><v_int_equiv>): ...this.
3260         (vec_cmp<mode><v_cmp_result>): Rename to...
3261         (vec_cmp<mode><v_int_equiv>): ...this.
3263 2017-08-31  Richard Sandiford  <richard.sandiford@linaro.org>
3264             Alan Hayward  <alan.hayward@arm.com>
3265             David Sherwood  <david.sherwood@arm.com>
3267         * config/aarch64/aarch64-modes.def: Remove 32-, 48- and 64-byte
3268         vector modes.
3269         * config/aarch64/iterators.md (VRL2, VRL3, VRL4): Delete.
3270         * config/aarch64/aarch64.md (UNSPEC_LD2_DREG, UNSPEC_LD3_DREG)
3271         (UNSPEC_LD4_DREG): New unspecs.
3272         * config/aarch64/aarch64-simd.md (aarch64_ld2<mode>_dreg_le)
3273         (aarch64_ld2<mode>_dreg_be): Replace with...
3274         (aarch64_ld2<mode>_dreg): ...this pattern and use the new DREG
3275         unspec.
3276         (aarch64_ld3<mode>_dreg_le)
3277         (aarch64_ld3<mode>_dreg_be): Replace with...
3278         (aarch64_ld3<mode>_dreg): ...this pattern and use the new DREG
3279         unspec.
3280         (aarch64_ld4<mode>_dreg_le)
3281         (aarch64_ld4<mode>_dreg_be): Replace with...
3282         (aarch64_ld4<mode>_dreg): ...this pattern and use the new DREG
3283         unspec.
3285 2017-08-30  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
3287         PR tree-optimization/81987
3288         * gimple-ssa-strength-reduction.c (insert_initializers): Don't
3289         insert an initializer in a location not dominated by the stride
3290         definition.
3292 2017-08-30  Eric Botcazou  <ebotcazou@adacore.com>
3294         * tree-eh.c (lower_try_finally_switch): Set the location of the finally
3295         on the entire header of the finally block in the fallthru case.
3297 2017-08-30  Eric Botcazou  <ebotcazou@adacore.com>
3299         * varasm.c (decode_addr_const): Deal with INDIRECT_REF <INTEGER_CST>.
3301 2017-08-30  Pat Haugen  <pthaugen@us.ibm.com>
3303         * config/rs6000/rs6000.c (rs6000_emit_prologue_move_from_cr): Rename from
3304         rs6000_emit_move_from_cr and call renamed function.
3305         (rs6000_emit_prologue): Call renamed functions.
3306         * config/rs6000/rs6000.md (prologue_movesi_from_cr): Rename from
3307         movesi_from_cr, remove volatile CRs.
3309 2017-08-30  Jon Beniston  <jon@beniston.com>
3310             Richard Biener  <rguenther@suse.de>
3312         * tree-vect-patterns.c (vect_pattern_recog_1): Use VECTOR_TYPE_P instead
3313         of VECTOR_MODE_P check.
3314         * tree-vect-stmts.c (get_vectype_for_scalar_type_and_size): Allow single
3315         element vector types.
3317 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3319         * df.h (df_read_modify_subreg_p): Remove in favor of...
3320         * rtl.h (read_modify_subreg_p): ...this new function.  Take a
3321         const_rtx instead of an rtx.
3322         * cprop.c (local_cprop_find_used_regs): Update accordingly.
3323         * df-problems.c (df_word_lr_mark_ref): Likewise.
3324         * ira-lives.c (mark_pseudo_reg_live): Likewise.
3325         (mark_pseudo_reg_dead): Likewise.
3326         (mark_ref_dead): Likewise.
3327         * reginfo.c (init_subregs_of_mode): Likewise.
3328         * sched-deps.c (sched_analyze_1): Likewise.
3329         * df-scan.c (df_def_record_1): Likewise.
3330         (df_uses_record): Likewise.
3331         (df_read_modify_subreg_p): Remove in favor of...
3332         * rtlanal.c (read_modify_subreg_p): ...this new function.  Take a
3333         const_rtx instead of an rtx.
3335 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3336             Alan Hayward  <alan.hayward@arm.com>
3337             David Sherwood  <david.sherwood@arm.com>
3339         * rtl.h (partial_subreg_p): New function.
3340         * caller-save.c (save_call_clobbered_regs): Use it.
3341         * calls.c (expand_call): Likewise.
3342         * combine.c (combinable_i3pat): Likewise.
3343         (simplify_set): Likewise.
3344         (make_extraction): Likewise.
3345         (make_compound_operation_int): Likewise.
3346         (gen_lowpart_or_truncate): Likewise.
3347         (force_to_mode): Likewise.
3348         (make_field_assignment): Likewise.
3349         (reg_truncated_to_mode): Likewise.
3350         (record_truncated_value): Likewise.
3351         (move_deaths): Likewise.
3352         * cse.c (record_jump_cond): Likewise.
3353         (cse_insn): Likewise.
3354         * cselib.c (cselib_lookup_1): Likewise.
3355         * expmed.c (extract_bit_field_using_extv): Likewise.
3356         * function.c (assign_parm_setup_reg): Likewise.
3357         * ifcvt.c (noce_convert_multiple_sets): Likewise.
3358         * ira-build.c (create_insn_allocnos): Likewise.
3359         * lra-coalesce.c (merge_pseudos): Likewise.
3360         * lra-constraints.c (match_reload): Likewise.
3361         (simplify_operand_subreg): Likewise.
3362         (curr_insn_transform): Likewise.
3363         * lra-lives.c (process_bb_lives): Likewise.
3364         * lra.c (new_insn_reg): Likewise.
3365         (lra_substitute_pseudo): Likewise.
3366         * regcprop.c (mode_change_ok): Likewise.
3367         (maybe_mode_change): Likewise.
3368         (copyprop_hardreg_forward_1): Likewise.
3369         * reload.c (push_reload): Likewise.
3370         (find_reloads): Likewise.
3371         (find_reloads_subreg_address): Likewise.
3372         * reload1.c (alter_reg): Likewise.
3373         (eliminate_regs_1): Likewise.
3374         * simplify-rtx.c (simplify_unary_operation_1): Likewise.
3376 2017-08-30  David Edelsohn  <dje.gcc@gmail.com>
3378         * config/rs6000/rs6000.c (rs6000_expand_binop_builtin): Revert
3379         back to if statements, including unpack.
3381 2017-08-30  Martin Liska  <mliska@suse.cz>
3383         PR inline-asm/82001
3384         * ipa-icf-gimple.c (func_checker::compare_tree_list_operand):
3385         Rename to ...
3386         (func_checker::compare_asm_inputs_outputs): ... this function.
3387         (func_checker::compare_gimple_asm): Use the function to compare
3388         also ASM constrains.
3389         * ipa-icf-gimple.h: Rename the function.
3391 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3392             Alan Hayward  <alan.hayward@arm.com>
3393             David Sherwood  <david.sherwood@arm.com>
3395         * coretypes.h (complex_mode): New type.
3396         * gdbhooks.py (build_pretty_printer): Handle it.
3397         * machmode.h (complex_mode): New class.
3398         (complex_mode::includes_p): New function.
3399         (is_complex_int_mode): Likewise.
3400         (is_complex_float_mode): Likewise.
3401         * genmodes.c (get_mode_class): Handle complex mode classes.
3402         * function.c (expand_function_end): Use is_complex_int_mode.
3404 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3405             Alan Hayward  <alan.hayward@arm.com>
3406             David Sherwood  <david.sherwood@arm.com>
3408         * coretypes.h (scalar_mode_pod): New typedef.
3409         * gdbhooks.py (build_pretty_printer): Handle it.
3410         * machmode.h (gt_ggc_mx, gt_pch_nx): New functions.
3411         * fixed-value.h (fixed_value::mode): Change type to scalar_mode_pod.
3412         * fold-const.c (fold_convert_const_int_from_fixed): Use scalar_mode.
3413         * tree-streamer-in.c (unpack_ts_fixed_cst_value_fields): Use
3414         as_a <scalar_mode>.
3416 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3417             Alan Hayward  <alan.hayward@arm.com>
3418             David Sherwood  <david.sherwood@arm.com>
3420         * machmode.h (mode_for_vector): Take a scalar_mode instead
3421         of a machine_mode.
3422         * stor-layout.c (mode_for_vector): Likewise.
3423         * explow.c (promote_mode): Use as_a <scalar_mode>.
3424         * sdbout.c (sdbout_parms): Use is_a <scalar_mode>.
3426 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3427             Alan Hayward  <alan.hayward@arm.com>
3428             David Sherwood  <david.sherwood@arm.com>
3430         * target.def (preferred_simd_mode): Take a scalar_mode
3431         instead of a machine_mode.
3432         * targhooks.h (default_preferred_simd_mode): Likewise.
3433         * targhooks.c (default_preferred_simd_mode): Likewise.
3434         * config/arc/arc.c (arc_preferred_simd_mode): Likewise.
3435         * config/arm/arm.c (arm_preferred_simd_mode): Likewise.
3436         * config/c6x/c6x.c (c6x_preferred_simd_mode): Likewise.
3437         * config/epiphany/epiphany.c (epiphany_preferred_simd_mode): Likewise.
3438         * config/i386/i386.c (ix86_preferred_simd_mode): Likewise.
3439         * config/mips/mips.c (mips_preferred_simd_mode): Likewise.
3440         * config/nvptx/nvptx.c (nvptx_preferred_simd_mode): Likewise.
3441         * config/powerpcspe/powerpcspe.c (rs6000_preferred_simd_mode):
3442         Likewise.
3443         * config/rs6000/rs6000.c (rs6000_preferred_simd_mode): Likewise.
3444         * config/s390/s390.c (s390_preferred_simd_mode): Likewise.
3445         * config/sparc/sparc.c (sparc_preferred_simd_mode): Likewise.
3446         * config/aarch64/aarch64.c (aarch64_preferred_simd_mode): Likewise.
3447         (aarch64_simd_scalar_immediate_valid_for_move): Update accordingly.
3448         * doc/tm.texi: Regenerate.
3449         * optabs-query.c (can_vec_mask_load_store_p): Return false for
3450         non-scalar modes.
3452 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3453             Alan Hayward  <alan.hayward@arm.com>
3454             David Sherwood  <david.sherwood@arm.com>
3456         * target.def (scalar_mode_supported_p): Take a scalar_mode
3457         instead of a machine_mode.
3458         * targhooks.h (default_scalar_mode_supported_p): Likewise.
3459         * targhooks.c (default_scalar_mode_supported_p): Likewise.
3460         * config/aarch64/aarch64.c (aarch64_scalar_mode_supported_p): Likewise.
3461         * config/alpha/alpha.c (alpha_scalar_mode_supported_p): Likewise.
3462         * config/arm/arm.c (arm_scalar_mode_supported_p): Likewise.
3463         * config/avr/avr.c (avr_scalar_mode_supported_p): Likewise.
3464         * config/c6x/c6x.c (c6x_scalar_mode_supported_p): Likewise.
3465         * config/i386/i386.c (ix86_scalar_mode_supported_p): Likewise.
3466         * config/ia64/ia64.c (ia64_scalar_mode_supported_p): Likewise.
3467         * config/mips/mips.c (mips_scalar_mode_supported_p): Likewise.
3468         * config/msp430/msp430.c (msp430_scalar_mode_supported_p): Likewise.
3469         * config/pa/pa.c (pa_scalar_mode_supported_p): Likewise.
3470         * config/pdp11/pdp11.c (pdp11_scalar_mode_supported_p): Likewise.
3471         * config/powerpcspe/powerpcspe.c (rs6000_scalar_mode_supported_p):
3472         Likewise.
3473         * config/rs6000/rs6000.c (rs6000_scalar_mode_supported_p): Likewise.
3474         * config/s390/s390.c (s390_scalar_mode_supported_p): Likewise.
3475         * config/spu/spu.c (spu_scalar_mode_supported_p): Likewise.
3476         * config/tilegx/tilegx.c (tilegx_scalar_mode_supported_p): Likewise.
3477         * config/tilepro/tilepro.c (tilepro_scalar_mode_supported_p):
3478         Likewise.
3479         * doc/tm.texi: Regenerate.
3481 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3482             Alan Hayward  <alan.hayward@arm.com>
3483             David Sherwood  <david.sherwood@arm.com>
3485         * coretypes.h (opt_scalar_mode): New typedef.
3486         * gdbhooks.py (build_pretty_printers): Handle it.
3487         * machmode.h (mode_iterator::get_2xwider): Add overload for
3488         opt_mode<T>.
3489         * emit-rtl.c (init_emit_once): Use opt_scalar_mode when iterating
3490         over scalar modes.
3491         * expr.c (convert_mode_scalar): Likewise.
3492         * omp-low.c (omp_clause_aligned_alignment): Likewise.
3493         * optabs.c (expand_float): Likewise.
3494         (expand_fix): Likewise.
3495         * tree-vect-stmts.c (vectorizable_conversion): Likewise.
3497 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3498             Alan Hayward  <alan.hayward@arm.com>
3499             David Sherwood  <david.sherwood@arm.com>
3501         * optabs.c (expand_float): Explicitly check for scalars before
3502         using a branching expansion.
3503         (expand_fix): Likewise.
3505 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3506             Alan Hayward  <alan.hayward@arm.com>
3507             David Sherwood  <david.sherwood@arm.com>
3509         * expr.c (convert_mode): Split scalar handling out into...
3510         (convert_mode_scalar): ...this new function.  Treat the modes
3511         as scalar_modes.
3513 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3514             Alan Hayward  <alan.hayward@arm.com>
3515             David Sherwood  <david.sherwood@arm.com>
3517         * omp-expand.c (expand_omp_atomic): Use is_int_mode, is_float_mode
3518         and scalar_mode.
3519         * tree-vect-stmts.c (get_vectype_for_scalar_type_and_size): Likewise.
3521 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3522             Alan Hayward  <alan.hayward@arm.com>
3523             David Sherwood  <david.sherwood@arm.com>
3525         * fixed-value.h (fixed_from_double_int): Take a scalar_mode
3526         rather than a machine_mode.
3527         (fixed_from_string): Likewise.
3528         (fixed_convert): Likewise.
3529         (fixed_convert_from_int): Likewise.
3530         (fixed_convert_from_real): Likewise.
3531         (real_convert_from_fixed): Likewise.
3532         * fixed-value.c (fixed_from_double_int): Likewise.
3533         (fixed_from_string): Likewise.
3534         (fixed_convert): Likewise.
3535         (fixed_convert_from_int): Likewise.
3536         (fixed_convert_from_real): Likewise.
3537         (real_convert_from_fixed): Likewise.
3538         * config/avr/avr.c (avr_out_round): Use as_a <scalar_mode>.
3540 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3541             Alan Hayward  <alan.hayward@arm.com>
3542             David Sherwood  <david.sherwood@arm.com>
3544         * emit-rtl.c (immed_double_const): Use is_a <scalar_mode> instead
3545         of separate mode class checks.  Do not allow vector modes here.
3546         (immed_wide_int_const): Use as_a <scalar_mode>.
3547         * explow.c (trunc_int_for_mode): Likewise.
3548         * rtl.h (wi::int_traits<rtx_mode_t>::get_precision): Likewise.
3549         (wi::shwi): Likewise.
3550         (wi::min_value): Likewise.
3551         (wi::max_value): Likewise.
3552         * dwarf2out.c (loc_descriptor): Likewise.
3553         * simplify-rtx.c (simplify_immed_subreg): Fix rtx_mode_t argument
3554         for CONST_WIDE_INT.
3556 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3557             Alan Hayward  <alan.hayward@arm.com>
3558             David Sherwood  <david.sherwood@arm.com>
3560         * tree.h (SCALAR_TYPE_MODE): New macro.
3561         * expr.c (expand_expr_addr_expr_1): Use it.
3562         (expand_expr_real_2): Likewise.
3563         * fold-const.c (fold_convert_const_fixed_from_fixed): Likeise.
3564         (fold_convert_const_fixed_from_int): Likewise.
3565         (fold_convert_const_fixed_from_real): Likewise.
3566         (native_encode_fixed): Likewise
3567         (native_encode_complex): Likewise
3568         (native_encode_vector): Likewise.
3569         (native_interpret_fixed): Likewise.
3570         (native_interpret_real): Likewise.
3571         (native_interpret_complex): Likewise.
3572         (native_interpret_vector): Likewise.
3573         * omp-simd-clone.c (simd_clone_adjust_return_type): Likewise.
3574         (simd_clone_adjust_argument_types): Likewise.
3575         (simd_clone_init_simd_arrays): Likewise.
3576         (simd_clone_adjust): Likewise.
3577         * stor-layout.c (layout_type): Likewise.
3578         * tree.c (build_minus_one_cst): Likewise.
3579         * tree-cfg.c (verify_gimple_assign_ternary): Likewise.
3580         * tree-inline.c (estimate_move_cost): Likewise.
3581         * tree-ssa-math-opts.c (convert_plusminus_to_widen): Likewise.
3582         * tree-vect-loop.c (vect_create_epilog_for_reduction): Likewise.
3583         (vectorizable_reduction): Likewise.
3584         * tree-vect-patterns.c (vect_recog_widen_mult_pattern): Likewise.
3585         (vect_recog_mixed_size_cond_pattern): Likewise.
3586         (check_bool_pattern): Likewise.
3587         (adjust_bool_pattern): Likewise.
3588         (search_type_for_mask_1): Likewise.
3589         * tree-vect-slp.c (vect_schedule_slp_instance): Likewise.
3590         * tree-vect-stmts.c (vectorizable_conversion): Likewise.
3591         (vectorizable_load): Likewise.
3592         (vectorizable_store): Likewise.
3593         * ubsan.c (ubsan_encode_value): Likewise.
3594         * varasm.c (output_constant): Likewise.
3596 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3597             Alan Hayward  <alan.hayward@arm.com>
3598             David Sherwood  <david.sherwood@arm.com>
3600         * coretypes.h (scalar_mode): New class.
3601         * machmode.h (scalar_mode): Likewise.
3602         (scalar_mode::includes_p): New function.
3603         (mode_to_inner): Return a scalar_mode rather than a machine_mode.
3604         * gdbhooks.py (build_pretty_printers): Handle scalar_mode.
3605         * genmodes.c (get_mode_class): Handle remaining scalar modes.
3606         * cfgexpand.c (expand_debug_expr): Use scalar_mode.
3607         * expmed.c (store_bit_field_1): Likewise.
3608         (extract_bit_field_1): Likewise.
3609         * expr.c (write_complex_part): Likewise.
3610         (read_complex_part): Likewise.
3611         (emit_move_complex_push): Likewise.
3612         (expand_expr_real_2): Likewise.
3613         * function.c (assign_parm_setup_reg): Likewise.
3614         (assign_parms_unsplit_complex): Likewise.
3615         * optabs.c (expand_binop): Likewise.
3616         * rtlanal.c (subreg_get_info): Likewise.
3617         * simplify-rtx.c (simplify_immed_subreg): Likewise.
3618         * varasm.c (output_constant_pool_2): Likewise.
3620 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3621             Alan Hayward  <alan.hayward@arm.com>
3622             David Sherwood  <david.sherwood@arm.com>
3624         * expmed.c (extract_high_half): Use scalar_int_mode and remove
3625         assertion.
3626         (expmed_mult_highpart_optab): Likewise.
3627         (expmed_mult_highpart): Likewise.
3629 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3630             Alan Hayward  <alan.hayward@arm.com>
3631             David Sherwood  <david.sherwood@arm.com>
3633         * builtins.h (builtin_strncpy_read_str): Take a scalar_int_mode
3634         instead of a machine_mode.
3635         (builtin_memset_read_str): Likewise.
3636         * builtins.c (c_readstr): Likewise.
3637         (builtin_memcpy_read_str): Likewise.
3638         (builtin_strncpy_read_str): Likewise.
3639         (builtin_memset_read_str): Likewise.
3640         (builtin_memset_gen_str): Likewise.
3641         (expand_builtin_signbit): Use scalar_int_mode for local variables.
3642         * cfgexpand.c (convert_debug_memory_address): Take a scalar_int_mode
3643         instead of a machine_mode.
3644         * combine.c (simplify_if_then_else): Use scalar_int_mode for local
3645         variables.
3646         (make_extraction): Likewise.
3647         (try_widen_shift_mode): Take and return scalar_int_modes instead
3648         of machine_modes.
3649         * config/aarch64/aarch64.c (aarch64_libgcc_cmp_return_mode): Return
3650         a scalar_int_mode instead of a machine_mode.
3651         * config/avr/avr.c (avr_addr_space_address_mode): Likewise.
3652         (avr_addr_space_pointer_mode): Likewise.
3653         * config/cr16/cr16.c (cr16_unwind_word_mode): Likewise.
3654         * config/msp430/msp430.c (msp430_addr_space_pointer_mode): Likewise.
3655         (msp430_unwind_word_mode): Likewise.
3656         * config/spu/spu.c (spu_unwind_word_mode): Likewise.
3657         (spu_addr_space_pointer_mode): Likewise.
3658         (spu_addr_space_address_mode): Likewise.
3659         (spu_libgcc_cmp_return_mode): Likewise.
3660         (spu_libgcc_shift_count_mode): Likewise.
3661         * config/rl78/rl78.c (rl78_addr_space_address_mode): Likewise.
3662         (rl78_addr_space_pointer_mode): Likewise.
3663         (fl78_unwind_word_mode): Likewise.
3664         (rl78_valid_pointer_mode): Take a scalar_int_mode instead of a
3665         machine_mode.
3666         * config/alpha/alpha.c (vms_valid_pointer_mode): Likewise.
3667         * config/ia64/ia64.c (ia64_vms_valid_pointer_mode): Likewise.
3668         * config/mips/mips.c (mips_mode_rep_extended): Likewise.
3669         (mips_valid_pointer_mode): Likewise.
3670         * config/tilegx/tilegx.c (tilegx_mode_rep_extended): Likewise.
3671         * config/ft32/ft32.c (ft32_valid_pointer_mode): Likewise.
3672         (ft32_addr_space_pointer_mode): Return a scalar_int_mode instead
3673         of a machine_mode.
3674         (ft32_addr_space_address_mode): Likewise.
3675         * config/m32c/m32c.c (m32c_valid_pointer_mode): Take a
3676         scalar_int_mode instead of a machine_mode.
3677         (m32c_addr_space_pointer_mode): Return a scalar_int_mode instead
3678         of a machine_mode.
3679         (m32c_addr_space_address_mode): Likewise.
3680         * config/powerpcspe/powerpcspe.c (rs6000_abi_word_mode): Likewise.
3681         (rs6000_eh_return_filter_mode): Likewise.
3682         * config/rs6000/rs6000.c (rs6000_abi_word_mode): Likewise.
3683         (rs6000_eh_return_filter_mode): Likewise.
3684         * config/s390/s390.c (s390_libgcc_cmp_return_mode): Likewise.
3685         (s390_libgcc_shift_count_mode): Likewise.
3686         (s390_unwind_word_mode): Likewise.
3687         (s390_valid_pointer_mode): Take a scalar_int_mode rather than a
3688         machine_mode.
3689         * target.def (mode_rep_extended): Likewise.
3690         (valid_pointer_mode): Likewise.
3691         (addr_space.valid_pointer_mode): Likewise.
3692         (eh_return_filter_mode): Return a scalar_int_mode rather than
3693         a machine_mode.
3694         (libgcc_cmp_return_mode): Likewise.
3695         (libgcc_shift_count_mode): Likewise.
3696         (unwind_word_mode): Likewise.
3697         (addr_space.pointer_mode): Likewise.
3698         (addr_space.address_mode): Likewise.
3699         * doc/tm.texi: Regenerate.
3700         * dojump.c (prefer_and_bit_test): Take a scalar_int_mode rather than
3701         a machine_mode.
3702         (do_jump): Use scalar_int_mode for local variables.
3703         * dwarf2cfi.c (init_return_column_size): Take a scalar_int_mode
3704         rather than a machine_mode.
3705         * dwarf2out.c (convert_descriptor_to_mode): Likewise.
3706         (scompare_loc_descriptor_wide): Likewise.
3707         (scompare_loc_descriptor_narrow): Likewise.
3708         * emit-rtl.c (adjust_address_1): Use scalar_int_mode for local
3709         variables.
3710         * except.c (sjlj_emit_dispatch_table): Likewise.
3711         (expand_builtin_eh_copy_values): Likewise.
3712         * explow.c (convert_memory_address_addr_space_1): Likewise.
3713         Take a scalar_int_mode rather than a machine_mode.
3714         (convert_memory_address_addr_space): Take a scalar_int_mode rather
3715         than a machine_mode.
3716         (memory_address_addr_space): Use scalar_int_mode for local variables.
3717         * expmed.h (expand_mult_highpart_adjust): Take a scalar_int_mode
3718         rather than a machine_mode.
3719         * expmed.c (mask_rtx): Likewise.
3720         (init_expmed_one_conv): Likewise.
3721         (expand_mult_highpart_adjust): Likewise.
3722         (extract_high_half): Likewise.
3723         (expmed_mult_highpart_optab): Likewise.
3724         (expmed_mult_highpart): Likewise.
3725         (expand_smod_pow2): Likewise.
3726         (expand_sdiv_pow2): Likewise.
3727         (emit_store_flag_int): Likewise.
3728         (adjust_bit_field_mem_for_reg): Use scalar_int_mode for local
3729         variables.
3730         (extract_low_bits): Likewise.
3731         * expr.h (by_pieces_constfn): Take a scalar_int_mode rather than
3732         a machine_mode.
3733         * expr.c (pieces_addr::adjust):  Likewise.
3734         (can_store_by_pieces): Likewise.
3735         (store_by_pieces): Likewise.
3736         (clear_by_pieces_1): Likewise.
3737         (expand_expr_addr_expr_1): Likewise.
3738         (expand_expr_addr_expr): Use scalar_int_mode for local variables.
3739         (expand_expr_real_1): Likewise.
3740         (try_casesi): Likewise.
3741         * final.c (shorten_branches): Likewise.
3742         * fold-const.c (fold_convert_const_int_from_fixed): Change the
3743         type of "mode" to machine_mode.
3744         * internal-fn.c (expand_arith_overflow_result_store): Take a
3745         scalar_int_mode rather than a machine_mode.
3746         (expand_mul_overflow): Use scalar_int_mode for local variables.
3747         * loop-doloop.c (doloop_modify): Likewise.
3748         (doloop_optimize): Likewise.
3749         * optabs.c (expand_subword_shift): Take a scalar_int_mode rather
3750         than a machine_mode.
3751         (expand_doubleword_shift_condmove): Likewise.
3752         (expand_doubleword_shift): Likewise.
3753         (expand_doubleword_clz): Likewise.
3754         (expand_doubleword_popcount): Likewise.
3755         (expand_doubleword_parity): Likewise.
3756         (expand_absneg_bit): Use scalar_int_mode for local variables.
3757         (prepare_float_lib_cmp): Likewise.
3758         * rtl.h (convert_memory_address_addr_space_1): Take a scalar_int_mode
3759         rather than a machine_mode.
3760         (convert_memory_address_addr_space): Likewise.
3761         (get_mode_bounds): Likewise.
3762         (get_address_mode): Return a scalar_int_mode rather than a
3763         machine_mode.
3764         * rtlanal.c (get_address_mode): Likewise.
3765         * stor-layout.c (get_mode_bounds): Take a scalar_int_mode rather
3766         than a machine_mode.
3767         * targhooks.c (default_mode_rep_extended): Likewise.
3768         (default_valid_pointer_mode): Likewise.
3769         (default_addr_space_valid_pointer_mode): Likewise.
3770         (default_eh_return_filter_mode): Return a scalar_int_mode rather
3771         than a machine_mode.
3772         (default_libgcc_cmp_return_mode): Likewise.
3773         (default_libgcc_shift_count_mode): Likewise.
3774         (default_unwind_word_mode): Likewise.
3775         (default_addr_space_pointer_mode): Likewise.
3776         (default_addr_space_address_mode): Likewise.
3777         * targhooks.h (default_eh_return_filter_mode): Likewise.
3778         (default_libgcc_cmp_return_mode): Likewise.
3779         (default_libgcc_shift_count_mode): Likewise.
3780         (default_unwind_word_mode): Likewise.
3781         (default_addr_space_pointer_mode): Likewise.
3782         (default_addr_space_address_mode): Likewise.
3783         (default_mode_rep_extended): Take a scalar_int_mode rather than
3784         a machine_mode.
3785         (default_valid_pointer_mode): Likewise.
3786         (default_addr_space_valid_pointer_mode): Likewise.
3787         * tree-ssa-address.c (addr_for_mem_ref): Use scalar_int_mode for
3788         local variables.
3789         * tree-ssa-loop-ivopts.c (get_shiftadd_cost): Take a scalar_int_mode
3790         rather than a machine_mode.
3791         * tree-switch-conversion.c (array_value_type): Use scalar_int_mode
3792         for local variables.
3793         * tree-vrp.c (simplify_float_conversion_using_ranges): Likewise.
3794         * var-tracking.c (use_narrower_mode): Take a scalar_int_mode rather
3795         than a machine_mode.
3797 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3798             Alan Hayward  <alan.hayward@arm.com>
3799             David Sherwood  <david.sherwood@arm.com>
3801         * dojump.c (do_jump_by_parts_greater_rtx): Change the type of
3802         the mode argument to scalar_int_mode.
3803         (do_jump_by_parts_zero_rtx): Likewise.
3804         (do_jump_by_parts_equality_rtx): Likewise.
3805         (do_jump_by_parts_greater): Take a mode argument.
3806         (do_jump_by_parts_equality): Likewise.
3807         (do_jump_1): Update calls accordingly.
3809 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3810             Alan Hayward  <alan.hayward@arm.com>
3811             David Sherwood  <david.sherwood@arm.com>
3813         * is-a.h (safe_dyn_cast): New function.
3814         * rtl.h (rtx_jump_table_data::get_data_mode): New function.
3815         (jump_table_for_label): Likewise.
3816         * final.c (final_addr_vec_align): Take an rtx_jump_table_data *
3817         instead of an rtx_insn *.
3818         (shorten_branches): Use dyn_cast instead of LABEL_P and
3819         JUMP_TABLE_DATA_P.  Use jump_table_for_label and
3820         rtx_jump_table_data::get_data_mode.
3821         (final_scan_insn): Likewise.
3823 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3824             Alan Hayward  <alan.hayward@arm.com>
3825             David Sherwood  <david.sherwood@arm.com>
3827         * combine.c (try_combine): Use is_a <scalar_int_mode> when
3828         trying to combine a full-register integer set with a subreg
3829         integer set.
3831 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3832             Alan Hayward  <alan.hayward@arm.com>
3833             David Sherwood  <david.sherwood@arm.com>
3835         * expr.c (expand_expr_addr_expr): Add a new_tmode local variable
3836         that is always either address_mode or pointer_mode.
3838 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3839             Alan Hayward  <alan.hayward@arm.com>
3840             David Sherwood  <david.sherwood@arm.com>
3842         * expr.c (expand_expr_real_2): Use word_mode instead of innermode
3843         when the two are known to be equal.
3845 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3846             Alan Hayward  <alan.hayward@arm.com>
3847             David Sherwood  <david.sherwood@arm.com>
3849         * simplify-rtx.c (simplify_const_unary_operation): Use
3850         is_a <scalar_int_mode> instead of checking for a nonzero
3851         precision.  Forcibly convert op_mode to a scalar_int_mode
3852         in that case.  More clearly differentiate the operand and
3853         result modes and use the former when deciding what the value
3854         of a count-bits operation should be.  Use is_int_mode instead
3855         of checking for a MODE_INT.  Remove redundant check for whether
3856         this mode has a zero precision.
3858 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3859             Alan Hayward  <alan.hayward@arm.com>
3860             David Sherwood  <david.sherwood@arm.com>
3862         * optabs.c (widen_leading): Change the type of the mode argument
3863         to scalar_int_mode.  Use opt_scalar_int_mode for the mode iterator.
3864         (widen_bswap): Likewise.
3865         (expand_parity): Likewise.
3866         (expand_ctz): Change the type of the mode argument to scalar_int_mode.
3867         (expand_ffs): Likewise.
3868         (epand_unop): Check for scalar integer modes before calling the
3869         above routines.
3871 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3872             Alan Hayward  <alan.hayward@arm.com>
3873             David Sherwood  <david.sherwood@arm.com>
3875         * expr.c (const_scalar_mask_from_tree): Add a mode argument.
3876         Expand commentary.
3877         (expand_expr_real_1): Update call accordingly.
3879 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3880             Alan Hayward  <alan.hayward@arm.com>
3881             David Sherwood  <david.sherwood@arm.com>
3883         * expmed.c (store_bit_field_using_insv): Add op0_mode and
3884         value_mode arguments.  Use scalar_int_mode internally.
3885         (store_bit_field_1): Rename the new integer mode from imode
3886         to op0_mode and use it instead of GET_MODE (op0).  Update calls
3887         to store_split_bit_field, store_bit_field_using_insv and
3888         store_fixed_bit_field.
3889         (store_fixed_bit_field): Add op0_mode and value_mode arguments.
3890         Use scalar_int_mode internally.  Use a bit count rather than a mode
3891         when calculating the largest bit size for get_best_mode.
3892         Update calls to store_split_bit_field and store_fixed_bit_field_1.
3893         (store_fixed_bit_field_1): Add mode and value_mode arguments.
3894         Remove assertion that OP0 has a scalar integer mode.
3895         (store_split_bit_field): Add op0_mode and value_mode arguments.
3896         Update calls to extract_fixed_bit_field.
3897         (extract_bit_field_using_extv): Add an op0_mode argument.
3898         Use scalar_int_mode internally.
3899         (extract_bit_field_1): Rename the new integer mode from imode to
3900         op0_mode and use it instead of GET_MODE (op0).  Update calls to
3901         extract_split_bit_field, extract_bit_field_using_extv and
3902         extract_fixed_bit_field.
3903         (extract_fixed_bit_field): Add an op0_mode argument.  Update calls
3904         to extract_split_bit_field and extract_fixed_bit_field_1.
3905         (extract_fixed_bit_field_1): Add a mode argument.  Remove assertion
3906         that OP0 has a scalar integer mode.  Use as_a <scalar_int_mode>
3907         on the target mode.
3908         (extract_split_bit_field): Add an op0_mode argument.  Update call
3909         to extract_fixed_bit_field.
3911 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3912             Alan Hayward  <alan.hayward@arm.com>
3913             David Sherwood  <david.sherwood@arm.com>
3915         * cse.c (cse_insn): Use opt_scalar_int_mode for the mode iterator.
3916         * explow.c (hard_function_value): Likewise.
3917         * expmed.c (extract_fixed_bit_field_1): Likewise.  Move the
3918         convert_to_mode call outside the loop.
3919         * expr.c (alignment_for_piecewise_move): Use opt_scalar_int_mode
3920         for the mode iterator.  Require the mode specified by max_pieces
3921         to exist.
3922         (emit_block_move_via_movmem): Use opt_scalar_int_mode for the
3923         mode iterator.
3924         (copy_blkmode_to_reg): Likewise.
3925         (set_storage_via_setmem): Likewise.
3926         * optabs.c (prepare_cmp_insn): Likewise.
3927         * rtlanal.c (init_num_sign_bit_copies_in_rep): Likewise.
3928         * stor-layout.c (finish_bitfield_representative): Likewise.
3930 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3931             Alan Hayward  <alan.hayward@arm.com>
3932             David Sherwood  <david.sherwood@arm.com>
3934         * rtl.h (subreg_unpromoted_mode, subreg_promoted_mode): New functions.
3935         * expr.c (convert_move): Use them.
3936         (convert_modes): Likewise.
3937         (store_expr_with_bounds): Likewise.
3939 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3940             Alan Hayward  <alan.hayward@arm.com>
3941             David Sherwood  <david.sherwood@arm.com>
3943         * rtl.h (rtl_hooks::reg_nonzero_bits): Add a scalar_int_mode
3944         parameter for the mode of "x".  Remove the "known_x", "known_mode"
3945         and "known_ret" arguments.  Change the type of the mode argument
3946         to scalar_int_mode.
3947         (rtl_hooks:reg_num_sign_bit_copies): Likewise.
3948         * combine.c (reg_nonzero_bits_for_combine): Update accordingly.
3949         (reg_num_sign_bit_copies_for_combine): Likewise.
3950         * rtlanal.c (nonzero_bits1): Likewise.
3951         (num_sign_bit_copies1): Likewise.
3952         * rtlhooks-def.h (reg_nonzero_bits_general): Likewise.
3953         (reg_num_sign_bit_copies_general): Likewise.
3954         * rtlhooks.c (reg_num_sign_bit_copies_general): Likewise.
3955         (reg_nonzero_bits_general): Likewise.
3957 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3958             Alan Hayward  <alan.hayward@arm.com>
3959             David Sherwood  <david.sherwood@arm.com>
3961         * rtlanal.c (num_sign_bit_copies): Handle VOIDmode here rather
3962         than in subroutines.  Return 1 for non-integer modes.
3963         (cached_num_sign_bit_copies): Change the type of the mode parameter
3964         to scalar_int_mode.
3965         (num_sign_bit_copies1): Likewise.  Remove early exit for other mode
3966         classes.  Handle CONST_INT_P first and then check whether X also
3967         has a scalar integer mode.  Check the same thing for inner registers
3968         of a SUBREG and for values that are being extended or truncated.
3970 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3971             Alan Hayward  <alan.hayward@arm.com>
3972             David Sherwood  <david.sherwood@arm.com>
3974         * rtlanal.c (nonzero_bits): Handle VOIDmode here rather than
3975         in subroutines.  Return the mode mask for non-integer modes.
3976         (cached_nonzero_bits): Change the type of the mode parameter
3977         to scalar_int_mode.
3978         (nonzero_bits1): Likewise.  Remove early exit for other mode
3979         classes.  Handle CONST_INT_P first and then check whether X
3980         also has a scalar integer mode.
3982 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3983             Alan Hayward  <alan.hayward@arm.com>
3984             David Sherwood  <david.sherwood@arm.com>
3986         * expr.c (widest_int_mode_for_size): Make the comment match the code.
3987         Return a scalar_int_mode and assert that the size is greater than
3988         one byte.
3989         (by_pieces_ninsns): Update accordingly and remove VOIDmode handling.
3990         (op_by_pieces_d::op_by_pieces_d): Likewise.
3991         (op_by_pieces_d::run): Likewise.
3992         (can_store_by_pieces): Likewise.
3994 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3995             Alan Hayward  <alan.hayward@arm.com>
3996             David Sherwood  <david.sherwood@arm.com>
3998         * combine.c (extract_left_shift): Add a mode argument and update
3999         recursive calls.
4000         (make_compound_operation_int): Change the type of the mode parameter
4001         to scalar_int_mode and update the call to extract_left_shift.
4003 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
4004             Alan Hayward  <alan.hayward@arm.com>
4005             David Sherwood  <david.sherwood@arm.com>
4007         * combine.c (simplify_and_const_int): Change the type of the mode
4008         parameter to scalar_int_mode.
4009         (simplify_and_const_int_1): Likewise.  Update recursive call.
4011 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
4012             Alan Hayward  <alan.hayward@arm.com>
4013             David Sherwood  <david.sherwood@arm.com>
4015         * combine.c (simplify_compare_const): Check that the mode is a
4016         scalar_int_mode (rather than VOIDmode) before testing its
4017         precision.
4018         (simplify_comparison): Move COMPARISON_P handling out of the
4019         loop and restrict the latter part of the loop to scalar_int_modes.
4020         Check is_a <scalar_int_mode> before calling HWI_COMPUTABLE_MODE_P
4021         and when considering SUBREG_REGs.  Use is_int_mode instead of
4022         checking GET_MODE_CLASS against MODE_INT.
4024 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
4025             Alan Hayward  <alan.hayward@arm.com>
4026             David Sherwood  <david.sherwood@arm.com>
4028         * combine.c (try_widen_shift_mode): Move check for equal modes to...
4029         (simplify_shift_const_1): ...here.  Use scalar_int_mode for
4030         shift_unit_mode and for modes involved in scalar shifts.
4032 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
4033             Alan Hayward  <alan.hayward@arm.com>
4034             David Sherwood  <david.sherwood@arm.com>
4036         * combine.c (force_int_to_mode): New function, split out from...
4037         (force_to_mode): ...here.  Keep xmode up-to-date and use it
4038         instead of GET_MODE (x).
4040 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
4041             Alan Hayward  <alan.hayward@arm.com>
4042             David Sherwood  <david.sherwood@arm.com>
4044         * optabs-query.h (extraction_insn::struct_mode): Change type to
4045         opt_scalar_int_mode and update comment.
4046         (extraction_insn::field_mode): Change type to scalar_int_mode.
4047         (extraction_insn::pos_mode): Likewise.
4048         * combine.c (make_extraction): Update accordingly.
4049         * optabs-query.c (get_traditional_extraction_insn): Likewise.
4050         (get_optab_extraction_insn): Likewise.
4051         * recog.c (simplify_while_replacing): Likewise.
4052         * expmed.c (narrow_bit_field_mem): Change the type of the mode
4053         parameter to opt_scalar_int_mode.
4055 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
4056             Alan Hayward  <alan.hayward@arm.com>
4057             David Sherwood  <david.sherwood@arm.com>
4059         * machmode.h (bit_field_mode_iterator::next_mode): Take a pointer
4060         to a scalar_int_mode instead of a machine_mode.
4061         (bit_field_mode_iterator::m_mode): Change type to opt_scalar_int_mode.
4062         (get_best_mode): Return a boolean and use a pointer argument to store
4063         the selected mode.  Replace the limit mode parameter with a bit limit.
4064         * expmed.c (adjust_bit_field_mem_for_reg): Use scalar_int_mode
4065         for the values returned by bit_field_mode_iterator::next_mode.
4066         (store_bit_field): Update call to get_best_mode.
4067         (store_fixed_bit_field): Likewise.
4068         (extract_fixed_bit_field): Likewise.
4069         * expr.c (optimize_bitfield_assignment_op): Likewise.
4070         * fold-const.c (optimize_bit_field_compare): Likewise.
4071         (fold_truth_andor_1): Likewise.
4072         * stor-layout.c (bit_field_mode_iterator::next_mode): As above.
4073         Update for new type of m_mode.
4074         (get_best_mode): As above.
4076 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
4077             Alan Hayward  <alan.hayward@arm.com>
4078             David Sherwood  <david.sherwood@arm.com>
4080         * expmed.c (strict_volatile_bitfield_p): Change the type of fieldmode
4081         to scalar_int_mode.  Remove check for SCALAR_INT_MODE_P.
4082         (store_bit_field): Check is_a <scalar_int_mode> before calling
4083         strict_volatile_bitfield_p.
4084         (extract_bit_field): Likewise.
4086 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
4087             Alan Hayward  <alan.hayward@arm.com>
4088             David Sherwood  <david.sherwood@arm.com>
4090         * target.def (cstore_mode): Return a scalar_int_mode.
4091         * doc/tm.texi: Regenerate.
4092         * config/sparc/sparc.c (sparc_cstore_mode): Return a scalar_int_mode.
4093         * targhooks.h (default_cstore_mode): Likewise.
4094         * targhooks.c (default_cstore_mode): Likewise, using a forced
4095         conversion.
4096         * expmed.c (emit_cstore): Expect the target of the cstore to be
4097         a scalar_int_mode.
4099 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
4100             Alan Hayward  <alan.hayward@arm.com>
4101             David Sherwood  <david.sherwood@arm.com>
4103         * cfgloop.h (rtx_iv): Change type of extend_mode and mode to
4104         scalar_int_mode.
4105         (niter_desc): Likewise mode.
4106         (iv_analyze): Add a mode parameter.
4107         (biv_p): Likewise.
4108         (iv_analyze_expr): Pass the mode paraeter before the rtx it describes
4109         and change its type to scalar_int_mode.
4110         * loop-iv.c: Update commentary at head of file.
4111         (iv_constant): Pass the mode paraeter before the rtx it describes
4112         and change its type to scalar_int_mode.  Remove VOIDmode handling.
4113         (iv_subreg): Change the type of the mode parameter to scalar_int_mode.
4114         (iv_extend): Likewise.
4115         (shorten_into_mode): Likewise.
4116         (iv_add): Use scalar_int_mode.
4117         (iv_mult): Likewise.
4118         (iv_shift): Likewise.
4119         (canonicalize_iv_subregs): Likewise.
4120         (get_biv_step_1): Pass the outer_mode parameter before the rtx
4121         it describes and change its mode to scalar_int_mode.   Also change
4122         the type of the returned inner_mode to scalar_int_mode.
4123         (get_biv_step): Likewise, turning outer_mode from a pointer
4124         into a direct parameter.  Update call to get_biv_step_1.
4125         (iv_analyze_biv): Add an outer_mode parameter.  Update calls to
4126         iv_constant and get_biv_step.
4127         (iv_analyze_expr): Pass the mode parameter before the rtx it describes
4128         and change its type to scalar_int_mode.  Don't initialise iv->mode
4129         to VOIDmode and remove later checks for its still being VOIDmode.
4130         Update calls to iv_analyze_op and iv_analyze_expr.  Check
4131         is_a <scalar_int_mode> when changing the mode under consideration.
4132         (iv_analyze_def): Ignore registers that don't have a scalar_int_mode.
4133         Update call to iv_analyze_expr.
4134         (iv_analyze_op): Add a mode parameter.  Reject subregs whose
4135         inner register is not also a scalar_int_mode.  Update call to
4136         iv_analyze_biv.
4137         (iv_analyze): Add a mode parameter.  Update call to iv_analyze_op.
4138         (biv_p): Add a mode parameter.  Update call to iv_analyze_biv.
4139         (iv_number_of_iterations): Use is_a <scalar_int_mode> instead of
4140         separate mode class checks.  Update calls to iv_analyze.  Remove
4141         fix-up of VOIDmodes after iv_analyze_biv.
4142         * loop-unroll.c (analyze_iv_to_split_insn): Reject registers that
4143         don't have a scalar_int_mode.  Update call to biv_p.
4145 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
4146             Alan Hayward  <alan.hayward@arm.com>
4147             David Sherwood  <david.sherwood@arm.com>
4149         * cfgexpand.c (convert_debug_memory_address): Use
4150         as_a <scalar_int_mode>.
4151         * combine.c (expand_compound_operation): Likewise.
4152         (make_extraction): Likewise.
4153         (change_zero_ext): Likewise.
4154         (simplify_comparison): Likewise.
4155         * cse.c (cse_insn): Likewise.
4156         * dwarf2out.c (minmax_loc_descriptor): Likewise.
4157         (mem_loc_descriptor): Likewise.
4158         (loc_descriptor): Likewise.
4159         * expmed.c (init_expmed_one_mode): Likewise.
4160         (synth_mult): Likewise.
4161         (emit_store_flag_1): Likewise.
4162         (expand_divmod): Likewise.  Use HWI_COMPUTABLE_MODE_P instead
4163         of a comparison with size.
4164         * expr.c (expand_assignment): Use as_a <scalar_int_mode>.
4165         (reduce_to_bit_field_precision): Likewise.
4166         * function.c (expand_function_end): Likewise.
4167         * internal-fn.c (expand_arith_overflow_result_store): Likewise.
4168         * loop-doloop.c (doloop_modify): Likewise.
4169         * optabs.c (expand_binop): Likewise.
4170         (expand_unop): Likewise.
4171         (expand_copysign_absneg): Likewise.
4172         (prepare_cmp_insn): Likewise.
4173         (maybe_legitimize_operand): Likewise.
4174         * recog.c (const_scalar_int_operand): Likewise.
4175         * rtlanal.c (get_address_mode): Likewise.
4176         * simplify-rtx.c (simplify_unary_operation_1): Likewise.
4177         (simplify_cond_clz_ctz): Likewise.
4178         * tree-nested.c (get_nl_goto_field): Likewise.
4179         * tree.c (build_vector_type_for_mode): Likewise.
4180         * var-tracking.c (use_narrower_mode): Likewise.
4182 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
4183             Alan Hayward  <alan.hayward@arm.com>
4184             David Sherwood  <david.sherwood@arm.com>
4186         * tree.h (SCALAR_INT_TYPE_MODE): New macro.
4187         * builtins.c (expand_builtin_signbit): Use it.
4188         * cfgexpand.c (expand_debug_expr): Likewise.
4189         * dojump.c (do_jump): Likewise.
4190         (do_compare_and_jump): Likewise.
4191         * dwarf2cfi.c (expand_builtin_init_dwarf_reg_sizes): Likewise.
4192         * expmed.c (make_tree): Likewise.
4193         * expr.c (expand_expr_real_2): Likewise.
4194         (expand_expr_real_1): Likewise.
4195         (try_casesi): Likewise.
4196         * fold-const-call.c (fold_const_call_ss): Likewise.
4197         * fold-const.c (unextend): Likewise.
4198         (extract_muldiv_1): Likewise.
4199         (fold_single_bit_test): Likewise.
4200         (native_encode_int): Likewise.
4201         (native_encode_string): Likewise.
4202         (native_interpret_int): Likewise.
4203         * gimple-fold.c (gimple_fold_builtin_memset): Likewise.
4204         * internal-fn.c (expand_addsub_overflow): Likewise.
4205         (expand_neg_overflow): Likewise.
4206         (expand_mul_overflow): Likewise.
4207         (expand_arith_overflow): Likewise.
4208         * match.pd: Likewise.
4209         * stor-layout.c (layout_type): Likewise.
4210         * tree-cfg.c (verify_gimple_assign_ternary): Likewise.
4211         * tree-ssa-math-opts.c (convert_mult_to_widen): Likewise.
4212         * tree-ssanames.c (get_range_info): Likewise.
4213         * tree-switch-conversion.c (array_value_type) Likewise.
4214         * tree-vect-patterns.c (vect_recog_rotate_pattern): Likewise.
4215         (vect_recog_divmod_pattern): Likewise.
4216         (vect_recog_mixed_size_cond_pattern): Likewise.
4217         * tree-vrp.c (extract_range_basic): Likewise.
4218         (simplify_float_conversion_using_ranges): Likewise.
4219         * tree.c (int_fits_type_p): Likewise.
4220         * ubsan.c (instrument_bool_enum_load): Likewise.
4221         * varasm.c (mergeable_string_section): Likewise.
4222         (narrowing_initializer_constant_valid_p): Likewise.
4223         (output_constant): Likewise.
4225 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
4226             Alan Hayward  <alan.hayward@arm.com>
4227             David Sherwood  <david.sherwood@arm.com>
4229         * machmode.h (NARROWEST_INT_MODE): New macro.
4230         * expr.c (alignment_for_piecewise_move): Use it instead of
4231         GET_CLASS_NARROWEST_MODE (MODE_INT).
4232         (push_block): Likewise.
4233         * stor-layout.c (bit_field_mode_iterator::bit_field_mode_iterator):
4234         Likewise.
4235         * tree-vrp.c (simplify_float_conversion_using_ranges): Likewise.
4237 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
4238             Alan Hayward  <alan.hayward@arm.com>
4239             David Sherwood  <david.sherwood@arm.com>
4241         * postreload.c (move2add_valid_value_p): Change the type of the
4242         mode parameter to scalar_int_mode.
4243         (move2add_use_add2_insn): Add a mode parameter and use it instead
4244         of GET_MODE (reg).
4245         (move2add_use_add3_insn): Likewise.
4246         (reload_cse_move2add): Update accordingly.
4248 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
4249             Alan Hayward  <alan.hayward@arm.com>
4250             David Sherwood  <david.sherwood@arm.com>
4252         * expr.c (expand_expr_real_2): Use scalar_int_mode for the
4253         double-word mode.
4254         * lower-subreg.c (resolve_shift_zext): Use is_a <scalar_int_mode>.
4255         * optabs.c (expand_unop): Likewise.
4257 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
4258             Alan Hayward  <alan.hayward@arm.com>
4259             David Sherwood  <david.sherwood@arm.com>
4261         * dwarf2out.c (typed_binop): Change mode parameter to scalar_int_mode.
4262         (clz_loc_descriptor): Likewise.  Remove SCALAR_INT_MODE_P check.
4263         (popcount_loc_descriptor): Likewise.
4264         (bswap_loc_descriptor): Likewise.
4265         (rotate_loc_descriptor): Likewise.
4266         (mem_loc_descriptor): Add is_a <scalar_int_mode> checks before
4267         calling the functions above.
4269 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
4270             Alan Hayward  <alan.hayward@arm.com>
4271             David Sherwood  <david.sherwood@arm.com>
4273         * combine.c (sign_extend_short_imm): Add is_a <scalar_int_mode>
4274         checks.
4275         (try_combine): Likewise.
4276         (simplify_if_then_else): Likewise.
4277         * cse.c (cse_insn): Likewise.
4278         * dwarf2out.c (mem_loc_descriptor): Likewise.
4279         * emit-rtl.c (gen_lowpart_common): Likewise.
4280         * simplify-rtx.c (simplify_truncation): Likewise.
4281         (simplify_binary_operation_1): Likewise.
4282         (simplify_const_relational_operation): Likewise.
4283         (simplify_ternary_operation): Likewise.
4284         * tree-ssa-loop-ivopts.c (force_expr_to_var_cost): Likewise.
4286 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
4287             Alan Hayward  <alan.hayward@arm.com>
4288             David Sherwood  <david.sherwood@arm.com>
4290         * cse.c (cse_insn): Add is_a <scalar_int_mode> checks.
4291         * reload.c (push_reload): Likewise.
4292         (find_reloads): Likewise.
4294 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
4295             Alan Hayward  <alan.hayward@arm.com>
4296             David Sherwood  <david.sherwood@arm.com>
4298         * combine.c (find_split_point): Add is_a <scalar_int_mode> checks.
4299         (make_compound_operation_int): Likewise.
4300         (change_zero_ext): Likewise.
4301         * expr.c (convert_move): Likewise.
4302         (convert_modes): Likewise.
4303         * fwprop.c (forward_propagate_subreg): Likewise.
4304         * loop-iv.c (get_biv_step_1): Likewise.
4305         * optabs.c (widen_operand): Likewise.
4306         * postreload.c (move2add_valid_value_p): Likewise.
4307         * recog.c (simplify_while_replacing): Likewise.
4308         * simplify-rtx.c (simplify_unary_operation_1): Likewise.
4309         (simplify_binary_operation_1): Likewise.  Remove redundant
4310         mode equality check.
4312 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
4313             Alan Hayward  <alan.hayward@arm.com>
4314             David Sherwood  <david.sherwood@arm.com>
4316         * combine.c (combine_simplify_rtx): Add checks for
4317         is_a <scalar_int_mode>.
4318         (simplify_if_then_else): Likewise.
4319         (make_field_assignment): Likewise.
4320         (simplify_comparison): Likewise.
4321         * ifcvt.c (noce_try_bitop): Likewise.
4322         * loop-invariant.c (canonicalize_address_mult): Likewise.
4323         * simplify-rtx.c (simplify_unary_operation_1): Likewise.
4325 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
4326             Alan Hayward  <alan.hayward@arm.com>
4327             David Sherwood  <david.sherwood@arm.com>
4329         * gimple-fold.c (gimple_fold_builtin_memory_op): Use
4330         is_a <scalar_int_mode> instead of != BLKmode.
4332 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
4333             Alan Hayward  <alan.hayward@arm.com>
4334             David Sherwood  <david.sherwood@arm.com>
4336         * cfgexpand.c (expand_debug_expr): Use is_a <scalar_int_mode>
4337         instead of != VOIDmode.
4338         * combine.c (if_then_else_cond): Likewise.
4339         (change_zero_ext): Likewise.
4340         * dwarf2out.c (mem_loc_descriptor): Likewise.
4341         (loc_descriptor): Likewise.
4342         * rtlanal.c (canonicalize_condition): Likewise.
4343         * simplify-rtx.c (simplify_relational_operation_1): Likewise.
4345 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
4346             Alan Hayward  <alan.hayward@arm.com>
4347             David Sherwood  <david.sherwood@arm.com>
4349         * simplify-rtx.c (simplify_binary_operation_1): Use
4350         is_a <scalar_int_mode> instead of !VECTOR_MODE_P.
4352 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
4353             Alan Hayward  <alan.hayward@arm.com>
4354             David Sherwood  <david.sherwood@arm.com>
4356         * wide-int.h (int_traits<unsigned char>) New class.
4357         (int_traits<unsigned short>) Likewise.
4358         * cfgexpand.c (expand_debug_expr): Use is_a <scalar_int_mode>.
4359         Use GET_MODE_UNIT_PRECISION and remove redundant test for
4360         SCALAR_INT_MODE_P.
4361         * combine.c (set_nonzero_bits_and_sign_copies): Use
4362         is_a <scalar_int_mode>.
4363         (find_split_point): Likewise.
4364         (combine_simplify_rtx): Likewise.
4365         (simplify_logical): Likewise.
4366         (expand_compound_operation): Likewise.
4367         (expand_field_assignment): Likewise.
4368         (make_compound_operation): Likewise.
4369         (extended_count): Likewise.
4370         (change_zero_ext): Likewise.
4371         (simplify_comparison): Likewise.
4372         * dwarf2out.c (scompare_loc_descriptor): Likewise.
4373         (ucompare_loc_descriptor): Likewise.
4374         (minmax_loc_descriptor): Likewise.
4375         (mem_loc_descriptor): Likewise.
4376         (loc_descriptor): Likewise.
4377         * expmed.c (init_expmed_one_mode): Likewise.
4378         * lra-constraints.c (lra_constraint_offset): Likewise.
4379         * optabs.c (prepare_libcall_arg): Likewise.
4380         * postreload.c (move2add_note_store): Likewise.
4381         * reload.c (operands_match_p): Likewise.
4382         * rtl.h (load_extend_op): Likewise.
4383         * rtlhooks.c (gen_lowpart_general): Likewise.
4384         * simplify-rtx.c (simplify_truncation): Likewise.
4385         (simplify_unary_operation_1): Likewise.
4386         (simplify_binary_operation_1): Likewise.
4387         (simplify_const_binary_operation): Likewise.
4388         (simplify_const_relational_operation): Likewise.
4389         (simplify_subreg): Likewise.
4390         * stor-layout.c (bitwise_mode_for_mode): Likewise.
4391         * var-tracking.c (adjust_mems): Likewise.
4392         (prepare_call_arguments): Likewise.
4394 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
4395             Alan Hayward  <alan.hayward@arm.com>
4396             David Sherwood  <david.sherwood@arm.com>
4398         * machmode.h (is_int_mode): New fuction.
4399         * combine.c (find_split_point): Use it.
4400         (combine_simplify_rtx): Likewise.
4401         (simplify_if_then_else): Likewise.
4402         (simplify_set): Likewise.
4403         (simplify_shift_const_1): Likewise.
4404         (simplify_comparison): Likewise.
4405         * config/aarch64/aarch64.c (aarch64_rtx_costs): Likewise.
4406         * cse.c (notreg_cost): Likewise.
4407         (cse_insn): Likewise.
4408         * cselib.c (cselib_lookup_1): Likewise.
4409         * dojump.c (do_jump_1): Likewise.
4410         (do_compare_rtx_and_jump): Likewise.
4411         * dse.c (get_call_args): Likewise.
4412         * dwarf2out.c (rtl_for_decl_init): Likewise.
4413         (native_encode_initializer): Likewise.
4414         * expmed.c (emit_store_flag_1): Likewise.
4415         (emit_store_flag): Likewise.
4416         * expr.c (convert_modes): Likewise.
4417         (store_field): Likewise.
4418         (expand_expr_real_1): Likewise.
4419         * fold-const.c (fold_read_from_constant_string): Likewise.
4420         * gimple-ssa-sprintf.c (get_format_string): Likewise.
4421         * optabs-libfuncs.c (gen_int_libfunc): Likewise.
4422         * optabs.c (expand_binop): Likewise.
4423         (expand_unop): Likewise.
4424         (expand_abs_nojump): Likewise.
4425         (expand_one_cmpl_abs_nojump): Likewise.
4426         * simplify-rtx.c (mode_signbit_p): Likewise.
4427         (val_signbit_p): Likewise.
4428         (val_signbit_known_set_p): Likewise.
4429         (val_signbit_known_clear_p): Likewise.
4430         (simplify_relational_operation_1): Likewise.
4431         * tree.c (vector_type_mode): Likewise.
4433 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
4434             Alan Hayward  <alan.hayward@arm.com>
4435             David Sherwood  <david.sherwood@arm.com>
4437         * machmode.h (smallest_mode_for_size): Fix formatting.
4438         (smallest_int_mode_for_size): New function.
4439         * cfgexpand.c (expand_debug_expr): Use smallest_int_mode_for_size
4440         instead of smallest_mode_for_size.
4441         * combine.c (make_extraction): Likewise.
4442         * config/arc/arc.c (arc_expand_movmem): Likewise.
4443         * config/arm/arm.c (arm_expand_divmod_libfunc): Likewise.
4444         * config/i386/i386.c (ix86_get_mask_mode): Likewise.
4445         * config/s390/s390.c (s390_expand_insv): Likewise.
4446         * config/sparc/sparc.c (assign_int_registers): Likewise.
4447         * config/spu/spu.c (spu_function_value): Likewise.
4448         (spu_function_arg): Likewise.
4449         * coverage.c (get_gcov_type): Likewise.
4450         (get_gcov_unsigned_t): Likewise.
4451         * dse.c (find_shift_sequence): Likewise.
4452         * expmed.c (store_bit_field_1): Likewise.
4453         * expr.c (convert_move): Likewise.
4454         (store_field): Likewise.
4455         * internal-fn.c (expand_arith_overflow): Likewise.
4456         * optabs-query.c (get_best_extraction_insn): Likewise.
4457         * optabs.c (expand_twoval_binop_libfunc): Likewise.
4458         * stor-layout.c (layout_type): Likewise.
4459         (initialize_sizetypes): Likewise.
4460         * targhooks.c (default_get_mask_mode): Likewise.
4461         * tree-ssa-loop-manip.c (canonicalize_loop_ivs): Likewise.
4463 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
4464             Alan Hayward  <alan.hayward@arm.com>
4465             David Sherwood  <david.sherwood@arm.com>
4467         * machmode.h (opt_mode::else_blk): New function.
4468         (int_mode_for_mode): Declare.
4469         * stor-layout.c (int_mode_for_mode): Return an opt_scalar_int_mode.
4470         * builtins.c (expand_builtin_signbit): Adjust for new int_mode_for_mode
4471         return type.
4472         * cfgexpand.c (expand_debug_expr): Likewise.
4473         * combine.c (gen_lowpart_or_truncate): Likewise.
4474         (gen_lowpart_for_combine): Likewise.
4475         * config/aarch64/aarch64.c (aarch64_emit_approx_sqrt): Likewise.
4476         * config/avr/avr.c (avr_to_int_mode): Likewise.
4477         (avr_out_plus_1): Likewise.
4478         (avr_out_plus): Likewise.
4479         (avr_out_round): Likewise.
4480         * config/i386/i386.c (ix86_split_to_parts): Likewise.
4481         * config/s390/s390.c (s390_expand_vec_compare_cc): Likewise.
4482         (s390_expand_vcond): Likewise.
4483         * config/spu/spu.c (spu_split_immediate): Likewise.
4484         (spu_expand_mov): Likewise.
4485         * dse.c (get_stored_val): Likewise.
4486         * expmed.c (store_bit_field_1): Likewise.
4487         (convert_extracted_bit_field): Use int_mode_for_mode instead of
4488         int_mode_for_size.
4489         (extract_bit_field_1): Adjust for new int_mode_for_mode return type.
4490         (extract_low_bits): Likewise.
4491         * expr.c (emit_group_load_1): Likewise.  Separate out the BLKmode
4492         handling rather than repeating the check.
4493         (emit_group_store): Likewise.
4494         (emit_move_via_integer): Adjust for new int_mode_for_mode return type.
4495         * optabs.c (expand_absneg_bit): Likewise.
4496         (expand_copysign_absneg): Likewise.
4497         (expand_copysign_bit): Likewise.
4498         * tree-if-conv.c (ifcvt_can_use_mask_load_store): Likewise.
4499         * tree-vect-slp.c (vect_transform_slp_perm_load): Likewise.
4500         * tree-vect-stmts.c (vect_gen_perm_mask_any): Likewise.
4501         * var-tracking.c (prepare_call_arguments):  Likewise.
4502         * config/powerpcspe/powerpcspe.c (rs6000_do_expand_vec_perm): Use
4503         int_mode_for_mode instead of mode_for_size.
4504         * config/rs6000/rs6000.c (rs6000_do_expand_vec_perm): Likewise.
4506 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
4507             Alan Hayward  <alan.hayward@arm.com>
4508             David Sherwood  <david.sherwood@arm.com>
4510         * machmode.h (int_mode_for_size): New function.
4511         * builtins.c (set_builtin_user_assembler_name): Use int_mode_for_size
4512         instead of mode_for_size.
4513         * calls.c (save_fixed_argument_area): Likewise.  Make use of BLKmode
4514         explicit.
4515         * combine.c (expand_field_assignment): Use int_mode_for_size
4516         instead of mode_for_size.
4517         (make_extraction): Likewise.
4518         (simplify_shift_const_1): Likewise.
4519         (simplify_comparison): Likewise.
4520         * dojump.c (do_jump): Likewise.
4521         * dwarf2out.c (mem_loc_descriptor): Likewise.
4522         * emit-rtl.c (init_derived_machine_modes): Likewise.
4523         * expmed.c (flip_storage_order): Likewise.
4524         (convert_extracted_bit_field): Likewise.
4525         * expr.c (copy_blkmode_from_reg): Likewise.
4526         * graphite-isl-ast-to-gimple.c (max_mode_int_precision): Likewise.
4527         * internal-fn.c (expand_mul_overflow): Likewise.
4528         * lower-subreg.c (simple_move): Likewise.
4529         * optabs-libfuncs.c (init_optabs): Likewise.
4530         * simplify-rtx.c (simplify_unary_operation_1): Likewise.
4531         * tree.c (vector_type_mode): Likewise.
4532         * tree-ssa-strlen.c (handle_builtin_memcmp): Likewise.
4533         * tree-vect-data-refs.c (vect_lanes_optab_supported_p): Likewise.
4534         * tree-vect-generic.c (expand_vector_parallel): Likewise.
4535         * tree-vect-stmts.c (vectorizable_load): Likewise.
4536         (vectorizable_store): Likewise.
4538 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
4539             Alan Hayward  <alan.hayward@arm.com>
4540             David Sherwood  <david.sherwood@arm.com>
4542         * coretypes.h (pod_mode): New type.
4543         (scalar_int_mode_pod): New typedef.
4544         * machmode.h (pod_mode): New class.
4545         (int_n_data_t::m): Change type to scalar_int_mode_pod.
4546         * genmodes.c (emit_mode_int_n): Update accordingly.
4547         * lower-subreg.h (target_lower_subreg): Change type to
4548         scalar_int_mode_pod.
4549         * gdbhooks.py (build_pretty_printer): Handle pod_mode and
4550         scalar_int_mode_pod.
4552 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
4553             Alan Hayward  <alan.hayward@arm.com>
4554             David Sherwood  <david.sherwood@arm.com>
4556         * config/powerpcspe/powerpcspe.h (rs6000_pmode): Change type from
4557         machine_mode to scalar_int_mode.
4558         * config/powerpcspe/powerpcspe.c (rs6000_pmode): Likewise.
4559         (rs6000_option_override_internal): Remove cast to int.
4560         * config/rs6000/rs6000.h (rs6000_pmode): Change type from
4561         machine_mode to scalar_int_mode.
4562         * config/rs6000/rs6000.c (rs6000_pmode): Likewise.
4563         (rs6000_option_override_internal): Remove cast to int.
4564         * config/s390/s390.h (Pmode): Remove cast to machine_mode.
4565         * config/epiphany/epiphany.h (RTX_OK_FOR_OFFSET_P): Add cast
4566         to machine_mode.
4567         * config/s390/s390.c (s390_expand_builtin): Likewise.
4568         * coretypes.h (scalar_int_mode): New type.
4569         (opt_scalar_int_mode): New typedef.
4570         * machmode.h (scalar_int_mode): New class.
4571         (scalar_int_mode::includes_p): New function.
4572         (byte_mode): Change type to scalar_int_mode.
4573         (word_mode): Likewise.
4574         (ptr_mode): Likewise.
4575         * emit-rtl.c (byte_mode): Likewise.
4576         (word_mode): Likewise.
4577         (ptr_mode): Likewise.
4578         (init_derived_machine_modes): Update accordingly.
4579         * genmodes.c (get_mode_class): Return scalar_int_mode for MODE_INT
4580         and MODE_PARTIAL_INT.
4581         * gdbhooks.py (build_pretty_printer): Handle scalar_int_mode and
4582         opt_scalar_int_mode.
4584 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
4585             Alan Hayward  <alan.hayward@arm.com>
4586             David Sherwood  <david.sherwood@arm.com>
4588         * target.def (libgcc_floating_mode_supported_p): Take a
4589         scalar_float_mode.
4590         * doc/tm.texi: Regenerate.
4591         * targhooks.h (default_libgcc_floating_mode_supported_p): Take a
4592         scalar_float_mode.
4593         * targhooks.c (default_libgcc_floating_mode_supported_p): Likewise.
4594         * config/aarch64/aarch64.c (aarch64_libgcc_floating_mode_supported_p):
4595         Likewise.
4597 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
4598             Alan Hayward  <alan.hayward@arm.com>
4599             David Sherwood  <david.sherwood@arm.com>
4601         * target.def (default_floatn_mode): Return an opt_scalar_float_mode.
4602         * doc/tm.texi: Regenerate.
4603         * config/arm/arm.c (arm_floatn_mode): Return an opt_scalar_float_mode.
4604         * config/powerpcspe/powerpcspe.c (rs6000_floatn_mode): Likewise.
4605         * config/rs6000/rs6000.c (rs6000_floatn_mode): Likewise.
4606         * targhooks.h (default_floatn_mode): Likewise.
4607         * targhooks.c (default_floatn_mode): Likewise.
4608         * tree.c (build_common_tree_nodes): Update accordingly.
4610 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
4611             Alan Hayward  <alan.hayward@arm.com>
4612             David Sherwood  <david.sherwood@arm.com>
4614         * machmode.h (mode_iterator::start): Provide overload for opt_modes.
4615         (mode_iterator::iterate_p): Likewise.
4616         (mode_iterator::get_wider): Likewise.
4617         * expr.c (init_expr_target): Use opt_scalar_float_mode.
4619 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
4620             Alan Hayward  <alan.hayward@arm.com>
4621             David Sherwood  <david.sherwood@arm.com>
4623         * coretypes.h (opt_scalar_float_mode): New typedef.
4624         * machmode.h (float_mode_for_size): New function.
4625         * emit-rtl.c (double_mode): Delete.
4626         (init_emit_once): Use float_mode_for_size.
4627         * stor-layout.c (layout_type): Likewise.
4628         * gdbhooks.py (build_pretty_printer): Handle opt_scalar_float_mode.
4630 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
4631             Alan Hayward  <alan.hayward@arm.com>
4632             David Sherwood  <david.sherwood@arm.com>
4634         * output.h (assemble_real): Take a scalar_float_mode.
4635         * config/arm/arm.c (arm_assemble_integer): Update accordingly.
4636         * config/arm/arm.md (consttable_4): Likewise.
4637         (consttable_8): Likewise.
4638         (consttable_16): Likewise.
4639         * config/mips/mips.md (consttable_float): Likewise.
4640         * config/s390/s390.c (s390_output_pool_entry): Likewise.
4641         * varasm.c (assemble_real): Take a scalar_float_mode.
4642         (output_constant_pool_2): Update accordingly.
4643         (output_constant): Likewise.
4645 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
4646             Alan Hayward  <alan.hayward@arm.com>
4647             David Sherwood  <david.sherwood@arm.com>
4649         * tree.h (SCALAR_FLOAT_TYPE_MODE): New macro.
4650         * builtins.c (expand_builtin_signbit): Use it instead of TYPE_MODE.
4651         * fold-const.c (fold_convert_const_real_from_fixed): Likewise.
4652         (native_encode_real): Likewise.
4653         (native_interpret_real): Likewise.
4654         * hsa-brig.c (emit_immediate_scalar_to_buffer): Likewise.
4655         * tree-vrp.c (simplify_float_conversion_using_ranges): Likewise.
4657 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
4658             Alan Hayward  <alan.hayward@arm.com>
4659             David Sherwood  <david.sherwood@arm.com>
4661         * optabs-libfuncs.c (gen_trunc_conv_libfunc): Use is_a
4662         <scalar_float_mode>.  Simplify.
4663         (gen_extend_conv_libfunc): Likewise.
4665 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
4666             Alan Hayward  <alan.hayward@arm.com>
4667             David Sherwood  <david.sherwood@arm.com>
4669         * coretypes.h (scalar_float_mode): New type.
4670         * machmode.h (mode_traits::from_int): Use machine_mode if
4671         USE_ENUM_MODES is defined.
4672         (is_a): New function.
4673         (as_a): Likewise.
4674         (dyn_cast): Likewise.
4675         (scalar_float_mode): New class.
4676         (scalar_float_mode::includes_p): New function.
4677         (is_float_mode): Likewise.
4678         * gdbhooks.py (MachineModePrinter): New class.
4679         (build_pretty_printer): Use it for scalar_float_mode.
4680         * real.h (FLOAT_MODE_FORMAT): Use as_a <scalar_float_mode>.
4681         (format_helper::format_helper): Turn into a template.
4682         * genmodes.c (get_mode_class): New function.
4683         (emit_insn_modes_h): Give modes the class returned by get_mode_class,
4684         or machine_mode if none.
4685         * config/aarch64/aarch64.c (aarch64_simd_valid_immediate): Use
4686         as_a <scalar_float_mode>.
4687         * dwarf2out.c (mem_loc_descriptor): Likewise.
4688         (insert_float): Likewise.
4689         (add_const_value_attribute): Likewise.
4690         * simplify-rtx.c (simplify_immed_subreg): Likewise.
4691         * optabs.c (expand_absneg_bit): Take a scalar_float_mode.
4692         (expand_unop): Update accordingly.
4693         (expand_abs_nojump): Likewise.
4694         (expand_copysign_absneg): Take a scalar_float_mode.
4695         (expand_copysign_bit): Likewise.
4696         (expand_copysign): Update accordingly.
4698 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
4699             Alan Hayward  <alan.hayward@arm.com>
4700             David Sherwood  <david.sherwood@arm.com>
4702         * coretypes.h (opt_mode): New class.
4703         * machmode.h (opt_mode): Likewise.
4704         (opt_mode::else_void): New function.
4705         (opt_mode::require): Likewise.
4706         (opt_mode::exists): Likewise.
4707         (GET_MODE_WIDER_MODE): Turn into a function and return an opt_mode.
4708         (GET_MODE_2XWIDER_MODE): Likewise.
4709         (mode_iterator::get_wider): Update accordingly.
4710         (mode_iterator::get_2xwider): Likewise.
4711         (mode_iterator::get_known_wider): Likewise, turning into a template.
4712         * combine.c (make_extraction): Update use of GET_MODE_WIDER_MODE,
4713         forcing a wider mode to exist.
4714         * config/cr16/cr16.h (LONG_REG_P): Likewise.
4715         * rtlanal.c (init_num_sign_bit_copies_in_rep): Likewise.
4716         * config/c6x/c6x.c (c6x_rtx_costs): Update use of
4717         GET_MODE_2XWIDER_MODE, forcing a wider mode to exist.
4718         * lower-subreg.c (init_lower_subreg): Likewise.
4719         * optabs-libfuncs.c (init_sync_libfuncs_1): Likewise, but not
4720         on the final iteration.
4721         * config/i386/i386.c (ix86_expand_set_or_movmem): Check whether
4722         a wider mode exists before asking for a move pattern.
4723         (get_mode_wider_vector): Update use of GET_MODE_WIDER_MODE,
4724         forcing a wider mode to exist.
4725         (expand_vselect_vconcat): Update use of GET_MODE_2XWIDER_MODE,
4726         returning false if no such mode exists.
4727         * config/ia64/ia64.c (expand_vselect_vconcat): Likewise.
4728         * config/mips/mips.c (mips_expand_vselect_vconcat): Likewise.
4729         * expmed.c (init_expmed_one_mode): Update use of GET_MODE_WIDER_MODE.
4730         Avoid checking for a MODE_INT if we already know the mode is not a
4731         SCALAR_INT_MODE_P.
4732         (extract_high_half): Update use of GET_MODE_WIDER_MODE,
4733         forcing a wider mode to exist.
4734         (expmed_mult_highpart_optab): Likewise.
4735         (expmed_mult_highpart): Likewise.
4736         * expr.c (expand_expr_real_2): Update use of GET_MODE_WIDER_MODE,
4737         using else_void.
4738         * lto-streamer-in.c (lto_input_mode_table): Likewise.
4739         * optabs-query.c (find_widening_optab_handler_and_mode): Likewise.
4740         * stor-layout.c (bit_field_mode_iterator::next_mode): Likewise.
4741         * internal-fn.c (expand_mul_overflow): Update use of
4742         GET_MODE_2XWIDER_MODE.
4743         * omp-low.c (omp_clause_aligned_alignment): Likewise.
4744         * tree-ssa-math-opts.c (convert_mult_to_widen): Update use of
4745         GET_MODE_WIDER_MODE.
4746         (convert_plusminus_to_widen): Likewise.
4747         * tree-switch-conversion.c (array_value_type): Likewise.
4748         * var-tracking.c (emit_note_insn_var_location): Likewise.
4749         * tree-vrp.c (simplify_float_conversion_using_ranges): Likewise.
4750         Return false inside rather than outside the loop if no wider mode
4751         exists
4752         * optabs.c (expand_binop): Update use of GET_MODE_WIDER_MODE
4753         and GET_MODE_2XWIDER_MODE
4754         (can_compare_p): Use else_void.
4755         * gdbhooks.py (OptMachineModePrinter): New class.
4756         (build_pretty_printer): Use it for opt_mode.
4758 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
4759             Alan Hayward  <alan.hayward@arm.com>
4760             David Sherwood  <david.sherwood@arm.com>
4762         * tree-switch-conversion.c (array_value_type): Only read TYPE_MODE
4763         once.  Use get_narrowest_mode instead of GET_CLASS_NARROWEST_MODE.
4765 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
4766             Alan Hayward  <alan.hayward@arm.com>
4767             David Sherwood  <david.sherwood@arm.com>
4769         * machmode.h (mode_traits): New structure.
4770         (get_narrowest_mode): New function.
4771         (mode_iterator::start): Likewise.
4772         (mode_iterator::iterate_p): Likewise.
4773         (mode_iterator::get_wider): Likewise.
4774         (mode_iterator::get_known_wider): Likewise.
4775         (mode_iterator::get_2xwider): Likewise.
4776         (FOR_EACH_MODE_IN_CLASS): New mode iterator.
4777         (FOR_EACH_MODE): Likewise.
4778         (FOR_EACH_MODE_FROM): Likewise.
4779         (FOR_EACH_MODE_UNTIL): Likewise.
4780         (FOR_EACH_WIDER_MODE): Likewise.
4781         (FOR_EACH_2XWIDER_MODE): Likewise.
4782         * builtins.c (expand_builtin_strlen): Use new mode iterators.
4783         * combine.c (simplify_comparison): Likewise
4784         * config/i386/i386.c (type_natural_mode): Likewise.
4785         * cse.c (cse_insn): Likewise.
4786         * dse.c (find_shift_sequence): Likewise.
4787         * emit-rtl.c (init_derived_machine_modes): Likewise.
4788         (init_emit_once): Likewise.
4789         * explow.c (hard_function_value): Likewise.
4790         * expmed.c (extract_fixed_bit_field_1): Likewise.
4791         (extract_bit_field_1): Likewise.
4792         (expand_divmod): Likewise.
4793         (emit_store_flag_1): Likewise.
4794         * expr.c (init_expr_target): Likewise.
4795         (convert_move): Likewise.
4796         (alignment_for_piecewise_move): Likewise.
4797         (widest_int_mode_for_size): Likewise.
4798         (emit_block_move_via_movmem): Likewise.
4799         (copy_blkmode_to_reg): Likewise.
4800         (set_storage_via_setmem): Likewise.
4801         (compress_float_constant): Likewise.
4802         * omp-low.c (omp_clause_aligned_alignment): Likewise.
4803         * optabs-query.c (get_best_extraction_insn): Likewise.
4804         * optabs.c (expand_binop): Likewise.
4805         (expand_twoval_unop): Likewise.
4806         (expand_twoval_binop): Likewise.
4807         (widen_leading): Likewise.
4808         (widen_bswap): Likewise.
4809         (expand_parity): Likewise.
4810         (expand_unop): Likewise.
4811         (prepare_cmp_insn): Likewise.
4812         (prepare_float_lib_cmp): Likewise.
4813         (expand_float): Likewise.
4814         (expand_fix): Likewise.
4815         (expand_sfix_optab): Likewise.
4816         * postreload.c (move2add_use_add2_insn): Likewise.
4817         * reg-stack.c (reg_to_stack): Likewise.
4818         * reginfo.c (choose_hard_reg_mode): Likewise.
4819         * rtlanal.c (init_num_sign_bit_copies_in_rep): Likewise.
4820         * stor-layout.c (mode_for_size): Likewise.
4821         (smallest_mode_for_size): Likewise.
4822         (mode_for_vector): Likewise.
4823         (finish_bitfield_representative): Likewise.
4824         * tree-ssa-math-opts.c (target_supports_divmod_p): Likewise.
4825         * tree-vect-generic.c (type_for_widest_vector_mode): Likewise.
4826         * tree-vect-stmts.c (vectorizable_conversion): Likewise.
4827         * var-tracking.c (prepare_call_arguments): Likewise.
4829 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
4830             Alan Hayward  <alan.hayward@arm.com>
4831             David Sherwood  <david.sherwood@arm.com>
4833         * genconditions.c (write_header): Add a "#define USE_ENUM_MODES".
4834         * genmodes.c (emit_insn_modes_h): Define FOOmode to E_FOOmode if
4835         USE_ENUM_MODES is defined and to ((void) 0, E_FOOmode) otherwise.
4836         * machmode.h (mode_size): Move earlier in file.
4837         (mode_precision): Likewise.
4838         (mode_inner): Likewise.
4839         (mode_nunits): Likewise.
4840         (mode_unit_size): Likewise.
4841         (unit_unit_precision): Likewise.
4842         (mode_wider): Likewise.
4843         (mode_2xwider): Likewise.
4844         (machine_mode): New class.
4845         (mode_to_bytes): New function.
4846         (mode_to_bits): Likewise.
4847         (mode_to_precision): Likewise.
4848         (mode_to_inner): Likewise.
4849         (mode_to_unit_size): Likewise.
4850         (mode_to_unit_precision): Likewise.
4851         (mode_to_nunits): Likewise.
4852         (GET_MODE_SIZE): Use mode_to_bytes.
4853         (GET_MODE_BITSIZE): Use mode_to_bits.
4854         (GET_MODE_PRECISION): Use mode_to_precision.
4855         (GET_MODE_INNER): Use mode_to_inner.
4856         (GET_MODE_UNIT_SIZE): Use mode_to_unit_size.
4857         (GET_MODE_UNIT_PRECISION): Use mode_to_unit_precision.
4858         (GET_MODE_NUNITS): Use mode_to_nunits.
4859         * system.h (ALWAYS_INLINE): New macro.
4860         * config/powerpcspe/powerpcspe-c.c
4861         (altivec_resolve_overloaded_builtin): Use machine_mode instead of
4862         int for arg1_mode and arg2_mode.
4864 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
4865             Alan Hayward  <alan.hayward@arm.com>
4866             David Sherwood  <david.sherwood@arm.com>
4868         * config/aarch64/aarch64-builtins.c (aarch64_simd_builtin_std_type):
4869         Prefix mode names with E_ in case statements.
4870         * config/aarch64/aarch64-elf.h (ASM_OUTPUT_ADDR_DIFF_ELT): Likewise.
4871         * config/aarch64/aarch64.c (aarch64_split_simd_combine): Likewise.
4872         (aarch64_split_simd_move): Likewise.
4873         (aarch64_gen_storewb_pair): Likewise.
4874         (aarch64_gen_loadwb_pair): Likewise.
4875         (aarch64_gen_store_pair): Likewise.
4876         (aarch64_gen_load_pair): Likewise.
4877         (aarch64_get_condition_code_1): Likewise.
4878         (aarch64_constant_pool_reload_icode): Likewise.
4879         (get_rsqrte_type): Likewise.
4880         (get_rsqrts_type): Likewise.
4881         (get_recpe_type): Likewise.
4882         (get_recps_type): Likewise.
4883         (aarch64_gimplify_va_arg_expr): Likewise.
4884         (aarch64_simd_container_mode): Likewise.
4885         (aarch64_emit_load_exclusive): Likewise.
4886         (aarch64_emit_store_exclusive): Likewise.
4887         (aarch64_expand_compare_and_swap): Likewise.
4888         (aarch64_gen_atomic_cas): Likewise.
4889         (aarch64_emit_bic): Likewise.
4890         (aarch64_emit_atomic_swap): Likewise.
4891         (aarch64_emit_atomic_load_op): Likewise.
4892         (aarch64_evpc_trn): Likewise.
4893         (aarch64_evpc_uzp): Likewise.
4894         (aarch64_evpc_zip): Likewise.
4895         (aarch64_evpc_ext): Likewise.
4896         (aarch64_evpc_rev): Likewise.
4897         (aarch64_evpc_dup): Likewise.
4898         (aarch64_gen_ccmp_first): Likewise.
4899         (aarch64_gen_ccmp_next): Likewise.
4900         * config/alpha/alpha.c (alpha_scalar_mode_supported_p): Likewise.
4901         (alpha_emit_xfloating_libcall): Likewise.
4902         (emit_insxl): Likewise.
4903         (alpha_arg_type): Likewise.
4904         * config/arc/arc.c (arc_vector_mode_supported_p): Likewise.
4905         (arc_preferred_simd_mode): Likewise.
4906         (arc_secondary_reload): Likewise.
4907         (get_arc_condition_code): Likewise.
4908         (arc_print_operand): Likewise.
4909         (arc_legitimate_constant_p): Likewise.
4910         * config/arc/arc.h (ASM_OUTPUT_ADDR_DIFF_ELT): Likewise.
4911         * config/arc/arc.md (casesi_load): Likewise.
4912         (casesi_compact_jump): Likewise.
4913         * config/arc/predicates.md (proper_comparison_operator): Likewise.
4914         (cc_use_register): Likewise.
4915         * config/arm/aout.h (ASM_OUTPUT_ADDR_DIFF_ELT): Likewise.
4916         * config/arm/arm-builtins.c (arm_simd_builtin_std_type): Likewise.
4917         (arm_init_iwmmxt_builtins): Likewise.
4918         * config/arm/arm.c (thumb1_size_rtx_costs): Likewise.
4919         (neon_expand_vector_init): Likewise.
4920         (arm_attr_length_move_neon): Likewise.
4921         (maybe_get_arm_condition_code): Likewise.
4922         (arm_emit_vector_const): Likewise.
4923         (arm_preferred_simd_mode): Likewise.
4924         (arm_output_iwmmxt_tinsr): Likewise.
4925         (thumb1_output_casesi): Likewise.
4926         (thumb2_output_casesi): Likewise.
4927         (arm_emit_load_exclusive): Likewise.
4928         (arm_emit_store_exclusive): Likewise.
4929         (arm_expand_compare_and_swap): Likewise.
4930         (arm_evpc_neon_vuzp): Likewise.
4931         (arm_evpc_neon_vzip): Likewise.
4932         (arm_evpc_neon_vrev): Likewise.
4933         (arm_evpc_neon_vtrn): Likewise.
4934         (arm_evpc_neon_vext): Likewise.
4935         (arm_validize_comparison): Likewise.
4936         * config/arm/neon.md (neon_vc<cmp_op><mode>): Likewise.
4937         * config/avr/avr-c.c (avr_resolve_overloaded_builtin): Likewise.
4938         * config/avr/avr.c (avr_rtx_costs_1): Likewise.
4939         * config/c6x/c6x.c (c6x_vector_mode_supported_p): Likewise.
4940         (c6x_preferred_simd_mode): Likewise.
4941         * config/epiphany/epiphany.c (get_epiphany_condition_code): Likewise.
4942         (epiphany_rtx_costs): Likewise.
4943         * config/epiphany/predicates.md (proper_comparison_operator):
4944         Likewise.
4945         * config/frv/frv.c (condexec_memory_operand): Likewise.
4946         (frv_emit_move): Likewise.
4947         (output_move_single): Likewise.
4948         (output_condmove_single): Likewise.
4949         (frv_hard_regno_mode_ok): Likewise.
4950         (frv_matching_accg_mode): Likewise.
4951         * config/h8300/h8300.c (split_adds_subs): Likewise.
4952         (h8300_rtx_costs): Likewise.
4953         (h8300_print_operand): Likewise.
4954         (compute_mov_length): Likewise.
4955         (output_logical_op): Likewise.
4956         (compute_logical_op_length): Likewise.
4957         (compute_logical_op_cc): Likewise.
4958         (h8300_shift_needs_scratch_p): Likewise.
4959         (output_a_shift): Likewise.
4960         (compute_a_shift_length): Likewise.
4961         (compute_a_shift_cc): Likewise.
4962         (expand_a_rotate): Likewise.
4963         (output_a_rotate): Likewise.
4964         * config/i386/i386.c (classify_argument): Likewise.
4965         (function_arg_advance_32): Likewise.
4966         (function_arg_32): Likewise.
4967         (function_arg_64): Likewise.
4968         (function_value_64): Likewise.
4969         (ix86_gimplify_va_arg): Likewise.
4970         (ix86_legitimate_constant_p): Likewise.
4971         (put_condition_code): Likewise.
4972         (split_double_mode): Likewise.
4973         (ix86_avx256_split_vector_move_misalign): Likewise.
4974         (ix86_expand_vector_logical_operator): Likewise.
4975         (ix86_split_idivmod): Likewise.
4976         (ix86_expand_adjust_ufix_to_sfix_si): Likewise.
4977         (ix86_build_const_vector): Likewise.
4978         (ix86_build_signbit_mask): Likewise.
4979         (ix86_match_ccmode): Likewise.
4980         (ix86_cc_modes_compatible): Likewise.
4981         (ix86_expand_branch): Likewise.
4982         (ix86_expand_sse_cmp): Likewise.
4983         (ix86_expand_sse_movcc): Likewise.
4984         (ix86_expand_int_sse_cmp): Likewise.
4985         (ix86_expand_vec_perm_vpermi2): Likewise.
4986         (ix86_expand_vec_perm): Likewise.
4987         (ix86_expand_sse_unpack): Likewise.
4988         (ix86_expand_int_addcc): Likewise.
4989         (ix86_split_to_parts): Likewise.
4990         (ix86_vectorize_builtin_gather): Likewise.
4991         (ix86_vectorize_builtin_scatter): Likewise.
4992         (avx_vpermilp_parallel): Likewise.
4993         (inline_memory_move_cost): Likewise.
4994         (ix86_tieable_integer_mode_p): Likewise.
4995         (x86_maybe_negate_const_int): Likewise.
4996         (ix86_expand_vector_init_duplicate): Likewise.
4997         (ix86_expand_vector_init_one_nonzero): Likewise.
4998         (ix86_expand_vector_init_one_var): Likewise.
4999         (ix86_expand_vector_init_concat): Likewise.
5000         (ix86_expand_vector_init_interleave): Likewise.
5001         (ix86_expand_vector_init_general): Likewise.
5002         (ix86_expand_vector_set): Likewise.
5003         (ix86_expand_vector_extract): Likewise.
5004         (emit_reduc_half): Likewise.
5005         (ix86_emit_i387_round): Likewise.
5006         (ix86_mangle_type): Likewise.
5007         (ix86_expand_round_sse4): Likewise.
5008         (expand_vec_perm_blend): Likewise.
5009         (canonicalize_vector_int_perm): Likewise.
5010         (ix86_expand_vec_one_operand_perm_avx512): Likewise.
5011         (expand_vec_perm_1): Likewise.
5012         (expand_vec_perm_interleave3): Likewise.
5013         (expand_vec_perm_even_odd_pack): Likewise.
5014         (expand_vec_perm_even_odd_1): Likewise.
5015         (expand_vec_perm_broadcast_1): Likewise.
5016         (ix86_vectorize_vec_perm_const_ok): Likewise.
5017         (ix86_expand_vecop_qihi): Likewise.
5018         (ix86_expand_mul_widen_hilo): Likewise.
5019         (ix86_expand_sse2_abs): Likewise.
5020         (ix86_expand_pextr): Likewise.
5021         (ix86_expand_pinsr): Likewise.
5022         (ix86_preferred_simd_mode): Likewise.
5023         (ix86_simd_clone_compute_vecsize_and_simdlen): Likewise.
5024         * config/i386/sse.md (*andnot<mode>3): Likewise.
5025         (<mask_codefor><code><mode>3<mask_name>): Likewise.
5026         (*<code><mode>3): Likewise.
5027         * config/ia64/ia64.c (ia64_expand_vecint_compare): Likewise.
5028         (ia64_expand_atomic_op): Likewise.
5029         (ia64_arg_type): Likewise.
5030         (ia64_mode_to_int): Likewise.
5031         (ia64_scalar_mode_supported_p): Likewise.
5032         (ia64_vector_mode_supported_p): Likewise.
5033         (expand_vec_perm_broadcast): Likewise.
5034         * config/iq2000/iq2000.c (iq2000_move_1word): Likewise.
5035         (iq2000_function_arg_advance): Likewise.
5036         (iq2000_function_arg): Likewise.
5037         * config/m32c/m32c.c (m32c_preferred_reload_class): Likewise.
5038         * config/m68k/m68k.c (output_dbcc_and_branch): Likewise.
5039         (m68k_libcall_value): Likewise.
5040         (m68k_function_value): Likewise.
5041         (sched_attr_op_type): Likewise.
5042         * config/mcore/mcore.c (mcore_output_move): Likewise.
5043         * config/microblaze/microblaze.c (microblaze_function_arg_advance):
5044         Likewise.
5045         (microblaze_function_arg): Likewise.
5046         * config/mips/mips.c (mips16_build_call_stub): Likewise.
5047         (mips_print_operand): Likewise.
5048         (mips_mode_ok_for_mov_fmt_p): Likewise.
5049         (mips_vector_mode_supported_p): Likewise.
5050         (mips_preferred_simd_mode): Likewise.
5051         (mips_expand_vpc_loongson_even_odd): Likewise.
5052         (mips_expand_vec_unpack): Likewise.
5053         (mips_expand_vi_broadcast): Likewise.
5054         (mips_expand_vector_init): Likewise.
5055         (mips_expand_vec_reduc): Likewise.
5056         (mips_expand_msa_cmp): Likewise.
5057         * config/mips/mips.md (casesi_internal_mips16_<mode>): Likewise.
5058         * config/mn10300/mn10300.c (mn10300_print_operand): Likewise.
5059         (cc_flags_for_mode): Likewise.
5060         * config/msp430/msp430.c (msp430_print_operand): Likewise.
5061         * config/nds32/nds32-md-auxiliary.c (nds32_mem_format): Likewise.
5062         (nds32_output_casesi_pc_relative): Likewise.
5063         * config/nds32/nds32.h (ASM_OUTPUT_ADDR_DIFF_ELT): Likewise.
5064         * config/nvptx/nvptx.c (nvptx_ptx_type_from_mode): Likewise.
5065         (nvptx_gen_unpack): Likewise.
5066         (nvptx_gen_pack): Likewise.
5067         (nvptx_gen_shuffle): Likewise.
5068         (nvptx_gen_wcast): Likewise.
5069         (nvptx_preferred_simd_mode): Likewise.
5070         * config/pa/pa.c (pa_secondary_reload): Likewise.
5071         * config/pa/predicates.md (base14_operand): Likewise.
5072         * config/powerpcspe/powerpcspe-c.c
5073         (altivec_resolve_overloaded_builtin): Likewise.
5074         * config/powerpcspe/powerpcspe.c (rs6000_setup_reg_addr_masks):
5075         Likewise.
5076         (rs6000_preferred_simd_mode): Likewise.
5077         (output_vec_const_move): Likewise.
5078         (rs6000_expand_vector_extract): Likewise.
5079         (rs6000_split_vec_extract_var): Likewise.
5080         (reg_offset_addressing_ok_p): Likewise.
5081         (rs6000_legitimate_offset_address_p): Likewise.
5082         (rs6000_legitimize_address): Likewise.
5083         (rs6000_emit_set_const): Likewise.
5084         (rs6000_const_vec): Likewise.
5085         (rs6000_emit_move): Likewise.
5086         (spe_build_register_parallel): Likewise.
5087         (rs6000_darwin64_record_arg_recurse): Likewise.
5088         (swap_selector_for_mode): Likewise.
5089         (spe_init_builtins): Likewise.
5090         (paired_init_builtins): Likewise.
5091         (altivec_init_builtins): Likewise.
5092         (do_load_for_compare): Likewise.
5093         (rs6000_generate_compare): Likewise.
5094         (rs6000_expand_float128_convert): Likewise.
5095         (emit_load_locked): Likewise.
5096         (emit_store_conditional): Likewise.
5097         (rs6000_output_function_epilogue): Likewise.
5098         (rs6000_handle_altivec_attribute): Likewise.
5099         (rs6000_function_value): Likewise.
5100         (emit_fusion_gpr_load): Likewise.
5101         (emit_fusion_p9_load): Likewise.
5102         (emit_fusion_p9_store): Likewise.
5103         * config/powerpcspe/predicates.md (easy_fp_constant): Likewise.
5104         (fusion_gpr_mem_load): Likewise.
5105         (fusion_addis_mem_combo_load): Likewise.
5106         (fusion_addis_mem_combo_store): Likewise.
5107         * config/rs6000/predicates.md (easy_fp_constant): Likewise.
5108         (fusion_gpr_mem_load): Likewise.
5109         (fusion_addis_mem_combo_load): Likewise.
5110         (fusion_addis_mem_combo_store): Likewise.
5111         * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin):
5112         Likewise.
5113         * config/rs6000/rs6000-string.c (do_load_for_compare): Likewise.
5114         * config/rs6000/rs6000.c (rs6000_setup_reg_addr_masks): Likewise.
5115         (rs6000_preferred_simd_mode): Likewise.
5116         (output_vec_const_move): Likewise.
5117         (rs6000_expand_vector_extract): Likewise.
5118         (rs6000_split_vec_extract_var): Likewise.
5119         (reg_offset_addressing_ok_p): Likewise.
5120         (rs6000_legitimate_offset_address_p): Likewise.
5121         (rs6000_legitimize_address): Likewise.
5122         (rs6000_emit_set_const): Likewise.
5123         (rs6000_const_vec): Likewise.
5124         (rs6000_emit_move): Likewise.
5125         (rs6000_darwin64_record_arg_recurse): Likewise.
5126         (swap_selector_for_mode): Likewise.
5127         (paired_init_builtins): Likewise.
5128         (altivec_init_builtins): Likewise.
5129         (rs6000_expand_float128_convert): Likewise.
5130         (emit_load_locked): Likewise.
5131         (emit_store_conditional): Likewise.
5132         (rs6000_output_function_epilogue): Likewise.
5133         (rs6000_handle_altivec_attribute): Likewise.
5134         (rs6000_function_value): Likewise.
5135         (emit_fusion_gpr_load): Likewise.
5136         (emit_fusion_p9_load): Likewise.
5137         (emit_fusion_p9_store): Likewise.
5138         * config/rx/rx.c (rx_gen_move_template): Likewise.
5139         (flags_from_mode): Likewise.
5140         * config/s390/predicates.md (s390_alc_comparison): Likewise.
5141         (s390_slb_comparison): Likewise.
5142         * config/s390/s390.c (s390_handle_vectorbool_attribute): Likewise.
5143         (s390_vector_mode_supported_p): Likewise.
5144         (s390_cc_modes_compatible): Likewise.
5145         (s390_match_ccmode_set): Likewise.
5146         (s390_canonicalize_comparison): Likewise.
5147         (s390_emit_compare_and_swap): Likewise.
5148         (s390_branch_condition_mask): Likewise.
5149         (s390_rtx_costs): Likewise.
5150         (s390_secondary_reload): Likewise.
5151         (__SECONDARY_RELOAD_CASE): Likewise.
5152         (s390_expand_cs): Likewise.
5153         (s390_preferred_simd_mode): Likewise.
5154         * config/s390/vx-builtins.md (vec_packsu_u<mode>): Likewise.
5155         * config/sh/sh.c (sh_print_operand): Likewise.
5156         (dump_table): Likewise.
5157         (sh_secondary_reload): Likewise.
5158         * config/sh/sh.h (ASM_OUTPUT_ADDR_DIFF_ELT): Likewise.
5159         * config/sh/sh.md (casesi_worker_1): Likewise.
5160         (casesi_worker_2): Likewise.
5161         * config/sparc/predicates.md (icc_comparison_operator): Likewise.
5162         (fcc_comparison_operator): Likewise.
5163         * config/sparc/sparc.c (sparc_expand_move): Likewise.
5164         (emit_soft_tfmode_cvt): Likewise.
5165         (sparc_preferred_simd_mode): Likewise.
5166         (output_cbranch): Likewise.
5167         (sparc_print_operand): Likewise.
5168         (sparc_expand_vec_perm_bmask): Likewise.
5169         (vector_init_bshuffle): Likewise.
5170         * config/spu/spu.c (spu_scalar_mode_supported_p): Likewise.
5171         (spu_vector_mode_supported_p): Likewise.
5172         (spu_expand_insv): Likewise.
5173         (spu_emit_branch_or_set): Likewise.
5174         (spu_handle_vector_attribute): Likewise.
5175         (spu_builtin_splats): Likewise.
5176         (spu_builtin_extract): Likewise.
5177         (spu_builtin_promote): Likewise.
5178         (spu_expand_sign_extend): Likewise.
5179         * config/tilegx/tilegx.c (tilegx_scalar_mode_supported_p): Likewise.
5180         (tilegx_simd_int): Likewise.
5181         * config/tilepro/tilepro.c (tilepro_scalar_mode_supported_p): Likewise.
5182         (tilepro_simd_int): Likewise.
5183         * config/v850/v850.c (const_double_split): Likewise.
5184         (v850_print_operand): Likewise.
5185         (ep_memory_offset): Likewise.
5186         * config/vax/vax.c (vax_rtx_costs): Likewise.
5187         (vax_output_int_move): Likewise.
5188         (vax_output_int_add): Likewise.
5189         (vax_output_int_subtract): Likewise.
5190         * config/visium/predicates.md (visium_branch_operator): Likewise.
5191         * config/visium/visium.c (rtx_ok_for_offset_p): Likewise.
5192         (visium_print_operand_address): Likewise.
5193         * config/visium/visium.h (ASM_OUTPUT_ADDR_DIFF_ELT): Likewise.
5194         * config/xtensa/xtensa.c (xtensa_mem_offset): Likewise.
5195         (xtensa_expand_conditional_branch): Likewise.
5196         (xtensa_copy_incoming_a7): Likewise.
5197         (xtensa_output_literal): Likewise.
5198         * dfp.c (decimal_real_maxval): Likewise.
5199         * targhooks.c (default_libgcc_floating_mode_supported_p): Likewise.
5201 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
5202             Alan Hayward  <alan.hayward@arm.com>
5203             David Sherwood  <david.sherwood@arm.com>
5205         * genmodes.c (mode_size_inline): Add an E_ prefix to mode names.
5206         (mode_nunits_inline): Likewise.
5207         (mode_inner_inline): Likewise.
5208         (mode_unit_size_inline): Likewise.
5209         (mode_unit_precision_inline): Likewise.
5210         (emit_insn_modes_h): Likewise.  Also emit a #define of the
5211         unprefixed name.
5212         (emit_mode_wider): Add an E_ prefix to mode names.
5213         (emit_mode_complex): Likewise.
5214         (emit_mode_inner): Likewise.
5215         (emit_mode_adjustments): Likewise.
5216         (emit_mode_int_n): Likewise.
5217         * config/aarch64/aarch64-builtins.c (v8qi_UP, v4hi_UP, v4hf_UP)
5218         (v2si_UP, v2sf_UP, v1df_UP, di_UP, df_UP, v16qi_UP, v8hi_UP, v8hf_UP)
5219         (v4si_UP, v4sf_UP, v2di_UP, v2df_UP, ti_UP, oi_UP, ci_UP, xi_UP)
5220         (si_UP, sf_UP, hi_UP, hf_UP, qi_UP): Likewise.
5221         (CRC32_BUILTIN, ENTRY): Likewise.
5222         * config/aarch64/aarch64.c (aarch64_push_regs): Likewise.
5223         (aarch64_pop_regs): Likewise.
5224         (aarch64_process_components): Likewise.
5225         * config/alpha/alpha.c (alpha_emit_conditional_move): Likewise.
5226         * config/arm/arm-builtins.c (v8qi_UP, v4hi_UP, v4hf_UP, v2si_UP)
5227         (v2sf_UP, di_UP, v16qi_UP, v8hi_UP, v8hf_UP, v4si_UP, v4sf_UP)
5228         (v2di_UP, ti_UP, ei_UP, oi_UP, hf_UP, si_UP, void_UP): Likewise.
5229         * config/arm/arm.c (arm_init_libfuncs): Likewise.
5230         * config/i386/i386-builtin-types.awk (ix86_builtin_type_vect_mode):
5231         Likewise.
5232         * config/i386/i386-builtin.def (pcmpestr): Likewise.
5233         (pcmpistr): Likewise.
5234         * config/microblaze/microblaze.c (double_memory_operand): Likewise.
5235         * config/mmix/mmix.c (mmix_output_condition): Likewise.
5236         * config/powerpcspe/powerpcspe.c (rs6000_init_hard_regno_mode_ok):
5237         Likewise.
5238         * config/rl78/rl78.c (mduc_regs): Likewise.
5239         * config/rs6000/rs6000.c (rs6000_init_hard_regno_mode_ok): Likewise.
5240         (htm_expand_builtin): Likewise.
5241         * config/sh/sh.h (REGISTER_NATURAL_MODE): Likewise.
5242         * config/sparc/sparc.c (emit_save_or_restore_regs): Likewise.
5243         * config/xtensa/xtensa.c (print_operand): Likewise.
5244         * expmed.h (NUM_MODE_PARTIAL_INT): Likewise.
5245         (NUM_MODE_VECTOR_INT): Likewise.
5246         * genoutput.c (null_operand): Likewise.
5247         (output_operand_data): Likewise.
5248         * genrecog.c (print_parameter_value): Likewise.
5249         * lra.c (debug_operand_data): Likewise.
5251 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
5253         * dwarf2out.c (scompare_loc_descriptor_wide)
5254         (scompare_loc_descriptor_narrow): New functions, split out from...
5255         (scompare_loc_descriptor): ...here.
5256         * expmed.c (emit_store_flag_int): New function, split out from...
5257         (emit_store_flag): ...here.
5259 2017-08-30  Richard Biener  <rguenther@suse.de>
5261         * dwarf2out.c (dwarf2out_finish): Remove setting AT_pubnames.
5262         (dwarf2out_early_finish): Move setting of AT_pubnames from
5263         early debug output to early finish.
5265 2017-08-30  Jozef Lawrynowicz  <jozef.l@somniumtech.com>
5267         * gcc/config/msp430/msp430.h: Pass -mcode/data-region to the linker
5268         and -mdata-region to the assembler.
5270 2017-08-30  Richard Biener  <rguenther@suse.de>
5272         * dwarf2out.c (add_dwarf_attr): Check we don't add duplicate
5273         attributes.
5274         (gen_subprogram_die): Add DW_AT_object_pointer only early.
5275         (dwarf2out_early_global_decl): Only generate a DIE for the
5276         abstract origin if it doesn't already exist or is a declaration DIE.
5277         (resolve_addr): Do not add the linkage name twice when
5278         generating a stub DIE for the DW_TAG_GNU_call_site target.
5280 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
5282         * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin):
5283         Use machine_mode rather than int for arg1_mode.
5285 2017-08-29  Michael Meissner  <meissner@linux.vnet.ibm.com>
5287         PR target/82015
5288         * config/rs6000/rs6000.c (rs6000_expand_binop_builtin): Insure
5289         that the second argument of the built-in functions to unpack
5290         128-bit scalar types to 64-bit values is 0 or 1.  Change to use a
5291         switch statement instead a lot of if statements.
5292         * config/rs6000/rs6000.md (unpack<mode>, FMOVE128_VSX iterator):
5293         Allow 64-bit values to be in Altivec registers as well as
5294         traditional floating point registers.
5295         (pack<mode>, FMOVE128_VSX iterator): Likewise.
5297 2017-08-29  Alexander Monakov  <amonakov@ispras.ru>
5299         * ira-costs.c (record_address_regs): Handle both operands of PLUS for
5300         MAX_REGS_PER_ADDRESS == 1.
5302 2017-08-29  Uros Bizjak  <ubizjak@gmail.com>
5304         * config/i386/i386.opt (flag_fentry): Do not init to -1.
5305         * config/i386/i386.c (ix86_option_override_internal): Simplify
5306         setting of opts->x_flag_entry.
5308 2017-08-29  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
5309             Jakub Jelinek  <jakub@redhat.com>
5310             Richard Biener  <rguenther@suse.de>
5312         PR tree-optimization/81503
5313         * gimple-ssa-strength-reduction.c (replace_mult_candidate): Ensure
5314         folded constant fits in the target type; reorder tests for clarity.
5316 2017-08-29  Martin Liska  <mliska@suse.cz>
5318         * passes.def: Include pass_lower_switch.
5319         * stmt.c (dump_case_nodes): Remove and move to
5320         tree-switch-conversion.
5321         (case_values_threshold): Likewise.
5322         (expand_switch_as_decision_tree_p): Likewise.
5323         (emit_case_decision_tree): Likewise.
5324         (expand_case): Likewise.
5325         (balance_case_nodes): Likewise.
5326         (node_has_low_bound): Likewise.
5327         (node_has_high_bound): Likewise.
5328         (node_is_bounded): Likewise.
5329         (emit_case_nodes): Likewise.
5330         (struct simple_case_node): New struct.
5331         (add_case_node): Remove.
5332         (emit_case_dispatch_table): Use vector instead of case_list.
5333         (reset_out_edges_aux): Remove.
5334         (compute_cases_per_edge): Likewise.
5335         (expand_case): Build list of simple_case_node.
5336         (expand_sjlj_dispatch_table): Use it.
5337         * tree-switch-conversion.c (struct case_node): Moved from
5338         stmt.c and adjusted.
5339         (emit_case_nodes): Likewise.
5340         (node_has_low_bound): Likewise.
5341         (node_has_high_bound): Likewise.
5342         (node_is_bounded): Likewise.
5343         (case_values_threshold): Likewise.
5344         (reset_out_edges_aux): Likewise.
5345         (compute_cases_per_edge): Likewise.
5346         (add_case_node): Likewise.
5347         (dump_case_nodes): Likewise.
5348         (balance_case_nodes): Likewise.
5349         (expand_switch_as_decision_tree_p): Likewise.
5350         (emit_jump): Likewise.
5351         (emit_case_decision_tree): Likewise.
5352         (try_switch_expansion): Likewise.
5353         (do_jump_if_equal): Likewise.
5354         (emit_cmp_and_jump_insns): Likewise.
5355         (fix_phi_operands_for_edge): New function.
5356         (record_phi_operand_mapping): Likewise.
5357         (class pass_lower_switch): New pass.
5358         (pass_lower_switch::execute): New function.
5359         (make_pass_lower_switch): Likewise.
5360         (conditional_probability):
5361         * timevar.def: Add TV_TREE_SWITCH_LOWERING.
5362         * tree-pass.h: Add make_pass_lower_switch.
5364 2017-08-29  Jozef Lawrynowicz  <jozef.l@somniumtech.com>
5366         PR target/80993
5367         * gcc/config/msp430/msp430.c (msp430_attr): Mark interrupt
5368         handlers as used.
5370 2017-08-29  Richard Biener  <rguenther@suse.de>
5372         * dwarf2out.c (add_dwarf_attr): When checking is enabled verify
5373         we do not add a DW_AT_inline attribute twice.
5374         (gen_subprogram_die): Remove code setting DW_AT_inline on
5375         DECL_ABSTRACT_P nodes.
5377 2017-08-29  Richard Sandiford  <richard.sandiford@linaro.org>
5379         * gimplify.c (gimplify_call_expr): Copy the nothrow flag to
5380         calls to internal functions.
5381         (gimplify_modify_expr): Likewise.
5382         * tree-call-cdce.c (use_internal_fn): Likewise.
5383         * tree-ssa-math-opts.c (pass_cse_reciprocals::execute): Likewise.
5384         (convert_to_divmod): Set the nothrow flag.
5385         * tree-if-conv.c (predicate_mem_writes):  Likewise.
5386         * tree-vect-stmts.c (vectorizable_mask_load_store): Likewise.
5387         (vectorizable_call): Likewise.
5388         (vectorizable_store): Likewise.
5389         (vectorizable_load): Likewise.
5390         * tree-vect-patterns.c (vect_recog_pow_pattern): Likewise.
5391         (vect_recog_mask_conversion_pattern): Likewise.
5393 2017-08-29  Martin Liska  <mliska@suse.cz>
5395         PR other/39851
5396         * gcc.c (driver_handle_option): Add new argument.
5397         * opts-common.c (handle_option): Pass
5398         target_option_override_hook.
5399         * opts-global.c (lang_handle_option): Add new option.
5400         (set_default_handlers):  Add new argument.
5401         (decode_options): Likewise.
5402         * opts.c (target_handle_option): Likewise.
5403         (common_handle_option): Call target_option_override_hook.
5404         * opts.h (struct cl_option_handler_func): Add hook for
5405         target option override.
5406         (struct cl_option_handlers): Likewise.
5407         (set_default_handlers): Add new argument.
5408         (decode_options): Likewise.
5409         (common_handle_option): Likewise.
5410         (target_handle_option): Likewise.
5411         * toplev.c (toplev::main): Pass targetm.target_option.override
5412         hook.
5414 2017-08-29  Richard Biener  <rguenther@suse.de>
5415         Dominik Infuehr <dominik.infuehr@theobroma-systems.com>
5417         * tree-vect-slp.c (vect_bb_slp_scalar_cost): Properly confine
5418         life to the active subtree.
5420 2017-08-28  Jeff Law  <law@redhat.com>
5422         * tree-ssa-dom.c (edge_info::record_simple_equiv): Call
5423         derive_equivalences.
5424         (derive_equivalences_from_bit_ior, record_temporary_equivalences):
5425         Code moved into....
5426         (edge_info::derive_equivalences): New private member function
5428         * tree-ssa-dom.c (class edge_info): Changed from a struct
5429         to a class.  Add ctor/dtor, methods and data members.
5430         (edge_info::edge_info): Renamed from allocate_edge_info.
5431         Initialize additional members.
5432         (edge_info::~edge_info): New.
5433         (free_dom_edge_info): Delete the edge info.
5434         (record_edge_info): Use new class & associated member functions.
5435         Tighten forms for testing for edge equivalences.
5436         (record_temporary_equivalences): Iterate over the simple
5437         equivalences rather than assuming there's only one per edge.
5438         (cprop_into_successor_phis): Iterate over the simple
5439         equivalences rather than assuming there's only one per edge.
5440         (optimize_stmt): Use operand_equal_p rather than pointer
5441         equality for mini-DSE code.
5443 2017-08-28  Nathan Sidwell  <nathan@acm.org>
5445         * gcc.c (execute): Fold SIGPIPE handling into switch
5446         statement.  Adjust internal error message.
5448 2017-08-28  Richard Biener  <rguenther@suse.de>
5450         PR debug/81993
5451         * dwarf2out.c (gen_remaining_tmpl_value_param_die_attributes):
5452         Do nothing for removed DIEs.
5454 2017-08-28  Richard Biener  <rguenther@suse.de>
5456         PR tree-optimization/81977
5457         * tree-ssa-sccvn.c (vn_reference_lookup_3): Fix look through
5458         memcpy.
5460 2017-08-28  Alexander Monakov  <amonakov@ispras.ru>
5462         PR target/80640
5463         * doc/md.texi (mem_thread_fence): Remove mention of mode.  Rewrite.
5464         * optabs.c (expand_mem_thread_fence): Emit a compiler barrier when
5465         using targetm.gen_mem_thread_fence.
5467 2017-08-27  Uros Bizjak  <ubizjak@gmail.com>
5469         PR target/81995
5470         * config/i386/i386.md (*<btsc><mode>): Change operand 2
5471         predicate to register_operand.  Reorder operands.
5472         (*btr<mode>): Ditto.
5473         (*<btsc><mode>_mask): Change operand 3 predicate to register_operand.
5474         (*btr<mode>_mask): Ditto.
5476 2017-08-25  Steven Munroe  <munroesj@gcc.gnu.org>
5478         * config.gcc (powerpc*-*-*): Add xmmintrin.h and mm_malloc.h.
5479         * config/rs6000/xmmintrin.h: New file.
5480         * config/rs6000/x86intrin.h [__ALTIVEC__]: Include xmmintrin.h.
5482 2017-08-25  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
5484         PR target/81504
5485         * config/rs6000/rs6000-p8swap.c (find_alignment_op): Add reference
5486         parameter and_insn and return it.
5487         (recombine_lvx_pattern): Insert a copy to ensure availability of
5488         the base register of the copied masking operation at the point of
5489         the instruction replacement.
5490         (recombine_stvx_pattern): Likewise.
5492 2017-08-25  Michael Meissner  <meissner@linux.vnet.ibm.com>
5494         * config/rs6000/rs6000.opt (-mpower9-dform-scalar): Delete
5495         undocumented switches.
5496         (-mpower9-dform-vector): Likewise.
5497         (-mpower9-dform): Likewise.
5498         * config/rs6000/rs6000-c.c (rs6000_target_modify_macros): Update
5499         comments to delete references to -mpower9-dform* switches.
5500         * config/rs6000/predicates.md (vsx_quad_dform_memory_operand):
5501         Delete reference to -mpower9-dform* switches, test for
5502         -mpower9-vector instead.
5503         * config/rs6000/rs6000-cpus.def (ISA_3_0_MASKS_SERVER): Likewise.
5504         (OTHER_P9_VECTOR_MASKS): Likewise.
5505         (POWERPC_MASKS): Likewise.
5506         * config/rs6000/rs6000.c (rs6000_setup_reg_addr_masks): Change
5507         tests against -mpower9-dform* to -mpower9-vector.  Delete code
5508         that checked for -mpower9-dform* consistancy with other options.
5509         Add test for -mpower9-misc to enable other power9 switches.
5510         (rs6000_init_hard_regno_mode_ok): Likewise.
5511         (rs6000_option_override_internal): Likewise.
5512         (rs6000_emit_prologue): Likewise.
5513         (rs6000_emit_epilogue): Likewise.
5514         (rs6000_opt_masks): Delete -mpower9-dform-{scalar,vector}.
5515         (rs6000_disable_incompatiable_switches): Delete -mpower9-dform.
5516         (emit_fusion_p9_load): Change tests for -mpower9-dform-scalar
5517         -mpower9-vector.
5518         (emit_fusion_p9_store): Likewise.
5519         * config/rs6000/rs6000.h (TARGET_P9_DFORM_SCALAR): Delete
5520         resetting these macros if the assembler does not support ISA 3.0
5521         instructions.
5522         (TARGET_P9_DFORM_VECTOR): Likewise.
5523         * config/rs6000/rs6000.md (peepholes to optimize altivec memory):
5524         Change to use -mpower9-vector instead of -mpower9-dform-scalar.
5526 2017-08-25  Alan Modra  <amodra@gmail.com>
5528         PR rtl-optimization/81747
5529         * cse.c (cse_extended_basic_block): Don't attempt to record
5530         equivalences for degenerate conditional branches that branch
5531         to their fall-through.
5533 2017-08-24  Martin Sebor  <msebor@redhat.com>
5535         PR middle-end/81908
5536         * gimple-fold.c (size_must_be_zero_p): New function.
5537         (gimple_fold_builtin_memory_op): Call it.
5539 2017-08-24  Steven Munroe  <munroesj@gcc.gnu.org>
5541         * config/rs6000/mm_malloc.h: New file.
5543 2017-08-24  Bin Cheng  <bin.cheng@arm.com>
5545         PR tree-optimization/81913
5546         * tree-ssa-loop-niter.c (number_of_iterations_cond): Skip niter
5547         analysis when either IVs in condition can wrap.
5549 2017-08-24  Uros Bizjak  <ubizjak@gmail.com>
5551         * dwarf2out.c (MAX_ARTIFICIAL_LABEL_BYTES): Increase to 40.
5552         * dwarf2cfi.c (MAX_ARTIFICIAL_LABEL_BYTES): Remove.
5554 2017-08-24  Richard Biener  <rguenther@suse.de>
5556         PR target/81921
5557         * targhooks.c (default_target_can_inline_p): Properly
5558         use target_option_default_node when no DECL_FUNCTION_SPECIFIC_TARGET
5559         is present and always compare.
5560         * config/i386/i386.c (ix86_valid_target_attribute_tree): Do not
5561         infer -mfpmath=sse from TARGET_SSE_P.
5562         (ix86_can_inline_p): Properly use target_option_default_node when
5563         no DECL_FUNCTION_SPECIFIC_TARGET is present and always compare.
5565 2017-08-24  Richard Biener  <rguenther@suse.de>
5567         PR debug/81936
5568         * dwarf2out.c (output_die): Handle flag_generate_offload like
5569         flag_generate_lto.
5570         (output_comp_unit): Likewise.
5571         (gen_array_type_die): Likewise.
5572         (dwarf2out_early_finish): Likewise.
5573         (note_variable_value_in_expr): Likewise.
5574         (dwarf2out_finish): Likewise.  Adjust assert.
5575         * cgraphunit.c (symbol_table::compile): Move setting of
5576         flag_generate_offload earlier ...
5577         (symbol_table::finalize_compilation_unit): ... here, before
5578         early debug finalization.
5580 2017-08-24  Richard Biener  <rguenther@suse.de>
5582         * config/i386/i386.c: Include symbol-summary.h, ipa-prop.h
5583         and ipa-fnsummary.h.
5584         (ix86_can_inline_p): When ix86_fpmath flags do not match
5585         check whether the callee uses FP math at all.
5587 2017-08-24  Aldy Hernandez  <aldyh@redhat.com>
5589         PR middle-end/81931
5590         * tree-ssanames.c (get_nonzero_bits): Use element_precision
5591         instead of TYPE_PRECISION.
5593 2017-08-24  Richard Sandiford  <richard.sandiford@linaro.org>
5594             Alan Hayward  <alan.hayward@arm.com>
5595             David Sherwood  <david.sherwood@arm.com>
5597         * combine.c (make_extraction): Use subreg_offset_from_lsb.
5599 2017-08-23  Daniel Santos  <daniel.santos@pobox.com>
5601         * config/i386/i386.h (ix86_frame::stack_realign_allocate_offset):
5602         Remove field.
5603         (ix86_frame::stack_realign_allocate): New field.
5604         (struct machine_frame_state): Modify comments.
5605         (machine_frame_state::sp_realigned_fp_end): New field.
5606         * config/i386/i386.c (ix86_compute_frame_layout): Rework stack frame
5607         layout calculation.
5608         (sp_valid_at): Add assertion to assure no attempt to access invalid
5609         offset of a realigned stack.
5610         (fp_valid_at): Likewise.
5611         (choose_baseaddr): Modify comments.
5612         (ix86_emit_outlined_ms2sysv_save): Adjust to changes in
5613         ix86_expand_prologue.
5614         (ix86_expand_prologue): Modify stack realignment and allocation.
5615         (ix86_expand_epilogue): Modify comments.
5616         * doc/sourcebuild.texi: Add documentation for target selectors avx2,
5617         avx2_runtime, avx512f, and avx512f_runtime.
5619 2017-08-23  Uros Bizjak  <ubizjak@gmail.com>
5621         * config/i386/i386.opt: Remove unneeded Init(0) initializations.
5622         (mstackrealign): Do not init to -1.
5623         * config/i386/i386.c (ix86_option_override_internal):
5624         Check opts_set, not opts when setting default value of
5625         opts->x_ix86_force_align_arg_pointer.
5627 2017-08-23  Richard Biener  <rguenther@suse.de>
5629         * function.c (fndecl_name): Use verbosity 1 (no arguments) for
5630         lang_hooks.decl_printable_name.
5631         * print-rtl-function.c (print_rtx_function): Likewise.
5632         * tree-pretty-print.c (dump_function_header): Likewise.
5634 2017-08-23  Richard Biener  <rguenther@suse.de>
5636         PR lto/81940
5637         * dwarf2out.c (dwarf2out_abstract_function): Handle LTO with
5638         -g0 at compile-time.
5640 2017-08-23  Tamar Christina  <tamar.christina@arm.com>
5642         PR middle-end/19706
5643         * doc/sourcebuild.texi (Other hardware attributes):
5644         Document xorsign.
5646 2017-08-23  Tamar Christina  <tamar.christina@arm.com>
5648         PR middle-end/19706
5649         * tree-ssa-math-opts.c (convert_expand_mult_copysign):
5650         Fix single-use check.
5652 2017-08-23  Thomas Preud'homme  <thomas.preudhomme@arm.com>
5654         * gcc.c (execute): Only test for SIGKILL and SIGQUIT if available.
5656 2017-08-22  Daniel Santos  <daniel.santos@pobox.com>
5658         * doc/install.texi: Modify to add more details on running selected
5659         tests.
5661 2017-08-22  Daniel Santos  <daniel.santos@pobox.com>
5663         * config/i386/i386.c (ix86_option_override_internal): Error when -mx32
5664         is combined with -mabi=ms.
5665         (ix86_function_type_abi): Limit errors for mixing -mx32 with attribute
5666         ms_abi.
5668 2017-08-22  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
5670         PR tree-optimization/81488
5671         * gimple-ssa-strength-reduction (struct slsr_cand_d): Add visited
5672         and cached_basis fields.
5673         (MAX_SPREAD): New constant.
5674         (alloc_cand_and_find_basis): Initialize new fields.
5675         (clear_visited): New function.
5676         (create_phi_basis_1): Rename from create_phi_basis, set visited
5677         and cached_basis fields.
5678         (create_phi_basis): New wrapper function.
5679         (phi_add_costs_1): Rename from phi_add_costs, add spread
5680         parameter, set visited field, short-circuit when limits reached.
5681         (phi_add_costs): New wrapper function.
5682         (record_phi_increments_1): Rename from record_phi_increments, set
5683         visited field.
5684         (record_phi_increments): New wrapper function.
5685         (phi_incr_cost_1): Rename from phi_incr_cost, set visited field.
5686         (phi_incr_cost): New wrapper function.
5687         (all_phi_incrs_profitable_1): Rename from
5688         all_phi_incrs_profitable, set visited field.
5689         (all_phi_incrs_profitable): New wrapper function.
5691 2017-08-22  Richard Sandiford  <richard.sandiford@linaro.org>
5692             Alan Hayward  <alan.hayward@arm.com>
5693             David Sherwood  <david.sherwood@arm.com>
5695         * rtl.h (paradoxical_subreg_p): Define inline, and add a version
5696         that takes the outer and inner modes.
5697         * doc/rtl.texi: Use paradoxical_subreg_p instead of a GET_MODE_SIZE
5698         comparison as the canonical test for a paradoxical subreg.
5699         * combine.c (simplify_set): Use paradoxical_subreg_p.
5700         (make_extraction): Likewise.
5701         (force_to_mode): Likewise.
5702         (rtx_equal_for_field_assignment_p): Likewise.
5703         (gen_lowpart_for_combine): Likewise.
5704         (simplify_comparison): Likewise.
5705         * cse.c (equiv_constant): Likewise.
5706         * expmed.c (store_bit_field_1): Likewise.
5707         * final.c (alter_subreg): Likewise.
5708         * fwprop.c (propagate_rtx): Likewise.
5709         (forward_propagate_subreg): Likewise.
5710         * ira-conflicts.c (ira_build_conflicts): Likewise.
5711         * lower-subreg.c (simplify_gen_subreg_concatn): Likewise.
5712         * lra-constraints.c (curr_insn_transform): Likewise.
5713         (split_reg): Likewise.
5714         * lra-eliminations.c (move_plus_up): Likewise.
5715         (lra_eliminate_regs_1): Likewise.
5716         * recog.c (general_operand): Likewise.
5717         * ree.c (combine_reaching_defs): Likewise.
5718         * reload.c (push_reload): Likewise.
5719         (find_reloads): Likewise.
5720         * reload1.c (elimination_effects): Likewise.
5721         (compute_reload_subreg_offset): Likewise.
5722         (choose_reload_regs): Likewise.
5723         * rtlanal.c (subreg_lsb_1): Likewise.
5724         * simplify-rtx.c (simplify_unary_operation_1): Likewise.
5725         (simplify_subreg): Likewise.
5726         * var-tracking.c (track_loc_p): Likewise.
5727         * emit-rtl.c (byte_lowpart_offset): Likewise.
5728         (paradoxical_subreg_p): Delete out-of-line definition.
5730 2017-08-22  Jeff Law  <law@redhat.com>
5732         PR tree-optimization/81741
5733         PR tree-optimization/71947
5734         * tree-ssa-dom.c: Include tree-inline.h.
5735         (record_temporary_equivalences): Only record SSA_NAME = SSA_NAME
5736         equivalences if one is more expensive to compute than the other.
5737         * tree-ssa-scopedtables.h (class const_or_copies): Make
5738         record_const_or_copy_raw method private.
5739         (class avail_exprs_stack): New method simplify_binary_operation.
5740         * tree-ssa-scopedtables.c (avail_exprs_stack::lookup_avail_expr): Call
5741         avail_exprs_stack::simplify_binary_operation as needed.
5742         (avail_exprs_stack::simplify_binary_operation): New function.
5744 2017-08-22  Sebastian Huber  <sebastian.huber@embedded-brains.de>
5746         * config.gcc (powerpc-*-rtems*): Add rs6000/linux64.opt.
5747         * config/rs6000/rtems.h (ASM_PREFERRED_EH_DATA_FORMAT): New define.
5748         (DOT_SYMBOLS): Likewise.
5749         (MINIMAL_TOC_SECTION_ASM_OP): Likewise.
5750         (RELOCATABLE_NEEDS_FIXUP): Likewise.
5751         (RS6000_ABI_NAME): Likewise.
5752         (TARGET_CMODEL): Likewise.
5753         (TOC_SECTION_ASM_OP): Likewise.
5754         (SET_CMODEL): New macro.
5755         (SUBSUBTARGET_OVERRIDE_OPTIONS): Evaluate cmodel options.
5757 2017-08-22  Richard Biener  <rguenther@suse.de>
5759         * tree-inline.c (remap_type_1): Change asserts on TYPE_SIZE[_UNIT]
5760         to allow for free-lang-data replacements similar to verify_type_variant.
5762 2017-08-22  Richard Sandiford  <richard.sandiford@linaro.org>
5763             Alan Hayward  <alan.hayward@arm.com>
5764             David Sherwood  <david.sherwood@arm.com>
5766         * config/aarch64/aarch64.md (casesi): Use DImode rather than
5767         VOIDmode for the LABEL_REF.
5769 2017-08-22  Richard Biener  <rguenther@suse.de>
5771         * tree-cfg.c (gimple_split_edge): Avoid reallocating target PHI nodes.
5773 2017-08-22  Richard Biener  <rguenther@suse.de>
5775         * common.opt (feliminate-dwarf2-dups): Ignore.
5776         * doc/invoke.texi (feliminate-dwarf2-dups): Remove documentation.
5777         * dwarf2out.c (push_new_compile_unit, pop_compile_unit,
5778         same_die_p_wrap, compute_section_prefix,
5779         is_symbol_die, assign_symbol_names, break_out_includes): Remove.
5780         (comdat_symbol_id, comdat_symbol_number): Likewise.
5781         (cu_hash_table_entry, cu_hash_table_entry_hasher, cu_hash_type):
5782         Likewise.
5783         (check_duplicate_cu, record_comdat_symbol_number): Likewise.
5784         (output_die): Mark unreachable path unreachable.
5785         (dwarf2out_start_source_file): Do not create DW_TAG_GNU_BINCL.
5786         (dwarf2out_end_source_file): Do not create DW_TAG_GNU_EINCL.
5787         (dwarf2out_init): Remove code handling flag_eliminate_dwarf2_dups.
5788         (dwarf2out_early_finish): Likewise.
5790 2017-08-22  Aldy Hernandez  <aldyh@redhat.com>
5792         * wide-int.h (hwi_with_prec::hwi_with_prec): Sign extend.
5794 2017-08-22  Georg-Johann Lay  <avr@gjlay.de>
5796         PR target/81910
5797         * config/avr/avr.c (avr_handle_addr_attribute): Early return if
5798         not VAR_P. Filter attribute warnings with OPT_Wattributes.
5799         (avr_attribute_table) <io, io_low, address>: Initialize
5800         .decl_required with true.
5802 2017-08-21  Michael Meissner  <meissner@linux.vnet.ibm.com>
5804         * config/rs6000/rs6000-cpus.def (-mvsx-scalar-float): Delete
5805         undocumented debugging options.
5806         (-mvsx-scalar-double): Likewise.
5807         (-mallow-df-permute): Likewise.
5808         (-mvectorize-builtins): Likewise.
5809         * config/rs6000/rs6000.c (rs6000_init_hard_regno_mode_ok): Likewise.
5810         (rs6000_builtin_vectorized_function): Likewise.
5811         (rs6000_builtin_md_vectorized_function): Likewise.
5812         (rs6000_opt_vars): Likewise.
5814 2017-08-21  Uros Bizjak  <ubizjak@gmail.com>
5816         PR target/46091
5817         * config/i386/i386.md (*btsq_imm): Rename from *btsq.
5818         (*btrq_imm): Rename from *btrq.
5819         (*btcq_imm): Rename from *btcq.
5820         (btsc): New code attribute.
5821         (*<btsc><mode>): New insn pattern.
5822         (*btr<mode>): Ditto.
5823         (*<btsc><mode>_mask): New insn_and_split pattern.
5824         (*btr<mode>_mask): Ditto.
5826 2017-08-21  Richard Sandiford  <richard.sandiford@linaro.org>
5827             Alan Hayward  <alan.hayward@arm.com>
5828             David Sherwood  <david.sherwood@arm.com>
5830         * function.c (pad_below): Simplify padding calculation.
5832 2017-08-21  Richard Sandiford  <richard.sandiford@linaro.org>
5833             Alan Hayward  <alan.hayward@arm.com>
5834             David Sherwood  <david.sherwood@arm.com>
5836         * target.def (function_prologue): Remove frame size argument.
5837         (function_epilogue): Likewise.
5838         * doc/tm.texi: Regenerate.
5839         * final.c (final_start_function): Update call to function_prologue.
5840         (final_end_function): Update call to function_epilogue.
5841         (default_function_pro_epilogue): Remove frame size argument.
5842         * output.h (default_function_pro_epilogue): Likewise.
5843         * config/arm/arm.c (arm_output_function_epilogue): Likewise.
5844         (arm_output_function_prologue): Likewise.
5845         * config/frv/frv.c (frv_function_prologue): Likewise.
5846         (frv_function_epilogue): Likewise.
5847         * config/i386/i386.c (ix86_output_function_epilogue): Likewise.
5848         * config/ia64/ia64.c (ia64_output_function_prologue): Likewise.
5849         (ia64_output_function_epilogue): Likewise.
5850         * config/m32r/m32r.c (m32r_output_function_prologue): Likewise.
5851         (m32r_output_function_epilogue): Likewise.
5852         * config/microblaze/microblaze.c (microblaze_function_prologue)
5853         (microblaze_function_epilogue): Likewise.
5854         * config/mips/mips.c (mips_output_function_prologue): Likewise.
5855         (mips_output_function_epilogue): Likewise.
5856         * config/mmix/mmix.c (mmix_target_asm_function_prologue): Likewise.
5857         (mmix_target_asm_function_epilogue): Likewise.
5858         * config/msp430/msp430.c (msp430_start_function): Likewise.
5859         * config/nds32/nds32.c (nds32_asm_function_prologue): Likewise.
5860         (nds32_asm_function_epilogue): Likewise.
5861         * config/nios2/nios2.c (nios2_asm_function_prologue): Likewise.
5862         * config/pa/pa.c (pa_output_function_prologue): Likewise.
5863         (pa_output_function_epilogue): Likewise.
5864         * config/powerpcspe/powerpcspe.c (rs6000_output_function_prologue)
5865         (rs6000_output_function_epilogue): Likewise.
5866         * config/rl78/rl78.c (rl78_start_function): Likewise.
5867         * config/rs6000/rs6000.c (rs6000_output_function_prologue): Likewise.
5868         (rs6000_output_function_epilogue): Likewise.
5869         * config/rx/rx.c (rx_output_function_prologue): Likewise.
5870         * config/sh/sh.c (sh_output_function_epilogue): Likewise.
5871         * config/sparc/sparc.c (sparc_asm_function_prologue): Likewise.
5872         (sparc_asm_function_epilogue): Likewise.
5874 2017-08-21  Richard Sandiford  <richard.sandiford@linaro.org>
5876         * tree.h (type_has_mode_precision_p): New function.
5877         * convert.c (convert_to_integer_1): Use it.
5878         * expr.c (expand_expr_real_2): Likewise.
5879         (expand_expr_real_1): Likewise.
5880         * fold-const.c (fold_single_bit_test_into_sign_test): Likewise.
5881         * match.pd: Likewise.
5882         * tree-ssa-forwprop.c (simplify_rotate): Likewise.
5883         * tree-ssa-math-opts.c (convert_mult_to_fma): Likewise.
5884         * tree-tailcall.c (process_assignment): Likewise.
5885         * tree-vect-loop.c (vectorizable_reduction): Likewise.
5886         * tree-vect-patterns.c (vect_recog_vector_vector_shift_pattern)
5887         (vect_recog_mult_pattern, vect_recog_divmod_pattern): Likewise.
5888         * tree-vect-stmts.c (vectorizable_conversion): Likewise.
5889         (vectorizable_assignment): Likewise.
5890         (vectorizable_shift): Likewise.
5891         (vectorizable_operation): Likewise.
5892         * tree-vrp.c (register_edge_assert_for_2): Likewise.
5894 2017-08-21  Wilco Dijkstra  <wdijkstr@arm.com>
5896         * match.pd: Add pow (C, x) simplification.
5898 2017-08-21  Richard Biener  <rguenther@suse.de>
5900         PR tree-optimization/81900
5901         * tree-ssa-pre.c (compute_antic_aux): Properly compute changed
5902         for blocks with abnormal predecessors.
5903         (compute_antic): Do not set visited flag prematurely.
5905 2017-08-21  Georg-Johann Lay  <avr@gjlay.de>
5907         PR target/79883
5908         * config/avr/avr.c (avr_set_current_function): Typo in diagnostic.
5910 2017-08-21  Richard Sandiford  <richard.sandiford@linaro.org>
5912         * stor-layout.h (vector_type_mode): Move to...
5913         * tree.h (vector_type_mode): ...here.
5914         * stor-layout.c (vector_type_mode): Move to...
5915         * tree.c (vector_type_mode): ...here.  Include rtl.h and regs.h.
5917 2017-08-21  Richard Biener  <rguenther@suse.de>
5919         * debug.h (struct gcc_debug_hooks): Add die_ref_for_decl and
5920         register_external_die hooks.
5921         (debug_false_tree_charstarstar_uhwistar): Declare.
5922         (debug_nothing_tree_charstar_uhwi): Likewise.
5923         * debug.c (do_nothing_debug_hooks): Adjust.
5924         (debug_false_tree_charstarstar_uhwistar): New do nothing.
5925         (debug_nothing_tree_charstar_uhwi): Likewise.
5926         * dbxout.c (dbx_debug_hooks): Adjust.
5927         (xcoff_debug_hooks): Likewise.
5928         * sdbout.c (sdb_debug_hooks): Likewise.
5929         * vmsdbgout.c (vmsdbg_debug_hooks): Likewise.
5930         * dwarf2out.c (macinfo_label_base): New global.
5931         (dwarf2out_register_external_die): New function for the
5932         register_external_die hook.
5933         (dwarf2out_die_ref_for_decl): Likewise for die_ref_for_decl.
5934         (dwarf2_debug_hooks): Use them.
5935         (dwarf2_lineno_debug_hooks): Adjust.
5936         (struct die_struct): Add with_offset flag.
5937         (DEBUG_LTO_DWO_INFO_SECTION, DEBUG_LTO_INFO_SECTION,
5938         DEBUG_LTO_DWO_ABBREV_SECTION, DEBUG_LTO_ABBREV_SECTION,
5939         DEBUG_LTO_DWO_MACINFO_SECTION, DEBUG_LTO_MACINFO_SECTION,
5940         DEBUG_LTO_DWO_MACRO_SECTION, DEBUG_LTO_MACRO_SECTION,
5941         DEBUG_LTO_LINE_SECTION, DEBUG_LTO_DWO_STR_OFFSETS_SECTION,
5942         DEBUG_LTO_STR_DWO_SECTION, DEBUG_STR_LTO_SECTION): New macros
5943         defining section names for the early LTO debug variants.
5944         (reset_indirect_string): New helper.
5945         (add_AT_external_die_ref): Helper for dwarf2out_register_external_die.
5946         (print_dw_val): Add support for offsetted symbol references.
5947         (get_ultimate_context): Split out from is_cxx.
5948         (is_cxx): Use get_ultimate_context.
5949         (is_fortran): Add decl overload.
5950         (compute_comp_unit_symbol): Split out worker from
5951         compute_section_prefix.
5952         (compute_section_prefix): Call compute_comp_unit_symbol and
5953         set comdat_type_p here.
5954         (output_die): Skip DIE symbol output for the LTO added one.
5955         Handle DIE symbol references with offset.
5956         (output_comp_unit): Guard section name mangling properly.
5957         For LTO debug sections emit a symbol at the section beginning
5958         which we use to refer to its DIEs.
5959         (add_abstract_origin_attribute): For DIEs registered via
5960         dwarf2out_register_external_die directly refer to the early
5961         DIE rather than indirectly through the shadow one we created.
5962         Remove obsolete call to dwarf2out_abstract_function for
5963         non-function/block origins.
5964         (gen_array_type_die): When generating early LTO debug do
5965         not emit DW_AT_string_length.
5966         (gen_formal_parameter_die): Do not re-create DIEs for PARM_DECLs
5967         late when in LTO.  As suggested place a gcc_unreachable for
5968         the DECL_ABSTRACT_P case.
5969         (gen_subprogram_die): Avoid another specification DIE
5970         for early built declarations/definitions for the late LTO case.
5971         (gen_variable_die): Add type references for late duplicated VLA dies
5972         when in late LTO.
5973         (gen_inlined_subroutine_die): Do not call dwarf2out_abstract_function,
5974         we have the abstract instance already.
5975         (process_scope_var): Adjust decl DIE contexts in LTO which
5976         first puts them in limbo.
5977         (gen_decl_die): Do not generate type DIEs late apart from
5978         types for VLAs or for decls we do not yet have a DIE.  Do not
5979         call dwarf2out_abstract_function late.
5980         (dwarf2out_early_global_decl): Make sure to create DIEs
5981         for abstract instances of a decl first.
5982         (dwarf2out_late_global_decl): Adjust comment.
5983         (output_macinfo_op): With multiple macro sections use
5984         macinfo_label_base to distinguish labels.
5985         (output_macinfo): Likewise.  Update macinfo_label_base.
5986         Pass in the line info label.
5987         (note_variable_value_in_expr): When generating LTO resolve
5988         all variable values here by generating DIEs as needed.
5989         (init_sections_and_labels): Add early LTO debug flag parameter
5990         and generate different sections and names if set.  Add generation
5991         counter for the labels so we can have multiple of them.
5992         (reset_dies): Helper to allow DIEs to be output multiple times.
5993         (dwarf2out_finish): When outputting DIEs to the fat part of an
5994         LTO object first reset DIEs.
5995         (dwarf2out_early_finish): Output early DIEs when generating LTO.
5996         (modified_type_die): Check for decl_ultimate_origin being self
5997         before recursing.
5998         (gen_type_die_with_usage): Likewise.
5999         (gen_typedef_die): Allow decl_ultimate_origin being self.
6000         (set_decl_abstract_flags): Remove.
6001         (set_block_abstract_flags): Likewise.
6002         (dwarf2out_abstract_function): Treat the early generated DIEs
6003         as the abstract copy and only add DW_AT_inline and
6004         DW_AT_artificial here and call set_decl_origin_self.
6005         If the DIE has an abstract origin don't do anything.
6006         * tree.c (free_lang_data): Build a dummy TRANSLATION_UNIT_DECL
6007         if we have none yet (Go fails to build one, PR78628).
6008         (variably_modified_type_p): Prevent endless recursion for Ada
6009         cyclic pointer types.
6010         * lto-streamer-in.c: Include debug.h.
6011         (dref_queue): New global.
6012         (lto_read_tree_1): Stream in DIE references.
6013         (lto_input_tree): Register DIE references.
6014         (input_function): Stream DECL_DEBUG_ARGS.
6015         * lto-streamer-out.c: Include debug.h.
6016         (lto_write_tree_1): Output DIE references.
6017         (DFS::DFS_write_tree_body): Follow DECL_ABSTRACT_ORIGIN.
6018         Force a TRANSLATION_UNIT_DECL DECL_CONTEXT for file-scope decls.
6019         (output_function): Stream DECL_DEBUG_ARGS.
6020         * tree-streamer-in.c (lto_input_ts_decl_common_tree_pointers):
6021         Stream DECL_ABSTRACT_ORIGIN.
6022         * tree-streamer-out.c (write_ts_decl_common_tree_pointers): Likewise.
6023         (write_ts_decl_minimal_tree_pointers): Force a TRANSLATION_UNIT_DECL
6024         DECL_CONTEXT for file-scope decls.
6025         * lto-streamer.h (struct dref_entry): Declare.
6026         (dref_queue): Likewise.
6027         * cfgexpand.c (pass_expand::execute): Do not call the
6028         outlining_inline_function hook here.
6029         * lto-wrapper.c (debug_obj): New global.
6030         (tool_cleanup): Unlink it if required.
6031         (debug_objcopy): New function.
6032         (run_gcc): Handle early debug sections in the IL files by
6033         extracting them to separate files, partially linkin them and
6034         feeding the result back as result to the linker.
6035         * config/darwin.h (DEBUG_LTO_INFO_SECTION, DEBUG_LTO_ABBREV_SECTION,
6036         DEBUG_LTO_MACINFO_SECTION, DEBUG_LTO_LINE_SECTION,
6037         DEBUG_STR_LTO_SECTION, DEBUG_LTO_MACRO_SECTION): Put early debug
6038         sections into a separate segment.
6039         * config/darwin.c (darwin_asm_named_section): Handle __GNU_DWARF_LTO
6040         segments.
6041         (darwin_asm_dwarf_section): Likewise.
6042         (darwin_asm_output_dwarf_offset): Likewise.
6043         * config/i386/i386.c (make_resolver_func): Set DECL_IGNORED_P.
6045 2017-08-21  Richard Sandiford  <richard.sandiford@linaro.org>
6046             Alan Hayward  <alan.hayward@arm.com>
6047             David Sherwood  <david.sherwood@arm.com>
6049         * read-md.h (md_reader::record_potential_iterator_use): Replace
6050         pointer argument with an rtx and an index.
6051         * read-rtl.c (iterator_group::apply_iterator): Likewise.
6052         (apply_mode_iterator): Likewise.
6053         (apply_code_iterator): Likewise.
6054         (apply_int_iterator): Likewise.
6055         (apply_subst_iterator): Likewise.
6056         (record_iterator_use): Likewise.
6057         (record_attribute_use): Likewise.
6058         (md_reader::record_potential_iterator_use): Likewise.  Update calls
6059         to record_iterator_use and apply_iterator.
6060         (iterator_use): Replace ptr with x and index.
6061         (attribute_use): Likewise.
6062         (apply_attribute_uses): Update calls to apply_iterator.
6063         (apply_iterators): Likewise.  Update initialization of iterator_use.
6064         (rtx_reader::read_rtx_code): Update calls to record_iterator_use
6065         and record_potential_iterator_use.
6066         (rtx_reader::read_rtx_operand): Likewise.
6068 2017-08-21  Richard Sandiford  <richard.sandiford@linaro.org>
6069             Alan Hayward  <alan.hayward@arm.com>
6070             David Sherwood  <david.sherwood@arm.com>
6072         * varasm.c (const_rtx_hash_1): Don't hash in the mode of a
6073         CONST_WIDE_INT.
6075 2017-08-21  Richard Biener  <rguenther@suse.de>
6077         PR middle-end/81884
6078         * tree-ssa-alias.c (stmt_kills_ref_p): Handle array accesses
6079         at struct end conservatively when comparing common bases.
6081 2017-08-21  Richard Biener  <rguenther@suse.de>
6083         * tree-ssa-loop-im.c (struct lim_aux_data): Add ref index member.
6084         (mem_ref_in_stmt): Remove.
6085         (determine_max_movement): Use ref index to get at the reference.
6086         (invariantness_dom_walker::before_dom_children): Deal with
6087         lim data already initialized.
6088         (gather_mem_refs_stmt): Initialize lim data and record ref index.
6090 2017-08-19  Uros Bizjak  <ubizjak@gmail.com>
6092         * config/i386/i386.h (OPTION_MASK_ISA_ROUND): Remove.
6093         (TARGET_ISA_ROUND): Ditto.
6094         (TARGET_ROUND): Ditto.
6095         * config/i386/i386.c: Substitute TARGET_ROUND with TARGET_SSE4_1.
6096         * config/i386/i386.md: Ditto.
6097         * config/i386/sse.md: Ditto.
6098         * config/i386/i386-builtin.def: Substitute OPTION_MASK_ISA_ROUND
6099         with OPTION_MASK_ISA_SSE4_1.
6101 2017-08-19  Uros Bizjak  <ubizjak@gmail.com>
6103         PR target/81894
6104         * doc/extend.texi (x86 Built-in Functions): Correct the name of
6105         __builtin_ia32_lzcnt_u16.
6107 2017-08-18  Peter Bergner  <bergner@vnet.ibm.com>
6109         PR target/80210
6110         * config/rs6000/rs6000.c (rs6000_activate_target_options): New function.
6111         (rs6000_set_current_function): Rewrite function to use it.
6113 2017-08-18  H.J. Lu  <hongjiu.lu@intel.com>
6115         PR c/53037
6116         * print-tree.c (print_node): Support DECL_WARN_IF_NOT_ALIGN
6117         and TYPE_WARN_IF_NOT_ALIGN.
6118         * stor-layout.c (do_type_align): Merge DECL_WARN_IF_NOT_ALIGN.
6119         (handle_warn_if_not_align): New.
6120         (place_union_field): Call handle_warn_if_not_align.
6121         (place_field): Call handle_warn_if_not_align.
6122         Copy TYPE_WARN_IF_NOT_ALIGN.
6123         (finish_builtin_struct): Copy TYPE_WARN_IF_NOT_ALIGN.
6124         (layout_type): Likewise.
6125         * tree-core.h (tree_type_common): Add warn_if_not_align.  Set
6126         spare to 18.
6127         (tree_decl_common): Add warn_if_not_align.
6128         * tree.c (build_range_type_1): Copy TYPE_WARN_IF_NOT_ALIGN.
6129         * tree.h (TYPE_WARN_IF_NOT_ALIGN): New.
6130         (SET_TYPE_WARN_IF_NOT_ALIGN): Likewise.
6131         (DECL_WARN_IF_NOT_ALIGN): Likewise.
6132         (SET_DECL_WARN_IF_NOT_ALIGN): Likewise.
6133         * doc/extend.texi: Document warn_if_not_aligned attribute.
6134         * doc/invoke.texi: Document -Wif-not-aligned and -Wpacked-not-aligned.
6136 2017-08-17  Martin Liska  <mliska@suse.cz>
6138         PR bootstrap/81864
6139         * tree-loop-distribution.c (ddrs_table): Change type to pointer type.
6140         (get_data_dependence): Use it as pointer type.
6141         (distribute_loop): Likewise.
6143 2017-08-17  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
6145         * config/rs6000/altivec.md (UNSPEC_VMRGOW_DIRECT): New constant.
6146         (p8_vmrgew_v4sf_direct): Generalize to p8_vmrgew_<mode>_direct.
6147         (p8_vmrgow_<mode>_direct): New define_insn.
6148         * config/rs6000/rs6000.c (altivec_expand_vec_perm_const): Properly
6149         handle endianness for vmrgew and vmrgow permute patterns.
6151 2017-08-17  Peter Bergner  <bergner@vnet.ibm.com>
6153         * config/rs6000/altivec.md (VParity): Remove TARGET_VSX_TIMODE.
6154         * config/rs6000/rs6000-cpus.def: Remove comment.
6155         (ISA_2_7_MASKS_SERVER): Delete OPTION_MASK_VSX_TIMODE;
6156         (POWERPC_MASKS): Likewise.
6157         * config/rs6000/rs6000.c (rs6000_hard_regno_mode_ok): Remove unneeded
6158         use of TARGET_VSX_TIMODE.
6159         (rs6000_setup_reg_addr_masks): Change TARGET_VSX_TIMODE to TARGET_VSX.
6160         (rs6000_init_hard_regno_mode_ok): Remove unneeded uses of
6161         TARGET_VSX_TIMODE.  Change use of TARGET_VSX_TIMODE to TARGET_VSX.
6162         (rs6000_option_override_internal): Remove dead code.
6163         (rs6000_legitimize_address): Change TARGET_VSX_TIMODE to TARGET_VSX.
6164         (rs6000_legitimize_reload_address): Likewise.
6165         (rs6000_legitimate_address_p): Likewise.
6166         (rs6000_opt_masks): Delete "vsx-timode".
6167         (rs6000_disable_incompatible_switches): Remove mention of -mvsx-timode
6168         from function comment.
6169         * config/rs6000/rs6000.h (MASK_VSX_TIMODE): Delete.
6170         * config/rs6000/rs6000.md (FMOVE128_GPR): Remove TARGET_VSX_TIMODE.
6171         (V16QI, V8HI, V4SI, V4SF, V2DI, V2DF, V1TI): Remove useless empty
6172         condition.
6173         * config/rs6000/rs6000.opt (mvsx-timode): Replace with stub.
6174         * config/rs6000/vector.md (VEC_IP): Remove TARGET_VSX_TIMODE.
6175         * config/rs6000/vsx.md (VSX_LE_128): Likewise.
6176         (VSX_TI): Likewise.
6177         (VSX_M): Likewise.
6178         (define_peephole2): Likewise.
6180 2017-08-17  Martin Sebor  <msebor@redhat.com>
6182         PR c/81859
6183         * pretty-print.c (pp_format): Use strnlen in %.*s to avoid reading
6184         past the end of an array.
6185         (test_pp_format): Add test cases.
6187 2017-08-17  Richard Sandiford  <richard.sandiford@linaro.org>
6189         * internal-fn.def (CLRSB, CLZ, CTZ, FFS, PARITY, POPCOUNT): Add
6190         missing ECF_NOTHROW flags.
6192 2017-08-17  Peter Bergner  <bergner@vnet.ibm.com>
6194         PR target/72804
6195         * config/rs6000/vsx.md (*vsx_le_permute_<mode>): Add support for
6196         operands residing in integer registers.
6197         (*vsx_le_perm_load_<mode>): Likewise.
6198         (*vsx_le_perm_store_<mode>): Likewise.
6199         (define_peephole2): Add peepholes to optimize the above.
6201 2017-08-17  Marek Polacek  <polacek@redhat.com>
6203         PR middle-end/81814
6204         * fold-const.c (operand_equal_for_comparison_p): Remove code that used
6205         to mimic what shorten_compare did.  Change the return type to bool.
6206         (fold_cond_expr_with_comparison): Update call to
6207         operand_equal_for_comparison_p.
6208         (fold_ternary_loc): Likewise.
6210 2017-08-17  Jackson Woodruff  <jackson.woodruff@arm.com>
6212         * aarch64-simd.md (mov<mode>): No longer force zero immediate into
6213         register.
6214         (*aarch64_simd_mov<mode>): Add new case for stp using zero immediate.
6216 2017-08-17  Richard Biener  <rguenther@suse.de>
6218         * tree-ssa-structalias.c (solve_graph): When propagating
6219         to successors update the graphs succ edges and avoid duplicate work.
6221 2017-08-17  Maxim Ostapenko  <m.ostapenko@samsung.com>
6223         PR target/81861
6224         * config/i386/i386.c (ix86_option_override_internal): Save target
6225         specific options after ix86_stack_protector_guard_reg was changed.
6227 2017-08-17  Richard Biener  <rguenther@suse.de>
6229         PR tree-optimization/81827
6230         * tree-ssa-structalias.c (struct variable_info): Add is_reg_var flag.
6231         (new_var_info): Initialize it conservatively.
6232         (get_call_vi): Mark register vars.
6233         (new_scalar_tmp_constraint_exp): Likewise.
6234         (handle_rhs_call): Likewise.
6235         (handle_const_call): Likewise.
6236         (create_function_info_for): Likewise.
6237         (solve_constraints): Sort varinfos to separate register from
6238         non-register vars to pack points-to solution bitmaps during
6239         iteration.
6241 2017-08-17  Marek Polacek  <polacek@redhat.com>
6243         * gimplify.c (gimplify_adjust_omp_clauses): Compare with 0 instead of 1.
6245 2017-08-17  Richard Biener  <rguenther@suse.de>
6247         * tree-vrp.c (vrp_int_const_binop): Do not set *overflow_p
6248         to true when overflow is undefined and we saturated the result.
6250 2017-08-17  Alan Modra  <amodra@gmail.com>
6252         PR target/80938
6253         * config/rs6000/rs6000.c (rs6000_savres_strategy): Revert 2017-08-09.
6254         Don't use store multiple if only one reg needs saving.
6255         (interesting_frame_related_regno): New function.
6256         (rs6000_frame_related): Don't emit frame info for regs that
6257         don't need saving.
6258         (rs6000_emit_epilogue): Likewise.
6260 2017-08-16  Nathan Sidwell  <nathan@acm.org>
6262         * tree-core.h (tree_type_non_common): Rename binfo to lang_1.
6263         * tree.h (TYPE_BINFO): Use type_non_common.maxval.
6264         (TYPE_LANG_SLOT_1): Use type_non_common.lang_1, for any type.
6265         * tree.c (free_lang_data_in_type): Use else-if chain.  Always
6266         clear TYPE_LANG_1.  Remove obsolete member-function stripping.
6267         (find_decls_types_r): Comment about TYPE_MAX_VALUES_RAW.
6268         (verify_type): Adjust for TYPE_BINFO move.
6269         * lto-streamer-out.c (DFS::DFS_write_tree_body): No need to
6270         process TYPE_BINFO directly.
6271         (hash_tree): Likewise.
6272         * tree-streamer-in.c (lto_input_ts_type_non_common_tree_pointers):
6273         Likewise.
6274         * tree-streamer-out.c (write_ts_type_non_common_tree_pointers):
6275         Likewise.
6277 2017-08-16  David Malcolm  <dmalcolm@redhat.com>
6279         * diagnostic-show-locus.c (colorizer::m_caret): Remove unused field.
6281 2017-08-16  Uros Bizjak  <ubizjak@gmail.com>
6283         PR target/46091
6284         * config/i386/i386.md (*anddi_1_btr): Change predicates of
6285         operand 0 and operand 1 to nomimmediate_operand. Add "m" constraint.
6286         Add ix86_binary_operator_ok to insn constraint.
6287         (*iordi_1_bts): Ditto.
6288         (*xordi_1_btc): Ditto.
6289         (*btsq): Change predicate of operand 0 to nonimmediate_operand.
6290         Update corresponding peephole2 pattern.
6291         (*btrq): Ditto.
6292         (*btcq): Ditto.
6294 2017-08-16  Bin Cheng  <bin.cheng@arm.com>
6296         PR tree-optimization/81832
6297         * tree-ssa-loop-ch.c (should_duplicate_loop_header_p): Don't
6298         copy loop header which has IFN_LOOP_DIST_ALIAS call.
6300 2017-08-16  Marek Polacek  <polacek@redhat.com>
6302         PR middle/81695
6303         * fold-const.c (fold_indirect_ref_1): Restore original behavior
6304         regarding size_zero_node.
6306 2017-08-16  Martin Liska  <mliska@suse.cz>
6308         PR target/81753
6309         * config.gcc: Respect previously set extra_objs in case
6310         of darwin target.
6312 2017-08-16  Richard Sandiford  <richard.sandiford@linaro.org>
6314         PR tree-optimization/81835
6315         * tree-vect-loop.c (vect_is_simple_reduction): Simply checks for
6316         the phi SSA_NAME.  Check that the condition in a COND_EXPR does
6317         not depend on the phi.
6319 2017-08-16  Alan Modra  <amodra@gmail.com>
6321         * config/rs6000/rs6000.c (rs6000_init_hard_regno_mode_ok): Delete
6322         dead code.
6324 2017-08-16  Alan Modra  <amodra@gmail.com>
6326         * config/rs6000/rs6000.c (rs6000_reg_live_or_pic_offset_p): Merge..
6327         (save_reg_p): ..into this.  Update all callers.
6328         (first_reg_to_save): Simplify.
6330 2017-08-16  Alan Modra  <amodra@gmail.com>
6332         * config/rs6000/rs6000.c (rs6000_savres_strategy): Don't restore
6333         fixed regs.
6335 2017-08-15  Joseph Myers  <joseph@codesourcery.com>
6337         PR target/78460
6338         PR target/67712
6339         * config/sh/sh-mem.cc (sh_expand_cmpnstr): Only unroll for
6340         constant count if that count is less than 32.
6342 2017-08-15  Nathan Sidwell  <nathan@acm.org>
6344         * gcc.c (execute): Emit friendlier message if inferior is killed
6345         by an external cause.
6347 2017-08-15  Richard Biener  <rguenther@suse.de>
6349         PR tree-optimization/81790
6350         * tree-ssa-sccvn.c (vn_lookup_simplify_result): Handle both
6351         CONSTRUCTORs from simplifying and VN.
6353 2017-08-14  Martin Sebor  <msebor@redhat.com>
6355         * builtin-attrs.def: Add comments.
6357 2017-08-14  Martin Sebor  <msebor@redhat.com>
6359         PR c/81117
6360         * doc/extend.texi (attribute nonstring): Document new attribute.
6362 2017-08-14  Martin Sebor  <msebor@redhat.com>
6364         PR c/81117
6365         * tree-diagnostic.c (default_tree_printer): Handle %G.
6366         * gimple-pretty-print.h (percent_G_format): Declare new function.
6367         * gimple-pretty-print.c (percent_G_format): Define.
6368         * tree-pretty-print.c (percent_K_format): Add argument.
6370 2017-08-14  Martin Sebor  <msebor@redhat.com>
6372         PR translation/79998
6373         * gimple-ssa-sprintf.c (pass_sprintf_length::handle_gimple_call):
6374         Remove a stray space.
6376 2017-08-14  Uros Bizjak  <ubizjak@gmail.com>
6378         PR target/46091
6379         * config/i386/i386.md (*anddi_1_btr): New insn_and_split pattern.
6380         (*iordi_1_bts): Ditto.
6381         (*xordi_1_btc): Ditto.
6383 2017-08-14  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
6385         PR target/79845
6386         * config/rs6000/linux64.h (INVALID_64BIT): Use quoted strings.
6387         * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin):
6388         Likewise.
6389         * config/rs6000/rs6000.c (rs6000_init_hard_regno_mode_ok): Use
6390         quoted strings, and make more translator-friendly.
6391         (darwin_rs6000_override_options): Likewise.
6392         (rs6000_option_override_internal): Likewise.
6393         (rs6000_return_in_memory): Fix overlong line.
6394         (init_cmulative_args): Use quoted strings, and make more
6395         translator-friendly.
6396         (rs6000_pass_by_reference): Fix overlong line.
6397         (def_builtin): Use quoted strings.
6398         (altivec_expand_predicate_builtin): Use quoted strings, and make
6399         more translator-friendly.
6400         (htm_expand_builtin): Use quoted strings.
6401         (cpu_expand_builtin): Use quoted strings, and make more
6402         translator-friendly.
6403         (altivec_expand_builtin): Likewise.
6404         (paired_expand_predicate_builtin): Likewise.
6405         (rs6000_invalid_builtin): Likewise.
6406         (builtin_function_type): Use quoted strings.
6407         (rs6000_expand_split_stack_prologue): Use quoted strings, and make
6408         more translator-friendly.
6409         (rs6000_trampoline_init): Likewise.
6410         (rs6000_handle_altivec_attribute): Likewise.
6411         (rs6000_inner_target_options): Use quoted strings.
6412         (rs6000_disable_incompatible_switches): Likewise.
6413         * config/rs6000/sysv4.h (SUBTARGET_OVERRIDE_OPTIONS): Use quoted
6414         strings, and make more translator-friendly.
6415         (SUBSUBTARGET_OVERRIDE_OPTIONS): Use quoted strings.
6417 2017-08-14  Bin Cheng  <bin.cheng@arm.com>
6419         PR tree-optimization/81799
6420         * tree-loop-distribution.c (version_loop_by_alias_check): Force
6421         cond_expr to simple gimple operand.
6423 2017-08-14  Wilco Dijkstra  <wdijkstr@arm.com>
6425         PR middle-end/46932
6426         * doc/sourcebuild.texi (autoincdec): Add autoincdec description.
6428 2017-08-14  Georg-Johann Lay  <avr@gjlay.de>
6430         PR target/81754
6431         PR target/81268
6432         * config/avr/avr.opt (mgas-isr-prologues): New Var avr_gasisr_prologues.
6433         * config/avr/avr.md (gasisr, *gasisr): Use it instead of
6434         TARGET_GASISR_PROLOGUES.
6435         * config/avr/avr.c (avr_option_override): Same.
6436         (avr_pass_pre_proep::execute): Same.
6438 2017-08-13  H.J. Lu  <hongjiu.lu@intel.com>
6440         PR target/81820
6441         * config/i386/i386.c (ix86_finalize_stack_frame_flags): Replace
6442         frame pointer with stack pointer - UNITS_PER_WORD in debug insns.
6444 2017-08-13  Uros Bizjak  <ubizjak@gmail.com>
6446         * config/i386/i386.md (*load_tp_<mode>): Redefine as
6447         define_insn_and_split.  Split to a memory load from 0 in
6448         DEFAULT_TLS_SEG_REG address space.  Merge with *load_tp_x32
6449         using PTR mode iterator.
6450         (*load_tp_x32_zext"): Redefine as define_insn_and_split.
6451         Split to a memory load from 0 in DEFAULT_TLS_SEG_REG address space.
6452         (*add_tp_<mode>): Redefine as define_insn_and_split.
6453         Split to an add with a memory load from 0 in DEFAULT_TLS_SEG_REG
6454         address space.  Merge with *add_tp_x32 using PTR mode iterator.
6455         (*add_tp_x32_zext"): Redefine as define_insn_and_split.
6456         Split to an add with a  memory load from 0 in
6457         DEFAULT_TLS_SEG_REG address space.
6459 2017-08-12  Andrew Pinski  <apinski@cavium.com>
6461         * config/aarch64/aarch64-option-extensions.def (rdma):
6462         Fix feature string to what Linux prints out in /proc/cpuinfo.
6464 2017-08-12  Pierre-Marie de Rodat  <derodat@adacore.com>
6466         PR ada/79542
6467         * dwarf2out.c (modified_type_die): For C typedef types that have
6468         an ultimate origin, process the ultimate origin instead of the
6469         input type.
6470         (gen_typedef_die): Assert that input DECLs have no ultimate
6471         origin.
6472         (gen_type_die_with_usage): For typedef variants that have an
6473         ultimate origin, just call gen_decl_die on the original DECL.
6474         (process_scope_var): Avoid creating DIEs for local typedefs and
6475         concrete static variables.
6477 2017-08-12  Alan Modra  <amodra@gmail.com>
6479         PR target/81170
6480         PR target/81295
6481         * config/rs6000/sysv4.h (STARTFILE_LINUX_SPEC): Upgrade to
6482         match gnu-user.h startfile.
6483         (ENDFILE_LINUX_SPEC): Similarly.
6485 2017-08-11  Thomas Schwinge  <thomas@codesourcery.com>
6487         PR lto/81430
6488         * config/nvptx/nvptx.c (nvptx_override_options_after_change):
6489         Remove function.
6490         (TARGET_OVERRIDE_OPTIONS_AFTER_CHANGE): Remove definition.
6492 2017-08-11  Tamar Christina  <tamar.christina@arm.com>
6493         * config/aarch64/aarch64.md (mov<mode>): Change.
6494         (*movhf_aarch64, *movsf_aarch64, *movdf_aarch64):
6495         aarch64_reg_or_fp_float into aarch64_reg_or_fp_zero.
6496         * config/aarch64/predicates.md (aarch64_reg_or_fp_float): Removed.
6498 2017-08-11  Eric Botcazou  <ebotcazou@adacore.com>
6500         * tree-sra.c (build_access_from_expr_1): Use more precise diagnostics
6501         for storage order barriers.
6503 2017-08-11  Martin Liska  <mliska@suse.cz>
6505         PR tree-opt/79987
6506         * tree-chkp.c (chkp_get_bounds_for_decl_addr): Do not instrument
6507         variables of void type.
6509 2017-08-11  Martin Liska  <mliska@suse.cz>
6511         * asan.c (asan_protect_global): Replace ASM_OUTPUT_DEF with
6512         TARGET_SUPPORTS_ALIASES.
6513         * cgraph.c (cgraph_node::create_same_body_alias): Likewise.
6514         * ipa-visibility.c (can_replace_by_local_alias): Likewise.
6515         (optimize_weakref): Likewise.
6516         * symtab.c (symtab_node::noninterposable_alias): Likewise.
6517         * varpool.c (varpool_node::create_extra_name_alias): Likewise.
6518         * defaults.h: Introduce TARGET_SUPPORTS_ALIASES.
6520 2017-08-11  Martin Liska  <mliska@suse.cz>
6522         PR ipa/81213
6523         * config/i386/i386.c (make_resolver_func): Do complete
6524         refactoring of the function.
6526 2017-08-10  Uros Bizjak  <ubizjak@gmail.com>
6528         PR target/81708
6529         * config/i386/i386.opt (mstack-protector-guard-symbol=): New option
6530         * config/i386/i386.c (ix86_stack_protect_guard): Use
6531         ix86_stack_protect_guard_symbol_str to generate varible declaration.
6532         * doc/invoke.texi (x86 Options): Document
6533         -mstack-protector-guard-symbol= option.
6535 2017-08-10  Uros Bizjak  <ubizjak@gmail.com>
6537         * config/i386/i386-protos.h (ix86_split_stack_guard): New prototype.
6538         * config/i386/i386.c (ix86_split_stack_guard): New function.
6539         (ix86_xpand_split_stack_prologue): Call ix86_split_stack_guard.
6540         (ix86_legitimate_address_p) <case UNSPEC_STACK_CHECK>: Remove.
6541         (i386_asm_output_addr_const_extra) <case UNSPEC_STACK_CHECK>: Ditto.
6542         (optput_pic_addr_const): Remove UNSPEC_STACK_CHECK handling.
6543         * config/i386/i386.md (unspec): Remove UNSPEC_STACK_CHECK.
6544         (split_stack_space_check): Call ix86_split_stack_guard.
6546 2017-08-10  Martin Sebor  <msebor@redhat.com>
6548         * print-tree.c (print_node): Print location using the established
6549         format %s:%i%i.
6550         Replace spaces with colons.
6551         (debug_raw, debug): Ditto.
6553 2017-08-10  Martin Sebor  <msebor@redhat.com>
6555         PR c++/81586
6556         * pretty-print.c (pp_format): Correct the handling of %s precision.
6558 2017-08-10  H.J. Lu  <hongjiu.lu@intel.com>
6560         PR target/81736
6561         * config/i386/i386.c (ix86_finalize_stack_realign_flags): Renamed
6562         to ...
6563         (ix86_finalize_stack_frame_flags): This.  Also clear
6564         frame_pointer_needed if -fno-omit-frame-pointer is used without
6565         stack access.
6566         (ix86_expand_prologue): Replace ix86_finalize_stack_realign_flags
6567         with ix86_finalize_stack_frame_flags.
6568         (ix86_expand_epilogue): Likewise.
6569         (ix86_expand_split_stack_prologue): Likewise.
6570         * doc/invoke.texi: Add a note for -fno-omit-frame-pointer.
6572 2017-08-10  Martin Liska  <mliska@suse.cz>
6574         PR c++/81355
6575         * c-attribs.c (handle_target_attribute):
6576         Report warning for an empty string argument of target attribute.
6578 2017-08-09  Jakub Jelinek  <jakub@redhat.com>
6580         PR c/81687
6581         * omp-low.c (omp_copy_decl): Don't remap FORCED_LABEL or DECL_NONLOCAL
6582         LABEL_DECLs.
6583         * tree-cfg.c (move_stmt_op): Don't adjust DECL_CONTEXT of FORCED_LABEL
6584         or DECL_NONLOCAL labels.
6585         (move_stmt_r) <case GIMPLE_LABEL>: Adjust DECL_CONTEXT of FORCED_LABEL
6586         or DECL_NONLOCAL labels here.
6588 2017-08-09  Will Schmidt  <will_schmidt@vnet.ibm.com>
6590         * config/rs6000/rs6000.c (rs6000_option_override_internal): Add blurb
6591         to indicate when early gimple folding has been disabled.
6592         (rs6000_gimple_fold_builtin): Add debug content.
6593         (rs6000_invalid_builtin): Fix whitespace.
6594         (rs6000_expand_builtin): Fix whitespace.
6595         * config/rs6000/rs6000.opt: Add option for -mfold-gimple.
6597 2017-08-09  Segher Boessenkool  <segher@kernel.crashing.org>
6599         PR target/80938
6600         * config/rs6000/rs6000.c (rs6000_savres_strategy): Don't use
6601         SAVE_MULTIPLE if not all the registers that saves, should be saved.
6603 2017-08-09  Jim Wilson  <jim.wilson@linaro.org>
6605         * config/aarch64/aarch64-cores.def (falkor): Use falkor pipeline.
6606         (qdf24xx): Likewise.
6607         * config/aarch64/aarch64.md: Include falkor.md.
6608         * config/aarch64/falkor.md: New.
6610 2017-08-09  Marek Polacek  <polacek@redhat.com>
6612         PR c/81233
6613         * diagnostic-core.h (emit_diagnostic_valist): Add declaration.
6614         * diagnostic.c (emit_diagnostic): Add a comment.
6615         (emit_diagnostic_valist): New function.
6617 2017-08-09  Marek Polacek  <polacek@redhat.com>
6619         PR c/81417
6620         * input.c (make_location): New overload.
6621         * input.h (make_location): Declare.
6623 2017-08-08  Alan Modra  <amodra@gmail.com>
6624             H.J. Lu  <hongjiu.lu@intel.com>
6626         PR driver/81523
6627         * gcc.c (NO_PIE_SPEC): Delete.
6628         (PIE_SPEC): Define as !no-pie/pie.  Move static|shared|r
6629         exclusion..
6630         (LINK_PIE_SPEC): ..to here.
6631         (LINK_COMMAND_SPEC): Support -no-pie.
6632         * config/gnu-user.h (GNU_USER_TARGET_STARTFILE_SPEC): Correct
6633         chain of crtbegin*.o selection, update for PIE_SPEC changes and
6634         format.
6635         (GNU_USER_TARGET_ENDFILE_SPEC): Similarly.
6636         * config/sol2.h (STARTFILE_CRTBEGIN_SPEC): Similarly.
6637         (ENDFILE_CRTEND_SPEC): Similarly.
6639 2017-08-08  Uros Bizjak  <ubizjak@gmail.com>
6641         PR target/81708
6642         * config/i386/i386.opt (mstack-protector-guard-reg=): New option
6643         (mstack-protector-guard-offset=): Ditto.
6644         * config/i386/i386.c (ix86_option_override): Handle
6645         -mstack-protector-guard-reg= and -mstack-protector-guard-offset=
6646         options.
6647         (ix86_stack_protect_guard): Use ix86_stack_protect_guard_reg and
6648         ix86_stack_protect_guard_offset variables.
6649         (TARGET_STACK_PROTECT_GUARD): Always define.
6650         * doc/invoke.texi (x86 Options): Document -mstack-protector-guard-reg=
6651         and -mstack-protector-guard-offset= options.
6653 2017-08-08  Bin Cheng  <bin.cheng@arm.com>
6655         * tree-ssa-loop-ivopts.c (relate_compare_use_with_all_cands): Handle
6656         boundary case for the last candidate.
6658 2017-08-08  Bin Cheng  <bin.cheng@arm.com>
6660         * doc/invoke.texi: Document -ftree-loop-distribution for O3.
6661         * opts.c (default_options_table): Add OPT_ftree_loop_distribution.
6663 2017-08-08  Tamar Christina  <tamar.christina@arm.com>
6665         PR middle-end/19706
6666         * config/aarch64/aarch64.md (xorsign<mode>3): New optabs.
6667         * config/aarch64/aarch64-builtins.c
6668         (aarch64_builtin_vectorized_function): Added CASE_CFN_XORSIGN.
6669         * config/aarch64/aarch64-simd-builtins.def: Added xorsign BINOP.
6670         * config/aarch64/aarch64-simd.md: Added xorsign<mode>3
6672 2017-08-08  Tamar Christina  <tamar.christina@arm.com>
6673             Andrew Pinski <pinskia@gmail.com>
6675         PR middle-end/19706
6676         * internal-fn.def (XORSIGN): New.
6677         * optabs.def (xorsign_optab): New.
6678         * tree-ssa-math-opts.c (is_copysign_call_with_1): New.
6679         (convert_expand_mult_copysign): New.
6680         (pass_optimize_widening_mul::execute): Call
6681         convert_expand_mult_copysign.
6683 2017-08-08  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
6685         PR tree-optimization/81354
6686         * gimple-ssa-strength-reduction.c (create_add_on_incoming_edge):
6687         Insert on edges rather than explicitly creating landing pads.
6688         (analyze_candidates_and_replace): Commit edge inserts.
6690 2017-08-08  Richard Biener  <rguenther@suse.de>
6692         PR middle-end/81719
6693         * tree-ssa-loop-niter.c: Include tree-dfa.h.
6694         (expand_simple_operations): Also look through ADDR_EXPRs with
6695         MEM_REF bases treating them as POINTER_PLUS_EXPR.
6697 2017-08-08  Richard Biener  <rguenther@suse.de>
6699         PR tree-optimization/81723
6700         * tree-vect-slp.c (struct bst_traits): New hash traits.
6701         (bst_fail): New global.
6702         (vect_build_slp_tree_2): New worker, split out from ...
6703         (vect_build_slp_tree): ... this now wrapping it with using
6704         bst_fail set to cache SLP tree build fails.  Properly handle
6705         max_tree_size.
6706         (vect_analyze_slp_instance): Allocate and free bst_fail.
6708 2017-08-08  Martin Liska  <mliska@suse.cz>
6710         PR tree-opt/81696
6711         * ipa-icf-gimple.c (func_checker::compare_cst_or_decl): Consider
6712         LABEL_DECLs that can be from a different function.
6714 2017-08-08  Bin Cheng  <bin.cheng@arm.com>
6716         PR tree-optimization/81744
6717         * tree-predcom.c (prepare_finalizers_chain): Deep copy expr of
6718         loop's number of iterations.
6720 2017-08-08  Martin Liska  <mliska@suse.cz>
6722         * asan.c: Include header files.
6723         * attribs.c (build_decl_attribute_variant): New function moved
6724         from tree.[ch].
6725         (build_type_attribute_qual_variant): Likewise.
6726         (cmp_attrib_identifiers): Likewise.
6727         (simple_cst_list_equal): Likewise.
6728         (omp_declare_simd_clauses_equal): Likewise.
6729         (attribute_value_equal): Likewise.
6730         (comp_type_attributes): Likewise.
6731         (build_type_attribute_variant): Likewise.
6732         (lookup_ident_attribute): Likewise.
6733         (remove_attribute): Likewise.
6734         (merge_attributes): Likewise.
6735         (merge_type_attributes): Likewise.
6736         (merge_decl_attributes): Likewise.
6737         (merge_dllimport_decl_attributes): Likewise.
6738         (handle_dll_attribute): Likewise.
6739         (attribute_list_equal): Likewise.
6740         (attribute_list_contained): Likewise.
6741         * attribs.h (lookup_attribute): New function moved from tree.[ch].
6742         (lookup_attribute_by_prefix): Likewise.
6743         * bb-reorder.c: Include header files.
6744         * builtins.c: Likewise.
6745         * calls.c: Likewise.
6746         * cfgexpand.c: Likewise.
6747         * cgraph.c: Likewise.
6748         * cgraphunit.c: Likewise.
6749         * convert.c: Likewise.
6750         * dwarf2out.c: Likewise.
6751         * final.c: Likewise.
6752         * fold-const.c: Likewise.
6753         * function.c: Likewise.
6754         * gimple-expr.c: Likewise.
6755         * gimple-fold.c: Likewise.
6756         * gimple-pretty-print.c: Likewise.
6757         * gimple.c: Likewise.
6758         * gimplify.c: Likewise.
6759         * hsa-common.c: Likewise.
6760         * hsa-gen.c: Likewise.
6761         * internal-fn.c: Likewise.
6762         * ipa-chkp.c: Likewise.
6763         * ipa-cp.c: Likewise.
6764         * ipa-devirt.c: Likewise.
6765         * ipa-fnsummary.c: Likewise.
6766         * ipa-inline.c: Likewise.
6767         * ipa-visibility.c: Likewise.
6768         * ipa.c: Likewise.
6769         * lto-cgraph.c: Likewise.
6770         * omp-expand.c: Likewise.
6771         * omp-general.c: Likewise.
6772         * omp-low.c: Likewise.
6773         * omp-offload.c: Likewise.
6774         * omp-simd-clone.c: Likewise.
6775         * opts-global.c: Likewise.
6776         * passes.c: Likewise.
6777         * predict.c: Likewise.
6778         * sancov.c: Likewise.
6779         * sanopt.c: Likewise.
6780         * symtab.c: Likewise.
6781         * toplev.c: Likewise.
6782         * trans-mem.c: Likewise.
6783         * tree-chkp.c: Likewise.
6784         * tree-eh.c: Likewise.
6785         * tree-into-ssa.c: Likewise.
6786         * tree-object-size.c: Likewise.
6787         * tree-parloops.c: Likewise.
6788         * tree-profile.c: Likewise.
6789         * tree-ssa-ccp.c: Likewise.
6790         * tree-ssa-live.c: Likewise.
6791         * tree-ssa-loop.c: Likewise.
6792         * tree-ssa-sccvn.c: Likewise.
6793         * tree-ssa-structalias.c: Likewise.
6794         * tree-ssa.c: Likewise.
6795         * tree-streamer-in.c: Likewise.
6796         * tree-vectorizer.c: Likewise.
6797         * tree-vrp.c: Likewise.
6798         * tsan.c: Likewise.
6799         * ubsan.c: Likewise.
6800         * varasm.c: Likewise.
6801         * varpool.c: Likewise.
6802         * tree.c: Remove functions moved to attribs.[ch].
6803         * tree.h: Likewise.
6804         * config/aarch64/aarch64.c: Add attrs.h header file.
6805         * config/alpha/alpha.c: Likewise.
6806         * config/arc/arc.c: Likewise.
6807         * config/arm/arm.c: Likewise.
6808         * config/avr/avr.c: Likewise.
6809         * config/bfin/bfin.c: Likewise.
6810         * config/c6x/c6x.c: Likewise.
6811         * config/cr16/cr16.c: Likewise.
6812         * config/cris/cris.c: Likewise.
6813         * config/darwin.c: Likewise.
6814         * config/epiphany/epiphany.c: Likewise.
6815         * config/fr30/fr30.c: Likewise.
6816         * config/frv/frv.c: Likewise.
6817         * config/ft32/ft32.c: Likewise.
6818         * config/h8300/h8300.c: Likewise.
6819         * config/i386/winnt.c: Likewise.
6820         * config/ia64/ia64.c: Likewise.
6821         * config/iq2000/iq2000.c: Likewise.
6822         * config/lm32/lm32.c: Likewise.
6823         * config/m32c/m32c.c: Likewise.
6824         * config/m32r/m32r.c: Likewise.
6825         * config/m68k/m68k.c: Likewise.
6826         * config/mcore/mcore.c: Likewise.
6827         * config/microblaze/microblaze.c: Likewise.
6828         * config/mips/mips.c: Likewise.
6829         * config/mmix/mmix.c: Likewise.
6830         * config/mn10300/mn10300.c: Likewise.
6831         * config/moxie/moxie.c: Likewise.
6832         * config/msp430/msp430.c: Likewise.
6833         * config/nds32/nds32-isr.c: Likewise.
6834         * config/nds32/nds32.c: Likewise.
6835         * config/nios2/nios2.c: Likewise.
6836         * config/nvptx/nvptx.c: Likewise.
6837         * config/pa/pa.c: Likewise.
6838         * config/pdp11/pdp11.c: Likewise.
6839         * config/powerpcspe/powerpcspe.c: Likewise.
6840         * config/riscv/riscv.c: Likewise.
6841         * config/rl78/rl78.c: Likewise.
6842         * config/rx/rx.c: Likewise.
6843         * config/s390/s390.c: Likewise.
6844         * config/sh/sh.c: Likewise.
6845         * config/sol2.c: Likewise.
6846         * config/sparc/sparc.c: Likewise.
6847         * config/spu/spu.c: Likewise.
6848         * config/stormy16/stormy16.c: Likewise.
6849         * config/tilegx/tilegx.c: Likewise.
6850         * config/tilepro/tilepro.c: Likewise.
6851         * config/v850/v850.c: Likewise.
6852         * config/vax/vax.c: Likewise.
6853         * config/visium/visium.c: Likewise.
6854         * config/xtensa/xtensa.c: Likewise.
6856 2017-08-07  Michael Meissner  <meissner@linux.vnet.ibm.com>
6858         PR target/81593
6859         * config/rs6000/vsx.md (vsx_concat_<mode>, VSX_D): Cleanup
6860         constraints since the -mupper-regs-* switches have been
6861         eliminated.
6862         (vsx_concat_<mode>_1): New combiner insns to recognize inserting
6863         into a vector from a double word element that was extracted from
6864         another vector, and eliminate extra XXPERMDI instructions.
6865         (vsx_concat_<mode>_2): Likewise.
6866         (vsx_concat_<mode>_3): Likewise.
6867         (vsx_set_<mode>, VSX_D): Rewrite vector set in terms of vector
6868         concat to allow optimizing inserts from previous extracts.
6870 2017-08-07  Uros Bizjak  <ubizjak@gmail.com>
6872         * config/i386/i386.c (ix86_stack_protect_guard): Generate
6873         memory reference to a SSP offset in TLS address space.
6874         (ix86_print_operand) <case '@'>: Remove.
6875         (ix86_print_operand_punct_valid_p): Remove '@' code.
6876         * config/i386/i386.md (unspec): Remove UNSPEC_SP_TLS_SET and
6877         UNSPEC_SP_TLS_TEST.
6878         (stack_tls_protect_set_<mode>): Remove.
6879         (stack_protect_set): Do not call gen_stack_tls_protect_set_<mode>.
6880         (stack_tls_protect_test_<mode>): Remove.
6881         (stack_protect_test): Do not call gen_stack_tls_protect_test_<mode>.
6883 2017-08-07  Olivier Hainque  <hainque@adacore.com>
6885         PR target/81755
6886         * config/vxworksae.h (VXWORKS_HAVE_TLS): Define.
6888 2017-08-07  Douglas Rupp  <rupp@adacore.com>
6890         * Makefile.in (install-mkheaders): Fix typo, where the multi_dir
6891         variable was referenced as multidir in command.
6893 2017-08-07  Jakub Jelinek  <jakub@redhat.com>
6895         PR c/69389
6896         * gimplify.c (goa_stabilize_expr): Handle BIT_INSERT_EXPR and
6897         BIT_FIELD_REF.
6899 2017-08-07  Martin Liska  <mliska@suse.cz>
6901         * config/m32c/m32c.c: Add include of stringpool.h and attribs.h.
6902         * config/rl78/rl78.c: Add include of attribs.h.
6903         * config/sh/sh.c: Likewise.
6904         * config/v850/v850.c: Likewise.
6906 2017-08-07  Tom de Vries  <tom@codesourcery.com>
6908         PR middle-end/78266
6909         * omp-expand.c (expand_oacc_for): Ensure diff_type is large enough.
6911 2017-08-07  Martin Liska  <mliska@suse.cz>
6913         * config/mips/mips.c: Include attribs.h.
6915 2017-08-07  Thomas Koenig  <tkoenig@gcc.gnu.org>
6917         PR fortran/68829
6918         * doc/invoke.texi: Document change in behvaior for -Ofast for
6919         Fortran.
6921 2017-08-07  Wilco Dijkstra  <wdijkstr@arm.com>
6923         * config/aarch64/aarch64.c (aarch64_pushwb_single_reg):
6924         Use gen_frame_mem.
6925         (aarch64_pop_regs): Likewise.
6926         (aarch64_gen_load_pair): Likewise.
6927         (aarch64_save_callee_saves): Likewise.
6928         (aarch64_restore_callee_saves): Likewise.
6930 2017-08-07  H.J. Lu  <hongjiu.lu@intel.com>
6932         * config/i386/i386.c: Revert the last change.
6934 2017-08-07  H.J. Lu  <hongjiu.lu@intel.com>
6936         PR target/81736
6937         * config/i386/i386.c (ix86_finalize_stack_realign_flags): Renamed
6938         to ...
6939         (ix86_finalize_stack_frame_flags): This.  Also clear
6940         frame_pointer_needed if -fno-omit-frame-pointer is used without
6941         stack access.
6942         (ix86_expand_prologue): Replace ix86_finalize_stack_realign_flags
6943         with ix86_finalize_stack_frame_flags.
6944         (ix86_expand_epilogue): Likewise.
6945         (ix86_expand_split_stack_prologue): Likewise.
6947 2017-08-07  H.J. Lu  <hongjiu.lu@intel.com>
6949         PR target/81743
6950         * config/i386/i386.c (get_builtin_code_for_version): Set priority
6951         to P_AES for Westmere.
6953 2017-08-07  Jonathan Yong  <10walls@gmail.com>
6955         * config/i386/mingw.opt (fset-stack-executable): Removed.
6956         * config/i386/cygming.opt (fset-stack-executable): Moved
6957         from mingw.opt.
6958         * config/i386/cygwin.h: Define CHECK_EXECUTE_STACK_ENABLED.
6960 2017-08-07  Segher Boessenkool  <segher@kernel.crashing.org>
6962         * print-rtl.c (print_exp): Print NOT as "~" instead of as "!".
6964 2017-08-07  Marek Polacek  <polacek@redhat.com>
6966         PR middle-end/81737
6967         * fold-const.c (fold_indirect_ref_1): Check type_domain.
6969 2017-08-07  Martin Liska  <mliska@suse.cz>
6971         * attribs.h (canonicalize_attr_name): New function.
6972         (cmp_attribs): Move from c-format.c and adjusted.
6973         (is_attribute_p): Moved from tree.h.
6974         * tree-inline.c: Add new includes.
6975         * tree.c (cmp_attrib_identifiers): Use cmp_attribs.
6976         (private_is_attribute_p): Remove.
6977         (private_lookup_attribute): Likewise.
6978         (private_lookup_attribute_by_prefix): Simplify.
6979         (remove_attribute): Use is_attribute_p.
6980         * tree.h: Remove removed declarations.
6982 2017-08-07  Jakub Jelinek  <jakub@redhat.com>
6984         PR middle-end/81698
6985         * stmt.c (emit_case_dispatch_table): Add DEFAULT_EDGE argument,
6986         instead of computing it in the function.  Formatting fix.
6987         (expand_case): Don't rely on default_edge being the first edge,
6988         clear it if removing it, pass default_edge to
6989         emit_case_dispatch_table.
6990         (expand_sjlj_dispatch_table): Pass NULL as DEFAULT_EDGE, formatting
6991         fix.
6993 2017-08-06  Uros Bizjak  <ubizjak@gmail.com>
6995         * config/alpha/alpha.c (alpha_reorg): If trap is the last active
6996         insn in the function, emit NOP after the insn.
6998 2017-08-06  Tom de Vries  <tom@codesourcery.com>
7000         * omp-expand.c (expand_oacc_for): Add missing edge probability for tile
7001         and element loops.
7003 2017-08-06  Tom de Vries  <tom@codesourcery.com>
7005         * omp-expand.c (expand_oacc_for): Add missing edge probability for chunk
7006         loop.
7008 2017-08-04  Yury Gribov  <tetra2005@gmail.com>
7010         PR tree-optimization/57371
7011         * match.pd: New pattern.
7013 2017-08-04  Marek Polacek  <polacek@redhat.com>
7015         PR middle-end/81695
7016         * fold-const.c (fold_indirect_ref_1): For ((int *)&a + 4 -> a[1],
7017         perform the computation in offset_int.
7019 2017-08-04  Richard Sandiford  <richard.sandiford@linaro.org>
7021         PR tree-optimization/81136
7022         * tree-vectorizer.h: Include tree-hash-traits.h.
7023         (vec_base_alignments): New typedef.
7024         (vec_info): Add a base_alignments field.
7025         (vect_record_base_alignments): Declare.
7026         * tree-data-ref.h (data_reference): Add an is_conditional_in_stmt
7027         field.
7028         (DR_IS_CONDITIONAL_IN_STMT): New macro.
7029         (create_data_ref): Add an is_conditional_in_stmt argument.
7030         * tree-data-ref.c (create_data_ref): Likewise.  Use it to initialize
7031         the is_conditional_in_stmt field.
7032         (data_ref_loc): Add an is_conditional_in_stmt field.
7033         (get_references_in_stmt): Set the is_conditional_in_stmt field.
7034         (find_data_references_in_stmt): Update call to create_data_ref.
7035         (graphite_find_data_references_in_stmt): Likewise.
7036         * tree-ssa-loop-prefetch.c (determine_loop_nest_reuse): Likewise.
7037         * tree-vect-data-refs.c (vect_analyze_data_refs): Likewise.
7038         (vect_record_base_alignment): New function.
7039         (vect_record_base_alignments): Likewise.
7040         (vect_compute_data_ref_alignment): Adjust base_addr and aligned_to
7041         for nested statements even if we fail to compute a misalignment.
7042         Use pooled base alignments for unconditional references.
7043         (vect_find_same_alignment_drs): Compare base addresses instead
7044         of base objects.
7045         (vect_analyze_data_refs_alignment): Call vect_record_base_alignments.
7046         * tree-vect-slp.c (vect_slp_analyze_bb_1): Likewise.
7048 2017-08-04  Richard Sandiford  <richard.sandiford@linaro.org>
7050         * tree-vectorizer.h (vec_info): Add a constructor and destructor.
7051         Add an explicit name for the enum.  Use auto_vec for slp_instances
7052         and grouped_stores.
7053         (_loop_vec_info): Add a constructor and destructor.  Use auto_vec
7054         for all vectors.
7055         (_bb_vec_info): Add a constructor and destructor.
7056         (vinfo_for_stmt): Return NULL for uids of -1 as well.
7057         (destroy_loop_vec_info): Delete.
7058         (vect_destroy_datarefs): Likewise.
7059         * tree-vectorizer.c (vect_destroy_datarefs): Delete.
7060         (vec_info::vec_info): New function.
7061         (vec_info::~vec_info): Likewise.
7062         (vectorize_loops): Use delete instead of destroy_loop_vec_info.
7063         * tree-parloops.c (gather_scalar_reductions): Use delete instead of
7064         destroy_loop_vec_info.
7065         * tree-vect-loop.c (new_loop_vec_info): Replace with...
7066         (_loop_vec_info::_loop_vec_info): ...this.
7067         (destroy_loop_vec_info): Replace with...
7068         (_loop_vec_info::~_loop_vec_info): ...this.  Unconditionally delete
7069         the stmt_vec_infos.  Leave handling of vec_info information to its
7070         destructor.  Remove explicit vector releases.
7071         (vect_analyze_loop_form): Use new instead of new_loop_vec_info.
7072         (vect_analyze_loop): Use delete instead of destroy_loop_vec_info.
7073         * tree-vect-slp.c (new_bb_vec_info): Replace with...
7074         (_bb_vec_info::_bb_vec_info): ...this.  Don't reserve space in
7075         BB_VINFO_GROUPED_STORES or BB_VINFO_SLP_INSTANCES.
7076         (destroy_bb_vec_info): Replace with...
7077         (_bb_vec_info::~_bb_vec_info): ...this.  Leave handling of vec_info
7078         information to its destructor.
7079         (vect_slp_analyze_bb_1): Use new and delete instead of
7080         new_bb_vec_info and destroy_bb_vec_info.
7081         (vect_slp_bb): Replace 2 calls to destroy_bb_vec_info with a
7082         single delete.
7084 2017-08-04  Richard Sandiford  <richard.sandiford@linaro.org>
7086         * tree-data-ref.h (subscript): Add access_fn field.
7087         (data_dependence_relation): Add could_be_independent_p.
7088         (SUB_ACCESS_FN, DDR_COULD_BE_INDEPENDENT_P): New macros.
7089         (same_access_functions): Move to tree-data-ref.c.
7090         * tree-data-ref.c (ref_contains_union_access_p): New function.
7091         (access_fn_component_p): Likewise.
7092         (access_fn_components_comparable_p): Likewise.
7093         (dr_analyze_indices): Add a reference to access_fn_component_p.
7094         (dump_data_dependence_relation): Use SUB_ACCESS_FN instead of
7095         DR_ACCESS_FN.
7096         (constant_access_functions): Likewise.
7097         (add_other_self_distances): Likewise.
7098         (same_access_functions): Likewise.  (Moved from tree-data-ref.h.)
7099         (initialize_data_dependence_relation): Use XCNEW and remove
7100         explicit zeroing of DDR_REVERSED_P.  Look for a subsequence
7101         of access functions that have the same type.  Allow the
7102         subsequence to end with different bases in some circumstances.
7103         Record the chosen access functions in SUB_ACCESS_FN.
7104         (build_classic_dist_vector_1): Replace ddr_a and ddr_b with
7105         a_index and b_index.  Use SUB_ACCESS_FN instead of DR_ACCESS_FN.
7106         (subscript_dependence_tester_1): Likewise dra and drb.
7107         (build_classic_dist_vector): Update calls accordingly.
7108         (subscript_dependence_tester): Likewise.
7109         * tree-ssa-loop-prefetch.c (determine_loop_nest_reuse): Check
7110         DDR_COULD_BE_INDEPENDENT_P.
7111         * tree-vectorizer.h (LOOP_REQUIRES_VERSIONING_FOR_ALIAS): Test
7112         comp_alias_ddrs instead of may_alias_ddrs.
7113         * tree-vect-data-refs.c (vect_analyze_possibly_independent_ddr):
7114         New function.
7115         (vect_analyze_data_ref_dependence): Use it if
7116         DDR_COULD_BE_INDEPENDENT_P, but fall back to using the recorded
7117         distance vectors if that fails.
7118         (dependence_distance_ge_vf): New function.
7119         (vect_prune_runtime_alias_test_list): Use it.  Don't clear
7120         LOOP_VINFO_MAY_ALIAS_DDRS.
7122 2017-08-04  Richard Biener  <rguenther@suse.de>
7124         PR middle-end/81705
7125         * fold-const.c (fold_binary_loc): Properly restrict
7126         minus_var0 && minus_var1 case when associating undefined overflow
7127         entities.
7129 2017-08-04  Tom de Vries  <tom@codesourcery.com>
7131         * omp-simd-clone.c (simd_clone_adjust): Add missing edge probability.
7133 2017-08-03  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
7135         * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin):
7136         Don't start diagnostic messages with a capital letter.
7137         * config/rs6000/rs6000.c (rs6000_option_override_internal):
7138         Likewise.
7139         (rs6000_invalid_builtin): Likewise.
7140         (rs6000_trampoline_init): Likewise.
7142 2017-08-03  Jakub Jelinek  <jakub@redhat.com>
7144         PR target/81621
7145         * bb-reorder.c (pass_partition_blocks::execute): Return TODO_df_finish
7146         after setting changeable df flags.
7148 2017-08-03  Richard Biener  <rguenther@suse.de>
7150         * tree-ssa-reassoc.c (should_break_up_subtract): Also break
7151         up if the use is in USE - X.
7153 2017-08-03  Alexander Monakov  <amonakov@ispras.ru>
7155         * toplev.c (dumpfile.h): New include.
7156         (internal_error_reentered): New static function.  Use it...
7157         (internal_error_function): ...here to handle reentered internal_error.
7159 2017-08-03  Richard Biener  <rguenther@suse.de>
7161         PR middle-end/81148
7162         * fold-const.c (split_tree): Add minus_var and minus_con
7163         arguments, remove unused loc arg.  Never generate NEGATE_EXPRs
7164         here but always use minus_*.
7165         (associate_trees): Assert we never associate with MINUS_EXPR
7166         and NULL first operand.  Do not recurse for PLUS_EXPR operands
7167         when associating as MINUS_EXPR either.
7168         (fold_binary_loc): Track minus_var and minus_con.
7170 2017-08-03  Tom de Vries  <tom@codesourcery.com>
7172         PR lto/81430
7173         * tree-streamer-in.c (lto_input_ts_function_decl_tree_pointers): If
7174         ACCEL_COMPILER, apply finish_options on
7175         DECL_FUNCTION_SPECIFIC_OPTIMIZATION.
7177 2017-08-03  Tom de Vries  <tom@codesourcery.com>
7179         PR target/81662
7180         * config/nvptx/nvptx.c (nvptx_option_override): Emit sorry if
7181         function_entry_patch_area_size > 0.
7183 2017-08-03  Jakub Jelinek  <jakub@redhat.com>
7185         PR driver/81650
7186         * calls.c (alloc_max_size): Use HOST_WIDE_INT_UC (10??)
7187         instead of 10??LU, perform unit multiplication in wide_int,
7188         don't change alloc_object_size_limit if the limit is larger
7189         than SSIZE_MAX.
7191         PR tree-optimization/81655
7192         PR tree-optimization/81588
7193         * tree-ssa-reassoc.c (optimize_range_tests_var_bound): Handle also
7194         the case when ranges[i].low and high are 1 for unsigned type with
7195         precision 1.
7197         PR middle-end/81052
7198         * omp-low.c (diagnose_sb_0): Handle flag_openmp_simd like flag_openmp.
7199         (pass_diagnose_omp_blocks::gate): Enable also for flag_openmp_simd.
7201 2017-08-03  Prathamesh Kulkarni  <prathamesh.kulkarni@linaro.org>
7203         * tree-vrp.h: Add include guard.
7205 2017-08-02  Uros Bizjak  <ubizjak@gmail.com>
7207         PR target/81644
7208         * config/i386/i386.md (unspecv): Add UNSPECV_UD2.
7209         (ud2): New insn pattern.
7210         * config/i386/i386.c (ix86_expand_epilogue):
7211         For naked functions, generate ud2 instead of trap insn.
7213 2017-08-02  Marek Polacek  <polacek@redhat.com>
7215         PR other/81667
7216         * alloc-pool.h (base_pool_allocator): Initialize m_elt_size.
7218 2017-08-02  Tom de Vries  <tom@codesourcery.com>
7219             Cesar Philippidis  <cesar@codesourcery.com>
7221         * config/nvptx/nvptx.c (nvptx_lockless_update, nvptx_lockfull_update):
7222         Add missing edge probabilities.
7224 2017-08-02  Tamar Christina  <tamar.christina@arm.com>
7226         * config/aarch64/aarch64.c (aarch64_reinterpret_float_as_int):
7227         Correct endianness.
7229 2017-08-02  Jakub Jelinek  <jakub@redhat.com>
7231         PR middle-end/79499
7232         * function.c (thread_prologue_and_epilogue_insns): Determine blocks
7233         for find_many_sub_basic_blocks bitmap by looking up BLOCK_FOR_INSN
7234         of first NONDEBUG_INSN_P in each of the split_prologue_seq and
7235         prologue_seq sequences - if any.
7237 2017-08-02  Richard Biener  <rguenther@suse.de>
7239         * tree-vect-stmts.c (vectorizable_store): Perform vector extracts
7240         via vectors if supported, integer extracts via punning if supported
7241         or otherwise vector extracts.
7243 2017-08-02  Richard Biener  <rguenther@suse.de>
7245         * tree-ssa-pre.c (bitmap_insert_into_set_1): Remove and inline
7246         into ...
7247         (bitmap_insert_into_set): ... this.
7249 2017-08-02  Richard Biener  <rguenther@suse.de>
7251         PR tree-optimization/81633
7252         Revert
7253         2015-08-17  Alan Hayward  <alan.hayward@arm.com>
7255         PR tree-optimization/71752
7256         * tree-vect-slp.c (vect_get_slp_defs): Handle null operands.
7258 2017-08-01  Daniel Santos  <daniel.santos@pobox.com>
7260         * config/i386/i386.h (ix86_frame::outlined_save_offset): Remove field.
7261         (machine_function::call_ms2sysv_pad_out): Remove field.
7262         * config/i386/i386.c (xlogue_layout::get_stack_space_used): Modify.
7263         (ix86_compute_frame_layout): Likewise.
7265 2017-08-01  H.J. Lu  <hongjiu.lu@intel.com>
7267         PR target/81654
7268         * config/i386/i386.c (ix86_set_func_type): Disallow naked
7269         attribute with interrupt attribute.
7271 2017-08-01  Andrew Pinski  <apinski@cavium.com>
7273         * tree-ssa-scopedtables.c (hashable_expr_equal_p): Check
7274         BIT_INSERT_EXPR's operand 1
7275         to see if the types precision matches.
7277 2017-08-01  Martin Liska  <mliska@suse.cz>
7279         PR middle-end/70140
7280         * builtins.c (expand_builtin_memcpy_args): Remove.
7281         (expand_builtin_memcpy): Call newly added function
7282         expand_builtin_memory_copy_args.
7283         (expand_builtin_memcpy_with_bounds): Likewise.
7284         (expand_builtin_mempcpy): Remove last argument.
7285         (expand_builtin_mempcpy_with_bounds): Likewise.
7286         (expand_builtin_memory_copy_args): New function created from
7287         expand_builtin_mempcpy_args with small modifications.
7288         (expand_builtin_mempcpy_args): Remove.
7289         (expand_builtin_stpcpy): Remove unused argument.
7290         (expand_builtin): Likewise.
7291         (expand_builtin_with_bounds): Likewise.
7293 2017-08-01  Martin Liska  <mliska@suse.cz>
7295         Revert r250771
7296         Make mempcpy more optimal (PR middle-end/70140).
7298 2017-08-01  Jakub Jelinek  <jakub@redhat.com>
7300         PR target/81622
7301         * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin): For
7302         __builtin_vec_cmpne verify both arguments are compatible vectors
7303         before looking at TYPE_MODE on the element type.  For __builtin_vec_ld
7304         verify arg1_type is a pointer or array type.  For __builtin_vec_st,
7305         move computation of aligned to after checking the argument types.
7306         Formatting fixes.
7308         PR target/80846
7309         * config/rs6000/vsx.md (vextract_fp_from_shorth,
7310         vextract_fp_from_shortl): Add element mode after mode in gen_vec_init*
7311         calls.
7313 2017-08-01  Jerome Lambourg  <lambourg@adacore.com>
7314             Doug Rupp  <rupp@adacore.com>
7315             Olivier Hainque  <hainque@adacore.com>
7317         * config.gcc (arm-wrs-vxworks*): Rework to handle arm-wrs-vxworks7 as
7318         well as arm-wrs-vxworks. Update target_cpu_name from arm6 (arch v3) to
7319         arm8 (arch v4).
7320         * config/arm/vxworks.h (MAYBE_TARGET_BPABI_CPP_BUILTINS): New, helper
7321         for TARGET_OS_CPP_BUILTIN.
7322         (TARGET_OS_CPP_BUILTIN): Invoke MAYBE_TARGET_BPABI_CPP_BUILTINS(),
7323         refine CPU definitions for arm_arch5 and add those for arm_arch6 and
7324         arm_arch7.
7325         (MAYBE_ASM_ABI_SPEC): New, helper for SUBTARGET_EXTRA_ASM_SPEC,
7326         passing required abi options to the assembler for EABI configurations.
7327         (EXTRA_CC1_SPEC): New macro, to help prevent the implicit production
7328         of .text.hot and .text.unlikely sections for kernel modules when
7329         using ARM style exceptions.
7330         (CC1_SPEC): Remove obsolete attempt at mimicking Diab toolchain
7331         options. Add EXTRA_CC1_SPEC.
7332         (VXWORKS_ENDIAN_SPEC): Adjust comment and remove handling of Diab
7333         toolchain options.
7334         (DWARF2_UNWIND_INFO): Redefine to handle the pre/post VxWorks 7
7335         transition.
7336         (ARM_TARGET2_DWARF_FORMAT): Define.
7337         * config/arm/t-vxworks: Adjust multilib control to removal of the
7338         Diab command line options.
7340 2017-08-01  Martin Liska  <mliska@suse.cz>
7342         PR gcov-profile/81561
7343         * gcov.c (unblock): Make unblocking safe as we need to preserve
7344         index correspondence of blocks and block_lists.
7346 2017-08-01  Richard Biener  <rguenther@suse.de>
7348         PR tree-optimization/81181
7349         * tree-ssa-pre.c (compute_antic_aux): Defer clean() to ...
7350         (compute_antic): ... end of iteration here.
7352 2017-08-01  James Greenhalgh  <james.greenhalgh@arm.com>
7354         * common.opt (ftree-vectorize): No longer set flag_tree_vectorize.
7355         (ftree-loop-vectorize): Set as EnabledBy ftree-vectorize.
7356         (ftree-slp-vectorize): Likewise.
7357         * omp-expand (expand_omp_simd): Remove flag_tree_vectorize, as it
7358         can no longer be set independent of flag_tree_loop_vectorize.
7359         * omp-general.c (emp_max_vf): Likewise.
7360         * opts.c (enable_fdo_optimizations): Remove references to
7361         flag_tree_vectorize, these are now implicit.
7362         (common_handle_option): Remove handling for OPT_ftree_vectorize,
7363         and leave it for the options machinery.
7365 2017-08-01  Martin Liska  <mliska@suse.cz>
7367         PR middle-end/70140
7368         * builtins.c (expand_builtin_memcpy_args): Remove.
7369         (expand_builtin_memcpy): Call newly added function
7370         expand_builtin_memory_copy_args.
7371         (expand_builtin_memcpy_with_bounds): Likewise.
7372         (expand_builtin_mempcpy): Remove last argument.
7373         (expand_builtin_mempcpy_with_bounds): Likewise.
7374         (expand_builtin_memory_copy_args): New function created from
7375         expand_builtin_mempcpy_args with small modifications.
7376         (expand_builtin_mempcpy_args): Remove.
7377         (expand_builtin_stpcpy): Remove unused argument.
7378         (expand_builtin): Likewise.
7379         (expand_builtin_with_bounds): Likewise.
7381 2017-08-01  Uros Bizjak  <ubizjak@gmail.com>
7383         PR target/81641
7384         * config/i386/i386.c (ix86_print_operand_address_as): For -masm=intel
7385         print "ds:" only for immediates in generic address space.
7387 2017-08-01  Uros Bizjak  <ubizjak@gmail.com>
7389         PR target/81639
7390         * config/i386/i386.c (ix86_funciton_naked): New prototype.
7391         (ix86_function_ok_for_sibcall): Return false for naked functions.
7393 2017-08-01  Richard Biener  <rguenther@suse.de>
7395         * tree-ssa-pre.c (print_pre_expr): Handle NULL expr.
7396         (compute_antic): Seed worklist with exit block predecessors.
7397         * cfganal.c (dfs_find_deadend): For a cycle return the source
7398         of the edge closing it.
7400 2017-08-01  Tamar Christina  <tamar.christina@arm.com>
7402         * config/aarch64/aarch64.c
7403         (aarch64_can_const_movi_rtx_p): Move 0 check.
7405 2017-08-01  Bin Cheng  <bin.cheng@arm.com>
7407         * tree.h (POINTER_TYPE_OVERFLOW_UNDEFINED): Delete.
7408         * fold-const.c (fold_comparison, fold_binary_loc): Delete use of
7409         above macro.
7410         * match.pd: Ditto in address comparison pattern.
7412 2017-08-01  Bin Cheng  <bin.cheng@arm.com>
7414         PR tree-optimization/81627
7415         * tree-predcom.c (prepare_finalizers): Always rewrite into loop
7416         closed ssa form for store-store chain.
7418 2017-08-01  Bin Cheng  <bin.cheng@arm.com>
7420         PR tree-optimization/81620
7421         * tree-predcom.c (add_ref_to_chain): Don't set has_max_use_after
7422         for store-store chain.
7424 2017-08-01  Jakub Jelinek  <jakub@redhat.com>
7426         PR tree-optimization/81588
7427         * tree-ssa-reassoc.c (optimize_range_tests_var_bound): If
7428         ranges[i].in_p, invert comparison code ccode.  For >/>=,
7429         swap rhs1 and rhs2 and comparison code unconditionally,
7430         for </<= don't do that.  Don't swap rhs1/rhs2 again if
7431         ranges[i].in_p, instead invert comparison code ccode if
7432         opcode or oe->rank is BIT_IOR_EXPR.
7434         PR target/80846
7435         * optabs.def (vec_extract_optab, vec_init_optab): Change from
7436         a direct optab to conversion optab.
7437         * optabs.c (expand_vector_broadcast): Use convert_optab_handler
7438         with GET_MODE_INNER as last argument instead of optab_handler.
7439         * expmed.c (extract_bit_field_1): Likewise.  Use vector from
7440         vector extraction if possible and optab is available.
7441         * expr.c (store_constructor): Use convert_optab_handler instead
7442         of optab_handler.  Use vector initialization from smaller
7443         vectors if possible and optab is available.
7444         * tree-vect-stmts.c (vectorizable_load): Likewise.
7445         * doc/md.texi (vec_extract, vec_init): Document that the optabs
7446         now have two modes.
7447         * config/i386/i386.c (ix86_expand_vector_init): Handle expansion
7448         of vec_init from half-sized vectors with the same element mode.
7449         * config/i386/sse.md (ssehalfvecmode): Add V4TI case.
7450         (ssehalfvecmodelower, ssescalarmodelower): New mode attributes.
7451         (reduc_plus_scal_v8df, reduc_plus_scal_v4df, reduc_plus_scal_v2df,
7452         reduc_plus_scal_v16sf, reduc_plus_scal_v8sf, reduc_plus_scal_v4sf,
7453         reduc_<code>_scal_<mode>, reduc_umin_scal_v8hi): Add element mode
7454         after mode in gen_vec_extract* calls.
7455         (vec_extract<mode>): Renamed to ...
7456         (vec_extract<mode><ssescalarmodelower>): ... this.
7457         (vec_extract<mode><ssehalfvecmodelower>): New expander.
7458         (rotl<mode>3, rotr<mode>3, <shift_insn><mode>3, ashrv2di3): Add
7459         element mode after mode in gen_vec_init* calls.
7460         (VEC_INIT_HALF_MODE): New mode iterator.
7461         (vec_init<mode>): Renamed to ...
7462         (vec_init<mode><ssescalarmodelower>): ... this.
7463         (vec_init<mode><ssehalfvecmodelower>): New expander.
7464         * config/i386/mmx.md (vec_extractv2sf): Renamed to ...
7465         (vec_extractv2sfsf): ... this.
7466         (vec_initv2sf): Renamed to ...
7467         (vec_initv2sfsf): ... this.
7468         (vec_extractv2si): Renamed to ...
7469         (vec_extractv2sisi): ... this.
7470         (vec_initv2si): Renamed to ...
7471         (vec_initv2sisi): ... this.
7472         (vec_extractv4hi): Renamed to ...
7473         (vec_extractv4hihi): ... this.
7474         (vec_initv4hi): Renamed to ...
7475         (vec_initv4hihi): ... this.
7476         (vec_extractv8qi): Renamed to ...
7477         (vec_extractv8qiqi): ... this.
7478         (vec_initv8qi): Renamed to ...
7479         (vec_initv8qiqi): ... this.
7480         * config/rs6000/vector.md (VEC_base_l): New mode attribute.
7481         (vec_init<mode>): Renamed to ...
7482         (vec_init<mode><VEC_base_l>): ... this.
7483         (vec_extract<mode>): Renamed to ...
7484         (vec_extract<mode><VEC_base_l>): ... this.
7485         * config/rs6000/paired.md (vec_initv2sf): Renamed to ...
7486         (vec_initv2sfsf): ... this.
7487         * config/rs6000/altivec.md (splitter, altivec_copysign_v4sf3,
7488         vec_unpacku_hi_v16qi, vec_unpacku_hi_v8hi, vec_unpacku_lo_v16qi,
7489         vec_unpacku_lo_v8hi, mulv16qi3, altivec_vreve<mode>2): Add
7490         element mode after mode in gen_vec_init* calls.
7491         * config/aarch64/aarch64-simd.md (vec_init<mode>): Renamed to ...
7492         (vec_init<mode><Vel>): ... this.
7493         (vec_extract<mode>): Renamed to ...
7494         (vec_extract<mode><Vel>): ... this.
7495         * config/aarch64/iterators.md (Vel): New mode attribute.
7496         * config/s390/s390.c (s390_expand_vec_strlen, s390_expand_vec_movstr):
7497         Add element mode after mode in gen_vec_extract* calls.
7498         * config/s390/vector.md (non_vec_l): New mode attribute.
7499         (vec_extract<mode>): Renamed to ...
7500         (vec_extract<mode><non_vec_l>): ... this.
7501         (vec_init<mode>): Renamed to ...
7502         (vec_init<mode><non_vec_l>): ... this.
7503         * config/s390/s390-builtins.def (s390_vlgvb, s390_vlgvh, s390_vlgvf,
7504         s390_vlgvf_flt, s390_vlgvg, s390_vlgvg_dbl): Add element mode after
7505         vec_extract mode.
7506         * config/arm/iterators.md (V_elem_l): New mode attribute.
7507         * config/arm/neon.md (vec_extract<mode>): Renamed to ...
7508         (vec_extract<mode><V_elem_l>): ... this.
7509         (vec_extractv2di): Renamed to ...
7510         (vec_extractv2didi): ... this.
7511         (vec_init<mode>): Renamed to ...
7512         (vec_init<mode><V_elem_l>): ... this.
7513         (reduc_plus_scal_<mode>, reduc_plus_scal_v2di, reduc_smin_scal_<mode>,
7514         reduc_smax_scal_<mode>, reduc_umin_scal_<mode>,
7515         reduc_umax_scal_<mode>, neon_vget_lane<mode>, neon_vget_laneu<mode>):
7516         Add element mode after gen_vec_extract* calls.
7517         * config/mips/mips-msa.md (vec_init<mode>): Renamed to ...
7518         (vec_init<mode><unitmode>): ... this.
7519         (vec_extract<mode>): Renamed to ...
7520         (vec_extract<mode><unitmode>): ... this.
7521         * config/mips/loongson.md (vec_init<mode>): Renamed to ...
7522         (vec_init<mode><unitmode>): ... this.
7523         * config/mips/mips-ps-3d.md (vec_initv2sf): Renamed to ...
7524         (vec_initv2sfsf): ... this.
7525         (vec_extractv2sf): Renamed to ...
7526         (vec_extractv2sfsf): ... this.
7527         (reduc_plus_scal_v2sf, reduc_smin_scal_v2sf, reduc_smax_scal_v2sf):
7528         Add element mode after gen_vec_extract* calls.
7529         * config/mips/mips.md (unitmode): New mode iterator.
7530         * config/spu/spu.c (spu_expand_prologue, spu_allocate_stack,
7531         spu_builtin_extract): Add element mode after gen_vec_extract* calls.
7532         * config/spu/spu.md (inner_l): New mode attribute.
7533         (vec_init<mode>): Renamed to ...
7534         (vec_init<mode><inner_l>): ... this.
7535         (vec_extract<mode>): Renamed to ...
7536         (vec_extract<mode><inner_l>): ... this.
7537         * config/sparc/sparc.md (veltmode): New mode iterator.
7538         (vec_init<VMALL:mode>): Renamed to ...
7539         (vec_init<VMALL:mode><VMALL:veltmode>): ... this.
7540         * config/ia64/vect.md (vec_initv2si): Renamed to ...
7541         (vec_initv2sisi): ... this.
7542         (vec_initv2sf): Renamed to ...
7543         (vec_initv2sfsf): ... this.
7544         (vec_extractv2sf): Renamed to ...
7545         (vec_extractv2sfsf): ... this.
7546         * config/powerpcspe/vector.md (VEC_base_l): New mode attribute.
7547         (vec_init<mode>): Renamed to ...
7548         (vec_init<mode><VEC_base_l>): ... this.
7549         (vec_extract<mode>): Renamed to ...
7550         (vec_extract<mode><VEC_base_l>): ... this.
7551         * config/powerpcspe/paired.md (vec_initv2sf): Renamed to ...
7552         (vec_initv2sfsf): ... this.
7553         * config/powerpcspe/altivec.md (splitter, altivec_copysign_v4sf3,
7554         vec_unpacku_hi_v16qi, vec_unpacku_hi_v8hi, vec_unpacku_lo_v16qi,
7555         vec_unpacku_lo_v8hi, mulv16qi3): Add element mode after mode in
7556         gen_vec_init* calls.
7558 2017-08-01  Richard Biener  <rguenther@suse.de>
7560         PR tree-optimization/81297
7561         * tree-vrp.c (get_single_symbol): Remove assert, instead drop
7562         TREE_OVERFLOW from INTEGER_CSTs.
7564 2017-07-31  Segher Boessenkool  <segher@kernel.crashing.org>
7566         * config/rs6000/rs6000.c (enum rs6000_reg_type): Delete trailing comma.
7568 2017-07-31  Carl Love  <cel@us.ibm.com>
7570         * config/rs6000/rs6000-c: Add support for built-in functions
7571         vector signed char vec_xl_be (signed long long, signed char *);
7572         vector unsigned char vec_xl_be (signed long long, unsigned char *);
7573         vector signed int vec_xl_be (signed long long, signed int *);
7574         vector unsigned int vec_xl_be (signed long long, unsigned int *);
7575         vector signed long long vec_xl_be (signed long long, signed long long *);
7576         vector unsigned long long vec_xl_be (signed long long, unsigned long long *);
7577         vector signed short vec_xl_be (signed long long, signed short *);
7578         vector unsigned short vec_xl_be (signed long long, unsigned short *);
7579         vector double vec_xl_be (signed long long, double *);
7580         vector float vec_xl_be (signed long long, float *);
7581         * config/rs6000/altivec.h (vec_xl_be): Add #define.
7582         * config/rs6000/rs6000-builtin.def (XL_BE_V16QI, XL_BE_V8HI, XL_BE_V4SI)
7583         XL_BE_V2DI, XL_BE_V4SF, XL_BE_V2DF, XL_BE): Add definitions
7584         for the builtins.
7585         * config/rs6000/rs6000.c (altivec_expand_xl_be_builtin): Add function.
7586         (altivec_expand_builtin): Add switch statement to call
7587         altivec_expand_xl_be for each builtin.
7588         (altivec_init_builtins): Add def_builtin for _builtin_vsx_le_be_v8hi,
7589         __builtin_vsx_le_be_v4si, __builtin_vsx_le_be_v2di,
7590         __builtin_vsx_le_be_v4sf, __builtin_vsx_le_be_v2df,
7591         __builtin_vsx_le_be_v16qi.
7592         * doc/extend.texi: Update the built-in documentation file for the
7593         new built-in functions.
7595 2017-07-31  Uros Bizjak  <ubizjak@gmail.com>
7597         PR target/25967
7598         * config/i386/i386.c (ix86_allocate_stack_slots_for_args):
7599         New function.
7600         (TARGET_ALLOCATE_STACK_SLOTS_FOR_ARGS): Define.
7602 2017-07-31  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
7604         * config.gcc: Add z14.
7605         * config/s390/driver-native.c (s390_host_detect_local_cpu): Add
7606         CPU model numbers for z13s and z14.
7607         * config/s390/s390-c.c (s390_resolve_overloaded_builtin): Replace
7608         arch12 with z14.
7609         * config/s390/s390-opts.h (enum processor_type): Rename
7610         PROCESSOR_ARCH12 to PROCESSOR_3906_Z14.
7611         * config/s390/s390.c (processor_table): Add field for CPU name to
7612         be passed to Binutils.
7613         (s390_asm_output_machine_for_arch): Use the new field in
7614         processor_table for Binutils.
7615         (s390_expand_builtin): Replace arch12 with z14.
7616         (s390_issue_rate): Rename PROCESSOR_ARCH12 to PROCESSOR_3906_Z14.
7617         (s390_get_sched_attrmask): Likewise.
7618         (s390_get_unit_mask): Likewise.
7619         * config/s390/s390.opt: Add z14 to processor_type enum.
7621 2017-07-31  Martin Jambor  <mjambor@suse.cz>
7623         PR hsa/81477
7624         * ipa-fnsummary.c (ipa_fn_summary_generate): Set versionable
7625         regardless of optimization level.
7627 2017-07-31  Jan Hubicka <hubicka@ucw.cz>
7628             Martin Liska  <mliska@suse.cz>
7630         * predict.def: Remove old comment and adjust probability.
7631         * gimplify.c (should_warn_for_implicit_fallthrough): Ignore
7632         PREDICT statements.
7634 2017-07-31  Uros Bizjak  <ubizjak@gmail.com>
7636         PR target/25967
7637         * config/i386/i386.c (ix86_function_naked): New function.
7638         (ix86_can_use_return_insn_p): Return false for naked functions.
7639         (ix86_expand_prologue): Skip prologue for naked functions.
7640         (ix86_expand_epilogue): Skip epilogue for naked functions
7641         and emit trap instruction.
7642         (ix86_warn_func_return): New function.
7643         (ix86_attribute_table): Add "naked" attribute specification.
7644         (TARGET_WARN_FUNC_RETURN): Define.
7645         * doc/extend.texi (x86 Function Attributes) <naked>: Document it.
7647 2017-07-31  Martin Liska  <mliska@suse.cz>
7649         * gimple-pretty-print.c (dump_gimple_label): Never dump BB info.
7650         (dump_gimple_bb_header): Always dump BB info.
7651         (pp_cfg_jump): Do not append info about BB when dumping a jump.
7653 2017-07-31  Martin Liska  <mliska@suse.cz>
7655         PR sanitize/81530
7656         * convert.c (convert_to_integer_1): Guard condition with flag_sanitize_p
7657         also with current_function_decl non-null equality.
7659 2017-07-31  Jakub Jelinek  <jakub@redhat.com>
7661         PR sanitizer/81604
7662         * ubsan.c (ubsan_type_descriptor): For UBSAN_PRINT_ARRAY don't
7663         change type to the element type, instead add eltype variable and
7664         use it where we are interested in the element type.
7666         PR tree-optimization/81603
7667         * ipa-polymorphic-call.c
7668         (ipa_polymorphic_call_context::ipa_polymorphic_call_context): Perform
7669         offset arithmetic in offset_int, bail out if the resulting bit offset
7670         doesn't fit into shwi.
7672 2017-07-31  Martin Liska  <mliska@suse.cz>
7674         * gimplify.c (mostly_copy_tree_r): Remove Java specific hunk.
7675         (gimplify_save_expr): Fix comment.
7677 2017-07-30  H.J. Lu  <hongjiu.lu@intel.com>
7679         PR target/79793
7680         * config/i386/i386.c (ix86_function_arg): Update arguments for
7681         exception handler.
7682         (ix86_compute_frame_layout): Set the initial stack offset to
7683         INCOMING_FRAME_SP_OFFSET.  Update red-zone offset with
7684         INCOMING_FRAME_SP_OFFSET.
7685         (ix86_expand_epilogue): Don't pop the 'ERROR_CODE' off the
7686         stack before exception handler returns.
7687         * config/i386/i386.h (INCOMING_FRAME_SP_OFFSET): Add the
7688         the 'ERROR_CODE' for exception handler.
7690 2017-07-30  Uros Bizjak  <ubizjak@gmail.com>
7692         * config/i386/i386.h (ASM_PRINTF_EXTENSIONS): New macro.
7693         (ASM_OUTPUT_REG_PUSH): Rewrite with new operand modifiers.
7694         (ASM_OUTPUT_REG_POP): Ditto.
7695         * config/i386/i386.c (ix86_asm_output_function_label): Use fputs
7696         instead of asm_fprintf to output pure string.
7698 2017-07-29  Jakub Jelinek  <jakub@redhat.com>
7700         * debug.h (struct gcc_debug_hooks): Add IMPLICIT argument
7701         to imported_module_or_decl hook.
7702         (debug_nothing_tree_tree_tree_bool): Remove.
7703         (debug_nothing_tree_tree_tree_bool_bool): New declaration.
7704         * debug.c (do_nothing_debug_hooks): Use
7705         debug_nothing_tree_tree_tree_bool_bool instead of
7706         debug_nothing_tree_tree_tree_bool.
7707         * vmsdbgout.c (vmsdbg_debug_hooks): Likewise.
7708         * dbxout.c (dbx_debug_hooks, xcoff_debug_hooks): Likewise.
7709         * sdbout.c (sdb_debug_hooks): Likewise.
7710         * dwarf2out.c (dwarf2_lineno_debug_hooks): Likewise.
7711         (gen_namespace_die): Add DW_AT_export_symbols attribute if
7712         langhook wants it.
7713         (dwarf2out_imported_module_or_decl): Add IMPLICIT argument,
7714         if true, -gdwarf-5 and decl will have DW_AT_export_symbols
7715         attribute, don't add anything.
7717 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
7719         * fold-const.c (fold_build1_stat_loc): Remove _stat from name.
7720         (fold_build2_stat_loc): Likewise.
7721         (fold_build3_stat_loc): Likewise.
7722         * fold-const.h (fold_build1, fold_build2, fold_build3): Adjust.
7723         (fold_build1_loc): Remove macro.
7724         (fold_build2_loc): Likewise.
7725         (fold_build3_loc): Likewise.
7727 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
7729         * gimple.c (gimple_build_debug_bind_stat): Remove _stat from name.
7730         (gimple_build_debug_bind_source_stat): Likewise.
7731         * gimple.h (gimple_build_debug_bind): Remove macro.
7732         (gimple_build_debug_bind_source): Likewise.
7734 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
7736         * bitmap.c (bitmap_alloc): Adjust.
7737         (bitmap_gc_alloc): Likewise.
7738         * bitmap.h (bitmap_initialize_stat): Remove _stat from name.
7740 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
7742         * bitmap.c (bitmap_obstack_alloc_stat): Rename to bitmap_alloc.
7743         (bitmap_gc_alloc_stat): Rename to bitmap_gc_alloc.
7744         * bitmap.h (bitmap_obstack_alloc_stat): Adjust prototype.
7745         (bitmap_gc_alloc_stat): Likewise.
7746         (BITMAP_ALLOC, BITMAP_GGC_ALLOC): Adjust.
7748 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
7750         * rtl.c (shallow_copy_rtx_stat): Remove _stat from name.
7751         * rtl.h (shallow_copy_rtx): Remove macro.
7753 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
7755         * emit-rtl.c (gen_raw_REG): Adjust.
7756         * gengenrtl.c (gendef): Likewise.
7757         * rtl.c (rtx_alloc_stat): Remove _stat from name.
7758         * rtl.h (rtx_alloc): Remove macro.
7760 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
7762         * tree.c (build_tree_list_vec_stat): Remove _stat from name.
7763         (build_tree_list_stat): Likewise.
7764         * tree.h (build_tree_list): Remove macro.
7765         (build_tree_list_vec): Likewise.
7767 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
7769         * tree.c (make_vector_stat): Remove _stat from name.
7770         (build_vector_stat): Likewise.
7771         * tree.h (make_vector_stat): Remove macro.
7772         (build_vector_stat): Likewise.
7774 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
7776         * tree.h (build_var_debug_value): Remove prototype.
7778 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
7780         * tree.c (tree_cons_stat): Remove _stat from name.
7781         * tree.h (tree_cons): Remove macro.
7783 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
7785         * tree.c (build_vl_exp_stat): Remove _stat from name.
7786         * tree.h (build_vl_exp): Remove macro.
7788 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
7790         * tree.c (build_decl_stat): Remove _stat from name.
7791         * tree.h (build_decl): Remove macro.
7793 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
7795         * gimple.c (gimple_build_with_ops_stat): Adjust.
7796         (gimple_alloc_stat): Remove _stat from name.
7797         * gimple.h (gimple_alloc): Remove macro.
7799 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
7801         * tree.c (make_tree_vec_stat): Remove _stat from name.
7802         (grow_tree_vec_stat): Likewise.
7803         * tree.h (make_tree_vec_stat): Adjust prototype.
7804         (grow_tree_vec_stat): Likewise.
7805         (make_tree_vec): Remove macro.
7806         (grow_tree_vec): Likewise.
7808 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
7810         * fold-const.c (fold_build1_stat_loc): Adjust.
7811         (fold_build2_stat_loc): Likewise.
7812         (fold_build3_stat_loc): Likewise.
7813         * tree.c (build0_stat): Remove _stat from name.
7814         (build1_stat): Likewise.
7815         (build2_stat): Likewise.
7816         (build3_stat): Likewise.
7817         (build4_stat): Likewise.
7818         (build5_stat): Likewise.
7819         * tree.h (build1_loc): Remove macro, and rename _stat function
7820         to this.
7821         (build2_loc): Likewise.
7822         (build3_loc): Likewise.
7823         (build4_loc): Likewise.
7824         (build5_loc): Likewise.
7826 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
7828         * tree.c (make_int_cst_stat): Remove _stat from name.
7829         * tree.h (make_int_cst_stat): Adjust prototype.
7830         (make_int_cst): Remove macro.
7832 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
7834         * tree.c (make_tre_binfo_stat): Remove _stat from name.
7835         * tree.h (make_tree_binfo_stat): Adjust prototype.
7836         (make_tree_binfo): Remove.
7838 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
7840         * tree.c (copy_node_stat): Rename to copy_node.
7841         (build_distinct_type_copy): Adjust.
7842         * tree.h (copy_node_stat): Adjust prototype.
7843         (copy_node): Remove macro.
7845 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
7847         * tree.c (make_node_stat): rename to make_node.
7848         (build_tree_list_stat): Adjust.
7849         (build0_stat): Likewise.
7850         (build2_stat): Likewise.
7851         (build3_stat): Likewise.
7852         (build4_stat): Likewise.
7853         (build5_stat): Likewise.
7854         (build_decl_stat): Likewise.
7855         * tree.h (make_node_stat): Adjust prototype.
7856         (make_node): remove macro.
7858 2017-07-28  Peter Bergner  <bergner@vnet.ibm.com>
7860         * config/rs6000/ppc-auxv.h (PPC_FEATURE2_DARN): New define.
7861         (PPC_FEATURE2_SCV): Likewise.
7862         * config/rs6000/rs6000.c (cpu_supports_info): Use them.
7864 2017-07-28  Tamar Christina  <tamar.christina@arm.com>
7866         * config/aarch64/aarch64.c
7867         (aarch64_internal_mov_immediate): Add new special pattern.
7868         * config/aarch64/aarch64.md (*movdi_aarch64):
7869         Add reg/32bit const mov case.
7871 2017-07-28  Tamar Christina  <tamar.christina@arm.com>
7872             Richard Sandiford <richard.sandiford@linaro.org>
7874         * config/aarch64/aarch64.md (mov<mode>): Generalize.
7875         (*movhf_aarch64, *movsf_aarch64, *movdf_aarch64):
7876         Add integer and movi cases.
7877         (movi-split-hf-df-sf split, fp16): New.
7878         (enabled): Added TARGET_FP_F16INST.
7879         * config/aarch64/iterators.md (GPF_HF): New.
7880         * config/aarch64/predicates.md (aarch64_reg_or_fp_float): New.
7882 2017-07-28  Tamar Christina  <tamar.christina@arm.com>
7884         * config/aarch64/aarch64.c
7885         (aarch64_simd_container_mode): Add prototype.
7886         (aarch64_expand_mov_immediate): Add HI support.
7887         (aarch64_reinterpret_float_as_int, aarch64_float_const_rtx_p: New.
7888         (aarch64_can_const_movi_rtx_p): New.
7889         (aarch64_preferred_reload_class):
7890         Remove restrictions of using FP registers for certain SIMD operations.
7891         (aarch64_rtx_costs): Added new cost for CONST_DOUBLE moves.
7892         (aarch64_valid_floating_const): Add integer move validation.
7893         (aarch64_simd_imm_scalar_p): Remove.
7894         (aarch64_output_scalar_simd_mov_immediate): Generalize function.
7895         (aarch64_legitimate_constant_p): Expand list of supported cases.
7896         * config/aarch64/aarch64-protos.h
7897         (aarch64_float_const_rtx_p, aarch64_can_const_movi_rtx_p): New.
7898         (aarch64_reinterpret_float_as_int): New.
7899         (aarch64_simd_imm_scalar_p): Remove.
7900         * config/aarch64/constraints.md (Uvi): New.
7901         (Dd): Split into Ds and new Dd.
7902         * config/aarch64/aarch64.md (*movsi_aarch64):
7903         Add SIMD mov case.
7904         (*movdi_aarch64): Add SIMD mov case.
7906 2017-07-28  Bin Cheng  <bin.cheng@arm.com>
7908         * tree-predcom.c: (struct chain): Handle store-store chain in which
7909         stores for elimination only store loop invariant values.
7910         (execute_pred_commoning_chain): Ditto.
7911         (prepare_initializers_chain_store_elim): Ditto.
7912         (prepare_finalizers): Ditto.
7913         (is_inv_store_elimination_chain): New function.
7914         (initialize_root_vars_store_elim_1): New function.
7916 2017-07-28  Bin Cheng  <bin.cheng@arm.com>
7918         * tree-predcom.c: Revise general description of the pass.
7919         (enum chain_type): New enum type for store elimination.
7920         (struct chain): New field supporting store elimination.
7921         (struct component): Ditto.
7922         (dump_chain): Dump store-stores chain.
7923         (release_chain): Release resources.
7924         (split_data_refs_to_components): Compute and create component
7925         contains only stores for elimination.
7926         (get_chain_last_ref_at): New function.
7927         (make_invariant_chain): Initialization.
7928         (make_rooted_chain): Specify chain type in parameter and record it.
7929         (add_looparound_copies): Skip for store-stores chain.
7930         (determine_roots_comp): Compute type of chain and pass it to
7931         make_rooted_chain.
7932         (initialize_root_vars_store_elim_2): New function.
7933         (finalize_eliminated_stores): New function.
7934         (remove_stmt): Handle store for elimination.
7935         (execute_pred_commoning_chain): Execute predictive commoning on
7936         store-store chains.
7937         (determine_unroll_factor): Skip unroll for store-stores chain.
7938         (prepare_initializers_chain_store_elim): New function.
7939         (prepare_initializers_chain): Hanlde store-store chain.
7940         (prepare_finalizers_chain, prepare_finalizers): New function.
7941         (tree_predictive_commoning_loop): Return integer value indicating
7942         if loop is unrolled or lcssa form is corrupted.
7943         (tree_predictive_commoning): Rewrite for lcssa form if necessary.
7945 2017-07-28  Bin Cheng  <bin.cheng@arm.com>
7947         * tree-predcom.c (initialize_root): Delete.
7948         (execute_pred_commoning_chain): Initialize root vars and replace
7949         reference of non-combined chain directly, rather than call above
7950         function.
7952 2017-07-28  Bin Cheng  <bin.cheng@arm.com>
7954         * tree-predcom.c (ref_at_iteration): Add parameter NITERS.  Compute
7955         memory reference to DR at (NITERS + ITERS)-th iteration of loop.
7957 2017-07-28  Bin Cheng  <bin.cheng@arm.com>
7959         * tree-predcom.c (struct chain): New field init_seq.
7960         (release_chain): Release init_seq.
7961         (prepare_initializers_chain): Record intialization stmts in above
7962         field.
7963         (insert_init_seqs): New function.
7964         (tree_predictive_commoning_loop): Call insert_init_seqs.
7966 2017-07-28  Bin Cheng  <bin.cheng@arm.com>
7968         * tree-predcom.c (determine_roots_comp): Skip trivial components.
7970 2017-07-28  Richard Biener  <rguenther@suse.de>
7972         * match.pd: Remove superfluous :c.
7973         * genmatch.c (simplify::id): Add member.
7974         (lower_commutative, lower_opt_convert, lower_cond, lower_for):
7975         Copy id.
7976         (current_id): New global.
7977         (dt_node::parent): Move from ...
7978         (dt_operand::parent): ... here.  Add for_id member.
7979         (is_a_helper <dt_operand *>::test): DT_TRUE is also a dt_operand.
7980         (decision_tree::find_node): Relax order requirement when
7981         merging DT_TRUE nodes to ones inbetween the current simplify
7982         and the one we try to merge with.  Add diagnostic whenever
7983         we need to enforce pattern order by not merging.
7984         (decision_tree::insert): Set current_id.
7985         (decision_tree::print_node): Dump parent node and for_id.
7986         (parser::last_id): Add member.
7987         (parser::push_simplify): Assign unique id.
7988         (parser::parser): Initialize last_id.
7990 2017-07-28  Martin Liska  <mliska@suse.cz>
7992         PR sanitizer/81340
7993         * sanopt.c (sanitize_rewrite_addressable_params): Set VALUE_EXPR after
7994         gimple_build_debug_bind.
7996 2017-07-28  Richard Biener  <rguenther@suse.de>
7998         PR tree-optimization/81502
7999         * match.pd: Add pattern combining BIT_INSERT_EXPR with
8000         BIT_FIELD_REF.
8001         * tree-cfg.c (verify_expr): Verify types of BIT_FIELD_REF
8002         size/pos operands.
8003         (verify_gimple_assign_ternary): Likewise for BIT_INSERT_EXPR pos.
8004         * gimple-fold.c (maybe_canonicalize_mem_ref_addr): Use bitsizetype
8005         for BIT_FIELD_REF args.
8006         * fold-const.c (make_bit_field_ref): Likewise.
8007         * tree-vect-stmts.c (vectorizable_simd_clone_call): Likewise.
8009 2017-07-28  Jakub Jelinek  <jakub@redhat.com>
8011         PR sanitizer/80998
8012         * sanopt.c (pass_sanopt::execute): Handle IFN_UBSAN_PTR.
8013         * tree-ssa-alias.c (call_may_clobber_ref_p_1): Likewise.
8014         * flag-types.h (enum sanitize_code): Add SANITIZER_POINTER_OVERFLOW.
8015         Or it into SANITIZER_UNDEFINED.
8016         * ubsan.c: Include gimple-fold.h and varasm.h.
8017         (ubsan_expand_ptr_ifn): New function.
8018         (instrument_pointer_overflow): New function.
8019         (maybe_instrument_pointer_overflow): New function.
8020         (instrument_object_size): Formatting fix.
8021         (pass_ubsan::execute): Call instrument_pointer_overflow
8022         and maybe_instrument_pointer_overflow.
8023         * internal-fn.c (expand_UBSAN_PTR): New function.
8024         * ubsan.h (ubsan_expand_ptr_ifn): Declare.
8025         * sanitizer.def (__ubsan_handle_pointer_overflow,
8026         __ubsan_handle_pointer_overflow_abort): New builtins.
8027         * tree-ssa-tail-merge.c (merge_stmts_p): Handle IFN_UBSAN_PTR.
8028         * internal-fn.def (UBSAN_PTR): New internal function.
8029         * opts.c (sanitizer_opts): Add pointer-overflow.
8030         * lto-streamer-in.c (input_function): Handle IFN_UBSAN_PTR.
8031         * fold-const.c (build_range_check): Compute pointer range check in
8032         integral type if pointer arithmetics would be needed.  Formatting
8033         fixes.
8035 2017-07-28  Martin Liska  <mliska@suse.cz>
8037         PR sanitizer/81460
8038         * sanopt.c (sanitize_rewrite_addressable_params): Do not rewrite
8039         parameters that are of a variable-length.
8041 2017-07-28  Sebastian Huber  <sebastian.huber@embedded-brains.de>
8043         * config.gcc (powerpc-*-rtems*): Remove rs6000/eabi.h.  Add
8044         rs6000/biarch64.h.
8045         * config/rs6000/rtems.h (ASM_DECLARE_FUNCTION_SIZE): New macro.
8046         (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Likewise.
8047         (CRT_CALL_STATIC_FUNCTION): Likewise.
8048         (ASM_DEFAULT_SPEC): New define.
8049         (ASM_SPEC32): Likewise.
8050         (ASM_SPEC64): Likewise.
8051         (ASM_SPEC_COMMON): Likewise.
8052         (ASM_SPEC): Likewise.
8053         (INVALID_64BIT): Likewise.
8054         (LINK_OS_DEFAULT_SPEC): Likewise.
8055         (LINK_OS_SPEC32): Likewise.
8056         (LINK_OS_SPEC64): Likewise.
8057         (POWERPC_LINUX): Likewise.
8058         (PTRDIFF_TYPE): Likewise.
8059         (RESTORE_FP_PREFIX): Likewise.
8060         (RESTORE_FP_SUFFIX): Likewise.
8061         (SAVE_FP_PREFIX): Likewise.
8062         (SAVE_FP_SUFFIX): Likewise.
8063         (SIZE_TYPE): Likewise.
8064         (SUBSUBTARGET_OVERRIDE_OPTIONS): Likewise.
8065         (TARGET_64BIT): Likewise.
8066         (TARGET_64BIT): Likewise.
8067         (TARGET_AIX): Likewise.
8068         (WCHAR_TYPE_SIZE): Likewise.
8069         (WCHAR_TYPE): Undefine.
8070         (TARGET_OS_CPP_BUILTINS): Add 64-bit PowerPC defines.
8071         (CPP_OS_DEFAULT_SPEC): Use previous CPP_OS_RTEMS_SPEC.
8072         (CPP_OS_RTEMS_SPEC): Delete.
8073         (SUBSUBTARGET_EXTRA_SPECS): Remove cpp_os_rtems.  Add
8074         asm_spec_common, asm_spec32, asm_spec64, link_os_spec32, and
8075         link_os_spec64.
8076         * config/rs6000/t-rtems: Add mcpu=e6500/m64 multilibs.
8078 2017-07-28  Jakub Jelinek  <jakub@redhat.com>
8080         PR tree-optimization/81578
8081         * tree-parloops.c (build_new_reduction): Bail out if
8082         reduction_code isn't one of the standard OpenMP reductions.
8083         Move the details printing after that decision.
8085 2017-07-27  Peter Bergner  <bergner@vnet.ibm.com>
8087         * config/rs6000/predicates.md (volatile_mem_operand): Remove code
8088         related to reload_in_progress.
8089         (splat_input_operand): Likewise.
8090         * config/rs6000/rs6000-protos.h (rs6000_secondary_memory_needed_rtx):
8091         Delete prototype.
8092         * config/rs6000/rs6000.c (machine_function): Remove sdmode_stack_slot
8093         field.
8094         (TARGET_EXPAND_TO_RTL_HOOK): Delete.
8095         (TARGET_INSTANTIATE_DECLS): Likewise.
8096         (legitimate_indexed_address_p): Delete reload_in_progress code.
8097         (rs6000_debug_legitimate_address_p): Likewise.
8098         (rs6000_eliminate_indexed_memrefs): Likewise.
8099         (rs6000_emit_le_vsx_store): Likewise.
8100         (rs6000_emit_move_si_sf_subreg): Likewise.
8101         (rs6000_emit_move): Likewise.
8102         (register_to_reg_type): Likewise.
8103         (rs6000_pre_atomic_barrier): Likewise.
8104         (rs6000_machopic_legitimize_pic_address): Likewise.
8105         (rs6000_allocate_stack_temp): Likewise.
8106         (rs6000_address_for_fpconvert): Likewise.
8107         (rs6000_address_for_altivec): Likewise.
8108         (rs6000_secondary_memory_needed_rtx): Delete function.
8109         (rs6000_check_sdmode): Likewise.
8110         (rs6000_alloc_sdmode_stack_slot): Likewise.
8111         (rs6000_instantiate_decls): Likewise.
8112         * config/rs6000/rs6000.h (SECONDARY_MEMORY_NEEDED_RTX): Delete.
8113         * config/rs6000/rs6000.md (splitter for *movsi_got_internal):
8114         Delete reload_in_progress.
8115         (*vec_reload_and_plus_<mptrsize>): Likewise.
8116         * config/rs6000/vsx.md (vsx_mul_v2di): Likewise.
8117         (vsx_div_v2di): Likewise.
8118         (vsx_udiv_v2di): Likewise.
8120 2017-07-27  Peter Bergner  <bergner@vnet.ibm.com>
8122         * config/rs6000/rs6000.opt (mlra): Replace with stub.
8123         * config/rs6000/rs6000-cpus.def (POWERPC_MASKS): Delete OPTION_MASK_LRA.
8124         * config/rs6000/rs6000.c (TARGET_LRA_P): Delete.
8125         (rs6000_debug_reg_global): Delete print of LRA status.
8126         (rs6000_option_override_internal): Delete dead LRA related code.
8127         (rs6000_lra_p): Delete function.
8128         * doc/invoke.texi (RS/6000 and PowerPC Options): Delete -mlra.
8130 2017-07-27  Sebastian Huber  <sebastian.huber@embedded-brains.de>
8132         * config.gcc (riscv*-*-elf*): Add (riscv*-*-rtems*).
8133         * config/riscv/rtems.h: New file.
8135 2017-07-27  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
8136             Sudakshina Das  <sudi.das@arm.com>
8138         * config/aarch64/aarch64.md
8139         (define_split for and<mode>3nr_compare): Move
8140         non aarch64_logical_operand to a register.
8141         (define_split for and_<SHIFT:optab><mode>3nr_compare0): Move non
8142         register immediate operand to a register.
8143         * config/aarch64/predicates.md (aarch64_mov_imm_operand): New.
8145 2017-07-27  Peter Bergner  <bergner@vnet.ibm.com>
8147         PR middle-end/81564
8148         * tree-cfg.c (group_case_labels_stmt): Handle already deleted blocks.
8150 2017-07-27  Richard Biener  <rguenther@suse.de>
8152         PR tree-optimization/81573
8153         PR tree-optimization/81494
8154         * tree-vect-loop.c (vect_create_epilog_for_reduction): Handle
8155         multi defuse cycle case.
8157 2017-07-27  Richard Biener  <rguenther@suse.de>
8159         PR tree-optimization/81571
8160         * tree-vect-slp.c (vect_build_slp_tree): Properly verify reduction
8161         PHIs.
8163 2017-07-27  Eric Botcazou  <ebotcazou@adacore.com>
8165         * config/sparc/sparc.c (sparc_option_override): Set MASK_FSMULD flag
8166         earlier and only if MASK_FPU is set.  Adjust formatting.
8168 2017-07-27  Martin Liska  <mliska@suse.cz>
8170         * opt-functions.awk: Add validation of value of Init.
8171         * optc-gen.awk: Pass new argument.
8173 2017-07-27  Martin Liska  <mliska@suse.cz>
8175         * auto-profile.c (autofdo_source_profile::update_inlined_ind_target):
8176         Fix wrong condition.
8178 2017-07-27  Martin Liska  <mliska@suse.cz>
8180         * auto-profile.c (afdo_annotate_cfg): Assign zero counts to
8181         BBs and edges seen by autoFDO.
8183 2017-07-27  Richard Biener  <rguenther@suse.de>
8185         PR tree-optimization/81502
8186         * tree-ssa.c (non_rewritable_lvalue_p): Handle BIT_INSERT_EXPR
8187         with incompatible but same sized type.
8188         (execute_update_addresses_taken): Likewise.
8190 2017-07-27  James Greenhalgh  <james.greenhalgh@arm.com>
8192         * tree-ssa-loop-ch.c (pass_ch::process_loop_p): Guard on
8193         flag_tree_loop_vectorize rather than flag_tree_vectorize.
8195 2017-07-27  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
8197         PR target/81534
8198         * config/s390/s390.md ("*atomic_compare_and_swap<mode>_1")
8199         ("*atomic_compare_and_swapdi_2", "*atomic_compare_and_swapsi_3"):
8200         Change s_operand to memory_operand.
8202 2017-07-27  Richard Sandiford  <richard.sandiford@linaro.org>
8204         * config/rs6000/rs6000-protos.h (rs6000_emit_le_vsx_permute): Declare.
8205         * config/rs6000/rs6000.c (rs6000_gen_le_vsx_permute): Replace with...
8206         (rs6000_emit_le_vsx_permute): ...this.  Take the destination as input.
8207         Emit instructions rather than returning an expression.  Handle TFmode
8208         and KFmode by casting to TImode.
8209         (rs6000_emit_le_vsx_load): Update to use rs6000_emit_le_vsx_permute.
8210         (rs6000_emit_le_vsx_store): Likewise.
8211         * config/rs6000/vsx.md (VSX_TI): New iterator.
8212         (*vsx_le_permute_<mode>): Use it instead of VSX_LE_128.
8213         (*vsx_le_undo_permute_<mode>): Likewise.
8214         (*vsx_le_perm_load_<mode>): Use rs6000_emit_le_vsx_permute to
8215         emit the split sequence.
8216         (*vsx_le_perm_store_<mode>): Likewise.
8218 2017-07-27  Jakub Jelinek  <jakub@redhat.com>
8220         PR tree-optimization/81555
8221         PR tree-optimization/81556
8222         * tree-ssa-reassoc.c (rewrite_expr_tree): Add NEXT_CHANGED argument,
8223         if true, force CHANGED for the recursive invocation.
8224         (reassociate_bb): Remember original length of ops array, pass
8225         len != orig_len as NEXT_CHANGED in rewrite_expr_tree call.
8227         * attribs.c (decl_attributes): Imply noinline, noclone and no_icf
8228         attributes for noipa attribute.  For naked attribute use
8229         lookup_attribute first before lookup_attribute_spec.
8230         * final.c (rest_of_handle_final): Disable IPA RA for functions with
8231         noipa attribute.
8232         * ipa-visibility.c (non_local_p): Fix comment typos.  Return true
8233         for functions with noipa attribute.
8234         (cgraph_externally_visible_p): Return true for functions with noipa
8235         attribute.
8236         * cgraph.c (cgraph_node::get_availability): Return AVAIL_INTERPOSABLE
8237         for functions with noipa attribute.
8238         * doc/extend.texi: Document noipa function attribute.
8239         * tree-ssa-structalias.c (refered_from_nonlocal_fn): Set *nonlocal_p
8240         also for functions with noipa attribute.
8241         (ipa_pta_execute): Set nonlocal_p also for nodes with noipa attribute.
8243 2017-07-26  Andrew Pinski  <apinski@cavium.com>
8245         * config/aarch64/aarch64.c (thunderx_vector_cost): Decrease cost of
8246         vec_unalign_load_cost and vec_unalign_store_cost.
8248 2017-07-26  Michael Meissner  <meissner@linux.vnet.ibm.com>
8250         * config/rs6000/rs6000-cpus.def (ISA_2_7_MASKS_SERVER): Delete
8251         -mvsx-small-integer option.
8252         (ISA_3_0_MASKS_IEEE): Likewise.
8253         (OTHER_VSX_VECTOR_MASKS): Likewise.
8254         (POWERPC_MASKS): Likewise.
8255         * config/rs6000/rs6000.opt (-mvsx-small-integer): Likewise.
8256         * config/rs6000/rs6000.c (rs6000_hard_regno_mode_ok): Simplify
8257         code, only testing for DImode being allowed in non-VSX floating
8258         point registers.
8259         (rs6000_init_hard_regno_mode_ok): Change TARGET_VSX_SMALL_INTEGER
8260         to TARGET_P8_VECTOR test.  Remove redundant VSX test inside of
8261         another VSX test.
8262         (rs6000_option_override_internal): Delete -mvsx-small-integer.
8263         (rs6000_expand_vector_set): Change TARGET_VSX_SMALL_INTEGER to
8264         TARGET_P8_VECTOR test.
8265         (rs6000_secondary_reload_simple_move): Likewise.
8266         (rs6000_preferred_reload_class): Delete TARGET_VSX_SMALL_INTEGER,
8267         since TARGET_P9_VECTOR was already tested.
8268         (rs6000_opt_masks): Remove -mvsx-small-integer.
8269         * config/rs6000/vsx.md (vsx_extract_<mode>): Delete
8270         TARGET_VSX_SMALL_INTEGER, since a test for TARGET_P9_VECTOR was
8271         used.
8272         (vsx_extract_<mode>_p9): Delete TARGET_VSX_SMALL_INTEGER, since a
8273         test for TARGET_VEXTRACTUB was used, and that uses
8274         TARGET_P9_VECTOR.
8275         (p9 extract splitter): Likewise.
8276         (vsx_extract_<mode>_di_p9): Likewise.
8277         (vsx_extract_<mode>_store_p9): Likewise.
8278         (vsx_extract_si): Delete TARGET_VSX_SMALL_INTEGER, since a test
8279         for TARGET_P9_VECTOR was used.  Delete code that is now dead with
8280         the elimination of TARGET_VSX_SMALL_INTEGER.
8281         (vsx_extract_<mode>_p8): Likewise.
8282         (vsx_ext_<VSX_EXTRACT_I:VS_scalar>_fl_<FL_CONV:mode>): Likewise.
8283         (vsx_ext_<VSX_EXTRACT_I:VS_scalar>_ufl_<FL_CONV:mode>): Likewise.
8284         (vsx_set_<mode>_p9): Likewise.
8285         (vsx_set_v4sf_p9): Likewise.
8286         (vsx_set_v4sf_p9_zero): Likewise.
8287         (vsx_insert_extract_v4sf_p9): Likewise.
8288         (vsx_insert_extract_v4sf_p9_2): Likewise.
8289         * config/rs6000/rs6000.md (sign extend splitter): Change
8290         TARGET_VSX_SMALL_INTEGER to TARGET_P8_VECTOR test.
8291         (floatsi<mode>2_lfiwax_mem): Likewise.
8292         (floatunssi<mode>2_lfiwzx_mem): Likewise.
8293         (float<QHI:mode><FP_ISA3:mode>2): Delete TARGET_VSX_SMALL_INTEGER,
8294         since a test for TARGET_P9_VECTOR was used.
8295         (float<QHI:mode><FP_ISA3:mode>2_internal): Likewise.
8296         (floatuns<QHI:mode><FP_ISA3:mode>2): Likewise.
8297         (floatuns<QHI:mode><FP_ISA3:mode>2_internal): Likewise.
8298         (fix_trunc<mode>si2): Change TARGET_VSX_SMALL_INTEGER to
8299         TARGET_P8_VECTOR test.
8300         (fix_trunc<mode>si2_stfiwx): Likewise.
8301         (fix_trunc<mode>si2_internal): Likewise.
8302         (fix_trunc<SFDF:mode><QHI:mode>2): Delete
8303         TARGET_VSX_SMALL_INTEGER, since a test for TARGET_P9_VECTOR was
8304         used.
8305         (fix_trunc<SFDF:mode><QHI:mode>2_internal): Likewise.
8306         (fixuns_trunc<mode>si2): Change TARGET_VSX_SMALL_INTEGER to
8307         TARGET_P8_VECTOR test.
8308         (fixuns_trunc<mode>si2_stfiwx): Likewise.
8309         (fixuns_trunc<SFDF:mode><QHI:mode>2): Delete
8310         TARGET_VSX_SMALL_INTEGER, since a test for TARGET_P9_VECTOR was
8311         used.
8312         (fixuns_trunc<SFDF:mode><QHI:mode>2_internal): Likewise.
8313         (fctiw<u>z_<mode>_smallint): Delete TARGET_VSX_SMALL_INTEGER,
8314         since a test for TARGET_P9_VECTOR was used.
8315         (splitter for loading small constants): Likewise.
8317 2017-07-26  Andrew Pinski  <apinski@cavium.com>
8319         * config/aarch64/aarch64.c (thunderx_vector_cost): Fix
8320         vec_fp_stmt_cost.
8322 2017-07-26  H.J. Lu  <hongjiu.lu@intel.com>
8324         PR target/81563
8325         * config/i386/i386.c (sp_valid_at): Properly check CFA offset.
8326         (fp_valid_at): Likewise.
8328 2017-07-26  James Greenhalgh  <james.greenhalgh@arm.com>
8330         * config/aarch64/aarch64.c (cortexa57_addrcost_table): Remove.
8331         (qdf24xx_addrcost_table): Likewise.
8332         (cortexa57_tunings): Update to use generic_branch_cost.
8333         (cortexa72_tunings): Likewise.
8334         (cortexa73_tunings): Likewise.
8335         (qdf24xx_tunings): Likewise.
8337 2017-07-26  James Greenhalgh  <james.greenhalgh@arm.com>
8339         * config/aarch64/aarch64.c (cortexa57_branch_cost): Remove.
8340         (thunderx2t99_branch_cost): Likewise.
8341         (cortexa35_tunings): Update to use generic_branch_cost.
8342         (cortexa53_tunings): Likewise.
8343         (cortexa57_tunings): Likewise.
8344         (cortexa72_tunings): Likewise.
8345         (cortexa73_tunings): Likewise.
8346         (thunderx2t99_tunings): Likewise.
8348 2017-07-26  Sebastian Huber  <sebastian.huber@embedded-brains.de>
8350         * config/sparc/sparc.c (dump_target_flag_bits): Dump MASK_FSMULD.
8351         (sparc_option_override): Honour MASK_FSMULD.
8352         * config/sparc/sparc.h (MASK_FEATURES): Add MASK_FSMULD.
8353         * config/sparc/sparc.md (muldf3_extend): Use TARGET_FSMULD.
8354         * config/sparc/sparc.opt (mfsmuld): New option.
8355         * doc/invoke.texi (mfsmuld): Document option.
8357 2017-07-26  Marek Polacek  <polacek@redhat.com>
8359         PR middle-end/70992
8360         * tree.c (build2_stat): Don't set TREE_CONSTANT on divisions by zero.
8362 2017-07-26  Richard Biener  <rguenther@suse.de>
8364         * gimple-match-head.c (do_valueize): Return OP if valueize
8365         returns NULL_TREE.
8366         (get_def): New helper to get at the def stmt of a SSA name
8367         if valueize allows.
8368         * genmatch.c (dt_node::gen_kids_1): Use get_def instead of
8369         do_valueize to get at the def stmt.
8370         (dt_operand::gen_gimple_expr): Simplify do_valueize calls.
8372 2017-07-26  Wilco Dijkstra  <wdijkstr@arm.com>
8374         PR middle-end/46932
8375         * auto-inc-dec.c (parse_add_or_inc): Block autoinc on sfp.
8377 2017-07-26  Martin Liska  <mliska@suse.cz>
8379         PR sanitize/81186
8380         * function.c (expand_function_start): Make expansion of
8381         nonlocal_goto_save_area after parm_birth_insn.
8383 2017-07-26  Sebastian Huber  <sebastian.huber@embedded-brains.de>
8385         * config/sparc/sparc.c (sparc_option_override): Remove MASK_FPU
8386         from all CPU target flags enable members.
8388 2017-07-26  Richard Biener  <rguenther@suse.de>
8390         * genmatch.c (dt_simplify::gen): Make iterator vars const.
8391         (decision_tree::gen): Make 'type' const.
8392         (write_predicate): Likewise.
8394 2017-07-24  Michael Meissner  <meissner@linux.vnet.ibm.com>
8396         * config/rs6000/rs6000.c (rs6000_init_hard_regno_mode_ok):
8397         Eliminate TARGET_UPPER_REGS_{DF,DI,SF} usage.
8398         (rs6000_option_override_internal): Likewise.
8399         (rs6000_expand_vector_set): Likewise.
8400         * config/rs6000/rs6000.h (TARGET_UPPER_REGS_DF): Delete.
8401         (TARGET_UPPER_REGS_SF): Likewise.
8402         (TARGET_UPPER_REGS_DI): Likewise.
8403         (TARGET_VEXTRACTUB): Eliminate TARGET_UPPER_REGS_{DF,DI,SF}.
8404         (TARGET_DIRECT_MOVE_64BIT): Likewise.
8405         * config/rs6000/rs6000.md (ALTIVEC_DFORM): Likewise.
8406         (float<QHI:mode><FP_ISA3:mode>2_internal): Likewise.
8407         (Splitters for DI constants in Altivec registers): Likewise.
8408         * config/rs6000/vsx.md (vsx_set_<mode>_p9): Likewise.
8409         (vsx_set_v4sf_p9): Likewise.
8410         (vsx_set_v4sf_p9_zero): Likewise.
8411         (vsx_insert_extract_v4sf_p9): Likewise.
8412         (vsx_insert_extract_v4sf_p9_2): Likewise.
8414 2017-07-25  Carl Love  <cel@us.ibm.com>
8416         * doc/extend.texi: Update the built-in documentation file for the
8417         existing built-in functions
8418         vector signed char vec_cnttz (vector signed char);
8419         vector unsigned char vec_cnttz (vector unsigned char);
8420         vector signed short vec_cnttz (vector signed short);
8421         vector unsigned short vec_cnttz (vector unsigned short);
8422         vector signed int vec_cnttz (vector signed int);
8423         vector unsigned int vec_cnttz (vector unsigned int);
8424         vector signed long long vec_cnttz (vector signed long long);
8425         vector unsigned long long vec_cnttz (vector unsigned long long);
8427 2017-07-25  Andrew Pinski  <apinski@cavium.com>
8429         * tree-ssa-uninit.c (warn_uninitialized_vars): Don't warn about memory
8430         accesses where the use is for the first operand of a BIT_INSERT.
8432 2017-07-25  Jim Wilson  <jim.wilson@linaro.org>
8434         PR bootstrap/81521
8435         * config/i386/winnt-cxx.c (i386_pe_adjust_class_at_definition): Look
8436         for FUNCTION_DECLs in TYPE_FIELDS rather than TYPE_METHODS.
8438 2017-07-25  Jim Wilson  <jim.wilson@linaro.org>
8440         * config/i386/gstabs.h: Delete.
8441         * config/i386/openbsd.h, config/i386/t-openbsd: Likewise.
8443 2017-07-25  Uros Bizjak  <ubizjak@gmail.com>
8445         * config/i386/i386.c (ix86_decompose_address): Do not check for
8446         register RTX when looking at index_reg or base_reg.
8447         * config/i386/i386.h (INCOMING_RETURN_ADDR_RTX): Use stack_pointer_rtx.
8449 2017-07-25  Eric Botcazou  <ebotcazou@adacore.com>
8451         * gimple.c (gimple_assign_set_rhs_with_ops): Do not ask gsi_replace
8452         to update EH info here.
8454 2017-07-25  Alexander Monakov  <amonakov@ispras.ru>
8456         * match.pd ((X * CST1) * CST2): Simplify to X * (CST1 * CST2).
8458 2017-07-25  Alexander Monakov  <amonakov@ispras.ru>
8460         * match.pd ((X * CST) * Y): Reassociate to (X * Y) * CST.
8462 2017-07-25  Torsten Duwe  <duwe@suse.de>
8464         * common.opt: Introduce -fpatchable-function-entry
8465         command line option, and its variables function_entry_patch_area_size
8466         and function_entry_patch_area_start.
8467         * opts.c (common_handle_option): Add -fpatchable_function_entry_ case,
8468         including a two-value parser.
8469         * target.def (print_patchable_function_entry): New target hook.
8470         * targhooks.h (default_print_patchable_function_entry): New function.
8471         * targhooks.c (default_print_patchable_function_entry): Likewise.
8472         * toplev.c (process_options): Switch off IPA-RA if
8473         patchable function entries are being generated.
8474         * varasm.c (assemble_start_function): Look at the
8475         patchable-function-entry command line switch and current
8476         function attributes and maybe generate NOP instructions by
8477         calling the print_patchable_function_entry hook.
8478         * doc/extend.texi: Document patchable_function_entry attribute.
8479         * doc/invoke.texi: Document -fpatchable_function_entry
8480         command line option.
8481         * doc/tm.texi.in (TARGET_ASM_PRINT_PATCHABLE_FUNCTION_ENTRY):
8482         New target hook.
8483         * doc/tm.texi: Re-generate.
8485 2017-07-25  Jakub Jelinek  <jakub@redhat.com>
8487         PR target/81532
8488         * config/i386/constraints.md (Yd, Ye): Use ALL_SSE_REGS for
8489         TARGET_AVX512DQ rather than TARGET_AVX512BW.
8491 2017-07-25  Tamar Christina  <tamar.christina@arm.com>
8493         * config/arm/parsecpu.awk (all_cores): Remove duplicates.
8495 2017-07-25  Richard Biener  <rguenther@suse.de>
8497         PR tree-optimization/81455
8498         * tree-ssa-loop-unswitch.c (find_loop_guard): Make sure to
8499         not walk in cycles when looking for guards.
8501 2017-07-25  Richard Biener  <rguenther@suse.de>
8503         PR tree-optimization/81529
8504         * tree-vect-stmts.c (process_use): Disregard live induction PHIs
8505         when optimizing backedge uses.
8507 2017-07-25  David Edelsohn  <dje.gcc@gmail.com>
8509         * dwarf2asm.c (dw2_asm_output_nstring): Encode double quote
8510         character for AIX.
8511         * dwarf2out.c (output_macinfo): Copy debug_line_section_label
8512         to dl_section_ref.  On AIX, append an expression to subtract
8513         the size of the section length to dl_section_ref.
8515 2017-07-25  Segher Boessenkool  <segher@kernel.crashing.org>
8517         * configure.ac: If any of the config.* scripts fail, exit 1.
8518         * configure: Regenerate.
8520 2017-07-25  Richard Biener  <rguenther@suse.de>
8522         PR middle-end/81546
8523         * tree-ssa-operands.c (verify_imm_links): Remove cap on number
8524         of immediate uses, be more verbose on errors.
8526 2017-07-25  Richard Biener  <rguenther@suse.de>
8528         PR tree-optimization/81510
8529         * tree-vect-loop.c (vect_is_simple_reduction): When the
8530         reduction stmt is not inside the loop bail out.
8532 2017-07-25  Richard Biener  <rguenther@suse.de>
8534         PR tree-optimization/81303
8535         * tree-vect-loop-manip.c (vect_loop_versioning): Build
8536         profitability check against LOOP_VINFO_NITERSM1.
8538 2017-07-25  Alexander Monakov  <amonakov@ispras.ru>
8540         * domwalk.c (cmp_bb_postorder): Simplify.
8541         (sort_bbs_postorder): New function.  Use it...
8542         (dom_walker::walk): ...here to optimize common cases.
8544 2017-07-25  Martin Liska  <mliska@suse.cz>
8546         PR ipa/81520
8547         * ipa-visibility.c (function_and_variable_visibility): Make the
8548         redirection just on target that supports aliasing.
8549         Fix GNU coding style.
8551 2017-07-25  Sebastian Huber  <sebastian.huber@embedded-brains.de>
8553         PR libgcc/61152
8554         * config/aarch64/rtems.h: Add GCC Runtime Library Exception.
8555         Format changes.
8556         * config/arm/rtems.h: Likewise.
8557         * config/bfin/rtems.h: Likewise.
8558         * config/i386/rtemself.h: Likewise.
8559         * config/lm32/rtems.h: Likewise.
8560         * config/m32c/rtems.h: Likewise.
8561         * config/m68k/rtemself.h: Likewise.
8562         * config/microblaze/rtems.h: Likewise.
8563         * config/mips/rtems.h: Likewise.
8564         * config/moxie/rtems.h: Likewise.
8565         * config/nios2/rtems.h: Likewise.
8566         * config/powerpcspe/rtems.h: Likewise.
8567         * config/rs6000/rtems.h: Likewise.
8568         * config/rtems.h: Likewise.
8569         * config/sh/rtems.h: Likewise.
8570         * config/sh/rtemself.h: Likewise.
8571         * config/sparc/rtemself.h: Likewise.
8573 2017-07-25  Georg-Johann Lay  <avr@gjlay.de>
8575         PR 81487
8576         * hsa-brig.c (brig_init): Use xasprintf instead of asprintf.
8577         * gimple-pretty-print.c (dump_profile, dump_probability): Same.
8578         * tree-ssa-structalias.c (alias_get_name): Same.
8580 2017-07-25  Bin Cheng  <bin.cheng@arm.com>
8582         PR target/81414
8583         * config/aarch64/cortex-a57-fma-steering.c (analyze): Skip fmul/fmac
8584         instructions if no du chain is found.
8586 2017-07-25  Georg-Johann Lay  <avr@gjlay.de>
8588         * config/avr/avr-log.c (avr_log_vadump) ['T']: Print NULL-TREE.
8590 2017-07-25  Richard Biener  <rguenther@suse.de>
8592         PR middle-end/81505
8593         * fold-const.c (fold_negate_const): TREE_OVERFLOW should be
8594         sticky.
8596 2017-07-24  Michael Meissner  <meissner@linux.vnet.ibm.com>
8598         * config/rs6000/rs6000-cpus.def (ISA_2_6_MASKS_SERVER): Delete
8599         upper-regs options.
8600         (ISA_2_7_MASKS_SERVER): Likewise.
8601         (ISA_3_0_MASKS_IEEE): Likewise.
8602         (OTHER_P8_VECTOR_MASKS): Likewise.
8603         (OTHER_VSX_VECTOR_MASKS): Likewise.
8604         (POWERPC_MASKS): Likewise.
8605         (power7 cpu): Use ISA_2_6_MASKS_SERVER instead of using a
8606         duplicate list of options.
8607         * config/rs6000/rs6000-c.c (rs6000_target_modify_macros): Remove
8608         explicit -mupper-regs options.
8609         * config/rs6000/rs6000.opt (-mvsx-scalar-memory): Delete
8610         -mupper-regs* options.  Delete -mvsx-scalar-memory, which was an
8611         alias for -mupper-regs-df.
8612         * config/rs6000/rs6000.c (rs6000_setup_reg_addr_masks): Likewise.
8613         (rs6000_init_hard_regno_mode_ok): Likewise.
8614         (rs6000_option_override_internal): Likewise.
8615         (rs6000_opt_masks): Likewise.
8616         * config/rs6000/rs6000.h (TARGET_UPPER_REGS_DF): Define upper regs
8617         options in terms of whether -mvsx or -mpower8-vector was used.
8618         (TARGET_UPPER_REGS_DI): Likewise.
8619         (TARGET_UPPER_REGS_SF): Likewise.
8620         * doc/invoke.texi (RS/6000 and PowerPC Options): Delete the
8621         -mupper-regs-* options.
8623 2017-07-24  Segher Boessenkool  <segher@kernel.crashing.org>
8625         * passes.c (emergency_dump_function): Print some empty lines and a
8626         header before the RTL dump.
8628 2017-07-24  Segher Boessenkool  <segher@kernel.crashing.org>
8630         * cfgrtl.c (rtl_dump_bb): Don't call NEXT_INSN on NULL.
8632 2017-07-24  Wilco Dijkstra  <wdijkstr@arm.com>
8634         PR target/79041
8635         * config/aarch64/aarch64.c (aarch64_classify_symbol):
8636         Avoid SYMBOL_SMALL_ABSOLUTE for literals with pc-relative literals.
8638 2017-07-24  Carl Love  <cel@us.ibm.com>
8640         * config/rs6000/rs6000-c.c: Add support for built-in functions
8641         vector float vec_extract_fp32_from_shorth (vector unsigned short);
8642         vector float vec_extract_fp32_from_shortl (vector unsigned short);
8643         * config/rs6000/altivec.h (vec_extract_fp_from_shorth,
8644         vec_extract_fp_from_shortl): Add defines for the two builtins.
8645         * config/rs6000/rs6000-builtin.def (VEXTRACT_FP_FROM_SHORTH,
8646         VEXTRACT_FP_FROM_SHORTL): Add BU_P9V_OVERLOAD_1 and BU_P9V_VSX_1
8647         new builtins.
8648         * config/rs6000/vsx.md vsx_xvcvhpsp): Add define_insn.
8649         (vextract_fp_from_shorth, vextract_fp_from_shortl): Add define_expands.
8650         * doc/extend.texi: Update the built-in documentation file for the
8651         new built-in function.
8653 2017-07-24  Jakub Jelinek  <jakub@redhat.com>
8655         PR bootstrap/81521
8656         * tree.def: Remove TYPE_METHODS documentation, adjust TYPE_FIELDS
8657         documentation.
8658         * doc/generic.texi: Likewise.
8659         * config/i386/winnt-cxx.c (i386_pe_adjust_class_at_definition): Look
8660         for FUNCTION_DECLs in TYPE_FIELDS rather than TYPE_METHODS.
8662 2017-07-24  Jackson Woodruff  <jackson.woodruff@arm.com>
8664         * config/aarch64/aarch64-simd.md (aarch64_mla_elt_merge<mode>): New.
8665         (aarch64_mls_elt_merge<mode>): Likewise.
8667 2017-07-23  Krister Walfridsson  <krister.walfridsson@gmail.com>
8669         * config.gcc (*-*-netbsd*): Remove check for NetBSD versions not
8670         having __cxa_atexit.
8672 2017-07-23  Michael Collison  <michael.collison@arm.com>
8674         * config/arm/arm.c (arm_option_override): Deprecate
8675         use of -mstructure-size-boundary.
8676         * config/arm/arm.opt: Deprecate -mstructure-size-boundary.
8677         * doc/invoke.texi: Deprecate -mstructure-size-boundary.
8679 2017-07-23  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
8681         PR target/80695
8682         * config/rs6000/rs6000.c (rs6000_builtin_vectorization_cost):
8683         Reduce cost estimate for direct moves.
8685 2017-07-23  Uros Bizjak  <ubizjak@gmail.com>
8687         PR target/80569
8688         * config/i386/i386.c (ix86_option_override_internal): Disable
8689         BMI, BMI2 and TBM instructions for -m16.
8691 2017-07-21  Carl Love  <cel@us.ibm.com>
8693         * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Add
8694         ALTIVEC_BUILTIN_VMULESW, ALTIVEC_BUILTIN_VMULEUW,
8695         ALTIVEC_BUILTIN_VMULOSW, ALTIVEC_BUILTIN_VMULOUW entries.
8696         * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin,
8697         builtin_function_type): Add ALTIVEC_BUILTIN_* case statements.
8698         * config/rs6000/altivec.md (MVULEUW, VMULESW, VMULOUW,
8699         VMULOSW): New enum "unspec" values.
8700         (altivec_vmuleuw, altivec_vmulesw, altivec_vmulouw,
8701         altivec_vmulosw): New patterns.
8702         * config/rs6000/rs6000-builtin.def (VMLEUW, VMULESW, VMULOUW,
8703         VMULOSW): Add definitions.
8705 2017-07-21  Jim Wilson  <jim.wilson@linaro.org>
8707         * config/aarch64/aarch64-cores.def (falkor): Add AARCH64_FL_RDMA.
8708         (qdf24xx): Likewise.
8709         * config/aarch64/aarch64-options-extensions.def (rdma); New.
8710         * config/aarch64/aarch64.h (AARCH64_FL_RDMA): New.
8711         (AARCH64_FL_V8_1): Renumber.
8712         (AARCH64_FL_FOR_ARCH8_1): Add AARCH64_FL_RDMA.
8713         (AARCH64_ISA_RDMA): Use AARCH64_FL_RDMA.
8714         * config/aarch64/arm_neon.h: Use +rdma instead of arch=armv8.1-a.
8715         * doc/invoke.texi (AArch64 Options): Mention +rmda in -march docs.  Add
8716         rdma to feature modifiers list.
8718 2017-07-21  Yury Gribov  <tetra2005@gmail.com>
8720         PR middle-end/56727
8721         * ipa-visibility (function_and_variable_visibility): Convert
8722         recursive PLT call to direct call if appropriate.
8724 2017-07-21  Andrew Pinski  <apinski@cavium.com>
8726         * tree-ssa-sccvn.c (vn_nary_op_eq): Check BIT_INSERT_EXPR's
8727         operand 1 to see if the types precision matches.
8728         * fold-const.c (operand_equal_p): Likewise.
8730 2017-07-21  Richard Biener  <rguenther@suse.de>
8732         PR tree-optimization/81303
8733         * tree-vect-data-refs.c (vect_get_peeling_costs_all_drs): Pass
8734         in datarefs vector.  Allow NULL dr0 for no peeling cost estimate.
8735         (vect_peeling_hash_get_lowest_cost): Adjust.
8736         (vect_enhance_data_refs_alignment): Likewise.  Use
8737         vect_get_peeling_costs_all_drs to compute the penalty for no
8738         peeling to match up costs.
8740 2017-07-21  Richard Biener  <rguenther@suse.de>
8742         PR tree-optimization/81500
8743         * tree-vect-loop.c (vect_is_simple_reduction): Properly fail if
8744         we didn't identify a reduction path.
8746 2017-07-21  Tom de Vries  <tom@codesourcery.com>
8747             Cesar Philippidis  <cesar@codesourcery.com>
8749         PR gcov-profile/81442
8750         * config/nvptx/nvptx.c (nvptx_goacc_reduction_init): Add missing edge
8751         probabilities.
8753 2017-07-21  Tom de Vries  <tom@codesourcery.com>
8755         PR lto/81430
8756         * config/nvptx/nvptx.c (nvptx_override_options_after_change): New
8757         function.
8758         (TARGET_OVERRIDE_OPTIONS_AFTER_CHANGE): Define to
8759         nvptx_override_options_after_change.
8761 2017-07-21  Ulrich Drepper  <drepper@redhat.com>
8763         * dwarf2out.c (output_file_names): Avoid double testing for
8764         dwarf_version >= 5.
8766 2017-07-21  Georg-Johann Lay  <avr@gjlay.de>
8768         * doc/invoke.texi (AVR Built-in Functions): Re-layout section.
8770 2016-07-21  Jan Hubicka  <hubicka@ucw.cz>
8772         * cfgcleanup.c (flow_find_cross_jump): Do not crossjump across
8773         hot/cold regions.
8774         (try_crossjump_to_edge): Do not punt on partitioned functions.
8776 2016-07-21  Jan Hubicka  <hubicka@ucw.cz>
8778         * bb-reorder.c (find_rarely_executed_basic_blocks_and_crossing_edges):
8779         Put all BBs reachable only via paths crossing cold region to cold
8780         region.
8781         * cfgrtl.c (find_bbs_reachable_by_hot_paths): New function.
8783 2016-07-21  Richard Biener  <rguenther@suse.de>
8785         PR tree-optimization/81303
8786         * tree-vect-loop.c (vect_estimate_min_profitable_iters): Take
8787         into account prologue and epilogue iterations when raising
8788         min_profitable_iters to sth at least covering one vector iteration.
8790 2017-07-21  Tamar Christina  <tamar.christina@arm.com>
8792         * config/arm/arm.c (arm_test_cpu_arch_dat):
8793         Check for overlap.
8795 2017-07-20  Nathan Sidwell  <nathan@acm.org>
8797         Remove TYPE_METHODS.
8798         * tree.h (TYPE_METHODS): Delete.
8799         * dwarf2out.c (gen_member_die): Member fns are on TYPE_FIELDS.
8800         * dbxout.c (dbxout_type_fields): Ignore FUNCTION_DECLs.
8801         (dbxout_type_methods): Scan TYPE_FIELDS.
8802         (dbxout_type): Don't check TYPE_METHODS here.
8803         * function.c (use_register_for_decl): Always ignore register for
8804         class types when not optimizing.
8805         * ipa-devirt.c (odr_types_equivalent_p): Delete TYPE_METHODS scan.
8806         * tree.c (free_lang_data_in_type): Stitch out member functions and
8807         templates from TYPE_FIELDS.
8808         (build_distinct_type_copy, verify_type_variant,
8809         verify_type): Member fns are on TYPE_FIELDS.
8810         * tree-dump.c (dequeue_and_dump): No TYPE_METHODS.
8811         * tree-pretty-print.c (dump_generic_node): Likewise.
8813 2017-07-20  Jakub Jelinek  <jakub@redhat.com>
8815         PR target/80846
8816         * config/i386/i386.c (ix86_expand_vector_init_general): Handle
8817         V2TImode and V4TImode.
8818         (ix86_expand_vector_extract): Likewise.
8819         * config/i386/sse.md (VMOVE): Enable V4TImode even for just
8820         TARGET_AVX512F, instead of only for TARGET_AVX512BW.
8821         (ssescalarmode): Handle V4TImode and V2TImode.
8822         (VEC_EXTRACT_MODE): Add V4TImode and V2TImode.
8823         (*vec_extractv2ti, *vec_extractv4ti): New insns.
8824         (VEXTRACTI128_MODE): New mode iterator.
8825         (splitter for *vec_extractv?ti first element): New.
8826         (VEC_INIT_MODE): New mode iterator.
8827         (vec_init<mode>): Consolidate 3 expanders into one using
8828         VEC_INIT_MODE mode iterator.
8830 2017-07-20  Alexander Monakov  <amonakov@ispras.ru>
8832         * lra-assigns.c (pseudo_compare_func): Fix comparison step based on
8833         non_spilled_static_chain_regno_p.
8835 2017-07-20  Alexander Monakov  <amonakov@ispras.ru>
8837         * gimple-ssa-store-merging.c (sort_by_bitpos): Return 0 on equal bitpos.
8839 2017-07-20  Jan Hubicka  <hubicka@ucw.cz>
8841         * bb-reorder.c (connect_traces): Allow copying of blocks within
8842         single partition.
8844 2017-07-20  Richard Biener  <rguenther@suse.de>
8846         * gimple.h (gimple_phi_result): Add gphi * overload.
8847         (gimple_phi_result_ptr): Likewise.
8848         (gimple_phi_arg): Likewise.  Adjust index assert to only
8849         allow actual argument accesses rather than all slots available
8850         by capacity.
8851         (gimple_phi_arg_def): Add gphi * overload.
8852         * tree-phinodes.c (make_phi_node): Initialize only actual
8853         arguments.
8854         (resize_phi_node): Clear memory not covered by old node,
8855         do not initialize excess argument slots.
8856         (reserve_phi_args_for_new_edge): Initialize new argument slot
8857         completely.
8859 2017-07-20  Bin Cheng  <bin.cheng@arm.com>
8861         PR tree-optimization/81388
8862         Revert r238585:
8863         2016-07-21  Bin Cheng  <bin.cheng@arm.com>
8865         * tree-ssa-loop-niter.c (number_of_iterations_lt_to_ne): Clean up
8866         by removing computation of may_be_zero.
8868 2017-07-18  Jan Hubicka  <hubicka@ucw.cz>
8869             Tom de Vries  <tom@codesourcery.com>
8871         PR middle-end/81030
8872         * cfgbuild.c (find_many_sub_basic_blocks): Update REG_BR_PROB note
8873         when gimple level profile disagrees with what RTL expander did.
8875 2017-07-20  Richard Biener  <rguenther@suse.de>
8877         PR tree-optimization/61171
8878         * tree-vectorizer.h (slp_instance): Add reduc_phis member.
8879         (vect_analyze_stmt): Add slp instance parameter.
8880         (vectorizable_reduction): Likewise.
8881         * tree-vect-loop.c (vect_analyze_loop_operations): Adjust.
8882         (vect_is_simple_reduction): Deal with chains not detected
8883         as SLP reduction chain, specifically not properly associated
8884         chains containing a mix of plus/minus.
8885         (get_reduction_op): Remove.
8886         (get_initial_defs_for_reduction): Simplify, pass in whether
8887         this is a reduction chain, pass in the SLP node for the PHIs.
8888         (vect_create_epilog_for_reduction): Get the SLP instance as
8889         arg and adjust.
8890         (vectorizable_reduction): Get the SLP instance as arg.
8891         During analysis remember the SLP node with the PHIs in the
8892         instance.  Simplify getting at the vectorized reduction PHIs.
8893         * tree-vect-slp.c (vect_slp_analyze_node_operations): Pass
8894         through SLP instance.
8895         (vect_slp_analyze_operations): Likewise.
8896         * tree-vect-stms.c (vect_analyze_stmt): Likewise.
8897         (vect_transform_stmt): Likewise.
8899 2017-07-20  Tom de Vries  <tom@codesourcery.com>
8901         PR tree-optimization/81489
8902         * gimple-ssa-isolate-paths.c (find_implicit_erroneous_behavior): Move
8903         read of phi arg location to before loop that modifies phi.
8905 2017-07-20  Naveen H.S  <Naveen.Hurugalawadi@cavium.com>
8907         * match.pd (((m1 >/</>=/<= m2) * d -> (m1 >/</>=/<= m2) ? d : 0):
8908         New pattern.
8910 2017-07-19  Jan Hubicka  <hubicka@ucw.cz>
8912         PR middle-end/81331
8913         * except.c (execute): Fix ordering issue.
8915 2018-07-19  Segher Boessenkool  <segher@kernel.crashing.org>
8917         PR rtl-optimization/81423
8918         * combine.c (make_compound_operation_int): Don't try to optimize
8919         the AND of a SUBREG of an LSHIFTRT if that SUBREG is paradoxical.
8921 2017-07-19  Segher Boessenkool  <segher@kernel.crashing.org>
8923         PR rtl-optimization/81423
8924         * simplify-rtx.c (simplify_truncation): Handle truncating an IOR
8925         with a constant that is -1 in the truncated to mode.
8927 2017-07-19  Jan Hubicka  <hubicka@ucw.cz>
8929         * predict.c (propagate_unlikely_bbs_forward): Break out from ...
8930         (determine_unlikely_bbs): ... here.
8931         * predict.h (propagate_unlikely_bbs_forward): Declare.
8932         * cfgexpand.c (pass_expand::execute): Use it.
8933         * bb-reorder.c (sanitize_hot_paths): Do not consider known to be
8934         unlikely edges.
8935         (find_rarely_executed_basic_blocks_and_crossing_edges): Use
8936         propagate_unlikely_bbs_forward.
8938 2017-07-19  Jan Hubicka  <hubicka@ucw.cz>
8940         PR middle-end/81331
8941         * except.c (maybe_add_nop_after_section_switch): New function.
8942         (execute): Use it.
8944 2017-07-19  Tom de Vries  <tom@codesourcery.com>
8946         * gimple.h (gimple_phi_set_arg): Make assert more strict.
8948 2017-07-19  Tom de Vries  <tom@codesourcery.com>
8950         * gimple.h (gimple_phi_arg): Make assert more strict.
8952 2017-07-19  Steven Munroe  <munroesj@gcc.gnu.org>
8954         * config.gcc (powerpc*-*-*): Add mmintrin.h.
8955         * config/rs6000/mmintrin.h: New file.
8956         * config/rs6000/x86intrin.h [__ALTIVEC__]: Include mmintrin.h.
8958 2017-07-19  Jakub Jelinek  <jakub@redhat.com>
8960         PR tree-optimization/81346
8961         * match.pd: Optimize (X - 1U) <= INT_MAX-1U into (int) X > 0.
8963 2017-07-19  Tom de Vries  <tom@codesourcery.com>
8965         * config/nvptx/nvptx.md (VECIM): Add V2DI.
8967 2017-07-19  Tom de Vries  <tom@codesourcery.com>
8969         * config/nvptx/nvptx-modes.def: Add V2DImode.
8970         * config/nvptx/nvptx-protos.h (nvptx_data_alignment): Declare.
8971         * config/nvptx/nvptx.c (nvptx_ptx_type_from_mode): Handle V2DImode.
8972         (nvptx_output_mov_insn): Handle lack of mov.b128.
8973         (nvptx_print_operand): Handle 'H' and 'L' codes.
8974         (nvptx_vector_mode_supported): Allow V2DImode.
8975         (nvptx_preferred_simd_mode): New function.
8976         (nvptx_data_alignment): New function.
8977         (TARGET_VECTORIZE_PREFERRED_SIMD_MODE): Redefine to
8978         nvptx_preferred_simd_mode.
8979         * config/nvptx/nvptx.h (STACK_BOUNDARY, BIGGEST_ALIGNMENT): Change from
8980         64 to 128 bits.
8981         (DATA_ALIGNMENT): Define.  Set to nvptx_data_alignment.
8983 2017-07-19  Tom de Vries  <tom@codesourcery.com>
8985         * config/nvptx/nvptx-modes.def: New file.  Add V2SImode.
8986         * config/nvptx/nvptx.c (nvptx_ptx_type_from_mode): Handle V2SImode.
8987         (nvptx_vector_mode_supported): New function.  Allow V2SImode.
8988         (TARGET_VECTOR_MODE_SUPPORTED_P): Redefine to nvptx_vector_mode_supported.
8989         * config/nvptx/nvptx.md (VECIM): New mode iterator. Add V2SI.
8990         (mov<VECIM>_insn): New define_insn.
8991         (define_expand "mov<VECIM>): New define_expand.
8993 2017-07-19  Tom de Vries  <tom@codesourcery.com>
8995         * config/nvptx/nvptx.c (nvptx_print_operand): Handle v2 vector mode.
8997 2017-07-19  Jakub Jelinek  <jakub@redhat.com>
8999         PR tree-optimization/81346
9000         * fold-const.h (fold_div_compare, range_check_type): Declare.
9001         * fold-const.c (range_check_type): New function.
9002         (build_range_check): Use range_check_type.
9003         (fold_div_compare): No longer static, rewritten into
9004         a match.pd helper function.
9005         (fold_comparison): Don't call fold_div_compare here.
9006         * match.pd (X / C1 op C2): New optimization using fold_div_compare
9007         as helper function.
9009 2017-07-19  Nathan Sidwell  <nathan@acm.org>
9011         * tree.h (TYPE_MINVAL, TYPE_MAXVAL): Rename to ...
9012         (TYPE_MIN_VALUE_RAW, TYPE_MAX_VALUE_RAW): ... these.
9013         * tree.c (find_decls_types_r, verify_type): Use
9014         TYPE_{MIN,MAX}_VALUE_RAW.
9015         * lto-streamer-out.c (DFS::DFS_write_tree_body): Likewise.
9016         (hash_tree): Likewise.
9017         * tree-streamer-in.c (lto_input_ts_type_non_common_tree_pointers):
9018         Likewise.
9019         * tree-streamer-out.c (write_ts_type_non_common_tree_pointers):
9020         Likewise.
9022 2017-07-18  Tom de Vries  <tom@codesourcery.com>
9024         PR middle-end/81464
9025         * omp-expand.c (expand_omp_for_static_chunk): Handle
9026         equal-argument loop exit phi.
9028 2017-07-18  Uros Bizjak  <ubizjak@gmail.com>
9030         PR target/81471
9031         * config/i386/i386.md (rorx_immediate_operand): New mode attribute.
9032         (*bmi2_rorx<mode>3_1): Use rorx_immediate_operand as
9033         operand 2 predicate.
9034         (*bmi2_rorxsi3_1_zext): Use const_0_to_31_operand as
9035         operand 2 predicate.
9036         (ror,rol -> rorx splitters): Use const_int_operand as
9037         operand 2 predicate.
9039 2017-06-18  Richard Biener  <rguenther@suse.de>
9041         PR tree-optimization/81410
9042         * tree-vect-stmts.c (vectorizable_load): Properly adjust for
9043         the gap in the ! slp_perm SLP case after each group.
9045 2017-07-18  Jan Hubicka  <hubicka@ucw.cz>
9047         PR middle-end/81463
9048         * cfgloopmanip.c (scale_loop_profile): Watch out for zero frequency
9049         again.
9051 2017-07-18  Jan Hubicka  <hubicka@ucw.cz>
9053         PR middle-end/81462
9054         * predict.c (set_even_probabilities): Cleanup; do not affect
9055         probabilities that are already known.
9056         (combine_predictions_for_bb): Call even when count is set.
9058 2017-07-18  Nathan Sidwell  <nathan@acm.org>
9060         * tree-parloops.c (try_transform_to_exit_first_loop_alt): Use
9061         TYPE_MAX_VALUE.
9063 2017-07-18  Bin Cheng  <bin.cheng@arm.com>
9065         PR target/81408
9066         * tree-ssa-loop-niter.c (number_of_iterations_exit): Dump missed
9067         optimization for loop niter analysis.
9069 2017-07-18  Georg-Johann Lay  <avr@gjlay.de>
9071         PR target/81473
9072         * config/avr/avr.c (avr_optimize_casesi): Don't use
9073         INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX, UINT16_MAX.
9075 2017-07-18  Robin Dapp  <rdapp@linux.vnet.ibm.com>
9077         * tree-vect-data-refs.c (vect_enhance_data_refs_alignment): Remove
9078         body_cost_vec from _vect_peel_extended_info.
9079         (vect_peeling_hash_get_lowest_cost): Do not set body_cost_vec.
9080         (vect_peeling_hash_choose_best_peeling): Remove body_cost_vec and
9081         npeel.
9083 2017-07-18  Bin Cheng  <bin.cheng@arm.com>
9085         * config/arm/arm.c (emit_unlikely_jump): Remove unused var.
9087 2017-07-18  Richard Biener  <rguenther@suse.de>
9089         PR tree-optimization/80620
9090         PR tree-optimization/81403
9091         * tree-ssa-pre.c (phi_translate_1): Clear range and points-to
9092         info when re-using a VN table entry.
9094 2017-07-18  Richard Biener  <rguenther@suse.de>
9096         PR tree-optimization/81418
9097         * tree-vect-loop.c (vectorizable_reduction): Properly compute
9098         vectype_in.  Verify that with lane-reducing reduction operations
9099         we have a single def-use cycle.
9101 2017-07-17  Carl Love  <cel@us.ibm.com>
9103         Revert commit r249424   2017-06-20  Carl Love  <cel@us.ibm.com>
9105         * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Add
9106         ALTIVEC_BUILTIN_VMULESW, ALTIVEC_BUILTIN_VMULEUW,
9107         ALTIVEC_BUILTIN_VMULOSW, ALTIVEC_BUILTIN_VMULOUW entries.
9108         * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin,
9109         builtin_function_type): Add ALTIVEC_BUILTIN_* case statements.
9110         * config/rs6000/altivec.md (MVULEUW, VMULESW, VMULOUW,
9111         VMULOSW): New enum "unspec" values.
9112         (vec_widen_umult_even_v4si, vec_widen_smult_even_v4si,
9113         vec_widen_umult_odd_v4si, vec_widen_smult_odd_v4si,
9114         altivec_vmuleuw, altivec_vmulesw, altivec_vmulouw,
9115         altivec_vmulosw): New patterns.
9116         * config/rs6000/rs6000-builtin.def (VMLEUW, VMULESW, VMULOUW,
9117         VMULOSW): Add definitions.
9118 2017-07-17  Uros Bizjak  <ubizjak@gmail.com>
9120         * config/alpha/alpha.c: Include predict.h.
9122 2017-07-17  Yury Gribov  <tetra2005@gmail.com>
9124         * tree-vrp.c (compare_assert_loc): Fix comparison function
9125         to return predictable results.
9127 2017-07-17  Claudiu Zissulescu  <claziss@synopsys.com>
9129         * config/arc/arc.md (adddi3): Remove support for mexpand-adddi
9130         option.
9131         (subdi3): Likewise.
9132         * config/arc/arc.opt (mexpand-adddi): Deprecate it.
9133         * doc/invoke.texi (mexpand-adddi): Update text.
9135 2017-07-17  Claudiu Zissulescu  <claziss@synopsys.com>
9137         * config/arc/arc.md (clzsi2): Expand to an arc_clzsi2 instruction
9138         that also clobbers the CC register. The old expand code is moved
9139         to ...
9140         (*arc_clzsi2): ... here.
9141         (ctzsi2): Expand to an arc_ctzsi2 instruction that also clobbers
9142         the CC register. The old expand code is moved to ...
9143         (arc_ctzsi2): ... here.
9145 2017-07-17  Claudiu Zissulescu  <claziss@synopsys.com>
9147         * config/arc/arc.opt (mindexed-loads): Use initial value
9148         TARGET_INDEXED_LOADS_DEFAULT.
9149         (mauto-modify-reg): Use initial value
9150         TARGET_AUTO_MODIFY_REG_DEFAULT.
9151         * config/arc/elf.h (TARGET_INDEXED_LOADS_DEFAULT): Define.
9152         (TARGET_AUTO_MODIFY_REG_DEFAULT): Likewise.
9153         * config/arc/linux.h (TARGET_INDEXED_LOADS_DEFAULT): Define.
9154         (TARGET_AUTO_MODIFY_REG_DEFAULT): Likewise.
9156 2017-07-17  Martin Liska  <mliska@suse.cz>
9158         PR sanitizer/81302
9159         * opts.c (finish_options): Do not allow -fgnu-tm
9160         w/ -fsanitize={kernel-,}address.  Say sorry.
9162 2017-07-17  Bin Cheng  <bin.cheng@arm.com>
9164         PR target/81369
9165         * tree-loop-distribution.c (classify_partition): Only assert on
9166         numer of iterations.
9167         (merge_dep_scc_partitions): Delete prameter.  Update function call.
9168         (distribute_loop): Remove code handling loop with unknown niters.
9169         (pass_loop_distribution::execute): Skip loop with unknown niters.
9171 2017-07-17  Bin Cheng  <bin.cheng@arm.com>
9173         PR target/81369
9174         * tree-loop-distribution.c (merge_dep_scc_partitions): Sink call to
9175         function sort_partitions_by_post_order.
9177 2017-07-17  Bin Cheng  <bin.cheng@arm.com>
9179         PR tree-optimization/81374
9180         * tree-loop-distribution.c (pass_loop_distribution::execute): Record
9181         the max index of basic blocks, rather than number of basic blocks.
9183 2017-07-17  Claudiu Zissulescu  <claziss@synopsys.com>
9185         * config/arc/arc-protos.h (arc_legitimate_pc_offset_p): Remove
9186         proto.
9187         (arc_legitimate_pic_operand_p): Likewise.
9188         * config/arc/arc.c (arc_legitimate_pic_operand_p): Remove
9189         function.
9190         (arc_needs_pcl_p): Likewise.
9191         (arc_legitimate_pc_offset_p): Likewise.
9192         (arc_legitimate_pic_addr_p): Remove LABEL_REF case, as this
9193         function is also used in constrains.md.
9194         (arc_legitimate_constant_p): Use arc_legitimate_pic_addr_p to
9195         validate pic constants. Handle CONST_INT, CONST_DOUBLE, MINUS and
9196         PLUS.  Only return true/false in known cases, otherwise assert.
9197         (arc_legitimate_address_p): Remove arc_legitimate_pic_addr_p as it
9198         is already called in arc_legitimate_constant_p.
9199         * config/arc/arc.h (CONSTANT_ADDRESS_P): Consider also LABEL for
9200         pic addresses.
9201         (LEGITIMATE_PIC_OPERAND_P): Use
9202         arc_raw_symbolic_reference_mentioned_p function.
9203         * config/arc/constraints.md (Cpc): Use arc_legitimate_pic_addr_p
9204         function.
9205         (Cal): Likewise.
9206         (C32): Likewise.
9208 2017-07-17  Claudiu Zissulescu  <claziss@synopsys.com>
9209         Andrew Burgess  <andrew.burgess@embecosm.com>
9211         * config/arc/arc-protos.h (arc_compute_function_type): Change prototype.
9212         (arc_return_address_register): New function.
9213         * config/arc/arc.c (arc_handle_fndecl_attribute): New function.
9214         (arc_handle_fndecl_attribute): Add naked attribute.
9215         (TARGET_ALLOCATE_STACK_SLOTS_FOR_ARGS): Define.
9216         (TARGET_WARN_FUNC_RETURN): Likewise.
9217         (arc_allocate_stack_slots_for_args): New function.
9218         (arc_warn_func_return): Likewise.
9219         (machine_function): Change type fn_type.
9220         (arc_compute_function_type): Consider new naked function type,
9221         change function return type.
9222         (arc_must_save_register): Adapt to handle new
9223         arc_compute_function_type's return type.
9224         (arc_expand_prologue): Likewise.
9225         (arc_expand_epilogue): Likewise.
9226         (arc_return_address_regs): Delete.
9227         (arc_return_address_register): New function.
9228         (arc_epilogue_uses): Use above function.
9229         * config/arc/arc.h (arc_return_address_regs): Delete prototype.
9230         (arc_function_type): Change encoding, add naked type.
9231         (ARC_INTERRUPT_P): Change to handle the new encoding.
9232         (ARC_FAST_INTERRUPT_P): Likewise.
9233         (ARC_NORMAL_P): Define.
9234         (ARC_NAKED_P): Likewise.
9235         (arc_compute_function_type): Delete prototype.
9236         * config/arc/arc.md (in_ret_delay_slot): Use
9237         arc_return_address_register function.
9238         (simple_return): Likewise.
9239         (p_return_i): Likewise.
9241 2017-07-17  Jakub Jelinek  <jakub@redhat.com>
9243         PR tree-optimization/81428
9244         * match.pd (X / X -> one): Don't optimize _Fract divisions, as 1
9245         can't be built for those types.
9247 2017-07-17  Georg-Johann Lay  <avr@gjlay.de>
9249         Remove stuff dead since r239246.
9251         * config/avr/avr-arch.h (avr_inform_devices): Remove dead proto.
9252         * config/avr/avr-devices.c (mcu_name, comparator, avr_mcus_str)
9253         (avr_inform_devices): Remove dead stuff.
9255 2017-07-17  Tamar Christina  <tamar.christina@arm.com>
9257         * config/arm/arm_neon.h: Fix softp typo.
9259 2017-07-17  Jakub Jelinek  <jakub@redhat.com>
9261         PR tree-optimization/81365
9262         * tree-ssa-phiprop.c (propagate_with_phi): When considering hoisting
9263         aggregate moves onto bb predecessor edges, make sure there are no
9264         loads that could alias the lhs in between the start of bb and the
9265         loads from *phi.
9267 2017-07-17  Georg-Johann Lay  <avr@gjlay.de>
9269         PR 80929
9270         * config/avr/avr.c (avr_mul_highpart_cost): New static function.
9271         (avr_rtx_costs_1) [TRUNCATE]: Use it to compute mul_highpart cost.
9272         [LSHIFTRT, outer_code = TRUNCATE]: Same.
9274 2017-07-17  Jakub Jelinek  <jakub@redhat.com>
9276         PR tree-optimization/81396
9277         * tree-ssa-math-opts.c (struct symbolic_number): Add n_ops field.
9278         (init_symbolic_number): Initialize it to 1.
9279         (perform_symbolic_merge): Add n_ops from both operands into the new
9280         n_ops.
9281         (find_bswap_or_nop): Don't consider n->n == cmpnop computations
9282         without base_addr as useless if they need more than one operation.
9283         (bswap_replace): Handle !bswap case for NULL base_addr.
9285 2017-07-17  Tom de Vries  <tom@codesourcery.com>
9287         PR target/81069
9288         * config/nvptx/nvptx.c (nvptx_single): Insert diverging branch as late
9289         as possible.
9291 2017-07-17  Sebastian Huber  <sebastian.huber@embedded-brains.de>
9293         * config/sparc/rtemself.h (TARGET_OS_CPP_BUILTINS): Add
9294         conditional builtin define __FIX_LEON3FT_B2BST.
9296 2017-07-17  Daniel Cederman  <cederman@gaisler.com>
9298         * config/sparc/t-rtems: Add mfix-gr712rc multilibs. Replace
9299         MULTILIB_EXCEPTIONS with MULTILIB_REQUIRED. Match -mfix-gr712rc
9300         with -mfix-ut700.
9302 2017-07-16  Eric Botcazou  <ebotcazou@adacore.com>
9304         PR rtl-optimization/81424
9305         * optabs.c (prepare_cmp_insn): Use copy_to_reg instead of force_reg
9306         to remove potential trapping from operands if -fnon-call-exceptions.
9308 2017-07-16  Jan Hubicka  <hubicka@ucw.cz>
9310         * tree-ssa-loop-manip.c (tree_transform_and_unroll_loop): Use
9311         profile_proability for scalling.
9312         * scale_profile_for_vect_loop.c (scale_profile_for_vect_loop): Likewise.
9314 2017-07-16  Jan Hubicka  <hubicka@ucw.cz>
9316         * cgraph.c (cgraph_edge::redirect_call_stmt_to_caller): Cleanup.
9318 2017-07-16  Jan Hubicka  <hubicka@ucw.cz>
9320         * cfgloopmanip.c (scale_loop_profile): Avoid use of REG_BR_PROB_BASE
9321         fixpoint arithmetics.
9323 2017-07-16  Jan Hubicka  <hubicka@ucw.cz>
9325         * tree-ssa-loop-unswitch.c (hoist_guard): Avoid use of REG_BR_PROB_BASE
9326         fixpoint arithmetics.
9328 2017-07-16  Jan Hubicka  <hubicka@ucw.cz>
9330         * asan.c (create_cond_insert_point): Avoid use of REG_BR_PROB_BASE
9331         fixpoint arithmetics.
9333 2017-07-16  Jan Hubicka  <hubicka@ucw.cz>
9335         * profile-count.h (profile_probability::from_reg_br_prob_note,
9336         profile_probability::to_reg_br_prob_note): New functions.
9337         * doc/rtl.texi (REG_BR_PROB_NOTE): Update documentation.
9338         * reg-notes.h (REG_BR_PROB, REG_BR_PRED): Update docs.
9339         * predict.c (probability_reliable_p): Update.
9340         (edge_probability_reliable_p): Update.
9341         (br_prob_note_reliable_p): Update.
9342         (invert_br_probabilities): Update.
9343         (add_reg_br_prob_note): New function.
9344         (combine_predictions_for_insn): Update.
9345         * asan.c (asan_clear_shadow): Update.
9346         * cfgbuild.c (compute_outgoing_frequencies): Update.
9347         * cfgrtl.c (force_nonfallthru_and_redirect): Update.
9348         (update_br_prob_note): Update.
9349         (rtl_verify_edges): Update.
9350         (purge_dead_edges): Update.
9351         (fixup_reorder_chain): Update.
9352         * emit-rtl.c (try_split): Update.
9353         * ifcvt.c (cond_exec_process_insns): Update.
9354         (cond_exec_process_if_block): Update.
9355         (dead_or_predicable): Update.
9356         * internal-fn.c (expand_addsub_overflow): Update.
9357         (expand_neg_overflow): Update.
9358         (expand_mul_overflow): Update.
9359         * loop-doloop.c (doloop_modify): Update.
9360         * loop-unroll.c (compare_and_jump_seq): Update.
9361         * optabs.c (emit_cmp_and_jump_insn_1): Update.
9362         * predict.h: Update.
9363         * reorg.c (mostly_true_jump): Update.
9364         * rtl.h: Update.
9365         * config/aarch64/aarch64.c (aarch64_emit_unlikely_jump): Update.
9366         * config/alpha/alpha.c (emit_unlikely_jump): Update.
9367         * config/arc/arc.c: (emit_unlikely_jump): Update.
9368         * config/arm/arm.c: (emit_unlikely_jump): Update.
9369         * config/bfin/bfin.c (cbranch_predicted_taken_p): Update.
9370         * config/frv/frv.c (frv_print_operand_jump_hint): Update.
9371         * config/i386/i386.c (ix86_expand_split_stack_prologue): Update.
9372         (ix86_print_operand): Update.
9373         (ix86_split_fp_branch): Update.
9374         (predict_jump): Update.
9375         * config/ia64/ia64.c (ia64_print_operand): Update.
9376         * config/mmix/mmix.c (mmix_print_operand): Update.
9377         * config/powerpcspe/powerpcspe.c (output_cbranch): Update.
9378         (rs6000_expand_split_stack_prologue): Update.
9379         * config/rs6000/rs6000.c: Update.
9380         * config/s390/s390.c (s390_expand_vec_strlen): Update.
9381         (s390_expand_vec_movstr): Update.
9382         (s390_expand_cs_tdsi): Update.
9383         (s390_expand_split_stack_prologue): Update.
9384         * config/sh/sh.c (sh_print_operand): Update.
9385         (expand_cbranchsi4): Update.
9386         (expand_cbranchdi4): Update.
9387         * config/sparc/sparc.c (output_v9branch): Update.
9388         * config/spu/spu.c (get_branch_target): Update.
9389         (ea_load_store_inline): Update.
9390         * config/tilegx/tilegx.c (cbranch_predicted_p): Update.
9391         * config/tilepro/tilepro.c: Update.
9393 2017-07-16  Eric Botcazou  <ebotcazou@adacore.com>
9395         * gimplify.c (mostly_copy_tree_r): Revert latest change.
9396         (gimplify_save_expr): Likewise.
9398 2017-07-07  Jan Hubicka  <hubicka@ucw.cz>
9400         * ipa-visibility.c (function_and_variable_visibility): Fix pasto.
9402 2017-07-07  Jan Hubicka  <hubicka@ucw.cz>
9404         * ipa-fnsummary.c (pass_data_ipa_fn_summary): Use
9405         TV_IPA_FNSUMMARY.
9406         * timevar.def (TV_IPA_FNSUMMARY): Define.
9408 2017-07-16  Daniel Cederman  <cederman@gaisler.com>
9410         * config/sparc/sparc.md (divdf3_fix): Add NOP to prevent back
9411         to back store errata sensitive sequence from being generated.
9412         (sqrtdf2_fix): Likewise.
9414 2017-07-07  Jan Hubicka  <hubicka@ucw.cz>
9416         * tree-ssa-threadupdate.c (compute_path_counts,
9417         update_joiner_offpath_counts): Use profile_probability.
9419 2017-07-15  Thomas Preud'homme  <thomas.preudhomme@arm.com>
9421         Revert:
9422         2017-07-14  Thomas Preud'homme  <thomas.preudhomme@arm.com>
9424         * config/arm/arm-c.c (arm_cpu_builtins): Define
9425         __ARM_FEATURE_NUMERIC_MAXMIN solely based on TARGET_VFP5.
9427 2017-07-14  Kelvin Nilsen  <kelvin@gcc.gnu.org>
9429         * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Add
9430         array entries to represent __ieee128 versions of the
9431         scalar_test_data_class, scalar_test_neg, scalar_extract_exp,
9432         scalar_extract_sig, and scalar_insert_exp built-in functions.
9433         (altivec_resolve_overloaded_builtin): Add special case handling
9434         for the __builtin_scalar_insert_exp function, as represented by
9435         the P9V_BUILTIN_VEC_VSIEDP constant.
9436         * config/rs6000/rs6000-builtin.def (VSEEQP): Add scalar extract
9437         exponent support for __ieee128 argument.
9438         (VSESQP): Add scalar extract signature support for __ieee128
9439         argument.
9440         (VSTDCNQP): Add scalar test negative support for __ieee128
9441         argument.
9442         (VSIEQP): Add scalar insert exponent support for __int128 argument
9443         with __ieee128 result.
9444         (VSIEQPF): Add scalar insert exponent support for __ieee128
9445         argument with __ieee128 result.
9446         (VSTDCQP): Add scalar test data class support for __ieee128
9447         argument.
9448         (VSTDCNQP): Add overload support for scalar test negative with
9449         __ieee128 argument.
9450         (VSTDCQP): Add overload support for scalar test data class
9451         __ieee128 argument.
9452         * config/rs6000/vsx.md (UNSPEC_VSX_SXSIG) Replace
9453         UNSPEC_VSX_SXSIGDP.
9454         (UNSPEC_VSX_SIEXPQP): New constant.
9455         (xsxexpqp): New insn for VSX scalar extract exponent quad
9456         precision.
9457         (xsxsigqp): New insn for VSX scalar extract significand quad
9458         precision.
9459         (xsiexpqpf): New insn for VSX scalar insert exponent quad
9460         precision with floating point argument.
9461         (xststdcqp): New expand for VSX scalar test data class quad
9462         precision.
9463         (xststdcnegqp): New expand for VSX scalar test negative quad
9464         precision.
9465         (xststdcqp): New insn to match expansions for VSX scalar test data
9466         class quad precision and VSX scalar test negative quad precision.
9467         * config/rs6000/rs6000.c (rs6000_expand_binop_builtin): Add
9468         special case operand checking to enforce that second operand of
9469         VSX scalar test data class with quad precision argument is a 7-bit
9470         unsigned literal.
9471         * doc/extend.texi (PowerPC AltiVec Built-in Functions): Add
9472         prototypes and descriptions of __ieee128 versions of
9473         scalar_extract_exp, scalar_extract_sig, scalar_insert_exp,
9474         scalar_test_data_class, and scalar_test_neg built-in functions.
9476 2016-07-14  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
9478         PR tree-optimization/81162
9479         * gimple-ssa-strength-reduction.c (replace_mult_candidate): Don't
9480         replace a negate with an add.
9482 2017-07-14  James Greenhalgh  <james.greenhalgh@arm.com>
9484         * doc/invoke.texi (arm/-mcpu): Document +crypto.
9486 2017-07-14  Thomas Preud'homme  <thomas.preudhomme@arm.com>
9488         * config/arm/arm-c.c (arm_cpu_builtins): Define
9489         __ARM_FEATURE_NUMERIC_MAXMIN solely based on TARGET_VFP5.
9491 2017-07-14  Thomas Preud'homme  <thomas.preudhomme@arm.com>
9493         * config/arm/arm-cpus.in (cortex-r52): Add new entry.
9494         (armv8-r): Set ARM Cortex-R52 as default CPU.
9495         * config/arm/arm-tables.opt: Regenerate.
9496         * config/arm/arm-tune.md: Regenerate.
9497         * config/arm/driver-arm.c (arm_cpu_table): Add entry for ARM
9498         Cortex-R52.
9499         * doc/invoke.texi: Mention -mtune=cortex-r52 and availability of fp.dp
9500         extension for -mcpu=cortex-r52.
9502 2017-07-14  Thomas Preud'homme  <thomas.preudhomme@arm.com>
9504         * config/arm/arm-isa.h (isa_bit_FP_ARMv8): Delete enumerator.
9505         (ISA_FP_ARMv8): Define as ISA_FPv5 and ISA_FP_D32.
9506         * config/arm/arm-cpus.in (armv8-r): Define fp.sp as enabling FPv5.
9507         (fp-armv8): Define it as FP_ARMv8 only.
9508         config/arm/arm.h (TARGET_FPU_ARMV8): Delete.
9509         (TARGET_VFP_FP16INST): Define using TARGET_VFP5 rather than
9510         TARGET_FPU_ARMV8.
9511         config/arm/arm.c (arm_rtx_costs_internal): Replace checks against
9512         TARGET_FPU_ARMV8 by checks against TARGET_VFP5.
9513         * config/arm/arm-builtins.c (arm_builtin_vectorized_function): Define
9514         first ARM_CHECK_BUILTIN_MODE definition using TARGET_VFP5 rather
9515         than TARGET_FPU_ARMV8.
9516         * config/arm/arm-c.c (arm_cpu_builtins): Likewise for
9517         __ARM_FEATURE_NUMERIC_MAXMIN macro definition.
9518         * config/arm/arm.md (cmov<mode>): Condition on TARGET_VFP5 rather than
9519         TARGET_FPU_ARMV8.
9520         * config/arm/neon.md (neon_vrint): Likewise.
9521         (neon_vcvt): Likewise.
9522         (neon_<fmaxmin_op><mode>): Likewise.
9523         (<fmaxmin><mode>3): Likewise.
9524         * config/arm/vfp.md (l<vrint_pattern><su_optab><mode>si2): Likewise.
9525         * config/arm/predicates.md (arm_cond_move_operator): Check against
9526         TARGET_VFP5 rather than TARGET_FPU_ARMV8 and fix spacing.
9528 2017-07-14  Jackson Woodruff  <jackson.woodruff@arm.com>
9530         * config/aarch64/aarch64.c (aarch64_print_operand): Move comments
9531         to top of function.
9533 2017-07-14  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
9535         * gimple-ssa-store-merging.c (clear_bit_region): Replace reference to
9536         loop in comment with memset.
9538 2017-07-14  Martin Liska  <mliska@suse.cz>
9540         * cfgexpand.c (expand_gimple_basic_block): Remove dead comment.
9541         * dwarf2out.c (is_java): Remove the function.
9542         (output_pubname): Remove usage of the function.
9543         (lower_bound_default): Remove usage of DW_LANG_Java.
9544         (gen_compile_unit_die): Likewise.
9545         * gcc.c: Remove compiler defaults for .java and .zip files.
9546         * gimple-expr.c (remove_suffix): Change as there's no longer
9547         extension than 4-letter one.
9548         * gimplify.c (mostly_copy_tree_r): Remove Java-special part.
9549         (gimplify_save_expr): Likewise.
9550         * ipa-utils.h (polymorphic_type_binfo_p): Remove the comment
9551         as it's possible even for other languages than Java.
9552         * langhooks.h (struct lang_hooks): Remove Java from a comment.
9553         * lto-opts.c (lto_write_options): Remove reference to Java.
9554         * opts.c (strip_off_ending): Update file extension handling.
9555         * tree-cfg.c (verify_gimple_call): Remove comment with Java.
9556         * tree-eh.c (lower_resx): Likewise.
9557         * tree.c (free_lang_data_in_type): Remove dead code.
9558         (find_decls_types_r): Likewise.
9559         (build_common_builtin_nodes): Remove Java from a comment.
9560         (verify_type): Remove dead code.
9561         * varasm.c (assemble_external): Remove Java from a comment.
9563 2017-07-14  Martin Liska  <mliska@suse.cz>
9565         * opts.c (finish_options): Add quotes.
9566         (common_handle_option): Likewise.
9568 2017-07-14  Martin Liska  <mliska@suse.cz>
9570         * dbxout.c (get_lang_number): Do not handle GNU Pascal.
9571         * dbxout.h (extern void dbxout_stab_value_internal_label_diff):
9572         Remove N_SO_PASCAL.
9573         * dwarf2out.c (lower_bound_default): Do not handle
9574         DW_LANG_Pascal83.
9575         (gen_compile_unit_die): Likewise.
9576         * gcc.c: Remove default extension binding for GNU Pascal.
9577         * stmt.c: Remove Pascal language from a comment.
9578         * xcoffout.c: Likewise.
9580 2017-07-13  David Malcolm  <dmalcolm@redhat.com>
9582         PR c/81405
9583         * diagnostic-show-locus.c (fixit_cmp): New function.
9584         (layout::layout): Sort m_fixit_hints.
9585         (column_range::column_range): Assert that the values are valid.
9586         (struct char_span): New struct.
9587         (correction::overwrite): New method.
9588         (struct source_line): New struct.
9589         (line_corrections::add_hint): Add assertions.  Reimplement memcpy
9590         calls in terms of classes source_line and char_span, and
9591         correction::overwrite.
9592         (selftest::test_overlapped_fixit_printing_2): New function.
9593         (selftest::diagnostic_show_locus_c_tests): Call it.
9595 2017-07-13  Will Schmidt  <will_schmidt@vnet.ibm.com>
9597         * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Return
9598         early if there is no lhs.
9600 2017-07-13  Martin Liska  <mliska@suse.cz>
9602         * dwarf2out.c (gen_pointer_type_die): Remove dead code.
9603         (gen_reference_type_die): Likewise.
9604         * stor-layout.c: Remove Pascal-related comment.
9606 2017-07-13  Martin Liska  <mliska@suse.cz>
9608         * opts.c (finish_options): Add quotes to error messages.
9609         (parse_sanitizer_options): Likewise.
9611 2017-07-13  Thomas Preud'homme  <thomas.preudhomme@arm.com>
9613         * doc/invoke.texi (armv8-r): Document +fp.sp ARMv8-R extension.
9615 2017-07-13  Richard Earnshaw  <rearnsha@arm.com>
9617         * config/arm/vxworks.h (TARGET_ENDIAN_DEFAULT): Define.
9619 2017-07-13  Maxim Ostapenko  <m.ostapenko@samsung.com>
9621         * asan.c (asan_emit_allocas_unpoison): Use ptr_mode for arguments
9622         during expansion.
9623         * builtins.c (expand_asan_emit_allocas_unpoison): Likewise.
9625 2017-07-12  Michael Meissner  <meissner@linux.vnet.ibm.com>
9627         PR target/81193
9628         * config/rs6000/rs6000-c.c (rs6000_cpu_cpp_builtins): If GLIBC
9629         provides the hardware capability bits, define the macro
9630         __BUILTIN_CPU_SUPPORTS__.
9631         * config/rs6000/rs6000.c (cpu_expand_builtin): Generate a warning
9632         if GLIBC does not provide the hardware capability bits.  Add a
9633         gcc_unreachable call if the built-in cpu function is neither
9634         __builtin_cpu_is nor __builtin_cpu_supports.
9635         (rs6000_get_function_versions_dispatcher): Change the warning
9636         that an old GLIBC is used which does not export the capability
9637         bits to be an error.
9638         * doc/extend.texi (target_clones attribute): Document the
9639         restriction that GLIBC 2.23 or newer is needed on the PowerPC.
9640         (PowerPC built-in functions): Document that GLIBC 2.23 or newer is
9641         needed by __builtin_cpu_is and __builtin_cpu_supports.  Document
9642         the macros defined by GCC if the newer GLIBC is available.
9644 2017-07-12  Jeff Law  <law@redhat.com>
9646         * config/riscv/riscv.c: Remove unnecessary includes.  Reorder
9647         remaining includes slightly.
9648         * config/riscv/riscv-builtins.c: Include profile-count.h.
9650 2017-07-12  Georg-Johann Lay  <avr@gjlay.de>
9652         PR target/79883
9653         * config/avr/avr.c (avr_set_current_function): In diagnostic
9654         messages: Quote keywords and (parts of) identifiers.
9655         [WITH_AVRLIBC]: Warn for functions named "ISR", "SIGNAL" or
9656         "INTERUPT".
9658 2017-07-12  Carl Love  <cel@us.ibm.com>
9660         * config/rs6000/rs6000-c.c: Add support for built-in functions
9661         vector bool char vec_revb (vector bool char);
9662         vector bool short vec_revb (vector short char);
9663         vector bool int vec_revb (vector bool int);
9664         vector bool long long vec_revb (vector bool long long);
9665         * doc/extend.texi: Update the built-in documentation file for the
9666         new built-in functions.
9668 2017-07-12  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
9670         * config/s390/s390.md: Remove movcc splitter.
9672 2017-07-12  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
9674         * config/s390/s390.c (s390_rtx_costs): Return proper costs for
9675         load/store on condition.
9677 2017-07-12  Georg-Johann Lay  <avr@gjlay.de>
9679         PR target/81407
9680         * config/avr/avr.c (avr_encode_section_info)
9681         [progmem && !TREE_READONLY]: Error if progmem object needs
9682         constructing.
9684 2017-07-11  Michael Collison  <michael.collison@arm.com>
9686         * config/aarch64/aarch64-simd.md (aarch64_sub<mode>_compare0):
9687         New pattern.
9689 2017-07-11  Carl Love  <cel@us.ibm.com>
9691         * config/rs6000/rs6000-c.c: Add support for builtins
9692         vector unsigned int vec_parity_lsbb (vector signed int);
9693         vector unsigned int vec_parity_lsbb (vector unsigned int);
9694         vector unsigned __int128 vec_parity_lsbb (vector signed __int128);
9695         vector unsigned __int128 vec_parity_lsbb (vector unsigned __int128);
9696         vector unsigned long long vec_parity_lsbb (vector signed long long);
9697         vector unsigned long long vec_parity_lsbb (vector unsigned long long);
9698         * config/rs6000/rs6000-builtin.def (VPARITY_LSBB): Add BU_P9V_OVERLOAD1.
9699         * config/rs6000/altivec.h (vec_parity_lsbb): Add define.
9700         * doc/extend.texi: Update the built-in documentation file for the
9701         new built-in functions.
9703 2017-07-11  David Malcolm  <dmalcolm@redhat.com>
9705         * diagnostic-show-locus.c: Include "gcc-rich-location.h".
9706         (layout::m_primary_loc): New field.
9707         (layout::layout): Initialize new field.  Move location filtering
9708         logic from here to...
9709         (layout::maybe_add_location_range): ...this new method.  Add
9710         support for filtering to just the lines already specified by other
9711         locations.
9712         (layout::will_show_line_p): New method.
9713         (gcc_rich_location::add_location_if_nearby): New method.
9714         (selftest::test_add_location_if_nearby): New test function.
9715         (selftest::diagnostic_show_locus_c_tests): Call it.
9716         * gcc-rich-location.h (gcc_rich_location::add_location_if_nearby):
9717         New method.
9719 2017-07-11  Tom de Vries  <tom@codesourcery.com>
9721         * config/nvptx/nvptx.c (WORKAROUND_PTXJIT_BUG): New macro.
9722         (bb_first_real_insn): New function.
9723         (nvptx_single): Add extra initialization of broadcasted condition
9724         variables.
9726 2017-07-11  Nathan Sidwell  <nathan@acm.org>
9728         * dwarf2out.c (gen_member_die): Remove useless check for anon ctors.
9730 2017-07-11  Georg-Johann Lay  <avr@gjlay.de>
9732         * doc/extend.texi (AVR Function Attributes): Remove weblink to
9733         Binutils doc as TEXI will mess them up.
9734         * doc/invoke.texi (AVR Options): Same here.
9736 2017-07-11  Daniel Cederman  <cederman@gaisler.com>
9738         * config/sparc/sparc.opt (mfix-ut700): New option.
9739         (mfix-gr712rc): Likewise.
9740         (sparc_fix_b2bst): New variable.
9741         * doc/invoke.texi (SPARC options): Document them.
9742         (ARM options): Fix warnings.
9743         * config/sparc/sparc.c (sparc_do_work_around_errata): Insert NOP
9744         instructions to prevent sequences that can trigger the store-store
9745         errata for certain LEON3FT processors.
9746         (pass_work_around_errata::gate): Also test sparc_fix_b2bst.
9747         (sparc_option_override): Set sparc_fix_b2bst appropriately.
9748         * config/sparc/sparc.md (fix_b2bst): New attribute.
9749         (in_branch_delay): Prevent stores in delay slot if fix_b2bst.
9751 2017-07-10  Uros Bizjak  <ubizjak@gmail.com>
9753         PR target/81375
9754         * config/i386/i386.md (divsf3): Add TARGET_SSE to TARGET_SSE_MATH.
9755         (rcpps): Ditto.
9756         (*rsqrtsf2_sse): Ditto.
9757         (rsqrtsf2): Ditto.
9758         (div<mode>3): Macroize insn from divdf3 and divsf3
9759         using MODEF mode iterator.
9761 2017-07-10  Martin Sebor  <msebor@redhat.com>
9763         PR tree-optimization/80397
9764         * gimple-ssa-sprintf.c (format_integer): Use INTEGRAL_TYPE_P()
9765         instead of testing for equality to INTEGER_TYPE.
9767 2017-07-10  Vineet Gupta <vgupta@synopsys.com>
9769         * config.gcc: Remove uclibc from arc target spec.
9771 2017-07-10  Claudiu Zissulescu  <claziss@synopsys.com>
9773         * config/arc/arc.h (ADDITIONAL_REGISTER_NAMES): Define.
9775 2017-07-07  Jan Hubicka  <hubicka@ucw.cz>
9777         PR lto/80838
9778         * lto-wrapper.c (remove_option): New function.
9779         (merge_and_complain): Merge PIC/PIE options more realistically.
9781 2017-07-10  Georg-Johann Lay  <avr@gjlay.de>
9783         Better ISR prologues by supporting GASes __gcc_isr pseudo insn.
9785         PR target/20296
9786         PR target/81268
9787         * configure.ac [target=avr]: Add GAS check for -mgcc-isr.
9788         (HAVE_AS_AVR_MGCCISR_OPTION):  If so, AC_DEFINE it.
9789         * config.in: Regenerate.
9790         * configure: Regenerate.
9791         * doc/extend.texi (AVR Function Attributes) <no_gccisr>: Document it.
9792         * doc/invoke.texi (AVR Options) <-mgas-isr-prologues>: Document it.
9793         * config/avr/avr.opt (-mgas-isr-prologues): New option and...
9794         (TARGET_GASISR_PROLOGUES): ...target mask.
9795         * common/config/avr/avr-common.c
9796         (avr_option_optimization_table) [OPT_LEVELS_1_PLUS_NOT_DEBUG]:
9797         Set -mgas-isr-prologues.
9798         * config/avr/avr-passes.def (avr_pass_pre_proep): Add
9799         INSERT_PASS_BEFORE for it.
9800         * config/avr/avr-protos.h (make_avr_pass_pre_proep): New proto.
9801         * config/avr/avr.c (avr_option_override)
9802         [!HAVE_AS_AVR_MGCCISR_OPTION]: Unset TARGET_GASISR_PROLOGUES.
9803         (avr_no_gccisr_function_p, avr_hregs_split_reg): New static functions.
9804         (avr_attribute_table) <no_gccisr>: Add new function attribute.
9805         (avr_set_current_function) <is_no_gccisr>: Init machine field.
9806         (avr_pass_data_pre_proep, avr_pass_pre_proep): New pass data
9807         and rtl_opt_pass.
9808         (make_avr_pass_pre_proep): New function.
9809         (emit_push_sfr) <treg>: Add argument to function and use it
9810         instead of TMP_REG.
9811         (avr_expand_prologue) [machine->gasisr.maybe]: Emit gasisr insn
9812         and set machine->gasisr.yes.
9813         (avr_expand_epilogue) [machine->gasisr.yes]: Similar.
9814         (avr_asm_function_end_prologue) [machine->gasisr.yes]: Add
9815         __gcc_isr.n_pushed to .L__stack_usage.
9816         (TARGET_ASM_FINAL_POSTSCAN_INSN): Define to...
9817         (avr_asm_final_postscan_insn): ...this new static function.
9818         * config/avr/avr.h (machine_function)
9819         <is_no_gccisr, use_L__stack_usage>: New fields.
9820         <gasisr, gasisr.yes, gasisr.maybe, gasisr.regno>: New fields.
9821         * config/avr/avr.md (UNSPECV_GASISR): Add unspecv enum.
9822         (GASISR_Prologue, GASISR_Epilogue, GASISR_Done): New define_constants.
9823         (gasisr, *gasisr): New expander and insn.
9824         * config/avr/gen-avr-mmcu-specs.c (print_mcu)
9825         [HAVE_AS_AVR_MGCCISR_OPTION]: Print asm_gccisr spec.
9826         * config/avr/specs.h (ASM_SPEC) <asm_gccisr>: Add sub spec.
9828 2017-07-10  Richard Earnshaw  <rearnsha@arm.com>
9830         * config/arm/parsecpu.awk (gen_comm_data): Do not escape single quotes
9831         in quoted strings.
9833 2017-07-10  Georg-Johann Lay  <avr@gjlay.de>
9835         Move jump-tables out of .text again.
9837         PR target/81075
9838         * config/avr/avr.c (ASM_OUTPUT_ADDR_VEC_ELT): Remove function.
9839         (ASM_OUTPUT_ADDR_VEC): New function.
9840         (avr_adjust_insn_length) [JUMP_TABLE_DATA_P]: Return 0.
9841         (avr_final_prescan_insn) [avr_log.insn_addresses]: Dump
9842         INSN_ADDRESSes as asm comment.
9843         * config/avr/avr.h (JUMP_TABLES_IN_TEXT_SECTION): Adjust comment.
9844         (ASM_OUTPUT_ADDR_VEC_ELT): Remove define.
9845         (ASM_OUTPUT_ADDR_VEC): Define to avr_output_addr_vec.
9846         * config/avr/avr.md (*tablejump): Adjust comment.
9847         * config/avr/elf.h (ASM_OUTPUT_BEFORE_CASE_LABEL): Remove.
9848         * config/avr/avr-log.c (avr_log_set_avr_log) <insn_addresses>:
9849         New detail.
9850         * config/avr/avr-protos.h (avr_output_addr_vec_elt): Remove proto.
9851         (avr_output_addr_vec): New proto.
9852         (avr_log_t) <insn_addresses>: New field.
9854 2017-07-09  H.J. Lu  <hongjiu.lu@intel.com>
9856         PR target/81313
9857         * config/i386/i386.c (ix86_function_arg_advance): Set
9858         outgoing_args_on_stack to true if there are outgoing arguments
9859         on stack.
9860         (ix86_function_arg): Likewise.
9861         (ix86_get_drap_rtx): Use DRAP only if there are outgoing
9862         arguments on stack and ACCUMULATE_OUTGOING_ARGS is false.
9863         * config/i386/i386.h (machine_function): Add
9864         outgoing_args_on_stack.
9866 2017-07-09  Krister Walfridsson  <krister.walfridsson@gmail.com>
9868         * config.gcc (*-*-netbsd*): Remove check for NetBSD versions not
9869         supporting pthreds.
9870         * config/netbsd.h (NETBSD_LIBGCC_SPEC): Always enable pthreads.
9872 2017-07-08  Richard Sandiford  <richard.sandiford@linaro.org>
9874         * Makefile.in (HOOKS_H, RTL_BASE_H, FUNCTION_H, EXPR_H, REGS_H)
9875         (REAL_H): Remove $(MACHMODE_H).
9876         (FIXED_VALUE_H, TREE_CORE_H, CFGLOOP_H): Remove $(MACHMODE_H) and
9877         double-int.h.
9878         (CORETYPES_H): Add signop.h, wide-int.h, wide-int-print.h,
9879         $(MACHMODE_H) and double-int.h.
9880         (build/min-insn-modes.o): Depend on $(CORETYPES_H) rather than
9881         $(MACHMODE_H).
9882         (gengtype-state.o, gengtype.o, build/gengtype.o): Don't depend on
9883         double-int.h.
9885 2017-07-07  Andrew Pinski  <apinski@cavium.com>
9887         * config/aarch64/aarch64.c (aarch_macro_fusion_pair_p): Check
9888         prev_set and curr_set for AARCH64_FUSE_ALU_BRANCH.
9890 2017-07-07  Michael Meissner  <meissner@linux.vnet.ibm.com>
9892         * config/rs6000/rs6000.c (rs6000_get_function_versions_dispatcher):
9893         Add warning if GCC was not configured to link against a GLIBC that
9894         exports the hardware capability bits.
9895         (make_resolver_func): Make resolver function private and not a
9896         COMDAT function.  Create the name with clone_function_name instead
9897         of make_unique_name.
9899         PR target/81348
9900         * config/rs6000/rs6000.md (HI sign_extend splitter): Use the
9901         correct operand in doing the split.
9903 2017-07-07 Carl Love  <cel@us.ibm.com>
9905         * config/rs6000/rs6000-c: Add support for built-in function
9906         vector unsigned short vec_pack_to_short_fp32 (vector float,
9907                                                       vector float).
9908         * config/rs6000/rs6000-builtin.def (CONVERT_4F32_8I16): Add
9909         BU_P9V_AV_2 and BU_P9V_OVERLOAD_2 definitions.
9910         * config/rs6000/altivec.h (vec_pack_to_short_fp32): Add define.
9911         * config/rs6000/altivec.md(UNSPEC_CONVERT_4F32_8I16): Add UNSPEC.
9912         (convert_4f32_8i16): Add define_expand.
9913         * doc/extend.texi: Update the built-in documentation file for the
9914         new built-in function.
9916 2017-07-07  Jose E. Marchesi  <jose.marchesi@oracle.com>
9918         * config/sparc/m8.md: New file.
9919         * config/sparc/sparc.md: Include m8.md.
9921 2017-07-07  Jose E. Marchesi  <jose.marchesi@oracle.com>
9923         * config/sparc/sparc.opt: New option -mvis4b.
9924         * config/sparc/sparc.c (dump_target_flag_bits): Handle MASK_VIS4B.
9925         (sparc_option_override): Handle VIS4B.
9926         (enum sparc_builtins): Define
9927         SPARC_BUILTIN_DICTUNPACK{8,16,32},
9928         SPARC_BUILTIN_FPCMP{LE,GT,EQ,NE}{8,16,32}SHL,
9929         SPARC_BUILTIN_FPCMPU{LE,GT}{8,16,32}SHL,
9930         SPARC_BUILTIN_FPCMPDE{8,16,32}SHL and
9931         SPARC_BUILTIN_FPCMPUR{8,16,32}SHL.
9932         (check_constant_argument): New function.
9933         (sparc_vis_init_builtins): Define builtins
9934         __builtin_vis_dictunpack{8,16,32},
9935         __builtin_vis_fpcmp{le,gt,eq,ne}{8,16,32}shl,
9936         __builtin_vis_fpcmpu{le,gt}{8,16,32}shl,
9937         __builtin_vis_fpcmpde{8,16,32}shl and
9938         __builtin_vis_fpcmpur{8,16,32}shl.
9939         (sparc_expand_builtin): Check that the constant operands to
9940         __builtin_vis_fpcmp*shl and _builtin_vis_dictunpack* are indeed
9941         constant and in range.
9942         * config/sparc/sparc-c.c (sparc_target_macros): Handle
9943         TARGET_VIS4B.
9944         * config/sparc/sparc.h (SPARC_IMM2_P): Define.
9945         (SPARC_IMM5_P): Likewise.
9946         * config/sparc/sparc.md (cpu_feature): Add new feagure "vis4b".
9947         (enabled): Handle vis4b.
9948         (UNSPEC_DICTUNPACK): New unspec.
9949         (UNSPEC_FPCMPSHL): Likewise.
9950         (UNSPEC_FPUCMPSHL): Likewise.
9951         (UNSPEC_FPCMPDESHL): Likewise.
9952         (UNSPEC_FPCMPURSHL): Likewise.
9953         (cpu_feature): New CPU feature `vis4b'.
9954         (dictunpack{8,16,32}): New insns.
9955         (FPCSMODE): New mode iterator.
9956         (fpcscond): New code iterator.
9957         (fpcsucond): Likewise.
9958         (fpcmp{le,gt,eq,ne}{8,16,32}{si,di}shl): New insns.
9959         (fpcmpu{le,gt}{8,16,32}{si,di}shl): Likewise.
9960         (fpcmpde{8,16,32}{si,di}shl): Likewise.
9961         (fpcmpur{8,16,32}{si,di}shl): Likewise.
9962         * config/sparc/constraints.md: Define constraints `q' for unsigned
9963         2-bit integer constants and `t' for unsigned 5-bit integer
9964         constants.
9965         * config/sparc/predicates.md (imm5_operand_dictunpack8): New
9966         predicate.
9967         (imm5_operand_dictunpack16): Likewise.
9968         (imm5_operand_dictunpack32): Likewise.
9969         (imm2_operand): Likewise.
9970         * doc/invoke.texi (SPARC Options): Document -mvis4b.
9971         * doc/extend.texi (SPARC VIS Built-in Functions): Document the
9972         ditunpack* and fpcmp*shl builtins.
9974 2017-07-07  Jose E. Marchesi  <jose.marchesi@oracle.com>
9976         * config.gcc: Handle m8 in --with-{cpu,tune} options.
9977         * config.in: Add HAVE_AS_SPARC6 define.
9978         * config/sparc/driver-sparc.c (cpu_names): Add entry for the SPARC
9979         M8.
9980         * config/sparc/sol2.h (CPP_CPU64_DEFAULT_SPEC): Define for
9981         TARGET_CPU_m8.
9982         (ASM_CPU32_DEFAUILT_SPEC): Likewise.
9983         (CPP_CPU_SPEC): Handle m8.
9984         (ASM_CPU_SPEC): Likewise.
9985         * config/sparc/sparc-opts.h (enum processor_type): Add
9986         PROCESSOR_M8.
9987         * config/sparc/sparc.c (m8_costs): New struct.
9988         (sparc_option_override): Handle TARGET_CPU_m8.
9989         (sparc32_initialize_trampoline): Likewise.
9990         (sparc64_initialize_trampoline): Likewise.
9991         (sparc_issue_rate): Likewise.
9992         (sparc_register_move_cost): Likewise.
9993         * config/sparc/sparc.h (TARGET_CPU_m8): Define.
9994         (CPP_CPU64_DEFAULT_SPEC): Define for M8.
9995         (ASM_CPU64_DEFAULT_SPEC): Likewise.
9996         (CPP_CPU_SPEC): Handle M8.
9997         (ASM_CPU_SPEC): Likewise.
9998         (AS_M8_FLAG): Define.
9999         * config/sparc/sparc.md: Add m8 to the cpu attribute.
10000         * config/sparc/sparc.opt: New option -mcpu=m8 for sparc targets.
10001         * configure.ac (HAVE_AS_SPARC6): Check for assembler support for
10002         M8 instructions.
10003         * configure: Regenerate.
10004         * doc/invoke.texi (SPARC Options): Document -mcpu=m8 and
10005         -mtune=m8.
10007 2017-07-07  Jose E. Marchesi  <jose.marchesi@oracle.com>
10009         * config/sparc/niagara7.md: Rework the DFA scheduler to use insn
10010         subtypes.
10011         * config/sparc/sparc.md: Remove the `v3pipe' insn attribute.
10012         ("*movdi_insn_sp32"): Do not set v3pipe.
10013         ("*movsi_insn"): Likewise.
10014         ("*movdi_insn_sp64"): Likewise.
10015         ("*movsf_insn"): Likewise.
10016         ("*movdf_insn_sp32"): Likewise.
10017         ("*movdf_insn_sp64"): Likewise.
10018         ("*zero_extendsidi2_insn_sp64"): Likewise.
10019         ("*sign_extendsidi2_insn"): Likewise.
10020         ("*mov<VM32:mode>_insn"): Likewise.
10021         ("*mov<VM64:mode>_insn_sp64"): Likewise.
10022         ("*mov<VM64:mode>_insn_sp32"): Likewise.
10023         ("<plusminus_insn><VADDSUB:mode>3"): Likewise.
10024         ("<vlop:code><VL:mode>3"): Likewise.
10025         ("*not_<vlop:code><VL:mode>3"): Likewise.
10026         ("*nand<VL:mode>_vis"): Likewise.
10027         ("*<vlnotop:code>_not1<VL:mode>_vis"): Likewise.
10028         ("*<vlnotop:code>_not2<VL:mode>_vis"): Likewise.
10029         ("one_cmpl<VL:mode>2"): Likewise.
10030         ("faligndata<VM64:mode>_vis"): Likewise.
10031         ("alignaddrsi_vis"): Likewise.
10032         ("alignaddrdi_vis"): Likweise.
10033         ("alignaddrlsi_vis"): Likewise.
10034         ("alignaddrldi_vis"): Likewise.
10035         ("fcmp<gcond:code><GCM:gcm_name><P:mode>_vis"): Likewise.
10036         ("bmaskdi_vis"): Likewise.
10037         ("bmasksi_vis"): Likewise.
10038         ("bshuffle<VM64:mode>_vis"): Likewise.
10039         ("cmask8<P:mode>_vis"): Likewise.
10040         ("cmask16<P:mode>_vis"): Likewise.
10041         ("cmask32<P:mode>_vis"): Likewise.
10042         ("pdistn<P:mode>_vis"): Likewise.
10043         ("<vis3_addsub_ss_patname><VASS:mode>3"): Likewise.
10045 2017-07-07  Jose E. Marchesi  <jose.marchesi@oracle.com>
10047         * config/sparc/sparc.md ("subtype"): New insn attribute.
10048         ("*wrgsr_sp64"): Set insn subtype.
10049         ("*rdgsr_sp64"): Likewise.
10050         ("alignaddrsi_vis"): Likewise.
10051         ("alignaddrdi_vis"): Likewise.
10052         ("alignaddrlsi_vis"): Likewise.
10053         ("alignaddrldi_vis"): Likewise.
10054         ("<plusminus_insn><VADDSUB:mode>3"): Likewise.
10055         ("fexpand_vis"): Likewise.
10056         ("fpmerge_vis"): Likewise.
10057         ("faligndata<VM64:mode>_vis"): Likewise.
10058         ("bshuffle<VM64:mode>_vis"): Likewise.
10059         ("cmask8<P:mode>_vis"): Likewise.
10060         ("cmask16<P:mode>_vis"): Likewise.
10061         ("cmask32<P:mode>_vis"): Likewise.
10062         ("fchksm16_vis"): Likewise.
10063         ("v<vis3_shift_patname><GCM:mode>3"): Likewise.
10064         ("fmean16_vis"): Likewise.
10065         ("fp<plusminus_insn>64_vis"): Likewise.
10066         ("<plusminus_insn>v8qi3"): Likewise.
10067         ("<vis3_addsub_ss_patname><VASS:mode>3"): Likewise.
10068         ("<vis4_minmax_patname><VMMAX:mode>3"): Likewise.
10069         ("<vis4_uminmax_patname><VMMAX:mode>3"): Likewise.
10070         ("<vis3_addsub_ss_patname>v8qi3"): Likewise.
10071         ("<vis4_addsub_us_patname><VAUS:mode>3"): Likewise.
10072         ("*movqi_insn"): Likewise.
10073         ("*movhi_insn"): Likewise.
10074         ("*movsi_insn"): Likewise.
10075         ("movsi_pic_gotdata_op"): Likewise.
10076         ("*movdi_insn_sp32"): Likewise.
10077         ("*movdi_insn_sp64"): Likewise.
10078         ("movdi_pic_gotdata_op"): Likewise.
10079         ("*movsf_insn"): Likewise.
10080         ("*movdf_insn_sp32"): Likewise.
10081         ("*movdf_insn_sp64"): Likewise.
10082         ("*zero_extendhisi2_insn"): Likewise.
10083         ("*zero_extendqihi2_insn"): Likewise.
10084         ("*zero_extendqisi2_insn"): Likewise.
10085         ("*zero_extendqidi2_insn"): Likewise.
10086         ("*zero_extendhidi2_insn"): Likewise.
10087         ("*zero_extendsidi2_insn_sp64"): Likewise.
10088         ("ldfsr"): Likewise.
10089         ("prefetch_64"): Likewise.
10090         ("prefetch_32"): Likewise.
10091         ("tie_ld32"): Likewise.
10092         ("tie_ld64"): Likewise.
10093         ("*tldo_ldub_sp32"): Likewise.
10094         ("*tldo_ldub1_sp32"): Likewise.
10095         ("*tldo_ldub2_sp32"): Likewise.
10096         ("*tldo_ldub_sp64"): Likewise.
10097         ("*tldo_ldub1_sp64"): Likewise.
10098         ("*tldo_ldub2_sp64"): Likewise.
10099         ("*tldo_ldub3_sp64"): Likewise.
10100         ("*tldo_lduh_sp32"): Likewise.
10101         ("*tldo_lduh1_sp32"): Likewise.
10102         ("*tldo_lduh_sp64"): Likewise.
10103         ("*tldo_lduh1_sp64"): Likewise.
10104         ("*tldo_lduh2_sp64"): Likewise.
10105         ("*tldo_lduw_sp32"): Likewise.
10106         ("*tldo_lduw_sp64"): Likewise.
10107         ("*tldo_lduw1_sp64"): Likewise.
10108         ("*tldo_ldx_sp64"): Likewise.
10109         ("*mov<VM32:mode>_insn"): Likewise.
10110         ("*mov<VM64:mode>_insn_sp64"): Likewise.
10111         ("*mov<VM64:mode>_insn_sp32"): Likewise.
10113 2017-07-07  Jose E. Marchesi  <jose.marchesi@oracle.com>
10115         * config/sparc/sparc.md ("type"): New insn type viscmp.
10116         ("fcmp<gcond:code><GCM:gcm_name><P:mode>_vis"): Set insn type to
10117         viscmp.
10118         ("fpcmp<gcond:code>8<P:mode>_vis"): Likewise.
10119         ("fucmp<gcond:code>8<P:mode>_vis"): Likewise.
10120         ("fpcmpu<gcond:code><GCM:gcm_name><P:mode>_vis"): Likewise.
10121         * config/sparc/niagara7.md ("n7_vis_logical_v3pipe"): Handle
10122         viscmp.
10123         ("n7_vis_logical_11cycle"): Likewise.
10124         * config/sparc/niagara4.md ("n4_vis_logical"): Likewise.
10125         * config/sparc/niagara2.md ("niag3_vis": Likewise.
10126         * config/sparc/niagara.md ("niag_vis"): Likewise.
10127         * config/sparc/ultra3.md ("us3_fga"): Likewise.
10128         * config/sparc/ultra1_2.md ("us1_fga_double"): Likewise.
10130 2017-07-07  Jose E. Marchesi  <jose.marchesi@oracle.com>
10132         * config/sparc/sparc.md: New instruction type `bmask'.
10133         (bmaskdi_vis): Use the `bmask' type.
10134         (bmasksi_vis): Likewise.
10135         * config/sparc/ultra3.md (us3_array): Likewise.
10136         * config/sparc/niagara7.md (n7_array): Likewise.
10137         * config/sparc/niagara4.md (n4_array): Likewise.
10138         * config/sparc/niagara2.md (niag2_vis): Likewise.
10139         (niag3_vis): Likewise.
10140         * config/sparc/niagara.md (niag_vis): Likewise.
10142 2017-07-06  Jan Hubicka  <hubicka@ucw.cz>
10144         * ipa-comdats.c: Remove optimize check from gate.
10145         * ipa-fnsummary.c (ipa_fn_summary_generate): do not generate summary
10146         for functions not optimized.
10147         (ipa_fn_summary_read): Skip optimize check.
10148         (ipa_fn_summary_write): Likewise.
10149         * ipa-inline-analysis.c (do_estimate_growth_1): Check that caller
10150         is optimized.
10151         * ipa-inline.c (can_inline_edge_p): Not optimized functions are
10152         uninlinable.
10153         (can_inline_edge_p): Check flag_pcc_struct_return for match.
10154         (check_callers): Give up on caller which is not optimized.
10155         (inline_small_functions): Likewise.
10156         (ipa_inline): Do not give up when not optimizing.
10157         * ipa-visbility.c (function_and_variable_visibility): Do not optimize
10158         away unoptimizes cdtors.
10159         (whole_program_function_and_variable_visibility): Do
10160         ipa_discover_readonly_nonaddressable_vars in LTO mode.
10161         * ipa.c (process_references): Do not check optimize.
10162         (symbol_table::remove_unreachable_nodes): Update optimize check.
10163         (set_writeonly_bit): Update optimize check.
10164         (pass_ipa_cdtor_merge::gate): Do not check optimize.
10165         (pass_ipa_single_use::gate): Remove.
10167 2017-07-06  Aaron Sawdey  <acsawdey@linux.vnet.ibm.com>
10169         * config/rs6000/rs6000.c (union_defs, union_uses, insn_is_load_p,
10170         insn_is_store_p, insn_is_swap_p, const_load_sequence_p, v2df_reduction_p,
10171         rtx_is_swappable_p, insn_is_swappable_p, chain_contains_only_swaps,
10172         mark_swaps_for_removal, swap_const_vector_halves, adjust_subreg_index,
10173         permute_load, permute_store, adjust_extract, adjust_splat,
10174         adjust_xxpermdi, adjust_concat, adjust_vperm, handle_special_swappables,
10175         replace_swap_with_copy, dump_swap_insn_table,
10176         alignment_with_canonical_addr, alignment_mask, find_alignment_op,
10177         recombine_lvx_pattern, recombine_stvx_pattern,
10178         recombine_lvx_stvx_patterns, rs6000_analyze_swaps,
10179         make_pass_analyze_swaps): Move all code related to p8 swap optimizations
10180         to file rs6000-p8swap.c.
10181         * config/rs6000/rs6000-p8swap.c: New file.
10182         * config/rs6000/t-rs6000: Add rule to build rs6000-p8swap.o.
10183         * config.gcc: Add rs6000-p8swap.o to extra_objs for powerpc*-*-*
10184         and rs6000*-*-* targets.
10186 2017-07-06  David Malcolm  <dmalcolm@redhat.com>
10188         * Makefile.in (selftest): Remove dependency on s-selftest-c++.
10190 2017-07-06  Jan Hubicka  <hubicka@ucw.cz>
10192         * lto-wrapper.c (merge_and_complain): Do not merge
10193         fexceptions, fnon_call_exceptions, ftrapv, ffp_contract_, fmath_errno,
10194         fsigned_zeros, ftrapping_math, fwrapv.
10195         (append_compiler_options): Do not track these options.
10196         (append_linker_options): Likewie
10198 2017-07-06  Jan Hubicka  <hubicka@ucw.cz>
10200         * cgraphunit.c (cgraph_node::finalize_function): When
10201         !flag_toplevel_reorde set no_reorder flag.
10202         (varpool_node::finalize_decl): Likewise.
10203         (symbol_table::compile): Drop no toplevel reorder path.
10205 2017-07-06  Jan Hubicka  <hubicka@ucw.cz>
10207         * bb-reorder.c (better_edge_p): Do not build traces across abnormal/eh
10208         edges; zero probability is not better than uninitialized.
10210 2017-07-06  Maxim Ostapenko  <m.ostapenko@samsung.com>
10212         * asan.h (asan_sanitize_allocas_p): Declare.
10213         * asan.c (asan_sanitize_allocas_p): New function.
10214         (handle_builtin_stack_restore): Bail out if !asan_sanitize_allocas_p.
10215         (handle_builtin_alloca): Likewise.
10216         * cfgexpand.c (expand_used_vars): Do not add allocas unpoisoning stuff
10217         if !asan_sanitize_allocas_p.
10218         * params.def (asan-instrument-allocas): Add new option.
10219         * params.h (ASAN_PROTECT_ALLOCAS): Define.
10220         * opts.c (common_handle_option): Disable allocas sanitization for
10221         KASan by default.
10223 2017-07-06  Maxim Ostapenko  <m.ostapenko@samsung.com>
10225         * asan.c: Include gimple-fold.h.
10226         (get_last_alloca_addr): New function.
10227         (handle_builtin_stackrestore): Likewise.
10228         (handle_builtin_alloca): Likewise.
10229         (asan_emit_allocas_unpoison): Likewise.
10230         (get_mem_refs_of_builtin_call): Add new parameter, remove const
10231         quallifier from first paramerer. Handle BUILT_IN_ALLOCA,
10232         BUILT_IN_ALLOCA_WITH_ALIGN and BUILT_IN_STACK_RESTORE builtins.
10233         (instrument_builtin_call): Pass gimple iterator to
10234         get_mem_refs_of_builtin_call.
10235         (last_alloca_addr): New global.
10236         * asan.h (asan_emit_allocas_unpoison): Declare.
10237         * builtins.c (expand_asan_emit_allocas_unpoison): New function.
10238         (expand_builtin): Handle BUILT_IN_ASAN_ALLOCAS_UNPOISON.
10239         * cfgexpand.c (expand_used_vars): Call asan_emit_allocas_unpoison
10240         if function calls alloca.
10241         * gimple-fold.c (replace_call_with_value): Remove static keyword.
10242         * gimple-fold.h (replace_call_with_value): Declare.
10243         * internal-fn.c: Include asan.h.
10244         * sanitizer.def (BUILT_IN_ASAN_ALLOCA_POISON,
10245         BUILT_IN_ASAN_ALLOCAS_UNPOISON): New builtins.
10247 2017-07-06  David Malcolm  <dmalcolm@redhat.com>
10249         * Makefile.in (SELFTEST_FLAGS): Drop "-x c", moving it to...
10250         (C_SELFTEST_FLAGS): New.
10251         (CPP_SELFTEST_FLAGS): New.
10252         (SELFTEST_DEPS): New, from deps of s-selftest.
10253         (C_SELFTEST_DEPS): New, from deps of s-selftest.
10254         (CPP_SELFTEST_DEPS): New.
10255         (selftest): Add dependency on s-selftest-c++.
10256         (s-selftest): Rename to...
10257         (s-selftest-c): ...this, moving deps to SELFTEST_DEPS
10258         and C_SELFTEST_DEPS, and using C_SELFTEST_FLAGS rather
10259         than SELFTEST_FLAGS.
10260         (selftest-gdb): Rename to...
10261         (selftest-c-gdb): ...this, using C_SELFTEST_DEPS and
10262         C_SELFTEST_FLAGS.
10263         (selftest-gdb): Reintroduce as an alias for selftest-c-gdb.
10264         (selftest-valgrind): Rename to...
10265         (selftest-c-valgrind): ...this, using C_SELFTEST_DEPS and
10266         C_SELFTEST_FLAGS.
10267         (selftest-valgrind): Reintroduce as an alias for
10268         selftest-c-valgrind.
10269         (s-selftest-c++): New.
10270         (selftest-c++-gdb): New.
10271         (selftest-c++-valgrind): New.
10273 2017-07-06  Olivier Hainque  <hainque@adacore.com>
10275         * gcc.c (process_command): When deciding if undefined variables
10276         should be ignored when processing specs, accept "gcc -v" as well.
10278 2017-07-06  Jan Hubicka  <hubicka@ucw.cz>
10280         * auto-profile.c (afdo_set_bb_count, afdo_propagate_edge,
10281         afdo_annotate_cfg): Set counts/probabilities as determined by afdo.
10283 2017-07-06  Thomas Preud'homme  <thomas.preudhomme@arm.com>
10285         * config/arm/arm-cpus.in (armv8-r): Add new entry.
10286         * config/arm/arm-isa.h (ISA_ARMv8r): Define macro.
10287         * config/arm/arm-tables.opt: Regenerate.
10288         * config/arm/arm.h (enum base_architecture): Add BASE_ARCH_8R
10289         enumerator.
10290         * doc/invoke.texi: Mention -march=armv8-r and its extensions.
10292 2017-07-06  Carl Love  <cel@us.ibm.com>
10294         * ChangeLog: Clean up from mid air collision
10296 2017-07-06  Carl Love  <cel@us.ibm.com>
10298         * config/rs6000/rs6000-c.c: Add support for built-in functions
10299         vector signed int vec_subc (vector signed int, vector signed int);
10300         vector signed __int128 vec_subc (vector signed __int128,
10301                                          vector signed __int128);
10302         vector unsigned __int128 vec_subc (vector unsigned __int128,
10303                                            vector unsigned __int128);
10304         vector signed int vec_sube (vector signed int, vector signed int,
10305                                     vector signed int);
10306         vector unsigned int vec_sube (vector unsigned int,
10307                                       vector unsigned int,
10308                                       vector unsigned int);
10309         vector signed __int128 vec_sube (vector signed __int128,
10310                                          vector signed __int128,
10311                                          vector signed__int128);
10312         vector unsigned __int128 vec_sube (vector unsigned __int128,
10313                                            vector unsigned __int128,
10314                                            vector unsigned __int128);
10315         vector signed int vec_subec (vector signed int, vector signed int,
10316                                      vector signed int);
10317         vector unsigned int vec_subec (vector unsigned int,
10318                                        vector unsigned int,
10319                                        vector unsigned int);
10320         vector signed __int128 vec_subec (vector signed __int128,
10321                                           vector signed __int128,
10322                                           vector signed__int128);
10323         vector unsigned __int128 vec_subec (vector unsigned __int128,
10324                                             vector unsigned __int128,
10325                                             vector unsigned __int128);
10326         * config/rs6000/rs6000.c (ALTIVEC_BUILTIN_VEC_SUBE,
10327         ALTIVEC_BUILTIN_VEC_SUBEC): Add ef_builtins.
10328         * config/rs6000/rs6000-builtin.def (SUBE, SUBEC): Add
10329         BU_ALTIVEC_OVERLOAD_X definitions.
10330         * config/rs6000/altivec.h (vec_sube, vec_subec): Add builtin defines.
10331         * doc/extend.texi: Update the built-in documentation file for the new
10332         built-in functions.
10334 2017-07-06  David Malcolm  <dmalcolm@redhat.com>
10336         PR c++/79300
10337         * diagnostic-show-locus.c (layout::layout): Use start and finish
10338         spelling location for the start and finish of each range.
10339         * genmatch.c (linemap_client_expand_location_to_spelling_point):
10340         Add unused aspect param.
10341         * input.c (expand_location_1): Add "aspect" param, and use it
10342         to access the correct part of the location.
10343         (expand_location): Pass LOCATION_ASPECT_CARET to new param of
10344         expand_location_1.
10345         (expand_location_to_spelling_point): Likewise.
10346         (linemap_client_expand_location_to_spelling_point): Add "aspect"
10347         param, and pass it to expand_location_1.
10349 2017-07-06  Sebastian Peryt  <sebastian.peryt@intel.com>
10351         * config/i386/avx512fintrin.h (_mm_mask_getexp_round_ss,
10352         _mm_maskz_getexp_round_ss, _mm_mask_getexp_round_sd,
10353         _mm_maskz_getexp_round_sd, _mm_mask_getmant_round_sd,
10354         _mm_maskz_getmant_round_sd, _mm_mask_getmant_round_ss,
10355         _mm_maskz_getmant_round_ss, _mm_mask_getexp_ss, _mm_maskz_getexp_ss,
10356         _mm_mask_getexp_sd, _mm_maskz_getexp_sd, _mm_mask_getmant_sd,
10357         _mm_maskz_getmant_sd, _mm_mask_getmant_ss,
10358         _mm_maskz_getmant_ss): New intrinsics.
10359         (__builtin_ia32_getexpss128_mask): Changed to ...
10360         __builtin_ia32_getexpss128_round ... this.
10361         (__builtin_ia32_getexpsd128_mask): Changed to ...
10362         __builtin_ia32_getexpsd128_round ... this.
10363         * config/i386/i386-builtin-types.def
10364         ((V2DF, V2DF, V2DF, INT, V2DF, UQI, INT),
10365         (V4SF, V4SF, V4SF, INT, V4SF, UQI, INT)): New function type aliases.
10366         * config/i386/i386-builtin.def (__builtin_ia32_getexpsd_mask_round,
10367         __builtin_ia32_getexpss_mask_round,     __builtin_ia32_getmantsd_mask_round,
10368         __builtin_ia32_getmantss_mask_round): New builtins.
10369         * config/i386/i386.c (V2DF_FTYPE_V2DF_V2DF_INT_V2DF_UQI_INT,
10370         V4SF_FTYPE_V4SF_V4SF_INT_V4SF_UQI_INT): Handle new types.
10371         (CODE_FOR_avx512f_vgetmantv2df_mask_round,
10372         CODE_FOR_avx512f_vgetmantv4sf_mask_round): New cases.
10373         * config/i386/sse.md
10374         (avx512f_sgetexp<mode><round_saeonly_name>): Changed to ...
10375         avx512f_sgetexp<mode><mask_scalar_name>
10376         <round_saeonly_scalar_name> ... this.
10377         (vgetexp<ssescalarmodesuffix>\t{<round_saeonly_op3>%2, %1, %0|
10378         %0, %1, %2<round_saeonly_op3>}): Changed to ...
10379         vgetexp<ssescalarmodesuffix>
10380         \t{<round_saeonly_scalar_mask_op3>%2, %1, %0<mask_scalar_operand3>|
10381         %0<mask_scalar_operand3>, %1, %2<round_saeonly_scalar_mask_op3>} ... this.
10382         (avx512f_vgetmant<mode><round_saeonly_name>): Changed to ...
10383         avx512f_vgetmant<mode><mask_scalar_name>
10384         <round_saeonly_scalar_name> ... this.
10385         (vgetmant<ssescalarmodesuffix>\t{%3, <round_saeonly_op4>%2, %1, %0|
10386         %0, %1, %2<round_saeonly_op4>, %3}): Changed to ...
10387         vgetmant<ssescalarmodesuffix>
10388         \t{%3, <round_saeonly_scalar_mask_op4>%2, %1, %0<mask_scalar_operand4>|
10389         %0<mask_scalar_operand4>, %1, %2
10390         <round_saeonly_scalar_mask_op4>, %3} ... this.
10391         * config/i386/subst.md (mask_scalar_operand4,
10392         round_saeonly_scalar_mask_operand4,     round_saeonly_scalar_mask_op4,
10393         round_saeonly_scalar_nimm_predicate): New subst attributes.
10395 2017-07-06  Julia Koval  <julia.koval@intel.com>
10397         * config/i386/i386.c (ix86_erase_embedded_rounding):
10398         Remove code for old rounding pattern.
10400 2017-07-06  Richard Earnshaw  <rearnsha@arm.com>
10402         * config/arm/t-arm (GTM_H): Add arm-cpu.h.
10404 2017-07-06  Christophe Lyon  <christophe.lyon@linaro.org>
10406         * doc/sourcebuild.texi (Test Directives, Variants of
10407         dg-require-support): Add documentation for dg-require-stack-check.
10409 2017-07-05  Sebastian Peryt  <sebastian.peryt@intel.com>
10411         * config/i386/subst.md (mask_scalar, round_scalar,
10412         round_saeonly_scalar): New meta-templates.
10413         (mask_scalar_name, mask_scalar_operand3, round_scalar_name,
10414         round_scalar_mask_operand3, round_scalar_mask_op3,
10415         round_scalar_constraint, round_scalar_prefix, round_saeonly_scalar_name,
10416         round_saeonly_scalar_mask_operand3, round_saeonly_scalar_mask_op3,
10417         round_saeonly_scalar_constraint,
10418         round_saeonly_scalar_prefix): New subst attribute.
10419         * config/i386/sse.md
10420         (<sse>_vm<plusminus_insn><mode>3<mask_name><round_name>): Renamed to ...
10421         <sse>_vm<plusminus_insn><mode>3<mask_scalar_name>
10422         <round_scalar_name> ... this.
10423         (<sse>_vm<multdiv_mnemonic><mode>3<mask_name><round_name>): Renamed to ...
10424         <sse>_vm<multdiv_mnemonic><mode>3<mask_scalar_name>
10425         <round_scalar_name> ... this.
10426         (<sse>_vm<code><mode>3<mask_name><round_saeonly_name>): Renamed to ...
10427         <sse>_vm<code><mode>3<mask_scalar_name>
10428         <round_saeonly_scalar_name> ... this.
10429         (v<plusminus_mnemonic><ssescalarmodesuffix>
10430         \t{<round_mask_op3>%2, %1, %0<mask_operand3>|
10431         %0<mask_operand3>, %1, %<iptr>2<round_mask_op3>}): Changed to ...
10432         v<plusminus_mnemonic><ssescalarmodesuffix>
10433         \t{<round_scalar_mask_op3>%2, %1, %0<mask_scalar_operand3>|
10434         %0<mask_scalar_operand3>, %1, %<iptr>2<round_scalar_mask_op3>} ... this.
10435         (v<multdiv_mnemonic><ssescalarmodesuffix>
10436         \t{<round_mask_op3>%2, %1, %0<mask_operand3>|
10437         %0<mask_operand3>, %1, %<iptr>2<round_mask_op3>}): Changed to ...
10438         v<multdiv_mnemonic><ssescalarmodesuffix>
10439         \t{<round_scalar_mask_op3>%2, %1, %0<mask_scalar_operand3>|
10440         %0<mask_scalar_operand3>, %1, %<iptr>2<round_scalar_mask_op3>} ... this.
10441         (v<maxmin_float><ssescalarmodesuffix>
10442         \t{<round_saeonly_mask_op3>%2, %1, %0<mask_operand3>|
10443         %0<mask_operand3>, %1, %<iptr>2<round_saeonly_mask_op3>}): Changed to ...
10444         v<maxmin_float><ssescalarmodesuffix>
10445         \t{<round_saeonly_scalar_mask_op3>%2, %1, %0<mask_scalar_operand3>|
10446         %0<mask_scalar_operand3>, %1, %<iptr>2
10447         <round_saeonly_scalar_mask_op3>} ... this.
10449 2017-07-05  Richard Earnshaw  <rearnsha@arm.com>
10451         * config/arm/arm.c (arm_fixed_condition_code_regs): New function.
10452         (TARGET_FIXED_CONDITION_CODE_REGS): Redefine.
10454 2017-07-05  Richard Sandiford  <richard.sandiford@linaro.org>
10455             Alan Hayward  <alan.hayward@arm.com>
10456             David Sherwood  <david.sherwood@arm.com>
10458         * combine.c (simplify_if_then_else): Remove "enum" before
10459         "machine_mode".
10460         * compare-elim.c (can_eliminate_compare): Likewise.
10461         * config/aarch64/aarch64-builtins.c (aarch64_simd_builtin_std_type):
10462         Likewise.
10463         (aarch64_lookup_simd_builtin_type): Likewise.
10464         (aarch64_simd_builtin_type): Likewise.
10465         (aarch64_init_simd_builtin_types): Likewise.
10466         (aarch64_simd_expand_args): Likewise.
10467         * config/aarch64/aarch64-protos.h (aarch64_simd_attr_length_rglist):
10468         Likewise.
10469         (aarch64_reverse_mask): Likewise.
10470         (aarch64_simd_emit_reg_reg_move): Likewise.
10471         (aarch64_gen_adjusted_ldpstp): Likewise.
10472         (aarch64_ccmp_mode_to_code): Likewise.
10473         (aarch64_operands_ok_for_ldpstp): Likewise.
10474         (aarch64_operands_adjust_ok_for_ldpstp): Likewise.
10475         * config/aarch64/aarch64.c (aarch64_ira_change_pseudo_allocno_class):
10476         Likewise.
10477         (aarch64_min_divisions_for_recip_mul): Likewise.
10478         (aarch64_reassociation_width): Likewise.
10479         (aarch64_get_condition_code_1): Likewise.
10480         (aarch64_simd_emit_reg_reg_move): Likewise.
10481         (aarch64_simd_attr_length_rglist): Likewise.
10482         (aarch64_reverse_mask): Likewise.
10483         (aarch64_operands_ok_for_ldpstp): Likewise.
10484         (aarch64_operands_adjust_ok_for_ldpstp): Likewise.
10485         (aarch64_gen_adjusted_ldpstp): Likewise.
10486         * config/aarch64/cortex-a57-fma-steering.c (fma_node::rename):
10487         Likewise.
10488         * config/arc/arc.c (legitimate_offset_address_p): Likewise.
10489         * config/arm/arm-builtins.c (arm_simd_builtin_std_type): Likewise.
10490         (arm_lookup_simd_builtin_type): Likewise.
10491         (arm_simd_builtin_type): Likewise.
10492         (arm_init_simd_builtin_types): Likewise.
10493         (arm_expand_builtin_args): Likewise.
10494         * config/arm/arm-protos.h (arm_expand_builtin): Likewise.
10495         * config/ft32/ft32.c (ft32_libcall_value): Likewise.
10496         (ft32_setup_incoming_varargs): Likewise.
10497         (ft32_function_arg): Likewise.
10498         (ft32_function_arg_advance): Likewise.
10499         (ft32_pass_by_reference): Likewise.
10500         (ft32_arg_partial_bytes): Likewise.
10501         (ft32_valid_pointer_mode): Likewise.
10502         (ft32_addr_space_pointer_mode): Likewise.
10503         (ft32_addr_space_legitimate_address_p): Likewise.
10504         * config/i386/i386-protos.h (ix86_operands_ok_for_move_multiple):
10505         Likewise.
10506         * config/i386/i386.c (ix86_setup_incoming_vararg_bounds): Likewise.
10507         (ix86_emit_outlined_ms2sysv_restore): Likewise.
10508         (iamcu_alignment): Likewise.
10509         (canonicalize_vector_int_perm): Likewise.
10510         (ix86_noce_conversion_profitable_p): Likewise.
10511         (ix86_mpx_bound_mode): Likewise.
10512         (ix86_operands_ok_for_move_multiple): Likewise.
10513         * config/microblaze/microblaze-protos.h
10514         (microblaze_expand_conditional_branch_reg): Likewise.
10515         * config/microblaze/microblaze.c
10516         (microblaze_expand_conditional_branch_reg): Likewise.
10517         * config/powerpcspe/powerpcspe.c (rs6000_init_hard_regno_mode_ok):
10518         Likewise.
10519         (rs6000_reassociation_width): Likewise.
10520         (rs6000_invalid_binary_op): Likewise.
10521         (fusion_p9_p): Likewise.
10522         (emit_fusion_p9_load): Likewise.
10523         (emit_fusion_p9_store): Likewise.
10524         * config/riscv/riscv-protos.h (riscv_regno_mode_ok_for_base_p):
10525         Likewise.
10526         (riscv_hard_regno_mode_ok_p): Likewise.
10527         (riscv_address_insns): Likewise.
10528         (riscv_split_symbol): Likewise.
10529         (riscv_legitimize_move): Likewise.
10530         (riscv_function_value): Likewise.
10531         (riscv_hard_regno_nregs): Likewise.
10532         (riscv_expand_builtin): Likewise.
10533         * config/riscv/riscv.c (riscv_build_integer_1): Likewise.
10534         (riscv_build_integer): Likewise.
10535         (riscv_split_integer): Likewise.
10536         (riscv_legitimate_constant_p): Likewise.
10537         (riscv_cannot_force_const_mem): Likewise.
10538         (riscv_regno_mode_ok_for_base_p): Likewise.
10539         (riscv_valid_base_register_p): Likewise.
10540         (riscv_valid_offset_p): Likewise.
10541         (riscv_valid_lo_sum_p): Likewise.
10542         (riscv_classify_address): Likewise.
10543         (riscv_legitimate_address_p): Likewise.
10544         (riscv_address_insns): Likewise.
10545         (riscv_load_store_insns): Likewise.
10546         (riscv_force_binary): Likewise.
10547         (riscv_split_symbol): Likewise.
10548         (riscv_force_address): Likewise.
10549         (riscv_legitimize_address): Likewise.
10550         (riscv_move_integer): Likewise.
10551         (riscv_legitimize_const_move): Likewise.
10552         (riscv_legitimize_move): Likewise.
10553         (riscv_address_cost): Likewise.
10554         (riscv_subword): Likewise.
10555         (riscv_output_move): Likewise.
10556         (riscv_canonicalize_int_order_test): Likewise.
10557         (riscv_emit_int_order_test): Likewise.
10558         (riscv_function_arg_boundary): Likewise.
10559         (riscv_pass_mode_in_fpr_p): Likewise.
10560         (riscv_pass_fpr_single): Likewise.
10561         (riscv_pass_fpr_pair): Likewise.
10562         (riscv_get_arg_info): Likewise.
10563         (riscv_function_arg): Likewise.
10564         (riscv_function_arg_advance): Likewise.
10565         (riscv_arg_partial_bytes): Likewise.
10566         (riscv_function_value): Likewise.
10567         (riscv_pass_by_reference): Likewise.
10568         (riscv_setup_incoming_varargs): Likewise.
10569         (riscv_print_operand): Likewise.
10570         (riscv_elf_select_rtx_section): Likewise.
10571         (riscv_save_restore_reg): Likewise.
10572         (riscv_for_each_saved_reg): Likewise.
10573         (riscv_register_move_cost): Likewise.
10574         (riscv_hard_regno_mode_ok_p): Likewise.
10575         (riscv_hard_regno_nregs): Likewise.
10576         (riscv_class_max_nregs): Likewise.
10577         (riscv_memory_move_cost): Likewise.
10578         * config/rl78/rl78-protos.h (rl78_split_movsi): Likewise.
10579         * config/rl78/rl78.c (rl78_split_movsi): Likewise.
10580         (rl78_addr_space_address_mode): Likewise.
10581         * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin):
10582         Likewise.
10583         * config/rs6000/rs6000.c (rs6000_init_hard_regno_mode_ok): Likewise.
10584         (rs6000_reassociation_width): Likewise.
10585         (rs6000_invalid_binary_op): Likewise.
10586         (fusion_p9_p): Likewise.
10587         (emit_fusion_p9_load): Likewise.
10588         (emit_fusion_p9_store): Likewise.
10589         * config/visium/visium-protos.h (prepare_move_operands): Likewise.
10590         (ok_for_simple_move_operands): Likewise.
10591         (ok_for_simple_move_strict_operands): Likewise.
10592         (ok_for_simple_arith_logic_operands): Likewise.
10593         (visium_legitimize_reload_address): Likewise.
10594         (visium_select_cc_mode): Likewise.
10595         (output_cbranch): Likewise.
10596         (visium_split_double_move): Likewise.
10597         (visium_expand_copysign): Likewise.
10598         (visium_expand_int_cstore): Likewise.
10599         (visium_expand_fp_cstore): Likewise.
10600         * config/visium/visium.c (visium_pass_by_reference): Likewise.
10601         (visium_function_arg): Likewise.
10602         (visium_function_arg_advance): Likewise.
10603         (visium_libcall_value): Likewise.
10604         (visium_setup_incoming_varargs): Likewise.
10605         (visium_legitimate_constant_p): Likewise.
10606         (visium_legitimate_address_p): Likewise.
10607         (visium_legitimize_address): Likewise.
10608         (visium_secondary_reload): Likewise.
10609         (visium_register_move_cost): Likewise.
10610         (visium_memory_move_cost): Likewise.
10611         (prepare_move_operands): Likewise.
10612         (ok_for_simple_move_operands): Likewise.
10613         (ok_for_simple_move_strict_operands): Likewise.
10614         (ok_for_simple_arith_logic_operands): Likewise.
10615         (visium_function_value_1): Likewise.
10616         (rtx_ok_for_offset_p): Likewise.
10617         (visium_legitimize_reload_address): Likewise.
10618         (visium_split_double_move): Likewise.
10619         (visium_expand_copysign): Likewise.
10620         (visium_expand_int_cstore): Likewise.
10621         (visium_expand_fp_cstore): Likewise.
10622         (visium_split_cstore): Likewise.
10623         (visium_select_cc_mode): Likewise.
10624         (visium_split_cbranch): Likewise.
10625         (output_cbranch): Likewise.
10626         (visium_print_operand_address): Likewise.
10627         * expmed.c (flip_storage_order): Likewise.
10628         * expmed.h (emit_cstore): Likewise.
10629         (flip_storage_order): Likewise.
10630         * genrecog.c (validate_pattern): Likewise.
10631         * hsa-gen.c (gen_hsa_addr): Likewise.
10632         * internal-fn.c (expand_arith_overflow): Likewise.
10633         * ira-color.c (allocno_copy_cost_saving): Likewise.
10634         * lra-assigns.c (find_hard_regno_for_1): Likewise.
10635         * lra-constraints.c (prohibited_class_reg_set_mode_p): Likewise.
10636         (process_invariant_for_inheritance): Likewise.
10637         * lra-eliminations.c (move_plus_up): Likewise.
10638         * omp-low.c (lower_oacc_reductions): Likewise.
10639         * simplify-rtx.c (simplify_subreg): Likewise.
10640         * target.def (TARGET_SETUP_INCOMING_VARARG_BOUNDS): Likewise.
10641         (TARGET_CHKP_BOUND_MODE): Likewise..
10642         * targhooks.c (default_chkp_bound_mode): Likewise.
10643         (default_setup_incoming_vararg_bounds): Likewise.
10644         * targhooks.h (default_chkp_bound_mode): Likewise.
10645         (default_setup_incoming_vararg_bounds): Likewise.
10646         * tree-ssa-math-opts.c (divmod_candidate_p): Likewise.
10647         * tree-vect-loop.c (calc_vec_perm_mask_for_shift): Likewise.
10648         (have_whole_vector_shift): Likewise.
10649         * tree-vect-stmts.c (vectorizable_load): Likewise.
10650         * doc/tm.texi: Regenerate.
10652 2017-07-05  Georg-Johann Lay  <avr@gjlay.de>
10654         Graceful degrade if Binutils PR21472 is not available.
10656         PR target/81072
10657         * configure.ac [target=avr]: WARN instead of ERROR if avrxmega3
10658         .rodata in flash test fails.
10659         (HAVE_LD_AVR_AVRXMEGA3_RODATA_IN_FLASH): Define it if test passes.
10660         * confgure: Regenerate.
10661         * config.in: Regenerate.
10662         * config/avr/avr.c (avr_asm_named_section)
10663         [HAVE_LD_AVR_AVRXMEGA3_RODATA_IN_FLASH]: Only trigger
10664         __do_copy_data for stuff in .rodata if flash_pm_offset = 0.
10665         (avr_asm_init_sections): Same.
10667 2017-07-05  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
10669         * config/arm/neon.md (fma<VCVTF:mode>4): Remove %?.
10670         (fma<VH:mode>4_intrinsic): Likewise.
10671         (*fmsub<VCVTF:mode>4): Likewise.
10672         (*fmsub<VH:mode>4_intrinsic): Likewise.
10674 2017-07-05  Georg-Johann Lay  <avr@gjlay.de>
10676         PR target/81305
10677         * config/avr/avr.c (avr_out_movhi_mr_r_xmega) [CONSTANT_ADDRESS_P]:
10678         Don't depend on "optimize > 0".
10679         (out_movhi_r_mr, out_movqi_mr_r): Same.
10680         (out_movhi_mr_r, out_movqi_r_mr): Same.
10681         (avr_address_cost) [CONSTANT_ADDRESS_P]: Don't depend cost for
10682         io_address_operand on "optimize > 0".
10684 2017-07-05  Bin Cheng  <bin.cheng@arm.com>
10686         * tree-loop-distribution.c: Add general explanantion on the pass.
10687         (generate_loops_for_partition): Mark distributed loop.
10688         (pg_add_dependence_edges): New parameter.  Handle alias data
10689         dependence specially and record it in the parameter if asked.
10690         (struct pg_vdata, pg_edata, pg_edge_callback_data): New structs.
10691         (init_partition_graph_vertices, add_partition_graph_edge): New.
10692         (pg_skip_alias_edge, free_partition_graph_edata_cb): New.
10693         (free_partition_graph_vdata, build_partition_graph): New.
10694         (sort_partitions_by_post_order, merge_dep_scc_partitions): New.
10695         (pg_collect_alias_ddrs, break_alias_scc_partitions): New.
10696         (data_ref_segment_size, latch_dominated_by_data_ref): New.
10697         (compute_alias_check_pairs, version_loop_by_alias_check): New.
10698         (version_for_distribution_p, finalize_partitions): New.
10699         (distribute_loop): Handle alias data dependence specially.  Factor
10700         out loop fusion code as functions and call these functions.
10702 2017-07-05  Bin Cheng  <bin.cheng@arm.com>
10704         * tree-loop-distribution.c (classify_partition): New parameter and
10705         better handle reduction statement.
10706         (rdg_build_partitions): Revise comment.
10707         (distribute_loop): Compute statements in all partitions and pass it
10708         to classify_partition.
10710 2017-07-05  Bin Cheng  <bin.cheng@arm.com>
10712         * tree-loop-distribution.c (enum partition_type): New.
10713         (struct partition): New field type.
10714         (partition_merge_into): Add parameter.  Update partition type.
10715         (data_dep_in_cycle_p, update_type_for_merge): New functions.
10716         (build_rdg_partition_for_vertex): Compute partition type.
10717         (rdg_build_partitions): Dump partition type.
10718         (distribute_loop): Update calls to partition_merge_into.
10720 2017-07-05  Bin Cheng  <bin.cheng@arm.com>
10722         * tree-loop-distribution.c (struct ddr_hasher): New.
10723         (ddr_hasher::hash, ::equal, get_data_dependence): New function.
10724         (ddrs_table): New.
10725         (classify_partition): Call get_data_dependence.
10726         (pg_add_dependence_edges): Ditto.
10727         (distribute_loop): Release data dependence hash table.
10729 2017-07-05  Bin Cheng  <bin.cheng@arm.com>
10731         * tree-loop-distribution.c (ref_base_address): Delete.
10732         (similar_memory_accesses): Rename ...
10733         (share_memory_accesses): ... to this.  Check if partitions access
10734         the same memory reference.
10735         (distribute_loop): Call share_memory_accesses.
10737 2017-07-05  Bin Cheng  <bin.cheng@arm.com>
10739         * tree-loop-distribution.c (struct partition): New field recording
10740         its data reference.
10741         (partition_alloc, partition_free): Init and release data refs.
10742         (partition_merge_into): Merge data refs.
10743         (build_rdg_partition_for_vertex): Collect data refs for partition.
10744         (pg_add_dependence_edges): Change parameters from vector to bitmap.
10745         Update uses.
10746         (distribute_loop): Remve data refs from vertice data of partition
10747         graph.
10749 2017-07-05  Bin Cheng  <bin.cheng@arm.com>
10751         * tree-loop-distribution.c (params.h): Include header file.
10752         (MAX_DATAREFS_NUM, DR_INDEX): New macro.
10753         (datarefs_vec): New global var.
10754         (create_rdg_vertices): Use datarefs_vec directly.
10755         (free_rdg): Don't free data references.
10756         (build_rdg): Update use.  Don't free data references.
10757         (distribute_loop): Compute global variable for data references.
10758         Bail out if there are too many data references.
10760 2017-07-05  Bin Cheng  <bin.cheng@arm.com>
10762         * tree-loop-distribution.c (loop_nest): New global var.
10763         (build_rdg): Use loop directly, rather than loop nest.
10764         (pg_add_dependence_edges): Remove loop nest parameter.  Use global
10765         variable directly.
10766         (distribute_loop): Compute global variable loop nest.  Update use.
10768 2017-07-05  Bin Cheng  <bin.cheng@arm.com>
10770         * tree-loop-distribution.c (enum fuse_type, fuse_message): New.
10771         (partition_merge_into): New parameter.  Dump reason for fusion.
10772         (distribute_loop): Update use of partition_merge_into.
10774 2017-07-05  Bin Cheng  <bin.cheng@arm.com>
10776         * tree-loop-distribution.c (bb_top_order_index): New.
10777         (bb_top_order_index_size, bb_top_order_cmp): New.
10778         (stmts_from_loop): Use topological order.
10779         (pass_loop_distribution::execute): Compute and release topological
10780         order for basic blocks.
10782 2017-07-05  Bin Cheng  <bin.cheng@arm.com>
10784         * tree-loop-distribution.c (pass_loop_distribution::execute): Skip
10785         if no loops.
10787 2017-07-05  Bin Cheng  <bin.cheng@arm.com>
10789         * cfgloop.h (struct loop): Add comment.  New field orig_loop_num.
10790         * cfgloopmanip.c (lv_adjust_loop_entry_edge): Comment change.
10791         * internal-fn.c (expand_LOOP_DIST_ALIAS): New function.
10792         * internal-fn.def (LOOP_DIST_ALIAS): New.
10793         * tree-vectorizer.c (fold_loop_vectorized_call): Rename to ...
10794         (fold_loop_internal_call): ... this.
10795         (vect_loop_dist_alias_call): New function.
10796         (set_uid_loop_bbs): Call fold_loop_internal_call.
10797         (vectorize_loops): Fold IFN_LOOP_VECTORIZED and IFN_LOOP_DIST_ALIAS
10798         internal calls.
10800 2017-07-04  Uros Bizjak  <ubizjak@gmail.com>
10802         PR target/81300
10803         * config/i386/i386.md (setcc + movzbl/and to xor + setcc peepholes):
10804         Require dead FLAGS_REG at the beginning of a peephole.
10806 2017-07-04  Uros Bizjak  <ubizjak@gmail.com>
10808         PR target/81294
10809         * config/i386/adxintrin.h (_subborrow_u32): Swap _X and _Y
10810         arguments in the call to __builtin_ia32_sbb_u32.
10811         (_subborrow_u64): Swap _X and _Y arguments in the call to
10812         __builtin_ia32_sbb_u64.
10814 2017-07-04  Jakub Jelinek  <jakub@redhat.com>
10816         PR debug/81278
10817         * tree-vrp.c (compare_assert_loc): Turn into a function template
10818         with stable template parameter.  Only test if a->e is NULL,
10819         !a->e == !b->e has been verified already.  Use e == NULL or
10820         e != NULL instead of e or ! e tests.  If stable is true, don't use
10821         iterative_hash_expr, on the other side allow a or b or both NULL
10822         and sort the NULLs last.
10823         (process_assert_insertions): Sort using compare_assert_loc<false>
10824         instead of compare_assert_loc, later sort using
10825         compare_assert_loc<true> before calling process_assert_insertions_for
10826         in a loop.  Use break instead of continue once seen NULL pointer.
10828 2017-07-04  Thomas Preud'homme  <thomas.preudhomme@arm.com>
10830         * config/arm/driver-arm.c (arm_cpu_table): Add entry for ARM
10831         Cortex-R7 and Cortex-R8 processors.
10833 2017-07-04  Jan Hubicka  <hubicka@ucw.cz>
10835         * ipa-utils.c (ipa_merge_profiles): Fix merging when dst is
10836         uninitialized while src is not.
10838 2017-07-04  Richard Earnshaw  <rearnsha@arm.com>
10840         * common/config/arm/arm-common.c: Adjust include path for
10841         arm-cpu-cdata.h
10842         * config/arm/t-arm (TM_H): Adjust path for arm-cpu.h.
10843         (arm-cpu.h): Create in build directory.  Adjust dependency rules.
10844         (arm-cpu-data.h): Likewise.
10845         (arm-cpu-cdata.h): Likewise.
10846         * config/arm/arm-cpu.h: Delete.
10847         * config/arm/arm-cpu-cdata.h: Delete.
10848         * config/arm/arm-cpu-data.h: Delete.
10850 2017-07-04  James Greenhalgh  <james.greenhalgh@arm.com>
10852         * config/arm/arm-cpus.in (cortex-a55): New.
10853         (cortex-a75): Likewise.
10854         (cortex-a75.cortex-a55): Likewise.
10855         * config/arm/driver-arm.c (arm_cpu_table): Add cortex-a55 and
10856         cortex-a75.
10857         * doc/invoke.texi (-mcpu): Document cortex-a55 and cortex-a75.
10858         * config/arm/arm-cpu-cdata.h: Regenerate.
10859         * config/arm/arm-cpu-data.h: Regenerate.
10860         * config/arm/arm-cpu.h: Regenerate.
10861         * config/arm/arm-tables.opt: Regenerate.
10862         * config/arm/arm-tune.md: Regenerate.
10864 2017-07-04  Jan Hubicka  <hubicka@ucw.cz>
10866         * haifa-sched.c (sched_create_recovery_edges): Update profile.
10868 2017-07-04  Jan Hubicka  <hubicka@ucw.cz>
10870         * bb-reorder.c (better_edge_p): Fix handling of uninitialized
10871         probability.
10873 2017-07-04  Richard Sandiford  <richard.sandiford@linaro.org>
10875         PR tree-optimization/81292
10876         * tree-ssa-strlen.c (handle_builtin_strlen): When setting
10877         full_string_p, also call adjust_related_strinfos if the adjustment
10878         is simple, otherwise invalidate related strinfos.
10880 2017-07-04  Martin Liska  <mliska@suse.cz>
10882         PR sanitizer/81040
10883         * sanopt.c (sanitize_rewrite_addressable_params): Mark the
10884         newly created variable as DECL_IGNORED_P.
10886 2017-07-04  Martin Liska  <mliska@suse.cz>
10888         PR ipa/81293
10889         * ipa-inline.c (inline_small_functions):
10890         Use xstrdup_for_dump.
10892 2017-07-04  Tom de Vries  <tom@codesourcery.com>
10894         * graph.c (draw_cfg_edges): Save and restore EDGE_DFS_BACK.
10896 2017-07-03  Dominique d'Humieres  <dominiq@lps.ens.fr>
10898         PR target/81033
10899         * config/darwin.c (darwin_function_switched_text_sections):
10900         Fix spaces.
10902 2017-07-03  Jan Hubicka  <hubicka@ucw.cz>
10904         * tree-vect-loop-manip.c (vect_do_peeling): Fix scaling up.
10906 2017-07-03  Richard Earnshaw  <rearnsha@arm.com>
10908         * doc/invoke.texi (ARM Options): Add -mbe8 and -mbe32 to option summary.
10910 2017-07-03  Richard Sandiford  <richard.sandiford@linaro.org>
10912         * tree-vect-loop.c (vect_analyze_loop_2): Treat min_scalar_loop_bound,
10913         min_profitable_iters, and th as inclusive lower bounds.
10914         Fix LOOP_VINFO_PEELING_FOR_GAPS condition.
10915         (vect_estimate_min_profitable_iters): Return inclusive lower bounds
10916         for min_profitable_iters and min_profitable_estimate.
10917         (vect_transform_loop): Treat th as an inclusive lower bound.
10918         * tree-vect-loop-manip.c (vect_loop_versioning): Likewise.
10920 2017-07-03  Dominique d'Humieres  <dominiq@lps.ens.fr>
10922         PR target/81033
10923         * config/darwin.c (darwin_function_switched_text_sections):
10924         Replace DECL_NAME with DECL_ASSEMBLER_NAME, split assemble_name_raw
10925         in two pieces, and suppress the use of buf.
10927 2017-07-03  Nathan Sidwell  <nathan@acm.org>
10929         * hash-table.h (hash_table_mod1): Fix indentation.
10931 2017-07-02  Jan Hubicka  <hubicka@ucw.cz>
10933         PR middle-end/81290
10934         * predict.c (force_edge_cold): Be more careful about propagation
10935         backward.
10936         * profile-count.h (profile_probability::guessed,
10937         profile_probability::fdo, profile_count::guessed, profile_count::fdo):
10938         New.
10939         * tree-ssa-threadupdate.c (recompute_probabilities): Result is guessed.
10941 2017-07-03  James Greenhalgh  <james.greenhalgh@arm.com>
10943         * doc/invoke.texi (rcpc architecture extension): Document it.
10945 2017-07-03  Richard Biener  <rguenther@suse.de>
10947         PR tree-optimization/60510
10948         * tree-vect-loop.c (vect_create_epilog_for_reduction): Pass in
10949         the scalar reduction PHI and use it.
10950         (vectorizable_reduction): Properly guard the single_defuse_cycle
10951         path for non-SLP reduction chains where we cannot use it.
10952         Rework reduc_def/index and vector type deduction.  Rework
10953         vector operand gathering during reduction op code-gen.
10954         * tree-vect-slp.c (vect_analyze_slp): For failed SLP reduction
10955         chains dissolve the chain and leave it to non-SLP reduction
10956         handling.
10958 2017-07-03  Richard Sandiford  <richard.sandiford@linaro.org>
10960         * tree-data-ref.h (dr_alignment): Declare.
10961         * tree-data-ref.c (dr_alignment): New function.
10962         * tree-vectorizer.h (dataref_aux): Remove base_element_aligned.
10963         * tree-vect-data-refs.c (vect_compute_data_ref_alignment): Don't
10964         set it.
10965         * tree-vect-stmts.c (vectorizable_store): Use dr_alignment.
10967 2017-07-03  Richard Sandiford  <richard.sandiford@linaro.org>
10969         * tree-data-ref.h (innermost_loop_behavior): Add base_alignment
10970         and base_misalignment fields.
10971         (DR_BASE_ALIGNMENT, DR_BASE_MISALIGNMENT): New macros.
10972         * tree-data-ref.c: Include builtins.h.
10973         (dr_analyze_innermost): Set up the new innmost_loop_behavior fields.
10974         * tree-vectorizer.h (STMT_VINFO_DR_BASE_ALIGNMENT): New macro.
10975         (STMT_VINFO_DR_BASE_MISALIGNMENT): Likewise.
10976         * tree-vect-data-refs.c: Include tree-cfg.h.
10977         (vect_compute_data_ref_alignment): Use the new innermost_loop_behavior
10978         fields instead of calculating an alignment here.
10979         (vect_analyze_data_refs): Use dr_analyze_innermost.  Dump the new
10980         innermost_loop_behavior fields.
10982 2017-07-03  Richard Sandiford  <richard.sandiford@linaro.org>
10984         * tree-data-ref.h (innermost_loop_behavior): Add a step_alignment
10985         field.
10986         (DR_STEP_ALIGNMENT): New macro.
10987         * tree-vectorizer.h (STMT_VINFO_DR_STEP_ALIGNMENT): Likewise.
10988         * tree-data-ref.c (dr_analyze_innermost): Initalize step_alignment.
10989         (create_data_ref): Print it.
10990         * tree-vect-stmts.c (vectorizable_load): Use the step alignment
10991         to tell whether the step preserves vector (mis)alignment.
10992         * tree-vect-data-refs.c (vect_compute_data_ref_alignment): Likewise.
10993         Move the check for an integer step and generalise to all INTEGER_CST.
10994         (vect_analyze_data_refs): Set DR_STEP_ALIGNMENT when setting DR_STEP.
10995         Print the outer step alignment.
10997 2017-07-03  Richard Sandiford  <richard.sandiford@linaro.org>
10999         * tree-data-ref.h (innermost_loop_behavior): Replace aligned_to
11000         with offset_alignment.
11001         (DR_ALIGNED_TO): Delete.
11002         (DR_OFFSET_ALIGNMENT): New macro.
11003         * tree-vectorizer.h (STMT_VINFO_DR_ALIGNED_TO): Delete.
11004         (STMT_VINFO_DR_OFFSET_ALIGNMENT): New macro.
11005         * tree-data-ref.c (dr_analyze_innermost): Update after above changes.
11006         (create_data_ref): Likewise.
11007         * tree-vect-data-refs.c (vect_compute_data_ref_alignment): Likewise.
11008         (vect_analyze_data_refs): Likewise.
11009         * tree-if-conv.c (if_convertible_loop_p_1): Use memset before
11010         creating dummy innermost behavior.
11012 2017-07-03  Richard Sandiford  <richard.sandiford@linaro.org>
11014         * tree-data-ref.h (dr_analyze_innermost): Replace the dr argument
11015         with a "innermost_loop_behavior *" and refeence tree.
11016         * tree-data-ref.c (dr_analyze_innermost): Likewise.
11017         (create_data_ref): Update call accordingly.
11018         * tree-predcom.c (find_looparound_phi): Likewise.
11020 2017-07-03  Richard Sandiford  <richard.sandiford@linaro.org>
11022         * tree-vectorizer.h (_stmt_vec_info): Replace individual dr_*
11023         fields with dr_wrt_vec_loop.
11024         (STMT_VINFO_DR_BASE_ADDRESS, STMT_VINFO_DR_INIT, STMT_VINFO_DR_OFFSET)
11025         (STMT_VINFO_DR_STEP, STMT_VINFO_DR_ALIGNED_TO): Update accordingly.
11026         (STMT_VINFO_DR_WRT_VEC_LOOP): New macro.
11027         (vect_dr_behavior): New function.
11028         (vect_create_addr_base_for_vector_ref): Remove loop parameter.
11029         * tree-vect-data-refs.c (vect_compute_data_ref_alignment): Use
11030         vect_dr_behavior.  Use a step_preserves_misalignment_p boolean to
11031         track whether the step preserves the misalignment.
11032         (vect_create_addr_base_for_vector_ref): Remove loop parameter.
11033         Use vect_dr_behavior.
11034         (vect_setup_realignment): Update call accordingly.
11035         (vect_create_data_ref_ptr): Likewise.  Use vect_dr_behavior.
11036         * tree-vect-loop-manip.c (vect_gen_prolog_loop_niters): Update
11037         call to vect_create_addr_base_for_vector_ref.
11038         (vect_create_cond_for_align_checks): Likewise.
11039         * tree-vect-patterns.c (vect_recog_bool_pattern): Copy
11040         STMT_VINFO_DR_WRT_VEC_LOOP as a block.
11041         (vect_recog_mask_conversion_pattern): Likewise.
11042         * tree-vect-stmts.c (compare_step_with_zero): Use vect_dr_behavior.
11043         (new_stmt_vec_info): Remove redundant zeroing.
11045 2017-07-03  Richard Earnshaw  <rearnsha@arm.com>
11047         * common/config/arm/arm-common.c (arm_be8_option): New function.
11048         * config/arm/arm-isa.h (isa_feature): Add new feature bit isa_bit_be8.
11049         (ISA_ARMv6): Add isa_bit_be8.
11050         * config/arm/arm.h (arm_be8_option): Add prototype.
11051         (BE8_SPEC_FUNCTION): New define.
11052         (EXTRA_SPEC_FUNCTIONS): Add BE8_SPEC_FUNCTION.
11053         * config/arm/arm.opt (mbig-endian): Mark as Negative of mlittle-endian.
11054         (mlittle-endian): Similarly.
11055         (mbe8, mbe32): New options.
11056         * config/arm/bpabi.h (BE8_LINK_SPEC): Call arm_be8_option.
11057         * doc/invoke.texi (ARM Options): Document -mbe8 and -mbe32.
11059 2017-07-02  Jan Hubicka  <hubicka@ucw.cz>
11061         * tree-cfg.c (gimple_find_sub_bbs): Fix profile updating.
11063 2017-07-02  Jan Hubicka  <hubicka@ucw.cz>
11065         * tree-cfgcleanup.c (want_merge_blocks_p): New function.
11066         (cleanup_tree_cfg_bb): Use it.
11067         * profile-count.h (profile_count::of_for_merging, profile_count::merge):
11068         New functions.
11069         * tree-cfg.c (gimple_merge_blocks): Use profile_count::merge.
11071 2017-07-02  Jan Hubicka  <hubicka@ucw.cz>
11073         PR bootstrap/81285
11074         * loop-doloop.c (add_test): Update profile.
11076 2017-07-03  Martin Liska  <mliska@suse.cz>
11078         PR sanitize/81040
11079         * sanopt.c (rewrite_usage_of_param): New function.
11080         (sanitize_rewrite_addressable_params): Likewise.
11081         (pass_sanopt::execute): Call rewrite_usage_of_param.
11083 2017-07-03  Richard Biener  <rguenther@suse.de>
11085         * tree-vect-loop.c (vect_create_epilog_for_reduction): Revert
11086         back to using VIEW_CONVERT_EXPR.
11088 2017-07-03  Martin Liska  <mliska@suse.cz>
11090         PR other/78366
11091         * doc/extend.texi: Document when a resolver function is
11092         generated for target_clones.
11094 2017-07-03  Martin Liska  <mliska@suse.cz>
11096         * asan.c (asan_emit_stack_protection): Unpoison just red zones
11097         and shadow memory of auto variables which are subject of
11098         use-after-scope sanitization.
11099         (asan_expand_mark_ifn): Add do set only when is_poison.
11101 2016-07-03  Richard Biener  <rguenther@suse.de>
11103         * tree-vect-loop.c (vect_analyze_loop_operations): Also analyze
11104         reduction PHIs.
11105         (vect_force_simple_reduction): Record reduction def -> phi mapping.
11106         (vectorizable_reduction): Perform reduction PHI creation when
11107         visiting a reduction PHI and adjust and simplify code generation
11108         phase of the reduction op.  Cache dts, use fold_binary, not fold_build2.
11109         (vect_transform_loop): Visit reduction PHIs.
11110         * tree-vect-slp.c (vect_get_and_check_slp_defs): Record reduction
11111         defs into the SLP tree.
11112         (vect_build_slp_tree): Reduction defs terminate the recursion.
11113         * tree-vect-stmts.c (vect_get_vec_def_for_operand_1): Allow lookup
11114         of reduction defs.
11115         (vect_get_vec_defs_for_stmt_copy): Export.
11116         (vect_get_vec_defs): Likewise.
11117         * tree-vectorizer.h (struct _stmt_vec_info): Amend reduc_def
11118         purpose.
11119         (vect_get_vec_defs_for_stmt_copy): Declare.
11120         (vect_get_vec_defs): Likewise.
11122 2017-07-03  Richard Sandiford  <richard.sandiford@linaro.org>
11124         * tree-data-ref.c (dr_analyze_innermost): Replace the "nest"
11125         parameter with a "loop" parameter and use it instead of the
11126         loop containing DR_STMT.  Don't check simple_iv when doing
11127         BB analysis.  Describe the two analysis modes in the comment.
11129 2017-07-03  Tom de Vries  <tom@codesourcery.com>
11131         PR tree-optimization/69468
11132         * tree-ssa-tail-merge.c (ignore_edge_flags): New constant.
11133         (find_same_succ_bb): Handle ignore_edge_flags.
11135 2017-07-03  Tom de Vries  <tom@codesourcery.com>
11137         PR tree-optimization/81192
11138         * tree-ssa-tail-merge.c (same_succ_hash): Use bb->loop_father->num in
11139         hash.
11140         (same_succ::equal): Don't find bbs to be equal if bb->loop_father
11141         differs.
11142         (find_same_succ_bb): Remove obsolete test on bb->loop_father->latch.
11144 2017-07-03  Tom de Vries  <tom@codesourcery.com>
11146         PR tree-optimization/81192
11147         * tree-ssa-tail-merge.c (same_succ_flush_bb): Handle
11148         BB_SAME_SUCC (bb) == NULL.
11150 2017-07-02  Jan Hubicka  <hubicka@ucw.cz>
11152         * cfgrtl.c (rtl_verify_edges): Enable checking of profile_probability
11153         consistency.
11155 2017-07-02  Jan Hubicka  <hubicka@ucw.cz>
11157         * dumpfile.c: Include profile-count.h
11158         * tree-cfg.c (gimple_duplicate_sese_tail): Drop UNUSED attributes;
11159         update profile.
11160         (insert_cond_bb): Update profile.
11161         * tree-cfg.h (insert_cond_bb): Update prototype.
11162         * tree-chkp-opt.c (chkp_optimize_string_function_calls): Update.
11163         * tree-dump.c: Do not include tree-cfg.
11165 2017-07-02  Jan Hubicka  <hubicka@ucw.cz>
11167         * bb-reorder.c (fix_up_crossing_landing_pad): Update profile.
11169 2017-07-02  Jan Hubicka  <hubicka@ucw.cz>
11171         * expect.c (dw2_build_landing_pads): Update profile of the landing pad
11172         bb.
11174 2017-07-02  Jan Hubicka  <hubicka@ucw.cz>
11176         * tree-complex.c (expand_complex_div_wide): update profile.
11178 2017-07-02  Richard Sandiford  <richard.sandiford@linaro.org>
11179             Alan Hayward  <alan.hayward@arm.com>
11180             David Sherwood  <david.sherwood@arm.com>
11182         * Makefile.in (MACHMODE_H): Remove insn-modes.h
11183         (CORETYPES_H): New define.
11184         (MOSTLYCLEANFILES): Add insn-modes-inline.h.
11185         (insn-modes-inline.h, s-modes-inline-h): New rules.
11186         (generated_files): Add insn-modes-inline.h.
11187         (RTL_BASE_H, TREE_CORE_H): Use CORETYPES_H instead of coretypes.h.
11188         (build/gensupport.o, build/ggc-none.o, build/print-rtl.o): Likewise.
11189         (build/read-md.o, build/read-rtl.o, build/rtl.o): Likewise.
11190         (build/vec.o, build/hash-table.o, build/inchash.o): Likewise.
11191         (build/gencondmd.o, build/genattr.o, build/genattr-common.o): Likewise.
11192         (build/genattrtab.o, build/genautomata.o, build/gencheck.o): Likewise.
11193         (build/gencodes.o, build/genconditions.o): Likewise.
11194         (build/genconfig.o, build/genconstants.o, build/genemit.o): Likewise.
11195         (build/genenums.o, build/genextract.o, build/genflags.o): Likewise.
11196         (build/gentarget-def.o, build/genmddeps.o, build/genopinit.o)
11197         (build/genoutput.o, build/genpeep.o, build/genpreds.o): Likewise.
11198         (build/genrecog.o, build/genmddump.o, build/genmatch.o): Likewise.
11199         (build/gencfn-macros.o, build/gcov-iov.o): Likewise.
11200         * coretypes.h: Include everything up to real.h for generators.
11201         Include insn-modes.h first.  Include wide-int-print.h after
11202         wide-int.h.  Include insn-modes-inline.h and then machmode.h.
11203         * machmode.h: Don't include insn-modes.h here.
11204         * function-tests.c: Remove includes of signop.h, machmode.h,
11205         double-int.h and wide-int.h.
11206         * rtl.h: Likewise.
11207         * gcc-rich-location.c: Remove includes of machmode.h, double-int.h
11208         and wide-int.h.
11209         * optc-save-gen.awk: Likewise.
11210         * gencheck.c (BITS_PER_UNIT): Delete dummy definition.
11211         * godump.c: Remove include of wide-int-print.h.
11212         * pretty-print.h: Likewise.
11213         * wide-int-print.cc: Likewise.
11214         * wide-int.cc: Likewise.
11215         * hash-map-tests.c: Remove include of signop.h.
11216         * hash-set-tests.c: Likewise.
11217         * rtl-tests.c: Likewise.
11218         * mkconfig.sh: Remove include of machmode.h.
11219         * genmodes.c (emit_insn_modes_h): Split emission of inline functions
11220         into...
11221         (emit_insn_modes_inline_h): ...this new function.  Emit the code
11222         into an insn-modes-inline.h header file, adding appropriate
11223         include guards and end comments.
11224         (emit_insn_modes_c_header): Remove include of machmode.h.
11225         (emit_min_insn_modes_c_header): Include coretypes.h rather than
11226         machmode.h.
11227         (main): Handle -i flag and call emit_insn_modes_inline_h when
11228         it is passed.
11230 2017-07-02  Richard Sandiford  <richard.sandiford@linaro.org>
11232         * tree-ssa-strlen.c (strinfo): Rename the length field to
11233         nonzero_chars.  Add a full_string_p field.
11234         (compare_nonzero_chars, zero_length_string_p): New functions.
11235         (get_addr_stridx): Add an offset_out parameter.
11236         Use compare_nonzero_chars.
11237         (get_stridx): Update accordingly.  Use compare_nonzero_chars.
11238         (new_strinfo): Update after above changes to strinfo.
11239         (set_endptr_and_length): Set full_string_p.
11240         (get_string_length): Update after above changes to strinfo.
11241         (unshare_strinfo): Update call to new_strinfo.
11242         (maybe_invalidate): Likewise.
11243         (get_stridx_plus_constant): Change off to unsigned HOST_WIDE_INT.
11244         Use compare_nonzero_chars and zero_string_p.  Treat nonzero_chars
11245         as a uhwi instead of an shwi.  Update after above changes to
11246         strinfo and new_strinfo.
11247         (zero_length_string): Assert that chainsi contains full strings.
11248         Use zero_length_string_p.  Update call to new_strinfo.
11249         (adjust_related_strinfos): Update after above changes to strinfo.
11250         Copy full_string_p from origsi.
11251         (adjust_last_stmt): Use zero_length_string_p.
11252         (handle_builtin_strlen): Update after above changes to strinfo and
11253         new_strinfo.  Install the lhs as the string length if the previous
11254         entry didn't describe a full string.
11255         (handle_builtin_strchr): Update after above changes to strinfo
11256         and new_strinfo.
11257         (handle_builtin_strcpy): Likewise.
11258         (handle_builtin_strcat): Likewise.
11259         (handle_builtin_malloc): Likewise.
11260         (handle_pointer_plus): Likewise.
11261         (handle_builtin_memcpy): Likewise.  Track nonzero characters
11262         that aren't necessarily followed by a nul terminator.
11263         (handle_char_store): Likewise.
11265 2017-07-02  Richard Sandiford  <richard.sandiford@linaro.org>
11267         PR tree-optimization/80769
11268         * tree-ssa-strlen.c (strinfo): Document that "stmt" is also used
11269         for malloc and calloc.  Document the new invariant that all related
11270         strinfos have delayed lengths or none do.
11271         (verify_related_strinfos): Move earlier in file.
11272         (set_endptr_and_length): New function, split out from...
11273         (get_string_length): ...here.  Also set the lengths of related
11274         strinfos.
11275         (zero_length_string): Assert that chainsi has known (rather than
11276         delayed) lengths.
11277         (adjust_related_strinfos): Likewise.
11279 2017-07-02  Richard Sandiford  <richard.sandiford@linaro.org>
11281         PR tree-optimization/81136
11282         * tree-vect-data-refs.c (vect_update_misalignment_for_peel): Only
11283         assert that two references with the same misalignment have the same
11284         compile-time misalignment if those compile-time misalignments
11285         are known.
11287 2017-07-01  Andi Kleen  <ak@linux.intel.com>
11289         * print-tree.c (print_node): Print all attributes.
11291 2017-07-01  Jan Hubicka  <hubicka@ucw.cz>
11293         * cfg.c (scale_bbs_frequencies): New function.
11294         * cfg.h (scale_bbs_frequencies): Declare it.
11295         * cfgloopanal.c (single_likely_exit): Cleanup.
11296         * cfgloopmanip.c (scale_loop_frequencies): Take profile_probability
11297         as parameter.
11298         (scale_loop_profile): Likewise.
11299         (loop_version): Likewise.
11300         (create_empty_loop_on_edge): Update.
11301         * cfgloopmanip.h (scale_loop_frequencies, scale_loop_profile,
11302         scale_loop_frequencies, scale_loop_profile, loopify,
11303         loop_version): Update prototypes.
11304         * modulo-sched.c (sms_schedule): Update.
11305         * predict.c (unlikely_executed_edge_p): Also check probability.
11306         (probably_never_executed_edge_p): Fix typo.
11307         * tree-if-conv.c (version_loop_for_if_conversion): Update.
11308         * tree-parloops.c (gen_parallel_loop): Update.
11309         * tree-ssa-loop-ivcanon.c (try_peel_loop): Update.
11310         * tree-ssa-loop-manip.c (tree_transform_and_unroll_loop): Update.
11311         * tree-ssa-loop-split.c (split_loop): Update.
11312         * tree-ssa-loop-unswitch.c (tree_unswitch_loop): Update.
11313         * tree-vect-loop-manip.c (vect_do_peeling): Update.
11314         (vect_loop_versioning): Update.
11315         * tree-vect-loop.c (scale_profile_for_vect_loop): Update.
11317 2017-07-01  Jan Hubicka  <hubicka@ucw.cz>
11319         * trans-mem.c (split_bb_make_tm_edge): Update profile.
11321 2017-07-01  Jan Hubicka  <hubicka@ucw.cz>
11323         * tree-if-conv.c (combine_blocks): Use make_single_succ_edge
11324         to keep profile consistent.
11326 2017-07-01  Jan Hubicka  <hubicka@ucw.cz>
11328         * cfgrtl.c (rtl_flow_call_edges_add): Update profile.
11329         * tree-cfg.c (gimple_flow_call_edges_add): Likewise.
11330         * profile-count.h (max_safe_multiplier): Make unsigned.
11331         (profile_count::guessed_zero): New.
11333 2017-07-01  Jan Hubicka  <hubicka@ucw.cz>
11335         * bb-reorder.c (fix_up_crossing_landing_pad,
11336         fix_crossing_conditional_branches): Use make_single_succ_edge
11337         to keep profile consistent.
11339 2017-07-01  Jan Hubicka  <hubicka@ucw.cz>
11341         * tree-vect-loop.c (optimize_mask_stores): Use make_single_succ_edge
11342         to update profile.
11344 2017-07-01  Jakub Jelinek  <jakub@redhat.com>
11346         PR sanitizer/81262
11347         * bb-reorder.c (fix_up_fall_thru_edges): Move variable declarations to
11348         the right scopes, make sure cond_jump isn't preserved between multiple
11349         iterations.  Search for fallthru edge whenever there are 3+ edges and
11350         use find_fallthru_edge for it.
11352 2017-06-29  Jan Hubicka  <hubicka@ucw.cz>
11354         Patch by Alexander Monakov <amonakov@ispras.ru>
11355         * sel-sched-ir.c (compute_succs_info): Handle uninitialized
11356         probabilities consistently.
11358 2017-06-29  Jan Hubicka  <hubicka@ucw.cz>
11360         * pa.c (pa_expand_compare_and_swap_loop): Update call of
11361         emit_cmp_and_jump_insns.
11363 2017-06-29  Jan Hubicka  <hubicka@ucw.cz>
11365         PR ipa/81261
11366         * tree-inline.c (expand_call_inline): Combine profile statuses.
11368 2017-06-30  Andrew Pinski  <apinski@cavium.com>
11370         * tree-if-conv.c (predicate_scalar_phi): Update new_stmt if
11371         fold_stmt returned true.
11373 2017-06-30  Nathan Sidwell  <nathan@acm.org>
11375         * ggc.h (empty_string): Delete.
11376         * cfgexpand.c (expand_asm_stmt): Use plain "".
11377         * optabs.c (expand_asm_memory_barrier): Likewise.
11378         * stringpool.c (empty_string): Delete.
11379         (digit_vector, digit_string): Delete.
11380         (ggc_alloc_string): Use plain "", don't optimize single digit
11381         strings.  Use ggc_alloc_atomic.
11383 2017-06-30  Richard Earnshaw  <rearnsha@arm.com>
11385         * rtlanal.c (insn_rtx_cost): If a parallel contains exactly one
11386         comparison set and one other set, use the cost of the non-comparison
11387         set.
11389 2017-06-30  Nathan Sidwell  <nathan@acm.org>
11391         * ggc.h: Replace all 'static inline' with plain 'inline'.  Fix
11392         some formatting.
11394 2017-06-30  Peter Bergner  <bergner@vnet.ibm.com>
11396         * tree-cfg.c (group_case_labels_stmt): Merge scanning and compressing
11397         loops.  Remove now unneeded calls to gimple_switch_set_label() that
11398         just set removed labels to NULL_TREE.
11400 2017-06-30  Aldy Hernandez  <aldyh@redhat.com>
11402         * tree-ssanames.c (set_range_info_raw): Abstract from ...
11403         (set_range_info): ...here.  Only call set_range_info_raw if domain
11404         is useful.
11405         (set_nonzero_bits): Call set_range_info_raw.
11406         * tree-ssanames.h (set_range_info_raw): New.
11408 2017-06-30  Jakub Jelinek  <jakub@redhat.com>
11410         PR target/81225
11411         * config/i386/sse.md (vec_extract_lo_<mode><mask_name>): For V8FI,
11412         V16FI and VI8F_256 iterators, use <store_mask_predicate> instead
11413         of nonimmediate_operand and <store_mask_constraint> instead of m
11414         for the input operand.  For V8FI iterator, always split if input
11415         is a MEM.  For V16FI and V8SF_256 iterators, don't test if both
11416         operands are MEM if <mask_applied>.  For VI4F_256 iterator, use
11417         <store_mask_predicate> instead of register_operand and
11418         <store_mask_constraint> instead of v for the input operand.  Make
11419         sure both operands aren't MEMs for if not <mask_applied>.
11421 2017-06-30  Sylvestre Ledru  <sylvestre@debian.org>
11423         * lto-wrapper.c (copy_file) Close both file descriptors before
11424         exiting normally.
11426 2017-06-30  Martin Liska  <mliska@suse.cz>
11428         PR ipa/81214
11429         * multiple_target.c (create_dispatcher_calls): Make ifunc
11430         also for function that don't have calls or are not referenced.
11432 2017-06-30  Richard Biener  <rguenther@suse.de>
11434         * tree-vect-slp.c (vect_slp_analyze_node_operations): Only
11435         analyze the first scalar stmt.  Move vector type computation
11436         for the BB case here from ...
11437         * tree-vect-stmts.c (vect_analyze_stmt): ... here.  Guard
11438         live operation processing in the SLP case properly.
11440 2017-06-30  Richard Biener  <rguenther@suse.de>
11442         * graph.c (draw_cfg_node_succ_edges): Fix broken dot syntax.
11444 2017-06-30  Martin Liska  <mliska@suse.cz>
11446         PR sanitizer/81021
11447         * tree-eh.c (lower_resx): Call BUILT_IN_ASAN_HANDLE_NO_RETURN
11448         before BUILT_IN_UNWIND_RESUME when ASAN is used.
11450 2017-06-30  Yvan Roux  <yvan.roux@linaro.org>
11452         * doc/invoke.texi (AArch64): Add missing options and remove redundant
11453         ones.
11455 2017-06-30  Richard Biener  <rguenther@suse.de>
11457         PR tree-optimization/81249
11458         * tree-vect-loop.c (vect_create_epilog_for_reduction): Convert
11459         condition reduction result to original scalar type.
11461 2017-06-30  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
11463         * profile-count.h (enum profile_quality): Fix typos and whitespace
11464         issues.
11466 2017-06-30  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
11468         * config/s390/s390.c (s390_expand_setmem): Adjust to the new data
11469         type for branch probabilities.
11471 2017-06-29  Julian Brown  <julian@codesourcery.com>
11472             Naveen H.S  <Naveen.Hurugalawadi@cavium.com>
11474         * config/aarch64/aarch64-fusion-pairs.def: Add ALU_BRANCH entry.
11475         * config/aarch64/aarch64.c (AARCH64_FUSE_ALU_BRANCH): New fusion type.
11476         (thunderx2t99_tunings): Set AARCH64_FUSE_ALU_BRANCH flag.
11477         (aarch_macro_fusion_pair_p): Add support for AARCH64_FUSE_ALU_BRANCH.
11479 2017-06-29  Naveen H.S  <Naveen.Hurugalawadi@cavium.com>
11481         * config/aarch64/aarch64.c (aarch_macro_fusion_pair_p): Push the
11482         check for CC usage into AARCH64_FUSE_CMP_BRANCH.
11483         * config/i386/i386.c (ix86_macro_fusion_pair_p): Push the check for
11484         CC usage from generic code to here.
11485         * sched-deps.c (sched_macro_fuse_insns): Move the condition for
11486         CC usage into the target macros.
11488 2017-06-29  Maya Rashish  <coypu@sdf.org>
11490         * config/netbsd.h (NETBSD_LIB_SPEC): Add -lc when creating shared
11491         objects.
11493 2017-06-29  Jan Hubicka  <hubicka@ucw.cz>
11495         * arm/arm-builtins.c: Include profile-count.h
11496         * except.c (sjlj_emit_function_enter): Use
11497         profile_probability::unlikely.
11499 2017-06-29  Aaron Sawdey  <acsawdey@linux.vnet.ibm.com>
11501         * config/rs6000/rs6000.c (toc_relative_expr_p): Make tocrel_base
11502         and tocrel_offset be pointer args rather than implicitly using
11503         static versions.
11504         (legitimate_constant_pool_address_p, rs6000_emit_move,
11505         const_load_sequence_p, adjust_vperm): Add local tocrel_base and
11506         tocrel_offset and use in toc_relative_expr_p call.
11507         (print_operand, print_operand_address): Use static tocrel_base_oac
11508         and tocrel_offset_oac.
11509         (rs6000_output_addr_const_extra): Use static tocrel_base_oac and
11510         tocrel_offset_oac.
11512 2017-06-29  Maya Rashish  <coypu@sdf.org>
11514         * config/vax/builtins.md (ffssi2_internal): Correct constraint.
11516 2017-06-29  Eric Botcazou  <ebotcazou@adacore.com>
11518         * expr.c (expand_expr) <normal_inner_ref>: When testing for unaligned
11519         objects, take into account only the alignment of 'op0' and 'mode1' if
11520         'op0' is a MEM.
11522 2017-06-29  Steve Ellcey  <sellcey@cavium.com>
11524         * ccmp.c (ccmp_tree_comparison_p): New function.
11525         (ccmp_candidate_p): Update to use above function.
11526         (get_compare_parts): New function.
11527         (expand_ccmp_next): Update to use new functions.
11528         (expand_ccmp_expr_1): Take tree arg instead of gimple, update to use
11529         new functions.
11530         (expand_ccmp_expr): Pass tree instead of gimple to expand_ccmp_expr_1,
11531         take mode as argument.
11532         * ccmp.h (expand_ccmp_expr): Add mode as argument.
11533         * expr.c (expand_expr_real_1): Pass mode as argument.
11535 2017-06-29  Segher Boessenkool  <segher@kernel.crashing.org>
11537         * combine.c (combine_instructions): Print insns to dump_file, together
11538         with their costs.
11540 2017-06-29  Jan Hubicka  <hubicka@ucw.cz>
11542         * asan.c (asan_emit_stack_protection): Update.
11543         (create_cond_insert_point): Update.
11544         * auto-profile.c (afdo_propagate_circuit): Update.
11545         * basic-block.h (struct edge_def): Turn probability to
11546         profile_probability.
11547         (EDGE_FREQUENCY): Update.
11548         * bb-reorder.c (find_traces_1_round): Update.
11549         (better_edge_p): Update.
11550         (sanitize_hot_paths): Update.
11551         * cfg.c (unchecked_make_edge): Initialize probability to uninitialized.
11552         (make_single_succ_edge): Update.
11553         (check_bb_profile): Update.
11554         (dump_edge_info): Update.
11555         (update_bb_profile_for_threading): Update.
11556         * cfganal.c (connect_infinite_loops_to_exit): Initialize new edge
11557         probabilitycount to 0.
11558         * cfgbuild.c (compute_outgoing_frequencies): Update.
11559         * cfgcleanup.c (try_forward_edges): Update.
11560         (outgoing_edges_match): Update.
11561         (try_crossjump_to_edge): Update.
11562         * cfgexpand.c (expand_gimple_cond): Update make_single_succ_edge.
11563         (expand_gimple_tailcall): Update.
11564         (construct_init_block): Use make_single_succ_edge.
11565         (construct_exit_block): Use make_single_succ_edge.
11566         * cfghooks.c (verify_flow_info): Update.
11567         (redirect_edge_succ_nodup): Update.
11568         (split_edge): Update.
11569         (account_profile_record): Update.
11570         * cfgloopanal.c (single_likely_exit): Update.
11571         * cfgloopmanip.c (scale_loop_profile): Update.
11572         (set_zero_probability): Remove.
11573         (duplicate_loop_to_header_edge): Update.
11574         * cfgloopmanip.h (loop_version): Update prototype.
11575         * cfgrtl.c (try_redirect_by_replacing_jump): Update.
11576         (force_nonfallthru_and_redirect): Update.
11577         (update_br_prob_note): Update.
11578         (rtl_verify_edges): Update.
11579         (purge_dead_edges): Update.
11580         (rtl_lv_add_condition_to_bb): Update.
11581         * cgraph.c: (cgraph_edge::redirect_call_stmt_to_calle): Update.
11582         * cgraphunit.c (init_lowered_empty_function): Update.
11583         (cgraph_node::expand_thunk): Update.
11584         * cilk-common.c: Include profile-count.h
11585         * dojump.c (inv): Remove.
11586         (jumpifnot): Update.
11587         (jumpifnot_1): Update.
11588         (do_jump_1): Update.
11589         (do_jump): Update.
11590         (do_jump_by_parts_greater_rtx): Update.
11591         (do_compare_rtx_and_jump): Update.
11592         * dojump.h (jumpifnot, jumpifnot_1, jumpif_1, jumpif, do_jump,
11593         do_jump_1. do_compare_rtx_and_jump): Update prototype.
11594         * dwarf2cfi.c: Include profile-count.h
11595         * except.c (dw2_build_landing_pads): Use make_single_succ_edge.
11596         (sjlj_emit_dispatch_table): Likewise.
11597         * explow.c: Include profile-count.h
11598         * expmed.c (emit_store_flag_force): Update.
11599         (do_cmp_and_jump): Update.
11600         * expr.c (compare_by_pieces_d::generate): Update.
11601         (compare_by_pieces_d::finish_mode): Update.
11602         (emit_block_move_via_loop): Update.
11603         (store_expr_with_bounds): Update.
11604         (store_constructor): Update.
11605         (expand_expr_real_2): Update.
11606         (expand_expr_real_1): Update.
11607         * expr.h (try_casesi, try_tablejump): Update prototypes.
11608         * gimple-pretty-print.c (dump_probability): Update.
11609         (dump_profile): New.
11610         (dump_gimple_label): Update.
11611         (dump_gimple_bb_header): Update.
11612         * graph.c (draw_cfg_node_succ_edges): Update.
11613         * hsa-gen.c (convert_switch_statements): Update.
11614         * ifcvt.c (cheap_bb_rtx_cost_p): Update.
11615         (find_if_case_1): Update.
11616         (find_if_case_2): Update.
11617         * internal-fn.c (expand_arith_overflow_result_store): Update.
11618         (expand_addsub_overflow): Update.
11619         (expand_neg_overflow): Update.
11620         (expand_mul_overflow): Update.
11621         (expand_vector_ubsan_overflow): Update.
11622         * ipa-cp.c (good_cloning_opportunity_p): Update.
11623         * ipa-split.c (split_function): Use make_single_succ_edge.
11624         * ipa-utils.c (ipa_merge_profiles): Update.
11625         * loop-doloop.c (add_test): Update.
11626         (doloop_modify): Update.
11627         * loop-unroll.c (compare_and_jump_seq): Update.
11628         (unroll_loop_runtime_iterations): Update.
11629         * lra-constraints.c (lra_inheritance): Update.
11630         * lto-streamer-in.c (input_cfg): Update.
11631         * lto-streamer-out.c (output_cfg): Update.
11632         * mcf.c (adjust_cfg_counts): Update.
11633         * modulo-sched.c (sms_schedule): Update.
11634         * omp-expand.c (expand_omp_for_init_counts): Update.
11635         (extract_omp_for_update_vars): Update.
11636         (expand_omp_ordered_sink): Update.
11637         (expand_omp_for_ordered_loops): Update.
11638         (expand_omp_for_generic): Update.
11639         (expand_omp_for_static_nochunk): Update.
11640         (expand_omp_for_static_chunk): Update.
11641         (expand_cilk_for): Update.
11642         (expand_omp_simd): Update.
11643         (expand_omp_taskloop_for_outer): Update.
11644         (expand_omp_taskloop_for_inner): Update.
11645         * omp-simd-clone.c (simd_clone_adjust): Update.
11646         * optabs.c (expand_doubleword_shift): Update.
11647         (expand_abs): Update.
11648         (emit_cmp_and_jump_insn_1): Update.
11649         (expand_compare_and_swap_loop): Update.
11650         * optabs.h (emit_cmp_and_jump_insns): Update prototype.
11651         * predict.c (predictable_edge_p): Update.
11652         (edge_probability_reliable_p): Update.
11653         (set_even_probabilities): Update.
11654         (combine_predictions_for_insn): Update.
11655         (combine_predictions_for_bb): Update.
11656         (propagate_freq): Update.
11657         (estimate_bb_frequencies): Update.
11658         (force_edge_cold): Update.
11659         * profile-count.c (profile_count::dump): Add missing space into dump.
11660         (profile_count::debug): Add newline.
11661         (profile_count::differs_from_p): Explicitly convert to unsigned.
11662         (profile_count::stream_in): Update.
11663         (profile_probability::dump): New member function.
11664         (profile_probability::debug): New member function.
11665         (profile_probability::differs_from_p): New member function.
11666         (profile_probability::differs_lot_from_p): New member function.
11667         (profile_probability::stream_in): New member function.
11668         (profile_probability::stream_out): New member function.
11669         * profile-count.h (profile_count_quality): Rename to ...
11670         (profile_quality): ... this one.
11671         (profile_probability): New.
11672         (profile_count): Update.
11673         * profile.c (compute_branch_probabilities): Update.
11674         * recog.c (peep2_attempt): Update.
11675         * sched-ebb.c (schedule_ebbs): Update.
11676         * sched-rgn.c (find_single_block_region): Update.
11677         (compute_dom_prob_ps): Update.
11678         (schedule_region): Update.
11679         * sel-sched-ir.c (compute_succs_info): Update.
11680         * stmt.c (struct case_node): Update.
11681         (do_jump_if_equal): Update.
11682         (get_outgoing_edge_probs): Update.
11683         (conditional_probability): Update.
11684         (emit_case_dispatch_table): Update.
11685         (expand_case): Update.
11686         (expand_sjlj_dispatch_table): Update.
11687         (emit_case_nodes): Update.
11688         * targhooks.c: Update.
11689         * tracer.c (better_p): Update.
11690         (find_best_successor): Update.
11691         * trans-mem.c (expand_transaction): Update.
11692         * tree-call-cdce.c: Update.
11693         * tree-cfg.c (gimple_split_edge): Upate.
11694         (move_sese_region_to_fn): Upate.
11695         * tree-cfgcleanup.c (cleanup_control_expr_graph): Upate.
11696         * tree-eh.c (lower_resx): Upate.
11697         (cleanup_empty_eh_move_lp): Upate.
11698         * tree-if-conv.c (version_loop_for_if_conversion): Update.
11699         * tree-inline.c (copy_edges_for_bb): Update.
11700         (copy_cfg_body): Update.
11701         * tree-parloops.c (gen_parallel_loop): Update.
11702         * tree-profile.c (gimple_gen_ic_func_profiler): Update.
11703         (gimple_gen_time_profiler): Update.
11704         * tree-ssa-dce.c (remove_dead_stmt): Update.
11705         * tree-ssa-ifcombine.c (update_profile_after_ifcombine): Update.
11706         * tree-ssa-loop-im.c (execute_sm_if_changed): Update.
11707         * tree-ssa-loop-ivcanon.c (remove_exits_and_undefined_stmts): Update.
11708         (unloop_loops): Update.
11709         (try_peel_loop): Update.
11710         * tree-ssa-loop-manip.c (tree_transform_and_unroll_loop): Update.
11711         * tree-ssa-loop-split.c (connect_loops): Update.
11712         (split_loop): Update.
11713         * tree-ssa-loop-unswitch.c (tree_unswitch_loop): Update.
11714         (hoist_guard): Update.
11715         * tree-ssa-phionlycprop.c (propagate_rhs_into_lhs): Update.
11716         * tree-ssa-phiopt.c (replace_phi_edge_with_variable): Update.
11717         (value_replacement): Update.
11718         * tree-ssa-reassoc.c (branch_fixup): Update.
11719         * tree-ssa-tail-merge.c (replace_block_by): Update.
11720         * tree-ssa-threadupdate.c (remove_ctrl_stmt_and_useless_edges): Update.
11721         (create_edge_and_update_destination_phis): Update.
11722         (compute_path_counts): Update.
11723         (recompute_probabilities): Update.
11724         (update_joiner_offpath_counts): Update.
11725         (freqs_to_counts_path): Update.
11726         (duplicate_thread_path): Update.
11727         * tree-switch-conversion.c (hoist_edge_and_branch_if_true): Update.
11728         (struct switch_conv_info): Update.
11729         (gen_inbound_check): Update.
11730         * tree-vect-loop-manip.c (slpeel_add_loop_guard): Update.
11731         (vect_do_peeling): Update.
11732         (vect_loop_versioning): Update.
11733         * tree-vect-loop.c (scale_profile_for_vect_loop): Update.
11734         (optimize_mask_stores): Update.
11735         * ubsan.c (ubsan_expand_null_ifn): Update.
11736         * value-prof.c (gimple_divmod_fixed_value): Update.
11737         (gimple_divmod_fixed_value_transform): Update.
11738         (gimple_mod_pow2): Update.
11739         (gimple_mod_pow2_value_transform): Update.
11740         (gimple_mod_subtract): Update.
11741         (gimple_mod_subtract_transform): Update.
11742         (gimple_ic): Update.
11743         (gimple_stringop_fixed_value): Update.
11744         (gimple_stringops_transform): Update.
11745         * value-prof.h: Update.
11747 2017-06-29  Carl Love  <cel@us.ibm.com>
11749         * config/rs6000/rs6000-c.c: Add support for built-in functions
11750         vector signed int vec_signed (vector float);
11751         vector signed long long vec_signed (vector double);
11752         vector signed int vec_signed2 (vector double, vector double);
11753         vector signed int vec_signede (vector double);
11754         vector signed int vec_signedo (vector double);
11755         * config/rs6000/rs6000.c (rs6000_generate_vsigned2_code): Add
11756         instruction generator.
11757         * config/rs6000/vsx.md (UNSPEC_VSX_XVCVSPSXWS, UNSPEC_VSX_XVCVSPSXDS,
11758         UNSPEC_VSX_VSIGNED2): Add UNSPECS.
11759         (vsx_xvcvspsxws, vsx_xvcvdpuxds_scale, vsx_xvcvspuxws, vsigned2_v2df):
11760         Add define_insn.
11761         (vsignedo_v2df, vsignede_v2df, vunsigned2_v2df, vunsignedo_v2df,
11762         vunsignede_v2df): Add define_expands.
11763         * config/rs6000/rs6000-builtin.def (VEC_SIGNED, VEC_UNSIGNED,
11764         VEC_SIGNED2, VEC_UNSIGNED2, VEC_SIGNEDE, VEC_UNSIGNEDE, VEC_SIGNEDO,
11765         VEC_UNSIGNEDO): Add definitions.
11766         * config/vsx.md (UNSPEC_VSX_XVCVSPSXWS, UNSPEC_VSX_XVCVSPSXDS,
11767         UNSPEC_VSX_VSIGNED2): Add UNSPECs.
11768         (vsx_xvcvspsxws, vsx_xvcvspuxws): Add define_insn.
11769         (vsigned2_v2df, vsigendo_v2df, vsignede_v2df,
11770         vunsigned2_v2df, vunsignedo_v2df, vunsignede_v2df): Add define_expands.
11771         * config/rs6000/altivec.h (vec_signed, vec_signed2,
11772         vec_signede and vec_signedo, vec_unsigned, vec_unsigned2,
11773         vec_unsignede, vec_unsignedo): Add builtin defines.
11774         * config/rs6000-protos.h (rs6000_generate_vsigned2_code): Add extern
11775         declaration.
11776         * doc/extend.texi: Update the built-in documentation file for the
11777         new built-in functions.
11779 2017-06-29  Richard Biener  <rguenther@suse.de>
11781         * tree-vect-loop.c (vect_analyze_scalar_cycles_1): Do not add
11782         reduction chains to LOOP_VINFO_REDUCTIONS.
11783         * tree-vect-slp.c (vect_analyze_slp): Continue looking for
11784         SLP reductions after processing reduction chains.
11786 2017-06-29  Nathan Sidwell  <nathan@acm.org>
11788         * builtins.c (fold_builtin_FUNCTION): Use
11789         lang_hooks.decl_printable_name.
11791 2017-06-29  Peter Bergner  <bergner@vnet.ibm.com>
11793         PR middle-end/81194
11794         * cfgexpand.c (expand_gimple_stmt_1): Handle switch statements
11795         with only one label.
11796         * stmt.c (expand_case): Assert NCASES is greater than one.
11798 2017-06-29  Richard Biener  <rguenther@suse.de>
11800         * tree-cfg.c (group_case_labels_stmt): Return whether we changed
11801         anything.
11802         (group_case_labels): Likewise.
11803         (find_taken_edge): Push sanity checking on val to workers...
11804         (find_taken_edge_cond_expr): ... here
11805         (find_taken_edge_switch_expr): ... and here, handle cases
11806         with just a default label.
11807         * tree-cfg.h (group_case_labels_stmt): Adjust prototype.
11808         (group_case_labels): Likewise.
11809         * tree-cfgcleanup.c (execute_cleanup_cfg_post_optimizing): When
11810         group_case_labels does anything cleanup the CFG again.
11812 2017-06-29  Bin Cheng  <bin.cheng@arm.com>
11814         PR tree-optimization/81196
11815         * tree-ssa-loop-niter.c (number_of_iterations_cond): Handle loop
11816         exit condition comparing two IVs.
11818 2017-06-29  Richard Earnshaw  <rearnsha@arm.com>
11820         * config/arm/parsecpu.awk (gen_comm_data): Add initializer for
11821         profile to the dummy entry at the end of the list of architectures.
11822         * config/arm/arm-cpu-cdata.h: Regenerated.
11824 2017-06-29  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
11825             Michael Collison <michael.collison@arm.com>
11827         PR target/70119
11828         * config/aarch64/aarch64.md (*aarch64_<optab>_reg_<mode>3_mask1):
11829         New pattern.
11830         (*aarch64_reg_<mode>3_neg_mask2): New pattern.
11831         (*aarch64_reg_<mode>3_minus_mask): New pattern.
11832         (*aarch64_<optab>_reg_di3_mask2): New pattern.
11833         * config/aarch64/aarch64.c (aarch64_rtx_costs): Account for cost
11834         of shift when the shift amount is masked with constant equal to
11835         the size of the mode.
11836         * config/aarch64/predicates.md (subreg_lowpart_operator): New
11837         predicate.
11839 2017-06-29  Martin Liska  <mliska@suse.cz>
11841         * config/i386/i386.opt: Change range from [1,5] to [0,5].
11843 2017-06-29  Yury Gribov  <tetra2005@gmail.com>
11845         PR bootstrap/80565
11846         * ipa-cp.c (allocate_and_init_ipcp_value): Add initialization
11847         code.
11848         * ipa-inline.h
11849         (edge_growth_cache_entry::edge_growth_cache_entry): New
11850         function.
11851         (reset_edge_growth_cache): Update to use constructor.
11853 2017-06-28  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
11855         * config/aarch64/aarch64.h (AARCH64_EXPAND_ALIGNMENT): New.
11856         (DATA_ALIGNMENT): Update to use AARCH64_EXPAND_ALIGNMENT.
11857         (LOCAL_ALIGNMENT): Update to use AARCH64_EXPAND_ALIGNMENT.
11859 2017-06-28  Sebastian Peryt  <sebastian.peryt@intel.com>
11861         * config/i386/avx512vlintrin.h (_mm256_permutexvar_epi64)
11862         (_mm256_permutexvar_epi32, _mm256_permutex_epi64): New intrinsics.
11864 2017-06-28  Szabolcs Nagy  <szabolcs.nagy@arm.com>
11866         * config.gcc (*-linux-musl*): Add t-musl tmake_file.
11867         (*-linux-uclibc*): Add t-uclibc tmake_file.
11868         * config/t-musl: New.
11869         * config/t-uclibc: New.
11871 2017-06-28  Richard Earnshaw  <rearnsha@arm.com>
11873         * config/arm/parsecpu.awk (profile): Parse new keyword in an arch
11874         context.
11875         (gen_comm_data): Emit architectural setting of arch_prof.
11876         * config/arm/arm-cpus.in (armv6-m, armv6s-m, armv7-a, armv7ve): Set the
11877         profile.
11878         (armv7-r, armv7-m, armv7e-m, armv8-a, armv8.1-a, armv8.2-a): Likewise.
11879         (armv8-m.base, armv8-m.main): Likewise.
11880         * arm-protos.h (arm_build_target): Add profile field.
11881         (arch_option): Likewise.
11882         * config/arm/arm.c (arm_configure_build_target): Copy the profile to
11883         the active target.
11884         * config/arm/arm.h (TARGET_ARM_ARCH_PROFILE): Use
11885         arm_active_target.profile.
11887 2017-06-28  Richard Biener  <rguenther@suse.de>
11889         PR middle-end/81227
11890         * fold-const.c (negate_expr_p): Use TYPE_UNSIGNED, not
11891         TYPE_OVERFLOW_WRAPS.
11892         * match.pd (negate_expr_p): Likewise.
11893         * tree-ssa-reassoc.c (optimize_range_tests_diff): Use
11894         fold_build2, not fold_binary.
11896 2017-06-28  Wilco Dijkstra  <wdijkstr@arm.com>
11898         * config/aarch64/aarch64 (aarch64_expand_mov_immediate):
11899         Convert memory address to Pmode.
11900         (aarch64_print_operand): Assert MEM operands are always Pmode.
11902 2017-06-28  Wilco Dijkstra  <wdijkstr@arm.com>
11904         PR target/79665
11905         * config/arm/aarch-common.c (arm_no_early_alu_shift_dep):
11906         Remove redundant if.
11907         (aarch_forward_to_shift_is_not_shifted_reg): Remove.
11908         * config/arm/aarch-common-protos.h
11909         (aarch_forward_to_shift_is_not_shifted_re): Remove.
11910         * config/arm/cortex-a53.md: Use arm_no_early_alu_shift_dep in bypass.
11912 2017-06-28  Michael Meissner  <meissner@linux.vnet.ibm.com>
11914         PR ipa/81238
11915         * multiple_target.c (create_dispatcher_calls): Set the default
11916         clone to be static, not public.
11918 2017-06-28  Richard Biener  <rguenther@suse.de>
11920         * tree-vect-loop.c (vectorizable_reduction): Move special
11921         cond reduction IV var creation ...
11922         (vect_create_epilog_for_reduction): ... here.  Remove induction_index
11923         parameter.  Use STMT_VINFO_VECTYPE.
11924         * tree-vect-slp.c (vect_get_constant_vectors): Properly reset
11925         constant_p.
11927 2017-06-28  Martin Liska  <mliska@suse.cz>
11929         PR ipa/81128
11930         * ipa-visibility.c (non_local_p): Handle visibility.
11932 2017-06-28  Martin Liska  <mliska@suse.cz>
11934         PR driver/79659
11935         * common.opt: Add IntegerRange to various options.
11936         * opt-functions.awk (integer_range_info): New function.
11937         * optc-gen.awk: Add integer_range_info to cl_options struct.
11938         * opts-common.c (decode_cmdline_option): Handle
11939         CL_ERR_INT_RANGE_ARG.
11940         (cmdline_handle_error): Likewise.
11941         * opts.c (print_filtered_help): Show valid interval in
11942         when --help is provided.
11943         * opts.h (struct cl_option): Add range_min and range_max fields.
11944         * config/i386/i386.opt: Add IntegerRange for -mbranch-cost.
11946 2017-06-28  Marc Glisse  <marc.glisse@inria.fr>
11948         * match.pd ((X & ~Y) | (~X & Y)): Generalize to + and ^.
11949         (x * C EQ/NE y * C): New transformation.
11951 2017-06-28  Christophe Lyon  <christophe.lyon@linaro.org>
11953         * genmultilib (combination_space): Accept '+' in option names.
11955 2017-06-28  Martin Liska  <mliska@suse.cz>
11957         PR sanitizer/81224
11958         * asan.c (instrument_derefs): Bail out inner references
11959         that are hard register variables.
11961 2017-06-28  Jakub Jelinek  <jakub@redhat.com>
11963         PR target/81175
11964         * config/i386/i386.c (ix86_init_mmx_sse_builtins): Use def_builtin
11965         rather than def_builtin_pure for __builtin_ia32_gatherpf*.
11967 2017-06-28  Richard Biener  <rguenther@suse.de>
11969         * tree-vectorizer.h (vect_get_vec_defs): Remove.
11970         (vect_get_slp_defs): Adjust.
11971         * tree-vect-loop.c (get_initial_defs_for_reduction): Split
11972         out from ...
11973         * tree-vect-slp.c (vect_get_constant_vectors): ... here and
11974         simplify.
11975         * tree-vect-loop.c (vect_create_epilog_for_reduction): Use
11976         get_initial_defs_for_reduction instead of vect_get_vec_defs.
11977         (vectorizable_reduction): Adjust.
11978         * tree-vect-slp.c (vect_get_constant_vectors): Remove reduction
11979         handling.
11980         (vect_get_slp_defs): Likewise.
11981         * tree-vect-stmts.c (vect_get_vec_defs): Make static and adjust.
11982         (vectorizable_bswap): Adjust.
11983         (vectorizable_call): Likewise.
11984         (vectorizable_conversion): Likewise.
11985         (vectorizable_assignment): Likewise.
11986         (vectorizable_shift): Likewise.
11987         (vectorizable_operation): Likewise.
11988         (vectorizable_store): Likewise.
11989         (vectorizable_condition): Likewise.
11990         (vectorizable_comparison): Likewise.
11992 2017-06-28  Michael Collison  <michael.collison@arm.com>
11994         PR target/68535
11995         * config/arm/arm.c (gen_ldm_seq): Remove last unnecessary
11996         set of base_reg
11997         (arm_gen_movmemqi): Removed unused variable 'i'.
11998         Convert 'for' loop into 'while' loop.
11999         (arm_expand_prologue): Remove last unnecessary set of insn.
12000         (thumb_pop): Remove unused variable 'pushed_words'.
12001         (thumb_exit): Remove last unnecessary set of regs_to_pop.
12003 2017-06-28  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
12005         * config/s390/predicates.md: Use s390_rel_address_ok_p.
12006         * config/s390/s390-protos.h: Add prototype of
12007         s390_rel_address_ok_p.
12008         * config/s390/s390.c (s390_got_symbol): New function.
12009         (s390_rel_address_ok_p): New function.
12010         (legitimize_pic_address): Use s390_rel_address_ok_p.
12011         (s390_load_got): Use s390_got_symbol.
12012         (s390_option_override): Issue error if
12013         -mno-pic-data-is-text-relative is used without -fpic/-fPIC.
12014         * config/s390/s390.h (TARGET_DEFAULT_PIC_DATA_IS_TEXT_RELATIVE):
12015         New macro.
12016         * config/s390/s390.opt: New option mpic-data-is-text-relative.
12018 2017-06-27  Andrew Pinski  <apinski@cavium.com>
12020         * match.pd (X >/>=/</<= 0 ? 1.0 : -1.0): New patterns.
12021         (X * copysign (1.0, X)): New pattern.
12022         (X * copysign (1.0, -X)): New pattern.
12023         (copysign (-1.0, CST)): New pattern.
12025 2017-06-27  Joseph Myers  <joseph@codesourcery.com>
12027         * genmultilib (combination_space): Remove variable.
12028         Validate reuse rules against regular expression for any sequence
12029         of multilib options in any order.
12031 2017-06-27  Michael Collison  <michael.collison@arm.com>
12033         * config/aarch64/aarch64-simd.md (aarch64_combine<mode>): Directly
12034         call aarch64_split_simd_combine.
12035         * (aarch64_combine_internal<mode>): Delete pattern.
12036         * config/aarch64/aarch64.c (aarch64_split_simd_combine):
12037         Allow register and subreg operands.
12039 2017-06-27  Jerome Lambourg  <lambourg@adacore.com>
12041         * config/i386/vxworks.h (ASM_SPEC): Remove definition. No target
12042         specific need, just fallback on defaults.
12043         (ASM_OUTPUT_ALIGNED_BSS): Add #undef before #define.
12045 2017-06-27  Jerome Lambourg  <lambourg@adacore.com>
12046             Olivier Hainque  <hainque@adacore.com>
12048         * config/i386/vxworks.h (DBX_REGISTER_NUMBER): Pick distinct
12049         map for 64bits.
12050         (TARGET_OS_CPP_BUILTINS): builtin_define CPU to X86_64 for 64bit
12051         targets. Pick a default if no particular attempt applied.
12052         (STACK_CHECK_PROTECT): Double for 64bit targets, which have
12053         larger contexts.
12055 2017-06-27  Jerome Lambourg  <lambourg@adacore.com>
12057         * config.gcc (i*86-wrs-vxworks7): Handle new acceptable triplet.
12058         (x86_64-wrs-vxworks7): Likewise.
12060 2017-06-27  Marek Polacek  <polacek@redhat.com>
12062         PR sanitizer/81223
12063         * ubsan.c (instrument_null): Check get_base_address's result for null.
12065 2017-06-27  Marc Glisse  <marc.glisse@inria.fr>
12067         * match.pd ((A+-B)+(C-A), (A+B)-(A-C)): New transformations.
12069 2017-06-27  Marc Glisse  <marc.glisse@inria.fr>
12071         * builtin-types.def (BT_FENV_T_PTR, BT_CONST_FENV_T_PTR,
12072         BT_FEXCEPT_T_PTR, BT_CONST_FEXCEPT_T_PTR): New primitive types.
12073         (BT_FN_INT_FENV_T_PTR, BT_FN_INT_CONST_FENV_T_PTR,
12074         BT_FN_INT_FEXCEPT_T_PTR_INT, BT_FN_INT_CONST_FEXCEPT_T_PTR_INT):
12075         New function types.
12076         * builtins.def (BUILT_IN_FECLEAREXCEPT, BUILT_IN_FEGETENV,
12077         BUILT_IN_FEGETEXCEPTFLAG, BUILT_IN_FEGETROUND,
12078         BUILT_IN_FEHOLDEXCEPT, BUILT_IN_FERAISEEXCEPT,
12079         BUILT_IN_FESETENV, BUILT_IN_FESETEXCEPTFLAG,
12080         BUILT_IN_FESETROUND, BUILT_IN_FETESTEXCEPT,
12081         BUILT_IN_FEUPDATEENV): New builtins.
12082         * tree-core.h (TI_FENV_T_PTR_TYPE, TI_CONST_FENV_T_PTR_TYPE,
12083         TI_FEXCEPT_T_PTR_TYPE, TI_CONST_FEXCEPT_T_PTR_TYPE): New entries.
12084         * tree.h (fenv_t_ptr_type_node, const_fenv_t_ptr_type_node,
12085         fexcept_t_ptr_type_node, const_fexcept_t_ptr_type_node): New
12086         macros.
12087         (builtin_structptr_types): Adjust size.
12088         * tree.c (builtin_structptr_types): Add four entries.
12090 2017-06-27  Jerome Lambourg  <lambourg@adacore.com>
12091             Olivier Hainque  <hainque@adacore.com>
12093         * config/vxworks.h (VXWORKS_LIB_SPEC): Incorporate ...
12094         (TLS_SYM): New local macro, forcing reference to __tls__ on
12095         link command lines for VxWorks 7 RTPs, triggering initialization
12096         of tlsLib.
12097         (VXWORKS_HAVE_TLS): New macro. State whether the target VxWorks
12098         OS features TLS support, true for RTPs on VxWorks 7.
12099         * config/vxworks.c (vxworks_override_options): Setup emutls
12100         accordingly.
12102 2017-06-27  Jakub Jelinek  <jakub@redhat.com>
12104         * predict.c (test_prediction_value_range): Use -1U instead of -1
12105         to avoid narrowing conversion warning.
12106         * dumpfile.c (dump_options): Wrap all value into dump_flags_t cast
12107         to avoid narrowing conversion warning.
12108         * opt-functions.awk (var_ref): Return (unsigned short) -1 instead of
12109         -1.
12110         * optc-gen.awk (END): Expect (unsigned short) -1 instead of -1.
12112 2017-06-27  Jerome Lambourg  <lambourg@adacore.com>
12114         * config/vxworks.h (VXWORKS_LIBS_RTP): Alternative definition for
12115         64bit configurations.
12116         (PTR_DIFF_TYPE): Alternative definition for TARGET_LP64.
12117         (SIZE_TYPE): Likewise.
12118         * config/vxworks.c (vxworks_emutls_var_fields): Use
12119         long_unsigned_type_node instead of unsigned_type_node as the offset
12120         field type, which is "pointer" mode in emutls.c.
12122 2017-06-27  Jakub Jelinek  <jakub@redhat.com>
12124         PR sanitizer/81209
12125         * ubsan.c (ubsan_encode_value): Initialize DECL_CONTEXT on var.
12127         PR middle-end/81207
12128         * gimple-fold.c (replace_call_with_call_and_fold): Handle
12129         gimple_vuse copying separately from gimple_vdef copying.
12131 2017-06-27  Prathamesh Kulkarni  <prathamesh.kulkarni@linaro.org>
12133         * value-prof.c (free_hist): Remove call to memset and the enclosing if
12134         condition.
12136 2017-06-26  Jerome Lambourg  <lambourg@adacore.com>
12137             Olivier Hainque  <hainque@adacore.com>
12139         * config.gcc (*-*-vxworks*): Add TARGET_VXWORKS7=1 to tm_defines
12140         for all vxworks7 targets.
12141         * config/vxworks.h (TARGET_VXWORKS7): If not defined, define to 0.
12142         (VXWORKS_ADDITIONAL_CPP_SPEC): Alternative definition for VXWORKS7.
12143         (VXWORKS_LIBS_RTP, VXWORKS_LIBS_RTP_DIR): New macros, allowing
12144         variations for VX6/VX7 and 32/64bits later on in ...
12145         (VXWORKS_LIB_SPEC): Leverage new macros.
12146         (VXWORKS_OS_CPP_BUILTINS): Define _VSB_CONFIG_FILE for VXWORKS7,
12147         as well as _ALLOW_KEYWORD_MACROS when "inline" is not a keyword.
12149 2017-06-26  Jerome Lambourg  <lambourg@adacore.com>
12151         * config/vxworks.h (VXWORKS_OS_CPP_BUILTINS): builtin_define
12152         _VX_TOOL_FAMILY and _VX_TOOL to gnu.
12154 2017-06-26  Carl Love  <cel@us.ibm.com>
12156         * config/rs6000/rs6000-c.c: Add support for built-in functions
12157         vector bool char vec_reve (vector bool char);
12158         vector signed char vec_reve (vector signed char);
12159         vector unsigned char vec_reve (vector unsigned char);
12160         vector bool int vec_reve (vector bool int);
12161         vector signed int vec_reve (vector signed int);
12162         vector unsigned int vec_reve (vector unsigned int);
12163         vector bool long long vec_reve (vector bool long long);
12164         vector signed long long vec_reve (vector signed long long);
12165         vector unsigned long long vec_reve (vector unsigned long long);
12166         vector bool short vec_reve (vector bool short);
12167         vector signed short vec_reve (vector signed short);
12168         vector double vec_reve (vector double);
12169         vector float vec_reve (vector float);
12170         * config/rs6000/rs6000-builtin.def (VREVE_V2DI, VREVE_V4SI,
12171         VREVE_V8HI, VREVE_V16QI, VREVE_V2DF, VREVE_V4SF, VREVE): New builtin.
12172         * config/rs6000/altivec.md (UNSPEC_VREVEV): New UNSPEC.
12173         (altivec_vreve): New pattern.
12174         * config/rs6000/altivec.h (vec_reve): New define.
12175         * doc/extend.texi (vec_rev): Update the built-in documentation file
12176         for the new built-in functions.
12178 2016-06-26  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
12180         PR tree-optimization/71815
12181         * gimple-ssa-strength-reduction.c (uses_consumed_by_stmt): New
12182         function.
12183         (find_basis_for_candidate): Call uses_consumed_by_stmt rather than
12184         has_single_use.
12185         (slsr_process_phi): Likewise.
12186         (replace_uncond_cands_and_profitable_phis): Don't replace a
12187         multiply candidate with a stride of 1 (copy or cast).
12188         (phi_incr_cost): Call uses_consumed_by_stmt rather than
12189         has_single_use.
12190         (lowest_cost_path): Likewise.
12191         (total_savings): Likewise.
12193 2017-06-26  Richard Biener  <rguenther@suse.de>
12195         PR target/81175
12196         * config/i386/i386.c (ix86_init_mmx_sse_builtins):
12197         Use def_builtin_pure for all gather builtins.
12199 2017-06-26  Richard Biener  <rguenther@suse.de>
12201         PR tree-optimization/81203
12202         * tree-tailcall.c (find_tail_calls): Do not move stmts into
12203         non-dominating BBs.
12205 2017-06-26  Marek Polacek  <polacek@redhat.com>
12207         PR c/80116
12208         * doc/invoke.texi: Document -Wmultistatement-macros.
12210 2017-06-26  Christophe Lyon  <christophe.lyon@linaro.org>
12212         * doc/sourcebuild.texi (ARM-specific attributes): Document new
12213         arm_neon_ok_no_float_abi effective target.
12215 2017-06-26  Richard Biener  <rguenther@suse.de>
12217         PR tree-optimization/80928
12218         * cfghooks.c (duplicate_block): Do not copy BB_DUPLICATED flag.
12219         (copy_bbs): Set BB_DUPLICATED flag early.
12220         (execute_on_growing_pred): Do not execute for BB_DUPLICATED
12221         marked blocks.
12222         (execute_on_shrinking_pred): Likewise.
12223         * tree-ssa.c (ssa_redirect_edge): Do not look for PHI args in
12224         BB_DUPLICATED blocks.
12225         * tree-ssa-phionlycoprop.c (eliminate_degenerate_phis_1): Properly
12226         iterate over all PHIs considering removal of *gsi.
12228 2017-06-23  Jim Wilson  <jim.wilson@linaro.org>
12230         * doc/invoke.texi (AArch64 Options, -mtune): Re-add falkor and
12231         qdf24xx.
12233 2017-06-23  Aaron Sawdey  <acsawdey@linux.vnet.ibm.com>
12235         * config/rs6000/rs6000-string.c: (expand_block_clear,
12236         do_load_for_compare, select_block_compare_mode,
12237         compute_current_alignment, expand_block_compare,
12238         expand_strncmp_align_check, expand_strn_compare,
12239         expand_block_move, rs6000_output_load_multiple)
12240         Move functions related to string/block move/compare
12241         to a separate file.
12242         * config/rs6000/rs6000.c: Move above functions to rs6000-string.c.
12243         * config/rs6000/rs6000-protos.h (rs6000_emit_dot_insn): Add prototype
12244         for this function which is now used in two files.
12245         * config/rs6000/t-rs6000: Add rule to compile rs6000-string.o.
12246         * config.gcc: Add rs6000-string.o to extra_objs for
12247         targets powerpc*-*-* and rs6000*-*-*.
12249 2017-06-23  Michael Meissner  <meissner@linux.vnet.ibm.com>
12251         PR target/80510
12252         * config/rs6000/rs6000.md (ALTIVEC_DFORM): Do not allow DImode in
12253         32-bit, since indexed is not valid for DImode.
12254         (mov<mode>_hardfloat32): Reorder ISA 2.07 load/stores before ISA
12255         3.0 d-form load/stores to be the same as mov<mode>_hardfloat64.
12256         (define_peephole2 for Altivec d-form load): Add 32-bit support.
12257         (define_peephole2 for Altivec d-form store): Likewise.
12259         PR ipa/81185
12260         * multiple_target.c (create_dispatcher_calls): Only create the
12261         dispatcher call if the function is the default clone of a
12262         versioned function.
12264 2017-06-23  Segher Boessenkool  <segher@kernel.crashing.org>
12266         PR middle-end/80902
12267         * builtins.c (expand_builtin_atomic_fetch_op): If emitting code after
12268         a call, force the call to not be a tail call.
12270 2017-06-23  Jeff Law  <law@redhat.com>
12272         * doc/contrib.texi: Add entry for Steven Pemberton's work on
12273         enquire.
12275 2017-06-23  Will Schmidt  <will_schmidt@vnet.ibm.com>
12277         * config/rs6000/rs6000.c: Add include of ssa-propagate.h for
12278         update_call_from_tree().  (rs6000_gimple_fold_builtin): Add
12279         handling for early expansion of vector shifts (sl,sr,sra,rl).
12280         (builtin_function_type): Add vector shift right instructions
12281         to the unsigned argument list.
12283 2017-06-23  Bernd Edlinger  <bernd.edlinger@hotmail.de>
12285         rtl-optimizatoin/79286
12286         * ira.c (update_equiv_regs): Revert to using may_trap_or_fault_p again.
12287         * rtlanal.c (rtx_addr_can_trap_p_1): SYMBOL_REF_FUNCTION_P can never
12288         trap.  PIC register plus a const unspec without offset can never trap.
12290 2017-06-23  Marc Glisse  <marc.glisse@inria.fr>
12292         * tree.h (builtin_structptr_type): New type.
12293         (builtin_structptr_types): Declare new array.
12294         * tree.c (builtin_structptr_types): New array.
12295         (free_lang_data, build_common_tree_nodes): Use it.
12297 2017-06-23  Jonathan Wakely  <jwakely@redhat.com>
12299         PR c++/81187
12300         * doc/invoke.texi (-Wnoexcept-type): Fix name of option, from
12301         -Wnoexcept.
12303 2017-06-22  Matt Turner  <mattst88@gmail.com>
12305         * config/i386/driver-i386.c (host_detect_local_cpu): Add Kaby
12306         Lake models to skylake case.  Assume skylake for unknown
12307         models with clflushopt.
12309 2017-06-22  Jeff Law  <law@redhat.com>
12311         * config/aarch64/aarch64.c (aarch64_emit_probe_stack_range): Handle
12312         frame sizes that do not satisfy aarch64_uimm12_shift.
12314 2017-06-22  Jan Hubicka <hubicka@ucw.cz>
12316         * profile-count.h (apply_probability,
12317         apply_scale, probability_in): Fix checks for zero.
12319 2017-06-22  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
12321         * incpath.c (add_sysroot_to_chain): Allow for $SYSROOT prefix.
12322         * doc/cppdiropts.texi (-I @var{dir}): Document it.
12324 2016-06-22  Richard Biener  <rguenther@suse.de>
12326         * tree-vect-loop.c (vect_model_reduction_cost): Handle
12327         COND_REDUCTION and INTEGER_INDUC_COND_REDUCTION without
12328         REDUC_MAX_EXPR support.
12329         (vectorizable_reduction): Likewise.
12330         (vect_create_epilog_for_reduction): Likewise.
12332 2017-06-22  James Greenhalgh  <james.greenhalgh@arm.com>
12334         * match.pd (A / (1 << B) -> A >> B): New.
12335         * generic-match-head.c: Include optabs-tree.h.
12336         * gimple-match-head.c: Likewise.
12337         * optabs-tree.h (target_supports_op_p): New.
12338         * optabs-tree.c (target_supports_op_p): New.
12340 2017-06-22  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
12342         * configure.ac (gcc_cv_ld_static_dynamic): Also check stderr for
12343         $gcc_cv_ld --help output.
12344         (gcc_cv_ld_demangle): Likewise.
12345         (gcc_cv_ld_eh_frame_hdr): Likewise.
12346         (gcc_cv_ld_pie): Likewise.
12347         (gcc_cv_ld_as_needed): Likewise.  Prefer native forms unless $gnu_ld.
12348         (gcc_cv_ld_buildid): Likewise.
12349         (gcc_cv_ld_sysroot): Likewise.
12350         (ld_bndplt_support): Likewise.
12351         (ld_pushpopstate_support): Likewise.
12352         * configure: Regenerate.
12353         * config/sol2.h [!USE_GLD] (SYSROOT_SPEC): Define.
12355 2017-06-21  Jakub Jelinek  <jakub@redhat.com>
12357         PR target/81151
12358         * config/i386/sse.md (round<mode>2): Renumber match_dup and
12359         operands indexes to avoid gap between operands and match_dups.
12361 2017-06-21  Andrew Pinski  <apinski@cavium.com>
12363         * config/aarch64/aarch64-cost-tables.h (thunderx_extra_costs):
12364         Increment Arith_shift and Arith_shift_reg by 1.
12365         * config/aarch64/aarch64-tuning-flags.def (cheap_shift_extend):
12366         New tuning flag.
12367         * config/aarch64/aarch64.c (thunderx_tunings): Enable
12368         AARCH64_EXTRA_TUNE_CHEAP_SHIFT_EXTEND.
12369         (aarch64_strip_extend): Add new argument and test for it.
12370         (aarch64_cheap_mult_shift_p): New function.
12371         (aarch64_rtx_mult_cost): Call aarch64_cheap_mult_shift_p and don't
12372         add a cost if it is true.
12373         Update calls to aarch64_strip_extend.
12374         (aarch64_rtx_costs): Update calls to aarch64_strip_extend.
12376 2017-06-21  Andrew Pinski  <apinski@cavium.com>
12378         * config/aarch64/aarch64-cores.def (thunderxt88p1): Use thunderxt88
12379         tunings.
12380         (thunderxt88): Likewise.
12381         * config/aarch64/aarch64.c (thunderxt88_prefetch_tune): New variable.
12382         (thunderx_prefetch_tune): New variable.
12383         (thunderx2t99_prefetch_tune): Update for the correct values.
12384         (thunderxt88_tunings): New variable.
12385         (thunderx_tunings): Use thunderx_prefetch_tune instead of
12386         generic_prefetch_tune.
12387         (thunderx2t99_tunings): Use AUTOPREFETCHER_WEAK.
12389 2017-06-21  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
12391         * config/aarch64/atomics.md (aarch64_compare_and_swap<mode>_lse,
12392         SHORT): Relax operand 3 to aarch64_reg_or_zero and constraint to Z.
12393         (aarch64_compare_and_swap<mode>_lse, GPI): Likewise.
12394         (aarch64_atomic_cas<mode>, SHORT): Likewise for operand 2.
12395         (aarch64_atomic_cas<mode>, GPI): Likewise.
12397 2017-06-21  Martin Liska  <mliska@suse.cz>
12399         * gimplify.c (gimplify_label_expr): Insert GIMPLE_PREDICT
12400         statements on cold and hot labels.
12401         * predict.c (tree_estimate_probability_bb): Remove the
12402         prediction from this place.
12404 2017-06-21  Martin Liska  <mliska@suse.cz>
12406         PR tree-optimization/79489
12407         * gimplify.c (maybe_add_early_return_predict_stmt): New
12408         function.
12409         (gimplify_return_expr): Call the function.
12410         * predict.c (tree_estimate_probability_bb): Remove handling
12411         of early return.
12412         * predict.def: Update comment about early return predictor.
12413         * gimple-predict.h (is_gimple_predict): New function.
12414         * predict.def: Change default value of early return to 66.
12415         * tree-tailcall.c (find_tail_calls): Skip GIMPLE_PREDICT
12416         statements.
12417         * passes.def: Put pass_strip_predict_hints to the beginning of
12418         IPA passes.
12420 2017-06-21  Pierre-Marie de Rodat  <derodat@adacore.com>
12422         * dwarf2out.c (gen_decl_die): Remove the guard to skip file-scope
12423         FUNCTION_DECL declarations.
12424         (dwarf2out_early_global_decl): Remove the guard to skip FUNCTION_DECL
12425         declarations.
12426         (dwaf2out_decl): Likewise.
12427         * godump.c (go_early_global_decl): Skip call to the real debug hook
12428         for FUNCTION_DECL declarations.
12429         * passes.c (rest_of_decl_compilation): Skip call to the
12430         early_global_decl debug hook for FUNCTION_DECL declarations, unless
12431         -fdump-go-spec is passed.
12433 2017-06-21  Marc Glisse  <marc.glisse@inria.fr>
12435         * config/i386/i386.c (struct builtin_isa): New field pure_p.
12436         Reorder for compactness.
12437         (def_builtin, def_builtin2, ix86_add_new_builtins): Handle pure_p.
12438         (def_builtin_pure, def_builtin_pure2): New functions.
12439         (ix86_init_mmx_sse_builtins) [__builtin_ia32_stmxcsr]: Mark as pure.
12441 2017-06-21  Marc Glisse  <marc.glisse@inria.fr>
12443         * match.pd (nop_convert): New predicate.
12444         ((A +- CST1) +- CST2): Allow some NOP conversions.
12446 2017-06-21  Jakub Jelinek  <jakub@redhat.com>
12448         PR c++/81130
12449         * gimplify.c (omp_add_variable): Don't force GOVD_SEEN for types
12450         with ctors/dtors if GOVD_SHARED is set.
12452 2017-06-21  Wilco Dijkstra  <wdijkstr@arm.com>
12454         * config/aarch64/aarch64.md (movti_aarch64):
12455         Emit mov rather than orr.
12456         (movtf_aarch64): Likewise.
12457         * config/aarch64/aarch64-simd.md (aarch64_simd_mov):
12458         Emit mov rather than orr.
12460 2017-06-21  Wilco Dijkstra  <wdijkstr@arm.com>
12462         * config/aarch64/aarch64-simd.md (aarch64_simd_dup):
12463         Swap alternatives, make integer dup more expensive.
12465 2017-06-21  Wilco Dijkstra  <wdijkstr@arm.com>
12467         * config/aarch64/aarch64.c (aarch64_legitimate_constant_p):
12468         Return true for non-tls symbols.
12470 2017-06-21  James Greenhalgh  <james.greenhalgh@arm.com>
12472         * config/aarch64/aarch64-cores.def (cortex-a55): New.
12473         (cortex-a75): Likewise.
12474         (cortex-a75.cortex-a55): Likewise.
12475         * config/aarch64/aarch64-tune.md: Regenerate.
12476         * doc/invoke.texi (-mtune): Document new values for -mtune.
12478 2017-06-21  Tom de Vries  <tom@codesourcery.com>
12480         * doc/sourcebuild.texi (Add Options, Features for dg-add-options): Add
12481         stack_size feature.
12482         (Effective-Target Keywords, Other attributes): Suggest using
12483         dg-add-options stack_size feature to get stack limit in stack_size
12484         effective target documentation.
12486 2017-06-21  Julian Brown  <julian@codesourcery.com>
12487             Naveen H.S  <Naveen.Hurugalawadi@cavium.com>
12489         * config/aarch64/aarch64-simd.md (aarch64_crypto_pmulldi)
12490         (aarch64_crypto_pmullv2di): Change type attribute to crypto_pmull.
12491         * config/aarch64/thunderx2t99.md (thunderx2t99_pmull): New
12492         reservation.
12493         * config/arm/cortex-a53.md (cortex_a53_advsimd_type): Add crypto_pmull to
12494         attribute type list for neon_multiply.
12495         * config/arm/cortex-a57.md (cortex_a57_neon_type): Add crypto_pmull to
12496         attribute type list for neon_multiply.
12497         * config/arm/crypto.md (crypto_vmullp64): Change type to crypto_pmull.
12498         * config/arm/exynos-m1.md (exynos_m1_neon_type): Add crypto_pmull to
12499         attribute type list for neon_multiply.
12500         * config/arm/types.md (crypto_pmull): Add.
12501         * config/arm/xgene1.md (xgene1_neon_pmull): Add crypto_pmull to
12502         attribute type list.
12504 2017-06-20  Andreas Tobler  <andreast@gcc.gnu.org>
12506         * config.gcc (armv6*-*-freebsd*): Change the target_cpu_cname to
12507         arm1176jzf-s.
12509 2017-06-20  Jakub Jelinek  <jakub@redhat.com>
12511         * ira-costs.c (find_costs_and_classes): Initialize cost_classes later
12512         to make sure not to dereference a NULL cost_classes_ptr pointer.
12514 2017-06-20  Carl Love  <cel@us.ibm.com>
12516         * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Add
12517         ALTIVEC_BUILTIN_VMULESW, ALTIVEC_BUILTIN_VMULEUW,
12518         ALTIVEC_BUILTIN_VMULOSW, ALTIVEC_BUILTIN_VMULOUW entries.
12519         * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin,
12520         builtin_function_type): Add ALTIVEC_BUILTIN_* case statements.
12521         * config/rs6000/altivec.md (MVULEUW, VMULESW, VMULOUW,
12522         VMULOSW): New enum "unspec" values.
12523         (vec_widen_umult_even_v4si, vec_widen_smult_even_v4si,
12524         vec_widen_umult_odd_v4si, vec_widen_smult_odd_v4si,
12525         altivec_vmuleuw, altivec_vmulesw, altivec_vmulouw,
12526         altivec_vmulosw): New patterns.
12527         * config/rs6000/rs6000-builtin.def (VMLEUW, VMULESW, VMULOUW,
12528         VMULOSW): Add definitions.
12530 2017-06-20  Julia Koval  <julia.koval@intel.com>
12532         * config/i386/i386.c: Fix rounding expand for new pattern.
12533         * config/i386/subst.md: Fix pattern (parallel -> unspec).
12535 2017-06-20  James Greenhalgh  <james.greenhalgh@arm.com>
12537         * config/aarch64/aarch64-option-extensions.def (rcpc): New.
12538         * config/aarch64/aarch64.h (AARCH64_FL_RCPC): New.
12540 2017-06-20  James Greenhalgh  <james.greenhalgh@arm.com>
12542         * config/aarch64/aarch64-option-extensions.def (fp16): Fix expected
12543         feature string.
12545 2017-06-20  James Greenhalgh  <james.greenhalgh@arm.com>
12547         * config/aarch64/aarch64-cores.def: Rearrange to sort by
12548         architecture, then by implementer ID.
12549         * config/aarch64/aarch64-tune.md: Regenerate.
12551 2017-06-20  Richard Biener  <rguenther@suse.de>
12553         PR middle-end/81097
12554         * fold-const.c (split_tree): Fold to type before negating.
12556 2017-06-20  David Malcolm  <dmalcolm@redhat.com>
12558         * diagnostic-show-locus.c
12559         (selftest::test_fixit_deletion_affecting_newline): New function.
12560         (selftest::diagnostic_show_locus_c_tests): Call it.
12562 2017-06-20  Andreas Schwab  <schwab@suse.de>
12564         PR target/80970
12565         * config/m68k/m68k.md (bsetdreg, bchgdreg, bclrdreg): Use "=d"
12566         instead of "+d".
12568 2017-06-20  Prakhar Bahuguna  <prakhar.bahuguna@arm.com>
12570         * config/arm/arm-c.c (arm_cpu_builtins): New block to define
12571         __ARM_FEATURE_COPROC according to support.
12573 2017-06-20  Jakub Jelinek  <jakub@redhat.com>
12575         * tree-chkp.c (chkp_get_hard_register_var_fake_base_address):
12576         Rewritten to avoid overflow for > 32-bit pointers.
12578         PR sanitizer/81125
12579         * ubsan.h (ubsan_encode_value): Workaround buggy clang++ parser
12580         by removing enum keyword.
12581         (ubsan_type_descriptor): Likewise.  Formatting fix.
12583         PR target/81121
12584         * config/i386/i386.md (TARGET_USE_VECTOR_CONVERTS float si->{sf,df}
12585         splitter): Require TARGET_SSE2 in the condition.
12587 2017-06-20  Michael Meissner  <meissner@linux.vnet.ibm.com>
12589         PR target/79799
12590         * config/rs6000/rs6000.c (rs6000_expand_vector_init): Add support
12591         for doing vector set of SFmode on ISA 3.0.
12592         * config/rs6000/vsx.md (vsx_set_v4sf_p9): Likewise.
12593         (vsx_set_v4sf_p9_zero): Special case setting 0.0f to a V4SF
12594         element.
12595         (vsx_insert_extract_v4sf_p9): Add an optimization for inserting a
12596         SFmode value into a V4SF variable that was extracted from another
12597         V4SF variable without converting the element to double precision
12598         and back to single precision vector format.
12599         (vsx_insert_extract_v4sf_p9_2): Likewise.
12601 2017-06-19  Jakub Jelinek  <jakub@redhat.com>
12603         * tree-ssa-structalias.c (get_constraint_for_ptr_offset): Multiply
12604         in UWHI to avoid undefined overflow.
12606         PR sanitizer/81125
12607         * ubsan.h (enum ubsan_encode_value_phase): New.
12608         (ubsan_encode_value): Change second argument to
12609         enum ubsan_encode_value_phase with default value of
12610         UBSAN_ENCODE_VALUE_GENERIC.
12611         * ubsan.c (ubsan_encode_value): Change second argument to
12612         enum ubsan_encode_value_phase PHASE from bool IN_EXPAND_P,
12613         adjust uses, for UBSAN_ENCODE_VALUE_GENERIC use just
12614         create_tmp_var_raw instead of create_tmp_var and use a
12615         TARGET_EXPR.
12616         (ubsan_expand_bounds_ifn, ubsan_build_overflow_builtin,
12617         instrument_bool_enum_load, ubsan_instrument_float_cast): Adjust
12618         ubsan_encode_value callers.
12620         PR sanitizer/81111
12621         * ubsan.c (ubsan_encode_value): If current_function_decl is NULL,
12622         use create_tmp_var_raw instead of create_tmp_var, mark it addressable
12623         just by setting TREE_ADDRESSABLE on the result and use a TARGET_EXPR.
12625 2017-06-19  Richard Biener  <rguenther@suse.de>
12627         PR middle-end/81118
12628         * tree-cfgcleanup.c (cleanup_tree_cfg_noloop): Clear niter
12629         estimates if we changed anything.
12631 2017-06-19  Richard Biener  <rguenther@suse.de>
12633         PR tree-optimization/80887
12634         * tree-ssa-sccvn.c (mprts_hook_cnt): New global.
12635         (vn_lookup_simplify_result): Allow only mprts_hook_cnt succesful
12636         simplified lookups, then reset mprts_hook.
12637         (vn_nary_build_or_lookup_1): Set mprts_hook_cnt to 9 before
12638         simplifying.
12639         (try_to_simplify): Likewise.
12641 2017-06-19  Martin Liska  <mliska@suse.cz>
12643         PR sanitizer/80879
12644         * gimplify.c (gimplify_switch_expr):
12645         Initialize live_switch_vars for SWITCH_BODY == STATEMENT_LIST.
12647 2017-06-19  Martin Liska  <mliska@suse.cz>
12649         * doc/install.texi: Document that PGO runs in 4 stages.
12651 2017-06-19  Martin Liska  <mliska@suse.cz>
12653         PR ipa/80732
12654         * attribs.c (make_dispatcher_decl): Do not append '.ifunc'
12655         to dispatcher function name.
12656         * multiple_target.c (replace_function_decl): New function.
12657         (create_dispatcher_calls): Redirect both edges and references.
12659 2017-06-19  Jan Hubicka <hubicka@ucw.cz>
12661         * profile-count.c (profile_count::dump): Dump quality.
12662         (profile_count::differs_from_p): Update for unsigned val.
12663         * profile-count.h (profile_count_quality): New enum.
12664         (profile_count): Turn m_val to 62bit unsigned, add quality tracking.
12666 2017-06-19  Richard Biener  <rguenther@suse.de>
12668         * tree-ssa-loop-niter.h (estimate_numbers_of_iterations): Take
12669         struct function as arg.
12670         (estimate_numbers_of_iterations): Export overload with loop arg.
12671         (free_numbers_of_iterations_estimates_loop): Use an overload of
12672         free_numbers_of_iterations_estimates instead.
12673         * tree-cfg.c (remove_bb): Adjust.
12674         * tree-cfgcleanup.c (remove_forwarder_block_with_phi): Likewise.
12675         * tree-parloops.c (gen_parallel_loop): Likewise.
12676         * tree-ssa-loop-ivcanon.c (canonicalize_induction_variables):
12677         Likewise.
12678         (tree_unroll_loops_completely): Likewise.
12679         * tree-ssa-loop-niter.c (estimate_numbers_of_iterations_loop):
12680         Use an overload instead and export.
12681         (estimated_loop_iterations): Adjust.
12682         (max_loop_iterations): Likewise.
12683         (likely_max_loop_iterations): Likewise.
12684         (estimate_numbers_of_iterations): Take struct function as arg
12685         and adjust.
12686         (loop_exits_before_overflow): Adjust.
12687         (free_numbers_of_iterations_estimates_loop): Use an overload.
12688         * tree-vect-loop.c (vect_analyze_loop_form): Adjust.
12689         * tree-vectorizer.c (vect_free_loop_info_assumptions): Likewise.
12691 2017-06-19  Richard Biener  <rguenther@suse.de>
12693         PR ipa/81112
12694         * ipa-prop.c (find_constructor_constant_at_offset): Handle
12695         RANGE_EXPR conservatively.
12697 2017-06-16  Carl Love  <cel@us.ibm.com>
12699         * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Add
12700         definitions for vec_float, vec_float2, vec_floato,
12701         vec_floate built-ins.
12702         * config/rs6000/vsx.md (define_c_enum "unspec"): Add RTL code
12703         for instructions vsx_xvcvsxws vsx_xvcvuxwsp, float2, floato and
12704         floate.
12705         * config/rs6000/rs6000-builtin.def (FLOAT2_V2DI, FLOATE_V2DF,
12706         FLOATE_2DI, FLOATO_V2DF, FLOATEE_V2DI, XVCVSXWSP_V4SF,
12707         UNS_FLOATO_V2DI, UNS_FLOATE_V2DI): Add definitions.
12708         * config/altivec.md (define_insn "p8_vmrgew_<mode>",
12709         define_mode_attr VF_sxddp): Add V4SF type to p8_vmrgew.
12710         * config/rs6000/altivec.h (vec_float, vec_float2, vec_floate,
12711         vec_floato): Add builtin defines.
12712         * doc/extend.texi (vec_float, vec_float2, vec_floate, vec_floato):
12713         Update the built-in documentation file for the new built-in
12714         functions.
12716 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
12718         * config/arm/arm.opt (marm): Mark as the negative of of -mthumb.
12719         (mthumb): Mark as the negative of -marm.
12721 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
12723         * doc/invoke.texi (ARM Options, -mcpu): Document supported
12724         extension options.
12725         (ARM Options, -mtune): Document that this accepts the same
12726         extension options as -mcpu.
12727         (ARM Options, -mfpu): Document addition of -mfpu=auto.
12729 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
12731         * doc/invoke.texi (ARM Options, -march=): Document new syntax and
12732         permitted extensions.
12734 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
12736         * config/arm/arm-cpus.in (armv7): Add extension +nofp.
12737         (armv7-r): Add aliases vfpv3xd and vfpv3-d16.
12738         (armv8-m.main): Add option +nodsp.
12739         * config/arm/arm-cpu-cdata.h: Regenerated.
12741 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
12743         * config/arm/t-fuchsia: New file.
12744         * config.gcc (arm*-*-fuchsia*): Use it.
12746 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
12748         * config/arm/t-symbian: Rewrite for new option infrastructure.
12750 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
12752         * config/arm/t-phoenix (MULTILIB_REUSE): Clear variable.
12753         (MULTILIB_REQUIRED): Likewise.
12755 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
12757         * config/arm/t-linux-eabi (MULTILIB_EXCEPTIONS): Set to empty.
12758         (MULTILIB_RESUE): Likewise.
12759         (MULTILIB_MATCHES): Likewise.
12760         (MULTLIB_REQUIRED): Likewise.
12762 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
12764         * config/arm/t-rtems: Rewrite for new option framework.
12766 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
12768         * config/arm/t-aprofile (v7_a_nosimd_variants, v7_a_simd_variants)
12769         (v7ve_nosimd_variatns, v7ve_vfpv3_simd_variants)
12770         (v7ve_vfpv4_simd_variants, v8_a_nosimd_variants, v8_a_simd_variants)
12771         (v8_1_a_simd_variants, v8_2_a_simd_variants): Move to ...
12772         * config/arm/t-multilib: ... here.
12773         (MULTILIB_OPTIONS): Add armv7 and armv7+fp architectures.
12774         (MULTILIB_MATCHES): Use armv7 libraries for armv7-r.  Also use for
12775         armv7-a and armv8*-a when A-profile libraries have not been built.
12776         * config/arm/t-rmprofile: Rewrite.
12778 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
12780         * genmultilib (multilib_reuse): Allow an explicit period to be escaped
12781         with a backslash.  Remove the backslash after substituting unescaped
12782         periods.
12783         * doc/fragments.texi (MULTILIB_REUSE): Document it.
12785 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
12787         * config.gcc: (arm*-*-*): When building a-profile libraries, force
12788         the driver to pass through the default setting of -mfloat-abi.
12789         * common/config/arm/arm-common.c (arm_target_thumb_only): Return -marm
12790         rather than NULL.
12791         * config/arm/t-multilib (MULTILIB_REUSE): Initialize to empty.
12792         (all_feat_combs): New rule.
12793         (MULTILIB_OPTIONS): Use explicit ARM and Thumb directories.  Rework
12794         default libraries.
12795         * config/arm/t-aprofile: Rewrite.
12797 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
12799         * config/arm/arm.h (FPUTYPE_AUTO): Define.
12800         * config/arm/arm.c (arm_option_override): Use FPUTYPE_AUTO if the
12801         fpu is not specified by the user/command-line.
12802         * config/arm/bpabi.h (FPUTYPE_DEFAULT): Delete.
12803         * config/arm/netbsd-elf.h (FPUTYPE_DEFAULT): Delete.
12804         * config/arm/linux-elf.h (FPUTYPE_DEFAULT): Delete.
12805         * config/arm/vxworks.h (FPUTYPE_DEFAULT): Delete.
12806         * common/config/arm/arm-common.c (arm_canon_arch_option): Use
12807         FPUTYPE_AUTO insted of FPUTYPE_DEFAULT.
12809 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
12811         * config/arm/elf.h (MULTILIB_DEFAULTS): Delete.
12812         * config/arm/t-arm-elf: Rewritten.
12814 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
12816         * config/arm/arm.h (TARGET_HARD_FLOAT): Also check that we
12817         have some floating-point instructions.
12818         (TARGET_SOFT_FLOAT): Define as inverse of TARGET_HARD_FLOAT.
12819         (TARGET_MAYBE_HARD_FLOAT): New macro.
12820         * config/arm/arm-builtins.c (arm_init_builtins): Use
12821         TARGET_MAYBE_HARD_FLOAT.
12822         * config/arm/arm.c (arm_option_override): Use TARGET_HARD_FLOAT_ABI.
12824 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
12826         * common/config/arm/arm-common.c: Define INCLUDE_LIST.
12827         (configargs.h): Include it.
12828         (arm_print_hint_for_fpu_option): New function.
12829         (arm_parse_fpu_option): New function.
12830         (candidate_extension): New class.
12831         (arm_canon_for_multilib): New function.
12832         * config/arm/arm.h (CANON_ARCH_SPEC_FUNCTION): New macro.
12833         (EXTRA_SPEC_FUNCTIONS): Add CANON_ARCH_SPEC_FUNCTION.
12834         (ARCH_CANONICAL_SPECS): New macro.
12835         (DRIVER_SELF_SPECS): Add ARCH_CANONICAL_SPECS.
12837 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
12839         * config.gcc (arm*-*-*): Ensure both target_cpu_cname and with_cpu
12840         are set after handling multilib fragments.  Set target_cpu_default2
12841         from with_cpu.
12843 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
12845         * config.gcc (arm*-*-fucshia*): Set target_cpu_cname to the real
12846         cpu name.
12847         (arm*-*-*): Set target_cpu_default2 to a quoted string.
12848         * config/arm/parsecpu.awk (check_cpu): Validate any extension
12849         options.
12850         (check_arch): Likewise.
12851         * config/arm/arm.c (arm_configure_build_target): Handle
12852         TARGET_CPU_DEFAULT being a string constant.  Scan any feature
12853         options in the default.
12855 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
12857         * config/arm/arm-protos.h (cpu_arch_extension): Add field to record
12858         when an option is an alias of another.
12859         * config/arm/parsecpu.awk (optalias): New parser token.
12860         (gen_comm_data): Mark non-alias options as such.  Emit entries
12861         for extension aliases.
12862         * config/arm/arm-cpus.in (armv5e): Make vfpv2 an alias.
12863         (armv5te, armv5tej, armv6, armv6j, armv6k, armv6z): Likewise.
12864         (armv6kz, armv6zk, armv6t2): Likewise.
12865         (armv7): Make vfpv3-d16 an alias.
12866         (armv7-a): Make vfpv3-d16, neon and neon-vfpv3 aliases.  Sort in
12867         canonical order.
12868         (armv7ve): Make vfpv4-d16, neon-vfpv3 and neon-vfpv4 aliases.
12869         Sort in canonical order.
12870         (armv8-a): Sort in canonical order.
12871         (armv8.1-a, armv8.2-a):  Likewise.
12872         (generic-armv7-a): Make neon and neon-vfpv3 aliases.  Sort in
12873         canonical order.
12874         (cortex-a9): Sort in canonical order.
12875         * config/arm/arm.c (selftests.h): Include it.
12876         (arm_test_cpu_arch_data): New function.
12877         (arm_run_self_tests): New function.
12878         (TARGET_RUN_TARGET_SELFTESTS): Redefine.
12879         (targetm): Move declaration to the end of the file.
12880         * arm-cpu-cdata.h: Regenerated.
12882 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
12884         * config/arm/arm.h (TARGET_MODE_SPECS): Add additional parameter to
12885         call to target_mode_check describing the type of option passed.
12886         * common/config/arm/arm-common.c (arm_arch_core_flag): Delete.
12887         (arm_target_thumb_only): Use arm_parse_arch_option_name or
12888         arm_parse_cpu_option_name to match parameters against list of
12889         available targets.
12890         * config/arm/parsecpu.awk (gen_comm_data): Don't generate
12891         arm_arch_core_flags data structure.
12892         * config/arm/arm-cpu_cdata.h: Regenerated.
12894 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
12896         * common/config/arm/arm-common.c (arm_initialize_isa): Moved here from
12897         config/arm/arm.c.
12898         (arm_print_hint_for_cpu_option): Likewise.
12899         (arm_print_hint_for_arch_option): Likewise.
12900         (arm_parse_cpu_option_name): Likewise.
12901         (arm_parse_arch_option_name): Likewise.
12902         * config/arm/arm.c (arm_identify_fpu_from_isa): Use the computed number
12903         of entries in the all_fpus list.
12904         * config/arm/arm-protos.h (all_architectures, all_cores): Declare.
12905         (arm_parse_cpu_option_name): Declare.
12906         (arm_parse_arch_option_name): Declare.
12907         (arm_parse_option_features): Declare.
12908         (arm_intialize_isa): Declare.
12909         * config/arm/parsecpu.awk (gen_data): Move CPU and architecture
12910         data tables to ...
12911         (gen_comm_data): ... here.  Make definitions non-static.
12912         * config/arm/arm-cpu-data.h: Regenerated.
12913         * config/arm/arm-cpu-cdata.h: Regenerated.
12915 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
12917         * config/arm/arm-protos.h (arm_build_target): Remove arch_core.
12918         (cpu_arch_extension): New structure.
12919         (cpu_arch_option, arch_option, cpu_option): New structures.
12920         * config/arm/parsecpu.awk (gen_headers): Build an enumeration of
12921         architecture types.
12922         (gen_data): Generate new format data tables.
12923         * config/arm/arm.c (cpu_tune): New structure.
12924         (cpu_option, processors): Delete.
12925         (arm_print_hint_for_core_or_arch): Delete.  Replace with ...
12926         (arm_print_hint_for_cpu_option): ... this and ...
12927         (arm_print_hint_for_arch_option): ... this.
12928         (arm_parse_arch_cpu_name): Delete.  Replace with ...
12929         (arm_parse_cpu_option_name): ... this and ...
12930         (arm_parse_arch_option_name): ... this.
12931         (arm_unrecognized_feature): Change type of target parameter to
12932         cpu_arch_option.
12933         (arm_parse_arch_cpu_features): Delete.  Replace with ...
12934         (arm_parse_option_features): ... this.
12935         (arm_configure_build_target): Rework to use new configuration data
12936         tables.
12937         (arm_print_tune_info): Rework for new configuration data tables.
12938         * config/arm/arm-cpu-data.h: Regenerated.
12939         * config/arm/arm-cpu.h: Regenerated.
12941 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
12943         * Makefile.in (OBJS): Move sbitmap.o from here ...
12944         (OBJS-libcommon): ... to here.
12946 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
12948         * config/arm/arm-isa.h (ISA_ALL_FPU_INTERNAL): Renamed from ISA_ALL_FPU.
12949         (ISA_ALL_CRYPTO): New macro.
12950         (ISA_ALL_SIMD): New macro
12951         (ISA_ALL_FP): New macro.
12952         * config/arm/arm.c (fpu_bitlist): Update initializer.
12953         * config/arm/arm-cpus.in: Use new ISA_ALL macros to disable crypto,
12954         simd or fp.
12955         (arm9e): Add fpu.  Add option for nofp
12956         (arm946e-s, arm966e-s, arm968e-s, arm10e, arm1020e, arm1022e): Likewise.
12957         (arm926ej-s, arm1026ej-s): Likewise.
12958         (generic-armv7-a): Add fpu.  Add options for simd, vfpv3, vfpv3-d16,
12959         vfpv3-fp16, vfpv3-d16-fp16, vfpv4, vfpv4-d16, neon, neon-vfp3,
12960         neon-fp16, neon-vfpv4, nofp and nosimd.
12961         (cortex-a5, cortex-a7): Add fpu.  Add options for nosimd and nofp.
12962         (cortex-a8): Add fpu.  Add option for nofp.
12963         (cortex-a9): Add fpu.  Add options for nosimd and nofp.
12964         (cortex-a12, cortex-a15, cortex-a17): Add fpu.  Add option for nofp.
12965         (cortex-r4f): Add fpu.
12966         (cortex-r5): Add fpu.  Add options for nofp.dp and nofp.
12967         (cortex-r7): Use idiv option from architecture.  Add fpu.  Add option
12968         for nofp.
12969         (cortex-r8): Likewise.
12970         (cortex-m4): Add fpu.  Add option for nofp.
12971         (cortex-a15.cortex-a7): Add fpu.  Add option for nofp.
12972         (cortex-a17.cortex-a7): Likewise.
12973         (cortex-a32): Add fpu.  Add options for crypto and nofp.
12974         (cortex-a35, cortex-a53): Likewise.
12975         (cortex-a57): Add fpu.  Add option for crypto.
12976         (cortex-a72, cortex-a73): Likewise.
12977         (exynos-m1): Likewise.
12978         (cortex-a57.cortex-a53, cortex-a72.cortex-a53): Likewise.
12979         (cortex-a73.cortex-a35, cortex-a73.cortex-a53): Likewise.
12980         (cortex-m33): Add fpu.  Add option for nofp.
12981         * config/arm/arm-cpu-cdata.h: Regenerated
12982         * config/arm/arm-cpu-data.h: Regenerated.
12984 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
12986         * arm-cpus.in (armv5e): Add options fp, vfpv2 and nofp.
12987         (armv5te, armv5tej): Likewise.
12988         (armv6, armv6j, armv6k, armv6z, armv6kz, armv6zk, armv6t2): Likewise.
12989         (armv7): Add options fp and vfpv3-d16.
12990         (armv7-a): Add options fp, simd, vfpv3, vfpv3-d16, vfpv3-d16-fp16,
12991         vfpv3-fp16, vfpv4, vfpv4-d16, neon, neon-vfpv3, neon-fp16, neon-vfpv4,
12992         nofp and nosimd.
12993         (armv7ve): Likewise.
12994         (armv7-r): Add options fp, fp.sp, idiv, nofp and noidiv.
12995         (armv7e-m): Add options fp, fpv5, fp.dp and nofp.
12996         (armv8-a): Add nocrypto option.
12997         (armv8.1-a, armv8.2-a): Likewise.
12998         (armv8-m.main): add options fp, fp.dp and nofp.
13000 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
13002         * config/arm/arm-cpus.in (armv8-a): Add options crc, simd crypto and
13003         nofp.
13004         (armv8-a+crc): Delete.
13005         (armv8.1-a): Add options simd, crypto and nofp.
13006         (armv8.2-a): Add options fp16, simd, crypto and nofp.
13007         (armv8.2-a+fp16): Delete.
13008         (armv8-m.main): Add option dsp.
13009         (armv8-m.main+dsp): Delete.
13010         (cortex-a8): Add fpu.  Add nofp option.
13011         (cortex-a9): Add fpu.  Add nofp and nosimd options.
13012         * config/arm/parsecpu.awk (gen_data): Generate option tables and
13013         link to main cpu and architecture data structures.
13014         (gen_comm_data): Only put isa attributes from the main architecture
13015         in common tables.
13016         (option): New statement for architecture and CPU entries.
13017         * arm.c (struct cpu_option): New structure.
13018         (struct processors): Add entry for options.
13019         (arm_unrecognized_feature): New function.
13020         (arm_parse_arch_cpu_name): Ignore any characters after the first
13021         '+' character.
13022         (arm_parse_arch_cpu_feature): New function.
13023         (arm_configure_build_target): Separate out any CPU and architecture
13024         features and parse separately.  Don't error out if -mfpu=auto is
13025         used with only an architecture string.
13026         (arm_print_asm_arch_directives): New function.
13027         (arm_file_start): Call it.
13028         * config/arm/arm-cpu-cdata.h: Regenerated.
13029         * config/arm/arm-cpu-data.h: Likewise.
13030         * config/arm/arm-tables.opt: Likewise.
13032 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
13034         * config/arm/elf.h (ASM_SPEC): Only pass -mfpu through to the
13035         assembler when it is not -mfpu=auto.
13037 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
13039         * config/arm/arm.h (BIG_LITTLE_SPEC): Delete macro.
13040         (ASM_REWRITE_SPEC_FUNCTIONS): New macro.
13041         (BIG_LITTLE_CPU_SPEC_FUNCTIONS): Delete macro.
13042         (ASM_CPU_SPEC): Rewrite.
13043         (MCPU_MTUNE_NATIVE_FUNCTIONS): New macro.
13044         (EXTRA_SPEC_FUNCTIONS): Move outside of ifdef.  Use
13045         MCPU_MTUNE_NATIVE_FUNCTIONS and ASM_REWRITE_SPEC_FUNCTIONS.  Remove
13046         reference to BIG_LITTLE_CPU_SPEC_FUNCTIONS.
13047         * common/config/arm/arm-common.c (arm_rewrite_selected_cpu): Ensure
13048         copied string is NUL-terminated.  Also strip any characters prefixed
13049         by '+'.
13050         (arm_rewrite_selected_arch): New function.
13051         (arm_rewrite_march): New function.
13053 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
13055         * config/arm/arm.opt (x_arm_arch_string): New TargetSave option.
13056         (x_arm_cpu_string, x_arm_tune_string): Likewise.
13057         (march, mcpu, mtune): Convert to string-based options.
13058         * config/arm/arm.c (arm_print_hint_for_core_or_arch): New function.
13059         (arm_parse_arch_cpu_name): New function.
13060         (arm_configure_build_target): Use arm_parse_arch_cpu_name to
13061         identify selected architecture or CPU.
13062         (arm_option_save): New function.
13063         (TARGET_OPTION_SAVE): Redefine.
13064         (arm_option_restore): Restore string options.
13065         (arm_option_print): Print string options.
13067 2017-06-16  Martin Sebor  <msebor@redhat.com>
13069         PR tree-optimization/80933
13070         PR tree-optimization/80934
13071         * builtins.c (fold_builtin_3): Do not handle bcmp here.
13072         * gimple-fold.c (gimple_fold_builtin_bcmp): New function.
13073         (gimple_fold_builtin_bcopy, gimple_fold_builtin_bzero): Likewise.
13074         (gimple_fold_builtin): Call them.
13076 2017-06-16  Jan Hubicka  <hubicka@ucw.cz>
13078         * gimple-ssa-isolate-paths.c (isolate_path): Set edge leading to path
13079         as unlikely; update profile.
13081 2017-06-16  Jan Hubicka  <hubicka@ucw.cz>
13083         * predict.c (force_edge_cold): Handle declaring edges impossible
13084         more aggresively.
13086 2017-06-16  Jan Hubicka  <hubicka@ucw.cz>
13088         * tree-ssa-loop-ivcanon.c (remove_exits_and_undefined_stmts): Update
13089         profile.
13090         (try_unroll_loop_completely): Fix reporting.
13092 2017-06-16  Jan Hubicka  <hubicka@ucw.cz>
13094         * tree-ssa-tail-merge.c (replace_block_by): Fix profile updating.
13096 2017-06-16  James Greenhalgh  <james.greenhalgh@arm.com>
13098         PR target/71778
13099         * config/arm/arm-builtins.c (arm_expand_builtin_args): Return TARGET
13100         if given a non-constant argument for an intrinsic which requires a
13101         constant.
13103 2017-06-16  Jan Hubicka  <hubicka@ucw.cz>
13105         * profile.c (compare_freqs): New function.
13106         (branch_prob): Sort edge list.
13107         (find_spanning_tree): Assume that the list is priority sorted.
13109 2017-06-16  Richard Biener  <rguenther@suse.de>
13111         PR tree-optimization/81090
13112         * passes.def (pass_record_bounds): Remove.
13113         * tree-pass.h (make_pass_record_bounds): Likewise.
13114         * tree-ssa-loop.c (pass_data_record_bounds, pass_record_bounds,
13115         make_pass_record_bounds): Likewise.
13116         * tree-ssa-loop-ivcanon.c (canonicalize_induction_variables): Do
13117         not free niter estimates at the beginning but at the end.
13118         * tree-scalar-evolution.c (scev_finalize): Free niter estimates.
13120 2017-06-16  Richard Biener  <rguenther@suse.de>
13122         * tree-switch-conversion.c (emit_case_bit_tests): Adjust
13123         initializer to workaround ICE in host GCC 4.8.
13125 2017-06-16  Jan Hubicka  <hubicka@ucw.cz>
13127         * ipa-inline-transform.c (update_noncloned_frequencies): Update also
13128         counts.
13129         (clone_inlined_nodes): Update.
13131 2017-06-16  Maxim Kuvyrkov  <maxim.kuvyrkov@linaro.org>
13133         * config/aarch64/aarch64.c (qdf24xx_prefetch_tune): Update
13134         prefetch settings, and enable prefetching by default at -O3.
13136 2017-06-16  Maxim Kuvyrkov  <maxim.kuvyrkov@linaro.org>
13138         * config/aarch64/aarch64.c (aarch64_override_options_internal):
13139         Set flag_prefetch_loop_arrays according to tuning data.
13141 2017-06-16  Maxim Kuvyrkov  <maxim.kuvyrkov@linaro.org>
13143         * config/aarch64/aarch64-protos.h (struct cpu_prefetch_tune):
13144         New tune structure.
13145         (struct tune_params): Use cpu_prefetch_tune instead of cache_line_size.
13146         [Unrelated to main purpose of the patch] Place the pointer field last
13147         to enable type checking errors when tune structure are wrongly merged.
13148         * config/aarch64/aarch64.c (generic_prefetch_tune,)
13149         (exynosm1_prefetch_tune, qdf24xx_prefetch_tune,)
13150         (thunderx2t99_prefetch_tune): New tune constants.
13151         (tune_params *_tunings): Update all tunings (no functional change).
13152         (aarch64_override_options_internal): Set PARAM_SIMULTANEOUS_PREFETCHES,
13153         PARAM_L1_CACHE_SIZE, PARAM_L1_CACHE_LINE_SIZE, and PARAM_L2_CACHE_SIZE
13154         from tunings structures.
13156 2017-06-16  Jakub Jelinek  <jakub@redhat.com>
13158         PR sanitizer/81094
13159         * ubsan.c (instrument_null): Add T argument, use it instead
13160         of computing it based on IS_LHS.
13161         (instrument_object_size): Likewise.
13162         (pass_ubsan::execute): Adjust instrument_null and
13163         instrument_object_size callers to pass gimple_get_lhs or
13164         gimple_assign_rhs1 result to it.  Use instrument_null instead of
13165         calling get_base_address and instrument_mem_ref.  Handle
13166         aggregate call arguments for object-size sanitization.
13168 2017-06-16  Yury Gribov  <tetra2005@gmail.com>
13170         PR tree-optimization/81089
13171         * tree-vrp.c (is_masked_range_test): Validate operands of
13172         subexpression.
13174 2017-06-15  Martin Sebor  <msebor@redhat.com>
13176         PR c++/80560
13177         * dumpfile.c (dump_register): Avoid calling memset to initialize
13178         a class with a default ctor.
13179         * gcc.c (struct compiler): Remove const qualification.
13180         * genattrtab.c (gen_insn_reserv): Replace memset with initialization.
13181         * hash-table.h: Ditto.
13182         * ipa-cp.c (allocate_and_init_ipcp_value): Replace memset with
13183           assignment.
13184         * ipa-prop.c (ipa_free_edge_args_substructures): Ditto.
13185         * omp-low.c (lower_omp_ordered_clauses): Replace memset with
13186         default ctor.
13187         * params.h (struct param_info): Make struct members non-const.
13188         * tree-switch-conversion.c (emit_case_bit_tests): Replace memset
13189         with default initialization.
13190         * vec.h (vec_copy_construct, vec_default_construct): New helper
13191         functions.
13192         (vec<T>::copy, vec<T>::splice, vec<T>::reserve): Replace memcpy
13193         with vec_copy_construct.
13194         (vect<T>::quick_grow_cleared): Replace memset with default ctor.
13195         (vect<T>::vec_safe_grow_cleared, vec_safe_grow_cleared): Same.
13196         * doc/invoke.texi (-Wclass-memaccess): Document.
13198 2017-06-15  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
13200         * emit-rtl.h (is_leaf): Update comment about local
13201         register allocator.
13203 2017-06-15  Jozef Lawrynowicz   <jozef.l@somniumtech.com>
13205         PR target/78818
13206         * config/msp430/msp430.c (msp430_data_attr): Check that it's possible
13207         for a variable to have a section before checking if the section has a
13208         name.
13209         Set section to.persistent if persistent attribute is set.
13210         Warn if .persistent attribute is used on an automatic variable.
13212 2017-06-15  Eric Botcazou  <ebotcazou@adacore.com>
13214         PR rtl-optimization/80474
13215         * reorg.c (update_block): Do not ignore instructions in a delay slot.
13217 2017-06-15  Segher Boessenkool  <segher@kernel.crashing.org>
13219         * config/rs6000/rs6000.md (add<mode>3): Use reg_or_subregno instead
13220         of REGNO.
13222 2017-06-14  Maciej W. Rozycki  <macro@imgtec.com>
13224         * config/mips/mips.md (MIPS16_T_REGNUM): Remove constant.
13225         (casesi): Emit bounds checking as RTL.
13226         (casesi_internal_mips16_<mode>): Remove bounds checking.
13228 2017-06-14  Max Filippov  <jcmvbkbc@gmail.com>
13230         * config/xtensa/xtensa.c (xtensa_option_override): Append
13231         MASK_CONST16 to target_flags in the absence of TARGET_L32R.
13232         (hwloop_optimize, hwloop_fail, hwloop_pattern_reg,
13233          xtensa_doloop_hooks): Define unconditionally.
13234         (xtensa_reorg_loops): Only call reorg_loops in the presence of
13235         TARGET_LOOPS.
13236         * config/xtensa/xtensa.h (TARGET_L32R): New definition.
13237         (TARGET_DEFAULT): Remove XCHAL_HAVE_L32R condition and account
13238         for it in xtensa_option_override.
13239         (HARD_FRAME_POINTER_IS_FRAME_POINTER,
13240          HARD_FRAME_POINTER_IS_ARG_POINTER): New definitions.
13242 2017-06-14  Boris Kolpackov  <boris@codesynthesis.com>
13244         * doc/cppopts.texi: Document '-' special value to -MF.
13246 2017-06-14  Wilco Dijkstra  <wdijkstr@arm.com>
13248         * config/arm/cortex-a53.md (cortex_a53_fpalu) Adjust latency.
13249         (cortex_a53_fconst): Likewise.
13250         (cortex_a53_fpmul): Likewise.
13251         (cortex_a53_f_load_64): Likewise.
13252         (cortex_a53_f_load_many): Likewise.
13253         (cortex_a53_advsimd_alu): Likewise.
13254         (cortex_a53_advsimd_alu_q): Likewise.
13255         (cortex_a53_advsimd_mul): Likewise.
13256         (cortex_a53_advsimd_mul_q): Likewise.
13257         (fpmac bypass): Add new bypass for fpmac-fpmac case.
13258         Add missing fmul, r2f_cvt and fconst cases.
13260 2017-06-14  Richard Biener  <rguenther@suse.de>
13262         PR middle-end/81088
13263         * fold-const.c (split_tree): Drop TREE_OVERFLOW flag from
13264         literal constants.
13265         (fold_binary_loc): When associating do not treat pre-existing
13266         TREE_OVERFLOW on literal constants as a reason to allow
13267         TREE_OVERFLOW on associated literal constants.
13269 2017-06-14  Eric Botcazou  <ebotcazou@adacore.com>
13271         * config/sparc/sparc.h (MASK_ISA): Add MASK_LEON and MASK_LEON3.
13272         (MASK_FEATURES): New macro.
13273         * config/sparc/sparc.c (sparc_option_override): Remove the special
13274         handling of -mfpu and generalize it to all MASK_FEATURES switches.
13276 2017-06-14  Eric Botcazou  <ebotcazou@adacore.com>
13278         * simplify-rtx.c (simplify_binary_operation_1) <UDIV>: Do not simplify
13279         a division of 0 if non-call exceptions are enabled.
13281 2017-06-14  Andrew Pinski  <apinski@cavium.com>
13282             Naveen H.S  <Naveen.Hurugalawadi@cavium.com>
13284         PR target/71663
13285         * config/aarch64/aarch64.c (aarch64_expand_vector_init):
13286         Improve vector initialization code gen for only variable case.
13288 2017-06-14  Eric Botcazou  <ebotcazou@adacore.com>
13290         * config/sparc/driver-sparc.c (cpu_names): Add SPARC-T5 entry.
13292 2017-06-14  Richard Biener  <rguenther@suse.de>
13294         PR tree-optimization/81083
13295         * tree-ssa-sccvn.c (vn_reference_lookup_3): Do not use abnormals
13296         as values.
13298 2017-06-13  Segher Boessenkool  <segher@kernel.crashing.org>
13300         * config/rs6000/rs6000.c: Update all comments that mentioned SPE.
13301         (rs6000_expand_builtin): Remove RS6000_BTC_EVSEL.
13302         * config/rs6000/rs6000.h (RS6000_BTC_EVSEL): Delete.
13303         * config/rs6000/vxworks.h (VXCPU_FOR_8548): Delete.  Adjust former use.
13304         * config/rs6000/vxworksae.h (VXCPU_FOR_8548): Delete.
13305         * config/rs6000/vxworksmils.h (VXCPU_FOR_8548): Delete.
13307 2017-06-13  Segher Boessenkool  <segher@kernel.crashing.org>
13309         * config/rs6000/rs6000-opts.h (enum rs6000_vector): Delete VECTOR_SPE.
13310         * config/rs6000/rs6000.c (rs6000_debug_vector_unit): Delete VECTOR_SPE.
13312 2017-06-13  Segher Boessenkool  <segher@kernel.crashing.org>
13314         * config/rs6000/rs6000.h (FIXED_SCRATCH): Delete.
13316 2017-06-13  Segher Boessenkool  <segher@kernel.crashing.org>
13318         * config/rs6000/t-rtems: Don't handle SPE.
13320 2017-06-13  Segher Boessenkool  <segher@kernel.crashing.org>
13322         * config/rs6000/t-linux: Don't handle SPE.
13324 2017-06-13  Segher Boessenkool  <segher@kernel.crashing.org>
13326         * config/rs6000/eabispe.h: Delete file.
13328 2017-06-13  Segher Boessenkool  <segher@kernel.crashing.org>
13330         * config/rs6000/t-spe: Delete file.
13332 2017-06-13  Segher Boessenkool  <segher@kernel.crashing.org>
13334         * config/rs6000/rs6000.c (SPE_CONST_OFFSET_OK): Delete.
13335         (rs6000_legitimate_offset_address_p): Return false for anything in
13336         V2SImode or V2SFmode.
13338 2017-06-13  Segher Boessenkool  <segher@kernel.crashing.org>
13340         * config/rs6000/rs6000-modes.def: Remove all 8-byte vector modes
13341         except V2SF and V2SI.  Rearrange the vector modes, and add comments.
13342         * config/rs6000/rs6000.c (rs6000_debug_reg_global): Remove V8QImode
13343         and V4HImode.
13344         (reg_offset_addressing_ok_p): Remove V4HImode and V1DImode.
13345         (rs6000_legitimate_offset_address_p): Ditto.
13346         (rs6000_emit_move): Ditto.
13347         (rs6000_init_builtins): Remove V4HI_type_node.
13349 2017-06-13  Martin Liska  <mliska@suse.cz>
13351         PR sanitize/78204
13352         * asan.c (asan_sanitize_stack_p): Use sanitize_flags_p.
13353         (gate_asan): Likewise.
13354         * asan.h (asan_no_sanitize_address_p): Remove the function.
13355         (sanitize_flags_p): New function.
13356         * builtins.def: Fix coding style.
13357         * common.opt: Use renamed enum value.
13358         * convert.c (convert_to_integer_1): Use sanitize_flags_p.
13359         * doc/extend.texi: Document no_sanitize attribute.
13360         * flag-types.h (enum sanitize_code): Rename SANITIZE_NONDEFAULT
13361         to SANITIZE_UNDEFINED_NONDEFAULT.
13362         * gcc.c (sanitize_spec_function): Use the renamed enum value.
13363         * gimple-fold.c (optimize_atomic_compare_exchange_p):
13364         Use sanitize_flags_p.
13365         * gimplify.c (gimplify_function_tree): Likewise.
13366         * ipa-inline.c (sanitize_attrs_match_for_inline_p): Likewise.
13367         * opts.c (parse_no_sanitize_attribute): New function.
13368         (common_handle_option): Use renamed enum value.
13369         * opts.h (parse_no_sanitize_attribute): Declare.
13370         * tree.c (sanitize_flags_p): New function.
13371         * tree.h: Declared here.
13372         * tsan.c: Use sanitize_flags_p.
13373         * ubsan.c (ubsan_expand_null_ifn): Likewise.
13374         (instrument_mem_ref): Likewise.
13375         (instrument_bool_enum_load): Likewise.
13376         (do_ubsan_in_current_function): Remove the function.
13377         (pass_ubsan::execute): Use sanitize_flags_p.
13378         * ubsan.h: Remove do_ubsan_in_current_function
13379         * tree-cfg.c (print_no_sanitize_attr_value): New function.
13380         (dump_function_to_file): Use it here.
13382 2017-06-13  Martin Jambor  <mjambor@suse.cz>
13384         PR tree-optimization/80803
13385         PR tree-optimization/81063
13386         * tree-sra.c (subtree_mark_written_and_enqueue): Move up in the file.
13387         (propagate_subaccesses_across_link): Enqueue subtree whenever
13388         necessary instead of relying on the caller.
13390 2017-06-13  Martin Jambor  <mjambor@suse.cz>
13392         * tree-sra.c (add_access_to_work_queue): Only enqueue accesses
13393         that have a first_link.
13394         (sort_and_splice_var_accesses): Do not check first_link before
13395         enquing.
13396         (subtree_mark_written_and_enqueue): Likewise.
13397         (propagate_all_subaccesses): Likewise and do not stop at first
13398         parent with a first_link.
13400 2017-06-13  Martin Jambor  <mjambor@suse.cz>
13402         * tree-sra.c (dump_access_tree_1): Fix accidental dumping to stderr
13403         instead of f.
13405 2017-06-13  Yury Gribov  <tetra2005@gmail.com>
13407         * match.pd: New pattern.
13409 2017-06-13  Yury Gribov  <tetra2005@gmail.com>
13411         * tree-vrp.c (is_masked_range_test): New function.
13412         (register_edge_assert_for): Determine ranges for
13413         some bit tests.
13415 2017-06-13  Yury Gribov  <tetra2005@gmail.com>
13417         PR tree-optimization/67328
13418         * fold-const.c (maskable_range_p): New function.
13419         (build_range_check): Generate bittests if possible.
13421 2017-06-13  Martin Liska  <mliska@suse.cz>
13423         * gimple-pretty-print.c (dump_probability): Add new argument.
13424         (dump_edge_probability): Dump both probability and count.
13425         (dump_gimple_label): Likewise.
13426         (dump_gimple_bb_header): Likewise.
13428 2017-06-13  Georg-Johann Lay  <avr@gjlay.de>
13430         PR target/81072
13431         * config/avr/avr-devices.c: Fix indentation.
13432         * config/avr/gen-avr-mmcu-specs.c: Dito.
13434 2017-06-13  Richard Biener  <rguenther@suse.de>
13436         * tree-vect-loop.c (vect_model_reduction_cost): Do not fail,
13437         instead get vector type from stmt_info.
13438         (vectorizable_reduction): Adjust.  Remove dead code.
13440 2017-06-13  Richard Biener  <rguenther@suse.de>
13442         PR middle-end/81065
13443         * fold-const.c (extract_muldiv_1): Remove bogus distribution
13444         case of C * (x * C2 + C3).
13445         (fold_addr_of_array_ref_difference): Properly fold index difference.
13447 2017-06-12  David S. Miller  <davem@davemloft.net>
13449         PR target/80968
13450         * config/sparc/sparc.md (return expander): Emit frame blockage if
13451         function uses alloca.
13453 2017-06-12  Richard Sandiford  <richard.sandiford@linaro.org>
13455         * combine.c (make_field_assignment): Check len rather than the mode
13456         precision when calling force_to_mode.
13458 2017-06-12  Georg-Johann Lay  <avr@gjlay.de>
13460         Support multilibs and devices that see flash in RAM address range.
13462         PR target/81072
13463         * config/avr/avr-arch.h (avr_arch_id) <ARCH_AVRXMEGA3>: New enum.
13464         (avr_mcu_t) <flash_pm_offset>: New field.
13465         (avr_device_specific_features) <AVR_ISA_RCALL>: New enum.
13466         * config/avr/avr.h (AVR_SHORT_CALLS): New define.
13467         (AVR_HAVE_JMP_CALL): Don't set if AVR_SHORT_CALLS.
13468         (AVR_TINY_PM_OFFSET): Remove macro.
13469         * config/avr/avr.opt (-mshort-calls): New option.
13470         * config/avr/gen-avr-mmcu-specs.c (print_mcu)
13471         [*self_spec]: Add / remove -mshort-calls depending on AVR_ISA_RCALL.
13472         * config/avr/avr-c.c (avr_cpu_cpp_builtins)
13473         <__AVR_SHORT_CALLS__>: Built-in define if AVR_SHORT_CALLS.
13474         <__AVR_HAVE_JMP_CALL__>: Use AVR_HAVE_JMP_CALL as condition
13475         instead of avr_arch->have_jmp_call.
13476         <__AVR_PM_BASE_ADDRESS__>: Built-in define if avr_arch->flash_pm_offset.
13477         [AVR_TINY] <__AVR_TINY_PM_BASE_ADDRESS__>: Use
13478         avr_arch->flash_pm_offset to define.
13479         * config/avr/avr-devices.c (avr_arch_types): Add initializers for
13480         new field flash_pm_offset.  Add entry for avrxmega3.
13481         (avr_texinfo): Add entry for avrxmega3.
13482         * config/avr/avr-mcus.def: Add entries for: avrxmega3,
13483         attiny212, attiny214,
13484         attiny412, attiny414, attiny416, attiny417,
13485         attiny814, attiny816, attiny817,
13486         attiny1614, attiny1616, attiny1617,
13487         attiny3214, attiny3216, attiny3217.
13488         * config/avr/avr.c (avr_assemble_integer)[AVR_TINY]: Use
13489         avr_arch->flash_pm_offset instead of AVR_TINY_PM_OFFSET.
13490         (avr_print_operand_address) [AVR_TINY]: Same.
13491         (avr_asm_init_sections) <readonly_data_section>: Only patch
13492         callback if avr_arch->flash_pm_offset = 0.
13493         (avr_asm_named_section) <avr_need_copy_data_p>: Skip setting it
13494         for rodata if avr_arch->flash_pm_offset != 0.
13495         (avr_encode_section_info) [AVR_TINY]: Adjust comment.
13496         * config/avr/genmultilib.awk (dir_rcall, opt_rcall): New vars.
13497         (opts) [AVR_ISA_RCALL]: Append opt_rcall.
13498         (m_options): Append opt_rcall.
13499         (m_dirnames): Append dir_rcall.
13500         * config/avr/t-multilib: Regenerate.
13502         * configure.ac [target=avr]: Check whether avrxmega3 default
13503         linker description file works as needed.
13504         * configure: Regenerate.
13505         * doc/avr-mmcu.texi: Regenerate.
13506         * doc/invoke.texi (AVR Options) <-mshort-calls>: Document it.
13507         <__AVR_ARCH__>: Document avrxmega3 and 103.
13508         <__AVR_HAVE_JMP_CALL__>: Adjust documentation.
13509         <__AVR_SHORT_CALLS__>: Document it.
13510         <__AVR_PM_BASE_ADDRESS__>: Document it.
13511         * doc/extend.texi (AVR Options) <-mshort-calls>: Document it.
13512         (AVR Variable Attributes) <progmem>: Document this is
13513         not needed for avrxmega3.
13514         (AVR Named Address Spaces) <__flash>: Dito.
13516 2017-06-12  Jan Hubicka  <hubicka@ucw.cz>
13518         * cgraph.c (cgraph_node::dump): Complain about profile insanities.
13520 2017-06-12  Doug Rupp  <rupp@adacore.com>
13522         * config.gcc (*-*-vxworks*): Set use_gcc_stdint to "provide".
13523         Append vxworks-stdint.h to the tm_file list.
13524         * config/vxworks-stdint.h: New file.
13526 2017-06-12  Martin Liska  <mliska@suse.cz>
13528         PR tree-optimization/81041
13529         * tree-profile.c (gimple_gen_ic_func_profiler):
13530         Create an extra BB in profile-generate
13531         (gimple_gen_time_profiler): Likewise.
13533 2017-06-12  Jakub Jelinek  <jakub@redhat.com>
13535         PR tree-optimization/81003
13536         * tree-ssa-reassoc.c (force_into_ssa_name): New function.
13537         (update_range_test): Use it instead of force_gimple_operand_gsi.
13539 2017-06-12  Richard Biener  <rguenther@suse.de>
13541         PR tree-optimization/81053
13542         * tree-vect-loop.c (vect_is_simple_reduction): Handle PHI
13543         with backedge value not defined in loop.  Simplify def stmt
13544         compute.
13546 2017-06-11  Tom de Vries  <tom@codesourcery.com>
13548         PR target/79939
13549         * config/nvptx/nvptx.c (nvptx_cannot_force_const_mem): New function.
13550         Return true.
13551         (TARGET_CANNOT_FORCE_CONST_MEM): Redefine to
13552         nvptx_cannot_force_const_mem.
13554 2017-06-10  Jan Hubicka  <hubicka@ucw.cz>
13556         * opts.c (finish_options): Move test for flag_split_stack after
13557         it has been initialized.
13559 2017-06-11  Jason Merrill  <jason@redhat.com>
13561         * tree.h (id_equal): New.
13562         * dwarf2out.c, hsa-gen.c, ipa-devirt.c, omp-expand.c,
13563         omp-simd-clone.c, read-rtl-function.c, tree-chkp.c, tree.c: Use it
13564         instead of strcmp of IDENTIFIER_POINTER.
13566 2017-06-10  Jan Hubicka  <hubicka@ucw.cz>
13568         * ipa-inline-transform.c: Include function.h, cfg.h and basic-block.h
13569         (mark_all_inlined_calls_cdtor): Fix formating.
13570         (inline_transform): Rescale profile before inlining.
13572 2017-06-10  Jan Hubicka  <hubicka@ucw.cz>
13574         * cgraph.h (cgraph_edge::clone): Update prototype.
13575         * cgraphclones.c (cgraph_edge::clone): Update profile scaling.
13576         (cgraph_node::create_clone): Update.
13577         (cgraph_node::create_version_clone): Update.
13578         * tree-inline.c (copy_bb): Update.
13579         (expand_call_inline): Update.
13581 2017-06-10  Segher Boessenkool  <segher@kernel.crashing.org>
13583         * config/rs6000/rs6000.c (emit_vrsave_prologue): New function,
13584         factored out from ...
13585         (rs6000_emit_prologue): ... here.
13587 2017-06-10  Segher Boessenkool  <segher@kernel.crashing.org>
13589         * config/rs6000/rs6000.c (emit_split_stack_prologue): New function,
13590         factored out from ...
13591         (rs6000_emit_prologue): ... here.
13593 2017-06-10  Jan Hubicka  <hubicka@ucw.cz>
13595         * predict.c (drop_profile): Also drop individual bb/edge and cgraph
13596         edge counts.
13597         (handle_missing_profiles): Fix computation of tp_first_run.
13598         (counts_to_freqs): Do not touch freqs when count is 0.
13600 2017-06-10  Jan Hubicka  <hubicka@ucw.cz>
13602         * cgraphbuild.c (cgraph_edge::rebuild_references): Do not touch
13603         profile.
13605 2017-06-10  Tom de Vries  <tom@codesourcery.com>
13607         * doc/sourcebuild.texi (Effective-Target Keywords, Environment
13608         attributes): Document signal effective target.
13610 2017-06-10  Tom de Vries  <tom@codesourcery.com>
13612         * doc/sourcebuild.texi (Effective-Target Keywords, Other attributes):
13613         Document effective target stack_size.
13615 2017-06-09  David Malcolm  <dmalcolm@redhat.com>
13617         * diagnostic.c (diagnostic_report_diagnostic): Only add fixits
13618         to the edit_context if they can be auto-applied.
13620 2017-06-9  Ian Lance Taylor  <iant@golang.org>
13622         * opts.c (finish_options): If -fsplit-stack, disable implicit
13623         -forder-blocks-and-partition.
13624         * doc/invoke.texi (Optimize Options): Document that when using
13625         -fsplit-stack -forder-blocks-and-partition is not implicitly
13626         enabled.
13628 2017-06-09  Jan Hubicka  <hubicka@ucw.cz>
13630         * builtin-attrs.def (ATTR_NORETURN_NOTHROW_LEAF_COLD_LIST,
13631         ATTR_CONST_NORETURN_NOTHROW_LEAF_COLD_LIST,
13632         ATTR_TMPURE_NORETURN_NOTHROW_LEAF_COLD_LIST): New.
13633         * builtins.def (abort, trap, unreachable): Declare cold.
13634         * calls.c (flags_from_decl_or_type): Lookup ECF_COLD.
13635         * tree-core.h (ECF_COLD): New.
13636         * tree.c (set_call_expr_flags): Handle ECF_COLD.
13637         (build_common_builtin_nodes): Mark unreachable and abort as cold.
13639 2017-06-09  Jan Hubicka  <hubicka@ucw.cz>
13641         * predict.c (unlikely_executed_stmt_p): Cleanup.
13643 2017-06-09  Richard Biener  <rguenther@suse.de>
13645         * tree-ssa-loop-im.c (execute_sm): Do not force multi-threaded
13646         model if the ref is always written to.
13648 2017-06-09  Tamar Christina  <tamar.christina@arm.com>
13650         * config/aarch64/aarch64.md (lrint<GPF:mode><GPI:mode>2): New.
13652 2017-06-09  Tamar Christina  <tamar.christina@arm.com>
13654         * config/arm/arm.c (arm_rtx_costs_internal): Make sdiv more expensive
13655         than udiv.
13657 2017-06-09  Tom de Vries  <tom@codesourcery.com>
13659         PR target/80855
13660         * config/nvptx/nvptx.md (define_expand "mov<QHSDISDFM>"): Error out with
13661         "target cannot support label values" when encountering LABEL_REF.
13663 2017-06-09  Martin Liska  <mliska@suse.cz>
13665         * tree-profile.c (gimple_gen_ic_profiler): Update comment.
13666         (gimple_gen_ic_func_profiler): Emit direct comparison
13667         of __gcov_indirect_call_callee with NULL.
13668         (gimple_gen_time_profiler): Change probability from
13669         PROB_VERY_UNLIKELY to PROB_UNLIKELY.
13671 2017-06-09  Jan Hubicka  <hubicka@ucw.cz>
13673         * profile.c (edge_gcov_counts): Turn to pointer.
13674         (compute_branch_probabilities, compute_branch_probabilities): Update.
13675         (branch_prob): Do not clear edge_gcov_count.
13676         * profile.h (edge_gcov_counts): Turn to pointer.
13677         (edge_gcov_count): Update.
13679 2017-06-09  Jan Hubicka  <hubicka@ucw.cz>
13681         * gimple.h (gimple_check_failed): Mark cold.
13683 2017-06-09  Richard Biener  <rguenther@suse.de>
13685         PR tree-optimization/66623
13686         * tree-vect-loop.c (vect_is_simple_reduction): Cleanup,
13687         refactor check_reduction into two parts, properly computing
13688         whether we have to check reduction validity for outer loop
13689         vectorization.
13691 2017-06-09  Richard Biener  <rguenther@suse.de>
13693         PR tree-optimization/79483
13694         * graphite-scop-detection.c (order): New global.
13695         (get_order): Compute bb to order mapping that satisfies code
13696         generation constraints.
13697         (cmp_pbbs): New helper.
13698         (build_scops): Start domwalk at entry block, sort generated
13699         pbbs.
13701 2017-06-09  Richard Biener  <rguenther@suse.de>
13703         PR middle-end/81007
13704         * ipa-polymorphic-call.c
13705         (ipa_polymorphic_call_context::restrict_to_inner_class):
13706         Skip FIELD_DECLs with error_mark_node type.
13707         * passes.def (all_lowering_passes): Run pass_build_cgraph_edges
13708         last again.
13710 2017-06-09  Martin Liska  <mliska@suse.cz>
13712         * predict.c (struct branch_predictor): New struct.
13713         (test_prediction_value_range): New test.
13714         (predict_c_tests): New function.
13715         * selftest-run-tests.c (selftest::run_tests): Run the function.
13716         * selftest.h: Declare new tests.
13718 2017-06-09  Segher Boessenkool  <segher@kernel.crashing.org>
13720         PR target/80966
13721         * config/rs6000/rs6000.c (rs6000_emit_allocate_stack): Assert that
13722         gen_add3_insn did not fail.
13723         * config/rs6000/rs6000.md (add<mode>3): If asked to add a constant to
13724         r0, construct that number in a temporary reg and add that reg to r0.
13725         If asked to put the result in r0 as well, fail.
13727 2017-06-08  Will Schmidt  <will_schmidt@vnet.ibm.com>
13729         * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Add handling
13730         for early expansion of vec_eqv.
13732 2017-06-08  Jakub Jelinek  <jakub@redhat.com>
13734         PR middle-end/81005
13735         * ubsan.c (instrument_null): Avoid pointless code temporary.
13736         (pass_ubsan::execute): Instrument aggregate arguments of calls.
13738 2017-06-08  Uros Bizjak  <ubizjak@gmail.com>
13740         PR target/81015
13741         Revert:
13742         2016-12-14  Uros Bizjak  <ubizjak@gmail.com>
13744         PR target/59874
13745         * config/i386/i386.md (*ctzhi2): New insn_and_split pattern.
13746         (*clzhi2): Ditto.
13748 2017-06-08  Jan Hubicka  <hubicka@ucw.cz>
13750         * predict.c (unlikely_executed_edge_p): Move ahead.
13751         (probably_never_executed_edge_p): Use it.
13753 2017-06-08  Alexander Ivchenko  <alexander.ivchenko@intel.com>
13755         PR middle-end/79988
13756         * tree-chkp.c (chkp_gimple_call_builtin_p): Remove
13757         gimple_call_builtin_p call.
13759 2017-06-08  Jan Hubicka  <hubicka@ucw.cz>
13761         * system.h (fancy_abort): Annotate by ATTRIBUTE_COLD.
13762         * rtl.h (rtl_check_failed_bounds, rtl_check_failed_type1,
13763         rtl_check_failed_type2, rtl_check_failed_code1,
13764         rtl_check_failed_code2, rtl_check_failed_code_mode,
13765         rtl_check_failed_block_symbol, cwi_check_failed_bounds,
13766         rtvec_check_failed_bounds, rtl_check_failed_flag,
13767         _fatal_insn_not_found, _fatal_insn): Likewise.
13768         * tree.h (tree_contains_struct_check_failed,
13769         tree_check_failed, tree_not_check_failed,
13770         tree_class_check_failed, tree_range_check_failed,
13771         tree_not_class_check_failed, tree_int_cst_elt_check_failed,
13772         tree_vec_elt_check_failed, phi_node_elt_check_failed,
13773         tree_operand_check_failed, omp_clause_check_failed,
13774         omp_clause_operand_check_failed, omp_clause_range_check_failed):
13775         Likewise.
13777 2017-06-08  Jan Hubicka  <hubicka@ucw.cz>
13779         * cgraph.c (cgraph_edge::maybe_hot_p): Do not check
13780         flag_branch_probabilities.
13781         * ipa-inline.c (edge_badness): Likewise.
13782         * ipa-profile.c (ipa_propagate_frequency_1): Likewise.
13783         * postreload-gcse.c (eliminate_partially_redundant_load): Likewise.
13784         * predict.c (maybe_hot_frequency_p): Likewise.
13785         (probably_never_executed): Likewise.
13786         * sched-ebb.c (schedule_ebbs): Likewise.
13787         * sched-rgn.c (find_single_block_region): Likewise.
13788         * tracer.c (tail_duplicate): Likewise.
13790 2017-06-08  Jan Hubicka  <hubicka@ucw.cz>
13792         * opts.c (finish_options): x_flag_reorder_blocks_and_partition no
13793         longer requires x_flag_profile_use.
13795 2017-06-08  Jan Hubicka  <hubicka@ucw.cz>
13797         * cfgrtl.c (cfg_layout_initialize): Check crtl->has_bb_partition
13798         instead of flag_reorder_blocks_and_partition.
13799         * dbxout.c (dbxout_function_end): Likewise.
13800         * dwarf2out.c (gen_subprogram_die): Likewise.
13801         * haifa-sched.c (sched_create_recovery_edges): Likewise.
13802         * hw-doloop.c (reorg_loops): Likewise.
13803         * varasm.c (assemble_start_function,
13804         assemble_end_function): Likewise.
13805         (decide_function_section): Do not check for
13806         flag_reorder_blocks_and_partition.
13808 2017-06-08  Alexander Ivchenko  <alexander.ivchenko@intel.com>
13810         * tree-chkp.c (chkp_get_hard_register_var_fake_base_address):
13811         New function.
13812         (chkp_get_hard_register_fake_addr_expr): Ditto.
13813         (chkp_build_addr_expr): Add check for hard reg case.
13814         (chkp_parse_array_and_component_ref): Ditto.
13815         (chkp_find_bounds_1): Ditto.
13816         (chkp_process_stmt): Don't generate bounds store for
13817         hard reg case.
13819 2017-06-08  Jan Hubicka  <hubicka@ucw.cz>
13821         * predict.c (maybe_hot_bb_p): Do not check profile status.
13822         (maybe_hot_edge_p): Likewise.
13823         (probably_never_executed): Check for zero counts even if profile
13824         is not read.
13825         (unlikely_executed_edge_p): New function.
13826         (unlikely_executed_stmt_p): New function.
13827         (unlikely_executed_bb_p): New function.
13828         (set_even_probabilities): Use unlikely predicates.
13829         (combine_predictions_for_bb): Likewise.
13830         (predict_paths_for_bb): Likewise.
13831         (predict_paths_leading_to_edge): Likewise.
13832         (determine_unlikely_bbs): New function.
13833         (estimate_bb_frequencies): Use it.
13834         (compute_function_frequency): Use zero counts even if profile is
13835         not read.
13836         * profile-count.h: Fix typo.
13838 2017-08-08  Julia Koval  <julia.koval@intel.com>
13840         * config/i386/avx512bwintrin.h (_mm512_mask_cvtepi16_storeu_epi8,
13841         _mm512_mask_cvtsepi16_storeu_epi8,
13842         _mm512_mask_cvtusepi16_storeu_epi8): New intrinsics.
13843         * config/i386/avx512vlbwintrin.h (_mm256_mask_cvtepi16_storeu_epi8,
13844         _mm_mask_cvtsepi16_storeu_epi8, _mm256_mask_cvtsepi16_storeu_epi8,
13845         _mm_mask_cvtusepi16_storeu_epi8, _mm256_mask_cvtusepi16_storeu_epi8,
13846         _mm_mask_cvtepi16_storeu_epi8): New intrinsics.
13847         * config/i386/i386-builtin-types.def (PV8Q, V8QI): New pointer type.
13848         (VOID_FTYPE_PV32QI_V32HI_USI, VOID_FTYPE_PV8QI_V8HI_UQI,
13849         VOID_FTYPE_PV16QI_V16HI_UHI): New function types.
13850         * config/i386/i386-builtin.def (__builtin_ia32_pmovwb128mem_mask,
13851         __builtin_ia32_pmovwb256mem_mask, __builtin_ia32_pmovswb128mem_mask,
13852         __builtin_ia32_pmovswb256mem_mask, __builtin_ia32_pmovuswb128mem_mask,
13853         __builtin_ia32_pmovuswb256mem_mask,
13854         __builtin_ia32_pmovuswb512mem_mask, __builtin_ia32_pmovswb512mem_mask)
13855         __builtin_ia32_pmovwb512mem_mask): New builtins.
13857 2017-08-08  Julia Koval  <julia.koval@intel.com>
13859         PR target/73350,80862
13860         * config/i386/subst.md (round): Fix round pattern.
13861         * config/i386/i386.c (ix86_erase_embedded_rounding):
13862         Fix erasing rounding for the fixed pattern.
13864 2017-06-08  Jan Hubicka  <hubicka@ucw.cz>
13866         * cfgbuild.c (find_many_sub_basic_blocks): Fix thinko.
13868 2017-06-08  Martin Liska  <mliska@suse.cz>
13870         PR gcov-profile/80911
13871         * gcov.c (block_info::block_info): New constructor.
13873 2017-06-07  Carl Love  <cel@us.ibm.com>
13875         * config/rs6000/rs6000-c: The return type of the following
13876         built-in functions was implemented as int not long long.  Fix sign
13877         of return value for the unsigned version of vec_mulo and vec_mule.
13878         vector unsigned long long vec_bperm (vector unsigned long long,
13879                                              vector unsigned char)
13880         vector signed long long vec_mule (vector signed int,
13881                                           vector signed int)
13882         vector unsigned long long vec_mule (vector unsigned int,
13883                                             vector unsigned int)
13884         vector signed long long vec_mulo (vector signed int,
13885                                           vector signed int)
13886         vector unsigned long long vec_mulo (vector unsigned int,
13887                                             vector unsigned int)
13888         * doc/extend.texi: Fix the documentation for the built-in
13889         functions.
13891 2017-06-07  Carl Love  <cel@us.ibm.com>
13893         PR target/80982
13894         * config/rs6000/altivec.md (double<mode>2): Fix the implementation of
13895         for BE.
13897 2017-06-07  Carl Love  <cel@us.ibm.com>
13899         * config/rs6000/altivec.md: Fix argument swizzle in vec_doublel
13900         support, Generate       doublehv for signed int/float for BE case only.
13902 2017-06-07  Alexander Monakov  <amonakov@ispras.ru>
13904         * doc/invoke.texi (mcx16): Rewrite.
13906 2017-06-07  Segher Boessenkool  <segher@kernel.crashing.org>
13908         * config/rs6000/predicates.md (rs6000_nonimmediate_operand): Delete.
13909         * config/rs6000/rs6000.md (*movsi_internal1, movsi_from_sf,
13910         *mov<mode>_softfloat, and an anonymous splitter): Use
13911         nonimmediate_operand instead of rs6000_nonimmediate_operand.
13913 2017-06-07  Segher Boessenkool  <segher@kernel.crashing.org>
13915         * config/rs6000/darwin.h (REGISTER_NAMES): Delete the SPE_ACC and
13916         SPEFSCR registers.
13917         * config/rs6000/rs6000.c (rs6000_reg_names, alt_reg_names): Ditto.
13918         (enum rs6000_reg_type): Delete SPE_ACC_TYPE and SPEFSCR_REG_TYPE.
13919         (rs6000_debug_reg_global): Adjust.
13920         (rs6000_init_hard_regno_mode_ok): Adjust.
13921         (rs6000_dbx_register_number): Adjust.
13922         * config/rs6000/rs6000.h (FIRST_PSEUDO_REGISTER): Change to 115.
13923         (FIXED_REGISTERS, CALL_USED_REGISTERS, CALL_REALLY_USED_REGISTERS):
13924         Remove SPE_ACC and SPEFSCR.
13925         (REG_ALLOC_ORDER): Ditto.
13926         (FRAME_POINTER_REGNUM): Change to 111.
13927         (enum reg_class): Remove the SPE_ACC and SPEFSCR registers.
13928         (REG_CLASS_NAMES): Ditto.
13929         (REG_CLASS_CONTENTS): Delete the SPE_ACC and SPEFSCR registers.
13930         (REGISTER_NAMES): Ditto.
13931         (ADDITIONAL_REG_NAMES): Ditto.
13932         (rs6000_reg_names): Ditto.
13933         * config/rs6000/rs6000.md: Renumber some register number
13934         define_constants.
13936 2017-06-07  Segher Boessenkool  <segher@kernel.crashing.org>
13938         * config/rs6000/darwin.h (REGISTER_NAMES): Delete the SPE high
13939         registers.
13940         * config/rs6000/rs6000.c (rs6000_reg_names, alt_reg_names): Ditto.
13941         * config/rs6000/rs6000.h (FIRST_PSEUDO_REGISTER): Change from 149
13942         to 117.
13943         (DWARF_REG_TO_UNWIND_COLUMN): Do not define.
13944         (FIXED_REGISTERS, CALL_USED_REGISTERS, CALL_REALLY_USED_REGISTERS):
13945         Delete the SPE high registers.
13946         (REG_ALLOC_ORDER): Ditto.
13947         (enum reg_class): Remove SPE_HIGH_REGS.
13948         (REG_CLASS_NAMES): Ditto.
13949         (REG_CLASS_CONTENTS): Delete the SPE high registers.
13950         (REGISTER_NAMES): Ditto.
13951         (rs6000_reg_names): Ditto.
13952         * doc/tm.texi.in: Remove SPE as example.
13953         * doc/tm.texi: Regenerate.
13955 2017-06-07  Segher Boessenkool  <segher@kernel.crashing.org>
13957         * config/rs6000/8540.md (ppc8540_brinc): Delete.
13958         * config/rs6000/e500mc.md (e500mc_brinc): Delete.
13959         * config/rs6000/e500mc64.md (e500mc64_brinc): Delete.
13960         * config/rs6000/rs6000.md (type): Remove "brinc".
13962 2017-06-07  Segher Boessenkool  <segher@kernel.crashing.org>
13964         * config.gcc (powerpc*-*-*): Don't add spe.h to extra_headers.
13965         (powerpc*-linux*spe*): Use ${cpu_type} instead of rs6000.
13966         * config/rs6000/linuxspe.h: Delete file.
13967         * config/rs6000/rs6000.md: Don't include spe.md.
13968         * config/rs6000/spe.h: Delete file.
13969         * config/rs6000/spe.md: Delete file.
13970         * config/rs6000/t-rs6000: Remove spe.md.
13972 2017-06-07  Segher Boessenkool  <segher@kernel.crashing.org>
13974         * config/rs6000/predicates.md (reg_or_mem_operand): Reformat.
13975         (reg_or_none500mem_operand): Delete.
13976         * config/rs6000/rs6000.md (extendsfdf2): Use reg_or_mem_operand
13977         instead of reg_or_none500mem_operand.
13979 2017-06-07  Segher Boessenkool  <segher@kernel.crashing.org>
13981         * config/rs6000/rs6000.c (rs6000_option_override_internal): Delete
13982         handling of SPE flags.
13983         * config/rs6000/rs6000.opt (-mspe, -mspe=no, -mspe=yes): Delete.
13985 2017-06-07  Segher Boessenkool  <segher@kernel.crashing.org>
13987         * config/rs6000/rs6000-common.c (rs6000_handle_option): Remove
13988         SPE ABI handling.
13989         * config/rs6000/paired.md (paired_negv2sf2): Rename to negv2sf2.
13990         (paired_absv2sf2, paired_addv2sf3, paired_subv2sf3, paired_mulv2sf3,
13991         paired_divv2sf3): Similar.
13992         * config/rs6000/predicates.md: Replace TARGET_SPE, TARGET_SPE_ABI,
13993         SPE_VECTOR_MODE and SPE_HIGH_REGNO_P by 0; simplify.
13994         * config/rs6000/rs6000-builtin.def: Delete RS6000_BUILTIN_E and
13995         RS6000_BUILTIN_S.
13996         Delete BU_SPE_1, BU_SPE_2, BU_SPE_3, BU_SPE_E, BU_SPE_P, and BU_SPE_X.
13997         Rename the paired_* instruction patterns.
13998         * config/rs6000/rs6000-c.c (rs6000_target_modify_macros): Do not
13999         define __SPE__.
14000         * config/rs6000/rs6000-protos.h (invalid_e500_subreg): Delete.
14001         * config/rs6000/rs6000.c: Delete RS6000_BUILTIN_E and RS6000_BUILTIN_S.
14002         (struct rs6000_stack): Delete fields spe_gp_save_offset, spe_gp_size,
14003         spe_padding_size, and spe_64bit_regs_used.  Replace TARGET_SPE and
14004         TARGET_SPE_ABI with 0, simplify.  Replace SPE_VECTOR_MODE with
14005         PAIRED_VECTOR_MODE.
14006         (struct machine_function): Delete field spe_insn_chain_scanned_p.
14007         (spe_func_has_64bit_regs_p): Delete.
14008         (spe_expand_predicate_builtin): Delete.
14009         (spe_expand_evsel_builtin): Delete.
14010         (TARGET_DWARF_REGISTER_SPAN): Do not define.
14011         (TARGET_MEMBER_TYPE_FORCES_BLK): Do not define.
14012         (invalid_e500_subreg): Delete.
14013         (rs6000_legitimize_address): Always force_reg op2 as well, for
14014         paired single memory accesses.
14015         (rs6000_member_type_forces_blk): Delete.
14016         (rs6000_spe_function_arg): Delete.
14017         (rs6000_expand_unop_builtin): Delete SPE handling.
14018         (rs6000_expand_binop_builtin): Ditto.
14019         (spe_expand_stv_builtin): Delete.
14020         (bdesc_2arg_spe): Delete.
14021         (spe_expand_builtin): Delete.
14022         (spe_expand_predicate_builtin): Delete.
14023         (spe_expand_evsel_builtin): Delete.
14024         (rs6000_invalid_builtin): Remove RS6000_BTM_SPE handling.
14025         (spe_init_builtins): Delete.
14026         (spe_func_has_64bit_regs_p): Delete.
14027         (savres_routine_name): Delete "info" parameter.  Adjust callers.
14028         (rs6000_emit_stack_reset): Ditto.
14029         (rs6000_dwarf_register_span): Delete.
14030         * config/rs6000/rs6000.h (TARGET_SPE_ABI, TARGET_SPE,
14031         UNITS_PER_SPE_WORD, SPE_HIGH_REGNO_P, SPE_SIMD_REGNO_P,
14032         SPE_VECTOR_MODE, RS6000_BTM_SPE, RS6000_BUILTIN_E, RS6000_BUILTIN_S):
14033         Delete.
14034         * config/rs6000/rs6000.md (FIRST_SPE_HIGH_REGNO, LAST_SPE_HIGH_REGNO):
14035         Delete.
14036         * config/rs6000/rs6000.opt (-mabi=spe, -mabi=no-spe): Delete.
14037         * config/rs6000/spe.md: Delete every pattern that uses TARGET_SPE.
14038         * config/rs6000/vector.md (absv2sf2, negv2sf2, addv2sf3, subv2sf3,
14039         mulv2sf3, divv2sf3): Delete expanders.
14041 2017-06-07  Segher Boessenkool  <segher@kernel.crashing.org>
14043         config/rs6000/rs6000.md (UNSPEC_MV_CR_GT): Delete.
14045 2017-06-07  Segher Boessenkool  <segher@kernel.crashing.org>
14047         * config/rs6000/rs6000-protos.h (output_e500_flip_gt_bit): Delete.
14048         * config/rs6000/rs6000.c: Ditto.
14050 2017-06-07  Segher Boessenkool  <segher@kernel.crashing.org>
14052         * config/rs6000/predicated.md (rs6000_cbranch_operator): Delete.
14053         * config/rs6000/rs6000.md: Replace rs6000_cbranch_operator by
14054         comparison_operator.
14056 2017-06-07  Segher Boessenkool  <segher@kernel.crashing.org>
14058         * config/rs6000/rs6000.c: Remove everything related to -mfloat-gprs.
14059         * config/rs6000/rs6000.opt: Ditto.
14060         * config/rs6000/t-rtems: Ditto.
14062 2017-06-07  Segher Boessenkool  <segher@kernel.crashing.org>
14064         * config/rs6000/predicates.md: Replace TARGET_E500_DOUBLE and
14065         TARGET_E500_SINGLE by 0, simplify.
14066         * config/rs6000/rs6000.c: Ditto.
14067         (rs6000_option_override_internal): Delete CHECK_E500_OPTIONS.
14068         (spe_build_register_parallel): Delete.
14069         * config/rs6000/rs6000.h: Delete TARGET_E500_SINGLE,
14070         TARGET_E500_DOUBLE, and CHECK_E500_OPTIONS.
14071         * config/rs6000/rs6000.md: Replace TARGET_E500_DOUBLE,
14072         TARGET_E500_SINGLE, and <E500_CONVERT> by 0, simplify.
14073         (E500_CONVERT): Delete.
14074         * config/rs6000/spe.md: Remove many patterns and all define_constants.
14076 2017-06-07  Segher Boessenkool  <segher@kernel.crashing.org>
14078         * config/rs6000/darwin.md: Replace TARGET_FPRS by 1 and simplify.
14079         * config/rs6000/dfp.md: Ditto.
14080         (negdd2, *negdd2_fpr): Merge.
14081         (absdd2, *absdd2_fpr): Merge.
14082         (negtd2, *negtd2_fpr): Merge.
14083         (abstd2, *abstd2_fpr): Merge.
14084         * config/rs6000/e500.h: Delete file.
14085         * config/rs6000/predicates.md (rs6000_cbranch_operator): Replace
14086         TARGET_FPRS by 1 and simplify.
14087         * config/rs6000/rs6000-c.c: Ditto.
14088         * config/rs6000/rs6000.c: Ditto.  Also replace TARGET_SF_SPE and
14089         TARGET_DF_SPE by 0.
14090         * config/rs6000/rs6000.h: Ditto.  Delete TARGET_SF_SPE and
14091         TARGET_DF_SPE.
14092         * config/rs6000/rs6000.md: Ditto.
14093         (floatdidf2, *floatdidf2_fpr): Merge.
14094         (move_from_CR_gt_bit): Delete.
14095         * config/rs6000/spe.md: Replace TARGET_FPRS by 1 and simplify.
14096         (E500_CR_IOR_COMPARE): Delete.
14097         (All patterns that require !TARGET_FPRS): Delete.
14098         * config/rs6000/vsx.md: Replace TARGET_FPRS by 1 and simplify.
14100 2017-06-07  Bin Cheng  <bin.cheng@arm.com>
14102         * passes.def (pass_iv_canon): Move before pass_loop_distribution.
14104 2017-06-07  Bin Cheng  <bin.cheng@arm.com>
14106         * graphds.c (add_edge): Intitialize edge's attached data.
14107         (foll_in_subgraph, dfs_fst_edge, dfs_next_edge): New function
14108         pointer parameter.  Call pointed function on each edge during
14109         graph traversing.  Skip traversing the edge when the function
14110         returns true.
14111         (graphds_dfs, graphds_scc): Ditto.
14112         (for_each_edge): New parameter.  Pass the new parameter to callback
14113         function.
14114         * graphds.h (skip_edge_callback): New function pointer type.
14115         (graphds_dfs, graphds_scc): New function pointer parameter.
14116         (graphds_edge_callback, for_each_edge): New parameter.
14118 2017-06-07  Bin Cheng  <bin.cheng@arm.com>
14120         * tree-vect-data-refs.c (vect_mark_for_runtime_alias_test): Factor
14121         out code checking if runtime alias check is possible to below ...
14122         Call the new function.
14123         * tree-data-ref.c (runtime_alias_check_p): ... to new function.
14124         * tree-data-ref.h (runtime_alias_check_p): New decalaration.
14126 2017-06-07  Marek Polacek  <polacek@redhat.com>
14128         PR sanitizer/80932
14129         * fold-const.c (extract_muldiv_1) <case MINUS_EXPR>: Add
14130         TYPE_OVERFLOW_WRAPS check.
14132 2017-06-07  Bin Cheng  <bin.cheng@arm.com>
14134         * tree-vect-loop-manip.c (vect_do_peeling): Don't skip vector loop
14135         if versioning is required.
14136         * tree-vect-loop.c (vect_analyze_loop_2): Merge niter check for loop
14137         peeling with the check for versioning.
14139 2017-06-07  Bin Cheng  <bin.cheng@arm.com>
14141         * tree-vectorizer.h (vect_build_loop_niters): New parameter.
14142         * tree-vect-loop-manip.c (vect_build_loop_niters): New parameter.
14143         Set true to new parameter if new ssa variable is defined.
14144         (vect_gen_vector_loop_niters): Refactor.  Set range information
14145         for the new vector loop bound variable.
14146         (vect_do_peeling): Ditto.
14148 2017-06-07  Bin Cheng  <bin.cheng@arm.com>
14150         * tree-affine.c (ssa.h): Include header file.
14151         (tree_to_aff_combination): Handle (T1)(X - CST) when inner type
14152         has wrapping overflow behavior.
14154 2017-06-07  Bin Cheng  <bin.cheng@arm.com>
14156         * tree-affine.c (tree_to_aff_combination): Handle (T1)(X + X).
14158 2017-06-07  Bin Cheng  <bin.cheng@arm.com>
14160         (aff_combination_expand): Move (T1)(X *+- CST) simplification to ...
14161         (tree_to_aff_combination): ... here.
14163 2017-06-07  Bin Cheng  <bin.cheng@arm.com>
14165         * tree-ssa-loop-ivopts.c (ivopts_estimate_reg_pressure): New
14166         reg_pressure model function.
14167         (ivopts_global_cost_for_size): Delete.
14168         (determine_set_costs, iv_ca_recount_cost): Call new model function
14169         ivopts_estimate_reg_pressure.
14171 2017-06-07  Tamar Christina  <tamar.christina@arm.com>
14173         * config/aarch64/aarch64.c (aarch64_rtx_costs): Make sdiv more
14174         expensive than udiv.  Remove floating point cases from mod.
14176 2017-06-07  Tamar Christina  <tamar.christina@arm.com>
14178         * config/arm/aarch-cost-tables.h (cortexa53_extra_cost):
14179         Increase idiv cost.
14181 2017-06-07  Tamar Christina  <tamar.christina@arm.com>
14183         * config/aarch64/aarch64.md
14184         (copysignsf3): Fix mask generation.
14186 2017-06-07  Jakub Jelinek  <jakub@redhat.com>
14188         * dumpfile.h (enum tree_dump_index): Rename TDI_generic to
14189         TDI_gimple.
14190         (class dump_manager): Add register_dumps method.
14191         * dumpfile.c: Include langhooks.h.
14192         (dump_files): Use 0 instead of 3/4/5 for TDI_{original,gimple,nested}.
14193         (FIRST_AUTO_NUMBERED_DUMP): Decrease to 1.
14194         (FIRST_ME_AUTO_NUMBERED_DUMP): Define.
14195         (dump_manager::dump_register): Start with 512 entries instead of 32.
14196         (dump_manager::register_dumps): New method.
14197         * toplev.c (general_init): Instead of invoking register_dumps
14198         langhook, invoke register_dumps method on the dump manager.
14199         * gimplify.c (gimplify_function_tree): Use TDI_gimple instead of
14200         TDI_generic.
14202 2017-06-07  Richard Sandiford  <richard.sandiford@linaro.org>
14204         * doc/md.texi: Clarify the restrictions on a define_insn condition.
14205         Say that # requires an associated define_split to exist, and that
14206         the define_split must be suitable for use after register allocation.
14208 2017-06-06  Jan Hubicka  <hubicka@ucw.cz>
14210         * cfgbuild.c (find_bb_boundaries): Initialize profile of split blocks.
14211         (compute_outgoing_frequencies): Also initialize zero counts.
14212         (find_many_sub_basic_blocks): Do not produce uninitialized profile
14213         around loops; preserve more of profile when nothing changes.
14215 2017-06-06  Jim Wilson  <jim.wilson@linaro.org>
14217         * config/aarch64/aarch64-cost-tables.h (qdf24xx_extra_costs): Move to
14218         here.
14219         * config/arm/aarch-cost-tables.h (qdf24xx_extra_costs): From here.
14220         * config/arm/arm-cpu-cdata.h: Regenerate.
14221         * config/arm/arm-cpu-data.h, config/arm/arm-cpu.h: Likewise.
14222         * config/arm/arm-tables.opt, config/arm/arm-tune.md: Likewise.
14223         * config/arm/arm-cpus.in: Delete falkor and qdf24xx entries.
14224         * config/arm/arm.c (arm_qdf24xx_tune): Delete.
14225         * config/arm/bpabi.h (BE8_LINK_SPEC): Delete falkor and qdf24xx
14226         support.
14227         * config/arm/t-aprofile (MULTILIB_MATCHES): Delete falkor and qdf24xx
14228         support.
14229         * config/arm/t-rmprofile: Likewise.
14230         * doc/invoke.texi (ARM Options): Drop falkor and qdf24xx support.
14232 2017-06-06  David S. Miller  <davem@davemloft.net>
14234         PR target/80968
14235         * config/sparc/sparc.c (sparc_expand_prologue): Emit frame
14236         blockage if function uses alloca.
14238 2017-06-06  Maxim Kuvyrkov  <maxim.kuvyrkov@linaro.org>
14240         * tree-ssa-loop-prefetch.c (struct mem_ref_group, struct mem_ref):
14241         New "uid" fields to hold pretty-print IDs of group and ref.
14242         Memory references are now identified as <group_id>:<ref_id>
14243         instead of using [random] addresses.
14244         (dump_mem_details): Simplify, no functional change.
14245         (dump_mem_ref): Simplify and make output more concise.
14246         Replace couple of fprintf's throughout code with calls to dump_mem_ref.
14247         (find_or_create_group): Initialize group uid.
14248         (record_ref): Initialize ref uid.  Improve debug output.
14249         (prune_group_by_reuse, should_issue_prefetch_p,)
14250         (should_issue_prefetch_p, schedule_prefetches, issue_prefetch_ref,)
14251         (mark_nontemporal_store, determine_loop_nest_reuse):
14252         Improve debug output.
14254 2017-06-06  Maxim Kuvyrkov  <maxim.kuvyrkov@linaro.org>
14256         * dbgcnt.def (prefetch): New debug counter.
14257         * tree-ssa-loop-prefetch.c (dbgcnt.h): New include.
14258         (schedule_prefetches): Stop issueing prefetches if debug counter
14259         tripped.
14261 2017-06-06  Tom de Vries  <tom@codesourcery.com>
14263         * doc/sourcebuild.texi (Testsuites, C Language Testsuites,
14264         gcc.c-torture/compile): Remove mention of NO_LABEL_VALUES in fixme.
14266 2017-06-06  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
14268         * config/aarch64/atomics.md (atomic_compare_and_swap<mode> expander):
14269         Use aarch64_reg_or_zero predicate for operand 4.
14270         (aarch64_compare_and_swap<mode> define_insn_and_split):
14271         Use aarch64_reg_or_zero predicate for operand 3.  Add 'Z' constraint.
14272         (aarch64_store_exclusive<mode>): Likewise for operand 2.
14274 2017-06-06  Thomas Preud'homme  <thomas.preudhomme@arm.com>
14276         * config/arm/arm.c (arm_compute_save_reg_mask): Rename into ...
14277         (arm_compute_save_core_reg_mask): This.
14278         (thumb1_compute_save_reg_mask): Rename into ...
14279         (thumb1_compute_save_core_reg_mask): This.
14280         (arm_compute_save_reg0_reg12_mask): Adapt comment.
14281         (arm_compute_frame_layout): Likewise.
14283 2017-06-06  Richard Biener  <rguenther@suse.de>
14285         PR tree-optimization/80974
14286         * tree-ssa-sccvn.c (set_ssa_val_to): Do not change but only
14287         keep or clear leaders SSA info.
14289 2017-06-06  Tom de Vries  <tom@codesourcery.com>
14291         * config/nvptx/nvptx.c (split_mode_p): New function.
14292         (nvptx_declare_function_name, nvptx_print_operand): Use split_mode_p.
14294 2017-06-06  Tom de Vries  <tom@codesourcery.com>
14296         * config/nvptx/nvptx.c (nvptx_print_operand): Use maybe_split_mode.
14298 2017-06-06  Jan Hubicka  <hubicka@ucw.cz>
14300         PR bootstrap/80978
14301         * tree-cfg.c (execute_fixup_cfg): Fix condition on when to rescale
14302         profile.
14304 2017-06-06  Jan Hubicka  <hubicka@ucw.cz>
14306         * shrink-wrap.c (handle_simple_exit): Update profile.
14307         (try_shrink_wrapping): Upate profile.
14309 2017-06-06  Jan Hubicka  <hubicka@ucw.cz>
14311         * predict.c (tree_estimate_probability_bb): Add LOCAL_ONLY.
14312         (tree_guess_outgoing_edge_probabilities): New.
14313         * predict.h (tree_guess_outgoing_edge_probabilities): Declare.
14314         * tree-cfg.c (gimple_find_sub_bbs): Propagate profile.
14316 2017-06-06  Jan Hubicka  <hubicka@ucw.cz>
14318         * ipa-split.c (split_function): Initialize return bb profile.
14320 2017-06-06  Jan Hubicka  <hubicka@ucw.cz>
14322         * profile.c (compute_branch_probabilities): Also initialize
14323         EXIT_BLOCK profile.
14325 2017-06-06  Richard Biener  <rguenther@suse.de>
14327         PR tree-optimization/80928
14328         * tree-vect-loop.c (vect_update_vf_for_slp): Amend dumps.
14329         (vect_analyze_loop_operations): Properly guard analysis for
14330         pure SLP case.
14331         (vect_transform_loop): Likewise.
14332         (vect_analyze_loop_2): Also reset SLP type on PHIs.
14333         (vect_model_induction_cost): Do not cost for pure SLP.
14334         (vectorizable_induction): Pass in SLP node, implement SLP vectorization
14335         of induction in inner loop vectorization.
14336         * tree-vect-slp.c (vect_create_new_slp_node): Handle PHIs.
14337         (vect_get_and_check_slp_defs): Handle vect_induction_def.
14338         (vect_build_slp_tree): Likewise.  Handle PHIs as terminating the
14339         recursion.
14340         (vect_analyze_slp_cost_1): Cost induction.
14341         (vect_detect_hybrid_slp_stmts): Handle PHIs.
14342         (vect_get_slp_vect_defs): Likewise.
14343         * tree-vect-stmts.c (vect_analyze_stmt): Handle induction.
14344         (vect_transform_stmt): Handle SLP reductions.
14345         * tree-vectorizer.h (vectorizable_induction): Adjust.
14347 2017-06-05  Michael Meissner  <meissner@linux.vnet.ibm.com>
14349         * config/rs6000/rs6000.c (make_resolver_func): Update
14350         init_lowered_empty_function call.
14352 2017-06-05  Bernd Edlinger  <bernd.edlinger@hotmail.de>
14354         * doc/invoke.texi: Document the -fprofile-abs-path option.
14355         * common.opt (fprofile-abs-path): New option.
14356         * gcov-io.h (gcov_write_filename): Declare.
14357         * gcov-io.c (gcov_write_filename): New function.
14358         * coverage.c (coverage_begin_function): Use gcov_write_filename.
14359         * profile.c (output_location): Likewise.
14361 2017-06-05  Jan Hubicka  <hubicka@ucw.cz>
14363         * shring-wrap.c: Revert accidental commit.
14365 2017-06-05  Volker Reichelt  <v.reichelt@netcologne.de>
14367         * doc/invoke.texi (-Wduplicated-branches): Add to warning list.
14369 2017-06-05  Jan Hubicka  <hubicka@ucw.cz>
14371         * cfgexpand.c (expand_gimple_tailcall): Initialize profile of
14372         new edge.
14373         * ipa-inline.c (want_inline_self_recursive_call_p): Watch for missing
14374         profile in callgraph edge.
14375         * profile-count.h (apply_probability): If THIS is 0, then result is 0
14376         (apply_scale): Likewise.
14377         * tree-inline.c (copy_bb, copy_edges_for_bb, copy_cfg_body):
14378         Also scale profile when inlining function with zero profile.
14379         (initialize_cfun): Update exit block profile even when it is zero.
14380         * tree-ssa-threadupdate.c (clear_counts_path): Handle correctly case
14381         when profile is read.
14383 2017-06-05  Michael Meissner  <meissner@linux.vnet.ibm.com>
14385         * config/rs6000/rs6000.c (toplevel): Include attribs.h.
14386         (CLONE_*): New constants to define the processors we can generate
14387         code for with the target_clone attribute.
14388         (rs6000_clone_map): New array to identify which clone processors
14389         the current program is running on.
14390         (TARGET_COMPARE_VERSION_PRIORITY): Define to enable the
14391         target_clone attribute.
14392         (TARGET_GENERATE_VERSION_DISPATCHER_BODY): Likewise.
14393         (TARGET_GET_FUNCTION_VERSIONS_DISPATCHER): Likewise.
14394         (TARGET_OPTION_FUNCTION_VERSIONS): Likewise.
14395         (cpu_expand_builtin): Add support for target_clone attribute.
14396         (rs6000_valid_attribute_p): Allow "default" attribute.
14397         (get_decl_name): New debug function to simplify printing the
14398         current function name in debugging statements.
14399         (rs6000_clone_priority): New functions to support the target_clone
14400         attribute, and be able to generate code to switch between ISA 2.05
14401         through ISA 3.0 (power6 through power9).
14402         (rs6000_compare_version_priority): Likewise.
14403         (rs6000_get_function_versions_dispatcher): Likewise.
14404         (make_resolver_func): Likewise.
14405         (add_condition_to_bb): Likewise.
14406         (dispatch_function_versions): Likewise.
14407         (rs6000_generate_version_dispatcher_body): Likewise.
14408         (rs6000_can_inline_p): Call get_decl_name for debugging usage.
14409         (fusion_gpr_load_p): Fix a spacing issue.
14410         * doc/extend.texi (Common Function Attributes): Document that the
14411         PowerPC supports the target_clone attribute.
14413 2017-06-05  Thomas Preud'homme  <thomas.preudhomme@arm.com>
14415         * config/arm/arm.h: explain F symbol found in description of ARM
14416         register allocation in its legend.
14418 2017-06-05  Jan Hubicka  <hubicka@ucw.cz>
14420         * config/mips/frame-header-opt.c: Include profile-count.h.
14421         * config/riscv/riscv.c: Include profile-count.h
14423 2017-06-05  Jan Hubicka  <hubicka@ucw.cz>
14425         * tree-ssa-loop-im.c (execute_sm_if_changed): Add FLAG_BBS parameter;
14426         update profile.
14427         (sm_set_flag_if_changed): Add bbs field.
14428         (execute_sm_if_changed_flag_set): Pass BBS.
14429         (execute_sm): Update.
14431 2017-06-05  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
14433         * config/aarch64/aarch64-simd.md (aarch64_store_lane0<mode>):
14434         New pattern.
14436 2017-06-05  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
14438         * config/aarch64/aarch64.md (sub<mode>3_compare1_imm): New define_insn.
14439         (peephole2): New peephole2 to emit the above.
14440         * config/aarch64/predicates.md (aarch64_sub_immediate): New predicate.
14442 2017-06-05  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
14444         * config/aarch64/aarch64.c (define_peephole2 above
14445         *sub_<shift>_<mode>): New peephole.
14447 2017-05-23  Jan Hubicka  <hubicka@ucw.cz>
14449         * config/i386/i386.c (make_resolver_func): Update.
14450         * Makefile.in: Add profile-count.h and profile-count.o
14451         * auto-profile.c (afdo_indirect_call): Update to new API.
14452         (afdo_set_bb_count): Update.
14453         (afdo_propagate_edge): Update.
14454         (afdo_propagate_circuit): Update.
14455         (afdo_calculate_branch_prob): Update.
14456         (afdo_annotate_cfg): Update.
14457         * basic-block.h: Include profile-count.h
14458         (struct edge_def): Turn count to profile_count.
14459         (struct basic_block_def): Likewie.
14460         (REG_BR_PROB_BASE): Move to profile-count.h
14461         (RDIV): Move to profile-count.h
14462         * bb-reorder.c (max_entry_count): Turn to profile_count.
14463         (find_traces): Update.
14464         (rotate_loop):Update.
14465         (connect_traces):Update.
14466         (sanitize_hot_paths):Update.
14467         * bt-load.c (migrate_btr_defs): Update.
14468         * cfg.c (RDIV): Remove.
14469         (init_flow): Use alloc_block.
14470         (alloc_block): Uninitialize count.
14471         (unchecked_make_edge): Uninitialize count.
14472         (check_bb_profile): Update.
14473         (dump_edge_info): Update.
14474         (dump_bb_info): Update.
14475         (update_bb_profile_for_threading): Update.
14476         (scale_bbs_frequencies_int): Update.
14477         (scale_bbs_frequencies_gcov_type): Update.
14478         (scale_bbs_frequencies_profile_count): New.
14479         * cfg.h (update_bb_profile_for_threading): Update.
14480         (scale_bbs_frequencies_profile_count): Declare.
14481         * cfgbuild.c (compute_outgoing_frequencies): Update.
14482         (find_many_sub_basic_blocks): Update.
14483         * cfgcleanup.c (try_forward_edges): Update.
14484         (try_crossjump_to_edge): Update.
14485         * cfgexpand.c (expand_gimple_tailcall): Update.
14486         (construct_exit_block): Update.
14487         * cfghooks.c (verify_flow_info): Update.
14488         (dump_bb_for_graph): Update.
14489         (split_edge): Update.
14490         (make_forwarder_block): Update.
14491         (duplicate_block): Update.
14492         (account_profile_record): Update.
14493         * cfgloop.c (find_subloop_latch_edge_by_profile): Update.
14494         (get_estimated_loop_iterations): Update.
14495         * cfgloopanal.c (expected_loop_iterations_unbounded): Update.
14496         (single_likely_exit): Update.
14497         * cfgloopmanip.c (scale_loop_profile): Update.
14498         (loopify): Update.
14499         (set_zero_probability): Update.
14500         (lv_adjust_loop_entry_edge): Update.
14501         * cfgrtl.c (force_nonfallthru_and_redirect): Update.
14502         (purge_dead_edges): Update.
14503         (rtl_account_profile_record): Update.
14504         * cgraph.c (cgraph_node::create): Uninitialize count.
14505         (symbol_table::create_edge): Uninitialize count.
14506         (cgraph_update_edges_for_call_stmt_node): Update.
14507         (cgraph_edge::dump_edge_flags): Update.
14508         (cgraph_node::dump): Update.
14509         (cgraph_edge::maybe_hot_p): Update.
14510         * cgraph.h: Include profile-count.h
14511         (create_clone), create_edge, create_indirect_edge): Update.
14512         (cgraph_node): Turn count to profile_count.
14513         (cgraph_edge0: Likewise.
14514         (make_speculative, clone): Update.
14515         (create_edge): Update.
14516         (init_lowered_empty_function): Update.
14517         * cgraphclones.c (cgraph_edge::clone): Update.
14518         (duplicate_thunk_for_node): Update.
14519         (cgraph_node::create_clone): Update.
14520         * cgraphunit.c (cgraph_node::analyze): Update.
14521         (cgraph_node::expand_thunk): Update.
14522         * final.c (dump_basic_block_info): Update.
14523         * gimple-streamer-in.c (input_bb): Update.
14524         * gimple-streamer-out.c (output_bb): Update.
14525         * graphite.c (print_global_statistics): Update.
14526         (print_graphite_scop_statistics): Update.
14527         * hsa-brig.c: Include basic-block.h.
14528         * hsa-dump.c: Include basic-block.h.
14529         * hsa-gen.c (T sum_slice): Update.
14530         (convert_switch_statements):Update.
14531         * hsa-regalloc.c: Include basic-block.h.
14532         * ipa-chkp.c (chkp_produce_thunks): Update.
14533         * ipa-cp.c (struct caller_statistics): Update.
14534         (init_caller_stats): Update.
14535         (gather_caller_stats): Update.
14536         (ipcp_cloning_candidate_p): Update.
14537         (good_cloning_opportunity_p): Update.
14538         (get_info_about_necessary_edges): Update.
14539         (dump_profile_updates): Update.
14540         (update_profiling_info): Update.
14541         (update_specialized_profile): Update.
14542         (perhaps_add_new_callers): Update.
14543         (decide_about_value): Update.
14544         (ipa_cp_c_finalize): Update.
14545         * ipa-devirt.c (struct odr_type_warn_count): Update.
14546         (struct decl_warn_count): Update.
14547         (struct final_warning_record): Update.
14548         (possible_polymorphic_call_targets): Update.
14549         (ipa_devirt): Update.
14550         * ipa-fnsummary.c (redirect_to_unreachable): Update.
14551         * ipa-icf.c (sem_function::merge): Update.
14552         * ipa-inline-analysis.c (do_estimate_edge_time): Update.
14553         * ipa-inline.c (compute_uninlined_call_time): Update.
14554         (compute_inlined_call_time): Update.
14555         (want_inline_small_function_p): Update.
14556         (want_inline_self_recursive_call_p): Update.
14557         (edge_badness): Update.
14558         (lookup_recursive_calls): Update.
14559         (recursive_inlining): Update.
14560         (inline_small_functions): Update.
14561         (dump_overall_stats): Update.
14562         (dump_inline_stats): Update.
14563         * ipa-profile.c (ipa_profile_generate_summary): Update.
14564         (ipa_propagate_frequency): Update.
14565         (ipa_profile): Update.
14566         * ipa-prop.c (ipa_make_edge_direct_to_target): Update.
14567         * ipa-utils.c (ipa_merge_profiles): Update.
14568         * loop-doloop.c (doloop_modify): Update.
14569         * loop-unroll.c (report_unroll): Update.
14570         (unroll_loop_runtime_iterations): Update.
14571         * lto-cgraph.c (lto_output_edge): Update.
14572         (lto_output_node): Update.
14573         (input_node): Update.
14574         (input_edge): Update.
14575         (merge_profile_summaries): Update.
14576         * lto-streamer-in.c (input_cfg): Update.
14577         * lto-streamer-out.c (output_cfg): Update.
14578         * mcf.c (create_fixup_graph): Update.
14579         (adjust_cfg_counts): Update.
14580         (sum_edge_counts): Update.
14581         * modulo-sched.c (sms_schedule): Update.
14582         * postreload-gcse.c (eliminate_partially_redundant_load): Update.
14583         * predict.c (maybe_hot_count_p): Update.
14584         (probably_never_executed): Update.
14585         (dump_prediction): Update.
14586         (combine_predictions_for_bb): Update.
14587         (propagate_freq): Update.
14588         (handle_missing_profiles): Update.
14589         (counts_to_freqs): Update.
14590         (rebuild_frequencies): Update.
14591         (force_edge_cold): Update.
14592         * predict.h: Include profile-count.h
14593         (maybe_hot_count_p, counts_to_freqs): UPdate.
14594         * print-rtl-function.c: Do not include cfg.h
14595         * print-rtl.c: Include basic-block.h
14596         * profile-count.c: New file.
14597         * profile-count.h: New file.
14598         * profile.c (is_edge_inconsistent): Update.
14599         (correct_negative_edge_counts): Update.
14600         (is_inconsistent): Update.
14601         (set_bb_counts): Update.
14602         (read_profile_edge_counts): Update.
14603         (compute_frequency_overlap): Update.
14604         (compute_branch_probabilities): Update; Initialize and deinitialize
14605         gcov_count tables.
14606         (branch_prob): Update.
14607         * profile.h (bb_gcov_counts, edge_gcov_counts): New.
14608         (edge_gcov_count): New.
14609         (bb_gcov_count): New.
14610         * shrink-wrap.c (try_shrink_wrapping): Update.
14611         * tracer.c (better_p): Update.
14612         * trans-mem.c (expand_transaction): Update.
14613         (ipa_tm_insert_irr_call): Update.
14614         (ipa_tm_insert_gettmclone_call): Update.
14615         * tree-call-cdce.c: Update.
14616         * tree-cfg.c (gimple_duplicate_sese_region): Update.
14617         (gimple_duplicate_sese_tail): Update.
14618         (gimple_account_profile_record): Update.
14619         (execute_fixup_cfg): Update.
14620         * tree-inline.c (copy_bb): Update.
14621         (copy_edges_for_bb): Update.
14622         (initialize_cfun): Update.
14623         (freqs_to_counts): Update.
14624         (copy_cfg_body): Update.
14625         (expand_call_inline): Update.
14626         * tree-ssa-ifcombine.c (update_profile_after_ifcombine): Update.
14627         * tree-ssa-loop-ivcanon.c (unloop_loops): Update.
14628         (try_unroll_loop_completely): Update.
14629         (try_peel_loop): Update.
14630         * tree-ssa-loop-manip.c (tree_transform_and_unroll_loop): Update.
14631         * tree-ssa-loop-niter.c (estimate_numbers_of_iterations_loop): Update.
14632         * tree-ssa-loop-split.c (connect_loops): Update.
14633         * tree-ssa-loop-unswitch.c (hoist_guard): Update.
14634         * tree-ssa-reassoc.c (branch_fixup): Update.
14635         * tree-ssa-tail-merge.c (replace_block_by): Update.
14636         * tree-ssa-threadupdate.c (create_block_for_threading): Update.
14637         (compute_path_counts): Update.
14638         (update_profile): Update.
14639         (recompute_probabilities): Update.
14640         (update_joiner_offpath_counts): Update.
14641         (estimated_freqs_path): Update.
14642         (freqs_to_counts_path): Update.
14643         (clear_counts_path): Update.
14644         (ssa_fix_duplicate_block_edges): Update.
14645         (duplicate_thread_path): Update.
14646         * tree-switch-conversion.c (case_bit_test_cmp): Update.
14647         (struct switch_conv_info): Update.
14648         * tree-tailcall.c (decrease_profile): Update.
14649         * tree-vect-loop-manip.c (slpeel_add_loop_guard): Update.
14650         * tree-vect-loop.c (scale_profile_for_vect_loop): Update.
14651         * value-prof.c (check_counter): Update.
14652         (gimple_divmod_fixed_value): Update.
14653         (gimple_mod_pow2): Update.
14654         (gimple_mod_subtract): Update.
14655         (gimple_ic_transform): Update.
14656         (gimple_stringop_fixed_value): Update.
14657         * value-prof.h (gimple_ic): Update.
14659 2017-06-02  Carl Love  <cel@us.ibm.com>
14661         * config/rs6000/rs6000-c: Add support for built-in functions
14662         vector double vec_doublee (vector signed int);
14663         vector double vec_doublee (vector unsigned int);
14664         vector double vec_doublee (vector float);
14665         vector double vec_doubleh (vector signed int);
14666         vector double vec_doubleh (vector unsigned int);
14667         vector double vec_doubleh (vector float);
14668         vector double vec_doublel (vector signed int);
14669         vector double vec_doublel (vector unsigned int);
14670         vector double vec_doublel (vector float);
14671         vector double vec_doubleo (vector signed int);
14672         vector double vec_doubleo (vector unsigned int);
14673         vector double vec_doubleo (vector float);.
14674         * config/rs6000/rs6000-builtin.def: Add definitions for DOUBLEE,
14675         DOUBLEO, DOUBLEH, DOUBLEL, UNS_DOUBLEO, UNS_DOUBLEE, UNS_DOUBLEH,
14676         UNS_DOUBLEL.
14677         * config/rs6000/altivec.md: Add code generator for doublee<mode>2,
14678         unsdoubleev4si2, doubleo<mode>2, unsdoubleov4si2, doubleh<mode>2,
14679         unsdoublehv4si2, doublel<mode>2, unsdoublelv4si2, add mode attribute
14680         VS_sxwsp.
14681         * config/rs6000/altivec.h: Add define for vec_doublee, vec_doubleo,
14682         vec_doublel, vec_doubleh.
14683         * doc/extend.texi: Update the built-in documentation file for the
14684         new built-in functions.
14686 2017-06-02  David Malcolm  <dmalcolm@redhat.com>
14688         PR jit/80954
14689         * ipa-inline-analysis.c (free_growth_caches): Set
14690         edge_removal_hook_holder to NULL after removing it.
14692 2017-06-02  Sudakshina Das  <sudi.das@arm.com>
14694         * config/aarch64/aarch64.c (aarch64_select_cc_mode): Return CC_SWP for
14695         comparision with zero.
14697 2017-06-02  Will Schmidt  <will_schmidt@vnet.ibm.com>
14698         * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Add handling
14699         for early expansion of vec_min and vec_max builtins.
14700         (builtin_function_type): Add min/max unsigned variants to those
14701         identified as having unsigned arguments.
14703 2017-06-02  Olivier Hainque  <hainque@adacore.com>
14705         * config/vx-common.h (DWARF_UNWIND_INFO): Switch #define to 1.
14707 2017-06-02  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
14709         * config/aarch64/aarch64-simd.md (*aarch64_simd_vec_copy_lane<mode>):
14710         Use VALL_F16 iterator rather than VALL.
14712 2017-06-02  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
14714         * config/aarch64/aarch64.c (aarch64_split_compare_and_swap):
14715         Emit CBNZ inside loop when doing a strong exchange and comparing
14716         against zero.  Generate the CC flags after the loop.
14718 2017-06-02  David Edelsohn  <dje.gcc@gmail.com>
14720         * dwarf2out.c (DWARF_INITIAL_LENGTH_SIZE_STR): New.
14721         (dl_section_ref): New.
14722         (dwarf2out_finish): Copy debug_line_section_label to dl_section_ref.
14723         On AIX, append an expression to subtract the size of the
14724         section length to dl_section_ref.
14726 2017-06-02  Will Schmidt  <will_schmidt@vnet.ibm.com>
14728         * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Add handling
14729         for early expansion of vector absolute builtins.
14731 2017-06-02  Richard Biener  <rguenther@suse.de>
14733         * tree-vect-slp.c (vect_detect_hybrid_slp_2): Match up
14734         what we consider a relevant use stmt with vect_detect_hybrid_slp_stmts.
14736 2017-06-02  Richard Biener  <rguenther@suse.de>
14738         PR tree-optimization/80948
14739         * tree-tailcall.c (find_tail_calls): Track stmts to move in
14740         stmt order as well.
14742 2017-06-02  Richard Biener  <rguenther@suse.de>
14744         * tree-vect-loop.c (vect_analyze_loop_operations): Not relevant
14745         PHIs are ok.
14746         * tree-vect-stmts.c (process_use): Do not mark backedge defs
14747         for inductions as relevant.
14749 2017-06-02  Richard Biener  <rguenther@suse.de>
14751         * tree-vect-loop.c (get_initial_def_for_induction): Inline into ...
14752         (vectorizable_induction): ... this.  Remove dead code.
14754 2017-06-02  Eric Botcazou  <ebotcazou@adacore.com>
14756         * builtins. (expand_builtin_alloca): Remove second parameter and
14757         infer its value from the first parameter instead.
14758         (expand_builtin) <BUILT_IN_ALLOCA>: Adjust call to above.
14760 2017-06-02  Jakub Jelinek  <jakub@redhat.com>
14762         PR rtl-optimization/80903
14763         * loop-doloop.c (add_test): Unshare sequence.
14765 2017-06-02  Bernd Edlinger  <bernd.edlinger@hotmail.de>
14767         * doc/invoke.texi: Document the -Wsizeof-pointer-div warning.
14769 2017-06-01  Bernd Edlinger  <bernd.edlinger@hotmail.de>
14771         * config/i386/i386.c (x86_64_ms_sysv_extra_clobbered_registers): Make
14772         static.
14773         (xlogue_layout::get_stack_space_used, xlogue_layout::s_instances,
14774         xlogue_layout::get_instance, logue_layout::xlogue_layout,
14775         sp_valid_at, fp_valid_at, choose_basereg): Formatting.
14776         (xlogue_layout::get_stub_rtx): Make static.
14777         (xlogue_layout::get_stub_name): Avoid const-cast, make static.
14778         (xlogue_layout::compute_stub_managed_regs): Rename to...
14779         (xlogue_layout::count_stub_managed_regs): ...this.
14780         (xlogue_layout::is_stub_managed_reg): New function.
14781         (xlogue_layout::m_stub_names): Rename to...
14782         (xlogue_layout::s_stub_names): ...this, make static.
14783         (xlogue_layout::STUB_INDEX_OFFSET, xlogue_layout::MIN_REGS,
14784         xlogue_layout::MAX_REGS, xlogue_layout::MAX_EXTRA_REGS,
14785         xlogue_layout::VARIANT_COUNT, xlogue_layout::STUB_NAME_MAX_LEN,
14786         xlogue_layout::s_stub_names): Instantiate statics.
14787         (stub_managed_regs): Remove.
14788         (ix86_save_reg): Use xlogue_layout::compute_stub_managed_regs.
14789         (disable_call_ms2sysv_xlogues): Rename to...
14790         (warn_once_call_ms2sysv_xlogues): ...this, and warn only once.
14791         (ix86_initial_elimination_offset, ix86_expand_call): Fix call_ms2sysv
14792         warning logic.
14793         (ix86_static_chain): Make sure that ix86_static_chain_on_stack can't
14794         change after reload_completed.
14795         (ix86_can_use_return_insn_p): Use the ix86_frame data structure
14796         directly.
14797         (ix86_expand_prologue): Likewise.
14798         (ix86_expand_epilogue): Likewise.
14799         (ix86_expand_split_stack_prologue): Likewise.
14800         (ix86_compute_frame_layout): Remove frame parameter ...
14801         (TARGET_COMPUTE_FRAME_LAYOUT): ... and export it as a target hook.
14802         (ix86_finalize_stack_realign_flags): Call ix86_compute_frame_layout
14803         only if necessary.
14804         (ix86_init_machine_status): Don't set use_fast_prologue_epilogue_nregs.
14805         (ix86_frame): Move from here ...
14806         * config/i386/i386.h (ix86_frame): ... to here.
14807         (machine_function): Remove use_fast_prologue_epilogue_nregs, cache the
14808         complete ix86_frame data structure instead.  Remove some_ld_name.
14810 2017-06-01  Pierre-Marie de Rodat  <derodat@adacore.com>
14812         * dwarf2out.c (dwarf2out_late_global_decl): Add locations for
14813         symbols that hold a DECL_VALUE_EXPR.
14815 2017-06-01  Martin Jambor  <mjambor@suse.cz>
14817         PR tree-optimization/80898
14818         * tree-sra.c (process_subtree_disqualification): Removed.
14819         (disqualify_candidate): Do not acll
14820         process_subtree_disqualification.
14821         (subtree_mark_written_and_enqueue): New function.
14822         (propagate_all_subaccesses): Set grp_write of LHS subtree if the
14823         RHS has been disqualified and re-queue LHS if necessary.  Apart
14824         from that, ignore disqualified RHS.
14826 2017-06-01  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
14828         * config/s390/s390.c (s390_emit_epilogue): Disable early return
14829         address fetch for z10 or later.
14831 2017-06-01  Claudiu Zissulescu  <claziss@synopsys.com>
14833         * config/arc/arc.md (tst_movb): Add guard when splitting.
14835 2017-06-01  Claudiu Zissulescu  <claziss@synopsys.com>
14837         * config/arc/arc.c (arc_can_eliminate): Test against
14838         arc_frame_pointer_needed.
14840 2017-06-01  Claudiu Zissulescu  <claziss@synopsys.com>
14842         * config/arc/arc.c (arc_expand_prologue): Emit a special barrier
14843         to prevent store reordering.
14844         * config/arc/arc.md (UNSPEC_ARC_STKTIE): Define.
14845         (type): Add block type.
14846         (stack_tie): Define special instruction to be used in
14847         expand_prologue.
14849 2017-06-01  Claudiu Zissulescu  <claziss@synopsys.com>
14851         * config/arc/arc.md (commutative_binary_comparison): Remove 'I'
14852         constraint. It is not valid for the pattern.
14853         (noncommutative_binary_comparison): Likewise.
14855 2017-06-01  Claudiu Zissulescu  <claziss@synopsys.com>
14857         * config/arc/simdext.md (movv2hi_insn): Change predicate to avoid
14858         scaled addresses.
14860 2017-06-01  Claudiu Zissulescu  <claziss@synopsys.com>
14862         * config/arc/arc.c (arc_conditional_register_usage): Allow r30 to
14863         be used by the reg-alloc.
14865 2017-06-01  Claudiu Zissulescu  <claziss@synopsys.com>
14867         * config/arc/arc.md (mulsi3): Avoid use of hard registers before
14868         reg-alloc when having mul64 or mul32x16 instructions.
14869         (mulsidi3): Likewise.
14870         (umulsidi3): Likewise.
14871         (mulsi32x16): New pattern.
14872         (mulsi64): Likewise.
14873         (mulsidi64): Likewise.
14874         (umulsidi64): Likewise.
14875         (MUL32x16_REG): Define.
14876         (mul64_600): Use MUL32x16_REG.
14877         (mac64_600): Likewise.
14878         (umul64_600): Likewise.
14879         (umac64_600): Likewise.
14881 2017-06-01  Claudiu Zissulescu  <claziss@synopsys.com>
14883         * config/arc/arc.md (mulsi3_700): Make it commutative.
14885 2017-06-01  Jose E. Marchesi  <jose.marchesi@oracle.com>
14887         * config/sparc/sparc.md (*zero_extendsidi2_insn_sp64): Set insn
14888         type for movstouw.
14889         (*sign_extendsidi2_insn): Likewise for movstosw.
14891 2017-06-01  Pierre-Marie de Rodat  <derodat@adacore.com>
14893         * dwarf2out.c (get_discr_value): Call the get_debug_type hook on
14894         the type of the input discriminant value.  Convert the
14895         discriminant value of signedness vary.
14897 2017-06-01  Volker Reichelt  <v.reichelt@netcologne.de>
14899         * doc/invoke.texi (-Wcatch-value): Document new shortcut.
14900         Add to -Wall section.
14902 2017-06-01  Richard Biener  <rguenther@suse.de>
14904         PR middle-end/66313
14905         * fold-const.c (fold_plusminus_mult_expr): If the factored
14906         factor may be zero use a wrapping type for the inner operation.
14907         * tree-tailcall.c (independent_of_stmt_p): Pass in to_move bitmap
14908         and handle moved defs.
14909         (process_assignment): Properly guard the unary op case.  Return a
14910         tri-state indicating that moving the stmt before the call may allow
14911         to continue.  Pass through to_move.
14912         (find_tail_calls): Handle moving unrelated defs before
14913         the call.
14915 2017-05-31  Segher Boessenkool  <segher@kernel.crashing.org>
14917         PR target/80618
14918         * config/rs6000/vector.md (*vector_uneq<mode>): Write the nor in the
14919         splitter result in the canonical way.
14921 2017-05-31  Uros Bizjak  <ubizjak@gmail.com>
14923         * config/i386/i386.md (*zero_extendsidi2): Enable alternative (?r, *Yj)
14924         also for 32bit target.  Update insn attributes.
14925         (zero-extendsidi2 splitter): Allow all registers for operand 1.
14927 2017-05-31  Sebastian Peryt  <sebastian.peryt@intel.com>
14929         * config/i386/avx512fintrin.h (_mm_mask_max_sd)
14930         (_mm_maskz_max_sd, _mm_mask_max_ss, _mm_maskz_max_ss)
14931         (_mm_mask_min_sd, _mm_maskz_min_sd, _mm_mask_min_ss)
14932         (_mm_maskz_min_ss): New intrinsics.
14934 2017-05-31  Martin Liska  <mliska@suse.cz>
14936         * tree-vect-loop.c (vect_create_epilog_for_reduction):
14937         Change comment style to one we normally use.
14938         (vectorizable_reduction): Likewise.
14939         (vectorizable_induction): Likewise.
14940         * tree-vect-stmts.c (vectorizable_mask_load_store): Likewise.
14941         (vectorizable_call): Likewise.
14942         (vectorizable_simd_clone_call): Likewise.
14943         (vectorizable_conversion): Likewise.
14944         (vectorizable_assignment): Likewise.
14945         (vectorizable_shift): Likewise.
14946         (vectorizable_operation): Likewise.
14947         (vectorizable_store): Likewise.
14948         (vectorizable_load): Likewise.
14949         * tree-vectorizer.h: Likewise.
14951 2017-05-31  Alexander Monakov  <amonakov@ispras.ru>
14953         * passes.c (emergency_dump_function): New.
14954         * tree-pass.h (emergency_dump_function): Declare.
14955         * plugin.c (plugins_internal_error_function): Remove.
14956         * plugin.h (plugins_internal_error_function): Remove declaration.
14957         * toplev.c (internal_error_function): New static function.  Use it...
14958         (general_init): ...here.
14960 2017-05-31  Graham Markall  <graham.markall@embecosm.com>
14962         * config/arc/arc.c (arc_print_operand): Handle constant operands.
14963         (arc_rtx_costs): Add costs for new patterns.
14964         * config/arc/arc.md: Additional *add_n and *sub_n patterns.
14965         * config/arc/predicates.md: Add _1_2_3_operand predicate.
14967 2017-05-31  Richard Sandiford  <richard.sandiford@linaro.org>
14969         * tree-ssa-strlen.c (get_next_strinfo): New function.
14970         (get_stridx_plus_constant): Use it.
14971         (zero_length_string): Likewise.
14972         (adjust_related_strinfos): Likewise.
14973         (adjust_last_stmt): Likewise.
14975 2017-05-31  Richard Biener  <rguenther@suse.de>
14977         PR target/80880
14978         * config/i386/i386.c (ix86_expand_builtin): Remove assert
14979         for arg being an SSA name when expanding IX86_BUILTIN_BNDRET.
14981 2017-05-31  Richard Sandiford  <richard.sandiford@linaro.org>
14983         * tree-vect-data-refs.c (vect_find_same_alignment_drs): Remove
14984         loop_vinfo argument and use of dependence distance vectors.
14985         Check instead whether the two references differ only in their
14986         initial value and assume that they have the same alignment if the
14987         difference is a multiple of the vector alignment.
14988         (vect_analyze_data_refs_alignment): Update call accordingly.
14990 2017-05-31  Martin Liska  <mliska@suse.cz>
14992         PR target/79155
14993         * config/i386/cpuid.h: Fix typo in a comment in cpuid.h.
14995 2017-05-31  Bin Cheng  <bin.cheng@arm.com>
14997         * tree-vect-loop-manip.c (create_intersect_range_checks_index)
14998         (create_intersect_range_checks): Move from ...
14999         * tree-data-ref.c (create_intersect_range_checks_index)
15000         (create_intersect_range_checks): ... to here.
15001         (create_runtime_alias_checks): New function factored from ...
15002         * tree-vect-loop-manip.c (vect_create_cond_for_alias_checks): ...
15003         here.  Call above function.
15004         * tree-data-ref.h (create_runtime_alias_checks): New function.
15006 2017-05-31  Bin Cheng  <bin.cheng@arm.com>
15008         * tree-data-ref.c (prune_runtime_alias_test_list): Relax minimal
15009         segment length for dr_b and compute it in wide_int.
15011 2017-05-31  Richard Biener  <rguenther@suse.de>
15013         PR tree-optimization/80906
15014         * graphite-isl-ast-to-gimple.c (copy_loop_close_phi_nodes): Get
15015         and pass through iv_map.
15016         (copy_bb_and_scalar_dependences): Adjust.
15017         (translate_pending_phi_nodes): Likewise.
15018         (copy_loop_close_phi_args): Handle code-generating IVs instead
15019         of ICEing.
15021 2017-05-30  David Malcolm  <dmalcolm@redhat.com>
15023         * diagnostic-color.c (color_dict): Add "type-diff".
15024         (parse_gcc_colors): Update comment.
15025         * doc/invoke.texi (Diagnostic Message Formatting Options): Add
15026         -fdiagnostics-show-template-tree and -fno-elide-type.
15027         (GCC_COLORS): Add type-diff to example.
15028         (type-diff=): New.
15029         (-fdiagnostics-show-template-tree): New.
15030         (-fno-elide-type): New.
15031         * pretty-print.c (pp_format): Pass quote and formatters[argno] to
15032         the pp_format_decoder callback.  Call any m_format_postprocessor's
15033         "handle" method.
15034         (pretty_printer::pretty_printer): Initialize
15035         m_format_postprocessor.
15036         (pretty_printer::~pretty_printer): Delete any
15037         m_format_postprocessor.
15038         * pretty-print.h (printer_fn): Add bool and const char ** parameters.
15039         (class format_postprocessor): New class.
15040         (struct pretty_printer::format_decoder): Document the new parameters.
15041         (struct pretty_printer::m_format_postprocessor): New field.
15042         * tree-diagnostic.c (default_tree_printer): Update for new
15043         bool and const char ** params.
15044         * tree-diagnostic.h (default_tree_printer): Likewise.
15046 2017-05-30  Segher Boessenkool  <segher@kernel.crashing.org>
15048         * config/rs6000/predicates.md (cc_reg_not_micro_cr0_operand): Delete.
15049         (lwa_operand): Delete rs6000_gen_cell_microcode test.
15050         * config/rs6000/rs6000.c (rs6000_option_override_internal): Delete
15051         rs6000_gen_cell_microcode code.
15052         (rs6000_final_prescan_insn): Delete.
15053         (rs6000_opt_vars): Delete the "gen-cell-microcode" and
15054         "warn-cell-microcode" entries.
15055         * config/rs6000/rs6000.h (FINAL_PRESCAN_INSN): Delete.
15056         * config/rs6000/rs6000.md: Delete rs6000_gen_cell_microcode tests
15057         throughout.  Change cc_reg_not_micro_cr0_operand to
15058         cc_reg_not_cr0_operand throughout.
15059         (*extendhi<mode>2_noload): Delete.
15060         * config/rs6000/rs6000.opt (mgen-cell-microcode): Replace by stub.
15061         (mwarn-cell-microcode): Delete.
15062         * doc/invoke.texi (RS/6000 and PowerPC Options): Delete
15063         -mgen-cell-microcode and -mwarn-cell-microcode.
15065 2017-05-30  Uros Bizjak  <ubizjak@gmail.com>
15067         PR target/80833
15068         * config/i386/constraints.md (Yd): New constraint.
15069         (Ye): Ditto.
15070         * config/i386/i386.md (*movti_internal): Add (?r, Ye)
15071         and (?Yd, r) alternatives.  Update insn attributes.
15072         * config/i386/i386.md (*movti_internal): Add (?r, *Ye)
15073         and (?*Yd, r) alternatives.  Update insn attributes.
15074         (double-mode inter-unit splitters): Add new GR<->XMM splitters.
15076 2017-05-30  Pierre-Marie de Rodat  <derodat@adacore.com>
15078         * gimplify.c (gimplify_modify_expr): Don't create a
15079         DECL_DEBUG_EXPR link if *FROM_P does not belong to the current
15080         function.
15082 2017-05-30  Wilco Dijkstra  <wdijkstr@arm.com>
15084         * config/arm/arm-builtins.c (arm_expand_builtin): Remove const.
15086 2017-05-30  Richard Biener  <rguenther@suse.de>
15088         * tree-vectorizer.h (struct _stmt_vec_info): Add reduc_type
15089         and reduc_def fields.
15090         (STMT_VINFO_REDUC_TYPE): New define.
15091         (STMT_VINFO_REDUC_DEF): Likewise.
15092         (vect_force_simple_reduction): Adjust prototype.
15093         * tree-vect-loop.c (vect_analyze_scalar_cycles_1): Adjust.
15094         (vect_is_simple_reduction): Remove check_reduction argument.
15095         (vect_force_simple_reduction): Adjust and set
15096         STMT_VINFO_REDUC_TYPE and STMT_VINFO_REDUC_DEF.
15097         (vectorizable_reduction): Do not re-do reduction analysis
15098         but use STMT_VINFO_REDUC_TYPE and STMT_VINFO_REDUC_DEF.
15099         * tree-parloops.c (gather_scalar_reductions): Adjust.
15101 2017-05-30  Richard Biener  <rguenther@suse.de>
15103         PR middle-end/80901
15104         * cfgexpand.c (expand_gimple_cond): Match up loop fixup with
15105         split_edge code.
15107 2017-05-24  Robin Dapp  <rdapp@linux.vnet.ibm.com>
15109         * tree-vect-data-refs.c (vect_get_peeling_costs_all_drs):
15110         Introduce unknown_misalignment parameter and remove vf.
15111         (vect_peeling_hash_get_lowest_cost):
15112         Pass unknown_misalignment parameter.
15113         (vect_enhance_data_refs_alignment):
15114         Fix unsupportable data ref treatment.
15116 2017-05-30  Robin Dapp  <rdapp@linux.vnet.ibm.com>
15118         * tree-vect-data-refs.c (vect_get_data_access_cost):
15119         Workaround for SLP handling.
15120         (vect_enhance_data_refs_alignment):
15121         Compute costs for doing no peeling at all, compare to the best
15122         peeling costs so far and avoid peeling if cheaper.
15124 2017-05-30  Robin Dapp  <rdapp@linux.vnet.ibm.com>
15126         * tree-vect-data-refs.c (vect_peeling_hash_choose_best_peeling):
15127         Return peeling info and set costs to zero for unlimited cost
15128         model.
15129         (vect_enhance_data_refs_alignment): Also inspect all datarefs
15130         with unknown misalignment. Compute and costs for unknown
15131         misalignment, compare them to the costs for known misalignment
15132         and choose the cheapest for peeling.
15134 2017-05-30  Robin Dapp  <rdapp@linux.vnet.ibm.com>
15136         * tree-vect-data-refs.c (vect_update_misalignment_for_peel): Rename.
15137         (vect_get_peeling_costs_all_drs): Create function.
15138         (vect_peeling_hash_get_lowest_cost):
15139         Use vect_get_peeling_costs_all_drs.
15140         (vect_peeling_supportable): Create function.
15141         (vect_enhance_data_refs_alignment): Use vect_peeling_supportable.
15143 2017-05-30  Robin Dapp  <rdapp@linux.vnet.ibm.com>
15145         * tree-vect-data-refs.c (vect_compute_data_ref_alignment): Create
15146         DR_HAS_NEGATIVE_STEP.
15147         (vect_update_misalignment_for_peel): Define DR_MISALIGNMENT.
15148         (vect_enhance_data_refs_alignment): Use.
15149         (vect_duplicate_ssa_name_ptr_info): Use.
15150         * tree-vectorizer.h (dr_misalignment): Use.
15151         (known_alignment_for_access_p): Use.
15153 2017-05-30  Jozef Lawrynowicz  <jozef.l@somniumtech.com>
15155         PR target/78838
15156         * config/msp430/msp430.c (gen_prefix): Return NULL when section name is
15157         .lowtext.
15158         (has_section_name): New function.
15160 2017-05-30  Martin Liska  <mliska@suse.cz>
15162         PR other/80909
15163         * auto-profile.c (get_function_decl_from_block): Fix
15164         parenthesis.
15166 2017-05-30  Richard Biener  <rguenther@suse.de>
15168         PR middle-end/80876
15169         * cfgexpand.c (expand_gimple_cond): Fixup preserving loops again.
15171 2017-05-30  Martin Liska  <mliska@suse.cz>
15173         * dumpfile.c: Use newly added macro DUMP_FILE_INFO.
15174         * dumpfile.h (struct dump_file_info): Remove ctors.
15176 2017-05-30  Martin Liska  <mliska@suse.cz>
15178         * predict.def: Fix GNU coding style.
15180 2017-05-29  Max Filippov  <jcmvbkbc@gmail.com>
15182         * config/xtensa/xtensa.c (xtensa_initial_elimination_offset):
15183         Mark 'to' argument with ATTRIBUTE_UNUSED.
15185 2017-05-29  Max Filippov  <jcmvbkbc@gmail.com>
15187         * config/xtensa/xtensa.c (xtensa_emit_call): Use
15188         HOST_WIDE_INT_PRINT_HEX instead of 0x%lx format string.
15189         (print_operand): Use HOST_WIDE_INT_PRINT_DEC instead of %ld
15190         format string.
15192 2017-05-29  Eric Botcazou  <ebotcazou@adacore.com>
15194         * doc/install.texi (Options specification): Restore entry of
15195         --enable-sjlj-exceptions.
15197 2017-05-27  Michael Eager  <eager@eagercon.com>
15199         Revert:
15200         2016-01-21  Ajit Agarwal  <ajitkum@xilinx.com>
15202         See https://gcc.gnu.org/ml/gcc/2017-05/msg00221.html.
15204         * config/microblaze/microblaze.h
15205         (FIXED_REGISTERS): Update in macro.
15206         (CALL_USED_REGISTERS): Update in macro.
15208 2017-05-27  François-Xavier Coudett  <fxcoudert@gcc.gnu.org>
15210         * doc/install.texi: Add links to macOS binary distributions.
15212 2017-05-27  Jakub Jelinek  <jakub@redhat.com>
15214         PR bootstrap/80887
15215         Revert:
15216         2017-05-25  Marc Glisse  <marc.glisse@inria.fr>
15218         * match.pd ((A +- CST1) +- CST2): Allow some conversions.
15220 2017-05-26  Martin Liska  <mliska@suse.cz>
15222         * dumpfile.h (enum dump_kind): Renumber TDF_* flags to be contiguous.
15224 2017-05-26  Martin Liska  <mliska@suse.cz>
15226         * cfg.c (check_bb_profile): Do not use TDF_COMMENT and print
15227         always leading ';; '.
15228         (dump_bb_info): Likewise.
15229         (brief_dump_cfg): Likewise.
15230         * cfgrtl.c (print_rtl_with_bb): Do not use TDF_COMMENT.
15231         * dumpfile.c: Remove usage of TDF_VERBOSE.
15232         * dumpfile.h (enum dump_kind): Likewise.
15233         (dump_gimple_bb_header): Do not use TDF_COMMENT.
15234         * print-tree.c (debug_verbose): Remove.
15235         * tree-cfg.c (gimple_dump_cfg): Do not use TDF_COMMENT.
15236         (dump_function_to_file): Remove dumps guarded with TDF_VERBOSE.
15237         * tree-diagnostic.c (default_tree_printer): Replace
15238         TDF_DIAGNOSTIC with TDF_SLIM.
15240 2017-05-26  Bin Cheng  <bin.cheng@arm.com>
15242         * tree-vect-loop-manip.c (create_intersect_range_checks_index): Pass
15243         in parameter loop, rather than loop_vinfo.
15244         (create_intersect_range_checks): Ditto.
15245         (vect_create_cond_for_alias_checks): Update call to above functions.
15247 2017-05-26  Bin Cheng  <bin.cheng@arm.com>
15249         PR tree-optimization/80815
15250         * tree-data-ref.c (prune_runtime_alias_test_list): Simplify condition
15251         for merging runtime alias checks.  Handle negative DR_STEPs.
15253 2017-05-26  Bin Cheng  <bin.cheng@arm.com>
15255         * tree-vect-data-refs.c (Operator==, comp_dr_with_seg_len_pair):
15256         Move from ...
15257         * tree-data-ref.c (Operator==, comp_dr_with_seg_len_pair): To here.
15258         * tree-vect-data-refs.c (vect_prune_runtime_alias_test_list): Factor
15259         out code pruning runtime alias checks.
15260         * tree-data-ref.c (prune_runtime_alias_test_list): New function
15261         factored out from above.
15262         * tree-vectorizer.h (struct dr_with_seg_len, dr_with_seg_len_pair_t):
15263         Move from ...
15264         * tree-data-ref.h (struct dr_with_seg_len, dr_with_seg_len_pair_t):
15265         ... to here.
15266         (prune_runtime_alias_test_list): New decalaration.
15268 2017-05-26  Bin Cheng  <bin.cheng@arm.com>
15270         * tree-vect-data-refs.c (compare_tree): Rename and move ...
15271         * tree-data-ref.c (data_ref_compare_tree): ... to here.
15272         * tree-data-ref.h (data_ref_compare_tree): New decalaration.
15273         * tree-vect-data-refs.c (dr_group_sort_cmp): Update uses.
15274         (operator==, comp_dr_with_seg_len_pair): Ditto.
15275         (vect_prune_runtime_alias_test_list): Ditto.
15277 2017-05-26  Martin Liska  <mliska@suse.cz>
15279         PR ipa/80663
15280         * params.def: Bound partial-inlining-entry-probability param.
15282 2017-05-26  Marek Polacek  <polacek@redhat.com>
15284         PR sanitizer/80875
15285         * fold-const.c (fold_binary_loc) <case MULT_EXPR>: Check if OP1
15286         can be negated.
15288 2017-05-26  Richard Biener  <rguenther@suse.de>
15290         PR tree-optimization/80842
15291         * tree-ssa-ccp.c (set_lattice_value): Always meet with the old
15292         value.
15294 2017-05-26  Richard Biener  <rguenther@suse.de>
15296         PR tree-optimization/80844
15297         * tree-vectorizer.c (adjust_simduid_builtins): Propagate results.
15299 2017-05-25  Sebastian Peryt  <sebastian.peryt@intel.com>
15301         * doc/md.texi (Machine Constraints): Update x86 family
15302         machine constraints section to match 'config/i386/constraints.md'.
15304 2017-05-25  Volker Reichelt  <v.reichelt@netcologne.de>
15306         * doc/invoke.texi (-Wcatch-value=): Document new warning option.
15308 2017-05-25  Nathan Sidwell  <nathan@acm.org>
15310         * doc/invoke.texi (--enable-languages): Update documentation.
15312 2017-05-25  Martin Liska  <mliska@suse.cz>
15314         * dumpfile.c: Add TDF_FOLDING.
15315         * dumpfile.h (enum dump_kind): Likewise.
15316         * genmatch.c (dt_simplify::gen_1): Use it.
15318 2017-05-25  Marc Glisse  <marc.glisse@inria.fr>
15320         * match.pd (view_convert (convert@0 @1)): Handle zero-extension.
15322 2017-05-25  Marc Glisse  <marc.glisse@inria.fr>
15324         * match.pd ((A +- CST1) +- CST2): Allow some conversions.
15325         * tree.c (drop_tree_overflow): Handle COMPLEX_CST and VECTOR_CST.
15327 2017-05-25  Marc Glisse  <marc.glisse@inria.fr>
15329         * fold-const.c (fold_binary_loc) [(A & C) == D]: Remove transformation.
15330         * match.pd (X == C): Rewrite it here.
15331         (with_possible_nonzero_bits, with_possible_nonzero_bits2,
15332         with_certain_nonzero_bits2): New predicates.
15333         * tree-ssanames.c (get_nonzero_bits): Handle INTEGER_CST.
15335 2017-05-24  Nathan Sidwell  <nathan@acm.org>
15337         * lto-streamer-in.c (lto_input_data_block): Adjust T const cast to
15338         avoid warning.
15340         * auto-profile.c (afdo_propagate): Adjust T const cast to avoid
15341         warning.
15343 2017-05-24  Segher Boessenkool  <segher@kernel.crashing.org>
15345         * config/powerpcspe: New port.  Files are copied from the rs6000
15346         port, with "rs6000" in filenames replaced by "powerpcspe".
15348 2017-05-24  Wilco Dijkstra  <wdijkstr@arm.com>
15350         PR rtl-optimization/80754
15351         * lra-remat.c (do_remat): Add overlap checks for dst_regno.
15353 2017-05-24  Sheldon Lobo  <smlobo@sheldon.us.oracle.com>
15355         * config/sparc/sparc.md (length): Return the correct value for -mflat
15356         sibcalls to match output_sibcall.
15358 2017-05-24  Segher Boessenkool  <segher@kernel.crashing.org>
15360         PR bootstrap/80860
15361         PR bootstrap/80843
15362         * config/rs6000/rs6000.c (struct machine_function): Add new field
15363         n_components.
15364         (rs6000_get_separate_components): Init that field, use it.
15365         (rs6000_components_for_bb): Use the field.
15367 2017-05-24  Thomas Preud'homme  <thomas.preudhomme@arm.com>
15369         * config/arm/arm.c (arm_expand_prologue): Fix typo in comment.
15371 2017-05-24  Peter Bergner  <bergner@vnet.ibm.com>
15373         PR middle-end/80823
15374         * tree-cfg.c (group_case_labels_stmt): Delete increment of "i";
15376 2017-05-24  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
15378         PR target/80725
15379         * config/s390/s390.c (s390_check_qrst_address): Check incoming
15380         address against address_operand predicate.
15381         * config/s390/s390.md ("*indirect_jump"): Swap alternatives.
15383 2017-05-24  Eric Botcazou  <ebotcazou@adacore.com>
15385         * var-tracking.c (track_expr_p): Do not return 0 for tracked record
15386         parameters passed indirectly.
15388 2017-05-23  Uros Bizjak  <ubizjak@gmail.com>
15390         * config/i386/i386.md (*movdi_internal): Remove SSE4
15391         alternative 18 (?r, *v).  Update insn attributes.
15392         (*movsi_internal): Remove SSE4 alternative 13 (?r, *v).
15393         Update insn attributes.
15394         (*zero_extendsidi2): Remove SSE4 alternative (?r, *x).
15395         Update insn attributes.
15396         * config/i386/sse.md (vec_extract<ssevecmodelower>_0): Remove SSE4
15397         alternative 1 (r, v). Remove isa attribute.
15398         * config/i386/i386.c (dimode_scalar_chain::make_vector_copies):
15399         Always move value through stack for !TARGET_INTER_UNIT_MOVES_TO_VEC
15400         and !TARGET_INTER_UNIT_MOVES_TO_VEC targets.
15402 2017-05-23  Tom de Vries  <tom@codesourcery.com>
15404         * doc/sourcebuild.texi (Directives, Verify compiler message): Document
15405         dg-line directive.
15407 2017-05-23  Jan Hubicka  <hubicka@ucw.cz>
15409         * cgraphunit.c (symbol_table::process_new_functions): Update.
15410         * ipa-fnsummary.c (pass_data_inline_parameters): Remove.
15411         (inline_generate_summary): Rename to ...
15412         (ipa_fn_summary_generate): ... this one.
15413         (inline_read_summary): Rename to ...
15414         (ipa_fn_summary_read): ... this one.
15415         (inline_write_summary): Rename to ...
15416         (ipa_fn_summary_write): ... this one.
15417         (inline_free_summary): Rename to ...
15418         (ipa_free_fn_summary): ... this one.
15419         (pass_data_local_fn_summary, pass_local_fn_summary,
15420         make_pass_local_fn_summary, pass_data_ipa_free_fn_summary,
15421         pass_ipa_free_fn_summary, make_pass_ipa_free_fn_summary,
15422         pass_data_ipa_fn_summary, pass_ipa_fn_summary,
15423         make_pass_ipa_fn_summary): New.
15424         * ipa-fnsummary.h (inline_generate_summary, inline_read_summary,
15425         inline_write_summary, inline_free_summary): Remove.
15426         (ipa_free_fn_summary) : New.
15427         * ipa-inline.c (ipa_inline): Update.
15428         (pass_ipa_inline): Do not generate summaries.
15429         * ipa.c (pass_data_ipa_free_fn_summary, pass_ipa_free_fn_summary):
15430         Remove.
15431         * passes.def: Replace pass_inline_parameters by pass_local_fn_summary
15432         and add pass_ipa_fn_summary.
15433         * tree-pass.h (make_pass_ipa_fn_summary, make_pass_local_fn_summary):
15434         New.
15435         (make_pass_inline_parameters): Remove.
15437 2017-05-23  Thomas Schwinge  <thomas@codesourcery.com>
15439         * omp-low.c (struct omp_context): Remove "default_kind" member.
15440         Adjust all users.
15442         * omp-offload.c (execute_oacc_device_lower): Remove the
15443         parallelism dimensions function attributes for unparallelized
15444         OpenACC kernels constructs.
15446 2017-05-23  Martin Liska  <mliska@suse.cz>
15448         * cgraph.c (cgraph_node::get_create): Use symtab_node::dump_{asm_,}name
15449         functions.
15450         (cgraph_edge::make_speculative): Likewise.
15451         (cgraph_edge::resolve_speculation): Likewise.
15452         (cgraph_edge::redirect_call_stmt_to_callee): Likewise.
15453         (cgraph_node::dump): Likewise.
15454         * cgraph.h: Likewise.
15455         * cgraphunit.c (analyze_functions): Likewise.
15456         (symbol_table::compile): Likewise.
15457         * ipa-cp.c (print_all_lattices): Likewise.
15458         (determine_versionability): Likewise.
15459         (initialize_node_lattices): Likewise.
15460         (ipcp_verify_propagated_values): Likewise.
15461         (estimate_local_effects): Likewise.
15462         (update_profiling_info): Likewise.
15463         (create_specialized_node): Likewise.
15464         (perhaps_add_new_callers): Likewise.
15465         (decide_about_value): Likewise.
15466         (decide_whether_version_node): Likewise.
15467         (identify_dead_nodes): Likewise.
15468         (ipcp_store_bits_results): Likewise.
15469         * ipa-devirt.c (dump_targets): Likewise.
15470         (ipa_devirt): Likewise.
15471         * ipa-icf.c (sem_item::dump): Likewise.
15472         (sem_function::equals): Likewise.
15473         (sem_variable::equals): Likewise.
15474         (sem_item_optimizer::read_section): Likewise.
15475         (sem_item_optimizer::execute): Likewise.
15476         (congruence_class::dump): Likewise.
15477         * ipa-inline-analysis.c (dump_ipa_call_summary): Likewise.
15478         (dump_inline_summary): Likewise.
15479         (estimate_node_size_and_time): Likewise.
15480         (inline_analyze_function): Likewise.
15481         * ipa-inline-transform.c (inline_call): Likewise.
15482         * ipa-inline.c (report_inline_failed_reason): Likewise.
15483         (want_early_inline_function_p): Likewise.
15484         (edge_badness): Likewise.
15485         (update_edge_key): Likewise.
15486         (inline_small_functions): Likewise.
15487         * ipa-profile.c (ipa_profile): Likewise.
15488         * ipa-prop.c (ipa_print_node_jump_functions): Likewise.
15489         (ipa_make_edge_direct_to_target): Likewise.
15490         (remove_described_reference): Likewise.
15491         (ipa_impossible_devirt_target): Likewise.
15492         (propagate_controlled_uses): Likewise.
15493         (ipa_print_node_params): Likewise.
15494         (ipcp_transform_function): Likewise.
15495         * ipa-pure-const.c (pure_const_read_summary): Likewise.
15496         (propagate_pure_const): Likewise.
15497         * ipa-reference.c (generate_summary): Likewise.
15498         (read_write_all_from_decl): Likewise.
15499         (propagate): Likewise.
15500         (ipa_reference_read_optimization_summary): Likewise.
15501         * ipa-utils.c (ipa_merge_profiles): Likewise.
15502         * ipa.c (walk_polymorphic_call_targets): Likewise.
15503         (symbol_table::remove_unreachable_nodes): Likewise.
15504         (ipa_single_use): Likewise.
15505         * passes.c (execute_todo): Likewise.
15506         * predict.c (drop_profile): Likewise.
15507         * symtab.c (symtab_node::get_dump_name): New function.
15508         (symtab_node::dump_name): Likewise.
15509         (symtab_node::dump_asm_name): Likewise.
15510         (symtab_node::dump_references): Likewise.
15511         (symtab_node::dump_referring): Likewise.
15512         (symtab_node::dump_base): Likewise.
15513         (symtab_node::debug_symtab): Likewise.
15514         * tree-sra.c (convert_callers_for_node): Likewise.
15515         * tree-ssa-structalias.c (ipa_pta_execute): Likewise.
15516         * value-prof.c (init_node_map): Likewise.
15518 2017-05-23  Martin Liska  <mliska@suse.cz>
15520         * cgraph.h: Move symtab_node::dump_table to symbol_table::dump
15521         and symtab_node::debug_symtab to symbol_table::debug.
15522         * cgraphunit.c (analyze_functions): Use the renamed function.
15523         (symbol_table::compile): Likewise.
15524         * ipa-cp.c (ipcp_verify_propagated_values): Likewise.
15525         * ipa-icf.c (sem_item_optimizer::execute): Likewise.
15526         * passes.c (execute_todo): Likewise.
15527         * symtab.c (symbol_table::dump): New function.
15528         * tree-ssa-structalias.c (ipa_pta_execute): Use the renamed function.
15530 2017-05-23  Jan Hubicka  <hubicka@ucw.cz>
15532         * ipa-fnsummary.c (estimate_node_size_and_time): Do not sanity check
15533         that nonconst implies exec.
15535 2017-05-23  Jan Hubicka  <hubicka@ucw.cz>
15537         * ipa-inline-analysis.c (cgraph_2edge_hook_list, cgraph_edge_hook_list,
15538         inline_edge_removal_hook, inline_edge_duplication_hook): Remove.
15539         (inline_edge_summary_vec): Turn into ...
15540         (ipa_call_summaries): ... this one.
15541         (redirect_to_unreachable, edge_set_predicate,
15542         evaluate_properties_for_edge, inline_summary_alloc,
15543         reset_ipa_call_summary, reset_inline_summary,
15544         inline_summary_t::duplicate): Update.
15545         (inline_edge_duplication_hook): Turn to ...
15546         (ipa_call_summary_t::duplicate): ... this one.
15547         (inline_edge_removal_hook): Turn to ...
15548         (ipa_call_summary_t::remove): ... this one.
15549         (dump_inline_edge_summary): Turn to ...
15550         (dump_ipa_call_summary): ... this one.
15551         (estimate_function_body_sizes): Update.
15552         (inline_update_callee_summaries): Update.
15553         (remap_edge_change_prob): Update.
15554         (remap_edge_summaries): Update.
15555         (inline_merge_summary): Update.
15556         (do_estimate_edge_time): Update.
15557         (inline_generate_summary): Update.
15558         (inline_read_section): Update.
15559         (inline_read_summary): Update.
15560         (inline_free_summary): Update.
15561         * ipa-inline.c (can_inline_edge_p): Update.
15562         (compute_inlined_call_time): Update.
15563         (want_inline_small_function_p): Update.
15564         (edge_badness): Update.
15565         (early_inliner): Update.
15566         * ipa-inline.h (inline_edge_summary): Turn to ...
15567         (ipa_call_summary): ... this one.
15568         (ipa_call_summary_t): New class.
15569         (inline_edge_summary_t, inline_edge_summary_vec): Remove.
15570         (ipa_call_summaries): New.
15571         (inline_edge_summary): Remove.
15572         (estimate_edge_growth): Update.
15573         * ipa-profile.c (ipa_propagate_frequency_1): Update.
15574         * ipa-prop.c (ipa_make_edge_direct_to_target): Update.
15575         * ipa-split.c (execute_split_functions): Update.
15576         * ipa.c (symbol_table::remove_unreachable_nodes): Update.
15578 2017-05-23  Tom de Vries  <tom@codesourcery.com>
15580         * doc/sourcebuild.texi (Effective-Target Keywords, Other hardware
15581         attributes): Document rdrand effective target.
15583 2017-05-23  Tom de Vries  <tom@codesourcery.com>
15585         * doc/sourcebuild.texi (Effective-Target Keywords, Other hardware
15586         attributes): Sort alphabetically.
15588 2017-05-23  Georg-Johann Lay  <avr@gjlay.de>
15590         * config/avr/genmultilib.awk: Use gsub instead of gensub.
15592 2017-05-22  Michael Meissner  <meissner@linux.vnet.ibm.com>
15594         PR target/80718
15595         * config/rs6000/vsx.md (vsx_splat_<mode>, VSX_D iterator): Split
15596         V2DF/V2DI splat into two separate patterns, one that handles
15597         registers, and the other that only handles memory.  Drop support
15598         for splatting from a GPR on ISA 2.07 and then splitting the
15599         splat into direct move and splat.
15600         (vsx_splat_<mode>_reg): Likewise.
15601         (vsx_splat_<mode>_mem): Likewise.
15603 2017-05-22  Segher Boessenkool  <segher@kernel.crashing.org>
15605         * cfgcleanup.c (bb_is_just_return): Allow CLOBBERs.
15607 2017-05-22  Jakub Jelinek  <jakub@redhat.com>
15609         PR middle-end/80809
15610         * omp-low.c (finish_taskreg_remap): New function.
15611         (finish_taskreg_scan): If unit size of ctx->record_type
15612         is non-constant, unshare the size expression and replace
15613         decls in it with possible outer var refs.
15615         PR middle-end/80809
15616         * gimplify.c (omp_add_variable): For GOVD_DEBUG_PRIVATE use
15617         GOVD_SHARED rather than GOVD_PRIVATE with it.
15618         (gimplify_adjust_omp_clauses_1, gimplify_adjust_omp_clauses): Expect
15619         GOVD_SHARED rather than GOVD_PRIVATE with GOVD_DEBUG_PRIVATE.
15621         PR middle-end/80853
15622         * omp-low.c (lower_reduction_clauses): Pass OMP_CLAUSE_PRIVATE
15623         as last argument to build_outer_var_ref for pointer bases of array
15624         section reductions.
15626 2017-05-19  Martin Sebor  <msebor@redhat.com>
15628         * print-tree.c (print_node): Print DECL_READ_P flag.
15630 2017-05-22  Jan Hubicka  <hubicka@ucw.cz>
15632         * Makefile.in: Add ipa-fnsummary.o and ipa-fnsummary.h
15633         * auto-profile.c: Replace ipa-inline.h by ipa-fnsummary.h
15634         * cgraph.c: Likewise.
15635         * cgraphunit.c: Likewise.
15636         * gengtype.c: Likewise.
15637         * ipa-cp.c: Likewise.
15638         * ipa-devirt.c: Likewise.
15639         * ipa-icf.c: Likewise.
15640         * ipa-predicate.c: Likewise.
15641         * ipa-profile.c: Likewise.
15642         * ipa-prop.c: Likewise.
15643         * ipa-split.c: Likewise.
15644         * ipa.c: Likewise.
15645         * ipa-inline-analysis.c (inline_summaries, ipa_call_summaries,
15646         edge_predicate_pool, dump_inline_hints,
15647         inline_summary::account_size_time, redirect_to_unreachable,
15648         edge_set_predicate, set_hint_predicate,
15649         evaluate_conditions_for_known_args, evaluate_properties_for_edge,
15650         inline_summary_alloc, ipa_call_summary::reset, inline_summary::reset,
15651         inline_summary_t::remove, remap_hint_predicate_after_duplication,
15652         inline_summary_t::duplicate, ipa_call_summary_t::duplicate,
15653         ipa_call_summary_t::remove, initialize_growth_caches,
15654         free_growth_caches, dump_ipa_call_summary, dump_inline_summary,
15655         debug_inline_summary, dump_inline_summaries, initialize_inline_failed,
15656         mark_modified, unmodified_parm_1, unmodified_parm,
15657         unmodified_parm_or_parm_agg_item, eliminated_by_inlining_prob,
15658         set_cond_stmt_execution_predicate, set_switch_stmt_execution_predicate,
15659         compute_bb_predicates, will_be_nonconstant_expr_predicate,
15660         will_be_nonconstant_predicate, record_modified_bb_info,
15661         get_minimal_bb, record_modified, param_change_prob,
15662         phi_result_unknown_predicate, predicate_for_phi_result,
15663         array_index_predicate, clobber_only_eh_bb_p, fp_expression_p,
15664         estimate_function_body_sizes, compute_inline_parameters,
15665         compute_inline_parameters_for_curren, pass_data_inline_parameters,
15666         estimate_node_size_and_time, estimate_ipcp_clone_size_and_time,
15667         inline_update_callee_summaries, remap_edge_change_prob,
15668         remap_edge_summaries, remap_hint_predicate, inline_merge_summary,
15669         inline_update_overall_summary, inline_indirect_intraprocedural_analysis,
15670         inline_analyze_function, inline_summary_t::insert,
15671         inline_generate_summary, read_ipa_call_summary, inline_read_section,
15672         inline_read_summary, write_ipa_call_summary, inline_write_summary,
15673         inline_free_summary): Move to ipa-fnsummary.h
15674         (predicate_t): Remove.
15675         * ipa-fnsummary.c: New file.
15676         * ipa-inline.h:  Do not include sreal.h and ipa-predicate.h
15677         (enum inline_hints_vals, inline_hints, agg_position_info,
15678         INLINE_SIZE_SCALE, size_time_entry, inline_summary, inline_summary_t,
15679         inline_summaries, ipa_call_summary, ipa_call_summary_t,
15680         ipa_call_summaries, debug_inline_summary, dump_inline_summaries,
15681         dump_inline_summary, dump_inline_hints, inline_generate_summary,
15682         inline_read_summary, inline_write_summary, inline_free_summary,
15683         inline_analyze_function, initialize_inline_failed,
15684         inline_merge_summary, inline_update_overall_summary,
15685         compute_inline_parameters): Move to ipa-fnsummary.h
15686         * ipa-fnsummary.h: New file.
15687         * ipa-inline-transform.h: Include ipa-inline.h.
15688         * ipa-inline.c: LIkewise.
15690 2017-05-22  Jan Hubicka  <hubicka@ucw.cz>
15692         * ipa-inline.c (edge_badness): Use inlined_time instead of
15693         inline_summaries->get.
15695 2017-05-22  Jan Hubicka  <hubicka@ucw.cz>
15697         * ipa-inline.c (edge_badness): Use estimate_size_after_inlining.
15699 2017-05-22  Nathan Sidwell  <nathan@acm.org>
15701         * doc/invoke.texi (fdump-translation-unit): Delete documentation.
15702         (fdump-lang): Document 'raw' option.
15703         * dumpfile.h (TDI_tu): Delete.
15704         * dumpfile.c (dump_files): Remove translation-unit.
15705         (FIRST_AUTO_NUMBERED_DUMP): Decrement.
15707 2017-05-22  Georg-Johann Lay  <avr@gjlay.de>
15709         * config/avr/t-avr (AWK) [t-multilib]: Remove "-v FORMAT=Makefile"
15710         command option from $(AWK) call.
15711         * config/avr/genmultilib.awk: Simplify and rewrite so that it
15712         generates MULTILIB_REQUIRED instead of MULTILIB_EXCEPTIONS.
15713         [FORMAT]: Remove handling of variable.
15714         * config/avr/t-multilib: Regenerate.
15716 2017-05-22  Jan Hubicka  <hubicka@ucw.cz>
15718         * ipa-inline-analysis.c (inline_summary::reset): Do not reset
15719         self_time.
15720         (dump_inline_summary): Do not print self_time.
15721         (estimate_function_body_sizes): Do not set self_time.
15722         (compute_inline_parameters): Likewise.
15723         (inline_read_section, inline_write_summary): Do not stream self_time.
15724         * ipa-inline.h (inline_summary): Drop self_time.
15726 2017-05-22  Jan Hubicka  <hubicka@ucw.cz>
15728         * ipa-inline-analysis.c (account_size_time): Rename to ...
15729         (inline_summary::account_size_time): ... this one.
15730         (reset_ipa_call_summary): Turn to ...
15731         (ipa_call_summary::reset): ... this one.
15732         (reset_inline_summary): Turn to ...
15733         (inline_summary::reset): ... this one.
15734         (inline_summary_t::remove): Update.
15735         (inline_summary_t::duplicate): Update.
15736         (ipa_call_summary_t::remove): Update.
15737         (dump_inline_summary): Update.
15738         (estimate_function_body_sizes): Update.
15739         (compute_inline_parameters): Update.
15740         (estimate_node_size_and_time): Update.
15741         (inline_merge_summary): Update.
15742         (inline_update_overall_summary): Update.
15743         (inline_read_section): Update.
15744         (inline_write_summary): Update.
15745         * ipa-inline.h (inline_summary): Rename entry to size_time_table;
15746         add account_size_time and reset member functions.
15747         (ipa_call_summary): Add reset function.
15748         * ipa-predicate.h (predicate::operator &): Constify.
15750 2017-05-22  Richard Biener  <rguenther@suse.de>
15752         * df-scan.c (df_insn_refs_verify): Speedup when not verifying.
15754 2017-05-19  Jason Merrill  <jason@redhat.com>
15756         * tree.c (make_tree_vec_stat, grow_tree_vec_stat): Use size_t.
15758 2017-05-19  Marek Polacek  <polacek@redhat.com>
15760         PR sanitizer/80800
15761         * fold-const.c (extract_muldiv_1) <case TRUNC_DIV_EXPR>: Add
15762         TYPE_OVERFLOW_WRAPS checks.
15764 2017-05-19  Thomas Schwinge  <thomas@codesourcery.com>
15766         * tree-core.h (enum omp_clause_default_kind): Add
15767         "OMP_CLAUSE_DEFAULT_PRESENT".
15768         * tree-pretty-print.c (dump_omp_clause): Handle it.
15769         * gimplify.c (enum gimplify_omp_var_data): Add
15770         "GOVD_MAP_FORCE_PRESENT".
15771         (gimplify_adjust_omp_clauses_1): Map it to
15772         "GOMP_MAP_FORCE_PRESENT".
15773         (oacc_default_clause): Handle "OMP_CLAUSE_DEFAULT_PRESENT".
15775         * gimplify.c (oacc_default_clause): Clarify.
15777 2017-05-19  Nathan Sidwell  <nathan@acm.org>
15779         LANG_HOOK_REGISTER_DUMPS
15780         * toplev.c (general_init): Call register dump lang hook.
15781         * doc/invoke.texi: Document -fdump-lang option family.
15782         * dumpfile.c (dump_files): Remove class dump here.
15783         (FIRST_AUTO_NUMBERED_DUMP): Adjust.
15784         * dumpfile.h (tree_dump_index): Remove TDI_class.
15785         * langhooks-def.h (lhd_register_dumps): Declare.
15786         (LANG_HOOKS_REGISTER_DUMPS): Define.
15787         (LANG_HOOKS_INITIALIZER): Add it.
15788         * langhooks.c (lhd_register_dumps): Define.
15789         * langhooks.h (struct lang_hooks): Add register_dumps.
15791 2017-05-19  Nathan Sidwell  <nathan@acm.org>
15793         * context.h (context::set_passes): New.
15794         * context.c (context::context): Do not create pass manager.
15795         * toplev.c (general_init): Create pass manager here.
15797 2017-05-19  Segher Boessenkool  <segher@kernel.crashing.org>
15799         * config/rs6000/rs6000.md (splitter to load of -1 and mask): Don't
15800         use this splitter if two add or or instructions would also work for
15801         the constant we want to generate.
15803 2017-05-19  Richard Biener  <rguenther@suse.de>
15805         PR build/80821
15806         * genmatch.c (dt_node::gen_kids_1): Add missing scope around
15807         predicate evaluation.
15809 2017-05-19  Jan Hubicka  <hubicka@ucw.cz>
15811         * ipa-inline.h (ipa_call_summary): Turn sizes into signed;
15812         add ctor.
15813         * ipa-inline.c (want_inline_small_function_p): Do not cast to
15814         unsigned.
15816 2017-05-19  Jan Hubicka  <hubicka@ucw.cz>
15818         * ipa-inline-analysis.c (cgraph_2edge_hook_list, cgraph_edge_hook_list,
15819         inline_edge_removal_hook, inline_edge_duplication_hook): Remove.
15820         (inline_edge_summary_vec): Turn into ...
15821         (ipa_call_summaries): ... this one.
15822         (redirect_to_unreachable, edge_set_predicate,
15823         evaluate_properties_for_edge, inline_summary_alloc,
15824         reset_ipa_call_summary, reset_inline_summary,
15825         inline_summary_t::duplicate): Update.
15826         (inline_edge_duplication_hook): Turn to ...
15827         (ipa_call_summary_t::duplicate): ... this one.
15828         (inline_edge_removal_hook): Turn to ...
15829         (ipa_call_summary_t::remove): ... this one.
15830         (dump_inline_edge_summary): Turn to ...
15831         (dump_ipa_call_summary): ... this one.
15832         (estimate_function_body_sizes): Update.
15833         (inline_update_callee_summaries): Update.
15834         (remap_edge_change_prob): Update.
15835         (remap_edge_summaries): Update.
15836         (inline_merge_summary): Update.
15837         (do_estimate_edge_time): Update.
15838         (inline_generate_summary): Update.
15839         (inline_read_section): Update.
15840         (inline_read_summary): Update.
15841         (inline_free_summary): Update.
15842         * ipa-inline.c (can_inline_edge_p): Update.
15843         (compute_inlined_call_time): Update.
15844         (want_inline_small_function_p): Update.
15845         (edge_badness): Update.
15846         (early_inliner): Update.
15847         * ipa-inline.h (inline_edge_summary): Turn to ...
15848         (ipa_call_summary): ... this one.
15849         (ipa_call_summary_t): New class.
15850         (inline_edge_summary_t, inline_edge_summary_vec): Remove.
15851         (ipa_call_summaries): New.
15852         (inline_edge_summary): Remove.
15853         (estimate_edge_growth): Update.
15854         * ipa-profile.c (ipa_propagate_frequency_1): Update.
15855         * ipa-prop.c (ipa_make_edge_direct_to_target): Update.
15856         * ipa-split.c (execute_split_functions): Update.
15857         * ipa.c (symbol_table::remove_unreachable_nodes): Update.
15859 2017-05-19  Richard Biener  <rguenther@suse.de>
15861         PR middle-end/80764
15862         * cfgexpand.c (expand_gimple_cond): Fix loop fixup.
15864 2017-05-18  Segher Boessenkool  <segher@kernel.crashing.org>
15866         * config/rs6000/rs6000.c (struct machine_function): Add field
15867         fpr_is_wrapped_separately.
15868         (rs6000_get_separate_components): Use 64 components.  Handle the
15869         new FPR components.
15870         (rs6000_components_for_bb): Handle the FPR components.
15871         (rs6000_emit_prologue_components): Handle the FPR components.
15872         (rs6000_emit_epilogue_components): Handle the FPR components.
15873         (rs6000_set_handled_components): Handle the FPR components.
15874         (rs6000_emit_prologue): Don't output prologue code for those FPRs
15875         that are already separately shrink-wrapped.
15876         (rs6000_emit_epilogue): Don't output epilogue code for those FPRs
15877         that are already separately shrink-wrapped.
15879 2017-05-18  Michael Meissner  <meissner@linux.vnet.ibm.com>
15881         PR target/80510
15882         * config/rs6000/predicates.md (simple_offsettable_mem_operand):
15883         New predicate.
15885         * config/rs6000/rs6000.md (ALTIVEC_DFORM): New iterator.
15886         (define_peephole2 for Altivec d-form load): Add peepholes to catch
15887         cases where the register allocator uses a move and an offsettable
15888         memory operation to/from a FPR register on ISA 2.06/2.07.
15889         (define_peephole2 for Altivec d-form store): Likewise.
15891 2017-05-18  Uros Bizjak  <ubizjak@gmail.com>
15893         PR target/80799
15894         * config/i386/mmx.md (*mov<mode>_internal): Enable
15895         alternatives 11, 12, 13 and 14 also for 32bit targets.
15896         Remove alternatives 15, 16, 17 and 18.
15897         * config/i386/sse.md (vec_concatv2di): Change
15898         alternative (!x, *y) to (x, ?!*Yn).
15900 2017-05-18  Paolo Carlini  <paolo.carlini@oracle.com>
15902         * dumpfile.h (enum dump_kind): Remove stray comma.
15904 2017-05-18  Jan Hubicka  <hubicka@ucw.cz>
15906         * Makefile.in: Add ipa-predicate.o and ipa-predicate.h
15907         * ipa-inline-analysis.c (NUM_CONDITIONS): turn into
15908         predicate::num_conditions
15909         (IS_NOT_CONSTANT): turn into predicate::is_not_constant.
15910         (CHANGED): turn into predicate::changed.
15911         (agg_position_info): Move to ipa-predicate.h
15912         (add_condition, predicate::add_clause, predicate::operator &=,
15913         predicate::or_with, predicate::evaluate, predicate::probability,
15914         dump_condition, dump_clause, predicate::dump,
15915         predicate::remap_after_duplication, predicate::remap_after_inlining,
15916         predicate::stream_in, predicate::stream_out): Move to ipa-predicate.c
15917         (evaluate_conditions_for_known_args): Update.
15918         (set_cond_stmt_execution_predicate): Update.
15919         * ipa-inline.h: Include ipa-predicate.h
15920         (condition, inline_param_summary, conditions, agg_position_info,
15921         predicate): Move to ipa-predicate.h
15922         * ipa-predicate.c: New file.
15923         * ipa-predicate.h: New file.
15925 2017-05-18  Wilco Dijkstra  <wdijkstr@arm.com>
15927         * final.c (leaf_function_p): Check we are not in a sequence.
15929 2017-05-18  Martin Liska  <mliska@suse.cz>
15931         * cfgrtl.c (rtl_verify_edges): Remove usage of TDF_RTL.
15932         * dumpfile.c (dump_register): Use new enum dump_kind.
15933         (get_dump_file_name): Likewise.
15934         (dump_enable_all): Likewise.
15935         (dump_switch_p_1): Likewise.
15936         (enable_rtl_dump_file): Remove usage of TDF_RTL.
15937         * dumpfile.h (enum dump_kind): New enum type.
15938         (struct dump_file_info): Create constructor and
15939         format fields and comments.
15940         * passes.c (pass_manager::register_one_dump_file):
15941         Use num dump_kind.
15942         * statistics.c (statistics_early_init): Likewise.
15943         * tree-ssa-loop-prefetch.c (dump_mem_details): Replace
15944         TDF_TREE with TDF_SLIM.
15945         (gather_memory_references_ref): Likewise.
15947 2017-05-18  Martin Liska  <mliska@suse.cz>
15949         * vec.h (struct vnull): Use it.
15951 2017-05-18  Jan Hubicka  <hubicka@ucw.cz>
15953         * ipa-inline-analysis.c (predicate_conditions): Move to ipa-inline.h
15954         (true_predicate, false_predicate, true_predicate_p,
15955         false_predicate_p): Remove.
15956         (single_cond_predicate, not_inlined_predicate): Turn to member function
15957         in ipa-inline.h
15958         (add_condition): Update.
15959         (add_clause): Turn to...
15960         (predicate::add_clause): ... this one; update; allow passing NULL
15961         as parameter.
15962         (and_predicates): Turn to ...
15963         (predicate::operator &=): ... this one.
15964         (predicates_equal_p): Move to predicate::operator == in ipa-inline.h
15965         (or_predicates): Turn to ...
15966         (predicate::or_with): ... this one.
15967         (evaluate_predicate): Turn to ...
15968         (predicate::evaluate): ... this one.
15969         (predicate_probability): Turn to ...
15970         (predicate::probability): ... this one.
15971         (dump_condition): Update.
15972         (dump_predicate): Turn to ...
15973         (predicate::dump): ... this one.
15974         (account_size_time): Update.
15975         (edge_set_predicate): Update.
15976         (set_hint_predicate): UPdate.
15977         (evaluate_conditions_for_known_args): Update.
15978         (evaluate_properties_for_edge): Update.
15979         (remap_predicate_after_duplication): Turn to...
15980         (predicate::remap_after_duplication): ... this one.
15981         (remap_hint_predicate_after_duplication): Update.
15982         (inline_summary_t::duplicate): UPdate.
15983         (dump_inline_edge_summary): Update.
15984         (dump_inline_summary): Update.
15985         (set_cond_stmt_execution_predicate): Update.
15986         (set_switch_stmt_execution_predicate): Update.
15987         (compute_bb_predicates): Update.
15988         (will_be_nonconstant_expr_predicate): Update.
15989         (will_be_nonconstant_predicate): Update.
15990         (phi_result_unknown_predicate): Update.
15991         (predicate_for_phi_result): Update.
15992         (array_index_predicate): Update.
15993         (estimate_function_body_sizes): Update.
15994         (estimate_node_size_and_time): Update.
15995         (estimate_ipcp_clone_size_and_time): Update.
15996         (remap_predicate): Rename to ...
15997         (predicate::remap_after_inlining): ... this one.
15998         (remap_hint_predicate): Update.
15999         (inline_merge_summary): Update.
16000         (inline_update_overall_summary): Update.
16001         (estimate_size_after_inlining): Update.
16002         (read_predicate): Rename to ...
16003         (predicate::stream_in): ... this one.
16004         (read_inline_edge_summary): Update.
16005         (write_predicate): Rename to ...
16006         (predicate::stream_out): ... this one.
16007         (write_inline_edge_summary): Update.
16008         * ipa-inline.h (MAX_CLAUSES): Turn to predicate::max_clauses.
16009         (clause_t): Turn to uint32_t
16010         (predicate): Turn to class; implement constructor and operators
16011         ==, !=, &
16012         (size_time_entry): Update.
16013         (inline_summary): Update.
16014         (inline_edge_summary): Update.
16016 2017-05-18  Marc Glisse  <marc.glisse@inria.fr>
16018         * fold-const.c (fold_binary_loc): Move transformation...
16019         * match.pd (C - X CMP X): ... here.
16021 2017-05-18  Sheldon Lobo  <sheldon.lobo@oracle.com>
16023         * config/sparc/sparc.c (sparc_option_override): Set function
16024         alignment for -mcpu=niagara7 to 64 to match the I$ line.
16025         * config/sparc/sparc.h (BRANCH_COST): Set the SPARC M7 branch
16026         latency to 1.
16027         * config/sparc/sparc.h (BRANCH_COST): Set the SPARC T4 branch
16028         latency to 2.
16029         * config/sparc/sol2.h: Fix a ASM_CPU32_DEFAULT_SPEC typo.
16031 2017-05-18  Marek Polacek  <polacek@redhat.com>
16033         PR sanitizer/80797
16034         * ubsan.c (instrument_null): Unwrap ADDR_EXPRs.
16035         (pass_ubsan::execute): Call gimple_assign_single_p instead of
16036         gimple_assign_load_p.
16038 2017-05-17  Segher Boessenkool  <segher@kernel.crashing.org>
16040         PR middle-end/80692
16041         * real.c (do_compare): Give decimal_do_compare preference over
16042         comparing just the signs.
16044 2017-05-17  Uros Bizjak  <ubizjak@gmail.com>
16046         * doc/md.texi (Canonicalization of Instructions): Describe the
16047         canonical form of instructions that inherently set a condition
16048         code register.
16050 2017-05-17  Peter Bergner  <bergner@vnet.ibm.com>
16052         PR middle-end/80775
16053         * tree-cfg.c: Move deletion of unreachable case statements to after
16054         the merging of consecutive case labels.
16056 2017-05-17  Thomas Preud'homme  <thomas.preudhomme@arm.com>
16058         * config/arm/arm.c (cmse_nonsecure_call_clear_caller_saved): Refer
16059         readers to __gnu_cmse_nonsecure_call libcall for saving, clearing and
16060         restoring of callee-saved registers.
16062 2017-05-17  Eric Botcazou  <ebotcazou@adacore.com>
16064         * compare-elim.c (equivalent_reg_at_start): Adjust outdated comment.
16065         * config/visium/visium.c (single_set_and_flags): Likewise.
16066         * config/visium/visium.md (Substitutions): Likewise.
16068 2017-05-17  Martin Liska  <mliska@suse.cz>
16070         * cfg.c: Introduce dump_flags_t type and
16071         use it instead of int type.
16072         * cfg.h: Likewise.
16073         * cfghooks.c: Likewise.
16074         * cfghooks.h (struct cfg_hooks): Likewise.
16075         * cfgrtl.c: Likewise.
16076         * cfgrtl.h: Likewise.
16077         * cgraph.c (cgraph_node::get_body): Likewise.
16078         * coretypes.h: Likewise.
16079         * domwalk.c: Likewise.
16080         * domwalk.h: Likewise.
16081         * dumpfile.c (struct dump_option_value_info): Likewise.
16082         (dump_enable_all): Likewise.
16083         (dump_switch_p_1): Likewise.
16084         (opt_info_switch_p): Likewise.
16085         * dumpfile.h (enum tree_dump_index): Likewise.
16086         (struct dump_file_info): Likewise.
16087         * genemit.c: Likewise.
16088         * generic-match-head.c: Likewise.
16089         * gengtype.c (open_base_files): Likewise.
16090         * gimple-pretty-print.c: Likewise.
16091         * gimple-pretty-print.h: Likewise.
16092         * graph.c (print_graph_cfg): Likewise.
16093         * graphite-scop-detection.c (dot_all_sese): Likewise.
16094         * ipa-devirt.c (build_type_inheritance_graph): Likewise.
16095         * loop-unroll.c (report_unroll): Likewise.
16096         * passes.c (pass_manager::register_one_dump_file): Likewise.
16097         * print-tree.c: Likewise.
16098         * statistics.c: Likewise.
16099         * tree-cfg.c: Likewise.
16100         * tree-cfg.h: Likewise.
16101         * tree-dfa.c: Likewise.
16102         * tree-dfa.h: Likewise.
16103         * tree-dump.c (dump_function): Likewise.
16104         * tree-dump.h (struct dump_info): Likewise.
16105         * tree-pretty-print.c: Likewise.
16106         * tree-pretty-print.h: Likewise.
16107         * tree-ssa-live.c: Likewise.
16108         * tree-ssa-live.h: Likewise.
16109         * tree-ssa-loop-ivcanon.c (try_unroll_loop_completely): Likewise.
16110         * tree-vect-loop.c: Likewise.
16111         * tree-vect-slp.c: Likewise.
16113 2017-05-16  James Greenhalgh  <james.greenhalgh@arm.com>
16114             Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
16116         PR tree-optimization/80457
16117         * tree-vect-stmts.c (vect_model_simple_cost): Model the cost
16118         of all arguments to a statement as scalar_to_vec operations.
16119         (vectorizable_call): Adjust call to vect_model_simple_cost for
16120         new parameter.
16121         (vectorizable_conversion): Likewise.
16122         (vectorizable_assignment): Likewise.
16123         (vectorizable_shift): Likewise.
16124         (vectorizable_operation): Likewise.
16125         (vectorizable_comparison): Likewise.
16126         (vect_is_simple_cond): Record the def types for operands.
16127         (vectorizable_condition): Likewise, call vect_model_simple_cost.
16128         * tree-vectorizer.h (vect_model_simple_cost): Add new parameter
16129         for statement argument count.
16131 2017-05-16  Carl Love  <cel@us.ibm.com>
16133         * config/rs6000/rs6000-c: Add support for built-in functions
16134         vector unsigned long long vec_bperm (vector unsigned long long,
16135                                              vector unsigned char)
16136         vector signed long long vec_mule (vector signed int,
16137                                           vector signed int)
16138         vector unsigned long long vec_mule (vector unsigned int,
16139                                             vector unsigned int)
16140         vector signed long long vec_mulo (vector signed int,
16141                                           vector signed int)
16142         vector unsigned long long vec_mulo (vector unsigned int,
16143                                             vector unsigned int)
16144         vector signed char vec_sldw (vector signed char,
16145                                      vector signed char,
16146                                      const int)
16147         vector unsigned char vec_sldw (vector unsigned char,
16148                                        vector unsigned char,
16149                                        const int)
16150         vector signed short vec_sldw (vector signed short,
16151                                       vector signed short,
16152                                       const int)
16153         vector unsigned short vec_sldw (vector unsigned short,
16154                                         vector unsigned short,
16155                                         const int)
16156         vector signed int vec_sldw (vector signed int,
16157                                     vector signed int,
16158                                     const int)
16159         vector unsigned int vec_sldw (vector unsigned int,
16160                                       vector unsigned int,
16161                                       const int)
16162         vector signed long long vec_sldw (vector signed long long,
16163                                           vector signed long long,
16164                                           const int)
16165         vector unsigned long long vec_sldw (vector unsigned long long,
16166                                             vector unsigned long long,
16167                                             const int)
16168         * config/rs6000/rs6000-c: Add support for built-in functions
16169         * config/rs6000/rs6000-builtin.def: Add definition for SLDW.
16170         * config/rs6000/altivec.h: Add defintion for vec_sldw.
16171         * doc/extend.texi: Update the built-in documentation for the
16172         new built-in functions.
16174 2017-05-16  Marek Polacek  <polacek@redhat.com>
16176         PR sanitizer/80536
16177         PR sanitizer/80386
16178         * tree.c (save_expr): Don't fold the expression.
16180 2017-05-16  Uros Bizjak  <ubizjak@gmail.com>
16182         * config/i386/i386.md (*movsi_internal): Split (?rm,*y) alternative
16183         to (?r,*Yn) and (?m,*y) alternatives, and (?*y,rm) to (?*Ym,r)
16184         and (?*y,m).  Update insn attributes.
16186 2017-05-16  Martin Liska  <mliska@suse.cz>
16188         * cgraph.c (cgraph_edge::resolve_speculation): Add default value for
16189         flags argument of print_gimple_stmt, print_gimple_expr,
16190         print_generic_stmt and print_generic_expr.
16191         * cgraphclones.c (symbol_table::materialize_all_clones): Likewise.
16192         * coretypes.h: Likewise.
16193         * except.c (dump_eh_tree): Likewise.
16194         * gimple-fold.c (gimple_fold_stmt_to_constant_1): Likewise.
16195         * gimple-pretty-print.h: Likewise.
16196         * gimple-ssa-backprop.c (dump_usage_prefix): Likewise.
16197         (backprop::push_to_worklist): Likewise.
16198         (backprop::pop_from_worklist): Likewise.
16199         (backprop::process_use): Likewise.
16200         (backprop::intersect_uses): Likewise.
16201         (note_replacement): Likewise.
16202         * gimple-ssa-store-merging.c
16203         (pass_store_merging::terminate_all_aliasing_chains): Likewise.
16204         (imm_store_chain_info::coalesce_immediate_stores): Likewise.
16205         (pass_store_merging::execute): Likewise.
16206         * gimple-ssa-strength-reduction.c (dump_candidate): Likewise.
16207         (ssa_base_cand_dump_callback): Likewise.
16208         (dump_incr_vec): Likewise.
16209         (replace_refs): Likewise.
16210         (replace_mult_candidate): Likewise.
16211         (create_add_on_incoming_edge): Likewise.
16212         (create_phi_basis): Likewise.
16213         (insert_initializers): Likewise.
16214         (all_phi_incrs_profitable): Likewise.
16215         (introduce_cast_before_cand): Likewise.
16216         (replace_one_candidate): Likewise.
16217         * gimplify.c (gimplify_expr): Likewise.
16218         * graphite-isl-ast-to-gimple.c (is_valid_rename): Likewise.
16219         (set_rename): Likewise.
16220         (rename_uses): Likewise.
16221         (copy_loop_phi_nodes): Likewise.
16222         (add_close_phis_to_merge_points): Likewise.
16223         (copy_loop_close_phi_args): Likewise.
16224         (copy_cond_phi_args): Likewise.
16225         (graphite_copy_stmts_from_block): Likewise.
16226         (translate_pending_phi_nodes): Likewise.
16227         * graphite-poly.c (print_pdr): Likewise.
16228         (dump_gbb_cases): Likewise.
16229         (dump_gbb_conditions): Likewise.
16230         (print_scop_params): Likewise.
16231         * graphite-scop-detection.c (build_cross_bb_scalars_def): Likewise.
16232         (build_cross_bb_scalars_use): Likewise.
16233         (gather_bbs::before_dom_children): Likewise.
16234         * hsa-dump.c (dump_hsa_immed): Likewise.
16235         * ipa-cp.c (print_ipcp_constant_value): Likewise.
16236         (get_replacement_map): Likewise.
16237         * ipa-inline-analysis.c (dump_condition): Likewise.
16238         (estimate_function_body_sizes): Likewise.
16239         * ipa-polymorphic-call.c (check_stmt_for_type_change): Likewise.
16240         (ipa_polymorphic_call_context::get_dynamic_type): Likewise.
16241         * ipa-prop.c (ipa_dump_param): Likewise.
16242         (ipa_print_node_jump_functions_for_edge): Likewise.
16243         (ipa_modify_call_arguments): Likewise.
16244         (ipa_modify_expr): Likewise.
16245         (ipa_dump_param_adjustments): Likewise.
16246         (ipa_dump_agg_replacement_values): Likewise.
16247         (ipcp_modif_dom_walker::before_dom_children): Likewise.
16248         * ipa-pure-const.c (check_stmt): Likewise.
16249         (pass_nothrow::execute): Likewise.
16250         * ipa-split.c (execute_split_functions): Likewise.
16251         * omp-offload.c (dump_oacc_loop_part): Likewise.
16252         (dump_oacc_loop): Likewise.
16253         * trans-mem.c (tm_log_emit): Likewise.
16254         (tm_memopt_accumulate_memops): Likewise.
16255         (dump_tm_memopt_set): Likewise.
16256         (dump_tm_memopt_transform): Likewise.
16257         * tree-cfg.c (gimple_verify_flow_info): Likewise.
16258         (print_loop): Likewise.
16259         * tree-chkp-opt.c (chkp_print_addr): Likewise.
16260         (chkp_gather_checks_info): Likewise.
16261         (chkp_get_check_result): Likewise.
16262         (chkp_remove_check_if_pass): Likewise.
16263         (chkp_use_outer_bounds_if_possible): Likewise.
16264         (chkp_reduce_bounds_lifetime): Likewise.
16265         * tree-chkp.c (chkp_register_addr_bounds): Likewise.
16266         (chkp_mark_completed_bounds): Likewise.
16267         (chkp_register_incomplete_bounds): Likewise.
16268         (chkp_mark_invalid_bounds): Likewise.
16269         (chkp_maybe_copy_and_register_bounds): Likewise.
16270         (chkp_build_returned_bound): Likewise.
16271         (chkp_get_bound_for_parm): Likewise.
16272         (chkp_build_bndldx): Likewise.
16273         (chkp_get_bounds_by_definition): Likewise.
16274         (chkp_generate_extern_var_bounds): Likewise.
16275         (chkp_get_bounds_for_decl_addr): Likewise.
16276         * tree-chrec.c (chrec_apply): Likewise.
16277         * tree-data-ref.c (dump_data_reference): Likewise.
16278         (dump_subscript): Likewise.
16279         (dump_data_dependence_relation): Likewise.
16280         (analyze_overlapping_iterations): Likewise.
16281         * tree-inline.c (expand_call_inline): Likewise.
16282         (tree_function_versioning): Likewise.
16283         * tree-into-ssa.c (dump_defs_stack): Likewise.
16284         (dump_currdefs): Likewise.
16285         (dump_names_replaced_by): Likewise.
16286         (dump_update_ssa): Likewise.
16287         (update_ssa): Likewise.
16288         * tree-object-size.c (pass_object_sizes::execute): Likewise.
16289         * tree-parloops.c (build_new_reduction): Likewise.
16290         (try_create_reduction_list): Likewise.
16291         (ref_conflicts_with_region): Likewise.
16292         (oacc_entry_exit_ok_1): Likewise.
16293         (oacc_entry_exit_single_gang): Likewise.
16294         * tree-pretty-print.h: Likewise.
16295         * tree-scalar-evolution.c (set_scalar_evolution): Likewise.
16296         (get_scalar_evolution): Likewise.
16297         (add_to_evolution): Likewise.
16298         (get_loop_exit_condition): Likewise.
16299         (analyze_evolution_in_loop): Likewise.
16300         (analyze_initial_condition): Likewise.
16301         (analyze_scalar_evolution): Likewise.
16302         (instantiate_scev): Likewise.
16303         (number_of_latch_executions): Likewise.
16304         (gather_chrec_stats): Likewise.
16305         (final_value_replacement_loop): Likewise.
16306         (scev_const_prop): Likewise.
16307         * tree-sra.c (dump_access): Likewise.
16308         (disqualify_candidate): Likewise.
16309         (create_access): Likewise.
16310         (reject): Likewise.
16311         (maybe_add_sra_candidate): Likewise.
16312         (create_access_replacement): Likewise.
16313         (analyze_access_subtree): Likewise.
16314         (analyze_all_variable_accesses): Likewise.
16315         (sra_modify_assign): Likewise.
16316         (initialize_constant_pool_replacements): Likewise.
16317         (find_param_candidates): Likewise.
16318         (decide_one_param_reduction): Likewise.
16319         (replace_removed_params_ssa_names): Likewise.
16320         * tree-ssa-ccp.c (ccp_fold_stmt): Likewise.
16321         * tree-ssa-copy.c (dump_copy_of): Likewise.
16322         (copy_prop_visit_cond_stmt): Likewise.
16323         * tree-ssa-dce.c (mark_operand_necessary): Likewise.
16324         * tree-ssa-dom.c (pass_dominator::execute): Likewise.
16325         (record_equivalences_from_stmt): Likewise.
16326         * tree-ssa-dse.c (compute_trims): Likewise.
16327         (delete_dead_call): Likewise.
16328         (delete_dead_assignment): Likewise.
16329         * tree-ssa-forwprop.c (forward_propagate_into_gimple_cond): Likewise.
16330         (forward_propagate_into_cond): Likewise.
16331         (pass_forwprop::execute): Likewise.
16332         * tree-ssa-ifcombine.c (ifcombine_ifandif): Likewise.
16333         * tree-ssa-loop-im.c (invariantness_dom_walker::before_dom_children):
16334         Likewise.
16335         (move_computations_worker): Likewise.
16336         (execute_sm): Likewise.
16337         * tree-ssa-loop-ivcanon.c (tree_estimate_loop_size): Likewise.
16338         (remove_exits_and_undefined_stmts): Likewise.
16339         (remove_redundant_iv_tests): Likewise.
16340         * tree-ssa-loop-ivopts.c (dump_use): Likewise.
16341         (adjust_iv_update_pos): Likewise.
16342         * tree-ssa-math-opts.c (bswap_replace): Likewise.
16343         * tree-ssa-phiopt.c (factor_out_conditional_conversion): Likewise.
16344         (value_replacement): Likewise.
16345         * tree-ssa-phiprop.c (phiprop_insert_phi): Likewise.
16346         * tree-ssa-pre.c (print_pre_expr): Likewise.
16347         (get_representative_for): Likewise.
16348         (create_expression_by_pieces): Likewise.
16349         (insert_into_preds_of_block): Likewise.
16350         (eliminate_insert): Likewise.
16351         (eliminate_dom_walker::before_dom_children): Likewise.
16352         (eliminate): Likewise.
16353         (remove_dead_inserted_code): Likewise.
16354         * tree-ssa-propagate.c (substitute_and_fold): Likewise.
16355         * tree-ssa-reassoc.c (get_rank): Likewise.
16356         (eliminate_duplicate_pair): Likewise.
16357         (eliminate_plus_minus_pair): Likewise.
16358         (eliminate_not_pairs): Likewise.
16359         (undistribute_ops_list): Likewise.
16360         (eliminate_redundant_comparison): Likewise.
16361         (update_range_test): Likewise.
16362         (optimize_range_tests_var_bound): Likewise.
16363         (optimize_vec_cond_expr): Likewise.
16364         (rewrite_expr_tree): Likewise.
16365         (rewrite_expr_tree_parallel): Likewise.
16366         (linearize_expr): Likewise.
16367         (break_up_subtract): Likewise.
16368         (linearize_expr_tree): Likewise.
16369         (attempt_builtin_powi): Likewise.
16370         (attempt_builtin_copysign): Likewise.
16371         (transform_stmt_to_copy): Likewise.
16372         (transform_stmt_to_multiply): Likewise.
16373         (dump_ops_vector): Likewise.
16374         * tree-ssa-sccvn.c (vn_nary_build_or_lookup_1): Likewise.
16375         (print_scc): Likewise.
16376         (set_ssa_val_to): Likewise.
16377         (visit_reference_op_store): Likewise.
16378         (visit_use): Likewise.
16379         (sccvn_dom_walker::before_dom_children): Likewise.
16380         (run_scc_vn): Likewise.
16381         * tree-ssa-scopedtables.c (avail_exprs_stack::lookup_avail_expr):
16382         Likewise.
16383         (expr_hash_elt::print): Likewise.
16384         (const_and_copies::pop_to_marker): Likewise.
16385         (const_and_copies::record_const_or_copy_raw): Likewise.
16386         * tree-ssa-structalias.c (compute_dependence_clique): Likewise.
16387         * tree-ssa-uninit.c (collect_phi_def_edges): Likewise.
16388         (dump_predicates): Likewise.
16389         (find_uninit_use): Likewise.
16390         (warn_uninitialized_phi): Likewise.
16391         (pass_late_warn_uninitialized::execute): Likewise.
16392         * tree-ssa.c (verify_vssa): Likewise.
16393         (verify_ssa): Likewise.
16394         (maybe_optimize_var): Likewise.
16395         * tree-vrp.c (dump_value_range): Likewise.
16396         (dump_all_value_ranges): Likewise.
16397         (dump_asserts_for): Likewise.
16398         (register_edge_assert_for_2): Likewise.
16399         (vrp_visit_cond_stmt): Likewise.
16400         (vrp_visit_switch_stmt): Likewise.
16401         (vrp_visit_stmt): Likewise.
16402         (vrp_visit_phi_node): Likewise.
16403         (simplify_cond_using_ranges_1): Likewise.
16404         (fold_predicate_in): Likewise.
16405         (evrp_dom_walker::before_dom_children): Likewise.
16406         (evrp_dom_walker::push_value_range): Likewise.
16407         (evrp_dom_walker::pop_value_range): Likewise.
16408         (execute_early_vrp): Likewise.
16410 2017-05-16  Richard Biener  <rguenther@suse.de>
16412         * dwarf2out.c (loc_list_from_tree_1): Do not create
16413         DW_OP_GNU_variable_value for DECL_IGNORED_P decls.
16415 2017-05-16  Richard Biener  <rguenther@suse.de>
16417         * dwarf2out.c (resolve_variable_value_in_expr): Lookup DIE
16418         just generated.
16419         (note_variable_value_in_expr): If we resolved the decl ref
16420         do not push to the stack.
16422 2017-05-16  Matthew Wahab  <matthew.wahab@arm.com>
16424         * config/arm/arm_neon.h (vadd_f16): Use standard arithmetic
16425         operations in fast-math mode.
16426         (vaddq_f16): Likewise.
16427         (vmul_f16): Likewise.
16428         (vmulq_f16): Likewise.
16429         (vsub_f16): Likewise.
16430         (vsubq_f16): Likewise.
16431         * config/arm/neon.md (add<mode>3): New.
16432         (sub<mode>3): New.
16433         (fma:<VH:mode>3): New.  Also remove outdated comment.
16434         (mul<mode>3): New.
16436 2017-05-16  Martin Liska  <mliska@suse.cz>
16438         PR ipa/79849.
16439         PR ipa/79850.
16440         * ipa-devirt.c (warn_types_mismatch): Fix typo.
16441         (odr_types_equivalent_p): Likewise.
16443 2017-05-15  Sylvestre Ledru  <sylvestre@debian.org>
16445         * plugin.c (try_init_one_plugin): Fix ressource leaks (CID 726637).
16447 2017-05-15  Uros Bizjak  <ubizjak@gmail.com>
16449         PR target/80425
16450         * config/i386.i386.md (*zero_extendsidi2): Do not penalize
16451         non-interunit SSE move alternatives with '?'.
16452         (zero-extendsidi peephole2): New peephole to skip intermediate
16453         general register in SSE zero-extend sequence.
16455 2017-05-15  Jeff Law  <law@redhat.com>
16457         * reorg.c (relax_delay_slots): Create a new variable to hold
16458         the temporary target rather than clobbering TARGET_LABEL.
16460         * config/tilegx/tilegx.c (tilegx_expand_unaligned_load): Add
16461         missing argument to extract_bit_field call.
16462         * config/tilepro/tilepro.c (tilepro_expand_unaligned_load): Likewise.
16464 2017-05-15  Martin Liska  <mliska@suse.cz>
16466         PR driver/31468
16467         * gcc.c (process_command): Do not allow empty argument of -o option.
16469 2017-05-15  Renlin Li  <renlin.li@arm.com>
16471         * config/aarch64/aarch64-protos.h (aarch64_expand_call): Declare.
16472         * config/aarch64/aarch64.c (aarch64_expand_call): Define.
16473         * config/aarch64/constraints.md (Usf): Add long call check.
16474         * config/aarch64/aarch64.md (call): Use aarch64_expand_call.
16475         (call_value): Likewise.
16476         (sibcall): Likewise.
16477         (sibcall_value): Likewise.
16478         (call_insn): New.
16479         (call_value_insn): New.
16480         (sibcall_insn): Update rtx pattern.
16481         (sibcall_value_insn): Likewise.
16482         (call_internal): Remove.
16483         (call_value_internal): Likewise.
16484         (sibcall_internal): Likewise.
16485         (sibcall_value_internal): Likewise.
16486         (call_reg): Likewise.
16487         (call_symbol): Likewise.
16488         (call_value_reg): Likewise.
16489         (call_value_symbol): Likewise.
16491 2017-05-14  Krister Walfridsson  <krister.walfridsson@gmail.com>
16493         PR target/80600
16494         * config/netbsd.h (NETBSD_LIBGCC_SPEC): Always add -lgcc.
16496 2017-05-14  Uros Bizjak  <ubizjak@gmail.com>
16498         * config/i386.i386.c (ix86_cc_modes_compatible): CCNOmode is
16499         compatible with CCGOCmode and with CCZmode.
16501 2017-05-14  Martin Sebor  <msebor@redhat.com>
16503         PR middle-end/77671
16504         * gimple-fold.c (gimple_fold_builtin_sprintf): Make extern.
16505         (gimple_fold_builtin_snprintf): Same.
16506         * gimple-fold.h (gimple_fold_builtin_sprintf): Declare.
16507         (gimple_fold_builtin_snprintf): Same.
16508         * gimple-ssa-sprintf.c (get_format_string): Correct the detection
16509         of character types.
16510         (is_call_safe): New function.
16511         (try_substitute_return_value): Call it.
16512         (try_simplify_call): New function.
16513         (pass_sprintf_length::handle_gimple_call): Call it.
16515 2017-05-14  Martin Sebor  <msebor@redhat.com>
16517         PR middle-end/80669
16518         * builtins.c (expand_builtin_stpncpy): Simplify.
16520 2017-05-14  Daniel Santos  <daniel.santos@pobox.com>
16522         * config/i386/i386.opt: Add option -mcall-ms2sysv-xlogues.
16523         * config/i386/i386.h
16524         (x86_64_ms_sysv_extra_clobbered_registers): Change type to unsigned.
16525         (NUM_X86_64_MS_CLOBBERED_REGS): New macro.
16526         (struct machine_function): Add new members call_ms2sysv,
16527         call_ms2sysv_pad_in, call_ms2sysv_pad_out and call_ms2sysv_extra_regs.
16528         (struct machine_frame_state): New fields sp_realigned and
16529         sp_realigned_offset.
16530         * config/i386/i386.c
16531         (enum xlogue_stub): New enum.
16532         (enum xlogue_stub_sets): New enum.
16533         (class xlogue_layout): New class.
16534         (struct ix86_frame): New fields stack_realign_allocate_offset,
16535         stack_realign_offset and outlined_save_offset.  Modify comments to
16536         detail stack layout when using out-of-line stubs.
16537         (ix86_target_string): Add -mcall-ms2sysv-xlogues option.
16538         (ix86_option_override_internal): Add sorry() for TARGET_SEH and
16539         -mcall-ms2sysv-xlogues.
16540         (stub_managed_regs): New static variable.
16541         (ix86_save_reg): Add new parameter ignore_outlined to optionally omit
16542         registers managed by out-of-line stub.
16543         (disable_call_ms2sysv_xlogues): New function.
16544         (ix86_compute_frame_layout): Modify re-alignment calculations, disable
16545         m->call_ms2sysv when appropriate and compute frame layout for
16546         out-of-line stubs.
16547         (sp_valid_at, fp_valid_at): New inline functions.
16548         (choose_basereg): New function.
16549         (choose_baseaddr): Add align parameter, use choose_basereg and modify
16550         all callers.
16551         (ix86_emit_save_reg_using_mov, ix86_emit_restore_sse_regs_using_mov):
16552         Use align parameter of choose_baseaddr to generated aligned SSE movs
16553         when possible.
16554         (pro_epilogue_adjust_stack): Modify to track
16555         machine_frame_state::sp_realigned.
16556         (ix86_nsaved_regs): Modify to accommodate changes to ix86_save_reg.
16557         (ix86_nsaved_sseregs): Likewise.
16558         (ix86_emit_save_regs): Likewise.
16559         (ix86_emit_save_regs_using_mov): Likewise.
16560         (ix86_emit_save_sse_regs_using_mov): Likewise.
16561         (get_scratch_register_on_entry): Likewise.
16562         (gen_frame_set): New function.
16563         (gen_frame_load): Likewise.
16564         (gen_frame_store): Likewise.
16565         (emit_outlined_ms2sysv_save): Likewise.
16566         (emit_outlined_ms2sysv_restore): Likewise.
16567         (ix86_expand_prologue): Modify stack re-alignment code and call
16568         emit_outlined_ms2sysv_save when appropriate.
16569         (ix86_emit_leave): Clear machine_frame_state::sp_realigned.  Add
16570         parameter rtx_insn *insn, which allows the function to be used to only
16571         generate the notes.
16572         (ix86_expand_epilogue): Modify validity checks of frame and stack
16573         pointers, and call emit_outlined_ms2sysv_restore when appropriate.
16574         (ix86_expand_call): Modify to enable m->call_ms2sysv when appropriate.
16575         * config/i386/predicates.md
16576         (save_multiple): New predicate.
16577         (restore_multiple): Likewise.
16578         * config/i386/sse.md
16579         (save_multiple<mode>): New pattern.
16580         (save_multiple_realign<mode>): Likewise.
16581         (restore_multiple<mode>): Likewise.
16582         (restore_multiple_and_return<mode>): Likewise.
16583         (restore_multiple_leave_return<mode>): Likewise.
16584         * Makefile.in: Export HOSTCXX and HOSTCXXFLAGS to site.exp
16586 2017-05-14  Julia Koval  <julia.koval@intel.com>
16588         * config/i386/i386-builtin-types.def (VOID_FTYPE_INT_INT64): New type.
16589         * config/i386/i386-builtin.def (__builtin_ia32_xgetbv)
16590         (__builtin_ia32_xsetbv): New builtins.
16591         * config/i386/i386.c (ix86_expand_special_args_builtin):
16592         Process new types.
16593         (ix86_expand_builtin): Special expand for new intrinsics.
16594         * config/i386/i386.md (UNSPECV_XGETBV, UNSPECV_XSETBV): New.
16595         (xsetbv, xsetbv_rex64, xgetbv, xgetbv_rex64): New insn patterns.
16596         * config/i386/xsaveintrin.h (_xsetbv, _getbv): New intrinsics.
16598 2017-05-13  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
16600         * cfganal.c (inverted_post_order_compute): Change argument type
16601         to vec *.
16602         * cfganal.h (inverted_post_order_compute): Adjust prototype.
16603         * df-core.c (rest_of_handle_df_initialize): Adjust.
16604         (rest_of_handle_df_finish): Likewise.
16605         (df_analyze_1): Likewise.
16606         (df_analyze): Likewise.
16607         (loop_inverted_post_order_compute): Change argument to be a vec *.
16608         (df_analyze_loop): Adjust.
16609         (df_get_n_blocks): Likewise.
16610         (df_get_postorder): Likewise.
16611         * df.h (struct df_d): Change field to be a vec.
16612         * lcm.c (compute_laterin): Adjust.
16613         (compute_available): Likewise.
16614         * lra-lives.c (lra_create_live_ranges_1): Likewise.
16615         * tree-ssa-dce.c (remove_dead_stmt): Likewise.
16616         * tree-ssa-pre.c (compute_antic): Likewise.
16618 2017-05-13  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
16620         * cfganal.c (connect_infinite_loops_to_exit): Adjust.
16621         (depth_first_search::depth_first_search): Change structure init
16622         function to this constructor.
16623         (depth_first_search::add_bb): Rename function to this member.
16624         (depth_first_search::execute): Likewise.
16625         (flow_dfs_compute_reverse_finish): Adjust.
16627 2017-05-13  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
16629         * ddg.c (find_nodes_on_paths): Use auto_sbitmap.
16630         (longest_simple_path): Likewise.
16631         * shrink-wrap.c (spread_components): Likewise.
16632         (disqualify_problematic_components): Likewise.
16633         (emit_common_heads_for_components): Likewise.
16634         (emit_common_tails_for_components): Likewise.
16635         (insert_prologue_epilogue_for_components): Likewise.
16637 2017-05-13  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
16639         * tree-ssa-dse.c (dse_dom_walker): Make m_live_byes a
16640         auto_sbitmap.
16642 2017-05-13  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
16644         * df-core.c (df_set_blocks): Start using auto_bitmap.
16645         (df_compact_blocks): Likewise.
16646         * df-problems.c (df_rd_confluence_n): Likewise.
16647         * df-scan.c (df_insn_rescan_all): Likewise.
16648         (df_process_deferred_rescans): Likewise.
16649         (df_update_entry_block_defs): Likewise.
16650         (df_update_exit_block_uses): Likewise.
16651         (df_entry_block_bitmap_verify): Likewise.
16652         (df_exit_block_bitmap_verify): Likewise.
16653         (df_scan_verify): Likewise.
16654         * lra-constraints.c (lra_constraints): Likewise.
16655         (undo_optional_reloads): Likewise.
16656         (lra_undo_inheritance): Likewise.
16657         * lra-remat.c (calculate_gen_cands): Likewise.
16658         (do_remat): Likewise.
16659         * lra-spills.c (assign_spill_hard_regs): Likewise.
16660         (spill_pseudos): Likewise.
16661         * tree-ssa-pre.c (bitmap_set_and): Likewise.
16662         (bitmap_set_subtract_values): Likewise.
16664 2017-05-13  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
16666         * haifa-sched.c (estimate_shadow_tick): Replace manual bitmap
16667         management with auto_bitmap.
16668         (fix_inter_tick): Likewise.
16669         (fix_recovery_deps): Likewise.
16670         * ira.c (add_store_equivs): Likewise.
16671         (find_moveable_pseudos): Likewise.
16672         (split_live_ranges_for_shrink_wrap): Likewise.
16673         * print-rtl.c (rtx_reuse_manager::rtx_reuse_manager): Likewise.
16674         (rtx_reuse_manager::seen_def_p): Likewise.
16675         (rtx_reuse_manager::set_seen_def): Likewise.
16676         * print-rtl.h (class rtx_reuse_manager): Likewise.
16678 2017-05-13  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
16680         * bt-load.c (combine_btr_defs): Use auto_bitmap to manage bitmap
16681         lifetime.
16682         (migrate_btr_def): Likewise.
16683         * cfgloop.c (get_loop_body_in_bfs_order): Likewise.
16684         * df-core.c (loop_post_order_compute): Likewise.
16685         (loop_inverted_post_order_compute): Likewise.
16686         * hsa-common.h: Likewise.
16687         * hsa-gen.c (hsa_bb::~hsa_bb): Likewise.
16688         * init-regs.c (initialize_uninitialized_regs): Likewise.
16689         * ipa-inline.c (resolve_noninline_speculation): Likewise.
16690         (inline_small_functions): Likewise.
16691         * ipa-reference.c (ipa_reference_write_optimization_summary): Likewise.
16692         * ira.c (combine_and_move_insns): Likewise.
16693         (build_insn_chain): Likewise.
16694         * loop-invariant.c (find_invariants): Likewise.
16695         * lower-subreg.c (propagate_pseudo_copies): Likewise.
16696         * predict.c (tree_predict_by_opcode): Likewise.
16697         (predict_paths_leading_to): Likewise.
16698         (predict_paths_leading_to_edge): Likewise.
16699         (estimate_loops_at_level): Likewise.
16700         (estimate_loops): Likewise.
16701         * shrink-wrap.c (try_shrink_wrapping): Likewise.
16702         (spread_components): Likewise.
16703         * tree-cfg.c (remove_edge_and_dominated_blocks): Likewise.
16704         * tree-loop-distribution.c (rdg_build_partitions): Likewise.
16705         * tree-predcom.c (tree_predictive_commoning_loop): Likewise.
16706         * tree-ssa-coalesce.c (coalesce_ssa_name): Likewise.
16707         * tree-ssa-phionlycprop.c (pass_phi_only_cprop::execute): Likewise.
16708         * tree-ssa-pre.c (remove_dead_inserted_code): Likewise.
16709         * tree-ssa-sink.c (nearest_common_dominator_of_uses): Likewise.
16710         * tree-ssa-threadupdate.c (compute_path_counts): Likewise.
16711         (mark_threaded_blocks): Likewise.
16712         (thread_through_all_blocks): Likewise.
16713         * tree-ssa.c (verify_ssa): Likewise.
16714         (execute_update_addresses_taken): Likewise.
16715         * tree-ssanames.c (verify_ssaname_freelists): Likewise.
16717 2017-05-13  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
16719         * cfganal.c (mark_dfs_back_edges): Replace manual stack with
16720         auto_vec.
16721         (post_order_compute): Likewise.
16722         (inverted_post_order_compute): Likewise.
16723         (pre_and_rev_post_order_compute_fn): Likewise.
16725 2017-05-13  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
16727         * genrecog.c (int_set::int_set): Explicitly construct our
16728         auto_vec base class.
16729         * vec.h (auto_vec::auto_vec): New constructor.
16731 2017-05-13  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
16733         * bitmap.h (class auto_bitmap): New constructor taking
16734         bitmap_obstack * argument.
16736 2017-05-13  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
16738         * bitmap.h (class auto_bitmap): Change type of m_bits to
16739         bitmap_head, and adjust ctor / dtor and member operators.
16741 2017-05-13  Uros Bizjak  <ubizjak@gmail.com>
16743         * compare-elim.c (equivalent_reg_at_start): Return NULL_RTX
16744         when returned register mode doesn't match original mode.
16746 2017-05-12  Jeff Law  <law@redhat.com>
16747             Jakub Jelinek  <jakub@redhat.com>
16749         * config/mn10300/mn10300.c (mn10300_match_ccmode): Fix where
16750         we look for cc setter after the compare-elim changes.
16751         * config/mn10300/mn10300.md (addsi3_flags): Fix order of patterns
16752         within the vector to match what compare-elim now expects.
16753         (subsi3_flags, andsi3_flags, iorsi3_flags): Likewise.
16754         (xorsi3_flags, one_cmplsi2_flags): Likewise.
16756         * config/rx/rx.c (rx_match_ccmode): Fix where we look cc setter
16757         after the compare-elim changes.
16758         * config/rx/rx.md (abssi2_flags): Fix order of patterns within
16759         the vector to match what compare-elim now expects.
16760         (addsi3_flags, adc_flags, addsi3_flags peepholes): Likewise.
16761         (andsi3_flags, negsi2_flags, one_cmplsi2_flags): Likewise.
16762         (iorsi3_flags, rotlsi3_flags, rotrsi3_flags): Likewise.
16763         (ashrsi3_flags, lshrsi3_flags, ashlsi3_flags): Likewise.
16764         (ssaddsi3, subsi3_flags, sbb_flags, xorsi3_flags): Likewise.
16766         * config/visium/visium.c (single_set_and_flags): Fix where
16767         we look for cc setter after the compare-elim changes.
16768         * config/visium/visium.md (flags_subst_logic): Fix order of patterns
16769         with the vector to match what compare-elim now expects.
16770         (flags_subst_arith, add<mode>3_insn_set_carry): Likewise.
16771         (add<mode>3_insn_set_overflow, addsi3_insn_set_carry): Likewise.
16772         (addsi3_insn_set_overflow, sub<mode>3_insn_set_carry): Likewise.
16773         (sub<mode>3_insn_set_overflow, subsi3_insn_set_carry): Likewise.
16774         (subsi3_insn_set_overflow, negsi2_insn_set_carry): Likewise.
16775         (neg<mode>2_insn_set_overflow): Likewise.
16777 2017-05-12  Jim Wilson  <jim.wilson@linaro.org>
16779         PR middle-end/79794
16780         * expmed.c (extract_bit_field_1): Add alt_rtl argument.  Before
16781         maybe_expand_insn call, set ops[0].target.  If still set after call,
16782         set alt_rtl.  Add extra arg to recursive calls.
16783         (extract_bit_field): Add alt_rtl argument.  Pass to
16784         extract_bit_field.
16785         * expmed.h (extract_bit_field): Fix prototype.
16786         * expr.c (emit_group_load_1, copy_blkmode_from_reg)
16787         (copy_blkmode_to_reg, read_complex_part, store_field): Pass extra NULL
16788         to extract_bit_field_calls.
16789         (expand_expr_real_1): Pass alt_rtl to expand_expr_real instead of 0.
16790         Pass alt_rtl to extract_bit_field calls.
16791         * calls.c (store_unaligned_arguments_into_psuedos)
16792         load_register_parameters): Pass extra NULL to extract_bit_field calls.
16793         * optabs.c (maybe_legitimize_operand): Clear op->target when call
16794         gen_reg_rtx.
16795         * optabs.h (struct expand_operand): Add target bitfield.
16797 2017-05-12  Uros Bizjak  <ubizjak@gmail.com>
16799         * compare-elim.c (try_eliminate_compare): Canonicalize
16800         operation with embedded compare to
16801         [(set (reg:CCM) (compare:CCM (operation) (immediate)))
16802          (set (reg) (operation)].
16804         * config/i386/i386.c (TARGET_FLAGS_REGNUM): New define.
16806 2017-05-12  Uros Bizjak  <ubizjak@gmail.com>
16808         PR target/80723
16809         * config/i386/i386.c (ix86_rtx_cost) [case PLUS]: Ignore the
16810         cost of adding a carry flag for ADC instruction.
16811         [case MINUS]: Ignore the cost of subtracting a carry flag
16812         for SBB instruction.
16814 2017-05-12  Steven Munroe  <munroesj@gcc.gnu.org>
16816         * config.gcc (powerpc*-*-*): Add bmi2intrin.h, bmiintrin.h,
16817         and x86intrin.h
16818         * config/rs6000/bmiintrin.h: New file.
16819         * config/rs6000/bmi2intrin.h: New file.
16820         * config/rs6000/x86intrin.h: New file.
16822 2017-05-12  Jeff Law  <law@redhat.com>
16824         * tree-vrp.c (vrp_dom_walker::before_dom_children): Push unwinding
16825         markers.
16827 2017-05-12  Peter Bergner  <bergner@vnet.ibm.com>
16829         PR middle-end/80707
16830         * tree-cfg.c: Remove cfg edges of unreachable case statements.
16832 2017-05-12  Will Schmidt  <will_schmidt@vnet.ibm.com>
16834         * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Add handling for
16835         early expansion of vector divide builtins.
16836         (builtin_function_type): Add VSX_BUILTIN_UDIV_V2DI to the list of
16837         builtins identified as having unsigned arguments.
16839 2017-05-12  Will Schmidt  <will_schmidt@vnet.ibm.com>
16841         * config/rs6000/rs6000.c (gimple-fold.h): New #include.
16842         (rs6000_gimple_fold_builtin): Add handling for early GIMPLE
16843         expansion of vector logical operations (and, andc, or, xor,
16844         nor, orc, nand).
16846 2017-05-12  Will Schmidt  <will_schmidt@vnet.ibm.com>
16848         * gimple-fold.c (create_tmp_reg_or_ssa_name): Remove static declaration.
16849         * gimple-fold.h (create_tmp_reg_or_ssa_name): New prototype.
16851 2017-05-12  Will Schmidt  <will_schmidt@vnet.ibm.com>
16853         * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Add handling for
16854         early GIMPLE expansion of vector multiplies.
16856 2017-05-12  Prakhar Bahuguna  <prakhar.bahuguna@arm.com>
16858         * config/arm/arm.md (movsi): Add TARGET_32BIT in addition to the
16859         TARGET_HAVE_MOVT conditional.
16860         (movt splitter): Likewise.
16862 2017-05-12  Richard Biener  <rguenther@suse.de>
16864         * tree-ssa-sccvn.h (has_VN_INFO): Declare.
16865         * tree-ssa-pre.c (eliminate_dom_walker::before_dom_children):
16866         Fold all stmts not inplace.
16868 2017-05-12  Richard Biener  <rguenther@suse.de>
16870         PR tree-optimization/80713
16871         * tree-ssa-pre.c (remove_dead_inserted_code): Clear
16872         inserted_exprs bit for not removed stmts.
16874 2017-05-12  Thomas Schwinge  <thomas@codesourcery.com>
16876         PR middle-end/69921
16877         * tree-parloops.c (create_parallel_loop): Set "oacc kernels
16878         parallelized" attribute for parallelized OpenACC kernels.
16879         * omp-offload.c (execute_oacc_device_lower): Use it.
16881         * omp-expand.c (expand_omp_target) <GF_OMP_TARGET_KIND_OACC_KERNELS>:
16882         Set "oacc kernels" attribute.
16883         * omp-general.c (oacc_set_fn_attrib): Remove is_kernel formal
16884         parameter.  Adjust all users.
16885         (oacc_fn_attrib_kernels_p): Remove function.
16886         * omp-offload.c (execute_oacc_device_lower): Look for "oacc
16887         kernels" attribute instead of calling oacc_fn_attrib_kernels_p.
16888         * tree-ssa-loop.c (gate_oacc_kernels): Likewise.
16889         * tree-parloops.c (create_parallel_loop): If oacc_kernels_p,
16890         assert "oacc kernels" attribute is set.
16892 2017-05-11  Carl Love  <cel@us.ibm.com>
16894         * config/rs6000/rs6000-c: Add support for built-in functions
16895         vector unsigned char vec_popcnt (vector signed char)
16896         vector unsigned char vec_popcnt (vector unsigned char)
16897         vector unsigned short vec_popcnt (vector signed short)
16898         vector unsigned short vec_popcnt (vector unsigned short)
16899         vector unsigned int vec_popcnt (vector signed int)
16900         vector unsigned int vec_popcnt (vector unsigned int)
16901         vector unsigned long long vec_popcnt (vector signed long long)
16902         vector unsigned long long vec_popcnt (vector unsigned long long)
16903         vector signed long long vec_slo (vector signed long long,
16904                                          vector signed char)
16905         vector signed long long vec_slo (vector signed long long,
16906                                          vector unsigned char)
16907         vector unsigned long long vec_slo (vector unsigned long long,
16908                                            vector signed char)
16909         vector unsigned long long vec_slo (vector unsigned long long,
16910                                            vector unsigned char)
16911         * config/rs6000/rs6000-builtin.def: Add definitions for VPOPCNTUB,
16912         VPOPCNTUH, VPOPCNTUW, and VPOPCNTUD overloads.
16913         * config/rs6000/altivec.h: Add define for vec_popcnt, vec_popcntb,
16914         vec_popcnth, vec_popcntw and vec_popcntd built-in functions.
16915         * doc/extend.texi: Update the built-in documentation file for the
16916         new built-in functions.
16918 2017-05-11  Michael Meissner  <meissner@linux.vnet.ibm.com>
16920         * attribs.h (sorted_attr_string): Move machine independent
16921         functions for target clone support from the i386 port to common
16922         code.  Rename ix86_function_versions to common_function_versions.
16923         Rename make_name to make_unique_name.
16924         (common_function_versions): Likewise.
16925         (make_unique_name): Likewise.
16926         (make_dispatcher_decl): Likewise.
16927         (is_function_default_version): Likewise.
16928         * attribs.c (attr_strcmp): Likewise.
16929         (sorted_attr_string): Likewise.
16930         (common_function_versions): Likewise.
16931         (make_unique_name): Likewise.
16932         (make_dispatcher_decl): Likewise.
16933         (is_function_default_version): Likewise.
16934         * config/i386/i386.c (attr_strcmp): Likewise.
16935         (sorted_attr_string): Likewise.
16936         (ix86_function_versions): Likewise.
16937         (make_name): Likewise.
16938         (make_dispatcher_decl): Likewise.
16939         (is_function_default_version): Likewise.
16940         (TARGET_OPTION_FUNCTION_VERSIONS): Update target function hook.
16942 2017-05-11  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
16944         PR target/80695
16945         * config/rs6000/rs6000.c (rs6000_builtin_vectorization_cost):
16946         Account for direct move costs for vec_construct of integer
16947         vectors.
16949 2017-05-11  Uros Bizjak  <ubizjak@gmail.com>
16951         PR target/80706
16952         * config/i386/sync.md (UNSPEC_LDX_ATOMIC): New unspec.
16953         (UNSPEC_STX_ATOMIC): Ditto.
16954         (loaddi_via_sse): New insn.
16955         (storedi_via_sse): Ditto.
16956         (atomic_loaddi_fpu): Emit loaddi_via_sse and storedi_via_sse.
16957         Update corresponding peephole2 patterns.
16958         (atomic_storedi_fpu): Ditto.
16960 2017-05-11  Julia Koval  <julia.koval@intel.com>
16962         * config/i386/avx512fintrin.h (_mm_mask_rsqrt14_sd)
16963         (_mm_maskz_rsqrt14_sd, _mm_mask_rsqrt14_ss, _mm_maskz_rsqrt14_ss):
16964         New intrinsics.
16965         * config/i386/i386-builtin.def (__builtin_ia32_rsqrt14sd_mask)
16966         (__builtin_ia32_rsqrt14ss_mask): New builtins.
16967         * config/i386/sse.md (rsqrt14_<mode>_mask): New pattern.
16969 2017-05-11  Nathan Sidwell  <nathan@acm.org>
16971         * graphite-poly.c: Include dumpfile.h.
16973         * dumpfle.h (dump_function): Declare here ...
16974         * tree-dump.h (dump_function): ... not here.
16975         * dumpfile.c: #include tree-cfg.h.
16976         (dump_function): Move here from ...
16977         * tree-dump.c (dump_function): ... here.
16978         * gimplify.c: #include splay-tree.h, not tree-dump.h.
16979         * graphite-poly.c: Don't include tree-dump.h.
16980         * cgraphclones.c: Include dumpfile.h not tree-dump.h.
16981         * print-tree.c: Likewise.
16982         * stor-layout.c: Likewise.
16983         * tree-nested.c: Likewise.
16985         * dumpfile.c (dump_start): Use TDF_FLAGS.
16986         (dump_enable_all): Fix TDF_KIND check thinko.
16988 2017-05-11  Kelvin Nilsen  <kelvin@gcc.gnu.org>
16990         * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Add
16991         array entries to represent two legal parameterizations of the
16992         overloaded __builtin_cmpb function, as represented by the
16993         P6_OV_BUILTIN_CMPB constant.
16994         (altivec_resolve_overloaded_builtin): Add special case handling
16995         for the __builtin_cmpb function, as represented by the
16996         P6_OV_BUILTIN_CMPB constant.
16997         * config/rs6000/rs6000-builtin.def (BU_P6_2): New macro.
16998         (BU_P6_64BIT_2): New macro.
16999         (BU_P6_OVERLOAD_2): New macro
17000         (CMPB_32): Add 32-bit compare-bytes support for 32-bit only targets.
17001         (CMPB): Add 64-bit compare-bytes support for 32-bit and 64-bit targets.
17002         (CMPB): Add overload support to represent both 32-bit and 64-bit
17003         compare-bytes function.
17004         * config/rs6000/rs6000.c (rs6000_builtin_mask_calculate): Add
17005         support for TARGET_CMPB.
17006         * config/rs6000/rs6000.h: Add support for RS6000_BTM_CMPB.
17007         * doc/extend.texi (PowerPC AltiVec Built-in Functions): Add
17008         documentation of the __builtin_cmpb overloaded built-in function.
17010 2017-05-11  Richard Biener  <rguenther@suse.de>
17012         PR tree-optimization/80705
17013         * tree-vect-data-refs.c (vect_analyze_data_refs): DECL_NONALIASED
17014         bases are not vectorizable.
17016 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
17018         * tree-ssa-loop-ivopts.c (determine_set_costs): Skip non-interger
17019         when counting register pressure.
17021 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
17023         * tree-ssa-loop-ivopts.c (compare_cost_pair): New.
17024         (iv_ca_more_deps): Renamed to ...
17025         (iv_ca_compare_deps): ... this.
17026         (iv_ca_extend): Extend iv_ca if NEW_CP is cheaper than OLD_CP.
17028 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
17030         * tree-ssa-loop-ivopts.c (find_interesting_uses): Move inv vars dump
17031         to ...
17032         (determine_group_iv_costs): ... here.
17033         (find_inv_vars_cb): Record inv var if it's not recorded before.
17035 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
17037         * tree-ssa-loop-ivopts.c (allow_ip_end_pos_p): Refine comments.
17038         (get_shiftadd_cost): Ditto.
17040 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
17042         * tree-ssa-address.c: Include header file.
17043         (move_hint_to_base): Return TRUE if BASE_HINT is moved to memory
17044         address.
17045         (add_to_parts): Refactor.
17046         (addr_to_parts): New parameter.  Update use of move_hint_to_base.
17047         (create_mem_ref): Update use of addr_to_parts.  Re-associate addr
17048         in new order.
17050 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
17052         PR tree-optimization/53090
17053         * tree-ssa-loop-ivopts.c (enum comp_iv_rewrite): New enum value
17054         COMP_IV_EXPR_2.
17055         (extract_cond_operands): Detect condition with IV on both sides
17056         and return COMP_IV_EXPR_2.
17057         (find_interesting_uses_cond): Add iv_use for both IVs in condition.
17058         (rewrite_use_compare): Simplify by removing call to function
17059         extract_cond_operands.
17061 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
17063         * tree-ssa-loop-ivopts.c (enum comp_iv_rewrite): New.
17064         (extract_cond_operands): Detect condition comparing against non-
17065         invariant bound and return appropriate enum value.
17066         (find_interesting_uses_cond): Update use of extract_cond_operands.
17067         Handle its return value accordingly.
17068         (determine_group_iv_cost_cond, rewrite_use_compare): Ditto.
17070 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
17072         * tree-ssa-loop-ivopts.c (rewrite_use_nonlinear_expr): Re-associate
17073         nonlinear iv_use computation in loop invariant sensitive way.
17075 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
17077         * tree-ssa-loop-ivopts.c (relate_compare_use_with_all_cands): New.
17078         (find_iv_candidates): Call relate_compare_use_with_all_cands.
17080 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
17082         * tree-ssa-loop-ivopts.c (struct iv_cand): New field inv_exprs.
17083         (dump_cand): Support iv_cand.inv_exprs.
17084         (add_candidate_1): Record invariant exprs in iv_cand.inv_exprs
17085         for candidates.
17086         (iv_ca_set_no_cp, iv_ca_set_cp, free_loop_data): Support
17087         iv_cand.inv_exprs.
17089 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
17091         * tree-ssa-loop-ivopts.c (multiplier_allowed_in_address_p): Move
17092         from ...
17093         * tree-ssa-address.c (multiplier_allowed_in_address_p): ... to here
17094         as local function.  Include necessary header files.
17095         * tree-ssa-loop-ivopts.h (multiplier_allowed_in_address_p): Delete.
17097 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
17099         * tree-ssa-loop-ivopts.c (autoinc_possible_for_pair): Simplify.
17101 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
17103         * tree-ssa-loop-ivopts.c (force_expr_to_var_cost): Handle more
17104         operators: TRUNC_DIV_EXPR, BIT_AND_EXPR, BIT_IOR_EXPR, LSHIFT_EXPR,
17105         RSHIFT_EXPR and BIT_NOT_EXPR.
17107 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
17109         * tree-ssa-loop-ivopts.c (get_loop_invariant_expr): Simplify.
17110         (adjust_setup_cost): New parameter supporting round up adjustment.
17111         (struct address_cost_data): Delete.
17112         (force_expr_to_var_cost): Don't bound cost with spill_cost.
17113         (split_address_cost, ptr_difference_cost): Delete.
17114         (difference_cost, compare_aff_trees, record_inv_expr): Delete.
17115         (struct ainc_cost_data): New struct.
17116         (get_address_cost_ainc): New function.
17117         (get_address_cost, get_computation_cost): Reimplement.
17118         (determine_group_iv_cost_address): Record inv_expr for all uses of
17119         a group.
17120         (determine_group_iv_cost_cond): Call get_loop_invariant_expr.
17121         (iv_ca_has_deps): Reimplemented to ...
17122         (iv_ca_more_deps): ... this.  Check if NEW_CP introduces more deps
17123         than OLD_CP.
17124         (iv_ca_extend): Call iv_ca_more_deps.
17126 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
17128         * tree-ssa-address.c (struct mem_address): Move to header file.
17129         (valid_mem_ref_p, move_fixed_address_to_symbol): Make it global.
17130         * tree-ssa-address.h (struct mem_address): Move from C file.
17131         (valid_mem_ref_p, move_fixed_address_to_symbol): Declare.
17133 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
17135         * tree-affine.h (aff_combination_type): New interface.
17136         (aff_combination_zero_p): Remove static.
17137         (aff_combination_const_p): New interface.
17138         (aff_combination_singleton_var_p): New interfaces.
17140 2017-05-11  Richard Biener  <rguenther@suse.de>
17142         * tree-ssa-pre.c (eliminate_dom_walker::before_dom_children):
17143         Skip unreachable blocks and destinations.
17144         (eliminate): Move stmt removal and fixup ...
17145         (fini_eliminate): ... here.  Skip inserted exprs.
17146         (pass_pre::execute): Move fini_pre after fini_eliminate.
17147         * tree-ssa-tailmerge.c: Include tree-cfgcleanup.h.
17148         (tail_merge_optimize): Run cleanup_tree_cfg if requested by
17149         PRE to get rid of dead code that has invalid SSA form and
17150         split critical edges again.
17152 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
17154         * rtlanal.c (rtx_cost): Handle TRUNCATE between tieable modes.
17156 2017-05-11  Richard Biener  <rguenther@suse.de>
17158         * passes.c (execute_function_todo): Verify loops if they are
17159         said to be up-to-date.
17160         * cfgexpand.c (pass_expand::execute): Discard loops for -dx.
17161         * trans-mem.c (pass_tm_edges::execute): Mark loops for fixup.
17163 2017-05-10  John David Anglin  <danglin@gcc.gnu.org>
17165         PR target/80090
17166         * config/pa/pa.c (pa_assemble_integer): When outputting a SYMBOL_REF,
17167         handle calling assemble_external ourself.
17169         PR target/79027
17170         * config/pa/pa.c (pa_cannot_change_mode_class): Reject changes to/from
17171         modes with zero size.  Enhance comment.
17173 2017-05-10  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
17175         * config/rs6000/rs6000.c (altivec_init_builtins): Define POWER8
17176         built-ins for vec_xl and vec_xst with short and char pointer
17177         arguments.
17179 2017-05-10  Sebastian Peryt  <sebastian.peryt@intel.com>
17181         * config/i386/avx512fintrin.h (_mm_mask_max_round_sd)
17182         (_mm_maskz_max_round_sd, _mm_mask_max_round_ss)
17183         (_mm_maskz_max_round_ss, _mm_mask_min_round_sd)
17184         (_mm_maskz_min_round_sd, _mm_mask_min_round_ss)
17185         (_mm_maskz_min_round_ss): New intrinsics.
17186         * config/i386/i386-builtin-types.def (V2DF, V2DF, V2DF, V2DF, UQI, INT)
17187         (V4SF, V4SF, V4SF, V4SF, UQI, INT): New function type aliases.
17188         * config/i386/i386-builtin.def (__builtin_ia32_maxsd_mask_round)
17189         (__builtin_ia32_maxss_mask_round, __builtin_ia32_minsd_mask_round)
17190         (__builtin_ia32_minss_mask_round): New builtins.
17191         * config/i386/i386.c (V2DF_FTYPE_V2DF_V2DF_V2DF_UQI_INT)
17192         (V4SF_FTYPE_V4SF_V4SF_V4SF_UQI_INT): Handle new types.
17193         * config/i386/sse.md (<sse>_vm<code><mode>3<round_saeonly_name>):
17194         Rename to ...
17195         (<sse>_vm<code><mode>3<mask_name><round_saeonly_name>): ... this.
17196         (v<maxmin_float><ssescalarmodesuffix>\t{<round_saeonly_op3>%2, %1, %0|%0, %1, %<iptr>2<round_saeonly_op3>}):
17197         Change to ...
17198         (v<maxmin_float><ssescalarmodesuffix>\t{<round_saeonly_mask_op3>%2, %1, %0<mask_operand3>|%0<mask_operand3>, %1, %<iptr>2<round_saeonly_mask_op3>}):
17199         ... this.
17201 2017-05-10  Sebastian Peryt  <sebastian.peryt@intel.com>
17203         * config/i386/avx512fintrin.h (_mm_mask_mul_round_sd)
17204         (_mm_maskz_mul_round_sd, _mm_mask_mul_round_ss)
17205         (_mm_maskz_mul_round_ss, _mm_mask_div_round_sd)
17206         (_mm_maskz_div_round_sd, _mm_mask_div_round_ss)
17207         (_mm_maskz_div_round_ss, _mm_mask_mul_sd, _mm_maskz_mul_sd)
17208         (_mm_mask_mul_ss, _mm_maskz_mul_ss, _mm_mask_div_sd)
17209         (_mm_maskz_div_sd, _mm_mask_div_ss, _mm_maskz_div_ss): New intrinsics.
17210         * config/i386/i386-builtin-types.def (V2DF_FTYPE_V2DF_V2DF_V2DF_UQI_INT)
17211         (V4SF_FTYPE_V4SF_V4SF_V4SF_UQI_INT): New function type aliases.
17212         * config/i386/i386-builtin.def (__builtin_ia32_divsd_mask_round)
17213         (__builtin_ia32_divss_mask_round, __builtin_ia32_mulsd_mask_round)
17214         (__builtin_ia32_mulss_mask_round): New builtins.
17215         * config/i386/i386.c (V2DF_FTYPE_V2DF_V2DF_V2DF_UQI_INT)
17216         (V4SF_FTYPE_V4SF_V4SF_V4SF_UQI_INT): Handle new types.
17217         * config/i386/sse.md (<sse>_vm<multdiv_mnemonic><mode>3<round_name>):
17218         Rename to ...
17219         (<sse>_vm<multdiv_mnemonic><mode>3<mask_name><round_name>): ... this.
17220         (v<multdiv_mnemonic><ssescalarmodesuffix>\t{<round_op3>%2, %1, %0|%0, %1, %<iptr>2<round_op3>}):
17221         Change to ...
17222         (v<multdiv_mnemonic><ssescalarmodesuffix>\t{<round_mask_op3>%2, %1, %0<mask_operand3>|%0<mask_operand3>, %1, %<iptr>2<round_mask_op3>}):
17223         ... this.
17225 2017-05-10  Julia Koval  <julia.koval@intel.com>
17227         * config/i386/avxintrin.h (_mm256_set_m128, _mm256_set_m128d)
17228         (_mm256_set_m128i, _mm256_setr_m128, _mm256_setr_m128d)
17229         (_mm256_setr_m128i): New intrinsics.
17231 2017-05-10  Julia Koval  <julia.koval@intel.com>
17233         * config/i386/avx512fintrin.h (_mm_mask_rcp14_sd)
17234         (_mm_maskz_rcp14_sd, _mm_mask_rcp14_ss)
17235         (_mm_maskz_rcp14_ss): New intrinsics.
17236         * config/i386/i386-builtin.def (__builtin_ia32_rcp14sd_mask)
17237         (__builtin_ia32_rcp14ss_mask): New builtins.
17238         * config/i386/sse.md (srcp14<mode>_mask): New pattern.
17240 2017-05-10  Peter Bergner  <bergner@vnet.ibm.com>
17242         PR tree-optimization/51513
17243         * tree-cfg.c (gimple_seq_unreachable_p): New function.
17244         (assert_unreachable_fallthru_edge_p): Use it.
17245         (group_case_labels_stmt): Likewise.
17246         * tree-cfg.h: Prototype it.
17247         * stmt.c: Include cfghooks.h and tree-cfg.h.
17248         (emit_case_dispatch_table) <gap_label>: New local variable.
17249         Use it to fill dispatch table gaps.
17250         Test for default_label before updating probabilities.
17251         (expand_case) <default_label>: Remove unneeded initialization.
17252         Test for unreachable default case statement and remove its edge.
17253         Set default_label accordingly.
17254         * tree-ssa-ccp.c (optimize_unreachable): Update comment.
17256 2017-05-10  Carl Love  <cel@us.ibm.com>
17258         * config/rs6000/rs6000-c: Add support for built-in functions
17259         vector signed char      vec_neg (vector signed char)
17260         vector signed short int vec_neg (vector short int)
17261         vector signed int       vec_neg (vector signed int)
17262         vector signed long long vec_neg (vector signed long long)
17263         vector float            vec_neg (vector float)
17264         vector double           vec_neg (vector double)
17265         * config/rs6000/rs6000-builtin.def: Add definitions for NEG function
17266         overload.
17267         * config/rs6000/altivec.h: Add define for vec_neg
17268         * doc/extend.texi: Update the built-in documentation for the
17269         new built-in functions.
17271 2017-05-10  Prathamesh Kulkarni  <prathamesh.kulkarni@linaro.org>
17273         PR tree-optimization/77644
17274         * match.pd (sqrt(x) cmp sqrt(y) -> x cmp y): New pattern.
17276 2017-05-10  Nathan Sidwell  <nathan@acm.org>
17278         * dumpfile.h (TDI_lang_all): New.
17279         (TDF_KIND): New. Renumber others
17280         (TDF_LANG, TDF_TREE, TDF_RTL, TDF_IPA): Enumerate value, rather
17281         than bits.
17282         * dumpfile.c (dump_files): Mark language dumps as TDF_LANG.  add
17283         lang-all.
17284         (get_dump_file_name): Adjust suffix generation.
17285         (dump_enable_all): Use TDF_KIND.
17286         * doc/invoke.texi (-fdump-lang-all): Document.
17288         * dumpfile.h: Tabify.
17290 2017-05-10  Wilco Dijkstra  <wdijkstr@arm.com>
17292         PR target/80671
17293         * config/aarch64/cortex-a57-fma-steering.c (merge_forest):
17294         Move member access before delete.
17296 2017-05-10  Alexandre Oliva <aoliva@redhat.com>
17298         * tree-inline.c (expand_call_inline): Split block at stmt
17299         before the call.
17301 2017-05-09  Michael Meissner  <meissner@linux.vnet.ibm.com>
17303         PR target/68163
17304         * config/rs6000/rs6000.md (f32_lr): Delete mode attributes that
17305         are now unused after splitting mov{sf,sd}_hardfloat.
17306         (f32_lr2): Likewise.
17307         (f32_lm): Likewise.
17308         (f32_lm2): Likewise.
17309         (f32_li): Likewise.
17310         (f32_li2): Likewise.
17311         (f32_lv): Likewise.
17312         (f32_sr): Likewise.
17313         (f32_sr2): Likewise.
17314         (f32_sm): Likewise.
17315         (f32_sm2): Likewise.
17316         (f32_si): Likewise.
17317         (f32_si2): Likewise.
17318         (f32_sv): Likewise.
17319         (f32_dm): Likewise.
17320         (f32_vsx): Likewise.
17321         (f32_av): Likewise.
17322         (mov<mode>_hardfloat): Split into separate movsf and movsd pieces.
17323         For movsf, order stores so the VSX stores occur before the GPR
17324         store which encourages the register allocator to use a traditional
17325         FPR instead of a GPR.  For movsd, order the stores so that the GPR
17326         store comes before the VSX stores to allow the power6 to work.
17327         This is due to the power6 not having a 32-bit integer store
17328         instruction from a FPR.
17329         (movsf_hardfloat): Likewise.
17330         (movsd_hardfloat): Likewise.
17332 2017-05-09  Martin Sebor  <msebor@redhat.com>
17334         PR translation/80280
17335         * config/sol2-c.c (cmn_err_flag_specs): Initialize new data member
17336         added in r247778.
17338         PR translation/80280
17339         * config/i386/msformat-c.c (ms_printf_flag_specs): Initialize new
17340         data member added in r247778.
17341         (ms_scanf_flag_specs, ms_strftime_flag_specs): Same.
17343 2017-05-09  Nathan Sidwell  <nathan@acm.org>
17345         * tree.h (tree_fits_shwi_p, tree_fits_uhwi_p): Unconditionally pure.
17347         * ipa-devirt.c (default_hash_traits<type_pair>): Skip struct-scope
17348         typedefs.
17350 2017-05-09  Marek Polacek  <polacek@redhat.com>
17352         * doc/invoke.texi: Fix typo.
17354 2017-05-09  Richard Biener  <rguenther@suse.de>
17356         * tree-vrp.c (vrp_val_is_max): Adjust comment.
17357         (vrp_val_is_min): Likewise.
17358         (set_value_range_to_value): Likewise.
17359         (set_value_range_to_nonnegative): Likewise.
17360         (gimple_assign_nonzero_p): Likewise.
17361         (gimple_stmt_nonzero_p): Likewise.
17362         (vrp_int_const_binop): Likewise.  Remove unreachable case.
17363         (adjust_range_with_scev): Adjust comments.
17364         (compare_range_with_value): Likewise.
17365         (extract_range_from_phi_node): Likewise.
17366         (test_for_singularity): Likewise.
17368 2017-05-09  Richard Biener  <rguenther@suse.de>
17370         * tree-vrp.c (get_single_symbol): Add assert that we don't
17371         get overflowed constants as invariant part.
17372         (compare_values_warnv): Add comment before the TREE_NO_WARNING
17373         checks.  Use wi::cmp instead of recursing for integer constants.
17374         (compare_values): Just ignore whether we assumed undefined
17375         overflow instead of failing the compare.
17376         (extract_range_for_var_from_comparison_expr): Add comment before the
17377         TREE_NO_WARNING sets.
17378         (test_for_singularity): Likewise.
17379         (extract_range_from_comparison): Do not disable optimization
17380         when we assumed undefined overflow.
17381         (extract_range_basic): Remove init of unused var.
17383 2017-05-09  Richard Biener  <rguenther@suse.de>
17385         * tree-vrp.c (vrp_int_const_binop): Use wide-ints and simplify.
17386         (extract_range_from_multiplicative_op_1): Adjust.
17387         (extract_range_from_binary_expr_1): Use int_const_binop.
17389 2017-05-08  Kelvin Nilsen  <kelvin@gcc.gnu.org>
17391         PR target/80101
17392         * config/rs6000/power6.md: Replace store_data_bypass_p calls with
17393         rs6000_store_data_bypass_p in seven define_bypass directives and
17394         in several comments.
17395         * config/rs6000/rs6000-protos.h: Add prototype for
17396         rs6000_store_data_bypass_p function.
17397         * config/rs6000/rs6000.c (rs6000_store_data_bypass_p): New
17398         function implements slightly different (rs6000-specific) semantics
17399         than store_data_bypass_p, returning false rather than aborting
17400         with assertion error when arguments do not satisfy the
17401         requirements of store data bypass.
17402         (rs6000_adjust_cost): Replace six calls of store_data_bypass_p with
17403         rs6000_store_data_bypass_p.
17405 2017-05-08  Max Filippov  <jcmvbkbc@gmail.com>
17407         * config/xtensa/xtensa-protos.h
17408         (xtensa_initial_elimination_offset): New declaration.
17409         * config/xtensa/xtensa.c (xtensa_initial_elimination_offset):
17410         New function. Move its body from the INITIAL_ELIMINATION_OFFSET
17411         macro definition, add case for FRAME_POINTER_REGNUM when
17412         FRAME_GROWS_DOWNWARD.
17413         * config/xtensa/xtensa.h (FRAME_GROWS_DOWNWARD): New macro definition.
17414         (INITIAL_ELIMINATION_OFFSET): Replace body with call to
17415         xtensa_initial_elimination_offset.
17417 2017-05-08  Nathan Sidwell  <nathan@acm.org>
17419         * doc/invoke.texi: Alphabetize -fdump options.
17421 2017-05-08  Martin Sebor  <msebor@redhat.com>
17423         PR translation/80280
17424         * config/sol2-c.c (solaris_pragma_align): Correct quoting.
17426 2017-05-08  Bernd Edlinger  <bernd.edlinger@hotmail.de>
17428         * target.def (compute_frame_layout): New optional target hook.
17429         * doc/tm.texi.in (TARGET_COMPUTE_FRAME_LAYOUT): Add hook.
17430         * doc/tm.texi (TARGET_COMPUTE_FRAME_LAYOUT): Add documentation.
17431         * lra-eliminations.c (update_reg_eliminate): Call compute_frame_layout
17432         target hook.
17433         * reload1.c (verify_initial_elim_offsets): Likewise.
17434         * config/arm/arm.c (TARGET_COMPUTE_FRAME_LAYOUT): Define.
17435         (use_simple_return_p): Call arm_compute_frame_layout if needed.
17436         (arm_get_frame_offsets): Split up into this ...
17437         (arm_compute_frame_layout): ... and this function.
17439 2017-05-08  Richard Sandiford  <richard.sandiford@arm.com>
17441         * config/aarch64/constraints.md (Usa): New constraint.
17442         * config/aarch64/aarch64.md (*movsi_aarch64, *movdi_aarch64): Use it.
17444 2017-05-08  Thomas Preud'homme  <thomas.preudhomme@arm.com>
17446         * config.gcc (arm*-*-*): Set TM_MULTILIB_CONFIG from
17447         with_multilib_list after it has been checked.
17449 2017-05-08  Richard Biener  <rguenther@suse.de>
17451         * tree-ssa-pre.c (bitmap_set_and): Avoid bitmap copy.
17452         (bitmap_set_subtract_values): Likewise.
17454 2017-05-08  Richard Biener  <rguenther@suse.de>
17456         * tree-vrp.c (gimple_assign_nonzero_warnv_p): Rename to ...
17457         (gimple_assign_nonzero): ... this and remove strict_overflow_p
17458         argument.
17459         (gimple_stmt_nonzero_warnv_p): Rename to ...
17460         (gimple_stmt_nonzero_p): ... this and remove strict_overflow_p
17461         argument.
17462         (vrp_stmt_computes_nonzero): Remove strict_overflow_p argument.
17463         (extract_range_basic): Adjust, do not disable propagation on
17464         strict overflow sensitive simplification.
17465         (vrp_visit_cond_stmt): Likewise.
17467 2017-05-05  Jan Hubicka  <hubicka@ucw.cz>
17469         * ipa-inline-analysis.c (estimate_function_body_sizes): Recompute
17470         body size unconditionally.
17472 2017-05-07  Jeff Law  <law@redhat.com>
17474         Revert:
17475         2017-05-06  Jeff Law  <law@redhat.com>
17476         PR tree-optimization/78496
17477         * tree-vrp.c (simplify_assert_expr_using_ranges): Remove debugging
17478         code.
17480         PR tree-optimization/78496
17481         * tree-vrp.c (simplify_assert_expr_using_ranges): New function.
17482         (simplify_stmt_using_ranges): Call it.
17483         (vrp_dom_walker::before_dom_children): Extract equivalences
17484         from an ASSERT_EXPR with an equality comparison against a
17485         constant.
17487 2017-05-06  Jeff Law  <law@redhat.com>
17489         PR tree-optimization/78496
17490         * tree-vrp.c (simplify_assert_expr_using_ranges): Remove debugging
17491         code.
17493         PR tree-optimization/78496
17494         * tree-vrp.c (simplify_assert_expr_using_ranges): New function.
17495         (simplify_stmt_using_ranges): Call it.
17496         (vrp_dom_walker::before_dom_children): Extract equivalences
17497         from an ASSERT_EXPR with an equality comparison against a
17498         constant.
17500 2017-05-06  Richard Sandiford  <richard.sandiford@linaro.org>
17502         * lra-constraints.c (lra_copy_reg_equiv): New function.
17503         (split_reg): Use it to copy equivalence information from the
17504         original register to the spill register.
17506 2017-05-06  Richard Sandiford  <richard.sandiford@linaro.org>
17508         PR rtl-optimization/75964
17509         * simplify-rtx.c (simplify_const_relational_operation): Remove
17510         invalid handling of comparisons of integer ABS.
17512 2017-05-06  Uros Bizjak  <ubizjak@gmail.com>
17514         * config/i386/i386.c (ext_80387_constant_init): Do not explicitly
17515         initialize to zero.
17516         (init_regs): Remove declaration.
17517         (function_arg_advance_32): Initialize error_p as boolean variable.
17519 2017-05-05  Nathan Sidwell  <nathan@acm.org>
17521         * store-motion.c (remove_reachable_equiv_notes): Reformat long
17522         lines.  Use for (;;).
17524 2017-05-05  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
17526         * config/rs6000/rs6000.c (rs6000_vect_nonmem): New static var.
17527         (rs6000_init_cost): Initialize rs6000_vect_nonmem.
17528         (rs6000_add_stmt_cost): Update rs6000_vect_nonmem.
17529         (rs6000_finish_cost): Avoid vectorizing simple copy loops with
17530         VF=2 that require versioning.
17532 2017-05-05  David Malcolm  <dmalcolm@redhat.com>
17534         * diagnostic.h (CARET_LINE_MARGIN): Convert from macro to const
17535         int.
17537 2017-05-05  David Malcolm  <dmalcolm@redhat.com>
17539         * diagnostic.h (diagnostic_override_option_index): Convert from
17540         macro to inline function.
17542 2017-05-05  David Malcolm  <dmalcolm@redhat.com>
17544         * diagnostic.c (last_module_changed_p): New function.
17545         (set_last_module): New function.
17546         (diagnostic_report_current_module): Convert macro usage to
17547         the above functions.
17548         * diagnostic.h (diagnostic_context::last_module): Strengthen
17549         from const line_map * to const line_map_ordinary *.
17550         (diagnostic_last_module_changed): Delete macro.
17551         (diagnostic_set_last_module): Delete macro.
17553 2017-05-05  David Malcolm  <dmalcolm@redhat.com>
17555         * diagnostic.c (diagnostic_impl): Replace report_diagnostic
17556         with diagnostic_report_diagnostic.
17557         (diagnostic_n_impl_richloc): Likewise.
17558         * diagnostic.h (report_diagnostic): Delete macro.
17559         * rtl-error.c (diagnostic_for_asm): Replace report_diagnostic
17560         with diagnostic_report_diagnostic.
17561         * substring-locations.c (format_warning_va): Likewise.
17563 2017-05-05  David Malcolm  <dmalcolm@redhat.com>
17565         * diagnostic.c (diagnostic_report_diagnostic): Eliminate
17566         save/restor of format_spec.  Move option-printing code to...
17567         (print_option_information): ...this new function, and
17568         reimplement by simply printing to the pretty_printer,
17569         rather than appending to the format string.
17571 2017-05-05  David Malcolm  <dmalcolm@redhat.com>
17573         * diagnostic.c (diagnostic_report_diagnostic): Split out pragma
17574         handling logic into...
17575         (update_effective_level_from_pragmas): ...this new function.
17577 2017-05-04  Andrew Waterman  <andrew@sifive.com>
17579         * config/riscv/riscv.opt (mstrict-align): New option.
17580         * config/riscv/riscv.h (STRICT_ALIGNMENT): Use it.  Update comment.
17581         (SLOW_UNALIGNED_ACCESS): Define.
17582         (riscv_slow_unaligned_access): Declare.
17583         * config/riscv/riscv.c (riscv_tune_info): Add slow_unaligned_access
17584         field.
17585         (riscv_slow_unaligned_access): New variable.
17586         (rocket_tune_info): Set slow_unaligned_access to true.
17587         (optimize_size_tune_info): Set slow_unaligned_access to false.
17588         (riscv_cpu_info_table): Add entry for optimize_size_tune_info.
17589         (riscv_valid_lo_sum_p): Use TARGET_STRICT_ALIGN.
17590         (riscv_option_override): Set riscv_slow_unaligned_access.
17591         * doc/invoke.texi: Add -mstrict-align to RISC-V.
17593 2017-05-04  Kito Cheng  <kito.cheng@gmail.com>
17595         * config/riscv/riscv.md: Unify indentation.
17597 2017-05-05  Michael Meissner  <meissner@linux.vnet.ibm.com>
17599         PR target/79038
17600         PR target/79202
17601         PR target/79203
17602         * config/rs6000/rs6000.md (u code attribute): Add FIX and
17603         UNSIGNED_FIX.
17604         (extendsi<mode>2): Add support for doing sign extension via
17605         VUPKHSW and XXPERMDI if the value is in Altivec registers and we
17606         don't have ISA 3.0 instructions.
17607         (extendsi<mode>2 splitter): Likewise.
17608         (fix_trunc<mode>si2): If we are at ISA 2.07 (VSX small integer),
17609         generate the normal insns since SImode can now go in vector
17610         registers.  Disallow the special UNSPECs needed for previous
17611         machines to hide SImode being used.  Add new insns
17612         fctiw{,w}_<mode>_smallint if SImode can go in vector registers.
17613         (fix_trunc<mode>si2_stfiwx): Likewise.
17614         (fix_trunc<mode>si2_internal): Likewise.
17615         (fixuns_trunc<mode>si2): Likewise.
17616         (fixuns_trunc<mode>si2_stfiwx): Likewise.
17617         (fctiw<u>z_<mode>_smallint): Likewise.
17618         (fctiw<u>z_<mode>_mem): New combiner pattern to prevent conversion
17619         of floating point to 32-bit integer from doing a direct move to
17620         the GPR registers to do a store.
17621         (fctiwz_<mode>): Break long line.
17623 2017-05-05  Bin Cheng  <bin.cheng@arm.com>
17625         * Makefile.in (GTFILES): Add tree-ssa-loop-ivopts.c.
17626         * tree-ssa-loop-ivopts.c (compute_max_addr_offset): Delete.
17627         (addr_list, addr_offset_valid_p): New.
17628         (split_address_groups): Check offset validity with above function.
17629         (gt-tree-ssa-loop-ivopts.h): Include header file.
17631 2017-05-05  Nathan Sidwell  <nathan@acm.org>
17633         * config.gcc (arm*-*-*): Add missing 'fi'.
17635 2017-05-05  Steve Ellcey  <sellcey@cavium.com>
17637         * doc/invoke.texi (-fopt-info): Explicitly say order of options
17638         included in -fopt-info does not matter.
17639         * doc/optinfo.texi (-fopt-info): Fix description of default
17640         behavour. Explicitly say order of options included in -fopt-info
17641         does not matter.
17643 2017-05-05  Thomas Preud'homme  <thomas.preudhomme@arm.com>
17645         * config.gcc: Allow combinations of aprofile and rmprofile values for
17646         --with-multilib-list.
17647         * config/arm/t-multilib: New file.
17648         * config/arm/t-aprofile: Remove initialization of MULTILIB_*
17649         variables.  Remove setting of ISA and floating-point ABI in
17650         MULTILIB_OPTIONS and MULTILIB_DIRNAMES.  Set architecture and FPU in
17651         MULTI_ARCH_OPTS_A and MULTI_ARCH_DIRS_A rather than MULTILIB_OPTIONS
17652         and MULTILIB_DIRNAMES respectively.  Add comment to introduce all
17653         matches.  Add architecture matches for marvel-pj4 and generic-armv7-a
17654         CPU options.
17655         * config/arm/t-rmprofile: Likewise except for the matches changes.
17656         * doc/install.texi (--with-multilib-list): Document the combination of
17657         aprofile and rmprofile values and warn about pitfalls in doing that.
17659 2017-05-05  Wilco Dijkstra  <wdijkstr@arm.com>
17661         * config/aarch64/aarch64.md (movsi_aarch64): Remove '*' from r=w.
17662         (movdi_aarch64): Likewise.
17664 2017-05-05  Jakub Jelinek  <jakub@redhat.com>
17666         PR tree-optimization/80632
17667         * tree-switch-conversion.c (struct switch_conv_info): Add target_vop
17668         field.
17669         (build_arrays): Initialize it for virtual phis.
17670         (fix_phi_nodes): Use it for virtual phis.
17672         PR tree-optimization/80558
17673         * tree-vrp.c (extract_range_from_binary_expr_1): Optimize
17674         [x, y] op z into [x op, y op z] for op & or | if conditions
17675         are met.
17677 2017-05-05  Andre Vieira  <andre.simoesdiasvieira@arm.com>
17678             Prakhar Bahuguna  <prakhar.bahuguna@arm.com>
17680         PR target/71607
17681         * config/arm/arm.md (use_literal_pool): Remove.
17682         (64-bit immediate split): No longer takes cost into consideration
17683         if arm_disable_literal_pool is enabled.
17684         * config/arm/arm.c (arm_tls_referenced_p): Add diagnostic if TLS is
17685         used when arm_disable_literal_pool is enabled.
17686         (arm_max_const_double_inline_cost): Remove use of
17687         arm_disable_literal_pool.
17688         (push_minipool_fix): Add assert.
17689         (arm_reorg): Add return if arm_disable_literal_pool is enabled.
17690         * config/arm/vfp.md (no_literal_pool_df_immediate): New.
17691         (no_literal_pool_sf_immediate): New.
17693 2017-05-05  Prathamesh Kulkarni  <prathamesh.kulkarni@linaro.org>
17695         PR tree-optimization/80613
17696         * tree-ssa-dce.c (propagate_necessity): Remove cases for
17697         BUILT_IN_STRDUP and BUILT_IN_STRNDUP.
17699 2017-05-05  Richard Biener  <rguenther@suse.de>
17701         * tree-ssa-pre.c (get_or_alloc_expr_for): Simplify.
17703 2017-05-05  Georg-Johann Lay  <avr@gjlay.de>
17705         * config/avr/avr.md [flag_strict_overflow]: Remove any occurence
17706         of this flag from insn conditions due to removal from r247495.
17708 2017-05-05  Wilco Dijkstra  <wdijkstr@arm.com>
17710         * config/arm/aarch-common.c (arm_early_load_addr_dep_ptr):
17711         New function.
17712         (arm_early_store_addr_dep_ptr): Likewise.
17713         * config/arm/aarch-common-protos.h
17714         (arm_early_load_addr_dep_ptr): Add prototype.
17715         (arm_early_store_addr_dep_ptr): Likewise.
17716         * config/arm/cortex-a53.md: Add new bypasses.
17718 2017-05-05  Jakub Jelinek  <jakub@redhat.com>
17720         * tree.c (next_type_uid): Change type to unsigned.
17721         (type_hash_canon): Decrement back next_type_uid if
17722         freeing a type node with the highest TYPE_UID.  For INTEGER_TYPEs
17723         also ggc_free TYPE_MIN_VALUE, TYPE_MAX_VALUE and TYPE_CACHED_VALUES
17724         if possible.
17726 2017-05-04  Martin Sebor  <msebor@redhat.com>
17728         * builtins.c: Fix a trivial typo in a comment.
17730         PR middle-end/79234
17731         * builtins.c (check_sizes): Adjust to handle reading past the end.
17732         Avoid printing excessive upper bound of ranges.  Use %E to print
17733         tree nodes instead of converting them to %wu.
17734         (expand_builtin_memchr): New function.
17735         (compute_dest_size): Rename...
17736         (compute_objsize): ...to this.
17737         (expand_builtin_memcpy): Adjust.
17738         (expand_builtin_mempcpy): Adjust.
17739         (expand_builtin_strcat): Adjust.
17740         (expand_builtin_strcpy): Adjust.
17741         (check_strncat_sizes): Adjust.
17742         (expand_builtin_strncat): Adjust.
17743         (expand_builtin_strncpy): Adjust and simplify.
17744         (expand_builtin_memset): Adjust.
17745         (expand_builtin_bzero): Adjust.
17746         (expand_builtin_memcmp): Adjust.
17747         (expand_builtin): Handle memcmp.
17748         (maybe_emit_chk_warning): Check strncat just once.
17750 2017-05-04  Martin Sebor  <msebor@redhat.com>
17752         PR preprocessor/79214
17753         PR middle-end/79222
17754         PR middle-end/79223
17755         * builtins.c (check_sizes): Add inlining context and issue
17756         warnings even when -Wno-system-headers is set.
17757         (check_strncat_sizes): Same.
17758         (expand_builtin_strncat): Same.
17759         (expand_builtin_memmove): New function.
17760         (expand_builtin_stpncpy): Same.
17761         (expand_builtin): Handle memmove and stpncpy.
17763 2017-05-04  Bin Cheng  <bin.cheng@arm.com>
17765         * tree-ssa-loop-ivopts.c (struct cost_pair): Remove field inv_expr
17766         which is not used any more.
17768 2017-05-04  Wilco Dijkstra  <wdijkstr@arm.com>
17770         * config/aarch64/aarch64.c (generic_tunings): Update prefetch model.
17772 2017-05-04  Wilco Dijkstra  <wdijkstr@arm.com>
17774         * config/aarch64/aarch64.c (cortexa35_tunings): Set jump alignment to 4.
17775         (cortexa53_tunings): Likewise.
17776         (cortexa57_tunings): Likewise.
17777         (cortexa72_tunings): Likewise.
17778         (cortexa73_tunings): Likewise.
17780 2017-05-04  Wilco Dijkstra  <wdijkstr@arm.com>
17782         * config/aarch64/aarch64.c (generic_tunings): Set jump alignment to 4.
17783         Set loop alignment to 8.
17785 2017-05-04  Martin Sebor  <msebor@redhat.com>
17787         PR translation/80280
17788         * builtins.c (expand_builtin_object_size): Add missing quoting to
17789         %D and like directives.
17790         * hsa-gen.c (hsa_type_for_scalar_tree_type): Same.
17791         (hsa_type_for_tree_type): Same.
17792         (verify_function_arguments): Same.
17793         * symtab.c (symbol_table::change_decl_assembler_name): Same.
17794         * varasm.c (get_section): Same.
17795         (mark_weak): Same.
17797 2017-05-04  Martin Sebor  <msebor@redhat.com>
17799         PR translation/80280
17800         * config/i386/i386.c (ix86_function_versions): Quote a %D directive.
17802 2017-05-04  Wilco Dijkstra  <wdijkstr@arm.com>
17804         * config/aarch64/aarch64.c (generic_addrcost_table):
17805         Change HI/TI mode setting.
17807 2017-05-04  Martin Jambor  <mjambor@suse.cz>
17809         PR tree-optimization/80622
17810         * tree-sra.c (comes_initialized_p): New function.
17811         (build_accesses_from_assign): Only set write lazily when
17812         comes_initialized_p is false.
17813         (analyze_access_subtree): Use comes_initialized_p.
17814         (propagate_subaccesses_across_link): Assert !comes_initialized_p
17815         instead of testing for PARM_DECL.
17817 2017-05-04  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
17819         * config/aarch64/aarch64.md (prefetch); Adjust predicate and
17820         constraint on operand 0 to allow more general addressing modes.
17821         Adjust output template.
17822         * config/aarch64/aarch64.c (aarch64_address_valid_for_prefetch_p):
17823         New function.
17824         * config/aarch64/aarch64-protos.h
17825         (aarch64_address_valid_for_prefetch_p): Declare prototype.
17826         * config/aarch64/constraints.md (Dp): New address constraint.
17827         * config/aarch64/predicates.md (aarch64_prefetch_operand): New
17828         predicate.
17830 2017-05-04  Jan Hubicka  <hubicka@ucw.cz>
17832         * ipa-cp.c (perform_estimation_of_a_value): Drop base_time parameter;
17833         update use of estimate_ipcp_clone_size_and_time.
17834         (estimate_local_effects): Update use of
17835         estimate_ipcp_clone_size_and_time and perform_estimation_of_a_value.
17836         * ipa-inline.h (estimate_ipcp_clone_size_and_time): Update prototype.
17837         * ipa-inline-analysis.c (estimate_ipcp_clone_size_and_time):
17838         Return nonspecialized time.
17840 2017-05-04  Richard Biener  <rguenther@suse.de>
17842         * tree-ssa-alias.c (get_continuation_for_phi): Improve looking
17843         for the last VUSE which def dominates the PHI.  Directly call
17844         maybe_skip_until.
17845         (get_continuation_for_phi_1): Remove.
17847 2017-05-04  Richard Sandiford  <richard.sandiford@linaro.org>
17849         * tree-ssa-loop-manip.c (niter_for_unrolled_loop): Add commentary
17850         to explain the use of truncating division.  Cap the number of
17851         iterations to the maximum given by nb_iterations_upper_bound,
17852         if defined.
17854 2017-05-04  Thomas Preud'homme  <thomas.preudhomme@arm.com>
17856         * configure.ac (--enable-mingw-wildcard): Add new configurable feature.
17857         * configure: Regenerate.
17858         * config.in: Regenerate.
17859         * config/i386/driver-mingw32.c: new file.
17860         * config/i386/x-mingw32: Add rule to build driver-mingw32.o.
17861         * config.host: Link driver-mingw32.o on MinGW host.
17862         * doc/install.texi: Document new --enable-mingw-wildcard configure
17863         option.
17865 2017-05-04  Marek Polacek  <polacek@redhat.com>
17867         PR tree-optimization/80612
17868         * calls.c (get_size_range): Check for INTEGRAL_TYPE_P.
17870 2017-05-04  Prakhar Bahuguna  <prakhar.bahuguna@arm.com>
17871             Andre Simoes Dias Vieira  <andre.simoesdiasvieira@arm.com>
17873         * config/arm/arm.md (movsi): Change TARGET_32BIT to TARGET_HAVE_MOVT.
17874         (movt splitter): Likewise.
17875         * config/arm/arm.c (arm_option_check_internal): Change arm_arch_thumb2
17876         to TARGET_HAVE_MOVT, and merge with -mslow-flash-data check.
17877         (const_ok_for_arm): Change else to else if (TARGET_THUMB2) and add else
17878         block for Thumb-1 with MOVT.
17879         (thumb2_legitimate_address_p): Move code block ...
17880         (can_avoid_literal_pool_for_label_p): ... into this new function.
17881         (thumb1_legitimate_address_p): Add check for TARGET_HAVE_MOVT and
17882         literal pool.
17883         (thumb_legitimate_constant_p): Add conditional on TARGET_HAVE_MOVT
17884         * doc/invoke.texi (-mpure-code): Change "ARMv7-M targets" for
17885         "M-profile targets with the MOVT instruction".
17887 2017-05-04  Prakhar Bahuguna  <prakhar.bahuguna@arm.com>
17889         * config/arm/arm-builtins.c (arm_init_builtins): Rename
17890         __builtin_arm_ldfscr to __builtin_arm_get_fpscr, and rename
17891         __builtin_arm_stfscr to __builtin_arm_set_fpscr.
17893 2017-05-04  Martin Liska  <mliska@suse.cz>
17895         * tree-vrp.c (simplify_cond_using_ranges_2): Remove unused
17896         variable cond_code.
17898 2017-05-04  Richard Biener  <rguenther@suse.de>
17900         * tree.c (array_at_struct_end_p): Handle arrays at struct
17901         end with flexarrays more conservatively.  Refactor and treat
17902         arrays of arrays or aggregates more strict.  Fix
17903         VIEW_CONVERT_EXPR handling.  Remove allow_compref argument.
17904         * tree.c (array_at_struct_end_p): Adjust prototype.
17905         * emit-rtl.c (set_mem_attributes_minus_bitpos): Adjust.
17906         * gimple-fold.c (get_range_strlen): Likewise.
17907         * tree-chkp.c (chkp_may_narrow_to_field): Likewise.
17909 2017-05-04  Richard Biener  <rguenther@suse.de>
17911         PR tree-optimization/31130
17912         * tree-vrp.c (needs_overflow_infinity): Remove as always returning
17913         false.
17914         (supports_overflow_infinity): Likewise.
17915         (is_negative_overflow_infinity): Likewise.
17916         (is_positive_overflow_infinity): Likewise.
17917         (is_overflow_infinity): Likewise.
17918         (stmt_overflow_infinity): Likewise.
17919         (overflow_infinity_range_p): Likewise.
17920         (usable_range_p): Remove as always returning true.
17921         (make_overflow_infinity): Remove.
17922         (negative_overflow_infinity): Likewise.
17923         (positive_overflow_infinity): Likewise.
17924         (avoid_overflow_infinity): Likewise.
17925         (set_value_range): Adjust accordingly.
17926         (set_value_range_to_nonnegative): Likewise, remove now unused
17927         overflow_infinity arg.
17928         (vrp_operand_equal_p): Adjust.
17929         (update_value_range): Likewise.
17930         (range_int_cst_singleton_p): Likewise.
17931         (operand_less_p): Likewise.
17932         (compare_values_warnv): Likewise.
17933         (extract_range_for_var_from_comparison_expr): Likewise.
17934         (vrp_int_const_binop): Likewise.
17935         (zero_nonzero_bits_from_vr): Likewise.
17936         (extract_range_from_multiplicative_op_1): Likewise.
17937         (extract_range_from_binary_expr_1): Likewise.
17938         (extract_range_from_unary_expr): Likewise.
17939         (extract_range_from_comparison): Likewise.
17940         (extract_range_basic): Likewise.
17941         (adjust_range_with_scev): Likewise.
17942         (compare_ranges): Likewise.
17943         (compare_range_with_value): Likewise.
17944         (dump_value_range): Likewise.
17945         (test_for_singularity): Likewise, remove strict_overflow_p parameter
17946         never used.
17947         (simplify_cond_using_ranges): Adjust.
17949 2017-05-04  Pekka Jääskeläinen  <pekka.jaaskelainen@parmance.com>
17951         * brig-builtins.def: Added a builtin for class_f64.
17952         * builtin-types.def: Added a builtin type needed by class_f64.
17954 2017-05-03  Jason Merrill  <jason@redhat.com>
17956         * timevar.def: Add TV_CONSTEXPR.
17958 2017-05-03  David Malcolm  <dmalcolm@redhat.com>
17960         * common.opt (fdiagnostics-parseable-fixits): Fix typo.
17962 2017-05-03  Martin Jambor  <mjambor@suse.cz>
17964         * ipa-prop.c (ipa_update_after_lto_read): Removed.
17965         * ipa-prop.h (ipa_update_after_lto_read): Remove declaration.
17966         * ipa-cp.c (ipcp_propagate_stage): Do not call
17967         ipa_update_after_lto_read.
17968         * ipa-inline.c (ipa_inline): Likewise.
17970 2017-05-03  Martin Jambor  <mjambor@suse.cz>
17972         * ipa-prop.h (ipa_edge_args): Make a class.  Mark with for_user GTY
17973         tag.  Added a default constructor and a destructor.
17974         (ipa_edge_args_sum_t): New class;
17975         (ipa_edge_args_sum): Declare.
17976         (ipa_edge_args_vector): Remove declaration.
17977         (IPA_EDGE_REF): Use ipa_edge_args_sum.
17978         (ipa_free_edge_args_substructures): Remove declaration.
17979         (ipa_check_create_edge_args): Use ipa_edge_args_sum.
17980         (ipa_edge_args_info_available_for_edge_p): Likewise.
17981         * ipa-prop.c (ipa_edge_args_vector): Removed.
17982         (edge_removal_hook_holder): Likewise.
17983         (edge_duplication_hook_holder): Likewise.
17984         (ipa_edge_args_sum): New variable.
17985         (ipa_propagate_indirect_call_infos): Test ipa_edge_args_sum instead of
17986         ipa_edge_args_vector.
17987         (ipa_free_edge_args_substructures): Likewise.
17988         (ipa_free_all_edge_args): Free ipa_edge_args_sum instead of
17989         ipa_edge_args_vector.
17990         (ipa_edge_removal_hook): Turned into method
17991         ipa_edge_args_sum_t::remove.
17992         (ipa_edge_duplication_hook): Turned into method
17993         ipa_edge_args_sum_t::duplicate.
17994         (ipa_register_cgraph_hooks): Create ipa_edge_args_sum instead of
17995         registering edge hooks.
17996         (ipa_unregister_cgraph_hooks): Do not unregister edge hooks.
17997         * ipa-inline-analysis.c (estimate_function_body_sizes): Test
17998         ipa_edge_args_sum instead of ipa_edge_args_vector.
17999         * ipa-profile.c (ipa_profile): Likewise.
18001 2017-05-03  Martin Jambor  <mjambor@suse.cz>
18003         * symbol-summary.h (function_summary): New method exists.
18004         (function_summary::symtab_removal): Deallocate through release.
18005         (call_summary): New class.
18006         (gt_ggc_mx): New overload.
18007         (gt_pch_nx): Likewise.
18008         (gt_pch_nx): Likewise.
18010 2017-05-03  Jeff Law  <law@redhat.com>
18012         PR tree-optimization/78496
18013         * tree-vrp.c (simplify_cond_using_ranges_1): Renamed
18014         from simplify_cond_using_ranges.  Split off code to walk
18015         backwards through casts into ...
18016         (simplify_cond_using_ranges_2): New function.
18017         (simplify_stmt_using_ranges): Call simplify_cond_using_ranges_1.
18018         (execute_vrp): After identifying jump threads, call
18019         simplify_cond_using_ranges_2.
18021 2017-05-03  Jan Hubicka  <hubicka@ucw.cz>
18023         PR bootstrap/80609
18024         * ipa-inline.h (inline_summary): Add ctor.
18025         (create_ggc): Do not use ggc_cleared_alloc.
18027 2017-05-03  Jeff Downs  <heydowns@somuchpressure.net>
18028             Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
18030         * gcc.c (handle_braces): Support escaping in switch matching
18031         text.
18032         * doc/invoke.texi (Spec Files): Document it.
18033         Remove superfluous @code markup in items.
18035 2017-05-03  David Malcolm  <dmalcolm@redhat.com>
18037         * diagnostic-show-locus.c (struct column_range): New struct.
18038         (get_affected_columns): New function.
18039         (get_printed_columns): New function.
18040         (struct correction): New struct.
18041         (correction::ensure_capacity): New function.
18042         (correction::ensure_terminated): New function.
18043         (struct line_corrections): New struct.
18044         (line_corrections::~line_corrections): New dtor.
18045         (line_corrections::add_hint): New function.
18046         (layout::print_trailing_fixits): Reimplement in terms of the new
18047         classes.
18048         (selftest::test_overlapped_fixit_printing): New function.
18049         (selftest::diagnostic_show_locus_c_tests): Call it.
18051 2017-05-03  Nathan Sidwell  <nathan@acm.org>
18053         Canonicalize canonical type hashing
18054         * tree.h (type_hash_canon_hash): Declare.
18055         * tree.c (type_hash_list, attribute_hash_list): Move into
18056         type_hash_canon_hash.
18057         (build_type_attribute_qual_variant): Break out hash code calc into
18058         type_hash_canon_hash.
18059         (type_hash_canon_hash): New.  Generic type hash computation.
18060         (build_range_type_1, build_array_type_1, build_function_type,
18061         build_method_type_directly, build_offset_type, build_complex_type,
18062         make_vector_type): Call it.
18064 2017-05-03  Richard Biener  <rguenther@suse.de>
18066         * tree-vect-data-refs.c (vect_enhance_data_refs_alignment):
18067         When all DRs have unknown misaligned do not always peel
18068         when there is a store but apply the same costing model as if
18069         there were only loads.
18071 2017-05-03  Richard Biener  <rguenther@suse.de>
18073         Revert
18074         PR tree-optimization/80492
18075         * tree-ssa-alias.c (decl_refs_may_alias_p): Handle
18076         compare_base_decls returning dont-know properly.
18078 2017-05-03  Thomas Preud'homme  <thomas.preudhomme@arm.com>
18080         * config/arm/iterators.md (CCSI): New mode iterator.
18081         (arch): New mode attribute.
18082         * config/arm/sync.md (atomic_compare_and_swap<mode>_1): Rename into ...
18083         (atomic_compare_and_swap<CCSI:arch><NARROW:mode>_1): This and ...
18084         (atomic_compare_and_swap<CCSI:arch><SIDI:mode>_1): This.  Use CCSI
18085         code iterator for success result mode.
18086         * config/arm/arm.c (arm_expand_compare_and_swap): Adapt code to use
18087         the corresponding new insn generators.
18089 2017-05-03  Bin Cheng  <bin.cheng@arm.com>
18091         Revert r247509
18092         2017-05-02  Bin Cheng  <bin.cheng@arm.com>
18093         * rtlanal.c (rtx_cost): Handle TRUNCATE between tieable modes.
18095 2017-05-03  Richard Sandiford  <richard.sandiford@linaro.org>
18097         * tree-data-ref.h (SUB_CONFLICTS_IN_A): Wrap SUB argument in brackets.
18098         (SUB_CONFLICTS_IN_B, SUB_LAST_CONFLICT, SUB_DISTANCE): Likewise.
18099         (DDR_A): Wrap DDR argument in brackets.
18100         (DDR_B, DDR_AFFINE_P, DDR_ARE_DEPENDENT, DDR_SUBSCRIPTS): Likewise.
18101         (DDR_LOOP_NEST, DDR_INNER_LOOP, DDR_SELF_REFERENCE): Likewise.
18102         (DDR_REVERSED_P): Likewise.
18104 2017-05-03  Jakub Jelinek  <jakub@redhat.com>
18106         PR tree-optimization/79472
18107         * tree-switch-conversion.c (struct switch_conv_info): Add
18108         contiguous_range and default_case_nonstandard fields.
18109         (collect_switch_conv_info): Compute contiguous_range and
18110         default_case_nonstandard fields, don't clear final_bb if
18111         contiguous_range and only the default case doesn't have the required
18112         structure.
18113         (check_all_empty_except_final): Set default_case_nonstandard instead
18114         of failing if contiguous_range and the default case doesn't have empty
18115         block.
18116         (check_final_bb): Add SWTCH argument, don't fail if contiguous_range
18117         and only the default case doesn't have the required constants.  Skip
18118         virtual phis.
18119         (gather_default_values): Skip virtual phis.  Allow non-NULL CASE_LOW
18120         if default_case_nonstandard.
18121         (build_constructors): Build constant 1 just once.  Assert that default
18122         values aren't inserted in between cases if contiguous_range.  Skip
18123         virtual phis.
18124         (build_arrays): Skip virtual phis.
18125         (prune_bbs): Add DEFAULT_BB argument, don't remove that bb.
18126         (fix_phi_nodes): Don't add e2f phi arg if default_case_nonstandard.
18127         Handle virtual phis.
18128         (gen_inbound_check): Handle default_case_nonstandard case.
18129         (process_switch): Adjust check_final_bb caller.  Call
18130         gather_default_values with the first non-default case instead of
18131         default case if default_case_nonstandard.
18133 2017-05-02  Nathan Sidwell  <nathan@acm.org>
18135         * ggc-page.c (move_ptes_to_front): Replace unsigned >0 with i--
18136         check.  Fix formatting.
18138 2017-05-02  Jan Hubicka  <hubicka@ucw.cz>
18140         * ipa-inline-analysis.c (estimate_node_size_and_time): Allow roundoff
18141         errors when comparing specialized and unspecialized times.
18143 2017-05-02  David Malcolm  <dmalcolm@redhat.com>
18145         * diagnostic-show-locus.c
18146         (layout::should_print_annotation_line_p): Make private.
18147         (layout::print_annotation_line): Make private.
18148         (layout::annotation_line_showed_range_p): Make private.
18149         (layout::show_ruler): Make private.
18150         (layout::print_source_line): Make private.  Pass in line and
18151         line_width, rather than calling location_get_source_line.  Drop
18152         returned value.
18153         (layout::print_leading_fixits): New method.
18154         (layout::print_any_fixits): Rename to...
18155         (layout::print_trailing_fixits): ...this, and make private.
18156         Don't print newline fixits.
18157         (diagnostic_show_locus): Move logic for printing one row into...
18158         (layout::print_line): ...this new function.  Move the
18159         location_get_source_line call and error-handling from
18160         print_source_line to here.  Call print_leading_fixits, and rename
18161         print_any_fixits to print_trailing_fixits.
18162         (selftest::test_fixit_insert_containing_newline): Update now that
18163         newlines are partially supported.
18164         (selftest::test_fixit_insert_containing_newline_2): New test.
18165         (selftest::test_fixit_replace_containing_newline): Update comments.
18166         (selftest::diagnostic_show_locus_c_tests): Call the new test.
18167         * edit-context.c (class added_line): New class.
18168         (class edited_line): Describe newline handling in comment.
18169         (edited_line::actually_edited_p): New method.
18170         (edited_line::print_content): Delete redundant decl.
18171         (edited_line::m_predecessors): New field.
18172         (edited_file::print_content): Call edited_line::print_content.
18173         (edited_file::print_diff): Update to support newlines.
18174         (edited_file::print_diff_hunk): Likewise.
18175         (edited_file::print_run_of_changed_lines): New function.
18176         (edited_file::print_diff_line): Convert to...
18177         (print_diff_line): ...this.
18178         (edited_file::get_effective_line_count): New function.
18179         (edited_line::edited_line): Initialize new field m_predecessors.
18180         (edited_line::~edited_line): Clean up m_predecessors.
18181         (edited_line::apply_fixit): Handle newlines.
18182         (edited_line::get_effective_line_count): New function.
18183         (edited_line::print_content): New function.
18184         (edited_line::print_diff_lines): New function.
18185         (selftest::test_applying_fixits_insert_containing_newline): New
18186         test.
18187         (selftest::test_applying_fixits_replace_containing_newline): New
18188         test.
18189         (selftest::insert_line): New function.
18190         (selftest::test_applying_fixits_multiple_lines): Add example of
18191         inserting a line.
18192         (selftest::edit_context_c_tests): Call the new tests.
18194 2017-05-02  Bin Cheng  <bin.cheng@arm.com>
18196         * tree-ssa-loop-ivopts.c (get_scaled_computation_cost_at): Delete
18197         parameter cand.  Update dump information.
18198         (get_computation_cost): Update uses.
18200 2017-05-02  Bin Cheng  <bin.cheng@arm.com>
18202         * tree-ssa-loop-ivopts.c (get_computation_aff_1): New.
18203         (get_computation_aff): Reorder parameters.  Use get_computation_aff_1.
18204         (get_computation_at, rewrite_use_address): Update use of
18205         get_computation_aff.
18207 2017-05-02  Bin Cheng  <bin.cheng@arm.com>
18209         * tree-ssa-loop-ivopts.c (get_computation_at): Reorder parameters.
18210         (get_computation): Delete.
18211         (get_computation_cost): Implement like get_computation_cost_at.
18212         Use get_computation_at.
18213         (get_computation_cost_at): Delete.
18214         (rewrite_use_nonlinear_expr): Use get_computation_at.
18215         (rewrite_use_compare, remove_unused_ivs): Ditto.
18217 2017-05-02  Bin Cheng  <bin.cheng@arm.com>
18219         * tree-ssa-loop-ivopts.c (rewrite_use_address): Simple refactor.
18221 2017-05-02  Bin Cheng  <bin.cheng@arm.com>
18223         * tree-ssa-loop-ivopts.c (struct iv_ca): Rename n_regs to n_invs.
18224         (ivopts_global_cost_for_size): Rename parameter and update uses.
18225         (iv_ca_recount_cost): Update uses.
18226         (iv_ca_set_remove_invs, iv_ca_set_no_cp): Record invariants and
18227         candidates seperately in n_invs and n_cands.
18228         (iv_ca_set_add_invs, iv_ca_set_cp, iv_ca_new): Ditto.
18230 2017-05-02  Bin Cheng  <bin.cheng@arm.com>
18232         * tree-ssa-loop-ivopts.c (struct walk_tree_data): New.
18233         (find_inv_vars_cb): New.
18234         (find_depends): Renamed to ...
18235         (find_inv_vars): ... this.
18236         (add_candidate_1, force_var_cost): Call find_inv_vars.
18237         (split_address_cost, determine_group_iv_cost_cond): Ditto.
18239 2017-05-02  Bin Cheng  <bin.cheng@arm.com>
18241         * tree-ssa-loop-ivopts.c (struct cost_pair): Rename depends_on to
18242         inv_vars.  Add inv_exprs.
18243         (struct iv_cand): Rename depends_on to inv_vars.
18244         (struct ivopts_data): Rename max_inv_id/n_invariant_uses to
18245         max_inv_var_id/n_inv_var_uses.  Move max_inv_expr_id around.
18246         Refactor field used_inv_exprs from has_map to array n_inv_expr_uses.
18247         (dump_cand): Dump inv_vars.
18248         (tree_ssa_iv_optimize_init): Support inv_vars and inv_exprs.
18249         (record_invariant, find_depends, add_candidate_1): Ditto.
18250         (set_group_iv_cost, force_var_cost): Ditto.
18251         (split_address_cost, ptr_difference_cost, difference_cost): Ditto.
18252         (get_computation_cost_at, get_computation_cost): Ditto.
18253         (determine_group_iv_cost_generic): Ditto.
18254         (determine_group_iv_cost_address): Ditto.
18255         (determine_group_iv_cost_cond, autoinc_possible_for_pair): Ditto.
18256         (determine_group_iv_costs): Ditto.
18257         (iv_ca_recount_cost): Update call to ivopts_global_cost_for_size.
18258         (iv_ca_set_remove_invariants): Renamed to ...
18259         (iv_ca_set_remove_invs): ... this.  Support inv_vars and inv_exprs.
18260         (iv_ca_set_no_cp): Use iv_ca_set_remove_invs.
18261         (iv_ca_set_add_invariants):  Renamed to ...
18262         (iv_ca_set_add_invs): ... this.  Support inv_vars and inv_exprs.
18263         (iv_ca_set_cp): Use iv_ca_set_add_invs.
18264         (iv_ca_has_deps): Support inv_vars and inv_exprs.
18265         (iv_ca_new, iv_ca_free, iv_ca_dump, free_loop_data): Ditto.
18266         (create_new_ivs): Remove useless dump.
18268 2017-05-02  Bin Cheng  <bin.cheng@arm.com>
18270         * tree-ssa-loop-ivopts.c (get_computation_cost_at): Remove pseudo
18271         iv_cand code.
18272         (determine_group_iv_cost_cond, determine_iv_cost): Ditto.
18273         (iv_ca_set_no_cp, create_new_iv): Ditto.
18275 2017-05-02  Bin Cheng  <bin.cheng@arm.com>
18277         * rtlanal.c (rtx_cost): Handle TRUNCATE between tieable modes.
18279 2017-05-02  Xi Ruoyao  <ryxi@stu.xidian.edu.cn>
18281         * tree.h (EXPR_CILK_SPAWN): Use macro TREE_CHECK2 instead of
18282         function tree_check2.
18284 2017-05-02  Martin Liska  <mliska@suse.cz>
18286         * doc/gcov.texi: Add missing preposition.
18287         * gcov.c (function_info::function_info): Properly fill up
18288         all member variables.
18290 2017-05-02  Tamar Christina  <tamar.christina@arm.com>
18292         * expr.c (expand_expr_real_2): Re-cost if previous costs are the same.
18294 2017-05-02  Tamar Christina  <tamar.christina@arm.com>
18296         * simplify-rtx.c (simplify_binary_operation_1): Add LSHIFTRT case.
18298 2017-05-02  Martin Liska  <mliska@suse.cz>
18300         PR lto/77954.
18301         * lto-streamer-in.c (lto_read_tree_1): Remove
18302         LTO_STREAMER_DEBUG.
18303         * lto-streamer.c (struct tree_hash_entry): Likewise.
18304         (struct tree_entry_hasher): Likewise.
18305         (tree_entry_hasher::hash): Likewise.
18306         (tree_entry_hasher::equal): Likewise.
18307         (lto_streamer_init): Likewise.
18308         (lto_orig_address_map): Likewise.
18309         (lto_orig_address_get): Likewise.
18310         (lto_orig_address_remove): Likewise.
18311         * lto-streamer.h: Likewise.
18312         * tree-streamer-in.c (streamer_alloc_tree): Likewise.
18313         * tree-streamer-out.c (streamer_write_tree_header): Likewise.
18315 2017-05-02  Sebastian Peryt  <sebastian.peryt@intel.com>
18317         * config/i386/avx512fintrin.h (_mm_mask_add_round_sd)
18318         (_mm_maskz_add_round_sd, _mm_mask_add_round_ss)
18319         (mm_maskz_add_round_ss, _mm_mask_sub_round_sd)
18320         (mm_maskz_sub_round_sd, _mm_mask_sub_round_ss)
18321         (mm_maskz_sub_round_ss, _mm_mask_add_sd)
18322         (mm_maskz_add_sd, _mm_mask_add_ss, _mm_maskz_add_ss)
18323         (mm_mask_sub_sd, _mm_maskz_sub_sd, _mm_mask_sub_ss)
18324         (mm_maskz_sub_ss): New intrinsics.
18325         * config/i386/i386-builtin-types.def (V2DF_FTYPE_V2DF_V2DF_V2DF_UQI_INT)
18326         (V4SF_FTYPE_V4SF_V4SF_V4SF_UQI_INT): New function type aliases.
18327         * config/i386/i386-builtin.def (__builtin_ia32_addsd_mask_round)
18328         (__builtin_ia32_addss_mask_round, __builtin_ia32_subsd_mask_round)
18329         (__builtin_ia32_subss_mask_round): New builtins.
18330         * config/i386/i386.c (V2DF_FTYPE_V2DF_V2DF_V2DF_UQI_INT)
18331         (V4SF_FTYPE_V4SF_V4SF_V4SF_UQI_INT): Handle new types.
18332         * config/i386/sse.md (<sse>_vm<plusminus_insn><mode>3<round_name>):
18333         Renamed to ...
18334         (<sse>_vm<plusminus_insn><mode>3<mask_name><round_name>): ... this.
18335         (v<plusminus_mnemonic><ssescalarmodesuffix>\t{<round_op3>%2, %1, %0|%0, %1, %<iptr>2<round_op3>}):
18336         Changed to ...
18337         (v<plusminus_mnemonic><ssescalarmodesuffix>\t{<round_mask_op3>%2, %1, %0<mask_operand3>|%0<mask_operand3>, %1, %<iptr>2<round_mask_op3>}):
18338         ... this.
18340 2017-05-02  Martin Jambor  <mjambor@suse.cz>
18342         PR tree-optimization/78687
18343         * tree-sra.c (access): New field parent.
18344         (process_subtree_disqualification): New function.
18345         (disqualify_candidate): Call it.
18346         (build_accesses_from_assign): Reset write flag if creating an
18347         assighnment link.
18348         (build_access_subtree): Fill in parent field and also prpagate
18349         down grp_write flag.
18350         (create_artificial_child_access): New parameter set_grp_write, set
18351         grp_write to its value.
18352         (propagate_subaccesses_across_link): Also propagate grp_write flag
18353         values.
18354         (propagate_all_subaccesses): Push the closest parent back to work
18355         queue if add_access_to_work_queue returned true.
18357 2017-05-02  Richard Biener  <rguenther@suse.de>
18359         * common.opt (fstrict-overflow): Alias negative to fwrapv.
18360         * doc/invoke.texi (fstrict-overflow): Remove all traces of
18361         -fstrict-overflow documentation.
18362         * tree.h (TYPE_OVERFLOW_UNDEFINED): Do not test flag_strict_overflow.
18363         (POINTER_TYPE_OVERFLOW_UNDEFINED): Test !flag_wrapv instead of
18364         flag_strict_overflow.
18365         * ipa-inline.c (can_inline_edge_p): Do not test flag_strict_overflow.
18366         * lto-opts.c (lto_write_options): Do not stream it.
18367         * lto-wrapper.c (merge_and_complain): Do not handle it.
18368         * opts.c (default_options_table): Do not set -fstrict-overflow.
18369         (finish_options): Likewise do not clear it when sanitizing.
18370         * simplify-rtx.c (simplify_const_relational_operation): Do not
18371         test flag_strict_overflow.
18373 2017-05-02  Uros Bizjak  <ubizjak@gmail.com>
18375         * config/alpha/alpha.md (*add<mode>3_ieee): Merge to add<mode>3
18376         using enabled attribute.
18377         (*sub<mode>3_ieee): Merge to sub<mode>3 using enabled attribute.
18378         (*mul<mode>3_ieee): Merge to mul<mode>3 using enabled attribute.
18379         (*div<mode>3_ieee): Merge to div<mode>3 using enabled attribute.
18380         (*sqrt<mode>2_ieee): Merge to sqrt<mode>2 using enabled attribute.
18381         (*fix_truncdfdi_ieee): Merge to *fix_truncdfdi2 using enabled attribute.
18382         (*fix_truncsfdi_ieee): Merge to *fix_truncsfdi2 using enabled attribute.
18383         (*floatdisf_ieee): Merge to floatdisf2 using enabled attribute.
18384         (*floatdidf_ieee): Merge to floatdidf2 using enabled attribute.
18385         (*truncdfsf2_ieee): Merge to truncdfsf2 using enabled attribute.
18386         (*cmpdf_ieee): Merge to *cmpdf_internal using enabled attribute.
18388 2017-05-02  Uros Bizjak  <ubizjak@gmail.com>
18390         * config/i386/i386.c (ix86_code_end): Use {FIRST,LAST}_INT_REG.
18392 2017-05-02  Richard Biener  <rguenther@suse.de>
18394         PR tree-optimization/80591
18395         Revert
18396         2017-04-10  Richard Biener  <rguenther@suse.de>
18398         * tree-ssa-structalias.c (find_func_aliases): Properly handle
18399         asm inputs.
18401 2017-05-02  Richard Biener  <rguenther@suse.de>
18403         PR tree-optimization/80549
18404         * tree-cfgcleanup.c (mfb_keep_latches): New helper.
18405         (cleanup_tree_cfg_noloop): Create forwarders to known loop
18406         headers if they do not have a preheader.
18408 2017-05-02  Martin Liska  <mliska@suse.cz>
18410         PR other/80589
18411         * common.opt: Fix typo.
18412         * doc/invoke.texi: Likewise.
18414 2017-05-01  Jan Beulich  <jbeulich@suse.com>
18416         * config/i386/sse.md (xop_vpermil2<mode>3): Do not allow operand
18417         swapping, add (x,x,m,x,n) alternative.
18419 2017-05-01  Nathan Sidwell  <nathan@acm.org>
18421         * calls.c (combine_pending_stack_adjustment_and_call): Remove
18422         unnecessary unadjusted_alignment check.
18424 2017-05-01  Xi Ruoyao  <ryxi@stu.xidian.edu.cn>
18426         PR c++/80038
18427         * cilk_common.c (expand_builtin_cilk_detach): Move pedigree
18428         operations here.
18429         * gimplify.c (gimplify_cilk_detach): New function.
18430         (gimplify_call_expr, gimplify_modify_expr): Call it as needed.
18431         * tree-core.h: Document EXPR_CILK_SPAWN.
18432         * tree.h (EXPR_CILK_SPAWN): Define.
18434 2017-05-01  David Malcolm  <dmalcolm@redhat.com>
18436         * diagnostic-show-locus.c (layout::get_expanded_location): Rewrite
18437         to use new fixit_hint representation, using the "replace" logic.
18438         (get_line_span_for_fixit_hint): Likewise.
18439         (layout::print_any_fixits): Likewise.
18440         (selftest::test_one_liner_many_fixits): Rename to...
18441         (selftest::test_one_liner_many_fixits_1): ...this, and update
18442         comment and expected output to reflect that the multiple fix-it
18443         hints are now consolidated into one insertion.
18444         (selftest::test_one_liner_many_fixits_2): New test.
18445         (selftest::test_diagnostic_show_locus_one_liner): Update for
18446         above.
18447         (selftest::test_fixit_consolidation): Update for fix-it API
18448         change.
18449         * diagnostic.c (print_parseable_fixits): Likewise.
18450         * edit-context.c (edited_line::m_line_events): Convert from
18451         auto_vec <line_event *> to auto_vec <line_event>.
18452         (class line_event): Convert from abstract base class to a concrete
18453         class, taking over the role of replace_event.
18454         (class insert_event): Delete.
18455         (class replace_event): Rename to class line_event.  Convert to
18456         half-open range.
18457         (edit_context::add_fixits): Reimplement.
18458         (edit_context::apply_insert): Delete.
18459         (edit_context::apply_replace): Rename to...
18460         (edit_context::apply_fixit): ...this.  Convert to half-open range.
18461         (edited_file::apply_insert): Delete.
18462         (edited_file::apply_replace): Rename to...
18463         (edited_file::apply_fixit): ...this.
18464         (edited_line::~edited_line): Drop deletion of events.
18465         (edited_line::apply_insert): Delete.
18466         (edited_line::apply_replace): Rename to...
18467         (edited_line::apply_fixit): ...this.  Convert to half-open range.
18468         Update for change to type of m_line_events.
18469         * edit-context.h (edit_context::apply_insert): Delete.
18470         (edit_context::apply_replace): Rename to...
18471         (edit_context::apply_fixit): ...this.
18473 2017-05-01  Martin Sebor  <msebor@redhat.com>
18475         * gimple-ssa-sprintf.c (format_integer): Set knownrange when it's
18476         known.
18478 2017-05-01  Uros Bizjak  <ubizjak@gmail.com>
18480         PR target/68491
18481         * config/i386/cpuid.h (__get_cpuid): Always return 0 when
18482         __get_cpuid_max returns 0.
18483         (__get_cpuid_count): Ditto.
18485 2017-05-01  Eric Botcazou  <ebotcazou@adacore.com>
18487         * tree.c (substitute_in_expr) <tcc_vl_exp>: Also inline a call if the
18488         replacement expression is another instance of one of its arguments.
18490 2017-05-01  Jakub Jelinek  <jakub@redhat.com>
18492         PR target/79430
18493         * rtlanal.c (reg_set_p): If reg is a stack_pointer_rtx, also
18494         check for stack push/pop autoinc.
18495         * config/i386/i386.c (ix86_agi_dependent): Return false
18496         if the only reason why modified_in_p returned true is that
18497         addr is SP based and set_insn is a push or pop.
18499 2017-04-29  Jan Hubicka  <hubicka@ucw.cz>
18501         * ipa-inline.c (compute_inlined_call_time): Remove now unnecesary
18502         overflow check.
18504 2017-04-29  Jan Hubicka  <hubicka@ucw.cz>
18506         PR ipa/79224
18507         * ipa-inline-analysis.c (dump_predicate): Add optional parameter NL.
18508         (account_size_time): Use two predicates - exec_pred and
18509         nonconst_pred_ptr.
18510         (evaluate_conditions_for_known_args): Compute both clause and
18511         nonspec_clause.
18512         (evaluate_properties_for_edge): Evaulate both clause and nonspec_clause.
18513         (inline_summary_t::duplicate): Update.
18514         (estimate_function_body_sizes): Caluculate exec and nonconst predicates
18515         separately.
18516         (compute_inline_parameters): Likewise.
18517         (estimate_edge_size_and_time): Update caluclation of time.
18518         (estimate_node_size_and_time): Compute both time and nonspecialized
18519         time.
18520         (estimate_ipcp_clone_size_and_time): Update.
18521         (inline_merge_summary): Update.
18522         (do_estimate_edge_time): Update.
18523         (do_estimate_edge_size): Update.
18524         (do_estimate_edge_hints): Update.
18525         (inline_read_section, inline_write_summary): Stream both new predicates.
18526         * ipa-inline.c (compute_uninlined_call_time): Take uninlined_call_time
18527         as argument.
18528         (compute_inlined_call_time): Cleanup.
18529         (big_speedup_p): Update.
18530         (edge_badness): Update.
18531         * ipa-inline.h (INLINE_TIME_SCALE): Remove.
18532         (size_time_entry): Replace predicate by exec_predicate and
18533         nonconst_predicate.
18534         (edge_growth_cache_entry): Cache both time nad nonspecialized time.
18535         (estimate_edge_time): Return also nonspec_time.
18536         (reset_edge_growth_cache): Update.
18538 2017-04-29  Jakub Jelinek  <jakub@redhat.com>
18540         PR rtl-optimization/80491
18541         * ifcvt.c (noce_process_if_block): When looking for x setter
18542         with missing else_bb, don't check only the insn right before
18543         cond_earliest, but look for the last insn that x is modified in
18544         within the same bb.
18546         PR rtl-optimization/80491
18547         * alias.c (memory_modified_in_insn_p): Return true for CALL_INSNs.
18549 2017-04-29  Marc Glisse  <marc.glisse@inria.fr>
18551         PR tree-optimization/80487
18552         * tree-ssa-alias.c (stmt_kills_ref_p): Handle stpncpy and strncpy.
18554 2017-04-29  Prathamesh Kulkarni  <prathamesh.kulkarni@linaro.org>
18556         PR tree-optimization/79697
18557         * tree-ssa-dce.c (mark_stmt_if_obviously_necessary): Check if callee
18558         is BUILT_IN_STRDUP, BUILT_IN_STRNDUP, BUILT_IN_REALLOC.
18559         (propagate_necessity): Check if def_callee is BUILT_IN_STRDUP or
18560         BUILT_IN_STRNDUP.
18561         * gimple-fold.c (gimple_fold_builtin_realloc): New function.
18562         (gimple_fold_builtin): Call gimple_fold_builtin_realloc.
18564 2017-04-28  Martin Sebor  <msebor@redhat.com>
18566         PR tree-optimization/80523
18567         * gimple-ssa-sprintf.c (target_to_host_charmap): New global variable.
18568         (init_target_to_host_charmap, target_to_host, target_strtol10): New
18569         functions.
18570         (maybe_warn, format_directive, parse_directive): Use new functions.
18571         (pass_sprintf_length::execute): Call init_target_to_host_charmap.
18573 2017-04-28  Marc Glisse  <marc.glisse@inria.fr>
18575         * match.pd (X+Z OP Y+Z, X-Z OP Y-Z, Z-X OP Z-Y): New transformations.
18577 2017-04-28  Bernd Edlinger  <bernd.edlinger@hotmail.de>
18579         * configure.ac (SYSTEM_HEADER_DIR, BUILD_SYSTEM_HEADER_DIR,
18580         target_header_dir): Set correctly.
18581         * configure: Regenerated.
18582         * Makefile.in (BUILD_SYSTEM_HEADER_DIR): New make variabe.
18583         (LIMITS_H_TEST, if_multiarch, stmp-fixinc): Use BUILD_SYSTEM_HEADER_DIR
18584         instead of SYSTEM_HEADER_DIR.
18586 2017-04-28  Jan Hubicka  <hubicka@ucw.cz>
18588         * ipa-cp.c (perform_estimation_of_a_value): Turn time to sreal.
18589         (estimate_local_effects): Likewise.
18590         * ipa-inline.c (compute_inlined_call_time, want_inline_small_function_p,
18591         edge_badness, inline_small_functions, dump_overall_stats): LIkewise.
18592         * ipa-inline.h (edge_growth_cache_entry, estimate_time_after_inlining,
18593         estimate_ipcp_clone_size_and_time, do_estimate_edge_time,
18594         do_estimate_edge_time, estimate_edge_time): Likewise.
18595         * ipa-inline-analysis.c (estimate_node_size_and_time,
18596         estimate_ipcp_clone_size_and_time, do_estimate_edge_time): Likewise.
18597         (estimate_time_after_inlining): Remove.
18599 2017-04-28  Martin Liska  <mliska@suse.cz>
18601         * doc/gcov.texi: Enhance documentation of gcov.
18603 2017-04-28  Martin Liska  <mliska@suse.cz>
18605         * doc/gcov.texi: Sort options in alphabetic order.
18606         * doc/gcov-dump.texi: Likewise.
18607         * doc/gcov-tool.texi: Likewise.
18608         * gcov.c (print_usage): Likewise.
18609         * gcov-dump.c (print_usage): Likewise.
18610         * gcov-tool.c (print_merge_usage_message): Likewise.
18611         (print_rewrite_usage_message): Likewise.
18612         (print_overlap_usage_message): Likewise.
18614 2017-04-28  Martin Liska  <mliska@suse.cz>
18616         PR gcov-profile/53915
18617         * gcov.c (format_gcov): Print 'NAN %' when top > bottom.
18619 2017-04-28  Martin Liska  <mliska@suse.cz>
18621         PR gcov-profile/79891
18622         * gcov.c (add_line_counts): Assign BBs to lines just if the BB
18623         is marked by compiler as living on a line.
18624         (get_cycles_count): Remove usage of the union.
18625         (output_intermediate_file): Likewise.
18626         (find_source): Fix GNU coding style.
18627         (accumulate_line_counts): Remove old non-all block mode.
18628         (output_lines): Remove usage of the union.
18629         * profile.c (output_location): Include all BBs, even if
18630         belonging to a same line (and file) as a previous BB.
18632 2017-04-28  Martin Liska  <mliska@suse.cz>
18634         * gcov.c (process_args): Handle new argument 'w'.
18635         (read_graph_file): Assign ID to BBs.
18636         (output_branch_count): Display BB # if verbose flag is set.
18637         (output_lines): Likewise for arcs.
18638         (print_usage): Add '--verbose' option help.
18639         * doc/gcov.texi: Document --verbose (-w) option.
18641 2017-04-28  Martin Liska  <mliska@suse.cz>
18643         * gcov.c (struct block_location_info): New struct.
18644         (process_file): Fill up the new structure.
18645         (read_graph_file): Replace usage of encoding by the newly added
18646         struct.
18647         (add_line_counts): Likewise.
18648         (accumulate_line_counts): Remove usage of the union.
18649         (function_info::function_info): New function.
18650         (function_info::~function_info): Likewise.
18651         (process_file): Call delete instead of release_function.
18652         (release_function): Release the function.
18653         (release_structures): Call delete instead of release_function.
18654         (solve_flow_graph): Replace usage of num_blocks.
18655         (find_exception_blocks): Likewise.
18656         (output_lines): Fix GNU coding style.
18658 2017-04-28  Martin Liska  <mliska@suse.cz>
18660         PR driver/56469
18661         * coverage.c (coverage_remove_note_file): New function.
18662         * coverage.h: Declare the function.
18663         * toplev.c (finalize): Clean if an error has been seen.
18665 2017-04-28  Martin Liska  <mliska@suse.cz>
18667         PR gcov-profile/80031
18668         * gcov-dump.c (tag_blocks): Just print number of basic blocks.
18669         * gcov-io.h (GCOV_TAG_BLOCKS_NUM): Remove unused macro.
18670         * gcov.c (read_graph_file): Read just number of blocks.
18671         * profile.c (branch_prob): Do not stream 0 flags per a basic
18672         block.
18674 2017-04-28  Martin Liska  <mliska@suse.cz>
18676         * gcov-dump.c (tag_*): Add new argument to declarations.
18677         (dump_gcov_file): Likewise.
18678         (tag_blocks): Add and use new argument depth.
18679         (tag_arcs): Likewise.
18680         (tag_lines): Likewise.
18681         (tag_counters): Likewise.
18682         (tag_summary): Likewise.
18683         (dump_working_sets): Use depth to do a proper indentation.
18685 2017-04-28  Jakub Jelinek  <jakub@redhat.com>
18687         PR bootstrap/80531
18688         * cgraph.h (symtab_node::debug_symtab): No longer inline.
18689         * symtab.c (symtab_node::debug_symtab): Move definition here.
18691 2017-04-28  Richard Biener  <rguenther@suse.de>
18693         * lto-streamer.h (LTO_major_version): Bump to 7.
18695 2017-04-28  Richard Biener  <rguenther@suse.de>
18697         * tree-vrp.c (assert_info): New struct.
18698         (add_assert_info): New helper.
18699         (register_edge_assert_for_2): Refactor to add asserts to a vector
18700         of assert_info.
18701         (register_edge_assert_for_1): Likewise.
18702         (register_edge_assert_for): Likewise.
18703         (finish_register_edge_assert_for): New helper actually registering
18704         asserts where live on edge.
18705         (find_conditional_asserts): Adjust.
18706         (find_switch_asserts): Likewise.
18707         (evrp_dom_walker::try_find_new_range): Generalize.
18708         (evrp_dom_walker::before_dom_children): Use register_edge_assert_for.
18710 2017-04-27  Marek Polacek  <polacek@redhat.com>
18712         PR sanitizer/80349
18713         * fold-const.c (fold_binary_loc) <case EQ_EXPR, NE_EXPR>: Convert
18714         arg10 and arg11 to itype.
18716 2017-04-27  Jonathan Wakely  <jwakely@redhat.com>
18718         * doc/extend.texi (Object Size Checking): Improve grammar.
18720 2017-04-27  Richard Earnshaw  <rearnsha@arm.com>
18722         PR target/80530
18723         * config/aarch64/aarch64.c (aarch64_emit_approx_sqrt): Ensure
18724         that the logic for permitting reciprocal estimates matches that
18725         in use_rsqrt_p.
18727 2017-04-27  Jakub Jelinek  <jakub@redhat.com>
18729         PR c++/80534
18730         * tree.c (type_cache_hasher::equal): Only compare
18731         TYPE_TYPELESS_STORAGE flag on non-aggregate element types.
18732         (build_array_type_1): Only hash TYPE_TYPELESS_STORAGE flag on
18733         non-aggregate element types.
18734         * tree.h (TYPE_TYPELESS_STORAGE): Fix comment typo, add more details
18735         about the flag on ARRAY_TYPEs in the comment, formatting fix.
18737 2017-04-27  Richard Biener  <rguenther@suse.de>
18739         PR middle-end/80533
18740         * emit-rtl.c (set_mem_attributes_minus_bitpos): When
18741         stripping ARRAY_REFs from MEM_EXPR make sure we're not
18742         keeping a reference to a trailing array.
18744 2017-04-27  Richard Biener  <rguenther@suse.de>
18746         PR middle-end/80539
18747         * tree-chrec.c (chrec_fold_plus_poly_poly): Deal with not
18748         being in loop-closed SSA form conservatively.
18749         (chrec_fold_multiply_poly_poly): Likewise.
18751 2017-04-27  Tamar Christina  <tamar.christina@arm.com>
18753         PR middle-end/79665
18754         * expr.c (expand_expr_real_2): Move TRUNC_MOD_EXPR, FLOOR_MOD_EXPR,
18755         CEIL_MOD_EXPR, ROUND_MOD_EXPR cases.
18757 2017-04-27  Jakub Jelinek  <jakub@redhat.com>
18759         PR target/77728
18760         * config/aarch64/aarch64.c (struct aarch64_fn_arg_alignment): Remove.
18761         (aarch64_function_arg_alignment): Return unsigned int again, but still
18762         ignore TYPE_FIELDS chain decls other than FIELD_DECLs.
18763         (aarch64_layout_arg): Adjust aarch64_function_arg_alignment caller.
18764         Don't emit -Wpsabi note.
18765         (aarch64_function_arg_boundary): Likewise.
18766         (aarch64_gimplify_va_arg_expr): Adjust aarch64_function_arg_alignment
18767         caller.
18769 2017-04-26  Nathan Sidwell  <nathan@acm.org>
18771         * tree.h (crc32_unsigned_n): Declare.
18772         (crc32_unsigned, crc32_unsigned): Make inline.
18773         * tree.c (crc32_unsigned_bits): Replace with ...
18774         (crc32_unsigned_n): ... this.
18775         (crc32_unsigned, crc32_byte): Remove.
18776         (crc32_string): Remove unnecessary braces.
18778 2017-04-25  Jan Hubicka  <hubicka@ucw.cz>
18780         * ipa-cp.c (estimate_local_effects): Convert sreal to int.
18781         * ipa-inline-analysis.c (MAX_TIME): Remove.
18782         (account_size_time): Use sreal for time.
18783         (dump_inline_summary): Update.
18784         (estimate_function_body_sizes): Update.
18785         (estimate_edge_size_and_time): Update.
18786         (estimate_calls_size_and_time): Update.
18787         (estimate_node_size_and_time): Update.
18788         (inline_merge_summary): Update.
18789         (inline_update_overall_summary): Update.
18790         (estimate_time_after_inlining): Update.
18791         (inline_read_section): Update.
18792         (inline_write_summary): Update.
18793         * ipa-inline.c (compute_uninlined_call_time): Update.
18794         (compute_inlined_call_time): Update.
18795         (recursive_inlining): Update.
18796         (inline_small_functions): Update.
18797         (dump_overall_stats): Update.
18798         * ipa-inline.h: Include sreal.h.
18799         (size_time_entry): Turn time to sreal.
18800         (inline_summary): Turn self_time nad time to sreal.
18802 2017-04-25  Jan Hubicka  <hubicka@ucw.cz>
18804         * sreal.c: Include backend.h, tree.h, gimple.h, cgraph.h and
18805         data-streamer.h
18806         (sreal::stream_out, sreal::stream_in): New.
18807         * sreal.h (sreal::stream_out, sreal::stream_in): Declare.
18809 2017-04-25  Jakub Jelinek  <jakub@redhat.com>
18811         * Makefile.in (s-options): Invoke opt-gather.awk with LC_ALL=C in the
18812         environment.
18814 2017-04-25  Uros Bizjak  <ubizjak@gmail.com>
18816         PR target/70799
18817         * config/i386/i386.c (dimode_scalar_to_vector_candidate_p):
18818         Handle ASHIFTRT.
18819         (dimode_scalar_chain::compute_convert_gain): Ditto.
18820         (dimode_scalar_chain::make_vector_copies): Ditto.
18821         (dimode_scalar_chain::convert_reg): Ditto.
18822         (dimode_scalar_chain::convert_insn): Ditto.
18823         * config/i386/sse.md (VI24_AVX512BW_1): Remove mode iterator.
18824         (VI248_AVX512BW_1): New mode iterator.
18825         (<mask_codefor>ashr<mode>3<mask_name>): Merge insn pattern with
18826         <mask_codefor>ashrv2di3<mask_name> insn using VI248_AVX512BW_1
18827         mode iterator.
18829 2017-04-25  Martin Sebor  <msebor@redhat.com>
18831         PR tree-optimization/80497
18832         * gimple-ssa-sprintf.c (get_int_range): Avoid assuming all integer
18833         constants are representable in HOST_WIDE_INT.
18834         (parse_directive): Ditto.
18836 2017-04-25  Martin Sebor  <msebor@redhat.com>
18838         PR bootstrap/80486
18839         * dominance.c (dom_info::m_n_basic_blocks): Change type to unsigned.
18840         (new_zero_array): Adjust signature.
18841         (dom_info::dom_init): Used unsigned rather that size_t.
18842         (dom_info::dom_info): Same.
18844 2017-04-25  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
18845             Jakub Jelinek  <jakub@redhat.com>
18847         PR target/77728
18848         * config/arm/arm.c: Include gimple.h.
18849         (aapcs_layout_arg): Emit -Wpsabi note if arm_needs_doubleword_align
18850         returns negative, increment ncrn only if it returned positive.
18851         (arm_needs_doubleword_align): Return int instead of bool,
18852         ignore DECL_ALIGN of non-FIELD_DECL TYPE_FIELDS chain
18853         members, but if there is any such non-FIELD_DECL
18854         > PARM_BOUNDARY aligned decl, return -1 instead of false.
18855         (arm_function_arg): Emit -Wpsabi note if arm_needs_doubleword_align
18856         returns negative, increment nregs only if it returned positive.
18857         (arm_setup_incoming_varargs): Likewise.
18858         (arm_function_arg_boundary): Emit -Wpsabi note if
18859         arm_needs_doubleword_align returns negative, return
18860         DOUBLEWORD_ALIGNMENT only if it returned positive.
18862 2017-04-25  Marek Polacek  <polacek@redhat.com>
18864         PR sanitizer/80349
18865         * fold-const.c (fold_binary_loc) <case BIT_IOR_EXPR>: Convert arg0's
18866         first argument to type.
18868 2017-04-25  Bill Seurer  <seurer@linux.vnet.ibm.com>
18870         PR target/80482
18871         * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin): Change
18872         type checks to test for compatibility instead of equality.
18874 2017-04-25  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
18875             Jakub Jelinek  <jakub@redhat.com>
18877         PR target/77728
18878         * config/aarch64/aarch64.c (struct aarch64_fn_arg_alignment): New
18879         type.
18880         (aarch64_function_arg_alignment): Return aarch64_fn_arg_alignment
18881         struct.  Ignore DECL_ALIGN of decls other than FIELD_DECL for
18882         the alignment computation, but return their maximum in warn_alignment.
18883         (aarch64_layout_arg): Adjust aarch64_function_arg_alignment caller.
18884         Emit a -Wpsabi note if warn_alignment is 16 bytes, but alignment
18885         is smaller.
18886         (aarch64_function_arg_boundary): Likewise.  Simplify using MIN/MAX.
18887         (aarch64_gimplify_va_arg_expr): Adjust aarch64_function_arg_alignment
18888         caller.
18890 2017-04-25  Claudiu Zissulescu  <claziss@synopsys.com>
18892         * config/arc/simdext.md (dmpyh): Fix typo.
18894 2017-04-25  Richard Biener  <rguenther@suse.de>
18896         PR tree-optimization/80492
18897         * alias.c (compare_base_decls): Handle registers with asm
18898         specification conservatively.
18899         * tree-ssa-alias.c (decl_refs_may_alias_p): Handle
18900         compare_base_decls returning dont-know properly.
18902 2017-04-25  Claudiu Zissulescu  <claziss@synopsys.com>
18904         * config/arc/arc.c (LEGITIMATE_OFFSET_ADDRESS_P): Delete macro.
18905         (legitimate_offset_address_p): New function.
18906         (arc_legitimate_address_p): Use above function.
18908 2017-04-25  Claudiu Zissulescu  <claziss@synopsys.com>
18910         * config/arc/arc.c (arc_output_mi_thunk): Emit PIC calls.
18912 2017-04-25  Claudiu Zissulescu  <claziss@synopsys.com>
18914         * config/arc/arc.c (arc_conditional_register_usage): Use ACCL,
18915         ACCH registers whenever they are available.
18917 2017-04-25  Claudiu Zissulescu  <claziss@synopsys.com>
18919         * config/arc/arc.c (arc_conditional_register_usage): Make D0, D1
18920         double regs fix when not used.
18922 2017-04-25  Claudiu Zissulescu  <claziss@synopsys.com>
18924         * config/arc/arc.h (REGNO_OK_FOR_BASE_P): Consider also extension
18925         core registers.
18926         (REG_OK_FOR_INDEX_P_NONSTRICT): Likewise.
18927         (REG_OK_FOR_BASE_P_NONSTRICT): Likewise.
18929 2017-04-25  Claudiu Zissulescu  <claziss@synopsys.com>
18931         * config/arc/arc.c (arc_output_addsi): Check for h-register class
18932         when emitting short ADD instructions.
18934 2017-04-25  Claudiu Zissulescu  <claziss@synopsys.com>
18936         * config/arc/arc.md (cmpsi_cc_insn_mixed): Use 'h' register
18937         constraint.
18938         (cmpsi_cc_c_insn): Likewise.
18939         (cbranchsi4_scratch): Compute proper instruction length using
18940         compact_hreg_operand.
18941         * config/arc/predicates.md (compact_hreg_operand): New predicate.
18943 2017-04-25  Richard Biener  <rguenther@suse.de>
18945         PR middle-end/80509
18946         * passes.c (pass_manager::pass_manager): Initialize
18947         m_name_to_pass_map.
18949 2017-04-25  Richard Biener  <rguenther@suse.de>
18951         PR tree-optimization/79201
18952         * tree-ssa-sink.c (statement_sink_location): Handle calls.
18954 2017-04-25  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
18956         PR target/80464
18957         * config/s390/vector.md: Split MEM->GPR vector moves for
18958         non-s_operand addresses.
18960 2017-04-25  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
18962         PR target/79895
18963         * config/s390/predicates.md (reload_const_wide_int_operand): New
18964         predicate.
18965         * config/s390/s390.md ("movti"): Remove d/P alternative.
18966         ("movti_bigconst"): New pattern definition.
18968 2017-04-25  Dominik Vogt  <vogt@linux.vnet.ibm.com>
18970         PR target/80080
18971         * s390-protos.h (s390_expand_cs_hqi): Removed.
18972         (s390_expand_cs, s390_expand_atomic_exchange_tdsi): New prototypes.
18973         * config/s390/s390.c (s390_emit_compare_and_swap): Handle all integer
18974         modes as well as CCZ1mode and CCZmode.
18975         (s390_expand_atomic_exchange_tdsi, s390_expand_atomic): Adapt to new
18976         signature of s390_emit_compare_and_swap.
18977         (s390_expand_cs_hqi): Likewise, make static.
18978         (s390_expand_cs_tdsi): Generate an explicit compare before trying
18979         compare-and-swap, in some cases.
18980         (s390_expand_cs): Wrapper function.
18981         (s390_expand_atomic_exchange_tdsi): New backend specific expander for
18982         atomic_exchange.
18983         (s390_match_ccmode_set): Allow CCZmode <-> CCZ1 mode.
18984         * config/s390/s390.md ("atomic_compare_and_swap<mode>"): Merge the
18985         patterns for small and large integers.  Forbid symref memory operands.
18986         Move expander to s390.c.  Require cc register.
18987         ("atomic_compare_and_swap<DGPR:mode><CCZZ1:mode>_internal")
18988         ("*atomic_compare_and_swap<TDI:mode><CCZZ1:mode>_1")
18989         ("*atomic_compare_and_swapdi<CCZZ1:mode>_2")
18990         ("*atomic_compare_and_swapsi<CCZZ1:mode>_3"): Use s_operand to forbid
18991         symref memory operands.  Remove CC mode and call s390_match_ccmode
18992         instead.
18993         ("atomic_exchange<mode>"): Allow and implement all integer modes.
18995 2017-04-25  Dominik Vogt  <vogt@linux.vnet.ibm.com>
18997         * config/s390/s390.md (define_peephole2): New peephole to help
18998         combining the load-and-test pattern with volatile memory.
19000 2017-04-25  Dominik Vogt  <vogt@linux.vnet.ibm.com>
19002         * config/s390/s390.md ("cstorecc4"): Use load-on-condition and deal
19003         with CCZmode for TARGET_Z196.
19005 2017-04-25  Jakub Jelinek  <jakub@redhat.com>
19007         PR rtl-optimization/80501
19008         * combine.c (make_compound_operation_int): Set subreg_code to SET
19009         even for AND with mask of the sign bit of mode.
19011         PR rtl-optimization/80500
19012         * loop-unroll.c (combine_var_copies_in_loop_exit): Call copy_rtx on
19013         sum's initial value.
19015 2017-04-25  Julian Brown  <julian@codesourcery.com>
19016             Naveen H.S  <Naveen.Hurugalawadi@cavium.com>
19018         * config/aarch64/thunderx2t99.md (thunderx2t99_crc): New Reservation.
19020 2017-04-25  Marc Glisse  <marc.glisse@inria.fr>
19022         * fold-const.c (tree_single_nonzero_warnv_p): Handle SSA_NAME.
19024 2017-04-25  Julian Brown  <julian@codesourcery.com>
19025             Naveen H.S  <Naveen.Hurugalawadi@cavium.com>
19027         * config/aarch64/thunderx2t99.md (thunderx2t99_aes): New Reservation.
19028         (thunderx2t99_sha): New Reservation.
19030 2017-04-25  Julian Brown  <julian@codesourcery.com>
19031             Naveen H.S  <Naveen.Hurugalawadi@cavium.com>
19033         * config/aarch64/aarch64-simd.md (aarch64_simd_vec_set<mode>): Fix
19034         type for 1-element load.
19036 2017-04-24  Marc Glisse  <marc.glisse@inria.fr>
19038         * match.pd (X/[ex]C CMP Y/[ex]C): New transformation.
19040 2017-04-24  Martin Jambor  <mjambor@suse.cz>
19042         PR tree-optimization/80293
19043         * tree-sra.c (scalarizable_type_p): New parameter const_decl, make
19044         char arrays not totally scalarizable if it is false.
19045         (analyze_all_variable_accesses): Pass correct value in the new
19046         parameter.  Add a statistics counter.
19048 2017-04-24  Jan Hubicka  <hubicka@ucw.cz>
19050         PR middle-end/79931
19051         * ipa-devirt.c (dump_possible_polymorphic_call_targets): Fix ICE.
19053 2017-04-24  Richard Biener  <rguenther@suse.de>
19055         PR tree-optimization/80494
19056         * tree-scalar-evolution.c (analyze_scalar_evolution_1): Bail
19057         out for complex types.
19059 2017-04-24  Richard Biener  <rguenther@suse.de>
19061         * tree-ssa-sccvn.h (run_scc_vn): Adjust prototype.
19062         * tree-ssa-sccvn.c (print_scc): Print SCC size.
19063         (extract_and_process_scc_for_name): Never fail but drop SCC to varying.
19064         (DFS): Adjust and never fail.
19065         (sccvn_dom_walker::fail): Remove.
19066         (sccvn_dom_walker::before_dom_children): Adjust.
19067         (run_scc_vn): Likewise and never fail.
19068         * tree-ssa-pre.c (pass_pre::execute): Adjust.
19069         (pass_fre::execute): Likewise.
19071 2017-04-24  Richard Biener  <rguenther@suse.de>
19073         PR tree-optimization/79725
19074         * tree-ssa-sink.c (statement_sink_location): Return whether
19075         failure reason was zero uses.  Move that check later.
19076         (sink_code_in_bb): Deal with zero uses by removing the stmt
19077         if possible.
19079 2017-04-24  Richard Biener  <rguenther@suse.de>
19081         PR c++/2972
19082         * tree-ssa-uninit.c (warn_uninitialized_vars): Handle some
19083         pointer-based references.
19085 2017-04-24  Richard Biener  <rguenther@suse.de>
19087         PR bootstrap/79814
19088         * pass_manager.h (pass_manager::operator new): Remove.
19089         (pass_manager::operator delete): Likewise.
19090         * passes.c (pass_manager::operator new): Remove.
19091         (pass_manager::operator delete): Likewise.
19092         (pass_manager::pass_manager): Zero individual pass members.
19094 2017-04-23  Uros Bizjak  <ubizjak@gmail.com>
19096         PR target/70799
19097         * config/i386/i386.c (dimode_scalar_to_vector_candidate_p)
19098         <case ASHIFT, case LSHIFTRT>: Also consider variable shifts.
19099         Check "XEXP (src, 1)" operand here.
19100         <case PLUS, case MINUS, case IOR, case XOR, case AND>:
19101         Check "XEXP (src, 1)" operand here.
19102         (dimode_scalar_chain::make_vector_copies): Detect count register
19103         of a shift instruction.  Zero extend count register from QImode
19104         to DImode to satisfy vector shift pattern count operand predicate.
19105         Substitute vector shift count operand with a DImode copy.
19106         (dimode_scalar_chain::convert_reg): Ditto, zero-extend from
19107         vector register.
19109 2017-04-21  Uros Bizjak  <ubizjak@gmail.com>
19111         * config/i386/i386.md (*extzvqi_mem_rex64): Move above *extzv<mode>.
19112         Remove UNSPEC_NOREX_MEM tag.  Update corresponding peephole2 pattern.
19113         (*insvqi_1_mem_rex64): Move above insv<mode>_1.  Remove
19114         UNSPEC_NOREX_MEM tag.  Update corresponding peephole2 pattern.
19115         (UNSPEC_NOREX_MEM): Remove definition.
19117 2017-04-21  Richard Biener  <rguenther@suse.de>
19119         PR tree-optimization/79547
19120         * tree-ssa-structalias.c (find_func_aliases_for_builtin_call):
19121         Handle strlen, strcmp, strncmp, strcasecmp, strncasecmp, memcmp,
19122         bcmp, strspn, strcspn, __builtin_object_size and __builtin_constant_p
19123         without any constraints.
19125 2017-04-21  Richard Biener  <rguenther@suse.de>
19127         PR tree-optimization/78847
19128         * fold-const.c (split_tree): Handle POINTER_PLUS_EXPR.
19130 2017-04-21  Richard Biener  <rguenther@suse.de>
19132         * tree.h (build_qualified_type): Annotate with CXX_MEM_STAT_INFO.
19133         (build_distinct_type_copy): Likewise.
19134         (build_variant_type_copy): Likewise.
19135         * tree.c (build_qualified_type): Pass down mem-stat info.
19136         (build_distinct_type_copy): Likewise.
19137         (build_variant_type_copy): Likewise.
19139 2017-04-21  Richard Biener  <rguenther@suse.de>
19141         PR tree-optimization/80237
19142         * tree-ssa-pre.c (find_leader_in_sets): Add third set argument,
19143         defaulted to NULL.
19144         (phi_translate_1): Also allow a leader in AVAIL_OUT of pred
19145         for a simplified result.
19147 2016-04-21  Richard Biener  <rguenther@suse.de>
19149         * tree-ssa-loop-ivcanon.c (constant_after_peeling): Do not require
19150         sth as strict as a simple_iv but a chrec without symbols and an
19151         operand defined in the loop we are peeling (and not some subloop).
19152         (propagate_constants_for_unrolling): Propagate all constants.
19154 2017-04-20  Uros Bizjak  <ubizjak@gmail.com>
19156         PR target/79804
19157         * config/i386/i386.c (print_reg): Remove assert for disalowed
19158         regno values, call output_operand_lossage instead.
19160 2017-04-20  Uros Bizjak  <ubizjak@gmail.com>
19162         PR target/78090
19163         * config/i386/constraints.md (Yc): New register constraint.
19164         * config/i386/i386.md (*float<SWI48:mode><MODEF:mode>2_mixed):
19165         Use Yc constraint for alternative 2 of operand 0.  Remove
19166         preferred_for_speed attribute.
19168 2017-04-20  Alexander Monakov  <amonakov@ispras.ru>
19170         * omp-low.c (lower_lastprivate_clauses): Correct handling of linear and
19171         lastprivate clauses in SIMT case.
19173 2017-04-20  Volker Reichelt  <v.reichelt@netcologne.de>
19175         * doc/invoke.texi (-Wextra-semi): Document new warning option.
19177 2017-04-20  Richard Biener  <rguenther@suse.de>
19179         PR tree-optimization/57796
19180         * tree-vect-stmts.c (vect_model_store_cost): Cost scatters
19181         as N scalar stores.
19182         (vect_model_load_cost): Cost gathers as N scalar loads.
19184 2017-04-20  Richard Biener  <rguenther@suse.de>
19186         * ggc-page.c (ggc_allocated_p): Rename to ...
19187         (safe_lookup_page_table_entry): ... this and return the lookup
19188         result.
19189         (gt_ggc_m_S): Use safe_lookup_page_table_entry.
19191 2017-04-20  Richard Biener  <rguenther@suse.de>
19193         PR tree-optimization/80453
19194         * tree-ssa-sccvn.h (struct vn_phi_s): Add cclhs and ccrhs members.
19195         * tree-ssa-sccvn.c (cond_stmts_equal_p): Use recorded lhs and rhs
19196         from the conditions.
19197         (vn_phi_eq): Pass them down.
19198         (vn_phi_lookup): Record them.
19199         (vn_phi_insert): Likewise.
19201 2017-04-20  Matthew Fortune  <matthew.fortune@imgtec.com>
19203         * config/mips/mips.c (mips_expand_vec_perm_const): Re-fix
19204         uninitialized variable warning to avoid buffer overrun.
19206 2017-04-20  Alexander Monakov  <amonakov@ispras.ru>
19208         PR other/71250
19209         * doc/invoke.texi (-Wmissing-field-initializers): Mention that warning
19210         is suppressed for '{ 0 }' in C.
19212 2017-04-20  Jakub Jelinek  <jakub@redhat.com>
19214         * BASE-VER: Set to 8.0.0.
19216 2017-04-20  Thomas Preud'homme  <thomas.preudhomme@arm.com>
19218         * config/arm/arm.c (arm_elf_asm_cdtor): Create non-default
19219         priority .init_array and .fini_array section with SECTION_NOTYPE
19220         flag.
19222 2017-04-20  Jakub Jelinek  <jakub@redhat.com>
19224         PR middle-end/80423
19225         * tree.h (build_array_type): Add typeless_storage default argument.
19226         * tree.c (type_cache_hasher::equal): Also compare
19227         TYPE_TYPELESS_STORAGE flag for ARRAY_TYPEs.
19228         (build_array_type): Add typeless_storage argument, set
19229         TYPE_TYPELESS_STORAGE to it, if shared also hash it, and pass to
19230         recursive call.
19231         (build_nonshared_array_type): Adjust build_array_type_1 caller.
19232         (build_array_type): Likewise.  Add typeless_storage argument.
19234 2017-04-19  Eric Botcazou  <ebotcazou@adacore.com>
19235             Jakub Jelinek  <jakub@redhat.com>
19237         PR tree-optimization/80426
19238         * tree-vrp.c (extract_range_from_binary_expr_1): For an additive
19239         operation on symbolic operands, also compute the overflow for the
19240         invariant part when the operation degenerates into a negation.
19242 2017-04-19  Jakub Jelinek  <jakub@redhat.com>
19244         PR debug/80461
19245         * dwarf2out.c (modified_type_die, gen_type_die_with_usage):
19246         Check for t with zero TYPE_QUALS_NO_ADDR_SPACE.
19248         PR debug/80436
19249         * tree-ssa-loop-manip.c (find_uses_to_rename_def): Ignore debug uses.
19251 2017-04-19  Georg-Johann Lay  <avr@gjlay.de>
19253         PR target/80462
19254         * config/avr/avr.c (tree.h): Include it.
19255         (cgraph.h): Include it.
19256         (avr_encode_section_info): Don't warn for uninitialized progmem
19257         variable if it's just an alias.
19259 2017-04-19  Richard Biener  <rguenther@suse.de>
19261         PR ipa/65972
19262         * auto-profile.c (afdo_vpt_for_early_inline): Update SSA
19263         when needed by AutoPGO.
19265 2017-04-19  Paulo J. Matos  <paulo@matos-sorge.com>
19267         PR lto/50345
19268         * doc/lto.texi: Remove an extra 'that'.
19270 2017-04-19  Segher Boessenkool  <segher@kernel.crashing.org>
19272         PR rtl-optimization/80429
19273         * ira.c (split_live_ranges_for_shrink_wrap): Don't split regs that
19274         are only used in debug insns.
19276 2017-04-19  Eric Botcazou  <ebotcazou@adacore.com>
19277             Vladimir Makarov  <vmakarov@redhat.com>
19279         * config/sparc/predicates.md (input_operand): Add comment.  Return
19280         true for any memory operand when LRA is in progress.
19281         * config/sparc/sparc.c (sparc_expand_move): Minor formatting fix.
19283 2017-04-18  Jeff Law  <law@redhat.com>
19285         PR target/74563
19286         * mips.md ({return,simple_return}_internal): Do not overwrite
19287         operands[0].
19289 2017-04-18  Jakub Jelinek  <jakub@redhat.com>
19291         PR tree-optimization/80443
19292         * tree-vrp.c (intersect_ranges): For signed 1-bit precision type,
19293         instead of adding 1, subtract -1 and similarly instead of subtracting
19294         1 add -1.
19296 2017-04-18  Richard Sandiford  <richard.sandiford@arm.com>
19298         PR rtl-optimization/80357
19299         * haifa-sched.c (tmp_bitmap): New variable.
19300         (model_recompute): Handle duplicate use records.
19301         (alloc_global_sched_pressure_data): Initialize tmp_bitmap.
19302         (free_global_sched_pressure_data): Free it.
19304 2017-04-18  Bernd Edlinger  <bernd.edlinger@hotmail.de>
19306         Revert:
19307         2017-02-20  Bernd Edlinger  <bernd.edlinger@hotmail.de>
19308         * Makefile.in (BUILD_SYSTEM_HEADER_DIR): New make variabe.
19309         (LIMITS_H_TEST, if_multiarch, stmp-fixinc): Use BUILD_SYSTEM_HEADER_DIR
19310         instead of SYSTEM_HEADER_DIR.
19312 2017-04-18  Jeff Law  <law@redhat.com>
19314         PR middle-end/80422
19315         * cfgcleanup.c (try_crossjump_to_edge): Verify SRC1 and SRC2 have
19316         predecessors after walking up the insn chain.
19318 2017-04-18  Jakub Jelinek  <jakub@redhat.com>
19320         PR debug/80263
19321         * dwarf2out.c (modified_type_die): Try harder not to emit internal
19322         sizetype type into debug info.
19324 2017-04-18  Michael Meissner  <meissner@linux.vnet.ibm.com>
19326         PR target/80099
19327         * config/rs6000/rs6000.c (rs6000_expand_vector_extract): Eliminate
19328         unneeded test for TARGET_UPPER_REGS_SF.
19329         * config/rs6000/vsx.md (vsx_extract_v4sf_var): Likewise.
19331 2017-04-18  Jakub Jelinek  <jakub@redhat.com>
19333         PR sanitizer/80444
19334         * sancov.c (sancov_pass): Use gsi_start_nondebug_after_labels_bb
19335         instead of gsi_after_labels.
19337 2017-04-18  Jeff Law  <law@redhat.com>
19339         * regcprop.c (maybe_mode_change): Avoid creating copies of the
19340         stack pointer.
19342         Revert:
19343         2017-04-13  Jeff Law  <law@redhat.com>
19344         * config/mips.mips.md (zero_extendsidi2): Do not allow SP to appear
19345         in operands[1] if it is a MEM and TARGET_MIPS16 is active.
19347 2017-04-18  Georg-Johann Lay  <avr@gjlay.de>
19349         PR target/79453
19350         * config/avr/avr.c (intl.h): Include it.
19351         (avr_pgm_check_var_decl) [reason]: Wrap diagnostic snippets into _().
19353 2017-04-18  Martin Liska  <mliska@suse.cz>
19355         PR gcov-profile/78783
19356         * gcov-tool.c (gcov_output_files): Validate that destination
19357         file is either removed by the tool or by a user.
19359 2017-04-14  Andrew Burgess  <andrew.burgess@embecosm.com>
19360             Guy Benyei  <guybe@mellanox.com>
19362         * config/arc/arc.c (arc_reorg): Move loop_end_id into a more local
19363         block, and do not negate it, the stored id is already negative.
19365 2017-04-14  Andrew Burgess  <andrew.burgess@embecosm.com>
19367         * config/arc/arc.md (doloop_begin_i): Use @pcl assembler syntax.
19369 2017-04-14  Michael Meissner  <meissner@linux.vnet.ibm.com>
19371         PR target/80098
19372         * config/rs6000/rs6000-cpus.def (OTHER_P9_VECTOR_MASKS): Define
19373         masks of options that should be turned off if the VSX vector
19374         options are turned off.
19375         (OTHER_P8_VECTOR_MASKS): Likewise.
19376         (OTHER_VSX_VECTOR_MASKS): Likewise.
19377         * config/rs6000/rs6000.c (rs6000_option_override_internal): Call
19378         rs6000_disable_incompatible_switches to validate no type switches
19379         like -mvsx.
19380         (rs6000_incompatible_switch): New function to disallow turning on
19381         other vector options if -mno-vsx, -mno-power8-vector, or
19382         -mno-power9-vector are specified.
19384 2017-04-14  Claudiu Zissulescu  <claziss@synopsys.com>
19386         * config/arc/arc.h (CRT_CALL_STATIC_FUNCTION): Use long calls.
19388 2017-04-14  Claudiu Zissulescu  <claziss@synopsys.com>
19390         * config/arc/arc-protos.h (arc_decl_pretend_args): Remove.
19391         * config/arc/arc.c (arc_decl_pretend_args): Likewise.
19392         * config/arc/arc.h (CFA_FRAME_BASE_OFFSET): Likewise.
19393         (ARG_POINTER_CFA_OFFSET): Likewise.
19395 2017-04-14  Claudiu Zissulescu  <claziss@synopsys.com>
19397         * config/arc/arc.c (arc_mode_dependent_address_p): Relax
19398         conditions to take advantage of various optimizations.
19400 2017-04-13  Jeff Law  <law@redhat.com>
19402         * config/mips.mips.md (zero_extendsidi2): Do not allow SP to appear
19403         in operands[1] if it is a MEM and TARGET_MIPS16 is active.
19404         (zero_extendsidi2_dext): Likewise.
19406 2017-04-13  Jakub Jelinek  <jakub@redhat.com>
19408         PR sanitizer/80403
19409         * fold-const.c (fold_ternary_loc): Revert
19410         use op0 instead of fold_convert_loc (loc, type, arg0) part of
19411         2017-04-12 change.
19413 2017-04-13  Vladimir Makarov  <vmakarov@redhat.com>
19415         PR rtl-optimization/80343
19416         * lra-remat.c (update_scratch_ops): Assign original hard reg to
19417         new scratch pseudo.
19419 2017-04-13  Denis Khalikov <d.khalikov@partner.samsung.com>
19421         PR sanitizer/80414
19422         * ubsan.c (ubsan_expand_bounds_ifn): Pass original index
19423         to ubsan_encode_value.
19425 2017-04-13  Jeff Law  <law@redhat.com>
19427         * reload1.c (eliminate_regs_1): Call gen_rtx_raw_SUBREG for SUBREGs
19428         appearing in DEBUG_INSNs.
19430 2017-04-13  Martin Liska  <mliska@suse.cz>
19432         PR gcov-profile/80413
19433         * gcov-io.c (gcov_write_string): Copy to buffer just when
19434         allocated size is greater than zero.
19436 2017-04-13  Jakub Jelinek  <jakub@redhat.com>
19438         PR debug/80321
19439         * dwarf2out.c (decls_for_scope): Ignore declarations of
19440         current_function_decl in BLOCK_NONLOCALIZED_VARS.
19442 2017-04-12  Jan Hubicka  <hubicka@ucw.cz>
19444         PR lto/69953
19445         * ipa-visibility.c (non_local_p): Fix typos.
19446         (localize_node): When localizing symbol in same comdat group,
19447         dissolve the group only when we know external symbols are going
19448         to be privatized.
19449         (function_and_variable_visibility): Do not localize DECL_EXTERNAL.
19451 2017-04-12  Jakub Jelinek  <jakub@redhat.com>
19453         PR tree-optimization/79390
19454         * optabs.c (emit_conditional_move): If the preferred op2/op3 operand
19455         order does not result in usable sequence, retry with reversed operand
19456         order.
19458         PR sanitizer/80403
19459         PR sanitizer/80404
19460         PR sanitizer/80405
19461         * fold-const.c (fold_ternary_loc): Use op1 instead of arg1 as argument
19462         to fold_build2_loc.  Convert TREE_OPERAND (tem, 0) to type.  Use
19463         op0 instead of fold_convert_loc (loc, type, arg0).
19465 2017-04-12  Jeff Law  <law@redhat.com>
19467         * genattrtab.c (write_eligible_delay): Verify DELAY_INSN still
19468         has a delay slot in the generated code.
19470         * config/cris/cris.md (cris_preferred_reload_class): Return
19471         GENNONACR_REGS rather than GENERAL_REGS.
19473 2017-04-12  Jakub Jelinek  <jakub@redhat.com>
19475         PR c/80163
19476         * expr.c <CASE_CONVERT>: For EXPAND_INITIALIZER determine SIGN_EXTEND
19477         vs. ZERO_EXTEND based on signedness of treeop0's type rather than
19478         signedness of the result type.
19480 2017-04-12  Richard Biener  <rguenther@suse.de>
19481             Jeff Law  <law@redhat.com>
19483         PR tree-optimization/80359
19484         * tree-ssa-dse.c (maybe_trim_partially_dead_store): Do not
19485         trim stores to TARGET_MEM_REFs.
19487 2017-04-12  Richard Biener  <rguenther@suse.de>
19489         PR tree-optimization/79390
19490         * gimple-ssa-split-paths.c (is_feasible_trace): Restrict
19491         threading case even more.
19493 2017-04-12  Segher Boessenkool  <segher@kernel.crashing.org>
19495         PR target/80382
19496         * config/rs6000/sync.md (atomic_load<mode>, atomic_store<mode): Test
19497         for quad_address_p for TImode, instead of just not indexed_address.
19499 2017-04-12  Richard Biener  <rguenther@suse.de>
19500             Bernd Edlinger  <bernd.edlinger@hotmail.de>
19502         PR middle-end/79671
19503         * alias.c (component_uses_parent_alias_set_from): Handle
19504         TYPE_TYPELESS_STORAGE.
19505         (get_alias_set): Likewise.
19506         * tree-core.h (tree_type_common): Add typeless_storage flag.
19507         * tree.h (TYPE_TYPELESS_STORAGE): New macro.
19508         * stor-layout.c (place_union_field): Set TYPE_TYPELESS_STORAGE
19509         for types containing members with TYPE_TYPELESS_STORAGE.
19510         (place_field): Likewise.
19511         (layout_type): Likewise for ARRAY_TYPE.
19512         * lto-streamer-out.c (hash_tree): Hash TYPE_TYPELESS_STORAGE.
19513         * tree-streamer-in.c (unpack_ts_type_common_value_fields): Stream
19514         TYPE_TYPELESS_STORAGE.
19515         * tree-streamer-out.c (pack_ts_type_common_value_fields): Likewise.
19517 2017-04-12  Jakub Jelinek  <jakub@redhat.com>
19519         PR sanitizer/80349
19520         * fold-const.c (fold_binary_loc) <case BIT_IOR_EXPR>: Convert arg0's
19521         first argument to type.
19523 2017-04-11  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
19525         PR target/80376
19526         PR target/80315
19527         * config/rs6000/rs6000.c (rs6000_expand_unop_builtin): Return
19528         CONST0_RTX (mode) rather than const0_rtx where appropriate.
19529         (rs6000_expand_binop_builtin): Likewise.
19530         (rs6000_expand_ternop_builtin): Likewise; also add missing
19531         vsx_xxpermdi_* variants; also fix typo (arg1 => arg2) for
19532         vshasigma built-ins.
19533         * doc/extend.texi: Document that vec_xxpermdi's third argument
19534         must be a constant.
19536 2017-04-11  Uros Bizjak  <ubizjak@gmail.com>
19538         * config/i386/i386.c (dimode_scalar_chain::compute_convert_gain):
19539         Use shift_const cost parameter when calculating gain of STV shifts.
19541 2017-04-11  Vladimir Makarov  <vmakarov@redhat.com>
19543         PR rtl-optimization/70478
19544         * lra-constraints.c (process_alt_operands): Check memory for
19545         disfavoring memory insn operand.
19547 2017-04-11  Jakub Jelinek  <jakub@redhat.com>
19549         PR middle-end/80100
19550         * simplify-rtx.c (simplify_binary_operation_1) <case IOR>: Perform
19551         left shift in unsigned HOST_WIDE_INT type.
19553         PR rtl-optimization/80385
19554         * simplify-rtx.c (simplify_unary_operation_1): Don't transform
19555         (not (neg X)) into (plus X -1) for complex or non-integral modes.
19557         PR libgomp/80394
19558         * omp-low.c (scan_omp_task): Don't optimize away empty tasks
19559         if they have any depend clauses.
19561 2017-04-11  Martin Liska  <mliska@suse.cz>
19563         PR ipa/80212
19564         * cgraph.c (cgraph_node::dump): Dump calls_comdat_local.
19565         * ipa-split.c (split_function): Create a local comdat symbol
19566         if caller is in a comdat group.
19568 2017-04-11  Martin Liska  <mliska@suse.cz>
19570         PR ipa/80212
19571         * ipa-cp.c (determine_versionability): Handle calls_comdat_local
19572         flags.
19574 2017-04-11  Martin Sebor  <msebor@redhat.com>
19576         PR middle-end/80364
19577         * gimple-ssa-sprintf.c (get_int_range): Remove second argument and
19578         always use the int type.  Use INTEGRAL_TYPE_P() rather than testing
19579         for INTEGER_TYPE.
19580         (directive::set_width, directive::set_precision, format_character):
19581         Adjust.
19582         (parse_directive): Use INTEGRAL_TYPE_P() rather than testing for
19583         INTEGER_TYPE.
19585 2017-04-11  Richard Earnshaw  <rearnsha@arm.com>
19587         PR target/80389
19588         * config/arm/arm.c (arm_configure_build_target): When -mcpu and -arch
19589         conflict, set target->arch_name instead of target->cpu_name.
19591 2017-04-11  Richard Biener  <rguenther@suse.de>
19593         PR tree-optimization/80374
19594         * tree-ssa-dom.c (derive_equivalences_from_bit_ior): Use
19595         build_zero_cst, remove fold_convertible_p check again.
19597 2017-04-11  Martin Liska  <mliska@suse.cz>
19599         PR sanitizer/70878
19600         * ubsan.c (instrument_object_size): Do not instrument register
19601         variables.
19603 2017-04-11  Jakub Jelinek  <jakub@redhat.com>
19605         PR target/80381
19606         * config/i386/i386-builtin-types.def
19607         (V16HI_FTYPE_V16HI_INT_V16HI_UHI_COUNT,
19608         V16HI_FTYPE_V16HI_V8HI_V16HI_UHI_COUNT,
19609         V16SI_FTYPE_V16SI_INT_V16SI_UHI_COUNT,
19610         V16SI_FTYPE_V16SI_V4SI_V16SI_UHI_COUNT,
19611         V2DI_FTYPE_V2DI_INT_V2DI_UQI_COUNT,
19612         V2DI_FTYPE_V2DI_V2DI_V2DI_UQI_COUNT,
19613         V32HI_FTYPE_V32HI_INT_V32HI_USI_COUNT,
19614         V32HI_FTYPE_V32HI_V8HI_V32HI_USI_COUNT,
19615         V4DI_FTYPE_V4DI_INT_V4DI_UQI_COUNT,
19616         V4DI_FTYPE_V4DI_V2DI_V4DI_UQI_COUNT,
19617         V4SI_FTYPE_V4SI_INT_V4SI_UQI_COUNT,
19618         V4SI_FTYPE_V4SI_V4SI_V4SI_UQI_COUNT,
19619         V8DI_FTYPE_V8DI_INT_V8DI_UQI_COUNT,
19620         V8DI_FTYPE_V8DI_V2DI_V8DI_UQI_COUNT,
19621         V8HI_FTYPE_V8HI_INT_V8HI_UQI_COUNT,
19622         V8HI_FTYPE_V8HI_V8HI_V8HI_UQI_COUNT,
19623         V8SI_FTYPE_V8SI_INT_V8SI_UQI_COUNT,
19624         V8SI_FTYPE_V8SI_V4SI_V8SI_UQI_COUNT): New function type aliases.
19625         * config/i386/i386-builtin.def (__builtin_ia32_pslld512_mask,
19626         __builtin_ia32_pslldi512_mask, __builtin_ia32_psllq512_mask,
19627         __builtin_ia32_psllqi512_mask, __builtin_ia32_psrad512_mask,
19628         __builtin_ia32_psradi512_mask, __builtin_ia32_psraq512_mask,
19629         __builtin_ia32_psraqi512_mask, __builtin_ia32_psrld512_mask,
19630         __builtin_ia32_psrldi512_mask, __builtin_ia32_psrlq512_mask,
19631         __builtin_ia32_psrlqi512_mask, __builtin_ia32_psllwi128_mask,
19632         __builtin_ia32_pslldi128_mask, __builtin_ia32_psllqi128_mask,
19633         __builtin_ia32_psllw128_mask, __builtin_ia32_pslld128_mask,
19634         __builtin_ia32_psllq128_mask, __builtin_ia32_psllwi256_mask,
19635         __builtin_ia32_psllw256_mask, __builtin_ia32_pslldi256_mask,
19636         __builtin_ia32_pslld256_mask, __builtin_ia32_psllqi256_mask,
19637         __builtin_ia32_psllq256_mask, __builtin_ia32_psradi128_mask,
19638         __builtin_ia32_psrad128_mask, __builtin_ia32_psradi256_mask,
19639         __builtin_ia32_psrad256_mask, __builtin_ia32_psraqi128_mask,
19640         __builtin_ia32_psraq128_mask, __builtin_ia32_psraqi256_mask,
19641         __builtin_ia32_psraq256_mask, __builtin_ia32_psrldi128_mask,
19642         __builtin_ia32_psrld128_mask, __builtin_ia32_psrldi256_mask,
19643         __builtin_ia32_psrld256_mask, __builtin_ia32_psrlqi128_mask,
19644         __builtin_ia32_psrlq128_mask, __builtin_ia32_psrlqi256_mask,
19645         __builtin_ia32_psrlq256_mask, __builtin_ia32_psrawi256_mask,
19646         __builtin_ia32_psraw256_mask, __builtin_ia32_psrawi128_mask,
19647         __builtin_ia32_psraw128_mask, __builtin_ia32_psrlwi256_mask,
19648         __builtin_ia32_psrlw256_mask, __builtin_ia32_psrlwi128_mask,
19649         __builtin_ia32_psrlw128_mask, __builtin_ia32_psllwi512_mask,
19650         __builtin_ia32_psllw512_mask, __builtin_ia32_psrawi512_mask,
19651         __builtin_ia32_psraw512_mask, __builtin_ia32_psrlwi512_mask,
19652         __builtin_ia32_psrlw512_mask): Use _COUNT suffixed function type
19653         aliases.
19654         * config/i386/i386.c (ix86_expand_args_builtin): Rename last_arg_count
19655         flag to second_arg_count, handle 4 argument function type _COUNT
19656         aliases, handle second_arg_count on second argument rather than last.
19658 2017-04-10  Jeff Law  <law@redhat.com>
19660         PR tree-optimization/80374
19661         * tree-ssa-dom.c (derive_equivalences_from_bit_ior): Do not try to
19662         record anything if we can not convert integer_zero_node to the
19663         desired type.
19665 2017-04-10  Kelvin Nilsen  <kelvin@gcc.gnu.org>
19667         PR target/80108
19668         * config/rs6000/rs6000.c (rs6000_option_override_internal):
19669         Enhance special handling given to the TARGET_P9_MINMAX option in
19670         relation to certain other options.
19672 2017-04-10  Bin Cheng  <bin.cheng@arm.com>
19674         PR tree-optimization/80153
19675         * tree-ssa-loop-ivopts.c (add_iv_candidate_for_use): Check and
19676         remove POINTER_PLUS_EXPR's base part directly, rather than through
19677         aff_tree.
19679 2017-04-10  Richard Biener  <rguenther@suse.de>
19680             Bin Cheng  <bin.cheng@arm.com>
19682         PR tree-optimization/80153
19683         * tree-affine.c (aff_combination_to_tree): Get base pointer from
19684         the first element of pointer type aff_tree.  Build result expr in
19685         aff_tree's type.
19686         (add_elt_to_tree): Convert to type unconditionally.  Remove other
19687         fold_convert calls.
19688         * tree-ssa-loop-ivopts.c (alloc_iv): Pass in consistent types.
19689         (rewrite_use_nonlinear_expr): Check invariant using iv information.
19691 2017-04-10  Richard Biener  <rguenther@suse.de>
19693         * tree-ssa-structalias.c (find_func_aliases): Properly handle
19694         asm inputs.
19696 2017-04-10  Vladimir Makarov  <vmakarov@redhat.com>
19698         PR rtl-optimization/70478
19699         * lra-constraints.c (curr_small_class_check): New.
19700         (update_and_check_small_class_inputs): New.
19701         (process_alt_operands): Update curr_small_class_check.  Disfavor
19702         alternative insn memory operands.  Check available regs for small
19703         class operands.
19705 2017-03-31  Matthew Fortune  <matthew.fortune@imgtec.com>
19707         PR target/80057
19708         * config/mips/mips.opt (-mvirt): Update description.
19709         * doc/invoke.texi (-mvirt): Likewise.
19711 2017-04-10  Richard Biener  <rguenther@suse.de>
19713         PR middle-end/80362
19714         * fold-const.c (fold_binary_loc): Look at unstripped ops when
19715         looking for NEGATE_EXPR in -A / -B to A / B folding.
19717 2017-04-10  Martin Liska  <mliska@suse.cz>
19719         PR gcov-profile/80224
19720         * gcov.c (print_usage): Fix usage string.
19721         (get_gcov_intermediate_filename): Remove.
19722         (output_gcov_file): Use both for normal and intermediate format.
19723         (generate_results): Do not initialize special file for
19724         intermediate format.
19726 2017-04-10  Richard Biener  <rguenther@suse.de>
19728         PR tree-optimization/80304
19729         * tree-ssa-loop-im.c (ref_indep_loop_p_1): Also recurse
19730         for safelen.
19732 2017-04-10  Nathan Sidwell  <nathan@acm.org>
19734         PR target/79905
19735         * config/rs6000/rs6000.c (rs6000_vector_type): New.
19736         (rs6000_init_builtins): Use it.
19738 2016-04-10  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
19740         * config/arm/arm.md (<mrc>): Add mode to SET source.
19741         (<mrrc>): Likewise.
19743 2017-04-10  Richard Biener  <rguenther@suse.de>
19745         PR middle-end/80344
19746         * gimplify.c (is_gimple_mem_rhs_or_call): Allow CLOBBERs.
19748 2017-04-10  Jakub Jelinek  <jakub@redhat.com>
19750         PR target/80324
19751         * config/i386/avx512fintrin.h (_mm512_reduce_add_epi32,
19752         _mm512_reduce_mul_epi32, _mm512_reduce_and_epi32,
19753         _mm512_reduce_or_epi32, _mm512_mask_reduce_add_epi32,
19754         _mm512_mask_reduce_mul_epi32, _mm512_mask_reduce_and_epi32,
19755         _mm512_mask_reduce_or_epi32, _mm512_reduce_min_epi32,
19756         _mm512_reduce_max_epi32, _mm512_reduce_min_epu32,
19757         _mm512_reduce_max_epu32, _mm512_mask_reduce_min_epi32,
19758         _mm512_mask_reduce_max_epi32, _mm512_mask_reduce_min_epu32,
19759         _mm512_mask_reduce_max_epu32, _mm512_reduce_add_ps,
19760         _mm512_reduce_mul_ps, _mm512_mask_reduce_add_ps,
19761         _mm512_mask_reduce_mul_ps, _mm512_reduce_min_ps, _mm512_reduce_max_ps,
19762         _mm512_mask_reduce_min_ps, _mm512_mask_reduce_max_ps,
19763         _mm512_reduce_add_epi64, _mm512_reduce_mul_epi64,
19764         _mm512_reduce_and_epi64, _mm512_reduce_or_epi64,
19765         _mm512_mask_reduce_add_epi64, _mm512_mask_reduce_mul_epi64,
19766         _mm512_mask_reduce_and_epi64, _mm512_mask_reduce_or_epi64,
19767         _mm512_reduce_min_epi64, _mm512_reduce_max_epi64,
19768         _mm512_mask_reduce_min_epi64, _mm512_mask_reduce_max_epi64,
19769         _mm512_reduce_min_epu64, _mm512_reduce_max_epu64,
19770         _mm512_mask_reduce_min_epu64, _mm512_mask_reduce_max_epu64,
19771         _mm512_reduce_add_pd, _mm512_reduce_mul_pd, _mm512_mask_reduce_add_pd,
19772         _mm512_mask_reduce_mul_pd, _mm512_reduce_min_pd, _mm512_reduce_max_pd,
19773         _mm512_mask_reduce_min_pd, _mm512_mask_reduce_max_pd): New intrinsics.
19775 2017-04-08  Vladimir Makarov  <vmakarov@redhat.com>
19777         PR rtl-optimization/70478
19778         * lra-constraints.c: Reverse the last patch.
19780 2017-04-08  Andreas Tobler  <andreast@gcc.gnu.org>
19782         * config/aarch64/aarch64-freebsd.h: Define MCOUNT_NAME.
19783         Add comment for WCHAR_T.
19785 2017-04-08  Martin Liska  <mliska@suse.cz>
19787         Revert:
19788         2017-04-07  Martin Liska  <mliska@suse.cz>
19790         PR ipa/80212
19791         * ipa-split.c (split_function): Add function part to a same comdat
19792         group.
19794 2017-04-08  Aaron Sawdey  <acsawdey@linux.vnet.ibm.com>
19796         PR target/80358
19797         * config/rs6000/rs6000.c (expand_block_compare): Fix boundary check.
19799 2017-04-07  Pat Haugen  <pthaugen@us.ibm.com>
19801         * rs6000/rs6000.c (vec_load_pendulum): Rename...
19802         (vec_pairing): ...to this.
19803         (power9_sched_reorder2): Rewrite code for pairing vector/vecload insns.
19804         (rs6000_sched_init): Adjust for name change.
19805         (struct rs6000_sched_context): Likewise.
19806         (rs6000_init_sched_context): Likewise.
19807         (rs6000_set_sched_context): Likewise.
19809 2017-04-07  Jakub Jelinek  <jakub@redhat.com>
19811         PR target/80322
19812         PR target/80323
19813         PR target/80325
19814         PR target/80326
19815         * config/i386/avxintrin.h (_mm256_cvtsd_f64, _mm256_cvtss_f32): New
19816         intrinsics.
19817         * config/i386/avx512fintrin.h (_mm512_int2mask, _mm512_mask2int,
19818         _mm512_abs_ps, _mm512_mask_abs_ps, _mm512_abs_pd, _mm512_mask_abs_pd,
19819         _mm512_cvtsd_f64, _mm512_cvtss_f32): Likewise.
19821 2017-04-07  Andreas Tobler  <andreast@gcc.gnu.org>
19823         * config/aarch64/aarch64-freebsd.h: Define WCHAR_TYPE.
19825 2017-04-07  Vladimir Makarov  <vmakarov@redhat.com>
19827         PR rtl-optimization/70703
19828         * ira-color.c (update_conflict_hard_regno_costs): Use
19829         int64_t instead of HOST_WIDE_INT.
19831 2017-04-07  Vladimir Makarov  <vmakarov@redhat.com>
19833         PR rtl-optimization/70478
19834         * lra-constraints.c (process_alt_operands): Disfavor alternative
19835         insn memory operands.
19837 2017-04-07  Jeff Law  <law@redhat.com>
19839         * config/iq2000/iq2000.c (final_prescan_insn): Do not separate a
19840         CALL and NOTE_INSN_CALL_ARG_LOCATION.
19842 2017-04-07  Martin Liska  <mliska@suse.cz>
19844         PR target/79889
19845         * config/aarch64/aarch64.c (aarch64_process_target_attr):
19846         Show error message instead of an ICE.
19848 2017-04-07  Martin Liska  <mliska@suse.cz>
19850         PR ipa/80212
19851         * ipa-split.c (split_function): Add function part to a same comdat
19852         group.
19854 2017-04-07  Richard Biener  <rguenther@suse.de>
19856         PR middle-end/80341
19857         * tree.c (get_unwidened): Also handle ! for_type case for
19858         INTEGER_CSTs.
19859         * convert.c (do_narrow): Split out from ...
19860         (convert_to_integer_1): ... here.  Do not pass final truncation
19861         type to get_unwidened for TRUNC_DIV_EXPR.
19863 2017-04-07  Richard Biener  <rguenther@suse.de>
19865         * tree-affine.c (wide_int_ext_for_comb): Take type rather
19866         than aff_tree.
19867         (aff_combination_const): Adjust.
19868         (aff_combination_scale): Likewise.
19869         (aff_combination_add_elt): Likewise.
19870         (aff_combination_add_cst): Likewise.
19871         (aff_combination_convert): Likewise.
19872         (add_elt_to_tree): Likewise.  Remove unused argument.
19873         (aff_combination_to_tree): Adjust calls to add_elt_to_tree.
19875 2017-04-07  Sebastian Huber  <sebastian.huber@embedded-brains.de>
19877         * config/arm/arm.h (ARM_DEFAULT_SHORT_ENUMS): Provide default
19878         definition.
19879         * config/arm/arm.c (arm_default_short_enums): Use
19880         ARM_DEFAULT_SHORT_ENUMS.
19881         * config/arm/rtems.h (ARM_DEFAULT_SHORT_ENUMS): Define.
19883 2017-04-06  Jakub Jelinek  <jakub@redhat.com>
19885         PR debug/80234
19886         * dwarf2out.c (gen_member_die): Handle C++17 inline static data
19887         members with redundant out-of-class redeclaration.
19889 2017-04-06  Uros Bizjak  <ubizjak@gmail.com>
19891         PR target/80286
19892         * config/i386/sse.md (*vec_extractv4si_0_zext_sse4): New pattern.
19893         * config/i386/i386.md (*zero_extendsidi2):
19894         Add (?*x,*x) and (?*v,*v) alternatives.
19896 2017-04-06  Uros Bizjak  <ubizjak@gmail.com>
19898         PR target/79733
19899         * config/i386/i386.c (ix86_expand_builtin)
19900         <case IX86_BUILTIN_K{,OR}TEST{C,Z}{8,16,32,64}>: Determine insn operand
19901         mode from insn data. Convert operands to insn operand mode.
19902         Copy operands that don't satisfy insn predicate to a register.
19904 2017-04-06  Sam Thursfield  <sam.thursfield@codethink.co.uk>
19906         * config/rs6000/x-aix: Increase memory limit for genautomata on AIX.
19907         Update comments.
19909 2017-04-06  Richard Biener  <rguenther@suse.de>
19911         PR tree-optimization/80334
19912         * tree-ssa-loop-ivopts.c (rewrite_use_address): Properly
19913         preserve alignment of accesses.
19915 2017-04-06  Richard Biener  <rguenther@suse.de>
19917         PR tree-optimization/80262
19918         * tree-sra.c (build_ref_for_offset): Preserve address-space
19919         information.
19920         * tree-ssa-sccvn.c (vn_reference_maybe_forwprop_address):
19921         Drop useless address-space information on MEM_REF offsets.
19923 2017-04-05  Andreas Schwab  <schwab@linux-m68k.org>
19925         * builtins.def (BUILT_IN_UPDATE_SETJMP_BUF): Fix type.
19927 2017-04-05  Vladimir Makarov  <vmakarov@redhat.com>
19929         PR rtl-optimization/70703
19930         * ira-color.c (update_conflict_hard_regno_costs): Use
19931         HOST_WIDE_INT instead of long.
19933 2017-04-05  Uros Bizjak  <ubizjak@gmail.com>
19935         PR target/80298
19936         * config/i386/mmintrin.h: Add -msse target option when __SSE__ is
19937         not defined for x86_64 target.  Add -mmmx target option when __SSE2__
19938         is not defined.
19939         * config/i386/mm3dnow.h: Add -msse target when __SSE__ is not defined
19940         for x86_64 target.  Handle -m3dnowa option.
19942 2017-04-05  Vladimir Makarov  <vmakarov@redhat.com>
19944         PR rtl-optimization/70703
19945         * ira-color.c (update_costs_from_allocno): Use the smallest mode.
19946         (update_conflict_hard_regno_costs): Use long instead of unsigned
19947         arithmetic for cost calculation.
19949 2017-04-05  Jakub Jelinek  <jakub@redhat.com>
19950             Bernd Edlinger  <bernd.edlinger@hotmail.de>
19952         PR sanitizer/80308
19953         * asan.c (asan_store_shadow_bytes): Fix location of last_chunk_value
19954         for big endian.
19956 2017-04-05  Eric Botcazou  <ebotcazou@adacore.com>
19958         PR target/78002
19959         * config/aarch64/aarch64.c (aarch64_emit_probe_stack_range): Replace
19960         ptr_mode with Pmode throughout.
19961         * config/aarch64/aarch64.md (probe_stack_range_<PTR:mode): Rename
19962         into probe_stack_range and use DImode.
19964 2017-04-05  Dominik Vogt  <vogt@linux.vnet.ibm.com>
19966         PR target/79890
19967         * config/s390/s390.c (s390_register_info_gprtofpr): Return if
19968         call_eh_return is true.
19970 2017-04-05  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
19972         * config/s390/s390-c.c (s390_resolve_overloaded_builtin):
19973         Initialize last_match_fntype_index.
19975 2017-04-05  Jakub Jelinek  <jakub@redhat.com>
19977         PR target/80310
19978         * tree-nvr.c: Include internal-fn.h.
19979         (pass_return_slot::execute): Ignore internal calls without
19980         direct optab.
19982 2017-04-04  Jakub Jelinek  <jakub@redhat.com>
19983             Richard Biener  <rguenther@suse.de>
19985         PR c++/80297
19986         * genmatch.c (capture::gen_transform): For GENERIC unshare_expr
19987         captures used multiple times, except for the last use.
19988         * generic-match-head.c: Include gimplify.h.
19990 2017-04-04  Jakub Jelinek  <jakub@redhat.com>
19992         PR tree-optimization/79390
19993         * target.h (struct noce_if_info): Declare.
19994         * targhooks.h (default_noce_conversion_profitable_p): Declare.
19995         * target.def (noce_conversion_profitable_p): New target hook.
19996         * ifcvt.h (struct noce_if_info): New type, moved from ...
19997         * ifcvt.c (struct noce_if_info): ... here.
19998         (noce_conversion_profitable_p): Renamed to ...
19999         (default_noce_conversion_profitable_p): ... this.  No longer
20000         static nor inline.
20001         (noce_try_store_flag_constants, noce_try_addcc,
20002         noce_try_store_flag_mask, noce_try_cmove, noce_try_cmove_arith,
20003         noce_convert_multiple_sets): Use targetm.noce_conversion_profitable_p
20004         instead of noce_conversion_profitable_p.
20005         * config/i386/i386.c: Include ifcvt.h.
20006         (ix86_option_override_internal): Don't override
20007         PARAM_MAX_RTL_IF_CONVERSION_INSNS default.
20008         (ix86_noce_conversion_profitable_p): New function.
20009         (TARGET_NOCE_CONVERSION_PROFITABLE_P): Redefine.
20010         * config/i386/x86-tune.def (X86_TUNE_ONE_IF_CONV_INSN): Adjust comment.
20011         * doc/tm.texi.in (TARGET_NOCE_CONVERSION_PROFITABLE_P): Add.
20012         * doc/tm.texi: Regenerated.
20014 2017-04-04  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
20016         * doc/extend.texi (PowerPC AltiVec Built-in Functions): Grammar
20017         correction.
20019 2017-04-04  Thomas Preud'homme  <thomas.preudhomme@arm.com>
20021         PR target/80307
20022         * config/arm/arm.c (thumb1_rtx_costs): Give a cost of 32
20023         instructions for small multiply cores.
20025 2017-04-04  Jeff Law  <law@redhat.com>
20027         * config/mips/mips.c (mips_multi_add): Zero initialize the newly
20028         added member.
20029         (mips_expand_vec_perm_const): Initialize elements in orig_perm
20030         that are not set by the loop over the elements.
20032 2017-04-04  Jakub Jelinek  <jakub@redhat.com>
20034         PR target/80286
20035         * config/i386/i386.c (ix86_expand_args_builtin): If op has scalar
20036         int mode, convert_modes it to mode as unsigned, otherwise use
20037         lowpart_subreg to mode rather than SImode.
20038         * config/i386/sse.md (<mask_codefor>ashr<mode>3<mask_name>,
20039         ashr<mode>3, ashr<mode>3<mask_name>, <shift_insn><mode>3<mask_name>):
20040         Use DImode instead of SImode for the shift count operand.
20041         * config/i386/mmx.md (mmx_ashr<mode>3, mmx_<shift_insn><mode>3):
20042         Likewise.
20044 2017-04-04  Richard Biener  <rguenther@suse.de>
20046         PR middle-end/80281
20047         * match.pd (A + (-B) -> A - B): Make sure to preserve unsigned
20048         arithmetic done for the negate or the plus.  Simplify.
20049         (A - (-B) -> A + B): Likewise.
20050         * fold-const.c (split_tree): Make sure to not negate pointers.
20052 2017-04-04  Segher Boessenkool  <segher@kernel.crashing.org>
20054         PR rtl-optimization/60818
20055         * simplify-rtx.c (simplify_binary_operation_1): Do not replace
20056         a compare of comparisons with the thing compared if this results
20057         in a different machine mode.
20059 2017-04-03  Jonathan Wakely  <jwakely@redhat.com>
20061         * alias.c (base_alias_check): Fix typo in comment.
20062         * cgraph.h (class ipa_polymorphic_call_context): Likewise.
20063         * cgraphunit.c (symbol_table::compile): Likewise.
20064         * collect2.c (maybe_run_lto_and_relink): Likewise.
20065         * config/arm/arm.c (arm_thumb1_mi_thunk): Likewise.
20066         * config/avr/avr-arch.h (avr_arch_info_t): Likewise.
20067         * config/avr/avr.c (avr_map_op_t): Likewise.
20068         * config/cr16/cr16.h (DATA_ALIGNMENT): Likewise.
20069         * config/epiphany/epiphany.c (TARGET_ARG_PARTIAL_BYTES): Likewise.
20070         * config/epiphany/epiphany.md (movcc): Likewise.
20071         * config/i386/i386.c (legitimize_pe_coff_extern_decl): Likewise.
20072         * config/m68k/m68k.c (struct _sched_ib, m68k_sched_variable_issue):
20073         Likewise.
20074         * config/mips/mips.c (mips_save_restore_reg): Likewise.
20075         * config/rx/rx.c (rx_is_restricted_memory_address): Likewise.
20076         * config/s390/s390.c (Z10_EARLYLOAD_DISTANCE): Likewise.
20077         * config/sh/sh.c (sh_rtx_costs): Likewise.
20078         * fold-const.c (fold_truth_andor): Likewise.
20079         * genautomata.c (collapse_flag): Likewise.
20080         * gengtype.h (struct type::u::s): Likewise.
20081         * gensupport.c (has_subst_attribute, add_mnemonic_string): Likewise.
20082         * input.c (FORMAT_AMOUNT): Likewise.
20083         * ipa-cp.c (class ipcp_lattice, agg_replacements_to_vector)
20084         (known_aggs_to_agg_replacement_list): Likewise.
20085         * ipa-inline-analysis.c: Likewise.
20086         * ipa-inline.h (estimate_edge_time, estimate_edge_hints): Likewise.
20087         * ipa-polymorphic-call.c
20088         (ipa_polymorphic_call_context::restrict_to_inner_class): Likewise.
20089         * loop-unroll.c (analyze_insn_to_expand_var): Likewise.
20090         * lra.c (lra_optional_reload_pseudos, lra_subreg_reload_pseudos):
20091         Likewise.
20092         * modulo-sched.c (apply_reg_moves): Likewise.
20093         * omp-expand.c (build_omp_regions_1): Likewise.
20094         * trans-mem.c (struct tm_wrapper_hasher): Likewise.
20095         * tree-ssa-loop-ivopts.c (may_eliminate_iv): Likewise.
20096         * tree-ssa-loop-niter.c (maybe_lower_iteration_bound): Likewise.
20097         * tree-vect-data-refs.c (vect_enhance_data_refs_alignment): Likewise.
20098         * value-prof.c: Likewise.
20099         * var-tracking.c (val_reset): Likewise.
20101 2017-04-03  Richard Biener  <rguenther@suse.de>
20103         PR tree-optimization/80275
20104         * fold-const.c (split_address_to_core_and_offset): Handle
20105         POINTER_PLUS_EXPR.
20107 2017-04-03  Eric Botcazou  <ebotcazou@adacore.com>
20109         * tree-nested.c (get_descriptor_type): Make sure that the alignment of
20110         descriptors is at least equal to that of functions.
20112 2017-04-02  Uros Bizjak  <ubizjak@gmail.com>
20114         * config/i386/sse.md (movdi_to_sse): Add missing DONE.
20116 2017-04-02  Uros Bizjak  <ubizjak@gmail.com>
20118         PR target/80250
20119         * config/i386/sse.md (mov<IMOD4:mode>): Remove insn pattern.
20120         (mov<IMOD4:mode>): New expander.
20121         (*mov<IMOD4:mode>_internal): New insn and split pattern.
20123 2017-03-31  Segher Boessenkool  <segher@kernel.crashing.org>
20125         PR rtl-optimization/79405
20126         * fwprop.c (propagations_left): New variable.
20127         (forward_propagate_into): Decrement it.
20128         (fwprop_init): Initialize it.
20129         (fw_prop): If the variable has reached zero, stop propagating.
20130         (fwprop_addr): Ditto.
20132 2017-03-31  Jakub Jelinek  <jakub@redhat.com>
20134         PR debug/79255
20135         * dwarf2out.c (decls_for_scope): If BLOCK_NONLOCALIZED_VAR is
20136         a FUNCTION_DECL, pass it as decl instead of origin to
20137         process_scope_var.
20139 2017-03-31  Alexander Monakov  <amonakov@ispras.ru>
20141         * config/nvptx/nvptx.c (nvptx_output_softstack_switch): Correct format
20142         string.
20144 2017-03-31  Pat Haugen  <pthaugen@us.ibm.com>
20146         PR target/80107
20147         * config/rs6000/rs6000.md (extendhi<mode>2): Add test for
20148         TARGET_VSX_SMALL_INTEGER.
20150 2017-03-31  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
20152         * doc/extend.texi (PowerPC AltiVec Built-in Functions): Add
20153         reference to the OpenPOWER 64-Bit ELF V2 ABI Specification.
20155 2017-03-31  Matthew Fortune  <matthew.fortune@imgtec.com>
20157         * config/mips/mips-msa.md (msa_vec_extract_<msafmt_f>): Update
20158         extraction from odd-numbered MSA register.
20160 2017-03-31  Jakub Jelinek  <jakub@redhat.com>
20162         PR middle-end/80173
20163         * expmed.c (store_bit_field_1): Don't attempt to create
20164         a word subreg out of hard registers wider than word if they
20165         have HARD_REGNO_NREGS of 1 for their mode.
20167         PR middle-end/80163
20168         * varasm.c (initializer_constant_valid_p_1): Disallow sign-extending
20169         conversions to integer types wider than word and pointer.
20171         PR debug/80025
20172         * cselib.h (rtx_equal_for_cselib_1): Add depth argument.
20173         (rtx_equal_for_cselib_p): Pass 0 to it.
20174         * cselib.c (cselib_hasher::equal): Likewise.
20175         (rtx_equal_for_cselib_1): Add depth argument.  If depth
20176         is 128, don't look up VALUE locs and punt.  Increment
20177         depth in recursive calls when walking VALUE locs.
20179 2017-03-31  Bernd Edlinger  <bernd.edlinger@hotmail.de>
20181         * gcov.c (md5sum_to_hex): Fix output of MD5 hex bytes.
20182         (make_gcov_file_name): Use the canonical path name for generating
20183         the MD5 value.
20184         (read_line): Fix handling of files with ascii null bytes.
20186 2017-03-30  Matthew Fortune  <matthew.fortune@imgtec.com>
20188         * config/mips/mips.c (mips_expand_vector_init): Create a const_vector
20189         to initialise a vector register instead
20190         of using a const_int.
20192 2017-03-30  Jakub Jelinek  <jakub@redhat.com>
20194         PR translation/80189
20195         * gimplify.c (omp_default_clause): Use %qs instead of %s in
20196         diagnostic messages.
20198 2017-03-30  Peter Bergner  <bergner@vnet.ibm.com>
20200         PR target/80246
20201         * config/rs6000/dfp.md (dfp_dxex_<mode>): Update mode of operand 0.
20202         (dfp_diex_<mode>): Update mode of operand 1.
20203         * doc/extend.texi (dxex, dxexq): Document change to return type.
20204         (diex, diexq): Document change to argument type.
20206 2017-03-30  Martin Jambor  <mjambor@suse.cz>
20208         PR ipa/77333
20209         * cgraph.h (cgraph_build_function_type_skip_args): Declare.
20210         * cgraph.c (redirect_call_stmt_to_callee): Set gimple fntype so that
20211         it reflects the signature changes performed at the callee side.
20212         * cgraphclones.c (build_function_type_skip_args): Make public, renamed
20213         to cgraph_build_function_type_skip_args.
20214         (build_function_decl_skip_args): Adjust call to the above function.
20216 2017-03-30  Jakub Jelinek  <jakub@redhat.com>
20218         PR target/80206
20219         * config/i386/sse.md
20220         (<extract_type>_vextract<shuffletype><extract_suf>_mask): Use
20221         register as dest whenever it is a MEM not rtx_equal_p to the
20222         corresponding dup operand, and when forcing into reg move the
20223         reg into the memory afterwards.
20224         (<extract_type_2>_vextract<shuffletype><extract_suf_2>_mask):
20225         Likewise.  Use <ssehalfvecmode> instead of <ssequartermode>
20226         for the force_reg mode.
20227         (avx512vl_vextractf128<mode>): Use register as dest either
20228         always when a MEM, or when it is a MEM not rtx_equal_p to the
20229         corresponding dup operand, or even not when it is a CONST_VECTOR
20230         depending on the mode and lo vs. hi.
20231         (avx512dq_vextract<shuffletype>64x2_1_maskm): Remove extraneous
20232         parens.
20233         (avx512f_vextract<shuffletype>32x4_1_maskm): Likewise.
20234         (<mask_codefor>avx512dq_vextract<shuffletype>64x2_1<mask_name>):
20235         Likewise.  Require that operands[2] is even.
20236         (<mask_codefor>avx512f_vextract<shuffletype>32x4_1<mask_name>):
20237         Remove extraneous parens.  Require that operands[2] is a multiple
20238         of 4.
20239         (vec_extract_lo_<mode><mask_name>): Don't bother testing if
20240         operands[0] is a MEM if <mask_applied>, the predicates/constraints
20241         disallow memory then.
20243 2017-03-30  Richard Biener  <rguenther@suse.de>
20245         PR tree-optimization/77498
20246         * tree-ssa-pre.c (phi_translate_1): Do not allow simplifications
20247         to non-constants over backedges.
20249 2017-03-29  Segher Boessenkool  <segher@kernel.crashing.org>
20251         PR rtl-optimization/80233
20252         * combine.c (combine_instructions): Only take NONDEBUG_INSN_P insns
20253         as last_combined_insn.  Do not test for BARRIER_P separately.
20255 2017-03-29  Andreas Schwab  <schwab@suse.de>
20257         PR ada/80146
20258         * calls.c (prepare_call_address): Convert funexp to Pmode before
20259         copying to temp reg.
20261 2017-03-29  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
20263         PR tree-optimization/80158
20264         * gimple-ssa-strength-reduction.c (replace_mult_candidate):
20265         Handle possible future case of more than one alternate
20266         interpretation.
20267         (replace_rhs_if_not_dup): Likewise.
20268         (replace_one_candidate): Likewise.
20270 2017-03-28  Vladimir Makarov  <vmakarov@redhat.com>
20272         PR rtl-optimization/80193
20273         * ira.c (ira): Do not check allocation for LRA.
20275 2017-03-28  Alexander Monakov  <amonakov@ispras.ru>
20277         * config/nvptx/nvptx-protos.h (nvptx_output_simt_enter): Declare.
20278         (nvptx_output_simt_exit): Declare.
20279         * config/nvptx/nvptx.c (nvptx_init_unisimt_predicate): Use
20280         cfun->machine->unisimt_location.  Handle NULL unisimt_predicate.
20281         (init_softstack_frame): Move initialization of crtl->is_leaf to...
20282         (nvptx_declare_function_name): ...here.  Emit declaration of local
20283         memory space buffer for omp_simt_enter insn.
20284         (nvptx_output_unisimt_switch): New.
20285         (nvptx_output_softstack_switch): New.
20286         (nvptx_output_simt_enter): New.
20287         (nvptx_output_simt_exit): New.
20288         * config/nvptx/nvptx.h (struct machine_function): New fields
20289         has_simtreg, unisimt_location, simt_stack_size, simt_stack_align.
20290         * config/nvptx/nvptx.md (UNSPECV_SIMT_ENTER): New unspec.
20291         (UNSPECV_SIMT_EXIT): Ditto.
20292         (omp_simt_enter_insn): New insn.
20293         (omp_simt_enter): New expansion.
20294         (omp_simt_exit): New insn.
20295         * config/nvptx/nvptx.opt (msoft-stack-reserve-local): New option.
20297         * internal-fn.c (expand_GOMP_SIMT_ENTER): New.
20298         (expand_GOMP_SIMT_ENTER_ALLOC): New.
20299         (expand_GOMP_SIMT_EXIT): New.
20300         * internal-fn.def (GOMP_SIMT_ENTER): New internal function.
20301         (GOMP_SIMT_ENTER_ALLOC): Ditto.
20302         (GOMP_SIMT_EXIT): Ditto.
20303         * target-insns.def (omp_simt_enter): New insn.
20304         (omp_simt_exit): Ditto.
20305         * omp-low.c (struct omplow_simd_context): New fields simt_eargs,
20306         simt_dlist.
20307         (lower_rec_simd_input_clauses): Implement SIMT privatization.
20308         (lower_rec_input_clauses): Likewise.
20309         (lower_lastprivate_clauses): Handle SIMT privatization.
20311         * omp-offload.c: Include langhooks.h, tree-nested.h, stor-layout.h.
20312         (ompdevlow_adjust_simt_enter): New.
20313         (find_simtpriv_var_op): New.
20314         (execute_omp_device_lower): Handle IFN_GOMP_SIMT_ENTER,
20315         IFN_GOMP_SIMT_ENTER_ALLOC, IFN_GOMP_SIMT_EXIT.
20317         * tree-inline.h (struct copy_body_data): New field dst_simt_vars.
20318         * tree-inline.c (expand_call_inline): Handle SIMT privatization.
20319         (copy_decl_for_dup_finish): Ditto.
20321         * tree-ssa.c (execute_update_addresses_taken): Handle GOMP_SIMT_ENTER.
20323 2017-03-28  Uros Bizjak  <ubizjak@gmail.com>
20325         PR target/53383
20326         * config/i386/i386.c (ix86_option_override_internal): Always
20327         allow -mpreferred-stack-boundary=3 for 64-bit targets.
20329 2017-03-28  Bin Cheng  <bin.cheng@arm.com>
20331         * tree-vect-loop.c (optimize_mask_stores): Add bb to the right loop.
20333 2017-03-28  Bin Cheng  <bin.cheng@arm.com>
20335         * tree-vect-loop-manip.c (slpeel_add_loop_guard): New param and
20336         mark new edge's irreducible flag accordign to it.
20337         (vect_do_peeling): Check loop preheader edge's irreducible flag
20338         and pass it to function slpeel_add_loop_guard.
20340 2017-03-28  Richard Sandiford  <richard.sandiford@arm.com>
20342         PR tree-optimization/80218
20343         * tree-call-cdce.c (shrink_wrap_one_built_in_call_with_conds):
20344         Update block frequencies and counts.
20346 2017-03-28  Richard Biener  <rguenther@suse.de>
20348         PR tree-optimization/78644
20349         * tree-ssa-ccp.c (evaluate_stmt): When we may not use the value
20350         of a simplification result we may not use it at all.
20352 2017-03-28  Richard Biener  <rguenther@suse.de>
20354         PR ipa/80205
20355         * tree-inline.c (copy_phis_for_bb): Do not create PHI node
20356         without arguments, generate default definition of a SSA name.
20358 2017-03-28  Richard Biener  <rguenther@suse.de>
20360         PR middle-end/80222
20361         * gimple-fold.c (gimple_fold_indirect_ref): Do not touch
20362         TYPE_REF_CAN_ALIAS_ALL references.
20363         * fold-const.c (fold_indirect_ref_1): Likewise.
20365 2017-03-28  Martin Liska  <mliska@suse.cz>
20367         PR ipa/80104
20368         * cgraphunit.c (cgraph_node::expand_thunk): Mark argument of a
20369         thunk call as DECL_GIMPLE_REG_P when vector or complex type.
20371 2017-03-28  Claudiu Zissulescu  <claziss@synopsys.com>
20372             Thomas Petazzoni  <thomas.petazzoni@free-electrons.com>
20374         * config/arc/arc.h (CPP_SPEC): Add subtarget_cpp_spec.
20375         (EXTRA_SPECS): Define.
20376         (SUBTARGET_EXTRA_SPECS): Likewise.
20377         (SUBTARGET_CPP_SPEC): Likewise.
20378         * config/arc/elf.h (EXTRA_SPECS): Renamed to
20379         SUBTARGET_EXTRA_SPECS.
20380         * config/arc/linux.h (SUBTARGET_CPP_SPEC): Define.
20382 2017-03-28  Claudiu Zissulescu  <claziss@synopsys.com>
20384         * config/arc/simdext.md (vst64_insn): Update pattern.
20385         (vld32wh_insn): Likewise.
20386         (vld32wl_insn): Likewise.
20387         (vld64_insn): Likewise.
20388         (vld32_insn): Likewise.
20390 2017-03-28  Marek Polacek  <polacek@redhat.com>
20392         PR sanitizer/80067
20393         * fold-const.c (fold_comparison): Use protected_set_expr_location
20394         instead of SET_EXPR_LOCATION.
20396 2017-03-28  Markus Trippelsdorf  <markus@trippelsdorf.de>
20398         * tree.c (add_expr): Avoid name lookup warning.
20400 2017-03-27  Jeff Law  <law@redhat.com>
20402         PR tree-optimization/80216
20403         * tree-ssa-dom.c (derive_equivalences_from_bit_ior): Fix typo in
20404         function name.  Limit recursion depth.
20405         (record_temporary_equivalences): Corresponding changes.
20407 2017-03-27  Jonathan Wakely  <jwakely@redhat.com>
20409         * doc/invoke.texi (-Wno-narrowing): Reorder so default behavior is
20410         covered first.
20412 2017-03-27  Jakub Jelinek  <jakub@redhat.com>
20414         PR target/80102
20415         * reg-notes.def (REG_CFA_NOTE): Define.  Use it for CFA related
20416         notes.
20417         * cfgcleanup.c (reg_note_cfa_p): New array.
20418         (insns_have_identical_cfa_notes): New function.
20419         (old_insns_match_p): Don't cross-jump in between /f
20420         and non-/f instructions.  If both i1 and i2 are frame related,
20421         verify all CFA notes, their order and content.
20423 2017-03-27  Michael Meissner  <meissner@linux.vnet.ibm.com>
20425         PR target/78543
20426         * config/rs6000/rs6000.md (bswaphi2_extenddi): Combine bswap
20427         HImode and SImode with zero extend to DImode to one insn.
20428         (bswap<mode>2_extenddi): Likewise.
20429         (bswapsi2_extenddi): Likewise.
20430         (bswaphi2_extendsi): Likewise.
20431         (bswaphi2): Combine bswap HImode and SImode into one insn.
20432         Separate memory insns from swapping register.
20433         (bswapsi2): Likewise.
20434         (bswap<mode>2): Likewise.
20435         (bswaphi2_internal): Delete, no longer used.
20436         (bswapsi2_internal): Likewise.
20437         (bswap<mode>2_load): Split bswap HImode/SImode into separate load,
20438         store, and gpr<-gpr swap insns.
20439         (bswap<mode>2_store): Likewise.
20440         (bswaphi2_reg): Register only splitter, combine with the splitter.
20441         (bswaphi2 splitter): Likewise.
20442         (bswapsi2_reg): Likewise.
20443         (bswapsi2 splitter): Likewise.
20444         (bswapdi2): If we have the LDBRX and STDBRX instructions, split
20445         the insns into load, store, and register/register insns.
20446         (bswapdi2_ldbrx): Likewise.
20447         (bswapdi2_load): Likewise.
20448         (bswapdi2_store): Likewise.
20449         (bswapdi2_reg): Likewise.
20451 2017-03-27  Gunther Nikl  <gnikl@users.sourceforge.net>
20453         * system.h (HAVE_DESIGNATED_INITIALIZERS): Fix non C++ case.
20454         (HAVE_DESIGNATED_UNION_INITIALIZERS): Likewise.
20456 2017-03-27  Kelvin Nilsen  <kelvin@gcc.gnu.org>
20458         PR target/80103
20459         * config/rs6000/rs6000-c.c (rs6000_target_modify_macros): Edit and
20460         add comments.
20461         * config/rs6000/rs6000.c (rs6000_option_override_internal): Add
20462         special handling for target option conflicts between dform
20463         options (-mpower9-dform, -mpower9-dform-vector,
20464         -mpower9-dform-scalar) and -mno-direct-move.
20466 2017-03-27  Richard Biener  <rguenther@suse.de>
20468         PR tree-optimization/80181
20469         * tree-ssa-ccp.c (likely_value): UNDEFINED ^ X is UNDEFINED.
20471 2017-03-27  Claudiu Zissulescu  <claziss@synopsys.com>
20473         * config/arc/predicates.md (move_double_src_operand): Replace the
20474         call to move_double_src_operand with a call to address_operand.
20476 2017-03-27  Claudiu Zissulescu  <claziss@synopsys.com>
20478         * config/arc/elf.h (ARGET_ARC_TP_REGNO_DEFAULT): Define.
20479         * config/arc/linux.h (ARGET_ARC_TP_REGNO_DEFAULT): Likewise.
20480         * config/arc/arc.opt (mtp-regno): Use ARGET_ARC_TP_REGNO_DEFAULT.
20482 2017-03-27  Claudiu Zissulescu  <claziss@synopsys.com>
20484         * config/arc/predicates.md (long_immediate_loadstore_operand):
20485         Consider scaled addresses cases.
20487 2017-03-27  Claudiu Zissulescu  <claziss@synopsys.com>
20489         * config/arc/arc.c (arc_epilogue_uses): BLINK should be also
20490         restored when in interrupt.
20491         * config/arc/arc.md (simple_return): ARCv2 rtie instruction
20492         doesn't have delay slot.
20494 2017-03-27  Richard Biener  <rguenther@suse.de>
20496         PR ipa/79776
20497         * tree-ssa-structalias.c (associate_varinfo_to_alias): Skip
20498         inlined thunk clones.
20500 2017-03-27  Jakub Jelinek  <jakub@redhat.com>
20502         PR sanitizer/80168
20503         * asan.c (instrument_derefs): Copy over last operand from
20504         original COMPONENT_REF to the new COMPONENT_REF with
20505         DECL_BIT_FIELD_REPRESENTATIVE.
20506         * ubsan.c (instrument_object_size): Likewise.
20508 2017-03-27  Richard Biener  <rguenther@suse.de>
20510         PR tree-optimization/80170
20511         * tree-vect-data-refs.c (vect_compute_data_ref_alignment): Make
20512         sure DR/SCEV didnt fold in constants we do not see when looking
20513         at the reference base alignment.
20515 2017-03-27  Richard Biener  <rguenther@suse.de>
20517         PR middle-end/80171
20518         * gimple-fold.c (fold_ctor_reference): Properly guard against
20519         NULL return value from canonicalize_constructor_val.
20521 2017-03-25  Uros Bizjak  <ubizjak@gmail.com>
20523         PR target/80180
20524         * config/i386/i386.c (ix86_expand_builtin)
20525         <IX86_BUILTIN_RDSEED{16,32,64}_STEP>: Do not expand arg0 between
20526         flags reg setting and flags reg using instructions.
20527         <IX86_BUILTIN_RDRAND{16,32,64}_STEP>: Ditto.  Use non-flags reg
20528         clobbering instructions to zero extend op2.
20530 2017-03-25  Gerald Pfeifer  <gerald@pfeifer.com>
20532         * doc/install.texi (Configuration) <--with-aix-soname>:
20533         Update link to AIX ld.
20535 2017-03-25  Bernd Schmidt  <bschmidt@redhat.com>
20537         PR rtl-optimization/80160
20538         PR rtl-optimization/80159
20539         * lra-assigns.c (must_not_spill_p): Tighten new test to also take
20540         reg_alternate_class into account.
20542 2017-03-24  Vladimir Makarov  <vmakarov@redhat.com>
20544         PR target/80148
20545         * lra-assigns.c (assign_by_spills): Add spilled non-reload pseudos
20546         to consider in curr_insn_transform.
20548 2017-03-24  Jakub Jelinek  <jakub@redhat.com>
20550         * genrecog.c (validate_pattern): Add VEC_SELECT validation.
20551         * genmodes.c (emit_min_insn_modes_c): Call emit_mode_nunits
20552         and emit_mode_inner.
20554 2017-03-24  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
20556         * config/s390/s390-builtins.def: Add VXE builtins.  Add a flags
20557         argument to the overloaded builtin variants.  Use the new flag to
20558         deprecate certain builtin variants.
20559         * config/s390/s390-builtin-types.def: Add new builtin types.
20560         * config/s390/s390-builtins.h: Support new flags field for
20561         overloaded builtins.
20562         * config/s390/s390-c.c (OB_DEF_VAR): New flags field.
20563         (s390_macro_to_expand): Enable vector float data type.
20564         (s390_cpu_cpp_builtins_internal): Indicate support of the new
20565         builtins by incrementing the __VEC__ version number.
20566         (s390_expand_overloaded_builtin): Support expansion of vec_xl and
20567         vec_xst.
20568         (s390_resolve_overloaded_builtin): Emit error messages depending
20569         on the builtin flags.
20570         * config/s390/s390.c (s390_expand_builtin): Support additional
20571         flags argument.  Change error message to match the messages
20572         emitted in s390-c.c.
20573         * config/s390/s390.md: New UNSPEC_* constants.
20574         (op_type): Add new instruction types.
20575         * config/s390/vecintrin.h: Add new builtins and test data class
20576         constants.
20577         * config/s390/vx-builtins.md (V_HW_32_64): Add V4SF.
20578         (V_HW_4, VEC_HW, VECF_HW): New mode iterators.
20579         (VEC_INEXACT, VEC_NOINEXACT): New constants.
20580         ("vec_splats<mode>", "vec_insert<mode>", "vec_promote<mode>")
20581         ("vec_insert_and_zero<mode>", "vec_mergeh<mode>")
20582         ("vec_mergel<mode>"): V_HW -> VEC_HW.
20584         ("vlrlrv16qi", "vstrlrv16qi", "vbpermv16qi", "vec_msumv2di")
20585         ("vmslg", "*vftci<mode>_cconly", "vftci<mode>_intcconly")
20586         ("*vftci<mode>", "vftci<mode>_intcc", "vec_double_s64")
20587         ("vec_double_u64", "vfmin<mode>", "vfmax<mode>"): New definition.
20589         ("and_av2df3", "and_cv2df3", "vec_andc_av2df3")
20590         ("vec_andc_cv2df3", "xor_av2df3", "xor_cv2df3", "vec_nor_av2df3")
20591         ("vec_nor_cv2df3", "ior_av2df3", "ior_cv2df3", "vec_nabs")
20592         ("*vftcidb", "*vftcidb_cconly", "vftcidb"): Remove definition.
20594         ("vec_all_<fpcmpcc:code>v2df", "vec_any_<fpcmpcc:code>v2df")
20595         ("vec_scatter_elementv4si_DI", "vec_cmp<fpcmp:code>v2df")
20596         ("vec_di_to_df_s64", "vec_di_to_df_u64", "vec_df_to_di_u64")
20597         ("vfidb", "*vldeb", "*vledb", "*vec_cmp<insn_cmp>v2df_cconly")
20598         ("vec_cmpeqv2df_cc", "vec_cmpeqv2df_cc", "vec_cmphv2df_cc")
20599         ("vec_cmphev2df_cc", "*vec_cmpeqv2df_cc")
20600         ("*vec_cmphv2df_cc", "*vec_cmphev2df_cc"): Enable new modes as ...
20602         ("vec_all_<fpcmpcc:code><mode>", "vec_any_<fpcmpcc:code><mode>")
20603         ("vec_scatter_element<V_HW_4:mode>_DI")
20604         ("vec_cmp<fpcmp:code><mode>", "vcdgb", "vcdlgb", "vclgdb")
20605         ("vec_fpint<mode>", "vflls")
20606         ("vflrd", "*vec_cmp<insn_cmp><mode>_cconly", "vec_cmpeq<mode>_cc")
20607         ("vec_cmpeq<mode>_cc", "vec_cmph<mode>_cc", "vec_cmphe<mode>_cc")
20608         ("*vec_cmpeq<mode>_cc", "*vec_cmph<mode>_cc")
20609         ("*vec_cmphe<mode>_cc"): ... these.
20611         ("vec_ctd_s64", "vec_ctsl", "vec_ctul", "vec_st2f"): Use rounding
20612         mode constant instead of magic value.
20614 2017-03-24  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
20616         * config/s390/s390.c (s390_expand_vec_compare): Support other
20617         vector floating point modes than just V2DF.
20618         (s390_expand_vcond): Likewise.
20619         (s390_hard_regno_mode_ok): Allow SFmode values in VRs.
20620         (s390_cannot_change_mode_class): Prevent mode changes between TF
20621         and V1TF in vector registers.
20622         * config/s390/s390.md (DF, SF): New mode attributes.
20623         ("*cmp<mode>_ccs", "add<mode>3", "sub<mode>3", "mul<mode>3")
20624         ("fma<mode>4", "fms<mode>4", "div<mode>3", "*neg<mode>2"): Add
20625         SFmode support for VRs.
20626         * config/s390/vector.md (V_HW, V_HW2, VT_HW, ti*, nonvec): Add new
20627         vector fp modes.
20628         (VFT, VF_HW): New mode iterators.
20629         (vw, sdx): New mode attributes.
20630         ("addv2df3", "subv2df3", "mulv2df3", "divv2df3", "sqrtv2df2")
20631         ("fmav2df4","fmsv2df4", "negv2df2", "absv2df2", "*negabsv2df2")
20632         ("smaxv2df3", "sminv2df3", "*vec_cmp<VFCMP_HW_OP:code>v2df_nocc")
20633         ("vec_cmpuneqv2df", "vec_cmpltgtv2df", "vec_orderedv2df")
20634         ("vec_unorderedv2df"): Adjust the v2df only patterns to support
20635         also the new vector floating point modes.  Renaming to ...
20637         ("add<mode>3", "sub<mode>3", "mul<mode>3", "div<mode>3")
20638         ("sqrt<mode>2", "fma<mode>4", "fms<mode>4", "neg<mode>2")
20639         ("abs<mode>2", "negabs<mode>2", "smax<mode>3")
20640         ("smin<mode>3", "*vec_cmp<VFCMP_HW_OP:code><mode>_nocc")
20641         ("vec_cmpuneq<mode>", "vec_cmpltgt<mode>", "vec_ordered<mode>")
20642         ("vec_unordered<mode>"): ... these.
20644         ("neg_fma<mode>4", "neg_fms<mode>4", "*smax<mode>3_vxe")
20645         ("*smin<mode>3_vxe", "*sminv2df3_vx", "*vec_extendv4sf")
20646         ("*vec_extendv2df"): New insn definitions.
20648 2017-03-24  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
20650         * config/s390/s390.md ("*adddi3_sign", "*subdi3_sign", "mulditi3")
20651         ("mulditi3_2", "*muldi3_sign"): New patterns.
20652         ("muldi3", "*muldi3", "mulsi3", "*mulsi3"): Add an expander and
20653         rename the pattern definition.
20655 2017-03-24  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
20657         * config/s390/s390.md ("indirect_jump"): Turn insn definition into
20658         expander.
20659         ("*indirect_jump", "*indirect2_jump"): New pattern definitions.
20661 2017-03-24  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
20663         * config/s390/s390.c (s390_expand_vec_init): Use vllezl
20664         instruction if possible.
20665         * config/s390/vector.md (vec_halfnumelts): New mode
20666         attribute.
20667         ("*vec_vllezlf<mode>"): New pattern.
20669 2017-03-24  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
20671         * config/s390/vector.md ("popcountv16qi2", "popcountv8hi2")
20672         ("popcountv4si2", "popcountv2di2"): Rename to ...
20673         ("popcount<mode>2", "popcountv8hi2_vx", "popcountv4si2_vx")
20674         ("popcountv2di2_vx"): ... these and add !TARGET_VXE to the
20675         condition.
20676         ("popcount<mode>2_vxe"): New pattern.
20678 2017-03-24  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
20680         * common/config/s390/s390-common.c (processor_flags_table): Add
20681         arch12.
20682         * config.gcc: Add arch12.
20683         * config/s390/driver-native.c (s390_host_detect_local_cpu):
20684         Default to arch12 for unknown CPU model numbers.
20685         * config/s390/s390-builtins.def: Add B_VXE builtin flag.
20686         * config/s390/s390-c.c (s390_cpu_cpp_builtins_internal): Adjust
20687         PROCESSOR_max sanity check.
20688         * config/s390/s390-opts.h (enum processor_type): Add
20689         PROCESSOR_ARCH12.
20690         * config/s390/s390.c (processor_table): Add arch12.
20691         (s390_expand_builtin): Add check for B_VXE flag.
20692         (s390_issue_rate): Add PROCESSOR_ARCH12.
20693         (s390_get_sched_attrmask): Likewise.
20694         (s390_get_unit_mask): Likewise.
20695         (s390_sched_score): Enable z13 scheduling for arch12.
20696         (s390_sched_reorder): Likewise.
20697         (s390_sched_variable_issue): Likewise.
20698         * config/s390/s390.h (enum processor_flags): Add PF_ARCH12 and
20699         PF_VXE.
20700         (s390_tune_attr): Use z13 scheduling also for arch12.
20701         (TARGET_CPU_ARCH12, TARGET_CPU_ARCH12_P, TARGET_CPU_VXE)
20702         (TARGET_CPU_VXE_P, TARGET_ARCH12, TARGET_ARCH12_P, TARGET_VXE)
20703         (TARGET_VXE_P): New macros.
20704         * config/s390/s390.md: Add arch12 to cpu attribute.  Add arch12
20705         and vxe to cpu_facility.  Add arch12 and vxe to enabled attribute.
20706         * config/s390/s390.opt: Add arch12 as processor_type.
20708 2017-03-24  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
20710         * config/s390/s390.md
20711         ("fixuns_truncdddi2", "fixuns_trunctddi2")
20712         ("fixuns_trunc<BFP:mode><GPR:mode>2"): Merge into ...
20713         ("fixuns_trunc<FP:mode><GPR:mode>2"): New expander.
20715         ("fixuns_trunc<BFP:mode><GPR:mode>2", "fixuns_trunc<mode>si2"):
20716         Rename expanders to ...
20718         ("fixuns_trunc<BFP:mode><GPR:mode>2_emu")
20719         ("fixuns_truncdddi2_emu"): ... these.
20721         ("fixuns_trunc<mode>si2_emu"): New expander.
20723         ("*fixuns_truncdfdi2_z13"): Rename to ...
20724         ("*fixuns_truncdfdi2_vx"): ... this.
20726 2017-03-24  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
20728         * config/s390/2964.md: Remove the single element vector compare
20729         instructions which are no longer used.
20730         * config/s390/s390.c (s390_select_ccmode): Remove handling of
20731         vector CCmodes.
20732         (s390_canonicalize_comparison): Remove handling of DFmode
20733         compares.
20734         (s390_expand_vec_compare_scalar): Remove function.
20735         (s390_emit_compare): Don't call s390_expand_vec_compare_scalar.
20736         * config/s390/s390.md ("*vec_cmp<insn_cmp>df_cconly"): Remove
20737         pattern.
20738         ("*cmp<mode>_ccs"): Add wfcdb instruction.
20740 2017-03-24  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
20742         * config/s390/s390.md ("mov<mode>_64dfp" DD_DF): Use vleig for loading a
20743         FP zero.
20744         ("*mov<mode>_64" DD_DF): Remove the vector instructions. These
20745         will anyway by matched by mov<mode>_64dfp.
20747 2017-03-24  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
20749         * config/s390/s390.md ("mov<mode>" SD_SF): Change vleg/vsteg to
20750         vlef/vstef.  Add missing operand to vleif.
20752 2017-03-24  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
20754         * config/s390/s390.c (s390_expand_vec_init): Enable vector load
20755         pair for all vector types with 64 bit elements.
20756         * config/s390/vx-builtins.md (V_HW_64): Move mode iterator to ...
20757         * config/s390/vector.md (V_HW_64): ... here.
20758         (V_128_NOSINGLE): New mode iterator.
20759         ("vec_init<V_HW:mode>"): Use V_128 as mode iterator.
20760         ("*vec_splat<mode>"): Use V_128_NOSINGLE mode iterator.
20761         ("*vec_tf_to_v1tf", "*vec_ti_to_v1ti"): New pattern definitions.
20762         ("*vec_load_pairv2di"): Change to ...
20763         ("*vec_load_pair<mode>"): ... this one.
20765 2017-03-24  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
20767         * config/s390/constraints.md: Add comments.
20768         (jKK): Reject element sizes > 8 bytes.
20769         * config/s390/s390.c (s390_split_ok_p): Enable splitting also for
20770         s_operands.
20771         * config/s390/s390.md: Add the s_operand checks formerly in
20772         s390_split_ok_p to various splitters where they are still
20773         required.
20774         * config/s390/vector.md ("mov<mode>" V_128): Add GPR alternatives
20775         for 128 bit vectors.  Plus two splitters.
20777 2017-03-24  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
20779         * config/s390/s390.md: Rename the cpu facilty vec to vx throughout
20780         the file.
20782 2017-03-24  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
20784         PR target/79893
20785         * config/s390/s390-c.c (s390_adjust_builtin_arglist): Issue an
20786         error if the boundary argument is not constant.
20788 2017-03-24  Jakub Jelinek  <jakub@redhat.com>
20790         PR rtl-optimization/80112
20791         * loop-doloop.c (doloop_condition_get): Don't check condition
20792         if cmp isn't SET with IF_THEN_ELSE src.
20794 2017-03-24  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
20796         PR tree-optimization/80158
20797         * gimple-ssa-strength-reduction.c (replace_mult_candidate): When
20798         replacing a candidate statement, also replace it for the
20799         candidate's alternate interpretation.
20800         (replace_rhs_if_not_dup): Likewise.
20801         (replace_one_candidate): Likewise.
20803 2017-03-24  Richard Biener  <rguenther@suse.de>
20805         PR tree-optimization/80167
20806         * graphite-isl-ast-to-gimple.c
20807         (translate_isl_ast_to_gimple::is_valid_rename): Handle default-defs
20808         properly.
20809         (translate_isl_ast_to_gimple::get_rename): Likewise.
20811 2017-03-23  Kelvin Nilsen  <kelvin@gcc.gnu.org>
20813         * config/rs6000/rs6000.c (rs6000_option_override_internal): Change
20814         handling of certain combinations of target options, including the
20815         combinations -mpower8-vector vs. -mno-vsx, -mpower9-vector vs.
20816         -mno-power8-vector, and -mpower9_dform vs. -mno-power9-vector.
20818 2017-03-23  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
20820         PR target/71436
20821         * config/arm/arm.md (*load_multiple): Add reload_completed to
20822         matching condition.
20824 2017-03-23  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
20825             Richard Biener  <rguenth@suse.de>
20827         PR tree-optimization/79908
20828         PR tree-optimization/80136
20829         * tree-stdarg.c (expand_ifn_va_arg_1): For a VA_ARG whose LHS has
20830         been cast away, gimplify_and_add suffices.
20832 2017-03-23  Markus Trippelsdorf  <markus@trippelsdorf.de>
20834         * tree-vrp.c (identify_jump_threads): Delete avail_exprs.
20836 2017-03-23  Richard Biener  <rguenther@suse.de>
20838         PR tree-optimization/80032
20839         * gimplify.c (gimple_push_cleanup): Forced unconditional
20840         cleanups still have to go to the conditional_cleanups
20841         sequence.
20843 2017-03-22  Jakub Jelinek  <jakub@redhat.com>
20845         PR tree-optimization/80072
20846         * tree-ssa-reassoc.c (struct operand_entry): Change id field type
20847         to unsigned int.
20848         (next_operand_entry_id): Change type to unsigned int.
20849         (sort_by_operand_rank): Make sure to return the right return value
20850         even if unsigned fields are bigger than INT_MAX.
20851         (struct oecount): Change cnt and id type to unsigned int.
20852         (oecount_hasher::equal): Formatting fix.
20853         (oecount_cmp): Make sure to return the right return value
20854         even if unsigned fields are bigger than INT_MAX.
20855         (undistribute_ops_list): Change next_oecount_id type to unsigned int.
20857         PR c++/80129
20858         * gimplify.c (gimplify_modify_expr_rhs) <case COND_EXPR>: Clear
20859         TREE_READONLY on result if writing it more than once.
20861         PR sanitizer/80110
20862         * doc/invoke.texi (-fsanitize=thread): Document that with
20863         -fnon-call-exceptions atomics are not able to throw
20864         exceptions.
20866         PR sanitizer/80110
20867         * tsan.c: Include tree-eh.h.
20868         (instrument_builtin_call): Call maybe_clean_eh_stmt or
20869         maybe_clean_or_replace_eh_stmt where needed.
20870         (instrument_memory_accesses): Add cfg_changed argument.
20871         Call gimple_purge_dead_eh_edges on each block and set *cfg_changed
20872         if it returned true.
20873         (tsan_pass): Adjust caller.  Return TODO_cleanup_cfg if cfg_changed.
20875         PR rtl-optimization/63191
20876         * config/i386/i386.c (ix86_delegitimize_address): Turn into small
20877         wrapper function, moved the whole old content into ...
20878         (ix86_delegitimize_address_1): ... this.  New inline function.
20879         (ix86_find_base_term): Use ix86_delegitimize_address_1 with
20880         true as last argument instead of ix86_delegitimize_address.
20882 2017-03-22  Wilco Dijkstra  <wdijkstr@arm.com>
20884         * config/aarch64/aarch64.c (generic_branch_cost): Copy
20885         cortexa57_branch_cost.
20887 2017-03-22  Wilco Dijkstra  <wdijkstr@arm.com>
20889         * config/aarch64/aarch64.c (generic_tunings): Add AES fusion.
20891 2017-03-21  Aaron Sawdey  <acsawdey@linux.vnet.ibm.com>
20893         PR target/80123
20894         * doc/md.texi (Constraints): Document wA constraint.
20895         * config/rs6000/constraints.md (wA): New.
20896         * config/rs6000/rs6000.c (rs6000_debug_reg_global): Add wA reg_class.
20897         (rs6000_init_hard_regno_mode_ok): Init wA constraint.
20898         * config/rs6000/rs6000.h (RS6000_CONSTRAINT_wA): New.
20899         * config/rs6000/vsx.md (vsx_splat_<mode>): Use wA constraint.
20901 2017-03-22  Cesar Philippidis  <cesar@codesourcery.com>
20903         PR c++/80029
20904         * gimplify.c (is_oacc_declared): New function.
20905         (oacc_default_clause): Use it to set default flags for acc declared
20906         variables inside parallel regions.
20907         (gimplify_scan_omp_clauses): Strip firstprivate pointers for acc
20908         declared variables.
20909         (gimplify_oacc_declare): Gimplify the declare clauses.  Add the
20910         declare attribute to any decl as necessary.
20912 2017-03-22  Thomas Preud'homme  <thomas.preudhomme@arm.com>
20914         PR target/80082
20915         * config/arm/arm-isa.h (isa_bit_lpae): New feature bit.
20916         (ISA_ARMv7ve): Add isa_bit_lpae to the definition.
20917         * config/arm/arm-protos.h (arm_arch7ve): Rename into ...
20918         (arm_arch_lpae): This.
20919         * config/arm/arm.c (arm_arch7ve): Rename into ...
20920         (arm_arch_lpae): This.  Define it in term of isa_bit_lpae.
20921         * config/arm/arm.h (TARGET_HAVE_LPAE): Redefine in term of
20922         arm_arch_lpae.
20924 2017-03-22  Martin Liska  <mliska@suse.cz>
20926         PR target/79906
20927         * config/rs6000/rs6000.c (rs6000_inner_target_options): Show
20928         error message instead of an ICE.
20930 2017-03-21  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
20932         * doc/extend.texi (6.11 Additional Floating Types): Revise.
20934 2017-03-21  Kelvin Nilsen  <kelvin@gcc.gnu.org>
20936         * config/rs6000/rs6000-c.c (rs6000_target_modify_macros): Add
20937         comments.
20938         * config/rs6000/rs6000.c (rs6000_option_override_internal): Add
20939         comments.
20941 2017-03-21  Martin Sebor  <msebor@redhat.com>
20943         * doc/extend.texi: Use "cannot" instead of "can't."
20944         * doc/hostconfig.texi: Same.
20945         * doc/install.texi: Same.
20946         * doc/invoke.texi: Same.
20947         * doc/loop.texi: Same.
20948         * doc/md.texi: Same.
20949         * doc/objc.texi: Same.
20950         * doc/rtl.texi: Same.
20951         * doc/tm.texi: Same.
20952         * doc/tm.texi.in: Same.
20953         * doc/trouble.texi: Same.
20955 2017-03-21  Alexandre Oliva <aoliva@redhat.com>
20957         PR debug/63238
20958         * dwarf2out.c (struct checksum_attributes): Add at_alignment.
20959         (collect_checksum_attributes): Set it.
20960         (die_checksum_ordered): Use it.
20962 2017-03-21  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
20964         PR tree-optimization/79908
20965         * tree-stdarg.c (expand_ifn_va_arg_1): Revert the following
20966         change: For a VA_ARG whose LHS has been cast away, use
20967         force_gimple_operand to construct the side effects.
20969 2017-03-21  David Malcolm  <dmalcolm@redhat.com>
20971         PR translation/80001
20972         * omp-offload.c (oacc_loop_fixed_partitions): Make diagnostics
20973         more amenable to translation.
20974         (oacc_loop_auto_partitions): Likewise.
20976 2017-03-21  Marek Polacek  <polacek@redhat.com>
20977             Martin Sebor  <msebor@redhat.com>
20979         PR tree-optimization/80109
20980         * gimple-ssa-warn-alloca.c (alloca_call_type): Only call get_range_info
20981         on INTEGRAL_TYPE_P.
20983 2017-03-21  Jakub Jelinek  <jakub@redhat.com>
20984             Segher Boessenkool  <segher@kernel.crashing.org>
20986         PR target/80125
20987         * combine.c (can_combine_p): Revert the 2017-03-20 change, only
20988         check reg_used_between_p between insn and one of succ or succ2
20989         depending on if succ is artificial insn not inserted into insn
20990         stream.
20992 2017-03-21  Martin Liska  <mliska@suse.cz>
20994         PR gcov-profile/80081
20995         * Makefile.in: Add gcov-dump and fix installation of gcov-tool.
20996         * doc/gcc.texi: Include gcov-dump stuff.
20997         * doc/gcov-dump.texi: New file.
20999 2017-03-21  Toma Tabacu  <toma.tabacu@imgtec.com>
21001         PR rtl-optimization/79150
21002         * config/mips/mips.c (mips_block_move_loop): Emit a NOP after the
21003         conditional jump, if the jump is the last insn of the loop.
21005 2017-03-21  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
21006             Richard Biener  <rguenth@suse.de>
21008         PR tree-optimization/79908
21009         * tree-stdarg.c (expand_ifn_va_arg_1): For a VA_ARG whose LHS has
21010         been cast away, use force_gimple_operand to construct the side
21011         effects.
21013 2017-03-21  Martin Liska  <mliska@suse.cz>
21015         PR libfortran/79956
21016         * simplify-rtx.c (simplify_immed_subreg): Initialize a variable
21017         to NULL.
21019 2017-03-21  Brad Spengler <spender@grsecurity.net>
21021         PR plugins/80094
21022         * plugin.c (htab_hash_plugin): New function.
21023         (add_new_plugin): Use it and adjust.
21024         (parse_plugin_arg_opt): Adjust.
21025         (init_one_plugin): Likewise.
21027 2017-03-21  Richard Biener  <rguenther@suse.de>
21029         PR tree-optimization/80032
21030         * gimplify.c (gimple_push_cleanup): Add force_uncond parameter,
21031         if set force the cleanup to happen unconditionally.
21032         (gimplify_target_expr): Push inserted clobbers with force_uncond
21033         to avoid them being removed by control-dependent DCE.
21035 2017-03-21  Richard Biener  <rguenther@suse.de>
21037         PR tree-optimization/80122
21038         * tree-inline.c (copy_bb): Do not expans va-arg packs or
21039         va_arg_pack_len when the inlined call stmt requires pack
21040         expansion itself.
21041         * tree-inline.h (struct copy_body_data): Make call_stmt a gcall *.
21043 2017-03-21  Jakub Jelinek  <jakub@redhat.com>
21045         PR sanitizer/78158
21046         * tsan.c (instrument_builtin_call): If the memory model argument
21047         is not a constant, assume it is valid.
21049         PR c/67338
21050         * fold-const.c (round_up_loc): Negate divisor in unsigned type to
21051         avoid UB.
21053 2017-03-20  Segher Boessenkool  <segher@kernel.crashing.org>
21055         PR rtl-optimization/79910
21056         * combine.c (can_combine_p): Do not allow combining an I0 or I1
21057         if its dest is used by an insn before I2 (other than the combined
21058         insns themselves, which are properly handled already).
21060 2017-03-20  Segher Boessenkool  <segher@kernel.crashing.org>
21062         Revert:
21063         2017-03-17  Bernd Schmidt  <bschmidt@redhat.com>
21065         * combine.c (record_used_regs): New static function.
21066         (try_combine): Handle situations where there is an additional
21067         instruction between I2 and I3 which needs to have a LOG_LINK
21068         updated.
21070         Revert:
21071         2017-03-17  Jim Wilson  <jim.wilson@linaro.org>
21073         * combine.c (try_combine): Delete redundant i1 test.  Call
21074         prev_nonnote_nondebug_insn instead of prev_nonnote_insn.
21076 2017-03-20  Aaron Sawdey  <acsawdey@linux.vnet.ibm.com>
21078         PR target/80083
21079         * config/rs6000/rs6000.md (*movsi_internal1): Fix constraints for
21080         alternatives 13/14.
21082 2017-03-20  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
21084         PR tree-optimization/80054
21085         * gimple-ssa-strength-reduction.c (all_phi_incrs_profitable): Fail
21086         the optimization if a PHI or any of its arguments is not dominated
21087         by the candidate's basis.  Use gphi* rather than gimple* as
21088         appropriate.
21089         (replace_profitable_candidates): Clean up a gimple* variable that
21090         should be a gphi* variable.
21092 2017-03-20  Martin Sebor  <msebor@redhat.com>
21094         PR c++/52477
21095         * doc/extend.texi (attribute constructor): Document present limitation.
21097 2017-03-20  Kelvin Nilsen  <kelvin@gcc.gnu.org>
21099         PR target/79963
21100         * config/rs6000/altivec.h (vec_all_ne): Under __cplusplus__ and
21101         __POWER9_VECTOR__ #ifdef control, change template definition to
21102         use Power9-specific built-in function.
21103         (vec_any_eq): Likewise.
21104         * config/rs6000/vector.md (vector_ae_v2di_p): Change the flag used
21105         to control outcomes from this test.
21106         (vector_ae_<mode>p): For VEC_F modes, likewise.
21108 2017-03-20  Ian Lance Taylor  <iant@google.com>
21110         * config/i386/i386.c (ix86_function_regparm): Save an extra
21111         register for -fsplit-stack with DECL_STATIC_CHAIN.
21113 2017-03-17  Palmer Dabbelt  <palmer@dabbelt.com>
21115         PR target/79912
21116         * config/riscv/riscv.c (riscv_preferred_reload_class): Remove.
21117         (TARGET_PREFERRED_RELOAD_CLASS): Likewise.
21119 2017-03-17  Palmer Dabbelt  <palmer@dabbelt.com>
21121         * config/riscv/riscv.c (riscv_print_operand): Use "fence
21122         iorw,ow".
21123         * config/riscv/sync.mc (mem_thread_fence_1): Use "fence
21124         iorw,iorw".
21126 2017-03-20  Marek Polacek  <polacek@redhat.com>
21128         PR sanitizer/80063
21129         * asan.c (DEF_SANITIZER_BUILTIN): Use do { } while (0).
21131 2017-03-20  Richard Biener  <rguenther@suse.de>
21133         PR tree-optimization/80113
21134         * graphite-isl-ast-to-gimple.c (copy_loop_phi_nodes): Do not
21135         allocate extra SSA name for PHI def.
21136         (add_close_phis_to_outer_loops): Likewise.
21137         (add_close_phis_to_merge_points): Likewise.
21138         (copy_loop_close_phi_args): Likewise.
21139         (copy_cond_phi_nodes): Likewise.
21141 2017-03-20  Martin Liska  <mliska@suse.cz>
21143         PR middle-end/79753
21144         * tree-chkp.c (chkp_build_returned_bound): Do not build
21145         returned bounds for a LHS that's not a BOUNDED_P type.
21147 2017-03-20  Martin Liska  <mliska@suse.cz>
21149         PR target/79769
21150         PR target/79770
21151         * tree-chkp.c (chkp_find_bounds_1): Handle REAL_CST,
21152         COMPLEX_CST and VECTOR_CST.
21154 2017-03-20  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
21156         PR target/78857
21157         * config/s390/s390.md ("cmp<mode>_ccs_0"): Add a clobber of the
21158         target operand.  A new splitter adds the clobber statement in case
21159         the target operand is dead anyway.
21161 2017-03-19  Gerald Pfeifer  <gerald@pfeifer.com>
21163         * doc/install.texi (Specific) <sparc-*-linux*>: No longer refer
21164         to age-old versions of binutils and glibc.
21166 2017-03-18  Segher Boessenkool  <segher@kernel.crashing.org>
21168         * doc/contrib.texi (Contributors): Remove duplicate entry for myself.
21170 2017-03-18  Gerald Pfeifer  <gerald@pfeifer.com>
21172         * doc/contrib.texi (Contributors): Add Segher Boessenkool.
21174 2017-03-18  Gerald Pfeifer  <gerald@pfeifer.com>
21176         * doc/install.texi (Specific) <arm-*-eabi>: Remove old
21177         requirement for binutils 2.13.
21179 2017-03-17  Jim Wilson  <jim.wilson@linaro.org>
21181         * combine.c (try_combine): Delete redundant i1 test.  Call
21182         prev_nonnote_nondebug_insn instead of prev_nonnote_insn.
21184 2017-03-17  Palmer Dabbelt  <palmer@dabbelt.com
21186         * doc/install.texi (Specific) <riscv32-*-elf>: Add riscv32-*-elf,
21187         riscv32-*-linux, riscv64-*-elf, riscv64-*-linux to the table of
21188         contents.
21189         <riscv64-*-elf>: Re-arrange section
21190         <riscv32-*-elf>: Add a note about requiring binutils 2.28.
21191         <riscv32-*-linux>: Likewise.
21192         <riscv64-*-elf>: Likewise
21193         <riscv64-*-linux>: Likewise.
21195 2017-03-17  Richard Earnshaw  <rearnsha@arm.com>
21197         PR target/80052
21198         * aarch64.opt(verbose-cost-dump): Fix typo.
21200 2017-03-17  Pat Haugen  <pthaugen@us.ibm.com>
21202         PR target/79951
21203         * config/rs6000/rs6000.md (copysign<mode>3_fcpsgn): Test
21204         for VECTOR_UNIT_VSX_P (<MODE>mode) too.
21206 2017-03-17  Bernd Schmidt  <bschmidt@redhat.com>
21208         * reload.c (find_reloads): When reloading a nonoffsettable address,
21209         use RELOAD_OTHER for it and its address reloads.
21211         PR rtl-optimization/79910
21212         * combine.c (record_used_regs): New static function.
21213         (try_combine): Handle situations where there is an additional
21214         instruction between I2 and I3 which needs to have a LOG_LINK
21215         updated.
21217 2017-03-17  Jeff Law  <law@redhat.com>
21219         PR tree-optimization/71437
21220         * tree-vrp.c (simplify_stmt_for_jump_threading): Lookup the
21221         conditional in the hash table first.
21222         (vrp_dom_walker::before_dom_children): Extract condition from
21223         ASSERT_EXPR.  Record condition, its inverion and any implied
21224         conditions as well.
21226 2017-03-17  Marek Polacek  <polacek@redhat.com>
21227             Markus Trippelsdorf  <markus@trippelsdorf.de>
21229         PR tree-optimization/80079
21230         * gimple-ssa-store-merging.c (class pass_store_merging): Initialize
21231         m_stores_head.
21233 2017-03-17  Richard Biener  <rguenther@suse.de>
21235         PR middle-end/80075
21236         * tree-eh.c (stmt_could_throw_1_p): Only handle gimple assigns.
21237         Properly verify the LHS before the RHS possibly claims to be
21238         handled.
21239         (stmt_could_throw_p): Hande gimple conds fully here.  Clobbers
21240         do not throw.
21242 2017-03-17  Martin Jambor  <mjambor@suse.cz>
21244         * doc/invoke.texi (Option Options): Include -fipa-vrp in the list.
21245         (List of -O2 options): Likewise.
21246         (-fipa-bit-cp): Replace "ipa" with "interprocedural."
21247         (-fipa-vrp) New.
21249 2017-03-17  Tom de Vries  <tom@codesourcery.com>
21251         * gcov-dump.c (print_usage): Print bug_report_url.
21253 2017-03-17  Richard Biener  <rguenther@suse.de>
21255         PR middle-end/80050
21256         * genmatch.c (parser::next): Remove pointless check for CPP_EOF.
21257         (parser::peek): Likewise.
21259 2017-03-17  Richard Biener  <rguenther@suse.de>
21261         PR tree-optimization/80048
21262         * sese.c (free_sese_info): Properly release rename_map and
21263         copied_bb_map elements.
21265 2017-03-16  Alexandre Oliva <aoliva@redhat.com>
21267         * gimple-ssa-store-merging.c (struct imm_store_chain_info):
21268         Add linked-list forward and backlinks.  Insert on
21269         construction, remove on destruction.
21270         (class pass_store_merging): Add m_stores_head field.
21271         (pass_store_merging::terminate_and_process_all_chains):
21272         Iterate over m_stores_head list.
21273         (pass_store_merging::terminate_all_aliasing_chains):
21274         Likewise.
21275         (pass_store_merging::execute): Check for debug stmts first.
21276         Push new chains onto the m_stores_head stack.
21278 2017-03-16  Michael Meissner  <meissner@linux.vnet.ibm.com>
21280         PR target/71294
21281         * config/rs6000/vsx.md (vsx_splat_<mode>, VSX_D iterator): Allow a
21282         SPLAT operation on ISA 2.07 64-bit systems that have direct move,
21283         but no MTVSRDD support, by doing MTVSRD and XXPERMDI.
21285 2017-03-16  Jeff Law  <law@redhat.com>
21287         PR tree-optimization/71437
21288         * tree-ssa-dom.c (dom_opt_dom_walker): Remove thread_across_edge
21289         member function.  Implementation moved into after_dom_children
21290         member function and into the threader's thread_outgoing_edges
21291         function.
21292         (dom_opt_dom_walker::after_dom_children): Simplify by moving
21293         some code into new thread_outgoing_edges.
21294         * tree-ssa-threadedge.c (thread_across_edge): Make static and simplify
21295         definition.  Simplify marker handling (do it here).   Assume we always
21296         have the available expression and the const/copies tables.
21297         (thread_outgoing_edges): New function extracted from tree-ssa-dom.c
21298         and tree-vrp.c
21299         * tree-ssa-threadedge.h (thread_outgoing_edges): Declare.
21300         * tree-vrp.c (equiv_stack): No longer file scoped.
21301         (vrp_dom_walker): New class.
21302         (vrp_dom_walker::before_dom_children): New member function.
21303         (vrp_dom_walker::after_dom_children): Likewise.
21304         (identify_jump_threads):  Setup domwalker.  Use it rather than
21305         walking edges in a random order by hand.  Simplify setup/finalization.
21306         (finalize_jump_threads): Remove.
21307         (vrp_finalize): Do not call identify_jump_threads here.
21308         (execute_vrp): Do it here instead and call thread_through_all_blocks
21309         here too.
21311         PR tree-optimization/71437
21312         * tree-ssa-dom.c (pfn_simplify): Add basic_block argument.  All
21313         callers changed.
21314         (simplify_stmt_for_jump_threading): Add basic_block argument.  All
21315         callers changed.
21316         (lhs_of_dominating_assert): Moved from here into tree-vrp.c.
21317         (dom_opt_dom_walker::thread_across_edge): Remove
21318         handle_dominating_asserts argument.  All callers changed.
21319         (record_temporary_equivalences_from_stmts_at_dest): Corresponding
21320         changes.  Remove calls to lhs_of_dominating_assert.  Other
21321         uses of handle_dominating_asserts turn into unconditional code
21322         (simplify_control_stmt_condition_1): Likewise.
21323         (simplify_control_stmt_condition): Likewise.
21324         (thread_through_normal_block, thread_across_edge): Likewise.
21325         * tree-ssa-threadedge.h (thread_across_edge): Corresponding changes.
21326         * tree-vrp.c (lhs_of_dominating_assert): Move here.  Return original
21327         object if it is not an SSA_NAME.
21328         (simplify_stmt_for_jump_threading): Call lhs_of_dominating_assert
21329         before calling into the VRP specific simplifiers.
21330         (identify_jump_threads): Remove handle_dominating_asserts
21331         argument.
21333 2017-03-16  Jakub Jelinek  <jakub@redhat.com>
21335         PR fortran/79886
21336         * tree-diagnostic.c (default_tree_printer): No longer static.
21337         * tree-diagnostic.h (default_tree_printer): New prototype.
21339 2017-03-16  Tamar Christina  <tamar.christina@arm.com>
21341         * config/aarch64/aarch64-simd.md (*aarch64_simd_mov<mode>)
21342         Change ins into fmov.
21344 2017-03-16  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
21346         * config/aarch64/iterators.md (h_con): Return "x" for V4HF and V8HF.
21347         * config/aarch64/aarch64-simd.md (*aarch64_fma4_elt_from_dup<mode>):
21348         Use h_con constraint for operand 1.
21349         (*aarch64_fnma4_elt_from_dup<mode>): Likewise.
21350         (*aarch64_mulx_elt_from_dup<mode>): Likewise for operand 2.
21352 2017-03-15  Jeff Law  <law@redhat.com>
21354         PR tree-optimization/71437
21355         * tree-ssa-dom.c (derive_equivalences_from_bit_ior): New function.
21356         (record_temporary_equivalences): Use it.
21358         PR tree-optimization/71437
21359         * tree-ssa-dom.c (struct cond_equivalence): Moved from here into
21360         tree-ssa-scopedtables.
21361         (lookup_avail_expr, build_and_record_new_cond): Likewise.
21362         (record_conditions, record_cond, vuse_eq): Likewise.
21363         (record_edge_info): Adjust to API tweak of record_conditions.
21364         (simplify_stmt_for_jump_threading): Similarly for lookup_avail_expr.
21365         (record_temporary_equivalences, optimize_stmt): Likewise.
21366         (eliminate_redundant_computations): Likewise.
21367         (record_equivalences_from_stmt): Likewise.
21368         * tree-ssa-scopedtables.c: Include options.h and params.h.
21369         (vuse_eq): New function, moved from tree-ssa-dom.c
21370         (build_and_record_new_cond): Likewise.
21371         (record_conditions): Likewise.  Accept vector of conditions rather
21372         than edge_equivalence structure for first argument.
21373         for the first argument.
21374         (avail_exprs_stack::lookup_avail_expr): New member function, moved
21375         from tree-ssa-dom.c.
21376         (avail_exprs_stack::record_cond): Likewise.
21377         * tree-ssa-scopedtables.h (struct cond_equivalence): Moved here
21378         from tree-ssa-dom.c.
21379         (avail_exprs_stack): Add new member functions lookup_avail_expr
21380         and record_cond.
21381         (record_conditions): Declare.
21383 2017-03-15  Vladimir Makarov  <vmakarov@redhat.com>
21385         PR target/80017
21386         * lra-constraints.c (process_alt_operands): Increase reject for
21387         reloading an input/output operand.
21389 2017-03-15  Michael Meissner  <meissner@linux.vnet.ibm.com>
21391         PR target/79038
21392         * config/rs6000/rs6000.md (float<QHI:mode><IEEE128:mode>2): Define
21393         insns to convert from signed/unsigned char/short to IEEE 128-bit
21394         floating point.
21395         (floatuns<QHI:mode><IEEE128:mode>2): Likewise.
21397 2017-03-15  Uros Bizjak  <ubizjak@gmail.com>
21399         PR target/80019
21400         * config/i386/i386.c (ix86_vector_duplicate_value): Create
21401         subreg of inner mode for values already in registers.
21403 2017-03-15  Bernd Schmidt  <bschmidt@redhat.com>
21405         * config/c6x/c6x.c (hwloop_optimize): Handle case where the old
21406         iteration reg is used after the loop.
21408 2017-03-14  Martin Sebor  <msebor@redhat.com>
21410         PR tree-optimization/79800
21411         * gimple-ssa-sprintf.c (format_floating: Add argument.  Handle
21412         precision in negative-positive range.
21413         (format_floating): Call non-const overload with adjusted precision.
21415 2017-03-14  Michael Meissner  <meissner@linux.vnet.ibm.com>
21417         PR target/79947
21418         * config/rs6000/rs6000.h (TARGET_FRSQRTES): Add check for
21419         -mpowerpc-gfxopt.
21421 2017-03-14  Martin Sebor  <msebor@redhat.com>
21423         PR middle-end/80020
21424         * builtin-attrs.def (ATTR_ALLOC_SIZE_2_NOTHROW_LIST): New macro.
21425         * builtins.def (aligned_alloc): Use it.
21427         PR c/79936
21428         * Makefile.in (GTFILES): Add calls.c.
21429         * calls.c: Include "gt-calls.h".
21431 2017-03-14  Bernd Schmidt  <bschmidt@redhat.com>
21433         PR rtl-optimization/79728
21434         * regs.h (struct target_regs): New field
21435         x_contains_allocatable_regs_of_mode.
21436         (contains_allocatable_regs_of_mode): New macro.
21437         * reginfo.c (init_reg_sets_1): Initialize it, and change
21438         contains_reg_of_mode so it includes global regs as well.
21439         * reload.c (push_reload): Use contains_allocatable_regs_of_mode
21440         rather than contains_regs_of_mode.
21442 2017-03-14  Martin Liska  <mliska@suse.cz>
21444         * doc/invoke.texi: Document options that can't be combined with
21445         -fcheck-pointer-bounds.
21447 2017-03-14  Martin Liska  <mliska@suse.cz>
21449         PR middle-end/79831
21450         * doc/invoke.texi (-Wchkp): Document the option.
21452 2017-03-14  Martin Liska  <mliska@suse.cz>
21454         * Makefile.in: Install gcov-dump.
21456 2017-03-14  Martin Liska  <mliska@suse.cz>
21458         * multiple_target.c (expand_target_clones): Bail out for
21459         an invalid attribute.
21461 2017-03-14  Richard Biener  <rguenther@suse.de>
21463         * alias.c (struct alias_set_entry): Pack properly.
21464         * cfgloop.h (struct loop): Likewise.
21465         * cse.c (struct set): Likewise.
21466         * ipa-utils.c (struct searchc_env): Likewise.
21467         * loop-invariant.c (struct invariant): Likewise.
21468         * lra-remat.c (struct cand): Likewise.
21469         * recog.c (struct change_t): Likewise.
21470         * rtl.h (struct address_info): Likewise.
21471         * symbol-summary.h (function_summary): Likewise.
21472         * tree-loop-distribution.c (struct partition): Likewise.
21473         * tree-object-size.c (struct object_size_info): Likewise.
21474         * tree-ssa-loop-ivopts.c (struct cost_pair): Likewise.
21475         * tree-ssa-threadupdate.c (struct ssa_local_info_t): Likewise.
21476         * tree-vect-data-refs.c (struct _vect_peel_info): Likewise.
21477         * tree-vect-slp.c (struct _slp_oprnd_info): Likewise.
21478         * tree-vect-stmts.c (struct simd_call_arg_info): Likewise.
21479         * tree-vectorizer.h (struct _loop_vec_info): Likewise.
21480         (struct _stmt_vec_info): Likewise.
21482 2017-03-14  Martin Liska  <mliska@suse.cz>
21484         PR target/79892
21485         * multiple_target.c (create_dispatcher_calls): Check that
21486         a target can create a function dispatcher.
21488 2017-03-14  Martin Liska  <mliska@suse.cz>
21490         PR lto/66295
21491         * multiple_target.c (expand_target_clones): Drop local.local
21492         flag for default implementation.
21494 2017-03-14  Richard Biener  <rguenther@suse.de>
21496         PR tree-optimization/80030
21497         * tree-vect-stmts.c (vectorizable_store): Plug memleak.
21499 2017-03-13  Kito Cheng  <kito.cheng@gmail.com>
21501         * config/riscv/riscv.c (riscv_emit_float_compare>: Use
21502         gcc_fallthrough() instead of __attribute__((fallthrough));
21504 2017-03-13  Gerald Pfeifer  <gerald@pfeifer.com>
21506         * doc/gcc.texi: Remove "up" link to (DIR).
21507         * doc/gccint.texi: Ditto.
21509 2017-03-13  Gerald Pfeifer  <gerald@pfeifer.com>
21511         * doc/install.texi (Specific) <avr>: Remove reference to
21512         binutils 2.13.
21514 2017-03-13  Jeff Law  <law@redhat.com>
21516         * config/riscv/riscv.c (riscv_emit_float_compare): Use fallthru
21517         attribute rather than comments.
21519         * config/pdp11/pdp11.md (movmemhi): Adjust operand numbers to
21520         match_scratch operand is highest.
21522 2017-03-13  Martin Liska  <mliska@suse.cz>
21524         PR middle-end/78339
21525         * ipa-pure-const.c (warn_function_noreturn): If the declarations
21526         is a CHKP clone, use original declaration.
21528 2017-03-13  Claudiu Zissulescu  <claziss@synopsys.com>
21530         * config/arc/arc.c (arc_init): Use multiplier whenever we have it.
21531         (arc_conditional_register_usage): Use a different allocation order
21532         when optimizing for size.
21533         * common/config/arc/arc-common.c (arc_option_optimization_table):
21534         Section anchors default on when optimizing for size.
21536 2017-03-13  Claudiu Zissulescu  <claziss@synopsys.com>
21538         * config/arc/arc.md (*tst_bitfield_tst): Fix pattern.
21540 2017-03-13  Claudiu Zissulescu  <claziss@synopsys.com>
21542         * config/arc/arc.c (arc_output_addsi): Emit code density adds.
21543         * config/arc/arc.md (cpu_facility): Add cd variant.
21544         (*movqi_insn): Add code density variant.
21545         (*movhi_insn): Likewise.
21546         (*movqi_insn): Likewise.
21547         (*addsi3_mixed): Likewise.
21548         (subsi3_insn): Likewise.
21550 2017-03-13  Claudiu Zissulescu  <claziss@synopsys.com>
21552         * config/arc/arc.md (movsi_cond_exec): Update constraint.
21554 2017-03-13  Claudiu Zissulescu  <claziss@synopsys.com>
21556         * config/arc/arc.c (arc_legitimize_pic_address): Handle PIC
21557         expressions with MINUS and UNARY ops.
21559 2017-03-13  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
21561         PR target/79911
21562         * config/arm/neon.md (vec_sel_widen_ssum_lo<VQI:mode><VW:mode>3):
21563         Rename to...
21564         (vec_sel_widen_ssum_lo<mode><V_half>3): ... This. Avoid mismatch
21565         between vec_select and vector argument.
21566         (vec_sel_widen_ssum_hi<VQI:mode><VW:mode>3): Rename to...
21567         (vec_sel_widen_ssum_hi<mode><V_half>3): ... This. Likewise.
21568         (vec_sel_widen_usum_lo<VQI:mode><VW:mode>3): Rename to...
21569         (vec_sel_widen_usum_lo<mode><V_half>3): ... This.
21570         (vec_sel_widen_usum_hi<VQI:mode><VW:mode>3): Rename to...
21571         (vec_sel_widen_usum_hi<mode><V_half>3): ... This.
21573 2017-03-13  Richard Biener  <rguenther@suse.de>
21575         PR other/79991
21576         * params.def (vect-max-peeling-for-alignment): Fix typo.
21578 2017-03-12  Gerald Pfeifer  <gerald@pfeifer.com>
21580         * doc/install.texi (Specific) <mips-*-*>: Remove description of
21581         issue that only occurred with binutils below 2.18.
21583 2017-03-12  Gerald Pfeifer  <gerald@pfeifer.com>
21585         * doc/install.texi (Specific) <cris-axis-elf>: No longer
21586         refer to binutils 2.11/2.12 minimum.
21588 2017-03-12  Gerald Pfeifer  <gerald@pfeifer.com>
21590         * doc/install.texi (Specific) <powerpc-*-*>: Remove link to
21591         ftp.kernel.org and simplify binutils requirement.
21593 2017-03-11  Gerald Pfeifer  <gerald@pfeifer.com>
21595         * doc/invoke.texi (Warning Options): Fix spelling of link-time
21596         optimization.
21597         (Optimize Options): Ditto.  Also remove redundancy.
21599 2017-03-10  David Malcolm  <dmalcolm@redhat.com>
21601         PR translation/79848
21602         * ipa-devirt.c (warn_types_mismatch): Simplify uses of "%<%s%>" to
21603         "%qs".
21604         * ipa-pure-const.c (suggest_attribute): Likewise.  Convert _
21605         to G_ to avoid double translation.
21607 2017-03-10  David Malcolm  <dmalcolm@redhat.com>
21609         PR translation/79923
21610         * auto-profile.c (get_combined_location): Convert leading
21611         character of diagnostics to lower case and remove trailing period.
21612         (read_profile): Likewise for various diagnostics.
21613         * config/arm/arm.c (arm_option_override): Remove trailing period
21614         from various diagnostics.
21615         * config/msp430/msp430.c (msp430_expand_delay_cycles): Likewise.
21616         (msp430_expand_delay_cycles): Likewise.
21618 2017-03-10  David Malcolm  <dmalcolm@redhat.com>
21620         PR target/79925
21621         * config/aarch64/aarch64.c (aarch64_validate_mcpu): Quote the
21622         full command-line argument, rather than just "str".
21623         (aarch64_validate_march): Likewise.
21624         (aarch64_validate_mtune): Likewise.
21626 2017-03-10  Bernd Schmidt  <bschmidt@redhat.com>
21628         PR rtl-optimization/78911
21629         * lra-assigns.c (must_not_spill_p): New function.
21630         (spill_for): Use it.
21632 2017-03-10  Jakub Jelinek  <jakub@redhat.com>
21634         PR tree-optimization/79981
21635         * tree-vrp.c (extract_range_basic): Handle IMAGPART_EXPR of
21636         ATOMIC_COMPARE_EXCHANGE ifn result.
21637         (stmt_interesting_for_vrp, vrp_visit_stmt): Handle
21638         IFN_ATOMIC_COMPARE_EXCHANGE.
21640 2017-03-10  David Malcolm  <dmalcolm@redhat.com>
21642         PR driver/79875
21643         * opts.c (parse_sanitizer_options): Add missing question mark to
21644         "did you mean" message.
21646 2017-03-10  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
21648         * config/rs6000/rs6000-builtin.def (VMULEUB_UNS): Remove orphaned
21649         built-in.
21650         (VMULEUH_UNS): Likewise.
21651         (VMULOUB_UNS): Likewise.
21652         (VMULOUH_UNS): Likewise.
21653         * config/rs6000/rs6000.c (builtin_function_type): Remove
21654         references to ALTIVEC_BUILTIN_VMUL[EO]U[BH]_UNS.
21656 2017-03-10  David Malcolm  <dmalcolm@redhat.com>
21658         PR bootstrap/79952
21659         * read-rtl-function.c (function_reader::read_rtx_operand): Update
21660         x with result of extra_parsing_for_operand_code_0.
21661         (function_reader::extra_parsing_for_operand_code_0): Convert
21662         return type from void to rtx, returning x.  When reading
21663         SYMBOL_REF with SYMBOL_FLAG_HAS_BLOCK_INFO, reallocate x to the
21664         larger size containing struct block_symbol.
21666 2017-03-10  Segher Boessenkool  <segher@kernel.crashing.org>
21668         * config/rs6000/rs6000.c (rs6000_option_override_internal): Disallow
21669         -mfloat128-hardware without -m64.
21671 2017-03-10  Will Schmidt <will_schmidt@vnet.ibm.com>
21673         PR target/79941
21674         * config/rs6000/rs6000.c (builtin_function_type): Add VMUL*U[HB]
21675         entries to the case statement that marks unsigned arguments to
21676         overloaded functions.
21678 2017-03-10  Kelvin Nilsen  <kelvin@gcc.gnu.org>
21680         * config/rs6000/rs6000.c (rs6000_option_override_internal): Fix
21681         two typographic errors in the handling of TARGET_UPPER_REGS_DI.
21683 2017-03-10  Pat Haugen  <pthaugen@us.ibm.com>
21685         PR target/79907
21686         * config/rs6000/rs6000.c (rs6000_init_hard_regno_mode_ok): Test
21687         TARGET_UPPER_REGS_DI when setting 'wi' constraint regclass.
21689 2017-03-10  Martin Liska  <mliska@suse.cz>
21691         PR target/65705
21692         PR target/69804
21693         * toplev.c (process_options): Enable MPX with LSAN and UBSAN.
21694         * tree-chkp.c (chkp_walk_pointer_assignments): Verify that
21695         FIELD != NULL.
21697 2017-03-10  Olivier Hainque  <hainque@adacore.com>
21699         * tree-switch-conversion (array_value_type): Start by resetting
21700         candidate type to it's main variant.
21702 2017-03-10  Jakub Jelinek  <jakub@redhat.com>
21704         PR rtl-optimization/79909
21705         * combine.c (try_combine): Use simplify_replace_rtx on individual
21706         CALL_INSN_FUNCTION_USAGE elements instead of replace_rtx on copy_rtx
21707         of the whole CALL_INSN_FUNCTION_USAGE.
21709         PR tree-optimization/79972
21710         * gimple-ssa-warn-alloca.c (alloca_call_type): Only call
21711         get_range_info on SSA_NAMEs.  Formatting fixes.
21713 2017-03-10  Richard Biener  <rguenther@suse.de>
21714             Jakub Jelinek  <jakub@redhat.com>
21716         PR tree-optimization/77975
21717         * tree-ssa-loop-niter.c (get_base_for): Allow phi argument from latch
21718         edge to be constant.
21719         (get_val_for): For constant x return it.  Formatting fix.
21720         (loop_niter_by_eval): Avoid pointless looping if the next iteration
21721         would use the same bases as the current one.
21723 2017-03-09  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
21725         * config/rs6000/rs6000.c (rs6000_gen_le_vsx_permute): Use rotate
21726         instead of vec_select for V1TImode.
21727         * conifg/rs6000/vsx.md (VSX_LE): Remove mode iterator that is no
21728         longer needed.
21729         (VSX_LE_128): Add V1TI to this mode iterator.
21730         (*vsx_le_perm_load_<mode>): Change to use VSX_D mode iterator.
21731         (*vsx_le_perm_store_<mode>): Likewise.
21732         (pre-reload splitter for VSX stores): Likewise.
21733         (post-reload splitter for VSX stores): Likewise.
21734         (*vsx_xxpermdi2_le_<mode>): Likewise.
21735         (*vsx_lxvd2x2_le_<mode>): Likewise.
21736         (*vsx_stxvd2x2_le_<mode>): Likewise.
21738 2017-03-09  Michael Eager  <eager@eagercon.com>
21740         Correct failures with --enable-checking=yes,rtl.
21742         * config/microblaze/microblaze.c (microblaze_expand_shift):
21743         Replace GET_CODE test with CONST_INT_P and INTVAL test with
21744         test for const0_rtx.
21745         * config/microblaze/microblaze.md (ashlsi3_byone, ashrsi3_byone,
21746         lshrsi3_byone): Replace INTVAL with test for const1_rtx.
21748 2017-03-09  Richard Biener  <rguenther@suse.de>
21750         PR tree-optimization/79977
21751         * graphite-scop-detection.c (scop_detection::merge_sese):
21752         Handle the case of extra exits to blocks dominating the entry.
21754 2017-03-09  Toma Tabacu  <toma.tabacu@imgtec.com>
21756         * doc/sourcebuild.texi (Effective-Target Keywords, Other attributes):
21757         Document rdynamic.
21759 2017-03-09  Vladimir Makarov  <vmakarov@redhat.com>
21761         PR rtl-optimization/79949
21762         * lra-constraints.c (process_alt_operands): Check memory when
21763         trying to predict a cycle.  Print about the overall increase.
21765 2017-03-09  Richard Biener  <rguenther@suse.de>
21767         PR middle-end/79971
21768         * gimple-expr.c (useless_type_conversion_p): Preserve
21769         TYPE_SATURATING for fixed-point types.
21771 2017-03-09  Richard Biener  <rguenther@suse.de>
21773         PR ipa/79970
21774         * ipa-prop.c (ipa_modify_formal_parameters): Avoid changing
21775         alignment of BLKmode params.
21777 2017-03-09  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
21779         PR target/79913
21780         * config/aarch64/iterators.md (VALL_F16_NO_V2Q): New mode iterator.
21781         (VALL_NO_V2Q): Likewise.
21782         (VDQF_DF): Delete.
21783         * config/aarch64/aarch64-simd.md
21784         (aarch64_dup_lane_<vswap_width_name><mode>): Use VALL_F16_NO_V2Q
21785         iterator.
21786         (*aarch64_simd_vec_copy_lane_<vswap_width_name><mode>): Use
21787         VALL_NO_V2Q mode iterator.
21788         (*aarch64_vgetfmulx<mode>): Use VDQF iterator.
21790 2017-03-09  Martin Liska  <mliska@suse.cz>
21792         PR tree-optimization/79631
21793         * tree-chkp-opt.c (chkp_is_constant_addr): Call
21794         tree_int_cst_sign_bit just for INTEGER constants.
21796 2017-03-09  Martin Liska  <mliska@suse.cz>
21798         PR target/65705
21799         PR target/69804
21800         * toplev.c (process_options): Disable -fcheck-pointer-bounds with
21801         sanitizers.
21803 2017-03-09  Marek Polacek  <polacek@redhat.com>
21805         PR c++/79672
21806         * tree.c (inchash::add_expr): Handle TREE_VEC.
21808 2017-03-09  Martin Liska  <mliska@suse.cz>
21810         PR ipa/79764
21811         (chkp_narrow_size_and_offset): New function.
21812         (chkp_parse_array_and_component_ref): Support BIT_FIELD_REF.
21813         (void chkp_parse_bit_field_ref): New function.
21814         (chkp_make_addressed_object_bounds): Add case for BIT_FIELD_REF.
21815         (chkp_process_stmt): Use chkp_parse_bit_field_ref.
21817 2017-03-09  Martin Liska  <mliska@suse.cz>
21819         PR ipa/79761
21820         * tree-chkp.c (chkp_get_bound_for_parm): Get bounds for a param.
21821         (chkp_find_bounds_1): Remove gcc_unreachable.
21823 2017-03-09  Jakub Jelinek  <jakub@redhat.com>
21825         PR sanitizer/79944
21826         * asan.c (get_mem_refs_of_builtin_call): For BUILT_IN_ATOMIC* and
21827         BUILT_IN_SYNC*, determine the access type from the size suffix and
21828         always build a MEM_REF with that type.  Handle forgotten
21829         BUILT_IN_SYNC_FETCH_AND_NAND_16 and BUILT_IN_SYNC_NAND_AND_FETCH_16.
21831         PR target/79932
21832         * config/i386/avx512vlintrin.h (_mm256_cmpge_epi32_mask,
21833         _mm256_cmpge_epi64_mask, _mm256_cmpge_epu32_mask,
21834         _mm256_cmpge_epu64_mask, _mm256_cmple_epi32_mask,
21835         _mm256_cmple_epi64_mask, _mm256_cmple_epu32_mask,
21836         _mm256_cmple_epu64_mask, _mm256_cmplt_epi32_mask,
21837         _mm256_cmplt_epi64_mask, _mm256_cmplt_epu32_mask,
21838         _mm256_cmplt_epu64_mask, _mm256_cmpneq_epi32_mask,
21839         _mm256_cmpneq_epi64_mask, _mm256_cmpneq_epu32_mask,
21840         _mm256_cmpneq_epu64_mask, _mm256_mask_cmpge_epi32_mask,
21841         _mm256_mask_cmpge_epi64_mask, _mm256_mask_cmpge_epu32_mask,
21842         _mm256_mask_cmpge_epu64_mask, _mm256_mask_cmple_epi32_mask,
21843         _mm256_mask_cmple_epi64_mask, _mm256_mask_cmple_epu32_mask,
21844         _mm256_mask_cmple_epu64_mask, _mm256_mask_cmplt_epi32_mask,
21845         _mm256_mask_cmplt_epi64_mask, _mm256_mask_cmplt_epu32_mask,
21846         _mm256_mask_cmplt_epu64_mask, _mm256_mask_cmpneq_epi32_mask,
21847         _mm256_mask_cmpneq_epi64_mask, _mm256_mask_cmpneq_epu32_mask,
21848         _mm256_mask_cmpneq_epu64_mask, _mm_cmpge_epi32_mask,
21849         _mm_cmpge_epi64_mask, _mm_cmpge_epu32_mask, _mm_cmpge_epu64_mask,
21850         _mm_cmple_epi32_mask, _mm_cmple_epi64_mask, _mm_cmple_epu32_mask,
21851         _mm_cmple_epu64_mask, _mm_cmplt_epi32_mask, _mm_cmplt_epi64_mask,
21852         _mm_cmplt_epu32_mask, _mm_cmplt_epu64_mask, _mm_cmpneq_epi32_mask,
21853         _mm_cmpneq_epi64_mask, _mm_cmpneq_epu32_mask, _mm_cmpneq_epu64_mask,
21854         _mm_mask_cmpge_epi32_mask, _mm_mask_cmpge_epi64_mask,
21855         _mm_mask_cmpge_epu32_mask, _mm_mask_cmpge_epu64_mask,
21856         _mm_mask_cmple_epi32_mask, _mm_mask_cmple_epi64_mask,
21857         _mm_mask_cmple_epu32_mask, _mm_mask_cmple_epu64_mask,
21858         _mm_mask_cmplt_epi32_mask, _mm_mask_cmplt_epi64_mask,
21859         _mm_mask_cmplt_epu32_mask, _mm_mask_cmplt_epu64_mask,
21860         _mm_mask_cmpneq_epi32_mask, _mm_mask_cmpneq_epi64_mask,
21861         _mm_mask_cmpneq_epu32_mask, _mm_mask_cmpneq_epu64_mask): Move
21862         definitions outside of __OPTIMIZE__ guarded section.
21864         PR target/79932
21865         * config/i386/avx512bwintrin.h (_mm512_packs_epi32,
21866         _mm512_maskz_packs_epi32, _mm512_mask_packs_epi32,
21867         _mm512_packus_epi32, _mm512_maskz_packus_epi32,
21868         _mm512_mask_packus_epi32): Move definitions outside of __OPTIMIZE__
21869         guarded section.
21871 2017-03-09  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
21873         * config/s390/vx-builtins.md ("vfee<mode>", "vfeez<mode>")
21874         ("vfenez<mode>"): Add missing constraints.
21876 2017-03-08  Martin Sebor  <msebor@redhat.com>
21878         PR target/79928
21879         * config/nds32/nds32.c (nds32_option_override):
21880         Fix misspelled diagnostic.
21882 2017-03-08  Jakub Jelinek  <jakub@redhat.com>
21884         PR c/79940
21885         * gimplify.c (gimplify_omp_for): Replace index var in outer
21886         taskloop statement with an artificial variable and add
21887         OMP_CLAUSE_PRIVATE clause for it.
21889 2017-03-08  Richard Biener  <rguenther@suse.de>
21891         PR tree-optimization/79955
21892         * tree-ssa-uninit.c (warn_uninitialized_vars): Do not warn
21893         for accesses that are completely outside of the variable.
21895 2017-03-08  Andrew Haley  <aph@redhat.com>
21897         PR tree-optimization/79943
21898         * tree-ssa-loop-split.c (compute_new_first_bound): When
21899         calculating the new upper bound, (END-BEG) should be added, not
21900         subtracted.
21902 2017-03-08  Jakub Jelinek  <jakub@redhat.com>
21904         * config/avr/avr.md (setmemhi): Make sure match_dup
21905         operand number comes before match_scratch.
21907 2017-03-08  Richard Biener  <rguenther@suse.de>
21909         PR tree-optimization/79920
21910         * tree-vect-slp.c (vect_create_mask_and_perm): Remove and inline
21911         with ncopies == 1 to ...
21912         (vect_transform_slp_perm_load): ... here.  Properly compute
21913         all element loads by iterating VF times over the group.  Do
21914         not handle ncopies (computed in a broken way) in
21915         vect_create_mask_and_perm.
21917 2017-03-08  Jakub Jelinek  <jakub@redhat.com>
21919         PR sanitizer/79904
21920         * internal-fn.c (expand_vector_ubsan_overflow): If arg0 or arg1
21921         is a uniform vector, use uniform_vector_p return value instead of
21922         building ARRAY_REF on folded VIEW_CONVERT_EXPR to array type.
21924 2017-03-07  Marek Polacek  <polacek@redhat.com>
21926         PR middle-end/79809
21927         * gimple-ssa-warn-alloca.c (pass_walloca::gate): Use HOST_WIDE_INT.
21928         (alloca_call_type): Likewise.
21930 2017-03-07  Martin Liska  <mliska@suse.cz>
21932         * gcov.c (process_args): Put comment to correct location.
21934 2017-03-07  Martin Liska  <mliska@suse.cz>
21936         PR middle-end/68270
21937         * tree-chkp.c (chkp_may_narrow_to_field): Add new argument ref.
21938         Use array_at_struct_end_p instead of DECL_CHAIN (field).
21939         (chkp_narrow_bounds_for_field): Likewise.
21940         (chkp_parse_array_and_component_ref): Pass one more argument to
21941         call.
21943 2017-03-07  Richard Biener  <rguenther@suse.de>
21945         * tree-vect-loop-manip.c (slpeel_add_loop_guard): Preserve
21946         preheaders.
21948 2017-03-07  Segher Boessenkool  <segher@kernel.crashing.org>
21950         * config/i386/i386.c (ix86_local_alignment): Align most aggregates
21951         of 16 bytes and more to 16 bytes, not those of 16 bits and more.
21953 2017-03-07  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
21955         PR c/79855
21956         * params.def (PARAM_STORE_MERGING_ALLOW_UNALIGNED): Add full stop
21957         to end of description.
21958         (PARAM_MAX_STORES_TO_MERGE): Likewise.
21960 2017-03-07  Jakub Jelinek  <jakub@redhat.com>
21962         PR rtl-optimization/79901
21963         * config/i386/sse.md (*avx512bw_<code><mode>3<mask_name>): Renamed to
21964         ...
21965         (*avx512f_<code><mode>3<mask_name>): ... this.
21966         (<code><mode>3 with maxmin code iterator): Use VI8_AVX2_AVX512F
21967         iterator instead of VI8_AVX2_AVX512BW.
21969         PR rtl-optimization/79901
21970         * expr.c (expand_expr_real_2): For vector MIN/MAX, if there is no
21971         min/max expander, expand it using expand_vec_cond_expr.
21973         PR sanitizer/79897
21974         * ubsan.c (ubsan_encode_value): Call mark_addressable on the
21975         temporary.
21977 2017-03-06  Jakub Jelinek  <jakub@redhat.com>
21979         PR c++/79821
21980         * dwarf2out.h (dw_vec_const): Change array type from unsigned char *
21981         to void * for PCH reasons.
21982         * dwarf2out.c (output_loc_operands, output_die): Cast
21983         v.val_vec.array to unsigned char *.
21985 2017-03-06  John David Anglin  <danglin@gcc.gnu.org>
21987         PR target/77850
21988         * config/pa/pa-64.h (PAD_VARARGS_DOWN): Don't pad down complex and
21989         vector types.
21991 2017-03-06  Vladimir Makarov  <vmakarov@redhat.com>
21993         PR rtl-optimization/79571
21994         * lra-constraints.c (process_alt_operands): Calculate static
21995         reject and subtract it from overall when only addresses will be
21996         reloaded.
21998 2017-03-06  Julia Koval  <julia.koval@intel.com>
22000         PR target/79793
22001         * config/i386/i386.c (ix86_minimum_incoming_stack_boundary): Set
22002         incoming stack boundary to 128 for 64-bit targets.
22004 2017-03-06  Richard Biener  <rguenther@suse.de>
22006         PR tree-optimization/79894
22007         * tree-vectorizer.c (vectorize_loops): Set loop_vectorized_call
22008         to NULL after folding it.
22010 2017-03-06  Richard Biener  <rguenther@suse.de>
22012         PR tree-optimization/79824
22013         * tree-vect-stmts.c (get_group_load_store_type): Fix alignment
22014         check disabling peeling for gaps.
22016 2017-03-06  Toma Tabacu  <toma.tabacu@imgtec.com>
22018         * doc/sourcebuild.texi (Effective-Target Keywords, Environment
22019         attributes): Document gettimeofday.
22021 2017-03-06  Robin Dapp  <rdapp@linux.vnet.ibm.com>
22023         * config/s390/s390.c (s390_option_override_internal): Set
22024         PARAM_MIN_VECT_LOOP_BOUND
22026 2017-03-06  Robin Dapp  <rdapp@linux.vnet.ibm.com>
22028         * config/s390/s390.c (s390_asm_output_function_label): Use nopr %r0.
22029         * config/s390/s390.md: Likewise.
22031 2017-03-06  Jakub Jelinek  <jakub@redhat.com>
22033         PR target/79812
22034         * config/i386/sse.md (VI8F_256_512): Remove mode iterator.
22035         (<avx2_avx512>_perm<mode>): Rename to ...
22036         (avx2_perm<mode>): ... this.  Use VI8F_256 iterator instead
22037         of VI8F_256_512.
22038         (<avx512>_perm<mode>_mask): Rename to ...
22039         (avx512vl_perm<mode>_mask): ... this.  Use VI8F_256 iterator instead
22040         of VI8F_256_512.
22041         (<avx2_avx512>_perm<mode>_1<mask_name>): Rename to ...
22042         (avx2_perm<mode>_1<mask_name): ... this.  Use VI8F_256 iterator
22043         instead of VI8F_256_512.
22044         (avx512f_perm<mode>): New define_expand.
22045         (avx512f_perm<mode>_mask): Likewise.
22046         (avx512f_perm<mode>_1<mask_name>): New define_insn.
22047         (<avx512>_vec_dup<mode>_1): Fix up vec_select mode.
22049 2017-03-06  Prachi Godbole  <prachi.godbole@imgtec.com>
22051         * config/mips/mips-msa.md (msa_fmax_a_<msafmt>, msa_fmin_a_<msafmt>,
22052         msa_max_a_<msafmt>, msa_min_a_<msafmt>): Introduce mode interator for
22053         if_then_else.
22054         (smin<mode>3, smax<mode>3): Change operand print code from 'B' to 'E'.
22056 2017-03-06  Martin Liska  <mliska@suse.cz>
22058         PR sanitize/79783
22059         * asan.c (asan_expand_poison_ifn): Do not expand ASAN_POISON
22060         when having a SSA NAME w/o VAR_DECL assigned to it.
22062 2017-03-06  Prachi Godbole  <prachi.godbole@imgtec.com>
22064         * config/mips/mips-msa.md (msa_dotp_<su>_d, msa_dpadd_<su>_d,
22065         msa_dpsub_<su>_d): Fix MODE for vec_select.
22067 2017-03-06  Prachi Godbole  <prachi.godbole@imgtec.com>
22069         * config/mips/mips.c (mips_gen_const_int_vector): Change type of last
22070         argument.
22071         * config/mips/mips-protos.h (mips_gen_const_int_vector): Likewise.
22073 2017-03-06  Richard Biener  <rguenther@suse.de>
22075         * lto-streamer.c (lto_check_version): Use %qs in diagnostics.
22076         * plugin.c (register_plugin_info): Likewise.
22077         * tree-chkp.c (chkp_make_static_const_bounds): Likewise.
22079 2017-03-05  Jakub Jelinek  <jakub@redhat.com>
22081         * config/i386/sse.md (sse_storehps, sse_storelps,
22082         avx_<castmode><avxsizesuffix>_<castmode>,
22083         avx512f_<castmode><avxsizesuffix>_<castmode>,
22084         avx512f_<castmode><avxsizesuffix>_256<castmode>): Require
22085         in condition that at least one operand is not a MEM.
22087 2017-03-03  Jakub Jelinek  <jakub@redhat.com>
22089         PR middle-end/79805
22090         * internal-fn.def (ATOMIC_BIT_TEST_AND_SET, ATOMIC_BIT_TEST_AND_RESET,
22091         ATOMIC_BIT_TEST_AND_COMPLEMENT, ATOMIC_COMPARE_EXCHANGE): Remove
22092         ECF_NOTHROW.
22093         * gimple-fold.c (fold_builtin_atomic_compare_exchange): Set
22094         gimple_call_nothrow_p flag based on whether original builtin can throw.
22095         If it can, emit following stmts on the fallthrough edge.
22096         * tree-ssa-ccp.c (optimize_atomic_bit_test_and): Similarly, except
22097         don't create new bb if inserting just debug stmts on the edge, try to
22098         insert them on the fallthru bb or just reset debug stmts.
22100 2017-03-03  Segher Boesssenkool  <segher@kernel.crashing.org>
22102         PR target/43763
22103         * config/rs6000/rs6000.c (rs6000_final_prescan_insn): Save and
22104         restore recog_data (including the operand rtxes inside it) around
22105         the call to get_insn_template.
22107 2017-03-03  Martin Sebor  <msebor@redhat.com>
22109         PR tree-optimization/79699
22110         * context.c (context::~context): Free MPFR caches to avoid
22111         a memory leak on program exit.
22113 2017-03-03  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
22115         * config/aarch64/aarch64.c (aarch64_float_const_representable_p):
22116         Use wide_int::ulow () instead of .elt (0).
22118 2017-03-03  Uros Bizjak  <ubizjak@gmail.com>
22120         * config/i386/i386.md (*pushtf): Change *roF constraint to *roC.
22121         (*pushxf): Limit oF constraint to 32bit targets and add oC
22122         constraint for 64bit targets.
22123         (pushxf splitter): Use PUSH_ROUNDING to calculate stack adjustment.
22124         (*pushdf): Change rmF constraint to rmC.
22126 2017-03-03  Martin Liska  <mliska@suse.cz>
22128         * tree-ssa-loop-prefetch.c (pass_loop_prefetch::execute):
22129         Remove unused variable.
22131 2017-03-03  Jakub Jelinek  <jakub@redhat.com>
22133         PR target/79807
22134         * config/i386/i386.c (ix86_expand_multi_arg_builtin): If target
22135         is a memory operand, increase num_memory.
22136         (ix86_expand_args_builtin): Likewise.
22138 2017-03-03  Jan Hubicka  <jh@suse.cz>
22140         PR lto/79760
22141         * ipa-devirt.c (maybe_record_node): Properly handle
22142         __cxa_pure_virtual visibility.
22144 2017-03-03  Martin Liska  <mliska@suse.cz>
22146         PR tree-optimization/79803
22147         * tree-ssa-loop-prefetch.c (tree_ssa_prefetch_arrays): Remove
22148         assert.
22149         (pass_loop_prefetch::execute): Disabled optimization if an
22150         assumption about L1 cache size is not met.
22152 2017-03-03  Martin Liska  <mliska@suse.cz>
22154         PR rtl-optimization/79574
22155         * gcse.c (struct gcse_expr): Use HOST_WIDE_INT instead of int.
22156         (hash_scan_set): Likewise.
22157         (dump_hash_table): Likewise.
22158         (hoist_code): Likewise.
22160 2017-03-03  Richard Biener  <rguenther@suse.de>
22162         * fixed-value.c (fixed_from_string): Restore use of elt (1)
22163         in place of uhigh ().
22164         (fixed_convert_from_real): Likewise.
22166 2017-03-03  Uros Bizjak  <ubizjak@gmail.com>
22168         PR target/79514
22169         * config/i386/i386.md (*pushxf_rounded): Use Pmode instead of DImode.
22171 2017-03-03  Richard Biener  <rguenther@suse.de>
22173         PR middle-end/79818
22174         * match.pd ( X +- C1 CMP C2 -> X CMP C2 -+ C1): Add missing
22175         TYPE_OVERFLOW_UNDEFINED check.
22177 2017-03-02  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
22179         * config/rs6000/vector.md (vector_ne_<mode>_p): Correct operand
22180         numbers.
22181         (vector_ae_<mode>_p): Likewise.
22182         (vector_nez_<mode>_p): Likewise.
22183         (vector_ne_v2di_p): Likewise.
22184         (vector_ae_v2di_p): Likewise.
22185         (vector_ne_<mode>_p): Likewise.
22186         * config/rs6000/vsx.md (vsx_tsqrt<mode>2_fg): Correct operand
22187         numbers.
22188         (vsx_tsqrt<mode>2_fe): Likewise.
22190 2017-03-02  Uros Bizjak  <ubizjak@gmail.com>
22192         PR target/79514
22193         * config/i386/i386.md (*pushxf_rounded): New insn_and_split pattern.
22195 2017-03-02  Jakub Jelinek  <jakub@redhat.com>
22197         PR rtl-optimization/79780
22198         * cprop.c (one_cprop_pass): When second and further conditional trap
22199         in a single basic block is turned into an unconditional trap, turn it
22200         into a deleted note to avoid RTL verification failures.
22202 2017-03-02  Richard Biener  <rguenther@suse.de>
22204         * fold-const.c (const_binop): Use ulow () instead of elt (0).
22206 2017-03-02  Richard Biener  <rguenther@suse.de>
22208         PR tree-optimization/79345
22209         PR c++/42000
22210         * tree-ssa-alias.c (walk_aliased_vdefs_1): Take a limit
22211         param and abort the walk, returning -1 if it is hit.
22212         (walk_aliased_vdefs): Take a limit param and pass it on.
22213         * tree-ssa-alias.h (walk_aliased_vdefs): Add a limit param,
22214         defaulting to 0 and return a signed int.
22215         * tree-ssa-uninit.c (struct check_defs_data): New struct.
22216         (check_defs): New helper.
22217         (warn_uninitialized_vars): Use walk_aliased_vdefs to warn
22218         about uninitialized memory.
22219         * fixed-value.c (fixed_from_string): Use ulow/uhigh to avoid
22220         bogus uninitialized warning.
22221         (fixed_convert_from_real): Likewise.
22223 2017-03-02  Bin Cheng  <bin.cheng@arm.com>
22225         PR tree-optimization/66768
22226         * tree-ssa-loop-ivopts.c (find_interesting_uses_address): Skip addr
22227         iv_use if base object can't be determined.
22229 2017-03-02  Jakub Jelinek  <jakub@redhat.com>
22231         PR tree-optimization/79345
22232         * gensupport.h (struct pattern_stats): Add min_scratch_opno field.
22233         * gensupport.c (get_pattern_stats_1) <case MATCH_SCRATCH>: Update it.
22234         (get_pattern_stats): Initialize it.
22235         * genemit.c (gen_expand): Verify match_scratch numbers come after
22236         match_operand/match_dup numbers.
22237         * config/i386/i386.md (<s>mul<mode>3_highpart): Swap match_dup and
22238         match_scratch numbers.
22239         * config/i386/sse.md (avx2_gathersi<mode>, avx2_gatherdi<mode>):
22240         Likewise.
22241         * config/s390/s390.md (trunctdsd2): Likewise.
22243 2017-03-02  Richard Biener  <rguenther@suse.de>
22245         * wide-int.h (wide_int_storage::operator=): Implement in terms
22246         of wi::copy.
22248 2017-03-02  Richard Biener  <rguenther@suse.de>
22250         PR tree-optimization/79777
22251         * tree-ssa-pre.c (eliminate_insert): Give up if we simplify
22252         the to insert expression to sth existing.
22254 2017-03-01  Martin Sebor  <msebor@redhat.com>
22256         PR middle-end/79692
22257         * gimple-ssa-sprintf.c
22258         (directive::known_width_and_precision): New function.
22259         (format_integer): Use it.
22260         (get_mpfr_format_length): Consider the full range of precision
22261         when computing %g output with the # flag.  Set the likely byte
22262         count to 3 rather than 1 when precision is indeterminate.
22263         (format_floating): Correct the lower bound of precision.
22265 2017-03-01  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
22267         * doc/invoke.texi: Document default code model for 64-bit Linux.
22269 2017-03-01  Aaron Sawdey  <acsawdey@linux.vnet.ibm.com>
22271         PR target/79752
22272         * config/rs6000/rs6000.md (peephole2 for udiv/umod): Should emit
22273         udiv rather than div since input pattern is unsigned.
22275 2017-03-01  Uros Bizjak  <ubizjak@gmail.com>
22277         * config/i386/i386.c (print_reg): Warn for values of
22278         unsupported size in integer register.
22280 2017-03-01  Michael Meissner  <meissner@linux.vnet.ibm.com>
22282         PR target/79439
22283         * config/rs6000/predicates.md (current_file_function_operand): Do
22284         not allow self calls to be local if the function is replaceable.
22286 2017-03-01  Kelvin Nilsen  <kelvin@gcc.gnu.org>
22288         PR target/79395
22289         * config/rs6000/altivec.h (vec_ctz and others): Change the
22290         preprocessor macro that controls conditional compilation from
22291         _ARCH_PWR9 to __POWER9_VECTOR__.
22292         (vec_all_ne): Change parameterization of __altivec_scalar_pred
22293         macro expansion under preprocessor #ifdef __POWER9_VECTOR__
22294         control (instead of _ARCH_PWR9 control) so that template
22295         definition uses power9-specific function.
22296         (vec_any_eq): Likewise.
22297         (vec_all_ne): Change macro definition to use a power9-specific
22298         expansion under #ifdef __POWER9_VECTOR__ control (instead of
22299         _ARCH_PWR9 control).
22300         (vec_any_eq) Likewise.
22301         * config/rs6000/rs6000-builtin.def (CMPNEF): Remove BU_P9V_AV_2
22302         expansion for CMPNEF to remove support for xvcmpnesp instruction.
22303         (CMPNED): Remove BU_P9V_AV2 expansion for CMPNED to remove
22304         support for xvcmpnedp instruction.
22305         (VCMPNEB_P): Replace BU_P9V_AV_P macro expansion with BU_P9V_AV_2
22306         macro expansion so that Power9 implementation of vec_all_ne does
22307         not use the AltiVec predicate framework.
22308         (VCMPNEH_P): Likewise.
22309         (VCMPNEW_P): Likewise.
22310         (VCMPNED_P): Likewise.
22311         (VCMPNEFP_P): Likewise.
22312         (VCMPNEDP_P): Likewise.
22313         (VCMPAEB_P): Add BU_P9V_AV_2 macro expansion to change
22314         implementation of vec_any_eq to not use AltiVec predicate
22315         framework.
22316         (VCMPAEH_P): Likewise.
22317         (VCMPAEW_P): Likewise.
22318         (VCMPAED_P): Likewise.
22319         (VCMPAEFP_P): Likewise.
22320         (VCMPAEDP_P): Likewise.
22321         (VCMPNE_P): Replace BU_P9V_OVERLOAD_P macro expansion with
22322         BU_P9V_OVERLOAD_2 so that Power9 implementation of vec_all_ne does
22323         not use the AltiVec predicate framework.
22324         (VCMPAE_P): Add BU_P9V_OVERLOAD_2 macro to change implementation
22325         of vec_any_eq to not use AltiVec predicate framework.
22326         * config/rs6000/rs6000-c.c (rs6000_target_modify_macros): Add
22327         support for predefined __POWER9_VECTOR__ macro to indicate that
22328         Power9 instruction selection is enabled.
22329         (altivec_overloaded_builtins): Remove extraneous
22330         ALTIVEC_BUILTIN_VEC_CMPNE entry for overloaded
22331         function argument types RS6000_BTI_bool_V16QI and
22332         RS6000_BTI_bool_V16QI.  Remove erroneous ALTIVEC_BUILTIN_VEC_CMPNE
22333         entry for overloaded function argument types RS6000_BTI_bool_V4SI
22334         andRS6000_BTI_bool_V4SI, mapping to P9V_BUILTIN_CMPNEB.  Remove
22335         two entries mapping to P9V_BUITIN_CMPNED and one entry mapping to
22336         P9V_BUILTIN_CMPNEF to force use of instructions not specific to
22337         Power9 for implementations of vec_cmpne.  Change the signature for
22338         all definitions of the overloaded P9V_BUILTIN_VEC_CMPNE_P function
22339         (representing vec_all_ne) to remove the previously described first
22340         argument of type RS6000_BTI_INTSI, as this was an artifact of
22341         reliance on the AltiVec predicate framework, which is no longer
22342         used in the implementation of these functions.  Add
22343         P9V_BUILTIN_VEC_VCMPAE_P entries (representing the vec_anyeq
22344         function) to match all of the P9V_BUILTIN_VEC_VCMNE_P entries
22345         since, unlike the AltiVec predicate framework implementation, we
22346         do not share function descriptors between vec_alle and vec_anyeq.
22347         (altivec_resolve_overloaded_builtin): Add SFmode and DFmode to the
22348         set of modes that receive special treatment even when
22349         TARGET_P9_VECTOR is true.  The special treatment emits code that
22350         does not depend on Power9 instructions.
22351         * config/rs6000/vector.md (vector_ne_<mode>_p): Change this
22352         define_expand to not rely on AltiVec predicate framework.
22353         (vector_ae_<mode>p): New define_expand to represent vec_any_eq
22354         function.
22355         (vector_ne_v2di_p): Change this define_expand to not rely on
22356         AltiVec predicate framework.
22357         (vector_ae_v2di_p): New define_expand to represent vec_any_eq
22358         function.
22359         (vector_ne_<mode>_p): Change this define_expand to not rely on
22360         AltiVec predicate framework.
22361         (vector_ae_<mode>p): New define_expand to represent vec_any_eq
22362         function.
22363         * config/rs6000/vsx.md (*vsx_ne_<mode>_p): For modes VSX_EXTRACT_I
22364         (V16QI, V8HI, V4SI), correct a typo in the code emitted for this
22365         define_insn pattern.
22366         (*vsx_ne_<mode>_p): For modes VSX_F (V4SF and V2DF), remove this
22367         define_insn pattern because the xvcmpne<VSs>. instruction is not
22368         supported.
22369         (vcmpne<VSs>): Remove this define_insn because xvcmpne<VSs>
22370         instruction is not supported.
22372 2017-03-01  Jakub Jelinek  <jakub@redhat.com>
22374         * config/nvptx/nvptx.c: Include intl.h.
22376 2017-03-01  Martin Jambor  <mjambor@suse.cz>
22378         PR lto/78140
22379         * ipa-prop.h (ipa_bits): Removed field known.
22380         (ipa_jump_func): Removed field vr_known.  Changed fields bits and m_vr
22381         to pointers.  Adjusted their comments to warn about their sharing.
22382         (ipcp_transformation_summary): Change bits to a vector of pointers.
22383         (ipa_check_create_edge_args): Moved to ipa-prop.c, declare.
22384         (ipa_get_ipa_bits_for_value): Declare.
22385         * tree-vrp.h (value_range): Mark as GTY((for_user)).
22386         * ipa-prop.c (ipa_bit_ggc_hash_traits): New.
22387         (ipa_bits_hash_table): Likewise.
22388         (ipa_vr_ggc_hash_traits): Likewise.
22389         (ipa_vr_hash_table): Likewise.
22390         (ipa_print_node_jump_functions_for_edge): Adjust for bits and m_vr
22391         being pointers and vr_known being removed.
22392         (ipa_set_jf_unknown): Likewise.
22393         (ipa_get_ipa_bits_for_value): New function.
22394         (ipa_set_jfunc_bits): Likewise.
22395         (ipa_get_value_range): New overloaded functions.
22396         (ipa_set_jfunc_vr): Likewise.
22397         (ipa_compute_jump_functions_for_edge): Use the above functions to
22398         construct bits and vr parts of jump functions.
22399         (ipa_check_create_edge_args): Move here from ipa-prop.h, also allocate
22400         ipa_bits_hash_table and ipa_vr_hash_table if they do not already
22401         exist.
22402         (ipcp_grow_transformations_if_necessary): Also allocate
22403         ipa_bits_hash_table and ipa_vr_hash_table if they do not already
22404         exist.
22405         (ipa_node_params_t::duplicate): Do not copy bits, just pointers to
22406         them.  Fix too long lines.
22407         (ipa_write_jump_function): Adjust for bits and m_vr being pointers and
22408         vr_known being removed.
22409         (ipa_read_jump_function): Use new setter functions to construct bits
22410         and vr parts of jump functions or set them to NULL.
22411         (write_ipcp_transformation_info): Adjust for bits being pointers.
22412         (read_ipcp_transformation_info): Likewise.
22413         (ipcp_update_bits): Likewise.  Fix excessively long lines a trailing
22414         space.
22415         Include gt-ipa-prop.h.
22416         * ipa-cp.c (propagate_bits_across_jump_function): Adjust for bits
22417         being pointers.
22418         (ipcp_store_bits_results): Likewise.
22419         (propagate_vr_across_jump_function): Adjust for m_vr being a pointer.
22420         Do not write to existing jump functions but use a temporary instead.
22422 2017-03-01  Jakub Jelinek  <jakub@redhat.com>
22424         PR c++/79681
22425         * fold-const.c (make_bit_field_ref): If orig_inner is COMPONENT_REF,
22426         attempt to use its first operand as BIT_FIELD_REF base.
22428 2017-03-01  Richard Biener  <rguenther@suse.de>
22430         PR middle-end/79721
22431         * tree-chrec.c (chrec_evaluate): Perform computation of Newtons
22432         interpolating formula in wrapping arithmetic.
22433         (chrec_apply): Convert chrec_evaluate return value to wanted type.
22435 2017-03-01  Jakub Jelinek  <jakub@redhat.com>
22437         PR tree-optimization/79734
22438         * tree-vect-generic.c (expand_vector_condition): Optimize
22439         AVX512 vector boolean VEC_COND_EXPRs into bitwise operations.
22440         Handle VEC_COND_EXPR where comparison has different inner width from
22441         type's inner width.
22443 2017-02-28  Sandra Loosemore  <sandra@codesourcery.com>
22445         * doc/invoke.texi (ARC Options): Copy-edit to fix punctuation,
22446         markup, and similar issues.  Remove @opindex entries for things
22447         that aren't options.  Add missing -mmpy-option entries.
22449 2017-02-28  Jakub Jelinek  <jakub@redhat.com>
22451         PR tree-optimization/79737
22452         * gimple-ssa-store-merging.c (encode_tree_to_bitpos): If bitlen is
22453         a multiple of BITS_PER_UNIT and !BYTES_BIG_ENDIAN, clear
22454         tmpbuf[byte_size - 1].  Call natice_encode_expr with byte_size - 1
22455         instead of byte_size.  Formatting fix.
22456         (shift_bytes_in_array_right): Formatting fix.
22458 2017-02-28  Eric Botcazou  <ebotcazou@adacore.com>
22460         PR target/79749
22461         * config/sparc/sparc.c (sparc_frame_pointer_required): Add missing
22462         condition on optimize for the leaf function test.
22464 2017-02-28  Martin Liska  <mliska@suse.cz>
22466         PR lto/79625
22467         * read-rtl-function.c (function_reader::handle_unknown_directive):
22468         Bail out when one uses -flto.
22470 2017-02-28  Martin Liska  <mliska@suse.cz>
22472         * common.opt: Replace space with tabular for options of <number>
22473         type.
22474         * config/i386/i386.opt: Show <number> value for
22475         -mlarge-data-threshold.
22476         * opts.c (print_filtered_help): Do not display number in hexadecimal
22477         format.
22479 2017-02-28  Martin Liska  <mliska@suse.cz>
22481         * common.opt: Fix --help=option -Q for options which are of
22482         an enum type.
22484 2017-02-28  Uros Bizjak  <ubizjak@gmail.com>
22486         * config/i386/i386.c (print_reg): Error out for values
22487         of 8-bit size in invalid integer register.
22489 2017-02-28  Martin Sebor  <msebor@redhat.com>
22491         PR tree-optimization/79691
22492         * passes.def (pass_all_optimizations_g): Enable pass_sprintf_length.
22494 2017-02-28  Jakub Jelinek  <jakub@redhat.com>
22496         PR target/79729
22497         * config/i386/i386.c (ix86_print_operand) <case 'R'>: Replace
22498         gcc_unreachable with output_operand_lossage.
22500 2017-02-28  Richard Biener  <rguenther@suse.de>
22502         PR tree-optimization/79740
22503         * tree-ssa-sccvn.c (vn_nary_op_insert_into): Allow redundant
22504         inserts.
22505         (visit_nary_op): Insert the nary into the hashtable if we
22506         pattern-matched sth.
22507         * tree-ssa-pre.c (eliminate_insert): Robustify.
22509 2017-02-28  Richard Biener  <rguenther@suse.de>
22511         PR middle-end/79731
22512         * fold-const.c (decode_field_reference): Reject out-of-bound
22513         accesses.
22515 2017-02-28  Jakub Jelinek  <jakub@redhat.com>
22517         * config/i386/i386.c: Include intl.h.
22518         (ix86_option_override_internal): Use cond ? G_("...") : G_("...")
22519         instead of just cond ? "..." : "...".
22520         * config/nvptx/nvptx.c (nvptx_goacc_validate_dims): Likewise.
22521         * coverage.c (read_counts_file): Likewise.
22522         * omp-offload.c: Include intl.h.
22523         (oacc_loop_fixed_partitions): Use cond ? G_("...") : G_("...") instead
22524         of just cond ? "..." : "...".
22525         * gcov.c (read_count_file): Use cond ? N_("...") : N_("...") instead
22526         of just cond ? "..." : "...".
22528 2017-02-28  Richard Earnshaw  <rearnsha@arm.com>
22530         PR target/79742
22531         * config/arm/parsecpu.awk (gen_data): Set tuning target to 'tune for'
22532         entry, if present.
22533         * config/arm/arm-cpus.in (cortex-m0plus.small-multiply): Correct
22534         'tune for' CPU name.
22535         * config/arm/arm-cpu-data.h: Regenerated.
22537 2017-02-28  Richard Biener  <rguenther@suse.de>
22539         PR tree-optimization/79732
22540         * tree-inline.c (expand_call_inline): Do not shadow var.
22542 2017-02-28  Richard Biener  <rguenther@suse.de>
22544         PR tree-optimization/79723
22545         * tree-vect-stmts.c (get_vectype_for_scalar_type_and_size): Preserve
22546         address-space properly.
22548 2017-02-28  Thomas Schwinge  <thomas@codesourcery.com>
22550         * doc/optinfo.texi (Optimization groups): Fix option used for
22551         OPTGROUP_ALL.
22552         * doc/invoke.texi (-fopt-info): Document "omp".
22553         * dumpfile.h: Sort OPTGROUP_OMP before OPTGROUP_VEC.
22554         (OPTGROUP_ALL): Add OPTGROUP_OMP.
22555         * hsa-gen.c (pass_data_gen_hsail): Use OPTGROUP_OMP.
22556         * ipa-hsa.c (pass_data_ipa_hsa): Likewise.
22557         * omp-simd-clone.c (pass_data_omp_simd_clone): Likewise.
22559         * dumpfile.h (OPTGROUP_OPENMP): Rename to OPTGROUP_OMP.  Adjust
22560         all users.
22561         * dumpfile.c (optgroup_options): Instead of "openmp", associate
22562         OPTGROUP_OMP with "omp".
22564 2017-02-27  Pat Haugen  <pthaugen@us.ibm.com>
22566         PR target/79544
22567         * config/rs6000/rs6000-c.c (struct altivec_builtin_types): Use VSRAD
22568         for arithmetic shift of unsigned V2DI.
22570 2017-02-27  Claudiu Zissulescu  <claziss@synopsys.com>
22572         * config.gcc (arc*-): Clean up, use arc/big.h, arc/elf.h, and
22573         arc/linux.h headers.
22574         * config/arc/arc.h (TARGET_OS_CPP_BUILTINS): Remove.
22575         (LINK_SPEC): Likewise.
22576         (ARC_TLS_EXTRA_START_SPEC): Likewise.
22577         (EXTRA_SPECS): Likewise.
22578         (STARTFILE_SPEC): Likewise.
22579         (ENDFILE_SPEC): Likewise.
22580         (LIB_SPEC): Likewise.
22581         (TARGET_SDATA_DEFAULT): Likewise.
22582         (TARGET_MMEDIUM_CALLS_DEFAULT): Likewise.
22583         (MULTILIB_DEFAULTS): Likewise.
22584         (DWARF2_UNWIND_INFO): Likewise.
22585         * config/arc/big.h: New file.
22586         * config/arc/elf.h: Likewise.
22587         * config/arc/linux.h: Likewise.
22588         * config/arc/t-uClibc: Remove.
22590 2017-02-27  Bin Cheng  <bin.cheng@arm.com>
22592         PR tree-optimization/77536
22593         * tree-ssa-loop-manip.c (niter_for_unrolled_loop): New function.
22594         (tree_transform_and_unroll_loop): Use above function to compute the
22595         estimated niter of unrolled loop and use it when scaling profile.
22596         Also use count info rather than frequency if it's non-zero.
22597         * tree-ssa-loop-manip.h niter_for_unrolled_loop(): New declaration.
22598         * tree-vect-loop.c (scale_profile_for_vect_loop): New function.
22599         (vect_transform_loop): Call above function.
22601 2017-02-27  Richard Biener  <rguenther@suse.de>
22603         PR tree-optimization/45397
22604         * tree-ssa-pre.c (eliminate_insert): Handle BIT_AND_EXPR.
22605         * tree-ssa-sccvn.c (valueized_wider_op): New helper.
22606         (visit_nary_op): Add pattern matching for CSEing sign-changed
22607         or truncated operations with wider ones.
22609 2017-02-27  Richard Biener  <rguenther@suse.de>
22611         PR tree-optimization/79690
22612         * tree-vect-stmts.c (vectorizable_store): Use vector type
22613         built from the DR with address-space.
22615 2017-02-26  Gerald Pfeifer  <gerald@pfeifer.com>
22617         * doc/invoke.texi (Optimize Options): Refine the description
22618         of asan-use-after-return.
22620 2017-02-25  Alan Modra  <amodra@gmail.com>
22622         PR rtl-optimization/79584
22623         * lra-constraints.c (base_to_reg): Reload ad->base, the entire
22624         base, not ad->base_term, the reg within base.  Remove assertion
22625         that ad->base == ad->base_term.  Replace gen_int_mode using
22626         bogus mode with const0_rtx.
22628 2017-02-25  Jakub Jelinek  <jakub@redhat.com>
22630         PR middle-end/79396
22631         * tree-eh.c (operation_could_trap_p, stmt_could_throw_1_p): Handle
22632         FMA_EXPR like tcc_binary or tcc_unary.
22634         * tree-ssa-loop-niter.c (number_of_iterations_exit): Simplify warning.
22636         PR debug/77589
22637         * dwarf2out.c (struct dw_loc_list_struct): Add noted_variable_value
22638         bitfield.
22639         (size_of_loc_descr): Handle DW_OP_GNU_variable_value.
22640         (output_loc_operands): Handle DW_OP_call_ref and
22641         DW_OP_GNU_variable_value.
22642         (struct variable_value_struct): New type.
22643         (struct variable_value_hasher): Likewise.
22644         (variable_value_hash): New variable.
22645         (string_types): Remove.
22646         (copy_loc_descr): New function.
22647         (add_loc_descr_to_each): Clarify comment.  Use copy_loc_descr.
22648         (prepend_loc_descr_to_each): New function.
22649         (add_loc_list): Fix comment typo.  Use prepend_loc_descr_to_each
22650         instead of add_loc_descr_to_each if the first argument is single
22651         location list and the second has multiple.
22652         (resolve_args_picking_1): Handle DW_OP_GNU_variable_value.
22653         (loc_list_from_tree_1): For early_dwarf, emit DW_OP_GNU_variable_value
22654         when looking for variable value which doesn't have other location info.
22655         (loc_list_from_tree): Formatting fix.
22656         (gen_array_type_die): Simplify DW_AT_string_length handling.
22657         (adjust_string_types): Remove.
22658         (gen_subprogram_die): Don't call adjust_string_types nor test/set
22659         string_types.  Call resolve_variable_values.
22660         (prune_unused_types_walk_loc_descr): Handle DW_OP_GNU_variable_value.
22661         (resolve_addr_in_expr): Likewise.  Add A argument.
22662         (copy_deref_exprloc): Remove deref argument.  Adjust for the
22663         original expression being DW_OP_GNU_variable_value with optionally
22664         DW_OP_stack_value after it instead of DW_OP_call4 with DW_OP_deref
22665         optionally after it.
22666         (optimize_string_length): Rework for DW_OP_GNU_variable_value.
22667         (resolve_addr): Adjust optimize_string_length and resolve_addr_in_expr
22668         callers.  Set remove_AT_byte_size if removing DW_AT_string_length.
22669         (variable_value_hasher::hash, variable_value_hasher::equal): New
22670         methods.
22671         (resolve_variable_value_in_expr, resolve_variable_value,
22672         resolve_variable_values, note_variable_value_in_expr,
22673         note_variable_value): New functions.
22674         (dwarf2out_early_finish): Call note_variable_value on all toplevel
22675         DIEs.
22677 2017-02-24  Jakub Jelinek  <jakub@redhat.com>
22679         PR c/79677
22680         * opts.h (handle_generated_option): Add GENERATED_P argument.
22681         * opts-common.c (handle_option): Adjust function comment.
22682         (handle_generated_option): Add GENERATED_P argument, pass it to
22683         handle_option.
22684         (control_warning_option): Pass false to handle_generated_option
22685         GENERATED_P.
22686         * opts.c (maybe_default_option): Pass true to handle_generated_option
22687         GENERATED_P.
22688         * optc-gen.awk: Likewise.
22690 2017-02-24  Segher Boessenkool  <segher@kernel.crashing.org>
22692         * config/sh/sh.md (tstsi_t): If operands[0] is a SUBREG instead of
22693         a REG, look at the REG it is a SUBREG of.
22694         (splitter for cmpeqsi_t): Ditto.
22696 2017-02-24  Segher Boessenkool  <segher@kernel.crashing.org>
22698         * config/pa/pa.c (pa_combine_instructions): Do not share RTL.  Make
22699         the special USEs with the pattern of the insn, not the insn itself.
22701 2017-02-24  Matthew Fortune  <matthew.fortune@imgtec.com>
22703         PR target/79473
22704         * doc/invoke.texi: Document -mload-store-pairs.
22706 2017-02-24  Segher Boessenkool  <segher@kernel.crashing.org>
22707             Sandra Loosemore  <sandra@codesourcery.com>
22709         * config/nios2/nios2.c (nios2_simple_const_p): Returns false if the
22710         argument isn't a CONST_INT.
22711         (nios2_alternate_compare_const): Assert op is a CONST_INT.
22712         (nios2_valid_compare_const_p): Assert op is a CONST_INT.
22713         (nios2_validate_compare): Bypass alternate compare logic if *op2
22714         is not a CONST_INT.
22715         (ldstwm_operation_p): Return false if first_base is not a REG or
22716         if first_offset is not a CONST_INT.
22718 2017-02-24  Segher Boessenkool  <segher@kernel.crashing.org>
22720         * config/cris/cris.md: Use correct operand in a define_peephole2.
22722 2017-02-24  Segher Boessenkool  <segher@kernel.crashing.org>
22724         * config/c6x/c6x.c (predicate_insn): Do not incorrectly share RTL.
22726 2017-02-24  Segher Boessenkool  <segher@kernel.crashing.org>
22728         * config/arc/arc.c (arc_ccfsm_advance): Only take the PATTERN of
22729         this_insn if it is an INSN or JUMP_INSN.
22730         (force_offsettable): Look at base, not at addr.
22731         * config/arc/predicates.md (brcc_nolimm_operator): Don't call INTVAL
22732         on things that aren't necessarily CONST_INTs.
22734 2017-02-24  Uros Bizjak  <ubizjak@gmail.com>
22736         * doc/invoke.texi (x86 Options, -mfpmath=sse): Mention that
22737         -mfpmath=sse is the default also for x86-32 targets with SSE2
22738         instruction set when @option{-ffast-math} is enabled
22740 2017-02-24  Jeff Law  <law@redhat.com>
22742         PR rtl-optimizatoin/79286
22743         * ira.c (update_equiv_regs): Drop may_trap_p exception to
22744         dominance test.
22746 2017-02-24  Richard Biener  <rguenther@suse.de>
22748         PR tree-optimization/79389
22749         * gimple-ssa-split-paths.c (is_feasible_trace): Properly skip
22750         debug insns.
22752 2017-02-24  Aldy Hernandez  <aldyh@redhat.com>
22754         * tree-ssa-loop-niter.c (number_of_iterations_exit): Update
22755         function comment to reflect reality.
22756         (loop_exits_before_overflow): Fix typo in function description.
22758 2017-02-24  Richard Biener  <rguenther@suse.de>
22760         PR tree-optimization/79389
22761         * gimple-ssa-split-paths.c (is_feasible_trace): Verify more
22762         properly that a threading opportunity exists.  Detect conditional
22763         copy/constant propagation opportunities.
22765 2017-02-23  Eric Botcazou  <ebotcazou@adacore.com>
22767         * config/visium/visium.md (type): Add trap.
22768         (b): New mode attribute.
22769         (*btst): Rename into...
22770         (*btst<mode>): ...this and adjust.
22771         (*cbranchsi4_btst_insn): Rename into...
22772         (*cbranch<mode>4_btst_insn): ...this and adjust.
22773         (trap): New define_insn.
22775 2017-02-23  Jakub Jelinek  <jakub@redhat.com>
22777         PR tree-optimization/79389
22778         * ifcvt.c (struct noce_if_info): Add rev_cond field.
22779         (noce_reversed_cond_code): New function.
22780         (noce_emit_store_flag): Use rev_cond if non-NULL instead of
22781         reversed_comparison_code.  Formatting fix.
22782         (noce_try_store_flag): Test rev_cond != NULL in addition to
22783         reversed_comparison_code.
22784         (noce_try_store_flag_constants): Likewise.
22785         (noce_try_store_flag_mask): Likewise.
22786         (noce_try_addcc): Use rev_cond if non-NULL instead of
22787         reversed_comparison_code.
22788         (noce_try_cmove_arith): Likewise.  Formatting fixes.
22789         (noce_try_minmax, noce_try_abs): Clear rev_cond.
22790         (noce_find_if_block): Initialize rev_cond.
22791         (find_cond_trap): Call noce_get_condition with then_bb == trap_bb
22792         instead of false as last argument never attempt to reverse it
22793         afterwards.
22795 2017-02-23  Bin Cheng  <bin.cheng@arm.com>
22797         PR tree-optimization/79663
22798         * tree-predcom.c (combine_chains): Process refs in reverse order
22799         only for ZERO length chains, and add explaining comment.
22801 2017-02-23  Jeff Law  <law@redhat.com>
22803         PR tree-optimization/79578
22804         * tree-ssa-dse.c (clear_bytes_written_by): Use OEP_ADDRESS_OF
22805         in call to operand_equal_p.
22807 2017-01-23  Dominique d'Humieres  <dominiq@lps.ens.fr>
22809         PR target/71017
22810         * config/i386/cpuid.h: Fix another undefined behavior.
22812 2017-02-23  Richard Biener  <rguenther@suse.de>
22814         PR tree-optimization/79683
22815         * tree-vect-stmts.c (vect_analyze_stmt): Do not overwrite
22816         vector types for data-refs.
22818 2017-02-23  Martin Liska  <mliska@suse.cz>
22820         * params.def (PARAM_MIN_NONDEBUG_INSN_UID): Change default to 0.
22822 2017-02-23  Jakub Jelinek  <jakub@redhat.com>
22824         PR middle-end/79665
22825         * internal-fn.c (get_range_pos_neg): Moved to ...
22826         * tree.c (get_range_pos_neg): ... here.  No longer static.
22827         * tree.h (get_range_pos_neg): New prototype.
22828         * expr.c (expand_expr_real_2) <case TRUNC_DIV_EXPR>: If both arguments
22829         are known to be in between 0 and signed maximum inclusive, try to
22830         expand both unsigned and signed divmod and use the cheaper one from
22831         those.
22833 2017-02-22  Jeff Law  <law@redhat.com>
22835         PR tree-optimization/79578
22836         * tree-ssa-dse.c (clear_bytes_written_by): Use operand_equal_p
22837         to compare base operands.
22839 2017-02-22  Segher Boessenkool  <segher@kernel.crashing.org>
22841         PR target/79211
22842         * config/rs6000/rs6000.md (*fsel<SFDF:mode><SFDF2:mode>4): Use
22843         gpc_reg_operand instead of fpr_reg_operand.
22845 2017-02-22  Sameera Deshpande  <sameera.deshpande@imgtec.com>
22847         * config/mips/mips.c (mips_return_in_memory): Force FP
22848         vector types to be returned in memory for o32 ABI.
22850 2017-02-22  Jakub Jelinek  <jakub@redhat.com>
22852         * dwarf2out.c (gen_variable_die): For -gdwarf-5, use DW_TAG_variable
22853         instead of DW_TAG_member for static data member declarations and don't
22854         set no_linkage_name for static inline data members.
22855         (gen_member_die): For -gdwarf-5 don't change DW_TAG_variable
22856         to DW_TAG_member.
22858 2017-02-22  Martin Liska  <mliska@suse.cz>
22860         * doc/invoke.texi: Replace inequality signs with square brackets
22861         for -Wnormalized.
22863 2017-02-22  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
22865         PR tree-optimization/68644
22866         * gcc.dg/tree-ssa/ivopts-lt-2.c: Skip for powerpc*-*-*.
22868 2017-02-22  Matthew Fortune  <matthew.fortune@imgtec.com>
22870         PR target/78660
22871         * lra-constraints.c (simplify_operand_subreg): Handle
22872         WORD_REGISTER_OPERATIONS targets.
22874 2017-02-22  Jakub Jelinek  <jakub@redhat.com>
22876         PR target/70465
22877         * reg-stack.c (emit_swap_insn): Treat (float_extend:?F (mem:?F))
22878         and (const_double:?F) like (mem:?F) for the purpose of fxch %st(1)
22879         elimination by swapping fld*.
22881 2017-02-22  Richard Biener  <rguenther@suse.de>
22883         PR tree-optimization/79673
22884         * tree-ssa-pre.c (compute_avail): Use wide_int_to_tree to
22885         convert the [TARGET_]MEM_REF offset INTEGER_CST, scrapping off
22886         irrelevant address-space qualifiers and avoiding a
22887         ADDR_SPACE_CONVERT_EXPR from fold_convert.
22889 2017-02-22  Richard Biener  <rguenther@suse.de>
22891         PR tree-optimization/79666
22892         * tree-vrp.c (extract_range_from_binary_expr_1): Make sure
22893         to not symbolically negate if that may introduce undefined
22894         overflow.
22896 2017-02-22  Martin Liska  <mliska@suse.cz>
22898         PR lto/79587
22899         * data-streamer-in.c (streamer_read_gcov_count): Remove assert.
22900         * data-streamer-out.c (streamer_write_gcov_count_stream):
22901         Likewise.
22902         * value-prof.c (stream_out_histogram_value): Make assert more
22903         precise based on type of counter.
22905 2017-02-21  Uros Bizjak  <ubizjak@gmail.com>
22907         PR target/79593
22908         * config/i386/i386.md (standard_x87sse_constant_load splitter):
22909         Use nonimmediate_operand instead of memory_operand for operand 1.
22910         (float-extend standard_x87sse_constant_load splitter): Ditto.
22912 2017-02-21  Jeff Law  <law@redhat.com>
22914         PR tree-optimization/79621
22915         * gimple-ssa-isolate-paths.c (find_implicit_erroneous_behavior): Ignore
22916         blocks with edges to themselves.
22918 2017-02-21  Jakub Jelinek  <jakub@redhat.com>
22920         PR target/79633
22921         * tree-chkp-opt.c (chkp_optimize_string_function_calls): Use
22922         is_gimple_call instead of comparing gimple_code with GIMPLE_CALL.
22923         Use gimple_call_builtin_p.
22925         PR target/79570
22926         * sel-sched.c (moveup_expr_cached): Don't call sel_bb_head
22927         on temporarily removed DEBUG_INSNs.
22929         PR tree-optimization/79649
22930         * tree-loop-distribution.c (classify_partition): Give up on
22931         non-generic address space loads/stores.
22933 2017-02-21  Aldy Hernandez  <aldyh@redhat.com>
22935         * doc/loop.texi (Loop manipulation): Remove nonexistent
22936         tree_ssa_loop_version from the documentation.
22937         * cfgloopmanip.c (loop_version): Document CONDITION_BB argument.
22939 2017-02-21  Jakub Jelinek  <jakub@redhat.com>
22941         PR target/79494
22942         * config/i386/i386.c (ix86_expand_split_stack_prologue): Call
22943         make_reg_eh_region_note_nothrow_nononlocal on call_insn.
22944         * config/rs6000/rs6000.c: Include except.h.
22945         (rs6000_expand_split_stack_prologue): Call
22946         make_reg_eh_region_note_nothrow_nononlocal on the call insn.
22948 2017-02-21  Martin Jambor  <mjambor@suse.cz>
22950         PR lto/79579
22951         * ipa-prop.c (ipa_prop_write_jump_functions): Bail out if no edges
22952         have been analyzed.
22954 2017-02-21  Martin Jambor  <mjambor@suse.cz>
22956         * common.opt (-fipa-cp-alignment): Mark as ignored and preserved
22957         for backward compatibility only.
22958         * doc/invoke.texi (Option Summary): Remove all references to
22959         -fipa-cp-alignment.
22961 2017-02-21  Matthew Fortune  <matthew.fortune@imgtec.com>
22963         PR target/78660
22964         Revert:
22965         2017-02-20  Matthew Fortune  <matthew.fortune@imgtec.com>
22967         * lra-constraints.c (curr_insn_transform): Handle
22968         WORD_REGISTER_OPERATIONS requirements when reloading SUBREGs.
22970 2017-02-21  Martin Liska  <mliska@suse.cz>
22972         * config/i386/i386.opt: Replace -masm-dialect with -masm.
22974 2017-02-21  Thomas Schwinge  <thomas@codesourcery.com>
22976         PR translation/79638
22977         * config/nvptx/nvptx.c (ENTRY_TEMPLATE): Single out "%ntid.y".
22979 2017-02-21  Eric Botcazou  <ebotcazou@adacore.com>
22981         PR ada/67205
22982         * config/arm/arm.c (TARGET_CUSTOM_FUNCTION_DESCRIPTORS): Define.
22983         (arm_function_ok_for_sibcall): Return false for an indirect call by
22984         descriptor if all the argument registers are used.
22985         (arm_relayout_function): Use FUNCTION_ALIGNMENT macro to adjust the
22986         alignment of the function.
22988 2017-02-21  Jakub Jelinek  <jakub@redhat.com>
22990         PR tree-optimization/61441
22991         * simplify-rtx.c (simplify_const_unary_operation): For
22992         -fsignaling-nans and sNaN operand, return NULL_RTX rather than
22993         the sNaN unmodified.
22995 2017-02-20  Bernd Edlinger  <bernd.edlinger@hotmail.de>
22997         * Makefile.in (BUILD_SYSTEM_HEADER_DIR): New make variabe.
22998         (LIMITS_H_TEST, if_multiarch, stmp-fixinc): Use BUILD_SYSTEM_HEADER_DIR
22999         instead of SYSTEM_HEADER_DIR.
23001 2017-02-20  Gerald Pfeifer  <gerald@pfeifer.com>
23002             Martin LiÅ¡ka  <mliska@suse.cz>
23004         * doc/invoke.texi (use-after-scope-direct-emission-threshold):
23005         Fix typos and grammar, use active voice, and clarify.
23007 2017-02-20  Marek Polacek  <polacek@redhat.com>
23009         PR middle-end/79537
23010         * gimplify.c (gimplify_expr): Handle unused *&&L;.
23012         PR sanitizer/79558
23013         * ubsan.c (ubsan_type_descriptor): Check if TYPE_MAX_VALUE is null.
23015 2017-02-20  Jakub Jelinek  <jakub@redhat.com>
23017         PR target/79568
23018         * config/i386/i386.c (ix86_expand_builtin): Handle
23019         OPTION_MASK_ISA_AVX512VL and OPTION_MASK_ISA_64BIT in
23020         ix86_builtins_isa[fcode].isa as a requirement of those
23021         flags and any other flag in the bitmask.
23022         (ix86_init_mmx_sse_builtins): Use 0 instead of
23023         ~OPTION_MASK_ISA_64BIT as mask.
23024         * config/i386/i386-builtin.def (__builtin_ia32_rdtsc,
23025         __builtin_ia32_rdtscp, __builtin_ia32_pause, __builtin_ia32_bsrsi,
23026         __builtin_ia32_rdpmc, __builtin_ia32_rolqi, __builtin_ia32_rolhi,
23027         __builtin_ia32_rorqi, __builtin_ia32_rorhi): Likewise.
23029 2017-02-20  Matthew Fortune  <matthew.fortune@imgtec.com>
23031         PR target/78012
23032         * lra-constraints.c (split_reg): Check requested split mode
23033         is supported by the register.
23035 2017-02-20  Matthew Fortune  <matthew.fortune@imgtec.com>
23037         * lra-constraints.c (simplify_operand_subreg): Remove early
23038         return false.
23040 2017-02-20  Matthew Fortune  <matthew.fortune@imgtec.com>
23042         PR target/78660
23043         * lra-constraints.c (curr_insn_transform): Tighten condition
23044         for converting SUBREG reloads from OP_OUT to OP_INOUT.
23046 2017-02-20  Matthew Fortune  <matthew.fortune@imgtec.com>
23048         PR target/78660
23049         * lra-constraints.c (curr_insn_transform): Handle
23050         WORD_REGISTER_OPERATIONS requirements when reloading SUBREGs.
23052 2017-02-19  Uros Bizjak  <ubizjak@gmail.com>
23054         Revert:
23055         2016-05-30  Uros Bizjak  <ubizjak@gmail.com>
23057         * config/i386/sync.md (mfence_nosse): Use "lock orl $0, -4(%esp)".
23059 2017-02-19  Jonathan Wakely  <jwakely@redhat.com>
23061         PR c++/69523
23062         * doc/invoke.texi (C++ Dialect Options) [-Wliteral-suffix]: Update
23063         description.
23065 2017-02-19  Prathamesh Kulkarni  <prathamesh.kulkarni@linaro.org>
23067         * gimple-pretty-print.c (dump_ternary_rhs): Adjust gimple dump format
23068         for FMA_EXPR.
23070 2017-02-18  Jakub Jelinek  <jakub@redhat.com>
23072         * final.c (last_columnnum, override_columnnum): New variables.
23073         (final_start_function): Set last_columnnum, pass it to begin_prologue
23074         hook and pass 0 to dwarf2out_begin_prologue.
23075         (final_scan_insn): Update override_columnnum.  Pass last_columnnum
23076         to source_line debug hook.
23077         (notice_source_line): Compute last_columnnum and for debug_column_info
23078         return true on column changes.
23079         * debug.h (struct gcc_debug_hooks): Add column argument to
23080         source_line and begin_prologue hooks.
23081         (debug_nothing_int_charstar_int_bool): Remove prototype.
23082         (debug_nothing_int_int_charstar,
23083         debug_nothing_int_int_charstar_int_bool): New prototypes.
23084         (dwarf2out_begin_prologue): Add column argument.
23085         * debug.c (do_nothing_debug_hooks): Adjust source_line and
23086         begin_prologue hooks.
23087         (debug_nothing_int_charstar_int_bool): Remove.
23088         (debug_nothing_int_int_charstar,
23089         debug_nothing_int_int_charstar_int_bool): New functions.
23090         * dwarf2out.c (dwarf2out_begin_prologue): Add column argument, pass it
23091         through to dwarf2out_source_line.
23092         (dwarf2_lineno_debug_hooks): Adjust begin_prologue hook.
23093         (dwarf2out_source_line): Add column argument, emit it if requested.
23094         * sdbout.c (sdbout_source_line, sdbout_begin_prologue): Add column
23095         arguments.
23096         * xcoffout.h (xcoffout_begin_prologue, xcoffout_source_line): Likewise.
23097         * xcoffout.c (xcoffout_begin_prologue, xcoffout_source_line): Likewise.
23098         * vmsdbgout.c (vmsdbgout_begin_prologue): Add column argument, pass it
23099         through to dwarf2out_begin_prologue.
23100         (vmsdbgout_source_line): Add column argument, pass it through to
23101         dwarf2out_source_line.
23102         * dbxout.c (dbxout_begin_prologue): Add column argument, adjust
23103         dbxout_source_line caller.
23104         (dbxout_source_line): Add column argument.
23106         * common.opt (gno-column-info, gcolumn-info): New options.
23107         * dwarf2out.c (dwarf2_lineno_debug_hooks): Formatting fix.
23108         (check_die): Also test for multiple DW_AT_decl_column attributes.
23109         (add_src_coords_attributes, dwarf2out_imported_module_or_decl_1): Add
23110         DW_AT_decl_column if requested.
23111         (gen_subprogram_die): Compare and/or add also DW_AT_decl_column
23112         if requested.
23113         (gen_variable_die): Likewise.
23114         (add_call_src_coords_attributes): Add DW_AT_call_column if requested.
23115         * doc/invoke.texi (-gcolumn-info, -gno-column-info): Document.
23117         PR target/79569
23118         * config/i386/i386.opt (m3dnowa): Replace Undocumented with Report.
23119         * common/config/i386/i386-common.c (OPTION_MASK_ISA_3DNOW_A_SET): Define.
23120         (ix86_handle_option): Handle OPT_m3dnowa.
23121         * doc/invoke.texi (-m3dnowa): Document.
23122         * doc/extend.texi (__builtin_ia32_pmulhuw, __builtin_ia32_pf2iw): Use
23123         -m3dnowa instead of -m3dnow -march=athlon.
23125         PR target/79559
23126         * config/i386/i386.c (ix86_print_operand): Use output_operand_lossage
23127         instead of gcc_assert for K, r and R code checks.  Formatting fixes.
23129 2017-02-17  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
23131         PR target/79261
23132         * config/rs6000/rs6000.c (rs6000_expand_ternop_builtin): Add
23133         support for CODE_FOR_vsx_xxpermdi_v2d[fi]_be.
23134         * config/rs6000/rs6000.md (reload_gpr_from_vsx<mode>): Call
23135         generator for vsx_xxpermdi_<mode>_be.
23136         * config/rs6000/vsx.md (vsx_xxpermdi_<mode>): Remove logic to
23137         force big-endian semantics.
23138         (vsx_xxpermdi_<mode>_be): New define_expand with same
23139         implementation as previous version of vsx_xxpermdi_<mode>.
23141 2017-02-17  Jakub Jelinek  <jakub@redhat.com>
23143         PR tree-optimization/79327
23144         * gimple-ssa-sprintf.c (format_integer): Remove likely_adjust
23145         variable, its initialization and use.
23147 2017-02-17  Julia Koval  <julia.koval@intel.com>
23149         * common/config/i386/i386-common.c (OPTION_MASK_ISA_RDPID_SET): New.
23150         (OPTION_MASK_ISA_PKU_UNSET): New.
23151         (ix86_handle_option): Handle -mrdpid.
23152         * config/i386/cpuid.h (bit_RDPID): New.
23153         * config/i386/driver-i386.c (host_detect_local_cpu):
23154         Detect RDPID feature.
23155         * config/i386/i386-builtin.def (__builtin_ia32_rdpid): New.
23156         * config/i386/i386-c.c (ix86_target_macros_internal):
23157         Handle RDPID flag.
23158         * config/i386/i386.c (ix86_target_string): Add -mrdpid to isa2_opts.
23159         (ix86_valid_target_attribute_inner_p): Add "rdpid".
23160         (ix86_expand_builtin): Handle IX86_BUILTIN_RDPID.
23161         * config/i386/i386.h (TARGET_RDPID, TARGET_RDPID_P): New.
23162         * config/i386/i386.md (define_insn "rdpid"): New.
23163         * config/i386/i386.opt Add -mrdpid.
23164         * config/i386/immintrin.h (_rdpid_u32): New.
23166 2017-02-17  Vladimir Makarov  <vmakarov@redhat.com>
23168         PR rtl-optimization/79541
23169         * lra-constraints.c (curr_insn_transform): Remove wrong asm insn
23170         instead of transforming it into USE.
23172 2017-02-17  Segher Boessenkool  <segher@kernel.crashing.org>
23174         * config/rs6000/rs6000.md (extendsfdf2): Remove default arguments.
23175         If HONOR_SNANS (SFmode) force the input to a register.
23176         (*extendsfdf2_fpr): Add !HONOR_SNANS (SFmode) condition.
23177         (*extendsfdf2_snan): New pattern, used when using SNaNs; it generates
23178         an frsp or similar insn.
23180 2017-02-17  Martin Liska  <mliska@suse.cz>
23182         PR rtl-optimization/79577
23183         * params.def (selsched-max-sched-times): Increase minimum to 1.
23185 2017-02-17  Martin Liska  <mliska@suse.cz>
23187         PR rtl-optimization/79574
23188         * gcse.c (want_to_gcse_p): Prevent integer overflow.
23190 2017-02-17  Martin Liska  <mliska@suse.cz>
23192         PR tree-optimization/79529
23193         * tree-ssa-loop-unswitch.c (is_maybe_undefined): Use
23194         ssa_defined_default_def_p to handle cases which are implicitly
23195         defined.
23196         * tree-ssa.c (ssa_defined_default_def_p): New function.
23197         (ssa_undefined_value_p): Use ssa_defined_default_def_p to handle cases
23198         which are implicitly defined.
23199         * tree-ssa.h (ssa_defined_default_def_p): Declare.
23201 2017-02-17  Richard Biener  <rguenther@suse.de>
23203         PR middle-end/79576
23204         * params.def (max-ssa-name-query-depth): Limit to 10.
23206 2017-02-17  Richard Biener  <rguenther@suse.de>
23208         PR tree-optimization/79552
23209         * tree-ssa-structalias.c (visit_loadstore): Properly verify
23210         default defs.
23212 2017-02-17  Richard Biener  <rguenther@suse.de>
23214         PR bootstrap/79567
23215         * genmatch.c (output_line_directive): Handle DIR_SEPARATOR_2.
23217 2017-02-17  Marek Polacek  <polacek@redhat.com>
23219         PR middle-end/79536
23220         * fold-const.c (fold_negate_expr_1): Renamed from fold_negate_expr.
23221         (fold_negate_expr): New wrapper.
23223 2017-02-16  Sandra Loosemore  <sandra@codesourcery.com>
23225         * doc/invoke.texi (C++ Dialect Options) [-Wno-non-template-friend]: 
23226         Correct terminology and de-emphasize pre-standard behavior.
23228 2017-02-16  Alan Modra  <amodra@gmail.com>
23230         PR rtl-optimization/79286
23231         * ira.c (def_dominates_uses): New function.
23232         (update_equiv_regs): Don't create an equivalence for insns that
23233         may trap where the register def does not dominate the use.
23235 2017-02-16  Vladimir Makarov  <vmakarov@redhat.com>
23237         PR rtl-optimization/78127
23238         * lra.c (lra): Call lra_eliminate before finish the loop after
23239         lra_constraint.
23241 2017-02-16  Richard Biener  <rguenther@suse.de>
23243         * graphite.h: Do not include isl/isl_val_gmp.h, instead include
23244         isl/isl_val.h.
23245         * graphite-isl-ast-to-gimple.c (gmp_cst_to_tree): Remove.
23246         (gcc_expression_from_isl_expr_int): Use generic isl_val interface.
23247         * graphite-sese-to-poly.c: Do not include isl/isl_val_gmp.h.
23248         (isl_val_int_from_wi): New function.
23249         (extract_affine_gmp): Rename to ...
23250         (extract_affine_wi): ... this, take a widest_int.
23251         (extract_affine_int): Just wrap extract_affine_wi.
23252         (add_param_constraints): Use isl_val_int_from_wi.
23253         (add_loop_constraints): Likewise, and extract_affine_wi.
23255 2017-02-15  Jeff Law  <law@redhat.com>
23257         PR middle-end/79521
23258         * ira-costs.c (scan_one_insn): Check have_regs_of_mode before calling
23259         ira_init_register_move_cost_if_necessary.
23261 2017-02-15  Martin Sebor  <msebor@redhat.com>
23263         PR middle-end/32003
23264         * doc/invoke.texi (-fdump-final-insns): Replace option accidentally
23265         removed in a prior commit.
23267 2017-02-15  Bin Cheng  <bin.cheng@arm.com>
23269         PR tree-optimization/79347
23270         * tree-vect-loop-manip.c (vect_do_peeling): Maintain profile
23271         counters during peeling.
23273 2017-02-15  Thomas Schwinge  <thomas@codesourcery.com>
23275         * Makefile.in (site.exp): Remove "set ISLVER".
23277 2017-02-15  Jakub Jelinek  <jakub@redhat.com>
23279         PR target/79487
23280         * real.c (real_from_integer): Call real_convert even for decimal.
23282 2017-02-15  Dominik Vogt  <vogt@linux.vnet.ibm.com>
23284         PR target/79421
23285         * config/s390/s390.c: define TARGET_CUSTOM_FUNCTION_DESCRIPTORS.
23287 2017-02-14  Andrew Pinski  <apinski@cavium.com>
23289         * config/aarch64/aarch64-cores.def (thunderx2t99): Move to under 'C"
23290         cores and change the partno/implementer to be correct.
23291         (thunderx2t99p1): New core which replaces thunderx2t99 and still has
23292         the 'B" as the implementer.
23293         * config/aarch64/aarch64-tune.md: Regenerate.
23295 2017-02-14  Carl Love  <cel@us.ibm.com>
23297         * config/rs6000/rs6000.c: Add case statement entry to make the
23298         xvcvuxdsp built-in argument unsigned.
23299         * config/rs6000/vsx.md: Fix the source and return operand types so they
23300         match the instruction definitions from the ISA document.  Fix typo
23301         in the instruction generation for the (define_insn "vsx_xvcvuxdsp"
23302         statement.
23304 2017-02-14  Vladimir Makarov  <vmakarov@redhat.com>
23306         PR target/79282
23307         * lra-int.h (struct lra_operand_data, struct lra_insn_reg): Add
23308         member early_clobber_alts.
23309         * lra-lives.c (reg_early_clobber_p): New.
23310         (process_bb_lives): Use it.
23311         * lra.c (new_insn_reg): New arg early_clobber_alts.  Use it.
23312         (debug_operand_data): Initialize early_clobber_alts.
23313         (setup_operand_alternative): Set up early_clobber_alts.
23314         (collect_non_operand_hard_regs): Ditto.  Pass early clobber
23315         alternatives to new_insn_reg.
23316         (add_regs_to_insn_regno_info): Add arg early_clobber_alts.  Use
23317         it.
23318         (lra_update_insn_regno_info): Pass the new arg.
23320 2017-02-14  Jakub Jelinek  <jakub@redhat.com>
23322         PR middle-end/79505
23323         * omp-offload.c (free_oacc_loop): Release loop->ifns vector.
23324         (new_oacc_loop_raw): Don't clear already cleared fields.
23326         PR target/79481
23327         * config/i386/avx512pfintrin.h (_mm512_prefetch_i32gather_pd,
23328         _mm512_prefetch_i32gather_ps, _mm512_prefetch_i64gather_pd,
23329         _mm512_prefetch_i64gather_ps): New inline functions and macros.
23331 2017-02-14  Uros Bizjak  <ubizjak@gmail.com>
23333         PR target/79495
23334         * config/i386/i386.md (*movxf_internal): Add (o,rC) alternative.
23336 2017-02-14  H.J. Lu  <hongjiu.lu@intel.com>
23338         PR target/79498
23339         * config/i386/i386.c (timode_scalar_chain::convert_insn): Insert
23340         the extra instruction to the right place to store 128-bit constant
23341         when needed.
23343 2017-02-14  Martin Sebor  <msebor@redhat.com>
23345         PR middle-end/79448
23346         * gimple-ssa-sprintf.c (format_directive): Avoid issuing INT_MAX
23347           warning for strings of unknown length.
23349 2017-02-13  Segher Boessenkool  <segher@kernel.crashing.org>
23351         * config.gcc (supported_defaults) [powerpc*-*-*]: Update.
23353 2017-02-14  Jeff Law  <law@redhat.com>
23355         PR target/79404
23356         * ira-costs.c (scan_one_insn): Initialize register move costs
23357         for pseudos seen in USE/CLOBBER insns.
23359         PR tree-optimization/79095
23360         * tree-vrp.c (extract_range_from_binary_expr_1): For EXACT_DIV_EXPR,
23361         if the numerator has the range ~[0,0] make the resultant range ~[0,0].
23362         (extract_range_from_binary_expr): For MINUS_EXPR with no derived range,
23363         if the operands are known to be not equal, then the resulting range
23364         is ~[0,0].
23365         (intersect_ranges): If the new range is ~[0,0] and the old range is
23366         wide, then prefer ~[0,0].
23367         * tree-vrp.c (overflow_comparison_p_1): New function.
23368         (overflow_comparison_p): New function.
23369         * tree-vrp.c (register_edge_assert_for_2): Register additional asserts
23370         if NAME is used in an overflow test.
23371         (vrp_evaluate_conditional_warnv_with_ops): If the ops represent an
23372         overflow check that can be expressed as an equality test, then adjust
23373         ops to be that equality test.
23375 2017-02-14  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
23377         * config/s390/s390-builtin-types.def: Remove flags argument.
23378         * config/s390/s390.c (s390_init_builtins): Likewise.
23380 2017-02-14  Martin Liska  <mliska@suse.cz>
23382         * tree-ssa-loop-unswitch.c (hoist_guard): Release get_loop_body
23383         vector.  Fix trailing white spaces.
23385 2017-02-14  James Greenhalgh  <james.greenhalgh@arm.com>
23387         * config/aarch64/aarch64.c (aarch64_simd_container_mode): Handle
23388         HFmode.
23390 2017-02-14  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
23392         PR rtl-optimization/68664
23393         * config/arm/arm.c (arm_sched_can_speculate_insn):
23394         New function.  Declare prototype.
23395         (TARGET_SCHED_CAN_SPECULATE_INSN): Define.
23397 2017-02-14  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
23399         PR rtl-optimization/68664
23400         * config/aarch64/aarch64.c (aarch64_sched_can_speculate_insn):
23401         New function.
23402         (TARGET_SCHED_CAN_SPECULATE_INSN): Define.
23404 2017-02-14  Amit Pawar  <amit.pawar@amd.com>
23406         * config/i386/i386.c (znver1_cost): Fix the alignment for function and
23407         max skip bytes for function, loop and jump.
23409 2017-02-14  Prathamesh Kulkarni  <prathamesh.kulkarni@linaro.org>
23411         * gimple-pretty-print.c (dump_unary_rhs): Adjust dump format for
23412         ABS_EXPR for gimple dump.
23414 2017-02-14  Jakub Jelinek  <jakub@redhat.com>
23416         PR target/79462
23417         * config/sh/sh.c (expand_cbranchdi4): Don't clear operands[4].
23419         PR tree-optimization/79408
23420         * tree-vrp.c (simplify_div_or_mod_using_ranges): Handle also the
23421         case when on TRUNC_MOD_EXPR op0 is INTEGER_CST.
23422         (simplify_stmt_using_ranges): Call simplify_div_or_mod_using_ranges
23423         also if rhs1 is INTEGER_CST.
23425 2017-02-14  Richard Biener  <rguenther@suse.de>
23427         PR middle-end/79432
23428         * tree-into-ssa.c (insert_phi_nodes): When the function can
23429         have abnormal edges rewrite SSA names with broken use-def
23430         dominance out of SSA and register them for PHI insertion.
23432 2017-02-13  Martin Sebor  <msebor@redhat.com>
23434         PR middle-end/79496
23435         * gimple-ssa-sprintf.c (pass_sprintf_length::handle_gimple_call): Avoid
23436         clearing info.nowrite flag when snprintf size argument is a range.
23438 2017-02-13  Jakub Jelinek  <jakub@redhat.com>
23440         * cprop.c (cprop_jump): Add missing space in string literal.
23441         * tree-ssa-structalias.c (rewrite_constraints): Likewise.
23442         (get_constraint_for_component_ref): Likewise.
23443         * df-core.c (df_worklist_dataflow_doublequeue): Likewise.
23444         * tree-outof-ssa.c (insert_partition_copy_on_edge): Likewise.
23445         * lra-constraints.c (process_alt_operands): Likewise.
23446         * ipa-inline.c (inline_small_functions): Likewise.
23447         * tree-ssa-sccvn.c (visit_reference_op_store): Likewise.
23448         * cgraph.c (cgraph_edge::redirect_call_stmt_to_callee): Likewise.
23449         * trans-mem.c (diagnose_tm_1_op): Likewise.
23450         * omp-grid.c (grid_find_single_omp_among_assignments): Likewise.
23451         (grid_parallel_clauses_gridifiable): Likewise.
23453         * config/nvptx/mkoffload.c (process): Add space in between
23454         , and %d.
23456         * config/i386/i386.h (REG_CLASS_NAMES): Add , in between
23457         "MOD4_SSE_REGS" and "ALL_REGS".
23459         * spellcheck.c (test_data): Add , in between "foo" and "food".
23461 2017-02-13  Aaron Sawdey  <acsawdey@linux.vnet.ibm.com>
23463         PR target/79449
23464         * config/rs6000/rs6000.c (expand_block_compare): Make sure runtime
23465         boundary crossing check and subsequent code generation agree.
23467 2017-02-13  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
23469         * config/aarch64/aarch64.c (has_memory_op): Delete.
23470         (aarch64_madd_needs_nop): Use contains_mem_rtx_p instead of
23471         has_memory_op.
23473 2017-02-13  Jakub Jelinek  <jakub@redhat.com>
23475         PR rtl-optimization/79388
23476         PR rtl-optimization/79450
23477         * combine.c (distribute_notes): When removing TEM_INSN for which
23478         corresponding dest has last value recorded, invalidate that last
23479         value.
23481 2017-02-13  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
23483         * config/arm/arm.c (arm_print_tune_info): Use ASM_COMMENT_START instead
23484         of explicit '@'.  Add missing assembly comment marker on branch costs
23485         printout.
23487 2017-02-13  Nathan Sidwell  <nathan@acm.org>
23489         * gengtype-lex.l (<in_struct>): Add '/'.
23491 2017-02-13  Martin Liska  <mliska@suse.cz>
23493         PR c/79471
23494         * calls.c (expand_call): Replace XALLOCAVEC with XCNEWVEC.
23496 2017-02-13  Richard Biener  <rguenther@suse.de>
23498         * configure.ac (HAVE_ISL_OPTIONS_SET_SCHEDULE_SERIALIZE_SCCS):
23499         Remove.
23500         * configure: Re-generate.
23501         * config.in: Likewise.
23502         * graphite-dependences.c: Simplify as if
23503         HAVE_ISL_OPTIONS_SET_SCHEDULE_SERIALIZE_SCCS was defined.
23504         * graphite-isl-ast-to-gimple.c: Likewise.
23505         * graphite-optimize-isl.c: Likewise.
23506         * graphite-poly.c: Likewise.
23507         * graphite-sese-to-poly.c: Likewise.
23508         * graphite.h: Likewise.
23509         * toplev.c: Include isl/version.h and use isl_version () for
23510         printing the ISL version.
23511         * doc/install.texi: Update ISL requirement.
23513 2017-02-12  Gerald Pfeifer  <gerald@pfeifer.com>
23515         * doc/standards.texi (Standards): Update reference to
23516         Objective-C 2.0.
23518 2017-02-12  Gerald Pfeifer  <gerald@pfeifer.com>
23520         * doc/extend.texi (Named Address Spaces): sourceware.org now
23521         defaults to https.
23522         * doc/install.texi (Binaries): Ditto.
23523         (Specific): Ditto.
23525 2017-02-11  Sandra Loosemore  <sandra@codesourcery.com>
23527         * doc/cpp.texi: Replace "stringify"/"stringification" with C
23528         standard terminology "stringize"/"stringizing" throughout.
23529         * doc/cppinternals.texi: Likewise.
23531 2017-02-11  Sandra Loosemore  <sandra@codesourcery.com>
23533         * doc/extend.texi: Fix some spelling mistakes and typos.
23534         * doc/invoke.texi: Likewise.
23536 2017-02-11  Jan Hubicka  <hubicka@ucw.cz>
23538         PR ipa/79224
23539         * params.def (inline-min-speedup) Change from 10 to 8.
23541 2017-02-11  Jakub Jelinek  <jakub@redhat.com>
23543         * doc/invoke.texi (fopenmp): Bump OpenMP version from 4.0 to
23544         4.5.
23546 2017-02-11  Jan Hubicka  <hubicka@ucw.cz>
23548         PR ipa/79224
23549         * ipa-inline-analysis.c (get_minimal_bb): New function.
23550         (record_modified): Use it.
23551         (remap_edge_change_prob): Handle also ancestor functions.
23553 2017-02-11  Gerald Pfeifer  <gerald@pfeifer.com>
23555         * doc/contrib.texi (Contributors): Remove broken link into
23556         the Mauve CVS repository.
23558 2017-02-11  Jakub Jelinek  <jakub@redhat.com>
23560         PR middle-end/79454
23561         * internal-fn.c (expand_vector_ubsan_overflow): Use piece-wise
23562         result computation whenever lhs doesn't have vector mode, not
23563         just when it has BLKmode.
23565 2017-02-10  Gerald Pfeifer  <gerald@pfeifer.com>
23567         * doc/makefile.texi (profiledbootstrap): Refer to the
23568         installation instructions only in textual form.
23570 2017-02-10  Aaron Sawdey  <acsawdey@linux.vnet.ibm.com>
23572         PR target/79295
23573         * config/rs6000/altivec.md (bcd<bcd_add_sub>): Fix constraints.
23575 2017-02-10  Gerald Pfeifer  <gerald@pfeifer.com>
23577         * doc/install.texi (Specific): Use https for blackfin.uclinux.org.
23578         (Specific): Update mingw-w64 reference.
23579         (Binaries): Ditto.
23580         (Specific): Remove broken link to Renesas RX processor.
23582 2017-02-10  Richard Biener  <rguenther@suse.de>
23584         * toplev.c (process_options): Do not mention obsolete graphite
23585         options when printing sorry message about missing graphite support.
23586         Mention -floop-nest-optimize.
23588 2017-02-10  Christophe Lyon  <christophe.lyon@linaro.org>
23590         * config/aarch64/arm_neon.h (vtst_p8): Rewrite without asm.
23591         (vtst_p16): Likewise.
23592         (vtstq_p8): Likewise.
23593         (vtstq_p16): Likewise.
23594         (vtst_p64): New.
23595         (vtstq_p64): Likewise.
23596         * config/arm/arm_neon.h (vgetq_lane_p64): New.
23597         (vset_lane_p64): New.
23598         (vsetq_lane_p64): New.
23600 2017-02-10  Jakub Jelinek  <jakub@redhat.com>
23602         PR tree-optimization/79411
23603         * tree-ssa-reassoc.c (is_reassociable_op): Return false if
23604         stmt operands are SSA_NAMEs used in abnormal phis.
23605         (can_reassociate_p): Return false if op is SSA_NAME used in abnormal
23606         phis.
23608 2017-02-09  Jan Hubicka  <hubicka@ucw.cz>
23610         PR ipa/70795
23611         * cgraphunit.c (cgraph_node::add_new_function): Set externally_visible
23612         flag if needed.
23614 2017-02-09  Jan Hubicka  <hubicka@ucw.cz>
23616         * tree-ssa-loop-unswitch.c (hoist_guard): Update profile.
23618 2017-02-09  Jakub Jelinek  <jakub@redhat.com>
23620         * omp-offload.c (oacc_loop_auto_partitions): Use || instead of |
23621         to avoid warning.
23623         PR c/79413
23624         * gimplify.h (is_gimple_sizepos): Only test for INTEGER_CST constants,
23625         not arbitrary TREE_CONSTANT.
23627         PR c/79431
23628         * gimplify.c (gimplify_adjust_omp_clauses): Ignore
23629         "omp declare target link" attribute unless is_global_var.
23630         * omp-offload.c (find_link_var_op): Likewise.
23632 2017-02-09  Nathan Sidwell  <nathan@codesourcery.com>
23633             Chung-Lin Tang  <cltang@codesourcery.com>
23635         * gimplify.c (gimplify_scan_omp_clauses): No special handling for
23636         OMP_CLAUSE_TILE.
23637         (gimplify_adjust_omp_clauses): Don't delete TILE.
23638         (gimplify_omp_for): Deal with TILE.
23639         * internal-fn.c (expand_GOACC_TILE): New function.
23640         * internal-fn.def (GOACC_DIM_POS): Comment may be overly conservative.
23641         (GOACC_TILE): New.
23642         * omp-expand.c (struct oacc_collapse): Add tile and outer fields.
23643         (expand_oacc_collapse_init): Add LOC paramter.  Initialize tile
23644         element fields.
23645         (expand_oacc_collapse_vars): Add INNER parm, adjust for tiling,
23646         avoid DIV for outermost collapse var.
23647         (expand_oacc_for): Insert tile element loop as needed.  Adjust.
23648         Remove out of date comments, fix whitespace.
23649         * omp-general.c (omp_extract_for_data): Deal with tiling.
23650         * omp-general.h (enum oacc_loop_flags): Add OLF_TILE flag,
23651         adjust OLF_DIM_BASE value.
23652         (struct omp_for_data): Add tiling field.
23653         * omp-low.c (scan_sharing_clauses): Allow OMP_CLAUSE_TILE.
23654         (lower_oacc_head_mark): Add OLF_TILE as appropriate.  Ensure 2 levels
23655         for auto loops.  Remove default auto determining, moved to
23656         oacc_loop_fixed_partitions.
23657         * omp-offload.c (struct oacc_loop): Change 'ifns' to vector of call
23658         stmts, add e_mask field.
23659         (oacc_dim_call): New function, abstracted out from oacc_thread_numbers.
23660         (oacc_thread_numbers): Use oacc_dim_call.
23661         (oacc_xform_tile): New.
23662         (new_oacc_loop_raw): Initialize e_mask, adjust for ifns vector.
23663         (finish_oacc_loop): Adjust for ifns vector.
23664         (oacc_loop_discover_walk): Append loop abstraction sites to list,
23665         add case for GOACC_TILE fns.
23666         (oacc_loop_xform_loop): Delete.
23667         (oacc_loop_process): Iterate over call list directly, and add
23668         handling for GOACC_TILE fns.
23669         (oacc_loop_fixed_partitions): Determine default auto, deal with TILE,
23670         dump partitioning.
23671         (oacc_loop_auto_partitions): Add outer_assign parm. Assign all but
23672         vector partitioning to outer loops.  Assign 2 partitions to loops
23673         when available. Add TILE handling.
23674         (oacc_loop_partition): Adjust oacc_loop_auto_partitions call.
23675         (execite_oacc_device_lower): Process GOACC_TILE fns,
23676         ignore unknown specs.
23677         * tree-nested.c (convert_nonlocal_omp_clauses): Allow OMP_CLAUSE_TILE.
23678         * tree.c (omp_clause_num_ops): Adjust TILE ops.
23679         * tree.h (OMP_CLAUSE_TILE_ITERVAR, OMP_CLAUSE_TILE_COUNT): New.
23681 2017-02-09  Gerald Pfeifer  <gerald@pfeifer.com>
23683         * configure.ac (ACX_BUGURL): Update.
23684         * configure: Regenerate.
23686 2017-02-09  Richard Biener  <rguenther@suse.de>
23688         PR tree-optimization/69823
23689         * graphite-scop-detection.c (scop_detection::harmful_loop_in_region):
23690         Properly enumerate all BBs in the region.  Use auto_vec/auto_bitmap.
23692 2017-02-09  Andrew Burgess  <andrew.burgess@embecosm.com>
23694         * config/arc/arc-c.def: Add __NPS400__ definition.
23695         * config/arc/arc.h (CPP_SPEC): Don't define __NPS400__ here.
23696         (TARGET_NPS400): Define.
23698 2017-02-09  Andrew Burgess  <andrew.burgess@embecosm.com>
23700         * config/arc/arc-arch.h (arc_arch_t): Move unchanged to earlier in
23701         file.
23702         (arc_cpu_t): Change base_architecture field, arch, to a arc_arc_t
23703         pointer, arch_info.
23704         (arc_cpu_types): Fill the arch_info field with a pointer into the
23705         arc_arch_types table.
23706         (arc_selected_cpu): Declare.
23707         * config/arc/arc.c (arc_selected_cpu): Make global.
23708         (arc_selected_arch): Delete.
23709         (arc_base_cpu): Delete.
23710         (arc_override_options): Remove references to deleted variables,
23711         update access to arch information.
23712         (ARC_OPT): Update access to arch information.
23713         (ARC_OPTX): Likewise.
23714         * config/arc/arc.h (arc_base_cpu): Remove declaration.
23715         (TARGET_ARC600): Update access to arch information.
23716         (TARGET_ARC601): Likewise.
23717         (TARGET_ARC700): Likewise.
23718         (TARGET_EM): Likewise.
23719         (TARGET_HS): Likewise.
23720         * config/arc/driver-arc.c (arc_cpu_to_as): Update access to arch
23721         information.
23723 2017-02-08  Pat Haugen  <pthaugen@us.ibm.com>
23725         PR target/78604
23726         * config/rs6000/rs6000.c (rs6000_emit_vector_cond_expr): Invert
23727         condition/operands for integer GE/LE/GEU/LEU operations.
23729 2017-02-08  Segher Boessenkool  <segher@kernel.crashing.org>
23731         PR translation/79397
23732         * config/rs6000/rs6000.opt (maltivec=le, maltivec=be): Fix spelling
23733         of AltiVec.
23735 2017-02-08  Martin Jambor  <mjambor@suse.cz>
23737         PR ipa/79375
23738         * ipa-prop.c (ipa_alloc_node_params): Make static, return bool
23739         whether allocation happened.
23740         (ipa_initialize_node_params): Do not call ipa_alloc_node_params if
23741         nothing was allocated.
23743 2017-02-08  Jakub Jelinek  <jakub@redhat.com>
23745         PR tree-optimization/79408
23746         * tree-vrp.c (simplify_div_or_mod_using_ranges): If op1 is not
23747         constant, but SSA_NAME with a known integer range, use the minimum
23748         of that range instead of op1 to determine if modulo can be replaced
23749         with its first operand.
23751 2016-02-08  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
23753         * config/riscv/riscv.c (riscv_build_integer_1): Avoid use of INT16_MAX.
23755 2017-02-08  Richard Biener  <rguenther@suse.de>
23757         PR tree-optimization/71824
23758         * graphite-scop-detection.c (scop_detection::build_scop_breadth):
23759         Check all loops contained in the merged region.
23761 2017-02-07  Andrew Pinski  <apinski@cavium.com>
23763         * config/aarch64/aarch64.md (popcount<mode>2): New pattern.
23765 2017-02-07  Andrew Pinski  <apinski@cavium.com>
23767         * config/aarch64/aarch64-cores.def (thunderx): Disable LSE.
23768         (thunderxt88): Likewise.
23769         (thunderxt81): Disable LSE and change v8.1 to v8.
23770         (thunderxt83): Likewise.
23772 2017-02-07  Jakub Jelinek  <jakub@redhat.com>
23773             Richard Biener  <rguenther@suse.de>
23775         PR middle-end/79399
23776         * ira-int.h (struct target_ira_int): Change x_max_struct_costs_size
23777         type from int to size_t.
23778         * ira-costs.c (struct_costs_size): Change type from int to size_t.
23780 2017-02-07  Jakub Jelinek  <jakub@redhat.com>
23782         PR rtl-optimization/79386
23783         * cprop.c (bypass_conditional_jumps): Initialize
23784         bypass_last_basic_block already before splitting bbs after
23785         unconditional traps...
23786         (bypass_conditional_jumps): ... rather than here.
23788         PR target/79299
23789         * config/i386/sse.md (xtg_mode, gatherq_mode): New mode attrs.
23790         (*avx512f_gathersi<mode>, *avx512f_gathersi<mode>_2,
23791         *avx512f_gatherdi<mode>, *avx512f_gatherdi<mode>_2): Use them,
23792         fix -masm=intel patterns.
23794 2017-02-07  Richard Biener  <rguenther@suse.de>
23796         PR tree-optimization/79256
23797         PR middle-end/79278
23798         * builtins.c (get_object_alignment_2): Use min_align_of_type
23799         to extract alignment for MEM_REFs to honor BIGGEST_FIELD_ALIGNMENT
23800         and ADJUST_FIELD_ALIGN.
23802         * doc/tm.texi.in (ADJUST_FIELD_ALIGN): Adjust to take additional
23803         type parameter.
23804         * doc/tm.texi: Regenerate.
23805         * stor-layout.c (layout_decl): Adjust.
23806         (update_alignment_for_field): Likewise.
23807         (place_field): Likewise.
23808         (min_align_of_type): Likewise.
23809         * config/arc/arc.h (ADJUST_FIELD_ALIGN): Adjust.
23810         * config/epiphany/epiphany.h (ADJUST_FIELD_ALIGN): Likewise.
23811         * config/epiphany/epiphany.c (epiphany_adjust_field_align): Likewise.
23812         * config/frv/frv.h (ADJUST_FIELD_ALIGN): Likewise.
23813         * config/frv/frv.c (frv_adjust_field_align): Likewise.
23814         * config/i386/i386.h (ADJUST_FIELD_ALIGN): Likewise.
23815         * config/i386/i386.c (x86_field_alignment): Likewise.
23816         * config/rs6000/aix.h (ADJUST_FIELD_ALIGN): Likewise.
23817         * config/rs6000/darwin.h (ADJUST_FIELD_ALIGN): Likewise.
23818         * config/rs6000/freebsd64.h (ADJUST_FIELD_ALIGN): Likewise.
23819         * config/rs6000/linux64.h (ADJUST_FIELD_ALIGN): Likewise.
23820         * config/rs6000/sysv4.h (ADJUST_FIELD_ALIGN): Likewise.
23821         * config/rs6000/rs6000.c (rs6000_special_adjust_field_align_p):
23822          Likewise.
23824         Revert
23825         2017-01-30  Richard Biener  <rguenther@suse.de>
23827         PR tree-optimization/79256
23828         * targhooks.c (default_builtin_vector_alignment_reachable): Honor
23829         BIGGEST_FIELD_ALIGNMENT and ADJUST_FIELD_ALIGN to fix up bogus
23830         alignment on TYPE.
23832 2017-02-07  Toma Tabacu  <toma.tabacu@imgtec.com>
23834         * config/mips/mips.c (mips_expand_builtin_insn): Convert the QImode
23835         argument of the pshufh, psllh, psllw, psrah, psraw, psrlh, psrlw
23836         builtins to SImode and emit a zero-extend, if necessary.
23838 2017-02-06  Palmer Dabbelt  <palmer@dabbelt.com>
23840         * docs/invoke.texi (RISC-V Options): Alphabetize.
23842 2017-02-06  Palmer Dabbelt  <palmer@dabbelt.com>
23844         * doc/invoke.texi (RISC-V Options): Use two spaces to separate
23845         options.
23847 2017-02-06  Palmer Dabbelt  <palmer@dabbelt.com>
23849         * config/riscv/riscv.c: New file.
23850         * common/config/riscv/riscv-common.c: Likewise.
23851         * config.gcc: Likewise.
23852         * config/riscv/constraints.md: Likewise.
23853         * config/riscv/elf.h: Likewise.
23854         * config/riscv/generic.md: Likewise.
23855         * config/riscv/linux.h: Likewise.
23856         * config/riscv/multilib-generator: Likewise.
23857         * config/riscv/peephole.md: Likewise.
23858         * config/riscv/pic.md: Likewise.
23859         * config/riscv/predicates.md: Likewise.
23860         * config/riscv/riscv-builtins.c: Likewise.
23861         * config/riscv/riscv-c.c: Likewise.
23862         * config/riscv/riscv-ftypes.def: Likewise.
23863         * config/riscv/riscv-modes.def: Likewise.
23864         * config/riscv/riscv-opts.h: Likewise.
23865         * config/riscv/riscv-protos.h: Likewise.
23866         * config/riscv/riscv.h: Likewise.
23867         * config/riscv/riscv.md: Likewise.
23868         * config/riscv/riscv.opt: Likewise.
23869         * config/riscv/sync.md: Likewise.
23870         * config/riscv/t-elf-multilib: Likewise.
23871         * config/riscv/t-linux: Likewise.
23872         * config/riscv/t-linux-multilib: Likewise.
23873         * config/riscv/t-riscv: Likewise.
23874         * configure.ac: Likewise.
23875         * doc/contrib.texi: Add Kito Cheng, Palmer Dabbelt, and Andrew
23876         Waterman as RISC-V maintainers.
23877         * doc/install.texi: Add RISC-V entries.
23878         * doc/invoke.texi: Add RISC-V options section.
23879         * doc/md.texi: Add RISC-V constraints section.
23880         * configure: Regenerated.
23882 2017-02-06  Michael Meissner  <meissner@linux.vnet.ibm.com>
23884         PR target/66144
23885         * config/rs6000/vector.md (vcond<mode><mode>): Allow the true and
23886         false values to be constant vectors with all 0 or all 1 bits set.
23887         (vcondu<mode><mode>): Likewise.
23888         * config/rs6000/predicates.md (vector_int_reg_or_same_bit): New
23889         predicate.
23890         (fpmask_comparison_operator): Update comment.
23891         (vecint_comparison_operator): New predicate.
23892         * config/rs6000/rs6000.c (rs6000_emit_vector_cond_expr): Optimize
23893         vector conditionals when the true and false values are constant
23894         vectors with all 0 bits or all 1 bits set.
23896 2017-02-06  Martin Sebor  <msebor@redhat.com>
23898         PR  tree-optimization/79376
23899         * gimple-fold.c (get_range_strlen): Set the minimum length to zero.
23901 2017-02-06  Uros Bizjak  <ubizjak@gmail.com>
23903         * config/i386/sse.md (vector modes -> vec_extract* splitter): Use
23904         explicit subreg RTX with operand 1.  Use VECTOR_MODE_P predicate
23905         to simplify split condition.
23907 2017-02-06  Jakub Jelinek  <jakub@redhat.com>
23909         * omp-expand.c (oxpand_omp_atomic_fetch_op,
23910         expand_omp_atomic_pipeline): Return false if can_atomic_load_p is
23911         false.
23913 2017-02-06  Segher Boessenkool  <segher@kernel.crashing.org>
23915         PR rtl-optimization/68664
23916         * target.def (can_speculate_insn): New hook.
23917         * doc/tm.texi.in (TARGET_SCHED_CAN_SPECULATE_INSN): New hook.
23918         * doc/tm.texi: Regenerate.
23919         * sched-rgn.c (can_schedule_ready_p): Use the new hook.
23920         * config/rs6000/rs6000.c (TARGET_SCHED_CAN_SPECULATE_INSN): New macro.
23921         (rs6000_sched_can_speculate_insn): New function.
23923 2017-02-06  Jakub Jelinek  <jakub@redhat.com>
23925         PR tree-optimization/79284
23926         * tree-vectorizer.h (VECT_SCALAR_BOOLEAN_TYPE_P): Define.
23927         * tree-vect-stmts.c (vect_get_vec_def_for_operand,
23928         vectorizable_mask_load_store, vectorizable_operation,
23929         vect_is_simple_cond, get_same_sized_vectype): Use it instead
23930         of comparing TREE_CODE of a type against BOOLEAN_TYPE.
23931         * tree-vect-patterns.c (check_bool_pattern, search_type_for_mask_1,
23932         vect_recog_bool_pattern, vect_recog_mask_conversion_pattern): Likewise.
23933         * tree-vect-slp.c (vect_get_constant_vectors): Likewise.
23934         * tree-vect-loop.c (vect_determine_vectorization_factor): Likewise.
23935         Remove redundant gimple_code (stmt) == GIMPLE_ASSIGN test after
23936         is_gimple_assign (stmt).  Replace another such test with
23937         is_gimple_assign (stmt).
23939 2017-02-06  Georg-Johann Lay  <avr@gjlay.de>
23941         PR target/78883
23942         * config/avr/avr.c (rtl-iter.h): Include it.
23943         (TARGET_LEGITIMATE_COMBINED_INSN): New hook define...
23944         (avr_legitimate_combined_insn): ...and implementation.
23946 2017-02-06  Dominik Vogt  <vogt@linux.vnet.ibm.com>
23948         * config/s390/predicates.md ("larl_operand"): Use macros from hwint.h.
23949         * config/s390/s390.c (s390_const_operand_ok)
23950         (s390_canonicalize_comparison, s390_extract_part)
23951         (s390_single_part, s390_contiguous_bitmask_nowrap_p)
23952         (s390_contiguous_bitmask_p, s390_rtx_costs)
23953         (legitimize_pic_address): Likewise.
23954         * config/s390/s390.md ("clzdi2", "clztidi2"): Likewise.
23955         * config/s390/vx-builtins.md ("vec_genbytemaskv16qi")
23956         ("vec_permi<mode>", "vfae<mode>", "*vfaes<mode>", "vstrc<mode>")
23957         ("*vstrcs<mode>"): Use UINTVAL() to set unsigned HOST_WIDE_INT.
23958         * config/s390/vector.md ("vec_vfenes<mode>"): Likewise.
23960 2017-02-06  Georg-Johann Lay  <avr@gjlay.de>
23962         * config/avr/avr.md (*addhi3_zero_extend): Add alternative where
23963         REGNO($0) == REGNO($1).
23965 2017-02-06  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
23967         * config/s390/linux.h(SIZE_TYPE): Add comment.
23969 2017-02-06  Julian Brown  <julian@codesourcery.com>
23970             Naveen H.S  <Naveen.Hurugalawadi@cavium.com>
23971             Virendra Pathak  <virendra.pathak@broadcom.com>
23973         * config/aarch64/aarch64-cores.def: Change the scheduler
23974         to Thunderx2t99.
23975         * config/aarch64/aarch64.md: Include thunderx2t99.md.
23976         * config/aarch64/thunderx2t99.md: New file.
23978 2017-02-05  Gerald Pfeifer  <gerald@pfeifer.com>
23980         * doc/standards.texi (Go Language): Update link to language
23981         standard.
23983 2017-02-05  Jan Hubicka  <hubicka@ucw.cz>
23985         * tree-eh.c (lower_resx): Sanitize profile.
23986         (cleanup_empty_eh_move_lp): Likewise.
23988 2017-02-05  Jan Hubicka  <hubicka@ucw.cz>
23990         PR tree-ssa/79347
23991         * cfgloopmanip.c (lv_adjust_loop_entry_edge, loop_version): Add
23992         ELSE_PROB.
23993         * cfgloopmanip.h (loop_version): Update prototype.
23994         * modulo-sched.c (sms_schedule): Update call of loop_version.
23995         * tree-if-conv.c(version_loop_for_if_conversion): Likewise.
23996         * tree-parloops.c (gen_parallel_loop): Likewise.
23997         * tree-ssa-loop-manip.c (tree_transform_and_unroll_loop): Likewise.
23998         * tree-ssa-loop-split.c (split_loop): Likewise.
23999         * tree-ssa-loop-unswitch.c (tree_unswitch_loop): Likewise.
24000         * tree-vect-loop-manip.c (vect_loop_versioning): Likewise.
24002 2017-02-05  Martin Liska  <mliska@suse.cz>
24004         PR bootstrap/78985
24005         * config/s390/s390.c (s390_gimplify_va_arg): Initialize local
24006         variable to NULL.
24007         (print_operand_address): Initialize a struct to zero.
24009 2017-02-05  Gerald Pfeifer  <gerald@pfeifer.com>
24011         * doc/contrib.texi (Contributors): Refer to Hans Boehm's
24012         garbage collector only in textual form.
24014 2017-02-05  Gerald Pfeifer  <gerald@pfeifer.com>
24016         * doc/extend.texi (x86 specific memory model extensions for
24017         transactional memory): Simplify a phrase.
24019 2017-02-05  Eric Botcazou  <ebotcazou@adacore.com>
24021         PR target/79353
24022         * config/sparc/sync.md (atomic_loaddi_1): Replace 'U' constraint with
24023         'r', 'm' constraint with 'T' and !TARGET_ARCH64 with TARGET_ARCH32.
24024         (atomic_storedi_1): Likewise.
24026 2017-02-04  Jakub Jelinek  <jakub@redhat.com>
24028         PR tree-optimization/79338
24029         * tree-parloops.c (gather_scalar_reductions): Don't call
24030         vect_analyze_loop_form for loop->inner before destroying loop's
24031         loop_vinfo.
24033 2017-02-03  Martin Sebor  <msebor@redhat.com>
24035         PR tree-optimization/79327
24036         * gimple-ssa-sprintf.c (tree_digits): Avoid adding the base prefix
24037         when precision has resulted in leading zeros.
24038         (format_integer): Adjust the likely counter to assume an unknown
24039         argument that may be zero is non-zero.
24041 2017-02-03  Jason Merrill  <jason@redhat.com>
24043         PR c++/78689
24044         * tree-inline.c (copy_tree_body_r) [COND_EXPR]: Revert change to
24045         avoid copying non-taken branch.
24047 2017-02-03  Jakub Jelinek  <jakub@redhat.com>
24049         PR tree-optimization/79340
24050         * tree-vect-loop.c (vectorizable_reduction): Release
24051         vec_defs elements after safe_splicing them into other vectors.
24052         Formatting fixes.
24054         PR tree-optimization/79327
24055         * gimple-ssa-sprintf.c (adjust_range_for_overflow): If returning
24056         true, always set *argmin and *argmax to TYPE_{MIN,MAX}_VALUE of
24057         dirtype.
24058         (format_integer): Use wide_int_to_tree instead of build_int_cst
24059         + to_?hwi.  If argmin is NULL, just set argmin and argmax to
24060         TYPE_{MIN,MAX}_VALUE of argtype.  Simplify and fix computation
24061         of shortest and longest sequence.
24063 2017-02-03  Uros Bizjak  <ubizjak@gmail.com>
24065         * config/i386/i386.c (dimode_scalar_chain::convert_reg):
24066         Use pextrd for TARGET_SSE4_1 when creating scalar copy.
24068 2017-02-03  Walter Lee  <walt@tilera.com>
24070         PR target/78862
24071         * config/tilegx/tilegx.md (tilegx_expand_prologue): Add blockage
24072         after initial stackframe link reg save.
24073         * config/tilepro/tilepro.md (tilepro_expand_prologue): Likewise.
24075 2017-02-03  Jakub Jelinek  <jakub@redhat.com>
24077         PR target/79354
24078         * config/rs6000/rs6000.md (movsi_from_sf): Use wb constraint instead of
24079         wu for stxssp alternative.
24081 2017-02-03  Martin Sebor  <msebor@redhat.com>
24083         PR tree-optimization/79352
24084         * gimple-fold.c (get_range_strlen): Add argument.
24085         (get_range_strlen): Change return type to bool.
24086         (get_maxval_strlen): Pass in a dummy argument.
24087         * gimple-fold.h (get_range_strlen): Change return type to bool.
24088         * gimple-ssa-sprintf.c (get_string_length): Set unlikely counter.
24089         * tree.h (array_at_struct_end_p): Add argument.
24090         * tree.c (array_at_struct_end_p): Handle it.
24092 2017-02-03  Martin Liska  <mliska@suse.cz>
24094         PR lto/66295
24095         * multiple_target.c (create_dispatcher_calls): Redirect edge
24096         from a caller of a dispatcher.
24097         (expand_target_clones): Make the clones local.
24098         (ipa_target_clone): Do both target clones and resolvers.
24099         (ipa_dispatcher_calls): Remove the pass.
24100         (pass_dispatcher_calls::gate): Likewise.
24101         (make_pass_dispatcher_calls): Likewise.
24102         * passes.def (pass_target_clone): Put as very first IPA early
24103         pass.
24105 2017-02-03  Martin Liska  <mliska@suse.cz>
24107         * symtab.c (symtab_node::binds_to_current_def_p): Bail out
24108         in case of a function with ifunc attribute.
24110 2017-02-03  Martin Liska  <mliska@suse.cz>
24112         * cgraph.c (cgraph_node::dump): Dump function version info.
24113         * symtab.c (symtab_node::dump_base): Add missing new line.
24115 2017-02-02  Jan Hubicka  <hubicka@ucw.cz>
24117         * tree-ssa-ifcombine.c (update_profile_after_ifcombine): New function.
24118         (ifcombine_ifandif): Use it.
24120 2017-02-03  Martin Liska  <mliska@suse.cz>
24122         * doc/invoke.texi: Document default value for
24123         use-after-scope-direct-emission-threshold.
24125 2017-02-03  Martin Liska  <mliska@suse.cz>
24127         PR tree-optimization/79339
24128         * gimple-ssa-sprintf.c (format_floating_max): Call mpfr_clear.
24129         (format_floating): Likewise.
24131 2017-02-03  Martin Liska  <mliska@suse.cz>
24133         PR ipa/79337
24134         * ipa-prop.c (ipa_node_params_t::insert): Remove current
24135         implementation.
24136         (ipa_node_params_t::remove): Likewise.
24137         * ipa-prop.h (ipa_node_params::ipa_node_params): Make default
24138         initialization from removed ipa_node_params_t::insert.
24139         (ipa_node_params::~ipa_node_params): Move from removed
24140         ipa_node_params_t::release.
24141         * symbol-summary.h (symbol_summary::m_released): New member.
24142         Do not release a summary twice.  Do not allow to call finalizer
24143         for types of a summary that live in GGC memory.
24145 2017-02-02  Naveen H.S  <Naveen.Hurugalawadi@cavium.com>
24147         * config/aarch64/aarch64.c (thunderx2t99_tunings): Enable AES and
24148         cmp_branch fusion.
24150 2017-02-02  Martin Sebor  <msebor@redhat.com>
24152         PR middle-end/79275
24153         * gimple-ssa-sprintf.c (get_string_length): Set lower bound to zero.
24154         (format_string): Tighten up the range of output for non-constant
24155         strings and correct the expected range for wide non-constant strings.
24157 2017-02-02  Martin Sebor  <msebor@redhat.com>
24159         * doc/invoke.texi (-maccumulate-args): Fix bad grammar.
24161         PR middle-end/32003
24162         * doc/invoke.texi (-fdump-tree-): Remove pass-specific options from
24163         index.
24164         (-fdump-tree-@var): Add to index and document how to come up
24165         with pass-specific option and dump file names.
24166         (-fdump-passes): Clarify where to look for output.
24168 2017-02-02  Jan Hubicka  <hubicka@ucw.cz>
24170         PR middle-end/77445
24171         * tree-ssa-threadbackward.c (profitable_jump_thread_path): Dump
24172         statistics of the analyzed path; allow threading for speed when
24173         any of BBs along the path are optimized for speed.
24175 2017-02-02  Eric Botcazou  <ebotcazou@adacore.com>
24177         PR middle-end/78468
24178         * emit-rtl.c (init_emit): Add ??? comment for problematic alignment
24179         settings of the virtual registers.
24181         Revert again
24182         2016-08-23  Dominik Vogt  <vogt@linux.vnet.ibm.com>
24184         * explow.c (get_dynamic_stack_size): Take known alignment of stack
24185         pointer + STACK_DYNAMIC_OFFSET into account when calculating the size
24186         needed.
24188 2017-02-02  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
24190         * config/s390/vx-builtins.md ("vec_ceil", "vec_floor")
24191         ("vec_trunc", "vec_roundc", "vec_round"): Remove expanders.
24193 2017-02-02  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
24195         * config/s390/s390.md: Add missing comments with the expanded
24196         mnemonics.
24197         * config/s390/vector.md: Likewise.
24198         * config/s390/vx-builtins.md: Likewise.
24200 2017-02-02  Jakub Jelinek  <jakub@redhat.com>
24202         PR target/79197
24203         * config/rs6000/rs6000.md (*fixuns_trunc<mode>di2_fctiduz): Rename to ...
24204         (fixuns_trunc<mode>di2): ... this, remove previous expander.  Put all
24205         conditions on a single line.
24207 2017-02-02  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
24209         * config/s390/s390-c.c (s390_cpu_cpp_builtins_internal): Rename
24210         __S390_VX__ to __VX__.
24212 2017-02-01  Andrew Pinski  <apinski@cavium.com>
24214         * tree-vect-loop.c (vect_compute_single_scalar_iteration_cost): Pass
24215         stmt_info to record_stmt_cost.
24216         (vect_get_known_peeling_cost): Pass stmt_info if known to
24217         record_stmt_cost.
24218         * config/aarch64/aarch64-protos.h (cpu_vector_cost): Split
24219         cpu_vector_cost field into
24220         scalar_int_stmt_cost and scalar_fp_stmt_cost.  Split vec_stmt_cost
24221         field into vec_int_stmt_cost and vec_fp_stmt_cost.
24222         * config/aarch64/aarch64.c (generic_vector_cost): Update for the
24223         splitting of scalar_stmt_cost and vec_stmt_cost.
24224         (thunderx_vector_cost): Likewise.
24225         (cortexa57_vector_cost): LIkewise.
24226         (exynosm1_vector_cost): Likewise.
24227         (xgene1_vector_cost): Likewise.
24228         (thunderx2t99_vector_cost): Improve after the splitting of the two
24229         fields.
24230         (aarch64_builtin_vectorization_cost): Update for the splitting of
24231         scalar_stmt_cost and vec_stmt_cost.
24233 2017-02-01  Torvald Riegel  <triegel@redhat.com>
24234             Richard Henderson  <rth@redhat.com>
24236         * builtins.c (fold_builtin_atomic_always_lock_free): Make "lock-free"
24237         conditional on existance of a fast atomic load.
24238         * optabs-query.c (can_atomic_load_p): New function.
24239         * optabs-query.h (can_atomic_load_p): Declare it.
24240         * optabs.c (expand_atomic_exchange): Always delegate to libatomic if
24241         no fast atomic load is available for the particular size of access.
24242         (expand_atomic_compare_and_swap): Likewise.
24243         (expand_atomic_load): Likewise.
24244         (expand_atomic_store): Likewise.
24245         (expand_atomic_fetch_op): Likewise.
24246         * testsuite/lib/target-supports.exp
24247         (check_effective_target_sync_int_128): Remove x86 because it provides
24248         no fast atomic load.
24249         (check_effective_target_sync_int_128_runtime): Likewise.
24251 2017-02-01  Richard Biener  <rguenther@suse.de>
24253         * graphite.c: Include tree-vectorizer.h for find_loop_location.
24254         (graphite_transform_loops): Provide opt-info for optimized nests.
24255         * tree-parloop.c (parallelize_loops): Provide opt-info for
24256         parallelized loops.
24258 2017-02-01  Richard Biener  <rguenther@suse.de>
24260         PR middle-end/79315
24261         * tree-cfg.c (move_stmt_op): Never set TREE_BLOCK when it
24262         was not set before.
24264 2017-02-01  Richard Biener  <rguenther@suse.de>
24266         PR tree-optimization/71824
24267         * graphite-scop-detection.c (scop_detection::build_scop_breadth):
24268         Verify the loops are valid in the merged SESE region.
24269         (scop_detection::can_represent_loop_1): Check analyzing the
24270         evolution of the number of iterations in the region succeeds.
24272 2017-01-31  Ian Lance Taylor  <iant@golang.org>
24274         * config/i386/i386.c (ix86_expand_split_stack_prologue): Add
24275         REG_ARGS_SIZE note to 32-bit push insns and call insn.
24277 2017-01-31  David Malcolm  <dmalcolm@redhat.com>
24279         PR preprocessor/79210
24280         * input.c (get_substring_ranges_for_loc): Replace line_width
24281         assertion with error-handling.
24283 2017-01-31  Richard Biener  <rguenther@suse.de>
24285         PR tree-optimization/77318
24286         * graphite-sese-to-poly.c (extract_affine): Fix assert.
24287         (create_pw_aff_from_tree): Take loop parameter.
24288         (add_condition_to_pbb): Pass loop of the condition to
24289         create_pw_aff_from_tree.
24291 2017-01-31  Jakub Jelinek  <jakub@redhat.com>
24293         * config/s390/s390.c (s390_asan_shadow_offset): New function.
24294         (TARGET_ASAN_SHADOW_OFFSET): Redefine.
24296 2017-01-31  Michael Meissner  <meissner@linux.vnet.ibm.com>
24298         PR target/78597
24299         PR target/79038
24300         * config/rs6000/rs6000-protos.h (convert_float128_to_int): Delete,
24301         no longer used.
24302         (convert_int_to_float128): Likewise.
24303         * config/rs6000/rs6000.c (convert_float128_to_int): Likewise.
24304         (convert_int_to_float128): Likewise.
24305         * config/rs6000/rs6000.md (UNSPEC_IEEE128_MOVE): Likewise.
24306         (UNSPEC_IEEE128_CONVERT): Likewise.
24307         (floatsi<mode>2, FLOAT128 iterator): Bypass calling
24308         rs6000_expand_float128_convert if we have IEEE 128-bit hardware.
24309         Use local variables for IBM extended format.
24310         (fix_trunc<mode>si2, FLOAT128 iterator): Likewise.
24311         (fix_trunc<mode>si2_fprs): Likewise.
24312         (fixuns_trunc<IEEE128:mode><SDI:mode>2): Likewise.
24313         (floatuns<IEEE128:mode>2, IEEE128 iterator): Likewise.
24314         (fix<uns>_<mode>si2_hw): Rework the IEEE 128-bt hardware support
24315         to know that we can now have integers of all sizes in vector
24316         registers.
24317         (fix<uns>_<mode>di2_hw): Likewise.
24318         (float<uns>_<mode>si2_hw): Likewise.
24319         (fix_<mode>si2_hw): Likewise.
24320         (fixuns_<mode>si2_hw): Likewise.
24321         (float<uns>_<mode>di2_hw): Likewise.
24322         (float_<mode>di2_hw): Likewise.
24323         (float_<mode>si2_hw): Likewise.
24324         (floatuns_<mode>di2_hw): Likewise.
24325         (floatuns_<mode>si2_hw): Likewise.
24326         (xscvqp<su>wz_<mode>): Delete, no longer used.
24327         (xscvqp<su>dz_<mode>): Likewise.
24328         (xscv<su>dqp_<mode>): Likewise.
24329         (ieee128_mfvsrd_64bit): Likewise.
24330         (ieee128_mfvsrd_32bit): Likewise.
24331         (ieee128_mfvsrwz): Likewise.
24332         (ieee128_mtvsrw): Likewise.
24333         (ieee128_mtvsrd_64bit): Likewise.
24334         (ieee128_mtvsrd_32bit): Likewise.
24336 2017-01-31  Martin Liska  <mliska@suse.cz>
24338         PR ipa/79285
24339         * ipa-prop.c (ipa_free_all_node_params): Call release method
24340         instead of ~sumbol_summary to not to trigger double times
24341         dtor of hash_map.
24343 2017-01-31  Aldy Hernandez  <aldyh@redhat.com>
24345         PR tree-optimization/71691
24346         * bitmap.h (class auto_bitmap): New.
24347         * tree-ssa-loop-unswitch.c (tree_may_unswitch_on): Call
24348         is_maybe_undefined instead of ssa_undefined_value_p.
24350 2017-01-31  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
24352         * config/s390/s390-c.c (s390_cpu_cpp_builtins_internal): Rename
24353         __S390_ARCH_LEVEL__ to __ARCH__.
24355 2017-01-31  Jakub Jelinek  <jakub@redhat.com>
24357         PR tree-optimization/79267
24358         * value-prof.c (gimple_ic): Only drop lhs for noreturn calls
24359         if should_remove_lhs_p is true.
24361 2017-01-30  Alexandre Oliva <aoliva@redhat.com>
24363         PR debug/63238
24364         * dwarf2out.c (clone_as_declaration): Drop DW_AT_alignment.
24365         (add_alignment_attribute): New.
24366         (base_type_die): Add alignment attribute.
24367         (subrange_type_die): Likewise.
24368         (modified_type_die): Likewise.
24369         (gen_array_type_die): Likewise.
24370         (gen_descr_array_type_die: Likewise.
24371         (gen_enumeration_type_die): Likewise.
24372         (gen_subprogram_die): Likewise.
24373         (gen_variable_die): Likewise.
24374         (gen_field_die): Likewise.
24375         (gen_ptr_to_mbr_type_die): Likewise.
24376         (gen_struct_or_union_type_die): Likewise.
24377         (gen_subroutine_type_die): Likewise.
24378         (gen_typedef_die): Likewise.
24379         (base_type_cmp): Compare alignment attribute.
24381 2017-01-30  Aaron Sawdey  <acsawdey@linux.vnet.ibm.com>
24383         PR target/79170
24384         * config/rs6000/altivec.md (*setb_internal): Rename to setb_signed.
24385         (setb_unsigned) New pattern for setb with CCUNS.
24386         * config/rs6000/rs6000.c (expand_block_compare): Use a different
24387         subfc./subfe sequence to avoid overflow problems.  Generate a
24388         shorter sequence with cmpld/setb for power9.
24389         * config/rs6000/rs6000.md (subf<mode>3_carry_dot2): Add a new pattern
24390         for generating subfc. instruction.
24391         (cmpstrsi): Add TARGET_POPCNTD predicate as the generate sequence
24392         now uses this instruction.
24394 2017-01-30  Ian Lance Taylor  <iant@google.com>
24396         PR debug/79289
24397         * dwarf2out.c (gen_type_die_with_usage): When picking a variant
24398         for FUNCTION_TYPE/METHOD_TYPE, use the first matching one.
24400 2017-01-30  Martin Sebor  <msebor@redhat.com>
24402         * gimple-ssa-sprintf.c (fmtresult::adjust_for_width_or_precision):
24403         Move constant to the right of a relational operator.
24404         (get_mpfr_format_length, format_character, format_string): Ditto.
24405         (should_warn_p, maybe_warn): Same.
24407         * doc/invoke.texi (-Wformat-truncation=1): Fix typo.
24409 2017-01-30  Maxim Ostapenko  <m.ostapenko@samsung.com>
24411         PR lto/79061
24412         * asan.c (get_translation_unit_decl): Remove function.
24413         (asan_add_global): Force has_dynamic_init to zero in LTO mode.
24415 2017-01-30  Martin Liska  <mliska@suse.cz>
24417         PR gcov-profile/79259
24418         * opts.c (common_handle_option): Enable flag_ipa_bit_cp w/
24419         -fprofile-generate.
24421 2017-01-30  Martin Liska  <mliska@suse.cz>
24423         PR bootstrap/78985
24424         * config/aarch64/cortex-a57-fma-steering.c (func_fma_steering::analyze):
24425         Initialize variables with NULL value.
24427 2017-01-30  Richard Earnshaw  <rearnsh@arm.com>
24429         PR target/79260
24430         * config.gcc (arm*-*-*): Add arm/arm-flags.h and arm/arm-isa.h to
24431         tm_p_file.
24432         * arm/arm-protos.h: Don't directly include arm-flags.h and arm-isa.h.
24434 2017-01-30  Richard Biener  <rguenther@suse.de>
24436         PR tree-optimization/79276
24437         * tree-vrp.c (process_assert_insertions): Properly adjust common
24438         when removing a duplicate.
24440         * gcc.dg/torture/pr79276.c: New testcase.
24442 2017-01-30  Richard Biener  <rguenther@suse.de>
24444         PR tree-optimization/79256
24445         * targhooks.c (default_builtin_vector_alignment_reachable): Honor
24446         BIGGEST_FIELD_ALIGNMENT and ADJUST_FIELD_ALIGN to fix up bogus
24447         alignment on TYPE.
24448         * tree.c (build_aligned_type): Set TYPE_USER_ALIGN.
24450 2017-01-30  Dominik Vogt  <vogt@linux.vnet.ibm.com>
24452         PR target/79240
24453         * config/s390/s390.md ("*r<noxa>sbg_<mode>_srl_bitmask")
24454         ("*r<noxa>sbg_<mode>_sll_bitmask")
24455         ("*extzv_<mode>_srl<clobbercc_or_nocc>")
24456         ("*extzv_<mode>_sll<clobbercc_or_nocc>"):
24457         Use contiguous_bitmask_nowrap_operand.
24459 2017-01-29  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
24461         PR target/79268
24462         * config/rs6000/altivec.h (vec_xl): Revise #define.
24463         (vec_xst): Likewise.
24465 2017-01-27  Uros Bizjak  <ubizjak@gmail.com>
24467         * config/i386/i386.c (print_reg): Use REGNO instead of true_regnum.
24469 2017-01-27  Bernd Schmidt  <bschmidt@redhat.com>
24471         PR rtl-optimization/79194
24472         * cprop.c (one_cprop_pass): Move deletion of code after unconditional
24473         traps before call to bypass_conditional_jumps.
24475 2017-01-27  Vladimir Makarov  <vmakarov@redhat.com>
24477         PR tree-optimization/71374
24478         * lra-constraints.c (check_conflict_input_operands): New.
24479         (match_reload): Use it.
24481 2017-01-27  Vladimir Makarov  <vmakarov@redhat.com>
24483         PR target/79131
24484         * lra-assigns.c (find_hard_regno_for_1): Take endianess for into
24485         account to calculate conflict_set.
24487 2017-01-27  Bin Cheng  <bin.cheng@arm.com>
24489         PR rtl-optimization/78559
24490         * combine.c (try_combine): Discard REG_EQUAL and REG_EQUIV for
24491         other_insn in combine.
24493 2017-01-27  Pekka Jääskeläinen  <pekka.jaaskelainen@parmance.com>
24495         * builtin-types.def: Use unsigned_char_type_node for BT_UINT8.  Use
24496         uint16_type_node for BT_UINT16.
24498 2017-01-27  David Malcolm  <dmalcolm@redhat.com>
24500         * doc/sourcebuild.texi (Testsuites): Add "GIMPLE Tests" and
24501         "RTL Tests" to menu.
24502         (GIMPLE Tests): New node.
24503         (RTL Tests): New node.
24505 2017-01-27  Richard Biener  <rguenther@suse.de>
24507         PR tree-optimization/79245
24508         * tree-loop-distribution.c (distribute_loop): Apply cost
24509         modeling also to detected patterns.
24511 2017-01-27  Richard Biener  <rguenther@suse.de>
24513         PR tree-optimization/71433
24514         * tree-vrp.c (register_new_assert_for): Revert earlier changes.
24515         (compare_assert_loc): New function.
24516         (process_assert_insertions): Sort and optimize assert locations
24517         to remove duplicates and push down identical assertions on
24518         edges to their destination block.
24520 2017-01-27  Richard Biener  <rguenther@suse.de>
24522         PR tree-optimization/79244
24523         * tree-vrp.c (remove_range_assertions): Forcefully propagate
24524         out SSA names even if abnormal.
24526 2017-01-27  Jakub Jelinek  <jakub@redhat.com>
24528         * realmpfr.h: Poison MPFR_RND{N,Z,U,D}.
24529         * gimple-ssa-sprintf.c (format_floating_max): Use GMP_RNDN
24530         instead of MPFR_RNDN.
24532 2017-01-27  Richard Earnshaw  <rearnsha@arm.com>
24534         PR target/79239
24535         * arm.c (arm_option_override): Don't call build_target_option_node
24536         until after doing all option overrides.
24537         (arm_valid_target_attribute_tree): Likewise.
24539 2017-01-27  Martin Liska  <mliska@suse.cz>
24541         * doc/invoke.texi (-fprofile-arcs): Document profiling support
24542         for {cd}tors and C++ {cd}tors.
24544 2017-01-27  Dominik Vogt  <vogt@linux.vnet.ibm.com>
24546         * config/s390/s390.md ("*setmem_long_and")
24547         ("*setmem_long_and_31z"): Use zero_extend instead of and.
24549 2017-01-26  Martin Sebor  <msebor@redhat.com>
24551         * gimple-ssa-sprintf.c (format_floating): Simplify the computation
24552         of precision.
24554 2017-01-26  Martin Sebor  <msebor@redhat.com>
24556         * gimple-ssa-sprintf.c (format_floating): Test HAVE_XFmode and
24557         HAVE_DFmode before using XFmode or DFmode.
24558         (parse_directive): Avoid using the z length modifier to avoid
24559         the ISO C++98 does not support the â€˜z’ gnu_printf length modifier.
24561         PR middle-end/78703
24562         * gimple-ssa-sprintf.c (adjust_for_width_or_precision): Change
24563         to accept adjustment as an array.
24564         (get_int_range): New function.
24565         (struct directive): Make width and prec arrays.
24566         (directive::set_width, directive::set_precision): Call get_int_range.
24567         (format_integer, format_floating): Handle width and precision ranges.
24568         (format_string, parse_directive): Same.
24570 2017-01-26  Jakub Jelinek  <jakub@redhat.com>
24572         PR debug/79129
24573         * dwarf2out.c (generate_skeleton_bottom_up): For children with
24574         comdat_type_p set, just clone them, but keep the children in the
24575         original DIE.
24577         PR debug/78835
24578         * dwarf2out.c (prune_unused_types): Mark all functions with DIEs
24579         which have direct callers with -fvar-tracking-assignments enabled
24580         in the current TU.
24581         (resolve_addr): Avoid adding skeleton DIEs for DW_AT_call_origin
24582         inside of type units.
24584 2017-01-26  Martin Sebor  <msebor@redhat.com>
24586         PR middle-end/78703
24587         * gimple-ssa-sprintf.c (struct result_range): Add likely and
24588         unlikely counters.
24589         (struct format_result): Replace number_chars, number_chars_min,
24590         and number_chars_max with a single member of struct result_range.
24591         Remove bounded.
24592         (format_result::operator+=): Adjust.
24593         (struct fmtresult): Remove bounded.  Handle likely and unlikely
24594         counters.
24595         (fmtresult::adjust_for_width_or_precision): New function.
24596         (fmtresult:type_max_digits): New function.
24597         (bytes_remaining): Handle likely and unlikely counters.
24598         (min_bytes_remaining): Remove.
24599         (format_percent): Simplify.
24600         (format_integer, format_floating): Set likely and unlikely counters.
24601         (get_string_length, format_character, format_string): Same.
24602         (format_plain, should_warn_p): New function.
24603         (maybe_warn): Call should_warn_p.  Update diagnostic messages
24604         and handle those for all directives, including plain strings.
24605         (format_directive): Handle likely and unlikely counters.
24606         Remove unnecessary quoting from diagnostics.  Add an informational
24607         note.
24608         (add_bytes): Remove.
24609         (pass_sprintf_length::compute_format_length): Simplify.
24610         (try_substitute_return_value): Handle likely and unlikely counters.
24612 2017-01-26  Carl Love  <cel@us.ibm.com>
24614         * config/rs6000/rs6000-c (altivec_overloaded_builtins): Remove
24615         bogus entries for the P8V_BUILTIN_VEC_VGBBD built-ins
24617 2017-01-26  Vladimir Makarov  <vmakarov@redhat.com>
24619         PR target/79131
24620         * lra-assigns.c (setup_live_pseudos_and_spill_after_risky): Take
24621         endianess for subregs into account.
24622         * lra-constraints.c (lra_constraints): Do risky transformations
24623         always on the first iteration.
24624         * lra-lives.c (check_pseudos_live_through_calls): Add arg
24625         last_call_used_reg_set.
24626         (process_bb_lives): Define and use last_call_used_reg_set.
24627         * lra.c (lra): Always continue after lra_constraints on the first
24628         iteration.
24630 2017-01-26  Kirill Yukhin  <kirill.yukhin@gmail.com>
24632         * gcc.target/i386/avx512bw-kshiftlq-2.c: Use unsigned long long
24633         constant.
24634         * gcc.target/i386/avx512bw-kshiftrq-2.c: Ditto.
24636 2017-01-26  Jakub Jelinek  <jakub@redhat.com>
24638         * config/i386/avx512fintrin.h (_ktest_mask16_u8,
24639         _ktestz_mask16_u8, _ktestc_mask16_u8, _kadd_mask16): Move to ...
24640         * config/i386/avx512dqintrin.h (_ktest_mask16_u8,
24641         _ktestz_mask16_u8, _ktestc_mask16_u8, _kadd_mask16): ... here.
24642         * config/i386/i386-builtin.def (__builtin_ia32_ktestchi,
24643         __builtin_ia32_ktestzhi, __builtin_ia32_kaddhi): Use
24644         OPTION_MASK_ISA_AVX512DQ instead of OPTION_MASK_ISA_AVX512F.
24645         * config/i386/sse.md (SWI1248_AVX512BWDQ2): New mode iterator.
24646         (kadd<mode>, ktest<mode>): Use it instead of SWI1248_AVX512BWDQ.
24648 2017-01-26  Marek Polacek  <polacek@redhat.com>
24650         PR c/79199
24651         * fold-const.c (operand_equal_p) [COND_EXPR]: Use OP_SAME_WITH_NULL
24652         for the third operand.
24654 2017-01-26  Jakub Jelinek  <jakub@redhat.com>
24656         PR middle-end/79236
24657         * omp-low.c (struct omp_context): Add simt_stmt field.
24658         (scan_omp_for): Return omp_context *.
24659         (scan_omp_simd): Set simt_stmt on the non-_simt_ SIMD
24660         context to the _simt_ SIMD stmt.
24661         (lower_omp_for): For combined SIMD with sibling _simt_
24662         SIMD, make sure to use the same decls in _looptemp_
24663         clauses as in the sibling.
24665 2017-01-26  David Sherwood  <david.sherwood@arm.com>
24667         PR middle-end/79212
24668         * gimplify.c (omp_notice_variable): Add GOVD_SEEN flag to variables in
24669         all contexts.
24671 2017-01-26  Jakub Jelinek  <jakub@redhat.com>
24673         PR target/70465
24674         * reg-stack.c (emit_swap_insn): Instead of fld a; fld b; fxchg %st(1);
24675         emit fld b; fld a; if possible.
24677         * brig-builtins.def: Update copyright years.
24678         * config/arm/arm_acle_builtins.def: Update copyright years.
24680 2017-01-25  Michael Meissner  <meissner@linux.vnet.ibm.com>
24682         PR target/79179
24683         * config/rs6000/vsx.md (vsx_extract_<mode>_store): Use wY
24684         constraint instead of o for the stxsd instruction.
24686 2017-01-25  Carl Love  <cel@us.ibm.com>
24688         * config/rs6000/rs6000-c (altivec_overloaded_builtins): Fix order
24689         of entries for ALTIVEC_BUILTIN_VEC_PACKS and P8V_BUILTIN_VEC_VGBBD.
24691 2017-01-25  Jonathan Wakely  <jwakely@redhat.com>
24693         * doc/invoke.texi (C++ Dialect Options): Fix typo.
24695 2017-01-25  Richard Biener  <rguenther@suse.de>
24697         PR tree-optimization/69264
24698         * target.def (vector_alignment_reachable): Improve documentation.
24699         * doc/tm.texi: Regenerate.
24700         * targhooks.c (default_builtin_vector_alignment_reachable): Simplify
24701         and add a comment.
24702         * tree-vect-data-refs.c (vect_supportable_dr_alignment): Revert
24703         earlier changes with respect to TYPE_USER_ALIGN.
24704         (vector_alignment_reachable_p): Likewise.  Improve dumping.
24706 2016-01-25  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
24708         PR target/79145
24709         * config/arm/arm.md (xordi3): Force constant operand into a register
24710         for TARGET_IWMMXT.
24712 2016-01-25  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
24714         * doc/invoke.texi (-fstore-merging): Correct default optimization
24715         levels at which it is enabled.
24716         (-O): Move -fstore-merging from list to...
24717         (-O2): ... Here.
24719 2017-01-25  Richard Biener  <rguenther@suse.de>
24721         PR debug/78363
24722         * omp-expand.c: Include debug.h.
24723         (expand_omp_taskreg): Make sure to generate early debug before
24724         outlining anything from a function.
24725         (expand_omp_target): Likewise.
24726         (grid_expand_target_grid_body): Likewise.
24728 2017-01-25  Maxim Ostapenko  <m.ostapenko@samsung.com>
24730         PR lto/79061
24731         * asan.c (get_translation_unit_decl): New function.
24732         (asan_add_global): Extract modules file name from globals
24733         TRANSLATION_UNIT_DECL name.
24735 2017-01-24  Eric Botcazou  <ebotcazou@adacore.com>
24737         PR target/77439
24738         * config/arm/arm.c (arm_function_ok_for_sibcall): Add back restriction
24739         for long calls with APCS frame and VFP.
24741 2017-01-24  David Malcolm  <dmalcolm@redhat.com>
24743         * cfg.c (original_copy_tables_initialized_p): New function.
24744         * cfg.h (original_copy_tables_initialized_p): New decl.
24745         * cfgrtl.c (relink_block_chain): Guard the call to
24746         free_original_copy_tables with a call to
24747         original_copy_tables_initialized_p.
24748         * cgraph.h (symtab_node::native_rtl_p): New decl.
24749         * cgraphunit.c (symtab_node::native_rtl_p): New function.
24750         (symtab_node::needed_p): Don't assert for early assembly output
24751         for __RTL functions.
24752         (cgraph_node::finalize_function): Set "force_output" for __RTL
24753         functions.
24754         (cgraph_node::analyze): Bail out early for __RTL functions.
24755         (analyze_functions): Update assertion to support __RTL functions.
24756         (cgraph_node::expand): Bail out early for __RTL functions.
24757         * final.c (rest_of_clean_state): Don't call delete_tree_ssa for
24758         __RTL functions.
24759         * function.h (struct function): Update comment for field
24760         "pass_startwith".
24761         * gimple-expr.c: Include "tree-pass.h".
24762         (gimple_has_body_p): Return false for __RTL functions.
24763         * Makefile.in (OBJS): Add run-rtl-passes.o.
24764         * pass_manager.h (gcc::pass_manager::get_rest_of_compilation): New
24765         accessor.
24766         (gcc::pass_manager::get_clean_slate): New accessor.
24767         * passes.c: Include "insn-addr.h".
24768         (should_skip_pass_p): Add logging.  Update logic for running
24769         "expand" to be compatible with both __GIMPLE and __RTL.  Guard
24770         property-provider override so it is only done for gimple passes.
24771         Don't skip dfinit.
24772         (skip_pass): New function.
24773         (execute_one_pass): Call skip_pass when skipping passes.
24774         * read-md.c (md_reader::read_char): Support filtering
24775         the input to a subset of line numbers.
24776         (md_reader::md_reader): Initialize fields
24777         m_first_line and m_last_line.
24778         (md_reader::read_file_fragment): New function.
24779         * read-md.h (md_reader::read_file_fragment): New decl.
24780         (md_reader::m_first_line): New field.
24781         (md_reader::m_last_line): New field.
24782         * read-rtl-function.c (function_reader::create_function): Only
24783         create cfun if it doesn't already exist.  Set PROP_rtl on cfun's
24784         curr_properties.  Set DECL_INITIAL to a dummy block.
24785         (read_rtl_function_body_from_file_range): New function.
24786         * read-rtl-function.h (read_rtl_function_body_from_file_range):
24787         New decl.
24788         * run-rtl-passes.c: New file.
24789         * run-rtl-passes.h: New file.
24791 2017-01-24  Jeff Law  <law@redhat.com>
24793         * config/microblaze/microblaze.h (ASM_FORMAT_PRIVATE_NAME): Increase
24794         buffer size.
24796 2017-01-24  Bin Cheng  <bin.cheng@arm.com>
24798         PR tree-optimization/79159
24799         * tree-ssa-loop-niter.c (get_cst_init_from_scev): New function.
24800         (record_nonwrapping_iv): Improve boundary using above function if no
24801         value range information.
24803 2017-01-24  Pekka Jääskeläinen  <pekka@parmance.com>
24804             Martin Jambor  <mjambor@suse.cz>
24806         * brig-builtins.def: New file.
24807         * builtins.def (DEF_HSAIL_BUILTIN): New macro.
24808         (DEF_HSAIL_ATOMIC_BUILTIN): Likewise.
24809         (DEF_HSAIL_SAT_BUILTIN): Likewise.
24810         (DEF_HSAIL_INTR_BUILTIN): Likewise.
24811         (DEF_HSAIL_CVT_ZEROI_SAT_BUILTIN): Likewise.
24812         * builtin-types.def (BT_INT8): New.
24813         (BT_INT16): Likewise.
24814         (BT_UINT8): Likewise.
24815         (BT_UINT16): Likewise.
24816         (BT_FN_ULONG): Likewise.
24817         (BT_FN_UINT_INT): Likewise.
24818         (BT_FN_UINT_ULONG): Likewise.
24819         (BT_FN_UINT_LONG): Likewise.
24820         (BT_FN_UINT_PTR): Likewise.
24821         (BT_FN_ULONG_PTR): Likewise.
24822         (BT_FN_INT8_FLOAT): Likewise.
24823         (BT_FN_INT16_FLOAT): Likewise.
24824         (BT_FN_UINT32_FLOAT): Likewise.
24825         (BT_FN_UINT16_FLOAT): Likewise.
24826         (BT_FN_UINT8_FLOAT): Likewise.
24827         (BT_FN_UINT64_FLOAT): Likewise.
24828         (BT_FN_UINT16_UINT32): Likewise.
24829         (BT_FN_UINT32_UINT16): Likewise.
24830         (BT_FN_UINT16_UINT16_UINT16): Likewise.
24831         (BT_FN_INT_PTR_INT): Likewise.
24832         (BT_FN_UINT_PTR_UINT): Likewise.
24833         (BT_FN_LONG_PTR_LONG): Likewise.
24834         (BT_FN_ULONG_PTR_ULONG): Likewise.
24835         (BT_FN_VOID_UINT64_UINT64): Likewise.
24836         (BT_FN_UINT8_UINT8_UINT8): Likewise.
24837         (BT_FN_INT8_INT8_INT8): Likewise.
24838         (BT_FN_INT16_INT16_INT16): Likewise.
24839         (BT_FN_INT_INT_INT): Likewise.
24840         (BT_FN_UINT_FLOAT_UINT): Likewise.
24841         (BT_FN_FLOAT_UINT_UINT): Likewise.
24842         (BT_FN_ULONG_UINT_UINT): Likewise.
24843         (BT_FN_ULONG_UINT_PTR): Likewise.
24844         (BT_FN_ULONG_ULONG_ULONG): Likewise.
24845         (BT_FN_UINT_UINT_UINT): Likewise.
24846         (BT_FN_VOID_UINT_PTR): Likewise.
24847         (BT_FN_UINT_UINT_PTR: Likewise.
24848         (BT_FN_UINT32_UINT64_PTR): Likewise.
24849         (BT_FN_INT_INT_UINT_UINT): Likewise.
24850         (BT_FN_UINT_UINT_UINT_UINT): Likewise.
24851         (BT_FN_UINT_UINT_UINT_PTR): Likewise.
24852         (BT_FN_UINT_ULONG_ULONG_UINT): Likewise.
24853         (BT_FN_ULONG_ULONG_ULONG_ULONG): Likewise.
24854         (BT_FN_LONG_LONG_UINT_UINT): Likewise.
24855         (BT_FN_ULONG_ULONG_UINT_UINT): Likewise.
24856         (BT_FN_VOID_UINT32_UINT64_PTR): Likewise.
24857         (BT_FN_VOID_UINT32_UINT32_PTR): Likewise.
24858         (BT_FN_UINT_UINT_UINT_UINT_UINT): Likewise.
24859         (BT_FN_UINT_FLOAT_FLOAT_FLOAT_FLOAT): Likewise.
24860         (BT_FN_ULONG_ULONG_ULONG_UINT_UINT): Likewise.
24861         * doc/frontends.texi: List BRIG FE.
24862         * doc/install.texi (Testing): Add BRIG tesring requirements.
24863         * doc/invoke.texi (Overall Options): Mention BRIG.
24864         * doc/standards.texi (Standards): Doucment BRIG HSA version.
24866 2017-01-24  Richard Biener  <rguenther@suse.de>
24868         PR translation/79208
24869         * ipa-devirt.c (odr_types_equivalent_p): Fix typo in diagnostic.
24871 2017-01-24  Martin Jambor  <mjambor@suse.cz>
24873         PR bootstrap/79198
24874         * ipa-prop.c (ipa_free_all_node_params): Call summary destructor.
24875         * ipa-prop.c (ipa_node_params_t::insert): Initialize fields known_csts
24876         and known_contexts.
24878 2017-01-24  Aldy Hernandez  <aldyh@redhat.com>
24880         PR middle-end/79123
24881         * gimple-ssa-warn-alloca.c (alloca_call_type): Make sure
24882         casts from signed to unsigned really don't have a range.
24884 2017-01-24  Markus Trippelsdorf  <markus@trippelsdorf.de>
24886         * gimple-ssa-sprintf.c (format_floating): Change MPFR_RNDx to
24887         GMP_RNDx for compatiblity.
24889 2017-01-24  Martin Liska  <mliska@suse.cz>
24891         PR bootstrap/79132
24892         * tree-ssa-reassoc.c (rewrite_expr_tree_parallel): Insert assert
24893         that would prevent us to call alloca with -1 as argument.
24895 2017-01-24  Jakub Jelinek  <jakub@redhat.com>
24897         * dwarf2out.c (output_compilation_unit_header, output_file_names):
24898         Avoid -Wformat-security warning.
24900 2017-01-23  Andrew Pinski  <apinski@cavium.com>
24902         * config/aarch64/aarch64.c (thunderx2t99_addrcost_table): Improve
24903         cost table.
24905 2017-01-23  Martin Sebor  <msebor@redhat.com>
24907         PR middle-end/78703
24908         * gimple-ssa-sprintf.c (warn_level): New global.
24909         (format_integer): Use it here and throughout the rest of the file.
24910         Use the same switch to compute sign as base.
24911         (maybe_warn): New function.
24912         (format_directive): Factor out warnings into maybe_warn.
24913         Add debugging output.  Use warn_level.
24914         (add_bytes): Use warn_level.
24915         (pass_sprintf_length::compute_format_length): Add debugging output.
24916         (try_substitute_return_value): Same.
24917         (pass_sprintf_length::handle_gimple_call): Set and use warn_level.
24919         PR middle-end/78703
24920         * gimple-ssa-sprintf.c (struct format_result): Remove constant member.
24921         (struct fmtresult, format_integer, format_floating): Adjust.
24922         (fmtresult::fmtresult): Set max correctly in two argument ctor.
24923         (get_string_length, format_string,format_directive): Same.
24924         (pass_sprintf_length::compute_format_length): Same.
24925         (try_substitute_return_value): Simplify slightly.
24927         PR middle-end/78703
24928         * gimple-ssa-sprintf.c (pass_sprintf_length::gate): Adjust formatting.
24929         (fmtresult::operator+=): Outlined.
24930         (struct fmtresult): Add ctors.
24931         (struct conversion_spec): Rename...
24932         (struct directive): ...to this.  Add and remove data members.
24933         (directive::set_width, directive::set_precision): New functions.
24934         (format_percent): Use fmtresult ctor.
24935         (get_width_and_precision): Remove.
24936         (format_integer): Make naming changes.  Avoid computing width and
24937         precision.
24938         (format_floating): Same.  Adjust indentation.
24939         (format_character, format_none): New functions.
24940         (format_string): Moved character handling to format_character.
24941         (format_directive): Remove arguments, change return type.
24942         (parse_directive): New function.
24943         (pass_sprintf_length::compute_format_length): Move directive
24944         parsing to parse_directive.
24946 2017-01-23  Jakub Jelinek  <jakub@redhat.com>
24948         * tree.h (assign_assembler_name_if_neeeded): Rename to ...
24949         (assign_assembler_name_if_needed): ... this.
24950         * tree.c (assign_assembler_name_if_neeeded): Rename to ...
24951         (assign_assembler_name_if_needed): ... this.
24952         (free_lang_data_in_cgraph): Adjust callers.
24953         * cgraphunit.c (cgraph_node::analyze): Likewise.
24954         * omp-expand.c (expand_omp_taskreg, expand_omp_target):
24955         Likewise.
24957 2017-01-23  Richard Biener  <rguenther@suse.de>
24959         PR tree-optimization/79088
24960         PR tree-optimization/79188
24961         * tree-ssa-threadupdate.c (mark_threaded_blocks): Move code
24962         resetting loop bounds after last path deletion.  Reset loop
24963         bounds of the target loop, make code match the comments.
24964         * tree-ssa-threadbackwards.c (pass_early_thread_jumps::execute):
24965         Make sure loops need no fixups.
24967 2017-01-23  Kelvin Nilsen  <kelvin@gcc.gnu.org>
24969         * config/rs6000/rs6000-builtin.def (VSIEDPF): Add scalar insert
24970         exponent support with double type for first argument.
24971         * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Changed
24972         type returned by __builtin_vec_extract_sig,
24973         __builtin_vec_extract_sig_sp, and __builtin_vec_extract_sig_dp
24974         functions from "vector int" to "vector unsigned int" or from
24975         "vector long long int" to "vector unsigned long long int".
24976         Changed type returned by __builtin_vec_extract_exp,
24977         __builtin_vec_extract_exp_sp, and __builtin_vec_extract_exp_dp
24978         functions from "vector int" to "vector unsigned int" or from
24979         "vector long long int" to "vector unsigned long long int".
24980         Changed return type of __builtin_vec_test_data_class,
24981         __builtin_vec_test_data_class_sp, and
24982         __builtin_vec_test_data_class_dp from "vector int" to
24983         "vector bool int" or from "vector long long int" to "vector bool
24984         long long int" and changed second argument type from "unsigned
24985         int" to "int".  Added new overloaded function forms "vector float
24986         __builtin_vec_insert_exp (vector float, vector unsigned int)" and
24987         "vector float __builtin_vec_insert_exp_sp (vector float, vector
24988         unsigned int)" and "vector double __builtin_vec_insert_exp (vector
24989         double, vector unsigned long long int)" and "vector double
24990         __builtin_vec_insert_exp_dp (vector double, vector unsigned long
24991         long int)".  Changed return type of
24992         __builtin_scalar_test_data_class and
24993         __builtin_scalar_test_data_class_sp and
24994         __builtin_scalar_test_data_class_dp from "unsigned int" to "bool
24995         int" and changed second argument from "unsigned int" to "int".
24996         Changed type returned by __builtin_scalar_test_neg,
24997         __builtin_scalar_test_neg_sp, and __builtin_scalar_test_neg_dp
24998         from "int" to "bool int".  Added new overloaded function form
24999         "double __builtin_scalar_insert_exp (double, unsigned long long int)".
25000         * config/rs6000/vsx.md (xsiexpdpf): New insn for scalar insert
25001         exponent double-precision with floating point first argument.
25002         * doc/extend.texi (PowerPC AltiVec Built-in Functions): Adjust
25003         documentation of scalar_test_data_class, scalar_test_neg,
25004         scalar_extract_sig, scalar_extract_exp, scalar_insert_exp,
25005         vector_extract_exp, vec_extract_sig, vec_insert_exp, and
25006         vec_test_data_class built-in functions to reflect refinements in
25007         their type signatures.
25009 2017-01-23  Andreas Tobler  <andreast@gcc.gnu.org>
25011         * config/aarch64/aarch64.c (aarch64_elf_asm_constructor): Increase
25012         size of buf.
25013         (aarch64_elf_asm_destructor): Likewise.
25015 2017-01-23  Bernd Schmidt  <bschmidt@redhat.com>
25017         PR rtl-optimization/78634
25018         * config/i386/i386.c (ix86_max_noce_ifcvt_seq_cost): New function.
25019         (TARGET_MAX_NOCE_IFCVT_SEQ_COST): Define.
25020         * ifcvt.c (noce_try_cmove): Add missing cost check.
25022         PR rtl-optimization/71724
25023         * combine.c (if_then_else_cond): Look for situations where it is
25024         beneficial to undo the work of one of the recursive calls.
25026 2017-01-23  Bin Cheng  <bin.cheng@arm.com>
25028         PR tree-optimization/70754
25029         * tree-predcom.c (stmt_combining_refs): New parameter INSERT_BEFORE.
25030         (reassociate_to_the_same_stmt): New parameter INSERT_BEFORE.  Insert
25031         combined stmt before it if not NULL.
25032         (combine_chains): Process refs reversely and compute dominance point
25033         for root ref.
25035 2017-01-23  Martin Liska  <mliska@suse.cz>
25037         PR tree-optimization/79196
25038         * tree-ssa-strlen.c (fold_strstr_to_memcmp): Rename to ...
25039         (fold_strstr_to_strncmp): ... this.  Fold the pattern to strncmp
25040         instead of memcmp.
25041         (strlen_optimize_stmt): Call the renamed function.
25043 2017-01-23  Michael Matz  <matz@suse.de>
25045         PR tree-optimization/78384
25046         * tree-ssa-loop-split.c (patch_loop_exit): Use correct edge.
25048 2017-01-23  Richard Biener  <rguenther@suse.de>
25050         PR tree-optimization/79186
25051         * tree-vrp.c (register_new_assert_for): Make sure we've seen
25052         both incoming edges before moving an assert.
25054 2017-01-23  Martin Jambor  <mjambor@suse.cz>
25056         * ipa-prop.c (load_from_param_1): Removed.
25057         (load_from_unmodified_param): Bits from load_from_param_1 put back
25058         here.
25059         (load_from_param): Removed.
25060         (compute_complex_assign_jump_func): Removed stmt2 and just replaced it
25061         with stmt.  Reverted back to use of load_from_unmodified_param.
25063 2017-01-23  Martin Jambor  <mjambor@suse.cz>
25065         PR ipa/79108
25066         * ipa-prop.h (ipa_param_descriptor): Anotate with with GTY(()).
25067         (ipa_node_params): Annotate with GTY((for_user)).  Make descriptors
25068         field a pointer to garbage collected vector, mark lattices and
25069         ipcp_orig_node with GTY((skip)).
25070         (ipa_get_param_count): Adjust to descriptors being a pointer.
25071         (ipa_get_param): Likewise.
25072         (ipa_get_type): Likewise.
25073         (ipa_get_param_move_cost): Likewise.
25074         (ipa_set_param_used): Likewise.
25075         (ipa_get_controlled_uses): Likewise.
25076         (ipa_set_controlled_uses): Likewise.
25077         (ipa_is_param_used): Likewise.
25078         (ipa_node_params_t): Move into garbage collector.  New methods insert
25079         and remove.
25080         (ipa_node_params_sum): Annotate wth GTY(()).
25081         (ipa_check_create_node_params): Adjust to ipa_node_params_sum being
25082         garbage collected.
25083         (ipa_load_from_parm_agg): Adjust declaration.
25084         * ipa-icf.c (param_used_p): Adjust to descriptors being a pointer.
25085         * ipa-profile.c (ipa_profile): Likewise.
25086         * ipa-prop.c (ipa_get_param_decl_index_1): Likewise.
25087         (ipa_populate_param_decls): Make descriptors parameter garbage
25088         collected.
25089         (ipa_dump_param): Adjust to descriptors being a pointer.
25090         (ipa_alloc_node_params): Likewise.
25091         (ipa_initialize_node_params): Likewise.
25092         (load_from_param_1): Make descriptors parameter garbage collected.
25093         (load_from_unmodified_param): Likewise.
25094         (load_from_param): Likewise.
25095         (ipa_load_from_parm_agg): Likewise.
25096         (ipa_node_params::~ipa_node_params): Removed.
25097         (ipa_free_all_node_params): Remove call to delete operator.
25098         (ipa_node_params_t::insert): New.
25099         (ipa_node_params_t::remove): Likewise.
25100         (ipa_node_params_t::duplicate): Adjust to descriptors being a pointer,
25101         copy known_csts and known_contexts vectors.
25102         (ipa_read_node_info): Adjust to descriptors being a pointer.
25103         (ipcp_modif_dom_walker): Make m_descriptors field garbage
25104         collected.
25105         (ipcp_transform_function): Make descriptors variable garbage
25106         collected.
25108 2017-01-23  Andrew Senkevich  <andrew.senkevich@intel.com>
25110         * config/i386/avx512bwintrin.h: Add k-mask test, kortest intrinsics.
25111         * config/i386/avx512dqintrin.h: Ditto.
25112         * config/i386/avx512fintrin.h: Ditto.
25113         * config/i386/i386.c: Handle new builtins.
25114         * config/i386/i386-builtin.def: Add new builtins.
25115         * config/i386/sse.md (ktest<mode>, kortest<mode>): New.
25116         (UNSPEC_KORTEST, UNSPEC_KTEST): New.
25118 2017-01-23  Jakub Jelinek  <jakub@redhat.com>
25119             Martin Liska  <mliska@suse.cz>
25121         * asan.h: Define ASAN_USE_AFTER_SCOPE_ATTRIBUTE.
25122         * asan.c (asan_expand_poison_ifn): Support stores and use
25123         appropriate ASAN report function.
25124         * internal-fn.c (expand_ASAN_POISON_USE): New function.
25125         * internal-fn.def (ASAN_POISON_USE): Declare.
25126         * tree-into-ssa.c (maybe_add_asan_poison_write): New function.
25127         (maybe_register_def): Create ASAN_POISON_USE when sanitizing.
25128         * tree-ssa-dce.c (eliminate_unnecessary_stmts): Remove
25129         ASAN_POISON calls w/o LHS.
25130         * tree-ssa.c (execute_update_addresses_taken): Create clobber
25131         for ASAN_MARK (UNPOISON, &x, ...) in order to prevent usage of a LHS
25132         from ASAN_MARK (POISON, &x, ...) coming to a PHI node.
25133         * gimplify.c (asan_poison_variables): Add attribute
25134         use_after_scope_memory to variables that really needs to live
25135         in memory.
25136         * tree-ssa.c (is_asan_mark_p): Do not rewrite into SSA when
25137         having the attribute.
25139 2017-01-23  Martin Liska  <mliska@suse.cz>
25141         * asan.c (create_asan_shadow_var): New function.
25142         (asan_expand_poison_ifn): Likewise.
25143         * asan.h (asan_expand_poison_ifn): New declaration.
25144         * internal-fn.c (expand_ASAN_POISON): Likewise.
25145         * internal-fn.def (ASAN_POISON): New builtin.
25146         * sanopt.c (pass_sanopt::execute): Expand
25147         asan_expand_poison_ifn.
25148         * tree-inline.c (copy_decl_for_dup_finish): Make function
25149         external.
25150         * tree-inline.h (copy_decl_for_dup_finish): Likewise.
25151         * tree-ssa.c (is_asan_mark_p): New function.
25152         (execute_update_addresses_taken): Rewrite local variables
25153         (identified just by use-after-scope as addressable) into SSA.
25155 2017-01-22  Gerald Pfeifer  <gerald@pfeifer.com>
25157         * doc/install.texi (Specific): opensource.apple.com uses https
25158         now. Remove trailing slash.
25160 2017-01-22  Gerald Pfeifer  <gerald@pfeifer.com>
25162         * README.Portability: Remove note on an Irix compatibility issue.
25164 2017-01-22  Dimitry Andric <dim@FreeBSD.org>
25166         * gcov.c (INCLUDE_ALGORITHM): Define.
25167         (INCLUDE_VECTOR): Define.
25168         No longer include <vector> and <algorithm> directly.
25170 2017-01-21  Gerald Pfeifer  <gerald@pfeifer.com>
25172         * doc/extend.texi (Thread-Local): Change www.akkadia.org reference
25173         to https.
25174         * doc/invoke.texi (Code Gen Options): Ditto.
25176 2017-01-21  Jan Hubicka  <hubicka@ucw.cz>
25178         PR lto/78407
25179         * cfg.c (update_bb_profile_for_threading): Fix updating of probablity.
25181 2017-01-21  Bernd Schmidt  <bschmidt@redhat.com>
25183         rtl-optimization/79125
25184         * cprop.c (local_cprop_pass): Handle cases where we make an
25185         unconditional trap.
25187 2017-01-20  Segher Boessenkool  <segher@kernel.crashing.org>
25189         PR target/61729
25190         PR target/77850
25191         * config/rs6000/rs6000.c (rs6000_gimplify_va_arg): Adjust address to
25192         read from, for big endian.
25194 2017-01-20  Jiong Wang  <jiong.wang@arm.com>
25196         * config/aarch64/aarch64-builtins.c (aarch64_init_builtins): Register
25197         register pauth builtins for LP64 only.
25199 2017-01-20  Marek Polacek  <polacek@redhat.com>
25201         PR c/79152
25202         * gimplify.c (should_warn_for_implicit_fallthrough): Handle consecutive
25203         non-case labels.
25205 2017-01-20  Alexander Monakov  <amonakov@ispras.ru>
25207         * omp-expand.c (expand_omp_simd): Clear PROP_gimple_lomp_dev regardless
25208         of safelen status.
25209         * omp-offload.c (pass_omp_device_lower::gate): Use PROP_gimple_lomp_dev.
25210         * passes.c (dump_properties): Handle PROP_gimple_lomp_dev.
25211         * tree-inline.c (expand_call_inline): Propagate PROP_gimple_lomp_dev.
25213 2017-01-20  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
25215         PR target/71270
25216         * config/arm/arm.c (neon_valid_immediate): Reject vector constants
25217         in big-endian mode when they are not a single duplicated value.
25219 2017-01-20  Richard Biener  <rguenther@suse.de>
25221         * BASE-VER: Bump to 7.0.1.
25223 2017-01-20  Alexander Monakov  <amonakov@ispras.ru>
25225         * omp-low.c (omplow_simd_context): New struct.  Use it...
25226         (lower_rec_simd_input_clauses): ...here and...
25227         (lower_rec_input_clauses): ...here to hold common data.  Adjust all
25228         references to idx, lane, max_vf, is_simt.
25230 2017-01-20  Graham Markall  <graham.markall@embecosm.com>
25232         * config/arc/arc.h (LINK_SPEC): Use arclinux_nps emulation when
25233         mcpu=nps400.
25235 2017-01-20  Martin Jambor  <mjambor@suse.cz>
25237         * hsa.h: Renaed to hsa-common.h.  Adjusted a comment.
25238         * hsa.c: Renaed to hsa-common.c.  Change include of gt-hsa.h to
25239         gt-hsa-common.h.
25240         * Makefile.in (OBJS): Rename hsa.o to hsa-common.o.
25241         (GTFILES): Rename hsa.c to hsa-common.c.
25242         * hsa-brig.c: Change include of hsa.h to hsa-common.h.
25243         * hsa-dump.c: Likewise.
25244         * hsa-gen.c: Likewise.
25245         * hsa-regalloc.c: Likewise.
25246         * ipa-hsa.c: Likewise.
25247         * omp-expand.c: Likewise.
25248         * omp-low.c: Likewise.
25249         * toplev.c: Likewise.
25251 2017-01-20  Marek Polacek  <polacek@redhat.com>
25253         PR c/64279
25254         * doc/invoke.texi: Document -Wduplicated-branches.
25255         * fold-const.c (operand_equal_p): Handle MODIFY_EXPR, INIT_EXPR,
25256         COMPOUND_EXPR, PREDECREMENT_EXPR, PREINCREMENT_EXPR,
25257         POSTDECREMENT_EXPR, POSTINCREMENT_EXPR, CLEANUP_POINT_EXPR, EXPR_STMT,
25258         STATEMENT_LIST, and RETURN_EXPR.  For non-pure non-const functions
25259         return 0 only when not OEP_LEXICOGRAPHIC.
25260         (fold_build_cleanup_point_expr): Use the expression
25261         location when building CLEANUP_POINT_EXPR.
25262         * tree-core.h (enum operand_equal_flag): Add OEP_LEXICOGRAPHIC.
25263         * tree.c (add_expr): Handle error_mark_node.
25265 2017-01-20  Martin Liska  <mliska@suse.cz>
25267         PR lto/69188
25268         * tree-profile.c (init_ic_make_global_vars): Do not call
25269         finalize_decl.
25270         (gimple_init_gcov_profiler): Likewise.
25272 2017-01-20  Martin Liska  <mliska@suse.cz>
25274         PR ipa/71190
25275         * cgraph.h (maybe_create_reference): Remove argument and
25276         update comment.
25277         * cgraphclones.c (cgraph_node::create_virtual_clone): Remove one
25278         argument.
25279         * ipa-cp.c (create_specialized_node): Likewise.
25280         * symtab.c (symtab_node::maybe_create_reference): Handle
25281         VAR_DECLs and ADDR_EXPRs and select ipa_ref_use type.
25283 2017-01-20  Martin Liska  <mliska@suse.cz>
25285         * read-rtl-function.c (function_reader::create_function): Use
25286         build_decl instread of build_decl_stat.
25288 2017-01-20  Andrew Senkevich  <andrew.senkevich@intel.com>
25290         * config/i386/avx512bwintrin.h: Add k-mask registers shift intrinsics.
25291         * config/i386/avx512dqintrin.h: Ditto.
25292         * config/i386/avx512fintrin.h: Ditto.
25293         * config/i386/i386-builtin-types.def: Add new types.
25294         * config/i386/i386.c: Handle new types.
25295         * config/i386/i386-builtin.def (__builtin_ia32_kshiftliqi)
25296         (__builtin_ia32_kshiftlihi, __builtin_ia32_kshiftlisi)
25297         (__builtin_ia32_kshiftlidi, __builtin_ia32_kshiftriqi)
25298         (__builtin_ia32_kshiftrihi, __builtin_ia32_kshiftrisi)
25299         (__builtin_ia32_kshiftridi): New.
25300         * config/i386/sse.md (k<code><mode>): Rename *k<code><mode>.
25302 2017-01-19  Segher Boessenkool  <segher@kernel.crashing.org>
25304         PR target/78875
25305         PR target/79140
25306         * config/rs6000/rs6000.c (TARGET_STACK_PROTECT_GUARD): Unconditionally
25307         define to rs6000_init_stack_protect_guard.
25308         (rs6000_init_stack_protect_guard): New function.
25310 2017-01-19  Matthew Fortune  <matthew.fortune@imgtec.com>
25311             Yunqiang Su  <yunqiang.su@imgtec.com>
25313         * config.gcc (supported_defaults): Add madd4.
25314         (with_madd4): Add validation.
25315         (all_defaults): Add madd4.
25316         * config/mips/mips.opt (mmadd4): New option.
25317         * config/mips/mips.h (OPTION_DEFAULT_SPECS): Add a default for
25318         mmadd4.
25319         (TARGET_CPU_CPP_BUILTINS): Add builtin_define for
25320         __mips_no_madd4.
25321         (ISA_HAS_UNFUSED_MADD4): Gate with mips_madd4.
25322         (ISA_HAS_FUSED_MADD4): Likewise.
25323         * doc/invoke.texi (-mmadd4): Document the new option.
25324         * doc/install.texi (--with-madd4): Document the new option.
25326 2017-01-19  Jiong Wang  <jiong.wang@arm.com>
25328         * config/aarch64/aarch64-builtins.c (enum aarch64_builtins): New
25329         entries for AARCH64_PAUTH_BUILTIN_XPACLRI,
25330         AARCH64_PAUTH_BUILTIN_PACIA1716, AARCH64_PAUTH_BUILTIN_AUTIA1716.
25331         (aarch64_init_pauth_hint_builtins): New.
25332         (aarch64_init_builtins): Call aarch64_init_pauth_hint_builtins.
25333         (aarch64_expand_builtin): Expand new builtins.
25335 2017-01-19  Jiong Wang  <jiong.wang@arm.com>
25337         * reg-notes.def (CFA_TOGGLE_RA_MANGLE): New reg-note.
25338         * combine-stack-adj.c (no_unhandled_cfa): Handle
25339         REG_CFA_TOGGLE_RA_MANGLE.
25340         * dwarf2cfi.c (dwarf2out_frame_debug): Handle REG_CFA_TOGGLE_RA_MANGLE.
25341         * config/aarch64/aarch64.c (aarch64_expand_prologue): Generates DWARF
25342         info for return address signing.
25343         (aarch64_expand_epilogue): Likewise.
25345 2017-01-19  Jiong Wang  <jiong.wang@arm.com>
25347         * config/aarch64/aarch64-opts.h (aarch64_function_type): New enum.
25348         * config/aarch64/aarch64-protos.h
25349         (aarch64_return_address_signing_enabled): New declaration.
25350         * config/aarch64/aarch64.c (aarch64_return_address_signing_enabled):
25351         New function.
25352         (aarch64_expand_prologue): Sign return address before it's pushed onto
25353         stack.
25354         (aarch64_expand_epilogue): Authenticate return address fetched from
25355         stack.
25356         (aarch64_override_options): Sanity check for ILP32 and ISA level.
25357         (aarch64_attributes): New function attributes for "sign-return-address".
25358         * config/aarch64/aarch64.md (UNSPEC_AUTI1716, UNSPEC_AUTISP,
25359         UNSPEC_PACI1716, UNSPEC_PACISP, UNSPEC_XPACLRI): New unspecs.
25360         ("*do_return"): Generate combined instructions according to key index.
25361         ("<pauth_mnem_prefix>sp", "<pauth_mnem_prefix1716", "xpaclri"): New.
25362         * config/aarch64/iterators.md (PAUTH_LR_SP, PAUTH_17_16): New integer
25363         iterators.
25364         (pauth_mnem_prefix, pauth_hint_num_a): New integer attributes.
25365         * config/aarch64/aarch64.opt (msign-return-address=): New.
25366         * doc/extend.texi (AArch64 Function Attributes): Documents
25367         "sign-return-address=".
25368         * doc/invoke.texi (AArch64 Options): Documents "-msign-return-address=".
25370 2017-01-19  Matthew Fortune  <matthew.fortune@imgtec.com>
25372         * doc/invoke.texi: Add missing -mlxc1-sxc1 options to
25373         overall option summary.
25375 2017-01-19  Jiong Wang  <jiong.wang@arm.com>
25377         * config/aarch64/aarch64-arches.def: New entry for "armv8.3-a".
25378         * config/aarch64/aarch64.h (AARCH64_FL_V8_3, AARCH64_FL_FOR_ARCH8_3,
25379         AARCH64_ISA_V8_3, TARGET_ARMV8_3): New.
25380         * doc/invoke.texi (AArch64 Options): Document "armv8.3-a".
25382 2017-01-19  Michael Meissner  <meissner@linux.vnet.ibm.com>
25384         * config/rs6000/rs6000-cpus.def (ISA_3_0_MASKS_SERVER): Enable
25385         -mpower9-minmax by default for -mcpu=power9.
25386         (ISA_3_MASKS_IEEE): Require -mvsx-small-integer to enable IEEE
25387         128-bit floating point.
25389 2017-01-20  Alan Modra  <amodra@gmail.com>
25391         * config/rs6000/rs6000.md (cmpstrnsi, cmpstrsi): Fail if
25392         optimizing for size.
25394 2017-01-20  Alan Modra  <amodra@gmail.com>
25396         PR target/79144
25397         * config/rs6000/rs6000.c (expand_strn_compare): Get the asm name
25398         for strcmp and strncmp from corresponding builtin decl.
25400 2017-01-19  Uros Bizjak  <ubizjak@gmail.com>
25402         * config.gcc (x86_64-*-rtems*): Use i386/rtemself.h
25403         instead of i386/rtems-64.h.
25404         * config/i386/rtems-64.h: Remove.
25406 2017-01-19  Uros Bizjak  <ubizjak@gmail.com>
25408         PR target/78478
25409         Revert:
25410         2013-11-05  Uros Bizjak  <ubizjak@gmail.com>
25412         * config/i386/rtemself.h (LONG_DOUBLE_TYPE_SIZE): New define.
25414 2017-01-19  Tamar Christina  <tamar.christina@arm.com>
25416         * config/aarch64/aarch64.c (aarch64_simd_gen_const_vector_dup):
25417         Change int to HOST_WIDE_INT.
25418         * config/aarch64/aarch64-protos.h
25419         (aarch64_simd_gen_const_vector_dup): Likewise.
25420         * config/aarch64/aarch64-simd.md: Add copysign<mode>3.
25422 2017-01-19  David Malcolm  <dmalcolm@redhat.com>
25424         * langhooks-def.h (lhd_type_for_size): New decl.
25425         (LANG_HOOKS_TYPE_FOR_SIZE): Define as lhd_type_for_size.
25426         * langhooks.c (lhd_type_for_size): New function, taken from
25427         lto_type_for_size.
25429 2017-01-19  Pat Haugen  <pthaugen@us.ibm.com>
25431         * config/rs6000/power9.md (power9-alu): Remove 'cmp' type and add
25432         define_bypass for CR latency.
25433         (power9-cracked-alu): Update bypass latency and remove power9-branch.
25434         (power9-alu2): Add define_bypass for CR latency.
25435         (power9-cmp): New.
25436         (power9-mul): Update insn latency.
25437         (power9-mul-compare): Update insn latency, bypass latency and remove
25438         power9-branch.
25440 2016-01-19  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
25442         * config/aarch64/aarch64-protos.h (aarch64_nopcrelative_literal_loads):
25443         Delete.
25444         * config/aarch64/aarch64.md
25445         (aarch64_reload_movcp<GPF_TF:mode><P:mode>): Delete reference to
25446         aarch64_nopcrelative_literal_loads.
25447         (aarch64_reload_movcp<VALL:mode><P:mode>): Likewise.
25449 2017-01-19  Chenghua Xu  <paul.hua.gm@gmail.com>
25451         * config/mips/mips.h (ISA_HAS_FUSED_MADD4): Enable for
25452         TARGET_LOONGSON_3A.
25453         (ISA_HAS_UNFUSED_MADD4): Exclude TARGET_LOONGSON_3A.
25455 2017-01-19  Doug Gilmore  <doug.gilmore@imgtec.com>
25457         PR target/78176
25458         * config.gcc (supported_defaults): Add lxc1-sxc1.
25459         (with_lxc1_sxc1): Add validation.
25460         (all_defaults): Add lxc1-sxc1.
25461         * config/mips/mips.opt (mlxc1-sxc1): New option.
25462         * config/mips/mips.h (OPTION_DEFAULT_SPECS): Add a default for
25463         mlxc1-sxc1.
25464         (TARGET_CPU_CPP_BUILTINS): Add builtin_define for
25465         __mips_no_lxc1_sxc1.
25466         (ISA_HAS_LXC1_SXC1): Gate with mips_lxc1_sxc1.
25467         * doc/invoke.texi (-mlxc1-sxc1): Document the new option.
25468         * doc/install.texi (--with-lxc1-sxc1): Document the new option.
25470 2017-01-19  Richard Biener  <rguenther@suse.de>
25472         PR tree-optimization/72488
25473         * tree-ssa-sccvn.c (run_scc_vn): When we abort the VN make
25474         sure to restore SSA info.
25475         * tree-ssa.c (verify_ssa): Verify SSA info is not shared.
25477 2017-01-19  Richard Earnshaw  <rearnsha@arm.com>
25479         PR rtl-optimization/79121
25480         * expr.c (expand_expr_real_2, case LSHIFT_EXPR): Look at the signedness
25481         of the inner type when shifting an extended value.
25483 2017-01-17  Jan Hubicka  <hubicka@ucw.cz>
25485         PR lto/78407
25486         * symtab.c (symtab_node::equal_address_to): Fix comparing of
25487         interposable aliases.
25489 2017-01-18  Peter Bergner  <bergner@vnet.ibm.com>
25491         PR target/78516
25492         * config/rs6000/spe.md (mov_si<mode>_e500_subreg0): Fix constraints.
25493         Use the evmergelohi instruction.
25494         (mov_si<mode>_e500_subreg4_2_le): Likewise.
25495         (mov_sitf_e500_subreg8_2_be): Likewise.
25496         (mov_sitf_e500_subreg12_2_le): Likewise.
25497         (mov_si<mode>_e500_subreg0_2_le): Fix constraints.
25498         (mov_si<mode>_e500_subreg4_2_be): Likewise.
25499         (mov_sitf_e500_subreg8_2_le): Likewise.
25500         (mov_sitf_e500_subreg12_2_be): Likewise.
25502 2017-01-18  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
25504         * config/rs6000/altivec.md (altivec_vbpermq): Change "type"
25505         attribute from vecsimple to vecperm.
25506         (altivec_vbpermq2): Likewise.
25508 2017-01-18  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
25510         PR target/79040
25511         * config/rs6000/altivec.h: Fix typo of vec_cntlz to vec_cnttz.
25513 2017-01-18  Aaron Sawdey  <acsawdey@linux.vnet.ibm.com>
25514         * config/rs6000/rs6000-protos.h (expand_strn_compare): Add arg.
25515         * config/rs6000/rs6000.c (expand_strn_compare): Add ability to expand
25516         strcmp. Fix bug where comparison didn't stop with zero byte. Fix
25517         case where N arg is SIZE_MAX.
25518         * config/rs6000/rs6000.md (cmpstrnsi): Args to expand_strn_compare.
25519         (cmpstrsi): Add pattern.
25521 2017-01-18  Michael Meissner  <meissner@linux.vnet.ibm.com>
25523         * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Add
25524         __builtin_vec_revb builtins.
25525         * config/rs6000/rs6000-builtins.def (P9V_BUILTIN_XXBRQ_V16QI): Add
25526         built-in functions to support generation of the ISA 3.0 XXBR<x>
25527         vector byte reverse instructions.
25528         (P9V_BUILTIN_XXBRQ_V1TI): Likewise.
25529         (P9V_BUILTIN_XXBRD_V2DI): Likewise.
25530         (P9V_BUILTIN_XXBRD_V2DF): Likewise.
25531         (P9V_BUILTIN_XXBGW_V4SI): Likewise.
25532         (P9V_BUILTIN_XXBGW_V4SF): Likewise.
25533         (P9V_BUILTIN_XXBGH_V8HI): Likewise.
25534         (P9V_BUILTIN_VEC_REVB): Likewise.
25535         * config/rs6000/vsx.md (p9_xxbrq_v1ti): New insns/expanders to
25536         generate the ISA 3.0 XXBR<x> vector byte reverse instructions.
25537         (p9_xxbrq_v16qi): Likewise.
25538         (p9_xxbrd_<mode>, VSX_D iterator): Likewise.
25539         (p9_xxbrw_<mode>, VSX_W iterator): Likewise.
25540         (p9_xxbrh_v8hi): Likewise.
25541         * config/rs6000/altivec.h (vec_revb): Define if ISA 3.0.
25542         * doc/extend.texi (RS/6000 Altivec Built-ins): Document the
25543         vec_revb built-in functions.
25545 2017-01-18  Uros Bizjak  <ubizjak@gmail.com>
25547         PR rtl-optimization/78952
25548         * config/i386/i386.md (any_extract): New code iterator.
25549         (*insvqi_2): Use any_extract for source operand.
25550         (*insvqi_3): Use any_shiftrt for source operand.
25552 2017-01-18  Wilco Dijkstra  <wdijkstr@arm.com>
25554         * config/aarch64/aarch64.c (aarch64_sched_adjust_priority)
25555         New function.
25556         (TARGET_SCHED_ADJUST_PRIORITY): Define target hook.
25558 2017-01-18  Matthias Klose  <doko@ubuntu.com>
25560         * doc/install.texi: Allow default for --with-target-bdw-gc-include.
25562 2016-01-18  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
25564         * config/rs6000/altivec.h (vec_bperm): Change #define.
25565         * config/rs6000/altivec.md (UNSPEC_VBPERMD): New enum constant.
25566         (altivec_vbpermq2): New define_insn.
25567         (altivec_vbpermd): Likewise.
25568         * config/rs6000/rs6000-builtin.def (VBPERMQ2): New monomorphic
25569         function interface.
25570         (VBPERMD): Likewise.
25571         (VBPERM): New polymorphic function interface.
25572         * config/rs6000/r6000-c.c (altivec_overloaded_builtins_table):
25573         Add entries for P9V_BUILTIN_VEC_VBPERM.
25574         * doc/extend.texi: Add interfaces for vec_bperm.
25576 2017-01-18  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
25578         * config/s390/s390-c.c (s390_expand_overloaded_builtin): Downcase
25579         first letter of error messages.
25580         (s390_resolve_overloaded_builtin): Likewise.
25581         * config/s390/s390.c (s390_expand_builtin): Likewise.
25582         (s390_invalid_arg_for_unprototyped_fn): Likewise.
25583         (s390_valid_target_attribute_inner_p): Likewise.
25584         * config/s390/s390.md ("tabort"): Likewise.
25586 2017-01-18  Toma Tabacu  <toma.tabacu@imgtec.com>
25588         * config/mips/mips.h (ISA_HAS_DIV3): Remove unused macro.
25589         (ISA_AVOID_DIV_HILO): New macro.
25590         (ISA_HAS_DIV): Use new ISA_AVOID_DIV_HILO macro.
25591         (ISA_HAS_DDIV): Likewise.
25593 2017-01-18  Markus Trippelsdorf  <markus@trippelsdorf.de>
25595         * doc/invoke.texi (fabi-version): Correct number of occurrences.
25597 2017-01-18  Markus Trippelsdorf  <markus@trippelsdorf.de>
25599         * doc/invoke.texi (fabi-version): Spelling fix.
25601 2017-01-18  Markus Trippelsdorf  <markus@trippelsdorf.de>
25603         PR c++/70182
25604         * doc/invoke.texi (fabi-version): Mention mangling fix for
25605         operator names.
25607 2017-01-18  Markus Trippelsdorf  <markus@trippelsdorf.de>
25609         PR c++/77489
25610         * doc/invoke.texi (fabi-version): Document discriminator mangling.
25612 2017-01-17  Segher Boessenkool  <segher@kernel.crashing.org>
25614         PR target/78875
25615         * config/rs6000/rs6000-opts.h (stack_protector_guard): New enum.
25616         * config/rs6000/rs6000.c (rs6000_option_override_internal): Handle
25617         the new options.
25618         * config/rs6000/rs6000.md (stack_protect_set): Handle the new more
25619         flexible settings.
25620         (stack_protect_test): Ditto.
25621         * config/rs6000/rs6000.opt (mstack-protector-guard=,
25622         mstack-protector-guard-reg=, mstack-protector-guard-offset=): New
25623         options.
25624         * doc/invoke.texi (Option Summary) [RS/6000 and PowerPC Options]:
25625         Add -mstack-protector-guard=, -mstack-protector-guard-reg=, and
25626         -mstack-protector-guard-offset=.
25627         (RS/6000 and PowerPC Options): Ditto.
25629 2017-01-17  Uros Bizjak  <ubizjak@gmail.com>
25631         * config/i386/i386.h (MASK_CLASS_P): New define.
25632         * config/i386/i386.c (inline_secondary_memory_needed): Ensure that
25633         there are no registers from different register sets also when
25634         mask registers are used.  Update function comment.
25635         * config/i386/i386.md (*movsi_internal): Split (*k/*krm) alternative
25636         to (*k/*r) and (*k/*km) alternatives.
25638 2017-01-17  Wilco Dijkstra  <wdijkstr@arm.com>
25640         * config/aarch64/aarch64.md (eh_return): Remove pattern and splitter.
25641         * config/aarch64/aarch64.h (AARCH64_EH_STACKADJ_REGNUM): Remove.
25642         (EH_RETURN_HANDLER_RTX): New define.
25643         * config/aarch64/aarch64.c (aarch64_frame_pointer_required):
25644         Force frame pointer in EH return functions.
25645         (aarch64_expand_epilogue): Add barrier for eh_return.
25646         (aarch64_final_eh_return_addr): Remove.
25647         (aarch64_eh_return_handler_rtx): New function.
25648         * config/aarch64/aarch64-protos.h (aarch64_final_eh_return_addr):
25649         Remove.
25650         (aarch64_eh_return_handler_rtx): New prototype.
25652 2017-01-17  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
25654         * config/rs6000/altivec.h (vec_rlmi): New #define.
25655         (vec_vrlnm): Likewise.
25656         (vec_rlnm): Likewise.
25657         * config/rs6000/altivec.md (UNSPEC_VRLMI): New UNSPEC enum value.
25658         (UNSPEC_VRLNM): Likewise.
25659         (VIlong): New mode iterator.
25660         (altivec_vrl<VI_char>mi): New define_insn.
25661         (altivec_vrl<VI_char>nm): Likewise.
25662         * config/rs6000/rs6000-builtin.def (VRLWNM): New monomorphic
25663         function entry.
25664         (VRLDNM): Likewise.
25665         (RLNM): New polymorphic function entry.
25666         (VRLWMI): New monomorphic function entry.
25667         (VRLDMI): Likewise.
25668         (RLMI): New polymorphic function entry.
25669         * config/rs6000/r6000-c.c (altivec_overloaded_builtin_table): Add
25670         new entries for P9V_BUILTIN_VEC_RLMI and P9V_BUILTIN_VEC_RLNM.
25671         * doc/extend.texi: Add description of vec_rlmi, vec_rlnm, and
25672         vec_vrlnm.
25674 2017-01-17  Jakub Jelinek  <jakub@redhat.com>
25676         PR debug/78839
25677         * dwarf2out.c (field_byte_offset): Restore the
25678         PCC_BITFIELD_TYPE_MATTERS behavior for INTEGER_CST DECL_FIELD_OFFSET
25679         and DECL_FIELD_BIT_OFFSET.  Use fold_build2 instead of build2 + fold.
25680         (analyze_variants_discr, gen_variant_part): Use fold_build2 instead
25681         of build2 + fold.
25683 2017-01-17  Eric Botcazou  <ebotcazou@adacore.com>
25685         PR ada/67205
25686         * config/aarch64/aarch64.c (TARGET_CUSTOM_FUNCTION_DESCRIPTORS): Define
25688 2017-01-17  Jakub Jelinek  <jakub@redhat.com>
25690         PR debug/71669
25691         * dwarf2out.c (add_data_member_location_attribute): For constant
25692         offset bitfield emit for -gdwarf-5 DW_AT_data_bit_offset attribute
25693         instead of DW_AT_data_member_location, DW_AT_bit_offset and
25694         DW_AT_byte_size attributes.
25696 2017-01-17  Eric Botcazou  <ebotcazou@adacore.com>
25698         * config/rs6000/rs6000.c (rs6000_emit_move): Also use a TOC reference
25699         after forcing to constant memory when the code model is medium.
25701 2017-01-17  Julia Koval  <julia.koval@intel.com>
25703         PR target/76731
25704         * config/i386/avx512fintrin.h
25705         (_mm512_i32gather_ps): Change __addr type to void const*.
25706         (_mm512_mask_i32gather_ps): Ditto.
25707         (_mm512_i32gather_pd): Ditto.
25708         (_mm512_mask_i32gather_pd): Ditto.
25709         (_mm512_i64gather_ps): Ditto.
25710         (_mm512_mask_i64gather_ps): Ditto.
25711         (_mm512_i64gather_pd): Ditto.
25712         (_mm512_mask_i64gather_pd): Ditto.
25713         (_mm512_i32gather_epi32): Ditto.
25714         (_mm512_mask_i32gather_epi32): Ditto.
25715         (_mm512_i32gather_epi64): Ditto.
25716         (_mm512_mask_i32gather_epi64): Ditto.
25717         (_mm512_i64gather_epi32): Ditto.
25718         (_mm512_mask_i64gather_epi32): Ditto.
25719         (_mm512_i64gather_epi64): Ditto.
25720         (_mm512_mask_i64gather_epi64): Ditto.
25721         (_mm512_i32scatter_ps): Change __addr type to void*.
25722         (_mm512_mask_i32scatter_ps): Ditto.
25723         (_mm512_i32scatter_pd): Ditto.
25724         (_mm512_mask_i32scatter_pd): Ditto.
25725         (_mm512_i64scatter_ps): Ditto.
25726         (_mm512_mask_i64scatter_ps): Ditto.
25727         (_mm512_i64scatter_pd): Ditto.
25728         (_mm512_mask_i64scatter_pd): Ditto.
25729         (_mm512_i32scatter_epi32): Ditto.
25730         (_mm512_mask_i32scatter_epi32): Ditto.
25731         (_mm512_i32scatter_epi64): Ditto.
25732         (_mm512_mask_i32scatter_epi64): Ditto.
25733         (_mm512_i64scatter_epi32): Ditto.
25734         (_mm512_mask_i64scatter_epi32): Ditto.
25735         (_mm512_i64scatter_epi64): Ditto.
25736         (_mm512_mask_i64scatter_epi64): Ditto.
25737         * config/i386/avx512pfintrin.h
25738         (_mm512_mask_prefetch_i32gather_pd): Change __addr type to void const*.
25739         (_mm512_mask_prefetch_i32gather_ps): Ditto.
25740         (_mm512_mask_prefetch_i64gather_pd): Ditto.
25741         (_mm512_mask_prefetch_i64gather_ps): Ditto.
25742         (_mm512_prefetch_i32scatter_pd): Change __addr type to void*.
25743         (_mm512_prefetch_i32scatter_ps): Ditto.
25744         (_mm512_mask_prefetch_i32scatter_pd): Ditto.
25745         (_mm512_mask_prefetch_i32scatter_ps): Ditto.
25746         (_mm512_prefetch_i64scatter_pd): Ditto.
25747         (_mm512_prefetch_i64scatter_ps): Ditto.
25748         (_mm512_mask_prefetch_i64scatter_pd): Ditto.
25749         (_mm512_mask_prefetch_i64scatter_ps): Ditto.
25750         * config/i386/avx512vlintrin.h
25751         (_mm256_mmask_i32gather_ps): Change __addr type to void const*.
25752         (_mm_mmask_i32gather_ps): Ditto.
25753         (_mm256_mmask_i32gather_pd): Ditto.
25754         (_mm_mmask_i32gather_pd): Ditto.
25755         (_mm256_mmask_i64gather_ps): Ditto.
25756         (_mm_mmask_i64gather_ps): Ditto.
25757         (_mm256_mmask_i64gather_pd): Ditto.
25758         (_mm_mmask_i64gather_pd): Ditto.
25759         (_mm256_mmask_i32gather_epi32): Ditto.
25760         (_mm_mmask_i32gather_epi32): Ditto.
25761         (_mm256_mmask_i32gather_epi64): Ditto.
25762         (_mm_mmask_i32gather_epi64): Ditto.
25763         (_mm256_mmask_i64gather_epi32): Ditto.
25764         (_mm_mmask_i64gather_epi32): Ditto.
25765         (_mm256_mmask_i64gather_epi64): Ditto.
25766         (_mm_mmask_i64gather_epi64): Ditto.
25767         (_mm256_i32scatter_ps): Change __addr type to void*.
25768         (_mm256_mask_i32scatter_ps): Ditto.
25769         (_mm_i32scatter_ps): Ditto.
25770         (_mm_mask_i32scatter_ps): Ditto.
25771         (_mm256_i32scatter_pd): Ditto.
25772         (_mm256_mask_i32scatter_pd): Ditto.
25773         (_mm_i32scatter_pd): Ditto.
25774         (_mm_mask_i32scatter_pd): Ditto.
25775         (_mm256_i64scatter_ps): Ditto.
25776         (_mm256_mask_i64scatter_ps): Ditto.
25777         (_mm_i64scatter_ps): Ditto.
25778         (_mm_mask_i64scatter_ps): Ditto.
25779         (_mm256_i64scatter_pd): Ditto.
25780         (_mm256_mask_i64scatter_pd): Ditto.
25781         (_mm_i64scatter_pd): Ditto.
25782         (_mm_mask_i64scatter_pd): Ditto.
25783         (_mm256_i32scatter_epi32): Ditto.
25784         (_mm256_mask_i32scatter_epi32): Ditto.
25785         (_mm_i32scatter_epi32): Ditto.
25786         (_mm_mask_i32scatter_epi32): Ditto.
25787         (_mm256_i32scatter_epi64): Ditto.
25788         (_mm256_mask_i32scatter_epi64): Ditto.
25789         (_mm_i32scatter_epi64): Ditto.
25790         (_mm_mask_i32scatter_epi64): Ditto.
25791         (_mm256_i64scatter_epi32): Ditto.
25792         (_mm256_mask_i64scatter_epi32): Ditto.
25793         (_mm_i64scatter_epi32): Ditto.
25794         (_mm_mask_i64scatter_epi32): Ditto.
25795         (_mm256_i64scatter_epi64): Ditto.
25796         (_mm256_mask_i64scatter_epi64): Ditto.
25797         (_mm_i64scatter_epi64): Ditto.
25798         (_mm_mask_i64scatter_epi64): Ditto.
25799         * config/i386/i386-builtin-types.def (V16SF_V16SF_PCFLOAT_V16SI_HI_INT)
25800         (V8DF_V8DF_PCDOUBLE_V8SI_QI_INT, V8SF_V8SF_PCFLOAT_V8DI_QI_INT)
25801         (V8DF_V8DF_PCDOUBLE_V8DI_QI_INT, V16SI_V16SI_PCINT_V16SI_HI_INT)
25802         (V8DI_V8DI_PCINT64_V8SI_QI_INT, V8SI_V8SI_PCINT_V8DI_QI_INT)
25803         (V8DI_V8DI_PCINT64_V8DI_QI_INT, V2DF_V2DF_PCDOUBLE_V4SI_QI_INT)
25804         (V4DF_V4DF_PCDOUBLE_V4SI_QI_INT, V2DF_V2DF_PCDOUBLE_V2DI_QI_INT)
25805         (V4DF_V4DF_PCDOUBLE_V4DI_QI_INT, V4SF_V4SF_PCFLOAT_V4SI_QI_INT)
25806         (V8SF_V8SF_PCFLOAT_V8SI_QI_INT, V4SF_V4SF_PCFLOAT_V2DI_QI_INT)
25807         (V4SF_V4SF_PCFLOAT_V4DI_QI_INT, V2DI_V2DI_PCINT64_V4SI_QI_INT)
25808         (V4DI_V4DI_PCINT64_V4SI_QI_INT, V2DI_V2DI_PCINT64_V2DI_QI_INT)
25809         (V4DI_V4DI_PCINT64_V4DI_QI_INT, V4SI_V4SI_PCINT_V4SI_QI_INT)
25810         (V8SI_V8SI_PCINT_V8SI_QI_INT, V4SI_V4SI_PCINT_V2DI_QI_INT)
25811         (V4SI_V4SI_PCINT_V4DI_QI_INT, VOID_PFLOAT_HI_V16SI_V16SF_INT)
25812         (VOID_PFLOAT_QI_V8SI_V8SF_INT, VOID_PFLOAT_QI_V4SI_V4SF_INT)
25813         (VOID_PDOUBLE_QI_V8SI_V8DF_INT, VOID_PDOUBLE_QI_V4SI_V4DF_INT)
25814         (VOID_PDOUBLE_QI_V4SI_V2DF_INT, VOID_PFLOAT_QI_V8DI_V8SF_INT)
25815         (VOID_PFLOAT_QI_V4DI_V4SF_INT, VOID_PFLOAT_QI_V2DI_V4SF_INT)
25816         (VOID_PDOUBLE_QI_V8DI_V8DF_INT, VOID_PDOUBLE_QI_V4DI_V4DF_INT)
25817         (VOID_PDOUBLE_QI_V2DI_V2DF_INT, VOID_PINT_HI_V16SI_V16SI_INT)
25818         (VOID_PINT_QI_V8SI_V8SI_INT, VOID_PINT_QI_V4SI_V4SI_INT)
25819         (VOID_PLONGLONG_QI_V8SI_V8DI_INT, VOID_PLONGLONG_QI_V4SI_V4DI_INT)
25820         (VOID_PLONGLONG_QI_V4SI_V2DI_INT, VOID_PINT_QI_V8DI_V8SI_INT)
25821         (VOID_PINT_QI_V4DI_V4SI_INT, VOID_PINT_QI_V2DI_V4SI_INT)
25822         (VOID_PLONGLONG_QI_V8DI_V8DI_INT, VOID_QI_V8SI_PCINT64_INT_INT)
25823         (VOID_PLONGLONG_QI_V4DI_V4DI_INT, VOID_PLONGLONG_QI_V2DI_V2DI_INT)
25824         (VOID_HI_V16SI_PCINT_INT_INT, VOID_QI_V8DI_PCINT64_INT_INT)
25825         (VOID_QI_V8DI_PCINT_INT_INT): Remove.
25826         (V16SF_V16SF_PCVOID_V16SI_HI_INT,  V8DF_V8DF_PCVOID_V8SI_QI_INT)
25827         (V8SF_V8SF_PCVOID_V8DI_QI_INT, V8DF_V8DF_PCVOID_V8DI_QI_INT)
25828         (V16SI_V16SI_PCVOID_V16SI_HI_INT, V8DI_V8DI_PCVOID_V8SI_QI_INT)
25829         (V8SI_V8SI_PCVOID_V8DI_QI_INT, V8DI_V8DI_PCVOID_V8DI_QI_INT)
25830         (VOID_PVOID_HI_V16SI_V16SF_INT, VOID_PVOID_QI_V8SI_V8DF_INT)
25831         (VOID_PVOID_QI_V8DI_V8SF_INT, VOID_PVOID_QI_V8DI_V8DF_INT)
25832         (VOID_PVOID_HI_V16SI_V16SI_INT, VOID_PVOID_QI_V8SI_V8DI_INT)
25833         (VOID_PVOID_QI_V8DI_V8SI_INT, VOID_PVOID_QI_V8DI_V8DI_INT)
25834         (V2DF_V2DF_PCVOID_V4SI_QI_INT, V4DF_V4DF_PCVOID_V4SI_QI_INT)
25835         (V2DF_V2DF_PCVOID_V2DI_QI_INT, V4DF_V4DF_PCVOID_V4DI_QI_INT
25836         (V4SF_V4SF_PCVOID_V4SI_QI_INT, V8SF_V8SF_PCVOID_V8SI_QI_INT)
25837         (V4SF_V4SF_PCVOID_V2DI_QI_INT, V4SF_V4SF_PCVOID_V4DI_QI_INT)
25838         (V2DI_V2DI_PCVOID_V4SI_QI_INT, V4DI_V4DI_PCVOID_V4SI_QI_INT)
25839         (V2DI_V2DI_PCVOID_V2DI_QI_INT, V4DI_V4DI_PCVOID_V4DI_QI_INT)
25840         (V4SI_V4SI_PCVOID_V4SI_QI_INT, V8SI_V8SI_PCVOID_V8SI_QI_INT)
25841         (V4SI_V4SI_PCVOID_V2DI_QI_INT, V4SI_V4SI_PCVOID_V4DI_QI_INT)
25842         (VOID_PVOID_QI_V8SI_V8SF_INT, VOID_PVOID_QI_V4SI_V4SF_INT)
25843         (VOID_PVOID_QI_V4SI_V4DF_INT, VOID_PVOID_QI_V4SI_V2DF_INT)
25844         (VOID_PVOID_QI_V4DI_V4SF_INT, VOID_PVOID_QI_V2DI_V4SF_INT)
25845         (VOID_PVOID_QI_V4DI_V4DF_INT, VOID_PVOID_QI_V2DI_V2DF_INT)
25846         (VOID_PVOID_QI_V8SI_V8SI_INT, VOID_PVOID_QI_V4SI_V4SI_INT)
25847         (VOID_PVOID_QI_V4SI_V4DI_INT, VOID_PVOID_QI_V4SI_V2DI_INT)
25848         (VOID_PVOID_QI_V4DI_V4SI_INT, VOID_PVOID_QI_V2DI_V4SI_INT)
25849         (VOID_PVOID_QI_V4DI_V4DI_INT, VOID_PVOID_QI_V2DI_V2DI_INT)
25850         (VOID_QI_V8SI_PCVOID_INT_INT, VOID_HI_V16SI_PCVOID_INT_INT)
25851         (VOID_QI_V8DI_PCVOID_INT_INT): Add.
25852         * config/i386/i386.c (ix86_init_mmx_sse_builtins): Adjust builtin
25853         definitions accordingly.
25855 2017-01-17  Kito Cheng  <kito.cheng@gmail.com>
25856             Kuan-Lin Chen  <kuanlinchentw@gmail.com>
25858         PR target/79079
25859         * internal-fn.c (expand_mul_overflow): Use convert_modes instead of
25860         gen_lowpart.
25862 2017-01-17  Vladimir Makarov  <vmakarov@redhat.com>
25864         PR target/79058
25865         * ira-conflicts.c (ira_build_conflicts): Update total conflict
25866         hard regs for inner regno.
25868 2017-01-17  Martin Liska  <mliska@suse.cz>
25870         PR ipa/71207
25871         * ipa-polymorphic-call.c (contains_type_p): Fix wrong
25872         assumption and add comment.
25874 2017-01-17  Nathan Sidwell  <nathan@acm.org>
25876         * ipa-visibility.c (localize_node): New function, broken out of ...
25877         (function_and_variable_visibility): ... here. Call it.
25879 2017-01-17  Jan Hubicka  <hubicka@ucw.cz>
25881         PR middle-end/77445
25882         * tree-ssa-threadupdate.c (remove_ctrl_stmt_and_useless_edges):
25883         correctly set frequency of oudgoing edge.
25884         (duplicate_thread_path): Fix profile updating.
25886 2017-01-17  Jakub Jelinek  <jakub@redhat.com>
25888         PR other/79046
25889         * configure.ac: Add GCC_BASE_VER.
25890         * Makefile.in (version): Use @get_gcc_base_ver@ instead of cat to get
25891         version from BASE-VER file.
25892         (CFLAGS-gcc.o): Add -DBASEVER=$(BASEVER_s).
25893         (gcc.o): Depend on $(BASEVER).
25894         * common.opt (dumpfullversion): New option.
25895         * gcc.c (driver_handle_option): Handle OPT_dumpfullversion.
25896         * doc/invoke.texi: Document -dumpfullversion.
25897         * doc/install.texi: Document --with-gcc-major-version-only.
25898         * configure: Regenerated.
25900 2017-01-17  Richard Biener  <rguenther@suse.de>
25902         PR tree-optimization/71433
25903         * tree-vrp.c (register_new_assert_for): Merge same asserts
25904         on all incoming edges.
25905         (process_assert_insertions_for): Handle insertions at the
25906         beginning of BBs.
25908 2017-01-17  Gerald Pfeifer  <gerald@pfeifer.com>
25910         * config/i386/cygwin.h (LIBGCJ_SONAME): Remove.
25911         * config/i386/mingw32.h (LIBGCJ_SONAME): Remove.
25913 2017-01-17  Kaz Kojima  <kkojima@gcc.gnu.org>
25915         PR target/78633
25916         * config/sh/sh.md (cmpeqsi_t+1): Call copy_rtx to avoid invalid
25917         RTL sharing.
25919 2017-01-17  Alan Modra  <amodra@gmail.com>
25921         PR target/79066
25922         * config/rs6000/rs6000.md (elf_high, elf_low): Disable when pic.
25923         * config/rs6000/rs6000.c (rs6000_emit_allocate_stack): Don't allow
25924         symbolic stack limit when pic.
25926 2017-01-16  Martin Sebor  <msebor@redhat.com>
25928         PR tree-optimization/78608
25929         * gimple-ssa-sprintf.c (tree_digits): Avoid negating TYPE_MIN.
25931 2017-01-16  Jeff Law  <law@redhat.com>
25933         Revert:
25934         2016-12-02  Tadek Kijkowski  <tkijkowski@gmail.com>
25935         * Makefile.in (PREPROCESSOR_DEFINES): Add a level of indirection
25936         for several include directories that may be relative to sysroot.
25937         * config/i386/x-mingw32 (gplus_includedir): Define.
25938         (gplus_tool_includedir, gplus_backward_include_dir): Likewise.
25939         (native_system_includedir): Likewise.
25940         * config/i386/mingw32.h (STANDARD_STARTFILE_PREFIX_1): Do not
25941         override if TARGET_SYSTEM_ROOT is defined.
25942         (NATIVE_SYSTEM_HEADER_DIR): Likewise.
25944         PR tree-optimization/79090
25945         PR tree-optimization/33562
25946         PR tree-optimization/61912
25947         PR tree-optimization/77485
25948         * tree-ssa-dse.c (compute_trims): Accept STMT argument.  Dump STMT
25949         and computed trims into the dump file.
25951 2017-01-17  Uros Bizjak  <ubizjak@gmail.com>
25953         * config/i386/i386.h (LIMIT_RELOAD_CLASS): Remove.
25955 2017-01-16  Jakub Jelinek  <jakub@redhat.com>
25957         PR c/79089
25958         * gimplify.c (gimplify_init_constructor): If want_value and
25959         object == lhs, unshare lhs to avoid invalid tree sharing.  Formatting
25960         fix.
25962         PR target/79080
25963         * loop-doloop.c (doloop_modify): Call unshare_all_rtl_in_chain on
25964         sequence.  Formatting fixes.
25965         (doloop_optimize): Formatting fixes.
25967         PR driver/49726
25968         * gcc.c (debug_level_greater_than_spec_func): New function.
25969         (static_spec_functions): Add debug-level-gt spec function.
25970         (ASM_DEBUG_SPEC, cpp_options): Use %:debug-level-gt(0) instead of
25971         !g0.
25972         * config/darwin.h (DSYMUTIL_SPEC, ASM_DEBUG_SPEC): Likewise.
25973         * config/darwin9.h (DSYMUTIL_SPEC, ASM_DEBUG_SPEC): Likewise.
25974         * common.opt (g, gcoff, gdwarf, gdwarf-, ggdb, gno-pubnames,
25975         gpubnames, ggnu-pubnames, gno-record-gcc-switches,
25976         grecord-gcc-switches, gno-strict-dwarf, gstrict-dwarf, gstabs,
25977         gstabs+, gtoggle, gvms, gxcoff, gxcoff+): Add Driver flag.
25979 2017-01-16  Uros Bizjak  <ubizjak@gmail.com>
25981         * config/i386/i386.h (HARD_REGNO_CALLER_SAVE_MODE): Apply HImode and
25982         QImode fixups to general and mask registers only.
25984 2017-01-16  Carl Love  <cel@us.ibm.com>
25986         * config/rs6000/rs6000-c (altivec_overloaded_builtins): Add support
25987         for built-in functions
25988         vector signed char vec_nabs (vector signed char)
25989         vector signed short vec_nabs (vector signed short)
25990         vector signed int vec_nabs (vector signed int)
25991         vector signed long long vec_nabs (vector signed long long)
25992         vector float vec_nabs (vector float)
25993         vector double vec_nabs (vector double)
25994         * config/rs6000/rs6000-builtin.def: Add definitions for NABS functions
25995         and NABS overload.
25996         * config/rs6000/altivec.md: New define_expand nabs<mode>2 types
25997         * config/rs6000/altivec.h: New define for vec_nabs built-in function.
25998         * doc/extend.texi: Update the documentation file for the new built-in
25999         functions.
26001 2017-01-16  Martin Sebor  <msebor@redhat.com>
26003         * gimple-ssa-sprintf.c (format_directive): Correct a typo in a warning
26004         message.
26006 2017-01-16  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
26008         * config/rs6000/rs6000.c (rtx_is_swappable_p): Change
26009         UNSPEC_VSX__XXSPLTD to require special splat handling.
26011 2017-01-16  David Malcolm  <dmalcolm@redhat.com>
26013         PR bootstrap/78616
26014         * system.h: Poison strndup.
26016 2017-01-16  Alan Modra  <amodra@gmail.com>
26018         PR target/79098
26019         * config/rs6000/rs6000.c (rs6000_legitimate_combined_insn): Don't
26020         use a switch.
26022 2017-01-16  Georg-Johann Lay  <avr@gjlay.de>
26024         * config/avr/avr.h (BRANCH_COST) [reload_completed]: Increase by 4.
26026 2017-01-15  Uros Bizjak  <ubizjak@gmail.com>
26028         * config/i386/i386.c (ix86_legitimate_combined_insn): Do not
26029         call recog here.  Assert that INSN_CODE (insn) is non-negative.
26031 2017-01-15  Segher Boessenkool  <segher@kernel.crashing.org>
26033         PR target/72749
26034         * cfgrtl.c (rtl_split_edge): Also patch jump insns that jump to the
26035         fallthrough.
26036         * haifa-sched.c (dump_insn_stream): Don't crash if there is a label
26037         in the currently scheduled RTL fragment.
26039 2017-01-15  Segher Boessenkool  <segher@kernel.crashing.org>
26041         PR rtl-optimization/78751
26042         * ifcvt.c (find_cond_trap): If we generated a non-existing insn,
26043         give up.
26045 2017-01-14  Jeff Law  <law@redhat.com>
26047         PR tree-optimization/79090
26048         * tree-ssa-dse.c (valid_ao_ref_for_dse): Reject zero length and
26049         variable length stores.
26050         (compute_trims): Delete dead assignment to *trim_tail.
26051         (dse_dom_walker::dse_optimize_stmt): Optimize mem* calls with
26052         zero length.
26054 2017-01-14  Bernd Schmidt  <bschmidt@redhat.com>
26056         PR rtl-optimization/78626
26057         PR rtl-optimization/78727
26058         * cprop.c (one_cprop_pass): Collect unconditional traps in the middle
26059         of a block, and split such blocks after everything else is finished.
26061 2017-01-14  Alan Modra  <amodra@gmail.com>
26063         PR target/72749
26064         * combine.c (recog_for_combine_1): Set INSN_CODE before calling
26065         target legitimate_combined_insn.
26066         * config/rs6000/rs6000.c (TARGET_LEGITIMATE_COMBINED_INSN): Define.
26067         (rs6000_legitimate_combined_insn): New function.
26068         * config/rs6000/rs6000.md (UNSPEC_DOLOOP): Delete, and remove
26069         all uses.
26070         (ctr<mode>_internal3): Rename from *ctr<mode>_internal5.
26071         (ctr<mode>_internal4): Rename from *ctr<mode>_internal6.
26072         (ctr<mode>_internal1, ctr<mode>_internal2): Remove '*' from name.
26074 2017-01-14  Gerald Pfeifer  <gerald@pfeifer.com>
26076         * doc/frontends.texi (G++ and GCC): Remove references to Java.
26078 2017-01-13  Jeff Law  <law@redhat.com>
26080         PR tree-optimization/33562
26081         PR tree-optimization/61912
26082         PR tree-optimization/77485
26083         * tree-ssa-dse.c (delete_dead_call): Accept gsi rather than
26084         a statement.
26085         (delete_dead_assignment): Likewise.
26086         (dse_dom_walker::dse_optimize_stmt): Pass in the gsi rather than
26087         statement to delete_dead_call and delete_dead_assignment.
26089 2017-01-13  David Malcolm  <dmalcolm@redhat.com>
26091         PR c/78304
26092         * substring-locations.c (format_warning_va): Strengthen case 1 so
26093         that both endpoints of the substring must be within the format
26094         range for just the substring to be printed.
26096 2017-01-13  Uros Bizjak  <ubizjak@gmail.com>
26098         * config/i386/i386.opt (msgx): Use ix86_isa_flags2 variable.
26099         * config/i386/i386.c (ix86_target_string): Add missing options
26100         to isa_opts and reorder options by implied ISAs.  Rename isa_opts2 to
26101         isa2_opts, ix86_flag_opts to flag2_opts, ix86_target_other to
26102         flags_other and ix86_target_other to flags2_other.  Display unknown
26103         isa2 options.
26104         (ix86_valid_target_attribute_inner_p): Add missing options and
26105         reorder options by implied ISAs, as in ix86_target_string.
26107 2017-01-13  Richard Sandiford  <richard.sandiford@arm.com>
26109         * hash-table.h (hash_table::too_empty_p): New function.
26110         (hash_table::expand): Use it.
26111         (hash_table::traverse): Likewise.
26112         (hash_table::empty_slot): Use sizeof (value_type) instead of
26113         sizeof (PTR) to convert bytes to elements.  Shrink the table
26114         if the current size is excessive for the current number of
26115         elements.
26117 2017-01-13  Richard Sandiford  <richard.sandiford@arm.com>
26119         * ira-costs.c (record_reg_classes): Break from the inner loop
26120         early once alt_fail is known to be true.  Update outer loop
26121         handling accordingly.
26123 2017-01-13  Jeff Law  <law@redhat.com>
26125         * tree-ssa-dse.c (decrement_count): New function.
26126         (increment_start_addr, maybe_trim_memstar_call): Likewise.
26127         (dse_dom_walker::optimize_stmt): Call maybe_trim_memstar_call directly
26128         when we know the partially dead statement is a mem* function.
26130         PR tree-optimization/61912
26131         PR tree-optimization/77485
26132         * tree-ssa-dse.c: Include expr.h.
26133         (maybe_trim_constructor_store): New function.
26134         (maybe_trim_partially_dead_store): Call maybe_trim_constructor_store.
26136         PR tree-optimization/33562
26137         PR tree-optimization/61912
26138         PR tree-optimization/77485
26139         * doc/invoke.texi: Document new dse-max-object-size param.
26140         * params.def (PARM_DSE_MAX_OBJECT_SIZE): New PARAM.
26141         * tree-ssa-dse.c: Include params.h.
26142         (dse_store_status): New enum.
26143         (initialize_ao_ref_for_dse): New, partially extracted from
26144         dse_optimize_stmt.
26145         (valid_ao_ref_for_dse, normalize_ref): New.
26146         (setup_live_bytes_from_ref, compute_trims): Likewise.
26147         (clear_bytes_written_by, maybe_trim_complex_store): Likewise.
26148         (maybe_trim_partially_dead_store): Likewise.
26149         (maybe_trim_complex_store): Likewise.
26150         (dse_classify_store): Renamed from dse_possibly_dead_store_p.
26151         Track what bytes live from the original store.  Return tri-state
26152         for dead, partially dead or live.
26153         (dse_dom_walker): Add constructor, destructor and new private members.
26154         (delete_dead_call, delete_dead_assignment): New extracted from
26155         dse_optimize_stmt.
26156         (dse_optimize_stmt): Make a member of dse_dom_walker.
26157         Use initialize_ao_ref_for_dse.
26159         PR tree-optimization/33562
26160         PR tree-optimization/61912
26161         PR tree-optimization/77485
26162         * sbitmap.h (bitmap_count_bits): Prototype.
26163         (bitmap_clear_range, bitmap_set_range): Likewise.
26164         * sbitmap.c (bitmap_clear_range): New function.
26165         (bitmap_set_range, sbitmap_popcount, bitmap_count_bits): Likewise.
26167 2017-01-13  Martin Liska  <mliska@suse.cz>
26169         PR ipa/79043
26170         * function.c (set_cfun): Add new argument force.
26171         * function.h (set_cfun): Likewise.
26172         * ipa-inline-transform.c (inline_call): Use the function when
26173         strict alising from is dropped for function we inline to.
26175 2017-01-13  Richard Biener  <rguenther@suse.de>
26177         * tree-pretty-print.c (dump_generic_node): Fix inverted condition
26178         for dumping GIMPLE INTEGER_CSTs.
26180 2017-01-13  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
26182         * config/sol2.h (TARGET_OS_CPP_BUILTINS): Define __STDC_VERSION__
26183         to 201112L since C++17.
26185 2017-01-13  Maxim Ostapenko  <m.ostapenko@samsung.com>
26187         PR sanitizer/78887
26188         * asan.c (asan_needs_odr_indicator_p): Don't emit ODR indicators
26189         if -fsanitize=kernel-address is present.
26191 2017-01-13  Richard Biener  <rguenther@suse.de>
26193         * tree-pretty-print.c (dump_generic_node): Dump INTEGER_CSTs
26194         as _Literal ( type ) number in case usual suffixes do not
26195         preserve all information.
26197 2017-01-13  Richard Biener  <rguenther@suse.de>
26199         PR tree-optimization/77283
26200         * gimple-ssa-split-paths.c: Include gimple-ssa.h, tree-phinodes.h
26201         and ssa-iterators.h.
26202         (is_feasible_trace): Implement a cost model based on joiner
26203         PHI node uses.
26205 2017-01-12  Michael Meissner  <meissner@linux.vnet.ibm.com>
26207         PR target/79004
26208         * config/rs6000/rs6000.md (FP_ISA3): Do not optimize converting
26209         char or short to __float128/_Float128 directly.
26211 2017-01-12  Martin Sebor  <msebor@redhat.com>
26213         to -Wformat-overflow.
26214         * gimple-ssa-sprintf.c (pass_sprintf_length::gate): Adjust.
26215         (min_bytes_remaining): Same.
26216         (get_string_length): Same.
26217         (format_string): Same.
26218         (format_directive): Same.
26219         (add_bytes): Same.
26220         (pass_sprintf_length::handle_gimple_call): Same.
26222 2017-01-12  Jakub Jelinek  <jakub@redhat.com>
26224         * gimple-ssa-sprintf.c (try_substitute_return_value): Remove
26225         info.nowrite calls with no lhs that can't throw.  Return bool
26226         whether gsi_remove has been called or not.
26227         (pass_sprintf_length::handle_gimple_call): Return bool whether
26228         try_substitute_return_value called gsi_remove.  Formatting fix.
26229         (pass_sprintf_length::execute): Don't use gsi_remove if
26230         handle_gimple_call returned true.
26232         PR bootstrap/79069
26233         * cfgrtl.c (rtl_tidy_fallthru_edge): For any_uncondjump_p that can't
26234         be removed due to side-effects, don't remove following barrier nor
26235         turn the successor edge into fallthru edge.
26237 2017-01-12  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
26239         PR target/79044
26240         * config/rs6000/rs6000.c (insn_is_swappable_p): Mark
26241         element-reversing loads and stores as not swappable.
26243 2017-01-12  Nathan Sidwell  <nathan@acm.org>
26244             Nicolai Stange  <nicstange@gmail.com>
26246         * combine.c (try_combine): Don't ignore result of overlap checking
26247         loop.  Combine overlap & asm check into single loop.
26249 2017-01-12  Richard Biener  <rguenther@suse.de>
26251         * tree-pretty-print.c (dump_generic_node): Provide -gimple
26252         variant for MEM_REF.  Sanitize INTEGER_CST for -gimple.
26254 2017-01-12  Richard Biener  <rguenther@suse.de>
26256         * tree.c (initialize_tree_contains_struct): Make TS_OPTIMIZATION
26257         and TS_TARGET_OPTION directly derive from TS_BASE.
26258         * tree-core.h (tree_optimization_option): Derive from tree_base.
26259         (tree_target_option): Likewise.
26261 2017-01-11  Uros Bizjak  <ubizjak@gmail.com>
26263         * config/i386/i386.c (memory_address_length): Increase len
26264         only when rip_relative_addr_p returns false.
26266 2017-01-11  Julia Koval  <julia.koval@intel.com>
26268         * common/config/i386/i386-common.c (OPTION_MASK_ISA_SGX_UNSET): New.
26269         (OPTION_MASK_ISA_SGX_SET): New.
26270         (ix86_handle_option): Handle OPT_msgx.
26271         * config.gcc: Added sgxintrin.h.
26272         * config/i386/driver-i386.c (host_detect_local_cpu): Detect sgx.
26273         * config/i386/i386-c.c (ix86_target_macros_internal): Define __SGX__.
26274         * config/i386/i386.c (ix86_target_string): Add -msgx.
26275         (PTA_SGX): New.
26276         (ix86_option_override_internal): Handle new options.
26277         (ix86_valid_target_attribute_inner_p): Add sgx.
26278         * config/i386/i386.h (TARGET_SGX, TARGET_SGX_P): New.
26279         * config/i386/i386.opt: Add msgx.
26280         * config/i386/sgxintrin.h: New file.
26281         * config/i386/x86intrin.h: Add sgxintrin.h.
26283 2017-01-11  Jakub Jelinek  <jakub@redhat.com>
26285         PR c++/71537
26286         * fold-const.c (maybe_nonzero_address): Return 1 for function
26287         local objects.
26288         (tree_single_nonzero_warnv_p): Don't handle function local objects
26289         here.
26291         PR c++/72813
26292         * gcc.c (default_compilers): Don't add -o %g.s for -S -save-temps
26293         of c-header.
26295 2017-01-11  David Malcolm  <dmalcolm@redhat.com>
26297         PR driver/78877
26298         * opts.c: Include "spellcheck.h"
26299         (struct string_fragment): New struct.
26300         (struct edit_distance_traits<const string_fragment &>): New
26301         struct.
26302         (get_closest_sanitizer_option): New function.
26303         (parse_sanitizer_options): Offer suggestions for unrecognized arguments.
26305 2017-01-11  Jakub Jelinek  <jakub@redhat.com>
26307         * dwarf2out.c (DWARF_COMPILE_UNIT_HEADER_SIZE): For DWARF5 decrease
26308         by 12.
26309         (DWARF_COMDAT_TYPE_UNIT_HEADER_SIZE): Always
26310         DWARF_COMPILE_UNIT_HEADER_SIZE plus 12.
26311         (DWARF_COMPILE_UNIT_SKELETON_HEADER_SIZE): Define.
26312         (calc_base_type_die_sizes): Use DWARF_COMPILE_UNIT_SKELETON_HEADER_SIZE
26313         for initial die_offset if dwarf_split_debug_info.
26314         (output_comp_unit): Use DWARF_COMPILE_UNIT_SKELETON_HEADER_SIZE for
26315         initial next_die_offset if dwo_id is non-NULL.  Don't emit padding
26316         fields.
26317         (output_skeleton_debug_sections): Formatting fix.  Use
26318         DWARF_COMPILE_UNIT_SKELETON_HEADER_SIZE instead of
26319         DWARF_COMPILE_UNIT_HEADER_SIZE.  Don't emit padding.
26321 2017-01-11  Wilco Dijkstra  <wdijkstr@arm.com>
26323         * config/arm/cortex-a53.md: Add bypasses for
26324         cortex_a53_r2f_cvt.
26325         (cortex_a53_r2f): Only use for transfers.
26326         (cortex_a53_f2r): Likewise.
26327         (cortex_a53_r2f_cvt): Add reservation for conversions.
26328         (cortex_a53_f2r_cvt): Likewise.
26330 2017-01-11  Tamar Christina  <tamar.christina@arm.com>
26332         * config/arm/arm_neon.h: Add __artificial__ and gnu_inline
26333         to all inlined functions, change static to extern.
26335 2017-01-11  Christophe Lyon  <christophe.lyon@linaro.org>
26337         PR target/78253
26338         * config/arm/arm.c (legitimize_pic_address): Handle reference to
26339         weak symbol.
26340         (arm_assemble_integer): Likewise.
26342 2017-01-11  Richard Earnshaw  <rearnsha@arm.com>
26344         * config.gcc: Use new awk script to check CPU, FPU and architecture
26345         parameters for --with-... options.
26346         * config/arm/parsecpu.awk: New file
26347         * config/arm/arm-cpus.in: New file.
26348         * config/arm/arm-opts.h: Include arm-cpu.h instead of processing .def
26349         files.
26350         * config/arm/arm.c: Include arm-cpu-data.h instead of processing .def
26351         files.
26352         * config/arm/t-arm: Update dependency rules.
26353         * common/config/arm/arm-common.c: Include arm-cpu-cdata.h instead
26354         of processing .def files.
26355         * config/arm/genopt.sh: Deleted.
26356         * config/arm/gentune.sh: Deleted.
26357         * config/arm/arm-cores.def: Deleted.
26358         * config/arm/arm-arches.def: Deleted.
26359         * config/arm/arm-fpus.def: Deleted.
26360         * config/arm/arm-tune.md: Regenerated.
26361         * config/arm/arm-tables.opt: Regenerated.
26362         * config/arm/arm-cpu.h: New generated file.
26363         * config/arm/arm-cpu-data.h: New generated file.
26364         * config/arm/arm-cpu-cdata.h: New generated file.
26366 2017-01-11  Maxim Ostapenko  <m.ostapenko@samsung.com>
26368         PR lto/79042
26369         * lto-cgraph.c (lto_output_varpool_node): Pack dynamically_initialized
26370         bit.
26371         (input_varpool_node): Unpack dynamically_initialized bit.
26373 2017-01-11  Eric Botcazou  <ebotcazou@adacore.com>
26375         PR rtl-optimization/79032
26376         * lra-constraints.c (simplify_operand_subreg): In the MEM case, test
26377         the alignment of the adjusted memory reference against that of MODE,
26378         instead of the alignment of the original memory reference.
26380 2017-01-11  Martin Jambor  <mjambor@suse.cz>
26382         * hsa.c (hsa_callable_function_p): Revert addition of DECL_ARTIFICIAL
26383         test.
26384         * ipa-hsa.c (process_hsa_functions): Only duplicate non-artificial
26385         decorated functions.
26387 2017-01-11  Richard Biener  <rguenther@suse.de>
26389         * tree-vrp.c (evrp_dom_walker::before_dom_children): Also
26390         set range/nonnull info for PHI results.  Do not set it on
26391         stmts marked for removal.
26393 2017-01-10  Eric Botcazou  <ebotcazou@adacore.com>
26395         * expr.c (store_field): In the bitfield case, fetch the return value
26396         from the registers before applying a single big-endian adjustment.
26397         Always do a final load for a BLKmode value not larger than a word.
26399 2017-01-10  David Malcolm  <dmalcolm@redhat.com>
26401         PR c++/77949
26402         * input.c (selftest::test_accessing_ordinary_linemaps): Verify
26403         that we correctly handle column numbers greater than
26404         LINE_MAP_MAX_COLUMN_NUMBER.
26406 2017-01-10  Martin Sebor  <msebor@redhat.com>
26408         PR middle-end/78245
26409         * gimple-ssa-sprintf.c (get_destination_size): Call
26410         {init,fini}object_sizes.
26411         * tree-object-size.c (addr_object_size): Adjust.
26412         (pass_through_call): Adjust.
26413         (pass_object_sizes::execute): Adjust.
26414         * tree-object-size.h (fini_object_sizes): Declare.
26416 2017-01-10  Martin Sebor  <msebor@redhat.com>
26418         PR tree-optimization/78775
26419         * builtins.c (get_size_range): Move...
26420         * calls.c: ...to here.
26421         (alloc_max_size): Accept zero argument.
26422         (operand_signed_p): Remove.
26423         (maybe_warn_alloc_args_overflow): Call get_size_range.
26424         * calls.h (get_size_range): Declare.
26426 2017-01-10  Joe Seymour  <joe.s@somniumtech.com>
26428         * config/msp430/driver-msp430.c (msp430_mcu_data): Sync with data
26429         from TI's devices.csv file as of September 2016.
26430         * config/msp430/msp430.c (msp430_mcu_data): Likewise.
26432 2017-01-10  Sandra Loosemore  <sandra@codesourcery.com>
26434         * doc/extend.texi: Tweak formatting to fix overfull hbox warnings.
26435         * doc/invoke.texi: Likewise.
26436         * doc/md.texi: Likewise.
26437         * doc/objc.texi: Likewise.
26439 2017-01-10  Joshua Conner  <joshconner@google.com>
26441         * config/arm/fuchsia-elf.h: New file.
26442         * config/fuchsia.h: New file.
26443         * config.gcc (*-*-fuchsia*): Set native_system_header_dir.
26444         (aarch64*-*-fuchsia*, arm*-*-fuchsia*, x86_64-*-fuchsia*): Add to
26445         targets.
26446         * config.host: (aarch64*-*-fuchsia*, arm*-*-fuchsia*): Add to hosts.
26448 2016-01-10  Richard Biener  <rguenther@suse.de>
26450         PR tree-optimization/79034
26451         * tree-call-cdce.c (shrink_wrap_one_built_in_call_with_conds):
26452         Propagate out degenerate PHIs in the joiner.
26454 2017-01-10  Martin Liska  <mliska@suse.cz>
26456         * ipa-icf.c (sort_sem_items_by_decl_uid): New function.
26457         (sort_congruence_classes_by_decl_uid): Likewise.
26458         (sort_congruence_class_groups_by_decl_uid): Likewise.
26459         (sem_item_optimizer::merge_classes): Sort class, groups in these
26460         classes and members in the groups by DECL_UID of declarations.
26461         This would make merge operations stable.
26463 2017-01-10  Martin Liska  <mliska@suse.cz>
26465         * ipa-icf.c (sem_item_optimizer::sem_item_optimizer): Remove
26466         usage of m_classes_vec.
26467         (sem_item_optimizer::~sem_item_optimizer):  Likewise.
26468         (sem_item_optimizer::get_group_by_hash): Likewise.
26469         (sem_item_optimizer::subdivide_classes_by_equality): Likewise.
26470         (sem_item_optimizer::subdivide_classes_by_sensitive_refs): Likewise.
26471         (sem_item_optimizer::verify_classes): Likewise.
26472         (sem_item_optimizer::process_cong_reduction): Likewise.
26473         (sem_item_optimizer::dump_cong_classes): Likewise.
26474         (sem_item_optimizer::merge_classes): Likewise.
26475         * ipa-icf.h (congruence_class_hash): Rename from
26476         congruence_class_group_hash.  Remove declaration of m_classes_vec.
26478 2017-01-10  Andrew Senkevich  <andrew.senkevich@intel.com>
26480         * common/config/i386/i386-common.c (OPTION_MASK_ISA_AVX512VPOPCNTDQ_SET,
26481         OPTION_MASK_ISA_AVX512VPOPCNTDQ_UNSET): New.
26482         * config.gcc: Add avx512vpopcntdqintrin.h.
26483         * config/i386/avx512vpopcntdqintrin.h: New.
26484         * config/i386/cpuid.h (bit_AVX512VPOPCNTDQ): New.
26485         * config/i386/i386-builtin-types.def: Add new types.
26486         * config/i386/i386-builtin.def (__builtin_ia32_vpopcountd_v16si,
26487         __builtin_ia32_vpopcountd_v16si_mask, __builtin_ia32_vpopcountq_v8di,
26488         __builtin_ia32_vpopcountq_v8di_mask): New.
26489         * config/i386/i386-c.c (ix86_target_macros_internal): Define
26490         __AVX512VPOPCNTDQ__.
26491         * config/i386/i386.c (ix86_target_string): Add -mavx512vpopcntdq.
26492         (PTA_AVX512VPOPCNTDQ): Define.
26493         * config/i386/i386.h (TARGET_AVX512VPOPCNTDQ,
26494         TARGET_AVX512VPOPCNTDQ_P): Define.
26495         * config/i386/i386.opt: Add mavx512vpopcntdq.
26496         * config/i386/immintrin.h: Include avx512vpopcntdqintrin.h.
26497         * config/i386/sse.md (define_insn "vpopcount<mode><mask_name>"): New.
26499 2017-01-01  Jan Hubicka  <hubicka@ucw.cz>
26501         PR middle-end/77484
26502         * predict.def (PRED_CALL): Set to 67.
26504 2017-01-09  Eric Botcazou  <ebotcazou@adacore.com>
26506         * expr.c (store_field): In the bitfield case, if the value comes from
26507         a function call and is of an aggregate type returned in registers, do
26508         not modify the field mode; extract the value in all cases if the mode
26509         is BLKmode and the size is not larger than a word.
26511 2017-01-09  Dominique d'Humieres  <dominiq@lps.ens.fr>
26513         PR target/71017
26514         * config/i386/cpuid.h: Fix undefined behavior.
26516 2017-01-04  Jeff Law  <law@redhat.com>
26518         PR tree-optimization/79007
26519         PR tree-optimization/67955
26520         * tree-ssa-alias.c (same_addr_size_stores_p): Only need to be
26521         conservative for pt.null when flag_non_call_exceptions is on.
26523 2017-01-09  Jakub Jelinek  <jakub@redhat.com>
26525         PR translation/79019
26526         PR translation/79020
26527         * params.def (PARAM_INLINE_MIN_SPEEDUP,
26528         PARAM_IPA_CP_SINGLE_CALL_PENALTY,
26529         PARAM_USE_AFTER_SCOPE_DIRECT_EMISSION_THRESHOLD): Fix typos
26530         in descriptions.
26531         * config/avr/avr.opt (maccumulate-args): Likewise.
26532         * config/msp430/msp430.opt (mwarn-mcu): Likewise.
26533         * common.opt (freport-bug): Likewise.
26534         * cif-code.def (CIF_FINAL_ERROR): Likewise.
26535         * doc/invoke.texi (ipa-cp-single-call-penalty): Likewise.
26536         * config/s390/s390.c (s390_invalid_binary_op): Fix spelling in
26537         translatable string.
26538         * config/i386/i386.c (function_value_32): Likewise.
26539         * config/nios2/nios2.c (nios2_valid_target_attribute_rec): Likewise.
26540         * config/msp430/msp430.c (msp430_option_override, msp430_attr):
26541         Likewise.
26542         * config/msp430/driver-msp430.c (msp430_select_hwmult_lib): Likewise.
26543         * common/config/msp430/msp430-common.c (msp430_handle_option):
26544         Likewise.
26545         * symtab.c (symtab_node::verify_base): Likewise.
26546         * opts.c (set_debug_level): Likewise.
26547         * tree.c (verify_type_variant): Likewise.  Fix typo in comment.
26548         * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin): Add
26549         missing whitespace to translatable strings.
26550         * config/avr/avr.md (bswapsi2): Fix typo in comment.
26551         * config/sh/superh.h: Likewise.
26552         * config/i386/xopintrin.h: Likewise.
26553         * config/i386/znver1.md: Likewise.
26554         * config/rs6000/rs6000.c (struct rs6000_opt_mask): Likewise.
26555         * ipa-inline-analysis.c (compute_inline_parameters): Likewise.
26556         * double-int.h (struct double_int): Likewise.
26557         * double-int.c (div_and_round_double): Likewise.
26558         * wide-int.cc: Likewise.
26559         * tree-ssa.c (non_rewritable_mem_ref_base): Likewise.
26560         * tree-ssa-sccvn.c (vn_reference_lookup_3): Likewise.
26561         * cfgcleanup.c (crossjumps_occured): Renamed to ...
26562         (crossjumps_occurred): ... this.
26563         (try_crossjump_bb, try_head_merge_bb, try_optimize_cfg, cleanup_cfg):
26564         Adjust all uses.
26566         PR tree-optimization/78899
26567         * tree-if-conv.c (version_loop_for_if_conversion): Instead of
26568         returning bool return struct loop *, NULL for failure and the new
26569         loop on success.
26570         (versionable_outer_loop_p): Don't version outer loop if it has
26571         dont_vectorized bit set.
26572         (tree_if_conversion): When versioning outer loop, ensure
26573         tree_if_conversion is performed also on the inner loop of the
26574         non-vectorizable outer loop copy.
26575         * tree-vectorizer.c (set_uid_loop_bbs): Formatting fix.  Fold
26576         LOOP_VECTORIZED in inner loop of the scalar outer loop and
26577         prevent vectorization of it.
26578         (vectorize_loops): For outer + inner LOOP_VECTORIZED, ensure
26579         the outer loop vectorization of the non-scalar version is attempted
26580         before vectorization of the inner loop in scalar version.  If
26581         outer LOOP_VECTORIZED guarded loop is not vectorized, prevent
26582         vectorization of its inner loop.
26583         * tree-vect-loop-manip.c (rename_variables_in_bb): If outer_loop
26584         has 2 inner loops, rename also on edges from bb whose single pred
26585         is outer_loop->header.  Fix typo in function comment.
26587 2017-01-09  Martin Sebor  <msebor@redhat.com>
26589         PR bootstrap/79033
26590         * asan.c (asan_emit_stack_protection): Increase local buffer size
26591         to avoid snprintf truncation warning.
26593 2017-01-09  Andrew Pinski  <apinski@cavium.com>
26595         * config/aarch64/aarch64-cores.def: Add thunderx2t99.  Change vulcan
26596         to reference thunderx2t99 for the tuning structure
26597         * config/aarch64/aarch64-cost-tables.h (vulcan_extra_costs):
26598         Rename to ...
26599         (thunderx2t99_extra_costs): This.
26600         * config/aarch64/aarch64-tune.md: Regenerate.
26601         * config/aarch64/aarch64.c (vulcan_addrcost_table): Rename to ...
26602         (vulcan_addrcost_table): This.
26603         (vulcan_regmove_cost): Rename to ...
26604         (thunderx2t99_regmove_cost): This.
26605         (vulcan_vector_cost): Rename to ...
26606         (thunderx2t99_vector_cost): this.
26607         (vulcan_branch_cost): Rename to ...
26608         (thunderx2t99_branch_cost): This.
26609         (vulcan_tunings): Rename to ...
26610         (thunderx2t99_tunings): This and s/vulcan/thunderx2t99 .
26611         * doc/invoke.texi (AARCH64/mtune): Add thunderx2t99.
26613 2017-01-09  Martin Jambor  <mjambor@suse.cz>
26615         PR ipa/78365
26616         PR ipa/78599
26617         * ipa-prop.h (ipa_jump_func): Swap positions of vr_known and m_vr.
26618         * ipa-cp.c (ipa_vr_operation_and_type_effects): New function.
26619         (propagate_vr_accross_jump_function): Use the above function for all
26620         value range computations for pass-through jump functions and type
26621         converasion from explicit value range values.
26622         (ipcp_propagate_stage): Do not attempt to deduce types of formal
26623         parameters from TYPE_ARG_TYPES.
26624         * ipa-prop.c (ipa_write_jump_function): Remove trailing whitespace.
26625         (ipa_write_node_info): Stream type of the actual argument.
26626         (ipa_read_node_info): Likewise. Also remove trailing whitespace.
26628 2017-01-09  Martin Liska  <mliska@suse.cz>
26630         PR pch/78970
26631         * gcc.c (driver_handle_option): Handle OPT_E and set have_E.
26632         (lookup_compiler): Do not show error message with have_E.
26634 2017-01-09  Jakub Jelinek  <jakub@redhat.com>
26636         PR tree-optimization/78938
26637         * tree-vect-stmts.c (vectorizable_condition): For non-masked COND_EXPR
26638         where comp_vectype is VECTOR_BOOLEAN_TYPE_P, use
26639         BIT_{NOT,XOR,AND,IOR}_EXPR on the comparison operands instead of
26640         {EQ,NE,GE,GT,LE,LT}_EXPR directly inside of VEC_COND_EXPR.  Formatting
26641         fixes.
26643 2017-01-09  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
26645         * tree-ssa-address.c (gen_addr_rtx): Don't handle index if it
26646         is const0_rtx.
26648 2017-01-09  Richard Biener  <rguenther@suse.de>
26650         PR tree-optimization/78997
26651         * tree-vect-slp.c (vect_mask_constant_operand_p): Handle SSA
26652         name condition properly.
26654 2017-01-09  Richard Biener  <rguenther@suse.de>
26656         PR debug/79000
26657         * dwarf2out.c (is_cxx): New overload with context.
26658         (is_naming_typedef_decl): Use it.
26660 2017-01-08  Sandra Loosemore  <sandra@codesourcery.com>
26662         * invoke.texi (Option Summary): Correct spacing in option lists
26663         and add line breaks to fix over-long lines.
26665 2017-01-08  Sandra Loosemore  <sandra@codesourcery.com>
26667         PR middle-end/17660
26669         * extend.texi (Common Variable Attributes): Add xref to GCC
26670         Internals manual to explain mode attribute keywords.
26672 2017-01-08  Sandra Loosemore  <sandra@codesourcery.com>
26674         PR other/16519
26675         * doc/invoke.texi (Option Summary): Move -pthread to Linker Options
26676         and Preprocessor Options.
26677         (Options for Linking): Document -pthread here....
26678         (RS/6000 and PowerPC Options): ...not here.
26679         (Solaris 2 Options): ...or here.
26680         * doc/cppopts.texi: Document -pthread.
26682 2017-01-08  Martin Sebor  <msebor@redhat.com>
26684         PR middle-end/77708
26685         * doc/invoke.texi (Warning Options): Document -Wformat-truncation.
26686         * gimple-ssa-sprintf.c (call_info::reval_used, call_info::warnopt):
26687         New member functions.
26688         (format_directive): Used them.
26689         (add_bytes): Same.
26690         (pass_sprintf_length::handle_gimple_call): Same.
26691         * graphite-sese-to-poly.c (tree_int_to_gmp): Increase buffer size
26692         to avoid truncation for any argument.
26693         (extract_affine_mul): Same.
26694         * tree.c (get_file_function_name): Same.
26696 2017-01-01  Jan Hubicka  <hubicka@ucw.cz>
26698         PR middle-end/77484
26699         * predict.def (PRED_INDIR_CALL): Set to 86.
26701 2017-01-07  Sandra Loosemore  <sandra@codesourcery.com>
26703         PR preprocessor/54124
26704         * doc/cppopts.texi: Reformat -d subtable to list the full name
26705         of the options.  Add cross-reference to the docs for the general
26706         compiler -d options.
26707         * doc/invoke.texi (Developer Options): Add cross-reference to the
26708         preprocessor-specific -d option documentation.
26710 2017-01-07  Sandra Loosemore  <sandra@codesourcery.com>
26712         PR preprocessor/13498
26713         * doc/cpp.texi (Search Path): Rewrite to remove obsolete and
26714         redudant material, and reflect new command-line options.
26715         (System Headers): Likewise.
26717 2017-01-07  Sandra Loosemore  <sandra@codesourcery.com>
26719         * doc/cppdiropts.texi: Merge documentation of -I, -iquote,
26720         -isystem, and -idirafter.  Copy-edit.
26721         * doc/cppopts.texi: Copy-edit.  Remove contradiction about
26722         default for -ftrack-macro-expansion.  Delete obsolete and
26723         badly-formatted implementation details about -fdebug-cpp output.
26724         * doc/cppwarnopts.texi: Copy-edit.
26726 2017-01-07  David Malcolm  <dmalcolm@redhat.com>
26728         PR c++/72803
26729         * input.c (selftest::test_accessing_ordinary_linemaps): Verify
26730         that the transition from a max line width >= 1<<10 to narrower
26731         lines works correctly.
26733 2017-01-07  Alexandre Oliva <aoliva@redhat.com>
26735         * doc/options.texi (PerFunction): New.
26736         * opt-functions.awk (switch_flags): Map both Optimization and
26737         PerFunction to CL_OPTIMIZATION.
26738         * opth-gen.awk: Test for PerFunction flag along with
26739         Optimization.
26740         * optc-save-gen.awk: Likewise.  Introduce var_opt_hash and set
26741         it only when the latter is present.  Skip those that don't in
26742         the hash function generator.
26743         * common.opt (fvar-tracking): Mark as PerFunction instead of
26744         Optimization.
26745         (fvar-tracking-assignments): Likewise.
26746         (fvar-tracking-assignments-toggle): Likewise.
26747         (fvar-tracking-uninit): Likewise.
26749 2017-01-07  Jakub Jelinek  <jakub@redhat.com>
26751         PR translation/79018
26752         * params.def (PARAM_MAX_STORES_TO_MERGE): Add missing space between
26753         the and store.
26755 2017-01-06  Mikael Pettersson  <mikpelinux@gmail.com>
26757         PR target/57583
26758         * config/m68k/m68k.opt (LONG_JUMP_TABLE_OFFSETS): New option.
26759         * config/m68k/linux.h (ASM_RETURN_CASE_JUMP): Handle
26760         TARGET_LONG_JUMP_TABLE_OFFSETS.
26761         * config/m68k/m68kelf.h (ASM_RETURN_CASE_JUMP): Likewise.
26762         * config/m68k/netbsd-elf.h (ASM_RETURN_CASE_JUMP): Likewise.
26763         * config/m68k/m68k.h (CASE_VECTOR_MODE): Likewise.
26764         (ASM_OUTPUT_ADDR_DIFF_ELF): Likewise.
26765         * config/m68k/m68k.md (tablejump expander): Likewise.
26766         (*tablejump_pcrel_hi): Renamed from unnamed insn, reject
26767         TARGET_LONG_JUMP_TABLE_OFFSETS.
26768         (*tablejump_pcrel_si): New insn, handle TARGET_LONG_JUMP_TABLE_OFFSETS.
26769         * doc/invoke.texi (M68K options): Add -mlong-jump-table-offsets.
26771 2017-01-06  Edgar E. Iglesias <edgar.iglesias@xilinx.com>
26772             David Holsgrove <david.holsgrove@xilinx.com>
26774         * common/config/microblaze/microblaze-common.c
26775         (TARGET_EXCEPT_UNWIND_INFO): Remove.
26776         * config/microblaze/microblaze-protos.h (microblaze_eh_return):
26777         New prototype.
26778         * config/microblaze/microblaze.c (microblaze_must_save_register)
26779         (microblaze_expand_epilogue, microblaze_return_addr): Handle
26780         calls_eh_return.
26781         (microblaze_eh_return): New function.
26782         * config/microblaze/microblaze.h (RETURN_ADDR_OFFSET)
26783         (EH_RETURN_DATA_REGNO, MB_EH_STACKADJ_REGNUM)
26784         (EH_RETURN_STACKADJ_RTX, ASM_PREFERRED_EH_DATA_FORMAT): New macros.
26785         * config/microblaze/microblaze.md (eh_return): New pattern.
26787 2017-01-06  Jakub Jelinek  <jakub@redhat.com>
26789         * system.h (GCC_DIAGNOSTIC_PUSH_IGNORED, GCC_DIAGNOSTIC_POP,
26790         GCC_DIAGNOSTIC_STRINGIFY): Define.
26792         * read-rtl.c (rtx_reader::read_rtx_code): Avoid -Wsign-compare warning.
26794 2017-01-06  Andre Vieira  <andre.simoesdiasvieira@arm.com>
26796         * config/arm/arm.md (<mcrr>): New.
26797         (<mrrc>): New.
26798         * config/arm/arm.c (arm_arch5te): New.
26799         (arm_option_override): Set arm_arch5te.
26800         (arm_coproc_builtin_available): Add support for mcrr, mcrr2, mrrc
26801         and mrrc2.
26802         * config/arm/arm-builtins.c (MCRR_QUALIFIERS): Define to...
26803         (arm_mcrr_qualifiers): ... this. New.
26804         (MRRC_QUALIFIERS): Define to...
26805         (arm_mrrc_qualifiers): ... this. New.
26806         * config/arm/arm_acle.h (__arm_mcrr, __arm_mcrr2, __arm_mrrc,
26807         __arm_mrrc2): New.
26808         * config/arm/arm_acle_builtins.def (mcrr, mcrr2, mrrc, mrrc2): New.
26809         * config/arm/iterators.md (MCRRI, mcrr, MCRR): New.
26810         (MRRCI, mrrc, MRRC): New.
26811         * config/arm/unspecs.md (VUNSPEC_MCRR, VUNSPEC_MCRR2, VUNSPEC_MRRC,
26812         VUNSPEC_MRRC2): New.
26814 2017-01-06  Andre Vieira  <andre.simoesdiasvieira@arm.com>
26816         * config/arm/arm.md (<mcr>): New.
26817         (<mrc>): New.
26818         * config/arm/arm.c (arm_coproc_builtin_available): Add
26819         support for mcr, mrc, mcr2 and mrc2.
26820         * config/arm/arm-builtins.c (MCR_QUALIFIERS): Define to...
26821         (arm_mcr_qualifiers): ... this. New.
26822         (MRC_QUALIFIERS): Define to ...
26823         (arm_mrc_qualifiers): ... this. New.
26824         (MCR_QUALIFIERS): Define to ...
26825         (arm_mcr_qualifiers): ... this. New.
26826         * config/arm/arm_acle.h (__arm_mcr, __arm_mrc, __arm_mcr2,
26827         __arm_mrc2): New.
26828         * config/arm/arm_acle_builtins.def (mcr, mcr2, mrc, mrc2): New.
26829         * config/arm/iterators.md (MCRI, mcr, MCR, MRCI, mrc, MRC): New.
26830         * config/arm/unspecs.md (VUNSPEC_MCR, VUNSPEC_MCR2, VUNSPEC_MRC,
26831         VUNSPEC_MRC2): New.
26833 2017-01-06  Andre Vieira  <andre.simoesdiasvieira@arm.com>
26835         * config/arm/arm.md (*ldc): New.
26836         (*stc): New.
26837         (<ldc>): New.
26838         (<stc>): New.
26839         * config/arm/arm.c (arm_coproc_builtin_available): Add
26840         support for ldc,ldcl,stc,stcl,ldc2,ldc2l,stc2 and stc2l.
26841         (arm_coproc_ldc_stc_legitimate_address): New.
26842         * config/arm/arm-builtins.c (arm_type_qualifiers): Add
26843         'qualifier_const_pointer'.
26844         (LDC_QUALIFIERS): Define to...
26845         (arm_ldc_qualifiers): ... this. New.
26846         (STC_QUALIFIERS): Define to...
26847         (arm_stc_qualifiers): ... this. New.
26848         * config/arm/arm-protos.h
26849         (arm_coproc_ldc_stc_legitimate_address): New.
26850         * config/arm/arm_acle.h (__arm_ldc, __arm_ldcl, __arm_stc,
26851         __arm_stcl, __arm_ldc2, __arm_ldc2l, __arm_stc2, __arm_stc2l): New.
26852         * config/arm/arm_acle_builtins.def (ldc, ldc2, ldcl, ldc2l, stc,
26853         stc2, stcl, stc2l): New.
26854         * config/arm/constraints.md (Uz): New.
26855         * config/arm/iterators.md (LDCI, STCI, ldc, stc, LDC STC): New.
26856         * config/arm/unspecs.md (VUNSPEC_LDC, VUNSPEC_LDC2, VUNSPEC_LDCL,
26857         VUNSPEC_LDC2L, VUNSPEC_STC, VUNSPEC_STC2, VUNSPEC_STCL,
26858         VUNSPEC_STC2L): New.
26860 2017-01-06  Andre Vieira  <andre.simoesdiasvieira@arm.com>
26862         * config/arm/arm.md (<cdp>): New.
26863         * config/arm/arm.c (neon_const_bounds): Rename this ...
26864         (arm_const_bounds): ... this.
26865         (arm_coproc_builtin_available): New.
26866         * config/arm/arm-builtins.c (SIMD_MAX_BUILTIN_ARGS): Increase.
26867         (arm_type_qualifiers): Add 'qualifier_unsigned_immediate'.
26868         (CDP_QUALIFIERS): Define to...
26869         (arm_cdp_qualifiers): ... this. New.
26870         (void_UP): Define.
26871         (arm_expand_builtin_args): Add case for 6 arguments.
26872         * config/arm/arm-protos.h (neon_const_bounds): Rename this ...
26873         (arm_const_bounds): ... this.
26874         (arm_coproc_builtin_available): New.
26875         * config/arm/arm_acle.h (__arm_cdp): New.
26876         (__arm_cdp2): New.
26877         * config/arm/arm_acle_builtins.def (cdp): New.
26878         (cdp2): New.
26879         * config/arm/iterators.md (CDPI,CDP,cdp): New.
26880         * config/arm/neon.md: Rename all 'neon_const_bounds' to
26881         'arm_const_bounds'.
26882         * config/arm/types.md (coproc): New.
26883         * config/arm/unspecs.md (VUNSPEC_CDP, VUNSPEC_CDP2): New.
26884         * doc/extend.texi (ACLE): Add a mention of Coprocessor intrinsics.
26885         * doc/sourcebuild.texi (arm_coproc1_ok, arm_coproc2_ok,
26886         arm_coproc3_ok, arm_coproc4_ok): Document new effective targets.
26888 2017-01-06  Andre Vieira  <andre.simoesdiasvieira@arm.com>
26890         * config/arm/arm-builtins.c (arm_unsigned_binop_qualifiers): New.
26891         (UBINOP_QUALIFIERS): New.
26892         (si_UP): Define.
26893         (acle_builtin_data): New. Change comment.
26894         (arm_builtins): Remove ARM_BUILTIN_CRC32B, ARM_BUILTIN_CRC32H,
26895         ARM_BUILTIN_CRC32W, ARM_BUILTIN_CRC32CB, ARM_BUILTIN_CRC32CH,
26896         ARM_BUILTIN_CRC32CW. Add ARM_BUILTIN_ACLE_BASE and include
26897         arm_acle_builtins.def.
26898         (ARM_BUILTIN_ACLE_PATTERN_START): Define.
26899         (arm_init_acle_builtins): New.
26900         (CRC32_BUILTIN): Remove.
26901         (bdesc_2arg): Remove entries for crc32b, crc32h, crc32w,
26902         crc32cb, crc32ch and crc32cw.
26903         (arm_init_crc32_builtins): Remove.
26904         (arm_init_builtins): Use arm_init_acle_builtins rather
26905         than arm_init_crc32_builtins.
26906         (arm_expand_acle_builtin): New.
26907         (arm_expand_builtin): Use 'arm_expand_acle_builtin'.
26908         * config/arm/arm_acle_builtins.def: New.
26910 2017-01-06  Andre Vieira  <andre.simoesdiasvieira@arm.com>
26912         * config/arm/arm-builtins.c (neon_builtin_datum): Rename to ..
26913         (arm_builtin_datum): ... this.
26914         (arm_init_neon_builtin): Rename to ...
26915         (arm_init_builtin): ... this. Add a new parameters PREFIX
26916         and USE_SIG_IN_NAME.
26917         (arm_init_neon_builtins): Replace 'arm_init_neon_builtin' with
26918         'arm_init_builtin'. Replace type 'neon_builtin_datum' with
26919         'arm_builtin_datum'.
26920         (arm_init_vfp_builtins): Likewise.
26921         (builtin_arg): Rename enum's replacing 'NEON_ARG' with
26922         'ARG_BUILTIN' and add a 'ARG_BUILTIN_NEON_MEMORY.
26923         (arm_expand_neon_args): Rename to ...
26924         (arm_expand_builtin_args): ... this. Rename builtin_arg
26925         enum values and differentiate between ARG_BUILTIN_MEMORY
26926         and ARG_BUILTIN_NEON_MEMORY.
26927         (arm_expand_neon_builtin_1): Rename to ...
26928         (arm_expand_builtin_1): ... this. Rename builtin_arg enum
26929         values, arm_expand_builtin_args and add bool parameter NEON.
26930         (arm_expand_neon_builtin): Use arm_expand_builtin_1.
26931         (arm_expand_vfp_builtin): Likewise.
26932         (NEON_MAX_BUILTIN_ARGS): Remove, it was unused.
26934 2017-01-01  Jan Hubicka  <hubicka@ucw.cz>
26936         PR middle-end/77484
26937         * predict.def (PRED_POLYMORPHIC_CALL): Set to 59.
26938         * predict.c (tree_estimate_probability_bb): Reverse direction of
26939         polymorphic call predictor.
26941 2017-01-06  David Malcolm  <dmalcolm@redhat.com>
26943         * passes.c (execute_one_pass): Split out pass-skipping logic into...
26944         (determine_pass_name_match): ...this new function and...
26945         (should_skip_pass_p): ...this new function.
26947 2017-01-06  Nathan Sidwell  <nathan@acm.org>
26949         * ipa-visibility.c (function_and_variable_visibility): Reformat
26950         comments and long lines.  Remove extrneous if.
26951         * symtab.c (symtab_node::make_decl_local): Fix code format.
26952         (symtab_node::set_section_for_node): Fix comment typo.
26954 2017-01-06  Martin Liska  <mliska@suse.cz>
26956         PR bootstrap/79003
26957         * lra-constraints.c: Rename invariant to lra_invariant.
26958         * predict.c (set_even_probabilities): Initialize e to NULL.
26960 2017-01-05  Martin Sebor  <msebor@redhat.com>
26962         PR tree-optimization/78910
26963         * gimple-ssa-sprintf.c (tree_digits): Add an argument.
26964         (format_integer): Correct off-by-one error in the handling
26965         of precision with negative numbers in signed conversions..
26967 2017-01-05  Eric Botcazou  <ebotcazou@adacore.com>
26969         * doc/invoke.texi (C Dialect Options): Adjust -fsso-struct entry.
26971 2017-01-05  Jakub Jelinek  <jakub@redhat.com>
26973         PR tree-optimization/71016
26974         * tree-ssa-phiopt.c (tree_ssa_phiopt_worker): Pass cond_stmt to
26975         factor_out_conditional_conversion.  Formatting fix.
26976         (factor_out_conditional_conversion): Add cond_stmt argument.
26977         If arg1 is INTEGER_CST, punt if new_arg0 is not any operand of
26978         cond_stmt and if arg0_def_stmt is not the only stmt in its bb.
26979         Formatting fix.
26981 2017-01-05  David Malcolm  <dmalcolm@redhat.com>
26983         * Makefile.in (OBJS): Add read-md.o, read-rtl.o,
26984         read-rtl-function.o, and selftest-rtl.o.
26985         * config/aarch64/aarch64.c: Include selftest.h and selftest-rtl.h.
26986         (selftest::aarch64_test_loading_full_dump): New function.
26987         (selftest::aarch64_run_selftests): New function.
26988         (TARGET_RUN_TARGET_SELFTESTS): Wire it up to
26989         selftest::aarch64_run_selftests.
26990         * config/i386/i386.c
26991         (selftest::ix86_test_loading_dump_fragment_1): New function.
26992         (selftest::ix86_test_loading_call_insn): New function.
26993         (selftest::ix86_test_loading_full_dump): New function.
26994         (selftest::ix86_test_loading_unspec): New function.
26995         (selftest::ix86_run_selftests): Call the new functions.
26996         * emit-rtl.c (maybe_set_max_label_num): New function.
26997         * emit-rtl.h (maybe_set_max_label_num): New decl.
26998         * function.c (instantiate_decls): Guard call to
26999         instantiate_decls_1 with if (DECL_INITIAL (fndecl)).
27000         * function-tests.c (selftest::verify_three_block_rtl_cfg): Remove
27001         "static".
27002         * gensupport.c (gen_reader::gen_reader): Pass "false"
27003         for new "compact" param of rtx_reader.
27004         * print-rtl.c (rtx_writer::print_rtx_operand): Print "(nil)"
27005         rather than an empty string for NULL strings.
27006         * read-md.c: Potentially include config.h rather than bconfig.h.
27007         Wrap include of errors.h with #ifdef GENERATOR_FILE.
27008         (have_error): New global, copied from errors.c.
27009         (md_reader::read_name): Rename to...
27010         (md_reader::read_name_1): ...this, adding "out_loc" param,
27011         and converting "missing name or number" to returning false, rather
27012         than failing.
27013         (md_reader::read_name): Reimplement in terms of read_name_1.
27014         (md_reader::read_name_or_nil): New function.
27015         (md_reader::read_string): Handle "(nil)" by returning NULL.
27016         (md_reader::md_reader): Add new param "compact".
27017         (md_reader::read_md_files): Wrap with #ifdef GENERATOR_FILE.
27018         (md_reader::read_file): New method.
27019         * read-md.h (md_reader::md_reader): Add new param "compact".
27020         (md_reader::read_file): New method.
27021         (md_reader::is_compact): New accessor.
27022         (md_reader::read_name): Convert return type from void to file_location.
27023         (md_reader::read_name_or_nil): New decl.
27024         (md_reader::read_name_1): New decl.
27025         (md_reader::m_compact): New field.
27026         (noop_reader::noop_reader): Pass "false" for new "compact" param
27027         of rtx_reader.
27028         (rtx_reader::rtx_reader): Add new "compact" param.
27029         (rtx_reader::read_rtx_operand): Make virtual and convert return
27030         type from void to rtx.
27031         (rtx_reader::read_until): New decl.
27032         (rtx_reader::handle_any_trailing_information): New virtual function.
27033         (rtx_reader::postprocess): New virtual function.
27034         (rtx_reader::finalize_string): New virtual function.
27035         (rtx_reader::m_in_call_function_usage): New field.
27036         (rtx_reader::m_reuse_rtx_by_id): New field.
27037         * read-rtl-function.c: New file.
27038         * selftest-rtl.c (selftest::assert_rtx_ptr_eq_at): New function.
27039         * selftest-rtl.h (ASSERT_RTX_PTR_EQ): New macro.
27040         (selftest::verify_three_block_rtl_cfg): New decl.
27041         * read-rtl-function.h: New file.
27042         * read-rtl.c: Potentially include config.h rather than bconfig.h.
27043         For host, include function.h, memmodel.h, and emit-rtl.h.
27044         (one_time_initialization): New function.
27045         (struct compact_insn_name): New struct.
27046         (compact_insn_names): New array.
27047         (find_code): Handle insn codes in compact dumps.
27048         (apply_subst_iterator): Wrap with #ifdef GENERATOR_FILE.
27049         (bind_subst_iter_and_attr): Likewise.
27050         (add_condition_to_string): Likewise.
27051         (add_condition_to_rtx): Likewise.
27052         (apply_attribute_uses): Likewise.
27053         (add_current_iterators): Likewise.
27054         (apply_iterators): Likewise.
27055         (initialize_iterators): Guard usage of apply_subst_iterator with
27056         #ifdef GENERATOR_FILE.
27057         (read_conditions): Wrap with #ifdef GENERATOR_FILE.
27058         (md_reader::read_mapping): Likewise.
27059         (add_define_attr_for_define_subst): Likewise.
27060         (add_define_subst_attr): Likewise.
27061         (read_subst_mapping): Likewise.
27062         (check_code_iterator): Likewise.
27063         (rtx_reader::read_rtx): Likewise.  Move one-time initialization
27064         logic to...
27065         (one_time_initialization): New function.
27066         (rtx_reader::read_until): New method.
27067         (read_flags): New function.
27068         (parse_reg_note_name): New function.
27069         (rtx_reader::read_rtx_code): Initialize "iterator" to NULL.
27070         Handle reuse_rtx ids.
27071         Wrap iterator lookup within #ifdef GENERATOR_FILE.
27072         Add parsing support for RTL dumps, mirroring the special-cases in
27073         print_rtx, by calling read_flags, reading REG_NOTE names, INSN_UID
27074         values, and calling handle_any_trailing_information.
27075         (rtx_reader::read_rtx_operand): Convert return type from void
27076         to rtx, returning return_rtx.  Handle case 'e'.  Call
27077         finalize_string on XSTR and XTMPL fields.
27078         (rtx_reader::read_nested_rtx):  Handle dumps in which trailing
27079          "(nil)" values were omitted.  Call the postprocess vfunc on the
27080         return_rtx.
27081         (rtx_reader::rtx_reader): Add new "compact" param and pass to base
27082         class ctor.  Initialize m_in_call_function_usage.  Call
27083         one_time_initialization.
27084         * rtl-tests.c (selftest::test_uncond_jump): Call
27085         set_new_first_and_last_insn.
27086         * rtl.h (read_rtx): Wrap decl with #ifdef GENERATOR_FILE.
27087         * selftest-rtl.c: New file.
27088         * selftest-rtl.h (class selftest::rtl_dump_test): New class.
27089         (selftest::get_insn_by_uid): New decl.
27090         * selftest-run-tests.c (selftest::run_tests): Call
27091         read_rtl_function_c_tests.
27092         * selftest.h  (selftest::read_rtl_function_c_tests): New decl.
27093         * tree-dfa.c (ssa_default_def): Return NULL_TREE for rtl function
27094         dumps.
27096 2017-01-05  Uros Bizjak  <ubizjak@gmail.com>
27098         * config/i386/i386.md (*testqi_ext_3): No need to handle memory
27099         operands in a special way.  Assert that pos+len <= mode precision.
27101 2017-01-05  Jakub Jelinek  <jakub@redhat.com>
27103         * common.opt (fvect-cost-model): Remove RejectNegative flag, use
27104         3 argument Alias with unlimited for the negative form.
27105         (fno-vect-cost-model): Removed.
27107 2017-01-05  Martin Liska  <mliska@suse.cz>
27109         * hsa-gen.c (gen_hsa_divmod): New function.
27110         (gen_hsa_insn_for_internal_fn_call): Use the function for IFN_DIVMOD.
27112 2017-01-05  Martin Liska  <mliska@suse.cz>
27114         PR pch/78970
27115         * gcc.c (lookup_compiler): Reject '-' filename for a precompiled
27116         header.
27118 2017-01-05  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
27120         * config/s390/s390.c (s390_expand_setmem): Unroll the loop for
27121         small constant length operands.
27123 2017-01-05  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
27125         * config/s390/s390.c (s390_expand_setmem): Avoid overlapping bytes
27126         between loop iterations.
27128 2017-01-05  Martin Liska  <mliska@suse.cz>
27130         PR sanitizer/78815
27131         * gimplify.c (gimplify_decl_expr): Compare to
27132         asan_poisoned_variables instread of checking flags.
27133         (gimplify_target_expr): Likewise.
27134         (gimplify_expr): Likewise.
27135         (gimplify_function_tree): Conditionally initialize
27136         asan_poisoned_variables.
27138 2017-01-04  Jeff Law  <law@redhat.com>
27140         PR tree-optimizatin/78812
27141         * rtl.h (contains_mem_rtx_p): Prototype.
27142         * ifcvt.c (containts_mem_rtx_p): Move from here to...
27143         * rtlanal.c (contains_mem_rtx_p): Here and remove static linkage.
27144         * gcse.c (prune_expressions): Use contains_mem_rtx_p to discover
27145         and prune MEMs that are not at the toplevel of a SET_SRC rtx.  Look
27146         through ZERO_EXTEND and SIGN_EXTEND when trying to avoid pruning MEMs.
27148 2017-01-04  Alexandre Oliva <aoliva@redhat.com>
27150         * input.c (assert_char_at_range): Default-initialize actual_range.
27152 2017-01-04  Alexandre Oliva <aoliva@redhat.com>
27154         * df-scan.c (df_ref_create_structure): Make regno unsigned,
27155         to match the caller.
27157 2017-01-04  Alexandre Oliva <aoliva@redhat.com>
27159         * cfgexpand.c (expand_gimple_basic_block): Disregard debug
27160         insns after final jump in test to emit dummy move.
27162 2017-01-04  Alexandre Oliva <aoliva@redhat.com>
27164         * gimple-iterator.h (gsi_one_nondebug_before_end_p): New.
27165         * tree-eh.c (cleanup_empty_eh): Skip more debug stmts.
27167 2017-01-04  Alexandre Oliva <aoliva@redhat.com>
27169         * multiple_target.c (create_dispatcher_calls): Init e_next.
27170         * tree-ssa-loop-split.c (split_loop): Init border.
27171         * tree-vect-loop.c (vect_determine_vectorization_factor): Init
27172         scalar_type.
27174 2017-01-04  Michael Meissner  <meissner@linux.vnet.ibm.com>
27176         PR target/71977
27177         PR target/70568
27178         PR target/78823
27179         * config/rs6000/predicates.md (sf_subreg_operand): New predicate.
27180         (altivec_register_operand): Do not return true if the operand
27181         contains a SUBREG mixing SImode and SFmode.
27182         (vsx_register_operand): Likewise.
27183         (vsx_reg_sfsubreg_ok): New predicate.
27184         (vfloat_operand): Do not return true if the operand contains a
27185         SUBREG mixing SImode and SFmode.
27186         (vint_operand): Likewise.
27187         (vlogical_operand): Likewise.
27188         (gpc_reg_operand): Likewise.
27189         (int_reg_operand): Likewise.
27190         * config/rs6000/rs6000-protos.h (valid_sf_si_move): Add declaration.
27191         * config/rs6000/rs6000.c (valid_sf_si_move): New function to
27192         determine if a MOVSI or MOVSF operation contains SUBREGs that mix
27193         SImode and SFmode.
27194         (rs6000_emit_move_si_sf_subreg): New helper function.
27195         (rs6000_emit_move): Call rs6000_emit_move_si_sf_subreg to possbily
27196         fixup SUBREGs involving SImode and SFmode.
27197         * config/rs6000/vsx.md (SFBOOL_*): New constants that are operand
27198         numbers for the new peephole2 optimization.
27199         (peephole2 for SFmode unions): New peephole2 to optimize cases in
27200         the GLIBC math library that do AND/IOR/XOR operations on single
27201         precision floating point.
27202         * config/rs6000/rs6000.h (TARGET_NO_SF_SUBREG): New internal
27203         target macros to say whether we need to avoid SUBREGs mixing
27204         SImode and SFmode.
27205         (TARGET_ALLOW_SF_SUBREG): Likewise.
27206         * config/rs6000/rs6000.md (UNSPEC_SF_FROM_SI): New unspecs.
27207         (UNSPEC_SI_FROM_SF): Likewise.
27208         (iorxor): Change spacing.
27209         (and_ior_xor): New iterator for AND, IOR, and XOR.
27210         (movsi_from_sf): New insns for SImode/SFmode SUBREG support.
27211         (movdi_from_sf_zero_ext): Likewise.
27212         (mov<mode>_hardfloat, FMOVE32 iterator): Use register_operand
27213         instead of gpc_reg_operand.  Add SImode/SFmode SUBREG support.
27214         (movsf_from_si): New insn for SImode/SFmode SUBREG support.
27215         (fma<mode>4): Use gpc_reg_operand instead of register_operand.
27216         (fms<mode>4): Likewise.
27217         (fnma<mode>4): Likewise.
27218         (fnms<mode>4): Likewise.
27219         (nfma<mode>4): Likewise.
27220         (nfms<mode>4): Likewise.
27222 2017-01-04  Marek Polacek  <polacek@redhat.com>
27224         PR c++/64767
27225         * doc/invoke.texi: Document -Wpointer-compare.
27227 2017-01-04  Jakub Jelinek  <jakub@redhat.com>
27229         * optc-gen.awk: Emit #error for -W*/-f*/-m* Enum without
27230         RejectNegative.
27232         * dwarf2out.c (output_loc_list): Don't throw away 64K+ location
27233         descriptions for -gdwarf-5 and emit them as uleb128 instead of
27234         2-byte data.
27236 2017-01-04  Kelvin Nilsen  <kelvin@gcc.gnu.org>
27238         PR target/78056
27239         * doc/sourcebuild.texi (PowerPC-specific attributes): Add
27240         documentation of the powerpc_popcntb_ok attribute.
27241         * config/rs6000/rs6000.c (rs6000_option_override_internal): Add
27242         code to issue warning messages if a requested CPU configuration is
27243         not supported by the binary (assembler and loader) toolchain.
27244         (spe_init_builtins): Add two assertions to prevent ICE if attempt is
27245         made to define a built-in function that has been disabled.
27246         (paired_init_builtins): Add assertion to prevent ICE if attempt is
27247         made to define a built-in function that has been disabled.
27248         (altivec_init_builtins): Add comment explaining why definition
27249         of the DST built-in functions is not preceded by an assertion
27250         check.  Add assertions to prevent ICE if attempts are made to
27251         define an altivec predicate or an abs* built-in function that has
27252         been disabled.
27253         (htm_init_builtins): Add comment explaining why definition of the
27254         htm built-in functions is not preceded by an assertion check.
27256 2017-01-04  Jeff Law  <law@redhat.com>
27258         PR tree-optimizatin/67955
27259         * tree-ssa-alias.c (same_addr_size_stores_p): Check offsets first.
27260         Allow any SSA_VAR_P as the base objects.  Use integer_zerop.  Verify
27261         the points-to solution does not include pt_null.  Use DECL_PT_UID
27262         unconditionally.
27264 2017-01-04  Uros Bizjak  <ubizjak@gmail.com>
27266         * config/i386/i386.md (HI/SImode test with imm to QImode splitters):
27267         Use gen_int_mode instead of gen_lopwart for const_int operands.
27269 2017-01-04  Jakub Jelinek  <jakub@redhat.com>
27271         PR tree-optimization/71563
27272         * match.pd: Simplify X << Y into X if Y is known to be 0 or
27273         out of range value - has low bits known to be zero.
27275 2017-01-04  Alan Modra  <amodra@gmail.com>
27277         * Makefile.in (aclocal_deps): Update and order as per aclocal.m4.
27278         * configure: Regenerate.
27279         * config.in: Regenerate.
27281 2017-01-04  Jakub Jelinek  <jakub@redhat.com>
27283         PR bootstrap/77569
27284         * input.c (ebcdic_execution_charset::on_error): Don't use strstr for
27285         a substring of the message, but strcmp with the whole message.  Ifdef
27286         ENABLE_NLS, translate the message first using dgettext.
27288 2017-01-03  Jeff Law  <law@redhat.com>
27290         PR tree-optimizatin/78856
27291         * tree-ssa-threadupdate.c: Include tree-vectorizer.h.
27292         (mark_threaded_blocks): Remove code to truncate thread paths that
27293         cross multiple loop headers.  Instead invalidate the cached loop
27294         iteration information and handle case of a thread path walking
27295         into an irreducible region.
27297 2017-01-03  Michael Meissner  <meissner@linux.vnet.ibm.com>
27299         PR target/78900
27300         * config/rs6000/rs6000.c (rs6000_split_signbit): Change some
27301         assertions.  Add support for doing the signbit if the IEEE 128-bit
27302         floating point value is in a GPR.
27303         * config/rs6000/rs6000.md (Fsignbit): Delete.
27304         (signbit<mode>2_dm): Delete using <Fsignbit> and just use "wa".
27305         Update the length attribute if the value is in a GPR.
27306         (signbit<mode>2_dm_<su>ext): Add combiner pattern to eliminate
27307         the sign or zero extension instruction, since the value is always 0/1.
27308         (signbit<mode>2_dm2): Delete using <Fsignbit>.
27310         PR target/78953
27311         * config/rs6000/vsx.md (vsx_extract_<mode>_store_p9): If we are
27312         extracting SImode to a GPR register so that we can generate a
27313         store, limit the vector to be in a traditional Altivec register
27314         for the vextuwrx instruction.
27316 2017-01-03  Ian Lance Taylor  <iant@google.com>
27318         * godump.c (go_format_type): Treat ENUMERAL_TYPE like INTEGER_TYPE.
27320 2017-01-03  Martin Sebor  <msebor@redhat.com>
27322         PR tree-optimization/78696
27323         * gimple-ssa-sprintf.c (format_floating): Correct handling of
27324         precision.  Use MPFR for %f for greater fidelity.  Correct handling
27325         of %g.
27326         (pass_sprintf_length::compute_format_length): Set width and precision
27327         specified by asrerisk to void_node for vararg functions.
27328         (try_substitute_return_value): Adjust dump output.
27330 2017-01-03  David Edelsohn  <dje.gcc@gmail.com>
27332         * doc/invoke.texi (RS6000 options): LRA is enabled by default.
27334 2017-01-03  Eric Botcazou  <ebotcazou@adacore.com>
27336         * doc/invoke.texi (SPARC options): Document -mlra as the default.
27337         * config/sparc/sparc.c (sparc_option_override): Force LRA unless
27338         -mlra/-mno-lra was passed to the compiler.
27340 2017-01-03  James Cowgill  <James.Cowgill@imgtec.com>
27342         PR rtl-optimization/65618
27343         * emit-rtl.c (try_split): Move initialization of "before" and
27344         "after" to just before the call to emit_insn_after_setloc.
27346 2017-01-03  Gerald Pfeifer  <gerald@pfeifer.com>
27348         * doc/md.texi (Standard Names): Remove reference to Java frontend.
27350 2017-01-03  Pierre-Marie de Rodat  <derodat@adacore.com>
27352         * dwarf2out.c (gen_enumeration_type_die): When
27353         -gno-strict-dwarf, add a DW_AT_encoding attribute.
27355 2017-01-03  Jakub Jelinek  <jakub@redhat.com>
27357         PR tree-optimization/78965
27358         * gimple-ssa-sprintf.c (pass_sprintf_length::compute_format_length):
27359         Change first argument from const call_info & to call_info &.  For %n
27360         set info.nowrite to false.
27362         PR middle-end/78901
27363         * gimple-ssa-sprintf.c (try_substitute_return_value): Don't change
27364         possibly throwing calls.
27366         * genmatch.c (dt_node::gen_kids_1): If generic_exprs include SSA_NAME
27367         and exprs_len || fns_len, emit the code for SSA_NAME next to the exprs
27368         and fns handling, rather than in a separate case SSA_NAME.
27370 2017-01-02  Jeff Law  <law@redhat.com>
27372         * config/darwin-driver.c (darwin_driver_init): Const-correctness
27373         fixes for first_period and second_period variables.
27375 2017-01-02  Uros Bizjak  <ubizjak@gmail.com>
27377         PR target/78967
27378         * config/i386/i386.md (UNSPEC_NOREX_MEM): New unspec.
27379         (*insvqi_1): New insn pattern.
27380         (*insvqi_1_mem_rex64): Ditto.
27381         (*insvqi_2): Ditto.
27382         (*insvqi_3): Rename from *insvqi.
27384         (*extzvqi_mem_rex64): Add UNSPEC_NOREX_MEM tag.
27386 2017-01-02  Gerald Pfeifer  <gerald@pfeifer.com>
27388         * doc/cfg.texi (Edges): Remove reference to Java.
27389         (Maintaining the CFG): Ditto.
27391 2017-01-01  Jan Hubicka  <hubicka@ucw.cz>
27393         PR middle-end/77674
27394         * symtab.c (symtab_node::binds_to_current_def_p): Fix handling of
27395         transparent aliases.
27397 2017-01-01  Jan Hubicka  <hubicka@ucw.cz>
27399         PR middle-end/77484
27400         * predict.def (PRED_CALL): Update hitrate.
27401         (PRED_INDIR_CALL, PRED_POLYMORPHIC_CALL): New predictors.
27402         * predict.c (tree_estimate_probability_bb): Split CALL predictor
27403         into direct/indirect/polymorphic variants.
27405 2017-01-01  Jakub Jelinek  <jakub@redhat.com>
27407         Update copyright years.
27409         * gcc.c (process_command): Update copyright notice dates.
27410         * gcov-dump.c (print_version): Ditto.
27411         * gcov.c (print_version): Ditto.
27412         * gcov-tool.c (print_version): Ditto.
27413         * gengtype.c (create_file): Ditto.
27414         * doc/cpp.texi: Bump @copying's copyright year.
27415         * doc/cppinternals.texi: Ditto.
27416         * doc/gcc.texi: Ditto.
27417         * doc/gccint.texi: Ditto.
27418         * doc/gcov.texi: Ditto.
27419         * doc/install.texi: Ditto.
27420         * doc/invoke.texi: Ditto.
27422 Copyright (C) 2017 Free Software Foundation, Inc.
27424 Copying and distribution of this file, with or without modification,
27425 are permitted in any medium without royalty provided the copyright
27426 notice and this notice are preserved.