Use vec<> in build_vector
[official-gcc.git] / gcc / ChangeLog
blobb52eced6e1a6be862599dc9b3a114dbc51097af9
1 2017-09-14  Richard Sandiford  <richard.sandiford@linaro.org>
2             Alan Hayward  <alan.hayward@arm.com>
3             David Sherwood  <david.sherwood@arm.com>
5         * tree.h (build_vector): Take a vec<tree> instead of a tree *.
6         * tree.c (build_vector): Likewise.
7         (build_vector_from_ctor): Update accordingly.
8         (build_vector_from_val): Likewise.
9         * gimple-fold.c (gimple_fold_stmt_to_constant_1): Likewise.
10         * tree-ssa-forwprop.c (simplify_vector_constructor): Likewise.
11         * tree-vect-generic.c (add_rshift): Likewise.
12         (expand_vector_divmod): Likewise.
13         (optimize_vector_constructor): Likewise.
14         * tree-vect-slp.c (vect_get_constant_vectors): Likewise.
15         (vect_transform_slp_perm_load): Likewise.
16         (vect_schedule_slp_instance): Likewise.
17         * tree-vect-stmts.c (vectorizable_bswap): Likewise.
18         (vectorizable_call): Likewise.
19         (vect_gen_perm_mask_any): Likewise.  Add elements in order.
20         * expmed.c (make_tree): Likewise.
21         * fold-const.c (fold_negate_expr_1): Use auto_vec<tree> when building
22         a vector passed to build_vector.
23         (fold_convert_const): Likewise.
24         (exact_inverse): Likewise.
25         (fold_ternary_loc): Likewise.
26         (fold_relational_const): Likewise.
27         (const_binop): Likewise.  Use VECTOR_CST_ELT directly when operating
28         on VECTOR_CSTs, rather than going through vec_cst_ctor_to_array.
29         (const_unop): Likewise.  Store the reduction accumulator in a
30         variable rather than an array.
31         (vec_cst_ctor_to_array): Take the number of elements as a parameter.
32         (fold_vec_perm): Update calls accordingly.  Use auto_vec<tree> for
33         the new vector, rather than constructing it after the input arrays.
34         (native_interpret_vector): Use auto_vec<tree> when building
35         a vector passed to build_vector.  Add elements in order.
36         * tree-vect-loop.c (get_initial_defs_for_reduction): Use
37         auto_vec<tree> when building a vector passed to build_vector.
38         (vect_create_epilog_for_reduction): Likewise.
39         (vectorizable_induction): Likewise.
40         (get_initial_def_for_reduction): Likewise.  Fix indentation of
41         case statements.
42         * config/sparc/sparc.c (sparc_handle_vis_mul8x16): Change n_elts
43         to a vec<tree> *.
44         (sparc_fold_builtin): Use auto_vec<tree> when building a vector
45         passed to build_vector.
47 2017-09-14  Richard Sandiford  <richard.sandiford@linaro.org>
48             Alan Hayward  <alan.hayward@arm.com>
49             David Sherwood  <david.sherwood@arm.com>
51         * tree-core.h (tree_base::u): Add an "nelts" field.
52         (tree_vector): Use VECTOR_CST_NELTS as the length.
53         * tree.c (tree_size): Likewise.
54         (make_vector): Initialize VECTOR_CST_NELTS.
55         * tree.h (VECTOR_CST_NELTS): Use the u.nelts field.
56         * cfgexpand.c (expand_debug_expr): Use VECTOR_CST_NELTS instead of
57         TYPE_VECTOR_SUBPARTS.
58         * expr.c (const_vector_mask_from_tree): Consistently use "units"
59         as the number of units, setting it from VECTOR_CST_NELTS.
60         (const_vector_from_tree): Likewise.
61         * fold-const.c (negate_expr_p): Use VECTOR_CST_NELTS instead of
62         TYPE_VECTOR_SUBPARTS for the number of elements in a VECTOR_CST.
63         (fold_negate_expr_1): Likewise.
64         (fold_convert_const): Likewise.
65         (const_binop): Likewise.  Differentiate the number of output and
66         input elements.
67         (const_unop): Likewise.
68         (fold_ternary_loc): Use VECTOR_CST_NELTS for the number of elements
69         in a VECTOR_CST, asserting that it is the same as TYPE_VECTOR_SUBPARTS
70         in cases that did the opposite.
72 2017-09-14  Richard Biener  <rguenther@suse.de>
74         * tree-ssa-sccvn.c (visit_phi): Merge undefined values similar
75         to VN_TOP.
77 2017-09-14  Eric Botcazou  <ebotcazou@adacore.com>
79         * dwarf2out.c (dwarf2out_source_line): Remove superfluous test.
81 2017-09-14  Jakub Jelinek  <jakub@redhat.com>
83         PR target/81325
84         * cfgbuild.c (find_bb_boundaries): Ignore debug insns in decisions
85         if and where to split a bb, except for splitting before debug insn
86         sequences followed by non-label real insn.  Delete debug insns
87         in between basic blocks.
89         * combine.c (make_compound_operation_int): Formatting fixes.
91         * config/alpha/elf.h (LINK_EH_SPEC): Add -static-pie support.
92         * config/alpha/linux.h (LINK_GCC_C_SEQUENCE_SPEC): Likewise.
93         * config/netbsd.h (LINK_EH_SPEC): Likewise.
94         * config/sol2.h (LINK_EH_SPEC): Likewise.
95         * config/arm/uclinux-elf.h (LINK_GCC_C_SEQUENCE_SPEC): Likewise.
96         * config/s390/linux.h (LINK_SPEC): Likewise.
97         * config/freebsd.h (LINK_EH_SPEC): Likewise.
98         * config/openbsd.h (LINK_EH_SPEC): Likewise.
99         * config/lm32/uclinux-elf.h (LINK_GCC_C_SEQUENCE_SPEC): Likewise.
100         * config/aarch64/aarch64-linux.h (LINUX_TARGET_LINK_SPEC): Likewise.
101         * config/powerpcspe/sysv4.h (LINK_EH_SPEC): Likewise.
102         * config/bfin/linux.h (LINK_GCC_C_SEQUENCE_SPEC): Likewise.
103         * config/i386/gnu-user64.h (GNU_USER_TARGET_LINK_SPEC): Fix a typo.
104         * config/i386/gnu-user.h (GNU_USER_TARGET_LINK_SPEC): Formatting fix.
106 2017-09-13  Jakub Jelinek  <jakub@redhat.com>
108         * config/rs6000/sysv4.h (STARTFILE_LINUX_SPEC): Add -static-pie
109         support.
110         (ENDFILE_LINUX_SPEC): Likewise.
111         (LINK_EH_SPEC): Likewise.
112         * config/rs6000/linux64.h (LINK_SHLIB_SPEC): Likewise.
113         (LINK_OS_LINUX_SPEC32): Likewise.
114         (LINK_OS_LINUX_SPEC64): Likewise.
115         * config/rs6000/linux.h (LINK_SHLIB_SPEC): Likewise.
116         (LINK_OS_LINUX_SPEC): Likewise.
118 2017-09-13  Martin Liska  <mliska@suse.cz>
120         PR middle-end/82154
121         * stmt.c (expand_sjlj_dispatch_table): Use CASE_LOW when
122         CASE_HIGH is NULL_TREE.
124 2017-09-13  Richard Sandiford  <richard.sandiford@linaro.org>
125             Alan Hayward  <alan.hayward@arm.com>
126             David Sherwood  <david.sherwood@arm.com>
128         * target.def (secondary_memory_needed): New hook.
129         (secondary_reload): Refer to TARGET_SECONDARY_MEMORY_NEEDED
130         instead of SECONDARY_MEMORY_NEEDED.
131         (secondary_memory_needed_mode): Likewise.
132         * hooks.h (hook_bool_mode_reg_class_t_reg_class_t_false): Declare.
133         * hooks.c (hook_bool_mode_reg_class_t_reg_class_t_false): New function.
134         * doc/tm.texi.in (SECONDARY_MEMORY_NEEDED): Replace with...
135         (TARGET_SECONDARY_MEMORY_NEEDED): ...this.
136         (SECONDARY_MEMORY_NEEDED_RTX): Update reference accordingly.
137         * doc/tm.texi: Regenerate.
138         * config/alpha/alpha.h (SECONDARY_MEMORY_NEEDED): Delete.
139         * config/alpha/alpha.c (alpha_secondary_memory_needed): New function.
140         (TARGET_SECONDARY_MEMORY_NEEDED): Redefine.
141         * config/i386/i386.h (SECONDARY_MEMORY_NEEDED): Delete.
142         * config/i386/i386-protos.h (ix86_secondary_memory_needed): Delete.
143         * config/i386/i386.c (inline_secondary_memory_needed): Put the
144         mode argument first and change the reg_class arguments to reg_class_t.
145         (ix86_secondary_memory_needed): Likewise.  Remove the strict parameter.
146         Make static.  Update the call to inline_secondary_memory_needed.
147         (ix86_register_move_cost): Update the call to
148         inline_secondary_memory_needed.
149         (TARGET_SECONDARY_MEMORY_NEEDED): Redefine.
150         * config/ia64/ia64.h (SECONDARY_MEMORY_NEEDED): Delete commented-out
151         definition.
152         * config/ia64/ia64.c (spill_xfmode_rfmode_operand): Refer to
153         TARGET_SECONDARY_MEMORY_NEEDED rather than SECONDARY_MEMORY_NEEDED
154         in comment.
155         * config/mips/mips.h (SECONDARY_MEMORY_NEEDED): Delete.
156         * config/mips/mips-protos.h (mips_secondary_memory_needed): Delete.
157         * config/mips/mips.c (mips_secondary_memory_needed): Make static
158         and match hook interface.  Add comment from mips.h.
159         (TARGET_SECONDARY_MEMORY_NEEDED): Redefine.
160         * config/mmix/mmix.md (truncdfsf2): Refer to
161         TARGET_SECONDARY_MEMORY_NEEDED rather than SECONDARY_MEMORY_NEEDED
162         in comment.
163         * config/pa/pa-64.h (SECONDARY_MEMORY_NEEDED): Rename to...
164         (PA_SECONDARY_MEMORY_NEEDED): ...this, and put the mode argument first.
165         * config/pa/pa.c (TARGET_SECONDARY_MEMORY_NEEDED): Redefine.
166         (pa_secondary_memory_needed): New function.
167         * config/pdp11/pdp11.h (SECONDARY_MEMORY_NEEDED): Delete.
168         * config/pdp11/pdp11-protos.h (pdp11_secondary_memory_needed): Delete.
169         * config/pdp11/pdp11.c (TARGET_SECONDARY_MEMORY_NEEDED): Redefine.
170         (pdp11_secondary_memory_needed): Make static and match hook interface.
171         * config/powerpcspe/powerpcspe.h (SECONDARY_MEMORY_NEEDED): Delete.
172         * config/powerpcspe/powerpcspe-protos.h
173         (rs6000_secondary_memory_needed_ptr): Delete.
174         * config/powerpcspe/powerpcspe.c (rs6000_secondary_memory_needed_ptr):
175         Delete.
176         (TARGET_SECONDARY_MEMORY_NEEDED): Redefine.
177         (rs6000_option_override_internal): Assign to
178         targetm.secondary_memory_needed rather than
179         rs6000_secondary_memory_needed_ptr.
180         (rs6000_secondary_memory_needed): Match hook interface.
181         (rs6000_debug_secondary_memory_needed): Likewise.
182         * config/riscv/riscv.h (SECONDARY_MEMORY_NEEDED): Delete.
183         * config/riscv/riscv.c (riscv_secondary_memory_needed): New function.
184         (riscv_register_move_cost): Use it instead of SECONDARY_MEMORY_NEEDED.
185         (TARGET_SECONDARY_MEMORY_NEEDED): Redefine.
186         * config/rs6000/rs6000.h (SECONDARY_MEMORY_NEEDED): Delete.
187         * config/rs6000/rs6000-protos.h (rs6000_secondary_memory_needed_ptr):
188         Delete.
189         * config/rs6000/rs6000.c (rs6000_secondary_memory_needed_ptr): Delete.
190         (TARGET_SECONDARY_MEMORY_NEEDED): Redefine.
191         (rs6000_option_override_internal): Assign to
192         targetm.secondary_memory_needed rather than
193         rs6000_secondary_memory_needed_ptr.
194         (rs6000_secondary_memory_needed): Match hook interface.
195         (rs6000_debug_secondary_memory_needed): Likewise.
196         * config/s390/s390.h (SECONDARY_MEMORY_NEEDED): Delete.
197         * config/s390/s390.c (s390_secondary_memory_needed): New function.
198         (TARGET_SECONDARY_MEMORY_NEEDED): Redefine.
199         * config/sparc/sparc.h (SECONDARY_MEMORY_NEEDED): Delete.
200         * config/sparc/sparc.c (TARGET_SECONDARY_MEMORY_NEEDED): Redefine.
201         (sparc_secondary_memory_needed): New function.
202         * lra-constraints.c (check_and_process_move): Refer to
203         TARGET_SECONDARY_MEMORY_NEEDED rather than SECONDARY_MEMORY_NEEDED
204         in comment.
205         (curr_insn_transform): Likewise.
206         (process_alt_operands): Use targetm.secondary_memory_needed
207         instead of TARGET_SECONDARY_MEMORY_NEEDED.
208         (check_secondary_memory_needed_p): Likewise.
209         (choose_split_class): Likewise.
210         * reload.c: Unconditionally include code that was previously
211         conditional on SECONDARY_MEMORY_NEEDED.
212         (push_secondary_reload): Use targetm.secondary_memory_needed
213         instead of TARGET_SECONDARY_MEMORY_NEEDED.
214         (push_reload): Likewise.
215         * reload1.c: Unconditionally include code that was previously
216         conditional on SECONDARY_MEMORY_NEEDED.
217         (choose_reload_regs): Use targetm.secondary_memory_needed
218         instead of TARGET_SECONDARY_MEMORY_NEEDED.
219         (gen_reload): Likewise.
220         * system.h (SECONDARY_MEMORY_NEEDED): Poison.
222 2017-09-13  Richard Sandiford  <richard.sandiford@linaro.org>
223             Alan Hayward  <alan.hayward@arm.com>
224             David Sherwood  <david.sherwood@arm.com>
226         * target.def (secondary_memory_needed_mode): New hook:
227         * targhooks.c (default_secondary_memory_needed_mode): Declare.
228         * targhooks.h (default_secondary_memory_needed_mode): New function.
229         * doc/tm.texi.in (SECONDARY_MEMORY_NEEDED_MODE): Replace with...
230         (TARGET_SECONDARY_MEMORY_NEEDED_MODE): ...this.
231         * doc/tm.texi: Regenerate.
232         * lra-constraints.c (check_and_process_move): Use
233         targetm.secondary_memory_needed_mode instead of
234         TARGET_SECONDARY_MEMORY_NEEDED_MODE.
235         (curr_insn_transform): Likewise.
236         * reload.c (get_secondary_mem): Likewise.
237         * config/alpha/alpha.h (SECONDARY_MEMORY_NEEDED_MODE): Delete.
238         * config/alpha/alpha.c (alpha_secondary_memory_needed_mode): New
239         function.
240         (TARGET_SECONDARY_MEMORY_NEEDED_MODE): Redefine.
241         * config/i386/i386.h (SECONDARY_MEMORY_NEEDED_MODE): Delete.
242         * config/i386/i386.c (ix86_secondary_memory_needed_mode): New function.
243         (TARGET_SECONDARY_MEMORY_NEEDED_MODE): Redefine.
244         * config/powerpcspe/powerpcspe.h (SECONDARY_MEMORY_NEEDED_MODE):
245         Delete.
246         * config/powerpcspe/powerpcspe-protos.h
247         (rs6000_secondary_memory_needed_mode): Delete.
248         * config/powerpcspe/powerpcspe.c
249         (TARGET_SECONDARY_MEMORY_NEEDED_MODE): Redefine.
250         (rs6000_secondary_memory_needed_mode): Make static.
251         * config/rs6000/rs6000.h (SECONDARY_MEMORY_NEEDED_MODE): Delete.
252         * config/rs6000/rs6000-protos.h (rs6000_secondary_memory_needed_mode):
253         Delete.
254         * config/rs6000/rs6000.c (TARGET_SECONDARY_MEMORY_NEEDED_MODE):
255         Redefine.
256         (rs6000_secondary_memory_needed_mode): Make static.
257         * config/s390/s390.h (SECONDARY_MEMORY_NEEDED_MODE): Delete.
258         * config/s390/s390.c (s390_secondary_memory_needed_mode): New function.
259         (TARGET_SECONDARY_MEMORY_NEEDED_MODE): Redefine.
260         * config/sparc/sparc.h (SECONDARY_MEMORY_NEEDED_MODE): Delete.
261         * config/sparc/sparc.c (TARGET_SECONDARY_MEMORY_NEEDED_MODE):
262         Redefine.
263         (sparc_secondary_memory_needed_mode): New function.
264         * system.h (TARGET_SECONDARY_MEMORY_NEEDED_MODE): Poison.
266 2017-09-13  Jackson Woodruff  <jackson.woodruff@arm.com>
268         * config/aarch64/constraints.md (Umq): New constraint.
269         * config/aarch64/aarch64-simd.md (*aarch64_simd_mov<mode>):
270         Change to use Umq.
271         (mov<mode>): Update condition.
273 2017-09-13  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
275         * gimple-ssa-store-merging.c (sort_by_bitpos): Compare store order
276         when bitposition is the same.
278 2017-09-13  Richard Biener  <rguenther@suse.de>
280         * dwarf2out.c (output_die_symbol): Remove.
281         (output_die): Do not output a DIEs symbol.
283 2017-09-13  Richard Biener  <rguenther@suse.de>
285         PR middle-end/82128
286         * gimple-fold.c (gimple_fold_call): Update SSA name in-place to
287         default-def to avoid breaking iterator update with the weird
288         interaction with cgraph_update_edges_for_call_stmt_node.
290 2017-09-13  Richard Biener  <rguenther@suse.de>
292         * tree-cfg.c (verify_gimple_assign_binary): Add verification
293         for WIDEN_SUM_EXPR, VEC_WIDEN_MULT_{HI,LO,EVEN,ODD}_EXPR,
294         VEC_PACK_{TRUNC,SAT,FIX_TRUNC}_EXPR.
295         (verify_gimple_assign_ternary): Add verification for DOT_PROD_EXPR.
297 2017-09-13  Kugan Vivekanandarajah  <kuganv@linaro.org>
299         * config/aarch64/aarch64.c (aarch64_override_options_after_change_1):
300         Disable pc relative literal load irrespective of
301         TARGET_FIX_ERR_A53_84341 for default.
303 2017-09-12  Eric Botcazou  <ebotcazou@adacore.com>
305         * config/sparc/sparc.c (output_return): Output the source location of
306         the insn in the delay slot, if any.
307         (output_sibcall): Likewise.
309 2017-09-12  H.J. Lu  <hongjiu.lu@intel.com>
311         PR driver/81498
312         * common.opt (-static-pie): New alias.
313         (shared): Negate static-pie.
314         (-no-pie): Update help text.
315         (-pie): Likewise.
316         (static-pie): New option.
317         * config/gnu-user.h (GNU_USER_TARGET_STARTFILE_SPEC): Add
318         -static-pie support.
319         (GNU_USER_TARGET_ENDFILE_SPEC): Likewise.
320         (LINK_EH_SPEC): Likewise.
321         (LINK_GCC_C_SEQUENCE_SPEC): Likewise.
322         * config/i386/gnu-user.h (GNU_USER_TARGET_LINK_SPEC): Likewise.
323         * config/i386/gnu-user64.h (GNU_USER_TARGET_LINK_SPEC): Likewise.
324         * gcc.c (LINK_COMMAND_SPEC): Likewise.
325         (init_gcc_specs): Likewise.
326         (init_spec): Likewise.
327         (display_help): Update help message for -pie.
328         * doc/invoke.texi: Update -pie, -no-pie and -static.  Document
329         -static-pie.
331 2017-09-12  Wilco Dijkstra  <wdijkstr@arm.com>
333         * config/aarch64/aarch64.md (movsi_aarch64): Remove all '*'.
334         (movdi_aarch64): Likewise.
335         (movti_aarch64): Likewise.
337 2017-09-12 Simon Wright <simon@pushface.org>
339         PR target/80204
340         * config/darwin-driver.c (darwin_find_version_from_kernel): Eliminate
341         calculation of the minor version, always output as 0.
343 2017-09-12  Jakub Jelinek  <jakub@redhat.com>
345         PR target/82112
346         * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin): For
347         ALTIVEC_BUILTIN_VEC_LD if arg1 has array type call default_conversion
348         on it early, rather than manual conversion late.  For
349         ALTIVEC_BUILTIN_VEC_ST if arg2 has array type call default_conversion
350         instead of performing manual conversion.
352 2017-09-12  Carl Love  <cel@us.ibm.com>
354         * config/rs6000/altivec.md (vec_widen_umult_even_v4si,
355         vec_widen_smult_even_v4si): Add define expands for vmuleuw, vmulesw,
356         vmulouw, vmulosw.
357         * config/rs6000/rs6000-builtin.def (VMLEUW, VMULESW, VMULOUW,
358         VMULOSW): Add definitions.
359         * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Add
360         ALTIVEC_BUILTIN_VMULESW, ALTIVEC_BUILTIN_VMULEUW,
361         ALTIVEC_BUILTIN_VMULOSW, ALTIVEC_BUILTIN_VMULOUW entries.
362         * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin,
363         builtin_function_type): Add ALTIVEC_BUILTIN_* case statements.
365 2017-09-12  James Greenhalgh  <james.greenhalgh@arm.com>
367         * config/aarch64/aarch64.md (movdi_aarch64): Set load/store
368         types correctly.
369         (movti_aarch64): Likewise.
370         (movdf_aarch64): Likewise.
371         (movtf_aarch64): Likewise.
372         (load_pairdi): Likewise.
373         (store_pairdi): Likewise.
374         (load_pairdf): Likewise.
375         (store_pairdf): Likewise.
376         (loadwb_pair<GPI:mode>_<P:mode>): Likewise.
377         (storewb_pair<GPI:mode>_<P:mode>): Likewise.
378         (ldr_got_small_<mode>): Likewise.
379         (ldr_got_small_28k_<mode>): Likewise.
380         (ldr_got_tiny): Likewise.
381         * config/aarch64/iterators.md (ldst_sz): New.
382         (ldpstp_sz): Likewise.
383         * config/aarch64/thunderx.md (thunderx_storepair): Split store_8
384         to store_16.
385         (thunderx_load): Split load_8 to load_16.
386         * config/aarch64/thunderx2t99.md (thunderx2t99_loadpair): Split
387         load_8 to load_16.
388         (thunderx2t99_storepair_basic): Split store_8 to store_16.
389         * config/arm/xgene1.md (xgene1_load_pair): Split load_8 to load_16.
390         (xgene1_store_pair): Split store_8 to store_16.
391         * config/aarch64/falkor.md (falkor_ld_3_ld): Split load_8 to load_16.
392         (falkor_st_0_st_sd): Split store_8 to store_16.
394 2017-09-12  James Greenhalgh  <james.greenhalgh@arm.com>
396         * config/arm/types.md (type): Rename load1/2/3/4 to load_4/8/12/16
397         and store1/2/3/4 to store_4/8/12/16.
398         * config/aarch64/aarch64.md: Update for rename.
399         * config/arm/arm.md: Likewise.: Likewise.
400         * config/arm/arm.c: Likewise.
401         * config/arm/thumb1.md: Likewise.
402         * config/arm/thumb2.md: Likewise.
403         * config/arm/vfp.md: Likewise.
404         * config/arm/arm-generic.md: Likewise.
405         * config/arm/arm1020e.md: Likewise.
406         * config/arm/arm1026ejs.md: Likewise.
407         * config/arm/arm1136jfs.md: Likewise.
408         * config/arm/arm926ejs.md: Likewise.
409         * config/arm/cortex-a15.md: Likewise.
410         * config/arm/cortex-a17.md: Likewise.
411         * config/arm/cortex-a5.md: Likewise.
412         * config/arm/cortex-a53.md: Likewise.
413         * config/arm/cortex-a57.md: Likewise.
414         * config/arm/cortex-a7.md: Likewise.
415         * config/arm/cortex-a8.md: Likewise.
416         * config/arm/cortex-a9.md: Likewise.
417         * config/arm/cortex-m4.md: Likewise.
418         * config/arm/cortex-m7.md: Likewise.
419         * config/arm/cortex-r4.md: Likewise.
420         * config/arm/exynos-m1.md: Likewise.
421         * config/arm/fa526.md: Likewise.
422         * config/arm/fa606te.md: Likewise.
423         * config/arm/fa626te.md: Likewise.
424         * config/arm/fa726te.md: Likewise.
425         * config/arm/fmp626.md: Likewise.
426         * config/arm/iwmmxt.md: Likewise.
427         * config/arm/ldmstm.md: Likewise.
428         * config/arm/marvell-pj4.md: Likewise.
429         * config/arm/xgene1.md: Likewise.
430         * config/aarch64/thunderx.md: Likewise.
431         * config/aarch64/thunderx2t99.md: Likewise.
432         * config/aarch64/falkor.md: Likewise.
434 2017-09-12  Martin Liska  <mliska@suse.cz>
436         * attribs.c (private_lookup_attribute): New function.
437         * attribs.h (private_lookup_attribute): Declared here.
438         (lookup_attribute): Called from this place.
440 2017-09-12  Richard Biener  <rguenther@suse.de>
442         PR tree-optimization/82157
443         * tree-ssa-pre.c (remove_dead_inserted_code): Do not remove
444         stmts with side-effects.
446 2017-09-12  Richard Sandiford  <richard.sandiford@linaro.org>
447             Alan Hayward  <alan.hayward@arm.com>
448             David Sherwood <david.sherwood@arm.com>
450         * target.def (hard_regno_nregs): New hook.
451         (class_max_nregs): Refer to it instead of HARD_REGNO_NREGS.
452         * targhooks.h (default_hard_regno_nregs): Declare.
453         * targhooks.c (default_hard_regno_nregs): New function.
454         * doc/tm.texi.in (HARD_REGNO_NREGS): Replace with...
455         (TARGET_HARD_REGNO_NREGS): ...this hook.
456         (HARD_REGNO_NREGS_HAS_PADDING): Update accordingly.
457         (CLASS_MAX_NREGS): Likewise.
458         * doc/tm.texi: Regenerate.
459         * reginfo.c (init_reg_modes_target): Use targetm.hard_regno_nregs
460         instead of HARD_REGNO_NREGS.
461         * rtl.h (REG_NREGS): Refer to TARGET_HARD_REGNO_NREGS rather than
462         HARD_REGNO_NREGS in the comment.
463         * config/aarch64/aarch64.h (HARD_REGNO_NREGS): Delete.
464         * config/aarch64/aarch64-protos.h (aarch64_hard_regno_nregs): Delete.
465         * config/aarch64/aarch64.c (aarch64_hard_regno_nregs): Make static.
466         Return an unsigned int.
467         (TARGET_HARD_REGNO_NREGS): Redefine.
468         * config/alpha/alpha.h (HARD_REGNO_NREGS): Delete.
469         * config/arc/arc.h (HARD_REGNO_NREGS): Delete.
470         * config/arc/arc.c (TARGET_HARD_REGNO_NREGS): Redefine.
471         (arc_hard_regno_nregs): New function.
472         * config/arm/arm.h (HARD_REGNO_NREGS): Delete.
473         * config/arm/arm.c (TARGET_HARD_REGNO_NREGS): Redefine.
474         (arm_hard_regno_nregs): New function.
475         * config/avr/avr.h (HARD_REGNO_NREGS): Delete.
476         * config/bfin/bfin.h (HARD_REGNO_NREGS): Delete.
477         * config/bfin/bfin.c (bfin_hard_regno_nregs): New function.
478         (TARGET_HARD_REGNO_NREGS): Redefine.
479         * config/c6x/c6x.h (HARD_REGNO_NREGS): Delete.
480         * config/cr16/cr16.h (LONG_REG_P): Use targetm.hard_regno_nregs.
481         (HARD_REGNO_NREGS): Delete.
482         * config/cr16/cr16.c (TARGET_HARD_REGNO_NREGS): Redefine.
483         (cr16_hard_regno_nregs): New function.
484         (cr16_memory_move_cost): Use it instead of HARD_REGNO_NREGS.
485         * config/cris/cris.h (HARD_REGNO_NREGS): Delete.
486         * config/cris/cris.c (TARGET_HARD_REGNO_NREGS): Redefine.
487         (cris_hard_regno_nregs): New function.
488         * config/epiphany/epiphany.h (HARD_REGNO_NREGS): Delete.
489         * config/fr30/fr30.h (HARD_REGNO_NREGS): Delete.
490         (CLASS_MAX_NREGS): Use targetm.hard_regno_nregs.
491         * config/frv/frv.h (HARD_REGNO_NREGS): Delete.
492         (CLASS_MAX_NREGS): Remove outdated copy of documentation.
493         * config/frv/frv-protos.h (frv_hard_regno_nregs): Delete.
494         * config/frv/frv.c (TARGET_HARD_REGNO_NREGS): Redefine.
495         (frv_hard_regno_nregs): Make static.  Take and return an
496         unsigned int.
497         (frv_class_max_nregs): Remove outdated copy of documentation.
498         * config/ft32/ft32.h (HARD_REGNO_NREGS): Delete.
499         * config/h8300/h8300.h (HARD_REGNO_NREGS): Delete.
500         * config/h8300/h8300-protos.h (h8300_hard_regno_nregs): Delete.
501         * config/h8300/h8300.c (h8300_hard_regno_nregs): Delete.
502         * config/i386/i386.h (HARD_REGNO_NREGS): Delete.
503         * config/i386/i386.c (ix86_hard_regno_nregs): New function.
504         (TARGET_HARD_REGNO_NREGS): Redefine.
505         * config/ia64/ia64.h (HARD_REGNO_NREGS): Delete.
506         (CLASS_MAX_NREGS): Update comment.
507         * config/ia64/ia64.c (TARGET_HARD_REGNO_NREGS): Redefine.
508         (ia64_hard_regno_nregs): New function.
509         * config/iq2000/iq2000.h (HARD_REGNO_NREGS): Delete.
510         * config/lm32/lm32.h (HARD_REGNO_NREGS): Delete.
511         * config/m32c/m32c.h (HARD_REGNO_NREGS): Delete.
512         * config/m32c/m32c-protos.h (m32c_hard_regno_nregs): Delete.
513         * config/m32c/m32c.c (m32c_hard_regno_nregs_1): Take and return
514         an unsigned int.
515         (m32c_hard_regno_nregs): Likewise.  Make static.
516         (TARGET_HARD_REGNO_NREGS): Redefine.
517         * config/m32r/m32r.h (HARD_REGNO_NREGS): Delete.
518         * config/m68k/m68k.h (HARD_REGNO_NREGS): Delete.
519         * config/m68k/m68k.c (TARGET_HARD_REGNO_NREGS): Redefine.
520         (m68k_hard_regno_nregs): New function.
521         * config/mcore/mcore.h (HARD_REGNO_NREGS): Delete.
522         * config/microblaze/microblaze.h (HARD_REGNO_NREGS): Delete.
523         * config/mips/mips.h (HARD_REGNO_NREGS): Delete.
524         * config/mips/mips-protos.h (mips_hard_regno_nregs): Delete.
525         * config/mips/mips.c (mips_hard_regno_nregs): Make static.
526         Take and return an unsigned int.
527         (TARGET_HARD_REGNO_NREGS): Redefine.
528         * config/mmix/mmix.h (HARD_REGNO_NREGS): Delete.
529         (CLASS_MAX_NREGS): Use targetm.hard_regno_nregs.
530         * config/mn10300/mn10300.h (HARD_REGNO_NREGS): Delete.
531         * config/moxie/moxie.h (HARD_REGNO_NREGS): Delete.
532         * config/msp430/msp430.h (HARD_REGNO_NREGS): Delete.
533         * config/msp430/msp430-protos.h (msp430_hard_regno_nregs): Delete.
534         * config/msp430/msp430.c (TARGET_HARD_REGNO_NREGS): Redefine.
535         (msp430_hard_regno_nregs): Make static.  Take and return an
536         unsigned int.
537         * config/nds32/nds32.h (HARD_REGNO_NREGS): Delete.
538         * config/nds32/nds32-protos.h (nds32_hard_regno_nregs): Delete.
539         * config/nds32/nds32.c (nds32_hard_regno_nregs): Delete.
540         (nds32_hard_regno_mode_ok): Use targetm.hard_regno_nregs.
541         * config/nios2/nios2.h (HARD_REGNO_NREGS): Delete.
542         * config/nvptx/nvptx.h (HARD_REGNO_NREGS): Delete.
543         * config/nvptx/nvptx.c (nvptx_hard_regno_nregs): New function.
544         (TARGET_HARD_REGNO_NREGS): Redefine.
545         * config/pa/pa32-regs.h (HARD_REGNO_NREGS): Rename to...
546         (PA_HARD_REGNO_NREGS): ...this.
547         * config/pa/pa64-regs.h (HARD_REGNO_NREGS): Rename to...
548         (PA_HARD_REGNO_NREGS): ...this.
549         * config/pa/pa.c (TARGET_HARD_REGNO_NREGS): Redefine.
550         (pa_hard_regno_nregs): New function.
551         * config/pdp11/pdp11.h (HARD_REGNO_NREGS): Delete.
552         * config/pdp11/pdp11.c (TARGET_HARD_REGNO_NREGS): Redefine.
553         (pdp11_hard_regno_nregs): New function.
554         * config/powerpcspe/powerpcspe.h (HARD_REGNO_NREGS): Delete.
555         * config/powerpcspe/powerpcspe.c (TARGET_HARD_REGNO_NREGS): Redefine.
556         (rs6000_hard_regno_nregs_hook): New function.
557         * config/riscv/riscv.h (HARD_REGNO_NREGS): Delete.
558         * config/riscv/riscv-protos.h (riscv_hard_regno_nregs): Delete.
559         * config/riscv/riscv.c (riscv_hard_regno_nregs): Make static.
560         Take and return an unsigned int.  Move earlier in file.
561         (TARGET_HARD_REGNO_NREGS): Redefine.
562         * config/rl78/rl78.h (HARD_REGNO_NREGS): Delete.
563         * config/rl78/rl78-protos.h (rl78_hard_regno_nregs): Delete.
564         * config/rl78/rl78.c (TARGET_HARD_REGNO_NREGS): Reefine.
565         (rl78_hard_regno_nregs): Make static.  Take and return an
566         unsigned int.
567         * config/rs6000/rs6000.h (HARD_REGNO_NREGS): Delete.
568         * config/rs6000/rs6000.c (TARGET_HARD_REGNO_NREGS): Redefine.
569         (rs6000_hard_regno_nregs_hook): New function.
570         * config/rx/rx.h (HARD_REGNO_NREGS): Delete.
571         * config/rx/rx.c (rx_hard_regno_nregs): New function.
572         (TARGET_HARD_REGNO_NREGS): Redefine.
573         * config/s390/s390.h (HARD_REGNO_NREGS): Delete.
574         * config/s390/s390.c (REGNO_PAIR_OK): Use s390_hard_regno_nregs
575         instead of HARD_REGNO_NREGS.
576         (s390_hard_regno_nregs): New function.
577         (s390_hard_regno_mode_ok): Add comment from s390.h.
578         (TARGET_HARD_REGNO_NREGS): Redefine.
579         * config/sh/sh.h (HARD_REGNO_NREGS): Delete.
580         * config/sh/sh.c (TARGET_HARD_REGNO_NREGS): Redefine.
581         (sh_hard_regno_nregs): New function.
582         (sh_pass_in_reg_p): Use it.
583         * config/sparc/sparc.h (HARD_REGNO_NREGS): Delete.
584         * config/sparc/sparc.c (TARGET_HARD_REGNO_NREGS): Redefine.
585         (sparc_hard_regno_nregs): New function.
586         * config/spu/spu.h (HARD_REGNO_NREGS): Delete.
587         * config/spu/spu.c (spu_hard_regno_nregs): New function.
588         (spu_function_arg_advance): Use it, supplying a valid register number.
589         (TARGET_HARD_REGNO_NREGS): Redefine.
590         * config/stormy16/stormy16.h (HARD_REGNO_NREGS): Delete.
591         * config/tilegx/tilegx.h (HARD_REGNO_NREGS): Delete.
592         * config/tilepro/tilepro.h (HARD_REGNO_NREGS): Delete.
593         * config/v850/v850.h (HARD_REGNO_NREGS): Delete.
594         * config/vax/vax.h (HARD_REGNO_NREGS): Delete.
595         * config/visium/visium.h (HARD_REGNO_NREGS): Delete.
596         (CLASS_MAX_NREGS): Remove copy of old documentation.
597         * config/visium/visium.c (TARGET_HARD_REGNO_NREGS): Redefine.
598         (visium_hard_regno_nregs): New function.
599         (visium_hard_regno_mode_ok): Use it instead of HARD_REGNO_NREGS.
600         * config/xtensa/xtensa.h (HARD_REGNO_NREGS): Delete.
601         * config/xtensa/xtensa.c (TARGET_HARD_REGNO_NREGS): Redefine.
602         xtensa_hard_regno_nregs): New function.
603         * system.h (HARD_REGNO_NREGS): Poison.
605 2017-09-12  Richard Sandiford  <richard.sandiford@linaro.org>
607         * config/arm/arm.h (THUMB_SECONDARY_INPUT_RELOAD_CLASS): Use
608         hard_regno_nregs instead of HARD_REGNO_NREGS.
609         (THUMB_SECONDARY_OUTPUT_RELOAD_CLASS): Likewise.
610         * config/c6x/c6x.c (c6x_expand_prologue): Likewise.
611         (c6x_expand_epilogue): Likewise.
612         * config/frv/frv.c (frv_alloc_temp_reg): Likewise.
613         (frv_read_iacc_argument): Likewise.
614         * config/sh/sh.c: Include regs.h.
615         (sh_print_operand): Use hard_regno_nregs instead of HARD_REGNO_NREGS.
616         (regs_used): Likewise.
617         (output_stack_adjust): Likewise.
618         * config/xtensa/xtensa.c (xtensa_copy_incoming_a7): Likewise.
619         * expmed.c: Include regs.h.
620         (store_bit_field_1): Use hard_regno_nregs instead of HARD_REGNO_NREGS.
621         * ree.c: Include regs.h.
622         (combine_reaching_defs): Use hard_regno_nregs instead of
623         HARD_REGNO_NREGS.
624         (add_removable_extension): Likewise.
626 2017-09-12  Richard Sandiford  <richard.sandiford@linaro.org>
628         * regs.h (hard_regno_nregs): Turn into a function.
629         (end_hard_regno): Update accordingly.
630         * caller-save.c (setup_save_areas): Likewise.
631         (save_call_clobbered_regs): Likewise.
632         (replace_reg_with_saved_mem): Likewise.
633         (insert_restore): Likewise.
634         (insert_save): Likewise.
635         * combine.c (can_change_dest_mode): Likewise.
636         (move_deaths): Likewise.
637         (distribute_notes): Likewise.
638         * config/mips/mips.c (mips_hard_regno_call_part_clobbered): Likewise.
639         * config/powerpcspe/powerpcspe.c (rs6000_cannot_change_mode_class)
640         (rs6000_split_multireg_move): Likewise.
641         (rs6000_register_move_cost): Likewise.
642         (rs6000_memory_move_cost): Likewise.
643         * config/rs6000/rs6000.c (rs6000_cannot_change_mode_class): Likewise.
644         (rs6000_split_multireg_move): Likewise.
645         (rs6000_register_move_cost): Likewise.
646         (rs6000_memory_move_cost): Likewise.
647         * cselib.c (cselib_reset_table): Likewise.
648         (cselib_lookup_1): Likewise.
649         * emit-rtl.c (set_mode_and_regno): Likewise.
650         * function.c (aggregate_value_p): Likewise.
651         * ira-color.c (setup_profitable_hard_regs): Likewise.
652         (check_hard_reg_p): Likewise.
653         (calculate_saved_nregs): Likewise.
654         (assign_hard_reg): Likewise.
655         (improve_allocation): Likewise.
656         (calculate_spill_cost): Likewise.
657         * ira-emit.c (modify_move_list): Likewise.
658         * ira-int.h (ira_hard_reg_set_intersection_p): Likewise.
659         (ira_hard_reg_in_set_p): Likewise.
660         * ira.c (setup_reg_mode_hard_regset): Likewise.
661         (clarify_prohibited_class_mode_regs): Likewise.
662         (check_allocation): Likewise.
663         * lra-assigns.c (find_hard_regno_for_1): Likewise.
664         (lra_setup_reg_renumber): Likewise.
665         (setup_try_hard_regno_pseudos): Likewise.
666         (spill_for): Likewise.
667         (assign_hard_regno): Likewise.
668         (setup_live_pseudos_and_spill_after_risky_transforms): Likewise.
669         * lra-constraints.c (in_class_p): Likewise.
670         (lra_constraint_offset): Likewise.
671         (simplify_operand_subreg): Likewise.
672         (lra_constraints): Likewise.
673         (split_reg): Likewise.
674         (split_if_necessary): Likewise.
675         (invariant_p): Likewise.
676         (inherit_in_ebb): Likewise.
677         * lra-lives.c (process_bb_lives): Likewise.
678         * lra-remat.c (reg_overlap_for_remat_p): Likewise.
679         (get_hard_regs): Likewise.
680         (do_remat): Likewise.
681         * lra-spills.c (assign_spill_hard_regs): Likewise.
682         * mode-switching.c (create_pre_exit): Likewise.
683         * postreload.c (reload_combine_recognize_pattern): Likewise.
684         * recog.c (peep2_find_free_register): Likewise.
685         * regcprop.c (kill_value_regno): Likewise.
686         (set_value_regno): Likewise.
687         (copy_value): Likewise.
688         (maybe_mode_change): Likewise.
689         (find_oldest_value_reg): Likewise.
690         (copyprop_hardreg_forward_1): Likewise.
691         * regrename.c (check_new_reg_p): Likewise.
692         (regrename_do_replace): Likewise.
693         * reload.c (push_reload): Likewise.
694         (combine_reloads): Likewise.
695         (find_dummy_reload): Likewise.
696         (operands_match_p): Likewise.
697         (find_reloads): Likewise.
698         (find_equiv_reg): Likewise.
699         (reload_adjust_reg_for_mode): Likewise.
700         * reload1.c (count_pseudo): Likewise.
701         (count_spilled_pseudo): Likewise.
702         (find_reg): Likewise.
703         (clear_reload_reg_in_use): Likewise.
704         (free_for_value_p): Likewise.
705         (allocate_reload_reg): Likewise.
706         (choose_reload_regs): Likewise.
707         (reload_adjust_reg_for_temp): Likewise.
708         (emit_reload_insns): Likewise.
709         (delete_output_reload): Likewise.
710         * rtlanal.c (subreg_get_info): Likewise.
711         * sched-deps.c (sched_analyze_reg): Likewise.
712         * sel-sched.c (init_regs_for_mode): Likewise.
713         (mark_unavailable_hard_regs): Likewise.
714         (choose_best_reg_1): Likewise.
715         (verify_target_availability): Likewise.
716         * valtrack.c (dead_debug_insert_temp): Likewise.
717         * var-tracking.c (track_loc_p): Likewise.
718         (emit_note_insn_var_location): Likewise.
719         * varasm.c (make_decl_rtl): Likewise.
720         * reginfo.c (choose_hard_reg_mode): Likewise.
721         (init_reg_modes_target): Refer directly to
722         this_target_regs->x_hard_regno_nregs.
724 2017-09-12  Richard Sandiford  <richard.sandiford@linaro.org>
726         * ira-costs.c (record_operand_costs): Use in_hard_reg_set_p
727         instead of hard_regno_nregs.
729 2017-09-12  Richard Sandiford  <richard.sandiford@linaro.org>
731         * config/aarch64/aarch64.c (aarch64_hard_regno_mode_ok): Use
732         end_hard_regno instead of hard_regno_nregs.
733         * config/s390/s390.c (s390_reg_clobbered_rtx): Likewise.
734         * config/sparc/sparc.h (ASM_DECLARE_REGISTER_GLOBAL): Likewise.
735         * config/visium/visium.c (visium_hard_regno_mode_ok): Likewise.
736         * ira-color.c (improve_allocation): Likewise.
737         * lra-assigns.c (find_hard_regno_for_1): Likewise.
738         * lra-lives.c (mark_regno_live): Likewise.
739         (mark_regno_dead): Likewise.
740         * lra-remat.c (operand_to_remat): Likewise.
741         * lra.c (collect_non_operand_hard_regs): Likewise.
742         * postreload.c (reload_combine_note_store): Likewise.
743         (move2add_valid_value_p): Likewise.
744         * reload.c (regno_clobbered_p): Likewise.
746 2017-09-12  Richard Sandiford  <richard.sandiford@linaro.org>
748         * config/frv/frv.c (FOR_EACH_REGNO): Use END_REGNO instead of
749         hard_regno_nregs.
750         * config/v850/v850.c (v850_reorg): Likewise.
751         * reload.c (refers_to_regno_for_reload_p): Likewise.
752         (find_equiv_reg): Likewise.
753         * reload1.c (reload_reg_reaches_end_p): Likewise.
755 2017-09-12  Richard Sandiford  <richard.sandiford@linaro.org>
757         * caller-save.c (add_used_regs): Use REG_NREGS instead of
758         hard_regno_nregs.
759         * config/aarch64/aarch64.c (aarch64_split_combinev16qi): Likewise.
760         * config/arm/arm.c (output_move_neon): Likewise.
761         (arm_attr_length_move_neon): Likewise.
762         (neon_split_vcombine): Likewise.
763         * config/c6x/c6x.c (c6x_mark_reg_read): Likewise.
764         (c6x_mark_reg_written): Likewise.
765         (c6x_dwarf_register_span): Likewise.
766         * config/i386/i386.c (ix86_save_reg): Likewise.
767         * config/ia64/ia64.c (mark_reg_gr_used_mask): Likewise.
768         (rws_access_reg): Likewise.
769         * config/s390/s390.c (s390_call_saved_register_used): Likewise.
770         * mode-switching.c (create_pre_exit): Likewise.
771         * ree.c (combine_reaching_defs): Likewise.
772         (add_removable_extension): Likewise.
773         * regcprop.c (find_oldest_value_reg): Likewise.
774         (copyprop_hardreg_forward_1): Likewise.
775         * reload.c (reload_inner_reg_of_subreg): Likewise.
776         (push_reload): Likewise.
777         (combine_reloads): Likewise.
778         (find_dummy_reload): Likewise.
779         (reload_adjust_reg_for_mode): Likewise.
780         * reload1.c (find_reload_regs): Likewise.
781         (forget_old_reloads_1): Likewise.
782         (reload_reg_free_for_value_p): Likewise.
783         (reload_adjust_reg_for_temp): Likewise.
784         (emit_reload_insns): Likewise.
785         (delete_output_reload): Likewise.
786         * sel-sched.c (choose_best_reg_1): Likewise.
787         (choose_best_pseudo_reg): Likewise.
789 2017-09-12  Richard Sandiford  <richard.sandiford@linaro.org>
790             Alan Hayward  <alan.hayward@arm.com>
791             David Sherwood <david.sherwood@arm.com>
793         * defaults.h (SLOW_UNALIGNED_ACCESS): Delete.
794         * target.def (slow_unaligned_access): New hook.
795         * targhooks.h (default_slow_unaligned_access): Declare.
796         * targhooks.c (default_slow_unaligned_access): New function.
797         * doc/tm.texi.in (SLOW_UNALIGNED_ACCESS): Replace with...
798         (TARGET_SLOW_UNALIGNED_ACCESS): ...this.
799         * doc/tm.texi: Regenerate.
800         * config/alpha/alpha.h (SLOW_UNALIGNED_ACCESS): Delete.
801         * config/arm/arm.h (SLOW_UNALIGNED_ACCESS): Delete.
802         * config/i386/i386.h (SLOW_UNALIGNED_ACCESS): Delete commented-out
803         definition.
804         * config/powerpcspe/powerpcspe.h (SLOW_UNALIGNED_ACCESS): Delete.
805         * config/powerpcspe/powerpcspe.c (TARGET_SLOW_UNALIGNED_ACCESS):
806         Redefine.
807         (rs6000_slow_unaligned_access): New function.
808         (rs6000_emit_move): Use it instead of SLOW_UNALIGNED_ACCESS.
809         (expand_block_compare): Likewise.
810         (expand_strn_compare): Likewise.
811         (rs6000_rtx_costs): Likewise.
812         * config/riscv/riscv.h (SLOW_UNALIGNED_ACCESS): Delete.
813         (riscv_slow_unaligned_access): Likewise.
814         * config/riscv/riscv.c (riscv_slow_unaligned_access): Rename to...
815         (riscv_slow_unaligned_access_p): ...this and make static.
816         (riscv_option_override): Update accordingly.
817         (riscv_slow_unaligned_access): New function.
818         (TARGET_SLOW_UNALIGNED_ACCESS): Redefine.
819         * config/rs6000/rs6000.h (SLOW_UNALIGNED_ACCESS): Delete.
820         * config/rs6000/rs6000.c (TARGET_SLOW_UNALIGNED_ACCESS): Redefine.
821         (rs6000_slow_unaligned_access): New function.
822         (rs6000_emit_move): Use it instead of SLOW_UNALIGNED_ACCESS.
823         (rs6000_rtx_costs): Likewise.
824         * config/rs6000/rs6000-string.c (expand_block_compare)
825         (expand_strn_compare): Use targetm.slow_unaligned_access instead
826         of SLOW_UNALIGNED_ACCESS.
827         * config/tilegx/tilegx.h (SLOW_UNALIGNED_ACCESS): Delete.
828         * config/tilepro/tilepro.h (SLOW_UNALIGNED_ACCESS): Delete.
829         * calls.c (expand_call): Use targetm.slow_unaligned_access instead
830         of SLOW_UNALIGNED_ACCESS.
831         * expmed.c (simple_mem_bitfield_p): Likewise.
832         * expr.c (alignment_for_piecewise_move): Likewise.
833         (emit_group_load_1): Likewise.
834         (emit_group_store): Likewise.
835         (copy_blkmode_from_reg): Likewise.
836         (emit_push_insn): Likewise.
837         (expand_assignment): Likewise.
838         (store_field): Likewise.
839         (expand_expr_real_1): Likewise.
840         * gimple-fold.c (gimple_fold_builtin_memory_op): Likewise.
841         * lra-constraints.c (simplify_operand_subreg): Likewise.
842         * stor-layout.c (bit_field_mode_iterator::next_mode): Likewise.
843         * gimple-ssa-store-merging.c: Likewise in block comment at start
844         of file.
845         * tree-ssa-strlen.c: Include target.h.
846         (handle_builtin_memcmp): Use targetm.slow_unaligned_access instead
847         of SLOW_UNALIGNED_ACCESS.
848         * system.h (SLOW_UNALIGNED_ACCESS): Poison.
850 2017-09-12  Richard Sandiford  <richard.sandiford@linaro.org>
852         PR rtl-optimization/82185
853         * expmed.c (emit_store_flag_int): Only test tem if it has been
854         initialized.
856 2017-09-12  Richard Biener  <rguenther@suse.de>
858         PR middle-end/82149
859         * match.pd ((FTYPE) N CMP CST): Fix typo.
861 2017-09-12  Simon Atanasyan  <simon.atanasyan@imgtec.com>
863         * config/mips/mips.c (mips_attribute_table): Add 'short_call'
864         attribute.
865         (mips_near_type_p): Add 'short_call' attribute as a synonym
866         for 'near'.
867         * doc/extend.texi (short_call): Document new function attribute.
869 2017-09-12  Jakub Jelinek  <jakub@redhat.com>
871         PR target/82112
872         * c-common.c (sync_resolve_size): Instead of c_dialect_cxx ()
873         assertion check that in the condition.
874         (get_atomic_generic_size): Likewise.  Before testing if parameter
875         has pointer type, if it has array type, call for C++
876         default_conversion to perform array-to-pointer conversion.
878 2017-09-12  Richard Biener  <rguenther@suse.de>
880         * tree-vect-generic.c (expand_vector_operations_1): Do nothing
881         for operations we cannot scalarize.
883 2017-09-12  Aldy Hernandez  <aldyh@redhat.com>
885         * tree-ssa-threadbackward.c (fsm_find_thread_path): Make GC
886         vectors heap vectors.  Clean up comments.
887         Make visited_bbs a reference.
888         (profitable_jump_thread_path): Make GC
889         vectors heap vectors.  Clean up comments.
890         Misc cleanups.
891         (convert_and_register_jump_thread_path): Make GC vectors heap
892         vectors.
893         (check_subpath_and_update_thread_path): Same.  Clean up comments.
894         Make visited_bbs a reference.
895         (handle_phi): Abstract common code to to
896         register_jump_thread_path_if_profitable.
897         Rename VAR_BB to DEF_BB.
898         Update comments.
899         Make GC vectors heap vectors.
900         Make visited_bbs a reference.
901         (handle_assignment): Same.
902         (register_jump_thread_path_if_profitable): New.
903         (fsm_find_control_statement_thread_paths): Rename VAR_BB to
904         DEF_BB.
905         Make GC vectors heap vectors.  Clean up comments.
906         Make visited_bbs a reference.
907         (find_jump_threads_backwards): Make visited_bbs live in the stack.
908         * tree-ssa-threadupdate.c (delete_jump_thread_path): Fix typo in
909         comment.
911 2017-09-11  Max Filippov  <jcmvbkbc@gmail.com>
913         PR target/82181
914         * config/xtensa/xtensa.c (xtensa_mem_offset): Check that both
915         words of E_DImode object are reachable by xtensa_uimm8x4 access.
917 2017-09-11  Vidya Praveen  <vidyapraveen@arm.com>
919         Revert r251800 and r251799.
921 2017-09-11  Martin Jambor  <mjambor@suse.cz>
923         PR hsa/82119
924         * hsa-gen.c (gen_hsa_phi_from_gimple_phi): Process ADDR_EXPRs in
925         arguments in advance.
926         * hsa-regalloc.c (naive_process_phi): New parameter predecessors,
927         use it to find predecessor edges.
928         (naive_outof_ssa): Collect vector of predecessors.
930 2017-09-08  Jason Merrill  <jason@redhat.com>
932         PR c++/70029 - ICE with ref-qualifier and -flto
933         * langhooks.h (struct lang_hooks_for_types): Add
934         copy_lang_qualifiers.
935         * attribs.c (build_type_attribute_qual_variant): Use it.
936         * langhooks-def.h (LANG_HOOKS_COPY_LANG_QUALIFIERS): Default to
937         NULL.
938         (LANG_HOOKS_FOR_TYPES_INITIALIZER): Use it.
939         * tree.c (verify_type): Re-enable TYPE_CANONICAL main variant check.
941 2017-09-08  Eric Botcazou  <ebotcazou@adacore.com>
943         PR target/81988
944         * config/sparc/sparc.md (mulsi3): Rename into *mulsi3_sp32.
945         (*mulsi3_sp64): New instruction.
946         (mulsi3): New expander.
948 2017-09-08  Uros Bizjak  <ubizjak@gmail.com>
950         * config/alpha/alpha.c (alpha_print_operand) <case 'S'>: Remove.
952 2017-09-08  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
954         * sancov.c: Include memmodel.h.
956 2017-09-07  Eric Botcazou  <ebotcazou@adacore.com>
958         PR target/80897
959         * config/sparc/sparc.c (sparc_emit_set_symbolic_const64): Deal with too
960         large offsets.
962 2017-09-07  Carl Love  <cel@us.ibm.com>
964         * config/rs6000/vsx.md (define_insn "*stxvl"): Add missing argument to
965         the sldi instruction.
967 2017-09-07  David Edelsohn  <dje.gcc@gmail.com>
969         * sancov.c: Include tm_p.h.
971 2017-09-07  Jakub Jelinek  <jakub@redhat.com>
973         PR target/81979
974         * output.h (switch_to_other_text_partition): New declaration.
975         * varasm.c (switch_to_other_text_partition): New function.
976         * config/rs6000/rs6000.c (uses_TOC): Return 2 if
977         NOTE_INSN_SWITCH_TEXT_SECTIONS is seen before finding load_toc_* insn.
978         (rs6000_elf_declare_function_name): If uses_TOC returned 2, switch
979         to the other text partition before emitting LCL label and switch back
980         after emitting the word after it.
982 2017-09-07  Richard Biener  <rguenther@suse.de>
984         * passes.def (pass_split_crit_edges): Remove instance before PRE.
985         * tree-ssa-pre.c (pass_pre::execute): Instead manually split
986         critical edges here, after loop init.
987         (pass_data_pre): Remove PROP_no_crit_edges flags.
988         * tree-ssa-sccvn.c (vn_reference_lookup_3): Use vn_valueize
989         for valueization of call args to avoid leaking VN_TOP.
990         (visit_use): Assert we do not visit default defs.
991         (init_scc_vn): Use build_decl for VN_TOP to make name nicer.
992         Use error_mark_node to more easily detect leaking VN_TOP.
993         All default-defs are varying, not VN_TOP.  Mark them visited.
994         (run_scc_vn): Make code match comment.
996 2017-09-07  Michael Meissner  <meissner@linux.vnet.ibm.com>
998         * config/rs6000/rs6000-cpus.def (OTHER_VSX_VECTOR_MASKS): Delete
999         OPTION_MASK_FLOAT128_KEYWORD.
1000         (POWERPC_MASKS): Likewise.
1001         * config/rs6000/rs6000-c.c (rs6000_target_modify_macros): Delete
1002         support for the -mfloat128-type option, and make -mfloat128
1003         default on PowerPC Linux systems.  Define or undefine
1004         __FLOAT128__ and  __FLOAT128_HARDWARE__ for the current options.
1005         Define __float128 to be __ieee128 if IEEE 128-bit support is
1006         enabled, or undefine it.
1007         (rs6000_cpu_cpp_builtins): Delete defining __FLOAT128__ here.
1008         Delete defining __FLOAT128_TYPE__.
1009         * config/rs6000/rs6000.opt (x_TARGET_FLOAT128_TYPE): Delete the
1010         -mfloat128-type option and make -mfloat128 default on PowerPC
1011         Linux systems.
1012         (TARGET_FLOAT128_TYPE): Likewise.
1013         (-mfloat128-type): Likewise.
1014         * config/rs6000/rs6000.c (rs6000_option_override_internal):
1015         Delete the -mfloat128-type option and make -mfloat128 default on
1016         PowerPC Linux systems.  Always use __ieee128 to be the keyword for
1017         the IEEE 128-bit type, and map __float128 to __ieee128 if IEEE
1018         128-bit floating point is enabled.  Change tests from using
1019         -mfloat128-type to -mfloat128.
1020         (rs6000_mangle_type): Use the correct mangling for the __float128
1021         type even if normal long double is restricted to 64-bits.
1022         (floatn_mode): Enable the _Float128 type by default on VSX Linux
1023         systems.
1024         * config/rs6000/rs6000.h (MASK_FLOAT128_TYPE): Delete.
1025         (MASK_FLOAT128_KEYWORD): Define new shortcut macro.
1026         (RS6000BTM_FLOAT128): Define in terms of -mfloat128, not
1027         -mfloat128-type.
1028         * doc/invoke.texi (RS/6000 and PowerPC Options): Update
1029         documentation for -mfloat128.
1031 2017-09-06  Olivier Hainque  <hainque@adacore.com>
1033         * config.gcc (powerpc-wrs-vxworksspe): Now match as vxworks*spe.
1035 2017-09-06  Wish Wu  <wishwu007@gmail.com>
1036             Jakub Jelinek  <jakub@redhat.com>
1038         * asan.c (initialize_sanitizer_builtins): Add
1039         BT_FN_VOID_UINT8_UINT8, BT_FN_VOID_UINT16_UINT16,
1040         BT_FN_VOID_UINT32_UINT32, BT_FN_VOID_UINT64_UINT64,
1041         BT_FN_VOID_FLOAT_FLOAT, BT_FN_VOID_DOUBLE_DOUBLE and
1042         BT_FN_VOID_UINT64_PTR variables.
1043         * builtin-types.def (BT_FN_VOID_UINT8_UINT8): New fn type.
1044         (BT_FN_VOID_UINT16_UINT16): Likewise.
1045         (BT_FN_VOID_UINT32_UINT32): Likewise.
1046         (BT_FN_VOID_FLOAT_FLOAT): Likewise.
1047         (BT_FN_VOID_DOUBLE_DOUBLE): Likewise.
1048         (BT_FN_VOID_UINT64_PTR): Likewise.
1049         * common.opt (flag_sanitize_coverage): New variable.
1050         (fsanitize-coverage=trace-pc): Remove.
1051         (fsanitize-coverage=): Add.
1052         * flag-types.h (enum sanitize_coverage_code): New enum.
1053         * fold-const.c (fold_range_test): Disable non-short-circuit
1054         optimization if flag_sanitize_coverage.
1055         (fold_truth_andor): Likewise.
1056         * tree-ssa-ifcombine.c (ifcombine_ifandif): Likewise.
1057         * opts.c (COVERAGE_SANITIZER_OPT): Define.
1058         (coverage_sanitizer_opts): New array.
1059         (get_closest_sanitizer_option): Add OPTS argument, handle also
1060         OPT_fsanitize_coverage_.
1061         (parse_sanitizer_options): Adjusted to also handle
1062         OPT_fsanitize_coverage_.
1063         (common_handle_option): Add OPT_fsanitize_coverage_.
1064         * sancov.c (instrument_comparison, instrument_switch): New function.
1065         (sancov_pass): Add trace-cmp support.
1066         * sanitizer.def (BUILT_IN_SANITIZER_COV_TRACE_CMP1,
1067         BUILT_IN_SANITIZER_COV_TRACE_CMP2, BUILT_IN_SANITIZER_COV_TRACE_CMP4,
1068         BUILT_IN_SANITIZER_COV_TRACE_CMP8,
1069         BUILT_IN_SANITIZER_COV_TRACE_CONST_CMP1,
1070         BUILT_IN_SANITIZER_COV_TRACE_CONST_CMP2,
1071         BUILT_IN_SANITIZER_COV_TRACE_CONST_CMP4,
1072         BUILT_IN_SANITIZER_COV_TRACE_CONST_CMP8,
1073         BUILT_IN_SANITIZER_COV_TRACE_CMPF, BUILT_IN_SANITIZER_COV_TRACE_CMPD,
1074         BUILT_IN_SANITIZER_COV_TRACE_SWITCH): New builtins.
1075         * doc/invoke.texi: Document -fsanitize-coverage=trace-cmp.
1077 2017-09-06  Richard Earnshaw  <rearnsha@arm.com>
1079         * config/arm/parsecpu.awk (fatal): Note that we've encountered an
1080         error.  Only quit immediately if parsing is complete.
1081         (BEGIN): Initialize fatal_err and parse_done.
1082         (begin fpu, end fpu): Check number of arguments.
1083         (begin arch, end arch): Likewise.
1084         (begin cpu, end cpu): Likewise.
1085         (cname, tune for, tune flags, architecture, fpu, option): Likewise.
1086         (optalias): Likewise.
1088 2017-09-06  Richard Earnshaw  <rearnsha@arm.com>
1090         * config.gcc (arm*-*-*): Don't add arm-isa.h to tm_p_file.
1091         * config/arm/arm-isa.h: Delete.  Move definitions to ...
1092         * arm-cpus.in: ... here.  Use new feature and fgroup values.
1093         * config/arm/arm.c (arm_option_override): Use lower case for feature
1094         bit names.
1095         * config/arm/arm.h (TARGET_HARD_FLOAT): Likewise.
1096         (TARGET_VFP3, TARGET_VFP5, TARGET_FMA): Likewise.
1097         * config/arm/parsecpu.awk (END): Add new command 'isa'.
1098         (isa_pfx): Delete.
1099         (print_isa_bits_for): New function.
1100         (gen_isa): New function.
1101         (gen_comm_data): Use print_isa_bits_for.
1102         (define feature): New keyword.
1103         (define fgroup): New keyword.
1104         * config/arm/t-arm (OPTIONS_H_EXTRA): Add arm-isa.h
1105         (arm-isa.h): Add rule to generate file.
1106         * common/config/arm/arm-common.c: (arm_canon_arch_option): Use lower
1107         case for feature bit names.
1109 2017-09-06  Richard Biener  <rguenther@suse.de>
1111         * tree-ssa-pre.c (NECESSARY): Remove.
1112         (create_expression_by_pieces): Do not touch pass-local flags.
1113         (insert_into_preds_of_block): Likewise.
1114         (do_pre_regular_insertion): Likewise.
1115         (eliminate_insert): Likewise.
1116         (eliminate_dom_walker::before_dom_children): Likewise.
1117         (fini_eliminate): Do not look at inserted_exprs.
1118         (mark_operand_necessary): Remove.
1119         (remove_dead_inserted_code): Replace with simple work-list
1120         algorithm based on inserted_exprs and SSA uses.
1121         (pass_pre::execute): Re-order fini_eliminate and
1122         remove_dead_inserted_code.
1124 2017-09-06  Olivier Hainque  <hainque@adacore.com>
1126         * config/powerpcspe/vxworks.h (VXCPU_FOR_8548): Correct definition
1127         for VxWorks 7.  Adjust surrounding comments.
1129 2017-09-06  Richard Biener  <rguenther@suse.de>
1131         * gimple-ssa-strength-reduction.c
1132         (find_candidates_dom_walker::before_dom_children): Also allow
1133         pointer types.
1135 2017-09-06  Richard Biener  <rguenther@suse.de>
1137         PR tree-optimization/82108
1138         * tree-vect-stmts.c (vectorizable_load): Fix pointer adjustment
1139         for gap in the non-permutation SLP case.
1141 2017-09-06  Martin Jambor  <mjambor@suse.cz>
1143         PR tree-optimization/82078
1144         * tree-sra.c (sort_and_splice_var_accesses): Move call to
1145         add_access_to_work_queue...
1146         (build_accesses_from_assign): ...here.
1147         (propagate_all_subaccesses): Make sure racc is the group
1148         representative, if there is one.
1150 2017-09-06  Jakub Jelinek  <jakub@redhat.com>
1152         PR middle-end/82095
1153         * varasm.c (categorize_decl_for_section): Use SECCAT_TBSS for TLS vars with
1154         NULL DECL_INITIAL.
1156 2017-09-06  Richard Biener  <rguenther@suse.de>
1158         * gimple-ssa-strength-reduction.c
1159         (find_candidates_dom_walker::before_doom_children): Use a
1160         type and not a mode check.
1162 2017-09-06  Bernd Edlinger  <bernd.edlinger@hotmail.de>
1164         PR target/77308
1165         * config/arm/predicates.md (arm_general_adddi_operand): Create new
1166         non-vfp predicate.
1167         * config/arm/arm.md (*arm_adddi3, *arm_subdi3): Use new predicates.
1169 2017-09-05  Jeff Law  <law@redhat.com>
1171         PR tree-optimization/64910
1172         * tree-ssa-reassoc.c (reassociate_bb): Restrict last change to
1173         cases where we have 3 or more operands.
1175 2017-09-05  Jakub Jelinek  <jakub@redhat.com>
1177         PR middle-end/81768
1178         * omp-low.c (lower_omp_for): Recompute tree invariant if
1179         gimple_omp_for_initial/final is ADDR_EXPR.
1181         PR middle-end/81768
1182         * omp-expand.c (expand_omp_simd): Force second operands of COND_EXPR
1183         into gimple val before gimplification fo the COND_EXPR.
1185 2017-09-05  Aldy Hernandez  <aldyh@redhat.com>
1187         * tree-ssa-threadupdate.c (duplicate_thread_path): Remove unused
1188         REGION_COPY argument.
1189         (thread_through_all_blocks): Remove unused argument to
1190         duplicate_thread_path.
1192 2017-09-05  Richard Sandiford  <richard.sandiford@linaro.org>
1193             Alan Hayward  <alan.hayward@arm.com>
1194             David Sherwood  <david.sherwood@arm.com>
1196         * config/aarch64/aarch64-protos.h (aarch64_gen_adjusted_ldpstp):
1197         Take a scalar_mode rather than a machine_mode.
1198         (aarch64_operands_adjust_ok_for_ldpstp): Likewise.
1199         * config/aarch64/aarch64.c (aarch64_simd_container_mode): Likewise.
1200         (aarch64_operands_adjust_ok_for_ldpstp): Likewise.
1201         (aarch64_gen_adjusted_ldpstp): Likewise.
1202         (aarch64_expand_vector_init): Use scalar_mode instead of machine_mode.
1204 2017-09-05  Richard Sandiford  <richard.sandiford@linaro.org>
1205             Alan Hayward  <alan.hayward@arm.com>
1206             David Sherwood  <david.sherwood@arm.com>
1208         * config/aarch64/aarch64-protos.h (aarch64_is_extend_from_extract):
1209         Take a scalar_int_mode instead of a machine_mode.
1210         (aarch64_mask_and_shift_for_ubfiz_p): Likewise.
1211         (aarch64_output_scalar_simd_mov_immediate): Likewise.
1212         (aarch64_simd_scalar_immediate_valid_for_move): Likewise.
1213         (aarch64_simd_attr_length_rglist): Delete.
1214         * config/aarch64/aarch64.c (aarch64_is_extend_from_extract): Take
1215         a scalar_int_mode instead of a machine_mode.
1216         (aarch64_add_offset): Likewise.
1217         (aarch64_internal_mov_immediate): Likewise
1218         (aarch64_add_constant_internal): Likewise.
1219         (aarch64_add_constant): Likewise.
1220         (aarch64_movw_imm): Likewise.
1221         (aarch64_rtx_arith_op_extract_p): Likewise.
1222         (aarch64_mask_and_shift_for_ubfiz_p): Likewise.
1223         (aarch64_simd_scalar_immediate_valid_for_move): Likewise.
1224         Remove assert that the mode isn't a vector.
1225         (aarch64_output_scalar_simd_mov_immediate): Likewise.
1226         (aarch64_expand_mov_immediate): Update calls after above changes.
1227         (aarch64_output_casesi): Use as_a <scalar_int_mode>.
1228         (aarch64_and_bitmask_imm): Check for scalar integer modes.
1229         (aarch64_move_imm): Likewise.
1230         (aarch64_can_const_movi_rtx_p): Likewise.
1231         (aarch64_strip_extend): Likewise.
1232         (aarch64_extr_rtx_p): Likewise.
1233         (aarch64_rtx_costs): Likewise, using wode_mode as the mode of
1234         a CONST_INT when the mode parameter is VOIDmode.
1235         (aarch64_float_const_rtx_p): Use scalar_int_mode for a temporary.
1237 2017-09-05  Richard Sandiford  <richard.sandiford@linaro.org>
1239         * machmode.h (bitwise_mode_for_mode): Return opt_mode.
1240         * stor-layout.c (bitwise_mode_for_mode): Likewise.
1241         (bitwise_type_for_mode): Update accordingly.
1243 2017-09-05  Richard Sandiford  <richard.sandiford@linaro.org>
1245         * stor-layout.h (mode_for_size_tree): Return an opt_mode.
1246         * stor-layout.c (mode_for_size_tree): Likewise.
1247         (mode_for_array): Update accordingly.
1248         (layout_decl): Likewise.
1249         (compute_record_mode): Likewise.  Only set the mode once.
1251 2017-09-05  Richard Sandiford  <richard.sandiford@linaro.org>
1253         * target.def (get_mask_mode): Change return type to opt_mode.
1254         Expand commentary.
1255         * doc/tm.texi: Regenerate.
1256         * targhooks.h (default_get_mask_mode): Return an opt_mode.
1257         * targhooks.c (default_get_mask_mode): Likewise.
1258         * config/i386/i386.c (ix86_get_mask_mode): Likewise.
1259         * optabs-query.c (can_vec_mask_load_store_p): Update use of
1260         targetm.get_mask_mode.
1261         * tree.c (build_truth_vector_type): Likewise.
1263 2017-09-05  Richard Sandiford  <richard.sandiford@linaro.org>
1265         * machmode.h (mode_for_vector): Return an opt_mode.
1266         * stor-layout.c (mode_for_vector): Likewise.
1267         (mode_for_int_vector): Update accordingly.
1268         (layout_type): Likewise.
1269         * config/i386/i386.c (emit_memmov): Likewise.
1270         (ix86_expand_set_or_movmem): Likewise.
1271         (ix86_expand_vector_init): Likewise.
1272         (ix86_get_mask_mode): Likewise.
1273         * config/powerpcspe/powerpcspe.c (rs6000_expand_vec_perm_const_1):
1274         Likewise.
1275         * config/rs6000/rs6000.c (rs6000_expand_vec_perm_const_1): Likewise.
1276         * expmed.c (extract_bit_field_1): Likewise.
1277         * expr.c (expand_expr_real_2): Likewise.
1278         * optabs-query.c (can_vec_perm_p): Likewise.
1279         (can_vec_mask_load_store_p): Likewise.
1280         * optabs.c (expand_vec_perm): Likewise.
1281         * targhooks.c (default_get_mask_mode): Likewise.
1282         * tree-vect-stmts.c (vectorizable_store): Likewise.
1283         (vectorizable_load): Likewise.
1284         (get_vectype_for_scalar_type_and_size): Likewise.
1286 2017-09-05  Richard Sandiford  <richard.sandiford@linaro.org>
1288         * machmode.h (mode_for_int_vector): New function.
1289         * stor-layout.c (mode_for_int_vector): Likewise.
1290         * config/aarch64/aarch64.c (aarch64_emit_approx_sqrt): Use it.
1291         * config/powerpcspe/powerpcspe.c (rs6000_do_expand_vec_perm): Likewise.
1292         * config/rs6000/rs6000.c (rs6000_do_expand_vec_perm): Likewise.
1293         * config/s390/s390.c (s390_expand_vec_compare_cc): Likewise.
1294         (s390_expand_vcond): Likewise.
1296 2017-09-05  Richard Sandiford  <richard.sandiford@linaro.org>
1298         * machmode.h (opt_machine_mode): New type.
1299         (opt_mode<T>): Allow construction from anything that can be
1300         converted to a T.
1301         (is_a, as_a, dyn_cast): Add overloads for opt_mode.
1302         (mode_for_size): Return an opt_machine_mode.
1303         * stor-layout.c (mode_for_size): Likewise.
1304         (mode_for_size_tree): Update call accordingly.
1305         (bitwise_mode_for_mode): Likewise.
1306         (make_fract_type): Likewise.
1307         (make_accum_type): Likewise.
1308         * caller-save.c (replace_reg_with_saved_mem): Update call
1309         accordingly.
1310         * config/alpha/alpha.h (SECONDARY_MEMORY_NEEDED_MODE): Likewise.
1311         * config/i386/i386.h (SECONDARY_MEMORY_NEEDED_MODE): Likewise.
1312         * config/s390/s390.h (SECONDARY_MEMORY_NEEDED_MODE): Likewise.
1313         * config/sparc/sparc.h (SECONDARY_MEMORY_NEEDED_MODE): Likewise.
1314         * expmed.c (extract_bit_field_1): Likewise.
1315         * reload.c (get_secondary_mem): Likewise.
1316         * varasm.c (assemble_integer): Likewise.
1317         * lower-subreg.c (simplify_subreg_concatn): Likewise.  Move
1318         early-out.
1320 2017-09-05  Richard Sandiford  <richard.sandiford@linaro.org>
1322         * machmode.h (decimal_float_mode_for_size): New function.
1323         * real.h (REAL_VALUE_TO_TARGET_LONG_DOUBLE): Use float_mode_for_size.
1324         (REAL_VALUE_TO_TARGET_DOUBLE): Likewise.
1325         (REAL_VALUE_TO_TARGET_SINGLE): Likewise.
1326         (REAL_VALUE_TO_TARGET_DECIMAL128): Use decimal_float_mode_for_size.
1327         (REAL_VALUE_TO_TARGET_DECIMAL64): Likewise.
1328         (REAL_VALUE_TO_TARGET_DECIMAL32): Likewise.
1330 2017-09-05  Richard Sandiford  <richard.sandiford@linaro.org>
1332         * builtins.c (expand_builtin_powi): Use int_mode_for_size.
1333         (get_builtin_sync_mode): Likewise.
1334         (expand_ifn_atomic_compare_exchange): Likewise.
1335         (expand_builtin_atomic_clear): Likewise.
1336         (expand_builtin_atomic_test_and_set): Likewise.
1337         (fold_builtin_atomic_always_lock_free): Likewise.
1338         * calls.c (compute_argument_addresses): Likewise.
1339         (emit_library_call_value_1): Likewise.
1340         (store_one_arg): Likewise.
1341         * combine.c (combine_instructions): Likewise.
1342         * config/aarch64/aarch64.c (aarch64_function_value): Likewise.
1343         * config/arm/arm.c (arm_function_value): Likewise.
1344         (aapcs_allocate_return_reg): Likewise.
1345         * config/c6x/c6x.c (c6x_expand_movmem): Likewise.
1346         * config/i386/i386.c (construct_container): Likewise.
1347         (ix86_gimplify_va_arg): Likewise.
1348         (ix86_expand_sse_cmp): Likewise.
1349         (emit_memmov): Likewise.
1350         (emit_memset): Likewise.
1351         (expand_small_movmem_or_setmem): Likewise.
1352         (ix86_expand_pextr): Likewise.
1353         (ix86_expand_pinsr): Likewise.
1354         * config/lm32/lm32.c (lm32_block_move_inline): Likewise.
1355         * config/microblaze/microblaze.c (microblaze_block_move_straight):
1356         Likewise.
1357         * config/mips/mips.c (mips_function_value_1) Likewise.
1358         (mips_block_move_straight): Likewise.
1359         (mips_expand_ins_as_unaligned_store): Likewise.
1360         * config/powerpcspe/powerpcspe.c
1361         (rs6000_darwin64_record_arg_advance_flush): Likewise.
1362         (rs6000_darwin64_record_arg_flush): Likewise.
1363         * config/rs6000/rs6000.c
1364         (rs6000_darwin64_record_arg_advance_flush): Likewise.
1365         (rs6000_darwin64_record_arg_flush): Likewise.
1366         * config/sparc/sparc.c (sparc_function_arg_1): Likewise.
1367         (sparc_function_value_1): Likewise.
1368         * config/spu/spu.c (adjust_operand): Likewise.
1369         (spu_emit_branch_or_set): Likewise.
1370         (arith_immediate_p): Likewise.
1371         * emit-rtl.c (gen_lowpart_common): Likewise.
1372         * expr.c (expand_expr_real_1): Likewise.
1373         * function.c (assign_parm_setup_block): Likewise.
1374         * gimple-ssa-store-merging.c (encode_tree_to_bitpos): Likewise.
1375         * reload1.c (alter_reg): Likewise.
1376         * stor-layout.c (mode_for_vector): Likewise.
1377         (layout_type): Likewise.
1379 2017-09-05  Richard Sandiford  <richard.sandiford@linaro.org>
1381         * config/spu/spu.c (exp2_immediate_p): Use int_mode_for_mode.
1382         (spu_convert_move): Likewise.
1383         * lower-subreg.c (resolve_simple_move): Likewise.
1385 2017-09-05  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
1387         PR target/81833
1388         * config/rs6000/altivec.md (altivec_vsum2sws): Convert from a
1389         define_insn to a define_expand.
1390         (altivec_vsum2sws_direct): New define_insn.
1391         (altivec_vsumsws): Convert from a define_insn to a define_expand.
1393 2017-09-05  Wilco Dijkstra  <wdijkstr@arm.com>
1395         * config/arm/arm.c (arm_option_params_internal): Improve setting of
1396         max_insns_skipped.
1398 2017-09-05  H.J. Lu  <hongjiu.lu@intel.com>
1400         PR target/59501
1401         PR target/81624
1402         PR target/81769
1403         * config/i386/i386.c (ix86_finalize_stack_frame_flags): Don't
1404         realign stack if stack alignment needed is less than incoming
1405         stack boundary.
1407 2017-09-05  Marek Polacek  <polacek@redhat.com>
1409         PR sanitizer/82072
1410         * convert.c (convert_to_integer_1) <case NEGATE_EXPR>: Move the ubsan
1411         check earlier.
1413 2017-09-05  Wilco Dijkstra  <wdijkstr@arm.com>
1415         * explow.c (get_dynamic_stack_size): Improve dynamic alignment.
1417 2017-09-05  Richard Biener  <rguenther@suse.de>
1419         PR tree-optimization/82084
1420         * fold-const.c (can_native_encode_string_p): Handle wide characters.
1422 2017-09-05  Richard Biener  <rguenther@suse.de>
1424         PR tree-optimization/82102
1425         * tree-ssa-pre.c (fini_eliminate): Check if lhs is NULL.
1427 2017-09-05  Martin Liska  <mliska@suse.cz>
1429         PR tree-optimization/82032
1430         * tree-cfg.c (generate_range_test): New function.
1431         * tree-cfg.h (generate_range_test): Declared here.
1432         * tree-cfgcleanup.c (convert_single_case_switch): New function.
1433         (cleanup_control_expr_graph): Use it.
1434         * tree-switch-conversion.c (try_switch_expansion): Remove
1435         assert.
1436         (emit_case_nodes): Use generate_range_test.
1438 2017-09-04  Uros Bizjak  <ubizjak@gmail.com>
1440         PR target/82098
1441         * config/i386/i386.md (*<btsc><mode>_mask): Add
1442         TARGET_USE_BT to insn constraint.
1443         (*btr<mode>_mask): Ditto.
1445 2017-09-04  Wilco Dijkstra  <wdijkstr@arm.com>
1447         * config/arm/arm.c (arm_legitimate_index_p): Add comment.
1448         (thumb2_legitimate_index_p): Use correct range for DI/DF mode.
1450 2017-09-04  Bernd Edlinger  <bernd.edlinger@hotmail.de>
1452         PR target/77308
1453         * config/arm/arm.md (*arm_adddi3, *arm_subdi3): Split early except for
1454         TARGET_NEON and TARGET_IWMMXT.
1455         (anddi3, iordi3, xordi3, one_cmpldi2): Split while expanding except for
1456         TARGET_NEON and TARGET_IWMMXT.
1457         (*one_cmpldi2_insn): Moved the body of one_cmpldi2 here.
1459 2017-09-04  Uros Bizjak  <ubizjak@gmail.com>
1461         * config/i386/i386-protos.h (ix86_tls_address_pattern_p) New prototype.
1462         (ix86_rewrite_tls_address): Ditto.
1463         * config/i386/i386.c (ix86_tls_address_pattern_p) New function.
1464         (ix86_rewrite_tls_address_1): Ditto.
1465         (ix86_rewrite_tls_address): Ditto.
1466         * config/i386/predicates.md (tls_address_pattern): New predicate.
1467         * config/i386/i386.md (TLS address splitter): New splitter.
1469 2017-09-04  Richard Biener  <rguenther@suse.de>
1471         PR tree-optimization/82084
1472         * fold-const.h (can_native_encode_string_p): Declare.
1473         * fold-const.c (can_native_encode_string_p): Factor out from ...
1474         (native_encode_string): ... here.
1475         * tree-vect-stmts.c (vectorizable_store): Call it to avoid
1476         vectorizing stores from constants we later cannot handle.
1478 2017-09-04  Marek Polacek  <polacek@redhat.com>
1480         PR c/81783
1481         * doc/invoke.texi: Update -Wtautological-compare documentation.
1483 2017-09-04  Jeff Law  <law@redhat.com>
1485         PR tree-optimization/64910
1486         * tree-ssa-reassoc.c (reassociate_bb): For bitwise binary ops,
1487         swap the first and last operand if the last is a constant.
1489 2017-09-04  Marek Polacek  <polacek@redhat.com>
1491         PR sanitizer/82072
1492         * convert.c (do_narrow): When sanitizing signed integer overflows,
1493         bail out for signed types.
1494         (convert_to_integer_1) <case NEGATE_EXPR>: Likewise.
1496 2017-09-04  Richard Biener  <rguenther@suse.de>
1498         PR tree-optimization/82060
1499         * tree-ssa-pre.c (eliminate_dom_walker::before_dom_children):
1500         Move devirtualization after stmt folding and before EH/AB/noreturn
1501         cleanup to get the stmt refs canonicalized.  Use a bool instead
1502         of gimple_modified_p since that doesn't work for NOPs.  Schedule
1503         NOPs generated by folding for removal.
1505 2017-09-04  Richard Sandiford  <richard.sandiford@linaro.org>
1506             Alan Hayward  <alan.hayward@arm.com>
1507             David Sherwood  <david.sherwood@arm.com>
1509         * coretypes.h (pad_direction): New enum.
1510         * defaults.h (DEFAULT_FUNCTION_ARG_PADDING): Delete.
1511         (FUNCTION_ARG_PADDING): Likewise.
1512         * target.def (function_arg_padding): New hook.
1513         * targhooks.h (default_function_arg_padding): Declare.
1514         * targhooks.c (default_function_arg_padding): New function.
1515         * doc/tm.texi.in (FUNCTION_ARG_PADDING): Replace with...
1516         (TARGET_FUNCTION_ARG_PADDING): ...this.
1517         * doc/tm.texi: Regenerate.
1518         * calls.c (store_unaligned_arguments_into_pseudos): Use pad_direction
1519         instead of direction.
1520         (compute_argument_addresses): Likewise.
1521         (load_register_parameters): Likewise.
1522         (emit_library_call_value_1): Likewise.
1523         (store_one_arg): Use targetm.calls.function_arg_padding instead
1524         of FUNCTION_ARG_PADDING.
1525         (must_pass_in_stack_var_size_or_pad): Likewise.
1526         * expr.c (emit_group_load_1): Use pad_direction instead of direction.
1527         (emit_group_store): Likewise.
1528         (emit_single_push_insn_1): Use targetm.calls.function_arg_padding
1529         instead of FUNCTION_ARG_PADDING.
1530         (emit_push_insn): Likewise, and propagate enum change throughout
1531         function.
1532         * function.h (direction): Delete.
1533         (locate_and_pad_arg_data::where_pad): Use pad_direction instead
1534         of direction.
1535         * function.c (assign_parm_find_stack_rtl): Likewise.
1536         (assign_parm_setup_block_p): Likewise.
1537         (assign_parm_setup_block): Likewise.
1538         (gimplify_parameters): Likewise.
1539         (locate_and_pad_parm): Use targetm.calls.function_arg_padding
1540         instead of FUNCTION_ARG_PADDING, and propagate enum change throughout
1541         function.
1542         * config/aarch64/aarch64.h (FUNCTION_ARG_PADDING): Delete.
1543         (BLOCK_REG_PADDING): Use pad_direction instead of direction.
1544         * config/aarch64/aarch64-protos.h (aarch64_pad_arg_upward): Delete.
1545         * config/aarch64/aarch64.c (aarch64_pad_arg_upward): Replace with...
1546         (aarch64_function_arg_padding): ...this new function.
1547         (aarch64_gimplify_va_arg_expr): Use pad_direction instead of direction.
1548         (TARGET_FUNCTION_ARG_PADDING): Redefine.
1549         * config/arm/arm.h (FUNCTION_ARG_PADDING): Delete.
1550         (BLOCK_REG_PADDING): Use pad_direction instead of direction.
1551         * config/arm/arm-protos.h (arm_pad_arg_upward): Delete.
1552         * config/arm/arm.c (TARGET_FUNCTION_ARG_PADDING): Redefine.
1553         (arm_pad_arg_upward): Replace with...
1554         (arm_function_arg_padding): ...this new function.
1555         * config/c6x/c6x.h (BLOCK_REG_PADDING): Use pad_direction instead
1556         of direction.
1557         * config/ia64/hpux.h (FUNCTION_ARG_PADDING): Delete.
1558         * config/ia64/ia64-protos.h (ia64_hpux_function_arg_padding): Delete.
1559         * config/ia64/ia64.c (TARGET_FUNCTION_ARG_PADDING): Redefine.
1560         (ia64_hpux_function_arg_padding): Replace with...
1561         (ia64_function_arg_padding): ...this new function.  Use pad_direction
1562         instead of direction.  Check for TARGET_HPUX.
1563         * config/iq2000/iq2000.h (FUNCTION_ARG_PADDING): Delete.
1564         * config/iq2000/iq2000.c (TARGET_FUNCTION_ARG_PADDING): Redefine.
1565         (iq2000_function_arg_padding): New function.
1566         * config/mips/mips-protos.h (mips_pad_arg_upward): Delete.
1567         * config/mips/mips.c (mips_pad_arg_upward): Replace with...
1568         (mips_function_arg_padding): ...this new function.
1569         (mips_pad_reg_upward): Update accordingly.
1570         (TARGET_FUNCTION_ARG_PADDING): Redefine.
1571         * config/mips/mips.h (PAD_VARARGS_DOWN): Use
1572         targetm.calls.function_arg_padding.
1573         (FUNCTION_ARG_PADDING): Delete.
1574         (BLOCK_REG_PADDING): Use pad_direction instead of direction.
1575         * config/nios2/nios2.h (FUNCTION_ARG_PADDING): Delete.
1576         (PAD_VARARGS_DOWN): Use targetm.calls.function_arg_padding.
1577         * config/nios2/nios2-protos.h (nios2_function_arg_padding): Delete.
1578         (nios2_block_reg_padding): Return pad_direction instead of direction.
1579         * config/nios2/nios2.c (nios2_block_reg_padding): Return pad_direction
1580         instead of direction.
1581         (nios2_function_arg_padding): Likewise.  Make static.
1582         (TARGET_FUNCTION_ARG_PADDING): Redefine.
1583         * config/pa/pa.h (FUNCTION_ARG_PADDING): Delete.
1584         (BLOCK_REG_PADDING): Use targetm.calls.function_arg_padding.
1585         * config/pa/pa-protos.h (pa_function_arg_padding): Delete.
1586         * config/pa/pa.c (TARGET_FUNCTION_ARG_PADDING): Redefine.
1587         (pa_function_arg_padding): Make static.  Return pad_direction instead
1588         of direction.
1589         * config/powerpcspe/powerpcspe.h (FUNCTION_ARG_PADDING): Delete.
1590         (PAD_VARARGS_DOWN): Use targetm.calls.function_arg_padding.
1591         * config/powerpcspe/aix.h (BLOCK_REG_PADDING): Use pad_direction
1592         instead of direction.  Use targetm.calls.function_arg_padding.
1593         * config/powerpcspe/darwin.h (BLOCK_REG_PADDING): Likewise.
1594         * config/powerpcspe/freebsd64.h (BLOCK_REG_PADDING): Likewise.
1595         * config/powerpcspe/linux64.h (BLOCK_REG_PADDING): Likewise.
1596         * config/powerpcspe/powerpcspe-protos.h (function_arg_padding): Delete.
1597         * config/powerpcspe/powerpcspe.c (TARGET_FUNCTION_ARG_PADDING):
1598         Redefine.
1599         (function_arg_padding): Rename to...
1600         (rs6000_function_arg_padding): ...this.  Make static.  Return
1601         pad_direction instead of direction.
1602         (rs6000_return_in_msb): Use rs6000_function_arg_padding.
1603         * config/rs6000/rs6000.h (FUNCTION_ARG_PADDING): Delete.
1604         (PAD_VARARGS_DOWN): Use targetm.calls.function_arg_padding.
1605         * config/rs6000/aix.h (BLOCK_REG_PADDING): Use pad_direction
1606         instead of direction.  Use targetm.calls.function_arg_padding.
1607         * config/rs6000/darwin.h (BLOCK_REG_PADDING): Likewise.
1608         * config/rs6000/freebsd64.h (BLOCK_REG_PADDING): Likewise.
1609         * config/rs6000/linux64.h (BLOCK_REG_PADDING): Likewise.
1610         * config/rs6000/rs6000-protos.h (function_arg_padding): Delete.
1611         * config/rs6000/rs6000.c (TARGET_FUNCTION_ARG_PADDING): Redefine.
1612         (function_arg_padding): Rename to...
1613         (rs6000_function_arg_padding): ...this.  Make static.  Return
1614         pad_direction instead of direction.
1615         (rs6000_return_in_msb): Use rs6000_function_arg_padding.
1616         * config/s390/s390.h (FUNCTION_ARG_PADDING): Delete.
1617         * config/s390/s390.c (s390_function_arg_padding): New function.
1618         (TARGET_FUNCTION_ARG_PADDING): Redefine.
1619         * config/sparc/sparc.h (FUNCTION_ARG_PADDING): Delete.
1620         * config/sparc/sparc-protos.h (function_arg_padding): Delete.
1621         * config/sparc/sparc.c (TARGET_FUNCTION_ARG_PADDING): Redefine.
1622         (function_arg_padding): Rename to...
1623         (sparc_function_arg_padding): ...this.  Make static.  Return
1624         pad_direction instead of direction.
1625         * config/spu/spu.h (FUNCTION_ARG_PADDING): Delete.
1626         * config/spu/spu.c (spu_function_arg_padding): New function.
1627         (TARGET_FUNCTION_ARG_PADDING): Redefine.
1628         * system.h (FUNCTION_ARG_PADDING): Poison.
1630 2017-09-04  Richard Sandiford  <richard.sandiford@linaro.org>
1631             Alan Hayward  <alan.hayward@arm.com>
1632             David Sherwood  <david.sherwood@arm.com>
1634         * target.def (modes_tieable_p): New hook.
1635         * doc/tm.texi (MODES_TIEABLE_P): Replace with...
1636         (TARGET_MODES_TIEABLE_P): ...this.
1637         * doc/tm.texi.in: Regenerate.
1638         * hooks.h (hook_bool_mode_mode_true): Declare.
1639         * hooks.c (hook_bool_mode_mode_true): New function.
1640         * combine.c (subst): Use targetm.modes_tieable_p instead of
1641         MODES_TIEABLE_P.
1642         * dse.c (find_shift_sequence): Likewise.
1643         * expmed.c (extract_low_bits): Likewise.
1644         * lower-subreg.c: Include target.h.
1645         (find_decomposable_subregs): Use targetm.modes_tieable_p instead of
1646         MODES_TIEABLE_P.
1647         * rtlanal.c (rtx_cost): Likewise.
1648         * config/aarch64/aarch64.h (MODES_TIEABLE_P): Delete.
1649         * config/aarch64/aarch64-protos.h (aarch64_modes_tieable_p): Delete.
1650         * config/aarch64/aarch64.c (aarch64_modes_tieable_p): Make static.
1651         (TARGET_MODES_TIEABLE_P): Redefine.
1652         * config/alpha/alpha.h (MODES_TIEABLE_P): Delete.
1653         * config/alpha/alpha.c (alpha_modes_tieable_p): New function.
1654         (TARGET_MODES_TIEABLE_P): Redefine.
1655         * config/arc/arc.h (MODES_TIEABLE_P): Delete.
1656         * config/arc/arc.c (TARGET_MODES_TIEABLE_P): Redefine.
1657         (arc_modes_tieable_p): New function.
1658         * config/arm/arm.h (MODES_TIEABLE_P): Delete.
1659         * config/arm/arm-protos.h (arm_modes_tieable_p): Delete.
1660         * config/arm/arm.c (TARGET_MODES_TIEABLE_P): Redefine.
1661         (arm_modes_tieable_p): Make static.
1662         * config/avr/avr.h (MODES_TIEABLE_P): Delete.
1663         * config/bfin/bfin.h (MODES_TIEABLE_P): Delete.
1664         * config/bfin/bfin.c (bfin_modes_tieable_p): New function.
1665         (TARGET_MODES_TIEABLE_P): Redefine.
1666         * config/c6x/c6x.h (MODES_TIEABLE_P): Delete.
1667         * config/c6x/c6x.c (c6x_modes_tieable_p): New function.
1668         (TARGET_MODES_TIEABLE_P): Redefine.
1669         * config/cr16/cr16.h (MODES_TIEABLE_P): Delete.
1670         * config/cr16/cr16.c (TARGET_MODES_TIEABLE_P): Redefine.
1671         (cr16_modes_tieable_p): New function.
1672         * config/cris/cris.h (MODES_TIEABLE_P): Delete.
1673         * config/epiphany/epiphany.h (MODES_TIEABLE_P): Delete.
1674         * config/fr30/fr30.h (MODES_TIEABLE_P): Delete.
1675         (TRULY_NOOP_TRUNCATION): Update comment.
1676         * config/frv/frv.h (MODES_TIEABLE_P): Delete.
1677         (TRULY_NOOP_TRUNCATION): Update comment.
1678         * config/frv/frv.c (TARGET_MODES_TIEABLE_P): Redefine.
1679         (frv_modes_tieable_p): New function.
1680         * config/ft32/ft32.h (MODES_TIEABLE_P): Delete.
1681         * config/h8300/h8300.h (MODES_TIEABLE_P): Delete.
1682         * config/h8300/h8300.c (h8300_modes_tieable_p): New function.
1683         (TARGET_MODES_TIEABLE_P): Redefine.
1684         * config/i386/i386.h (MODES_TIEABLE_P): Delete.
1685         * config/i386/i386-protos.h (ix86_modes_tieable_p): Delete.
1686         * config/i386/i386.c (ix86_modes_tieable_p): Make static.
1687         (TARGET_MODES_TIEABLE_P): Redefine.
1688         * config/ia64/ia64.h (MODES_TIEABLE_P): Delete.
1689         * config/ia64/ia64.c (TARGET_MODES_TIEABLE_P): Redefine.
1690         (ia64_modes_tieable_p): New function.
1691         * config/iq2000/iq2000.h (MODES_TIEABLE_P): Delete.
1692         * config/iq2000/iq2000.c (TARGET_MODES_TIEABLE_P): Redefine.
1693         (iq2000_modes_tieable_p): New function.
1694         * config/lm32/lm32.h (MODES_TIEABLE_P): Delete.
1695         * config/lm32/lm32.c (TARGET_MODES_TIEABLE_P): Redefine.
1696         (lm32_modes_tieable_p): New function.
1697         * config/m32c/m32c.h (MODES_TIEABLE_P): Delete.
1698         * config/m32c/m32c-protos.h (m32c_modes_tieable_p): Delete.
1699         * config/m32c/m32c.c (m32c_modes_tieable_p): Make static.
1700         (TARGET_MODES_TIEABLE_P): Redefine.
1701         * config/m32r/m32r.h (MODES_TIEABLE_P): Delete.
1702         * config/m32r/m32r.c (TARGET_MODES_TIEABLE_P): Redefine.
1703         (m32r_modes_tieable_p): New function.
1704         * config/m68k/m68k.h (MODES_TIEABLE_P): Delete.
1705         * config/m68k/m68k.c (TARGET_MODES_TIEABLE_P): Redefine.
1706         (m68k_modes_tieable_p): New function.
1707         * config/mcore/mcore.h (MODES_TIEABLE_P): Delete.
1708         * config/mcore/mcore.c (TARGET_MODES_TIEABLE_P): Redefine.
1709         (mcore_modes_tieable_p): New function.
1710         * config/microblaze/microblaze.h (MODES_TIEABLE_P): Delete.
1711         * config/microblaze/microblaze.c (microblaze_modes_tieable_p): New
1712         function.
1713         (TARGET_MODES_TIEABLE_P): Redefine.
1714         * config/mips/mips.h (MODES_TIEABLE_P): Delete.
1715         * config/mips/mips-protos.h (mips_modes_tieable_p): Delete.
1716         * config/mips/mips.c (mips_modes_tieable_p): Make static.
1717         (TARGET_MODES_TIEABLE_P): Redefine.
1718         * config/mmix/mmix.h (MODES_TIEABLE_P): Delete.
1719         * config/mn10300/mn10300.h (MODES_TIEABLE_P): Delete.
1720         * config/mn10300/mn10300-protos.h (mn10300_modes_tieable): Delete.
1721         * config/mn10300/mn10300.c (mn10300_modes_tieable): Rename to...
1722         (mn10300_modes_tieable_p): ...this and make static.
1723         (TARGET_MODES_TIEABLE_P): Redefine.
1724         * config/moxie/moxie.h (MODES_TIEABLE_P): Delete.
1725         * config/msp430/msp430.h (MODES_TIEABLE_P): Delete.
1726         * config/msp430/msp430-protos.h (msp430_modes_tieable_p): Delete.
1727         * config/msp430/msp430.c (TARGET_MODES_TIEABLE_P): Redefine.
1728         (msp430_modes_tieable_p): Make static.
1729         * config/nds32/nds32.h (MODES_TIEABLE_P): Delete.
1730         * config/nds32/nds32.c (nds32_modes_tieable_p): New function.
1731         (TARGET_MODES_TIEABLE_P): Redefine.
1732         * config/nios2/nios2.h (MODES_TIEABLE_P): Delete.
1733         * config/nvptx/nvptx.h (MODES_TIEABLE_P): Delete.
1734         * config/nvptx/nvptx.c (nvptx_modes_tieable_p): New function.
1735         (TARGET_MODES_TIEABLE_P): Redefine.
1736         * config/pa/pa.h (MODES_TIEABLE_P): Delete.
1737         * config/pa/pa-protos.h (pa_modes_tieable_p): Delete.
1738         * config/pa/pa.c (pa_modes_tieable_p): Make static.
1739         (TARGET_MODES_TIEABLE_P): Redefine.
1740         * config/pdp11/pdp11.h (MODES_TIEABLE_P): Delete.
1741         * config/pdp11/pdp11.c (TARGET_MODES_TIEABLE_P): Redefine.
1742         (pdp11_modes_tieable_p): New function.
1743         * config/powerpcspe/powerpcspe.h (MODES_TIEABLE_P): Delete.
1744         * config/powerpcspe/powerpcspe.c (TARGET_MODES_TIEABLE_P): Redefine.
1745         (rs6000_modes_tieable_p): New function.
1746         (rs6000_debug_reg_global): Use it instead of MODES_TIEABLE_P.
1747         * config/powerpcspe/powerpcspe.md: Update comment.
1748         * config/riscv/riscv.h (MODES_TIEABLE_P): Delete.
1749         * config/riscv/riscv.c (riscv_modes_tieable_p): New function.
1750         (TARGET_MODES_TIEABLE_P): Redefine.
1751         * config/rl78/rl78.h (MODES_TIEABLE_P): Delete.
1752         * config/rl78/rl78.c (TARGET_MODES_TIEABLE_P): Redefine.
1753         (rl78_modes_tieable_p): New function.
1754         * config/rs6000/rs6000.h (MODES_TIEABLE_P): Delete.
1755         * config/rs6000/rs6000.c (TARGET_MODES_TIEABLE_P): Redefine.
1756         (rs6000_modes_tieable_p): New function.
1757         (rs6000_debug_reg_global): Use it instead of MODES_TIEABLE_P.
1758         * config/rs6000/rs6000.md: Update comment.
1759         * config/rx/rx.h (MODES_TIEABLE_P): Delete.
1760         * config/rx/rx.c (rx_modes_tieable_p): New function.
1761         (TARGET_MODES_TIEABLE_P): Redefine.
1762         * config/s390/s390.h (MODES_TIEABLE_P): Delete.
1763         * config/s390/s390.c (s390_modes_tieable_p): New function.
1764         (TARGET_MODES_TIEABLE_P): Redefine.
1765         * config/sh/sh.h (MODES_TIEABLE_P): Delete.
1766         * config/sh/sh.c (TARGET_MODES_TIEABLE_P): Redefine.
1767         (sh_modes_tieable_p): New function.
1768         * config/sparc/sparc.h (MODES_TIEABLE_P): Delete.
1769         * config/sparc/sparc-protos.h (sparc_modes_tieable_p): Delete.
1770         * config/sparc/sparc.c (TARGET_MODES_TIEABLE_P): Redefine.
1771         (sparc_modes_tieable_p): Make static.
1772         * config/spu/spu.h (MODES_TIEABLE_P): Delete.
1773         * config/spu/spu.c (spu_modes_tieable_p): New function.
1774         (TARGET_MODES_TIEABLE_P): Redefine.
1775         * config/stormy16/stormy16.h (MODES_TIEABLE_P): Delete.
1776         * config/stormy16/stormy16.c (xstormy16_modes_tieable_p): New function.
1777         (TARGET_MODES_TIEABLE_P): Redefine.
1778         * config/tilegx/tilegx.h (MODES_TIEABLE_P): Delete.
1779         * config/tilepro/tilepro.h (MODES_TIEABLE_P): Delete.
1780         * config/v850/v850.h (MODES_TIEABLE_P): Delete.
1781         * config/v850/v850.c (v850_modes_tieable_p): New function.
1782         (TARGET_MODES_TIEABLE_P): Redefine.
1783         * config/vax/vax.h (MODES_TIEABLE_P): Delete.
1784         * config/visium/visium.h (MODES_TIEABLE_P): Delete.
1785         * config/visium/visium.c (TARGET_MODES_TIEABLE_P): Redefine.
1786         (visium_modes_tieable_p): New function.
1787         * config/xtensa/xtensa.h (MODES_TIEABLE_P): Delete.
1788         * config/xtensa/xtensa.c (TARGET_MODES_TIEABLE_P): Redefine.
1789         (xtensa_modes_tieable_p): New function.
1790         * system.h (MODES_TIEABLE_P): Poison.
1792 2017-09-04  Richard Sandiford  <richard.sandiford@linaro.org>
1793             Alan Hayward  <alan.hayward@arm.com>
1794             David Sherwood  <david.sherwood@arm.com>
1796         * target.def (hard_regno_mode_ok): New hook.
1797         * doc/tm.texi (HARD_REGNO_MODE_OK): Replace with...
1798         (TARGET_HARD_REGNO_MODE_OK): ...this.
1799         * doc/tm.texi.in: Regenerate.
1800         * hooks.h (hook_bool_uint_mode_true): Declare.
1801         * hooks.c (hook_bool_uint_mode_true): New function.
1802         * doc/md.texi: Refer to targetm.hard_regno_mode_ok instead of
1803         HARD_REGNO_MODE_OK.
1804         * genpreds.c (write_insn_preds_c): Add an include of target.h.
1805         * alias.c (init_alias_target): Use targetm.hard_regno_mode_ok
1806         instead of HARD_REGNO_MODE_OK.
1807         * caller-save.c: Include target.h.
1808         (reg_save_code): Use targetm.hard_regno_mode_ok instead of
1809         HARD_REGNO_MODE_OK.
1810         * combine.c (can_combine_p): Likewise.
1811         (combinable_i3pat): Likewise.
1812         (can_change_dest_mode): Likewise.
1813         * expr.c (init_expr_target): Likewise.
1814         (convert_move): Likewise.
1815         (convert_modes): Likewise.
1816         * ira.c (setup_prohibited_class_mode_regs): Likewise.
1817         (setup_prohibited_mode_move_regs): Likewise.
1818         * ira.h (target_ira): Likewise.
1819         * lra-assigns.c (find_hard_regno_for_1): Likewise.
1820         * lra-constraints.c (process_alt_operands): Likewise.
1821         (split_reg): Likewise.
1822         * recog.c (peep2_find_free_register): Likewise.
1823         * ree.c (combine_reaching_defs): Likewise.
1824         * regcprop.c (maybe_mode_change): Likewise.
1825         * reginfo.c (init_reg_sets_1): Likewise.
1826         (choose_hard_reg_mode): Likewise.
1827         (simplifiable_subregs): Likewise.
1828         * regrename.c (check_new_reg_p): Likewise.
1829         * reload.c (find_valid_class): Likewise.
1830         (find_valid_class_1): Likewise.
1831         (reload_inner_reg_of_subreg): Likewise.
1832         (push_reload): Likewise.
1833         (combine_reloads): Likewise.
1834         (find_dummy_reload): Likewise.
1835         (find_reloads): Likewise.
1836         * reload1.c (find_reg): Likewise.
1837         (set_reload_reg): Likewise.
1838         (allocate_reload_reg): Likewise.
1839         (choose_reload_regs): Likewise.
1840         (reload_adjust_reg_for_temp): Likewise.
1841         * rtlanal.c (subreg_size_offset_from_lsb): Likewise.
1842         (simplify_subreg_regno): Likewise.
1843         * sel-sched.c (init_regs_for_mode): Likewise.
1844         * varasm.c (make_decl_rtl): Likewise.
1845         * config/aarch64/aarch64.h (HARD_REGNO_MODE_OK): Delete.
1846         (MODES_TIEABLE_P): Use targetm.hard_regno_mode_ok instead of
1847         HARD_REGNO_MODE_OK.
1848         * config/aarch64/aarch64-protos.h (aarch64_hard_regno_mode_ok): Delete.
1849         * config/aarch64/aarch64.c (aarch64_hard_regno_mode_ok): Make static.
1850         (TARGET_HARD_REGNO_MODE_OK): Redefine.
1851         * config/alpha/alpha.h (HARD_REGNO_MODE_OK): Delete.
1852         * config/alpha/alpha.c (alpha_hard_regno_mode_ok): New function.
1853         (TARGET_HARD_REGNO_MODE_OK): Redefine.
1854         * config/arc/arc.h (arc_hard_regno_mode_ok): Delete.
1855         (arc_mode_class): Delete.
1856         (HARD_REGNO_MODE_OK): Delete.
1857         * config/arc/arc.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
1858         (arc_hard_regno_mode_ok): Rename old array to...
1859         (arc_hard_regno_mode_ok_modes): ...this.
1860         (arc_conditional_register_usage): Update accordingly.
1861         (arc_mode_class): Make static.
1862         (arc_hard_regno_mode_ok): New function.
1863         * config/arm/arm.h (HARD_REGNO_MODE_OK): Delete.
1864         * config/arm/arm-protos.h (arm_hard_regno_mode_ok): Delete.
1865         * config/arm/arm.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
1866         (arm_hard_regno_mode_ok): Make static.
1867         * config/arm/arm.md (movdi): Use targetm.hard_regno_mode_ok instead of
1868         HARD_REGNO_MODE_OK.
1869         * config/avr/avr-protos.h (avr_hard_regno_mode_ok): Delete.
1870         * config/avr/avr.h (HARD_REGNO_MODE_OK): Delete.
1871         * config/avr/avr.c (avr_hard_regno_mode_ok): Make static and
1872         return a bool.
1873         (TARGET_HARD_REGNO_MODE_OK): Redefine.
1874         * config/bfin/bfin-protos.h (hard_regno_mode_ok): Delete.
1875         * config/bfin/bfin.h (HARD_REGNO_MODE_OK): Delete.
1876         * config/bfin/bfin.c (hard_regno_mode_ok): Rename to...
1877         (bfin_hard_regno_mode_ok): ...this.  Make static and return a bool.
1878         (TARGET_HARD_REGNO_MODE_OK): Redefine.
1879         * config/bfin/predicates.md (valid_reg_operand): Use
1880         targetm.hard_regno_mode_ok instead of HARD_REGNO_MODE_OK.
1881         * config/c6x/c6x.h (HARD_REGNO_MODE_OK): Delete.
1882         * config/c6x/c6x.c (c6x_hard_regno_mode_ok): New function.
1883         (TARGET_HARD_REGNO_MODE_OK): Redefine.
1884         * config/cr16/cr16.h (HARD_REGNO_MODE_OK): Delete.
1885         * config/cr16/cr16-protos.h (cr16_hard_regno_mode_ok): Delete.
1886         * config/cr16/cr16.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
1887         (cr16_hard_regno_mode_ok): Make static and return a bool.
1888         * config/cris/cris.h (HARD_REGNO_MODE_OK): Delete.
1889         * config/cris/cris.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
1890         (cris_hard_regno_mode_ok): New function.
1891         * config/epiphany/epiphany.h (epiphany_hard_regno_mode_ok): Delete.
1892         (epiphany_mode_class): Delete.
1893         (HARD_REGNO_MODE_OK): Delete.
1894         * config/epiphany/epiphany-protos.h (hard_regno_mode_ok): Delete.
1895         * config/epiphany/epiphany.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
1896         (hard_regno_mode_ok): Rename to...
1897         (epiphany_hard_regno_mode_ok): ...this.  Make static and return a bool.
1898         * config/fr30/fr30.h (HARD_REGNO_MODE_OK): Delete.
1899         * config/fr30/fr30.md: Refer to targetm.hard_regno_mode_ok instead of
1900         HARD_REGNO_MODE_OK.
1901         * config/frv/frv.h (HARD_REGNO_MODE_OK): Delete.
1902         * config/frv/frv-protos.h (frv_hard_regno_mode_ok): Delete.
1903         * config/frv/frv.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
1904         (frv_hard_regno_mode_ok): Make static and return a bool.
1905         * config/frv/frv.md: Refer to targetm.hard_regno_mode_ok instead of
1906         HARD_REGNO_MODE_OK.
1907         * config/ft32/ft32.h (HARD_REGNO_MODE_OK): Delete.
1908         * config/h8300/h8300.h (HARD_REGNO_MODE_OK): Delete.
1909         * config/h8300/h8300-protos.h (h8300_hard_regno_mode_ok): Delete.
1910         * config/h8300/h8300.c (h8300_hard_regno_mode_ok): Make static
1911         and return a bool.
1912         (TARGET_HARD_REGNO_MODE_OK): Redefine.
1913         * config/i386/i386.h (HARD_REGNO_MODE_OK): Delete.
1914         * config/i386/i386-protos.h (ix86_hard_regno_mode_ok): Delete.
1915         * config/i386/i386.c (ix86_hard_regno_mode_ok): Make static and
1916         return a bool.
1917         (TARGET_HARD_REGNO_MODE_OK): Redefine.
1918         * config/ia64/ia64.h (HARD_REGNO_MODE_OK): Delete.
1919         * config/ia64/ia64.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
1920         (ia64_hard_regno_mode_ok): New function.
1921         * config/iq2000/iq2000.h (HARD_REGNO_MODE_OK): Delete.
1922         * config/iq2000/iq2000.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
1923         (iq2000_hard_regno_mode_ok): New function.
1924         * config/lm32/lm32.h (HARD_REGNO_MODE_OK): Delete.
1925         * config/lm32/lm32.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
1926         (lm32_hard_regno_mode_ok): New function.
1927         * config/m32c/m32c.h (HARD_REGNO_MODE_OK): Delete.
1928         * config/m32c/m32c-protos.h (m32c_hard_regno_ok): Delete.
1929         * config/m32c/m32c.c (class_can_hold_mode): Use m32c_hard_regno_mode_ok
1930         instead of HARD_REGNO_MODE_OK.
1931         (m32c_hard_regno_ok): Rename to...
1932         (m32c_hard_regno_mode_ok): ...this.  Make static and return a bool.
1933         (m32c_cannot_change_mode_class): Update accordingly.
1934         (TARGET_HARD_REGNO_MODE_OK): Redefine.
1935         * config/m32r/m32r.h (m32r_hard_regno_mode_ok): Delete.
1936         (m32r_mode_class): Delete.
1937         (HARD_REGNO_MODE_OK): Delete.
1938         * config/m32r/m32r.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
1939         (m32r_hard_regno_mode_ok): Rename to...
1940         (m32r_hard_regno_modes): ...this.
1941         (m32r_mode_class): Make static.
1942         (m32r_hard_regno_mode_ok): New function.
1943         * config/m68k/m68k.h (HARD_REGNO_MODE_OK): Delete.
1944         * config/m68k/m68k-protos.h (m68k_regno_mode_ok): Delete.
1945         * config/m68k/m68k.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
1946         (m68k_hard_regno_mode_ok): Make static.
1947         * config/mcore/mcore.h (HARD_REGNO_MODE_OK): Delete.
1948         * config/mcore/mcore.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
1949         (mcore_hard_regno_mode_ok): New function.
1950         * config/microblaze/microblaze.h (microblaze_hard_regno_mode_ok)
1951         (HARD_REGNO_MODE_OK): Delete.
1952         * config/microblaze/microblaze.c (microblaze_hard_regno_mode_ok):
1953         Rename to...
1954         (microblaze_hard_regno_mode_ok_p): ...this and make static.
1955         (microblaze_hard_regno_mode_ok): New function.
1956         (TARGET_HARD_REGNO_MODE_OK): Redefine.
1957         * config/mips/mips.h (HARD_REGNO_MODE_OK): Delete.
1958         (mips_hard_regno_mode_ok): Delete.
1959         * config/mips/mips.c (mips_hard_regno_mode_ok): Rename to...
1960         (mips_hard_regno_mode_ok_p): ...this and make static.
1961         (mips_hard_regno_mode_ok_p): Rename to...
1962         (mips_hard_regno_mode_ok_uncached): ...this.
1963         (mips_hard_regno_mode_ok): New function.
1964         (mips_class_max_nregs): Use mips_hard_regno_mode_ok instead
1965         of HARD_REGNO_MODE_OK.
1966         (mips_option_override): Update after above name changes.
1967         (TARGET_HARD_REGNO_MODE_OK): Redefine.
1968         * config/mmix/mmix.h (HARD_REGNO_MODE_OK): Delete.
1969         * config/mn10300/mn10300.h (HARD_REGNO_MODE_OK): Delete.
1970         * config/mn10300/mn10300-protos.h (mn10300_hard_regno_mode_ok): Delete.
1971         * config/mn10300/mn10300.c (mn10300_hard_regno_mode_ok): Make static.
1972         (TARGET_HARD_REGNO_MODE_OK): Redefine.
1973         * config/moxie/moxie.h (HARD_REGNO_MODE_OK): Delete.
1974         * config/msp430/msp430.h (HARD_REGNO_MODE_OK): Delete.
1975         * config/msp430/msp430-protos.h (msp430_hard_regno_mode_ok): Delete.
1976         * config/msp430/msp430.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
1977         (msp430_hard_regno_mode_ok): Make static and return a bool.
1978         * config/nds32/nds32.h (HARD_REGNO_MODE_OK): Delete.
1979         * config/nds32/nds32-protos.h (nds32_hard_regno_mode_ok): Delete.
1980         * config/nds32/nds32.c (nds32_hard_regno_mode_ok): Make static
1981         and return a bool.
1982         (TARGET_HARD_REGNO_MODE_OK): Redefine.
1983         * config/nios2/nios2.h (HARD_REGNO_MODE_OK): Delete.
1984         * config/nvptx/nvptx.h (HARD_REGNO_MODE_OK): Delete.
1985         * config/pa/pa.h (MODES_TIEABLE_P): Update commentary.
1986         * config/pa/pa32-regs.h (HARD_REGNO_MODE_OK): Rename to...
1987         (PA_HARD_REGNO_MODE_OK): ...this
1988         * config/pa/pa64-regs.h (HARD_REGNO_MODE_OK): Rename to...
1989         (PA_HARD_REGNO_MODE_OK): ...this.
1990         * config/pa/pa.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
1991         (pa_hard_regno_mode_ok): New function.
1992         * config/pdp11/pdp11.h (HARD_REGNO_MODE_OK): Delete.
1993         * config/pdp11/pdp11.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
1994         (pdp11_hard_regno_mode_ok): New function.
1995         * config/powerpcspe/powerpcspe.h (HARD_REGNO_MODE_OK): Delete.
1996         * config/powerpcspe/powerpcspe-protos.h (rs6000_hard_regno_mode_ok_p):
1997         Delete.
1998         * config/powerpcspe/powerpcspe.c (rs6000_hard_regno_mode_ok_p):
1999         Make static.
2000         (TARGET_HARD_REGNO_MODE_OK): Redefine.
2001         (rs6000_hard_regno_mode_ok): Rename to...
2002         (rs6000_hard_regno_mode_ok_uncached): ...this.
2003         (rs6000_init_hard_regno_mode_ok): Update accordingly.
2004         (rs6000_hard_regno_mode_ok): New function.
2005         * config/riscv/riscv.h (HARD_REGNO_MODE_OK): Delete.
2006         * config/riscv/riscv-protos.h (riscv_hard_regno_mode_ok_p): Delete.
2007         * config/riscv/riscv.c (riscv_hard_regno_mode_ok_p): Rename to...
2008         (riscv_hard_regno_mode_ok): ...this and make static.
2009         (TARGET_HARD_REGNO_MODE_OK): Redefine.
2010         * config/rl78/rl78.h (HARD_REGNO_MODE_OK): Delete.
2011         * config/rl78/rl78-protos.h (rl78_hard_regno_mode_ok): Delete.
2012         * config/rl78/rl78.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
2013         (rl78_hard_regno_mode_ok): Make static and return bool.
2014         * config/rs6000/rs6000.h (HARD_REGNO_MODE_OK): Delete.
2015         * config/rs6000/rs6000-protos.h (rs6000_hard_regno_mode_ok_p):
2016         Delete.
2017         * config/rs6000/rs6000.c (rs6000_hard_regno_mode_ok_p): Make static.
2018         (TARGET_HARD_REGNO_MODE_OK): Redefine.
2019         (rs6000_hard_regno_mode_ok): Rename to...
2020         (rs6000_hard_regno_mode_ok_uncached): ...this.
2021         (rs6000_init_hard_regno_mode_ok): Update accordingly.
2022         (rs6000_hard_regno_mode_ok): New function.
2023         * config/rx/rx.h (HARD_REGNO_MODE_OK): Delete.
2024         * config/rx/rx.c (rx_hard_regno_mode_ok): New function.
2025         (TARGET_HARD_REGNO_MODE_OK): Redefine.
2026         * config/s390/s390.h (HARD_REGNO_MODE_OK): Delete.
2027         * config/s390/s390-protos.h (s390_hard_regno_mode_ok): Delete.
2028         * config/s390/s390.c (s390_hard_regno_mode_ok): Make static.
2029         (TARGET_HARD_REGNO_MODE_OK): Redefine.
2030         * config/sh/sh.h (HARD_REGNO_MODE_OK): Delete.
2031         * config/sh/sh-protos.h (sh_hard_regno_mode_ok): Delete.
2032         * config/sh/sh.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
2033         (sh_hard_regno_mode_ok): Make static.
2034         * config/sparc/constraints.md: Refer to targetm.hard_regno_mode_ok
2035         instead of HARD_REGNO_MODE_OK.
2036         * config/sparc/sparc.h (hard_regno_mode_classes): Delete.
2037         (sparc_mode_class): Delete.
2038         (HARD_REGNO_MODE_OK): Delete.
2039         * config/sparc/sparc.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
2040         (hard_regno_mode_classes): Make static.
2041         (sparc_mode_class): Likewise.
2042         (sparc_hard_regno_mode_ok): New function.
2043         * config/spu/spu.h (HARD_REGNO_MODE_OK): Delete.
2044         * config/stormy16/stormy16.h (HARD_REGNO_MODE_OK): Delete.
2045         * config/stormy16/stormy16.c (xstormy16_hard_regno_mode_ok): New
2046         function.
2047         (TARGET_HARD_REGNO_MODE_OK): Redefine.
2048         * config/tilegx/tilegx.h (HARD_REGNO_MODE_OK): Delete.
2049         * config/tilepro/tilepro.h (HARD_REGNO_MODE_OK): Delete.
2050         * config/v850/v850.h (HARD_REGNO_MODE_OK): Delete.
2051         * config/v850/v850.c (v850_hard_regno_mode_ok): New function.
2052         (TARGET_HARD_REGNO_MODE_OK): Redefine.
2053         * config/vax/vax.h (HARD_REGNO_MODE_OK): Delete.
2054         * config/visium/visium.h (HARD_REGNO_MODE_OK): Delete.
2055         * config/visium/visium.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
2056         (visium_hard_regno_mode_ok): New function.
2057         * config/visium/visium.md: Refer to targetm.hard_regno_mode_ok
2058         instead of HARD_REGNO_MODE_OK.
2059         * config/xtensa/xtensa.h (xtensa_hard_regno_mode_ok): Delete.
2060         (HARD_REGNO_MODE_OK): Delete.
2061         * config/xtensa/xtensa.c (xtensa_hard_regno_mode_ok): Rename to...
2062         (xtensa_hard_regno_mode_ok_p): ...this and make static.
2063         (xtensa_option_override): Update accordingly.
2064         (TARGET_HARD_REGNO_MODE_OK): Redefine.
2065         (xtensa_hard_regno_mode_ok): New function.
2066         * system.h (HARD_REGNO_MODE_OK): Poison.
2068 2017-09-04  Richard Sandiford  <richard.sandiford@linaro.org>
2069             Alan Hayward  <alan.hayward@arm.com>
2070             David Sherwood  <david.sherwood@arm.com>
2072         * target.def (hard_regno_call_part_clobbered): New hook.
2073         * doc/tm.texi.in (HARD_REGNO_CALL_PART_CLOBBERED): Replace with...
2074         (TARGET_HARD_REGNO_CALL_PART_CLOBBERED): ...this hook.
2075         * doc/tm.texi: Regenerate.
2076         * hooks.h (hook_bool_uint_mode_false): Declare.
2077         * hooks.c (hook_bool_uint_mode_false): New function.
2078         * regs.h (HARD_REGNO_CALL_PART_CLOBBERED): Delete.
2079         * cselib.c (cselib_process_insn): Use
2080         targetm.hard_regno_call_part_clobbered instead of
2081         HARD_REGNO_CALL_PART_CLOBBERED.
2082         * ira-conflicts.c (ira_build_conflicts): Likewise.
2083         * ira-costs.c (ira_tune_allocno_costs): Likewise.
2084         * lra-constraints.c (need_for_call_save_p): Likewise.
2085         * lra-lives.c: Include target.h.
2086         (check_pseudos_live_through_calls): Use
2087         targetm.hard_regno_call_part_clobbered instead of
2088         HARD_REGNO_CALL_PART_CLOBBERED.
2089         * regcprop.c: Include target.h.
2090         (copyprop_hardreg_forward_1): Use
2091         targetm.hard_regno_call_part_clobbered instead of
2092         HARD_REGNO_CALL_PART_CLOBBERED.
2093         * reginfo.c (choose_hard_reg_mode): Likewise.
2094         * regrename.c (check_new_reg_p): Likewise.
2095         * reload.c (find_equiv_reg): Likewise.
2096         * reload1.c (emit_reload_insns): Likewise.
2097         * sched-deps.c (deps_analyze_insn): Likewise.
2098         * sel-sched.c (init_regs_for_mode): Likewise.
2099         (mark_unavailable_hard_regs): Likewise.
2100         * targhooks.c (default_dwarf_frame_reg_mode): Likewise.
2101         * config/aarch64/aarch64.h (HARD_REGNO_CALL_PART_CLOBBERED): Delete.
2102         * config/aarch64/aarch64.c (aarch64_hard_regno_call_part_clobbered):
2103         New function.
2104         (TARGET_HARD_REGNO_CALL_PART_CLOBBERED): Redefine.
2105         * config/avr/avr.h (HARD_REGNO_CALL_PART_CLOBBERED): Delete.
2106         * config/avr/avr-protos.h (avr_hard_regno_call_part_clobbered):
2107         Delete.
2108         * config/avr/avr.c (avr_hard_regno_call_part_clobbered): Make static
2109         and return a bool.
2110         (TARGET_HARD_REGNO_CALL_PART_CLOBBERED): Redefine.
2111         * config/i386/i386.h (HARD_REGNO_CALL_PART_CLOBBERED): Delete.
2112         * config/i386/i386.c (ix86_hard_regno_call_part_clobbered): New
2113         function.
2114         (TARGET_HARD_REGNO_CALL_PART_CLOBBERED): Redefine.
2115         * config/mips/mips.h (HARD_REGNO_CALL_PART_CLOBBERED): Delete.
2116         * config/mips/mips.c (mips_hard_regno_call_part_clobbered): New
2117         function.
2118         (TARGET_HARD_REGNO_CALL_PART_CLOBBERED): Redefine.
2119         * config/powerpcspe/powerpcspe.h (HARD_REGNO_CALL_PART_CLOBBERED):
2120         Delete.
2121         * config/powerpcspe/powerpcspe.c
2122         (rs6000_hard_regno_call_part_clobbered): New function.
2123         (TARGET_HARD_REGNO_CALL_PART_CLOBBERED): Redefine.
2124         * config/rs6000/rs6000.h (HARD_REGNO_CALL_PART_CLOBBERED): Delete.
2125         * config/rs6000/rs6000.c (rs6000_hard_regno_call_part_clobbered):
2126         New function.
2127         (TARGET_HARD_REGNO_CALL_PART_CLOBBERED): Redefine.
2128         * config/s390/s390.h (HARD_REGNO_CALL_PART_CLOBBERED): Delete.
2129         * config/s390/s390.c (s390_hard_regno_call_part_clobbered): New
2130         function.
2131         (TARGET_HARD_REGNO_CALL_PART_CLOBBERED): Redefine.
2132         * config/sh/sh.h (HARD_REGNO_CALL_PART_CLOBBERED): Delete.
2133         * system.h (HARD_REGNO_CALL_PART_CLOBBERED): Poison.
2135 2017-09-04  Richard Sandiford  <richard.sandiford@linaro.org>
2136             Alan Hayward  <alan.hayward@arm.com>
2137             David Sherwood  <david.sherwood@arm.com>
2139         * rtl.h (subreg_memory_offset): Declare.
2140         * emit-rtl.c (subreg_memory_offset): New function.
2141         * expmed.c (store_bit_field_1): Use it.
2142         * expr.c (undefined_operand_subword_p): Likewise.
2143         * simplify-rtx.c (simplify_subreg): Likewise.
2145 2017-09-04  Alexander Monakov  <amonakov@ispras.ru>
2147         PR rtl-optimization/57448
2148         PR target/67458
2149         PR target/81316
2150         * optabs.c (expand_atomic_load): Place compiler memory barriers if
2151         using atomic_load pattern.
2152         (expand_atomic_store): Likewise.
2154 2017-09-04  Jakub Jelinek  <jakub@redhat.com>
2156         PR sanitizer/81981
2157         * gimple-fold.c (gimple_fold_call): Optimize away useless UBSAN_PTR
2158         and UBSAN_BOUNDS internal calls.  Clean up IFN_UBSAN_OBJECT_SIZE
2159         handling.  Use replace_call_with_value with NULL instead of
2160         gsi_replace, unlink_stmt_vdef and release_defs.
2162         * gdbhooks.py (OptMachineModePrinter.to_string): Use 8 spaces
2163         instead of tab.
2165         * lra-remat.c (reg_overlap_for_remat_p): Fix a pasto.
2167 2017-09-04  Richard Sandiford  <richard.sandiford@linaro.org>
2169         PR bootstrap/82045
2170         * rtl.h (emit_library_call_value_1): Declare.
2171         (emit_library_call): Replace declaration with a series of overloads.
2172         Remove the parameter count argument.
2173         (emit_library_call_value): Likewise.
2174         * calls.c (emit_library_call_value_1): Make global.  Replace varargs
2175         with an "rtx_mode_t *".
2176         (emit_library_call_value): Delete.
2177         (emit_library_call): Likewise.
2178         * asan.c (asan_emit_stack_protection): Update calls accordingly.
2179         (asan_emit_allocas_unpoison): Likewise.
2180         * builtins.c (expand_builtin_powi): Likewise.
2181         (expand_asan_emit_allocas_unpoison): Likewise.
2182         * cfgexpand.c (expand_main_function): Likewise.
2183         * config/aarch64/aarch64.c (aarch64_trampoline_init): Likewise.
2184         * config/aarch64/aarch64.h (PROFILE_HOOK): Likewise.
2185         * config/alpha/alpha.c (alpha_trampoline_init): Likewise.
2186         * config/arm/arm.c (arm_trampoline_init): Likewise.
2187         (arm_call_tls_get_addr): Likewise.
2188         (arm_expand_divmod_libfunc): Likewise.
2189         * config/bfin/bfin.md (umulsi3_highpart): Likewise.
2190         (smulsi3_highpart): Likewise.
2191         * config/c6x/c6x.c (c6x_initialize_trampoline): Likewise.
2192         (c6x_expand_compare): Likewise.
2193         (c6x_expand_movmem): Likewise.
2194         * config/frv/frv.c (frv_trampoline_init): Likewise.
2195         * config/i386/i386.c (ix86_trampoline_init): Likewise.
2196         (ix86_expand_divmod_libfunc): Likewise.
2197         * config/ia64/ia64.c (ia64_expand_tls_address): Likewise.
2198         (ia64_expand_compare): Likewise.
2199         (ia64_profile_hook): Likewise.
2200         * config/ia64/ia64.md (save_stack_nonlocal): Likewise.
2201         (nonlocal_goto): Likewise.
2202         (restore_stack_nonlocal): Likewise.
2203         * config/m32r/m32r.c (block_move_call): Likewise.
2204         (m32r_trampoline_init): Likewise.
2205         * config/m68k/linux.h (FINALIZE_TRAMPOLINE): Likewise.
2206         * config/m68k/m68k.c (m68k_call_tls_get_addr): Likewise.
2207         (m68k_call_m68k_read_tp): Likewise.
2208         * config/microblaze/microblaze.c (microblaze_call_tls_get_addr)
2209         (microblaze_expand_divide): Likewise.
2210         * config/mips/mips.h (mips_args): Likewise.
2211         * config/mips/sdemtk.h (mips_sync_icache): Likewise.
2212         (MIPS_ICACHE_SYNC): Likewise.
2213         * config/nios2/nios2.c (nios2_emit_expensive_div): Likewise.
2214         (nios2_trampoline_init): Likewise.
2215         * config/pa/pa.c (hppa_tls_call): Likewise.
2216         (pa_trampoline_init): Likewise.
2217         * config/pa/pa.md (canonicalize_funcptr_for_compare): Likewise.
2218         * config/powerpcspe/powerpcspe.c (rs6000_legitimize_tls_address)
2219         (expand_strn_compare): Likewise.
2220         (rs6000_generate_compare): Likewise.
2221         (rs6000_expand_float128_convert): Likewise.
2222         (output_profile_hook): Likewise.
2223         (rs6000_trampoline_init): Likewise.
2224         * config/powerpcspe/powerpcspe.md (neg<mode>2): Likewise.
2225         * config/riscv/riscv.h (PROFILE_HOOK): Likewise.
2226         * config/rs6000/rs6000-string.c (expand_strn_compare): Likewise.
2227         * config/rs6000/rs6000.c (rs6000_legitimize_tls_address): Likewise.
2228         (rs6000_generate_compare): Likewise.
2229         (rs6000_expand_float128_convert): Likewise.
2230         (output_profile_hook): Likewise.
2231         (rs6000_trampoline_init): Likewise.
2232         * config/rs6000/rs6000.md (neg<mode>2): Likewise.
2233         * config/sh/sh.c (sh_trampoline_init): Likewise.
2234         * config/sparc/sparc.c (emit_soft_tfmode_libcall): Likewise.
2235         (sparc_emit_float_lib_cmp): Likewise.
2236         (sparc32_initialize_trampoline): Likewise.
2237         (sparc64_initialize_trampoline): Likewise.
2238         (sparc_profile_hook): Likewise.
2239         * config/spu/spu.c (ea_load_store): Likewise.
2240         * config/spu/spu.md (floatunssidf2): Likewise.
2241         * config/tilegx/tilegx.c (tilegx_trampoline_init): Likewise.
2242         * config/tilepro/tilepro.c (tilepro_trampoline_init): Likewise.
2243         * config/visium/visium.c (expand_block_move_4): Likewise.
2244         (expand_block_move_2): Likewise.
2245         (expand_block_move_1): Likewise.
2246         (expand_block_set_4): Likewise.
2247         (expand_block_set_2): Likewise.
2248         (expand_block_set_1): Likewise.
2249         (visium_trampoline_init): Likewise.
2250         (visium_profile_hook): Likewise.
2251         * config/xtensa/xtensa.c (xtensa_expand_nonlocal_goto): Likewise.
2252         (xtensa_setup_frame_addresses): Likewise.
2253         (xtensa_trampoline_init): Likewise.
2254         * except.c (sjlj_emit_function_enter): Likewise.
2255         (sjlj_emit_function_exit): Likewise.
2256         * explow.c (allocate_dynamic_stack_space): Likewise.
2257         (probe_stack_range): Likewise.
2258         * expr.c (convert_mode_scalar): Likewise.
2259         * optabs.c (expand_binop): Likewise.
2260         (expand_twoval_binop_libfunc): Likewise.
2261         (expand_unop): Likewise.
2262         (prepare_cmp_insn): Likewise.
2263         (prepare_float_lib_cmp): Likewise.
2264         (expand_float): Likewise.
2265         (expand_fix): Likewise.
2266         (expand_fixed_convert): Likewise.
2267         (maybe_emit_sync_lock_test_and_set): Likewise.
2268         (expand_atomic_compare_and_swap): Likewise.
2269         (expand_mem_thread_fence): Likewise.
2270         (expand_atomic_fetch_op): Likewise.
2272 2017-09-03  Gerald Pfeifer  <gerald@pfeifer.com>
2274         * doc/generic.texi (OpenACC): Adjust URL.
2275         * doc/invoke.texi (C Dialect Options): Ditto.
2277 2017-09-03  Uros Bizjak  <ubizjak@gmail.com>
2279         * config/i386/i386.md (*bt<mode>): Use nonimmediate_operand
2280         predicate for operand 1.  Add (m,<S>) constraint.
2281         (*jcc_bt<mode>): Use nonimmediate_operand predicate for operand 1.
2282         Prevent memory operand 1 with register operand 2.
2284 2017-09-01  Segher Boessenkool  <segher@kernel.crashing.org>
2286         PR rtl-optimization/82024
2287         * combine.c (try_combine): If the combination result is a PARALLEL,
2288         and we only need to retain the SET in there that would be placed
2289         at I2, check that we can place that at I3 instead, before doing so.
2291 2017-09-01  Jakub Jelinek  <jakub@redhat.com>
2293         PR target/81766
2294         * config/i386/i386.c (ix86_init_large_pic_reg): Return label
2295         instead of void.
2296         (ix86_init_pic_reg): Remember label from ix86_init_large_pic_reg,
2297         if non-NULL and preceded by NOTE_INSN_BASIC_BLOCK, swap the note
2298         and label.
2300 2017-09-01  Joerg Sonnenberger  <joerg@bec.de>
2301             Jeff Law  <law@redhat.com>
2303         * varasm.c (bss_initializer_p): Do not put constants into .bss
2304         (categorize_decl_for_section): Handle bss_initializer_p returning
2305         false when DECL_INITIAL is NULL.
2307 2017-09-01  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
2309         PR target/82012
2310         * config/s390/s390.c (s390_can_inline_p): New function.
2312 2017-09-01  Jeff Law  <law@redhat.com>
2314         PR tree-optimization/82052
2315         * tree-ssa-scopedtables.c (avail_exprs_stack::lookup_avail_expr):
2316         Always initialize the returned slot after a hash table miss
2317         when INSERT is true.
2319 2017-09-01  Alexander Monakov  <amonakov@ispras.ru>
2321         * config/s390/s390.md (mem_signal_fence): Remove.
2322         * doc/md.texi (mem_signal_fence): Remove.
2323         * optabs.c (expand_mem_signal_fence): Remove uses of mem_signal_fence.
2324         Update comments.
2325         * target-insns.def (mem_signal_fence): Remove.
2327 2017-09-01  Jakub Jelinek  <jakub@redhat.com>
2329         PR sanitizer/81902
2330         * doc/invoke.texi: Document -fsanitize=pointer-overflow.
2332         PR sanitizer/81923
2333         * asan.c (create_odr_indicator): Strip name encoding from assembler
2334         name before appending it after __odr_asan_.
2336 2017-09-01  Martin Liska  <mliska@suse.cz>
2338         PR tree-optimization/82059
2339         * gimple-ssa-isolate-paths.c (isolate_path): Add profile and
2340         frequency only when an edge is redirected.
2342 2017-09-01  Claudiu Zissulescu  <claziss@synopsys.com>
2344         * config/arc/arc-c.c (__ARC_LPC_WIDTH__): Add builtin define.
2345         * config/arc/arc.c (ARC_MAX_LOOP_LENGTH): Define.
2346         (arc_conditional_register_usage): Remove ARC600 lp_count
2347         exception.
2348         (arc_file_start): Emit Tag_ARC_CPU_variation.
2349         (arc_can_use_doloop_p): New conditions to use ZOLs.
2350         (hwloop_fail): New function.
2351         (hwloop_optimize): Likewise.
2352         (hwloop_pattern_reg): Likewise.
2353         (arc_doloop_hooks): New struct, to be used with reorg_loops.
2354         (arc_reorg_loops): New function, calls reorg_loops.
2355         (arc_reorg): Call arc_reorg_loops.  Remove old ZOL handling.
2356         (arc600_corereg_hazard): Remove ZOL checking, case handled by
2357         hwloop_optimize.
2358         (arc_loop_hazard): Remove function, functionality moved into
2359         hwloop_optimize.
2360         (arc_hazard): Remove arc_loop_hazard call.
2361         (arc_adjust_insn_length): Remove ZOL handling, functionality moved
2362         into hwloop_optimize.
2363         (arc_label_align): Remove ZOL handling.
2364         * config/arc/arc.h (LOOP_ALIGN): Changed to 0.
2365         * config/arc/arc.md (doloop_begin): Remove pattern.
2366         (doloop_begin_i): Likewise.
2367         (doloop_end_i): Likewise.
2368         (doloop_fallback): Likewise.
2369         (doloop_fallback_m): Likewise.
2370         (doloop_end): Reimplement expand.
2371         (arc_lp): New pattern for LP instruction.
2372         (loop_end): New pattern.
2373         (loop_fail): Likewise.
2374         (decrement_and_branch_until_zero): Likewise.
2375         * config/arc/arc.opt (mlpc-width): New option.
2376         * doc/invoke.texi (mlpc-width): Document option.
2378 2017-09-01  Claudiu Zissulescu  <claziss@synopsys.com>
2380         * config/arc/arc.c (arc_ifcvt): Remove use of merge_blocks call.
2381         (arc_ccfsm_advance): Fix checking for delay slots.
2382         (arc_reorg): Add rtl dump after each call to arc_ifcvt.
2384 2017-09-01  Claudiu Zissulescu  <claziss@synopsys.com>
2386         * config/arc/arc.md (movqi_insn): Add stores to save constant long
2387         immediates.
2388         (movhi_insn): Update store instruction constraint which are saving
2389         6-bit short immediates.
2390         (movsi_insn): Consider also short scaled load operations.
2391         (zero_extendhisi2_i): Use Usd constraint instead of T.
2392         (extendhisi2_i): Add q constraint.
2393         (arc_clzsi2): Add type and length attributes.
2394         (arc_ctzsi2): Likewise.
2395         * config/arc/constraints.md (Usc): Update constraint, the
2396         assembler can parse two relocations for a single instruction.
2398 2017-09-01  Claudiu Zissulescu  <claziss@synopsys.com>
2400         * config/arc/arc.c (arc_use_anchors_for_symbol_p): New function.
2401         (TARGET_USE_ANCHORS_FOR_SYMBOL_P): Define.
2403 2017-08-31  Olivier Hainque  <hainque@adacore.com>
2405         * config.gcc (powerpc-wrs-vxworks|vxworksae|vxworksmils): Now
2406         match as powerpc-wrs-vxworks*.
2408 2017-08-31  James Greenhalgh  <james.greenhalgh@arm.com>
2410         * config/aarch64/aarch64-simd.md (aarch64_mla_elt_merge<mode>): Fix
2411         register constraint for by-element operand.
2412         (aarch64_mls_elt_merge<mode>): Likewise.
2414 2017-08-31  Claudiu Zissulescu  <claziss@synopsys.com>
2416         * config/arc/arc.c (arc_can_follow_jump): Check for short
2417         branches.
2419 2017-08-31  Claudiu Zissulescu  <claziss@synopsys.com>
2421         * config.gcc: Use g.opt for arc.
2422         * config/arc/arc.c (LEGITIMATE_SCALED_ADDRESS_P): Deleted,
2423         functionality moved to ...
2424         (legitimate_scaled_address_p): New function, ...here.
2425         (LEGITIMATE_SMALL_DATA_OFFSET_P): New define.
2426         (LEGITIMATE_SMALL_DATA_ADDRESS_P): Use the above define.
2427         (legitimate_offset_address_p): Delete TARGET_NO_SDATA_SET
2428         condition.
2429         (arc_override_options): Handle G option.
2430         (arc_output_pic_addr_const): Correct function definition.
2431         (arc_legitimate_address_p): Use legitimate_scaled_address_p.
2432         (arc_decl_anon_ns_mem_p): Delete.
2433         (arc_in_small_data_p): Overhaul this function to take into
2434         consideration the value given via G option.
2435         (arc_rewrite_small_data_1): Renamed and corrected old
2436         arc_rewrite_small_data function.
2437         (arc_rewrite_small_data): New function.
2438         (small_data_pattern): Don't use pic_offset_table_rtx.
2439         * config/arc/arc.h (CC1_SPEC): Recognize G option.
2440         * config/arc/simdext.md (movmisalignv2hi): Use
2441         prepare_move_operands function.
2442         (mov*): Likewise.
2443         (movmisalign*): Likewise.
2444         * doc/invoke.texi (ARC options): Document -G option.
2446 2017-08-31  Claudiu Zissulescu  <claziss@synopsys.com>
2448         * config/arc/arc-protos.h (compact_sda_memory_operand): Update
2449         prototype.
2450         * config/arc/arc.c (arc_print_operand): Output scalled address for
2451         sdata whenever is possible.
2452         (arc_in_small_data_p): Allow sdata for 64bit datum when double
2453         load/stores are available.
2454         (compact_sda_memory_operand): Check for the alignment required by
2455         code density instructions.
2456         * config/arc/arc.md (movsi_insn): Use newly introduced Us0
2457         constraint.
2458         * config/arc/constraints.md (Usd): Update constraint.
2459         (Us0): New constraint.
2460         (Usc): Update constraint.
2462 2017-08-31  Richard Biener  <rguenther@suse.de>
2464         PR middle-end/82054
2465         * dwarf2out.c (dwarf2out_early_global_decl): Process each
2466         function only once.
2468 2017-08-31  Tamar Christina  <tamar.christina@arm.com>
2470         * config/aarch64/aarch64-builtins.c (aarch64_init_simd_builtins):
2471         Resize type_signature.
2473 2017-08-31  Richard Sandiford  <richard.sandiford@linaro.org>
2474             Alan Hayward  <alan.hayward@arm.com>
2475             David Sherwood  <david.sherwood@arm.com>
2477         * config/aarch64/aarch64.c (aarch64_base_register_rtx_p): Only allow
2478         subregs whose inner modes can be stored in GPRs.
2479         (aarch64_classify_index): Likewise.
2481 2017-08-31  Richard Sandiford  <richard.sandiford@linaro.org>
2482             Alan Hayward  <alan.hayward@arm.com>
2483             David Sherwood  <david.sherwood@arm.com>
2485         * config/aarch64/iterators.md (V_cmp_result): Rename to...
2486         (V_INT_EQUIV): ...this.
2487         (v_cmp_result): Rename to...
2488         (v_int_equiv): ...this.
2489         * config/aarch64/aarch64.md (xorsign<mode>3): Update accordingly.
2490         * config/aarch64/aarch64-simd.md (xorsign<mode>3): Likewise.
2491         (copysign<mode>3): Likewise.
2492         (aarch64_simd_bsl<mode>_internal): Likewise.
2493         (aarch64_simd_bsl<mode>): Likewise.
2494         (vec_cmp<mode><mode>): Likewise.
2495         (vcond<mode><mode>): Likewise.
2496         (vcond<v_cmp_mixed><mode>): Likewise.
2497         (vcondu<mode><v_cmp_mixed>): Likewise.
2498         (aarch64_cm<optab><mode>): Likewise.
2499         (aarch64_cmtst<mode>): Likewise.
2500         (aarch64_fac<optab><mode>): Likewise.
2501         (vec_perm_const<mode>): Likewise.
2502         (vcond_mask_<mode><v_cmp_result>): Rename to...
2503         (vcond_mask_<mode><v_int_equiv>): ...this.
2504         (vec_cmp<mode><v_cmp_result>): Rename to...
2505         (vec_cmp<mode><v_int_equiv>): ...this.
2507 2017-08-31  Richard Sandiford  <richard.sandiford@linaro.org>
2508             Alan Hayward  <alan.hayward@arm.com>
2509             David Sherwood  <david.sherwood@arm.com>
2511         * config/aarch64/aarch64-modes.def: Remove 32-, 48- and 64-byte
2512         vector modes.
2513         * config/aarch64/iterators.md (VRL2, VRL3, VRL4): Delete.
2514         * config/aarch64/aarch64.md (UNSPEC_LD2_DREG, UNSPEC_LD3_DREG)
2515         (UNSPEC_LD4_DREG): New unspecs.
2516         * config/aarch64/aarch64-simd.md (aarch64_ld2<mode>_dreg_le)
2517         (aarch64_ld2<mode>_dreg_be): Replace with...
2518         (aarch64_ld2<mode>_dreg): ...this pattern and use the new DREG
2519         unspec.
2520         (aarch64_ld3<mode>_dreg_le)
2521         (aarch64_ld3<mode>_dreg_be): Replace with...
2522         (aarch64_ld3<mode>_dreg): ...this pattern and use the new DREG
2523         unspec.
2524         (aarch64_ld4<mode>_dreg_le)
2525         (aarch64_ld4<mode>_dreg_be): Replace with...
2526         (aarch64_ld4<mode>_dreg): ...this pattern and use the new DREG
2527         unspec.
2529 2017-08-30  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
2531         PR tree-optimization/81987
2532         * gimple-ssa-strength-reduction.c (insert_initializers): Don't
2533         insert an initializer in a location not dominated by the stride
2534         definition.
2536 2017-08-30  Eric Botcazou  <ebotcazou@adacore.com>
2538         * tree-eh.c (lower_try_finally_switch): Set the location of the finally
2539         on the entire header of the finally block in the fallthru case.
2541 2017-08-30  Eric Botcazou  <ebotcazou@adacore.com>
2543         * varasm.c (decode_addr_const): Deal with INDIRECT_REF <INTEGER_CST>.
2545 2017-08-30  Pat Haugen  <pthaugen@us.ibm.com>
2547         * config/rs6000/rs6000.c (rs6000_emit_prologue_move_from_cr): Rename from
2548         rs6000_emit_move_from_cr and call renamed function.
2549         (rs6000_emit_prologue): Call renamed functions.
2550         * config/rs6000/rs6000.md (prologue_movesi_from_cr): Rename from
2551         movesi_from_cr, remove volatile CRs.
2553 2017-08-30  Jon Beniston  <jon@beniston.com>
2554             Richard Biener  <rguenther@suse.de>
2556         * tree-vect-patterns.c (vect_pattern_recog_1): Use VECTOR_TYPE_P instead
2557         of VECTOR_MODE_P check.
2558         * tree-vect-stmts.c (get_vectype_for_scalar_type_and_size): Allow single
2559         element vector types.
2561 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
2563         * df.h (df_read_modify_subreg_p): Remove in favor of...
2564         * rtl.h (read_modify_subreg_p): ...this new function.  Take a
2565         const_rtx instead of an rtx.
2566         * cprop.c (local_cprop_find_used_regs): Update accordingly.
2567         * df-problems.c (df_word_lr_mark_ref): Likewise.
2568         * ira-lives.c (mark_pseudo_reg_live): Likewise.
2569         (mark_pseudo_reg_dead): Likewise.
2570         (mark_ref_dead): Likewise.
2571         * reginfo.c (init_subregs_of_mode): Likewise.
2572         * sched-deps.c (sched_analyze_1): Likewise.
2573         * df-scan.c (df_def_record_1): Likewise.
2574         (df_uses_record): Likewise.
2575         (df_read_modify_subreg_p): Remove in favor of...
2576         * rtlanal.c (read_modify_subreg_p): ...this new function.  Take a
2577         const_rtx instead of an rtx.
2579 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
2580             Alan Hayward  <alan.hayward@arm.com>
2581             David Sherwood  <david.sherwood@arm.com>
2583         * rtl.h (partial_subreg_p): New function.
2584         * caller-save.c (save_call_clobbered_regs): Use it.
2585         * calls.c (expand_call): Likewise.
2586         * combine.c (combinable_i3pat): Likewise.
2587         (simplify_set): Likewise.
2588         (make_extraction): Likewise.
2589         (make_compound_operation_int): Likewise.
2590         (gen_lowpart_or_truncate): Likewise.
2591         (force_to_mode): Likewise.
2592         (make_field_assignment): Likewise.
2593         (reg_truncated_to_mode): Likewise.
2594         (record_truncated_value): Likewise.
2595         (move_deaths): Likewise.
2596         * cse.c (record_jump_cond): Likewise.
2597         (cse_insn): Likewise.
2598         * cselib.c (cselib_lookup_1): Likewise.
2599         * expmed.c (extract_bit_field_using_extv): Likewise.
2600         * function.c (assign_parm_setup_reg): Likewise.
2601         * ifcvt.c (noce_convert_multiple_sets): Likewise.
2602         * ira-build.c (create_insn_allocnos): Likewise.
2603         * lra-coalesce.c (merge_pseudos): Likewise.
2604         * lra-constraints.c (match_reload): Likewise.
2605         (simplify_operand_subreg): Likewise.
2606         (curr_insn_transform): Likewise.
2607         * lra-lives.c (process_bb_lives): Likewise.
2608         * lra.c (new_insn_reg): Likewise.
2609         (lra_substitute_pseudo): Likewise.
2610         * regcprop.c (mode_change_ok): Likewise.
2611         (maybe_mode_change): Likewise.
2612         (copyprop_hardreg_forward_1): Likewise.
2613         * reload.c (push_reload): Likewise.
2614         (find_reloads): Likewise.
2615         (find_reloads_subreg_address): Likewise.
2616         * reload1.c (alter_reg): Likewise.
2617         (eliminate_regs_1): Likewise.
2618         * simplify-rtx.c (simplify_unary_operation_1): Likewise.
2620 2017-08-30  David Edelsohn  <dje.gcc@gmail.com>
2622         * config/rs6000/rs6000.c (rs6000_expand_binop_builtin): Revert
2623         back to if statements, including unpack.
2625 2017-08-30  Martin Liska  <mliska@suse.cz>
2627         PR inline-asm/82001
2628         * ipa-icf-gimple.c (func_checker::compare_tree_list_operand):
2629         Rename to ...
2630         (func_checker::compare_asm_inputs_outputs): ... this function.
2631         (func_checker::compare_gimple_asm): Use the function to compare
2632         also ASM constrains.
2633         * ipa-icf-gimple.h: Rename the function.
2635 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
2636             Alan Hayward  <alan.hayward@arm.com>
2637             David Sherwood  <david.sherwood@arm.com>
2639         * coretypes.h (complex_mode): New type.
2640         * gdbhooks.py (build_pretty_printer): Handle it.
2641         * machmode.h (complex_mode): New class.
2642         (complex_mode::includes_p): New function.
2643         (is_complex_int_mode): Likewise.
2644         (is_complex_float_mode): Likewise.
2645         * genmodes.c (get_mode_class): Handle complex mode classes.
2646         * function.c (expand_function_end): Use is_complex_int_mode.
2648 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
2649             Alan Hayward  <alan.hayward@arm.com>
2650             David Sherwood  <david.sherwood@arm.com>
2652         * coretypes.h (scalar_mode_pod): New typedef.
2653         * gdbhooks.py (build_pretty_printer): Handle it.
2654         * machmode.h (gt_ggc_mx, gt_pch_nx): New functions.
2655         * fixed-value.h (fixed_value::mode): Change type to scalar_mode_pod.
2656         * fold-const.c (fold_convert_const_int_from_fixed): Use scalar_mode.
2657         * tree-streamer-in.c (unpack_ts_fixed_cst_value_fields): Use
2658         as_a <scalar_mode>.
2660 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
2661             Alan Hayward  <alan.hayward@arm.com>
2662             David Sherwood  <david.sherwood@arm.com>
2664         * machmode.h (mode_for_vector): Take a scalar_mode instead
2665         of a machine_mode.
2666         * stor-layout.c (mode_for_vector): Likewise.
2667         * explow.c (promote_mode): Use as_a <scalar_mode>.
2668         * sdbout.c (sdbout_parms): Use is_a <scalar_mode>.
2670 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
2671             Alan Hayward  <alan.hayward@arm.com>
2672             David Sherwood  <david.sherwood@arm.com>
2674         * target.def (preferred_simd_mode): Take a scalar_mode
2675         instead of a machine_mode.
2676         * targhooks.h (default_preferred_simd_mode): Likewise.
2677         * targhooks.c (default_preferred_simd_mode): Likewise.
2678         * config/arc/arc.c (arc_preferred_simd_mode): Likewise.
2679         * config/arm/arm.c (arm_preferred_simd_mode): Likewise.
2680         * config/c6x/c6x.c (c6x_preferred_simd_mode): Likewise.
2681         * config/epiphany/epiphany.c (epiphany_preferred_simd_mode): Likewise.
2682         * config/i386/i386.c (ix86_preferred_simd_mode): Likewise.
2683         * config/mips/mips.c (mips_preferred_simd_mode): Likewise.
2684         * config/nvptx/nvptx.c (nvptx_preferred_simd_mode): Likewise.
2685         * config/powerpcspe/powerpcspe.c (rs6000_preferred_simd_mode):
2686         Likewise.
2687         * config/rs6000/rs6000.c (rs6000_preferred_simd_mode): Likewise.
2688         * config/s390/s390.c (s390_preferred_simd_mode): Likewise.
2689         * config/sparc/sparc.c (sparc_preferred_simd_mode): Likewise.
2690         * config/aarch64/aarch64.c (aarch64_preferred_simd_mode): Likewise.
2691         (aarch64_simd_scalar_immediate_valid_for_move): Update accordingly.
2692         * doc/tm.texi: Regenerate.
2693         * optabs-query.c (can_vec_mask_load_store_p): Return false for
2694         non-scalar modes.
2696 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
2697             Alan Hayward  <alan.hayward@arm.com>
2698             David Sherwood  <david.sherwood@arm.com>
2700         * target.def (scalar_mode_supported_p): Take a scalar_mode
2701         instead of a machine_mode.
2702         * targhooks.h (default_scalar_mode_supported_p): Likewise.
2703         * targhooks.c (default_scalar_mode_supported_p): Likewise.
2704         * config/aarch64/aarch64.c (aarch64_scalar_mode_supported_p): Likewise.
2705         * config/alpha/alpha.c (alpha_scalar_mode_supported_p): Likewise.
2706         * config/arm/arm.c (arm_scalar_mode_supported_p): Likewise.
2707         * config/avr/avr.c (avr_scalar_mode_supported_p): Likewise.
2708         * config/c6x/c6x.c (c6x_scalar_mode_supported_p): Likewise.
2709         * config/i386/i386.c (ix86_scalar_mode_supported_p): Likewise.
2710         * config/ia64/ia64.c (ia64_scalar_mode_supported_p): Likewise.
2711         * config/mips/mips.c (mips_scalar_mode_supported_p): Likewise.
2712         * config/msp430/msp430.c (msp430_scalar_mode_supported_p): Likewise.
2713         * config/pa/pa.c (pa_scalar_mode_supported_p): Likewise.
2714         * config/pdp11/pdp11.c (pdp11_scalar_mode_supported_p): Likewise.
2715         * config/powerpcspe/powerpcspe.c (rs6000_scalar_mode_supported_p):
2716         Likewise.
2717         * config/rs6000/rs6000.c (rs6000_scalar_mode_supported_p): Likewise.
2718         * config/s390/s390.c (s390_scalar_mode_supported_p): Likewise.
2719         * config/spu/spu.c (spu_scalar_mode_supported_p): Likewise.
2720         * config/tilegx/tilegx.c (tilegx_scalar_mode_supported_p): Likewise.
2721         * config/tilepro/tilepro.c (tilepro_scalar_mode_supported_p):
2722         Likewise.
2723         * doc/tm.texi: Regenerate.
2725 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
2726             Alan Hayward  <alan.hayward@arm.com>
2727             David Sherwood  <david.sherwood@arm.com>
2729         * coretypes.h (opt_scalar_mode): New typedef.
2730         * gdbhooks.py (build_pretty_printers): Handle it.
2731         * machmode.h (mode_iterator::get_2xwider): Add overload for
2732         opt_mode<T>.
2733         * emit-rtl.c (init_emit_once): Use opt_scalar_mode when iterating
2734         over scalar modes.
2735         * expr.c (convert_mode_scalar): Likewise.
2736         * omp-low.c (omp_clause_aligned_alignment): Likewise.
2737         * optabs.c (expand_float): Likewise.
2738         (expand_fix): Likewise.
2739         * tree-vect-stmts.c (vectorizable_conversion): Likewise.
2741 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
2742             Alan Hayward  <alan.hayward@arm.com>
2743             David Sherwood  <david.sherwood@arm.com>
2745         * optabs.c (expand_float): Explicitly check for scalars before
2746         using a branching expansion.
2747         (expand_fix): Likewise.
2749 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
2750             Alan Hayward  <alan.hayward@arm.com>
2751             David Sherwood  <david.sherwood@arm.com>
2753         * expr.c (convert_mode): Split scalar handling out into...
2754         (convert_mode_scalar): ...this new function.  Treat the modes
2755         as scalar_modes.
2757 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
2758             Alan Hayward  <alan.hayward@arm.com>
2759             David Sherwood  <david.sherwood@arm.com>
2761         * omp-expand.c (expand_omp_atomic): Use is_int_mode, is_float_mode
2762         and scalar_mode.
2763         * tree-vect-stmts.c (get_vectype_for_scalar_type_and_size): Likewise.
2765 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
2766             Alan Hayward  <alan.hayward@arm.com>
2767             David Sherwood  <david.sherwood@arm.com>
2769         * fixed-value.h (fixed_from_double_int): Take a scalar_mode
2770         rather than a machine_mode.
2771         (fixed_from_string): Likewise.
2772         (fixed_convert): Likewise.
2773         (fixed_convert_from_int): Likewise.
2774         (fixed_convert_from_real): Likewise.
2775         (real_convert_from_fixed): Likewise.
2776         * fixed-value.c (fixed_from_double_int): Likewise.
2777         (fixed_from_string): Likewise.
2778         (fixed_convert): Likewise.
2779         (fixed_convert_from_int): Likewise.
2780         (fixed_convert_from_real): Likewise.
2781         (real_convert_from_fixed): Likewise.
2782         * config/avr/avr.c (avr_out_round): Use as_a <scalar_mode>.
2784 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
2785             Alan Hayward  <alan.hayward@arm.com>
2786             David Sherwood  <david.sherwood@arm.com>
2788         * emit-rtl.c (immed_double_const): Use is_a <scalar_mode> instead
2789         of separate mode class checks.  Do not allow vector modes here.
2790         (immed_wide_int_const): Use as_a <scalar_mode>.
2791         * explow.c (trunc_int_for_mode): Likewise.
2792         * rtl.h (wi::int_traits<rtx_mode_t>::get_precision): Likewise.
2793         (wi::shwi): Likewise.
2794         (wi::min_value): Likewise.
2795         (wi::max_value): Likewise.
2796         * dwarf2out.c (loc_descriptor): Likewise.
2797         * simplify-rtx.c (simplify_immed_subreg): Fix rtx_mode_t argument
2798         for CONST_WIDE_INT.
2800 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
2801             Alan Hayward  <alan.hayward@arm.com>
2802             David Sherwood  <david.sherwood@arm.com>
2804         * tree.h (SCALAR_TYPE_MODE): New macro.
2805         * expr.c (expand_expr_addr_expr_1): Use it.
2806         (expand_expr_real_2): Likewise.
2807         * fold-const.c (fold_convert_const_fixed_from_fixed): Likeise.
2808         (fold_convert_const_fixed_from_int): Likewise.
2809         (fold_convert_const_fixed_from_real): Likewise.
2810         (native_encode_fixed): Likewise
2811         (native_encode_complex): Likewise
2812         (native_encode_vector): Likewise.
2813         (native_interpret_fixed): Likewise.
2814         (native_interpret_real): Likewise.
2815         (native_interpret_complex): Likewise.
2816         (native_interpret_vector): Likewise.
2817         * omp-simd-clone.c (simd_clone_adjust_return_type): Likewise.
2818         (simd_clone_adjust_argument_types): Likewise.
2819         (simd_clone_init_simd_arrays): Likewise.
2820         (simd_clone_adjust): Likewise.
2821         * stor-layout.c (layout_type): Likewise.
2822         * tree.c (build_minus_one_cst): Likewise.
2823         * tree-cfg.c (verify_gimple_assign_ternary): Likewise.
2824         * tree-inline.c (estimate_move_cost): Likewise.
2825         * tree-ssa-math-opts.c (convert_plusminus_to_widen): Likewise.
2826         * tree-vect-loop.c (vect_create_epilog_for_reduction): Likewise.
2827         (vectorizable_reduction): Likewise.
2828         * tree-vect-patterns.c (vect_recog_widen_mult_pattern): Likewise.
2829         (vect_recog_mixed_size_cond_pattern): Likewise.
2830         (check_bool_pattern): Likewise.
2831         (adjust_bool_pattern): Likewise.
2832         (search_type_for_mask_1): Likewise.
2833         * tree-vect-slp.c (vect_schedule_slp_instance): Likewise.
2834         * tree-vect-stmts.c (vectorizable_conversion): Likewise.
2835         (vectorizable_load): Likewise.
2836         (vectorizable_store): Likewise.
2837         * ubsan.c (ubsan_encode_value): Likewise.
2838         * varasm.c (output_constant): Likewise.
2840 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
2841             Alan Hayward  <alan.hayward@arm.com>
2842             David Sherwood  <david.sherwood@arm.com>
2844         * coretypes.h (scalar_mode): New class.
2845         * machmode.h (scalar_mode): Likewise.
2846         (scalar_mode::includes_p): New function.
2847         (mode_to_inner): Return a scalar_mode rather than a machine_mode.
2848         * gdbhooks.py (build_pretty_printers): Handle scalar_mode.
2849         * genmodes.c (get_mode_class): Handle remaining scalar modes.
2850         * cfgexpand.c (expand_debug_expr): Use scalar_mode.
2851         * expmed.c (store_bit_field_1): Likewise.
2852         (extract_bit_field_1): Likewise.
2853         * expr.c (write_complex_part): Likewise.
2854         (read_complex_part): Likewise.
2855         (emit_move_complex_push): Likewise.
2856         (expand_expr_real_2): Likewise.
2857         * function.c (assign_parm_setup_reg): Likewise.
2858         (assign_parms_unsplit_complex): Likewise.
2859         * optabs.c (expand_binop): Likewise.
2860         * rtlanal.c (subreg_get_info): Likewise.
2861         * simplify-rtx.c (simplify_immed_subreg): Likewise.
2862         * varasm.c (output_constant_pool_2): Likewise.
2864 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
2865             Alan Hayward  <alan.hayward@arm.com>
2866             David Sherwood  <david.sherwood@arm.com>
2868         * expmed.c (extract_high_half): Use scalar_int_mode and remove
2869         assertion.
2870         (expmed_mult_highpart_optab): Likewise.
2871         (expmed_mult_highpart): Likewise.
2873 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
2874             Alan Hayward  <alan.hayward@arm.com>
2875             David Sherwood  <david.sherwood@arm.com>
2877         * builtins.h (builtin_strncpy_read_str): Take a scalar_int_mode
2878         instead of a machine_mode.
2879         (builtin_memset_read_str): Likewise.
2880         * builtins.c (c_readstr): Likewise.
2881         (builtin_memcpy_read_str): Likewise.
2882         (builtin_strncpy_read_str): Likewise.
2883         (builtin_memset_read_str): Likewise.
2884         (builtin_memset_gen_str): Likewise.
2885         (expand_builtin_signbit): Use scalar_int_mode for local variables.
2886         * cfgexpand.c (convert_debug_memory_address): Take a scalar_int_mode
2887         instead of a machine_mode.
2888         * combine.c (simplify_if_then_else): Use scalar_int_mode for local
2889         variables.
2890         (make_extraction): Likewise.
2891         (try_widen_shift_mode): Take and return scalar_int_modes instead
2892         of machine_modes.
2893         * config/aarch64/aarch64.c (aarch64_libgcc_cmp_return_mode): Return
2894         a scalar_int_mode instead of a machine_mode.
2895         * config/avr/avr.c (avr_addr_space_address_mode): Likewise.
2896         (avr_addr_space_pointer_mode): Likewise.
2897         * config/cr16/cr16.c (cr16_unwind_word_mode): Likewise.
2898         * config/msp430/msp430.c (msp430_addr_space_pointer_mode): Likewise.
2899         (msp430_unwind_word_mode): Likewise.
2900         * config/spu/spu.c (spu_unwind_word_mode): Likewise.
2901         (spu_addr_space_pointer_mode): Likewise.
2902         (spu_addr_space_address_mode): Likewise.
2903         (spu_libgcc_cmp_return_mode): Likewise.
2904         (spu_libgcc_shift_count_mode): Likewise.
2905         * config/rl78/rl78.c (rl78_addr_space_address_mode): Likewise.
2906         (rl78_addr_space_pointer_mode): Likewise.
2907         (fl78_unwind_word_mode): Likewise.
2908         (rl78_valid_pointer_mode): Take a scalar_int_mode instead of a
2909         machine_mode.
2910         * config/alpha/alpha.c (vms_valid_pointer_mode): Likewise.
2911         * config/ia64/ia64.c (ia64_vms_valid_pointer_mode): Likewise.
2912         * config/mips/mips.c (mips_mode_rep_extended): Likewise.
2913         (mips_valid_pointer_mode): Likewise.
2914         * config/tilegx/tilegx.c (tilegx_mode_rep_extended): Likewise.
2915         * config/ft32/ft32.c (ft32_valid_pointer_mode): Likewise.
2916         (ft32_addr_space_pointer_mode): Return a scalar_int_mode instead
2917         of a machine_mode.
2918         (ft32_addr_space_address_mode): Likewise.
2919         * config/m32c/m32c.c (m32c_valid_pointer_mode): Take a
2920         scalar_int_mode instead of a machine_mode.
2921         (m32c_addr_space_pointer_mode): Return a scalar_int_mode instead
2922         of a machine_mode.
2923         (m32c_addr_space_address_mode): Likewise.
2924         * config/powerpcspe/powerpcspe.c (rs6000_abi_word_mode): Likewise.
2925         (rs6000_eh_return_filter_mode): Likewise.
2926         * config/rs6000/rs6000.c (rs6000_abi_word_mode): Likewise.
2927         (rs6000_eh_return_filter_mode): Likewise.
2928         * config/s390/s390.c (s390_libgcc_cmp_return_mode): Likewise.
2929         (s390_libgcc_shift_count_mode): Likewise.
2930         (s390_unwind_word_mode): Likewise.
2931         (s390_valid_pointer_mode): Take a scalar_int_mode rather than a
2932         machine_mode.
2933         * target.def (mode_rep_extended): Likewise.
2934         (valid_pointer_mode): Likewise.
2935         (addr_space.valid_pointer_mode): Likewise.
2936         (eh_return_filter_mode): Return a scalar_int_mode rather than
2937         a machine_mode.
2938         (libgcc_cmp_return_mode): Likewise.
2939         (libgcc_shift_count_mode): Likewise.
2940         (unwind_word_mode): Likewise.
2941         (addr_space.pointer_mode): Likewise.
2942         (addr_space.address_mode): Likewise.
2943         * doc/tm.texi: Regenerate.
2944         * dojump.c (prefer_and_bit_test): Take a scalar_int_mode rather than
2945         a machine_mode.
2946         (do_jump): Use scalar_int_mode for local variables.
2947         * dwarf2cfi.c (init_return_column_size): Take a scalar_int_mode
2948         rather than a machine_mode.
2949         * dwarf2out.c (convert_descriptor_to_mode): Likewise.
2950         (scompare_loc_descriptor_wide): Likewise.
2951         (scompare_loc_descriptor_narrow): Likewise.
2952         * emit-rtl.c (adjust_address_1): Use scalar_int_mode for local
2953         variables.
2954         * except.c (sjlj_emit_dispatch_table): Likewise.
2955         (expand_builtin_eh_copy_values): Likewise.
2956         * explow.c (convert_memory_address_addr_space_1): Likewise.
2957         Take a scalar_int_mode rather than a machine_mode.
2958         (convert_memory_address_addr_space): Take a scalar_int_mode rather
2959         than a machine_mode.
2960         (memory_address_addr_space): Use scalar_int_mode for local variables.
2961         * expmed.h (expand_mult_highpart_adjust): Take a scalar_int_mode
2962         rather than a machine_mode.
2963         * expmed.c (mask_rtx): Likewise.
2964         (init_expmed_one_conv): Likewise.
2965         (expand_mult_highpart_adjust): Likewise.
2966         (extract_high_half): Likewise.
2967         (expmed_mult_highpart_optab): Likewise.
2968         (expmed_mult_highpart): Likewise.
2969         (expand_smod_pow2): Likewise.
2970         (expand_sdiv_pow2): Likewise.
2971         (emit_store_flag_int): Likewise.
2972         (adjust_bit_field_mem_for_reg): Use scalar_int_mode for local
2973         variables.
2974         (extract_low_bits): Likewise.
2975         * expr.h (by_pieces_constfn): Take a scalar_int_mode rather than
2976         a machine_mode.
2977         * expr.c (pieces_addr::adjust):  Likewise.
2978         (can_store_by_pieces): Likewise.
2979         (store_by_pieces): Likewise.
2980         (clear_by_pieces_1): Likewise.
2981         (expand_expr_addr_expr_1): Likewise.
2982         (expand_expr_addr_expr): Use scalar_int_mode for local variables.
2983         (expand_expr_real_1): Likewise.
2984         (try_casesi): Likewise.
2985         * final.c (shorten_branches): Likewise.
2986         * fold-const.c (fold_convert_const_int_from_fixed): Change the
2987         type of "mode" to machine_mode.
2988         * internal-fn.c (expand_arith_overflow_result_store): Take a
2989         scalar_int_mode rather than a machine_mode.
2990         (expand_mul_overflow): Use scalar_int_mode for local variables.
2991         * loop-doloop.c (doloop_modify): Likewise.
2992         (doloop_optimize): Likewise.
2993         * optabs.c (expand_subword_shift): Take a scalar_int_mode rather
2994         than a machine_mode.
2995         (expand_doubleword_shift_condmove): Likewise.
2996         (expand_doubleword_shift): Likewise.
2997         (expand_doubleword_clz): Likewise.
2998         (expand_doubleword_popcount): Likewise.
2999         (expand_doubleword_parity): Likewise.
3000         (expand_absneg_bit): Use scalar_int_mode for local variables.
3001         (prepare_float_lib_cmp): Likewise.
3002         * rtl.h (convert_memory_address_addr_space_1): Take a scalar_int_mode
3003         rather than a machine_mode.
3004         (convert_memory_address_addr_space): Likewise.
3005         (get_mode_bounds): Likewise.
3006         (get_address_mode): Return a scalar_int_mode rather than a
3007         machine_mode.
3008         * rtlanal.c (get_address_mode): Likewise.
3009         * stor-layout.c (get_mode_bounds): Take a scalar_int_mode rather
3010         than a machine_mode.
3011         * targhooks.c (default_mode_rep_extended): Likewise.
3012         (default_valid_pointer_mode): Likewise.
3013         (default_addr_space_valid_pointer_mode): Likewise.
3014         (default_eh_return_filter_mode): Return a scalar_int_mode rather
3015         than a machine_mode.
3016         (default_libgcc_cmp_return_mode): Likewise.
3017         (default_libgcc_shift_count_mode): Likewise.
3018         (default_unwind_word_mode): Likewise.
3019         (default_addr_space_pointer_mode): Likewise.
3020         (default_addr_space_address_mode): Likewise.
3021         * targhooks.h (default_eh_return_filter_mode): Likewise.
3022         (default_libgcc_cmp_return_mode): Likewise.
3023         (default_libgcc_shift_count_mode): Likewise.
3024         (default_unwind_word_mode): Likewise.
3025         (default_addr_space_pointer_mode): Likewise.
3026         (default_addr_space_address_mode): Likewise.
3027         (default_mode_rep_extended): Take a scalar_int_mode rather than
3028         a machine_mode.
3029         (default_valid_pointer_mode): Likewise.
3030         (default_addr_space_valid_pointer_mode): Likewise.
3031         * tree-ssa-address.c (addr_for_mem_ref): Use scalar_int_mode for
3032         local variables.
3033         * tree-ssa-loop-ivopts.c (get_shiftadd_cost): Take a scalar_int_mode
3034         rather than a machine_mode.
3035         * tree-switch-conversion.c (array_value_type): Use scalar_int_mode
3036         for local variables.
3037         * tree-vrp.c (simplify_float_conversion_using_ranges): Likewise.
3038         * var-tracking.c (use_narrower_mode): Take a scalar_int_mode rather
3039         than a machine_mode.
3041 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3042             Alan Hayward  <alan.hayward@arm.com>
3043             David Sherwood  <david.sherwood@arm.com>
3045         * dojump.c (do_jump_by_parts_greater_rtx): Change the type of
3046         the mode argument to scalar_int_mode.
3047         (do_jump_by_parts_zero_rtx): Likewise.
3048         (do_jump_by_parts_equality_rtx): Likewise.
3049         (do_jump_by_parts_greater): Take a mode argument.
3050         (do_jump_by_parts_equality): Likewise.
3051         (do_jump_1): Update calls accordingly.
3053 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3054             Alan Hayward  <alan.hayward@arm.com>
3055             David Sherwood  <david.sherwood@arm.com>
3057         * is-a.h (safe_dyn_cast): New function.
3058         * rtl.h (rtx_jump_table_data::get_data_mode): New function.
3059         (jump_table_for_label): Likewise.
3060         * final.c (final_addr_vec_align): Take an rtx_jump_table_data *
3061         instead of an rtx_insn *.
3062         (shorten_branches): Use dyn_cast instead of LABEL_P and
3063         JUMP_TABLE_DATA_P.  Use jump_table_for_label and
3064         rtx_jump_table_data::get_data_mode.
3065         (final_scan_insn): Likewise.
3067 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3068             Alan Hayward  <alan.hayward@arm.com>
3069             David Sherwood  <david.sherwood@arm.com>
3071         * combine.c (try_combine): Use is_a <scalar_int_mode> when
3072         trying to combine a full-register integer set with a subreg
3073         integer set.
3075 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3076             Alan Hayward  <alan.hayward@arm.com>
3077             David Sherwood  <david.sherwood@arm.com>
3079         * expr.c (expand_expr_addr_expr): Add a new_tmode local variable
3080         that is always either address_mode or pointer_mode.
3082 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3083             Alan Hayward  <alan.hayward@arm.com>
3084             David Sherwood  <david.sherwood@arm.com>
3086         * expr.c (expand_expr_real_2): Use word_mode instead of innermode
3087         when the two are known to be equal.
3089 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3090             Alan Hayward  <alan.hayward@arm.com>
3091             David Sherwood  <david.sherwood@arm.com>
3093         * simplify-rtx.c (simplify_const_unary_operation): Use
3094         is_a <scalar_int_mode> instead of checking for a nonzero
3095         precision.  Forcibly convert op_mode to a scalar_int_mode
3096         in that case.  More clearly differentiate the operand and
3097         result modes and use the former when deciding what the value
3098         of a count-bits operation should be.  Use is_int_mode instead
3099         of checking for a MODE_INT.  Remove redundant check for whether
3100         this mode has a zero precision.
3102 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3103             Alan Hayward  <alan.hayward@arm.com>
3104             David Sherwood  <david.sherwood@arm.com>
3106         * optabs.c (widen_leading): Change the type of the mode argument
3107         to scalar_int_mode.  Use opt_scalar_int_mode for the mode iterator.
3108         (widen_bswap): Likewise.
3109         (expand_parity): Likewise.
3110         (expand_ctz): Change the type of the mode argument to scalar_int_mode.
3111         (expand_ffs): Likewise.
3112         (epand_unop): Check for scalar integer modes before calling the
3113         above routines.
3115 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3116             Alan Hayward  <alan.hayward@arm.com>
3117             David Sherwood  <david.sherwood@arm.com>
3119         * expr.c (const_scalar_mask_from_tree): Add a mode argument.
3120         Expand commentary.
3121         (expand_expr_real_1): Update call accordingly.
3123 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3124             Alan Hayward  <alan.hayward@arm.com>
3125             David Sherwood  <david.sherwood@arm.com>
3127         * expmed.c (store_bit_field_using_insv): Add op0_mode and
3128         value_mode arguments.  Use scalar_int_mode internally.
3129         (store_bit_field_1): Rename the new integer mode from imode
3130         to op0_mode and use it instead of GET_MODE (op0).  Update calls
3131         to store_split_bit_field, store_bit_field_using_insv and
3132         store_fixed_bit_field.
3133         (store_fixed_bit_field): Add op0_mode and value_mode arguments.
3134         Use scalar_int_mode internally.  Use a bit count rather than a mode
3135         when calculating the largest bit size for get_best_mode.
3136         Update calls to store_split_bit_field and store_fixed_bit_field_1.
3137         (store_fixed_bit_field_1): Add mode and value_mode arguments.
3138         Remove assertion that OP0 has a scalar integer mode.
3139         (store_split_bit_field): Add op0_mode and value_mode arguments.
3140         Update calls to extract_fixed_bit_field.
3141         (extract_bit_field_using_extv): Add an op0_mode argument.
3142         Use scalar_int_mode internally.
3143         (extract_bit_field_1): Rename the new integer mode from imode to
3144         op0_mode and use it instead of GET_MODE (op0).  Update calls to
3145         extract_split_bit_field, extract_bit_field_using_extv and
3146         extract_fixed_bit_field.
3147         (extract_fixed_bit_field): Add an op0_mode argument.  Update calls
3148         to extract_split_bit_field and extract_fixed_bit_field_1.
3149         (extract_fixed_bit_field_1): Add a mode argument.  Remove assertion
3150         that OP0 has a scalar integer mode.  Use as_a <scalar_int_mode>
3151         on the target mode.
3152         (extract_split_bit_field): Add an op0_mode argument.  Update call
3153         to extract_fixed_bit_field.
3155 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3156             Alan Hayward  <alan.hayward@arm.com>
3157             David Sherwood  <david.sherwood@arm.com>
3159         * cse.c (cse_insn): Use opt_scalar_int_mode for the mode iterator.
3160         * explow.c (hard_function_value): Likewise.
3161         * expmed.c (extract_fixed_bit_field_1): Likewise.  Move the
3162         convert_to_mode call outside the loop.
3163         * expr.c (alignment_for_piecewise_move): Use opt_scalar_int_mode
3164         for the mode iterator.  Require the mode specified by max_pieces
3165         to exist.
3166         (emit_block_move_via_movmem): Use opt_scalar_int_mode for the
3167         mode iterator.
3168         (copy_blkmode_to_reg): Likewise.
3169         (set_storage_via_setmem): Likewise.
3170         * optabs.c (prepare_cmp_insn): Likewise.
3171         * rtlanal.c (init_num_sign_bit_copies_in_rep): Likewise.
3172         * stor-layout.c (finish_bitfield_representative): Likewise.
3174 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3175             Alan Hayward  <alan.hayward@arm.com>
3176             David Sherwood  <david.sherwood@arm.com>
3178         * rtl.h (subreg_unpromoted_mode, subreg_promoted_mode): New functions.
3179         * expr.c (convert_move): Use them.
3180         (convert_modes): Likewise.
3181         (store_expr_with_bounds): Likewise.
3183 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3184             Alan Hayward  <alan.hayward@arm.com>
3185             David Sherwood  <david.sherwood@arm.com>
3187         * rtl.h (rtl_hooks::reg_nonzero_bits): Add a scalar_int_mode
3188         parameter for the mode of "x".  Remove the "known_x", "known_mode"
3189         and "known_ret" arguments.  Change the type of the mode argument
3190         to scalar_int_mode.
3191         (rtl_hooks:reg_num_sign_bit_copies): Likewise.
3192         * combine.c (reg_nonzero_bits_for_combine): Update accordingly.
3193         (reg_num_sign_bit_copies_for_combine): Likewise.
3194         * rtlanal.c (nonzero_bits1): Likewise.
3195         (num_sign_bit_copies1): Likewise.
3196         * rtlhooks-def.h (reg_nonzero_bits_general): Likewise.
3197         (reg_num_sign_bit_copies_general): Likewise.
3198         * rtlhooks.c (reg_num_sign_bit_copies_general): Likewise.
3199         (reg_nonzero_bits_general): Likewise.
3201 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3202             Alan Hayward  <alan.hayward@arm.com>
3203             David Sherwood  <david.sherwood@arm.com>
3205         * rtlanal.c (num_sign_bit_copies): Handle VOIDmode here rather
3206         than in subroutines.  Return 1 for non-integer modes.
3207         (cached_num_sign_bit_copies): Change the type of the mode parameter
3208         to scalar_int_mode.
3209         (num_sign_bit_copies1): Likewise.  Remove early exit for other mode
3210         classes.  Handle CONST_INT_P first and then check whether X also
3211         has a scalar integer mode.  Check the same thing for inner registers
3212         of a SUBREG and for values that are being extended or truncated.
3214 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3215             Alan Hayward  <alan.hayward@arm.com>
3216             David Sherwood  <david.sherwood@arm.com>
3218         * rtlanal.c (nonzero_bits): Handle VOIDmode here rather than
3219         in subroutines.  Return the mode mask for non-integer modes.
3220         (cached_nonzero_bits): Change the type of the mode parameter
3221         to scalar_int_mode.
3222         (nonzero_bits1): Likewise.  Remove early exit for other mode
3223         classes.  Handle CONST_INT_P first and then check whether X
3224         also has a scalar integer mode.
3226 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3227             Alan Hayward  <alan.hayward@arm.com>
3228             David Sherwood  <david.sherwood@arm.com>
3230         * expr.c (widest_int_mode_for_size): Make the comment match the code.
3231         Return a scalar_int_mode and assert that the size is greater than
3232         one byte.
3233         (by_pieces_ninsns): Update accordingly and remove VOIDmode handling.
3234         (op_by_pieces_d::op_by_pieces_d): Likewise.
3235         (op_by_pieces_d::run): Likewise.
3236         (can_store_by_pieces): Likewise.
3238 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3239             Alan Hayward  <alan.hayward@arm.com>
3240             David Sherwood  <david.sherwood@arm.com>
3242         * combine.c (extract_left_shift): Add a mode argument and update
3243         recursive calls.
3244         (make_compound_operation_int): Change the type of the mode parameter
3245         to scalar_int_mode and update the call to extract_left_shift.
3247 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3248             Alan Hayward  <alan.hayward@arm.com>
3249             David Sherwood  <david.sherwood@arm.com>
3251         * combine.c (simplify_and_const_int): Change the type of the mode
3252         parameter to scalar_int_mode.
3253         (simplify_and_const_int_1): Likewise.  Update recursive call.
3255 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3256             Alan Hayward  <alan.hayward@arm.com>
3257             David Sherwood  <david.sherwood@arm.com>
3259         * combine.c (simplify_compare_const): Check that the mode is a
3260         scalar_int_mode (rather than VOIDmode) before testing its
3261         precision.
3262         (simplify_comparison): Move COMPARISON_P handling out of the
3263         loop and restrict the latter part of the loop to scalar_int_modes.
3264         Check is_a <scalar_int_mode> before calling HWI_COMPUTABLE_MODE_P
3265         and when considering SUBREG_REGs.  Use is_int_mode instead of
3266         checking GET_MODE_CLASS against MODE_INT.
3268 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3269             Alan Hayward  <alan.hayward@arm.com>
3270             David Sherwood  <david.sherwood@arm.com>
3272         * combine.c (try_widen_shift_mode): Move check for equal modes to...
3273         (simplify_shift_const_1): ...here.  Use scalar_int_mode for
3274         shift_unit_mode and for modes involved in scalar shifts.
3276 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3277             Alan Hayward  <alan.hayward@arm.com>
3278             David Sherwood  <david.sherwood@arm.com>
3280         * combine.c (force_int_to_mode): New function, split out from...
3281         (force_to_mode): ...here.  Keep xmode up-to-date and use it
3282         instead of GET_MODE (x).
3284 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3285             Alan Hayward  <alan.hayward@arm.com>
3286             David Sherwood  <david.sherwood@arm.com>
3288         * optabs-query.h (extraction_insn::struct_mode): Change type to
3289         opt_scalar_int_mode and update comment.
3290         (extraction_insn::field_mode): Change type to scalar_int_mode.
3291         (extraction_insn::pos_mode): Likewise.
3292         * combine.c (make_extraction): Update accordingly.
3293         * optabs-query.c (get_traditional_extraction_insn): Likewise.
3294         (get_optab_extraction_insn): Likewise.
3295         * recog.c (simplify_while_replacing): Likewise.
3296         * expmed.c (narrow_bit_field_mem): Change the type of the mode
3297         parameter to opt_scalar_int_mode.
3299 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3300             Alan Hayward  <alan.hayward@arm.com>
3301             David Sherwood  <david.sherwood@arm.com>
3303         * machmode.h (bit_field_mode_iterator::next_mode): Take a pointer
3304         to a scalar_int_mode instead of a machine_mode.
3305         (bit_field_mode_iterator::m_mode): Change type to opt_scalar_int_mode.
3306         (get_best_mode): Return a boolean and use a pointer argument to store
3307         the selected mode.  Replace the limit mode parameter with a bit limit.
3308         * expmed.c (adjust_bit_field_mem_for_reg): Use scalar_int_mode
3309         for the values returned by bit_field_mode_iterator::next_mode.
3310         (store_bit_field): Update call to get_best_mode.
3311         (store_fixed_bit_field): Likewise.
3312         (extract_fixed_bit_field): Likewise.
3313         * expr.c (optimize_bitfield_assignment_op): Likewise.
3314         * fold-const.c (optimize_bit_field_compare): Likewise.
3315         (fold_truth_andor_1): Likewise.
3316         * stor-layout.c (bit_field_mode_iterator::next_mode): As above.
3317         Update for new type of m_mode.
3318         (get_best_mode): As above.
3320 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3321             Alan Hayward  <alan.hayward@arm.com>
3322             David Sherwood  <david.sherwood@arm.com>
3324         * expmed.c (strict_volatile_bitfield_p): Change the type of fieldmode
3325         to scalar_int_mode.  Remove check for SCALAR_INT_MODE_P.
3326         (store_bit_field): Check is_a <scalar_int_mode> before calling
3327         strict_volatile_bitfield_p.
3328         (extract_bit_field): Likewise.
3330 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3331             Alan Hayward  <alan.hayward@arm.com>
3332             David Sherwood  <david.sherwood@arm.com>
3334         * target.def (cstore_mode): Return a scalar_int_mode.
3335         * doc/tm.texi: Regenerate.
3336         * config/sparc/sparc.c (sparc_cstore_mode): Return a scalar_int_mode.
3337         * targhooks.h (default_cstore_mode): Likewise.
3338         * targhooks.c (default_cstore_mode): Likewise, using a forced
3339         conversion.
3340         * expmed.c (emit_cstore): Expect the target of the cstore to be
3341         a scalar_int_mode.
3343 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3344             Alan Hayward  <alan.hayward@arm.com>
3345             David Sherwood  <david.sherwood@arm.com>
3347         * cfgloop.h (rtx_iv): Change type of extend_mode and mode to
3348         scalar_int_mode.
3349         (niter_desc): Likewise mode.
3350         (iv_analyze): Add a mode parameter.
3351         (biv_p): Likewise.
3352         (iv_analyze_expr): Pass the mode paraeter before the rtx it describes
3353         and change its type to scalar_int_mode.
3354         * loop-iv.c: Update commentary at head of file.
3355         (iv_constant): Pass the mode paraeter before the rtx it describes
3356         and change its type to scalar_int_mode.  Remove VOIDmode handling.
3357         (iv_subreg): Change the type of the mode parameter to scalar_int_mode.
3358         (iv_extend): Likewise.
3359         (shorten_into_mode): Likewise.
3360         (iv_add): Use scalar_int_mode.
3361         (iv_mult): Likewise.
3362         (iv_shift): Likewise.
3363         (canonicalize_iv_subregs): Likewise.
3364         (get_biv_step_1): Pass the outer_mode parameter before the rtx
3365         it describes and change its mode to scalar_int_mode.   Also change
3366         the type of the returned inner_mode to scalar_int_mode.
3367         (get_biv_step): Likewise, turning outer_mode from a pointer
3368         into a direct parameter.  Update call to get_biv_step_1.
3369         (iv_analyze_biv): Add an outer_mode parameter.  Update calls to
3370         iv_constant and get_biv_step.
3371         (iv_analyze_expr): Pass the mode parameter before the rtx it describes
3372         and change its type to scalar_int_mode.  Don't initialise iv->mode
3373         to VOIDmode and remove later checks for its still being VOIDmode.
3374         Update calls to iv_analyze_op and iv_analyze_expr.  Check
3375         is_a <scalar_int_mode> when changing the mode under consideration.
3376         (iv_analyze_def): Ignore registers that don't have a scalar_int_mode.
3377         Update call to iv_analyze_expr.
3378         (iv_analyze_op): Add a mode parameter.  Reject subregs whose
3379         inner register is not also a scalar_int_mode.  Update call to
3380         iv_analyze_biv.
3381         (iv_analyze): Add a mode parameter.  Update call to iv_analyze_op.
3382         (biv_p): Add a mode parameter.  Update call to iv_analyze_biv.
3383         (iv_number_of_iterations): Use is_a <scalar_int_mode> instead of
3384         separate mode class checks.  Update calls to iv_analyze.  Remove
3385         fix-up of VOIDmodes after iv_analyze_biv.
3386         * loop-unroll.c (analyze_iv_to_split_insn): Reject registers that
3387         don't have a scalar_int_mode.  Update call to biv_p.
3389 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3390             Alan Hayward  <alan.hayward@arm.com>
3391             David Sherwood  <david.sherwood@arm.com>
3393         * cfgexpand.c (convert_debug_memory_address): Use
3394         as_a <scalar_int_mode>.
3395         * combine.c (expand_compound_operation): Likewise.
3396         (make_extraction): Likewise.
3397         (change_zero_ext): Likewise.
3398         (simplify_comparison): Likewise.
3399         * cse.c (cse_insn): Likewise.
3400         * dwarf2out.c (minmax_loc_descriptor): Likewise.
3401         (mem_loc_descriptor): Likewise.
3402         (loc_descriptor): Likewise.
3403         * expmed.c (init_expmed_one_mode): Likewise.
3404         (synth_mult): Likewise.
3405         (emit_store_flag_1): Likewise.
3406         (expand_divmod): Likewise.  Use HWI_COMPUTABLE_MODE_P instead
3407         of a comparison with size.
3408         * expr.c (expand_assignment): Use as_a <scalar_int_mode>.
3409         (reduce_to_bit_field_precision): Likewise.
3410         * function.c (expand_function_end): Likewise.
3411         * internal-fn.c (expand_arith_overflow_result_store): Likewise.
3412         * loop-doloop.c (doloop_modify): Likewise.
3413         * optabs.c (expand_binop): Likewise.
3414         (expand_unop): Likewise.
3415         (expand_copysign_absneg): Likewise.
3416         (prepare_cmp_insn): Likewise.
3417         (maybe_legitimize_operand): Likewise.
3418         * recog.c (const_scalar_int_operand): Likewise.
3419         * rtlanal.c (get_address_mode): Likewise.
3420         * simplify-rtx.c (simplify_unary_operation_1): Likewise.
3421         (simplify_cond_clz_ctz): Likewise.
3422         * tree-nested.c (get_nl_goto_field): Likewise.
3423         * tree.c (build_vector_type_for_mode): Likewise.
3424         * var-tracking.c (use_narrower_mode): Likewise.
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         * tree.h (SCALAR_INT_TYPE_MODE): New macro.
3431         * builtins.c (expand_builtin_signbit): Use it.
3432         * cfgexpand.c (expand_debug_expr): Likewise.
3433         * dojump.c (do_jump): Likewise.
3434         (do_compare_and_jump): Likewise.
3435         * dwarf2cfi.c (expand_builtin_init_dwarf_reg_sizes): Likewise.
3436         * expmed.c (make_tree): Likewise.
3437         * expr.c (expand_expr_real_2): Likewise.
3438         (expand_expr_real_1): Likewise.
3439         (try_casesi): Likewise.
3440         * fold-const-call.c (fold_const_call_ss): Likewise.
3441         * fold-const.c (unextend): Likewise.
3442         (extract_muldiv_1): Likewise.
3443         (fold_single_bit_test): Likewise.
3444         (native_encode_int): Likewise.
3445         (native_encode_string): Likewise.
3446         (native_interpret_int): Likewise.
3447         * gimple-fold.c (gimple_fold_builtin_memset): Likewise.
3448         * internal-fn.c (expand_addsub_overflow): Likewise.
3449         (expand_neg_overflow): Likewise.
3450         (expand_mul_overflow): Likewise.
3451         (expand_arith_overflow): Likewise.
3452         * match.pd: Likewise.
3453         * stor-layout.c (layout_type): Likewise.
3454         * tree-cfg.c (verify_gimple_assign_ternary): Likewise.
3455         * tree-ssa-math-opts.c (convert_mult_to_widen): Likewise.
3456         * tree-ssanames.c (get_range_info): Likewise.
3457         * tree-switch-conversion.c (array_value_type) Likewise.
3458         * tree-vect-patterns.c (vect_recog_rotate_pattern): Likewise.
3459         (vect_recog_divmod_pattern): Likewise.
3460         (vect_recog_mixed_size_cond_pattern): Likewise.
3461         * tree-vrp.c (extract_range_basic): Likewise.
3462         (simplify_float_conversion_using_ranges): Likewise.
3463         * tree.c (int_fits_type_p): Likewise.
3464         * ubsan.c (instrument_bool_enum_load): Likewise.
3465         * varasm.c (mergeable_string_section): Likewise.
3466         (narrowing_initializer_constant_valid_p): Likewise.
3467         (output_constant): Likewise.
3469 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3470             Alan Hayward  <alan.hayward@arm.com>
3471             David Sherwood  <david.sherwood@arm.com>
3473         * machmode.h (NARROWEST_INT_MODE): New macro.
3474         * expr.c (alignment_for_piecewise_move): Use it instead of
3475         GET_CLASS_NARROWEST_MODE (MODE_INT).
3476         (push_block): Likewise.
3477         * stor-layout.c (bit_field_mode_iterator::bit_field_mode_iterator):
3478         Likewise.
3479         * tree-vrp.c (simplify_float_conversion_using_ranges): Likewise.
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         * postreload.c (move2add_valid_value_p): Change the type of the
3486         mode parameter to scalar_int_mode.
3487         (move2add_use_add2_insn): Add a mode parameter and use it instead
3488         of GET_MODE (reg).
3489         (move2add_use_add3_insn): Likewise.
3490         (reload_cse_move2add): Update accordingly.
3492 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3493             Alan Hayward  <alan.hayward@arm.com>
3494             David Sherwood  <david.sherwood@arm.com>
3496         * expr.c (expand_expr_real_2): Use scalar_int_mode for the
3497         double-word mode.
3498         * lower-subreg.c (resolve_shift_zext): Use is_a <scalar_int_mode>.
3499         * optabs.c (expand_unop): Likewise.
3501 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3502             Alan Hayward  <alan.hayward@arm.com>
3503             David Sherwood  <david.sherwood@arm.com>
3505         * dwarf2out.c (typed_binop): Change mode parameter to scalar_int_mode.
3506         (clz_loc_descriptor): Likewise.  Remove SCALAR_INT_MODE_P check.
3507         (popcount_loc_descriptor): Likewise.
3508         (bswap_loc_descriptor): Likewise.
3509         (rotate_loc_descriptor): Likewise.
3510         (mem_loc_descriptor): Add is_a <scalar_int_mode> checks before
3511         calling the functions above.
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         * combine.c (sign_extend_short_imm): Add is_a <scalar_int_mode>
3518         checks.
3519         (try_combine): Likewise.
3520         (simplify_if_then_else): Likewise.
3521         * cse.c (cse_insn): Likewise.
3522         * dwarf2out.c (mem_loc_descriptor): Likewise.
3523         * emit-rtl.c (gen_lowpart_common): Likewise.
3524         * simplify-rtx.c (simplify_truncation): Likewise.
3525         (simplify_binary_operation_1): Likewise.
3526         (simplify_const_relational_operation): Likewise.
3527         (simplify_ternary_operation): Likewise.
3528         * tree-ssa-loop-ivopts.c (force_expr_to_var_cost): Likewise.
3530 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3531             Alan Hayward  <alan.hayward@arm.com>
3532             David Sherwood  <david.sherwood@arm.com>
3534         * cse.c (cse_insn): Add is_a <scalar_int_mode> checks.
3535         * reload.c (push_reload): Likewise.
3536         (find_reloads): Likewise.
3538 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3539             Alan Hayward  <alan.hayward@arm.com>
3540             David Sherwood  <david.sherwood@arm.com>
3542         * combine.c (find_split_point): Add is_a <scalar_int_mode> checks.
3543         (make_compound_operation_int): Likewise.
3544         (change_zero_ext): Likewise.
3545         * expr.c (convert_move): Likewise.
3546         (convert_modes): Likewise.
3547         * fwprop.c (forward_propagate_subreg): Likewise.
3548         * loop-iv.c (get_biv_step_1): Likewise.
3549         * optabs.c (widen_operand): Likewise.
3550         * postreload.c (move2add_valid_value_p): Likewise.
3551         * recog.c (simplify_while_replacing): Likewise.
3552         * simplify-rtx.c (simplify_unary_operation_1): Likewise.
3553         (simplify_binary_operation_1): Likewise.  Remove redundant
3554         mode equality check.
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         * combine.c (combine_simplify_rtx): Add checks for
3561         is_a <scalar_int_mode>.
3562         (simplify_if_then_else): Likewise.
3563         (make_field_assignment): Likewise.
3564         (simplify_comparison): Likewise.
3565         * ifcvt.c (noce_try_bitop): Likewise.
3566         * loop-invariant.c (canonicalize_address_mult): Likewise.
3567         * simplify-rtx.c (simplify_unary_operation_1): Likewise.
3569 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3570             Alan Hayward  <alan.hayward@arm.com>
3571             David Sherwood  <david.sherwood@arm.com>
3573         * gimple-fold.c (gimple_fold_builtin_memory_op): Use
3574         is_a <scalar_int_mode> instead of != BLKmode.
3576 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3577             Alan Hayward  <alan.hayward@arm.com>
3578             David Sherwood  <david.sherwood@arm.com>
3580         * cfgexpand.c (expand_debug_expr): Use is_a <scalar_int_mode>
3581         instead of != VOIDmode.
3582         * combine.c (if_then_else_cond): Likewise.
3583         (change_zero_ext): Likewise.
3584         * dwarf2out.c (mem_loc_descriptor): Likewise.
3585         (loc_descriptor): Likewise.
3586         * rtlanal.c (canonicalize_condition): Likewise.
3587         * simplify-rtx.c (simplify_relational_operation_1): Likewise.
3589 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3590             Alan Hayward  <alan.hayward@arm.com>
3591             David Sherwood  <david.sherwood@arm.com>
3593         * simplify-rtx.c (simplify_binary_operation_1): Use
3594         is_a <scalar_int_mode> instead of !VECTOR_MODE_P.
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         * wide-int.h (int_traits<unsigned char>) New class.
3601         (int_traits<unsigned short>) Likewise.
3602         * cfgexpand.c (expand_debug_expr): Use is_a <scalar_int_mode>.
3603         Use GET_MODE_UNIT_PRECISION and remove redundant test for
3604         SCALAR_INT_MODE_P.
3605         * combine.c (set_nonzero_bits_and_sign_copies): Use
3606         is_a <scalar_int_mode>.
3607         (find_split_point): Likewise.
3608         (combine_simplify_rtx): Likewise.
3609         (simplify_logical): Likewise.
3610         (expand_compound_operation): Likewise.
3611         (expand_field_assignment): Likewise.
3612         (make_compound_operation): Likewise.
3613         (extended_count): Likewise.
3614         (change_zero_ext): Likewise.
3615         (simplify_comparison): Likewise.
3616         * dwarf2out.c (scompare_loc_descriptor): Likewise.
3617         (ucompare_loc_descriptor): Likewise.
3618         (minmax_loc_descriptor): Likewise.
3619         (mem_loc_descriptor): Likewise.
3620         (loc_descriptor): Likewise.
3621         * expmed.c (init_expmed_one_mode): Likewise.
3622         * lra-constraints.c (lra_constraint_offset): Likewise.
3623         * optabs.c (prepare_libcall_arg): Likewise.
3624         * postreload.c (move2add_note_store): Likewise.
3625         * reload.c (operands_match_p): Likewise.
3626         * rtl.h (load_extend_op): Likewise.
3627         * rtlhooks.c (gen_lowpart_general): Likewise.
3628         * simplify-rtx.c (simplify_truncation): Likewise.
3629         (simplify_unary_operation_1): Likewise.
3630         (simplify_binary_operation_1): Likewise.
3631         (simplify_const_binary_operation): Likewise.
3632         (simplify_const_relational_operation): Likewise.
3633         (simplify_subreg): Likewise.
3634         * stor-layout.c (bitwise_mode_for_mode): Likewise.
3635         * var-tracking.c (adjust_mems): Likewise.
3636         (prepare_call_arguments): Likewise.
3638 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3639             Alan Hayward  <alan.hayward@arm.com>
3640             David Sherwood  <david.sherwood@arm.com>
3642         * machmode.h (is_int_mode): New fuction.
3643         * combine.c (find_split_point): Use it.
3644         (combine_simplify_rtx): Likewise.
3645         (simplify_if_then_else): Likewise.
3646         (simplify_set): Likewise.
3647         (simplify_shift_const_1): Likewise.
3648         (simplify_comparison): Likewise.
3649         * config/aarch64/aarch64.c (aarch64_rtx_costs): Likewise.
3650         * cse.c (notreg_cost): Likewise.
3651         (cse_insn): Likewise.
3652         * cselib.c (cselib_lookup_1): Likewise.
3653         * dojump.c (do_jump_1): Likewise.
3654         (do_compare_rtx_and_jump): Likewise.
3655         * dse.c (get_call_args): Likewise.
3656         * dwarf2out.c (rtl_for_decl_init): Likewise.
3657         (native_encode_initializer): Likewise.
3658         * expmed.c (emit_store_flag_1): Likewise.
3659         (emit_store_flag): Likewise.
3660         * expr.c (convert_modes): Likewise.
3661         (store_field): Likewise.
3662         (expand_expr_real_1): Likewise.
3663         * fold-const.c (fold_read_from_constant_string): Likewise.
3664         * gimple-ssa-sprintf.c (get_format_string): Likewise.
3665         * optabs-libfuncs.c (gen_int_libfunc): Likewise.
3666         * optabs.c (expand_binop): Likewise.
3667         (expand_unop): Likewise.
3668         (expand_abs_nojump): Likewise.
3669         (expand_one_cmpl_abs_nojump): Likewise.
3670         * simplify-rtx.c (mode_signbit_p): Likewise.
3671         (val_signbit_p): Likewise.
3672         (val_signbit_known_set_p): Likewise.
3673         (val_signbit_known_clear_p): Likewise.
3674         (simplify_relational_operation_1): Likewise.
3675         * tree.c (vector_type_mode): Likewise.
3677 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3678             Alan Hayward  <alan.hayward@arm.com>
3679             David Sherwood  <david.sherwood@arm.com>
3681         * machmode.h (smallest_mode_for_size): Fix formatting.
3682         (smallest_int_mode_for_size): New function.
3683         * cfgexpand.c (expand_debug_expr): Use smallest_int_mode_for_size
3684         instead of smallest_mode_for_size.
3685         * combine.c (make_extraction): Likewise.
3686         * config/arc/arc.c (arc_expand_movmem): Likewise.
3687         * config/arm/arm.c (arm_expand_divmod_libfunc): Likewise.
3688         * config/i386/i386.c (ix86_get_mask_mode): Likewise.
3689         * config/s390/s390.c (s390_expand_insv): Likewise.
3690         * config/sparc/sparc.c (assign_int_registers): Likewise.
3691         * config/spu/spu.c (spu_function_value): Likewise.
3692         (spu_function_arg): Likewise.
3693         * coverage.c (get_gcov_type): Likewise.
3694         (get_gcov_unsigned_t): Likewise.
3695         * dse.c (find_shift_sequence): Likewise.
3696         * expmed.c (store_bit_field_1): Likewise.
3697         * expr.c (convert_move): Likewise.
3698         (store_field): Likewise.
3699         * internal-fn.c (expand_arith_overflow): Likewise.
3700         * optabs-query.c (get_best_extraction_insn): Likewise.
3701         * optabs.c (expand_twoval_binop_libfunc): Likewise.
3702         * stor-layout.c (layout_type): Likewise.
3703         (initialize_sizetypes): Likewise.
3704         * targhooks.c (default_get_mask_mode): Likewise.
3705         * tree-ssa-loop-manip.c (canonicalize_loop_ivs): Likewise.
3707 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3708             Alan Hayward  <alan.hayward@arm.com>
3709             David Sherwood  <david.sherwood@arm.com>
3711         * machmode.h (opt_mode::else_blk): New function.
3712         (int_mode_for_mode): Declare.
3713         * stor-layout.c (int_mode_for_mode): Return an opt_scalar_int_mode.
3714         * builtins.c (expand_builtin_signbit): Adjust for new int_mode_for_mode
3715         return type.
3716         * cfgexpand.c (expand_debug_expr): Likewise.
3717         * combine.c (gen_lowpart_or_truncate): Likewise.
3718         (gen_lowpart_for_combine): Likewise.
3719         * config/aarch64/aarch64.c (aarch64_emit_approx_sqrt): Likewise.
3720         * config/avr/avr.c (avr_to_int_mode): Likewise.
3721         (avr_out_plus_1): Likewise.
3722         (avr_out_plus): Likewise.
3723         (avr_out_round): Likewise.
3724         * config/i386/i386.c (ix86_split_to_parts): Likewise.
3725         * config/s390/s390.c (s390_expand_vec_compare_cc): Likewise.
3726         (s390_expand_vcond): Likewise.
3727         * config/spu/spu.c (spu_split_immediate): Likewise.
3728         (spu_expand_mov): Likewise.
3729         * dse.c (get_stored_val): Likewise.
3730         * expmed.c (store_bit_field_1): Likewise.
3731         (convert_extracted_bit_field): Use int_mode_for_mode instead of
3732         int_mode_for_size.
3733         (extract_bit_field_1): Adjust for new int_mode_for_mode return type.
3734         (extract_low_bits): Likewise.
3735         * expr.c (emit_group_load_1): Likewise.  Separate out the BLKmode
3736         handling rather than repeating the check.
3737         (emit_group_store): Likewise.
3738         (emit_move_via_integer): Adjust for new int_mode_for_mode return type.
3739         * optabs.c (expand_absneg_bit): Likewise.
3740         (expand_copysign_absneg): Likewise.
3741         (expand_copysign_bit): Likewise.
3742         * tree-if-conv.c (ifcvt_can_use_mask_load_store): Likewise.
3743         * tree-vect-slp.c (vect_transform_slp_perm_load): Likewise.
3744         * tree-vect-stmts.c (vect_gen_perm_mask_any): Likewise.
3745         * var-tracking.c (prepare_call_arguments):  Likewise.
3746         * config/powerpcspe/powerpcspe.c (rs6000_do_expand_vec_perm): Use
3747         int_mode_for_mode instead of mode_for_size.
3748         * config/rs6000/rs6000.c (rs6000_do_expand_vec_perm): Likewise.
3750 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3751             Alan Hayward  <alan.hayward@arm.com>
3752             David Sherwood  <david.sherwood@arm.com>
3754         * machmode.h (int_mode_for_size): New function.
3755         * builtins.c (set_builtin_user_assembler_name): Use int_mode_for_size
3756         instead of mode_for_size.
3757         * calls.c (save_fixed_argument_area): Likewise.  Make use of BLKmode
3758         explicit.
3759         * combine.c (expand_field_assignment): Use int_mode_for_size
3760         instead of mode_for_size.
3761         (make_extraction): Likewise.
3762         (simplify_shift_const_1): Likewise.
3763         (simplify_comparison): Likewise.
3764         * dojump.c (do_jump): Likewise.
3765         * dwarf2out.c (mem_loc_descriptor): Likewise.
3766         * emit-rtl.c (init_derived_machine_modes): Likewise.
3767         * expmed.c (flip_storage_order): Likewise.
3768         (convert_extracted_bit_field): Likewise.
3769         * expr.c (copy_blkmode_from_reg): Likewise.
3770         * graphite-isl-ast-to-gimple.c (max_mode_int_precision): Likewise.
3771         * internal-fn.c (expand_mul_overflow): Likewise.
3772         * lower-subreg.c (simple_move): Likewise.
3773         * optabs-libfuncs.c (init_optabs): Likewise.
3774         * simplify-rtx.c (simplify_unary_operation_1): Likewise.
3775         * tree.c (vector_type_mode): Likewise.
3776         * tree-ssa-strlen.c (handle_builtin_memcmp): Likewise.
3777         * tree-vect-data-refs.c (vect_lanes_optab_supported_p): Likewise.
3778         * tree-vect-generic.c (expand_vector_parallel): Likewise.
3779         * tree-vect-stmts.c (vectorizable_load): Likewise.
3780         (vectorizable_store): Likewise.
3782 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3783             Alan Hayward  <alan.hayward@arm.com>
3784             David Sherwood  <david.sherwood@arm.com>
3786         * coretypes.h (pod_mode): New type.
3787         (scalar_int_mode_pod): New typedef.
3788         * machmode.h (pod_mode): New class.
3789         (int_n_data_t::m): Change type to scalar_int_mode_pod.
3790         * genmodes.c (emit_mode_int_n): Update accordingly.
3791         * lower-subreg.h (target_lower_subreg): Change type to
3792         scalar_int_mode_pod.
3793         * gdbhooks.py (build_pretty_printer): Handle pod_mode and
3794         scalar_int_mode_pod.
3796 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3797             Alan Hayward  <alan.hayward@arm.com>
3798             David Sherwood  <david.sherwood@arm.com>
3800         * config/powerpcspe/powerpcspe.h (rs6000_pmode): Change type from
3801         machine_mode to scalar_int_mode.
3802         * config/powerpcspe/powerpcspe.c (rs6000_pmode): Likewise.
3803         (rs6000_option_override_internal): Remove cast to int.
3804         * config/rs6000/rs6000.h (rs6000_pmode): Change type from
3805         machine_mode to scalar_int_mode.
3806         * config/rs6000/rs6000.c (rs6000_pmode): Likewise.
3807         (rs6000_option_override_internal): Remove cast to int.
3808         * config/s390/s390.h (Pmode): Remove cast to machine_mode.
3809         * config/epiphany/epiphany.h (RTX_OK_FOR_OFFSET_P): Add cast
3810         to machine_mode.
3811         * config/s390/s390.c (s390_expand_builtin): Likewise.
3812         * coretypes.h (scalar_int_mode): New type.
3813         (opt_scalar_int_mode): New typedef.
3814         * machmode.h (scalar_int_mode): New class.
3815         (scalar_int_mode::includes_p): New function.
3816         (byte_mode): Change type to scalar_int_mode.
3817         (word_mode): Likewise.
3818         (ptr_mode): Likewise.
3819         * emit-rtl.c (byte_mode): Likewise.
3820         (word_mode): Likewise.
3821         (ptr_mode): Likewise.
3822         (init_derived_machine_modes): Update accordingly.
3823         * genmodes.c (get_mode_class): Return scalar_int_mode for MODE_INT
3824         and MODE_PARTIAL_INT.
3825         * gdbhooks.py (build_pretty_printer): Handle scalar_int_mode and
3826         opt_scalar_int_mode.
3828 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3829             Alan Hayward  <alan.hayward@arm.com>
3830             David Sherwood  <david.sherwood@arm.com>
3832         * target.def (libgcc_floating_mode_supported_p): Take a
3833         scalar_float_mode.
3834         * doc/tm.texi: Regenerate.
3835         * targhooks.h (default_libgcc_floating_mode_supported_p): Take a
3836         scalar_float_mode.
3837         * targhooks.c (default_libgcc_floating_mode_supported_p): Likewise.
3838         * config/aarch64/aarch64.c (aarch64_libgcc_floating_mode_supported_p):
3839         Likewise.
3841 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3842             Alan Hayward  <alan.hayward@arm.com>
3843             David Sherwood  <david.sherwood@arm.com>
3845         * target.def (default_floatn_mode): Return an opt_scalar_float_mode.
3846         * doc/tm.texi: Regenerate.
3847         * config/arm/arm.c (arm_floatn_mode): Return an opt_scalar_float_mode.
3848         * config/powerpcspe/powerpcspe.c (rs6000_floatn_mode): Likewise.
3849         * config/rs6000/rs6000.c (rs6000_floatn_mode): Likewise.
3850         * targhooks.h (default_floatn_mode): Likewise.
3851         * targhooks.c (default_floatn_mode): Likewise.
3852         * tree.c (build_common_tree_nodes): Update accordingly.
3854 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3855             Alan Hayward  <alan.hayward@arm.com>
3856             David Sherwood  <david.sherwood@arm.com>
3858         * machmode.h (mode_iterator::start): Provide overload for opt_modes.
3859         (mode_iterator::iterate_p): Likewise.
3860         (mode_iterator::get_wider): Likewise.
3861         * expr.c (init_expr_target): Use opt_scalar_float_mode.
3863 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3864             Alan Hayward  <alan.hayward@arm.com>
3865             David Sherwood  <david.sherwood@arm.com>
3867         * coretypes.h (opt_scalar_float_mode): New typedef.
3868         * machmode.h (float_mode_for_size): New function.
3869         * emit-rtl.c (double_mode): Delete.
3870         (init_emit_once): Use float_mode_for_size.
3871         * stor-layout.c (layout_type): Likewise.
3872         * gdbhooks.py (build_pretty_printer): Handle opt_scalar_float_mode.
3874 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3875             Alan Hayward  <alan.hayward@arm.com>
3876             David Sherwood  <david.sherwood@arm.com>
3878         * output.h (assemble_real): Take a scalar_float_mode.
3879         * config/arm/arm.c (arm_assemble_integer): Update accordingly.
3880         * config/arm/arm.md (consttable_4): Likewise.
3881         (consttable_8): Likewise.
3882         (consttable_16): Likewise.
3883         * config/mips/mips.md (consttable_float): Likewise.
3884         * config/s390/s390.c (s390_output_pool_entry): Likewise.
3885         * varasm.c (assemble_real): Take a scalar_float_mode.
3886         (output_constant_pool_2): Update accordingly.
3887         (output_constant): Likewise.
3889 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3890             Alan Hayward  <alan.hayward@arm.com>
3891             David Sherwood  <david.sherwood@arm.com>
3893         * tree.h (SCALAR_FLOAT_TYPE_MODE): New macro.
3894         * builtins.c (expand_builtin_signbit): Use it instead of TYPE_MODE.
3895         * fold-const.c (fold_convert_const_real_from_fixed): Likewise.
3896         (native_encode_real): Likewise.
3897         (native_interpret_real): Likewise.
3898         * hsa-brig.c (emit_immediate_scalar_to_buffer): Likewise.
3899         * tree-vrp.c (simplify_float_conversion_using_ranges): Likewise.
3901 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3902             Alan Hayward  <alan.hayward@arm.com>
3903             David Sherwood  <david.sherwood@arm.com>
3905         * optabs-libfuncs.c (gen_trunc_conv_libfunc): Use is_a
3906         <scalar_float_mode>.  Simplify.
3907         (gen_extend_conv_libfunc): Likewise.
3909 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3910             Alan Hayward  <alan.hayward@arm.com>
3911             David Sherwood  <david.sherwood@arm.com>
3913         * coretypes.h (scalar_float_mode): New type.
3914         * machmode.h (mode_traits::from_int): Use machine_mode if
3915         USE_ENUM_MODES is defined.
3916         (is_a): New function.
3917         (as_a): Likewise.
3918         (dyn_cast): Likewise.
3919         (scalar_float_mode): New class.
3920         (scalar_float_mode::includes_p): New function.
3921         (is_float_mode): Likewise.
3922         * gdbhooks.py (MachineModePrinter): New class.
3923         (build_pretty_printer): Use it for scalar_float_mode.
3924         * real.h (FLOAT_MODE_FORMAT): Use as_a <scalar_float_mode>.
3925         (format_helper::format_helper): Turn into a template.
3926         * genmodes.c (get_mode_class): New function.
3927         (emit_insn_modes_h): Give modes the class returned by get_mode_class,
3928         or machine_mode if none.
3929         * config/aarch64/aarch64.c (aarch64_simd_valid_immediate): Use
3930         as_a <scalar_float_mode>.
3931         * dwarf2out.c (mem_loc_descriptor): Likewise.
3932         (insert_float): Likewise.
3933         (add_const_value_attribute): Likewise.
3934         * simplify-rtx.c (simplify_immed_subreg): Likewise.
3935         * optabs.c (expand_absneg_bit): Take a scalar_float_mode.
3936         (expand_unop): Update accordingly.
3937         (expand_abs_nojump): Likewise.
3938         (expand_copysign_absneg): Take a scalar_float_mode.
3939         (expand_copysign_bit): Likewise.
3940         (expand_copysign): Update accordingly.
3942 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
3943             Alan Hayward  <alan.hayward@arm.com>
3944             David Sherwood  <david.sherwood@arm.com>
3946         * coretypes.h (opt_mode): New class.
3947         * machmode.h (opt_mode): Likewise.
3948         (opt_mode::else_void): New function.
3949         (opt_mode::require): Likewise.
3950         (opt_mode::exists): Likewise.
3951         (GET_MODE_WIDER_MODE): Turn into a function and return an opt_mode.
3952         (GET_MODE_2XWIDER_MODE): Likewise.
3953         (mode_iterator::get_wider): Update accordingly.
3954         (mode_iterator::get_2xwider): Likewise.
3955         (mode_iterator::get_known_wider): Likewise, turning into a template.
3956         * combine.c (make_extraction): Update use of GET_MODE_WIDER_MODE,
3957         forcing a wider mode to exist.
3958         * config/cr16/cr16.h (LONG_REG_P): Likewise.
3959         * rtlanal.c (init_num_sign_bit_copies_in_rep): Likewise.
3960         * config/c6x/c6x.c (c6x_rtx_costs): Update use of
3961         GET_MODE_2XWIDER_MODE, forcing a wider mode to exist.
3962         * lower-subreg.c (init_lower_subreg): Likewise.
3963         * optabs-libfuncs.c (init_sync_libfuncs_1): Likewise, but not
3964         on the final iteration.
3965         * config/i386/i386.c (ix86_expand_set_or_movmem): Check whether
3966         a wider mode exists before asking for a move pattern.
3967         (get_mode_wider_vector): Update use of GET_MODE_WIDER_MODE,
3968         forcing a wider mode to exist.
3969         (expand_vselect_vconcat): Update use of GET_MODE_2XWIDER_MODE,
3970         returning false if no such mode exists.
3971         * config/ia64/ia64.c (expand_vselect_vconcat): Likewise.
3972         * config/mips/mips.c (mips_expand_vselect_vconcat): Likewise.
3973         * expmed.c (init_expmed_one_mode): Update use of GET_MODE_WIDER_MODE.
3974         Avoid checking for a MODE_INT if we already know the mode is not a
3975         SCALAR_INT_MODE_P.
3976         (extract_high_half): Update use of GET_MODE_WIDER_MODE,
3977         forcing a wider mode to exist.
3978         (expmed_mult_highpart_optab): Likewise.
3979         (expmed_mult_highpart): Likewise.
3980         * expr.c (expand_expr_real_2): Update use of GET_MODE_WIDER_MODE,
3981         using else_void.
3982         * lto-streamer-in.c (lto_input_mode_table): Likewise.
3983         * optabs-query.c (find_widening_optab_handler_and_mode): Likewise.
3984         * stor-layout.c (bit_field_mode_iterator::next_mode): Likewise.
3985         * internal-fn.c (expand_mul_overflow): Update use of
3986         GET_MODE_2XWIDER_MODE.
3987         * omp-low.c (omp_clause_aligned_alignment): Likewise.
3988         * tree-ssa-math-opts.c (convert_mult_to_widen): Update use of
3989         GET_MODE_WIDER_MODE.
3990         (convert_plusminus_to_widen): Likewise.
3991         * tree-switch-conversion.c (array_value_type): Likewise.
3992         * var-tracking.c (emit_note_insn_var_location): Likewise.
3993         * tree-vrp.c (simplify_float_conversion_using_ranges): Likewise.
3994         Return false inside rather than outside the loop if no wider mode
3995         exists
3996         * optabs.c (expand_binop): Update use of GET_MODE_WIDER_MODE
3997         and GET_MODE_2XWIDER_MODE
3998         (can_compare_p): Use else_void.
3999         * gdbhooks.py (OptMachineModePrinter): New class.
4000         (build_pretty_printer): Use it for opt_mode.
4002 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
4003             Alan Hayward  <alan.hayward@arm.com>
4004             David Sherwood  <david.sherwood@arm.com>
4006         * tree-switch-conversion.c (array_value_type): Only read TYPE_MODE
4007         once.  Use get_narrowest_mode instead of GET_CLASS_NARROWEST_MODE.
4009 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
4010             Alan Hayward  <alan.hayward@arm.com>
4011             David Sherwood  <david.sherwood@arm.com>
4013         * machmode.h (mode_traits): New structure.
4014         (get_narrowest_mode): New function.
4015         (mode_iterator::start): Likewise.
4016         (mode_iterator::iterate_p): Likewise.
4017         (mode_iterator::get_wider): Likewise.
4018         (mode_iterator::get_known_wider): Likewise.
4019         (mode_iterator::get_2xwider): Likewise.
4020         (FOR_EACH_MODE_IN_CLASS): New mode iterator.
4021         (FOR_EACH_MODE): Likewise.
4022         (FOR_EACH_MODE_FROM): Likewise.
4023         (FOR_EACH_MODE_UNTIL): Likewise.
4024         (FOR_EACH_WIDER_MODE): Likewise.
4025         (FOR_EACH_2XWIDER_MODE): Likewise.
4026         * builtins.c (expand_builtin_strlen): Use new mode iterators.
4027         * combine.c (simplify_comparison): Likewise
4028         * config/i386/i386.c (type_natural_mode): Likewise.
4029         * cse.c (cse_insn): Likewise.
4030         * dse.c (find_shift_sequence): Likewise.
4031         * emit-rtl.c (init_derived_machine_modes): Likewise.
4032         (init_emit_once): Likewise.
4033         * explow.c (hard_function_value): Likewise.
4034         * expmed.c (extract_fixed_bit_field_1): Likewise.
4035         (extract_bit_field_1): Likewise.
4036         (expand_divmod): Likewise.
4037         (emit_store_flag_1): Likewise.
4038         * expr.c (init_expr_target): Likewise.
4039         (convert_move): Likewise.
4040         (alignment_for_piecewise_move): Likewise.
4041         (widest_int_mode_for_size): Likewise.
4042         (emit_block_move_via_movmem): Likewise.
4043         (copy_blkmode_to_reg): Likewise.
4044         (set_storage_via_setmem): Likewise.
4045         (compress_float_constant): Likewise.
4046         * omp-low.c (omp_clause_aligned_alignment): Likewise.
4047         * optabs-query.c (get_best_extraction_insn): Likewise.
4048         * optabs.c (expand_binop): Likewise.
4049         (expand_twoval_unop): Likewise.
4050         (expand_twoval_binop): Likewise.
4051         (widen_leading): Likewise.
4052         (widen_bswap): Likewise.
4053         (expand_parity): Likewise.
4054         (expand_unop): Likewise.
4055         (prepare_cmp_insn): Likewise.
4056         (prepare_float_lib_cmp): Likewise.
4057         (expand_float): Likewise.
4058         (expand_fix): Likewise.
4059         (expand_sfix_optab): Likewise.
4060         * postreload.c (move2add_use_add2_insn): Likewise.
4061         * reg-stack.c (reg_to_stack): Likewise.
4062         * reginfo.c (choose_hard_reg_mode): Likewise.
4063         * rtlanal.c (init_num_sign_bit_copies_in_rep): Likewise.
4064         * stor-layout.c (mode_for_size): Likewise.
4065         (smallest_mode_for_size): Likewise.
4066         (mode_for_vector): Likewise.
4067         (finish_bitfield_representative): Likewise.
4068         * tree-ssa-math-opts.c (target_supports_divmod_p): Likewise.
4069         * tree-vect-generic.c (type_for_widest_vector_mode): Likewise.
4070         * tree-vect-stmts.c (vectorizable_conversion): Likewise.
4071         * var-tracking.c (prepare_call_arguments): Likewise.
4073 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
4074             Alan Hayward  <alan.hayward@arm.com>
4075             David Sherwood  <david.sherwood@arm.com>
4077         * genconditions.c (write_header): Add a "#define USE_ENUM_MODES".
4078         * genmodes.c (emit_insn_modes_h): Define FOOmode to E_FOOmode if
4079         USE_ENUM_MODES is defined and to ((void) 0, E_FOOmode) otherwise.
4080         * machmode.h (mode_size): Move earlier in file.
4081         (mode_precision): Likewise.
4082         (mode_inner): Likewise.
4083         (mode_nunits): Likewise.
4084         (mode_unit_size): Likewise.
4085         (unit_unit_precision): Likewise.
4086         (mode_wider): Likewise.
4087         (mode_2xwider): Likewise.
4088         (machine_mode): New class.
4089         (mode_to_bytes): New function.
4090         (mode_to_bits): Likewise.
4091         (mode_to_precision): Likewise.
4092         (mode_to_inner): Likewise.
4093         (mode_to_unit_size): Likewise.
4094         (mode_to_unit_precision): Likewise.
4095         (mode_to_nunits): Likewise.
4096         (GET_MODE_SIZE): Use mode_to_bytes.
4097         (GET_MODE_BITSIZE): Use mode_to_bits.
4098         (GET_MODE_PRECISION): Use mode_to_precision.
4099         (GET_MODE_INNER): Use mode_to_inner.
4100         (GET_MODE_UNIT_SIZE): Use mode_to_unit_size.
4101         (GET_MODE_UNIT_PRECISION): Use mode_to_unit_precision.
4102         (GET_MODE_NUNITS): Use mode_to_nunits.
4103         * system.h (ALWAYS_INLINE): New macro.
4104         * config/powerpcspe/powerpcspe-c.c
4105         (altivec_resolve_overloaded_builtin): Use machine_mode instead of
4106         int for arg1_mode and arg2_mode.
4108 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
4109             Alan Hayward  <alan.hayward@arm.com>
4110             David Sherwood  <david.sherwood@arm.com>
4112         * config/aarch64/aarch64-builtins.c (aarch64_simd_builtin_std_type):
4113         Prefix mode names with E_ in case statements.
4114         * config/aarch64/aarch64-elf.h (ASM_OUTPUT_ADDR_DIFF_ELT): Likewise.
4115         * config/aarch64/aarch64.c (aarch64_split_simd_combine): Likewise.
4116         (aarch64_split_simd_move): Likewise.
4117         (aarch64_gen_storewb_pair): Likewise.
4118         (aarch64_gen_loadwb_pair): Likewise.
4119         (aarch64_gen_store_pair): Likewise.
4120         (aarch64_gen_load_pair): Likewise.
4121         (aarch64_get_condition_code_1): Likewise.
4122         (aarch64_constant_pool_reload_icode): Likewise.
4123         (get_rsqrte_type): Likewise.
4124         (get_rsqrts_type): Likewise.
4125         (get_recpe_type): Likewise.
4126         (get_recps_type): Likewise.
4127         (aarch64_gimplify_va_arg_expr): Likewise.
4128         (aarch64_simd_container_mode): Likewise.
4129         (aarch64_emit_load_exclusive): Likewise.
4130         (aarch64_emit_store_exclusive): Likewise.
4131         (aarch64_expand_compare_and_swap): Likewise.
4132         (aarch64_gen_atomic_cas): Likewise.
4133         (aarch64_emit_bic): Likewise.
4134         (aarch64_emit_atomic_swap): Likewise.
4135         (aarch64_emit_atomic_load_op): Likewise.
4136         (aarch64_evpc_trn): Likewise.
4137         (aarch64_evpc_uzp): Likewise.
4138         (aarch64_evpc_zip): Likewise.
4139         (aarch64_evpc_ext): Likewise.
4140         (aarch64_evpc_rev): Likewise.
4141         (aarch64_evpc_dup): Likewise.
4142         (aarch64_gen_ccmp_first): Likewise.
4143         (aarch64_gen_ccmp_next): Likewise.
4144         * config/alpha/alpha.c (alpha_scalar_mode_supported_p): Likewise.
4145         (alpha_emit_xfloating_libcall): Likewise.
4146         (emit_insxl): Likewise.
4147         (alpha_arg_type): Likewise.
4148         * config/arc/arc.c (arc_vector_mode_supported_p): Likewise.
4149         (arc_preferred_simd_mode): Likewise.
4150         (arc_secondary_reload): Likewise.
4151         (get_arc_condition_code): Likewise.
4152         (arc_print_operand): Likewise.
4153         (arc_legitimate_constant_p): Likewise.
4154         * config/arc/arc.h (ASM_OUTPUT_ADDR_DIFF_ELT): Likewise.
4155         * config/arc/arc.md (casesi_load): Likewise.
4156         (casesi_compact_jump): Likewise.
4157         * config/arc/predicates.md (proper_comparison_operator): Likewise.
4158         (cc_use_register): Likewise.
4159         * config/arm/aout.h (ASM_OUTPUT_ADDR_DIFF_ELT): Likewise.
4160         * config/arm/arm-builtins.c (arm_simd_builtin_std_type): Likewise.
4161         (arm_init_iwmmxt_builtins): Likewise.
4162         * config/arm/arm.c (thumb1_size_rtx_costs): Likewise.
4163         (neon_expand_vector_init): Likewise.
4164         (arm_attr_length_move_neon): Likewise.
4165         (maybe_get_arm_condition_code): Likewise.
4166         (arm_emit_vector_const): Likewise.
4167         (arm_preferred_simd_mode): Likewise.
4168         (arm_output_iwmmxt_tinsr): Likewise.
4169         (thumb1_output_casesi): Likewise.
4170         (thumb2_output_casesi): Likewise.
4171         (arm_emit_load_exclusive): Likewise.
4172         (arm_emit_store_exclusive): Likewise.
4173         (arm_expand_compare_and_swap): Likewise.
4174         (arm_evpc_neon_vuzp): Likewise.
4175         (arm_evpc_neon_vzip): Likewise.
4176         (arm_evpc_neon_vrev): Likewise.
4177         (arm_evpc_neon_vtrn): Likewise.
4178         (arm_evpc_neon_vext): Likewise.
4179         (arm_validize_comparison): Likewise.
4180         * config/arm/neon.md (neon_vc<cmp_op><mode>): Likewise.
4181         * config/avr/avr-c.c (avr_resolve_overloaded_builtin): Likewise.
4182         * config/avr/avr.c (avr_rtx_costs_1): Likewise.
4183         * config/c6x/c6x.c (c6x_vector_mode_supported_p): Likewise.
4184         (c6x_preferred_simd_mode): Likewise.
4185         * config/epiphany/epiphany.c (get_epiphany_condition_code): Likewise.
4186         (epiphany_rtx_costs): Likewise.
4187         * config/epiphany/predicates.md (proper_comparison_operator):
4188         Likewise.
4189         * config/frv/frv.c (condexec_memory_operand): Likewise.
4190         (frv_emit_move): Likewise.
4191         (output_move_single): Likewise.
4192         (output_condmove_single): Likewise.
4193         (frv_hard_regno_mode_ok): Likewise.
4194         (frv_matching_accg_mode): Likewise.
4195         * config/h8300/h8300.c (split_adds_subs): Likewise.
4196         (h8300_rtx_costs): Likewise.
4197         (h8300_print_operand): Likewise.
4198         (compute_mov_length): Likewise.
4199         (output_logical_op): Likewise.
4200         (compute_logical_op_length): Likewise.
4201         (compute_logical_op_cc): Likewise.
4202         (h8300_shift_needs_scratch_p): Likewise.
4203         (output_a_shift): Likewise.
4204         (compute_a_shift_length): Likewise.
4205         (compute_a_shift_cc): Likewise.
4206         (expand_a_rotate): Likewise.
4207         (output_a_rotate): Likewise.
4208         * config/i386/i386.c (classify_argument): Likewise.
4209         (function_arg_advance_32): Likewise.
4210         (function_arg_32): Likewise.
4211         (function_arg_64): Likewise.
4212         (function_value_64): Likewise.
4213         (ix86_gimplify_va_arg): Likewise.
4214         (ix86_legitimate_constant_p): Likewise.
4215         (put_condition_code): Likewise.
4216         (split_double_mode): Likewise.
4217         (ix86_avx256_split_vector_move_misalign): Likewise.
4218         (ix86_expand_vector_logical_operator): Likewise.
4219         (ix86_split_idivmod): Likewise.
4220         (ix86_expand_adjust_ufix_to_sfix_si): Likewise.
4221         (ix86_build_const_vector): Likewise.
4222         (ix86_build_signbit_mask): Likewise.
4223         (ix86_match_ccmode): Likewise.
4224         (ix86_cc_modes_compatible): Likewise.
4225         (ix86_expand_branch): Likewise.
4226         (ix86_expand_sse_cmp): Likewise.
4227         (ix86_expand_sse_movcc): Likewise.
4228         (ix86_expand_int_sse_cmp): Likewise.
4229         (ix86_expand_vec_perm_vpermi2): Likewise.
4230         (ix86_expand_vec_perm): Likewise.
4231         (ix86_expand_sse_unpack): Likewise.
4232         (ix86_expand_int_addcc): Likewise.
4233         (ix86_split_to_parts): Likewise.
4234         (ix86_vectorize_builtin_gather): Likewise.
4235         (ix86_vectorize_builtin_scatter): Likewise.
4236         (avx_vpermilp_parallel): Likewise.
4237         (inline_memory_move_cost): Likewise.
4238         (ix86_tieable_integer_mode_p): Likewise.
4239         (x86_maybe_negate_const_int): Likewise.
4240         (ix86_expand_vector_init_duplicate): Likewise.
4241         (ix86_expand_vector_init_one_nonzero): Likewise.
4242         (ix86_expand_vector_init_one_var): Likewise.
4243         (ix86_expand_vector_init_concat): Likewise.
4244         (ix86_expand_vector_init_interleave): Likewise.
4245         (ix86_expand_vector_init_general): Likewise.
4246         (ix86_expand_vector_set): Likewise.
4247         (ix86_expand_vector_extract): Likewise.
4248         (emit_reduc_half): Likewise.
4249         (ix86_emit_i387_round): Likewise.
4250         (ix86_mangle_type): Likewise.
4251         (ix86_expand_round_sse4): Likewise.
4252         (expand_vec_perm_blend): Likewise.
4253         (canonicalize_vector_int_perm): Likewise.
4254         (ix86_expand_vec_one_operand_perm_avx512): Likewise.
4255         (expand_vec_perm_1): Likewise.
4256         (expand_vec_perm_interleave3): Likewise.
4257         (expand_vec_perm_even_odd_pack): Likewise.
4258         (expand_vec_perm_even_odd_1): Likewise.
4259         (expand_vec_perm_broadcast_1): Likewise.
4260         (ix86_vectorize_vec_perm_const_ok): Likewise.
4261         (ix86_expand_vecop_qihi): Likewise.
4262         (ix86_expand_mul_widen_hilo): Likewise.
4263         (ix86_expand_sse2_abs): Likewise.
4264         (ix86_expand_pextr): Likewise.
4265         (ix86_expand_pinsr): Likewise.
4266         (ix86_preferred_simd_mode): Likewise.
4267         (ix86_simd_clone_compute_vecsize_and_simdlen): Likewise.
4268         * config/i386/sse.md (*andnot<mode>3): Likewise.
4269         (<mask_codefor><code><mode>3<mask_name>): Likewise.
4270         (*<code><mode>3): Likewise.
4271         * config/ia64/ia64.c (ia64_expand_vecint_compare): Likewise.
4272         (ia64_expand_atomic_op): Likewise.
4273         (ia64_arg_type): Likewise.
4274         (ia64_mode_to_int): Likewise.
4275         (ia64_scalar_mode_supported_p): Likewise.
4276         (ia64_vector_mode_supported_p): Likewise.
4277         (expand_vec_perm_broadcast): Likewise.
4278         * config/iq2000/iq2000.c (iq2000_move_1word): Likewise.
4279         (iq2000_function_arg_advance): Likewise.
4280         (iq2000_function_arg): Likewise.
4281         * config/m32c/m32c.c (m32c_preferred_reload_class): Likewise.
4282         * config/m68k/m68k.c (output_dbcc_and_branch): Likewise.
4283         (m68k_libcall_value): Likewise.
4284         (m68k_function_value): Likewise.
4285         (sched_attr_op_type): Likewise.
4286         * config/mcore/mcore.c (mcore_output_move): Likewise.
4287         * config/microblaze/microblaze.c (microblaze_function_arg_advance):
4288         Likewise.
4289         (microblaze_function_arg): Likewise.
4290         * config/mips/mips.c (mips16_build_call_stub): Likewise.
4291         (mips_print_operand): Likewise.
4292         (mips_mode_ok_for_mov_fmt_p): Likewise.
4293         (mips_vector_mode_supported_p): Likewise.
4294         (mips_preferred_simd_mode): Likewise.
4295         (mips_expand_vpc_loongson_even_odd): Likewise.
4296         (mips_expand_vec_unpack): Likewise.
4297         (mips_expand_vi_broadcast): Likewise.
4298         (mips_expand_vector_init): Likewise.
4299         (mips_expand_vec_reduc): Likewise.
4300         (mips_expand_msa_cmp): Likewise.
4301         * config/mips/mips.md (casesi_internal_mips16_<mode>): Likewise.
4302         * config/mn10300/mn10300.c (mn10300_print_operand): Likewise.
4303         (cc_flags_for_mode): Likewise.
4304         * config/msp430/msp430.c (msp430_print_operand): Likewise.
4305         * config/nds32/nds32-md-auxiliary.c (nds32_mem_format): Likewise.
4306         (nds32_output_casesi_pc_relative): Likewise.
4307         * config/nds32/nds32.h (ASM_OUTPUT_ADDR_DIFF_ELT): Likewise.
4308         * config/nvptx/nvptx.c (nvptx_ptx_type_from_mode): Likewise.
4309         (nvptx_gen_unpack): Likewise.
4310         (nvptx_gen_pack): Likewise.
4311         (nvptx_gen_shuffle): Likewise.
4312         (nvptx_gen_wcast): Likewise.
4313         (nvptx_preferred_simd_mode): Likewise.
4314         * config/pa/pa.c (pa_secondary_reload): Likewise.
4315         * config/pa/predicates.md (base14_operand): Likewise.
4316         * config/powerpcspe/powerpcspe-c.c
4317         (altivec_resolve_overloaded_builtin): Likewise.
4318         * config/powerpcspe/powerpcspe.c (rs6000_setup_reg_addr_masks):
4319         Likewise.
4320         (rs6000_preferred_simd_mode): Likewise.
4321         (output_vec_const_move): Likewise.
4322         (rs6000_expand_vector_extract): Likewise.
4323         (rs6000_split_vec_extract_var): Likewise.
4324         (reg_offset_addressing_ok_p): Likewise.
4325         (rs6000_legitimate_offset_address_p): Likewise.
4326         (rs6000_legitimize_address): Likewise.
4327         (rs6000_emit_set_const): Likewise.
4328         (rs6000_const_vec): Likewise.
4329         (rs6000_emit_move): Likewise.
4330         (spe_build_register_parallel): Likewise.
4331         (rs6000_darwin64_record_arg_recurse): Likewise.
4332         (swap_selector_for_mode): Likewise.
4333         (spe_init_builtins): Likewise.
4334         (paired_init_builtins): Likewise.
4335         (altivec_init_builtins): Likewise.
4336         (do_load_for_compare): Likewise.
4337         (rs6000_generate_compare): Likewise.
4338         (rs6000_expand_float128_convert): Likewise.
4339         (emit_load_locked): Likewise.
4340         (emit_store_conditional): Likewise.
4341         (rs6000_output_function_epilogue): Likewise.
4342         (rs6000_handle_altivec_attribute): Likewise.
4343         (rs6000_function_value): Likewise.
4344         (emit_fusion_gpr_load): Likewise.
4345         (emit_fusion_p9_load): Likewise.
4346         (emit_fusion_p9_store): Likewise.
4347         * config/powerpcspe/predicates.md (easy_fp_constant): Likewise.
4348         (fusion_gpr_mem_load): Likewise.
4349         (fusion_addis_mem_combo_load): Likewise.
4350         (fusion_addis_mem_combo_store): Likewise.
4351         * config/rs6000/predicates.md (easy_fp_constant): Likewise.
4352         (fusion_gpr_mem_load): Likewise.
4353         (fusion_addis_mem_combo_load): Likewise.
4354         (fusion_addis_mem_combo_store): Likewise.
4355         * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin):
4356         Likewise.
4357         * config/rs6000/rs6000-string.c (do_load_for_compare): Likewise.
4358         * config/rs6000/rs6000.c (rs6000_setup_reg_addr_masks): Likewise.
4359         (rs6000_preferred_simd_mode): Likewise.
4360         (output_vec_const_move): Likewise.
4361         (rs6000_expand_vector_extract): Likewise.
4362         (rs6000_split_vec_extract_var): Likewise.
4363         (reg_offset_addressing_ok_p): Likewise.
4364         (rs6000_legitimate_offset_address_p): Likewise.
4365         (rs6000_legitimize_address): Likewise.
4366         (rs6000_emit_set_const): Likewise.
4367         (rs6000_const_vec): Likewise.
4368         (rs6000_emit_move): Likewise.
4369         (rs6000_darwin64_record_arg_recurse): Likewise.
4370         (swap_selector_for_mode): Likewise.
4371         (paired_init_builtins): Likewise.
4372         (altivec_init_builtins): Likewise.
4373         (rs6000_expand_float128_convert): Likewise.
4374         (emit_load_locked): Likewise.
4375         (emit_store_conditional): Likewise.
4376         (rs6000_output_function_epilogue): Likewise.
4377         (rs6000_handle_altivec_attribute): Likewise.
4378         (rs6000_function_value): Likewise.
4379         (emit_fusion_gpr_load): Likewise.
4380         (emit_fusion_p9_load): Likewise.
4381         (emit_fusion_p9_store): Likewise.
4382         * config/rx/rx.c (rx_gen_move_template): Likewise.
4383         (flags_from_mode): Likewise.
4384         * config/s390/predicates.md (s390_alc_comparison): Likewise.
4385         (s390_slb_comparison): Likewise.
4386         * config/s390/s390.c (s390_handle_vectorbool_attribute): Likewise.
4387         (s390_vector_mode_supported_p): Likewise.
4388         (s390_cc_modes_compatible): Likewise.
4389         (s390_match_ccmode_set): Likewise.
4390         (s390_canonicalize_comparison): Likewise.
4391         (s390_emit_compare_and_swap): Likewise.
4392         (s390_branch_condition_mask): Likewise.
4393         (s390_rtx_costs): Likewise.
4394         (s390_secondary_reload): Likewise.
4395         (__SECONDARY_RELOAD_CASE): Likewise.
4396         (s390_expand_cs): Likewise.
4397         (s390_preferred_simd_mode): Likewise.
4398         * config/s390/vx-builtins.md (vec_packsu_u<mode>): Likewise.
4399         * config/sh/sh.c (sh_print_operand): Likewise.
4400         (dump_table): Likewise.
4401         (sh_secondary_reload): Likewise.
4402         * config/sh/sh.h (ASM_OUTPUT_ADDR_DIFF_ELT): Likewise.
4403         * config/sh/sh.md (casesi_worker_1): Likewise.
4404         (casesi_worker_2): Likewise.
4405         * config/sparc/predicates.md (icc_comparison_operator): Likewise.
4406         (fcc_comparison_operator): Likewise.
4407         * config/sparc/sparc.c (sparc_expand_move): Likewise.
4408         (emit_soft_tfmode_cvt): Likewise.
4409         (sparc_preferred_simd_mode): Likewise.
4410         (output_cbranch): Likewise.
4411         (sparc_print_operand): Likewise.
4412         (sparc_expand_vec_perm_bmask): Likewise.
4413         (vector_init_bshuffle): Likewise.
4414         * config/spu/spu.c (spu_scalar_mode_supported_p): Likewise.
4415         (spu_vector_mode_supported_p): Likewise.
4416         (spu_expand_insv): Likewise.
4417         (spu_emit_branch_or_set): Likewise.
4418         (spu_handle_vector_attribute): Likewise.
4419         (spu_builtin_splats): Likewise.
4420         (spu_builtin_extract): Likewise.
4421         (spu_builtin_promote): Likewise.
4422         (spu_expand_sign_extend): Likewise.
4423         * config/tilegx/tilegx.c (tilegx_scalar_mode_supported_p): Likewise.
4424         (tilegx_simd_int): Likewise.
4425         * config/tilepro/tilepro.c (tilepro_scalar_mode_supported_p): Likewise.
4426         (tilepro_simd_int): Likewise.
4427         * config/v850/v850.c (const_double_split): Likewise.
4428         (v850_print_operand): Likewise.
4429         (ep_memory_offset): Likewise.
4430         * config/vax/vax.c (vax_rtx_costs): Likewise.
4431         (vax_output_int_move): Likewise.
4432         (vax_output_int_add): Likewise.
4433         (vax_output_int_subtract): Likewise.
4434         * config/visium/predicates.md (visium_branch_operator): Likewise.
4435         * config/visium/visium.c (rtx_ok_for_offset_p): Likewise.
4436         (visium_print_operand_address): Likewise.
4437         * config/visium/visium.h (ASM_OUTPUT_ADDR_DIFF_ELT): Likewise.
4438         * config/xtensa/xtensa.c (xtensa_mem_offset): Likewise.
4439         (xtensa_expand_conditional_branch): Likewise.
4440         (xtensa_copy_incoming_a7): Likewise.
4441         (xtensa_output_literal): Likewise.
4442         * dfp.c (decimal_real_maxval): Likewise.
4443         * targhooks.c (default_libgcc_floating_mode_supported_p): Likewise.
4445 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
4446             Alan Hayward  <alan.hayward@arm.com>
4447             David Sherwood  <david.sherwood@arm.com>
4449         * genmodes.c (mode_size_inline): Add an E_ prefix to mode names.
4450         (mode_nunits_inline): Likewise.
4451         (mode_inner_inline): Likewise.
4452         (mode_unit_size_inline): Likewise.
4453         (mode_unit_precision_inline): Likewise.
4454         (emit_insn_modes_h): Likewise.  Also emit a #define of the
4455         unprefixed name.
4456         (emit_mode_wider): Add an E_ prefix to mode names.
4457         (emit_mode_complex): Likewise.
4458         (emit_mode_inner): Likewise.
4459         (emit_mode_adjustments): Likewise.
4460         (emit_mode_int_n): Likewise.
4461         * config/aarch64/aarch64-builtins.c (v8qi_UP, v4hi_UP, v4hf_UP)
4462         (v2si_UP, v2sf_UP, v1df_UP, di_UP, df_UP, v16qi_UP, v8hi_UP, v8hf_UP)
4463         (v4si_UP, v4sf_UP, v2di_UP, v2df_UP, ti_UP, oi_UP, ci_UP, xi_UP)
4464         (si_UP, sf_UP, hi_UP, hf_UP, qi_UP): Likewise.
4465         (CRC32_BUILTIN, ENTRY): Likewise.
4466         * config/aarch64/aarch64.c (aarch64_push_regs): Likewise.
4467         (aarch64_pop_regs): Likewise.
4468         (aarch64_process_components): Likewise.
4469         * config/alpha/alpha.c (alpha_emit_conditional_move): Likewise.
4470         * config/arm/arm-builtins.c (v8qi_UP, v4hi_UP, v4hf_UP, v2si_UP)
4471         (v2sf_UP, di_UP, v16qi_UP, v8hi_UP, v8hf_UP, v4si_UP, v4sf_UP)
4472         (v2di_UP, ti_UP, ei_UP, oi_UP, hf_UP, si_UP, void_UP): Likewise.
4473         * config/arm/arm.c (arm_init_libfuncs): Likewise.
4474         * config/i386/i386-builtin-types.awk (ix86_builtin_type_vect_mode):
4475         Likewise.
4476         * config/i386/i386-builtin.def (pcmpestr): Likewise.
4477         (pcmpistr): Likewise.
4478         * config/microblaze/microblaze.c (double_memory_operand): Likewise.
4479         * config/mmix/mmix.c (mmix_output_condition): Likewise.
4480         * config/powerpcspe/powerpcspe.c (rs6000_init_hard_regno_mode_ok):
4481         Likewise.
4482         * config/rl78/rl78.c (mduc_regs): Likewise.
4483         * config/rs6000/rs6000.c (rs6000_init_hard_regno_mode_ok): Likewise.
4484         (htm_expand_builtin): Likewise.
4485         * config/sh/sh.h (REGISTER_NATURAL_MODE): Likewise.
4486         * config/sparc/sparc.c (emit_save_or_restore_regs): Likewise.
4487         * config/xtensa/xtensa.c (print_operand): Likewise.
4488         * expmed.h (NUM_MODE_PARTIAL_INT): Likewise.
4489         (NUM_MODE_VECTOR_INT): Likewise.
4490         * genoutput.c (null_operand): Likewise.
4491         (output_operand_data): Likewise.
4492         * genrecog.c (print_parameter_value): Likewise.
4493         * lra.c (debug_operand_data): Likewise.
4495 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
4497         * dwarf2out.c (scompare_loc_descriptor_wide)
4498         (scompare_loc_descriptor_narrow): New functions, split out from...
4499         (scompare_loc_descriptor): ...here.
4500         * expmed.c (emit_store_flag_int): New function, split out from...
4501         (emit_store_flag): ...here.
4503 2017-08-30  Richard Biener  <rguenther@suse.de>
4505         * dwarf2out.c (dwarf2out_finish): Remove setting AT_pubnames.
4506         (dwarf2out_early_finish): Move setting of AT_pubnames from
4507         early debug output to early finish.
4509 2017-08-30  Jozef Lawrynowicz  <jozef.l@somniumtech.com>
4511         * gcc/config/msp430/msp430.h: Pass -mcode/data-region to the linker
4512         and -mdata-region to the assembler.
4514 2017-08-30  Richard Biener  <rguenther@suse.de>
4516         * dwarf2out.c (add_dwarf_attr): Check we don't add duplicate
4517         attributes.
4518         (gen_subprogram_die): Add DW_AT_object_pointer only early.
4519         (dwarf2out_early_global_decl): Only generate a DIE for the
4520         abstract origin if it doesn't already exist or is a declaration DIE.
4521         (resolve_addr): Do not add the linkage name twice when
4522         generating a stub DIE for the DW_TAG_GNU_call_site target.
4524 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
4526         * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin):
4527         Use machine_mode rather than int for arg1_mode.
4529 2017-08-29  Michael Meissner  <meissner@linux.vnet.ibm.com>
4531         PR target/82015
4532         * config/rs6000/rs6000.c (rs6000_expand_binop_builtin): Insure
4533         that the second argument of the built-in functions to unpack
4534         128-bit scalar types to 64-bit values is 0 or 1.  Change to use a
4535         switch statement instead a lot of if statements.
4536         * config/rs6000/rs6000.md (unpack<mode>, FMOVE128_VSX iterator):
4537         Allow 64-bit values to be in Altivec registers as well as
4538         traditional floating point registers.
4539         (pack<mode>, FMOVE128_VSX iterator): Likewise.
4541 2017-08-29  Alexander Monakov  <amonakov@ispras.ru>
4543         * ira-costs.c (record_address_regs): Handle both operands of PLUS for
4544         MAX_REGS_PER_ADDRESS == 1.
4546 2017-08-29  Uros Bizjak  <ubizjak@gmail.com>
4548         * config/i386/i386.opt (flag_fentry): Do not init to -1.
4549         * config/i386/i386.c (ix86_option_override_internal): Simplify
4550         setting of opts->x_flag_entry.
4552 2017-08-29  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
4553             Jakub Jelinek  <jakub@redhat.com>
4554             Richard Biener  <rguenther@suse.de>
4556         PR tree-optimization/81503
4557         * gimple-ssa-strength-reduction.c (replace_mult_candidate): Ensure
4558         folded constant fits in the target type; reorder tests for clarity.
4560 2017-08-29  Martin Liska  <mliska@suse.cz>
4562         * passes.def: Include pass_lower_switch.
4563         * stmt.c (dump_case_nodes): Remove and move to
4564         tree-switch-conversion.
4565         (case_values_threshold): Likewise.
4566         (expand_switch_as_decision_tree_p): Likewise.
4567         (emit_case_decision_tree): Likewise.
4568         (expand_case): Likewise.
4569         (balance_case_nodes): Likewise.
4570         (node_has_low_bound): Likewise.
4571         (node_has_high_bound): Likewise.
4572         (node_is_bounded): Likewise.
4573         (emit_case_nodes): Likewise.
4574         (struct simple_case_node): New struct.
4575         (add_case_node): Remove.
4576         (emit_case_dispatch_table): Use vector instead of case_list.
4577         (reset_out_edges_aux): Remove.
4578         (compute_cases_per_edge): Likewise.
4579         (expand_case): Build list of simple_case_node.
4580         (expand_sjlj_dispatch_table): Use it.
4581         * tree-switch-conversion.c (struct case_node): Moved from
4582         stmt.c and adjusted.
4583         (emit_case_nodes): Likewise.
4584         (node_has_low_bound): Likewise.
4585         (node_has_high_bound): Likewise.
4586         (node_is_bounded): Likewise.
4587         (case_values_threshold): Likewise.
4588         (reset_out_edges_aux): Likewise.
4589         (compute_cases_per_edge): Likewise.
4590         (add_case_node): Likewise.
4591         (dump_case_nodes): Likewise.
4592         (balance_case_nodes): Likewise.
4593         (expand_switch_as_decision_tree_p): Likewise.
4594         (emit_jump): Likewise.
4595         (emit_case_decision_tree): Likewise.
4596         (try_switch_expansion): Likewise.
4597         (do_jump_if_equal): Likewise.
4598         (emit_cmp_and_jump_insns): Likewise.
4599         (fix_phi_operands_for_edge): New function.
4600         (record_phi_operand_mapping): Likewise.
4601         (class pass_lower_switch): New pass.
4602         (pass_lower_switch::execute): New function.
4603         (make_pass_lower_switch): Likewise.
4604         (conditional_probability):
4605         * timevar.def: Add TV_TREE_SWITCH_LOWERING.
4606         * tree-pass.h: Add make_pass_lower_switch.
4608 2017-08-29  Jozef Lawrynowicz  <jozef.l@somniumtech.com>
4610         PR target/80993
4611         * gcc/config/msp430/msp430.c (msp430_attr): Mark interrupt
4612         handlers as used.
4614 2017-08-29  Richard Biener  <rguenther@suse.de>
4616         * dwarf2out.c (add_dwarf_attr): When checking is enabled verify
4617         we do not add a DW_AT_inline attribute twice.
4618         (gen_subprogram_die): Remove code setting DW_AT_inline on
4619         DECL_ABSTRACT_P nodes.
4621 2017-08-29  Richard Sandiford  <richard.sandiford@linaro.org>
4623         * gimplify.c (gimplify_call_expr): Copy the nothrow flag to
4624         calls to internal functions.
4625         (gimplify_modify_expr): Likewise.
4626         * tree-call-cdce.c (use_internal_fn): Likewise.
4627         * tree-ssa-math-opts.c (pass_cse_reciprocals::execute): Likewise.
4628         (convert_to_divmod): Set the nothrow flag.
4629         * tree-if-conv.c (predicate_mem_writes):  Likewise.
4630         * tree-vect-stmts.c (vectorizable_mask_load_store): Likewise.
4631         (vectorizable_call): Likewise.
4632         (vectorizable_store): Likewise.
4633         (vectorizable_load): Likewise.
4634         * tree-vect-patterns.c (vect_recog_pow_pattern): Likewise.
4635         (vect_recog_mask_conversion_pattern): Likewise.
4637 2017-08-29  Martin Liska  <mliska@suse.cz>
4639         PR other/39851
4640         * gcc.c (driver_handle_option): Add new argument.
4641         * opts-common.c (handle_option): Pass
4642         target_option_override_hook.
4643         * opts-global.c (lang_handle_option): Add new option.
4644         (set_default_handlers):  Add new argument.
4645         (decode_options): Likewise.
4646         * opts.c (target_handle_option): Likewise.
4647         (common_handle_option): Call target_option_override_hook.
4648         * opts.h (struct cl_option_handler_func): Add hook for
4649         target option override.
4650         (struct cl_option_handlers): Likewise.
4651         (set_default_handlers): Add new argument.
4652         (decode_options): Likewise.
4653         (common_handle_option): Likewise.
4654         (target_handle_option): Likewise.
4655         * toplev.c (toplev::main): Pass targetm.target_option.override
4656         hook.
4658 2017-08-29  Richard Biener  <rguenther@suse.de>
4659         Dominik Infuehr <dominik.infuehr@theobroma-systems.com>
4661         * tree-vect-slp.c (vect_bb_slp_scalar_cost): Properly confine
4662         life to the active subtree.
4664 2017-08-28  Jeff Law  <law@redhat.com>
4666         * tree-ssa-dom.c (edge_info::record_simple_equiv): Call
4667         derive_equivalences.
4668         (derive_equivalences_from_bit_ior, record_temporary_equivalences):
4669         Code moved into....
4670         (edge_info::derive_equivalences): New private member function
4672         * tree-ssa-dom.c (class edge_info): Changed from a struct
4673         to a class.  Add ctor/dtor, methods and data members.
4674         (edge_info::edge_info): Renamed from allocate_edge_info.
4675         Initialize additional members.
4676         (edge_info::~edge_info): New.
4677         (free_dom_edge_info): Delete the edge info.
4678         (record_edge_info): Use new class & associated member functions.
4679         Tighten forms for testing for edge equivalences.
4680         (record_temporary_equivalences): Iterate over the simple
4681         equivalences rather than assuming there's only one per edge.
4682         (cprop_into_successor_phis): Iterate over the simple
4683         equivalences rather than assuming there's only one per edge.
4684         (optimize_stmt): Use operand_equal_p rather than pointer
4685         equality for mini-DSE code.
4687 2017-08-28  Nathan Sidwell  <nathan@acm.org>
4689         * gcc.c (execute): Fold SIGPIPE handling into switch
4690         statement.  Adjust internal error message.
4692 2017-08-28  Richard Biener  <rguenther@suse.de>
4694         PR debug/81993
4695         * dwarf2out.c (gen_remaining_tmpl_value_param_die_attributes):
4696         Do nothing for removed DIEs.
4698 2017-08-28  Richard Biener  <rguenther@suse.de>
4700         PR tree-optimization/81977
4701         * tree-ssa-sccvn.c (vn_reference_lookup_3): Fix look through
4702         memcpy.
4704 2017-08-28  Alexander Monakov  <amonakov@ispras.ru>
4706         PR target/80640
4707         * doc/md.texi (mem_thread_fence): Remove mention of mode.  Rewrite.
4708         * optabs.c (expand_mem_thread_fence): Emit a compiler barrier when
4709         using targetm.gen_mem_thread_fence.
4711 2017-08-27  Uros Bizjak  <ubizjak@gmail.com>
4713         PR target/81995
4714         * config/i386/i386.md (*<btsc><mode>): Change operand 2
4715         predicate to register_operand.  Reorder operands.
4716         (*btr<mode>): Ditto.
4717         (*<btsc><mode>_mask): Change operand 3 predicate to register_operand.
4718         (*btr<mode>_mask): Ditto.
4720 2017-08-25  Steven Munroe  <munroesj@gcc.gnu.org>
4722         * config.gcc (powerpc*-*-*): Add xmmintrin.h and mm_malloc.h.
4723         * config/rs6000/xmmintrin.h: New file.
4724         * config/rs6000/x86intrin.h [__ALTIVEC__]: Include xmmintrin.h.
4726 2017-08-25  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
4728         PR target/81504
4729         * config/rs6000/rs6000-p8swap.c (find_alignment_op): Add reference
4730         parameter and_insn and return it.
4731         (recombine_lvx_pattern): Insert a copy to ensure availability of
4732         the base register of the copied masking operation at the point of
4733         the instruction replacement.
4734         (recombine_stvx_pattern): Likewise.
4736 2017-08-25  Michael Meissner  <meissner@linux.vnet.ibm.com>
4738         * config/rs6000/rs6000.opt (-mpower9-dform-scalar): Delete
4739         undocumented switches.
4740         (-mpower9-dform-vector): Likewise.
4741         (-mpower9-dform): Likewise.
4742         * config/rs6000/rs6000-c.c (rs6000_target_modify_macros): Update
4743         comments to delete references to -mpower9-dform* switches.
4744         * config/rs6000/predicates.md (vsx_quad_dform_memory_operand):
4745         Delete reference to -mpower9-dform* switches, test for
4746         -mpower9-vector instead.
4747         * config/rs6000/rs6000-cpus.def (ISA_3_0_MASKS_SERVER): Likewise.
4748         (OTHER_P9_VECTOR_MASKS): Likewise.
4749         (POWERPC_MASKS): Likewise.
4750         * config/rs6000/rs6000.c (rs6000_setup_reg_addr_masks): Change
4751         tests against -mpower9-dform* to -mpower9-vector.  Delete code
4752         that checked for -mpower9-dform* consistancy with other options.
4753         Add test for -mpower9-misc to enable other power9 switches.
4754         (rs6000_init_hard_regno_mode_ok): Likewise.
4755         (rs6000_option_override_internal): Likewise.
4756         (rs6000_emit_prologue): Likewise.
4757         (rs6000_emit_epilogue): Likewise.
4758         (rs6000_opt_masks): Delete -mpower9-dform-{scalar,vector}.
4759         (rs6000_disable_incompatiable_switches): Delete -mpower9-dform.
4760         (emit_fusion_p9_load): Change tests for -mpower9-dform-scalar
4761         -mpower9-vector.
4762         (emit_fusion_p9_store): Likewise.
4763         * config/rs6000/rs6000.h (TARGET_P9_DFORM_SCALAR): Delete
4764         resetting these macros if the assembler does not support ISA 3.0
4765         instructions.
4766         (TARGET_P9_DFORM_VECTOR): Likewise.
4767         * config/rs6000/rs6000.md (peepholes to optimize altivec memory):
4768         Change to use -mpower9-vector instead of -mpower9-dform-scalar.
4770 2017-08-25  Alan Modra  <amodra@gmail.com>
4772         PR rtl-optimization/81747
4773         * cse.c (cse_extended_basic_block): Don't attempt to record
4774         equivalences for degenerate conditional branches that branch
4775         to their fall-through.
4777 2017-08-24  Martin Sebor  <msebor@redhat.com>
4779         PR middle-end/81908
4780         * gimple-fold.c (size_must_be_zero_p): New function.
4781         (gimple_fold_builtin_memory_op): Call it.
4783 2017-08-24  Steven Munroe  <munroesj@gcc.gnu.org>
4785         * config/rs6000/mm_malloc.h: New file.
4787 2017-08-24  Bin Cheng  <bin.cheng@arm.com>
4789         PR tree-optimization/81913
4790         * tree-ssa-loop-niter.c (number_of_iterations_cond): Skip niter
4791         analysis when either IVs in condition can wrap.
4793 2017-08-24  Uros Bizjak  <ubizjak@gmail.com>
4795         * dwarf2out.c (MAX_ARTIFICIAL_LABEL_BYTES): Increase to 40.
4796         * dwarf2cfi.c (MAX_ARTIFICIAL_LABEL_BYTES): Remove.
4798 2017-08-24  Richard Biener  <rguenther@suse.de>
4800         PR target/81921
4801         * targhooks.c (default_target_can_inline_p): Properly
4802         use target_option_default_node when no DECL_FUNCTION_SPECIFIC_TARGET
4803         is present and always compare.
4804         * config/i386/i386.c (ix86_valid_target_attribute_tree): Do not
4805         infer -mfpmath=sse from TARGET_SSE_P.
4806         (ix86_can_inline_p): Properly use target_option_default_node when
4807         no DECL_FUNCTION_SPECIFIC_TARGET is present and always compare.
4809 2017-08-24  Richard Biener  <rguenther@suse.de>
4811         PR debug/81936
4812         * dwarf2out.c (output_die): Handle flag_generate_offload like
4813         flag_generate_lto.
4814         (output_comp_unit): Likewise.
4815         (gen_array_type_die): Likewise.
4816         (dwarf2out_early_finish): Likewise.
4817         (note_variable_value_in_expr): Likewise.
4818         (dwarf2out_finish): Likewise.  Adjust assert.
4819         * cgraphunit.c (symbol_table::compile): Move setting of
4820         flag_generate_offload earlier ...
4821         (symbol_table::finalize_compilation_unit): ... here, before
4822         early debug finalization.
4824 2017-08-24  Richard Biener  <rguenther@suse.de>
4826         * config/i386/i386.c: Include symbol-summary.h, ipa-prop.h
4827         and ipa-fnsummary.h.
4828         (ix86_can_inline_p): When ix86_fpmath flags do not match
4829         check whether the callee uses FP math at all.
4831 2017-08-24  Aldy Hernandez  <aldyh@redhat.com>
4833         PR middle-end/81931
4834         * tree-ssanames.c (get_nonzero_bits): Use element_precision
4835         instead of TYPE_PRECISION.
4837 2017-08-24  Richard Sandiford  <richard.sandiford@linaro.org>
4838             Alan Hayward  <alan.hayward@arm.com>
4839             David Sherwood  <david.sherwood@arm.com>
4841         * combine.c (make_extraction): Use subreg_offset_from_lsb.
4843 2017-08-23  Daniel Santos  <daniel.santos@pobox.com>
4845         * config/i386/i386.h (ix86_frame::stack_realign_allocate_offset):
4846         Remove field.
4847         (ix86_frame::stack_realign_allocate): New field.
4848         (struct machine_frame_state): Modify comments.
4849         (machine_frame_state::sp_realigned_fp_end): New field.
4850         * config/i386/i386.c (ix86_compute_frame_layout): Rework stack frame
4851         layout calculation.
4852         (sp_valid_at): Add assertion to assure no attempt to access invalid
4853         offset of a realigned stack.
4854         (fp_valid_at): Likewise.
4855         (choose_baseaddr): Modify comments.
4856         (ix86_emit_outlined_ms2sysv_save): Adjust to changes in
4857         ix86_expand_prologue.
4858         (ix86_expand_prologue): Modify stack realignment and allocation.
4859         (ix86_expand_epilogue): Modify comments.
4860         * doc/sourcebuild.texi: Add documentation for target selectors avx2,
4861         avx2_runtime, avx512f, and avx512f_runtime.
4863 2017-08-23  Uros Bizjak  <ubizjak@gmail.com>
4865         * config/i386/i386.opt: Remove unneeded Init(0) initializations.
4866         (mstackrealign): Do not init to -1.
4867         * config/i386/i386.c (ix86_option_override_internal):
4868         Check opts_set, not opts when setting default value of
4869         opts->x_ix86_force_align_arg_pointer.
4871 2017-08-23  Richard Biener  <rguenther@suse.de>
4873         * function.c (fndecl_name): Use verbosity 1 (no arguments) for
4874         lang_hooks.decl_printable_name.
4875         * print-rtl-function.c (print_rtx_function): Likewise.
4876         * tree-pretty-print.c (dump_function_header): Likewise.
4878 2017-08-23  Richard Biener  <rguenther@suse.de>
4880         PR lto/81940
4881         * dwarf2out.c (dwarf2out_abstract_function): Handle LTO with
4882         -g0 at compile-time.
4884 2017-08-23  Tamar Christina  <tamar.christina@arm.com>
4886         PR middle-end/19706
4887         * doc/sourcebuild.texi (Other hardware attributes):
4888         Document xorsign.
4890 2017-08-23  Tamar Christina  <tamar.christina@arm.com>
4892         PR middle-end/19706
4893         * tree-ssa-math-opts.c (convert_expand_mult_copysign):
4894         Fix single-use check.
4896 2017-08-23  Thomas Preud'homme  <thomas.preudhomme@arm.com>
4898         * gcc.c (execute): Only test for SIGKILL and SIGQUIT if available.
4900 2017-08-22  Daniel Santos  <daniel.santos@pobox.com>
4902         * doc/install.texi: Modify to add more details on running selected
4903         tests.
4905 2017-08-22  Daniel Santos  <daniel.santos@pobox.com>
4907         * config/i386/i386.c (ix86_option_override_internal): Error when -mx32
4908         is combined with -mabi=ms.
4909         (ix86_function_type_abi): Limit errors for mixing -mx32 with attribute
4910         ms_abi.
4912 2017-08-22  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
4914         PR tree-optimization/81488
4915         * gimple-ssa-strength-reduction (struct slsr_cand_d): Add visited
4916         and cached_basis fields.
4917         (MAX_SPREAD): New constant.
4918         (alloc_cand_and_find_basis): Initialize new fields.
4919         (clear_visited): New function.
4920         (create_phi_basis_1): Rename from create_phi_basis, set visited
4921         and cached_basis fields.
4922         (create_phi_basis): New wrapper function.
4923         (phi_add_costs_1): Rename from phi_add_costs, add spread
4924         parameter, set visited field, short-circuit when limits reached.
4925         (phi_add_costs): New wrapper function.
4926         (record_phi_increments_1): Rename from record_phi_increments, set
4927         visited field.
4928         (record_phi_increments): New wrapper function.
4929         (phi_incr_cost_1): Rename from phi_incr_cost, set visited field.
4930         (phi_incr_cost): New wrapper function.
4931         (all_phi_incrs_profitable_1): Rename from
4932         all_phi_incrs_profitable, set visited field.
4933         (all_phi_incrs_profitable): New wrapper function.
4935 2017-08-22  Richard Sandiford  <richard.sandiford@linaro.org>
4936             Alan Hayward  <alan.hayward@arm.com>
4937             David Sherwood  <david.sherwood@arm.com>
4939         * rtl.h (paradoxical_subreg_p): Define inline, and add a version
4940         that takes the outer and inner modes.
4941         * doc/rtl.texi: Use paradoxical_subreg_p instead of a GET_MODE_SIZE
4942         comparison as the canonical test for a paradoxical subreg.
4943         * combine.c (simplify_set): Use paradoxical_subreg_p.
4944         (make_extraction): Likewise.
4945         (force_to_mode): Likewise.
4946         (rtx_equal_for_field_assignment_p): Likewise.
4947         (gen_lowpart_for_combine): Likewise.
4948         (simplify_comparison): Likewise.
4949         * cse.c (equiv_constant): Likewise.
4950         * expmed.c (store_bit_field_1): Likewise.
4951         * final.c (alter_subreg): Likewise.
4952         * fwprop.c (propagate_rtx): Likewise.
4953         (forward_propagate_subreg): Likewise.
4954         * ira-conflicts.c (ira_build_conflicts): Likewise.
4955         * lower-subreg.c (simplify_gen_subreg_concatn): Likewise.
4956         * lra-constraints.c (curr_insn_transform): Likewise.
4957         (split_reg): Likewise.
4958         * lra-eliminations.c (move_plus_up): Likewise.
4959         (lra_eliminate_regs_1): Likewise.
4960         * recog.c (general_operand): Likewise.
4961         * ree.c (combine_reaching_defs): Likewise.
4962         * reload.c (push_reload): Likewise.
4963         (find_reloads): Likewise.
4964         * reload1.c (elimination_effects): Likewise.
4965         (compute_reload_subreg_offset): Likewise.
4966         (choose_reload_regs): Likewise.
4967         * rtlanal.c (subreg_lsb_1): Likewise.
4968         * simplify-rtx.c (simplify_unary_operation_1): Likewise.
4969         (simplify_subreg): Likewise.
4970         * var-tracking.c (track_loc_p): Likewise.
4971         * emit-rtl.c (byte_lowpart_offset): Likewise.
4972         (paradoxical_subreg_p): Delete out-of-line definition.
4974 2017-08-22  Jeff Law  <law@redhat.com>
4976         PR tree-optimization/81741
4977         PR tree-optimization/71947
4978         * tree-ssa-dom.c: Include tree-inline.h.
4979         (record_temporary_equivalences): Only record SSA_NAME = SSA_NAME
4980         equivalences if one is more expensive to compute than the other.
4981         * tree-ssa-scopedtables.h (class const_or_copies): Make
4982         record_const_or_copy_raw method private.
4983         (class avail_exprs_stack): New method simplify_binary_operation.
4984         * tree-ssa-scopedtables.c (avail_exprs_stack::lookup_avail_expr): Call
4985         avail_exprs_stack::simplify_binary_operation as needed.
4986         (avail_exprs_stack::simplify_binary_operation): New function.
4988 2017-08-22  Sebastian Huber  <sebastian.huber@embedded-brains.de>
4990         * config.gcc (powerpc-*-rtems*): Add rs6000/linux64.opt.
4991         * config/rs6000/rtems.h (ASM_PREFERRED_EH_DATA_FORMAT): New define.
4992         (DOT_SYMBOLS): Likewise.
4993         (MINIMAL_TOC_SECTION_ASM_OP): Likewise.
4994         (RELOCATABLE_NEEDS_FIXUP): Likewise.
4995         (RS6000_ABI_NAME): Likewise.
4996         (TARGET_CMODEL): Likewise.
4997         (TOC_SECTION_ASM_OP): Likewise.
4998         (SET_CMODEL): New macro.
4999         (SUBSUBTARGET_OVERRIDE_OPTIONS): Evaluate cmodel options.
5001 2017-08-22  Richard Biener  <rguenther@suse.de>
5003         * tree-inline.c (remap_type_1): Change asserts on TYPE_SIZE[_UNIT]
5004         to allow for free-lang-data replacements similar to verify_type_variant.
5006 2017-08-22  Richard Sandiford  <richard.sandiford@linaro.org>
5007             Alan Hayward  <alan.hayward@arm.com>
5008             David Sherwood  <david.sherwood@arm.com>
5010         * config/aarch64/aarch64.md (casesi): Use DImode rather than
5011         VOIDmode for the LABEL_REF.
5013 2017-08-22  Richard Biener  <rguenther@suse.de>
5015         * tree-cfg.c (gimple_split_edge): Avoid reallocating target PHI nodes.
5017 2017-08-22  Richard Biener  <rguenther@suse.de>
5019         * common.opt (feliminate-dwarf2-dups): Ignore.
5020         * doc/invoke.texi (feliminate-dwarf2-dups): Remove documentation.
5021         * dwarf2out.c (push_new_compile_unit, pop_compile_unit,
5022         same_die_p_wrap, compute_section_prefix,
5023         is_symbol_die, assign_symbol_names, break_out_includes): Remove.
5024         (comdat_symbol_id, comdat_symbol_number): Likewise.
5025         (cu_hash_table_entry, cu_hash_table_entry_hasher, cu_hash_type):
5026         Likewise.
5027         (check_duplicate_cu, record_comdat_symbol_number): Likewise.
5028         (output_die): Mark unreachable path unreachable.
5029         (dwarf2out_start_source_file): Do not create DW_TAG_GNU_BINCL.
5030         (dwarf2out_end_source_file): Do not create DW_TAG_GNU_EINCL.
5031         (dwarf2out_init): Remove code handling flag_eliminate_dwarf2_dups.
5032         (dwarf2out_early_finish): Likewise.
5034 2017-08-22  Aldy Hernandez  <aldyh@redhat.com>
5036         * wide-int.h (hwi_with_prec::hwi_with_prec): Sign extend.
5038 2017-08-22  Georg-Johann Lay  <avr@gjlay.de>
5040         PR target/81910
5041         * config/avr/avr.c (avr_handle_addr_attribute): Early return if
5042         not VAR_P. Filter attribute warnings with OPT_Wattributes.
5043         (avr_attribute_table) <io, io_low, address>: Initialize
5044         .decl_required with true.
5046 2017-08-21  Michael Meissner  <meissner@linux.vnet.ibm.com>
5048         * config/rs6000/rs6000-cpus.def (-mvsx-scalar-float): Delete
5049         undocumented debugging options.
5050         (-mvsx-scalar-double): Likewise.
5051         (-mallow-df-permute): Likewise.
5052         (-mvectorize-builtins): Likewise.
5053         * config/rs6000/rs6000.c (rs6000_init_hard_regno_mode_ok): Likewise.
5054         (rs6000_builtin_vectorized_function): Likewise.
5055         (rs6000_builtin_md_vectorized_function): Likewise.
5056         (rs6000_opt_vars): Likewise.
5058 2017-08-21  Uros Bizjak  <ubizjak@gmail.com>
5060         PR target/46091
5061         * config/i386/i386.md (*btsq_imm): Rename from *btsq.
5062         (*btrq_imm): Rename from *btrq.
5063         (*btcq_imm): Rename from *btcq.
5064         (btsc): New code attribute.
5065         (*<btsc><mode>): New insn pattern.
5066         (*btr<mode>): Ditto.
5067         (*<btsc><mode>_mask): New insn_and_split pattern.
5068         (*btr<mode>_mask): Ditto.
5070 2017-08-21  Richard Sandiford  <richard.sandiford@linaro.org>
5071             Alan Hayward  <alan.hayward@arm.com>
5072             David Sherwood  <david.sherwood@arm.com>
5074         * function.c (pad_below): Simplify padding calculation.
5076 2017-08-21  Richard Sandiford  <richard.sandiford@linaro.org>
5077             Alan Hayward  <alan.hayward@arm.com>
5078             David Sherwood  <david.sherwood@arm.com>
5080         * target.def (function_prologue): Remove frame size argument.
5081         (function_epilogue): Likewise.
5082         * doc/tm.texi: Regenerate.
5083         * final.c (final_start_function): Update call to function_prologue.
5084         (final_end_function): Update call to function_epilogue.
5085         (default_function_pro_epilogue): Remove frame size argument.
5086         * output.h (default_function_pro_epilogue): Likewise.
5087         * config/arm/arm.c (arm_output_function_epilogue): Likewise.
5088         (arm_output_function_prologue): Likewise.
5089         * config/frv/frv.c (frv_function_prologue): Likewise.
5090         (frv_function_epilogue): Likewise.
5091         * config/i386/i386.c (ix86_output_function_epilogue): Likewise.
5092         * config/ia64/ia64.c (ia64_output_function_prologue): Likewise.
5093         (ia64_output_function_epilogue): Likewise.
5094         * config/m32r/m32r.c (m32r_output_function_prologue): Likewise.
5095         (m32r_output_function_epilogue): Likewise.
5096         * config/microblaze/microblaze.c (microblaze_function_prologue)
5097         (microblaze_function_epilogue): Likewise.
5098         * config/mips/mips.c (mips_output_function_prologue): Likewise.
5099         (mips_output_function_epilogue): Likewise.
5100         * config/mmix/mmix.c (mmix_target_asm_function_prologue): Likewise.
5101         (mmix_target_asm_function_epilogue): Likewise.
5102         * config/msp430/msp430.c (msp430_start_function): Likewise.
5103         * config/nds32/nds32.c (nds32_asm_function_prologue): Likewise.
5104         (nds32_asm_function_epilogue): Likewise.
5105         * config/nios2/nios2.c (nios2_asm_function_prologue): Likewise.
5106         * config/pa/pa.c (pa_output_function_prologue): Likewise.
5107         (pa_output_function_epilogue): Likewise.
5108         * config/powerpcspe/powerpcspe.c (rs6000_output_function_prologue)
5109         (rs6000_output_function_epilogue): Likewise.
5110         * config/rl78/rl78.c (rl78_start_function): Likewise.
5111         * config/rs6000/rs6000.c (rs6000_output_function_prologue): Likewise.
5112         (rs6000_output_function_epilogue): Likewise.
5113         * config/rx/rx.c (rx_output_function_prologue): Likewise.
5114         * config/sh/sh.c (sh_output_function_epilogue): Likewise.
5115         * config/sparc/sparc.c (sparc_asm_function_prologue): Likewise.
5116         (sparc_asm_function_epilogue): Likewise.
5118 2017-08-21  Richard Sandiford  <richard.sandiford@linaro.org>
5120         * tree.h (type_has_mode_precision_p): New function.
5121         * convert.c (convert_to_integer_1): Use it.
5122         * expr.c (expand_expr_real_2): Likewise.
5123         (expand_expr_real_1): Likewise.
5124         * fold-const.c (fold_single_bit_test_into_sign_test): Likewise.
5125         * match.pd: Likewise.
5126         * tree-ssa-forwprop.c (simplify_rotate): Likewise.
5127         * tree-ssa-math-opts.c (convert_mult_to_fma): Likewise.
5128         * tree-tailcall.c (process_assignment): Likewise.
5129         * tree-vect-loop.c (vectorizable_reduction): Likewise.
5130         * tree-vect-patterns.c (vect_recog_vector_vector_shift_pattern)
5131         (vect_recog_mult_pattern, vect_recog_divmod_pattern): Likewise.
5132         * tree-vect-stmts.c (vectorizable_conversion): Likewise.
5133         (vectorizable_assignment): Likewise.
5134         (vectorizable_shift): Likewise.
5135         (vectorizable_operation): Likewise.
5136         * tree-vrp.c (register_edge_assert_for_2): Likewise.
5138 2017-08-21  Wilco Dijkstra  <wdijkstr@arm.com>
5140         * match.pd: Add pow (C, x) simplification.
5142 2017-08-21  Richard Biener  <rguenther@suse.de>
5144         PR tree-optimization/81900
5145         * tree-ssa-pre.c (compute_antic_aux): Properly compute changed
5146         for blocks with abnormal predecessors.
5147         (compute_antic): Do not set visited flag prematurely.
5149 2017-08-21  Georg-Johann Lay  <avr@gjlay.de>
5151         PR target/79883
5152         * config/avr/avr.c (avr_set_current_function): Typo in diagnostic.
5154 2017-08-21  Richard Sandiford  <richard.sandiford@linaro.org>
5156         * stor-layout.h (vector_type_mode): Move to...
5157         * tree.h (vector_type_mode): ...here.
5158         * stor-layout.c (vector_type_mode): Move to...
5159         * tree.c (vector_type_mode): ...here.  Include rtl.h and regs.h.
5161 2017-08-21  Richard Biener  <rguenther@suse.de>
5163         * debug.h (struct gcc_debug_hooks): Add die_ref_for_decl and
5164         register_external_die hooks.
5165         (debug_false_tree_charstarstar_uhwistar): Declare.
5166         (debug_nothing_tree_charstar_uhwi): Likewise.
5167         * debug.c (do_nothing_debug_hooks): Adjust.
5168         (debug_false_tree_charstarstar_uhwistar): New do nothing.
5169         (debug_nothing_tree_charstar_uhwi): Likewise.
5170         * dbxout.c (dbx_debug_hooks): Adjust.
5171         (xcoff_debug_hooks): Likewise.
5172         * sdbout.c (sdb_debug_hooks): Likewise.
5173         * vmsdbgout.c (vmsdbg_debug_hooks): Likewise.
5174         * dwarf2out.c (macinfo_label_base): New global.
5175         (dwarf2out_register_external_die): New function for the
5176         register_external_die hook.
5177         (dwarf2out_die_ref_for_decl): Likewise for die_ref_for_decl.
5178         (dwarf2_debug_hooks): Use them.
5179         (dwarf2_lineno_debug_hooks): Adjust.
5180         (struct die_struct): Add with_offset flag.
5181         (DEBUG_LTO_DWO_INFO_SECTION, DEBUG_LTO_INFO_SECTION,
5182         DEBUG_LTO_DWO_ABBREV_SECTION, DEBUG_LTO_ABBREV_SECTION,
5183         DEBUG_LTO_DWO_MACINFO_SECTION, DEBUG_LTO_MACINFO_SECTION,
5184         DEBUG_LTO_DWO_MACRO_SECTION, DEBUG_LTO_MACRO_SECTION,
5185         DEBUG_LTO_LINE_SECTION, DEBUG_LTO_DWO_STR_OFFSETS_SECTION,
5186         DEBUG_LTO_STR_DWO_SECTION, DEBUG_STR_LTO_SECTION): New macros
5187         defining section names for the early LTO debug variants.
5188         (reset_indirect_string): New helper.
5189         (add_AT_external_die_ref): Helper for dwarf2out_register_external_die.
5190         (print_dw_val): Add support for offsetted symbol references.
5191         (get_ultimate_context): Split out from is_cxx.
5192         (is_cxx): Use get_ultimate_context.
5193         (is_fortran): Add decl overload.
5194         (compute_comp_unit_symbol): Split out worker from
5195         compute_section_prefix.
5196         (compute_section_prefix): Call compute_comp_unit_symbol and
5197         set comdat_type_p here.
5198         (output_die): Skip DIE symbol output for the LTO added one.
5199         Handle DIE symbol references with offset.
5200         (output_comp_unit): Guard section name mangling properly.
5201         For LTO debug sections emit a symbol at the section beginning
5202         which we use to refer to its DIEs.
5203         (add_abstract_origin_attribute): For DIEs registered via
5204         dwarf2out_register_external_die directly refer to the early
5205         DIE rather than indirectly through the shadow one we created.
5206         Remove obsolete call to dwarf2out_abstract_function for
5207         non-function/block origins.
5208         (gen_array_type_die): When generating early LTO debug do
5209         not emit DW_AT_string_length.
5210         (gen_formal_parameter_die): Do not re-create DIEs for PARM_DECLs
5211         late when in LTO.  As suggested place a gcc_unreachable for
5212         the DECL_ABSTRACT_P case.
5213         (gen_subprogram_die): Avoid another specification DIE
5214         for early built declarations/definitions for the late LTO case.
5215         (gen_variable_die): Add type references for late duplicated VLA dies
5216         when in late LTO.
5217         (gen_inlined_subroutine_die): Do not call dwarf2out_abstract_function,
5218         we have the abstract instance already.
5219         (process_scope_var): Adjust decl DIE contexts in LTO which
5220         first puts them in limbo.
5221         (gen_decl_die): Do not generate type DIEs late apart from
5222         types for VLAs or for decls we do not yet have a DIE.  Do not
5223         call dwarf2out_abstract_function late.
5224         (dwarf2out_early_global_decl): Make sure to create DIEs
5225         for abstract instances of a decl first.
5226         (dwarf2out_late_global_decl): Adjust comment.
5227         (output_macinfo_op): With multiple macro sections use
5228         macinfo_label_base to distinguish labels.
5229         (output_macinfo): Likewise.  Update macinfo_label_base.
5230         Pass in the line info label.
5231         (note_variable_value_in_expr): When generating LTO resolve
5232         all variable values here by generating DIEs as needed.
5233         (init_sections_and_labels): Add early LTO debug flag parameter
5234         and generate different sections and names if set.  Add generation
5235         counter for the labels so we can have multiple of them.
5236         (reset_dies): Helper to allow DIEs to be output multiple times.
5237         (dwarf2out_finish): When outputting DIEs to the fat part of an
5238         LTO object first reset DIEs.
5239         (dwarf2out_early_finish): Output early DIEs when generating LTO.
5240         (modified_type_die): Check for decl_ultimate_origin being self
5241         before recursing.
5242         (gen_type_die_with_usage): Likewise.
5243         (gen_typedef_die): Allow decl_ultimate_origin being self.
5244         (set_decl_abstract_flags): Remove.
5245         (set_block_abstract_flags): Likewise.
5246         (dwarf2out_abstract_function): Treat the early generated DIEs
5247         as the abstract copy and only add DW_AT_inline and
5248         DW_AT_artificial here and call set_decl_origin_self.
5249         If the DIE has an abstract origin don't do anything.
5250         * tree.c (free_lang_data): Build a dummy TRANSLATION_UNIT_DECL
5251         if we have none yet (Go fails to build one, PR78628).
5252         (variably_modified_type_p): Prevent endless recursion for Ada
5253         cyclic pointer types.
5254         * lto-streamer-in.c: Include debug.h.
5255         (dref_queue): New global.
5256         (lto_read_tree_1): Stream in DIE references.
5257         (lto_input_tree): Register DIE references.
5258         (input_function): Stream DECL_DEBUG_ARGS.
5259         * lto-streamer-out.c: Include debug.h.
5260         (lto_write_tree_1): Output DIE references.
5261         (DFS::DFS_write_tree_body): Follow DECL_ABSTRACT_ORIGIN.
5262         Force a TRANSLATION_UNIT_DECL DECL_CONTEXT for file-scope decls.
5263         (output_function): Stream DECL_DEBUG_ARGS.
5264         * tree-streamer-in.c (lto_input_ts_decl_common_tree_pointers):
5265         Stream DECL_ABSTRACT_ORIGIN.
5266         * tree-streamer-out.c (write_ts_decl_common_tree_pointers): Likewise.
5267         (write_ts_decl_minimal_tree_pointers): Force a TRANSLATION_UNIT_DECL
5268         DECL_CONTEXT for file-scope decls.
5269         * lto-streamer.h (struct dref_entry): Declare.
5270         (dref_queue): Likewise.
5271         * cfgexpand.c (pass_expand::execute): Do not call the
5272         outlining_inline_function hook here.
5273         * lto-wrapper.c (debug_obj): New global.
5274         (tool_cleanup): Unlink it if required.
5275         (debug_objcopy): New function.
5276         (run_gcc): Handle early debug sections in the IL files by
5277         extracting them to separate files, partially linkin them and
5278         feeding the result back as result to the linker.
5279         * config/darwin.h (DEBUG_LTO_INFO_SECTION, DEBUG_LTO_ABBREV_SECTION,
5280         DEBUG_LTO_MACINFO_SECTION, DEBUG_LTO_LINE_SECTION,
5281         DEBUG_STR_LTO_SECTION, DEBUG_LTO_MACRO_SECTION): Put early debug
5282         sections into a separate segment.
5283         * config/darwin.c (darwin_asm_named_section): Handle __GNU_DWARF_LTO
5284         segments.
5285         (darwin_asm_dwarf_section): Likewise.
5286         (darwin_asm_output_dwarf_offset): Likewise.
5287         * config/i386/i386.c (make_resolver_func): Set DECL_IGNORED_P.
5289 2017-08-21  Richard Sandiford  <richard.sandiford@linaro.org>
5290             Alan Hayward  <alan.hayward@arm.com>
5291             David Sherwood  <david.sherwood@arm.com>
5293         * read-md.h (md_reader::record_potential_iterator_use): Replace
5294         pointer argument with an rtx and an index.
5295         * read-rtl.c (iterator_group::apply_iterator): Likewise.
5296         (apply_mode_iterator): Likewise.
5297         (apply_code_iterator): Likewise.
5298         (apply_int_iterator): Likewise.
5299         (apply_subst_iterator): Likewise.
5300         (record_iterator_use): Likewise.
5301         (record_attribute_use): Likewise.
5302         (md_reader::record_potential_iterator_use): Likewise.  Update calls
5303         to record_iterator_use and apply_iterator.
5304         (iterator_use): Replace ptr with x and index.
5305         (attribute_use): Likewise.
5306         (apply_attribute_uses): Update calls to apply_iterator.
5307         (apply_iterators): Likewise.  Update initialization of iterator_use.
5308         (rtx_reader::read_rtx_code): Update calls to record_iterator_use
5309         and record_potential_iterator_use.
5310         (rtx_reader::read_rtx_operand): Likewise.
5312 2017-08-21  Richard Sandiford  <richard.sandiford@linaro.org>
5313             Alan Hayward  <alan.hayward@arm.com>
5314             David Sherwood  <david.sherwood@arm.com>
5316         * varasm.c (const_rtx_hash_1): Don't hash in the mode of a
5317         CONST_WIDE_INT.
5319 2017-08-21  Richard Biener  <rguenther@suse.de>
5321         PR middle-end/81884
5322         * tree-ssa-alias.c (stmt_kills_ref_p): Handle array accesses
5323         at struct end conservatively when comparing common bases.
5325 2017-08-21  Richard Biener  <rguenther@suse.de>
5327         * tree-ssa-loop-im.c (struct lim_aux_data): Add ref index member.
5328         (mem_ref_in_stmt): Remove.
5329         (determine_max_movement): Use ref index to get at the reference.
5330         (invariantness_dom_walker::before_dom_children): Deal with
5331         lim data already initialized.
5332         (gather_mem_refs_stmt): Initialize lim data and record ref index.
5334 2017-08-19  Uros Bizjak  <ubizjak@gmail.com>
5336         * config/i386/i386.h (OPTION_MASK_ISA_ROUND): Remove.
5337         (TARGET_ISA_ROUND): Ditto.
5338         (TARGET_ROUND): Ditto.
5339         * config/i386/i386.c: Substitute TARGET_ROUND with TARGET_SSE4_1.
5340         * config/i386/i386.md: Ditto.
5341         * config/i386/sse.md: Ditto.
5342         * config/i386/i386-builtin.def: Substitute OPTION_MASK_ISA_ROUND
5343         with OPTION_MASK_ISA_SSE4_1.
5345 2017-08-19  Uros Bizjak  <ubizjak@gmail.com>
5347         PR target/81894
5348         * doc/extend.texi (x86 Built-in Functions): Correct the name of
5349         __builtin_ia32_lzcnt_u16.
5351 2017-08-18  Peter Bergner  <bergner@vnet.ibm.com>
5353         PR target/80210
5354         * config/rs6000/rs6000.c (rs6000_activate_target_options): New function.
5355         (rs6000_set_current_function): Rewrite function to use it.
5357 2017-08-18  H.J. Lu  <hongjiu.lu@intel.com>
5359         PR c/53037
5360         * print-tree.c (print_node): Support DECL_WARN_IF_NOT_ALIGN
5361         and TYPE_WARN_IF_NOT_ALIGN.
5362         * stor-layout.c (do_type_align): Merge DECL_WARN_IF_NOT_ALIGN.
5363         (handle_warn_if_not_align): New.
5364         (place_union_field): Call handle_warn_if_not_align.
5365         (place_field): Call handle_warn_if_not_align.
5366         Copy TYPE_WARN_IF_NOT_ALIGN.
5367         (finish_builtin_struct): Copy TYPE_WARN_IF_NOT_ALIGN.
5368         (layout_type): Likewise.
5369         * tree-core.h (tree_type_common): Add warn_if_not_align.  Set
5370         spare to 18.
5371         (tree_decl_common): Add warn_if_not_align.
5372         * tree.c (build_range_type_1): Copy TYPE_WARN_IF_NOT_ALIGN.
5373         * tree.h (TYPE_WARN_IF_NOT_ALIGN): New.
5374         (SET_TYPE_WARN_IF_NOT_ALIGN): Likewise.
5375         (DECL_WARN_IF_NOT_ALIGN): Likewise.
5376         (SET_DECL_WARN_IF_NOT_ALIGN): Likewise.
5377         * doc/extend.texi: Document warn_if_not_aligned attribute.
5378         * doc/invoke.texi: Document -Wif-not-aligned and -Wpacked-not-aligned.
5380 2017-08-17  Martin Liska  <mliska@suse.cz>
5382         PR bootstrap/81864
5383         * tree-loop-distribution.c (ddrs_table): Change type to pointer type.
5384         (get_data_dependence): Use it as pointer type.
5385         (distribute_loop): Likewise.
5387 2017-08-17  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
5389         * config/rs6000/altivec.md (UNSPEC_VMRGOW_DIRECT): New constant.
5390         (p8_vmrgew_v4sf_direct): Generalize to p8_vmrgew_<mode>_direct.
5391         (p8_vmrgow_<mode>_direct): New define_insn.
5392         * config/rs6000/rs6000.c (altivec_expand_vec_perm_const): Properly
5393         handle endianness for vmrgew and vmrgow permute patterns.
5395 2017-08-17  Peter Bergner  <bergner@vnet.ibm.com>
5397         * config/rs6000/altivec.md (VParity): Remove TARGET_VSX_TIMODE.
5398         * config/rs6000/rs6000-cpus.def: Remove comment.
5399         (ISA_2_7_MASKS_SERVER): Delete OPTION_MASK_VSX_TIMODE;
5400         (POWERPC_MASKS): Likewise.
5401         * config/rs6000/rs6000.c (rs6000_hard_regno_mode_ok): Remove unneeded
5402         use of TARGET_VSX_TIMODE.
5403         (rs6000_setup_reg_addr_masks): Change TARGET_VSX_TIMODE to TARGET_VSX.
5404         (rs6000_init_hard_regno_mode_ok): Remove unneeded uses of
5405         TARGET_VSX_TIMODE.  Change use of TARGET_VSX_TIMODE to TARGET_VSX.
5406         (rs6000_option_override_internal): Remove dead code.
5407         (rs6000_legitimize_address): Change TARGET_VSX_TIMODE to TARGET_VSX.
5408         (rs6000_legitimize_reload_address): Likewise.
5409         (rs6000_legitimate_address_p): Likewise.
5410         (rs6000_opt_masks): Delete "vsx-timode".
5411         (rs6000_disable_incompatible_switches): Remove mention of -mvsx-timode
5412         from function comment.
5413         * config/rs6000/rs6000.h (MASK_VSX_TIMODE): Delete.
5414         * config/rs6000/rs6000.md (FMOVE128_GPR): Remove TARGET_VSX_TIMODE.
5415         (V16QI, V8HI, V4SI, V4SF, V2DI, V2DF, V1TI): Remove useless empty
5416         condition.
5417         * config/rs6000/rs6000.opt (mvsx-timode): Replace with stub.
5418         * config/rs6000/vector.md (VEC_IP): Remove TARGET_VSX_TIMODE.
5419         * config/rs6000/vsx.md (VSX_LE_128): Likewise.
5420         (VSX_TI): Likewise.
5421         (VSX_M): Likewise.
5422         (define_peephole2): Likewise.
5424 2017-08-17  Martin Sebor  <msebor@redhat.com>
5426         PR c/81859
5427         * pretty-print.c (pp_format): Use strnlen in %.*s to avoid reading
5428         past the end of an array.
5429         (test_pp_format): Add test cases.
5431 2017-08-17  Richard Sandiford  <richard.sandiford@linaro.org>
5433         * internal-fn.def (CLRSB, CLZ, CTZ, FFS, PARITY, POPCOUNT): Add
5434         missing ECF_NOTHROW flags.
5436 2017-08-17  Peter Bergner  <bergner@vnet.ibm.com>
5438         PR target/72804
5439         * config/rs6000/vsx.md (*vsx_le_permute_<mode>): Add support for
5440         operands residing in integer registers.
5441         (*vsx_le_perm_load_<mode>): Likewise.
5442         (*vsx_le_perm_store_<mode>): Likewise.
5443         (define_peephole2): Add peepholes to optimize the above.
5445 2017-08-17  Marek Polacek  <polacek@redhat.com>
5447         PR middle-end/81814
5448         * fold-const.c (operand_equal_for_comparison_p): Remove code that used
5449         to mimic what shorten_compare did.  Change the return type to bool.
5450         (fold_cond_expr_with_comparison): Update call to
5451         operand_equal_for_comparison_p.
5452         (fold_ternary_loc): Likewise.
5454 2017-08-17  Jackson Woodruff  <jackson.woodruff@arm.com>
5456         * aarch64-simd.md (mov<mode>): No longer force zero immediate into
5457         register.
5458         (*aarch64_simd_mov<mode>): Add new case for stp using zero immediate.
5460 2017-08-17  Richard Biener  <rguenther@suse.de>
5462         * tree-ssa-structalias.c (solve_graph): When propagating
5463         to successors update the graphs succ edges and avoid duplicate work.
5465 2017-08-17  Maxim Ostapenko  <m.ostapenko@samsung.com>
5467         PR target/81861
5468         * config/i386/i386.c (ix86_option_override_internal): Save target
5469         specific options after ix86_stack_protector_guard_reg was changed.
5471 2017-08-17  Richard Biener  <rguenther@suse.de>
5473         PR tree-optimization/81827
5474         * tree-ssa-structalias.c (struct variable_info): Add is_reg_var flag.
5475         (new_var_info): Initialize it conservatively.
5476         (get_call_vi): Mark register vars.
5477         (new_scalar_tmp_constraint_exp): Likewise.
5478         (handle_rhs_call): Likewise.
5479         (handle_const_call): Likewise.
5480         (create_function_info_for): Likewise.
5481         (solve_constraints): Sort varinfos to separate register from
5482         non-register vars to pack points-to solution bitmaps during
5483         iteration.
5485 2017-08-17  Marek Polacek  <polacek@redhat.com>
5487         * gimplify.c (gimplify_adjust_omp_clauses): Compare with 0 instead of 1.
5489 2017-08-17  Richard Biener  <rguenther@suse.de>
5491         * tree-vrp.c (vrp_int_const_binop): Do not set *overflow_p
5492         to true when overflow is undefined and we saturated the result.
5494 2017-08-17  Alan Modra  <amodra@gmail.com>
5496         PR target/80938
5497         * config/rs6000/rs6000.c (rs6000_savres_strategy): Revert 2017-08-09.
5498         Don't use store multiple if only one reg needs saving.
5499         (interesting_frame_related_regno): New function.
5500         (rs6000_frame_related): Don't emit frame info for regs that
5501         don't need saving.
5502         (rs6000_emit_epilogue): Likewise.
5504 2017-08-16  Nathan Sidwell  <nathan@acm.org>
5506         * tree-core.h (tree_type_non_common): Rename binfo to lang_1.
5507         * tree.h (TYPE_BINFO): Use type_non_common.maxval.
5508         (TYPE_LANG_SLOT_1): Use type_non_common.lang_1, for any type.
5509         * tree.c (free_lang_data_in_type): Use else-if chain.  Always
5510         clear TYPE_LANG_1.  Remove obsolete member-function stripping.
5511         (find_decls_types_r): Comment about TYPE_MAX_VALUES_RAW.
5512         (verify_type): Adjust for TYPE_BINFO move.
5513         * lto-streamer-out.c (DFS::DFS_write_tree_body): No need to
5514         process TYPE_BINFO directly.
5515         (hash_tree): Likewise.
5516         * tree-streamer-in.c (lto_input_ts_type_non_common_tree_pointers):
5517         Likewise.
5518         * tree-streamer-out.c (write_ts_type_non_common_tree_pointers):
5519         Likewise.
5521 2017-08-16  David Malcolm  <dmalcolm@redhat.com>
5523         * diagnostic-show-locus.c (colorizer::m_caret): Remove unused field.
5525 2017-08-16  Uros Bizjak  <ubizjak@gmail.com>
5527         PR target/46091
5528         * config/i386/i386.md (*anddi_1_btr): Change predicates of
5529         operand 0 and operand 1 to nomimmediate_operand. Add "m" constraint.
5530         Add ix86_binary_operator_ok to insn constraint.
5531         (*iordi_1_bts): Ditto.
5532         (*xordi_1_btc): Ditto.
5533         (*btsq): Change predicate of operand 0 to nonimmediate_operand.
5534         Update corresponding peephole2 pattern.
5535         (*btrq): Ditto.
5536         (*btcq): Ditto.
5538 2017-08-16  Bin Cheng  <bin.cheng@arm.com>
5540         PR tree-optimization/81832
5541         * tree-ssa-loop-ch.c (should_duplicate_loop_header_p): Don't
5542         copy loop header which has IFN_LOOP_DIST_ALIAS call.
5544 2017-08-16  Marek Polacek  <polacek@redhat.com>
5546         PR middle/81695
5547         * fold-const.c (fold_indirect_ref_1): Restore original behavior
5548         regarding size_zero_node.
5550 2017-08-16  Martin Liska  <mliska@suse.cz>
5552         PR target/81753
5553         * config.gcc: Respect previously set extra_objs in case
5554         of darwin target.
5556 2017-08-16  Richard Sandiford  <richard.sandiford@linaro.org>
5558         PR tree-optimization/81835
5559         * tree-vect-loop.c (vect_is_simple_reduction): Simply checks for
5560         the phi SSA_NAME.  Check that the condition in a COND_EXPR does
5561         not depend on the phi.
5563 2017-08-16  Alan Modra  <amodra@gmail.com>
5565         * config/rs6000/rs6000.c (rs6000_init_hard_regno_mode_ok): Delete
5566         dead code.
5568 2017-08-16  Alan Modra  <amodra@gmail.com>
5570         * config/rs6000/rs6000.c (rs6000_reg_live_or_pic_offset_p): Merge..
5571         (save_reg_p): ..into this.  Update all callers.
5572         (first_reg_to_save): Simplify.
5574 2017-08-16  Alan Modra  <amodra@gmail.com>
5576         * config/rs6000/rs6000.c (rs6000_savres_strategy): Don't restore
5577         fixed regs.
5579 2017-08-15  Joseph Myers  <joseph@codesourcery.com>
5581         PR target/78460
5582         PR target/67712
5583         * config/sh/sh-mem.cc (sh_expand_cmpnstr): Only unroll for
5584         constant count if that count is less than 32.
5586 2017-08-15  Nathan Sidwell  <nathan@acm.org>
5588         * gcc.c (execute): Emit friendlier message if inferior is killed
5589         by an external cause.
5591 2017-08-15  Richard Biener  <rguenther@suse.de>
5593         PR tree-optimization/81790
5594         * tree-ssa-sccvn.c (vn_lookup_simplify_result): Handle both
5595         CONSTRUCTORs from simplifying and VN.
5597 2017-08-14  Martin Sebor  <msebor@redhat.com>
5599         * builtin-attrs.def: Add comments.
5601 2017-08-14  Martin Sebor  <msebor@redhat.com>
5603         PR c/81117
5604         * doc/extend.texi (attribute nonstring): Document new attribute.
5606 2017-08-14  Martin Sebor  <msebor@redhat.com>
5608         PR c/81117
5609         * tree-diagnostic.c (default_tree_printer): Handle %G.
5610         * gimple-pretty-print.h (percent_G_format): Declare new function.
5611         * gimple-pretty-print.c (percent_G_format): Define.
5612         * tree-pretty-print.c (percent_K_format): Add argument.
5614 2017-08-14  Martin Sebor  <msebor@redhat.com>
5616         PR translation/79998
5617         * gimple-ssa-sprintf.c (pass_sprintf_length::handle_gimple_call):
5618         Remove a stray space.
5620 2017-08-14  Uros Bizjak  <ubizjak@gmail.com>
5622         PR target/46091
5623         * config/i386/i386.md (*anddi_1_btr): New insn_and_split pattern.
5624         (*iordi_1_bts): Ditto.
5625         (*xordi_1_btc): Ditto.
5627 2017-08-14  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
5629         PR target/79845
5630         * config/rs6000/linux64.h (INVALID_64BIT): Use quoted strings.
5631         * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin):
5632         Likewise.
5633         * config/rs6000/rs6000.c (rs6000_init_hard_regno_mode_ok): Use
5634         quoted strings, and make more translator-friendly.
5635         (darwin_rs6000_override_options): Likewise.
5636         (rs6000_option_override_internal): Likewise.
5637         (rs6000_return_in_memory): Fix overlong line.
5638         (init_cmulative_args): Use quoted strings, and make more
5639         translator-friendly.
5640         (rs6000_pass_by_reference): Fix overlong line.
5641         (def_builtin): Use quoted strings.
5642         (altivec_expand_predicate_builtin): Use quoted strings, and make
5643         more translator-friendly.
5644         (htm_expand_builtin): Use quoted strings.
5645         (cpu_expand_builtin): Use quoted strings, and make more
5646         translator-friendly.
5647         (altivec_expand_builtin): Likewise.
5648         (paired_expand_predicate_builtin): Likewise.
5649         (rs6000_invalid_builtin): Likewise.
5650         (builtin_function_type): Use quoted strings.
5651         (rs6000_expand_split_stack_prologue): Use quoted strings, and make
5652         more translator-friendly.
5653         (rs6000_trampoline_init): Likewise.
5654         (rs6000_handle_altivec_attribute): Likewise.
5655         (rs6000_inner_target_options): Use quoted strings.
5656         (rs6000_disable_incompatible_switches): Likewise.
5657         * config/rs6000/sysv4.h (SUBTARGET_OVERRIDE_OPTIONS): Use quoted
5658         strings, and make more translator-friendly.
5659         (SUBSUBTARGET_OVERRIDE_OPTIONS): Use quoted strings.
5661 2017-08-14  Bin Cheng  <bin.cheng@arm.com>
5663         PR tree-optimization/81799
5664         * tree-loop-distribution.c (version_loop_by_alias_check): Force
5665         cond_expr to simple gimple operand.
5667 2017-08-14  Wilco Dijkstra  <wdijkstr@arm.com>
5669         PR middle-end/46932
5670         * doc/sourcebuild.texi (autoincdec): Add autoincdec description.
5672 2017-08-14  Georg-Johann Lay  <avr@gjlay.de>
5674         PR target/81754
5675         PR target/81268
5676         * config/avr/avr.opt (mgas-isr-prologues): New Var avr_gasisr_prologues.
5677         * config/avr/avr.md (gasisr, *gasisr): Use it instead of
5678         TARGET_GASISR_PROLOGUES.
5679         * config/avr/avr.c (avr_option_override): Same.
5680         (avr_pass_pre_proep::execute): Same.
5682 2017-08-13  H.J. Lu  <hongjiu.lu@intel.com>
5684         PR target/81820
5685         * config/i386/i386.c (ix86_finalize_stack_frame_flags): Replace
5686         frame pointer with stack pointer - UNITS_PER_WORD in debug insns.
5688 2017-08-13  Uros Bizjak  <ubizjak@gmail.com>
5690         * config/i386/i386.md (*load_tp_<mode>): Redefine as
5691         define_insn_and_split.  Split to a memory load from 0 in
5692         DEFAULT_TLS_SEG_REG address space.  Merge with *load_tp_x32
5693         using PTR mode iterator.
5694         (*load_tp_x32_zext"): Redefine as define_insn_and_split.
5695         Split to a memory load from 0 in DEFAULT_TLS_SEG_REG address space.
5696         (*add_tp_<mode>): Redefine as define_insn_and_split.
5697         Split to an add with a memory load from 0 in DEFAULT_TLS_SEG_REG
5698         address space.  Merge with *add_tp_x32 using PTR mode iterator.
5699         (*add_tp_x32_zext"): Redefine as define_insn_and_split.
5700         Split to an add with a  memory load from 0 in
5701         DEFAULT_TLS_SEG_REG address space.
5703 2017-08-12  Andrew Pinski  <apinski@cavium.com>
5705         * config/aarch64/aarch64-option-extensions.def (rdma):
5706         Fix feature string to what Linux prints out in /proc/cpuinfo.
5708 2017-08-12  Pierre-Marie de Rodat  <derodat@adacore.com>
5710         PR ada/79542
5711         * dwarf2out.c (modified_type_die): For C typedef types that have
5712         an ultimate origin, process the ultimate origin instead of the
5713         input type.
5714         (gen_typedef_die): Assert that input DECLs have no ultimate
5715         origin.
5716         (gen_type_die_with_usage): For typedef variants that have an
5717         ultimate origin, just call gen_decl_die on the original DECL.
5718         (process_scope_var): Avoid creating DIEs for local typedefs and
5719         concrete static variables.
5721 2017-08-12  Alan Modra  <amodra@gmail.com>
5723         PR target/81170
5724         PR target/81295
5725         * config/rs6000/sysv4.h (STARTFILE_LINUX_SPEC): Upgrade to
5726         match gnu-user.h startfile.
5727         (ENDFILE_LINUX_SPEC): Similarly.
5729 2017-08-11  Thomas Schwinge  <thomas@codesourcery.com>
5731         PR lto/81430
5732         * config/nvptx/nvptx.c (nvptx_override_options_after_change):
5733         Remove function.
5734         (TARGET_OVERRIDE_OPTIONS_AFTER_CHANGE): Remove definition.
5736 2017-08-11  Tamar Christina  <tamar.christina@arm.com>
5737         * config/aarch64/aarch64.md (mov<mode>): Change.
5738         (*movhf_aarch64, *movsf_aarch64, *movdf_aarch64):
5739         aarch64_reg_or_fp_float into aarch64_reg_or_fp_zero.
5740         * config/aarch64/predicates.md (aarch64_reg_or_fp_float): Removed.
5742 2017-08-11  Eric Botcazou  <ebotcazou@adacore.com>
5744         * tree-sra.c (build_access_from_expr_1): Use more precise diagnostics
5745         for storage order barriers.
5747 2017-08-11  Martin Liska  <mliska@suse.cz>
5749         PR tree-opt/79987
5750         * tree-chkp.c (chkp_get_bounds_for_decl_addr): Do not instrument
5751         variables of void type.
5753 2017-08-11  Martin Liska  <mliska@suse.cz>
5755         * asan.c (asan_protect_global): Replace ASM_OUTPUT_DEF with
5756         TARGET_SUPPORTS_ALIASES.
5757         * cgraph.c (cgraph_node::create_same_body_alias): Likewise.
5758         * ipa-visibility.c (can_replace_by_local_alias): Likewise.
5759         (optimize_weakref): Likewise.
5760         * symtab.c (symtab_node::noninterposable_alias): Likewise.
5761         * varpool.c (varpool_node::create_extra_name_alias): Likewise.
5762         * defaults.h: Introduce TARGET_SUPPORTS_ALIASES.
5764 2017-08-11  Martin Liska  <mliska@suse.cz>
5766         PR ipa/81213
5767         * config/i386/i386.c (make_resolver_func): Do complete
5768         refactoring of the function.
5770 2017-08-10  Uros Bizjak  <ubizjak@gmail.com>
5772         PR target/81708
5773         * config/i386/i386.opt (mstack-protector-guard-symbol=): New option
5774         * config/i386/i386.c (ix86_stack_protect_guard): Use
5775         ix86_stack_protect_guard_symbol_str to generate varible declaration.
5776         * doc/invoke.texi (x86 Options): Document
5777         -mstack-protector-guard-symbol= option.
5779 2017-08-10  Uros Bizjak  <ubizjak@gmail.com>
5781         * config/i386/i386-protos.h (ix86_split_stack_guard): New prototype.
5782         * config/i386/i386.c (ix86_split_stack_guard): New function.
5783         (ix86_xpand_split_stack_prologue): Call ix86_split_stack_guard.
5784         (ix86_legitimate_address_p) <case UNSPEC_STACK_CHECK>: Remove.
5785         (i386_asm_output_addr_const_extra) <case UNSPEC_STACK_CHECK>: Ditto.
5786         (optput_pic_addr_const): Remove UNSPEC_STACK_CHECK handling.
5787         * config/i386/i386.md (unspec): Remove UNSPEC_STACK_CHECK.
5788         (split_stack_space_check): Call ix86_split_stack_guard.
5790 2017-08-10  Martin Sebor  <msebor@redhat.com>
5792         * print-tree.c (print_node): Print location using the established
5793         format %s:%i%i.
5794         Replace spaces with colons.
5795         (debug_raw, debug): Ditto.
5797 2017-08-10  Martin Sebor  <msebor@redhat.com>
5799         PR c++/81586
5800         * pretty-print.c (pp_format): Correct the handling of %s precision.
5802 2017-08-10  H.J. Lu  <hongjiu.lu@intel.com>
5804         PR target/81736
5805         * config/i386/i386.c (ix86_finalize_stack_realign_flags): Renamed
5806         to ...
5807         (ix86_finalize_stack_frame_flags): This.  Also clear
5808         frame_pointer_needed if -fno-omit-frame-pointer is used without
5809         stack access.
5810         (ix86_expand_prologue): Replace ix86_finalize_stack_realign_flags
5811         with ix86_finalize_stack_frame_flags.
5812         (ix86_expand_epilogue): Likewise.
5813         (ix86_expand_split_stack_prologue): Likewise.
5814         * doc/invoke.texi: Add a note for -fno-omit-frame-pointer.
5816 2017-08-10  Martin Liska  <mliska@suse.cz>
5818         PR c++/81355
5819         * c-attribs.c (handle_target_attribute):
5820         Report warning for an empty string argument of target attribute.
5822 2017-08-09  Jakub Jelinek  <jakub@redhat.com>
5824         PR c/81687
5825         * omp-low.c (omp_copy_decl): Don't remap FORCED_LABEL or DECL_NONLOCAL
5826         LABEL_DECLs.
5827         * tree-cfg.c (move_stmt_op): Don't adjust DECL_CONTEXT of FORCED_LABEL
5828         or DECL_NONLOCAL labels.
5829         (move_stmt_r) <case GIMPLE_LABEL>: Adjust DECL_CONTEXT of FORCED_LABEL
5830         or DECL_NONLOCAL labels here.
5832 2017-08-09  Will Schmidt  <will_schmidt@vnet.ibm.com>
5834         * config/rs6000/rs6000.c (rs6000_option_override_internal): Add blurb
5835         to indicate when early gimple folding has been disabled.
5836         (rs6000_gimple_fold_builtin): Add debug content.
5837         (rs6000_invalid_builtin): Fix whitespace.
5838         (rs6000_expand_builtin): Fix whitespace.
5839         * config/rs6000/rs6000.opt: Add option for -mfold-gimple.
5841 2017-08-09  Segher Boessenkool  <segher@kernel.crashing.org>
5843         PR target/80938
5844         * config/rs6000/rs6000.c (rs6000_savres_strategy): Don't use
5845         SAVE_MULTIPLE if not all the registers that saves, should be saved.
5847 2017-08-09  Jim Wilson  <jim.wilson@linaro.org>
5849         * config/aarch64/aarch64-cores.def (falkor): Use falkor pipeline.
5850         (qdf24xx): Likewise.
5851         * config/aarch64/aarch64.md: Include falkor.md.
5852         * config/aarch64/falkor.md: New.
5854 2017-08-09  Marek Polacek  <polacek@redhat.com>
5856         PR c/81233
5857         * diagnostic-core.h (emit_diagnostic_valist): Add declaration.
5858         * diagnostic.c (emit_diagnostic): Add a comment.
5859         (emit_diagnostic_valist): New function.
5861 2017-08-09  Marek Polacek  <polacek@redhat.com>
5863         PR c/81417
5864         * input.c (make_location): New overload.
5865         * input.h (make_location): Declare.
5867 2017-08-08  Alan Modra  <amodra@gmail.com>
5868             H.J. Lu  <hongjiu.lu@intel.com>
5870         PR driver/81523
5871         * gcc.c (NO_PIE_SPEC): Delete.
5872         (PIE_SPEC): Define as !no-pie/pie.  Move static|shared|r
5873         exclusion..
5874         (LINK_PIE_SPEC): ..to here.
5875         (LINK_COMMAND_SPEC): Support -no-pie.
5876         * config/gnu-user.h (GNU_USER_TARGET_STARTFILE_SPEC): Correct
5877         chain of crtbegin*.o selection, update for PIE_SPEC changes and
5878         format.
5879         (GNU_USER_TARGET_ENDFILE_SPEC): Similarly.
5880         * config/sol2.h (STARTFILE_CRTBEGIN_SPEC): Similarly.
5881         (ENDFILE_CRTEND_SPEC): Similarly.
5883 2017-08-08  Uros Bizjak  <ubizjak@gmail.com>
5885         PR target/81708
5886         * config/i386/i386.opt (mstack-protector-guard-reg=): New option
5887         (mstack-protector-guard-offset=): Ditto.
5888         * config/i386/i386.c (ix86_option_override): Handle
5889         -mstack-protector-guard-reg= and -mstack-protector-guard-offset=
5890         options.
5891         (ix86_stack_protect_guard): Use ix86_stack_protect_guard_reg and
5892         ix86_stack_protect_guard_offset variables.
5893         (TARGET_STACK_PROTECT_GUARD): Always define.
5894         * doc/invoke.texi (x86 Options): Document -mstack-protector-guard-reg=
5895         and -mstack-protector-guard-offset= options.
5897 2017-08-08  Bin Cheng  <bin.cheng@arm.com>
5899         * tree-ssa-loop-ivopts.c (relate_compare_use_with_all_cands): Handle
5900         boundary case for the last candidate.
5902 2017-08-08  Bin Cheng  <bin.cheng@arm.com>
5904         * doc/invoke.texi: Document -ftree-loop-distribution for O3.
5905         * opts.c (default_options_table): Add OPT_ftree_loop_distribution.
5907 2017-08-08  Tamar Christina  <tamar.christina@arm.com>
5909         PR middle-end/19706
5910         * config/aarch64/aarch64.md (xorsign<mode>3): New optabs.
5911         * config/aarch64/aarch64-builtins.c
5912         (aarch64_builtin_vectorized_function): Added CASE_CFN_XORSIGN.
5913         * config/aarch64/aarch64-simd-builtins.def: Added xorsign BINOP.
5914         * config/aarch64/aarch64-simd.md: Added xorsign<mode>3
5916 2017-08-08  Tamar Christina  <tamar.christina@arm.com>
5917             Andrew Pinski <pinskia@gmail.com>
5919         PR middle-end/19706
5920         * internal-fn.def (XORSIGN): New.
5921         * optabs.def (xorsign_optab): New.
5922         * tree-ssa-math-opts.c (is_copysign_call_with_1): New.
5923         (convert_expand_mult_copysign): New.
5924         (pass_optimize_widening_mul::execute): Call
5925         convert_expand_mult_copysign.
5927 2017-08-08  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
5929         PR tree-optimization/81354
5930         * gimple-ssa-strength-reduction.c (create_add_on_incoming_edge):
5931         Insert on edges rather than explicitly creating landing pads.
5932         (analyze_candidates_and_replace): Commit edge inserts.
5934 2017-08-08  Richard Biener  <rguenther@suse.de>
5936         PR middle-end/81719
5937         * tree-ssa-loop-niter.c: Include tree-dfa.h.
5938         (expand_simple_operations): Also look through ADDR_EXPRs with
5939         MEM_REF bases treating them as POINTER_PLUS_EXPR.
5941 2017-08-08  Richard Biener  <rguenther@suse.de>
5943         PR tree-optimization/81723
5944         * tree-vect-slp.c (struct bst_traits): New hash traits.
5945         (bst_fail): New global.
5946         (vect_build_slp_tree_2): New worker, split out from ...
5947         (vect_build_slp_tree): ... this now wrapping it with using
5948         bst_fail set to cache SLP tree build fails.  Properly handle
5949         max_tree_size.
5950         (vect_analyze_slp_instance): Allocate and free bst_fail.
5952 2017-08-08  Martin Liska  <mliska@suse.cz>
5954         PR tree-opt/81696
5955         * ipa-icf-gimple.c (func_checker::compare_cst_or_decl): Consider
5956         LABEL_DECLs that can be from a different function.
5958 2017-08-08  Bin Cheng  <bin.cheng@arm.com>
5960         PR tree-optimization/81744
5961         * tree-predcom.c (prepare_finalizers_chain): Deep copy expr of
5962         loop's number of iterations.
5964 2017-08-08  Martin Liska  <mliska@suse.cz>
5966         * asan.c: Include header files.
5967         * attribs.c (build_decl_attribute_variant): New function moved
5968         from tree.[ch].
5969         (build_type_attribute_qual_variant): Likewise.
5970         (cmp_attrib_identifiers): Likewise.
5971         (simple_cst_list_equal): Likewise.
5972         (omp_declare_simd_clauses_equal): Likewise.
5973         (attribute_value_equal): Likewise.
5974         (comp_type_attributes): Likewise.
5975         (build_type_attribute_variant): Likewise.
5976         (lookup_ident_attribute): Likewise.
5977         (remove_attribute): Likewise.
5978         (merge_attributes): Likewise.
5979         (merge_type_attributes): Likewise.
5980         (merge_decl_attributes): Likewise.
5981         (merge_dllimport_decl_attributes): Likewise.
5982         (handle_dll_attribute): Likewise.
5983         (attribute_list_equal): Likewise.
5984         (attribute_list_contained): Likewise.
5985         * attribs.h (lookup_attribute): New function moved from tree.[ch].
5986         (lookup_attribute_by_prefix): Likewise.
5987         * bb-reorder.c: Include header files.
5988         * builtins.c: Likewise.
5989         * calls.c: Likewise.
5990         * cfgexpand.c: Likewise.
5991         * cgraph.c: Likewise.
5992         * cgraphunit.c: Likewise.
5993         * convert.c: Likewise.
5994         * dwarf2out.c: Likewise.
5995         * final.c: Likewise.
5996         * fold-const.c: Likewise.
5997         * function.c: Likewise.
5998         * gimple-expr.c: Likewise.
5999         * gimple-fold.c: Likewise.
6000         * gimple-pretty-print.c: Likewise.
6001         * gimple.c: Likewise.
6002         * gimplify.c: Likewise.
6003         * hsa-common.c: Likewise.
6004         * hsa-gen.c: Likewise.
6005         * internal-fn.c: Likewise.
6006         * ipa-chkp.c: Likewise.
6007         * ipa-cp.c: Likewise.
6008         * ipa-devirt.c: Likewise.
6009         * ipa-fnsummary.c: Likewise.
6010         * ipa-inline.c: Likewise.
6011         * ipa-visibility.c: Likewise.
6012         * ipa.c: Likewise.
6013         * lto-cgraph.c: Likewise.
6014         * omp-expand.c: Likewise.
6015         * omp-general.c: Likewise.
6016         * omp-low.c: Likewise.
6017         * omp-offload.c: Likewise.
6018         * omp-simd-clone.c: Likewise.
6019         * opts-global.c: Likewise.
6020         * passes.c: Likewise.
6021         * predict.c: Likewise.
6022         * sancov.c: Likewise.
6023         * sanopt.c: Likewise.
6024         * symtab.c: Likewise.
6025         * toplev.c: Likewise.
6026         * trans-mem.c: Likewise.
6027         * tree-chkp.c: Likewise.
6028         * tree-eh.c: Likewise.
6029         * tree-into-ssa.c: Likewise.
6030         * tree-object-size.c: Likewise.
6031         * tree-parloops.c: Likewise.
6032         * tree-profile.c: Likewise.
6033         * tree-ssa-ccp.c: Likewise.
6034         * tree-ssa-live.c: Likewise.
6035         * tree-ssa-loop.c: Likewise.
6036         * tree-ssa-sccvn.c: Likewise.
6037         * tree-ssa-structalias.c: Likewise.
6038         * tree-ssa.c: Likewise.
6039         * tree-streamer-in.c: Likewise.
6040         * tree-vectorizer.c: Likewise.
6041         * tree-vrp.c: Likewise.
6042         * tsan.c: Likewise.
6043         * ubsan.c: Likewise.
6044         * varasm.c: Likewise.
6045         * varpool.c: Likewise.
6046         * tree.c: Remove functions moved to attribs.[ch].
6047         * tree.h: Likewise.
6048         * config/aarch64/aarch64.c: Add attrs.h header file.
6049         * config/alpha/alpha.c: Likewise.
6050         * config/arc/arc.c: Likewise.
6051         * config/arm/arm.c: Likewise.
6052         * config/avr/avr.c: Likewise.
6053         * config/bfin/bfin.c: Likewise.
6054         * config/c6x/c6x.c: Likewise.
6055         * config/cr16/cr16.c: Likewise.
6056         * config/cris/cris.c: Likewise.
6057         * config/darwin.c: Likewise.
6058         * config/epiphany/epiphany.c: Likewise.
6059         * config/fr30/fr30.c: Likewise.
6060         * config/frv/frv.c: Likewise.
6061         * config/ft32/ft32.c: Likewise.
6062         * config/h8300/h8300.c: Likewise.
6063         * config/i386/winnt.c: Likewise.
6064         * config/ia64/ia64.c: Likewise.
6065         * config/iq2000/iq2000.c: Likewise.
6066         * config/lm32/lm32.c: Likewise.
6067         * config/m32c/m32c.c: Likewise.
6068         * config/m32r/m32r.c: Likewise.
6069         * config/m68k/m68k.c: Likewise.
6070         * config/mcore/mcore.c: Likewise.
6071         * config/microblaze/microblaze.c: Likewise.
6072         * config/mips/mips.c: Likewise.
6073         * config/mmix/mmix.c: Likewise.
6074         * config/mn10300/mn10300.c: Likewise.
6075         * config/moxie/moxie.c: Likewise.
6076         * config/msp430/msp430.c: Likewise.
6077         * config/nds32/nds32-isr.c: Likewise.
6078         * config/nds32/nds32.c: Likewise.
6079         * config/nios2/nios2.c: Likewise.
6080         * config/nvptx/nvptx.c: Likewise.
6081         * config/pa/pa.c: Likewise.
6082         * config/pdp11/pdp11.c: Likewise.
6083         * config/powerpcspe/powerpcspe.c: Likewise.
6084         * config/riscv/riscv.c: Likewise.
6085         * config/rl78/rl78.c: Likewise.
6086         * config/rx/rx.c: Likewise.
6087         * config/s390/s390.c: Likewise.
6088         * config/sh/sh.c: Likewise.
6089         * config/sol2.c: Likewise.
6090         * config/sparc/sparc.c: Likewise.
6091         * config/spu/spu.c: Likewise.
6092         * config/stormy16/stormy16.c: Likewise.
6093         * config/tilegx/tilegx.c: Likewise.
6094         * config/tilepro/tilepro.c: Likewise.
6095         * config/v850/v850.c: Likewise.
6096         * config/vax/vax.c: Likewise.
6097         * config/visium/visium.c: Likewise.
6098         * config/xtensa/xtensa.c: Likewise.
6100 2017-08-07  Michael Meissner  <meissner@linux.vnet.ibm.com>
6102         PR target/81593
6103         * config/rs6000/vsx.md (vsx_concat_<mode>, VSX_D): Cleanup
6104         constraints since the -mupper-regs-* switches have been
6105         eliminated.
6106         (vsx_concat_<mode>_1): New combiner insns to recognize inserting
6107         into a vector from a double word element that was extracted from
6108         another vector, and eliminate extra XXPERMDI instructions.
6109         (vsx_concat_<mode>_2): Likewise.
6110         (vsx_concat_<mode>_3): Likewise.
6111         (vsx_set_<mode>, VSX_D): Rewrite vector set in terms of vector
6112         concat to allow optimizing inserts from previous extracts.
6114 2017-08-07  Uros Bizjak  <ubizjak@gmail.com>
6116         * config/i386/i386.c (ix86_stack_protect_guard): Generate
6117         memory reference to a SSP offset in TLS address space.
6118         (ix86_print_operand) <case '@'>: Remove.
6119         (ix86_print_operand_punct_valid_p): Remove '@' code.
6120         * config/i386/i386.md (unspec): Remove UNSPEC_SP_TLS_SET and
6121         UNSPEC_SP_TLS_TEST.
6122         (stack_tls_protect_set_<mode>): Remove.
6123         (stack_protect_set): Do not call gen_stack_tls_protect_set_<mode>.
6124         (stack_tls_protect_test_<mode>): Remove.
6125         (stack_protect_test): Do not call gen_stack_tls_protect_test_<mode>.
6127 2017-08-07  Olivier Hainque  <hainque@adacore.com>
6129         PR target/81755
6130         * config/vxworksae.h (VXWORKS_HAVE_TLS): Define.
6132 2017-08-07  Douglas Rupp  <rupp@adacore.com>
6134         * Makefile.in (install-mkheaders): Fix typo, where the multi_dir
6135         variable was referenced as multidir in command.
6137 2017-08-07  Jakub Jelinek  <jakub@redhat.com>
6139         PR c/69389
6140         * gimplify.c (goa_stabilize_expr): Handle BIT_INSERT_EXPR and
6141         BIT_FIELD_REF.
6143 2017-08-07  Martin Liska  <mliska@suse.cz>
6145         * config/m32c/m32c.c: Add include of stringpool.h and attribs.h.
6146         * config/rl78/rl78.c: Add include of attribs.h.
6147         * config/sh/sh.c: Likewise.
6148         * config/v850/v850.c: Likewise.
6150 2017-08-07  Tom de Vries  <tom@codesourcery.com>
6152         PR middle-end/78266
6153         * omp-expand.c (expand_oacc_for): Ensure diff_type is large enough.
6155 2017-08-07  Martin Liska  <mliska@suse.cz>
6157         * config/mips/mips.c: Include attribs.h.
6159 2017-08-07  Thomas Koenig  <tkoenig@gcc.gnu.org>
6161         PR fortran/68829
6162         * doc/invoke.texi: Document change in behvaior for -Ofast for
6163         Fortran.
6165 2017-08-07  Wilco Dijkstra  <wdijkstr@arm.com>
6167         * config/aarch64/aarch64.c (aarch64_pushwb_single_reg):
6168         Use gen_frame_mem.
6169         (aarch64_pop_regs): Likewise.
6170         (aarch64_gen_load_pair): Likewise.
6171         (aarch64_save_callee_saves): Likewise.
6172         (aarch64_restore_callee_saves): Likewise.
6174 2017-08-07  H.J. Lu  <hongjiu.lu@intel.com>
6176         * config/i386/i386.c: Revert the last change.
6178 2017-08-07  H.J. Lu  <hongjiu.lu@intel.com>
6180         PR target/81736
6181         * config/i386/i386.c (ix86_finalize_stack_realign_flags): Renamed
6182         to ...
6183         (ix86_finalize_stack_frame_flags): This.  Also clear
6184         frame_pointer_needed if -fno-omit-frame-pointer is used without
6185         stack access.
6186         (ix86_expand_prologue): Replace ix86_finalize_stack_realign_flags
6187         with ix86_finalize_stack_frame_flags.
6188         (ix86_expand_epilogue): Likewise.
6189         (ix86_expand_split_stack_prologue): Likewise.
6191 2017-08-07  H.J. Lu  <hongjiu.lu@intel.com>
6193         PR target/81743
6194         * config/i386/i386.c (get_builtin_code_for_version): Set priority
6195         to P_AES for Westmere.
6197 2017-08-07  Jonathan Yong  <10walls@gmail.com>
6199         * config/i386/mingw.opt (fset-stack-executable): Removed.
6200         * config/i386/cygming.opt (fset-stack-executable): Moved
6201         from mingw.opt.
6202         * config/i386/cygwin.h: Define CHECK_EXECUTE_STACK_ENABLED.
6204 2017-08-07  Segher Boessenkool  <segher@kernel.crashing.org>
6206         * print-rtl.c (print_exp): Print NOT as "~" instead of as "!".
6208 2017-08-07  Marek Polacek  <polacek@redhat.com>
6210         PR middle-end/81737
6211         * fold-const.c (fold_indirect_ref_1): Check type_domain.
6213 2017-08-07  Martin Liska  <mliska@suse.cz>
6215         * attribs.h (canonicalize_attr_name): New function.
6216         (cmp_attribs): Move from c-format.c and adjusted.
6217         (is_attribute_p): Moved from tree.h.
6218         * tree-inline.c: Add new includes.
6219         * tree.c (cmp_attrib_identifiers): Use cmp_attribs.
6220         (private_is_attribute_p): Remove.
6221         (private_lookup_attribute): Likewise.
6222         (private_lookup_attribute_by_prefix): Simplify.
6223         (remove_attribute): Use is_attribute_p.
6224         * tree.h: Remove removed declarations.
6226 2017-08-07  Jakub Jelinek  <jakub@redhat.com>
6228         PR middle-end/81698
6229         * stmt.c (emit_case_dispatch_table): Add DEFAULT_EDGE argument,
6230         instead of computing it in the function.  Formatting fix.
6231         (expand_case): Don't rely on default_edge being the first edge,
6232         clear it if removing it, pass default_edge to
6233         emit_case_dispatch_table.
6234         (expand_sjlj_dispatch_table): Pass NULL as DEFAULT_EDGE, formatting
6235         fix.
6237 2017-08-06  Uros Bizjak  <ubizjak@gmail.com>
6239         * config/alpha/alpha.c (alpha_reorg): If trap is the last active
6240         insn in the function, emit NOP after the insn.
6242 2017-08-06  Tom de Vries  <tom@codesourcery.com>
6244         * omp-expand.c (expand_oacc_for): Add missing edge probability for tile
6245         and element loops.
6247 2017-08-06  Tom de Vries  <tom@codesourcery.com>
6249         * omp-expand.c (expand_oacc_for): Add missing edge probability for chunk
6250         loop.
6252 2017-08-04  Yury Gribov  <tetra2005@gmail.com>
6254         PR tree-optimization/57371
6255         * match.pd: New pattern.
6257 2017-08-04  Marek Polacek  <polacek@redhat.com>
6259         PR middle-end/81695
6260         * fold-const.c (fold_indirect_ref_1): For ((int *)&a + 4 -> a[1],
6261         perform the computation in offset_int.
6263 2017-08-04  Richard Sandiford  <richard.sandiford@linaro.org>
6265         PR tree-optimization/81136
6266         * tree-vectorizer.h: Include tree-hash-traits.h.
6267         (vec_base_alignments): New typedef.
6268         (vec_info): Add a base_alignments field.
6269         (vect_record_base_alignments): Declare.
6270         * tree-data-ref.h (data_reference): Add an is_conditional_in_stmt
6271         field.
6272         (DR_IS_CONDITIONAL_IN_STMT): New macro.
6273         (create_data_ref): Add an is_conditional_in_stmt argument.
6274         * tree-data-ref.c (create_data_ref): Likewise.  Use it to initialize
6275         the is_conditional_in_stmt field.
6276         (data_ref_loc): Add an is_conditional_in_stmt field.
6277         (get_references_in_stmt): Set the is_conditional_in_stmt field.
6278         (find_data_references_in_stmt): Update call to create_data_ref.
6279         (graphite_find_data_references_in_stmt): Likewise.
6280         * tree-ssa-loop-prefetch.c (determine_loop_nest_reuse): Likewise.
6281         * tree-vect-data-refs.c (vect_analyze_data_refs): Likewise.
6282         (vect_record_base_alignment): New function.
6283         (vect_record_base_alignments): Likewise.
6284         (vect_compute_data_ref_alignment): Adjust base_addr and aligned_to
6285         for nested statements even if we fail to compute a misalignment.
6286         Use pooled base alignments for unconditional references.
6287         (vect_find_same_alignment_drs): Compare base addresses instead
6288         of base objects.
6289         (vect_analyze_data_refs_alignment): Call vect_record_base_alignments.
6290         * tree-vect-slp.c (vect_slp_analyze_bb_1): Likewise.
6292 2017-08-04  Richard Sandiford  <richard.sandiford@linaro.org>
6294         * tree-vectorizer.h (vec_info): Add a constructor and destructor.
6295         Add an explicit name for the enum.  Use auto_vec for slp_instances
6296         and grouped_stores.
6297         (_loop_vec_info): Add a constructor and destructor.  Use auto_vec
6298         for all vectors.
6299         (_bb_vec_info): Add a constructor and destructor.
6300         (vinfo_for_stmt): Return NULL for uids of -1 as well.
6301         (destroy_loop_vec_info): Delete.
6302         (vect_destroy_datarefs): Likewise.
6303         * tree-vectorizer.c (vect_destroy_datarefs): Delete.
6304         (vec_info::vec_info): New function.
6305         (vec_info::~vec_info): Likewise.
6306         (vectorize_loops): Use delete instead of destroy_loop_vec_info.
6307         * tree-parloops.c (gather_scalar_reductions): Use delete instead of
6308         destroy_loop_vec_info.
6309         * tree-vect-loop.c (new_loop_vec_info): Replace with...
6310         (_loop_vec_info::_loop_vec_info): ...this.
6311         (destroy_loop_vec_info): Replace with...
6312         (_loop_vec_info::~_loop_vec_info): ...this.  Unconditionally delete
6313         the stmt_vec_infos.  Leave handling of vec_info information to its
6314         destructor.  Remove explicit vector releases.
6315         (vect_analyze_loop_form): Use new instead of new_loop_vec_info.
6316         (vect_analyze_loop): Use delete instead of destroy_loop_vec_info.
6317         * tree-vect-slp.c (new_bb_vec_info): Replace with...
6318         (_bb_vec_info::_bb_vec_info): ...this.  Don't reserve space in
6319         BB_VINFO_GROUPED_STORES or BB_VINFO_SLP_INSTANCES.
6320         (destroy_bb_vec_info): Replace with...
6321         (_bb_vec_info::~_bb_vec_info): ...this.  Leave handling of vec_info
6322         information to its destructor.
6323         (vect_slp_analyze_bb_1): Use new and delete instead of
6324         new_bb_vec_info and destroy_bb_vec_info.
6325         (vect_slp_bb): Replace 2 calls to destroy_bb_vec_info with a
6326         single delete.
6328 2017-08-04  Richard Sandiford  <richard.sandiford@linaro.org>
6330         * tree-data-ref.h (subscript): Add access_fn field.
6331         (data_dependence_relation): Add could_be_independent_p.
6332         (SUB_ACCESS_FN, DDR_COULD_BE_INDEPENDENT_P): New macros.
6333         (same_access_functions): Move to tree-data-ref.c.
6334         * tree-data-ref.c (ref_contains_union_access_p): New function.
6335         (access_fn_component_p): Likewise.
6336         (access_fn_components_comparable_p): Likewise.
6337         (dr_analyze_indices): Add a reference to access_fn_component_p.
6338         (dump_data_dependence_relation): Use SUB_ACCESS_FN instead of
6339         DR_ACCESS_FN.
6340         (constant_access_functions): Likewise.
6341         (add_other_self_distances): Likewise.
6342         (same_access_functions): Likewise.  (Moved from tree-data-ref.h.)
6343         (initialize_data_dependence_relation): Use XCNEW and remove
6344         explicit zeroing of DDR_REVERSED_P.  Look for a subsequence
6345         of access functions that have the same type.  Allow the
6346         subsequence to end with different bases in some circumstances.
6347         Record the chosen access functions in SUB_ACCESS_FN.
6348         (build_classic_dist_vector_1): Replace ddr_a and ddr_b with
6349         a_index and b_index.  Use SUB_ACCESS_FN instead of DR_ACCESS_FN.
6350         (subscript_dependence_tester_1): Likewise dra and drb.
6351         (build_classic_dist_vector): Update calls accordingly.
6352         (subscript_dependence_tester): Likewise.
6353         * tree-ssa-loop-prefetch.c (determine_loop_nest_reuse): Check
6354         DDR_COULD_BE_INDEPENDENT_P.
6355         * tree-vectorizer.h (LOOP_REQUIRES_VERSIONING_FOR_ALIAS): Test
6356         comp_alias_ddrs instead of may_alias_ddrs.
6357         * tree-vect-data-refs.c (vect_analyze_possibly_independent_ddr):
6358         New function.
6359         (vect_analyze_data_ref_dependence): Use it if
6360         DDR_COULD_BE_INDEPENDENT_P, but fall back to using the recorded
6361         distance vectors if that fails.
6362         (dependence_distance_ge_vf): New function.
6363         (vect_prune_runtime_alias_test_list): Use it.  Don't clear
6364         LOOP_VINFO_MAY_ALIAS_DDRS.
6366 2017-08-04  Richard Biener  <rguenther@suse.de>
6368         PR middle-end/81705
6369         * fold-const.c (fold_binary_loc): Properly restrict
6370         minus_var0 && minus_var1 case when associating undefined overflow
6371         entities.
6373 2017-08-04  Tom de Vries  <tom@codesourcery.com>
6375         * omp-simd-clone.c (simd_clone_adjust): Add missing edge probability.
6377 2017-08-03  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
6379         * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin):
6380         Don't start diagnostic messages with a capital letter.
6381         * config/rs6000/rs6000.c (rs6000_option_override_internal):
6382         Likewise.
6383         (rs6000_invalid_builtin): Likewise.
6384         (rs6000_trampoline_init): Likewise.
6386 2017-08-03  Jakub Jelinek  <jakub@redhat.com>
6388         PR target/81621
6389         * bb-reorder.c (pass_partition_blocks::execute): Return TODO_df_finish
6390         after setting changeable df flags.
6392 2017-08-03  Richard Biener  <rguenther@suse.de>
6394         * tree-ssa-reassoc.c (should_break_up_subtract): Also break
6395         up if the use is in USE - X.
6397 2017-08-03  Alexander Monakov  <amonakov@ispras.ru>
6399         * toplev.c (dumpfile.h): New include.
6400         (internal_error_reentered): New static function.  Use it...
6401         (internal_error_function): ...here to handle reentered internal_error.
6403 2017-08-03  Richard Biener  <rguenther@suse.de>
6405         PR middle-end/81148
6406         * fold-const.c (split_tree): Add minus_var and minus_con
6407         arguments, remove unused loc arg.  Never generate NEGATE_EXPRs
6408         here but always use minus_*.
6409         (associate_trees): Assert we never associate with MINUS_EXPR
6410         and NULL first operand.  Do not recurse for PLUS_EXPR operands
6411         when associating as MINUS_EXPR either.
6412         (fold_binary_loc): Track minus_var and minus_con.
6414 2017-08-03  Tom de Vries  <tom@codesourcery.com>
6416         PR lto/81430
6417         * tree-streamer-in.c (lto_input_ts_function_decl_tree_pointers): If
6418         ACCEL_COMPILER, apply finish_options on
6419         DECL_FUNCTION_SPECIFIC_OPTIMIZATION.
6421 2017-08-03  Tom de Vries  <tom@codesourcery.com>
6423         PR target/81662
6424         * config/nvptx/nvptx.c (nvptx_option_override): Emit sorry if
6425         function_entry_patch_area_size > 0.
6427 2017-08-03  Jakub Jelinek  <jakub@redhat.com>
6429         PR driver/81650
6430         * calls.c (alloc_max_size): Use HOST_WIDE_INT_UC (10??)
6431         instead of 10??LU, perform unit multiplication in wide_int,
6432         don't change alloc_object_size_limit if the limit is larger
6433         than SSIZE_MAX.
6435         PR tree-optimization/81655
6436         PR tree-optimization/81588
6437         * tree-ssa-reassoc.c (optimize_range_tests_var_bound): Handle also
6438         the case when ranges[i].low and high are 1 for unsigned type with
6439         precision 1.
6441         PR middle-end/81052
6442         * omp-low.c (diagnose_sb_0): Handle flag_openmp_simd like flag_openmp.
6443         (pass_diagnose_omp_blocks::gate): Enable also for flag_openmp_simd.
6445 2017-08-03  Prathamesh Kulkarni  <prathamesh.kulkarni@linaro.org>
6447         * tree-vrp.h: Add include guard.
6449 2017-08-02  Uros Bizjak  <ubizjak@gmail.com>
6451         PR target/81644
6452         * config/i386/i386.md (unspecv): Add UNSPECV_UD2.
6453         (ud2): New insn pattern.
6454         * config/i386/i386.c (ix86_expand_epilogue):
6455         For naked functions, generate ud2 instead of trap insn.
6457 2017-08-02  Marek Polacek  <polacek@redhat.com>
6459         PR other/81667
6460         * alloc-pool.h (base_pool_allocator): Initialize m_elt_size.
6462 2017-08-02  Tom de Vries  <tom@codesourcery.com>
6463             Cesar Philippidis  <cesar@codesourcery.com>
6465         * config/nvptx/nvptx.c (nvptx_lockless_update, nvptx_lockfull_update):
6466         Add missing edge probabilities.
6468 2017-08-02  Tamar Christina  <tamar.christina@arm.com>
6470         * config/aarch64/aarch64.c (aarch64_reinterpret_float_as_int):
6471         Correct endianness.
6473 2017-08-02  Jakub Jelinek  <jakub@redhat.com>
6475         PR middle-end/79499
6476         * function.c (thread_prologue_and_epilogue_insns): Determine blocks
6477         for find_many_sub_basic_blocks bitmap by looking up BLOCK_FOR_INSN
6478         of first NONDEBUG_INSN_P in each of the split_prologue_seq and
6479         prologue_seq sequences - if any.
6481 2017-08-02  Richard Biener  <rguenther@suse.de>
6483         * tree-vect-stmts.c (vectorizable_store): Perform vector extracts
6484         via vectors if supported, integer extracts via punning if supported
6485         or otherwise vector extracts.
6487 2017-08-02  Richard Biener  <rguenther@suse.de>
6489         * tree-ssa-pre.c (bitmap_insert_into_set_1): Remove and inline
6490         into ...
6491         (bitmap_insert_into_set): ... this.
6493 2017-08-02  Richard Biener  <rguenther@suse.de>
6495         PR tree-optimization/81633
6496         Revert
6497         2015-08-17  Alan Hayward  <alan.hayward@arm.com>
6499         PR tree-optimization/71752
6500         * tree-vect-slp.c (vect_get_slp_defs): Handle null operands.
6502 2017-08-01  Daniel Santos  <daniel.santos@pobox.com>
6504         * config/i386/i386.h (ix86_frame::outlined_save_offset): Remove field.
6505         (machine_function::call_ms2sysv_pad_out): Remove field.
6506         * config/i386/i386.c (xlogue_layout::get_stack_space_used): Modify.
6507         (ix86_compute_frame_layout): Likewise.
6509 2017-08-01  H.J. Lu  <hongjiu.lu@intel.com>
6511         PR target/81654
6512         * config/i386/i386.c (ix86_set_func_type): Disallow naked
6513         attribute with interrupt attribute.
6515 2017-08-01  Andrew Pinski  <apinski@cavium.com>
6517         * tree-ssa-scopedtables.c (hashable_expr_equal_p): Check
6518         BIT_INSERT_EXPR's operand 1
6519         to see if the types precision matches.
6521 2017-08-01  Martin Liska  <mliska@suse.cz>
6523         PR middle-end/70140
6524         * builtins.c (expand_builtin_memcpy_args): Remove.
6525         (expand_builtin_memcpy): Call newly added function
6526         expand_builtin_memory_copy_args.
6527         (expand_builtin_memcpy_with_bounds): Likewise.
6528         (expand_builtin_mempcpy): Remove last argument.
6529         (expand_builtin_mempcpy_with_bounds): Likewise.
6530         (expand_builtin_memory_copy_args): New function created from
6531         expand_builtin_mempcpy_args with small modifications.
6532         (expand_builtin_mempcpy_args): Remove.
6533         (expand_builtin_stpcpy): Remove unused argument.
6534         (expand_builtin): Likewise.
6535         (expand_builtin_with_bounds): Likewise.
6537 2017-08-01  Martin Liska  <mliska@suse.cz>
6539         Revert r250771
6540         Make mempcpy more optimal (PR middle-end/70140).
6542 2017-08-01  Jakub Jelinek  <jakub@redhat.com>
6544         PR target/81622
6545         * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin): For
6546         __builtin_vec_cmpne verify both arguments are compatible vectors
6547         before looking at TYPE_MODE on the element type.  For __builtin_vec_ld
6548         verify arg1_type is a pointer or array type.  For __builtin_vec_st,
6549         move computation of aligned to after checking the argument types.
6550         Formatting fixes.
6552         PR target/80846
6553         * config/rs6000/vsx.md (vextract_fp_from_shorth,
6554         vextract_fp_from_shortl): Add element mode after mode in gen_vec_init*
6555         calls.
6557 2017-08-01  Jerome Lambourg  <lambourg@adacore.com>
6558             Doug Rupp  <rupp@adacore.com>
6559             Olivier Hainque  <hainque@adacore.com>
6561         * config.gcc (arm-wrs-vxworks*): Rework to handle arm-wrs-vxworks7 as
6562         well as arm-wrs-vxworks. Update target_cpu_name from arm6 (arch v3) to
6563         arm8 (arch v4).
6564         * config/arm/vxworks.h (MAYBE_TARGET_BPABI_CPP_BUILTINS): New, helper
6565         for TARGET_OS_CPP_BUILTIN.
6566         (TARGET_OS_CPP_BUILTIN): Invoke MAYBE_TARGET_BPABI_CPP_BUILTINS(),
6567         refine CPU definitions for arm_arch5 and add those for arm_arch6 and
6568         arm_arch7.
6569         (MAYBE_ASM_ABI_SPEC): New, helper for SUBTARGET_EXTRA_ASM_SPEC,
6570         passing required abi options to the assembler for EABI configurations.
6571         (EXTRA_CC1_SPEC): New macro, to help prevent the implicit production
6572         of .text.hot and .text.unlikely sections for kernel modules when
6573         using ARM style exceptions.
6574         (CC1_SPEC): Remove obsolete attempt at mimicking Diab toolchain
6575         options. Add EXTRA_CC1_SPEC.
6576         (VXWORKS_ENDIAN_SPEC): Adjust comment and remove handling of Diab
6577         toolchain options.
6578         (DWARF2_UNWIND_INFO): Redefine to handle the pre/post VxWorks 7
6579         transition.
6580         (ARM_TARGET2_DWARF_FORMAT): Define.
6581         * config/arm/t-vxworks: Adjust multilib control to removal of the
6582         Diab command line options.
6584 2017-08-01  Martin Liska  <mliska@suse.cz>
6586         PR gcov-profile/81561
6587         * gcov.c (unblock): Make unblocking safe as we need to preserve
6588         index correspondence of blocks and block_lists.
6590 2017-08-01  Richard Biener  <rguenther@suse.de>
6592         PR tree-optimization/81181
6593         * tree-ssa-pre.c (compute_antic_aux): Defer clean() to ...
6594         (compute_antic): ... end of iteration here.
6596 2017-08-01  James Greenhalgh  <james.greenhalgh@arm.com>
6598         * common.opt (ftree-vectorize): No longer set flag_tree_vectorize.
6599         (ftree-loop-vectorize): Set as EnabledBy ftree-vectorize.
6600         (ftree-slp-vectorize): Likewise.
6601         * omp-expand (expand_omp_simd): Remove flag_tree_vectorize, as it
6602         can no longer be set independent of flag_tree_loop_vectorize.
6603         * omp-general.c (emp_max_vf): Likewise.
6604         * opts.c (enable_fdo_optimizations): Remove references to
6605         flag_tree_vectorize, these are now implicit.
6606         (common_handle_option): Remove handling for OPT_ftree_vectorize,
6607         and leave it for the options machinery.
6609 2017-08-01  Martin Liska  <mliska@suse.cz>
6611         PR middle-end/70140
6612         * builtins.c (expand_builtin_memcpy_args): Remove.
6613         (expand_builtin_memcpy): Call newly added function
6614         expand_builtin_memory_copy_args.
6615         (expand_builtin_memcpy_with_bounds): Likewise.
6616         (expand_builtin_mempcpy): Remove last argument.
6617         (expand_builtin_mempcpy_with_bounds): Likewise.
6618         (expand_builtin_memory_copy_args): New function created from
6619         expand_builtin_mempcpy_args with small modifications.
6620         (expand_builtin_mempcpy_args): Remove.
6621         (expand_builtin_stpcpy): Remove unused argument.
6622         (expand_builtin): Likewise.
6623         (expand_builtin_with_bounds): Likewise.
6625 2017-08-01  Uros Bizjak  <ubizjak@gmail.com>
6627         PR target/81641
6628         * config/i386/i386.c (ix86_print_operand_address_as): For -masm=intel
6629         print "ds:" only for immediates in generic address space.
6631 2017-08-01  Uros Bizjak  <ubizjak@gmail.com>
6633         PR target/81639
6634         * config/i386/i386.c (ix86_funciton_naked): New prototype.
6635         (ix86_function_ok_for_sibcall): Return false for naked functions.
6637 2017-08-01  Richard Biener  <rguenther@suse.de>
6639         * tree-ssa-pre.c (print_pre_expr): Handle NULL expr.
6640         (compute_antic): Seed worklist with exit block predecessors.
6641         * cfganal.c (dfs_find_deadend): For a cycle return the source
6642         of the edge closing it.
6644 2017-08-01  Tamar Christina  <tamar.christina@arm.com>
6646         * config/aarch64/aarch64.c
6647         (aarch64_can_const_movi_rtx_p): Move 0 check.
6649 2017-08-01  Bin Cheng  <bin.cheng@arm.com>
6651         * tree.h (POINTER_TYPE_OVERFLOW_UNDEFINED): Delete.
6652         * fold-const.c (fold_comparison, fold_binary_loc): Delete use of
6653         above macro.
6654         * match.pd: Ditto in address comparison pattern.
6656 2017-08-01  Bin Cheng  <bin.cheng@arm.com>
6658         PR tree-optimization/81627
6659         * tree-predcom.c (prepare_finalizers): Always rewrite into loop
6660         closed ssa form for store-store chain.
6662 2017-08-01  Bin Cheng  <bin.cheng@arm.com>
6664         PR tree-optimization/81620
6665         * tree-predcom.c (add_ref_to_chain): Don't set has_max_use_after
6666         for store-store chain.
6668 2017-08-01  Jakub Jelinek  <jakub@redhat.com>
6670         PR tree-optimization/81588
6671         * tree-ssa-reassoc.c (optimize_range_tests_var_bound): If
6672         ranges[i].in_p, invert comparison code ccode.  For >/>=,
6673         swap rhs1 and rhs2 and comparison code unconditionally,
6674         for </<= don't do that.  Don't swap rhs1/rhs2 again if
6675         ranges[i].in_p, instead invert comparison code ccode if
6676         opcode or oe->rank is BIT_IOR_EXPR.
6678         PR target/80846
6679         * optabs.def (vec_extract_optab, vec_init_optab): Change from
6680         a direct optab to conversion optab.
6681         * optabs.c (expand_vector_broadcast): Use convert_optab_handler
6682         with GET_MODE_INNER as last argument instead of optab_handler.
6683         * expmed.c (extract_bit_field_1): Likewise.  Use vector from
6684         vector extraction if possible and optab is available.
6685         * expr.c (store_constructor): Use convert_optab_handler instead
6686         of optab_handler.  Use vector initialization from smaller
6687         vectors if possible and optab is available.
6688         * tree-vect-stmts.c (vectorizable_load): Likewise.
6689         * doc/md.texi (vec_extract, vec_init): Document that the optabs
6690         now have two modes.
6691         * config/i386/i386.c (ix86_expand_vector_init): Handle expansion
6692         of vec_init from half-sized vectors with the same element mode.
6693         * config/i386/sse.md (ssehalfvecmode): Add V4TI case.
6694         (ssehalfvecmodelower, ssescalarmodelower): New mode attributes.
6695         (reduc_plus_scal_v8df, reduc_plus_scal_v4df, reduc_plus_scal_v2df,
6696         reduc_plus_scal_v16sf, reduc_plus_scal_v8sf, reduc_plus_scal_v4sf,
6697         reduc_<code>_scal_<mode>, reduc_umin_scal_v8hi): Add element mode
6698         after mode in gen_vec_extract* calls.
6699         (vec_extract<mode>): Renamed to ...
6700         (vec_extract<mode><ssescalarmodelower>): ... this.
6701         (vec_extract<mode><ssehalfvecmodelower>): New expander.
6702         (rotl<mode>3, rotr<mode>3, <shift_insn><mode>3, ashrv2di3): Add
6703         element mode after mode in gen_vec_init* calls.
6704         (VEC_INIT_HALF_MODE): New mode iterator.
6705         (vec_init<mode>): Renamed to ...
6706         (vec_init<mode><ssescalarmodelower>): ... this.
6707         (vec_init<mode><ssehalfvecmodelower>): New expander.
6708         * config/i386/mmx.md (vec_extractv2sf): Renamed to ...
6709         (vec_extractv2sfsf): ... this.
6710         (vec_initv2sf): Renamed to ...
6711         (vec_initv2sfsf): ... this.
6712         (vec_extractv2si): Renamed to ...
6713         (vec_extractv2sisi): ... this.
6714         (vec_initv2si): Renamed to ...
6715         (vec_initv2sisi): ... this.
6716         (vec_extractv4hi): Renamed to ...
6717         (vec_extractv4hihi): ... this.
6718         (vec_initv4hi): Renamed to ...
6719         (vec_initv4hihi): ... this.
6720         (vec_extractv8qi): Renamed to ...
6721         (vec_extractv8qiqi): ... this.
6722         (vec_initv8qi): Renamed to ...
6723         (vec_initv8qiqi): ... this.
6724         * config/rs6000/vector.md (VEC_base_l): New mode attribute.
6725         (vec_init<mode>): Renamed to ...
6726         (vec_init<mode><VEC_base_l>): ... this.
6727         (vec_extract<mode>): Renamed to ...
6728         (vec_extract<mode><VEC_base_l>): ... this.
6729         * config/rs6000/paired.md (vec_initv2sf): Renamed to ...
6730         (vec_initv2sfsf): ... this.
6731         * config/rs6000/altivec.md (splitter, altivec_copysign_v4sf3,
6732         vec_unpacku_hi_v16qi, vec_unpacku_hi_v8hi, vec_unpacku_lo_v16qi,
6733         vec_unpacku_lo_v8hi, mulv16qi3, altivec_vreve<mode>2): Add
6734         element mode after mode in gen_vec_init* calls.
6735         * config/aarch64/aarch64-simd.md (vec_init<mode>): Renamed to ...
6736         (vec_init<mode><Vel>): ... this.
6737         (vec_extract<mode>): Renamed to ...
6738         (vec_extract<mode><Vel>): ... this.
6739         * config/aarch64/iterators.md (Vel): New mode attribute.
6740         * config/s390/s390.c (s390_expand_vec_strlen, s390_expand_vec_movstr):
6741         Add element mode after mode in gen_vec_extract* calls.
6742         * config/s390/vector.md (non_vec_l): New mode attribute.
6743         (vec_extract<mode>): Renamed to ...
6744         (vec_extract<mode><non_vec_l>): ... this.
6745         (vec_init<mode>): Renamed to ...
6746         (vec_init<mode><non_vec_l>): ... this.
6747         * config/s390/s390-builtins.def (s390_vlgvb, s390_vlgvh, s390_vlgvf,
6748         s390_vlgvf_flt, s390_vlgvg, s390_vlgvg_dbl): Add element mode after
6749         vec_extract mode.
6750         * config/arm/iterators.md (V_elem_l): New mode attribute.
6751         * config/arm/neon.md (vec_extract<mode>): Renamed to ...
6752         (vec_extract<mode><V_elem_l>): ... this.
6753         (vec_extractv2di): Renamed to ...
6754         (vec_extractv2didi): ... this.
6755         (vec_init<mode>): Renamed to ...
6756         (vec_init<mode><V_elem_l>): ... this.
6757         (reduc_plus_scal_<mode>, reduc_plus_scal_v2di, reduc_smin_scal_<mode>,
6758         reduc_smax_scal_<mode>, reduc_umin_scal_<mode>,
6759         reduc_umax_scal_<mode>, neon_vget_lane<mode>, neon_vget_laneu<mode>):
6760         Add element mode after gen_vec_extract* calls.
6761         * config/mips/mips-msa.md (vec_init<mode>): Renamed to ...
6762         (vec_init<mode><unitmode>): ... this.
6763         (vec_extract<mode>): Renamed to ...
6764         (vec_extract<mode><unitmode>): ... this.
6765         * config/mips/loongson.md (vec_init<mode>): Renamed to ...
6766         (vec_init<mode><unitmode>): ... this.
6767         * config/mips/mips-ps-3d.md (vec_initv2sf): Renamed to ...
6768         (vec_initv2sfsf): ... this.
6769         (vec_extractv2sf): Renamed to ...
6770         (vec_extractv2sfsf): ... this.
6771         (reduc_plus_scal_v2sf, reduc_smin_scal_v2sf, reduc_smax_scal_v2sf):
6772         Add element mode after gen_vec_extract* calls.
6773         * config/mips/mips.md (unitmode): New mode iterator.
6774         * config/spu/spu.c (spu_expand_prologue, spu_allocate_stack,
6775         spu_builtin_extract): Add element mode after gen_vec_extract* calls.
6776         * config/spu/spu.md (inner_l): New mode attribute.
6777         (vec_init<mode>): Renamed to ...
6778         (vec_init<mode><inner_l>): ... this.
6779         (vec_extract<mode>): Renamed to ...
6780         (vec_extract<mode><inner_l>): ... this.
6781         * config/sparc/sparc.md (veltmode): New mode iterator.
6782         (vec_init<VMALL:mode>): Renamed to ...
6783         (vec_init<VMALL:mode><VMALL:veltmode>): ... this.
6784         * config/ia64/vect.md (vec_initv2si): Renamed to ...
6785         (vec_initv2sisi): ... this.
6786         (vec_initv2sf): Renamed to ...
6787         (vec_initv2sfsf): ... this.
6788         (vec_extractv2sf): Renamed to ...
6789         (vec_extractv2sfsf): ... this.
6790         * config/powerpcspe/vector.md (VEC_base_l): New mode attribute.
6791         (vec_init<mode>): Renamed to ...
6792         (vec_init<mode><VEC_base_l>): ... this.
6793         (vec_extract<mode>): Renamed to ...
6794         (vec_extract<mode><VEC_base_l>): ... this.
6795         * config/powerpcspe/paired.md (vec_initv2sf): Renamed to ...
6796         (vec_initv2sfsf): ... this.
6797         * config/powerpcspe/altivec.md (splitter, altivec_copysign_v4sf3,
6798         vec_unpacku_hi_v16qi, vec_unpacku_hi_v8hi, vec_unpacku_lo_v16qi,
6799         vec_unpacku_lo_v8hi, mulv16qi3): Add element mode after mode in
6800         gen_vec_init* calls.
6802 2017-08-01  Richard Biener  <rguenther@suse.de>
6804         PR tree-optimization/81297
6805         * tree-vrp.c (get_single_symbol): Remove assert, instead drop
6806         TREE_OVERFLOW from INTEGER_CSTs.
6808 2017-07-31  Segher Boessenkool  <segher@kernel.crashing.org>
6810         * config/rs6000/rs6000.c (enum rs6000_reg_type): Delete trailing comma.
6812 2017-07-31  Carl Love  <cel@us.ibm.com>
6814         * config/rs6000/rs6000-c: Add support for built-in functions
6815         vector signed char vec_xl_be (signed long long, signed char *);
6816         vector unsigned char vec_xl_be (signed long long, unsigned char *);
6817         vector signed int vec_xl_be (signed long long, signed int *);
6818         vector unsigned int vec_xl_be (signed long long, unsigned int *);
6819         vector signed long long vec_xl_be (signed long long, signed long long *);
6820         vector unsigned long long vec_xl_be (signed long long, unsigned long long *);
6821         vector signed short vec_xl_be (signed long long, signed short *);
6822         vector unsigned short vec_xl_be (signed long long, unsigned short *);
6823         vector double vec_xl_be (signed long long, double *);
6824         vector float vec_xl_be (signed long long, float *);
6825         * config/rs6000/altivec.h (vec_xl_be): Add #define.
6826         * config/rs6000/rs6000-builtin.def (XL_BE_V16QI, XL_BE_V8HI, XL_BE_V4SI)
6827         XL_BE_V2DI, XL_BE_V4SF, XL_BE_V2DF, XL_BE): Add definitions
6828         for the builtins.
6829         * config/rs6000/rs6000.c (altivec_expand_xl_be_builtin): Add function.
6830         (altivec_expand_builtin): Add switch statement to call
6831         altivec_expand_xl_be for each builtin.
6832         (altivec_init_builtins): Add def_builtin for _builtin_vsx_le_be_v8hi,
6833         __builtin_vsx_le_be_v4si, __builtin_vsx_le_be_v2di,
6834         __builtin_vsx_le_be_v4sf, __builtin_vsx_le_be_v2df,
6835         __builtin_vsx_le_be_v16qi.
6836         * doc/extend.texi: Update the built-in documentation file for the
6837         new built-in functions.
6839 2017-07-31  Uros Bizjak  <ubizjak@gmail.com>
6841         PR target/25967
6842         * config/i386/i386.c (ix86_allocate_stack_slots_for_args):
6843         New function.
6844         (TARGET_ALLOCATE_STACK_SLOTS_FOR_ARGS): Define.
6846 2017-07-31  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
6848         * config.gcc: Add z14.
6849         * config/s390/driver-native.c (s390_host_detect_local_cpu): Add
6850         CPU model numbers for z13s and z14.
6851         * config/s390/s390-c.c (s390_resolve_overloaded_builtin): Replace
6852         arch12 with z14.
6853         * config/s390/s390-opts.h (enum processor_type): Rename
6854         PROCESSOR_ARCH12 to PROCESSOR_3906_Z14.
6855         * config/s390/s390.c (processor_table): Add field for CPU name to
6856         be passed to Binutils.
6857         (s390_asm_output_machine_for_arch): Use the new field in
6858         processor_table for Binutils.
6859         (s390_expand_builtin): Replace arch12 with z14.
6860         (s390_issue_rate): Rename PROCESSOR_ARCH12 to PROCESSOR_3906_Z14.
6861         (s390_get_sched_attrmask): Likewise.
6862         (s390_get_unit_mask): Likewise.
6863         * config/s390/s390.opt: Add z14 to processor_type enum.
6865 2017-07-31  Martin Jambor  <mjambor@suse.cz>
6867         PR hsa/81477
6868         * ipa-fnsummary.c (ipa_fn_summary_generate): Set versionable
6869         regardless of optimization level.
6871 2017-07-31  Jan Hubicka <hubicka@ucw.cz>
6872             Martin Liska  <mliska@suse.cz>
6874         * predict.def: Remove old comment and adjust probability.
6875         * gimplify.c (should_warn_for_implicit_fallthrough): Ignore
6876         PREDICT statements.
6878 2017-07-31  Uros Bizjak  <ubizjak@gmail.com>
6880         PR target/25967
6881         * config/i386/i386.c (ix86_function_naked): New function.
6882         (ix86_can_use_return_insn_p): Return false for naked functions.
6883         (ix86_expand_prologue): Skip prologue for naked functions.
6884         (ix86_expand_epilogue): Skip epilogue for naked functions
6885         and emit trap instruction.
6886         (ix86_warn_func_return): New function.
6887         (ix86_attribute_table): Add "naked" attribute specification.
6888         (TARGET_WARN_FUNC_RETURN): Define.
6889         * doc/extend.texi (x86 Function Attributes) <naked>: Document it.
6891 2017-07-31  Martin Liska  <mliska@suse.cz>
6893         * gimple-pretty-print.c (dump_gimple_label): Never dump BB info.
6894         (dump_gimple_bb_header): Always dump BB info.
6895         (pp_cfg_jump): Do not append info about BB when dumping a jump.
6897 2017-07-31  Martin Liska  <mliska@suse.cz>
6899         PR sanitize/81530
6900         * convert.c (convert_to_integer_1): Guard condition with flag_sanitize_p
6901         also with current_function_decl non-null equality.
6903 2017-07-31  Jakub Jelinek  <jakub@redhat.com>
6905         PR sanitizer/81604
6906         * ubsan.c (ubsan_type_descriptor): For UBSAN_PRINT_ARRAY don't
6907         change type to the element type, instead add eltype variable and
6908         use it where we are interested in the element type.
6910         PR tree-optimization/81603
6911         * ipa-polymorphic-call.c
6912         (ipa_polymorphic_call_context::ipa_polymorphic_call_context): Perform
6913         offset arithmetic in offset_int, bail out if the resulting bit offset
6914         doesn't fit into shwi.
6916 2017-07-31  Martin Liska  <mliska@suse.cz>
6918         * gimplify.c (mostly_copy_tree_r): Remove Java specific hunk.
6919         (gimplify_save_expr): Fix comment.
6921 2017-07-30  H.J. Lu  <hongjiu.lu@intel.com>
6923         PR target/79793
6924         * config/i386/i386.c (ix86_function_arg): Update arguments for
6925         exception handler.
6926         (ix86_compute_frame_layout): Set the initial stack offset to
6927         INCOMING_FRAME_SP_OFFSET.  Update red-zone offset with
6928         INCOMING_FRAME_SP_OFFSET.
6929         (ix86_expand_epilogue): Don't pop the 'ERROR_CODE' off the
6930         stack before exception handler returns.
6931         * config/i386/i386.h (INCOMING_FRAME_SP_OFFSET): Add the
6932         the 'ERROR_CODE' for exception handler.
6934 2017-07-30  Uros Bizjak  <ubizjak@gmail.com>
6936         * config/i386/i386.h (ASM_PRINTF_EXTENSIONS): New macro.
6937         (ASM_OUTPUT_REG_PUSH): Rewrite with new operand modifiers.
6938         (ASM_OUTPUT_REG_POP): Ditto.
6939         * config/i386/i386.c (ix86_asm_output_function_label): Use fputs
6940         instead of asm_fprintf to output pure string.
6942 2017-07-29  Jakub Jelinek  <jakub@redhat.com>
6944         * debug.h (struct gcc_debug_hooks): Add IMPLICIT argument
6945         to imported_module_or_decl hook.
6946         (debug_nothing_tree_tree_tree_bool): Remove.
6947         (debug_nothing_tree_tree_tree_bool_bool): New declaration.
6948         * debug.c (do_nothing_debug_hooks): Use
6949         debug_nothing_tree_tree_tree_bool_bool instead of
6950         debug_nothing_tree_tree_tree_bool.
6951         * vmsdbgout.c (vmsdbg_debug_hooks): Likewise.
6952         * dbxout.c (dbx_debug_hooks, xcoff_debug_hooks): Likewise.
6953         * sdbout.c (sdb_debug_hooks): Likewise.
6954         * dwarf2out.c (dwarf2_lineno_debug_hooks): Likewise.
6955         (gen_namespace_die): Add DW_AT_export_symbols attribute if
6956         langhook wants it.
6957         (dwarf2out_imported_module_or_decl): Add IMPLICIT argument,
6958         if true, -gdwarf-5 and decl will have DW_AT_export_symbols
6959         attribute, don't add anything.
6961 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
6963         * fold-const.c (fold_build1_stat_loc): Remove _stat from name.
6964         (fold_build2_stat_loc): Likewise.
6965         (fold_build3_stat_loc): Likewise.
6966         * fold-const.h (fold_build1, fold_build2, fold_build3): Adjust.
6967         (fold_build1_loc): Remove macro.
6968         (fold_build2_loc): Likewise.
6969         (fold_build3_loc): Likewise.
6971 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
6973         * gimple.c (gimple_build_debug_bind_stat): Remove _stat from name.
6974         (gimple_build_debug_bind_source_stat): Likewise.
6975         * gimple.h (gimple_build_debug_bind): Remove macro.
6976         (gimple_build_debug_bind_source): Likewise.
6978 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
6980         * bitmap.c (bitmap_alloc): Adjust.
6981         (bitmap_gc_alloc): Likewise.
6982         * bitmap.h (bitmap_initialize_stat): Remove _stat from name.
6984 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
6986         * bitmap.c (bitmap_obstack_alloc_stat): Rename to bitmap_alloc.
6987         (bitmap_gc_alloc_stat): Rename to bitmap_gc_alloc.
6988         * bitmap.h (bitmap_obstack_alloc_stat): Adjust prototype.
6989         (bitmap_gc_alloc_stat): Likewise.
6990         (BITMAP_ALLOC, BITMAP_GGC_ALLOC): Adjust.
6992 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
6994         * rtl.c (shallow_copy_rtx_stat): Remove _stat from name.
6995         * rtl.h (shallow_copy_rtx): Remove macro.
6997 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
6999         * emit-rtl.c (gen_raw_REG): Adjust.
7000         * gengenrtl.c (gendef): Likewise.
7001         * rtl.c (rtx_alloc_stat): Remove _stat from name.
7002         * rtl.h (rtx_alloc): Remove macro.
7004 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
7006         * tree.c (build_tree_list_vec_stat): Remove _stat from name.
7007         (build_tree_list_stat): Likewise.
7008         * tree.h (build_tree_list): Remove macro.
7009         (build_tree_list_vec): Likewise.
7011 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
7013         * tree.c (make_vector_stat): Remove _stat from name.
7014         (build_vector_stat): Likewise.
7015         * tree.h (make_vector_stat): Remove macro.
7016         (build_vector_stat): Likewise.
7018 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
7020         * tree.h (build_var_debug_value): Remove prototype.
7022 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
7024         * tree.c (tree_cons_stat): Remove _stat from name.
7025         * tree.h (tree_cons): Remove macro.
7027 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
7029         * tree.c (build_vl_exp_stat): Remove _stat from name.
7030         * tree.h (build_vl_exp): Remove macro.
7032 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
7034         * tree.c (build_decl_stat): Remove _stat from name.
7035         * tree.h (build_decl): Remove macro.
7037 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
7039         * gimple.c (gimple_build_with_ops_stat): Adjust.
7040         (gimple_alloc_stat): Remove _stat from name.
7041         * gimple.h (gimple_alloc): Remove macro.
7043 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
7045         * tree.c (make_tree_vec_stat): Remove _stat from name.
7046         (grow_tree_vec_stat): Likewise.
7047         * tree.h (make_tree_vec_stat): Adjust prototype.
7048         (grow_tree_vec_stat): Likewise.
7049         (make_tree_vec): Remove macro.
7050         (grow_tree_vec): Likewise.
7052 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
7054         * fold-const.c (fold_build1_stat_loc): Adjust.
7055         (fold_build2_stat_loc): Likewise.
7056         (fold_build3_stat_loc): Likewise.
7057         * tree.c (build0_stat): Remove _stat from name.
7058         (build1_stat): Likewise.
7059         (build2_stat): Likewise.
7060         (build3_stat): Likewise.
7061         (build4_stat): Likewise.
7062         (build5_stat): Likewise.
7063         * tree.h (build1_loc): Remove macro, and rename _stat function
7064         to this.
7065         (build2_loc): Likewise.
7066         (build3_loc): Likewise.
7067         (build4_loc): Likewise.
7068         (build5_loc): Likewise.
7070 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
7072         * tree.c (make_int_cst_stat): Remove _stat from name.
7073         * tree.h (make_int_cst_stat): Adjust prototype.
7074         (make_int_cst): Remove macro.
7076 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
7078         * tree.c (make_tre_binfo_stat): Remove _stat from name.
7079         * tree.h (make_tree_binfo_stat): Adjust prototype.
7080         (make_tree_binfo): Remove.
7082 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
7084         * tree.c (copy_node_stat): Rename to copy_node.
7085         (build_distinct_type_copy): Adjust.
7086         * tree.h (copy_node_stat): Adjust prototype.
7087         (copy_node): Remove macro.
7089 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
7091         * tree.c (make_node_stat): rename to make_node.
7092         (build_tree_list_stat): Adjust.
7093         (build0_stat): Likewise.
7094         (build2_stat): Likewise.
7095         (build3_stat): Likewise.
7096         (build4_stat): Likewise.
7097         (build5_stat): Likewise.
7098         (build_decl_stat): Likewise.
7099         * tree.h (make_node_stat): Adjust prototype.
7100         (make_node): remove macro.
7102 2017-07-28  Peter Bergner  <bergner@vnet.ibm.com>
7104         * config/rs6000/ppc-auxv.h (PPC_FEATURE2_DARN): New define.
7105         (PPC_FEATURE2_SCV): Likewise.
7106         * config/rs6000/rs6000.c (cpu_supports_info): Use them.
7108 2017-07-28  Tamar Christina  <tamar.christina@arm.com>
7110         * config/aarch64/aarch64.c
7111         (aarch64_internal_mov_immediate): Add new special pattern.
7112         * config/aarch64/aarch64.md (*movdi_aarch64):
7113         Add reg/32bit const mov case.
7115 2017-07-28  Tamar Christina  <tamar.christina@arm.com>
7116             Richard Sandiford <richard.sandiford@linaro.org>
7118         * config/aarch64/aarch64.md (mov<mode>): Generalize.
7119         (*movhf_aarch64, *movsf_aarch64, *movdf_aarch64):
7120         Add integer and movi cases.
7121         (movi-split-hf-df-sf split, fp16): New.
7122         (enabled): Added TARGET_FP_F16INST.
7123         * config/aarch64/iterators.md (GPF_HF): New.
7124         * config/aarch64/predicates.md (aarch64_reg_or_fp_float): New.
7126 2017-07-28  Tamar Christina  <tamar.christina@arm.com>
7128         * config/aarch64/aarch64.c
7129         (aarch64_simd_container_mode): Add prototype.
7130         (aarch64_expand_mov_immediate): Add HI support.
7131         (aarch64_reinterpret_float_as_int, aarch64_float_const_rtx_p: New.
7132         (aarch64_can_const_movi_rtx_p): New.
7133         (aarch64_preferred_reload_class):
7134         Remove restrictions of using FP registers for certain SIMD operations.
7135         (aarch64_rtx_costs): Added new cost for CONST_DOUBLE moves.
7136         (aarch64_valid_floating_const): Add integer move validation.
7137         (aarch64_simd_imm_scalar_p): Remove.
7138         (aarch64_output_scalar_simd_mov_immediate): Generalize function.
7139         (aarch64_legitimate_constant_p): Expand list of supported cases.
7140         * config/aarch64/aarch64-protos.h
7141         (aarch64_float_const_rtx_p, aarch64_can_const_movi_rtx_p): New.
7142         (aarch64_reinterpret_float_as_int): New.
7143         (aarch64_simd_imm_scalar_p): Remove.
7144         * config/aarch64/constraints.md (Uvi): New.
7145         (Dd): Split into Ds and new Dd.
7146         * config/aarch64/aarch64.md (*movsi_aarch64):
7147         Add SIMD mov case.
7148         (*movdi_aarch64): Add SIMD mov case.
7150 2017-07-28  Bin Cheng  <bin.cheng@arm.com>
7152         * tree-predcom.c: (struct chain): Handle store-store chain in which
7153         stores for elimination only store loop invariant values.
7154         (execute_pred_commoning_chain): Ditto.
7155         (prepare_initializers_chain_store_elim): Ditto.
7156         (prepare_finalizers): Ditto.
7157         (is_inv_store_elimination_chain): New function.
7158         (initialize_root_vars_store_elim_1): New function.
7160 2017-07-28  Bin Cheng  <bin.cheng@arm.com>
7162         * tree-predcom.c: Revise general description of the pass.
7163         (enum chain_type): New enum type for store elimination.
7164         (struct chain): New field supporting store elimination.
7165         (struct component): Ditto.
7166         (dump_chain): Dump store-stores chain.
7167         (release_chain): Release resources.
7168         (split_data_refs_to_components): Compute and create component
7169         contains only stores for elimination.
7170         (get_chain_last_ref_at): New function.
7171         (make_invariant_chain): Initialization.
7172         (make_rooted_chain): Specify chain type in parameter and record it.
7173         (add_looparound_copies): Skip for store-stores chain.
7174         (determine_roots_comp): Compute type of chain and pass it to
7175         make_rooted_chain.
7176         (initialize_root_vars_store_elim_2): New function.
7177         (finalize_eliminated_stores): New function.
7178         (remove_stmt): Handle store for elimination.
7179         (execute_pred_commoning_chain): Execute predictive commoning on
7180         store-store chains.
7181         (determine_unroll_factor): Skip unroll for store-stores chain.
7182         (prepare_initializers_chain_store_elim): New function.
7183         (prepare_initializers_chain): Hanlde store-store chain.
7184         (prepare_finalizers_chain, prepare_finalizers): New function.
7185         (tree_predictive_commoning_loop): Return integer value indicating
7186         if loop is unrolled or lcssa form is corrupted.
7187         (tree_predictive_commoning): Rewrite for lcssa form if necessary.
7189 2017-07-28  Bin Cheng  <bin.cheng@arm.com>
7191         * tree-predcom.c (initialize_root): Delete.
7192         (execute_pred_commoning_chain): Initialize root vars and replace
7193         reference of non-combined chain directly, rather than call above
7194         function.
7196 2017-07-28  Bin Cheng  <bin.cheng@arm.com>
7198         * tree-predcom.c (ref_at_iteration): Add parameter NITERS.  Compute
7199         memory reference to DR at (NITERS + ITERS)-th iteration of loop.
7201 2017-07-28  Bin Cheng  <bin.cheng@arm.com>
7203         * tree-predcom.c (struct chain): New field init_seq.
7204         (release_chain): Release init_seq.
7205         (prepare_initializers_chain): Record intialization stmts in above
7206         field.
7207         (insert_init_seqs): New function.
7208         (tree_predictive_commoning_loop): Call insert_init_seqs.
7210 2017-07-28  Bin Cheng  <bin.cheng@arm.com>
7212         * tree-predcom.c (determine_roots_comp): Skip trivial components.
7214 2017-07-28  Richard Biener  <rguenther@suse.de>
7216         * match.pd: Remove superfluous :c.
7217         * genmatch.c (simplify::id): Add member.
7218         (lower_commutative, lower_opt_convert, lower_cond, lower_for):
7219         Copy id.
7220         (current_id): New global.
7221         (dt_node::parent): Move from ...
7222         (dt_operand::parent): ... here.  Add for_id member.
7223         (is_a_helper <dt_operand *>::test): DT_TRUE is also a dt_operand.
7224         (decision_tree::find_node): Relax order requirement when
7225         merging DT_TRUE nodes to ones inbetween the current simplify
7226         and the one we try to merge with.  Add diagnostic whenever
7227         we need to enforce pattern order by not merging.
7228         (decision_tree::insert): Set current_id.
7229         (decision_tree::print_node): Dump parent node and for_id.
7230         (parser::last_id): Add member.
7231         (parser::push_simplify): Assign unique id.
7232         (parser::parser): Initialize last_id.
7234 2017-07-28  Martin Liska  <mliska@suse.cz>
7236         PR sanitizer/81340
7237         * sanopt.c (sanitize_rewrite_addressable_params): Set VALUE_EXPR after
7238         gimple_build_debug_bind.
7240 2017-07-28  Richard Biener  <rguenther@suse.de>
7242         PR tree-optimization/81502
7243         * match.pd: Add pattern combining BIT_INSERT_EXPR with
7244         BIT_FIELD_REF.
7245         * tree-cfg.c (verify_expr): Verify types of BIT_FIELD_REF
7246         size/pos operands.
7247         (verify_gimple_assign_ternary): Likewise for BIT_INSERT_EXPR pos.
7248         * gimple-fold.c (maybe_canonicalize_mem_ref_addr): Use bitsizetype
7249         for BIT_FIELD_REF args.
7250         * fold-const.c (make_bit_field_ref): Likewise.
7251         * tree-vect-stmts.c (vectorizable_simd_clone_call): Likewise.
7253 2017-07-28  Jakub Jelinek  <jakub@redhat.com>
7255         PR sanitizer/80998
7256         * sanopt.c (pass_sanopt::execute): Handle IFN_UBSAN_PTR.
7257         * tree-ssa-alias.c (call_may_clobber_ref_p_1): Likewise.
7258         * flag-types.h (enum sanitize_code): Add SANITIZER_POINTER_OVERFLOW.
7259         Or it into SANITIZER_UNDEFINED.
7260         * ubsan.c: Include gimple-fold.h and varasm.h.
7261         (ubsan_expand_ptr_ifn): New function.
7262         (instrument_pointer_overflow): New function.
7263         (maybe_instrument_pointer_overflow): New function.
7264         (instrument_object_size): Formatting fix.
7265         (pass_ubsan::execute): Call instrument_pointer_overflow
7266         and maybe_instrument_pointer_overflow.
7267         * internal-fn.c (expand_UBSAN_PTR): New function.
7268         * ubsan.h (ubsan_expand_ptr_ifn): Declare.
7269         * sanitizer.def (__ubsan_handle_pointer_overflow,
7270         __ubsan_handle_pointer_overflow_abort): New builtins.
7271         * tree-ssa-tail-merge.c (merge_stmts_p): Handle IFN_UBSAN_PTR.
7272         * internal-fn.def (UBSAN_PTR): New internal function.
7273         * opts.c (sanitizer_opts): Add pointer-overflow.
7274         * lto-streamer-in.c (input_function): Handle IFN_UBSAN_PTR.
7275         * fold-const.c (build_range_check): Compute pointer range check in
7276         integral type if pointer arithmetics would be needed.  Formatting
7277         fixes.
7279 2017-07-28  Martin Liska  <mliska@suse.cz>
7281         PR sanitizer/81460
7282         * sanopt.c (sanitize_rewrite_addressable_params): Do not rewrite
7283         parameters that are of a variable-length.
7285 2017-07-28  Sebastian Huber  <sebastian.huber@embedded-brains.de>
7287         * config.gcc (powerpc-*-rtems*): Remove rs6000/eabi.h.  Add
7288         rs6000/biarch64.h.
7289         * config/rs6000/rtems.h (ASM_DECLARE_FUNCTION_SIZE): New macro.
7290         (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Likewise.
7291         (CRT_CALL_STATIC_FUNCTION): Likewise.
7292         (ASM_DEFAULT_SPEC): New define.
7293         (ASM_SPEC32): Likewise.
7294         (ASM_SPEC64): Likewise.
7295         (ASM_SPEC_COMMON): Likewise.
7296         (ASM_SPEC): Likewise.
7297         (INVALID_64BIT): Likewise.
7298         (LINK_OS_DEFAULT_SPEC): Likewise.
7299         (LINK_OS_SPEC32): Likewise.
7300         (LINK_OS_SPEC64): Likewise.
7301         (POWERPC_LINUX): Likewise.
7302         (PTRDIFF_TYPE): Likewise.
7303         (RESTORE_FP_PREFIX): Likewise.
7304         (RESTORE_FP_SUFFIX): Likewise.
7305         (SAVE_FP_PREFIX): Likewise.
7306         (SAVE_FP_SUFFIX): Likewise.
7307         (SIZE_TYPE): Likewise.
7308         (SUBSUBTARGET_OVERRIDE_OPTIONS): Likewise.
7309         (TARGET_64BIT): Likewise.
7310         (TARGET_64BIT): Likewise.
7311         (TARGET_AIX): Likewise.
7312         (WCHAR_TYPE_SIZE): Likewise.
7313         (WCHAR_TYPE): Undefine.
7314         (TARGET_OS_CPP_BUILTINS): Add 64-bit PowerPC defines.
7315         (CPP_OS_DEFAULT_SPEC): Use previous CPP_OS_RTEMS_SPEC.
7316         (CPP_OS_RTEMS_SPEC): Delete.
7317         (SUBSUBTARGET_EXTRA_SPECS): Remove cpp_os_rtems.  Add
7318         asm_spec_common, asm_spec32, asm_spec64, link_os_spec32, and
7319         link_os_spec64.
7320         * config/rs6000/t-rtems: Add mcpu=e6500/m64 multilibs.
7322 2017-07-28  Jakub Jelinek  <jakub@redhat.com>
7324         PR tree-optimization/81578
7325         * tree-parloops.c (build_new_reduction): Bail out if
7326         reduction_code isn't one of the standard OpenMP reductions.
7327         Move the details printing after that decision.
7329 2017-07-27  Peter Bergner  <bergner@vnet.ibm.com>
7331         * config/rs6000/predicates.md (volatile_mem_operand): Remove code
7332         related to reload_in_progress.
7333         (splat_input_operand): Likewise.
7334         * config/rs6000/rs6000-protos.h (rs6000_secondary_memory_needed_rtx):
7335         Delete prototype.
7336         * config/rs6000/rs6000.c (machine_function): Remove sdmode_stack_slot
7337         field.
7338         (TARGET_EXPAND_TO_RTL_HOOK): Delete.
7339         (TARGET_INSTANTIATE_DECLS): Likewise.
7340         (legitimate_indexed_address_p): Delete reload_in_progress code.
7341         (rs6000_debug_legitimate_address_p): Likewise.
7342         (rs6000_eliminate_indexed_memrefs): Likewise.
7343         (rs6000_emit_le_vsx_store): Likewise.
7344         (rs6000_emit_move_si_sf_subreg): Likewise.
7345         (rs6000_emit_move): Likewise.
7346         (register_to_reg_type): Likewise.
7347         (rs6000_pre_atomic_barrier): Likewise.
7348         (rs6000_machopic_legitimize_pic_address): Likewise.
7349         (rs6000_allocate_stack_temp): Likewise.
7350         (rs6000_address_for_fpconvert): Likewise.
7351         (rs6000_address_for_altivec): Likewise.
7352         (rs6000_secondary_memory_needed_rtx): Delete function.
7353         (rs6000_check_sdmode): Likewise.
7354         (rs6000_alloc_sdmode_stack_slot): Likewise.
7355         (rs6000_instantiate_decls): Likewise.
7356         * config/rs6000/rs6000.h (SECONDARY_MEMORY_NEEDED_RTX): Delete.
7357         * config/rs6000/rs6000.md (splitter for *movsi_got_internal):
7358         Delete reload_in_progress.
7359         (*vec_reload_and_plus_<mptrsize>): Likewise.
7360         * config/rs6000/vsx.md (vsx_mul_v2di): Likewise.
7361         (vsx_div_v2di): Likewise.
7362         (vsx_udiv_v2di): Likewise.
7364 2017-07-27  Peter Bergner  <bergner@vnet.ibm.com>
7366         * config/rs6000/rs6000.opt (mlra): Replace with stub.
7367         * config/rs6000/rs6000-cpus.def (POWERPC_MASKS): Delete OPTION_MASK_LRA.
7368         * config/rs6000/rs6000.c (TARGET_LRA_P): Delete.
7369         (rs6000_debug_reg_global): Delete print of LRA status.
7370         (rs6000_option_override_internal): Delete dead LRA related code.
7371         (rs6000_lra_p): Delete function.
7372         * doc/invoke.texi (RS/6000 and PowerPC Options): Delete -mlra.
7374 2017-07-27  Sebastian Huber  <sebastian.huber@embedded-brains.de>
7376         * config.gcc (riscv*-*-elf*): Add (riscv*-*-rtems*).
7377         * config/riscv/rtems.h: New file.
7379 2017-07-27  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
7380             Sudakshina Das  <sudi.das@arm.com>
7382         * config/aarch64/aarch64.md
7383         (define_split for and<mode>3nr_compare): Move
7384         non aarch64_logical_operand to a register.
7385         (define_split for and_<SHIFT:optab><mode>3nr_compare0): Move non
7386         register immediate operand to a register.
7387         * config/aarch64/predicates.md (aarch64_mov_imm_operand): New.
7389 2017-07-27  Peter Bergner  <bergner@vnet.ibm.com>
7391         PR middle-end/81564
7392         * tree-cfg.c (group_case_labels_stmt): Handle already deleted blocks.
7394 2017-07-27  Richard Biener  <rguenther@suse.de>
7396         PR tree-optimization/81573
7397         PR tree-optimization/81494
7398         * tree-vect-loop.c (vect_create_epilog_for_reduction): Handle
7399         multi defuse cycle case.
7401 2017-07-27  Richard Biener  <rguenther@suse.de>
7403         PR tree-optimization/81571
7404         * tree-vect-slp.c (vect_build_slp_tree): Properly verify reduction
7405         PHIs.
7407 2017-07-27  Eric Botcazou  <ebotcazou@adacore.com>
7409         * config/sparc/sparc.c (sparc_option_override): Set MASK_FSMULD flag
7410         earlier and only if MASK_FPU is set.  Adjust formatting.
7412 2017-07-27  Martin Liska  <mliska@suse.cz>
7414         * opt-functions.awk: Add validation of value of Init.
7415         * optc-gen.awk: Pass new argument.
7417 2017-07-27  Martin Liska  <mliska@suse.cz>
7419         * auto-profile.c (autofdo_source_profile::update_inlined_ind_target):
7420         Fix wrong condition.
7422 2017-07-27  Martin Liska  <mliska@suse.cz>
7424         * auto-profile.c (afdo_annotate_cfg): Assign zero counts to
7425         BBs and edges seen by autoFDO.
7427 2017-07-27  Richard Biener  <rguenther@suse.de>
7429         PR tree-optimization/81502
7430         * tree-ssa.c (non_rewritable_lvalue_p): Handle BIT_INSERT_EXPR
7431         with incompatible but same sized type.
7432         (execute_update_addresses_taken): Likewise.
7434 2017-07-27  James Greenhalgh  <james.greenhalgh@arm.com>
7436         * tree-ssa-loop-ch.c (pass_ch::process_loop_p): Guard on
7437         flag_tree_loop_vectorize rather than flag_tree_vectorize.
7439 2017-07-27  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
7441         PR target/81534
7442         * config/s390/s390.md ("*atomic_compare_and_swap<mode>_1")
7443         ("*atomic_compare_and_swapdi_2", "*atomic_compare_and_swapsi_3"):
7444         Change s_operand to memory_operand.
7446 2017-07-27  Richard Sandiford  <richard.sandiford@linaro.org>
7448         * config/rs6000/rs6000-protos.h (rs6000_emit_le_vsx_permute): Declare.
7449         * config/rs6000/rs6000.c (rs6000_gen_le_vsx_permute): Replace with...
7450         (rs6000_emit_le_vsx_permute): ...this.  Take the destination as input.
7451         Emit instructions rather than returning an expression.  Handle TFmode
7452         and KFmode by casting to TImode.
7453         (rs6000_emit_le_vsx_load): Update to use rs6000_emit_le_vsx_permute.
7454         (rs6000_emit_le_vsx_store): Likewise.
7455         * config/rs6000/vsx.md (VSX_TI): New iterator.
7456         (*vsx_le_permute_<mode>): Use it instead of VSX_LE_128.
7457         (*vsx_le_undo_permute_<mode>): Likewise.
7458         (*vsx_le_perm_load_<mode>): Use rs6000_emit_le_vsx_permute to
7459         emit the split sequence.
7460         (*vsx_le_perm_store_<mode>): Likewise.
7462 2017-07-27  Jakub Jelinek  <jakub@redhat.com>
7464         PR tree-optimization/81555
7465         PR tree-optimization/81556
7466         * tree-ssa-reassoc.c (rewrite_expr_tree): Add NEXT_CHANGED argument,
7467         if true, force CHANGED for the recursive invocation.
7468         (reassociate_bb): Remember original length of ops array, pass
7469         len != orig_len as NEXT_CHANGED in rewrite_expr_tree call.
7471         * attribs.c (decl_attributes): Imply noinline, noclone and no_icf
7472         attributes for noipa attribute.  For naked attribute use
7473         lookup_attribute first before lookup_attribute_spec.
7474         * final.c (rest_of_handle_final): Disable IPA RA for functions with
7475         noipa attribute.
7476         * ipa-visibility.c (non_local_p): Fix comment typos.  Return true
7477         for functions with noipa attribute.
7478         (cgraph_externally_visible_p): Return true for functions with noipa
7479         attribute.
7480         * cgraph.c (cgraph_node::get_availability): Return AVAIL_INTERPOSABLE
7481         for functions with noipa attribute.
7482         * doc/extend.texi: Document noipa function attribute.
7483         * tree-ssa-structalias.c (refered_from_nonlocal_fn): Set *nonlocal_p
7484         also for functions with noipa attribute.
7485         (ipa_pta_execute): Set nonlocal_p also for nodes with noipa attribute.
7487 2017-07-26  Andrew Pinski  <apinski@cavium.com>
7489         * config/aarch64/aarch64.c (thunderx_vector_cost): Decrease cost of
7490         vec_unalign_load_cost and vec_unalign_store_cost.
7492 2017-07-26  Michael Meissner  <meissner@linux.vnet.ibm.com>
7494         * config/rs6000/rs6000-cpus.def (ISA_2_7_MASKS_SERVER): Delete
7495         -mvsx-small-integer option.
7496         (ISA_3_0_MASKS_IEEE): Likewise.
7497         (OTHER_VSX_VECTOR_MASKS): Likewise.
7498         (POWERPC_MASKS): Likewise.
7499         * config/rs6000/rs6000.opt (-mvsx-small-integer): Likewise.
7500         * config/rs6000/rs6000.c (rs6000_hard_regno_mode_ok): Simplify
7501         code, only testing for DImode being allowed in non-VSX floating
7502         point registers.
7503         (rs6000_init_hard_regno_mode_ok): Change TARGET_VSX_SMALL_INTEGER
7504         to TARGET_P8_VECTOR test.  Remove redundant VSX test inside of
7505         another VSX test.
7506         (rs6000_option_override_internal): Delete -mvsx-small-integer.
7507         (rs6000_expand_vector_set): Change TARGET_VSX_SMALL_INTEGER to
7508         TARGET_P8_VECTOR test.
7509         (rs6000_secondary_reload_simple_move): Likewise.
7510         (rs6000_preferred_reload_class): Delete TARGET_VSX_SMALL_INTEGER,
7511         since TARGET_P9_VECTOR was already tested.
7512         (rs6000_opt_masks): Remove -mvsx-small-integer.
7513         * config/rs6000/vsx.md (vsx_extract_<mode>): Delete
7514         TARGET_VSX_SMALL_INTEGER, since a test for TARGET_P9_VECTOR was
7515         used.
7516         (vsx_extract_<mode>_p9): Delete TARGET_VSX_SMALL_INTEGER, since a
7517         test for TARGET_VEXTRACTUB was used, and that uses
7518         TARGET_P9_VECTOR.
7519         (p9 extract splitter): Likewise.
7520         (vsx_extract_<mode>_di_p9): Likewise.
7521         (vsx_extract_<mode>_store_p9): Likewise.
7522         (vsx_extract_si): Delete TARGET_VSX_SMALL_INTEGER, since a test
7523         for TARGET_P9_VECTOR was used.  Delete code that is now dead with
7524         the elimination of TARGET_VSX_SMALL_INTEGER.
7525         (vsx_extract_<mode>_p8): Likewise.
7526         (vsx_ext_<VSX_EXTRACT_I:VS_scalar>_fl_<FL_CONV:mode>): Likewise.
7527         (vsx_ext_<VSX_EXTRACT_I:VS_scalar>_ufl_<FL_CONV:mode>): Likewise.
7528         (vsx_set_<mode>_p9): Likewise.
7529         (vsx_set_v4sf_p9): Likewise.
7530         (vsx_set_v4sf_p9_zero): Likewise.
7531         (vsx_insert_extract_v4sf_p9): Likewise.
7532         (vsx_insert_extract_v4sf_p9_2): Likewise.
7533         * config/rs6000/rs6000.md (sign extend splitter): Change
7534         TARGET_VSX_SMALL_INTEGER to TARGET_P8_VECTOR test.
7535         (floatsi<mode>2_lfiwax_mem): Likewise.
7536         (floatunssi<mode>2_lfiwzx_mem): Likewise.
7537         (float<QHI:mode><FP_ISA3:mode>2): Delete TARGET_VSX_SMALL_INTEGER,
7538         since a test for TARGET_P9_VECTOR was used.
7539         (float<QHI:mode><FP_ISA3:mode>2_internal): Likewise.
7540         (floatuns<QHI:mode><FP_ISA3:mode>2): Likewise.
7541         (floatuns<QHI:mode><FP_ISA3:mode>2_internal): Likewise.
7542         (fix_trunc<mode>si2): Change TARGET_VSX_SMALL_INTEGER to
7543         TARGET_P8_VECTOR test.
7544         (fix_trunc<mode>si2_stfiwx): Likewise.
7545         (fix_trunc<mode>si2_internal): Likewise.
7546         (fix_trunc<SFDF:mode><QHI:mode>2): Delete
7547         TARGET_VSX_SMALL_INTEGER, since a test for TARGET_P9_VECTOR was
7548         used.
7549         (fix_trunc<SFDF:mode><QHI:mode>2_internal): Likewise.
7550         (fixuns_trunc<mode>si2): Change TARGET_VSX_SMALL_INTEGER to
7551         TARGET_P8_VECTOR test.
7552         (fixuns_trunc<mode>si2_stfiwx): Likewise.
7553         (fixuns_trunc<SFDF:mode><QHI:mode>2): Delete
7554         TARGET_VSX_SMALL_INTEGER, since a test for TARGET_P9_VECTOR was
7555         used.
7556         (fixuns_trunc<SFDF:mode><QHI:mode>2_internal): Likewise.
7557         (fctiw<u>z_<mode>_smallint): Delete TARGET_VSX_SMALL_INTEGER,
7558         since a test for TARGET_P9_VECTOR was used.
7559         (splitter for loading small constants): Likewise.
7561 2017-07-26  Andrew Pinski  <apinski@cavium.com>
7563         * config/aarch64/aarch64.c (thunderx_vector_cost): Fix
7564         vec_fp_stmt_cost.
7566 2017-07-26  H.J. Lu  <hongjiu.lu@intel.com>
7568         PR target/81563
7569         * config/i386/i386.c (sp_valid_at): Properly check CFA offset.
7570         (fp_valid_at): Likewise.
7572 2017-07-26  James Greenhalgh  <james.greenhalgh@arm.com>
7574         * config/aarch64/aarch64.c (cortexa57_addrcost_table): Remove.
7575         (qdf24xx_addrcost_table): Likewise.
7576         (cortexa57_tunings): Update to use generic_branch_cost.
7577         (cortexa72_tunings): Likewise.
7578         (cortexa73_tunings): Likewise.
7579         (qdf24xx_tunings): Likewise.
7581 2017-07-26  James Greenhalgh  <james.greenhalgh@arm.com>
7583         * config/aarch64/aarch64.c (cortexa57_branch_cost): Remove.
7584         (thunderx2t99_branch_cost): Likewise.
7585         (cortexa35_tunings): Update to use generic_branch_cost.
7586         (cortexa53_tunings): Likewise.
7587         (cortexa57_tunings): Likewise.
7588         (cortexa72_tunings): Likewise.
7589         (cortexa73_tunings): Likewise.
7590         (thunderx2t99_tunings): Likewise.
7592 2017-07-26  Sebastian Huber  <sebastian.huber@embedded-brains.de>
7594         * config/sparc/sparc.c (dump_target_flag_bits): Dump MASK_FSMULD.
7595         (sparc_option_override): Honour MASK_FSMULD.
7596         * config/sparc/sparc.h (MASK_FEATURES): Add MASK_FSMULD.
7597         * config/sparc/sparc.md (muldf3_extend): Use TARGET_FSMULD.
7598         * config/sparc/sparc.opt (mfsmuld): New option.
7599         * doc/invoke.texi (mfsmuld): Document option.
7601 2017-07-26  Marek Polacek  <polacek@redhat.com>
7603         PR middle-end/70992
7604         * tree.c (build2_stat): Don't set TREE_CONSTANT on divisions by zero.
7606 2017-07-26  Richard Biener  <rguenther@suse.de>
7608         * gimple-match-head.c (do_valueize): Return OP if valueize
7609         returns NULL_TREE.
7610         (get_def): New helper to get at the def stmt of a SSA name
7611         if valueize allows.
7612         * genmatch.c (dt_node::gen_kids_1): Use get_def instead of
7613         do_valueize to get at the def stmt.
7614         (dt_operand::gen_gimple_expr): Simplify do_valueize calls.
7616 2017-07-26  Wilco Dijkstra  <wdijkstr@arm.com>
7618         PR middle-end/46932
7619         * auto-inc-dec.c (parse_add_or_inc): Block autoinc on sfp.
7621 2017-07-26  Martin Liska  <mliska@suse.cz>
7623         PR sanitize/81186
7624         * function.c (expand_function_start): Make expansion of
7625         nonlocal_goto_save_area after parm_birth_insn.
7627 2017-07-26  Sebastian Huber  <sebastian.huber@embedded-brains.de>
7629         * config/sparc/sparc.c (sparc_option_override): Remove MASK_FPU
7630         from all CPU target flags enable members.
7632 2017-07-26  Richard Biener  <rguenther@suse.de>
7634         * genmatch.c (dt_simplify::gen): Make iterator vars const.
7635         (decision_tree::gen): Make 'type' const.
7636         (write_predicate): Likewise.
7638 2017-07-24  Michael Meissner  <meissner@linux.vnet.ibm.com>
7640         * config/rs6000/rs6000.c (rs6000_init_hard_regno_mode_ok):
7641         Eliminate TARGET_UPPER_REGS_{DF,DI,SF} usage.
7642         (rs6000_option_override_internal): Likewise.
7643         (rs6000_expand_vector_set): Likewise.
7644         * config/rs6000/rs6000.h (TARGET_UPPER_REGS_DF): Delete.
7645         (TARGET_UPPER_REGS_SF): Likewise.
7646         (TARGET_UPPER_REGS_DI): Likewise.
7647         (TARGET_VEXTRACTUB): Eliminate TARGET_UPPER_REGS_{DF,DI,SF}.
7648         (TARGET_DIRECT_MOVE_64BIT): Likewise.
7649         * config/rs6000/rs6000.md (ALTIVEC_DFORM): Likewise.
7650         (float<QHI:mode><FP_ISA3:mode>2_internal): Likewise.
7651         (Splitters for DI constants in Altivec registers): Likewise.
7652         * config/rs6000/vsx.md (vsx_set_<mode>_p9): Likewise.
7653         (vsx_set_v4sf_p9): Likewise.
7654         (vsx_set_v4sf_p9_zero): Likewise.
7655         (vsx_insert_extract_v4sf_p9): Likewise.
7656         (vsx_insert_extract_v4sf_p9_2): Likewise.
7658 2017-07-25  Carl Love  <cel@us.ibm.com>
7660         * doc/extend.texi: Update the built-in documentation file for the
7661         existing built-in functions
7662         vector signed char vec_cnttz (vector signed char);
7663         vector unsigned char vec_cnttz (vector unsigned char);
7664         vector signed short vec_cnttz (vector signed short);
7665         vector unsigned short vec_cnttz (vector unsigned short);
7666         vector signed int vec_cnttz (vector signed int);
7667         vector unsigned int vec_cnttz (vector unsigned int);
7668         vector signed long long vec_cnttz (vector signed long long);
7669         vector unsigned long long vec_cnttz (vector unsigned long long);
7671 2017-07-25  Andrew Pinski  <apinski@cavium.com>
7673         * tree-ssa-uninit.c (warn_uninitialized_vars): Don't warn about memory
7674         accesses where the use is for the first operand of a BIT_INSERT.
7676 2017-07-25  Jim Wilson  <jim.wilson@linaro.org>
7678         PR bootstrap/81521
7679         * config/i386/winnt-cxx.c (i386_pe_adjust_class_at_definition): Look
7680         for FUNCTION_DECLs in TYPE_FIELDS rather than TYPE_METHODS.
7682 2017-07-25  Jim Wilson  <jim.wilson@linaro.org>
7684         * config/i386/gstabs.h: Delete.
7685         * config/i386/openbsd.h, config/i386/t-openbsd: Likewise.
7687 2017-07-25  Uros Bizjak  <ubizjak@gmail.com>
7689         * config/i386/i386.c (ix86_decompose_address): Do not check for
7690         register RTX when looking at index_reg or base_reg.
7691         * config/i386/i386.h (INCOMING_RETURN_ADDR_RTX): Use stack_pointer_rtx.
7693 2017-07-25  Eric Botcazou  <ebotcazou@adacore.com>
7695         * gimple.c (gimple_assign_set_rhs_with_ops): Do not ask gsi_replace
7696         to update EH info here.
7698 2017-07-25  Alexander Monakov  <amonakov@ispras.ru>
7700         * match.pd ((X * CST1) * CST2): Simplify to X * (CST1 * CST2).
7702 2017-07-25  Alexander Monakov  <amonakov@ispras.ru>
7704         * match.pd ((X * CST) * Y): Reassociate to (X * Y) * CST.
7706 2017-07-25  Torsten Duwe  <duwe@suse.de>
7708         * common.opt: Introduce -fpatchable-function-entry
7709         command line option, and its variables function_entry_patch_area_size
7710         and function_entry_patch_area_start.
7711         * opts.c (common_handle_option): Add -fpatchable_function_entry_ case,
7712         including a two-value parser.
7713         * target.def (print_patchable_function_entry): New target hook.
7714         * targhooks.h (default_print_patchable_function_entry): New function.
7715         * targhooks.c (default_print_patchable_function_entry): Likewise.
7716         * toplev.c (process_options): Switch off IPA-RA if
7717         patchable function entries are being generated.
7718         * varasm.c (assemble_start_function): Look at the
7719         patchable-function-entry command line switch and current
7720         function attributes and maybe generate NOP instructions by
7721         calling the print_patchable_function_entry hook.
7722         * doc/extend.texi: Document patchable_function_entry attribute.
7723         * doc/invoke.texi: Document -fpatchable_function_entry
7724         command line option.
7725         * doc/tm.texi.in (TARGET_ASM_PRINT_PATCHABLE_FUNCTION_ENTRY):
7726         New target hook.
7727         * doc/tm.texi: Re-generate.
7729 2017-07-25  Jakub Jelinek  <jakub@redhat.com>
7731         PR target/81532
7732         * config/i386/constraints.md (Yd, Ye): Use ALL_SSE_REGS for
7733         TARGET_AVX512DQ rather than TARGET_AVX512BW.
7735 2017-07-25  Tamar Christina  <tamar.christina@arm.com>
7737         * config/arm/parsecpu.awk (all_cores): Remove duplicates.
7739 2017-07-25  Richard Biener  <rguenther@suse.de>
7741         PR tree-optimization/81455
7742         * tree-ssa-loop-unswitch.c (find_loop_guard): Make sure to
7743         not walk in cycles when looking for guards.
7745 2017-07-25  Richard Biener  <rguenther@suse.de>
7747         PR tree-optimization/81529
7748         * tree-vect-stmts.c (process_use): Disregard live induction PHIs
7749         when optimizing backedge uses.
7751 2017-07-25  David Edelsohn  <dje.gcc@gmail.com>
7753         * dwarf2asm.c (dw2_asm_output_nstring): Encode double quote
7754         character for AIX.
7755         * dwarf2out.c (output_macinfo): Copy debug_line_section_label
7756         to dl_section_ref.  On AIX, append an expression to subtract
7757         the size of the section length to dl_section_ref.
7759 2017-07-25  Segher Boessenkool  <segher@kernel.crashing.org>
7761         * configure.ac: If any of the config.* scripts fail, exit 1.
7762         * configure: Regenerate.
7764 2017-07-25  Richard Biener  <rguenther@suse.de>
7766         PR middle-end/81546
7767         * tree-ssa-operands.c (verify_imm_links): Remove cap on number
7768         of immediate uses, be more verbose on errors.
7770 2017-07-25  Richard Biener  <rguenther@suse.de>
7772         PR tree-optimization/81510
7773         * tree-vect-loop.c (vect_is_simple_reduction): When the
7774         reduction stmt is not inside the loop bail out.
7776 2017-07-25  Richard Biener  <rguenther@suse.de>
7778         PR tree-optimization/81303
7779         * tree-vect-loop-manip.c (vect_loop_versioning): Build
7780         profitability check against LOOP_VINFO_NITERSM1.
7782 2017-07-25  Alexander Monakov  <amonakov@ispras.ru>
7784         * domwalk.c (cmp_bb_postorder): Simplify.
7785         (sort_bbs_postorder): New function.  Use it...
7786         (dom_walker::walk): ...here to optimize common cases.
7788 2017-07-25  Martin Liska  <mliska@suse.cz>
7790         PR ipa/81520
7791         * ipa-visibility.c (function_and_variable_visibility): Make the
7792         redirection just on target that supports aliasing.
7793         Fix GNU coding style.
7795 2017-07-25  Sebastian Huber  <sebastian.huber@embedded-brains.de>
7797         PR libgcc/61152
7798         * config/aarch64/rtems.h: Add GCC Runtime Library Exception.
7799         Format changes.
7800         * config/arm/rtems.h: Likewise.
7801         * config/bfin/rtems.h: Likewise.
7802         * config/i386/rtemself.h: Likewise.
7803         * config/lm32/rtems.h: Likewise.
7804         * config/m32c/rtems.h: Likewise.
7805         * config/m68k/rtemself.h: Likewise.
7806         * config/microblaze/rtems.h: Likewise.
7807         * config/mips/rtems.h: Likewise.
7808         * config/moxie/rtems.h: Likewise.
7809         * config/nios2/rtems.h: Likewise.
7810         * config/powerpcspe/rtems.h: Likewise.
7811         * config/rs6000/rtems.h: Likewise.
7812         * config/rtems.h: Likewise.
7813         * config/sh/rtems.h: Likewise.
7814         * config/sh/rtemself.h: Likewise.
7815         * config/sparc/rtemself.h: Likewise.
7817 2017-07-25  Georg-Johann Lay  <avr@gjlay.de>
7819         PR 81487
7820         * hsa-brig.c (brig_init): Use xasprintf instead of asprintf.
7821         * gimple-pretty-print.c (dump_profile, dump_probability): Same.
7822         * tree-ssa-structalias.c (alias_get_name): Same.
7824 2017-07-25  Bin Cheng  <bin.cheng@arm.com>
7826         PR target/81414
7827         * config/aarch64/cortex-a57-fma-steering.c (analyze): Skip fmul/fmac
7828         instructions if no du chain is found.
7830 2017-07-25  Georg-Johann Lay  <avr@gjlay.de>
7832         * config/avr/avr-log.c (avr_log_vadump) ['T']: Print NULL-TREE.
7834 2017-07-25  Richard Biener  <rguenther@suse.de>
7836         PR middle-end/81505
7837         * fold-const.c (fold_negate_const): TREE_OVERFLOW should be
7838         sticky.
7840 2017-07-24  Michael Meissner  <meissner@linux.vnet.ibm.com>
7842         * config/rs6000/rs6000-cpus.def (ISA_2_6_MASKS_SERVER): Delete
7843         upper-regs options.
7844         (ISA_2_7_MASKS_SERVER): Likewise.
7845         (ISA_3_0_MASKS_IEEE): Likewise.
7846         (OTHER_P8_VECTOR_MASKS): Likewise.
7847         (OTHER_VSX_VECTOR_MASKS): Likewise.
7848         (POWERPC_MASKS): Likewise.
7849         (power7 cpu): Use ISA_2_6_MASKS_SERVER instead of using a
7850         duplicate list of options.
7851         * config/rs6000/rs6000-c.c (rs6000_target_modify_macros): Remove
7852         explicit -mupper-regs options.
7853         * config/rs6000/rs6000.opt (-mvsx-scalar-memory): Delete
7854         -mupper-regs* options.  Delete -mvsx-scalar-memory, which was an
7855         alias for -mupper-regs-df.
7856         * config/rs6000/rs6000.c (rs6000_setup_reg_addr_masks): Likewise.
7857         (rs6000_init_hard_regno_mode_ok): Likewise.
7858         (rs6000_option_override_internal): Likewise.
7859         (rs6000_opt_masks): Likewise.
7860         * config/rs6000/rs6000.h (TARGET_UPPER_REGS_DF): Define upper regs
7861         options in terms of whether -mvsx or -mpower8-vector was used.
7862         (TARGET_UPPER_REGS_DI): Likewise.
7863         (TARGET_UPPER_REGS_SF): Likewise.
7864         * doc/invoke.texi (RS/6000 and PowerPC Options): Delete the
7865         -mupper-regs-* options.
7867 2017-07-24  Segher Boessenkool  <segher@kernel.crashing.org>
7869         * passes.c (emergency_dump_function): Print some empty lines and a
7870         header before the RTL dump.
7872 2017-07-24  Segher Boessenkool  <segher@kernel.crashing.org>
7874         * cfgrtl.c (rtl_dump_bb): Don't call NEXT_INSN on NULL.
7876 2017-07-24  Wilco Dijkstra  <wdijkstr@arm.com>
7878         PR target/79041
7879         * config/aarch64/aarch64.c (aarch64_classify_symbol):
7880         Avoid SYMBOL_SMALL_ABSOLUTE for literals with pc-relative literals.
7882 2017-07-24  Carl Love  <cel@us.ibm.com>
7884         * config/rs6000/rs6000-c.c: Add support for built-in functions
7885         vector float vec_extract_fp32_from_shorth (vector unsigned short);
7886         vector float vec_extract_fp32_from_shortl (vector unsigned short);
7887         * config/rs6000/altivec.h (vec_extract_fp_from_shorth,
7888         vec_extract_fp_from_shortl): Add defines for the two builtins.
7889         * config/rs6000/rs6000-builtin.def (VEXTRACT_FP_FROM_SHORTH,
7890         VEXTRACT_FP_FROM_SHORTL): Add BU_P9V_OVERLOAD_1 and BU_P9V_VSX_1
7891         new builtins.
7892         * config/rs6000/vsx.md vsx_xvcvhpsp): Add define_insn.
7893         (vextract_fp_from_shorth, vextract_fp_from_shortl): Add define_expands.
7894         * doc/extend.texi: Update the built-in documentation file for the
7895         new built-in function.
7897 2017-07-24  Jakub Jelinek  <jakub@redhat.com>
7899         PR bootstrap/81521
7900         * tree.def: Remove TYPE_METHODS documentation, adjust TYPE_FIELDS
7901         documentation.
7902         * doc/generic.texi: Likewise.
7903         * config/i386/winnt-cxx.c (i386_pe_adjust_class_at_definition): Look
7904         for FUNCTION_DECLs in TYPE_FIELDS rather than TYPE_METHODS.
7906 2017-07-24  Jackson Woodruff  <jackson.woodruff@arm.com>
7908         * config/aarch64/aarch64-simd.md (aarch64_mla_elt_merge<mode>): New.
7909         (aarch64_mls_elt_merge<mode>): Likewise.
7911 2017-07-23  Krister Walfridsson  <krister.walfridsson@gmail.com>
7913         * config.gcc (*-*-netbsd*): Remove check for NetBSD versions not
7914         having __cxa_atexit.
7916 2017-07-23  Michael Collison  <michael.collison@arm.com>
7918         * config/arm/arm.c (arm_option_override): Deprecate
7919         use of -mstructure-size-boundary.
7920         * config/arm/arm.opt: Deprecate -mstructure-size-boundary.
7921         * doc/invoke.texi: Deprecate -mstructure-size-boundary.
7923 2017-07-23  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
7925         PR target/80695
7926         * config/rs6000/rs6000.c (rs6000_builtin_vectorization_cost):
7927         Reduce cost estimate for direct moves.
7929 2017-07-23  Uros Bizjak  <ubizjak@gmail.com>
7931         PR target/80569
7932         * config/i386/i386.c (ix86_option_override_internal): Disable
7933         BMI, BMI2 and TBM instructions for -m16.
7935 2017-07-21  Carl Love  <cel@us.ibm.com>
7937         * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Add
7938         ALTIVEC_BUILTIN_VMULESW, ALTIVEC_BUILTIN_VMULEUW,
7939         ALTIVEC_BUILTIN_VMULOSW, ALTIVEC_BUILTIN_VMULOUW entries.
7940         * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin,
7941         builtin_function_type): Add ALTIVEC_BUILTIN_* case statements.
7942         * config/rs6000/altivec.md (MVULEUW, VMULESW, VMULOUW,
7943         VMULOSW): New enum "unspec" values.
7944         (altivec_vmuleuw, altivec_vmulesw, altivec_vmulouw,
7945         altivec_vmulosw): New patterns.
7946         * config/rs6000/rs6000-builtin.def (VMLEUW, VMULESW, VMULOUW,
7947         VMULOSW): Add definitions.
7949 2017-07-21  Jim Wilson  <jim.wilson@linaro.org>
7951         * config/aarch64/aarch64-cores.def (falkor): Add AARCH64_FL_RDMA.
7952         (qdf24xx): Likewise.
7953         * config/aarch64/aarch64-options-extensions.def (rdma); New.
7954         * config/aarch64/aarch64.h (AARCH64_FL_RDMA): New.
7955         (AARCH64_FL_V8_1): Renumber.
7956         (AARCH64_FL_FOR_ARCH8_1): Add AARCH64_FL_RDMA.
7957         (AARCH64_ISA_RDMA): Use AARCH64_FL_RDMA.
7958         * config/aarch64/arm_neon.h: Use +rdma instead of arch=armv8.1-a.
7959         * doc/invoke.texi (AArch64 Options): Mention +rmda in -march docs.  Add
7960         rdma to feature modifiers list.
7962 2017-07-21  Yury Gribov  <tetra2005@gmail.com>
7964         PR middle-end/56727
7965         * ipa-visibility (function_and_variable_visibility): Convert
7966         recursive PLT call to direct call if appropriate.
7968 2017-07-21  Andrew Pinski  <apinski@cavium.com>
7970         * tree-ssa-sccvn.c (vn_nary_op_eq): Check BIT_INSERT_EXPR's
7971         operand 1 to see if the types precision matches.
7972         * fold-const.c (operand_equal_p): Likewise.
7974 2017-07-21  Richard Biener  <rguenther@suse.de>
7976         PR tree-optimization/81303
7977         * tree-vect-data-refs.c (vect_get_peeling_costs_all_drs): Pass
7978         in datarefs vector.  Allow NULL dr0 for no peeling cost estimate.
7979         (vect_peeling_hash_get_lowest_cost): Adjust.
7980         (vect_enhance_data_refs_alignment): Likewise.  Use
7981         vect_get_peeling_costs_all_drs to compute the penalty for no
7982         peeling to match up costs.
7984 2017-07-21  Richard Biener  <rguenther@suse.de>
7986         PR tree-optimization/81500
7987         * tree-vect-loop.c (vect_is_simple_reduction): Properly fail if
7988         we didn't identify a reduction path.
7990 2017-07-21  Tom de Vries  <tom@codesourcery.com>
7991             Cesar Philippidis  <cesar@codesourcery.com>
7993         PR gcov-profile/81442
7994         * config/nvptx/nvptx.c (nvptx_goacc_reduction_init): Add missing edge
7995         probabilities.
7997 2017-07-21  Tom de Vries  <tom@codesourcery.com>
7999         PR lto/81430
8000         * config/nvptx/nvptx.c (nvptx_override_options_after_change): New
8001         function.
8002         (TARGET_OVERRIDE_OPTIONS_AFTER_CHANGE): Define to
8003         nvptx_override_options_after_change.
8005 2017-07-21  Ulrich Drepper  <drepper@redhat.com>
8007         * dwarf2out.c (output_file_names): Avoid double testing for
8008         dwarf_version >= 5.
8010 2017-07-21  Georg-Johann Lay  <avr@gjlay.de>
8012         * doc/invoke.texi (AVR Built-in Functions): Re-layout section.
8014 2016-07-21  Jan Hubicka  <hubicka@ucw.cz>
8016         * cfgcleanup.c (flow_find_cross_jump): Do not crossjump across
8017         hot/cold regions.
8018         (try_crossjump_to_edge): Do not punt on partitioned functions.
8020 2016-07-21  Jan Hubicka  <hubicka@ucw.cz>
8022         * bb-reorder.c (find_rarely_executed_basic_blocks_and_crossing_edges):
8023         Put all BBs reachable only via paths crossing cold region to cold
8024         region.
8025         * cfgrtl.c (find_bbs_reachable_by_hot_paths): New function.
8027 2016-07-21  Richard Biener  <rguenther@suse.de>
8029         PR tree-optimization/81303
8030         * tree-vect-loop.c (vect_estimate_min_profitable_iters): Take
8031         into account prologue and epilogue iterations when raising
8032         min_profitable_iters to sth at least covering one vector iteration.
8034 2017-07-21  Tamar Christina  <tamar.christina@arm.com>
8036         * config/arm/arm.c (arm_test_cpu_arch_dat):
8037         Check for overlap.
8039 2017-07-20  Nathan Sidwell  <nathan@acm.org>
8041         Remove TYPE_METHODS.
8042         * tree.h (TYPE_METHODS): Delete.
8043         * dwarf2out.c (gen_member_die): Member fns are on TYPE_FIELDS.
8044         * dbxout.c (dbxout_type_fields): Ignore FUNCTION_DECLs.
8045         (dbxout_type_methods): Scan TYPE_FIELDS.
8046         (dbxout_type): Don't check TYPE_METHODS here.
8047         * function.c (use_register_for_decl): Always ignore register for
8048         class types when not optimizing.
8049         * ipa-devirt.c (odr_types_equivalent_p): Delete TYPE_METHODS scan.
8050         * tree.c (free_lang_data_in_type): Stitch out member functions and
8051         templates from TYPE_FIELDS.
8052         (build_distinct_type_copy, verify_type_variant,
8053         verify_type): Member fns are on TYPE_FIELDS.
8054         * tree-dump.c (dequeue_and_dump): No TYPE_METHODS.
8055         * tree-pretty-print.c (dump_generic_node): Likewise.
8057 2017-07-20  Jakub Jelinek  <jakub@redhat.com>
8059         PR target/80846
8060         * config/i386/i386.c (ix86_expand_vector_init_general): Handle
8061         V2TImode and V4TImode.
8062         (ix86_expand_vector_extract): Likewise.
8063         * config/i386/sse.md (VMOVE): Enable V4TImode even for just
8064         TARGET_AVX512F, instead of only for TARGET_AVX512BW.
8065         (ssescalarmode): Handle V4TImode and V2TImode.
8066         (VEC_EXTRACT_MODE): Add V4TImode and V2TImode.
8067         (*vec_extractv2ti, *vec_extractv4ti): New insns.
8068         (VEXTRACTI128_MODE): New mode iterator.
8069         (splitter for *vec_extractv?ti first element): New.
8070         (VEC_INIT_MODE): New mode iterator.
8071         (vec_init<mode>): Consolidate 3 expanders into one using
8072         VEC_INIT_MODE mode iterator.
8074 2017-07-20  Alexander Monakov  <amonakov@ispras.ru>
8076         * lra-assigns.c (pseudo_compare_func): Fix comparison step based on
8077         non_spilled_static_chain_regno_p.
8079 2017-07-20  Alexander Monakov  <amonakov@ispras.ru>
8081         * gimple-ssa-store-merging.c (sort_by_bitpos): Return 0 on equal bitpos.
8083 2017-07-20  Jan Hubicka  <hubicka@ucw.cz>
8085         * bb-reorder.c (connect_traces): Allow copying of blocks within
8086         single partition.
8088 2017-07-20  Richard Biener  <rguenther@suse.de>
8090         * gimple.h (gimple_phi_result): Add gphi * overload.
8091         (gimple_phi_result_ptr): Likewise.
8092         (gimple_phi_arg): Likewise.  Adjust index assert to only
8093         allow actual argument accesses rather than all slots available
8094         by capacity.
8095         (gimple_phi_arg_def): Add gphi * overload.
8096         * tree-phinodes.c (make_phi_node): Initialize only actual
8097         arguments.
8098         (resize_phi_node): Clear memory not covered by old node,
8099         do not initialize excess argument slots.
8100         (reserve_phi_args_for_new_edge): Initialize new argument slot
8101         completely.
8103 2017-07-20  Bin Cheng  <bin.cheng@arm.com>
8105         PR tree-optimization/81388
8106         Revert r238585:
8107         2016-07-21  Bin Cheng  <bin.cheng@arm.com>
8109         * tree-ssa-loop-niter.c (number_of_iterations_lt_to_ne): Clean up
8110         by removing computation of may_be_zero.
8112 2017-07-18  Jan Hubicka  <hubicka@ucw.cz>
8113             Tom de Vries  <tom@codesourcery.com>
8115         PR middle-end/81030
8116         * cfgbuild.c (find_many_sub_basic_blocks): Update REG_BR_PROB note
8117         when gimple level profile disagrees with what RTL expander did.
8119 2017-07-20  Richard Biener  <rguenther@suse.de>
8121         PR tree-optimization/61171
8122         * tree-vectorizer.h (slp_instance): Add reduc_phis member.
8123         (vect_analyze_stmt): Add slp instance parameter.
8124         (vectorizable_reduction): Likewise.
8125         * tree-vect-loop.c (vect_analyze_loop_operations): Adjust.
8126         (vect_is_simple_reduction): Deal with chains not detected
8127         as SLP reduction chain, specifically not properly associated
8128         chains containing a mix of plus/minus.
8129         (get_reduction_op): Remove.
8130         (get_initial_defs_for_reduction): Simplify, pass in whether
8131         this is a reduction chain, pass in the SLP node for the PHIs.
8132         (vect_create_epilog_for_reduction): Get the SLP instance as
8133         arg and adjust.
8134         (vectorizable_reduction): Get the SLP instance as arg.
8135         During analysis remember the SLP node with the PHIs in the
8136         instance.  Simplify getting at the vectorized reduction PHIs.
8137         * tree-vect-slp.c (vect_slp_analyze_node_operations): Pass
8138         through SLP instance.
8139         (vect_slp_analyze_operations): Likewise.
8140         * tree-vect-stms.c (vect_analyze_stmt): Likewise.
8141         (vect_transform_stmt): Likewise.
8143 2017-07-20  Tom de Vries  <tom@codesourcery.com>
8145         PR tree-optimization/81489
8146         * gimple-ssa-isolate-paths.c (find_implicit_erroneous_behavior): Move
8147         read of phi arg location to before loop that modifies phi.
8149 2017-07-20  Naveen H.S  <Naveen.Hurugalawadi@cavium.com>
8151         * match.pd (((m1 >/</>=/<= m2) * d -> (m1 >/</>=/<= m2) ? d : 0):
8152         New pattern.
8154 2017-07-19  Jan Hubicka  <hubicka@ucw.cz>
8156         PR middle-end/81331
8157         * except.c (execute): Fix ordering issue.
8159 2018-07-19  Segher Boessenkool  <segher@kernel.crashing.org>
8161         PR rtl-optimization/81423
8162         * combine.c (make_compound_operation_int): Don't try to optimize
8163         the AND of a SUBREG of an LSHIFTRT if that SUBREG is paradoxical.
8165 2017-07-19  Segher Boessenkool  <segher@kernel.crashing.org>
8167         PR rtl-optimization/81423
8168         * simplify-rtx.c (simplify_truncation): Handle truncating an IOR
8169         with a constant that is -1 in the truncated to mode.
8171 2017-07-19  Jan Hubicka  <hubicka@ucw.cz>
8173         * predict.c (propagate_unlikely_bbs_forward): Break out from ...
8174         (determine_unlikely_bbs): ... here.
8175         * predict.h (propagate_unlikely_bbs_forward): Declare.
8176         * cfgexpand.c (pass_expand::execute): Use it.
8177         * bb-reorder.c (sanitize_hot_paths): Do not consider known to be
8178         unlikely edges.
8179         (find_rarely_executed_basic_blocks_and_crossing_edges): Use
8180         propagate_unlikely_bbs_forward.
8182 2017-07-19  Jan Hubicka  <hubicka@ucw.cz>
8184         PR middle-end/81331
8185         * except.c (maybe_add_nop_after_section_switch): New function.
8186         (execute): Use it.
8188 2017-07-19  Tom de Vries  <tom@codesourcery.com>
8190         * gimple.h (gimple_phi_set_arg): Make assert more strict.
8192 2017-07-19  Tom de Vries  <tom@codesourcery.com>
8194         * gimple.h (gimple_phi_arg): Make assert more strict.
8196 2017-07-19  Steven Munroe  <munroesj@gcc.gnu.org>
8198         * config.gcc (powerpc*-*-*): Add mmintrin.h.
8199         * config/rs6000/mmintrin.h: New file.
8200         * config/rs6000/x86intrin.h [__ALTIVEC__]: Include mmintrin.h.
8202 2017-07-19  Jakub Jelinek  <jakub@redhat.com>
8204         PR tree-optimization/81346
8205         * match.pd: Optimize (X - 1U) <= INT_MAX-1U into (int) X > 0.
8207 2017-07-19  Tom de Vries  <tom@codesourcery.com>
8209         * config/nvptx/nvptx.md (VECIM): Add V2DI.
8211 2017-07-19  Tom de Vries  <tom@codesourcery.com>
8213         * config/nvptx/nvptx-modes.def: Add V2DImode.
8214         * config/nvptx/nvptx-protos.h (nvptx_data_alignment): Declare.
8215         * config/nvptx/nvptx.c (nvptx_ptx_type_from_mode): Handle V2DImode.
8216         (nvptx_output_mov_insn): Handle lack of mov.b128.
8217         (nvptx_print_operand): Handle 'H' and 'L' codes.
8218         (nvptx_vector_mode_supported): Allow V2DImode.
8219         (nvptx_preferred_simd_mode): New function.
8220         (nvptx_data_alignment): New function.
8221         (TARGET_VECTORIZE_PREFERRED_SIMD_MODE): Redefine to
8222         nvptx_preferred_simd_mode.
8223         * config/nvptx/nvptx.h (STACK_BOUNDARY, BIGGEST_ALIGNMENT): Change from
8224         64 to 128 bits.
8225         (DATA_ALIGNMENT): Define.  Set to nvptx_data_alignment.
8227 2017-07-19  Tom de Vries  <tom@codesourcery.com>
8229         * config/nvptx/nvptx-modes.def: New file.  Add V2SImode.
8230         * config/nvptx/nvptx.c (nvptx_ptx_type_from_mode): Handle V2SImode.
8231         (nvptx_vector_mode_supported): New function.  Allow V2SImode.
8232         (TARGET_VECTOR_MODE_SUPPORTED_P): Redefine to nvptx_vector_mode_supported.
8233         * config/nvptx/nvptx.md (VECIM): New mode iterator. Add V2SI.
8234         (mov<VECIM>_insn): New define_insn.
8235         (define_expand "mov<VECIM>): New define_expand.
8237 2017-07-19  Tom de Vries  <tom@codesourcery.com>
8239         * config/nvptx/nvptx.c (nvptx_print_operand): Handle v2 vector mode.
8241 2017-07-19  Jakub Jelinek  <jakub@redhat.com>
8243         PR tree-optimization/81346
8244         * fold-const.h (fold_div_compare, range_check_type): Declare.
8245         * fold-const.c (range_check_type): New function.
8246         (build_range_check): Use range_check_type.
8247         (fold_div_compare): No longer static, rewritten into
8248         a match.pd helper function.
8249         (fold_comparison): Don't call fold_div_compare here.
8250         * match.pd (X / C1 op C2): New optimization using fold_div_compare
8251         as helper function.
8253 2017-07-19  Nathan Sidwell  <nathan@acm.org>
8255         * tree.h (TYPE_MINVAL, TYPE_MAXVAL): Rename to ...
8256         (TYPE_MIN_VALUE_RAW, TYPE_MAX_VALUE_RAW): ... these.
8257         * tree.c (find_decls_types_r, verify_type): Use
8258         TYPE_{MIN,MAX}_VALUE_RAW.
8259         * lto-streamer-out.c (DFS::DFS_write_tree_body): Likewise.
8260         (hash_tree): Likewise.
8261         * tree-streamer-in.c (lto_input_ts_type_non_common_tree_pointers):
8262         Likewise.
8263         * tree-streamer-out.c (write_ts_type_non_common_tree_pointers):
8264         Likewise.
8266 2017-07-18  Tom de Vries  <tom@codesourcery.com>
8268         PR middle-end/81464
8269         * omp-expand.c (expand_omp_for_static_chunk): Handle
8270         equal-argument loop exit phi.
8272 2017-07-18  Uros Bizjak  <ubizjak@gmail.com>
8274         PR target/81471
8275         * config/i386/i386.md (rorx_immediate_operand): New mode attribute.
8276         (*bmi2_rorx<mode>3_1): Use rorx_immediate_operand as
8277         operand 2 predicate.
8278         (*bmi2_rorxsi3_1_zext): Use const_0_to_31_operand as
8279         operand 2 predicate.
8280         (ror,rol -> rorx splitters): Use const_int_operand as
8281         operand 2 predicate.
8283 2017-06-18  Richard Biener  <rguenther@suse.de>
8285         PR tree-optimization/81410
8286         * tree-vect-stmts.c (vectorizable_load): Properly adjust for
8287         the gap in the ! slp_perm SLP case after each group.
8289 2017-07-18  Jan Hubicka  <hubicka@ucw.cz>
8291         PR middle-end/81463
8292         * cfgloopmanip.c (scale_loop_profile): Watch out for zero frequency
8293         again.
8295 2017-07-18  Jan Hubicka  <hubicka@ucw.cz>
8297         PR middle-end/81462
8298         * predict.c (set_even_probabilities): Cleanup; do not affect
8299         probabilities that are already known.
8300         (combine_predictions_for_bb): Call even when count is set.
8302 2017-07-18  Nathan Sidwell  <nathan@acm.org>
8304         * tree-parloops.c (try_transform_to_exit_first_loop_alt): Use
8305         TYPE_MAX_VALUE.
8307 2017-07-18  Bin Cheng  <bin.cheng@arm.com>
8309         PR target/81408
8310         * tree-ssa-loop-niter.c (number_of_iterations_exit): Dump missed
8311         optimization for loop niter analysis.
8313 2017-07-18  Georg-Johann Lay  <avr@gjlay.de>
8315         PR target/81473
8316         * config/avr/avr.c (avr_optimize_casesi): Don't use
8317         INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX, UINT16_MAX.
8319 2017-07-18  Robin Dapp  <rdapp@linux.vnet.ibm.com>
8321         * tree-vect-data-refs.c (vect_enhance_data_refs_alignment): Remove
8322         body_cost_vec from _vect_peel_extended_info.
8323         (vect_peeling_hash_get_lowest_cost): Do not set body_cost_vec.
8324         (vect_peeling_hash_choose_best_peeling): Remove body_cost_vec and
8325         npeel.
8327 2017-07-18  Bin Cheng  <bin.cheng@arm.com>
8329         * config/arm/arm.c (emit_unlikely_jump): Remove unused var.
8331 2017-07-18  Richard Biener  <rguenther@suse.de>
8333         PR tree-optimization/80620
8334         PR tree-optimization/81403
8335         * tree-ssa-pre.c (phi_translate_1): Clear range and points-to
8336         info when re-using a VN table entry.
8338 2017-07-18  Richard Biener  <rguenther@suse.de>
8340         PR tree-optimization/81418
8341         * tree-vect-loop.c (vectorizable_reduction): Properly compute
8342         vectype_in.  Verify that with lane-reducing reduction operations
8343         we have a single def-use cycle.
8345 2017-07-17  Carl Love  <cel@us.ibm.com>
8347         Revert commit r249424   2017-06-20  Carl Love  <cel@us.ibm.com>
8349         * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Add
8350         ALTIVEC_BUILTIN_VMULESW, ALTIVEC_BUILTIN_VMULEUW,
8351         ALTIVEC_BUILTIN_VMULOSW, ALTIVEC_BUILTIN_VMULOUW entries.
8352         * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin,
8353         builtin_function_type): Add ALTIVEC_BUILTIN_* case statements.
8354         * config/rs6000/altivec.md (MVULEUW, VMULESW, VMULOUW,
8355         VMULOSW): New enum "unspec" values.
8356         (vec_widen_umult_even_v4si, vec_widen_smult_even_v4si,
8357         vec_widen_umult_odd_v4si, vec_widen_smult_odd_v4si,
8358         altivec_vmuleuw, altivec_vmulesw, altivec_vmulouw,
8359         altivec_vmulosw): New patterns.
8360         * config/rs6000/rs6000-builtin.def (VMLEUW, VMULESW, VMULOUW,
8361         VMULOSW): Add definitions.
8362 2017-07-17  Uros Bizjak  <ubizjak@gmail.com>
8364         * config/alpha/alpha.c: Include predict.h.
8366 2017-07-17  Yury Gribov  <tetra2005@gmail.com>
8368         * tree-vrp.c (compare_assert_loc): Fix comparison function
8369         to return predictable results.
8371 2017-07-17  Claudiu Zissulescu  <claziss@synopsys.com>
8373         * config/arc/arc.md (adddi3): Remove support for mexpand-adddi
8374         option.
8375         (subdi3): Likewise.
8376         * config/arc/arc.opt (mexpand-adddi): Deprecate it.
8377         * doc/invoke.texi (mexpand-adddi): Update text.
8379 2017-07-17  Claudiu Zissulescu  <claziss@synopsys.com>
8381         * config/arc/arc.md (clzsi2): Expand to an arc_clzsi2 instruction
8382         that also clobbers the CC register. The old expand code is moved
8383         to ...
8384         (*arc_clzsi2): ... here.
8385         (ctzsi2): Expand to an arc_ctzsi2 instruction that also clobbers
8386         the CC register. The old expand code is moved to ...
8387         (arc_ctzsi2): ... here.
8389 2017-07-17  Claudiu Zissulescu  <claziss@synopsys.com>
8391         * config/arc/arc.opt (mindexed-loads): Use initial value
8392         TARGET_INDEXED_LOADS_DEFAULT.
8393         (mauto-modify-reg): Use initial value
8394         TARGET_AUTO_MODIFY_REG_DEFAULT.
8395         * config/arc/elf.h (TARGET_INDEXED_LOADS_DEFAULT): Define.
8396         (TARGET_AUTO_MODIFY_REG_DEFAULT): Likewise.
8397         * config/arc/linux.h (TARGET_INDEXED_LOADS_DEFAULT): Define.
8398         (TARGET_AUTO_MODIFY_REG_DEFAULT): Likewise.
8400 2017-07-17  Martin Liska  <mliska@suse.cz>
8402         PR sanitizer/81302
8403         * opts.c (finish_options): Do not allow -fgnu-tm
8404         w/ -fsanitize={kernel-,}address.  Say sorry.
8406 2017-07-17  Bin Cheng  <bin.cheng@arm.com>
8408         PR target/81369
8409         * tree-loop-distribution.c (classify_partition): Only assert on
8410         numer of iterations.
8411         (merge_dep_scc_partitions): Delete prameter.  Update function call.
8412         (distribute_loop): Remove code handling loop with unknown niters.
8413         (pass_loop_distribution::execute): Skip loop with unknown niters.
8415 2017-07-17  Bin Cheng  <bin.cheng@arm.com>
8417         PR target/81369
8418         * tree-loop-distribution.c (merge_dep_scc_partitions): Sink call to
8419         function sort_partitions_by_post_order.
8421 2017-07-17  Bin Cheng  <bin.cheng@arm.com>
8423         PR tree-optimization/81374
8424         * tree-loop-distribution.c (pass_loop_distribution::execute): Record
8425         the max index of basic blocks, rather than number of basic blocks.
8427 2017-07-17  Claudiu Zissulescu  <claziss@synopsys.com>
8429         * config/arc/arc-protos.h (arc_legitimate_pc_offset_p): Remove
8430         proto.
8431         (arc_legitimate_pic_operand_p): Likewise.
8432         * config/arc/arc.c (arc_legitimate_pic_operand_p): Remove
8433         function.
8434         (arc_needs_pcl_p): Likewise.
8435         (arc_legitimate_pc_offset_p): Likewise.
8436         (arc_legitimate_pic_addr_p): Remove LABEL_REF case, as this
8437         function is also used in constrains.md.
8438         (arc_legitimate_constant_p): Use arc_legitimate_pic_addr_p to
8439         validate pic constants. Handle CONST_INT, CONST_DOUBLE, MINUS and
8440         PLUS.  Only return true/false in known cases, otherwise assert.
8441         (arc_legitimate_address_p): Remove arc_legitimate_pic_addr_p as it
8442         is already called in arc_legitimate_constant_p.
8443         * config/arc/arc.h (CONSTANT_ADDRESS_P): Consider also LABEL for
8444         pic addresses.
8445         (LEGITIMATE_PIC_OPERAND_P): Use
8446         arc_raw_symbolic_reference_mentioned_p function.
8447         * config/arc/constraints.md (Cpc): Use arc_legitimate_pic_addr_p
8448         function.
8449         (Cal): Likewise.
8450         (C32): Likewise.
8452 2017-07-17  Claudiu Zissulescu  <claziss@synopsys.com>
8453         Andrew Burgess  <andrew.burgess@embecosm.com>
8455         * config/arc/arc-protos.h (arc_compute_function_type): Change prototype.
8456         (arc_return_address_register): New function.
8457         * config/arc/arc.c (arc_handle_fndecl_attribute): New function.
8458         (arc_handle_fndecl_attribute): Add naked attribute.
8459         (TARGET_ALLOCATE_STACK_SLOTS_FOR_ARGS): Define.
8460         (TARGET_WARN_FUNC_RETURN): Likewise.
8461         (arc_allocate_stack_slots_for_args): New function.
8462         (arc_warn_func_return): Likewise.
8463         (machine_function): Change type fn_type.
8464         (arc_compute_function_type): Consider new naked function type,
8465         change function return type.
8466         (arc_must_save_register): Adapt to handle new
8467         arc_compute_function_type's return type.
8468         (arc_expand_prologue): Likewise.
8469         (arc_expand_epilogue): Likewise.
8470         (arc_return_address_regs): Delete.
8471         (arc_return_address_register): New function.
8472         (arc_epilogue_uses): Use above function.
8473         * config/arc/arc.h (arc_return_address_regs): Delete prototype.
8474         (arc_function_type): Change encoding, add naked type.
8475         (ARC_INTERRUPT_P): Change to handle the new encoding.
8476         (ARC_FAST_INTERRUPT_P): Likewise.
8477         (ARC_NORMAL_P): Define.
8478         (ARC_NAKED_P): Likewise.
8479         (arc_compute_function_type): Delete prototype.
8480         * config/arc/arc.md (in_ret_delay_slot): Use
8481         arc_return_address_register function.
8482         (simple_return): Likewise.
8483         (p_return_i): Likewise.
8485 2017-07-17  Jakub Jelinek  <jakub@redhat.com>
8487         PR tree-optimization/81428
8488         * match.pd (X / X -> one): Don't optimize _Fract divisions, as 1
8489         can't be built for those types.
8491 2017-07-17  Georg-Johann Lay  <avr@gjlay.de>
8493         Remove stuff dead since r239246.
8495         * config/avr/avr-arch.h (avr_inform_devices): Remove dead proto.
8496         * config/avr/avr-devices.c (mcu_name, comparator, avr_mcus_str)
8497         (avr_inform_devices): Remove dead stuff.
8499 2017-07-17  Tamar Christina  <tamar.christina@arm.com>
8501         * config/arm/arm_neon.h: Fix softp typo.
8503 2017-07-17  Jakub Jelinek  <jakub@redhat.com>
8505         PR tree-optimization/81365
8506         * tree-ssa-phiprop.c (propagate_with_phi): When considering hoisting
8507         aggregate moves onto bb predecessor edges, make sure there are no
8508         loads that could alias the lhs in between the start of bb and the
8509         loads from *phi.
8511 2017-07-17  Georg-Johann Lay  <avr@gjlay.de>
8513         PR 80929
8514         * config/avr/avr.c (avr_mul_highpart_cost): New static function.
8515         (avr_rtx_costs_1) [TRUNCATE]: Use it to compute mul_highpart cost.
8516         [LSHIFTRT, outer_code = TRUNCATE]: Same.
8518 2017-07-17  Jakub Jelinek  <jakub@redhat.com>
8520         PR tree-optimization/81396
8521         * tree-ssa-math-opts.c (struct symbolic_number): Add n_ops field.
8522         (init_symbolic_number): Initialize it to 1.
8523         (perform_symbolic_merge): Add n_ops from both operands into the new
8524         n_ops.
8525         (find_bswap_or_nop): Don't consider n->n == cmpnop computations
8526         without base_addr as useless if they need more than one operation.
8527         (bswap_replace): Handle !bswap case for NULL base_addr.
8529 2017-07-17  Tom de Vries  <tom@codesourcery.com>
8531         PR target/81069
8532         * config/nvptx/nvptx.c (nvptx_single): Insert diverging branch as late
8533         as possible.
8535 2017-07-17  Sebastian Huber  <sebastian.huber@embedded-brains.de>
8537         * config/sparc/rtemself.h (TARGET_OS_CPP_BUILTINS): Add
8538         conditional builtin define __FIX_LEON3FT_B2BST.
8540 2017-07-17  Daniel Cederman  <cederman@gaisler.com>
8542         * config/sparc/t-rtems: Add mfix-gr712rc multilibs. Replace
8543         MULTILIB_EXCEPTIONS with MULTILIB_REQUIRED. Match -mfix-gr712rc
8544         with -mfix-ut700.
8546 2017-07-16  Eric Botcazou  <ebotcazou@adacore.com>
8548         PR rtl-optimization/81424
8549         * optabs.c (prepare_cmp_insn): Use copy_to_reg instead of force_reg
8550         to remove potential trapping from operands if -fnon-call-exceptions.
8552 2017-07-16  Jan Hubicka  <hubicka@ucw.cz>
8554         * tree-ssa-loop-manip.c (tree_transform_and_unroll_loop): Use
8555         profile_proability for scalling.
8556         * scale_profile_for_vect_loop.c (scale_profile_for_vect_loop): Likewise.
8558 2017-07-16  Jan Hubicka  <hubicka@ucw.cz>
8560         * cgraph.c (cgraph_edge::redirect_call_stmt_to_caller): Cleanup.
8562 2017-07-16  Jan Hubicka  <hubicka@ucw.cz>
8564         * cfgloopmanip.c (scale_loop_profile): Avoid use of REG_BR_PROB_BASE
8565         fixpoint arithmetics.
8567 2017-07-16  Jan Hubicka  <hubicka@ucw.cz>
8569         * tree-ssa-loop-unswitch.c (hoist_guard): Avoid use of REG_BR_PROB_BASE
8570         fixpoint arithmetics.
8572 2017-07-16  Jan Hubicka  <hubicka@ucw.cz>
8574         * asan.c (create_cond_insert_point): Avoid use of REG_BR_PROB_BASE
8575         fixpoint arithmetics.
8577 2017-07-16  Jan Hubicka  <hubicka@ucw.cz>
8579         * profile-count.h (profile_probability::from_reg_br_prob_note,
8580         profile_probability::to_reg_br_prob_note): New functions.
8581         * doc/rtl.texi (REG_BR_PROB_NOTE): Update documentation.
8582         * reg-notes.h (REG_BR_PROB, REG_BR_PRED): Update docs.
8583         * predict.c (probability_reliable_p): Update.
8584         (edge_probability_reliable_p): Update.
8585         (br_prob_note_reliable_p): Update.
8586         (invert_br_probabilities): Update.
8587         (add_reg_br_prob_note): New function.
8588         (combine_predictions_for_insn): Update.
8589         * asan.c (asan_clear_shadow): Update.
8590         * cfgbuild.c (compute_outgoing_frequencies): Update.
8591         * cfgrtl.c (force_nonfallthru_and_redirect): Update.
8592         (update_br_prob_note): Update.
8593         (rtl_verify_edges): Update.
8594         (purge_dead_edges): Update.
8595         (fixup_reorder_chain): Update.
8596         * emit-rtl.c (try_split): Update.
8597         * ifcvt.c (cond_exec_process_insns): Update.
8598         (cond_exec_process_if_block): Update.
8599         (dead_or_predicable): Update.
8600         * internal-fn.c (expand_addsub_overflow): Update.
8601         (expand_neg_overflow): Update.
8602         (expand_mul_overflow): Update.
8603         * loop-doloop.c (doloop_modify): Update.
8604         * loop-unroll.c (compare_and_jump_seq): Update.
8605         * optabs.c (emit_cmp_and_jump_insn_1): Update.
8606         * predict.h: Update.
8607         * reorg.c (mostly_true_jump): Update.
8608         * rtl.h: Update.
8609         * config/aarch64/aarch64.c (aarch64_emit_unlikely_jump): Update.
8610         * config/alpha/alpha.c (emit_unlikely_jump): Update.
8611         * config/arc/arc.c: (emit_unlikely_jump): Update.
8612         * config/arm/arm.c: (emit_unlikely_jump): Update.
8613         * config/bfin/bfin.c (cbranch_predicted_taken_p): Update.
8614         * config/frv/frv.c (frv_print_operand_jump_hint): Update.
8615         * config/i386/i386.c (ix86_expand_split_stack_prologue): Update.
8616         (ix86_print_operand): Update.
8617         (ix86_split_fp_branch): Update.
8618         (predict_jump): Update.
8619         * config/ia64/ia64.c (ia64_print_operand): Update.
8620         * config/mmix/mmix.c (mmix_print_operand): Update.
8621         * config/powerpcspe/powerpcspe.c (output_cbranch): Update.
8622         (rs6000_expand_split_stack_prologue): Update.
8623         * config/rs6000/rs6000.c: Update.
8624         * config/s390/s390.c (s390_expand_vec_strlen): Update.
8625         (s390_expand_vec_movstr): Update.
8626         (s390_expand_cs_tdsi): Update.
8627         (s390_expand_split_stack_prologue): Update.
8628         * config/sh/sh.c (sh_print_operand): Update.
8629         (expand_cbranchsi4): Update.
8630         (expand_cbranchdi4): Update.
8631         * config/sparc/sparc.c (output_v9branch): Update.
8632         * config/spu/spu.c (get_branch_target): Update.
8633         (ea_load_store_inline): Update.
8634         * config/tilegx/tilegx.c (cbranch_predicted_p): Update.
8635         * config/tilepro/tilepro.c: Update.
8637 2017-07-16  Eric Botcazou  <ebotcazou@adacore.com>
8639         * gimplify.c (mostly_copy_tree_r): Revert latest change.
8640         (gimplify_save_expr): Likewise.
8642 2017-07-07  Jan Hubicka  <hubicka@ucw.cz>
8644         * ipa-visibility.c (function_and_variable_visibility): Fix pasto.
8646 2017-07-07  Jan Hubicka  <hubicka@ucw.cz>
8648         * ipa-fnsummary.c (pass_data_ipa_fn_summary): Use
8649         TV_IPA_FNSUMMARY.
8650         * timevar.def (TV_IPA_FNSUMMARY): Define.
8652 2017-07-16  Daniel Cederman  <cederman@gaisler.com>
8654         * config/sparc/sparc.md (divdf3_fix): Add NOP to prevent back
8655         to back store errata sensitive sequence from being generated.
8656         (sqrtdf2_fix): Likewise.
8658 2017-07-07  Jan Hubicka  <hubicka@ucw.cz>
8660         * tree-ssa-threadupdate.c (compute_path_counts,
8661         update_joiner_offpath_counts): Use profile_probability.
8663 2017-07-15  Thomas Preud'homme  <thomas.preudhomme@arm.com>
8665         Revert:
8666         2017-07-14  Thomas Preud'homme  <thomas.preudhomme@arm.com>
8668         * config/arm/arm-c.c (arm_cpu_builtins): Define
8669         __ARM_FEATURE_NUMERIC_MAXMIN solely based on TARGET_VFP5.
8671 2017-07-14  Kelvin Nilsen  <kelvin@gcc.gnu.org>
8673         * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Add
8674         array entries to represent __ieee128 versions of the
8675         scalar_test_data_class, scalar_test_neg, scalar_extract_exp,
8676         scalar_extract_sig, and scalar_insert_exp built-in functions.
8677         (altivec_resolve_overloaded_builtin): Add special case handling
8678         for the __builtin_scalar_insert_exp function, as represented by
8679         the P9V_BUILTIN_VEC_VSIEDP constant.
8680         * config/rs6000/rs6000-builtin.def (VSEEQP): Add scalar extract
8681         exponent support for __ieee128 argument.
8682         (VSESQP): Add scalar extract signature support for __ieee128
8683         argument.
8684         (VSTDCNQP): Add scalar test negative support for __ieee128
8685         argument.
8686         (VSIEQP): Add scalar insert exponent support for __int128 argument
8687         with __ieee128 result.
8688         (VSIEQPF): Add scalar insert exponent support for __ieee128
8689         argument with __ieee128 result.
8690         (VSTDCQP): Add scalar test data class support for __ieee128
8691         argument.
8692         (VSTDCNQP): Add overload support for scalar test negative with
8693         __ieee128 argument.
8694         (VSTDCQP): Add overload support for scalar test data class
8695         __ieee128 argument.
8696         * config/rs6000/vsx.md (UNSPEC_VSX_SXSIG) Replace
8697         UNSPEC_VSX_SXSIGDP.
8698         (UNSPEC_VSX_SIEXPQP): New constant.
8699         (xsxexpqp): New insn for VSX scalar extract exponent quad
8700         precision.
8701         (xsxsigqp): New insn for VSX scalar extract significand quad
8702         precision.
8703         (xsiexpqpf): New insn for VSX scalar insert exponent quad
8704         precision with floating point argument.
8705         (xststdcqp): New expand for VSX scalar test data class quad
8706         precision.
8707         (xststdcnegqp): New expand for VSX scalar test negative quad
8708         precision.
8709         (xststdcqp): New insn to match expansions for VSX scalar test data
8710         class quad precision and VSX scalar test negative quad precision.
8711         * config/rs6000/rs6000.c (rs6000_expand_binop_builtin): Add
8712         special case operand checking to enforce that second operand of
8713         VSX scalar test data class with quad precision argument is a 7-bit
8714         unsigned literal.
8715         * doc/extend.texi (PowerPC AltiVec Built-in Functions): Add
8716         prototypes and descriptions of __ieee128 versions of
8717         scalar_extract_exp, scalar_extract_sig, scalar_insert_exp,
8718         scalar_test_data_class, and scalar_test_neg built-in functions.
8720 2016-07-14  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
8722         PR tree-optimization/81162
8723         * gimple-ssa-strength-reduction.c (replace_mult_candidate): Don't
8724         replace a negate with an add.
8726 2017-07-14  James Greenhalgh  <james.greenhalgh@arm.com>
8728         * doc/invoke.texi (arm/-mcpu): Document +crypto.
8730 2017-07-14  Thomas Preud'homme  <thomas.preudhomme@arm.com>
8732         * config/arm/arm-c.c (arm_cpu_builtins): Define
8733         __ARM_FEATURE_NUMERIC_MAXMIN solely based on TARGET_VFP5.
8735 2017-07-14  Thomas Preud'homme  <thomas.preudhomme@arm.com>
8737         * config/arm/arm-cpus.in (cortex-r52): Add new entry.
8738         (armv8-r): Set ARM Cortex-R52 as default CPU.
8739         * config/arm/arm-tables.opt: Regenerate.
8740         * config/arm/arm-tune.md: Regenerate.
8741         * config/arm/driver-arm.c (arm_cpu_table): Add entry for ARM
8742         Cortex-R52.
8743         * doc/invoke.texi: Mention -mtune=cortex-r52 and availability of fp.dp
8744         extension for -mcpu=cortex-r52.
8746 2017-07-14  Thomas Preud'homme  <thomas.preudhomme@arm.com>
8748         * config/arm/arm-isa.h (isa_bit_FP_ARMv8): Delete enumerator.
8749         (ISA_FP_ARMv8): Define as ISA_FPv5 and ISA_FP_D32.
8750         * config/arm/arm-cpus.in (armv8-r): Define fp.sp as enabling FPv5.
8751         (fp-armv8): Define it as FP_ARMv8 only.
8752         config/arm/arm.h (TARGET_FPU_ARMV8): Delete.
8753         (TARGET_VFP_FP16INST): Define using TARGET_VFP5 rather than
8754         TARGET_FPU_ARMV8.
8755         config/arm/arm.c (arm_rtx_costs_internal): Replace checks against
8756         TARGET_FPU_ARMV8 by checks against TARGET_VFP5.
8757         * config/arm/arm-builtins.c (arm_builtin_vectorized_function): Define
8758         first ARM_CHECK_BUILTIN_MODE definition using TARGET_VFP5 rather
8759         than TARGET_FPU_ARMV8.
8760         * config/arm/arm-c.c (arm_cpu_builtins): Likewise for
8761         __ARM_FEATURE_NUMERIC_MAXMIN macro definition.
8762         * config/arm/arm.md (cmov<mode>): Condition on TARGET_VFP5 rather than
8763         TARGET_FPU_ARMV8.
8764         * config/arm/neon.md (neon_vrint): Likewise.
8765         (neon_vcvt): Likewise.
8766         (neon_<fmaxmin_op><mode>): Likewise.
8767         (<fmaxmin><mode>3): Likewise.
8768         * config/arm/vfp.md (l<vrint_pattern><su_optab><mode>si2): Likewise.
8769         * config/arm/predicates.md (arm_cond_move_operator): Check against
8770         TARGET_VFP5 rather than TARGET_FPU_ARMV8 and fix spacing.
8772 2017-07-14  Jackson Woodruff  <jackson.woodruff@arm.com>
8774         * config/aarch64/aarch64.c (aarch64_print_operand): Move comments
8775         to top of function.
8777 2017-07-14  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
8779         * gimple-ssa-store-merging.c (clear_bit_region): Replace reference to
8780         loop in comment with memset.
8782 2017-07-14  Martin Liska  <mliska@suse.cz>
8784         * cfgexpand.c (expand_gimple_basic_block): Remove dead comment.
8785         * dwarf2out.c (is_java): Remove the function.
8786         (output_pubname): Remove usage of the function.
8787         (lower_bound_default): Remove usage of DW_LANG_Java.
8788         (gen_compile_unit_die): Likewise.
8789         * gcc.c: Remove compiler defaults for .java and .zip files.
8790         * gimple-expr.c (remove_suffix): Change as there's no longer
8791         extension than 4-letter one.
8792         * gimplify.c (mostly_copy_tree_r): Remove Java-special part.
8793         (gimplify_save_expr): Likewise.
8794         * ipa-utils.h (polymorphic_type_binfo_p): Remove the comment
8795         as it's possible even for other languages than Java.
8796         * langhooks.h (struct lang_hooks): Remove Java from a comment.
8797         * lto-opts.c (lto_write_options): Remove reference to Java.
8798         * opts.c (strip_off_ending): Update file extension handling.
8799         * tree-cfg.c (verify_gimple_call): Remove comment with Java.
8800         * tree-eh.c (lower_resx): Likewise.
8801         * tree.c (free_lang_data_in_type): Remove dead code.
8802         (find_decls_types_r): Likewise.
8803         (build_common_builtin_nodes): Remove Java from a comment.
8804         (verify_type): Remove dead code.
8805         * varasm.c (assemble_external): Remove Java from a comment.
8807 2017-07-14  Martin Liska  <mliska@suse.cz>
8809         * opts.c (finish_options): Add quotes.
8810         (common_handle_option): Likewise.
8812 2017-07-14  Martin Liska  <mliska@suse.cz>
8814         * dbxout.c (get_lang_number): Do not handle GNU Pascal.
8815         * dbxout.h (extern void dbxout_stab_value_internal_label_diff):
8816         Remove N_SO_PASCAL.
8817         * dwarf2out.c (lower_bound_default): Do not handle
8818         DW_LANG_Pascal83.
8819         (gen_compile_unit_die): Likewise.
8820         * gcc.c: Remove default extension binding for GNU Pascal.
8821         * stmt.c: Remove Pascal language from a comment.
8822         * xcoffout.c: Likewise.
8824 2017-07-13  David Malcolm  <dmalcolm@redhat.com>
8826         PR c/81405
8827         * diagnostic-show-locus.c (fixit_cmp): New function.
8828         (layout::layout): Sort m_fixit_hints.
8829         (column_range::column_range): Assert that the values are valid.
8830         (struct char_span): New struct.
8831         (correction::overwrite): New method.
8832         (struct source_line): New struct.
8833         (line_corrections::add_hint): Add assertions.  Reimplement memcpy
8834         calls in terms of classes source_line and char_span, and
8835         correction::overwrite.
8836         (selftest::test_overlapped_fixit_printing_2): New function.
8837         (selftest::diagnostic_show_locus_c_tests): Call it.
8839 2017-07-13  Will Schmidt  <will_schmidt@vnet.ibm.com>
8841         * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Return
8842         early if there is no lhs.
8844 2017-07-13  Martin Liska  <mliska@suse.cz>
8846         * dwarf2out.c (gen_pointer_type_die): Remove dead code.
8847         (gen_reference_type_die): Likewise.
8848         * stor-layout.c: Remove Pascal-related comment.
8850 2017-07-13  Martin Liska  <mliska@suse.cz>
8852         * opts.c (finish_options): Add quotes to error messages.
8853         (parse_sanitizer_options): Likewise.
8855 2017-07-13  Thomas Preud'homme  <thomas.preudhomme@arm.com>
8857         * doc/invoke.texi (armv8-r): Document +fp.sp ARMv8-R extension.
8859 2017-07-13  Richard Earnshaw  <rearnsha@arm.com>
8861         * config/arm/vxworks.h (TARGET_ENDIAN_DEFAULT): Define.
8863 2017-07-13  Maxim Ostapenko  <m.ostapenko@samsung.com>
8865         * asan.c (asan_emit_allocas_unpoison): Use ptr_mode for arguments
8866         during expansion.
8867         * builtins.c (expand_asan_emit_allocas_unpoison): Likewise.
8869 2017-07-12  Michael Meissner  <meissner@linux.vnet.ibm.com>
8871         PR target/81193
8872         * config/rs6000/rs6000-c.c (rs6000_cpu_cpp_builtins): If GLIBC
8873         provides the hardware capability bits, define the macro
8874         __BUILTIN_CPU_SUPPORTS__.
8875         * config/rs6000/rs6000.c (cpu_expand_builtin): Generate a warning
8876         if GLIBC does not provide the hardware capability bits.  Add a
8877         gcc_unreachable call if the built-in cpu function is neither
8878         __builtin_cpu_is nor __builtin_cpu_supports.
8879         (rs6000_get_function_versions_dispatcher): Change the warning
8880         that an old GLIBC is used which does not export the capability
8881         bits to be an error.
8882         * doc/extend.texi (target_clones attribute): Document the
8883         restriction that GLIBC 2.23 or newer is needed on the PowerPC.
8884         (PowerPC built-in functions): Document that GLIBC 2.23 or newer is
8885         needed by __builtin_cpu_is and __builtin_cpu_supports.  Document
8886         the macros defined by GCC if the newer GLIBC is available.
8888 2017-07-12  Jeff Law  <law@redhat.com>
8890         * config/riscv/riscv.c: Remove unnecessary includes.  Reorder
8891         remaining includes slightly.
8892         * config/riscv/riscv-builtins.c: Include profile-count.h.
8894 2017-07-12  Georg-Johann Lay  <avr@gjlay.de>
8896         PR target/79883
8897         * config/avr/avr.c (avr_set_current_function): In diagnostic
8898         messages: Quote keywords and (parts of) identifiers.
8899         [WITH_AVRLIBC]: Warn for functions named "ISR", "SIGNAL" or
8900         "INTERUPT".
8902 2017-07-12  Carl Love  <cel@us.ibm.com>
8904         * config/rs6000/rs6000-c.c: Add support for built-in functions
8905         vector bool char vec_revb (vector bool char);
8906         vector bool short vec_revb (vector short char);
8907         vector bool int vec_revb (vector bool int);
8908         vector bool long long vec_revb (vector bool long long);
8909         * doc/extend.texi: Update the built-in documentation file for the
8910         new built-in functions.
8912 2017-07-12  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
8914         * config/s390/s390.md: Remove movcc splitter.
8916 2017-07-12  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
8918         * config/s390/s390.c (s390_rtx_costs): Return proper costs for
8919         load/store on condition.
8921 2017-07-12  Georg-Johann Lay  <avr@gjlay.de>
8923         PR target/81407
8924         * config/avr/avr.c (avr_encode_section_info)
8925         [progmem && !TREE_READONLY]: Error if progmem object needs
8926         constructing.
8928 2017-07-11  Michael Collison  <michael.collison@arm.com>
8930         * config/aarch64/aarch64-simd.md (aarch64_sub<mode>_compare0):
8931         New pattern.
8933 2017-07-11  Carl Love  <cel@us.ibm.com>
8935         * config/rs6000/rs6000-c.c: Add support for builtins
8936         vector unsigned int vec_parity_lsbb (vector signed int);
8937         vector unsigned int vec_parity_lsbb (vector unsigned int);
8938         vector unsigned __int128 vec_parity_lsbb (vector signed __int128);
8939         vector unsigned __int128 vec_parity_lsbb (vector unsigned __int128);
8940         vector unsigned long long vec_parity_lsbb (vector signed long long);
8941         vector unsigned long long vec_parity_lsbb (vector unsigned long long);
8942         * config/rs6000/rs6000-builtin.def (VPARITY_LSBB): Add BU_P9V_OVERLOAD1.
8943         * config/rs6000/altivec.h (vec_parity_lsbb): Add define.
8944         * doc/extend.texi: Update the built-in documentation file for the
8945         new built-in functions.
8947 2017-07-11  David Malcolm  <dmalcolm@redhat.com>
8949         * diagnostic-show-locus.c: Include "gcc-rich-location.h".
8950         (layout::m_primary_loc): New field.
8951         (layout::layout): Initialize new field.  Move location filtering
8952         logic from here to...
8953         (layout::maybe_add_location_range): ...this new method.  Add
8954         support for filtering to just the lines already specified by other
8955         locations.
8956         (layout::will_show_line_p): New method.
8957         (gcc_rich_location::add_location_if_nearby): New method.
8958         (selftest::test_add_location_if_nearby): New test function.
8959         (selftest::diagnostic_show_locus_c_tests): Call it.
8960         * gcc-rich-location.h (gcc_rich_location::add_location_if_nearby):
8961         New method.
8963 2017-07-11  Tom de Vries  <tom@codesourcery.com>
8965         * config/nvptx/nvptx.c (WORKAROUND_PTXJIT_BUG): New macro.
8966         (bb_first_real_insn): New function.
8967         (nvptx_single): Add extra initialization of broadcasted condition
8968         variables.
8970 2017-07-11  Nathan Sidwell  <nathan@acm.org>
8972         * dwarf2out.c (gen_member_die): Remove useless check for anon ctors.
8974 2017-07-11  Georg-Johann Lay  <avr@gjlay.de>
8976         * doc/extend.texi (AVR Function Attributes): Remove weblink to
8977         Binutils doc as TEXI will mess them up.
8978         * doc/invoke.texi (AVR Options): Same here.
8980 2017-07-11  Daniel Cederman  <cederman@gaisler.com>
8982         * config/sparc/sparc.opt (mfix-ut700): New option.
8983         (mfix-gr712rc): Likewise.
8984         (sparc_fix_b2bst): New variable.
8985         * doc/invoke.texi (SPARC options): Document them.
8986         (ARM options): Fix warnings.
8987         * config/sparc/sparc.c (sparc_do_work_around_errata): Insert NOP
8988         instructions to prevent sequences that can trigger the store-store
8989         errata for certain LEON3FT processors.
8990         (pass_work_around_errata::gate): Also test sparc_fix_b2bst.
8991         (sparc_option_override): Set sparc_fix_b2bst appropriately.
8992         * config/sparc/sparc.md (fix_b2bst): New attribute.
8993         (in_branch_delay): Prevent stores in delay slot if fix_b2bst.
8995 2017-07-10  Uros Bizjak  <ubizjak@gmail.com>
8997         PR target/81375
8998         * config/i386/i386.md (divsf3): Add TARGET_SSE to TARGET_SSE_MATH.
8999         (rcpps): Ditto.
9000         (*rsqrtsf2_sse): Ditto.
9001         (rsqrtsf2): Ditto.
9002         (div<mode>3): Macroize insn from divdf3 and divsf3
9003         using MODEF mode iterator.
9005 2017-07-10  Martin Sebor  <msebor@redhat.com>
9007         PR tree-optimization/80397
9008         * gimple-ssa-sprintf.c (format_integer): Use INTEGRAL_TYPE_P()
9009         instead of testing for equality to INTEGER_TYPE.
9011 2017-07-10  Vineet Gupta <vgupta@synopsys.com>
9013         * config.gcc: Remove uclibc from arc target spec.
9015 2017-07-10  Claudiu Zissulescu  <claziss@synopsys.com>
9017         * config/arc/arc.h (ADDITIONAL_REGISTER_NAMES): Define.
9019 2017-07-07  Jan Hubicka  <hubicka@ucw.cz>
9021         PR lto/80838
9022         * lto-wrapper.c (remove_option): New function.
9023         (merge_and_complain): Merge PIC/PIE options more realistically.
9025 2017-07-10  Georg-Johann Lay  <avr@gjlay.de>
9027         Better ISR prologues by supporting GASes __gcc_isr pseudo insn.
9029         PR target/20296
9030         PR target/81268
9031         * configure.ac [target=avr]: Add GAS check for -mgcc-isr.
9032         (HAVE_AS_AVR_MGCCISR_OPTION):  If so, AC_DEFINE it.
9033         * config.in: Regenerate.
9034         * configure: Regenerate.
9035         * doc/extend.texi (AVR Function Attributes) <no_gccisr>: Document it.
9036         * doc/invoke.texi (AVR Options) <-mgas-isr-prologues>: Document it.
9037         * config/avr/avr.opt (-mgas-isr-prologues): New option and...
9038         (TARGET_GASISR_PROLOGUES): ...target mask.
9039         * common/config/avr/avr-common.c
9040         (avr_option_optimization_table) [OPT_LEVELS_1_PLUS_NOT_DEBUG]:
9041         Set -mgas-isr-prologues.
9042         * config/avr/avr-passes.def (avr_pass_pre_proep): Add
9043         INSERT_PASS_BEFORE for it.
9044         * config/avr/avr-protos.h (make_avr_pass_pre_proep): New proto.
9045         * config/avr/avr.c (avr_option_override)
9046         [!HAVE_AS_AVR_MGCCISR_OPTION]: Unset TARGET_GASISR_PROLOGUES.
9047         (avr_no_gccisr_function_p, avr_hregs_split_reg): New static functions.
9048         (avr_attribute_table) <no_gccisr>: Add new function attribute.
9049         (avr_set_current_function) <is_no_gccisr>: Init machine field.
9050         (avr_pass_data_pre_proep, avr_pass_pre_proep): New pass data
9051         and rtl_opt_pass.
9052         (make_avr_pass_pre_proep): New function.
9053         (emit_push_sfr) <treg>: Add argument to function and use it
9054         instead of TMP_REG.
9055         (avr_expand_prologue) [machine->gasisr.maybe]: Emit gasisr insn
9056         and set machine->gasisr.yes.
9057         (avr_expand_epilogue) [machine->gasisr.yes]: Similar.
9058         (avr_asm_function_end_prologue) [machine->gasisr.yes]: Add
9059         __gcc_isr.n_pushed to .L__stack_usage.
9060         (TARGET_ASM_FINAL_POSTSCAN_INSN): Define to...
9061         (avr_asm_final_postscan_insn): ...this new static function.
9062         * config/avr/avr.h (machine_function)
9063         <is_no_gccisr, use_L__stack_usage>: New fields.
9064         <gasisr, gasisr.yes, gasisr.maybe, gasisr.regno>: New fields.
9065         * config/avr/avr.md (UNSPECV_GASISR): Add unspecv enum.
9066         (GASISR_Prologue, GASISR_Epilogue, GASISR_Done): New define_constants.
9067         (gasisr, *gasisr): New expander and insn.
9068         * config/avr/gen-avr-mmcu-specs.c (print_mcu)
9069         [HAVE_AS_AVR_MGCCISR_OPTION]: Print asm_gccisr spec.
9070         * config/avr/specs.h (ASM_SPEC) <asm_gccisr>: Add sub spec.
9072 2017-07-10  Richard Earnshaw  <rearnsha@arm.com>
9074         * config/arm/parsecpu.awk (gen_comm_data): Do not escape single quotes
9075         in quoted strings.
9077 2017-07-10  Georg-Johann Lay  <avr@gjlay.de>
9079         Move jump-tables out of .text again.
9081         PR target/81075
9082         * config/avr/avr.c (ASM_OUTPUT_ADDR_VEC_ELT): Remove function.
9083         (ASM_OUTPUT_ADDR_VEC): New function.
9084         (avr_adjust_insn_length) [JUMP_TABLE_DATA_P]: Return 0.
9085         (avr_final_prescan_insn) [avr_log.insn_addresses]: Dump
9086         INSN_ADDRESSes as asm comment.
9087         * config/avr/avr.h (JUMP_TABLES_IN_TEXT_SECTION): Adjust comment.
9088         (ASM_OUTPUT_ADDR_VEC_ELT): Remove define.
9089         (ASM_OUTPUT_ADDR_VEC): Define to avr_output_addr_vec.
9090         * config/avr/avr.md (*tablejump): Adjust comment.
9091         * config/avr/elf.h (ASM_OUTPUT_BEFORE_CASE_LABEL): Remove.
9092         * config/avr/avr-log.c (avr_log_set_avr_log) <insn_addresses>:
9093         New detail.
9094         * config/avr/avr-protos.h (avr_output_addr_vec_elt): Remove proto.
9095         (avr_output_addr_vec): New proto.
9096         (avr_log_t) <insn_addresses>: New field.
9098 2017-07-09  H.J. Lu  <hongjiu.lu@intel.com>
9100         PR target/81313
9101         * config/i386/i386.c (ix86_function_arg_advance): Set
9102         outgoing_args_on_stack to true if there are outgoing arguments
9103         on stack.
9104         (ix86_function_arg): Likewise.
9105         (ix86_get_drap_rtx): Use DRAP only if there are outgoing
9106         arguments on stack and ACCUMULATE_OUTGOING_ARGS is false.
9107         * config/i386/i386.h (machine_function): Add
9108         outgoing_args_on_stack.
9110 2017-07-09  Krister Walfridsson  <krister.walfridsson@gmail.com>
9112         * config.gcc (*-*-netbsd*): Remove check for NetBSD versions not
9113         supporting pthreds.
9114         * config/netbsd.h (NETBSD_LIBGCC_SPEC): Always enable pthreads.
9116 2017-07-08  Richard Sandiford  <richard.sandiford@linaro.org>
9118         * Makefile.in (HOOKS_H, RTL_BASE_H, FUNCTION_H, EXPR_H, REGS_H)
9119         (REAL_H): Remove $(MACHMODE_H).
9120         (FIXED_VALUE_H, TREE_CORE_H, CFGLOOP_H): Remove $(MACHMODE_H) and
9121         double-int.h.
9122         (CORETYPES_H): Add signop.h, wide-int.h, wide-int-print.h,
9123         $(MACHMODE_H) and double-int.h.
9124         (build/min-insn-modes.o): Depend on $(CORETYPES_H) rather than
9125         $(MACHMODE_H).
9126         (gengtype-state.o, gengtype.o, build/gengtype.o): Don't depend on
9127         double-int.h.
9129 2017-07-07  Andrew Pinski  <apinski@cavium.com>
9131         * config/aarch64/aarch64.c (aarch_macro_fusion_pair_p): Check
9132         prev_set and curr_set for AARCH64_FUSE_ALU_BRANCH.
9134 2017-07-07  Michael Meissner  <meissner@linux.vnet.ibm.com>
9136         * config/rs6000/rs6000.c (rs6000_get_function_versions_dispatcher):
9137         Add warning if GCC was not configured to link against a GLIBC that
9138         exports the hardware capability bits.
9139         (make_resolver_func): Make resolver function private and not a
9140         COMDAT function.  Create the name with clone_function_name instead
9141         of make_unique_name.
9143         PR target/81348
9144         * config/rs6000/rs6000.md (HI sign_extend splitter): Use the
9145         correct operand in doing the split.
9147 2017-07-07 Carl Love  <cel@us.ibm.com>
9149         * config/rs6000/rs6000-c: Add support for built-in function
9150         vector unsigned short vec_pack_to_short_fp32 (vector float,
9151                                                       vector float).
9152         * config/rs6000/rs6000-builtin.def (CONVERT_4F32_8I16): Add
9153         BU_P9V_AV_2 and BU_P9V_OVERLOAD_2 definitions.
9154         * config/rs6000/altivec.h (vec_pack_to_short_fp32): Add define.
9155         * config/rs6000/altivec.md(UNSPEC_CONVERT_4F32_8I16): Add UNSPEC.
9156         (convert_4f32_8i16): Add define_expand.
9157         * doc/extend.texi: Update the built-in documentation file for the
9158         new built-in function.
9160 2017-07-07  Jose E. Marchesi  <jose.marchesi@oracle.com>
9162         * config/sparc/m8.md: New file.
9163         * config/sparc/sparc.md: Include m8.md.
9165 2017-07-07  Jose E. Marchesi  <jose.marchesi@oracle.com>
9167         * config/sparc/sparc.opt: New option -mvis4b.
9168         * config/sparc/sparc.c (dump_target_flag_bits): Handle MASK_VIS4B.
9169         (sparc_option_override): Handle VIS4B.
9170         (enum sparc_builtins): Define
9171         SPARC_BUILTIN_DICTUNPACK{8,16,32},
9172         SPARC_BUILTIN_FPCMP{LE,GT,EQ,NE}{8,16,32}SHL,
9173         SPARC_BUILTIN_FPCMPU{LE,GT}{8,16,32}SHL,
9174         SPARC_BUILTIN_FPCMPDE{8,16,32}SHL and
9175         SPARC_BUILTIN_FPCMPUR{8,16,32}SHL.
9176         (check_constant_argument): New function.
9177         (sparc_vis_init_builtins): Define builtins
9178         __builtin_vis_dictunpack{8,16,32},
9179         __builtin_vis_fpcmp{le,gt,eq,ne}{8,16,32}shl,
9180         __builtin_vis_fpcmpu{le,gt}{8,16,32}shl,
9181         __builtin_vis_fpcmpde{8,16,32}shl and
9182         __builtin_vis_fpcmpur{8,16,32}shl.
9183         (sparc_expand_builtin): Check that the constant operands to
9184         __builtin_vis_fpcmp*shl and _builtin_vis_dictunpack* are indeed
9185         constant and in range.
9186         * config/sparc/sparc-c.c (sparc_target_macros): Handle
9187         TARGET_VIS4B.
9188         * config/sparc/sparc.h (SPARC_IMM2_P): Define.
9189         (SPARC_IMM5_P): Likewise.
9190         * config/sparc/sparc.md (cpu_feature): Add new feagure "vis4b".
9191         (enabled): Handle vis4b.
9192         (UNSPEC_DICTUNPACK): New unspec.
9193         (UNSPEC_FPCMPSHL): Likewise.
9194         (UNSPEC_FPUCMPSHL): Likewise.
9195         (UNSPEC_FPCMPDESHL): Likewise.
9196         (UNSPEC_FPCMPURSHL): Likewise.
9197         (cpu_feature): New CPU feature `vis4b'.
9198         (dictunpack{8,16,32}): New insns.
9199         (FPCSMODE): New mode iterator.
9200         (fpcscond): New code iterator.
9201         (fpcsucond): Likewise.
9202         (fpcmp{le,gt,eq,ne}{8,16,32}{si,di}shl): New insns.
9203         (fpcmpu{le,gt}{8,16,32}{si,di}shl): Likewise.
9204         (fpcmpde{8,16,32}{si,di}shl): Likewise.
9205         (fpcmpur{8,16,32}{si,di}shl): Likewise.
9206         * config/sparc/constraints.md: Define constraints `q' for unsigned
9207         2-bit integer constants and `t' for unsigned 5-bit integer
9208         constants.
9209         * config/sparc/predicates.md (imm5_operand_dictunpack8): New
9210         predicate.
9211         (imm5_operand_dictunpack16): Likewise.
9212         (imm5_operand_dictunpack32): Likewise.
9213         (imm2_operand): Likewise.
9214         * doc/invoke.texi (SPARC Options): Document -mvis4b.
9215         * doc/extend.texi (SPARC VIS Built-in Functions): Document the
9216         ditunpack* and fpcmp*shl builtins.
9218 2017-07-07  Jose E. Marchesi  <jose.marchesi@oracle.com>
9220         * config.gcc: Handle m8 in --with-{cpu,tune} options.
9221         * config.in: Add HAVE_AS_SPARC6 define.
9222         * config/sparc/driver-sparc.c (cpu_names): Add entry for the SPARC
9223         M8.
9224         * config/sparc/sol2.h (CPP_CPU64_DEFAULT_SPEC): Define for
9225         TARGET_CPU_m8.
9226         (ASM_CPU32_DEFAUILT_SPEC): Likewise.
9227         (CPP_CPU_SPEC): Handle m8.
9228         (ASM_CPU_SPEC): Likewise.
9229         * config/sparc/sparc-opts.h (enum processor_type): Add
9230         PROCESSOR_M8.
9231         * config/sparc/sparc.c (m8_costs): New struct.
9232         (sparc_option_override): Handle TARGET_CPU_m8.
9233         (sparc32_initialize_trampoline): Likewise.
9234         (sparc64_initialize_trampoline): Likewise.
9235         (sparc_issue_rate): Likewise.
9236         (sparc_register_move_cost): Likewise.
9237         * config/sparc/sparc.h (TARGET_CPU_m8): Define.
9238         (CPP_CPU64_DEFAULT_SPEC): Define for M8.
9239         (ASM_CPU64_DEFAULT_SPEC): Likewise.
9240         (CPP_CPU_SPEC): Handle M8.
9241         (ASM_CPU_SPEC): Likewise.
9242         (AS_M8_FLAG): Define.
9243         * config/sparc/sparc.md: Add m8 to the cpu attribute.
9244         * config/sparc/sparc.opt: New option -mcpu=m8 for sparc targets.
9245         * configure.ac (HAVE_AS_SPARC6): Check for assembler support for
9246         M8 instructions.
9247         * configure: Regenerate.
9248         * doc/invoke.texi (SPARC Options): Document -mcpu=m8 and
9249         -mtune=m8.
9251 2017-07-07  Jose E. Marchesi  <jose.marchesi@oracle.com>
9253         * config/sparc/niagara7.md: Rework the DFA scheduler to use insn
9254         subtypes.
9255         * config/sparc/sparc.md: Remove the `v3pipe' insn attribute.
9256         ("*movdi_insn_sp32"): Do not set v3pipe.
9257         ("*movsi_insn"): Likewise.
9258         ("*movdi_insn_sp64"): Likewise.
9259         ("*movsf_insn"): Likewise.
9260         ("*movdf_insn_sp32"): Likewise.
9261         ("*movdf_insn_sp64"): Likewise.
9262         ("*zero_extendsidi2_insn_sp64"): Likewise.
9263         ("*sign_extendsidi2_insn"): Likewise.
9264         ("*mov<VM32:mode>_insn"): Likewise.
9265         ("*mov<VM64:mode>_insn_sp64"): Likewise.
9266         ("*mov<VM64:mode>_insn_sp32"): Likewise.
9267         ("<plusminus_insn><VADDSUB:mode>3"): Likewise.
9268         ("<vlop:code><VL:mode>3"): Likewise.
9269         ("*not_<vlop:code><VL:mode>3"): Likewise.
9270         ("*nand<VL:mode>_vis"): Likewise.
9271         ("*<vlnotop:code>_not1<VL:mode>_vis"): Likewise.
9272         ("*<vlnotop:code>_not2<VL:mode>_vis"): Likewise.
9273         ("one_cmpl<VL:mode>2"): Likewise.
9274         ("faligndata<VM64:mode>_vis"): Likewise.
9275         ("alignaddrsi_vis"): Likewise.
9276         ("alignaddrdi_vis"): Likweise.
9277         ("alignaddrlsi_vis"): Likewise.
9278         ("alignaddrldi_vis"): Likewise.
9279         ("fcmp<gcond:code><GCM:gcm_name><P:mode>_vis"): Likewise.
9280         ("bmaskdi_vis"): Likewise.
9281         ("bmasksi_vis"): Likewise.
9282         ("bshuffle<VM64:mode>_vis"): Likewise.
9283         ("cmask8<P:mode>_vis"): Likewise.
9284         ("cmask16<P:mode>_vis"): Likewise.
9285         ("cmask32<P:mode>_vis"): Likewise.
9286         ("pdistn<P:mode>_vis"): Likewise.
9287         ("<vis3_addsub_ss_patname><VASS:mode>3"): Likewise.
9289 2017-07-07  Jose E. Marchesi  <jose.marchesi@oracle.com>
9291         * config/sparc/sparc.md ("subtype"): New insn attribute.
9292         ("*wrgsr_sp64"): Set insn subtype.
9293         ("*rdgsr_sp64"): Likewise.
9294         ("alignaddrsi_vis"): Likewise.
9295         ("alignaddrdi_vis"): Likewise.
9296         ("alignaddrlsi_vis"): Likewise.
9297         ("alignaddrldi_vis"): Likewise.
9298         ("<plusminus_insn><VADDSUB:mode>3"): Likewise.
9299         ("fexpand_vis"): Likewise.
9300         ("fpmerge_vis"): Likewise.
9301         ("faligndata<VM64:mode>_vis"): Likewise.
9302         ("bshuffle<VM64:mode>_vis"): Likewise.
9303         ("cmask8<P:mode>_vis"): Likewise.
9304         ("cmask16<P:mode>_vis"): Likewise.
9305         ("cmask32<P:mode>_vis"): Likewise.
9306         ("fchksm16_vis"): Likewise.
9307         ("v<vis3_shift_patname><GCM:mode>3"): Likewise.
9308         ("fmean16_vis"): Likewise.
9309         ("fp<plusminus_insn>64_vis"): Likewise.
9310         ("<plusminus_insn>v8qi3"): Likewise.
9311         ("<vis3_addsub_ss_patname><VASS:mode>3"): Likewise.
9312         ("<vis4_minmax_patname><VMMAX:mode>3"): Likewise.
9313         ("<vis4_uminmax_patname><VMMAX:mode>3"): Likewise.
9314         ("<vis3_addsub_ss_patname>v8qi3"): Likewise.
9315         ("<vis4_addsub_us_patname><VAUS:mode>3"): Likewise.
9316         ("*movqi_insn"): Likewise.
9317         ("*movhi_insn"): Likewise.
9318         ("*movsi_insn"): Likewise.
9319         ("movsi_pic_gotdata_op"): Likewise.
9320         ("*movdi_insn_sp32"): Likewise.
9321         ("*movdi_insn_sp64"): Likewise.
9322         ("movdi_pic_gotdata_op"): Likewise.
9323         ("*movsf_insn"): Likewise.
9324         ("*movdf_insn_sp32"): Likewise.
9325         ("*movdf_insn_sp64"): Likewise.
9326         ("*zero_extendhisi2_insn"): Likewise.
9327         ("*zero_extendqihi2_insn"): Likewise.
9328         ("*zero_extendqisi2_insn"): Likewise.
9329         ("*zero_extendqidi2_insn"): Likewise.
9330         ("*zero_extendhidi2_insn"): Likewise.
9331         ("*zero_extendsidi2_insn_sp64"): Likewise.
9332         ("ldfsr"): Likewise.
9333         ("prefetch_64"): Likewise.
9334         ("prefetch_32"): Likewise.
9335         ("tie_ld32"): Likewise.
9336         ("tie_ld64"): Likewise.
9337         ("*tldo_ldub_sp32"): Likewise.
9338         ("*tldo_ldub1_sp32"): Likewise.
9339         ("*tldo_ldub2_sp32"): Likewise.
9340         ("*tldo_ldub_sp64"): Likewise.
9341         ("*tldo_ldub1_sp64"): Likewise.
9342         ("*tldo_ldub2_sp64"): Likewise.
9343         ("*tldo_ldub3_sp64"): Likewise.
9344         ("*tldo_lduh_sp32"): Likewise.
9345         ("*tldo_lduh1_sp32"): Likewise.
9346         ("*tldo_lduh_sp64"): Likewise.
9347         ("*tldo_lduh1_sp64"): Likewise.
9348         ("*tldo_lduh2_sp64"): Likewise.
9349         ("*tldo_lduw_sp32"): Likewise.
9350         ("*tldo_lduw_sp64"): Likewise.
9351         ("*tldo_lduw1_sp64"): Likewise.
9352         ("*tldo_ldx_sp64"): Likewise.
9353         ("*mov<VM32:mode>_insn"): Likewise.
9354         ("*mov<VM64:mode>_insn_sp64"): Likewise.
9355         ("*mov<VM64:mode>_insn_sp32"): Likewise.
9357 2017-07-07  Jose E. Marchesi  <jose.marchesi@oracle.com>
9359         * config/sparc/sparc.md ("type"): New insn type viscmp.
9360         ("fcmp<gcond:code><GCM:gcm_name><P:mode>_vis"): Set insn type to
9361         viscmp.
9362         ("fpcmp<gcond:code>8<P:mode>_vis"): Likewise.
9363         ("fucmp<gcond:code>8<P:mode>_vis"): Likewise.
9364         ("fpcmpu<gcond:code><GCM:gcm_name><P:mode>_vis"): Likewise.
9365         * config/sparc/niagara7.md ("n7_vis_logical_v3pipe"): Handle
9366         viscmp.
9367         ("n7_vis_logical_11cycle"): Likewise.
9368         * config/sparc/niagara4.md ("n4_vis_logical"): Likewise.
9369         * config/sparc/niagara2.md ("niag3_vis": Likewise.
9370         * config/sparc/niagara.md ("niag_vis"): Likewise.
9371         * config/sparc/ultra3.md ("us3_fga"): Likewise.
9372         * config/sparc/ultra1_2.md ("us1_fga_double"): Likewise.
9374 2017-07-07  Jose E. Marchesi  <jose.marchesi@oracle.com>
9376         * config/sparc/sparc.md: New instruction type `bmask'.
9377         (bmaskdi_vis): Use the `bmask' type.
9378         (bmasksi_vis): Likewise.
9379         * config/sparc/ultra3.md (us3_array): Likewise.
9380         * config/sparc/niagara7.md (n7_array): Likewise.
9381         * config/sparc/niagara4.md (n4_array): Likewise.
9382         * config/sparc/niagara2.md (niag2_vis): Likewise.
9383         (niag3_vis): Likewise.
9384         * config/sparc/niagara.md (niag_vis): Likewise.
9386 2017-07-06  Jan Hubicka  <hubicka@ucw.cz>
9388         * ipa-comdats.c: Remove optimize check from gate.
9389         * ipa-fnsummary.c (ipa_fn_summary_generate): do not generate summary
9390         for functions not optimized.
9391         (ipa_fn_summary_read): Skip optimize check.
9392         (ipa_fn_summary_write): Likewise.
9393         * ipa-inline-analysis.c (do_estimate_growth_1): Check that caller
9394         is optimized.
9395         * ipa-inline.c (can_inline_edge_p): Not optimized functions are
9396         uninlinable.
9397         (can_inline_edge_p): Check flag_pcc_struct_return for match.
9398         (check_callers): Give up on caller which is not optimized.
9399         (inline_small_functions): Likewise.
9400         (ipa_inline): Do not give up when not optimizing.
9401         * ipa-visbility.c (function_and_variable_visibility): Do not optimize
9402         away unoptimizes cdtors.
9403         (whole_program_function_and_variable_visibility): Do
9404         ipa_discover_readonly_nonaddressable_vars in LTO mode.
9405         * ipa.c (process_references): Do not check optimize.
9406         (symbol_table::remove_unreachable_nodes): Update optimize check.
9407         (set_writeonly_bit): Update optimize check.
9408         (pass_ipa_cdtor_merge::gate): Do not check optimize.
9409         (pass_ipa_single_use::gate): Remove.
9411 2017-07-06  Aaron Sawdey  <acsawdey@linux.vnet.ibm.com>
9413         * config/rs6000/rs6000.c (union_defs, union_uses, insn_is_load_p,
9414         insn_is_store_p, insn_is_swap_p, const_load_sequence_p, v2df_reduction_p,
9415         rtx_is_swappable_p, insn_is_swappable_p, chain_contains_only_swaps,
9416         mark_swaps_for_removal, swap_const_vector_halves, adjust_subreg_index,
9417         permute_load, permute_store, adjust_extract, adjust_splat,
9418         adjust_xxpermdi, adjust_concat, adjust_vperm, handle_special_swappables,
9419         replace_swap_with_copy, dump_swap_insn_table,
9420         alignment_with_canonical_addr, alignment_mask, find_alignment_op,
9421         recombine_lvx_pattern, recombine_stvx_pattern,
9422         recombine_lvx_stvx_patterns, rs6000_analyze_swaps,
9423         make_pass_analyze_swaps): Move all code related to p8 swap optimizations
9424         to file rs6000-p8swap.c.
9425         * config/rs6000/rs6000-p8swap.c: New file.
9426         * config/rs6000/t-rs6000: Add rule to build rs6000-p8swap.o.
9427         * config.gcc: Add rs6000-p8swap.o to extra_objs for powerpc*-*-*
9428         and rs6000*-*-* targets.
9430 2017-07-06  David Malcolm  <dmalcolm@redhat.com>
9432         * Makefile.in (selftest): Remove dependency on s-selftest-c++.
9434 2017-07-06  Jan Hubicka  <hubicka@ucw.cz>
9436         * lto-wrapper.c (merge_and_complain): Do not merge
9437         fexceptions, fnon_call_exceptions, ftrapv, ffp_contract_, fmath_errno,
9438         fsigned_zeros, ftrapping_math, fwrapv.
9439         (append_compiler_options): Do not track these options.
9440         (append_linker_options): Likewie
9442 2017-07-06  Jan Hubicka  <hubicka@ucw.cz>
9444         * cgraphunit.c (cgraph_node::finalize_function): When
9445         !flag_toplevel_reorde set no_reorder flag.
9446         (varpool_node::finalize_decl): Likewise.
9447         (symbol_table::compile): Drop no toplevel reorder path.
9449 2017-07-06  Jan Hubicka  <hubicka@ucw.cz>
9451         * bb-reorder.c (better_edge_p): Do not build traces across abnormal/eh
9452         edges; zero probability is not better than uninitialized.
9454 2017-07-06  Maxim Ostapenko  <m.ostapenko@samsung.com>
9456         * asan.h (asan_sanitize_allocas_p): Declare.
9457         * asan.c (asan_sanitize_allocas_p): New function.
9458         (handle_builtin_stack_restore): Bail out if !asan_sanitize_allocas_p.
9459         (handle_builtin_alloca): Likewise.
9460         * cfgexpand.c (expand_used_vars): Do not add allocas unpoisoning stuff
9461         if !asan_sanitize_allocas_p.
9462         * params.def (asan-instrument-allocas): Add new option.
9463         * params.h (ASAN_PROTECT_ALLOCAS): Define.
9464         * opts.c (common_handle_option): Disable allocas sanitization for
9465         KASan by default.
9467 2017-07-06  Maxim Ostapenko  <m.ostapenko@samsung.com>
9469         * asan.c: Include gimple-fold.h.
9470         (get_last_alloca_addr): New function.
9471         (handle_builtin_stackrestore): Likewise.
9472         (handle_builtin_alloca): Likewise.
9473         (asan_emit_allocas_unpoison): Likewise.
9474         (get_mem_refs_of_builtin_call): Add new parameter, remove const
9475         quallifier from first paramerer. Handle BUILT_IN_ALLOCA,
9476         BUILT_IN_ALLOCA_WITH_ALIGN and BUILT_IN_STACK_RESTORE builtins.
9477         (instrument_builtin_call): Pass gimple iterator to
9478         get_mem_refs_of_builtin_call.
9479         (last_alloca_addr): New global.
9480         * asan.h (asan_emit_allocas_unpoison): Declare.
9481         * builtins.c (expand_asan_emit_allocas_unpoison): New function.
9482         (expand_builtin): Handle BUILT_IN_ASAN_ALLOCAS_UNPOISON.
9483         * cfgexpand.c (expand_used_vars): Call asan_emit_allocas_unpoison
9484         if function calls alloca.
9485         * gimple-fold.c (replace_call_with_value): Remove static keyword.
9486         * gimple-fold.h (replace_call_with_value): Declare.
9487         * internal-fn.c: Include asan.h.
9488         * sanitizer.def (BUILT_IN_ASAN_ALLOCA_POISON,
9489         BUILT_IN_ASAN_ALLOCAS_UNPOISON): New builtins.
9491 2017-07-06  David Malcolm  <dmalcolm@redhat.com>
9493         * Makefile.in (SELFTEST_FLAGS): Drop "-x c", moving it to...
9494         (C_SELFTEST_FLAGS): New.
9495         (CPP_SELFTEST_FLAGS): New.
9496         (SELFTEST_DEPS): New, from deps of s-selftest.
9497         (C_SELFTEST_DEPS): New, from deps of s-selftest.
9498         (CPP_SELFTEST_DEPS): New.
9499         (selftest): Add dependency on s-selftest-c++.
9500         (s-selftest): Rename to...
9501         (s-selftest-c): ...this, moving deps to SELFTEST_DEPS
9502         and C_SELFTEST_DEPS, and using C_SELFTEST_FLAGS rather
9503         than SELFTEST_FLAGS.
9504         (selftest-gdb): Rename to...
9505         (selftest-c-gdb): ...this, using C_SELFTEST_DEPS and
9506         C_SELFTEST_FLAGS.
9507         (selftest-gdb): Reintroduce as an alias for selftest-c-gdb.
9508         (selftest-valgrind): Rename to...
9509         (selftest-c-valgrind): ...this, using C_SELFTEST_DEPS and
9510         C_SELFTEST_FLAGS.
9511         (selftest-valgrind): Reintroduce as an alias for
9512         selftest-c-valgrind.
9513         (s-selftest-c++): New.
9514         (selftest-c++-gdb): New.
9515         (selftest-c++-valgrind): New.
9517 2017-07-06  Olivier Hainque  <hainque@adacore.com>
9519         * gcc.c (process_command): When deciding if undefined variables
9520         should be ignored when processing specs, accept "gcc -v" as well.
9522 2017-07-06  Jan Hubicka  <hubicka@ucw.cz>
9524         * auto-profile.c (afdo_set_bb_count, afdo_propagate_edge,
9525         afdo_annotate_cfg): Set counts/probabilities as determined by afdo.
9527 2017-07-06  Thomas Preud'homme  <thomas.preudhomme@arm.com>
9529         * config/arm/arm-cpus.in (armv8-r): Add new entry.
9530         * config/arm/arm-isa.h (ISA_ARMv8r): Define macro.
9531         * config/arm/arm-tables.opt: Regenerate.
9532         * config/arm/arm.h (enum base_architecture): Add BASE_ARCH_8R
9533         enumerator.
9534         * doc/invoke.texi: Mention -march=armv8-r and its extensions.
9536 2017-07-06  Carl Love  <cel@us.ibm.com>
9538         * ChangeLog: Clean up from mid air collision
9540 2017-07-06  Carl Love  <cel@us.ibm.com>
9542         * config/rs6000/rs6000-c.c: Add support for built-in functions
9543         vector signed int vec_subc (vector signed int, vector signed int);
9544         vector signed __int128 vec_subc (vector signed __int128,
9545                                          vector signed __int128);
9546         vector unsigned __int128 vec_subc (vector unsigned __int128,
9547                                            vector unsigned __int128);
9548         vector signed int vec_sube (vector signed int, vector signed int,
9549                                     vector signed int);
9550         vector unsigned int vec_sube (vector unsigned int,
9551                                       vector unsigned int,
9552                                       vector unsigned int);
9553         vector signed __int128 vec_sube (vector signed __int128,
9554                                          vector signed __int128,
9555                                          vector signed__int128);
9556         vector unsigned __int128 vec_sube (vector unsigned __int128,
9557                                            vector unsigned __int128,
9558                                            vector unsigned __int128);
9559         vector signed int vec_subec (vector signed int, vector signed int,
9560                                      vector signed int);
9561         vector unsigned int vec_subec (vector unsigned int,
9562                                        vector unsigned int,
9563                                        vector unsigned int);
9564         vector signed __int128 vec_subec (vector signed __int128,
9565                                           vector signed __int128,
9566                                           vector signed__int128);
9567         vector unsigned __int128 vec_subec (vector unsigned __int128,
9568                                             vector unsigned __int128,
9569                                             vector unsigned __int128);
9570         * config/rs6000/rs6000.c (ALTIVEC_BUILTIN_VEC_SUBE,
9571         ALTIVEC_BUILTIN_VEC_SUBEC): Add ef_builtins.
9572         * config/rs6000/rs6000-builtin.def (SUBE, SUBEC): Add
9573         BU_ALTIVEC_OVERLOAD_X definitions.
9574         * config/rs6000/altivec.h (vec_sube, vec_subec): Add builtin defines.
9575         * doc/extend.texi: Update the built-in documentation file for the new
9576         built-in functions.
9578 2017-07-06  David Malcolm  <dmalcolm@redhat.com>
9580         PR c++/79300
9581         * diagnostic-show-locus.c (layout::layout): Use start and finish
9582         spelling location for the start and finish of each range.
9583         * genmatch.c (linemap_client_expand_location_to_spelling_point):
9584         Add unused aspect param.
9585         * input.c (expand_location_1): Add "aspect" param, and use it
9586         to access the correct part of the location.
9587         (expand_location): Pass LOCATION_ASPECT_CARET to new param of
9588         expand_location_1.
9589         (expand_location_to_spelling_point): Likewise.
9590         (linemap_client_expand_location_to_spelling_point): Add "aspect"
9591         param, and pass it to expand_location_1.
9593 2017-07-06  Sebastian Peryt  <sebastian.peryt@intel.com>
9595         * config/i386/avx512fintrin.h (_mm_mask_getexp_round_ss,
9596         _mm_maskz_getexp_round_ss, _mm_mask_getexp_round_sd,
9597         _mm_maskz_getexp_round_sd, _mm_mask_getmant_round_sd,
9598         _mm_maskz_getmant_round_sd, _mm_mask_getmant_round_ss,
9599         _mm_maskz_getmant_round_ss, _mm_mask_getexp_ss, _mm_maskz_getexp_ss,
9600         _mm_mask_getexp_sd, _mm_maskz_getexp_sd, _mm_mask_getmant_sd,
9601         _mm_maskz_getmant_sd, _mm_mask_getmant_ss,
9602         _mm_maskz_getmant_ss): New intrinsics.
9603         (__builtin_ia32_getexpss128_mask): Changed to ...
9604         __builtin_ia32_getexpss128_round ... this.
9605         (__builtin_ia32_getexpsd128_mask): Changed to ...
9606         __builtin_ia32_getexpsd128_round ... this.
9607         * config/i386/i386-builtin-types.def
9608         ((V2DF, V2DF, V2DF, INT, V2DF, UQI, INT),
9609         (V4SF, V4SF, V4SF, INT, V4SF, UQI, INT)): New function type aliases.
9610         * config/i386/i386-builtin.def (__builtin_ia32_getexpsd_mask_round,
9611         __builtin_ia32_getexpss_mask_round,     __builtin_ia32_getmantsd_mask_round,
9612         __builtin_ia32_getmantss_mask_round): New builtins.
9613         * config/i386/i386.c (V2DF_FTYPE_V2DF_V2DF_INT_V2DF_UQI_INT,
9614         V4SF_FTYPE_V4SF_V4SF_INT_V4SF_UQI_INT): Handle new types.
9615         (CODE_FOR_avx512f_vgetmantv2df_mask_round,
9616         CODE_FOR_avx512f_vgetmantv4sf_mask_round): New cases.
9617         * config/i386/sse.md
9618         (avx512f_sgetexp<mode><round_saeonly_name>): Changed to ...
9619         avx512f_sgetexp<mode><mask_scalar_name>
9620         <round_saeonly_scalar_name> ... this.
9621         (vgetexp<ssescalarmodesuffix>\t{<round_saeonly_op3>%2, %1, %0|
9622         %0, %1, %2<round_saeonly_op3>}): Changed to ...
9623         vgetexp<ssescalarmodesuffix>
9624         \t{<round_saeonly_scalar_mask_op3>%2, %1, %0<mask_scalar_operand3>|
9625         %0<mask_scalar_operand3>, %1, %2<round_saeonly_scalar_mask_op3>} ... this.
9626         (avx512f_vgetmant<mode><round_saeonly_name>): Changed to ...
9627         avx512f_vgetmant<mode><mask_scalar_name>
9628         <round_saeonly_scalar_name> ... this.
9629         (vgetmant<ssescalarmodesuffix>\t{%3, <round_saeonly_op4>%2, %1, %0|
9630         %0, %1, %2<round_saeonly_op4>, %3}): Changed to ...
9631         vgetmant<ssescalarmodesuffix>
9632         \t{%3, <round_saeonly_scalar_mask_op4>%2, %1, %0<mask_scalar_operand4>|
9633         %0<mask_scalar_operand4>, %1, %2
9634         <round_saeonly_scalar_mask_op4>, %3} ... this.
9635         * config/i386/subst.md (mask_scalar_operand4,
9636         round_saeonly_scalar_mask_operand4,     round_saeonly_scalar_mask_op4,
9637         round_saeonly_scalar_nimm_predicate): New subst attributes.
9639 2017-07-06  Julia Koval  <julia.koval@intel.com>
9641         * config/i386/i386.c (ix86_erase_embedded_rounding):
9642         Remove code for old rounding pattern.
9644 2017-07-06  Richard Earnshaw  <rearnsha@arm.com>
9646         * config/arm/t-arm (GTM_H): Add arm-cpu.h.
9648 2017-07-06  Christophe Lyon  <christophe.lyon@linaro.org>
9650         * doc/sourcebuild.texi (Test Directives, Variants of
9651         dg-require-support): Add documentation for dg-require-stack-check.
9653 2017-07-05  Sebastian Peryt  <sebastian.peryt@intel.com>
9655         * config/i386/subst.md (mask_scalar, round_scalar,
9656         round_saeonly_scalar): New meta-templates.
9657         (mask_scalar_name, mask_scalar_operand3, round_scalar_name,
9658         round_scalar_mask_operand3, round_scalar_mask_op3,
9659         round_scalar_constraint, round_scalar_prefix, round_saeonly_scalar_name,
9660         round_saeonly_scalar_mask_operand3, round_saeonly_scalar_mask_op3,
9661         round_saeonly_scalar_constraint,
9662         round_saeonly_scalar_prefix): New subst attribute.
9663         * config/i386/sse.md
9664         (<sse>_vm<plusminus_insn><mode>3<mask_name><round_name>): Renamed to ...
9665         <sse>_vm<plusminus_insn><mode>3<mask_scalar_name>
9666         <round_scalar_name> ... this.
9667         (<sse>_vm<multdiv_mnemonic><mode>3<mask_name><round_name>): Renamed to ...
9668         <sse>_vm<multdiv_mnemonic><mode>3<mask_scalar_name>
9669         <round_scalar_name> ... this.
9670         (<sse>_vm<code><mode>3<mask_name><round_saeonly_name>): Renamed to ...
9671         <sse>_vm<code><mode>3<mask_scalar_name>
9672         <round_saeonly_scalar_name> ... this.
9673         (v<plusminus_mnemonic><ssescalarmodesuffix>
9674         \t{<round_mask_op3>%2, %1, %0<mask_operand3>|
9675         %0<mask_operand3>, %1, %<iptr>2<round_mask_op3>}): Changed to ...
9676         v<plusminus_mnemonic><ssescalarmodesuffix>
9677         \t{<round_scalar_mask_op3>%2, %1, %0<mask_scalar_operand3>|
9678         %0<mask_scalar_operand3>, %1, %<iptr>2<round_scalar_mask_op3>} ... this.
9679         (v<multdiv_mnemonic><ssescalarmodesuffix>
9680         \t{<round_mask_op3>%2, %1, %0<mask_operand3>|
9681         %0<mask_operand3>, %1, %<iptr>2<round_mask_op3>}): Changed to ...
9682         v<multdiv_mnemonic><ssescalarmodesuffix>
9683         \t{<round_scalar_mask_op3>%2, %1, %0<mask_scalar_operand3>|
9684         %0<mask_scalar_operand3>, %1, %<iptr>2<round_scalar_mask_op3>} ... this.
9685         (v<maxmin_float><ssescalarmodesuffix>
9686         \t{<round_saeonly_mask_op3>%2, %1, %0<mask_operand3>|
9687         %0<mask_operand3>, %1, %<iptr>2<round_saeonly_mask_op3>}): Changed to ...
9688         v<maxmin_float><ssescalarmodesuffix>
9689         \t{<round_saeonly_scalar_mask_op3>%2, %1, %0<mask_scalar_operand3>|
9690         %0<mask_scalar_operand3>, %1, %<iptr>2
9691         <round_saeonly_scalar_mask_op3>} ... this.
9693 2017-07-05  Richard Earnshaw  <rearnsha@arm.com>
9695         * config/arm/arm.c (arm_fixed_condition_code_regs): New function.
9696         (TARGET_FIXED_CONDITION_CODE_REGS): Redefine.
9698 2017-07-05  Richard Sandiford  <richard.sandiford@linaro.org>
9699             Alan Hayward  <alan.hayward@arm.com>
9700             David Sherwood  <david.sherwood@arm.com>
9702         * combine.c (simplify_if_then_else): Remove "enum" before
9703         "machine_mode".
9704         * compare-elim.c (can_eliminate_compare): Likewise.
9705         * config/aarch64/aarch64-builtins.c (aarch64_simd_builtin_std_type):
9706         Likewise.
9707         (aarch64_lookup_simd_builtin_type): Likewise.
9708         (aarch64_simd_builtin_type): Likewise.
9709         (aarch64_init_simd_builtin_types): Likewise.
9710         (aarch64_simd_expand_args): Likewise.
9711         * config/aarch64/aarch64-protos.h (aarch64_simd_attr_length_rglist):
9712         Likewise.
9713         (aarch64_reverse_mask): Likewise.
9714         (aarch64_simd_emit_reg_reg_move): Likewise.
9715         (aarch64_gen_adjusted_ldpstp): Likewise.
9716         (aarch64_ccmp_mode_to_code): Likewise.
9717         (aarch64_operands_ok_for_ldpstp): Likewise.
9718         (aarch64_operands_adjust_ok_for_ldpstp): Likewise.
9719         * config/aarch64/aarch64.c (aarch64_ira_change_pseudo_allocno_class):
9720         Likewise.
9721         (aarch64_min_divisions_for_recip_mul): Likewise.
9722         (aarch64_reassociation_width): Likewise.
9723         (aarch64_get_condition_code_1): Likewise.
9724         (aarch64_simd_emit_reg_reg_move): Likewise.
9725         (aarch64_simd_attr_length_rglist): Likewise.
9726         (aarch64_reverse_mask): Likewise.
9727         (aarch64_operands_ok_for_ldpstp): Likewise.
9728         (aarch64_operands_adjust_ok_for_ldpstp): Likewise.
9729         (aarch64_gen_adjusted_ldpstp): Likewise.
9730         * config/aarch64/cortex-a57-fma-steering.c (fma_node::rename):
9731         Likewise.
9732         * config/arc/arc.c (legitimate_offset_address_p): Likewise.
9733         * config/arm/arm-builtins.c (arm_simd_builtin_std_type): Likewise.
9734         (arm_lookup_simd_builtin_type): Likewise.
9735         (arm_simd_builtin_type): Likewise.
9736         (arm_init_simd_builtin_types): Likewise.
9737         (arm_expand_builtin_args): Likewise.
9738         * config/arm/arm-protos.h (arm_expand_builtin): Likewise.
9739         * config/ft32/ft32.c (ft32_libcall_value): Likewise.
9740         (ft32_setup_incoming_varargs): Likewise.
9741         (ft32_function_arg): Likewise.
9742         (ft32_function_arg_advance): Likewise.
9743         (ft32_pass_by_reference): Likewise.
9744         (ft32_arg_partial_bytes): Likewise.
9745         (ft32_valid_pointer_mode): Likewise.
9746         (ft32_addr_space_pointer_mode): Likewise.
9747         (ft32_addr_space_legitimate_address_p): Likewise.
9748         * config/i386/i386-protos.h (ix86_operands_ok_for_move_multiple):
9749         Likewise.
9750         * config/i386/i386.c (ix86_setup_incoming_vararg_bounds): Likewise.
9751         (ix86_emit_outlined_ms2sysv_restore): Likewise.
9752         (iamcu_alignment): Likewise.
9753         (canonicalize_vector_int_perm): Likewise.
9754         (ix86_noce_conversion_profitable_p): Likewise.
9755         (ix86_mpx_bound_mode): Likewise.
9756         (ix86_operands_ok_for_move_multiple): Likewise.
9757         * config/microblaze/microblaze-protos.h
9758         (microblaze_expand_conditional_branch_reg): Likewise.
9759         * config/microblaze/microblaze.c
9760         (microblaze_expand_conditional_branch_reg): Likewise.
9761         * config/powerpcspe/powerpcspe.c (rs6000_init_hard_regno_mode_ok):
9762         Likewise.
9763         (rs6000_reassociation_width): Likewise.
9764         (rs6000_invalid_binary_op): Likewise.
9765         (fusion_p9_p): Likewise.
9766         (emit_fusion_p9_load): Likewise.
9767         (emit_fusion_p9_store): Likewise.
9768         * config/riscv/riscv-protos.h (riscv_regno_mode_ok_for_base_p):
9769         Likewise.
9770         (riscv_hard_regno_mode_ok_p): Likewise.
9771         (riscv_address_insns): Likewise.
9772         (riscv_split_symbol): Likewise.
9773         (riscv_legitimize_move): Likewise.
9774         (riscv_function_value): Likewise.
9775         (riscv_hard_regno_nregs): Likewise.
9776         (riscv_expand_builtin): Likewise.
9777         * config/riscv/riscv.c (riscv_build_integer_1): Likewise.
9778         (riscv_build_integer): Likewise.
9779         (riscv_split_integer): Likewise.
9780         (riscv_legitimate_constant_p): Likewise.
9781         (riscv_cannot_force_const_mem): Likewise.
9782         (riscv_regno_mode_ok_for_base_p): Likewise.
9783         (riscv_valid_base_register_p): Likewise.
9784         (riscv_valid_offset_p): Likewise.
9785         (riscv_valid_lo_sum_p): Likewise.
9786         (riscv_classify_address): Likewise.
9787         (riscv_legitimate_address_p): Likewise.
9788         (riscv_address_insns): Likewise.
9789         (riscv_load_store_insns): Likewise.
9790         (riscv_force_binary): Likewise.
9791         (riscv_split_symbol): Likewise.
9792         (riscv_force_address): Likewise.
9793         (riscv_legitimize_address): Likewise.
9794         (riscv_move_integer): Likewise.
9795         (riscv_legitimize_const_move): Likewise.
9796         (riscv_legitimize_move): Likewise.
9797         (riscv_address_cost): Likewise.
9798         (riscv_subword): Likewise.
9799         (riscv_output_move): Likewise.
9800         (riscv_canonicalize_int_order_test): Likewise.
9801         (riscv_emit_int_order_test): Likewise.
9802         (riscv_function_arg_boundary): Likewise.
9803         (riscv_pass_mode_in_fpr_p): Likewise.
9804         (riscv_pass_fpr_single): Likewise.
9805         (riscv_pass_fpr_pair): Likewise.
9806         (riscv_get_arg_info): Likewise.
9807         (riscv_function_arg): Likewise.
9808         (riscv_function_arg_advance): Likewise.
9809         (riscv_arg_partial_bytes): Likewise.
9810         (riscv_function_value): Likewise.
9811         (riscv_pass_by_reference): Likewise.
9812         (riscv_setup_incoming_varargs): Likewise.
9813         (riscv_print_operand): Likewise.
9814         (riscv_elf_select_rtx_section): Likewise.
9815         (riscv_save_restore_reg): Likewise.
9816         (riscv_for_each_saved_reg): Likewise.
9817         (riscv_register_move_cost): Likewise.
9818         (riscv_hard_regno_mode_ok_p): Likewise.
9819         (riscv_hard_regno_nregs): Likewise.
9820         (riscv_class_max_nregs): Likewise.
9821         (riscv_memory_move_cost): Likewise.
9822         * config/rl78/rl78-protos.h (rl78_split_movsi): Likewise.
9823         * config/rl78/rl78.c (rl78_split_movsi): Likewise.
9824         (rl78_addr_space_address_mode): Likewise.
9825         * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin):
9826         Likewise.
9827         * config/rs6000/rs6000.c (rs6000_init_hard_regno_mode_ok): Likewise.
9828         (rs6000_reassociation_width): Likewise.
9829         (rs6000_invalid_binary_op): Likewise.
9830         (fusion_p9_p): Likewise.
9831         (emit_fusion_p9_load): Likewise.
9832         (emit_fusion_p9_store): Likewise.
9833         * config/visium/visium-protos.h (prepare_move_operands): Likewise.
9834         (ok_for_simple_move_operands): Likewise.
9835         (ok_for_simple_move_strict_operands): Likewise.
9836         (ok_for_simple_arith_logic_operands): Likewise.
9837         (visium_legitimize_reload_address): Likewise.
9838         (visium_select_cc_mode): Likewise.
9839         (output_cbranch): Likewise.
9840         (visium_split_double_move): Likewise.
9841         (visium_expand_copysign): Likewise.
9842         (visium_expand_int_cstore): Likewise.
9843         (visium_expand_fp_cstore): Likewise.
9844         * config/visium/visium.c (visium_pass_by_reference): Likewise.
9845         (visium_function_arg): Likewise.
9846         (visium_function_arg_advance): Likewise.
9847         (visium_libcall_value): Likewise.
9848         (visium_setup_incoming_varargs): Likewise.
9849         (visium_legitimate_constant_p): Likewise.
9850         (visium_legitimate_address_p): Likewise.
9851         (visium_legitimize_address): Likewise.
9852         (visium_secondary_reload): Likewise.
9853         (visium_register_move_cost): Likewise.
9854         (visium_memory_move_cost): Likewise.
9855         (prepare_move_operands): Likewise.
9856         (ok_for_simple_move_operands): Likewise.
9857         (ok_for_simple_move_strict_operands): Likewise.
9858         (ok_for_simple_arith_logic_operands): Likewise.
9859         (visium_function_value_1): Likewise.
9860         (rtx_ok_for_offset_p): Likewise.
9861         (visium_legitimize_reload_address): Likewise.
9862         (visium_split_double_move): Likewise.
9863         (visium_expand_copysign): Likewise.
9864         (visium_expand_int_cstore): Likewise.
9865         (visium_expand_fp_cstore): Likewise.
9866         (visium_split_cstore): Likewise.
9867         (visium_select_cc_mode): Likewise.
9868         (visium_split_cbranch): Likewise.
9869         (output_cbranch): Likewise.
9870         (visium_print_operand_address): Likewise.
9871         * expmed.c (flip_storage_order): Likewise.
9872         * expmed.h (emit_cstore): Likewise.
9873         (flip_storage_order): Likewise.
9874         * genrecog.c (validate_pattern): Likewise.
9875         * hsa-gen.c (gen_hsa_addr): Likewise.
9876         * internal-fn.c (expand_arith_overflow): Likewise.
9877         * ira-color.c (allocno_copy_cost_saving): Likewise.
9878         * lra-assigns.c (find_hard_regno_for_1): Likewise.
9879         * lra-constraints.c (prohibited_class_reg_set_mode_p): Likewise.
9880         (process_invariant_for_inheritance): Likewise.
9881         * lra-eliminations.c (move_plus_up): Likewise.
9882         * omp-low.c (lower_oacc_reductions): Likewise.
9883         * simplify-rtx.c (simplify_subreg): Likewise.
9884         * target.def (TARGET_SETUP_INCOMING_VARARG_BOUNDS): Likewise.
9885         (TARGET_CHKP_BOUND_MODE): Likewise..
9886         * targhooks.c (default_chkp_bound_mode): Likewise.
9887         (default_setup_incoming_vararg_bounds): Likewise.
9888         * targhooks.h (default_chkp_bound_mode): Likewise.
9889         (default_setup_incoming_vararg_bounds): Likewise.
9890         * tree-ssa-math-opts.c (divmod_candidate_p): Likewise.
9891         * tree-vect-loop.c (calc_vec_perm_mask_for_shift): Likewise.
9892         (have_whole_vector_shift): Likewise.
9893         * tree-vect-stmts.c (vectorizable_load): Likewise.
9894         * doc/tm.texi: Regenerate.
9896 2017-07-05  Georg-Johann Lay  <avr@gjlay.de>
9898         Graceful degrade if Binutils PR21472 is not available.
9900         PR target/81072
9901         * configure.ac [target=avr]: WARN instead of ERROR if avrxmega3
9902         .rodata in flash test fails.
9903         (HAVE_LD_AVR_AVRXMEGA3_RODATA_IN_FLASH): Define it if test passes.
9904         * confgure: Regenerate.
9905         * config.in: Regenerate.
9906         * config/avr/avr.c (avr_asm_named_section)
9907         [HAVE_LD_AVR_AVRXMEGA3_RODATA_IN_FLASH]: Only trigger
9908         __do_copy_data for stuff in .rodata if flash_pm_offset = 0.
9909         (avr_asm_init_sections): Same.
9911 2017-07-05  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
9913         * config/arm/neon.md (fma<VCVTF:mode>4): Remove %?.
9914         (fma<VH:mode>4_intrinsic): Likewise.
9915         (*fmsub<VCVTF:mode>4): Likewise.
9916         (*fmsub<VH:mode>4_intrinsic): Likewise.
9918 2017-07-05  Georg-Johann Lay  <avr@gjlay.de>
9920         PR target/81305
9921         * config/avr/avr.c (avr_out_movhi_mr_r_xmega) [CONSTANT_ADDRESS_P]:
9922         Don't depend on "optimize > 0".
9923         (out_movhi_r_mr, out_movqi_mr_r): Same.
9924         (out_movhi_mr_r, out_movqi_r_mr): Same.
9925         (avr_address_cost) [CONSTANT_ADDRESS_P]: Don't depend cost for
9926         io_address_operand on "optimize > 0".
9928 2017-07-05  Bin Cheng  <bin.cheng@arm.com>
9930         * tree-loop-distribution.c: Add general explanantion on the pass.
9931         (generate_loops_for_partition): Mark distributed loop.
9932         (pg_add_dependence_edges): New parameter.  Handle alias data
9933         dependence specially and record it in the parameter if asked.
9934         (struct pg_vdata, pg_edata, pg_edge_callback_data): New structs.
9935         (init_partition_graph_vertices, add_partition_graph_edge): New.
9936         (pg_skip_alias_edge, free_partition_graph_edata_cb): New.
9937         (free_partition_graph_vdata, build_partition_graph): New.
9938         (sort_partitions_by_post_order, merge_dep_scc_partitions): New.
9939         (pg_collect_alias_ddrs, break_alias_scc_partitions): New.
9940         (data_ref_segment_size, latch_dominated_by_data_ref): New.
9941         (compute_alias_check_pairs, version_loop_by_alias_check): New.
9942         (version_for_distribution_p, finalize_partitions): New.
9943         (distribute_loop): Handle alias data dependence specially.  Factor
9944         out loop fusion code as functions and call these functions.
9946 2017-07-05  Bin Cheng  <bin.cheng@arm.com>
9948         * tree-loop-distribution.c (classify_partition): New parameter and
9949         better handle reduction statement.
9950         (rdg_build_partitions): Revise comment.
9951         (distribute_loop): Compute statements in all partitions and pass it
9952         to classify_partition.
9954 2017-07-05  Bin Cheng  <bin.cheng@arm.com>
9956         * tree-loop-distribution.c (enum partition_type): New.
9957         (struct partition): New field type.
9958         (partition_merge_into): Add parameter.  Update partition type.
9959         (data_dep_in_cycle_p, update_type_for_merge): New functions.
9960         (build_rdg_partition_for_vertex): Compute partition type.
9961         (rdg_build_partitions): Dump partition type.
9962         (distribute_loop): Update calls to partition_merge_into.
9964 2017-07-05  Bin Cheng  <bin.cheng@arm.com>
9966         * tree-loop-distribution.c (struct ddr_hasher): New.
9967         (ddr_hasher::hash, ::equal, get_data_dependence): New function.
9968         (ddrs_table): New.
9969         (classify_partition): Call get_data_dependence.
9970         (pg_add_dependence_edges): Ditto.
9971         (distribute_loop): Release data dependence hash table.
9973 2017-07-05  Bin Cheng  <bin.cheng@arm.com>
9975         * tree-loop-distribution.c (ref_base_address): Delete.
9976         (similar_memory_accesses): Rename ...
9977         (share_memory_accesses): ... to this.  Check if partitions access
9978         the same memory reference.
9979         (distribute_loop): Call share_memory_accesses.
9981 2017-07-05  Bin Cheng  <bin.cheng@arm.com>
9983         * tree-loop-distribution.c (struct partition): New field recording
9984         its data reference.
9985         (partition_alloc, partition_free): Init and release data refs.
9986         (partition_merge_into): Merge data refs.
9987         (build_rdg_partition_for_vertex): Collect data refs for partition.
9988         (pg_add_dependence_edges): Change parameters from vector to bitmap.
9989         Update uses.
9990         (distribute_loop): Remve data refs from vertice data of partition
9991         graph.
9993 2017-07-05  Bin Cheng  <bin.cheng@arm.com>
9995         * tree-loop-distribution.c (params.h): Include header file.
9996         (MAX_DATAREFS_NUM, DR_INDEX): New macro.
9997         (datarefs_vec): New global var.
9998         (create_rdg_vertices): Use datarefs_vec directly.
9999         (free_rdg): Don't free data references.
10000         (build_rdg): Update use.  Don't free data references.
10001         (distribute_loop): Compute global variable for data references.
10002         Bail out if there are too many data references.
10004 2017-07-05  Bin Cheng  <bin.cheng@arm.com>
10006         * tree-loop-distribution.c (loop_nest): New global var.
10007         (build_rdg): Use loop directly, rather than loop nest.
10008         (pg_add_dependence_edges): Remove loop nest parameter.  Use global
10009         variable directly.
10010         (distribute_loop): Compute global variable loop nest.  Update use.
10012 2017-07-05  Bin Cheng  <bin.cheng@arm.com>
10014         * tree-loop-distribution.c (enum fuse_type, fuse_message): New.
10015         (partition_merge_into): New parameter.  Dump reason for fusion.
10016         (distribute_loop): Update use of partition_merge_into.
10018 2017-07-05  Bin Cheng  <bin.cheng@arm.com>
10020         * tree-loop-distribution.c (bb_top_order_index): New.
10021         (bb_top_order_index_size, bb_top_order_cmp): New.
10022         (stmts_from_loop): Use topological order.
10023         (pass_loop_distribution::execute): Compute and release topological
10024         order for basic blocks.
10026 2017-07-05  Bin Cheng  <bin.cheng@arm.com>
10028         * tree-loop-distribution.c (pass_loop_distribution::execute): Skip
10029         if no loops.
10031 2017-07-05  Bin Cheng  <bin.cheng@arm.com>
10033         * cfgloop.h (struct loop): Add comment.  New field orig_loop_num.
10034         * cfgloopmanip.c (lv_adjust_loop_entry_edge): Comment change.
10035         * internal-fn.c (expand_LOOP_DIST_ALIAS): New function.
10036         * internal-fn.def (LOOP_DIST_ALIAS): New.
10037         * tree-vectorizer.c (fold_loop_vectorized_call): Rename to ...
10038         (fold_loop_internal_call): ... this.
10039         (vect_loop_dist_alias_call): New function.
10040         (set_uid_loop_bbs): Call fold_loop_internal_call.
10041         (vectorize_loops): Fold IFN_LOOP_VECTORIZED and IFN_LOOP_DIST_ALIAS
10042         internal calls.
10044 2017-07-04  Uros Bizjak  <ubizjak@gmail.com>
10046         PR target/81300
10047         * config/i386/i386.md (setcc + movzbl/and to xor + setcc peepholes):
10048         Require dead FLAGS_REG at the beginning of a peephole.
10050 2017-07-04  Uros Bizjak  <ubizjak@gmail.com>
10052         PR target/81294
10053         * config/i386/adxintrin.h (_subborrow_u32): Swap _X and _Y
10054         arguments in the call to __builtin_ia32_sbb_u32.
10055         (_subborrow_u64): Swap _X and _Y arguments in the call to
10056         __builtin_ia32_sbb_u64.
10058 2017-07-04  Jakub Jelinek  <jakub@redhat.com>
10060         PR debug/81278
10061         * tree-vrp.c (compare_assert_loc): Turn into a function template
10062         with stable template parameter.  Only test if a->e is NULL,
10063         !a->e == !b->e has been verified already.  Use e == NULL or
10064         e != NULL instead of e or ! e tests.  If stable is true, don't use
10065         iterative_hash_expr, on the other side allow a or b or both NULL
10066         and sort the NULLs last.
10067         (process_assert_insertions): Sort using compare_assert_loc<false>
10068         instead of compare_assert_loc, later sort using
10069         compare_assert_loc<true> before calling process_assert_insertions_for
10070         in a loop.  Use break instead of continue once seen NULL pointer.
10072 2017-07-04  Thomas Preud'homme  <thomas.preudhomme@arm.com>
10074         * config/arm/driver-arm.c (arm_cpu_table): Add entry for ARM
10075         Cortex-R7 and Cortex-R8 processors.
10077 2017-07-04  Jan Hubicka  <hubicka@ucw.cz>
10079         * ipa-utils.c (ipa_merge_profiles): Fix merging when dst is
10080         uninitialized while src is not.
10082 2017-07-04  Richard Earnshaw  <rearnsha@arm.com>
10084         * common/config/arm/arm-common.c: Adjust include path for
10085         arm-cpu-cdata.h
10086         * config/arm/t-arm (TM_H): Adjust path for arm-cpu.h.
10087         (arm-cpu.h): Create in build directory.  Adjust dependency rules.
10088         (arm-cpu-data.h): Likewise.
10089         (arm-cpu-cdata.h): Likewise.
10090         * config/arm/arm-cpu.h: Delete.
10091         * config/arm/arm-cpu-cdata.h: Delete.
10092         * config/arm/arm-cpu-data.h: Delete.
10094 2017-07-04  James Greenhalgh  <james.greenhalgh@arm.com>
10096         * config/arm/arm-cpus.in (cortex-a55): New.
10097         (cortex-a75): Likewise.
10098         (cortex-a75.cortex-a55): Likewise.
10099         * config/arm/driver-arm.c (arm_cpu_table): Add cortex-a55 and
10100         cortex-a75.
10101         * doc/invoke.texi (-mcpu): Document cortex-a55 and cortex-a75.
10102         * config/arm/arm-cpu-cdata.h: Regenerate.
10103         * config/arm/arm-cpu-data.h: Regenerate.
10104         * config/arm/arm-cpu.h: Regenerate.
10105         * config/arm/arm-tables.opt: Regenerate.
10106         * config/arm/arm-tune.md: Regenerate.
10108 2017-07-04  Jan Hubicka  <hubicka@ucw.cz>
10110         * haifa-sched.c (sched_create_recovery_edges): Update profile.
10112 2017-07-04  Jan Hubicka  <hubicka@ucw.cz>
10114         * bb-reorder.c (better_edge_p): Fix handling of uninitialized
10115         probability.
10117 2017-07-04  Richard Sandiford  <richard.sandiford@linaro.org>
10119         PR tree-optimization/81292
10120         * tree-ssa-strlen.c (handle_builtin_strlen): When setting
10121         full_string_p, also call adjust_related_strinfos if the adjustment
10122         is simple, otherwise invalidate related strinfos.
10124 2017-07-04  Martin Liska  <mliska@suse.cz>
10126         PR sanitizer/81040
10127         * sanopt.c (sanitize_rewrite_addressable_params): Mark the
10128         newly created variable as DECL_IGNORED_P.
10130 2017-07-04  Martin Liska  <mliska@suse.cz>
10132         PR ipa/81293
10133         * ipa-inline.c (inline_small_functions):
10134         Use xstrdup_for_dump.
10136 2017-07-04  Tom de Vries  <tom@codesourcery.com>
10138         * graph.c (draw_cfg_edges): Save and restore EDGE_DFS_BACK.
10140 2017-07-03  Dominique d'Humieres  <dominiq@lps.ens.fr>
10142         PR target/81033
10143         * config/darwin.c (darwin_function_switched_text_sections):
10144         Fix spaces.
10146 2017-07-03  Jan Hubicka  <hubicka@ucw.cz>
10148         * tree-vect-loop-manip.c (vect_do_peeling): Fix scaling up.
10150 2017-07-03  Richard Earnshaw  <rearnsha@arm.com>
10152         * doc/invoke.texi (ARM Options): Add -mbe8 and -mbe32 to option summary.
10154 2017-07-03  Richard Sandiford  <richard.sandiford@linaro.org>
10156         * tree-vect-loop.c (vect_analyze_loop_2): Treat min_scalar_loop_bound,
10157         min_profitable_iters, and th as inclusive lower bounds.
10158         Fix LOOP_VINFO_PEELING_FOR_GAPS condition.
10159         (vect_estimate_min_profitable_iters): Return inclusive lower bounds
10160         for min_profitable_iters and min_profitable_estimate.
10161         (vect_transform_loop): Treat th as an inclusive lower bound.
10162         * tree-vect-loop-manip.c (vect_loop_versioning): Likewise.
10164 2017-07-03  Dominique d'Humieres  <dominiq@lps.ens.fr>
10166         PR target/81033
10167         * config/darwin.c (darwin_function_switched_text_sections):
10168         Replace DECL_NAME with DECL_ASSEMBLER_NAME, split assemble_name_raw
10169         in two pieces, and suppress the use of buf.
10171 2017-07-03  Nathan Sidwell  <nathan@acm.org>
10173         * hash-table.h (hash_table_mod1): Fix indentation.
10175 2017-07-02  Jan Hubicka  <hubicka@ucw.cz>
10177         PR middle-end/81290
10178         * predict.c (force_edge_cold): Be more careful about propagation
10179         backward.
10180         * profile-count.h (profile_probability::guessed,
10181         profile_probability::fdo, profile_count::guessed, profile_count::fdo):
10182         New.
10183         * tree-ssa-threadupdate.c (recompute_probabilities): Result is guessed.
10185 2017-07-03  James Greenhalgh  <james.greenhalgh@arm.com>
10187         * doc/invoke.texi (rcpc architecture extension): Document it.
10189 2017-07-03  Richard Biener  <rguenther@suse.de>
10191         PR tree-optimization/60510
10192         * tree-vect-loop.c (vect_create_epilog_for_reduction): Pass in
10193         the scalar reduction PHI and use it.
10194         (vectorizable_reduction): Properly guard the single_defuse_cycle
10195         path for non-SLP reduction chains where we cannot use it.
10196         Rework reduc_def/index and vector type deduction.  Rework
10197         vector operand gathering during reduction op code-gen.
10198         * tree-vect-slp.c (vect_analyze_slp): For failed SLP reduction
10199         chains dissolve the chain and leave it to non-SLP reduction
10200         handling.
10202 2017-07-03  Richard Sandiford  <richard.sandiford@linaro.org>
10204         * tree-data-ref.h (dr_alignment): Declare.
10205         * tree-data-ref.c (dr_alignment): New function.
10206         * tree-vectorizer.h (dataref_aux): Remove base_element_aligned.
10207         * tree-vect-data-refs.c (vect_compute_data_ref_alignment): Don't
10208         set it.
10209         * tree-vect-stmts.c (vectorizable_store): Use dr_alignment.
10211 2017-07-03  Richard Sandiford  <richard.sandiford@linaro.org>
10213         * tree-data-ref.h (innermost_loop_behavior): Add base_alignment
10214         and base_misalignment fields.
10215         (DR_BASE_ALIGNMENT, DR_BASE_MISALIGNMENT): New macros.
10216         * tree-data-ref.c: Include builtins.h.
10217         (dr_analyze_innermost): Set up the new innmost_loop_behavior fields.
10218         * tree-vectorizer.h (STMT_VINFO_DR_BASE_ALIGNMENT): New macro.
10219         (STMT_VINFO_DR_BASE_MISALIGNMENT): Likewise.
10220         * tree-vect-data-refs.c: Include tree-cfg.h.
10221         (vect_compute_data_ref_alignment): Use the new innermost_loop_behavior
10222         fields instead of calculating an alignment here.
10223         (vect_analyze_data_refs): Use dr_analyze_innermost.  Dump the new
10224         innermost_loop_behavior fields.
10226 2017-07-03  Richard Sandiford  <richard.sandiford@linaro.org>
10228         * tree-data-ref.h (innermost_loop_behavior): Add a step_alignment
10229         field.
10230         (DR_STEP_ALIGNMENT): New macro.
10231         * tree-vectorizer.h (STMT_VINFO_DR_STEP_ALIGNMENT): Likewise.
10232         * tree-data-ref.c (dr_analyze_innermost): Initalize step_alignment.
10233         (create_data_ref): Print it.
10234         * tree-vect-stmts.c (vectorizable_load): Use the step alignment
10235         to tell whether the step preserves vector (mis)alignment.
10236         * tree-vect-data-refs.c (vect_compute_data_ref_alignment): Likewise.
10237         Move the check for an integer step and generalise to all INTEGER_CST.
10238         (vect_analyze_data_refs): Set DR_STEP_ALIGNMENT when setting DR_STEP.
10239         Print the outer step alignment.
10241 2017-07-03  Richard Sandiford  <richard.sandiford@linaro.org>
10243         * tree-data-ref.h (innermost_loop_behavior): Replace aligned_to
10244         with offset_alignment.
10245         (DR_ALIGNED_TO): Delete.
10246         (DR_OFFSET_ALIGNMENT): New macro.
10247         * tree-vectorizer.h (STMT_VINFO_DR_ALIGNED_TO): Delete.
10248         (STMT_VINFO_DR_OFFSET_ALIGNMENT): New macro.
10249         * tree-data-ref.c (dr_analyze_innermost): Update after above changes.
10250         (create_data_ref): Likewise.
10251         * tree-vect-data-refs.c (vect_compute_data_ref_alignment): Likewise.
10252         (vect_analyze_data_refs): Likewise.
10253         * tree-if-conv.c (if_convertible_loop_p_1): Use memset before
10254         creating dummy innermost behavior.
10256 2017-07-03  Richard Sandiford  <richard.sandiford@linaro.org>
10258         * tree-data-ref.h (dr_analyze_innermost): Replace the dr argument
10259         with a "innermost_loop_behavior *" and refeence tree.
10260         * tree-data-ref.c (dr_analyze_innermost): Likewise.
10261         (create_data_ref): Update call accordingly.
10262         * tree-predcom.c (find_looparound_phi): Likewise.
10264 2017-07-03  Richard Sandiford  <richard.sandiford@linaro.org>
10266         * tree-vectorizer.h (_stmt_vec_info): Replace individual dr_*
10267         fields with dr_wrt_vec_loop.
10268         (STMT_VINFO_DR_BASE_ADDRESS, STMT_VINFO_DR_INIT, STMT_VINFO_DR_OFFSET)
10269         (STMT_VINFO_DR_STEP, STMT_VINFO_DR_ALIGNED_TO): Update accordingly.
10270         (STMT_VINFO_DR_WRT_VEC_LOOP): New macro.
10271         (vect_dr_behavior): New function.
10272         (vect_create_addr_base_for_vector_ref): Remove loop parameter.
10273         * tree-vect-data-refs.c (vect_compute_data_ref_alignment): Use
10274         vect_dr_behavior.  Use a step_preserves_misalignment_p boolean to
10275         track whether the step preserves the misalignment.
10276         (vect_create_addr_base_for_vector_ref): Remove loop parameter.
10277         Use vect_dr_behavior.
10278         (vect_setup_realignment): Update call accordingly.
10279         (vect_create_data_ref_ptr): Likewise.  Use vect_dr_behavior.
10280         * tree-vect-loop-manip.c (vect_gen_prolog_loop_niters): Update
10281         call to vect_create_addr_base_for_vector_ref.
10282         (vect_create_cond_for_align_checks): Likewise.
10283         * tree-vect-patterns.c (vect_recog_bool_pattern): Copy
10284         STMT_VINFO_DR_WRT_VEC_LOOP as a block.
10285         (vect_recog_mask_conversion_pattern): Likewise.
10286         * tree-vect-stmts.c (compare_step_with_zero): Use vect_dr_behavior.
10287         (new_stmt_vec_info): Remove redundant zeroing.
10289 2017-07-03  Richard Earnshaw  <rearnsha@arm.com>
10291         * common/config/arm/arm-common.c (arm_be8_option): New function.
10292         * config/arm/arm-isa.h (isa_feature): Add new feature bit isa_bit_be8.
10293         (ISA_ARMv6): Add isa_bit_be8.
10294         * config/arm/arm.h (arm_be8_option): Add prototype.
10295         (BE8_SPEC_FUNCTION): New define.
10296         (EXTRA_SPEC_FUNCTIONS): Add BE8_SPEC_FUNCTION.
10297         * config/arm/arm.opt (mbig-endian): Mark as Negative of mlittle-endian.
10298         (mlittle-endian): Similarly.
10299         (mbe8, mbe32): New options.
10300         * config/arm/bpabi.h (BE8_LINK_SPEC): Call arm_be8_option.
10301         * doc/invoke.texi (ARM Options): Document -mbe8 and -mbe32.
10303 2017-07-02  Jan Hubicka  <hubicka@ucw.cz>
10305         * tree-cfg.c (gimple_find_sub_bbs): Fix profile updating.
10307 2017-07-02  Jan Hubicka  <hubicka@ucw.cz>
10309         * tree-cfgcleanup.c (want_merge_blocks_p): New function.
10310         (cleanup_tree_cfg_bb): Use it.
10311         * profile-count.h (profile_count::of_for_merging, profile_count::merge):
10312         New functions.
10313         * tree-cfg.c (gimple_merge_blocks): Use profile_count::merge.
10315 2017-07-02  Jan Hubicka  <hubicka@ucw.cz>
10317         PR bootstrap/81285
10318         * loop-doloop.c (add_test): Update profile.
10320 2017-07-03  Martin Liska  <mliska@suse.cz>
10322         PR sanitize/81040
10323         * sanopt.c (rewrite_usage_of_param): New function.
10324         (sanitize_rewrite_addressable_params): Likewise.
10325         (pass_sanopt::execute): Call rewrite_usage_of_param.
10327 2017-07-03  Richard Biener  <rguenther@suse.de>
10329         * tree-vect-loop.c (vect_create_epilog_for_reduction): Revert
10330         back to using VIEW_CONVERT_EXPR.
10332 2017-07-03  Martin Liska  <mliska@suse.cz>
10334         PR other/78366
10335         * doc/extend.texi: Document when a resolver function is
10336         generated for target_clones.
10338 2017-07-03  Martin Liska  <mliska@suse.cz>
10340         * asan.c (asan_emit_stack_protection): Unpoison just red zones
10341         and shadow memory of auto variables which are subject of
10342         use-after-scope sanitization.
10343         (asan_expand_mark_ifn): Add do set only when is_poison.
10345 2016-07-03  Richard Biener  <rguenther@suse.de>
10347         * tree-vect-loop.c (vect_analyze_loop_operations): Also analyze
10348         reduction PHIs.
10349         (vect_force_simple_reduction): Record reduction def -> phi mapping.
10350         (vectorizable_reduction): Perform reduction PHI creation when
10351         visiting a reduction PHI and adjust and simplify code generation
10352         phase of the reduction op.  Cache dts, use fold_binary, not fold_build2.
10353         (vect_transform_loop): Visit reduction PHIs.
10354         * tree-vect-slp.c (vect_get_and_check_slp_defs): Record reduction
10355         defs into the SLP tree.
10356         (vect_build_slp_tree): Reduction defs terminate the recursion.
10357         * tree-vect-stmts.c (vect_get_vec_def_for_operand_1): Allow lookup
10358         of reduction defs.
10359         (vect_get_vec_defs_for_stmt_copy): Export.
10360         (vect_get_vec_defs): Likewise.
10361         * tree-vectorizer.h (struct _stmt_vec_info): Amend reduc_def
10362         purpose.
10363         (vect_get_vec_defs_for_stmt_copy): Declare.
10364         (vect_get_vec_defs): Likewise.
10366 2017-07-03  Richard Sandiford  <richard.sandiford@linaro.org>
10368         * tree-data-ref.c (dr_analyze_innermost): Replace the "nest"
10369         parameter with a "loop" parameter and use it instead of the
10370         loop containing DR_STMT.  Don't check simple_iv when doing
10371         BB analysis.  Describe the two analysis modes in the comment.
10373 2017-07-03  Tom de Vries  <tom@codesourcery.com>
10375         PR tree-optimization/69468
10376         * tree-ssa-tail-merge.c (ignore_edge_flags): New constant.
10377         (find_same_succ_bb): Handle ignore_edge_flags.
10379 2017-07-03  Tom de Vries  <tom@codesourcery.com>
10381         PR tree-optimization/81192
10382         * tree-ssa-tail-merge.c (same_succ_hash): Use bb->loop_father->num in
10383         hash.
10384         (same_succ::equal): Don't find bbs to be equal if bb->loop_father
10385         differs.
10386         (find_same_succ_bb): Remove obsolete test on bb->loop_father->latch.
10388 2017-07-03  Tom de Vries  <tom@codesourcery.com>
10390         PR tree-optimization/81192
10391         * tree-ssa-tail-merge.c (same_succ_flush_bb): Handle
10392         BB_SAME_SUCC (bb) == NULL.
10394 2017-07-02  Jan Hubicka  <hubicka@ucw.cz>
10396         * cfgrtl.c (rtl_verify_edges): Enable checking of profile_probability
10397         consistency.
10399 2017-07-02  Jan Hubicka  <hubicka@ucw.cz>
10401         * dumpfile.c: Include profile-count.h
10402         * tree-cfg.c (gimple_duplicate_sese_tail): Drop UNUSED attributes;
10403         update profile.
10404         (insert_cond_bb): Update profile.
10405         * tree-cfg.h (insert_cond_bb): Update prototype.
10406         * tree-chkp-opt.c (chkp_optimize_string_function_calls): Update.
10407         * tree-dump.c: Do not include tree-cfg.
10409 2017-07-02  Jan Hubicka  <hubicka@ucw.cz>
10411         * bb-reorder.c (fix_up_crossing_landing_pad): Update profile.
10413 2017-07-02  Jan Hubicka  <hubicka@ucw.cz>
10415         * expect.c (dw2_build_landing_pads): Update profile of the landing pad
10416         bb.
10418 2017-07-02  Jan Hubicka  <hubicka@ucw.cz>
10420         * tree-complex.c (expand_complex_div_wide): update profile.
10422 2017-07-02  Richard Sandiford  <richard.sandiford@linaro.org>
10423             Alan Hayward  <alan.hayward@arm.com>
10424             David Sherwood  <david.sherwood@arm.com>
10426         * Makefile.in (MACHMODE_H): Remove insn-modes.h
10427         (CORETYPES_H): New define.
10428         (MOSTLYCLEANFILES): Add insn-modes-inline.h.
10429         (insn-modes-inline.h, s-modes-inline-h): New rules.
10430         (generated_files): Add insn-modes-inline.h.
10431         (RTL_BASE_H, TREE_CORE_H): Use CORETYPES_H instead of coretypes.h.
10432         (build/gensupport.o, build/ggc-none.o, build/print-rtl.o): Likewise.
10433         (build/read-md.o, build/read-rtl.o, build/rtl.o): Likewise.
10434         (build/vec.o, build/hash-table.o, build/inchash.o): Likewise.
10435         (build/gencondmd.o, build/genattr.o, build/genattr-common.o): Likewise.
10436         (build/genattrtab.o, build/genautomata.o, build/gencheck.o): Likewise.
10437         (build/gencodes.o, build/genconditions.o): Likewise.
10438         (build/genconfig.o, build/genconstants.o, build/genemit.o): Likewise.
10439         (build/genenums.o, build/genextract.o, build/genflags.o): Likewise.
10440         (build/gentarget-def.o, build/genmddeps.o, build/genopinit.o)
10441         (build/genoutput.o, build/genpeep.o, build/genpreds.o): Likewise.
10442         (build/genrecog.o, build/genmddump.o, build/genmatch.o): Likewise.
10443         (build/gencfn-macros.o, build/gcov-iov.o): Likewise.
10444         * coretypes.h: Include everything up to real.h for generators.
10445         Include insn-modes.h first.  Include wide-int-print.h after
10446         wide-int.h.  Include insn-modes-inline.h and then machmode.h.
10447         * machmode.h: Don't include insn-modes.h here.
10448         * function-tests.c: Remove includes of signop.h, machmode.h,
10449         double-int.h and wide-int.h.
10450         * rtl.h: Likewise.
10451         * gcc-rich-location.c: Remove includes of machmode.h, double-int.h
10452         and wide-int.h.
10453         * optc-save-gen.awk: Likewise.
10454         * gencheck.c (BITS_PER_UNIT): Delete dummy definition.
10455         * godump.c: Remove include of wide-int-print.h.
10456         * pretty-print.h: Likewise.
10457         * wide-int-print.cc: Likewise.
10458         * wide-int.cc: Likewise.
10459         * hash-map-tests.c: Remove include of signop.h.
10460         * hash-set-tests.c: Likewise.
10461         * rtl-tests.c: Likewise.
10462         * mkconfig.sh: Remove include of machmode.h.
10463         * genmodes.c (emit_insn_modes_h): Split emission of inline functions
10464         into...
10465         (emit_insn_modes_inline_h): ...this new function.  Emit the code
10466         into an insn-modes-inline.h header file, adding appropriate
10467         include guards and end comments.
10468         (emit_insn_modes_c_header): Remove include of machmode.h.
10469         (emit_min_insn_modes_c_header): Include coretypes.h rather than
10470         machmode.h.
10471         (main): Handle -i flag and call emit_insn_modes_inline_h when
10472         it is passed.
10474 2017-07-02  Richard Sandiford  <richard.sandiford@linaro.org>
10476         * tree-ssa-strlen.c (strinfo): Rename the length field to
10477         nonzero_chars.  Add a full_string_p field.
10478         (compare_nonzero_chars, zero_length_string_p): New functions.
10479         (get_addr_stridx): Add an offset_out parameter.
10480         Use compare_nonzero_chars.
10481         (get_stridx): Update accordingly.  Use compare_nonzero_chars.
10482         (new_strinfo): Update after above changes to strinfo.
10483         (set_endptr_and_length): Set full_string_p.
10484         (get_string_length): Update after above changes to strinfo.
10485         (unshare_strinfo): Update call to new_strinfo.
10486         (maybe_invalidate): Likewise.
10487         (get_stridx_plus_constant): Change off to unsigned HOST_WIDE_INT.
10488         Use compare_nonzero_chars and zero_string_p.  Treat nonzero_chars
10489         as a uhwi instead of an shwi.  Update after above changes to
10490         strinfo and new_strinfo.
10491         (zero_length_string): Assert that chainsi contains full strings.
10492         Use zero_length_string_p.  Update call to new_strinfo.
10493         (adjust_related_strinfos): Update after above changes to strinfo.
10494         Copy full_string_p from origsi.
10495         (adjust_last_stmt): Use zero_length_string_p.
10496         (handle_builtin_strlen): Update after above changes to strinfo and
10497         new_strinfo.  Install the lhs as the string length if the previous
10498         entry didn't describe a full string.
10499         (handle_builtin_strchr): Update after above changes to strinfo
10500         and new_strinfo.
10501         (handle_builtin_strcpy): Likewise.
10502         (handle_builtin_strcat): Likewise.
10503         (handle_builtin_malloc): Likewise.
10504         (handle_pointer_plus): Likewise.
10505         (handle_builtin_memcpy): Likewise.  Track nonzero characters
10506         that aren't necessarily followed by a nul terminator.
10507         (handle_char_store): Likewise.
10509 2017-07-02  Richard Sandiford  <richard.sandiford@linaro.org>
10511         PR tree-optimization/80769
10512         * tree-ssa-strlen.c (strinfo): Document that "stmt" is also used
10513         for malloc and calloc.  Document the new invariant that all related
10514         strinfos have delayed lengths or none do.
10515         (verify_related_strinfos): Move earlier in file.
10516         (set_endptr_and_length): New function, split out from...
10517         (get_string_length): ...here.  Also set the lengths of related
10518         strinfos.
10519         (zero_length_string): Assert that chainsi has known (rather than
10520         delayed) lengths.
10521         (adjust_related_strinfos): Likewise.
10523 2017-07-02  Richard Sandiford  <richard.sandiford@linaro.org>
10525         PR tree-optimization/81136
10526         * tree-vect-data-refs.c (vect_update_misalignment_for_peel): Only
10527         assert that two references with the same misalignment have the same
10528         compile-time misalignment if those compile-time misalignments
10529         are known.
10531 2017-07-01  Andi Kleen  <ak@linux.intel.com>
10533         * print-tree.c (print_node): Print all attributes.
10535 2017-07-01  Jan Hubicka  <hubicka@ucw.cz>
10537         * cfg.c (scale_bbs_frequencies): New function.
10538         * cfg.h (scale_bbs_frequencies): Declare it.
10539         * cfgloopanal.c (single_likely_exit): Cleanup.
10540         * cfgloopmanip.c (scale_loop_frequencies): Take profile_probability
10541         as parameter.
10542         (scale_loop_profile): Likewise.
10543         (loop_version): Likewise.
10544         (create_empty_loop_on_edge): Update.
10545         * cfgloopmanip.h (scale_loop_frequencies, scale_loop_profile,
10546         scale_loop_frequencies, scale_loop_profile, loopify,
10547         loop_version): Update prototypes.
10548         * modulo-sched.c (sms_schedule): Update.
10549         * predict.c (unlikely_executed_edge_p): Also check probability.
10550         (probably_never_executed_edge_p): Fix typo.
10551         * tree-if-conv.c (version_loop_for_if_conversion): Update.
10552         * tree-parloops.c (gen_parallel_loop): Update.
10553         * tree-ssa-loop-ivcanon.c (try_peel_loop): Update.
10554         * tree-ssa-loop-manip.c (tree_transform_and_unroll_loop): Update.
10555         * tree-ssa-loop-split.c (split_loop): Update.
10556         * tree-ssa-loop-unswitch.c (tree_unswitch_loop): Update.
10557         * tree-vect-loop-manip.c (vect_do_peeling): Update.
10558         (vect_loop_versioning): Update.
10559         * tree-vect-loop.c (scale_profile_for_vect_loop): Update.
10561 2017-07-01  Jan Hubicka  <hubicka@ucw.cz>
10563         * trans-mem.c (split_bb_make_tm_edge): Update profile.
10565 2017-07-01  Jan Hubicka  <hubicka@ucw.cz>
10567         * tree-if-conv.c (combine_blocks): Use make_single_succ_edge
10568         to keep profile consistent.
10570 2017-07-01  Jan Hubicka  <hubicka@ucw.cz>
10572         * cfgrtl.c (rtl_flow_call_edges_add): Update profile.
10573         * tree-cfg.c (gimple_flow_call_edges_add): Likewise.
10574         * profile-count.h (max_safe_multiplier): Make unsigned.
10575         (profile_count::guessed_zero): New.
10577 2017-07-01  Jan Hubicka  <hubicka@ucw.cz>
10579         * bb-reorder.c (fix_up_crossing_landing_pad,
10580         fix_crossing_conditional_branches): Use make_single_succ_edge
10581         to keep profile consistent.
10583 2017-07-01  Jan Hubicka  <hubicka@ucw.cz>
10585         * tree-vect-loop.c (optimize_mask_stores): Use make_single_succ_edge
10586         to update profile.
10588 2017-07-01  Jakub Jelinek  <jakub@redhat.com>
10590         PR sanitizer/81262
10591         * bb-reorder.c (fix_up_fall_thru_edges): Move variable declarations to
10592         the right scopes, make sure cond_jump isn't preserved between multiple
10593         iterations.  Search for fallthru edge whenever there are 3+ edges and
10594         use find_fallthru_edge for it.
10596 2017-06-29  Jan Hubicka  <hubicka@ucw.cz>
10598         Patch by Alexander Monakov <amonakov@ispras.ru>
10599         * sel-sched-ir.c (compute_succs_info): Handle uninitialized
10600         probabilities consistently.
10602 2017-06-29  Jan Hubicka  <hubicka@ucw.cz>
10604         * pa.c (pa_expand_compare_and_swap_loop): Update call of
10605         emit_cmp_and_jump_insns.
10607 2017-06-29  Jan Hubicka  <hubicka@ucw.cz>
10609         PR ipa/81261
10610         * tree-inline.c (expand_call_inline): Combine profile statuses.
10612 2017-06-30  Andrew Pinski  <apinski@cavium.com>
10614         * tree-if-conv.c (predicate_scalar_phi): Update new_stmt if
10615         fold_stmt returned true.
10617 2017-06-30  Nathan Sidwell  <nathan@acm.org>
10619         * ggc.h (empty_string): Delete.
10620         * cfgexpand.c (expand_asm_stmt): Use plain "".
10621         * optabs.c (expand_asm_memory_barrier): Likewise.
10622         * stringpool.c (empty_string): Delete.
10623         (digit_vector, digit_string): Delete.
10624         (ggc_alloc_string): Use plain "", don't optimize single digit
10625         strings.  Use ggc_alloc_atomic.
10627 2017-06-30  Richard Earnshaw  <rearnsha@arm.com>
10629         * rtlanal.c (insn_rtx_cost): If a parallel contains exactly one
10630         comparison set and one other set, use the cost of the non-comparison
10631         set.
10633 2017-06-30  Nathan Sidwell  <nathan@acm.org>
10635         * ggc.h: Replace all 'static inline' with plain 'inline'.  Fix
10636         some formatting.
10638 2017-06-30  Peter Bergner  <bergner@vnet.ibm.com>
10640         * tree-cfg.c (group_case_labels_stmt): Merge scanning and compressing
10641         loops.  Remove now unneeded calls to gimple_switch_set_label() that
10642         just set removed labels to NULL_TREE.
10644 2017-06-30  Aldy Hernandez  <aldyh@redhat.com>
10646         * tree-ssanames.c (set_range_info_raw): Abstract from ...
10647         (set_range_info): ...here.  Only call set_range_info_raw if domain
10648         is useful.
10649         (set_nonzero_bits): Call set_range_info_raw.
10650         * tree-ssanames.h (set_range_info_raw): New.
10652 2017-06-30  Jakub Jelinek  <jakub@redhat.com>
10654         PR target/81225
10655         * config/i386/sse.md (vec_extract_lo_<mode><mask_name>): For V8FI,
10656         V16FI and VI8F_256 iterators, use <store_mask_predicate> instead
10657         of nonimmediate_operand and <store_mask_constraint> instead of m
10658         for the input operand.  For V8FI iterator, always split if input
10659         is a MEM.  For V16FI and V8SF_256 iterators, don't test if both
10660         operands are MEM if <mask_applied>.  For VI4F_256 iterator, use
10661         <store_mask_predicate> instead of register_operand and
10662         <store_mask_constraint> instead of v for the input operand.  Make
10663         sure both operands aren't MEMs for if not <mask_applied>.
10665 2017-06-30  Sylvestre Ledru  <sylvestre@debian.org>
10667         * lto-wrapper.c (copy_file) Close both file descriptors before
10668         exiting normally.
10670 2017-06-30  Martin Liska  <mliska@suse.cz>
10672         PR ipa/81214
10673         * multiple_target.c (create_dispatcher_calls): Make ifunc
10674         also for function that don't have calls or are not referenced.
10676 2017-06-30  Richard Biener  <rguenther@suse.de>
10678         * tree-vect-slp.c (vect_slp_analyze_node_operations): Only
10679         analyze the first scalar stmt.  Move vector type computation
10680         for the BB case here from ...
10681         * tree-vect-stmts.c (vect_analyze_stmt): ... here.  Guard
10682         live operation processing in the SLP case properly.
10684 2017-06-30  Richard Biener  <rguenther@suse.de>
10686         * graph.c (draw_cfg_node_succ_edges): Fix broken dot syntax.
10688 2017-06-30  Martin Liska  <mliska@suse.cz>
10690         PR sanitizer/81021
10691         * tree-eh.c (lower_resx): Call BUILT_IN_ASAN_HANDLE_NO_RETURN
10692         before BUILT_IN_UNWIND_RESUME when ASAN is used.
10694 2017-06-30  Yvan Roux  <yvan.roux@linaro.org>
10696         * doc/invoke.texi (AArch64): Add missing options and remove redundant
10697         ones.
10699 2017-06-30  Richard Biener  <rguenther@suse.de>
10701         PR tree-optimization/81249
10702         * tree-vect-loop.c (vect_create_epilog_for_reduction): Convert
10703         condition reduction result to original scalar type.
10705 2017-06-30  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
10707         * profile-count.h (enum profile_quality): Fix typos and whitespace
10708         issues.
10710 2017-06-30  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
10712         * config/s390/s390.c (s390_expand_setmem): Adjust to the new data
10713         type for branch probabilities.
10715 2017-06-29  Julian Brown  <julian@codesourcery.com>
10716             Naveen H.S  <Naveen.Hurugalawadi@cavium.com>
10718         * config/aarch64/aarch64-fusion-pairs.def: Add ALU_BRANCH entry.
10719         * config/aarch64/aarch64.c (AARCH64_FUSE_ALU_BRANCH): New fusion type.
10720         (thunderx2t99_tunings): Set AARCH64_FUSE_ALU_BRANCH flag.
10721         (aarch_macro_fusion_pair_p): Add support for AARCH64_FUSE_ALU_BRANCH.
10723 2017-06-29  Naveen H.S  <Naveen.Hurugalawadi@cavium.com>
10725         * config/aarch64/aarch64.c (aarch_macro_fusion_pair_p): Push the
10726         check for CC usage into AARCH64_FUSE_CMP_BRANCH.
10727         * config/i386/i386.c (ix86_macro_fusion_pair_p): Push the check for
10728         CC usage from generic code to here.
10729         * sched-deps.c (sched_macro_fuse_insns): Move the condition for
10730         CC usage into the target macros.
10732 2017-06-29  Maya Rashish  <coypu@sdf.org>
10734         * config/netbsd.h (NETBSD_LIB_SPEC): Add -lc when creating shared
10735         objects.
10737 2017-06-29  Jan Hubicka  <hubicka@ucw.cz>
10739         * arm/arm-builtins.c: Include profile-count.h
10740         * except.c (sjlj_emit_function_enter): Use
10741         profile_probability::unlikely.
10743 2017-06-29  Aaron Sawdey  <acsawdey@linux.vnet.ibm.com>
10745         * config/rs6000/rs6000.c (toc_relative_expr_p): Make tocrel_base
10746         and tocrel_offset be pointer args rather than implicitly using
10747         static versions.
10748         (legitimate_constant_pool_address_p, rs6000_emit_move,
10749         const_load_sequence_p, adjust_vperm): Add local tocrel_base and
10750         tocrel_offset and use in toc_relative_expr_p call.
10751         (print_operand, print_operand_address): Use static tocrel_base_oac
10752         and tocrel_offset_oac.
10753         (rs6000_output_addr_const_extra): Use static tocrel_base_oac and
10754         tocrel_offset_oac.
10756 2017-06-29  Maya Rashish  <coypu@sdf.org>
10758         * config/vax/builtins.md (ffssi2_internal): Correct constraint.
10760 2017-06-29  Eric Botcazou  <ebotcazou@adacore.com>
10762         * expr.c (expand_expr) <normal_inner_ref>: When testing for unaligned
10763         objects, take into account only the alignment of 'op0' and 'mode1' if
10764         'op0' is a MEM.
10766 2017-06-29  Steve Ellcey  <sellcey@cavium.com>
10768         * ccmp.c (ccmp_tree_comparison_p): New function.
10769         (ccmp_candidate_p): Update to use above function.
10770         (get_compare_parts): New function.
10771         (expand_ccmp_next): Update to use new functions.
10772         (expand_ccmp_expr_1): Take tree arg instead of gimple, update to use
10773         new functions.
10774         (expand_ccmp_expr): Pass tree instead of gimple to expand_ccmp_expr_1,
10775         take mode as argument.
10776         * ccmp.h (expand_ccmp_expr): Add mode as argument.
10777         * expr.c (expand_expr_real_1): Pass mode as argument.
10779 2017-06-29  Segher Boessenkool  <segher@kernel.crashing.org>
10781         * combine.c (combine_instructions): Print insns to dump_file, together
10782         with their costs.
10784 2017-06-29  Jan Hubicka  <hubicka@ucw.cz>
10786         * asan.c (asan_emit_stack_protection): Update.
10787         (create_cond_insert_point): Update.
10788         * auto-profile.c (afdo_propagate_circuit): Update.
10789         * basic-block.h (struct edge_def): Turn probability to
10790         profile_probability.
10791         (EDGE_FREQUENCY): Update.
10792         * bb-reorder.c (find_traces_1_round): Update.
10793         (better_edge_p): Update.
10794         (sanitize_hot_paths): Update.
10795         * cfg.c (unchecked_make_edge): Initialize probability to uninitialized.
10796         (make_single_succ_edge): Update.
10797         (check_bb_profile): Update.
10798         (dump_edge_info): Update.
10799         (update_bb_profile_for_threading): Update.
10800         * cfganal.c (connect_infinite_loops_to_exit): Initialize new edge
10801         probabilitycount to 0.
10802         * cfgbuild.c (compute_outgoing_frequencies): Update.
10803         * cfgcleanup.c (try_forward_edges): Update.
10804         (outgoing_edges_match): Update.
10805         (try_crossjump_to_edge): Update.
10806         * cfgexpand.c (expand_gimple_cond): Update make_single_succ_edge.
10807         (expand_gimple_tailcall): Update.
10808         (construct_init_block): Use make_single_succ_edge.
10809         (construct_exit_block): Use make_single_succ_edge.
10810         * cfghooks.c (verify_flow_info): Update.
10811         (redirect_edge_succ_nodup): Update.
10812         (split_edge): Update.
10813         (account_profile_record): Update.
10814         * cfgloopanal.c (single_likely_exit): Update.
10815         * cfgloopmanip.c (scale_loop_profile): Update.
10816         (set_zero_probability): Remove.
10817         (duplicate_loop_to_header_edge): Update.
10818         * cfgloopmanip.h (loop_version): Update prototype.
10819         * cfgrtl.c (try_redirect_by_replacing_jump): Update.
10820         (force_nonfallthru_and_redirect): Update.
10821         (update_br_prob_note): Update.
10822         (rtl_verify_edges): Update.
10823         (purge_dead_edges): Update.
10824         (rtl_lv_add_condition_to_bb): Update.
10825         * cgraph.c: (cgraph_edge::redirect_call_stmt_to_calle): Update.
10826         * cgraphunit.c (init_lowered_empty_function): Update.
10827         (cgraph_node::expand_thunk): Update.
10828         * cilk-common.c: Include profile-count.h
10829         * dojump.c (inv): Remove.
10830         (jumpifnot): Update.
10831         (jumpifnot_1): Update.
10832         (do_jump_1): Update.
10833         (do_jump): Update.
10834         (do_jump_by_parts_greater_rtx): Update.
10835         (do_compare_rtx_and_jump): Update.
10836         * dojump.h (jumpifnot, jumpifnot_1, jumpif_1, jumpif, do_jump,
10837         do_jump_1. do_compare_rtx_and_jump): Update prototype.
10838         * dwarf2cfi.c: Include profile-count.h
10839         * except.c (dw2_build_landing_pads): Use make_single_succ_edge.
10840         (sjlj_emit_dispatch_table): Likewise.
10841         * explow.c: Include profile-count.h
10842         * expmed.c (emit_store_flag_force): Update.
10843         (do_cmp_and_jump): Update.
10844         * expr.c (compare_by_pieces_d::generate): Update.
10845         (compare_by_pieces_d::finish_mode): Update.
10846         (emit_block_move_via_loop): Update.
10847         (store_expr_with_bounds): Update.
10848         (store_constructor): Update.
10849         (expand_expr_real_2): Update.
10850         (expand_expr_real_1): Update.
10851         * expr.h (try_casesi, try_tablejump): Update prototypes.
10852         * gimple-pretty-print.c (dump_probability): Update.
10853         (dump_profile): New.
10854         (dump_gimple_label): Update.
10855         (dump_gimple_bb_header): Update.
10856         * graph.c (draw_cfg_node_succ_edges): Update.
10857         * hsa-gen.c (convert_switch_statements): Update.
10858         * ifcvt.c (cheap_bb_rtx_cost_p): Update.
10859         (find_if_case_1): Update.
10860         (find_if_case_2): Update.
10861         * internal-fn.c (expand_arith_overflow_result_store): Update.
10862         (expand_addsub_overflow): Update.
10863         (expand_neg_overflow): Update.
10864         (expand_mul_overflow): Update.
10865         (expand_vector_ubsan_overflow): Update.
10866         * ipa-cp.c (good_cloning_opportunity_p): Update.
10867         * ipa-split.c (split_function): Use make_single_succ_edge.
10868         * ipa-utils.c (ipa_merge_profiles): Update.
10869         * loop-doloop.c (add_test): Update.
10870         (doloop_modify): Update.
10871         * loop-unroll.c (compare_and_jump_seq): Update.
10872         (unroll_loop_runtime_iterations): Update.
10873         * lra-constraints.c (lra_inheritance): Update.
10874         * lto-streamer-in.c (input_cfg): Update.
10875         * lto-streamer-out.c (output_cfg): Update.
10876         * mcf.c (adjust_cfg_counts): Update.
10877         * modulo-sched.c (sms_schedule): Update.
10878         * omp-expand.c (expand_omp_for_init_counts): Update.
10879         (extract_omp_for_update_vars): Update.
10880         (expand_omp_ordered_sink): Update.
10881         (expand_omp_for_ordered_loops): Update.
10882         (expand_omp_for_generic): Update.
10883         (expand_omp_for_static_nochunk): Update.
10884         (expand_omp_for_static_chunk): Update.
10885         (expand_cilk_for): Update.
10886         (expand_omp_simd): Update.
10887         (expand_omp_taskloop_for_outer): Update.
10888         (expand_omp_taskloop_for_inner): Update.
10889         * omp-simd-clone.c (simd_clone_adjust): Update.
10890         * optabs.c (expand_doubleword_shift): Update.
10891         (expand_abs): Update.
10892         (emit_cmp_and_jump_insn_1): Update.
10893         (expand_compare_and_swap_loop): Update.
10894         * optabs.h (emit_cmp_and_jump_insns): Update prototype.
10895         * predict.c (predictable_edge_p): Update.
10896         (edge_probability_reliable_p): Update.
10897         (set_even_probabilities): Update.
10898         (combine_predictions_for_insn): Update.
10899         (combine_predictions_for_bb): Update.
10900         (propagate_freq): Update.
10901         (estimate_bb_frequencies): Update.
10902         (force_edge_cold): Update.
10903         * profile-count.c (profile_count::dump): Add missing space into dump.
10904         (profile_count::debug): Add newline.
10905         (profile_count::differs_from_p): Explicitly convert to unsigned.
10906         (profile_count::stream_in): Update.
10907         (profile_probability::dump): New member function.
10908         (profile_probability::debug): New member function.
10909         (profile_probability::differs_from_p): New member function.
10910         (profile_probability::differs_lot_from_p): New member function.
10911         (profile_probability::stream_in): New member function.
10912         (profile_probability::stream_out): New member function.
10913         * profile-count.h (profile_count_quality): Rename to ...
10914         (profile_quality): ... this one.
10915         (profile_probability): New.
10916         (profile_count): Update.
10917         * profile.c (compute_branch_probabilities): Update.
10918         * recog.c (peep2_attempt): Update.
10919         * sched-ebb.c (schedule_ebbs): Update.
10920         * sched-rgn.c (find_single_block_region): Update.
10921         (compute_dom_prob_ps): Update.
10922         (schedule_region): Update.
10923         * sel-sched-ir.c (compute_succs_info): Update.
10924         * stmt.c (struct case_node): Update.
10925         (do_jump_if_equal): Update.
10926         (get_outgoing_edge_probs): Update.
10927         (conditional_probability): Update.
10928         (emit_case_dispatch_table): Update.
10929         (expand_case): Update.
10930         (expand_sjlj_dispatch_table): Update.
10931         (emit_case_nodes): Update.
10932         * targhooks.c: Update.
10933         * tracer.c (better_p): Update.
10934         (find_best_successor): Update.
10935         * trans-mem.c (expand_transaction): Update.
10936         * tree-call-cdce.c: Update.
10937         * tree-cfg.c (gimple_split_edge): Upate.
10938         (move_sese_region_to_fn): Upate.
10939         * tree-cfgcleanup.c (cleanup_control_expr_graph): Upate.
10940         * tree-eh.c (lower_resx): Upate.
10941         (cleanup_empty_eh_move_lp): Upate.
10942         * tree-if-conv.c (version_loop_for_if_conversion): Update.
10943         * tree-inline.c (copy_edges_for_bb): Update.
10944         (copy_cfg_body): Update.
10945         * tree-parloops.c (gen_parallel_loop): Update.
10946         * tree-profile.c (gimple_gen_ic_func_profiler): Update.
10947         (gimple_gen_time_profiler): Update.
10948         * tree-ssa-dce.c (remove_dead_stmt): Update.
10949         * tree-ssa-ifcombine.c (update_profile_after_ifcombine): Update.
10950         * tree-ssa-loop-im.c (execute_sm_if_changed): Update.
10951         * tree-ssa-loop-ivcanon.c (remove_exits_and_undefined_stmts): Update.
10952         (unloop_loops): Update.
10953         (try_peel_loop): Update.
10954         * tree-ssa-loop-manip.c (tree_transform_and_unroll_loop): Update.
10955         * tree-ssa-loop-split.c (connect_loops): Update.
10956         (split_loop): Update.
10957         * tree-ssa-loop-unswitch.c (tree_unswitch_loop): Update.
10958         (hoist_guard): Update.
10959         * tree-ssa-phionlycprop.c (propagate_rhs_into_lhs): Update.
10960         * tree-ssa-phiopt.c (replace_phi_edge_with_variable): Update.
10961         (value_replacement): Update.
10962         * tree-ssa-reassoc.c (branch_fixup): Update.
10963         * tree-ssa-tail-merge.c (replace_block_by): Update.
10964         * tree-ssa-threadupdate.c (remove_ctrl_stmt_and_useless_edges): Update.
10965         (create_edge_and_update_destination_phis): Update.
10966         (compute_path_counts): Update.
10967         (recompute_probabilities): Update.
10968         (update_joiner_offpath_counts): Update.
10969         (freqs_to_counts_path): Update.
10970         (duplicate_thread_path): Update.
10971         * tree-switch-conversion.c (hoist_edge_and_branch_if_true): Update.
10972         (struct switch_conv_info): Update.
10973         (gen_inbound_check): Update.
10974         * tree-vect-loop-manip.c (slpeel_add_loop_guard): Update.
10975         (vect_do_peeling): Update.
10976         (vect_loop_versioning): Update.
10977         * tree-vect-loop.c (scale_profile_for_vect_loop): Update.
10978         (optimize_mask_stores): Update.
10979         * ubsan.c (ubsan_expand_null_ifn): Update.
10980         * value-prof.c (gimple_divmod_fixed_value): Update.
10981         (gimple_divmod_fixed_value_transform): Update.
10982         (gimple_mod_pow2): Update.
10983         (gimple_mod_pow2_value_transform): Update.
10984         (gimple_mod_subtract): Update.
10985         (gimple_mod_subtract_transform): Update.
10986         (gimple_ic): Update.
10987         (gimple_stringop_fixed_value): Update.
10988         (gimple_stringops_transform): Update.
10989         * value-prof.h: Update.
10991 2017-06-29  Carl Love  <cel@us.ibm.com>
10993         * config/rs6000/rs6000-c.c: Add support for built-in functions
10994         vector signed int vec_signed (vector float);
10995         vector signed long long vec_signed (vector double);
10996         vector signed int vec_signed2 (vector double, vector double);
10997         vector signed int vec_signede (vector double);
10998         vector signed int vec_signedo (vector double);
10999         * config/rs6000/rs6000.c (rs6000_generate_vsigned2_code): Add
11000         instruction generator.
11001         * config/rs6000/vsx.md (UNSPEC_VSX_XVCVSPSXWS, UNSPEC_VSX_XVCVSPSXDS,
11002         UNSPEC_VSX_VSIGNED2): Add UNSPECS.
11003         (vsx_xvcvspsxws, vsx_xvcvdpuxds_scale, vsx_xvcvspuxws, vsigned2_v2df):
11004         Add define_insn.
11005         (vsignedo_v2df, vsignede_v2df, vunsigned2_v2df, vunsignedo_v2df,
11006         vunsignede_v2df): Add define_expands.
11007         * config/rs6000/rs6000-builtin.def (VEC_SIGNED, VEC_UNSIGNED,
11008         VEC_SIGNED2, VEC_UNSIGNED2, VEC_SIGNEDE, VEC_UNSIGNEDE, VEC_SIGNEDO,
11009         VEC_UNSIGNEDO): Add definitions.
11010         * config/vsx.md (UNSPEC_VSX_XVCVSPSXWS, UNSPEC_VSX_XVCVSPSXDS,
11011         UNSPEC_VSX_VSIGNED2): Add UNSPECs.
11012         (vsx_xvcvspsxws, vsx_xvcvspuxws): Add define_insn.
11013         (vsigned2_v2df, vsigendo_v2df, vsignede_v2df,
11014         vunsigned2_v2df, vunsignedo_v2df, vunsignede_v2df): Add define_expands.
11015         * config/rs6000/altivec.h (vec_signed, vec_signed2,
11016         vec_signede and vec_signedo, vec_unsigned, vec_unsigned2,
11017         vec_unsignede, vec_unsignedo): Add builtin defines.
11018         * config/rs6000-protos.h (rs6000_generate_vsigned2_code): Add extern
11019         declaration.
11020         * doc/extend.texi: Update the built-in documentation file for the
11021         new built-in functions.
11023 2017-06-29  Richard Biener  <rguenther@suse.de>
11025         * tree-vect-loop.c (vect_analyze_scalar_cycles_1): Do not add
11026         reduction chains to LOOP_VINFO_REDUCTIONS.
11027         * tree-vect-slp.c (vect_analyze_slp): Continue looking for
11028         SLP reductions after processing reduction chains.
11030 2017-06-29  Nathan Sidwell  <nathan@acm.org>
11032         * builtins.c (fold_builtin_FUNCTION): Use
11033         lang_hooks.decl_printable_name.
11035 2017-06-29  Peter Bergner  <bergner@vnet.ibm.com>
11037         PR middle-end/81194
11038         * cfgexpand.c (expand_gimple_stmt_1): Handle switch statements
11039         with only one label.
11040         * stmt.c (expand_case): Assert NCASES is greater than one.
11042 2017-06-29  Richard Biener  <rguenther@suse.de>
11044         * tree-cfg.c (group_case_labels_stmt): Return whether we changed
11045         anything.
11046         (group_case_labels): Likewise.
11047         (find_taken_edge): Push sanity checking on val to workers...
11048         (find_taken_edge_cond_expr): ... here
11049         (find_taken_edge_switch_expr): ... and here, handle cases
11050         with just a default label.
11051         * tree-cfg.h (group_case_labels_stmt): Adjust prototype.
11052         (group_case_labels): Likewise.
11053         * tree-cfgcleanup.c (execute_cleanup_cfg_post_optimizing): When
11054         group_case_labels does anything cleanup the CFG again.
11056 2017-06-29  Bin Cheng  <bin.cheng@arm.com>
11058         PR tree-optimization/81196
11059         * tree-ssa-loop-niter.c (number_of_iterations_cond): Handle loop
11060         exit condition comparing two IVs.
11062 2017-06-29  Richard Earnshaw  <rearnsha@arm.com>
11064         * config/arm/parsecpu.awk (gen_comm_data): Add initializer for
11065         profile to the dummy entry at the end of the list of architectures.
11066         * config/arm/arm-cpu-cdata.h: Regenerated.
11068 2017-06-29  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
11069             Michael Collison <michael.collison@arm.com>
11071         PR target/70119
11072         * config/aarch64/aarch64.md (*aarch64_<optab>_reg_<mode>3_mask1):
11073         New pattern.
11074         (*aarch64_reg_<mode>3_neg_mask2): New pattern.
11075         (*aarch64_reg_<mode>3_minus_mask): New pattern.
11076         (*aarch64_<optab>_reg_di3_mask2): New pattern.
11077         * config/aarch64/aarch64.c (aarch64_rtx_costs): Account for cost
11078         of shift when the shift amount is masked with constant equal to
11079         the size of the mode.
11080         * config/aarch64/predicates.md (subreg_lowpart_operator): New
11081         predicate.
11083 2017-06-29  Martin Liska  <mliska@suse.cz>
11085         * config/i386/i386.opt: Change range from [1,5] to [0,5].
11087 2017-06-29  Yury Gribov  <tetra2005@gmail.com>
11089         PR bootstrap/80565
11090         * ipa-cp.c (allocate_and_init_ipcp_value): Add initialization
11091         code.
11092         * ipa-inline.h
11093         (edge_growth_cache_entry::edge_growth_cache_entry): New
11094         function.
11095         (reset_edge_growth_cache): Update to use constructor.
11097 2017-06-28  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
11099         * config/aarch64/aarch64.h (AARCH64_EXPAND_ALIGNMENT): New.
11100         (DATA_ALIGNMENT): Update to use AARCH64_EXPAND_ALIGNMENT.
11101         (LOCAL_ALIGNMENT): Update to use AARCH64_EXPAND_ALIGNMENT.
11103 2017-06-28  Sebastian Peryt  <sebastian.peryt@intel.com>
11105         * config/i386/avx512vlintrin.h (_mm256_permutexvar_epi64)
11106         (_mm256_permutexvar_epi32, _mm256_permutex_epi64): New intrinsics.
11108 2017-06-28  Szabolcs Nagy  <szabolcs.nagy@arm.com>
11110         * config.gcc (*-linux-musl*): Add t-musl tmake_file.
11111         (*-linux-uclibc*): Add t-uclibc tmake_file.
11112         * config/t-musl: New.
11113         * config/t-uclibc: New.
11115 2017-06-28  Richard Earnshaw  <rearnsha@arm.com>
11117         * config/arm/parsecpu.awk (profile): Parse new keyword in an arch
11118         context.
11119         (gen_comm_data): Emit architectural setting of arch_prof.
11120         * config/arm/arm-cpus.in (armv6-m, armv6s-m, armv7-a, armv7ve): Set the
11121         profile.
11122         (armv7-r, armv7-m, armv7e-m, armv8-a, armv8.1-a, armv8.2-a): Likewise.
11123         (armv8-m.base, armv8-m.main): Likewise.
11124         * arm-protos.h (arm_build_target): Add profile field.
11125         (arch_option): Likewise.
11126         * config/arm/arm.c (arm_configure_build_target): Copy the profile to
11127         the active target.
11128         * config/arm/arm.h (TARGET_ARM_ARCH_PROFILE): Use
11129         arm_active_target.profile.
11131 2017-06-28  Richard Biener  <rguenther@suse.de>
11133         PR middle-end/81227
11134         * fold-const.c (negate_expr_p): Use TYPE_UNSIGNED, not
11135         TYPE_OVERFLOW_WRAPS.
11136         * match.pd (negate_expr_p): Likewise.
11137         * tree-ssa-reassoc.c (optimize_range_tests_diff): Use
11138         fold_build2, not fold_binary.
11140 2017-06-28  Wilco Dijkstra  <wdijkstr@arm.com>
11142         * config/aarch64/aarch64 (aarch64_expand_mov_immediate):
11143         Convert memory address to Pmode.
11144         (aarch64_print_operand): Assert MEM operands are always Pmode.
11146 2017-06-28  Wilco Dijkstra  <wdijkstr@arm.com>
11148         PR target/79665
11149         * config/arm/aarch-common.c (arm_no_early_alu_shift_dep):
11150         Remove redundant if.
11151         (aarch_forward_to_shift_is_not_shifted_reg): Remove.
11152         * config/arm/aarch-common-protos.h
11153         (aarch_forward_to_shift_is_not_shifted_re): Remove.
11154         * config/arm/cortex-a53.md: Use arm_no_early_alu_shift_dep in bypass.
11156 2017-06-28  Michael Meissner  <meissner@linux.vnet.ibm.com>
11158         PR ipa/81238
11159         * multiple_target.c (create_dispatcher_calls): Set the default
11160         clone to be static, not public.
11162 2017-06-28  Richard Biener  <rguenther@suse.de>
11164         * tree-vect-loop.c (vectorizable_reduction): Move special
11165         cond reduction IV var creation ...
11166         (vect_create_epilog_for_reduction): ... here.  Remove induction_index
11167         parameter.  Use STMT_VINFO_VECTYPE.
11168         * tree-vect-slp.c (vect_get_constant_vectors): Properly reset
11169         constant_p.
11171 2017-06-28  Martin Liska  <mliska@suse.cz>
11173         PR ipa/81128
11174         * ipa-visibility.c (non_local_p): Handle visibility.
11176 2017-06-28  Martin Liska  <mliska@suse.cz>
11178         PR driver/79659
11179         * common.opt: Add IntegerRange to various options.
11180         * opt-functions.awk (integer_range_info): New function.
11181         * optc-gen.awk: Add integer_range_info to cl_options struct.
11182         * opts-common.c (decode_cmdline_option): Handle
11183         CL_ERR_INT_RANGE_ARG.
11184         (cmdline_handle_error): Likewise.
11185         * opts.c (print_filtered_help): Show valid interval in
11186         when --help is provided.
11187         * opts.h (struct cl_option): Add range_min and range_max fields.
11188         * config/i386/i386.opt: Add IntegerRange for -mbranch-cost.
11190 2017-06-28  Marc Glisse  <marc.glisse@inria.fr>
11192         * match.pd ((X & ~Y) | (~X & Y)): Generalize to + and ^.
11193         (x * C EQ/NE y * C): New transformation.
11195 2017-06-28  Christophe Lyon  <christophe.lyon@linaro.org>
11197         * genmultilib (combination_space): Accept '+' in option names.
11199 2017-06-28  Martin Liska  <mliska@suse.cz>
11201         PR sanitizer/81224
11202         * asan.c (instrument_derefs): Bail out inner references
11203         that are hard register variables.
11205 2017-06-28  Jakub Jelinek  <jakub@redhat.com>
11207         PR target/81175
11208         * config/i386/i386.c (ix86_init_mmx_sse_builtins): Use def_builtin
11209         rather than def_builtin_pure for __builtin_ia32_gatherpf*.
11211 2017-06-28  Richard Biener  <rguenther@suse.de>
11213         * tree-vectorizer.h (vect_get_vec_defs): Remove.
11214         (vect_get_slp_defs): Adjust.
11215         * tree-vect-loop.c (get_initial_defs_for_reduction): Split
11216         out from ...
11217         * tree-vect-slp.c (vect_get_constant_vectors): ... here and
11218         simplify.
11219         * tree-vect-loop.c (vect_create_epilog_for_reduction): Use
11220         get_initial_defs_for_reduction instead of vect_get_vec_defs.
11221         (vectorizable_reduction): Adjust.
11222         * tree-vect-slp.c (vect_get_constant_vectors): Remove reduction
11223         handling.
11224         (vect_get_slp_defs): Likewise.
11225         * tree-vect-stmts.c (vect_get_vec_defs): Make static and adjust.
11226         (vectorizable_bswap): Adjust.
11227         (vectorizable_call): Likewise.
11228         (vectorizable_conversion): Likewise.
11229         (vectorizable_assignment): Likewise.
11230         (vectorizable_shift): Likewise.
11231         (vectorizable_operation): Likewise.
11232         (vectorizable_store): Likewise.
11233         (vectorizable_condition): Likewise.
11234         (vectorizable_comparison): Likewise.
11236 2017-06-28  Michael Collison  <michael.collison@arm.com>
11238         PR target/68535
11239         * config/arm/arm.c (gen_ldm_seq): Remove last unnecessary
11240         set of base_reg
11241         (arm_gen_movmemqi): Removed unused variable 'i'.
11242         Convert 'for' loop into 'while' loop.
11243         (arm_expand_prologue): Remove last unnecessary set of insn.
11244         (thumb_pop): Remove unused variable 'pushed_words'.
11245         (thumb_exit): Remove last unnecessary set of regs_to_pop.
11247 2017-06-28  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
11249         * config/s390/predicates.md: Use s390_rel_address_ok_p.
11250         * config/s390/s390-protos.h: Add prototype of
11251         s390_rel_address_ok_p.
11252         * config/s390/s390.c (s390_got_symbol): New function.
11253         (s390_rel_address_ok_p): New function.
11254         (legitimize_pic_address): Use s390_rel_address_ok_p.
11255         (s390_load_got): Use s390_got_symbol.
11256         (s390_option_override): Issue error if
11257         -mno-pic-data-is-text-relative is used without -fpic/-fPIC.
11258         * config/s390/s390.h (TARGET_DEFAULT_PIC_DATA_IS_TEXT_RELATIVE):
11259         New macro.
11260         * config/s390/s390.opt: New option mpic-data-is-text-relative.
11262 2017-06-27  Andrew Pinski  <apinski@cavium.com>
11264         * match.pd (X >/>=/</<= 0 ? 1.0 : -1.0): New patterns.
11265         (X * copysign (1.0, X)): New pattern.
11266         (X * copysign (1.0, -X)): New pattern.
11267         (copysign (-1.0, CST)): New pattern.
11269 2017-06-27  Joseph Myers  <joseph@codesourcery.com>
11271         * genmultilib (combination_space): Remove variable.
11272         Validate reuse rules against regular expression for any sequence
11273         of multilib options in any order.
11275 2017-06-27  Michael Collison  <michael.collison@arm.com>
11277         * config/aarch64/aarch64-simd.md (aarch64_combine<mode>): Directly
11278         call aarch64_split_simd_combine.
11279         * (aarch64_combine_internal<mode>): Delete pattern.
11280         * config/aarch64/aarch64.c (aarch64_split_simd_combine):
11281         Allow register and subreg operands.
11283 2017-06-27  Jerome Lambourg  <lambourg@adacore.com>
11285         * config/i386/vxworks.h (ASM_SPEC): Remove definition. No target
11286         specific need, just fallback on defaults.
11287         (ASM_OUTPUT_ALIGNED_BSS): Add #undef before #define.
11289 2017-06-27  Jerome Lambourg  <lambourg@adacore.com>
11290             Olivier Hainque  <hainque@adacore.com>
11292         * config/i386/vxworks.h (DBX_REGISTER_NUMBER): Pick distinct
11293         map for 64bits.
11294         (TARGET_OS_CPP_BUILTINS): builtin_define CPU to X86_64 for 64bit
11295         targets. Pick a default if no particular attempt applied.
11296         (STACK_CHECK_PROTECT): Double for 64bit targets, which have
11297         larger contexts.
11299 2017-06-27  Jerome Lambourg  <lambourg@adacore.com>
11301         * config.gcc (i*86-wrs-vxworks7): Handle new acceptable triplet.
11302         (x86_64-wrs-vxworks7): Likewise.
11304 2017-06-27  Marek Polacek  <polacek@redhat.com>
11306         PR sanitizer/81223
11307         * ubsan.c (instrument_null): Check get_base_address's result for null.
11309 2017-06-27  Marc Glisse  <marc.glisse@inria.fr>
11311         * match.pd ((A+-B)+(C-A), (A+B)-(A-C)): New transformations.
11313 2017-06-27  Marc Glisse  <marc.glisse@inria.fr>
11315         * builtin-types.def (BT_FENV_T_PTR, BT_CONST_FENV_T_PTR,
11316         BT_FEXCEPT_T_PTR, BT_CONST_FEXCEPT_T_PTR): New primitive types.
11317         (BT_FN_INT_FENV_T_PTR, BT_FN_INT_CONST_FENV_T_PTR,
11318         BT_FN_INT_FEXCEPT_T_PTR_INT, BT_FN_INT_CONST_FEXCEPT_T_PTR_INT):
11319         New function types.
11320         * builtins.def (BUILT_IN_FECLEAREXCEPT, BUILT_IN_FEGETENV,
11321         BUILT_IN_FEGETEXCEPTFLAG, BUILT_IN_FEGETROUND,
11322         BUILT_IN_FEHOLDEXCEPT, BUILT_IN_FERAISEEXCEPT,
11323         BUILT_IN_FESETENV, BUILT_IN_FESETEXCEPTFLAG,
11324         BUILT_IN_FESETROUND, BUILT_IN_FETESTEXCEPT,
11325         BUILT_IN_FEUPDATEENV): New builtins.
11326         * tree-core.h (TI_FENV_T_PTR_TYPE, TI_CONST_FENV_T_PTR_TYPE,
11327         TI_FEXCEPT_T_PTR_TYPE, TI_CONST_FEXCEPT_T_PTR_TYPE): New entries.
11328         * tree.h (fenv_t_ptr_type_node, const_fenv_t_ptr_type_node,
11329         fexcept_t_ptr_type_node, const_fexcept_t_ptr_type_node): New
11330         macros.
11331         (builtin_structptr_types): Adjust size.
11332         * tree.c (builtin_structptr_types): Add four entries.
11334 2017-06-27  Jerome Lambourg  <lambourg@adacore.com>
11335             Olivier Hainque  <hainque@adacore.com>
11337         * config/vxworks.h (VXWORKS_LIB_SPEC): Incorporate ...
11338         (TLS_SYM): New local macro, forcing reference to __tls__ on
11339         link command lines for VxWorks 7 RTPs, triggering initialization
11340         of tlsLib.
11341         (VXWORKS_HAVE_TLS): New macro. State whether the target VxWorks
11342         OS features TLS support, true for RTPs on VxWorks 7.
11343         * config/vxworks.c (vxworks_override_options): Setup emutls
11344         accordingly.
11346 2017-06-27  Jakub Jelinek  <jakub@redhat.com>
11348         * predict.c (test_prediction_value_range): Use -1U instead of -1
11349         to avoid narrowing conversion warning.
11350         * dumpfile.c (dump_options): Wrap all value into dump_flags_t cast
11351         to avoid narrowing conversion warning.
11352         * opt-functions.awk (var_ref): Return (unsigned short) -1 instead of
11353         -1.
11354         * optc-gen.awk (END): Expect (unsigned short) -1 instead of -1.
11356 2017-06-27  Jerome Lambourg  <lambourg@adacore.com>
11358         * config/vxworks.h (VXWORKS_LIBS_RTP): Alternative definition for
11359         64bit configurations.
11360         (PTR_DIFF_TYPE): Alternative definition for TARGET_LP64.
11361         (SIZE_TYPE): Likewise.
11362         * config/vxworks.c (vxworks_emutls_var_fields): Use
11363         long_unsigned_type_node instead of unsigned_type_node as the offset
11364         field type, which is "pointer" mode in emutls.c.
11366 2017-06-27  Jakub Jelinek  <jakub@redhat.com>
11368         PR sanitizer/81209
11369         * ubsan.c (ubsan_encode_value): Initialize DECL_CONTEXT on var.
11371         PR middle-end/81207
11372         * gimple-fold.c (replace_call_with_call_and_fold): Handle
11373         gimple_vuse copying separately from gimple_vdef copying.
11375 2017-06-27  Prathamesh Kulkarni  <prathamesh.kulkarni@linaro.org>
11377         * value-prof.c (free_hist): Remove call to memset and the enclosing if
11378         condition.
11380 2017-06-26  Jerome Lambourg  <lambourg@adacore.com>
11381             Olivier Hainque  <hainque@adacore.com>
11383         * config.gcc (*-*-vxworks*): Add TARGET_VXWORKS7=1 to tm_defines
11384         for all vxworks7 targets.
11385         * config/vxworks.h (TARGET_VXWORKS7): If not defined, define to 0.
11386         (VXWORKS_ADDITIONAL_CPP_SPEC): Alternative definition for VXWORKS7.
11387         (VXWORKS_LIBS_RTP, VXWORKS_LIBS_RTP_DIR): New macros, allowing
11388         variations for VX6/VX7 and 32/64bits later on in ...
11389         (VXWORKS_LIB_SPEC): Leverage new macros.
11390         (VXWORKS_OS_CPP_BUILTINS): Define _VSB_CONFIG_FILE for VXWORKS7,
11391         as well as _ALLOW_KEYWORD_MACROS when "inline" is not a keyword.
11393 2017-06-26  Jerome Lambourg  <lambourg@adacore.com>
11395         * config/vxworks.h (VXWORKS_OS_CPP_BUILTINS): builtin_define
11396         _VX_TOOL_FAMILY and _VX_TOOL to gnu.
11398 2017-06-26  Carl Love  <cel@us.ibm.com>
11400         * config/rs6000/rs6000-c.c: Add support for built-in functions
11401         vector bool char vec_reve (vector bool char);
11402         vector signed char vec_reve (vector signed char);
11403         vector unsigned char vec_reve (vector unsigned char);
11404         vector bool int vec_reve (vector bool int);
11405         vector signed int vec_reve (vector signed int);
11406         vector unsigned int vec_reve (vector unsigned int);
11407         vector bool long long vec_reve (vector bool long long);
11408         vector signed long long vec_reve (vector signed long long);
11409         vector unsigned long long vec_reve (vector unsigned long long);
11410         vector bool short vec_reve (vector bool short);
11411         vector signed short vec_reve (vector signed short);
11412         vector double vec_reve (vector double);
11413         vector float vec_reve (vector float);
11414         * config/rs6000/rs6000-builtin.def (VREVE_V2DI, VREVE_V4SI,
11415         VREVE_V8HI, VREVE_V16QI, VREVE_V2DF, VREVE_V4SF, VREVE): New builtin.
11416         * config/rs6000/altivec.md (UNSPEC_VREVEV): New UNSPEC.
11417         (altivec_vreve): New pattern.
11418         * config/rs6000/altivec.h (vec_reve): New define.
11419         * doc/extend.texi (vec_rev): Update the built-in documentation file
11420         for the new built-in functions.
11422 2016-06-26  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
11424         PR tree-optimization/71815
11425         * gimple-ssa-strength-reduction.c (uses_consumed_by_stmt): New
11426         function.
11427         (find_basis_for_candidate): Call uses_consumed_by_stmt rather than
11428         has_single_use.
11429         (slsr_process_phi): Likewise.
11430         (replace_uncond_cands_and_profitable_phis): Don't replace a
11431         multiply candidate with a stride of 1 (copy or cast).
11432         (phi_incr_cost): Call uses_consumed_by_stmt rather than
11433         has_single_use.
11434         (lowest_cost_path): Likewise.
11435         (total_savings): Likewise.
11437 2017-06-26  Richard Biener  <rguenther@suse.de>
11439         PR target/81175
11440         * config/i386/i386.c (ix86_init_mmx_sse_builtins):
11441         Use def_builtin_pure for all gather builtins.
11443 2017-06-26  Richard Biener  <rguenther@suse.de>
11445         PR tree-optimization/81203
11446         * tree-tailcall.c (find_tail_calls): Do not move stmts into
11447         non-dominating BBs.
11449 2017-06-26  Marek Polacek  <polacek@redhat.com>
11451         PR c/80116
11452         * doc/invoke.texi: Document -Wmultistatement-macros.
11454 2017-06-26  Christophe Lyon  <christophe.lyon@linaro.org>
11456         * doc/sourcebuild.texi (ARM-specific attributes): Document new
11457         arm_neon_ok_no_float_abi effective target.
11459 2017-06-26  Richard Biener  <rguenther@suse.de>
11461         PR tree-optimization/80928
11462         * cfghooks.c (duplicate_block): Do not copy BB_DUPLICATED flag.
11463         (copy_bbs): Set BB_DUPLICATED flag early.
11464         (execute_on_growing_pred): Do not execute for BB_DUPLICATED
11465         marked blocks.
11466         (execute_on_shrinking_pred): Likewise.
11467         * tree-ssa.c (ssa_redirect_edge): Do not look for PHI args in
11468         BB_DUPLICATED blocks.
11469         * tree-ssa-phionlycoprop.c (eliminate_degenerate_phis_1): Properly
11470         iterate over all PHIs considering removal of *gsi.
11472 2017-06-23  Jim Wilson  <jim.wilson@linaro.org>
11474         * doc/invoke.texi (AArch64 Options, -mtune): Re-add falkor and
11475         qdf24xx.
11477 2017-06-23  Aaron Sawdey  <acsawdey@linux.vnet.ibm.com>
11479         * config/rs6000/rs6000-string.c: (expand_block_clear,
11480         do_load_for_compare, select_block_compare_mode,
11481         compute_current_alignment, expand_block_compare,
11482         expand_strncmp_align_check, expand_strn_compare,
11483         expand_block_move, rs6000_output_load_multiple)
11484         Move functions related to string/block move/compare
11485         to a separate file.
11486         * config/rs6000/rs6000.c: Move above functions to rs6000-string.c.
11487         * config/rs6000/rs6000-protos.h (rs6000_emit_dot_insn): Add prototype
11488         for this function which is now used in two files.
11489         * config/rs6000/t-rs6000: Add rule to compile rs6000-string.o.
11490         * config.gcc: Add rs6000-string.o to extra_objs for
11491         targets powerpc*-*-* and rs6000*-*-*.
11493 2017-06-23  Michael Meissner  <meissner@linux.vnet.ibm.com>
11495         PR target/80510
11496         * config/rs6000/rs6000.md (ALTIVEC_DFORM): Do not allow DImode in
11497         32-bit, since indexed is not valid for DImode.
11498         (mov<mode>_hardfloat32): Reorder ISA 2.07 load/stores before ISA
11499         3.0 d-form load/stores to be the same as mov<mode>_hardfloat64.
11500         (define_peephole2 for Altivec d-form load): Add 32-bit support.
11501         (define_peephole2 for Altivec d-form store): Likewise.
11503         PR ipa/81185
11504         * multiple_target.c (create_dispatcher_calls): Only create the
11505         dispatcher call if the function is the default clone of a
11506         versioned function.
11508 2017-06-23  Segher Boessenkool  <segher@kernel.crashing.org>
11510         PR middle-end/80902
11511         * builtins.c (expand_builtin_atomic_fetch_op): If emitting code after
11512         a call, force the call to not be a tail call.
11514 2017-06-23  Jeff Law  <law@redhat.com>
11516         * doc/contrib.texi: Add entry for Steven Pemberton's work on
11517         enquire.
11519 2017-06-23  Will Schmidt  <will_schmidt@vnet.ibm.com>
11521         * config/rs6000/rs6000.c: Add include of ssa-propagate.h for
11522         update_call_from_tree().  (rs6000_gimple_fold_builtin): Add
11523         handling for early expansion of vector shifts (sl,sr,sra,rl).
11524         (builtin_function_type): Add vector shift right instructions
11525         to the unsigned argument list.
11527 2017-06-23  Bernd Edlinger  <bernd.edlinger@hotmail.de>
11529         rtl-optimizatoin/79286
11530         * ira.c (update_equiv_regs): Revert to using may_trap_or_fault_p again.
11531         * rtlanal.c (rtx_addr_can_trap_p_1): SYMBOL_REF_FUNCTION_P can never
11532         trap.  PIC register plus a const unspec without offset can never trap.
11534 2017-06-23  Marc Glisse  <marc.glisse@inria.fr>
11536         * tree.h (builtin_structptr_type): New type.
11537         (builtin_structptr_types): Declare new array.
11538         * tree.c (builtin_structptr_types): New array.
11539         (free_lang_data, build_common_tree_nodes): Use it.
11541 2017-06-23  Jonathan Wakely  <jwakely@redhat.com>
11543         PR c++/81187
11544         * doc/invoke.texi (-Wnoexcept-type): Fix name of option, from
11545         -Wnoexcept.
11547 2017-06-22  Matt Turner  <mattst88@gmail.com>
11549         * config/i386/driver-i386.c (host_detect_local_cpu): Add Kaby
11550         Lake models to skylake case.  Assume skylake for unknown
11551         models with clflushopt.
11553 2017-06-22  Jeff Law  <law@redhat.com>
11555         * config/aarch64/aarch64.c (aarch64_emit_probe_stack_range): Handle
11556         frame sizes that do not satisfy aarch64_uimm12_shift.
11558 2017-06-22  Jan Hubicka <hubicka@ucw.cz>
11560         * profile-count.h (apply_probability,
11561         apply_scale, probability_in): Fix checks for zero.
11563 2017-06-22  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
11565         * incpath.c (add_sysroot_to_chain): Allow for $SYSROOT prefix.
11566         * doc/cppdiropts.texi (-I @var{dir}): Document it.
11568 2016-06-22  Richard Biener  <rguenther@suse.de>
11570         * tree-vect-loop.c (vect_model_reduction_cost): Handle
11571         COND_REDUCTION and INTEGER_INDUC_COND_REDUCTION without
11572         REDUC_MAX_EXPR support.
11573         (vectorizable_reduction): Likewise.
11574         (vect_create_epilog_for_reduction): Likewise.
11576 2017-06-22  James Greenhalgh  <james.greenhalgh@arm.com>
11578         * match.pd (A / (1 << B) -> A >> B): New.
11579         * generic-match-head.c: Include optabs-tree.h.
11580         * gimple-match-head.c: Likewise.
11581         * optabs-tree.h (target_supports_op_p): New.
11582         * optabs-tree.c (target_supports_op_p): New.
11584 2017-06-22  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
11586         * configure.ac (gcc_cv_ld_static_dynamic): Also check stderr for
11587         $gcc_cv_ld --help output.
11588         (gcc_cv_ld_demangle): Likewise.
11589         (gcc_cv_ld_eh_frame_hdr): Likewise.
11590         (gcc_cv_ld_pie): Likewise.
11591         (gcc_cv_ld_as_needed): Likewise.  Prefer native forms unless $gnu_ld.
11592         (gcc_cv_ld_buildid): Likewise.
11593         (gcc_cv_ld_sysroot): Likewise.
11594         (ld_bndplt_support): Likewise.
11595         (ld_pushpopstate_support): Likewise.
11596         * configure: Regenerate.
11597         * config/sol2.h [!USE_GLD] (SYSROOT_SPEC): Define.
11599 2017-06-21  Jakub Jelinek  <jakub@redhat.com>
11601         PR target/81151
11602         * config/i386/sse.md (round<mode>2): Renumber match_dup and
11603         operands indexes to avoid gap between operands and match_dups.
11605 2017-06-21  Andrew Pinski  <apinski@cavium.com>
11607         * config/aarch64/aarch64-cost-tables.h (thunderx_extra_costs):
11608         Increment Arith_shift and Arith_shift_reg by 1.
11609         * config/aarch64/aarch64-tuning-flags.def (cheap_shift_extend):
11610         New tuning flag.
11611         * config/aarch64/aarch64.c (thunderx_tunings): Enable
11612         AARCH64_EXTRA_TUNE_CHEAP_SHIFT_EXTEND.
11613         (aarch64_strip_extend): Add new argument and test for it.
11614         (aarch64_cheap_mult_shift_p): New function.
11615         (aarch64_rtx_mult_cost): Call aarch64_cheap_mult_shift_p and don't
11616         add a cost if it is true.
11617         Update calls to aarch64_strip_extend.
11618         (aarch64_rtx_costs): Update calls to aarch64_strip_extend.
11620 2017-06-21  Andrew Pinski  <apinski@cavium.com>
11622         * config/aarch64/aarch64-cores.def (thunderxt88p1): Use thunderxt88
11623         tunings.
11624         (thunderxt88): Likewise.
11625         * config/aarch64/aarch64.c (thunderxt88_prefetch_tune): New variable.
11626         (thunderx_prefetch_tune): New variable.
11627         (thunderx2t99_prefetch_tune): Update for the correct values.
11628         (thunderxt88_tunings): New variable.
11629         (thunderx_tunings): Use thunderx_prefetch_tune instead of
11630         generic_prefetch_tune.
11631         (thunderx2t99_tunings): Use AUTOPREFETCHER_WEAK.
11633 2017-06-21  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
11635         * config/aarch64/atomics.md (aarch64_compare_and_swap<mode>_lse,
11636         SHORT): Relax operand 3 to aarch64_reg_or_zero and constraint to Z.
11637         (aarch64_compare_and_swap<mode>_lse, GPI): Likewise.
11638         (aarch64_atomic_cas<mode>, SHORT): Likewise for operand 2.
11639         (aarch64_atomic_cas<mode>, GPI): Likewise.
11641 2017-06-21  Martin Liska  <mliska@suse.cz>
11643         * gimplify.c (gimplify_label_expr): Insert GIMPLE_PREDICT
11644         statements on cold and hot labels.
11645         * predict.c (tree_estimate_probability_bb): Remove the
11646         prediction from this place.
11648 2017-06-21  Martin Liska  <mliska@suse.cz>
11650         PR tree-optimization/79489
11651         * gimplify.c (maybe_add_early_return_predict_stmt): New
11652         function.
11653         (gimplify_return_expr): Call the function.
11654         * predict.c (tree_estimate_probability_bb): Remove handling
11655         of early return.
11656         * predict.def: Update comment about early return predictor.
11657         * gimple-predict.h (is_gimple_predict): New function.
11658         * predict.def: Change default value of early return to 66.
11659         * tree-tailcall.c (find_tail_calls): Skip GIMPLE_PREDICT
11660         statements.
11661         * passes.def: Put pass_strip_predict_hints to the beginning of
11662         IPA passes.
11664 2017-06-21  Pierre-Marie de Rodat  <derodat@adacore.com>
11666         * dwarf2out.c (gen_decl_die): Remove the guard to skip file-scope
11667         FUNCTION_DECL declarations.
11668         (dwarf2out_early_global_decl): Remove the guard to skip FUNCTION_DECL
11669         declarations.
11670         (dwaf2out_decl): Likewise.
11671         * godump.c (go_early_global_decl): Skip call to the real debug hook
11672         for FUNCTION_DECL declarations.
11673         * passes.c (rest_of_decl_compilation): Skip call to the
11674         early_global_decl debug hook for FUNCTION_DECL declarations, unless
11675         -fdump-go-spec is passed.
11677 2017-06-21  Marc Glisse  <marc.glisse@inria.fr>
11679         * config/i386/i386.c (struct builtin_isa): New field pure_p.
11680         Reorder for compactness.
11681         (def_builtin, def_builtin2, ix86_add_new_builtins): Handle pure_p.
11682         (def_builtin_pure, def_builtin_pure2): New functions.
11683         (ix86_init_mmx_sse_builtins) [__builtin_ia32_stmxcsr]: Mark as pure.
11685 2017-06-21  Marc Glisse  <marc.glisse@inria.fr>
11687         * match.pd (nop_convert): New predicate.
11688         ((A +- CST1) +- CST2): Allow some NOP conversions.
11690 2017-06-21  Jakub Jelinek  <jakub@redhat.com>
11692         PR c++/81130
11693         * gimplify.c (omp_add_variable): Don't force GOVD_SEEN for types
11694         with ctors/dtors if GOVD_SHARED is set.
11696 2017-06-21  Wilco Dijkstra  <wdijkstr@arm.com>
11698         * config/aarch64/aarch64.md (movti_aarch64):
11699         Emit mov rather than orr.
11700         (movtf_aarch64): Likewise.
11701         * config/aarch64/aarch64-simd.md (aarch64_simd_mov):
11702         Emit mov rather than orr.
11704 2017-06-21  Wilco Dijkstra  <wdijkstr@arm.com>
11706         * config/aarch64/aarch64-simd.md (aarch64_simd_dup):
11707         Swap alternatives, make integer dup more expensive.
11709 2017-06-21  Wilco Dijkstra  <wdijkstr@arm.com>
11711         * config/aarch64/aarch64.c (aarch64_legitimate_constant_p):
11712         Return true for non-tls symbols.
11714 2017-06-21  James Greenhalgh  <james.greenhalgh@arm.com>
11716         * config/aarch64/aarch64-cores.def (cortex-a55): New.
11717         (cortex-a75): Likewise.
11718         (cortex-a75.cortex-a55): Likewise.
11719         * config/aarch64/aarch64-tune.md: Regenerate.
11720         * doc/invoke.texi (-mtune): Document new values for -mtune.
11722 2017-06-21  Tom de Vries  <tom@codesourcery.com>
11724         * doc/sourcebuild.texi (Add Options, Features for dg-add-options): Add
11725         stack_size feature.
11726         (Effective-Target Keywords, Other attributes): Suggest using
11727         dg-add-options stack_size feature to get stack limit in stack_size
11728         effective target documentation.
11730 2017-06-21  Julian Brown  <julian@codesourcery.com>
11731             Naveen H.S  <Naveen.Hurugalawadi@cavium.com>
11733         * config/aarch64/aarch64-simd.md (aarch64_crypto_pmulldi)
11734         (aarch64_crypto_pmullv2di): Change type attribute to crypto_pmull.
11735         * config/aarch64/thunderx2t99.md (thunderx2t99_pmull): New
11736         reservation.
11737         * config/arm/cortex-a53.md (cortex_a53_advsimd_type): Add crypto_pmull to
11738         attribute type list for neon_multiply.
11739         * config/arm/cortex-a57.md (cortex_a57_neon_type): Add crypto_pmull to
11740         attribute type list for neon_multiply.
11741         * config/arm/crypto.md (crypto_vmullp64): Change type to crypto_pmull.
11742         * config/arm/exynos-m1.md (exynos_m1_neon_type): Add crypto_pmull to
11743         attribute type list for neon_multiply.
11744         * config/arm/types.md (crypto_pmull): Add.
11745         * config/arm/xgene1.md (xgene1_neon_pmull): Add crypto_pmull to
11746         attribute type list.
11748 2017-06-20  Andreas Tobler  <andreast@gcc.gnu.org>
11750         * config.gcc (armv6*-*-freebsd*): Change the target_cpu_cname to
11751         arm1176jzf-s.
11753 2017-06-20  Jakub Jelinek  <jakub@redhat.com>
11755         * ira-costs.c (find_costs_and_classes): Initialize cost_classes later
11756         to make sure not to dereference a NULL cost_classes_ptr pointer.
11758 2017-06-20  Carl Love  <cel@us.ibm.com>
11760         * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Add
11761         ALTIVEC_BUILTIN_VMULESW, ALTIVEC_BUILTIN_VMULEUW,
11762         ALTIVEC_BUILTIN_VMULOSW, ALTIVEC_BUILTIN_VMULOUW entries.
11763         * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin,
11764         builtin_function_type): Add ALTIVEC_BUILTIN_* case statements.
11765         * config/rs6000/altivec.md (MVULEUW, VMULESW, VMULOUW,
11766         VMULOSW): New enum "unspec" values.
11767         (vec_widen_umult_even_v4si, vec_widen_smult_even_v4si,
11768         vec_widen_umult_odd_v4si, vec_widen_smult_odd_v4si,
11769         altivec_vmuleuw, altivec_vmulesw, altivec_vmulouw,
11770         altivec_vmulosw): New patterns.
11771         * config/rs6000/rs6000-builtin.def (VMLEUW, VMULESW, VMULOUW,
11772         VMULOSW): Add definitions.
11774 2017-06-20  Julia Koval  <julia.koval@intel.com>
11776         * config/i386/i386.c: Fix rounding expand for new pattern.
11777         * config/i386/subst.md: Fix pattern (parallel -> unspec).
11779 2017-06-20  James Greenhalgh  <james.greenhalgh@arm.com>
11781         * config/aarch64/aarch64-option-extensions.def (rcpc): New.
11782         * config/aarch64/aarch64.h (AARCH64_FL_RCPC): New.
11784 2017-06-20  James Greenhalgh  <james.greenhalgh@arm.com>
11786         * config/aarch64/aarch64-option-extensions.def (fp16): Fix expected
11787         feature string.
11789 2017-06-20  James Greenhalgh  <james.greenhalgh@arm.com>
11791         * config/aarch64/aarch64-cores.def: Rearrange to sort by
11792         architecture, then by implementer ID.
11793         * config/aarch64/aarch64-tune.md: Regenerate.
11795 2017-06-20  Richard Biener  <rguenther@suse.de>
11797         PR middle-end/81097
11798         * fold-const.c (split_tree): Fold to type before negating.
11800 2017-06-20  David Malcolm  <dmalcolm@redhat.com>
11802         * diagnostic-show-locus.c
11803         (selftest::test_fixit_deletion_affecting_newline): New function.
11804         (selftest::diagnostic_show_locus_c_tests): Call it.
11806 2017-06-20  Andreas Schwab  <schwab@suse.de>
11808         PR target/80970
11809         * config/m68k/m68k.md (bsetdreg, bchgdreg, bclrdreg): Use "=d"
11810         instead of "+d".
11812 2017-06-20  Prakhar Bahuguna  <prakhar.bahuguna@arm.com>
11814         * config/arm/arm-c.c (arm_cpu_builtins): New block to define
11815         __ARM_FEATURE_COPROC according to support.
11817 2017-06-20  Jakub Jelinek  <jakub@redhat.com>
11819         * tree-chkp.c (chkp_get_hard_register_var_fake_base_address):
11820         Rewritten to avoid overflow for > 32-bit pointers.
11822         PR sanitizer/81125
11823         * ubsan.h (ubsan_encode_value): Workaround buggy clang++ parser
11824         by removing enum keyword.
11825         (ubsan_type_descriptor): Likewise.  Formatting fix.
11827         PR target/81121
11828         * config/i386/i386.md (TARGET_USE_VECTOR_CONVERTS float si->{sf,df}
11829         splitter): Require TARGET_SSE2 in the condition.
11831 2017-06-20  Michael Meissner  <meissner@linux.vnet.ibm.com>
11833         PR target/79799
11834         * config/rs6000/rs6000.c (rs6000_expand_vector_init): Add support
11835         for doing vector set of SFmode on ISA 3.0.
11836         * config/rs6000/vsx.md (vsx_set_v4sf_p9): Likewise.
11837         (vsx_set_v4sf_p9_zero): Special case setting 0.0f to a V4SF
11838         element.
11839         (vsx_insert_extract_v4sf_p9): Add an optimization for inserting a
11840         SFmode value into a V4SF variable that was extracted from another
11841         V4SF variable without converting the element to double precision
11842         and back to single precision vector format.
11843         (vsx_insert_extract_v4sf_p9_2): Likewise.
11845 2017-06-19  Jakub Jelinek  <jakub@redhat.com>
11847         * tree-ssa-structalias.c (get_constraint_for_ptr_offset): Multiply
11848         in UWHI to avoid undefined overflow.
11850         PR sanitizer/81125
11851         * ubsan.h (enum ubsan_encode_value_phase): New.
11852         (ubsan_encode_value): Change second argument to
11853         enum ubsan_encode_value_phase with default value of
11854         UBSAN_ENCODE_VALUE_GENERIC.
11855         * ubsan.c (ubsan_encode_value): Change second argument to
11856         enum ubsan_encode_value_phase PHASE from bool IN_EXPAND_P,
11857         adjust uses, for UBSAN_ENCODE_VALUE_GENERIC use just
11858         create_tmp_var_raw instead of create_tmp_var and use a
11859         TARGET_EXPR.
11860         (ubsan_expand_bounds_ifn, ubsan_build_overflow_builtin,
11861         instrument_bool_enum_load, ubsan_instrument_float_cast): Adjust
11862         ubsan_encode_value callers.
11864         PR sanitizer/81111
11865         * ubsan.c (ubsan_encode_value): If current_function_decl is NULL,
11866         use create_tmp_var_raw instead of create_tmp_var, mark it addressable
11867         just by setting TREE_ADDRESSABLE on the result and use a TARGET_EXPR.
11869 2017-06-19  Richard Biener  <rguenther@suse.de>
11871         PR middle-end/81118
11872         * tree-cfgcleanup.c (cleanup_tree_cfg_noloop): Clear niter
11873         estimates if we changed anything.
11875 2017-06-19  Richard Biener  <rguenther@suse.de>
11877         PR tree-optimization/80887
11878         * tree-ssa-sccvn.c (mprts_hook_cnt): New global.
11879         (vn_lookup_simplify_result): Allow only mprts_hook_cnt succesful
11880         simplified lookups, then reset mprts_hook.
11881         (vn_nary_build_or_lookup_1): Set mprts_hook_cnt to 9 before
11882         simplifying.
11883         (try_to_simplify): Likewise.
11885 2017-06-19  Martin Liska  <mliska@suse.cz>
11887         PR sanitizer/80879
11888         * gimplify.c (gimplify_switch_expr):
11889         Initialize live_switch_vars for SWITCH_BODY == STATEMENT_LIST.
11891 2017-06-19  Martin Liska  <mliska@suse.cz>
11893         * doc/install.texi: Document that PGO runs in 4 stages.
11895 2017-06-19  Martin Liska  <mliska@suse.cz>
11897         PR ipa/80732
11898         * attribs.c (make_dispatcher_decl): Do not append '.ifunc'
11899         to dispatcher function name.
11900         * multiple_target.c (replace_function_decl): New function.
11901         (create_dispatcher_calls): Redirect both edges and references.
11903 2017-06-19  Jan Hubicka <hubicka@ucw.cz>
11905         * profile-count.c (profile_count::dump): Dump quality.
11906         (profile_count::differs_from_p): Update for unsigned val.
11907         * profile-count.h (profile_count_quality): New enum.
11908         (profile_count): Turn m_val to 62bit unsigned, add quality tracking.
11910 2017-06-19  Richard Biener  <rguenther@suse.de>
11912         * tree-ssa-loop-niter.h (estimate_numbers_of_iterations): Take
11913         struct function as arg.
11914         (estimate_numbers_of_iterations): Export overload with loop arg.
11915         (free_numbers_of_iterations_estimates_loop): Use an overload of
11916         free_numbers_of_iterations_estimates instead.
11917         * tree-cfg.c (remove_bb): Adjust.
11918         * tree-cfgcleanup.c (remove_forwarder_block_with_phi): Likewise.
11919         * tree-parloops.c (gen_parallel_loop): Likewise.
11920         * tree-ssa-loop-ivcanon.c (canonicalize_induction_variables):
11921         Likewise.
11922         (tree_unroll_loops_completely): Likewise.
11923         * tree-ssa-loop-niter.c (estimate_numbers_of_iterations_loop):
11924         Use an overload instead and export.
11925         (estimated_loop_iterations): Adjust.
11926         (max_loop_iterations): Likewise.
11927         (likely_max_loop_iterations): Likewise.
11928         (estimate_numbers_of_iterations): Take struct function as arg
11929         and adjust.
11930         (loop_exits_before_overflow): Adjust.
11931         (free_numbers_of_iterations_estimates_loop): Use an overload.
11932         * tree-vect-loop.c (vect_analyze_loop_form): Adjust.
11933         * tree-vectorizer.c (vect_free_loop_info_assumptions): Likewise.
11935 2017-06-19  Richard Biener  <rguenther@suse.de>
11937         PR ipa/81112
11938         * ipa-prop.c (find_constructor_constant_at_offset): Handle
11939         RANGE_EXPR conservatively.
11941 2017-06-16  Carl Love  <cel@us.ibm.com>
11943         * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Add
11944         definitions for vec_float, vec_float2, vec_floato,
11945         vec_floate built-ins.
11946         * config/rs6000/vsx.md (define_c_enum "unspec"): Add RTL code
11947         for instructions vsx_xvcvsxws vsx_xvcvuxwsp, float2, floato and
11948         floate.
11949         * config/rs6000/rs6000-builtin.def (FLOAT2_V2DI, FLOATE_V2DF,
11950         FLOATE_2DI, FLOATO_V2DF, FLOATEE_V2DI, XVCVSXWSP_V4SF,
11951         UNS_FLOATO_V2DI, UNS_FLOATE_V2DI): Add definitions.
11952         * config/altivec.md (define_insn "p8_vmrgew_<mode>",
11953         define_mode_attr VF_sxddp): Add V4SF type to p8_vmrgew.
11954         * config/rs6000/altivec.h (vec_float, vec_float2, vec_floate,
11955         vec_floato): Add builtin defines.
11956         * doc/extend.texi (vec_float, vec_float2, vec_floate, vec_floato):
11957         Update the built-in documentation file for the new built-in
11958         functions.
11960 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
11962         * config/arm/arm.opt (marm): Mark as the negative of of -mthumb.
11963         (mthumb): Mark as the negative of -marm.
11965 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
11967         * doc/invoke.texi (ARM Options, -mcpu): Document supported
11968         extension options.
11969         (ARM Options, -mtune): Document that this accepts the same
11970         extension options as -mcpu.
11971         (ARM Options, -mfpu): Document addition of -mfpu=auto.
11973 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
11975         * doc/invoke.texi (ARM Options, -march=): Document new syntax and
11976         permitted extensions.
11978 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
11980         * config/arm/arm-cpus.in (armv7): Add extension +nofp.
11981         (armv7-r): Add aliases vfpv3xd and vfpv3-d16.
11982         (armv8-m.main): Add option +nodsp.
11983         * config/arm/arm-cpu-cdata.h: Regenerated.
11985 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
11987         * config/arm/t-fuchsia: New file.
11988         * config.gcc (arm*-*-fuchsia*): Use it.
11990 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
11992         * config/arm/t-symbian: Rewrite for new option infrastructure.
11994 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
11996         * config/arm/t-phoenix (MULTILIB_REUSE): Clear variable.
11997         (MULTILIB_REQUIRED): Likewise.
11999 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
12001         * config/arm/t-linux-eabi (MULTILIB_EXCEPTIONS): Set to empty.
12002         (MULTILIB_RESUE): Likewise.
12003         (MULTILIB_MATCHES): Likewise.
12004         (MULTLIB_REQUIRED): Likewise.
12006 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
12008         * config/arm/t-rtems: Rewrite for new option framework.
12010 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
12012         * config/arm/t-aprofile (v7_a_nosimd_variants, v7_a_simd_variants)
12013         (v7ve_nosimd_variatns, v7ve_vfpv3_simd_variants)
12014         (v7ve_vfpv4_simd_variants, v8_a_nosimd_variants, v8_a_simd_variants)
12015         (v8_1_a_simd_variants, v8_2_a_simd_variants): Move to ...
12016         * config/arm/t-multilib: ... here.
12017         (MULTILIB_OPTIONS): Add armv7 and armv7+fp architectures.
12018         (MULTILIB_MATCHES): Use armv7 libraries for armv7-r.  Also use for
12019         armv7-a and armv8*-a when A-profile libraries have not been built.
12020         * config/arm/t-rmprofile: Rewrite.
12022 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
12024         * genmultilib (multilib_reuse): Allow an explicit period to be escaped
12025         with a backslash.  Remove the backslash after substituting unescaped
12026         periods.
12027         * doc/fragments.texi (MULTILIB_REUSE): Document it.
12029 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
12031         * config.gcc: (arm*-*-*): When building a-profile libraries, force
12032         the driver to pass through the default setting of -mfloat-abi.
12033         * common/config/arm/arm-common.c (arm_target_thumb_only): Return -marm
12034         rather than NULL.
12035         * config/arm/t-multilib (MULTILIB_REUSE): Initialize to empty.
12036         (all_feat_combs): New rule.
12037         (MULTILIB_OPTIONS): Use explicit ARM and Thumb directories.  Rework
12038         default libraries.
12039         * config/arm/t-aprofile: Rewrite.
12041 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
12043         * config/arm/arm.h (FPUTYPE_AUTO): Define.
12044         * config/arm/arm.c (arm_option_override): Use FPUTYPE_AUTO if the
12045         fpu is not specified by the user/command-line.
12046         * config/arm/bpabi.h (FPUTYPE_DEFAULT): Delete.
12047         * config/arm/netbsd-elf.h (FPUTYPE_DEFAULT): Delete.
12048         * config/arm/linux-elf.h (FPUTYPE_DEFAULT): Delete.
12049         * config/arm/vxworks.h (FPUTYPE_DEFAULT): Delete.
12050         * common/config/arm/arm-common.c (arm_canon_arch_option): Use
12051         FPUTYPE_AUTO insted of FPUTYPE_DEFAULT.
12053 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
12055         * config/arm/elf.h (MULTILIB_DEFAULTS): Delete.
12056         * config/arm/t-arm-elf: Rewritten.
12058 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
12060         * config/arm/arm.h (TARGET_HARD_FLOAT): Also check that we
12061         have some floating-point instructions.
12062         (TARGET_SOFT_FLOAT): Define as inverse of TARGET_HARD_FLOAT.
12063         (TARGET_MAYBE_HARD_FLOAT): New macro.
12064         * config/arm/arm-builtins.c (arm_init_builtins): Use
12065         TARGET_MAYBE_HARD_FLOAT.
12066         * config/arm/arm.c (arm_option_override): Use TARGET_HARD_FLOAT_ABI.
12068 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
12070         * common/config/arm/arm-common.c: Define INCLUDE_LIST.
12071         (configargs.h): Include it.
12072         (arm_print_hint_for_fpu_option): New function.
12073         (arm_parse_fpu_option): New function.
12074         (candidate_extension): New class.
12075         (arm_canon_for_multilib): New function.
12076         * config/arm/arm.h (CANON_ARCH_SPEC_FUNCTION): New macro.
12077         (EXTRA_SPEC_FUNCTIONS): Add CANON_ARCH_SPEC_FUNCTION.
12078         (ARCH_CANONICAL_SPECS): New macro.
12079         (DRIVER_SELF_SPECS): Add ARCH_CANONICAL_SPECS.
12081 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
12083         * config.gcc (arm*-*-*): Ensure both target_cpu_cname and with_cpu
12084         are set after handling multilib fragments.  Set target_cpu_default2
12085         from with_cpu.
12087 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
12089         * config.gcc (arm*-*-fucshia*): Set target_cpu_cname to the real
12090         cpu name.
12091         (arm*-*-*): Set target_cpu_default2 to a quoted string.
12092         * config/arm/parsecpu.awk (check_cpu): Validate any extension
12093         options.
12094         (check_arch): Likewise.
12095         * config/arm/arm.c (arm_configure_build_target): Handle
12096         TARGET_CPU_DEFAULT being a string constant.  Scan any feature
12097         options in the default.
12099 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
12101         * config/arm/arm-protos.h (cpu_arch_extension): Add field to record
12102         when an option is an alias of another.
12103         * config/arm/parsecpu.awk (optalias): New parser token.
12104         (gen_comm_data): Mark non-alias options as such.  Emit entries
12105         for extension aliases.
12106         * config/arm/arm-cpus.in (armv5e): Make vfpv2 an alias.
12107         (armv5te, armv5tej, armv6, armv6j, armv6k, armv6z): Likewise.
12108         (armv6kz, armv6zk, armv6t2): Likewise.
12109         (armv7): Make vfpv3-d16 an alias.
12110         (armv7-a): Make vfpv3-d16, neon and neon-vfpv3 aliases.  Sort in
12111         canonical order.
12112         (armv7ve): Make vfpv4-d16, neon-vfpv3 and neon-vfpv4 aliases.
12113         Sort in canonical order.
12114         (armv8-a): Sort in canonical order.
12115         (armv8.1-a, armv8.2-a):  Likewise.
12116         (generic-armv7-a): Make neon and neon-vfpv3 aliases.  Sort in
12117         canonical order.
12118         (cortex-a9): Sort in canonical order.
12119         * config/arm/arm.c (selftests.h): Include it.
12120         (arm_test_cpu_arch_data): New function.
12121         (arm_run_self_tests): New function.
12122         (TARGET_RUN_TARGET_SELFTESTS): Redefine.
12123         (targetm): Move declaration to the end of the file.
12124         * arm-cpu-cdata.h: Regenerated.
12126 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
12128         * config/arm/arm.h (TARGET_MODE_SPECS): Add additional parameter to
12129         call to target_mode_check describing the type of option passed.
12130         * common/config/arm/arm-common.c (arm_arch_core_flag): Delete.
12131         (arm_target_thumb_only): Use arm_parse_arch_option_name or
12132         arm_parse_cpu_option_name to match parameters against list of
12133         available targets.
12134         * config/arm/parsecpu.awk (gen_comm_data): Don't generate
12135         arm_arch_core_flags data structure.
12136         * config/arm/arm-cpu_cdata.h: Regenerated.
12138 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
12140         * common/config/arm/arm-common.c (arm_initialize_isa): Moved here from
12141         config/arm/arm.c.
12142         (arm_print_hint_for_cpu_option): Likewise.
12143         (arm_print_hint_for_arch_option): Likewise.
12144         (arm_parse_cpu_option_name): Likewise.
12145         (arm_parse_arch_option_name): Likewise.
12146         * config/arm/arm.c (arm_identify_fpu_from_isa): Use the computed number
12147         of entries in the all_fpus list.
12148         * config/arm/arm-protos.h (all_architectures, all_cores): Declare.
12149         (arm_parse_cpu_option_name): Declare.
12150         (arm_parse_arch_option_name): Declare.
12151         (arm_parse_option_features): Declare.
12152         (arm_intialize_isa): Declare.
12153         * config/arm/parsecpu.awk (gen_data): Move CPU and architecture
12154         data tables to ...
12155         (gen_comm_data): ... here.  Make definitions non-static.
12156         * config/arm/arm-cpu-data.h: Regenerated.
12157         * config/arm/arm-cpu-cdata.h: Regenerated.
12159 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
12161         * config/arm/arm-protos.h (arm_build_target): Remove arch_core.
12162         (cpu_arch_extension): New structure.
12163         (cpu_arch_option, arch_option, cpu_option): New structures.
12164         * config/arm/parsecpu.awk (gen_headers): Build an enumeration of
12165         architecture types.
12166         (gen_data): Generate new format data tables.
12167         * config/arm/arm.c (cpu_tune): New structure.
12168         (cpu_option, processors): Delete.
12169         (arm_print_hint_for_core_or_arch): Delete.  Replace with ...
12170         (arm_print_hint_for_cpu_option): ... this and ...
12171         (arm_print_hint_for_arch_option): ... this.
12172         (arm_parse_arch_cpu_name): Delete.  Replace with ...
12173         (arm_parse_cpu_option_name): ... this and ...
12174         (arm_parse_arch_option_name): ... this.
12175         (arm_unrecognized_feature): Change type of target parameter to
12176         cpu_arch_option.
12177         (arm_parse_arch_cpu_features): Delete.  Replace with ...
12178         (arm_parse_option_features): ... this.
12179         (arm_configure_build_target): Rework to use new configuration data
12180         tables.
12181         (arm_print_tune_info): Rework for new configuration data tables.
12182         * config/arm/arm-cpu-data.h: Regenerated.
12183         * config/arm/arm-cpu.h: Regenerated.
12185 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
12187         * Makefile.in (OBJS): Move sbitmap.o from here ...
12188         (OBJS-libcommon): ... to here.
12190 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
12192         * config/arm/arm-isa.h (ISA_ALL_FPU_INTERNAL): Renamed from ISA_ALL_FPU.
12193         (ISA_ALL_CRYPTO): New macro.
12194         (ISA_ALL_SIMD): New macro
12195         (ISA_ALL_FP): New macro.
12196         * config/arm/arm.c (fpu_bitlist): Update initializer.
12197         * config/arm/arm-cpus.in: Use new ISA_ALL macros to disable crypto,
12198         simd or fp.
12199         (arm9e): Add fpu.  Add option for nofp
12200         (arm946e-s, arm966e-s, arm968e-s, arm10e, arm1020e, arm1022e): Likewise.
12201         (arm926ej-s, arm1026ej-s): Likewise.
12202         (generic-armv7-a): Add fpu.  Add options for simd, vfpv3, vfpv3-d16,
12203         vfpv3-fp16, vfpv3-d16-fp16, vfpv4, vfpv4-d16, neon, neon-vfp3,
12204         neon-fp16, neon-vfpv4, nofp and nosimd.
12205         (cortex-a5, cortex-a7): Add fpu.  Add options for nosimd and nofp.
12206         (cortex-a8): Add fpu.  Add option for nofp.
12207         (cortex-a9): Add fpu.  Add options for nosimd and nofp.
12208         (cortex-a12, cortex-a15, cortex-a17): Add fpu.  Add option for nofp.
12209         (cortex-r4f): Add fpu.
12210         (cortex-r5): Add fpu.  Add options for nofp.dp and nofp.
12211         (cortex-r7): Use idiv option from architecture.  Add fpu.  Add option
12212         for nofp.
12213         (cortex-r8): Likewise.
12214         (cortex-m4): Add fpu.  Add option for nofp.
12215         (cortex-a15.cortex-a7): Add fpu.  Add option for nofp.
12216         (cortex-a17.cortex-a7): Likewise.
12217         (cortex-a32): Add fpu.  Add options for crypto and nofp.
12218         (cortex-a35, cortex-a53): Likewise.
12219         (cortex-a57): Add fpu.  Add option for crypto.
12220         (cortex-a72, cortex-a73): Likewise.
12221         (exynos-m1): Likewise.
12222         (cortex-a57.cortex-a53, cortex-a72.cortex-a53): Likewise.
12223         (cortex-a73.cortex-a35, cortex-a73.cortex-a53): Likewise.
12224         (cortex-m33): Add fpu.  Add option for nofp.
12225         * config/arm/arm-cpu-cdata.h: Regenerated
12226         * config/arm/arm-cpu-data.h: Regenerated.
12228 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
12230         * arm-cpus.in (armv5e): Add options fp, vfpv2 and nofp.
12231         (armv5te, armv5tej): Likewise.
12232         (armv6, armv6j, armv6k, armv6z, armv6kz, armv6zk, armv6t2): Likewise.
12233         (armv7): Add options fp and vfpv3-d16.
12234         (armv7-a): Add options fp, simd, vfpv3, vfpv3-d16, vfpv3-d16-fp16,
12235         vfpv3-fp16, vfpv4, vfpv4-d16, neon, neon-vfpv3, neon-fp16, neon-vfpv4,
12236         nofp and nosimd.
12237         (armv7ve): Likewise.
12238         (armv7-r): Add options fp, fp.sp, idiv, nofp and noidiv.
12239         (armv7e-m): Add options fp, fpv5, fp.dp and nofp.
12240         (armv8-a): Add nocrypto option.
12241         (armv8.1-a, armv8.2-a): Likewise.
12242         (armv8-m.main): add options fp, fp.dp and nofp.
12244 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
12246         * config/arm/arm-cpus.in (armv8-a): Add options crc, simd crypto and
12247         nofp.
12248         (armv8-a+crc): Delete.
12249         (armv8.1-a): Add options simd, crypto and nofp.
12250         (armv8.2-a): Add options fp16, simd, crypto and nofp.
12251         (armv8.2-a+fp16): Delete.
12252         (armv8-m.main): Add option dsp.
12253         (armv8-m.main+dsp): Delete.
12254         (cortex-a8): Add fpu.  Add nofp option.
12255         (cortex-a9): Add fpu.  Add nofp and nosimd options.
12256         * config/arm/parsecpu.awk (gen_data): Generate option tables and
12257         link to main cpu and architecture data structures.
12258         (gen_comm_data): Only put isa attributes from the main architecture
12259         in common tables.
12260         (option): New statement for architecture and CPU entries.
12261         * arm.c (struct cpu_option): New structure.
12262         (struct processors): Add entry for options.
12263         (arm_unrecognized_feature): New function.
12264         (arm_parse_arch_cpu_name): Ignore any characters after the first
12265         '+' character.
12266         (arm_parse_arch_cpu_feature): New function.
12267         (arm_configure_build_target): Separate out any CPU and architecture
12268         features and parse separately.  Don't error out if -mfpu=auto is
12269         used with only an architecture string.
12270         (arm_print_asm_arch_directives): New function.
12271         (arm_file_start): Call it.
12272         * config/arm/arm-cpu-cdata.h: Regenerated.
12273         * config/arm/arm-cpu-data.h: Likewise.
12274         * config/arm/arm-tables.opt: Likewise.
12276 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
12278         * config/arm/elf.h (ASM_SPEC): Only pass -mfpu through to the
12279         assembler when it is not -mfpu=auto.
12281 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
12283         * config/arm/arm.h (BIG_LITTLE_SPEC): Delete macro.
12284         (ASM_REWRITE_SPEC_FUNCTIONS): New macro.
12285         (BIG_LITTLE_CPU_SPEC_FUNCTIONS): Delete macro.
12286         (ASM_CPU_SPEC): Rewrite.
12287         (MCPU_MTUNE_NATIVE_FUNCTIONS): New macro.
12288         (EXTRA_SPEC_FUNCTIONS): Move outside of ifdef.  Use
12289         MCPU_MTUNE_NATIVE_FUNCTIONS and ASM_REWRITE_SPEC_FUNCTIONS.  Remove
12290         reference to BIG_LITTLE_CPU_SPEC_FUNCTIONS.
12291         * common/config/arm/arm-common.c (arm_rewrite_selected_cpu): Ensure
12292         copied string is NUL-terminated.  Also strip any characters prefixed
12293         by '+'.
12294         (arm_rewrite_selected_arch): New function.
12295         (arm_rewrite_march): New function.
12297 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
12299         * config/arm/arm.opt (x_arm_arch_string): New TargetSave option.
12300         (x_arm_cpu_string, x_arm_tune_string): Likewise.
12301         (march, mcpu, mtune): Convert to string-based options.
12302         * config/arm/arm.c (arm_print_hint_for_core_or_arch): New function.
12303         (arm_parse_arch_cpu_name): New function.
12304         (arm_configure_build_target): Use arm_parse_arch_cpu_name to
12305         identify selected architecture or CPU.
12306         (arm_option_save): New function.
12307         (TARGET_OPTION_SAVE): Redefine.
12308         (arm_option_restore): Restore string options.
12309         (arm_option_print): Print string options.
12311 2017-06-16  Martin Sebor  <msebor@redhat.com>
12313         PR tree-optimization/80933
12314         PR tree-optimization/80934
12315         * builtins.c (fold_builtin_3): Do not handle bcmp here.
12316         * gimple-fold.c (gimple_fold_builtin_bcmp): New function.
12317         (gimple_fold_builtin_bcopy, gimple_fold_builtin_bzero): Likewise.
12318         (gimple_fold_builtin): Call them.
12320 2017-06-16  Jan Hubicka  <hubicka@ucw.cz>
12322         * gimple-ssa-isolate-paths.c (isolate_path): Set edge leading to path
12323         as unlikely; update profile.
12325 2017-06-16  Jan Hubicka  <hubicka@ucw.cz>
12327         * predict.c (force_edge_cold): Handle declaring edges impossible
12328         more aggresively.
12330 2017-06-16  Jan Hubicka  <hubicka@ucw.cz>
12332         * tree-ssa-loop-ivcanon.c (remove_exits_and_undefined_stmts): Update
12333         profile.
12334         (try_unroll_loop_completely): Fix reporting.
12336 2017-06-16  Jan Hubicka  <hubicka@ucw.cz>
12338         * tree-ssa-tail-merge.c (replace_block_by): Fix profile updating.
12340 2017-06-16  James Greenhalgh  <james.greenhalgh@arm.com>
12342         PR target/71778
12343         * config/arm/arm-builtins.c (arm_expand_builtin_args): Return TARGET
12344         if given a non-constant argument for an intrinsic which requires a
12345         constant.
12347 2017-06-16  Jan Hubicka  <hubicka@ucw.cz>
12349         * profile.c (compare_freqs): New function.
12350         (branch_prob): Sort edge list.
12351         (find_spanning_tree): Assume that the list is priority sorted.
12353 2017-06-16  Richard Biener  <rguenther@suse.de>
12355         PR tree-optimization/81090
12356         * passes.def (pass_record_bounds): Remove.
12357         * tree-pass.h (make_pass_record_bounds): Likewise.
12358         * tree-ssa-loop.c (pass_data_record_bounds, pass_record_bounds,
12359         make_pass_record_bounds): Likewise.
12360         * tree-ssa-loop-ivcanon.c (canonicalize_induction_variables): Do
12361         not free niter estimates at the beginning but at the end.
12362         * tree-scalar-evolution.c (scev_finalize): Free niter estimates.
12364 2017-06-16  Richard Biener  <rguenther@suse.de>
12366         * tree-switch-conversion.c (emit_case_bit_tests): Adjust
12367         initializer to workaround ICE in host GCC 4.8.
12369 2017-06-16  Jan Hubicka  <hubicka@ucw.cz>
12371         * ipa-inline-transform.c (update_noncloned_frequencies): Update also
12372         counts.
12373         (clone_inlined_nodes): Update.
12375 2017-06-16  Maxim Kuvyrkov  <maxim.kuvyrkov@linaro.org>
12377         * config/aarch64/aarch64.c (qdf24xx_prefetch_tune): Update
12378         prefetch settings, and enable prefetching by default at -O3.
12380 2017-06-16  Maxim Kuvyrkov  <maxim.kuvyrkov@linaro.org>
12382         * config/aarch64/aarch64.c (aarch64_override_options_internal):
12383         Set flag_prefetch_loop_arrays according to tuning data.
12385 2017-06-16  Maxim Kuvyrkov  <maxim.kuvyrkov@linaro.org>
12387         * config/aarch64/aarch64-protos.h (struct cpu_prefetch_tune):
12388         New tune structure.
12389         (struct tune_params): Use cpu_prefetch_tune instead of cache_line_size.
12390         [Unrelated to main purpose of the patch] Place the pointer field last
12391         to enable type checking errors when tune structure are wrongly merged.
12392         * config/aarch64/aarch64.c (generic_prefetch_tune,)
12393         (exynosm1_prefetch_tune, qdf24xx_prefetch_tune,)
12394         (thunderx2t99_prefetch_tune): New tune constants.
12395         (tune_params *_tunings): Update all tunings (no functional change).
12396         (aarch64_override_options_internal): Set PARAM_SIMULTANEOUS_PREFETCHES,
12397         PARAM_L1_CACHE_SIZE, PARAM_L1_CACHE_LINE_SIZE, and PARAM_L2_CACHE_SIZE
12398         from tunings structures.
12400 2017-06-16  Jakub Jelinek  <jakub@redhat.com>
12402         PR sanitizer/81094
12403         * ubsan.c (instrument_null): Add T argument, use it instead
12404         of computing it based on IS_LHS.
12405         (instrument_object_size): Likewise.
12406         (pass_ubsan::execute): Adjust instrument_null and
12407         instrument_object_size callers to pass gimple_get_lhs or
12408         gimple_assign_rhs1 result to it.  Use instrument_null instead of
12409         calling get_base_address and instrument_mem_ref.  Handle
12410         aggregate call arguments for object-size sanitization.
12412 2017-06-16  Yury Gribov  <tetra2005@gmail.com>
12414         PR tree-optimization/81089
12415         * tree-vrp.c (is_masked_range_test): Validate operands of
12416         subexpression.
12418 2017-06-15  Martin Sebor  <msebor@redhat.com>
12420         PR c++/80560
12421         * dumpfile.c (dump_register): Avoid calling memset to initialize
12422         a class with a default ctor.
12423         * gcc.c (struct compiler): Remove const qualification.
12424         * genattrtab.c (gen_insn_reserv): Replace memset with initialization.
12425         * hash-table.h: Ditto.
12426         * ipa-cp.c (allocate_and_init_ipcp_value): Replace memset with
12427           assignment.
12428         * ipa-prop.c (ipa_free_edge_args_substructures): Ditto.
12429         * omp-low.c (lower_omp_ordered_clauses): Replace memset with
12430         default ctor.
12431         * params.h (struct param_info): Make struct members non-const.
12432         * tree-switch-conversion.c (emit_case_bit_tests): Replace memset
12433         with default initialization.
12434         * vec.h (vec_copy_construct, vec_default_construct): New helper
12435         functions.
12436         (vec<T>::copy, vec<T>::splice, vec<T>::reserve): Replace memcpy
12437         with vec_copy_construct.
12438         (vect<T>::quick_grow_cleared): Replace memset with default ctor.
12439         (vect<T>::vec_safe_grow_cleared, vec_safe_grow_cleared): Same.
12440         * doc/invoke.texi (-Wclass-memaccess): Document.
12442 2017-06-15  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
12444         * emit-rtl.h (is_leaf): Update comment about local
12445         register allocator.
12447 2017-06-15  Jozef Lawrynowicz   <jozef.l@somniumtech.com>
12449         PR target/78818
12450         * config/msp430/msp430.c (msp430_data_attr): Check that it's possible
12451         for a variable to have a section before checking if the section has a
12452         name.
12453         Set section to.persistent if persistent attribute is set.
12454         Warn if .persistent attribute is used on an automatic variable.
12456 2017-06-15  Eric Botcazou  <ebotcazou@adacore.com>
12458         PR rtl-optimization/80474
12459         * reorg.c (update_block): Do not ignore instructions in a delay slot.
12461 2017-06-15  Segher Boessenkool  <segher@kernel.crashing.org>
12463         * config/rs6000/rs6000.md (add<mode>3): Use reg_or_subregno instead
12464         of REGNO.
12466 2017-06-14  Maciej W. Rozycki  <macro@imgtec.com>
12468         * config/mips/mips.md (MIPS16_T_REGNUM): Remove constant.
12469         (casesi): Emit bounds checking as RTL.
12470         (casesi_internal_mips16_<mode>): Remove bounds checking.
12472 2017-06-14  Max Filippov  <jcmvbkbc@gmail.com>
12474         * config/xtensa/xtensa.c (xtensa_option_override): Append
12475         MASK_CONST16 to target_flags in the absence of TARGET_L32R.
12476         (hwloop_optimize, hwloop_fail, hwloop_pattern_reg,
12477          xtensa_doloop_hooks): Define unconditionally.
12478         (xtensa_reorg_loops): Only call reorg_loops in the presence of
12479         TARGET_LOOPS.
12480         * config/xtensa/xtensa.h (TARGET_L32R): New definition.
12481         (TARGET_DEFAULT): Remove XCHAL_HAVE_L32R condition and account
12482         for it in xtensa_option_override.
12483         (HARD_FRAME_POINTER_IS_FRAME_POINTER,
12484          HARD_FRAME_POINTER_IS_ARG_POINTER): New definitions.
12486 2017-06-14  Boris Kolpackov  <boris@codesynthesis.com>
12488         * doc/cppopts.texi: Document '-' special value to -MF.
12490 2017-06-14  Wilco Dijkstra  <wdijkstr@arm.com>
12492         * config/arm/cortex-a53.md (cortex_a53_fpalu) Adjust latency.
12493         (cortex_a53_fconst): Likewise.
12494         (cortex_a53_fpmul): Likewise.
12495         (cortex_a53_f_load_64): Likewise.
12496         (cortex_a53_f_load_many): Likewise.
12497         (cortex_a53_advsimd_alu): Likewise.
12498         (cortex_a53_advsimd_alu_q): Likewise.
12499         (cortex_a53_advsimd_mul): Likewise.
12500         (cortex_a53_advsimd_mul_q): Likewise.
12501         (fpmac bypass): Add new bypass for fpmac-fpmac case.
12502         Add missing fmul, r2f_cvt and fconst cases.
12504 2017-06-14  Richard Biener  <rguenther@suse.de>
12506         PR middle-end/81088
12507         * fold-const.c (split_tree): Drop TREE_OVERFLOW flag from
12508         literal constants.
12509         (fold_binary_loc): When associating do not treat pre-existing
12510         TREE_OVERFLOW on literal constants as a reason to allow
12511         TREE_OVERFLOW on associated literal constants.
12513 2017-06-14  Eric Botcazou  <ebotcazou@adacore.com>
12515         * config/sparc/sparc.h (MASK_ISA): Add MASK_LEON and MASK_LEON3.
12516         (MASK_FEATURES): New macro.
12517         * config/sparc/sparc.c (sparc_option_override): Remove the special
12518         handling of -mfpu and generalize it to all MASK_FEATURES switches.
12520 2017-06-14  Eric Botcazou  <ebotcazou@adacore.com>
12522         * simplify-rtx.c (simplify_binary_operation_1) <UDIV>: Do not simplify
12523         a division of 0 if non-call exceptions are enabled.
12525 2017-06-14  Andrew Pinski  <apinski@cavium.com>
12526             Naveen H.S  <Naveen.Hurugalawadi@cavium.com>
12528         PR target/71663
12529         * config/aarch64/aarch64.c (aarch64_expand_vector_init):
12530         Improve vector initialization code gen for only variable case.
12532 2017-06-14  Eric Botcazou  <ebotcazou@adacore.com>
12534         * config/sparc/driver-sparc.c (cpu_names): Add SPARC-T5 entry.
12536 2017-06-14  Richard Biener  <rguenther@suse.de>
12538         PR tree-optimization/81083
12539         * tree-ssa-sccvn.c (vn_reference_lookup_3): Do not use abnormals
12540         as values.
12542 2017-06-13  Segher Boessenkool  <segher@kernel.crashing.org>
12544         * config/rs6000/rs6000.c: Update all comments that mentioned SPE.
12545         (rs6000_expand_builtin): Remove RS6000_BTC_EVSEL.
12546         * config/rs6000/rs6000.h (RS6000_BTC_EVSEL): Delete.
12547         * config/rs6000/vxworks.h (VXCPU_FOR_8548): Delete.  Adjust former use.
12548         * config/rs6000/vxworksae.h (VXCPU_FOR_8548): Delete.
12549         * config/rs6000/vxworksmils.h (VXCPU_FOR_8548): Delete.
12551 2017-06-13  Segher Boessenkool  <segher@kernel.crashing.org>
12553         * config/rs6000/rs6000-opts.h (enum rs6000_vector): Delete VECTOR_SPE.
12554         * config/rs6000/rs6000.c (rs6000_debug_vector_unit): Delete VECTOR_SPE.
12556 2017-06-13  Segher Boessenkool  <segher@kernel.crashing.org>
12558         * config/rs6000/rs6000.h (FIXED_SCRATCH): Delete.
12560 2017-06-13  Segher Boessenkool  <segher@kernel.crashing.org>
12562         * config/rs6000/t-rtems: Don't handle SPE.
12564 2017-06-13  Segher Boessenkool  <segher@kernel.crashing.org>
12566         * config/rs6000/t-linux: Don't handle SPE.
12568 2017-06-13  Segher Boessenkool  <segher@kernel.crashing.org>
12570         * config/rs6000/eabispe.h: Delete file.
12572 2017-06-13  Segher Boessenkool  <segher@kernel.crashing.org>
12574         * config/rs6000/t-spe: Delete file.
12576 2017-06-13  Segher Boessenkool  <segher@kernel.crashing.org>
12578         * config/rs6000/rs6000.c (SPE_CONST_OFFSET_OK): Delete.
12579         (rs6000_legitimate_offset_address_p): Return false for anything in
12580         V2SImode or V2SFmode.
12582 2017-06-13  Segher Boessenkool  <segher@kernel.crashing.org>
12584         * config/rs6000/rs6000-modes.def: Remove all 8-byte vector modes
12585         except V2SF and V2SI.  Rearrange the vector modes, and add comments.
12586         * config/rs6000/rs6000.c (rs6000_debug_reg_global): Remove V8QImode
12587         and V4HImode.
12588         (reg_offset_addressing_ok_p): Remove V4HImode and V1DImode.
12589         (rs6000_legitimate_offset_address_p): Ditto.
12590         (rs6000_emit_move): Ditto.
12591         (rs6000_init_builtins): Remove V4HI_type_node.
12593 2017-06-13  Martin Liska  <mliska@suse.cz>
12595         PR sanitize/78204
12596         * asan.c (asan_sanitize_stack_p): Use sanitize_flags_p.
12597         (gate_asan): Likewise.
12598         * asan.h (asan_no_sanitize_address_p): Remove the function.
12599         (sanitize_flags_p): New function.
12600         * builtins.def: Fix coding style.
12601         * common.opt: Use renamed enum value.
12602         * convert.c (convert_to_integer_1): Use sanitize_flags_p.
12603         * doc/extend.texi: Document no_sanitize attribute.
12604         * flag-types.h (enum sanitize_code): Rename SANITIZE_NONDEFAULT
12605         to SANITIZE_UNDEFINED_NONDEFAULT.
12606         * gcc.c (sanitize_spec_function): Use the renamed enum value.
12607         * gimple-fold.c (optimize_atomic_compare_exchange_p):
12608         Use sanitize_flags_p.
12609         * gimplify.c (gimplify_function_tree): Likewise.
12610         * ipa-inline.c (sanitize_attrs_match_for_inline_p): Likewise.
12611         * opts.c (parse_no_sanitize_attribute): New function.
12612         (common_handle_option): Use renamed enum value.
12613         * opts.h (parse_no_sanitize_attribute): Declare.
12614         * tree.c (sanitize_flags_p): New function.
12615         * tree.h: Declared here.
12616         * tsan.c: Use sanitize_flags_p.
12617         * ubsan.c (ubsan_expand_null_ifn): Likewise.
12618         (instrument_mem_ref): Likewise.
12619         (instrument_bool_enum_load): Likewise.
12620         (do_ubsan_in_current_function): Remove the function.
12621         (pass_ubsan::execute): Use sanitize_flags_p.
12622         * ubsan.h: Remove do_ubsan_in_current_function
12623         * tree-cfg.c (print_no_sanitize_attr_value): New function.
12624         (dump_function_to_file): Use it here.
12626 2017-06-13  Martin Jambor  <mjambor@suse.cz>
12628         PR tree-optimization/80803
12629         PR tree-optimization/81063
12630         * tree-sra.c (subtree_mark_written_and_enqueue): Move up in the file.
12631         (propagate_subaccesses_across_link): Enqueue subtree whenever
12632         necessary instead of relying on the caller.
12634 2017-06-13  Martin Jambor  <mjambor@suse.cz>
12636         * tree-sra.c (add_access_to_work_queue): Only enqueue accesses
12637         that have a first_link.
12638         (sort_and_splice_var_accesses): Do not check first_link before
12639         enquing.
12640         (subtree_mark_written_and_enqueue): Likewise.
12641         (propagate_all_subaccesses): Likewise and do not stop at first
12642         parent with a first_link.
12644 2017-06-13  Martin Jambor  <mjambor@suse.cz>
12646         * tree-sra.c (dump_access_tree_1): Fix accidental dumping to stderr
12647         instead of f.
12649 2017-06-13  Yury Gribov  <tetra2005@gmail.com>
12651         * match.pd: New pattern.
12653 2017-06-13  Yury Gribov  <tetra2005@gmail.com>
12655         * tree-vrp.c (is_masked_range_test): New function.
12656         (register_edge_assert_for): Determine ranges for
12657         some bit tests.
12659 2017-06-13  Yury Gribov  <tetra2005@gmail.com>
12661         PR tree-optimization/67328
12662         * fold-const.c (maskable_range_p): New function.
12663         (build_range_check): Generate bittests if possible.
12665 2017-06-13  Martin Liska  <mliska@suse.cz>
12667         * gimple-pretty-print.c (dump_probability): Add new argument.
12668         (dump_edge_probability): Dump both probability and count.
12669         (dump_gimple_label): Likewise.
12670         (dump_gimple_bb_header): Likewise.
12672 2017-06-13  Georg-Johann Lay  <avr@gjlay.de>
12674         PR target/81072
12675         * config/avr/avr-devices.c: Fix indentation.
12676         * config/avr/gen-avr-mmcu-specs.c: Dito.
12678 2017-06-13  Richard Biener  <rguenther@suse.de>
12680         * tree-vect-loop.c (vect_model_reduction_cost): Do not fail,
12681         instead get vector type from stmt_info.
12682         (vectorizable_reduction): Adjust.  Remove dead code.
12684 2017-06-13  Richard Biener  <rguenther@suse.de>
12686         PR middle-end/81065
12687         * fold-const.c (extract_muldiv_1): Remove bogus distribution
12688         case of C * (x * C2 + C3).
12689         (fold_addr_of_array_ref_difference): Properly fold index difference.
12691 2017-06-12  David S. Miller  <davem@davemloft.net>
12693         PR target/80968
12694         * config/sparc/sparc.md (return expander): Emit frame blockage if
12695         function uses alloca.
12697 2017-06-12  Richard Sandiford  <richard.sandiford@linaro.org>
12699         * combine.c (make_field_assignment): Check len rather than the mode
12700         precision when calling force_to_mode.
12702 2017-06-12  Georg-Johann Lay  <avr@gjlay.de>
12704         Support multilibs and devices that see flash in RAM address range.
12706         PR target/81072
12707         * config/avr/avr-arch.h (avr_arch_id) <ARCH_AVRXMEGA3>: New enum.
12708         (avr_mcu_t) <flash_pm_offset>: New field.
12709         (avr_device_specific_features) <AVR_ISA_RCALL>: New enum.
12710         * config/avr/avr.h (AVR_SHORT_CALLS): New define.
12711         (AVR_HAVE_JMP_CALL): Don't set if AVR_SHORT_CALLS.
12712         (AVR_TINY_PM_OFFSET): Remove macro.
12713         * config/avr/avr.opt (-mshort-calls): New option.
12714         * config/avr/gen-avr-mmcu-specs.c (print_mcu)
12715         [*self_spec]: Add / remove -mshort-calls depending on AVR_ISA_RCALL.
12716         * config/avr/avr-c.c (avr_cpu_cpp_builtins)
12717         <__AVR_SHORT_CALLS__>: Built-in define if AVR_SHORT_CALLS.
12718         <__AVR_HAVE_JMP_CALL__>: Use AVR_HAVE_JMP_CALL as condition
12719         instead of avr_arch->have_jmp_call.
12720         <__AVR_PM_BASE_ADDRESS__>: Built-in define if avr_arch->flash_pm_offset.
12721         [AVR_TINY] <__AVR_TINY_PM_BASE_ADDRESS__>: Use
12722         avr_arch->flash_pm_offset to define.
12723         * config/avr/avr-devices.c (avr_arch_types): Add initializers for
12724         new field flash_pm_offset.  Add entry for avrxmega3.
12725         (avr_texinfo): Add entry for avrxmega3.
12726         * config/avr/avr-mcus.def: Add entries for: avrxmega3,
12727         attiny212, attiny214,
12728         attiny412, attiny414, attiny416, attiny417,
12729         attiny814, attiny816, attiny817,
12730         attiny1614, attiny1616, attiny1617,
12731         attiny3214, attiny3216, attiny3217.
12732         * config/avr/avr.c (avr_assemble_integer)[AVR_TINY]: Use
12733         avr_arch->flash_pm_offset instead of AVR_TINY_PM_OFFSET.
12734         (avr_print_operand_address) [AVR_TINY]: Same.
12735         (avr_asm_init_sections) <readonly_data_section>: Only patch
12736         callback if avr_arch->flash_pm_offset = 0.
12737         (avr_asm_named_section) <avr_need_copy_data_p>: Skip setting it
12738         for rodata if avr_arch->flash_pm_offset != 0.
12739         (avr_encode_section_info) [AVR_TINY]: Adjust comment.
12740         * config/avr/genmultilib.awk (dir_rcall, opt_rcall): New vars.
12741         (opts) [AVR_ISA_RCALL]: Append opt_rcall.
12742         (m_options): Append opt_rcall.
12743         (m_dirnames): Append dir_rcall.
12744         * config/avr/t-multilib: Regenerate.
12746         * configure.ac [target=avr]: Check whether avrxmega3 default
12747         linker description file works as needed.
12748         * configure: Regenerate.
12749         * doc/avr-mmcu.texi: Regenerate.
12750         * doc/invoke.texi (AVR Options) <-mshort-calls>: Document it.
12751         <__AVR_ARCH__>: Document avrxmega3 and 103.
12752         <__AVR_HAVE_JMP_CALL__>: Adjust documentation.
12753         <__AVR_SHORT_CALLS__>: Document it.
12754         <__AVR_PM_BASE_ADDRESS__>: Document it.
12755         * doc/extend.texi (AVR Options) <-mshort-calls>: Document it.
12756         (AVR Variable Attributes) <progmem>: Document this is
12757         not needed for avrxmega3.
12758         (AVR Named Address Spaces) <__flash>: Dito.
12760 2017-06-12  Jan Hubicka  <hubicka@ucw.cz>
12762         * cgraph.c (cgraph_node::dump): Complain about profile insanities.
12764 2017-06-12  Doug Rupp  <rupp@adacore.com>
12766         * config.gcc (*-*-vxworks*): Set use_gcc_stdint to "provide".
12767         Append vxworks-stdint.h to the tm_file list.
12768         * config/vxworks-stdint.h: New file.
12770 2017-06-12  Martin Liska  <mliska@suse.cz>
12772         PR tree-optimization/81041
12773         * tree-profile.c (gimple_gen_ic_func_profiler):
12774         Create an extra BB in profile-generate
12775         (gimple_gen_time_profiler): Likewise.
12777 2017-06-12  Jakub Jelinek  <jakub@redhat.com>
12779         PR tree-optimization/81003
12780         * tree-ssa-reassoc.c (force_into_ssa_name): New function.
12781         (update_range_test): Use it instead of force_gimple_operand_gsi.
12783 2017-06-12  Richard Biener  <rguenther@suse.de>
12785         PR tree-optimization/81053
12786         * tree-vect-loop.c (vect_is_simple_reduction): Handle PHI
12787         with backedge value not defined in loop.  Simplify def stmt
12788         compute.
12790 2017-06-11  Tom de Vries  <tom@codesourcery.com>
12792         PR target/79939
12793         * config/nvptx/nvptx.c (nvptx_cannot_force_const_mem): New function.
12794         Return true.
12795         (TARGET_CANNOT_FORCE_CONST_MEM): Redefine to
12796         nvptx_cannot_force_const_mem.
12798 2017-06-10  Jan Hubicka  <hubicka@ucw.cz>
12800         * opts.c (finish_options): Move test for flag_split_stack after
12801         it has been initialized.
12803 2017-06-11  Jason Merrill  <jason@redhat.com>
12805         * tree.h (id_equal): New.
12806         * dwarf2out.c, hsa-gen.c, ipa-devirt.c, omp-expand.c,
12807         omp-simd-clone.c, read-rtl-function.c, tree-chkp.c, tree.c: Use it
12808         instead of strcmp of IDENTIFIER_POINTER.
12810 2017-06-10  Jan Hubicka  <hubicka@ucw.cz>
12812         * ipa-inline-transform.c: Include function.h, cfg.h and basic-block.h
12813         (mark_all_inlined_calls_cdtor): Fix formating.
12814         (inline_transform): Rescale profile before inlining.
12816 2017-06-10  Jan Hubicka  <hubicka@ucw.cz>
12818         * cgraph.h (cgraph_edge::clone): Update prototype.
12819         * cgraphclones.c (cgraph_edge::clone): Update profile scaling.
12820         (cgraph_node::create_clone): Update.
12821         (cgraph_node::create_version_clone): Update.
12822         * tree-inline.c (copy_bb): Update.
12823         (expand_call_inline): Update.
12825 2017-06-10  Segher Boessenkool  <segher@kernel.crashing.org>
12827         * config/rs6000/rs6000.c (emit_vrsave_prologue): New function,
12828         factored out from ...
12829         (rs6000_emit_prologue): ... here.
12831 2017-06-10  Segher Boessenkool  <segher@kernel.crashing.org>
12833         * config/rs6000/rs6000.c (emit_split_stack_prologue): New function,
12834         factored out from ...
12835         (rs6000_emit_prologue): ... here.
12837 2017-06-10  Jan Hubicka  <hubicka@ucw.cz>
12839         * predict.c (drop_profile): Also drop individual bb/edge and cgraph
12840         edge counts.
12841         (handle_missing_profiles): Fix computation of tp_first_run.
12842         (counts_to_freqs): Do not touch freqs when count is 0.
12844 2017-06-10  Jan Hubicka  <hubicka@ucw.cz>
12846         * cgraphbuild.c (cgraph_edge::rebuild_references): Do not touch
12847         profile.
12849 2017-06-10  Tom de Vries  <tom@codesourcery.com>
12851         * doc/sourcebuild.texi (Effective-Target Keywords, Environment
12852         attributes): Document signal effective target.
12854 2017-06-10  Tom de Vries  <tom@codesourcery.com>
12856         * doc/sourcebuild.texi (Effective-Target Keywords, Other attributes):
12857         Document effective target stack_size.
12859 2017-06-09  David Malcolm  <dmalcolm@redhat.com>
12861         * diagnostic.c (diagnostic_report_diagnostic): Only add fixits
12862         to the edit_context if they can be auto-applied.
12864 2017-06-9  Ian Lance Taylor  <iant@golang.org>
12866         * opts.c (finish_options): If -fsplit-stack, disable implicit
12867         -forder-blocks-and-partition.
12868         * doc/invoke.texi (Optimize Options): Document that when using
12869         -fsplit-stack -forder-blocks-and-partition is not implicitly
12870         enabled.
12872 2017-06-09  Jan Hubicka  <hubicka@ucw.cz>
12874         * builtin-attrs.def (ATTR_NORETURN_NOTHROW_LEAF_COLD_LIST,
12875         ATTR_CONST_NORETURN_NOTHROW_LEAF_COLD_LIST,
12876         ATTR_TMPURE_NORETURN_NOTHROW_LEAF_COLD_LIST): New.
12877         * builtins.def (abort, trap, unreachable): Declare cold.
12878         * calls.c (flags_from_decl_or_type): Lookup ECF_COLD.
12879         * tree-core.h (ECF_COLD): New.
12880         * tree.c (set_call_expr_flags): Handle ECF_COLD.
12881         (build_common_builtin_nodes): Mark unreachable and abort as cold.
12883 2017-06-09  Jan Hubicka  <hubicka@ucw.cz>
12885         * predict.c (unlikely_executed_stmt_p): Cleanup.
12887 2017-06-09  Richard Biener  <rguenther@suse.de>
12889         * tree-ssa-loop-im.c (execute_sm): Do not force multi-threaded
12890         model if the ref is always written to.
12892 2017-06-09  Tamar Christina  <tamar.christina@arm.com>
12894         * config/aarch64/aarch64.md (lrint<GPF:mode><GPI:mode>2): New.
12896 2017-06-09  Tamar Christina  <tamar.christina@arm.com>
12898         * config/arm/arm.c (arm_rtx_costs_internal): Make sdiv more expensive
12899         than udiv.
12901 2017-06-09  Tom de Vries  <tom@codesourcery.com>
12903         PR target/80855
12904         * config/nvptx/nvptx.md (define_expand "mov<QHSDISDFM>"): Error out with
12905         "target cannot support label values" when encountering LABEL_REF.
12907 2017-06-09  Martin Liska  <mliska@suse.cz>
12909         * tree-profile.c (gimple_gen_ic_profiler): Update comment.
12910         (gimple_gen_ic_func_profiler): Emit direct comparison
12911         of __gcov_indirect_call_callee with NULL.
12912         (gimple_gen_time_profiler): Change probability from
12913         PROB_VERY_UNLIKELY to PROB_UNLIKELY.
12915 2017-06-09  Jan Hubicka  <hubicka@ucw.cz>
12917         * profile.c (edge_gcov_counts): Turn to pointer.
12918         (compute_branch_probabilities, compute_branch_probabilities): Update.
12919         (branch_prob): Do not clear edge_gcov_count.
12920         * profile.h (edge_gcov_counts): Turn to pointer.
12921         (edge_gcov_count): Update.
12923 2017-06-09  Jan Hubicka  <hubicka@ucw.cz>
12925         * gimple.h (gimple_check_failed): Mark cold.
12927 2017-06-09  Richard Biener  <rguenther@suse.de>
12929         PR tree-optimization/66623
12930         * tree-vect-loop.c (vect_is_simple_reduction): Cleanup,
12931         refactor check_reduction into two parts, properly computing
12932         whether we have to check reduction validity for outer loop
12933         vectorization.
12935 2017-06-09  Richard Biener  <rguenther@suse.de>
12937         PR tree-optimization/79483
12938         * graphite-scop-detection.c (order): New global.
12939         (get_order): Compute bb to order mapping that satisfies code
12940         generation constraints.
12941         (cmp_pbbs): New helper.
12942         (build_scops): Start domwalk at entry block, sort generated
12943         pbbs.
12945 2017-06-09  Richard Biener  <rguenther@suse.de>
12947         PR middle-end/81007
12948         * ipa-polymorphic-call.c
12949         (ipa_polymorphic_call_context::restrict_to_inner_class):
12950         Skip FIELD_DECLs with error_mark_node type.
12951         * passes.def (all_lowering_passes): Run pass_build_cgraph_edges
12952         last again.
12954 2017-06-09  Martin Liska  <mliska@suse.cz>
12956         * predict.c (struct branch_predictor): New struct.
12957         (test_prediction_value_range): New test.
12958         (predict_c_tests): New function.
12959         * selftest-run-tests.c (selftest::run_tests): Run the function.
12960         * selftest.h: Declare new tests.
12962 2017-06-09  Segher Boessenkool  <segher@kernel.crashing.org>
12964         PR target/80966
12965         * config/rs6000/rs6000.c (rs6000_emit_allocate_stack): Assert that
12966         gen_add3_insn did not fail.
12967         * config/rs6000/rs6000.md (add<mode>3): If asked to add a constant to
12968         r0, construct that number in a temporary reg and add that reg to r0.
12969         If asked to put the result in r0 as well, fail.
12971 2017-06-08  Will Schmidt  <will_schmidt@vnet.ibm.com>
12973         * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Add handling
12974         for early expansion of vec_eqv.
12976 2017-06-08  Jakub Jelinek  <jakub@redhat.com>
12978         PR middle-end/81005
12979         * ubsan.c (instrument_null): Avoid pointless code temporary.
12980         (pass_ubsan::execute): Instrument aggregate arguments of calls.
12982 2017-06-08  Uros Bizjak  <ubizjak@gmail.com>
12984         PR target/81015
12985         Revert:
12986         2016-12-14  Uros Bizjak  <ubizjak@gmail.com>
12988         PR target/59874
12989         * config/i386/i386.md (*ctzhi2): New insn_and_split pattern.
12990         (*clzhi2): Ditto.
12992 2017-06-08  Jan Hubicka  <hubicka@ucw.cz>
12994         * predict.c (unlikely_executed_edge_p): Move ahead.
12995         (probably_never_executed_edge_p): Use it.
12997 2017-06-08  Alexander Ivchenko  <alexander.ivchenko@intel.com>
12999         PR middle-end/79988
13000         * tree-chkp.c (chkp_gimple_call_builtin_p): Remove
13001         gimple_call_builtin_p call.
13003 2017-06-08  Jan Hubicka  <hubicka@ucw.cz>
13005         * system.h (fancy_abort): Annotate by ATTRIBUTE_COLD.
13006         * rtl.h (rtl_check_failed_bounds, rtl_check_failed_type1,
13007         rtl_check_failed_type2, rtl_check_failed_code1,
13008         rtl_check_failed_code2, rtl_check_failed_code_mode,
13009         rtl_check_failed_block_symbol, cwi_check_failed_bounds,
13010         rtvec_check_failed_bounds, rtl_check_failed_flag,
13011         _fatal_insn_not_found, _fatal_insn): Likewise.
13012         * tree.h (tree_contains_struct_check_failed,
13013         tree_check_failed, tree_not_check_failed,
13014         tree_class_check_failed, tree_range_check_failed,
13015         tree_not_class_check_failed, tree_int_cst_elt_check_failed,
13016         tree_vec_elt_check_failed, phi_node_elt_check_failed,
13017         tree_operand_check_failed, omp_clause_check_failed,
13018         omp_clause_operand_check_failed, omp_clause_range_check_failed):
13019         Likewise.
13021 2017-06-08  Jan Hubicka  <hubicka@ucw.cz>
13023         * cgraph.c (cgraph_edge::maybe_hot_p): Do not check
13024         flag_branch_probabilities.
13025         * ipa-inline.c (edge_badness): Likewise.
13026         * ipa-profile.c (ipa_propagate_frequency_1): Likewise.
13027         * postreload-gcse.c (eliminate_partially_redundant_load): Likewise.
13028         * predict.c (maybe_hot_frequency_p): Likewise.
13029         (probably_never_executed): Likewise.
13030         * sched-ebb.c (schedule_ebbs): Likewise.
13031         * sched-rgn.c (find_single_block_region): Likewise.
13032         * tracer.c (tail_duplicate): Likewise.
13034 2017-06-08  Jan Hubicka  <hubicka@ucw.cz>
13036         * opts.c (finish_options): x_flag_reorder_blocks_and_partition no
13037         longer requires x_flag_profile_use.
13039 2017-06-08  Jan Hubicka  <hubicka@ucw.cz>
13041         * cfgrtl.c (cfg_layout_initialize): Check crtl->has_bb_partition
13042         instead of flag_reorder_blocks_and_partition.
13043         * dbxout.c (dbxout_function_end): Likewise.
13044         * dwarf2out.c (gen_subprogram_die): Likewise.
13045         * haifa-sched.c (sched_create_recovery_edges): Likewise.
13046         * hw-doloop.c (reorg_loops): Likewise.
13047         * varasm.c (assemble_start_function,
13048         assemble_end_function): Likewise.
13049         (decide_function_section): Do not check for
13050         flag_reorder_blocks_and_partition.
13052 2017-06-08  Alexander Ivchenko  <alexander.ivchenko@intel.com>
13054         * tree-chkp.c (chkp_get_hard_register_var_fake_base_address):
13055         New function.
13056         (chkp_get_hard_register_fake_addr_expr): Ditto.
13057         (chkp_build_addr_expr): Add check for hard reg case.
13058         (chkp_parse_array_and_component_ref): Ditto.
13059         (chkp_find_bounds_1): Ditto.
13060         (chkp_process_stmt): Don't generate bounds store for
13061         hard reg case.
13063 2017-06-08  Jan Hubicka  <hubicka@ucw.cz>
13065         * predict.c (maybe_hot_bb_p): Do not check profile status.
13066         (maybe_hot_edge_p): Likewise.
13067         (probably_never_executed): Check for zero counts even if profile
13068         is not read.
13069         (unlikely_executed_edge_p): New function.
13070         (unlikely_executed_stmt_p): New function.
13071         (unlikely_executed_bb_p): New function.
13072         (set_even_probabilities): Use unlikely predicates.
13073         (combine_predictions_for_bb): Likewise.
13074         (predict_paths_for_bb): Likewise.
13075         (predict_paths_leading_to_edge): Likewise.
13076         (determine_unlikely_bbs): New function.
13077         (estimate_bb_frequencies): Use it.
13078         (compute_function_frequency): Use zero counts even if profile is
13079         not read.
13080         * profile-count.h: Fix typo.
13082 2017-08-08  Julia Koval  <julia.koval@intel.com>
13084         * config/i386/avx512bwintrin.h (_mm512_mask_cvtepi16_storeu_epi8,
13085         _mm512_mask_cvtsepi16_storeu_epi8,
13086         _mm512_mask_cvtusepi16_storeu_epi8): New intrinsics.
13087         * config/i386/avx512vlbwintrin.h (_mm256_mask_cvtepi16_storeu_epi8,
13088         _mm_mask_cvtsepi16_storeu_epi8, _mm256_mask_cvtsepi16_storeu_epi8,
13089         _mm_mask_cvtusepi16_storeu_epi8, _mm256_mask_cvtusepi16_storeu_epi8,
13090         _mm_mask_cvtepi16_storeu_epi8): New intrinsics.
13091         * config/i386/i386-builtin-types.def (PV8Q, V8QI): New pointer type.
13092         (VOID_FTYPE_PV32QI_V32HI_USI, VOID_FTYPE_PV8QI_V8HI_UQI,
13093         VOID_FTYPE_PV16QI_V16HI_UHI): New function types.
13094         * config/i386/i386-builtin.def (__builtin_ia32_pmovwb128mem_mask,
13095         __builtin_ia32_pmovwb256mem_mask, __builtin_ia32_pmovswb128mem_mask,
13096         __builtin_ia32_pmovswb256mem_mask, __builtin_ia32_pmovuswb128mem_mask,
13097         __builtin_ia32_pmovuswb256mem_mask,
13098         __builtin_ia32_pmovuswb512mem_mask, __builtin_ia32_pmovswb512mem_mask)
13099         __builtin_ia32_pmovwb512mem_mask): New builtins.
13101 2017-08-08  Julia Koval  <julia.koval@intel.com>
13103         PR target/73350,80862
13104         * config/i386/subst.md (round): Fix round pattern.
13105         * config/i386/i386.c (ix86_erase_embedded_rounding):
13106         Fix erasing rounding for the fixed pattern.
13108 2017-06-08  Jan Hubicka  <hubicka@ucw.cz>
13110         * cfgbuild.c (find_many_sub_basic_blocks): Fix thinko.
13112 2017-06-08  Martin Liska  <mliska@suse.cz>
13114         PR gcov-profile/80911
13115         * gcov.c (block_info::block_info): New constructor.
13117 2017-06-07  Carl Love  <cel@us.ibm.com>
13119         * config/rs6000/rs6000-c: The return type of the following
13120         built-in functions was implemented as int not long long.  Fix sign
13121         of return value for the unsigned version of vec_mulo and vec_mule.
13122         vector unsigned long long vec_bperm (vector unsigned long long,
13123                                              vector unsigned char)
13124         vector signed long long vec_mule (vector signed int,
13125                                           vector signed int)
13126         vector unsigned long long vec_mule (vector unsigned int,
13127                                             vector unsigned int)
13128         vector signed long long vec_mulo (vector signed int,
13129                                           vector signed int)
13130         vector unsigned long long vec_mulo (vector unsigned int,
13131                                             vector unsigned int)
13132         * doc/extend.texi: Fix the documentation for the built-in
13133         functions.
13135 2017-06-07  Carl Love  <cel@us.ibm.com>
13137         PR target/80982
13138         * config/rs6000/altivec.md (double<mode>2): Fix the implementation of
13139         for BE.
13141 2017-06-07  Carl Love  <cel@us.ibm.com>
13143         * config/rs6000/altivec.md: Fix argument swizzle in vec_doublel
13144         support, Generate       doublehv for signed int/float for BE case only.
13146 2017-06-07  Alexander Monakov  <amonakov@ispras.ru>
13148         * doc/invoke.texi (mcx16): Rewrite.
13150 2017-06-07  Segher Boessenkool  <segher@kernel.crashing.org>
13152         * config/rs6000/predicates.md (rs6000_nonimmediate_operand): Delete.
13153         * config/rs6000/rs6000.md (*movsi_internal1, movsi_from_sf,
13154         *mov<mode>_softfloat, and an anonymous splitter): Use
13155         nonimmediate_operand instead of rs6000_nonimmediate_operand.
13157 2017-06-07  Segher Boessenkool  <segher@kernel.crashing.org>
13159         * config/rs6000/darwin.h (REGISTER_NAMES): Delete the SPE_ACC and
13160         SPEFSCR registers.
13161         * config/rs6000/rs6000.c (rs6000_reg_names, alt_reg_names): Ditto.
13162         (enum rs6000_reg_type): Delete SPE_ACC_TYPE and SPEFSCR_REG_TYPE.
13163         (rs6000_debug_reg_global): Adjust.
13164         (rs6000_init_hard_regno_mode_ok): Adjust.
13165         (rs6000_dbx_register_number): Adjust.
13166         * config/rs6000/rs6000.h (FIRST_PSEUDO_REGISTER): Change to 115.
13167         (FIXED_REGISTERS, CALL_USED_REGISTERS, CALL_REALLY_USED_REGISTERS):
13168         Remove SPE_ACC and SPEFSCR.
13169         (REG_ALLOC_ORDER): Ditto.
13170         (FRAME_POINTER_REGNUM): Change to 111.
13171         (enum reg_class): Remove the SPE_ACC and SPEFSCR registers.
13172         (REG_CLASS_NAMES): Ditto.
13173         (REG_CLASS_CONTENTS): Delete the SPE_ACC and SPEFSCR registers.
13174         (REGISTER_NAMES): Ditto.
13175         (ADDITIONAL_REG_NAMES): Ditto.
13176         (rs6000_reg_names): Ditto.
13177         * config/rs6000/rs6000.md: Renumber some register number
13178         define_constants.
13180 2017-06-07  Segher Boessenkool  <segher@kernel.crashing.org>
13182         * config/rs6000/darwin.h (REGISTER_NAMES): Delete the SPE high
13183         registers.
13184         * config/rs6000/rs6000.c (rs6000_reg_names, alt_reg_names): Ditto.
13185         * config/rs6000/rs6000.h (FIRST_PSEUDO_REGISTER): Change from 149
13186         to 117.
13187         (DWARF_REG_TO_UNWIND_COLUMN): Do not define.
13188         (FIXED_REGISTERS, CALL_USED_REGISTERS, CALL_REALLY_USED_REGISTERS):
13189         Delete the SPE high registers.
13190         (REG_ALLOC_ORDER): Ditto.
13191         (enum reg_class): Remove SPE_HIGH_REGS.
13192         (REG_CLASS_NAMES): Ditto.
13193         (REG_CLASS_CONTENTS): Delete the SPE high registers.
13194         (REGISTER_NAMES): Ditto.
13195         (rs6000_reg_names): Ditto.
13196         * doc/tm.texi.in: Remove SPE as example.
13197         * doc/tm.texi: Regenerate.
13199 2017-06-07  Segher Boessenkool  <segher@kernel.crashing.org>
13201         * config/rs6000/8540.md (ppc8540_brinc): Delete.
13202         * config/rs6000/e500mc.md (e500mc_brinc): Delete.
13203         * config/rs6000/e500mc64.md (e500mc64_brinc): Delete.
13204         * config/rs6000/rs6000.md (type): Remove "brinc".
13206 2017-06-07  Segher Boessenkool  <segher@kernel.crashing.org>
13208         * config.gcc (powerpc*-*-*): Don't add spe.h to extra_headers.
13209         (powerpc*-linux*spe*): Use ${cpu_type} instead of rs6000.
13210         * config/rs6000/linuxspe.h: Delete file.
13211         * config/rs6000/rs6000.md: Don't include spe.md.
13212         * config/rs6000/spe.h: Delete file.
13213         * config/rs6000/spe.md: Delete file.
13214         * config/rs6000/t-rs6000: Remove spe.md.
13216 2017-06-07  Segher Boessenkool  <segher@kernel.crashing.org>
13218         * config/rs6000/predicates.md (reg_or_mem_operand): Reformat.
13219         (reg_or_none500mem_operand): Delete.
13220         * config/rs6000/rs6000.md (extendsfdf2): Use reg_or_mem_operand
13221         instead of reg_or_none500mem_operand.
13223 2017-06-07  Segher Boessenkool  <segher@kernel.crashing.org>
13225         * config/rs6000/rs6000.c (rs6000_option_override_internal): Delete
13226         handling of SPE flags.
13227         * config/rs6000/rs6000.opt (-mspe, -mspe=no, -mspe=yes): Delete.
13229 2017-06-07  Segher Boessenkool  <segher@kernel.crashing.org>
13231         * config/rs6000/rs6000-common.c (rs6000_handle_option): Remove
13232         SPE ABI handling.
13233         * config/rs6000/paired.md (paired_negv2sf2): Rename to negv2sf2.
13234         (paired_absv2sf2, paired_addv2sf3, paired_subv2sf3, paired_mulv2sf3,
13235         paired_divv2sf3): Similar.
13236         * config/rs6000/predicates.md: Replace TARGET_SPE, TARGET_SPE_ABI,
13237         SPE_VECTOR_MODE and SPE_HIGH_REGNO_P by 0; simplify.
13238         * config/rs6000/rs6000-builtin.def: Delete RS6000_BUILTIN_E and
13239         RS6000_BUILTIN_S.
13240         Delete BU_SPE_1, BU_SPE_2, BU_SPE_3, BU_SPE_E, BU_SPE_P, and BU_SPE_X.
13241         Rename the paired_* instruction patterns.
13242         * config/rs6000/rs6000-c.c (rs6000_target_modify_macros): Do not
13243         define __SPE__.
13244         * config/rs6000/rs6000-protos.h (invalid_e500_subreg): Delete.
13245         * config/rs6000/rs6000.c: Delete RS6000_BUILTIN_E and RS6000_BUILTIN_S.
13246         (struct rs6000_stack): Delete fields spe_gp_save_offset, spe_gp_size,
13247         spe_padding_size, and spe_64bit_regs_used.  Replace TARGET_SPE and
13248         TARGET_SPE_ABI with 0, simplify.  Replace SPE_VECTOR_MODE with
13249         PAIRED_VECTOR_MODE.
13250         (struct machine_function): Delete field spe_insn_chain_scanned_p.
13251         (spe_func_has_64bit_regs_p): Delete.
13252         (spe_expand_predicate_builtin): Delete.
13253         (spe_expand_evsel_builtin): Delete.
13254         (TARGET_DWARF_REGISTER_SPAN): Do not define.
13255         (TARGET_MEMBER_TYPE_FORCES_BLK): Do not define.
13256         (invalid_e500_subreg): Delete.
13257         (rs6000_legitimize_address): Always force_reg op2 as well, for
13258         paired single memory accesses.
13259         (rs6000_member_type_forces_blk): Delete.
13260         (rs6000_spe_function_arg): Delete.
13261         (rs6000_expand_unop_builtin): Delete SPE handling.
13262         (rs6000_expand_binop_builtin): Ditto.
13263         (spe_expand_stv_builtin): Delete.
13264         (bdesc_2arg_spe): Delete.
13265         (spe_expand_builtin): Delete.
13266         (spe_expand_predicate_builtin): Delete.
13267         (spe_expand_evsel_builtin): Delete.
13268         (rs6000_invalid_builtin): Remove RS6000_BTM_SPE handling.
13269         (spe_init_builtins): Delete.
13270         (spe_func_has_64bit_regs_p): Delete.
13271         (savres_routine_name): Delete "info" parameter.  Adjust callers.
13272         (rs6000_emit_stack_reset): Ditto.
13273         (rs6000_dwarf_register_span): Delete.
13274         * config/rs6000/rs6000.h (TARGET_SPE_ABI, TARGET_SPE,
13275         UNITS_PER_SPE_WORD, SPE_HIGH_REGNO_P, SPE_SIMD_REGNO_P,
13276         SPE_VECTOR_MODE, RS6000_BTM_SPE, RS6000_BUILTIN_E, RS6000_BUILTIN_S):
13277         Delete.
13278         * config/rs6000/rs6000.md (FIRST_SPE_HIGH_REGNO, LAST_SPE_HIGH_REGNO):
13279         Delete.
13280         * config/rs6000/rs6000.opt (-mabi=spe, -mabi=no-spe): Delete.
13281         * config/rs6000/spe.md: Delete every pattern that uses TARGET_SPE.
13282         * config/rs6000/vector.md (absv2sf2, negv2sf2, addv2sf3, subv2sf3,
13283         mulv2sf3, divv2sf3): Delete expanders.
13285 2017-06-07  Segher Boessenkool  <segher@kernel.crashing.org>
13287         config/rs6000/rs6000.md (UNSPEC_MV_CR_GT): Delete.
13289 2017-06-07  Segher Boessenkool  <segher@kernel.crashing.org>
13291         * config/rs6000/rs6000-protos.h (output_e500_flip_gt_bit): Delete.
13292         * config/rs6000/rs6000.c: Ditto.
13294 2017-06-07  Segher Boessenkool  <segher@kernel.crashing.org>
13296         * config/rs6000/predicated.md (rs6000_cbranch_operator): Delete.
13297         * config/rs6000/rs6000.md: Replace rs6000_cbranch_operator by
13298         comparison_operator.
13300 2017-06-07  Segher Boessenkool  <segher@kernel.crashing.org>
13302         * config/rs6000/rs6000.c: Remove everything related to -mfloat-gprs.
13303         * config/rs6000/rs6000.opt: Ditto.
13304         * config/rs6000/t-rtems: Ditto.
13306 2017-06-07  Segher Boessenkool  <segher@kernel.crashing.org>
13308         * config/rs6000/predicates.md: Replace TARGET_E500_DOUBLE and
13309         TARGET_E500_SINGLE by 0, simplify.
13310         * config/rs6000/rs6000.c: Ditto.
13311         (rs6000_option_override_internal): Delete CHECK_E500_OPTIONS.
13312         (spe_build_register_parallel): Delete.
13313         * config/rs6000/rs6000.h: Delete TARGET_E500_SINGLE,
13314         TARGET_E500_DOUBLE, and CHECK_E500_OPTIONS.
13315         * config/rs6000/rs6000.md: Replace TARGET_E500_DOUBLE,
13316         TARGET_E500_SINGLE, and <E500_CONVERT> by 0, simplify.
13317         (E500_CONVERT): Delete.
13318         * config/rs6000/spe.md: Remove many patterns and all define_constants.
13320 2017-06-07  Segher Boessenkool  <segher@kernel.crashing.org>
13322         * config/rs6000/darwin.md: Replace TARGET_FPRS by 1 and simplify.
13323         * config/rs6000/dfp.md: Ditto.
13324         (negdd2, *negdd2_fpr): Merge.
13325         (absdd2, *absdd2_fpr): Merge.
13326         (negtd2, *negtd2_fpr): Merge.
13327         (abstd2, *abstd2_fpr): Merge.
13328         * config/rs6000/e500.h: Delete file.
13329         * config/rs6000/predicates.md (rs6000_cbranch_operator): Replace
13330         TARGET_FPRS by 1 and simplify.
13331         * config/rs6000/rs6000-c.c: Ditto.
13332         * config/rs6000/rs6000.c: Ditto.  Also replace TARGET_SF_SPE and
13333         TARGET_DF_SPE by 0.
13334         * config/rs6000/rs6000.h: Ditto.  Delete TARGET_SF_SPE and
13335         TARGET_DF_SPE.
13336         * config/rs6000/rs6000.md: Ditto.
13337         (floatdidf2, *floatdidf2_fpr): Merge.
13338         (move_from_CR_gt_bit): Delete.
13339         * config/rs6000/spe.md: Replace TARGET_FPRS by 1 and simplify.
13340         (E500_CR_IOR_COMPARE): Delete.
13341         (All patterns that require !TARGET_FPRS): Delete.
13342         * config/rs6000/vsx.md: Replace TARGET_FPRS by 1 and simplify.
13344 2017-06-07  Bin Cheng  <bin.cheng@arm.com>
13346         * passes.def (pass_iv_canon): Move before pass_loop_distribution.
13348 2017-06-07  Bin Cheng  <bin.cheng@arm.com>
13350         * graphds.c (add_edge): Intitialize edge's attached data.
13351         (foll_in_subgraph, dfs_fst_edge, dfs_next_edge): New function
13352         pointer parameter.  Call pointed function on each edge during
13353         graph traversing.  Skip traversing the edge when the function
13354         returns true.
13355         (graphds_dfs, graphds_scc): Ditto.
13356         (for_each_edge): New parameter.  Pass the new parameter to callback
13357         function.
13358         * graphds.h (skip_edge_callback): New function pointer type.
13359         (graphds_dfs, graphds_scc): New function pointer parameter.
13360         (graphds_edge_callback, for_each_edge): New parameter.
13362 2017-06-07  Bin Cheng  <bin.cheng@arm.com>
13364         * tree-vect-data-refs.c (vect_mark_for_runtime_alias_test): Factor
13365         out code checking if runtime alias check is possible to below ...
13366         Call the new function.
13367         * tree-data-ref.c (runtime_alias_check_p): ... to new function.
13368         * tree-data-ref.h (runtime_alias_check_p): New decalaration.
13370 2017-06-07  Marek Polacek  <polacek@redhat.com>
13372         PR sanitizer/80932
13373         * fold-const.c (extract_muldiv_1) <case MINUS_EXPR>: Add
13374         TYPE_OVERFLOW_WRAPS check.
13376 2017-06-07  Bin Cheng  <bin.cheng@arm.com>
13378         * tree-vect-loop-manip.c (vect_do_peeling): Don't skip vector loop
13379         if versioning is required.
13380         * tree-vect-loop.c (vect_analyze_loop_2): Merge niter check for loop
13381         peeling with the check for versioning.
13383 2017-06-07  Bin Cheng  <bin.cheng@arm.com>
13385         * tree-vectorizer.h (vect_build_loop_niters): New parameter.
13386         * tree-vect-loop-manip.c (vect_build_loop_niters): New parameter.
13387         Set true to new parameter if new ssa variable is defined.
13388         (vect_gen_vector_loop_niters): Refactor.  Set range information
13389         for the new vector loop bound variable.
13390         (vect_do_peeling): Ditto.
13392 2017-06-07  Bin Cheng  <bin.cheng@arm.com>
13394         * tree-affine.c (ssa.h): Include header file.
13395         (tree_to_aff_combination): Handle (T1)(X - CST) when inner type
13396         has wrapping overflow behavior.
13398 2017-06-07  Bin Cheng  <bin.cheng@arm.com>
13400         * tree-affine.c (tree_to_aff_combination): Handle (T1)(X + X).
13402 2017-06-07  Bin Cheng  <bin.cheng@arm.com>
13404         (aff_combination_expand): Move (T1)(X *+- CST) simplification to ...
13405         (tree_to_aff_combination): ... here.
13407 2017-06-07  Bin Cheng  <bin.cheng@arm.com>
13409         * tree-ssa-loop-ivopts.c (ivopts_estimate_reg_pressure): New
13410         reg_pressure model function.
13411         (ivopts_global_cost_for_size): Delete.
13412         (determine_set_costs, iv_ca_recount_cost): Call new model function
13413         ivopts_estimate_reg_pressure.
13415 2017-06-07  Tamar Christina  <tamar.christina@arm.com>
13417         * config/aarch64/aarch64.c (aarch64_rtx_costs): Make sdiv more
13418         expensive than udiv.  Remove floating point cases from mod.
13420 2017-06-07  Tamar Christina  <tamar.christina@arm.com>
13422         * config/arm/aarch-cost-tables.h (cortexa53_extra_cost):
13423         Increase idiv cost.
13425 2017-06-07  Tamar Christina  <tamar.christina@arm.com>
13427         * config/aarch64/aarch64.md
13428         (copysignsf3): Fix mask generation.
13430 2017-06-07  Jakub Jelinek  <jakub@redhat.com>
13432         * dumpfile.h (enum tree_dump_index): Rename TDI_generic to
13433         TDI_gimple.
13434         (class dump_manager): Add register_dumps method.
13435         * dumpfile.c: Include langhooks.h.
13436         (dump_files): Use 0 instead of 3/4/5 for TDI_{original,gimple,nested}.
13437         (FIRST_AUTO_NUMBERED_DUMP): Decrease to 1.
13438         (FIRST_ME_AUTO_NUMBERED_DUMP): Define.
13439         (dump_manager::dump_register): Start with 512 entries instead of 32.
13440         (dump_manager::register_dumps): New method.
13441         * toplev.c (general_init): Instead of invoking register_dumps
13442         langhook, invoke register_dumps method on the dump manager.
13443         * gimplify.c (gimplify_function_tree): Use TDI_gimple instead of
13444         TDI_generic.
13446 2017-06-07  Richard Sandiford  <richard.sandiford@linaro.org>
13448         * doc/md.texi: Clarify the restrictions on a define_insn condition.
13449         Say that # requires an associated define_split to exist, and that
13450         the define_split must be suitable for use after register allocation.
13452 2017-06-06  Jan Hubicka  <hubicka@ucw.cz>
13454         * cfgbuild.c (find_bb_boundaries): Initialize profile of split blocks.
13455         (compute_outgoing_frequencies): Also initialize zero counts.
13456         (find_many_sub_basic_blocks): Do not produce uninitialized profile
13457         around loops; preserve more of profile when nothing changes.
13459 2017-06-06  Jim Wilson  <jim.wilson@linaro.org>
13461         * config/aarch64/aarch64-cost-tables.h (qdf24xx_extra_costs): Move to
13462         here.
13463         * config/arm/aarch-cost-tables.h (qdf24xx_extra_costs): From here.
13464         * config/arm/arm-cpu-cdata.h: Regenerate.
13465         * config/arm/arm-cpu-data.h, config/arm/arm-cpu.h: Likewise.
13466         * config/arm/arm-tables.opt, config/arm/arm-tune.md: Likewise.
13467         * config/arm/arm-cpus.in: Delete falkor and qdf24xx entries.
13468         * config/arm/arm.c (arm_qdf24xx_tune): Delete.
13469         * config/arm/bpabi.h (BE8_LINK_SPEC): Delete falkor and qdf24xx
13470         support.
13471         * config/arm/t-aprofile (MULTILIB_MATCHES): Delete falkor and qdf24xx
13472         support.
13473         * config/arm/t-rmprofile: Likewise.
13474         * doc/invoke.texi (ARM Options): Drop falkor and qdf24xx support.
13476 2017-06-06  David S. Miller  <davem@davemloft.net>
13478         PR target/80968
13479         * config/sparc/sparc.c (sparc_expand_prologue): Emit frame
13480         blockage if function uses alloca.
13482 2017-06-06  Maxim Kuvyrkov  <maxim.kuvyrkov@linaro.org>
13484         * tree-ssa-loop-prefetch.c (struct mem_ref_group, struct mem_ref):
13485         New "uid" fields to hold pretty-print IDs of group and ref.
13486         Memory references are now identified as <group_id>:<ref_id>
13487         instead of using [random] addresses.
13488         (dump_mem_details): Simplify, no functional change.
13489         (dump_mem_ref): Simplify and make output more concise.
13490         Replace couple of fprintf's throughout code with calls to dump_mem_ref.
13491         (find_or_create_group): Initialize group uid.
13492         (record_ref): Initialize ref uid.  Improve debug output.
13493         (prune_group_by_reuse, should_issue_prefetch_p,)
13494         (should_issue_prefetch_p, schedule_prefetches, issue_prefetch_ref,)
13495         (mark_nontemporal_store, determine_loop_nest_reuse):
13496         Improve debug output.
13498 2017-06-06  Maxim Kuvyrkov  <maxim.kuvyrkov@linaro.org>
13500         * dbgcnt.def (prefetch): New debug counter.
13501         * tree-ssa-loop-prefetch.c (dbgcnt.h): New include.
13502         (schedule_prefetches): Stop issueing prefetches if debug counter
13503         tripped.
13505 2017-06-06  Tom de Vries  <tom@codesourcery.com>
13507         * doc/sourcebuild.texi (Testsuites, C Language Testsuites,
13508         gcc.c-torture/compile): Remove mention of NO_LABEL_VALUES in fixme.
13510 2017-06-06  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
13512         * config/aarch64/atomics.md (atomic_compare_and_swap<mode> expander):
13513         Use aarch64_reg_or_zero predicate for operand 4.
13514         (aarch64_compare_and_swap<mode> define_insn_and_split):
13515         Use aarch64_reg_or_zero predicate for operand 3.  Add 'Z' constraint.
13516         (aarch64_store_exclusive<mode>): Likewise for operand 2.
13518 2017-06-06  Thomas Preud'homme  <thomas.preudhomme@arm.com>
13520         * config/arm/arm.c (arm_compute_save_reg_mask): Rename into ...
13521         (arm_compute_save_core_reg_mask): This.
13522         (thumb1_compute_save_reg_mask): Rename into ...
13523         (thumb1_compute_save_core_reg_mask): This.
13524         (arm_compute_save_reg0_reg12_mask): Adapt comment.
13525         (arm_compute_frame_layout): Likewise.
13527 2017-06-06  Richard Biener  <rguenther@suse.de>
13529         PR tree-optimization/80974
13530         * tree-ssa-sccvn.c (set_ssa_val_to): Do not change but only
13531         keep or clear leaders SSA info.
13533 2017-06-06  Tom de Vries  <tom@codesourcery.com>
13535         * config/nvptx/nvptx.c (split_mode_p): New function.
13536         (nvptx_declare_function_name, nvptx_print_operand): Use split_mode_p.
13538 2017-06-06  Tom de Vries  <tom@codesourcery.com>
13540         * config/nvptx/nvptx.c (nvptx_print_operand): Use maybe_split_mode.
13542 2017-06-06  Jan Hubicka  <hubicka@ucw.cz>
13544         PR bootstrap/80978
13545         * tree-cfg.c (execute_fixup_cfg): Fix condition on when to rescale
13546         profile.
13548 2017-06-06  Jan Hubicka  <hubicka@ucw.cz>
13550         * shrink-wrap.c (handle_simple_exit): Update profile.
13551         (try_shrink_wrapping): Upate profile.
13553 2017-06-06  Jan Hubicka  <hubicka@ucw.cz>
13555         * predict.c (tree_estimate_probability_bb): Add LOCAL_ONLY.
13556         (tree_guess_outgoing_edge_probabilities): New.
13557         * predict.h (tree_guess_outgoing_edge_probabilities): Declare.
13558         * tree-cfg.c (gimple_find_sub_bbs): Propagate profile.
13560 2017-06-06  Jan Hubicka  <hubicka@ucw.cz>
13562         * ipa-split.c (split_function): Initialize return bb profile.
13564 2017-06-06  Jan Hubicka  <hubicka@ucw.cz>
13566         * profile.c (compute_branch_probabilities): Also initialize
13567         EXIT_BLOCK profile.
13569 2017-06-06  Richard Biener  <rguenther@suse.de>
13571         PR tree-optimization/80928
13572         * tree-vect-loop.c (vect_update_vf_for_slp): Amend dumps.
13573         (vect_analyze_loop_operations): Properly guard analysis for
13574         pure SLP case.
13575         (vect_transform_loop): Likewise.
13576         (vect_analyze_loop_2): Also reset SLP type on PHIs.
13577         (vect_model_induction_cost): Do not cost for pure SLP.
13578         (vectorizable_induction): Pass in SLP node, implement SLP vectorization
13579         of induction in inner loop vectorization.
13580         * tree-vect-slp.c (vect_create_new_slp_node): Handle PHIs.
13581         (vect_get_and_check_slp_defs): Handle vect_induction_def.
13582         (vect_build_slp_tree): Likewise.  Handle PHIs as terminating the
13583         recursion.
13584         (vect_analyze_slp_cost_1): Cost induction.
13585         (vect_detect_hybrid_slp_stmts): Handle PHIs.
13586         (vect_get_slp_vect_defs): Likewise.
13587         * tree-vect-stmts.c (vect_analyze_stmt): Handle induction.
13588         (vect_transform_stmt): Handle SLP reductions.
13589         * tree-vectorizer.h (vectorizable_induction): Adjust.
13591 2017-06-05  Michael Meissner  <meissner@linux.vnet.ibm.com>
13593         * config/rs6000/rs6000.c (make_resolver_func): Update
13594         init_lowered_empty_function call.
13596 2017-06-05  Bernd Edlinger  <bernd.edlinger@hotmail.de>
13598         * doc/invoke.texi: Document the -fprofile-abs-path option.
13599         * common.opt (fprofile-abs-path): New option.
13600         * gcov-io.h (gcov_write_filename): Declare.
13601         * gcov-io.c (gcov_write_filename): New function.
13602         * coverage.c (coverage_begin_function): Use gcov_write_filename.
13603         * profile.c (output_location): Likewise.
13605 2017-06-05  Jan Hubicka  <hubicka@ucw.cz>
13607         * shring-wrap.c: Revert accidental commit.
13609 2017-06-05  Volker Reichelt  <v.reichelt@netcologne.de>
13611         * doc/invoke.texi (-Wduplicated-branches): Add to warning list.
13613 2017-06-05  Jan Hubicka  <hubicka@ucw.cz>
13615         * cfgexpand.c (expand_gimple_tailcall): Initialize profile of
13616         new edge.
13617         * ipa-inline.c (want_inline_self_recursive_call_p): Watch for missing
13618         profile in callgraph edge.
13619         * profile-count.h (apply_probability): If THIS is 0, then result is 0
13620         (apply_scale): Likewise.
13621         * tree-inline.c (copy_bb, copy_edges_for_bb, copy_cfg_body):
13622         Also scale profile when inlining function with zero profile.
13623         (initialize_cfun): Update exit block profile even when it is zero.
13624         * tree-ssa-threadupdate.c (clear_counts_path): Handle correctly case
13625         when profile is read.
13627 2017-06-05  Michael Meissner  <meissner@linux.vnet.ibm.com>
13629         * config/rs6000/rs6000.c (toplevel): Include attribs.h.
13630         (CLONE_*): New constants to define the processors we can generate
13631         code for with the target_clone attribute.
13632         (rs6000_clone_map): New array to identify which clone processors
13633         the current program is running on.
13634         (TARGET_COMPARE_VERSION_PRIORITY): Define to enable the
13635         target_clone attribute.
13636         (TARGET_GENERATE_VERSION_DISPATCHER_BODY): Likewise.
13637         (TARGET_GET_FUNCTION_VERSIONS_DISPATCHER): Likewise.
13638         (TARGET_OPTION_FUNCTION_VERSIONS): Likewise.
13639         (cpu_expand_builtin): Add support for target_clone attribute.
13640         (rs6000_valid_attribute_p): Allow "default" attribute.
13641         (get_decl_name): New debug function to simplify printing the
13642         current function name in debugging statements.
13643         (rs6000_clone_priority): New functions to support the target_clone
13644         attribute, and be able to generate code to switch between ISA 2.05
13645         through ISA 3.0 (power6 through power9).
13646         (rs6000_compare_version_priority): Likewise.
13647         (rs6000_get_function_versions_dispatcher): Likewise.
13648         (make_resolver_func): Likewise.
13649         (add_condition_to_bb): Likewise.
13650         (dispatch_function_versions): Likewise.
13651         (rs6000_generate_version_dispatcher_body): Likewise.
13652         (rs6000_can_inline_p): Call get_decl_name for debugging usage.
13653         (fusion_gpr_load_p): Fix a spacing issue.
13654         * doc/extend.texi (Common Function Attributes): Document that the
13655         PowerPC supports the target_clone attribute.
13657 2017-06-05  Thomas Preud'homme  <thomas.preudhomme@arm.com>
13659         * config/arm/arm.h: explain F symbol found in description of ARM
13660         register allocation in its legend.
13662 2017-06-05  Jan Hubicka  <hubicka@ucw.cz>
13664         * config/mips/frame-header-opt.c: Include profile-count.h.
13665         * config/riscv/riscv.c: Include profile-count.h
13667 2017-06-05  Jan Hubicka  <hubicka@ucw.cz>
13669         * tree-ssa-loop-im.c (execute_sm_if_changed): Add FLAG_BBS parameter;
13670         update profile.
13671         (sm_set_flag_if_changed): Add bbs field.
13672         (execute_sm_if_changed_flag_set): Pass BBS.
13673         (execute_sm): Update.
13675 2017-06-05  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
13677         * config/aarch64/aarch64-simd.md (aarch64_store_lane0<mode>):
13678         New pattern.
13680 2017-06-05  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
13682         * config/aarch64/aarch64.md (sub<mode>3_compare1_imm): New define_insn.
13683         (peephole2): New peephole2 to emit the above.
13684         * config/aarch64/predicates.md (aarch64_sub_immediate): New predicate.
13686 2017-06-05  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
13688         * config/aarch64/aarch64.c (define_peephole2 above
13689         *sub_<shift>_<mode>): New peephole.
13691 2017-05-23  Jan Hubicka  <hubicka@ucw.cz>
13693         * config/i386/i386.c (make_resolver_func): Update.
13694         * Makefile.in: Add profile-count.h and profile-count.o
13695         * auto-profile.c (afdo_indirect_call): Update to new API.
13696         (afdo_set_bb_count): Update.
13697         (afdo_propagate_edge): Update.
13698         (afdo_propagate_circuit): Update.
13699         (afdo_calculate_branch_prob): Update.
13700         (afdo_annotate_cfg): Update.
13701         * basic-block.h: Include profile-count.h
13702         (struct edge_def): Turn count to profile_count.
13703         (struct basic_block_def): Likewie.
13704         (REG_BR_PROB_BASE): Move to profile-count.h
13705         (RDIV): Move to profile-count.h
13706         * bb-reorder.c (max_entry_count): Turn to profile_count.
13707         (find_traces): Update.
13708         (rotate_loop):Update.
13709         (connect_traces):Update.
13710         (sanitize_hot_paths):Update.
13711         * bt-load.c (migrate_btr_defs): Update.
13712         * cfg.c (RDIV): Remove.
13713         (init_flow): Use alloc_block.
13714         (alloc_block): Uninitialize count.
13715         (unchecked_make_edge): Uninitialize count.
13716         (check_bb_profile): Update.
13717         (dump_edge_info): Update.
13718         (dump_bb_info): Update.
13719         (update_bb_profile_for_threading): Update.
13720         (scale_bbs_frequencies_int): Update.
13721         (scale_bbs_frequencies_gcov_type): Update.
13722         (scale_bbs_frequencies_profile_count): New.
13723         * cfg.h (update_bb_profile_for_threading): Update.
13724         (scale_bbs_frequencies_profile_count): Declare.
13725         * cfgbuild.c (compute_outgoing_frequencies): Update.
13726         (find_many_sub_basic_blocks): Update.
13727         * cfgcleanup.c (try_forward_edges): Update.
13728         (try_crossjump_to_edge): Update.
13729         * cfgexpand.c (expand_gimple_tailcall): Update.
13730         (construct_exit_block): Update.
13731         * cfghooks.c (verify_flow_info): Update.
13732         (dump_bb_for_graph): Update.
13733         (split_edge): Update.
13734         (make_forwarder_block): Update.
13735         (duplicate_block): Update.
13736         (account_profile_record): Update.
13737         * cfgloop.c (find_subloop_latch_edge_by_profile): Update.
13738         (get_estimated_loop_iterations): Update.
13739         * cfgloopanal.c (expected_loop_iterations_unbounded): Update.
13740         (single_likely_exit): Update.
13741         * cfgloopmanip.c (scale_loop_profile): Update.
13742         (loopify): Update.
13743         (set_zero_probability): Update.
13744         (lv_adjust_loop_entry_edge): Update.
13745         * cfgrtl.c (force_nonfallthru_and_redirect): Update.
13746         (purge_dead_edges): Update.
13747         (rtl_account_profile_record): Update.
13748         * cgraph.c (cgraph_node::create): Uninitialize count.
13749         (symbol_table::create_edge): Uninitialize count.
13750         (cgraph_update_edges_for_call_stmt_node): Update.
13751         (cgraph_edge::dump_edge_flags): Update.
13752         (cgraph_node::dump): Update.
13753         (cgraph_edge::maybe_hot_p): Update.
13754         * cgraph.h: Include profile-count.h
13755         (create_clone), create_edge, create_indirect_edge): Update.
13756         (cgraph_node): Turn count to profile_count.
13757         (cgraph_edge0: Likewise.
13758         (make_speculative, clone): Update.
13759         (create_edge): Update.
13760         (init_lowered_empty_function): Update.
13761         * cgraphclones.c (cgraph_edge::clone): Update.
13762         (duplicate_thunk_for_node): Update.
13763         (cgraph_node::create_clone): Update.
13764         * cgraphunit.c (cgraph_node::analyze): Update.
13765         (cgraph_node::expand_thunk): Update.
13766         * final.c (dump_basic_block_info): Update.
13767         * gimple-streamer-in.c (input_bb): Update.
13768         * gimple-streamer-out.c (output_bb): Update.
13769         * graphite.c (print_global_statistics): Update.
13770         (print_graphite_scop_statistics): Update.
13771         * hsa-brig.c: Include basic-block.h.
13772         * hsa-dump.c: Include basic-block.h.
13773         * hsa-gen.c (T sum_slice): Update.
13774         (convert_switch_statements):Update.
13775         * hsa-regalloc.c: Include basic-block.h.
13776         * ipa-chkp.c (chkp_produce_thunks): Update.
13777         * ipa-cp.c (struct caller_statistics): Update.
13778         (init_caller_stats): Update.
13779         (gather_caller_stats): Update.
13780         (ipcp_cloning_candidate_p): Update.
13781         (good_cloning_opportunity_p): Update.
13782         (get_info_about_necessary_edges): Update.
13783         (dump_profile_updates): Update.
13784         (update_profiling_info): Update.
13785         (update_specialized_profile): Update.
13786         (perhaps_add_new_callers): Update.
13787         (decide_about_value): Update.
13788         (ipa_cp_c_finalize): Update.
13789         * ipa-devirt.c (struct odr_type_warn_count): Update.
13790         (struct decl_warn_count): Update.
13791         (struct final_warning_record): Update.
13792         (possible_polymorphic_call_targets): Update.
13793         (ipa_devirt): Update.
13794         * ipa-fnsummary.c (redirect_to_unreachable): Update.
13795         * ipa-icf.c (sem_function::merge): Update.
13796         * ipa-inline-analysis.c (do_estimate_edge_time): Update.
13797         * ipa-inline.c (compute_uninlined_call_time): Update.
13798         (compute_inlined_call_time): Update.
13799         (want_inline_small_function_p): Update.
13800         (want_inline_self_recursive_call_p): Update.
13801         (edge_badness): Update.
13802         (lookup_recursive_calls): Update.
13803         (recursive_inlining): Update.
13804         (inline_small_functions): Update.
13805         (dump_overall_stats): Update.
13806         (dump_inline_stats): Update.
13807         * ipa-profile.c (ipa_profile_generate_summary): Update.
13808         (ipa_propagate_frequency): Update.
13809         (ipa_profile): Update.
13810         * ipa-prop.c (ipa_make_edge_direct_to_target): Update.
13811         * ipa-utils.c (ipa_merge_profiles): Update.
13812         * loop-doloop.c (doloop_modify): Update.
13813         * loop-unroll.c (report_unroll): Update.
13814         (unroll_loop_runtime_iterations): Update.
13815         * lto-cgraph.c (lto_output_edge): Update.
13816         (lto_output_node): Update.
13817         (input_node): Update.
13818         (input_edge): Update.
13819         (merge_profile_summaries): Update.
13820         * lto-streamer-in.c (input_cfg): Update.
13821         * lto-streamer-out.c (output_cfg): Update.
13822         * mcf.c (create_fixup_graph): Update.
13823         (adjust_cfg_counts): Update.
13824         (sum_edge_counts): Update.
13825         * modulo-sched.c (sms_schedule): Update.
13826         * postreload-gcse.c (eliminate_partially_redundant_load): Update.
13827         * predict.c (maybe_hot_count_p): Update.
13828         (probably_never_executed): Update.
13829         (dump_prediction): Update.
13830         (combine_predictions_for_bb): Update.
13831         (propagate_freq): Update.
13832         (handle_missing_profiles): Update.
13833         (counts_to_freqs): Update.
13834         (rebuild_frequencies): Update.
13835         (force_edge_cold): Update.
13836         * predict.h: Include profile-count.h
13837         (maybe_hot_count_p, counts_to_freqs): UPdate.
13838         * print-rtl-function.c: Do not include cfg.h
13839         * print-rtl.c: Include basic-block.h
13840         * profile-count.c: New file.
13841         * profile-count.h: New file.
13842         * profile.c (is_edge_inconsistent): Update.
13843         (correct_negative_edge_counts): Update.
13844         (is_inconsistent): Update.
13845         (set_bb_counts): Update.
13846         (read_profile_edge_counts): Update.
13847         (compute_frequency_overlap): Update.
13848         (compute_branch_probabilities): Update; Initialize and deinitialize
13849         gcov_count tables.
13850         (branch_prob): Update.
13851         * profile.h (bb_gcov_counts, edge_gcov_counts): New.
13852         (edge_gcov_count): New.
13853         (bb_gcov_count): New.
13854         * shrink-wrap.c (try_shrink_wrapping): Update.
13855         * tracer.c (better_p): Update.
13856         * trans-mem.c (expand_transaction): Update.
13857         (ipa_tm_insert_irr_call): Update.
13858         (ipa_tm_insert_gettmclone_call): Update.
13859         * tree-call-cdce.c: Update.
13860         * tree-cfg.c (gimple_duplicate_sese_region): Update.
13861         (gimple_duplicate_sese_tail): Update.
13862         (gimple_account_profile_record): Update.
13863         (execute_fixup_cfg): Update.
13864         * tree-inline.c (copy_bb): Update.
13865         (copy_edges_for_bb): Update.
13866         (initialize_cfun): Update.
13867         (freqs_to_counts): Update.
13868         (copy_cfg_body): Update.
13869         (expand_call_inline): Update.
13870         * tree-ssa-ifcombine.c (update_profile_after_ifcombine): Update.
13871         * tree-ssa-loop-ivcanon.c (unloop_loops): Update.
13872         (try_unroll_loop_completely): Update.
13873         (try_peel_loop): Update.
13874         * tree-ssa-loop-manip.c (tree_transform_and_unroll_loop): Update.
13875         * tree-ssa-loop-niter.c (estimate_numbers_of_iterations_loop): Update.
13876         * tree-ssa-loop-split.c (connect_loops): Update.
13877         * tree-ssa-loop-unswitch.c (hoist_guard): Update.
13878         * tree-ssa-reassoc.c (branch_fixup): Update.
13879         * tree-ssa-tail-merge.c (replace_block_by): Update.
13880         * tree-ssa-threadupdate.c (create_block_for_threading): Update.
13881         (compute_path_counts): Update.
13882         (update_profile): Update.
13883         (recompute_probabilities): Update.
13884         (update_joiner_offpath_counts): Update.
13885         (estimated_freqs_path): Update.
13886         (freqs_to_counts_path): Update.
13887         (clear_counts_path): Update.
13888         (ssa_fix_duplicate_block_edges): Update.
13889         (duplicate_thread_path): Update.
13890         * tree-switch-conversion.c (case_bit_test_cmp): Update.
13891         (struct switch_conv_info): Update.
13892         * tree-tailcall.c (decrease_profile): Update.
13893         * tree-vect-loop-manip.c (slpeel_add_loop_guard): Update.
13894         * tree-vect-loop.c (scale_profile_for_vect_loop): Update.
13895         * value-prof.c (check_counter): Update.
13896         (gimple_divmod_fixed_value): Update.
13897         (gimple_mod_pow2): Update.
13898         (gimple_mod_subtract): Update.
13899         (gimple_ic_transform): Update.
13900         (gimple_stringop_fixed_value): Update.
13901         * value-prof.h (gimple_ic): Update.
13903 2017-06-02  Carl Love  <cel@us.ibm.com>
13905         * config/rs6000/rs6000-c: Add support for built-in functions
13906         vector double vec_doublee (vector signed int);
13907         vector double vec_doublee (vector unsigned int);
13908         vector double vec_doublee (vector float);
13909         vector double vec_doubleh (vector signed int);
13910         vector double vec_doubleh (vector unsigned int);
13911         vector double vec_doubleh (vector float);
13912         vector double vec_doublel (vector signed int);
13913         vector double vec_doublel (vector unsigned int);
13914         vector double vec_doublel (vector float);
13915         vector double vec_doubleo (vector signed int);
13916         vector double vec_doubleo (vector unsigned int);
13917         vector double vec_doubleo (vector float);.
13918         * config/rs6000/rs6000-builtin.def: Add definitions for DOUBLEE,
13919         DOUBLEO, DOUBLEH, DOUBLEL, UNS_DOUBLEO, UNS_DOUBLEE, UNS_DOUBLEH,
13920         UNS_DOUBLEL.
13921         * config/rs6000/altivec.md: Add code generator for doublee<mode>2,
13922         unsdoubleev4si2, doubleo<mode>2, unsdoubleov4si2, doubleh<mode>2,
13923         unsdoublehv4si2, doublel<mode>2, unsdoublelv4si2, add mode attribute
13924         VS_sxwsp.
13925         * config/rs6000/altivec.h: Add define for vec_doublee, vec_doubleo,
13926         vec_doublel, vec_doubleh.
13927         * doc/extend.texi: Update the built-in documentation file for the
13928         new built-in functions.
13930 2017-06-02  David Malcolm  <dmalcolm@redhat.com>
13932         PR jit/80954
13933         * ipa-inline-analysis.c (free_growth_caches): Set
13934         edge_removal_hook_holder to NULL after removing it.
13936 2017-06-02  Sudakshina Das  <sudi.das@arm.com>
13938         * config/aarch64/aarch64.c (aarch64_select_cc_mode): Return CC_SWP for
13939         comparision with zero.
13941 2017-06-02  Will Schmidt  <will_schmidt@vnet.ibm.com>
13942         * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Add handling
13943         for early expansion of vec_min and vec_max builtins.
13944         (builtin_function_type): Add min/max unsigned variants to those
13945         identified as having unsigned arguments.
13947 2017-06-02  Olivier Hainque  <hainque@adacore.com>
13949         * config/vx-common.h (DWARF_UNWIND_INFO): Switch #define to 1.
13951 2017-06-02  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
13953         * config/aarch64/aarch64-simd.md (*aarch64_simd_vec_copy_lane<mode>):
13954         Use VALL_F16 iterator rather than VALL.
13956 2017-06-02  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
13958         * config/aarch64/aarch64.c (aarch64_split_compare_and_swap):
13959         Emit CBNZ inside loop when doing a strong exchange and comparing
13960         against zero.  Generate the CC flags after the loop.
13962 2017-06-02  David Edelsohn  <dje.gcc@gmail.com>
13964         * dwarf2out.c (DWARF_INITIAL_LENGTH_SIZE_STR): New.
13965         (dl_section_ref): New.
13966         (dwarf2out_finish): Copy debug_line_section_label to dl_section_ref.
13967         On AIX, append an expression to subtract the size of the
13968         section length to dl_section_ref.
13970 2017-06-02  Will Schmidt  <will_schmidt@vnet.ibm.com>
13972         * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Add handling
13973         for early expansion of vector absolute builtins.
13975 2017-06-02  Richard Biener  <rguenther@suse.de>
13977         * tree-vect-slp.c (vect_detect_hybrid_slp_2): Match up
13978         what we consider a relevant use stmt with vect_detect_hybrid_slp_stmts.
13980 2017-06-02  Richard Biener  <rguenther@suse.de>
13982         PR tree-optimization/80948
13983         * tree-tailcall.c (find_tail_calls): Track stmts to move in
13984         stmt order as well.
13986 2017-06-02  Richard Biener  <rguenther@suse.de>
13988         * tree-vect-loop.c (vect_analyze_loop_operations): Not relevant
13989         PHIs are ok.
13990         * tree-vect-stmts.c (process_use): Do not mark backedge defs
13991         for inductions as relevant.
13993 2017-06-02  Richard Biener  <rguenther@suse.de>
13995         * tree-vect-loop.c (get_initial_def_for_induction): Inline into ...
13996         (vectorizable_induction): ... this.  Remove dead code.
13998 2017-06-02  Eric Botcazou  <ebotcazou@adacore.com>
14000         * builtins. (expand_builtin_alloca): Remove second parameter and
14001         infer its value from the first parameter instead.
14002         (expand_builtin) <BUILT_IN_ALLOCA>: Adjust call to above.
14004 2017-06-02  Jakub Jelinek  <jakub@redhat.com>
14006         PR rtl-optimization/80903
14007         * loop-doloop.c (add_test): Unshare sequence.
14009 2017-06-02  Bernd Edlinger  <bernd.edlinger@hotmail.de>
14011         * doc/invoke.texi: Document the -Wsizeof-pointer-div warning.
14013 2017-06-01  Bernd Edlinger  <bernd.edlinger@hotmail.de>
14015         * config/i386/i386.c (x86_64_ms_sysv_extra_clobbered_registers): Make
14016         static.
14017         (xlogue_layout::get_stack_space_used, xlogue_layout::s_instances,
14018         xlogue_layout::get_instance, logue_layout::xlogue_layout,
14019         sp_valid_at, fp_valid_at, choose_basereg): Formatting.
14020         (xlogue_layout::get_stub_rtx): Make static.
14021         (xlogue_layout::get_stub_name): Avoid const-cast, make static.
14022         (xlogue_layout::compute_stub_managed_regs): Rename to...
14023         (xlogue_layout::count_stub_managed_regs): ...this.
14024         (xlogue_layout::is_stub_managed_reg): New function.
14025         (xlogue_layout::m_stub_names): Rename to...
14026         (xlogue_layout::s_stub_names): ...this, make static.
14027         (xlogue_layout::STUB_INDEX_OFFSET, xlogue_layout::MIN_REGS,
14028         xlogue_layout::MAX_REGS, xlogue_layout::MAX_EXTRA_REGS,
14029         xlogue_layout::VARIANT_COUNT, xlogue_layout::STUB_NAME_MAX_LEN,
14030         xlogue_layout::s_stub_names): Instantiate statics.
14031         (stub_managed_regs): Remove.
14032         (ix86_save_reg): Use xlogue_layout::compute_stub_managed_regs.
14033         (disable_call_ms2sysv_xlogues): Rename to...
14034         (warn_once_call_ms2sysv_xlogues): ...this, and warn only once.
14035         (ix86_initial_elimination_offset, ix86_expand_call): Fix call_ms2sysv
14036         warning logic.
14037         (ix86_static_chain): Make sure that ix86_static_chain_on_stack can't
14038         change after reload_completed.
14039         (ix86_can_use_return_insn_p): Use the ix86_frame data structure
14040         directly.
14041         (ix86_expand_prologue): Likewise.
14042         (ix86_expand_epilogue): Likewise.
14043         (ix86_expand_split_stack_prologue): Likewise.
14044         (ix86_compute_frame_layout): Remove frame parameter ...
14045         (TARGET_COMPUTE_FRAME_LAYOUT): ... and export it as a target hook.
14046         (ix86_finalize_stack_realign_flags): Call ix86_compute_frame_layout
14047         only if necessary.
14048         (ix86_init_machine_status): Don't set use_fast_prologue_epilogue_nregs.
14049         (ix86_frame): Move from here ...
14050         * config/i386/i386.h (ix86_frame): ... to here.
14051         (machine_function): Remove use_fast_prologue_epilogue_nregs, cache the
14052         complete ix86_frame data structure instead.  Remove some_ld_name.
14054 2017-06-01  Pierre-Marie de Rodat  <derodat@adacore.com>
14056         * dwarf2out.c (dwarf2out_late_global_decl): Add locations for
14057         symbols that hold a DECL_VALUE_EXPR.
14059 2017-06-01  Martin Jambor  <mjambor@suse.cz>
14061         PR tree-optimization/80898
14062         * tree-sra.c (process_subtree_disqualification): Removed.
14063         (disqualify_candidate): Do not acll
14064         process_subtree_disqualification.
14065         (subtree_mark_written_and_enqueue): New function.
14066         (propagate_all_subaccesses): Set grp_write of LHS subtree if the
14067         RHS has been disqualified and re-queue LHS if necessary.  Apart
14068         from that, ignore disqualified RHS.
14070 2017-06-01  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
14072         * config/s390/s390.c (s390_emit_epilogue): Disable early return
14073         address fetch for z10 or later.
14075 2017-06-01  Claudiu Zissulescu  <claziss@synopsys.com>
14077         * config/arc/arc.md (tst_movb): Add guard when splitting.
14079 2017-06-01  Claudiu Zissulescu  <claziss@synopsys.com>
14081         * config/arc/arc.c (arc_can_eliminate): Test against
14082         arc_frame_pointer_needed.
14084 2017-06-01  Claudiu Zissulescu  <claziss@synopsys.com>
14086         * config/arc/arc.c (arc_expand_prologue): Emit a special barrier
14087         to prevent store reordering.
14088         * config/arc/arc.md (UNSPEC_ARC_STKTIE): Define.
14089         (type): Add block type.
14090         (stack_tie): Define special instruction to be used in
14091         expand_prologue.
14093 2017-06-01  Claudiu Zissulescu  <claziss@synopsys.com>
14095         * config/arc/arc.md (commutative_binary_comparison): Remove 'I'
14096         constraint. It is not valid for the pattern.
14097         (noncommutative_binary_comparison): Likewise.
14099 2017-06-01  Claudiu Zissulescu  <claziss@synopsys.com>
14101         * config/arc/simdext.md (movv2hi_insn): Change predicate to avoid
14102         scaled addresses.
14104 2017-06-01  Claudiu Zissulescu  <claziss@synopsys.com>
14106         * config/arc/arc.c (arc_conditional_register_usage): Allow r30 to
14107         be used by the reg-alloc.
14109 2017-06-01  Claudiu Zissulescu  <claziss@synopsys.com>
14111         * config/arc/arc.md (mulsi3): Avoid use of hard registers before
14112         reg-alloc when having mul64 or mul32x16 instructions.
14113         (mulsidi3): Likewise.
14114         (umulsidi3): Likewise.
14115         (mulsi32x16): New pattern.
14116         (mulsi64): Likewise.
14117         (mulsidi64): Likewise.
14118         (umulsidi64): Likewise.
14119         (MUL32x16_REG): Define.
14120         (mul64_600): Use MUL32x16_REG.
14121         (mac64_600): Likewise.
14122         (umul64_600): Likewise.
14123         (umac64_600): Likewise.
14125 2017-06-01  Claudiu Zissulescu  <claziss@synopsys.com>
14127         * config/arc/arc.md (mulsi3_700): Make it commutative.
14129 2017-06-01  Jose E. Marchesi  <jose.marchesi@oracle.com>
14131         * config/sparc/sparc.md (*zero_extendsidi2_insn_sp64): Set insn
14132         type for movstouw.
14133         (*sign_extendsidi2_insn): Likewise for movstosw.
14135 2017-06-01  Pierre-Marie de Rodat  <derodat@adacore.com>
14137         * dwarf2out.c (get_discr_value): Call the get_debug_type hook on
14138         the type of the input discriminant value.  Convert the
14139         discriminant value of signedness vary.
14141 2017-06-01  Volker Reichelt  <v.reichelt@netcologne.de>
14143         * doc/invoke.texi (-Wcatch-value): Document new shortcut.
14144         Add to -Wall section.
14146 2017-06-01  Richard Biener  <rguenther@suse.de>
14148         PR middle-end/66313
14149         * fold-const.c (fold_plusminus_mult_expr): If the factored
14150         factor may be zero use a wrapping type for the inner operation.
14151         * tree-tailcall.c (independent_of_stmt_p): Pass in to_move bitmap
14152         and handle moved defs.
14153         (process_assignment): Properly guard the unary op case.  Return a
14154         tri-state indicating that moving the stmt before the call may allow
14155         to continue.  Pass through to_move.
14156         (find_tail_calls): Handle moving unrelated defs before
14157         the call.
14159 2017-05-31  Segher Boessenkool  <segher@kernel.crashing.org>
14161         PR target/80618
14162         * config/rs6000/vector.md (*vector_uneq<mode>): Write the nor in the
14163         splitter result in the canonical way.
14165 2017-05-31  Uros Bizjak  <ubizjak@gmail.com>
14167         * config/i386/i386.md (*zero_extendsidi2): Enable alternative (?r, *Yj)
14168         also for 32bit target.  Update insn attributes.
14169         (zero-extendsidi2 splitter): Allow all registers for operand 1.
14171 2017-05-31  Sebastian Peryt  <sebastian.peryt@intel.com>
14173         * config/i386/avx512fintrin.h (_mm_mask_max_sd)
14174         (_mm_maskz_max_sd, _mm_mask_max_ss, _mm_maskz_max_ss)
14175         (_mm_mask_min_sd, _mm_maskz_min_sd, _mm_mask_min_ss)
14176         (_mm_maskz_min_ss): New intrinsics.
14178 2017-05-31  Martin Liska  <mliska@suse.cz>
14180         * tree-vect-loop.c (vect_create_epilog_for_reduction):
14181         Change comment style to one we normally use.
14182         (vectorizable_reduction): Likewise.
14183         (vectorizable_induction): Likewise.
14184         * tree-vect-stmts.c (vectorizable_mask_load_store): Likewise.
14185         (vectorizable_call): Likewise.
14186         (vectorizable_simd_clone_call): Likewise.
14187         (vectorizable_conversion): Likewise.
14188         (vectorizable_assignment): Likewise.
14189         (vectorizable_shift): Likewise.
14190         (vectorizable_operation): Likewise.
14191         (vectorizable_store): Likewise.
14192         (vectorizable_load): Likewise.
14193         * tree-vectorizer.h: Likewise.
14195 2017-05-31  Alexander Monakov  <amonakov@ispras.ru>
14197         * passes.c (emergency_dump_function): New.
14198         * tree-pass.h (emergency_dump_function): Declare.
14199         * plugin.c (plugins_internal_error_function): Remove.
14200         * plugin.h (plugins_internal_error_function): Remove declaration.
14201         * toplev.c (internal_error_function): New static function.  Use it...
14202         (general_init): ...here.
14204 2017-05-31  Graham Markall  <graham.markall@embecosm.com>
14206         * config/arc/arc.c (arc_print_operand): Handle constant operands.
14207         (arc_rtx_costs): Add costs for new patterns.
14208         * config/arc/arc.md: Additional *add_n and *sub_n patterns.
14209         * config/arc/predicates.md: Add _1_2_3_operand predicate.
14211 2017-05-31  Richard Sandiford  <richard.sandiford@linaro.org>
14213         * tree-ssa-strlen.c (get_next_strinfo): New function.
14214         (get_stridx_plus_constant): Use it.
14215         (zero_length_string): Likewise.
14216         (adjust_related_strinfos): Likewise.
14217         (adjust_last_stmt): Likewise.
14219 2017-05-31  Richard Biener  <rguenther@suse.de>
14221         PR target/80880
14222         * config/i386/i386.c (ix86_expand_builtin): Remove assert
14223         for arg being an SSA name when expanding IX86_BUILTIN_BNDRET.
14225 2017-05-31  Richard Sandiford  <richard.sandiford@linaro.org>
14227         * tree-vect-data-refs.c (vect_find_same_alignment_drs): Remove
14228         loop_vinfo argument and use of dependence distance vectors.
14229         Check instead whether the two references differ only in their
14230         initial value and assume that they have the same alignment if the
14231         difference is a multiple of the vector alignment.
14232         (vect_analyze_data_refs_alignment): Update call accordingly.
14234 2017-05-31  Martin Liska  <mliska@suse.cz>
14236         PR target/79155
14237         * config/i386/cpuid.h: Fix typo in a comment in cpuid.h.
14239 2017-05-31  Bin Cheng  <bin.cheng@arm.com>
14241         * tree-vect-loop-manip.c (create_intersect_range_checks_index)
14242         (create_intersect_range_checks): Move from ...
14243         * tree-data-ref.c (create_intersect_range_checks_index)
14244         (create_intersect_range_checks): ... to here.
14245         (create_runtime_alias_checks): New function factored from ...
14246         * tree-vect-loop-manip.c (vect_create_cond_for_alias_checks): ...
14247         here.  Call above function.
14248         * tree-data-ref.h (create_runtime_alias_checks): New function.
14250 2017-05-31  Bin Cheng  <bin.cheng@arm.com>
14252         * tree-data-ref.c (prune_runtime_alias_test_list): Relax minimal
14253         segment length for dr_b and compute it in wide_int.
14255 2017-05-31  Richard Biener  <rguenther@suse.de>
14257         PR tree-optimization/80906
14258         * graphite-isl-ast-to-gimple.c (copy_loop_close_phi_nodes): Get
14259         and pass through iv_map.
14260         (copy_bb_and_scalar_dependences): Adjust.
14261         (translate_pending_phi_nodes): Likewise.
14262         (copy_loop_close_phi_args): Handle code-generating IVs instead
14263         of ICEing.
14265 2017-05-30  David Malcolm  <dmalcolm@redhat.com>
14267         * diagnostic-color.c (color_dict): Add "type-diff".
14268         (parse_gcc_colors): Update comment.
14269         * doc/invoke.texi (Diagnostic Message Formatting Options): Add
14270         -fdiagnostics-show-template-tree and -fno-elide-type.
14271         (GCC_COLORS): Add type-diff to example.
14272         (type-diff=): New.
14273         (-fdiagnostics-show-template-tree): New.
14274         (-fno-elide-type): New.
14275         * pretty-print.c (pp_format): Pass quote and formatters[argno] to
14276         the pp_format_decoder callback.  Call any m_format_postprocessor's
14277         "handle" method.
14278         (pretty_printer::pretty_printer): Initialize
14279         m_format_postprocessor.
14280         (pretty_printer::~pretty_printer): Delete any
14281         m_format_postprocessor.
14282         * pretty-print.h (printer_fn): Add bool and const char ** parameters.
14283         (class format_postprocessor): New class.
14284         (struct pretty_printer::format_decoder): Document the new parameters.
14285         (struct pretty_printer::m_format_postprocessor): New field.
14286         * tree-diagnostic.c (default_tree_printer): Update for new
14287         bool and const char ** params.
14288         * tree-diagnostic.h (default_tree_printer): Likewise.
14290 2017-05-30  Segher Boessenkool  <segher@kernel.crashing.org>
14292         * config/rs6000/predicates.md (cc_reg_not_micro_cr0_operand): Delete.
14293         (lwa_operand): Delete rs6000_gen_cell_microcode test.
14294         * config/rs6000/rs6000.c (rs6000_option_override_internal): Delete
14295         rs6000_gen_cell_microcode code.
14296         (rs6000_final_prescan_insn): Delete.
14297         (rs6000_opt_vars): Delete the "gen-cell-microcode" and
14298         "warn-cell-microcode" entries.
14299         * config/rs6000/rs6000.h (FINAL_PRESCAN_INSN): Delete.
14300         * config/rs6000/rs6000.md: Delete rs6000_gen_cell_microcode tests
14301         throughout.  Change cc_reg_not_micro_cr0_operand to
14302         cc_reg_not_cr0_operand throughout.
14303         (*extendhi<mode>2_noload): Delete.
14304         * config/rs6000/rs6000.opt (mgen-cell-microcode): Replace by stub.
14305         (mwarn-cell-microcode): Delete.
14306         * doc/invoke.texi (RS/6000 and PowerPC Options): Delete
14307         -mgen-cell-microcode and -mwarn-cell-microcode.
14309 2017-05-30  Uros Bizjak  <ubizjak@gmail.com>
14311         PR target/80833
14312         * config/i386/constraints.md (Yd): New constraint.
14313         (Ye): Ditto.
14314         * config/i386/i386.md (*movti_internal): Add (?r, Ye)
14315         and (?Yd, r) alternatives.  Update insn attributes.
14316         * config/i386/i386.md (*movti_internal): Add (?r, *Ye)
14317         and (?*Yd, r) alternatives.  Update insn attributes.
14318         (double-mode inter-unit splitters): Add new GR<->XMM splitters.
14320 2017-05-30  Pierre-Marie de Rodat  <derodat@adacore.com>
14322         * gimplify.c (gimplify_modify_expr): Don't create a
14323         DECL_DEBUG_EXPR link if *FROM_P does not belong to the current
14324         function.
14326 2017-05-30  Wilco Dijkstra  <wdijkstr@arm.com>
14328         * config/arm/arm-builtins.c (arm_expand_builtin): Remove const.
14330 2017-05-30  Richard Biener  <rguenther@suse.de>
14332         * tree-vectorizer.h (struct _stmt_vec_info): Add reduc_type
14333         and reduc_def fields.
14334         (STMT_VINFO_REDUC_TYPE): New define.
14335         (STMT_VINFO_REDUC_DEF): Likewise.
14336         (vect_force_simple_reduction): Adjust prototype.
14337         * tree-vect-loop.c (vect_analyze_scalar_cycles_1): Adjust.
14338         (vect_is_simple_reduction): Remove check_reduction argument.
14339         (vect_force_simple_reduction): Adjust and set
14340         STMT_VINFO_REDUC_TYPE and STMT_VINFO_REDUC_DEF.
14341         (vectorizable_reduction): Do not re-do reduction analysis
14342         but use STMT_VINFO_REDUC_TYPE and STMT_VINFO_REDUC_DEF.
14343         * tree-parloops.c (gather_scalar_reductions): Adjust.
14345 2017-05-30  Richard Biener  <rguenther@suse.de>
14347         PR middle-end/80901
14348         * cfgexpand.c (expand_gimple_cond): Match up loop fixup with
14349         split_edge code.
14351 2017-05-24  Robin Dapp  <rdapp@linux.vnet.ibm.com>
14353         * tree-vect-data-refs.c (vect_get_peeling_costs_all_drs):
14354         Introduce unknown_misalignment parameter and remove vf.
14355         (vect_peeling_hash_get_lowest_cost):
14356         Pass unknown_misalignment parameter.
14357         (vect_enhance_data_refs_alignment):
14358         Fix unsupportable data ref treatment.
14360 2017-05-30  Robin Dapp  <rdapp@linux.vnet.ibm.com>
14362         * tree-vect-data-refs.c (vect_get_data_access_cost):
14363         Workaround for SLP handling.
14364         (vect_enhance_data_refs_alignment):
14365         Compute costs for doing no peeling at all, compare to the best
14366         peeling costs so far and avoid peeling if cheaper.
14368 2017-05-30  Robin Dapp  <rdapp@linux.vnet.ibm.com>
14370         * tree-vect-data-refs.c (vect_peeling_hash_choose_best_peeling):
14371         Return peeling info and set costs to zero for unlimited cost
14372         model.
14373         (vect_enhance_data_refs_alignment): Also inspect all datarefs
14374         with unknown misalignment. Compute and costs for unknown
14375         misalignment, compare them to the costs for known misalignment
14376         and choose the cheapest for peeling.
14378 2017-05-30  Robin Dapp  <rdapp@linux.vnet.ibm.com>
14380         * tree-vect-data-refs.c (vect_update_misalignment_for_peel): Rename.
14381         (vect_get_peeling_costs_all_drs): Create function.
14382         (vect_peeling_hash_get_lowest_cost):
14383         Use vect_get_peeling_costs_all_drs.
14384         (vect_peeling_supportable): Create function.
14385         (vect_enhance_data_refs_alignment): Use vect_peeling_supportable.
14387 2017-05-30  Robin Dapp  <rdapp@linux.vnet.ibm.com>
14389         * tree-vect-data-refs.c (vect_compute_data_ref_alignment): Create
14390         DR_HAS_NEGATIVE_STEP.
14391         (vect_update_misalignment_for_peel): Define DR_MISALIGNMENT.
14392         (vect_enhance_data_refs_alignment): Use.
14393         (vect_duplicate_ssa_name_ptr_info): Use.
14394         * tree-vectorizer.h (dr_misalignment): Use.
14395         (known_alignment_for_access_p): Use.
14397 2017-05-30  Jozef Lawrynowicz  <jozef.l@somniumtech.com>
14399         PR target/78838
14400         * config/msp430/msp430.c (gen_prefix): Return NULL when section name is
14401         .lowtext.
14402         (has_section_name): New function.
14404 2017-05-30  Martin Liska  <mliska@suse.cz>
14406         PR other/80909
14407         * auto-profile.c (get_function_decl_from_block): Fix
14408         parenthesis.
14410 2017-05-30  Richard Biener  <rguenther@suse.de>
14412         PR middle-end/80876
14413         * cfgexpand.c (expand_gimple_cond): Fixup preserving loops again.
14415 2017-05-30  Martin Liska  <mliska@suse.cz>
14417         * dumpfile.c: Use newly added macro DUMP_FILE_INFO.
14418         * dumpfile.h (struct dump_file_info): Remove ctors.
14420 2017-05-30  Martin Liska  <mliska@suse.cz>
14422         * predict.def: Fix GNU coding style.
14424 2017-05-29  Max Filippov  <jcmvbkbc@gmail.com>
14426         * config/xtensa/xtensa.c (xtensa_initial_elimination_offset):
14427         Mark 'to' argument with ATTRIBUTE_UNUSED.
14429 2017-05-29  Max Filippov  <jcmvbkbc@gmail.com>
14431         * config/xtensa/xtensa.c (xtensa_emit_call): Use
14432         HOST_WIDE_INT_PRINT_HEX instead of 0x%lx format string.
14433         (print_operand): Use HOST_WIDE_INT_PRINT_DEC instead of %ld
14434         format string.
14436 2017-05-29  Eric Botcazou  <ebotcazou@adacore.com>
14438         * doc/install.texi (Options specification): Restore entry of
14439         --enable-sjlj-exceptions.
14441 2017-05-27  Michael Eager  <eager@eagercon.com>
14443         Revert:
14444         2016-01-21  Ajit Agarwal  <ajitkum@xilinx.com>
14446         See https://gcc.gnu.org/ml/gcc/2017-05/msg00221.html.
14448         * config/microblaze/microblaze.h
14449         (FIXED_REGISTERS): Update in macro.
14450         (CALL_USED_REGISTERS): Update in macro.
14452 2017-05-27  François-Xavier Coudett  <fxcoudert@gcc.gnu.org>
14454         * doc/install.texi: Add links to macOS binary distributions.
14456 2017-05-27  Jakub Jelinek  <jakub@redhat.com>
14458         PR bootstrap/80887
14459         Revert:
14460         2017-05-25  Marc Glisse  <marc.glisse@inria.fr>
14462         * match.pd ((A +- CST1) +- CST2): Allow some conversions.
14464 2017-05-26  Martin Liska  <mliska@suse.cz>
14466         * dumpfile.h (enum dump_kind): Renumber TDF_* flags to be contiguous.
14468 2017-05-26  Martin Liska  <mliska@suse.cz>
14470         * cfg.c (check_bb_profile): Do not use TDF_COMMENT and print
14471         always leading ';; '.
14472         (dump_bb_info): Likewise.
14473         (brief_dump_cfg): Likewise.
14474         * cfgrtl.c (print_rtl_with_bb): Do not use TDF_COMMENT.
14475         * dumpfile.c: Remove usage of TDF_VERBOSE.
14476         * dumpfile.h (enum dump_kind): Likewise.
14477         (dump_gimple_bb_header): Do not use TDF_COMMENT.
14478         * print-tree.c (debug_verbose): Remove.
14479         * tree-cfg.c (gimple_dump_cfg): Do not use TDF_COMMENT.
14480         (dump_function_to_file): Remove dumps guarded with TDF_VERBOSE.
14481         * tree-diagnostic.c (default_tree_printer): Replace
14482         TDF_DIAGNOSTIC with TDF_SLIM.
14484 2017-05-26  Bin Cheng  <bin.cheng@arm.com>
14486         * tree-vect-loop-manip.c (create_intersect_range_checks_index): Pass
14487         in parameter loop, rather than loop_vinfo.
14488         (create_intersect_range_checks): Ditto.
14489         (vect_create_cond_for_alias_checks): Update call to above functions.
14491 2017-05-26  Bin Cheng  <bin.cheng@arm.com>
14493         PR tree-optimization/80815
14494         * tree-data-ref.c (prune_runtime_alias_test_list): Simplify condition
14495         for merging runtime alias checks.  Handle negative DR_STEPs.
14497 2017-05-26  Bin Cheng  <bin.cheng@arm.com>
14499         * tree-vect-data-refs.c (Operator==, comp_dr_with_seg_len_pair):
14500         Move from ...
14501         * tree-data-ref.c (Operator==, comp_dr_with_seg_len_pair): To here.
14502         * tree-vect-data-refs.c (vect_prune_runtime_alias_test_list): Factor
14503         out code pruning runtime alias checks.
14504         * tree-data-ref.c (prune_runtime_alias_test_list): New function
14505         factored out from above.
14506         * tree-vectorizer.h (struct dr_with_seg_len, dr_with_seg_len_pair_t):
14507         Move from ...
14508         * tree-data-ref.h (struct dr_with_seg_len, dr_with_seg_len_pair_t):
14509         ... to here.
14510         (prune_runtime_alias_test_list): New decalaration.
14512 2017-05-26  Bin Cheng  <bin.cheng@arm.com>
14514         * tree-vect-data-refs.c (compare_tree): Rename and move ...
14515         * tree-data-ref.c (data_ref_compare_tree): ... to here.
14516         * tree-data-ref.h (data_ref_compare_tree): New decalaration.
14517         * tree-vect-data-refs.c (dr_group_sort_cmp): Update uses.
14518         (operator==, comp_dr_with_seg_len_pair): Ditto.
14519         (vect_prune_runtime_alias_test_list): Ditto.
14521 2017-05-26  Martin Liska  <mliska@suse.cz>
14523         PR ipa/80663
14524         * params.def: Bound partial-inlining-entry-probability param.
14526 2017-05-26  Marek Polacek  <polacek@redhat.com>
14528         PR sanitizer/80875
14529         * fold-const.c (fold_binary_loc) <case MULT_EXPR>: Check if OP1
14530         can be negated.
14532 2017-05-26  Richard Biener  <rguenther@suse.de>
14534         PR tree-optimization/80842
14535         * tree-ssa-ccp.c (set_lattice_value): Always meet with the old
14536         value.
14538 2017-05-26  Richard Biener  <rguenther@suse.de>
14540         PR tree-optimization/80844
14541         * tree-vectorizer.c (adjust_simduid_builtins): Propagate results.
14543 2017-05-25  Sebastian Peryt  <sebastian.peryt@intel.com>
14545         * doc/md.texi (Machine Constraints): Update x86 family
14546         machine constraints section to match 'config/i386/constraints.md'.
14548 2017-05-25  Volker Reichelt  <v.reichelt@netcologne.de>
14550         * doc/invoke.texi (-Wcatch-value=): Document new warning option.
14552 2017-05-25  Nathan Sidwell  <nathan@acm.org>
14554         * doc/invoke.texi (--enable-languages): Update documentation.
14556 2017-05-25  Martin Liska  <mliska@suse.cz>
14558         * dumpfile.c: Add TDF_FOLDING.
14559         * dumpfile.h (enum dump_kind): Likewise.
14560         * genmatch.c (dt_simplify::gen_1): Use it.
14562 2017-05-25  Marc Glisse  <marc.glisse@inria.fr>
14564         * match.pd (view_convert (convert@0 @1)): Handle zero-extension.
14566 2017-05-25  Marc Glisse  <marc.glisse@inria.fr>
14568         * match.pd ((A +- CST1) +- CST2): Allow some conversions.
14569         * tree.c (drop_tree_overflow): Handle COMPLEX_CST and VECTOR_CST.
14571 2017-05-25  Marc Glisse  <marc.glisse@inria.fr>
14573         * fold-const.c (fold_binary_loc) [(A & C) == D]: Remove transformation.
14574         * match.pd (X == C): Rewrite it here.
14575         (with_possible_nonzero_bits, with_possible_nonzero_bits2,
14576         with_certain_nonzero_bits2): New predicates.
14577         * tree-ssanames.c (get_nonzero_bits): Handle INTEGER_CST.
14579 2017-05-24  Nathan Sidwell  <nathan@acm.org>
14581         * lto-streamer-in.c (lto_input_data_block): Adjust T const cast to
14582         avoid warning.
14584         * auto-profile.c (afdo_propagate): Adjust T const cast to avoid
14585         warning.
14587 2017-05-24  Segher Boessenkool  <segher@kernel.crashing.org>
14589         * config/powerpcspe: New port.  Files are copied from the rs6000
14590         port, with "rs6000" in filenames replaced by "powerpcspe".
14592 2017-05-24  Wilco Dijkstra  <wdijkstr@arm.com>
14594         PR rtl-optimization/80754
14595         * lra-remat.c (do_remat): Add overlap checks for dst_regno.
14597 2017-05-24  Sheldon Lobo  <smlobo@sheldon.us.oracle.com>
14599         * config/sparc/sparc.md (length): Return the correct value for -mflat
14600         sibcalls to match output_sibcall.
14602 2017-05-24  Segher Boessenkool  <segher@kernel.crashing.org>
14604         PR bootstrap/80860
14605         PR bootstrap/80843
14606         * config/rs6000/rs6000.c (struct machine_function): Add new field
14607         n_components.
14608         (rs6000_get_separate_components): Init that field, use it.
14609         (rs6000_components_for_bb): Use the field.
14611 2017-05-24  Thomas Preud'homme  <thomas.preudhomme@arm.com>
14613         * config/arm/arm.c (arm_expand_prologue): Fix typo in comment.
14615 2017-05-24  Peter Bergner  <bergner@vnet.ibm.com>
14617         PR middle-end/80823
14618         * tree-cfg.c (group_case_labels_stmt): Delete increment of "i";
14620 2017-05-24  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
14622         PR target/80725
14623         * config/s390/s390.c (s390_check_qrst_address): Check incoming
14624         address against address_operand predicate.
14625         * config/s390/s390.md ("*indirect_jump"): Swap alternatives.
14627 2017-05-24  Eric Botcazou  <ebotcazou@adacore.com>
14629         * var-tracking.c (track_expr_p): Do not return 0 for tracked record
14630         parameters passed indirectly.
14632 2017-05-23  Uros Bizjak  <ubizjak@gmail.com>
14634         * config/i386/i386.md (*movdi_internal): Remove SSE4
14635         alternative 18 (?r, *v).  Update insn attributes.
14636         (*movsi_internal): Remove SSE4 alternative 13 (?r, *v).
14637         Update insn attributes.
14638         (*zero_extendsidi2): Remove SSE4 alternative (?r, *x).
14639         Update insn attributes.
14640         * config/i386/sse.md (vec_extract<ssevecmodelower>_0): Remove SSE4
14641         alternative 1 (r, v). Remove isa attribute.
14642         * config/i386/i386.c (dimode_scalar_chain::make_vector_copies):
14643         Always move value through stack for !TARGET_INTER_UNIT_MOVES_TO_VEC
14644         and !TARGET_INTER_UNIT_MOVES_TO_VEC targets.
14646 2017-05-23  Tom de Vries  <tom@codesourcery.com>
14648         * doc/sourcebuild.texi (Directives, Verify compiler message): Document
14649         dg-line directive.
14651 2017-05-23  Jan Hubicka  <hubicka@ucw.cz>
14653         * cgraphunit.c (symbol_table::process_new_functions): Update.
14654         * ipa-fnsummary.c (pass_data_inline_parameters): Remove.
14655         (inline_generate_summary): Rename to ...
14656         (ipa_fn_summary_generate): ... this one.
14657         (inline_read_summary): Rename to ...
14658         (ipa_fn_summary_read): ... this one.
14659         (inline_write_summary): Rename to ...
14660         (ipa_fn_summary_write): ... this one.
14661         (inline_free_summary): Rename to ...
14662         (ipa_free_fn_summary): ... this one.
14663         (pass_data_local_fn_summary, pass_local_fn_summary,
14664         make_pass_local_fn_summary, pass_data_ipa_free_fn_summary,
14665         pass_ipa_free_fn_summary, make_pass_ipa_free_fn_summary,
14666         pass_data_ipa_fn_summary, pass_ipa_fn_summary,
14667         make_pass_ipa_fn_summary): New.
14668         * ipa-fnsummary.h (inline_generate_summary, inline_read_summary,
14669         inline_write_summary, inline_free_summary): Remove.
14670         (ipa_free_fn_summary) : New.
14671         * ipa-inline.c (ipa_inline): Update.
14672         (pass_ipa_inline): Do not generate summaries.
14673         * ipa.c (pass_data_ipa_free_fn_summary, pass_ipa_free_fn_summary):
14674         Remove.
14675         * passes.def: Replace pass_inline_parameters by pass_local_fn_summary
14676         and add pass_ipa_fn_summary.
14677         * tree-pass.h (make_pass_ipa_fn_summary, make_pass_local_fn_summary):
14678         New.
14679         (make_pass_inline_parameters): Remove.
14681 2017-05-23  Thomas Schwinge  <thomas@codesourcery.com>
14683         * omp-low.c (struct omp_context): Remove "default_kind" member.
14684         Adjust all users.
14686         * omp-offload.c (execute_oacc_device_lower): Remove the
14687         parallelism dimensions function attributes for unparallelized
14688         OpenACC kernels constructs.
14690 2017-05-23  Martin Liska  <mliska@suse.cz>
14692         * cgraph.c (cgraph_node::get_create): Use symtab_node::dump_{asm_,}name
14693         functions.
14694         (cgraph_edge::make_speculative): Likewise.
14695         (cgraph_edge::resolve_speculation): Likewise.
14696         (cgraph_edge::redirect_call_stmt_to_callee): Likewise.
14697         (cgraph_node::dump): Likewise.
14698         * cgraph.h: Likewise.
14699         * cgraphunit.c (analyze_functions): Likewise.
14700         (symbol_table::compile): Likewise.
14701         * ipa-cp.c (print_all_lattices): Likewise.
14702         (determine_versionability): Likewise.
14703         (initialize_node_lattices): Likewise.
14704         (ipcp_verify_propagated_values): Likewise.
14705         (estimate_local_effects): Likewise.
14706         (update_profiling_info): Likewise.
14707         (create_specialized_node): Likewise.
14708         (perhaps_add_new_callers): Likewise.
14709         (decide_about_value): Likewise.
14710         (decide_whether_version_node): Likewise.
14711         (identify_dead_nodes): Likewise.
14712         (ipcp_store_bits_results): Likewise.
14713         * ipa-devirt.c (dump_targets): Likewise.
14714         (ipa_devirt): Likewise.
14715         * ipa-icf.c (sem_item::dump): Likewise.
14716         (sem_function::equals): Likewise.
14717         (sem_variable::equals): Likewise.
14718         (sem_item_optimizer::read_section): Likewise.
14719         (sem_item_optimizer::execute): Likewise.
14720         (congruence_class::dump): Likewise.
14721         * ipa-inline-analysis.c (dump_ipa_call_summary): Likewise.
14722         (dump_inline_summary): Likewise.
14723         (estimate_node_size_and_time): Likewise.
14724         (inline_analyze_function): Likewise.
14725         * ipa-inline-transform.c (inline_call): Likewise.
14726         * ipa-inline.c (report_inline_failed_reason): Likewise.
14727         (want_early_inline_function_p): Likewise.
14728         (edge_badness): Likewise.
14729         (update_edge_key): Likewise.
14730         (inline_small_functions): Likewise.
14731         * ipa-profile.c (ipa_profile): Likewise.
14732         * ipa-prop.c (ipa_print_node_jump_functions): Likewise.
14733         (ipa_make_edge_direct_to_target): Likewise.
14734         (remove_described_reference): Likewise.
14735         (ipa_impossible_devirt_target): Likewise.
14736         (propagate_controlled_uses): Likewise.
14737         (ipa_print_node_params): Likewise.
14738         (ipcp_transform_function): Likewise.
14739         * ipa-pure-const.c (pure_const_read_summary): Likewise.
14740         (propagate_pure_const): Likewise.
14741         * ipa-reference.c (generate_summary): Likewise.
14742         (read_write_all_from_decl): Likewise.
14743         (propagate): Likewise.
14744         (ipa_reference_read_optimization_summary): Likewise.
14745         * ipa-utils.c (ipa_merge_profiles): Likewise.
14746         * ipa.c (walk_polymorphic_call_targets): Likewise.
14747         (symbol_table::remove_unreachable_nodes): Likewise.
14748         (ipa_single_use): Likewise.
14749         * passes.c (execute_todo): Likewise.
14750         * predict.c (drop_profile): Likewise.
14751         * symtab.c (symtab_node::get_dump_name): New function.
14752         (symtab_node::dump_name): Likewise.
14753         (symtab_node::dump_asm_name): Likewise.
14754         (symtab_node::dump_references): Likewise.
14755         (symtab_node::dump_referring): Likewise.
14756         (symtab_node::dump_base): Likewise.
14757         (symtab_node::debug_symtab): Likewise.
14758         * tree-sra.c (convert_callers_for_node): Likewise.
14759         * tree-ssa-structalias.c (ipa_pta_execute): Likewise.
14760         * value-prof.c (init_node_map): Likewise.
14762 2017-05-23  Martin Liska  <mliska@suse.cz>
14764         * cgraph.h: Move symtab_node::dump_table to symbol_table::dump
14765         and symtab_node::debug_symtab to symbol_table::debug.
14766         * cgraphunit.c (analyze_functions): Use the renamed function.
14767         (symbol_table::compile): Likewise.
14768         * ipa-cp.c (ipcp_verify_propagated_values): Likewise.
14769         * ipa-icf.c (sem_item_optimizer::execute): Likewise.
14770         * passes.c (execute_todo): Likewise.
14771         * symtab.c (symbol_table::dump): New function.
14772         * tree-ssa-structalias.c (ipa_pta_execute): Use the renamed function.
14774 2017-05-23  Jan Hubicka  <hubicka@ucw.cz>
14776         * ipa-fnsummary.c (estimate_node_size_and_time): Do not sanity check
14777         that nonconst implies exec.
14779 2017-05-23  Jan Hubicka  <hubicka@ucw.cz>
14781         * ipa-inline-analysis.c (cgraph_2edge_hook_list, cgraph_edge_hook_list,
14782         inline_edge_removal_hook, inline_edge_duplication_hook): Remove.
14783         (inline_edge_summary_vec): Turn into ...
14784         (ipa_call_summaries): ... this one.
14785         (redirect_to_unreachable, edge_set_predicate,
14786         evaluate_properties_for_edge, inline_summary_alloc,
14787         reset_ipa_call_summary, reset_inline_summary,
14788         inline_summary_t::duplicate): Update.
14789         (inline_edge_duplication_hook): Turn to ...
14790         (ipa_call_summary_t::duplicate): ... this one.
14791         (inline_edge_removal_hook): Turn to ...
14792         (ipa_call_summary_t::remove): ... this one.
14793         (dump_inline_edge_summary): Turn to ...
14794         (dump_ipa_call_summary): ... this one.
14795         (estimate_function_body_sizes): Update.
14796         (inline_update_callee_summaries): Update.
14797         (remap_edge_change_prob): Update.
14798         (remap_edge_summaries): Update.
14799         (inline_merge_summary): Update.
14800         (do_estimate_edge_time): Update.
14801         (inline_generate_summary): Update.
14802         (inline_read_section): Update.
14803         (inline_read_summary): Update.
14804         (inline_free_summary): Update.
14805         * ipa-inline.c (can_inline_edge_p): Update.
14806         (compute_inlined_call_time): Update.
14807         (want_inline_small_function_p): Update.
14808         (edge_badness): Update.
14809         (early_inliner): Update.
14810         * ipa-inline.h (inline_edge_summary): Turn to ...
14811         (ipa_call_summary): ... this one.
14812         (ipa_call_summary_t): New class.
14813         (inline_edge_summary_t, inline_edge_summary_vec): Remove.
14814         (ipa_call_summaries): New.
14815         (inline_edge_summary): Remove.
14816         (estimate_edge_growth): Update.
14817         * ipa-profile.c (ipa_propagate_frequency_1): Update.
14818         * ipa-prop.c (ipa_make_edge_direct_to_target): Update.
14819         * ipa-split.c (execute_split_functions): Update.
14820         * ipa.c (symbol_table::remove_unreachable_nodes): Update.
14822 2017-05-23  Tom de Vries  <tom@codesourcery.com>
14824         * doc/sourcebuild.texi (Effective-Target Keywords, Other hardware
14825         attributes): Document rdrand effective target.
14827 2017-05-23  Tom de Vries  <tom@codesourcery.com>
14829         * doc/sourcebuild.texi (Effective-Target Keywords, Other hardware
14830         attributes): Sort alphabetically.
14832 2017-05-23  Georg-Johann Lay  <avr@gjlay.de>
14834         * config/avr/genmultilib.awk: Use gsub instead of gensub.
14836 2017-05-22  Michael Meissner  <meissner@linux.vnet.ibm.com>
14838         PR target/80718
14839         * config/rs6000/vsx.md (vsx_splat_<mode>, VSX_D iterator): Split
14840         V2DF/V2DI splat into two separate patterns, one that handles
14841         registers, and the other that only handles memory.  Drop support
14842         for splatting from a GPR on ISA 2.07 and then splitting the
14843         splat into direct move and splat.
14844         (vsx_splat_<mode>_reg): Likewise.
14845         (vsx_splat_<mode>_mem): Likewise.
14847 2017-05-22  Segher Boessenkool  <segher@kernel.crashing.org>
14849         * cfgcleanup.c (bb_is_just_return): Allow CLOBBERs.
14851 2017-05-22  Jakub Jelinek  <jakub@redhat.com>
14853         PR middle-end/80809
14854         * omp-low.c (finish_taskreg_remap): New function.
14855         (finish_taskreg_scan): If unit size of ctx->record_type
14856         is non-constant, unshare the size expression and replace
14857         decls in it with possible outer var refs.
14859         PR middle-end/80809
14860         * gimplify.c (omp_add_variable): For GOVD_DEBUG_PRIVATE use
14861         GOVD_SHARED rather than GOVD_PRIVATE with it.
14862         (gimplify_adjust_omp_clauses_1, gimplify_adjust_omp_clauses): Expect
14863         GOVD_SHARED rather than GOVD_PRIVATE with GOVD_DEBUG_PRIVATE.
14865         PR middle-end/80853
14866         * omp-low.c (lower_reduction_clauses): Pass OMP_CLAUSE_PRIVATE
14867         as last argument to build_outer_var_ref for pointer bases of array
14868         section reductions.
14870 2017-05-19  Martin Sebor  <msebor@redhat.com>
14872         * print-tree.c (print_node): Print DECL_READ_P flag.
14874 2017-05-22  Jan Hubicka  <hubicka@ucw.cz>
14876         * Makefile.in: Add ipa-fnsummary.o and ipa-fnsummary.h
14877         * auto-profile.c: Replace ipa-inline.h by ipa-fnsummary.h
14878         * cgraph.c: Likewise.
14879         * cgraphunit.c: Likewise.
14880         * gengtype.c: Likewise.
14881         * ipa-cp.c: Likewise.
14882         * ipa-devirt.c: Likewise.
14883         * ipa-icf.c: Likewise.
14884         * ipa-predicate.c: Likewise.
14885         * ipa-profile.c: Likewise.
14886         * ipa-prop.c: Likewise.
14887         * ipa-split.c: Likewise.
14888         * ipa.c: Likewise.
14889         * ipa-inline-analysis.c (inline_summaries, ipa_call_summaries,
14890         edge_predicate_pool, dump_inline_hints,
14891         inline_summary::account_size_time, redirect_to_unreachable,
14892         edge_set_predicate, set_hint_predicate,
14893         evaluate_conditions_for_known_args, evaluate_properties_for_edge,
14894         inline_summary_alloc, ipa_call_summary::reset, inline_summary::reset,
14895         inline_summary_t::remove, remap_hint_predicate_after_duplication,
14896         inline_summary_t::duplicate, ipa_call_summary_t::duplicate,
14897         ipa_call_summary_t::remove, initialize_growth_caches,
14898         free_growth_caches, dump_ipa_call_summary, dump_inline_summary,
14899         debug_inline_summary, dump_inline_summaries, initialize_inline_failed,
14900         mark_modified, unmodified_parm_1, unmodified_parm,
14901         unmodified_parm_or_parm_agg_item, eliminated_by_inlining_prob,
14902         set_cond_stmt_execution_predicate, set_switch_stmt_execution_predicate,
14903         compute_bb_predicates, will_be_nonconstant_expr_predicate,
14904         will_be_nonconstant_predicate, record_modified_bb_info,
14905         get_minimal_bb, record_modified, param_change_prob,
14906         phi_result_unknown_predicate, predicate_for_phi_result,
14907         array_index_predicate, clobber_only_eh_bb_p, fp_expression_p,
14908         estimate_function_body_sizes, compute_inline_parameters,
14909         compute_inline_parameters_for_curren, pass_data_inline_parameters,
14910         estimate_node_size_and_time, estimate_ipcp_clone_size_and_time,
14911         inline_update_callee_summaries, remap_edge_change_prob,
14912         remap_edge_summaries, remap_hint_predicate, inline_merge_summary,
14913         inline_update_overall_summary, inline_indirect_intraprocedural_analysis,
14914         inline_analyze_function, inline_summary_t::insert,
14915         inline_generate_summary, read_ipa_call_summary, inline_read_section,
14916         inline_read_summary, write_ipa_call_summary, inline_write_summary,
14917         inline_free_summary): Move to ipa-fnsummary.h
14918         (predicate_t): Remove.
14919         * ipa-fnsummary.c: New file.
14920         * ipa-inline.h:  Do not include sreal.h and ipa-predicate.h
14921         (enum inline_hints_vals, inline_hints, agg_position_info,
14922         INLINE_SIZE_SCALE, size_time_entry, inline_summary, inline_summary_t,
14923         inline_summaries, ipa_call_summary, ipa_call_summary_t,
14924         ipa_call_summaries, debug_inline_summary, dump_inline_summaries,
14925         dump_inline_summary, dump_inline_hints, inline_generate_summary,
14926         inline_read_summary, inline_write_summary, inline_free_summary,
14927         inline_analyze_function, initialize_inline_failed,
14928         inline_merge_summary, inline_update_overall_summary,
14929         compute_inline_parameters): Move to ipa-fnsummary.h
14930         * ipa-fnsummary.h: New file.
14931         * ipa-inline-transform.h: Include ipa-inline.h.
14932         * ipa-inline.c: LIkewise.
14934 2017-05-22  Jan Hubicka  <hubicka@ucw.cz>
14936         * ipa-inline.c (edge_badness): Use inlined_time instead of
14937         inline_summaries->get.
14939 2017-05-22  Jan Hubicka  <hubicka@ucw.cz>
14941         * ipa-inline.c (edge_badness): Use estimate_size_after_inlining.
14943 2017-05-22  Nathan Sidwell  <nathan@acm.org>
14945         * doc/invoke.texi (fdump-translation-unit): Delete documentation.
14946         (fdump-lang): Document 'raw' option.
14947         * dumpfile.h (TDI_tu): Delete.
14948         * dumpfile.c (dump_files): Remove translation-unit.
14949         (FIRST_AUTO_NUMBERED_DUMP): Decrement.
14951 2017-05-22  Georg-Johann Lay  <avr@gjlay.de>
14953         * config/avr/t-avr (AWK) [t-multilib]: Remove "-v FORMAT=Makefile"
14954         command option from $(AWK) call.
14955         * config/avr/genmultilib.awk: Simplify and rewrite so that it
14956         generates MULTILIB_REQUIRED instead of MULTILIB_EXCEPTIONS.
14957         [FORMAT]: Remove handling of variable.
14958         * config/avr/t-multilib: Regenerate.
14960 2017-05-22  Jan Hubicka  <hubicka@ucw.cz>
14962         * ipa-inline-analysis.c (inline_summary::reset): Do not reset
14963         self_time.
14964         (dump_inline_summary): Do not print self_time.
14965         (estimate_function_body_sizes): Do not set self_time.
14966         (compute_inline_parameters): Likewise.
14967         (inline_read_section, inline_write_summary): Do not stream self_time.
14968         * ipa-inline.h (inline_summary): Drop self_time.
14970 2017-05-22  Jan Hubicka  <hubicka@ucw.cz>
14972         * ipa-inline-analysis.c (account_size_time): Rename to ...
14973         (inline_summary::account_size_time): ... this one.
14974         (reset_ipa_call_summary): Turn to ...
14975         (ipa_call_summary::reset): ... this one.
14976         (reset_inline_summary): Turn to ...
14977         (inline_summary::reset): ... this one.
14978         (inline_summary_t::remove): Update.
14979         (inline_summary_t::duplicate): Update.
14980         (ipa_call_summary_t::remove): Update.
14981         (dump_inline_summary): Update.
14982         (estimate_function_body_sizes): Update.
14983         (compute_inline_parameters): Update.
14984         (estimate_node_size_and_time): Update.
14985         (inline_merge_summary): Update.
14986         (inline_update_overall_summary): Update.
14987         (inline_read_section): Update.
14988         (inline_write_summary): Update.
14989         * ipa-inline.h (inline_summary): Rename entry to size_time_table;
14990         add account_size_time and reset member functions.
14991         (ipa_call_summary): Add reset function.
14992         * ipa-predicate.h (predicate::operator &): Constify.
14994 2017-05-22  Richard Biener  <rguenther@suse.de>
14996         * df-scan.c (df_insn_refs_verify): Speedup when not verifying.
14998 2017-05-19  Jason Merrill  <jason@redhat.com>
15000         * tree.c (make_tree_vec_stat, grow_tree_vec_stat): Use size_t.
15002 2017-05-19  Marek Polacek  <polacek@redhat.com>
15004         PR sanitizer/80800
15005         * fold-const.c (extract_muldiv_1) <case TRUNC_DIV_EXPR>: Add
15006         TYPE_OVERFLOW_WRAPS checks.
15008 2017-05-19  Thomas Schwinge  <thomas@codesourcery.com>
15010         * tree-core.h (enum omp_clause_default_kind): Add
15011         "OMP_CLAUSE_DEFAULT_PRESENT".
15012         * tree-pretty-print.c (dump_omp_clause): Handle it.
15013         * gimplify.c (enum gimplify_omp_var_data): Add
15014         "GOVD_MAP_FORCE_PRESENT".
15015         (gimplify_adjust_omp_clauses_1): Map it to
15016         "GOMP_MAP_FORCE_PRESENT".
15017         (oacc_default_clause): Handle "OMP_CLAUSE_DEFAULT_PRESENT".
15019         * gimplify.c (oacc_default_clause): Clarify.
15021 2017-05-19  Nathan Sidwell  <nathan@acm.org>
15023         LANG_HOOK_REGISTER_DUMPS
15024         * toplev.c (general_init): Call register dump lang hook.
15025         * doc/invoke.texi: Document -fdump-lang option family.
15026         * dumpfile.c (dump_files): Remove class dump here.
15027         (FIRST_AUTO_NUMBERED_DUMP): Adjust.
15028         * dumpfile.h (tree_dump_index): Remove TDI_class.
15029         * langhooks-def.h (lhd_register_dumps): Declare.
15030         (LANG_HOOKS_REGISTER_DUMPS): Define.
15031         (LANG_HOOKS_INITIALIZER): Add it.
15032         * langhooks.c (lhd_register_dumps): Define.
15033         * langhooks.h (struct lang_hooks): Add register_dumps.
15035 2017-05-19  Nathan Sidwell  <nathan@acm.org>
15037         * context.h (context::set_passes): New.
15038         * context.c (context::context): Do not create pass manager.
15039         * toplev.c (general_init): Create pass manager here.
15041 2017-05-19  Segher Boessenkool  <segher@kernel.crashing.org>
15043         * config/rs6000/rs6000.md (splitter to load of -1 and mask): Don't
15044         use this splitter if two add or or instructions would also work for
15045         the constant we want to generate.
15047 2017-05-19  Richard Biener  <rguenther@suse.de>
15049         PR build/80821
15050         * genmatch.c (dt_node::gen_kids_1): Add missing scope around
15051         predicate evaluation.
15053 2017-05-19  Jan Hubicka  <hubicka@ucw.cz>
15055         * ipa-inline.h (ipa_call_summary): Turn sizes into signed;
15056         add ctor.
15057         * ipa-inline.c (want_inline_small_function_p): Do not cast to
15058         unsigned.
15060 2017-05-19  Jan Hubicka  <hubicka@ucw.cz>
15062         * ipa-inline-analysis.c (cgraph_2edge_hook_list, cgraph_edge_hook_list,
15063         inline_edge_removal_hook, inline_edge_duplication_hook): Remove.
15064         (inline_edge_summary_vec): Turn into ...
15065         (ipa_call_summaries): ... this one.
15066         (redirect_to_unreachable, edge_set_predicate,
15067         evaluate_properties_for_edge, inline_summary_alloc,
15068         reset_ipa_call_summary, reset_inline_summary,
15069         inline_summary_t::duplicate): Update.
15070         (inline_edge_duplication_hook): Turn to ...
15071         (ipa_call_summary_t::duplicate): ... this one.
15072         (inline_edge_removal_hook): Turn to ...
15073         (ipa_call_summary_t::remove): ... this one.
15074         (dump_inline_edge_summary): Turn to ...
15075         (dump_ipa_call_summary): ... this one.
15076         (estimate_function_body_sizes): Update.
15077         (inline_update_callee_summaries): Update.
15078         (remap_edge_change_prob): Update.
15079         (remap_edge_summaries): Update.
15080         (inline_merge_summary): Update.
15081         (do_estimate_edge_time): Update.
15082         (inline_generate_summary): Update.
15083         (inline_read_section): Update.
15084         (inline_read_summary): Update.
15085         (inline_free_summary): Update.
15086         * ipa-inline.c (can_inline_edge_p): Update.
15087         (compute_inlined_call_time): Update.
15088         (want_inline_small_function_p): Update.
15089         (edge_badness): Update.
15090         (early_inliner): Update.
15091         * ipa-inline.h (inline_edge_summary): Turn to ...
15092         (ipa_call_summary): ... this one.
15093         (ipa_call_summary_t): New class.
15094         (inline_edge_summary_t, inline_edge_summary_vec): Remove.
15095         (ipa_call_summaries): New.
15096         (inline_edge_summary): Remove.
15097         (estimate_edge_growth): Update.
15098         * ipa-profile.c (ipa_propagate_frequency_1): Update.
15099         * ipa-prop.c (ipa_make_edge_direct_to_target): Update.
15100         * ipa-split.c (execute_split_functions): Update.
15101         * ipa.c (symbol_table::remove_unreachable_nodes): Update.
15103 2017-05-19  Richard Biener  <rguenther@suse.de>
15105         PR middle-end/80764
15106         * cfgexpand.c (expand_gimple_cond): Fix loop fixup.
15108 2017-05-18  Segher Boessenkool  <segher@kernel.crashing.org>
15110         * config/rs6000/rs6000.c (struct machine_function): Add field
15111         fpr_is_wrapped_separately.
15112         (rs6000_get_separate_components): Use 64 components.  Handle the
15113         new FPR components.
15114         (rs6000_components_for_bb): Handle the FPR components.
15115         (rs6000_emit_prologue_components): Handle the FPR components.
15116         (rs6000_emit_epilogue_components): Handle the FPR components.
15117         (rs6000_set_handled_components): Handle the FPR components.
15118         (rs6000_emit_prologue): Don't output prologue code for those FPRs
15119         that are already separately shrink-wrapped.
15120         (rs6000_emit_epilogue): Don't output epilogue code for those FPRs
15121         that are already separately shrink-wrapped.
15123 2017-05-18  Michael Meissner  <meissner@linux.vnet.ibm.com>
15125         PR target/80510
15126         * config/rs6000/predicates.md (simple_offsettable_mem_operand):
15127         New predicate.
15129         * config/rs6000/rs6000.md (ALTIVEC_DFORM): New iterator.
15130         (define_peephole2 for Altivec d-form load): Add peepholes to catch
15131         cases where the register allocator uses a move and an offsettable
15132         memory operation to/from a FPR register on ISA 2.06/2.07.
15133         (define_peephole2 for Altivec d-form store): Likewise.
15135 2017-05-18  Uros Bizjak  <ubizjak@gmail.com>
15137         PR target/80799
15138         * config/i386/mmx.md (*mov<mode>_internal): Enable
15139         alternatives 11, 12, 13 and 14 also for 32bit targets.
15140         Remove alternatives 15, 16, 17 and 18.
15141         * config/i386/sse.md (vec_concatv2di): Change
15142         alternative (!x, *y) to (x, ?!*Yn).
15144 2017-05-18  Paolo Carlini  <paolo.carlini@oracle.com>
15146         * dumpfile.h (enum dump_kind): Remove stray comma.
15148 2017-05-18  Jan Hubicka  <hubicka@ucw.cz>
15150         * Makefile.in: Add ipa-predicate.o and ipa-predicate.h
15151         * ipa-inline-analysis.c (NUM_CONDITIONS): turn into
15152         predicate::num_conditions
15153         (IS_NOT_CONSTANT): turn into predicate::is_not_constant.
15154         (CHANGED): turn into predicate::changed.
15155         (agg_position_info): Move to ipa-predicate.h
15156         (add_condition, predicate::add_clause, predicate::operator &=,
15157         predicate::or_with, predicate::evaluate, predicate::probability,
15158         dump_condition, dump_clause, predicate::dump,
15159         predicate::remap_after_duplication, predicate::remap_after_inlining,
15160         predicate::stream_in, predicate::stream_out): Move to ipa-predicate.c
15161         (evaluate_conditions_for_known_args): Update.
15162         (set_cond_stmt_execution_predicate): Update.
15163         * ipa-inline.h: Include ipa-predicate.h
15164         (condition, inline_param_summary, conditions, agg_position_info,
15165         predicate): Move to ipa-predicate.h
15166         * ipa-predicate.c: New file.
15167         * ipa-predicate.h: New file.
15169 2017-05-18  Wilco Dijkstra  <wdijkstr@arm.com>
15171         * final.c (leaf_function_p): Check we are not in a sequence.
15173 2017-05-18  Martin Liska  <mliska@suse.cz>
15175         * cfgrtl.c (rtl_verify_edges): Remove usage of TDF_RTL.
15176         * dumpfile.c (dump_register): Use new enum dump_kind.
15177         (get_dump_file_name): Likewise.
15178         (dump_enable_all): Likewise.
15179         (dump_switch_p_1): Likewise.
15180         (enable_rtl_dump_file): Remove usage of TDF_RTL.
15181         * dumpfile.h (enum dump_kind): New enum type.
15182         (struct dump_file_info): Create constructor and
15183         format fields and comments.
15184         * passes.c (pass_manager::register_one_dump_file):
15185         Use num dump_kind.
15186         * statistics.c (statistics_early_init): Likewise.
15187         * tree-ssa-loop-prefetch.c (dump_mem_details): Replace
15188         TDF_TREE with TDF_SLIM.
15189         (gather_memory_references_ref): Likewise.
15191 2017-05-18  Martin Liska  <mliska@suse.cz>
15193         * vec.h (struct vnull): Use it.
15195 2017-05-18  Jan Hubicka  <hubicka@ucw.cz>
15197         * ipa-inline-analysis.c (predicate_conditions): Move to ipa-inline.h
15198         (true_predicate, false_predicate, true_predicate_p,
15199         false_predicate_p): Remove.
15200         (single_cond_predicate, not_inlined_predicate): Turn to member function
15201         in ipa-inline.h
15202         (add_condition): Update.
15203         (add_clause): Turn to...
15204         (predicate::add_clause): ... this one; update; allow passing NULL
15205         as parameter.
15206         (and_predicates): Turn to ...
15207         (predicate::operator &=): ... this one.
15208         (predicates_equal_p): Move to predicate::operator == in ipa-inline.h
15209         (or_predicates): Turn to ...
15210         (predicate::or_with): ... this one.
15211         (evaluate_predicate): Turn to ...
15212         (predicate::evaluate): ... this one.
15213         (predicate_probability): Turn to ...
15214         (predicate::probability): ... this one.
15215         (dump_condition): Update.
15216         (dump_predicate): Turn to ...
15217         (predicate::dump): ... this one.
15218         (account_size_time): Update.
15219         (edge_set_predicate): Update.
15220         (set_hint_predicate): UPdate.
15221         (evaluate_conditions_for_known_args): Update.
15222         (evaluate_properties_for_edge): Update.
15223         (remap_predicate_after_duplication): Turn to...
15224         (predicate::remap_after_duplication): ... this one.
15225         (remap_hint_predicate_after_duplication): Update.
15226         (inline_summary_t::duplicate): UPdate.
15227         (dump_inline_edge_summary): Update.
15228         (dump_inline_summary): Update.
15229         (set_cond_stmt_execution_predicate): Update.
15230         (set_switch_stmt_execution_predicate): Update.
15231         (compute_bb_predicates): Update.
15232         (will_be_nonconstant_expr_predicate): Update.
15233         (will_be_nonconstant_predicate): Update.
15234         (phi_result_unknown_predicate): Update.
15235         (predicate_for_phi_result): Update.
15236         (array_index_predicate): Update.
15237         (estimate_function_body_sizes): Update.
15238         (estimate_node_size_and_time): Update.
15239         (estimate_ipcp_clone_size_and_time): Update.
15240         (remap_predicate): Rename to ...
15241         (predicate::remap_after_inlining): ... this one.
15242         (remap_hint_predicate): Update.
15243         (inline_merge_summary): Update.
15244         (inline_update_overall_summary): Update.
15245         (estimate_size_after_inlining): Update.
15246         (read_predicate): Rename to ...
15247         (predicate::stream_in): ... this one.
15248         (read_inline_edge_summary): Update.
15249         (write_predicate): Rename to ...
15250         (predicate::stream_out): ... this one.
15251         (write_inline_edge_summary): Update.
15252         * ipa-inline.h (MAX_CLAUSES): Turn to predicate::max_clauses.
15253         (clause_t): Turn to uint32_t
15254         (predicate): Turn to class; implement constructor and operators
15255         ==, !=, &
15256         (size_time_entry): Update.
15257         (inline_summary): Update.
15258         (inline_edge_summary): Update.
15260 2017-05-18  Marc Glisse  <marc.glisse@inria.fr>
15262         * fold-const.c (fold_binary_loc): Move transformation...
15263         * match.pd (C - X CMP X): ... here.
15265 2017-05-18  Sheldon Lobo  <sheldon.lobo@oracle.com>
15267         * config/sparc/sparc.c (sparc_option_override): Set function
15268         alignment for -mcpu=niagara7 to 64 to match the I$ line.
15269         * config/sparc/sparc.h (BRANCH_COST): Set the SPARC M7 branch
15270         latency to 1.
15271         * config/sparc/sparc.h (BRANCH_COST): Set the SPARC T4 branch
15272         latency to 2.
15273         * config/sparc/sol2.h: Fix a ASM_CPU32_DEFAULT_SPEC typo.
15275 2017-05-18  Marek Polacek  <polacek@redhat.com>
15277         PR sanitizer/80797
15278         * ubsan.c (instrument_null): Unwrap ADDR_EXPRs.
15279         (pass_ubsan::execute): Call gimple_assign_single_p instead of
15280         gimple_assign_load_p.
15282 2017-05-17  Segher Boessenkool  <segher@kernel.crashing.org>
15284         PR middle-end/80692
15285         * real.c (do_compare): Give decimal_do_compare preference over
15286         comparing just the signs.
15288 2017-05-17  Uros Bizjak  <ubizjak@gmail.com>
15290         * doc/md.texi (Canonicalization of Instructions): Describe the
15291         canonical form of instructions that inherently set a condition
15292         code register.
15294 2017-05-17  Peter Bergner  <bergner@vnet.ibm.com>
15296         PR middle-end/80775
15297         * tree-cfg.c: Move deletion of unreachable case statements to after
15298         the merging of consecutive case labels.
15300 2017-05-17  Thomas Preud'homme  <thomas.preudhomme@arm.com>
15302         * config/arm/arm.c (cmse_nonsecure_call_clear_caller_saved): Refer
15303         readers to __gnu_cmse_nonsecure_call libcall for saving, clearing and
15304         restoring of callee-saved registers.
15306 2017-05-17  Eric Botcazou  <ebotcazou@adacore.com>
15308         * compare-elim.c (equivalent_reg_at_start): Adjust outdated comment.
15309         * config/visium/visium.c (single_set_and_flags): Likewise.
15310         * config/visium/visium.md (Substitutions): Likewise.
15312 2017-05-17  Martin Liska  <mliska@suse.cz>
15314         * cfg.c: Introduce dump_flags_t type and
15315         use it instead of int type.
15316         * cfg.h: Likewise.
15317         * cfghooks.c: Likewise.
15318         * cfghooks.h (struct cfg_hooks): Likewise.
15319         * cfgrtl.c: Likewise.
15320         * cfgrtl.h: Likewise.
15321         * cgraph.c (cgraph_node::get_body): Likewise.
15322         * coretypes.h: Likewise.
15323         * domwalk.c: Likewise.
15324         * domwalk.h: Likewise.
15325         * dumpfile.c (struct dump_option_value_info): Likewise.
15326         (dump_enable_all): Likewise.
15327         (dump_switch_p_1): Likewise.
15328         (opt_info_switch_p): Likewise.
15329         * dumpfile.h (enum tree_dump_index): Likewise.
15330         (struct dump_file_info): Likewise.
15331         * genemit.c: Likewise.
15332         * generic-match-head.c: Likewise.
15333         * gengtype.c (open_base_files): Likewise.
15334         * gimple-pretty-print.c: Likewise.
15335         * gimple-pretty-print.h: Likewise.
15336         * graph.c (print_graph_cfg): Likewise.
15337         * graphite-scop-detection.c (dot_all_sese): Likewise.
15338         * ipa-devirt.c (build_type_inheritance_graph): Likewise.
15339         * loop-unroll.c (report_unroll): Likewise.
15340         * passes.c (pass_manager::register_one_dump_file): Likewise.
15341         * print-tree.c: Likewise.
15342         * statistics.c: Likewise.
15343         * tree-cfg.c: Likewise.
15344         * tree-cfg.h: Likewise.
15345         * tree-dfa.c: Likewise.
15346         * tree-dfa.h: Likewise.
15347         * tree-dump.c (dump_function): Likewise.
15348         * tree-dump.h (struct dump_info): Likewise.
15349         * tree-pretty-print.c: Likewise.
15350         * tree-pretty-print.h: Likewise.
15351         * tree-ssa-live.c: Likewise.
15352         * tree-ssa-live.h: Likewise.
15353         * tree-ssa-loop-ivcanon.c (try_unroll_loop_completely): Likewise.
15354         * tree-vect-loop.c: Likewise.
15355         * tree-vect-slp.c: Likewise.
15357 2017-05-16  James Greenhalgh  <james.greenhalgh@arm.com>
15358             Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
15360         PR tree-optimization/80457
15361         * tree-vect-stmts.c (vect_model_simple_cost): Model the cost
15362         of all arguments to a statement as scalar_to_vec operations.
15363         (vectorizable_call): Adjust call to vect_model_simple_cost for
15364         new parameter.
15365         (vectorizable_conversion): Likewise.
15366         (vectorizable_assignment): Likewise.
15367         (vectorizable_shift): Likewise.
15368         (vectorizable_operation): Likewise.
15369         (vectorizable_comparison): Likewise.
15370         (vect_is_simple_cond): Record the def types for operands.
15371         (vectorizable_condition): Likewise, call vect_model_simple_cost.
15372         * tree-vectorizer.h (vect_model_simple_cost): Add new parameter
15373         for statement argument count.
15375 2017-05-16  Carl Love  <cel@us.ibm.com>
15377         * config/rs6000/rs6000-c: Add support for built-in functions
15378         vector unsigned long long vec_bperm (vector unsigned long long,
15379                                              vector unsigned char)
15380         vector signed long long vec_mule (vector signed int,
15381                                           vector signed int)
15382         vector unsigned long long vec_mule (vector unsigned int,
15383                                             vector unsigned int)
15384         vector signed long long vec_mulo (vector signed int,
15385                                           vector signed int)
15386         vector unsigned long long vec_mulo (vector unsigned int,
15387                                             vector unsigned int)
15388         vector signed char vec_sldw (vector signed char,
15389                                      vector signed char,
15390                                      const int)
15391         vector unsigned char vec_sldw (vector unsigned char,
15392                                        vector unsigned char,
15393                                        const int)
15394         vector signed short vec_sldw (vector signed short,
15395                                       vector signed short,
15396                                       const int)
15397         vector unsigned short vec_sldw (vector unsigned short,
15398                                         vector unsigned short,
15399                                         const int)
15400         vector signed int vec_sldw (vector signed int,
15401                                     vector signed int,
15402                                     const int)
15403         vector unsigned int vec_sldw (vector unsigned int,
15404                                       vector unsigned int,
15405                                       const int)
15406         vector signed long long vec_sldw (vector signed long long,
15407                                           vector signed long long,
15408                                           const int)
15409         vector unsigned long long vec_sldw (vector unsigned long long,
15410                                             vector unsigned long long,
15411                                             const int)
15412         * config/rs6000/rs6000-c: Add support for built-in functions
15413         * config/rs6000/rs6000-builtin.def: Add definition for SLDW.
15414         * config/rs6000/altivec.h: Add defintion for vec_sldw.
15415         * doc/extend.texi: Update the built-in documentation for the
15416         new built-in functions.
15418 2017-05-16  Marek Polacek  <polacek@redhat.com>
15420         PR sanitizer/80536
15421         PR sanitizer/80386
15422         * tree.c (save_expr): Don't fold the expression.
15424 2017-05-16  Uros Bizjak  <ubizjak@gmail.com>
15426         * config/i386/i386.md (*movsi_internal): Split (?rm,*y) alternative
15427         to (?r,*Yn) and (?m,*y) alternatives, and (?*y,rm) to (?*Ym,r)
15428         and (?*y,m).  Update insn attributes.
15430 2017-05-16  Martin Liska  <mliska@suse.cz>
15432         * cgraph.c (cgraph_edge::resolve_speculation): Add default value for
15433         flags argument of print_gimple_stmt, print_gimple_expr,
15434         print_generic_stmt and print_generic_expr.
15435         * cgraphclones.c (symbol_table::materialize_all_clones): Likewise.
15436         * coretypes.h: Likewise.
15437         * except.c (dump_eh_tree): Likewise.
15438         * gimple-fold.c (gimple_fold_stmt_to_constant_1): Likewise.
15439         * gimple-pretty-print.h: Likewise.
15440         * gimple-ssa-backprop.c (dump_usage_prefix): Likewise.
15441         (backprop::push_to_worklist): Likewise.
15442         (backprop::pop_from_worklist): Likewise.
15443         (backprop::process_use): Likewise.
15444         (backprop::intersect_uses): Likewise.
15445         (note_replacement): Likewise.
15446         * gimple-ssa-store-merging.c
15447         (pass_store_merging::terminate_all_aliasing_chains): Likewise.
15448         (imm_store_chain_info::coalesce_immediate_stores): Likewise.
15449         (pass_store_merging::execute): Likewise.
15450         * gimple-ssa-strength-reduction.c (dump_candidate): Likewise.
15451         (ssa_base_cand_dump_callback): Likewise.
15452         (dump_incr_vec): Likewise.
15453         (replace_refs): Likewise.
15454         (replace_mult_candidate): Likewise.
15455         (create_add_on_incoming_edge): Likewise.
15456         (create_phi_basis): Likewise.
15457         (insert_initializers): Likewise.
15458         (all_phi_incrs_profitable): Likewise.
15459         (introduce_cast_before_cand): Likewise.
15460         (replace_one_candidate): Likewise.
15461         * gimplify.c (gimplify_expr): Likewise.
15462         * graphite-isl-ast-to-gimple.c (is_valid_rename): Likewise.
15463         (set_rename): Likewise.
15464         (rename_uses): Likewise.
15465         (copy_loop_phi_nodes): Likewise.
15466         (add_close_phis_to_merge_points): Likewise.
15467         (copy_loop_close_phi_args): Likewise.
15468         (copy_cond_phi_args): Likewise.
15469         (graphite_copy_stmts_from_block): Likewise.
15470         (translate_pending_phi_nodes): Likewise.
15471         * graphite-poly.c (print_pdr): Likewise.
15472         (dump_gbb_cases): Likewise.
15473         (dump_gbb_conditions): Likewise.
15474         (print_scop_params): Likewise.
15475         * graphite-scop-detection.c (build_cross_bb_scalars_def): Likewise.
15476         (build_cross_bb_scalars_use): Likewise.
15477         (gather_bbs::before_dom_children): Likewise.
15478         * hsa-dump.c (dump_hsa_immed): Likewise.
15479         * ipa-cp.c (print_ipcp_constant_value): Likewise.
15480         (get_replacement_map): Likewise.
15481         * ipa-inline-analysis.c (dump_condition): Likewise.
15482         (estimate_function_body_sizes): Likewise.
15483         * ipa-polymorphic-call.c (check_stmt_for_type_change): Likewise.
15484         (ipa_polymorphic_call_context::get_dynamic_type): Likewise.
15485         * ipa-prop.c (ipa_dump_param): Likewise.
15486         (ipa_print_node_jump_functions_for_edge): Likewise.
15487         (ipa_modify_call_arguments): Likewise.
15488         (ipa_modify_expr): Likewise.
15489         (ipa_dump_param_adjustments): Likewise.
15490         (ipa_dump_agg_replacement_values): Likewise.
15491         (ipcp_modif_dom_walker::before_dom_children): Likewise.
15492         * ipa-pure-const.c (check_stmt): Likewise.
15493         (pass_nothrow::execute): Likewise.
15494         * ipa-split.c (execute_split_functions): Likewise.
15495         * omp-offload.c (dump_oacc_loop_part): Likewise.
15496         (dump_oacc_loop): Likewise.
15497         * trans-mem.c (tm_log_emit): Likewise.
15498         (tm_memopt_accumulate_memops): Likewise.
15499         (dump_tm_memopt_set): Likewise.
15500         (dump_tm_memopt_transform): Likewise.
15501         * tree-cfg.c (gimple_verify_flow_info): Likewise.
15502         (print_loop): Likewise.
15503         * tree-chkp-opt.c (chkp_print_addr): Likewise.
15504         (chkp_gather_checks_info): Likewise.
15505         (chkp_get_check_result): Likewise.
15506         (chkp_remove_check_if_pass): Likewise.
15507         (chkp_use_outer_bounds_if_possible): Likewise.
15508         (chkp_reduce_bounds_lifetime): Likewise.
15509         * tree-chkp.c (chkp_register_addr_bounds): Likewise.
15510         (chkp_mark_completed_bounds): Likewise.
15511         (chkp_register_incomplete_bounds): Likewise.
15512         (chkp_mark_invalid_bounds): Likewise.
15513         (chkp_maybe_copy_and_register_bounds): Likewise.
15514         (chkp_build_returned_bound): Likewise.
15515         (chkp_get_bound_for_parm): Likewise.
15516         (chkp_build_bndldx): Likewise.
15517         (chkp_get_bounds_by_definition): Likewise.
15518         (chkp_generate_extern_var_bounds): Likewise.
15519         (chkp_get_bounds_for_decl_addr): Likewise.
15520         * tree-chrec.c (chrec_apply): Likewise.
15521         * tree-data-ref.c (dump_data_reference): Likewise.
15522         (dump_subscript): Likewise.
15523         (dump_data_dependence_relation): Likewise.
15524         (analyze_overlapping_iterations): Likewise.
15525         * tree-inline.c (expand_call_inline): Likewise.
15526         (tree_function_versioning): Likewise.
15527         * tree-into-ssa.c (dump_defs_stack): Likewise.
15528         (dump_currdefs): Likewise.
15529         (dump_names_replaced_by): Likewise.
15530         (dump_update_ssa): Likewise.
15531         (update_ssa): Likewise.
15532         * tree-object-size.c (pass_object_sizes::execute): Likewise.
15533         * tree-parloops.c (build_new_reduction): Likewise.
15534         (try_create_reduction_list): Likewise.
15535         (ref_conflicts_with_region): Likewise.
15536         (oacc_entry_exit_ok_1): Likewise.
15537         (oacc_entry_exit_single_gang): Likewise.
15538         * tree-pretty-print.h: Likewise.
15539         * tree-scalar-evolution.c (set_scalar_evolution): Likewise.
15540         (get_scalar_evolution): Likewise.
15541         (add_to_evolution): Likewise.
15542         (get_loop_exit_condition): Likewise.
15543         (analyze_evolution_in_loop): Likewise.
15544         (analyze_initial_condition): Likewise.
15545         (analyze_scalar_evolution): Likewise.
15546         (instantiate_scev): Likewise.
15547         (number_of_latch_executions): Likewise.
15548         (gather_chrec_stats): Likewise.
15549         (final_value_replacement_loop): Likewise.
15550         (scev_const_prop): Likewise.
15551         * tree-sra.c (dump_access): Likewise.
15552         (disqualify_candidate): Likewise.
15553         (create_access): Likewise.
15554         (reject): Likewise.
15555         (maybe_add_sra_candidate): Likewise.
15556         (create_access_replacement): Likewise.
15557         (analyze_access_subtree): Likewise.
15558         (analyze_all_variable_accesses): Likewise.
15559         (sra_modify_assign): Likewise.
15560         (initialize_constant_pool_replacements): Likewise.
15561         (find_param_candidates): Likewise.
15562         (decide_one_param_reduction): Likewise.
15563         (replace_removed_params_ssa_names): Likewise.
15564         * tree-ssa-ccp.c (ccp_fold_stmt): Likewise.
15565         * tree-ssa-copy.c (dump_copy_of): Likewise.
15566         (copy_prop_visit_cond_stmt): Likewise.
15567         * tree-ssa-dce.c (mark_operand_necessary): Likewise.
15568         * tree-ssa-dom.c (pass_dominator::execute): Likewise.
15569         (record_equivalences_from_stmt): Likewise.
15570         * tree-ssa-dse.c (compute_trims): Likewise.
15571         (delete_dead_call): Likewise.
15572         (delete_dead_assignment): Likewise.
15573         * tree-ssa-forwprop.c (forward_propagate_into_gimple_cond): Likewise.
15574         (forward_propagate_into_cond): Likewise.
15575         (pass_forwprop::execute): Likewise.
15576         * tree-ssa-ifcombine.c (ifcombine_ifandif): Likewise.
15577         * tree-ssa-loop-im.c (invariantness_dom_walker::before_dom_children):
15578         Likewise.
15579         (move_computations_worker): Likewise.
15580         (execute_sm): Likewise.
15581         * tree-ssa-loop-ivcanon.c (tree_estimate_loop_size): Likewise.
15582         (remove_exits_and_undefined_stmts): Likewise.
15583         (remove_redundant_iv_tests): Likewise.
15584         * tree-ssa-loop-ivopts.c (dump_use): Likewise.
15585         (adjust_iv_update_pos): Likewise.
15586         * tree-ssa-math-opts.c (bswap_replace): Likewise.
15587         * tree-ssa-phiopt.c (factor_out_conditional_conversion): Likewise.
15588         (value_replacement): Likewise.
15589         * tree-ssa-phiprop.c (phiprop_insert_phi): Likewise.
15590         * tree-ssa-pre.c (print_pre_expr): Likewise.
15591         (get_representative_for): Likewise.
15592         (create_expression_by_pieces): Likewise.
15593         (insert_into_preds_of_block): Likewise.
15594         (eliminate_insert): Likewise.
15595         (eliminate_dom_walker::before_dom_children): Likewise.
15596         (eliminate): Likewise.
15597         (remove_dead_inserted_code): Likewise.
15598         * tree-ssa-propagate.c (substitute_and_fold): Likewise.
15599         * tree-ssa-reassoc.c (get_rank): Likewise.
15600         (eliminate_duplicate_pair): Likewise.
15601         (eliminate_plus_minus_pair): Likewise.
15602         (eliminate_not_pairs): Likewise.
15603         (undistribute_ops_list): Likewise.
15604         (eliminate_redundant_comparison): Likewise.
15605         (update_range_test): Likewise.
15606         (optimize_range_tests_var_bound): Likewise.
15607         (optimize_vec_cond_expr): Likewise.
15608         (rewrite_expr_tree): Likewise.
15609         (rewrite_expr_tree_parallel): Likewise.
15610         (linearize_expr): Likewise.
15611         (break_up_subtract): Likewise.
15612         (linearize_expr_tree): Likewise.
15613         (attempt_builtin_powi): Likewise.
15614         (attempt_builtin_copysign): Likewise.
15615         (transform_stmt_to_copy): Likewise.
15616         (transform_stmt_to_multiply): Likewise.
15617         (dump_ops_vector): Likewise.
15618         * tree-ssa-sccvn.c (vn_nary_build_or_lookup_1): Likewise.
15619         (print_scc): Likewise.
15620         (set_ssa_val_to): Likewise.
15621         (visit_reference_op_store): Likewise.
15622         (visit_use): Likewise.
15623         (sccvn_dom_walker::before_dom_children): Likewise.
15624         (run_scc_vn): Likewise.
15625         * tree-ssa-scopedtables.c (avail_exprs_stack::lookup_avail_expr):
15626         Likewise.
15627         (expr_hash_elt::print): Likewise.
15628         (const_and_copies::pop_to_marker): Likewise.
15629         (const_and_copies::record_const_or_copy_raw): Likewise.
15630         * tree-ssa-structalias.c (compute_dependence_clique): Likewise.
15631         * tree-ssa-uninit.c (collect_phi_def_edges): Likewise.
15632         (dump_predicates): Likewise.
15633         (find_uninit_use): Likewise.
15634         (warn_uninitialized_phi): Likewise.
15635         (pass_late_warn_uninitialized::execute): Likewise.
15636         * tree-ssa.c (verify_vssa): Likewise.
15637         (verify_ssa): Likewise.
15638         (maybe_optimize_var): Likewise.
15639         * tree-vrp.c (dump_value_range): Likewise.
15640         (dump_all_value_ranges): Likewise.
15641         (dump_asserts_for): Likewise.
15642         (register_edge_assert_for_2): Likewise.
15643         (vrp_visit_cond_stmt): Likewise.
15644         (vrp_visit_switch_stmt): Likewise.
15645         (vrp_visit_stmt): Likewise.
15646         (vrp_visit_phi_node): Likewise.
15647         (simplify_cond_using_ranges_1): Likewise.
15648         (fold_predicate_in): Likewise.
15649         (evrp_dom_walker::before_dom_children): Likewise.
15650         (evrp_dom_walker::push_value_range): Likewise.
15651         (evrp_dom_walker::pop_value_range): Likewise.
15652         (execute_early_vrp): Likewise.
15654 2017-05-16  Richard Biener  <rguenther@suse.de>
15656         * dwarf2out.c (loc_list_from_tree_1): Do not create
15657         DW_OP_GNU_variable_value for DECL_IGNORED_P decls.
15659 2017-05-16  Richard Biener  <rguenther@suse.de>
15661         * dwarf2out.c (resolve_variable_value_in_expr): Lookup DIE
15662         just generated.
15663         (note_variable_value_in_expr): If we resolved the decl ref
15664         do not push to the stack.
15666 2017-05-16  Matthew Wahab  <matthew.wahab@arm.com>
15668         * config/arm/arm_neon.h (vadd_f16): Use standard arithmetic
15669         operations in fast-math mode.
15670         (vaddq_f16): Likewise.
15671         (vmul_f16): Likewise.
15672         (vmulq_f16): Likewise.
15673         (vsub_f16): Likewise.
15674         (vsubq_f16): Likewise.
15675         * config/arm/neon.md (add<mode>3): New.
15676         (sub<mode>3): New.
15677         (fma:<VH:mode>3): New.  Also remove outdated comment.
15678         (mul<mode>3): New.
15680 2017-05-16  Martin Liska  <mliska@suse.cz>
15682         PR ipa/79849.
15683         PR ipa/79850.
15684         * ipa-devirt.c (warn_types_mismatch): Fix typo.
15685         (odr_types_equivalent_p): Likewise.
15687 2017-05-15  Sylvestre Ledru  <sylvestre@debian.org>
15689         * plugin.c (try_init_one_plugin): Fix ressource leaks (CID 726637).
15691 2017-05-15  Uros Bizjak  <ubizjak@gmail.com>
15693         PR target/80425
15694         * config/i386.i386.md (*zero_extendsidi2): Do not penalize
15695         non-interunit SSE move alternatives with '?'.
15696         (zero-extendsidi peephole2): New peephole to skip intermediate
15697         general register in SSE zero-extend sequence.
15699 2017-05-15  Jeff Law  <law@redhat.com>
15701         * reorg.c (relax_delay_slots): Create a new variable to hold
15702         the temporary target rather than clobbering TARGET_LABEL.
15704         * config/tilegx/tilegx.c (tilegx_expand_unaligned_load): Add
15705         missing argument to extract_bit_field call.
15706         * config/tilepro/tilepro.c (tilepro_expand_unaligned_load): Likewise.
15708 2017-05-15  Martin Liska  <mliska@suse.cz>
15710         PR driver/31468
15711         * gcc.c (process_command): Do not allow empty argument of -o option.
15713 2017-05-15  Renlin Li  <renlin.li@arm.com>
15715         * config/aarch64/aarch64-protos.h (aarch64_expand_call): Declare.
15716         * config/aarch64/aarch64.c (aarch64_expand_call): Define.
15717         * config/aarch64/constraints.md (Usf): Add long call check.
15718         * config/aarch64/aarch64.md (call): Use aarch64_expand_call.
15719         (call_value): Likewise.
15720         (sibcall): Likewise.
15721         (sibcall_value): Likewise.
15722         (call_insn): New.
15723         (call_value_insn): New.
15724         (sibcall_insn): Update rtx pattern.
15725         (sibcall_value_insn): Likewise.
15726         (call_internal): Remove.
15727         (call_value_internal): Likewise.
15728         (sibcall_internal): Likewise.
15729         (sibcall_value_internal): Likewise.
15730         (call_reg): Likewise.
15731         (call_symbol): Likewise.
15732         (call_value_reg): Likewise.
15733         (call_value_symbol): Likewise.
15735 2017-05-14  Krister Walfridsson  <krister.walfridsson@gmail.com>
15737         PR target/80600
15738         * config/netbsd.h (NETBSD_LIBGCC_SPEC): Always add -lgcc.
15740 2017-05-14  Uros Bizjak  <ubizjak@gmail.com>
15742         * config/i386.i386.c (ix86_cc_modes_compatible): CCNOmode is
15743         compatible with CCGOCmode and with CCZmode.
15745 2017-05-14  Martin Sebor  <msebor@redhat.com>
15747         PR middle-end/77671
15748         * gimple-fold.c (gimple_fold_builtin_sprintf): Make extern.
15749         (gimple_fold_builtin_snprintf): Same.
15750         * gimple-fold.h (gimple_fold_builtin_sprintf): Declare.
15751         (gimple_fold_builtin_snprintf): Same.
15752         * gimple-ssa-sprintf.c (get_format_string): Correct the detection
15753         of character types.
15754         (is_call_safe): New function.
15755         (try_substitute_return_value): Call it.
15756         (try_simplify_call): New function.
15757         (pass_sprintf_length::handle_gimple_call): Call it.
15759 2017-05-14  Martin Sebor  <msebor@redhat.com>
15761         PR middle-end/80669
15762         * builtins.c (expand_builtin_stpncpy): Simplify.
15764 2017-05-14  Daniel Santos  <daniel.santos@pobox.com>
15766         * config/i386/i386.opt: Add option -mcall-ms2sysv-xlogues.
15767         * config/i386/i386.h
15768         (x86_64_ms_sysv_extra_clobbered_registers): Change type to unsigned.
15769         (NUM_X86_64_MS_CLOBBERED_REGS): New macro.
15770         (struct machine_function): Add new members call_ms2sysv,
15771         call_ms2sysv_pad_in, call_ms2sysv_pad_out and call_ms2sysv_extra_regs.
15772         (struct machine_frame_state): New fields sp_realigned and
15773         sp_realigned_offset.
15774         * config/i386/i386.c
15775         (enum xlogue_stub): New enum.
15776         (enum xlogue_stub_sets): New enum.
15777         (class xlogue_layout): New class.
15778         (struct ix86_frame): New fields stack_realign_allocate_offset,
15779         stack_realign_offset and outlined_save_offset.  Modify comments to
15780         detail stack layout when using out-of-line stubs.
15781         (ix86_target_string): Add -mcall-ms2sysv-xlogues option.
15782         (ix86_option_override_internal): Add sorry() for TARGET_SEH and
15783         -mcall-ms2sysv-xlogues.
15784         (stub_managed_regs): New static variable.
15785         (ix86_save_reg): Add new parameter ignore_outlined to optionally omit
15786         registers managed by out-of-line stub.
15787         (disable_call_ms2sysv_xlogues): New function.
15788         (ix86_compute_frame_layout): Modify re-alignment calculations, disable
15789         m->call_ms2sysv when appropriate and compute frame layout for
15790         out-of-line stubs.
15791         (sp_valid_at, fp_valid_at): New inline functions.
15792         (choose_basereg): New function.
15793         (choose_baseaddr): Add align parameter, use choose_basereg and modify
15794         all callers.
15795         (ix86_emit_save_reg_using_mov, ix86_emit_restore_sse_regs_using_mov):
15796         Use align parameter of choose_baseaddr to generated aligned SSE movs
15797         when possible.
15798         (pro_epilogue_adjust_stack): Modify to track
15799         machine_frame_state::sp_realigned.
15800         (ix86_nsaved_regs): Modify to accommodate changes to ix86_save_reg.
15801         (ix86_nsaved_sseregs): Likewise.
15802         (ix86_emit_save_regs): Likewise.
15803         (ix86_emit_save_regs_using_mov): Likewise.
15804         (ix86_emit_save_sse_regs_using_mov): Likewise.
15805         (get_scratch_register_on_entry): Likewise.
15806         (gen_frame_set): New function.
15807         (gen_frame_load): Likewise.
15808         (gen_frame_store): Likewise.
15809         (emit_outlined_ms2sysv_save): Likewise.
15810         (emit_outlined_ms2sysv_restore): Likewise.
15811         (ix86_expand_prologue): Modify stack re-alignment code and call
15812         emit_outlined_ms2sysv_save when appropriate.
15813         (ix86_emit_leave): Clear machine_frame_state::sp_realigned.  Add
15814         parameter rtx_insn *insn, which allows the function to be used to only
15815         generate the notes.
15816         (ix86_expand_epilogue): Modify validity checks of frame and stack
15817         pointers, and call emit_outlined_ms2sysv_restore when appropriate.
15818         (ix86_expand_call): Modify to enable m->call_ms2sysv when appropriate.
15819         * config/i386/predicates.md
15820         (save_multiple): New predicate.
15821         (restore_multiple): Likewise.
15822         * config/i386/sse.md
15823         (save_multiple<mode>): New pattern.
15824         (save_multiple_realign<mode>): Likewise.
15825         (restore_multiple<mode>): Likewise.
15826         (restore_multiple_and_return<mode>): Likewise.
15827         (restore_multiple_leave_return<mode>): Likewise.
15828         * Makefile.in: Export HOSTCXX and HOSTCXXFLAGS to site.exp
15830 2017-05-14  Julia Koval  <julia.koval@intel.com>
15832         * config/i386/i386-builtin-types.def (VOID_FTYPE_INT_INT64): New type.
15833         * config/i386/i386-builtin.def (__builtin_ia32_xgetbv)
15834         (__builtin_ia32_xsetbv): New builtins.
15835         * config/i386/i386.c (ix86_expand_special_args_builtin):
15836         Process new types.
15837         (ix86_expand_builtin): Special expand for new intrinsics.
15838         * config/i386/i386.md (UNSPECV_XGETBV, UNSPECV_XSETBV): New.
15839         (xsetbv, xsetbv_rex64, xgetbv, xgetbv_rex64): New insn patterns.
15840         * config/i386/xsaveintrin.h (_xsetbv, _getbv): New intrinsics.
15842 2017-05-13  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
15844         * cfganal.c (inverted_post_order_compute): Change argument type
15845         to vec *.
15846         * cfganal.h (inverted_post_order_compute): Adjust prototype.
15847         * df-core.c (rest_of_handle_df_initialize): Adjust.
15848         (rest_of_handle_df_finish): Likewise.
15849         (df_analyze_1): Likewise.
15850         (df_analyze): Likewise.
15851         (loop_inverted_post_order_compute): Change argument to be a vec *.
15852         (df_analyze_loop): Adjust.
15853         (df_get_n_blocks): Likewise.
15854         (df_get_postorder): Likewise.
15855         * df.h (struct df_d): Change field to be a vec.
15856         * lcm.c (compute_laterin): Adjust.
15857         (compute_available): Likewise.
15858         * lra-lives.c (lra_create_live_ranges_1): Likewise.
15859         * tree-ssa-dce.c (remove_dead_stmt): Likewise.
15860         * tree-ssa-pre.c (compute_antic): Likewise.
15862 2017-05-13  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
15864         * cfganal.c (connect_infinite_loops_to_exit): Adjust.
15865         (depth_first_search::depth_first_search): Change structure init
15866         function to this constructor.
15867         (depth_first_search::add_bb): Rename function to this member.
15868         (depth_first_search::execute): Likewise.
15869         (flow_dfs_compute_reverse_finish): Adjust.
15871 2017-05-13  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
15873         * ddg.c (find_nodes_on_paths): Use auto_sbitmap.
15874         (longest_simple_path): Likewise.
15875         * shrink-wrap.c (spread_components): Likewise.
15876         (disqualify_problematic_components): Likewise.
15877         (emit_common_heads_for_components): Likewise.
15878         (emit_common_tails_for_components): Likewise.
15879         (insert_prologue_epilogue_for_components): Likewise.
15881 2017-05-13  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
15883         * tree-ssa-dse.c (dse_dom_walker): Make m_live_byes a
15884         auto_sbitmap.
15886 2017-05-13  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
15888         * df-core.c (df_set_blocks): Start using auto_bitmap.
15889         (df_compact_blocks): Likewise.
15890         * df-problems.c (df_rd_confluence_n): Likewise.
15891         * df-scan.c (df_insn_rescan_all): Likewise.
15892         (df_process_deferred_rescans): Likewise.
15893         (df_update_entry_block_defs): Likewise.
15894         (df_update_exit_block_uses): Likewise.
15895         (df_entry_block_bitmap_verify): Likewise.
15896         (df_exit_block_bitmap_verify): Likewise.
15897         (df_scan_verify): Likewise.
15898         * lra-constraints.c (lra_constraints): Likewise.
15899         (undo_optional_reloads): Likewise.
15900         (lra_undo_inheritance): Likewise.
15901         * lra-remat.c (calculate_gen_cands): Likewise.
15902         (do_remat): Likewise.
15903         * lra-spills.c (assign_spill_hard_regs): Likewise.
15904         (spill_pseudos): Likewise.
15905         * tree-ssa-pre.c (bitmap_set_and): Likewise.
15906         (bitmap_set_subtract_values): Likewise.
15908 2017-05-13  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
15910         * haifa-sched.c (estimate_shadow_tick): Replace manual bitmap
15911         management with auto_bitmap.
15912         (fix_inter_tick): Likewise.
15913         (fix_recovery_deps): Likewise.
15914         * ira.c (add_store_equivs): Likewise.
15915         (find_moveable_pseudos): Likewise.
15916         (split_live_ranges_for_shrink_wrap): Likewise.
15917         * print-rtl.c (rtx_reuse_manager::rtx_reuse_manager): Likewise.
15918         (rtx_reuse_manager::seen_def_p): Likewise.
15919         (rtx_reuse_manager::set_seen_def): Likewise.
15920         * print-rtl.h (class rtx_reuse_manager): Likewise.
15922 2017-05-13  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
15924         * bt-load.c (combine_btr_defs): Use auto_bitmap to manage bitmap
15925         lifetime.
15926         (migrate_btr_def): Likewise.
15927         * cfgloop.c (get_loop_body_in_bfs_order): Likewise.
15928         * df-core.c (loop_post_order_compute): Likewise.
15929         (loop_inverted_post_order_compute): Likewise.
15930         * hsa-common.h: Likewise.
15931         * hsa-gen.c (hsa_bb::~hsa_bb): Likewise.
15932         * init-regs.c (initialize_uninitialized_regs): Likewise.
15933         * ipa-inline.c (resolve_noninline_speculation): Likewise.
15934         (inline_small_functions): Likewise.
15935         * ipa-reference.c (ipa_reference_write_optimization_summary): Likewise.
15936         * ira.c (combine_and_move_insns): Likewise.
15937         (build_insn_chain): Likewise.
15938         * loop-invariant.c (find_invariants): Likewise.
15939         * lower-subreg.c (propagate_pseudo_copies): Likewise.
15940         * predict.c (tree_predict_by_opcode): Likewise.
15941         (predict_paths_leading_to): Likewise.
15942         (predict_paths_leading_to_edge): Likewise.
15943         (estimate_loops_at_level): Likewise.
15944         (estimate_loops): Likewise.
15945         * shrink-wrap.c (try_shrink_wrapping): Likewise.
15946         (spread_components): Likewise.
15947         * tree-cfg.c (remove_edge_and_dominated_blocks): Likewise.
15948         * tree-loop-distribution.c (rdg_build_partitions): Likewise.
15949         * tree-predcom.c (tree_predictive_commoning_loop): Likewise.
15950         * tree-ssa-coalesce.c (coalesce_ssa_name): Likewise.
15951         * tree-ssa-phionlycprop.c (pass_phi_only_cprop::execute): Likewise.
15952         * tree-ssa-pre.c (remove_dead_inserted_code): Likewise.
15953         * tree-ssa-sink.c (nearest_common_dominator_of_uses): Likewise.
15954         * tree-ssa-threadupdate.c (compute_path_counts): Likewise.
15955         (mark_threaded_blocks): Likewise.
15956         (thread_through_all_blocks): Likewise.
15957         * tree-ssa.c (verify_ssa): Likewise.
15958         (execute_update_addresses_taken): Likewise.
15959         * tree-ssanames.c (verify_ssaname_freelists): Likewise.
15961 2017-05-13  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
15963         * cfganal.c (mark_dfs_back_edges): Replace manual stack with
15964         auto_vec.
15965         (post_order_compute): Likewise.
15966         (inverted_post_order_compute): Likewise.
15967         (pre_and_rev_post_order_compute_fn): Likewise.
15969 2017-05-13  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
15971         * genrecog.c (int_set::int_set): Explicitly construct our
15972         auto_vec base class.
15973         * vec.h (auto_vec::auto_vec): New constructor.
15975 2017-05-13  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
15977         * bitmap.h (class auto_bitmap): New constructor taking
15978         bitmap_obstack * argument.
15980 2017-05-13  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
15982         * bitmap.h (class auto_bitmap): Change type of m_bits to
15983         bitmap_head, and adjust ctor / dtor and member operators.
15985 2017-05-13  Uros Bizjak  <ubizjak@gmail.com>
15987         * compare-elim.c (equivalent_reg_at_start): Return NULL_RTX
15988         when returned register mode doesn't match original mode.
15990 2017-05-12  Jeff Law  <law@redhat.com>
15991             Jakub Jelinek  <jakub@redhat.com>
15993         * config/mn10300/mn10300.c (mn10300_match_ccmode): Fix where
15994         we look for cc setter after the compare-elim changes.
15995         * config/mn10300/mn10300.md (addsi3_flags): Fix order of patterns
15996         within the vector to match what compare-elim now expects.
15997         (subsi3_flags, andsi3_flags, iorsi3_flags): Likewise.
15998         (xorsi3_flags, one_cmplsi2_flags): Likewise.
16000         * config/rx/rx.c (rx_match_ccmode): Fix where we look cc setter
16001         after the compare-elim changes.
16002         * config/rx/rx.md (abssi2_flags): Fix order of patterns within
16003         the vector to match what compare-elim now expects.
16004         (addsi3_flags, adc_flags, addsi3_flags peepholes): Likewise.
16005         (andsi3_flags, negsi2_flags, one_cmplsi2_flags): Likewise.
16006         (iorsi3_flags, rotlsi3_flags, rotrsi3_flags): Likewise.
16007         (ashrsi3_flags, lshrsi3_flags, ashlsi3_flags): Likewise.
16008         (ssaddsi3, subsi3_flags, sbb_flags, xorsi3_flags): Likewise.
16010         * config/visium/visium.c (single_set_and_flags): Fix where
16011         we look for cc setter after the compare-elim changes.
16012         * config/visium/visium.md (flags_subst_logic): Fix order of patterns
16013         with the vector to match what compare-elim now expects.
16014         (flags_subst_arith, add<mode>3_insn_set_carry): Likewise.
16015         (add<mode>3_insn_set_overflow, addsi3_insn_set_carry): Likewise.
16016         (addsi3_insn_set_overflow, sub<mode>3_insn_set_carry): Likewise.
16017         (sub<mode>3_insn_set_overflow, subsi3_insn_set_carry): Likewise.
16018         (subsi3_insn_set_overflow, negsi2_insn_set_carry): Likewise.
16019         (neg<mode>2_insn_set_overflow): Likewise.
16021 2017-05-12  Jim Wilson  <jim.wilson@linaro.org>
16023         PR middle-end/79794
16024         * expmed.c (extract_bit_field_1): Add alt_rtl argument.  Before
16025         maybe_expand_insn call, set ops[0].target.  If still set after call,
16026         set alt_rtl.  Add extra arg to recursive calls.
16027         (extract_bit_field): Add alt_rtl argument.  Pass to
16028         extract_bit_field.
16029         * expmed.h (extract_bit_field): Fix prototype.
16030         * expr.c (emit_group_load_1, copy_blkmode_from_reg)
16031         (copy_blkmode_to_reg, read_complex_part, store_field): Pass extra NULL
16032         to extract_bit_field_calls.
16033         (expand_expr_real_1): Pass alt_rtl to expand_expr_real instead of 0.
16034         Pass alt_rtl to extract_bit_field calls.
16035         * calls.c (store_unaligned_arguments_into_psuedos)
16036         load_register_parameters): Pass extra NULL to extract_bit_field calls.
16037         * optabs.c (maybe_legitimize_operand): Clear op->target when call
16038         gen_reg_rtx.
16039         * optabs.h (struct expand_operand): Add target bitfield.
16041 2017-05-12  Uros Bizjak  <ubizjak@gmail.com>
16043         * compare-elim.c (try_eliminate_compare): Canonicalize
16044         operation with embedded compare to
16045         [(set (reg:CCM) (compare:CCM (operation) (immediate)))
16046          (set (reg) (operation)].
16048         * config/i386/i386.c (TARGET_FLAGS_REGNUM): New define.
16050 2017-05-12  Uros Bizjak  <ubizjak@gmail.com>
16052         PR target/80723
16053         * config/i386/i386.c (ix86_rtx_cost) [case PLUS]: Ignore the
16054         cost of adding a carry flag for ADC instruction.
16055         [case MINUS]: Ignore the cost of subtracting a carry flag
16056         for SBB instruction.
16058 2017-05-12  Steven Munroe  <munroesj@gcc.gnu.org>
16060         * config.gcc (powerpc*-*-*): Add bmi2intrin.h, bmiintrin.h,
16061         and x86intrin.h
16062         * config/rs6000/bmiintrin.h: New file.
16063         * config/rs6000/bmi2intrin.h: New file.
16064         * config/rs6000/x86intrin.h: New file.
16066 2017-05-12  Jeff Law  <law@redhat.com>
16068         * tree-vrp.c (vrp_dom_walker::before_dom_children): Push unwinding
16069         markers.
16071 2017-05-12  Peter Bergner  <bergner@vnet.ibm.com>
16073         PR middle-end/80707
16074         * tree-cfg.c: Remove cfg edges of unreachable case statements.
16076 2017-05-12  Will Schmidt  <will_schmidt@vnet.ibm.com>
16078         * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Add handling for
16079         early expansion of vector divide builtins.
16080         (builtin_function_type): Add VSX_BUILTIN_UDIV_V2DI to the list of
16081         builtins identified as having unsigned arguments.
16083 2017-05-12  Will Schmidt  <will_schmidt@vnet.ibm.com>
16085         * config/rs6000/rs6000.c (gimple-fold.h): New #include.
16086         (rs6000_gimple_fold_builtin): Add handling for early GIMPLE
16087         expansion of vector logical operations (and, andc, or, xor,
16088         nor, orc, nand).
16090 2017-05-12  Will Schmidt  <will_schmidt@vnet.ibm.com>
16092         * gimple-fold.c (create_tmp_reg_or_ssa_name): Remove static declaration.
16093         * gimple-fold.h (create_tmp_reg_or_ssa_name): New prototype.
16095 2017-05-12  Will Schmidt  <will_schmidt@vnet.ibm.com>
16097         * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Add handling for
16098         early GIMPLE expansion of vector multiplies.
16100 2017-05-12  Prakhar Bahuguna  <prakhar.bahuguna@arm.com>
16102         * config/arm/arm.md (movsi): Add TARGET_32BIT in addition to the
16103         TARGET_HAVE_MOVT conditional.
16104         (movt splitter): Likewise.
16106 2017-05-12  Richard Biener  <rguenther@suse.de>
16108         * tree-ssa-sccvn.h (has_VN_INFO): Declare.
16109         * tree-ssa-pre.c (eliminate_dom_walker::before_dom_children):
16110         Fold all stmts not inplace.
16112 2017-05-12  Richard Biener  <rguenther@suse.de>
16114         PR tree-optimization/80713
16115         * tree-ssa-pre.c (remove_dead_inserted_code): Clear
16116         inserted_exprs bit for not removed stmts.
16118 2017-05-12  Thomas Schwinge  <thomas@codesourcery.com>
16120         PR middle-end/69921
16121         * tree-parloops.c (create_parallel_loop): Set "oacc kernels
16122         parallelized" attribute for parallelized OpenACC kernels.
16123         * omp-offload.c (execute_oacc_device_lower): Use it.
16125         * omp-expand.c (expand_omp_target) <GF_OMP_TARGET_KIND_OACC_KERNELS>:
16126         Set "oacc kernels" attribute.
16127         * omp-general.c (oacc_set_fn_attrib): Remove is_kernel formal
16128         parameter.  Adjust all users.
16129         (oacc_fn_attrib_kernels_p): Remove function.
16130         * omp-offload.c (execute_oacc_device_lower): Look for "oacc
16131         kernels" attribute instead of calling oacc_fn_attrib_kernels_p.
16132         * tree-ssa-loop.c (gate_oacc_kernels): Likewise.
16133         * tree-parloops.c (create_parallel_loop): If oacc_kernels_p,
16134         assert "oacc kernels" attribute is set.
16136 2017-05-11  Carl Love  <cel@us.ibm.com>
16138         * config/rs6000/rs6000-c: Add support for built-in functions
16139         vector unsigned char vec_popcnt (vector signed char)
16140         vector unsigned char vec_popcnt (vector unsigned char)
16141         vector unsigned short vec_popcnt (vector signed short)
16142         vector unsigned short vec_popcnt (vector unsigned short)
16143         vector unsigned int vec_popcnt (vector signed int)
16144         vector unsigned int vec_popcnt (vector unsigned int)
16145         vector unsigned long long vec_popcnt (vector signed long long)
16146         vector unsigned long long vec_popcnt (vector unsigned long long)
16147         vector signed long long vec_slo (vector signed long long,
16148                                          vector signed char)
16149         vector signed long long vec_slo (vector signed long long,
16150                                          vector unsigned char)
16151         vector unsigned long long vec_slo (vector unsigned long long,
16152                                            vector signed char)
16153         vector unsigned long long vec_slo (vector unsigned long long,
16154                                            vector unsigned char)
16155         * config/rs6000/rs6000-builtin.def: Add definitions for VPOPCNTUB,
16156         VPOPCNTUH, VPOPCNTUW, and VPOPCNTUD overloads.
16157         * config/rs6000/altivec.h: Add define for vec_popcnt, vec_popcntb,
16158         vec_popcnth, vec_popcntw and vec_popcntd built-in functions.
16159         * doc/extend.texi: Update the built-in documentation file for the
16160         new built-in functions.
16162 2017-05-11  Michael Meissner  <meissner@linux.vnet.ibm.com>
16164         * attribs.h (sorted_attr_string): Move machine independent
16165         functions for target clone support from the i386 port to common
16166         code.  Rename ix86_function_versions to common_function_versions.
16167         Rename make_name to make_unique_name.
16168         (common_function_versions): Likewise.
16169         (make_unique_name): Likewise.
16170         (make_dispatcher_decl): Likewise.
16171         (is_function_default_version): Likewise.
16172         * attribs.c (attr_strcmp): Likewise.
16173         (sorted_attr_string): Likewise.
16174         (common_function_versions): Likewise.
16175         (make_unique_name): Likewise.
16176         (make_dispatcher_decl): Likewise.
16177         (is_function_default_version): Likewise.
16178         * config/i386/i386.c (attr_strcmp): Likewise.
16179         (sorted_attr_string): Likewise.
16180         (ix86_function_versions): Likewise.
16181         (make_name): Likewise.
16182         (make_dispatcher_decl): Likewise.
16183         (is_function_default_version): Likewise.
16184         (TARGET_OPTION_FUNCTION_VERSIONS): Update target function hook.
16186 2017-05-11  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
16188         PR target/80695
16189         * config/rs6000/rs6000.c (rs6000_builtin_vectorization_cost):
16190         Account for direct move costs for vec_construct of integer
16191         vectors.
16193 2017-05-11  Uros Bizjak  <ubizjak@gmail.com>
16195         PR target/80706
16196         * config/i386/sync.md (UNSPEC_LDX_ATOMIC): New unspec.
16197         (UNSPEC_STX_ATOMIC): Ditto.
16198         (loaddi_via_sse): New insn.
16199         (storedi_via_sse): Ditto.
16200         (atomic_loaddi_fpu): Emit loaddi_via_sse and storedi_via_sse.
16201         Update corresponding peephole2 patterns.
16202         (atomic_storedi_fpu): Ditto.
16204 2017-05-11  Julia Koval  <julia.koval@intel.com>
16206         * config/i386/avx512fintrin.h (_mm_mask_rsqrt14_sd)
16207         (_mm_maskz_rsqrt14_sd, _mm_mask_rsqrt14_ss, _mm_maskz_rsqrt14_ss):
16208         New intrinsics.
16209         * config/i386/i386-builtin.def (__builtin_ia32_rsqrt14sd_mask)
16210         (__builtin_ia32_rsqrt14ss_mask): New builtins.
16211         * config/i386/sse.md (rsqrt14_<mode>_mask): New pattern.
16213 2017-05-11  Nathan Sidwell  <nathan@acm.org>
16215         * graphite-poly.c: Include dumpfile.h.
16217         * dumpfle.h (dump_function): Declare here ...
16218         * tree-dump.h (dump_function): ... not here.
16219         * dumpfile.c: #include tree-cfg.h.
16220         (dump_function): Move here from ...
16221         * tree-dump.c (dump_function): ... here.
16222         * gimplify.c: #include splay-tree.h, not tree-dump.h.
16223         * graphite-poly.c: Don't include tree-dump.h.
16224         * cgraphclones.c: Include dumpfile.h not tree-dump.h.
16225         * print-tree.c: Likewise.
16226         * stor-layout.c: Likewise.
16227         * tree-nested.c: Likewise.
16229         * dumpfile.c (dump_start): Use TDF_FLAGS.
16230         (dump_enable_all): Fix TDF_KIND check thinko.
16232 2017-05-11  Kelvin Nilsen  <kelvin@gcc.gnu.org>
16234         * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Add
16235         array entries to represent two legal parameterizations of the
16236         overloaded __builtin_cmpb function, as represented by the
16237         P6_OV_BUILTIN_CMPB constant.
16238         (altivec_resolve_overloaded_builtin): Add special case handling
16239         for the __builtin_cmpb function, as represented by the
16240         P6_OV_BUILTIN_CMPB constant.
16241         * config/rs6000/rs6000-builtin.def (BU_P6_2): New macro.
16242         (BU_P6_64BIT_2): New macro.
16243         (BU_P6_OVERLOAD_2): New macro
16244         (CMPB_32): Add 32-bit compare-bytes support for 32-bit only targets.
16245         (CMPB): Add 64-bit compare-bytes support for 32-bit and 64-bit targets.
16246         (CMPB): Add overload support to represent both 32-bit and 64-bit
16247         compare-bytes function.
16248         * config/rs6000/rs6000.c (rs6000_builtin_mask_calculate): Add
16249         support for TARGET_CMPB.
16250         * config/rs6000/rs6000.h: Add support for RS6000_BTM_CMPB.
16251         * doc/extend.texi (PowerPC AltiVec Built-in Functions): Add
16252         documentation of the __builtin_cmpb overloaded built-in function.
16254 2017-05-11  Richard Biener  <rguenther@suse.de>
16256         PR tree-optimization/80705
16257         * tree-vect-data-refs.c (vect_analyze_data_refs): DECL_NONALIASED
16258         bases are not vectorizable.
16260 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
16262         * tree-ssa-loop-ivopts.c (determine_set_costs): Skip non-interger
16263         when counting register pressure.
16265 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
16267         * tree-ssa-loop-ivopts.c (compare_cost_pair): New.
16268         (iv_ca_more_deps): Renamed to ...
16269         (iv_ca_compare_deps): ... this.
16270         (iv_ca_extend): Extend iv_ca if NEW_CP is cheaper than OLD_CP.
16272 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
16274         * tree-ssa-loop-ivopts.c (find_interesting_uses): Move inv vars dump
16275         to ...
16276         (determine_group_iv_costs): ... here.
16277         (find_inv_vars_cb): Record inv var if it's not recorded before.
16279 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
16281         * tree-ssa-loop-ivopts.c (allow_ip_end_pos_p): Refine comments.
16282         (get_shiftadd_cost): Ditto.
16284 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
16286         * tree-ssa-address.c: Include header file.
16287         (move_hint_to_base): Return TRUE if BASE_HINT is moved to memory
16288         address.
16289         (add_to_parts): Refactor.
16290         (addr_to_parts): New parameter.  Update use of move_hint_to_base.
16291         (create_mem_ref): Update use of addr_to_parts.  Re-associate addr
16292         in new order.
16294 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
16296         PR tree-optimization/53090
16297         * tree-ssa-loop-ivopts.c (enum comp_iv_rewrite): New enum value
16298         COMP_IV_EXPR_2.
16299         (extract_cond_operands): Detect condition with IV on both sides
16300         and return COMP_IV_EXPR_2.
16301         (find_interesting_uses_cond): Add iv_use for both IVs in condition.
16302         (rewrite_use_compare): Simplify by removing call to function
16303         extract_cond_operands.
16305 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
16307         * tree-ssa-loop-ivopts.c (enum comp_iv_rewrite): New.
16308         (extract_cond_operands): Detect condition comparing against non-
16309         invariant bound and return appropriate enum value.
16310         (find_interesting_uses_cond): Update use of extract_cond_operands.
16311         Handle its return value accordingly.
16312         (determine_group_iv_cost_cond, rewrite_use_compare): Ditto.
16314 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
16316         * tree-ssa-loop-ivopts.c (rewrite_use_nonlinear_expr): Re-associate
16317         nonlinear iv_use computation in loop invariant sensitive way.
16319 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
16321         * tree-ssa-loop-ivopts.c (relate_compare_use_with_all_cands): New.
16322         (find_iv_candidates): Call relate_compare_use_with_all_cands.
16324 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
16326         * tree-ssa-loop-ivopts.c (struct iv_cand): New field inv_exprs.
16327         (dump_cand): Support iv_cand.inv_exprs.
16328         (add_candidate_1): Record invariant exprs in iv_cand.inv_exprs
16329         for candidates.
16330         (iv_ca_set_no_cp, iv_ca_set_cp, free_loop_data): Support
16331         iv_cand.inv_exprs.
16333 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
16335         * tree-ssa-loop-ivopts.c (multiplier_allowed_in_address_p): Move
16336         from ...
16337         * tree-ssa-address.c (multiplier_allowed_in_address_p): ... to here
16338         as local function.  Include necessary header files.
16339         * tree-ssa-loop-ivopts.h (multiplier_allowed_in_address_p): Delete.
16341 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
16343         * tree-ssa-loop-ivopts.c (autoinc_possible_for_pair): Simplify.
16345 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
16347         * tree-ssa-loop-ivopts.c (force_expr_to_var_cost): Handle more
16348         operators: TRUNC_DIV_EXPR, BIT_AND_EXPR, BIT_IOR_EXPR, LSHIFT_EXPR,
16349         RSHIFT_EXPR and BIT_NOT_EXPR.
16351 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
16353         * tree-ssa-loop-ivopts.c (get_loop_invariant_expr): Simplify.
16354         (adjust_setup_cost): New parameter supporting round up adjustment.
16355         (struct address_cost_data): Delete.
16356         (force_expr_to_var_cost): Don't bound cost with spill_cost.
16357         (split_address_cost, ptr_difference_cost): Delete.
16358         (difference_cost, compare_aff_trees, record_inv_expr): Delete.
16359         (struct ainc_cost_data): New struct.
16360         (get_address_cost_ainc): New function.
16361         (get_address_cost, get_computation_cost): Reimplement.
16362         (determine_group_iv_cost_address): Record inv_expr for all uses of
16363         a group.
16364         (determine_group_iv_cost_cond): Call get_loop_invariant_expr.
16365         (iv_ca_has_deps): Reimplemented to ...
16366         (iv_ca_more_deps): ... this.  Check if NEW_CP introduces more deps
16367         than OLD_CP.
16368         (iv_ca_extend): Call iv_ca_more_deps.
16370 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
16372         * tree-ssa-address.c (struct mem_address): Move to header file.
16373         (valid_mem_ref_p, move_fixed_address_to_symbol): Make it global.
16374         * tree-ssa-address.h (struct mem_address): Move from C file.
16375         (valid_mem_ref_p, move_fixed_address_to_symbol): Declare.
16377 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
16379         * tree-affine.h (aff_combination_type): New interface.
16380         (aff_combination_zero_p): Remove static.
16381         (aff_combination_const_p): New interface.
16382         (aff_combination_singleton_var_p): New interfaces.
16384 2017-05-11  Richard Biener  <rguenther@suse.de>
16386         * tree-ssa-pre.c (eliminate_dom_walker::before_dom_children):
16387         Skip unreachable blocks and destinations.
16388         (eliminate): Move stmt removal and fixup ...
16389         (fini_eliminate): ... here.  Skip inserted exprs.
16390         (pass_pre::execute): Move fini_pre after fini_eliminate.
16391         * tree-ssa-tailmerge.c: Include tree-cfgcleanup.h.
16392         (tail_merge_optimize): Run cleanup_tree_cfg if requested by
16393         PRE to get rid of dead code that has invalid SSA form and
16394         split critical edges again.
16396 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
16398         * rtlanal.c (rtx_cost): Handle TRUNCATE between tieable modes.
16400 2017-05-11  Richard Biener  <rguenther@suse.de>
16402         * passes.c (execute_function_todo): Verify loops if they are
16403         said to be up-to-date.
16404         * cfgexpand.c (pass_expand::execute): Discard loops for -dx.
16405         * trans-mem.c (pass_tm_edges::execute): Mark loops for fixup.
16407 2017-05-10  John David Anglin  <danglin@gcc.gnu.org>
16409         PR target/80090
16410         * config/pa/pa.c (pa_assemble_integer): When outputting a SYMBOL_REF,
16411         handle calling assemble_external ourself.
16413         PR target/79027
16414         * config/pa/pa.c (pa_cannot_change_mode_class): Reject changes to/from
16415         modes with zero size.  Enhance comment.
16417 2017-05-10  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
16419         * config/rs6000/rs6000.c (altivec_init_builtins): Define POWER8
16420         built-ins for vec_xl and vec_xst with short and char pointer
16421         arguments.
16423 2017-05-10  Sebastian Peryt  <sebastian.peryt@intel.com>
16425         * config/i386/avx512fintrin.h (_mm_mask_max_round_sd)
16426         (_mm_maskz_max_round_sd, _mm_mask_max_round_ss)
16427         (_mm_maskz_max_round_ss, _mm_mask_min_round_sd)
16428         (_mm_maskz_min_round_sd, _mm_mask_min_round_ss)
16429         (_mm_maskz_min_round_ss): New intrinsics.
16430         * config/i386/i386-builtin-types.def (V2DF, V2DF, V2DF, V2DF, UQI, INT)
16431         (V4SF, V4SF, V4SF, V4SF, UQI, INT): New function type aliases.
16432         * config/i386/i386-builtin.def (__builtin_ia32_maxsd_mask_round)
16433         (__builtin_ia32_maxss_mask_round, __builtin_ia32_minsd_mask_round)
16434         (__builtin_ia32_minss_mask_round): New builtins.
16435         * config/i386/i386.c (V2DF_FTYPE_V2DF_V2DF_V2DF_UQI_INT)
16436         (V4SF_FTYPE_V4SF_V4SF_V4SF_UQI_INT): Handle new types.
16437         * config/i386/sse.md (<sse>_vm<code><mode>3<round_saeonly_name>):
16438         Rename to ...
16439         (<sse>_vm<code><mode>3<mask_name><round_saeonly_name>): ... this.
16440         (v<maxmin_float><ssescalarmodesuffix>\t{<round_saeonly_op3>%2, %1, %0|%0, %1, %<iptr>2<round_saeonly_op3>}):
16441         Change to ...
16442         (v<maxmin_float><ssescalarmodesuffix>\t{<round_saeonly_mask_op3>%2, %1, %0<mask_operand3>|%0<mask_operand3>, %1, %<iptr>2<round_saeonly_mask_op3>}):
16443         ... this.
16445 2017-05-10  Sebastian Peryt  <sebastian.peryt@intel.com>
16447         * config/i386/avx512fintrin.h (_mm_mask_mul_round_sd)
16448         (_mm_maskz_mul_round_sd, _mm_mask_mul_round_ss)
16449         (_mm_maskz_mul_round_ss, _mm_mask_div_round_sd)
16450         (_mm_maskz_div_round_sd, _mm_mask_div_round_ss)
16451         (_mm_maskz_div_round_ss, _mm_mask_mul_sd, _mm_maskz_mul_sd)
16452         (_mm_mask_mul_ss, _mm_maskz_mul_ss, _mm_mask_div_sd)
16453         (_mm_maskz_div_sd, _mm_mask_div_ss, _mm_maskz_div_ss): New intrinsics.
16454         * config/i386/i386-builtin-types.def (V2DF_FTYPE_V2DF_V2DF_V2DF_UQI_INT)
16455         (V4SF_FTYPE_V4SF_V4SF_V4SF_UQI_INT): New function type aliases.
16456         * config/i386/i386-builtin.def (__builtin_ia32_divsd_mask_round)
16457         (__builtin_ia32_divss_mask_round, __builtin_ia32_mulsd_mask_round)
16458         (__builtin_ia32_mulss_mask_round): New builtins.
16459         * config/i386/i386.c (V2DF_FTYPE_V2DF_V2DF_V2DF_UQI_INT)
16460         (V4SF_FTYPE_V4SF_V4SF_V4SF_UQI_INT): Handle new types.
16461         * config/i386/sse.md (<sse>_vm<multdiv_mnemonic><mode>3<round_name>):
16462         Rename to ...
16463         (<sse>_vm<multdiv_mnemonic><mode>3<mask_name><round_name>): ... this.
16464         (v<multdiv_mnemonic><ssescalarmodesuffix>\t{<round_op3>%2, %1, %0|%0, %1, %<iptr>2<round_op3>}):
16465         Change to ...
16466         (v<multdiv_mnemonic><ssescalarmodesuffix>\t{<round_mask_op3>%2, %1, %0<mask_operand3>|%0<mask_operand3>, %1, %<iptr>2<round_mask_op3>}):
16467         ... this.
16469 2017-05-10  Julia Koval  <julia.koval@intel.com>
16471         * config/i386/avxintrin.h (_mm256_set_m128, _mm256_set_m128d)
16472         (_mm256_set_m128i, _mm256_setr_m128, _mm256_setr_m128d)
16473         (_mm256_setr_m128i): New intrinsics.
16475 2017-05-10  Julia Koval  <julia.koval@intel.com>
16477         * config/i386/avx512fintrin.h (_mm_mask_rcp14_sd)
16478         (_mm_maskz_rcp14_sd, _mm_mask_rcp14_ss)
16479         (_mm_maskz_rcp14_ss): New intrinsics.
16480         * config/i386/i386-builtin.def (__builtin_ia32_rcp14sd_mask)
16481         (__builtin_ia32_rcp14ss_mask): New builtins.
16482         * config/i386/sse.md (srcp14<mode>_mask): New pattern.
16484 2017-05-10  Peter Bergner  <bergner@vnet.ibm.com>
16486         PR tree-optimization/51513
16487         * tree-cfg.c (gimple_seq_unreachable_p): New function.
16488         (assert_unreachable_fallthru_edge_p): Use it.
16489         (group_case_labels_stmt): Likewise.
16490         * tree-cfg.h: Prototype it.
16491         * stmt.c: Include cfghooks.h and tree-cfg.h.
16492         (emit_case_dispatch_table) <gap_label>: New local variable.
16493         Use it to fill dispatch table gaps.
16494         Test for default_label before updating probabilities.
16495         (expand_case) <default_label>: Remove unneeded initialization.
16496         Test for unreachable default case statement and remove its edge.
16497         Set default_label accordingly.
16498         * tree-ssa-ccp.c (optimize_unreachable): Update comment.
16500 2017-05-10  Carl Love  <cel@us.ibm.com>
16502         * config/rs6000/rs6000-c: Add support for built-in functions
16503         vector signed char      vec_neg (vector signed char)
16504         vector signed short int vec_neg (vector short int)
16505         vector signed int       vec_neg (vector signed int)
16506         vector signed long long vec_neg (vector signed long long)
16507         vector float            vec_neg (vector float)
16508         vector double           vec_neg (vector double)
16509         * config/rs6000/rs6000-builtin.def: Add definitions for NEG function
16510         overload.
16511         * config/rs6000/altivec.h: Add define for vec_neg
16512         * doc/extend.texi: Update the built-in documentation for the
16513         new built-in functions.
16515 2017-05-10  Prathamesh Kulkarni  <prathamesh.kulkarni@linaro.org>
16517         PR tree-optimization/77644
16518         * match.pd (sqrt(x) cmp sqrt(y) -> x cmp y): New pattern.
16520 2017-05-10  Nathan Sidwell  <nathan@acm.org>
16522         * dumpfile.h (TDI_lang_all): New.
16523         (TDF_KIND): New. Renumber others
16524         (TDF_LANG, TDF_TREE, TDF_RTL, TDF_IPA): Enumerate value, rather
16525         than bits.
16526         * dumpfile.c (dump_files): Mark language dumps as TDF_LANG.  add
16527         lang-all.
16528         (get_dump_file_name): Adjust suffix generation.
16529         (dump_enable_all): Use TDF_KIND.
16530         * doc/invoke.texi (-fdump-lang-all): Document.
16532         * dumpfile.h: Tabify.
16534 2017-05-10  Wilco Dijkstra  <wdijkstr@arm.com>
16536         PR target/80671
16537         * config/aarch64/cortex-a57-fma-steering.c (merge_forest):
16538         Move member access before delete.
16540 2017-05-10  Alexandre Oliva <aoliva@redhat.com>
16542         * tree-inline.c (expand_call_inline): Split block at stmt
16543         before the call.
16545 2017-05-09  Michael Meissner  <meissner@linux.vnet.ibm.com>
16547         PR target/68163
16548         * config/rs6000/rs6000.md (f32_lr): Delete mode attributes that
16549         are now unused after splitting mov{sf,sd}_hardfloat.
16550         (f32_lr2): Likewise.
16551         (f32_lm): Likewise.
16552         (f32_lm2): Likewise.
16553         (f32_li): Likewise.
16554         (f32_li2): Likewise.
16555         (f32_lv): Likewise.
16556         (f32_sr): Likewise.
16557         (f32_sr2): Likewise.
16558         (f32_sm): Likewise.
16559         (f32_sm2): Likewise.
16560         (f32_si): Likewise.
16561         (f32_si2): Likewise.
16562         (f32_sv): Likewise.
16563         (f32_dm): Likewise.
16564         (f32_vsx): Likewise.
16565         (f32_av): Likewise.
16566         (mov<mode>_hardfloat): Split into separate movsf and movsd pieces.
16567         For movsf, order stores so the VSX stores occur before the GPR
16568         store which encourages the register allocator to use a traditional
16569         FPR instead of a GPR.  For movsd, order the stores so that the GPR
16570         store comes before the VSX stores to allow the power6 to work.
16571         This is due to the power6 not having a 32-bit integer store
16572         instruction from a FPR.
16573         (movsf_hardfloat): Likewise.
16574         (movsd_hardfloat): Likewise.
16576 2017-05-09  Martin Sebor  <msebor@redhat.com>
16578         PR translation/80280
16579         * config/sol2-c.c (cmn_err_flag_specs): Initialize new data member
16580         added in r247778.
16582         PR translation/80280
16583         * config/i386/msformat-c.c (ms_printf_flag_specs): Initialize new
16584         data member added in r247778.
16585         (ms_scanf_flag_specs, ms_strftime_flag_specs): Same.
16587 2017-05-09  Nathan Sidwell  <nathan@acm.org>
16589         * tree.h (tree_fits_shwi_p, tree_fits_uhwi_p): Unconditionally pure.
16591         * ipa-devirt.c (default_hash_traits<type_pair>): Skip struct-scope
16592         typedefs.
16594 2017-05-09  Marek Polacek  <polacek@redhat.com>
16596         * doc/invoke.texi: Fix typo.
16598 2017-05-09  Richard Biener  <rguenther@suse.de>
16600         * tree-vrp.c (vrp_val_is_max): Adjust comment.
16601         (vrp_val_is_min): Likewise.
16602         (set_value_range_to_value): Likewise.
16603         (set_value_range_to_nonnegative): Likewise.
16604         (gimple_assign_nonzero_p): Likewise.
16605         (gimple_stmt_nonzero_p): Likewise.
16606         (vrp_int_const_binop): Likewise.  Remove unreachable case.
16607         (adjust_range_with_scev): Adjust comments.
16608         (compare_range_with_value): Likewise.
16609         (extract_range_from_phi_node): Likewise.
16610         (test_for_singularity): Likewise.
16612 2017-05-09  Richard Biener  <rguenther@suse.de>
16614         * tree-vrp.c (get_single_symbol): Add assert that we don't
16615         get overflowed constants as invariant part.
16616         (compare_values_warnv): Add comment before the TREE_NO_WARNING
16617         checks.  Use wi::cmp instead of recursing for integer constants.
16618         (compare_values): Just ignore whether we assumed undefined
16619         overflow instead of failing the compare.
16620         (extract_range_for_var_from_comparison_expr): Add comment before the
16621         TREE_NO_WARNING sets.
16622         (test_for_singularity): Likewise.
16623         (extract_range_from_comparison): Do not disable optimization
16624         when we assumed undefined overflow.
16625         (extract_range_basic): Remove init of unused var.
16627 2017-05-09  Richard Biener  <rguenther@suse.de>
16629         * tree-vrp.c (vrp_int_const_binop): Use wide-ints and simplify.
16630         (extract_range_from_multiplicative_op_1): Adjust.
16631         (extract_range_from_binary_expr_1): Use int_const_binop.
16633 2017-05-08  Kelvin Nilsen  <kelvin@gcc.gnu.org>
16635         PR target/80101
16636         * config/rs6000/power6.md: Replace store_data_bypass_p calls with
16637         rs6000_store_data_bypass_p in seven define_bypass directives and
16638         in several comments.
16639         * config/rs6000/rs6000-protos.h: Add prototype for
16640         rs6000_store_data_bypass_p function.
16641         * config/rs6000/rs6000.c (rs6000_store_data_bypass_p): New
16642         function implements slightly different (rs6000-specific) semantics
16643         than store_data_bypass_p, returning false rather than aborting
16644         with assertion error when arguments do not satisfy the
16645         requirements of store data bypass.
16646         (rs6000_adjust_cost): Replace six calls of store_data_bypass_p with
16647         rs6000_store_data_bypass_p.
16649 2017-05-08  Max Filippov  <jcmvbkbc@gmail.com>
16651         * config/xtensa/xtensa-protos.h
16652         (xtensa_initial_elimination_offset): New declaration.
16653         * config/xtensa/xtensa.c (xtensa_initial_elimination_offset):
16654         New function. Move its body from the INITIAL_ELIMINATION_OFFSET
16655         macro definition, add case for FRAME_POINTER_REGNUM when
16656         FRAME_GROWS_DOWNWARD.
16657         * config/xtensa/xtensa.h (FRAME_GROWS_DOWNWARD): New macro definition.
16658         (INITIAL_ELIMINATION_OFFSET): Replace body with call to
16659         xtensa_initial_elimination_offset.
16661 2017-05-08  Nathan Sidwell  <nathan@acm.org>
16663         * doc/invoke.texi: Alphabetize -fdump options.
16665 2017-05-08  Martin Sebor  <msebor@redhat.com>
16667         PR translation/80280
16668         * config/sol2-c.c (solaris_pragma_align): Correct quoting.
16670 2017-05-08  Bernd Edlinger  <bernd.edlinger@hotmail.de>
16672         * target.def (compute_frame_layout): New optional target hook.
16673         * doc/tm.texi.in (TARGET_COMPUTE_FRAME_LAYOUT): Add hook.
16674         * doc/tm.texi (TARGET_COMPUTE_FRAME_LAYOUT): Add documentation.
16675         * lra-eliminations.c (update_reg_eliminate): Call compute_frame_layout
16676         target hook.
16677         * reload1.c (verify_initial_elim_offsets): Likewise.
16678         * config/arm/arm.c (TARGET_COMPUTE_FRAME_LAYOUT): Define.
16679         (use_simple_return_p): Call arm_compute_frame_layout if needed.
16680         (arm_get_frame_offsets): Split up into this ...
16681         (arm_compute_frame_layout): ... and this function.
16683 2017-05-08  Richard Sandiford  <richard.sandiford@arm.com>
16685         * config/aarch64/constraints.md (Usa): New constraint.
16686         * config/aarch64/aarch64.md (*movsi_aarch64, *movdi_aarch64): Use it.
16688 2017-05-08  Thomas Preud'homme  <thomas.preudhomme@arm.com>
16690         * config.gcc (arm*-*-*): Set TM_MULTILIB_CONFIG from
16691         with_multilib_list after it has been checked.
16693 2017-05-08  Richard Biener  <rguenther@suse.de>
16695         * tree-ssa-pre.c (bitmap_set_and): Avoid bitmap copy.
16696         (bitmap_set_subtract_values): Likewise.
16698 2017-05-08  Richard Biener  <rguenther@suse.de>
16700         * tree-vrp.c (gimple_assign_nonzero_warnv_p): Rename to ...
16701         (gimple_assign_nonzero): ... this and remove strict_overflow_p
16702         argument.
16703         (gimple_stmt_nonzero_warnv_p): Rename to ...
16704         (gimple_stmt_nonzero_p): ... this and remove strict_overflow_p
16705         argument.
16706         (vrp_stmt_computes_nonzero): Remove strict_overflow_p argument.
16707         (extract_range_basic): Adjust, do not disable propagation on
16708         strict overflow sensitive simplification.
16709         (vrp_visit_cond_stmt): Likewise.
16711 2017-05-05  Jan Hubicka  <hubicka@ucw.cz>
16713         * ipa-inline-analysis.c (estimate_function_body_sizes): Recompute
16714         body size unconditionally.
16716 2017-05-07  Jeff Law  <law@redhat.com>
16718         Revert:
16719         2017-05-06  Jeff Law  <law@redhat.com>
16720         PR tree-optimization/78496
16721         * tree-vrp.c (simplify_assert_expr_using_ranges): Remove debugging
16722         code.
16724         PR tree-optimization/78496
16725         * tree-vrp.c (simplify_assert_expr_using_ranges): New function.
16726         (simplify_stmt_using_ranges): Call it.
16727         (vrp_dom_walker::before_dom_children): Extract equivalences
16728         from an ASSERT_EXPR with an equality comparison against a
16729         constant.
16731 2017-05-06  Jeff Law  <law@redhat.com>
16733         PR tree-optimization/78496
16734         * tree-vrp.c (simplify_assert_expr_using_ranges): Remove debugging
16735         code.
16737         PR tree-optimization/78496
16738         * tree-vrp.c (simplify_assert_expr_using_ranges): New function.
16739         (simplify_stmt_using_ranges): Call it.
16740         (vrp_dom_walker::before_dom_children): Extract equivalences
16741         from an ASSERT_EXPR with an equality comparison against a
16742         constant.
16744 2017-05-06  Richard Sandiford  <richard.sandiford@linaro.org>
16746         * lra-constraints.c (lra_copy_reg_equiv): New function.
16747         (split_reg): Use it to copy equivalence information from the
16748         original register to the spill register.
16750 2017-05-06  Richard Sandiford  <richard.sandiford@linaro.org>
16752         PR rtl-optimization/75964
16753         * simplify-rtx.c (simplify_const_relational_operation): Remove
16754         invalid handling of comparisons of integer ABS.
16756 2017-05-06  Uros Bizjak  <ubizjak@gmail.com>
16758         * config/i386/i386.c (ext_80387_constant_init): Do not explicitly
16759         initialize to zero.
16760         (init_regs): Remove declaration.
16761         (function_arg_advance_32): Initialize error_p as boolean variable.
16763 2017-05-05  Nathan Sidwell  <nathan@acm.org>
16765         * store-motion.c (remove_reachable_equiv_notes): Reformat long
16766         lines.  Use for (;;).
16768 2017-05-05  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
16770         * config/rs6000/rs6000.c (rs6000_vect_nonmem): New static var.
16771         (rs6000_init_cost): Initialize rs6000_vect_nonmem.
16772         (rs6000_add_stmt_cost): Update rs6000_vect_nonmem.
16773         (rs6000_finish_cost): Avoid vectorizing simple copy loops with
16774         VF=2 that require versioning.
16776 2017-05-05  David Malcolm  <dmalcolm@redhat.com>
16778         * diagnostic.h (CARET_LINE_MARGIN): Convert from macro to const
16779         int.
16781 2017-05-05  David Malcolm  <dmalcolm@redhat.com>
16783         * diagnostic.h (diagnostic_override_option_index): Convert from
16784         macro to inline function.
16786 2017-05-05  David Malcolm  <dmalcolm@redhat.com>
16788         * diagnostic.c (last_module_changed_p): New function.
16789         (set_last_module): New function.
16790         (diagnostic_report_current_module): Convert macro usage to
16791         the above functions.
16792         * diagnostic.h (diagnostic_context::last_module): Strengthen
16793         from const line_map * to const line_map_ordinary *.
16794         (diagnostic_last_module_changed): Delete macro.
16795         (diagnostic_set_last_module): Delete macro.
16797 2017-05-05  David Malcolm  <dmalcolm@redhat.com>
16799         * diagnostic.c (diagnostic_impl): Replace report_diagnostic
16800         with diagnostic_report_diagnostic.
16801         (diagnostic_n_impl_richloc): Likewise.
16802         * diagnostic.h (report_diagnostic): Delete macro.
16803         * rtl-error.c (diagnostic_for_asm): Replace report_diagnostic
16804         with diagnostic_report_diagnostic.
16805         * substring-locations.c (format_warning_va): Likewise.
16807 2017-05-05  David Malcolm  <dmalcolm@redhat.com>
16809         * diagnostic.c (diagnostic_report_diagnostic): Eliminate
16810         save/restor of format_spec.  Move option-printing code to...
16811         (print_option_information): ...this new function, and
16812         reimplement by simply printing to the pretty_printer,
16813         rather than appending to the format string.
16815 2017-05-05  David Malcolm  <dmalcolm@redhat.com>
16817         * diagnostic.c (diagnostic_report_diagnostic): Split out pragma
16818         handling logic into...
16819         (update_effective_level_from_pragmas): ...this new function.
16821 2017-05-04  Andrew Waterman  <andrew@sifive.com>
16823         * config/riscv/riscv.opt (mstrict-align): New option.
16824         * config/riscv/riscv.h (STRICT_ALIGNMENT): Use it.  Update comment.
16825         (SLOW_UNALIGNED_ACCESS): Define.
16826         (riscv_slow_unaligned_access): Declare.
16827         * config/riscv/riscv.c (riscv_tune_info): Add slow_unaligned_access
16828         field.
16829         (riscv_slow_unaligned_access): New variable.
16830         (rocket_tune_info): Set slow_unaligned_access to true.
16831         (optimize_size_tune_info): Set slow_unaligned_access to false.
16832         (riscv_cpu_info_table): Add entry for optimize_size_tune_info.
16833         (riscv_valid_lo_sum_p): Use TARGET_STRICT_ALIGN.
16834         (riscv_option_override): Set riscv_slow_unaligned_access.
16835         * doc/invoke.texi: Add -mstrict-align to RISC-V.
16837 2017-05-04  Kito Cheng  <kito.cheng@gmail.com>
16839         * config/riscv/riscv.md: Unify indentation.
16841 2017-05-05  Michael Meissner  <meissner@linux.vnet.ibm.com>
16843         PR target/79038
16844         PR target/79202
16845         PR target/79203
16846         * config/rs6000/rs6000.md (u code attribute): Add FIX and
16847         UNSIGNED_FIX.
16848         (extendsi<mode>2): Add support for doing sign extension via
16849         VUPKHSW and XXPERMDI if the value is in Altivec registers and we
16850         don't have ISA 3.0 instructions.
16851         (extendsi<mode>2 splitter): Likewise.
16852         (fix_trunc<mode>si2): If we are at ISA 2.07 (VSX small integer),
16853         generate the normal insns since SImode can now go in vector
16854         registers.  Disallow the special UNSPECs needed for previous
16855         machines to hide SImode being used.  Add new insns
16856         fctiw{,w}_<mode>_smallint if SImode can go in vector registers.
16857         (fix_trunc<mode>si2_stfiwx): Likewise.
16858         (fix_trunc<mode>si2_internal): Likewise.
16859         (fixuns_trunc<mode>si2): Likewise.
16860         (fixuns_trunc<mode>si2_stfiwx): Likewise.
16861         (fctiw<u>z_<mode>_smallint): Likewise.
16862         (fctiw<u>z_<mode>_mem): New combiner pattern to prevent conversion
16863         of floating point to 32-bit integer from doing a direct move to
16864         the GPR registers to do a store.
16865         (fctiwz_<mode>): Break long line.
16867 2017-05-05  Bin Cheng  <bin.cheng@arm.com>
16869         * Makefile.in (GTFILES): Add tree-ssa-loop-ivopts.c.
16870         * tree-ssa-loop-ivopts.c (compute_max_addr_offset): Delete.
16871         (addr_list, addr_offset_valid_p): New.
16872         (split_address_groups): Check offset validity with above function.
16873         (gt-tree-ssa-loop-ivopts.h): Include header file.
16875 2017-05-05  Nathan Sidwell  <nathan@acm.org>
16877         * config.gcc (arm*-*-*): Add missing 'fi'.
16879 2017-05-05  Steve Ellcey  <sellcey@cavium.com>
16881         * doc/invoke.texi (-fopt-info): Explicitly say order of options
16882         included in -fopt-info does not matter.
16883         * doc/optinfo.texi (-fopt-info): Fix description of default
16884         behavour. Explicitly say order of options included in -fopt-info
16885         does not matter.
16887 2017-05-05  Thomas Preud'homme  <thomas.preudhomme@arm.com>
16889         * config.gcc: Allow combinations of aprofile and rmprofile values for
16890         --with-multilib-list.
16891         * config/arm/t-multilib: New file.
16892         * config/arm/t-aprofile: Remove initialization of MULTILIB_*
16893         variables.  Remove setting of ISA and floating-point ABI in
16894         MULTILIB_OPTIONS and MULTILIB_DIRNAMES.  Set architecture and FPU in
16895         MULTI_ARCH_OPTS_A and MULTI_ARCH_DIRS_A rather than MULTILIB_OPTIONS
16896         and MULTILIB_DIRNAMES respectively.  Add comment to introduce all
16897         matches.  Add architecture matches for marvel-pj4 and generic-armv7-a
16898         CPU options.
16899         * config/arm/t-rmprofile: Likewise except for the matches changes.
16900         * doc/install.texi (--with-multilib-list): Document the combination of
16901         aprofile and rmprofile values and warn about pitfalls in doing that.
16903 2017-05-05  Wilco Dijkstra  <wdijkstr@arm.com>
16905         * config/aarch64/aarch64.md (movsi_aarch64): Remove '*' from r=w.
16906         (movdi_aarch64): Likewise.
16908 2017-05-05  Jakub Jelinek  <jakub@redhat.com>
16910         PR tree-optimization/80632
16911         * tree-switch-conversion.c (struct switch_conv_info): Add target_vop
16912         field.
16913         (build_arrays): Initialize it for virtual phis.
16914         (fix_phi_nodes): Use it for virtual phis.
16916         PR tree-optimization/80558
16917         * tree-vrp.c (extract_range_from_binary_expr_1): Optimize
16918         [x, y] op z into [x op, y op z] for op & or | if conditions
16919         are met.
16921 2017-05-05  Andre Vieira  <andre.simoesdiasvieira@arm.com>
16922             Prakhar Bahuguna  <prakhar.bahuguna@arm.com>
16924         PR target/71607
16925         * config/arm/arm.md (use_literal_pool): Remove.
16926         (64-bit immediate split): No longer takes cost into consideration
16927         if arm_disable_literal_pool is enabled.
16928         * config/arm/arm.c (arm_tls_referenced_p): Add diagnostic if TLS is
16929         used when arm_disable_literal_pool is enabled.
16930         (arm_max_const_double_inline_cost): Remove use of
16931         arm_disable_literal_pool.
16932         (push_minipool_fix): Add assert.
16933         (arm_reorg): Add return if arm_disable_literal_pool is enabled.
16934         * config/arm/vfp.md (no_literal_pool_df_immediate): New.
16935         (no_literal_pool_sf_immediate): New.
16937 2017-05-05  Prathamesh Kulkarni  <prathamesh.kulkarni@linaro.org>
16939         PR tree-optimization/80613
16940         * tree-ssa-dce.c (propagate_necessity): Remove cases for
16941         BUILT_IN_STRDUP and BUILT_IN_STRNDUP.
16943 2017-05-05  Richard Biener  <rguenther@suse.de>
16945         * tree-ssa-pre.c (get_or_alloc_expr_for): Simplify.
16947 2017-05-05  Georg-Johann Lay  <avr@gjlay.de>
16949         * config/avr/avr.md [flag_strict_overflow]: Remove any occurence
16950         of this flag from insn conditions due to removal from r247495.
16952 2017-05-05  Wilco Dijkstra  <wdijkstr@arm.com>
16954         * config/arm/aarch-common.c (arm_early_load_addr_dep_ptr):
16955         New function.
16956         (arm_early_store_addr_dep_ptr): Likewise.
16957         * config/arm/aarch-common-protos.h
16958         (arm_early_load_addr_dep_ptr): Add prototype.
16959         (arm_early_store_addr_dep_ptr): Likewise.
16960         * config/arm/cortex-a53.md: Add new bypasses.
16962 2017-05-05  Jakub Jelinek  <jakub@redhat.com>
16964         * tree.c (next_type_uid): Change type to unsigned.
16965         (type_hash_canon): Decrement back next_type_uid if
16966         freeing a type node with the highest TYPE_UID.  For INTEGER_TYPEs
16967         also ggc_free TYPE_MIN_VALUE, TYPE_MAX_VALUE and TYPE_CACHED_VALUES
16968         if possible.
16970 2017-05-04  Martin Sebor  <msebor@redhat.com>
16972         * builtins.c: Fix a trivial typo in a comment.
16974         PR middle-end/79234
16975         * builtins.c (check_sizes): Adjust to handle reading past the end.
16976         Avoid printing excessive upper bound of ranges.  Use %E to print
16977         tree nodes instead of converting them to %wu.
16978         (expand_builtin_memchr): New function.
16979         (compute_dest_size): Rename...
16980         (compute_objsize): ...to this.
16981         (expand_builtin_memcpy): Adjust.
16982         (expand_builtin_mempcpy): Adjust.
16983         (expand_builtin_strcat): Adjust.
16984         (expand_builtin_strcpy): Adjust.
16985         (check_strncat_sizes): Adjust.
16986         (expand_builtin_strncat): Adjust.
16987         (expand_builtin_strncpy): Adjust and simplify.
16988         (expand_builtin_memset): Adjust.
16989         (expand_builtin_bzero): Adjust.
16990         (expand_builtin_memcmp): Adjust.
16991         (expand_builtin): Handle memcmp.
16992         (maybe_emit_chk_warning): Check strncat just once.
16994 2017-05-04  Martin Sebor  <msebor@redhat.com>
16996         PR preprocessor/79214
16997         PR middle-end/79222
16998         PR middle-end/79223
16999         * builtins.c (check_sizes): Add inlining context and issue
17000         warnings even when -Wno-system-headers is set.
17001         (check_strncat_sizes): Same.
17002         (expand_builtin_strncat): Same.
17003         (expand_builtin_memmove): New function.
17004         (expand_builtin_stpncpy): Same.
17005         (expand_builtin): Handle memmove and stpncpy.
17007 2017-05-04  Bin Cheng  <bin.cheng@arm.com>
17009         * tree-ssa-loop-ivopts.c (struct cost_pair): Remove field inv_expr
17010         which is not used any more.
17012 2017-05-04  Wilco Dijkstra  <wdijkstr@arm.com>
17014         * config/aarch64/aarch64.c (generic_tunings): Update prefetch model.
17016 2017-05-04  Wilco Dijkstra  <wdijkstr@arm.com>
17018         * config/aarch64/aarch64.c (cortexa35_tunings): Set jump alignment to 4.
17019         (cortexa53_tunings): Likewise.
17020         (cortexa57_tunings): Likewise.
17021         (cortexa72_tunings): Likewise.
17022         (cortexa73_tunings): Likewise.
17024 2017-05-04  Wilco Dijkstra  <wdijkstr@arm.com>
17026         * config/aarch64/aarch64.c (generic_tunings): Set jump alignment to 4.
17027         Set loop alignment to 8.
17029 2017-05-04  Martin Sebor  <msebor@redhat.com>
17031         PR translation/80280
17032         * builtins.c (expand_builtin_object_size): Add missing quoting to
17033         %D and like directives.
17034         * hsa-gen.c (hsa_type_for_scalar_tree_type): Same.
17035         (hsa_type_for_tree_type): Same.
17036         (verify_function_arguments): Same.
17037         * symtab.c (symbol_table::change_decl_assembler_name): Same.
17038         * varasm.c (get_section): Same.
17039         (mark_weak): Same.
17041 2017-05-04  Martin Sebor  <msebor@redhat.com>
17043         PR translation/80280
17044         * config/i386/i386.c (ix86_function_versions): Quote a %D directive.
17046 2017-05-04  Wilco Dijkstra  <wdijkstr@arm.com>
17048         * config/aarch64/aarch64.c (generic_addrcost_table):
17049         Change HI/TI mode setting.
17051 2017-05-04  Martin Jambor  <mjambor@suse.cz>
17053         PR tree-optimization/80622
17054         * tree-sra.c (comes_initialized_p): New function.
17055         (build_accesses_from_assign): Only set write lazily when
17056         comes_initialized_p is false.
17057         (analyze_access_subtree): Use comes_initialized_p.
17058         (propagate_subaccesses_across_link): Assert !comes_initialized_p
17059         instead of testing for PARM_DECL.
17061 2017-05-04  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
17063         * config/aarch64/aarch64.md (prefetch); Adjust predicate and
17064         constraint on operand 0 to allow more general addressing modes.
17065         Adjust output template.
17066         * config/aarch64/aarch64.c (aarch64_address_valid_for_prefetch_p):
17067         New function.
17068         * config/aarch64/aarch64-protos.h
17069         (aarch64_address_valid_for_prefetch_p): Declare prototype.
17070         * config/aarch64/constraints.md (Dp): New address constraint.
17071         * config/aarch64/predicates.md (aarch64_prefetch_operand): New
17072         predicate.
17074 2017-05-04  Jan Hubicka  <hubicka@ucw.cz>
17076         * ipa-cp.c (perform_estimation_of_a_value): Drop base_time parameter;
17077         update use of estimate_ipcp_clone_size_and_time.
17078         (estimate_local_effects): Update use of
17079         estimate_ipcp_clone_size_and_time and perform_estimation_of_a_value.
17080         * ipa-inline.h (estimate_ipcp_clone_size_and_time): Update prototype.
17081         * ipa-inline-analysis.c (estimate_ipcp_clone_size_and_time):
17082         Return nonspecialized time.
17084 2017-05-04  Richard Biener  <rguenther@suse.de>
17086         * tree-ssa-alias.c (get_continuation_for_phi): Improve looking
17087         for the last VUSE which def dominates the PHI.  Directly call
17088         maybe_skip_until.
17089         (get_continuation_for_phi_1): Remove.
17091 2017-05-04  Richard Sandiford  <richard.sandiford@linaro.org>
17093         * tree-ssa-loop-manip.c (niter_for_unrolled_loop): Add commentary
17094         to explain the use of truncating division.  Cap the number of
17095         iterations to the maximum given by nb_iterations_upper_bound,
17096         if defined.
17098 2017-05-04  Thomas Preud'homme  <thomas.preudhomme@arm.com>
17100         * configure.ac (--enable-mingw-wildcard): Add new configurable feature.
17101         * configure: Regenerate.
17102         * config.in: Regenerate.
17103         * config/i386/driver-mingw32.c: new file.
17104         * config/i386/x-mingw32: Add rule to build driver-mingw32.o.
17105         * config.host: Link driver-mingw32.o on MinGW host.
17106         * doc/install.texi: Document new --enable-mingw-wildcard configure
17107         option.
17109 2017-05-04  Marek Polacek  <polacek@redhat.com>
17111         PR tree-optimization/80612
17112         * calls.c (get_size_range): Check for INTEGRAL_TYPE_P.
17114 2017-05-04  Prakhar Bahuguna  <prakhar.bahuguna@arm.com>
17115             Andre Simoes Dias Vieira  <andre.simoesdiasvieira@arm.com>
17117         * config/arm/arm.md (movsi): Change TARGET_32BIT to TARGET_HAVE_MOVT.
17118         (movt splitter): Likewise.
17119         * config/arm/arm.c (arm_option_check_internal): Change arm_arch_thumb2
17120         to TARGET_HAVE_MOVT, and merge with -mslow-flash-data check.
17121         (const_ok_for_arm): Change else to else if (TARGET_THUMB2) and add else
17122         block for Thumb-1 with MOVT.
17123         (thumb2_legitimate_address_p): Move code block ...
17124         (can_avoid_literal_pool_for_label_p): ... into this new function.
17125         (thumb1_legitimate_address_p): Add check for TARGET_HAVE_MOVT and
17126         literal pool.
17127         (thumb_legitimate_constant_p): Add conditional on TARGET_HAVE_MOVT
17128         * doc/invoke.texi (-mpure-code): Change "ARMv7-M targets" for
17129         "M-profile targets with the MOVT instruction".
17131 2017-05-04  Prakhar Bahuguna  <prakhar.bahuguna@arm.com>
17133         * config/arm/arm-builtins.c (arm_init_builtins): Rename
17134         __builtin_arm_ldfscr to __builtin_arm_get_fpscr, and rename
17135         __builtin_arm_stfscr to __builtin_arm_set_fpscr.
17137 2017-05-04  Martin Liska  <mliska@suse.cz>
17139         * tree-vrp.c (simplify_cond_using_ranges_2): Remove unused
17140         variable cond_code.
17142 2017-05-04  Richard Biener  <rguenther@suse.de>
17144         * tree.c (array_at_struct_end_p): Handle arrays at struct
17145         end with flexarrays more conservatively.  Refactor and treat
17146         arrays of arrays or aggregates more strict.  Fix
17147         VIEW_CONVERT_EXPR handling.  Remove allow_compref argument.
17148         * tree.c (array_at_struct_end_p): Adjust prototype.
17149         * emit-rtl.c (set_mem_attributes_minus_bitpos): Adjust.
17150         * gimple-fold.c (get_range_strlen): Likewise.
17151         * tree-chkp.c (chkp_may_narrow_to_field): Likewise.
17153 2017-05-04  Richard Biener  <rguenther@suse.de>
17155         PR tree-optimization/31130
17156         * tree-vrp.c (needs_overflow_infinity): Remove as always returning
17157         false.
17158         (supports_overflow_infinity): Likewise.
17159         (is_negative_overflow_infinity): Likewise.
17160         (is_positive_overflow_infinity): Likewise.
17161         (is_overflow_infinity): Likewise.
17162         (stmt_overflow_infinity): Likewise.
17163         (overflow_infinity_range_p): Likewise.
17164         (usable_range_p): Remove as always returning true.
17165         (make_overflow_infinity): Remove.
17166         (negative_overflow_infinity): Likewise.
17167         (positive_overflow_infinity): Likewise.
17168         (avoid_overflow_infinity): Likewise.
17169         (set_value_range): Adjust accordingly.
17170         (set_value_range_to_nonnegative): Likewise, remove now unused
17171         overflow_infinity arg.
17172         (vrp_operand_equal_p): Adjust.
17173         (update_value_range): Likewise.
17174         (range_int_cst_singleton_p): Likewise.
17175         (operand_less_p): Likewise.
17176         (compare_values_warnv): Likewise.
17177         (extract_range_for_var_from_comparison_expr): Likewise.
17178         (vrp_int_const_binop): Likewise.
17179         (zero_nonzero_bits_from_vr): Likewise.
17180         (extract_range_from_multiplicative_op_1): Likewise.
17181         (extract_range_from_binary_expr_1): Likewise.
17182         (extract_range_from_unary_expr): Likewise.
17183         (extract_range_from_comparison): Likewise.
17184         (extract_range_basic): Likewise.
17185         (adjust_range_with_scev): Likewise.
17186         (compare_ranges): Likewise.
17187         (compare_range_with_value): Likewise.
17188         (dump_value_range): Likewise.
17189         (test_for_singularity): Likewise, remove strict_overflow_p parameter
17190         never used.
17191         (simplify_cond_using_ranges): Adjust.
17193 2017-05-04  Pekka Jääskeläinen  <pekka.jaaskelainen@parmance.com>
17195         * brig-builtins.def: Added a builtin for class_f64.
17196         * builtin-types.def: Added a builtin type needed by class_f64.
17198 2017-05-03  Jason Merrill  <jason@redhat.com>
17200         * timevar.def: Add TV_CONSTEXPR.
17202 2017-05-03  David Malcolm  <dmalcolm@redhat.com>
17204         * common.opt (fdiagnostics-parseable-fixits): Fix typo.
17206 2017-05-03  Martin Jambor  <mjambor@suse.cz>
17208         * ipa-prop.c (ipa_update_after_lto_read): Removed.
17209         * ipa-prop.h (ipa_update_after_lto_read): Remove declaration.
17210         * ipa-cp.c (ipcp_propagate_stage): Do not call
17211         ipa_update_after_lto_read.
17212         * ipa-inline.c (ipa_inline): Likewise.
17214 2017-05-03  Martin Jambor  <mjambor@suse.cz>
17216         * ipa-prop.h (ipa_edge_args): Make a class.  Mark with for_user GTY
17217         tag.  Added a default constructor and a destructor.
17218         (ipa_edge_args_sum_t): New class;
17219         (ipa_edge_args_sum): Declare.
17220         (ipa_edge_args_vector): Remove declaration.
17221         (IPA_EDGE_REF): Use ipa_edge_args_sum.
17222         (ipa_free_edge_args_substructures): Remove declaration.
17223         (ipa_check_create_edge_args): Use ipa_edge_args_sum.
17224         (ipa_edge_args_info_available_for_edge_p): Likewise.
17225         * ipa-prop.c (ipa_edge_args_vector): Removed.
17226         (edge_removal_hook_holder): Likewise.
17227         (edge_duplication_hook_holder): Likewise.
17228         (ipa_edge_args_sum): New variable.
17229         (ipa_propagate_indirect_call_infos): Test ipa_edge_args_sum instead of
17230         ipa_edge_args_vector.
17231         (ipa_free_edge_args_substructures): Likewise.
17232         (ipa_free_all_edge_args): Free ipa_edge_args_sum instead of
17233         ipa_edge_args_vector.
17234         (ipa_edge_removal_hook): Turned into method
17235         ipa_edge_args_sum_t::remove.
17236         (ipa_edge_duplication_hook): Turned into method
17237         ipa_edge_args_sum_t::duplicate.
17238         (ipa_register_cgraph_hooks): Create ipa_edge_args_sum instead of
17239         registering edge hooks.
17240         (ipa_unregister_cgraph_hooks): Do not unregister edge hooks.
17241         * ipa-inline-analysis.c (estimate_function_body_sizes): Test
17242         ipa_edge_args_sum instead of ipa_edge_args_vector.
17243         * ipa-profile.c (ipa_profile): Likewise.
17245 2017-05-03  Martin Jambor  <mjambor@suse.cz>
17247         * symbol-summary.h (function_summary): New method exists.
17248         (function_summary::symtab_removal): Deallocate through release.
17249         (call_summary): New class.
17250         (gt_ggc_mx): New overload.
17251         (gt_pch_nx): Likewise.
17252         (gt_pch_nx): Likewise.
17254 2017-05-03  Jeff Law  <law@redhat.com>
17256         PR tree-optimization/78496
17257         * tree-vrp.c (simplify_cond_using_ranges_1): Renamed
17258         from simplify_cond_using_ranges.  Split off code to walk
17259         backwards through casts into ...
17260         (simplify_cond_using_ranges_2): New function.
17261         (simplify_stmt_using_ranges): Call simplify_cond_using_ranges_1.
17262         (execute_vrp): After identifying jump threads, call
17263         simplify_cond_using_ranges_2.
17265 2017-05-03  Jan Hubicka  <hubicka@ucw.cz>
17267         PR bootstrap/80609
17268         * ipa-inline.h (inline_summary): Add ctor.
17269         (create_ggc): Do not use ggc_cleared_alloc.
17271 2017-05-03  Jeff Downs  <heydowns@somuchpressure.net>
17272             Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
17274         * gcc.c (handle_braces): Support escaping in switch matching
17275         text.
17276         * doc/invoke.texi (Spec Files): Document it.
17277         Remove superfluous @code markup in items.
17279 2017-05-03  David Malcolm  <dmalcolm@redhat.com>
17281         * diagnostic-show-locus.c (struct column_range): New struct.
17282         (get_affected_columns): New function.
17283         (get_printed_columns): New function.
17284         (struct correction): New struct.
17285         (correction::ensure_capacity): New function.
17286         (correction::ensure_terminated): New function.
17287         (struct line_corrections): New struct.
17288         (line_corrections::~line_corrections): New dtor.
17289         (line_corrections::add_hint): New function.
17290         (layout::print_trailing_fixits): Reimplement in terms of the new
17291         classes.
17292         (selftest::test_overlapped_fixit_printing): New function.
17293         (selftest::diagnostic_show_locus_c_tests): Call it.
17295 2017-05-03  Nathan Sidwell  <nathan@acm.org>
17297         Canonicalize canonical type hashing
17298         * tree.h (type_hash_canon_hash): Declare.
17299         * tree.c (type_hash_list, attribute_hash_list): Move into
17300         type_hash_canon_hash.
17301         (build_type_attribute_qual_variant): Break out hash code calc into
17302         type_hash_canon_hash.
17303         (type_hash_canon_hash): New.  Generic type hash computation.
17304         (build_range_type_1, build_array_type_1, build_function_type,
17305         build_method_type_directly, build_offset_type, build_complex_type,
17306         make_vector_type): Call it.
17308 2017-05-03  Richard Biener  <rguenther@suse.de>
17310         * tree-vect-data-refs.c (vect_enhance_data_refs_alignment):
17311         When all DRs have unknown misaligned do not always peel
17312         when there is a store but apply the same costing model as if
17313         there were only loads.
17315 2017-05-03  Richard Biener  <rguenther@suse.de>
17317         Revert
17318         PR tree-optimization/80492
17319         * tree-ssa-alias.c (decl_refs_may_alias_p): Handle
17320         compare_base_decls returning dont-know properly.
17322 2017-05-03  Thomas Preud'homme  <thomas.preudhomme@arm.com>
17324         * config/arm/iterators.md (CCSI): New mode iterator.
17325         (arch): New mode attribute.
17326         * config/arm/sync.md (atomic_compare_and_swap<mode>_1): Rename into ...
17327         (atomic_compare_and_swap<CCSI:arch><NARROW:mode>_1): This and ...
17328         (atomic_compare_and_swap<CCSI:arch><SIDI:mode>_1): This.  Use CCSI
17329         code iterator for success result mode.
17330         * config/arm/arm.c (arm_expand_compare_and_swap): Adapt code to use
17331         the corresponding new insn generators.
17333 2017-05-03  Bin Cheng  <bin.cheng@arm.com>
17335         Revert r247509
17336         2017-05-02  Bin Cheng  <bin.cheng@arm.com>
17337         * rtlanal.c (rtx_cost): Handle TRUNCATE between tieable modes.
17339 2017-05-03  Richard Sandiford  <richard.sandiford@linaro.org>
17341         * tree-data-ref.h (SUB_CONFLICTS_IN_A): Wrap SUB argument in brackets.
17342         (SUB_CONFLICTS_IN_B, SUB_LAST_CONFLICT, SUB_DISTANCE): Likewise.
17343         (DDR_A): Wrap DDR argument in brackets.
17344         (DDR_B, DDR_AFFINE_P, DDR_ARE_DEPENDENT, DDR_SUBSCRIPTS): Likewise.
17345         (DDR_LOOP_NEST, DDR_INNER_LOOP, DDR_SELF_REFERENCE): Likewise.
17346         (DDR_REVERSED_P): Likewise.
17348 2017-05-03  Jakub Jelinek  <jakub@redhat.com>
17350         PR tree-optimization/79472
17351         * tree-switch-conversion.c (struct switch_conv_info): Add
17352         contiguous_range and default_case_nonstandard fields.
17353         (collect_switch_conv_info): Compute contiguous_range and
17354         default_case_nonstandard fields, don't clear final_bb if
17355         contiguous_range and only the default case doesn't have the required
17356         structure.
17357         (check_all_empty_except_final): Set default_case_nonstandard instead
17358         of failing if contiguous_range and the default case doesn't have empty
17359         block.
17360         (check_final_bb): Add SWTCH argument, don't fail if contiguous_range
17361         and only the default case doesn't have the required constants.  Skip
17362         virtual phis.
17363         (gather_default_values): Skip virtual phis.  Allow non-NULL CASE_LOW
17364         if default_case_nonstandard.
17365         (build_constructors): Build constant 1 just once.  Assert that default
17366         values aren't inserted in between cases if contiguous_range.  Skip
17367         virtual phis.
17368         (build_arrays): Skip virtual phis.
17369         (prune_bbs): Add DEFAULT_BB argument, don't remove that bb.
17370         (fix_phi_nodes): Don't add e2f phi arg if default_case_nonstandard.
17371         Handle virtual phis.
17372         (gen_inbound_check): Handle default_case_nonstandard case.
17373         (process_switch): Adjust check_final_bb caller.  Call
17374         gather_default_values with the first non-default case instead of
17375         default case if default_case_nonstandard.
17377 2017-05-02  Nathan Sidwell  <nathan@acm.org>
17379         * ggc-page.c (move_ptes_to_front): Replace unsigned >0 with i--
17380         check.  Fix formatting.
17382 2017-05-02  Jan Hubicka  <hubicka@ucw.cz>
17384         * ipa-inline-analysis.c (estimate_node_size_and_time): Allow roundoff
17385         errors when comparing specialized and unspecialized times.
17387 2017-05-02  David Malcolm  <dmalcolm@redhat.com>
17389         * diagnostic-show-locus.c
17390         (layout::should_print_annotation_line_p): Make private.
17391         (layout::print_annotation_line): Make private.
17392         (layout::annotation_line_showed_range_p): Make private.
17393         (layout::show_ruler): Make private.
17394         (layout::print_source_line): Make private.  Pass in line and
17395         line_width, rather than calling location_get_source_line.  Drop
17396         returned value.
17397         (layout::print_leading_fixits): New method.
17398         (layout::print_any_fixits): Rename to...
17399         (layout::print_trailing_fixits): ...this, and make private.
17400         Don't print newline fixits.
17401         (diagnostic_show_locus): Move logic for printing one row into...
17402         (layout::print_line): ...this new function.  Move the
17403         location_get_source_line call and error-handling from
17404         print_source_line to here.  Call print_leading_fixits, and rename
17405         print_any_fixits to print_trailing_fixits.
17406         (selftest::test_fixit_insert_containing_newline): Update now that
17407         newlines are partially supported.
17408         (selftest::test_fixit_insert_containing_newline_2): New test.
17409         (selftest::test_fixit_replace_containing_newline): Update comments.
17410         (selftest::diagnostic_show_locus_c_tests): Call the new test.
17411         * edit-context.c (class added_line): New class.
17412         (class edited_line): Describe newline handling in comment.
17413         (edited_line::actually_edited_p): New method.
17414         (edited_line::print_content): Delete redundant decl.
17415         (edited_line::m_predecessors): New field.
17416         (edited_file::print_content): Call edited_line::print_content.
17417         (edited_file::print_diff): Update to support newlines.
17418         (edited_file::print_diff_hunk): Likewise.
17419         (edited_file::print_run_of_changed_lines): New function.
17420         (edited_file::print_diff_line): Convert to...
17421         (print_diff_line): ...this.
17422         (edited_file::get_effective_line_count): New function.
17423         (edited_line::edited_line): Initialize new field m_predecessors.
17424         (edited_line::~edited_line): Clean up m_predecessors.
17425         (edited_line::apply_fixit): Handle newlines.
17426         (edited_line::get_effective_line_count): New function.
17427         (edited_line::print_content): New function.
17428         (edited_line::print_diff_lines): New function.
17429         (selftest::test_applying_fixits_insert_containing_newline): New
17430         test.
17431         (selftest::test_applying_fixits_replace_containing_newline): New
17432         test.
17433         (selftest::insert_line): New function.
17434         (selftest::test_applying_fixits_multiple_lines): Add example of
17435         inserting a line.
17436         (selftest::edit_context_c_tests): Call the new tests.
17438 2017-05-02  Bin Cheng  <bin.cheng@arm.com>
17440         * tree-ssa-loop-ivopts.c (get_scaled_computation_cost_at): Delete
17441         parameter cand.  Update dump information.
17442         (get_computation_cost): Update uses.
17444 2017-05-02  Bin Cheng  <bin.cheng@arm.com>
17446         * tree-ssa-loop-ivopts.c (get_computation_aff_1): New.
17447         (get_computation_aff): Reorder parameters.  Use get_computation_aff_1.
17448         (get_computation_at, rewrite_use_address): Update use of
17449         get_computation_aff.
17451 2017-05-02  Bin Cheng  <bin.cheng@arm.com>
17453         * tree-ssa-loop-ivopts.c (get_computation_at): Reorder parameters.
17454         (get_computation): Delete.
17455         (get_computation_cost): Implement like get_computation_cost_at.
17456         Use get_computation_at.
17457         (get_computation_cost_at): Delete.
17458         (rewrite_use_nonlinear_expr): Use get_computation_at.
17459         (rewrite_use_compare, remove_unused_ivs): Ditto.
17461 2017-05-02  Bin Cheng  <bin.cheng@arm.com>
17463         * tree-ssa-loop-ivopts.c (rewrite_use_address): Simple refactor.
17465 2017-05-02  Bin Cheng  <bin.cheng@arm.com>
17467         * tree-ssa-loop-ivopts.c (struct iv_ca): Rename n_regs to n_invs.
17468         (ivopts_global_cost_for_size): Rename parameter and update uses.
17469         (iv_ca_recount_cost): Update uses.
17470         (iv_ca_set_remove_invs, iv_ca_set_no_cp): Record invariants and
17471         candidates seperately in n_invs and n_cands.
17472         (iv_ca_set_add_invs, iv_ca_set_cp, iv_ca_new): Ditto.
17474 2017-05-02  Bin Cheng  <bin.cheng@arm.com>
17476         * tree-ssa-loop-ivopts.c (struct walk_tree_data): New.
17477         (find_inv_vars_cb): New.
17478         (find_depends): Renamed to ...
17479         (find_inv_vars): ... this.
17480         (add_candidate_1, force_var_cost): Call find_inv_vars.
17481         (split_address_cost, determine_group_iv_cost_cond): Ditto.
17483 2017-05-02  Bin Cheng  <bin.cheng@arm.com>
17485         * tree-ssa-loop-ivopts.c (struct cost_pair): Rename depends_on to
17486         inv_vars.  Add inv_exprs.
17487         (struct iv_cand): Rename depends_on to inv_vars.
17488         (struct ivopts_data): Rename max_inv_id/n_invariant_uses to
17489         max_inv_var_id/n_inv_var_uses.  Move max_inv_expr_id around.
17490         Refactor field used_inv_exprs from has_map to array n_inv_expr_uses.
17491         (dump_cand): Dump inv_vars.
17492         (tree_ssa_iv_optimize_init): Support inv_vars and inv_exprs.
17493         (record_invariant, find_depends, add_candidate_1): Ditto.
17494         (set_group_iv_cost, force_var_cost): Ditto.
17495         (split_address_cost, ptr_difference_cost, difference_cost): Ditto.
17496         (get_computation_cost_at, get_computation_cost): Ditto.
17497         (determine_group_iv_cost_generic): Ditto.
17498         (determine_group_iv_cost_address): Ditto.
17499         (determine_group_iv_cost_cond, autoinc_possible_for_pair): Ditto.
17500         (determine_group_iv_costs): Ditto.
17501         (iv_ca_recount_cost): Update call to ivopts_global_cost_for_size.
17502         (iv_ca_set_remove_invariants): Renamed to ...
17503         (iv_ca_set_remove_invs): ... this.  Support inv_vars and inv_exprs.
17504         (iv_ca_set_no_cp): Use iv_ca_set_remove_invs.
17505         (iv_ca_set_add_invariants):  Renamed to ...
17506         (iv_ca_set_add_invs): ... this.  Support inv_vars and inv_exprs.
17507         (iv_ca_set_cp): Use iv_ca_set_add_invs.
17508         (iv_ca_has_deps): Support inv_vars and inv_exprs.
17509         (iv_ca_new, iv_ca_free, iv_ca_dump, free_loop_data): Ditto.
17510         (create_new_ivs): Remove useless dump.
17512 2017-05-02  Bin Cheng  <bin.cheng@arm.com>
17514         * tree-ssa-loop-ivopts.c (get_computation_cost_at): Remove pseudo
17515         iv_cand code.
17516         (determine_group_iv_cost_cond, determine_iv_cost): Ditto.
17517         (iv_ca_set_no_cp, create_new_iv): Ditto.
17519 2017-05-02  Bin Cheng  <bin.cheng@arm.com>
17521         * rtlanal.c (rtx_cost): Handle TRUNCATE between tieable modes.
17523 2017-05-02  Xi Ruoyao  <ryxi@stu.xidian.edu.cn>
17525         * tree.h (EXPR_CILK_SPAWN): Use macro TREE_CHECK2 instead of
17526         function tree_check2.
17528 2017-05-02  Martin Liska  <mliska@suse.cz>
17530         * doc/gcov.texi: Add missing preposition.
17531         * gcov.c (function_info::function_info): Properly fill up
17532         all member variables.
17534 2017-05-02  Tamar Christina  <tamar.christina@arm.com>
17536         * expr.c (expand_expr_real_2): Re-cost if previous costs are the same.
17538 2017-05-02  Tamar Christina  <tamar.christina@arm.com>
17540         * simplify-rtx.c (simplify_binary_operation_1): Add LSHIFTRT case.
17542 2017-05-02  Martin Liska  <mliska@suse.cz>
17544         PR lto/77954.
17545         * lto-streamer-in.c (lto_read_tree_1): Remove
17546         LTO_STREAMER_DEBUG.
17547         * lto-streamer.c (struct tree_hash_entry): Likewise.
17548         (struct tree_entry_hasher): Likewise.
17549         (tree_entry_hasher::hash): Likewise.
17550         (tree_entry_hasher::equal): Likewise.
17551         (lto_streamer_init): Likewise.
17552         (lto_orig_address_map): Likewise.
17553         (lto_orig_address_get): Likewise.
17554         (lto_orig_address_remove): Likewise.
17555         * lto-streamer.h: Likewise.
17556         * tree-streamer-in.c (streamer_alloc_tree): Likewise.
17557         * tree-streamer-out.c (streamer_write_tree_header): Likewise.
17559 2017-05-02  Sebastian Peryt  <sebastian.peryt@intel.com>
17561         * config/i386/avx512fintrin.h (_mm_mask_add_round_sd)
17562         (_mm_maskz_add_round_sd, _mm_mask_add_round_ss)
17563         (mm_maskz_add_round_ss, _mm_mask_sub_round_sd)
17564         (mm_maskz_sub_round_sd, _mm_mask_sub_round_ss)
17565         (mm_maskz_sub_round_ss, _mm_mask_add_sd)
17566         (mm_maskz_add_sd, _mm_mask_add_ss, _mm_maskz_add_ss)
17567         (mm_mask_sub_sd, _mm_maskz_sub_sd, _mm_mask_sub_ss)
17568         (mm_maskz_sub_ss): New intrinsics.
17569         * config/i386/i386-builtin-types.def (V2DF_FTYPE_V2DF_V2DF_V2DF_UQI_INT)
17570         (V4SF_FTYPE_V4SF_V4SF_V4SF_UQI_INT): New function type aliases.
17571         * config/i386/i386-builtin.def (__builtin_ia32_addsd_mask_round)
17572         (__builtin_ia32_addss_mask_round, __builtin_ia32_subsd_mask_round)
17573         (__builtin_ia32_subss_mask_round): New builtins.
17574         * config/i386/i386.c (V2DF_FTYPE_V2DF_V2DF_V2DF_UQI_INT)
17575         (V4SF_FTYPE_V4SF_V4SF_V4SF_UQI_INT): Handle new types.
17576         * config/i386/sse.md (<sse>_vm<plusminus_insn><mode>3<round_name>):
17577         Renamed to ...
17578         (<sse>_vm<plusminus_insn><mode>3<mask_name><round_name>): ... this.
17579         (v<plusminus_mnemonic><ssescalarmodesuffix>\t{<round_op3>%2, %1, %0|%0, %1, %<iptr>2<round_op3>}):
17580         Changed to ...
17581         (v<plusminus_mnemonic><ssescalarmodesuffix>\t{<round_mask_op3>%2, %1, %0<mask_operand3>|%0<mask_operand3>, %1, %<iptr>2<round_mask_op3>}):
17582         ... this.
17584 2017-05-02  Martin Jambor  <mjambor@suse.cz>
17586         PR tree-optimization/78687
17587         * tree-sra.c (access): New field parent.
17588         (process_subtree_disqualification): New function.
17589         (disqualify_candidate): Call it.
17590         (build_accesses_from_assign): Reset write flag if creating an
17591         assighnment link.
17592         (build_access_subtree): Fill in parent field and also prpagate
17593         down grp_write flag.
17594         (create_artificial_child_access): New parameter set_grp_write, set
17595         grp_write to its value.
17596         (propagate_subaccesses_across_link): Also propagate grp_write flag
17597         values.
17598         (propagate_all_subaccesses): Push the closest parent back to work
17599         queue if add_access_to_work_queue returned true.
17601 2017-05-02  Richard Biener  <rguenther@suse.de>
17603         * common.opt (fstrict-overflow): Alias negative to fwrapv.
17604         * doc/invoke.texi (fstrict-overflow): Remove all traces of
17605         -fstrict-overflow documentation.
17606         * tree.h (TYPE_OVERFLOW_UNDEFINED): Do not test flag_strict_overflow.
17607         (POINTER_TYPE_OVERFLOW_UNDEFINED): Test !flag_wrapv instead of
17608         flag_strict_overflow.
17609         * ipa-inline.c (can_inline_edge_p): Do not test flag_strict_overflow.
17610         * lto-opts.c (lto_write_options): Do not stream it.
17611         * lto-wrapper.c (merge_and_complain): Do not handle it.
17612         * opts.c (default_options_table): Do not set -fstrict-overflow.
17613         (finish_options): Likewise do not clear it when sanitizing.
17614         * simplify-rtx.c (simplify_const_relational_operation): Do not
17615         test flag_strict_overflow.
17617 2017-05-02  Uros Bizjak  <ubizjak@gmail.com>
17619         * config/alpha/alpha.md (*add<mode>3_ieee): Merge to add<mode>3
17620         using enabled attribute.
17621         (*sub<mode>3_ieee): Merge to sub<mode>3 using enabled attribute.
17622         (*mul<mode>3_ieee): Merge to mul<mode>3 using enabled attribute.
17623         (*div<mode>3_ieee): Merge to div<mode>3 using enabled attribute.
17624         (*sqrt<mode>2_ieee): Merge to sqrt<mode>2 using enabled attribute.
17625         (*fix_truncdfdi_ieee): Merge to *fix_truncdfdi2 using enabled attribute.
17626         (*fix_truncsfdi_ieee): Merge to *fix_truncsfdi2 using enabled attribute.
17627         (*floatdisf_ieee): Merge to floatdisf2 using enabled attribute.
17628         (*floatdidf_ieee): Merge to floatdidf2 using enabled attribute.
17629         (*truncdfsf2_ieee): Merge to truncdfsf2 using enabled attribute.
17630         (*cmpdf_ieee): Merge to *cmpdf_internal using enabled attribute.
17632 2017-05-02  Uros Bizjak  <ubizjak@gmail.com>
17634         * config/i386/i386.c (ix86_code_end): Use {FIRST,LAST}_INT_REG.
17636 2017-05-02  Richard Biener  <rguenther@suse.de>
17638         PR tree-optimization/80591
17639         Revert
17640         2017-04-10  Richard Biener  <rguenther@suse.de>
17642         * tree-ssa-structalias.c (find_func_aliases): Properly handle
17643         asm inputs.
17645 2017-05-02  Richard Biener  <rguenther@suse.de>
17647         PR tree-optimization/80549
17648         * tree-cfgcleanup.c (mfb_keep_latches): New helper.
17649         (cleanup_tree_cfg_noloop): Create forwarders to known loop
17650         headers if they do not have a preheader.
17652 2017-05-02  Martin Liska  <mliska@suse.cz>
17654         PR other/80589
17655         * common.opt: Fix typo.
17656         * doc/invoke.texi: Likewise.
17658 2017-05-01  Jan Beulich  <jbeulich@suse.com>
17660         * config/i386/sse.md (xop_vpermil2<mode>3): Do not allow operand
17661         swapping, add (x,x,m,x,n) alternative.
17663 2017-05-01  Nathan Sidwell  <nathan@acm.org>
17665         * calls.c (combine_pending_stack_adjustment_and_call): Remove
17666         unnecessary unadjusted_alignment check.
17668 2017-05-01  Xi Ruoyao  <ryxi@stu.xidian.edu.cn>
17670         PR c++/80038
17671         * cilk_common.c (expand_builtin_cilk_detach): Move pedigree
17672         operations here.
17673         * gimplify.c (gimplify_cilk_detach): New function.
17674         (gimplify_call_expr, gimplify_modify_expr): Call it as needed.
17675         * tree-core.h: Document EXPR_CILK_SPAWN.
17676         * tree.h (EXPR_CILK_SPAWN): Define.
17678 2017-05-01  David Malcolm  <dmalcolm@redhat.com>
17680         * diagnostic-show-locus.c (layout::get_expanded_location): Rewrite
17681         to use new fixit_hint representation, using the "replace" logic.
17682         (get_line_span_for_fixit_hint): Likewise.
17683         (layout::print_any_fixits): Likewise.
17684         (selftest::test_one_liner_many_fixits): Rename to...
17685         (selftest::test_one_liner_many_fixits_1): ...this, and update
17686         comment and expected output to reflect that the multiple fix-it
17687         hints are now consolidated into one insertion.
17688         (selftest::test_one_liner_many_fixits_2): New test.
17689         (selftest::test_diagnostic_show_locus_one_liner): Update for
17690         above.
17691         (selftest::test_fixit_consolidation): Update for fix-it API
17692         change.
17693         * diagnostic.c (print_parseable_fixits): Likewise.
17694         * edit-context.c (edited_line::m_line_events): Convert from
17695         auto_vec <line_event *> to auto_vec <line_event>.
17696         (class line_event): Convert from abstract base class to a concrete
17697         class, taking over the role of replace_event.
17698         (class insert_event): Delete.
17699         (class replace_event): Rename to class line_event.  Convert to
17700         half-open range.
17701         (edit_context::add_fixits): Reimplement.
17702         (edit_context::apply_insert): Delete.
17703         (edit_context::apply_replace): Rename to...
17704         (edit_context::apply_fixit): ...this.  Convert to half-open range.
17705         (edited_file::apply_insert): Delete.
17706         (edited_file::apply_replace): Rename to...
17707         (edited_file::apply_fixit): ...this.
17708         (edited_line::~edited_line): Drop deletion of events.
17709         (edited_line::apply_insert): Delete.
17710         (edited_line::apply_replace): Rename to...
17711         (edited_line::apply_fixit): ...this.  Convert to half-open range.
17712         Update for change to type of m_line_events.
17713         * edit-context.h (edit_context::apply_insert): Delete.
17714         (edit_context::apply_replace): Rename to...
17715         (edit_context::apply_fixit): ...this.
17717 2017-05-01  Martin Sebor  <msebor@redhat.com>
17719         * gimple-ssa-sprintf.c (format_integer): Set knownrange when it's
17720         known.
17722 2017-05-01  Uros Bizjak  <ubizjak@gmail.com>
17724         PR target/68491
17725         * config/i386/cpuid.h (__get_cpuid): Always return 0 when
17726         __get_cpuid_max returns 0.
17727         (__get_cpuid_count): Ditto.
17729 2017-05-01  Eric Botcazou  <ebotcazou@adacore.com>
17731         * tree.c (substitute_in_expr) <tcc_vl_exp>: Also inline a call if the
17732         replacement expression is another instance of one of its arguments.
17734 2017-05-01  Jakub Jelinek  <jakub@redhat.com>
17736         PR target/79430
17737         * rtlanal.c (reg_set_p): If reg is a stack_pointer_rtx, also
17738         check for stack push/pop autoinc.
17739         * config/i386/i386.c (ix86_agi_dependent): Return false
17740         if the only reason why modified_in_p returned true is that
17741         addr is SP based and set_insn is a push or pop.
17743 2017-04-29  Jan Hubicka  <hubicka@ucw.cz>
17745         * ipa-inline.c (compute_inlined_call_time): Remove now unnecesary
17746         overflow check.
17748 2017-04-29  Jan Hubicka  <hubicka@ucw.cz>
17750         PR ipa/79224
17751         * ipa-inline-analysis.c (dump_predicate): Add optional parameter NL.
17752         (account_size_time): Use two predicates - exec_pred and
17753         nonconst_pred_ptr.
17754         (evaluate_conditions_for_known_args): Compute both clause and
17755         nonspec_clause.
17756         (evaluate_properties_for_edge): Evaulate both clause and nonspec_clause.
17757         (inline_summary_t::duplicate): Update.
17758         (estimate_function_body_sizes): Caluculate exec and nonconst predicates
17759         separately.
17760         (compute_inline_parameters): Likewise.
17761         (estimate_edge_size_and_time): Update caluclation of time.
17762         (estimate_node_size_and_time): Compute both time and nonspecialized
17763         time.
17764         (estimate_ipcp_clone_size_and_time): Update.
17765         (inline_merge_summary): Update.
17766         (do_estimate_edge_time): Update.
17767         (do_estimate_edge_size): Update.
17768         (do_estimate_edge_hints): Update.
17769         (inline_read_section, inline_write_summary): Stream both new predicates.
17770         * ipa-inline.c (compute_uninlined_call_time): Take uninlined_call_time
17771         as argument.
17772         (compute_inlined_call_time): Cleanup.
17773         (big_speedup_p): Update.
17774         (edge_badness): Update.
17775         * ipa-inline.h (INLINE_TIME_SCALE): Remove.
17776         (size_time_entry): Replace predicate by exec_predicate and
17777         nonconst_predicate.
17778         (edge_growth_cache_entry): Cache both time nad nonspecialized time.
17779         (estimate_edge_time): Return also nonspec_time.
17780         (reset_edge_growth_cache): Update.
17782 2017-04-29  Jakub Jelinek  <jakub@redhat.com>
17784         PR rtl-optimization/80491
17785         * ifcvt.c (noce_process_if_block): When looking for x setter
17786         with missing else_bb, don't check only the insn right before
17787         cond_earliest, but look for the last insn that x is modified in
17788         within the same bb.
17790         PR rtl-optimization/80491
17791         * alias.c (memory_modified_in_insn_p): Return true for CALL_INSNs.
17793 2017-04-29  Marc Glisse  <marc.glisse@inria.fr>
17795         PR tree-optimization/80487
17796         * tree-ssa-alias.c (stmt_kills_ref_p): Handle stpncpy and strncpy.
17798 2017-04-29  Prathamesh Kulkarni  <prathamesh.kulkarni@linaro.org>
17800         PR tree-optimization/79697
17801         * tree-ssa-dce.c (mark_stmt_if_obviously_necessary): Check if callee
17802         is BUILT_IN_STRDUP, BUILT_IN_STRNDUP, BUILT_IN_REALLOC.
17803         (propagate_necessity): Check if def_callee is BUILT_IN_STRDUP or
17804         BUILT_IN_STRNDUP.
17805         * gimple-fold.c (gimple_fold_builtin_realloc): New function.
17806         (gimple_fold_builtin): Call gimple_fold_builtin_realloc.
17808 2017-04-28  Martin Sebor  <msebor@redhat.com>
17810         PR tree-optimization/80523
17811         * gimple-ssa-sprintf.c (target_to_host_charmap): New global variable.
17812         (init_target_to_host_charmap, target_to_host, target_strtol10): New
17813         functions.
17814         (maybe_warn, format_directive, parse_directive): Use new functions.
17815         (pass_sprintf_length::execute): Call init_target_to_host_charmap.
17817 2017-04-28  Marc Glisse  <marc.glisse@inria.fr>
17819         * match.pd (X+Z OP Y+Z, X-Z OP Y-Z, Z-X OP Z-Y): New transformations.
17821 2017-04-28  Bernd Edlinger  <bernd.edlinger@hotmail.de>
17823         * configure.ac (SYSTEM_HEADER_DIR, BUILD_SYSTEM_HEADER_DIR,
17824         target_header_dir): Set correctly.
17825         * configure: Regenerated.
17826         * Makefile.in (BUILD_SYSTEM_HEADER_DIR): New make variabe.
17827         (LIMITS_H_TEST, if_multiarch, stmp-fixinc): Use BUILD_SYSTEM_HEADER_DIR
17828         instead of SYSTEM_HEADER_DIR.
17830 2017-04-28  Jan Hubicka  <hubicka@ucw.cz>
17832         * ipa-cp.c (perform_estimation_of_a_value): Turn time to sreal.
17833         (estimate_local_effects): Likewise.
17834         * ipa-inline.c (compute_inlined_call_time, want_inline_small_function_p,
17835         edge_badness, inline_small_functions, dump_overall_stats): LIkewise.
17836         * ipa-inline.h (edge_growth_cache_entry, estimate_time_after_inlining,
17837         estimate_ipcp_clone_size_and_time, do_estimate_edge_time,
17838         do_estimate_edge_time, estimate_edge_time): Likewise.
17839         * ipa-inline-analysis.c (estimate_node_size_and_time,
17840         estimate_ipcp_clone_size_and_time, do_estimate_edge_time): Likewise.
17841         (estimate_time_after_inlining): Remove.
17843 2017-04-28  Martin Liska  <mliska@suse.cz>
17845         * doc/gcov.texi: Enhance documentation of gcov.
17847 2017-04-28  Martin Liska  <mliska@suse.cz>
17849         * doc/gcov.texi: Sort options in alphabetic order.
17850         * doc/gcov-dump.texi: Likewise.
17851         * doc/gcov-tool.texi: Likewise.
17852         * gcov.c (print_usage): Likewise.
17853         * gcov-dump.c (print_usage): Likewise.
17854         * gcov-tool.c (print_merge_usage_message): Likewise.
17855         (print_rewrite_usage_message): Likewise.
17856         (print_overlap_usage_message): Likewise.
17858 2017-04-28  Martin Liska  <mliska@suse.cz>
17860         PR gcov-profile/53915
17861         * gcov.c (format_gcov): Print 'NAN %' when top > bottom.
17863 2017-04-28  Martin Liska  <mliska@suse.cz>
17865         PR gcov-profile/79891
17866         * gcov.c (add_line_counts): Assign BBs to lines just if the BB
17867         is marked by compiler as living on a line.
17868         (get_cycles_count): Remove usage of the union.
17869         (output_intermediate_file): Likewise.
17870         (find_source): Fix GNU coding style.
17871         (accumulate_line_counts): Remove old non-all block mode.
17872         (output_lines): Remove usage of the union.
17873         * profile.c (output_location): Include all BBs, even if
17874         belonging to a same line (and file) as a previous BB.
17876 2017-04-28  Martin Liska  <mliska@suse.cz>
17878         * gcov.c (process_args): Handle new argument 'w'.
17879         (read_graph_file): Assign ID to BBs.
17880         (output_branch_count): Display BB # if verbose flag is set.
17881         (output_lines): Likewise for arcs.
17882         (print_usage): Add '--verbose' option help.
17883         * doc/gcov.texi: Document --verbose (-w) option.
17885 2017-04-28  Martin Liska  <mliska@suse.cz>
17887         * gcov.c (struct block_location_info): New struct.
17888         (process_file): Fill up the new structure.
17889         (read_graph_file): Replace usage of encoding by the newly added
17890         struct.
17891         (add_line_counts): Likewise.
17892         (accumulate_line_counts): Remove usage of the union.
17893         (function_info::function_info): New function.
17894         (function_info::~function_info): Likewise.
17895         (process_file): Call delete instead of release_function.
17896         (release_function): Release the function.
17897         (release_structures): Call delete instead of release_function.
17898         (solve_flow_graph): Replace usage of num_blocks.
17899         (find_exception_blocks): Likewise.
17900         (output_lines): Fix GNU coding style.
17902 2017-04-28  Martin Liska  <mliska@suse.cz>
17904         PR driver/56469
17905         * coverage.c (coverage_remove_note_file): New function.
17906         * coverage.h: Declare the function.
17907         * toplev.c (finalize): Clean if an error has been seen.
17909 2017-04-28  Martin Liska  <mliska@suse.cz>
17911         PR gcov-profile/80031
17912         * gcov-dump.c (tag_blocks): Just print number of basic blocks.
17913         * gcov-io.h (GCOV_TAG_BLOCKS_NUM): Remove unused macro.
17914         * gcov.c (read_graph_file): Read just number of blocks.
17915         * profile.c (branch_prob): Do not stream 0 flags per a basic
17916         block.
17918 2017-04-28  Martin Liska  <mliska@suse.cz>
17920         * gcov-dump.c (tag_*): Add new argument to declarations.
17921         (dump_gcov_file): Likewise.
17922         (tag_blocks): Add and use new argument depth.
17923         (tag_arcs): Likewise.
17924         (tag_lines): Likewise.
17925         (tag_counters): Likewise.
17926         (tag_summary): Likewise.
17927         (dump_working_sets): Use depth to do a proper indentation.
17929 2017-04-28  Jakub Jelinek  <jakub@redhat.com>
17931         PR bootstrap/80531
17932         * cgraph.h (symtab_node::debug_symtab): No longer inline.
17933         * symtab.c (symtab_node::debug_symtab): Move definition here.
17935 2017-04-28  Richard Biener  <rguenther@suse.de>
17937         * lto-streamer.h (LTO_major_version): Bump to 7.
17939 2017-04-28  Richard Biener  <rguenther@suse.de>
17941         * tree-vrp.c (assert_info): New struct.
17942         (add_assert_info): New helper.
17943         (register_edge_assert_for_2): Refactor to add asserts to a vector
17944         of assert_info.
17945         (register_edge_assert_for_1): Likewise.
17946         (register_edge_assert_for): Likewise.
17947         (finish_register_edge_assert_for): New helper actually registering
17948         asserts where live on edge.
17949         (find_conditional_asserts): Adjust.
17950         (find_switch_asserts): Likewise.
17951         (evrp_dom_walker::try_find_new_range): Generalize.
17952         (evrp_dom_walker::before_dom_children): Use register_edge_assert_for.
17954 2017-04-27  Marek Polacek  <polacek@redhat.com>
17956         PR sanitizer/80349
17957         * fold-const.c (fold_binary_loc) <case EQ_EXPR, NE_EXPR>: Convert
17958         arg10 and arg11 to itype.
17960 2017-04-27  Jonathan Wakely  <jwakely@redhat.com>
17962         * doc/extend.texi (Object Size Checking): Improve grammar.
17964 2017-04-27  Richard Earnshaw  <rearnsha@arm.com>
17966         PR target/80530
17967         * config/aarch64/aarch64.c (aarch64_emit_approx_sqrt): Ensure
17968         that the logic for permitting reciprocal estimates matches that
17969         in use_rsqrt_p.
17971 2017-04-27  Jakub Jelinek  <jakub@redhat.com>
17973         PR c++/80534
17974         * tree.c (type_cache_hasher::equal): Only compare
17975         TYPE_TYPELESS_STORAGE flag on non-aggregate element types.
17976         (build_array_type_1): Only hash TYPE_TYPELESS_STORAGE flag on
17977         non-aggregate element types.
17978         * tree.h (TYPE_TYPELESS_STORAGE): Fix comment typo, add more details
17979         about the flag on ARRAY_TYPEs in the comment, formatting fix.
17981 2017-04-27  Richard Biener  <rguenther@suse.de>
17983         PR middle-end/80533
17984         * emit-rtl.c (set_mem_attributes_minus_bitpos): When
17985         stripping ARRAY_REFs from MEM_EXPR make sure we're not
17986         keeping a reference to a trailing array.
17988 2017-04-27  Richard Biener  <rguenther@suse.de>
17990         PR middle-end/80539
17991         * tree-chrec.c (chrec_fold_plus_poly_poly): Deal with not
17992         being in loop-closed SSA form conservatively.
17993         (chrec_fold_multiply_poly_poly): Likewise.
17995 2017-04-27  Tamar Christina  <tamar.christina@arm.com>
17997         PR middle-end/79665
17998         * expr.c (expand_expr_real_2): Move TRUNC_MOD_EXPR, FLOOR_MOD_EXPR,
17999         CEIL_MOD_EXPR, ROUND_MOD_EXPR cases.
18001 2017-04-27  Jakub Jelinek  <jakub@redhat.com>
18003         PR target/77728
18004         * config/aarch64/aarch64.c (struct aarch64_fn_arg_alignment): Remove.
18005         (aarch64_function_arg_alignment): Return unsigned int again, but still
18006         ignore TYPE_FIELDS chain decls other than FIELD_DECLs.
18007         (aarch64_layout_arg): Adjust aarch64_function_arg_alignment caller.
18008         Don't emit -Wpsabi note.
18009         (aarch64_function_arg_boundary): Likewise.
18010         (aarch64_gimplify_va_arg_expr): Adjust aarch64_function_arg_alignment
18011         caller.
18013 2017-04-26  Nathan Sidwell  <nathan@acm.org>
18015         * tree.h (crc32_unsigned_n): Declare.
18016         (crc32_unsigned, crc32_unsigned): Make inline.
18017         * tree.c (crc32_unsigned_bits): Replace with ...
18018         (crc32_unsigned_n): ... this.
18019         (crc32_unsigned, crc32_byte): Remove.
18020         (crc32_string): Remove unnecessary braces.
18022 2017-04-25  Jan Hubicka  <hubicka@ucw.cz>
18024         * ipa-cp.c (estimate_local_effects): Convert sreal to int.
18025         * ipa-inline-analysis.c (MAX_TIME): Remove.
18026         (account_size_time): Use sreal for time.
18027         (dump_inline_summary): Update.
18028         (estimate_function_body_sizes): Update.
18029         (estimate_edge_size_and_time): Update.
18030         (estimate_calls_size_and_time): Update.
18031         (estimate_node_size_and_time): Update.
18032         (inline_merge_summary): Update.
18033         (inline_update_overall_summary): Update.
18034         (estimate_time_after_inlining): Update.
18035         (inline_read_section): Update.
18036         (inline_write_summary): Update.
18037         * ipa-inline.c (compute_uninlined_call_time): Update.
18038         (compute_inlined_call_time): Update.
18039         (recursive_inlining): Update.
18040         (inline_small_functions): Update.
18041         (dump_overall_stats): Update.
18042         * ipa-inline.h: Include sreal.h.
18043         (size_time_entry): Turn time to sreal.
18044         (inline_summary): Turn self_time nad time to sreal.
18046 2017-04-25  Jan Hubicka  <hubicka@ucw.cz>
18048         * sreal.c: Include backend.h, tree.h, gimple.h, cgraph.h and
18049         data-streamer.h
18050         (sreal::stream_out, sreal::stream_in): New.
18051         * sreal.h (sreal::stream_out, sreal::stream_in): Declare.
18053 2017-04-25  Jakub Jelinek  <jakub@redhat.com>
18055         * Makefile.in (s-options): Invoke opt-gather.awk with LC_ALL=C in the
18056         environment.
18058 2017-04-25  Uros Bizjak  <ubizjak@gmail.com>
18060         PR target/70799
18061         * config/i386/i386.c (dimode_scalar_to_vector_candidate_p):
18062         Handle ASHIFTRT.
18063         (dimode_scalar_chain::compute_convert_gain): Ditto.
18064         (dimode_scalar_chain::make_vector_copies): Ditto.
18065         (dimode_scalar_chain::convert_reg): Ditto.
18066         (dimode_scalar_chain::convert_insn): Ditto.
18067         * config/i386/sse.md (VI24_AVX512BW_1): Remove mode iterator.
18068         (VI248_AVX512BW_1): New mode iterator.
18069         (<mask_codefor>ashr<mode>3<mask_name>): Merge insn pattern with
18070         <mask_codefor>ashrv2di3<mask_name> insn using VI248_AVX512BW_1
18071         mode iterator.
18073 2017-04-25  Martin Sebor  <msebor@redhat.com>
18075         PR tree-optimization/80497
18076         * gimple-ssa-sprintf.c (get_int_range): Avoid assuming all integer
18077         constants are representable in HOST_WIDE_INT.
18078         (parse_directive): Ditto.
18080 2017-04-25  Martin Sebor  <msebor@redhat.com>
18082         PR bootstrap/80486
18083         * dominance.c (dom_info::m_n_basic_blocks): Change type to unsigned.
18084         (new_zero_array): Adjust signature.
18085         (dom_info::dom_init): Used unsigned rather that size_t.
18086         (dom_info::dom_info): Same.
18088 2017-04-25  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
18089             Jakub Jelinek  <jakub@redhat.com>
18091         PR target/77728
18092         * config/arm/arm.c: Include gimple.h.
18093         (aapcs_layout_arg): Emit -Wpsabi note if arm_needs_doubleword_align
18094         returns negative, increment ncrn only if it returned positive.
18095         (arm_needs_doubleword_align): Return int instead of bool,
18096         ignore DECL_ALIGN of non-FIELD_DECL TYPE_FIELDS chain
18097         members, but if there is any such non-FIELD_DECL
18098         > PARM_BOUNDARY aligned decl, return -1 instead of false.
18099         (arm_function_arg): Emit -Wpsabi note if arm_needs_doubleword_align
18100         returns negative, increment nregs only if it returned positive.
18101         (arm_setup_incoming_varargs): Likewise.
18102         (arm_function_arg_boundary): Emit -Wpsabi note if
18103         arm_needs_doubleword_align returns negative, return
18104         DOUBLEWORD_ALIGNMENT only if it returned positive.
18106 2017-04-25  Marek Polacek  <polacek@redhat.com>
18108         PR sanitizer/80349
18109         * fold-const.c (fold_binary_loc) <case BIT_IOR_EXPR>: Convert arg0's
18110         first argument to type.
18112 2017-04-25  Bill Seurer  <seurer@linux.vnet.ibm.com>
18114         PR target/80482
18115         * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin): Change
18116         type checks to test for compatibility instead of equality.
18118 2017-04-25  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
18119             Jakub Jelinek  <jakub@redhat.com>
18121         PR target/77728
18122         * config/aarch64/aarch64.c (struct aarch64_fn_arg_alignment): New
18123         type.
18124         (aarch64_function_arg_alignment): Return aarch64_fn_arg_alignment
18125         struct.  Ignore DECL_ALIGN of decls other than FIELD_DECL for
18126         the alignment computation, but return their maximum in warn_alignment.
18127         (aarch64_layout_arg): Adjust aarch64_function_arg_alignment caller.
18128         Emit a -Wpsabi note if warn_alignment is 16 bytes, but alignment
18129         is smaller.
18130         (aarch64_function_arg_boundary): Likewise.  Simplify using MIN/MAX.
18131         (aarch64_gimplify_va_arg_expr): Adjust aarch64_function_arg_alignment
18132         caller.
18134 2017-04-25  Claudiu Zissulescu  <claziss@synopsys.com>
18136         * config/arc/simdext.md (dmpyh): Fix typo.
18138 2017-04-25  Richard Biener  <rguenther@suse.de>
18140         PR tree-optimization/80492
18141         * alias.c (compare_base_decls): Handle registers with asm
18142         specification conservatively.
18143         * tree-ssa-alias.c (decl_refs_may_alias_p): Handle
18144         compare_base_decls returning dont-know properly.
18146 2017-04-25  Claudiu Zissulescu  <claziss@synopsys.com>
18148         * config/arc/arc.c (LEGITIMATE_OFFSET_ADDRESS_P): Delete macro.
18149         (legitimate_offset_address_p): New function.
18150         (arc_legitimate_address_p): Use above function.
18152 2017-04-25  Claudiu Zissulescu  <claziss@synopsys.com>
18154         * config/arc/arc.c (arc_output_mi_thunk): Emit PIC calls.
18156 2017-04-25  Claudiu Zissulescu  <claziss@synopsys.com>
18158         * config/arc/arc.c (arc_conditional_register_usage): Use ACCL,
18159         ACCH registers whenever they are available.
18161 2017-04-25  Claudiu Zissulescu  <claziss@synopsys.com>
18163         * config/arc/arc.c (arc_conditional_register_usage): Make D0, D1
18164         double regs fix when not used.
18166 2017-04-25  Claudiu Zissulescu  <claziss@synopsys.com>
18168         * config/arc/arc.h (REGNO_OK_FOR_BASE_P): Consider also extension
18169         core registers.
18170         (REG_OK_FOR_INDEX_P_NONSTRICT): Likewise.
18171         (REG_OK_FOR_BASE_P_NONSTRICT): Likewise.
18173 2017-04-25  Claudiu Zissulescu  <claziss@synopsys.com>
18175         * config/arc/arc.c (arc_output_addsi): Check for h-register class
18176         when emitting short ADD instructions.
18178 2017-04-25  Claudiu Zissulescu  <claziss@synopsys.com>
18180         * config/arc/arc.md (cmpsi_cc_insn_mixed): Use 'h' register
18181         constraint.
18182         (cmpsi_cc_c_insn): Likewise.
18183         (cbranchsi4_scratch): Compute proper instruction length using
18184         compact_hreg_operand.
18185         * config/arc/predicates.md (compact_hreg_operand): New predicate.
18187 2017-04-25  Richard Biener  <rguenther@suse.de>
18189         PR middle-end/80509
18190         * passes.c (pass_manager::pass_manager): Initialize
18191         m_name_to_pass_map.
18193 2017-04-25  Richard Biener  <rguenther@suse.de>
18195         PR tree-optimization/79201
18196         * tree-ssa-sink.c (statement_sink_location): Handle calls.
18198 2017-04-25  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
18200         PR target/80464
18201         * config/s390/vector.md: Split MEM->GPR vector moves for
18202         non-s_operand addresses.
18204 2017-04-25  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
18206         PR target/79895
18207         * config/s390/predicates.md (reload_const_wide_int_operand): New
18208         predicate.
18209         * config/s390/s390.md ("movti"): Remove d/P alternative.
18210         ("movti_bigconst"): New pattern definition.
18212 2017-04-25  Dominik Vogt  <vogt@linux.vnet.ibm.com>
18214         PR target/80080
18215         * s390-protos.h (s390_expand_cs_hqi): Removed.
18216         (s390_expand_cs, s390_expand_atomic_exchange_tdsi): New prototypes.
18217         * config/s390/s390.c (s390_emit_compare_and_swap): Handle all integer
18218         modes as well as CCZ1mode and CCZmode.
18219         (s390_expand_atomic_exchange_tdsi, s390_expand_atomic): Adapt to new
18220         signature of s390_emit_compare_and_swap.
18221         (s390_expand_cs_hqi): Likewise, make static.
18222         (s390_expand_cs_tdsi): Generate an explicit compare before trying
18223         compare-and-swap, in some cases.
18224         (s390_expand_cs): Wrapper function.
18225         (s390_expand_atomic_exchange_tdsi): New backend specific expander for
18226         atomic_exchange.
18227         (s390_match_ccmode_set): Allow CCZmode <-> CCZ1 mode.
18228         * config/s390/s390.md ("atomic_compare_and_swap<mode>"): Merge the
18229         patterns for small and large integers.  Forbid symref memory operands.
18230         Move expander to s390.c.  Require cc register.
18231         ("atomic_compare_and_swap<DGPR:mode><CCZZ1:mode>_internal")
18232         ("*atomic_compare_and_swap<TDI:mode><CCZZ1:mode>_1")
18233         ("*atomic_compare_and_swapdi<CCZZ1:mode>_2")
18234         ("*atomic_compare_and_swapsi<CCZZ1:mode>_3"): Use s_operand to forbid
18235         symref memory operands.  Remove CC mode and call s390_match_ccmode
18236         instead.
18237         ("atomic_exchange<mode>"): Allow and implement all integer modes.
18239 2017-04-25  Dominik Vogt  <vogt@linux.vnet.ibm.com>
18241         * config/s390/s390.md (define_peephole2): New peephole to help
18242         combining the load-and-test pattern with volatile memory.
18244 2017-04-25  Dominik Vogt  <vogt@linux.vnet.ibm.com>
18246         * config/s390/s390.md ("cstorecc4"): Use load-on-condition and deal
18247         with CCZmode for TARGET_Z196.
18249 2017-04-25  Jakub Jelinek  <jakub@redhat.com>
18251         PR rtl-optimization/80501
18252         * combine.c (make_compound_operation_int): Set subreg_code to SET
18253         even for AND with mask of the sign bit of mode.
18255         PR rtl-optimization/80500
18256         * loop-unroll.c (combine_var_copies_in_loop_exit): Call copy_rtx on
18257         sum's initial value.
18259 2017-04-25  Julian Brown  <julian@codesourcery.com>
18260             Naveen H.S  <Naveen.Hurugalawadi@cavium.com>
18262         * config/aarch64/thunderx2t99.md (thunderx2t99_crc): New Reservation.
18264 2017-04-25  Marc Glisse  <marc.glisse@inria.fr>
18266         * fold-const.c (tree_single_nonzero_warnv_p): Handle SSA_NAME.
18268 2017-04-25  Julian Brown  <julian@codesourcery.com>
18269             Naveen H.S  <Naveen.Hurugalawadi@cavium.com>
18271         * config/aarch64/thunderx2t99.md (thunderx2t99_aes): New Reservation.
18272         (thunderx2t99_sha): New Reservation.
18274 2017-04-25  Julian Brown  <julian@codesourcery.com>
18275             Naveen H.S  <Naveen.Hurugalawadi@cavium.com>
18277         * config/aarch64/aarch64-simd.md (aarch64_simd_vec_set<mode>): Fix
18278         type for 1-element load.
18280 2017-04-24  Marc Glisse  <marc.glisse@inria.fr>
18282         * match.pd (X/[ex]C CMP Y/[ex]C): New transformation.
18284 2017-04-24  Martin Jambor  <mjambor@suse.cz>
18286         PR tree-optimization/80293
18287         * tree-sra.c (scalarizable_type_p): New parameter const_decl, make
18288         char arrays not totally scalarizable if it is false.
18289         (analyze_all_variable_accesses): Pass correct value in the new
18290         parameter.  Add a statistics counter.
18292 2017-04-24  Jan Hubicka  <hubicka@ucw.cz>
18294         PR middle-end/79931
18295         * ipa-devirt.c (dump_possible_polymorphic_call_targets): Fix ICE.
18297 2017-04-24  Richard Biener  <rguenther@suse.de>
18299         PR tree-optimization/80494
18300         * tree-scalar-evolution.c (analyze_scalar_evolution_1): Bail
18301         out for complex types.
18303 2017-04-24  Richard Biener  <rguenther@suse.de>
18305         * tree-ssa-sccvn.h (run_scc_vn): Adjust prototype.
18306         * tree-ssa-sccvn.c (print_scc): Print SCC size.
18307         (extract_and_process_scc_for_name): Never fail but drop SCC to varying.
18308         (DFS): Adjust and never fail.
18309         (sccvn_dom_walker::fail): Remove.
18310         (sccvn_dom_walker::before_dom_children): Adjust.
18311         (run_scc_vn): Likewise and never fail.
18312         * tree-ssa-pre.c (pass_pre::execute): Adjust.
18313         (pass_fre::execute): Likewise.
18315 2017-04-24  Richard Biener  <rguenther@suse.de>
18317         PR tree-optimization/79725
18318         * tree-ssa-sink.c (statement_sink_location): Return whether
18319         failure reason was zero uses.  Move that check later.
18320         (sink_code_in_bb): Deal with zero uses by removing the stmt
18321         if possible.
18323 2017-04-24  Richard Biener  <rguenther@suse.de>
18325         PR c++/2972
18326         * tree-ssa-uninit.c (warn_uninitialized_vars): Handle some
18327         pointer-based references.
18329 2017-04-24  Richard Biener  <rguenther@suse.de>
18331         PR bootstrap/79814
18332         * pass_manager.h (pass_manager::operator new): Remove.
18333         (pass_manager::operator delete): Likewise.
18334         * passes.c (pass_manager::operator new): Remove.
18335         (pass_manager::operator delete): Likewise.
18336         (pass_manager::pass_manager): Zero individual pass members.
18338 2017-04-23  Uros Bizjak  <ubizjak@gmail.com>
18340         PR target/70799
18341         * config/i386/i386.c (dimode_scalar_to_vector_candidate_p)
18342         <case ASHIFT, case LSHIFTRT>: Also consider variable shifts.
18343         Check "XEXP (src, 1)" operand here.
18344         <case PLUS, case MINUS, case IOR, case XOR, case AND>:
18345         Check "XEXP (src, 1)" operand here.
18346         (dimode_scalar_chain::make_vector_copies): Detect count register
18347         of a shift instruction.  Zero extend count register from QImode
18348         to DImode to satisfy vector shift pattern count operand predicate.
18349         Substitute vector shift count operand with a DImode copy.
18350         (dimode_scalar_chain::convert_reg): Ditto, zero-extend from
18351         vector register.
18353 2017-04-21  Uros Bizjak  <ubizjak@gmail.com>
18355         * config/i386/i386.md (*extzvqi_mem_rex64): Move above *extzv<mode>.
18356         Remove UNSPEC_NOREX_MEM tag.  Update corresponding peephole2 pattern.
18357         (*insvqi_1_mem_rex64): Move above insv<mode>_1.  Remove
18358         UNSPEC_NOREX_MEM tag.  Update corresponding peephole2 pattern.
18359         (UNSPEC_NOREX_MEM): Remove definition.
18361 2017-04-21  Richard Biener  <rguenther@suse.de>
18363         PR tree-optimization/79547
18364         * tree-ssa-structalias.c (find_func_aliases_for_builtin_call):
18365         Handle strlen, strcmp, strncmp, strcasecmp, strncasecmp, memcmp,
18366         bcmp, strspn, strcspn, __builtin_object_size and __builtin_constant_p
18367         without any constraints.
18369 2017-04-21  Richard Biener  <rguenther@suse.de>
18371         PR tree-optimization/78847
18372         * fold-const.c (split_tree): Handle POINTER_PLUS_EXPR.
18374 2017-04-21  Richard Biener  <rguenther@suse.de>
18376         * tree.h (build_qualified_type): Annotate with CXX_MEM_STAT_INFO.
18377         (build_distinct_type_copy): Likewise.
18378         (build_variant_type_copy): Likewise.
18379         * tree.c (build_qualified_type): Pass down mem-stat info.
18380         (build_distinct_type_copy): Likewise.
18381         (build_variant_type_copy): Likewise.
18383 2017-04-21  Richard Biener  <rguenther@suse.de>
18385         PR tree-optimization/80237
18386         * tree-ssa-pre.c (find_leader_in_sets): Add third set argument,
18387         defaulted to NULL.
18388         (phi_translate_1): Also allow a leader in AVAIL_OUT of pred
18389         for a simplified result.
18391 2016-04-21  Richard Biener  <rguenther@suse.de>
18393         * tree-ssa-loop-ivcanon.c (constant_after_peeling): Do not require
18394         sth as strict as a simple_iv but a chrec without symbols and an
18395         operand defined in the loop we are peeling (and not some subloop).
18396         (propagate_constants_for_unrolling): Propagate all constants.
18398 2017-04-20  Uros Bizjak  <ubizjak@gmail.com>
18400         PR target/79804
18401         * config/i386/i386.c (print_reg): Remove assert for disalowed
18402         regno values, call output_operand_lossage instead.
18404 2017-04-20  Uros Bizjak  <ubizjak@gmail.com>
18406         PR target/78090
18407         * config/i386/constraints.md (Yc): New register constraint.
18408         * config/i386/i386.md (*float<SWI48:mode><MODEF:mode>2_mixed):
18409         Use Yc constraint for alternative 2 of operand 0.  Remove
18410         preferred_for_speed attribute.
18412 2017-04-20  Alexander Monakov  <amonakov@ispras.ru>
18414         * omp-low.c (lower_lastprivate_clauses): Correct handling of linear and
18415         lastprivate clauses in SIMT case.
18417 2017-04-20  Volker Reichelt  <v.reichelt@netcologne.de>
18419         * doc/invoke.texi (-Wextra-semi): Document new warning option.
18421 2017-04-20  Richard Biener  <rguenther@suse.de>
18423         PR tree-optimization/57796
18424         * tree-vect-stmts.c (vect_model_store_cost): Cost scatters
18425         as N scalar stores.
18426         (vect_model_load_cost): Cost gathers as N scalar loads.
18428 2017-04-20  Richard Biener  <rguenther@suse.de>
18430         * ggc-page.c (ggc_allocated_p): Rename to ...
18431         (safe_lookup_page_table_entry): ... this and return the lookup
18432         result.
18433         (gt_ggc_m_S): Use safe_lookup_page_table_entry.
18435 2017-04-20  Richard Biener  <rguenther@suse.de>
18437         PR tree-optimization/80453
18438         * tree-ssa-sccvn.h (struct vn_phi_s): Add cclhs and ccrhs members.
18439         * tree-ssa-sccvn.c (cond_stmts_equal_p): Use recorded lhs and rhs
18440         from the conditions.
18441         (vn_phi_eq): Pass them down.
18442         (vn_phi_lookup): Record them.
18443         (vn_phi_insert): Likewise.
18445 2017-04-20  Matthew Fortune  <matthew.fortune@imgtec.com>
18447         * config/mips/mips.c (mips_expand_vec_perm_const): Re-fix
18448         uninitialized variable warning to avoid buffer overrun.
18450 2017-04-20  Alexander Monakov  <amonakov@ispras.ru>
18452         PR other/71250
18453         * doc/invoke.texi (-Wmissing-field-initializers): Mention that warning
18454         is suppressed for '{ 0 }' in C.
18456 2017-04-20  Jakub Jelinek  <jakub@redhat.com>
18458         * BASE-VER: Set to 8.0.0.
18460 2017-04-20  Thomas Preud'homme  <thomas.preudhomme@arm.com>
18462         * config/arm/arm.c (arm_elf_asm_cdtor): Create non-default
18463         priority .init_array and .fini_array section with SECTION_NOTYPE
18464         flag.
18466 2017-04-20  Jakub Jelinek  <jakub@redhat.com>
18468         PR middle-end/80423
18469         * tree.h (build_array_type): Add typeless_storage default argument.
18470         * tree.c (type_cache_hasher::equal): Also compare
18471         TYPE_TYPELESS_STORAGE flag for ARRAY_TYPEs.
18472         (build_array_type): Add typeless_storage argument, set
18473         TYPE_TYPELESS_STORAGE to it, if shared also hash it, and pass to
18474         recursive call.
18475         (build_nonshared_array_type): Adjust build_array_type_1 caller.
18476         (build_array_type): Likewise.  Add typeless_storage argument.
18478 2017-04-19  Eric Botcazou  <ebotcazou@adacore.com>
18479             Jakub Jelinek  <jakub@redhat.com>
18481         PR tree-optimization/80426
18482         * tree-vrp.c (extract_range_from_binary_expr_1): For an additive
18483         operation on symbolic operands, also compute the overflow for the
18484         invariant part when the operation degenerates into a negation.
18486 2017-04-19  Jakub Jelinek  <jakub@redhat.com>
18488         PR debug/80461
18489         * dwarf2out.c (modified_type_die, gen_type_die_with_usage):
18490         Check for t with zero TYPE_QUALS_NO_ADDR_SPACE.
18492         PR debug/80436
18493         * tree-ssa-loop-manip.c (find_uses_to_rename_def): Ignore debug uses.
18495 2017-04-19  Georg-Johann Lay  <avr@gjlay.de>
18497         PR target/80462
18498         * config/avr/avr.c (tree.h): Include it.
18499         (cgraph.h): Include it.
18500         (avr_encode_section_info): Don't warn for uninitialized progmem
18501         variable if it's just an alias.
18503 2017-04-19  Richard Biener  <rguenther@suse.de>
18505         PR ipa/65972
18506         * auto-profile.c (afdo_vpt_for_early_inline): Update SSA
18507         when needed by AutoPGO.
18509 2017-04-19  Paulo J. Matos  <paulo@matos-sorge.com>
18511         PR lto/50345
18512         * doc/lto.texi: Remove an extra 'that'.
18514 2017-04-19  Segher Boessenkool  <segher@kernel.crashing.org>
18516         PR rtl-optimization/80429
18517         * ira.c (split_live_ranges_for_shrink_wrap): Don't split regs that
18518         are only used in debug insns.
18520 2017-04-19  Eric Botcazou  <ebotcazou@adacore.com>
18521             Vladimir Makarov  <vmakarov@redhat.com>
18523         * config/sparc/predicates.md (input_operand): Add comment.  Return
18524         true for any memory operand when LRA is in progress.
18525         * config/sparc/sparc.c (sparc_expand_move): Minor formatting fix.
18527 2017-04-18  Jeff Law  <law@redhat.com>
18529         PR target/74563
18530         * mips.md ({return,simple_return}_internal): Do not overwrite
18531         operands[0].
18533 2017-04-18  Jakub Jelinek  <jakub@redhat.com>
18535         PR tree-optimization/80443
18536         * tree-vrp.c (intersect_ranges): For signed 1-bit precision type,
18537         instead of adding 1, subtract -1 and similarly instead of subtracting
18538         1 add -1.
18540 2017-04-18  Richard Sandiford  <richard.sandiford@arm.com>
18542         PR rtl-optimization/80357
18543         * haifa-sched.c (tmp_bitmap): New variable.
18544         (model_recompute): Handle duplicate use records.
18545         (alloc_global_sched_pressure_data): Initialize tmp_bitmap.
18546         (free_global_sched_pressure_data): Free it.
18548 2017-04-18  Bernd Edlinger  <bernd.edlinger@hotmail.de>
18550         Revert:
18551         2017-02-20  Bernd Edlinger  <bernd.edlinger@hotmail.de>
18552         * Makefile.in (BUILD_SYSTEM_HEADER_DIR): New make variabe.
18553         (LIMITS_H_TEST, if_multiarch, stmp-fixinc): Use BUILD_SYSTEM_HEADER_DIR
18554         instead of SYSTEM_HEADER_DIR.
18556 2017-04-18  Jeff Law  <law@redhat.com>
18558         PR middle-end/80422
18559         * cfgcleanup.c (try_crossjump_to_edge): Verify SRC1 and SRC2 have
18560         predecessors after walking up the insn chain.
18562 2017-04-18  Jakub Jelinek  <jakub@redhat.com>
18564         PR debug/80263
18565         * dwarf2out.c (modified_type_die): Try harder not to emit internal
18566         sizetype type into debug info.
18568 2017-04-18  Michael Meissner  <meissner@linux.vnet.ibm.com>
18570         PR target/80099
18571         * config/rs6000/rs6000.c (rs6000_expand_vector_extract): Eliminate
18572         unneeded test for TARGET_UPPER_REGS_SF.
18573         * config/rs6000/vsx.md (vsx_extract_v4sf_var): Likewise.
18575 2017-04-18  Jakub Jelinek  <jakub@redhat.com>
18577         PR sanitizer/80444
18578         * sancov.c (sancov_pass): Use gsi_start_nondebug_after_labels_bb
18579         instead of gsi_after_labels.
18581 2017-04-18  Jeff Law  <law@redhat.com>
18583         * regcprop.c (maybe_mode_change): Avoid creating copies of the
18584         stack pointer.
18586         Revert:
18587         2017-04-13  Jeff Law  <law@redhat.com>
18588         * config/mips.mips.md (zero_extendsidi2): Do not allow SP to appear
18589         in operands[1] if it is a MEM and TARGET_MIPS16 is active.
18591 2017-04-18  Georg-Johann Lay  <avr@gjlay.de>
18593         PR target/79453
18594         * config/avr/avr.c (intl.h): Include it.
18595         (avr_pgm_check_var_decl) [reason]: Wrap diagnostic snippets into _().
18597 2017-04-18  Martin Liska  <mliska@suse.cz>
18599         PR gcov-profile/78783
18600         * gcov-tool.c (gcov_output_files): Validate that destination
18601         file is either removed by the tool or by a user.
18603 2017-04-14  Andrew Burgess  <andrew.burgess@embecosm.com>
18604             Guy Benyei  <guybe@mellanox.com>
18606         * config/arc/arc.c (arc_reorg): Move loop_end_id into a more local
18607         block, and do not negate it, the stored id is already negative.
18609 2017-04-14  Andrew Burgess  <andrew.burgess@embecosm.com>
18611         * config/arc/arc.md (doloop_begin_i): Use @pcl assembler syntax.
18613 2017-04-14  Michael Meissner  <meissner@linux.vnet.ibm.com>
18615         PR target/80098
18616         * config/rs6000/rs6000-cpus.def (OTHER_P9_VECTOR_MASKS): Define
18617         masks of options that should be turned off if the VSX vector
18618         options are turned off.
18619         (OTHER_P8_VECTOR_MASKS): Likewise.
18620         (OTHER_VSX_VECTOR_MASKS): Likewise.
18621         * config/rs6000/rs6000.c (rs6000_option_override_internal): Call
18622         rs6000_disable_incompatible_switches to validate no type switches
18623         like -mvsx.
18624         (rs6000_incompatible_switch): New function to disallow turning on
18625         other vector options if -mno-vsx, -mno-power8-vector, or
18626         -mno-power9-vector are specified.
18628 2017-04-14  Claudiu Zissulescu  <claziss@synopsys.com>
18630         * config/arc/arc.h (CRT_CALL_STATIC_FUNCTION): Use long calls.
18632 2017-04-14  Claudiu Zissulescu  <claziss@synopsys.com>
18634         * config/arc/arc-protos.h (arc_decl_pretend_args): Remove.
18635         * config/arc/arc.c (arc_decl_pretend_args): Likewise.
18636         * config/arc/arc.h (CFA_FRAME_BASE_OFFSET): Likewise.
18637         (ARG_POINTER_CFA_OFFSET): Likewise.
18639 2017-04-14  Claudiu Zissulescu  <claziss@synopsys.com>
18641         * config/arc/arc.c (arc_mode_dependent_address_p): Relax
18642         conditions to take advantage of various optimizations.
18644 2017-04-13  Jeff Law  <law@redhat.com>
18646         * config/mips.mips.md (zero_extendsidi2): Do not allow SP to appear
18647         in operands[1] if it is a MEM and TARGET_MIPS16 is active.
18648         (zero_extendsidi2_dext): Likewise.
18650 2017-04-13  Jakub Jelinek  <jakub@redhat.com>
18652         PR sanitizer/80403
18653         * fold-const.c (fold_ternary_loc): Revert
18654         use op0 instead of fold_convert_loc (loc, type, arg0) part of
18655         2017-04-12 change.
18657 2017-04-13  Vladimir Makarov  <vmakarov@redhat.com>
18659         PR rtl-optimization/80343
18660         * lra-remat.c (update_scratch_ops): Assign original hard reg to
18661         new scratch pseudo.
18663 2017-04-13  Denis Khalikov <d.khalikov@partner.samsung.com>
18665         PR sanitizer/80414
18666         * ubsan.c (ubsan_expand_bounds_ifn): Pass original index
18667         to ubsan_encode_value.
18669 2017-04-13  Jeff Law  <law@redhat.com>
18671         * reload1.c (eliminate_regs_1): Call gen_rtx_raw_SUBREG for SUBREGs
18672         appearing in DEBUG_INSNs.
18674 2017-04-13  Martin Liska  <mliska@suse.cz>
18676         PR gcov-profile/80413
18677         * gcov-io.c (gcov_write_string): Copy to buffer just when
18678         allocated size is greater than zero.
18680 2017-04-13  Jakub Jelinek  <jakub@redhat.com>
18682         PR debug/80321
18683         * dwarf2out.c (decls_for_scope): Ignore declarations of
18684         current_function_decl in BLOCK_NONLOCALIZED_VARS.
18686 2017-04-12  Jan Hubicka  <hubicka@ucw.cz>
18688         PR lto/69953
18689         * ipa-visibility.c (non_local_p): Fix typos.
18690         (localize_node): When localizing symbol in same comdat group,
18691         dissolve the group only when we know external symbols are going
18692         to be privatized.
18693         (function_and_variable_visibility): Do not localize DECL_EXTERNAL.
18695 2017-04-12  Jakub Jelinek  <jakub@redhat.com>
18697         PR tree-optimization/79390
18698         * optabs.c (emit_conditional_move): If the preferred op2/op3 operand
18699         order does not result in usable sequence, retry with reversed operand
18700         order.
18702         PR sanitizer/80403
18703         PR sanitizer/80404
18704         PR sanitizer/80405
18705         * fold-const.c (fold_ternary_loc): Use op1 instead of arg1 as argument
18706         to fold_build2_loc.  Convert TREE_OPERAND (tem, 0) to type.  Use
18707         op0 instead of fold_convert_loc (loc, type, arg0).
18709 2017-04-12  Jeff Law  <law@redhat.com>
18711         * genattrtab.c (write_eligible_delay): Verify DELAY_INSN still
18712         has a delay slot in the generated code.
18714         * config/cris/cris.md (cris_preferred_reload_class): Return
18715         GENNONACR_REGS rather than GENERAL_REGS.
18717 2017-04-12  Jakub Jelinek  <jakub@redhat.com>
18719         PR c/80163
18720         * expr.c <CASE_CONVERT>: For EXPAND_INITIALIZER determine SIGN_EXTEND
18721         vs. ZERO_EXTEND based on signedness of treeop0's type rather than
18722         signedness of the result type.
18724 2017-04-12  Richard Biener  <rguenther@suse.de>
18725             Jeff Law  <law@redhat.com>
18727         PR tree-optimization/80359
18728         * tree-ssa-dse.c (maybe_trim_partially_dead_store): Do not
18729         trim stores to TARGET_MEM_REFs.
18731 2017-04-12  Richard Biener  <rguenther@suse.de>
18733         PR tree-optimization/79390
18734         * gimple-ssa-split-paths.c (is_feasible_trace): Restrict
18735         threading case even more.
18737 2017-04-12  Segher Boessenkool  <segher@kernel.crashing.org>
18739         PR target/80382
18740         * config/rs6000/sync.md (atomic_load<mode>, atomic_store<mode): Test
18741         for quad_address_p for TImode, instead of just not indexed_address.
18743 2017-04-12  Richard Biener  <rguenther@suse.de>
18744             Bernd Edlinger  <bernd.edlinger@hotmail.de>
18746         PR middle-end/79671
18747         * alias.c (component_uses_parent_alias_set_from): Handle
18748         TYPE_TYPELESS_STORAGE.
18749         (get_alias_set): Likewise.
18750         * tree-core.h (tree_type_common): Add typeless_storage flag.
18751         * tree.h (TYPE_TYPELESS_STORAGE): New macro.
18752         * stor-layout.c (place_union_field): Set TYPE_TYPELESS_STORAGE
18753         for types containing members with TYPE_TYPELESS_STORAGE.
18754         (place_field): Likewise.
18755         (layout_type): Likewise for ARRAY_TYPE.
18756         * lto-streamer-out.c (hash_tree): Hash TYPE_TYPELESS_STORAGE.
18757         * tree-streamer-in.c (unpack_ts_type_common_value_fields): Stream
18758         TYPE_TYPELESS_STORAGE.
18759         * tree-streamer-out.c (pack_ts_type_common_value_fields): Likewise.
18761 2017-04-12  Jakub Jelinek  <jakub@redhat.com>
18763         PR sanitizer/80349
18764         * fold-const.c (fold_binary_loc) <case BIT_IOR_EXPR>: Convert arg0's
18765         first argument to type.
18767 2017-04-11  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
18769         PR target/80376
18770         PR target/80315
18771         * config/rs6000/rs6000.c (rs6000_expand_unop_builtin): Return
18772         CONST0_RTX (mode) rather than const0_rtx where appropriate.
18773         (rs6000_expand_binop_builtin): Likewise.
18774         (rs6000_expand_ternop_builtin): Likewise; also add missing
18775         vsx_xxpermdi_* variants; also fix typo (arg1 => arg2) for
18776         vshasigma built-ins.
18777         * doc/extend.texi: Document that vec_xxpermdi's third argument
18778         must be a constant.
18780 2017-04-11  Uros Bizjak  <ubizjak@gmail.com>
18782         * config/i386/i386.c (dimode_scalar_chain::compute_convert_gain):
18783         Use shift_const cost parameter when calculating gain of STV shifts.
18785 2017-04-11  Vladimir Makarov  <vmakarov@redhat.com>
18787         PR rtl-optimization/70478
18788         * lra-constraints.c (process_alt_operands): Check memory for
18789         disfavoring memory insn operand.
18791 2017-04-11  Jakub Jelinek  <jakub@redhat.com>
18793         PR middle-end/80100
18794         * simplify-rtx.c (simplify_binary_operation_1) <case IOR>: Perform
18795         left shift in unsigned HOST_WIDE_INT type.
18797         PR rtl-optimization/80385
18798         * simplify-rtx.c (simplify_unary_operation_1): Don't transform
18799         (not (neg X)) into (plus X -1) for complex or non-integral modes.
18801         PR libgomp/80394
18802         * omp-low.c (scan_omp_task): Don't optimize away empty tasks
18803         if they have any depend clauses.
18805 2017-04-11  Martin Liska  <mliska@suse.cz>
18807         PR ipa/80212
18808         * cgraph.c (cgraph_node::dump): Dump calls_comdat_local.
18809         * ipa-split.c (split_function): Create a local comdat symbol
18810         if caller is in a comdat group.
18812 2017-04-11  Martin Liska  <mliska@suse.cz>
18814         PR ipa/80212
18815         * ipa-cp.c (determine_versionability): Handle calls_comdat_local
18816         flags.
18818 2017-04-11  Martin Sebor  <msebor@redhat.com>
18820         PR middle-end/80364
18821         * gimple-ssa-sprintf.c (get_int_range): Remove second argument and
18822         always use the int type.  Use INTEGRAL_TYPE_P() rather than testing
18823         for INTEGER_TYPE.
18824         (directive::set_width, directive::set_precision, format_character):
18825         Adjust.
18826         (parse_directive): Use INTEGRAL_TYPE_P() rather than testing for
18827         INTEGER_TYPE.
18829 2017-04-11  Richard Earnshaw  <rearnsha@arm.com>
18831         PR target/80389
18832         * config/arm/arm.c (arm_configure_build_target): When -mcpu and -arch
18833         conflict, set target->arch_name instead of target->cpu_name.
18835 2017-04-11  Richard Biener  <rguenther@suse.de>
18837         PR tree-optimization/80374
18838         * tree-ssa-dom.c (derive_equivalences_from_bit_ior): Use
18839         build_zero_cst, remove fold_convertible_p check again.
18841 2017-04-11  Martin Liska  <mliska@suse.cz>
18843         PR sanitizer/70878
18844         * ubsan.c (instrument_object_size): Do not instrument register
18845         variables.
18847 2017-04-11  Jakub Jelinek  <jakub@redhat.com>
18849         PR target/80381
18850         * config/i386/i386-builtin-types.def
18851         (V16HI_FTYPE_V16HI_INT_V16HI_UHI_COUNT,
18852         V16HI_FTYPE_V16HI_V8HI_V16HI_UHI_COUNT,
18853         V16SI_FTYPE_V16SI_INT_V16SI_UHI_COUNT,
18854         V16SI_FTYPE_V16SI_V4SI_V16SI_UHI_COUNT,
18855         V2DI_FTYPE_V2DI_INT_V2DI_UQI_COUNT,
18856         V2DI_FTYPE_V2DI_V2DI_V2DI_UQI_COUNT,
18857         V32HI_FTYPE_V32HI_INT_V32HI_USI_COUNT,
18858         V32HI_FTYPE_V32HI_V8HI_V32HI_USI_COUNT,
18859         V4DI_FTYPE_V4DI_INT_V4DI_UQI_COUNT,
18860         V4DI_FTYPE_V4DI_V2DI_V4DI_UQI_COUNT,
18861         V4SI_FTYPE_V4SI_INT_V4SI_UQI_COUNT,
18862         V4SI_FTYPE_V4SI_V4SI_V4SI_UQI_COUNT,
18863         V8DI_FTYPE_V8DI_INT_V8DI_UQI_COUNT,
18864         V8DI_FTYPE_V8DI_V2DI_V8DI_UQI_COUNT,
18865         V8HI_FTYPE_V8HI_INT_V8HI_UQI_COUNT,
18866         V8HI_FTYPE_V8HI_V8HI_V8HI_UQI_COUNT,
18867         V8SI_FTYPE_V8SI_INT_V8SI_UQI_COUNT,
18868         V8SI_FTYPE_V8SI_V4SI_V8SI_UQI_COUNT): New function type aliases.
18869         * config/i386/i386-builtin.def (__builtin_ia32_pslld512_mask,
18870         __builtin_ia32_pslldi512_mask, __builtin_ia32_psllq512_mask,
18871         __builtin_ia32_psllqi512_mask, __builtin_ia32_psrad512_mask,
18872         __builtin_ia32_psradi512_mask, __builtin_ia32_psraq512_mask,
18873         __builtin_ia32_psraqi512_mask, __builtin_ia32_psrld512_mask,
18874         __builtin_ia32_psrldi512_mask, __builtin_ia32_psrlq512_mask,
18875         __builtin_ia32_psrlqi512_mask, __builtin_ia32_psllwi128_mask,
18876         __builtin_ia32_pslldi128_mask, __builtin_ia32_psllqi128_mask,
18877         __builtin_ia32_psllw128_mask, __builtin_ia32_pslld128_mask,
18878         __builtin_ia32_psllq128_mask, __builtin_ia32_psllwi256_mask,
18879         __builtin_ia32_psllw256_mask, __builtin_ia32_pslldi256_mask,
18880         __builtin_ia32_pslld256_mask, __builtin_ia32_psllqi256_mask,
18881         __builtin_ia32_psllq256_mask, __builtin_ia32_psradi128_mask,
18882         __builtin_ia32_psrad128_mask, __builtin_ia32_psradi256_mask,
18883         __builtin_ia32_psrad256_mask, __builtin_ia32_psraqi128_mask,
18884         __builtin_ia32_psraq128_mask, __builtin_ia32_psraqi256_mask,
18885         __builtin_ia32_psraq256_mask, __builtin_ia32_psrldi128_mask,
18886         __builtin_ia32_psrld128_mask, __builtin_ia32_psrldi256_mask,
18887         __builtin_ia32_psrld256_mask, __builtin_ia32_psrlqi128_mask,
18888         __builtin_ia32_psrlq128_mask, __builtin_ia32_psrlqi256_mask,
18889         __builtin_ia32_psrlq256_mask, __builtin_ia32_psrawi256_mask,
18890         __builtin_ia32_psraw256_mask, __builtin_ia32_psrawi128_mask,
18891         __builtin_ia32_psraw128_mask, __builtin_ia32_psrlwi256_mask,
18892         __builtin_ia32_psrlw256_mask, __builtin_ia32_psrlwi128_mask,
18893         __builtin_ia32_psrlw128_mask, __builtin_ia32_psllwi512_mask,
18894         __builtin_ia32_psllw512_mask, __builtin_ia32_psrawi512_mask,
18895         __builtin_ia32_psraw512_mask, __builtin_ia32_psrlwi512_mask,
18896         __builtin_ia32_psrlw512_mask): Use _COUNT suffixed function type
18897         aliases.
18898         * config/i386/i386.c (ix86_expand_args_builtin): Rename last_arg_count
18899         flag to second_arg_count, handle 4 argument function type _COUNT
18900         aliases, handle second_arg_count on second argument rather than last.
18902 2017-04-10  Jeff Law  <law@redhat.com>
18904         PR tree-optimization/80374
18905         * tree-ssa-dom.c (derive_equivalences_from_bit_ior): Do not try to
18906         record anything if we can not convert integer_zero_node to the
18907         desired type.
18909 2017-04-10  Kelvin Nilsen  <kelvin@gcc.gnu.org>
18911         PR target/80108
18912         * config/rs6000/rs6000.c (rs6000_option_override_internal):
18913         Enhance special handling given to the TARGET_P9_MINMAX option in
18914         relation to certain other options.
18916 2017-04-10  Bin Cheng  <bin.cheng@arm.com>
18918         PR tree-optimization/80153
18919         * tree-ssa-loop-ivopts.c (add_iv_candidate_for_use): Check and
18920         remove POINTER_PLUS_EXPR's base part directly, rather than through
18921         aff_tree.
18923 2017-04-10  Richard Biener  <rguenther@suse.de>
18924             Bin Cheng  <bin.cheng@arm.com>
18926         PR tree-optimization/80153
18927         * tree-affine.c (aff_combination_to_tree): Get base pointer from
18928         the first element of pointer type aff_tree.  Build result expr in
18929         aff_tree's type.
18930         (add_elt_to_tree): Convert to type unconditionally.  Remove other
18931         fold_convert calls.
18932         * tree-ssa-loop-ivopts.c (alloc_iv): Pass in consistent types.
18933         (rewrite_use_nonlinear_expr): Check invariant using iv information.
18935 2017-04-10  Richard Biener  <rguenther@suse.de>
18937         * tree-ssa-structalias.c (find_func_aliases): Properly handle
18938         asm inputs.
18940 2017-04-10  Vladimir Makarov  <vmakarov@redhat.com>
18942         PR rtl-optimization/70478
18943         * lra-constraints.c (curr_small_class_check): New.
18944         (update_and_check_small_class_inputs): New.
18945         (process_alt_operands): Update curr_small_class_check.  Disfavor
18946         alternative insn memory operands.  Check available regs for small
18947         class operands.
18949 2017-03-31  Matthew Fortune  <matthew.fortune@imgtec.com>
18951         PR target/80057
18952         * config/mips/mips.opt (-mvirt): Update description.
18953         * doc/invoke.texi (-mvirt): Likewise.
18955 2017-04-10  Richard Biener  <rguenther@suse.de>
18957         PR middle-end/80362
18958         * fold-const.c (fold_binary_loc): Look at unstripped ops when
18959         looking for NEGATE_EXPR in -A / -B to A / B folding.
18961 2017-04-10  Martin Liska  <mliska@suse.cz>
18963         PR gcov-profile/80224
18964         * gcov.c (print_usage): Fix usage string.
18965         (get_gcov_intermediate_filename): Remove.
18966         (output_gcov_file): Use both for normal and intermediate format.
18967         (generate_results): Do not initialize special file for
18968         intermediate format.
18970 2017-04-10  Richard Biener  <rguenther@suse.de>
18972         PR tree-optimization/80304
18973         * tree-ssa-loop-im.c (ref_indep_loop_p_1): Also recurse
18974         for safelen.
18976 2017-04-10  Nathan Sidwell  <nathan@acm.org>
18978         PR target/79905
18979         * config/rs6000/rs6000.c (rs6000_vector_type): New.
18980         (rs6000_init_builtins): Use it.
18982 2016-04-10  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
18984         * config/arm/arm.md (<mrc>): Add mode to SET source.
18985         (<mrrc>): Likewise.
18987 2017-04-10  Richard Biener  <rguenther@suse.de>
18989         PR middle-end/80344
18990         * gimplify.c (is_gimple_mem_rhs_or_call): Allow CLOBBERs.
18992 2017-04-10  Jakub Jelinek  <jakub@redhat.com>
18994         PR target/80324
18995         * config/i386/avx512fintrin.h (_mm512_reduce_add_epi32,
18996         _mm512_reduce_mul_epi32, _mm512_reduce_and_epi32,
18997         _mm512_reduce_or_epi32, _mm512_mask_reduce_add_epi32,
18998         _mm512_mask_reduce_mul_epi32, _mm512_mask_reduce_and_epi32,
18999         _mm512_mask_reduce_or_epi32, _mm512_reduce_min_epi32,
19000         _mm512_reduce_max_epi32, _mm512_reduce_min_epu32,
19001         _mm512_reduce_max_epu32, _mm512_mask_reduce_min_epi32,
19002         _mm512_mask_reduce_max_epi32, _mm512_mask_reduce_min_epu32,
19003         _mm512_mask_reduce_max_epu32, _mm512_reduce_add_ps,
19004         _mm512_reduce_mul_ps, _mm512_mask_reduce_add_ps,
19005         _mm512_mask_reduce_mul_ps, _mm512_reduce_min_ps, _mm512_reduce_max_ps,
19006         _mm512_mask_reduce_min_ps, _mm512_mask_reduce_max_ps,
19007         _mm512_reduce_add_epi64, _mm512_reduce_mul_epi64,
19008         _mm512_reduce_and_epi64, _mm512_reduce_or_epi64,
19009         _mm512_mask_reduce_add_epi64, _mm512_mask_reduce_mul_epi64,
19010         _mm512_mask_reduce_and_epi64, _mm512_mask_reduce_or_epi64,
19011         _mm512_reduce_min_epi64, _mm512_reduce_max_epi64,
19012         _mm512_mask_reduce_min_epi64, _mm512_mask_reduce_max_epi64,
19013         _mm512_reduce_min_epu64, _mm512_reduce_max_epu64,
19014         _mm512_mask_reduce_min_epu64, _mm512_mask_reduce_max_epu64,
19015         _mm512_reduce_add_pd, _mm512_reduce_mul_pd, _mm512_mask_reduce_add_pd,
19016         _mm512_mask_reduce_mul_pd, _mm512_reduce_min_pd, _mm512_reduce_max_pd,
19017         _mm512_mask_reduce_min_pd, _mm512_mask_reduce_max_pd): New intrinsics.
19019 2017-04-08  Vladimir Makarov  <vmakarov@redhat.com>
19021         PR rtl-optimization/70478
19022         * lra-constraints.c: Reverse the last patch.
19024 2017-04-08  Andreas Tobler  <andreast@gcc.gnu.org>
19026         * config/aarch64/aarch64-freebsd.h: Define MCOUNT_NAME.
19027         Add comment for WCHAR_T.
19029 2017-04-08  Martin Liska  <mliska@suse.cz>
19031         Revert:
19032         2017-04-07  Martin Liska  <mliska@suse.cz>
19034         PR ipa/80212
19035         * ipa-split.c (split_function): Add function part to a same comdat
19036         group.
19038 2017-04-08  Aaron Sawdey  <acsawdey@linux.vnet.ibm.com>
19040         PR target/80358
19041         * config/rs6000/rs6000.c (expand_block_compare): Fix boundary check.
19043 2017-04-07  Pat Haugen  <pthaugen@us.ibm.com>
19045         * rs6000/rs6000.c (vec_load_pendulum): Rename...
19046         (vec_pairing): ...to this.
19047         (power9_sched_reorder2): Rewrite code for pairing vector/vecload insns.
19048         (rs6000_sched_init): Adjust for name change.
19049         (struct rs6000_sched_context): Likewise.
19050         (rs6000_init_sched_context): Likewise.
19051         (rs6000_set_sched_context): Likewise.
19053 2017-04-07  Jakub Jelinek  <jakub@redhat.com>
19055         PR target/80322
19056         PR target/80323
19057         PR target/80325
19058         PR target/80326
19059         * config/i386/avxintrin.h (_mm256_cvtsd_f64, _mm256_cvtss_f32): New
19060         intrinsics.
19061         * config/i386/avx512fintrin.h (_mm512_int2mask, _mm512_mask2int,
19062         _mm512_abs_ps, _mm512_mask_abs_ps, _mm512_abs_pd, _mm512_mask_abs_pd,
19063         _mm512_cvtsd_f64, _mm512_cvtss_f32): Likewise.
19065 2017-04-07  Andreas Tobler  <andreast@gcc.gnu.org>
19067         * config/aarch64/aarch64-freebsd.h: Define WCHAR_TYPE.
19069 2017-04-07  Vladimir Makarov  <vmakarov@redhat.com>
19071         PR rtl-optimization/70703
19072         * ira-color.c (update_conflict_hard_regno_costs): Use
19073         int64_t instead of HOST_WIDE_INT.
19075 2017-04-07  Vladimir Makarov  <vmakarov@redhat.com>
19077         PR rtl-optimization/70478
19078         * lra-constraints.c (process_alt_operands): Disfavor alternative
19079         insn memory operands.
19081 2017-04-07  Jeff Law  <law@redhat.com>
19083         * config/iq2000/iq2000.c (final_prescan_insn): Do not separate a
19084         CALL and NOTE_INSN_CALL_ARG_LOCATION.
19086 2017-04-07  Martin Liska  <mliska@suse.cz>
19088         PR target/79889
19089         * config/aarch64/aarch64.c (aarch64_process_target_attr):
19090         Show error message instead of an ICE.
19092 2017-04-07  Martin Liska  <mliska@suse.cz>
19094         PR ipa/80212
19095         * ipa-split.c (split_function): Add function part to a same comdat
19096         group.
19098 2017-04-07  Richard Biener  <rguenther@suse.de>
19100         PR middle-end/80341
19101         * tree.c (get_unwidened): Also handle ! for_type case for
19102         INTEGER_CSTs.
19103         * convert.c (do_narrow): Split out from ...
19104         (convert_to_integer_1): ... here.  Do not pass final truncation
19105         type to get_unwidened for TRUNC_DIV_EXPR.
19107 2017-04-07  Richard Biener  <rguenther@suse.de>
19109         * tree-affine.c (wide_int_ext_for_comb): Take type rather
19110         than aff_tree.
19111         (aff_combination_const): Adjust.
19112         (aff_combination_scale): Likewise.
19113         (aff_combination_add_elt): Likewise.
19114         (aff_combination_add_cst): Likewise.
19115         (aff_combination_convert): Likewise.
19116         (add_elt_to_tree): Likewise.  Remove unused argument.
19117         (aff_combination_to_tree): Adjust calls to add_elt_to_tree.
19119 2017-04-07  Sebastian Huber  <sebastian.huber@embedded-brains.de>
19121         * config/arm/arm.h (ARM_DEFAULT_SHORT_ENUMS): Provide default
19122         definition.
19123         * config/arm/arm.c (arm_default_short_enums): Use
19124         ARM_DEFAULT_SHORT_ENUMS.
19125         * config/arm/rtems.h (ARM_DEFAULT_SHORT_ENUMS): Define.
19127 2017-04-06  Jakub Jelinek  <jakub@redhat.com>
19129         PR debug/80234
19130         * dwarf2out.c (gen_member_die): Handle C++17 inline static data
19131         members with redundant out-of-class redeclaration.
19133 2017-04-06  Uros Bizjak  <ubizjak@gmail.com>
19135         PR target/80286
19136         * config/i386/sse.md (*vec_extractv4si_0_zext_sse4): New pattern.
19137         * config/i386/i386.md (*zero_extendsidi2):
19138         Add (?*x,*x) and (?*v,*v) alternatives.
19140 2017-04-06  Uros Bizjak  <ubizjak@gmail.com>
19142         PR target/79733
19143         * config/i386/i386.c (ix86_expand_builtin)
19144         <case IX86_BUILTIN_K{,OR}TEST{C,Z}{8,16,32,64}>: Determine insn operand
19145         mode from insn data. Convert operands to insn operand mode.
19146         Copy operands that don't satisfy insn predicate to a register.
19148 2017-04-06  Sam Thursfield  <sam.thursfield@codethink.co.uk>
19150         * config/rs6000/x-aix: Increase memory limit for genautomata on AIX.
19151         Update comments.
19153 2017-04-06  Richard Biener  <rguenther@suse.de>
19155         PR tree-optimization/80334
19156         * tree-ssa-loop-ivopts.c (rewrite_use_address): Properly
19157         preserve alignment of accesses.
19159 2017-04-06  Richard Biener  <rguenther@suse.de>
19161         PR tree-optimization/80262
19162         * tree-sra.c (build_ref_for_offset): Preserve address-space
19163         information.
19164         * tree-ssa-sccvn.c (vn_reference_maybe_forwprop_address):
19165         Drop useless address-space information on MEM_REF offsets.
19167 2017-04-05  Andreas Schwab  <schwab@linux-m68k.org>
19169         * builtins.def (BUILT_IN_UPDATE_SETJMP_BUF): Fix type.
19171 2017-04-05  Vladimir Makarov  <vmakarov@redhat.com>
19173         PR rtl-optimization/70703
19174         * ira-color.c (update_conflict_hard_regno_costs): Use
19175         HOST_WIDE_INT instead of long.
19177 2017-04-05  Uros Bizjak  <ubizjak@gmail.com>
19179         PR target/80298
19180         * config/i386/mmintrin.h: Add -msse target option when __SSE__ is
19181         not defined for x86_64 target.  Add -mmmx target option when __SSE2__
19182         is not defined.
19183         * config/i386/mm3dnow.h: Add -msse target when __SSE__ is not defined
19184         for x86_64 target.  Handle -m3dnowa option.
19186 2017-04-05  Vladimir Makarov  <vmakarov@redhat.com>
19188         PR rtl-optimization/70703
19189         * ira-color.c (update_costs_from_allocno): Use the smallest mode.
19190         (update_conflict_hard_regno_costs): Use long instead of unsigned
19191         arithmetic for cost calculation.
19193 2017-04-05  Jakub Jelinek  <jakub@redhat.com>
19194             Bernd Edlinger  <bernd.edlinger@hotmail.de>
19196         PR sanitizer/80308
19197         * asan.c (asan_store_shadow_bytes): Fix location of last_chunk_value
19198         for big endian.
19200 2017-04-05  Eric Botcazou  <ebotcazou@adacore.com>
19202         PR target/78002
19203         * config/aarch64/aarch64.c (aarch64_emit_probe_stack_range): Replace
19204         ptr_mode with Pmode throughout.
19205         * config/aarch64/aarch64.md (probe_stack_range_<PTR:mode): Rename
19206         into probe_stack_range and use DImode.
19208 2017-04-05  Dominik Vogt  <vogt@linux.vnet.ibm.com>
19210         PR target/79890
19211         * config/s390/s390.c (s390_register_info_gprtofpr): Return if
19212         call_eh_return is true.
19214 2017-04-05  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
19216         * config/s390/s390-c.c (s390_resolve_overloaded_builtin):
19217         Initialize last_match_fntype_index.
19219 2017-04-05  Jakub Jelinek  <jakub@redhat.com>
19221         PR target/80310
19222         * tree-nvr.c: Include internal-fn.h.
19223         (pass_return_slot::execute): Ignore internal calls without
19224         direct optab.
19226 2017-04-04  Jakub Jelinek  <jakub@redhat.com>
19227             Richard Biener  <rguenther@suse.de>
19229         PR c++/80297
19230         * genmatch.c (capture::gen_transform): For GENERIC unshare_expr
19231         captures used multiple times, except for the last use.
19232         * generic-match-head.c: Include gimplify.h.
19234 2017-04-04  Jakub Jelinek  <jakub@redhat.com>
19236         PR tree-optimization/79390
19237         * target.h (struct noce_if_info): Declare.
19238         * targhooks.h (default_noce_conversion_profitable_p): Declare.
19239         * target.def (noce_conversion_profitable_p): New target hook.
19240         * ifcvt.h (struct noce_if_info): New type, moved from ...
19241         * ifcvt.c (struct noce_if_info): ... here.
19242         (noce_conversion_profitable_p): Renamed to ...
19243         (default_noce_conversion_profitable_p): ... this.  No longer
19244         static nor inline.
19245         (noce_try_store_flag_constants, noce_try_addcc,
19246         noce_try_store_flag_mask, noce_try_cmove, noce_try_cmove_arith,
19247         noce_convert_multiple_sets): Use targetm.noce_conversion_profitable_p
19248         instead of noce_conversion_profitable_p.
19249         * config/i386/i386.c: Include ifcvt.h.
19250         (ix86_option_override_internal): Don't override
19251         PARAM_MAX_RTL_IF_CONVERSION_INSNS default.
19252         (ix86_noce_conversion_profitable_p): New function.
19253         (TARGET_NOCE_CONVERSION_PROFITABLE_P): Redefine.
19254         * config/i386/x86-tune.def (X86_TUNE_ONE_IF_CONV_INSN): Adjust comment.
19255         * doc/tm.texi.in (TARGET_NOCE_CONVERSION_PROFITABLE_P): Add.
19256         * doc/tm.texi: Regenerated.
19258 2017-04-04  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
19260         * doc/extend.texi (PowerPC AltiVec Built-in Functions): Grammar
19261         correction.
19263 2017-04-04  Thomas Preud'homme  <thomas.preudhomme@arm.com>
19265         PR target/80307
19266         * config/arm/arm.c (thumb1_rtx_costs): Give a cost of 32
19267         instructions for small multiply cores.
19269 2017-04-04  Jeff Law  <law@redhat.com>
19271         * config/mips/mips.c (mips_multi_add): Zero initialize the newly
19272         added member.
19273         (mips_expand_vec_perm_const): Initialize elements in orig_perm
19274         that are not set by the loop over the elements.
19276 2017-04-04  Jakub Jelinek  <jakub@redhat.com>
19278         PR target/80286
19279         * config/i386/i386.c (ix86_expand_args_builtin): If op has scalar
19280         int mode, convert_modes it to mode as unsigned, otherwise use
19281         lowpart_subreg to mode rather than SImode.
19282         * config/i386/sse.md (<mask_codefor>ashr<mode>3<mask_name>,
19283         ashr<mode>3, ashr<mode>3<mask_name>, <shift_insn><mode>3<mask_name>):
19284         Use DImode instead of SImode for the shift count operand.
19285         * config/i386/mmx.md (mmx_ashr<mode>3, mmx_<shift_insn><mode>3):
19286         Likewise.
19288 2017-04-04  Richard Biener  <rguenther@suse.de>
19290         PR middle-end/80281
19291         * match.pd (A + (-B) -> A - B): Make sure to preserve unsigned
19292         arithmetic done for the negate or the plus.  Simplify.
19293         (A - (-B) -> A + B): Likewise.
19294         * fold-const.c (split_tree): Make sure to not negate pointers.
19296 2017-04-04  Segher Boessenkool  <segher@kernel.crashing.org>
19298         PR rtl-optimization/60818
19299         * simplify-rtx.c (simplify_binary_operation_1): Do not replace
19300         a compare of comparisons with the thing compared if this results
19301         in a different machine mode.
19303 2017-04-03  Jonathan Wakely  <jwakely@redhat.com>
19305         * alias.c (base_alias_check): Fix typo in comment.
19306         * cgraph.h (class ipa_polymorphic_call_context): Likewise.
19307         * cgraphunit.c (symbol_table::compile): Likewise.
19308         * collect2.c (maybe_run_lto_and_relink): Likewise.
19309         * config/arm/arm.c (arm_thumb1_mi_thunk): Likewise.
19310         * config/avr/avr-arch.h (avr_arch_info_t): Likewise.
19311         * config/avr/avr.c (avr_map_op_t): Likewise.
19312         * config/cr16/cr16.h (DATA_ALIGNMENT): Likewise.
19313         * config/epiphany/epiphany.c (TARGET_ARG_PARTIAL_BYTES): Likewise.
19314         * config/epiphany/epiphany.md (movcc): Likewise.
19315         * config/i386/i386.c (legitimize_pe_coff_extern_decl): Likewise.
19316         * config/m68k/m68k.c (struct _sched_ib, m68k_sched_variable_issue):
19317         Likewise.
19318         * config/mips/mips.c (mips_save_restore_reg): Likewise.
19319         * config/rx/rx.c (rx_is_restricted_memory_address): Likewise.
19320         * config/s390/s390.c (Z10_EARLYLOAD_DISTANCE): Likewise.
19321         * config/sh/sh.c (sh_rtx_costs): Likewise.
19322         * fold-const.c (fold_truth_andor): Likewise.
19323         * genautomata.c (collapse_flag): Likewise.
19324         * gengtype.h (struct type::u::s): Likewise.
19325         * gensupport.c (has_subst_attribute, add_mnemonic_string): Likewise.
19326         * input.c (FORMAT_AMOUNT): Likewise.
19327         * ipa-cp.c (class ipcp_lattice, agg_replacements_to_vector)
19328         (known_aggs_to_agg_replacement_list): Likewise.
19329         * ipa-inline-analysis.c: Likewise.
19330         * ipa-inline.h (estimate_edge_time, estimate_edge_hints): Likewise.
19331         * ipa-polymorphic-call.c
19332         (ipa_polymorphic_call_context::restrict_to_inner_class): Likewise.
19333         * loop-unroll.c (analyze_insn_to_expand_var): Likewise.
19334         * lra.c (lra_optional_reload_pseudos, lra_subreg_reload_pseudos):
19335         Likewise.
19336         * modulo-sched.c (apply_reg_moves): Likewise.
19337         * omp-expand.c (build_omp_regions_1): Likewise.
19338         * trans-mem.c (struct tm_wrapper_hasher): Likewise.
19339         * tree-ssa-loop-ivopts.c (may_eliminate_iv): Likewise.
19340         * tree-ssa-loop-niter.c (maybe_lower_iteration_bound): Likewise.
19341         * tree-vect-data-refs.c (vect_enhance_data_refs_alignment): Likewise.
19342         * value-prof.c: Likewise.
19343         * var-tracking.c (val_reset): Likewise.
19345 2017-04-03  Richard Biener  <rguenther@suse.de>
19347         PR tree-optimization/80275
19348         * fold-const.c (split_address_to_core_and_offset): Handle
19349         POINTER_PLUS_EXPR.
19351 2017-04-03  Eric Botcazou  <ebotcazou@adacore.com>
19353         * tree-nested.c (get_descriptor_type): Make sure that the alignment of
19354         descriptors is at least equal to that of functions.
19356 2017-04-02  Uros Bizjak  <ubizjak@gmail.com>
19358         * config/i386/sse.md (movdi_to_sse): Add missing DONE.
19360 2017-04-02  Uros Bizjak  <ubizjak@gmail.com>
19362         PR target/80250
19363         * config/i386/sse.md (mov<IMOD4:mode>): Remove insn pattern.
19364         (mov<IMOD4:mode>): New expander.
19365         (*mov<IMOD4:mode>_internal): New insn and split pattern.
19367 2017-03-31  Segher Boessenkool  <segher@kernel.crashing.org>
19369         PR rtl-optimization/79405
19370         * fwprop.c (propagations_left): New variable.
19371         (forward_propagate_into): Decrement it.
19372         (fwprop_init): Initialize it.
19373         (fw_prop): If the variable has reached zero, stop propagating.
19374         (fwprop_addr): Ditto.
19376 2017-03-31  Jakub Jelinek  <jakub@redhat.com>
19378         PR debug/79255
19379         * dwarf2out.c (decls_for_scope): If BLOCK_NONLOCALIZED_VAR is
19380         a FUNCTION_DECL, pass it as decl instead of origin to
19381         process_scope_var.
19383 2017-03-31  Alexander Monakov  <amonakov@ispras.ru>
19385         * config/nvptx/nvptx.c (nvptx_output_softstack_switch): Correct format
19386         string.
19388 2017-03-31  Pat Haugen  <pthaugen@us.ibm.com>
19390         PR target/80107
19391         * config/rs6000/rs6000.md (extendhi<mode>2): Add test for
19392         TARGET_VSX_SMALL_INTEGER.
19394 2017-03-31  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
19396         * doc/extend.texi (PowerPC AltiVec Built-in Functions): Add
19397         reference to the OpenPOWER 64-Bit ELF V2 ABI Specification.
19399 2017-03-31  Matthew Fortune  <matthew.fortune@imgtec.com>
19401         * config/mips/mips-msa.md (msa_vec_extract_<msafmt_f>): Update
19402         extraction from odd-numbered MSA register.
19404 2017-03-31  Jakub Jelinek  <jakub@redhat.com>
19406         PR middle-end/80173
19407         * expmed.c (store_bit_field_1): Don't attempt to create
19408         a word subreg out of hard registers wider than word if they
19409         have HARD_REGNO_NREGS of 1 for their mode.
19411         PR middle-end/80163
19412         * varasm.c (initializer_constant_valid_p_1): Disallow sign-extending
19413         conversions to integer types wider than word and pointer.
19415         PR debug/80025
19416         * cselib.h (rtx_equal_for_cselib_1): Add depth argument.
19417         (rtx_equal_for_cselib_p): Pass 0 to it.
19418         * cselib.c (cselib_hasher::equal): Likewise.
19419         (rtx_equal_for_cselib_1): Add depth argument.  If depth
19420         is 128, don't look up VALUE locs and punt.  Increment
19421         depth in recursive calls when walking VALUE locs.
19423 2017-03-31  Bernd Edlinger  <bernd.edlinger@hotmail.de>
19425         * gcov.c (md5sum_to_hex): Fix output of MD5 hex bytes.
19426         (make_gcov_file_name): Use the canonical path name for generating
19427         the MD5 value.
19428         (read_line): Fix handling of files with ascii null bytes.
19430 2017-03-30  Matthew Fortune  <matthew.fortune@imgtec.com>
19432         * config/mips/mips.c (mips_expand_vector_init): Create a const_vector
19433         to initialise a vector register instead
19434         of using a const_int.
19436 2017-03-30  Jakub Jelinek  <jakub@redhat.com>
19438         PR translation/80189
19439         * gimplify.c (omp_default_clause): Use %qs instead of %s in
19440         diagnostic messages.
19442 2017-03-30  Peter Bergner  <bergner@vnet.ibm.com>
19444         PR target/80246
19445         * config/rs6000/dfp.md (dfp_dxex_<mode>): Update mode of operand 0.
19446         (dfp_diex_<mode>): Update mode of operand 1.
19447         * doc/extend.texi (dxex, dxexq): Document change to return type.
19448         (diex, diexq): Document change to argument type.
19450 2017-03-30  Martin Jambor  <mjambor@suse.cz>
19452         PR ipa/77333
19453         * cgraph.h (cgraph_build_function_type_skip_args): Declare.
19454         * cgraph.c (redirect_call_stmt_to_callee): Set gimple fntype so that
19455         it reflects the signature changes performed at the callee side.
19456         * cgraphclones.c (build_function_type_skip_args): Make public, renamed
19457         to cgraph_build_function_type_skip_args.
19458         (build_function_decl_skip_args): Adjust call to the above function.
19460 2017-03-30  Jakub Jelinek  <jakub@redhat.com>
19462         PR target/80206
19463         * config/i386/sse.md
19464         (<extract_type>_vextract<shuffletype><extract_suf>_mask): Use
19465         register as dest whenever it is a MEM not rtx_equal_p to the
19466         corresponding dup operand, and when forcing into reg move the
19467         reg into the memory afterwards.
19468         (<extract_type_2>_vextract<shuffletype><extract_suf_2>_mask):
19469         Likewise.  Use <ssehalfvecmode> instead of <ssequartermode>
19470         for the force_reg mode.
19471         (avx512vl_vextractf128<mode>): Use register as dest either
19472         always when a MEM, or when it is a MEM not rtx_equal_p to the
19473         corresponding dup operand, or even not when it is a CONST_VECTOR
19474         depending on the mode and lo vs. hi.
19475         (avx512dq_vextract<shuffletype>64x2_1_maskm): Remove extraneous
19476         parens.
19477         (avx512f_vextract<shuffletype>32x4_1_maskm): Likewise.
19478         (<mask_codefor>avx512dq_vextract<shuffletype>64x2_1<mask_name>):
19479         Likewise.  Require that operands[2] is even.
19480         (<mask_codefor>avx512f_vextract<shuffletype>32x4_1<mask_name>):
19481         Remove extraneous parens.  Require that operands[2] is a multiple
19482         of 4.
19483         (vec_extract_lo_<mode><mask_name>): Don't bother testing if
19484         operands[0] is a MEM if <mask_applied>, the predicates/constraints
19485         disallow memory then.
19487 2017-03-30  Richard Biener  <rguenther@suse.de>
19489         PR tree-optimization/77498
19490         * tree-ssa-pre.c (phi_translate_1): Do not allow simplifications
19491         to non-constants over backedges.
19493 2017-03-29  Segher Boessenkool  <segher@kernel.crashing.org>
19495         PR rtl-optimization/80233
19496         * combine.c (combine_instructions): Only take NONDEBUG_INSN_P insns
19497         as last_combined_insn.  Do not test for BARRIER_P separately.
19499 2017-03-29  Andreas Schwab  <schwab@suse.de>
19501         PR ada/80146
19502         * calls.c (prepare_call_address): Convert funexp to Pmode before
19503         copying to temp reg.
19505 2017-03-29  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
19507         PR tree-optimization/80158
19508         * gimple-ssa-strength-reduction.c (replace_mult_candidate):
19509         Handle possible future case of more than one alternate
19510         interpretation.
19511         (replace_rhs_if_not_dup): Likewise.
19512         (replace_one_candidate): Likewise.
19514 2017-03-28  Vladimir Makarov  <vmakarov@redhat.com>
19516         PR rtl-optimization/80193
19517         * ira.c (ira): Do not check allocation for LRA.
19519 2017-03-28  Alexander Monakov  <amonakov@ispras.ru>
19521         * config/nvptx/nvptx-protos.h (nvptx_output_simt_enter): Declare.
19522         (nvptx_output_simt_exit): Declare.
19523         * config/nvptx/nvptx.c (nvptx_init_unisimt_predicate): Use
19524         cfun->machine->unisimt_location.  Handle NULL unisimt_predicate.
19525         (init_softstack_frame): Move initialization of crtl->is_leaf to...
19526         (nvptx_declare_function_name): ...here.  Emit declaration of local
19527         memory space buffer for omp_simt_enter insn.
19528         (nvptx_output_unisimt_switch): New.
19529         (nvptx_output_softstack_switch): New.
19530         (nvptx_output_simt_enter): New.
19531         (nvptx_output_simt_exit): New.
19532         * config/nvptx/nvptx.h (struct machine_function): New fields
19533         has_simtreg, unisimt_location, simt_stack_size, simt_stack_align.
19534         * config/nvptx/nvptx.md (UNSPECV_SIMT_ENTER): New unspec.
19535         (UNSPECV_SIMT_EXIT): Ditto.
19536         (omp_simt_enter_insn): New insn.
19537         (omp_simt_enter): New expansion.
19538         (omp_simt_exit): New insn.
19539         * config/nvptx/nvptx.opt (msoft-stack-reserve-local): New option.
19541         * internal-fn.c (expand_GOMP_SIMT_ENTER): New.
19542         (expand_GOMP_SIMT_ENTER_ALLOC): New.
19543         (expand_GOMP_SIMT_EXIT): New.
19544         * internal-fn.def (GOMP_SIMT_ENTER): New internal function.
19545         (GOMP_SIMT_ENTER_ALLOC): Ditto.
19546         (GOMP_SIMT_EXIT): Ditto.
19547         * target-insns.def (omp_simt_enter): New insn.
19548         (omp_simt_exit): Ditto.
19549         * omp-low.c (struct omplow_simd_context): New fields simt_eargs,
19550         simt_dlist.
19551         (lower_rec_simd_input_clauses): Implement SIMT privatization.
19552         (lower_rec_input_clauses): Likewise.
19553         (lower_lastprivate_clauses): Handle SIMT privatization.
19555         * omp-offload.c: Include langhooks.h, tree-nested.h, stor-layout.h.
19556         (ompdevlow_adjust_simt_enter): New.
19557         (find_simtpriv_var_op): New.
19558         (execute_omp_device_lower): Handle IFN_GOMP_SIMT_ENTER,
19559         IFN_GOMP_SIMT_ENTER_ALLOC, IFN_GOMP_SIMT_EXIT.
19561         * tree-inline.h (struct copy_body_data): New field dst_simt_vars.
19562         * tree-inline.c (expand_call_inline): Handle SIMT privatization.
19563         (copy_decl_for_dup_finish): Ditto.
19565         * tree-ssa.c (execute_update_addresses_taken): Handle GOMP_SIMT_ENTER.
19567 2017-03-28  Uros Bizjak  <ubizjak@gmail.com>
19569         PR target/53383
19570         * config/i386/i386.c (ix86_option_override_internal): Always
19571         allow -mpreferred-stack-boundary=3 for 64-bit targets.
19573 2017-03-28  Bin Cheng  <bin.cheng@arm.com>
19575         * tree-vect-loop.c (optimize_mask_stores): Add bb to the right loop.
19577 2017-03-28  Bin Cheng  <bin.cheng@arm.com>
19579         * tree-vect-loop-manip.c (slpeel_add_loop_guard): New param and
19580         mark new edge's irreducible flag accordign to it.
19581         (vect_do_peeling): Check loop preheader edge's irreducible flag
19582         and pass it to function slpeel_add_loop_guard.
19584 2017-03-28  Richard Sandiford  <richard.sandiford@arm.com>
19586         PR tree-optimization/80218
19587         * tree-call-cdce.c (shrink_wrap_one_built_in_call_with_conds):
19588         Update block frequencies and counts.
19590 2017-03-28  Richard Biener  <rguenther@suse.de>
19592         PR tree-optimization/78644
19593         * tree-ssa-ccp.c (evaluate_stmt): When we may not use the value
19594         of a simplification result we may not use it at all.
19596 2017-03-28  Richard Biener  <rguenther@suse.de>
19598         PR ipa/80205
19599         * tree-inline.c (copy_phis_for_bb): Do not create PHI node
19600         without arguments, generate default definition of a SSA name.
19602 2017-03-28  Richard Biener  <rguenther@suse.de>
19604         PR middle-end/80222
19605         * gimple-fold.c (gimple_fold_indirect_ref): Do not touch
19606         TYPE_REF_CAN_ALIAS_ALL references.
19607         * fold-const.c (fold_indirect_ref_1): Likewise.
19609 2017-03-28  Martin Liska  <mliska@suse.cz>
19611         PR ipa/80104
19612         * cgraphunit.c (cgraph_node::expand_thunk): Mark argument of a
19613         thunk call as DECL_GIMPLE_REG_P when vector or complex type.
19615 2017-03-28  Claudiu Zissulescu  <claziss@synopsys.com>
19616             Thomas Petazzoni  <thomas.petazzoni@free-electrons.com>
19618         * config/arc/arc.h (CPP_SPEC): Add subtarget_cpp_spec.
19619         (EXTRA_SPECS): Define.
19620         (SUBTARGET_EXTRA_SPECS): Likewise.
19621         (SUBTARGET_CPP_SPEC): Likewise.
19622         * config/arc/elf.h (EXTRA_SPECS): Renamed to
19623         SUBTARGET_EXTRA_SPECS.
19624         * config/arc/linux.h (SUBTARGET_CPP_SPEC): Define.
19626 2017-03-28  Claudiu Zissulescu  <claziss@synopsys.com>
19628         * config/arc/simdext.md (vst64_insn): Update pattern.
19629         (vld32wh_insn): Likewise.
19630         (vld32wl_insn): Likewise.
19631         (vld64_insn): Likewise.
19632         (vld32_insn): Likewise.
19634 2017-03-28  Marek Polacek  <polacek@redhat.com>
19636         PR sanitizer/80067
19637         * fold-const.c (fold_comparison): Use protected_set_expr_location
19638         instead of SET_EXPR_LOCATION.
19640 2017-03-28  Markus Trippelsdorf  <markus@trippelsdorf.de>
19642         * tree.c (add_expr): Avoid name lookup warning.
19644 2017-03-27  Jeff Law  <law@redhat.com>
19646         PR tree-optimization/80216
19647         * tree-ssa-dom.c (derive_equivalences_from_bit_ior): Fix typo in
19648         function name.  Limit recursion depth.
19649         (record_temporary_equivalences): Corresponding changes.
19651 2017-03-27  Jonathan Wakely  <jwakely@redhat.com>
19653         * doc/invoke.texi (-Wno-narrowing): Reorder so default behavior is
19654         covered first.
19656 2017-03-27  Jakub Jelinek  <jakub@redhat.com>
19658         PR target/80102
19659         * reg-notes.def (REG_CFA_NOTE): Define.  Use it for CFA related
19660         notes.
19661         * cfgcleanup.c (reg_note_cfa_p): New array.
19662         (insns_have_identical_cfa_notes): New function.
19663         (old_insns_match_p): Don't cross-jump in between /f
19664         and non-/f instructions.  If both i1 and i2 are frame related,
19665         verify all CFA notes, their order and content.
19667 2017-03-27  Michael Meissner  <meissner@linux.vnet.ibm.com>
19669         PR target/78543
19670         * config/rs6000/rs6000.md (bswaphi2_extenddi): Combine bswap
19671         HImode and SImode with zero extend to DImode to one insn.
19672         (bswap<mode>2_extenddi): Likewise.
19673         (bswapsi2_extenddi): Likewise.
19674         (bswaphi2_extendsi): Likewise.
19675         (bswaphi2): Combine bswap HImode and SImode into one insn.
19676         Separate memory insns from swapping register.
19677         (bswapsi2): Likewise.
19678         (bswap<mode>2): Likewise.
19679         (bswaphi2_internal): Delete, no longer used.
19680         (bswapsi2_internal): Likewise.
19681         (bswap<mode>2_load): Split bswap HImode/SImode into separate load,
19682         store, and gpr<-gpr swap insns.
19683         (bswap<mode>2_store): Likewise.
19684         (bswaphi2_reg): Register only splitter, combine with the splitter.
19685         (bswaphi2 splitter): Likewise.
19686         (bswapsi2_reg): Likewise.
19687         (bswapsi2 splitter): Likewise.
19688         (bswapdi2): If we have the LDBRX and STDBRX instructions, split
19689         the insns into load, store, and register/register insns.
19690         (bswapdi2_ldbrx): Likewise.
19691         (bswapdi2_load): Likewise.
19692         (bswapdi2_store): Likewise.
19693         (bswapdi2_reg): Likewise.
19695 2017-03-27  Gunther Nikl  <gnikl@users.sourceforge.net>
19697         * system.h (HAVE_DESIGNATED_INITIALIZERS): Fix non C++ case.
19698         (HAVE_DESIGNATED_UNION_INITIALIZERS): Likewise.
19700 2017-03-27  Kelvin Nilsen  <kelvin@gcc.gnu.org>
19702         PR target/80103
19703         * config/rs6000/rs6000-c.c (rs6000_target_modify_macros): Edit and
19704         add comments.
19705         * config/rs6000/rs6000.c (rs6000_option_override_internal): Add
19706         special handling for target option conflicts between dform
19707         options (-mpower9-dform, -mpower9-dform-vector,
19708         -mpower9-dform-scalar) and -mno-direct-move.
19710 2017-03-27  Richard Biener  <rguenther@suse.de>
19712         PR tree-optimization/80181
19713         * tree-ssa-ccp.c (likely_value): UNDEFINED ^ X is UNDEFINED.
19715 2017-03-27  Claudiu Zissulescu  <claziss@synopsys.com>
19717         * config/arc/predicates.md (move_double_src_operand): Replace the
19718         call to move_double_src_operand with a call to address_operand.
19720 2017-03-27  Claudiu Zissulescu  <claziss@synopsys.com>
19722         * config/arc/elf.h (ARGET_ARC_TP_REGNO_DEFAULT): Define.
19723         * config/arc/linux.h (ARGET_ARC_TP_REGNO_DEFAULT): Likewise.
19724         * config/arc/arc.opt (mtp-regno): Use ARGET_ARC_TP_REGNO_DEFAULT.
19726 2017-03-27  Claudiu Zissulescu  <claziss@synopsys.com>
19728         * config/arc/predicates.md (long_immediate_loadstore_operand):
19729         Consider scaled addresses cases.
19731 2017-03-27  Claudiu Zissulescu  <claziss@synopsys.com>
19733         * config/arc/arc.c (arc_epilogue_uses): BLINK should be also
19734         restored when in interrupt.
19735         * config/arc/arc.md (simple_return): ARCv2 rtie instruction
19736         doesn't have delay slot.
19738 2017-03-27  Richard Biener  <rguenther@suse.de>
19740         PR ipa/79776
19741         * tree-ssa-structalias.c (associate_varinfo_to_alias): Skip
19742         inlined thunk clones.
19744 2017-03-27  Jakub Jelinek  <jakub@redhat.com>
19746         PR sanitizer/80168
19747         * asan.c (instrument_derefs): Copy over last operand from
19748         original COMPONENT_REF to the new COMPONENT_REF with
19749         DECL_BIT_FIELD_REPRESENTATIVE.
19750         * ubsan.c (instrument_object_size): Likewise.
19752 2017-03-27  Richard Biener  <rguenther@suse.de>
19754         PR tree-optimization/80170
19755         * tree-vect-data-refs.c (vect_compute_data_ref_alignment): Make
19756         sure DR/SCEV didnt fold in constants we do not see when looking
19757         at the reference base alignment.
19759 2017-03-27  Richard Biener  <rguenther@suse.de>
19761         PR middle-end/80171
19762         * gimple-fold.c (fold_ctor_reference): Properly guard against
19763         NULL return value from canonicalize_constructor_val.
19765 2017-03-25  Uros Bizjak  <ubizjak@gmail.com>
19767         PR target/80180
19768         * config/i386/i386.c (ix86_expand_builtin)
19769         <IX86_BUILTIN_RDSEED{16,32,64}_STEP>: Do not expand arg0 between
19770         flags reg setting and flags reg using instructions.
19771         <IX86_BUILTIN_RDRAND{16,32,64}_STEP>: Ditto.  Use non-flags reg
19772         clobbering instructions to zero extend op2.
19774 2017-03-25  Gerald Pfeifer  <gerald@pfeifer.com>
19776         * doc/install.texi (Configuration) <--with-aix-soname>:
19777         Update link to AIX ld.
19779 2017-03-25  Bernd Schmidt  <bschmidt@redhat.com>
19781         PR rtl-optimization/80160
19782         PR rtl-optimization/80159
19783         * lra-assigns.c (must_not_spill_p): Tighten new test to also take
19784         reg_alternate_class into account.
19786 2017-03-24  Vladimir Makarov  <vmakarov@redhat.com>
19788         PR target/80148
19789         * lra-assigns.c (assign_by_spills): Add spilled non-reload pseudos
19790         to consider in curr_insn_transform.
19792 2017-03-24  Jakub Jelinek  <jakub@redhat.com>
19794         * genrecog.c (validate_pattern): Add VEC_SELECT validation.
19795         * genmodes.c (emit_min_insn_modes_c): Call emit_mode_nunits
19796         and emit_mode_inner.
19798 2017-03-24  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
19800         * config/s390/s390-builtins.def: Add VXE builtins.  Add a flags
19801         argument to the overloaded builtin variants.  Use the new flag to
19802         deprecate certain builtin variants.
19803         * config/s390/s390-builtin-types.def: Add new builtin types.
19804         * config/s390/s390-builtins.h: Support new flags field for
19805         overloaded builtins.
19806         * config/s390/s390-c.c (OB_DEF_VAR): New flags field.
19807         (s390_macro_to_expand): Enable vector float data type.
19808         (s390_cpu_cpp_builtins_internal): Indicate support of the new
19809         builtins by incrementing the __VEC__ version number.
19810         (s390_expand_overloaded_builtin): Support expansion of vec_xl and
19811         vec_xst.
19812         (s390_resolve_overloaded_builtin): Emit error messages depending
19813         on the builtin flags.
19814         * config/s390/s390.c (s390_expand_builtin): Support additional
19815         flags argument.  Change error message to match the messages
19816         emitted in s390-c.c.
19817         * config/s390/s390.md: New UNSPEC_* constants.
19818         (op_type): Add new instruction types.
19819         * config/s390/vecintrin.h: Add new builtins and test data class
19820         constants.
19821         * config/s390/vx-builtins.md (V_HW_32_64): Add V4SF.
19822         (V_HW_4, VEC_HW, VECF_HW): New mode iterators.
19823         (VEC_INEXACT, VEC_NOINEXACT): New constants.
19824         ("vec_splats<mode>", "vec_insert<mode>", "vec_promote<mode>")
19825         ("vec_insert_and_zero<mode>", "vec_mergeh<mode>")
19826         ("vec_mergel<mode>"): V_HW -> VEC_HW.
19828         ("vlrlrv16qi", "vstrlrv16qi", "vbpermv16qi", "vec_msumv2di")
19829         ("vmslg", "*vftci<mode>_cconly", "vftci<mode>_intcconly")
19830         ("*vftci<mode>", "vftci<mode>_intcc", "vec_double_s64")
19831         ("vec_double_u64", "vfmin<mode>", "vfmax<mode>"): New definition.
19833         ("and_av2df3", "and_cv2df3", "vec_andc_av2df3")
19834         ("vec_andc_cv2df3", "xor_av2df3", "xor_cv2df3", "vec_nor_av2df3")
19835         ("vec_nor_cv2df3", "ior_av2df3", "ior_cv2df3", "vec_nabs")
19836         ("*vftcidb", "*vftcidb_cconly", "vftcidb"): Remove definition.
19838         ("vec_all_<fpcmpcc:code>v2df", "vec_any_<fpcmpcc:code>v2df")
19839         ("vec_scatter_elementv4si_DI", "vec_cmp<fpcmp:code>v2df")
19840         ("vec_di_to_df_s64", "vec_di_to_df_u64", "vec_df_to_di_u64")
19841         ("vfidb", "*vldeb", "*vledb", "*vec_cmp<insn_cmp>v2df_cconly")
19842         ("vec_cmpeqv2df_cc", "vec_cmpeqv2df_cc", "vec_cmphv2df_cc")
19843         ("vec_cmphev2df_cc", "*vec_cmpeqv2df_cc")
19844         ("*vec_cmphv2df_cc", "*vec_cmphev2df_cc"): Enable new modes as ...
19846         ("vec_all_<fpcmpcc:code><mode>", "vec_any_<fpcmpcc:code><mode>")
19847         ("vec_scatter_element<V_HW_4:mode>_DI")
19848         ("vec_cmp<fpcmp:code><mode>", "vcdgb", "vcdlgb", "vclgdb")
19849         ("vec_fpint<mode>", "vflls")
19850         ("vflrd", "*vec_cmp<insn_cmp><mode>_cconly", "vec_cmpeq<mode>_cc")
19851         ("vec_cmpeq<mode>_cc", "vec_cmph<mode>_cc", "vec_cmphe<mode>_cc")
19852         ("*vec_cmpeq<mode>_cc", "*vec_cmph<mode>_cc")
19853         ("*vec_cmphe<mode>_cc"): ... these.
19855         ("vec_ctd_s64", "vec_ctsl", "vec_ctul", "vec_st2f"): Use rounding
19856         mode constant instead of magic value.
19858 2017-03-24  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
19860         * config/s390/s390.c (s390_expand_vec_compare): Support other
19861         vector floating point modes than just V2DF.
19862         (s390_expand_vcond): Likewise.
19863         (s390_hard_regno_mode_ok): Allow SFmode values in VRs.
19864         (s390_cannot_change_mode_class): Prevent mode changes between TF
19865         and V1TF in vector registers.
19866         * config/s390/s390.md (DF, SF): New mode attributes.
19867         ("*cmp<mode>_ccs", "add<mode>3", "sub<mode>3", "mul<mode>3")
19868         ("fma<mode>4", "fms<mode>4", "div<mode>3", "*neg<mode>2"): Add
19869         SFmode support for VRs.
19870         * config/s390/vector.md (V_HW, V_HW2, VT_HW, ti*, nonvec): Add new
19871         vector fp modes.
19872         (VFT, VF_HW): New mode iterators.
19873         (vw, sdx): New mode attributes.
19874         ("addv2df3", "subv2df3", "mulv2df3", "divv2df3", "sqrtv2df2")
19875         ("fmav2df4","fmsv2df4", "negv2df2", "absv2df2", "*negabsv2df2")
19876         ("smaxv2df3", "sminv2df3", "*vec_cmp<VFCMP_HW_OP:code>v2df_nocc")
19877         ("vec_cmpuneqv2df", "vec_cmpltgtv2df", "vec_orderedv2df")
19878         ("vec_unorderedv2df"): Adjust the v2df only patterns to support
19879         also the new vector floating point modes.  Renaming to ...
19881         ("add<mode>3", "sub<mode>3", "mul<mode>3", "div<mode>3")
19882         ("sqrt<mode>2", "fma<mode>4", "fms<mode>4", "neg<mode>2")
19883         ("abs<mode>2", "negabs<mode>2", "smax<mode>3")
19884         ("smin<mode>3", "*vec_cmp<VFCMP_HW_OP:code><mode>_nocc")
19885         ("vec_cmpuneq<mode>", "vec_cmpltgt<mode>", "vec_ordered<mode>")
19886         ("vec_unordered<mode>"): ... these.
19888         ("neg_fma<mode>4", "neg_fms<mode>4", "*smax<mode>3_vxe")
19889         ("*smin<mode>3_vxe", "*sminv2df3_vx", "*vec_extendv4sf")
19890         ("*vec_extendv2df"): New insn definitions.
19892 2017-03-24  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
19894         * config/s390/s390.md ("*adddi3_sign", "*subdi3_sign", "mulditi3")
19895         ("mulditi3_2", "*muldi3_sign"): New patterns.
19896         ("muldi3", "*muldi3", "mulsi3", "*mulsi3"): Add an expander and
19897         rename the pattern definition.
19899 2017-03-24  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
19901         * config/s390/s390.md ("indirect_jump"): Turn insn definition into
19902         expander.
19903         ("*indirect_jump", "*indirect2_jump"): New pattern definitions.
19905 2017-03-24  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
19907         * config/s390/s390.c (s390_expand_vec_init): Use vllezl
19908         instruction if possible.
19909         * config/s390/vector.md (vec_halfnumelts): New mode
19910         attribute.
19911         ("*vec_vllezlf<mode>"): New pattern.
19913 2017-03-24  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
19915         * config/s390/vector.md ("popcountv16qi2", "popcountv8hi2")
19916         ("popcountv4si2", "popcountv2di2"): Rename to ...
19917         ("popcount<mode>2", "popcountv8hi2_vx", "popcountv4si2_vx")
19918         ("popcountv2di2_vx"): ... these and add !TARGET_VXE to the
19919         condition.
19920         ("popcount<mode>2_vxe"): New pattern.
19922 2017-03-24  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
19924         * common/config/s390/s390-common.c (processor_flags_table): Add
19925         arch12.
19926         * config.gcc: Add arch12.
19927         * config/s390/driver-native.c (s390_host_detect_local_cpu):
19928         Default to arch12 for unknown CPU model numbers.
19929         * config/s390/s390-builtins.def: Add B_VXE builtin flag.
19930         * config/s390/s390-c.c (s390_cpu_cpp_builtins_internal): Adjust
19931         PROCESSOR_max sanity check.
19932         * config/s390/s390-opts.h (enum processor_type): Add
19933         PROCESSOR_ARCH12.
19934         * config/s390/s390.c (processor_table): Add arch12.
19935         (s390_expand_builtin): Add check for B_VXE flag.
19936         (s390_issue_rate): Add PROCESSOR_ARCH12.
19937         (s390_get_sched_attrmask): Likewise.
19938         (s390_get_unit_mask): Likewise.
19939         (s390_sched_score): Enable z13 scheduling for arch12.
19940         (s390_sched_reorder): Likewise.
19941         (s390_sched_variable_issue): Likewise.
19942         * config/s390/s390.h (enum processor_flags): Add PF_ARCH12 and
19943         PF_VXE.
19944         (s390_tune_attr): Use z13 scheduling also for arch12.
19945         (TARGET_CPU_ARCH12, TARGET_CPU_ARCH12_P, TARGET_CPU_VXE)
19946         (TARGET_CPU_VXE_P, TARGET_ARCH12, TARGET_ARCH12_P, TARGET_VXE)
19947         (TARGET_VXE_P): New macros.
19948         * config/s390/s390.md: Add arch12 to cpu attribute.  Add arch12
19949         and vxe to cpu_facility.  Add arch12 and vxe to enabled attribute.
19950         * config/s390/s390.opt: Add arch12 as processor_type.
19952 2017-03-24  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
19954         * config/s390/s390.md
19955         ("fixuns_truncdddi2", "fixuns_trunctddi2")
19956         ("fixuns_trunc<BFP:mode><GPR:mode>2"): Merge into ...
19957         ("fixuns_trunc<FP:mode><GPR:mode>2"): New expander.
19959         ("fixuns_trunc<BFP:mode><GPR:mode>2", "fixuns_trunc<mode>si2"):
19960         Rename expanders to ...
19962         ("fixuns_trunc<BFP:mode><GPR:mode>2_emu")
19963         ("fixuns_truncdddi2_emu"): ... these.
19965         ("fixuns_trunc<mode>si2_emu"): New expander.
19967         ("*fixuns_truncdfdi2_z13"): Rename to ...
19968         ("*fixuns_truncdfdi2_vx"): ... this.
19970 2017-03-24  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
19972         * config/s390/2964.md: Remove the single element vector compare
19973         instructions which are no longer used.
19974         * config/s390/s390.c (s390_select_ccmode): Remove handling of
19975         vector CCmodes.
19976         (s390_canonicalize_comparison): Remove handling of DFmode
19977         compares.
19978         (s390_expand_vec_compare_scalar): Remove function.
19979         (s390_emit_compare): Don't call s390_expand_vec_compare_scalar.
19980         * config/s390/s390.md ("*vec_cmp<insn_cmp>df_cconly"): Remove
19981         pattern.
19982         ("*cmp<mode>_ccs"): Add wfcdb instruction.
19984 2017-03-24  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
19986         * config/s390/s390.md ("mov<mode>_64dfp" DD_DF): Use vleig for loading a
19987         FP zero.
19988         ("*mov<mode>_64" DD_DF): Remove the vector instructions. These
19989         will anyway by matched by mov<mode>_64dfp.
19991 2017-03-24  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
19993         * config/s390/s390.md ("mov<mode>" SD_SF): Change vleg/vsteg to
19994         vlef/vstef.  Add missing operand to vleif.
19996 2017-03-24  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
19998         * config/s390/s390.c (s390_expand_vec_init): Enable vector load
19999         pair for all vector types with 64 bit elements.
20000         * config/s390/vx-builtins.md (V_HW_64): Move mode iterator to ...
20001         * config/s390/vector.md (V_HW_64): ... here.
20002         (V_128_NOSINGLE): New mode iterator.
20003         ("vec_init<V_HW:mode>"): Use V_128 as mode iterator.
20004         ("*vec_splat<mode>"): Use V_128_NOSINGLE mode iterator.
20005         ("*vec_tf_to_v1tf", "*vec_ti_to_v1ti"): New pattern definitions.
20006         ("*vec_load_pairv2di"): Change to ...
20007         ("*vec_load_pair<mode>"): ... this one.
20009 2017-03-24  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
20011         * config/s390/constraints.md: Add comments.
20012         (jKK): Reject element sizes > 8 bytes.
20013         * config/s390/s390.c (s390_split_ok_p): Enable splitting also for
20014         s_operands.
20015         * config/s390/s390.md: Add the s_operand checks formerly in
20016         s390_split_ok_p to various splitters where they are still
20017         required.
20018         * config/s390/vector.md ("mov<mode>" V_128): Add GPR alternatives
20019         for 128 bit vectors.  Plus two splitters.
20021 2017-03-24  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
20023         * config/s390/s390.md: Rename the cpu facilty vec to vx throughout
20024         the file.
20026 2017-03-24  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
20028         PR target/79893
20029         * config/s390/s390-c.c (s390_adjust_builtin_arglist): Issue an
20030         error if the boundary argument is not constant.
20032 2017-03-24  Jakub Jelinek  <jakub@redhat.com>
20034         PR rtl-optimization/80112
20035         * loop-doloop.c (doloop_condition_get): Don't check condition
20036         if cmp isn't SET with IF_THEN_ELSE src.
20038 2017-03-24  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
20040         PR tree-optimization/80158
20041         * gimple-ssa-strength-reduction.c (replace_mult_candidate): When
20042         replacing a candidate statement, also replace it for the
20043         candidate's alternate interpretation.
20044         (replace_rhs_if_not_dup): Likewise.
20045         (replace_one_candidate): Likewise.
20047 2017-03-24  Richard Biener  <rguenther@suse.de>
20049         PR tree-optimization/80167
20050         * graphite-isl-ast-to-gimple.c
20051         (translate_isl_ast_to_gimple::is_valid_rename): Handle default-defs
20052         properly.
20053         (translate_isl_ast_to_gimple::get_rename): Likewise.
20055 2017-03-23  Kelvin Nilsen  <kelvin@gcc.gnu.org>
20057         * config/rs6000/rs6000.c (rs6000_option_override_internal): Change
20058         handling of certain combinations of target options, including the
20059         combinations -mpower8-vector vs. -mno-vsx, -mpower9-vector vs.
20060         -mno-power8-vector, and -mpower9_dform vs. -mno-power9-vector.
20062 2017-03-23  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
20064         PR target/71436
20065         * config/arm/arm.md (*load_multiple): Add reload_completed to
20066         matching condition.
20068 2017-03-23  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
20069             Richard Biener  <rguenth@suse.de>
20071         PR tree-optimization/79908
20072         PR tree-optimization/80136
20073         * tree-stdarg.c (expand_ifn_va_arg_1): For a VA_ARG whose LHS has
20074         been cast away, gimplify_and_add suffices.
20076 2017-03-23  Markus Trippelsdorf  <markus@trippelsdorf.de>
20078         * tree-vrp.c (identify_jump_threads): Delete avail_exprs.
20080 2017-03-23  Richard Biener  <rguenther@suse.de>
20082         PR tree-optimization/80032
20083         * gimplify.c (gimple_push_cleanup): Forced unconditional
20084         cleanups still have to go to the conditional_cleanups
20085         sequence.
20087 2017-03-22  Jakub Jelinek  <jakub@redhat.com>
20089         PR tree-optimization/80072
20090         * tree-ssa-reassoc.c (struct operand_entry): Change id field type
20091         to unsigned int.
20092         (next_operand_entry_id): Change type to unsigned int.
20093         (sort_by_operand_rank): Make sure to return the right return value
20094         even if unsigned fields are bigger than INT_MAX.
20095         (struct oecount): Change cnt and id type to unsigned int.
20096         (oecount_hasher::equal): Formatting fix.
20097         (oecount_cmp): Make sure to return the right return value
20098         even if unsigned fields are bigger than INT_MAX.
20099         (undistribute_ops_list): Change next_oecount_id type to unsigned int.
20101         PR c++/80129
20102         * gimplify.c (gimplify_modify_expr_rhs) <case COND_EXPR>: Clear
20103         TREE_READONLY on result if writing it more than once.
20105         PR sanitizer/80110
20106         * doc/invoke.texi (-fsanitize=thread): Document that with
20107         -fnon-call-exceptions atomics are not able to throw
20108         exceptions.
20110         PR sanitizer/80110
20111         * tsan.c: Include tree-eh.h.
20112         (instrument_builtin_call): Call maybe_clean_eh_stmt or
20113         maybe_clean_or_replace_eh_stmt where needed.
20114         (instrument_memory_accesses): Add cfg_changed argument.
20115         Call gimple_purge_dead_eh_edges on each block and set *cfg_changed
20116         if it returned true.
20117         (tsan_pass): Adjust caller.  Return TODO_cleanup_cfg if cfg_changed.
20119         PR rtl-optimization/63191
20120         * config/i386/i386.c (ix86_delegitimize_address): Turn into small
20121         wrapper function, moved the whole old content into ...
20122         (ix86_delegitimize_address_1): ... this.  New inline function.
20123         (ix86_find_base_term): Use ix86_delegitimize_address_1 with
20124         true as last argument instead of ix86_delegitimize_address.
20126 2017-03-22  Wilco Dijkstra  <wdijkstr@arm.com>
20128         * config/aarch64/aarch64.c (generic_branch_cost): Copy
20129         cortexa57_branch_cost.
20131 2017-03-22  Wilco Dijkstra  <wdijkstr@arm.com>
20133         * config/aarch64/aarch64.c (generic_tunings): Add AES fusion.
20135 2017-03-21  Aaron Sawdey  <acsawdey@linux.vnet.ibm.com>
20137         PR target/80123
20138         * doc/md.texi (Constraints): Document wA constraint.
20139         * config/rs6000/constraints.md (wA): New.
20140         * config/rs6000/rs6000.c (rs6000_debug_reg_global): Add wA reg_class.
20141         (rs6000_init_hard_regno_mode_ok): Init wA constraint.
20142         * config/rs6000/rs6000.h (RS6000_CONSTRAINT_wA): New.
20143         * config/rs6000/vsx.md (vsx_splat_<mode>): Use wA constraint.
20145 2017-03-22  Cesar Philippidis  <cesar@codesourcery.com>
20147         PR c++/80029
20148         * gimplify.c (is_oacc_declared): New function.
20149         (oacc_default_clause): Use it to set default flags for acc declared
20150         variables inside parallel regions.
20151         (gimplify_scan_omp_clauses): Strip firstprivate pointers for acc
20152         declared variables.
20153         (gimplify_oacc_declare): Gimplify the declare clauses.  Add the
20154         declare attribute to any decl as necessary.
20156 2017-03-22  Thomas Preud'homme  <thomas.preudhomme@arm.com>
20158         PR target/80082
20159         * config/arm/arm-isa.h (isa_bit_lpae): New feature bit.
20160         (ISA_ARMv7ve): Add isa_bit_lpae to the definition.
20161         * config/arm/arm-protos.h (arm_arch7ve): Rename into ...
20162         (arm_arch_lpae): This.
20163         * config/arm/arm.c (arm_arch7ve): Rename into ...
20164         (arm_arch_lpae): This.  Define it in term of isa_bit_lpae.
20165         * config/arm/arm.h (TARGET_HAVE_LPAE): Redefine in term of
20166         arm_arch_lpae.
20168 2017-03-22  Martin Liska  <mliska@suse.cz>
20170         PR target/79906
20171         * config/rs6000/rs6000.c (rs6000_inner_target_options): Show
20172         error message instead of an ICE.
20174 2017-03-21  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
20176         * doc/extend.texi (6.11 Additional Floating Types): Revise.
20178 2017-03-21  Kelvin Nilsen  <kelvin@gcc.gnu.org>
20180         * config/rs6000/rs6000-c.c (rs6000_target_modify_macros): Add
20181         comments.
20182         * config/rs6000/rs6000.c (rs6000_option_override_internal): Add
20183         comments.
20185 2017-03-21  Martin Sebor  <msebor@redhat.com>
20187         * doc/extend.texi: Use "cannot" instead of "can't."
20188         * doc/hostconfig.texi: Same.
20189         * doc/install.texi: Same.
20190         * doc/invoke.texi: Same.
20191         * doc/loop.texi: Same.
20192         * doc/md.texi: Same.
20193         * doc/objc.texi: Same.
20194         * doc/rtl.texi: Same.
20195         * doc/tm.texi: Same.
20196         * doc/tm.texi.in: Same.
20197         * doc/trouble.texi: Same.
20199 2017-03-21  Alexandre Oliva <aoliva@redhat.com>
20201         PR debug/63238
20202         * dwarf2out.c (struct checksum_attributes): Add at_alignment.
20203         (collect_checksum_attributes): Set it.
20204         (die_checksum_ordered): Use it.
20206 2017-03-21  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
20208         PR tree-optimization/79908
20209         * tree-stdarg.c (expand_ifn_va_arg_1): Revert the following
20210         change: For a VA_ARG whose LHS has been cast away, use
20211         force_gimple_operand to construct the side effects.
20213 2017-03-21  David Malcolm  <dmalcolm@redhat.com>
20215         PR translation/80001
20216         * omp-offload.c (oacc_loop_fixed_partitions): Make diagnostics
20217         more amenable to translation.
20218         (oacc_loop_auto_partitions): Likewise.
20220 2017-03-21  Marek Polacek  <polacek@redhat.com>
20221             Martin Sebor  <msebor@redhat.com>
20223         PR tree-optimization/80109
20224         * gimple-ssa-warn-alloca.c (alloca_call_type): Only call get_range_info
20225         on INTEGRAL_TYPE_P.
20227 2017-03-21  Jakub Jelinek  <jakub@redhat.com>
20228             Segher Boessenkool  <segher@kernel.crashing.org>
20230         PR target/80125
20231         * combine.c (can_combine_p): Revert the 2017-03-20 change, only
20232         check reg_used_between_p between insn and one of succ or succ2
20233         depending on if succ is artificial insn not inserted into insn
20234         stream.
20236 2017-03-21  Martin Liska  <mliska@suse.cz>
20238         PR gcov-profile/80081
20239         * Makefile.in: Add gcov-dump and fix installation of gcov-tool.
20240         * doc/gcc.texi: Include gcov-dump stuff.
20241         * doc/gcov-dump.texi: New file.
20243 2017-03-21  Toma Tabacu  <toma.tabacu@imgtec.com>
20245         PR rtl-optimization/79150
20246         * config/mips/mips.c (mips_block_move_loop): Emit a NOP after the
20247         conditional jump, if the jump is the last insn of the loop.
20249 2017-03-21  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
20250             Richard Biener  <rguenth@suse.de>
20252         PR tree-optimization/79908
20253         * tree-stdarg.c (expand_ifn_va_arg_1): For a VA_ARG whose LHS has
20254         been cast away, use force_gimple_operand to construct the side
20255         effects.
20257 2017-03-21  Martin Liska  <mliska@suse.cz>
20259         PR libfortran/79956
20260         * simplify-rtx.c (simplify_immed_subreg): Initialize a variable
20261         to NULL.
20263 2017-03-21  Brad Spengler <spender@grsecurity.net>
20265         PR plugins/80094
20266         * plugin.c (htab_hash_plugin): New function.
20267         (add_new_plugin): Use it and adjust.
20268         (parse_plugin_arg_opt): Adjust.
20269         (init_one_plugin): Likewise.
20271 2017-03-21  Richard Biener  <rguenther@suse.de>
20273         PR tree-optimization/80032
20274         * gimplify.c (gimple_push_cleanup): Add force_uncond parameter,
20275         if set force the cleanup to happen unconditionally.
20276         (gimplify_target_expr): Push inserted clobbers with force_uncond
20277         to avoid them being removed by control-dependent DCE.
20279 2017-03-21  Richard Biener  <rguenther@suse.de>
20281         PR tree-optimization/80122
20282         * tree-inline.c (copy_bb): Do not expans va-arg packs or
20283         va_arg_pack_len when the inlined call stmt requires pack
20284         expansion itself.
20285         * tree-inline.h (struct copy_body_data): Make call_stmt a gcall *.
20287 2017-03-21  Jakub Jelinek  <jakub@redhat.com>
20289         PR sanitizer/78158
20290         * tsan.c (instrument_builtin_call): If the memory model argument
20291         is not a constant, assume it is valid.
20293         PR c/67338
20294         * fold-const.c (round_up_loc): Negate divisor in unsigned type to
20295         avoid UB.
20297 2017-03-20  Segher Boessenkool  <segher@kernel.crashing.org>
20299         PR rtl-optimization/79910
20300         * combine.c (can_combine_p): Do not allow combining an I0 or I1
20301         if its dest is used by an insn before I2 (other than the combined
20302         insns themselves, which are properly handled already).
20304 2017-03-20  Segher Boessenkool  <segher@kernel.crashing.org>
20306         Revert:
20307         2017-03-17  Bernd Schmidt  <bschmidt@redhat.com>
20309         * combine.c (record_used_regs): New static function.
20310         (try_combine): Handle situations where there is an additional
20311         instruction between I2 and I3 which needs to have a LOG_LINK
20312         updated.
20314         Revert:
20315         2017-03-17  Jim Wilson  <jim.wilson@linaro.org>
20317         * combine.c (try_combine): Delete redundant i1 test.  Call
20318         prev_nonnote_nondebug_insn instead of prev_nonnote_insn.
20320 2017-03-20  Aaron Sawdey  <acsawdey@linux.vnet.ibm.com>
20322         PR target/80083
20323         * config/rs6000/rs6000.md (*movsi_internal1): Fix constraints for
20324         alternatives 13/14.
20326 2017-03-20  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
20328         PR tree-optimization/80054
20329         * gimple-ssa-strength-reduction.c (all_phi_incrs_profitable): Fail
20330         the optimization if a PHI or any of its arguments is not dominated
20331         by the candidate's basis.  Use gphi* rather than gimple* as
20332         appropriate.
20333         (replace_profitable_candidates): Clean up a gimple* variable that
20334         should be a gphi* variable.
20336 2017-03-20  Martin Sebor  <msebor@redhat.com>
20338         PR c++/52477
20339         * doc/extend.texi (attribute constructor): Document present limitation.
20341 2017-03-20  Kelvin Nilsen  <kelvin@gcc.gnu.org>
20343         PR target/79963
20344         * config/rs6000/altivec.h (vec_all_ne): Under __cplusplus__ and
20345         __POWER9_VECTOR__ #ifdef control, change template definition to
20346         use Power9-specific built-in function.
20347         (vec_any_eq): Likewise.
20348         * config/rs6000/vector.md (vector_ae_v2di_p): Change the flag used
20349         to control outcomes from this test.
20350         (vector_ae_<mode>p): For VEC_F modes, likewise.
20352 2017-03-20  Ian Lance Taylor  <iant@google.com>
20354         * config/i386/i386.c (ix86_function_regparm): Save an extra
20355         register for -fsplit-stack with DECL_STATIC_CHAIN.
20357 2017-03-17  Palmer Dabbelt  <palmer@dabbelt.com>
20359         PR target/79912
20360         * config/riscv/riscv.c (riscv_preferred_reload_class): Remove.
20361         (TARGET_PREFERRED_RELOAD_CLASS): Likewise.
20363 2017-03-17  Palmer Dabbelt  <palmer@dabbelt.com>
20365         * config/riscv/riscv.c (riscv_print_operand): Use "fence
20366         iorw,ow".
20367         * config/riscv/sync.mc (mem_thread_fence_1): Use "fence
20368         iorw,iorw".
20370 2017-03-20  Marek Polacek  <polacek@redhat.com>
20372         PR sanitizer/80063
20373         * asan.c (DEF_SANITIZER_BUILTIN): Use do { } while (0).
20375 2017-03-20  Richard Biener  <rguenther@suse.de>
20377         PR tree-optimization/80113
20378         * graphite-isl-ast-to-gimple.c (copy_loop_phi_nodes): Do not
20379         allocate extra SSA name for PHI def.
20380         (add_close_phis_to_outer_loops): Likewise.
20381         (add_close_phis_to_merge_points): Likewise.
20382         (copy_loop_close_phi_args): Likewise.
20383         (copy_cond_phi_nodes): Likewise.
20385 2017-03-20  Martin Liska  <mliska@suse.cz>
20387         PR middle-end/79753
20388         * tree-chkp.c (chkp_build_returned_bound): Do not build
20389         returned bounds for a LHS that's not a BOUNDED_P type.
20391 2017-03-20  Martin Liska  <mliska@suse.cz>
20393         PR target/79769
20394         PR target/79770
20395         * tree-chkp.c (chkp_find_bounds_1): Handle REAL_CST,
20396         COMPLEX_CST and VECTOR_CST.
20398 2017-03-20  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
20400         PR target/78857
20401         * config/s390/s390.md ("cmp<mode>_ccs_0"): Add a clobber of the
20402         target operand.  A new splitter adds the clobber statement in case
20403         the target operand is dead anyway.
20405 2017-03-19  Gerald Pfeifer  <gerald@pfeifer.com>
20407         * doc/install.texi (Specific) <sparc-*-linux*>: No longer refer
20408         to age-old versions of binutils and glibc.
20410 2017-03-18  Segher Boessenkool  <segher@kernel.crashing.org>
20412         * doc/contrib.texi (Contributors): Remove duplicate entry for myself.
20414 2017-03-18  Gerald Pfeifer  <gerald@pfeifer.com>
20416         * doc/contrib.texi (Contributors): Add Segher Boessenkool.
20418 2017-03-18  Gerald Pfeifer  <gerald@pfeifer.com>
20420         * doc/install.texi (Specific) <arm-*-eabi>: Remove old
20421         requirement for binutils 2.13.
20423 2017-03-17  Jim Wilson  <jim.wilson@linaro.org>
20425         * combine.c (try_combine): Delete redundant i1 test.  Call
20426         prev_nonnote_nondebug_insn instead of prev_nonnote_insn.
20428 2017-03-17  Palmer Dabbelt  <palmer@dabbelt.com
20430         * doc/install.texi (Specific) <riscv32-*-elf>: Add riscv32-*-elf,
20431         riscv32-*-linux, riscv64-*-elf, riscv64-*-linux to the table of
20432         contents.
20433         <riscv64-*-elf>: Re-arrange section
20434         <riscv32-*-elf>: Add a note about requiring binutils 2.28.
20435         <riscv32-*-linux>: Likewise.
20436         <riscv64-*-elf>: Likewise
20437         <riscv64-*-linux>: Likewise.
20439 2017-03-17  Richard Earnshaw  <rearnsha@arm.com>
20441         PR target/80052
20442         * aarch64.opt(verbose-cost-dump): Fix typo.
20444 2017-03-17  Pat Haugen  <pthaugen@us.ibm.com>
20446         PR target/79951
20447         * config/rs6000/rs6000.md (copysign<mode>3_fcpsgn): Test
20448         for VECTOR_UNIT_VSX_P (<MODE>mode) too.
20450 2017-03-17  Bernd Schmidt  <bschmidt@redhat.com>
20452         * reload.c (find_reloads): When reloading a nonoffsettable address,
20453         use RELOAD_OTHER for it and its address reloads.
20455         PR rtl-optimization/79910
20456         * combine.c (record_used_regs): New static function.
20457         (try_combine): Handle situations where there is an additional
20458         instruction between I2 and I3 which needs to have a LOG_LINK
20459         updated.
20461 2017-03-17  Jeff Law  <law@redhat.com>
20463         PR tree-optimization/71437
20464         * tree-vrp.c (simplify_stmt_for_jump_threading): Lookup the
20465         conditional in the hash table first.
20466         (vrp_dom_walker::before_dom_children): Extract condition from
20467         ASSERT_EXPR.  Record condition, its inverion and any implied
20468         conditions as well.
20470 2017-03-17  Marek Polacek  <polacek@redhat.com>
20471             Markus Trippelsdorf  <markus@trippelsdorf.de>
20473         PR tree-optimization/80079
20474         * gimple-ssa-store-merging.c (class pass_store_merging): Initialize
20475         m_stores_head.
20477 2017-03-17  Richard Biener  <rguenther@suse.de>
20479         PR middle-end/80075
20480         * tree-eh.c (stmt_could_throw_1_p): Only handle gimple assigns.
20481         Properly verify the LHS before the RHS possibly claims to be
20482         handled.
20483         (stmt_could_throw_p): Hande gimple conds fully here.  Clobbers
20484         do not throw.
20486 2017-03-17  Martin Jambor  <mjambor@suse.cz>
20488         * doc/invoke.texi (Option Options): Include -fipa-vrp in the list.
20489         (List of -O2 options): Likewise.
20490         (-fipa-bit-cp): Replace "ipa" with "interprocedural."
20491         (-fipa-vrp) New.
20493 2017-03-17  Tom de Vries  <tom@codesourcery.com>
20495         * gcov-dump.c (print_usage): Print bug_report_url.
20497 2017-03-17  Richard Biener  <rguenther@suse.de>
20499         PR middle-end/80050
20500         * genmatch.c (parser::next): Remove pointless check for CPP_EOF.
20501         (parser::peek): Likewise.
20503 2017-03-17  Richard Biener  <rguenther@suse.de>
20505         PR tree-optimization/80048
20506         * sese.c (free_sese_info): Properly release rename_map and
20507         copied_bb_map elements.
20509 2017-03-16  Alexandre Oliva <aoliva@redhat.com>
20511         * gimple-ssa-store-merging.c (struct imm_store_chain_info):
20512         Add linked-list forward and backlinks.  Insert on
20513         construction, remove on destruction.
20514         (class pass_store_merging): Add m_stores_head field.
20515         (pass_store_merging::terminate_and_process_all_chains):
20516         Iterate over m_stores_head list.
20517         (pass_store_merging::terminate_all_aliasing_chains):
20518         Likewise.
20519         (pass_store_merging::execute): Check for debug stmts first.
20520         Push new chains onto the m_stores_head stack.
20522 2017-03-16  Michael Meissner  <meissner@linux.vnet.ibm.com>
20524         PR target/71294
20525         * config/rs6000/vsx.md (vsx_splat_<mode>, VSX_D iterator): Allow a
20526         SPLAT operation on ISA 2.07 64-bit systems that have direct move,
20527         but no MTVSRDD support, by doing MTVSRD and XXPERMDI.
20529 2017-03-16  Jeff Law  <law@redhat.com>
20531         PR tree-optimization/71437
20532         * tree-ssa-dom.c (dom_opt_dom_walker): Remove thread_across_edge
20533         member function.  Implementation moved into after_dom_children
20534         member function and into the threader's thread_outgoing_edges
20535         function.
20536         (dom_opt_dom_walker::after_dom_children): Simplify by moving
20537         some code into new thread_outgoing_edges.
20538         * tree-ssa-threadedge.c (thread_across_edge): Make static and simplify
20539         definition.  Simplify marker handling (do it here).   Assume we always
20540         have the available expression and the const/copies tables.
20541         (thread_outgoing_edges): New function extracted from tree-ssa-dom.c
20542         and tree-vrp.c
20543         * tree-ssa-threadedge.h (thread_outgoing_edges): Declare.
20544         * tree-vrp.c (equiv_stack): No longer file scoped.
20545         (vrp_dom_walker): New class.
20546         (vrp_dom_walker::before_dom_children): New member function.
20547         (vrp_dom_walker::after_dom_children): Likewise.
20548         (identify_jump_threads):  Setup domwalker.  Use it rather than
20549         walking edges in a random order by hand.  Simplify setup/finalization.
20550         (finalize_jump_threads): Remove.
20551         (vrp_finalize): Do not call identify_jump_threads here.
20552         (execute_vrp): Do it here instead and call thread_through_all_blocks
20553         here too.
20555         PR tree-optimization/71437
20556         * tree-ssa-dom.c (pfn_simplify): Add basic_block argument.  All
20557         callers changed.
20558         (simplify_stmt_for_jump_threading): Add basic_block argument.  All
20559         callers changed.
20560         (lhs_of_dominating_assert): Moved from here into tree-vrp.c.
20561         (dom_opt_dom_walker::thread_across_edge): Remove
20562         handle_dominating_asserts argument.  All callers changed.
20563         (record_temporary_equivalences_from_stmts_at_dest): Corresponding
20564         changes.  Remove calls to lhs_of_dominating_assert.  Other
20565         uses of handle_dominating_asserts turn into unconditional code
20566         (simplify_control_stmt_condition_1): Likewise.
20567         (simplify_control_stmt_condition): Likewise.
20568         (thread_through_normal_block, thread_across_edge): Likewise.
20569         * tree-ssa-threadedge.h (thread_across_edge): Corresponding changes.
20570         * tree-vrp.c (lhs_of_dominating_assert): Move here.  Return original
20571         object if it is not an SSA_NAME.
20572         (simplify_stmt_for_jump_threading): Call lhs_of_dominating_assert
20573         before calling into the VRP specific simplifiers.
20574         (identify_jump_threads): Remove handle_dominating_asserts
20575         argument.
20577 2017-03-16  Jakub Jelinek  <jakub@redhat.com>
20579         PR fortran/79886
20580         * tree-diagnostic.c (default_tree_printer): No longer static.
20581         * tree-diagnostic.h (default_tree_printer): New prototype.
20583 2017-03-16  Tamar Christina  <tamar.christina@arm.com>
20585         * config/aarch64/aarch64-simd.md (*aarch64_simd_mov<mode>)
20586         Change ins into fmov.
20588 2017-03-16  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
20590         * config/aarch64/iterators.md (h_con): Return "x" for V4HF and V8HF.
20591         * config/aarch64/aarch64-simd.md (*aarch64_fma4_elt_from_dup<mode>):
20592         Use h_con constraint for operand 1.
20593         (*aarch64_fnma4_elt_from_dup<mode>): Likewise.
20594         (*aarch64_mulx_elt_from_dup<mode>): Likewise for operand 2.
20596 2017-03-15  Jeff Law  <law@redhat.com>
20598         PR tree-optimization/71437
20599         * tree-ssa-dom.c (derive_equivalences_from_bit_ior): New function.
20600         (record_temporary_equivalences): Use it.
20602         PR tree-optimization/71437
20603         * tree-ssa-dom.c (struct cond_equivalence): Moved from here into
20604         tree-ssa-scopedtables.
20605         (lookup_avail_expr, build_and_record_new_cond): Likewise.
20606         (record_conditions, record_cond, vuse_eq): Likewise.
20607         (record_edge_info): Adjust to API tweak of record_conditions.
20608         (simplify_stmt_for_jump_threading): Similarly for lookup_avail_expr.
20609         (record_temporary_equivalences, optimize_stmt): Likewise.
20610         (eliminate_redundant_computations): Likewise.
20611         (record_equivalences_from_stmt): Likewise.
20612         * tree-ssa-scopedtables.c: Include options.h and params.h.
20613         (vuse_eq): New function, moved from tree-ssa-dom.c
20614         (build_and_record_new_cond): Likewise.
20615         (record_conditions): Likewise.  Accept vector of conditions rather
20616         than edge_equivalence structure for first argument.
20617         for the first argument.
20618         (avail_exprs_stack::lookup_avail_expr): New member function, moved
20619         from tree-ssa-dom.c.
20620         (avail_exprs_stack::record_cond): Likewise.
20621         * tree-ssa-scopedtables.h (struct cond_equivalence): Moved here
20622         from tree-ssa-dom.c.
20623         (avail_exprs_stack): Add new member functions lookup_avail_expr
20624         and record_cond.
20625         (record_conditions): Declare.
20627 2017-03-15  Vladimir Makarov  <vmakarov@redhat.com>
20629         PR target/80017
20630         * lra-constraints.c (process_alt_operands): Increase reject for
20631         reloading an input/output operand.
20633 2017-03-15  Michael Meissner  <meissner@linux.vnet.ibm.com>
20635         PR target/79038
20636         * config/rs6000/rs6000.md (float<QHI:mode><IEEE128:mode>2): Define
20637         insns to convert from signed/unsigned char/short to IEEE 128-bit
20638         floating point.
20639         (floatuns<QHI:mode><IEEE128:mode>2): Likewise.
20641 2017-03-15  Uros Bizjak  <ubizjak@gmail.com>
20643         PR target/80019
20644         * config/i386/i386.c (ix86_vector_duplicate_value): Create
20645         subreg of inner mode for values already in registers.
20647 2017-03-15  Bernd Schmidt  <bschmidt@redhat.com>
20649         * config/c6x/c6x.c (hwloop_optimize): Handle case where the old
20650         iteration reg is used after the loop.
20652 2017-03-14  Martin Sebor  <msebor@redhat.com>
20654         PR tree-optimization/79800
20655         * gimple-ssa-sprintf.c (format_floating: Add argument.  Handle
20656         precision in negative-positive range.
20657         (format_floating): Call non-const overload with adjusted precision.
20659 2017-03-14  Michael Meissner  <meissner@linux.vnet.ibm.com>
20661         PR target/79947
20662         * config/rs6000/rs6000.h (TARGET_FRSQRTES): Add check for
20663         -mpowerpc-gfxopt.
20665 2017-03-14  Martin Sebor  <msebor@redhat.com>
20667         PR middle-end/80020
20668         * builtin-attrs.def (ATTR_ALLOC_SIZE_2_NOTHROW_LIST): New macro.
20669         * builtins.def (aligned_alloc): Use it.
20671         PR c/79936
20672         * Makefile.in (GTFILES): Add calls.c.
20673         * calls.c: Include "gt-calls.h".
20675 2017-03-14  Bernd Schmidt  <bschmidt@redhat.com>
20677         PR rtl-optimization/79728
20678         * regs.h (struct target_regs): New field
20679         x_contains_allocatable_regs_of_mode.
20680         (contains_allocatable_regs_of_mode): New macro.
20681         * reginfo.c (init_reg_sets_1): Initialize it, and change
20682         contains_reg_of_mode so it includes global regs as well.
20683         * reload.c (push_reload): Use contains_allocatable_regs_of_mode
20684         rather than contains_regs_of_mode.
20686 2017-03-14  Martin Liska  <mliska@suse.cz>
20688         * doc/invoke.texi: Document options that can't be combined with
20689         -fcheck-pointer-bounds.
20691 2017-03-14  Martin Liska  <mliska@suse.cz>
20693         PR middle-end/79831
20694         * doc/invoke.texi (-Wchkp): Document the option.
20696 2017-03-14  Martin Liska  <mliska@suse.cz>
20698         * Makefile.in: Install gcov-dump.
20700 2017-03-14  Martin Liska  <mliska@suse.cz>
20702         * multiple_target.c (expand_target_clones): Bail out for
20703         an invalid attribute.
20705 2017-03-14  Richard Biener  <rguenther@suse.de>
20707         * alias.c (struct alias_set_entry): Pack properly.
20708         * cfgloop.h (struct loop): Likewise.
20709         * cse.c (struct set): Likewise.
20710         * ipa-utils.c (struct searchc_env): Likewise.
20711         * loop-invariant.c (struct invariant): Likewise.
20712         * lra-remat.c (struct cand): Likewise.
20713         * recog.c (struct change_t): Likewise.
20714         * rtl.h (struct address_info): Likewise.
20715         * symbol-summary.h (function_summary): Likewise.
20716         * tree-loop-distribution.c (struct partition): Likewise.
20717         * tree-object-size.c (struct object_size_info): Likewise.
20718         * tree-ssa-loop-ivopts.c (struct cost_pair): Likewise.
20719         * tree-ssa-threadupdate.c (struct ssa_local_info_t): Likewise.
20720         * tree-vect-data-refs.c (struct _vect_peel_info): Likewise.
20721         * tree-vect-slp.c (struct _slp_oprnd_info): Likewise.
20722         * tree-vect-stmts.c (struct simd_call_arg_info): Likewise.
20723         * tree-vectorizer.h (struct _loop_vec_info): Likewise.
20724         (struct _stmt_vec_info): Likewise.
20726 2017-03-14  Martin Liska  <mliska@suse.cz>
20728         PR target/79892
20729         * multiple_target.c (create_dispatcher_calls): Check that
20730         a target can create a function dispatcher.
20732 2017-03-14  Martin Liska  <mliska@suse.cz>
20734         PR lto/66295
20735         * multiple_target.c (expand_target_clones): Drop local.local
20736         flag for default implementation.
20738 2017-03-14  Richard Biener  <rguenther@suse.de>
20740         PR tree-optimization/80030
20741         * tree-vect-stmts.c (vectorizable_store): Plug memleak.
20743 2017-03-13  Kito Cheng  <kito.cheng@gmail.com>
20745         * config/riscv/riscv.c (riscv_emit_float_compare>: Use
20746         gcc_fallthrough() instead of __attribute__((fallthrough));
20748 2017-03-13  Gerald Pfeifer  <gerald@pfeifer.com>
20750         * doc/gcc.texi: Remove "up" link to (DIR).
20751         * doc/gccint.texi: Ditto.
20753 2017-03-13  Gerald Pfeifer  <gerald@pfeifer.com>
20755         * doc/install.texi (Specific) <avr>: Remove reference to
20756         binutils 2.13.
20758 2017-03-13  Jeff Law  <law@redhat.com>
20760         * config/riscv/riscv.c (riscv_emit_float_compare): Use fallthru
20761         attribute rather than comments.
20763         * config/pdp11/pdp11.md (movmemhi): Adjust operand numbers to
20764         match_scratch operand is highest.
20766 2017-03-13  Martin Liska  <mliska@suse.cz>
20768         PR middle-end/78339
20769         * ipa-pure-const.c (warn_function_noreturn): If the declarations
20770         is a CHKP clone, use original declaration.
20772 2017-03-13  Claudiu Zissulescu  <claziss@synopsys.com>
20774         * config/arc/arc.c (arc_init): Use multiplier whenever we have it.
20775         (arc_conditional_register_usage): Use a different allocation order
20776         when optimizing for size.
20777         * common/config/arc/arc-common.c (arc_option_optimization_table):
20778         Section anchors default on when optimizing for size.
20780 2017-03-13  Claudiu Zissulescu  <claziss@synopsys.com>
20782         * config/arc/arc.md (*tst_bitfield_tst): Fix pattern.
20784 2017-03-13  Claudiu Zissulescu  <claziss@synopsys.com>
20786         * config/arc/arc.c (arc_output_addsi): Emit code density adds.
20787         * config/arc/arc.md (cpu_facility): Add cd variant.
20788         (*movqi_insn): Add code density variant.
20789         (*movhi_insn): Likewise.
20790         (*movqi_insn): Likewise.
20791         (*addsi3_mixed): Likewise.
20792         (subsi3_insn): Likewise.
20794 2017-03-13  Claudiu Zissulescu  <claziss@synopsys.com>
20796         * config/arc/arc.md (movsi_cond_exec): Update constraint.
20798 2017-03-13  Claudiu Zissulescu  <claziss@synopsys.com>
20800         * config/arc/arc.c (arc_legitimize_pic_address): Handle PIC
20801         expressions with MINUS and UNARY ops.
20803 2017-03-13  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
20805         PR target/79911
20806         * config/arm/neon.md (vec_sel_widen_ssum_lo<VQI:mode><VW:mode>3):
20807         Rename to...
20808         (vec_sel_widen_ssum_lo<mode><V_half>3): ... This. Avoid mismatch
20809         between vec_select and vector argument.
20810         (vec_sel_widen_ssum_hi<VQI:mode><VW:mode>3): Rename to...
20811         (vec_sel_widen_ssum_hi<mode><V_half>3): ... This. Likewise.
20812         (vec_sel_widen_usum_lo<VQI:mode><VW:mode>3): Rename to...
20813         (vec_sel_widen_usum_lo<mode><V_half>3): ... This.
20814         (vec_sel_widen_usum_hi<VQI:mode><VW:mode>3): Rename to...
20815         (vec_sel_widen_usum_hi<mode><V_half>3): ... This.
20817 2017-03-13  Richard Biener  <rguenther@suse.de>
20819         PR other/79991
20820         * params.def (vect-max-peeling-for-alignment): Fix typo.
20822 2017-03-12  Gerald Pfeifer  <gerald@pfeifer.com>
20824         * doc/install.texi (Specific) <mips-*-*>: Remove description of
20825         issue that only occurred with binutils below 2.18.
20827 2017-03-12  Gerald Pfeifer  <gerald@pfeifer.com>
20829         * doc/install.texi (Specific) <cris-axis-elf>: No longer
20830         refer to binutils 2.11/2.12 minimum.
20832 2017-03-12  Gerald Pfeifer  <gerald@pfeifer.com>
20834         * doc/install.texi (Specific) <powerpc-*-*>: Remove link to
20835         ftp.kernel.org and simplify binutils requirement.
20837 2017-03-11  Gerald Pfeifer  <gerald@pfeifer.com>
20839         * doc/invoke.texi (Warning Options): Fix spelling of link-time
20840         optimization.
20841         (Optimize Options): Ditto.  Also remove redundancy.
20843 2017-03-10  David Malcolm  <dmalcolm@redhat.com>
20845         PR translation/79848
20846         * ipa-devirt.c (warn_types_mismatch): Simplify uses of "%<%s%>" to
20847         "%qs".
20848         * ipa-pure-const.c (suggest_attribute): Likewise.  Convert _
20849         to G_ to avoid double translation.
20851 2017-03-10  David Malcolm  <dmalcolm@redhat.com>
20853         PR translation/79923
20854         * auto-profile.c (get_combined_location): Convert leading
20855         character of diagnostics to lower case and remove trailing period.
20856         (read_profile): Likewise for various diagnostics.
20857         * config/arm/arm.c (arm_option_override): Remove trailing period
20858         from various diagnostics.
20859         * config/msp430/msp430.c (msp430_expand_delay_cycles): Likewise.
20860         (msp430_expand_delay_cycles): Likewise.
20862 2017-03-10  David Malcolm  <dmalcolm@redhat.com>
20864         PR target/79925
20865         * config/aarch64/aarch64.c (aarch64_validate_mcpu): Quote the
20866         full command-line argument, rather than just "str".
20867         (aarch64_validate_march): Likewise.
20868         (aarch64_validate_mtune): Likewise.
20870 2017-03-10  Bernd Schmidt  <bschmidt@redhat.com>
20872         PR rtl-optimization/78911
20873         * lra-assigns.c (must_not_spill_p): New function.
20874         (spill_for): Use it.
20876 2017-03-10  Jakub Jelinek  <jakub@redhat.com>
20878         PR tree-optimization/79981
20879         * tree-vrp.c (extract_range_basic): Handle IMAGPART_EXPR of
20880         ATOMIC_COMPARE_EXCHANGE ifn result.
20881         (stmt_interesting_for_vrp, vrp_visit_stmt): Handle
20882         IFN_ATOMIC_COMPARE_EXCHANGE.
20884 2017-03-10  David Malcolm  <dmalcolm@redhat.com>
20886         PR driver/79875
20887         * opts.c (parse_sanitizer_options): Add missing question mark to
20888         "did you mean" message.
20890 2017-03-10  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
20892         * config/rs6000/rs6000-builtin.def (VMULEUB_UNS): Remove orphaned
20893         built-in.
20894         (VMULEUH_UNS): Likewise.
20895         (VMULOUB_UNS): Likewise.
20896         (VMULOUH_UNS): Likewise.
20897         * config/rs6000/rs6000.c (builtin_function_type): Remove
20898         references to ALTIVEC_BUILTIN_VMUL[EO]U[BH]_UNS.
20900 2017-03-10  David Malcolm  <dmalcolm@redhat.com>
20902         PR bootstrap/79952
20903         * read-rtl-function.c (function_reader::read_rtx_operand): Update
20904         x with result of extra_parsing_for_operand_code_0.
20905         (function_reader::extra_parsing_for_operand_code_0): Convert
20906         return type from void to rtx, returning x.  When reading
20907         SYMBOL_REF with SYMBOL_FLAG_HAS_BLOCK_INFO, reallocate x to the
20908         larger size containing struct block_symbol.
20910 2017-03-10  Segher Boessenkool  <segher@kernel.crashing.org>
20912         * config/rs6000/rs6000.c (rs6000_option_override_internal): Disallow
20913         -mfloat128-hardware without -m64.
20915 2017-03-10  Will Schmidt <will_schmidt@vnet.ibm.com>
20917         PR target/79941
20918         * config/rs6000/rs6000.c (builtin_function_type): Add VMUL*U[HB]
20919         entries to the case statement that marks unsigned arguments to
20920         overloaded functions.
20922 2017-03-10  Kelvin Nilsen  <kelvin@gcc.gnu.org>
20924         * config/rs6000/rs6000.c (rs6000_option_override_internal): Fix
20925         two typographic errors in the handling of TARGET_UPPER_REGS_DI.
20927 2017-03-10  Pat Haugen  <pthaugen@us.ibm.com>
20929         PR target/79907
20930         * config/rs6000/rs6000.c (rs6000_init_hard_regno_mode_ok): Test
20931         TARGET_UPPER_REGS_DI when setting 'wi' constraint regclass.
20933 2017-03-10  Martin Liska  <mliska@suse.cz>
20935         PR target/65705
20936         PR target/69804
20937         * toplev.c (process_options): Enable MPX with LSAN and UBSAN.
20938         * tree-chkp.c (chkp_walk_pointer_assignments): Verify that
20939         FIELD != NULL.
20941 2017-03-10  Olivier Hainque  <hainque@adacore.com>
20943         * tree-switch-conversion (array_value_type): Start by resetting
20944         candidate type to it's main variant.
20946 2017-03-10  Jakub Jelinek  <jakub@redhat.com>
20948         PR rtl-optimization/79909
20949         * combine.c (try_combine): Use simplify_replace_rtx on individual
20950         CALL_INSN_FUNCTION_USAGE elements instead of replace_rtx on copy_rtx
20951         of the whole CALL_INSN_FUNCTION_USAGE.
20953         PR tree-optimization/79972
20954         * gimple-ssa-warn-alloca.c (alloca_call_type): Only call
20955         get_range_info on SSA_NAMEs.  Formatting fixes.
20957 2017-03-10  Richard Biener  <rguenther@suse.de>
20958             Jakub Jelinek  <jakub@redhat.com>
20960         PR tree-optimization/77975
20961         * tree-ssa-loop-niter.c (get_base_for): Allow phi argument from latch
20962         edge to be constant.
20963         (get_val_for): For constant x return it.  Formatting fix.
20964         (loop_niter_by_eval): Avoid pointless looping if the next iteration
20965         would use the same bases as the current one.
20967 2017-03-09  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
20969         * config/rs6000/rs6000.c (rs6000_gen_le_vsx_permute): Use rotate
20970         instead of vec_select for V1TImode.
20971         * conifg/rs6000/vsx.md (VSX_LE): Remove mode iterator that is no
20972         longer needed.
20973         (VSX_LE_128): Add V1TI to this mode iterator.
20974         (*vsx_le_perm_load_<mode>): Change to use VSX_D mode iterator.
20975         (*vsx_le_perm_store_<mode>): Likewise.
20976         (pre-reload splitter for VSX stores): Likewise.
20977         (post-reload splitter for VSX stores): Likewise.
20978         (*vsx_xxpermdi2_le_<mode>): Likewise.
20979         (*vsx_lxvd2x2_le_<mode>): Likewise.
20980         (*vsx_stxvd2x2_le_<mode>): Likewise.
20982 2017-03-09  Michael Eager  <eager@eagercon.com>
20984         Correct failures with --enable-checking=yes,rtl.
20986         * config/microblaze/microblaze.c (microblaze_expand_shift):
20987         Replace GET_CODE test with CONST_INT_P and INTVAL test with
20988         test for const0_rtx.
20989         * config/microblaze/microblaze.md (ashlsi3_byone, ashrsi3_byone,
20990         lshrsi3_byone): Replace INTVAL with test for const1_rtx.
20992 2017-03-09  Richard Biener  <rguenther@suse.de>
20994         PR tree-optimization/79977
20995         * graphite-scop-detection.c (scop_detection::merge_sese):
20996         Handle the case of extra exits to blocks dominating the entry.
20998 2017-03-09  Toma Tabacu  <toma.tabacu@imgtec.com>
21000         * doc/sourcebuild.texi (Effective-Target Keywords, Other attributes):
21001         Document rdynamic.
21003 2017-03-09  Vladimir Makarov  <vmakarov@redhat.com>
21005         PR rtl-optimization/79949
21006         * lra-constraints.c (process_alt_operands): Check memory when
21007         trying to predict a cycle.  Print about the overall increase.
21009 2017-03-09  Richard Biener  <rguenther@suse.de>
21011         PR middle-end/79971
21012         * gimple-expr.c (useless_type_conversion_p): Preserve
21013         TYPE_SATURATING for fixed-point types.
21015 2017-03-09  Richard Biener  <rguenther@suse.de>
21017         PR ipa/79970
21018         * ipa-prop.c (ipa_modify_formal_parameters): Avoid changing
21019         alignment of BLKmode params.
21021 2017-03-09  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
21023         PR target/79913
21024         * config/aarch64/iterators.md (VALL_F16_NO_V2Q): New mode iterator.
21025         (VALL_NO_V2Q): Likewise.
21026         (VDQF_DF): Delete.
21027         * config/aarch64/aarch64-simd.md
21028         (aarch64_dup_lane_<vswap_width_name><mode>): Use VALL_F16_NO_V2Q
21029         iterator.
21030         (*aarch64_simd_vec_copy_lane_<vswap_width_name><mode>): Use
21031         VALL_NO_V2Q mode iterator.
21032         (*aarch64_vgetfmulx<mode>): Use VDQF iterator.
21034 2017-03-09  Martin Liska  <mliska@suse.cz>
21036         PR tree-optimization/79631
21037         * tree-chkp-opt.c (chkp_is_constant_addr): Call
21038         tree_int_cst_sign_bit just for INTEGER constants.
21040 2017-03-09  Martin Liska  <mliska@suse.cz>
21042         PR target/65705
21043         PR target/69804
21044         * toplev.c (process_options): Disable -fcheck-pointer-bounds with
21045         sanitizers.
21047 2017-03-09  Marek Polacek  <polacek@redhat.com>
21049         PR c++/79672
21050         * tree.c (inchash::add_expr): Handle TREE_VEC.
21052 2017-03-09  Martin Liska  <mliska@suse.cz>
21054         PR ipa/79764
21055         (chkp_narrow_size_and_offset): New function.
21056         (chkp_parse_array_and_component_ref): Support BIT_FIELD_REF.
21057         (void chkp_parse_bit_field_ref): New function.
21058         (chkp_make_addressed_object_bounds): Add case for BIT_FIELD_REF.
21059         (chkp_process_stmt): Use chkp_parse_bit_field_ref.
21061 2017-03-09  Martin Liska  <mliska@suse.cz>
21063         PR ipa/79761
21064         * tree-chkp.c (chkp_get_bound_for_parm): Get bounds for a param.
21065         (chkp_find_bounds_1): Remove gcc_unreachable.
21067 2017-03-09  Jakub Jelinek  <jakub@redhat.com>
21069         PR sanitizer/79944
21070         * asan.c (get_mem_refs_of_builtin_call): For BUILT_IN_ATOMIC* and
21071         BUILT_IN_SYNC*, determine the access type from the size suffix and
21072         always build a MEM_REF with that type.  Handle forgotten
21073         BUILT_IN_SYNC_FETCH_AND_NAND_16 and BUILT_IN_SYNC_NAND_AND_FETCH_16.
21075         PR target/79932
21076         * config/i386/avx512vlintrin.h (_mm256_cmpge_epi32_mask,
21077         _mm256_cmpge_epi64_mask, _mm256_cmpge_epu32_mask,
21078         _mm256_cmpge_epu64_mask, _mm256_cmple_epi32_mask,
21079         _mm256_cmple_epi64_mask, _mm256_cmple_epu32_mask,
21080         _mm256_cmple_epu64_mask, _mm256_cmplt_epi32_mask,
21081         _mm256_cmplt_epi64_mask, _mm256_cmplt_epu32_mask,
21082         _mm256_cmplt_epu64_mask, _mm256_cmpneq_epi32_mask,
21083         _mm256_cmpneq_epi64_mask, _mm256_cmpneq_epu32_mask,
21084         _mm256_cmpneq_epu64_mask, _mm256_mask_cmpge_epi32_mask,
21085         _mm256_mask_cmpge_epi64_mask, _mm256_mask_cmpge_epu32_mask,
21086         _mm256_mask_cmpge_epu64_mask, _mm256_mask_cmple_epi32_mask,
21087         _mm256_mask_cmple_epi64_mask, _mm256_mask_cmple_epu32_mask,
21088         _mm256_mask_cmple_epu64_mask, _mm256_mask_cmplt_epi32_mask,
21089         _mm256_mask_cmplt_epi64_mask, _mm256_mask_cmplt_epu32_mask,
21090         _mm256_mask_cmplt_epu64_mask, _mm256_mask_cmpneq_epi32_mask,
21091         _mm256_mask_cmpneq_epi64_mask, _mm256_mask_cmpneq_epu32_mask,
21092         _mm256_mask_cmpneq_epu64_mask, _mm_cmpge_epi32_mask,
21093         _mm_cmpge_epi64_mask, _mm_cmpge_epu32_mask, _mm_cmpge_epu64_mask,
21094         _mm_cmple_epi32_mask, _mm_cmple_epi64_mask, _mm_cmple_epu32_mask,
21095         _mm_cmple_epu64_mask, _mm_cmplt_epi32_mask, _mm_cmplt_epi64_mask,
21096         _mm_cmplt_epu32_mask, _mm_cmplt_epu64_mask, _mm_cmpneq_epi32_mask,
21097         _mm_cmpneq_epi64_mask, _mm_cmpneq_epu32_mask, _mm_cmpneq_epu64_mask,
21098         _mm_mask_cmpge_epi32_mask, _mm_mask_cmpge_epi64_mask,
21099         _mm_mask_cmpge_epu32_mask, _mm_mask_cmpge_epu64_mask,
21100         _mm_mask_cmple_epi32_mask, _mm_mask_cmple_epi64_mask,
21101         _mm_mask_cmple_epu32_mask, _mm_mask_cmple_epu64_mask,
21102         _mm_mask_cmplt_epi32_mask, _mm_mask_cmplt_epi64_mask,
21103         _mm_mask_cmplt_epu32_mask, _mm_mask_cmplt_epu64_mask,
21104         _mm_mask_cmpneq_epi32_mask, _mm_mask_cmpneq_epi64_mask,
21105         _mm_mask_cmpneq_epu32_mask, _mm_mask_cmpneq_epu64_mask): Move
21106         definitions outside of __OPTIMIZE__ guarded section.
21108         PR target/79932
21109         * config/i386/avx512bwintrin.h (_mm512_packs_epi32,
21110         _mm512_maskz_packs_epi32, _mm512_mask_packs_epi32,
21111         _mm512_packus_epi32, _mm512_maskz_packus_epi32,
21112         _mm512_mask_packus_epi32): Move definitions outside of __OPTIMIZE__
21113         guarded section.
21115 2017-03-09  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
21117         * config/s390/vx-builtins.md ("vfee<mode>", "vfeez<mode>")
21118         ("vfenez<mode>"): Add missing constraints.
21120 2017-03-08  Martin Sebor  <msebor@redhat.com>
21122         PR target/79928
21123         * config/nds32/nds32.c (nds32_option_override):
21124         Fix misspelled diagnostic.
21126 2017-03-08  Jakub Jelinek  <jakub@redhat.com>
21128         PR c/79940
21129         * gimplify.c (gimplify_omp_for): Replace index var in outer
21130         taskloop statement with an artificial variable and add
21131         OMP_CLAUSE_PRIVATE clause for it.
21133 2017-03-08  Richard Biener  <rguenther@suse.de>
21135         PR tree-optimization/79955
21136         * tree-ssa-uninit.c (warn_uninitialized_vars): Do not warn
21137         for accesses that are completely outside of the variable.
21139 2017-03-08  Andrew Haley  <aph@redhat.com>
21141         PR tree-optimization/79943
21142         * tree-ssa-loop-split.c (compute_new_first_bound): When
21143         calculating the new upper bound, (END-BEG) should be added, not
21144         subtracted.
21146 2017-03-08  Jakub Jelinek  <jakub@redhat.com>
21148         * config/avr/avr.md (setmemhi): Make sure match_dup
21149         operand number comes before match_scratch.
21151 2017-03-08  Richard Biener  <rguenther@suse.de>
21153         PR tree-optimization/79920
21154         * tree-vect-slp.c (vect_create_mask_and_perm): Remove and inline
21155         with ncopies == 1 to ...
21156         (vect_transform_slp_perm_load): ... here.  Properly compute
21157         all element loads by iterating VF times over the group.  Do
21158         not handle ncopies (computed in a broken way) in
21159         vect_create_mask_and_perm.
21161 2017-03-08  Jakub Jelinek  <jakub@redhat.com>
21163         PR sanitizer/79904
21164         * internal-fn.c (expand_vector_ubsan_overflow): If arg0 or arg1
21165         is a uniform vector, use uniform_vector_p return value instead of
21166         building ARRAY_REF on folded VIEW_CONVERT_EXPR to array type.
21168 2017-03-07  Marek Polacek  <polacek@redhat.com>
21170         PR middle-end/79809
21171         * gimple-ssa-warn-alloca.c (pass_walloca::gate): Use HOST_WIDE_INT.
21172         (alloca_call_type): Likewise.
21174 2017-03-07  Martin Liska  <mliska@suse.cz>
21176         * gcov.c (process_args): Put comment to correct location.
21178 2017-03-07  Martin Liska  <mliska@suse.cz>
21180         PR middle-end/68270
21181         * tree-chkp.c (chkp_may_narrow_to_field): Add new argument ref.
21182         Use array_at_struct_end_p instead of DECL_CHAIN (field).
21183         (chkp_narrow_bounds_for_field): Likewise.
21184         (chkp_parse_array_and_component_ref): Pass one more argument to
21185         call.
21187 2017-03-07  Richard Biener  <rguenther@suse.de>
21189         * tree-vect-loop-manip.c (slpeel_add_loop_guard): Preserve
21190         preheaders.
21192 2017-03-07  Segher Boessenkool  <segher@kernel.crashing.org>
21194         * config/i386/i386.c (ix86_local_alignment): Align most aggregates
21195         of 16 bytes and more to 16 bytes, not those of 16 bits and more.
21197 2017-03-07  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
21199         PR c/79855
21200         * params.def (PARAM_STORE_MERGING_ALLOW_UNALIGNED): Add full stop
21201         to end of description.
21202         (PARAM_MAX_STORES_TO_MERGE): Likewise.
21204 2017-03-07  Jakub Jelinek  <jakub@redhat.com>
21206         PR rtl-optimization/79901
21207         * config/i386/sse.md (*avx512bw_<code><mode>3<mask_name>): Renamed to
21208         ...
21209         (*avx512f_<code><mode>3<mask_name>): ... this.
21210         (<code><mode>3 with maxmin code iterator): Use VI8_AVX2_AVX512F
21211         iterator instead of VI8_AVX2_AVX512BW.
21213         PR rtl-optimization/79901
21214         * expr.c (expand_expr_real_2): For vector MIN/MAX, if there is no
21215         min/max expander, expand it using expand_vec_cond_expr.
21217         PR sanitizer/79897
21218         * ubsan.c (ubsan_encode_value): Call mark_addressable on the
21219         temporary.
21221 2017-03-06  Jakub Jelinek  <jakub@redhat.com>
21223         PR c++/79821
21224         * dwarf2out.h (dw_vec_const): Change array type from unsigned char *
21225         to void * for PCH reasons.
21226         * dwarf2out.c (output_loc_operands, output_die): Cast
21227         v.val_vec.array to unsigned char *.
21229 2017-03-06  John David Anglin  <danglin@gcc.gnu.org>
21231         PR target/77850
21232         * config/pa/pa-64.h (PAD_VARARGS_DOWN): Don't pad down complex and
21233         vector types.
21235 2017-03-06  Vladimir Makarov  <vmakarov@redhat.com>
21237         PR rtl-optimization/79571
21238         * lra-constraints.c (process_alt_operands): Calculate static
21239         reject and subtract it from overall when only addresses will be
21240         reloaded.
21242 2017-03-06  Julia Koval  <julia.koval@intel.com>
21244         PR target/79793
21245         * config/i386/i386.c (ix86_minimum_incoming_stack_boundary): Set
21246         incoming stack boundary to 128 for 64-bit targets.
21248 2017-03-06  Richard Biener  <rguenther@suse.de>
21250         PR tree-optimization/79894
21251         * tree-vectorizer.c (vectorize_loops): Set loop_vectorized_call
21252         to NULL after folding it.
21254 2017-03-06  Richard Biener  <rguenther@suse.de>
21256         PR tree-optimization/79824
21257         * tree-vect-stmts.c (get_group_load_store_type): Fix alignment
21258         check disabling peeling for gaps.
21260 2017-03-06  Toma Tabacu  <toma.tabacu@imgtec.com>
21262         * doc/sourcebuild.texi (Effective-Target Keywords, Environment
21263         attributes): Document gettimeofday.
21265 2017-03-06  Robin Dapp  <rdapp@linux.vnet.ibm.com>
21267         * config/s390/s390.c (s390_option_override_internal): Set
21268         PARAM_MIN_VECT_LOOP_BOUND
21270 2017-03-06  Robin Dapp  <rdapp@linux.vnet.ibm.com>
21272         * config/s390/s390.c (s390_asm_output_function_label): Use nopr %r0.
21273         * config/s390/s390.md: Likewise.
21275 2017-03-06  Jakub Jelinek  <jakub@redhat.com>
21277         PR target/79812
21278         * config/i386/sse.md (VI8F_256_512): Remove mode iterator.
21279         (<avx2_avx512>_perm<mode>): Rename to ...
21280         (avx2_perm<mode>): ... this.  Use VI8F_256 iterator instead
21281         of VI8F_256_512.
21282         (<avx512>_perm<mode>_mask): Rename to ...
21283         (avx512vl_perm<mode>_mask): ... this.  Use VI8F_256 iterator instead
21284         of VI8F_256_512.
21285         (<avx2_avx512>_perm<mode>_1<mask_name>): Rename to ...
21286         (avx2_perm<mode>_1<mask_name): ... this.  Use VI8F_256 iterator
21287         instead of VI8F_256_512.
21288         (avx512f_perm<mode>): New define_expand.
21289         (avx512f_perm<mode>_mask): Likewise.
21290         (avx512f_perm<mode>_1<mask_name>): New define_insn.
21291         (<avx512>_vec_dup<mode>_1): Fix up vec_select mode.
21293 2017-03-06  Prachi Godbole  <prachi.godbole@imgtec.com>
21295         * config/mips/mips-msa.md (msa_fmax_a_<msafmt>, msa_fmin_a_<msafmt>,
21296         msa_max_a_<msafmt>, msa_min_a_<msafmt>): Introduce mode interator for
21297         if_then_else.
21298         (smin<mode>3, smax<mode>3): Change operand print code from 'B' to 'E'.
21300 2017-03-06  Martin Liska  <mliska@suse.cz>
21302         PR sanitize/79783
21303         * asan.c (asan_expand_poison_ifn): Do not expand ASAN_POISON
21304         when having a SSA NAME w/o VAR_DECL assigned to it.
21306 2017-03-06  Prachi Godbole  <prachi.godbole@imgtec.com>
21308         * config/mips/mips-msa.md (msa_dotp_<su>_d, msa_dpadd_<su>_d,
21309         msa_dpsub_<su>_d): Fix MODE for vec_select.
21311 2017-03-06  Prachi Godbole  <prachi.godbole@imgtec.com>
21313         * config/mips/mips.c (mips_gen_const_int_vector): Change type of last
21314         argument.
21315         * config/mips/mips-protos.h (mips_gen_const_int_vector): Likewise.
21317 2017-03-06  Richard Biener  <rguenther@suse.de>
21319         * lto-streamer.c (lto_check_version): Use %qs in diagnostics.
21320         * plugin.c (register_plugin_info): Likewise.
21321         * tree-chkp.c (chkp_make_static_const_bounds): Likewise.
21323 2017-03-05  Jakub Jelinek  <jakub@redhat.com>
21325         * config/i386/sse.md (sse_storehps, sse_storelps,
21326         avx_<castmode><avxsizesuffix>_<castmode>,
21327         avx512f_<castmode><avxsizesuffix>_<castmode>,
21328         avx512f_<castmode><avxsizesuffix>_256<castmode>): Require
21329         in condition that at least one operand is not a MEM.
21331 2017-03-03  Jakub Jelinek  <jakub@redhat.com>
21333         PR middle-end/79805
21334         * internal-fn.def (ATOMIC_BIT_TEST_AND_SET, ATOMIC_BIT_TEST_AND_RESET,
21335         ATOMIC_BIT_TEST_AND_COMPLEMENT, ATOMIC_COMPARE_EXCHANGE): Remove
21336         ECF_NOTHROW.
21337         * gimple-fold.c (fold_builtin_atomic_compare_exchange): Set
21338         gimple_call_nothrow_p flag based on whether original builtin can throw.
21339         If it can, emit following stmts on the fallthrough edge.
21340         * tree-ssa-ccp.c (optimize_atomic_bit_test_and): Similarly, except
21341         don't create new bb if inserting just debug stmts on the edge, try to
21342         insert them on the fallthru bb or just reset debug stmts.
21344 2017-03-03  Segher Boesssenkool  <segher@kernel.crashing.org>
21346         PR target/43763
21347         * config/rs6000/rs6000.c (rs6000_final_prescan_insn): Save and
21348         restore recog_data (including the operand rtxes inside it) around
21349         the call to get_insn_template.
21351 2017-03-03  Martin Sebor  <msebor@redhat.com>
21353         PR tree-optimization/79699
21354         * context.c (context::~context): Free MPFR caches to avoid
21355         a memory leak on program exit.
21357 2017-03-03  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
21359         * config/aarch64/aarch64.c (aarch64_float_const_representable_p):
21360         Use wide_int::ulow () instead of .elt (0).
21362 2017-03-03  Uros Bizjak  <ubizjak@gmail.com>
21364         * config/i386/i386.md (*pushtf): Change *roF constraint to *roC.
21365         (*pushxf): Limit oF constraint to 32bit targets and add oC
21366         constraint for 64bit targets.
21367         (pushxf splitter): Use PUSH_ROUNDING to calculate stack adjustment.
21368         (*pushdf): Change rmF constraint to rmC.
21370 2017-03-03  Martin Liska  <mliska@suse.cz>
21372         * tree-ssa-loop-prefetch.c (pass_loop_prefetch::execute):
21373         Remove unused variable.
21375 2017-03-03  Jakub Jelinek  <jakub@redhat.com>
21377         PR target/79807
21378         * config/i386/i386.c (ix86_expand_multi_arg_builtin): If target
21379         is a memory operand, increase num_memory.
21380         (ix86_expand_args_builtin): Likewise.
21382 2017-03-03  Jan Hubicka  <jh@suse.cz>
21384         PR lto/79760
21385         * ipa-devirt.c (maybe_record_node): Properly handle
21386         __cxa_pure_virtual visibility.
21388 2017-03-03  Martin Liska  <mliska@suse.cz>
21390         PR tree-optimization/79803
21391         * tree-ssa-loop-prefetch.c (tree_ssa_prefetch_arrays): Remove
21392         assert.
21393         (pass_loop_prefetch::execute): Disabled optimization if an
21394         assumption about L1 cache size is not met.
21396 2017-03-03  Martin Liska  <mliska@suse.cz>
21398         PR rtl-optimization/79574
21399         * gcse.c (struct gcse_expr): Use HOST_WIDE_INT instead of int.
21400         (hash_scan_set): Likewise.
21401         (dump_hash_table): Likewise.
21402         (hoist_code): Likewise.
21404 2017-03-03  Richard Biener  <rguenther@suse.de>
21406         * fixed-value.c (fixed_from_string): Restore use of elt (1)
21407         in place of uhigh ().
21408         (fixed_convert_from_real): Likewise.
21410 2017-03-03  Uros Bizjak  <ubizjak@gmail.com>
21412         PR target/79514
21413         * config/i386/i386.md (*pushxf_rounded): Use Pmode instead of DImode.
21415 2017-03-03  Richard Biener  <rguenther@suse.de>
21417         PR middle-end/79818
21418         * match.pd ( X +- C1 CMP C2 -> X CMP C2 -+ C1): Add missing
21419         TYPE_OVERFLOW_UNDEFINED check.
21421 2017-03-02  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
21423         * config/rs6000/vector.md (vector_ne_<mode>_p): Correct operand
21424         numbers.
21425         (vector_ae_<mode>_p): Likewise.
21426         (vector_nez_<mode>_p): Likewise.
21427         (vector_ne_v2di_p): Likewise.
21428         (vector_ae_v2di_p): Likewise.
21429         (vector_ne_<mode>_p): Likewise.
21430         * config/rs6000/vsx.md (vsx_tsqrt<mode>2_fg): Correct operand
21431         numbers.
21432         (vsx_tsqrt<mode>2_fe): Likewise.
21434 2017-03-02  Uros Bizjak  <ubizjak@gmail.com>
21436         PR target/79514
21437         * config/i386/i386.md (*pushxf_rounded): New insn_and_split pattern.
21439 2017-03-02  Jakub Jelinek  <jakub@redhat.com>
21441         PR rtl-optimization/79780
21442         * cprop.c (one_cprop_pass): When second and further conditional trap
21443         in a single basic block is turned into an unconditional trap, turn it
21444         into a deleted note to avoid RTL verification failures.
21446 2017-03-02  Richard Biener  <rguenther@suse.de>
21448         * fold-const.c (const_binop): Use ulow () instead of elt (0).
21450 2017-03-02  Richard Biener  <rguenther@suse.de>
21452         PR tree-optimization/79345
21453         PR c++/42000
21454         * tree-ssa-alias.c (walk_aliased_vdefs_1): Take a limit
21455         param and abort the walk, returning -1 if it is hit.
21456         (walk_aliased_vdefs): Take a limit param and pass it on.
21457         * tree-ssa-alias.h (walk_aliased_vdefs): Add a limit param,
21458         defaulting to 0 and return a signed int.
21459         * tree-ssa-uninit.c (struct check_defs_data): New struct.
21460         (check_defs): New helper.
21461         (warn_uninitialized_vars): Use walk_aliased_vdefs to warn
21462         about uninitialized memory.
21463         * fixed-value.c (fixed_from_string): Use ulow/uhigh to avoid
21464         bogus uninitialized warning.
21465         (fixed_convert_from_real): Likewise.
21467 2017-03-02  Bin Cheng  <bin.cheng@arm.com>
21469         PR tree-optimization/66768
21470         * tree-ssa-loop-ivopts.c (find_interesting_uses_address): Skip addr
21471         iv_use if base object can't be determined.
21473 2017-03-02  Jakub Jelinek  <jakub@redhat.com>
21475         PR tree-optimization/79345
21476         * gensupport.h (struct pattern_stats): Add min_scratch_opno field.
21477         * gensupport.c (get_pattern_stats_1) <case MATCH_SCRATCH>: Update it.
21478         (get_pattern_stats): Initialize it.
21479         * genemit.c (gen_expand): Verify match_scratch numbers come after
21480         match_operand/match_dup numbers.
21481         * config/i386/i386.md (<s>mul<mode>3_highpart): Swap match_dup and
21482         match_scratch numbers.
21483         * config/i386/sse.md (avx2_gathersi<mode>, avx2_gatherdi<mode>):
21484         Likewise.
21485         * config/s390/s390.md (trunctdsd2): Likewise.
21487 2017-03-02  Richard Biener  <rguenther@suse.de>
21489         * wide-int.h (wide_int_storage::operator=): Implement in terms
21490         of wi::copy.
21492 2017-03-02  Richard Biener  <rguenther@suse.de>
21494         PR tree-optimization/79777
21495         * tree-ssa-pre.c (eliminate_insert): Give up if we simplify
21496         the to insert expression to sth existing.
21498 2017-03-01  Martin Sebor  <msebor@redhat.com>
21500         PR middle-end/79692
21501         * gimple-ssa-sprintf.c
21502         (directive::known_width_and_precision): New function.
21503         (format_integer): Use it.
21504         (get_mpfr_format_length): Consider the full range of precision
21505         when computing %g output with the # flag.  Set the likely byte
21506         count to 3 rather than 1 when precision is indeterminate.
21507         (format_floating): Correct the lower bound of precision.
21509 2017-03-01  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
21511         * doc/invoke.texi: Document default code model for 64-bit Linux.
21513 2017-03-01  Aaron Sawdey  <acsawdey@linux.vnet.ibm.com>
21515         PR target/79752
21516         * config/rs6000/rs6000.md (peephole2 for udiv/umod): Should emit
21517         udiv rather than div since input pattern is unsigned.
21519 2017-03-01  Uros Bizjak  <ubizjak@gmail.com>
21521         * config/i386/i386.c (print_reg): Warn for values of
21522         unsupported size in integer register.
21524 2017-03-01  Michael Meissner  <meissner@linux.vnet.ibm.com>
21526         PR target/79439
21527         * config/rs6000/predicates.md (current_file_function_operand): Do
21528         not allow self calls to be local if the function is replaceable.
21530 2017-03-01  Kelvin Nilsen  <kelvin@gcc.gnu.org>
21532         PR target/79395
21533         * config/rs6000/altivec.h (vec_ctz and others): Change the
21534         preprocessor macro that controls conditional compilation from
21535         _ARCH_PWR9 to __POWER9_VECTOR__.
21536         (vec_all_ne): Change parameterization of __altivec_scalar_pred
21537         macro expansion under preprocessor #ifdef __POWER9_VECTOR__
21538         control (instead of _ARCH_PWR9 control) so that template
21539         definition uses power9-specific function.
21540         (vec_any_eq): Likewise.
21541         (vec_all_ne): Change macro definition to use a power9-specific
21542         expansion under #ifdef __POWER9_VECTOR__ control (instead of
21543         _ARCH_PWR9 control).
21544         (vec_any_eq) Likewise.
21545         * config/rs6000/rs6000-builtin.def (CMPNEF): Remove BU_P9V_AV_2
21546         expansion for CMPNEF to remove support for xvcmpnesp instruction.
21547         (CMPNED): Remove BU_P9V_AV2 expansion for CMPNED to remove
21548         support for xvcmpnedp instruction.
21549         (VCMPNEB_P): Replace BU_P9V_AV_P macro expansion with BU_P9V_AV_2
21550         macro expansion so that Power9 implementation of vec_all_ne does
21551         not use the AltiVec predicate framework.
21552         (VCMPNEH_P): Likewise.
21553         (VCMPNEW_P): Likewise.
21554         (VCMPNED_P): Likewise.
21555         (VCMPNEFP_P): Likewise.
21556         (VCMPNEDP_P): Likewise.
21557         (VCMPAEB_P): Add BU_P9V_AV_2 macro expansion to change
21558         implementation of vec_any_eq to not use AltiVec predicate
21559         framework.
21560         (VCMPAEH_P): Likewise.
21561         (VCMPAEW_P): Likewise.
21562         (VCMPAED_P): Likewise.
21563         (VCMPAEFP_P): Likewise.
21564         (VCMPAEDP_P): Likewise.
21565         (VCMPNE_P): Replace BU_P9V_OVERLOAD_P macro expansion with
21566         BU_P9V_OVERLOAD_2 so that Power9 implementation of vec_all_ne does
21567         not use the AltiVec predicate framework.
21568         (VCMPAE_P): Add BU_P9V_OVERLOAD_2 macro to change implementation
21569         of vec_any_eq to not use AltiVec predicate framework.
21570         * config/rs6000/rs6000-c.c (rs6000_target_modify_macros): Add
21571         support for predefined __POWER9_VECTOR__ macro to indicate that
21572         Power9 instruction selection is enabled.
21573         (altivec_overloaded_builtins): Remove extraneous
21574         ALTIVEC_BUILTIN_VEC_CMPNE entry for overloaded
21575         function argument types RS6000_BTI_bool_V16QI and
21576         RS6000_BTI_bool_V16QI.  Remove erroneous ALTIVEC_BUILTIN_VEC_CMPNE
21577         entry for overloaded function argument types RS6000_BTI_bool_V4SI
21578         andRS6000_BTI_bool_V4SI, mapping to P9V_BUILTIN_CMPNEB.  Remove
21579         two entries mapping to P9V_BUITIN_CMPNED and one entry mapping to
21580         P9V_BUILTIN_CMPNEF to force use of instructions not specific to
21581         Power9 for implementations of vec_cmpne.  Change the signature for
21582         all definitions of the overloaded P9V_BUILTIN_VEC_CMPNE_P function
21583         (representing vec_all_ne) to remove the previously described first
21584         argument of type RS6000_BTI_INTSI, as this was an artifact of
21585         reliance on the AltiVec predicate framework, which is no longer
21586         used in the implementation of these functions.  Add
21587         P9V_BUILTIN_VEC_VCMPAE_P entries (representing the vec_anyeq
21588         function) to match all of the P9V_BUILTIN_VEC_VCMNE_P entries
21589         since, unlike the AltiVec predicate framework implementation, we
21590         do not share function descriptors between vec_alle and vec_anyeq.
21591         (altivec_resolve_overloaded_builtin): Add SFmode and DFmode to the
21592         set of modes that receive special treatment even when
21593         TARGET_P9_VECTOR is true.  The special treatment emits code that
21594         does not depend on Power9 instructions.
21595         * config/rs6000/vector.md (vector_ne_<mode>_p): Change this
21596         define_expand to not rely on AltiVec predicate framework.
21597         (vector_ae_<mode>p): New define_expand to represent vec_any_eq
21598         function.
21599         (vector_ne_v2di_p): Change this define_expand to not rely on
21600         AltiVec predicate framework.
21601         (vector_ae_v2di_p): New define_expand to represent vec_any_eq
21602         function.
21603         (vector_ne_<mode>_p): Change this define_expand to not rely on
21604         AltiVec predicate framework.
21605         (vector_ae_<mode>p): New define_expand to represent vec_any_eq
21606         function.
21607         * config/rs6000/vsx.md (*vsx_ne_<mode>_p): For modes VSX_EXTRACT_I
21608         (V16QI, V8HI, V4SI), correct a typo in the code emitted for this
21609         define_insn pattern.
21610         (*vsx_ne_<mode>_p): For modes VSX_F (V4SF and V2DF), remove this
21611         define_insn pattern because the xvcmpne<VSs>. instruction is not
21612         supported.
21613         (vcmpne<VSs>): Remove this define_insn because xvcmpne<VSs>
21614         instruction is not supported.
21616 2017-03-01  Jakub Jelinek  <jakub@redhat.com>
21618         * config/nvptx/nvptx.c: Include intl.h.
21620 2017-03-01  Martin Jambor  <mjambor@suse.cz>
21622         PR lto/78140
21623         * ipa-prop.h (ipa_bits): Removed field known.
21624         (ipa_jump_func): Removed field vr_known.  Changed fields bits and m_vr
21625         to pointers.  Adjusted their comments to warn about their sharing.
21626         (ipcp_transformation_summary): Change bits to a vector of pointers.
21627         (ipa_check_create_edge_args): Moved to ipa-prop.c, declare.
21628         (ipa_get_ipa_bits_for_value): Declare.
21629         * tree-vrp.h (value_range): Mark as GTY((for_user)).
21630         * ipa-prop.c (ipa_bit_ggc_hash_traits): New.
21631         (ipa_bits_hash_table): Likewise.
21632         (ipa_vr_ggc_hash_traits): Likewise.
21633         (ipa_vr_hash_table): Likewise.
21634         (ipa_print_node_jump_functions_for_edge): Adjust for bits and m_vr
21635         being pointers and vr_known being removed.
21636         (ipa_set_jf_unknown): Likewise.
21637         (ipa_get_ipa_bits_for_value): New function.
21638         (ipa_set_jfunc_bits): Likewise.
21639         (ipa_get_value_range): New overloaded functions.
21640         (ipa_set_jfunc_vr): Likewise.
21641         (ipa_compute_jump_functions_for_edge): Use the above functions to
21642         construct bits and vr parts of jump functions.
21643         (ipa_check_create_edge_args): Move here from ipa-prop.h, also allocate
21644         ipa_bits_hash_table and ipa_vr_hash_table if they do not already
21645         exist.
21646         (ipcp_grow_transformations_if_necessary): Also allocate
21647         ipa_bits_hash_table and ipa_vr_hash_table if they do not already
21648         exist.
21649         (ipa_node_params_t::duplicate): Do not copy bits, just pointers to
21650         them.  Fix too long lines.
21651         (ipa_write_jump_function): Adjust for bits and m_vr being pointers and
21652         vr_known being removed.
21653         (ipa_read_jump_function): Use new setter functions to construct bits
21654         and vr parts of jump functions or set them to NULL.
21655         (write_ipcp_transformation_info): Adjust for bits being pointers.
21656         (read_ipcp_transformation_info): Likewise.
21657         (ipcp_update_bits): Likewise.  Fix excessively long lines a trailing
21658         space.
21659         Include gt-ipa-prop.h.
21660         * ipa-cp.c (propagate_bits_across_jump_function): Adjust for bits
21661         being pointers.
21662         (ipcp_store_bits_results): Likewise.
21663         (propagate_vr_across_jump_function): Adjust for m_vr being a pointer.
21664         Do not write to existing jump functions but use a temporary instead.
21666 2017-03-01  Jakub Jelinek  <jakub@redhat.com>
21668         PR c++/79681
21669         * fold-const.c (make_bit_field_ref): If orig_inner is COMPONENT_REF,
21670         attempt to use its first operand as BIT_FIELD_REF base.
21672 2017-03-01  Richard Biener  <rguenther@suse.de>
21674         PR middle-end/79721
21675         * tree-chrec.c (chrec_evaluate): Perform computation of Newtons
21676         interpolating formula in wrapping arithmetic.
21677         (chrec_apply): Convert chrec_evaluate return value to wanted type.
21679 2017-03-01  Jakub Jelinek  <jakub@redhat.com>
21681         PR tree-optimization/79734
21682         * tree-vect-generic.c (expand_vector_condition): Optimize
21683         AVX512 vector boolean VEC_COND_EXPRs into bitwise operations.
21684         Handle VEC_COND_EXPR where comparison has different inner width from
21685         type's inner width.
21687 2017-02-28  Sandra Loosemore  <sandra@codesourcery.com>
21689         * doc/invoke.texi (ARC Options): Copy-edit to fix punctuation,
21690         markup, and similar issues.  Remove @opindex entries for things
21691         that aren't options.  Add missing -mmpy-option entries.
21693 2017-02-28  Jakub Jelinek  <jakub@redhat.com>
21695         PR tree-optimization/79737
21696         * gimple-ssa-store-merging.c (encode_tree_to_bitpos): If bitlen is
21697         a multiple of BITS_PER_UNIT and !BYTES_BIG_ENDIAN, clear
21698         tmpbuf[byte_size - 1].  Call natice_encode_expr with byte_size - 1
21699         instead of byte_size.  Formatting fix.
21700         (shift_bytes_in_array_right): Formatting fix.
21702 2017-02-28  Eric Botcazou  <ebotcazou@adacore.com>
21704         PR target/79749
21705         * config/sparc/sparc.c (sparc_frame_pointer_required): Add missing
21706         condition on optimize for the leaf function test.
21708 2017-02-28  Martin Liska  <mliska@suse.cz>
21710         PR lto/79625
21711         * read-rtl-function.c (function_reader::handle_unknown_directive):
21712         Bail out when one uses -flto.
21714 2017-02-28  Martin Liska  <mliska@suse.cz>
21716         * common.opt: Replace space with tabular for options of <number>
21717         type.
21718         * config/i386/i386.opt: Show <number> value for
21719         -mlarge-data-threshold.
21720         * opts.c (print_filtered_help): Do not display number in hexadecimal
21721         format.
21723 2017-02-28  Martin Liska  <mliska@suse.cz>
21725         * common.opt: Fix --help=option -Q for options which are of
21726         an enum type.
21728 2017-02-28  Uros Bizjak  <ubizjak@gmail.com>
21730         * config/i386/i386.c (print_reg): Error out for values
21731         of 8-bit size in invalid integer register.
21733 2017-02-28  Martin Sebor  <msebor@redhat.com>
21735         PR tree-optimization/79691
21736         * passes.def (pass_all_optimizations_g): Enable pass_sprintf_length.
21738 2017-02-28  Jakub Jelinek  <jakub@redhat.com>
21740         PR target/79729
21741         * config/i386/i386.c (ix86_print_operand) <case 'R'>: Replace
21742         gcc_unreachable with output_operand_lossage.
21744 2017-02-28  Richard Biener  <rguenther@suse.de>
21746         PR tree-optimization/79740
21747         * tree-ssa-sccvn.c (vn_nary_op_insert_into): Allow redundant
21748         inserts.
21749         (visit_nary_op): Insert the nary into the hashtable if we
21750         pattern-matched sth.
21751         * tree-ssa-pre.c (eliminate_insert): Robustify.
21753 2017-02-28  Richard Biener  <rguenther@suse.de>
21755         PR middle-end/79731
21756         * fold-const.c (decode_field_reference): Reject out-of-bound
21757         accesses.
21759 2017-02-28  Jakub Jelinek  <jakub@redhat.com>
21761         * config/i386/i386.c: Include intl.h.
21762         (ix86_option_override_internal): Use cond ? G_("...") : G_("...")
21763         instead of just cond ? "..." : "...".
21764         * config/nvptx/nvptx.c (nvptx_goacc_validate_dims): Likewise.
21765         * coverage.c (read_counts_file): Likewise.
21766         * omp-offload.c: Include intl.h.
21767         (oacc_loop_fixed_partitions): Use cond ? G_("...") : G_("...") instead
21768         of just cond ? "..." : "...".
21769         * gcov.c (read_count_file): Use cond ? N_("...") : N_("...") instead
21770         of just cond ? "..." : "...".
21772 2017-02-28  Richard Earnshaw  <rearnsha@arm.com>
21774         PR target/79742
21775         * config/arm/parsecpu.awk (gen_data): Set tuning target to 'tune for'
21776         entry, if present.
21777         * config/arm/arm-cpus.in (cortex-m0plus.small-multiply): Correct
21778         'tune for' CPU name.
21779         * config/arm/arm-cpu-data.h: Regenerated.
21781 2017-02-28  Richard Biener  <rguenther@suse.de>
21783         PR tree-optimization/79732
21784         * tree-inline.c (expand_call_inline): Do not shadow var.
21786 2017-02-28  Richard Biener  <rguenther@suse.de>
21788         PR tree-optimization/79723
21789         * tree-vect-stmts.c (get_vectype_for_scalar_type_and_size): Preserve
21790         address-space properly.
21792 2017-02-28  Thomas Schwinge  <thomas@codesourcery.com>
21794         * doc/optinfo.texi (Optimization groups): Fix option used for
21795         OPTGROUP_ALL.
21796         * doc/invoke.texi (-fopt-info): Document "omp".
21797         * dumpfile.h: Sort OPTGROUP_OMP before OPTGROUP_VEC.
21798         (OPTGROUP_ALL): Add OPTGROUP_OMP.
21799         * hsa-gen.c (pass_data_gen_hsail): Use OPTGROUP_OMP.
21800         * ipa-hsa.c (pass_data_ipa_hsa): Likewise.
21801         * omp-simd-clone.c (pass_data_omp_simd_clone): Likewise.
21803         * dumpfile.h (OPTGROUP_OPENMP): Rename to OPTGROUP_OMP.  Adjust
21804         all users.
21805         * dumpfile.c (optgroup_options): Instead of "openmp", associate
21806         OPTGROUP_OMP with "omp".
21808 2017-02-27  Pat Haugen  <pthaugen@us.ibm.com>
21810         PR target/79544
21811         * config/rs6000/rs6000-c.c (struct altivec_builtin_types): Use VSRAD
21812         for arithmetic shift of unsigned V2DI.
21814 2017-02-27  Claudiu Zissulescu  <claziss@synopsys.com>
21816         * config.gcc (arc*-): Clean up, use arc/big.h, arc/elf.h, and
21817         arc/linux.h headers.
21818         * config/arc/arc.h (TARGET_OS_CPP_BUILTINS): Remove.
21819         (LINK_SPEC): Likewise.
21820         (ARC_TLS_EXTRA_START_SPEC): Likewise.
21821         (EXTRA_SPECS): Likewise.
21822         (STARTFILE_SPEC): Likewise.
21823         (ENDFILE_SPEC): Likewise.
21824         (LIB_SPEC): Likewise.
21825         (TARGET_SDATA_DEFAULT): Likewise.
21826         (TARGET_MMEDIUM_CALLS_DEFAULT): Likewise.
21827         (MULTILIB_DEFAULTS): Likewise.
21828         (DWARF2_UNWIND_INFO): Likewise.
21829         * config/arc/big.h: New file.
21830         * config/arc/elf.h: Likewise.
21831         * config/arc/linux.h: Likewise.
21832         * config/arc/t-uClibc: Remove.
21834 2017-02-27  Bin Cheng  <bin.cheng@arm.com>
21836         PR tree-optimization/77536
21837         * tree-ssa-loop-manip.c (niter_for_unrolled_loop): New function.
21838         (tree_transform_and_unroll_loop): Use above function to compute the
21839         estimated niter of unrolled loop and use it when scaling profile.
21840         Also use count info rather than frequency if it's non-zero.
21841         * tree-ssa-loop-manip.h niter_for_unrolled_loop(): New declaration.
21842         * tree-vect-loop.c (scale_profile_for_vect_loop): New function.
21843         (vect_transform_loop): Call above function.
21845 2017-02-27  Richard Biener  <rguenther@suse.de>
21847         PR tree-optimization/45397
21848         * tree-ssa-pre.c (eliminate_insert): Handle BIT_AND_EXPR.
21849         * tree-ssa-sccvn.c (valueized_wider_op): New helper.
21850         (visit_nary_op): Add pattern matching for CSEing sign-changed
21851         or truncated operations with wider ones.
21853 2017-02-27  Richard Biener  <rguenther@suse.de>
21855         PR tree-optimization/79690
21856         * tree-vect-stmts.c (vectorizable_store): Use vector type
21857         built from the DR with address-space.
21859 2017-02-26  Gerald Pfeifer  <gerald@pfeifer.com>
21861         * doc/invoke.texi (Optimize Options): Refine the description
21862         of asan-use-after-return.
21864 2017-02-25  Alan Modra  <amodra@gmail.com>
21866         PR rtl-optimization/79584
21867         * lra-constraints.c (base_to_reg): Reload ad->base, the entire
21868         base, not ad->base_term, the reg within base.  Remove assertion
21869         that ad->base == ad->base_term.  Replace gen_int_mode using
21870         bogus mode with const0_rtx.
21872 2017-02-25  Jakub Jelinek  <jakub@redhat.com>
21874         PR middle-end/79396
21875         * tree-eh.c (operation_could_trap_p, stmt_could_throw_1_p): Handle
21876         FMA_EXPR like tcc_binary or tcc_unary.
21878         * tree-ssa-loop-niter.c (number_of_iterations_exit): Simplify warning.
21880         PR debug/77589
21881         * dwarf2out.c (struct dw_loc_list_struct): Add noted_variable_value
21882         bitfield.
21883         (size_of_loc_descr): Handle DW_OP_GNU_variable_value.
21884         (output_loc_operands): Handle DW_OP_call_ref and
21885         DW_OP_GNU_variable_value.
21886         (struct variable_value_struct): New type.
21887         (struct variable_value_hasher): Likewise.
21888         (variable_value_hash): New variable.
21889         (string_types): Remove.
21890         (copy_loc_descr): New function.
21891         (add_loc_descr_to_each): Clarify comment.  Use copy_loc_descr.
21892         (prepend_loc_descr_to_each): New function.
21893         (add_loc_list): Fix comment typo.  Use prepend_loc_descr_to_each
21894         instead of add_loc_descr_to_each if the first argument is single
21895         location list and the second has multiple.
21896         (resolve_args_picking_1): Handle DW_OP_GNU_variable_value.
21897         (loc_list_from_tree_1): For early_dwarf, emit DW_OP_GNU_variable_value
21898         when looking for variable value which doesn't have other location info.
21899         (loc_list_from_tree): Formatting fix.
21900         (gen_array_type_die): Simplify DW_AT_string_length handling.
21901         (adjust_string_types): Remove.
21902         (gen_subprogram_die): Don't call adjust_string_types nor test/set
21903         string_types.  Call resolve_variable_values.
21904         (prune_unused_types_walk_loc_descr): Handle DW_OP_GNU_variable_value.
21905         (resolve_addr_in_expr): Likewise.  Add A argument.
21906         (copy_deref_exprloc): Remove deref argument.  Adjust for the
21907         original expression being DW_OP_GNU_variable_value with optionally
21908         DW_OP_stack_value after it instead of DW_OP_call4 with DW_OP_deref
21909         optionally after it.
21910         (optimize_string_length): Rework for DW_OP_GNU_variable_value.
21911         (resolve_addr): Adjust optimize_string_length and resolve_addr_in_expr
21912         callers.  Set remove_AT_byte_size if removing DW_AT_string_length.
21913         (variable_value_hasher::hash, variable_value_hasher::equal): New
21914         methods.
21915         (resolve_variable_value_in_expr, resolve_variable_value,
21916         resolve_variable_values, note_variable_value_in_expr,
21917         note_variable_value): New functions.
21918         (dwarf2out_early_finish): Call note_variable_value on all toplevel
21919         DIEs.
21921 2017-02-24  Jakub Jelinek  <jakub@redhat.com>
21923         PR c/79677
21924         * opts.h (handle_generated_option): Add GENERATED_P argument.
21925         * opts-common.c (handle_option): Adjust function comment.
21926         (handle_generated_option): Add GENERATED_P argument, pass it to
21927         handle_option.
21928         (control_warning_option): Pass false to handle_generated_option
21929         GENERATED_P.
21930         * opts.c (maybe_default_option): Pass true to handle_generated_option
21931         GENERATED_P.
21932         * optc-gen.awk: Likewise.
21934 2017-02-24  Segher Boessenkool  <segher@kernel.crashing.org>
21936         * config/sh/sh.md (tstsi_t): If operands[0] is a SUBREG instead of
21937         a REG, look at the REG it is a SUBREG of.
21938         (splitter for cmpeqsi_t): Ditto.
21940 2017-02-24  Segher Boessenkool  <segher@kernel.crashing.org>
21942         * config/pa/pa.c (pa_combine_instructions): Do not share RTL.  Make
21943         the special USEs with the pattern of the insn, not the insn itself.
21945 2017-02-24  Matthew Fortune  <matthew.fortune@imgtec.com>
21947         PR target/79473
21948         * doc/invoke.texi: Document -mload-store-pairs.
21950 2017-02-24  Segher Boessenkool  <segher@kernel.crashing.org>
21951             Sandra Loosemore  <sandra@codesourcery.com>
21953         * config/nios2/nios2.c (nios2_simple_const_p): Returns false if the
21954         argument isn't a CONST_INT.
21955         (nios2_alternate_compare_const): Assert op is a CONST_INT.
21956         (nios2_valid_compare_const_p): Assert op is a CONST_INT.
21957         (nios2_validate_compare): Bypass alternate compare logic if *op2
21958         is not a CONST_INT.
21959         (ldstwm_operation_p): Return false if first_base is not a REG or
21960         if first_offset is not a CONST_INT.
21962 2017-02-24  Segher Boessenkool  <segher@kernel.crashing.org>
21964         * config/cris/cris.md: Use correct operand in a define_peephole2.
21966 2017-02-24  Segher Boessenkool  <segher@kernel.crashing.org>
21968         * config/c6x/c6x.c (predicate_insn): Do not incorrectly share RTL.
21970 2017-02-24  Segher Boessenkool  <segher@kernel.crashing.org>
21972         * config/arc/arc.c (arc_ccfsm_advance): Only take the PATTERN of
21973         this_insn if it is an INSN or JUMP_INSN.
21974         (force_offsettable): Look at base, not at addr.
21975         * config/arc/predicates.md (brcc_nolimm_operator): Don't call INTVAL
21976         on things that aren't necessarily CONST_INTs.
21978 2017-02-24  Uros Bizjak  <ubizjak@gmail.com>
21980         * doc/invoke.texi (x86 Options, -mfpmath=sse): Mention that
21981         -mfpmath=sse is the default also for x86-32 targets with SSE2
21982         instruction set when @option{-ffast-math} is enabled
21984 2017-02-24  Jeff Law  <law@redhat.com>
21986         PR rtl-optimizatoin/79286
21987         * ira.c (update_equiv_regs): Drop may_trap_p exception to
21988         dominance test.
21990 2017-02-24  Richard Biener  <rguenther@suse.de>
21992         PR tree-optimization/79389
21993         * gimple-ssa-split-paths.c (is_feasible_trace): Properly skip
21994         debug insns.
21996 2017-02-24  Aldy Hernandez  <aldyh@redhat.com>
21998         * tree-ssa-loop-niter.c (number_of_iterations_exit): Update
21999         function comment to reflect reality.
22000         (loop_exits_before_overflow): Fix typo in function description.
22002 2017-02-24  Richard Biener  <rguenther@suse.de>
22004         PR tree-optimization/79389
22005         * gimple-ssa-split-paths.c (is_feasible_trace): Verify more
22006         properly that a threading opportunity exists.  Detect conditional
22007         copy/constant propagation opportunities.
22009 2017-02-23  Eric Botcazou  <ebotcazou@adacore.com>
22011         * config/visium/visium.md (type): Add trap.
22012         (b): New mode attribute.
22013         (*btst): Rename into...
22014         (*btst<mode>): ...this and adjust.
22015         (*cbranchsi4_btst_insn): Rename into...
22016         (*cbranch<mode>4_btst_insn): ...this and adjust.
22017         (trap): New define_insn.
22019 2017-02-23  Jakub Jelinek  <jakub@redhat.com>
22021         PR tree-optimization/79389
22022         * ifcvt.c (struct noce_if_info): Add rev_cond field.
22023         (noce_reversed_cond_code): New function.
22024         (noce_emit_store_flag): Use rev_cond if non-NULL instead of
22025         reversed_comparison_code.  Formatting fix.
22026         (noce_try_store_flag): Test rev_cond != NULL in addition to
22027         reversed_comparison_code.
22028         (noce_try_store_flag_constants): Likewise.
22029         (noce_try_store_flag_mask): Likewise.
22030         (noce_try_addcc): Use rev_cond if non-NULL instead of
22031         reversed_comparison_code.
22032         (noce_try_cmove_arith): Likewise.  Formatting fixes.
22033         (noce_try_minmax, noce_try_abs): Clear rev_cond.
22034         (noce_find_if_block): Initialize rev_cond.
22035         (find_cond_trap): Call noce_get_condition with then_bb == trap_bb
22036         instead of false as last argument never attempt to reverse it
22037         afterwards.
22039 2017-02-23  Bin Cheng  <bin.cheng@arm.com>
22041         PR tree-optimization/79663
22042         * tree-predcom.c (combine_chains): Process refs in reverse order
22043         only for ZERO length chains, and add explaining comment.
22045 2017-02-23  Jeff Law  <law@redhat.com>
22047         PR tree-optimization/79578
22048         * tree-ssa-dse.c (clear_bytes_written_by): Use OEP_ADDRESS_OF
22049         in call to operand_equal_p.
22051 2017-01-23  Dominique d'Humieres  <dominiq@lps.ens.fr>
22053         PR target/71017
22054         * config/i386/cpuid.h: Fix another undefined behavior.
22056 2017-02-23  Richard Biener  <rguenther@suse.de>
22058         PR tree-optimization/79683
22059         * tree-vect-stmts.c (vect_analyze_stmt): Do not overwrite
22060         vector types for data-refs.
22062 2017-02-23  Martin Liska  <mliska@suse.cz>
22064         * params.def (PARAM_MIN_NONDEBUG_INSN_UID): Change default to 0.
22066 2017-02-23  Jakub Jelinek  <jakub@redhat.com>
22068         PR middle-end/79665
22069         * internal-fn.c (get_range_pos_neg): Moved to ...
22070         * tree.c (get_range_pos_neg): ... here.  No longer static.
22071         * tree.h (get_range_pos_neg): New prototype.
22072         * expr.c (expand_expr_real_2) <case TRUNC_DIV_EXPR>: If both arguments
22073         are known to be in between 0 and signed maximum inclusive, try to
22074         expand both unsigned and signed divmod and use the cheaper one from
22075         those.
22077 2017-02-22  Jeff Law  <law@redhat.com>
22079         PR tree-optimization/79578
22080         * tree-ssa-dse.c (clear_bytes_written_by): Use operand_equal_p
22081         to compare base operands.
22083 2017-02-22  Segher Boessenkool  <segher@kernel.crashing.org>
22085         PR target/79211
22086         * config/rs6000/rs6000.md (*fsel<SFDF:mode><SFDF2:mode>4): Use
22087         gpc_reg_operand instead of fpr_reg_operand.
22089 2017-02-22  Sameera Deshpande  <sameera.deshpande@imgtec.com>
22091         * config/mips/mips.c (mips_return_in_memory): Force FP
22092         vector types to be returned in memory for o32 ABI.
22094 2017-02-22  Jakub Jelinek  <jakub@redhat.com>
22096         * dwarf2out.c (gen_variable_die): For -gdwarf-5, use DW_TAG_variable
22097         instead of DW_TAG_member for static data member declarations and don't
22098         set no_linkage_name for static inline data members.
22099         (gen_member_die): For -gdwarf-5 don't change DW_TAG_variable
22100         to DW_TAG_member.
22102 2017-02-22  Martin Liska  <mliska@suse.cz>
22104         * doc/invoke.texi: Replace inequality signs with square brackets
22105         for -Wnormalized.
22107 2017-02-22  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
22109         PR tree-optimization/68644
22110         * gcc.dg/tree-ssa/ivopts-lt-2.c: Skip for powerpc*-*-*.
22112 2017-02-22  Matthew Fortune  <matthew.fortune@imgtec.com>
22114         PR target/78660
22115         * lra-constraints.c (simplify_operand_subreg): Handle
22116         WORD_REGISTER_OPERATIONS targets.
22118 2017-02-22  Jakub Jelinek  <jakub@redhat.com>
22120         PR target/70465
22121         * reg-stack.c (emit_swap_insn): Treat (float_extend:?F (mem:?F))
22122         and (const_double:?F) like (mem:?F) for the purpose of fxch %st(1)
22123         elimination by swapping fld*.
22125 2017-02-22  Richard Biener  <rguenther@suse.de>
22127         PR tree-optimization/79673
22128         * tree-ssa-pre.c (compute_avail): Use wide_int_to_tree to
22129         convert the [TARGET_]MEM_REF offset INTEGER_CST, scrapping off
22130         irrelevant address-space qualifiers and avoiding a
22131         ADDR_SPACE_CONVERT_EXPR from fold_convert.
22133 2017-02-22  Richard Biener  <rguenther@suse.de>
22135         PR tree-optimization/79666
22136         * tree-vrp.c (extract_range_from_binary_expr_1): Make sure
22137         to not symbolically negate if that may introduce undefined
22138         overflow.
22140 2017-02-22  Martin Liska  <mliska@suse.cz>
22142         PR lto/79587
22143         * data-streamer-in.c (streamer_read_gcov_count): Remove assert.
22144         * data-streamer-out.c (streamer_write_gcov_count_stream):
22145         Likewise.
22146         * value-prof.c (stream_out_histogram_value): Make assert more
22147         precise based on type of counter.
22149 2017-02-21  Uros Bizjak  <ubizjak@gmail.com>
22151         PR target/79593
22152         * config/i386/i386.md (standard_x87sse_constant_load splitter):
22153         Use nonimmediate_operand instead of memory_operand for operand 1.
22154         (float-extend standard_x87sse_constant_load splitter): Ditto.
22156 2017-02-21  Jeff Law  <law@redhat.com>
22158         PR tree-optimization/79621
22159         * gimple-ssa-isolate-paths.c (find_implicit_erroneous_behavior): Ignore
22160         blocks with edges to themselves.
22162 2017-02-21  Jakub Jelinek  <jakub@redhat.com>
22164         PR target/79633
22165         * tree-chkp-opt.c (chkp_optimize_string_function_calls): Use
22166         is_gimple_call instead of comparing gimple_code with GIMPLE_CALL.
22167         Use gimple_call_builtin_p.
22169         PR target/79570
22170         * sel-sched.c (moveup_expr_cached): Don't call sel_bb_head
22171         on temporarily removed DEBUG_INSNs.
22173         PR tree-optimization/79649
22174         * tree-loop-distribution.c (classify_partition): Give up on
22175         non-generic address space loads/stores.
22177 2017-02-21  Aldy Hernandez  <aldyh@redhat.com>
22179         * doc/loop.texi (Loop manipulation): Remove nonexistent
22180         tree_ssa_loop_version from the documentation.
22181         * cfgloopmanip.c (loop_version): Document CONDITION_BB argument.
22183 2017-02-21  Jakub Jelinek  <jakub@redhat.com>
22185         PR target/79494
22186         * config/i386/i386.c (ix86_expand_split_stack_prologue): Call
22187         make_reg_eh_region_note_nothrow_nononlocal on call_insn.
22188         * config/rs6000/rs6000.c: Include except.h.
22189         (rs6000_expand_split_stack_prologue): Call
22190         make_reg_eh_region_note_nothrow_nononlocal on the call insn.
22192 2017-02-21  Martin Jambor  <mjambor@suse.cz>
22194         PR lto/79579
22195         * ipa-prop.c (ipa_prop_write_jump_functions): Bail out if no edges
22196         have been analyzed.
22198 2017-02-21  Martin Jambor  <mjambor@suse.cz>
22200         * common.opt (-fipa-cp-alignment): Mark as ignored and preserved
22201         for backward compatibility only.
22202         * doc/invoke.texi (Option Summary): Remove all references to
22203         -fipa-cp-alignment.
22205 2017-02-21  Matthew Fortune  <matthew.fortune@imgtec.com>
22207         PR target/78660
22208         Revert:
22209         2017-02-20  Matthew Fortune  <matthew.fortune@imgtec.com>
22211         * lra-constraints.c (curr_insn_transform): Handle
22212         WORD_REGISTER_OPERATIONS requirements when reloading SUBREGs.
22214 2017-02-21  Martin Liska  <mliska@suse.cz>
22216         * config/i386/i386.opt: Replace -masm-dialect with -masm.
22218 2017-02-21  Thomas Schwinge  <thomas@codesourcery.com>
22220         PR translation/79638
22221         * config/nvptx/nvptx.c (ENTRY_TEMPLATE): Single out "%ntid.y".
22223 2017-02-21  Eric Botcazou  <ebotcazou@adacore.com>
22225         PR ada/67205
22226         * config/arm/arm.c (TARGET_CUSTOM_FUNCTION_DESCRIPTORS): Define.
22227         (arm_function_ok_for_sibcall): Return false for an indirect call by
22228         descriptor if all the argument registers are used.
22229         (arm_relayout_function): Use FUNCTION_ALIGNMENT macro to adjust the
22230         alignment of the function.
22232 2017-02-21  Jakub Jelinek  <jakub@redhat.com>
22234         PR tree-optimization/61441
22235         * simplify-rtx.c (simplify_const_unary_operation): For
22236         -fsignaling-nans and sNaN operand, return NULL_RTX rather than
22237         the sNaN unmodified.
22239 2017-02-20  Bernd Edlinger  <bernd.edlinger@hotmail.de>
22241         * Makefile.in (BUILD_SYSTEM_HEADER_DIR): New make variabe.
22242         (LIMITS_H_TEST, if_multiarch, stmp-fixinc): Use BUILD_SYSTEM_HEADER_DIR
22243         instead of SYSTEM_HEADER_DIR.
22245 2017-02-20  Gerald Pfeifer  <gerald@pfeifer.com>
22246             Martin LiÅ¡ka  <mliska@suse.cz>
22248         * doc/invoke.texi (use-after-scope-direct-emission-threshold):
22249         Fix typos and grammar, use active voice, and clarify.
22251 2017-02-20  Marek Polacek  <polacek@redhat.com>
22253         PR middle-end/79537
22254         * gimplify.c (gimplify_expr): Handle unused *&&L;.
22256         PR sanitizer/79558
22257         * ubsan.c (ubsan_type_descriptor): Check if TYPE_MAX_VALUE is null.
22259 2017-02-20  Jakub Jelinek  <jakub@redhat.com>
22261         PR target/79568
22262         * config/i386/i386.c (ix86_expand_builtin): Handle
22263         OPTION_MASK_ISA_AVX512VL and OPTION_MASK_ISA_64BIT in
22264         ix86_builtins_isa[fcode].isa as a requirement of those
22265         flags and any other flag in the bitmask.
22266         (ix86_init_mmx_sse_builtins): Use 0 instead of
22267         ~OPTION_MASK_ISA_64BIT as mask.
22268         * config/i386/i386-builtin.def (__builtin_ia32_rdtsc,
22269         __builtin_ia32_rdtscp, __builtin_ia32_pause, __builtin_ia32_bsrsi,
22270         __builtin_ia32_rdpmc, __builtin_ia32_rolqi, __builtin_ia32_rolhi,
22271         __builtin_ia32_rorqi, __builtin_ia32_rorhi): Likewise.
22273 2017-02-20  Matthew Fortune  <matthew.fortune@imgtec.com>
22275         PR target/78012
22276         * lra-constraints.c (split_reg): Check requested split mode
22277         is supported by the register.
22279 2017-02-20  Matthew Fortune  <matthew.fortune@imgtec.com>
22281         * lra-constraints.c (simplify_operand_subreg): Remove early
22282         return false.
22284 2017-02-20  Matthew Fortune  <matthew.fortune@imgtec.com>
22286         PR target/78660
22287         * lra-constraints.c (curr_insn_transform): Tighten condition
22288         for converting SUBREG reloads from OP_OUT to OP_INOUT.
22290 2017-02-20  Matthew Fortune  <matthew.fortune@imgtec.com>
22292         PR target/78660
22293         * lra-constraints.c (curr_insn_transform): Handle
22294         WORD_REGISTER_OPERATIONS requirements when reloading SUBREGs.
22296 2017-02-19  Uros Bizjak  <ubizjak@gmail.com>
22298         Revert:
22299         2016-05-30  Uros Bizjak  <ubizjak@gmail.com>
22301         * config/i386/sync.md (mfence_nosse): Use "lock orl $0, -4(%esp)".
22303 2017-02-19  Jonathan Wakely  <jwakely@redhat.com>
22305         PR c++/69523
22306         * doc/invoke.texi (C++ Dialect Options) [-Wliteral-suffix]: Update
22307         description.
22309 2017-02-19  Prathamesh Kulkarni  <prathamesh.kulkarni@linaro.org>
22311         * gimple-pretty-print.c (dump_ternary_rhs): Adjust gimple dump format
22312         for FMA_EXPR.
22314 2017-02-18  Jakub Jelinek  <jakub@redhat.com>
22316         * final.c (last_columnnum, override_columnnum): New variables.
22317         (final_start_function): Set last_columnnum, pass it to begin_prologue
22318         hook and pass 0 to dwarf2out_begin_prologue.
22319         (final_scan_insn): Update override_columnnum.  Pass last_columnnum
22320         to source_line debug hook.
22321         (notice_source_line): Compute last_columnnum and for debug_column_info
22322         return true on column changes.
22323         * debug.h (struct gcc_debug_hooks): Add column argument to
22324         source_line and begin_prologue hooks.
22325         (debug_nothing_int_charstar_int_bool): Remove prototype.
22326         (debug_nothing_int_int_charstar,
22327         debug_nothing_int_int_charstar_int_bool): New prototypes.
22328         (dwarf2out_begin_prologue): Add column argument.
22329         * debug.c (do_nothing_debug_hooks): Adjust source_line and
22330         begin_prologue hooks.
22331         (debug_nothing_int_charstar_int_bool): Remove.
22332         (debug_nothing_int_int_charstar,
22333         debug_nothing_int_int_charstar_int_bool): New functions.
22334         * dwarf2out.c (dwarf2out_begin_prologue): Add column argument, pass it
22335         through to dwarf2out_source_line.
22336         (dwarf2_lineno_debug_hooks): Adjust begin_prologue hook.
22337         (dwarf2out_source_line): Add column argument, emit it if requested.
22338         * sdbout.c (sdbout_source_line, sdbout_begin_prologue): Add column
22339         arguments.
22340         * xcoffout.h (xcoffout_begin_prologue, xcoffout_source_line): Likewise.
22341         * xcoffout.c (xcoffout_begin_prologue, xcoffout_source_line): Likewise.
22342         * vmsdbgout.c (vmsdbgout_begin_prologue): Add column argument, pass it
22343         through to dwarf2out_begin_prologue.
22344         (vmsdbgout_source_line): Add column argument, pass it through to
22345         dwarf2out_source_line.
22346         * dbxout.c (dbxout_begin_prologue): Add column argument, adjust
22347         dbxout_source_line caller.
22348         (dbxout_source_line): Add column argument.
22350         * common.opt (gno-column-info, gcolumn-info): New options.
22351         * dwarf2out.c (dwarf2_lineno_debug_hooks): Formatting fix.
22352         (check_die): Also test for multiple DW_AT_decl_column attributes.
22353         (add_src_coords_attributes, dwarf2out_imported_module_or_decl_1): Add
22354         DW_AT_decl_column if requested.
22355         (gen_subprogram_die): Compare and/or add also DW_AT_decl_column
22356         if requested.
22357         (gen_variable_die): Likewise.
22358         (add_call_src_coords_attributes): Add DW_AT_call_column if requested.
22359         * doc/invoke.texi (-gcolumn-info, -gno-column-info): Document.
22361         PR target/79569
22362         * config/i386/i386.opt (m3dnowa): Replace Undocumented with Report.
22363         * common/config/i386/i386-common.c (OPTION_MASK_ISA_3DNOW_A_SET): Define.
22364         (ix86_handle_option): Handle OPT_m3dnowa.
22365         * doc/invoke.texi (-m3dnowa): Document.
22366         * doc/extend.texi (__builtin_ia32_pmulhuw, __builtin_ia32_pf2iw): Use
22367         -m3dnowa instead of -m3dnow -march=athlon.
22369         PR target/79559
22370         * config/i386/i386.c (ix86_print_operand): Use output_operand_lossage
22371         instead of gcc_assert for K, r and R code checks.  Formatting fixes.
22373 2017-02-17  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
22375         PR target/79261
22376         * config/rs6000/rs6000.c (rs6000_expand_ternop_builtin): Add
22377         support for CODE_FOR_vsx_xxpermdi_v2d[fi]_be.
22378         * config/rs6000/rs6000.md (reload_gpr_from_vsx<mode>): Call
22379         generator for vsx_xxpermdi_<mode>_be.
22380         * config/rs6000/vsx.md (vsx_xxpermdi_<mode>): Remove logic to
22381         force big-endian semantics.
22382         (vsx_xxpermdi_<mode>_be): New define_expand with same
22383         implementation as previous version of vsx_xxpermdi_<mode>.
22385 2017-02-17  Jakub Jelinek  <jakub@redhat.com>
22387         PR tree-optimization/79327
22388         * gimple-ssa-sprintf.c (format_integer): Remove likely_adjust
22389         variable, its initialization and use.
22391 2017-02-17  Julia Koval  <julia.koval@intel.com>
22393         * common/config/i386/i386-common.c (OPTION_MASK_ISA_RDPID_SET): New.
22394         (OPTION_MASK_ISA_PKU_UNSET): New.
22395         (ix86_handle_option): Handle -mrdpid.
22396         * config/i386/cpuid.h (bit_RDPID): New.
22397         * config/i386/driver-i386.c (host_detect_local_cpu):
22398         Detect RDPID feature.
22399         * config/i386/i386-builtin.def (__builtin_ia32_rdpid): New.
22400         * config/i386/i386-c.c (ix86_target_macros_internal):
22401         Handle RDPID flag.
22402         * config/i386/i386.c (ix86_target_string): Add -mrdpid to isa2_opts.
22403         (ix86_valid_target_attribute_inner_p): Add "rdpid".
22404         (ix86_expand_builtin): Handle IX86_BUILTIN_RDPID.
22405         * config/i386/i386.h (TARGET_RDPID, TARGET_RDPID_P): New.
22406         * config/i386/i386.md (define_insn "rdpid"): New.
22407         * config/i386/i386.opt Add -mrdpid.
22408         * config/i386/immintrin.h (_rdpid_u32): New.
22410 2017-02-17  Vladimir Makarov  <vmakarov@redhat.com>
22412         PR rtl-optimization/79541
22413         * lra-constraints.c (curr_insn_transform): Remove wrong asm insn
22414         instead of transforming it into USE.
22416 2017-02-17  Segher Boessenkool  <segher@kernel.crashing.org>
22418         * config/rs6000/rs6000.md (extendsfdf2): Remove default arguments.
22419         If HONOR_SNANS (SFmode) force the input to a register.
22420         (*extendsfdf2_fpr): Add !HONOR_SNANS (SFmode) condition.
22421         (*extendsfdf2_snan): New pattern, used when using SNaNs; it generates
22422         an frsp or similar insn.
22424 2017-02-17  Martin Liska  <mliska@suse.cz>
22426         PR rtl-optimization/79577
22427         * params.def (selsched-max-sched-times): Increase minimum to 1.
22429 2017-02-17  Martin Liska  <mliska@suse.cz>
22431         PR rtl-optimization/79574
22432         * gcse.c (want_to_gcse_p): Prevent integer overflow.
22434 2017-02-17  Martin Liska  <mliska@suse.cz>
22436         PR tree-optimization/79529
22437         * tree-ssa-loop-unswitch.c (is_maybe_undefined): Use
22438         ssa_defined_default_def_p to handle cases which are implicitly
22439         defined.
22440         * tree-ssa.c (ssa_defined_default_def_p): New function.
22441         (ssa_undefined_value_p): Use ssa_defined_default_def_p to handle cases
22442         which are implicitly defined.
22443         * tree-ssa.h (ssa_defined_default_def_p): Declare.
22445 2017-02-17  Richard Biener  <rguenther@suse.de>
22447         PR middle-end/79576
22448         * params.def (max-ssa-name-query-depth): Limit to 10.
22450 2017-02-17  Richard Biener  <rguenther@suse.de>
22452         PR tree-optimization/79552
22453         * tree-ssa-structalias.c (visit_loadstore): Properly verify
22454         default defs.
22456 2017-02-17  Richard Biener  <rguenther@suse.de>
22458         PR bootstrap/79567
22459         * genmatch.c (output_line_directive): Handle DIR_SEPARATOR_2.
22461 2017-02-17  Marek Polacek  <polacek@redhat.com>
22463         PR middle-end/79536
22464         * fold-const.c (fold_negate_expr_1): Renamed from fold_negate_expr.
22465         (fold_negate_expr): New wrapper.
22467 2017-02-16  Sandra Loosemore  <sandra@codesourcery.com>
22469         * doc/invoke.texi (C++ Dialect Options) [-Wno-non-template-friend]: 
22470         Correct terminology and de-emphasize pre-standard behavior.
22472 2017-02-16  Alan Modra  <amodra@gmail.com>
22474         PR rtl-optimization/79286
22475         * ira.c (def_dominates_uses): New function.
22476         (update_equiv_regs): Don't create an equivalence for insns that
22477         may trap where the register def does not dominate the use.
22479 2017-02-16  Vladimir Makarov  <vmakarov@redhat.com>
22481         PR rtl-optimization/78127
22482         * lra.c (lra): Call lra_eliminate before finish the loop after
22483         lra_constraint.
22485 2017-02-16  Richard Biener  <rguenther@suse.de>
22487         * graphite.h: Do not include isl/isl_val_gmp.h, instead include
22488         isl/isl_val.h.
22489         * graphite-isl-ast-to-gimple.c (gmp_cst_to_tree): Remove.
22490         (gcc_expression_from_isl_expr_int): Use generic isl_val interface.
22491         * graphite-sese-to-poly.c: Do not include isl/isl_val_gmp.h.
22492         (isl_val_int_from_wi): New function.
22493         (extract_affine_gmp): Rename to ...
22494         (extract_affine_wi): ... this, take a widest_int.
22495         (extract_affine_int): Just wrap extract_affine_wi.
22496         (add_param_constraints): Use isl_val_int_from_wi.
22497         (add_loop_constraints): Likewise, and extract_affine_wi.
22499 2017-02-15  Jeff Law  <law@redhat.com>
22501         PR middle-end/79521
22502         * ira-costs.c (scan_one_insn): Check have_regs_of_mode before calling
22503         ira_init_register_move_cost_if_necessary.
22505 2017-02-15  Martin Sebor  <msebor@redhat.com>
22507         PR middle-end/32003
22508         * doc/invoke.texi (-fdump-final-insns): Replace option accidentally
22509         removed in a prior commit.
22511 2017-02-15  Bin Cheng  <bin.cheng@arm.com>
22513         PR tree-optimization/79347
22514         * tree-vect-loop-manip.c (vect_do_peeling): Maintain profile
22515         counters during peeling.
22517 2017-02-15  Thomas Schwinge  <thomas@codesourcery.com>
22519         * Makefile.in (site.exp): Remove "set ISLVER".
22521 2017-02-15  Jakub Jelinek  <jakub@redhat.com>
22523         PR target/79487
22524         * real.c (real_from_integer): Call real_convert even for decimal.
22526 2017-02-15  Dominik Vogt  <vogt@linux.vnet.ibm.com>
22528         PR target/79421
22529         * config/s390/s390.c: define TARGET_CUSTOM_FUNCTION_DESCRIPTORS.
22531 2017-02-14  Andrew Pinski  <apinski@cavium.com>
22533         * config/aarch64/aarch64-cores.def (thunderx2t99): Move to under 'C"
22534         cores and change the partno/implementer to be correct.
22535         (thunderx2t99p1): New core which replaces thunderx2t99 and still has
22536         the 'B" as the implementer.
22537         * config/aarch64/aarch64-tune.md: Regenerate.
22539 2017-02-14  Carl Love  <cel@us.ibm.com>
22541         * config/rs6000/rs6000.c: Add case statement entry to make the
22542         xvcvuxdsp built-in argument unsigned.
22543         * config/rs6000/vsx.md: Fix the source and return operand types so they
22544         match the instruction definitions from the ISA document.  Fix typo
22545         in the instruction generation for the (define_insn "vsx_xvcvuxdsp"
22546         statement.
22548 2017-02-14  Vladimir Makarov  <vmakarov@redhat.com>
22550         PR target/79282
22551         * lra-int.h (struct lra_operand_data, struct lra_insn_reg): Add
22552         member early_clobber_alts.
22553         * lra-lives.c (reg_early_clobber_p): New.
22554         (process_bb_lives): Use it.
22555         * lra.c (new_insn_reg): New arg early_clobber_alts.  Use it.
22556         (debug_operand_data): Initialize early_clobber_alts.
22557         (setup_operand_alternative): Set up early_clobber_alts.
22558         (collect_non_operand_hard_regs): Ditto.  Pass early clobber
22559         alternatives to new_insn_reg.
22560         (add_regs_to_insn_regno_info): Add arg early_clobber_alts.  Use
22561         it.
22562         (lra_update_insn_regno_info): Pass the new arg.
22564 2017-02-14  Jakub Jelinek  <jakub@redhat.com>
22566         PR middle-end/79505
22567         * omp-offload.c (free_oacc_loop): Release loop->ifns vector.
22568         (new_oacc_loop_raw): Don't clear already cleared fields.
22570         PR target/79481
22571         * config/i386/avx512pfintrin.h (_mm512_prefetch_i32gather_pd,
22572         _mm512_prefetch_i32gather_ps, _mm512_prefetch_i64gather_pd,
22573         _mm512_prefetch_i64gather_ps): New inline functions and macros.
22575 2017-02-14  Uros Bizjak  <ubizjak@gmail.com>
22577         PR target/79495
22578         * config/i386/i386.md (*movxf_internal): Add (o,rC) alternative.
22580 2017-02-14  H.J. Lu  <hongjiu.lu@intel.com>
22582         PR target/79498
22583         * config/i386/i386.c (timode_scalar_chain::convert_insn): Insert
22584         the extra instruction to the right place to store 128-bit constant
22585         when needed.
22587 2017-02-14  Martin Sebor  <msebor@redhat.com>
22589         PR middle-end/79448
22590         * gimple-ssa-sprintf.c (format_directive): Avoid issuing INT_MAX
22591           warning for strings of unknown length.
22593 2017-02-13  Segher Boessenkool  <segher@kernel.crashing.org>
22595         * config.gcc (supported_defaults) [powerpc*-*-*]: Update.
22597 2017-02-14  Jeff Law  <law@redhat.com>
22599         PR target/79404
22600         * ira-costs.c (scan_one_insn): Initialize register move costs
22601         for pseudos seen in USE/CLOBBER insns.
22603         PR tree-optimization/79095
22604         * tree-vrp.c (extract_range_from_binary_expr_1): For EXACT_DIV_EXPR,
22605         if the numerator has the range ~[0,0] make the resultant range ~[0,0].
22606         (extract_range_from_binary_expr): For MINUS_EXPR with no derived range,
22607         if the operands are known to be not equal, then the resulting range
22608         is ~[0,0].
22609         (intersect_ranges): If the new range is ~[0,0] and the old range is
22610         wide, then prefer ~[0,0].
22611         * tree-vrp.c (overflow_comparison_p_1): New function.
22612         (overflow_comparison_p): New function.
22613         * tree-vrp.c (register_edge_assert_for_2): Register additional asserts
22614         if NAME is used in an overflow test.
22615         (vrp_evaluate_conditional_warnv_with_ops): If the ops represent an
22616         overflow check that can be expressed as an equality test, then adjust
22617         ops to be that equality test.
22619 2017-02-14  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
22621         * config/s390/s390-builtin-types.def: Remove flags argument.
22622         * config/s390/s390.c (s390_init_builtins): Likewise.
22624 2017-02-14  Martin Liska  <mliska@suse.cz>
22626         * tree-ssa-loop-unswitch.c (hoist_guard): Release get_loop_body
22627         vector.  Fix trailing white spaces.
22629 2017-02-14  James Greenhalgh  <james.greenhalgh@arm.com>
22631         * config/aarch64/aarch64.c (aarch64_simd_container_mode): Handle
22632         HFmode.
22634 2017-02-14  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
22636         PR rtl-optimization/68664
22637         * config/arm/arm.c (arm_sched_can_speculate_insn):
22638         New function.  Declare prototype.
22639         (TARGET_SCHED_CAN_SPECULATE_INSN): Define.
22641 2017-02-14  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
22643         PR rtl-optimization/68664
22644         * config/aarch64/aarch64.c (aarch64_sched_can_speculate_insn):
22645         New function.
22646         (TARGET_SCHED_CAN_SPECULATE_INSN): Define.
22648 2017-02-14  Amit Pawar  <amit.pawar@amd.com>
22650         * config/i386/i386.c (znver1_cost): Fix the alignment for function and
22651         max skip bytes for function, loop and jump.
22653 2017-02-14  Prathamesh Kulkarni  <prathamesh.kulkarni@linaro.org>
22655         * gimple-pretty-print.c (dump_unary_rhs): Adjust dump format for
22656         ABS_EXPR for gimple dump.
22658 2017-02-14  Jakub Jelinek  <jakub@redhat.com>
22660         PR target/79462
22661         * config/sh/sh.c (expand_cbranchdi4): Don't clear operands[4].
22663         PR tree-optimization/79408
22664         * tree-vrp.c (simplify_div_or_mod_using_ranges): Handle also the
22665         case when on TRUNC_MOD_EXPR op0 is INTEGER_CST.
22666         (simplify_stmt_using_ranges): Call simplify_div_or_mod_using_ranges
22667         also if rhs1 is INTEGER_CST.
22669 2017-02-14  Richard Biener  <rguenther@suse.de>
22671         PR middle-end/79432
22672         * tree-into-ssa.c (insert_phi_nodes): When the function can
22673         have abnormal edges rewrite SSA names with broken use-def
22674         dominance out of SSA and register them for PHI insertion.
22676 2017-02-13  Martin Sebor  <msebor@redhat.com>
22678         PR middle-end/79496
22679         * gimple-ssa-sprintf.c (pass_sprintf_length::handle_gimple_call): Avoid
22680         clearing info.nowrite flag when snprintf size argument is a range.
22682 2017-02-13  Jakub Jelinek  <jakub@redhat.com>
22684         * cprop.c (cprop_jump): Add missing space in string literal.
22685         * tree-ssa-structalias.c (rewrite_constraints): Likewise.
22686         (get_constraint_for_component_ref): Likewise.
22687         * df-core.c (df_worklist_dataflow_doublequeue): Likewise.
22688         * tree-outof-ssa.c (insert_partition_copy_on_edge): Likewise.
22689         * lra-constraints.c (process_alt_operands): Likewise.
22690         * ipa-inline.c (inline_small_functions): Likewise.
22691         * tree-ssa-sccvn.c (visit_reference_op_store): Likewise.
22692         * cgraph.c (cgraph_edge::redirect_call_stmt_to_callee): Likewise.
22693         * trans-mem.c (diagnose_tm_1_op): Likewise.
22694         * omp-grid.c (grid_find_single_omp_among_assignments): Likewise.
22695         (grid_parallel_clauses_gridifiable): Likewise.
22697         * config/nvptx/mkoffload.c (process): Add space in between
22698         , and %d.
22700         * config/i386/i386.h (REG_CLASS_NAMES): Add , in between
22701         "MOD4_SSE_REGS" and "ALL_REGS".
22703         * spellcheck.c (test_data): Add , in between "foo" and "food".
22705 2017-02-13  Aaron Sawdey  <acsawdey@linux.vnet.ibm.com>
22707         PR target/79449
22708         * config/rs6000/rs6000.c (expand_block_compare): Make sure runtime
22709         boundary crossing check and subsequent code generation agree.
22711 2017-02-13  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
22713         * config/aarch64/aarch64.c (has_memory_op): Delete.
22714         (aarch64_madd_needs_nop): Use contains_mem_rtx_p instead of
22715         has_memory_op.
22717 2017-02-13  Jakub Jelinek  <jakub@redhat.com>
22719         PR rtl-optimization/79388
22720         PR rtl-optimization/79450
22721         * combine.c (distribute_notes): When removing TEM_INSN for which
22722         corresponding dest has last value recorded, invalidate that last
22723         value.
22725 2017-02-13  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
22727         * config/arm/arm.c (arm_print_tune_info): Use ASM_COMMENT_START instead
22728         of explicit '@'.  Add missing assembly comment marker on branch costs
22729         printout.
22731 2017-02-13  Nathan Sidwell  <nathan@acm.org>
22733         * gengtype-lex.l (<in_struct>): Add '/'.
22735 2017-02-13  Martin Liska  <mliska@suse.cz>
22737         PR c/79471
22738         * calls.c (expand_call): Replace XALLOCAVEC with XCNEWVEC.
22740 2017-02-13  Richard Biener  <rguenther@suse.de>
22742         * configure.ac (HAVE_ISL_OPTIONS_SET_SCHEDULE_SERIALIZE_SCCS):
22743         Remove.
22744         * configure: Re-generate.
22745         * config.in: Likewise.
22746         * graphite-dependences.c: Simplify as if
22747         HAVE_ISL_OPTIONS_SET_SCHEDULE_SERIALIZE_SCCS was defined.
22748         * graphite-isl-ast-to-gimple.c: Likewise.
22749         * graphite-optimize-isl.c: Likewise.
22750         * graphite-poly.c: Likewise.
22751         * graphite-sese-to-poly.c: Likewise.
22752         * graphite.h: Likewise.
22753         * toplev.c: Include isl/version.h and use isl_version () for
22754         printing the ISL version.
22755         * doc/install.texi: Update ISL requirement.
22757 2017-02-12  Gerald Pfeifer  <gerald@pfeifer.com>
22759         * doc/standards.texi (Standards): Update reference to
22760         Objective-C 2.0.
22762 2017-02-12  Gerald Pfeifer  <gerald@pfeifer.com>
22764         * doc/extend.texi (Named Address Spaces): sourceware.org now
22765         defaults to https.
22766         * doc/install.texi (Binaries): Ditto.
22767         (Specific): Ditto.
22769 2017-02-11  Sandra Loosemore  <sandra@codesourcery.com>
22771         * doc/cpp.texi: Replace "stringify"/"stringification" with C
22772         standard terminology "stringize"/"stringizing" throughout.
22773         * doc/cppinternals.texi: Likewise.
22775 2017-02-11  Sandra Loosemore  <sandra@codesourcery.com>
22777         * doc/extend.texi: Fix some spelling mistakes and typos.
22778         * doc/invoke.texi: Likewise.
22780 2017-02-11  Jan Hubicka  <hubicka@ucw.cz>
22782         PR ipa/79224
22783         * params.def (inline-min-speedup) Change from 10 to 8.
22785 2017-02-11  Jakub Jelinek  <jakub@redhat.com>
22787         * doc/invoke.texi (fopenmp): Bump OpenMP version from 4.0 to
22788         4.5.
22790 2017-02-11  Jan Hubicka  <hubicka@ucw.cz>
22792         PR ipa/79224
22793         * ipa-inline-analysis.c (get_minimal_bb): New function.
22794         (record_modified): Use it.
22795         (remap_edge_change_prob): Handle also ancestor functions.
22797 2017-02-11  Gerald Pfeifer  <gerald@pfeifer.com>
22799         * doc/contrib.texi (Contributors): Remove broken link into
22800         the Mauve CVS repository.
22802 2017-02-11  Jakub Jelinek  <jakub@redhat.com>
22804         PR middle-end/79454
22805         * internal-fn.c (expand_vector_ubsan_overflow): Use piece-wise
22806         result computation whenever lhs doesn't have vector mode, not
22807         just when it has BLKmode.
22809 2017-02-10  Gerald Pfeifer  <gerald@pfeifer.com>
22811         * doc/makefile.texi (profiledbootstrap): Refer to the
22812         installation instructions only in textual form.
22814 2017-02-10  Aaron Sawdey  <acsawdey@linux.vnet.ibm.com>
22816         PR target/79295
22817         * config/rs6000/altivec.md (bcd<bcd_add_sub>): Fix constraints.
22819 2017-02-10  Gerald Pfeifer  <gerald@pfeifer.com>
22821         * doc/install.texi (Specific): Use https for blackfin.uclinux.org.
22822         (Specific): Update mingw-w64 reference.
22823         (Binaries): Ditto.
22824         (Specific): Remove broken link to Renesas RX processor.
22826 2017-02-10  Richard Biener  <rguenther@suse.de>
22828         * toplev.c (process_options): Do not mention obsolete graphite
22829         options when printing sorry message about missing graphite support.
22830         Mention -floop-nest-optimize.
22832 2017-02-10  Christophe Lyon  <christophe.lyon@linaro.org>
22834         * config/aarch64/arm_neon.h (vtst_p8): Rewrite without asm.
22835         (vtst_p16): Likewise.
22836         (vtstq_p8): Likewise.
22837         (vtstq_p16): Likewise.
22838         (vtst_p64): New.
22839         (vtstq_p64): Likewise.
22840         * config/arm/arm_neon.h (vgetq_lane_p64): New.
22841         (vset_lane_p64): New.
22842         (vsetq_lane_p64): New.
22844 2017-02-10  Jakub Jelinek  <jakub@redhat.com>
22846         PR tree-optimization/79411
22847         * tree-ssa-reassoc.c (is_reassociable_op): Return false if
22848         stmt operands are SSA_NAMEs used in abnormal phis.
22849         (can_reassociate_p): Return false if op is SSA_NAME used in abnormal
22850         phis.
22852 2017-02-09  Jan Hubicka  <hubicka@ucw.cz>
22854         PR ipa/70795
22855         * cgraphunit.c (cgraph_node::add_new_function): Set externally_visible
22856         flag if needed.
22858 2017-02-09  Jan Hubicka  <hubicka@ucw.cz>
22860         * tree-ssa-loop-unswitch.c (hoist_guard): Update profile.
22862 2017-02-09  Jakub Jelinek  <jakub@redhat.com>
22864         * omp-offload.c (oacc_loop_auto_partitions): Use || instead of |
22865         to avoid warning.
22867         PR c/79413
22868         * gimplify.h (is_gimple_sizepos): Only test for INTEGER_CST constants,
22869         not arbitrary TREE_CONSTANT.
22871         PR c/79431
22872         * gimplify.c (gimplify_adjust_omp_clauses): Ignore
22873         "omp declare target link" attribute unless is_global_var.
22874         * omp-offload.c (find_link_var_op): Likewise.
22876 2017-02-09  Nathan Sidwell  <nathan@codesourcery.com>
22877             Chung-Lin Tang  <cltang@codesourcery.com>
22879         * gimplify.c (gimplify_scan_omp_clauses): No special handling for
22880         OMP_CLAUSE_TILE.
22881         (gimplify_adjust_omp_clauses): Don't delete TILE.
22882         (gimplify_omp_for): Deal with TILE.
22883         * internal-fn.c (expand_GOACC_TILE): New function.
22884         * internal-fn.def (GOACC_DIM_POS): Comment may be overly conservative.
22885         (GOACC_TILE): New.
22886         * omp-expand.c (struct oacc_collapse): Add tile and outer fields.
22887         (expand_oacc_collapse_init): Add LOC paramter.  Initialize tile
22888         element fields.
22889         (expand_oacc_collapse_vars): Add INNER parm, adjust for tiling,
22890         avoid DIV for outermost collapse var.
22891         (expand_oacc_for): Insert tile element loop as needed.  Adjust.
22892         Remove out of date comments, fix whitespace.
22893         * omp-general.c (omp_extract_for_data): Deal with tiling.
22894         * omp-general.h (enum oacc_loop_flags): Add OLF_TILE flag,
22895         adjust OLF_DIM_BASE value.
22896         (struct omp_for_data): Add tiling field.
22897         * omp-low.c (scan_sharing_clauses): Allow OMP_CLAUSE_TILE.
22898         (lower_oacc_head_mark): Add OLF_TILE as appropriate.  Ensure 2 levels
22899         for auto loops.  Remove default auto determining, moved to
22900         oacc_loop_fixed_partitions.
22901         * omp-offload.c (struct oacc_loop): Change 'ifns' to vector of call
22902         stmts, add e_mask field.
22903         (oacc_dim_call): New function, abstracted out from oacc_thread_numbers.
22904         (oacc_thread_numbers): Use oacc_dim_call.
22905         (oacc_xform_tile): New.
22906         (new_oacc_loop_raw): Initialize e_mask, adjust for ifns vector.
22907         (finish_oacc_loop): Adjust for ifns vector.
22908         (oacc_loop_discover_walk): Append loop abstraction sites to list,
22909         add case for GOACC_TILE fns.
22910         (oacc_loop_xform_loop): Delete.
22911         (oacc_loop_process): Iterate over call list directly, and add
22912         handling for GOACC_TILE fns.
22913         (oacc_loop_fixed_partitions): Determine default auto, deal with TILE,
22914         dump partitioning.
22915         (oacc_loop_auto_partitions): Add outer_assign parm. Assign all but
22916         vector partitioning to outer loops.  Assign 2 partitions to loops
22917         when available. Add TILE handling.
22918         (oacc_loop_partition): Adjust oacc_loop_auto_partitions call.
22919         (execite_oacc_device_lower): Process GOACC_TILE fns,
22920         ignore unknown specs.
22921         * tree-nested.c (convert_nonlocal_omp_clauses): Allow OMP_CLAUSE_TILE.
22922         * tree.c (omp_clause_num_ops): Adjust TILE ops.
22923         * tree.h (OMP_CLAUSE_TILE_ITERVAR, OMP_CLAUSE_TILE_COUNT): New.
22925 2017-02-09  Gerald Pfeifer  <gerald@pfeifer.com>
22927         * configure.ac (ACX_BUGURL): Update.
22928         * configure: Regenerate.
22930 2017-02-09  Richard Biener  <rguenther@suse.de>
22932         PR tree-optimization/69823
22933         * graphite-scop-detection.c (scop_detection::harmful_loop_in_region):
22934         Properly enumerate all BBs in the region.  Use auto_vec/auto_bitmap.
22936 2017-02-09  Andrew Burgess  <andrew.burgess@embecosm.com>
22938         * config/arc/arc-c.def: Add __NPS400__ definition.
22939         * config/arc/arc.h (CPP_SPEC): Don't define __NPS400__ here.
22940         (TARGET_NPS400): Define.
22942 2017-02-09  Andrew Burgess  <andrew.burgess@embecosm.com>
22944         * config/arc/arc-arch.h (arc_arch_t): Move unchanged to earlier in
22945         file.
22946         (arc_cpu_t): Change base_architecture field, arch, to a arc_arc_t
22947         pointer, arch_info.
22948         (arc_cpu_types): Fill the arch_info field with a pointer into the
22949         arc_arch_types table.
22950         (arc_selected_cpu): Declare.
22951         * config/arc/arc.c (arc_selected_cpu): Make global.
22952         (arc_selected_arch): Delete.
22953         (arc_base_cpu): Delete.
22954         (arc_override_options): Remove references to deleted variables,
22955         update access to arch information.
22956         (ARC_OPT): Update access to arch information.
22957         (ARC_OPTX): Likewise.
22958         * config/arc/arc.h (arc_base_cpu): Remove declaration.
22959         (TARGET_ARC600): Update access to arch information.
22960         (TARGET_ARC601): Likewise.
22961         (TARGET_ARC700): Likewise.
22962         (TARGET_EM): Likewise.
22963         (TARGET_HS): Likewise.
22964         * config/arc/driver-arc.c (arc_cpu_to_as): Update access to arch
22965         information.
22967 2017-02-08  Pat Haugen  <pthaugen@us.ibm.com>
22969         PR target/78604
22970         * config/rs6000/rs6000.c (rs6000_emit_vector_cond_expr): Invert
22971         condition/operands for integer GE/LE/GEU/LEU operations.
22973 2017-02-08  Segher Boessenkool  <segher@kernel.crashing.org>
22975         PR translation/79397
22976         * config/rs6000/rs6000.opt (maltivec=le, maltivec=be): Fix spelling
22977         of AltiVec.
22979 2017-02-08  Martin Jambor  <mjambor@suse.cz>
22981         PR ipa/79375
22982         * ipa-prop.c (ipa_alloc_node_params): Make static, return bool
22983         whether allocation happened.
22984         (ipa_initialize_node_params): Do not call ipa_alloc_node_params if
22985         nothing was allocated.
22987 2017-02-08  Jakub Jelinek  <jakub@redhat.com>
22989         PR tree-optimization/79408
22990         * tree-vrp.c (simplify_div_or_mod_using_ranges): If op1 is not
22991         constant, but SSA_NAME with a known integer range, use the minimum
22992         of that range instead of op1 to determine if modulo can be replaced
22993         with its first operand.
22995 2016-02-08  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
22997         * config/riscv/riscv.c (riscv_build_integer_1): Avoid use of INT16_MAX.
22999 2017-02-08  Richard Biener  <rguenther@suse.de>
23001         PR tree-optimization/71824
23002         * graphite-scop-detection.c (scop_detection::build_scop_breadth):
23003         Check all loops contained in the merged region.
23005 2017-02-07  Andrew Pinski  <apinski@cavium.com>
23007         * config/aarch64/aarch64.md (popcount<mode>2): New pattern.
23009 2017-02-07  Andrew Pinski  <apinski@cavium.com>
23011         * config/aarch64/aarch64-cores.def (thunderx): Disable LSE.
23012         (thunderxt88): Likewise.
23013         (thunderxt81): Disable LSE and change v8.1 to v8.
23014         (thunderxt83): Likewise.
23016 2017-02-07  Jakub Jelinek  <jakub@redhat.com>
23017             Richard Biener  <rguenther@suse.de>
23019         PR middle-end/79399
23020         * ira-int.h (struct target_ira_int): Change x_max_struct_costs_size
23021         type from int to size_t.
23022         * ira-costs.c (struct_costs_size): Change type from int to size_t.
23024 2017-02-07  Jakub Jelinek  <jakub@redhat.com>
23026         PR rtl-optimization/79386
23027         * cprop.c (bypass_conditional_jumps): Initialize
23028         bypass_last_basic_block already before splitting bbs after
23029         unconditional traps...
23030         (bypass_conditional_jumps): ... rather than here.
23032         PR target/79299
23033         * config/i386/sse.md (xtg_mode, gatherq_mode): New mode attrs.
23034         (*avx512f_gathersi<mode>, *avx512f_gathersi<mode>_2,
23035         *avx512f_gatherdi<mode>, *avx512f_gatherdi<mode>_2): Use them,
23036         fix -masm=intel patterns.
23038 2017-02-07  Richard Biener  <rguenther@suse.de>
23040         PR tree-optimization/79256
23041         PR middle-end/79278
23042         * builtins.c (get_object_alignment_2): Use min_align_of_type
23043         to extract alignment for MEM_REFs to honor BIGGEST_FIELD_ALIGNMENT
23044         and ADJUST_FIELD_ALIGN.
23046         * doc/tm.texi.in (ADJUST_FIELD_ALIGN): Adjust to take additional
23047         type parameter.
23048         * doc/tm.texi: Regenerate.
23049         * stor-layout.c (layout_decl): Adjust.
23050         (update_alignment_for_field): Likewise.
23051         (place_field): Likewise.
23052         (min_align_of_type): Likewise.
23053         * config/arc/arc.h (ADJUST_FIELD_ALIGN): Adjust.
23054         * config/epiphany/epiphany.h (ADJUST_FIELD_ALIGN): Likewise.
23055         * config/epiphany/epiphany.c (epiphany_adjust_field_align): Likewise.
23056         * config/frv/frv.h (ADJUST_FIELD_ALIGN): Likewise.
23057         * config/frv/frv.c (frv_adjust_field_align): Likewise.
23058         * config/i386/i386.h (ADJUST_FIELD_ALIGN): Likewise.
23059         * config/i386/i386.c (x86_field_alignment): Likewise.
23060         * config/rs6000/aix.h (ADJUST_FIELD_ALIGN): Likewise.
23061         * config/rs6000/darwin.h (ADJUST_FIELD_ALIGN): Likewise.
23062         * config/rs6000/freebsd64.h (ADJUST_FIELD_ALIGN): Likewise.
23063         * config/rs6000/linux64.h (ADJUST_FIELD_ALIGN): Likewise.
23064         * config/rs6000/sysv4.h (ADJUST_FIELD_ALIGN): Likewise.
23065         * config/rs6000/rs6000.c (rs6000_special_adjust_field_align_p):
23066          Likewise.
23068         Revert
23069         2017-01-30  Richard Biener  <rguenther@suse.de>
23071         PR tree-optimization/79256
23072         * targhooks.c (default_builtin_vector_alignment_reachable): Honor
23073         BIGGEST_FIELD_ALIGNMENT and ADJUST_FIELD_ALIGN to fix up bogus
23074         alignment on TYPE.
23076 2017-02-07  Toma Tabacu  <toma.tabacu@imgtec.com>
23078         * config/mips/mips.c (mips_expand_builtin_insn): Convert the QImode
23079         argument of the pshufh, psllh, psllw, psrah, psraw, psrlh, psrlw
23080         builtins to SImode and emit a zero-extend, if necessary.
23082 2017-02-06  Palmer Dabbelt  <palmer@dabbelt.com>
23084         * docs/invoke.texi (RISC-V Options): Alphabetize.
23086 2017-02-06  Palmer Dabbelt  <palmer@dabbelt.com>
23088         * doc/invoke.texi (RISC-V Options): Use two spaces to separate
23089         options.
23091 2017-02-06  Palmer Dabbelt  <palmer@dabbelt.com>
23093         * config/riscv/riscv.c: New file.
23094         * common/config/riscv/riscv-common.c: Likewise.
23095         * config.gcc: Likewise.
23096         * config/riscv/constraints.md: Likewise.
23097         * config/riscv/elf.h: Likewise.
23098         * config/riscv/generic.md: Likewise.
23099         * config/riscv/linux.h: Likewise.
23100         * config/riscv/multilib-generator: Likewise.
23101         * config/riscv/peephole.md: Likewise.
23102         * config/riscv/pic.md: Likewise.
23103         * config/riscv/predicates.md: Likewise.
23104         * config/riscv/riscv-builtins.c: Likewise.
23105         * config/riscv/riscv-c.c: Likewise.
23106         * config/riscv/riscv-ftypes.def: Likewise.
23107         * config/riscv/riscv-modes.def: Likewise.
23108         * config/riscv/riscv-opts.h: Likewise.
23109         * config/riscv/riscv-protos.h: Likewise.
23110         * config/riscv/riscv.h: Likewise.
23111         * config/riscv/riscv.md: Likewise.
23112         * config/riscv/riscv.opt: Likewise.
23113         * config/riscv/sync.md: Likewise.
23114         * config/riscv/t-elf-multilib: Likewise.
23115         * config/riscv/t-linux: Likewise.
23116         * config/riscv/t-linux-multilib: Likewise.
23117         * config/riscv/t-riscv: Likewise.
23118         * configure.ac: Likewise.
23119         * doc/contrib.texi: Add Kito Cheng, Palmer Dabbelt, and Andrew
23120         Waterman as RISC-V maintainers.
23121         * doc/install.texi: Add RISC-V entries.
23122         * doc/invoke.texi: Add RISC-V options section.
23123         * doc/md.texi: Add RISC-V constraints section.
23124         * configure: Regenerated.
23126 2017-02-06  Michael Meissner  <meissner@linux.vnet.ibm.com>
23128         PR target/66144
23129         * config/rs6000/vector.md (vcond<mode><mode>): Allow the true and
23130         false values to be constant vectors with all 0 or all 1 bits set.
23131         (vcondu<mode><mode>): Likewise.
23132         * config/rs6000/predicates.md (vector_int_reg_or_same_bit): New
23133         predicate.
23134         (fpmask_comparison_operator): Update comment.
23135         (vecint_comparison_operator): New predicate.
23136         * config/rs6000/rs6000.c (rs6000_emit_vector_cond_expr): Optimize
23137         vector conditionals when the true and false values are constant
23138         vectors with all 0 bits or all 1 bits set.
23140 2017-02-06  Martin Sebor  <msebor@redhat.com>
23142         PR  tree-optimization/79376
23143         * gimple-fold.c (get_range_strlen): Set the minimum length to zero.
23145 2017-02-06  Uros Bizjak  <ubizjak@gmail.com>
23147         * config/i386/sse.md (vector modes -> vec_extract* splitter): Use
23148         explicit subreg RTX with operand 1.  Use VECTOR_MODE_P predicate
23149         to simplify split condition.
23151 2017-02-06  Jakub Jelinek  <jakub@redhat.com>
23153         * omp-expand.c (oxpand_omp_atomic_fetch_op,
23154         expand_omp_atomic_pipeline): Return false if can_atomic_load_p is
23155         false.
23157 2017-02-06  Segher Boessenkool  <segher@kernel.crashing.org>
23159         PR rtl-optimization/68664
23160         * target.def (can_speculate_insn): New hook.
23161         * doc/tm.texi.in (TARGET_SCHED_CAN_SPECULATE_INSN): New hook.
23162         * doc/tm.texi: Regenerate.
23163         * sched-rgn.c (can_schedule_ready_p): Use the new hook.
23164         * config/rs6000/rs6000.c (TARGET_SCHED_CAN_SPECULATE_INSN): New macro.
23165         (rs6000_sched_can_speculate_insn): New function.
23167 2017-02-06  Jakub Jelinek  <jakub@redhat.com>
23169         PR tree-optimization/79284
23170         * tree-vectorizer.h (VECT_SCALAR_BOOLEAN_TYPE_P): Define.
23171         * tree-vect-stmts.c (vect_get_vec_def_for_operand,
23172         vectorizable_mask_load_store, vectorizable_operation,
23173         vect_is_simple_cond, get_same_sized_vectype): Use it instead
23174         of comparing TREE_CODE of a type against BOOLEAN_TYPE.
23175         * tree-vect-patterns.c (check_bool_pattern, search_type_for_mask_1,
23176         vect_recog_bool_pattern, vect_recog_mask_conversion_pattern): Likewise.
23177         * tree-vect-slp.c (vect_get_constant_vectors): Likewise.
23178         * tree-vect-loop.c (vect_determine_vectorization_factor): Likewise.
23179         Remove redundant gimple_code (stmt) == GIMPLE_ASSIGN test after
23180         is_gimple_assign (stmt).  Replace another such test with
23181         is_gimple_assign (stmt).
23183 2017-02-06  Georg-Johann Lay  <avr@gjlay.de>
23185         PR target/78883
23186         * config/avr/avr.c (rtl-iter.h): Include it.
23187         (TARGET_LEGITIMATE_COMBINED_INSN): New hook define...
23188         (avr_legitimate_combined_insn): ...and implementation.
23190 2017-02-06  Dominik Vogt  <vogt@linux.vnet.ibm.com>
23192         * config/s390/predicates.md ("larl_operand"): Use macros from hwint.h.
23193         * config/s390/s390.c (s390_const_operand_ok)
23194         (s390_canonicalize_comparison, s390_extract_part)
23195         (s390_single_part, s390_contiguous_bitmask_nowrap_p)
23196         (s390_contiguous_bitmask_p, s390_rtx_costs)
23197         (legitimize_pic_address): Likewise.
23198         * config/s390/s390.md ("clzdi2", "clztidi2"): Likewise.
23199         * config/s390/vx-builtins.md ("vec_genbytemaskv16qi")
23200         ("vec_permi<mode>", "vfae<mode>", "*vfaes<mode>", "vstrc<mode>")
23201         ("*vstrcs<mode>"): Use UINTVAL() to set unsigned HOST_WIDE_INT.
23202         * config/s390/vector.md ("vec_vfenes<mode>"): Likewise.
23204 2017-02-06  Georg-Johann Lay  <avr@gjlay.de>
23206         * config/avr/avr.md (*addhi3_zero_extend): Add alternative where
23207         REGNO($0) == REGNO($1).
23209 2017-02-06  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
23211         * config/s390/linux.h(SIZE_TYPE): Add comment.
23213 2017-02-06  Julian Brown  <julian@codesourcery.com>
23214             Naveen H.S  <Naveen.Hurugalawadi@cavium.com>
23215             Virendra Pathak  <virendra.pathak@broadcom.com>
23217         * config/aarch64/aarch64-cores.def: Change the scheduler
23218         to Thunderx2t99.
23219         * config/aarch64/aarch64.md: Include thunderx2t99.md.
23220         * config/aarch64/thunderx2t99.md: New file.
23222 2017-02-05  Gerald Pfeifer  <gerald@pfeifer.com>
23224         * doc/standards.texi (Go Language): Update link to language
23225         standard.
23227 2017-02-05  Jan Hubicka  <hubicka@ucw.cz>
23229         * tree-eh.c (lower_resx): Sanitize profile.
23230         (cleanup_empty_eh_move_lp): Likewise.
23232 2017-02-05  Jan Hubicka  <hubicka@ucw.cz>
23234         PR tree-ssa/79347
23235         * cfgloopmanip.c (lv_adjust_loop_entry_edge, loop_version): Add
23236         ELSE_PROB.
23237         * cfgloopmanip.h (loop_version): Update prototype.
23238         * modulo-sched.c (sms_schedule): Update call of loop_version.
23239         * tree-if-conv.c(version_loop_for_if_conversion): Likewise.
23240         * tree-parloops.c (gen_parallel_loop): Likewise.
23241         * tree-ssa-loop-manip.c (tree_transform_and_unroll_loop): Likewise.
23242         * tree-ssa-loop-split.c (split_loop): Likewise.
23243         * tree-ssa-loop-unswitch.c (tree_unswitch_loop): Likewise.
23244         * tree-vect-loop-manip.c (vect_loop_versioning): Likewise.
23246 2017-02-05  Martin Liska  <mliska@suse.cz>
23248         PR bootstrap/78985
23249         * config/s390/s390.c (s390_gimplify_va_arg): Initialize local
23250         variable to NULL.
23251         (print_operand_address): Initialize a struct to zero.
23253 2017-02-05  Gerald Pfeifer  <gerald@pfeifer.com>
23255         * doc/contrib.texi (Contributors): Refer to Hans Boehm's
23256         garbage collector only in textual form.
23258 2017-02-05  Gerald Pfeifer  <gerald@pfeifer.com>
23260         * doc/extend.texi (x86 specific memory model extensions for
23261         transactional memory): Simplify a phrase.
23263 2017-02-05  Eric Botcazou  <ebotcazou@adacore.com>
23265         PR target/79353
23266         * config/sparc/sync.md (atomic_loaddi_1): Replace 'U' constraint with
23267         'r', 'm' constraint with 'T' and !TARGET_ARCH64 with TARGET_ARCH32.
23268         (atomic_storedi_1): Likewise.
23270 2017-02-04  Jakub Jelinek  <jakub@redhat.com>
23272         PR tree-optimization/79338
23273         * tree-parloops.c (gather_scalar_reductions): Don't call
23274         vect_analyze_loop_form for loop->inner before destroying loop's
23275         loop_vinfo.
23277 2017-02-03  Martin Sebor  <msebor@redhat.com>
23279         PR tree-optimization/79327
23280         * gimple-ssa-sprintf.c (tree_digits): Avoid adding the base prefix
23281         when precision has resulted in leading zeros.
23282         (format_integer): Adjust the likely counter to assume an unknown
23283         argument that may be zero is non-zero.
23285 2017-02-03  Jason Merrill  <jason@redhat.com>
23287         PR c++/78689
23288         * tree-inline.c (copy_tree_body_r) [COND_EXPR]: Revert change to
23289         avoid copying non-taken branch.
23291 2017-02-03  Jakub Jelinek  <jakub@redhat.com>
23293         PR tree-optimization/79340
23294         * tree-vect-loop.c (vectorizable_reduction): Release
23295         vec_defs elements after safe_splicing them into other vectors.
23296         Formatting fixes.
23298         PR tree-optimization/79327
23299         * gimple-ssa-sprintf.c (adjust_range_for_overflow): If returning
23300         true, always set *argmin and *argmax to TYPE_{MIN,MAX}_VALUE of
23301         dirtype.
23302         (format_integer): Use wide_int_to_tree instead of build_int_cst
23303         + to_?hwi.  If argmin is NULL, just set argmin and argmax to
23304         TYPE_{MIN,MAX}_VALUE of argtype.  Simplify and fix computation
23305         of shortest and longest sequence.
23307 2017-02-03  Uros Bizjak  <ubizjak@gmail.com>
23309         * config/i386/i386.c (dimode_scalar_chain::convert_reg):
23310         Use pextrd for TARGET_SSE4_1 when creating scalar copy.
23312 2017-02-03  Walter Lee  <walt@tilera.com>
23314         PR target/78862
23315         * config/tilegx/tilegx.md (tilegx_expand_prologue): Add blockage
23316         after initial stackframe link reg save.
23317         * config/tilepro/tilepro.md (tilepro_expand_prologue): Likewise.
23319 2017-02-03  Jakub Jelinek  <jakub@redhat.com>
23321         PR target/79354
23322         * config/rs6000/rs6000.md (movsi_from_sf): Use wb constraint instead of
23323         wu for stxssp alternative.
23325 2017-02-03  Martin Sebor  <msebor@redhat.com>
23327         PR tree-optimization/79352
23328         * gimple-fold.c (get_range_strlen): Add argument.
23329         (get_range_strlen): Change return type to bool.
23330         (get_maxval_strlen): Pass in a dummy argument.
23331         * gimple-fold.h (get_range_strlen): Change return type to bool.
23332         * gimple-ssa-sprintf.c (get_string_length): Set unlikely counter.
23333         * tree.h (array_at_struct_end_p): Add argument.
23334         * tree.c (array_at_struct_end_p): Handle it.
23336 2017-02-03  Martin Liska  <mliska@suse.cz>
23338         PR lto/66295
23339         * multiple_target.c (create_dispatcher_calls): Redirect edge
23340         from a caller of a dispatcher.
23341         (expand_target_clones): Make the clones local.
23342         (ipa_target_clone): Do both target clones and resolvers.
23343         (ipa_dispatcher_calls): Remove the pass.
23344         (pass_dispatcher_calls::gate): Likewise.
23345         (make_pass_dispatcher_calls): Likewise.
23346         * passes.def (pass_target_clone): Put as very first IPA early
23347         pass.
23349 2017-02-03  Martin Liska  <mliska@suse.cz>
23351         * symtab.c (symtab_node::binds_to_current_def_p): Bail out
23352         in case of a function with ifunc attribute.
23354 2017-02-03  Martin Liska  <mliska@suse.cz>
23356         * cgraph.c (cgraph_node::dump): Dump function version info.
23357         * symtab.c (symtab_node::dump_base): Add missing new line.
23359 2017-02-02  Jan Hubicka  <hubicka@ucw.cz>
23361         * tree-ssa-ifcombine.c (update_profile_after_ifcombine): New function.
23362         (ifcombine_ifandif): Use it.
23364 2017-02-03  Martin Liska  <mliska@suse.cz>
23366         * doc/invoke.texi: Document default value for
23367         use-after-scope-direct-emission-threshold.
23369 2017-02-03  Martin Liska  <mliska@suse.cz>
23371         PR tree-optimization/79339
23372         * gimple-ssa-sprintf.c (format_floating_max): Call mpfr_clear.
23373         (format_floating): Likewise.
23375 2017-02-03  Martin Liska  <mliska@suse.cz>
23377         PR ipa/79337
23378         * ipa-prop.c (ipa_node_params_t::insert): Remove current
23379         implementation.
23380         (ipa_node_params_t::remove): Likewise.
23381         * ipa-prop.h (ipa_node_params::ipa_node_params): Make default
23382         initialization from removed ipa_node_params_t::insert.
23383         (ipa_node_params::~ipa_node_params): Move from removed
23384         ipa_node_params_t::release.
23385         * symbol-summary.h (symbol_summary::m_released): New member.
23386         Do not release a summary twice.  Do not allow to call finalizer
23387         for types of a summary that live in GGC memory.
23389 2017-02-02  Naveen H.S  <Naveen.Hurugalawadi@cavium.com>
23391         * config/aarch64/aarch64.c (thunderx2t99_tunings): Enable AES and
23392         cmp_branch fusion.
23394 2017-02-02  Martin Sebor  <msebor@redhat.com>
23396         PR middle-end/79275
23397         * gimple-ssa-sprintf.c (get_string_length): Set lower bound to zero.
23398         (format_string): Tighten up the range of output for non-constant
23399         strings and correct the expected range for wide non-constant strings.
23401 2017-02-02  Martin Sebor  <msebor@redhat.com>
23403         * doc/invoke.texi (-maccumulate-args): Fix bad grammar.
23405         PR middle-end/32003
23406         * doc/invoke.texi (-fdump-tree-): Remove pass-specific options from
23407         index.
23408         (-fdump-tree-@var): Add to index and document how to come up
23409         with pass-specific option and dump file names.
23410         (-fdump-passes): Clarify where to look for output.
23412 2017-02-02  Jan Hubicka  <hubicka@ucw.cz>
23414         PR middle-end/77445
23415         * tree-ssa-threadbackward.c (profitable_jump_thread_path): Dump
23416         statistics of the analyzed path; allow threading for speed when
23417         any of BBs along the path are optimized for speed.
23419 2017-02-02  Eric Botcazou  <ebotcazou@adacore.com>
23421         PR middle-end/78468
23422         * emit-rtl.c (init_emit): Add ??? comment for problematic alignment
23423         settings of the virtual registers.
23425         Revert again
23426         2016-08-23  Dominik Vogt  <vogt@linux.vnet.ibm.com>
23428         * explow.c (get_dynamic_stack_size): Take known alignment of stack
23429         pointer + STACK_DYNAMIC_OFFSET into account when calculating the size
23430         needed.
23432 2017-02-02  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
23434         * config/s390/vx-builtins.md ("vec_ceil", "vec_floor")
23435         ("vec_trunc", "vec_roundc", "vec_round"): Remove expanders.
23437 2017-02-02  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
23439         * config/s390/s390.md: Add missing comments with the expanded
23440         mnemonics.
23441         * config/s390/vector.md: Likewise.
23442         * config/s390/vx-builtins.md: Likewise.
23444 2017-02-02  Jakub Jelinek  <jakub@redhat.com>
23446         PR target/79197
23447         * config/rs6000/rs6000.md (*fixuns_trunc<mode>di2_fctiduz): Rename to ...
23448         (fixuns_trunc<mode>di2): ... this, remove previous expander.  Put all
23449         conditions on a single line.
23451 2017-02-02  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
23453         * config/s390/s390-c.c (s390_cpu_cpp_builtins_internal): Rename
23454         __S390_VX__ to __VX__.
23456 2017-02-01  Andrew Pinski  <apinski@cavium.com>
23458         * tree-vect-loop.c (vect_compute_single_scalar_iteration_cost): Pass
23459         stmt_info to record_stmt_cost.
23460         (vect_get_known_peeling_cost): Pass stmt_info if known to
23461         record_stmt_cost.
23462         * config/aarch64/aarch64-protos.h (cpu_vector_cost): Split
23463         cpu_vector_cost field into
23464         scalar_int_stmt_cost and scalar_fp_stmt_cost.  Split vec_stmt_cost
23465         field into vec_int_stmt_cost and vec_fp_stmt_cost.
23466         * config/aarch64/aarch64.c (generic_vector_cost): Update for the
23467         splitting of scalar_stmt_cost and vec_stmt_cost.
23468         (thunderx_vector_cost): Likewise.
23469         (cortexa57_vector_cost): LIkewise.
23470         (exynosm1_vector_cost): Likewise.
23471         (xgene1_vector_cost): Likewise.
23472         (thunderx2t99_vector_cost): Improve after the splitting of the two
23473         fields.
23474         (aarch64_builtin_vectorization_cost): Update for the splitting of
23475         scalar_stmt_cost and vec_stmt_cost.
23477 2017-02-01  Torvald Riegel  <triegel@redhat.com>
23478             Richard Henderson  <rth@redhat.com>
23480         * builtins.c (fold_builtin_atomic_always_lock_free): Make "lock-free"
23481         conditional on existance of a fast atomic load.
23482         * optabs-query.c (can_atomic_load_p): New function.
23483         * optabs-query.h (can_atomic_load_p): Declare it.
23484         * optabs.c (expand_atomic_exchange): Always delegate to libatomic if
23485         no fast atomic load is available for the particular size of access.
23486         (expand_atomic_compare_and_swap): Likewise.
23487         (expand_atomic_load): Likewise.
23488         (expand_atomic_store): Likewise.
23489         (expand_atomic_fetch_op): Likewise.
23490         * testsuite/lib/target-supports.exp
23491         (check_effective_target_sync_int_128): Remove x86 because it provides
23492         no fast atomic load.
23493         (check_effective_target_sync_int_128_runtime): Likewise.
23495 2017-02-01  Richard Biener  <rguenther@suse.de>
23497         * graphite.c: Include tree-vectorizer.h for find_loop_location.
23498         (graphite_transform_loops): Provide opt-info for optimized nests.
23499         * tree-parloop.c (parallelize_loops): Provide opt-info for
23500         parallelized loops.
23502 2017-02-01  Richard Biener  <rguenther@suse.de>
23504         PR middle-end/79315
23505         * tree-cfg.c (move_stmt_op): Never set TREE_BLOCK when it
23506         was not set before.
23508 2017-02-01  Richard Biener  <rguenther@suse.de>
23510         PR tree-optimization/71824
23511         * graphite-scop-detection.c (scop_detection::build_scop_breadth):
23512         Verify the loops are valid in the merged SESE region.
23513         (scop_detection::can_represent_loop_1): Check analyzing the
23514         evolution of the number of iterations in the region succeeds.
23516 2017-01-31  Ian Lance Taylor  <iant@golang.org>
23518         * config/i386/i386.c (ix86_expand_split_stack_prologue): Add
23519         REG_ARGS_SIZE note to 32-bit push insns and call insn.
23521 2017-01-31  David Malcolm  <dmalcolm@redhat.com>
23523         PR preprocessor/79210
23524         * input.c (get_substring_ranges_for_loc): Replace line_width
23525         assertion with error-handling.
23527 2017-01-31  Richard Biener  <rguenther@suse.de>
23529         PR tree-optimization/77318
23530         * graphite-sese-to-poly.c (extract_affine): Fix assert.
23531         (create_pw_aff_from_tree): Take loop parameter.
23532         (add_condition_to_pbb): Pass loop of the condition to
23533         create_pw_aff_from_tree.
23535 2017-01-31  Jakub Jelinek  <jakub@redhat.com>
23537         * config/s390/s390.c (s390_asan_shadow_offset): New function.
23538         (TARGET_ASAN_SHADOW_OFFSET): Redefine.
23540 2017-01-31  Michael Meissner  <meissner@linux.vnet.ibm.com>
23542         PR target/78597
23543         PR target/79038
23544         * config/rs6000/rs6000-protos.h (convert_float128_to_int): Delete,
23545         no longer used.
23546         (convert_int_to_float128): Likewise.
23547         * config/rs6000/rs6000.c (convert_float128_to_int): Likewise.
23548         (convert_int_to_float128): Likewise.
23549         * config/rs6000/rs6000.md (UNSPEC_IEEE128_MOVE): Likewise.
23550         (UNSPEC_IEEE128_CONVERT): Likewise.
23551         (floatsi<mode>2, FLOAT128 iterator): Bypass calling
23552         rs6000_expand_float128_convert if we have IEEE 128-bit hardware.
23553         Use local variables for IBM extended format.
23554         (fix_trunc<mode>si2, FLOAT128 iterator): Likewise.
23555         (fix_trunc<mode>si2_fprs): Likewise.
23556         (fixuns_trunc<IEEE128:mode><SDI:mode>2): Likewise.
23557         (floatuns<IEEE128:mode>2, IEEE128 iterator): Likewise.
23558         (fix<uns>_<mode>si2_hw): Rework the IEEE 128-bt hardware support
23559         to know that we can now have integers of all sizes in vector
23560         registers.
23561         (fix<uns>_<mode>di2_hw): Likewise.
23562         (float<uns>_<mode>si2_hw): Likewise.
23563         (fix_<mode>si2_hw): Likewise.
23564         (fixuns_<mode>si2_hw): Likewise.
23565         (float<uns>_<mode>di2_hw): Likewise.
23566         (float_<mode>di2_hw): Likewise.
23567         (float_<mode>si2_hw): Likewise.
23568         (floatuns_<mode>di2_hw): Likewise.
23569         (floatuns_<mode>si2_hw): Likewise.
23570         (xscvqp<su>wz_<mode>): Delete, no longer used.
23571         (xscvqp<su>dz_<mode>): Likewise.
23572         (xscv<su>dqp_<mode>): Likewise.
23573         (ieee128_mfvsrd_64bit): Likewise.
23574         (ieee128_mfvsrd_32bit): Likewise.
23575         (ieee128_mfvsrwz): Likewise.
23576         (ieee128_mtvsrw): Likewise.
23577         (ieee128_mtvsrd_64bit): Likewise.
23578         (ieee128_mtvsrd_32bit): Likewise.
23580 2017-01-31  Martin Liska  <mliska@suse.cz>
23582         PR ipa/79285
23583         * ipa-prop.c (ipa_free_all_node_params): Call release method
23584         instead of ~sumbol_summary to not to trigger double times
23585         dtor of hash_map.
23587 2017-01-31  Aldy Hernandez  <aldyh@redhat.com>
23589         PR tree-optimization/71691
23590         * bitmap.h (class auto_bitmap): New.
23591         * tree-ssa-loop-unswitch.c (tree_may_unswitch_on): Call
23592         is_maybe_undefined instead of ssa_undefined_value_p.
23594 2017-01-31  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
23596         * config/s390/s390-c.c (s390_cpu_cpp_builtins_internal): Rename
23597         __S390_ARCH_LEVEL__ to __ARCH__.
23599 2017-01-31  Jakub Jelinek  <jakub@redhat.com>
23601         PR tree-optimization/79267
23602         * value-prof.c (gimple_ic): Only drop lhs for noreturn calls
23603         if should_remove_lhs_p is true.
23605 2017-01-30  Alexandre Oliva <aoliva@redhat.com>
23607         PR debug/63238
23608         * dwarf2out.c (clone_as_declaration): Drop DW_AT_alignment.
23609         (add_alignment_attribute): New.
23610         (base_type_die): Add alignment attribute.
23611         (subrange_type_die): Likewise.
23612         (modified_type_die): Likewise.
23613         (gen_array_type_die): Likewise.
23614         (gen_descr_array_type_die: Likewise.
23615         (gen_enumeration_type_die): Likewise.
23616         (gen_subprogram_die): Likewise.
23617         (gen_variable_die): Likewise.
23618         (gen_field_die): Likewise.
23619         (gen_ptr_to_mbr_type_die): Likewise.
23620         (gen_struct_or_union_type_die): Likewise.
23621         (gen_subroutine_type_die): Likewise.
23622         (gen_typedef_die): Likewise.
23623         (base_type_cmp): Compare alignment attribute.
23625 2017-01-30  Aaron Sawdey  <acsawdey@linux.vnet.ibm.com>
23627         PR target/79170
23628         * config/rs6000/altivec.md (*setb_internal): Rename to setb_signed.
23629         (setb_unsigned) New pattern for setb with CCUNS.
23630         * config/rs6000/rs6000.c (expand_block_compare): Use a different
23631         subfc./subfe sequence to avoid overflow problems.  Generate a
23632         shorter sequence with cmpld/setb for power9.
23633         * config/rs6000/rs6000.md (subf<mode>3_carry_dot2): Add a new pattern
23634         for generating subfc. instruction.
23635         (cmpstrsi): Add TARGET_POPCNTD predicate as the generate sequence
23636         now uses this instruction.
23638 2017-01-30  Ian Lance Taylor  <iant@google.com>
23640         PR debug/79289
23641         * dwarf2out.c (gen_type_die_with_usage): When picking a variant
23642         for FUNCTION_TYPE/METHOD_TYPE, use the first matching one.
23644 2017-01-30  Martin Sebor  <msebor@redhat.com>
23646         * gimple-ssa-sprintf.c (fmtresult::adjust_for_width_or_precision):
23647         Move constant to the right of a relational operator.
23648         (get_mpfr_format_length, format_character, format_string): Ditto.
23649         (should_warn_p, maybe_warn): Same.
23651         * doc/invoke.texi (-Wformat-truncation=1): Fix typo.
23653 2017-01-30  Maxim Ostapenko  <m.ostapenko@samsung.com>
23655         PR lto/79061
23656         * asan.c (get_translation_unit_decl): Remove function.
23657         (asan_add_global): Force has_dynamic_init to zero in LTO mode.
23659 2017-01-30  Martin Liska  <mliska@suse.cz>
23661         PR gcov-profile/79259
23662         * opts.c (common_handle_option): Enable flag_ipa_bit_cp w/
23663         -fprofile-generate.
23665 2017-01-30  Martin Liska  <mliska@suse.cz>
23667         PR bootstrap/78985
23668         * config/aarch64/cortex-a57-fma-steering.c (func_fma_steering::analyze):
23669         Initialize variables with NULL value.
23671 2017-01-30  Richard Earnshaw  <rearnsh@arm.com>
23673         PR target/79260
23674         * config.gcc (arm*-*-*): Add arm/arm-flags.h and arm/arm-isa.h to
23675         tm_p_file.
23676         * arm/arm-protos.h: Don't directly include arm-flags.h and arm-isa.h.
23678 2017-01-30  Richard Biener  <rguenther@suse.de>
23680         PR tree-optimization/79276
23681         * tree-vrp.c (process_assert_insertions): Properly adjust common
23682         when removing a duplicate.
23684         * gcc.dg/torture/pr79276.c: New testcase.
23686 2017-01-30  Richard Biener  <rguenther@suse.de>
23688         PR tree-optimization/79256
23689         * targhooks.c (default_builtin_vector_alignment_reachable): Honor
23690         BIGGEST_FIELD_ALIGNMENT and ADJUST_FIELD_ALIGN to fix up bogus
23691         alignment on TYPE.
23692         * tree.c (build_aligned_type): Set TYPE_USER_ALIGN.
23694 2017-01-30  Dominik Vogt  <vogt@linux.vnet.ibm.com>
23696         PR target/79240
23697         * config/s390/s390.md ("*r<noxa>sbg_<mode>_srl_bitmask")
23698         ("*r<noxa>sbg_<mode>_sll_bitmask")
23699         ("*extzv_<mode>_srl<clobbercc_or_nocc>")
23700         ("*extzv_<mode>_sll<clobbercc_or_nocc>"):
23701         Use contiguous_bitmask_nowrap_operand.
23703 2017-01-29  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
23705         PR target/79268
23706         * config/rs6000/altivec.h (vec_xl): Revise #define.
23707         (vec_xst): Likewise.
23709 2017-01-27  Uros Bizjak  <ubizjak@gmail.com>
23711         * config/i386/i386.c (print_reg): Use REGNO instead of true_regnum.
23713 2017-01-27  Bernd Schmidt  <bschmidt@redhat.com>
23715         PR rtl-optimization/79194
23716         * cprop.c (one_cprop_pass): Move deletion of code after unconditional
23717         traps before call to bypass_conditional_jumps.
23719 2017-01-27  Vladimir Makarov  <vmakarov@redhat.com>
23721         PR tree-optimization/71374
23722         * lra-constraints.c (check_conflict_input_operands): New.
23723         (match_reload): Use it.
23725 2017-01-27  Vladimir Makarov  <vmakarov@redhat.com>
23727         PR target/79131
23728         * lra-assigns.c (find_hard_regno_for_1): Take endianess for into
23729         account to calculate conflict_set.
23731 2017-01-27  Bin Cheng  <bin.cheng@arm.com>
23733         PR rtl-optimization/78559
23734         * combine.c (try_combine): Discard REG_EQUAL and REG_EQUIV for
23735         other_insn in combine.
23737 2017-01-27  Pekka Jääskeläinen  <pekka.jaaskelainen@parmance.com>
23739         * builtin-types.def: Use unsigned_char_type_node for BT_UINT8.  Use
23740         uint16_type_node for BT_UINT16.
23742 2017-01-27  David Malcolm  <dmalcolm@redhat.com>
23744         * doc/sourcebuild.texi (Testsuites): Add "GIMPLE Tests" and
23745         "RTL Tests" to menu.
23746         (GIMPLE Tests): New node.
23747         (RTL Tests): New node.
23749 2017-01-27  Richard Biener  <rguenther@suse.de>
23751         PR tree-optimization/79245
23752         * tree-loop-distribution.c (distribute_loop): Apply cost
23753         modeling also to detected patterns.
23755 2017-01-27  Richard Biener  <rguenther@suse.de>
23757         PR tree-optimization/71433
23758         * tree-vrp.c (register_new_assert_for): Revert earlier changes.
23759         (compare_assert_loc): New function.
23760         (process_assert_insertions): Sort and optimize assert locations
23761         to remove duplicates and push down identical assertions on
23762         edges to their destination block.
23764 2017-01-27  Richard Biener  <rguenther@suse.de>
23766         PR tree-optimization/79244
23767         * tree-vrp.c (remove_range_assertions): Forcefully propagate
23768         out SSA names even if abnormal.
23770 2017-01-27  Jakub Jelinek  <jakub@redhat.com>
23772         * realmpfr.h: Poison MPFR_RND{N,Z,U,D}.
23773         * gimple-ssa-sprintf.c (format_floating_max): Use GMP_RNDN
23774         instead of MPFR_RNDN.
23776 2017-01-27  Richard Earnshaw  <rearnsha@arm.com>
23778         PR target/79239
23779         * arm.c (arm_option_override): Don't call build_target_option_node
23780         until after doing all option overrides.
23781         (arm_valid_target_attribute_tree): Likewise.
23783 2017-01-27  Martin Liska  <mliska@suse.cz>
23785         * doc/invoke.texi (-fprofile-arcs): Document profiling support
23786         for {cd}tors and C++ {cd}tors.
23788 2017-01-27  Dominik Vogt  <vogt@linux.vnet.ibm.com>
23790         * config/s390/s390.md ("*setmem_long_and")
23791         ("*setmem_long_and_31z"): Use zero_extend instead of and.
23793 2017-01-26  Martin Sebor  <msebor@redhat.com>
23795         * gimple-ssa-sprintf.c (format_floating): Simplify the computation
23796         of precision.
23798 2017-01-26  Martin Sebor  <msebor@redhat.com>
23800         * gimple-ssa-sprintf.c (format_floating): Test HAVE_XFmode and
23801         HAVE_DFmode before using XFmode or DFmode.
23802         (parse_directive): Avoid using the z length modifier to avoid
23803         the ISO C++98 does not support the â€˜z’ gnu_printf length modifier.
23805         PR middle-end/78703
23806         * gimple-ssa-sprintf.c (adjust_for_width_or_precision): Change
23807         to accept adjustment as an array.
23808         (get_int_range): New function.
23809         (struct directive): Make width and prec arrays.
23810         (directive::set_width, directive::set_precision): Call get_int_range.
23811         (format_integer, format_floating): Handle width and precision ranges.
23812         (format_string, parse_directive): Same.
23814 2017-01-26  Jakub Jelinek  <jakub@redhat.com>
23816         PR debug/79129
23817         * dwarf2out.c (generate_skeleton_bottom_up): For children with
23818         comdat_type_p set, just clone them, but keep the children in the
23819         original DIE.
23821         PR debug/78835
23822         * dwarf2out.c (prune_unused_types): Mark all functions with DIEs
23823         which have direct callers with -fvar-tracking-assignments enabled
23824         in the current TU.
23825         (resolve_addr): Avoid adding skeleton DIEs for DW_AT_call_origin
23826         inside of type units.
23828 2017-01-26  Martin Sebor  <msebor@redhat.com>
23830         PR middle-end/78703
23831         * gimple-ssa-sprintf.c (struct result_range): Add likely and
23832         unlikely counters.
23833         (struct format_result): Replace number_chars, number_chars_min,
23834         and number_chars_max with a single member of struct result_range.
23835         Remove bounded.
23836         (format_result::operator+=): Adjust.
23837         (struct fmtresult): Remove bounded.  Handle likely and unlikely
23838         counters.
23839         (fmtresult::adjust_for_width_or_precision): New function.
23840         (fmtresult:type_max_digits): New function.
23841         (bytes_remaining): Handle likely and unlikely counters.
23842         (min_bytes_remaining): Remove.
23843         (format_percent): Simplify.
23844         (format_integer, format_floating): Set likely and unlikely counters.
23845         (get_string_length, format_character, format_string): Same.
23846         (format_plain, should_warn_p): New function.
23847         (maybe_warn): Call should_warn_p.  Update diagnostic messages
23848         and handle those for all directives, including plain strings.
23849         (format_directive): Handle likely and unlikely counters.
23850         Remove unnecessary quoting from diagnostics.  Add an informational
23851         note.
23852         (add_bytes): Remove.
23853         (pass_sprintf_length::compute_format_length): Simplify.
23854         (try_substitute_return_value): Handle likely and unlikely counters.
23856 2017-01-26  Carl Love  <cel@us.ibm.com>
23858         * config/rs6000/rs6000-c (altivec_overloaded_builtins): Remove
23859         bogus entries for the P8V_BUILTIN_VEC_VGBBD built-ins
23861 2017-01-26  Vladimir Makarov  <vmakarov@redhat.com>
23863         PR target/79131
23864         * lra-assigns.c (setup_live_pseudos_and_spill_after_risky): Take
23865         endianess for subregs into account.
23866         * lra-constraints.c (lra_constraints): Do risky transformations
23867         always on the first iteration.
23868         * lra-lives.c (check_pseudos_live_through_calls): Add arg
23869         last_call_used_reg_set.
23870         (process_bb_lives): Define and use last_call_used_reg_set.
23871         * lra.c (lra): Always continue after lra_constraints on the first
23872         iteration.
23874 2017-01-26  Kirill Yukhin  <kirill.yukhin@gmail.com>
23876         * gcc.target/i386/avx512bw-kshiftlq-2.c: Use unsigned long long
23877         constant.
23878         * gcc.target/i386/avx512bw-kshiftrq-2.c: Ditto.
23880 2017-01-26  Jakub Jelinek  <jakub@redhat.com>
23882         * config/i386/avx512fintrin.h (_ktest_mask16_u8,
23883         _ktestz_mask16_u8, _ktestc_mask16_u8, _kadd_mask16): Move to ...
23884         * config/i386/avx512dqintrin.h (_ktest_mask16_u8,
23885         _ktestz_mask16_u8, _ktestc_mask16_u8, _kadd_mask16): ... here.
23886         * config/i386/i386-builtin.def (__builtin_ia32_ktestchi,
23887         __builtin_ia32_ktestzhi, __builtin_ia32_kaddhi): Use
23888         OPTION_MASK_ISA_AVX512DQ instead of OPTION_MASK_ISA_AVX512F.
23889         * config/i386/sse.md (SWI1248_AVX512BWDQ2): New mode iterator.
23890         (kadd<mode>, ktest<mode>): Use it instead of SWI1248_AVX512BWDQ.
23892 2017-01-26  Marek Polacek  <polacek@redhat.com>
23894         PR c/79199
23895         * fold-const.c (operand_equal_p) [COND_EXPR]: Use OP_SAME_WITH_NULL
23896         for the third operand.
23898 2017-01-26  Jakub Jelinek  <jakub@redhat.com>
23900         PR middle-end/79236
23901         * omp-low.c (struct omp_context): Add simt_stmt field.
23902         (scan_omp_for): Return omp_context *.
23903         (scan_omp_simd): Set simt_stmt on the non-_simt_ SIMD
23904         context to the _simt_ SIMD stmt.
23905         (lower_omp_for): For combined SIMD with sibling _simt_
23906         SIMD, make sure to use the same decls in _looptemp_
23907         clauses as in the sibling.
23909 2017-01-26  David Sherwood  <david.sherwood@arm.com>
23911         PR middle-end/79212
23912         * gimplify.c (omp_notice_variable): Add GOVD_SEEN flag to variables in
23913         all contexts.
23915 2017-01-26  Jakub Jelinek  <jakub@redhat.com>
23917         PR target/70465
23918         * reg-stack.c (emit_swap_insn): Instead of fld a; fld b; fxchg %st(1);
23919         emit fld b; fld a; if possible.
23921         * brig-builtins.def: Update copyright years.
23922         * config/arm/arm_acle_builtins.def: Update copyright years.
23924 2017-01-25  Michael Meissner  <meissner@linux.vnet.ibm.com>
23926         PR target/79179
23927         * config/rs6000/vsx.md (vsx_extract_<mode>_store): Use wY
23928         constraint instead of o for the stxsd instruction.
23930 2017-01-25  Carl Love  <cel@us.ibm.com>
23932         * config/rs6000/rs6000-c (altivec_overloaded_builtins): Fix order
23933         of entries for ALTIVEC_BUILTIN_VEC_PACKS and P8V_BUILTIN_VEC_VGBBD.
23935 2017-01-25  Jonathan Wakely  <jwakely@redhat.com>
23937         * doc/invoke.texi (C++ Dialect Options): Fix typo.
23939 2017-01-25  Richard Biener  <rguenther@suse.de>
23941         PR tree-optimization/69264
23942         * target.def (vector_alignment_reachable): Improve documentation.
23943         * doc/tm.texi: Regenerate.
23944         * targhooks.c (default_builtin_vector_alignment_reachable): Simplify
23945         and add a comment.
23946         * tree-vect-data-refs.c (vect_supportable_dr_alignment): Revert
23947         earlier changes with respect to TYPE_USER_ALIGN.
23948         (vector_alignment_reachable_p): Likewise.  Improve dumping.
23950 2016-01-25  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
23952         PR target/79145
23953         * config/arm/arm.md (xordi3): Force constant operand into a register
23954         for TARGET_IWMMXT.
23956 2016-01-25  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
23958         * doc/invoke.texi (-fstore-merging): Correct default optimization
23959         levels at which it is enabled.
23960         (-O): Move -fstore-merging from list to...
23961         (-O2): ... Here.
23963 2017-01-25  Richard Biener  <rguenther@suse.de>
23965         PR debug/78363
23966         * omp-expand.c: Include debug.h.
23967         (expand_omp_taskreg): Make sure to generate early debug before
23968         outlining anything from a function.
23969         (expand_omp_target): Likewise.
23970         (grid_expand_target_grid_body): Likewise.
23972 2017-01-25  Maxim Ostapenko  <m.ostapenko@samsung.com>
23974         PR lto/79061
23975         * asan.c (get_translation_unit_decl): New function.
23976         (asan_add_global): Extract modules file name from globals
23977         TRANSLATION_UNIT_DECL name.
23979 2017-01-24  Eric Botcazou  <ebotcazou@adacore.com>
23981         PR target/77439
23982         * config/arm/arm.c (arm_function_ok_for_sibcall): Add back restriction
23983         for long calls with APCS frame and VFP.
23985 2017-01-24  David Malcolm  <dmalcolm@redhat.com>
23987         * cfg.c (original_copy_tables_initialized_p): New function.
23988         * cfg.h (original_copy_tables_initialized_p): New decl.
23989         * cfgrtl.c (relink_block_chain): Guard the call to
23990         free_original_copy_tables with a call to
23991         original_copy_tables_initialized_p.
23992         * cgraph.h (symtab_node::native_rtl_p): New decl.
23993         * cgraphunit.c (symtab_node::native_rtl_p): New function.
23994         (symtab_node::needed_p): Don't assert for early assembly output
23995         for __RTL functions.
23996         (cgraph_node::finalize_function): Set "force_output" for __RTL
23997         functions.
23998         (cgraph_node::analyze): Bail out early for __RTL functions.
23999         (analyze_functions): Update assertion to support __RTL functions.
24000         (cgraph_node::expand): Bail out early for __RTL functions.
24001         * final.c (rest_of_clean_state): Don't call delete_tree_ssa for
24002         __RTL functions.
24003         * function.h (struct function): Update comment for field
24004         "pass_startwith".
24005         * gimple-expr.c: Include "tree-pass.h".
24006         (gimple_has_body_p): Return false for __RTL functions.
24007         * Makefile.in (OBJS): Add run-rtl-passes.o.
24008         * pass_manager.h (gcc::pass_manager::get_rest_of_compilation): New
24009         accessor.
24010         (gcc::pass_manager::get_clean_slate): New accessor.
24011         * passes.c: Include "insn-addr.h".
24012         (should_skip_pass_p): Add logging.  Update logic for running
24013         "expand" to be compatible with both __GIMPLE and __RTL.  Guard
24014         property-provider override so it is only done for gimple passes.
24015         Don't skip dfinit.
24016         (skip_pass): New function.
24017         (execute_one_pass): Call skip_pass when skipping passes.
24018         * read-md.c (md_reader::read_char): Support filtering
24019         the input to a subset of line numbers.
24020         (md_reader::md_reader): Initialize fields
24021         m_first_line and m_last_line.
24022         (md_reader::read_file_fragment): New function.
24023         * read-md.h (md_reader::read_file_fragment): New decl.
24024         (md_reader::m_first_line): New field.
24025         (md_reader::m_last_line): New field.
24026         * read-rtl-function.c (function_reader::create_function): Only
24027         create cfun if it doesn't already exist.  Set PROP_rtl on cfun's
24028         curr_properties.  Set DECL_INITIAL to a dummy block.
24029         (read_rtl_function_body_from_file_range): New function.
24030         * read-rtl-function.h (read_rtl_function_body_from_file_range):
24031         New decl.
24032         * run-rtl-passes.c: New file.
24033         * run-rtl-passes.h: New file.
24035 2017-01-24  Jeff Law  <law@redhat.com>
24037         * config/microblaze/microblaze.h (ASM_FORMAT_PRIVATE_NAME): Increase
24038         buffer size.
24040 2017-01-24  Bin Cheng  <bin.cheng@arm.com>
24042         PR tree-optimization/79159
24043         * tree-ssa-loop-niter.c (get_cst_init_from_scev): New function.
24044         (record_nonwrapping_iv): Improve boundary using above function if no
24045         value range information.
24047 2017-01-24  Pekka Jääskeläinen  <pekka@parmance.com>
24048             Martin Jambor  <mjambor@suse.cz>
24050         * brig-builtins.def: New file.
24051         * builtins.def (DEF_HSAIL_BUILTIN): New macro.
24052         (DEF_HSAIL_ATOMIC_BUILTIN): Likewise.
24053         (DEF_HSAIL_SAT_BUILTIN): Likewise.
24054         (DEF_HSAIL_INTR_BUILTIN): Likewise.
24055         (DEF_HSAIL_CVT_ZEROI_SAT_BUILTIN): Likewise.
24056         * builtin-types.def (BT_INT8): New.
24057         (BT_INT16): Likewise.
24058         (BT_UINT8): Likewise.
24059         (BT_UINT16): Likewise.
24060         (BT_FN_ULONG): Likewise.
24061         (BT_FN_UINT_INT): Likewise.
24062         (BT_FN_UINT_ULONG): Likewise.
24063         (BT_FN_UINT_LONG): Likewise.
24064         (BT_FN_UINT_PTR): Likewise.
24065         (BT_FN_ULONG_PTR): Likewise.
24066         (BT_FN_INT8_FLOAT): Likewise.
24067         (BT_FN_INT16_FLOAT): Likewise.
24068         (BT_FN_UINT32_FLOAT): Likewise.
24069         (BT_FN_UINT16_FLOAT): Likewise.
24070         (BT_FN_UINT8_FLOAT): Likewise.
24071         (BT_FN_UINT64_FLOAT): Likewise.
24072         (BT_FN_UINT16_UINT32): Likewise.
24073         (BT_FN_UINT32_UINT16): Likewise.
24074         (BT_FN_UINT16_UINT16_UINT16): Likewise.
24075         (BT_FN_INT_PTR_INT): Likewise.
24076         (BT_FN_UINT_PTR_UINT): Likewise.
24077         (BT_FN_LONG_PTR_LONG): Likewise.
24078         (BT_FN_ULONG_PTR_ULONG): Likewise.
24079         (BT_FN_VOID_UINT64_UINT64): Likewise.
24080         (BT_FN_UINT8_UINT8_UINT8): Likewise.
24081         (BT_FN_INT8_INT8_INT8): Likewise.
24082         (BT_FN_INT16_INT16_INT16): Likewise.
24083         (BT_FN_INT_INT_INT): Likewise.
24084         (BT_FN_UINT_FLOAT_UINT): Likewise.
24085         (BT_FN_FLOAT_UINT_UINT): Likewise.
24086         (BT_FN_ULONG_UINT_UINT): Likewise.
24087         (BT_FN_ULONG_UINT_PTR): Likewise.
24088         (BT_FN_ULONG_ULONG_ULONG): Likewise.
24089         (BT_FN_UINT_UINT_UINT): Likewise.
24090         (BT_FN_VOID_UINT_PTR): Likewise.
24091         (BT_FN_UINT_UINT_PTR: Likewise.
24092         (BT_FN_UINT32_UINT64_PTR): Likewise.
24093         (BT_FN_INT_INT_UINT_UINT): Likewise.
24094         (BT_FN_UINT_UINT_UINT_UINT): Likewise.
24095         (BT_FN_UINT_UINT_UINT_PTR): Likewise.
24096         (BT_FN_UINT_ULONG_ULONG_UINT): Likewise.
24097         (BT_FN_ULONG_ULONG_ULONG_ULONG): Likewise.
24098         (BT_FN_LONG_LONG_UINT_UINT): Likewise.
24099         (BT_FN_ULONG_ULONG_UINT_UINT): Likewise.
24100         (BT_FN_VOID_UINT32_UINT64_PTR): Likewise.
24101         (BT_FN_VOID_UINT32_UINT32_PTR): Likewise.
24102         (BT_FN_UINT_UINT_UINT_UINT_UINT): Likewise.
24103         (BT_FN_UINT_FLOAT_FLOAT_FLOAT_FLOAT): Likewise.
24104         (BT_FN_ULONG_ULONG_ULONG_UINT_UINT): Likewise.
24105         * doc/frontends.texi: List BRIG FE.
24106         * doc/install.texi (Testing): Add BRIG tesring requirements.
24107         * doc/invoke.texi (Overall Options): Mention BRIG.
24108         * doc/standards.texi (Standards): Doucment BRIG HSA version.
24110 2017-01-24  Richard Biener  <rguenther@suse.de>
24112         PR translation/79208
24113         * ipa-devirt.c (odr_types_equivalent_p): Fix typo in diagnostic.
24115 2017-01-24  Martin Jambor  <mjambor@suse.cz>
24117         PR bootstrap/79198
24118         * ipa-prop.c (ipa_free_all_node_params): Call summary destructor.
24119         * ipa-prop.c (ipa_node_params_t::insert): Initialize fields known_csts
24120         and known_contexts.
24122 2017-01-24  Aldy Hernandez  <aldyh@redhat.com>
24124         PR middle-end/79123
24125         * gimple-ssa-warn-alloca.c (alloca_call_type): Make sure
24126         casts from signed to unsigned really don't have a range.
24128 2017-01-24  Markus Trippelsdorf  <markus@trippelsdorf.de>
24130         * gimple-ssa-sprintf.c (format_floating): Change MPFR_RNDx to
24131         GMP_RNDx for compatiblity.
24133 2017-01-24  Martin Liska  <mliska@suse.cz>
24135         PR bootstrap/79132
24136         * tree-ssa-reassoc.c (rewrite_expr_tree_parallel): Insert assert
24137         that would prevent us to call alloca with -1 as argument.
24139 2017-01-24  Jakub Jelinek  <jakub@redhat.com>
24141         * dwarf2out.c (output_compilation_unit_header, output_file_names):
24142         Avoid -Wformat-security warning.
24144 2017-01-23  Andrew Pinski  <apinski@cavium.com>
24146         * config/aarch64/aarch64.c (thunderx2t99_addrcost_table): Improve
24147         cost table.
24149 2017-01-23  Martin Sebor  <msebor@redhat.com>
24151         PR middle-end/78703
24152         * gimple-ssa-sprintf.c (warn_level): New global.
24153         (format_integer): Use it here and throughout the rest of the file.
24154         Use the same switch to compute sign as base.
24155         (maybe_warn): New function.
24156         (format_directive): Factor out warnings into maybe_warn.
24157         Add debugging output.  Use warn_level.
24158         (add_bytes): Use warn_level.
24159         (pass_sprintf_length::compute_format_length): Add debugging output.
24160         (try_substitute_return_value): Same.
24161         (pass_sprintf_length::handle_gimple_call): Set and use warn_level.
24163         PR middle-end/78703
24164         * gimple-ssa-sprintf.c (struct format_result): Remove constant member.
24165         (struct fmtresult, format_integer, format_floating): Adjust.
24166         (fmtresult::fmtresult): Set max correctly in two argument ctor.
24167         (get_string_length, format_string,format_directive): Same.
24168         (pass_sprintf_length::compute_format_length): Same.
24169         (try_substitute_return_value): Simplify slightly.
24171         PR middle-end/78703
24172         * gimple-ssa-sprintf.c (pass_sprintf_length::gate): Adjust formatting.
24173         (fmtresult::operator+=): Outlined.
24174         (struct fmtresult): Add ctors.
24175         (struct conversion_spec): Rename...
24176         (struct directive): ...to this.  Add and remove data members.
24177         (directive::set_width, directive::set_precision): New functions.
24178         (format_percent): Use fmtresult ctor.
24179         (get_width_and_precision): Remove.
24180         (format_integer): Make naming changes.  Avoid computing width and
24181         precision.
24182         (format_floating): Same.  Adjust indentation.
24183         (format_character, format_none): New functions.
24184         (format_string): Moved character handling to format_character.
24185         (format_directive): Remove arguments, change return type.
24186         (parse_directive): New function.
24187         (pass_sprintf_length::compute_format_length): Move directive
24188         parsing to parse_directive.
24190 2017-01-23  Jakub Jelinek  <jakub@redhat.com>
24192         * tree.h (assign_assembler_name_if_neeeded): Rename to ...
24193         (assign_assembler_name_if_needed): ... this.
24194         * tree.c (assign_assembler_name_if_neeeded): Rename to ...
24195         (assign_assembler_name_if_needed): ... this.
24196         (free_lang_data_in_cgraph): Adjust callers.
24197         * cgraphunit.c (cgraph_node::analyze): Likewise.
24198         * omp-expand.c (expand_omp_taskreg, expand_omp_target):
24199         Likewise.
24201 2017-01-23  Richard Biener  <rguenther@suse.de>
24203         PR tree-optimization/79088
24204         PR tree-optimization/79188
24205         * tree-ssa-threadupdate.c (mark_threaded_blocks): Move code
24206         resetting loop bounds after last path deletion.  Reset loop
24207         bounds of the target loop, make code match the comments.
24208         * tree-ssa-threadbackwards.c (pass_early_thread_jumps::execute):
24209         Make sure loops need no fixups.
24211 2017-01-23  Kelvin Nilsen  <kelvin@gcc.gnu.org>
24213         * config/rs6000/rs6000-builtin.def (VSIEDPF): Add scalar insert
24214         exponent support with double type for first argument.
24215         * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Changed
24216         type returned by __builtin_vec_extract_sig,
24217         __builtin_vec_extract_sig_sp, and __builtin_vec_extract_sig_dp
24218         functions from "vector int" to "vector unsigned int" or from
24219         "vector long long int" to "vector unsigned long long int".
24220         Changed type returned by __builtin_vec_extract_exp,
24221         __builtin_vec_extract_exp_sp, and __builtin_vec_extract_exp_dp
24222         functions from "vector int" to "vector unsigned int" or from
24223         "vector long long int" to "vector unsigned long long int".
24224         Changed return type of __builtin_vec_test_data_class,
24225         __builtin_vec_test_data_class_sp, and
24226         __builtin_vec_test_data_class_dp from "vector int" to
24227         "vector bool int" or from "vector long long int" to "vector bool
24228         long long int" and changed second argument type from "unsigned
24229         int" to "int".  Added new overloaded function forms "vector float
24230         __builtin_vec_insert_exp (vector float, vector unsigned int)" and
24231         "vector float __builtin_vec_insert_exp_sp (vector float, vector
24232         unsigned int)" and "vector double __builtin_vec_insert_exp (vector
24233         double, vector unsigned long long int)" and "vector double
24234         __builtin_vec_insert_exp_dp (vector double, vector unsigned long
24235         long int)".  Changed return type of
24236         __builtin_scalar_test_data_class and
24237         __builtin_scalar_test_data_class_sp and
24238         __builtin_scalar_test_data_class_dp from "unsigned int" to "bool
24239         int" and changed second argument from "unsigned int" to "int".
24240         Changed type returned by __builtin_scalar_test_neg,
24241         __builtin_scalar_test_neg_sp, and __builtin_scalar_test_neg_dp
24242         from "int" to "bool int".  Added new overloaded function form
24243         "double __builtin_scalar_insert_exp (double, unsigned long long int)".
24244         * config/rs6000/vsx.md (xsiexpdpf): New insn for scalar insert
24245         exponent double-precision with floating point first argument.
24246         * doc/extend.texi (PowerPC AltiVec Built-in Functions): Adjust
24247         documentation of scalar_test_data_class, scalar_test_neg,
24248         scalar_extract_sig, scalar_extract_exp, scalar_insert_exp,
24249         vector_extract_exp, vec_extract_sig, vec_insert_exp, and
24250         vec_test_data_class built-in functions to reflect refinements in
24251         their type signatures.
24253 2017-01-23  Andreas Tobler  <andreast@gcc.gnu.org>
24255         * config/aarch64/aarch64.c (aarch64_elf_asm_constructor): Increase
24256         size of buf.
24257         (aarch64_elf_asm_destructor): Likewise.
24259 2017-01-23  Bernd Schmidt  <bschmidt@redhat.com>
24261         PR rtl-optimization/78634
24262         * config/i386/i386.c (ix86_max_noce_ifcvt_seq_cost): New function.
24263         (TARGET_MAX_NOCE_IFCVT_SEQ_COST): Define.
24264         * ifcvt.c (noce_try_cmove): Add missing cost check.
24266         PR rtl-optimization/71724
24267         * combine.c (if_then_else_cond): Look for situations where it is
24268         beneficial to undo the work of one of the recursive calls.
24270 2017-01-23  Bin Cheng  <bin.cheng@arm.com>
24272         PR tree-optimization/70754
24273         * tree-predcom.c (stmt_combining_refs): New parameter INSERT_BEFORE.
24274         (reassociate_to_the_same_stmt): New parameter INSERT_BEFORE.  Insert
24275         combined stmt before it if not NULL.
24276         (combine_chains): Process refs reversely and compute dominance point
24277         for root ref.
24279 2017-01-23  Martin Liska  <mliska@suse.cz>
24281         PR tree-optimization/79196
24282         * tree-ssa-strlen.c (fold_strstr_to_memcmp): Rename to ...
24283         (fold_strstr_to_strncmp): ... this.  Fold the pattern to strncmp
24284         instead of memcmp.
24285         (strlen_optimize_stmt): Call the renamed function.
24287 2017-01-23  Michael Matz  <matz@suse.de>
24289         PR tree-optimization/78384
24290         * tree-ssa-loop-split.c (patch_loop_exit): Use correct edge.
24292 2017-01-23  Richard Biener  <rguenther@suse.de>
24294         PR tree-optimization/79186
24295         * tree-vrp.c (register_new_assert_for): Make sure we've seen
24296         both incoming edges before moving an assert.
24298 2017-01-23  Martin Jambor  <mjambor@suse.cz>
24300         * ipa-prop.c (load_from_param_1): Removed.
24301         (load_from_unmodified_param): Bits from load_from_param_1 put back
24302         here.
24303         (load_from_param): Removed.
24304         (compute_complex_assign_jump_func): Removed stmt2 and just replaced it
24305         with stmt.  Reverted back to use of load_from_unmodified_param.
24307 2017-01-23  Martin Jambor  <mjambor@suse.cz>
24309         PR ipa/79108
24310         * ipa-prop.h (ipa_param_descriptor): Anotate with with GTY(()).
24311         (ipa_node_params): Annotate with GTY((for_user)).  Make descriptors
24312         field a pointer to garbage collected vector, mark lattices and
24313         ipcp_orig_node with GTY((skip)).
24314         (ipa_get_param_count): Adjust to descriptors being a pointer.
24315         (ipa_get_param): Likewise.
24316         (ipa_get_type): Likewise.
24317         (ipa_get_param_move_cost): Likewise.
24318         (ipa_set_param_used): Likewise.
24319         (ipa_get_controlled_uses): Likewise.
24320         (ipa_set_controlled_uses): Likewise.
24321         (ipa_is_param_used): Likewise.
24322         (ipa_node_params_t): Move into garbage collector.  New methods insert
24323         and remove.
24324         (ipa_node_params_sum): Annotate wth GTY(()).
24325         (ipa_check_create_node_params): Adjust to ipa_node_params_sum being
24326         garbage collected.
24327         (ipa_load_from_parm_agg): Adjust declaration.
24328         * ipa-icf.c (param_used_p): Adjust to descriptors being a pointer.
24329         * ipa-profile.c (ipa_profile): Likewise.
24330         * ipa-prop.c (ipa_get_param_decl_index_1): Likewise.
24331         (ipa_populate_param_decls): Make descriptors parameter garbage
24332         collected.
24333         (ipa_dump_param): Adjust to descriptors being a pointer.
24334         (ipa_alloc_node_params): Likewise.
24335         (ipa_initialize_node_params): Likewise.
24336         (load_from_param_1): Make descriptors parameter garbage collected.
24337         (load_from_unmodified_param): Likewise.
24338         (load_from_param): Likewise.
24339         (ipa_load_from_parm_agg): Likewise.
24340         (ipa_node_params::~ipa_node_params): Removed.
24341         (ipa_free_all_node_params): Remove call to delete operator.
24342         (ipa_node_params_t::insert): New.
24343         (ipa_node_params_t::remove): Likewise.
24344         (ipa_node_params_t::duplicate): Adjust to descriptors being a pointer,
24345         copy known_csts and known_contexts vectors.
24346         (ipa_read_node_info): Adjust to descriptors being a pointer.
24347         (ipcp_modif_dom_walker): Make m_descriptors field garbage
24348         collected.
24349         (ipcp_transform_function): Make descriptors variable garbage
24350         collected.
24352 2017-01-23  Andrew Senkevich  <andrew.senkevich@intel.com>
24354         * config/i386/avx512bwintrin.h: Add k-mask test, kortest intrinsics.
24355         * config/i386/avx512dqintrin.h: Ditto.
24356         * config/i386/avx512fintrin.h: Ditto.
24357         * config/i386/i386.c: Handle new builtins.
24358         * config/i386/i386-builtin.def: Add new builtins.
24359         * config/i386/sse.md (ktest<mode>, kortest<mode>): New.
24360         (UNSPEC_KORTEST, UNSPEC_KTEST): New.
24362 2017-01-23  Jakub Jelinek  <jakub@redhat.com>
24363             Martin Liska  <mliska@suse.cz>
24365         * asan.h: Define ASAN_USE_AFTER_SCOPE_ATTRIBUTE.
24366         * asan.c (asan_expand_poison_ifn): Support stores and use
24367         appropriate ASAN report function.
24368         * internal-fn.c (expand_ASAN_POISON_USE): New function.
24369         * internal-fn.def (ASAN_POISON_USE): Declare.
24370         * tree-into-ssa.c (maybe_add_asan_poison_write): New function.
24371         (maybe_register_def): Create ASAN_POISON_USE when sanitizing.
24372         * tree-ssa-dce.c (eliminate_unnecessary_stmts): Remove
24373         ASAN_POISON calls w/o LHS.
24374         * tree-ssa.c (execute_update_addresses_taken): Create clobber
24375         for ASAN_MARK (UNPOISON, &x, ...) in order to prevent usage of a LHS
24376         from ASAN_MARK (POISON, &x, ...) coming to a PHI node.
24377         * gimplify.c (asan_poison_variables): Add attribute
24378         use_after_scope_memory to variables that really needs to live
24379         in memory.
24380         * tree-ssa.c (is_asan_mark_p): Do not rewrite into SSA when
24381         having the attribute.
24383 2017-01-23  Martin Liska  <mliska@suse.cz>
24385         * asan.c (create_asan_shadow_var): New function.
24386         (asan_expand_poison_ifn): Likewise.
24387         * asan.h (asan_expand_poison_ifn): New declaration.
24388         * internal-fn.c (expand_ASAN_POISON): Likewise.
24389         * internal-fn.def (ASAN_POISON): New builtin.
24390         * sanopt.c (pass_sanopt::execute): Expand
24391         asan_expand_poison_ifn.
24392         * tree-inline.c (copy_decl_for_dup_finish): Make function
24393         external.
24394         * tree-inline.h (copy_decl_for_dup_finish): Likewise.
24395         * tree-ssa.c (is_asan_mark_p): New function.
24396         (execute_update_addresses_taken): Rewrite local variables
24397         (identified just by use-after-scope as addressable) into SSA.
24399 2017-01-22  Gerald Pfeifer  <gerald@pfeifer.com>
24401         * doc/install.texi (Specific): opensource.apple.com uses https
24402         now. Remove trailing slash.
24404 2017-01-22  Gerald Pfeifer  <gerald@pfeifer.com>
24406         * README.Portability: Remove note on an Irix compatibility issue.
24408 2017-01-22  Dimitry Andric <dim@FreeBSD.org>
24410         * gcov.c (INCLUDE_ALGORITHM): Define.
24411         (INCLUDE_VECTOR): Define.
24412         No longer include <vector> and <algorithm> directly.
24414 2017-01-21  Gerald Pfeifer  <gerald@pfeifer.com>
24416         * doc/extend.texi (Thread-Local): Change www.akkadia.org reference
24417         to https.
24418         * doc/invoke.texi (Code Gen Options): Ditto.
24420 2017-01-21  Jan Hubicka  <hubicka@ucw.cz>
24422         PR lto/78407
24423         * cfg.c (update_bb_profile_for_threading): Fix updating of probablity.
24425 2017-01-21  Bernd Schmidt  <bschmidt@redhat.com>
24427         rtl-optimization/79125
24428         * cprop.c (local_cprop_pass): Handle cases where we make an
24429         unconditional trap.
24431 2017-01-20  Segher Boessenkool  <segher@kernel.crashing.org>
24433         PR target/61729
24434         PR target/77850
24435         * config/rs6000/rs6000.c (rs6000_gimplify_va_arg): Adjust address to
24436         read from, for big endian.
24438 2017-01-20  Jiong Wang  <jiong.wang@arm.com>
24440         * config/aarch64/aarch64-builtins.c (aarch64_init_builtins): Register
24441         register pauth builtins for LP64 only.
24443 2017-01-20  Marek Polacek  <polacek@redhat.com>
24445         PR c/79152
24446         * gimplify.c (should_warn_for_implicit_fallthrough): Handle consecutive
24447         non-case labels.
24449 2017-01-20  Alexander Monakov  <amonakov@ispras.ru>
24451         * omp-expand.c (expand_omp_simd): Clear PROP_gimple_lomp_dev regardless
24452         of safelen status.
24453         * omp-offload.c (pass_omp_device_lower::gate): Use PROP_gimple_lomp_dev.
24454         * passes.c (dump_properties): Handle PROP_gimple_lomp_dev.
24455         * tree-inline.c (expand_call_inline): Propagate PROP_gimple_lomp_dev.
24457 2017-01-20  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
24459         PR target/71270
24460         * config/arm/arm.c (neon_valid_immediate): Reject vector constants
24461         in big-endian mode when they are not a single duplicated value.
24463 2017-01-20  Richard Biener  <rguenther@suse.de>
24465         * BASE-VER: Bump to 7.0.1.
24467 2017-01-20  Alexander Monakov  <amonakov@ispras.ru>
24469         * omp-low.c (omplow_simd_context): New struct.  Use it...
24470         (lower_rec_simd_input_clauses): ...here and...
24471         (lower_rec_input_clauses): ...here to hold common data.  Adjust all
24472         references to idx, lane, max_vf, is_simt.
24474 2017-01-20  Graham Markall  <graham.markall@embecosm.com>
24476         * config/arc/arc.h (LINK_SPEC): Use arclinux_nps emulation when
24477         mcpu=nps400.
24479 2017-01-20  Martin Jambor  <mjambor@suse.cz>
24481         * hsa.h: Renaed to hsa-common.h.  Adjusted a comment.
24482         * hsa.c: Renaed to hsa-common.c.  Change include of gt-hsa.h to
24483         gt-hsa-common.h.
24484         * Makefile.in (OBJS): Rename hsa.o to hsa-common.o.
24485         (GTFILES): Rename hsa.c to hsa-common.c.
24486         * hsa-brig.c: Change include of hsa.h to hsa-common.h.
24487         * hsa-dump.c: Likewise.
24488         * hsa-gen.c: Likewise.
24489         * hsa-regalloc.c: Likewise.
24490         * ipa-hsa.c: Likewise.
24491         * omp-expand.c: Likewise.
24492         * omp-low.c: Likewise.
24493         * toplev.c: Likewise.
24495 2017-01-20  Marek Polacek  <polacek@redhat.com>
24497         PR c/64279
24498         * doc/invoke.texi: Document -Wduplicated-branches.
24499         * fold-const.c (operand_equal_p): Handle MODIFY_EXPR, INIT_EXPR,
24500         COMPOUND_EXPR, PREDECREMENT_EXPR, PREINCREMENT_EXPR,
24501         POSTDECREMENT_EXPR, POSTINCREMENT_EXPR, CLEANUP_POINT_EXPR, EXPR_STMT,
24502         STATEMENT_LIST, and RETURN_EXPR.  For non-pure non-const functions
24503         return 0 only when not OEP_LEXICOGRAPHIC.
24504         (fold_build_cleanup_point_expr): Use the expression
24505         location when building CLEANUP_POINT_EXPR.
24506         * tree-core.h (enum operand_equal_flag): Add OEP_LEXICOGRAPHIC.
24507         * tree.c (add_expr): Handle error_mark_node.
24509 2017-01-20  Martin Liska  <mliska@suse.cz>
24511         PR lto/69188
24512         * tree-profile.c (init_ic_make_global_vars): Do not call
24513         finalize_decl.
24514         (gimple_init_gcov_profiler): Likewise.
24516 2017-01-20  Martin Liska  <mliska@suse.cz>
24518         PR ipa/71190
24519         * cgraph.h (maybe_create_reference): Remove argument and
24520         update comment.
24521         * cgraphclones.c (cgraph_node::create_virtual_clone): Remove one
24522         argument.
24523         * ipa-cp.c (create_specialized_node): Likewise.
24524         * symtab.c (symtab_node::maybe_create_reference): Handle
24525         VAR_DECLs and ADDR_EXPRs and select ipa_ref_use type.
24527 2017-01-20  Martin Liska  <mliska@suse.cz>
24529         * read-rtl-function.c (function_reader::create_function): Use
24530         build_decl instread of build_decl_stat.
24532 2017-01-20  Andrew Senkevich  <andrew.senkevich@intel.com>
24534         * config/i386/avx512bwintrin.h: Add k-mask registers shift intrinsics.
24535         * config/i386/avx512dqintrin.h: Ditto.
24536         * config/i386/avx512fintrin.h: Ditto.
24537         * config/i386/i386-builtin-types.def: Add new types.
24538         * config/i386/i386.c: Handle new types.
24539         * config/i386/i386-builtin.def (__builtin_ia32_kshiftliqi)
24540         (__builtin_ia32_kshiftlihi, __builtin_ia32_kshiftlisi)
24541         (__builtin_ia32_kshiftlidi, __builtin_ia32_kshiftriqi)
24542         (__builtin_ia32_kshiftrihi, __builtin_ia32_kshiftrisi)
24543         (__builtin_ia32_kshiftridi): New.
24544         * config/i386/sse.md (k<code><mode>): Rename *k<code><mode>.
24546 2017-01-19  Segher Boessenkool  <segher@kernel.crashing.org>
24548         PR target/78875
24549         PR target/79140
24550         * config/rs6000/rs6000.c (TARGET_STACK_PROTECT_GUARD): Unconditionally
24551         define to rs6000_init_stack_protect_guard.
24552         (rs6000_init_stack_protect_guard): New function.
24554 2017-01-19  Matthew Fortune  <matthew.fortune@imgtec.com>
24555             Yunqiang Su  <yunqiang.su@imgtec.com>
24557         * config.gcc (supported_defaults): Add madd4.
24558         (with_madd4): Add validation.
24559         (all_defaults): Add madd4.
24560         * config/mips/mips.opt (mmadd4): New option.
24561         * config/mips/mips.h (OPTION_DEFAULT_SPECS): Add a default for
24562         mmadd4.
24563         (TARGET_CPU_CPP_BUILTINS): Add builtin_define for
24564         __mips_no_madd4.
24565         (ISA_HAS_UNFUSED_MADD4): Gate with mips_madd4.
24566         (ISA_HAS_FUSED_MADD4): Likewise.
24567         * doc/invoke.texi (-mmadd4): Document the new option.
24568         * doc/install.texi (--with-madd4): Document the new option.
24570 2017-01-19  Jiong Wang  <jiong.wang@arm.com>
24572         * config/aarch64/aarch64-builtins.c (enum aarch64_builtins): New
24573         entries for AARCH64_PAUTH_BUILTIN_XPACLRI,
24574         AARCH64_PAUTH_BUILTIN_PACIA1716, AARCH64_PAUTH_BUILTIN_AUTIA1716.
24575         (aarch64_init_pauth_hint_builtins): New.
24576         (aarch64_init_builtins): Call aarch64_init_pauth_hint_builtins.
24577         (aarch64_expand_builtin): Expand new builtins.
24579 2017-01-19  Jiong Wang  <jiong.wang@arm.com>
24581         * reg-notes.def (CFA_TOGGLE_RA_MANGLE): New reg-note.
24582         * combine-stack-adj.c (no_unhandled_cfa): Handle
24583         REG_CFA_TOGGLE_RA_MANGLE.
24584         * dwarf2cfi.c (dwarf2out_frame_debug): Handle REG_CFA_TOGGLE_RA_MANGLE.
24585         * config/aarch64/aarch64.c (aarch64_expand_prologue): Generates DWARF
24586         info for return address signing.
24587         (aarch64_expand_epilogue): Likewise.
24589 2017-01-19  Jiong Wang  <jiong.wang@arm.com>
24591         * config/aarch64/aarch64-opts.h (aarch64_function_type): New enum.
24592         * config/aarch64/aarch64-protos.h
24593         (aarch64_return_address_signing_enabled): New declaration.
24594         * config/aarch64/aarch64.c (aarch64_return_address_signing_enabled):
24595         New function.
24596         (aarch64_expand_prologue): Sign return address before it's pushed onto
24597         stack.
24598         (aarch64_expand_epilogue): Authenticate return address fetched from
24599         stack.
24600         (aarch64_override_options): Sanity check for ILP32 and ISA level.
24601         (aarch64_attributes): New function attributes for "sign-return-address".
24602         * config/aarch64/aarch64.md (UNSPEC_AUTI1716, UNSPEC_AUTISP,
24603         UNSPEC_PACI1716, UNSPEC_PACISP, UNSPEC_XPACLRI): New unspecs.
24604         ("*do_return"): Generate combined instructions according to key index.
24605         ("<pauth_mnem_prefix>sp", "<pauth_mnem_prefix1716", "xpaclri"): New.
24606         * config/aarch64/iterators.md (PAUTH_LR_SP, PAUTH_17_16): New integer
24607         iterators.
24608         (pauth_mnem_prefix, pauth_hint_num_a): New integer attributes.
24609         * config/aarch64/aarch64.opt (msign-return-address=): New.
24610         * doc/extend.texi (AArch64 Function Attributes): Documents
24611         "sign-return-address=".
24612         * doc/invoke.texi (AArch64 Options): Documents "-msign-return-address=".
24614 2017-01-19  Matthew Fortune  <matthew.fortune@imgtec.com>
24616         * doc/invoke.texi: Add missing -mlxc1-sxc1 options to
24617         overall option summary.
24619 2017-01-19  Jiong Wang  <jiong.wang@arm.com>
24621         * config/aarch64/aarch64-arches.def: New entry for "armv8.3-a".
24622         * config/aarch64/aarch64.h (AARCH64_FL_V8_3, AARCH64_FL_FOR_ARCH8_3,
24623         AARCH64_ISA_V8_3, TARGET_ARMV8_3): New.
24624         * doc/invoke.texi (AArch64 Options): Document "armv8.3-a".
24626 2017-01-19  Michael Meissner  <meissner@linux.vnet.ibm.com>
24628         * config/rs6000/rs6000-cpus.def (ISA_3_0_MASKS_SERVER): Enable
24629         -mpower9-minmax by default for -mcpu=power9.
24630         (ISA_3_MASKS_IEEE): Require -mvsx-small-integer to enable IEEE
24631         128-bit floating point.
24633 2017-01-20  Alan Modra  <amodra@gmail.com>
24635         * config/rs6000/rs6000.md (cmpstrnsi, cmpstrsi): Fail if
24636         optimizing for size.
24638 2017-01-20  Alan Modra  <amodra@gmail.com>
24640         PR target/79144
24641         * config/rs6000/rs6000.c (expand_strn_compare): Get the asm name
24642         for strcmp and strncmp from corresponding builtin decl.
24644 2017-01-19  Uros Bizjak  <ubizjak@gmail.com>
24646         * config.gcc (x86_64-*-rtems*): Use i386/rtemself.h
24647         instead of i386/rtems-64.h.
24648         * config/i386/rtems-64.h: Remove.
24650 2017-01-19  Uros Bizjak  <ubizjak@gmail.com>
24652         PR target/78478
24653         Revert:
24654         2013-11-05  Uros Bizjak  <ubizjak@gmail.com>
24656         * config/i386/rtemself.h (LONG_DOUBLE_TYPE_SIZE): New define.
24658 2017-01-19  Tamar Christina  <tamar.christina@arm.com>
24660         * config/aarch64/aarch64.c (aarch64_simd_gen_const_vector_dup):
24661         Change int to HOST_WIDE_INT.
24662         * config/aarch64/aarch64-protos.h
24663         (aarch64_simd_gen_const_vector_dup): Likewise.
24664         * config/aarch64/aarch64-simd.md: Add copysign<mode>3.
24666 2017-01-19  David Malcolm  <dmalcolm@redhat.com>
24668         * langhooks-def.h (lhd_type_for_size): New decl.
24669         (LANG_HOOKS_TYPE_FOR_SIZE): Define as lhd_type_for_size.
24670         * langhooks.c (lhd_type_for_size): New function, taken from
24671         lto_type_for_size.
24673 2017-01-19  Pat Haugen  <pthaugen@us.ibm.com>
24675         * config/rs6000/power9.md (power9-alu): Remove 'cmp' type and add
24676         define_bypass for CR latency.
24677         (power9-cracked-alu): Update bypass latency and remove power9-branch.
24678         (power9-alu2): Add define_bypass for CR latency.
24679         (power9-cmp): New.
24680         (power9-mul): Update insn latency.
24681         (power9-mul-compare): Update insn latency, bypass latency and remove
24682         power9-branch.
24684 2016-01-19  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
24686         * config/aarch64/aarch64-protos.h (aarch64_nopcrelative_literal_loads):
24687         Delete.
24688         * config/aarch64/aarch64.md
24689         (aarch64_reload_movcp<GPF_TF:mode><P:mode>): Delete reference to
24690         aarch64_nopcrelative_literal_loads.
24691         (aarch64_reload_movcp<VALL:mode><P:mode>): Likewise.
24693 2017-01-19  Chenghua Xu  <paul.hua.gm@gmail.com>
24695         * config/mips/mips.h (ISA_HAS_FUSED_MADD4): Enable for
24696         TARGET_LOONGSON_3A.
24697         (ISA_HAS_UNFUSED_MADD4): Exclude TARGET_LOONGSON_3A.
24699 2017-01-19  Doug Gilmore  <doug.gilmore@imgtec.com>
24701         PR target/78176
24702         * config.gcc (supported_defaults): Add lxc1-sxc1.
24703         (with_lxc1_sxc1): Add validation.
24704         (all_defaults): Add lxc1-sxc1.
24705         * config/mips/mips.opt (mlxc1-sxc1): New option.
24706         * config/mips/mips.h (OPTION_DEFAULT_SPECS): Add a default for
24707         mlxc1-sxc1.
24708         (TARGET_CPU_CPP_BUILTINS): Add builtin_define for
24709         __mips_no_lxc1_sxc1.
24710         (ISA_HAS_LXC1_SXC1): Gate with mips_lxc1_sxc1.
24711         * doc/invoke.texi (-mlxc1-sxc1): Document the new option.
24712         * doc/install.texi (--with-lxc1-sxc1): Document the new option.
24714 2017-01-19  Richard Biener  <rguenther@suse.de>
24716         PR tree-optimization/72488
24717         * tree-ssa-sccvn.c (run_scc_vn): When we abort the VN make
24718         sure to restore SSA info.
24719         * tree-ssa.c (verify_ssa): Verify SSA info is not shared.
24721 2017-01-19  Richard Earnshaw  <rearnsha@arm.com>
24723         PR rtl-optimization/79121
24724         * expr.c (expand_expr_real_2, case LSHIFT_EXPR): Look at the signedness
24725         of the inner type when shifting an extended value.
24727 2017-01-17  Jan Hubicka  <hubicka@ucw.cz>
24729         PR lto/78407
24730         * symtab.c (symtab_node::equal_address_to): Fix comparing of
24731         interposable aliases.
24733 2017-01-18  Peter Bergner  <bergner@vnet.ibm.com>
24735         PR target/78516
24736         * config/rs6000/spe.md (mov_si<mode>_e500_subreg0): Fix constraints.
24737         Use the evmergelohi instruction.
24738         (mov_si<mode>_e500_subreg4_2_le): Likewise.
24739         (mov_sitf_e500_subreg8_2_be): Likewise.
24740         (mov_sitf_e500_subreg12_2_le): Likewise.
24741         (mov_si<mode>_e500_subreg0_2_le): Fix constraints.
24742         (mov_si<mode>_e500_subreg4_2_be): Likewise.
24743         (mov_sitf_e500_subreg8_2_le): Likewise.
24744         (mov_sitf_e500_subreg12_2_be): Likewise.
24746 2017-01-18  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
24748         * config/rs6000/altivec.md (altivec_vbpermq): Change "type"
24749         attribute from vecsimple to vecperm.
24750         (altivec_vbpermq2): Likewise.
24752 2017-01-18  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
24754         PR target/79040
24755         * config/rs6000/altivec.h: Fix typo of vec_cntlz to vec_cnttz.
24757 2017-01-18  Aaron Sawdey  <acsawdey@linux.vnet.ibm.com>
24758         * config/rs6000/rs6000-protos.h (expand_strn_compare): Add arg.
24759         * config/rs6000/rs6000.c (expand_strn_compare): Add ability to expand
24760         strcmp. Fix bug where comparison didn't stop with zero byte. Fix
24761         case where N arg is SIZE_MAX.
24762         * config/rs6000/rs6000.md (cmpstrnsi): Args to expand_strn_compare.
24763         (cmpstrsi): Add pattern.
24765 2017-01-18  Michael Meissner  <meissner@linux.vnet.ibm.com>
24767         * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Add
24768         __builtin_vec_revb builtins.
24769         * config/rs6000/rs6000-builtins.def (P9V_BUILTIN_XXBRQ_V16QI): Add
24770         built-in functions to support generation of the ISA 3.0 XXBR<x>
24771         vector byte reverse instructions.
24772         (P9V_BUILTIN_XXBRQ_V1TI): Likewise.
24773         (P9V_BUILTIN_XXBRD_V2DI): Likewise.
24774         (P9V_BUILTIN_XXBRD_V2DF): Likewise.
24775         (P9V_BUILTIN_XXBGW_V4SI): Likewise.
24776         (P9V_BUILTIN_XXBGW_V4SF): Likewise.
24777         (P9V_BUILTIN_XXBGH_V8HI): Likewise.
24778         (P9V_BUILTIN_VEC_REVB): Likewise.
24779         * config/rs6000/vsx.md (p9_xxbrq_v1ti): New insns/expanders to
24780         generate the ISA 3.0 XXBR<x> vector byte reverse instructions.
24781         (p9_xxbrq_v16qi): Likewise.
24782         (p9_xxbrd_<mode>, VSX_D iterator): Likewise.
24783         (p9_xxbrw_<mode>, VSX_W iterator): Likewise.
24784         (p9_xxbrh_v8hi): Likewise.
24785         * config/rs6000/altivec.h (vec_revb): Define if ISA 3.0.
24786         * doc/extend.texi (RS/6000 Altivec Built-ins): Document the
24787         vec_revb built-in functions.
24789 2017-01-18  Uros Bizjak  <ubizjak@gmail.com>
24791         PR rtl-optimization/78952
24792         * config/i386/i386.md (any_extract): New code iterator.
24793         (*insvqi_2): Use any_extract for source operand.
24794         (*insvqi_3): Use any_shiftrt for source operand.
24796 2017-01-18  Wilco Dijkstra  <wdijkstr@arm.com>
24798         * config/aarch64/aarch64.c (aarch64_sched_adjust_priority)
24799         New function.
24800         (TARGET_SCHED_ADJUST_PRIORITY): Define target hook.
24802 2017-01-18  Matthias Klose  <doko@ubuntu.com>
24804         * doc/install.texi: Allow default for --with-target-bdw-gc-include.
24806 2016-01-18  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
24808         * config/rs6000/altivec.h (vec_bperm): Change #define.
24809         * config/rs6000/altivec.md (UNSPEC_VBPERMD): New enum constant.
24810         (altivec_vbpermq2): New define_insn.
24811         (altivec_vbpermd): Likewise.
24812         * config/rs6000/rs6000-builtin.def (VBPERMQ2): New monomorphic
24813         function interface.
24814         (VBPERMD): Likewise.
24815         (VBPERM): New polymorphic function interface.
24816         * config/rs6000/r6000-c.c (altivec_overloaded_builtins_table):
24817         Add entries for P9V_BUILTIN_VEC_VBPERM.
24818         * doc/extend.texi: Add interfaces for vec_bperm.
24820 2017-01-18  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
24822         * config/s390/s390-c.c (s390_expand_overloaded_builtin): Downcase
24823         first letter of error messages.
24824         (s390_resolve_overloaded_builtin): Likewise.
24825         * config/s390/s390.c (s390_expand_builtin): Likewise.
24826         (s390_invalid_arg_for_unprototyped_fn): Likewise.
24827         (s390_valid_target_attribute_inner_p): Likewise.
24828         * config/s390/s390.md ("tabort"): Likewise.
24830 2017-01-18  Toma Tabacu  <toma.tabacu@imgtec.com>
24832         * config/mips/mips.h (ISA_HAS_DIV3): Remove unused macro.
24833         (ISA_AVOID_DIV_HILO): New macro.
24834         (ISA_HAS_DIV): Use new ISA_AVOID_DIV_HILO macro.
24835         (ISA_HAS_DDIV): Likewise.
24837 2017-01-18  Markus Trippelsdorf  <markus@trippelsdorf.de>
24839         * doc/invoke.texi (fabi-version): Correct number of occurrences.
24841 2017-01-18  Markus Trippelsdorf  <markus@trippelsdorf.de>
24843         * doc/invoke.texi (fabi-version): Spelling fix.
24845 2017-01-18  Markus Trippelsdorf  <markus@trippelsdorf.de>
24847         PR c++/70182
24848         * doc/invoke.texi (fabi-version): Mention mangling fix for
24849         operator names.
24851 2017-01-18  Markus Trippelsdorf  <markus@trippelsdorf.de>
24853         PR c++/77489
24854         * doc/invoke.texi (fabi-version): Document discriminator mangling.
24856 2017-01-17  Segher Boessenkool  <segher@kernel.crashing.org>
24858         PR target/78875
24859         * config/rs6000/rs6000-opts.h (stack_protector_guard): New enum.
24860         * config/rs6000/rs6000.c (rs6000_option_override_internal): Handle
24861         the new options.
24862         * config/rs6000/rs6000.md (stack_protect_set): Handle the new more
24863         flexible settings.
24864         (stack_protect_test): Ditto.
24865         * config/rs6000/rs6000.opt (mstack-protector-guard=,
24866         mstack-protector-guard-reg=, mstack-protector-guard-offset=): New
24867         options.
24868         * doc/invoke.texi (Option Summary) [RS/6000 and PowerPC Options]:
24869         Add -mstack-protector-guard=, -mstack-protector-guard-reg=, and
24870         -mstack-protector-guard-offset=.
24871         (RS/6000 and PowerPC Options): Ditto.
24873 2017-01-17  Uros Bizjak  <ubizjak@gmail.com>
24875         * config/i386/i386.h (MASK_CLASS_P): New define.
24876         * config/i386/i386.c (inline_secondary_memory_needed): Ensure that
24877         there are no registers from different register sets also when
24878         mask registers are used.  Update function comment.
24879         * config/i386/i386.md (*movsi_internal): Split (*k/*krm) alternative
24880         to (*k/*r) and (*k/*km) alternatives.
24882 2017-01-17  Wilco Dijkstra  <wdijkstr@arm.com>
24884         * config/aarch64/aarch64.md (eh_return): Remove pattern and splitter.
24885         * config/aarch64/aarch64.h (AARCH64_EH_STACKADJ_REGNUM): Remove.
24886         (EH_RETURN_HANDLER_RTX): New define.
24887         * config/aarch64/aarch64.c (aarch64_frame_pointer_required):
24888         Force frame pointer in EH return functions.
24889         (aarch64_expand_epilogue): Add barrier for eh_return.
24890         (aarch64_final_eh_return_addr): Remove.
24891         (aarch64_eh_return_handler_rtx): New function.
24892         * config/aarch64/aarch64-protos.h (aarch64_final_eh_return_addr):
24893         Remove.
24894         (aarch64_eh_return_handler_rtx): New prototype.
24896 2017-01-17  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
24898         * config/rs6000/altivec.h (vec_rlmi): New #define.
24899         (vec_vrlnm): Likewise.
24900         (vec_rlnm): Likewise.
24901         * config/rs6000/altivec.md (UNSPEC_VRLMI): New UNSPEC enum value.
24902         (UNSPEC_VRLNM): Likewise.
24903         (VIlong): New mode iterator.
24904         (altivec_vrl<VI_char>mi): New define_insn.
24905         (altivec_vrl<VI_char>nm): Likewise.
24906         * config/rs6000/rs6000-builtin.def (VRLWNM): New monomorphic
24907         function entry.
24908         (VRLDNM): Likewise.
24909         (RLNM): New polymorphic function entry.
24910         (VRLWMI): New monomorphic function entry.
24911         (VRLDMI): Likewise.
24912         (RLMI): New polymorphic function entry.
24913         * config/rs6000/r6000-c.c (altivec_overloaded_builtin_table): Add
24914         new entries for P9V_BUILTIN_VEC_RLMI and P9V_BUILTIN_VEC_RLNM.
24915         * doc/extend.texi: Add description of vec_rlmi, vec_rlnm, and
24916         vec_vrlnm.
24918 2017-01-17  Jakub Jelinek  <jakub@redhat.com>
24920         PR debug/78839
24921         * dwarf2out.c (field_byte_offset): Restore the
24922         PCC_BITFIELD_TYPE_MATTERS behavior for INTEGER_CST DECL_FIELD_OFFSET
24923         and DECL_FIELD_BIT_OFFSET.  Use fold_build2 instead of build2 + fold.
24924         (analyze_variants_discr, gen_variant_part): Use fold_build2 instead
24925         of build2 + fold.
24927 2017-01-17  Eric Botcazou  <ebotcazou@adacore.com>
24929         PR ada/67205
24930         * config/aarch64/aarch64.c (TARGET_CUSTOM_FUNCTION_DESCRIPTORS): Define
24932 2017-01-17  Jakub Jelinek  <jakub@redhat.com>
24934         PR debug/71669
24935         * dwarf2out.c (add_data_member_location_attribute): For constant
24936         offset bitfield emit for -gdwarf-5 DW_AT_data_bit_offset attribute
24937         instead of DW_AT_data_member_location, DW_AT_bit_offset and
24938         DW_AT_byte_size attributes.
24940 2017-01-17  Eric Botcazou  <ebotcazou@adacore.com>
24942         * config/rs6000/rs6000.c (rs6000_emit_move): Also use a TOC reference
24943         after forcing to constant memory when the code model is medium.
24945 2017-01-17  Julia Koval  <julia.koval@intel.com>
24947         PR target/76731
24948         * config/i386/avx512fintrin.h
24949         (_mm512_i32gather_ps): Change __addr type to void const*.
24950         (_mm512_mask_i32gather_ps): Ditto.
24951         (_mm512_i32gather_pd): Ditto.
24952         (_mm512_mask_i32gather_pd): Ditto.
24953         (_mm512_i64gather_ps): Ditto.
24954         (_mm512_mask_i64gather_ps): Ditto.
24955         (_mm512_i64gather_pd): Ditto.
24956         (_mm512_mask_i64gather_pd): Ditto.
24957         (_mm512_i32gather_epi32): Ditto.
24958         (_mm512_mask_i32gather_epi32): Ditto.
24959         (_mm512_i32gather_epi64): Ditto.
24960         (_mm512_mask_i32gather_epi64): Ditto.
24961         (_mm512_i64gather_epi32): Ditto.
24962         (_mm512_mask_i64gather_epi32): Ditto.
24963         (_mm512_i64gather_epi64): Ditto.
24964         (_mm512_mask_i64gather_epi64): Ditto.
24965         (_mm512_i32scatter_ps): Change __addr type to void*.
24966         (_mm512_mask_i32scatter_ps): Ditto.
24967         (_mm512_i32scatter_pd): Ditto.
24968         (_mm512_mask_i32scatter_pd): Ditto.
24969         (_mm512_i64scatter_ps): Ditto.
24970         (_mm512_mask_i64scatter_ps): Ditto.
24971         (_mm512_i64scatter_pd): Ditto.
24972         (_mm512_mask_i64scatter_pd): Ditto.
24973         (_mm512_i32scatter_epi32): Ditto.
24974         (_mm512_mask_i32scatter_epi32): Ditto.
24975         (_mm512_i32scatter_epi64): Ditto.
24976         (_mm512_mask_i32scatter_epi64): Ditto.
24977         (_mm512_i64scatter_epi32): Ditto.
24978         (_mm512_mask_i64scatter_epi32): Ditto.
24979         (_mm512_i64scatter_epi64): Ditto.
24980         (_mm512_mask_i64scatter_epi64): Ditto.
24981         * config/i386/avx512pfintrin.h
24982         (_mm512_mask_prefetch_i32gather_pd): Change __addr type to void const*.
24983         (_mm512_mask_prefetch_i32gather_ps): Ditto.
24984         (_mm512_mask_prefetch_i64gather_pd): Ditto.
24985         (_mm512_mask_prefetch_i64gather_ps): Ditto.
24986         (_mm512_prefetch_i32scatter_pd): Change __addr type to void*.
24987         (_mm512_prefetch_i32scatter_ps): Ditto.
24988         (_mm512_mask_prefetch_i32scatter_pd): Ditto.
24989         (_mm512_mask_prefetch_i32scatter_ps): Ditto.
24990         (_mm512_prefetch_i64scatter_pd): Ditto.
24991         (_mm512_prefetch_i64scatter_ps): Ditto.
24992         (_mm512_mask_prefetch_i64scatter_pd): Ditto.
24993         (_mm512_mask_prefetch_i64scatter_ps): Ditto.
24994         * config/i386/avx512vlintrin.h
24995         (_mm256_mmask_i32gather_ps): Change __addr type to void const*.
24996         (_mm_mmask_i32gather_ps): Ditto.
24997         (_mm256_mmask_i32gather_pd): Ditto.
24998         (_mm_mmask_i32gather_pd): Ditto.
24999         (_mm256_mmask_i64gather_ps): Ditto.
25000         (_mm_mmask_i64gather_ps): Ditto.
25001         (_mm256_mmask_i64gather_pd): Ditto.
25002         (_mm_mmask_i64gather_pd): Ditto.
25003         (_mm256_mmask_i32gather_epi32): Ditto.
25004         (_mm_mmask_i32gather_epi32): Ditto.
25005         (_mm256_mmask_i32gather_epi64): Ditto.
25006         (_mm_mmask_i32gather_epi64): Ditto.
25007         (_mm256_mmask_i64gather_epi32): Ditto.
25008         (_mm_mmask_i64gather_epi32): Ditto.
25009         (_mm256_mmask_i64gather_epi64): Ditto.
25010         (_mm_mmask_i64gather_epi64): Ditto.
25011         (_mm256_i32scatter_ps): Change __addr type to void*.
25012         (_mm256_mask_i32scatter_ps): Ditto.
25013         (_mm_i32scatter_ps): Ditto.
25014         (_mm_mask_i32scatter_ps): Ditto.
25015         (_mm256_i32scatter_pd): Ditto.
25016         (_mm256_mask_i32scatter_pd): Ditto.
25017         (_mm_i32scatter_pd): Ditto.
25018         (_mm_mask_i32scatter_pd): Ditto.
25019         (_mm256_i64scatter_ps): Ditto.
25020         (_mm256_mask_i64scatter_ps): Ditto.
25021         (_mm_i64scatter_ps): Ditto.
25022         (_mm_mask_i64scatter_ps): Ditto.
25023         (_mm256_i64scatter_pd): Ditto.
25024         (_mm256_mask_i64scatter_pd): Ditto.
25025         (_mm_i64scatter_pd): Ditto.
25026         (_mm_mask_i64scatter_pd): Ditto.
25027         (_mm256_i32scatter_epi32): Ditto.
25028         (_mm256_mask_i32scatter_epi32): Ditto.
25029         (_mm_i32scatter_epi32): Ditto.
25030         (_mm_mask_i32scatter_epi32): Ditto.
25031         (_mm256_i32scatter_epi64): Ditto.
25032         (_mm256_mask_i32scatter_epi64): Ditto.
25033         (_mm_i32scatter_epi64): Ditto.
25034         (_mm_mask_i32scatter_epi64): Ditto.
25035         (_mm256_i64scatter_epi32): Ditto.
25036         (_mm256_mask_i64scatter_epi32): Ditto.
25037         (_mm_i64scatter_epi32): Ditto.
25038         (_mm_mask_i64scatter_epi32): Ditto.
25039         (_mm256_i64scatter_epi64): Ditto.
25040         (_mm256_mask_i64scatter_epi64): Ditto.
25041         (_mm_i64scatter_epi64): Ditto.
25042         (_mm_mask_i64scatter_epi64): Ditto.
25043         * config/i386/i386-builtin-types.def (V16SF_V16SF_PCFLOAT_V16SI_HI_INT)
25044         (V8DF_V8DF_PCDOUBLE_V8SI_QI_INT, V8SF_V8SF_PCFLOAT_V8DI_QI_INT)
25045         (V8DF_V8DF_PCDOUBLE_V8DI_QI_INT, V16SI_V16SI_PCINT_V16SI_HI_INT)
25046         (V8DI_V8DI_PCINT64_V8SI_QI_INT, V8SI_V8SI_PCINT_V8DI_QI_INT)
25047         (V8DI_V8DI_PCINT64_V8DI_QI_INT, V2DF_V2DF_PCDOUBLE_V4SI_QI_INT)
25048         (V4DF_V4DF_PCDOUBLE_V4SI_QI_INT, V2DF_V2DF_PCDOUBLE_V2DI_QI_INT)
25049         (V4DF_V4DF_PCDOUBLE_V4DI_QI_INT, V4SF_V4SF_PCFLOAT_V4SI_QI_INT)
25050         (V8SF_V8SF_PCFLOAT_V8SI_QI_INT, V4SF_V4SF_PCFLOAT_V2DI_QI_INT)
25051         (V4SF_V4SF_PCFLOAT_V4DI_QI_INT, V2DI_V2DI_PCINT64_V4SI_QI_INT)
25052         (V4DI_V4DI_PCINT64_V4SI_QI_INT, V2DI_V2DI_PCINT64_V2DI_QI_INT)
25053         (V4DI_V4DI_PCINT64_V4DI_QI_INT, V4SI_V4SI_PCINT_V4SI_QI_INT)
25054         (V8SI_V8SI_PCINT_V8SI_QI_INT, V4SI_V4SI_PCINT_V2DI_QI_INT)
25055         (V4SI_V4SI_PCINT_V4DI_QI_INT, VOID_PFLOAT_HI_V16SI_V16SF_INT)
25056         (VOID_PFLOAT_QI_V8SI_V8SF_INT, VOID_PFLOAT_QI_V4SI_V4SF_INT)
25057         (VOID_PDOUBLE_QI_V8SI_V8DF_INT, VOID_PDOUBLE_QI_V4SI_V4DF_INT)
25058         (VOID_PDOUBLE_QI_V4SI_V2DF_INT, VOID_PFLOAT_QI_V8DI_V8SF_INT)
25059         (VOID_PFLOAT_QI_V4DI_V4SF_INT, VOID_PFLOAT_QI_V2DI_V4SF_INT)
25060         (VOID_PDOUBLE_QI_V8DI_V8DF_INT, VOID_PDOUBLE_QI_V4DI_V4DF_INT)
25061         (VOID_PDOUBLE_QI_V2DI_V2DF_INT, VOID_PINT_HI_V16SI_V16SI_INT)
25062         (VOID_PINT_QI_V8SI_V8SI_INT, VOID_PINT_QI_V4SI_V4SI_INT)
25063         (VOID_PLONGLONG_QI_V8SI_V8DI_INT, VOID_PLONGLONG_QI_V4SI_V4DI_INT)
25064         (VOID_PLONGLONG_QI_V4SI_V2DI_INT, VOID_PINT_QI_V8DI_V8SI_INT)
25065         (VOID_PINT_QI_V4DI_V4SI_INT, VOID_PINT_QI_V2DI_V4SI_INT)
25066         (VOID_PLONGLONG_QI_V8DI_V8DI_INT, VOID_QI_V8SI_PCINT64_INT_INT)
25067         (VOID_PLONGLONG_QI_V4DI_V4DI_INT, VOID_PLONGLONG_QI_V2DI_V2DI_INT)
25068         (VOID_HI_V16SI_PCINT_INT_INT, VOID_QI_V8DI_PCINT64_INT_INT)
25069         (VOID_QI_V8DI_PCINT_INT_INT): Remove.
25070         (V16SF_V16SF_PCVOID_V16SI_HI_INT,  V8DF_V8DF_PCVOID_V8SI_QI_INT)
25071         (V8SF_V8SF_PCVOID_V8DI_QI_INT, V8DF_V8DF_PCVOID_V8DI_QI_INT)
25072         (V16SI_V16SI_PCVOID_V16SI_HI_INT, V8DI_V8DI_PCVOID_V8SI_QI_INT)
25073         (V8SI_V8SI_PCVOID_V8DI_QI_INT, V8DI_V8DI_PCVOID_V8DI_QI_INT)
25074         (VOID_PVOID_HI_V16SI_V16SF_INT, VOID_PVOID_QI_V8SI_V8DF_INT)
25075         (VOID_PVOID_QI_V8DI_V8SF_INT, VOID_PVOID_QI_V8DI_V8DF_INT)
25076         (VOID_PVOID_HI_V16SI_V16SI_INT, VOID_PVOID_QI_V8SI_V8DI_INT)
25077         (VOID_PVOID_QI_V8DI_V8SI_INT, VOID_PVOID_QI_V8DI_V8DI_INT)
25078         (V2DF_V2DF_PCVOID_V4SI_QI_INT, V4DF_V4DF_PCVOID_V4SI_QI_INT)
25079         (V2DF_V2DF_PCVOID_V2DI_QI_INT, V4DF_V4DF_PCVOID_V4DI_QI_INT
25080         (V4SF_V4SF_PCVOID_V4SI_QI_INT, V8SF_V8SF_PCVOID_V8SI_QI_INT)
25081         (V4SF_V4SF_PCVOID_V2DI_QI_INT, V4SF_V4SF_PCVOID_V4DI_QI_INT)
25082         (V2DI_V2DI_PCVOID_V4SI_QI_INT, V4DI_V4DI_PCVOID_V4SI_QI_INT)
25083         (V2DI_V2DI_PCVOID_V2DI_QI_INT, V4DI_V4DI_PCVOID_V4DI_QI_INT)
25084         (V4SI_V4SI_PCVOID_V4SI_QI_INT, V8SI_V8SI_PCVOID_V8SI_QI_INT)
25085         (V4SI_V4SI_PCVOID_V2DI_QI_INT, V4SI_V4SI_PCVOID_V4DI_QI_INT)
25086         (VOID_PVOID_QI_V8SI_V8SF_INT, VOID_PVOID_QI_V4SI_V4SF_INT)
25087         (VOID_PVOID_QI_V4SI_V4DF_INT, VOID_PVOID_QI_V4SI_V2DF_INT)
25088         (VOID_PVOID_QI_V4DI_V4SF_INT, VOID_PVOID_QI_V2DI_V4SF_INT)
25089         (VOID_PVOID_QI_V4DI_V4DF_INT, VOID_PVOID_QI_V2DI_V2DF_INT)
25090         (VOID_PVOID_QI_V8SI_V8SI_INT, VOID_PVOID_QI_V4SI_V4SI_INT)
25091         (VOID_PVOID_QI_V4SI_V4DI_INT, VOID_PVOID_QI_V4SI_V2DI_INT)
25092         (VOID_PVOID_QI_V4DI_V4SI_INT, VOID_PVOID_QI_V2DI_V4SI_INT)
25093         (VOID_PVOID_QI_V4DI_V4DI_INT, VOID_PVOID_QI_V2DI_V2DI_INT)
25094         (VOID_QI_V8SI_PCVOID_INT_INT, VOID_HI_V16SI_PCVOID_INT_INT)
25095         (VOID_QI_V8DI_PCVOID_INT_INT): Add.
25096         * config/i386/i386.c (ix86_init_mmx_sse_builtins): Adjust builtin
25097         definitions accordingly.
25099 2017-01-17  Kito Cheng  <kito.cheng@gmail.com>
25100             Kuan-Lin Chen  <kuanlinchentw@gmail.com>
25102         PR target/79079
25103         * internal-fn.c (expand_mul_overflow): Use convert_modes instead of
25104         gen_lowpart.
25106 2017-01-17  Vladimir Makarov  <vmakarov@redhat.com>
25108         PR target/79058
25109         * ira-conflicts.c (ira_build_conflicts): Update total conflict
25110         hard regs for inner regno.
25112 2017-01-17  Martin Liska  <mliska@suse.cz>
25114         PR ipa/71207
25115         * ipa-polymorphic-call.c (contains_type_p): Fix wrong
25116         assumption and add comment.
25118 2017-01-17  Nathan Sidwell  <nathan@acm.org>
25120         * ipa-visibility.c (localize_node): New function, broken out of ...
25121         (function_and_variable_visibility): ... here. Call it.
25123 2017-01-17  Jan Hubicka  <hubicka@ucw.cz>
25125         PR middle-end/77445
25126         * tree-ssa-threadupdate.c (remove_ctrl_stmt_and_useless_edges):
25127         correctly set frequency of oudgoing edge.
25128         (duplicate_thread_path): Fix profile updating.
25130 2017-01-17  Jakub Jelinek  <jakub@redhat.com>
25132         PR other/79046
25133         * configure.ac: Add GCC_BASE_VER.
25134         * Makefile.in (version): Use @get_gcc_base_ver@ instead of cat to get
25135         version from BASE-VER file.
25136         (CFLAGS-gcc.o): Add -DBASEVER=$(BASEVER_s).
25137         (gcc.o): Depend on $(BASEVER).
25138         * common.opt (dumpfullversion): New option.
25139         * gcc.c (driver_handle_option): Handle OPT_dumpfullversion.
25140         * doc/invoke.texi: Document -dumpfullversion.
25141         * doc/install.texi: Document --with-gcc-major-version-only.
25142         * configure: Regenerated.
25144 2017-01-17  Richard Biener  <rguenther@suse.de>
25146         PR tree-optimization/71433
25147         * tree-vrp.c (register_new_assert_for): Merge same asserts
25148         on all incoming edges.
25149         (process_assert_insertions_for): Handle insertions at the
25150         beginning of BBs.
25152 2017-01-17  Gerald Pfeifer  <gerald@pfeifer.com>
25154         * config/i386/cygwin.h (LIBGCJ_SONAME): Remove.
25155         * config/i386/mingw32.h (LIBGCJ_SONAME): Remove.
25157 2017-01-17  Kaz Kojima  <kkojima@gcc.gnu.org>
25159         PR target/78633
25160         * config/sh/sh.md (cmpeqsi_t+1): Call copy_rtx to avoid invalid
25161         RTL sharing.
25163 2017-01-17  Alan Modra  <amodra@gmail.com>
25165         PR target/79066
25166         * config/rs6000/rs6000.md (elf_high, elf_low): Disable when pic.
25167         * config/rs6000/rs6000.c (rs6000_emit_allocate_stack): Don't allow
25168         symbolic stack limit when pic.
25170 2017-01-16  Martin Sebor  <msebor@redhat.com>
25172         PR tree-optimization/78608
25173         * gimple-ssa-sprintf.c (tree_digits): Avoid negating TYPE_MIN.
25175 2017-01-16  Jeff Law  <law@redhat.com>
25177         Revert:
25178         2016-12-02  Tadek Kijkowski  <tkijkowski@gmail.com>
25179         * Makefile.in (PREPROCESSOR_DEFINES): Add a level of indirection
25180         for several include directories that may be relative to sysroot.
25181         * config/i386/x-mingw32 (gplus_includedir): Define.
25182         (gplus_tool_includedir, gplus_backward_include_dir): Likewise.
25183         (native_system_includedir): Likewise.
25184         * config/i386/mingw32.h (STANDARD_STARTFILE_PREFIX_1): Do not
25185         override if TARGET_SYSTEM_ROOT is defined.
25186         (NATIVE_SYSTEM_HEADER_DIR): Likewise.
25188         PR tree-optimization/79090
25189         PR tree-optimization/33562
25190         PR tree-optimization/61912
25191         PR tree-optimization/77485
25192         * tree-ssa-dse.c (compute_trims): Accept STMT argument.  Dump STMT
25193         and computed trims into the dump file.
25195 2017-01-17  Uros Bizjak  <ubizjak@gmail.com>
25197         * config/i386/i386.h (LIMIT_RELOAD_CLASS): Remove.
25199 2017-01-16  Jakub Jelinek  <jakub@redhat.com>
25201         PR c/79089
25202         * gimplify.c (gimplify_init_constructor): If want_value and
25203         object == lhs, unshare lhs to avoid invalid tree sharing.  Formatting
25204         fix.
25206         PR target/79080
25207         * loop-doloop.c (doloop_modify): Call unshare_all_rtl_in_chain on
25208         sequence.  Formatting fixes.
25209         (doloop_optimize): Formatting fixes.
25211         PR driver/49726
25212         * gcc.c (debug_level_greater_than_spec_func): New function.
25213         (static_spec_functions): Add debug-level-gt spec function.
25214         (ASM_DEBUG_SPEC, cpp_options): Use %:debug-level-gt(0) instead of
25215         !g0.
25216         * config/darwin.h (DSYMUTIL_SPEC, ASM_DEBUG_SPEC): Likewise.
25217         * config/darwin9.h (DSYMUTIL_SPEC, ASM_DEBUG_SPEC): Likewise.
25218         * common.opt (g, gcoff, gdwarf, gdwarf-, ggdb, gno-pubnames,
25219         gpubnames, ggnu-pubnames, gno-record-gcc-switches,
25220         grecord-gcc-switches, gno-strict-dwarf, gstrict-dwarf, gstabs,
25221         gstabs+, gtoggle, gvms, gxcoff, gxcoff+): Add Driver flag.
25223 2017-01-16  Uros Bizjak  <ubizjak@gmail.com>
25225         * config/i386/i386.h (HARD_REGNO_CALLER_SAVE_MODE): Apply HImode and
25226         QImode fixups to general and mask registers only.
25228 2017-01-16  Carl Love  <cel@us.ibm.com>
25230         * config/rs6000/rs6000-c (altivec_overloaded_builtins): Add support
25231         for built-in functions
25232         vector signed char vec_nabs (vector signed char)
25233         vector signed short vec_nabs (vector signed short)
25234         vector signed int vec_nabs (vector signed int)
25235         vector signed long long vec_nabs (vector signed long long)
25236         vector float vec_nabs (vector float)
25237         vector double vec_nabs (vector double)
25238         * config/rs6000/rs6000-builtin.def: Add definitions for NABS functions
25239         and NABS overload.
25240         * config/rs6000/altivec.md: New define_expand nabs<mode>2 types
25241         * config/rs6000/altivec.h: New define for vec_nabs built-in function.
25242         * doc/extend.texi: Update the documentation file for the new built-in
25243         functions.
25245 2017-01-16  Martin Sebor  <msebor@redhat.com>
25247         * gimple-ssa-sprintf.c (format_directive): Correct a typo in a warning
25248         message.
25250 2017-01-16  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
25252         * config/rs6000/rs6000.c (rtx_is_swappable_p): Change
25253         UNSPEC_VSX__XXSPLTD to require special splat handling.
25255 2017-01-16  David Malcolm  <dmalcolm@redhat.com>
25257         PR bootstrap/78616
25258         * system.h: Poison strndup.
25260 2017-01-16  Alan Modra  <amodra@gmail.com>
25262         PR target/79098
25263         * config/rs6000/rs6000.c (rs6000_legitimate_combined_insn): Don't
25264         use a switch.
25266 2017-01-16  Georg-Johann Lay  <avr@gjlay.de>
25268         * config/avr/avr.h (BRANCH_COST) [reload_completed]: Increase by 4.
25270 2017-01-15  Uros Bizjak  <ubizjak@gmail.com>
25272         * config/i386/i386.c (ix86_legitimate_combined_insn): Do not
25273         call recog here.  Assert that INSN_CODE (insn) is non-negative.
25275 2017-01-15  Segher Boessenkool  <segher@kernel.crashing.org>
25277         PR target/72749
25278         * cfgrtl.c (rtl_split_edge): Also patch jump insns that jump to the
25279         fallthrough.
25280         * haifa-sched.c (dump_insn_stream): Don't crash if there is a label
25281         in the currently scheduled RTL fragment.
25283 2017-01-15  Segher Boessenkool  <segher@kernel.crashing.org>
25285         PR rtl-optimization/78751
25286         * ifcvt.c (find_cond_trap): If we generated a non-existing insn,
25287         give up.
25289 2017-01-14  Jeff Law  <law@redhat.com>
25291         PR tree-optimization/79090
25292         * tree-ssa-dse.c (valid_ao_ref_for_dse): Reject zero length and
25293         variable length stores.
25294         (compute_trims): Delete dead assignment to *trim_tail.
25295         (dse_dom_walker::dse_optimize_stmt): Optimize mem* calls with
25296         zero length.
25298 2017-01-14  Bernd Schmidt  <bschmidt@redhat.com>
25300         PR rtl-optimization/78626
25301         PR rtl-optimization/78727
25302         * cprop.c (one_cprop_pass): Collect unconditional traps in the middle
25303         of a block, and split such blocks after everything else is finished.
25305 2017-01-14  Alan Modra  <amodra@gmail.com>
25307         PR target/72749
25308         * combine.c (recog_for_combine_1): Set INSN_CODE before calling
25309         target legitimate_combined_insn.
25310         * config/rs6000/rs6000.c (TARGET_LEGITIMATE_COMBINED_INSN): Define.
25311         (rs6000_legitimate_combined_insn): New function.
25312         * config/rs6000/rs6000.md (UNSPEC_DOLOOP): Delete, and remove
25313         all uses.
25314         (ctr<mode>_internal3): Rename from *ctr<mode>_internal5.
25315         (ctr<mode>_internal4): Rename from *ctr<mode>_internal6.
25316         (ctr<mode>_internal1, ctr<mode>_internal2): Remove '*' from name.
25318 2017-01-14  Gerald Pfeifer  <gerald@pfeifer.com>
25320         * doc/frontends.texi (G++ and GCC): Remove references to Java.
25322 2017-01-13  Jeff Law  <law@redhat.com>
25324         PR tree-optimization/33562
25325         PR tree-optimization/61912
25326         PR tree-optimization/77485
25327         * tree-ssa-dse.c (delete_dead_call): Accept gsi rather than
25328         a statement.
25329         (delete_dead_assignment): Likewise.
25330         (dse_dom_walker::dse_optimize_stmt): Pass in the gsi rather than
25331         statement to delete_dead_call and delete_dead_assignment.
25333 2017-01-13  David Malcolm  <dmalcolm@redhat.com>
25335         PR c/78304
25336         * substring-locations.c (format_warning_va): Strengthen case 1 so
25337         that both endpoints of the substring must be within the format
25338         range for just the substring to be printed.
25340 2017-01-13  Uros Bizjak  <ubizjak@gmail.com>
25342         * config/i386/i386.opt (msgx): Use ix86_isa_flags2 variable.
25343         * config/i386/i386.c (ix86_target_string): Add missing options
25344         to isa_opts and reorder options by implied ISAs.  Rename isa_opts2 to
25345         isa2_opts, ix86_flag_opts to flag2_opts, ix86_target_other to
25346         flags_other and ix86_target_other to flags2_other.  Display unknown
25347         isa2 options.
25348         (ix86_valid_target_attribute_inner_p): Add missing options and
25349         reorder options by implied ISAs, as in ix86_target_string.
25351 2017-01-13  Richard Sandiford  <richard.sandiford@arm.com>
25353         * hash-table.h (hash_table::too_empty_p): New function.
25354         (hash_table::expand): Use it.
25355         (hash_table::traverse): Likewise.
25356         (hash_table::empty_slot): Use sizeof (value_type) instead of
25357         sizeof (PTR) to convert bytes to elements.  Shrink the table
25358         if the current size is excessive for the current number of
25359         elements.
25361 2017-01-13  Richard Sandiford  <richard.sandiford@arm.com>
25363         * ira-costs.c (record_reg_classes): Break from the inner loop
25364         early once alt_fail is known to be true.  Update outer loop
25365         handling accordingly.
25367 2017-01-13  Jeff Law  <law@redhat.com>
25369         * tree-ssa-dse.c (decrement_count): New function.
25370         (increment_start_addr, maybe_trim_memstar_call): Likewise.
25371         (dse_dom_walker::optimize_stmt): Call maybe_trim_memstar_call directly
25372         when we know the partially dead statement is a mem* function.
25374         PR tree-optimization/61912
25375         PR tree-optimization/77485
25376         * tree-ssa-dse.c: Include expr.h.
25377         (maybe_trim_constructor_store): New function.
25378         (maybe_trim_partially_dead_store): Call maybe_trim_constructor_store.
25380         PR tree-optimization/33562
25381         PR tree-optimization/61912
25382         PR tree-optimization/77485
25383         * doc/invoke.texi: Document new dse-max-object-size param.
25384         * params.def (PARM_DSE_MAX_OBJECT_SIZE): New PARAM.
25385         * tree-ssa-dse.c: Include params.h.
25386         (dse_store_status): New enum.
25387         (initialize_ao_ref_for_dse): New, partially extracted from
25388         dse_optimize_stmt.
25389         (valid_ao_ref_for_dse, normalize_ref): New.
25390         (setup_live_bytes_from_ref, compute_trims): Likewise.
25391         (clear_bytes_written_by, maybe_trim_complex_store): Likewise.
25392         (maybe_trim_partially_dead_store): Likewise.
25393         (maybe_trim_complex_store): Likewise.
25394         (dse_classify_store): Renamed from dse_possibly_dead_store_p.
25395         Track what bytes live from the original store.  Return tri-state
25396         for dead, partially dead or live.
25397         (dse_dom_walker): Add constructor, destructor and new private members.
25398         (delete_dead_call, delete_dead_assignment): New extracted from
25399         dse_optimize_stmt.
25400         (dse_optimize_stmt): Make a member of dse_dom_walker.
25401         Use initialize_ao_ref_for_dse.
25403         PR tree-optimization/33562
25404         PR tree-optimization/61912
25405         PR tree-optimization/77485
25406         * sbitmap.h (bitmap_count_bits): Prototype.
25407         (bitmap_clear_range, bitmap_set_range): Likewise.
25408         * sbitmap.c (bitmap_clear_range): New function.
25409         (bitmap_set_range, sbitmap_popcount, bitmap_count_bits): Likewise.
25411 2017-01-13  Martin Liska  <mliska@suse.cz>
25413         PR ipa/79043
25414         * function.c (set_cfun): Add new argument force.
25415         * function.h (set_cfun): Likewise.
25416         * ipa-inline-transform.c (inline_call): Use the function when
25417         strict alising from is dropped for function we inline to.
25419 2017-01-13  Richard Biener  <rguenther@suse.de>
25421         * tree-pretty-print.c (dump_generic_node): Fix inverted condition
25422         for dumping GIMPLE INTEGER_CSTs.
25424 2017-01-13  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
25426         * config/sol2.h (TARGET_OS_CPP_BUILTINS): Define __STDC_VERSION__
25427         to 201112L since C++17.
25429 2017-01-13  Maxim Ostapenko  <m.ostapenko@samsung.com>
25431         PR sanitizer/78887
25432         * asan.c (asan_needs_odr_indicator_p): Don't emit ODR indicators
25433         if -fsanitize=kernel-address is present.
25435 2017-01-13  Richard Biener  <rguenther@suse.de>
25437         * tree-pretty-print.c (dump_generic_node): Dump INTEGER_CSTs
25438         as _Literal ( type ) number in case usual suffixes do not
25439         preserve all information.
25441 2017-01-13  Richard Biener  <rguenther@suse.de>
25443         PR tree-optimization/77283
25444         * gimple-ssa-split-paths.c: Include gimple-ssa.h, tree-phinodes.h
25445         and ssa-iterators.h.
25446         (is_feasible_trace): Implement a cost model based on joiner
25447         PHI node uses.
25449 2017-01-12  Michael Meissner  <meissner@linux.vnet.ibm.com>
25451         PR target/79004
25452         * config/rs6000/rs6000.md (FP_ISA3): Do not optimize converting
25453         char or short to __float128/_Float128 directly.
25455 2017-01-12  Martin Sebor  <msebor@redhat.com>
25457         to -Wformat-overflow.
25458         * gimple-ssa-sprintf.c (pass_sprintf_length::gate): Adjust.
25459         (min_bytes_remaining): Same.
25460         (get_string_length): Same.
25461         (format_string): Same.
25462         (format_directive): Same.
25463         (add_bytes): Same.
25464         (pass_sprintf_length::handle_gimple_call): Same.
25466 2017-01-12  Jakub Jelinek  <jakub@redhat.com>
25468         * gimple-ssa-sprintf.c (try_substitute_return_value): Remove
25469         info.nowrite calls with no lhs that can't throw.  Return bool
25470         whether gsi_remove has been called or not.
25471         (pass_sprintf_length::handle_gimple_call): Return bool whether
25472         try_substitute_return_value called gsi_remove.  Formatting fix.
25473         (pass_sprintf_length::execute): Don't use gsi_remove if
25474         handle_gimple_call returned true.
25476         PR bootstrap/79069
25477         * cfgrtl.c (rtl_tidy_fallthru_edge): For any_uncondjump_p that can't
25478         be removed due to side-effects, don't remove following barrier nor
25479         turn the successor edge into fallthru edge.
25481 2017-01-12  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
25483         PR target/79044
25484         * config/rs6000/rs6000.c (insn_is_swappable_p): Mark
25485         element-reversing loads and stores as not swappable.
25487 2017-01-12  Nathan Sidwell  <nathan@acm.org>
25488             Nicolai Stange  <nicstange@gmail.com>
25490         * combine.c (try_combine): Don't ignore result of overlap checking
25491         loop.  Combine overlap & asm check into single loop.
25493 2017-01-12  Richard Biener  <rguenther@suse.de>
25495         * tree-pretty-print.c (dump_generic_node): Provide -gimple
25496         variant for MEM_REF.  Sanitize INTEGER_CST for -gimple.
25498 2017-01-12  Richard Biener  <rguenther@suse.de>
25500         * tree.c (initialize_tree_contains_struct): Make TS_OPTIMIZATION
25501         and TS_TARGET_OPTION directly derive from TS_BASE.
25502         * tree-core.h (tree_optimization_option): Derive from tree_base.
25503         (tree_target_option): Likewise.
25505 2017-01-11  Uros Bizjak  <ubizjak@gmail.com>
25507         * config/i386/i386.c (memory_address_length): Increase len
25508         only when rip_relative_addr_p returns false.
25510 2017-01-11  Julia Koval  <julia.koval@intel.com>
25512         * common/config/i386/i386-common.c (OPTION_MASK_ISA_SGX_UNSET): New.
25513         (OPTION_MASK_ISA_SGX_SET): New.
25514         (ix86_handle_option): Handle OPT_msgx.
25515         * config.gcc: Added sgxintrin.h.
25516         * config/i386/driver-i386.c (host_detect_local_cpu): Detect sgx.
25517         * config/i386/i386-c.c (ix86_target_macros_internal): Define __SGX__.
25518         * config/i386/i386.c (ix86_target_string): Add -msgx.
25519         (PTA_SGX): New.
25520         (ix86_option_override_internal): Handle new options.
25521         (ix86_valid_target_attribute_inner_p): Add sgx.
25522         * config/i386/i386.h (TARGET_SGX, TARGET_SGX_P): New.
25523         * config/i386/i386.opt: Add msgx.
25524         * config/i386/sgxintrin.h: New file.
25525         * config/i386/x86intrin.h: Add sgxintrin.h.
25527 2017-01-11  Jakub Jelinek  <jakub@redhat.com>
25529         PR c++/71537
25530         * fold-const.c (maybe_nonzero_address): Return 1 for function
25531         local objects.
25532         (tree_single_nonzero_warnv_p): Don't handle function local objects
25533         here.
25535         PR c++/72813
25536         * gcc.c (default_compilers): Don't add -o %g.s for -S -save-temps
25537         of c-header.
25539 2017-01-11  David Malcolm  <dmalcolm@redhat.com>
25541         PR driver/78877
25542         * opts.c: Include "spellcheck.h"
25543         (struct string_fragment): New struct.
25544         (struct edit_distance_traits<const string_fragment &>): New
25545         struct.
25546         (get_closest_sanitizer_option): New function.
25547         (parse_sanitizer_options): Offer suggestions for unrecognized arguments.
25549 2017-01-11  Jakub Jelinek  <jakub@redhat.com>
25551         * dwarf2out.c (DWARF_COMPILE_UNIT_HEADER_SIZE): For DWARF5 decrease
25552         by 12.
25553         (DWARF_COMDAT_TYPE_UNIT_HEADER_SIZE): Always
25554         DWARF_COMPILE_UNIT_HEADER_SIZE plus 12.
25555         (DWARF_COMPILE_UNIT_SKELETON_HEADER_SIZE): Define.
25556         (calc_base_type_die_sizes): Use DWARF_COMPILE_UNIT_SKELETON_HEADER_SIZE
25557         for initial die_offset if dwarf_split_debug_info.
25558         (output_comp_unit): Use DWARF_COMPILE_UNIT_SKELETON_HEADER_SIZE for
25559         initial next_die_offset if dwo_id is non-NULL.  Don't emit padding
25560         fields.
25561         (output_skeleton_debug_sections): Formatting fix.  Use
25562         DWARF_COMPILE_UNIT_SKELETON_HEADER_SIZE instead of
25563         DWARF_COMPILE_UNIT_HEADER_SIZE.  Don't emit padding.
25565 2017-01-11  Wilco Dijkstra  <wdijkstr@arm.com>
25567         * config/arm/cortex-a53.md: Add bypasses for
25568         cortex_a53_r2f_cvt.
25569         (cortex_a53_r2f): Only use for transfers.
25570         (cortex_a53_f2r): Likewise.
25571         (cortex_a53_r2f_cvt): Add reservation for conversions.
25572         (cortex_a53_f2r_cvt): Likewise.
25574 2017-01-11  Tamar Christina  <tamar.christina@arm.com>
25576         * config/arm/arm_neon.h: Add __artificial__ and gnu_inline
25577         to all inlined functions, change static to extern.
25579 2017-01-11  Christophe Lyon  <christophe.lyon@linaro.org>
25581         PR target/78253
25582         * config/arm/arm.c (legitimize_pic_address): Handle reference to
25583         weak symbol.
25584         (arm_assemble_integer): Likewise.
25586 2017-01-11  Richard Earnshaw  <rearnsha@arm.com>
25588         * config.gcc: Use new awk script to check CPU, FPU and architecture
25589         parameters for --with-... options.
25590         * config/arm/parsecpu.awk: New file
25591         * config/arm/arm-cpus.in: New file.
25592         * config/arm/arm-opts.h: Include arm-cpu.h instead of processing .def
25593         files.
25594         * config/arm/arm.c: Include arm-cpu-data.h instead of processing .def
25595         files.
25596         * config/arm/t-arm: Update dependency rules.
25597         * common/config/arm/arm-common.c: Include arm-cpu-cdata.h instead
25598         of processing .def files.
25599         * config/arm/genopt.sh: Deleted.
25600         * config/arm/gentune.sh: Deleted.
25601         * config/arm/arm-cores.def: Deleted.
25602         * config/arm/arm-arches.def: Deleted.
25603         * config/arm/arm-fpus.def: Deleted.
25604         * config/arm/arm-tune.md: Regenerated.
25605         * config/arm/arm-tables.opt: Regenerated.
25606         * config/arm/arm-cpu.h: New generated file.
25607         * config/arm/arm-cpu-data.h: New generated file.
25608         * config/arm/arm-cpu-cdata.h: New generated file.
25610 2017-01-11  Maxim Ostapenko  <m.ostapenko@samsung.com>
25612         PR lto/79042
25613         * lto-cgraph.c (lto_output_varpool_node): Pack dynamically_initialized
25614         bit.
25615         (input_varpool_node): Unpack dynamically_initialized bit.
25617 2017-01-11  Eric Botcazou  <ebotcazou@adacore.com>
25619         PR rtl-optimization/79032
25620         * lra-constraints.c (simplify_operand_subreg): In the MEM case, test
25621         the alignment of the adjusted memory reference against that of MODE,
25622         instead of the alignment of the original memory reference.
25624 2017-01-11  Martin Jambor  <mjambor@suse.cz>
25626         * hsa.c (hsa_callable_function_p): Revert addition of DECL_ARTIFICIAL
25627         test.
25628         * ipa-hsa.c (process_hsa_functions): Only duplicate non-artificial
25629         decorated functions.
25631 2017-01-11  Richard Biener  <rguenther@suse.de>
25633         * tree-vrp.c (evrp_dom_walker::before_dom_children): Also
25634         set range/nonnull info for PHI results.  Do not set it on
25635         stmts marked for removal.
25637 2017-01-10  Eric Botcazou  <ebotcazou@adacore.com>
25639         * expr.c (store_field): In the bitfield case, fetch the return value
25640         from the registers before applying a single big-endian adjustment.
25641         Always do a final load for a BLKmode value not larger than a word.
25643 2017-01-10  David Malcolm  <dmalcolm@redhat.com>
25645         PR c++/77949
25646         * input.c (selftest::test_accessing_ordinary_linemaps): Verify
25647         that we correctly handle column numbers greater than
25648         LINE_MAP_MAX_COLUMN_NUMBER.
25650 2017-01-10  Martin Sebor  <msebor@redhat.com>
25652         PR middle-end/78245
25653         * gimple-ssa-sprintf.c (get_destination_size): Call
25654         {init,fini}object_sizes.
25655         * tree-object-size.c (addr_object_size): Adjust.
25656         (pass_through_call): Adjust.
25657         (pass_object_sizes::execute): Adjust.
25658         * tree-object-size.h (fini_object_sizes): Declare.
25660 2017-01-10  Martin Sebor  <msebor@redhat.com>
25662         PR tree-optimization/78775
25663         * builtins.c (get_size_range): Move...
25664         * calls.c: ...to here.
25665         (alloc_max_size): Accept zero argument.
25666         (operand_signed_p): Remove.
25667         (maybe_warn_alloc_args_overflow): Call get_size_range.
25668         * calls.h (get_size_range): Declare.
25670 2017-01-10  Joe Seymour  <joe.s@somniumtech.com>
25672         * config/msp430/driver-msp430.c (msp430_mcu_data): Sync with data
25673         from TI's devices.csv file as of September 2016.
25674         * config/msp430/msp430.c (msp430_mcu_data): Likewise.
25676 2017-01-10  Sandra Loosemore  <sandra@codesourcery.com>
25678         * doc/extend.texi: Tweak formatting to fix overfull hbox warnings.
25679         * doc/invoke.texi: Likewise.
25680         * doc/md.texi: Likewise.
25681         * doc/objc.texi: Likewise.
25683 2017-01-10  Joshua Conner  <joshconner@google.com>
25685         * config/arm/fuchsia-elf.h: New file.
25686         * config/fuchsia.h: New file.
25687         * config.gcc (*-*-fuchsia*): Set native_system_header_dir.
25688         (aarch64*-*-fuchsia*, arm*-*-fuchsia*, x86_64-*-fuchsia*): Add to
25689         targets.
25690         * config.host: (aarch64*-*-fuchsia*, arm*-*-fuchsia*): Add to hosts.
25692 2016-01-10  Richard Biener  <rguenther@suse.de>
25694         PR tree-optimization/79034
25695         * tree-call-cdce.c (shrink_wrap_one_built_in_call_with_conds):
25696         Propagate out degenerate PHIs in the joiner.
25698 2017-01-10  Martin Liska  <mliska@suse.cz>
25700         * ipa-icf.c (sort_sem_items_by_decl_uid): New function.
25701         (sort_congruence_classes_by_decl_uid): Likewise.
25702         (sort_congruence_class_groups_by_decl_uid): Likewise.
25703         (sem_item_optimizer::merge_classes): Sort class, groups in these
25704         classes and members in the groups by DECL_UID of declarations.
25705         This would make merge operations stable.
25707 2017-01-10  Martin Liska  <mliska@suse.cz>
25709         * ipa-icf.c (sem_item_optimizer::sem_item_optimizer): Remove
25710         usage of m_classes_vec.
25711         (sem_item_optimizer::~sem_item_optimizer):  Likewise.
25712         (sem_item_optimizer::get_group_by_hash): Likewise.
25713         (sem_item_optimizer::subdivide_classes_by_equality): Likewise.
25714         (sem_item_optimizer::subdivide_classes_by_sensitive_refs): Likewise.
25715         (sem_item_optimizer::verify_classes): Likewise.
25716         (sem_item_optimizer::process_cong_reduction): Likewise.
25717         (sem_item_optimizer::dump_cong_classes): Likewise.
25718         (sem_item_optimizer::merge_classes): Likewise.
25719         * ipa-icf.h (congruence_class_hash): Rename from
25720         congruence_class_group_hash.  Remove declaration of m_classes_vec.
25722 2017-01-10  Andrew Senkevich  <andrew.senkevich@intel.com>
25724         * common/config/i386/i386-common.c (OPTION_MASK_ISA_AVX512VPOPCNTDQ_SET,
25725         OPTION_MASK_ISA_AVX512VPOPCNTDQ_UNSET): New.
25726         * config.gcc: Add avx512vpopcntdqintrin.h.
25727         * config/i386/avx512vpopcntdqintrin.h: New.
25728         * config/i386/cpuid.h (bit_AVX512VPOPCNTDQ): New.
25729         * config/i386/i386-builtin-types.def: Add new types.
25730         * config/i386/i386-builtin.def (__builtin_ia32_vpopcountd_v16si,
25731         __builtin_ia32_vpopcountd_v16si_mask, __builtin_ia32_vpopcountq_v8di,
25732         __builtin_ia32_vpopcountq_v8di_mask): New.
25733         * config/i386/i386-c.c (ix86_target_macros_internal): Define
25734         __AVX512VPOPCNTDQ__.
25735         * config/i386/i386.c (ix86_target_string): Add -mavx512vpopcntdq.
25736         (PTA_AVX512VPOPCNTDQ): Define.
25737         * config/i386/i386.h (TARGET_AVX512VPOPCNTDQ,
25738         TARGET_AVX512VPOPCNTDQ_P): Define.
25739         * config/i386/i386.opt: Add mavx512vpopcntdq.
25740         * config/i386/immintrin.h: Include avx512vpopcntdqintrin.h.
25741         * config/i386/sse.md (define_insn "vpopcount<mode><mask_name>"): New.
25743 2017-01-01  Jan Hubicka  <hubicka@ucw.cz>
25745         PR middle-end/77484
25746         * predict.def (PRED_CALL): Set to 67.
25748 2017-01-09  Eric Botcazou  <ebotcazou@adacore.com>
25750         * expr.c (store_field): In the bitfield case, if the value comes from
25751         a function call and is of an aggregate type returned in registers, do
25752         not modify the field mode; extract the value in all cases if the mode
25753         is BLKmode and the size is not larger than a word.
25755 2017-01-09  Dominique d'Humieres  <dominiq@lps.ens.fr>
25757         PR target/71017
25758         * config/i386/cpuid.h: Fix undefined behavior.
25760 2017-01-04  Jeff Law  <law@redhat.com>
25762         PR tree-optimization/79007
25763         PR tree-optimization/67955
25764         * tree-ssa-alias.c (same_addr_size_stores_p): Only need to be
25765         conservative for pt.null when flag_non_call_exceptions is on.
25767 2017-01-09  Jakub Jelinek  <jakub@redhat.com>
25769         PR translation/79019
25770         PR translation/79020
25771         * params.def (PARAM_INLINE_MIN_SPEEDUP,
25772         PARAM_IPA_CP_SINGLE_CALL_PENALTY,
25773         PARAM_USE_AFTER_SCOPE_DIRECT_EMISSION_THRESHOLD): Fix typos
25774         in descriptions.
25775         * config/avr/avr.opt (maccumulate-args): Likewise.
25776         * config/msp430/msp430.opt (mwarn-mcu): Likewise.
25777         * common.opt (freport-bug): Likewise.
25778         * cif-code.def (CIF_FINAL_ERROR): Likewise.
25779         * doc/invoke.texi (ipa-cp-single-call-penalty): Likewise.
25780         * config/s390/s390.c (s390_invalid_binary_op): Fix spelling in
25781         translatable string.
25782         * config/i386/i386.c (function_value_32): Likewise.
25783         * config/nios2/nios2.c (nios2_valid_target_attribute_rec): Likewise.
25784         * config/msp430/msp430.c (msp430_option_override, msp430_attr):
25785         Likewise.
25786         * config/msp430/driver-msp430.c (msp430_select_hwmult_lib): Likewise.
25787         * common/config/msp430/msp430-common.c (msp430_handle_option):
25788         Likewise.
25789         * symtab.c (symtab_node::verify_base): Likewise.
25790         * opts.c (set_debug_level): Likewise.
25791         * tree.c (verify_type_variant): Likewise.  Fix typo in comment.
25792         * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin): Add
25793         missing whitespace to translatable strings.
25794         * config/avr/avr.md (bswapsi2): Fix typo in comment.
25795         * config/sh/superh.h: Likewise.
25796         * config/i386/xopintrin.h: Likewise.
25797         * config/i386/znver1.md: Likewise.
25798         * config/rs6000/rs6000.c (struct rs6000_opt_mask): Likewise.
25799         * ipa-inline-analysis.c (compute_inline_parameters): Likewise.
25800         * double-int.h (struct double_int): Likewise.
25801         * double-int.c (div_and_round_double): Likewise.
25802         * wide-int.cc: Likewise.
25803         * tree-ssa.c (non_rewritable_mem_ref_base): Likewise.
25804         * tree-ssa-sccvn.c (vn_reference_lookup_3): Likewise.
25805         * cfgcleanup.c (crossjumps_occured): Renamed to ...
25806         (crossjumps_occurred): ... this.
25807         (try_crossjump_bb, try_head_merge_bb, try_optimize_cfg, cleanup_cfg):
25808         Adjust all uses.
25810         PR tree-optimization/78899
25811         * tree-if-conv.c (version_loop_for_if_conversion): Instead of
25812         returning bool return struct loop *, NULL for failure and the new
25813         loop on success.
25814         (versionable_outer_loop_p): Don't version outer loop if it has
25815         dont_vectorized bit set.
25816         (tree_if_conversion): When versioning outer loop, ensure
25817         tree_if_conversion is performed also on the inner loop of the
25818         non-vectorizable outer loop copy.
25819         * tree-vectorizer.c (set_uid_loop_bbs): Formatting fix.  Fold
25820         LOOP_VECTORIZED in inner loop of the scalar outer loop and
25821         prevent vectorization of it.
25822         (vectorize_loops): For outer + inner LOOP_VECTORIZED, ensure
25823         the outer loop vectorization of the non-scalar version is attempted
25824         before vectorization of the inner loop in scalar version.  If
25825         outer LOOP_VECTORIZED guarded loop is not vectorized, prevent
25826         vectorization of its inner loop.
25827         * tree-vect-loop-manip.c (rename_variables_in_bb): If outer_loop
25828         has 2 inner loops, rename also on edges from bb whose single pred
25829         is outer_loop->header.  Fix typo in function comment.
25831 2017-01-09  Martin Sebor  <msebor@redhat.com>
25833         PR bootstrap/79033
25834         * asan.c (asan_emit_stack_protection): Increase local buffer size
25835         to avoid snprintf truncation warning.
25837 2017-01-09  Andrew Pinski  <apinski@cavium.com>
25839         * config/aarch64/aarch64-cores.def: Add thunderx2t99.  Change vulcan
25840         to reference thunderx2t99 for the tuning structure
25841         * config/aarch64/aarch64-cost-tables.h (vulcan_extra_costs):
25842         Rename to ...
25843         (thunderx2t99_extra_costs): This.
25844         * config/aarch64/aarch64-tune.md: Regenerate.
25845         * config/aarch64/aarch64.c (vulcan_addrcost_table): Rename to ...
25846         (vulcan_addrcost_table): This.
25847         (vulcan_regmove_cost): Rename to ...
25848         (thunderx2t99_regmove_cost): This.
25849         (vulcan_vector_cost): Rename to ...
25850         (thunderx2t99_vector_cost): this.
25851         (vulcan_branch_cost): Rename to ...
25852         (thunderx2t99_branch_cost): This.
25853         (vulcan_tunings): Rename to ...
25854         (thunderx2t99_tunings): This and s/vulcan/thunderx2t99 .
25855         * doc/invoke.texi (AARCH64/mtune): Add thunderx2t99.
25857 2017-01-09  Martin Jambor  <mjambor@suse.cz>
25859         PR ipa/78365
25860         PR ipa/78599
25861         * ipa-prop.h (ipa_jump_func): Swap positions of vr_known and m_vr.
25862         * ipa-cp.c (ipa_vr_operation_and_type_effects): New function.
25863         (propagate_vr_accross_jump_function): Use the above function for all
25864         value range computations for pass-through jump functions and type
25865         converasion from explicit value range values.
25866         (ipcp_propagate_stage): Do not attempt to deduce types of formal
25867         parameters from TYPE_ARG_TYPES.
25868         * ipa-prop.c (ipa_write_jump_function): Remove trailing whitespace.
25869         (ipa_write_node_info): Stream type of the actual argument.
25870         (ipa_read_node_info): Likewise. Also remove trailing whitespace.
25872 2017-01-09  Martin Liska  <mliska@suse.cz>
25874         PR pch/78970
25875         * gcc.c (driver_handle_option): Handle OPT_E and set have_E.
25876         (lookup_compiler): Do not show error message with have_E.
25878 2017-01-09  Jakub Jelinek  <jakub@redhat.com>
25880         PR tree-optimization/78938
25881         * tree-vect-stmts.c (vectorizable_condition): For non-masked COND_EXPR
25882         where comp_vectype is VECTOR_BOOLEAN_TYPE_P, use
25883         BIT_{NOT,XOR,AND,IOR}_EXPR on the comparison operands instead of
25884         {EQ,NE,GE,GT,LE,LT}_EXPR directly inside of VEC_COND_EXPR.  Formatting
25885         fixes.
25887 2017-01-09  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
25889         * tree-ssa-address.c (gen_addr_rtx): Don't handle index if it
25890         is const0_rtx.
25892 2017-01-09  Richard Biener  <rguenther@suse.de>
25894         PR tree-optimization/78997
25895         * tree-vect-slp.c (vect_mask_constant_operand_p): Handle SSA
25896         name condition properly.
25898 2017-01-09  Richard Biener  <rguenther@suse.de>
25900         PR debug/79000
25901         * dwarf2out.c (is_cxx): New overload with context.
25902         (is_naming_typedef_decl): Use it.
25904 2017-01-08  Sandra Loosemore  <sandra@codesourcery.com>
25906         * invoke.texi (Option Summary): Correct spacing in option lists
25907         and add line breaks to fix over-long lines.
25909 2017-01-08  Sandra Loosemore  <sandra@codesourcery.com>
25911         PR middle-end/17660
25913         * extend.texi (Common Variable Attributes): Add xref to GCC
25914         Internals manual to explain mode attribute keywords.
25916 2017-01-08  Sandra Loosemore  <sandra@codesourcery.com>
25918         PR other/16519
25919         * doc/invoke.texi (Option Summary): Move -pthread to Linker Options
25920         and Preprocessor Options.
25921         (Options for Linking): Document -pthread here....
25922         (RS/6000 and PowerPC Options): ...not here.
25923         (Solaris 2 Options): ...or here.
25924         * doc/cppopts.texi: Document -pthread.
25926 2017-01-08  Martin Sebor  <msebor@redhat.com>
25928         PR middle-end/77708
25929         * doc/invoke.texi (Warning Options): Document -Wformat-truncation.
25930         * gimple-ssa-sprintf.c (call_info::reval_used, call_info::warnopt):
25931         New member functions.
25932         (format_directive): Used them.
25933         (add_bytes): Same.
25934         (pass_sprintf_length::handle_gimple_call): Same.
25935         * graphite-sese-to-poly.c (tree_int_to_gmp): Increase buffer size
25936         to avoid truncation for any argument.
25937         (extract_affine_mul): Same.
25938         * tree.c (get_file_function_name): Same.
25940 2017-01-01  Jan Hubicka  <hubicka@ucw.cz>
25942         PR middle-end/77484
25943         * predict.def (PRED_INDIR_CALL): Set to 86.
25945 2017-01-07  Sandra Loosemore  <sandra@codesourcery.com>
25947         PR preprocessor/54124
25948         * doc/cppopts.texi: Reformat -d subtable to list the full name
25949         of the options.  Add cross-reference to the docs for the general
25950         compiler -d options.
25951         * doc/invoke.texi (Developer Options): Add cross-reference to the
25952         preprocessor-specific -d option documentation.
25954 2017-01-07  Sandra Loosemore  <sandra@codesourcery.com>
25956         PR preprocessor/13498
25957         * doc/cpp.texi (Search Path): Rewrite to remove obsolete and
25958         redudant material, and reflect new command-line options.
25959         (System Headers): Likewise.
25961 2017-01-07  Sandra Loosemore  <sandra@codesourcery.com>
25963         * doc/cppdiropts.texi: Merge documentation of -I, -iquote,
25964         -isystem, and -idirafter.  Copy-edit.
25965         * doc/cppopts.texi: Copy-edit.  Remove contradiction about
25966         default for -ftrack-macro-expansion.  Delete obsolete and
25967         badly-formatted implementation details about -fdebug-cpp output.
25968         * doc/cppwarnopts.texi: Copy-edit.
25970 2017-01-07  David Malcolm  <dmalcolm@redhat.com>
25972         PR c++/72803
25973         * input.c (selftest::test_accessing_ordinary_linemaps): Verify
25974         that the transition from a max line width >= 1<<10 to narrower
25975         lines works correctly.
25977 2017-01-07  Alexandre Oliva <aoliva@redhat.com>
25979         * doc/options.texi (PerFunction): New.
25980         * opt-functions.awk (switch_flags): Map both Optimization and
25981         PerFunction to CL_OPTIMIZATION.
25982         * opth-gen.awk: Test for PerFunction flag along with
25983         Optimization.
25984         * optc-save-gen.awk: Likewise.  Introduce var_opt_hash and set
25985         it only when the latter is present.  Skip those that don't in
25986         the hash function generator.
25987         * common.opt (fvar-tracking): Mark as PerFunction instead of
25988         Optimization.
25989         (fvar-tracking-assignments): Likewise.
25990         (fvar-tracking-assignments-toggle): Likewise.
25991         (fvar-tracking-uninit): Likewise.
25993 2017-01-07  Jakub Jelinek  <jakub@redhat.com>
25995         PR translation/79018
25996         * params.def (PARAM_MAX_STORES_TO_MERGE): Add missing space between
25997         the and store.
25999 2017-01-06  Mikael Pettersson  <mikpelinux@gmail.com>
26001         PR target/57583
26002         * config/m68k/m68k.opt (LONG_JUMP_TABLE_OFFSETS): New option.
26003         * config/m68k/linux.h (ASM_RETURN_CASE_JUMP): Handle
26004         TARGET_LONG_JUMP_TABLE_OFFSETS.
26005         * config/m68k/m68kelf.h (ASM_RETURN_CASE_JUMP): Likewise.
26006         * config/m68k/netbsd-elf.h (ASM_RETURN_CASE_JUMP): Likewise.
26007         * config/m68k/m68k.h (CASE_VECTOR_MODE): Likewise.
26008         (ASM_OUTPUT_ADDR_DIFF_ELF): Likewise.
26009         * config/m68k/m68k.md (tablejump expander): Likewise.
26010         (*tablejump_pcrel_hi): Renamed from unnamed insn, reject
26011         TARGET_LONG_JUMP_TABLE_OFFSETS.
26012         (*tablejump_pcrel_si): New insn, handle TARGET_LONG_JUMP_TABLE_OFFSETS.
26013         * doc/invoke.texi (M68K options): Add -mlong-jump-table-offsets.
26015 2017-01-06  Edgar E. Iglesias <edgar.iglesias@xilinx.com>
26016             David Holsgrove <david.holsgrove@xilinx.com>
26018         * common/config/microblaze/microblaze-common.c
26019         (TARGET_EXCEPT_UNWIND_INFO): Remove.
26020         * config/microblaze/microblaze-protos.h (microblaze_eh_return):
26021         New prototype.
26022         * config/microblaze/microblaze.c (microblaze_must_save_register)
26023         (microblaze_expand_epilogue, microblaze_return_addr): Handle
26024         calls_eh_return.
26025         (microblaze_eh_return): New function.
26026         * config/microblaze/microblaze.h (RETURN_ADDR_OFFSET)
26027         (EH_RETURN_DATA_REGNO, MB_EH_STACKADJ_REGNUM)
26028         (EH_RETURN_STACKADJ_RTX, ASM_PREFERRED_EH_DATA_FORMAT): New macros.
26029         * config/microblaze/microblaze.md (eh_return): New pattern.
26031 2017-01-06  Jakub Jelinek  <jakub@redhat.com>
26033         * system.h (GCC_DIAGNOSTIC_PUSH_IGNORED, GCC_DIAGNOSTIC_POP,
26034         GCC_DIAGNOSTIC_STRINGIFY): Define.
26036         * read-rtl.c (rtx_reader::read_rtx_code): Avoid -Wsign-compare warning.
26038 2017-01-06  Andre Vieira  <andre.simoesdiasvieira@arm.com>
26040         * config/arm/arm.md (<mcrr>): New.
26041         (<mrrc>): New.
26042         * config/arm/arm.c (arm_arch5te): New.
26043         (arm_option_override): Set arm_arch5te.
26044         (arm_coproc_builtin_available): Add support for mcrr, mcrr2, mrrc
26045         and mrrc2.
26046         * config/arm/arm-builtins.c (MCRR_QUALIFIERS): Define to...
26047         (arm_mcrr_qualifiers): ... this. New.
26048         (MRRC_QUALIFIERS): Define to...
26049         (arm_mrrc_qualifiers): ... this. New.
26050         * config/arm/arm_acle.h (__arm_mcrr, __arm_mcrr2, __arm_mrrc,
26051         __arm_mrrc2): New.
26052         * config/arm/arm_acle_builtins.def (mcrr, mcrr2, mrrc, mrrc2): New.
26053         * config/arm/iterators.md (MCRRI, mcrr, MCRR): New.
26054         (MRRCI, mrrc, MRRC): New.
26055         * config/arm/unspecs.md (VUNSPEC_MCRR, VUNSPEC_MCRR2, VUNSPEC_MRRC,
26056         VUNSPEC_MRRC2): New.
26058 2017-01-06  Andre Vieira  <andre.simoesdiasvieira@arm.com>
26060         * config/arm/arm.md (<mcr>): New.
26061         (<mrc>): New.
26062         * config/arm/arm.c (arm_coproc_builtin_available): Add
26063         support for mcr, mrc, mcr2 and mrc2.
26064         * config/arm/arm-builtins.c (MCR_QUALIFIERS): Define to...
26065         (arm_mcr_qualifiers): ... this. New.
26066         (MRC_QUALIFIERS): Define to ...
26067         (arm_mrc_qualifiers): ... this. New.
26068         (MCR_QUALIFIERS): Define to ...
26069         (arm_mcr_qualifiers): ... this. New.
26070         * config/arm/arm_acle.h (__arm_mcr, __arm_mrc, __arm_mcr2,
26071         __arm_mrc2): New.
26072         * config/arm/arm_acle_builtins.def (mcr, mcr2, mrc, mrc2): New.
26073         * config/arm/iterators.md (MCRI, mcr, MCR, MRCI, mrc, MRC): New.
26074         * config/arm/unspecs.md (VUNSPEC_MCR, VUNSPEC_MCR2, VUNSPEC_MRC,
26075         VUNSPEC_MRC2): New.
26077 2017-01-06  Andre Vieira  <andre.simoesdiasvieira@arm.com>
26079         * config/arm/arm.md (*ldc): New.
26080         (*stc): New.
26081         (<ldc>): New.
26082         (<stc>): New.
26083         * config/arm/arm.c (arm_coproc_builtin_available): Add
26084         support for ldc,ldcl,stc,stcl,ldc2,ldc2l,stc2 and stc2l.
26085         (arm_coproc_ldc_stc_legitimate_address): New.
26086         * config/arm/arm-builtins.c (arm_type_qualifiers): Add
26087         'qualifier_const_pointer'.
26088         (LDC_QUALIFIERS): Define to...
26089         (arm_ldc_qualifiers): ... this. New.
26090         (STC_QUALIFIERS): Define to...
26091         (arm_stc_qualifiers): ... this. New.
26092         * config/arm/arm-protos.h
26093         (arm_coproc_ldc_stc_legitimate_address): New.
26094         * config/arm/arm_acle.h (__arm_ldc, __arm_ldcl, __arm_stc,
26095         __arm_stcl, __arm_ldc2, __arm_ldc2l, __arm_stc2, __arm_stc2l): New.
26096         * config/arm/arm_acle_builtins.def (ldc, ldc2, ldcl, ldc2l, stc,
26097         stc2, stcl, stc2l): New.
26098         * config/arm/constraints.md (Uz): New.
26099         * config/arm/iterators.md (LDCI, STCI, ldc, stc, LDC STC): New.
26100         * config/arm/unspecs.md (VUNSPEC_LDC, VUNSPEC_LDC2, VUNSPEC_LDCL,
26101         VUNSPEC_LDC2L, VUNSPEC_STC, VUNSPEC_STC2, VUNSPEC_STCL,
26102         VUNSPEC_STC2L): New.
26104 2017-01-06  Andre Vieira  <andre.simoesdiasvieira@arm.com>
26106         * config/arm/arm.md (<cdp>): New.
26107         * config/arm/arm.c (neon_const_bounds): Rename this ...
26108         (arm_const_bounds): ... this.
26109         (arm_coproc_builtin_available): New.
26110         * config/arm/arm-builtins.c (SIMD_MAX_BUILTIN_ARGS): Increase.
26111         (arm_type_qualifiers): Add 'qualifier_unsigned_immediate'.
26112         (CDP_QUALIFIERS): Define to...
26113         (arm_cdp_qualifiers): ... this. New.
26114         (void_UP): Define.
26115         (arm_expand_builtin_args): Add case for 6 arguments.
26116         * config/arm/arm-protos.h (neon_const_bounds): Rename this ...
26117         (arm_const_bounds): ... this.
26118         (arm_coproc_builtin_available): New.
26119         * config/arm/arm_acle.h (__arm_cdp): New.
26120         (__arm_cdp2): New.
26121         * config/arm/arm_acle_builtins.def (cdp): New.
26122         (cdp2): New.
26123         * config/arm/iterators.md (CDPI,CDP,cdp): New.
26124         * config/arm/neon.md: Rename all 'neon_const_bounds' to
26125         'arm_const_bounds'.
26126         * config/arm/types.md (coproc): New.
26127         * config/arm/unspecs.md (VUNSPEC_CDP, VUNSPEC_CDP2): New.
26128         * doc/extend.texi (ACLE): Add a mention of Coprocessor intrinsics.
26129         * doc/sourcebuild.texi (arm_coproc1_ok, arm_coproc2_ok,
26130         arm_coproc3_ok, arm_coproc4_ok): Document new effective targets.
26132 2017-01-06  Andre Vieira  <andre.simoesdiasvieira@arm.com>
26134         * config/arm/arm-builtins.c (arm_unsigned_binop_qualifiers): New.
26135         (UBINOP_QUALIFIERS): New.
26136         (si_UP): Define.
26137         (acle_builtin_data): New. Change comment.
26138         (arm_builtins): Remove ARM_BUILTIN_CRC32B, ARM_BUILTIN_CRC32H,
26139         ARM_BUILTIN_CRC32W, ARM_BUILTIN_CRC32CB, ARM_BUILTIN_CRC32CH,
26140         ARM_BUILTIN_CRC32CW. Add ARM_BUILTIN_ACLE_BASE and include
26141         arm_acle_builtins.def.
26142         (ARM_BUILTIN_ACLE_PATTERN_START): Define.
26143         (arm_init_acle_builtins): New.
26144         (CRC32_BUILTIN): Remove.
26145         (bdesc_2arg): Remove entries for crc32b, crc32h, crc32w,
26146         crc32cb, crc32ch and crc32cw.
26147         (arm_init_crc32_builtins): Remove.
26148         (arm_init_builtins): Use arm_init_acle_builtins rather
26149         than arm_init_crc32_builtins.
26150         (arm_expand_acle_builtin): New.
26151         (arm_expand_builtin): Use 'arm_expand_acle_builtin'.
26152         * config/arm/arm_acle_builtins.def: New.
26154 2017-01-06  Andre Vieira  <andre.simoesdiasvieira@arm.com>
26156         * config/arm/arm-builtins.c (neon_builtin_datum): Rename to ..
26157         (arm_builtin_datum): ... this.
26158         (arm_init_neon_builtin): Rename to ...
26159         (arm_init_builtin): ... this. Add a new parameters PREFIX
26160         and USE_SIG_IN_NAME.
26161         (arm_init_neon_builtins): Replace 'arm_init_neon_builtin' with
26162         'arm_init_builtin'. Replace type 'neon_builtin_datum' with
26163         'arm_builtin_datum'.
26164         (arm_init_vfp_builtins): Likewise.
26165         (builtin_arg): Rename enum's replacing 'NEON_ARG' with
26166         'ARG_BUILTIN' and add a 'ARG_BUILTIN_NEON_MEMORY.
26167         (arm_expand_neon_args): Rename to ...
26168         (arm_expand_builtin_args): ... this. Rename builtin_arg
26169         enum values and differentiate between ARG_BUILTIN_MEMORY
26170         and ARG_BUILTIN_NEON_MEMORY.
26171         (arm_expand_neon_builtin_1): Rename to ...
26172         (arm_expand_builtin_1): ... this. Rename builtin_arg enum
26173         values, arm_expand_builtin_args and add bool parameter NEON.
26174         (arm_expand_neon_builtin): Use arm_expand_builtin_1.
26175         (arm_expand_vfp_builtin): Likewise.
26176         (NEON_MAX_BUILTIN_ARGS): Remove, it was unused.
26178 2017-01-01  Jan Hubicka  <hubicka@ucw.cz>
26180         PR middle-end/77484
26181         * predict.def (PRED_POLYMORPHIC_CALL): Set to 59.
26182         * predict.c (tree_estimate_probability_bb): Reverse direction of
26183         polymorphic call predictor.
26185 2017-01-06  David Malcolm  <dmalcolm@redhat.com>
26187         * passes.c (execute_one_pass): Split out pass-skipping logic into...
26188         (determine_pass_name_match): ...this new function and...
26189         (should_skip_pass_p): ...this new function.
26191 2017-01-06  Nathan Sidwell  <nathan@acm.org>
26193         * ipa-visibility.c (function_and_variable_visibility): Reformat
26194         comments and long lines.  Remove extrneous if.
26195         * symtab.c (symtab_node::make_decl_local): Fix code format.
26196         (symtab_node::set_section_for_node): Fix comment typo.
26198 2017-01-06  Martin Liska  <mliska@suse.cz>
26200         PR bootstrap/79003
26201         * lra-constraints.c: Rename invariant to lra_invariant.
26202         * predict.c (set_even_probabilities): Initialize e to NULL.
26204 2017-01-05  Martin Sebor  <msebor@redhat.com>
26206         PR tree-optimization/78910
26207         * gimple-ssa-sprintf.c (tree_digits): Add an argument.
26208         (format_integer): Correct off-by-one error in the handling
26209         of precision with negative numbers in signed conversions..
26211 2017-01-05  Eric Botcazou  <ebotcazou@adacore.com>
26213         * doc/invoke.texi (C Dialect Options): Adjust -fsso-struct entry.
26215 2017-01-05  Jakub Jelinek  <jakub@redhat.com>
26217         PR tree-optimization/71016
26218         * tree-ssa-phiopt.c (tree_ssa_phiopt_worker): Pass cond_stmt to
26219         factor_out_conditional_conversion.  Formatting fix.
26220         (factor_out_conditional_conversion): Add cond_stmt argument.
26221         If arg1 is INTEGER_CST, punt if new_arg0 is not any operand of
26222         cond_stmt and if arg0_def_stmt is not the only stmt in its bb.
26223         Formatting fix.
26225 2017-01-05  David Malcolm  <dmalcolm@redhat.com>
26227         * Makefile.in (OBJS): Add read-md.o, read-rtl.o,
26228         read-rtl-function.o, and selftest-rtl.o.
26229         * config/aarch64/aarch64.c: Include selftest.h and selftest-rtl.h.
26230         (selftest::aarch64_test_loading_full_dump): New function.
26231         (selftest::aarch64_run_selftests): New function.
26232         (TARGET_RUN_TARGET_SELFTESTS): Wire it up to
26233         selftest::aarch64_run_selftests.
26234         * config/i386/i386.c
26235         (selftest::ix86_test_loading_dump_fragment_1): New function.
26236         (selftest::ix86_test_loading_call_insn): New function.
26237         (selftest::ix86_test_loading_full_dump): New function.
26238         (selftest::ix86_test_loading_unspec): New function.
26239         (selftest::ix86_run_selftests): Call the new functions.
26240         * emit-rtl.c (maybe_set_max_label_num): New function.
26241         * emit-rtl.h (maybe_set_max_label_num): New decl.
26242         * function.c (instantiate_decls): Guard call to
26243         instantiate_decls_1 with if (DECL_INITIAL (fndecl)).
26244         * function-tests.c (selftest::verify_three_block_rtl_cfg): Remove
26245         "static".
26246         * gensupport.c (gen_reader::gen_reader): Pass "false"
26247         for new "compact" param of rtx_reader.
26248         * print-rtl.c (rtx_writer::print_rtx_operand): Print "(nil)"
26249         rather than an empty string for NULL strings.
26250         * read-md.c: Potentially include config.h rather than bconfig.h.
26251         Wrap include of errors.h with #ifdef GENERATOR_FILE.
26252         (have_error): New global, copied from errors.c.
26253         (md_reader::read_name): Rename to...
26254         (md_reader::read_name_1): ...this, adding "out_loc" param,
26255         and converting "missing name or number" to returning false, rather
26256         than failing.
26257         (md_reader::read_name): Reimplement in terms of read_name_1.
26258         (md_reader::read_name_or_nil): New function.
26259         (md_reader::read_string): Handle "(nil)" by returning NULL.
26260         (md_reader::md_reader): Add new param "compact".
26261         (md_reader::read_md_files): Wrap with #ifdef GENERATOR_FILE.
26262         (md_reader::read_file): New method.
26263         * read-md.h (md_reader::md_reader): Add new param "compact".
26264         (md_reader::read_file): New method.
26265         (md_reader::is_compact): New accessor.
26266         (md_reader::read_name): Convert return type from void to file_location.
26267         (md_reader::read_name_or_nil): New decl.
26268         (md_reader::read_name_1): New decl.
26269         (md_reader::m_compact): New field.
26270         (noop_reader::noop_reader): Pass "false" for new "compact" param
26271         of rtx_reader.
26272         (rtx_reader::rtx_reader): Add new "compact" param.
26273         (rtx_reader::read_rtx_operand): Make virtual and convert return
26274         type from void to rtx.
26275         (rtx_reader::read_until): New decl.
26276         (rtx_reader::handle_any_trailing_information): New virtual function.
26277         (rtx_reader::postprocess): New virtual function.
26278         (rtx_reader::finalize_string): New virtual function.
26279         (rtx_reader::m_in_call_function_usage): New field.
26280         (rtx_reader::m_reuse_rtx_by_id): New field.
26281         * read-rtl-function.c: New file.
26282         * selftest-rtl.c (selftest::assert_rtx_ptr_eq_at): New function.
26283         * selftest-rtl.h (ASSERT_RTX_PTR_EQ): New macro.
26284         (selftest::verify_three_block_rtl_cfg): New decl.
26285         * read-rtl-function.h: New file.
26286         * read-rtl.c: Potentially include config.h rather than bconfig.h.
26287         For host, include function.h, memmodel.h, and emit-rtl.h.
26288         (one_time_initialization): New function.
26289         (struct compact_insn_name): New struct.
26290         (compact_insn_names): New array.
26291         (find_code): Handle insn codes in compact dumps.
26292         (apply_subst_iterator): Wrap with #ifdef GENERATOR_FILE.
26293         (bind_subst_iter_and_attr): Likewise.
26294         (add_condition_to_string): Likewise.
26295         (add_condition_to_rtx): Likewise.
26296         (apply_attribute_uses): Likewise.
26297         (add_current_iterators): Likewise.
26298         (apply_iterators): Likewise.
26299         (initialize_iterators): Guard usage of apply_subst_iterator with
26300         #ifdef GENERATOR_FILE.
26301         (read_conditions): Wrap with #ifdef GENERATOR_FILE.
26302         (md_reader::read_mapping): Likewise.
26303         (add_define_attr_for_define_subst): Likewise.
26304         (add_define_subst_attr): Likewise.
26305         (read_subst_mapping): Likewise.
26306         (check_code_iterator): Likewise.
26307         (rtx_reader::read_rtx): Likewise.  Move one-time initialization
26308         logic to...
26309         (one_time_initialization): New function.
26310         (rtx_reader::read_until): New method.
26311         (read_flags): New function.
26312         (parse_reg_note_name): New function.
26313         (rtx_reader::read_rtx_code): Initialize "iterator" to NULL.
26314         Handle reuse_rtx ids.
26315         Wrap iterator lookup within #ifdef GENERATOR_FILE.
26316         Add parsing support for RTL dumps, mirroring the special-cases in
26317         print_rtx, by calling read_flags, reading REG_NOTE names, INSN_UID
26318         values, and calling handle_any_trailing_information.
26319         (rtx_reader::read_rtx_operand): Convert return type from void
26320         to rtx, returning return_rtx.  Handle case 'e'.  Call
26321         finalize_string on XSTR and XTMPL fields.
26322         (rtx_reader::read_nested_rtx):  Handle dumps in which trailing
26323          "(nil)" values were omitted.  Call the postprocess vfunc on the
26324         return_rtx.
26325         (rtx_reader::rtx_reader): Add new "compact" param and pass to base
26326         class ctor.  Initialize m_in_call_function_usage.  Call
26327         one_time_initialization.
26328         * rtl-tests.c (selftest::test_uncond_jump): Call
26329         set_new_first_and_last_insn.
26330         * rtl.h (read_rtx): Wrap decl with #ifdef GENERATOR_FILE.
26331         * selftest-rtl.c: New file.
26332         * selftest-rtl.h (class selftest::rtl_dump_test): New class.
26333         (selftest::get_insn_by_uid): New decl.
26334         * selftest-run-tests.c (selftest::run_tests): Call
26335         read_rtl_function_c_tests.
26336         * selftest.h  (selftest::read_rtl_function_c_tests): New decl.
26337         * tree-dfa.c (ssa_default_def): Return NULL_TREE for rtl function
26338         dumps.
26340 2017-01-05  Uros Bizjak  <ubizjak@gmail.com>
26342         * config/i386/i386.md (*testqi_ext_3): No need to handle memory
26343         operands in a special way.  Assert that pos+len <= mode precision.
26345 2017-01-05  Jakub Jelinek  <jakub@redhat.com>
26347         * common.opt (fvect-cost-model): Remove RejectNegative flag, use
26348         3 argument Alias with unlimited for the negative form.
26349         (fno-vect-cost-model): Removed.
26351 2017-01-05  Martin Liska  <mliska@suse.cz>
26353         * hsa-gen.c (gen_hsa_divmod): New function.
26354         (gen_hsa_insn_for_internal_fn_call): Use the function for IFN_DIVMOD.
26356 2017-01-05  Martin Liska  <mliska@suse.cz>
26358         PR pch/78970
26359         * gcc.c (lookup_compiler): Reject '-' filename for a precompiled
26360         header.
26362 2017-01-05  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
26364         * config/s390/s390.c (s390_expand_setmem): Unroll the loop for
26365         small constant length operands.
26367 2017-01-05  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
26369         * config/s390/s390.c (s390_expand_setmem): Avoid overlapping bytes
26370         between loop iterations.
26372 2017-01-05  Martin Liska  <mliska@suse.cz>
26374         PR sanitizer/78815
26375         * gimplify.c (gimplify_decl_expr): Compare to
26376         asan_poisoned_variables instread of checking flags.
26377         (gimplify_target_expr): Likewise.
26378         (gimplify_expr): Likewise.
26379         (gimplify_function_tree): Conditionally initialize
26380         asan_poisoned_variables.
26382 2017-01-04  Jeff Law  <law@redhat.com>
26384         PR tree-optimizatin/78812
26385         * rtl.h (contains_mem_rtx_p): Prototype.
26386         * ifcvt.c (containts_mem_rtx_p): Move from here to...
26387         * rtlanal.c (contains_mem_rtx_p): Here and remove static linkage.
26388         * gcse.c (prune_expressions): Use contains_mem_rtx_p to discover
26389         and prune MEMs that are not at the toplevel of a SET_SRC rtx.  Look
26390         through ZERO_EXTEND and SIGN_EXTEND when trying to avoid pruning MEMs.
26392 2017-01-04  Alexandre Oliva <aoliva@redhat.com>
26394         * input.c (assert_char_at_range): Default-initialize actual_range.
26396 2017-01-04  Alexandre Oliva <aoliva@redhat.com>
26398         * df-scan.c (df_ref_create_structure): Make regno unsigned,
26399         to match the caller.
26401 2017-01-04  Alexandre Oliva <aoliva@redhat.com>
26403         * cfgexpand.c (expand_gimple_basic_block): Disregard debug
26404         insns after final jump in test to emit dummy move.
26406 2017-01-04  Alexandre Oliva <aoliva@redhat.com>
26408         * gimple-iterator.h (gsi_one_nondebug_before_end_p): New.
26409         * tree-eh.c (cleanup_empty_eh): Skip more debug stmts.
26411 2017-01-04  Alexandre Oliva <aoliva@redhat.com>
26413         * multiple_target.c (create_dispatcher_calls): Init e_next.
26414         * tree-ssa-loop-split.c (split_loop): Init border.
26415         * tree-vect-loop.c (vect_determine_vectorization_factor): Init
26416         scalar_type.
26418 2017-01-04  Michael Meissner  <meissner@linux.vnet.ibm.com>
26420         PR target/71977
26421         PR target/70568
26422         PR target/78823
26423         * config/rs6000/predicates.md (sf_subreg_operand): New predicate.
26424         (altivec_register_operand): Do not return true if the operand
26425         contains a SUBREG mixing SImode and SFmode.
26426         (vsx_register_operand): Likewise.
26427         (vsx_reg_sfsubreg_ok): New predicate.
26428         (vfloat_operand): Do not return true if the operand contains a
26429         SUBREG mixing SImode and SFmode.
26430         (vint_operand): Likewise.
26431         (vlogical_operand): Likewise.
26432         (gpc_reg_operand): Likewise.
26433         (int_reg_operand): Likewise.
26434         * config/rs6000/rs6000-protos.h (valid_sf_si_move): Add declaration.
26435         * config/rs6000/rs6000.c (valid_sf_si_move): New function to
26436         determine if a MOVSI or MOVSF operation contains SUBREGs that mix
26437         SImode and SFmode.
26438         (rs6000_emit_move_si_sf_subreg): New helper function.
26439         (rs6000_emit_move): Call rs6000_emit_move_si_sf_subreg to possbily
26440         fixup SUBREGs involving SImode and SFmode.
26441         * config/rs6000/vsx.md (SFBOOL_*): New constants that are operand
26442         numbers for the new peephole2 optimization.
26443         (peephole2 for SFmode unions): New peephole2 to optimize cases in
26444         the GLIBC math library that do AND/IOR/XOR operations on single
26445         precision floating point.
26446         * config/rs6000/rs6000.h (TARGET_NO_SF_SUBREG): New internal
26447         target macros to say whether we need to avoid SUBREGs mixing
26448         SImode and SFmode.
26449         (TARGET_ALLOW_SF_SUBREG): Likewise.
26450         * config/rs6000/rs6000.md (UNSPEC_SF_FROM_SI): New unspecs.
26451         (UNSPEC_SI_FROM_SF): Likewise.
26452         (iorxor): Change spacing.
26453         (and_ior_xor): New iterator for AND, IOR, and XOR.
26454         (movsi_from_sf): New insns for SImode/SFmode SUBREG support.
26455         (movdi_from_sf_zero_ext): Likewise.
26456         (mov<mode>_hardfloat, FMOVE32 iterator): Use register_operand
26457         instead of gpc_reg_operand.  Add SImode/SFmode SUBREG support.
26458         (movsf_from_si): New insn for SImode/SFmode SUBREG support.
26459         (fma<mode>4): Use gpc_reg_operand instead of register_operand.
26460         (fms<mode>4): Likewise.
26461         (fnma<mode>4): Likewise.
26462         (fnms<mode>4): Likewise.
26463         (nfma<mode>4): Likewise.
26464         (nfms<mode>4): Likewise.
26466 2017-01-04  Marek Polacek  <polacek@redhat.com>
26468         PR c++/64767
26469         * doc/invoke.texi: Document -Wpointer-compare.
26471 2017-01-04  Jakub Jelinek  <jakub@redhat.com>
26473         * optc-gen.awk: Emit #error for -W*/-f*/-m* Enum without
26474         RejectNegative.
26476         * dwarf2out.c (output_loc_list): Don't throw away 64K+ location
26477         descriptions for -gdwarf-5 and emit them as uleb128 instead of
26478         2-byte data.
26480 2017-01-04  Kelvin Nilsen  <kelvin@gcc.gnu.org>
26482         PR target/78056
26483         * doc/sourcebuild.texi (PowerPC-specific attributes): Add
26484         documentation of the powerpc_popcntb_ok attribute.
26485         * config/rs6000/rs6000.c (rs6000_option_override_internal): Add
26486         code to issue warning messages if a requested CPU configuration is
26487         not supported by the binary (assembler and loader) toolchain.
26488         (spe_init_builtins): Add two assertions to prevent ICE if attempt is
26489         made to define a built-in function that has been disabled.
26490         (paired_init_builtins): Add assertion to prevent ICE if attempt is
26491         made to define a built-in function that has been disabled.
26492         (altivec_init_builtins): Add comment explaining why definition
26493         of the DST built-in functions is not preceded by an assertion
26494         check.  Add assertions to prevent ICE if attempts are made to
26495         define an altivec predicate or an abs* built-in function that has
26496         been disabled.
26497         (htm_init_builtins): Add comment explaining why definition of the
26498         htm built-in functions is not preceded by an assertion check.
26500 2017-01-04  Jeff Law  <law@redhat.com>
26502         PR tree-optimizatin/67955
26503         * tree-ssa-alias.c (same_addr_size_stores_p): Check offsets first.
26504         Allow any SSA_VAR_P as the base objects.  Use integer_zerop.  Verify
26505         the points-to solution does not include pt_null.  Use DECL_PT_UID
26506         unconditionally.
26508 2017-01-04  Uros Bizjak  <ubizjak@gmail.com>
26510         * config/i386/i386.md (HI/SImode test with imm to QImode splitters):
26511         Use gen_int_mode instead of gen_lopwart for const_int operands.
26513 2017-01-04  Jakub Jelinek  <jakub@redhat.com>
26515         PR tree-optimization/71563
26516         * match.pd: Simplify X << Y into X if Y is known to be 0 or
26517         out of range value - has low bits known to be zero.
26519 2017-01-04  Alan Modra  <amodra@gmail.com>
26521         * Makefile.in (aclocal_deps): Update and order as per aclocal.m4.
26522         * configure: Regenerate.
26523         * config.in: Regenerate.
26525 2017-01-04  Jakub Jelinek  <jakub@redhat.com>
26527         PR bootstrap/77569
26528         * input.c (ebcdic_execution_charset::on_error): Don't use strstr for
26529         a substring of the message, but strcmp with the whole message.  Ifdef
26530         ENABLE_NLS, translate the message first using dgettext.
26532 2017-01-03  Jeff Law  <law@redhat.com>
26534         PR tree-optimizatin/78856
26535         * tree-ssa-threadupdate.c: Include tree-vectorizer.h.
26536         (mark_threaded_blocks): Remove code to truncate thread paths that
26537         cross multiple loop headers.  Instead invalidate the cached loop
26538         iteration information and handle case of a thread path walking
26539         into an irreducible region.
26541 2017-01-03  Michael Meissner  <meissner@linux.vnet.ibm.com>
26543         PR target/78900
26544         * config/rs6000/rs6000.c (rs6000_split_signbit): Change some
26545         assertions.  Add support for doing the signbit if the IEEE 128-bit
26546         floating point value is in a GPR.
26547         * config/rs6000/rs6000.md (Fsignbit): Delete.
26548         (signbit<mode>2_dm): Delete using <Fsignbit> and just use "wa".
26549         Update the length attribute if the value is in a GPR.
26550         (signbit<mode>2_dm_<su>ext): Add combiner pattern to eliminate
26551         the sign or zero extension instruction, since the value is always 0/1.
26552         (signbit<mode>2_dm2): Delete using <Fsignbit>.
26554         PR target/78953
26555         * config/rs6000/vsx.md (vsx_extract_<mode>_store_p9): If we are
26556         extracting SImode to a GPR register so that we can generate a
26557         store, limit the vector to be in a traditional Altivec register
26558         for the vextuwrx instruction.
26560 2017-01-03  Ian Lance Taylor  <iant@google.com>
26562         * godump.c (go_format_type): Treat ENUMERAL_TYPE like INTEGER_TYPE.
26564 2017-01-03  Martin Sebor  <msebor@redhat.com>
26566         PR tree-optimization/78696
26567         * gimple-ssa-sprintf.c (format_floating): Correct handling of
26568         precision.  Use MPFR for %f for greater fidelity.  Correct handling
26569         of %g.
26570         (pass_sprintf_length::compute_format_length): Set width and precision
26571         specified by asrerisk to void_node for vararg functions.
26572         (try_substitute_return_value): Adjust dump output.
26574 2017-01-03  David Edelsohn  <dje.gcc@gmail.com>
26576         * doc/invoke.texi (RS6000 options): LRA is enabled by default.
26578 2017-01-03  Eric Botcazou  <ebotcazou@adacore.com>
26580         * doc/invoke.texi (SPARC options): Document -mlra as the default.
26581         * config/sparc/sparc.c (sparc_option_override): Force LRA unless
26582         -mlra/-mno-lra was passed to the compiler.
26584 2017-01-03  James Cowgill  <James.Cowgill@imgtec.com>
26586         PR rtl-optimization/65618
26587         * emit-rtl.c (try_split): Move initialization of "before" and
26588         "after" to just before the call to emit_insn_after_setloc.
26590 2017-01-03  Gerald Pfeifer  <gerald@pfeifer.com>
26592         * doc/md.texi (Standard Names): Remove reference to Java frontend.
26594 2017-01-03  Pierre-Marie de Rodat  <derodat@adacore.com>
26596         * dwarf2out.c (gen_enumeration_type_die): When
26597         -gno-strict-dwarf, add a DW_AT_encoding attribute.
26599 2017-01-03  Jakub Jelinek  <jakub@redhat.com>
26601         PR tree-optimization/78965
26602         * gimple-ssa-sprintf.c (pass_sprintf_length::compute_format_length):
26603         Change first argument from const call_info & to call_info &.  For %n
26604         set info.nowrite to false.
26606         PR middle-end/78901
26607         * gimple-ssa-sprintf.c (try_substitute_return_value): Don't change
26608         possibly throwing calls.
26610         * genmatch.c (dt_node::gen_kids_1): If generic_exprs include SSA_NAME
26611         and exprs_len || fns_len, emit the code for SSA_NAME next to the exprs
26612         and fns handling, rather than in a separate case SSA_NAME.
26614 2017-01-02  Jeff Law  <law@redhat.com>
26616         * config/darwin-driver.c (darwin_driver_init): Const-correctness
26617         fixes for first_period and second_period variables.
26619 2017-01-02  Uros Bizjak  <ubizjak@gmail.com>
26621         PR target/78967
26622         * config/i386/i386.md (UNSPEC_NOREX_MEM): New unspec.
26623         (*insvqi_1): New insn pattern.
26624         (*insvqi_1_mem_rex64): Ditto.
26625         (*insvqi_2): Ditto.
26626         (*insvqi_3): Rename from *insvqi.
26628         (*extzvqi_mem_rex64): Add UNSPEC_NOREX_MEM tag.
26630 2017-01-02  Gerald Pfeifer  <gerald@pfeifer.com>
26632         * doc/cfg.texi (Edges): Remove reference to Java.
26633         (Maintaining the CFG): Ditto.
26635 2017-01-01  Jan Hubicka  <hubicka@ucw.cz>
26637         PR middle-end/77674
26638         * symtab.c (symtab_node::binds_to_current_def_p): Fix handling of
26639         transparent aliases.
26641 2017-01-01  Jan Hubicka  <hubicka@ucw.cz>
26643         PR middle-end/77484
26644         * predict.def (PRED_CALL): Update hitrate.
26645         (PRED_INDIR_CALL, PRED_POLYMORPHIC_CALL): New predictors.
26646         * predict.c (tree_estimate_probability_bb): Split CALL predictor
26647         into direct/indirect/polymorphic variants.
26649 2017-01-01  Jakub Jelinek  <jakub@redhat.com>
26651         Update copyright years.
26653         * gcc.c (process_command): Update copyright notice dates.
26654         * gcov-dump.c (print_version): Ditto.
26655         * gcov.c (print_version): Ditto.
26656         * gcov-tool.c (print_version): Ditto.
26657         * gengtype.c (create_file): Ditto.
26658         * doc/cpp.texi: Bump @copying's copyright year.
26659         * doc/cppinternals.texi: Ditto.
26660         * doc/gcc.texi: Ditto.
26661         * doc/gccint.texi: Ditto.
26662         * doc/gcov.texi: Ditto.
26663         * doc/install.texi: Ditto.
26664         * doc/invoke.texi: Ditto.
26666 Copyright (C) 2017 Free Software Foundation, Inc.
26668 Copying and distribution of this file, with or without modification,
26669 are permitted in any medium without royalty provided the copyright
26670 notice and this notice are preserved.