support --with-multilib-list=@name for ARM
[gcc.git] / gcc / ChangeLog
1 2018-12-21 Alexandre Oliva <oliva@adacore.com>
2
3 * config.gcc (tmake_file): Add name to tmake_file for
4 each @name in --with-multilib-list on arm-*-* targets.
5 * doc/install.texi (with-multilib-list): Document it.
6
7 2018-12-21 Jakub Jelinek <jakub@redhat.com>
8
9 * tree-vect-data-refs.c (vect_enhance_data_refs_alignment): Use
10 DR_TARGET_ALIGNMENT on dr_info rather than dr. Spelling fixes.
11
12 2018-12-20 Joern Rennecke <joern.rennecke@riscy-ip.com>
13
14 * tree-vect-data-refs.c (vect_enhance_data_refs_alignment): Don't do
15 versioning for data accesses with misaligned step.
16
17 2018-12-20 H.J. Lu <hongjiu.lu@intel.com>
18
19 PR c/51628
20 * doc/invoke.texi: Document -Wno-address-of-packed-member.
21
22 2018-12-20 Vladimir Makarov <vmakarov@redhat.com>
23
24 PR target/88457
25 * ira-color.c (fast_allocation): Choose the best cost hard reg.
26
27 2018-12-20 Richard Sandiford <richard.sandiford@arm.com>
28
29 * config/aarch64/iterators.md (SVE_INT_UNARY, fp_int_op): Add abs.
30 (SVE_FP_UNARY): Sort.
31
32 2018-12-20 Richard Sandiford <richard.sandiford@arm.com>
33
34 * config/aarch64/aarch64-sve.md (*cond_<optab><mode>_4): Use
35 sve_fmla_op rather than sve_fmad_op for the movprfx alternative.
36
37 2018-12-20 Martin Jambor <mjambor@suse.cz>
38
39 PR ipa/88214
40 * tree-ssa-alias.c (ao_ref_init_from_ptr_and_size): Assert that
41 ptr is a pointer.
42
43 2018-12-20 Richard Biener <rguenther@suse.de>
44
45 PR tree-optimization/84362
46 * tree-ssa-loop-im.c: Include alias.h, builtins.h and tree-dfa.h.
47 (struct im_mem_ref): add ref_canonical flag.
48 (struct mem_ref_hasher): Use ao_ref as compare_type.
49 (mem_ref_hasher::equal): Adjust and add variant comparing ao_ref
50 parts.
51 (mem_ref_alloc): Take ao_ref parameter, initialize ref_canonical
52 member.
53 (gather_mem_refs_stmt): Set up ao_ref early and do the lookup
54 using it. If we have non-equal refs canonicalize the one
55 in the hashtable used for insertion.
56 (tree_ssa_lim_initialize): Adjust.
57
58 2018-12-20 Jakub Jelinek <jakub@redhat.com>
59
60 PR target/88547
61 * config/i386/i386.c (ix86_expand_sse_movcc): For maskcmp, try to
62 emit vpmovm2? instruction perhaps after knot?. Reorganize code
63 so that it doesn't have to test !maskcmp in almost every conditional.
64
65 2018-12-20 Alan Modra <amodra@gmail.com>
66
67 * config/rs6000/sysv4.h (GNU_USER_DYNAMIC_LINKER): Define.
68
69 2018-12-19 Andreas Tobler <andreast@gcc.gnu.org>
70
71 * config.gcc: Enable TARGET_DEFAULT_ASYNC_UNWIND_TABLES on
72 aarch64*-*-freebsd*
73
74 2018-12-19 Uros Bizjak <ubizjak@gmail.com>
75
76 * config/i386/i386.md (SWI1248_AVX512BWDQ_64): Rename from
77 SWI1248_AVX512BWDQ2_64. Unconditionally enable HImode.
78 (*cmp<mode>_ccz_1): Emit kortest instead of ktest insn.
79 Use SWI1248_AVX512BWDQ_64 mode iterator and enable only for
80 TARGET_AVX512F.
81
82 2018-12-19 Thomas Preud'homme <thomas.preudhomme@linaro.org>
83
84 * config/arm/elf.h: Update comment about condition that need to
85 match with libgcc/config/arm/lib1funcs.S to also include
86 libgcc/config/arm/t-arm.
87 * doc/sourcebuild.texi (output-exists, output-exists-not): Rename
88 subsubsection these directives are in to "Check for output files".
89 Move scan-symbol to that section and add to it new scan-symbol-not
90 directive.
91
92 2018-12-19 Tom de Vries <tdevries@suse.de>
93
94 * config/nvptx/nvptx.c (PTX_CTA_SIZE): Define.
95
96 2018-12-19 Tom de Vries <tdevries@suse.de>
97
98 * omp-offload.c (oacc_fn_attrib_level): Remove static.
99 * omp-offload.h (oacc_fn_attrib_level): Declare.
100
101 2018-12-19 Tom de Vries <tdevries@suse.de>
102
103 * omp-offload.c (oacc_get_default_dim): New function.
104 * omp-offload.h (oacc_get_default_dim): Declare.
105
106 2018-12-19 David Malcolm <dmalcolm@redhat.com>
107
108 PR c++/87504
109 * gcc-rich-location.c
110 (maybe_range_label_for_tree_type_mismatch::get_text): Move here from
111 c/c-typeck.c.
112 (binary_op_rich_location::binary_op_rich_location): New ctor.
113 (binary_op_rich_location::use_operator_loc_p): New function.
114 * gcc-rich-location.h
115 (class maybe_range_label_for_tree_type_mismatch)): Move here from
116 c/c-typeck.c.
117 (struct op_location_t): New forward decl.
118 (class binary_op_rich_location): New class.
119 * tree.h (struct op_location_t): New struct.
120
121 2018-12-19 David Malcolm <dmalcolm@redhat.com>
122
123 PR c++/43064
124 PR c++/43486
125 * convert.c: Include "selftest.h".
126 (preserve_any_location_wrapper): New function.
127 (convert_to_pointer_maybe_fold): Update to handle location
128 wrappers.
129 (convert_to_real_maybe_fold): Likewise.
130 (convert_to_integer_1): Strip expr when using TREE_OVERFLOW.
131 Handle location wrappers when checking for INTEGER_CST.
132 (convert_to_integer_maybe_fold): Update to handle location
133 wrappers.
134 (convert_to_complex_maybe_fold): Likewise.
135 (selftest::test_convert_to_integer_maybe_fold): New functions.
136 (selftest::convert_c_tests): New function.
137 * convert.h (preserve_any_location_wrapper): New decl.
138 * fold-const.c (size_binop_loc): Strip location wrappers when
139 using TREE_OVERFLOW.
140 (operand_equal_p): Strip any location wrappers.
141 (integer_valued_real_p): Strip any location wrapper.
142 * selftest-run-tests.c (selftest::run_tests): Call
143 selftest::convert_c_tests.
144 * selftest.h (selftest::convert_c_tests): New decl.
145 * tree.c (build_complex): Assert that REAL and IMAG are constants.
146 (integer_zerop): Look through location wrappers.
147 (integer_onep): Likewise.
148 (integer_each_onep): Likewise.
149 (integer_all_onesp): Likewise.
150 (integer_minus_onep): Likewise.
151 (integer_pow2p): Likewise.
152 (integer_nonzerop): Likewise.
153 (integer_truep): Likewise.
154 (fixed_zerop): Likewise.
155 (real_zerop): Likewise.
156 (real_onep): Likewise.
157 (real_minus_onep): Likewise.
158 (tree_int_cst_equal): Likewise.
159 (simple_cst_equal): Treat location wrappers with non-equal source
160 locations as being unequal.
161 (uniform_integer_cst_p): Look through location wrappers.
162 (maybe_wrap_with_location): Don't create wrappers if any
163 auto_suppress_location_wrappers are active.
164 (suppress_location_wrappers): New variable.
165 (selftest::test_predicates): New test.
166 (selftest::tree_c_tests): Call it.
167 * tree.h (CONSTANT_CLASS_OR_WRAPPER_P): New macro.
168 (suppress_location_wrappers): New decl.
169 (class auto_suppress_location_wrappers): New class.
170
171 2018-12-19 Paul A. Clarke <pc@us.ibm.com>
172
173 * config/rs6000/tmmintrin.h (_mm_hadds_epi16): Vector lanes swapped.
174 (_mm_hsub_epi32): Likewise.
175 (_mm_shuffle_epi8): Fix reversed interpretation of parameters.
176 (_mm_shuffle_pi8): Likewise.
177 (_mm_addubs_pi16): Likewise.
178
179 2018-12-19 Thomas Preud'homme <thomas.preudhomme@linaro.org>
180
181 * config/arm/arm.h (TARGET_HARD_FLOAT): Restrict to TARGET_32BIT
182 targets.
183 * config/arm/arm.c (output_return_instruction): Only check
184 TARGET_HARD_FLOAT to decide whether FP instructions are available.
185
186 2018-12-19 Tom de Vries <tom@codesourcery.com>
187
188 * doc/sourcebuild.texi (Commands for use in dg-final, Scan optimization
189 dump files): Add offload-rtl.
190
191 2018-12-19 Segher Boessenkool <segher@kernel.crashing.org>
192
193 PR target/88213
194 * config/rs6000/vsx.md (*vsx_extract_<P:mode>_<VSX_D:mode>_load):
195 Require TARGET_POWERPC64.
196
197 2018-12-19 Richard Biener <rguenther@suse.de>
198
199 PR tree-optimization/88533
200 Revert
201 2018-04-30 Richard Biener <rguenther@suse.de>
202
203 PR tree-optimization/28364
204 PR tree-optimization/85275
205 * tree-ssa-loop-ch.c (ch_base::copy_headers): Stop after
206 copying first exit test.
207
208 * tree-ssa-loop-ch.c: Include tree-phinodes.h and
209 ssa-iterators.h.
210 (should_duplicate_loop_header_p): Track whether stmt compute
211 loop invariants or values based on IVs. Apart from the
212 original loop header only duplicate blocks with exit tests
213 that are based on IVs or invariants.
214
215 2018-12-19 Tom de Vries <tdevries@suse.de>
216
217 * config/nvptx/nvptx.c (nvptx_gen_shared_bcast, shared_prop_gen)
218 (nvptx_goacc_expand_accel_var): Use MAX and ROUND_UP.
219 (nvptx_assemble_value, nvptx_output_skip): Use MIN.
220 (nvptx_shared_propagate, nvptx_single, nvptx_expand_shared_addr): Use
221 MAX.
222
223 2018-12-19 Tom de Vries <tdevries@suse.de>
224
225 * config/nvptx/nvptx.c (nvptx_gen_wcast): Rename as
226 nvptx_gen_warp_bcast.
227 (nvptx_gen_wcast): Rename to nvptx_gen_shared_bcast, add bool
228 vector argument, and update call to nvptx_gen_shared_bcast.
229 (propagator_fn): Add bool argument.
230 (nvptx_propagate): New bool argument, pass bool argument to fn.
231 (vprop_gen): Rename to warp_prop_gen, update call to
232 nvptx_gen_warp_bcast.
233 (nvptx_vpropagate): Rename to nvptx_warp_propagate, update call to
234 nvptx_propagate.
235 (wprop_gen): Rename to shared_prop_gen, update call to
236 nvptx_gen_shared_bcast.
237 (nvptx_wpropagate): Rename to nvptx_shared_propagate, update call
238 to nvptx_propagate.
239 (nvptx_wsync): Rename to nvptx_cta_sync.
240 (nvptx_single): Update calls to nvptx_gen_warp_bcast,
241 nvptx_gen_shared_bcast and nvptx_cta_sync.
242 (nvptx_process_pars): Likewise.
243 (write_worker_buffer): Rename as write_shared_buffer.
244 (nvptx_file_end): Update calls to write_shared_buffer.
245 (nvptx_expand_worker_addr): Rename as nvptx_expand_shared_addr.
246 (nvptx_expand_builtin): Update call to nvptx_expand_shared_addr.
247 (nvptx_get_worker_red_addr): Rename as nvptx_get_shared_red_addr.
248 (nvptx_goacc_reduction_setup): Update call to
249 nvptx_get_shared_red_addr.
250 (nvptx_goacc_reduction_fini): Likewise.
251 (nvptx_goacc_reduction_teardown): Likewise.
252
253 2018-12-19 Tom de Vries <tdevries@suse.de>
254
255 * config/nvptx/nvptx.c (worker_bcast_size): Rename as
256 oacc_bcast_size.
257 (worker_bcast_align): Rename as oacc_bcast_align.
258 (worker_bcast_sym): Rename as oacc_bcast_sym.
259 (nvptx_option_override): Update usage of oacc_bcast_*.
260 (struct wcast_data_t): Rename as broadcast_data_t.
261 (nvptx_gen_wcast): Update type of data argument and usage of
262 oacc_bcast_align.
263 (wprop_gen): Update type of data_ and usage of oacc_bcast_align.
264 (nvptx_wpropagate): Update type of data and usage of
265 oacc_bcast_{sym,size}.
266 (nvptx_single): Update type of data and usage of oacc_bcast_size.
267 (nvptx_file_end): Update usage of oacc_bcast_{sym,align,size}.
268
269 2018-12-19 Tom de Vries <tdevries@suse.de>
270
271 * config/nvptx/nvptx.md (nvptx_barsync): Add and handle operand.
272 * config/nvptx/nvptx.c (nvptx_wsync): Update call to gen_nvptx_barsync.
273
274 2018-12-19 Tom de Vries <tdevries@suse.de>
275
276 * config/nvptx/nvptx.c (nvptx_single): Always pass false to
277 nvptx_wsync.
278 (nvptx_process_pars): Likewise.
279
280 2018-12-19 Tom de Vries <tdevries@suse.de>
281
282 * config/nvptx/nvptx.c (nvptx_previous_fndecl): Declare.
283 (nvptx_set_current_function): New function.
284 (TARGET_SET_CURRENT_FUNCTION): Define.
285
286 2018-12-19 Shaokun Zhang <zhangshaokun@hisilicon.com>
287
288 * config/aarch64/aarch64-cores.def (tsv110): Fix architecture. This
289 part is really Armv8.2 with some permitted Armv8.4 extensions.
290
291 2018-12-19 Jakub Jelinek <jakub@redhat.com>
292
293 PR target/88541
294 * config/i386/vpclmulqdqintrin.h (_mm256_clmulepi64_epi128): Enable
295 for -mavx -mvpclmulqdq rather than just for -mavx512vl -mvpclmulqdq.
296
297 2018-12-19 Alexandre Oliva <aoliva@redhat.com>
298
299 PR testsuite/86153
300 PR middle-end/83239
301 * vr-values.c
302 (vr_values::vrp_evaluate_conditional_warnv_with_ops): Extend
303 simplification of overflow tests to cover cases in which we
304 can determine the result of the comparison.
305
306 2018-12-19 Bin Cheng <bin.cheng@linux.alibaba.com>
307
308 * auto-profile.c (afdo_indirect_call): Skip generating histogram
309 value if we can't find cgraph_node for then indirected callee. Save
310 profile_id of the cgraph_node in histogram value's first counter.
311 * value-prof.c (gimple_value_profile_transformations): Don't skip
312 for flag_auto_profile.
313
314 2018-12-18 Vladimir Makarov <vmakarov@redhat.com>
315
316 PR rtl-optimization/87759
317 * lra-assigns.c (lra_split_hard_reg_for): Recalculate
318 non_reload_pseudos.
319
320 2018-12-18 Jakub Jelinek <jakub@redhat.com>
321
322 PR target/88464
323 * config/i386/i386-builtin-types.def
324 (VOID_FTYPE_PDOUBLE_QI_V8SI_V4DF_INT,
325 VOID_FTYPE_PFLOAT_QI_V4DI_V8SF_INT,
326 VOID_FTYPE_PLONGLONG_QI_V8SI_V4DI_INT,
327 VOID_FTYPE_PINT_QI_V4DI_V8SI_INT,
328 VOID_FTYPE_PDOUBLE_QI_V4SI_V2DF_INT,
329 VOID_FTYPE_PFLOAT_QI_V2DI_V4SF_INT,
330 VOID_FTYPE_PLONGLONG_QI_V4SI_V2DI_INT,
331 VOID_FTYPE_PINT_QI_V2DI_V4SI_INT): New builtin types.
332 * config/i386/i386.c (enum ix86_builtins): Add
333 IX86_BUILTIN_SCATTERALTSIV4DF, IX86_BUILTIN_SCATTERALTDIV8SF,
334 IX86_BUILTIN_SCATTERALTSIV4DI, IX86_BUILTIN_SCATTERALTDIV8SI,
335 IX86_BUILTIN_SCATTERALTSIV2DF, IX86_BUILTIN_SCATTERALTDIV4SF,
336 IX86_BUILTIN_SCATTERALTSIV2DI and IX86_BUILTIN_SCATTERALTDIV4SI.
337 (ix86_init_mmx_sse_builtins): Fix up names of IX86_BUILTIN_GATHERALT*,
338 IX86_BUILTIN_GATHER3ALT* and IX86_BUILTIN_SCATTERALT* builtins to
339 match the IX86_BUILTIN codes. Build IX86_BUILTIN_SCATTERALTSIV4DF,
340 IX86_BUILTIN_SCATTERALTDIV8SF, IX86_BUILTIN_SCATTERALTSIV4DI,
341 IX86_BUILTIN_SCATTERALTDIV8SI, IX86_BUILTIN_SCATTERALTSIV2DF,
342 IX86_BUILTIN_SCATTERALTDIV4SF, IX86_BUILTIN_SCATTERALTSIV2DI and
343 IX86_BUILTIN_SCATTERALTDIV4SI decls.
344 (ix86_vectorize_builtin_scatter): Expand those new builtins.
345
346 2018-12-18 Bill Schmidt <wschmidt@linux.ibm.com>
347
348 * doc/extend.texi (PowerPC Altivec/VSX Built-in Functions):
349 Describe when a typedef name can be used as the type specifier for
350 a vector type, and when it cannot.
351
352 2018-12-18 Jozef Lawrynowicz <jozef.l@mittosystems.com>
353
354 * config/msp430/msp430.h: Define TARGET_VTABLE_ENTRY_ALIGN.
355
356 2018-12-18 Jakub Jelinek <jakub@redhat.com>
357
358 PR target/88513
359 PR target/88514
360 * optabs.def (vec_pack_sbool_trunc_optab, vec_unpacks_sbool_hi_optab,
361 vec_unpacks_sbool_lo_optab): New optabs.
362 * optabs.c (expand_widen_pattern_expr): Use vec_unpacks_sbool_*_optab
363 and pass additional argument if both input and target have the same
364 scalar mode of VECTOR_BOOLEAN_TYPE_P vectors.
365 * expr.c (expand_expr_real_2) <case VEC_PACK_TRUNC_EXPR>: Handle
366 VECTOR_BOOLEAN_TYPE_P pack where result has the same scalar mode
367 as the operands using vec_pack_sbool_trunc_optab.
368 * tree-vect-stmts.c (supportable_widening_operation): Use
369 vec_unpacks_sbool_{lo,hi}_optab for VECTOR_BOOLEAN_TYPE_P conversions
370 where both wider_vectype and vectype have the same scalar mode.
371 (supportable_narrowing_operation): Similarly use
372 vec_pack_sbool_trunc_optab if narrow_vectype and vectype have the same
373 scalar mode.
374 * config/i386/i386.c (ix86_get_builtin)
375 <case IX86_BUILTIN_GATHER3ALTDIV8SF>: Check for VECTOR_MODE_P
376 rather than non-VOIDmode.
377 * config/i386/sse.md (vec_pack_trunc_qi, vec_pack_trunc_<mode>):
378 Remove useless ()s around "register_operand", formatting fixes.
379 (vec_pack_sbool_trunc_qi, vec_unpacks_sbool_lo_qi,
380 vec_unpacks_sbool_hi_qi): New expanders.
381 * doc/md.texi (vec_pack_sbool_trunc_M, vec_unpacks_sbool_hi_M,
382 vec_unpacks_sbool_lo_M): Document.
383
384 2018-12-18 Jozef Lawrynowicz <jozef.l@mittosystems.com>
385
386 * combine.c (update_rsp_from_reg_equal): Only look for the nonzero bits
387 of src in nonzero_bits_mode if the mode of src is MODE_INT and
388 HWI_COMPUTABLE.
389 (reg_nonzero_bits_for_combine): Add clarification to comment.
390
391 2018-12-18 Wei Xiao <wei3.xiao@intel.com>
392
393 * config/i386/driver-i386.c (host_detect_local_cpu): Detect cascadelake.
394 * config/i386/i386.c (fold_builtin_cpu): Handle cascadelake.
395 * doc/extend.texi: Add cascadelake.
396 2018-12-17 Peter Bergner <bergner@linux.ibm.com>
397
398 PR target/87870
399 * config/rs6000/vsx.md (nW): New mode iterator.
400 (vsx_mov<mode>_64bit): Use it. Remove redundant GPR 0/-1 alternative.
401 Update length attribute for (<??r>, <nW>) alternative.
402 (vsx_mov<mode>_32bit): Likewise.
403
404 2018-12-17 Tom de Vries <tdevries@suse.de>
405
406 * config/nvptx/nvptx.c (PTX_VECTOR_LENGTH, PTX_WORKER_LENGTH,
407 PTX_DEFAULT_RUNTIME_DIM): Move to the top of the file.
408
409 2018-12-17 Tom de Vries <tdevries@suse.de>
410
411 * config/nvptx/nvptx.c (PTX_WARP_SIZE): Define.
412 (nvptx_simt_vf): Return PTX_WARP_SIZE instead of PTX_VECTOR_LENGTH.
413
414 2018-12-17 Tom de Vries <tdevries@suse.de>
415
416 * config/nvptx/nvptx.c (nvptx_single): Fix whitespace.
417 (nvptx_neuter_pars): Likewise.
418
419 2018-12-17 Tom de Vries <tdevries@suse.de>
420
421 * config/nvptx/nvptx.c (nvptx_goacc_validate_dims): Work around Fortran
422 bug PR72741 by overriding dims parameter for routines.
423
424 2018-12-17 Tom de Vries <tdevries@suse.de>
425
426 * config/nvptx/nvptx.c (nvptx_goacc_validate_dims): Rewrite using
427 predicate vars.
428
429 2018-12-17 Steve Ellcey <sellcey@cavium.com>
430
431 * config/aarch64/aarch64-protos.h (aarch64_use_simple_return_insn_p):
432 New prototype.
433 (aarch64_epilogue_uses): Ditto.
434 * config/aarch64/aarch64.c (aarch64_attribute_table): New array.
435 (aarch64_simd_decl_p): New function.
436 (aarch64_reg_save_mode): New function.
437 (aarch64_function_ok_for_sibcall): Check for simd calls.
438 (aarch64_layout_frame): Check for simd function.
439 (aarch64_gen_storewb_pair): Handle E_TFmode.
440 (aarch64_push_regs): Use aarch64_reg_save_mode to get mode.
441 (aarch64_gen_loadwb_pair): Handle E_TFmode.
442 (aarch64_pop_regs): Use aarch64_reg_save_mode to get mode.
443 (aarch64_gen_store_pair): Handle E_TFmode.
444 (aarch64_gen_load_pair): Ditto.
445 (aarch64_save_callee_saves): Handle different mode sizes.
446 (aarch64_restore_callee_saves): Ditto.
447 (aarch64_components_for_bb): Check for simd function.
448 (aarch64_epilogue_uses): New function.
449 (aarch64_process_components): Check for simd function.
450 (aarch64_expand_prologue): Ditto.
451 (aarch64_expand_epilogue): Ditto.
452 (aarch64_expand_call): Ditto.
453 (aarch64_use_simple_return_insn_p): New function.
454 (TARGET_ATTRIBUTE_TABLE): New define.
455 * config/aarch64/aarch64.h (EPILOGUE_USES): Redefine.
456 (FP_SIMD_SAVED_REGNUM_P): New macro.
457 * config/aarch64/aarch64.md (simple_return): New define_expand.
458 (load_pair_dw_tftf): New instruction.
459 (store_pair_dw_tftf): Ditto.
460 (loadwb_pair<TX:mode>_<P:mode>): Ditto.
461 (storewb_pair<TX:mode>_<P:mode>): Ditto.
462
463 2018-12-17 Uros Bizjak <ubizjak@gmail.com>
464
465 PR target/88502
466 * internal-fn.def (ACOSH): New.
467 (ASINH): Ditto.
468 (ATANH): Ditto.
469 * optabs.def (acosh_optab): New.
470 (asinh_optab): Ditto.
471 (atanh_optab): Ditto.
472 * config/i386/i386-protos.h (ix86_emit_i387_asinh): New prototype.
473 (ix86_emit_i387_acosh): Ditto.
474 (ix86_emit_i387_atanh): Ditto.
475 * config/i386/i386.c (ix86_emit_i387_asinh): New function.
476 (ix86_emit_i387_acosh): Ditto.
477 (ix86_emit_i387_atanh): Ditto.
478 * config/i386/i386.md (asinhxf2): New expander.
479 (asinh<mode>2): Ditto.
480 (acoshxf2): Ditto.
481 (acosh<mode>2): Ditto.
482 (atanhxf2): Ditto.
483 (atanh<mode>2): Ditto.
484
485 2018-12-17 David Edelsohn <dje.gcc@gmail.com>
486
487 * config.gcc (powerpc-ibm-aix6.*): Delete extra_headers.
488 (powerpc-ibm-aix7.1.*): Same.
489 (powerpc-ibm-aix[789].*): Same.
490
491 2018-12-17 H.J. Lu <hongjiu.lu@intel.com>
492
493 PR debug/79342
494 * dwarf2out.c (find_AT_string_in_table): Add insert argument
495 defaulting to INSERT and replace INSERT.
496 (find_AT_string): Likewise.
497 (output_macinfo_op): Pass NO_INSERT to find_AT_string.
498
499 2018-12-15 Jan Hubicka <hubicka@ucw.cz>
500
501 * coverage.c (struct conts_entry): Add n_counts.
502 (remap_counts_file): Record number of ocunts.
503 (get_coverage_counts): Verify that counts match.
504 * coverage.h (get_coverage_counts): Update prototype.
505 * profile.c (get_exec_counts. compute_value_histograms): Add
506 n_counts parametrs.
507
508 2018-12-17 Senthil Kumar Selvaraj <senthilkumar.selvaraj@microchip.com>
509
510 PR rtl-optimization/88253
511 * combine.c (combine_simplify_rtx): Test for side-effects before
512 substituting by zero.
513
514 2018-12-17 Richard Sandiford <richard.sandiford@arm.com>
515
516 * doc/invoke.texi (-fversion-loops-for-strides): Document
517 (loop-versioning-group-size, loop-versioning-max-inner-insns)
518 (loop-versioning-max-outer-insns): Document new --params.
519 * Makefile.in (OBJS): Add gimple-loop-versioning.o.
520 * common.opt (fversion-loops-for-strides): New option.
521 * opts.c (default_options_table): Enable fversion-loops-for-strides
522 at -O3.
523 * params.def (PARAM_LOOP_VERSIONING_GROUP_SIZE)
524 (PARAM_LOOP_VERSIONING_MAX_INNER_INSNS)
525 (PARAM_LOOP_VERSIONING_MAX_OUTER_INSNS): New parameters.
526 * passes.def: Add pass_loop_versioning.
527 * timevar.def (TV_LOOP_VERSIONING): New time variable.
528 * tree-ssa-propagate.h
529 (substitute_and_fold_engine::substitute_and_fold): Add an optional
530 block parameter.
531 * tree-ssa-propagate.c
532 (substitute_and_fold_engine::substitute_and_fold): Likewise.
533 When passed, only walk blocks dominated by that block.
534 * tree-vrp.h (range_includes_p): Declare.
535 (range_includes_zero_p): Turn into an inline wrapper around
536 range_includes_p.
537 * tree-vrp.c (range_includes_p): New function, generalizing...
538 (range_includes_zero_p): ...this.
539 * tree-pass.h (make_pass_loop_versioning): Declare.
540 * gimple-loop-versioning.cc: New file.
541
542 2018-12-15 Jan Hubicka <hubicka@ucw.cz>
543
544 * ipa-fnsummary.c (remap_edge_change_prob): Do not ICE when changes
545 are not streamed in.
546
547 2018-12-15 H.J. Lu <hongjiu.lu@intel.com>
548
549 PR target/88483
550 * config/i386/i386.c (ix86_finalize_stack_frame_flags): Revert
551 reversion 267133.
552
553 2018-12-15 Jan Hubicka <hubicka@ucw.cz>
554
555 * ipa-fnsummary.c (analyze_function_body): Do not loeak conds and
556 size_time_table.
557 (ipa_fn_summary_generate): Add prevails parameter; do not allocate
558 data when symbol is not prevailing.
559 (inline_read_section): Likewise.
560
561 2018-12-15 Jan Hubicka <hubicka@ucw.cz>
562
563 * cgraph.h (cgraph_node): Add predicate prevailing_p.
564 (cgraph_edge): Add predicate possible_call_in_translation_unit_p.
565 * ipa-prop.c (ipa_write_jump_function): Optimize streaming of ADDR_EXPR.
566 (ipa_read_jump_function): Add prevails parameter; optimize streaming.
567 (ipa_read_edge_info): Break out from ...
568 (ipa_read_node_info): ... here; optimize streaming.
569 * cgraph.c (cgraph_edge::possibly_call_in_translation_unit_p): New
570 predicate.
571
572 2018-12-15 Jan Hubicka <hubicka@ucw.cz>
573
574 * ipa-utils.c (ipa_merge_profiles): Do no merging when source function
575 has zero count.
576
577 2018-12-15 Jakub Jelinek <jakub@redhat.com>
578
579 PR tree-optimization/88464
580 PR target/88498
581 * tree-vect-stmts.c (vect_build_gather_load_calls): For NARROWING
582 and mask with integral masktype, don't try to permute mask vectors,
583 instead emit VEC_UNPACK_{LO,HI}_EXPR. Fix up NOP_EXPR operand.
584 (vectorizable_store): Handle masked scatters with decl and integral
585 mask type.
586 (permute_vec_elements): Allow scalar_dest to be NULL.
587 * config/i386/i386.c (ix86_get_builtin)
588 <case IX86_BUILTIN_GATHER3ALTDIV16SF>: Use lowpart_subreg for masks.
589 <case IX86_BUILTIN_GATHER3ALTDIV8SF>: Don't assume mask and src have
590 to be the same.
591
592 2018-12-15 Jan Hubicka <hubicka@ucw.cz>
593
594 * ipa.c (cgraph_build_static_cdtor_1): Add OPTIMIZATION and TARGET
595 parameters.
596 (cgraph_build_static_cdtor): Update.
597 (build_cdtor): Use OPTIMIZATION and TARGET of the first real cdtor
598 callsed.
599
600 2018-12-15 Alan Modra <amodra@gmail.com>
601
602 * config/rs6000/rs6000.c (generate_set_vrsave, rs6000_emit_savres_rtx),
603 (rs6000_emit_prologue, rs6000_call_aix, rs6000_call_sysv),
604 (rs6000_call_darwin_1): Use gen_hard_reg_clobber.
605
606 2018-12-15 Jakub Jelinek <jakub@redhat.com>
607
608 PR target/88489
609 * config/i386/sse.md (UNSPEC_SFIXUPIMM): New unspec enumerator.
610 (avx512f_sfixupimm<mode><mask_name><round_saeonly_name>): Use it
611 instead of UNSPEC_FIXUPIMM.
612
613 PR rtl-optimization/88478
614 * cselib.c (cselib_record_sets): Move sets[i].src_elt tests
615 after REG_P (dest) test.
616
617 2018-12-14 Martin Sebor <msebor@redhat.com>
618
619 PR tree-optimization/88372
620 * calls.c (maybe_warn_alloc_args_overflow): Handle function pointers.
621 * tree-object-size.c (alloc_object_size): Same. Simplify.
622 * doc/extend.texi (Object Size Checking): Update.
623 (Other Builtins): Add __builtin_object_size.
624 (Common Type Attributes): Add alloc_size.
625 (Common Variable Attributes): Ditto.
626
627 2018-12-14 Martin Sebor <msebor@redhat.com>
628
629 PR rtl-optimization/87096
630 * gimple-ssa-sprintf.c (sprintf_dom_walker::handle_gimple_call): Avoid
631 folding calls whose bound may exceed INT_MAX. Diagnose bound ranges
632 that exceed the limit.
633
634 2018-12-14 Martin Sebor <msebor@redhat.com>
635
636 PR web/79738
637 * doc/extend.texi (attribute const, pure): Clarify.
638
639 2018-12-14 H.J. Lu <hongjiu.lu@intel.com>
640
641 * config/i386/i386.c (rest_of_insert_endbranch): Insert ENDBR
642 at the function entry only when -mmanual-endbr isn't used or
643 there is cf_check function attribute.
644 (ix86_attribute_table): Add cf_check.
645 * config/i386/i386.opt: Add -mmanual-endbr.
646 * doc/extend.texi: Document cf_check attribute.
647 * doc/invoke.texi: Document -mmanual-endbr.
648
649 2018-12-14 Thomas Schwinge <thomas@codesourcery.com>
650 Cesar Philippidis <cesar@codesourcery.com>
651
652 * omp-offload.c (inform_oacc_loop): New function.
653 (execute_oacc_device_lower): Use it to display loop parallelism.
654
655 2018-12-14 Jakub Jelinek <jakub@redhat.com>
656
657 PR c++/82294
658 PR c++/87436
659 * expr.h (categorize_ctor_elements): Add p_unique_nz_elts argument.
660 * expr.c (categorize_ctor_elements_1): Likewise. Compute it like
661 p_nz_elts, except don't multiply it by mult. Adjust recursive call.
662 Fix up COMPLEX_CST handling.
663 (categorize_ctor_elements): Add p_unique_nz_elts argument, initialize
664 it and pass it through to categorize_ctor_elements_1.
665 (mostly_zeros_p, all_zeros_p): Adjust categorize_ctor_elements callers.
666 * gimplify.c (gimplify_init_constructor): Likewise. Don't force
667 ctor into readonly data section if num_unique_nonzero_elements is
668 smaller or equal to 1/8 of num_nonzero_elements and size is >= 64
669 bytes.
670
671 2018-12-14 Thomas Preud'homme <thomas.preudhomme@arm.com>
672
673 * config/arm/arm.md (arm_movdi): Split if -mslow-flash-data and
674 source is a constant that would be loaded by literal pool.
675 (movsf expander): Generate a no_literal_pool_sf_immediate insn if
676 -mslow-flash-data is present, targeting hardfloat ABI and source is a
677 float constant that cannot be loaded via vmov.
678 (movdf expander): Likewise but generate a no_literal_pool_df_immediate
679 insn.
680 (arm_movsf_soft_insn): Split if -mslow-flash-data and source is a
681 float constant that would be loaded by literal pool.
682 (softfloat constant movsf splitter): Splitter for the above case.
683 (movdf_soft_insn): Split if -mslow-flash-data and source is a float
684 constant that would be loaded by literal pool.
685 (softfloat constant movdf splitter): Splitter for the above case.
686 * config/arm/constraints.md (Pz): Document existing constraint.
687 (Ha): Define constraint.
688 (Tu): Likewise.
689 * config/arm/predicates.md (hard_sf_operand): New predicate.
690 (hard_df_operand): Likewise.
691 * config/arm/thumb2.md (thumb2_movsi_insn): Split if
692 -mslow-flash-data and constant would be loaded by literal pool.
693 * constant/arm/vfp.md (thumb2_movsi_vfp): Likewise and disable constant
694 load in VFP register.
695 (movdi_vfp): Likewise.
696 (thumb2_movsf_vfp): Use hard_sf_operand as predicate for source to
697 prevent match for a constant load if -mslow-flash-data and constant
698 cannot be loaded via vmov. Adapt constraint accordingly by
699 using Ha instead of E for generic floating-point constant load.
700 (thumb2_movdf_vfp): Likewise using hard_df_operand predicate instead.
701 (no_literal_pool_df_immediate): Add a clobber to use as the
702 intermediate general purpose register and also enable it after reload
703 but disable it constant is a valid FP constant. Add constraints and
704 generate a DI intermediate load rather than 2 SI loads.
705 (no_literal_pool_sf_immediate): Add a clobber to use as the
706 intermediate general purpose register and also enable it after
707 reload.
708
709 2018-12-14 Uros Bizjak <ubizjak@gmail.com>
710
711 PR target/88474
712 * internal-fn.def (HYPOT): New.
713 * optabs.def (hypot_optab): New.
714 * config/i386/i386.md (hypot<mode>3): New expander.
715
716 2018-12-14 Jeff Law <law@redhat.com>
717
718 * target.def (post_cfi_startproc): Fix text.
719
720 2018-12-14 Sam Tebbs <sam.tebbs@arm.com>
721
722 * doc/tm.texi (TARGET_ASM_POST_CFI_STARTPROC): Define.
723 * doc/tm.texi.in (TARGET_ASM_POST_CFI_STARTPROC): Define.
724 * dwarf2out.c (dwarf2out_do_cfi_startproc): Trigger the hook.
725 * hooks.c (hook_void_FILEptr_tree): Define.
726 * hooks.h (hook_void_FILEptr_tree): Define.
727 * target.def (post_cfi_startproc): Define.
728
729 2018-12-14 Tom de Vries <tdevries@suse.de>
730
731 * lto-cgraph.c (verify_node_partition): New function.
732 (input_overwrite_node, input_varpool_node): Use verify_node_partition.
733
734 2018-12-14 H.J. Lu <hongjiu.lu@intel.com>
735
736 PR target/88483
737 * config/i386/i386.c (ix86_finalize_stack_frame_flags): Don't
738 use get_frame_size ().
739
740 2018-12-14 Andrew Stubbs <ams@codesourcery.com>
741
742 * gcc/lra-int.h (lra_register_new_scratch_op): Add third parameter.
743 * gcc/lra-remat.c (update_scratch_ops): Pass icode to
744 lra_register_new_scratch_op.
745 * gcc/lra.c (struct sloc): Add icode field.
746 (lra_register_new_scratch_op): Add icode parameter.
747 Use icode to skip insns that have changed beyond recognition.
748
749 2018-12-14 Eric Botcazou <ebotcazou@adacore.com>
750
751 * dwarf2out.c (analyze_discr_in_predicate): Simplify.
752 (analyze_variants_discr): Deal with naked boolean discriminants.
753
754 2018-12-14 Claudiu Zissulescu <claziss@synopsys.com>
755
756 * config/arc/arc.c (arc_restore_callee_milli) Don't clobber off
757 variable.
758
759 2018-12-14 Claudiu Zissulescu <claziss@synopsys.com>
760
761 * config/arc/arc.h (reg_class): Add SIBCALL_REGS.
762
763 2018-12-14 Richard Biener <rguenther@suse.de>
764
765 * gimple-ssa-split-paths.c (is_feasible_trace): Remove
766 duplicated code block.
767
768 2018-12-14 Alan Modra <amodra@gmail.com>
769
770 PR rtl-optimization/88311
771 * config/rs6000/rs6000.c (rs6000_call_sysv): Do not mask cookie.
772 (rs6000_sibcall_sysv): Likewise.
773
774 2018-12-14 Segher Boessenkool <segher@kernel.crashing.org>
775
776 PR rtl-optimization/88001
777 * function.c (match_asm_constraints_1): Don't invalidly share RTL.
778
779 2018-12-14 Bin Cheng <bin.cheng@linux.alibaba.com>
780
781 * auto-profile.c (afdo_annotate_cfg): Call update_max_bb_count even
782 if autofdo counts are all zeros.
783
784 2018-12-14 Bin Cheng <bin.cheng@linux.alibaba.com>
785
786 * auto-profile.c (afdo_indirect_call): Skip generating histogram
787 value for internal call.
788
789 2018-12-14 Bin Cheng <bin.cheng@linux.alibaba.com>
790
791 * auto-profile.c (AFDO_EINFO): New macro.
792 (class edge_info): New class.
793 (is_edge_annotated, set_edge_annotated): Delete.
794 (afdo_propagate_edge, afdo_propagate_circuit, afdo_propagate): Remove
795 parameter. Adjust edge count computation and annotation using class
796 edge_info.
797 (afdo_calculate_branch_prob, afdo_annotate_cfg): Likewise.
798
799 2018-12-13 Michael Ploujnikov <michael.ploujnikov@oracle.com>
800
801 * ipa-cp.c (print_all_lattices): Skip cp clones.
802
803 * ipa-cp.c: Fix various comment typos.
804
805 2018-12-13 Jakub Jelinek <jakub@redhat.com>
806
807 PR tree-optimization/88444
808 * tree-inline.c (fold_marked_statements): Iterate up to
809 last_basic_block_for_fn rather than n_basic_blocks_for_fn.
810
811 PR rtl-optimization/88470
812 * cfgcleanup.c (outgoing_edges_match): If the function is
813 shrink-wrapped and bb1 ends with a JUMP_INSN with a single fake
814 edge to EXIT, return false.
815
816 2018-12-13 Martin Sebor <msebor@redhat.com>
817
818 * doc/extend.texi: Consistently use @code for const and volatile
819 qualifiers, the true and false constants, and asm statements.
820
821 2018-12-13 Vladimir Makarov <vmakarov@redhat.com>
822
823 PR rtl-optimization/88414
824 * lra-int.h (lra_asm_error_p): New.
825 * lra-assigns.c (lra_assign): Check lra_asm_error_p for checking
826 call crossed pseudo assignment correctness.
827 (lra_split_hard_reg_for): Set up lra_asm_error_p.
828 * lra-constraints.c (curr_insn_transform): Ditto.
829 * lra.c (lra_asm_error_p): New.
830 (lra): Reset lra_asm_error_p.
831
832 2018-12-13 Jakub Jelinek <jakub@redhat.com>
833
834 PR rtl-optimization/88416
835 * valtrack.c (cleanup_auto_inc_dec): Handle pre/post-inc/dec/modify
836 even if !AUTO_INC_DEC.
837
838 2018-12-13 David Edelsohn <dje.gcc@gmail.com>
839
840 * config/rs6000/rs6000.c (rs6000_function_arg): Ensure type is
841 non-NULL.
842 (rs6000_arg_partial_bytes): Same.
843
844 2018-12-13 Jason Merrill <jason@redhat.com>
845
846 * gdbinit.in (pp): New macro.
847 (pbb): Remove.
848
849 2018-12-13 Jakub Jelinek <jakub@redhat.com>
850
851 PR tree-optimization/88464
852 * tree-vect-stmts.c (vect_build_gather_load_calls): Handle INTEGER_TYPE
853 masktype if mask is non-NULL.
854 (vectorizable_load): Don't reject masked gather loads if masktype
855 in the decl is INTEGER_TYPE.
856
857 2018-12-13 Andreas Krebbel <krebbel@linux.ibm.com>
858
859 * config/s390/s390-builtins.def (s390_vec_double_s64): Map to
860 s390_vec_double_s64 instead of s390_vcdgb.
861 (s390_vec_double_u64): Map to s390_vec_double_u64 instead of
862 s390_vcdlgb.
863
864 2018-12-13 Andreas Krebbel <krebbel@linux.ibm.com>
865
866 * config/s390/vx-builtins.md ("vec_ctd_s64", "vec_ctd_u64")
867 ("vec_ctsl", "vec_ctul"): Replace 0 with VEC_NOINEXACT.
868 ("vec_double_s64", "vec_double_u64"): Replace 4 with VEC_INEXACT.
869
870 2018-12-13 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
871
872 * doc/invoke.texi (-msve-vector-bits): Clarify -msve-vector-bits=128
873 behavior.
874
875 2018-12-13 Wei Xiao <wei3.xiao@intel.com>
876
877 * common/config/i386/i386-common.c (processor_names): Add cascadelake.
878 (processor_alias_table): Add cascadelake.
879 * config.gcc: Add -march=cascadelake.
880 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
881 cascadelake.
882 * config/i386/i386.c (Add m_CASCADELAKE): New.
883 (processor_cost_table): Add cascadelake.
884 (get_builtin_code_for_version): Handle cascadelake.
885 * config/i386/i386.h (TARGET_CASCADELAKE, PROCESSOR_CASCADELAKE): New.
886 (PTA_CASCADELAKE): Ditto.
887 * doc/invoke.texi: Add -march=cascadelake.
888
889 2018-12-13 Jakub Jelinek <jakub@redhat.com>
890
891 PR target/88465
892 * config/i386/i386.md (*movdi_internal, *movsi_internal,
893 *movhi_internal, *movqi_internal): Add alternative(s) to load
894 0 or -1 into k registers using kxor or kxnoq instructions.
895
896 PR target/88461
897 * config/i386/sse.md (VI1248_AVX512VLBW, AVX512ZEXTMASK): New
898 mode iterators.
899 (<avx512>_testm<mode>3<mask_scalar_merge_name>,
900 <avx512>_testnm<mode>3<mask_scalar_merge_name>): Merge patterns
901 with VI12_AVX512VL and VI48_AVX512VL iterators into ones with
902 VI1248_AVX512VLBW iterator.
903 (*<avx512>_testm<VI1248_AVX512VLBW:mode>3_zext,
904 *<avx512>_testm<VI1248_AVX512VLBW:mode>3_zext_mask,
905 *<avx512>_testnm<VI1248_AVX512VLBW:mode>3_zext,
906 *<avx512>_testnm<VI1248_AVX512VLBW:mode>3_zext_mask): New
907 define_insns.
908
909 PR target/88461
910 * config/i386/i386.md (*zero_extendsidi2, zero_extend<mode>di2,
911 *zero_extend<mode>si2, *zero_extendqihi2): Add =*k, *km alternatives.
912
913 2018-12-12 Tom de Vries <tdevries@suse.de>
914 Jakub Jelinek <jakub@redhat.com>
915
916 * omp-builtins.def (BUILT_IN_GOMP_LOOP_NONMONOTONIC_RUNTIME_START,
917 BUILT_IN_GOMP_LOOP_MAYBE_NONMONOTONIC_RUNTIME_START,
918 BUILT_IN_GOMP_LOOP_ULL_NONMONOTONIC_RUNTIME_START,
919 BUILT_IN_GOMP_LOOP_ULL_MAYBE_NONMONOTONIC_RUNTIME_START,
920 BUILT_IN_GOMP_PARALLEL_LOOP_NONMONOTONIC_RUNTIME,
921 BUILT_IN_GOMP_PARALLEL_LOOP_MAYBE_NONMONOTONIC_RUNTIME): Fix up
922 function types - remove one argument.
923
924 2018-12-12 Martin Sebor <msebor@redhat.com>
925
926 * doc/extend.texi (attribute copy): Fix typos.
927
928 2018-12-12 Martin Sebor <msebor@redhat.com>
929
930 * doc/extend.texi (Function Attributes): Clarify C++ aspects.
931 (Variable Attributes): Same.
932 (Type Attributes): Same.
933
934 2018-12-12 Olivier Hainque <hainque@adacore.com>
935
936 * config/aarch64/aarch64.c (aarch64_override_options): Once arch,
937 cpu and tune were validated, insert SUBTARGET_OVERRIDE_OPTIONS if
938 defined.
939
940 2018-12-12 Olivier Hainque <hainque@adacore.com>
941
942 * config/aarch64/aarch64.c (PROBE_STACK_FIRST_REG) : Redefine as
943 R9_REGNUM instead of 9.
944 (PROBE_STACK_SECOND_REG): Redefine as R10_REGNUM instead of 10.
945
946 2018-12-12 Eric Botcazou <ebotcazou@adacore.com>
947
948 PR target/86806
949 * config/sparc/sparc.md (unspecv): Add UNSPECV_SPECULATION_BARRIER.
950 (speculation_barrier): New instruction for V9.
951
952 2018-12-12 Segher Boessenkool <segher@kernel.crashing.org>
953 Iain Sandoe <iain@sandoe.co.uk>
954
955 PR target/88343
956 * config/rs6000/rs6000.c (save_reg_p): Do not save the picbase reg
957 unless it has been used.
958 (first_reg_to_save): Remove dead code.
959
960 2018-12-12 Iain Sandoe <iain@sandoe.co.uk>
961
962 * config/rs6000/rs6000-protos.h (rs6000_call_darwin): New.
963 (rs6000_sibcall_darwin): New. (macho_call_template): Remove.
964 * config/rs6000/rs6000.c (get_prev_label): Forward declaration.
965 (rs6000_call_template_1): Handle Darwin.
966 (macho_call_template): Remove.
967 (rs6000_call_sysv): Remove handling for Darwin.
968 (rs6000_call_darwin_1, rs6000_call_darwin): New
969 (rs6000_sibcall_darwin): New.
970 * config/rs6000/rs6000.md (define_expand “call”): Handle Darwin
971 with its own expander. (define_expand “call_value”): Likewise.
972 (define_expand “sibcall”): Likewise.
973 (define_expand “sibcall_value”): Likewise.
974 (call_nonlocal_sysv): Remove Darwin special-casing.
975 (call_value_nonlocal_sysv): Likewise.
976
977 2018-12-12 Iain Sandoe <iain@sandoe.co.uk>
978
979 * config/rs6000/darwin.md (call_indirect_nonlocal_darwin64): Remove.
980 (call_nonlocal_darwin64): Remove.
981 (call_value_indirect_nonlocal_darwin64): Remove.
982 (call_value_nonlocal_darwin64): Remove.
983 * config/rs6000/rs6000.c (rs6000_call_template_1): Handle Darwin with
984 the same asm output as AIX/ELFv2. (rs6000_call_sysv): Preserve the
985 CALL_LONG flag when needed for Darwin.
986 * config/rs6000/rs6000.md (define expand “call”): Expand Darwin as
987 per sysv.
988 (define_expand “call_value”): Likewise.
989 (define_expand “sibcall”): Likewise.
990 (define_expand “sibcall_value”): Likewise.
991 (call_indirect_nonlocal_sysv): Mark the clobber mode P.
992 (call_nonlocal_sysv): Likewise.
993 (call_nonlocal_sysv_secure): Likewise.
994 (call_value_indirect_nonlocal_sysv): Likewise.
995 (call_value_nonlocal_sysv): Likewise.
996 (call_value_nonlocal_sysv_secure): Likewise.
997 (call_local64): Mark the clobber DI.
998 (call_value_local64): Likewise.
999
1000 2018-12-11 Jakub Jelinek <jakub@redhat.com>
1001
1002 PR tree-optimization/88444
1003 * tree-vrp.c (register_edge_assert_for_2): Only register assertions
1004 for conversions if rhs1 is a SSA_NAME.
1005
1006 2018-12-11 Dimitar Dimitrov <dimitar@dinux.eu>
1007
1008 * cfgexpand.c (asm_clobber_reg_is_valid): Also produce
1009 error when stack pointer is clobbered.
1010 (expand_asm_stmt): Refactor clobber check in separate function.
1011
1012 2018-12-11 Eric Botcazou <ebotcazou@adacore.com>
1013
1014 * config/rs6000/vxworks.h (RS6000_STARTING_FRAME_OFFSET): Define,
1015 accounting for STACK_BOUNDARY 128.
1016 (STACK_DYNAMIC_OFFSET): Likewise.
1017
1018 2018-12-11 Jakub Jelinek <jakub@redhat.com>
1019
1020 PR target/88425
1021 * config/i386/i386.md (*x86_mov<SWI48:mode>cc_0_m1_neg_leu<SWI:mode>):
1022 New define_insn_and_split.
1023
1024 2018-12-11 Richard Biener <rguenther@suse.de>
1025
1026 PR middle-end/88448
1027 PR middle-end/88415
1028 * gimple.c (gimple_assign_set_rhs_with_ops): Revert previous
1029 change.
1030 * tree-complex.c (update_complex_assignment): Properly transfer
1031 or clean EH info around gimple_assign_set_rhs_with_ops.
1032
1033 2018-12-11 Richard Earnshaw <rearnsha@arm.com>
1034
1035 PR target/87369
1036 * config/aarch64/iterators.md (sizem1): Add sizes for SFmode and DFmode.
1037 (Vbtype): Add SFmode mapping.
1038 * config/aarch64/aarch64.md (copysigndf3, copysignsf3): Delete.
1039 (copysign<GPF:mode>3): New expand pattern.
1040 (copysign<GPF:mode>3_insn): New insn pattern.
1041
1042 2018-12-11 Richard Biener <rguenther@suse.de>
1043
1044 * ccmp.c (ccmp_candidate_p): Use GIMPLE API properly.
1045
1046 2018-12-11 Jakub Jelinek <jakub@redhat.com>
1047
1048 PR lto/86004
1049 * doc/sourcebuild.texi (lto_incremental): Document new effective
1050 target.
1051
1052 2018-12-11 Segher Boessenkool <segher@kernel.crashing.org>
1053
1054 PR target/88145
1055 * config/rs6000/rs6000.c (rs6000_expand_zeroop_builtin): Use
1056 rs6000_isa_flags instead of rs6000_isa_flags_explicit to decide
1057 whether soft float is enabled.
1058 (rs6000_expand_mtfsb_builtin): Ditto.
1059 (rs6000_expand_set_fpscr_rn_builtin): Ditto.
1060 (rs6000_expand_set_fpscr_drn_builtin): Ditto.
1061
1062 2018-12-10 Jeff Law <law@redhat.com>
1063
1064 PR tree-optimization/80520
1065 * gimple-ssa-split-paths.c (is_feasible_trace): Recognize half
1066 diamonds that are likely if convertable.
1067
1068 2018-12-10 Martin Sebor <msebor@redhat.com>
1069
1070 PR tree-optimization/86196
1071 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): Use
1072 base size only of arrays.
1073
1074 2018-12-10 Segher Boessenkool <segher@kernel.crashing.org>
1075
1076 * config.gcc (Obsolete configurations): Delete powerpc*-*-*spe*.
1077 (Unsupported targets): Add powerpc*-*-*spe*.
1078 (powerpc*-*-*spe*): Delete.
1079 (powerpc-*-eabispe*): Delete.
1080 (powerpc-*-rtems*spe*): Delete.
1081 (powerpc*-*-linux*spe*): Delete.
1082 (powerpc*-*-linux*): Do not handle the linux*spe* targets.
1083 (powerpc-wrs-vxworks*spe): Delete.
1084 (with_cpu setting code): Delete powerpc*-*-*spe* handling.
1085 * config.host (target powerpc*-*-*spe*): Delete.
1086 * doc/invoke.texi (PowerPC SPE Options): Delete.
1087 (PowerPC SPE Options): Delete.
1088 * config/powerpcspe: Delete.
1089
1090 2018-12-10 Uros Bizjak <ubizjak@gmail.com>
1091
1092 PR target/88418
1093 * config/i386/i386.c (ix86_expand_sse_cmp): For vector modes,
1094 check operand 1 with vector_operand predicate.
1095 (ix86_expand_sse_movcc): For vector modes, check op_true with
1096 vector_operand, not nonimmediate_operand.
1097
1098 2018-12-10 Richard Biener <rguenther@suse.de>
1099
1100 * tree-affine.c (tree_to_aff_combination): Remove unreachable
1101 MEM_REF case.
1102 (aff_combination_expand): Cache on SSA names, not possibly
1103 on conversion trees. Avoid expanding cases we do not handle.
1104
1105 2018-12-10 Richard Biener <rguenther@suse.de>
1106
1107 PR tree-optimization/88427
1108 * vr-values.c (vr_values::extract_range_from_phi_node):
1109 Handle symbolic ranges conservatively when trying to drop
1110 to Inf +- 1.
1111
1112 2018-12-10 Martin Jambor <mjambor@suse.cz>
1113
1114 PR ipa/88214
1115 * ipa-prop.c (determine_locally_known_aggregate_parts): Make sure
1116 we check pointers against pointers.
1117
1118 2018-12-10 Richard Biener <rguenther@suse.de>
1119
1120 PR middle-end/88415
1121 * gimple.c (gimple_assign_set_rhs_with_ops): Transfer EH
1122 info to a newly allocated stmt.
1123
1124 2018-12-10 Jerome Lambourg <lambourg@adacore.com>
1125
1126 * config/vxworksae.h (TARGET_VXWORKS_HAVE_CTORS_DTORS): Define.
1127
1128 2018-12-10 Fredrik Nyström <fredrik@lysator.liu.se>
1129
1130 PR bootstrap/65725
1131 * config/sol2.h: Only use libgcc-unwind.map if
1132 ENABLE_SHARED_LIBGCC.
1133
1134 2018-12-10 Bin Cheng <bin.cheng@linux.alibaba.com>
1135
1136 * auto-profile.c (afdo_calculate_branch_prob): Convert profile_count
1137 to afdo precision quality.
1138 (afdo_callsite_hot_enough_for_early_inline): Likewise.
1139 (afdo_annotate_cfg): Set profile_count for exit basic block.
1140
1141 2018-12-10 Bin Cheng <bin.cheng@linux.alibaba.com>
1142
1143 * auto-profile.c (string_table::get_index_by_decl)
1144 (function_instance::get_function_instance_by_decl): Avoid infinite
1145 recursion by using DECL_FROM_INLINE.
1146
1147 2018-12-09 John David Anglin <danglin@gcc.gnu.org>
1148
1149 * config.gcc (hppa*-*-linux*): Add pa/t-pa to tmake_file. Define
1150 d_target_objs.
1151 * config/pa/pa-protos.h (pa_d_target_versions): New prototype.
1152 * config/pa/pa.h (TARGET_D_CPU_VERSIONS): Define.
1153 * config/pa/pa-d.c: New file.
1154 * config/pa/t-pa: New file.
1155
1156 2018-12-08 Bin Cheng <bin.cheng@linux.alibaba.com>
1157
1158 * ipa-cp.c (update_profiling_info): Call adjust_for_ipa_scaling for
1159 zero profile count.
1160
1161 2018-12-08 Jakub Jelinek <jakub@redhat.com>
1162
1163 PR fortran/88304
1164 * tree-nested.c (convert_local_reference_stmt): Handle clobbers where
1165 lhs is not a decl normally, don't call use_pointer_in_frame on that
1166 lhs.
1167
1168 2018-12-08 Eric Botcazou <ebotcazou@adacore.com>
1169
1170 PR rtl-optimization/88390
1171 * dwarf2cfi.c (struct dw_cfi_row): Add window_save field.
1172 (cfi_row_equal_p): Compare it.
1173 (dwarf2out_frame_debug_cfa_window_save): Add FAKE parameter.
1174 If FAKE is false, set window_save of the current row.
1175 (dwarf2out_frame_debug) <REG_CFA_TOGGLE_RA_MANGLE>: Call above
1176 function with FAKE parameter set to true.
1177 <REG_CFA_WINDOW_SAVE>: Likewise but with FAKE parameter set to false.
1178 (change_cfi_row): Emit a DW_CFA_GNU_window_save if necessary.
1179
1180 2018-12-07 Peter Bergner <bergner@linux.ibm.com>
1181
1182 PR target/87496
1183 * config/rs6000/rs6000.c (rs6000_option_override_internal): Disallow
1184 -mabi=ieeelongdouble and -mabi=ibmlongdouble without -mlong-double-128.
1185 Do not error for -mabi=ibmlongdouble and no ISA 2.06 support.
1186 * doc/invoke.texi: Document -mabi=ibmlongdouble and -mabi=ieeelongdouble
1187 require -mlong-double-128.
1188
1189 2018-12-07 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
1190
1191 * config/aarch64/aarch64.c (aarch64_tuning_override_functions): Add
1192 sve_width entry.
1193 (aarch64_parse_sve_width_string): Define.
1194
1195 2018-12-07 Jeff Law <law@redhat.com>
1196
1197 PR middle-end/87813
1198 * gimple-ssa-evrp-analyze.h (class evrp_range_analyzer): Add
1199 m_update_global_ranges member. Add corresponding argument to ctor.
1200 * gimple-ssa-evrp-analyze.c
1201 (evrp_range_analyzer::evrp_range_analyzer): Add new argument and
1202 initialize m_update_global_ranges.
1203 (evrp_range_analyzer::set_ssa_range_info): Assert that we are
1204 updating global ranges.
1205 (evrp_range_analyzer::record_ranges_from_incoming_edge): Only
1206 update global ranges if explicitly requested.
1207 (evrp_range_analyzer::record_ranges_from_phis): Similarly.
1208 (evrp_range_analyzer::record_ranges_from_stmt): Similarly.
1209 * gimple-ssa-evrp.c (evrp_dom_walker): Pass new argument to
1210 evrp_range_analyzer ctor.
1211 * gimple-ssa-sprintf.c (sprintf_dom_walker): Similarly.
1212 * tree-ssa-dom.c (dom_opt_dom_walker): Similarly.
1213
1214 2018-12-07 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
1215
1216 * config/aarch64/aarch64-opts.h (aarch64_sve_vector_bits_enum):
1217 Add SVE_NOT_IMPLEMENTED value.
1218 * config/aarch64/aarch64-protos.h (struct tune_params): Add sve_width
1219 field.
1220 * config/aarch64/aarch64.c (generic_tunings,cortexa35_tunings,
1221 cortexa53_tunings, cortexa57_tunings, cortexa72_tunings,
1222 cortexa73_tunings, exynosm1_tunings, thunderx_tunings,
1223 thunderx_tunings, tsv110_tunings, xgene1_tunings, qdf24xx_tunings,
1224 saphira_tunings, thunderx2t99_tunings, emag_tunings):
1225 Specify sve_width.
1226 (aarch64_estimated_poly_value): Define.
1227 (TARGET_ESTIMATED_POLY_VALUE): Define.
1228
1229 2018-12-07 Paul A. Clarke <pc@us.ibm.com>
1230
1231 PR target/88408
1232 * config/rs6000/mmintrin.h (_mm_packs_pu16): Correctly use "__vector".
1233
1234 2018-12-07 Vladimir Makarov <vmakarov@redhat.com>
1235
1236 PR rtl-optimization/88349
1237 * ira-costs.c (record_operand_costs): Check bigger reg class on
1238 NO_REGS.
1239
1240 2018-12-07 Richard Sandiford <richard.sandiford@arm.com>
1241
1242 * config/aarch64/aarch64-sve.md (*mul<mode>3, *v<optab><mode>3):
1243 Split the patterns after reload if we don't need the predicate
1244 operand.
1245 (*post_ra_mul<mode>3, *post_ra_v<optab><mode>3): New patterns.
1246
1247 2018-12-07 Richard Sandiford <richard.sandiford@arm.com>
1248
1249 * config/aarch64/iterators.md (SVE_UNPRED_FP_BINARY): New code
1250 iterator.
1251 (sve_fp_op): Handle minus and mult.
1252 * config/aarch64/aarch64-sve.md (*add<mode>3, *sub<mode>3)
1253 (*mul<mode>3): Split the patterns after reload if we don't
1254 need the predicate operand.
1255 (*post_ra_<sve_fp_op><mode>3): New pattern.
1256
1257 2018-12-07 Bin Cheng <bin.cheng@linux.alibaba.com>
1258
1259 * profile-count.h (profile_count::oeprator>=): Fix typo by inverting
1260 return condition when *this is precise zero.
1261
1262 2018-12-07 Jakub Jelinek <jakub@redhat.com>
1263
1264 PR target/85593
1265 * final.c (rest_of_handle_final): Don't call collect_fn_hard_reg_usage
1266 for functions with naked attribute.
1267
1268 PR c/88367
1269 * tree-vrp.c (extract_range_from_binary_expr): For POINTER_PLUS_EXPR
1270 with -fno-delete-null-pointer-checks, set_nonnull only if the pointer
1271 is non-NULL and offset is known to have most significant bit clear.
1272 * vr-values.c (vr_values::vrp_stmt_computes_nonzero): For ADDR_EXPR
1273 of MEM_EXPR, return true if the MEM_EXPR has non-zero offset with
1274 most significant bit clear. If offset does have most significant bit
1275 set and -fno-delete-null-pointer-checks, don't return true even if
1276 the base pointer is non-NULL.
1277
1278 2018-12-06 Alexandre Oliva <aoliva@redhat.com>
1279
1280 * cselib.c (cselib_record_sets): Skip strict low part sets
1281 with NULL src_elt.
1282
1283 2018-12-06 Paul A. Clarke <pc@us.ibm.com>
1284
1285 PR target/88316
1286 * config/rs6000/smmintrin.h: New file.
1287 * config.gcc: Add smmintrin.h to extra_headers for powerpc*-*-*.
1288
1289 2018-12-06 Paul A. Clarke <pc@us.ibm.com>
1290
1291 PR target/88316
1292 * config/rs6000/mmintrin.h (_mm_unpackhi_pi8): Fix for big-endian.
1293 (_mm_unpacklo_pi8): Likewise.
1294 (_mm_mulhi_pi16): Likewise.
1295 (_mm_packs_pi16): Fix for big-endian. Use preferred API.
1296 (_mm_packs_pi32): Likewise.
1297 (_mm_packs_pu16): Likewise.
1298 * config/rs6000/xmmintrin.h (_mm_cvtss_si32): Fix for big-endian.
1299 (_mm_cvtss_si64): Likewise.
1300 (_mm_cvtpi32x2_ps): Likewise.
1301 (_mm_shuffle_ps): Likewise.
1302 (_mm_movemask_pi8): Likewise.
1303 (_mm_mulhi_pu16): Likewise.
1304 (_mm_sad_pu8): Likewise.
1305 (_mm_sad_pu8): Likewise.
1306 (_mm_cvtpu16_ps): Fix for big-endian. Use preferred API.
1307 (_mm_cvtpu8_ps): Likewise.
1308 (_mm_movemask_ps): Better #else case for big-endian (no functional
1309 change).
1310 (_mm_shuffle_pi16): Likewise.
1311 * config/rs6000/emmintrin.h (_mm_movemask_pd): Fix for big-endian.
1312 Better #else case for big-endian (no functional change).
1313 (_mm_movemask_epi8): Likewise.
1314 (_mm_shufflehi_epi16): Likewise.
1315 (_mm_shufflelo_epi16): Likewise.
1316 (_mm_shuffle_epi32): Likewise.
1317 (_mm_mul_epu32): Fix for big-endian.
1318 (_mm_bsrli_si128): Likewise.
1319 (_mm_cvtps_pd): Better #else case for big endian.
1320 (_mm_mulhi_epi16): Likewise.
1321 (_mm_mul_epu32): Likewise.
1322 (_mm_slli_si128): Likewise.
1323 (_mm_sll_epi16): Likewise.
1324 (_mm_sll_epi32): Likewise.
1325 (_mm_sra_epi16): Likewise.
1326 (_mm_sra_epi32): Likewise.
1327 (_mm_srl_epi16): Likewise.
1328 (_mm_srl_epi32): Likewise.
1329 (_mm_mulhi_epu16): Likewise.
1330 (_mm_sad_epu8): Likewise.
1331 * config/rs6000/pmmintrin.h (_mm_hadd_ps): Fix for big-endian.
1332 (_mm_sub_ps): Likewise.
1333 * config/rs6000/mmintrin.h (_mm_cmpeq_pi8): Fix for 32-bit mode.
1334 * gcc/config/rs6000/tmmintrin.h (_mm_alignr_epi8): Use ENDIAN
1335 macros consistently (no functional changes).
1336 (_mm_alignr_pi8): Likewise.
1337
1338 2018-12-06 Iain Sandoe <iain@sandoe.co.uk>
1339
1340 PR c++/87380
1341 * config/darwin.h (TARGET_WEAK_NOT_IN_ARCHIVE_TOC) Remove, use the
1342 default.
1343 * config/rs6000/darwin7.h (TARGET_WEAK_NOT_IN_ARCHIVE_TOC): New.
1344
1345 2018-12-06 Vladimir Makarov <vmakarov@redhat.com>
1346
1347 PR target/88282
1348 * ira.c (ira_init_register_move_cost): Use info from
1349 hard_regno_mode_ok instead of contains_reg_of_mode.
1350 * ira-costs.c (contains_reg_of_mode): Don't use cost from bigger
1351 hard register class for some fixed hard registers.
1352
1353 2018-12-06 Segher Boessenkool <segher@kernel.crashing.org>
1354
1355 * doc/extend.texi (Using Assembly Language with C): Document asm inline.
1356 (Size of an asm): Fix typo. Document asm inline.
1357 * gimple-pretty-print.c (dump_gimple_asm): Handle asm inline.
1358 * gimple.h (enum gf_mask): Add GF_ASM_INLINE.
1359 (gimple_asm_set_volatile): Fix typo.
1360 (gimple_asm_inline_p): New.
1361 (gimple_asm_set_inline): New.
1362 * gimplify.c (gimplify_asm_expr): Propagate the asm inline flag from
1363 tree to gimple.
1364 * ipa-icf-gimple.c (func_checker::compare_gimple_asm): Compare the
1365 gimple_asm_inline_p flag, too.
1366 * tree-core.h (tree_base): Document that protected_flag is ASM_INLINE_P
1367 in an ASM_EXPR.
1368 * tree-inline.c (estimate_num_insns): If gimple_asm_inline_p return
1369 a minimum size for an asm.
1370 * tree.h (ASM_INLINE_P): New.
1371
1372 2018-12-06 Segher Boessenkool <segher@kernel.crashing.org>
1373
1374 PR inline-asm/55681
1375 * doc/extend.texi (Basic Asm): Update grammar.
1376 (Extended Asm): Update grammar.
1377
1378 2018-12-06 Iain Sandoe <iain@sandoe.co.uk>
1379
1380 PR target/78444
1381 * config/i386/darwin.h (STACK_BOUNDARY): Remove macro.
1382 * config/i386/i386.c (ix86_compute_frame_layout): Ensure at least 128b
1383 stack alignment in non-leaf functions.
1384
1385 2018-12-06 Jakub Jelinek <jakub@redhat.com>
1386
1387 PR target/87598
1388 * config/aarch64/aarch64.c (aarch64_print_address_internal): Don't
1389 call output_operand_lossage on VOIDmode CONST_INTs. After
1390 output_operand_lossage do return false.
1391
1392 2018-12-06 Richard Biener <rguenther@suse.de>
1393
1394 * df-problems.c (df_rd_local_compute): Use bitmap_release.
1395 (df_live_free): Likewise.
1396 (df_md_local_compute): Likewise.
1397 (df_md_free): Release df_md_scratch bitmap.
1398 * loop-invariant.c (calculate_loop_reg_pressure): Use
1399 bitmap_release.
1400 * sched-deps.c (true_dependency_cache, output_dependency_cache,
1401 anti_dependency_cache, control_dependency_cache,
1402 spec_dependency_cache): Use bitmap instead of bitmap_head *.
1403 * sched-ebb.c (schedule_ebbs_init): Initialize non-GTY
1404 dont_calc_deps as bitmap allocated from obstack not GC.
1405 (schedule_ebbs_finish): Use bitmap_release.
1406 * sched-rgn.c (schedule_insns): Initialize non-GTY
1407 not_in_df as bitmap allocated from obstack not GC.
1408 Use bitmap_release.
1409 * sel-sched.c (_forced_ebb_heads): Remove premature optimization.
1410 (sel_region_init): Allocate forced_ebb_heads.
1411 (sel_region_finish): Free forced_ebb_heads.
1412
1413 2018-12-06 Richard Biener <rguenther@suse.de>
1414
1415 * bitmap.c (bitmap_head::crashme): Define.
1416 * bitmap.h (bitmap_head): Add constexpr default constructor
1417 poisoning the obstack member.
1418 (bitmap_head::crashme): Declare.
1419 (bitmap_release): New function clearing a bitmap and poisoning
1420 the obstack member.
1421 * gengtype.c (main): Make it recognize CONSTEXPR.
1422 * lra-constraints.c (lra_inheritance): Use bitmap_release
1423 instead of bitmap_clear.
1424 * ira.c (ira): Work around class-memaccess warning.
1425 * regrename.c (create_new_chain): Likewise.
1426
1427 2018-12-06 Jakub Jelinek <jakub@redhat.com>
1428
1429 PR tree-optimization/85726
1430 * generic-match-head.c (optimize_successive_divisions_p): New function.
1431 * gimple-match-head.c (optimize_successive_divisions_p): Likewise.
1432 * match.pd: Don't combine successive divisions if they aren't exact
1433 and optimize_successive_divisions_p is false.
1434
1435 PR fortran/88304
1436 * tree-nested.c (convert_nonlocal_reference_stmt): Remove clobbers
1437 for non-local automatic decls.
1438
1439 2018-12-05 David Edelsohn <dje.gcc@gmail.com>
1440
1441 * config/rs6000/aix72.h (ASM_DEFAULT_SPEC): Match Power7 processor
1442 default.
1443
1444 2018-12-05 Uros Bizjak <ubizjak@gmail.com>
1445
1446 * dwarf2out.c (field_byte_offset): Remove
1447 #ifdef PCC_BITFIELD_TYPE_MATTERS check.
1448
1449 2018-12-05 Richard Biener <rguenther@suse.de>
1450 Martin Sebor <msebor@redhat.com>
1451
1452 PR c/87028
1453 * calls.c (get_attr_nonstring_decl): Avoid setting *REF to
1454 SSA_NAME_VAR.
1455 * gcc/gimple-low.c (lower_stmt): Fold builtin calls here.
1456 * gimplify (maybe_fold_stmt): Avoid folding builtin calls.
1457
1458 2018-12-05 Iain Sandoe <iain@sandoe.co.uk>
1459
1460 * configure.ac (gcc_cv_otool): Set.
1461 * configure: Regenerate.
1462
1463 2018-12-05 Uros Bizjak <ubizjak@gmail.com>
1464
1465 * config/i386/cygming.h (PCC_BITFIELD_TYPE_MATTERS): Remove.
1466 (GROUP_BITFIELDS_BY_ALIGN): Ditto.
1467
1468 2018-12-05 Richard Sandiford <richard.sandiford@arm.com>
1469
1470 PR tree-optimization/88064
1471 * tree-vect-patterns.c (vect_convert_input): Convert the result of
1472 an existing cast if it has the right width but the wrong sign.
1473 Do not test the signedness of the required result when
1474 considering whether to split an existing cast; instead split to
1475 a type with the same signedness as the source of the cast, then
1476 convert it to the opposite signedness where necessary.
1477 (vect_recog_over_widening_pattern): Handle sign changes between
1478 the final PLUS_EXPR and the RSHIFT_EXPR.
1479 (vect_recog_average_pattern): Use an unsigned operation when
1480 truncating an addition, subtraction or multiplication. Cast the
1481 result back to the "real" signedness before promoting.
1482
1483 2018-12-05 Richard Biener <rguenther@suse.de>
1484
1485 PR tree-optimization/86637
1486 * tree-vectorizer.c (pass_slp_vectorize::execute): Reset
1487 vect_location at the end.
1488
1489 2018-12-05 Jakub Jelinek <jakub@redhat.com>
1490
1491 PR tree-optimization/87360
1492 * gimple-loop-jam.c (tree_loop_unroll_and_jam): On failure to analyze
1493 data dependencies, don't return false, just continue. Formatting
1494 fixes.
1495 (merge_loop_tree, bb_prevents_fusion_p, unroll_jam_possible_p,
1496 fuse_loops): Formatting fixes.
1497
1498 PR sanitizer/88333
1499 * cfgexpand.c (expand_stack_vars): If asan_vec is empty, start with
1500 aligning frame offset to ASAN_RED_ZONE_SIZE bytes.
1501
1502 2018-12-05 Xianmiao Qu <xianmiao_qu@c-sky.com>
1503
1504 * config.gcc (csky-*-linux-gnu*): Force .init_array support.
1505
1506 2018-12-05 Segher Boessenkool <segher@kernel.crashing.org>
1507
1508 * config/rs6000/rs6000.c (rs6000_function_arg): Only do the special
1509 aggregate handling on actual AIX, not on somewhat similar systems.
1510 (rs6000_arg_partial_bytes): Ditto.
1511
1512 2018-12-04 Vladimir Makarov <vmakarov@redhat.com>
1513
1514 PR rtl-optimization/88317
1515 * lra-constraints.c (split_reg): Don't set up check_only_regs if
1516 we are outside the inheritance pass.
1517
1518 2018-12-04 Jan Hubicka <hubicka@ucw.cz>
1519
1520 * ipa-prop.c (jump_function_useful_p): New.
1521 (ipa_read_node_info): Do not allocated useless jump functions.
1522
1523 2018-12-04 David Malcolm <dmalcolm@redhat.com>
1524
1525 PR c/82967
1526 * spellcheck.c (selftest::test_suggestions): Add another assertion.
1527
1528 2018-12-04 Martin Sebor <msebor@redhat.com>
1529
1530 * doc/extend.texi (__builtin_has_attribute): Fix typo.
1531
1532 2018-12-04 Jakub Jelinek <jakub@redhat.com>
1533
1534 PR target/88188
1535 * config/rs6000/rs6000.c (ccr_bit): Return -1 instead of assertion
1536 failures.
1537 (print_operand): Use REG_P instead of GET_CODE == REG.
1538 <case 'D'>: Also check CR_REGNO_P (REGNO (x)).
1539 <case 't'>: Likewise. Remove GET_MODE check.
1540 * config/rs6000/rs6000.md (scc patterns): Assert ccr_bit didn't
1541 return -1.
1542
1543 2018-12-04 Martin Sebor <msebor@redhat.com>
1544
1545 * doc/extend.texi (attribute aligned): Expand.
1546
1547 2018-12-04 David Edelsohn <dje.gcc@gmail.com>
1548
1549 PR target/61976
1550 * config/rs6000/rs6000.c (rs6000_function_arg): Don't pass aggregates
1551 in FPRs on AIX.
1552 (rs6000_arg_partial_bytes): Same.
1553
1554 2018-12-04 Vladimir Makarov <vmakarov@redhat.com>
1555
1556 PR target/88282
1557 * ira-costs.c (exec): Try bigger class to use smaller register
1558 move cost.
1559
1560 2018-12-04 Michael Ploujnikov <michael.ploujnikov@oracle.com>
1561
1562 PR ipa/88297
1563 * ipa-cp.c (create_specialized_node): Track clone counters by
1564 node assembler names.
1565 (ipcp_driver): Change type of clone_num_suffixes key to const char*.
1566
1567 2018-12-04 Richard Biener <rguenther@suse.de>
1568
1569 * tree-vect-loop.c (vect_transform_loop): Fix epilogue iterations
1570 for epilogue vectorization.
1571
1572 2018-12-04 Richard Biener <rguenther@suse.de>
1573
1574 PR tree-optimization/88301
1575 * tree-vrp.c (register_edge_assert_for_2): Fix sign-conversion
1576 issues in last commit.
1577
1578 2018-12-04 Richard Biener <rguenther@suse.de>
1579
1580 PR tree-optimization/88315
1581 * tree-vect-loop.c (get_initial_defs_for_reduction): Simplify
1582 and fix initialization vector for SAD and DOT_PROD SLP reductions.
1583
1584 2018-12-03 Sandra Loosemore <sandra@codesourcery.com>
1585
1586 PR c/59039
1587 * doc/extend.texi (Nonlocal gotos): New section.
1588
1589 2018-12-03 Uros Bizjak <ubizjak@gmail.com>
1590
1591 * config/i386/sse.md (vec_concatv2df): Change (v,xm,C)
1592 alternative to (v,vm,c).
1593
1594 2018-12-03 Segher Boessenkool <segher@kernel.crashing.org>
1595
1596 * gcc/config.gcc (Unsupported targets): Add powerpc*-*-linux*paired*.
1597 (powerpc*-*-linux*): Don't handle it here.
1598
1599 2018-12-03 Jeff Law <law@redhat.com>
1600
1601 * config/h8300/h8300.md (<code>qi3_1): Add gcc_unreachable to keep
1602 warnings quiet.
1603
1604 * config/h8300/h8300.md (low byte masking peepholes): Only accept
1605 nonimmediate_operand for the to-be-masked operand.
1606
1607 2018-12-03 Richard Biener <rguenther@suse.de>
1608
1609 * tree-ssa-sccvn.c (eliminate_dom_walker::eliminate_stmt): Only
1610 allow expected function-pointer cast re-instantiation.
1611
1612 2018-12-03 Ilya Leoshkevich <iii@linux.ibm.com>
1613
1614 * common/config/s390/s390-common.c (s390_option_init_struct):
1615 Use section anchors by default.
1616 * config/s390/s390.c (s390_check_symref_alignment): Handle
1617 anchors.
1618 (TARGET_MAX_ANCHOR_OFFSET): Use short displacement.
1619 * output.h (assemble_align): Pass `align' as unsigned int, so
1620 that the value 0x80000000, which corresponds to `aligned(1 <<
1621 28)', would pass the `align > BITS_PER_UNIT' check.
1622 * varasm.c (assemble_align): Likewise.
1623
1624 2018-12-03 Julian Brown <julian@codesourcery.com>
1625
1626 * tree-pretty-print.c (dump_omp_clause): Make default case
1627 gcc_unreachable.
1628
1629 2018-12-03 Richard Biener <rguenther@suse.de>
1630
1631 PR tree-optimization/88301
1632 * tree-vrp.c (register_edge_assert_for_2): Handle conversions
1633 that do not change the value by registering the same assert
1634 for the operand.
1635
1636 2018-12-03 Richard Biener <rguenther@suse.de>
1637
1638 * tree-vect-loop.c (vect_transform_loop): Properly compute
1639 upper bound for the epilogue when doing epilogue vectorization.
1640
1641 2018-12-03 Ilya Leoshkevich <iii@linux.ibm.com>
1642
1643 PR target/80080
1644 * cfgcleanup.c (class pass_postreload_jump): New pass.
1645 (pass_postreload_jump::execute): Likewise.
1646 (make_pass_postreload_jump): Likewise.
1647 * passes.def: Add pass_postreload_jump before
1648 pass_postreload_cse.
1649 * tree-pass.h (make_pass_postreload_jump): New pass.
1650
1651 2018-12-02 Uros Bizjak <ubizjak@gmail.com>
1652
1653 * config/i386/i386.c (inline_memory_move_cost): Correctly
1654 compute number of TFmode GPR moves.
1655
1656 2018-12-02 Jakub Jelinek <jakub@redhat.com>
1657
1658 PR target/88278
1659 * config/i386/sse.md (*vec_concatv4sf_0, *vec_concatv4si_0): New insns.
1660
1661 2018-12-02 Jeff Law <law@redhat.com>
1662
1663 * config/h8300/h8300.md (call, call_value): Drop mode from
1664 operand containing number of bytes pushed.
1665 (call_insn, call_value_insn): Use mode iterator for number
1666 of bytes pushed operand. Make pattern name vary appropriately.
1667
1668 2018-12-02 Jan Hubicka <jh@suse.cz>
1669
1670 * bb-reorer.c (find_rarely_executed_basic_blocks_and_crossin_edges):
1671 trust precise profiles.
1672
1673 2018-12-02 Jakub Jelinek <jakub@redhat.com>
1674
1675 * tree-nested.c (convert_nonlocal_omp_clauses,
1676 convert_local_omp_clauses): Handle OMP_CLAUSE_IN_REDUCTION,
1677 OMP_CLAUSE_TASK_REDUCTION and OMP_CLAUSE__SIMT_ clauses.
1678 (convert_nonlocal_reference_stmt, convert_local_reference_stmt):
1679 Convert clauses for GIMPLE_OMP_TASKGROUP.
1680
1681 * omp-low.c (check_omp_nesting_restrictions): Allow cancel or
1682 cancellation point with taskgroup clause inside of taskloop. Consider
1683 a taskloop construct without nogroup clause as implicit taskgroup for
1684 diagnostics if cancel/cancellation point with taskgroup clause is
1685 closely nested inside of taskgroup region.
1686
1687 PR sanitizer/88291
1688 * asan.c (asan_clear_shadow): Move assert that len is multiple of 4
1689 to the start of the function.
1690 (asan_emit_stack_protection): When emitting clearing sequence for
1691 epilogue, align offset down to ASAN_RED_ZONE_SIZE granularity,
1692 add last_size_aligned which is last_size padded to multiples of
1693 ASAN_RED_ZONE_SIZE and emit asan_clear_shadow always on 4 byte
1694 boundaries.
1695
1696 2018-12-01 Jakub Jelinek <jakub@redhat.com>
1697
1698 PR sanitizer/88289
1699 * asan.c (asan_redzone_buffer::flush_redzone_payload): Fix up
1700 an off-by-one for BYTES_BIG_ENDIAN.
1701
1702 PR target/54589
1703 * combine.c (find_split_point): For invalid memory address
1704 nonobj + obj + const, if reg + obj + const is valid addressing
1705 mode, split at nonobj. Use if rather than else if for the
1706 fallback. Comment fixes.
1707
1708 2018-11-30 Indu Bhagat <indu.bhagat@oracle.com>
1709
1710 * coverage.c (get_coverage_counts): Use from_function_decl for precise
1711 function location.
1712 * profile-count.c (profile_count::dump): Add handling for precise
1713 profile quality.
1714 * profile.c (compute_branch_probabilities): Rely on exec_counts instead
1715 of profile_info to set profile_status of function.
1716 (branch_prob): Do not set profile_status of function based on
1717 profile_info. Done above based on exec_counts.
1718
1719 2018-11-30 Jakub Jelinek <jakub@redhat.com>
1720
1721 PR tree-optimization/88274
1722 * tree-ssa-reassoc.c (optimize_range_tests_xor,
1723 optimize_range_tests_diff): If type has smaller precision than
1724 corresponding mode or if it has non-standard min/max, compute
1725 everything in a standard type for the precision.
1726
1727 PR testsuite/85368
1728 * params.def (PARAM_LOGICAL_OP_NON_SHORT_CIRCUIT): New param.
1729 * tree-ssa-ifcombine.c (ifcombine_ifandif): If
1730 --param logical-op-non-short-circuit is present, override
1731 LOGICAL_OP_NON_SHORT_CIRCUIT value from the param.
1732 * fold-const.c (fold_range_test, fold_truth_andor): Likewise.
1733
1734 2018-11-30 Jeff Law <law@redhat.com>
1735
1736 * optabs.c (expand_binop): Use "machine_mode" rather than
1737 "enum machine mode" in most recent change.
1738
1739 2018-11-30 Wilco Dijkstra <wdijkstr@arm.com>
1740
1741 PR middle-end/64242
1742 * builtins.c (expand_builtin_longjmp): Use a temporary when restoring
1743 the frame pointer.
1744 (expand_builtin_nonlocal_goto): Likewise.
1745
1746 2018-11-30 David Malcolm <dmalcolm@redhat.com>
1747
1748 * diagnostic-core.h (emit_diagnostic): New decl.
1749 * diagnostic.c (emit_diagnostic): New overload, taking a
1750 rich_location *.
1751
1752 2018-11-30 David Malcolm <dmalcolm@redhat.com>
1753
1754 * pretty-print.c (class selftest::test_pretty_printer): New
1755 subclass of pretty_printer.
1756 (selftest::test_prefixes_and_wrapping): New test.
1757 (selftest::pretty_print_c_tests): Call it.
1758
1759 2018-11-30 Michael Ploujnikov <michael.ploujnikov@oracle.com>
1760
1761 Minimize clone counter memory usage in create_virtual_clone.
1762 * cgraph.h (clone_function_name): Add a variant that takes a
1763 tree decl.
1764 * cgraph.h (cgraph_node::create_virtual_clone): Add a new
1765 argument: num_suffix.
1766 * cgraphclones.c (cgraph_node::create_virtual_clone): Pass
1767 num_suffix to clone_function_name.
1768 (clone_function_name): Add a variant that takes a tree decl.
1769 * ipa-cp.c (create_specialized_node): Keep track of clone
1770 counters in clone_num_suffixes hash map.
1771 (ipcp_driver): Free the counter hash map.
1772 * ipa-hsa.c (process_hsa_functions): Creates at most one hsa
1773 clone per function.
1774
1775 2018-11-30 Michael Ploujnikov <michael.ploujnikov@oracle.com>
1776 Make function assembly more independent.
1777
1778 This is achieved by having clone_function_name assign unique clone
1779 numbers for each function independently.
1780
1781 * cgraphclones.c: Replaced clone_fn_id_num with clone_fn_ids;
1782 hash map.
1783 (clone_function_name_numbered): Use clone_fn_ids.
1784
1785 2018-11-30 Vladimir Makarov <vmakarov@redhat.com>
1786
1787 PR rtl-optimization/88179
1788 * lra-constraints.c (address_eliminator::address_eliminator):
1789 Don't eleminate regs in illegitimate address.
1790
1791 2018-11-30 David Malcolm <dmalcolm@redhat.com>
1792
1793 PR preprocessor/88257
1794 * input.c (get_substring_ranges_for_loc): Fix indentation.
1795 Bulletproof against getting a different files back from
1796 linemap_resolve_location and expand_location_to_spelling_point.
1797
1798 2018-11-30 Alexander Monakov <amonakov@ispras.ru>
1799
1800 PR gcov-profile/88279
1801 * tree-profile.c (init_ic_make_global_vars): Call
1802 decl_default_tls_model for variable and not it's type.
1803
1804 2018-11-30 Sam Tebbs <sam.tebbs@arm.com>
1805
1806 * config/arm/arm.h (TARGET_DOTPROD): Add TARGET_VFP5 constraint.
1807
1808 2018-11-30 Martin Liska <mliska@suse.cz>
1809
1810 PR sanitizer/81715
1811 * asan.c (asan_shadow_cst): Remove, partially transform
1812 into flush_redzone_payload.
1813 (RZ_BUFFER_SIZE): New.
1814 (struct asan_redzone_buffer): New.
1815 (asan_redzone_buffer::emit_redzone_byte): Likewise.
1816 (asan_redzone_buffer::flush_redzone_payload): Likewise.
1817 (asan_redzone_buffer::flush_if_full): Likewise.
1818 (asan_emit_stack_protection): Use asan_redzone_buffer class
1819 that is responsible for proper aligned stores and flushing
1820 of shadow memory payload.
1821 * asan.h (ASAN_MIN_RED_ZONE_SIZE): New.
1822 (asan_var_and_redzone_size): Likewise.
1823 * cfgexpand.c (expand_stack_vars): Use smaller alignment
1824 (ASAN_MIN_RED_ZONE_SIZE) in order to make shadow memory
1825 for automatic variables more compact.
1826
1827 2018-11-30 Alan Modra <amodra@gmail.com>
1828
1829 * config/rs6000/predicates.md (easy_fp_constant): Avoid long
1830 dependent insn sequences.
1831 * config/rs6000/rs6000.c (num_insns_constant): Support long
1832 double constants.
1833 * config/rs6000/rs6000.md (mov<mode>_softfloat <FMOVE128>): Adjust
1834 length attribute.
1835
1836 2018-11-30 Alan Modra <amodra@gmail.com>
1837
1838 * config/rs6000/rs6000.c (num_insns_constant_gpr): Renamed from
1839 num_insns_constant_wide. Make static. Revise comment.
1840 (num_insns_constant_multi): New function.
1841 (num_insns_constant): Formatting. Correct CONST_WIDE_INT
1842 calculation. Simplify and extract code common to both
1843 CONST_INT and CONST_DOUBLE. Add gcc_unreachable for unhandled
1844 const_double modes.
1845 * config/rs6000/rs6000-protos.h (num_insns_const_wide): Delete.
1846
1847 2018-11-30 Richard Biener <rguenther@suse.de>
1848
1849 PR tree-optimization/88274
1850 * tree-vrp.c (ranges_from_anti_range): Fix handling of
1851 TYPE_MIN/MAX_VALUE.
1852
1853 2018-11-29 Andi Kleen <ak@linux.intel.com>
1854
1855 * config/i386/i386.c (current_fentry_section): Add.
1856 (x86_function_profiler): Handle fentry section.
1857 (ix86_attribute_table): Add fentry section.
1858 * config/i386/i386.opt: Add -mfentry-section.
1859 * doc/extend.texi: Document fentry_section attribute.
1860 * doc/invoke.texi: Document -mfentry-section.
1861
1862 2018-11-29 Andi Kleen <ak@linux.intel.com>
1863
1864 * config/i386/i386.c (x86_print_call_or_nop): Handle nop name.
1865 (current_fentry_name): Add.
1866 (x86_function_profiler): Handle fentry_name attribute.
1867 (ix86_handle_fentry_name): Add.
1868 (ix86_attribute_table): Add fentry_name.
1869 * config/i386/i386.opt: Add -mfentry-name
1870 * doc/extend.texi: Document fentry_name.
1871 * doc/invoke.texi: Document minstrument-return.
1872
1873 2018-11-29 Andi Kleen <ak@linux.intel.com>
1874
1875 * config/i386/i386-opts.h (enum instrument_return): Add.
1876 * config/i386/i386.c (output_return_instrumentation): Add.
1877 (ix86_output_function_return): Call output_return_instrumentation.
1878 (ix86_output_call_insn): Call output_return_instrumentation.
1879 * config/i386/i386.opt: Add -minstrument-return=.
1880 * doc/invoke.texi (-minstrument-return): Document.
1881
1882 2018-11-29 Eric Botcazou <ebotcazou@adacore.com>
1883
1884 PR target/87807
1885 * config/sparc/sparc-modes.def: Minor tweak.
1886 * config/sparc/sparc.c: Minor reordering.
1887 (sparc_pass_by_reference): Move around.
1888 (traverse_record_type): Change offset from HOST_WIDE_INT to int.
1889 (classify_registers): Likewise for bitpos.
1890 (function_arg_slotno): Remove dead test and tweak comments.
1891 <MODE_RANDOM>: Remove useless assertion and test whether the
1892 parameter is named in order to pass it in FP registers. Return
1893 the regno for floating-point vector types.
1894 (compute_int_layout): Change bitpos from HOST_WIDE_INT to int.
1895 (compute_fp_layout): Likewise.
1896 (count_registers): Likewise.
1897 (assign_int_registers): Likewise.
1898 (assign_fp_registers): Likewise.
1899 (assign_registers): Likewise.
1900 (function_arg_record_value): Change size from HOST_WIDE_INT to int
1901 and use CEIL_NWORDS to compute the number of registers.
1902 (function_arg_union_value): Minor tweaks.
1903 (function_arg_vector_value): Add slotno and named parameters, use
1904 CEIL_NWORDS to compute the number of registers.
1905 (sparc_function_arg_1): Rework handling of vector types. Change
1906 size from HOST_WIDE_INT to int.
1907 (sparc_arg_partial_bytes): Rework handling of 32-bit ABI and deal
1908 with vector types for the 64-bt ABI.
1909 (sparc_function_arg_advance): Likewise.
1910 (sparc_return_in_memory): Add reference to -fpcc-struct-return.
1911 (sparc_struct_value_rtx): Return NULL_RTX instead of 0.
1912 (sparc_function_value_1): Rework handling of vector types. Change
1913 size from HOST_WIDE_INT to int.
1914
1915 2018-11-29 Jakub Jelinek <jakub@redhat.com>
1916
1917 PR target/88152
1918 * config/i386/sse.md (*<sse>_movmsk<ssemodesuffix><avxsizesuffix>_lt,
1919 *<sse>_movmsk<ssemodesuffix><avxsizesuffix>_zext_lt,
1920 *<sse>_movmsk<ssemodesuffix><avxsizesuffix>_shift,
1921 *<sse>_movmsk<ssemodesuffix><avxsizesuffix>_zext_shift,
1922 *<sse2_avx2>_pmovmskb_lt, *<sse2_avx2>_pmovmskb_zext_lt): New
1923 define_insn_and_split patterns.
1924
1925 PR target/54700
1926 * config/i386/sse.md
1927 (*<sse4_1>_blendv<ssemodesuffix><avxsizesuffix>_lt,
1928 *<sse4_1>_blendv<ssefltmodesuffix><avxsizesuffix>_ltint,
1929 *<sse4_1_avx2>_pblendvb_lt): Change define_insn into
1930 define_insn_and_split.
1931
1932 2018-11-29 Peter Bergner <bergner@linux.ibm.com>
1933
1934 PR target/87496
1935 * config/rs6000/rs6000.c (rs6000_option_override_internal): Disallow
1936 -mabi=ieeelongdouble without both -mpopcntd and -mvsx.
1937
1938 2018-11-29 Uros Bizjak <ubizjak@gmail.com>
1939
1940 * config/i386/i386.c (inline_memory_move_cost):
1941 Check "in" for 2 in MMX_CLASS_P case.
1942 * config/i386/mmx.md (*mov<mode>_internal): Correct
1943 TARGET_INTER_UNIT_MOVES_FROM_VEC and TARGET_INTER_UNIT_MOVES_TO_VEC
1944 alternatives in preferred_for_speed attribute calculation.
1945
1946 2018-11-29 Martin Sebor <msebor@redhat.com>
1947
1948 PR c/88172
1949 PR testsuite/88208
1950 * doc/extend.texi (attribute constructor): Clarify.
1951
1952 2018-11-29 Martin Liska <mliska@suse.cz>
1953
1954 PR middle-end/88246
1955 * builtins.c (expand_movstr): Fix thinko introduced
1956 when switching to the new enum.
1957
1958 2018-11-29 qing zhao <qing.zhao@oracle.com>
1959
1960 * cif-code.def (EXTERN_LIVE_ONLY_STATIC): New CIF code.
1961 * common.opt: Add -flive-patching flag.
1962 * doc/invoke.texi: Document -flive-patching.
1963 * flag-types.h (enum live_patching_level): New enum.
1964 * ipa-inline.c (can_inline_edge_p): Disable external functions from
1965 inlining when flag_live_patching is LIVE_PATCHING_INLINE_ONLY_STATIC.
1966 * opts.c (control_options_for_live_patching): New function.
1967 (finish_options): Make flag_live_patching incompatible with flag_lto.
1968 Control IPA optimizations based on different levels of
1969 flag_live_patching.
1970
1971 2018-11-29 Giuliano Belinassi <giuliano.belinassi@usp.br>
1972
1973 * match.pd (sinh (atanh (x))): New simplification rules.
1974 (cosh (atanh (x))): Likewise.
1975
1976 2018-11-29 Jakub Jelinek <jakub@redhat.com>
1977
1978 PR target/54700
1979 * config/i386/sse.md (ssebytemode): Add V16SI, V8SI and V4SI entries.
1980 (ssefltmodesuffix, ssefltvecmode): New define_mode_attrs.
1981 (*<sse4_1>_blendv<ssemodesuffix><avxsizesuffix>_lt,
1982 *<sse4_1>_blendv<ssefltmodesuffix><avxsizesuffix>_ltint,
1983 *<sse4_1_avx2>_pblendvb_lt): New define_insns.
1984
1985 PR target/88152
1986 * tree.h (build_uniform_cst, uniform_integer_cst_p): Declare.
1987 * tree.c (build_uniform_cst, uniform_integer_cst_p): New functions.
1988 * match.pd (define_predicates): Add uniform_integer_cst_p.
1989 (cmp @0 INTEGER_CST@1, cmp (convert?@2 @0) INTEGER_CST@1): Adjust
1990 so that it works also for vector comparisons with uniform constants
1991 with INTEGER_CST element.
1992
1993 PR target/88234
1994 * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): For
1995 vec_add and vec_sub builtins, perform PLUS_EXPR or MINUS_EXPR
1996 in unsigned_type_for instead of vector integral type where overflow
1997 doesn't wrap.
1998
1999 2018-11-29 Michael Ploujnikov <michael.ploujnikov@oracle.com>
2000
2001 There can be at most one .resolver clone per function
2002 * config/rs6000/rs6000.c (make_resolver_func): Generate
2003 resolver symbol with clone_function_name instead of
2004 clone_function_name_numbered.
2005
2006 2018-11-29 Richard Biener <rguenther@suse.de>
2007
2008 PR tree-optimization/88243
2009 * tree-vect-patterns.c (vect_mark_pattern_stmts): Set the def
2010 type of all pattern-sequence stmts to vect_internal_def.
2011
2012 2018-11-29 Andre Vieira <andre.simoesdiasvieira@arm.com>
2013
2014 PR target/88224
2015 * config/arm/arm-cpus.in (armv7-r): Add FP16conv configurations.
2016 (cortex-r7, cortex-r8): Update default and add new configuration.
2017 * doc/invoke.texi (armv7-r): Add two new vfp options.
2018 (nofp.dp): Add cortex-r7 and cortex-r8 to the list of targets that
2019 support this option.
2020
2021 2018-11-29 Alan Modra <amodra@gmail.com>
2022
2023 * config/rs6000/rs6000.c (rs6000_emit_move): Disable long
2024 double split for targets other than Darwin.
2025
2026 2018-11-29 Alan Modra <amodra@gmail.com>
2027
2028 * config/rs6000/rs6000.md (movdi_internal64): Correct lengths.
2029
2030 2018-11-29 Alan Modra <amodra@gmail.com>
2031
2032 * config/rs6000/predicates.md (easy_fp_constant): Remove code
2033 dealing with integers in const_double. Assert on unexpected
2034 modes. Delete superfluous ABI_V4 test.
2035 * config/rs6000/rs6000.c (rs6000_emit_move): Comment fixes.
2036 Don't call easy_fp_constant for Pmode.
2037 (rs6000_hash_constant): Remove code dealing with integers in
2038 const_double.
2039 (rs6000_legitimate_constant_p): Likewise.
2040 (output_toc): Formatting, use CONST_DOUBLE_P.
2041
2042 2018-11-29 Alan Modra <amodra@gmail.com>
2043
2044 * config/rs6000/constraints.md (G, H): Comment on purpose of
2045 constraint. Correct mode comments and "G" mode test.
2046 * config/rs6000/rs6000.md (movdi_internal32): Remove "GH" from
2047 alternative handling "F". Add length attr. Formatting.
2048 (mov<mode>_softfloat <FMOVE128>): Delete "GH" from
2049 alternative, and move "F" to separate alternative. Correct
2050 insn lengths.
2051
2052 2018-11-29 Alan Modra <amodra@gmail.com>
2053
2054 * config/rs6000/predicates.md (easy_vector_constant): Don't call
2055 easy_fp_constant.
2056
2057 2018-11-29 Alan Modra <amodra@gmail.com>
2058
2059 * config.in (HAVE_AS_PLTSEQ): Add.
2060 * config/rs6000/predicates.md (indirect_call_operand): New.
2061 * config/rs6000/rs6000-protos.h (rs6000_pltseq_template),
2062 (rs6000_sibcall_sysv): Declare.
2063 * config/rs6000/rs6000.c (init_cumulative_args): Set cookie
2064 CALL_LONG for -fno-plt.
2065 (print_operand <T, z, 0>): Handle UNSPEC_PLTSEQ.
2066 (rs6000_indirect_call_template_1): Emit .reloc directives for
2067 UNSPEC_PLTSEQ calls.
2068 (rs6000_pltseq_template): New function.
2069 (rs6000_longcall_ref): Add arg parameter. Use PLT16 insns if
2070 relocs supported by assembler. Move SYMBOL_REF test to callers.
2071 (rs6000_call_aix): Adjust rs6000_longcall_ref call. Package
2072 insns in UNSPEC_PLTSEQ, preserving original func_desc.
2073 (rs6000_call_sysv): Likewise.
2074 (rs6000_sibcall_sysv): New function.
2075 * config/rs6000/rs6000.h (HAVE_AS_PLTSEQ): Provide default.
2076 * config/rs6000/rs6000.md (UNSPEC_PLTSEQ, UNSPEC_PLT16_HA,
2077 UNSPEC_PLT16_LO): New.
2078 (pltseq_tocsave, pltseq_plt16_ha, pltseq_plt16_lo, pltseq_mtctr): New.
2079 (call_indirect_nonlocal_sysv): Don't differentiate zero from non-zero
2080 cookie in constraints. Test explicitly for flags in length attr.
2081 Handle unspec operand 1.
2082 (call_value_indirect_nonlocal_sysv): Likewise.
2083 (call_indirect_aix, call_value_indirect_aix): Handle unspec operand 1.
2084 (call_indirect_elfv2, call_value_indirect_elfv2): Likewise.
2085 (sibcall, sibcall_value): Use rs6000_sibcall_sysv.
2086 (sibcall_indirect_nonlocal_sysv): New pattern.
2087 (sibcall_value_indirect_nonlocal_sysv): Likewise.
2088 (sibcall_nonlocal_sysv, sibcall_value_nonlocal_sysv): Remove indirect
2089 call alternatives.
2090 * configure.ac: Check for gas plt sequence marker support.
2091 * configure: Regenerate.
2092
2093 2018-11-29 Alan Modra <amodra@gmail.com>
2094
2095 * config/rs6000/predicates.md (unspec_tls): New.
2096 * config/rs6000/rs6000-protos.h (rs6000_call_template),
2097 (rs6000_sibcall_template): Update prototype.
2098 (rs6000_longcall_ref): Delete.
2099 (rs6000_call_sysv): Declare.
2100 * config/rs6000/rs6000.c (edit_tls_call_insn): New function.
2101 (global_tlsarg): New variable.
2102 (rs6000_legitimize_tls_address): Rewrite __tls_get_addr call
2103 handling.
2104 (print_operand): Extract UNSPEC_TLSGD address operand.
2105 (rs6000_call_template, rs6000_sibcall_template): Remove arg
2106 parameter, extract from second call operand instead.
2107 (rs6000_longcall_ref): Make static, localize vars.
2108 (rs6000_call_aix): Rename parameter to reflect new usage. Take
2109 tlsarg from global_tlsarg. Don't create unused rtl or nop insns.
2110 (rs6000_sibcall_aix): Rename parameter to reflect new usage. Take
2111 tlsarg from global_tlsarg.
2112 (rs6000_call_sysv): New function.
2113 * config/rs6000/rs6000.md: Adjust rs6000_call_template and
2114 rs6000_sibcall_template throughout.
2115 (tls_gd_aix, tls_gd_sysv, tls_gd_call_aix, tls_gd_call_sysv): Delete.
2116 (tls_ld_aix, tls_ld_sysv, tls_ld_call_aix, tls_ld_call_sysv): Delete.
2117 (tls_gdld_nomark): New insn.
2118 (tls_gd): Swap operand order. Simplify mode selection.
2119 (tls_gd_high, tls_gd_low): Swap operand order.
2120 (tls_ld): Remove const_int 0 vector element from UNSPEC_TLSLD.
2121 Simplify mode selection.
2122 (tls_ld_high, tls_ld_low): Similarly adjust UNSPEC_TLSLD.
2123 (call, call_value): Don't assert for second call operand.
2124 Use rs6000_call_sysv.
2125
2126 2018-11-29 Alan Modra <amodra@gmail.com>
2127
2128 * config/rs6000/darwin.md (call_indirect_nonlocal_darwin64),
2129 (call_nonlocal_darwin64, call_value_indirect_nonlocal_darwin64),
2130 (call_value_nonlocal_darwin64): Remove constraints from second call
2131 arg, the rounded_stack_size_rtx arg.
2132 * config/rs6000/rs6000.md (tls_gd_aix, tls_gd_sysv, tls_gd_call_aix),
2133 (tls_gd_call_sysv, tls_ld_aix, tls_ld_sysv, tls_ld_call_aix),
2134 (tls_ld_call_sysv, call_local32, call_local64, call_value_local32),
2135 (call_value_local64, call_indirect_nonlocal_sysv),
2136 (call_nonlocal_sysv, call_nonlocal_sysv_secure),
2137 (call_value_indirect_nonlocal_sysv, call_value_nonlocal_sysv),
2138 (call_value_nonlocal_sysv_secure, call_local_aix),
2139 (call_value_local_aix, call_nonlocal_aix, call_value_nonlocal_aix),
2140 (call_indirect_aix, call_value_indirect_aix, call_indirect_elfv2),
2141 (call_value_indirect_elfv2, sibcall_local32, sibcall_local64),
2142 (sibcall_value_local32, sibcall_value_local64, sibcall_aix),
2143 (sibcall_value_aix): Likewise.
2144
2145 2018-11-29 Alan Modra <amodra@gmail.com>
2146
2147 * config/rs6000/rs6000.md (TLSmode): Delete mode iterator. Replace
2148 with P throughout except for call mems which should use SI.
2149 (tls_abi_suffix, tls_sysv_suffix, tls_insn_suffix): Delete mode
2150 attributes. Replace with bits, mode and ptrload respectively.
2151
2152 2018-11-29 Alan Modra <amodra@gmail.com>
2153
2154 * config/rs6000/rs6000-protos.h (rs6000_indirect_call_template),
2155 (rs6000_indirect_sibcall_template): Declare.
2156 * config/rs6000/rs6000.c (rs6000_indirect_call_template_1),
2157 (rs6000_indirect_call_template, rs6000_indirect_sibcall_template):
2158 New functions.
2159 * config/rs6000/rs6000.md (call_indirect_nonlocal_sysv),
2160 (call_value_indirect_nonlocal_sysv, sibcall_nonlocal_sysv),
2161 (call_indirect_aix, call_value_indirect_aix): Use
2162 rs6000_indirect_call_template and rs6000_indirect_sibcall_template.
2163 call_indirect_elfv2, call_value_indirect_elfv2): Likewise, and
2164 handle both speculation and non-speculation cases.
2165 (call_indirect_aix_nospec, call_value_indirect_aix_nospec): Delete.
2166 (call_indirect_elfv2_nospec, call_value_indirect_elfv2_nospec): Delete.
2167
2168 2018-11-29 Alan Modra <amodra@gmail.com>
2169
2170 * config/rs6000/rs6000-protos.h (rs6000_call_template): Declare.
2171 (rs6000_sibcall_template): Declare.
2172 (macho_call_template): Rename from output_call.
2173 * config/rs6000/rs6000.c (rs6000_call_template_1): New function.
2174 (rs6000_call_template, rs6000_sibcall_template): Likewise.
2175 (macho_call_template): Rename from output_call.
2176 * config/rs6000/rs6000.md (tls_gd_aix, tls_gd_sysv),
2177 (tls_gd_call_aix, tls_gd_call_sysv, tls_ld_aix, tls_ld_sysv),
2178 (tls_ld_call_aix, tls_ld_call_sysv, call_nonlocal_sysv),
2179 (call_nonlocal_sysv_secure, call_value_nonlocal_sysv),
2180 (call_value_nonlocal_sysv_secure, call_nonlocal_aix),
2181 (call_value_nonlocal_aix): Use rs6000_call_template and update
2182 occurrences of output_call to macho_call_template.
2183 (sibcall_nonlocal_sysv, sibcall_value_nonlocal_sysv, sibcall_aix),
2184 (sibcall_value_aix): Use rs6000_sibcall_template.
2185
2186 2018-11-28 Aaron Sawdey <acsawdey@linux.ibm.com>
2187
2188 * config/rs6000/rs6000-string.c (expand_block_clear): Change how
2189 we determine if unaligned vsx is ok.
2190
2191 2018-11-28 Jan Hubicka <jh@suse.cz>
2192
2193 * predict.c (determine_unlikely_bbs): Forward declare; also determine
2194 edges that are always known to be taken because it is only likely
2195 edge out of given BB.
2196 (tree_estimate_probability): Call before profile guessing to get bit
2197 of extra precision.
2198
2199 2018-11-28 Jan Hubicka <jh@suse.cz>
2200
2201 * tree-ssa-ifcombine.c (update_profile_after_ifcombine): Handle
2202 profile_probability::always better.
2203
2204 2018-11-28 Jan Hubicka <jh@suse.cz>
2205
2206 * profile-count.h (profile_count::split): Give better result when
2207 splitting profile_probability::always.
2208
2209 2018-11-28 Vladimir Makarov <vmakarov@redhat.com>
2210
2211 PR target/88207
2212 * ira-costs.c (scan_one_insn): Process subregs when updating costs
2213 for pseudos and allocnos from insn.
2214
2215 2018-11-28 David Edelsohn <dje.gcc@gmail.com>
2216
2217 * config/rs6000/aix72.h: Update to match aix71.h changes.
2218
2219 2018-11-28 Jeff Law <law@redhat.com>
2220
2221 * config/h8300/constraints.md: Add "C" constraint for call insns.
2222 * config/h8300/h8300.md (call, call_value): Turn into a define_expand
2223 and define_insn pair. Move invalid call targets into a register in
2224 the expander and fix constraints in the matching pattern.
2225 * config/h8300/predicates.md (call_expander_operand): Renamed from
2226 call_insn_operand. Reject things we shouldn't be trying to handle.
2227 (call_insn_operand): New predicate for use by the call/call_value
2228 insns.
2229 (small_call_insn_operand): Update appropriately.
2230
2231 2018-11-28 Sam Tebbs <sam.tebbs@arm.com>
2232
2233 * config/aarch64/aarch64.c (aarch64_process_target_attr): Replace
2234 calls to strtok with strtok_r.
2235
2236 2018-11-28 Richard Biener <rguenther@suse.de>
2237
2238 PR tree-optimization/88223
2239 * tree-ssa-sccvn.c (vn_reference_lookup_3): When skipping
2240 over a stored-same value may-alias store make sure to consider
2241 partial overlaps which are valid when TBAA reasonings do not
2242 apply and byte-granular overlaps are possible at all.
2243
2244 2018-11-28 Richard Biener <rguenther@suse.de>
2245
2246 PR tree-optimization/88217
2247 * vr-values.c (vr_values::extract_range_from_phi_node): Make
2248 sure to handle results > +INF and < -INF correctly when
2249 trying to drop down to +INF - 1 or -INF + 1.
2250
2251 2018-11-28 Alan Modra <amodra@gmail.com>
2252
2253 * xcoffout.c (do_block): Signed/unsigned warning fix.
2254
2255 2018-11-28 Richard Biener <rguenther@suse.de>
2256
2257 PR tree-optimization/79351
2258 * tree-ssa-sccvn.c (vn_reference_lookup_3): For assignments from
2259 empty CONSTRUCTORs ensure the store is at a constant position.
2260
2261 2018-11-28 Richard Biener <rguenther@suse.de>
2262
2263 PR tree-optimization/88229
2264 * tree-ssa.c (non_rewritable_mem_ref_base): Check DECL_SIZE_UNIT
2265 is an INTEGER_CST before accessing it so.
2266
2267 2018-11-28 Sam Tebbs <sam.tebbs@arm.com>
2268
2269 * doc/invoke.texi (-mtune=): Remove obsolete CPU names.
2270
2271 2018-11-28 Jakub Jelinek <jakub@redhat.com>
2272
2273 PR target/88189
2274 * config/i386/i386.c (ix86_expand_sse_movcc): Handle DFmode and
2275 SFmode using sse4_1_blendvs[sd] with TARGET_SSE4_1. Formatting fixes.
2276 * config/i386/sse.md (sse4_1_blendv<ssemodesuffix>): New pattern.
2277
2278 2018-11-27 Martin Liska <mliska@suse.cz>
2279
2280 * gcov.c (generate_results): Append current_working_directory
2281 only when exists.
2282
2283 2018-11-27 Mike Gulick <mgulick@mathworks.com>
2284
2285 PR preprocessor/83173
2286 * input.c (dump_location_info): Dump reason and included_from
2287 fields from line_map_ordinary struct. Fix indentation when
2288 location > 5 digits.
2289 * diagnostic-show-locus.c (num_digits, num_digits): Move to
2290 diagnostic.c to allow it to be utilized by input.c.
2291 * diagnostic.c (num_digits, selftest::test_num_digits): Moved
2292 here.
2293 (selftest::diagnostic_c_tests): Run selftest::test_num_digits.
2294 * diagnostic.h (num_digits): Add extern definition.
2295
2296 2018-11-27 Fredrik Noring <noring@nocrew.org>
2297
2298 * config/mips/mips.c (mips_reorg_process_insns)
2299 (mips_option_override): Handle `-mfix-r5900'.
2300 * config/mips/mips.h (ASM_SPEC): Add `mfix-r5900' and
2301 `mno-fix-r5900'.
2302 * config/mips/mips.opt (mfix-r5900): New option.
2303 * doc/invoke.texi: Document the `r5900' processor name, and
2304 `-mfix-r5900' and `-mno-fix-r5900' options.
2305
2306 2018-11-27 Jakub Jelinek <jakub@redhat.com>
2307
2308 PR target/88188
2309 * config/rs6000/rs6000.c (print_operand) <case 'D'>: Use
2310 output_operand_lossage instead of gcc_assert.
2311 <case 't'>: Likewise.
2312 <case 'z'>: Likewise.
2313 <case 'V'>: Use output_operand_lossage instead of gcc_unreachable.
2314
2315 2018-11-27 Jeff Law <law@redhat.com>
2316
2317 * config/riscv/riscv (riscv_block_mvoe_straight): Use RETURN_BEGIN
2318 in call to move_by_pieces.
2319
2320 * config/sh/sh-mem.c (expand_block_move): Use RETURN_BEGIN in call
2321 to move_by_pieces.
2322
2323 * config/lm32/lm32.c (lm32_block_move_inline): Use RETURN_BEGIN in
2324 call to move_by_pieces.
2325
2326 * config/mips/mips.c (mips_block_move_straight): Use RETURN_BEGIN
2327 in call to move_by_pieces.
2328
2329 * config/microblaze/microblaze.c (microblaze_block_move_straight): Use
2330 RETURN_BEGIN in call to move_by_pieces.
2331 (microblaze_expand_block_move): Likewise.
2332
2333 2018-11-27 Tamar Christina <tamar.christina@arm.com>
2334
2335 * doc/md.texi (xorsign): Document it.
2336
2337 2018-11-27 Martin Liska <mliska@suse.cz>
2338
2339 * config/gnu-user.h (TARGET_F951_OPTIONS): New.
2340 * gcc.c (find_fortran_preinclude_file): New function
2341 to handle Fortran pre-include.
2342
2343 2018-11-27 Martin Liska <mliska@suse.cz>
2344
2345 * asan.c (asan_emit_stack_protection): Use new enum values
2346 instead of int constants.
2347 * builtins.c (expand_builtin_memory_copy_args): Replace int
2348 type with memop_ret enum type.
2349 (expand_builtin_mempcpy_args): Likewise.
2350 (expand_builtin_memcpy): Use new enum values
2351 instead of int constants. Likewise.
2352 (expand_builtin_mempcpy): Likewise.
2353 (expand_movstr): Likewise.
2354 (expand_builtin_strcpy_args): Likewise.
2355 (expand_builtin_stpcpy_1): Likewise.
2356 (expand_builtin_strncpy): Likewise.
2357 (expand_builtin_memset_args): Likewise.
2358 * expr.c (move_by_pieces_d::finish_endp): Rename to ...
2359 (move_by_pieces_d::finish_retmode): ... this.
2360 (move_by_pieces): Change last argument type to memop_ret.
2361 (store_by_pieces): Use new enum values
2362 instead of int constants.
2363 (emit_block_move_hints): Likewise.
2364 (emit_push_insn): Likewise.
2365 (store_expr): Likewise.
2366 * expr.h (store_by_pieces): Change int to newly added enum
2367 type.
2368 * rtl.h (enum memop_ret): Define.
2369 (move_by_pieces): Use the enum type.
2370
2371 2018-11-27 Alan Modra <amodra@gmail.com>
2372
2373 * config/rs6000/aix71.h (ASM_SPEC): Don't select default -maix64
2374 cpu here.
2375 (ASM_CPU_SPEC): Do so here. Rewrite using if .. else if .. specs
2376 form. Error on missing -mcpu case.
2377 * config/rs6000/driver-rs6000.c (asm_names <_AIX>): Update NULL case.
2378 (asm_names <!_AIX>): Add missing cpus. Update NULL case. Apply
2379 PR63177 fix for -mcpu=power8 and -mcpu=powerpc64le.
2380 * config/rs6000/rs6000.h (ASM_CPU_SPEC): Rewrite using if ..
2381 else if .. specs form. Error on missing -mcpu case. Don't output
2382 duplicate -maltivec. Apply PR63177 fix for -mcpu=powerpc64le.
2383
2384 2018-11-26 David Malcolm <dmalcolm@redhat.com>
2385
2386 * dump-context.h (dump_context::dump_loc): Convert 1st param from
2387 dump_flags_t to const dump_metadata_t &. Convert 2nd param from
2388 const dump_location_t & to const dump_user_location_t &.
2389 (dump_context::dump_loc_immediate): Convert 2nd param from
2390 const dump_location_t & to const dump_user_location_t &.
2391 (dump_context::dump_gimple_stmt): Convert 1st param from
2392 dump_flags_t to const dump_metadata_t &.
2393 (dump_context::void dump_gimple_stmt_loc): Likewise; convert
2394 2nd param from const dump_location_t & to
2395 const dump_user_location_t &.
2396 (dump_context::dump_gimple_expr): Convert 1st param from
2397 dump_flags_t to const dump_metadata_t &.
2398 (dump_context::dump_gimple_expr_loc): Likewise; convert
2399 2nd param from const dump_location_t & to
2400 const dump_user_location_t &.
2401 (dump_context::dump_generic_expr): Convert 1st param from
2402 dump_flags_t to const dump_metadata_t &.
2403 (dump_context::dump_generic_expr_loc): Likewise; convert
2404 2nd param from const dump_location_t & to
2405 const dump_user_location_t &.
2406 (dump_context::dump_printf_va): Convert 1st param from
2407 dump_flags_t to const dump_metadata_t &.
2408 (dump_context::dump_printf_loc_va): Likewise; convert
2409 2nd param from const dump_location_t & to
2410 const dump_user_location_t &.
2411 (dump_context::dump_dec): Convert 1st param from
2412 dump_flags_t to const dump_metadata_t &.
2413 (dump_context::dump_symtab_node): Likewise.
2414 (dump_context::begin_scope): Split out 2nd param into
2415 user and impl locations.
2416 (dump_context::ensure_pending_optinfo): Add metadata param.
2417 (dump_context::begin_next_optinfo): Replace dump_location_t param
2418 with metadata and user location.
2419 * dumpfile.c (dump_context::dump_loc): Convert 1st param from
2420 dump_flags_t to const dump_metadata_t &. Convert 2nd param from
2421 const dump_location_t & to const dump_user_location_t &.
2422 (dump_context::dump_loc_immediate): Convert 2nd param from
2423 const dump_location_t & to const dump_user_location_t &.
2424 (dump_context::dump_gimple_stmt): Convert 1st param from
2425 dump_flags_t to const dump_metadata_t &.
2426 (dump_context::void dump_gimple_stmt_loc): Likewise; convert
2427 2nd param from const dump_location_t & to
2428 const dump_user_location_t &.
2429 (dump_context::dump_gimple_expr): Convert 1st param from
2430 dump_flags_t to const dump_metadata_t &.
2431 (dump_context::dump_gimple_expr_loc): Likewise; convert
2432 2nd param from const dump_location_t & to
2433 const dump_user_location_t &.
2434 (dump_context::dump_generic_expr): Convert 1st param from
2435 dump_flags_t to const dump_metadata_t &.
2436 (dump_context::dump_generic_expr_loc): Likewise; convert
2437 2nd param from const dump_location_t & to
2438 const dump_user_location_t &.
2439 (dump_context::dump_printf_va): Convert 1st param from
2440 dump_flags_t to const dump_metadata_t &.
2441 (dump_context::dump_printf_loc_va): Likewise; convert
2442 2nd param from const dump_location_t & to
2443 const dump_user_location_t &.
2444 (dump_context::dump_dec): Convert 1st param from
2445 dump_flags_t to const dump_metadata_t &.
2446 (dump_context::dump_symtab_node): Likewise.
2447 (dump_context::begin_scope): Split out 2nd param into
2448 user and impl locations.
2449 (dump_context::ensure_pending_optinfo): Add metadata param.
2450 (dump_context::begin_next_optinfo): Replace dump_location_t param
2451 with metadata and user location.
2452 (dump_gimple_stmt): Convert 1st param from dump_flags_t to
2453 const dump_metadata_t &.
2454 (dump_gimple_stmt_loc): Likewise; convert 2nd param from
2455 const dump_location_t & to const dump_user_location_t &.
2456 (dump_gimple_expr): Convert 1st param from dump_flags_t to
2457 const dump_metadata_t &.
2458 (dump_gimple_expr_loc): Likewise; convert 2nd param from
2459 const dump_location_t & to const dump_user_location_t &.
2460 (dump_generic_expr): Convert 1st param from dump_flags_t to
2461 const dump_metadata_t &.
2462 (dump_generic_expr_loc): Likewise; convert 2nd param from
2463 const dump_location_t & to const dump_user_location_t &.
2464 (dump_printf): Convert 1st param from dump_flags_t to
2465 const dump_metadata_t &.
2466 (dump_printf_loc): Likewise; convert 2nd param from
2467 const dump_location_t & to const dump_user_location_t &.
2468 (dump_dec): Convert 1st param from dump_flags_t to
2469 const dump_metadata_t &.
2470 (dump_symtab_node): Likewise.
2471 (dump_begin_scope): Split out 2nd param into user and impl
2472 locations.
2473 (selftest::assert_impl_location_eq): New function.
2474 (ASSERT_IMPL_LOCATION_EQ): New macro.
2475 (selftest::test_impl_location): Update to use
2476 ASSERT_IMPL_LOCATION_EQ.
2477 (selftest::test_capture_of_dump_calls): Convert "loc" to
2478 dump_user_location_t. Add ASSERT_IMPL_LOCATION_EQ throughout,
2479 verifying line numbers of dump emissions.
2480 * dumpfile.h (class dump_metadata_t): New class.
2481 (dump_printf): Convert 1st param from dump_flags_t to
2482 const dump_metadata_t &.
2483 (dump_printf_loc): Likewise; convert 2nd param from
2484 const dump_location_t & to const dump_user_location_t &.
2485 (dump_generic_expr_loc): Likewise.
2486 (dump_generic_expr): Convert 1st param from dump_flags_t to
2487 const dump_metadata_t &.
2488 (dump_gimple_stmt_loc): Likewise; convert 2nd param from
2489 const dump_location_t & to const dump_user_location_t &.
2490 (dump_gimple_stmt): Convert 1st param from dump_flags_t to
2491 const dump_metadata_t &.
2492 (dump_gimple_expr_loc): Likewise; convert 2nd param from
2493 const dump_location_t & to const dump_user_location_t &.
2494 (dump_gimple_expr): Convert 1st param from dump_flags_t to
2495 const dump_metadata_t &.
2496 (dump_symtab_node): Likewise.
2497 (dump_dec): Likewise.
2498 (dump_begin_scope): Split out 2nd param into user and impl
2499 locations.
2500 (auto_dump_scope::auto_dump_scope): Split "loc" param into a user
2501 location and impl_location, and capture the impl_location.
2502 (AUTO_DUMP_SCOPE): Rename param from LOC to USER_LOC.
2503 * loop-unroll.c (report_unroll): Update for changes to
2504 dump_printf_loc and dump_printf.
2505 * opt-problem.cc (opt_problem::opt_problem): Update for change to
2506 dump_loc.
2507 * optinfo-emit-json.cc
2508 (selftest::test_building_json_from_dump_calls): Convert "loc" from
2509 dump_location_t to dump_user_location_t.
2510 * optinfo.cc (optinfo::emit_for_opt_problem): Update for change in
2511 dump_loc_immediate.
2512 * profile.c (compute_branch_probabilities): Update for change to
2513 dump_printf_loc.
2514 * selftest.h (ASSERT_STR_CONTAINS_AT): New macro.
2515 * tree-vect-slp.c (vect_print_slp_tree): Update for change to
2516 dump_printf_loc.
2517
2518 2018-11-27 Jozef Lawrynowicz <jozef.l@mittosystems.com>
2519
2520 * doc/sourcebuild.texi: Document check_effective_target_int_eq_float
2521 and check_effective_target_ptr_eq_long.
2522
2523 2018-11-27 Alan Modra <amodra@gmail.com>
2524
2525 * config.gcc (powerpc*-*-freebsd*, powerpc-*-netbsd*),
2526 (powerpc-*-eabisimaltivec*, powerpc-*-eabisim*, powerpc-*-elf*),
2527 (powerpc-*-eabialtivec*, powerpc-*-eabi*, powerpc-*-rtems*),
2528 (powerpc-wrs-vxworks*, powerpc-*-lynxos*, powerpcle-*-elf*),
2529 (powerpcle-*-eabisim*, powerpcle-*-eabi*): Add gnu-user.h to tm_file.
2530 * config/rs6000/freebsd.h (CPLUSPLUS_CPP_SPEC),
2531 (LINK_GCC_C_SEQUENCE_SPEC): Undef.
2532 (ASM_APP_ON, ASM_APP_OFF): Don't define.
2533 * config/rs6000/freebsd64.h (ASM_APP_ON, ASM_APP_OFF): Don't define.
2534 * config/rs6000/lynx.h (ASM_APP_ON, ASM_APP_OFF): Don't define.
2535 * config/rs6000/linux64.h (LINK_GCC_C_SEQUENCE_SPEC): Define.
2536 * config/rs6000/netbsd.h (CPLUSPLUS_CPP_SPEC),
2537 (LINK_GCC_C_SEQUENCE_SPEC): Undef.
2538 * config/rs6000/rtems.h (LINK_GCC_C_SEQUENCE_SPEC): Define.
2539 * config/rs6000/sysv4.h (GNU_USER_TARGET_CRTI): Redefine.
2540 (GNU_USER_TARGET_CRTN): Redefine.
2541 (CC1_SPEC): Use GNU_USER_TARGET_CC1_SPEC.
2542 (LIB_LINUX_SPEC): Use GNU_USER_TARGET_LIB_SPEC.
2543 (CRTOFFLOADBEGIN, CRTOFFLOADEND): Don't define.
2544 (STARTFILE_LINUX_SPEC): Define as GNU_USER_TARGET_STARTFILE_SPEC.
2545 (ENDFILE_LINUX_SPEC): Define as GNU_USER_TARGET_ENDFILE_SPEC.
2546 (UCLIBC_DYNAMIC_LINKER, CHOOSE_DYNAMIC_LINKER): Don't define.
2547 (LINK_EH_SPEC): Don't define.
2548
2549 2018-11-26 Martin Sebor <msebor@redhat.com>
2550
2551 PR 87756
2552 * expr.c (string_constant): Handle top-level decls of all character
2553 types and subobjects of narrow character type.
2554
2555 2018-11-27 Alan Modra <amodra@gmail.com>
2556
2557 * config.gcc (powerpc*-*-linux*): Add linux.h to tm_file.
2558 * config/rs6000/linux.h (TARGET_OS_CPP_BUILTINS): Use
2559 GNU_USER_TARGET_OS_CPP_BUILTINS.
2560 (RS6000_ABI_NAME): Define.
2561 * config/rs6000/linux64.h (TARGET_OS_CPP_BUILTINS): Use
2562 GNU_USER_TARGET_OS_CPP_BUILTINS.
2563 (MUSL_DYNAMIC_LINKER32): Undef before defining.
2564 (UCLIBC_DYNAMIC_LINKER32, UCLIBC_DYNAMIC_LINKER64): Don't define.
2565 (CHOOSE_DYNAMIC_LINKER): Don't define.
2566 (GNU_USER_DYNAMIC_LINKER32, GNU_USER_DYNAMIC_LINKER64): Don't define.
2567 * config/rs6000/sysv4.h (MUSL_DYNAMIC_LINKER): Undef before defining.
2568 (CHOOSE_DYNAMIC_LINKER, GNU_USER_DYNAMIC_LINKER): Only define when
2569 not already defined.
2570 (CPP_OS_LINUX_SPEC): Remove defines and asserts handled by
2571 TARGET_OS_CPP_BUILTINS.
2572
2573 2018-11-26 Jozef Lawrynowicz <jozef.l@mittosystems.com>
2574
2575 * doc/sourcebuild.texi: Document check_effective_target_newlib_nano_io.
2576
2577 2018-11-26 Jakub Jelinek <jakub@redhat.com>
2578
2579 PR target/88195
2580 * config/i386/i386.c (def_builtin2): If tcode == VOID_FTYPE_UINT64
2581 and !TARGET_64BIT, return NULL_TREE.
2582
2583 PR c++/86900
2584 * dwarf2out.c (secname_for_decl): For functions with
2585 DECL_SECTION_NAME if in_cold_section_p, try to return
2586 current_function_section's name if it is a named section.
2587
2588 2018-11-26 Maya Rashish <coypu@sdf.org>
2589
2590 PR target/58397
2591 * config.host (*-*-netbsd*): Use x-netbsd and host-netbsd.o.
2592 * config/x-netbsd: New file.
2593 * config/host-netbsd: New file.
2594
2595 2018-11-26 Jozef Lawrynowicz <jozef.l@mittosystems.com>
2596
2597 * doc/sourcebuild.texi: Document check_effective_target_size20plus.
2598 Clarify documentation for check_effective_target_size32plus.
2599
2600 2018-11-26 Aaron Sawdey <acsawdey@linux.ibm.com>
2601
2602 * config/rs6000/rs6000-string.c (expand_cmp_vec_sequence): Rename
2603 and modify expand_strncmp_vec_sequence.
2604 (emit_final_compare_vec): Rename and modify emit_final_str_compare_vec.
2605 (generate_6432_conversion): New function.
2606 (expand_block_compare): Add support for vsx.
2607 (expand_block_compare_gpr): New function.
2608 * config/rs6000/rs6000.opt (rs6000_block_compare_inline_limit): Increase
2609 default limit to 63 because of more compact vsx code.
2610
2611 2018-11-26 Uros Bizjak <ubizjak@gmail.com>
2612
2613 PR target/88178
2614 * config/i386/i386.c (dbx_register_map): Use IGNORED_DWARF_REGNUM
2615 for registers for which no debug information can be generated.
2616 Use INVALID_REGNUM for non-existent registers.
2617 (dbx64_register_map): Ditto.
2618 (svr4_dbx_register_map): Ditto.
2619
2620 2018-11-26 Sandra Loosemore <sandra@codesourcery.com>
2621
2622 PR c/57182
2623 * doc/invoke.texi (Optimize Options): Document that
2624 -freorder-functions also uses "hot" and "cold" attributes.
2625
2626 2018-11-26 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
2627
2628 * config/aarch64/aarch64.c (aarch64_mangle_type): Fix typo in comment.
2629
2630 2018-11-26 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
2631
2632 * config/arm/types.md (mul64): Rename to...
2633 (widen_mul64): ... This.
2634 * config/arm/arm-generic.md: Rename mul64 to widen_mul64.
2635 * config/arm/cortex-a15.md: Likewise.
2636 * config/arm/cortex-a5.md: Likewise.
2637 * config/arm/cortex-a53.md: Likewise.
2638 * config/arm/cortex-a57.md: Likewise.
2639 * config/arm/cortex-a7.md: Likewise.
2640 * config/arm/cortex-m4.md: Likewise.
2641 * config/arm/exynos-m1.md: Likewise.
2642 * config/arm/marvell-pj4.md: Likewise.
2643 * config/arm/xgene1.md: Likewise.
2644
2645 2018-11-26 Richard Biener <rguenther@suse.de>
2646
2647 PR tree-optimization/88182
2648 * tree-vect-loop.c (vectorizable_reduction): Pick up single
2649 correct reduc_def_info.
2650 * tree-vect-slp.c (vect_analyze_slp_instance): Set
2651 STMT_VINFO_REDUC_DEF of the first stmt.
2652
2653 2018-11-26 Andreas Krebbel <krebbel@linux.ibm.com>
2654
2655 * doc/invoke.texi: Document z14/arch12 -march option.
2656
2657 2018-11-25 Sandra Loosemore <sandra@codesourcery.com>
2658
2659 PR c/57166
2660 * doc/invoke.texi (Option Summary): Add -Wmissing-noreturn.
2661 (Warning Options): Likewise.
2662
2663 2018-11-25 Sandra Loosemore <sandra@codesourcery.com>
2664
2665 PR web/79738
2666 * doc/extend.texi (Common Function Attributes): Clarify that
2667 functions with "const" attribute can read const global variables.
2668
2669 2018-11-26 Alan Modra <amodra@gmail.com>
2670
2671 * config/rs6000/rs6000.h (OBJECT_PEF, TARGET_MACOS): Delete.
2672
2673 2018-11-25 Sandra Loosemore <sandra@codesourcery.com>
2674
2675 PR other/54265
2676 * doc/extend.texi (Common Variable Attributes): Use preferred
2677 placement of type attributes in examples, plus whitespace fixes.
2678 (Type Attributes): Clarify why placement of attributes
2679 immediately after struct/union/enum keyword is preferred.
2680 (Common Type Attributes): Use preferred placement of type
2681 attributes in examples, plus more whitespace fixes.
2682
2683 2018-11-25 Paul Koning <ni1d@arrl.net>
2684
2685 * config/pdp11/pdp11.h (TARGET_HAS_NO_HW_DIVIDE): Define.
2686
2687 2018-11-25 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2688
2689 * doc/sourcebuild.texi (Effective-Target Keywords, Environment
2690 attributes): Document d_runtime.
2691
2692 2018-11-25 Vladimir Makarov <vmakarov@redhat.com>
2693
2694 PR bootstrap/88157
2695 * ira-costs.c (record_operand_costs): Initiate register move cost
2696 for mode.
2697
2698 2018-11-23 Jeff Law <law@redhat.com>
2699
2700 PR rtl-optimization/87468
2701 * tree-ssa-threadupdate.c (create_block_for_threading): Clear
2702 EDGE_IGNORE on all outgoing edges of the duplicate block.
2703
2704 2018-11-23 Vladimir Makarov <vmakarov@redhat.com>
2705
2706 PR bootstrap/88157
2707 * ira-costs.c (record_operand_costs): Use bigger hard reg class if
2708 its mode does not fit to the original class.
2709
2710 2018-11-23 Martin Sebor <msebor@redhat.com>
2711
2712 PR tree-optimization/87756
2713 * expr.c (string_constant): Synthesize a string literal from
2714 the address of a constant character.
2715 * tree.c (build_string_literal): Add an argument.
2716 * tree.h (build_string_literal): Same.
2717
2718 2018-11-23 Christoph Muellner <christoph.muellner@theobroma-systems.com>
2719
2720 * config/aarch64/aarch64-cores.def: Define emag.
2721 * config/aarch64/aarch64-tune.md: Regenerated with emag.
2722 * config/aarch64/aarch64.c (emag_tunings): New struct.
2723 * doc/invoke.texi: Document mtune value.
2724
2725 2018-11-23 Christoph Muellner <christoph.muellner@theobroma-systems.com>
2726 Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
2727
2728 * config/aarch64/aarch64.c (xgene1_tunings): Optimize Xgene1 tunings
2729 for GCC 9.
2730 * config/aarch64/aarch64.c (xgene1_tunings): Add Xgene1 specific
2731 prefetch tunings.
2732 * config/aarch64/aarch64.c (xgene1_addrcost_table): Correct the post-modify
2733 costs.
2734 * config/arm/aarch-cost-tables.h (xgene1_extra_costs): Update the cost table
2735 for XGene1.
2736
2737 2018-11-23 Richard Biener <rguenther@suse.de>
2738
2739 PR tree-optimization/88149
2740 * tree-vect-slp.c (vect_slp_analyze_node_operations): Detect
2741 the case where there are two different def types for the
2742 same operand at different operand position in the same stmt.
2743
2744 2018-23-11 Mihail Ionescu <mihail.ionescu@arm.com>
2745
2746 * config/arm/arm.c (arm_expand_compare_and_swap): Simplify and call
2747 gen_atomic_compare_swap_1.
2748 (arm_evpc_neon_vuzp): Likewise gen_neon_vuzp_internal.
2749 (arm_evpc_neon_vtrn): Likewise gen_neon_vtrn_internal.
2750 (arm_evpc_neon_vext): Likewise gen_neon_vext_internal.
2751 (arm_evpc_neon_vzip): Likewise gen_neon_vzip_internal.
2752 (arm_evpc_neon_vrev): Replace the function pointer and simplify the mode
2753 checks.
2754 * config/arm/arm.md (neon_vext<mode>),
2755 (neon_vrev64<mode>, neon_vrev32<mode>),
2756 (neon_vrev16<mode>, neon_vtrn<mode>_internal),
2757 (neon_vzip<mode>_internal, neon_vuzp<mode>_internal): Add an '@'character
2758 before the pattern name.
2759 * config/arm/sync.md:
2760 (atomic_compare_and_swap<CCSI:arch><NARROW:mode>_1),
2761 (atomic_compare_and_swap<CCSI:arch><SIDI:mode>_1): Likewise.
2762
2763 2018-11-23 Jakub Jelinek <jakub@redhat.com>
2764
2765 PR tree-optimization/86614
2766 * gimple-ssa-warn-restrict.c (maybe_diag_offset_bounds): Return early
2767 if TREE_NO_WARNING is set on ref.ref.
2768
2769 2018-11-22 Sandra Loosemore <sandra@codesourcery.com>
2770 Alan Coopersmith <alan.coopersmith@oracle.com>
2771
2772 PR c/53608
2773 * doc/extend.texi (Designated Inits): Clarify handling of multiple
2774 initializers for unions.
2775
2776 2018-11-22 Jan Hubicka <jh@suse.cz>
2777
2778 PR lto/88142
2779 * ipa-devirt.c (type_variants_equivalent_p): Drop warn and warned
2780 parameters; do not warn here.
2781 (odr_subtypes_equivalent_p): Likewise.
2782 (warn_odr): Fix typo.
2783 (warn_types_mismatch): Do not output confused warnings on integer types.
2784 (odr_types_equivalent_p): Update.
2785
2786 2018-11-22 Jakub Jelinek <jakub@redhat.com>
2787
2788 * config/i386/i386.c (ix86_option_override_internal,
2789 ix86_can_inline_p, classify_argument, construct_container,
2790 ix86_expand_prologue, ix86_expand_split_stack_prologue,
2791 ix86_expand_carry_flag_compare, expand_set_or_movmem_via_loop,
2792 expand_setmem_epilogue_via_loop, promote_duplicated_reg,
2793 ix86_expand_set_or_movmem, ix86_init_builtins_va_builtins_abi):
2794 Formatting fixes.
2795
2796 * config/i386/i386.c (ix86_option_override_internal): For
2797 stack_protector_guard related options, use opts_set->x_ instead
2798 of global_options_set. and prefix options with opts->x_ . Move
2799 defaults for offset and reg into else block.
2800
2801 2018-11-22 Uros Bizjak <ubizjak@gmail.com>
2802
2803 * config/i386/i386.c (ix86_check_avx_upper_register):
2804 Return true for all SSE registers with mode bitsize > 128.
2805
2806 2018-11-22 Vladimir Makarov <vmakarov@redhat.com>
2807
2808 PR rtl-optimization/87718
2809 * ira-costs.c: Remove trailing white-spaces.
2810 (record_operand_costs): Add a special treatment for moves
2811 involving a hard register.
2812
2813 2018-11-22 Uros Bizjak <ubizjak@gmail.com>
2814
2815 * config/i386/i386.c (ix86_avx_emit_vzeroupper): Remove.
2816 (ix86_emit_mode_set) <case AVX_U128>: Emit vzeroupper here.
2817
2818 2018-11-22 Martin Liska <mliska@suse.cz>
2819
2820 * common/config/i386/i386-common.c (processor_names): Add
2821 static assert and add missing "znver2".
2822 (ix86_get_valid_option_values): Add checking assert for null
2823 values and add "native" value if feasible.
2824 * config/i386/i386.h: Do not declare size of processor_names.
2825 * common/config/i386/i386-common.c:
2826 * config/i386/i386.c: Add static assert for size
2827 of processor_cost_table.
2828
2829 2018-11-22 Thomas Preud'homme <thomas.preudhomme@linaro.org>
2830
2831 * target-insns.def (stack_protect_combined_set): Define new standard
2832 pattern name.
2833 (stack_protect_combined_test): Likewise.
2834 * cfgexpand.c (stack_protect_prologue): Try new
2835 stack_protect_combined_set pattern first.
2836 * function.c (stack_protect_epilogue): Try new
2837 stack_protect_combined_test pattern first.
2838 * config/arm/arm.c (require_pic_register): Add pic_reg and compute_now
2839 parameters to control which register to use as PIC register and force
2840 reloading PIC register respectively. Insert in the stream of insns if
2841 possible.
2842 (legitimize_pic_address): Expose above new parameters in prototype and
2843 adapt recursive calls accordingly. Use pic_reg if non null instead of
2844 cached one.
2845 (arm_load_pic_register): Add pic_reg parameter and use it if non null.
2846 (arm_legitimize_address): Adapt to new legitimize_pic_address
2847 prototype.
2848 (thumb_legitimize_address): Likewise.
2849 (arm_emit_call_insn): Adapt to require_pic_register prototype change.
2850 (arm_expand_prologue): Adapt to arm_load_pic_register prototype change.
2851 (thumb1_expand_prologue): Likewise.
2852 * config/arm/arm-protos.h (legitimize_pic_address): Adapt to prototype
2853 change.
2854 (arm_load_pic_register): Likewise.
2855 * config/arm/predicated.md (guard_addr_operand): New predicate.
2856 (guard_operand): New predicate.
2857 * config/arm/arm.md (movsi expander): Adapt to legitimize_pic_address
2858 prototype change.
2859 (builtin_setjmp_receiver expander): Adapt to thumb1_expand_prologue
2860 prototype change.
2861 (stack_protect_combined_set): New expander..
2862 (stack_protect_combined_set_insn): New insn_and_split pattern.
2863 (stack_protect_set_insn): New insn pattern.
2864 (stack_protect_combined_test): New expander.
2865 (stack_protect_combined_test_insn): New insn_and_split pattern.
2866 (arm_stack_protect_test_insn): New insn pattern.
2867 * config/arm/thumb1.md (thumb1_stack_protect_test_insn): New insn pattern.
2868 * config/arm/unspecs.md (UNSPEC_SP_SET): New unspec.
2869 (UNSPEC_SP_TEST): Likewise.
2870 * doc/md.texi (stack_protect_combined_set): Document new standard
2871 pattern name.
2872 (stack_protect_set): Clarify that the operand for guard's address is
2873 legal.
2874 (stack_protect_combined_test): Document new standard pattern name.
2875 (stack_protect_test): Clarify that the operand for guard's address is
2876 legal.
2877
2878 2018-11-22 Richard Biener <rguenther@suse.de>
2879
2880 PR tree-optimization/88148
2881 * tree-ssa-loop-niter.c (simplify_replace_tree): Get optional
2882 valueization callback parameter and handle it.
2883 * tree-ssa-loop-niter.h (simplify_replace_tree): Export.
2884 * tree-ssa-sccvn.c (process_bb): Eliminate in loop niter trees.
2885
2886 2018-11-22 Richard Biener <rguenther@suse.de>
2887
2888 PR lto/87229
2889 PR lto/88112
2890 * lto-streamer-out.c (lto_is_streamable): Allow CALL_EXPRs
2891 which can appear in size expressions.
2892 * tree-streamer-in.c (unpack_ts_base_value_fields): Stream
2893 CALL_EXPR_BY_DESCRIPTOR.
2894 (streamer_read_tree_bitfields): Stream CALL_EXPR_IFN.
2895 * tree-streamer-out.c (pack_ts_base_value_fields): Stream
2896 CALL_EXPR_BY_DESCRIPTOR.
2897 (streamer_write_tree_bitfields): Stream CALL_EXPR_IFN.
2898
2899 Revert
2900 PR lto/87229
2901 * tree.c (free_lang_data_in_one_sizepos): Free non-gimple-val
2902 sizepos values.
2903
2904 2018-11-22 Richard Biener <rguenther@suse.de>
2905
2906 PR tree-optimization/88069
2907 * tree-ssa-sccvn.c (visit_phi): Tweak previous fix to not
2908 apply to default defs.
2909
2910 2018-11-22 Jakub Jelinek <jakub@redhat.com>
2911
2912 PR target/85644
2913 PR target/86832
2914 * config/i386/i386.c (ix86_option_override_internal): Default
2915 ix86_stack_protector_guard to SSP_TLS only if TARGET_THREAD_SSP_OFFSET
2916 is defined.
2917 * config/i386/i386.md (stack_protect_set, stack_protect_set_<mode>,
2918 stack_protect_test, stack_protect_test_<mode>): Use empty condition
2919 instead of TARGET_SSP_TLS_GUARD.
2920
2921 2018-11-22 Martin Liska <mliska@suse.cz>
2922
2923 PR sanitizer/88017
2924 * config/i386/i386.c (ix86_option_override_internal): Error
2925 about usage -mabi=ms and -fsanitize=thread.
2926
2927 2018-11-21 Uros Bizjak <ubizjak@gmail.com>
2928
2929 Revert the revert:
2930 2013-10-26 Vladimir Makarov <vmakarov@redhat.com>
2931
2932 Revert:
2933 2013-10-25 Vladimir Makarov <vmakarov@redhat.com>
2934
2935 * lra-spills.c (lra_final_code_change): Remove useless move insns.
2936
2937 2018-11-21 Uros Bizjak <ubizjak@gmail.com>
2938
2939 PR middle-end/88129
2940 * function.c (expand_function_end): Do not emit extra blockage insn.
2941
2942 2018-11-21 Lokesh Janghel <lokeshjanghel91@gmail.com>
2943
2944 PR target/85667
2945 * config/i386/i386.c (function_value_ms_64): Return AX_REG instead
2946 of FIRST_SSE_REG for 4 or 8 byte modes.
2947
2948 2018-11-21 Jan Hubicka <jh@suse.cz>
2949
2950 PR lto/87957
2951 * tree.c (fld_decl_context): Break out from ...
2952 (free_lang_data_in_decl): ... here; free TREE_PUBLIC, TREE_PRIVATE
2953 DECL_ARTIFICIAL of TYPE_DECL; do not free TREE_TYPE of TYPE_DECL.
2954 (fld_incomplete_type_of): Build copy of TYP_DECL.
2955 * ipa-devirt.c (free_enum_values): Rename to ...
2956 (free_odr_warning_data): ... this one; free also duplicated TYPE_DECLs
2957 and TREE_TYPEs of TYPE_DECLs.
2958 (get_odr_type): Initialize odr_vtable_hash if needed.
2959
2960 2018-11-21 Alexandre Oliva <oliva@adacore.com>
2961
2962 * final.c (compute_discriminator): Declare. Renamed from...
2963 (maybe_set_discriminator): ... this. Set and return a local.
2964 (override_discriminator): New.
2965 (final_scan_insn_1): Set it.
2966 (notice_source_line): Adjust. Always set discriminator.
2967
2968 2018-11-21 Jakub Jelinek <jakub@redhat.com>
2969
2970 PR target/87839
2971 * config/aarch64/atomics.md (@aarch64_compare_and_swap<mode>): Use
2972 rIJ constraint for aarch64_plus_operand rather than rn.
2973
2974 2018-11-21 Renlin Li <renlin.li@arm.com>
2975
2976 PR middle-end/84877
2977 * explow.h (get_dynamic_stack_size): Declare it as external.
2978 * explow.c (record_new_stack_level): Remove function static attribute.
2979 * function.c (assign_stack_local_1): Dynamically align the stack slot
2980 addr for parameter copy on the stack.
2981
2982 2018-11-21 Richard Biener <rguenther@suse.de>
2983
2984 PR bootstrap/88133
2985 * bitmap.c (bitmap_last_set_bit): Refactor to avoid warning.
2986 * Makefile.in (bitmap.o-warn): Remove again.
2987
2988 2018-11-20 Jeff Law <law@redhat.com>
2989
2990 PR tree-optimization/88069
2991 * tree-ssa-dom.c (record_equivalences_from_phis): Propagate away
2992 degenerate virtual PHIs.
2993
2994 2018-11-21 H.J. Lu <hongjiu.lu@intel.com>
2995
2996 PR target/87317
2997 * config/i386/sse.md (sse4_1_<code>v8qiv8hi2<mask_name>): Replace
2998 nonimmediate_operand with register_operand.
2999 (avx2_<code>v8qiv8si2<mask_name>): Likewise.
3000 (sse4_1_<code>v4qiv4si2<mask_name>): Likewise.
3001 (sse4_1_<code>v4hiv4si2<mask_name>): Likewise.
3002 (sse4_1_<code>v2qiv2di2<mask_name>): Likewise.
3003 (avx512f_<code>v8qiv8di2<mask_name>): Likewise.
3004 (avx2_<code>v4qiv4di2<mask_name>): Likewise.
3005 (avx2_<code>v4hiv4di2<mask_name>): Likewise.
3006 (sse4_1_<code>v2hiv2di2<mask_name>): Likewise.
3007 (sse4_1_<code>v2siv2di2<mask_name>): Likewise.
3008 (*sse4_1_<code>v8qiv8hi2<mask_name>_1): New pattern.
3009 (*sse4_1_<code>v8qiv8hi2<mask_name>_2): Likewise.
3010 (*avx2_<code>v8qiv8si2<mask_name>_1): Likewise.
3011 (*avx2_<code>v8qiv8si2<mask_name>_2): Likewise.
3012 (*sse4_1_<code>v4qiv4si2<mask_name>_1): Likewise.
3013 (*sse4_1_<code>v4qiv4si2<mask_name>_2): Likewise.
3014 (*sse4_1_<code>v4hiv4si2<mask_name>_1): Likewise.
3015 (*sse4_1_<code>v4hiv4si2<mask_name>_2): Likewise.
3016 (*avx512f_<code>v8qiv8di2<mask_name>_1): Likewise.
3017 (*avx512f_<code>v8qiv8di2<mask_name>_2): Likewise.
3018 (*avx2_<code>v4qiv4di2<mask_name>_1): Likewise.
3019 (*avx2_<code>v4qiv4di2<mask_name>_2): Likewise.
3020 (*avx2_<code>v4hiv4di2<mask_name>_1): Likewise.
3021 (*avx2_<code>v4hiv4di2<mask_name>_2): Likewise.
3022 (*sse4_1_<code>v2hiv2di2<mask_name>_1): Likewise.
3023 (*sse4_1_<code>v2hiv2di2<mask_name>_2): Likewise.
3024 (*sse4_1_<code>v2siv2di2<mask_name>_1): Likewise.
3025 (*sse4_1_<code>v2siv2di2<mask_name>_2): Likewise.
3026
3027 2018-11-21 H.J. Lu <hongjiu.lu@intel.com>
3028
3029 * read-rtl.c (apply_subst_iterator): Handle define_split and
3030 define_insn_and_split.
3031
3032 2018-11-21 Jakub Jelinek <jakub@redhat.com>
3033
3034 PR rtl-optimization/87817
3035 * config/i386/i386.md (bmi2_bzhi_<mode>3, *bmi2_bzhi_<mode>3,
3036 *bmi2_bzhi_<mode>3_1, *bmi2_bzhi_<mode>3_1_ccz): Use IF_THEN_ELSE
3037 in the pattern to avoid triggering UB when operands[2] is zero.
3038 (tbm_bextri_<mode>): New expander. Renamed the old define_insn to ...
3039 (*tbm_bextri_<mode>): ... this.
3040
3041 2018-11-21 Tom de Vries <tdevries@suse.de>
3042
3043 PR driver/79855
3044 * params.def (HOT_BB_COUNT_FRACTION): Terminate help message with
3045 period.
3046
3047 2018-11-21 Andreas Krebbel <krebbel@linux.ibm.com>
3048
3049 * configure.ac: Add check for Binutils to determine whether vector
3050 load/store alignments hints are being supported.
3051 * config.in: Regenerate.
3052 * configure: Regenerate.
3053 * config/s390/s390.c (print_operand): Support new output
3054 modifier A.
3055 * config/s390/s390.md ("movti"): Append alignment hint output
3056 using the new output modifier 'A'.
3057 * config/s390/vector.md ("mov<mode>", "*vec_tf_to_v1tf")
3058 ("*vec_ti_to_v1ti"): Likewise.
3059
3060 2018-11-20 Martin Sebor <msebor@redhat.com>
3061
3062 * doc/extend.texi (Other Builtins): Add __builtin_has_attribute.
3063
3064 2018-11-20 Jan Hubicka <hubicka@ucw.cz>
3065
3066 PR lto/84044
3067 * ipa-devirt.c (odr_types_equivalent_p): Use operand_equal_p to
3068 compare ENUM values.
3069
3070 2018-11-20 Jakub Jelinek <jakub@redhat.com>
3071
3072 PR tree-optimization/87895
3073 * omp-simd-clone.c (ipa_simd_modify_function_body): When removing
3074 or replacing GIMPLE_RETURN, set EDGE_FALLTHRU on the edge to EXIT.
3075 (simd_clone_adjust): Don't set EDGE_FALLTHRU here. In a loop that
3076 redirects edges to EXIT to edges to incr_bb, iterate while EXIT
3077 has any preds and always use EDGE_PRED (, 0).
3078
3079 2018-11-20 Uros Bizjak <ubizjak@gmail.com>
3080
3081 PR target/88070
3082 * mode-switching.c (create_pre_exit): After reload, always split the
3083 fallthrough edge to the exit block.
3084
3085 2018-11-20 Jan Hubicka <hubicka@ucw.cz>
3086
3087 * ipa-devirt.c (add_type_duplicate): Do not ICE on incomplete enums.
3088 * tree.c (build_array_type_1): Forward declare.
3089 (fld_type_variant_equal_p): Add INNER_TYPE parameter.
3090 (fld_type_variant): Likewise.
3091 (fld_simplified_types): New hash.
3092 (fld_process_array_type): New function.
3093 (fld_incomplete_type_of): Handle array and enumeration types.
3094 (fld_simplified_type): Handle simplification of arrays.
3095 (free_lang_data): Allocate and free simplified types hash.
3096
3097 2018-11-20 Jan Hubicka <hubicka@ucw.cz>
3098
3099 PR lto/87957
3100 * ipa-devirt.c (odr_subtypes_equivalent_p): Report ODR violation
3101 when sybtype already violates ODR.
3102 (get_odr_type): Do not ICE when insert is false and type duplicate
3103 is not registered yet.
3104 (register_odr_type): Be sure to register subtypes first.
3105
3106 2018-11-20 Andreas Krebbel <krebbel@linux.ibm.com>
3107
3108 * config/s390/s390.md ("clztidi2"): Swap the RTX's written to the
3109 DImode parts of the target operand.
3110
3111 2018-11-20 Nathan Sidwell <nathan@acm.org>
3112
3113 PR 87926
3114 * Makefile.in (bitmap.o-warn): Use -Wno-error=array-bounds.
3115
3116 2018-11-20 Jan Hubicka <hubicka@ucw.cz>
3117
3118 PR lto/87997
3119 * tree.c (free_lang_data_in_cgraph): Add argument fld; break out
3120 type checking to...
3121 (free_lang_data) ... here; update call of free_lang_data_in_cgraph.
3122
3123 2018-11-20 Jan Hubicka <hubicka@ucw.cz>
3124
3125 PR ipa/87706
3126 * ipa-fnsummary.c (pass_ipa_fnsummary): Do not remove functions
3127 * ipa.c (possible_inline_candidate_p): Break out from ..
3128 (process_references): ... here ; drop before_inlining_p;
3129 cleanup handling of alises.
3130 (walk_polymorphic_call_targets): Likewise.
3131 (symbol_table::remove_unreachable_nodes): Likewise.
3132 * passes.c (pass_data_ipa_remove_symbols): New structure.
3133 (pass_ipa_remove_symbols): New pass.
3134 (make_pass_ipa_remove_symbols): New function.
3135 * tree-pass.h (make_pass_ipa_remove_symbols): Declare.
3136 * passes.def (pass_ipa_remove_symbols): Schedule after early passes.
3137
3138 2018-11-20 Richard Biener <rguenther@suse.de>
3139
3140 * tree-vect-stmts.c (vectorizable_condition): Do not get
3141 at else_clause vect def for EXTRACT_LAST_REDUCTION. Remove
3142 pointless vect_is_simple_use calls.
3143
3144 2018-11-20 Richard Biener <rguenther@suse.de>
3145
3146 PR tree-optimization/88074
3147 * tree-ssa-dom.c (pass_dominator::execute): Do not walk
3148 backedges.
3149
3150 2018-11-20 Richard Biener <rguenther@suse.de>
3151
3152 PR tree-optimization/88069
3153 * tree-ssa-sccvn.c (visit_phi): Do not value-number to unvisited
3154 virtual PHI arguments.
3155
3156 2018-11-20 Ilya Leoshkevich <iii@linux.ibm.com>
3157
3158 PR target/88083
3159 * config/s390/s390.md: Skip LT(G) peephole when literal pool is
3160 involved.
3161 * rtl.h (contains_constant_pool_address_p): New function.
3162 * rtlanal.c (contains_constant_pool_address_p): Likewise.
3163
3164 2018-11-20 Richard Biener <rguenther@suse.de>
3165
3166 PR middle-end/83215
3167 * alias.c (component_uses_parent_alias_set_from): Remove
3168 alias-set zero and TYPE_TYPELESS_STORAGE case both already
3169 handled in other ways.
3170
3171 2018-11-20 Richard Biener <rguenther@suse.de>
3172
3173 PR tree-optimization/88087
3174 * tree-ssa-pre.c (create_expression_by_pieces): Re-materialize
3175 call fntype.
3176 * tree-ssa-sccvn.c (copy_reference_ops_from_call): Remember
3177 call fntype.
3178
3179 2018-11-20 Richard Biener <rguenther@suse.de>
3180
3181 PR middle-end/88089
3182 * tree-data-ref.c (lambda_matrix_right_hermite): Use abs_hwi.
3183
3184 2018-11-19 Jan Hubicka <hubicka@ucw.cz>
3185
3186 PR lto/87957
3187 * ipa-devirt.c (free_enum_values): Do not ICE on ODR vilations.
3188
3189 2018-11-19 Sandra Loosemore <sandra@codesourcery.com>
3190
3191 PR driver/50250
3192 * doc/invoke.texi (Link Options): Mention shared libraries
3193 in documentation for the -l option. Simplify discussion and
3194 point to the system linker documentation for details.
3195
3196 2018-11-19 Peter Bergner <bergner@linux.ibm.com>
3197
3198 PR rtl-optimization/88033
3199 * ira-lives.c (non_conflicting_reg_copy_p): Skip copies from a register
3200 to itself. Use HARD_REGISTER_NUM_P.
3201
3202 2018-11-19 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
3203
3204 * tree-vect-loop.c (vect_transform_loop): Disable further unrolling
3205 of the loop if vf is non-constant.
3206
3207 2018-11-19 David Malcolm <dmalcolm@redhat.com>
3208
3209 PR tree-optimization/87025
3210 * dumpfile.c (dump_context::begin_scope): Call end_any_optinfo
3211 immediately after creating the scope optinfo.
3212 (selftest::test_pr87025): New function.
3213 (selftest::dumpfile_c_tests): Call it.
3214 * optinfo-emit-json.cc (optrecord_json_writer::pop_scope): Assert
3215 that we're not popping the top-level records array.
3216 * optinfo.cc (optinfo::handle_dump_file_kind): Assert that we're
3217 not changing the kind of a "scope" optinfo.
3218
3219 2018-11-19 David Malcolm <dmalcolm@redhat.com>
3220
3221 PR tree-optimization/87025
3222 * dump-context.h: Include "optinfo.h".
3223 (class optrecord_json_writer): New forward decl.
3224 (dump_context::forcibly_enable_optinfo_p): Delete.
3225 (dump_context::optinfo_enabled_p): New member function.
3226 (dump_context::optimization_records_enabled_p): New member
3227 function.
3228 (dump_context::set_json_writer): New member function.
3229 (dump_context::emit_optinfo): New member function.
3230 (dump_context::m_forcibly_enable_optinfo): Delete.
3231 (dump_context::m_json_writer): New member data.
3232 * dumpfile.c (dump_context::set_json_writer): New member function.
3233 (dump_context::finish_any_json_writer): New member function.
3234 (dump_context::end_scope): Replace call to
3235 optimization_records_maybe_pop_dump_scope with call to
3236 m_json_writer->pop_scope.
3237 (dump_context::optinfo_enabled_p): New member function.
3238 (dump_context::end_any_optinfo): Replace call to optinfo::emit with call
3239 to dump_context::emit_optinfo.
3240 (dump_context::emit_optinfo): New member function.
3241 (temp_dump_context::temp_dump_context): Replace
3242 m_forcibly_enable_optinfo with call to set_json_writer.
3243 (temp_dump_context::~temp_dump_context): Clean up any json writer.
3244 * optinfo-emit-json.cc (class optrecord_json_writer): Move to
3245 optinfo-emit-json.h
3246 (the_json_writer): Delete.
3247 (optimization_records_start): Delete.
3248 (optimization_records_finish): Delete.
3249 (optimization_records_enabled_p): Delete, in favor of
3250 dump_context::optimization_records_enabled_p.
3251 (optimization_records_maybe_record_optinfo): Delete.
3252 (optimization_records_maybe_pop_dump_scope): Delete.
3253 * optinfo-emit-json.h: Include "json.h". Delete forward
3254 decl of opt_pass.
3255 (optimization_records_start): Delete.
3256 (optimization_records_finish): Delete.
3257 (optimization_records_enabled_p): Delete.
3258 (optimization_records_maybe_record_optinfo): Delete.
3259 (optimization_records_maybe_pop_dump_scope): Delete.
3260 (class optrecord_json_writer): Move here from
3261 optinfo-emit-json.cc.
3262 * optinfo.cc (optinfo::emit_for_opt_problem): Replace call
3263 to optinfo::emit with call to dump_context::emit_optinfo.
3264 (optinfo::emit): Delete, in favor of dump_context::emit_optinfo.
3265 (optinfo_enabled_p): Delete, in favor of
3266 dump_context::optinfo_enabled_p.
3267 (optinfo_wants_inlining_info_p): Update for conversion o
3268 optimization_records_enabled_p to a member function of
3269 dump_context.
3270 * optinfo.h (optinfo_enabled_p): Delete, in favor of
3271 dump_context::optinfo_enabled_p.
3272 (optinfo::emit): Delete, in favor of dump_context::emit_optinfo.
3273 * toplev.c: Include "dump-context.h".
3274 (compile_file): Replace call to optimization_records_finish with
3275 dump_context::finish_any_json_writer.
3276 (do_compile): Replace call to optimization_records_start with
3277 conditionally creating a optrecord_json_writer for the
3278 dump_context.
3279
3280 2018-11-19 Jakub Jelinek <jakub@redhat.com>
3281
3282 PR tree-optimization/88071
3283 * tree-vect-loop.c (vectorize_fold_left_reduction): Pass true instead
3284 of false as last argument to gsi_remove.
3285 * tree-vect-stmts.c (vect_finish_replace_stmt): Pass true instead of
3286 false as last argument to gsi_replace.
3287
3288 PR debug/87039
3289 * omp-expand.c: Don't include debug.h.
3290 (adjust_context_and_scope): Add REGION argument. Find DECL_CONTEXT
3291 from innermost outer parallel, task, teams or target that has a
3292 child_fn set, or, if there is no such outer region, use
3293 current_function_decl. Do the DECL_CONTEXT adjustment regardless of
3294 whether a suitable BLOCK is found or not.
3295 (expand_parallel_call, expand_teams_call): Don't call
3296 adjust_context_and_scope here.
3297 (grid_expand_target_grid_body): Revert 2017-01-25 changes.
3298 (expand_omp_taskreg, expand_omp_target): Likewise. Call
3299 adjust_context_and_scope.
3300 * dwarf2out.c (dwarf2out_early_global_decl): For
3301 decl_function_context recurse instead of calling dwarf2out_decl.
3302
3303 2018-11-20 Eric Botcazou <ebotcazou@adacore.com>
3304
3305 PR rtl-optimization/85925
3306 * rtl.h (word_register_operation_p): New predicate.
3307 * combine.c (record_dead_and_set_regs_1): Only apply specific handling
3308 for WORD_REGISTER_OPERATIONS targets to word_register_operation_p RTX.
3309 * rtlanal.c (nonzero_bits1): Likewise. Adjust couple of comments.
3310 (num_sign_bit_copies1): Likewise.
3311
3312 2018-11-19 Richard Biener <rguenther@suse.de>
3313
3314 PR lto/87229
3315 * tree.c (free_lang_data_in_one_sizepos): Free non-gimple-val
3316 sizepos values.
3317
3318 2018-11-19 Eric Botcazou <ebotcazou@adacore.com>
3319
3320 * compare-elim.c (struct comparison): Add not_in_a field.
3321 (is_not): New static function.
3322 (strip_not): Likewise.
3323 (conforming_compare): Handle a NOT in the first operand.
3324 (can_eliminate_compare): Likewise.
3325 (find_comparison_dom_walker::before_dom_children): Likewise.
3326 (try_eliminate_compare): Likewise.
3327 * config/visium/visium.md (negsi2_insn_set_carry): Turn into...
3328 (neg<mode>2_insn_set_carry): ...this and add missing NEG operation.
3329
3330 2018-11-19 Jonathan Wakely <jwakely@redhat.com>
3331
3332 * doc/extend.texi (Common Type Attributes): Fix typos.
3333
3334 2018-11-19 Martin Liska <mliska@suse.cz>
3335
3336 PR gcov-profile/88045
3337 * coverage.c (coverage_begin_function): Add assert.
3338
3339 2018-11-18 Sandra Loosemore <sandra@codesourcery.com>
3340
3341 PR other/40498
3342 * doc/extend.texi (Common Function Attributes): Document that
3343 no_instrument_function applies to -p and -pg, too.
3344 * doc/invoke.texi (Instrumentation Options): Add cross-references
3345 to docs for -p, -pg, and -finstrument-functions.
3346
3347 2018-11-18 Alan Modra <amodra@gmail.com>
3348
3349 * config/gnu-user.h (GNU_USER_TARGET_CRTI): Define.
3350 (GNU_USER_TARGET_STARTFILE_SPEC): Use it here.
3351 (GNU_USER_TARGET_CRTN): Define.
3352 (GNU_USER_TARGET_ENDFILE_SPEC): Use it here.
3353 (GNU_USER_TARGET_LINK_GCC_C_SEQUENCE_SPEC): Define.
3354
3355 2018-11-18 Alan Modra <amodra@gmail.com>
3356
3357 * config/gnu-user.h (GNU_USER_TARGET_STARTFILE_SPEC): Delete
3358 !HAVE_LD_PIE variant.
3359 (GNU_USER_TARGET_ENDFILE_SPEC): Likewise.
3360
3361 2018-11-17 Nick Clifton <nickc@redhat.com>
3362 Sandra Loosemore <sandra@codesourcery.com>
3363
3364 PR driver/31357
3365 * doc/invoke.texi (Overall Options): Document that --help and
3366 --help=<value> options cannot be combined.
3367
3368 2018-11-17 Jim Wilson <jimw@sifive.com>
3369
3370 * config/riscv/riscv.c (epilogue_cfa_sp_offset): New.
3371 (riscv_restore_reg): If restoring HARD_FRAME_POINTER_REGNUM, and
3372 epilogue_cfa_sp_offset set, then add REG_CFA_DEF_CFA regnote.
3373 (riscv_expand_epilogue): Initialize epilogue_cfa_sp_offset. Set it
3374 to step2 if frame_pointer_needed and step1 is 0.
3375
3376 2018-11-17 Sandra Loosemore <sandra@codesourcery.com>
3377
3378 PR c++/4225
3379 * doc/cpp.texi (System Headers): Add note about implicit
3380 extern "C" block on targets that define SYSTEM_IMPLICIT_EXTERN_C.
3381
3382 2018-11-17 Sandra Loosemore <sandra@codesourcery.com>
3383
3384 PR c++/4025
3385 * doc/invoke.texi (C++ Dialect Options): Clarify usage of
3386 -fno-implicit-templates.
3387
3388 2018-11-17 Jakub Jelinek <jakub@redhat.com>
3389
3390 PR tree-optimization/87546
3391 * tree-vect-patterns.c (vect_look_through_possible_promotion): Add
3392 min_precision variable, initially set it to orig_precision, only does
3393 something if op_type's precision is <= min_precision and update
3394 min_precision whenever calling set_op.
3395
3396 2018-11-16 Jan Hubicka <hubicka@ucw.cz>
3397
3398 PR ipa/87957
3399 * ipa-devirt.c (warn_odr): Look for main variant to get TYPE_DECL.
3400
3401 2018-11-16 Sandra Loosemore <sandra@codesourcery.com>
3402
3403 * doc/invoke.texi (Option Summary): Fix whitespace and line
3404 breaks in @gccoptlist environments.
3405 (Warning Options): Likewise.
3406 (Optimize Options): Likewise.
3407 (PowerPC SPE Options): Likewise.
3408 (RS/6000 and PowerPC Options): Likewise.
3409
3410 2018-11-16 Jeff Law <law@redhat.com>
3411
3412 * config/mn10300/mn10300.md (adddi3_degenerate): Remove bogus
3413 gcc_assert.
3414
3415 2018-11-16 Sandra Loosemore <sandra@codesourcery.com>
3416
3417 PR middle-end/23197
3418 * doc/invoke.texi (Optimize Options): Update options enabled by
3419 fprofile-generate, -fprofile-use, and -fauto-profile.
3420
3421 2018-11-16 Jozef Lawrynowicz <jozef.l@mittosystems.com>
3422
3423 PR target/87927
3424 * target-def.h: Initialize TARGET_ASM_{,UN}ALIGNED_P{S,D,T}I_OP.
3425 Add them to the TARGET_ASM_{,UN}ALIGNED_INT_OP structs.
3426 * target.def: Enumerate TARGET_ASM_{,UN}ALIGNED_P{S,D,T}I_OP in
3427 the byte_op hook.
3428 * target.h: Add psi, pdi, pti to struct asm_int_op definition.
3429 * targhooks.c (default_print_patchable_function_entry): Assert
3430 asm_int_op does not return a NULL string.
3431 * varasm.c (integer_asm_op): Return the op for a partial int type
3432 when the requested size does not correspond to an integer type.
3433 * config/msp430/msp430.c: Initialize TARGET_ASM_{,UN}ALIGNED_PSI_OP.
3434 * doc/tm.texi: Regenerate.
3435
3436 2018-11-12 Jason Merrill <jason@redhat.com>
3437
3438 * gimplify.c (gimplify_case_label_expr): Handle hot/cold attributes.
3439
3440 2018-11-16 Michael Meissner <meissner@linux.ibm.com>
3441
3442 * config/rs6000/constraints.md (wF constraint): Remove power9
3443 fusion documentation. Just document wF's use for power8 fusion.
3444 * config/rs6000/predicates.md (p9_fusion_reg_operand): Delete.
3445 (fusion_gpr_addis): Delete power9 fusion support. Change power8
3446 fusion support to require the upper 12 bits to be all 0's or all
3447 1's.
3448 (fusion_gpr_mem_load): Add comment.
3449 (fusion_addis_mem_combo_load): Remove power9 fusion support.
3450 (fusion_addis_mem_combo_store): Delete.
3451 (fusion_offsettable_mem_operand): Delete.
3452 * config/rs6000/rs6000-cpus.def (ISA_2_7_MASKS_SERVER): Do not set
3453 power8 fusion here.
3454 (ISA_3_0_MASKS_SERVER): Delete power9 fusion.
3455 (POWERPC_MASKS): Delete power9 fusion.
3456 * config/rs6000/rs6000-protos.h (emit_fusion_load_store): Delete.
3457 (fusion_p9_p): Delete.
3458 (expand_fusion_p9_load): Delete.
3459 (expand_fusion_p9_store): Delete.
3460 (emit_fusion_p9_load): Delete.
3461 (emit_fusion_p9_store): Delete.
3462 * config/rs6000/rs6000.c (rs6000_debug_reg_global): Delete power9
3463 fusion support.
3464 (rs6000_option_override_internal): Set power8 fusion based on
3465 whether we are tuning for power8. Delete power9 fusion support.
3466 (rs6000_opt_masks): Delete -mpower9-fusion switch.
3467 (emit_fusion_load): Rename emit_fusion_load_store to
3468 emit_fusion_load, and drop fusion store support. Update callers.
3469 (emit_fusion_load_store): Likewise.
3470 (emit_fusion_gpr_load): Likewise.
3471 (fusion_p9_p): Delete.
3472 (expand_fusion_p9_load): Delete.
3473 (expand_fusion_p9_store): Delete.
3474 (emit_fusion_p9_load): Delete.
3475 (emit_fusion_p9_store): Delete.
3476 * config/rs6000/rs6000.md (UNSPEC_FUSION_P9): Delete.
3477 (GPR_FUSION): Delete.
3478 (FPR_FUSION): Delete.
3479 (power9 fusion peephole2s): Delete.
3480 (fusion_gpr_<P:mode>_<GPR_FUSION:mode>_load): Delete.
3481 (fusion_gpr_<P:mode>_<GPR_FUSION:mode>_store): Delete.
3482 (fusion_vsx_<P:mode>_<FPR_FUSION:mode>_load): Delete.
3483 (fusion_vsx_<P:mode>_<FPR_FUSION:mode>_store): Delete.
3484 (fusion_p9_<mode>_constant): Delete.
3485 * config/rs6000/rs6000.opt (-mpower9-fusion): Delete undocumented
3486 power9 fusion switch.
3487 * doc/md.texi (PowerPC constraints): Update wF constraint
3488 documentation for power8 fusion only.
3489
3490 2018-11-16 Jakub Jelinek <jakub@redhat.com>
3491
3492 PR rtl-optimization/87475
3493 * cfgrtl.c (patch_jump_insn): Allow redirection failure for
3494 CROSSING_JUMP_P insns.
3495 (cfg_layout_redirect_edge_and_branch): Don't ICE if ret is NULL.
3496
3497 2018-11-16 Uros Bizjak <ubizjak@gmail.com>
3498
3499 PR target/88051
3500 * config/i386/i386.md (floatunsdidf2): Allow only 64bit AVX512F targets.
3501 * config/i386/sse.md (UNSPEC_MOVDI_TO_SSE): New UNSPEC.
3502 (movdi_to_sse): Rewrite using UNSPEC_MOVDI_TO_SSE unspec.
3503
3504 2018-11-16 Jakub Jelinek <jakub@redhat.com>
3505
3506 PR middle-end/88032
3507 * optabs.c (expand_binop): For op0_mode use GET_MODE (op0), unless it
3508 is VOIDmode, in which case use int_mode. Similarly for op1_mode.
3509
3510 2018-11-16 Eric Botcazou <ebotcazou@adacore.com>
3511
3512 * tree-switch-conversion.h (switch_decision_tree::emit_case_nodes): Add
3513 location_t parameter.
3514 (switch_decision_tree::emit_cmp_and_jump_insns): Likewise.
3515 (switch_decision_tree::do_jump_if_equal): Likewise.
3516 * tree-switch-conversion.c (switch_decision_tree::emit): Pass location
3517 of switch statement to emit_case_nodes.
3518 (switch_decision_tree::emit_cmp_and_jump_insns): Add LOC parameter and
3519 set it on the newly built GIMPLE comparison statement.
3520 (switch_decision_tree::do_jump_if_equal): Likewise.
3521 (switch_decision_tree::emit_case_nodes): Add LOC parameter and pass it
3522 in calls to do_jump_if_equal as well as recursive calls.
3523
3524 2018-11-16 Andi Kleen <ak@linux.intel.com>
3525
3526 * config/i386/i386.md: Allow memory operands to ptwrite.
3527
3528 2018-11-16 Michael Matz <matz@suse.de>
3529
3530 * system.h (PRsa): New macro.
3531 (SIZE_AMOUNT): Cast number to uint64_t.
3532 * alloc-pool.h (pool_usage::dump): Don't use %zu but PRsa.
3533 (pool_usage::dump_footer): Likewise and also use PRIu64.
3534 * bitmap.h (bitmap_usage::dump): Likewise.
3535 * ggc-common.c (ggc_usage::dump): Likewise.
3536 * ggc-page.c (ggc_print_statistics): Likewise.
3537 * input.c (dump_line_table_statistics): Likewise.
3538 * mem-stats.h (mem_usage::dump): Likewise.
3539 (mem_usage::dump_footer): Likewise.
3540 * rtl.c (dump_rtx_statistics): Likewise.
3541 * tree-cfg.c (dump_cfg_stats): Likewise.
3542 * tree-dfa.c (dump_dfa_stats): Likewise.
3543 * tree-phinodes.c (phinodes_print_statistics): Likewise.
3544 * tree-ssanames (ssanames_print_statistics): Likewise.
3545 * vec.c (vec_usage::dump): Likewise.
3546 (vec_usage::dump_footer): Likewise.
3547
3548 2018-11-16 Richard Biener <rguenther@suse.de>
3549
3550 PR tree-optimization/88011
3551 * tree-vrp.c (extract_range_from_binary_expr): Fix error in
3552 replacing set_value_range_to_undefined and
3553 set_value_range_to_varying with method calls.
3554
3555 2018-11-16 Ilya Leoshkevich <iii@linux.ibm.com>
3556
3557 * config/s390/s390.md
3558 (*r<noxa>sbg_<mode>_srl_bitmask): Do not delegate arithmetic to
3559 assembler.
3560 (*r<noxa>sbg_<mode>_sll): Likewise.
3561 (*r<noxa>sbg_<mode>_srl): Likewise.
3562 (*r<noxa>sbg_sidi_srl): New pattern.
3563
3564 2018-11-16 Jerome Lambourg <lambourg@adacore.com>
3565
3566 * config/vxworks.h (TARGET_VXWORKS_HAVE_CTORS_DTORS): New macro.
3567 Default to TARGET_VXWORKS_RTP.
3568 (SUPPORTS_INIT_PRIORITY): Use TARGET_VXWORKS_HAVE_CTORS_DTORS instead
3569 of TARGET_VXWORKS_RTP.
3570 * config/vxworks.c: Use TARGET_VXWORKS_HAVE_CTORS_DTORS instead
3571 of TARGET_VXWORKS_RTP to set targetm.have_ctors_dtors.
3572
3573 2018-11-15 Sandra Loosemore <sandra@codesourcery.com>
3574
3575 PR c++/25759
3576 * doc/extend.texi (Common Type Attributes): Make it explicit
3577 that attribute "packed" can apply to C++ classes.
3578
3579 2018-11-15 Martin Sebor <msebor@redhat.com>
3580
3581 PR c++/87541
3582 PR c++/87542
3583 * tree.c (type_argument_type): New function.
3584 * tree.h (type_argument_type): Declare it.
3585 * gcc/doc/extend.texi (alloc_align): Update and clarify.
3586 (alloc_size, nonnull, sentinel): Same.
3587
3588 2018-11-15 Andrew Stubbs <ams@codesourcery.com>
3589 Kwok Cheung Yeung <kcy@codesourcery.com>
3590
3591 * tree-vect-stmts.c (vectorizable_store): Don't ICE when
3592 int_mode_for_size fails.
3593 (vectorizable_load): Likewise.
3594
3595 2018-11-15 David Malcolm <dmalcolm@redhat.com>
3596
3597 * doc/ux.texi (Group logically-related diagnostics): Move
3598 discussion of auto_diagnostic_group into this new subsection.
3599 Give an example of where this grouping is used.
3600
3601 2018-11-15 David Malcolm <dmalcolm@redhat.com>
3602
3603 PR other/19165
3604 * Makefile.in (OBJS): Move json.o to...
3605 (OBJS-libcommon): ...here and add diagnostic-format-json.o.
3606 * common.opt (fdiagnostics-format=): New option.
3607 (diagnostics_output_format): New enum.
3608 * diagnostic-format-json.cc: New file.
3609 * diagnostic.c (default_diagnostic_final_cb): New function, taken
3610 from start of diagnostic_finish.
3611 (diagnostic_initialize): Initialize final_cb to
3612 default_diagnostic_final_cb.
3613 (diagnostic_finish): Move "being treated as errors" messages to
3614 default_diagnostic_final_cb. Call any final_cb.
3615 (default_diagnostic_finalizer): Add diagnostic_t param.
3616 (diagnostic_report_diagnostic): Pass "orig_diag_kind" to
3617 diagnostic_finalizer callback.
3618 * diagnostic.h (enum diagnostics_output_format): New enum.
3619 (diagnostic_finalizer_fn): Reimplement, adding diagnostic_t param.
3620 (struct diagnostic_context): Add "final_cb".
3621 (default_diagnostic_finalizer): Add diagnostic_t param.
3622 (diagnostic_output_format_init): New decl.
3623 * doc/invoke.texi (-fdiagnostics-format): New option.
3624 * dwarf2out.c (gen_producer_string): Ignore
3625 OPT_fdiagnostics_format_.
3626 * gcc.c (driver_handle_option): Handle OPT_fdiagnostics_format_.
3627 * lto-wrapper.c (append_diag_options): Ignore it.
3628 * opts.c (common_handle_option): Handle it.
3629
3630 2018-11-15 David Malcolm <dmalcolm@redhat.com>
3631
3632 PR tree-optimization/88015
3633 * graphite-isl-ast-to-gimple.c
3634 (translate_isl_ast_to_gimple::scop_to_isl_ast): Add missing check
3635 for dump_enabled_p.
3636 * graphite-sese-to-poly.c (build_poly_scop): Likewise.
3637
3638 2018-11-15 Richard Biener <rguenther@suse.de>
3639
3640 PR middle-end/88029
3641 * gimple.c (gimple_call_flags): Union flags from decl, type
3642 and call fntype.
3643 * trans-mem.c (is_tm_pure_call): Simplify.
3644
3645 2018-11-15 Richard Biener <rguenther@suse.de>
3646
3647 PR tree-optimization/88031
3648 * tree-vect-loop.c (vectorizable_reduction): Move check
3649 for multiple types earlier so we get the expected dump.
3650 Simplify calls to vectorizable_condition.
3651 * tree-vect-stmts.h (vectorizable_condition): Update prototype.
3652 * tree-vect-stmts.c (vectorizable_condition): Instead of
3653 reduc_def and reduc_index take just a flag. Simplify
3654 code-generation now that we can rely on the defs being set up.
3655 (vectorizable_comparison): Remove unused argument.
3656
3657 2018-11-15 Richard Biener <rguenther@suse.de>
3658
3659 PR tree-optimization/88030
3660 * tree-complex.c (need_eh_cleanup): New global.
3661 (update_complex_assignment): Mark blocks that need EH update.
3662 (expand_complex_comparison): Likewise.
3663 (tree_lower_complex): Allocate and deallocate need_eh_cleanup,
3664 perform EH cleanup and schedule CFG cleanup if that did anything.
3665
3666 2018-11-15 Jakub Jelinek <jakub@redhat.com>
3667
3668 PR rtl-optimization/88018
3669 * cfgrtl.c (fixup_abnormal_edges): Guard moving insns to fallthru edge
3670 on the presence of fallthru edge, rather than if it is a USE or not.
3671
3672 2018-11-15 Richard Biener <rguenther@suse.de>
3673
3674 PR middle-end/87917
3675 * tree-data-ref.c (analyze_miv_subscript): Guard calls to
3676 analyze_subscript_affine_affine properly.
3677
3678 2018-11-15 Xianmiao Qu <xianmiao_qu@c-sky.com>
3679
3680 * config/csky/csky-linux-elf.h (LINUX_DYNAMIC_LINKER): Remove.
3681 (GLIBC_DYNAMIC_LINKER): Define.
3682 (LINUX_TARGET_LINK_SPEC): Update the dynamic linker's name.
3683
3684 2018-11-15 Bin Cheng <bin.cheng@linux.alibaba.com>
3685
3686 PR tree-optimization/84648
3687 * tree-ssa-loop-niter.c (adjust_cond_for_loop_until_wrap): New.
3688 (number_of_iterations_cond): Adjust exit cond for loop-until-wrap case
3689 by calling adjust_cond_for_loop_until_wrap.
3690
3691 2018-11-15 Sandra Loosemore <sandra@codesourcery.com>
3692
3693 PR other/56334
3694 * doc/extend.texi (Common Function Attributes): Clarify linker
3695 restrictions on "aligned" attribute.
3696 (Common Variable Attributes): Likewise. Mention that linker
3697 restrictions don't apply to stack-allocated variables.
3698
3699 2018-11-15 Joern Rennecke <joern.rennecke@riscy-ip.com>
3700
3701 * gensupport.c (add_predicate_code): Properly handle ZERO_EXTRACT
3702 as an lvalue.
3703
3704 2018-11-14 Sandra Loosemore <sandra@codesourcery.com>
3705
3706 PR lto/55102
3707 PR lto/56700
3708 * doc/invoke.texi (Optimize Options): Remove bad example about
3709 interaction between -flto and -O. Replace it with a note that
3710 you need to compile with -O and not just link. Copy-edit -flto
3711 discussion to reduce verbiage and improve flow.
3712
3713 2018-11-14 Sandra Loosemore <sandra@codesourcery.com>
3714
3715 PR middle-end/59658
3716 * doc/invoke.texi (Optimize Options): Clarify that -O0 and -Og
3717 also suppress many optimizations. Alphabetize option lists for
3718 -O1, -O2, and -Os. Add list of options disabled with -Og, and
3719 correct documentation for those options to say that.
3720 * opts.c (default_options_table): Sort table by level and option
3721 name, to make it easier to correlate to the manual.
3722
3723 2018-11-14 Uros Bizjak <ubizjak@gmail.com>
3724
3725 * config/i386/i386.c (ix86_print_operand_address_as): Simplify
3726 printing of the names of segment registers.
3727
3728 2018-11-14 Nathan Sidwell <nathan@acm.org>
3729
3730 PR debug/88006
3731 PR debug/87462
3732 * dwarf2out.c (dwarf2out_finish): Apply resolve_addr to comdat
3733 type list.
3734
3735 2018-11-14 David Malcolm <dmalcolm@redhat.com>
3736
3737 * Makefile.in (CFLAGS-optinfo-emit-json.o): Add $(ZLIBINC).
3738
3739 2018-11-14 Jakub Jelinek <jakub@redhat.com>
3740
3741 P1236R1 - Signed integers are two's complement
3742 * doc/invoke.texi (Wshift-overflow): Adjust documentation for c++2a.
3743
3744 PR bootstrap/86739
3745 * hash-map.h (hash_map::iterator::reference_pair): New class.
3746 (hash_map::iterator::operator*): Return it rather than std::pair.
3747
3748 2018-11-14 Jeff Law <law@redhat.com>
3749
3750 * optabs.c (expand_binop): Pass INT_MODE to operand_subword_force
3751 iff the operand is a constant.
3752
3753 2018-11-14 Aldy Hernandez <aldyh@redhat.com>
3754
3755 * gimple-ssa-evrp-analyze.c
3756 (evrp_range_analyzer::record_ranges_from_incoming_edge): Rename
3757 ignore_equivs_equal_p to equal_p.
3758 * ipa-cp.c (meet_with_1): Use equal_p instead of
3759 ignore_equivs_equal_p.
3760 * ipa-prop.c (ipa_vr_ggc_hash_traits::equal): Same.
3761 * tree-vrp.c (value_range::ignore_equivs_equal_p): Remove.
3762 (value_range::operator==): Remove.
3763 (value_range::operator!=): Remove.
3764 (vrp_prop::visit_stmt): Use equal_p.
3765 * tree-vrp.h (value_range): Remove operator==, operator!=,
3766 ignore_equivs_equal_p.
3767 * vr-values.c (update_value_range): Use equal_p.
3768
3769 2018-11-14 Michael Matz <matz@suse.de>
3770
3771 PR middle-end/86575
3772 * gimplify.c (collect_fallthrough_labels): Add new argument,
3773 return location via that, don't modify statements.
3774 (warn_implicit_fallthrough_r): Adjust call, don't use
3775 statement location directly.
3776
3777 2018-11-14 Richard Biener <rguenther@suse.de>
3778
3779 PR middle-end/87985
3780 * tree-data-ref.c (split_constant_offset): Add wrapper
3781 allocating a cache hash-map.
3782 (split_constant_offset_1): Cache results of expanding
3783 expressions from SSA def stmts.
3784
3785 2018-11-14 Richard Biener <rguenther@suse.de>
3786
3787 PR middle-end/88021
3788 * tree-data-ref.c (lambda_matrix_row_add): Change const1 argument
3789 to lambda_int.
3790 (lambda_vector_mult_const): Likewise.
3791 (lambda_matrix_right_hermite): Use lambda_int temporaries.
3792
3793 2018-11-14 Wilco Dijkstra <wdijkstr@arm.com>
3794 Jackson Woodruff <jackson.woodruff@arm.com>
3795
3796 PR 71026/tree-optimization
3797 * match.pd: Simplify floating point comparisons.
3798
3799 2018-11-14 Jakub Jelinek <jakub@redhat.com>
3800
3801 PR rtl-optimization/87817
3802 * config/i386/i386.c (ix86_fold_builtin): For _bzhi_u{32,64} if
3803 last argument has low 8 bits clear, fold to 0.
3804
3805 2018-11-14 Iain Sandoe <iain@sandoe.co.uk>
3806
3807 * tree-vect-data-refs.c (vect_can_force_dr_alignment_p): Cast
3808 MAX_OFILE_ALIGNMENT as needed.
3809
3810 2018-11-14 Richard Biener <rguenther@suse.de>
3811
3812 PR tree-optimization/88019
3813 * graphite-isl-ast-to-gimple.c (ternary_op_to_tree): Rewrite
3814 COND_EXPR arguments to non-trapping overflow.
3815
3816 2018-11-14 Claudiu Zissulescu <claziss@synopsys.com>
3817
3818 * config/arc/arc.h (reg_class): Reorder registers classes, remove
3819 unused register classes.
3820 (REG_CLASS_NAMES): Likewise.
3821 (REG_CLASS_CONTENTS): Likewise.
3822 (FIXED_REGISTERS): Make lp_count fixed.
3823 (BASE_REG_CLASS): Remove ACC16_BASE_REGS reference.
3824 (PROGRAM_COUNTER_REGNO): Remove.
3825 * config/arc/arc.c (arc_conditional_register_usage): Remove unused
3826 register classes, use constants for register numbers, remove
3827 reg_class_contents references.
3828 (arc_process_double_reg_moves): Add asserts.
3829 (arc_secondary_reload): Remove LPCOUNT_REG reference, use
3830 lra_in_progress predicate.
3831 (arc_init_reg_tables): Remove unused register classes.
3832 (arc_register_move_cost): Likewise.
3833 (arc_preferred_reload_class): Likewise.
3834 (hwloop_optimize): Update rtx patterns involving lp_count register.
3835 (arc_return_address_register): Rename ILINK1, INLINK2 regnums macros.
3836 * config/arc/constraints.md ("c"): Choose between GENERAL_REGS and
3837 CHEAP_CORE_REGS. Former one will be used for LRA.
3838 ("Rac"): Choose between GENERAL_REGS and ALL_CORE_REGS. Former
3839 one will be used for LRA.
3840 ("w"): Choose between GENERAL_REGS and WRITABLE_CORE_REGS. Former
3841 one will be used for LRA.
3842 ("W"): Choose between GENERAL_REGS and MPY_WRITABLE_CORE_REGS.
3843 Former one will be used for LRA.
3844 ("f"): Delete constraint.
3845 ("k"): Likewise.
3846 ("e"): Likewise.
3847 ("l"): Change it from register constraint to constraint.
3848 * config/arc/arc.md (movqi_insn): Remove unsed lp_count constraints.
3849 (movhi_insn): Likewise.
3850 (movsi_insn): Update pattern.
3851 (arc_lp): Likewise.
3852 (dbnz): Likewise.
3853 (stack_tie): Remove 'b' constraint letter.
3854 (R4_REG): Define.
3855 (R9_REG, R15_REG, R16_REG, R25_REG): Likewise.
3856 (R32_REG, R40_REG, R41_REG, R42_REG, R43_REG, R44_REG): Likewise.
3857 (R57_REG, R59_REG, PCL_REG): Likewise.
3858 (ILINK1_REGNUM): Renamed to ILINK1_REG.
3859 (ILINK2_REGNUM): Renamed to ILINK2_REG.
3860 (Rgp): Remove.
3861 (SP_REGS): Likewise.
3862 (Rcw): Remove unused reg classes.
3863 * config/arc/predicates.md (dest_reg_operand): Just default on
3864 register_operand predicate.
3865 (mpy_dest_reg_operand): Likewise.
3866 (move_dest_operand): Use macros instead of constants.
3867 * config/arc/arc.opt (mlra): Switch to lra as default.
3868
3869 2018-11-14 Richard Biener <rguenther@suse.de>
3870
3871 PR tree-optimization/87974
3872 * tree-vect-loop.c (vectorizable_reduction): When computing
3873 the vectorized reduction PHI vector type ignore constant
3874 and external defs.
3875
3876 2018-11-14 Jakub Jelinek <jakub@redhat.com>
3877
3878 PR tree-optimization/87977
3879 * tree-ssa-math-opts.c (optimize_recip_sqrt): Don't reuse division
3880 stmt, build a new one and replace the old one with it. Formatting fix.
3881 Call release_ssa_name (x) if !has_other_use and !delete_div.
3882 (pass_cse_reciprocals::execute): Before calling optimize_recip_sqrt
3883 verify lhs of stmt is still def.
3884
3885 2018-11-13 Peter Bergner <bergner@linux.ibm.com>
3886
3887 PR rtl-optimization/87507
3888 * lower-subreg.c (operand_for_swap_move_operator): New function.
3889 (simple_move): Strip simple operators.
3890 (find_pseudo_copy): Likewise.
3891 (resolve_operand_for_swap_move_operator): New function.
3892 (resolve_simple_move): Strip simple operators and swap operands.
3893
3894 2018-11-13 Jakub Jelinek <jakub@redhat.com>
3895
3896 PR tree-optimization/87898
3897 * omp-simd-clone.c (ipa_simd_modify_stmt_ops): Formatting fix.
3898 (ipa_simd_modify_function_body): Remove debug stmts where the first
3899 argument was changed into a non-decl.
3900
3901 2018-11-13 Peter Bergner <bergner@linux.ibm.com>
3902
3903 PR rtl-optimization/87899
3904 * lra-lives.c (start_living): Update white space in comment.
3905 (enum point_type): New.
3906 (sparseset_contains_pseudos_p): New function.
3907 (update_pseudo_point): Likewise.
3908 (make_hard_regno_live): Use HARD_REGISTER_NUM_P macro.
3909 (make_hard_regno_dead): Likewise. Remove ignore_reg_for_conflicts
3910 handling. Move early exit after adding conflicts.
3911 (mark_pseudo_live): Use HARD_REGISTER_NUM_P macro. Add early exit
3912 if regno is already live. Remove all handling of program points.
3913 (mark_pseudo_dead): Use HARD_REGISTER_NUM_P macro. Add early exit
3914 after adding conflicts. Remove all handling of program points and
3915 ignore_reg_for_conflicts.
3916 (mark_regno_live): Use HARD_REGISTER_NUM_P macro. Remove return value
3917 and do not guard call to mark_pseudo_live.
3918 (mark_regno_dead): Use HARD_REGISTER_NUM_P macro. Remove return value
3919 and do not guard call to mark_pseudo_dead.
3920 (check_pseudos_live_through_calls): Use HARD_REGISTER_NUM_P macro.
3921 (process_bb_lives): Use HARD_REGISTER_NUM_P and HARD_REGISTER_P macros.
3922 Use new function update_pseudo_point. Handle register copies by
3923 removing the source register from the live set. Handle INOUT operands.
3924 Update to the next program point using the unused_set, dead_set and
3925 start_dying sets.
3926 (lra_create_live_ranges_1): Use HARD_REGISTER_NUM_P macro.
3927
3928 2018-11-13 David Malcolm <dmalcolm@redhat.com>
3929
3930 * builtins.c: Replace "source_location" with "location_t".
3931 * diagnostic-show-locus.c: Likewise.
3932 * diagnostic.c: Likewise.
3933 * dumpfile.c: Likewise.
3934 * gcc-rich-location.h: Likewise.
3935 * genmatch.c: Likewise.
3936 * gimple.h: Likewise.
3937 * gimplify.c: Likewise.
3938 * input.c: Likewise.
3939 * input.h: Likewise. Eliminate the typedef.
3940 * omp-expand.c: Likewise.
3941 * selftest.h: Likewise.
3942 * substring-locations.h (get_source_location_for_substring):
3943 Rename to...
3944 (get_location_within_string): ...this.
3945 * tree-cfg.c: Replace "source_location" with "location_t".
3946 * tree-cfgcleanup.c: Likewise.
3947 * tree-diagnostic.c: Likewise.
3948 * tree-into-ssa.c: Likewise.
3949 * tree-outof-ssa.c: Likewise.
3950 * tree-parloops.c: Likewise.
3951 * tree-phinodes.c: Likewise.
3952 * tree-phinodes.h: Likewise.
3953 * tree-ssa-loop-ivopts.c: Likewise.
3954 * tree-ssa-loop-manip.c: Likewise.
3955 * tree-ssa-phiopt.c: Likewise.
3956 * tree-ssa-phiprop.c: Likewise.
3957 * tree-ssa-threadupdate.c: Likewise.
3958 * tree-ssa.c: Likewise.
3959 * tree-ssa.h: Likewise.
3960 * tree-vect-loop-manip.c: Likewise.
3961
3962 2018-11-13 Michael Ploujnikov <michael.ploujnikov@oracle.com>
3963
3964 * doc/extend.texi: Fix typo in the weakref description.
3965
3966 2018-11-13 Richard Biener <rguenther@suse.de>
3967
3968 PR tree-optimization/86991
3969 * tree-vect-loop.c (vect_is_slp_reduction): Delay reduction
3970 group building until we have successfully detected the SLP
3971 reduction.
3972 (vect_is_simple_reduction): Remove fixup code here.
3973
3974 2018-11-13 David Malcolm <dmalcolm@redhat.com>
3975
3976 * dumpfile.c (VERIFY_DUMP_ENABLED_P): New macro.
3977 (dump_gimple_stmt): Use it.
3978 (dump_gimple_stmt_loc): Likewise.
3979 (dump_gimple_expr): Likewise.
3980 (dump_gimple_expr_loc): Likewise.
3981 (dump_generic_expr): Likewise.
3982 (dump_generic_expr_loc): Likewise.
3983 (dump_printf): Likewise.
3984 (dump_printf_loc): Likewise.
3985 (dump_dec): Likewise.
3986 (dump_dec): Likewise.
3987 (dump_hex): Likewise.
3988 (dump_symtab_node): Likewise.
3989 * gimple-loop-interchange.cc (tree_loop_interchange::interchange):
3990 Guard dump call with dump_enabled_p.
3991 * graphite-isl-ast-to-gimple.c (graphite_regenerate_ast_isl): Likewise.
3992 * graphite-optimize-isl.c (optimize_isl): Likewise.
3993 * graphite.c (graphite_transform_loops): Likewise.
3994 * tree-loop-distribution.c (pass_loop_distribution::execute): Likewise.
3995 * tree-parloops.c (parallelize_loops): Likewise.
3996 * tree-ssa-loop-niter.c (number_of_iterations_exit): Likewise.
3997 * tree-vect-data-refs.c (vect_analyze_group_access_1): Likewise.
3998 (vect_prune_runtime_alias_test_list): Likewise.
3999 * tree-vect-loop.c (vect_update_vf_for_slp): Likewise.
4000 (vect_estimate_min_profitable_iters): Likewise.
4001 * tree-vect-slp.c (vect_record_max_nunits): Likewise.
4002 (vect_build_slp_tree_2): Likewise.
4003 (vect_supported_load_permutation_p): Likewise.
4004 (vect_slp_analyze_operations): Likewise.
4005 (vect_slp_analyze_bb_1): Likewise.
4006 (vect_slp_bb): Likewise.
4007 * tree-vect-stmts.c (vect_analyze_stmt): Likewise.
4008 * tree-vectorizer.c (try_vectorize_loop_1): Likewise.
4009 (pass_slp_vectorize::execute): Likewise.
4010 (increase_alignment): Likewise.
4011
4012 2018-11-13 David Malcolm <dmalcolm@redhat.com>
4013
4014 PR ipa/87955
4015 * ipa-inline.c (report_inline_failed_reason): Guard calls to
4016 cl_target_option_print_diff and cl_optimization_print_diff with
4017 if (dump_file).
4018
4019 2018-11-13 David Malcolm <dmalcolm@redhat.com>
4020
4021 * doc/invoke.texi (-fsave-optimization-record): Note that the
4022 output is compressed.
4023 * optinfo-emit-json.cc: Include <zlib.h>.
4024 (optrecord_json_writer::write): Compress the output.
4025
4026 2018-11-13 Aldy Hernandez <aldyh@redhat.com>
4027
4028 * tree-vrp.c (value_range_base::dump): Dump type.
4029 Do not use INF nomenclature for 1-bit types.
4030 (dump_value_range): Group all variants to common dumping code.
4031 (debug): New overloaded functions for value_ranges.
4032 (value_range_base::dump): Remove no argument version.
4033 (value_range::dump): Same.
4034
4035 2018-11-13 Richard Biener <rguenther@suse.de>
4036
4037 PR tree-optimization/87931
4038 * tree-vect-loop.c (vect_is_simple_reduction): Restrict
4039 nested cycles we support to latch computations vectorizable_reduction
4040 handles.
4041
4042 2018-11-13 Martin Liska <mliska@suse.cz>
4043
4044 PR tree-optimization/87885
4045 * cfghooks.c (account_profile_record): Rename
4046 to ...
4047 (profile_record_check_consistency): ... this.
4048 Calculate missing num_mismatched_freq_in.
4049 (profile_record_account_profile): New function
4050 that calculates time and size of a function.
4051 * cfghooks.h (struct profile_record): Remove
4052 all tuples.
4053 (struct cfg_hooks): Remove after_pass flag.
4054 (account_profile_record): Rename to ...
4055 (profile_record_check_consistency): ... this.
4056 (profile_record_account_profile): New.
4057 * cfgrtl.c (rtl_account_profile_record): Remove
4058 after_pass flag.
4059 * passes.c (check_profile_consistency): Do only
4060 checking.
4061 (account_profile): Calculate size and time of
4062 function only.
4063 (pass_manager::dump_profile_report): Reformat
4064 output.
4065 (execute_one_ipa_transform_pass): Call
4066 consistency check before clean upand call account_profile
4067 after a clean up is done.
4068 (execute_one_pass): Call check_profile_consistency and
4069 account_profile instead of using after_pass flag..
4070 * tree-cfg.c (gimple_account_profile_record): Likewise.
4071
4072 2018-11-13 Martin Liska <mliska@suse.cz>
4073
4074 PR sanitizer/87930
4075 * config/i386/i386.c (ix86_option_override_internal): Error
4076 about usage -mabi=ms and -fsanitize={,kernel-}address.
4077
4078 2018-11-13 Andre Vieira <andre.simoesdiasvieira@arm.com>
4079
4080 * config/aarch64/aarch64.c
4081 (aarch64_vectorize_preferred_vector_alignment): Change return type to
4082 poly_uint64.
4083 (aarch64_simd_vector_alignment_reachable): Adapt to preferred vector
4084 alignment being a poly int.
4085 * doc/tm.texi (TARGET_VECTORIZE_PREFERRED_VECTOR_ALIGNMENT): Change
4086 return type to poly_uint64.
4087 * target.def (default_preferred_vector_alignment): Likewise.
4088 * targhooks.c (default_preferred_vector_alignment): Likewise.
4089 * targhooks.h (default_preferred_vector_alignment): Likewise.
4090 * tree-vect-data-refs.c (vect_calculate_target_alignment): Likewise.
4091 (vect_compute_data_ref_alignment): Adapt to vector alignment being a
4092 poly int.
4093 (vect_update_misalignment_for_peel): Likewise.
4094 (vect_enhance_data_refs_alignment): Likewise.
4095 (vect_find_same_alignment_drs): Likewise.
4096 (vect_duplicate_ssa_name_ptr_info): Likewise.
4097 (vect_setup_realignment): Likewise.
4098 (vect_can_force_dr_alignment_p): Change alignment parameter type to
4099 poly_uint64.
4100 * tree-vect-loop-manip.c (get_misalign_in_elems): Learn to construct a
4101 mask with a compile time variable vector alignment.
4102 (vect_gen_prolog_loop_niters): Adapt to vector alignment being a poly
4103 int.
4104 (vect_do_peeling): Exit early if vector alignment is not constant.
4105 * tree-vect-stmts.c (ensure_base_align): Adapt to vector alignment being
4106 a poly int.
4107 (vectorizable_store): Likewise.
4108 (vectorizable_load): Likweise.
4109 * tree-vectorizer.h (struct dr_vec_info): Make target_alignment field a
4110 poly_uint64.
4111 (vect_known_alignment_in_bytes): Adapt to vector alignment being a
4112 poly int.
4113 (vect_can_force_dr_alignment_p): Change alignment parameter type to
4114 poly_uint64.
4115
4116 2018-11-13 Richard Biener <rguenther@suse.de>
4117
4118 PR tree-optimization/87962
4119 * tree-vect-loop.c (vect_is_simple_reduction): More reliably
4120 detect outer reduction for disqualifying in-loop uses.
4121
4122 2018-11-13 Richard Biener <rguenther@suse.de>
4123
4124 PR tree-optimization/87967
4125 * tree-vect-loop.c (vect_transform_loop): Also copy PHIs
4126 for constants for the scalar loop.
4127
4128 2018-11-13 Alan Modra <amodra@gmail.com>
4129
4130 * config/rs6000/linux64.h (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Exclude
4131 integer constants when -mcmodel=medium.
4132
4133 2018-11-13 Claudiu Zissulescu <claziss@synopsys.com>
4134
4135 * config/arc/arc.h (FUNCTION_PROFILER): Redefine to empty.
4136 * config/arc/elf.h (PROFILE_HOOK): Define.
4137 * config/arc/linux.h (PROFILE_HOOK): Likewise.
4138
4139 2018-11-13 Claudiu Zissulescu <claziss@synopsys.com>
4140
4141 * config/arc/arc.c (hwloop_optimize): Bailout when detecting a
4142 jump table data in the text section.
4143
4144 2018-11-13 Claudiu Zissulescu <claziss@synopsys.com>
4145
4146 * config/arc/arc.c (arc_eh_return_address_location): Repurpose it
4147 to fit the eh_return pattern.
4148 * config/arc/arc.md (eh_return): Define.
4149 (VUNSPEC_ARC_EH_RETURN): Likewise.
4150 * config/arc/arc-protos.h (arc_eh_return_address_location): Match
4151 new implementation.
4152 * config/arc/arc.h (EH_RETURN_HANDLER_RTX): Remove it.
4153
4154
4155 2018-11-13 Claudiu Zissulescu <claziss@synopsys.com>
4156
4157 * common/config/arc/arc-common.c (arc_option_optimization_table):
4158 Millicode optimization is default on for size optimizations.
4159 * config/arc/arc-protos.h (arc_check_multi): New function.
4160 * config/arc/arc.c (RTX_OK_FOR_OFFSET_P): Rearange.
4161 (ENTER_LEAVE_START_REG): Define.
4162 (ENTER_LEAVE_END_REG): Likewise.
4163 (arc_override_options): Disable millicode when long calls option
4164 is on.
4165 (arc_frame_info): Change it from int to bool.
4166 (arc_compute_frame_size): Clean up.
4167 (arc_save_restore): Remove.
4168 (frame_save_reg): New function.
4169 (frame_restore_reg): Likewise.
4170 (arc_enter_leave_p): Likewise.
4171 (arc_save_callee_saves): Likewise.
4172 (arc_restore_callee_saves): Likewise.
4173 (arc_save_callee_enter): Likewise.
4174 (arc_restore_callee_leave): Likewise.
4175 (arc_save_callee_milli): Likewise.
4176 (arc_restore_callee_milli): Likewise.
4177 (arc_expand_prologue): Reimplement to emit enter/leave
4178 instructions.
4179 (arc_expand_epilogue): Likewise.
4180 (arc_check_multi): New function.
4181 * config/arc/arc.md (push_multi_fp): New pattern.
4182 (push_multi_fp_blink): Likewise.
4183 (pop_multi_fp): Likewise.
4184 (pop_multi_fp_blink): Likewise.
4185 (pop_multi_fp_ret): Likewise.
4186 (pop_multi_fp_blink_ret): Likewise.
4187 * config/arc/arc.opt (mmillicode): Update option.
4188 (mcode-density-frame): New option.
4189 * config/arc/predicates.md (push_multi_operand): New predicate.
4190 (pop_multi_operand): Likewise.
4191 * doc/invoke.texi (ARC): Update ARC options information.
4192
4193
4194 2018-11-13 Claudiu Zissulescu <claziss@synopsys.com>
4195
4196 * config/arc/arc-protos.h (gen_operands_ldd_std): Add.
4197 * config/arc/arc.c (operands_ok_ldd_std): New function.
4198 (mem_ok_for_ldd_std): Likewise.
4199 (gen_operands_ldd_std): Likewise.
4200 * config/arc/arc.md: Add peephole2 rules for std/ldd.
4201
4202 2018-11-13 Eric Botcazou <ebotcazou@adacore.com>
4203
4204 * toplev.c (output_stack_usage): Turn test on flag_stack_usage into
4205 test on stack_usage_file.
4206 (lang_dependent_init): Do not open the .su file if generating LTO.
4207
4208 2018-11-13 Jakub Jelinek <jakub@redhat.com>
4209
4210 PR rtl-optimization/87918
4211 * simplify-rtx.c (simplify_merge_mask): For COMPARISON_P, use
4212 simplify_gen_relational rather than simplify_gen_binary.
4213
4214 2018-11-13 Richard Biener <rguenther@suse.de>
4215
4216 * tree-ssanames.h (set_range_info): Use value_range_base.
4217 (get_range_info): Likewise.
4218 * tree-ssanames.c (set_range_info): Likewise.
4219 (get_range_info): Likewise.
4220 * tree-vrp.c (value_range_base::union_helper): Split
4221 out common parts of value_range[_base]::union_.
4222 (value_range_base::union_): Update.
4223 (value_range::union_): Likewise.
4224 (determine_value_range_1): Use value_range_base.
4225 (determine_value_range): Likewise.
4226 * tree-vrp.h (value_range_base::union_helper): Move ...
4227 (value_range::union_helper): ... from here.
4228
4229 2018-11-13 Alan Modra <amodra@gmail.com>
4230
4231 * config/rs6000/rs6000.c (rs6000_secondary_reload_inner): Negate
4232 offset for PRE_DEC.
4233 (rs6000_secondary_reload_gpr): Don't call find_replacement.
4234
4235 2018-11-13 Sandra Loosemore <sandra@codesourcery.com>
4236
4237 PR middle-end/59634
4238 * doc/invoke.texi (Optimize Options): Clarify that the
4239 l1-cache-line-size, l1-cache-size, and l2-cache-size parameters
4240 apply to data cache size.
4241
4242 2018-11-13 Alan Modra <amodra@gmail.com>
4243
4244 * config/rs6000/predicates.md (logical_const_operand),
4245 (logical_operand): Correct comment.
4246 * config/rs6000/rs6000.c (rs6000_emit_prologue): Comment fix.
4247
4248 2018-11-13 Alan Modra <amodra@gmail.com>
4249
4250 * config/rs6000/rs6000.md (addsi3_high): Prefix with '*'.
4251
4252 2018-11-13 Alan Modra <amodra@gmail.com>
4253
4254 * gcc/doc/md.texi (Machine Constraints): Correct rs6000 h constraint
4255 description.
4256 * config/rs6000/rs6000.md (movsi_internal1): Delete MT%0 case
4257 covered by alternative.
4258 (movcc_internal1): Ignore h for register preference.
4259 (mov<mode>_hardfloat64): Likewise.
4260 (mov<mode>_softfloat): Ignore c, l, h for register preference.
4261
4262 2018-11-12 Sandra Loosemore <sandra@codesourcery.com>
4263
4264 PR preprocessor/47823
4265 * doc/cpp.texi (Alternatives to Wrapper #ifndef): Move #pragma once
4266 documentation to...
4267 (Pragmas): ...here.
4268 * doc/extend.texi (Pragmas): Note additional pragmas documented
4269 in the CPP manual.
4270
4271 2018-11-13 Kugan Vivekanandarajah <kuganv@linaro.org>
4272
4273 PR middle-end/86677
4274 PR middle-end/87528
4275 * tree-scalar-evolution.c (expression_expensive_p): Make
4276 BUILTIN POPCOUNT as expensive when backend does not define it.
4277
4278 2018-11-12 Fredrik Noring <noring@nocrew.org>
4279
4280 * config.gcc: Update with-llsc defaults for MIPS r5900.
4281
4282 2018-11-12 Martin Liska <mliska@suse.cz>
4283
4284 PR gcov-profile/87442
4285 * common.opt: Add -fprofile-filter-files and -fprofile-exclude-files
4286 options.
4287 * doc/invoke.texi: Document them.
4288 * tree-profile.c (parse_profile_filter): New.
4289 (parse_profile_file_filtering): Likewise.
4290 (release_profile_file_filtering): Likewise.
4291 (include_source_file_for_profile): Likewise.
4292 (tree_profiling): Filter source files based on the
4293 newly added options.
4294
4295 2018-11-12 Martin Liska <mliska@suse.cz>
4296
4297 PR target/87903
4298 * doc/extend.texi: Add missing values for __builtin_cpu_is and
4299 __builtin_cpu_supports for x86 target.
4300
4301 2018-11-12 Sandra Loosemore <sandra@codesourcery.com>
4302
4303 PR middle-end/21110
4304 * doc/rtl.texi (Constants): Clarify that mode of "high" doesn't
4305 have to be Pmode.
4306 (Arithmetic): Likewise for "lo_sum".
4307
4308 2018-11-12 Renlin Li <renlin.li@arm.com>
4309
4310 PR target/87815
4311 * dse.c (get_stored_val): Add check for compile-time constantness
4312 of gap.
4313
4314 2018-11-12 Sudakshina Das <sudi.das@arm.com>
4315
4316 * config/arm/arm-cpus.in (armv8_5, sb, predres): New features.
4317 (ARMv8_5a): New fgroup.
4318 (armv8.5-a): New arch.
4319 (armv8-a, armv8.1-a, armv8.2-a, armv8.3-a, armv8.4-a): New options
4320 sb and predres.
4321 * config/arm/arm-tables.opt: Regenerate.
4322 * config/arm/t-aprofile: Add matching rules for -march=armv8.5-a
4323 * config/arm/t-arm-elf (all_v8_archs): Add armv8.5-a.
4324 * config/arm/t-multilib (v8_5_a_simd_variants): New variable.
4325 Add matching rules for -march=armv8.5-a and extensions.
4326 * doc/invoke.texi (ARM options): Document -march=armv8.5-a.
4327 Add sb and predres to all armv8-a except armv8.5-a.
4328
4329 2018-11-12 Richard Biener <rguenther@suse.de>
4330
4331 * tree-vrp.h (value_range[_base]::set): Make public. Provide
4332 overload for single value.
4333 (value_range[_base]::set_nonnull): New.
4334 (value_range[_base]::set_null): Likewise.
4335 (value_range): Document bitmap copying behavior, mark
4336 copy constructor and assignment operator deleted.
4337 (value_range::move): New.
4338 (value_range::set_and_canonicalize): Default bitmap to zero.
4339 (set_value_range_to_nonnull): Remove.
4340 (set_value_range_to_null): Likewise.
4341 (set_value_range): Likewise.
4342 (set_value_range_to_value): Likewise.
4343 (extract_range_from_unary_expr): Work on value_range_base.
4344 (extract_range_from_binary_expr_1): Likewise. Rename to...
4345 (extract_range_from_binary_expr): ... this.
4346 * tree-vrp.c (value_range::update): Clear equiv bitmap
4347 if required.
4348 (value_range::move): New, move equiv bitmap.
4349 (value_range_base::set_undefined): Avoid assignment.
4350 (value_range::set_undefined): Likewise.
4351 (value_range_base::set_varying): Likewise.
4352 (value_range::set_varying): Likewise.
4353 (set_value_range): Remove.
4354 (value_range_base::set): New overload for value.
4355 (value_range::set): Likewise.
4356 (set_value_range_to_nonnull): Remove.
4357 (value_range_base::set_nonnull): New.
4358 (value_range::set_nonnull): Likewise.
4359 (set_value_range_to_null): Remove.
4360 (value_range_base::set_null): New.
4361 (value_range::set_null): Likewise.
4362 (range_is_null): Work on value_range_base.
4363 (range_is_nonnull): Likewise.
4364 (ranges_from_anti_range): Likewise.
4365 (extract_range_into_wide_ints): Likewise.
4366 (extract_range_from_multiplicative_op): Likewise.
4367 (extract_range_from_binary_expr): Likewise. Update for API changes.
4368 (extract_range_from_unary_expr): Likewise. Remove OBJ_TYPE_REF
4369 handling.
4370 (value_range::intersect_helper): Avoid copy and assignment.
4371 (value_range::union_helper): Likewise.
4372 (determine_value_range_1): Adjust.
4373 * gimple-ssa-evrp-analyze.c (evrp_range_analyzer::try_find_new_range):
4374 Avoid assignment by using move.
4375 (evrp_range_analyzer::record_ranges_from_stmt): Avoid assignment.
4376 * tree-ssa-threadedge.c (record_temporary_equivalences_from_phis):
4377 Likewise.
4378 * tree-ssanames.c (get_range_info): Likewise.
4379 * vr-values.h (vr_values::get_vr_for_comparison): Adjust API.
4380 * vr-values.c (vr_values::get_value_range): Adjust.
4381 (vr_values::update_value_range): Likewise.
4382 (symbolic_range_based_on_p): Work on value_range_base.
4383 (vr_values::extract_range_from_binary_expr): Use value_range_base.
4384 (vr_values::extract_range_from_unary_expr): Likewise.
4385 (vr_values::extract_range_from_cond_expr): Avoid assignment.
4386 (vr_values::extract_range_from_comparison): Adjust.
4387 (vr_values::check_for_binary_op_overflow): Use value_range_base.
4388 (vr_values::extract_range_basic): Adjust.
4389 (vr_values::adjust_range_with_scev): Likewise.
4390 (vr_values::vrp_visit_assignment_or_call): Likewise.
4391 (vr_values::get_vr_for_comparison): Change API to avoid
4392 assignment and copy construction.
4393 (vr_values::compare_name_with_value): Adjust accordingly.
4394 (vr_values::compare_names): Likewise.
4395 (vr_values::extract_range_from_phi_node): Avoid assignment and
4396 bogus in-place modify of equiv bitmap.
4397 (vr_values::simplify_bit_ops_using_ranges): Use value_range_base.
4398 * ipa-prop.c (ipa_compute_jump_functions_for_edge): Adjust
4399 for extract_range_from_unary_expr API change.
4400 * ipa-cp.c (ipa_vr_operation_and_type_effects): Likewise.
4401
4402 2018-11-12 Eric Botcazou <ebotcazou@adacore.com>
4403
4404 * config/mcore/mcore.h (WORD_REGISTER_OPERATIONS): Remove duplicate.
4405
4406 2018-11-12 Richard Biener <rguenther@suse.de>
4407
4408 * tree-vrp.h (value_range_base::symbolic_p,
4409 value_range_base::constant_p, value_range_base::zero_p,
4410 value_range_base::singleton_p): Move from value_range.
4411 (value_range::dump): Add.
4412 * gimple-ssa-evrp-analyze.c
4413 (evrp_range_analyzer::record_ranges_from_phis): Use set_varying.
4414 * ipa-cp.c (ipcp_vr_lattice::print): Use dump_value_range.
4415 * tree-ssa-threadedge.c (record_temporary_equivalences_from_phis):
4416 Use set_varying.
4417 * tree-vrp.c (value_range::symbolic_p): Move to value_range_base.
4418 (value_range::constant_p): Likewise.
4419 (value_range::singleton_p): Likewise.
4420 (value_range_base::dump): Add.
4421 (set_value_range_to_undefined): Remove.
4422 (set_value_range_to_varying): Likewise.
4423 (range_int_cst_p): Take value_range_base argument.
4424 (range_int_cst_singleton_p): Likewise.
4425 (value_range_constant_singleton): Likewise.
4426 (vrp_set_zero_nonzero_bits): Likewise.
4427 (extract_range_from_multiplicative_op): Use set_varying.
4428 (extract_range_from_binary_expr_1): Likewise. Use set_undefined.
4429 (extract_range_from_unary_expr): Likewise.
4430 (dump_value_range_base): Change to overload of dump_value_range.
4431 (vrp_prop::vrp_initialize): Use set_varying and set_undefined.
4432 (vrp_prop::visit_stmt): Likewise.
4433 (value_range::intersect_helper): Likewise.
4434 (value_range::union_helper): Likewise.
4435 (determine_value_range_1): Likewise.
4436
4437 2018-11-12 Richard Biener <rguenther@suse.de>
4438
4439 * tree-vrp.c (set_value_range_to_nonnull): Clear equiv.
4440 (set_value_range_to_null): Likewise.
4441 * vr-values.c (vr_values::extract_range_from_comparison):
4442 Clear equiv for constant singleton ranges.
4443
4444 2018-11-12 Wei Xiao <wei3.xiao@intel.com>
4445
4446 * config/i386/sse.md: Combine VFIXUPIMM* patterns
4447 (<avx512>_fixupimm<mode>_maskz<round_saeonly_expand_name>): Update.
4448 (<avx512>_fixupimm<mode><sd_maskz_name><round_saeonly_name>): Update.
4449 (<avx512>_fixupimm<mode>_mask<round_saeonly_name>): Remove.
4450 (avx512f_sfixupimm<mode>_maskz<round_saeonly_expand_name>): Update.
4451 (avx512f_sfixupimm<mode><sd_maskz_name><round_saeonly_name>): Update.
4452 (avx512f_sfixupimm<mode>_mask<round_saeonly_name>): Remove.
4453
4454 2018-11-11 Sandra Loosemore <sandra@codesourcery.com>
4455
4456 PR c/69502
4457 * doc/extend.texi (Common Type Attributes): For the align type
4458 attribute, copy language about decreasing alignment from the
4459 corresponding variable attribute.
4460
4461 2018-11-11 Xianmiao Qu <xianmiao_qu@c-sky.com>
4462
4463 * config/csky/csky.md (*fpuv2_nmulsf3_1, *fpuv2_nmuldf3_1): Handle
4464 -frounding-math.
4465
4466 2018-11-11 Sandra Loosemore <sandra@codesourcery.com>
4467
4468 PR c++/43105
4469 * doc/invoke.texi (C++ Dialect Options): Add warning about mixing
4470 -frtti and -fno-rtti code.
4471
4472 2018-11-11 Sandra Loosemore <sandra@codesourcery.com>
4473
4474 PR c/26366
4475 * doc/extend.texi (Other Builtins): Document probability associated
4476 with __builtin_expect.
4477
4478 2018-11-11 Uros Bizjak <ubizjak@gmail.com>
4479
4480 PR target/87928
4481 * config/i386/i386.h (STACK_BOUNDARY): Use TARGET_64BIT_MS_ABI
4482 instead of (TARGET_64BIT && ix86_abi == MS_ABI).
4483 * config/i386/darwin.h (STACK_BOUNDARY): Ditto.
4484 * config/i386/cygming.h (STACK_BOUNDARY): Remove.
4485
4486 2018-11-11 Xianmiao Qu <xianmiao_qu@c-sky.com>
4487
4488 * config/csky/csky-linux-elf.h (CC1_SPEC): Support -profile.
4489
4490 2018-11-11 Xianmiao Qu <xianmiao_qu@c-sky.com>
4491
4492 * config/csky/csky.h (ASM_PREFERRED_EH_DATA_FORMAT): Define.
4493
4494 2018-11-11 Richard Biener <rguenther@suse.de>
4495
4496 * tree-vrp.h (class value_range_base): New base class for
4497 value_range containing all but the m_equiv member.
4498 (dump_value_range_base): Add.
4499 (range_includes_zero_p): Work on value_range_base.
4500 * tree-vrp.c (value_range_base::set): Split out base handling
4501 from...
4502 (value_range::set): this.
4503 (value_range::set_equiv): New.
4504 (value_range_base::value_range_base): New constructors.
4505 (value_range_base::check): Split out base handling from...
4506 (value_range::check): this.
4507 (value_range::equal_p): Refactor in terms of
4508 ignore_equivs_equal_p which is now member of the base.
4509 (value_range_base::set_undefined): New.
4510 (value_range_base::set_varying): Likewise.
4511 (value_range_base::dump):Split out base handling from...
4512 (value_range::dump): this.
4513 (value_range_base::set_and_canonicalize): Split out base handling
4514 from...
4515 (value_range::set_and_canonicalize): this.
4516 (value_range_base::union_): New.
4517 * ipa-prop.h (struct ipa_jump_func): Use value_range_base *
4518 for m_vr.
4519 * ipa-cp.c (class ipcp_vr_lattice): Use value_range_base
4520 instead of value_range everywhere.
4521 (ipcp_vr_lattice::print): Use dump_value_range_base.
4522 (ipcp_vr_lattice::meet_with): Adjust.
4523 (ipcp_vr_lattice::meet_with_1): Likewise.
4524 (ipa_vr_operation_and_type_effects): Likewise.
4525 (propagate_vr_across_jump_function): Likewise.
4526 * ipa-prop.c (struct ipa_vr_ggc_hash_traits): Likewise.
4527 (ipa_get_value_range): Likewise.
4528 (ipa_set_jfunc_vr): Likewise.
4529 (ipa_compute_jump_functions_for_edge): Likewise.
4530
4531 2018-11-10 Sandra Loosemore <sandra@codesourcery.com>
4532
4533 PR middle-end/65703
4534 * doc/invoke.texi (Optimize Options): Add @opindex entries
4535 for the positive forms of -fno-xxx and -mno-xxx options
4536 that were lacking them.
4537
4538 2018-11-10 Segher Boessenkool <segher@kernel.crashing.org>
4539
4540 * combine.c (make_more_copies): Only make an intermediate copy if the
4541 dest of a move is a pseudo.
4542
4543 2018-11-09 Maya Rashish <coypu@sdf.org>
4544
4545 PR target/87221
4546 * config/netbsd-elf.h (NETBSD_STARTFILE_SPEC): Use crtbeginS.o for PIE.
4547 (NETBSD_ENDFILE_SPEC): Use crtendS.o for PIE.
4548
4549 2018-11-09 Sandra Loosemore <sandra@codesourcery.com>
4550
4551 PR driver/41179
4552 PR middle-end/65703
4553 * doc/invoke.texi (Optimize Options): Clarify default behavior
4554 for -fno-toplevel-reorder, -fno-defer-pop, and -fno-branch-count-reg.
4555
4556 2018-11-09 Bernd Edlinger <bernd.edlinger@hotmail.de>
4557
4558 PR tree-optimization/87940
4559 * expr.c (string_constant): Don't strip NOPS in subexpressions.
4560 Fold PLUS_EXPR correctly.
4561
4562 2018-11-09 Ilya Leoshkevich <iii@linux.ibm.com>
4563
4564 PR target/87762
4565 * config/s390/s390.c (s390_safe_relative_long_p): New function.
4566 (annotate_constant_pool_refs): Skip insns which support
4567 relative addressing.
4568 (annotate_constant_pool_refs_1): New helper function.
4569 (find_constant_pool_ref): Skip insns which support relative
4570 addression.
4571 (find_constant_pool_ref_1): New helper function.
4572 (replace_constant_pool_ref): Skip insns which support
4573 relative addressing.
4574 (replace_constant_pool_ref_1): New helper function.
4575 (s390_mainpool_start): Adapt to the new signature.
4576 (s390_mainpool_finish): Likewise.
4577 (s390_chunkify_start): Likewise.
4578 (s390_chunkify_finish): Likewise.
4579 (pass_s390_early_mach::execute): Likewise.
4580 (s390_prologue_plus_offset): Likewise.
4581 (s390_emit_prologue): Likewise.
4582 (s390_emit_epilogue): Likewise.
4583
4584 2018-11-09 Jakub Jelinek <jakub@redhat.com>
4585
4586 * gimplify.c (gimplify_scan_omp_clauses): Call sorry_at for valid
4587 but unsupported lastprivate with conditional modifier.
4588
4589 2018-11-09 Jeff Law <law@redhat.com>
4590
4591 * config/mips/mips.c (mips_loongson_ext2_prefetch_cookie): Handle
4592 unused argument better. Add gcc_unreachable to silence warning.
4593
4594 2018-11-09 Martin Sebor <msebor@redhat.com>
4595
4596 PR middle-end/81824
4597 * attribs.c (has_attribute): New helper function.
4598 (decls_mismatched_attributes, maybe_diag_alias_attributes): Same.
4599 * attribs.h (decls_mismatched_attributes): Declare.
4600 * cgraphunit.c (handle_alias_pairs): Call maybe_diag_alias_attributes.
4601 (maybe_diag_incompatible_alias): Use OPT_Wattribute_alias_.
4602 * common.opt (-Wattribute-alias): Take an argument.
4603 (-Wno-attribute-alias): New option.
4604 * doc/extend.texi (Common Function Attributes): Document copy.
4605 (Common Variable Attributes): Same.
4606 * doc/invoke.texi (-Wmissing-attributes): Document enhancement.
4607 (-Wattribute-alias): Document new option argument.
4608
4609 2018-11-09 Richard Earnshaw <rearnsha@arm.com>
4610
4611 * config/arm/parsecpu.awk (/alias/): Tighten invisible alias
4612 matching criteria. Remove unused array initializer.
4613
4614 2018-11-09 Bill Schmidt <wschmidt@linux.ibm.com>
4615 Jinsong Ji <jji@us.ibm.com>
4616
4617 * config/rs6000/xmmintrin.h (_mm_cvtss_si32): Fix incorrect
4618 constraints by introducing a new temporary.
4619 (_mm_cvtss_si64): Likewise.
4620
4621 2018-11-09 Martin Liska <mliska@suse.cz>
4622
4623 * common.opt: Add -fipa-stack-alignment flag.
4624 * doc/invoke.texi: Document it.
4625 * final.c (rest_of_clean_state): Guard stack
4626 shrinking with flag.
4627
4628 2018-11-09 Martin Liska <mliska@suse.cz>
4629
4630 * cgraph.h (ipa_discover_readonly_nonaddressable_vars): Rename
4631 to ...
4632 (ipa_discover_variable_flags): ... this.
4633 * common.opt: Come up with new flag -fipa-reference-addressable.
4634 * doc/invoke.texi: Document it.
4635 * ipa-reference.c (propagate): Call the renamed fn.
4636 * ipa-visibility.c (whole_program_function_and_variable_visibility):
4637 Likewise.
4638 * ipa.c (ipa_discover_readonly_nonaddressable_vars): Renamed to
4639 ...
4640 (ipa_discover_variable_flags): ... this. Discover
4641 non-addressable variables only with the newly added flag.
4642 * opts.c: Enable the newly added flag with -O1 and higher
4643 optimization level.
4644
4645 2018-11-09 David Malcolm <dmalcolm@redhat.com>
4646
4647 * json.cc (selftest::test_writing_literals): Fix comment.
4648
4649 2018-11-09 Martin Liska <mliska@suse.cz>
4650
4651 * config/aarch64/aarch64.c (aarch64_parse_arch): Do not copy
4652 string to a stack buffer.
4653 (aarch64_parse_cpu): Likewise.
4654 (aarch64_parse_tune): Likewise.
4655
4656 2018-11-09 Richard Biener <rguenther@suse.de>
4657
4658 PR tree-optimization/87953
4659 * tree-vect-loop.c (vectorizable_reduction): For analysis
4660 always pass ops[0] to vectorizable_condition.
4661
4662 2018-11-09 Stafford Horne <shorne@gmail.com>
4663 Richard Henderson <rth@twiddle.net>
4664 Joel Sherrill <joel@rtems.org>
4665
4666 * common/config/or1k/or1k-common.c: New file.
4667 * config/or1k/*: New.
4668 * config.gcc (or1k*-*-*): New.
4669 * configure.ac (or1k*-*-*): New test for openrisc tls.
4670 * configure: Regenerated.
4671 * doc/install.texi: Document OpenRISC triplets.
4672 * doc/invoke.texi: Document OpenRISC arguments.
4673 * doc/md.texi: Document OpenRISC.
4674
4675 2018-11-09 Richard Earnshaw <rearnsha@arm.com>
4676
4677 * config/arm/arm-cpus.in (arm7tdmi): Add an alias for arm7tdmi-s.
4678 (arm7tdmi-s): Delete CPU.
4679 (arm710t): Add aliases for arm720t and arm740t.
4680 (arm720t, arm740t): Delete CPUs.
4681 (arm920t): Add aliases for arm920, arm922t and arm940t.
4682 (arm920, arm922t, arm940t): Delete CPUs.
4683 (arm10tdmi): Add alias for arm1020t.
4684 (arm1020t): Delete CPU.
4685 (arm9e): Add aliases for arm946e-s, arm966e-s and arm968e-s.
4686 (arm946e-s, arm966e-s, arm968e-s): Delete CPUs.
4687 (arm10e): Add aliases for arm1020e and arm1022e.
4688 (arm1020e, arm1022e): Delete CPU.
4689 * config/arm/arm.md (generic_sched): Remove entries that are now
4690 handled by aliases.
4691 (generic_vfp): Likewise.
4692 * config/arm/arm1020e.md: Simplify tuning selection based on alias
4693 changes.
4694 * config/arm/arm-tune.md: Regenerated.
4695 * config/arm/arm-tables.opt: Regenerated.
4696
4697 2018-11-09 Richard Biener <rguenther@suse.de>
4698
4699 PR tree-optimization/87621
4700 * tree-vect-loop.c (vectorizable_reduction): Handle reduction
4701 op with only phi inputs.
4702 * tree-ssa-loop-ch.c: Include tree-ssa-sccvn.h.
4703 (ch_base::copy_headers): Run CSE on copied loop headers.
4704 (pass_ch_vect::process_loop_p): Simplify.
4705
4706 2018-11-09 Alexandre Oliva <oliva@adacore.com>
4707
4708 * config/i386/mingw32.h (LINK_SPEC_LARGE_ADDR_AWARE): Adjust
4709 for non-w64 x86_64 biarch.
4710
4711 2018-11-09 Alexandre Oliva <aoliva@redhat.com>
4712
4713 PR rtl-optimization/86438
4714 * compare-elim.c (try_eliminate_compare): Use SET_SRC instead
4715 of in_b for the compare if in_b is SET_DEST.
4716
4717 PR target/87793
4718 * config/i386/i386.c (ix86_const_not_ok_for_debug_p): Reject
4719 non-toplevel UNSPEC.
4720
4721 2018-11-08 Aldy Hernandez <aldyh@redhat.com>
4722
4723 * tree-vrp.c (value_range::check): Do not access internals
4724 directly.
4725 (value_range::singleton_p): Same.
4726 (value_range::type): Same.
4727 (vrp_finalize): Use value_range API.
4728
4729 2018-11-08 Aldy Hernandez <aldyh@redhat.com>
4730
4731 * tree-vrp.c (may_contain_p): Do not access m_min/m_max directly.
4732
4733 2018-11-08 Aldy Hernandez <aldyh@redhat.com>
4734
4735 * vr-values.c (vr_values::get_value_range): Use value_range API
4736 instead of piecing together ranges.
4737 (vr_values::update_value_range): Same.
4738
4739 2018-11-08 Aldy Hernandez <aldyh@redhat.com>
4740
4741 * gimple-fold.c (size_must_be_zero_p): Use value_range API instead
4742 of performing ad-hoc calculations.
4743 * tree-ssanames.c (set_range_info): New overloaded function
4744 accepting value_range &.
4745 (get_range_info): Same.
4746 * tree-ssanames.h (set_range_info_raw): Remove.
4747 (set_range_info): New prototype.
4748 (get_range_info): Same.
4749 * tree-vrp.h (value_range::null_p): Rename to zero_p.
4750 * tree-vrp.c (value_range::null_p): Same.
4751
4752 2018-11-09 Jan Hubicka <jh@suse.cz>
4753
4754 * tree.c (fld_type_variant_equal_p): Test user align flag.
4755 (flt_type_variant): Copy user align flag.
4756 (fld_incomplete_type_of): Clear it.
4757
4758 2018-11-09 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
4759
4760 * config/arm/neon.md (div<mode>3): New pattern.
4761
4762 2018-11-08 Andi Kleen <ak@linux.intel.com>
4763
4764 * common/config/i386/i386-common.c (OPTION_MASK_ISA_PTWRITE_SET): New.
4765 (OPTION_MASK_ISA_PTWRITE_UNSET): New.
4766 (ix86_handle_option): Handle OPT_mptwrite.
4767 * config/i386/cpuid.h (bit_PTWRITE): Add.
4768 * config/i386/driver-i386.c (host_detect_local_cpu): Detect ptwrite.
4769 * config/i386/i386-builtin.def (BDESC): Add ptwrite32/64.
4770 * config/i386/i386-c.c (ix86_target_macros_internal): Define __PTWRITE__.
4771 * config/i386/i386.c (ix86_target_string): Handle ptwrite.
4772 (ix86_option_override_internal): Handle PTA_PTWRITE.
4773 (ix86_valid_target_attribute_inner_p): Define ptwrite.
4774 (def_builtin2): Force UINT64 to be 64bit only.
4775 * config/i386/i386.h (TARGET_PTWRITE): Add.
4776 (TARGET_PTWRITE_P): Add.
4777 (PTA_PTWRITE): Add.
4778 * config/i386/i386.md: Define ptwrite.
4779 * config/i386/i386.opt: Add -mptwrite.
4780 * config/i386/immintrin.h (_ptwrite64): Add.
4781 (_ptwrite32): Add
4782 * doc/extend.texi: Document __builtin_ia32_ptwrite*.
4783 * doc/invoke.texi: Document -mptwrite.
4784
4785 2018-11-08 Peter Bergner <bergner@linux.ibm.com>
4786
4787 PR rtl-optimization/87600
4788 * cfgexpand.c (expand_asm_stmt): Catch illegal asm constraint usage.
4789 * lra-constraints.c (process_alt_operands): Skip illegal hard
4790 register usage. Prefer reloading non hard register operands.
4791
4792 2018-11-08 Sandra Loosemore <sandra@codesourcery.com>
4793
4794 PR other/36572
4795 * doc/invoke.texi (Optimize Options): Clarify default behavior
4796 for -fno-sched-interblock and -fno-sched-spec.
4797
4798 2018-11-08 Roman Geissler <roman.geissler@amadeus.com>
4799
4800 * collect2.c (linker_select): Add USE_LLD_LD.
4801 (ld_suffixes): Add ld.lld.
4802 (main): Handle -fuse-ld=lld.
4803 * common.opt (-fuse-ld=lld): New option.
4804 * doc/invoke.texi (-fuse-ld=lld): Document.
4805 * opts.c (common_handle_option): Handle OPT_fuse_ld_lld.
4806
4807 2018-11-08 Paul Koning <ni1d@arrl.net>
4808
4809 * config/pdp11/constraints.md: Add "Z" series constraints for use
4810 with pre-dec and post-inc addressing.
4811 * config/pdp11/pdp11-protos.m (expand_block_move): Delete.
4812 (pdp11_expand_operands): Add int argument (word count).
4813 (pdp11_sp_frame_offset): Delete.
4814 (pdp11_cmp_length): New function.
4815 (pushpop_regeq): New function.
4816 * config/pdp11/pdp11.c (TARGET_STACK_PROTECT_RUNTIME_ENABLED_P):
4817 Add hook.
4818 (pdp11_expand_prologue, pdp11_expand_epilogue): Rewrite for new
4819 frame layout.
4820 (pdp11_initial_elimination_offset): Ditto.
4821 (pdp11_expand_operands): Add word count argument. Bugfixes.
4822 (output_move_multiple): Change how pointer adjustment is done.
4823 (pdp11_gen_int_label): Correct format.
4824 (output_ascii): Ditto.
4825 (pdp11_asm_output_var): Add code for DEC assembler case.
4826 (pdp11_asm_print_operand): Bugfix for CONST_DOUBLE holding integer
4827 value.
4828 (legitimate_const_double_p): Ditto.
4829 (pdp11_register_move_cost): Adjust for new register classes.
4830 (pdp11_regno_reg_class): Ditto.
4831 (expand_block_move): Delete.
4832 (pushpop_regeq): New function.
4833 (pdp11_legitimate_address_p): Bugfix in check for constant
4834 offset.
4835 (pdp11_sp_frame_offset): Delete.
4836 (pdp11_reg_save_size): New helper function for new frame layout.
4837 (output_addr_const_pdp11): Remove CONST_DOUBLE case.
4838 (pdp11_expand_shift): Bugfix in check for constant shift count.
4839 (pdp11_shift_length): Ditto.
4840 (pdp11_assemble_shift): Copy input to pdp11_expand_operands.
4841 (pdp11_cmp_length): New function.
4842 * config/pdp11/pdp11.h (TARGET_CPU_CPP_BUILTINS): Add macros for
4843 some compile options.
4844 (FIXED_REGISTERS): Remove HARD_FRAME_POINTER_REGNUM.
4845 (CALL_USED_REGISTERS): Ditto.
4846 (ELIMINABLE_REGS): Ditto.
4847 (REGISTER_NAMES): Ditto.
4848 (reg_class): Add classes NOTR0_REG through NOTSP_REG for use by Z
4849 constraints.
4850 (REG_CLASS_NAMES): Ditto.
4851 (REG_CLASS_CONTENTS): Ditto. Also remove
4852 HARD_FRAME_POINTER_REGNUM.
4853 (CPU_REG_CLASS): New macro.
4854 (CLASS_MAX_NREGS): Adjust for new register classes.
4855 (FUNCTION_PROFILER): Make no-op.
4856 (may_call_alloca): Remove unused declaration.
4857 (ASM_OUTPUT_ALIGN): Add workaround for PR87795.
4858 (ASM_OUTPUT_SKIP): Fix format.
4859 * config/pdp11/pdp11.md (unspecv): Add UNSPECV_MOVMEM.
4860 (HARD_FRAME_POINTER_REGNUM): Remove.
4861 (return): Delete.
4862 (*rts): Rename. Remove epilogue related checks.
4863 (cmpsi, cmpdi): New insn.
4864 (cbranch<mode>4): Change to apply to SI and DI modes as well.
4865 (mov<mode>): Change constraints to enforce that push/pop
4866 destination cannot use the same register as source.
4867 (*mov<mode><cc_cc>): Ditto.
4868 (movmemhi, movmemhi1, movmemhi_nocc): Change to expand block move
4869 at assembly output rather than as RTL expander.
4870 (zero_extendqihi2): Bugfix in check for same registers.
4871 (adddi3_nocc): Bugfix in check for constant operand.
4872 (addsi3_nocc): Ditto.
4873 (subdi3_nocc): Ditto.
4874 (subsi3_nocc): Ditto.
4875 (negdi2_nocc): Copy input to pdp11_expand_operands.
4876 (negsi2_nocc): Ditto.
4877 (bswap2_nocc): Ditto.
4878 * config/pdp11/pdp11.opt (mlra): Fix documentation.
4879 * config/pdp11/t-pdp11: Use -Os.
4880
4881 2018-11-08 Richard Earnshaw <rearnsha@arm.com>
4882
4883 * config/arm/parsecpu.awk (/alias/): New parsing rule.
4884 (/begin cpu/): Check that the cpu name hasn't been previously defined.
4885 (gen_comm_data): Print out CPU alias tables.
4886 (check_cpu): Match aliases when checking the CPU name.
4887 * config/arm/arm-protos.h (cpu_alias): New structure.
4888 (cpu_option): Add entry for aliases.
4889 * config/arm/arm-cpus.in (strongarm): Add aliases for strongarm110
4890 strongarm1100 and strongarm1110.
4891 (strongarm110, strongarm1100, strongarm1110): Delete CPU entries.
4892 (config/arm/arm-generic.md): Remove redundant references to
4893 strongarm110, strongarm1100 and strongarm1110.
4894 * common/config/arm/arm-common.c (arm_print_hint_for_cpu_option):
4895 Scan aliases for additional hints.
4896 (arm_parse_cpu_option_name): Also match a cpu name against the list
4897 of aliases.
4898 * config/arm/arm-tables.opt: Regenerated.
4899 * config/arm/arm-tune.md: Regenerated.
4900
4901 2018-11-08 Jakub Jelinek <jakub@redhat.com>
4902
4903 * builtin-types.def (BT_FN_VOID_BOOL, BT_FN_VOID_SIZE_SIZE_PTR,
4904 BT_FN_UINT_UINT_PTR_PTR, BT_FN_UINT_OMPFN_PTR_UINT_UINT,
4905 BT_FN_BOOL_UINT_LONGPTR_LONG_LONG_LONGPTR_LONGPTR_PTR_PTR,
4906 BT_FN_BOOL_UINT_ULLPTR_LONG_ULL_ULLPTR_ULLPTR_PTR_PTR,
4907 BT_FN_BOOL_LONG_LONG_LONG_LONG_LONG_LONGPTR_LONGPTR_PTR_PTR,
4908 BT_FN_BOOL_BOOL_ULL_ULL_ULL_LONG_ULL_ULLPTR_ULLPTR_PTR_PTR): New.
4909 * gengtype.c (open_base_files): Add omp-general.h.
4910 * gimple.c (gimple_build_omp_critical):
4911 (gimple_build_omp_taskgroup): Add CLAUSES argument. Call
4912 gimple_omp_taskgroup_set_clauses.
4913 (gimple_build_omp_atomic_load): Add mo argument, call
4914 gimple_omp_atomic_set_memory_order.
4915 (gimple_build_omp_atomic_store): Likewise.
4916 (gimple_copy): Adjust handling of GIMPLE_OMP_TASKGROUP.
4917 * gimple.def (GIMPLE_OMP_TASKGROUP): Use GSS_OMP_SINGLE_LAYOUT
4918 instead of GSS_OMP.
4919 (GIMPLE_OMP_TEAMS): Use GSS_OMP_PARALLEL_LAYOUT instead
4920 of GSS_OMP_SINGLE_LAYOUT, adjust comments.
4921 * gimple.h (enum gf_mask): Add GF_OMP_TEAMS_HOST, GF_OMP_TASK_TASKWAIT
4922 and GF_OMP_ATOMIC_MEMORY_ORDER. Remove GF_OMP_ATOMIC_SEQ_CST, use
4923 different value for GF_OMP_ATOMIC_NEED_VALUE.
4924 (struct gimple_statement_omp_taskreg): Add GIMPLE_OMP_TEAMS to
4925 comments.
4926 (struct gimple_statement_omp_single_layout): And remove here.
4927 (struct gomp_teams): Inherit from gimple_statement_omp_taskreg rather
4928 than gimple_statement_omp_single_layout.
4929 (is_a_helper <gimple_statement_omp_taskreg *>::test): Allow
4930 GIMPLE_OMP_TEAMS.
4931 (is_a_helper <const gimple_statement_omp_taskreg *>::test): Likewise.
4932 (gimple_omp_subcode): Formatting fix.
4933 (gimple_omp_teams_child_fn, gimple_omp_teams_child_fn_ptr,
4934 gimple_omp_teams_set_child_fn, gimple_omp_teams_data_arg,
4935 gimple_omp_teams_data_arg_ptr, gimple_omp_teams_set_data_arg,
4936 gimple_omp_teams_host, gimple_omp_teams_set_host,
4937 gimple_omp_task_taskwait_p, gimple_omp_task_set_taskwait_p,
4938 gimple_omp_taskgroup_clauses, gimple_omp_taskgroup_clauses_ptr,
4939 gimple_omp_taskgroup_set_clauses): New inline functions.
4940 (gimple_build_omp_atomic_load): Add enum omp_memory_order argument.
4941 (gimple_build_omp_atomic_store): Likewise.
4942 (gimple_omp_atomic_seq_cst_p): Remove.
4943 (gimple_omp_atomic_memory_order): New function.
4944 (gimple_omp_atomic_set_seq_cst): Remove.
4945 (gimple_omp_atomic_set_memory_order): New function.
4946 (gimple_build_omp_taskgroup): Add clauses argument.
4947 * gimple-pretty-print.c (dump_gimple_omp_taskgroup): New function.
4948 (dump_gimple_omp_task): Print taskwait with depend clauses.
4949 (dump_gimple_omp_atomic_load, dump_gimple_omp_atomic_store): Use
4950 dump_omp_atomic_memory_order.
4951 (pp_gimple_stmt_1): Handle GIMPLE_OMP_TASKGROUP.
4952 * gimplify.c (enum gimplify_omp_var_data): Add GOVD_MAP_ALLOC_ONLY,
4953 GOVD_MAP_FROM_ONLY and GOVD_NONTEMPORAL.
4954 (enum omp_region_type): Reserve bits 1 and 2 for auxiliary flags,
4955 renumber values of most of ORT_* enumerators, add ORT_HOST_TEAMS,
4956 ORT_COMBINED_HOST_TEAMS, ORT_TASKGROUP, ORT_TASKLOOP and
4957 ORT_UNTIED_TASKLOOP enumerators.
4958 (enum gimplify_defaultmap_kind): New.
4959 (struct gimplify_omp_ctx): Remove target_map_scalars_firstprivate and
4960 target_map_pointers_as_0len_arrays members, add defaultmap.
4961 (new_omp_context): Initialize defaultmap member.
4962 (gimple_add_tmp_var): Handle ORT_TASKGROUP like ORT_WORKSHARE.
4963 (maybe_fold_stmt): Don't fold even in host teams regions.
4964 (omp_firstprivatize_variable): Handle ORT_TASKGROUP like
4965 ORT_WORKSHARE. Test ctx->defaultmap[GDMK_SCALAR] instead of
4966 ctx->omp_firstprivatize_variable.
4967 (omp_add_variable): Don't add private/firstprivate for VLAs in
4968 ORT_TASKGROUP.
4969 (omp_default_clause): Print "taskloop" rather than "task" if
4970 ORT_*TASKLOOP.
4971 (omp_notice_variable): Handle ORT_TASKGROUP like ORT_WORKSHARE.
4972 Handle new defaultmap clause kinds.
4973 (omp_is_private): Handle ORT_TASKGROUP like ORT_WORKSHARE. Allow simd
4974 iterator to be lastprivate or private. Fix up diagnostics if linear
4975 is used on collapse>1 simd iterator.
4976 (omp_check_private): Handle ORT_TASKGROUP like ORT_WORKSHARE.
4977 (gimplify_omp_depend): New function.
4978 (gimplify_scan_omp_clauses): Add shared clause on parallel for
4979 combined parallel master taskloop{, simd} if taskloop has
4980 firstprivate, lastprivate or reduction clause. Handle
4981 OMP_CLAUSE_REDUCTION_TASK diagnostics. Adjust tests for
4982 ORT_COMBINED_TEAMS. Gimplify depend clauses with iterators. Handle
4983 cancel and simd OMP_CLAUSE_IF_MODIFIERs. Handle
4984 OMP_CLAUSE_NONTEMPORAL. Handle new defaultmap clause kinds. Handle
4985 OMP_CLAUSE_{TASK,IN}_REDUCTION. Diagnose invalid conditional
4986 lastprivate.
4987 (gimplify_adjust_omp_clauses_1): Ignore GOVD_NONTEMPORAL. Handle
4988 GOVD_MAP_ALLOC_ONLY and GOVD_MAP_FROM_ONLY.
4989 (gimplify_adjust_omp_clauses): Handle OMP_CLAUSE_NONTEMPORAL. Handle
4990 OMP_CLAUSE_{TASK,IN}_REDUCTION.
4991 (gimplify_omp_task): Handle taskwait with depend clauses.
4992 (gimplify_omp_for): Add shared clause on parallel for combined
4993 parallel master taskloop{, simd} if taskloop has firstprivate,
4994 lastprivate or reduction clause. Use ORT_TASKLOOP or
4995 ORT_UNTIED_TASKLOOP instead of ORT_TASK or ORT_UNTIED_TASK. Adjust
4996 tests for ORT_COMBINED_TEAMS. Handle C++ range for loops with
4997 NULL TREE_PURPOSE in OMP_FOR_ORIG_DECLS. Firstprivatize
4998 __for_end and __for_range temporaries on OMP_PARALLEL for
4999 distribute parallel for{, simd}. Move OMP_CLAUSE_REDUCTION
5000 and OMP_CLAUSE_IN_REDUCTION from taskloop to the task construct
5001 sandwiched in between two taskloops.
5002 (computable_teams_clause): Test ctx->defaultmap[GDMK_SCALAR]
5003 instead of ctx->omp_firstprivatize_variable.
5004 (gimplify_omp_workshare): Set ort to ORT_HOST_TEAMS or
5005 ORT_COMBINED_HOST_TEAMS if not inside of target construct. If
5006 host teams, use gimplify_and_return_first etc. for body like
5007 for target or target data constructs, and at the end call
5008 gimple_omp_teams_set_host on the GIMPLE_OMP_TEAMS object.
5009 (gimplify_omp_atomic): Use OMP_ATOMIC_MEMORY_ORDER instead
5010 of OMP_ATOMIC_SEQ_CST, pass it as new argument to
5011 gimple_build_omp_atomic_load and gimple_build_omp_atomic_store, remove
5012 gimple_omp_atomic_set_seq_cst calls.
5013 (gimplify_expr) <case OMP_TASKGROUP>: Move handling into a separate
5014 case, handle taskgroup clauses.
5015 * lto-streamer-out.c (hash_tree): Handle
5016 OMP_CLAUSE_{TASK,IN}_REDUCTION.
5017 * Makefile.in (GTFILES): Add omp-general.h.
5018 * omp-builtins.def (BUILT_IN_GOMP_TASKWAIT_DEPEND,
5019 BUILT_IN_GOMP_LOOP_NONMONOTONIC_RUNTIME_START,
5020 BUILT_IN_GOMP_LOOP_MAYBE_NONMONOTONIC_RUNTIME_START,
5021 BUILT_IN_GOMP_LOOP_START, BUILT_IN_GOMP_LOOP_ORDERED_START,
5022 BUILT_IN_GOMP_LOOP_DOACROSS_START,
5023 BUILT_IN_GOMP_LOOP_NONMONOTONIC_RUNTIME_NEXT,
5024 BUILT_IN_GOMP_LOOP_MAYBE_NONMONOTONIC_RUNTIME_NEXT,
5025 BUILT_IN_GOMP_LOOP_ULL_NONMONOTONIC_RUNTIME_START,
5026 BUILT_IN_GOMP_LOOP_ULL_MAYBE_NONMONOTONIC_RUNTIME_START,
5027 BUILT_IN_GOMP_LOOP_ULL_START, BUILT_IN_GOMP_LOOP_ULL_ORDERED_START,
5028 BUILT_IN_GOMP_LOOP_ULL_DOACROSS_START,
5029 BUILT_IN_GOMP_LOOP_ULL_NONMONOTONIC_RUNTIME_NEXT,
5030 BUILT_IN_GOMP_LOOP_ULL_MAYBE_NONMONOTONIC_RUNTIME_NEXT,
5031 BUILT_IN_GOMP_PARALLEL_LOOP_NONMONOTONIC_RUNTIME,
5032 BUILT_IN_GOMP_PARALLEL_LOOP_MAYBE_NONMONOTONIC_RUNTIME,
5033 BUILT_IN_GOMP_PARALLEL_REDUCTIONS, BUILT_IN_GOMP_SECTIONS2_START,
5034 BUILT_IN_GOMP_TEAMS_REG, BUILT_IN_GOMP_TASKGROUP_REDUCTION_REGISTER,
5035 BUILT_IN_GOMP_TASKGROUP_REDUCTION_UNREGISTER,
5036 BUILT_IN_GOMP_TASK_REDUCTION_REMAP,
5037 BUILT_IN_GOMP_WORKSHARE_TASK_REDUCTION_UNREGISTER): New builtins.
5038 * omp-expand.c (workshare_safe_to_combine_p): Return false for
5039 non-worksharing loops.
5040 (omp_adjust_chunk_size): Don't adjust anything if chunk_size is zero.
5041 (determine_parallel_type): Don't combine parallel with worksharing
5042 which has _reductemp_ clause.
5043 (expand_parallel_call): Emit the GOMP_*nonmonotonic_runtime* or
5044 GOMP_*maybe_nonmonotonic_runtime* builtins instead of GOMP_*runtime*
5045 if there is nonmonotonic modifier or if there is no modifier and no
5046 ordered clause. For dynamic and guided schedule without monotonic
5047 and nonmonotonic modifier, default to nonmonotonic.
5048 (expand_omp_for): Likewise. Adjust expand_omp_for_generic caller, use
5049 GOMP_loop{,_ull}{,_ordered,_doacross}_start builtins if there are
5050 task reductions.
5051 (expand_task_call): Add GOMP_TASK_FLAG_REDUCTION flag to flags if
5052 there are any reduction clauses.
5053 (expand_taskwait_call): New function.
5054 (expand_teams_call): New function.
5055 (expand_omp_taskreg): Allow GIMPLE_OMP_TEAMS and call
5056 expand_teams_call for it. Formatting fix. Handle taskwait with
5057 depend clauses.
5058 (expand_omp_for_generic): Add SCHED_ARG argument. Handle expansion
5059 of worksharing loops with task reductions.
5060 (expand_omp_for_static_nochunk, expand_omp_for_static_chunk): Handle
5061 expansion of worksharing loops with task reductions.
5062 (expand_omp_sections): Handle expansion of sections with task
5063 reductions.
5064 (expand_omp_synch): For host teams call expand_omp_taskreg.
5065 (omp_memory_order_to_memmodel): New function.
5066 (expand_omp_atomic_load, expand_omp_atomic_store,
5067 expand_omp_atomic_fetch_op): Use it and gimple_omp_atomic_memory_order
5068 instead of gimple_omp_atomic_seq_cst_p.
5069 (build_omp_regions_1, omp_make_gimple_edges): Treat taskwait with
5070 depend clauses as a standalone directive.
5071 * omp-general.c (enum omp_requires): New variable.
5072 (omp_extract_for_data): Initialize have_reductemp member. Allow
5073 NE_EXPR even in OpenMP loops, transform them into LT_EXPR or
5074 GT_EXPR loops depending on incr sign. Formatting fixes.
5075 * omp-general.h (struct omp_for_data): Add have_reductemp member.
5076 (enum omp_requires): New enum.
5077 (omp_requires_mask): Declare.
5078 * omp-grid.c (grid_eliminate_combined_simd_part): Formatting fix.
5079 Fix comment typos.
5080 * omp-low.c (struct omp_context): Add task_reductions and
5081 task_reduction_map fields.
5082 (is_host_teams_ctx): New function.
5083 (is_taskreg_ctx): Return true also if is_host_teams_ctx.
5084 (use_pointer_for_field): Use is_global_var instead of
5085 TREE_STATIC || DECL_EXTERNAL, and apply only if not privatized
5086 in outer contexts.
5087 (build_outer_var_ref): Ignore taskgroup outer contexts.
5088 (delete_omp_context): Release task_reductions and task_reduction_map.
5089 (scan_sharing_clauses): Don't add any fields for reduction clause on
5090 taskloop. Handle OMP_CLAUSE__REDUCTEMP_. Handle
5091 OMP_CLAUSE_{IN,TASK}_REDUCTION and OMP_CLAUSE_REDUCTION with task
5092 modifier. Don't ignore shared clauses in is_host_teams_ctx contexts.
5093 Handle OMP_CLAUSE_NONTEMPORAL.
5094 (add_taskreg_looptemp_clauses): Add OMP_CLAUSE__REDUCTEMP_ clause if
5095 needed.
5096 (scan_omp_parallel): Add _reductemp_ clause if there are any reduction
5097 clauses with task modifier.
5098 (scan_omp_task): Handle taskwait with depend clauses.
5099 (finish_taskreg_scan): Move field corresponding to _reductemp_ clause
5100 first. Move also OMP_CLAUSE__REDUCTEMP_ clause in front if present.
5101 Handle GIMPLE_OMP_TEAMS like GIMPLE_OMP_PARALLEL.
5102 (scan_omp_for): Fix comment formatting.
5103 (scan_omp_teams): Handle host teams constructs.
5104 (check_omp_nesting_restrictions): Allow teams with no outer
5105 OpenMP context. Adjust diagnostics for teams strictly nested into
5106 some explicit OpenMP construct other than target. Allow OpenMP atomics
5107 inside of simd regions.
5108 (scan_omp_1_stmt): Call scan_sharing_clauses for taskgroups.
5109 (scan_omp_1_stmt) <case GIMPLE_OMP_TEAMS>: Temporarily bump
5110 taskreg_nesting_level while scanning host teams construct.
5111 (task_reduction_read): New function.
5112 (lower_rec_input_clauses): Handle OMP_CLAUSE_REDUCTION on taskloop
5113 construct. Handle OMP_CLAUSE_IN_REDUCTION and OMP_CLAUSE__REDUCTEMP_
5114 clauses. Handle OMP_CLAUSE_REDUCTION with task modifier. Remove
5115 second argument create_tmp_var if it is NULL. Don't ignore shared
5116 clauses in is_host_teams_ctx contexts. Handle
5117 OMP_CLAUSE_FIRSTPRIVATE_NO_REFERENCE on OMP_CLAUSE_FIRSTPRIVATE
5118 clauses.
5119 (lower_reduction_clauses): Ignore reduction clauses with task
5120 modifier. Remove second argument create_tmp_var if it is NULL.
5121 Initialize OMP_ATOMIC_MEMORY_ORDER to relaxed.
5122 (lower_send_clauses): Ignore reduction clauses with task modifier.
5123 Handle OMP_CLAUSE__REDUCTEMP_. Don't send anything for
5124 OMP_CLAUSE_REDUCTION on taskloop. Handle OMP_CLAUSE_IN_REDUCTION.
5125 (maybe_add_implicit_barrier_cancel): Add OMP_RETURN argument, don't
5126 rely that it is the last stmt in body so far. Ignore outer taskgroup
5127 contexts.
5128 (omp_task_reductions_find_first, omp_task_reduction_iterate,
5129 lower_omp_task_reductions): New functions.
5130 (lower_omp_sections): Handle reduction clauses with taskgroup
5131 modifiers. Adjust maybe_add_implicit_barrier_cancel caller.
5132 (lower_omp_single): Adjust maybe_add_implicit_barrier_cancel caller.
5133 (lower_omp_for): Likewise. Handle reduction clauses with taskgroup
5134 modifiers.
5135 (lower_omp_taskgroup): Handle taskgroup reductions.
5136 (create_task_copyfn): Copy over OMP_CLAUSE__REDUCTEMP_ pointer.
5137 Handle OMP_CLAUSE_IN_REDUCTION and OMP_CLAUSE_REDUCTION clauses.
5138 (lower_depend_clauses): If there are any
5139 OMP_CLAUSE_DEPEND_DEPOBJ or OMP_CLAUSE_DEPEND_MUTEXINOUTSET
5140 depend clauses, use a new array format. If OMP_CLAUSE_DEPEND_LAST is
5141 seen, assume lowering is done already and return early. Set kind
5142 on artificial depend clause to OMP_CLAUSE_DEPEND_LAST.
5143 (lower_omp_taskreg): Handle reduction clauses with task modifier on
5144 parallel construct. Handle reduction clause on taskloop construct.
5145 Handle taskwait with depend clauses.
5146 (lower_omp_1): Use lower_omp_taskreg instead of lower_omp_teams
5147 for host teams constructs.
5148 * tree.c (omp_clause_num_ops): Add in_reduction, task_reduction,
5149 nontemporal and _reductemp_ clause entries.
5150 (omp_clause_code_name): Likewise.
5151 (walk_tree_1): Handle OMP_CLAUSE_{IN,TASK}_REDUCTION,
5152 OMP_CLAUSE_NONTEMPORAL and OMP_CLAUSE__REDUCTEMP_.
5153 * tree-core.h (enum omp_clause_code): Add
5154 OMP_CLAUSE_{{IN,TASK}_REDUCTION,NONTEMPORAL,_REDUCTEMP_}.
5155 (enum omp_clause_defaultmap_kind, enum omp_memory_order): New.
5156 (struct tree_base): Add omp_atomic_memory_order field into union.
5157 Remove OMP_ATOMIC_SEQ_CST comment.
5158 (enum omp_clause_depend_kind): Add OMP_CLAUSE_DEPEND_MUTEXINOUTSET
5159 and OMP_CLAUSE_DEPEND_DEPOBJ.
5160 (struct tree_omp_clause): Add subcode.defaultmap_kind.
5161 * tree.def (OMP_TASKGROUP): Add another operand, move next to other
5162 OpenMP constructs with body and clauses operands.
5163 * tree.h (OMP_BODY): Use OMP_MASTER instead of OMP_TASKGROUP.
5164 (OMP_CLAUSES): Use OMP_TASKGROUP instead of OMP_SINGLE.
5165 (OMP_TASKGROUP_CLAUSES): Define.
5166 (OMP_CLAUSE_DECL): Use OMP_CLAUSE__REDUCTEMP_ instead of
5167 OMP_CLAUSE__LOOPTEMP_.
5168 (OMP_ATOMIC_SEQ_CST): Remove.
5169 (OMP_ATOMIC_MEMORY_ORDER, OMP_CLAUSE_FIRSTPRIVATE_NO_REFERENCE,
5170 OMP_CLAUSE_LASTPRIVATE_CONDITIONAL): Define.
5171 (OMP_CLAUSE_REDUCTION_CODE, OMP_CLAUSE_REDUCTION_INIT,
5172 OMP_CLAUSE_REDUCTION_MERGE, OMP_CLAUSE_REDUCTION_PLACEHOLDER,
5173 OMP_CLAUSE_REDUCTION_DECL_PLACEHOLDER,
5174 OMP_CLAUSE_REDUCTION_OMP_ORIG_REF): Handle
5175 OMP_CLAUSE_{,IN_,TASK_}REDUCTION.
5176 (OMP_CLAUSE_REDUCTION_TASK, OMP_CLAUSE_REDUCTION_INSCAN,
5177 OMP_CLAUSE_DEFAULTMAP_KIND, OMP_CLAUSE_DEFAULTMAP_CATEGORY,
5178 OMP_CLAUSE_DEFAULTMAP_BEHAVIOR, OMP_CLAUSE_DEFAULTMAP_SET_KIND):
5179 Define.
5180 * tree-inline.c (remap_gimple_stmt): Remap taskgroup clauses.
5181 * tree-nested.c (convert_nonlocal_omp_clauses): Handle
5182 OMP_CLAUSE__REDUCTEMP_, OMP_CLAUSE_NONTEMPORAL.
5183 (convert_local_omp_clauses): Likewise. Remove useless test.
5184 * tree-parloops.c (create_call_for_reduction_1): Pass
5185 OMP_MEMORY_ORDER_RELAXED as new argument to
5186 dump_gimple_omp_atomic_load and dump_gimple_omp_atomic_store.
5187 * tree-pretty-print.c (dump_omp_iterators): New function.
5188 (dump_omp_clause): Handle OMP_CLAUSE__REDUCTEMP_,
5189 OMP_CLAUSE_NONTEMPORAL, OMP_CLAUSE_{TASK,IN}_REDUCTION. Print
5190 reduction modifiers. Handle OMP_CLAUSE_DEPEND_DEPOBJ and
5191 OMP_CLAUSE_DEPEND_MUTEXINOUTSET. Print iterators in depend clauses.
5192 Print __internal__ for OMP_CLAUSE_DEPEND_LAST. Handle cancel and
5193 simd OMP_CLAUSE_IF_MODIFIERs. Handle new kinds of
5194 OMP_CLAUSE_DEFAULTMAP. Print conditional: for
5195 OMP_CLAUSE_LASTPRIVATE_CONDITIONAL.
5196 (dump_omp_atomic_memory_order): New function.
5197 (dump_generic_node): Use it. Print taskgroup clauses. Print
5198 taskwait with depend clauses.
5199 * tree-pretty-print.h (dump_omp_atomic_memory_order): Declare.
5200 * tree-streamer-in.c (unpack_ts_omp_clause_value_fields):
5201 Handle OMP_CLAUSE_{TASK,IN}_REDUCTION.
5202 * tree-streamer-out.c (pack_ts_omp_clause_value_fields,
5203 write_ts_omp_clause_tree_pointers): Likewise.
5204
5205 2018-11-08 David Malcolm <dmalcolm@redhat.com>
5206
5207 PR ipa/86395
5208 * doc/invoke.texi (-fdump-ipa-): Document the "-optimized",
5209 "-missed", "-note", and "-all" sub-options.
5210 * ipa-inline.c (caller_growth_limits): Port from fprintf to dump
5211 API.
5212 (can_early_inline_edge_p): Likewise.
5213 (want_early_inline_function_p): Likewise.
5214 (want_inline_self_recursive_call_p): Likewise.
5215 (recursive_inlining): Likewise.
5216 (inline_small_functions): Likewise.
5217 (flatten_function): Likewise.
5218 (ipa_inline): Likewise.
5219 (inline_always_inline_functions): Likewise.
5220 (early_inline_small_functions): Likewise.
5221 (early_inliner): Likewise.
5222 * tree-inline.c (expand_call_inline): Likewise.
5223
5224 2018-11-08 David Malcolm <dmalcolm@redhat.com>
5225
5226 * pretty-print.c (pp_format): Handle %f.
5227 (selftest::test_pp_format): Add test of %f.
5228 * pretty-print.h (pp_double): New macro.
5229
5230 2018-11-08 David Malcolm <dmalcolm@redhat.com>
5231
5232 * dump-context.h (ASSERT_IS_CGRAPH_NODE): New macro.
5233 * dumpfile.c (make_item_for_dump_cgraph_node): Move to before...
5234 (dump_pretty_printer::decode_format): Implement "%C" for
5235 cgraph_node *.
5236 (selftest::test_capture_of_dump_calls): Rename "where" to
5237 "stmt_loc". Convert test_decl to a function decl and set its
5238 location. Add a symbol_table_test RAII instance and a
5239 cgraph_node, using it to test "%C" and dump_symtab_node.
5240
5241 2018-11-08 Eric Botcazou <ebotcazou@adacore.com>
5242
5243 PR middle-end/87916
5244 * cgraphclones.c (duplicate_thunk_for_node): Also set DECL_IGNORED_P.
5245
5246 2018-11-08 David Malcolm <dmalcolm@redhat.com>
5247
5248 * cgraph.c: Include "selftest.h".
5249 (saved_symtab): New variable.
5250 (selftest::symbol_table_test::symbol_table_test): New ctor.
5251 (selftest::symbol_table_test::~symbol_table_test): New dtor.
5252 (selftest::test_symbol_table_test): New test.
5253 (selftest::cgraph_c_tests): New.
5254 * cgraph.h (saved_symtab): New decl.
5255 (selftest::symbol_table_test): New class.
5256 * selftest-run-tests.c (selftest::run_tests): Call
5257 selftest::cgraph_c_tests.
5258 * selftest.h (selftest::cgraph_c_tests): New decl.
5259
5260 2018-11-08 Richard Biener <rguenther@suse.de>
5261
5262 * tree-data-ref.h (lambda_int): New typedef.
5263 (lambda_vector_gcd): Adjust.
5264 (lambda_vector_new): Likewise.
5265 (lambda_matrix_new): Likewise.
5266 * tree-data-ref.c (print_lambda_vector): Adjust.
5267
5268 2018-11-08 Richard Biener <rguenther@suse.de>
5269
5270 PR tree-optimization/87929
5271 * tree-complex.c (expand_complex_comparison): Clean EH.
5272
5273 2018-11-08 Martin Liska <mliska@suse.cz>
5274
5275 * doc/extend.texi: Reword.
5276 * predict.c (expr_expected_value_1): Likewise.
5277
5278 2018-11-08 Richard Biener <rguenther@suse.de>
5279
5280 PR tree-optimization/87913
5281 * tree-ssa-phiopt.c (minmax_replacement): Turn EQ/NE compares
5282 of extreme values to ordered comparisons.
5283
5284 2018-11-07 Sandra Loosemore <sandra@codesourcery.com>
5285
5286 PR middle-end/42726
5287 * doc/invoke.texi (Code Gen Options): Clarify -fno-common behavior.
5288
5289 2018-11-07 Sandra Loosemore <sandra@codesourcery.com>
5290
5291 * doc/invoke.texi: Remove leading dash from @opindex entries
5292 throughout the file.
5293
5294 2018-11-07 Sandra Loosemore <sandra@codesourcery.com>
5295
5296 PR driver/80828
5297 * doc/invoke.texi (Option Summary): Add -e and --entry.
5298 (Link Options): Likewise.
5299
5300 2018-11-07 Nathan Sidwell <nathan@acm.org>
5301
5302 PR 87926
5303 * Makefile.in (bitmap.o-warn): Add -Wno-error to unbreak
5304 --disable-checking bootstrap.
5305
5306 2018-11-07 Hafiz Abid Qadeer <abidh@codesourcery.com>
5307
5308 * configure: Regenerated.
5309
5310 2018-11-07 Jozef Lawrynowicz <jozef.l@mittosystems.com>
5311
5312 PR c/87691
5313 * stor-layout.c (compute_record_mode): Set TYPE_MODE of UNION_TYPE
5314 to the mode of the widest field iff the widest field has mode class
5315 MODE_INT, or MODE_PARTIAL_INT and the union would be passed by
5316 reference.
5317
5318 2018-11-07 Nikolai Merinov <n.merinov@inango-systems.com>
5319
5320 * common.opt: Add -Wattribute-warning.
5321 * doc/invoke.texi: Add documentation for -Wno-attribute-warning.
5322 * expr.c (expand_expr_real_1): Add new attribute to warning_at
5323 call to allow user configure behavior of "warning" attribute.
5324
5325 2018-11-07 Segher Boessenkool <segher@kernel.crashing.org>
5326
5327 * target.def: Put @: after every vs., e.g., and i.e. where it is
5328 followed by whitespace.
5329 * doc/extend.texi: Ditto.
5330 * doc/fragments.texi: Ditto.
5331 * doc/gimple.texi: Ditto.
5332 * doc/implement-c.texi: Ditto.
5333 * doc/install.texi: Ditto.
5334 * doc/invoke.texi: Ditto.
5335 * doc/md.texi: Ditto.
5336 * doc/plugins.texi: Ditto.
5337 * doc/rtl.texi: Ditto.
5338 * doc/sourcebuild.texi: Ditto.
5339 * doc/tm.texi.in: Ditto.
5340 * doc/ux.texi: Ditto.
5341 * doc/tm.texi: Regenerate.
5342
5343 2018-11-07 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
5344
5345 * config/arm/arm-cpus.in (ares): New entry.
5346 * config/arm/arm-tables.opt: Regenerate.
5347 * config/arm/arm-tune.md: Likewise.
5348 * doc/invoke.texi (ARM Options): Document ares.
5349
5350 2018-11-07 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
5351
5352 * config/aarch64/aarch64-cores.def (ares): Define.
5353 * config/aarch64/aarch64-tune.md: Regenerate.
5354 * doc/invoke.texi (AArch64 Options): Document ares value for mtune.
5355
5356 2018-11-07 Jan Hubicka <jh@suse.cz>
5357
5358 * tree.c (fld_incomplete_type_of): Clear TREE_ADDRESSABLE.
5359 (free_lang_data_in_decl): Set TREE_ADDRESSABLE for public vars and
5360 functions; clear TYPE_DECL_SUPPRESS_DEBUG and DECL_MODE for
5361 TYPE_DECL.
5362
5363 2018-11-07 Richard Biener <rguenther@suse.de>
5364
5365 PR tree-optimization/87914
5366 * tree-vect-loop.c (vect_is_simple_reduction): Improve detection
5367 of nested cycles.
5368 (vectorizable_reduction): Handle shifts and rotates by dispatching
5369 to vectorizable_shift.
5370 * tree-vect-stmts.c (vect_get_vec_def_for_operand_1): Handle
5371 in-loop uses of vect_nested_cycle defs. Merge cycle and internal
5372 def cases.
5373 (vectorizable_shift): Export and handle being called as
5374 vect_nested_cycle.
5375 (vect_analyze_stmt): Call vectorizable_shift after
5376 vectorizable_reduction.
5377 * tree-vectorizer.h (vectorizable_shift): Declare.
5378
5379 2018-11-07 Jan Hubicka <jh@suse.cz>
5380
5381 * ipa-devirt.c (odr_types_equivalent_p): Expect constants
5382 than const decls in TREE_VALUE of enum.
5383 (dump_type_inheritance_graph): Improve duplicate dumping.
5384 (free_enum_values): New.
5385 (build_type_inheritance_graph): Use it.
5386 * tree.c (free_lang_data_in_type): Free TYPE_VALUES of enums
5387 which are not main variants or not ODR types.
5388 (verify_type_variant): Expect variants to have no TYPE_VALUES.
5389
5390 2018-11-07 Richard Biener <rguenther@suse.de>
5391
5392 * ipa-inline.c (want_inline_small_function_p): Compute
5393 big_speedup_p lazily and last.
5394
5395 2018-11-07 Jan Hubicka <jh@suse.cz>
5396
5397 * tree.c (fld_type_variant_equal_p): Skip TYPE_ALIGN check when
5398 building incomplete variant of complete type.
5399 (fld_type_variant): Do not copy TYPE_ALIGN when building incomplete
5400 variant of complete type.
5401
5402 2018-11-07 Chenghua Xu <paul.hua.gm@gmail.com>
5403
5404 * config/mips/mips.c: Fix typo in documentation of
5405 mips_loongson_ext2_prefetch_cookie.
5406 (mips_option_override): fix brain twister logical.
5407 * config/mips/mips.h: Fix typo in documentation of
5408 ISA_HAS_CTZ_CTO and define pattern.
5409 * config/mips/mips.md (prefetch): Hoist EXT2 above
5410 the 2EF/EXT block.
5411 (prefetch_indexed): Hoist EXT2 above the EXT block.
5412
5413 2018-11-07 Jan Hubicka <jh@suse.cz>
5414
5415 * tree.c (free_lang_data_in_type): Add fld parameter; simplify
5416 return and parameter types of function and method types.
5417 (free_lang_data_in_cgraph): Update.
5418
5419 2018-11-07 Martin Liska <mliska@suse.cz>
5420
5421 PR rtl-optimization/87868
5422 * postreload-gcse.c (eliminate_partially_redundant_load): Set
5423 threshold to max_count if we would overflow.
5424 * profile-count.h: Make max_count a public constant.
5425
5426 2018-11-07 Martin Liska <mliska@suse.cz>
5427
5428 * mem-stats.h: Fix GNU coding style.
5429
5430 2018-11-07 Chenghua Xu <paul.hua.gm@gmail.com>
5431
5432 * config/mips/gs264e.md: New.
5433 * config/mips/mips-cpus.def: Define gs264e.
5434 * config/mips/mips-tables.opt: Regenerate.
5435 * config/mips/mips.c (mips_rtx_cost_data): Add DEFAULT_COSTS for
5436 gs264e.
5437 (mips_issue_rate): Add support for gs264e.
5438 (mips_multipass_dfa_lookahead): Likewise.
5439 * config/mips/mips.h: Define TARGET_GS264E and TUNE_GS264E.
5440 (MIPS_ISA_LEVEL_SPEC): Infer mips64r2 from gs264e.
5441 (MIPS_ASE_MSA_SPEC): New.
5442 (BASE_DRIVER_SELF_SPECS): march=gs264e implies -mmsa.
5443 (ISA_HAS_FUSED_MADD4): Enable for TARGET_GS264E.
5444 (ISA_HAS_UNFUSED_MADD4): Exclude TARGET_GS264E.
5445 * config/mips/mips.md: Include gs264e.md.
5446 (processor): Add gs264e.
5447 * config/mips/mips.opt (MSA): Use Mask instead of Var.
5448 * doc/invoke.texi: Add gs264e to supported architectures.
5449
5450 2018-11-07 Chenghua Xu <paul.hua.gm@gmail.com>
5451
5452 * config/mips/gs464e.md: New.
5453 * config/mips/mips-cpus.def: Define gs464e.
5454 * config/mips/mips-tables.opt: Regenerate.
5455 * config/mips/mips.c (mips_rtx_cost_data): Add DEFAULT_COSTS for
5456 gs464e.
5457 (mips_issue_rate): Add support for gs464e.
5458 (mips_multipass_dfa_lookahead): Likewise.
5459 (mips_option_override): Enable MMI, EXT and EXT2 for gs464e.
5460 * config/mips/mips.h: Define TARGET_GS464E and TUNE_GS464E.
5461 (MIPS_ISA_LEVEL_SPEC): Infer mips64r2 from gs464e.
5462 (ISA_HAS_FUSED_MADD4): Enable for TARGET_GS464E.
5463 (ISA_HAS_UNFUSED_MADD4): Exclude TARGET_GS464E.
5464 * config/mips/mips.md: Include gs464e.md.
5465 (processor): Add gs464e.
5466 * doc/invoke.texi: Add gs464e to supported architectures.
5467
5468 2018-11-07 Chenghua Xu <paul.hua.gm@gmail.com>
5469
5470 * config/mips/loongson3a.md: Rename to ...
5471 * config/mips/gs464.md: ... here.
5472 * config/mips/mips-cpus.def: Define gs464; Add loongson3a
5473 as an alias of gs464 processor.
5474 * config/mips/mips-tables.opt: Regenerate.
5475 * config/mips/mips.c (mips_issue_rate): Use PROCESSOR_GS464
5476 instead of PROCESSOR_LOONGSON_3A.
5477 (mips_multipass_dfa_lookahead): Use TUNE_GS464 instead of
5478 TUNE_LOONGSON_3A.
5479 (mips_option_override): Enable MMI and EXT for gs464.
5480 * config/mips/mips.h: Rename TARGET_LOONGSON_3A to TARGET_GS464;
5481 Rename TUNE_LOONGSON_3A to TUNE_GS464.
5482 (MIPS_ISA_LEVEL_SPEC): Infer mips64r2 from gs464.
5483 (ISA_HAS_ODD_SPREG, ISA_AVOID_DIV_HILO, ISA_HAS_FUSED_MADD4,
5484 ISA_HAS_UNFUSED_MADD4): Use TARGET_GS464 instead of
5485 TARGET_LOONGSON_3A.
5486 * config/mips/mips.md: Include gs464.md instead of loongson3a.md.
5487 (processor): Add gs464;
5488 * doc/invoke.texi: Add gs464 to supported architectures.
5489
5490 2018-11-07 Chenghua Xu <paul.hua.gm@gmail.com>
5491
5492 * config/mips/mips-protos.h
5493 (mips_loongson_ext2_prefetch_cookie): New prototype.
5494 * config/mips/mips.c (mips_loongson_ext2_prefetch_cookie): New.
5495 (mips_option_override): Enable TARGET_LOONGSON_EXT when
5496 TARGET_LOONGSON_EXT2 is true.
5497 * config/mips/mips.h (TARGET_CPU_CPP_BUILTINS): Define
5498 __mips_loongson_ext2, __mips_loongson_ext_rev=2.
5499 (ISA_HAS_CTZ_CTO): New, true if TARGET_LOONGSON_EXT2.
5500 (ISA_HAS_PREFETCH): Include TARGET_LOONGSON_EXT and
5501 TARGET_LOONGSON_EXT2.
5502 (ASM_SPEC): Add mloongson-ext2 and mno-loongson-ext2.
5503 (define_insn "ctz<mode>2"): New insn pattern.
5504 (define_insn "prefetch"): Include TARGET_LOONGSON_EXT2.
5505 (define_insn "prefetch_indexed_<mode>"): Include
5506 TARGET_LOONGSON_EXT and TARGET_LOONGSON_EXT2.
5507 * config/mips/mips.opt (-mloongson-ext2): Add option.
5508 * gcc/doc/invoke.texi (-mloongson-ext2): Document.
5509
5510 2018-11-07 Chenghua Xu <paul.hua.gm@gmail.com>
5511
5512 * config/mips/mips.h (TARGET_CPU_CPP_BUILTINS): Add
5513 __mips_loongson_ext.
5514 (MIPS_ASE_LOONGSON_EXT_SPEC): New.
5515 (BASE_DRIVER_SELF_SPECS): march=loongson3a implies
5516 -mloongson-ext.
5517 (ASM_SPEC): Add mloongson-ext and mno-loongson-ext.
5518 * config/mips/mips.md (mul<mode>3, mul<mode>3_mul3_nohilo,
5519 <u>div<mode>3, <u>mod<mode>3, prefetch): Use TARGET_LOONGSON_EXT
5520 instead of TARGET_LOONGSON_3A.
5521 * config/mips/mips.opt (-mloongson-ext): Add option.
5522 * gcc/doc/invoke.texi (-mloongson-ext): Document.
5523
5524 2018-11-07 Chenghua Xu <paul.hua.gm@gmail.com>
5525
5526 * config.gcc (extra_headers): Add loongson-mmiintrin.h.
5527 * config/mips/loongson.md: Move to ...
5528 * config/mips/loongson-mmi.md: here; Adjustment.
5529 * config/mips/loongson.h: Move to ...
5530 State as deprecated. Include loongson-mmiintrin.h for back
5531 compatibility and warning.
5532 * config/mips/loongson-mmiintrin.h: ... here.
5533 * config/mips/mips.c (mips_hard_regno_mode_ok_uncached,
5534 mips_vector_mode_supported_p, AVAIL_NON_MIPS16): Use
5535 TARGET_LOONGSON_MMI instead of TARGET_LOONGSON_VECTORS.
5536 (mips_option_override): Make sure MMI use hard float;
5537 (mips_shift_truncation_mask, mips_expand_vpc_loongson_even_odd,
5538 mips_expand_vpc_loongson_pshufh, mips_expand_vpc_loongson_bcast,
5539 mips_expand_vector_init): Use TARGET_LOONGSON_MMI instead of
5540 TARGET_LOONGSON_VECTORS.
5541 * gcc/config/mips/mips.h (TARGET_LOONGSON_VECTORS): Delete.
5542 (TARGET_CPU_CPP_BUILTINS): Add __mips_loongson_mmi.
5543 (MIPS_ASE_DSP_SPEC, MIPS_ASE_LOONGSON_MMI_SPEC): New.
5544 (BASE_DRIVER_SELF_SPECS): march=loongson2e/2f/3a implies
5545 -mloongson-mmi.
5546 (SHIFT_COUNT_TRUNCATED): Use TARGET_LOONGSON_MMI instead of
5547 TARGET_LOONGSON_VECTORS.
5548 * gcc/config/mips/mips.md (MOVE64, MOVE128): Use
5549 TARGET_LOONGSON_MMI instead of TARGET_LOONGSON_VECTORS.
5550 (Loongson MMI patterns): Include loongson-mmi.md instead of
5551 loongson.md.
5552 * gcc/config/mips/mips.opt (-mloongson-mmi): New option.
5553 * gcc/doc/invoke.texi (-mloongson-mmi): Document.
5554
5555 2018-11-07 Richard Biener <rguenther@suse.de>
5556
5557 PR lto/87906
5558 * tree-streamer-in.c (lto_input_ts_block_tree_pointers): Fixup
5559 BLOCK_ABSTRACT_ORIGIN to be the ultimate origin.
5560
5561 2018-11-07 Alexandre Oliva <aoliva@redhat.com>
5562
5563 PR rtl-optimization/87874
5564 * lra.c (lra_substitute_pseudo): Do not create a subreg for
5565 const wide ints.
5566
5567 2018-11-06 Aaron Sawdey <acsawdey@linux.ibm.com>
5568
5569 * config/rs6000/rs6000.md (bswap<mode>2): Force address into register
5570 if not in indexed or indirect form.
5571 (bswap<mode>2_load): Change predicate to indexed_or_indirect_operand.
5572 (bswap<mode>2_store): Ditto.
5573
5574 2018-11-06 Richard Earnshaw <rearnsha@arm.com>
5575
5576 * config/aarch64/aarch64.md (speculation_tracker): Set the mode for
5577 the UNSPEC.
5578
5579 2018-11-06 Richard Biener <rguenther@suse.de>
5580
5581 PR tree-optimization/86850
5582 * vec.h (vec<T, va_heap, vl_ptr>::splice): Check src.length ()
5583 instead of src.m_vec.
5584
5585 2018-11-06 Jan Hubicka <jh@suse.cz>
5586
5587 * tree.c (fld_simplified_type_name): Break out form ...
5588 (free_lang_data_in_type): ... here.
5589 (fld_type_variant_equal_p): Use it.
5590
5591 2018-11-06 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
5592
5593 * config/default-d.c: Include memmodel.h.
5594
5595 * config/sol2-d.c: New file.
5596 * config/t-sol2 (sol2-d.o): New rule.
5597 * config.gcc <*-*-solaris2*>: Set d_target_objs,
5598 target_has_targetdm.
5599
5600 2018-11-06 Jan Hubicka <jh@suse.cz>
5601
5602 * tree.c (fld_type_variant): Also copy alignment; be sure that
5603 new variant is equal.
5604
5605 2018-11-06 Ilya Leoshkevich <iii@linux.ibm.com>
5606
5607 PR target/87762
5608 * config/s390/s390.md: Add relative_long attribute.
5609
5610 2018-11-06 Jan Hubicka <jh@suse.cz>
5611
5612 * ipa-pure-const.c (check_decl): Do not test TYPE_NEEDS_CONSTRUCTING.
5613 * lto-streamer-out.c (hash_tree): Do not hash TYPE_NEEDS_CONSTRUCTING.
5614 * tree-streamer-in.c (unpack_ts_type_common_value_fields): Do not
5615 stream TYPE_NEEDS_CONSTRUCTING.
5616 * tree-streamer-out.c (pack_ts_type_common_value_fields): Likewise.
5617 * tree.c (free_lang_data_in_type): Clear TYPE_NEEDS_CONSTRUCTING.
5618
5619 2018-11-06 Richard Biener <rguenther@suse.de>
5620
5621 * tree-vect-slp.c (vect_slp_bb): Move opening of vect_slp_analyze_bb
5622 dump-scope ...
5623 (vect_slp_analyze_bb_1): ... here to avoid hiding optimized locations.
5624
5625 2018-11-06 Jozef Lawrynowicz <jozef.l@mittosystems.com>
5626
5627 * gcc/config/msp430/msp430.h (REG_CLASS_CONTENTS): Add R0 to
5628 REG_CLASS_CONTENTS[GEN_REGS].
5629 (REGNO_REG_CLASS): Return NO_REGS for R2 and R3.
5630
5631 2018-11-06 Jan Hubicka <jh@suse.cz>
5632
5633 * tree.c (fld_simplified_type_of): Clear TYPELESS_STORAGE flag.
5634
5635 2018-11-06 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
5636
5637 PR sanitizer/80953
5638 * config/sol2.h (ASAN_CC1_SPEC): Define.
5639 (LD_WHOLE_ARCHIVE_OPTION): Define.
5640 (LD_NO_WHOLE_ARCHIVE_OPTION): Define.
5641 (ASAN_REJECT_SPEC): Provide default.
5642 (LIBASAN_EARLY_SPEC): Define.
5643 (LIBTSAN_EARLY_SPEC): Define.
5644 (LIBLSAN_EARLY_SPEC): Define.
5645 * config/i386/sol2.h (CC1_SPEC): Redefine.
5646 (ASAN_REJECT_SPEC): Define.
5647
5648 * config/sparc/sparc.c (sparc_asan_shadow_offset): Declare.
5649 (TARGET_ASAN_SHADOW_OFFSET): Define.
5650 (sparc_asan_shadow_offset): New function.
5651 * config/sparc/sol2.h (CC1_SPEC): Append ASAN_CC1_SPEC.
5652 (ASAN_REJECT_SPEC): Define.
5653
5654 2018-11-06 Jan Hubicka <jh@suse.cz>
5655
5656 * tree.c (fld_type_variant): Copy canonical type.
5657 (fld_incomplete_type_of): Check that canonical types looks sane;
5658 copy canonical type.
5659 (verify_type): Accept when incomplete type has complete canonical type.
5660
5661 2018-11-06 Jan Hubicka <jh@suse.cz>
5662
5663 * tree.c (free_lang_data): Reset overwite_assembler_name,
5664 print_xnode, print_decl, print_type and print_identifier of
5665 langhooks.
5666
5667 2018-11-06 Richard Biener <rguenther@suse.de>
5668
5669 PR tree-optimization/87889
5670 * tree-vect-loop-manip.c (slpeel_duplicate_current_defs_from_edges):
5671 Do nothing if old and new arg are the same
5672
5673 2018-11-06 Andreas Krebbel <krebbel@linux.ibm.com>
5674
5675 PR target/87723
5676 * config/s390/s390.md ("*r<noxa>sbg_di_rotl"): Remove mode
5677 attributes for operands 3 and 4.
5678
5679 2018-11-06 Richard Biener <rguenther@suse.de>
5680
5681 PR middle-end/18041
5682 * simplify-rtx.c (simplify_binary_operation_1): Add pattern
5683 matching bitfield insertion.
5684
5685 2018-11-06 Alexandre Oliva <aoliva@redhat.com>
5686
5687 * auto-inc-dec.c: Include valtrack.h. Improve comments.
5688 (reg_next_debug_use): New.
5689 (attempt_change): Propagate adjusted expression into affected
5690 debug insns.
5691 (merge_in_block): Track uses in debug insns.
5692 (pass_inc_dec::execute): Allocate and release
5693 reg_next_debug_use.
5694
5695 2018-11-06 Wei Xiao <wei3.xiao@intel.com>
5696
5697 * config/i386/avx512fintrin.h: Update VFIXUPIMM* intrinsics.
5698 (_mm512_fixupimm_round_pd): Update parameters and builtin.
5699 (_mm512_maskz_fixupimm_round_pd): Ditto.
5700 (_mm512_fixupimm_round_ps): Ditto.
5701 (_mm512_maskz_fixupimm_round_ps): Ditto.
5702 (_mm_fixupimm_round_sd): Ditto.
5703 (_mm_maskz_fixupimm_round_sd): Ditto.
5704 (_mm_fixupimm_round_ss): Ditto.
5705 (_mm_maskz_fixupimm_round_ss): Ditto.
5706 (_mm512_fixupimm_pd): Ditto.
5707 (_mm512_maskz_fixupimm_pd): Ditto.
5708 (_mm512_fixupimm_ps): Ditto.
5709 (_mm512_maskz_fixupimm_ps): Ditto.
5710 (_mm_fixupimm_sd): Ditto.
5711 (_mm_maskz_fixupimm_sd): Ditto.
5712 (_mm_fixupimm_ss): Ditto.
5713 (_mm_maskz_fixupimm_ss): Ditto.
5714 (_mm512_mask_fixupimm_round_pd): Update builtin.
5715 (_mm512_mask_fixupimm_round_ps): Ditto.
5716 (_mm_mask_fixupimm_round_sd): Ditto.
5717 (_mm_mask_fixupimm_round_ss): Ditto.
5718 (_mm512_mask_fixupimm_pd): Ditto.
5719 (_mm512_mask_fixupimm_ps): Ditto.
5720 (_mm_mask_fixupimm_sd): Ditto.
5721 (_mm_mask_fixupimm_ss): Ditto.
5722 * config/i386/avx512vlintrin.h:
5723 (_mm256_fixupimm_pd): Update parameters and builtin.
5724 (_mm256_maskz_fixupimm_pd): Ditto.
5725 (_mm256_fixupimm_ps): Ditto.
5726 (_mm256_maskz_fixupimm_ps): Ditto.
5727 (_mm_fixupimm_pd): Ditto.
5728 (_mm_maskz_fixupimm_pd): Ditto.
5729 (_mm_fixupimm_ps): Ditto.
5730 (_mm_maskz_fixupimm_ps): Ditto.
5731 (_mm256_mask_fixupimm_pd): Update builtin.
5732 (_mm256_mask_fixupimm_ps): Ditto.
5733 (_mm_mask_fixupimm_pd): Ditto.
5734 (_mm_mask_fixupimm_ps): Ditto.
5735 * config/i386/i386-builtin-types.def: Add new types and remove useless ones.
5736 * config/i386/i386-builtin.def: Update builtin definitions.
5737 * config/i386/i386.c: Handle new builtin types and remove useless ones.
5738 * config/i386/sse.md: Update VFIXUPIMM* patterns.
5739 (<avx512>_fixupimm<mode>_maskz<round_saeonly_expand_name>): Update.
5740 (<avx512>_fixupimm<mode><sd_maskz_name><round_saeonly_name>): Update.
5741 (<avx512>_fixupimm<mode>_mask<round_saeonly_name>): Update.
5742 (avx512f_sfixupimm<mode>_maskz<round_saeonly_expand_name>): Update.
5743 (avx512f_sfixupimm<mode><sd_maskz_name><round_saeonly_name>): Update.
5744 (avx512f_sfixupimm<mode>_mask<round_saeonly_name>): Update.
5745 * config/i386/subst.md:
5746 (round_saeonly_sd_mask_operand4): Add new subst_attr.
5747 (round_saeonly_sd_mask_op4): Ditto.
5748 (round_saeonly_expand_operand5): Ditto.
5749 (round_saeonly_expand): Update.
5750
5751 2018-11-05 Max Filippov <jcmvbkbc@gmail.com>
5752
5753 * config/xtensa/uclinux.h (XTENSA_ALWAYS_PIC): Change to 0.
5754
5755 2018-11-05 Segher Boessenkool <segher@kernel.crashing.org>
5756
5757 PR rtl-optimization/87871
5758 * combine.c (make_more_copies): Skip if dest is frame_pointer_rtx.
5759
5760 2018-11-05 Paul Koning <ni1d@arrl.net>
5761
5762 * doc/sourcebuild.texi (target attributes): Document new "inf"
5763 effective target keyword.
5764
5765 2018-11-05 Robin Dapp <rdapp@linux.ibm.com>
5766
5767 * config/s390/s390.c (s390_register_move_cost): Increase costs for
5768 moves involving the CC reg.
5769
5770 2018-11-05 Richard Biener <rguenther@suse.de>
5771
5772 PR tree-optimization/87873
5773 * tree-ssa-loop-manip.h (split_loop_exit_edge): Add copy_constants_p
5774 argument.
5775 * tree-ssa-loop-manip.c (split_loop_exit_edge): Likewise.
5776 * tree-vect-loop.c (vect_transform_loop): When splitting the
5777 loop exit also create forwarder PHIs for constants.
5778 * tree-vect-loop-manip.c (slpeel_duplicate_current_defs_from_edges):
5779 Handle constant to_arg, add extra checking we match up the correct
5780 PHIs.
5781
5782 2018-11-05 Robin Dapp <rdapp@linux.ibm.com>
5783
5784 * config/s390/s390.md: QImode and HImode for load on condition.
5785
5786 2018-11-05 Robin Dapp <rdapp@linux.ibm.com>
5787
5788 * config/s390/predicates.md: Fix typo.
5789 * config/s390/s390.md: Allow immediates for load on condition.
5790
5791 2018-11-05 Martin Liska <mliska@suse.cz>
5792
5793 * alloc-pool.h (struct pool_usage): Use SIZE_AMOUNT.
5794 * bitmap.h (struct bitmap_usage): Likewise.
5795 * ggc-common.c (SCALE): Remove.
5796 (LABEL): Likewise.
5797 (struct ggc_usage): Use SIZE_AMOUNT. And update
5798 compare method.
5799 * ggc-page.c (SCALE): Remove.
5800 (STAT_LABEL): Remove.
5801 (ggc_print_statistics): Use SIZE_AMOUNT.
5802 * gimple.h (SCALE): Remove.
5803 (LABEL): Likewise.
5804 * input.c (ONE_K): Remove.
5805 (ONE_M): Likewise.
5806 (SCALE): Likewise.
5807 (STAT_LABEL): Likewise.
5808 (FORMAT_AMOUNT): Likewise.
5809 (dump_line_table_statistics): Use SIZE_AMOUNT.
5810 * mem-stats.h (struct mem_usage): Likewise.
5811 * rtl.c (dump_rtx_statistics): Likewise.
5812 (rtx_alloc_counts): Change type to size_t.
5813 (rtx_alloc_sizes): Likewise.
5814 (rtx_count_cmp): New.
5815 (dump_rtx_statistics): Sort first based on counts.
5816 * tree.c (tree_nodes_cmp): New.
5817 (tree_codes_cmp): New.
5818 (dump_tree_statistics): Sort first based on counts.
5819 * system.h (ONE_K): New.
5820 (ONE_M): Likewise.
5821 (SIZE_SCALE): Likewise.
5822 (SIZE_LABEL): Likewise.
5823 (SIZE_AMOUNT): Likewise.
5824 * tree-cfg.c (dump_cfg_stats): Use SIZE_AMOUNT.
5825 * tree-dfa.c (dump_dfa_stats): Likewise.
5826 * tree-phinodes.c (phinodes_print_statistics): Likewise.
5827 * tree-ssanames.c (ssanames_print_statistics): Likewise.
5828 * tree.c (dump_tree_statistics): Likewise.
5829 * vec.c (struct vec_usage): Likewise.
5830 * trans-mem.c (tm_mangle): Enlarge buffer in order to not
5831 trigger a -Werror=format-overflow with
5832 --enable-gather-detailed-stats.
5833
5834 2018-11-05 Martin Liska <mliska@suse.cz>
5835
5836 * mem-stats.h (mem_alloc_description::release_instance_overhead):
5837 Return T *.
5838 * vec.c (struct vec_usage): Register m_element_size.
5839 (vec_prefix::register_overhead): New arguments: elements and
5840 element_size.
5841 (vec_prefix::release_overhead): Subtract elements.
5842 * vec.h (struct vec_prefix): Change signature.
5843 (va_heap::reserve): Pass proper arguments.
5844 (va_heap::release): Likewise.
5845
5846 2018-11-05 Martin Liska <mliska@suse.cz>
5847
5848 * mem-stats.h (mem_alloc_description::get_list): Fix GNU coding
5849 style.
5850 * vec.c: Likewise.
5851
5852 2018-11-05 Richard Biener <rguenther@suse.de>
5853
5854 * tree-scalar-evolution.h (final_value_replacement_loop): Update
5855 prototype.
5856 * tree-scalar-evolution.c (final_value_replacement_loop): Return
5857 whether anything was done.
5858 (scev_const_prop): Remove constant propagation part, fold
5859 remains into ...
5860 * tree-ssa-loop.c (pass_scev_cprop::execute): ... here.
5861 (pass_data_scev_cprop): TODO_cleanup_cfg is now done
5862 conditionally.
5863
5864 2018-11-05 Jakub Jelinek <jakub@redhat.com>
5865
5866 PR tree-optimization/87859
5867 * gimple-ssa-store-merging.c (struct merged_store_group): Add
5868 only_constants and first_nonmergeable_order members.
5869 (merged_store_group::merged_store_group): Initialize them.
5870 (merged_store_group::do_merge): Clear only_constants member if
5871 adding something other than INTEGER_CST store.
5872 (imm_store_chain_info::coalesce_immediate_stores): Don't merge
5873 stores with order >= first_nonmergeable_order. Use
5874 merged_store->only_constants instead of always recomputing it.
5875 Set merged_store->first_nonmergeable_order if we've skipped any
5876 stores. Attempt to merge overlapping INTEGER_CST stores that
5877 we would otherwise skip.
5878
5879 PR sanitizer/87837
5880 * match.pd (X + Y < X): Don't optimize if TYPE_OVERFLOW_SANITIZED.
5881
5882 2018-11-05 Xuepeng Guo <xuepeng.guo@intel.com>
5883
5884 PR target/87853
5885 * config/i386/emmintrin.h (__v16qs): New to cope with option
5886 -funsigned-char.
5887 (_mm_cmpeq_epi8): Replace __v16qi with __v16qs.
5888 (_mm_cmplt_epi8): Likewise.
5889 (_mm_cmpgt_epi8): Likewise.
5890
5891 2018-11-05 Richard Biener <rguenther@suse.de>
5892
5893 PR rtl-optimization/87852
5894 * fwprop.c (use_killed_between): Only consider single-defs of the
5895 use whose definition statement dominates the use.
5896
5897 2018-11-05 Martin Liska <mliska@suse.cz>
5898
5899 PR web/87829
5900 * doc/invoke.texi: Remove options that are
5901 not disabled with -Os.
5902
5903 2018-11-05 Martin Liska <mliska@suse.cz>
5904
5905 PR c/87811
5906 * doc/extend.texi: Update constrain about the last argument
5907 of __builtin_expect_with_probability.
5908
5909 2018-11-05 Martin Liska <mliska@suse.cz>
5910
5911 PR c/87811
5912 * predict.c (expr_expected_value_1): Verify
5913 that last argument is a real constants and emit
5914 error.
5915
5916 2018-11-05 Martin Liska <mliska@suse.cz>
5917
5918 PR gcov-profile/77698
5919 * ipa-profile.c (ipa_profile): Adjust hotness threshold
5920 only in LTO mode.
5921
5922 2018-11-04 Bernd Edlinger <bernd.edlinger@hotmail.de>
5923
5924 PR tree-optimization/86572
5925 * builtins.c (c_strlen): Handle negative offsets in a safe way.
5926
5927 2018-11-04 Bernd Edlinger <bernd.edlinger@hotmail.de>
5928
5929 PR tree-optimization/87672
5930 * gimple-fold.c (gimple_fold_builtin_stxcpy_chk): Gimplify.
5931 * tree-ssa-strlen.c (handle_builtin_strcat): Adjust object size.
5932
5933 2018-11-04 Uros Bizjak <ubizjak@gmail.com>
5934
5935 PR middle-end/58372
5936 * cfgexpand.c (pass_expand::execute): Move the call to
5937 finish_eh_generation in front of the call to expand_stack_alignment.
5938
5939 2018-11-04 Venkataramanan Kumar <venkataramanan.kumar@amd.com>
5940
5941 * common/config/i386/i386-common.c (processor_alias_table): Add
5942 znver2 entry.
5943 * config.gcc (i[34567]86-*-linux* | ...): Add znver2.
5944 (case ${target}): Add znver2.
5945 * config/i386/driver-i386.c: (host_detect_local_cpu): Let
5946 -march=native recognize znver2 processors.
5947 * config/i386/i386-c.c (ix86_target_macros_internal): Add znver2.
5948 * config/i386/i386.c (m_znver2): New definition.
5949 (m_ZNVER): New definition.
5950 (m_AMD_MULTIPLE): Includes m_znver2.
5951 (processor_cost_table): Add znver2 entry.
5952 (processor_target_table): Add znver2 entry.
5953 (get_builtin_code_for_version): Set priority for
5954 PROCESSOR_ZNVER2.
5955 (processor_model): Add M_AMDFAM17H_ZNVER2.
5956 (arch_names_table): Ditto.
5957 (ix86_reassociation_width): Include znver2.
5958 * config/i386/i386.h (TARGET_znver2): New definition.
5959 (struct ix86_size_cost): Add TARGET_ZNVER2.
5960 (enum processor_type): Add PROCESSOR_ZNVER2.
5961 * config/i386/i386.md (define_attr "cpu"): Add znver2.
5962 * config/i386/x86-tune-costs.h: (processor_costs) Add znver2 costs.
5963 * config/i386/x86-tune-sched.c: (ix86_issue_rate): Add znver2.
5964 (ix86_adjust_cost): Add znver2.
5965 * config/i386/x86-tune.def: Replace m_ZNVER1 by m_ZNVER.
5966 * gcc/doc/extend.texi: Add details about znver2.
5967 * gcc/doc/invoke.texi: Add details about znver2.
5968
5969 2018-11-03 Sandra Loosemore <sandra@codesourcery.com>
5970
5971 PR target/87079
5972
5973 * config/nios2/nios2.c (nios2_rtx_costs): Recognize <mul>sidi3
5974 pattern.
5975
5976 2018-11-02 Aaron Sawdey <acsawdey@linux.ibm.com>
5977
5978 * config/rs6000/rs6000-string.c (expand_strncmp_gpr_sequence): Pay
5979 attention to TARGET_AVOID_XFORM and BYTES_BIG_ENDIAN.
5980
5981 2018-11-02 Richard Earnshaw <rearnsha@arm.com>
5982
5983 * config/aarch64/aarch64.c ((aarch64_override_options): Disable
5984 shrink-wrapping when -mtrack-speculation.
5985
5986 2018-11-02 Richard Biener <rguenther@suse.de>
5987
5988 * tree-ssa-coalesce.c (struct coalesce_list): Add obstack member.
5989 (pop_cost_one_pair): Do not free pair.
5990 (pop_best_coalesce): Likewise.
5991 (create_coalesce_list): Initialize obstack.
5992 (delete_coalesce_list): Free obstack.
5993 (find_coalesce_pair): Obstack-allocate coalesce pairs.
5994 (add_cost_one_coalesce): Likewise.
5995 (struct live_track): Remove bitmap pointer indirections.
5996 (new_live_track): Adjust.
5997 (delete_live_track): Likewise.
5998 (live_track_remove_partition): Likewise.
5999 (live_track_add_partition): Likewise.
6000 (live_track_live_p): Likewise.
6001 (live_track_process_def): Likewise.
6002 (live_track_clear_base_vars): Likewise.
6003
6004 2018-11-02 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6005
6006 * configure.ac (gcc_cv_as_sparc_register_op): Remove.
6007 * configure: Regenerate.
6008 * config.in: Regenerate.
6009 * config/sparc/sparc.c (sparc_output_scratch_registers): Remove
6010 HAVE_AS_REGISTER_PSEUDO_OP guard.
6011 * config/sparc/sparc.h (ASM_ARCH64_SPEC): Remove
6012 !HAVE_AS_REGISTER_PSEUDO_OP support.
6013 (ASM_DECLARE_REGISTER_GLOBAL): Remove HAVE_AS_REGISTER_PSEUDO_OP
6014 guard.
6015
6016 2018-11-02 Richard Biener <rguenther@suse.de>
6017
6018 * dwarf2out.c (build_abbrev_table): Guard lookup_external_ref call
6019 with is_type_die.
6020
6021 2018-11-02 Richard Biener <rguenther@suse.de>
6022
6023 PR tree-optimization/87776
6024 * tree-ssa-sccvn.c (do_rpo_vn): Do not mark backedges
6025 executable when iterating but running into rpo-vn-max-loop-depth
6026 and not eliding the iteration.
6027
6028 2018-11-30 Jan Hubicka <jh@suse.cz>
6029
6030 * tree.c (free_lang_data_in_decl): Free TREE_TYPE and alignment of
6031 TYPE_DECL.
6032
6033 2018-11-01 Aaron Sawdey <acsawdey@linux.ibm.com>
6034
6035 * config/rs6000/rs6000-protos.h (rs6000_address_for_fpconvert): Remove
6036 prototype.
6037 * config/rs6000/rs6000.c (rs6000_force_indexed_or_indirect_mem):
6038 Combine with rs6000_address_for_fpconvert.
6039 (rs6000_address_for_fpconvert): Combine with
6040 rs6000_force_indexed_or_indirect_mem.
6041 (rs6000_expand_vector_init): Change function call from
6042 rs6000_address_for_fpconvert to rs6000_force_indexed_or_indirect_mem.
6043 * config/rs6000/rs6000.md (floatsi<mode>2_lfiwax): Change call from
6044 rs6000_address_for_fpconvert to rs6000_force_indexed_or_indirect_mem.
6045 (floatsi<mode>2_lfiwax_mem): Ditto.
6046 (floatunssi<mode>2_lfiwzx): Ditto.
6047 (floatunssi<mode>2_lfiwzx_mem): Ditto.
6048 (float<QHI:mode><FP_ISA3:mode>2): Ditto.
6049 (floatuns<QHI:mode><FP_ISA3:mode>2): Ditto.
6050 (fix_trunc<mode>si2_stfiwx): Ditto.
6051 (fixuns_trunc<mode>si2_stfiwx): Ditto.
6052 (float_<mode>si2_hw): Ditto.
6053 (floatuns_<mode>si2_hw): Ditto.
6054 * config/rs6000/vsx.md (*vsx_extract_si): Ditto.
6055 (vsx_splat_<mode>): Ditto.
6056
6057 2018-11-01 Joseph Myers <joseph@codesourcery.com>
6058
6059 * configure.ac (gcc_cv_as_ia64_ltoffx_ldxmov_relocs): Add newline
6060 at end of assembler input text.
6061 * configure: Regenerate.
6062
6063 2018-11-01 Jakub Jelinek <jakub@redhat.com>
6064
6065 PR tree-optimization/87826
6066 * gimple-ssa-store-merging.c (do_shift_rotate): Punt if count is
6067 negative or larger or equal to type's precision.
6068
6069 2018-10-31 Alexandre Oliva <aoliva@redhat.com>
6070
6071 * opts.c (default_options_table): Do not enable
6072 OPT_fdelayed_branch at -Og.
6073 * doc/invoke.texi (-fdelayed-branch): Document it.
6074
6075 2018-10-31 Richard Henderson <richard.henderson@linaro.org>
6076
6077 * optabs-libfuncs.c (build_libfunc_function_visibility):
6078 New, split out from...
6079 (build_libfunc_function): ... here.
6080 (init_one_libfunc_visibility): New, split out from ...
6081 (init_one_libfunc): ... here.
6082
6083 * config/aarch64/atomics.md (aarch64_atomic_<ATOMIC_LDOP><ALLI>_lse):
6084 scratch register need not be early-clobber. Document the reason
6085 why we cannot use ST<OP>.
6086
6087 2018-10-31 Joseph Myers <joseph@codesourcery.com>
6088
6089 PR bootstrap/82856
6090 * configure.ac: Remove AC_PREREQ. Use AC_LANG_SOURCE. Use single
6091 line for second argument of AC_DEFINE_UNQUOTED.
6092 * doc/install.texi (Tools/packages necessary for modifying GCC):
6093 Update to autoconf 2.69 and automake 1.15.1.
6094 * aclocal.m4, config.in, configure: Regenerate.
6095
6096 2018-10-31 Pat Haugen <pthaugen@us.ibm.com>
6097
6098 * tree-ssa-loop-ivcanon.c (try_peel_loop): Fix typo and remove dead
6099 initialization.
6100
6101 2018-10-31 Martin Liska <mliska@suse.cz>
6102
6103 PR driver/83193
6104 * common/config/aarch64/aarch64-common.c (aarch64_parse_extension):
6105 Add new argument invalid_extension.
6106 (aarch64_get_all_extension_candidates): New function.
6107 (aarch64_rewrite_selected_cpu): Add NULL to function call.
6108 * config/aarch64/aarch64-protos.h (aarch64_parse_extension): Add
6109 new argument.
6110 (aarch64_get_all_extension_candidates): New function.
6111 * config/aarch64/aarch64.c (aarch64_parse_arch): Add new
6112 argument invalid_extension.
6113 (aarch64_parse_cpu): Likewise.
6114 (aarch64_print_hint_for_extensions): New function.
6115 (aarch64_validate_mcpu): Provide hint about invalid extension.
6116 (aarch64_validate_march): Likewise.
6117 (aarch64_handle_attr_arch): Pass new argument.
6118 (aarch64_handle_attr_cpu): Provide hint about invalid extension.
6119 (aarch64_handle_attr_isa_flags): Likewise.
6120
6121 2018-10-31 Richard Biener <rguenther@suse.de>
6122
6123 PR middle-end/70359
6124 PR middle-end/86270
6125 * tree-outof-ssa.c (insert_backedge_copies): Restrict
6126 copy generation to useful cases. Place the copy before
6127 the definition of the backedge value when possible.
6128
6129 2018-10-31 Claudiu Zissulescu <claziss@synopsys.com>
6130
6131 * config/arc/arc-arch.h (ARC_TUNE_ARC7XX): New tune value.
6132 * config/arc/arc.c (arc_active_insn): New function.
6133 (check_store_cacheline_hazard): Likewise.
6134 (workaround_arc_anomaly): Use check_store_cacheline_hazard.
6135 (arc_override_options): Disable delay slot scheduler for older
6136 A7.
6137 (arc_store_addr_hazard_p): New implementation, old one renamed to
6138 ...
6139 (arc_store_addr_hazard_internal_p): Renamed.
6140 (arc_reorg): Don't combine into brcc instructions which are part
6141 of hardware hazard solution.
6142 * config/arc/arc.md (attr tune): Consider new arc7xx tune value.
6143 (tune_arc700): Likewise.
6144 * config/arc/arc.opt (arc7xx): New tune value.
6145 * config/arc/arc700.md: Improve A7 scheduler.
6146
6147 2018-10-31 Claudiu Zissulescu <claziss@synopsys.com>
6148
6149 * config/arc/arc.c (arc_override_options): Remove
6150 TARGET_COMPACT_CASESI.
6151 * config/arc/arc.h (ASM_OUTPUT_ADDR_DIFF_ELT): Update.
6152 (CASE_VECTOR_MODE): Likewise.
6153 (CASE_VECTOR_PC_RELATIVE): Likewise.
6154 (CASE_VECTOR_SHORTEN_MODE): Likewise.
6155 (CASE_VECTOR_SHORTEN_MODE1): Delete.
6156 (ADDR_VEC_ALIGN): Update.
6157 (ASM_OUTPUT_CASE_LABEL): Undefine.
6158 (ASM_OUTPUT_BEFORE_CASE_LABEL): Undefine.
6159 (TARGET_BI_BIH): Define.
6160 (DEFAULT_BRANCH_INDEX): Likewise.
6161 * config/arc/arc.md (casesi): Rework to accept BI/BIH
6162 instructions, remove compact_casesi use case.
6163 (casesi_compact_jump): Remove.
6164 (casesi_dispatch): New pattern.
6165 * config/arc/arc.opt: Add mbranch-index option. Deprecate
6166 compact_casesi option.
6167 * doc/invoke.texi: Document mbranch-index option.
6168
6169 2018-10-31 Claudiu Zissulescu <claziss@synopsys.com>
6170
6171 * config/arc/arc.c (arc_get_tp): Remove function.
6172 (arc_emit_call_tls_get_addr): Likewise.
6173 (arc_call_tls_get_addr): New function.
6174 (arc_legitimize_tls_address): Make use of arc_call_tls_get_addr.
6175 * config/arc/arc.md (tls_load_tp_soft): Remove.
6176 (tls_gd_get_addr): Likewise.
6177
6178 2018-10-31 Claudiu Zissulescu <claziss@synopsys.com>
6179
6180 * config/arc/arc.md (mulsi3): Remove call to mulsi_600_lib.
6181 (mulsi3_600_lib): Remove pattern.
6182 (umulsi3_highpart_600_lib_le): Likewise.
6183 (umulsi3_highpart): Remove call to umulsi3_highpart_600_lib_le.
6184 (umulsidi3): Remove call to umulsidi3_600_lib.
6185 (umulsidi3_600_lib): Remove pattern.
6186 (peephole2): Remove peephole using the above deprecated patterns.
6187
6188 2018-10-31 Thomas Preud'homme <thomas.preudhomme@linaro.org>
6189
6190 PR target/87374
6191 * config/arm/arm.c (arm_option_check_internal): Disable the combined
6192 use of -mslow-flash-data and -mword-relocations.
6193 (arm_option_override): Enable -mword-relocations if -fpic or -fPIC.
6194 * config/arm/arm.md (SYMBOL_REF MOVT splitter): Stop checking for
6195 flag_pic.
6196 * doc/invoke.texi (-mword-relocations): Mention conflict with
6197 -mslow-flash-data.
6198 (-mslow-flash-data): Reciprocally.
6199
6200 2018-10-31 Richard Henderson <richard.henderson@linaro.org>
6201
6202 * config/aarch64/aarch64.c (aarch64_hard_regno_mode_ok): Force
6203 16-byte modes held in GP registers to use an even regno.
6204
6205 * config/aarch64/aarch64.c (aarch64_emit_bic): Remove.
6206 (aarch64_atomic_ldop_supported_p): Remove.
6207 (aarch64_gen_atomic_ldop): Remove.
6208 * config/aarch64/atomic.md (atomic_<atomic_optab><ALLI>):
6209 Fully expand LSE operations here.
6210 (atomic_fetch_<atomic_optab><ALLI>): Likewise.
6211 (atomic_<atomic_optab>_fetch<ALLI>): Likewise.
6212 (aarch64_atomic_<ATOMIC_LDOP><ALLI>_lse): Drop atomic_op iterator
6213 and use ATOMIC_LDOP instead; use register_operand for the input;
6214 drop the split and emit insns directly.
6215 (aarch64_atomic_fetch_<ATOMIC_LDOP><ALLI>_lse): Likewise.
6216 (aarch64_atomic_<atomic_op>_fetch<ALLI>_lse): Remove.
6217 (@aarch64_atomic_load<ATOMIC_LDOP><ALLI>): Remove.
6218
6219 * config/aarch64/aarch64.c (aarch64_emit_atomic_swap): Remove.
6220 (aarch64_gen_atomic_ldop): Don't call it.
6221 * config/aarch64/atomics.md (atomic_exchange<ALLI>):
6222 Use aarch64_reg_or_zero.
6223 (aarch64_atomic_exchange<ALLI>): Likewise.
6224 (aarch64_atomic_exchange<ALLI>_lse): Remove split; remove & from
6225 operand 0; use aarch64_reg_or_zero for input; merge ...
6226 (@aarch64_atomic_swp<ALLI>): ... this and remove.
6227
6228 * config/aarch64/aarch64.c (aarch64_gen_compare_reg_maybe_ze): New.
6229 (aarch64_split_compare_and_swap): Use it.
6230 (aarch64_expand_compare_and_swap): Likewise. Remove convert_modes;
6231 test oldval against the proper predicate.
6232 * config/aarch64/atomics.md (@atomic_compare_and_swap<ALLI>):
6233 Use nonmemory_operand for expected.
6234 (cas_short_expected_pred): New.
6235 (@aarch64_compare_and_swap<SHORT>): Use it; use "rn" not "rI" to match.
6236 (@aarch64_compare_and_swap<GPI>): Use "rn" not "rI" for expected.
6237 * config/aarch64/predicates.md (aarch64_plushi_immediate): New.
6238 (aarch64_plushi_operand): New.
6239
6240 * config/aarch64/aarch64.c (aarch64_expand_compare_and_swap):
6241 Force oldval into the rval register for TARGET_LSE; emit the compare
6242 during initial expansion so that it may be deleted if unused.
6243 (aarch64_gen_atomic_cas): Remove.
6244 * config/aarch64/atomics.md (@aarch64_compare_and_swap<SHORT>_lse):
6245 Change =&r to +r for operand 0; use match_dup for operand 2;
6246 remove is_weak and mod_f operands as unused. Drop the split
6247 and merge with...
6248 (@aarch64_atomic_cas<SHORT>): ... this pattern's output; remove.
6249 (@aarch64_compare_and_swap<GPI>_lse): Similarly.
6250 (@aarch64_atomic_cas<GPI>): Similarly.
6251
6252 2018-10-31 Richard Biener <rguenther@suse.de>
6253
6254 * tree-eh.c (replace_trapping_overflow): Simplify ABS_EXPR case
6255 using ABSU_EXPR.
6256
6257 2018-10-31 Sameera Deshpande <sameera.deshpande@linaro.org>
6258
6259 * config/aarch64/aarch64-cores.def (saphira): Use saphira pipeline.
6260 * config/aarch64/aarch64.md: Include saphira.md
6261 * config/aarch64/saphira.md: New file for pipeline description.
6262
6263 2018-10-30 Martin Sebor <msebor@redhat.com>
6264
6265 PR middle-end/87041
6266 * gimple-ssa-sprintf.c (format_directive): Use %G to include
6267 inlining context.
6268 (sprintf_dom_walker::compute_format_length):
6269 Avoid setting POSUNDER4K here.
6270 (get_destination_size): Handle null argument values.
6271 (get_user_idx_format): New function.
6272 (sprintf_dom_walker::handle_gimple_call): Handle all printf-like
6273 functions, including user-defined with attribute format printf.
6274 Use %G to include inlining context.
6275 Set POSUNDER4K here.
6276
6277 2018-10-30 Jan Hubicka <jh@suse.cz>
6278
6279 * params.def (lto-partitions): Bump from 32 to 128.
6280
6281 2018-10-30 Jan Hubicka <jh@suse.cz>
6282
6283 * tree.c
6284 (free_lang_data_d, add_tree_to_fld_list, fld_worklist_push): Move
6285 head in file.
6286 (free_lang_data_in_type): Forward declare.
6287 (fld_type_variant_equal_p): New function.
6288 (fld_type_variant): New function
6289 (fld_incomplete_types): New hash.
6290 (fld_incomplete_type_of): New function
6291 (fld_simplfied-type): New function.
6292 (free_lang_data_in_decl): Add fld parameter; simplify type of FIELD_DECL
6293 (free_lang_data): Allocate and free fld_incomplete_type; update call
6294 of free_lang_data_in_decl.
6295
6296 2018-10-30 Eric Botcazou <ebotcazou@adacore.com>
6297
6298 * gcov.c (output_lines): Remove duplicate line.
6299
6300 2018-10-30 Aaron Sawdey <acsawdey@linux.ibm.com>
6301
6302 * config/rs6000/rs6000.md (bswapdi2): Force address into register
6303 if not in indexed or indirect form.
6304 (bswapdi2_load): Change predicate to indexed_or_indirect_operand.
6305 (bswapdi2_store): Ditto.
6306 * config/rs6000/rs6000.c (rs6000_force_indexed_or_indirect_mem): New
6307 helper function.
6308 * config/rs6000/rs6000-protos.h (rs6000_force_indexed_or_indirect_mem):
6309 Prototype for helper function.
6310
6311 2018-10-30 Martin Sebor <msebor@redhat.com>
6312
6313 * doc/extend.texi (optimize): Clarify/expand attribute documentation.
6314 (target, pragma GCC optimize, pragma GCC target): Ditto.
6315
6316 2018-10-30 Jonathan Wakely <jwakely@redhat.com>
6317
6318 * doc/extend.texi: Fix prototype and description of
6319 __builtin_expect_with_probability.
6320
6321 2018-10-30 Michael Ploujnikov <michael.ploujnikov@oracle.com>
6322
6323 * cgraph.h (clone_function_name_1): Replaced by new
6324 clone_function_name_numbered that takes name as string; for
6325 privatize_symbol_name_1 use only.
6326 (clone_function_name): Renamed to
6327 clone_function_name_numbered to be explicit about numbering.
6328 (clone_function_name): New two-argument function that does
6329 not number its output.
6330 (clone_function_name): New three-argument function that
6331 takes a number to append to its output.
6332 * cgraphclones.c (duplicate_thunk_for_node):
6333 (clone_function_name_1): Renamed.
6334 (clone_function_name_numbered): Two new functions.
6335 (clone_function_name): Improved documentation.
6336 (cgraph_node::create_virtual_clone): Use clone_function_name_numbered.
6337 * config/rs6000/rs6000.c (make_resolver_func): Ditto.
6338 * final.c (final_scan_insn_1): Use the new clone_function_name
6339 without numbering.
6340 * multiple_target.c (create_dispatcher_calls): Ditto.
6341 (create_target_clone): Ditto.
6342 * omp-expand.c (grid_expand_target_grid_body): Ditto.
6343 * omp-low.c (create_omp_child_function_name): Ditto.
6344 * omp-simd-clone.c (simd_clone_create): Ditto.
6345 * symtab.c (simd_symtab_node::noninterposable_alias): Use the
6346 new clone_function_name without numbering.
6347
6348 2018-10-30 Richard Earnshaw <rearnsha@arm.com>
6349
6350 * alloc-pool.h (base_pool_allocator <TBlockAllocator>::initialize):
6351 Assert that the allocation size is not zero.
6352
6353 2018-10-30 Richard Biener <rguenther@suse.de>
6354
6355 PR tree-optimization/87800
6356 * tree-vect-slp.c (vect_build_slp_tree_2): Reject any
6357 non-induction or reduction PHIs.
6358
6359 2018-10-30 Sameera Deshpande <sameera.deshpande@linaro.org>
6360
6361 * config/aarch64/falkor-tag-collision-avoidance.c
6362 (execute_tag_collision_avoidance): Call df_note_add_problem.
6363
6364 2018-10-30 Martin Liska <mliska@suse.cz>
6365
6366 * doc/extend.texi: Fix typo in documentation
6367 of __builtin_expect_with_probability.
6368
6369 2018-10-29 David Malcolm <dmalcolm@redhat.com>
6370
6371 PR c++/87721
6372 * input.c (get_substring_ranges_for_loc): Detect if
6373 linemap_resolve_location gives us a NULL map, and reject
6374 this case.
6375
6376 2018-10-29 Iain Buclaw <ibuclaw@gdcproject.org>
6377
6378 * config.gcc (xstormy16-*-elf): Set tm_d_file.
6379
6380 2018-10-29 David Malcolm <dmalcolm@redhat.com>
6381 Martin Sebor <msebor@redhat.com>
6382 Manuel Lopez-Ibanez <manu@gcc.gnu.org>
6383
6384 * doc/ux.texi (Quoting): New subsection, adapted from material at
6385 https://gcc.gnu.org/wiki/DiagnosticsGuidelines written by
6386 MartinSebor and ManuelLopezIbanez.
6387 (Fix-it hints): Note that fix-it hints shouldn't be marked for
6388 translation.
6389
6390 2018-10-29 Kugan Vivekanandarajah <kuganv@linaro.org>
6391
6392 PR middle-end/87469
6393 * tree-ssa-loop-niter.c (number_of_iterations_popcount): Fix niter
6394 max value.
6395
6396 2018-10-29 Paul A. Clarke <pc@us.ibm.com>
6397
6398 * gcc.target/powerpc/ssse3-check.h: Remove inaccurate comment.
6399
6400 2018-10-29 Paul Koning <ni1d@arrl.net>
6401
6402 * doc/rtl.texi (CONST_WIDE_INT_ELT): Give correct macro name.
6403
6404 2018-10-29 Paul A. Clarke <pc@us.ibm.com>
6405
6406 * gcc/config/rs6000/mmintrin.h (_mm_packs_pi16, _mm_packs_pi32,
6407 _mm_packs_pu16, _mm_unpackhi_pi8, _mm_unpacklo_pi8, _mm_add_pi8,
6408 _mm_add_pi16, _mm_add_pi32, _mm_sub_pi8, _mm_sub_pi16, _mm_sub_pi32,
6409 _mm_cmpgt_pi8, _mm_cmpeq_pi16, _mm_cmpgt_pi16, _mm_cmpeq_pi32,
6410 _mm_cmpgt_pi32, _mm_adds_pi8, _mm_adds_pi16, _mm_adds_pu8,
6411 _mm_adds_pu16, _mm_subs_pi8, _mm_subs_pi16, _mm_subs_pu8,
6412 _mm_subs_pu16, _mm_madd_pi16, _mm_mulhi_pi16, _mm_mullo_pi16,
6413 _mm_sll_pi16, _mm_sra_pi16, _mm_srl_pi16, _mm_set1_pi16, _mm_set1_pi8):
6414 Change 'vector' to '__vector'.
6415 * gcc/config/rs6000/xmmintrin.h (_mm_cvtps_pi32, _mm_cvttps_pi32,
6416 _mm_cvtps_pi16, _mm_cvtps_pi8, _mm_max_pi16, _mm_max_pu8, _mm_min_pi16,
6417 _mm_min_pu8, _mm_mulhi_pu16, _mm_shuffle_pi16, _mm_avg_pu8,
6418 _mm_avg_pu16): Likewise. And, whitespace corrections.
6419
6420 2018-10-29 Richard Biener <rguenther@suse.de>
6421
6422 PR tree-optimization/87785
6423 * tree-vect-slp.c (vect_gather_slp_loads): Only gather
6424 internal defs.
6425
6426 2018-10-29 Olivier Hainque <hainque@adacore.com>
6427
6428 * VXWORKS_NET_LIBS_RTP: New macro, network part of VXWORKS_LIBS_RTP.
6429
6430 2018-10-29 Olivier Hainque <hainque@adacore.com>
6431
6432 * config/vxworks.h (VXWORKS_PERSONALITY): New VxWorks
6433 ports configuration macro, defaults to "gnu".
6434 (VXWORKS_OS_CPP_BUILTINS): Use it. Feed TOOL and
6435 TOOL_FAMILY instead of _VX_TOOL/_VXTOOL_FAMILY.
6436
6437 2018-10-29 Olivier Hainque <hainque@adacore.com>
6438
6439 * config/vxworks.h (CLEAR_INSN_CACHE): #undef before #define.
6440
6441 2018-10-29 Richard Biener <rguenther@suse.de>
6442
6443 PR tree-optimization/87790
6444 * tree-vect-slp.c (vect_mark_slp_stmts): Simplify.
6445 (vect_make_slp_decision): Adjust.
6446 (vect_slp_analyze_bb_1): Likewise.
6447 (vect_detect_hybrid_slp_stmts): Properly union SLP type over
6448 edges.
6449
6450 2018-10-29 Richard Biener <rguenther@suse.de>
6451
6452 PR tree-optimization/87785
6453 * tree-vect-slp.c (vect_build_slp_tree_2): Remove loads argument
6454 and processing.
6455 (vect_build_slp_tree): Likewise.
6456 (vect_gather_slp_loads): New function.
6457 (vect_analyze_slp_instance): Gather loads separately from the
6458 SLP tree build.
6459
6460 2018-10-29 Martin Liska <mliska@suse.cz>
6461
6462 * Makefile.in: Make dependency to json.o.
6463 * doc/gcov.texi: Document new JSON format, remove
6464 old intermediate format documentation.
6465 * gcov.c (struct function_info): Come up with m_name and
6466 m_demangled_name.
6467 (function_info::function_info): Initialize it.
6468 (function_info::~function_info): Release it.
6469 (main): Rename flag_intermediate_format to flag_json_format.
6470 (print_usage): Describe --json-format.
6471 (process_args): Set flag_json_format.
6472 (output_intermediate_line): Remove.
6473 (output_intermediate_json_line): Likewise.
6474 (get_gcov_intermediate_filename): Return new extension
6475 ".gcov.json.gz".
6476 (output_intermediate_file): Implement JSON emission.
6477 (output_json_intermediate_file): Implement JSON emission.
6478 (generate_results): Use ::get_name for function name.
6479 Handle JSON output file.
6480 (read_graph_file): Use ::get_name instead of cplus_demangle.
6481 (read_count_file): Likewise.
6482 (solve_flow_graph): Likewise.
6483 (add_line_counts): Likewise.
6484 (accumulate_line_counts): Use new flag_json_format.
6485 (output_function_details): Use ::get_name instead of cplus_demangle.
6486 (output_lines): Likewise.
6487 * json.cc (test_writing_literals): Add new tests.
6488 * json.h (class literal): Add new boolean constructor.
6489
6490 2018-10-29 Segher Boessenkool <segher@kernel.crashing.org>
6491
6492 PR rtl-optimization/87701
6493 PR rtl-optimization/87780
6494 * combine.c (make_more_copies): Rewrite.
6495
6496 2018-10-28 Kugan Vivekanandarajah <kuganv@linaro.org>
6497
6498 * doc/generic.texi (ABSU_EXPR): Document.
6499 * match.pd (absu(x)*absu(x) -> x*x): Handle.
6500 (absu(absu(X)) -> absu(X)): Likewise.
6501 (absu(-X) -> absu(X)): Likewise.
6502 (absu(X) where X is nonnegative -> X): Likewise.
6503
6504 2018-10-28 Iain Buclaw <ibuclaw@gdcproject.org>
6505
6506 * Makefile.in (tm_d_file_list, tm_d_include_list): New variables.
6507 (TM_D_H, D_TARGET_DEF, D_TARGET_H, D_TARGET_OBJS): New variables.
6508 (tm_d.h, cs-tm_d.h, default-d.o): New rules.
6509 (d/d-target-hooks-def.h, s-d-target-hooks-def-h): New rules.
6510 (s-tm-texi): Also check timestamp on d-target.def.
6511 (generated_files): Add TM_D_H and d-target-hooks-def.h.
6512 (build/genhooks.o): Also depend on D_TARGET_DEF.
6513 * config.gcc (tm_d_file, d_target_objs, target_has_targetdm): New
6514 variables.
6515 * config/aarch64/aarch64-d.c: New file.
6516 * config/aarch64/aarch64-linux.h (GNU_USER_TARGET_D_CRITSEC_SIZE):
6517 Define.
6518 * config/aarch64/aarch64-protos.h (aarch64_d_target_versions): New
6519 prototype.
6520 * config/aarch64/aarch64.h (TARGET_D_CPU_VERSIONS): Define.
6521 * config/aarch64/t-aarch64 (aarch64-d.o): New rule.
6522 * config/arm/arm-d.c: New file.
6523 * config/arm/arm-protos.h (arm_d_target_versions): New prototype.
6524 * config/arm/arm.h (TARGET_D_CPU_VERSIONS): Define.
6525 * config/arm/linux-eabi.h (EXTRA_TARGET_D_OS_VERSIONS): Define.
6526 * config/arm/t-arm (arm-d.o): New rule.
6527 * config/default-d.c: New file.
6528 * config/glibc-d.c: New file.
6529 * config/gnu.h (GNU_USER_TARGET_D_OS_VERSIONS): Define.
6530 * config/i386/i386-d.c: New file.
6531 * config/i386/i386-protos.h (ix86_d_target_versions): New prototype.
6532 * config/i386/i386.h (TARGET_D_CPU_VERSIONS): Define.
6533 * config/i386/linux-common.h (EXTRA_TARGET_D_OS_VERSIONS): Define.
6534 (GNU_USER_TARGET_D_CRITSEC_SIZE): Define.
6535 * config/i386/t-i386 (i386-d.o): New rule.
6536 * config/kfreebsd-gnu.h (GNU_USER_TARGET_D_OS_VERSIONS): Define.
6537 * config/kopensolaris-gnu.h (GNU_USER_TARGET_D_OS_VERSIONS): Define.
6538 * config/linux-android.h (ANDROID_TARGET_D_OS_VERSIONS): Define.
6539 * config/linux.h (GNU_USER_TARGET_D_OS_VERSIONS): Define.
6540 * config/mips/linux-common.h (EXTRA_TARGET_D_OS_VERSIONS): Define.
6541 * config/mips/mips-d.c: New file.
6542 * config/mips/mips-protos.h (mips_d_target_versions): New prototype.
6543 * config/mips/mips.h (TARGET_D_CPU_VERSIONS): Define.
6544 * config/mips/t-mips (mips-d.o): New rule.
6545 * config/powerpcspe/linux.h (GNU_USER_TARGET_D_OS_VERSIONS): Define.
6546 * config/powerpcspe/linux64.h (GNU_USER_TARGET_D_OS_VERSIONS): Define.
6547 * config/powerpcspe/powerpcspe-d.c: New file.
6548 * config/powerpcspe/powerpcspe-protos.h (rs6000_d_target_versions):
6549 New prototype.
6550 * config/powerpcspe/powerpcspe.c (rs6000_output_function_epilogue):
6551 Support GNU D by using 0 as the language type.
6552 * config/powerpcspe/powerpcspe.h (TARGET_D_CPU_VERSIONS): Define.
6553 * config/powerpcspe/t-powerpcspe (powerpcspe-d.o): New rule.
6554 * config/riscv/riscv-d.c: New file.
6555 * config/riscv/riscv-protos.h (riscv_d_target_versions): New
6556 prototype.
6557 * config/riscv/riscv.h (TARGET_D_CPU_VERSIONS): Define.
6558 * config/riscv/t-riscv (riscv-d.o): New rule.
6559 * config/rs6000/linux.h (GNU_USER_TARGET_D_OS_VERSIONS): Define.
6560 * config/rs6000/linux64.h (GNU_USER_TARGET_D_OS_VERSIONS): Define.
6561 * config/rs6000/rs6000-d.c: New file.
6562 * config/rs6000/rs6000-protos.h (rs6000_d_target_versions): New
6563 prototype.
6564 * config/rs6000/rs6000.c (rs6000_output_function_epilogue):
6565 Support GNU D by using 0 as the language type.
6566 * config/rs6000/rs6000.h (TARGET_D_CPU_VERSIONS): Define.
6567 * config/rs6000/t-rs6000 (rs6000-d.o): New rule.
6568 * config/s390/s390-d.c: New file.
6569 * config/s390/s390-protos.h (s390_d_target_versions): New prototype.
6570 * config/s390/s390.h (TARGET_D_CPU_VERSIONS): Define.
6571 * config/s390/t-s390 (s390-d.o): New rule.
6572 * config/sparc/sparc-d.c: New file.
6573 * config/sparc/sparc-protos.h (sparc_d_target_versions): New
6574 prototype.
6575 * config/sparc/sparc.h (TARGET_D_CPU_VERSIONS): Define.
6576 * config/sparc/t-sparc (sparc-d.o): New rule.
6577 * config/t-glibc (glibc-d.o): New rule.
6578 * configure: Regenerated.
6579 * configure.ac (tm_d_file): New variable.
6580 (tm_d_file_list, tm_d_include_list, d_target_objs): Add substitutes.
6581 * doc/contrib.texi (Contributors): Add self for the D frontend.
6582 * doc/frontends.texi (G++ and GCC): Mention D as a supported language.
6583 * doc/install.texi (Configuration): Mention libphobos as an option for
6584 --enable-shared. Mention d as an option for --enable-languages.
6585 (Testing): Mention check-d as a target.
6586 * doc/invoke.texi (Overall Options): Mention .d, .dd, and .di as file
6587 name suffixes. Mention d as a -x option.
6588 * doc/sourcebuild.texi (Top Level): Mention libphobos.
6589 * doc/standards.texi (Standards): Add section on D language.
6590 * doc/tm.texi: Regenerated.
6591 * doc/tm.texi.in: Add @node for D language and ABI, and @hook for
6592 TARGET_CPU_VERSIONS, TARGET_D_OS_VERSIONS, and TARGET_D_CRITSEC_SIZE.
6593 * dwarf2out.c (is_dlang): New function.
6594 (gen_compile_unit_die): Use DW_LANG_D for D.
6595 (declare_in_namespace): Return module die for D, instead of adding
6596 extra declarations into the namespace.
6597 (gen_namespace_die): Generate DW_TAG_module for D.
6598 (gen_decl_die): Handle CONST_DECLSs for D.
6599 (dwarf2out_decl): Likewise.
6600 (prune_unused_types_walk_local_classes): Handle DW_tag_interface_type.
6601 (prune_unused_types_walk): Handle DW_tag_interface_type same as other
6602 kinds of aggregates.
6603 * gcc.c (default_compilers): Add entries for .d, .dd and .di.
6604 * genhooks.c: Include d/d-target.def.
6605
6606 2018-10-28 Iain Sandoe <iain@sandoe.co.uk>
6607
6608 PR target/85669
6609 * config/rs6000/darwin.h (STACK_BOUNDARY): New.
6610 (RS6000_STARTING_FRAME_OFFSET): Adjust to preserve 16byte alignment.
6611 (STACK_DYNAMIC_OFFSET): Likewise.
6612
6613 2018-10-27 Sandra Loosemore <sandra@codesourcery.com>
6614
6615 PR target/80024
6616 * config/nios2/nios2.c (nios2_valid_target_attribute_rec): Fix
6617 error message.
6618
6619 2018-10-26 Tulio Magno Quites Machado Filho <tuliom@linux.ibm.com>
6620
6621 * doc/extend.texi (PowerPC builtins): Fix __builtin_unpack_ibm128
6622 return type and other typos.
6623
6624 2018-10-26 Aaron Sawdey <acsawdey@linux.ibm.com>
6625
6626 * config/rs6000/rs6000-string.c (expand_strncmp_gpr_sequence): Change to
6627 a shorter sequence with fewer branches.
6628 (emit_final_str_compare_gpr): Ditto.
6629
6630 2018-10-26 Paul A. Clarke <pc@us.ibm.com>
6631
6632 * config/rs6000/tmmintrin.h: New file.
6633 * config.gcc (powerpc*-*-*): Add tmmintrin.h to extra_headers.
6634
6635 2018-10-26 Paul A. Clarke <pc@us.ibm.com>
6636
6637 * config/rs6000/mmintrin.h: Enable 32bit compilation.
6638 * config/rs6000/xmmintrin.h: Likewise.
6639
6640 2018-10-26 Paul A. Clarke <pc@us.ibm.com>
6641
6642 * config/rs6000/xmmintrin.h (_mm_extract_pi16): Fix for big-endian.
6643
6644 2018-10-26 Richard Biener <rguenther@suse.de>
6645
6646 * tree-vect-slp.c (vect_mark_slp_stmts): Add visited hash_set
6647 and wrapper.
6648 (vect_mark_slp_stmts_relevant): Likewise.
6649 (vect_detect_hybrid_slp_stmts): Likewise.
6650 (vect_bb_slp_scalar_cost): Likewise.
6651 (vect_remove_slp_scalar_calls): Likewise.
6652
6653 2018-10-26 Jan Hubicka <jh@suse.cz>
6654
6655 * ipa-devirt.c (odr_subtypes_equivalent_p): Fix recursion.
6656 (warn_types_mismatch): Fix walk of DECL_NAME.
6657 (odr_types_equivalent_p): Fix overactive assert.
6658
6659 2018-10-26 Richard Biener <rguenther@suse.de>
6660
6661 PR tree-optimization/87105
6662 * tree-vectorizer.h (_slp_tree::refcnt): New member.
6663 * tree-vect-slp.c (vect_free_slp_tree): Decrement and honor
6664 refcnt.
6665 (vect_create_new_slp_node): Initialize refcnt to one.
6666 (bst_traits): Move.
6667 (scalar_stmts_set_t, bst_fail): Remove.
6668 (vect_build_slp_tree_2): Add bst_map argument and adjust calls.
6669 (vect_build_slp_tree): Add bst_map argument and lookup
6670 already created SLP nodes.
6671 (vect_print_slp_tree): Handle a SLP graph, print SLP node
6672 addresses.
6673 (vect_slp_rearrange_stmts): Handle a SLP graph.
6674 (vect_analyze_slp_instance): Adjust and free SLP nodes from
6675 the CSE map. Fix indenting.
6676 (vect_schedule_slp_instance): Add short-cut.
6677
6678 2018-10-26 Martin Liska <mliska@suse.cz>
6679
6680 PR testsuite/86158
6681 * ipa-prop.c (struct ipa_vr_ggc_hash_traits): Hash with
6682 addr_expr and not with pointers.
6683
6684 2018-10-26 Jan Hubicka <jh@suse.cz>
6685
6686 * tree.c (free_lang_data_in_type): Only check main variants.
6687 * ipa-devirt.c (warn_odr): Make static.
6688 (types_same_for_odr): Drop strict variant.
6689 (types_odr_comparable): Likewise.
6690 (odr_or_derived_type_p): Look for main variants.
6691 (odr_name_hasher::equal): Cleanup comment.
6692 (odr_subtypes_equivalent): Add warn and warned arguments; check main
6693 variants.
6694 (type_variants_equivalent_p): break out from ...
6695 (odr_types_equivalent): ... here; go for main variants where needed.
6696 (warn_odr): ... here; turn static.
6697 (warn_types_mismatch): Compare mangled names of main variants.
6698 * ipa-utils.h (types_odr_comparable): Drop strict parameter.
6699 (type_with_linkage_p): Sanity check that we look at main variant.
6700 * lto.c (lto_read_decls): Only consider main variant to be ODR type.
6701 * tree.h (types_same_for_odr): Drop strict argument.
6702
6703 2018-10-26 Richard Biener <rguenther@suse.de>
6704
6705 PR tree-optimization/87746
6706 * tree-vect-data-refs.c (vect_update_misalignment_for_peel):
6707 Simplify and fix WRT strided store groups with size not
6708 equal to step in element count.
6709 (vect_analyze_group_access_1): Dump the whole group.
6710
6711 2018-10-25 Carl Love <cel@us.ibm.com>
6712
6713 * config/rs6000/rs6000-c.c (P9V_BUILTIN_VEC_VSCEDPGT,
6714 P9V_BUILTIN_VEC_VSCEDPLT, P9V_BUILTIN_VEC_VSCEDPEQ,
6715 P9V_BUILTIN_VEC_VSCEDPUO): Rename base overloaded name. Add quad
6716 precicion entry for each overloaded builtin.
6717 * config/rs6000/rs6000-builtin.def (VSCEDPGT, VSCEDPLT, VSCEDPEQ,
6718 VSCEDPUO): Rename overloaded name.
6719 (VSCEDPGT, VSCEQPGT, VSCEDPLT, VSCEQPLT, VSCEDPEQ, VSCEQPEQ,
6720 VSCEDPUO, VSCEQPUO): Add defitions for overloaded builtins.
6721 * config/rs6000/vsx.md (xscmpexpqp_<code>_<mode>): Add
6722 define_expand for xscmpexqp instruction.
6723 (*xscmpexpqp): Add define_insn for the xscmpexqp instruction.
6724
6725 2018-10-25 Bill Schmidt <wschmidt@linux.ibm.com>
6726 Jinsong Ji <jji@us.ibm.com>
6727
6728 * config/rs6000/emmintrin.h (_mm_slli_epi16): Replace deprecated
6729 function with vec_sl.
6730 (_mm_slli_epi32): Likewise.
6731 (_mm_slli_epi64): Likewise.
6732 (_mm_srai_epi16): Replace deprecated function with vec_sra.
6733 (_mm_srai_epi32): Likewise.
6734 (_mm_srli_epi16): Replace deprecated function with vec_sr.
6735 (_mm_srli_epi32): Likewise.
6736 (_mm_srli_epi64): Likewise.
6737 (_mm_sll_epi16): Replace deprecated function with vec_sl.
6738 (_mm_sll_epi32): Likewise.
6739 (_mm_sll_epi64): Likewise.
6740 (_mm_sra_epi16): Replace deprecated function with vec_sra.
6741 (_mm_sra_epi32): Likewise.
6742 (_mm_srl_epi16): Replace deprecated function with vec_sr.
6743 (_mm_srl_epi32): Likewise.
6744 (_mm_srl_epi64): Likewise.
6745
6746 2018-10-25 Bill Schmidt <wschmidt@linux.ibm.com>
6747 Jinsong Ji <jji@us.ibm.com>
6748
6749 * gcc/config/rs6000/emmintrin.h (_mm_sll_epi16): Replace
6750 comparison operators with vec_cmp* for compatibility due to
6751 unfortunate history; clean up formatting and use types more
6752 appropriately.
6753 (_mm_sll_epi32): Likewise.
6754 (_mm_sll_epi64): Likewise.
6755 (_mm_srl_epi16): Likewise.
6756 (_mm_srl_epi32): Likewise.
6757 (_mm_srl_epi64): Likewise.
6758
6759 2018-10-25 Bill Schmidt <wschmidt@linux.ibm.com>
6760 Jinsong Ji <jji@us.ibm.com>
6761
6762 * config/rs6000/emmintrin.h (_mm_sll_epi64): Remove wrong cast.
6763 * config/rs6000/xmmintrin.h (_mm_min_ps): Change m's type to
6764 __vector __bool int. Use vec_cmpgt in preference to deprecated
6765 function vec_vcmpgtfp.
6766 (_mm_max_ps): Likewise.
6767
6768 2018-10-25 Jeff Law <law@redhat.com>
6769
6770 * config/rl78/rl78.c (insn_ok_now): Always re-recognize the insn
6771 if returning false.
6772
6773 2018-10-25 Martin Sebor <msebor@redhat.com>
6774
6775 * doc/extend.texi (aligned): Expand attribute description.
6776 (Alignment): Rename section. Discuss function arguments.
6777
6778 2018-10-25 Jan Hubicka <jh@suse.cz>
6779
6780 * ipa-devirt.c (main_odr_variant): Remove.
6781 (hash_odr_name, types_same_for_odr, types_odr_comparable,
6782 odr_name_hasher::equal, odr_subtypes_equivalent_p):
6783 Drop use of main_odr_variant.
6784 (add_type_duplicate): Silence confused warnings on integer types.
6785 (get_odr_type): Always look for main variant.
6786 (register_odr_type): Simplify.
6787
6788 2018-10-25 Richard Biener <rguenther@suse.de>
6789
6790 * tree-vect-data-refs.c (vect_analyze_data_ref_accesses):
6791 Initialize ng to silence error with release checking bootstrap.
6792
6793 2018-10-25 Richard Biener <rguenther@suse.de>
6794
6795 * tree-if-conv.c: Include tree-ssa-sccvn.h.
6796 (tree_if_conversion): Run CSE on the if-converted loop body.
6797
6798 2018-10-25 Ilya Leoshkevich <iii@linux.ibm.com>
6799
6800 * config/s390/constraints.md (ZL): New constraint.
6801 * config/s390/s390.c (legitimate_pic_operand_p): Accept LARL
6802 operands.
6803 * config/s390/s390.md (movdi_larl): Remove.
6804 (movdi_64): Add the LARL alternative.
6805
6806 2018-10-25 Ilya Leoshkevich <iii@linux.ibm.com>
6807
6808 PR bootstrap/87747
6809 * rtl.c (RTX_CODE_HWINT_P_1): New helper macro.
6810 (RTX_CODE_HWINT_P): New macro.
6811 (rtx_code_size): Use RTX_CODE_HWINT_P ().
6812
6813 2018-10-25 Jan Hubicka <jh@suse.cz>
6814
6815 * ipa-devirt.c (odr_types_equivalent_p): Do not ICE if one of types
6816 is anonymous.
6817
6818 2018-10-25 Richard Biener <rguenther@suse.de>
6819
6820 PR tree-optimization/87665
6821 PR tree-optimization/87745
6822 * tree-vectorizer.h (get_earlier_stmt): Remove.
6823 (get_later_stmt): Pick up UID from the original non-pattern stmt.
6824
6825 2018-10-25 Sam Tebbs <sam.tebbs@arm.com>
6826
6827 * options.texi (Deprecated): Move list to Var section.
6828
6829 2018-10-24 Bill Schmidt <wschmidt@linux.ibm.com>
6830 Jinsong Ji <jji@us.ibm.com>
6831
6832 * config/rs6000/emmintrin.h (_mm_cvtpd_epi32): Change deprecated
6833 __vector long to __vector long long.
6834 (_mm_cvtpd_ps): Likewise.
6835 (_mm_cvttpd_epi32): Likewise.
6836 (_mm_cvtpi32_pd): Likewise.
6837 (_mm_unpackhi_epi64): Likewise.
6838 (_mm_unpacklo_epi64): Likewise.
6839
6840 2018-10-24 Segher Boessenkool <segher@kernel.crashing.org>
6841
6842 PR rtl-optimization/87720
6843 * combine.c (make_more_copies): Skip if the dest is pc_rtx.
6844
6845 2018-10-24 Alexandre Oliva <aoliva@redhat.com>
6846
6847 * gimple-ssa-isolate-paths.c
6848 (find_implicit_erroneous_behavior): Do not change code if the
6849 pass is running for warnings only.
6850 (find_explicit_erroneous_behavior): Likewise.
6851
6852 2018-10-24 Michael Meissner <meissner@linux.ibm.com>
6853
6854 * config/rs6000/rs6000.c (TARGET_MANGLE_DECL_ASSEMBLER_NAME):
6855 Define as rs6000_mangle_decl_assembler_name.
6856 (rs6000_mangle_decl_assembler_name): If the user switched from IBM
6857 long double to IEEE long double, switch the names of the long
6858 double built-in functions to be <func>f128 instead of <func>l.
6859
6860 2018-10-24 Martin Sebor <msebor@redhat.com>
6861
6862 * doc/extend.texi (nonnull): List no-argument form. Reference
6863 -fno-delete-null-pointer-checks and -fisolate-erroneous-paths-attribute.
6864
6865 2018-10-24 Richard Biener <rguenther@suse.de>
6866
6867 * tree-ssa-sccvn.c (do_rpo_vn): Free rpo_state.
6868
6869 2018-10-24 Martin Liska <mliska@suse.cz>
6870
6871 PR tree-optimization/84436
6872 * tree-switch-conversion.c (switch_conversion::contains_same_values_p):
6873 Remove.
6874 (switch_conversion::contains_linear_function_p): New.
6875 (switch_conversion::build_one_array): Support linear
6876 transformation on input.
6877 * tree-switch-conversion.h (struct switch_conversion): Add
6878 contains_linear_function_p declaration.
6879
6880 2018-10-24 Richard Biener <rguenther@suse.de>
6881
6882 * varasm.c (const_hash_1): Return hash of ADDR_EXPR
6883 if its argument is CONSTANT_CLASS_P.
6884
6885 2018-10-11 Jan Hubicka <hubicka@ucw.cz>
6886
6887 * ipa-utils.h (type_with_linkage_p): No longer check for TYPE_STUB_DECL;
6888 it is wrong for forward declarations.
6889
6890 2018-10-24 Ilya Leoshkevich <iii@linux.ibm.com>
6891
6892 * config/s390/s390.c (s390_check_qrst_address): Add the missing
6893 SYMBOL_REF_P () check.
6894
6895 2018-10-24 Richard Biener <rguenther@suse.de>
6896
6897 PR tree-optimization/87105
6898 * tree-vect-data-refs.c (vect_analyze_group_access_1): Adjust
6899 dump classification.
6900 (vect_analyze_data_ref_accesses): Handle duplicate loads and
6901 stores by splitting the affected group after the fact.
6902 * tree-vect-slp.c (vect_build_slp_tree_2): Dump when we
6903 fail the SLP build because of size constraints.
6904
6905 2018-10-24 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6906
6907 * configure.ac (gcc_cv_ld_aligned_shf_merge): New test.
6908 * configure: Regenerate.
6909 * config.in: Regenerate.
6910 * varasm.c (mergeable_string_section): Use readonly_data_section
6911 if linker doesn't support SHF_MERGE with alignment > 8.
6912 (mergeable_constant_section): Likewise.
6913
6914 2018-10-24 Richard Biener <rguenther@suse.de>
6915
6916 PR tree-optimization/84013
6917 * tree-ssa-structalias.c (struct msdi_data): New struct for
6918 marshalling data to walk_stmt_load_store_ops.
6919 (maybe_set_dependence_info): Refactor as callback for
6920 walk_stmt_load_store_ops.
6921 (compute_dependence_clique): Set restrict info on all stmt kinds.
6922
6923 2018-10-24 Martin Liska <mliska@suse.cz>
6924
6925 * cgraph.c (cgraph_node::dump):
6926 Remove reduntant dumps and make tp_first_run dump more compact.
6927
6928 2018-10-24 Richard Biener <rguenther@suse.de>
6929
6930 PR tree-optimization/87665
6931 * tree-vect-data-refs.c (vect_preserves_scalar_order_p): Adjust
6932 to reflect reality.
6933
6934 2018-10-12 Jeff Law <law@redhat.com>
6935
6936 * config/h8300/h8300.c (h8300_expand_prologue): Fix stm generation
6937 for H8/S.
6938
6939 2018-10-23 Richard Biener <rguenther@suse.de>
6940
6941 * tree-vrp.c (add_assert_info): Guard dump_printf with
6942 dump_enabled_p.
6943 * gimple-ssa-evrp-analyze.c
6944 (evrp_range_analyzer::record_ranges_from_incoming_edge):
6945 Use value_range::ignore_equivs_equal_p.
6946
6947 2018-10-23 Richard Biener <rguenther@suse.de>
6948
6949 PR tree-optimization/87105
6950 PR tree-optimization/87608
6951 * passes.def (pass_all_early_optimizations): Add early phi-opt
6952 after dce.
6953 * tree-ssa-phiopt.c (value_replacement): Ignore NOPs and predicts in
6954 addition to debug stmts.
6955 (tree_ssa_phiopt_worker): Add early_p argument, do only min/max
6956 and abs replacement early.
6957 * tree-cfg.c (gimple_empty_block_p): Likewise.
6958
6959 2018-10-23 Richard Earnshaw <rearnsha@arm.com>
6960
6961 PR target/86383
6962 * config.gcc (arm*-*-netbsdelf*): Default to StrongARM if no CPU
6963 specified to configure.
6964 (arm*-*-*): Use ARM7TDMI as the target CPU if no default provided.
6965
6966 2018-10-23 Richard Biener <rguenther@suse.de>
6967
6968 PR tree-optimization/87700
6969 * tree-ssa-copy.c (set_copy_of_val): Fix change detection logic.
6970
6971 2018-10-23 Jakub Jelinek <jakub@redhat.com>
6972
6973 PR target/87674
6974 * config/i386/avx512vlintrin.h (_mm_mask_mullo_epi32): Change type of
6975 second argument from __mmask16 to __mmask8.
6976 * config/i386/avx512vlbwintrin.h (_mm_mask_packus_epi32,
6977 _mm_mask_packs_epi32): Likewise.
6978 * config/i386/avx512pfintrin.h (_mm512_mask_prefetch_i64scatter_ps):
6979 Likewise.
6980 (_mm512_mask_prefetch_i64scatter_pd): Likewise. Formatting fix.
6981
6982 2018-10-23 Richard Biener <rguenther@suse.de>
6983
6984 * tree-vect-stmts.c (vect_analyze_stmt): Fix typo in comment.
6985
6986 2018-10-23 Richard Biener <rguenther@suse.de>
6987
6988 PR tree-optimization/86144
6989 * tree-vect-stmts.c (vect_analyze_stmt): Prefer -mveclibabi
6990 over simd attribute.
6991
6992 2018-10-23 Richard Biener <rguenther@suse.de>
6993
6994 PR tree-optimization/87693
6995 * tree-ssa-threadedge.c (thread_around_empty_blocks): Handle
6996 the case we do not find the taken edge.
6997
6998 2018-10-22 Bill Schmidt <wschmidt@linux.ibm.com>
6999 Jinsong Ji <jji@us.ibm.com>
7000
7001 * config/rs6000/emmintrin.h (_MM_SHUFFLE2): Comment cleanup.
7002 (_mm_store_pd): Use unaligned vector type for pointer cast.
7003 (_mm_maskmoveu_si128): Likewise.
7004 * config/rs6000/xmmintrin.h (__m128_u): New typedef.
7005 (_mm_store_ps): Use unaligned vector type for pointer cast.
7006
7007 2018-10-22 Paul Koning <ni1d@arrl.net>
7008
7009 * symtab.c (symtab_node::increase_alignment): Correct max
7010 alignment check.
7011
7012 2018-10-22 Yury Gribov <tetra2005@gmail.com>
7013
7014 PR tree-optimization/87633
7015 * match.pd: Do not generate unordered integer comparisons.
7016
7017 2018-10-22 Segher Boessenkool <segher@kernel.crashing.org>
7018
7019 PR rtl-optimization/87600
7020 * combine.c: Add include of expr.h.
7021 (cant_combine_insn_p): Do not combine moves from any hard non-fixed
7022 register to a pseudo.
7023 (make_more_copies): New function, add a copy to a new pseudo after
7024 the moves from hard registers into pseudos.
7025 (rest_of_handle_combine): Declare rebuild_jump_labels_after_combine
7026 later. Call make_more_copies.
7027
7028 2018-10-22 Andrew Stubbs <ams@codesourcery.com>
7029
7030 * lra-constraints.c (process_alt_operands): New local array,
7031 matching_early_clobber. Check matching_early_clobber before
7032 decrementing reject, and set matching_early_clobber after.
7033
7034 2018-10-22 Segher Boessenkool <segher@kernel.crashing.org>
7035
7036 PR target/87598
7037 * config/rs6000/rs6000.c (print_operand_address): For unexpected RTL
7038 call output_addr_const and hope for the best.
7039
7040 2018-10-22 Richard Biener <rguenther@suse.de>
7041
7042 * gimple-ssa-evrp-analyze.c
7043 (evrp_range_analyzer::record_ranges_from_incoming_edge): Be
7044 smarter about what ranges to use.
7045 * tree-vrp.c (add_assert_info): Dump here.
7046 (register_edge_assert_for_2): Instead of here at multiple but
7047 not all places.
7048
7049 * gcc.dg/tree-ssa/evrp12.c: New testcase.
7050 * gcc.dg/predict-6.c: Adjust.
7051 * gcc.dg/tree-ssa/vrp33.c: Disable EVRP.
7052 * gcc.dg/tree-ssa/vrp02.c: Likewise.
7053 * gcc.dg/tree-ssa/cunroll-9.c: Likewise.
7054
7055 2018-10-22 Steven Bosscher <steven@gcc.gnu.org>
7056 Richard Biener <rguenther@suse.de>
7057
7058 * bitmap.h: Update data structure documentation, including a
7059 description of bitmap views as either linked-lists or splay trees.
7060 (struct bitmap_element_def): Update comments for splay tree bitmaps.
7061 (struct bitmap_head_def): Likewise.
7062 (bitmap_list_view, bitmap_tree_view): New prototypes.
7063 (bitmap_initialize_stat): Initialize a bitmap_head's indx and
7064 tree_form fields.
7065 (bmp_iter_set_init): Assert the iterated bitmaps are in list form.
7066 (bmp_iter_and_init, bmp_iter_and_compl_init): Likewise.
7067 * bitmap.c (bitmap_elem_to_freelist): Unregister overhead of a
7068 released bitmap element here.
7069 (bitmap_element_free): Remove.
7070 (bitmap_elt_clear_from): Work on splay tree bitmaps.
7071 (bitmap_list_link_element): Renamed from bitmap_element_link. Move
7072 this function similar ones such that linked-list bitmap implementation
7073 functions are grouped.
7074 (bitmap_list_unlink_element): Renamed from bitmap_element_unlink,
7075 and moved for grouping.
7076 (bitmap_list_insert_element_after): Renamed from
7077 bitmap_elt_insert_after, and moved for grouping.
7078 (bitmap_list_find_element): New function spliced from bitmap_find_bit.
7079 (bitmap_tree_link_left, bitmap_tree_link_right,
7080 bitmap_tree_rotate_left, bitmap_tree_rotate_right, bitmap_tree_splay,
7081 bitmap_tree_link_element, bitmap_tree_unlink_element,
7082 bitmap_tree_find_element): New functions for splay-tree bitmap
7083 implementation.
7084 (bitmap_element_link, bitmap_element_unlink, bitmap_elt_insert_after):
7085 Renamed and moved, see above entries.
7086 (bitmap_tree_listify_from): New function to convert part of a splay
7087 tree bitmap to a linked-list bitmap.
7088 (bitmap_list_view): Convert a splay tree bitmap to linked-list form.
7089 (bitmap_tree_view): Convert a linked-list bitmap to splay tree form.
7090 (bitmap_find_bit): Remove.
7091 (bitmap_clear, bitmap_clear_bit, bitmap_set_bit,
7092 bitmap_single_bit_set_p, bitmap_first_set_bit, bitmap_last_set_bit):
7093 Handle splay tree bitmaps.
7094 (bitmap_copy, bitmap_count_bits, bitmap_and, bitmap_and_into,
7095 bitmap_elt_copy, bitmap_and_compl, bitmap_and_compl_into,
7096 bitmap_compl_and_into, bitmap_elt_ior, bitmap_ior, bitmap_ior_into,
7097 bitmap_xor, bitmap_xor_into, bitmap_equal_p, bitmap_intersect_p,
7098 bitmap_intersect_compl_p, bitmap_ior_and_compl,
7099 bitmap_ior_and_compl_into, bitmap_set_range, bitmap_clear_range,
7100 bitmap_hash): Reject trying to act on splay tree bitmaps. Make
7101 corresponding changes to use linked-list specific bitmap_element
7102 manipulation functions as applicable for efficiency.
7103 (bitmap_tree_to_vec): New function.
7104 (debug_bitmap_elt_file): New function split out from ...
7105 (debug_bitmap_file): ... here. Handle splay tree bitmaps.
7106 (bitmap_print): Likewise.
7107
7108 PR tree-optimization/63155
7109 * tree-ssa-propagate.c (ssa_prop_init): Use tree-view for the
7110 SSA edge worklists.
7111 * tree-ssa-coalesce.c (coalesce_ssa_name): Populate used_in_copies
7112 in tree-view.
7113
7114 2018-10-22 Martin Liska <mliska@suse.cz>
7115
7116 PR tree-optimization/87686
7117 Revert
7118 2018-08-29 Martin Liska <mliska@suse.cz>
7119
7120 * tree-switch-conversion.c (switch_conversion::expand):
7121 Strenghten assumption about gswitch statements.
7122
7123 2018-10-22 Martin Liska <mliska@suse.cz>
7124
7125 * ipa-icf.c (sem_item::compare_attributes): Remove.
7126 (sem_item::compare_referenced_symbol_properties): Use
7127 attribute_list_equal instead.
7128 (sem_function::equals_wpa): Likewise.
7129 * ipa-icf.h: Remove compare_attributes.
7130
7131 2018-10-22 Richard Biener <rguenther@suse.de>
7132
7133 PR middle-end/87682
7134 * mem-stats.h (mem_usage::operator==): Fix pasto.
7135
7136 2018-10-22 Richard Biener <rguenther@suse.de>
7137
7138 PR tree-optimization/87640
7139 * tree-vrp.c (set_value_range_with_overflow): Decompose
7140 incomplete result.
7141 (extract_range_from_binary_expr_1): Adjust.
7142
7143 2018-10-22 Martin Jambor <mjambor@suse.cz>
7144
7145 * tree-eh.h (stmt_could_throw_p): Add function parameter.
7146 (stmt_can_throw_external): Likewise.
7147 (stmt_can_throw_internal): Likewise.
7148 * tree-eh.c (lower_eh_constructs_2): Pass cfun to stmt_could_throw_p.
7149 (lower_eh_constructs_2): Likewise.
7150 (stmt_could_throw_p): Add fun parameter, use it instead of cfun.
7151 (stmt_can_throw_external): Likewise.
7152 (stmt_can_throw_internal): Likewise.
7153 (maybe_clean_eh_stmt_fn): Pass cfun to stmt_could_throw_p.
7154 (maybe_clean_or_replace_eh_stmt): Pass cfun to stmt_could_throw_p.
7155 (maybe_duplicate_eh_stmt_fn): Pass new_fun to stmt_could_throw_p.
7156 (maybe_duplicate_eh_stmt): Pass cfun to stmt_could_throw_p.
7157 (pass_lower_eh_dispatch::execute): Pass cfun to
7158 stmt_can_throw_external.
7159 (cleanup_empty_eh): Likewise.
7160 (verify_eh_edges): Pass cfun to stmt_could_throw_p.
7161 * cgraph.c (cgraph_edge::set_call_stmt): Pass a function to
7162 stmt_can_throw_external instead of pushing it to cfun.
7163 (symbol_table::create_edge): Likewise.
7164 * gimple-fold.c (fold_builtin_atomic_compare_exchange): Pass cfun to
7165 stmt_can_throw_internal.
7166 * gimple-ssa-evrp.c (evrp_dom_walker::before_dom_children): Pass cfun
7167 to stmt_could_throw_p.
7168 * gimple-ssa-store-merging.c (handled_load): Pass cfun to
7169 stmt_can_throw_internal.
7170 (pass_store_merging::execute): Likewise.
7171 * gimple-ssa-strength-reduction.c
7172 (find_candidates_dom_walker::before_dom_children): Pass cfun to
7173 stmt_could_throw_p.
7174 * gimplify-me.c (gimple_regimplify_operands): Pass cfun to
7175 stmt_can_throw_internal.
7176 * ipa-pure-const.c (check_call): Pass cfun to stmt_could_throw_p and
7177 to stmt_can_throw_external.
7178 (check_stmt): Pass cfun to stmt_could_throw_p.
7179 (check_stmt): Pass cfun to stmt_can_throw_external.
7180 (pass_nothrow::execute): Likewise.
7181 * trans-mem.c (expand_call_tm): Pass cfun to stmt_can_throw_internal.
7182 * tree-cfg.c (is_ctrl_altering_stmt): Pass cfun to
7183 stmt_can_throw_internal.
7184 (verify_gimple_in_cfg): Pass cfun to stmt_could_throw_p.
7185 (stmt_can_terminate_bb_p): Pass cfun to stmt_can_throw_external.
7186 (gimple_purge_dead_eh_edges): Pass cfun to stmt_can_throw_internal.
7187 * tree-complex.c (expand_complex_libcall): Pass cfun to
7188 stmt_could_throw_p and to stmt_can_throw_internal.
7189 (expand_complex_multiplication): Pass cfun to stmt_can_throw_internal.
7190 * tree-inline.c (copy_edges_for_bb): Likewise.
7191 (maybe_move_debug_stmts_to_successors): Likewise.
7192 * tree-outof-ssa.c (ssa_is_replaceable_p): Pass cfun to
7193 stmt_could_throw_p.
7194 * tree-parloops.c (oacc_entry_exit_ok_1): Likewise.
7195 * tree-sra.c (scan_function): Pass cfun to stmt_can_throw_external.
7196 * tree-ssa-alias.c (stmt_kills_ref_p): Pass cfun to
7197 stmt_can_throw_internal.
7198 * tree-ssa-ccp.c (optimize_atomic_bit_test_and): Likewise.
7199 * tree-ssa-dce.c (mark_stmt_if_obviously_necessary): Pass cfun to
7200 stmt_could_throw_p.
7201 (mark_aliased_reaching_defs_necessary_1): Pass cfun to
7202 stmt_can_throw_internal.
7203 * tree-ssa-forwprop.c (pass_forwprop::execute): Likewise.
7204 * tree-ssa-loop-im.c (movement_possibility): Pass cfun to
7205 stmt_could_throw_p.
7206 * tree-ssa-loop-ivopts.c (find_givs_in_stmt_scev): Likewise.
7207 (add_autoinc_candidates): Pass cfun to stmt_can_throw_internal.
7208 * tree-ssa-math-opts.c (pass_cse_reciprocals::execute): Likewise.
7209 (convert_mult_to_fma_1): Likewise.
7210 (convert_to_divmod): Likewise.
7211 * tree-ssa-phiprop.c (propagate_with_phi): Likewise.
7212 * tree-ssa-pre.c (compute_avail): Pass cfun to stmt_could_throw_p.
7213 * tree-ssa-propagate.c
7214 (substitute_and_fold_dom_walker::before_dom_children): Likewise.
7215 * tree-ssa-reassoc.c (suitable_cond_bb): Likewise.
7216 (maybe_optimize_range_tests): Likewise.
7217 (linearize_expr_tree): Likewise.
7218 (reassociate_bb): Likewise.
7219 * tree-ssa-sccvn.c (copy_reference_ops_from_call): Likewise.
7220 * tree-ssa-scopedtables.c (hashable_expr_equal_p): Likewise.
7221 * tree-ssa-strlen.c (adjust_last_stmt): Likewise.
7222 (handle_char_store): Likewise.
7223 * tree-vect-data-refs.c (vect_find_stmt_data_reference): Pass cfun to
7224 stmt_can_throw_internal.
7225 * tree-vect-patterns.c (check_bool_pattern): Pass cfun to
7226 stmt_could_throw_p.
7227 * tree-vect-stmts.c (vect_finish_stmt_generation_1): Likewise.
7228 (vectorizable_call): Pass cfun to stmt_can_throw_internal.
7229 (vectorizable_simd_clone_call): Likewise.
7230 * value-prof.c (gimple_ic): Pass cfun to stmt_could_throw_p.
7231 (gimple_stringop_fixed_value): Likewise.
7232
7233 2018-10-22 Ilya Leoshkevich <iii@linux.ibm.com>
7234
7235 * config/s390/s390.c (s390_loadrelative_operand_p): Accept
7236 literal pool references.
7237 (s390_check_qrst_address): Adapt to the new behavior of
7238 s390_loadrelative_operand_p ().
7239
7240 2018-10-22 H.J. Lu <hongjiu.lu@intel.com>
7241
7242 PR target/72782
7243 * config/i386/sse.md (*andnot<mode>3_bcst): New.
7244
7245 2018-10-22 H.J. Lu <hongjiu.lu@intel.com>
7246
7247 PR target/72782
7248 * config/i386/sse.md (*<code><mode>3_bcst): New.
7249
7250 2018-10-22 H.J. Lu <hongjiu.lu@intel.com>
7251
7252 PR target/72782
7253 * config/i386/sse.md (avx512bcst): Updated for V4SI, V2DI, V8SI,
7254 V4DI, V16SI and V8DI.
7255 (*sub<mode>3<mask_name>_bcst): New.
7256 (*add<mode>3<mask_name>_bcst): Likewise.
7257
7258 2018-10-21 Bill Schmidt <wschmidt@linux.ibm.com>
7259 Jinsong Ji <jji@us.ibm.com>
7260
7261 * config/rs6000/emmintrin.h (_mm_movemask_pd): Replace __vector
7262 __m64 with __vector unsigned long long for compatibility.
7263 (_mm_movemask_epi8): Likewise.
7264 * config/rs6000/xmmintrin.h (_mm_cvtps_pi32): Likewise.
7265 (_mm_cvttps_pi32): Likewise.
7266 (_mm_cvtpi32_ps): Likewise.
7267 (_mm_cvtps_pi16): Likewise.
7268 (_mm_loadh_pi): Likewise.
7269 (_mm_storeh_pi): Likewise.
7270 (_mm_movehl_ps): Likewise.
7271 (_mm_movelh_ps): Likewise.
7272 (_mm_loadl_pi): Likewise.
7273 (_mm_storel_pi): Likewise.
7274 (_mm_movemask_ps): Likewise.
7275 (_mm_shuffle_pi16): Likewise.
7276
7277 2018-10-21 H.J. Lu <hongjiu.lu@intel.com>
7278
7279 PR target/72782
7280 * config/i386/avx512fintrin.h (_mm512_fnmsub_round_pd): Use
7281 __builtin_ia32_vfnmsubpd512_mask.
7282 (_mm512_mask_fnmsub_round_pd): Likewise.
7283 (_mm512_fnmsub_pd): Likewise.
7284 (_mm512_mask_fnmsub_pd): Likewise.
7285 (_mm512_maskz_fnmsub_round_pd): Use
7286 __builtin_ia32_vfnmsubpd512_maskz.
7287 (_mm512_maskz_fnmsub_pd): Likewise.
7288 (_mm512_fnmsub_round_ps): Use __builtin_ia32_vfnmsubps512_mask.
7289 (_mm512_mask_fnmsub_round_ps): Likewise.
7290 (_mm512_fnmsub_ps): Likewise.
7291 (_mm512_mask_fnmsub_ps): Likewise.
7292 (_mm512_maskz_fnmsub_round_ps): Use
7293 __builtin_ia32_vfnmsubps512_maskz.
7294 (_mm512_maskz_fnmsub_ps): Likewise.
7295 * config/i386/avx512vlintrin.h (_mm256_mask_fnmsub_pd): Use
7296 __builtin_ia32_vfnmsubpd256_mask.
7297 (_mm256_maskz_fnmsub_pd): Use __builtin_ia32_vfnmsubpd256_maskz.
7298 (_mm_mask_fnmsub_pd): Use __builtin_ia32_vfmaddpd128_mask
7299 (_mm_maskz_fnmsub_pd): Use __builtin_ia32_vfnmsubpd128_maskz.
7300 (_mm256_mask_fnmsub_ps): Use __builtin_ia32_vfnmsubps256_mask.
7301 (_mm256_mask_fnmsub_ps): Use __builtin_ia32_vfnmsubps256_mask.
7302 (_mm256_maskz_fnmsub_ps): Use __builtin_ia32_vfnmsubps256_maskz.
7303 (_mm_mask_fnmsub_ps): Use __builtin_ia32_vfnmsubps128_mask.
7304 (_mm_maskz_fnmsub_ps): Use __builtin_ia32_vfnmsubps128_maskz.
7305 * config/i386/fmaintrin.h (_mm_fnmsub_pd): Use
7306 __builtin_ia32_vfnmsubpd.
7307 (_mm256_fnmsub_pd): Use __builtin_ia32_vfnmsubpd256.
7308 (_mm_fnmsub_ps): Use __builtin_ia32_vfnmsubps.
7309 (_mm256_fnmsub_ps): Use __builtin_ia32_vfnmsubps256.
7310 (_mm_fnmsub_sd): Use __builtin_ia32_vfnmsubsd3.
7311 (_mm_fnmsub_ss): Use __builtin_ia32_vfnmsubss3.
7312 * config/i386/i386-builtin.def: Add
7313 __builtin_ia32_vfnmsubpd256_mask,
7314 __builtin_ia32_vfnmsubpd256_maskz,
7315 __builtin_ia32_vfnmsubpd128_mask,
7316 __builtin_ia32_vfnmsubpd128_maskz,
7317 __builtin_ia32_vfnmsubps256_mask,
7318 __builtin_ia32_vfnmsubps256_maskz,
7319 __builtin_ia32_vfnmsubps128_mask,
7320 __builtin_ia32_vfnmsubps128_maskz,
7321 __builtin_ia32_vfnmsubpd512_mask,
7322 __builtin_ia32_vfnmsubpd512_maskz,
7323 __builtin_ia32_vfnmsubps512_mask,
7324 __builtin_ia32_vfnmsubps512_maskz, __builtin_ia32_vfnmsubss3,
7325 __builtin_ia32_vfnmsubsd3, __builtin_ia32_vfnmsubps,
7326 __builtin_ia32_vfnmsubpd, __builtin_ia32_vfnmsubps256 and.
7327 __builtin_ia32_vfnmsubpd256.
7328 * config/i386/sse.md (fma4i_fnmsub_<mode>): New.
7329 (<avx512>_fnmsub_<mode>_maskz<round_expand_name>): Likewise.
7330 (*<sd_mask_codefor>fma_fnmsub_<mode><sd_maskz_name>_bcst_1):
7331 Likewise.
7332 (*<sd_mask_codefor>fma_fnmsub_<mode><sd_maskz_name>_bcst_2):
7333 Likewise.
7334 (*<sd_mask_codefor>fma_fnmsub_<mode><sd_maskz_name>_bcst_3):
7335 Likewise.
7336 (fmai_vmfnmsub_<mode><round_name>): Likewise.
7337
7338 2018-10-21 H.J. Lu <hongjiu.lu@intel.com>
7339
7340 PR target/72782
7341 * config/i386/avx512fintrin.h (_mm512_fnmadd_round_pd): Use
7342 __builtin_ia32_vfnmaddpd512_mask.
7343 (_mm512_mask_fnmadd_round_pd): Likewise.
7344 (_mm512_fnmadd_pd): Likewise.
7345 (_mm512_mask_fnmadd_pd): Likewise.
7346 (_mm512_maskz_fnmadd_round_pd): Use
7347 __builtin_ia32_vfnmaddpd512_maskz.
7348 (_mm512_maskz_fnmadd_pd): Likewise.
7349 (_mm512_fnmadd_round_ps): Use __builtin_ia32_vfnmaddps512_mask.
7350 (_mm512_mask_fnmadd_round_ps): Likewise.
7351 (_mm512_fnmadd_ps): Likewise.
7352 (_mm512_mask_fnmadd_ps): Likewise.
7353 (_mm512_maskz_fnmadd_round_ps): Use
7354 __builtin_ia32_vfnmaddps512_maskz.
7355 (_mm512_maskz_fnmadd_ps): Likewise.
7356 * config/i386/avx512vlintrin.h (_mm256_mask_fnmadd_pd): Use
7357 __builtin_ia32_vfnmaddpd256_mask.
7358 (_mm256_maskz_fnmadd_pd): Use __builtin_ia32_vfnmaddpd256_maskz.
7359 (_mm_mask_fnmadd_pd): Use __builtin_ia32_vfmaddpd128_mask
7360 (_mm_maskz_fnmadd_pd): Use __builtin_ia32_vfnmaddpd128_maskz.
7361 (_mm256_mask_fnmadd_ps): Use __builtin_ia32_vfnmaddps256_mask.
7362 (_mm256_mask_fnmadd_ps): Use __builtin_ia32_vfnmaddps256_mask.
7363 (_mm256_maskz_fnmadd_ps): Use __builtin_ia32_vfnmaddps256_maskz.
7364 (_mm_mask_fnmadd_ps): Use __builtin_ia32_vfnmaddps128_mask.
7365 (_mm_maskz_fnmadd_ps): Use __builtin_ia32_vfnmaddps128_maskz.
7366 * config/i386/fmaintrin.h (_mm_fnmadd_pd): Use
7367 __builtin_ia32_vfnmaddpd.
7368 (_mm256_fnmadd_pd): Use __builtin_ia32_vfnmaddpd256.
7369 (_mm_fnmadd_ps): Use __builtin_ia32_vfnmaddps.
7370 (_mm256_fnmadd_ps): Use __builtin_ia32_vfnmaddps256.
7371 (_mm_fnmadd_sd): Use __builtin_ia32_vfnmaddsd3.
7372 (_mm_fnmadd_ss): Use __builtin_ia32_vfnmaddss3.
7373 * config/i386/i386-builtin.def: Add
7374 __builtin_ia32_vfnmaddpd256_mask,
7375 __builtin_ia32_vfnmaddpd256_maskz,
7376 __builtin_ia32_vfnmaddpd128_mask,
7377 __builtin_ia32_vfnmaddpd128_maskz,
7378 __builtin_ia32_vfnmaddps256_mask,
7379 __builtin_ia32_vfnmaddps256_maskz,
7380 __builtin_ia32_vfnmaddps128_mask,
7381 __builtin_ia32_vfnmaddps128_maskz,
7382 __builtin_ia32_vfnmaddpd512_mask,
7383 __builtin_ia32_vfnmaddpd512_maskz,
7384 __builtin_ia32_vfnmaddps512_mask,
7385 __builtin_ia32_vfnmaddps512_maskz, __builtin_ia32_vfnmaddss3,
7386 __builtin_ia32_vfnmaddsd3, __builtin_ia32_vfnmaddps,
7387 __builtin_ia32_vfnmaddpd, __builtin_ia32_vfnmaddps256 and.
7388 __builtin_ia32_vfnmaddpd256.
7389 * config/i386/sse.md (fma4i_fnmadd_<mode>): New.
7390 (<avx512>_fnmadd_<mode>_maskz<round_expand_name>): Likewise.
7391 (*<sd_mask_codefor>fma_fnmadd_<mode><sd_maskz_name>_bcst_1):
7392 Likewise.
7393 (*<sd_mask_codefor>fma_fnmadd_<mode><sd_maskz_name>_bcst_2):
7394 Likewise.
7395 (*<sd_mask_codefor>fma_fnmadd_<mode><sd_maskz_name>_bcst_3):
7396 Likewise.
7397 (fmai_vmfnmadd_<mode><round_name>): Likewise.
7398
7399 2018-10-21 H.J. Lu <hongjiu.lu@intel.com>
7400
7401 PR target/72782
7402 * config/i386/avx512fintrin.h (_mm512_fmsub_round_pd): Use
7403 __builtin_ia32_vfmsubpd512_mask.
7404 (_mm512_mask_fmsub_round_pd): Likewise.
7405 (_mm512_fmsub_pd): Likewise.
7406 (_mm512_mask_fmsub_pd): Likewise.
7407 (_mm512_maskz_fmsub_round_pd): Use
7408 __builtin_ia32_vfmsubpd512_maskz.
7409 (_mm512_maskz_fmsub_pd): Likewise.
7410 (_mm512_fmsub_round_ps): Use __builtin_ia32_vfmsubps512_mask.
7411 (_mm512_mask_fmsub_round_ps): Likewise.
7412 (_mm512_fmsub_ps): Likewise.
7413 (_mm512_mask_fmsub_ps): Likewise.
7414 (_mm512_maskz_fmsub_round_ps): Use
7415 __builtin_ia32_vfmsubps512_maskz.
7416 (_mm512_maskz_fmsub_ps): Likewise.
7417 * config/i386/avx512vlintrin.h (_mm256_mask_fmsub_pd): Use
7418 __builtin_ia32_vfmsubpd256_mask.
7419 (_mm256_maskz_fmsub_pd): Use __builtin_ia32_vfmsubpd256_maskz.
7420 (_mm_mask_fmsub_pd): Use __builtin_ia32_vfmaddpd128_mask
7421 (_mm_maskz_fmsub_pd): Use __builtin_ia32_vfmsubpd128_maskz.
7422 (_mm256_mask_fmsub_ps): Use __builtin_ia32_vfmsubps256_mask.
7423 (_mm256_mask_fmsub_ps): Use __builtin_ia32_vfmsubps256_mask.
7424 (_mm256_maskz_fmsub_ps): Use __builtin_ia32_vfmsubps256_maskz.
7425 (_mm_mask_fmsub_ps): Use __builtin_ia32_vfmsubps128_mask.
7426 (_mm_maskz_fmsub_ps): Use __builtin_ia32_vfmsubps128_maskz.
7427 * config/i386/fmaintrin.h (_mm_fmsub_pd): Use
7428 __builtin_ia32_vfmsubpd.
7429 (_mm256_fmsub_pd): Use __builtin_ia32_vfmsubpd256.
7430 (_mm_fmsub_ps): Use __builtin_ia32_vfmsubps.
7431 (_mm256_fmsub_ps): Use __builtin_ia32_vfmsubps256.
7432 (_mm_fmsub_sd): Use __builtin_ia32_vfmsubsd3.
7433 (_mm_fmsub_ss): Use __builtin_ia32_vfmsubss3.
7434 * config/i386/i386-builtin.def: Add
7435 __builtin_ia32_vfmsubpd256_mask,
7436 __builtin_ia32_vfmsubpd256_maskz,
7437 __builtin_ia32_vfmsubpd128_mask,
7438 __builtin_ia32_vfmsubpd128_maskz,
7439 __builtin_ia32_vfmsubps256_mask,
7440 __builtin_ia32_vfmsubps256_maskz,
7441 __builtin_ia32_vfmsubps128_mask,
7442 __builtin_ia32_vfmsubps128_maskz,
7443 __builtin_ia32_vfmsubpd512_mask,
7444 __builtin_ia32_vfmsubpd512_maskz,
7445 __builtin_ia32_vfmsubps512_mask,
7446 __builtin_ia32_vfmsubps512_maskz, __builtin_ia32_vfmsubss3,
7447 __builtin_ia32_vfmsubsd3, __builtin_ia32_vfmsubps,
7448 __builtin_ia32_vfmsubpd, __builtin_ia32_vfmsubps256 and.
7449 __builtin_ia32_vfmsubpd256.
7450 * config/i386/sse.md (fma4i_fmsub_<mode>): New.
7451 (<avx512>_fmsub_<mode>_maskz<round_expand_name>): Likewise.
7452 (*<sd_mask_codefor>fma_fmsub_<mode><sd_maskz_name>_bcst_1):
7453 Likewise.
7454 (*<sd_mask_codefor>fma_fmsub_<mode><sd_maskz_name>_bcst_2):
7455 Likewise.
7456 (*<sd_mask_codefor>fma_fmsub_<mode><sd_maskz_name>_bcst_3):
7457 Likewise.
7458 (fmai_vmfmsub_<mode><round_name>): Likewise.
7459
7460 2018-10-21 H.J. Lu <hongjiu.lu@intel.com>
7461
7462 * config/i386/sse.md (*<plusminus_insn><mode>3<mask_name>_bcst_1):
7463 Remove plus. Renamed to ...
7464 (*sub<mode>3<mask_name>_bcst): This.
7465 (*add<mode>3<mask_name>_bcst_2): Renamede to ...
7466 (*add<mode>3<mask_name>_bcst): This.
7467
7468 2018-10-21 H.J. Lu <hongjiu.lu@intel.com>
7469
7470 PR target/72782
7471 * config/i386/sse.md (*mul<mode>3<mask_name>_bcst): New.
7472
7473 2018-10-21 H.J. Lu <hongjiu.lu@intel.com>
7474
7475 PR target/87662
7476 * i386/avx512vlintrin.h (_mm256_or_epi32): New.
7477 (_mm_or_epi32): Likewise.
7478 (_mm256_xor_epi32): Likewise.
7479 (_mm_xor_epi32): Likewise.
7480 (_mm256_or_epi64): Likewise.
7481 (_mm_or_epi64): Likewise.
7482 (_mm256_xor_epi64): Likewise.
7483 (_mm_xor_epi64): Likewise.
7484
7485 2018-10-20 H.J. Lu <hongjiu.lu@intel.com>
7486
7487 PR target/72782
7488 * config/i386/sse.md (*<avx512>_div<mode>3<mask_name>_bcst): New.
7489
7490 2018-10-20 Jakub Jelinek <jakub@redhat.com>
7491
7492 PR middle-end/87647
7493 * varasm.c (decode_addr_const): Handle COMPOUND_LITERAL_EXPR.
7494
7495 2018-10-20 Andreas Schwab <schwab@linux-m68k.org>
7496
7497 * doc/ux.texi: Move @section directly after @node.
7498
7499 2018-10-19 Jakub Jelinek <jakub@redhat.com>
7500
7501 PR middle-end/85488
7502 PR middle-end/87649
7503 * omp-low.c (check_omp_nesting_restrictions): Diagnose ordered without
7504 depend closely nested inside of loop with ordered clause with
7505 a parameter.
7506
7507 2018-10-19 David Malcolm <dmalcolm@redhat.com>
7508
7509 * Makefile.in (TEXI_GCCINT_FILES): Add ux.texi.
7510 * doc/gccint.texi: Include ux.texi and use it in top-level menu.
7511 * doc/ux.texi: New file.
7512
7513 2018-10-19 Segher Boessenkool <segher@kernel.crashing.org>
7514
7515 * config/rs6000/rs6000.h (REG_ALLOC_ORDER): Move 68 (that is, CR0) to
7516 be the first CR field allocated.
7517
7518 2018-10-19 Richard Biener <rguenther@suse.de>
7519
7520 PR target/87657
7521 * config/i386/i386.c (ix86_builtin_vectorization_cost): Use
7522 TYPE_VECTOR_SUBPARTS and avoid relying on vector mode.
7523
7524 2018-10-19 H.J. Lu <hongjiu.lu@intel.com>
7525
7526 PR target/72782
7527 * config/i386/sse.md
7528 (*<plusminus_insn><mode>3<mask_name>_bcst_1): New.
7529 (*add<mode>3<mask_name>_bcst_2): Likewise.
7530
7531 2018-10-19 H.J. Lu <hongjiu.lu@intel.com>
7532
7533 * config/i386/sse.md
7534 (*<sd_mask_codefor>fma_fmadd_<mode><sd_maskz_name>_bcst_1):
7535 Replace nonimmediate_operand with register_operand.
7536 (*<sd_mask_codefor>fma_fmadd_<mode><sd_maskz_name>_bcst_2):
7537 Likewise.
7538 (*<sd_mask_codefor>fma_fmadd_<mode><sd_maskz_name>_bcst_3):
7539 Likewise.
7540
7541 2018-10-19 Ilya Leoshkevich <iii@linux.ibm.com>
7542
7543 PR rtl-optimization/87596
7544 * lra-constraints.c (spill_hard_reg_in_range): Use INSN_P () +
7545 lra_get_insn_recog_data () instead of lra_insn_recog_data[]
7546 for instructions in FROM..TO range.
7547
7548 2018-10-19 Eric Botcazou <ebotcazou@adacore.com>
7549
7550 * cfgexpand.c (expand_one_var): Use specific wording in error message
7551 for non-local frame variables.
7552 * stor-layout.c (layout_decl): Do not issue a warning for them.
7553
7554 2018-10-19 Robin Dapp <rdapp@linux.ibm.com>
7555
7556 * haifa-sched.c (priority): Add force_recompute parameter.
7557 (apply_replacement): Call priority () with force_recompute = true.
7558 (restore_pattern): Likewise.
7559
7560 2018-10-18 H.J. Lu <hongjiu.lu@intel.com>
7561
7562 * simplify-rtx.c (simplify_subreg): Limit mask of vec_merge to
7563 HOST_BITS_PER_WIDE_INT.
7564 (test_vector_ops_duplicate): Likewise.
7565
7566 2018-10-18 H.J. Lu <hongjiu.lu@intel.com>
7567
7568 PR target/72782
7569 * config/i386/sse.md (VF_AVX512): New.
7570 (avx512bcst): Likewise.
7571 (*<sd_mask_codefor>fma_fmadd_<mode><sd_maskz_name>_bcst_1):
7572 Likewise.
7573 (*<sd_mask_codefor>fma_fmadd_<mode><sd_maskz_name>_bcst_2):
7574 Likewise.
7575 (*<sd_mask_codefor>fma_fmadd_<mode><sd_maskz_name>_bcst_3):
7576 Likewise.
7577
7578 2018-10-18 Jonathan Wakely <jwakely@redhat.com>
7579
7580 * doc/invoke.texi (-dumpversion): Improve grammar.
7581 (-dumpfullversion): Make more consistent with -dumpversion.
7582
7583 2018-10-18 Uros Bizjak <ubizjak@gmail.com>
7584
7585 * config/i386/i386.c (ix86_emit_fp_unordered_jump):
7586 Set JUMP_LABEL to the jump insn.
7587 (ix86_emit_i387_log1p): Use ix86_expand_branch to expand branch.
7588 Predict emitted jump and add label to jump insn.
7589
7590 2018-10-18 David Malcolm <dmalcolm@redhat.com>
7591
7592 PR tree-optimization/87562
7593 * input.c (get_substring_ranges_for_loc): Use
7594 LRK_SPELLING_LOCATION rather than LRK_MACRO_EXPANSION_POINT when
7595 getting the linemap for the endpoint. Verify that it's either
7596 in the same linemap as the start point's spelling location, or
7597 at least in the same file.
7598
7599 2018-10-18 Richard Biener <rguenther@suse.de>
7600
7601 * config/i386/i386.c (ix86_builtin_vectorization_cost): Do not
7602 feed width-specific load/store costs through ix86_vec_cost.
7603 * config/i386/x86-tune-costs.h (athlon_cost): Adjust.
7604 (k8_cost): Likewise.
7605 (bdver_cost): Likewise.
7606 (znver1_cost): Likewise.
7607 (btver1_cost): Likewise.
7608 (btver2_cost): Likewise.
7609
7610 2018-10-18 H.J. Lu <hongjiu.lu@intel.com>
7611
7612 * simplify-rtx.c (simplify_subreg): Call simplify_gen_subreg
7613 to simplify subreg of vec_merge.
7614
7615 2018-10-18 Richard Biener <rguenther@suse.de>
7616
7617 * config/i386/i386.c: Fix costing of vector FMA.
7618
7619 2018-10-18 Richard Biener <rguenther@suse.de>
7620
7621 * config/i386/i386.c (ix86_vec_cost): Remove !parallel path
7622 and argument.
7623 (ix86_builtin_vectorization_cost): For vec_construct properly
7624 cost insertion into SSE regs.
7625 (...): Adjust calls to ix86_vec_cost.
7626
7627 2018-10-18 Richard Biener <rguenther@suse.de>
7628
7629 PR middle-end/87087
7630 Revert
7631 2018-02-07 Richard Biener <rguenther@suse.de>
7632
7633 PR tree-optimization/84204
7634 * tree-chrec.c (chrec_fold_plus_1): Remove size limiting in
7635 this place.
7636
7637 2018-10-18 H.J. Lu <hongjiu.lu@intel.com>
7638
7639 PR target/87537
7640 * simplify-rtx.c (simplify_subreg): Simplify subreg of vec_merge
7641 of vec_duplicate.
7642 (test_vector_ops_duplicate): Add test for a scalar subreg of a
7643 VEC_MERGE of a VEC_DUPLICATE.
7644
7645 2018-10-17 Joseph Myers <joseph@codesourcery.com>
7646
7647 * doc/cpp.texi (__STDC_VERSION__): Document C2X handling.
7648 * doc/invoke.texi (-std=c2x, -std=gnu2x): Document new options.
7649 * doc/standards.texi (C Language): Document C2X.
7650 * dwarf2out.c (highest_c_language), config/rl78/rl78.c
7651 (rl78_option_override): Handle "GNU C2X" language name.
7652
7653 2018-10-17 Joseph Myers <joseph@codesourcery.com>
7654
7655 * doc/invoke.texi (-std=c17), doc/standards.texi (C Language):
7656 Document C17 as published in 2018.
7657
7658 2018-10-17 Eric Botcazou <ebotcazou@adacore.com>
7659
7660 PR middle-end/87623
7661 * fold-const.c (fold_truth_andor_1): If the right side is not constant,
7662 bail out if both sides do not have the same storage order.
7663
7664 2018-10-17 Aldy Hernandez <aldyh@redhat.com>
7665
7666 * bitmap.c (bitmap_head::dump): New.
7667 * bitmap.h (bitmap_head): Add dump().
7668 * gimple-ssa-evrp-analyze.c
7669 (evrp_range_analyzer::try_find_new_range): Adjust for value_range API.
7670 (evrp_range_analyzer::set_ssa_range_info): Same.
7671 (evrp_range_analyzer::record_ranges_from_phis): Same.
7672 (evrp_range_analyzer::record_ranges_from_stmt): Same.
7673 * gimple-ssa-evrp.c (evrp_dom_walker::before_dom_children): Same.
7674 * gimple-ssa-sprintf.c (get_int_range): Same.
7675 (format_integer): Same.
7676 (sprintf_dom_walker::handle_gimple_call): Same.
7677 * ipa-cp.c (ipcp_vr_lattice::meet_with_1): Same.
7678 (ipcp_vr_lattice::top_p): Same.
7679 (ipcp_vr_lattice::bottom_p): Same.
7680 (ipcp_vr_lattice::set_to_bottom): Same.
7681 (ipa_vr_operation_and_type_effects): Same.
7682 (propagate_vr_across_jump_function): Same.
7683 (ipcp_store_vr_results): Same.
7684 * ipa-prop.c (struct ipa_vr_ggc_hash_traits): Same.
7685 (ipa_print_node_jump_functions_for_edge): Same.
7686 (ipa_get_value_range): Same.
7687 (ipa_compute_jump_functions_for_edge): Same.
7688 (ipa_write_jump_function): Same.
7689 * tree-ssa-dom.c (simplify_stmt_for_jump_threading): Same.
7690 * tree-ssa-threadedge.c (record_temporary_equivalences_from_phis):
7691 Same.
7692 * vr-values.c (set_value_range_to_nonnegative): Same.
7693 (set_value_range_to_truthvalue): Same.
7694 (vr_values::get_value_range): Same.
7695 (vr_values::set_defs_to_varying): Same.
7696 (vr_values::update_value_range): Same.
7697 (symbolic_range_based_on_p): Same.
7698 (vr_values::op_with_boolean_value_range_p): Same.
7699 (vr_values::extract_range_for_var_from_comparison_expr): Same.
7700 (vr_values::extract_range_from_ssa_name): Same.
7701 (vr_values::extract_range_from_binary_expr): Same.
7702 (vr_values::extract_range_from_unary_expr): Same.
7703 (vr_values::extract_range_from_cond_expr): Same.
7704 (vr_values::extract_range_from_comparison): Same.
7705 (vr_values::check_for_binary_op_overflow): Same.
7706 (vr_values::extract_range_basic): Same.
7707 (vr_values::extract_range_from_assignment): Same.
7708 (compare_ranges): Same.
7709 (compare_range_with_value): Same.
7710 (vr_values::adjust_range_with_scev): Same.
7711 (vrp_valueize): Same.
7712 (vrp_valueize_1): Same.
7713 (vr_values::get_vr_for_comparison): Same.
7714 (vr_values::compare_name_with_value): Same.
7715 (vr_values::compare_names): Same.
7716 (vr_values::vrp_evaluate_conditional): Same.
7717 (find_case_label_ranges): Same.
7718 (vr_values::vrp_visit_switch_stmt): Same.
7719 (vr_values::extract_range_from_phi_node): Same.
7720 (vr_values::simplify_div_or_mod_using_ranges): Same.
7721 (vr_values::simplify_bit_ops_using_ranges): Same.
7722 (test_for_singularity): Same.
7723 (range_fits_type_p): Same.
7724 (vr_values::simplify_cond_using_ranges_1): Same.
7725 (vr_values::simplify_switch_using_ranges): Same.
7726 (vr_values::simplify_float_conversion_using_ranges): Same.
7727 (vr_values::two_valued_val_range_p): Same.
7728 (vr_values::add_equivalence): Move to value_range::equiv_add.
7729 * vr-values.h (vr_values::add_equivalence): Remove.
7730 (VR_INITIALIZER): Remove.
7731 * tree-vrp.c (value_range::set): New.
7732 (value_range::equiv_add): New.
7733 (value_range::value_range): New.
7734 (value_range::deep_copy): New.
7735 (value_range::check): New.
7736 (value_range::equal_p): New.
7737 (value_range::ignore_equivs_equal_p): New.
7738 (value_range::operator==): New.
7739 (value_range::operator!=): New.
7740 (value_range::symbolic_p): New.
7741 (value_range::numeric_p): New.
7742 (value_range::set_undefined): New.
7743 (value_range::set_varying): New.
7744 (value_range::may_contain_p): New.
7745 (value_range::equiv_clear): New.
7746 (value_range::singleton_p): New.
7747 (value_range::intersect): New.
7748 (value_range::dump): New.
7749 (value_range::set_and_canonicalize): New.
7750 (set_value_range): Adjust for value_range API.
7751 (set_value_range_to_undefined): Same.
7752 (set_value_range_to_varying): Same.
7753 (set_and_canonicalize_value_range): Same.
7754 (set_value_range_to_nonnull): Same.
7755 (set_value_range_to_null): Same.
7756 (range_is_null): Same.
7757 (range_is_nonnull): Same.
7758 (range_int_cst_p): Same.
7759 (range_int_cst_singleton_p): Same.
7760 (symbolic_range_p): Same.
7761 (range_includes_zero_p): Same.
7762 (value_range_constant_singleton): Same.
7763 (vrp_set_zero_nonzero_bits): Same.
7764 (ranges_from_anti_range): Same.
7765 (extract_range_into_wide_ints): Same.
7766 (extract_range_from_multiplicative_op): Same.
7767 (set_value_range_with_overflow): Same.
7768 (extract_range_from_binary_expr_1): Same.
7769 (extract_range_from_unary_expr): Same.
7770 (dump_value_range): Same.
7771 (debug_value_range): Same.
7772 (vrp_prop::check_array_ref): Same.
7773 (vrp_prop::check_mem_ref): Same.
7774 (vrp_prop::vrp_initialize): Same.
7775 (vrp_prop::visit_stmt): Same.
7776 (intersect_ranges): Same.
7777 (vrp_prop::visit_phi): Same.
7778 (vrp_prop::vrp_finalize): Same.
7779 (determine_value_range_1): Same.
7780 (determine_value_range): Same.
7781 (vrp_intersect_ranges_1): Rename to...
7782 (vrp_intersect_1): this.
7783 (vrp_intersect_ranges): Rename to...
7784 (value_range::intersect_helper): ...this.
7785 (vrp_meet_1): Rename to...
7786 (value_range::union_helper): ...this.
7787 (vrp_meet): Rename to...
7788 (value_range::union_): ...this.
7789 (copy_value_range): Remove.
7790 * tree-vrp.h (struct value_range): Rewrite into a proper class.
7791 (value_range::vrtype): New.
7792 (value_range::type): New.
7793 (value_range::equiv): New.
7794 (value_range::min): New.
7795 (value_range::max): New.
7796 (value_range::varying_p): New.
7797 (value_range::undefined_p): New.
7798 (value_range::null_p): New.
7799 (value_range::equiv_add): New.
7800 (copy_value_range): Remove.
7801
7802 2018-10-17 David Malcolm <dmalcolm@redhat.com>
7803
7804 * Makefile.in (SELFTEST_TARGETS): New.
7805 (selftest) Change from s-selftest-c to $(SELFTEST_TARGETS).
7806 (C_SELFTEST_FLAGS, C_SELFTEST_DEPS, s-selftest-c, selftest-c-gdb)
7807 (selftest-gdb, selftest-c-valgrind, selftest-valgrind): Move to
7808 c/Make-lang.in.
7809 (CPP_SELFTEST_FLAGS, CPP_SELFTEST_DEPS, s-selftest-c++)
7810 (selftest-c++-gdb, selftest-c++-valgrind): Move to
7811 cp/Make-lang.in.
7812 * configure: Regenerate.
7813 * configure.ac (selftest_languages): New.
7814
7815 2018-10-17 Aldy Hernandez <aldyh@redhat.com>
7816
7817 * tree-vrp.c (extract_range_from_multiplicative_op): Remove
7818 overflow wraps argument.
7819 (extract_range_from_binary_expr_1): Do not pass overflow wraps to
7820 wide_int_range_multiplicative_op.
7821 * wide-int-range.cc (wide_int_range_mult_wrapping): Remove
7822 overflow wraps argument.
7823 (wide_int_range_multiplicative_op): Same.
7824 (wide_int_range_lshift): Same.
7825 (wide_int_range_div): Same.
7826 * wide-int-range.h (wide_int_range_multiplicative_op): Same.
7827 (wide_int_range_lshift): Same.
7828 (wide_int_range_div): Same.
7829
7830 2018-10-17 Aldy Hernandez <aldyh@redhat.com>
7831
7832 * wide-int-range.h (wide_int_range_shift_undefined_p): Adjust to
7833 use sign as argument.
7834 * tree-vrp.c (extract_range_from_binary_expr_1): Pass sign to
7835 wide_int_range_shift_undefined_p.
7836
7837 2018-10-16 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
7838
7839 * config/aarch64/aarch64.md (despeculate_copy<ALLI_TI:mode>):
7840 Rename to...
7841 (@despeculate_copy<ALLI_TI:mode>): ... This.
7842 * config/aarch64/aarch64.c (aarch64_speculation_safe_value): Remove
7843 switch statement.
7844
7845 2018-10-16 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
7846
7847 * config.gcc: Obsolete *-*-solaris2.10*.
7848 * doc/install.texi (Specific, *-*-solaris2*): Document it.
7849
7850 2018-10-12 Jeff Law <law@redhat.com>
7851
7852 * config/ft32/ft32.md (ft32_general_movsrc_operand): Disable
7853 reg + sym +- const_int addressing modes.
7854
7855 2018-10-15 David Malcolm <dmalcolm@redhat.com>
7856
7857 * common.opt (fdiagnostics-minimum-margin-width=): New option.
7858 * diagnostic-show-locus.c (layout::layout): Apply the minimum
7859 margin width.
7860 (layout::start_annotation_line): Only print up to 3 of the
7861 margin character, to avoid touching the left-hand side.
7862 (selftest::test_diagnostic_show_locus_fixit_lines): Update for
7863 minimum margin width, as set by test_diagnostic_context's ctor.
7864 (selftest::test_fixit_insert_containing_newline): Likewise.
7865 (selftest::test_fixit_insert_containing_newline_2): Likewise.
7866 (selftest::test_line_numbers_multiline_range): Clear
7867 dc.min_margin_width.
7868 * diagnostic.c (diagnostic_initialize): Initialize
7869 min_margin_width.
7870 * diagnostic.h (struct diagnostic_context): Add field
7871 "min_margin_width".
7872 * doc/invoke.texi: Add -fdiagnostics-minimum-margin-width=.
7873 * opts.c (common_handle_option): Handle
7874 OPT_fdiagnostics_minimum_margin_width_.
7875 * selftest-diagnostic.c
7876 (selftest::test_diagnostic_context::test_diagnostic_context):
7877 Initialize min_margin_width to 6.
7878 * toplev.c (general_init): Initialize global_dc->min_margin_width.
7879
7880 2018-10-15 David Malcolm <dmalcolm@redhat.com>
7881
7882 * gcc-rich-location.h (gcc_rich_location::add_location_if_nearby):
7883 Fix usage of "error_at_rich_loc" in the comment.
7884
7885 2018-10-15 Renlin Li <renlin.li@arm.com>
7886
7887 PR target/87563
7888 * tree-vectorizer.c (try_vectorize_loop_1): Don't use
7889 if-conversioned loop when it contains ifn with types not
7890 supported by backend.
7891 * internal-fn.c (expand_direct_optab_fn): Add an assert.
7892 (direct_internal_fn_supported_p): New helper function.
7893 * internal-fn.h (direct_internal_fn_supported_p): Declare.
7894
7895 2018-10-15 Jakub Jelinek <jakub@redhat.com>
7896
7897 PR target/87572
7898 * common/config/i386/i386-common.c (OPTION_MASK_ISA_AVX512F_UNSET):
7899 Remove OPTION_MASK_ISA_AVX5124FMAPS_UNSET and
7900 OPTION_MASK_ISA_AVX5124VNNIW_UNSET.
7901
7902 2018-10-15 Bin Cheng <bin.cheng@linux.alibaba.com>
7903
7904 PR tree-optimization/87022
7905 * tree-loop-distribution.c (pg_add_dependence_edges): Check all
7906 bits in dist vector rather than the first one.
7907
7908 2018-10-15 Richard Biener <rguenther@suse.de>
7909
7910 PR middle-end/87610
7911 * tree-ssa-structalias.c (struct vls_data): Add escaped_p member.
7912 (visit_loadstore): When a used restrict tag escaped verify that
7913 the points-to solution of "other" pointers do not include
7914 escaped.
7915 (compute_dependence_clique): If a used restrict tag escaped
7916 communicated that down to visit_loadstore.
7917
7918 2018-10-15 Andreas Krebbel <krebbel@linux.ibm.com>
7919
7920 * config/s390/s390.c (s390_expand_vec_init): Force vector element
7921 into reg if it isn't a general operand.
7922
7923 2018-10-14 H.J. Lu <hongjiu.lu@intel.com>
7924
7925 PR target/87599
7926 * config/i386/sse.md (*vec_dupv2di): Add register source to
7927 movddup.
7928
7929 2018-10-14 H.J. Lu <hongjiu.lu@intel.com>
7930
7931 PR target/87572
7932 * common/config/i386/i386-common.c (OPTION_MASK_ISA_AVX512F_UNSET):
7933 Add OPTION_MASK_ISA_AVX512IFMA_UNSET,
7934 OPTION_MASK_ISA_AVX5124FMAPS_UNSET and
7935 OPTION_MASK_ISA_AVX5124VNNIW_UNSET.
7936
7937 2018-10-13 Eric Botcazou <ebotcazou@adacore.com>
7938
7939 * dwarf2cfi.c (struct dw_trace_info): Add args_size_defined_for_eh.
7940 (notice_args_size): Set it in the current trace if no insn that can
7941 throw internally has been seen yet.
7942 (connect_traces): When connecting args_size between traces, allow the
7943 incoming values not to match if there is an insn setting it before the
7944 first insn that can throw internally; in that case, force the creation
7945 of a CFI note on this latter insn.
7946
7947 2018-10-13 Jonathan Wakely <jwakely@redhat.com>
7948
7949 * opt-problem.h (opt_wrapper): Use template-argument-list when naming
7950 the base class, because using the injected-class-name was not clearly
7951 specified until DR 176.
7952
7953 2018-10-12 Paul Koning <ni1d@arrl.net>
7954
7955 * config/pdp11/pdp11.md (doloop_end): New expander.
7956 (doloop_end_insn): renamed from "doloop_end".
7957 (addqi3): New pattern.
7958 (subqi3): New pattern.
7959 * config/pdp11/predicates.md (incdec_operand): New predicate.
7960
7961 2018-10-12 Yury Gribov <tetra2005@gmail.com>
7962
7963 PR middle-end/81376
7964 * real.c (format_helper::can_represent_integral_type_p): New function
7965 * real.h (format_helper::can_represent_integral_type_p): Ditto.
7966 * match.pd: New pattern.
7967
7968 2018-10-12 Alexandre Oliva <oliva@adacore.com>
7969
7970 * configure.ac: Introduce --enable-large-address-aware
7971 to define MINGW_DEFAULT_LARGE_ADDR_AWARE.
7972 * doc/install.texi: Document it.
7973 * configure, config.in: Rebuilt.
7974 * config/i386/mingw32.h (LINK_SPEC_LARGE_ADDR_AWARE): Define,
7975 based on MINGW_DEFAULT_LARGE_ADDR_AWARE.
7976 (LINK_SPEC): Insert it.
7977 * config/i386/mingw-w64.h: Likewise.
7978
7979 * cygming.h (HAVE_GAS_ALIGNED_COMM): Fallback-define.
7980
7981 2018-10-12 Peter Bergner <bergner@linux.ibm.com>
7982
7983 PR rtl-optimization/87600
7984 * ira-lives (non_conflicting_reg_copy_p): Disable for non LRA targets.
7985
7986 2018-10-12 Paul Koning <ni1d@arrl.net>
7987
7988 * doc/md.texi (doloop_end): Document that the pattern code may
7989 need to check operand mode.
7990
7991 2018-10-12 Wilco Dijkstra <wdijkstr@arm.com>
7992
7993 * config/aarch64/aarch64.md (zero_extendsidi2_aarch64): Add alternatives
7994 to zero-extend between int and floating-point registers.
7995 (load_pair_zero_extendsidi2_aarch64): Add alternative for zero-extended
7996 ldp into floating-point registers. Add type and arch attributes.
7997 (zero_extend<SHORT:mode><GPI:mode>2_aarch64): Add arch attribute.
7998 Use f_loads for type attribute.
7999
8000 2018-10-11 Martin Sebor <msebor@redhat.com>
8001
8002 * doc/extend.texi (attribute packed): Correct typos.
8003
8004 2018-10-11 Martin Sebor <msebor@redhat.com>
8005
8006 * doc/extend.texi (attribute flatten): Mention interaction with
8007 noinline.
8008
8009 2018-10-11 Jan Hubicka <hubicka@ucw.cz>
8010
8011 PR target/87156
8012 * cgraphclones.c (cgraph_node::create_version_clone_with_body):
8013 Set new_decl virtual flag to zero.
8014
8015 2018-10-11 Martin Sebor <msebor@redhat.com>
8016
8017 PR middle-end/87593
8018 * doc/extend.texi (attribute format_arg): Discuss using multiple
8019 attributes on a single function.
8020
8021 2018-10-11 Giuliano Belinassi <giuliano.belinassi@usp.br>
8022
8023 PR tree-optimization/86829
8024 * match.pd (sin (atan (x))): New simplification rules.
8025 (cos (atan (x))): Likewise.
8026 * real.c (build_sinatan_real): New function.
8027 * real.h (build_sinatan_real): Prototype.
8028
8029 2018-10-11 Will Schmidt <will_schmidt@vnet.ibm.com>
8030
8031 * config/rs6000/rs6000.c (map_to_integral_tree_type): New helper
8032 function.
8033 (fold_mergeeo_helper): New helper function.
8034 (rs6000_gimple_fold_builtin): Add hooks for vec_mergee and vec_mergeo
8035 intrinsics. Correct some whitespace indentation issues.
8036
8037 2018-10-11 Wilco Dijkstra <wdijkstr@arm.com>
8038
8039 PR target/87511
8040 * config/aarch64/aarch64.c (aarch64_mask_and_shift_for_ubfiz_p):
8041 Use HOST_WIDE_INT_1U for shift.
8042
8043 2018-10-11 Doug Rupp <rupp@adacore.com>
8044 Olivier Hainque <hainque@adacore.com>
8045
8046 * config/rs6000/vxworks.h (VXWORKS_RELAX_LINK_SPEC): New macro.
8047 Pass --relax to the linker for RTPs.
8048 (LINK_SPEC): Append VXWORKS_RELAX_LINK_SPEC.
8049
8050 2018-10-11 Andrew Stubbs <ams@codesourcery.com>
8051 Jan Hubicka <jh@suse.cz>
8052 Martin Jambor <mjambor@suse.cz>
8053
8054 * print-rtl.c (print_rtx_operand_codes_E_and_V): Print how many times
8055 the same elements are repeated rather than printing all of them.
8056 * read-rtl.c (rtx_reader::read_rtx_operand): Recognize and expand
8057 "repeated" elements.
8058 * read-rtl-function.c (test_loading_repeat): New function.
8059 (read_rtl_function_c_tests): Call test_loading_repeat.
8060 * rtl-tests.c (test_dumping_repeat): New function.
8061 (rtl_tests_c_tests): Call test_dumping_repeat.
8062
8063 2018-10-11 Richard Biener <rguenther@suse.de>
8064
8065 * config/i386/x86-tune-costs.h (bdver?_memcpy, bdver?_memset,
8066 bdver?_cost): Unify to ...
8067 (bdver_memcpy, bdver_memset, bdver_cost): ... this.
8068 * config/i386/i386.c (processor_cost_table): Adjust.
8069
8070 2018-10-10 Eric Botcazou <ebotcazou@adacore.com>
8071
8072 PR middle-end/87574
8073 * cgraphunit.c (cgraph_node::expand_thunk): Force DECL_IGNORED_P on
8074 the thunk when expanding to GIMPLE.
8075
8076 2018-10-10 Bernd Edlinger <bernd.edlinger@hotmail.de>
8077
8078 PR bootstrap/87551
8079 * varasm.c (mergeable_string_section): Don't try to move zero-length
8080 strings to the merge section.
8081
8082 2018-10-10 Uros Bizjak <ubizjak@gmail.com>
8083
8084 PR target/87573
8085 * config/i386/mmx.md (const_vector 0 -> mem splitter): New splitter.
8086
8087 2018-10-10 Jakub Jelinek <jakub@redhat.com>
8088
8089 PR target/87550
8090 * config/i386/i386-builtin.def (IX86_BUILTIN_RDPMC): Move from args set
8091 to special_args set.
8092
8093 2018-10-10 Richard Biener <rguenther@suse.de>
8094
8095 * config/i386/sse.md (reduc_plus_scal_v8df, reduc_plus_scal_v4df,
8096 reduc_plus_scal_v2df, reduc_plus_scal_v16sf, reduc_plus_scal_v8sf,
8097 reduc_plus_scal_v4sf): Merge into pattern reducing to half width
8098 and recursing and pattern terminating the recursion on SSE
8099 vector width using ix86_expand_reduc.
8100 (reduc_sminmax_scal_<mode>): Split into part reducing to half
8101 width and recursing and SSE2 vector variant doing the final
8102 reduction with ix86_expand_reduc.
8103 (reduc_uminmax_scal_<mode>): Likewise for the AVX512 variants
8104 with terminating the recursion at AVX level, splitting that
8105 to SSE there.
8106
8107 2018-10-09 David Malcolm <dmalcolm@redhat.com>
8108
8109 * genmatch.c (error_cb): Rename to...
8110 (diagnostic_cb): ...this, converting int params to enums.
8111 (fatal_at): Update for renaming.
8112 (warning_at): Likewise.
8113 (main): Likewise.
8114 * input.c (selftest::ebcdic_execution_charset::apply):
8115 Update for renaming of...
8116 (selftest::ebcdic_execution_charset::on_error): ...this, renaming
8117 to...
8118 (selftest::ebcdic_execution_charset::on_diagnostic): ...this,
8119 converting level and reason to enums.
8120 (class selftest::lexer_error_sink): Rename to...
8121 (class selftest::lexer_test_options): ...this, renaming field
8122 "m_errors" to "m_diagnostics".
8123 (selftest::lexer_test_options::apply): Update for renaming of...
8124 (selftest::lexer_test_options::on_error): ...this, renaming to...
8125 (selftest::lexer_test_options::on_diagnostic): ...this
8126 converting level and reason to enums.
8127 (selftest::test_lexer_string_locations_raw_string_unterminated):
8128 Update for renamings.
8129 * opth-gen.awk (struct cpp_reason_option_codes_t): Use enum for
8130 "reason".
8131
8132 2018-10-09 Paul A. Clarke <pc@us.ibm.com>
8133
8134 * config.gcc (powerpc*-*-*): Add pmmintrin.h to extra_headers.
8135 * config/rs6000/pmmintrin.h: New file.
8136
8137 2018-10-09 Eric Botcazou <ebotcazou@adacore.com>
8138
8139 PR tree-optimization/86659
8140 * gimple-match.h (gimple_match_op constructors): Initialize reverse.
8141
8142 2018-10-09 Richard Biener <rguenther@suse.de>
8143
8144 PR tree-optimization/63155
8145 * tree-ssa-structalias.c: Include tree-ssa.h.
8146 (get_constraint_for_ssa_var): For undefs return nothing_id.
8147 (find_func_aliases): Cleanup PHI handling.
8148
8149 2018-10-09 Richard Biener <rguenther@suse.de>
8150
8151 * tree-vectorizer.c (dump_stmt_cost): Fix cut&paste missing
8152 replacements.
8153
8154 2018-10-09 Martin Liska <mliska@suse.cz>
8155
8156 * asan.c (asan_emit_stack_protection): If a stack variable
8157 is located in a same file as current function, then emit
8158 line info into variable definition string.
8159
8160 2018-10-08 Eric Botcazou <ebotcazou@adacore.com>
8161
8162 * print-rtl.c (rtx_writer::print_rtx_operand_code_i): Print column
8163 information.
8164
8165 2018-10-08 Eric Botcazou <ebotcazou@adacore.com>
8166
8167 * cgraphunit.c (cgraph_node::expand_thunk): Do not force DECL_IGNORED_P
8168 on the thunk.
8169
8170 2018-10-08 Eric Botcazou <ebotcazou@adacore.com>
8171
8172 PR tree-optimization/86659
8173 * gimple-match.h (struct gimple_match_op): Add reverse field.
8174 (gimple_match_op::set_op): New overloaded method.
8175 * gimple-match-head.c (maybe_build_generic_op) <BIT_FIELD_REF>: Set
8176 the REF_REVERSE_STORAGE_ORDER flag on the value.
8177 (gimple_simplify) <GIMPLE_ASSIGN>: For BIT_FIELD_REF, propagate the
8178 REF_REVERSE_STORAGE_ORDER flag and avoid simplifying if it is set.
8179
8180 2018-10-08 Richard Sandiford <richard.sandiford@arm.com>
8181
8182 PR middle-end/63155
8183 * gimple-ssa-backprop.c (backprop::intersect_uses): Use
8184 FOR_EACH_IMM_USE_FAST instead of FOR_EACH_IMM_USE_STMT.
8185
8186 2018-10-08 H.J. Lu <hongjiu.lu@intel.com>
8187
8188 PR target/87517
8189 * config/i386/avx512fintrin.h (_mm512_mask_fmaddsub_round_pd):
8190 Defined with __builtin_ia32_vfmaddsubpd512_mask.
8191
8192 2018-10-08 Richard Biener <rguenther@suse.de>
8193
8194 * config/i386/x86-tune-costs.h (znver1_cost): Make AVX256 vector loads
8195 cost the same as AVX128 ones.
8196
8197 2018-10-08 Paul Koning <ni1d@arrl.net>
8198
8199 * config/pdp11/pdp11-protos.h (output_block_move): Remove.
8200 (expand_block_move): New function.
8201 * config/pdp11/pdp11.c (output_block_move): Remove.
8202 (expand_block_move): New function.
8203 * config/pdp11/pdp11.h (MOVE_RATIO): New definition.
8204 * config/pdp11/pdp11.md (movmemhi): Use expand_block_move.
8205 (*movmemhi1): Remove.
8206
8207 2018-10-08 Robin Dapp <rdapp@linux.ibm.com>
8208
8209 * config/s390/2827.md: Increase latencies for some FP instructions.
8210
8211 2018-10-08 Richard Biener <rguenther@suse.de>
8212
8213 * tree-vect-loop.c (vect_compute_single_scalar_iteration_cost):
8214 Open a dump scope.
8215 * tree-vectorizer.c (dump_stmt_cost): Add cost param and dump it.
8216 * tree-vectorizer.h (dump_stmt_cost): Adjust.
8217 (add_stmt_cost): Dump return value of the hook.
8218
8219 2018-10-08 Richard Biener <rguenther@suse.de>
8220
8221 PR tree-optimization/63155
8222 * tree-ssa-propagate.c (add_ssa_edge): Do cheap check first.
8223 (ssa_propagation_engine::ssa_propagate): Remove redundant
8224 bitmap bit clearing.
8225
8226 2018-10-05 Peter Bergner <bergner@linux.ibm.com>
8227
8228 PR rtl-optimization/86939
8229 PR rtl-optimization/87479
8230 * ira.h (non_conflicting_reg_copy_p): New prototype.
8231 * ira-lives.c (ignore_reg_for_conflicts): New static variable.
8232 (make_hard_regno_dead): Don't add conflicts for register
8233 ignore_reg_for_conflicts.
8234 (make_object_dead): Likewise.
8235 (non_conflicting_reg_copy_p): New function.
8236 (process_bb_node_lives): Set ignore_reg_for_conflicts for copies.
8237 Remove special conflict handling of REAL_PIC_OFFSET_TABLE_REGNUM.
8238 * lra-lives.c (ignore_reg_for_conflicts): New static variable.
8239 (make_hard_regno_dead): Don't add conflicts for register
8240 ignore_reg_for_conflicts. Remove special conflict handling of
8241 REAL_PIC_OFFSET_TABLE_REGNUM. Remove now unused argument
8242 check_pic_pseudo_p and update callers.
8243 (mark_pseudo_dead): Don't add conflicts for register
8244 ignore_reg_for_conflicts.
8245 (process_bb_lives): Set ignore_reg_for_conflicts for copies.
8246
8247 2018-10-05 Andrew Waterman <andrew@sifive.com>
8248 Jim Wilson <jimw@sifive.com>
8249
8250 * config/riscv/riscv.md (f<quiet_pattern>_quiet<ANYF:mode><X:mode>4):
8251 Add define_expand. Add ! HONOR_SNANS check to current pattern. Add
8252 new pattern using HONOR_SNANS that emits one extra instruction.
8253
8254 2018-10-05 Segher Boessenkool <segher@kernel.crashing.org>
8255
8256 * config/rs6000/rs6000.md (unnamed mfcr scc_comparison_operator
8257 patterns): Merge SI and DI patterns to a GPR pattern.
8258 (unnamed define_insn and define_split for record form of that): Merge
8259 to a single define_insn_and_split pattern.
8260
8261 2018-10-05 David Malcolm <dmalcolm@redhat.com>
8262
8263 PR c++/56856
8264 * input.c (expand_location_to_spelling_point): Add param "aspect"
8265 and use rather than hardcoding LOCATION_ASPECT_CARET.
8266 (get_substring_ranges_for_loc): Handle the case of a single token
8267 within a macro expansion.
8268 * input.h (expand_location_to_spelling_point): Add "aspect" param,
8269 defaulting to LOCATION_ASPECT_CARET.
8270
8271 2018-10-05 Paul Koning <ni1d@arrl.net>
8272
8273 * config/pdp11/pdp11.c (TARGET_CXX_GUARD_TYPE): Define.
8274 (TARGET_CXX_CLASS_DATA_ALWAYS_COMDAT): Define.
8275 (TARGET_CXX_LIBRARY_RTTI_COMDAT): Define.
8276 (pdp11_guard_type): New function.
8277
8278 2018-10-05 Paul Koning <ni1d@arrl.net>
8279
8280 * config/pdp11/pdp11.h (FLOAT_TYPE_SIZE): Always 32.
8281 * config/pdp11/pdp11.opt (mfloat32): Remove.
8282 (mfloat64): Remove.
8283 * doc/invoke.texi (pdp11 -mfloat32): Remove:
8284 (pdp11 -mfloat64): Remove.
8285
8286 2018-10-05 Uros Bizjak <ubizjak@gmail.com>
8287
8288 * config/i386/i386.md (*cmpxf_cc_i387): Remove pattern.
8289 (*cmp<mode>_cc_i387): Ditto.
8290 (*cmpu<mode>_cc_i387): Ditto.
8291 (*cmp<X87MODEF:mode>_<SWI24:mode>_cc_i387): Ditto.
8292 * config/i386/i386.c (ix86_expand_fp_compare): Remove
8293 "scratch" argument.
8294 <case IX86_FPCMP_SAHF>: Do not generate pattern with HImode clobber.
8295 Emit x86_sahf_1 pattern.
8296 (ix86_expand_compare): Update call to ix86_expand_fp_compare.
8297 (ix86_expand_carry_flag_compare): Ditto.
8298
8299 2018-10-05 Uros Bizjak <ubizjak@gmail.com>
8300
8301 * config/i386/i386.md (*cmpxf_i387): Change operand 2 predicate
8302 to reg_or_0_operand. Add "C" constraint.
8303 (*cmpxf_cc_i387): Ditto.
8304 (*cmp<mode>_i387): Change operand 2 predicate
8305 to nonimm_or_0_operand. Add "C" constraint.
8306 (*cmp<mode>_cc_i387): Ditto.
8307 (*cmp<mode>_0_i387): Remove insn pattern.
8308 (*cmp<mode>_0_cc_i387): Ditto.
8309
8310 2018-10-05 Uros Bizjak <ubizjak@gmail.com>
8311
8312 * config/i386/constraints.md ("C"): Do not depend on TARGET_SSE.
8313 * config/i386/predicates.md (nonimm_or_0_operand): Rename
8314 from vector_move_operand. Update all uses.
8315
8316 2018-10-05 Martin Sebor <msebor@redhat.com>
8317
8318 PR tree-optimization/87490
8319 * builtins.c (expand_builtin_strnlen): Handle a null data.decl
8320 consistently.
8321
8322 2018-10-05 Richard Biener <rguenther@suse.de>
8323
8324 PR tree-optimization/63155
8325 * tree-ssa-ccp.c (ccp_propagate::visit_phi): Avoid excess
8326 vertical space in dumpfiles.
8327 * tree-ssa-propagate.h
8328 (ssa_propagation_engine::process_ssa_edge_worklist): Remove.
8329 * tree-ssa-propagate.c (cfg_blocks_back): New global.
8330 (ssa_edge_worklist_back): Likewise.
8331 (curr_order): Likewise.
8332 (cfg_blocks_get): Remove abstraction.
8333 (cfg_blocks_add): Likewise.
8334 (cfg_blocks_empty_p): Likewise.
8335 (add_ssa_edge): Add to current or next worklist based on
8336 RPO index.
8337 (add_control_edge): Likewise.
8338 (ssa_propagation_engine::process_ssa_edge_worklist): Fold
8339 into ...
8340 (ssa_propagation_engine::ssa_propagate): ... here. Unify
8341 iteration from CFG and SSA edge worklist so we process
8342 everything in RPO order, prioritizing forward progress
8343 over iteration.
8344 (ssa_prop_init): Allocate new worklists, do not dump
8345 immediate uses.
8346 (ssa_prop_fini): Free new worklists.
8347
8348 2018-10-05 Richard Biener <rguenther@suse.de>
8349
8350 * tree-core.h (tree_block::abstract_flag): Remove.
8351 (tree_block::block_num): Make full 32bits.
8352 * tree.def (BLOCK): Remove docs about BLOCK_ABSTRACT.
8353 * tree.h (BLOCK_ABSTRACT): Remove.
8354 * dwarf2out.c (gen_lexical_block_die): Remove dead code
8355 resulting from BLOCK_ABSTRACT being always false.
8356 (gen_inlined_subroutine_die): Likewise.
8357 (gen_block_die): Likewise.
8358 * tree.c (block_ultimate_origin): Likewise.
8359 * tree-pretty-print.c (dump_block_node): Remove code dealing
8360 with BLOCK_ABSTRACT.
8361 * tree-ssa-live.c (dump_scope_block): Likewise.
8362 * tree-streamer-in.c (unpack_ts_block_value_fields): Likewise.
8363 * tree-streamer-out.c (pack_ts_block_value_fields): Likewise.
8364
8365 2018-10-05 Richard Biener <rguenther@suse.de>
8366
8367 * config/i386/i386.c (ix86_add_stmt_cost): When scalar cost
8368 is asked for initialize mode to the component mode of the
8369 vector type.
8370
8371 2018-10-05 H.J. Lu <hongjiu.lu@intel.com>
8372
8373 PR target/87522
8374 * config/i386/gnu-user.h (ASM_SPEC): Don't pass -msse2avx to
8375 assembler for -mavx.
8376 * config/i386/gnu-user64.h (ASM_SPEC): Likewise.
8377
8378 2018-10-05 Segher Boessenkool <segher@kernel.crashing.org>
8379
8380 PR target/87509
8381 * config/rs6000/rs6000-builtin.def (RS6000_BUILTIN_SET_FPSCR_DRN): Use
8382 RS6000_BTM_DFP.
8383 * config/rs6000/rs6000.md (rs6000_set_fpscr_rn): Require the operand
8384 to be DImode. When using mffscrn, force the operand to a register.
8385
8386 2018-10-04 Uros Bizjak <ubizjak@gmail.com>
8387
8388 * config/i386/i386.md (*fop_<X87MODEF:mode>_2_i387): Macroize insn
8389 from *fop_<MODEF:mode>_2_i387 and *fop_xf_2_i387 using
8390 X87MODEF mode iterator.
8391 (*fop_<X87MODEF:mode>_3_i387): Macroize insn from
8392 *fop_<MODEF:mode>_3_i387 and *fop_xf_3_i387 using
8393 X87MODEF mode iterator.
8394
8395 2018-10-04 Vinay Kumar <vinay.kumar@blackfigtech.com>
8396
8397 * doc/invoke.texi (-Wno-prio-ctor-dtor): Document new warning
8398 -Wno-prio-ctor-dtor.
8399
8400 2018-10-04 David Malcolm <dmalcolm@redhat.com>
8401
8402 * Makefile.in (OBJS): Add opt-problem.o.
8403 * dump-context.h: Include "selftest.h.
8404 (selftest::temp_dump_context): New forward decl.
8405 (class dump_context): Make friend of class
8406 selftest::temp_dump_context.
8407 (dump_context::dump_loc_immediate): New decl.
8408 (class dump_pretty_printer): Move here from dumpfile.c.
8409 (class temp_dump_context): Move to namespace selftest.
8410 (temp_dump_context::temp_dump_context): Add param
8411 "forcibly_enable_dumping".
8412 (selftest::verify_dumped_text):
8413 (ASSERT_DUMPED_TEXT_EQ): Move here from dumpfile.c.
8414 (selftest::verify_item):
8415 (ASSERT_IS_TEXT): Move here from dumpfile.c.
8416 (ASSERT_IS_TREE): Likewise.
8417 (ASSERT_IS_GIMPLE): Likewise.
8418 * dumpfile.c (dump_context::dump_loc): Move immediate dumping
8419 to...
8420 (dump_context::dump_loc_immediate): ...this new function.
8421 (class dump_pretty_printer): Move to dump-context.h.
8422 (dump_switch_p_1): Don't enable MSG_PRIORITY_REEMITTED.
8423 (opt_info_switch_p_1): Enable MSG_PRIORITY_REEMITTED.
8424 (temp_dump_context::temp_dump_context): Move to "selftest"
8425 namespace. Add param "forcibly_enable_dumping", and use it to
8426 conditionalize the use of m_pp;
8427 (selftest::verify_dumped_text): Make non-static.
8428 (ASSERT_DUMPED_TEXT_EQ): Move to dump-context.h.
8429 (selftest::verify_item): Make non-static.
8430 (ASSERT_IS_TEXT): Move to dump-context.h.
8431 (ASSERT_IS_TREE): Likewise.
8432 (ASSERT_IS_GIMPLE): Likewise.
8433 (selftest::test_capture_of_dump_calls): Pass "true" for new
8434 param of temp_dump_context.
8435 * dumpfile.h (enum dump_flag): Add MSG_PRIORITY_REEMITTED, adding
8436 it to MSG_ALL_PRIORITIES. Update values of TDF_COMPARE_DEBUG and
8437 TDF_COMPARE_DEBUG.
8438 * opt-problem.cc: New file.
8439 * opt-problem.h: New file.
8440 * optinfo-emit-json.cc
8441 (selftest::test_building_json_from_dump_calls): Pass "true" for
8442 new param of temp_dump_context.
8443 * optinfo.cc (optinfo_kind_to_dump_flag): New function.
8444 (optinfo::emit_for_opt_problem): New function.
8445 (optinfo::emit): Clarity which emit_item is used.
8446 * optinfo.h (optinfo::get_dump_location): New accessor.
8447 (optinfo::emit_for_opt_problem): New decl.
8448 (optinfo::emit): Make const.
8449 * selftest-run-tests.c (selftest::run_tests): Call
8450 selftest::opt_problem_cc_tests.
8451 * selftest.h (selftest::opt_problem_cc_tests): New decl.
8452 * tree-data-ref.c (dr_analyze_innermost): Convert return type from
8453 bool to opt_result, converting fprintf messages to
8454 opt_result::failure_at calls. Add "stmt" param for use by the
8455 failure_at calls.
8456 (create_data_ref): Pass "stmt" to the dr_analyze_innermost call.
8457 (runtime_alias_check_p): Convert return type from bool to
8458 opt_result, converting dump_printf calls to
8459 opt_result::failure_at, using the statement DDR_A for their
8460 location.
8461 (find_data_references_in_stmt): Convert return type from bool to
8462 opt_result, converting "return false" to opt_result::failure_at
8463 with a new message.
8464 * tree-data-ref.h: Include "opt-problem.h".
8465 (dr_analyze_innermost): Convert return type from bool to opt_result,
8466 and add a const gimple * param.
8467 (find_data_references_in_stmt): Convert return type from bool to
8468 opt_result.
8469 (runtime_alias_check_p): Likewise.
8470 * tree-predcom.c (find_looparound_phi): Pass "init_stmt" to
8471 dr_analyze_innermost.
8472 * tree-vect-data-refs.c (vect_mark_for_runtime_alias_test):
8473 Convert return type from bool to opt_result, adding a message for
8474 the PARAM_VECT_MAX_VERSION_FOR_ALIAS_CHECKS zero case.
8475 (vect_analyze_data_ref_dependence): Convert return type from bool
8476 to opt_result. Change sense of return type from "false"
8477 effectively meaning "no problems" to "false" meaning a problem,
8478 so that "return false" becomes "return opt_result::success".
8479 Convert "return true" calls to opt_result::failure_at, using
8480 the location of statement A rather than vect_location.
8481 (vect_analyze_data_ref_dependences): Convert return type from bool
8482 to opt_result.
8483 (verify_data_ref_alignment): Likewise, converting dump_printf_loc
8484 calls to opt_result::failure_at, using the stmt location rather
8485 than vect_location.
8486 (vect_verify_datarefs_alignment): Convert return type from bool
8487 to opt_result.
8488 (vect_enhance_data_refs_alignment): Likewise. Split local "stat"
8489 into multiple more-tightly-scoped copies.
8490 (vect_analyze_data_refs_alignment): Convert return type from bool
8491 to opt_result.
8492 (vect_analyze_data_ref_accesses): Likewise, converting a
8493 "return false" to a "return opt_result::failure_at", adding a
8494 new message.
8495 (vect_prune_runtime_alias_test_list): Convert return type from
8496 bool to opt_result, converting dump_printf_loc to
8497 opt_result::failure_at. Add a %G to show the pertinent statement,
8498 and use the stmt's location rather than vect_location.
8499 (vect_find_stmt_data_reference): Convert return type from
8500 bool to opt_result, converting dump_printf_loc to
8501 opt_result::failure_at, using stmt's location.
8502 (vect_analyze_data_refs): Convert return type from bool to
8503 opt_result. Convert "return false" to "return
8504 opt_result::failure_at", adding messages as needed.
8505 * tree-vect-loop.c (vect_determine_vf_for_stmt_1): Convert return
8506 type from bool to opt_result.
8507 (vect_determine_vf_for_stmt): Likewise.
8508 (vect_determine_vectorization_factor): Likewise, converting
8509 dump_printf_loc to opt_result::failure_at, using location of phi
8510 rather than vect_location.
8511 (vect_analyze_loop_form_1): Convert return type from bool to
8512 opt_result, converting dump_printf_loc calls, retaining the use of
8513 vect_location.
8514 (vect_analyze_loop_form): Convert return type from loop_vec_info
8515 to opt_loop_vec_info.
8516 (vect_analyze_loop_operations): Convert return type from bool to
8517 opt_result, converting dump_printf_loc calls, using the location
8518 of phi/stmt rather than vect_location where available. Convert
8519 various "return false" to "return opt_result::failure_at" with
8520 "unsupported phi" messages.
8521 (vect_get_datarefs_in_loop): Convert return type from bool to
8522 opt_result. Add a message for the
8523 PARAM_LOOP_MAX_DATAREFS_FOR_DATADEPS failure.
8524 (vect_analyze_loop_2): Convert return type from bool to
8525 opt_result. Ensure "ok" is set to a opt_result::failure_at before
8526 each "goto again;", adding new messages where needed.
8527 Add "unsupported grouped {store|load}" messages.
8528 (vect_analyze_loop): Convert return type from loop_vec_info to
8529 opt_loop_vec_info.
8530 * tree-vect-slp.c (vect_analyze_slp): Convert return type from
8531 bool to opt_result.
8532 * tree-vect-stmts.c (process_use): Likewise, converting
8533 dump_printf_loc call and using stmt location, rather than
8534 vect_location.
8535 (vect_mark_stmts_to_be_vectorized): Likeise.
8536 (vect_analyze_stmt): Likewise, adding a %G.
8537 (vect_get_vector_types_for_stmt): Convert return type from bool to
8538 opt_result, converting dump_printf_loc calls and using stmt
8539 location, rather than vect_location.
8540 (vect_get_mask_type_for_stmt): Convert return type from tree to
8541 opt_tree, converting dump_printf_loc calls and using stmt location.
8542 * tree-vectorizer.c: Include "opt-problem.h.
8543 (try_vectorize_loop_1): Flag "Analyzing loop at" dump message as
8544 MSG_PRIORITY_INTERNALS. Convert local "loop_vinfo" from
8545 loop_vec_info to opt_loop_vec_info. If if fails, and dumping is
8546 enabled, use it to report at the top level "couldn't vectorize
8547 loop" followed by the problem.
8548 * tree-vectorizer.h (opt_loop_vec_info): New typedef.
8549 (vect_mark_stmts_to_be_vectorized): Convert return type from bool
8550 to opt_result.
8551 (vect_analyze_stmt): Likewise.
8552 (vect_get_vector_types_for_stmt): Likewise.
8553 (tree vect_get_mask_type_for_stmt): Likewise.
8554 (vect_analyze_data_ref_dependences): Likewise.
8555 (vect_enhance_data_refs_alignment): Likewise.
8556 (vect_analyze_data_refs_alignment): Likewise.
8557 (vect_verify_datarefs_alignment): Likewise.
8558 (vect_analyze_data_ref_accesses): Likewise.
8559 (vect_prune_runtime_alias_test_list): Likewise.
8560 (vect_find_stmt_data_reference): Likewise.
8561 (vect_analyze_data_refs): Likewise.
8562 (vect_analyze_loop): Convert return type from loop_vec_info to
8563 opt_loop_vec_info.
8564 (vect_analyze_loop_form): Likewise.
8565 (vect_analyze_slp): Convert return type from bool to opt_result.
8566
8567 2018-10-04 David Malcolm <dmalcolm@redhat.com>
8568
8569 * doc/invoke.texi (-fopt-info): Document new "internals"
8570 sub-option.
8571 * dump-context.h (dump_context::apply_dump_filter_p): New decl.
8572 * dumpfile.c (dump_options): Update for renaming of MSG_ALL to
8573 MSG_ALL_KINDS.
8574 (optinfo_verbosity_options): Add "internals".
8575 (kind_as_string): Update for renaming of MSG_ALL to MSG_ALL_KINDS.
8576 (dump_context::apply_dump_filter_p): New member function.
8577 (dump_context::dump_loc): Use apply_dump_filter_p rather than
8578 explicitly masking the dump_kind.
8579 (dump_context::begin_scope): Increment the scope depth first. Use
8580 apply_dump_filter_p rather than explicitly masking the dump_kind.
8581 (dump_context::emit_item): Use apply_dump_filter_p rather than
8582 explicitly masking the dump_kind.
8583 (dump_dec): Likewise.
8584 (dump_hex): Likewise.
8585 (dump_switch_p_1): Default to MSG_ALL_PRIORITIES.
8586 (opt_info_switch_p_1): Default to MSG_PRIORITY_USER_FACING.
8587 (opt_info_switch_p): Update handling of default
8588 MSG_OPTIMIZED_LOCATIONS to cope with default of
8589 MSG_PRIORITY_USER_FACING.
8590 (dump_basic_block): Use apply_dump_filter_p rather than explicitly
8591 masking the dump_kind.
8592 (selftest::test_capture_of_dump_calls): Update test_dump_context
8593 instances to use MSG_ALL_KINDS | MSG_PRIORITY_USER_FACING rather
8594 than MSG_ALL. Generalize scope test to be run at all four
8595 combinations of with/without MSG_PRIORITY_USER_FACING and
8596 MSG_PRIORITY_INTERNALS, adding examples of explicit priority
8597 for each of the two values.
8598 * dumpfile.h (enum dump_flag): Add comment about the MSG_* flags.
8599 Rename MSG_ALL to MSG_ALL_KINDS. Add MSG_PRIORITY_USER_FACING,
8600 MSG_PRIORITY_INTERNALS, and MSG_ALL_PRIORITIES, updating the
8601 values for TDF_COMPARE_DEBUG and TDF_ALL_VALUES.
8602 (AUTO_DUMP_SCOPE): Add a note to the comment about the interaction
8603 with MSG_PRIORITY_*.
8604 * tree-vect-loop-manip.c (vect_loop_versioning): Mark versioning
8605 dump messages as MSG_PRIORITY_USER_FACING.
8606 * tree-vectorizer.h (DUMP_VECT_SCOPE): Add a note to the comment
8607 about the interaction with MSG_PRIORITY_*.
8608
8609 2018-10-04 Bernd Edlinger <bernd.edlinger@hotmail.de>
8610
8611 * varasm.c (output_constant): Add new parameter merge_strings.
8612 Make strings properly zero terminated in merge string sections.
8613 (mergeable_string_section): Don't fail if the last char is non-zero.
8614 (assemble_variable_contents): Handle merge string sections.
8615 (assemble_variable): Likewise.
8616 (assemble_constant_contents): Likewise.
8617 (output_constant_def_contents): Likewise.
8618 (output_constructor_array_range,
8619 output_constructor_regular_field): Adjust call to output_constant.
8620 (output_object_block): Adjust call to assemble_constant_contents
8621 and assemble_variable_contents.
8622
8623 2018-10-04 Martin Liska <mliska@suse.cz>
8624
8625 PR c/87483
8626 * cgraphunit.c (process_function_and_variable_attributes):
8627 Warn about a function with alias attribute and a body.
8628
8629 2018-10-04 Martin Liska <mliska@suse.cz>
8630
8631 PR ipa/82625
8632 * multiple_target.c (redirect_to_specific_clone): New function.
8633 (ipa_target_clone): Use it.
8634 * tree-inline.c: Fix comment.
8635
8636 2018-10-04 David Malcolm <dmalcolm@redhat.com>
8637
8638 * dumpfile.c (gcc::dump_manager::dump_manager): Initialize new
8639 fields.
8640 (gcc::dump_manager::~dump_manager): Free m_optinfo_filename.
8641 (gcc::dump_manager::register_pass): New member function, adapted
8642 from loop body in gcc::pass_manager::register_pass, adding a
8643 call to update_dfi_for_opt_info.
8644 (gcc::dump_manager::opt_info_enable_passes): Store the
8645 -fopt-info options into the new fields. Move the loop
8646 bodies into...
8647 (gcc::dump_manager::update_dfi_for_opt_info): ...this new member
8648 function.
8649 * dumpfile.h (struct opt_pass): New forward decl.
8650 (gcc::dump_manager::register_pass): New decl.
8651 (gcc::dump_manager::update_dfi_for_opt_info): New decl.
8652 (class gcc::dump_manager): Add fields "m_optgroup_flags",
8653 "m_optinfo_flags", and "m_optinfo_filename".
8654 * passes.c (gcc::pass_manager::register_pass): Move all of the
8655 dump-handling code to gcc::dump_manager::register_pass.
8656
8657 2018-10-04 Peter Bergner <bergner@linux.ibm.com>
8658
8659 PR rtl-optimization/87466
8660 * target.def (setjmp_preserves_nonvolatile_regs_p): New target hook.
8661 * doc/tm.texi.in (TARGET_SETJMP_PRESERVES_NONVOLATILE_REGS_P): New hook.
8662 * doc/tm.texi: Regenerate.
8663 * ira-lives.c (process_bb_node_lives): Use the new target hook.
8664 * lra-lives.c (process_bb_lives): Likewise.
8665 * config/rs6000/rs6000.c (TARGET_SETJMP_PRESERVES_NONVOLATILE_REGS_P):
8666 Define.
8667
8668 2018-10-04 Tamar Christina <tamar.christina@arm.com>
8669
8670 * params.c (add_params): Fix initialization.
8671
8672 2018-10-04 Martin Liska <mliska@suse.cz>
8673
8674 PR gcov-profile/84107
8675 * tree-profile.c (init_ic_make_global_vars):
8676 Remove ic_void_ptr_var and ic_gcov_type_ptr_var.
8677 Come up with new ic_tuple* variables. Emit
8678 __gcov_indirect_call{,_topn} variables.
8679 (gimple_gen_ic_profiler): Access the variable
8680 and emit gimple.
8681 (gimple_gen_ic_func_profiler): Access
8682 __gcov_indirect_call.callee field.
8683 (gimple_init_gcov_profiler): Use ptr_type_node.
8684 * value-prof.c (gimple_ic): Use ptr_type_node.
8685
8686 2018-10-04 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
8687
8688 PR tree-optimization/85787
8689 * ipa-pure-const.c (malloc_candidate_p_1): Move most of
8690 malloc_candidate_p into this function and add support for
8691 detecting multiple phis.
8692 (DUMP_AND_RETURN): Move from malloc_candidate_p into top-level macro.
8693
8694 2018-10-04 Martin Liska <mliska@suse.cz>
8695
8696 PR ipa/87491
8697 * ipa-inline.c (inline_to_all_callers_1):
8698 Call ultimate_alias_target for node being inlined.
8699
8700 2018-10-03 Jeff Law <law@redhat.com>
8701
8702 * gimple-ssa-sprintf.c (format_string): Do not hardcode size of
8703 target's wchar_t.
8704 * tree.c (get_typenode_from_name): Moved from fortran/trans-types.c.
8705 * tree.h (get_typenode_from_name): Prototype.
8706
8707 2018-10-03 Uros Bizjak <ubizjak@gmail.com>
8708
8709 * config/i386/i386.md (*cmp<X87MODEF:mode>_<SWI24:mode>_i387):
8710 Change operand 2 predicate to nonimmediate_operand.
8711 (*cmp<X87MODEF:mode>_<SWI24:mode>_cc_i387): Ditto.
8712
8713 2018-10-03 Martin Sebor <msebor@redhat.com>
8714 Jeff Law <law@redhat.com>
8715
8716 * gimple-ssa-sprintf.c (struct fmtresult): Add new member and
8717 initialize it.
8718 (get_string_length): Detect unterminated arrays.
8719 (format_string): Same.
8720 (format_directive): Warn about unterminated arrays.
8721 (handle_gimple_call): Mark statements with no_warning as needed.
8722
8723 2018-10-03 Jim Wilson <jimw@sifive.com>
8724
8725 * config/riscv/riscv-c.c (riscv_cpu_cpp_builtins): For ABI_ILP32E,
8726 also define __riscv_abi_rve. Delete trailing white space.
8727
8728 2018-10-03 Paul Koning <ni1d@arrl.net>
8729
8730 Enable LRA register allocator for PDP11.
8731 * config/pdp11/constraints.md (Q): Use define_memory_constraint.
8732 (R): Likewise.
8733 (D): Likewise.
8734 * config/pdp11/pdp11.c (pdp11_lra_p): New function.
8735 * config/pdp11/pdp11.opt (-mlra): New option.
8736 * doc/invoke.texi (PDP-11 Options): Document -mlra.
8737
8738 2018-10-03 Uros Bizjak <ubizjak@gmail.com>
8739
8740 * config/i386/i386.md (*<absneg:code>extendsfdf2): Remove.
8741 (*<absneg:code>extend<mode>xf2): Ditto.
8742
8743 2018-10-03 Aldy Hernandez <aldyh@redhat.com>
8744
8745 PR tree-optimization/87415
8746 * tree-vrp.c (set_value_range_with_overflow): Special case one bit
8747 precision fields.
8748
8749 2018-10-02 Jeff Law <law@redhat.com>
8750
8751 * gimple-fold.c (get_range_strlen): Only set *nonstr when
8752 an unterminated string is discovered. Bubble up range
8753 even for unterminated strings.
8754 (gimple_fold_builtin_strlen): Do not fold if get_range_strlen
8755 indicates the string was not terminated via NONSTR.
8756
8757 2018-10-03 Aldy Hernandez <aldyh@redhat.com>
8758
8759 * tree-vrp.c (extract_range_from_unary_expr): Special case all
8760 pointer conversions.
8761 Do not do anything special for anti-ranges.
8762
8763 2018-10-03 Jérôme Lambourg <lambourg@adacore.com>
8764
8765 * config/arm/vxworks.h (ARM_TARGET2_DWARF_FORMAT): Adjust to
8766 DW_EH_PE_pcrel | DW_EH_PE_indirect for RTPs.
8767
8768 2018-10-03 Martin Liska <mliska@suse.cz>
8769
8770 PR gcov-profile/86109
8771 * coverage.c (coverage_begin_function): Do not
8772 mark lambdas as artificial.
8773 * tree-core.h (struct GTY): Remove tm_clone_flag
8774 and introduce new lambda_function.
8775 * tree.h (DECL_LAMBDA_FUNCTION): New macro.
8776
8777 2018-10-02 Aaron Sawdey <acsawdey@linux.ibm.com>
8778
8779 PR target/87474
8780 * config/rs6000/rs6000-string.c (expand_strn_compare): Check that both
8781 P8_VECTOR and VSX are enabled.
8782
8783 2018-10-02 Andreas Krebbel <krebbel@linux.ibm.com>
8784
8785 * config/s390/driver-native.c (s390_host_detect_local_cpu): Add
8786 0x3907 as CPU model number.
8787
8788 2018-10-02 Andreas Krebbel <krebbel@linux.ibm.com>
8789
8790 * common/config/s390/s390-common.c: Rename PF_ARCH12 to PF_Z14.
8791 * config/s390/s390.h (enum processor_flags): Rename PF_ARCH12 to
8792 PF_Z14. Rename TARGET_CPU_ARCH12 to TARGET_CPU_Z14,
8793 TARGET_CPU_ARCH12_P to TARGET_CPU_Z14_P, TARGET_ARCH12 to
8794 TARGET_Z14, and TARGET_ARCH12_P to TARGET_Z14_P.
8795 * config/s390/s390.md: Likewise. Rename also the cpu attribute
8796 value from arch12 to z14.
8797
8798 2018-10-02 Uros Bizjak <ubizjak@gmail.com>
8799
8800 * config/i386/i386.md (fxam<mode>2_i387_with_temp): Remove.
8801 (isinfxf2): Ditto.
8802 (isinf<mode>2): Ditto.
8803
8804 2018-10-02 Uros Bizjak <ubizjak@gmail.com>
8805
8806 * config/i386/i386.c (ix86_emit_i387_round): Extend op1 to XFmode
8807 before emitting fxam. Perform calculations in XFmode.
8808
8809 2018-10-02 Marc Glisse <marc.glisse@inria.fr>
8810
8811 * match.pd (((X /[ex] A) +- B) * A): New transformation.
8812
8813 2018-10-02 Marc Glisse <marc.glisse@inria.fr>
8814
8815 PR middle-end/87319
8816 * fold-const.c (fold_plusminus_mult_expr): Handle complex and vectors.
8817 * tree.c (signed_or_unsigned_type_for): Handle complex.
8818
8819 2018-10-02 Jeff Law <law@redhat.com>
8820
8821 * gimple-fold.c (get_range_strlen): Remove dead code.
8822
8823 2018-10-02 Martin Sebor <msebor@redhat.com>
8824 Jeff Law <law@redhat.com>
8825
8826 * builtins.c (unterminated_array): Add new arguments.
8827 If argument is not terminated, bubble up size and exact
8828 state to callers.
8829 (expand_builtin_strnlen): Detect, avoid expanding
8830 and diagnose unterminated arrays.
8831 (c_strlen): Fill in offset of start of unterminated strings.
8832 * builtins.h (unterminated_array): Update prototype.
8833
8834 2018-10-02 Richard Biener <rguenther@suse.de>
8835
8836 * config/i386/sse.md (reduc_plus_scal_v4df): Avoid the use
8837 of haddv4df, first reduce to SSE width and exploit the fact
8838 that we only need element zero with the reduction result.
8839 (reduc_plus_scal_v2df): Likewise.
8840
8841 2018-10-02 Eric Botcazou <ebotcazou@adacore.com>
8842
8843 * dojump.h (do_jump): Delete.
8844 (do_jump_1): Likewise.
8845 (split_comparison): Move around.
8846 * dojump.c (do_jump): Make static.
8847 (do_jump_1): Likewise.
8848 (jumpifnot): Move around.
8849 (jumpifnot_1): Likewise.
8850 (jumpif): Likewise.
8851 (jumpif_1): Likewise.
8852 * expr.c (expand_expr_real_1): Call jumpif[not] instead of do_jump.
8853
8854 2018-10-02 Eric Botcazou <ebotcazou@adacore.com>
8855
8856 * reorg.c (make_return_insns): Use emit_copy_of_insn_after for the
8857 insns in the delay slot and add_insn_after for the jump insn.
8858
8859 2018-10-02 Richard Biener <rguenther@suse.de>
8860
8861 * tree-inline.c (expand_call_inline): Use the location of
8862 the callee declaration for the inline-entry marker.
8863 * final.c (notice_source_line): Remove special-casing of
8864 NOTE_INSN_INLINE_ENTRY.
8865
8866 2018-10-01 Carl Love <cel@us.ibm.com>
8867
8868 PR 69431
8869 * config/rs6000/rs6000-builtin.def (__builtin_mffsl): New.
8870 (__builtin_mtfsb0): New.
8871 (__builtin_mtfsb1): New.
8872 ( __builtin_set_fpscr_rn): New.
8873 (__builtin_set_fpscr_drn): New.
8874 * config/rs6000/rs6000.c (rs6000_expand_mtfsb_builtin): Add.
8875 (rs6000_expand_set_fpscr_rn_builtin): Add.
8876 (rs6000_expand_set_fpscr_drn_builtin): Add.
8877 (rs6000_expand_builtin): Add case statement entries for
8878 RS6000_BUILTIN_MTFSB0, RS6000_BUILTIN_MTFSB1,
8879 RS6000_BUILTIN_SET_FPSCR_RN, RS6000_BUILTIN_SET_FPSCR_DRN,
8880 RS6000_BUILTIN_MFFSL.
8881 (rs6000_init_builtins): Add ftype initialization and def_builtin
8882 calls for __builtin_mffsl, __builtin_mtfsb0, __builtin_mtfsb1,
8883 __builtin_set_fpscr_rn, __builtin_set_fpscr_drn.
8884 * config/rs6000.md (rs6000_mtfsb0, rs6000_mtfsb1, rs6000_mffscrn,
8885 rs6000_mffscdrn): Add define_insn.
8886 (rs6000_set_fpscr_rn, rs6000_set_fpscr_drn): Add define_expand.
8887 * doc/extend.texi: Add documentation for the builtins.
8888
8889 2018-10-01 Richard Biener <rguenther@suse.de>
8890
8891 PR tree-optimization/87465
8892 * tree-ssa-loop-ivcanon.c (tree_estimate_loop_size): Fix typo
8893 causing branch miscounts.
8894
8895 2018-10-01 Tamar Christina <tamar.christina@arm.com>
8896
8897 * common/config/aarch64/aarch64-common.c (TARGET_OPTION_DEFAULT_PARAM,
8898 aarch64_option_default_param): New.
8899 (params.h): Include.
8900 (TARGET_OPTION_VALIDATE_PARAM, aarch64_option_validate_param): New.
8901 * config/aarch64/aarch64.c (aarch64_override_options_internal): Simplify
8902 stack-clash protection validation code.
8903
8904 2018-10-01 Tamar Christina <tamar.christina@arm.com>
8905
8906 * params.c (validate_param): New.
8907 (add_params): Use it.
8908 (set_param_value): Refactor param validation into validate_param.
8909 (diagnostic.h): Include.
8910 * diagnostic.h (diagnostic_ready_p): New.
8911
8912 2018-10-01 Tamar Christina <tamar.christina@arm.com>
8913
8914 * params.c (set_param_value):
8915 Add index of parameter being validated.
8916 * common/common-target.def (option_validate_param): New.
8917 * common/common-targhooks.h (default_option_validate_param): New.
8918 * common/common-targhooks.c (default_option_validate_param): New.
8919 * doc/tm.texi.in (TARGET_OPTION_VALIDATE_PARAM): New.
8920 * doc/tm.texi: Regenerate.
8921
8922 2018-10-01 Tamar Christina <tamar.christina@arm.com>
8923
8924 PR target/86486
8925 * config/aarch64/aarch64.c (aarch64_override_options_internal):
8926 Add validation for stack-clash parameters and set defaults.
8927
8928 2018-10-01 Tamar Christina <tamar.christina@arm.com>
8929
8930 PR target/86486
8931 * configure.ac: Add stack-clash-protection-guard-size.
8932 * doc/install.texi: Document it.
8933 * config.in (DEFAULT_STK_CLASH_GUARD_SIZE): New.
8934 * params.def: Update comment for guard-size.
8935 (PARAM_STACK_CLASH_PROTECTION_GUARD_SIZE,
8936 PARAM_STACK_CLASH_PROTECTION_PROBE_INTERVAL): Update description.
8937 * configure: Regenerate.
8938
8939 2018-10-01 Tamar Christina <tamar.christina@arm.com>
8940
8941 PR target/86486
8942 * config/aarch64/aarch64.h (STACK_CLASH_MIN_BYTES_OUTGOING_ARGS,
8943 STACK_DYNAMIC_OFFSET): New.
8944 * config/aarch64/aarch64.c (aarch64_layout_frame):
8945 Update outgoing args size.
8946 (aarch64_stack_clash_protection_alloca_probe_range,
8947 TARGET_STACK_CLASH_PROTECTION_ALLOCA_PROBE_RANGE): New.
8948
8949 2018-10-01 Tamar Christina <tamar.christina@arm.com>
8950
8951 PR target/86486
8952 * explow.c (anti_adjust_stack_and_probe_stack_clash): Support custom
8953 probe ranges.
8954 * target.def (stack_clash_protection_alloca_probe_range): New.
8955 (stack_clash_protection_final_dynamic_probe): Remove.
8956 * targhooks.h (default_stack_clash_protection_alloca_probe_range) New.
8957 (default_stack_clash_protection_final_dynamic_probe): Remove.
8958 * targhooks.c: Likewise.
8959 * doc/tm.texi.in (TARGET_STACK_CLASH_PROTECTION_ALLOCA_PROBE_RANGE): New.
8960 (TARGET_STACK_CLASH_PROTECTION_FINAL_DYNAMIC_PROBE): Remove.
8961 * doc/tm.texi: Regenerate.
8962
8963 2018-10-01 Tamar Christina <tamar.christina@arm.com>
8964
8965 PR target/86486
8966 * config/aarch64/aarch64-protos.h (aarch64_output_probe_sve_stack_clash): New.
8967 * config/aarch64/aarch64.c (aarch64_output_probe_sve_stack_clash,
8968 aarch64_clamp_to_uimm12_shift): New.
8969 (aarch64_allocate_and_probe_stack_space): Add SVE specific section.
8970 * config/aarch64/aarch64.md (probe_sve_stack_clash): New.
8971
8972 2018-10-01 Tamar Christina <tamar.christina@arm.com>
8973
8974 PR target/86486
8975 * config/aarch64/aarch64.c (aarch64_layout_frame): Add assert.
8976
8977 2018-10-01 Jeff Law <law@redhat.com>
8978 Richard Sandiford <richard.sandiford@linaro.org>
8979 Tamar Christina <tamar.christina@arm.com>
8980
8981 PR target/86486
8982 * config/aarch64/aarch64.md
8983 (probe_stack_range): Add k (SP) constraint.
8984 * config/aarch64/aarch64.h (STACK_CLASH_CALLER_GUARD,
8985 STACK_CLASH_MAX_UNROLL_PAGES): New.
8986 * config/aarch64/aarch64.c (aarch64_output_probe_stack_range): Emit
8987 stack probes for stack clash.
8988 (aarch64_allocate_and_probe_stack_space): New.
8989 (aarch64_expand_prologue): Use it.
8990 (aarch64_expand_epilogue): Likewise and update IP regs re-use criteria.
8991 (aarch64_sub_sp): Add emit_move_imm optional param.
8992
8993 2018-10-01 MCC CS <deswurstes@users.noreply.github.com>
8994
8995 PR tree-optimization/87261
8996 * match.pd: Remove trailing whitespace.
8997 Add (x & y) | ~(x | y) -> ~(x ^ y),
8998 (~x | y) ^ (x ^ y) -> x | ~y and (x ^ y) | ~(x | y) -> ~(x & y)
8999
9000 2018-10-01 Claudiu Zissulescu <claziss@synopsys.com>
9001
9002 * config/arc/arc.md (*add_n): Clean up pattern, update instruction
9003 constraints.
9004 (ashlsi3_insn): Update instruction constraints.
9005 (ashrsi3_insn): Likewise.
9006 (rotrsi3): Likewise.
9007 (add_shift): Likewise.
9008 * config/arc/constraints.md (Csz): New 32 bit constraint. It
9009 avoids placing in the limm field small constants which, otherwise,
9010 could end into a small instruction.
9011
9012 2018-10-01 Claudiu Zissulescu <claziss@synopsys.com>
9013
9014 * config/arc/arc.md (maddsidi4_split): Don't use dmac if the
9015 destination register is not odd-even.
9016 (umaddsidi4_split): Likewise.
9017
9018 2018-10-01 Richard Biener <rguenther@suse.de>
9019
9020 * tree-inline.c (expand_call_inline): Store origin of fn
9021 in BLOCK_ABSTRACT_ORIGIN for the inline BLOCK.
9022 * tree.c (block_ultimate_origin): Simplify and do some
9023 checking.
9024
9025 2018-09-30 Uros Bizjak <ubizjak@gmail.com>
9026
9027 * config/i386/mmx.md (EMMS): New int iterator.
9028 (emms): New int attribute.
9029 (mmx_<emms>): Macroize insn from *mmx_emms and *mmx_femms using
9030 EMMS int iterator. Explicitly declare clobbers.
9031 (mmx_emms): Remove expander.
9032 (mmx_femms): Ditto.
9033 * config/i386/predicates.md (emms_operation): Remove predicate.
9034 (vzeroall_pattern): New predicate.
9035 (vzeroupper_pattern): Rename from vzeroupper_operation.
9036 * config/i386/i386.c (ix86_avx_u128_mode_after): Use
9037 vzeroupper_pattern and vzeroall_pattern predicates.
9038
9039 2018-09-30 Peter Bergner <bergner@linux.ibm.com>
9040
9041 PR rtl-optimization/86939
9042 * ira-lives.c (make_hard_regno_born): Rename from this...
9043 (make_hard_regno_live): ... to this. Remove update to conflict
9044 information. Update function comment.
9045 (make_hard_regno_dead): Add conflict information update. Update
9046 function comment.
9047 (make_object_born): Rename from this...
9048 (make_object_live): ... to this. Remove update to conflict information.
9049 Update function comment.
9050 (make_object_dead): Add conflict information update. Update function
9051 comment.
9052 (mark_pseudo_regno_live): Call make_object_live.
9053 (mark_pseudo_regno_subword_live): Likewise.
9054 (mark_hard_reg_dead): Update function comment.
9055 (mark_hard_reg_live): Call make_hard_regno_live.
9056 (process_bb_node_lives): Likewise.
9057 * lra-lives.c (make_hard_regno_born): Rename from this...
9058 (make_hard_regno_live): ... to this. Remove update to conflict
9059 information. Remove now uneeded check_pic_pseudo_p argument.
9060 Update function comment.
9061 (make_hard_regno_dead): Add check_pic_pseudo_p argument and add update
9062 to conflict information. Update function comment.
9063 (mark_pseudo_live): Remove update to conflict information. Update
9064 function comment.
9065 (mark_pseudo_dead): Add conflict information update.
9066 (mark_regno_live): Call make_hard_regno_live.
9067 (mark_regno_dead): Call make_hard_regno_dead with new arguement.
9068 (process_bb_lives): Call make_hard_regno_live and make_hard_regno_dead.
9069
9070 2018-09-29 H.J. Lu <hongjiu.lu@intel.com>
9071
9072 PR target/87370
9073 * config/i386/i386.c (construct_container): Use TImode for
9074 BLKmode values in 2 integer registers.
9075
9076 2018-09-29 Jeff Law <law@redhat.com>
9077
9078 * builtins.c (unterminated_array): Pass in c_strlen_data * to
9079 c_strlen rather than just a tree *.
9080 (c_strlen): Change NONSTR argument to a c_strlen_data pointer.
9081 Update recursive calls appropriately. If caller did not provide a
9082 suitable data pointer, create a local one. When a non-terminated
9083 string is discovered, bubble up information about the string via the
9084 c_strlen_data object.
9085 * builtins.h (c_strlen): Update prototype.
9086 (c_strlen_data): New structure.
9087 * gimple-fold.c (get_range_strlen): Update calls to c_strlen.
9088 For a type 2 call, if c_strlen indicates a non-terminated string
9089 use the length of the non-terminated string.
9090 (gimple_fold_builtin_stpcpy): Update calls to c_strlen.
9091
9092 2018-09-29 Jakub Jelinek <jakub@redhat.com>
9093
9094 PR target/87467
9095 * config/i386/avx512fintrin.h (_mm512_abs_pd, _mm512_mask_abs_pd): Use
9096 __m512d type for __A argument rather than __m512.
9097
9098 2018-09-28 John David Anglin <danglin@gcc.gnu.org>
9099
9100 * match.pd (simple_comparison): Don't optimize if either operand is
9101 a function pointer when target needs function pointer canonicalization.
9102
9103 2018-09-28 Segher Boessenkool <segher@kernel.crashing.org>
9104
9105 * config/rs6000/driver-rs6000.c (asm_names): Adjust the entries for
9106 power5 .. power9 to remove indirection.
9107 * config/rs6000/rs6000.h (ASM_CPU_POWER5_SPEC, ASM_CPU_POWER6_SPEC,
9108 ASM_CPU_POWER7_SPEC, ASM_CPU_POWER8_SPEC, ASM_CPU_POWER9_SPEC,
9109 ASM_CPU_476_SPEC): Delete.
9110 (ASM_CPU_SPEC): Adjust.
9111 (EXTRA_SPECS): Delete asm_cpu_power5, asm_cpu_power6, asm_cpu_power7,
9112 asm_cpu_power8, asm_cpu_power9, asm_cpu_476.
9113
9114 2018-09-28 Segher Boessenkool <segher@kernel.crashing.org>
9115
9116 * config.in: Delete HAVE_AS_DCI.
9117 * config/powerpcspe/powerpcspe.h: Treat HAVE_AS_DCI as always true.
9118 * config/rs6000/rs6000.h: Ditto.
9119 * configure.ac: Delete HAVE_AS_DCI.
9120 * configure: Regenerate.
9121
9122 2018-09-28 Segher Boessenkool <segher@kernel.crashing.org>
9123
9124 * config.in (HAVE_AS_LWSYNC): Delete.
9125 * config/powerpcspe/powerpcspe.h (TARGET_LWSYNC_INSTRUCTION): Delete.
9126 * config/powerpcspe/sync.md (*lwsync): Always generate lwsync, never
9127 do it as a .long .
9128 * config/rs6000/rs6000.h (TARGET_LWSYNC_INSTRUCTION): Delete.
9129 * config/rs6000/sync.md (*lwsync): Always generate lwsync, never do it
9130 as a .long .
9131 * configure.ac: Delete HAVE_AS_LWSYNC.
9132 * configure: Regenerate.
9133
9134 2018-09-28 Eric Botcazou <ebotcazou@adacore.com>
9135 Pierre-Marie de Rodat <derodat@adacore.com>
9136
9137 * calls.c (expand_call): Try to do a tail call for thunks at -O0 too.
9138 * cgraph.h (struct cgraph_thunk_info): Add indirect_offset.
9139 (cgraph_node::create_thunk): Add indirect_offset parameter.
9140 (thunk_adjust): Likewise.
9141 * cgraph.c (cgraph_node::create_thunk): Add indirect_offset parameter
9142 and initialize the corresponding field with it.
9143 (cgraph_node::dump): Dump indirect_offset field.
9144 * cgraphclones.c (duplicate_thunk_for_node): Deal with indirect_offset.
9145 * cgraphunit.c (cgraph_node::analyze): Be prepared for external thunks.
9146 (thunk_adjust): Add indirect_offset parameter and deal with it.
9147 (cgraph_node::expand_thunk): Deal with the indirect_offset field and
9148 pass it to thunk_adjust. Do not call the target hook if it's non-zero
9149 or if the thunk is external or local. Fix formatting. Do not chain
9150 the RESULT_DECL to BLOCK_VARS. Pass the static chain to the target,
9151 if any, in the GIMPLE representation.
9152 * ipa-icf.c (sem_function::equals_wpa): Deal with indirect_offset.
9153 * lto-cgraph.c (lto_output_node): Write indirect_offset field.
9154 (input_node): Read indirect_offset field.
9155 * tree-inline.c (expand_call_inline): Pass indirect_offset field in the
9156 call to thunk_adjust.
9157 * tree-nested.c (struct nesting_info): Add thunk_p field.
9158 (create_nesting_tree): Set it.
9159 (convert_all_function_calls): Copy static chain from targets to thunks.
9160 (finalize_nesting_tree_1): Return early for thunks.
9161 (unnest_nesting_tree_1): Do not finalize thunks.
9162 (gimplify_all_functions): Do not gimplify thunks.
9163
9164 2018-09-28 David Malcolm <dmalcolm@redhat.com>
9165
9166 * opt-suggestions.c (option_proposer::build_option_suggestions):
9167 Release "option_values".
9168
9169 2018-09-28 David Malcolm <dmalcolm@redhat.com>
9170
9171 * coverage.c (get_coverage_counts): Convert problem-reporting dump
9172 messages from MSG_OPTIMIZED_LOCATIONS to MSG_MISSED_OPTIMIZATION.
9173 * dumpfile.c (kind_as_string): New function.
9174 (dump_loc): Rather than a hardcoded prefix of "note: ", use
9175 kind_as_string to vary the prefix based on dump_kind.
9176 (selftest::test_capture_of_dump_calls): Update for above.
9177
9178 2018-09-28 Uros Bizjak <ubizjak@gmail.com>
9179
9180 * config/i386/i386.h (SSE_REGNO): Fix check for FIRST_REX_SSE_REG.
9181 (GET_SSE_REGNO): Rename from SSE_REGNO. Update all uses for rename.
9182
9183 2018-09-28 Uros Bizjak <ubizjak@gmail.com>
9184
9185 * config/i386/i386.h (CC_REGNO): Remove FPSR_REG.
9186 * config/i386/i386.c (ix86_fixed_condition_code_regs): Use
9187 INVALID_REGNUM instead of FPSR_REG.
9188 (ix86_md_asm_adjust): Do not clobber FPSR_REG.
9189 * config/i386/i386.md: Update comment of FP compares.
9190 (fldenv): Do not clobber FPSR_REG.
9191
9192 2018-09-28 Richard Biener <rguenther@suse.de>
9193
9194 * tree.h (BLOCK_ORIGIN): New.
9195 * omp-expand.c (grid_expand_target_grid_body): Assign
9196 BLOCK_ORIGIN to BLOCK_ABSTRACT_ORIGIN.
9197 * tree-inline.c (remap_block): Likewise.
9198 * auto-profile.c (get_function_decl_from_block): Simplify
9199 by eliding the BLOCK_ABSTRACT_ORIGIN chasing.
9200 * langhooks.c (lhd_print_error_function): Likewise.
9201 * optinfo-emit-json.cc (optrecord_json_writer::inlining_chain_to):
9202 Likewise.
9203 * tree-ssa-live.c (remove_unused_scope_block_p): Likewise.
9204 * tree.c (block_nonartificial_location): Likewise.
9205 (block_ultimate_origin): Likewise.
9206 * tree-pretty-print.c (percent_K_format): Likewise. Remove
9207 no longer needed LTO case.
9208
9209 2018-09-28 Andrew Stubbs <ams@codesourcery.com>
9210 Jan Hubicka <jh@suse.cz>
9211 Martin Jambor <mjambor@suse.cz>
9212
9213 * simplify-rtx.c (simplify_merge_mask): New function.
9214 (simplify_ternary_operation): Use it, also see if VEC_MERGEs with the
9215 same masks are used in op1 or op2.
9216 (test_vec_merge): New function.
9217 (test_vector_ops): Call test_vec_merge.
9218
9219 2018-09-28 Eric Botcazou <ebotcazou@adacore.com>
9220
9221 * config/sparc/sparc-protos.h (sparc_branch_cost): Declare.
9222 * config/sparc/sparc.h (BRANCH_COST): Call sparc_branch_cost.
9223 * config/sparc/sparc.c (struct processor_costs): Add branch_cost field.
9224 (cypress_costs): Set it.
9225 (supersparc_costs): Likewise.
9226 (hypersparc_costs): Likewise.
9227 (leon_cost): Likewise.
9228 (leon3_costs): Likewise.
9229 (sparclet_costs): Likewise.
9230 (ultrasparc_costs): Likewise.
9231 (ultrasparc_costs): Likewise.
9232 (niagara_costs): Likewise.
9233 (niagara2_costs): Likewise.
9234 (niagara3_costs): Likewise.
9235 (niagara4_costs): Likewise.
9236 (niagara7_costs): Likewise.
9237 (m8_costs): Likewise.
9238 (TARGET_CAN_FOLLOW_JUMP): Define.
9239 (pass_work_around_errata::gate): Minor tweak.
9240 (sparc_option_override): Remove MASK_FSMULD mask for V7 processors.
9241 Do not set both MASK_VIS4 and MASK_VIS4B for M8 processor.
9242 Automaitcally clear MASK_FSMULD mask for V7 processors.
9243 (sparc_can_follow_jump): New static function.
9244 (output_ubranch): Deal with CROSSING_JUMP_P.
9245 (sparc_use_sched_lookahead): Rewrite using switch statement.
9246 (sparc_issue_rate): Reorder.
9247 (sparc_branch_cost): New function.
9248
9249 2018-09-27 Martin Sebor <msebor@redhat.com>
9250
9251 * tree.h (tree_to_shwi): Add attribute nonnull and pure.
9252 (tree_to_poly_int64, tree_to_uhwi, tree_to_poly_uint64): Same.
9253 (int_fits_type_p): Same.
9254
9255 2018-09-27 Uros Bizjak <ubizjak@gmail.com>
9256
9257 * config/i386/i386.md (FPCR_REG): Remove.
9258 (UNSPEC_FLDCW): Remove.
9259 (x86_fnstcw_1): Use (const_int 0) instead of FPCR_REG.
9260 (x86_fldcw_1): Remove insn pattern.
9261 (fnstenv): Do not clobber FPCR_REG.
9262 (fldenv): Ditto.
9263 * config/i386/i386.h (FIXED_REGISTERS) Remove fpsr register.
9264 (CALL_USED_REGISTERS): Ditto.
9265 (REG_ALLOC_ORDER): Ditto.
9266 (REG_CLASS_CONTENTS): Ditto.
9267 (HI_REGISTER_NAMES): Ditto.
9268 (ADDITIONAL_REGISTER_NAMES): Use defines instead
9269 of numerical constants.
9270 * config/i386/i386.c (regclass_map): Remove fpsr register.
9271 (dbx_register_map): Ditto.
9272 (dbx64_register_map): Ditto.
9273 (svr4_dbx_register_map): Ditto.
9274 (print_reg): Do not handle FPCR_REG.
9275
9276 2018-09-27 Segher Boessenkool <segher@kernel.crashing.org>
9277
9278 PR target/87149
9279 * config.in (HAVE_AS_CMPB, HAVE_AS_DFP, HAVE_AS_FPRND, HAVE_AS_MFPGPR,
9280 HAVE_AS_POPCNTB, HAVE_AS_POPCNTD, HAVE_AS_POWER8, HAVE_AS_POWER9):
9281 Delete, always treat as true.
9282 * config/powerpcspe/powerpcspe.c (rs6000_option_override_internal):
9283 Ditto. Simplify remaining code.
9284 * config/powerpcspe/powerpcspe.h: Ditto.
9285 * config/rs6000/rs6000.c (rs6000_option_override_internal): Ditto.
9286 Simplify remaining code.
9287 (rs6000_expand_builtin): Ditto.
9288 * config/rs6000/rs6000.h: Ditto.
9289 * configure.ac: Ditto.
9290 * configure: Regenerate.
9291
9292 2018-09-27 Martin Liska <mliska@suse.cz>
9293
9294 * coverage.c (get_coverage_counts): Revert the formatting
9295 of missing profile opt info.
9296
9297 2018-09-27 Richard Biener <rguenther@suse.de>
9298
9299 PR debug/37801
9300 PR debug/87440
9301 * dwarf2out.c (set_block_origin_self): Do not mark outermost
9302 block as we do not output that.
9303 (gen_inlined_subroutine_die): Elide the originally outermost
9304 block, matching what we do for concrete instances.
9305 (decls_for_scope): Add parameter specifying whether to recurse
9306 to subblocks.
9307
9308 2018-09-27 Andrew Stubbs <ams@codesourcery.com>
9309 Tom de Vries <tom@codesourcery.com>
9310
9311 PR 82089
9312
9313 * expmed.c (emit_cstore): Fix handling of result_mode == BImode and
9314 STORE_FLAG_VALUE == 1.
9315
9316 2018-09-27 Andreas Krebbel <krebbel@linux.ibm.com>
9317
9318 * config/s390/s390.md (PPA_TX_ABORT, PPA_OOO_BARRIER): New
9319 constant definitions.
9320 ("tx_assist"): Replace magic number with PPA_TX_ABORT.
9321 ("*ppa"): Enable pattern also for -march=zEC12 -mno-htm.
9322 ("speculation_barrier"): New expander definition.
9323
9324 2018-09-26 Indu Bhagat <indu.bhagat@oracle.com>
9325
9326 PR gcov-profile/86957
9327 * common.opt: New warning option -Wmissing-profile.
9328 * coverage.c (get_coverage_counts): Add warning for missing .gcda file.
9329 * doc/invoke.texi: Document -Wmissing-profile.
9330
9331 2018-09-26 Jim Wilson <jimw@sifive.com>
9332
9333 * config/riscv/riscv.md (subsi3_extended2): Add J constraint.
9334 (negdi2, negsi2, negsi2_extended, negsi2_extended2): New.
9335
9336 2018-09-26 Martin Sebor <msebor@redhat.com>
9337
9338 * tree.c (zerop): Change return type to bool.
9339 (integer_zerop, integer_onep, integer_each_onep): Same.
9340 (integer_all_onesp, integer_minus_onep, integer_pow2p): Same.
9341 (integer_nonzerop, integer_truep, tree_ctz, real_zerop): Same.
9342 (real_onep, real_minus_onep, chain_index): Same.
9343 (print_type_hash_statistics, type_list_equal): Same.
9344 * tree.h (zerop): Same.
9345 (zerop, integer_zerop, integer_onep, integer_each_onep): Same.
9346 (integer_all_onesp, integer_minus_onep, integer_pow2p): Same.
9347 (integer_nonzerop, integer_truep, tree_ctz, real_zerop): Same.
9348 (real_onep, real_minus_onep, chain_index): Same.
9349 (print_type_hash_statistics, type_list_equal): Same.
9350
9351 2018-09-26 Jim Wilson <jimw@sifive.com>
9352
9353 * config/riscv/riscv.h (FUNCTION_ARG_REGNO_P): Fix comment.
9354
9355 2018-09-26 Jakub Jelinek <jakub@redhat.com>
9356
9357 PR target/87414
9358 * config/i386/i386.c: Include debug.h and dwarf2out.h.
9359 (output_indirect_thunk): Emit DW_CFA_def_cfa_offset after the
9360 call.
9361
9362 2018-09-25 Andrew Stubbs <ams@codesourcery.com>
9363
9364 * builtins.c (get_builtin_sync_mem): Force address mode conversion.
9365
9366 2018-09-26 Uros Bizjak <ubizjak@gmail.com>
9367
9368 * config/i386/i386.h (enum reg_class): Remove FP_TOP_SSE_REGS
9369 and FP_SECOND_SSE_REGS.
9370 (REG_CLASS_NAMES): Ditto.
9371 (REG_CLASS_CONTENTS): Ditto.
9372 * config/i386/i386.c (ix86_preferred_reload_class) Do not handle
9373 FP_TOP_SSE_REGS and FP_SECOND_SSE_REGS classes.
9374 (ix86_preferred_output_reload_class): Ditto.
9375 * config/i386/i386.md (fix_trunc<mode>_i387_fisttp): Change "=&1f"
9376 clobber constraint to "=&f".
9377 (fix_truncdi_i387): Ditto.
9378 (lrintxfdi2): Ditto.
9379 (fistdi2_<rounding>): Ditto.
9380 (fpremxf4_i387): Change "=u" constraint to "=f".
9381 (fprem1xf4_i387): Ditto.
9382 (sincosxf3): Ditto.
9383 (fptanxf4_i387): Ditto.
9384 (fxtractxf3_i387): Ditto.
9385 (fscalexf4_i387): Ditto.
9386 (atan2xf3): Change "u" constraint to "f".
9387 (fyl2xxf3_i387): Ditto.
9388 (fyl2xp1xf3_i387): Ditto.
9389
9390 2018-09-26 Uros Bizjak <ubizjak@gmail.com>
9391
9392 PR target/87439
9393 * config/i386/i386.h (NUM_MODES_FOR_MODE_SWITCHING): Update
9394 for removed I387_MASK_PM entity.
9395
9396
9397 2018-09-26 Jeff Law <law@redhat.com>
9398 Revert
9399 2018-09-26 Alexey Neyman <stilor@att.net>
9400
9401 * graphite.h: Include <isl/id.h> and <isl/space.h>; these
9402 headers are no longer pulled in by <isl/val.h>.
9403
9404 2018-09-26 Richard Biener <rguenther@suse.de>
9405
9406 PR debug/87443
9407 * dwarf2out.c (gen_lexical_block_die): Do not equate inline
9408 or concrete instance DIE to the tree. Create abstract origin
9409 attributes also for concrete instances.
9410
9411 2018-09-26 Alexey Neyman <stilor@att.net>
9412
9413 * graphite.h: Include <isl/id.h> and <isl/space.h>; these
9414 headers are no longer pulled in by <isl/val.h>.
9415
9416 2018-09-26 Matthew Malcomson <matthew.malcomson@arm.com>
9417
9418 * config/arm/arm.c (arm_split_compare_and_swap, arm_split_atomic_op):
9419 Use new helper functions.
9420 * config/arm/sync.md (atomic_load<mode>, atomic_store<mode>):
9421 Use new helper functions.
9422 * config/arm/aarch-common-protos.h (aarch_mm_needs_acquire,
9423 aarch_mm_needs_release): New declarations.
9424 * config/arm/aarch-common.c (aarch_mm_needs_acquire,
9425 aarch_mm_needs_release): New.
9426
9427 2018-09-26 Eric Botcazou <ebotcazou@adacore.com>
9428
9429 * config/arm/arm.c (arm_reorg): Skip Thumb reorg pass for thunks.
9430 (arm32_output_mi_thunk): Deal with long calls.
9431
9432 2018-09-26 Richard Biener <rguenther@suse.de>
9433
9434 PR debug/87428
9435 PR debug/87362
9436 * tree-inline.c (expand_call_inline): When the location
9437 of the call is UNKNOWN_LOCATION use DECL_SOURCE_LOCATION
9438 or BUILTINS_LOCATION for the BLOCK_SOURCE_LOCATION of
9439 the inserted BLOCK to make inlined_function_outer_scope_p
9440 recognize it.
9441 * dwarf2out.c (add_call_src_coords_attributes): Do not add
9442 coords for reserved locations.
9443
9444 2018-09-25 Segher Boessenkool <segher@kernel.crashing.org>
9445
9446 * config/rs6000/rs6000.md (*movcc_internal1): Use set_attr_alternative.
9447 (*call_indirect_nonlocal_sysv<mode>): Ditto.
9448 (*call_value_indirect_nonlocal_sysv<mode>): Ditto.
9449 (*sibcall_nonlocal_sysv<mode>): Ditto.
9450 (*sibcall_value_nonlocal_sysv<mode>): Ditto.
9451 (<bd>_<mode>): Ditto.
9452 (<bd>tf_<mode>): Ditto.
9453
9454 2018-09-25 Segher Boessenkool <segher@kernel.crashing.org>
9455
9456 * config/rs6000/altivec.md (*altivec_mov<mode>): Write the output
9457 control string as a list of templates instead of as C code.
9458 (*altivec_movti): Ditto.
9459 * config/rs6000/darwin.md (movdf_low_di): Ditto.
9460
9461 2018-09-25 Jim Wilson <jimw@sifive.com>
9462
9463 * config/riscv/riscv.c (riscv_split_symbol): Mark auipc label as weak
9464 when target symbol is weak.
9465
9466 2018-09-25 Bernd Edlinger <bernd.edlinger@hotmail.de>
9467
9468 PR c/87387
9469 * builtins.c (unterminated_array): Simplify.
9470 * expr.c (string_constant): Handle SSA_NAME. Add more exceptions
9471 where pointer arithmetic is safe.
9472
9473 2018-09-25 Segher Boessenkool <segher@kernel.crashing.org>
9474
9475 PR target/86987
9476 * config/rs6000/altivec.md (altivec_vspltb): Use
9477 const_0_to_15_operand instead of u5bit_cint_operand.
9478 (*altivec_vspltb_internal): Ditto.
9479 (altivec_vspltb_direct): Ditto.
9480 (altivec_vsplth): Use const_0_to_7_operand instead of
9481 u5bit_cint_operand.
9482 (*altivec_vsplth_internal): Ditto.
9483 (altivec_vsplth_direct): Ditto.
9484 (altivec_vspltw): Use const_0_to_3_operand instead of
9485 u5bit_cint_operand.
9486 (*altivec_vspltw_internal): Ditto.
9487 (altivec_vspltw_direct): Ditto.
9488 (altivec_vspltsf): Ditto.
9489 (*altivec_vspltsf_internal): Ditto.
9490 * config/rs6000/rs6000.c (rs6000_expand_binop_builtin): Handle the
9491 various splats with the proper size immediate. Reorder the various
9492 cases by ascending size of immediate, and put all such together.
9493
9494 2018-09-25 Richard Biener <rguenther@suse.de>
9495
9496 PR debug/83941
9497 * dwarf2out.c (add_AT_external_die_ref): Remove now redundant
9498 GC-ification.
9499 (maybe_create_die_with_external_ref): Do not create
9500 DW_TAG_imported_unit here.
9501 (add_abstract_origin_attribute): Handle external BLOCK refs.
9502 (dwarf2out_abstract_function): Simplify LTO case.
9503 (dwarf2out_early_finish): Create DW_TAG_imported_unit explicitely
9504 rather than using maybe_create_die_with_external_ref.
9505
9506 2018-09-25 Uros Bizjak <ubizjak@gmail.com>
9507
9508 PR target/71278
9509 * config/i386/i386.md (frndintxf2_mask_pm): Remove.
9510 (frndintxf2_mask_pm_i387): Ditto.
9511 (nearbyintxf2): Rewrite expander pattern to match rintxf2.
9512 Enable for !flag_trapping_math.
9513 (nearbyint<mode>2): Enable x87 modes for !flag_trapping_math.
9514 Enable SSE modes for TARGET_SSE4_1 and expand them with round insn.
9515 Change operand 1 predicate to nonimmediate_operand.
9516 (attr "i387_cw"): Remove mask_pm.
9517 * config/i386/i386.h (enum ix86_stack_slot): Remove SLOT_CW_MASK_PM.
9518 (enum ix86_entity): Remove I387_MASK_PM.
9519 * config/i386/i386.c (ix86_i387_mode_needed): Do not
9520 handle I387_MASK_PM.
9521 (ix86_mode_needed): Ditto.
9522 (ix86_mode_after): Ditto.
9523 (ix86_mode_entry): Ditto.
9524 (ix86_mode_exit): Ditto.
9525 (emit_i387_cw_initialization): Do not handle I387_CW_MASK_PM.
9526
9527 2018-09-25 Jakub Jelinek <jakub@redhat.com>
9528
9529 * vr-values.c (vr_values::vr_values): Initialize to_remove_edges and
9530 to_update_switch_stmts to vNULL instead of calling create on them
9531 immediately.
9532
9533 2018-09-25 Richard Biener <rguenther@suse.de>
9534
9535 PR tree-optimization/87402
9536 * tree-ssa-sccvn.c (SSA_VISITED): Remove unused function.
9537 (visit_phi): Re-instantiate handling of supposed to be VARYING
9538 but non-VARYING backedge value.
9539
9540 2018-09-25 Richard Biener <rguenther@suse.de>
9541
9542 PR debug/83941
9543 * dwarf2out.c (struct sym_off_pair): New.
9544 (external_die_map): New global.
9545 (lookup_decl_die): When in LTO create DIEs lazily from the
9546 external_die_map.
9547 (lookup_block_die): New function, create DIEs lazily in LTO.
9548 (equate_block_to_die): New function.
9549 (dwarf2out_die_ref_for_decl): During WPA get the association
9550 from the external DIE map.
9551 (dwarf2out_register_external_die): Record mapping into the
9552 external DIE map.
9553 (maybe_create_die_with_external_ref): New function split out from
9554 DIE generation part of old dwarf2out_register_external_die.
9555 (add_abstract_origin_attribute): Do not return the DIE. When
9556 in LTO reference externals directly.
9557 (dwarf2out_abstract_function): When in LTO ignore calls for
9558 decls with external DIEs (already present abstract instances).
9559 (gen_call_site_die): Adjust.
9560 (add_high_low_attributes): Likewise.
9561 (gen_lexical_block_die): Likewise.
9562 (gen_inlined_subroutine_die): Likewie.
9563 (gen_block_die): Likewise.
9564 (dwarf2out_inline_entry): Likewise.
9565 (dwarf2out_early_finish): In LTRANS phase create DW_TAG_imported_unit
9566 DIEs.
9567
9568 2018-09-25 Martin Liska <mliska@suse.cz>
9569
9570 * ipa-fnsummary.c (estimate_node_size_and_time): Scale by two
9571 integers and not by a float value.
9572
9573 2018-09-25 Martin Liska <mliska@suse.cz>
9574
9575 PR fortran/87394
9576 * dbgcnt.c (dbg_cnt_process_single_pair): Return false
9577 instead of NULL.
9578 * dumpfile.c (dump_enable_all): Remove extra parenthesis.
9579 * gcov-tool.c: Declare the function with ATTRIBUTE_NORETURN.
9580 * godump.c (go_format_type): Remove extra parenthesis.
9581
9582 2018-09-25 Martin Liska <mliska@suse.cz>
9583
9584 * alias.c (set_dest_equal_p): Remove unused function.
9585 * config/i386/i386.c (def_builtin_pure2): Likewise.
9586 * diagnostic-show-locus.c (class layout): Remove
9587 unused field.
9588 (layout::layout): Likewise here.
9589 * dump-context.h (class temp_dump_context): Likewise.
9590 * dwarf2out.c (add_AT_fde_ref): Remove unused function.
9591 (add_AT_loclistsptr): Likewise.
9592 (add_AT_offset): Likewise.
9593 (get_AT_hi_pc): Likewise.
9594 (is_comdat_die): Likewise.
9595 (type_is_enum): Likewise.
9596 (ceiling): Likewise.
9597 (add_AT_vms_delta): Likewise.
9598 (is_class_die): Likewise.
9599 * edit-context.c (class line_event): Remove unused field.
9600 * graphite-sese-to-poly.c (tree_int_to_gmp): Remove
9601 unused function.
9602 * ipa-cp.c (ipa_get_vr_lat): Likewise.
9603 * lra-constraints.c (ok_for_index_p_nonstrict): Likewise.
9604 (ok_for_base_p_nonstrict): Likewise.
9605 * tree-chrec.c (is_not_constant_evolution): Likewise.
9606 (chrec_fold_poly_cst): Likewise.
9607 * tree-if-conv.c (has_pred_critical_p): Likewise.
9608 * tree-ssa-coalesce.c (print_exprs): Likewise.
9609 * tree-ssa-pre.c (bitmap_set_contains_expr): Likewise.
9610 * tree-ssa-uninit.c (is_and_or_or_p): Likewise.
9611 * tree-vrp.c (value_ranges_intersect_p): Likewise.
9612 (value_range_nonnegative_p): Likewise.
9613
9614 2018-09-25 Martin Liska <mliska@suse.cz>
9615
9616 * config/powerpcspe/powerpcspe.c (rs6000_output_function_epilogue):
9617 Do not handle "GNU Pascal".
9618 * config/rs6000/rs6000.c (rs6000_output_function_epilogue):
9619 Likewise.
9620 * config/sparc/sparc.c (sparc_pass_by_reference): Remove Pascal
9621 from documentation. Likewise.
9622 * dbxout.c (dbxout_range_type): Likewise.
9623 * doc/cpp.texi: Likewise.
9624 * doc/extend.texi: Likewise.
9625 * doc/frontends.texi: Likewise.
9626 * doc/invoke.texi: Remove Pascal entry.
9627 * tree.def (CLEANUP_POINT_EXPR): Likewise.
9628 * doc/rtl.texi (MODE_FUNCTION): Remove not used entry.
9629
9630 2018-09-25 Martin Liska <mliska@suse.cz>
9631
9632 PR middle-end/86078
9633 * doc/invoke.texi: Document all parameters and remove default
9634 of the parameters.
9635
9636 2018-09-25 Ilya Leoshkevich <iii@linux.ibm.com>
9637
9638 PR bootstrap/87417
9639 * rtl.c (rtx_code_size): Take into account that EQ_ATTR_ALT
9640 contains HOST_WIDE_INTs when computing its size.
9641
9642 2018-09-24 Jim Wilson <jimw@sifive.com>
9643
9644 PR target/87391
9645 * config/riscv/riscv.h (STACK_BOUNDARY): Test riscv_abi == ABI_ILP32E
9646 not TARGET_RVE.
9647 (ABI_STACK_BOUNDARY, MAX_ARGS_IN_REGISTERS): Likewise.
9648
9649 2018-09-24 Andrew Pinski <apinski@marvell.com>
9650
9651 * config/aarch64/aarch64.c (aarch_macro_fusion_pair_p): Don't
9652 access prev before checking it for NULLness in the
9653 AARCH64_FUSE_CMP_BRANCH case.
9654
9655 2018-09-24 H.J. Lu <hongjiu.lu@intel.com>
9656
9657 PR target/82699
9658 * config/i386/i386.c (rest_of_insert_endbranch): Set
9659 endbr_queued_at_entrance to true and don't insert ENDBR if
9660 x86_function_profiler will be called.
9661 (x86_function_profiler): Insert ENDBR if endbr_queued_at_entrance
9662 is true.
9663 * config/i386/i386.h (machine_function): Add
9664 endbr_queued_at_entrance.
9665
9666 2018-09-24 Ilya Leoshkevich <iii@linux.ibm.com>
9667
9668 * genattrtab.c (mk_attr_alt): Use alternative_mask.
9669 (attr_rtx_1): Adjust caching to match the new EQ_ATTR_ALT field
9670 types.
9671 (check_attr_test): Use alternative_mask.
9672 (get_attr_value): Likewise.
9673 (compute_alternative_mask): Use alternative_mask and XWINT.
9674 (make_alternative_compare): Use alternative_mask.
9675 (attr_alt_subset_p): Use XWINT.
9676 (attr_alt_subset_of_compl_p): Likewise.
9677 (attr_alt_intersection): Use alternative_mask and XWINT.
9678 (attr_alt_union): Likewise.
9679 (attr_alt_complement): Use HOST_WIDE_INT and XWINT.
9680 (mk_attr_alt): Use alternative_mask and HOST_WIDE_INT.
9681 (simplify_test_exp): Use alternative_mask and XWINT.
9682 (write_test_expr): Use alternative_mask and XWINT, adjust bit
9683 number calculation to support 64 bits. Generate code that
9684 checks 64-bit masks.
9685 (main): Use alternative_mask.
9686 * rtl.def (EQ_ATTR_ALT): Change field types from ii to ww.
9687
9688 2018-09-24 Ilya Leoshkevich <iii@linux.ibm.com>
9689
9690 PR target/80080
9691 * config/s390/s390.c (s390_emit_epilogue): Do not use PARALLEL
9692 RETURN+USE when returning via %r14.
9693
9694 2018-09-24 Martin Liska <mliska@suse.cz>
9695
9696 * gcov.c (output_lines): Print colorization legend
9697 for both flag_use_colors and flag_use_hotness_colors.
9698 Reword the help.
9699
9700 2018-09-24 Martin Liska <mliska@suse.cz>
9701
9702 * coverage.c (get_coverage_counts): Use warning_at
9703 with current_function_decl location. Use %qD in warning
9704 message.
9705
9706 2018-09-24 Martin Liska <mliska@suse.cz>
9707
9708 * memory-block.h (memory_block_pool::release): Annotate with
9709 valgrind that the memory is not accessible.
9710
9711 2018-09-24 Martin Liska <mliska@suse.cz>
9712
9713 PR sanitizer/85774
9714 * asan.c: Make asan_handled_variables extern.
9715 * asan.h: Likewise.
9716 * cfgexpand.c (expand_stack_vars): Make sure
9717 a representative is unpoison if another
9718 variable in the partition is handled by
9719 use-after-scope sanitization.
9720
9721 2018-09-24 Richard Biener <rguenther@suse.de>
9722
9723 PR tree-optimization/63155
9724 * tree-ssa-propagate.c (add_ssa_edge): Avoid adding PHIs to
9725 the worklist when the edge of the respective argument isn't
9726 executable.
9727
9728 2018-09-23 Uros Bizjak <ubizjak@gmail.com>
9729
9730 * config/i386/i386.h (enum reg_class): Rename MASK_REGS to
9731 ALL_MASK_REGS and MASK_EVEX_REGS to MASK_REGS.
9732 (MASK_CLASS_P): Update for rename.
9733 (MAYBE_MASK_CLASS_P): Ditto.
9734 (REG_CLASS_NAMES): Update.
9735 (REG_CLASS_CONTENT): Update.
9736 * config/i386/i386.c (regclass_map): Update for MASK_REG
9737 and ALL_MASK_REGS rename.
9738 * config/i386/constraints.md (Yk): Update for rename.
9739 (k): Ditto.
9740
9741 2018-09-23 Uros Bizjak <ubizjak@gmail.com>
9742
9743 * config/i386/i386.h (enum reg_class): Remove
9744 EVEX_SSE_REGS and MOD4_SSE_REGS.
9745 (REG_CLASS_NAMES): Update.
9746 (REG_CLASS_CONTENT): Update.
9747 * config/i386/i386.c (regclass_map): Declare AVX-512 SSE
9748 registers as ALL_SSE_REGS.
9749 (ix86_additional_allocno_class_p): Remove.
9750 (TARGET_ADDITIONAL_ALLOCNO_CLASS_P): Remove.
9751 (ix86_register_priority): Lower priority of EVEX SSE registers.
9752 Use IN_RANGE macro where appropriate.
9753 (ix86_hard_regno_mode_ok): Merge AVX-5124FMAPS and
9754 AVX-5124VNNIW checks.
9755 (ix86_modes_tieable_p): Tie 512-bit SSE modes.
9756 * config/i386/sse.md (avx5124fmaddps_4fmaddps)
9757 (avx5124fmaddps_4fmaddps_mask, avx5124fmaddps_4fmaddps_maskz)
9758 (avx5124fmaddps_4fmaddss, avx5124fmaddps_4fmaddss_mask)
9759 (avx5124fmaddps_4fmaddss_maskz, avx5124fmaddps_4fnmaddps)
9760 (avx5124fmaddps_4fnmaddps_mask, avx5124fmaddps_4fnmaddps_maskz)
9761 (avx5124fmaddps_4fnmaddss, avx5124fmaddps_4fnmaddss_mask)
9762 (avx5124fmaddps_4fnmaddss_maskz, avx5124vnniw_vp4dpwssd)
9763 (avx5124vnniw_vp4dpwssd_mask, avx5124vnniw_vp4dpwssd_maskz)
9764 (avx5124vnniw_vp4dpwssds, avx5124vnniw_vp4dpwssds_mask)
9765 (avx5124vnniw_vp4dpwssds_maskz): Use "v" instead of "Yh" constraint.
9766 * config/i386/constraints.md (Yh): Remove.
9767
9768 2018-09-23 Uros Bizjak <ubizjak@gmail.com>
9769
9770 * config/i386/i386.c (regclass_map): Declare integer REX registers
9771 as GENERAL_REGS.
9772
9773 2018-09-23 Gerald Pfeifer <gerald@pfeifer.com>
9774
9775 * doc/service.texi (Service): Switch the fsf.org link to https.
9776
9777 2018-09-22 Chung-Ju Wu <jasonwucj@gmail.com>
9778
9779 PR target/86798
9780 * config/nds32/nds32.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
9781 Define to speculation_safe_value_not_needed.
9782
9783 2018-09-21 Florian Weimer <fweimer@redhat.com>
9784
9785 PR middle-end/81035
9786 * doc/extend.texi (Common Function Attributes): Mention that
9787 noreturn suppresses tail call optimization.
9788
9789 2018-09-21 Jeff Law <law@redhat.com>
9790
9791 * gimple-ssa-evrp.c (evrp_dom_walker::cleanup): Call
9792 vr_values::cleanup_edges_and_switches.
9793 * tree-vrp.c (to_remove_edges, to_update_switch_stmts): Moved into
9794 vr_values class.
9795 (identify_jump_threads): Remove EDGE_IGNORE handling.
9796 (execute_vrp): Move handling of to_remove_edges and
9797 to_update_switch_stmts into vr_values class member functions.
9798 * tree-vrp.h (switch_update, to_remove_edges): Remove declarations.
9799 (to_update_switch_stmts): Likewise.
9800 * vr-values.c: Include cfghooks.h.
9801 (vr_values::vr_values): Initialize to_remove_edges and
9802 to_update_switch_stmts.
9803 (vr_values::~vr_values): Verify to_remove_edges and
9804 to_update_switch_stmts are empty.
9805 (vr_values::simplify_switch_using_ranges): Set EDGE_IGNORE as needed.
9806 (vr_values::cleanup_edges_and_switches): New member function.
9807 * vr-values.h (vr_values): Add cleanup_edges_and_switches member
9808 function. Add new data members.
9809
9810 2018-09-21 David Malcolm <dmalcolm@redhat.com>
9811
9812 PR tree-optimization/87309
9813 * dumpfile.c (dump_context::begin_scope): Filter the dump_loc
9814 calls with pflags and alt_flags.
9815 (selftest::test_capture_of_dump_calls): Add test of interaction of
9816 MSG_OPTIMIZED_LOCATIONS with AUTO_DUMP_SCOPE.
9817
9818 2018-09-21 Olivier Hainque <hainque@adacore.com>
9819
9820 * config.gcc: Factorize and comment inclusion of vxworks-dummy.h.
9821
9822 2018-09-21 Olivier Hainque <hainque@adacore.com>
9823
9824 * config/vxworks.h (CLEAR_INSN_CACHE): #define to 1.
9825
9826 2018-09-21 Olivier Hainque <hainque@adacore.com>
9827
9828 * config/vxworks.h (VXWORKS_LIBGCC_SPEC): Remove -lc_internal.
9829 Merge block comment with the one ahead of VXWORKS_LIBS_RTP. Then:
9830 (VXWORKS_LIBS_RTP): Minor reordering.
9831
9832 2018-09-21 Olivier Hainque <hainque@adacore.com>
9833
9834 * config/vxworks.h (STARTFILE_PREFIX_SPEC): Define.
9835 (VXWORKS_LIBS_DIR_RTP): Remove definition and use.
9836
9837 2018-09-21 Olivier Hainque <hainque@adacore.com>
9838
9839 * config/vxworks.h (SIZE_TYPE): Account for TARGET_VXWORKS64.
9840 (PTRDIFF_TYPE): Likewise.
9841
9842 2018-09-21 Olivier Hainque <hainque@adacore.com>
9843
9844 * config.gcc: Enforce def of TARGET_VXWORKS64 to 1 from
9845 triplet, similar to support for VxWorks7.
9846 * config/vxworks-dummy.h: Provide a default definition
9847 of TARGET_VXWORKS64 to 0.
9848
9849 2018-09-21 Olivier Hainque <hainque@adacore.com>
9850
9851 * config/vxworks.h (TARGET_VXWORKS7): Move default definition ...
9852 * config/vxworks-dummy.h: here.
9853
9854 2018-09-21 Olivier Hainque <hainque@adacore.com>
9855
9856 * config.gcc: Prepend vxworks-dummy.h to tm_file for powerpc*
9857
9858 2018-09-21 Shaokun Zhang <zhangshaokun@hisilicon.com>
9859 Bo Zhou <zbo.zhou@hisilicon.com>
9860
9861 * config/aarch64/aarch64-cores.def (tsv110): New CPU.
9862 * config/aarch64/aarch64-tune.md: Regenerated.
9863 * doc/invoke.texi (AArch64 Options/-mtune): Add "tsv110".
9864 * config/aarch64/aarch64.c (tsv110_tunings): New tuning table.
9865 * config/aarch64/aarch64-cost-tables.h: Add "tsv110" extra costs.
9866
9867 2018-09-21 Andrew Stubbs <ams@codesourcery.com>
9868 Julian Brown <julian@codesourcery.com>
9869
9870 * builtins.c (get_builtin_sync_mem): Handle address spaces.
9871
9872 2018-09-21 Eric Botcazou <ebotcazou@adacore.com>
9873
9874 * config/rs6000/rs6000.c (rs6000_function_ok_for_sibcall): Return false
9875 if the call takes a static chain.
9876
9877 2018-09-21 Martin Liska <mliska@suse.cz>
9878
9879 * auto-profile.c (autofdo_source_profile::read): Do not
9880 set sum_all.
9881 (read_profile): Do not add working sets.
9882 (read_autofdo_file): Remove sum_all.
9883 (afdo_callsite_hot_enough_for_early_inline): Remove const
9884 qualifier.
9885 * coverage.c (struct counts_entry): Remove gcov_summary.
9886 (read_counts_file): Read new GCOV_TAG_OBJECT_SUMMARY,
9887 do not support GCOV_TAG_PROGRAM_SUMMARY.
9888 (get_coverage_counts): Remove summary and expected
9889 arguments.
9890 * coverage.h (get_coverage_counts): Likewise.
9891 * doc/gcov-dump.texi: Remove -w option.
9892 * gcov-dump.c (dump_working_sets): Remove.
9893 (main): Do not support '-w' option.
9894 (print_usage): Likewise.
9895 (tag_summary): Likewise.
9896 * gcov-io.c (gcov_write_summary): Do not dump
9897 histogram.
9898 (gcov_read_summary): Likewise.
9899 (gcov_histo_index): Remove.
9900 (gcov_histogram_merge): Likewise.
9901 (compute_working_sets): Likewise.
9902 * gcov-io.h (GCOV_TAG_OBJECT_SUMMARY): Mark
9903 it not obsolete.
9904 (GCOV_TAG_PROGRAM_SUMMARY): Mark it obsolete.
9905 (GCOV_TAG_SUMMARY_LENGTH): Adjust.
9906 (GCOV_HISTOGRAM_SIZE): Remove.
9907 (GCOV_HISTOGRAM_BITVECTOR_SIZE): Likewise.
9908 (struct gcov_summary): Simplify rapidly just
9909 to runs and sum_max fields.
9910 (gcov_histo_index): Remove.
9911 (NUM_GCOV_WORKING_SETS): Likewise.
9912 (compute_working_sets): Likewise.
9913 * gcov-tool.c (print_overlap_usage_message): Remove
9914 trailing empty line.
9915 * gcov.c (read_count_file): Read GCOV_TAG_OBJECT_SUMMARY.
9916 (output_lines): Remove program related line.
9917 * ipa-profile.c (ipa_profile): Do not consider GCOV histogram.
9918 * lto-cgraph.c (output_profile_summary): Do not stream GCOV
9919 histogram.
9920 (input_profile_summary): Do not read it.
9921 (merge_profile_summaries): And do not merge it.
9922 (input_symtab): Do not call removed function.
9923 * modulo-sched.c (sms_schedule): Do not print sum_max.
9924 * params.def (HOT_BB_COUNT_FRACTION): Reincarnate param that was
9925 removed when histogram method was invented.
9926 (HOT_BB_COUNT_WS_PERMILLE): Mention that it's used only in LTO
9927 mode.
9928 * postreload-gcse.c (eliminate_partially_redundant_load): Fix
9929 GCOV coding style.
9930 * predict.c (get_hot_bb_threshold): Use HOT_BB_COUNT_FRACTION
9931 and dump selected value.
9932 * profile.c (add_working_set): Remove.
9933 (get_working_sets): Likewise.
9934 (find_working_set): Likewise.
9935 (get_exec_counts): Do not work with working sets.
9936 (read_profile_edge_counts): Do not inform as sum_max is removed.
9937 (compute_branch_probabilities): Likewise.
9938 (compute_value_histograms): Remove argument for call of
9939 get_coverage_counts.
9940 * profile.h: Do not make gcov_summary const.
9941
9942 2018-09-21 Monk Chiang <sh.chiang04@gmail.com>
9943
9944 * config.gcc (nds32*-*-*): Set TARGET_DEFAULT_TLSDESC_TRAMPOLINE=0.
9945
9946 2018-09-21 Eric Botcazou <ebotcazou@adacore.com>
9947
9948 PR tree-optimization/86990
9949 * gimple-ssa-store-merging.c (imm_store_chain_info:coalesce_immediate):
9950 Check that the entire merged store group is made of constants only for
9951 overlapping stores.
9952
9953 2018-09-20 Allan Sandfeld Jensen <allan.jensen@qt.io>
9954
9955 * gcc.c (LINK_COMMAND_SPEC): Handle -r like -nostdlib.
9956 (VTABLE_VERIFICATION_SPEC): Likewise.
9957 (SANITIZER_EARLY_SPEC): Likewise.
9958 (SANITIZER_SPEC): Likewise.
9959 * config/darwin.h (LINK_COMMAND_SPEC): Likewise.
9960 * doc/invoke.texi (Link Options): Document -r.
9961
9962 2018-09-20 Richard Biener <rguenther@suse.de>
9963
9964 PR middle-end/87054
9965 * gimplify.c (gimplify_expr): Retain alignment of
9966 addressable lvalue in dereference.
9967
9968 2018-09-20 Alexandre Oliva <aoliva@redhat.com>
9969
9970 PR bootstrap/87013
9971 * configure.ac: Check for .loc is_stmt support.
9972 * configure, config.in: Rebuilt.
9973 * dwarf2out.c (dwarf2out_source_line): Skip is_stmt
9974 if not supported.
9975
9976 2018-09-20 Segher Boessenkool <segher@kernel.crashing.org>
9977
9978 * config/rs6000/rs6000.opt (misel=no, misel=yes): Delete.
9979 * doc/invoke.texi (RS/6000 and PowerPC Options): Delete -misel=yes and
9980 -misel=no.
9981
9982 2018-09-20 Segher Boessenkool <segher@kernel.crashing.org>
9983
9984 * config/rs6000/rs6000-opts.h (enum rs6000_vector): Delete
9985 VECTOR_OTHER.
9986 * config/rs6000/rs6000.c (rs6000_debug_vector_unit): Delete
9987 case VECTOR_OTHER.
9988
9989 2018-09-20 Marek Polacek <polacek@redhat.com>
9990
9991 * doc/invoke.texi: Add -Wno-init-list-lifetime to C++ Language Options.
9992
9993 2018-09-20 Richard Sandiford <richard.sandiford@arm.com>
9994
9995 PR tree-optimization/87288
9996 * tree-vect-loop.c (vect_analyze_loop_2): Take PEELING_FOR_GAPS
9997 into account when determining PEELING_FOR_NITERS.
9998
9999 2018-09-20 Richard Sandiford <richard.sandiford@arm.com>
10000
10001 PR tree-optimization/86877
10002 * tree-vect-loop.c (vect_analyze_loop_2): Call
10003 vect_verify_datarefs_alignment.
10004
10005 2018-09-19 Marek Polacek <polacek@redhat.com>
10006
10007 * doc/invoke.texi: Document -Wclass-conversion.
10008
10009 2018-09-19 John David Anglin <danglin@gcc.gnu.org>
10010
10011 * config/pa/pa.c (pa_adjust_priority): Delete.
10012 (TARGET_SCHED_ADJUST_PRIORITY): Delete define.
10013
10014 * config/pa/pa.md (atomic_storeqi): Restore deleted expander.
10015 (atomic_storehi): Likewise.
10016 (atomic_storesi): Likewise.
10017 (atomic_loaddi): Restore compare and swap exchange loop code.
10018
10019 2018-09-19 Segher Boessenkool <segher@kernel.crashing.org>
10020
10021 PR rtl-optimization/86902
10022 * combine.c (try_combine): When changing the CC mode used, don't change
10023 an unrelated mode in other_insn to that new CC mode.
10024
10025 2018-09-19 David Malcolm <dmalcolm@redhat.com>
10026
10027 * tree-data-ref.c (runtime_alias_check_p): Use formatted printing
10028 with %T in place of calls to dump_generic_expr.
10029 (prune_runtime_alias_test_list): Likewise.
10030 (create_runtime_alias_checks): Likewise.
10031 * tree-vect-data-refs.c (vect_check_nonzero_value): Likewise.
10032 (vect_analyze_data_ref_dependence): Likewise.
10033 (vect_slp_analyze_data_ref_dependence): Likewise.
10034 (vect_record_base_alignment): Likewise. Use %G in place of call
10035 to dump_gimple_stmt.
10036 (vect_compute_data_ref_alignment): Likewise.
10037 (verify_data_ref_alignment): Likewise.
10038 (vect_find_same_alignment_drs): Likewise.
10039 (vect_analyze_group_access_1): Likewise.
10040 (vect_analyze_data_ref_accesses): Likewise.
10041 (dependence_distance_ge_vf): Likewise.
10042 (dump_lower_bound): Likewise.
10043 (vect_prune_runtime_alias_test_list): Likewise.
10044 (vect_find_stmt_data_reference): Likewise.
10045 (vect_analyze_data_refs): Likewise.
10046 (vect_create_addr_base_for_vector_ref): Likewise.
10047 (vect_create_data_ref_ptr): Likewise.
10048 * tree-vect-loop-manip.c (vect_set_loop_condition): Likewise.
10049 (vect_can_advance_ivs_p): Likewise.
10050 (vect_update_ivs_after_vectorizer): Likewise.
10051 (vect_gen_prolog_loop_niters): Likewise.
10052 (vect_prepare_for_masked_peels): Likewise.
10053 * tree-vect-loop.c (vect_determine_vf_for_stmt): Likewise.
10054 (vect_determine_vectorization_factor): Likewise.
10055 (vect_is_simple_iv_evolution): Likewise.
10056 (vect_analyze_scalar_cycles_1): Likewise.
10057 (vect_analyze_loop_operations): Likewise.
10058 (report_vect_op): Likewise.
10059 (vect_is_slp_reduction): Likewise.
10060 (check_reduction_path): Likewise.
10061 (vect_is_simple_reduction): Likewise.
10062 (vect_create_epilog_for_reduction): Likewise.
10063 (vect_finalize_reduction:): Likewise.
10064 (vectorizable_induction): Likewise.
10065 (vect_transform_loop_stmt): Likewise.
10066 (vect_transform_loop): Likewise.
10067 (optimize_mask_stores): Likewise.
10068 * tree-vect-patterns.c (vect_pattern_detected): Likewise.
10069 (vect_split_statement): Likewise.
10070 (vect_recog_over_widening_pattern): Likewise.
10071 (vect_recog_average_pattern): Likewise.
10072 (vect_determine_min_output_precision_1): Likewise.
10073 (vect_determine_precisions_from_range): Likewise.
10074 (vect_determine_precisions_from_users): Likewise.
10075 (vect_mark_pattern_stmts): Likewise.
10076 (vect_pattern_recog_1): Likewise.
10077 * tree-vect-slp.c (vect_get_and_check_slp_defs): Likewise.
10078 (vect_record_max_nunits): Likewise.
10079 (vect_build_slp_tree_1): Likewise.
10080 (vect_build_slp_tree_2): Likewise.
10081 (vect_print_slp_tree): Likewise.
10082 (vect_analyze_slp_instance): Likewise.
10083 (vect_detect_hybrid_slp_stmts): Likewise.
10084 (vect_detect_hybrid_slp_1): Likewise.
10085 (vect_slp_analyze_operations): Likewise.
10086 (vect_slp_analyze_bb_1): Likewise.
10087 (vect_transform_slp_perm_load): Likewise.
10088 (vect_schedule_slp_instance): Likewise.
10089 * tree-vect-stmts.c (vect_mark_relevant): Likewise.
10090 (vect_mark_stmts_to_be_vectorized): Likewise.
10091 (vect_init_vector_1): Likewise.
10092 (vect_get_vec_def_for_operand): Likewise.
10093 (vect_finish_stmt_generation_1): Likewise.
10094 (vect_check_load_store_mask): Likewise.
10095 (vectorizable_call): Likewise.
10096 (vectorizable_conversion): Likewise.
10097 (vectorizable_operation): Likewise.
10098 (vectorizable_load): Likewise.
10099 (vect_analyze_stmt): Likewise.
10100 (vect_is_simple_use): Likewise.
10101 (vect_get_vector_types_for_stmt): Likewise.
10102 (vect_get_mask_type_for_stmt): Likewise.
10103 * tree-vectorizer.c (increase_alignment): Likewise.
10104
10105 2018-09-19 Andrew Stubbs <ams@codesourcery.com>
10106
10107 * doc/rtl.texi: Adjust vec_select description.
10108 * simplify-rtx.c (simplify_binary_operation_1): Allow VEC_SELECT to use
10109 non-constant selectors.
10110
10111 2018-09-19 Matthew Malcomson <matthew.malcomson@arm.com>
10112
10113 * config/aarch64/aarch64-protos.h
10114 (aarch64_offset_9bit_signed_unscaled_p): New declaration.
10115 * config/aarch64/aarch64.md (arches): New "rcpc8_4" attribute value.
10116 (arch_enabled): Add check for "rcpc8_4" attribute value of "arch".
10117 * config/aarch64/aarch64.h (AARCH64_FL_RCPC8_4): New bitfield.
10118 (AARCH64_FL_FOR_ARCH8_4): Include AARCH64_FL_RCPC8_4.
10119 (AARCH64_FL_PROFILE): Move index so flags are ordered.
10120 (AARCH64_ISA_RCPC8_4): New flag.
10121 * config/aarch64/aarch64.c (offset_9bit_signed_unscaled_p): Renamed
10122 to aarch64_offset_9bit_signed_unscaled_p.
10123 * config/aarch64/atomics.md (atomic_store<mode>): Allow offset
10124 and use stlur.
10125 * config/aarch64/constraints.md (Ust): New constraint.
10126 * config/aarch64/predicates.md.
10127 (aarch64_9bit_offset_memory_operand): New predicate.
10128 (aarch64_rcpc_memory_operand): New predicate.
10129
10130 2018-09-19 Eric Botcazou <ebotcazou@adacore.com>
10131
10132 PR rtl-optimization/87361
10133 * rtlanal.c (nonzero_bits1): Revert accidental change.
10134
10135 2018-09-19 Richard Biener <rguenther@suse.de>
10136
10137 PR tree-optimization/87349
10138 PR tree-optimization/87342
10139 * tree-ssa-sccvn.c (do_rpo_vn): Iterate max_rpo computation.
10140
10141 2018-09-18 Marek Polacek <polacek@redhat.com>
10142
10143 P1064R0 - Allowing Virtual Function Calls in Constant Expressions
10144 * gimple-fold.c (gimple_get_virt_method_for_vtable): Adjust assert.
10145
10146 2018-09-18 Segher Boessenkool <segher@kernel.crashing.org>
10147
10148 * config/rs6000/rs6000.md: Remove old "Cygnus sibcall" comment.
10149
10150 2018-09-18 Segher Boessenkool <segher@kernel.crashing.org>
10151
10152 PR rtl-optimization/86882
10153 * rtlanal.c (reg_overlap_mentioned_p): Handle CLOBBER.
10154
10155 2018-09-18 Uros Bizjak <ubizjak@gmail.com>
10156
10157 * config/i386/i386.md (*<code>extend<mode>xf2): Macroize insn from
10158 *<code>extendsfxf2 and *<code>extenddfxf2 using MODEF mode iterator.
10159
10160 2018-09-18 Jonathan Wakely <jwakely@redhat.com>
10161
10162 PR other/87353
10163 * doc/invoke.texi (Link Options): Fix formatting and grammar.
10164
10165 2018-09-18 Richard Biener <rguenther@suse.de>
10166
10167 PR middle-end/63155
10168 * tree-ssa-coalesce.c (tree_int_map_hasher): Remove.
10169 (compute_samebase_partition_bases): Likewise.
10170 (coalesce_ssa_name): Always use compute_optimized_partition_bases.
10171 (gimple_can_coalesce_p): Simplify.
10172
10173 2018-09-18 Hans-Peter Nilsson <hp@bitrange.com>
10174
10175 Handle a library implementation of ffs calling __builtin_ffs.
10176 * config/mmix/mmix.c (TARGET_INIT_LIBFUNCS): Override with...
10177 (mmix_init_libfuncs): New function: make __builtin_ffs expand
10178 to __ffsdi2.
10179
10180 2018-09-17 David Malcolm <dmalcolm@redhat.com>
10181
10182 * diagnostic-show-locus.c (class layout_range): Add field
10183 "m_original_idx".
10184 (layout_range::layout_range): Add "original_idx" param and use it
10185 to initialize new field.
10186 (make_range): Use 0 for original_idx.
10187 (layout::layout): Pass in index to calls to
10188 maybe_add_location_range.
10189 (layout::maybe_add_location_range): Add param "original_idx" and
10190 pass it on to layout_range.
10191 (layout::print_any_labels): Pass on range->m_original_idx to
10192 get_text call.
10193 (gcc_rich_location::add_location_if_nearby): Use 0 for
10194 original_idx.
10195 * gcc-rich-location.h (text_range_label::get_text): Update for new
10196 param.
10197 (range_label_for_type_mismatch::get_text): Likewise.
10198
10199 2018-09-17 Uros Bizjak <ubizjak@gmail.com>
10200
10201 * config/i386/i386.c (ix86_emit_i387_log1p): Emit fldln2 earlier.
10202
10203 2018-09-17 David Malcolm <dmalcolm@redhat.com>
10204
10205 * gimple-ssa-sprintf.c (fmtwarn): Update for introduction of
10206 format_string_diagnostic_t.
10207 (fmtwarn_n): Likewise.
10208 * substring-locations.c
10209 (format_string_diagnostic_t::format_string_diagnostic_t) New ctor.
10210 (format_warning_n_va): Convert to...
10211 (format_string_diagnostic_t::emit_warning_n_va): ...this.
10212 (format_warning_va): Convert to...
10213 (format_string_diagnostic_t::emit_warning_va): ...this.
10214 (format_warning_at_substring): Convert to...
10215 (format_string_diagnostic_t::emit_warning): ...this.
10216 (format_warning_at_substring_n): Convert to...
10217 (format_string_diagnostic_t::emit_warning_n): ...this.
10218 * substring-locations.h (class format_string_diagnostic_t): New
10219 class.
10220 (format_warning_va): Convert to
10221 format_string_diagnostic_t::emit_warning_va.
10222 (format_warning_n_va): Convert to
10223 format_string_diagnostic_t::emit_warning_n_va.
10224 (format_warning_at_substring): Convert to
10225 format_string_diagnostic_t::emit_warning.
10226 (format_warning_at_substring_n): Convert to
10227 format_string_diagnostic_t::emit_warning_n.
10228
10229 2018-09-17 Cesar Philippidis <cesar@codesourcery.com>
10230 Bernd Schmidt <bernds_cb1@t-online.de>
10231
10232 * config/nvptx/nvptx.md (atomic_fetch_<logic><mode>): Enable with
10233 SImode args.
10234
10235 2018-09-17 Uros Bizjak <ubizjak@gmail.com>
10236
10237 * config/i386/i386.md (truncxf<mode>2_i387_noop_unspec): Change
10238 operand 0 predicate to nonimmediate operand.
10239 (rint<mode>2_frndint): Remove insn pattern.
10240 (rint<mode>2): Change operand 1 predicate to general_operand.
10241 Extend operand 1 to XFmode and generate rintxf2 insn.
10242 (frndintxf2_<rounding>): Rename from frndint<mode>2_<rounding>.
10243 Do not use X87MODEF mode macro.
10244 (frndintxf2_<rounding>_i387): Rename from
10245 frndint<mode>2_<rounding>_i387. Do not use X87MODEF mode macro.
10246 (<rounding_insn><mode>2): For non-SSE modes, extend operand 1
10247 to XFmode and generate significandxf3 insn.
10248
10249 2018-09-17 Richard Biener <rguenther@suse.de>
10250
10251 PR tree-optimization/87328
10252 * tree-ssa-sccvn.c (process_bb): Remove assertion about not
10253 visiting unexecutable backedges when not iterating.
10254 (do_rpo_vn): Mark all edges not executable even when not
10255 iterating.
10256
10257 2018-09-17 Martin Jambor <mjambor@suse.cz>
10258
10259 PR c/63886
10260 * doc/invoke.texi (Warning Options): Likewise.
10261
10262 2018-09-17 Richard Biener <rguenther@suse.de>
10263
10264 PR tree-optimization/87301
10265 * tree-ssa-sccvn.c (eliminate_dom_walker::eliminate_cleanup): Properly
10266 clean EH info from leftover copy assignments.
10267
10268 2018-09-17 Martin Liska <mliska@suse.cz>
10269
10270 PR gcov-profile/85871
10271 * gcov.c (output_intermediate_file): Fix out of bounds
10272 access.
10273
10274 2018-09-17 Vineet Gupta <vgupta@synopsys.com>
10275
10276 * config/arc/arc.c: Object attributes for core4 not reflected
10277 correctly.
10278 * config/arc/arc.h: Don't restrict DBNZ to core3 (core4 includes
10279 core3).
10280
10281 2018-09-17 Alexey Brodkin <abrodkin@synopsys.com>
10282
10283 * config/arc/linux.h (LINK_EH_SPEC): Add missing space.
10284
10285 2018-09-17 Martin Liska <mliska@suse.cz>
10286
10287 * doc/gcov.texi: Document new option --use-hotness-colors.
10288 * gcov.c (struct source_info): Declare new field.
10289 (source_info::source_info): Set default for maximum_count.
10290 (print_usage): Add new -q option.
10291 (process_args): Process it.
10292 (accumulate_line_info): Save src->maximum_count.
10293 (output_line_beginning): Make color line number if
10294 flag_use_hotness_colors is set.
10295 (output_line_details): Pass default argument value.
10296 (output_lines): Pass src->maximum_count.
10297
10298 2018-09-17 Martin Liska <mliska@suse.cz>
10299
10300 * common/config/i386/i386-common.c (ix86_get_valid_option_values):
10301 Use processor_names table.
10302 * config/i386/i386.c (ix86_default_align): Use
10303 processor_cost_table for alignment values.
10304 (ix86_option_override_internal): Use processor_names.
10305 (ix86_function_specific_print): Likewise.
10306 * config/i386/i386.h (struct processor_costs):
10307 Add alignment values.
10308 (struct ptt): Remove and replace with const char *.
10309 * config/i386/x86-tune-costs.h (struct processor_costs):
10310 Declare default alignments for all costs.
10311
10312 2018-09-17 Aldy Hernandez <aldyh@redhat.com>
10313
10314 * tree-vrp.c (extract_range_from_unary_expr): Do not special case
10315 symbolics or VR_VARYING ranges for ABS_EXPR.
10316 * wide-int-range.cc (wide_int_range_abs): Return positive numbers
10317 when range will wrap.
10318
10319 2018-09-15 Eric Botcazou <ebotcazou@adacore.com>
10320
10321 PR middle-end/86864
10322 * cfgexpand.c (expand_gimple_basic_block): Be prepared for a BARRIER
10323 before and after a JUMP_TABLE_DATA.
10324
10325 2018-09-14 John David Anglin <danglin@gcc.gnu.org>
10326
10327 PR middle-end/87188
10328 * dojump.c (do_compare_and_jump): Canonicalize function pointers
10329 when one operand is a function pointer. Use POINTER_TYPE_P and
10330 FUNC_OR_METHOD_TYPE_P.
10331 * expr.c (do_store_flag): Use POINTER_TYPE_P and FUNC_OR_METHOD_TYPE_P.
10332 * fold-const.c (build_range_check): Likewise.
10333 * match.pd (simple_comparison): Likewise.
10334
10335 2018-09-14 David Malcolm <dmalcolm@redhat.com>
10336
10337 PR c/82967
10338 * spellcheck.c (get_edit_distance_cutoff): New function.
10339 (selftest::test_edit_distance_unit_test_oneway): Rename to...
10340 (selftest::test_get_edit_distance_one_way): ...this.
10341 (selftest::test_get_edit_distance_unit): Rename to...
10342 (selftest::test_get_edit_distance_both_ways): ...this.
10343 (selftest::test_edit_distances): Move tests to this new function,
10344 and test some more pairs of strings. Update for above renaming.
10345 (selftest::get_old_cutoff): New function.
10346 (selftest::test_get_edit_distance_cutoff): New function.
10347 (selftest::assert_suggested_for): New function.
10348 (ASSERT_SUGGESTED_FOR): New macro.
10349 (selftest::assert_not_suggested_for): New function.
10350 (ASSERT_NOT_SUGGESTED_FOR): New macro.
10351 (selftest::test_suggestions): New function.
10352 (selftest::spellcheck_c_tests): Move test_get_edit_distance_unit
10353 tests to selftest::test_edit_distances and call it. Add calls to
10354 selftest::test_get_edit_distance_cutoff and
10355 selftest::test_suggestions.
10356 * spellcheck.h (get_edit_distance_cutoff): New function declaration.
10357 (best_match::consider): Replace hard-coded cutoff calculation with
10358 a call to...
10359 (best_match::get_cutoff): New declaration.
10360 (best_match::get_best_meaningful_candidate): Likewise.
10361
10362 2018-09-14 Bernd Edlinger <bernd.edlinger@hotmail.de>
10363
10364 * builtins.c (fold_builtin_strlen): Remove TODO comment.
10365
10366 2018-09-14 Bernd Edlinger <bernd.edlinger@hotmail.de>
10367
10368 revert:
10369 2018-07-30 Bernd Edlinger <bernd.edlinger@hotmail.de>
10370
10371 * tree-ssa-forwprop.c (simplify_builtin_call): Don't create a not NUL
10372 terminated string literal.
10373
10374 2018-09-14 Martin Sebor <msebor@redhat.com>
10375
10376 * builtins.c (unterminated_array): Handle ARRAY_REF.
10377 (expand_builtin_stpcpy_1): Detect unterminated char arrays.
10378 * builtins.h (unterminated_array): Declare extern.
10379 * gimple-fold.c (gimple_fold_builtin_stpcpy): Detect unterminated
10380 arrays.
10381 (gimple_fold_builtin_sprintf): Propagate NO_WARNING to transformed
10382 calls.
10383
10384 2018-09-14 Martin Sebor <msebor@redhat.com>
10385 Jeff Law <law@redhat.com>
10386
10387 * builtins.c (unterminated_array): New.
10388 (expand_builtin_strcpy): Adjust.
10389 (expand_builtin_strcpy_args): Detect unterminated arrays.
10390 * gimple-fold.c (get_maxval_strlen): Add argument. Detect
10391 unterminated arrays.
10392 * gimple-fold.h (get_maxval_strlen): Add argument.
10393 (gimple_fold_builtin_strcpy): Detec unterminated arrays.
10394
10395 * gimple-fold.c (get_range_strlen): Add argument.
10396 (get_maxval_strlen): Adjust.
10397 * gimple-fold.h (get_range_strlen): Add argument.
10398
10399 2018-09-14 Wei Xiao <wei3.xiao@intel.com>
10400
10401 * config/i386/movdirintrin.h: Fix copyright year.
10402
10403 2018-09-14 Uros Bizjak <ubizjak@gmail.com>
10404
10405 * reg-stack.c: Include regs.h.
10406 (replace_reg): Assert that mode is MODE_FLOAT or MODE_COMPLEX_FLOAT.
10407 (emit_pop_insn): Default pop insn mode to the reg_raw_mode of
10408 FIRST_STACK_REG, not DFmode.
10409 (emit_swap_insn): Default swap insn mode to the reg_raw_mode of
10410 FIRST_STACK_REG, not XFmode. Explicitly construct swap RTX.
10411 (change stack): Default register mode to the reg_raw_mode of
10412 FIRST_STACK_REG, not DFmode.
10413 * config/i386/i386.md (*swap<mode>): Remove insn pattern.
10414 (*swapxf): Rename from swapxf.
10415
10416 2018-09-14 Carl Love <cel@us.ibm.com>
10417
10418 * config/rs6000/emmintrin.h: Add _MM_SHUFFLE2.
10419 * config/rs6000/xmmintrin.h: Add _MM_SHUFFLE.
10420
10421 2018-09-14 Segher Boessenkool <segher@kernel.crashing.org>
10422
10423 PR target/87224
10424 * config/rs6000/rs6000.md (*mov<mode>_hardfloat64): Add Z to the Y
10425 alternatives.
10426
10427 2018-09-14 Sam Tebbs <sam.tebbs@arm.com>
10428
10429 PR target/85628
10430 * config/aarch64/aarch64.md (*aarch64_bfxilsi_uxtw): Define.
10431
10432 2018-09-14 Jason Merrill <jason@redhat.com>
10433
10434 Fix --enable-gather-detailed-mem-stats.
10435 * hash-table.c (hash_table_usage): Change from variable to function.
10436 * hash-table.h: Adjust.
10437 * Makefile.in: Add missing dependencies on hash-table.h.
10438
10439 2018-09-14 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
10440
10441 PR tree-optimization/87259
10442 PR lto/87283
10443 (pass_cse_reciprocals::execute): Run optimize_recip_sqrt after
10444 execute_cse_reciprocals_1 has tried transforming.
10445
10446 2018-09-14 Aldy Hernandez <aldyh@redhat.com>
10447
10448 * tree-vrp.c (extract_range_from_binary_expr_1): Normalize
10449 VR_VARYING for PLUS/MINUS_EXPR.
10450
10451 2018-09-14 Ilya Leoshkevich <iii@linux.ibm.com>
10452
10453 * config/s390/s390-passes.def (INSERT_PASS_BEFORE): Improve
10454 formatting.
10455
10456 2018-09-14 Richard Biener <rguenther@suse.de>
10457
10458 PR middle-end/63155
10459 * tree-ssa-coalesce.c (ssa_conflicts_merge): Remove conflict
10460 bits for the merged partition.
10461
10462 2018-09-13 Martin Sebor <msebor@redhat.com>
10463 Bernd Edlinger <bernd.edlinger@hotmail.de>
10464
10465 * builtins.h (c_srlen): Add argument.
10466 * builtins.c (warn_string_no_nul): New function.
10467 (c_strlen): Add argument and use it. Update recursive calls.
10468 Pass DECL argument to string_constant to get info on non
10469 terminated strings. Update *NONSTR as needed.
10470 (fold_builtin_strlen): Add argument to calls to c_strlen.
10471 Warn for unterminated arrays.
10472 (warn_string_no_null): Add prototype.
10473 * expr.c (string_constant): Update arguments. Update recursive
10474 calls appropriately. Detect missing NUL terminator and outermost
10475 declaration its missing in.
10476 Improve checks for arrays with nonzero lower bound or elements
10477 that are not a single byte. Simplify offset computation.
10478 Simplify checks for non-NUL terminated strings.
10479 * gimple-fold.c (get_range_strlen): Add argument to c_strlen call.
10480 * gimple-ssa-sprintf.c (get_string_length): Remove unnecessary code.
10481
10482 2018-09-13 Bernd Edlinger <bernd.edlinger@hotmail.de>
10483
10484 * builtins.c (c_strlen): Handle not zero terminated STRING_CSTs
10485 correctly.
10486 * fold-const.c (c_getstr): Fix function comment. Remove unused third
10487 argument. Fix range checks.
10488 * fold-const.h (c_getstr): Adjust protoype.
10489 * gimple-fold.c (gimple_fold_builtin_memory_op): Avoid folding when
10490 string is constant but contains no NUL byte.
10491
10492 * expr.c (string_constant): Adjust function comment.
10493 Remove bogus check for zero termination.
10494
10495 * fold-const.c (c_getstr): Clamp STRING_LENGTH to STRING_SIZE.
10496
10497 * varasm.c (compare_constant): Compare type size of STRING_CSTs.
10498 (get_constant_size): Don't make STRING_CSTs larger than they are.
10499 (check_string_literal): New check function for STRING_CSTs.
10500 (output_constant): Use it.
10501
10502 2018-09-13 Eric Botcazou <ebotcazou@adacore.com>
10503
10504 PR target/86812
10505 * config/visium/visium.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Define.
10506
10507 2018-09-13 Richard Biener <rguenther@suse.de>
10508
10509 PR tree-optimization/87263
10510 * tree-ssa-sccvn.c (visit_phi): Revert some earlier changes.
10511 (struct unwind_state): Add max_rpo field.
10512 (do_rpo_vn): Allow up-to-date loop state to be used when not iterating.
10513 Compute max_rpo, the max RPO number a block can be backwards reached
10514 from. Re-write non-iterating mode to a RPO ordered worklist approach,
10515 separating it from the iterating mode.
10516
10517 2018-09-13 Vlad Lazar <vlad.lazar@arm.com>
10518
10519 * haifa-sched.c (rank_for_schedule): Schedule by INSN_COST.
10520 (rfs_decision): New scheduling decision.
10521
10522 2018-09-13 Richard Biener <rguenther@suse.de>
10523
10524 PR bootstrap/87134
10525 * tree-ssa-sccvn.c (vn_nary_op_insert_into): Fix assert.
10526 (vn_nary_op_insert_pieces_predicated): Do not write useless
10527 valid_dominated_by_p entry outside of the allocated storage.
10528
10529 2018-09-13 Omar Sandoval <osandov@osandov.com>
10530 Tom de Vries <tdevries@suse.de>
10531
10532 PR debug/86985
10533 * dwarf2out.c (is_c): New function.
10534 (add_subscript_info): Add DW_AT_count of 0 for C zero-length arrays.
10535
10536 2018-09-13 Sam Tebbs <sam.tebbs@arm.com>
10537
10538 PR target/85628
10539 * config/aarch64/aarch64.md (*aarch64_bfxil):
10540 Define.
10541 * config/aarch64/constraints.md (Ulc): Define.
10542 * config/aarch64/aarch64-protos.h (aarch64_high_bits_all_ones_p):
10543 Define.
10544 * config/aarch64/aarch64.c (aarch64_high_bits_all_ones_p):
10545 New function.
10546
10547 2018-09-13 Vlad Lazar <vlad.lazar@arm.com>
10548
10549 * config/aarch64/aarch64.h (TARGET_COMPUTE_FRAME_LAYOUT): Define.
10550 * config/aarch64/aarch64.c (aarch64_expand_prologue): Remove
10551 aarch64_layout_frame call.
10552 (aarch64_expand_epilogue): Likewise.
10553 (aarch64_initial_elimination_offset): Likewise.
10554 (aarch64_get_separate_components): Likewise.
10555 (aarch64_use_return_insn_p): Likewise.
10556 (aarch64_layout_frame): Remove unneeded check.
10557
10558 2018-09-13 Jakub Jelinek <jakub@redhat.com>
10559
10560 * configure.ac: Only append
10561 " : (reconfigured) $TOPLEVEL_CONFIGURE_ARGUMENTS" to
10562 gcc_config_arguments if it was never reconfigured or last reconfigure
10563 was with different arguments.
10564 * configure: Regenerated.
10565
10566 2018-09-13 Jakub Jelinek <jakub@redhat.com>
10567 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
10568
10569 PR middle-end/87290
10570 * expr.c (maybe_optimize_pow2p_mod_cmp): New function.
10571 (maybe_optimize_mod_cmp): Use it if integer_pow2p treeop1.
10572
10573 2018-09-13 Jakub Jelinek <jakub@redhat.com>
10574
10575 PR tree-optimization/87287
10576 * fold-const.c (fold_binary_loc) <case EQ_EXPR>: Move signed modulo
10577 X % C == 0 to X % (unsigned) C == 0 optimization to ...
10578 * match.pd (X % C == 0): ... here. New optimization.
10579
10580 2018-09-12 Jakub Jelinek <jakub@redhat.com>
10581
10582 PR middle-end/82853
10583 * expr.h (maybe_optimize_mod_cmp): Declare.
10584 * expr.c (mod_inv): New function.
10585 (maybe_optimize_mod_cmp): New function.
10586 (do_store_flag): Use it.
10587 * cfgexpand.c (expand_gimple_cond): Likewise.
10588
10589 2018-09-09 Cesar Philippidis <cesar@codesourcery.com>
10590 Julian Brown <julian@codesourcery.com>
10591
10592 PR middle-end/86336
10593 * gimplify.c (gimplify_scan_omp_clauses): Set
10594 target_firstprivatize_array_bases in OpenACC parallel and kernels
10595 region contexts. Remove GOMP_MAP_FIRSTPRIVATE_REFERENCE clauses from
10596 OpenACC data regions.
10597
10598 2018-09-12 Uros Bizjak <ubizjak@gmail.com>
10599
10600 * config/i386/i386.md (sqrt_extend<mode>xf3_i387): Remove.
10601 (sqrt<mode>2): Extend operand 1 to XFmode and generate sqrtxf3 insn.
10602
10603 2018-09-12 Richard Biener <rguenther@suse.de>
10604
10605 PR tree-optimization/87280
10606 * tree-ssa-sccvn.c (process_bb): Handle the case of executable
10607 edge but unreachable target.
10608 (do_rpo_vn): For conservatively handling a PHI only mark
10609 the backedge executable but not the block reachable.
10610
10611 2018-09-12 Richard Biener <rguenther@suse.de>
10612
10613 PR tree-optimization/87266
10614 * tree-ssa-sccvn.c (do_rpo_vn): Always iterate to not yet
10615 visited blocks.
10616
10617 2018-09-12 Andreas Krebbel <krebbel@linux.ibm.com>
10618
10619 * config/s390/s390.md (PFPO_RND_MODE_DFP, PFPO_RND_MODE_BFP): New
10620 constants.
10621 ("trunc<BFP:mode><DFP_ALL:mode>2")
10622 ("trunc<DFP_ALL:mode><BFP:mode>2")
10623 ("extend<BFP:mode><DFP_ALL:mode>2")
10624 ("extend<DFP_ALL:mode><BFP:mode>2"): Set proper rounding mode
10625 according to the target operand type.
10626
10627 2018-09-12 Jakub Jelinek <jakub@redhat.com>
10628 Andreas Krebbel <krebbel@linux.ibm.com>
10629
10630 PR tree-optimization/86844
10631 * gimple-ssa-store-merging.c
10632 (imm_store_chain_info::coalesce_immediate): For overlapping stores, if
10633 there are any overlapping stores in between them, make sure they are
10634 also coalesced or we give up completely.
10635
10636 2018-09-12 Jakub Jelinek <jakub@redhat.com>
10637
10638 PR middle-end/87248
10639 * fold-const.c (fold_ternary_loc) <case COND_EXPR>: Verify also that
10640 BIT_AND_EXPR's second operand is a power of two. Formatting fix.
10641
10642 2018-09-12 Tom de Vries <tdevries@suse.de>
10643
10644 * common.opt (gdescribe-dies): Add option.
10645 * dwarf2out.c (add_name_and_src_coords_attributes): Add description
10646 attribute for artifical and nameless decls.
10647 (dwarf2out_register_external_die): Add description attribute to
10648 external reference die.
10649 (add_desc_attribute): New functions.
10650 (gen_subprogram_die): Add description attribute to
10651 DW_TAG_call_site_parameter.
10652 * tree-pretty-print.c (print_generic_expr_to_str): New function.
10653 * tree-pretty-print.h (print_generic_expr_to_str): Declare.
10654 * doc/invoke.texi (@item Debugging Options): Add -gdescribe-dies and
10655 -gno-describe-dies.
10656 (@item -gdescribe-dies): Add.
10657
10658 2018-09-12 Aldy Hernandez <aldyh@redhat.com>
10659
10660 * tree-vrp.c (vrp_shift_undefined_p): Remove.
10661 (extract_range_from_binary_expr_1: Call
10662 wide_int_range_shift_undefined_p instead of vrp_shift_undefined_p.
10663 * wide-int-range.h (wide_int_range_shift_undefined_p): Do not
10664 depend on sign.
10665
10666 2018-09-12 Aldy Hernandez <aldyh@redhat.com>
10667
10668 * gimple-ssa-warn-alloca.c
10669 (alloca_type_and_limit::alloca_type_and_limit): Initialize limit
10670 field for ALLOCA_BOUND_*_LARGE.
10671
10672 2018-09-11 Nathan Sidwell <nathan@acm.org>
10673
10674 * gcc.c (load_specs, execute, run_attempt): Use %qs not '%s'.
10675
10676 2018-09-11 Uros Bizjak <ubizjak@gmail.com>
10677
10678 * reg-stack.c (subst_asm_stack_regs): Call replace_reg also
10679 for clobbers. Remove obsolete comment.
10680
10681 2018-09-11 Uros Bizjak <ubizjak@gmail.com>
10682
10683 * config/i386/i386.md (define_attr "type"): Remove mpxmov, mpxmk,
10684 mpxchk, mpxld and mpxst types.
10685 (define_attr length_immediate): Remove all processing of mpx types.
10686 (define_attr prefix_0f): Ditto.
10687 (define_attr memory): Ditto.
10688
10689 2018-09-11 Uros Bizjak <ubizjak@gmail.com>
10690
10691 * config/i386/i386.md (fyl2x_extend<mode>xf3_i387): Remove.
10692 (log<mode>2): Change operand 1 predicate to general_operand.
10693 Extend operand 1 to XFmode and generate logxf3 insn.
10694 (log10<mode>2): Change operand 1 predicate to general_operand.
10695 Extend operand 1 to XFmode and generate log10xf3 insn.
10696 (log2<mode>2): Change operand 1 predicate to general_operand.
10697 Extend operand 1 to XFmode and generate log2xf3 insn.
10698 (fyl2xp1_extend<mode>xf3_i387): Remove.
10699 (log1p<mode>2): Change operand 1 predicate to general_operand.
10700 Extend operand 1 to XFmode and generate log1pxf3 insn.
10701 (fxtract_extend<mode>xf3_i387): Remove.
10702 (logb<mode>2): Change operand 1 predicate to general_operand.
10703 Extend operand 1 to XFmode and generate logbxf3 insn.
10704 (ilogb<mode>2): Change operand 1 predicate to general_operand.
10705 Extend operand 1 to XFmode and generate fxtractxf3_i387 insn.
10706 (significand<mode>2): Change operand 1 predicate to general_operand.
10707 Extend operand 1 to XFmode and generate significandxf3 insn.
10708
10709 2018-09-11 Nathan Sidwell <nathan@acm.org>
10710
10711 * gcc.c (perror_with_name, pfatal_with_name): Delete.
10712 (load_specs): Use fatal_error.
10713 (DELETE_IF_ORDINARY, process_command): Use error.
10714 (execute, run_attempt): Use fatal_error.
10715
10716 2018-09-11 Andrew Stubbs <ams@codesourcery.com>
10717
10718 * diagnostic-core.h (sorry_at): New prototype.
10719 * diagnostic.c (sorry_at): New function.
10720
10721 2018-09-11 Aldy Hernandez <aldyh@redhat.com>
10722
10723 * tree-vrp.c (extract_range_from_binary_expr_1): Treat all divisions
10724 by zero as VR_UNDEFINED.
10725
10726 2018-09-10 Uros Bizjak <ubizjak@gmail.com>
10727
10728 * config/i386/i386.md (<sincos>xf2): Rename from *<sincos>xf2_i387.
10729 (*<sincos>_extend<mode>xf2_i387): Remove insn pattern.
10730 (<sincos>mode2): New expander.
10731 (sincos_extend<mode>xf3_i387): Remove insn pattern.
10732 (sincos -> sin, cos splitters): Remove splitter patterns.
10733 (sincos<mode>3): Change operand 2 predicate to general_operand.
10734 Extend operand 2 to XFmode and generate sincosxf3 insn.
10735 (fptanxf4_i387): Change mode of operands 0 and 3 to SFmode.
10736 Change operand 3 predicate to const1_operand.
10737 (fptan_extend<mode>xf4_i387): Remove insn pattern.
10738 (tanxf2): Update operands in the call to fptanxf4_i387.
10739 (tan<mode>2): Change operand 1 predicate to general_operand.
10740 Extend operand 1 to XFmode and generate tanxf3 insn.
10741 (atan2xf3): Rename from *fpatanxf3_i387.
10742 (fpatan_extend<mode>xf3_i387): Remove insn pattern.
10743 (atan2xf3): Remove expander.
10744 (atan2<mode<3): Change operand 1 and 2 predicates to general_operand.
10745 Extend operands 1 and 2 to XFmode and generate atan2xf3 insn.
10746 (atan<mode>2): Change operand 1 predicate to general_operand.
10747 Extend operand 1 to XFmode and generate atanxf3 insn.
10748
10749 2018-09-10 Uros Bizjak <ubizjak@gmail.com>
10750
10751 * config/i386/i386.md (x87/SSE constant load splitter): Use
10752 memory_operand instead of nonimmediate_operand for input operand
10753 predicate.
10754
10755 2018-09-09 Uros Bizjak <ubizjak@gmail.com>
10756
10757 * config/i386/i386.md (float partial SSE register stall splitter): Move
10758 splitter near its instruction pattern.
10759 (float_extend partial SSE register stall splitter): Ditto.
10760 (float_truncate partial SSE register stall splitter): Ditto.
10761
10762 2018-09-09 Hans-Peter Nilsson <hp@bitrange.com>
10763
10764 PR target/86794
10765 * config/mmix/mmix.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Redefine
10766 to speculation_safe_value_not_needed.
10767
10768 PR target/85666
10769 * config/mmix/mmix.c (mmix_assemble_integer): Handle byte-size
10770 non-CONST_INT rtx:es using assemble_integer_with_op ".byte".
10771 (MMIX_CFUN_NEEDS_SAVED_EH_RETURN_ADDRESS): Don't call
10772 leaf_function_p, instead use has_hard_reg_initial_val.
10773
10774 2018-09-09 Nathan Sidwell <nathan@acm.org>
10775
10776 * gcc.h (pfatal_with_name): Don't declare here.
10777 * gcc.c (pfatal_with_name): Make static.
10778
10779 2018-09-09 Xianmiao Qu <xianmiao_qu@c-sky.com>
10780
10781 * config/csky/csky.md (*cskyv2_adddi3, *cskyv2_subdi3): Add
10782 earlyclobber.
10783
10784 2018-09-08 John David Anglin <danglin@gcc.gnu.org>
10785
10786 PR rtl-optimization/85458
10787 * sel-sched.c (sel_target_adjust_priority): Allow backend adjust
10788 priority hook to reduce the priority of EXPR.
10789
10790 2018-09-07 Uros Bizjak <ubizjak@gmail.com>
10791
10792 * config/i386/i386.md (float<SWI48x:mode><MODEF:mode>2) Enable
10793 DImode for x87 on 32bit targets. Conditionally disable x87 modes
10794 with X87_ENABLE_FLOAT. Remove preparation code.
10795 (*float<SWI48:mode><MODEF:mode>2): Rename from
10796 *float<SWI48:mode><MODEF:mode>2_mixed. Handle x87, SSE and mixed
10797 math using "enabled" attribute.
10798 (*floatdi<MODEF:mode>2_i387): Rename from
10799 *float<SWI48x:mode><MODEF:mode>2_i387. Handle only DImode and
10800 enable for 32bit targets only.
10801 (floatdi<X87MODEF:mode>2_i387_with_xmm pre-reload splitter): New
10802 splitter.
10803 (floatdi<X87MODEF:mode>2_i387_with_xmm): Use register_operand
10804 as operand 1 predicate. Rewrite as define_insn_and_split.
10805 (floatdi<X87MODEF:mode>2_i387_with_xmm memory input splitter): Remove.
10806
10807 2018-09-06 Uros Bizjak <ubizjak@gmail.com>
10808
10809 * reg-stack.c (get_true_reg) <case FLOAT_TRUNCATE>: Reorder
10810 to fallthru to FLOAT case.
10811
10812 2018-09-06 Will Schmidt <will_schmidt@vnet.ibm.com>
10813
10814 PR target/86731
10815 * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Update logic
10816 around folding of vec_sl to handle out of range shift values.
10817
10818 2018-09-06 Uros Bizjak <ubizjak@gmail.com>
10819
10820 * config/i386/i386.md (fix_trunc<mode>_fisttp_i387_1): Remove.
10821 Update callers to gen_fix_trunc<mode>_i387_fisttp
10822 (fix_trunc<mode>_i387_fisttp): Change operand 0 predicate to
10823 nonimmediate_operand.
10824 (fix_trunc<mode>_i387_fisttp_with_temp): Remove insn pattern
10825 and corresponding splitters.
10826 (*fix_trunc<mode>_i387_1): Always expand with fix_trunc<mode>_i387.
10827 (fix_truncdi_i387): Change operand 0 predicate to nonimmediate_operand.
10828 (fix_truncdi_i387_with_temp): Remove insn pattern
10829 and corresponding splitters.
10830 (fix_trunc<mode>_i387): Change operand 0 predicate to
10831 nonimmediate_operand.
10832 (fix_trunc<mode>_i387_with_temp): Remove insn pattern
10833 and corresponding splitters.
10834 (*fistdi2_1): Remove.
10835 (fistdi2): Ditto.
10836 (fistdi2_with_temp): Remove insn pattern and corresponding splitters.
10837 (lrintxfdi2): Remove expander. Reimplement as define_insn.
10838 (*fist<mode>2_1): Remove.
10839 (fist<mode>2): Ditto.
10840 (fist<mode>2_with_temp): Remove insn pattern and corresponding
10841 splitters.
10842 (lrintxf<mode>2): Remove expander. Reimplement as define_insn.
10843 (*fist<mode>2_<rounding>_1): Always expand with fist<mode>2_<rounding>.
10844 (fistdi2_<rounding>): Change operand 0 predicate to
10845 nonimmediate_operand.
10846 (fistdi2_<rounding>_with_temp): Remove insn pattern
10847 and corresponding splitters.
10848 (fist<mode>2_<rounding>): Change operand 0 predicate to
10849 nonimmediate_operand.
10850 (fist<mode>2_<rounding>_with_temp): Remove insn pattern
10851 and corresponding splitters.
10852
10853 (*fixuns_trunc<mode>si2_avx512f_zext): Depend on TARGET_SSE_MATH.
10854
10855 2018-09-06 Bernd Edlinger <bernd.edlinger@hotmail.de>
10856
10857 * varasm.c (output_constructor_regular_field): Check TYPE_SIZE_UNIT of
10858 the init value.
10859
10860 2018-09-06 Will Schmidt <will_schmidt@vnet.ibm.com>
10861
10862 * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Add support for
10863 early gimple folding of vec_splat().
10864 * tree-vect-generic.c: Remove static from tree_vec_extract() definition.
10865 * gimple-fold.h: Add an extern define for tree_vec_extract().
10866
10867 2018-09-06 Will Schmidt <will_schmidt@vnet.ibm.com>
10868
10869 * config/rs6000/rs6000.c (fold_mergehl_helper): Add types_compatible_p
10870 wrappers around TREE_TYPE comparisons.
10871
10872 2018-09-06 Ilya Leoshkevich <iii@linux.ibm.com>
10873
10874 PR target/80080
10875 * config/s390/predicates.md: Add nonsym_memory_operand.
10876 * config/s390/s390.c (s390_legitimize_cs_operand): If operand
10877 contains a SYMBOL_REF, load it into an intermediate pseudo.
10878 (s390_emit_compare_and_swap): Legitimize operand.
10879 * config/s390/s390.md: Use the new nonsym_memory_operand
10880 with UNSPECV_CAS patterns.
10881
10882 2018-09-06 Ilya Leoshkevich <iii@linux.ibm.com>
10883
10884 PR target/80080
10885 * config/s390/s390-passes.def: New file.
10886 * config/s390/s390-protos.h (class rtl_opt_pass): Add forward
10887 declaration.
10888 (make_pass_s390_early_mach): Add declaration.
10889 * config/s390/s390.c (make_pass_s390_early_mach):
10890 (s390_option_override): Remove dynamic registration.
10891 * config/s390/t-s390: Add s390-passes.def.
10892
10893 2018-09-06 Ilya Leoshkevich <iii@linux.ibm.com>
10894
10895 * config/s390/s390.c (s390_decompose_constant_pool_ref):
10896 Remove UNSPEC_LTREL_BASE check.
10897 (annotate_constant_pool_refs): Likewise.
10898 (find_constant_pool_ref): Likewise.
10899 (find_ltrel_base): Removed.
10900 (replace_ltrel_base): Removed.
10901 (s390_mainpool_finish): Remove replace_ltrel_base call.
10902 (s390_chunkify_start): Remove pending LTREL_BASE logic.
10903 (s390_chunkify_finish): Remove replace_ltrel_base call.
10904 * config/s390/s390.md: Remove UNSPEC_LTREL_BASE.
10905
10906 2018-09-06 Hans-Peter Nilsson <hp@axis.com>
10907
10908 PR target/86779
10909 * config/cris/cris.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Redefine
10910 to speculation_safe_value_not_needed.
10911
10912 2018-09-05 Cesar Philippidis <cesar@codesourcery.com>
10913 Bernd Schmidt <bernds_cb1@t-online.de>
10914
10915 * config/nvptx/nvptx-opts.h: New file.
10916 * config/nvptx/nvptx.c (nvptx_file_start): Print the correct .target.
10917 * config/nvptx/nvptx.h: Include "nvptx-opts.h".
10918 (ASM_SPEC): Define.
10919 (TARGET_SM35): New macro.
10920 * config/nvptx/nvptx.md (atomic_fetch_<logic><mode>): Enable with the
10921 correct predicate.
10922 * config/nvptx/nvptx.opt (ptx_isa, sm_30, sm_35): New enum and its
10923 values.
10924 (misa=): New option.
10925 * doc/invoke.texi (Nvidia PTX Options): Document -misa.
10926
10927 2018-09-05 Uros Bizjak <ubizjak@gmail.com>
10928
10929 * config/i386/i386.md (truncdfsf2): Remove expander.
10930 (truncdfsf2_with_temp): Ditto.
10931 (truncxf<mode>2): Ditto.
10932 (*truncdfsf_fast_mixed): Remove insn pattern.
10933 (*truncdfsf_fast_i387): Ditto.
10934 (*truncdfsf_mixed): Ditto.
10935 (*truncdfsf_i387): Ditto.
10936 (*truncdfsf2_i387_1): Ditto.
10937 (*truncxfsf2_mixed): Ditto.
10938 (*truncxfdf2_mixed): Ditto.
10939 (*truncxf<mode>2_i387_noop): Ditto. Update callers
10940 to call gen_truncxf<mode>2 instead.
10941 (*truncxf<mode>2_i387): Remove.
10942 (reg->reg splitters): Remove splitter pattern.
10943 (reg->mem splitters): Ditto.
10944
10945 (truncdfsf2): New insn pattern.
10946 (truncxf<mode>2): Ditto.
10947
10948 2018-09-05 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
10949
10950 * tree-ssa-math-opts.c (is_mult_by): New function.
10951 (is_square_of): Use the above.
10952 (optimize_recip_sqrt): New function.
10953 (pass_cse_reciprocals::execute): Use the above.
10954
10955 2018-09-05 Richard Biener <rguenther@suse.de>
10956
10957 PR bootstrap/87134
10958 * tree-ssa-sccvn.c (rpo_elim::eliminate_push_avail): Make sure
10959 to zero-init the emplaced vec.
10960
10961 2018-09-05 Martin Liska <mliska@suse.cz>
10962
10963 PR tree-optimization/87205
10964 * tree-switch-conversion.c (pass_lower_switch::execute):
10965 Group cases for switch statements.
10966
10967 2018-09-05 Richard Biener <rguenther@suse.de>
10968
10969 PR tree-optimization/87217
10970 * tree-ssa-sccvn.c (vuse_valueize): New.
10971 (vn_reference_lookup_pieces): Use it.
10972 (vn_reference_lookup): Likewise.
10973
10974 2018-09-05 Nathan Sidwell <nathan@acm.org>
10975
10976 PR c++/87137
10977 * stor-layout.c (place_field): Scan forwards to check last
10978 bitfield when ms_bitfield_placement is in effect.
10979
10980 2018-09-05 Richard Biener <rguenther@suse.de>
10981
10982 PR bootstrap/87225
10983 * tree-vect-stmts.c (vectorizable_simd_clone_call): Fix bogus
10984 return.
10985
10986 2018-09-05 Siddhesh Poyarekar <siddhesh@sourceware.org>
10987 Kugan Vivekanandarajah <kugan.vivekanandarajah@linaro.org>
10988
10989 * config/aarch64/falkor-tag-collision-avoidance.c: New file.
10990 * config.gcc (extra_objs): Build it.
10991 * config/aarch64/t-aarch64 (falkor-tag-collision-avoidance.o):
10992 Likewise.
10993 * config/aarch64/aarch64-passes.def
10994 (pass_tag_collision_avoidance): New pass.
10995 * config/aarch64/aarch64.c (qdf24xx_tunings): Add
10996 AARCH64_EXTRA_TUNE_RENAME_LOAD_REGS to tuning_flags.
10997 (aarch64_classify_address): Remove static qualifier.
10998 (aarch64_address_info, aarch64_address_type): Move to...
10999 * config/aarch64/aarch64-protos.h: ... here.
11000 (make_pass_tag_collision_avoidance): New function.
11001 * config/aarch64/aarch64-tuning-flags.def (rename_load_regs):
11002 New tuning flag.
11003
11004 2018-09-05 Martin Liska <mliska@suse.cz>
11005
11006 * doc/gcov.texi: Update documentation of humar
11007 readable mode.
11008 * gcov.c (format_count): Print one decimal place, it provides
11009 more fine number of situations like '1G' vs. '1.4G'.
11010
11011 2018-09-05 Martin Liska <mliska@suse.cz>
11012
11013 PR target/87164
11014 * config/rs6000/rs6000.opt: Mark the option as Deprecated.
11015 * optc-gen.awk: Allow 'Var' for Deprecated options in order
11016 to generate a MASK value.
11017
11018 2018-09-04 H.J. Lu <hongjiu.lu@intel.com>
11019
11020 PR debug/86593
11021 * dwarf2out.c (based_loc_descr): Allow hard frame pointer even
11022 if frame pointer isn't used.
11023 (compute_frame_pointer_to_fb_displacement): Likewise.
11024
11025 2018-09-04 Jakub Jelinek <jakub@redhat.com>
11026
11027 PR target/87198
11028 * common/config/i386/i386-common.c (OPTION_MASK_ISA_XSAVEOPT_SET,
11029 OPTION_MASK_ISA_XSAVES_SET, OPTION_MASK_ISA_XSAVEC_SET): Use
11030 OPTION_MASK_ISA_XSAVE_SET instead of OPTION_MASK_ISA_XSAVE.
11031 (OPTION_MASK_ISA_XSAVE_UNSET): Add OPTION_MASK_ISA_XSAVES_UNSET
11032 and OPTION_MASK_ISA_XSAVEC_UNSET.
11033
11034 2018-09-04 Max Filippov <jcmvbkbc@gmail.com>
11035
11036 * config/xtensa/xtensa.c (xtensa_expand_atomic): Reorder AND and
11037 XOR operations in NAND case.
11038
11039 2018-09-04 Aldy Hernandez <aldyh@redhat.com>
11040
11041 * wide-int-range.cc (wide_int_range_convert): New.
11042 * wide-int-range.h (wide_int_range_convert): New.
11043 * tree-vrp.c (extract_range_from_unary_expr): Abstract wide int
11044 code into wide_int_range_convert.
11045 (extract_range_into_wide_ints): Do not munge anti range constants
11046 into the entire domain. Just return the range back.
11047
11048 2018-09-04 Martin Liska <mliska@suse.cz>
11049
11050 * genmatch.c (output_line_directive): Add new argument
11051 fnargs.
11052 (dt_simplify::gen_1): Encapsulate dump within __builtin_expect.
11053
11054 2018-09-04 Jonathan Wakely <jwakely@redhat.com>
11055
11056 * doc/invoke.texi (Option Summary): Add whitespace.
11057
11058 * doc/invoke.texi (Option Summary): Add -Waligned-new.
11059
11060 2018-09-04 Richard Biener <rguenther@suse.de>
11061
11062 PR tree-optimization/87211
11063 * tree-ssa-sccvn.c (visit_phi): When value-numbering to a
11064 backedge value we're supposed to treat as VARYING also number
11065 the PHI to VARYING in case it got a different value-number already.
11066
11067 2018-09-04 Aldy Hernandez <aldyh@redhat.com>
11068
11069 * tree-vrp.c (vrp_can_optimize_bit_op): Remove.
11070 (extract_range_from_binary_expr_1): Do not call
11071 vrp_can_optimize_bit_op.
11072 * wide-int-range.cc (wide_int_range_can_optimize_bit_op): Make
11073 static.
11074 (wide_int_range_get_mask_and_bounds): New.
11075 (wide_int_range_optimize_bit_op): New.
11076 (wide_int_range_bit_ior): Call wide_int_range_optimize_bit_op.
11077 (wide_int_range_bit_and): Same.
11078 * wide-int-range.h (wide_int_range_can_optimize_bit_op): Remove.
11079 (wide_int_range_optimize_bit_op): New.
11080 (wide_int_range_get_mask_and_bounds): New.
11081
11082 2018-09-04 Richard Biener <rguenther@suse.de>
11083
11084 PR tree-optimization/87176
11085 * tree-ssa-sccvn.c (visit_phi): Remove redundant allsame
11086 variable. When value-numbering a virtual PHI node make sure
11087 to not value-number to the backedge value.
11088
11089 2018-09-04 Jonathan Wakely <jwakely@redhat.com>
11090
11091 * doc/extend.texi (Long Long, Hex Floats): Document support for
11092 long long and hex floats in more recent versions of ISO C++.
11093
11094 2018-09-03 Richard Biener <rguenther@suse.de>
11095
11096 PR tree-optimization/87177
11097 * tree-ssa-sccvn.c (vuse_ssa_val): Revert previous change, keep
11098 cleanup.
11099
11100 2018-09-03 Alexander Monakov <amonakov@ispras.ru>
11101
11102 * bb-reorder.c (edge_order): Convert to C-qsort-style
11103 tri-state comparator.
11104 (reorder_basic_blocks_simple): Change std::stable_sort to
11105 gcc_stablesort.
11106
11107 2018-09-03 Alexander Monakov <amonakov@ispras.ru>
11108
11109 * tree-loop-distribution.c (offset_cmp): Convert to C-qsort-style
11110 tri-state comparator.
11111 (fuse_memset_builtins): Change std::stable_sort to gcc_stablesort.
11112
11113 2018-09-03 Alexander Monakov <amonakov@ispras.ru>
11114
11115 * sort.cc (struct sort_ctx): New field 'nlim'. Use it...
11116 (mergesort): ... here as maximum count for using netsort.
11117 (gcc_qsort): Set nlim to 3 if stable sort is requested.
11118 (gcc_stablesort): New.
11119 * system.h (gcc_stablesort): Declare.
11120
11121 2018-09-03 Alexander Monakov <amonakov@ispras.ru>
11122
11123 * sort.cc (gcc_qsort) [CHECKING_P]: Call qsort_chk.
11124 * system.h (qsort): Always redirect to gcc_qsort. Update comment.
11125 * vec.c (qsort_chk): Do not call gcc_qsort. Update comment.
11126
11127 2018-09-03 Segher Boessenkool <segher@kernel.crashing.org>
11128
11129 * config/rs6000/rs6000.md (*mov<mode>_hardfloat32): Remove %U from the
11130 lxsdx and stxsdx alternatives.
11131 (*mov<mode>_hardfloat64): Ditto.
11132 * config/rs6000/vsx.md (*vsx_extract_<mode>_store): Ditto.
11133
11134 2018-09-03 Richard Biener <rguenther@suse.de>
11135
11136 PR tree-optimization/87200
11137 * tree-ssa-sccvn.c (vn_nary_build_or_lookup_1): Valueize a
11138 simplify result.
11139
11140 2018-09-03 Martin Liska <mliska@suse.cz>
11141
11142 PR tree-optimization/87201
11143 * tree-switch-conversion.c (switch_decision_tree::balance_case_nodes):
11144 Fix parenthesis in an expression.
11145
11146 2018-09-03 Richard Biener <rguenther@suse.de>
11147
11148 PR tree-optimization/87197
11149 * tree-ssa-sccvn.c (vn_nary_build_or_lookup_1): Mark the new def
11150 visited. CSE the VN_INFO hashtable lookup.
11151
11152 PR tree-optimization/87169
11153 * tree-ssa-sccvn.c (do_rpo_vn): When marking loops for not
11154 iterating make sure there's no extra backedges from irreducible
11155 regions feeding the header. Mark the destination block
11156 executable.
11157
11158 2018-09-03 Martin Liska <mliska@suse.cz>
11159
11160 PR driver/83193
11161 * common/common-target.def: Add TARGET_GET_VALID_OPTION_VALUES.
11162 * common/common-targhooks.c (default_get_valid_option_values):
11163 New function.
11164 * common/common-targhooks.h (default_get_valid_option_values):
11165 Likewise.
11166 * common/config/i386/i386-common.c: Move processor_target_table
11167 from i386.c.
11168 (ix86_get_valid_option_values): New function.
11169 (TARGET_GET_VALID_OPTION_VALUES): New macro.
11170 * config/i386/i386.c (struct ptt): Move to i386-common.c.
11171 (PTA_*): Move all defined masks into i386-common.c.
11172 (ix86_function_specific_restore): Use new processor_cost_table.
11173 * config/i386/i386.h (struct ptt): Moved from i386.c.
11174 (struct pta): Likewise.
11175 * doc/tm.texi: Document new TARGET_GET_VALID_OPTION_VALUES.
11176 * doc/tm.texi.in: Likewise.
11177 * opt-suggestions.c (option_proposer::suggest_option):
11178 Pass prefix to build_option_suggestions.
11179 (option_proposer::get_completions): Likewise.
11180 (option_proposer::build_option_suggestions): Use the new target
11181 hook.
11182 * opts.c (struct option_help_tuple): New struct.
11183 (print_filtered_help): Use the new target hook.
11184
11185 2018-09-03 Martin Liska <mliska@suse.cz>
11186
11187 PR middle-end/59521
11188 * predict.c (set_even_probabilities): Add likely_edges
11189 argument and handle cases where we have precisely one
11190 likely edge.
11191 (combine_predictions_for_bb): Catch also likely_edges.
11192 (tree_predict_by_opcode): Handle gswitch statements.
11193 * tree-cfg.h (find_case_label_for_value): New declaration.
11194 (find_taken_edge_switch_expr): Likewise.
11195 * tree-switch-conversion.c (switch_decision_tree::balance_case_nodes):
11196 Find pivot in decision tree based on probabily, not by number of
11197 nodes.
11198
11199 2018-09-02 Gerald Pfeifer <gerald@pfeifer.com>
11200
11201 * doc/standards.texi (Standards): Update Objective-C reference.
11202
11203 2018-09-01 Gerald Pfeifer <gerald@pfeifer.com>
11204
11205 * doc/install.texi (Prerequisites): Update link for MPC.
11206
11207 2018-09-01 Michael Matz <matz@suse.de>
11208
11209 PR tree-optimization/87074
11210 * gimple-loop-jam.c (unroll_jam_possible_p): Check loop exit
11211 PHIs for outer-loop uses.
11212
11213 2018-09-01 Gerald Pfeifer <gerald@pfeifer.com>
11214
11215 * doc/generic.texi (OpenMP): Adjust link to openmp.org.
11216 * doc/invoke.texi (C Dialect Options): Ditto.
11217
11218 2018-09-01 Gerald Pfeifer <gerald@pfeifer.com>
11219
11220 * doc/install.texi (Prerequisites): Adjust link mpfr.org.
11221
11222 2018-08-31 Richard Biener <rguenther@suse.de>
11223
11224 PR tree-optimization/87168
11225 * tree-ssa-sccvn.c (SSA_VAL): Add visited output parameter.
11226 (rpo_elim::eliminate_avail): When OP was not visited it must
11227 be available.
11228
11229 2018-08-31 David Malcolm <dmalcolm@redhat.com>
11230
11231 * tree-vrp.c (copy_value_range): Convert param "from" from
11232 "value_range *" to "const value_range *".
11233 (range_is_null): Likewise for param "vr".
11234 (range_int_cst_p): Likewise.
11235 (range_int_cst_singleton_p): Likewise.
11236 (symbolic_range_p): Likewise.
11237 (value_ranges_intersect_p): Likewise for both params.
11238 (value_range_nonnegative_p): Likewise for param "vr".
11239 (value_range_constant_singleton): Likewise.
11240 (vrp_set_zero_nonzero_bits): Likewise for param "ar".
11241 (extract_range_into_wide_ints): Likewise for param "vr".
11242 (extract_range_from_multiplicative_op): Likewise for params "vr0"
11243 and "vr1".
11244 (vrp_can_optimize_bit_op): Likewise.
11245 (extract_range_from_binary_expr_1): Likewise for params "vr0_" and
11246 "vr1_".
11247 (extract_range_from_unary_expr): Likewise.
11248 (debug_value_range): Likewise for param "vr".
11249 (value_range::dump): Add "const" qualifier.
11250 (vrp_prop::check_array_ref): Convert local "vr" from
11251 "value_range *" to "const value_range *".
11252 (vrp_prop::check_mem_ref): Likewise.
11253 (vrp_prop::visit_stmt): Likewise for local "old_vr".
11254 (vrp_intersect_ranges_1): Likewise for param "vr_1".
11255 (vrp_intersect_ranges): Likewise.
11256 (simplify_stmt_for_jump_threading): Likewise for local "vr".
11257 (vrp_prop::vrp_finalize): Likewise.
11258 * tree-vrp.h (value_range::dump): Add "const" qualifier.
11259 (vrp_intersect_ranges): Add "const" qualifier to params as above.
11260 (extract_range_from_unary_expr): Likewise.
11261 (value_range_constant_singleton): Likewise.
11262 (symbolic_range_p): Likewise.
11263 (copy_value_range): Likewise.
11264 (extract_range_from_binary_expr_1): Likewise.
11265 (range_int_cst_p): Likewise.
11266 (vrp_set_zero_nonzero_bits): Likewise.
11267 (range_int_cst_singleton_p): Likewise.
11268
11269 2018-08-31 Vlad Lazar <vlad.lazar@arm.com>
11270
11271 * config/aarch64/arm_neon.h (vabsd_s64): New.
11272 (vnegd_s64): Likewise.
11273
11274 2018-08-31 Martin Jambor <mjambor@suse.cz>
11275
11276 * ipa-cp.c (estimate_local_effects): Replace wrong MAX with MIN.
11277
11278 2018-08-31 Martin Liska <mliska@suse.cz>
11279
11280 * ipa-icf.c (sem_item::add_type): Use
11281 sem_item::m_type_hash_cache.
11282 * ipa-icf.h: Move the cache from sem_item_optimizer
11283 to sem_item.
11284
11285 2018-08-31 Nathan Sidwell <nathan@acm.org>
11286
11287 * doc/extend.texi (Backwards Compatibility): Remove implicit
11288 extern C leeway of () being (...).
11289
11290 2018-08-31 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
11291
11292 * ipa-inline.c (can_inline_edge_by_limits_p): Fix typos in comment.
11293
11294 2018-08-31 Segher Boessenkool <segher@kernel.crashing.org>
11295
11296 PR target/86684
11297 PR target/87149
11298 * config/rs6000/rs6000.md (lround<mode>di2): Gate on TARGET_FPRND.
11299
11300 2018-08-31 Jakub Jelinek <jakub@redhat.com>
11301
11302 PR middle-end/87138
11303 * expmed.c (expand_mult_const): Use immed_wide_int_const instead of
11304 gen_int_mode. Formatting fixes.
11305
11306 2018-08-30 Sandra Loosemore <sandra@codesourcery.com>
11307
11308 * target.def (custom_function_descriptors): Improve documentation.
11309 * doc/tm.texi.in (Trampolines): Expand discussion of function
11310 descriptors and move TARGET_CUSTOM_FUNCTION_DESCRIPTORS to the
11311 beginning of the section.
11312 * doc/tm.texi: Regenerated.
11313
11314 2018-08-30 Jose E. Marchesi <jose.marchesi@oracle.com>
11315
11316 * cfg.h (class auto_edge_flag): Spell out the template-id of the
11317 base class in the initializer list. This is a workaround for
11318 building with older GCC.
11319 (class auto_bb_flag): Likewise.
11320
11321 2018-08-30 Aaron Sawdey <acsawdey@linux.ibm.com>
11322
11323 * config/rs6000/altivec.md (altivec_eq<mode>): Remove star.
11324 (altivec_vcmpequ<VI_char>_p): Remove star.
11325 * config/rs6000/rs6000-string.c (do_load_for_compare): Support
11326 vector load modes.
11327 (expand_strncmp_vec_sequence): New function.
11328 (emit_final_str_compare_vec): New function.
11329 (expand_strn_compare): Add support for vector strncmp.
11330 * config/rs6000/rs6000.opt (-mstring-compare-inline-limit): Change
11331 length specification to bytes.
11332 * config/rs6000/vsx.md (vsx_ld_elemrev_v16qi_internal): Remove star.
11333 (vcmpnezb_p): New pattern.
11334 * doc/invoke.texi (RS/6000 and PowerPC Options): Update documentation
11335 for option -mstring-compare-inline-limit.
11336
11337 2018-08-30 Thiago Macieira <thiago.macieira@intel.com>
11338
11339 * config/i386/i386.c (PTA_WESTMERE): Remove PTA_AES.
11340 (PTA_SKYLAKE): Add PTA_AES.
11341 (PTA_GOLDMONT): Likewise.
11342
11343 2018-08-29 Jan Hubicka <jh@suse.cz>
11344
11345 PR lto/86517
11346 * lto-opts.c (lto_write_options): Always stream PIC/PIE mode.
11347 * lto-wrapper.c (merge_and_complain): Fix merging of PIC/PIE.
11348
11349 2018-08-29 Jan Hubicka <jh@suse.cz>
11350
11351 * lto-streamer-out.c (DFS::DFS_write_tree_body): Do not follow
11352 TYPE_STUB_DECL.
11353 (hash_tree): Do not visit TYPE_STUB_DECL.
11354 * tree-streamer-out.c (write_ts_type_common_tree_pointers): Do not
11355 stream TYPE_STUB_DECL.
11356 * tree-streamer-in.c (lto_input_ts_type_common_tree_pointers): Likewise.
11357 * ipa-utils.h (type_with_linkage_p): Do not rely on TYPE_STUB_DECL
11358 after free_lang_data.
11359 (type_in_anonymous_namespace_p): Likewise.
11360
11361 2018-08-29 Jan Hubicka <jh@suse.cz>
11362
11363 * sreal.h (SREAL_PART_BITS): Change to 31; remove seemingly unnecessary
11364 comment that it has to be even number.
11365 (class sreal): Change m_sig type to int32_t.
11366 * sreal.c (sreal::dump, sreal::to_int, opreator+, operator-): Use
11367 int64_t for temporary calculations.
11368 (sreal_verify_basics): Drop one bit from minimum and maximum.
11369
11370 2018-08-30 Richard Biener <rguenther@suse.de>
11371
11372 PR tree-optimization/87147
11373 * tree-ssa-sccvn.c (SSA_VISITED): New function.
11374 (visit_phi): When the degenerate result is from the backedge and
11375 we didn't visit its definition yet drop to VARYING.
11376 (do_rpo_vn): Properly mark blocks with incoming backedges as executable.
11377
11378 2018-08-29 Jan Hubicka <jh@suse.cz>
11379
11380 * lto-streamer-out.c (DFS::DFS_write_tree_body): Do not walk
11381 DECL_VINDEX.
11382 (hash_tree): Likewise.
11383
11384 2018-08-29 Jan Hubicka <jh@suse.cz>
11385
11386 * tree.c (find_decls_types_r): Walk also TYPE_NEXT_PTR_TO
11387 and TYPE_NEXT_REF_TO.
11388
11389 2018-08-29 Jan Hubicka <jh@suse.cz>
11390
11391 * sreal.h (SREAL_PART_BITS): Change to 31; remove seemingly unnecessary
11392 comment that it has to be even number.
11393 (class sreal): Change m_sig type to int32_t.
11394 * sreal.c (sreal::dump, sreal::to_int, opreator+, operator-): Use
11395 int64_t for temporary calculations.
11396 (sreal_verify_basics): Drop one bit from minimum and maximum.
11397
11398 2018-08-30 Tamar Christina <tamar.christina@arm.com>
11399
11400 * config/aarch64/aarch64.c (aarch64_expand_movmem): Set TImode max.
11401
11402 2018-08-30 Vlad Lazar <vlad.lazar@arm.com>
11403
11404 PR middle-end/86995
11405 * expmed.c (canonicalize_comparison): Use wi::sub instead of wi::add
11406 if to_add is negative.
11407
11408 2018-08-29 Bernd Edlinger <bernd.edlinger@hotmail.de>
11409
11410 PR middle-end/87053
11411 * builtins.c (c_strlen): Improve range checks.
11412
11413 2018-08-29 Martin Sebor <msebor@redhat.com>
11414 Jeff Law <law@redhat.com>
11415
11416 PR tree-optimization/86714
11417 PR tree-optimization/86711
11418 * builtins.c (c_strlen): Add arguments to call to string_constant.
11419 * expr.c (string_constant): Add argument. Detect missing nul
11420 terminator and outermost declaration it's missing in.
11421 * expr.h (string_constant): Add argument.
11422 * fold-const.c (read_from_constant_string): Add arguments to call to
11423 string_constant.
11424 (c_getstr): Likewise.
11425 * tree-ssa-forwprop.c (simplify_builtin_call): Likewise.
11426 to string_constant.
11427 * tree-ssa-strlen.c (get_stridx): Likewise.
11428
11429 2018-08-29 Jan Hubicka <jh@suse.cz>
11430
11431 * tree-streamer-in.c (lto_input_ts_function_decl_tree_pointers):
11432 Do not stream DECL_VINDEX.
11433 * tree-streamer-out.c (write_ts_function_decl_tree_pointers): Likewise.
11434 * tree.c (free_lang_data_in_decl): Clear DECL_VINDEX.
11435 (decl_function_context): Use DECL_VIRTUAL_P rather than DECL_VINDEX.
11436
11437 2018-08-29 Richard Biener <rguenther@suse.de>
11438
11439 * tree-ssa-sccvn.c (vuse_ssa_val): Return NULL for unvisited
11440 virtual operands that are not default defs to honor region
11441 boundaries.
11442 (rpo_vn_valueize): Remove ineffective code here.
11443
11444 2018-08-29 Richard Biener <rguenther@suse.de>
11445
11446 PR tree-optimization/87132
11447 * tree-ssa-alias.c (get_continuation_for_phi): Do not translate
11448 when skipping defs reachable over backedges.
11449
11450 2018-08-29 Richard Biener <rguenther@suse.de>
11451
11452 * tree-core.h: Document use of deprecated_flag in SSA_NAME.
11453 * tree.h (SSA_NAME_POINTS_TO_READONLY_MEMORY): Define.
11454 * tree-into-ssa.c (pass_build_ssa::execute): Initialize
11455 function parameters SSA_NAME_POINTS_TO_READONLY_MEMORY from fnspec.
11456 * tree-ssa-sccvn.c (const_parms, init_const_parms): Remove.
11457 (vn_reference_lookup_3): Remove use of const_parms.
11458 (free_rpo_vn): Do not free const_parms.
11459 (do_rpo_vn): Do not call init_const_parms.
11460 * tree-ssa-alias.c (refs_may_alias_p_1): Honor
11461 SSA_NAME_POINTS_TO_READONLY_MEMORY.
11462 (call_may_clobber_ref_p_1): Likewise.
11463
11464 2018-08-29 Alexander Monakov <amonakov@ispras.ru>
11465
11466 PR other/86726
11467 * invoke.texi (Optimization Options): List -ftree-scev-cprop.
11468 (-O): Ditto.
11469 (-ftree-scev-cprop): Document.
11470
11471 2018-08-29 Jan Hubicka <jh@suse.cz>
11472
11473 * sreal.h (normalize, normalize_up, normalize_down): Add new_sig/new_exp
11474 parameters.
11475 (sreal constructor): Update.
11476 * sreal.c (sreal:operator+, sreal:operator-, sreal:operator*,
11477 sreal:operator/): Update.
11478
11479 2018-08-29 Martin Liska <mliska@suse.cz>
11480
11481 * tree-switch-conversion.c (switch_conversion::expand):
11482 Strenghten assumption about gswitch statements.
11483
11484 2018-08-29 Richard Biener <rguenther@suse.de>
11485
11486 PR tree-optimization/87117
11487 * tree-ssa-sccvn.c (eliminate_dom_walker::eliminate_stmt): Only
11488 re-value-number released SSA VDEFs.
11489
11490 2018-08-29 Richard Biener <rguenther@suse.de>
11491
11492 PR tree-optimization/87126
11493 * tree-ssa-sccvn.c (vn_reference_insert): Remove assert.
11494
11495 2018-08-28 Jim Wilson <jimw@sifive.com>
11496
11497 * config/riscv/pic.md: Rewrite.
11498 * config/riscv/riscv.c (riscv_address_insns): Return cost of 3 for
11499 invalid address.
11500 * config/riscv/riscv.md (ZERO_EXTEND_LOAD): Delete.
11501 (SOFTF, default_load, softload, softstore): New.
11502
11503 2018-08-28 Jeff Law <law@redhat.com>
11504
11505 * fold-const.c (fold_binary_loc): Remove recently added assert.
11506
11507 2018-08-28 Joern Rennecke <joern.rennecke@riscy-ip.com>
11508
11509 * genpreds.c (write_predicate_subfunction): Also add ATTRIBUTE_UNUSED
11510 to OP parmeter of generated function.
11511
11512 2018-08-28 MCC CS <deswurstes@users.noreply.github.com>
11513
11514 PR tree-optimization/87009
11515 * match.pd: Add boolean optimizations.
11516
11517 2018-08-28 Martin Sebor <msebor@redhat.com>
11518
11519 PR middle-end/86631
11520 * calls.c (alloc_max_size): Treat HOST_WIDE_INT special.
11521 * gimple-ssa-warn-alloca.c (adjusted_warn_limit): New function.
11522 (pass_walloca::gate): Use it.
11523 (alloca_call_type): Same.
11524 (pass_walloca::execute): Same.
11525 * stor-layout.c (layout_decl): Treat HOST_WIDE_INT special.
11526
11527 2018-08-28 David Malcolm <dmalcolm@redhat.com>
11528
11529 * dumpfile.h (ATTRIBUTE_GCC_DUMP_PRINTF): Change version check on
11530 GCC_VERSION for usage of "__gcc_dump_printf__" format from
11531 >= 3005 to >= 9000.
11532
11533 2018-08-28 Richard Biener <rguenther@suse.de>
11534
11535 PR tree-optimization/87124
11536 * tree-ssa-sccvn.c (vn_lookup_simplify_result): Guard against
11537 constants before looking up avail.
11538
11539 2018-08-28 Jakub Jelinek <jakub@redhat.com>
11540
11541 PR middle-end/87099
11542 * calls.c (maybe_warn_nonstring_arg): Punt early if
11543 warn_stringop_overflow is zero. Don't call get_range_strlen
11544 on 3rd argument, keep iterating until lenrng[1] is INTEGER_CST.
11545 Swap comparison operands to have constants on rhs. Only use
11546 lenrng[1] if non-NULL and INTEGER_CST. Don't uselessly
11547 increment lenrng[0].
11548
11549 2018-08-28 Richard Sandiford <richard.sandiford@arm.com>
11550
11551 * tree-ssa-sccvn.c (fully_constant_vn_reference_p): Fix unguarded
11552 use of tree_to_shwi. Remove duplicated test for the size being
11553 a whole number of bytes.
11554
11555 2018-08-28 Richard Biener <rguenther@suse.de>
11556
11557 PR tree-optimization/87117
11558 * tree-ssa-sccvn.c (eliminate_dom_walker::eliminate_cleanup):
11559 Handle removed stmt without LHS (GIMPLE_NOP).
11560
11561 2018-08-28 Richard Biener <rguenther@suse.de>
11562
11563 PR tree-optimization/87117
11564 * tree-ssa-sccvn.c (fully_constant_vn_reference_p): Exclude
11565 void which is is_gimple_reg_type by checking for COMPLETE_TYPE_P.
11566
11567 2018-08-28 Richard Biener <rguenther@suse.de>
11568
11569 PR tree-optimization/87117
11570 * tree-ssa-pre.c (compute_avail): Do not make expressions
11571 with predicated values available.
11572 (get_expr_value_id): Assert we do not run into predicated value
11573 expressions.
11574
11575 2018-08-28 Richard Biener <rguenther@suse.de>
11576
11577 PR tree-optimization/87117
11578 * tree-ssa-operands.c (add_stmt_operand): STRING_CST may
11579 get virtual operands.
11580 (get_expr_operands): Handle STRING_CST like other decls.
11581
11582 2018-08-28 Martin Liska <mliska@suse.cz>
11583
11584 * tree.h: Update documentation of fndecl_built_in_p
11585 functions.
11586
11587
11588 2018-08-27 Jeff Law <law@redhat.com>
11589 PR tree-optimization/87110
11590 * tree-ssa-dse.c (compute_trims): Handle non-constant
11591 TYPE_SIZE_UNIT.
11592
11593 2018-08-27 Martin Sebor <msebor@redhat.com>
11594
11595 PR tree-optimization/86914
11596 * tree-ssa-strlen.c (maybe_set_strlen_range): Avoid MEM_REF.
11597
11598 2018-08-27 Martin Sebor <msebor@redhat.com>
11599
11600 PR tree-optimization/87112
11601 * builtins.c (expand_builtin_strnlen): Convert c_strlen result to
11602 the type of the bound argument.
11603
11604 2018-08-27 Jeff Law <law@redhat.com>
11605
11606 * tree-ssa-dse.c (compute_trims): Handle case where the reference's
11607 type does not have a TYPE_SIZE_UNIT.
11608
11609 2018-08-27 Steve Ellcey <sellcey@cavium.com>
11610
11611 * config/aarch64/aarch64-speculation.cc: Replace include of cfg.h
11612 with include of backend.h.
11613
11614 2018-08-27 Richard Biener <rguenther@suse.de>
11615
11616 PR tree-optimization/86927
11617 * tree-vect-loop.c (vect_create_epilog_for_reduction): Properly
11618 use const cond reduction code.
11619
11620 2018-08-27 Alexander Monakov <amonakov@ispras.ru>
11621
11622 PR tree-optimization/85758
11623 * match.pd ((X & Y) ^ Y): Add :s qualifier to inner expression.
11624
11625 2018-08-27 David Malcolm <dmalcolm@redhat.com>
11626
11627 PR c++/87091
11628 * diagnostic-show-locus.c (class layout_range): Update for
11629 conversion of show_caret_p to a tri-state.
11630 (layout_range::layout_range): Likewise.
11631 (make_range): Likewise.
11632 (layout::maybe_add_location_range): Likewise.
11633 (layout::should_print_annotation_line_p): Don't show annotation
11634 lines for ranges that are SHOW_LINES_WITHOUT_RANGE.
11635 (layout::get_state_at_point): Update for conversion of
11636 show_caret_p to a tri-state. Bail out early for
11637 SHOW_LINES_WITHOUT_RANGE, so that such ranges don't affect
11638 underlining or source colorization.
11639 (gcc_rich_location::add_location_if_nearby): Update for conversion
11640 of show_caret_p to a tri-state.
11641 (selftest::test_one_liner_multiple_carets_and_ranges): Likewise.
11642 (selftest::test_one_liner_fixit_replace_equal_secondary_range):
11643 Likewise.
11644 (selftest::test_one_liner_labels): Likewise.
11645 * gcc-rich-location.c (gcc_rich_location::add_expr): Update for
11646 conversion of show_caret_p to a tri-state.
11647 * pretty-print.c (text_info::set_location): Likewise.
11648 * pretty-print.h (text_info::set_location): Likewise.
11649 * substring-locations.c (format_warning_n_va): Likewise.
11650 * tree-diagnostic.c (default_tree_printer): Likewise.
11651 * tree-pretty-print.c (newline_and_indent): Likewise.
11652
11653 2018-08-27 David Malcolm <dmalcolm@redhat.com>
11654
11655 PR c++/87091
11656 * diagnostic-show-locus.c (get_line_span_for_fixit_hint): Show the
11657 line above for line-insertion fix-it hints.
11658 (selftest::test_fixit_insert_containing_newline): Update the
11659 expected results, and add a test with line-numbering enabled.
11660
11661 2018-08-27 Martin Liska <mliska@suse.cz>
11662
11663 PR sanitizer/86962
11664 * sanopt.c (sanitize_rewrite_addressable_params): Ignore
11665 params with DECL_HAS_VALUE_EXPR_P.
11666
11667 2018-08-27 Martin Liska <mliska@suse.cz>
11668
11669 * config/i386/i386.c (ix86_expand_set_or_movmem): Dump
11670 selected expansion strategy.
11671
11672 2018-08-27 Martin Liska <mliska@suse.cz>
11673
11674 * builtins.h (is_builtin_fn): Remove and fndecl_built_in_p.
11675 * builtins.c (is_builtin_fn): Likewise.
11676 * attribs.c (diag_attr_exclusions): Use new function
11677 fndecl_built_in_p and remove check for FUNCTION_DECL if
11678 possible.
11679 (builtin_mathfn_code): Likewise.
11680 (fold_builtin_expect): Likewise.
11681 (fold_call_expr): Likewise.
11682 (fold_builtin_call_array): Likewise.
11683 (fold_call_stmt): Likewise.
11684 (set_builtin_user_assembler_name): Likewise.
11685 (is_simple_builtin): Likewise.
11686 * calls.c (gimple_alloca_call_p): Likewise.
11687 (maybe_warn_nonstring_arg): Likewise.
11688 * cfgexpand.c (expand_call_stmt): Likewise.
11689 * cgraph.c (cgraph_update_edges_for_call_stmt_node): Likewise.
11690 (cgraph_edge::verify_corresponds_to_fndecl): Likewise.
11691 (cgraph_node::verify_node): Likewise.
11692 * cgraphclones.c (build_function_decl_skip_args): Likewise.
11693 (cgraph_node::create_clone): Likewise.
11694 * config/arm/arm.c (arm_insert_attributes): Likewise.
11695 * config/i386/i386.c (ix86_gimple_fold_builtin): Likewise.
11696 * dse.c (scan_insn): Likewise.
11697 * expr.c (expand_expr_real_1): Likewise.
11698 * fold-const.c (operand_equal_p): Likewise.
11699 (fold_binary_loc): Likewise.
11700 * gimple-fold.c (gimple_fold_stmt_to_constant_1): Likewise.
11701 * gimple-low.c (lower_stmt): Likewise.
11702 * gimple-pretty-print.c (dump_gimple_call): Likewise.
11703 * gimple-ssa-warn-restrict.c (wrestrict_dom_walker::check_call):
11704 Likewise.
11705 * gimple.c (gimple_build_call_from_tree): Likewise.
11706 (gimple_call_builtin_p): Likewise.
11707 (gimple_call_combined_fn): Likewise.
11708 * gimplify.c (gimplify_call_expr): Likewise.
11709 (gimple_boolify): Likewise.
11710 (gimplify_modify_expr): Likewise.
11711 (gimplify_addr_expr): Likewise.
11712 * hsa-gen.c (gen_hsa_insns_for_call): Likewise.
11713 * ipa-cp.c (determine_versionability): Likewise.
11714 * ipa-fnsummary.c (compute_fn_summary): Likewise.
11715 * ipa-param-manipulation.c (ipa_modify_formal_parameters): Likewise.
11716 * ipa-split.c (visit_bb): Likewise.
11717 (split_function): Likewise.
11718 * ipa-visibility.c (cgraph_externally_visible_p): Likewise.
11719 * lto-cgraph.c (input_node): Likewise.
11720 * lto-streamer-out.c (write_symbol): Likewise.
11721 * omp-low.c (setjmp_or_longjmp_p): Likewise.
11722 (lower_omp_1): Likewise.
11723 * predict.c (strip_predict_hints): Likewise.
11724 * print-tree.c (print_node): Likewise.
11725 * symtab.c (symtab_node::output_to_lto_symbol_table_p): Likewise.
11726 * trans-mem.c (is_tm_irrevocable): Likewise.
11727 (is_tm_load): Likewise.
11728 (is_tm_simple_load): Likewise.
11729 (is_tm_store): Likewise.
11730 (is_tm_simple_store): Likewise.
11731 (is_tm_abort): Likewise.
11732 (tm_region_init_1): Likewise.
11733 * tree-call-cdce.c (gen_shrink_wrap_conditions): Likewise.
11734 * tree-cfg.c (verify_gimple_call): Likewise.
11735 (move_stmt_r): Likewise.
11736 (stmt_can_terminate_bb_p): Likewise.
11737 * tree-eh.c (lower_eh_constructs_2): Likewise.
11738 * tree-if-conv.c (if_convertible_stmt_p): Likewise.
11739 * tree-inline.c (remap_gimple_stmt): Likewise.
11740 (copy_bb): Likewise.
11741 (estimate_num_insns): Likewise.
11742 (fold_marked_statements): Likewise.
11743 * tree-sra.c (scan_function): Likewise.
11744 * tree-ssa-ccp.c (surely_varying_stmt_p): Likewise.
11745 (optimize_stack_restore): Likewise.
11746 (pass_fold_builtins::execute): Likewise.
11747 * tree-ssa-dce.c (mark_stmt_if_obviously_necessary): Likewise.
11748 (mark_all_reaching_defs_necessary_1): Likewise.
11749 * tree-ssa-dom.c (dom_opt_dom_walker::optimize_stmt): Likewise.
11750 * tree-ssa-forwprop.c (simplify_builtin_call): Likewise.
11751 (pass_forwprop::execute): Likewise.
11752 * tree-ssa-loop-im.c (stmt_cost): Likewise.
11753 * tree-ssa-math-opts.c (pass_cse_reciprocals::execute): Likewise.
11754 * tree-ssa-sccvn.c (fully_constant_vn_reference_p): Likewise.
11755 * tree-ssa-strlen.c (get_string_length): Likewise.
11756 * tree-ssa-structalias.c (handle_lhs_call): Likewise.
11757 (find_func_aliases_for_call): Likewise.
11758 * tree-ssa-ter.c (find_replaceable_in_bb): Likewise.
11759 * tree-stdarg.c (optimize_va_list_gpr_fpr_size): Likewise.
11760 * tree-tailcall.c (find_tail_calls): Likewise.
11761 * tree.c (need_assembler_name_p): Likewise.
11762 (free_lang_data_in_decl): Likewise.
11763 (get_call_combined_fn): Likewise.
11764 * ubsan.c (is_ubsan_builtin_p): Likewise.
11765 * varasm.c (incorporeal_function_p): Likewise.
11766 * tree.h (DECL_BUILT_IN): Remove and replace with
11767 fndecl_built_in_p.
11768 (DECL_BUILT_IN_P): Transfort to fndecl_built_in_p.
11769 (fndecl_built_in_p): New.
11770
11771 2018-08-27 Martin Liska <mliska@suse.cz>
11772
11773 PR tree-optimization/86847
11774 * tree-switch-conversion.c (switch_decision_tree::dump_case_nodes):
11775 Dump also subtree probability.
11776 (switch_decision_tree::do_jump_if_equal): New function.
11777 (switch_decision_tree::emit_case_nodes): Handle special
11778 situations in balanced tree that can be emitted much simpler.
11779 Fix calculation of probabilities that happen in tree expansion.
11780 * tree-switch-conversion.h (struct cluster): Add
11781 is_single_value_p.
11782 (struct simple_cluster): Likewise.
11783 (struct case_tree_node): Add new function has_child.
11784 (do_jump_if_equal): New.
11785
11786 2018-08-27 Martin Liska <mliska@suse.cz>
11787
11788 * tree-switch-conversion.c (bit_test_cluster::find_bit_tests):
11789 Add new argument to bit_test_cluster constructor.
11790 (bit_test_cluster::emit): Set bits really number of values
11791 handlel by a test.
11792 (bit_test_cluster::hoist_edge_and_branch_if_true): Add
11793 probability argument.
11794 * tree-switch-conversion.h (struct bit_test_cluster):
11795 Add m_handles_entire_switch.
11796
11797 2018-08-27 Martin Liska <mliska@suse.cz>
11798
11799 PR tree-optimization/86702
11800 * tree-switch-conversion.c (jump_table_cluster::emit):
11801 Make probabilities even for values in jump table
11802 according to number of cases handled.
11803 (switch_decision_tree::compute_cases_per_edge): Pass
11804 argument to reset_out_edges_aux function.
11805 (switch_decision_tree::analyze_switch_statement): Likewise.
11806 * tree-switch-conversion.h (switch_decision_tree::reset_out_edges_aux):
11807 Make it static.
11808
11809 2018-08-27 Martin Liska <mliska@suse.cz>
11810
11811 * cfgexpand.c (expand_asm_stmt): Use label_to_block and pass
11812 cfun argument explicitly.
11813 * gimple-pretty-print.c (dump_gimple_switch): Likewise.
11814 * hsa-gen.c (gen_hsa_insns_for_switch_stmt): Use new
11815 function gimple_switch_default_bb.
11816 (convert_switch_statements):
11817 (expand_builtins):
11818 * ipa-fnsummary.c (set_switch_stmt_execution_predicate):
11819 * stmt.c (label_to_block_fn): Use label_to_block and pass
11820 cfun argument explicitly and use gimple_switch_label_bb.
11821 (expand_case): Likewise.
11822 * tree-cfg.c (lower_phi_internal_fn): Use label_to_block and pass
11823 cfun argument explicitly. Likewise.
11824 (make_edges_bb): Likewise.
11825 (make_cond_expr_edges): Likewise.
11826 (get_cases_for_edge): Likewise.
11827 (make_gimple_switch_edges): Likewise.
11828 (label_to_block_fn): Likewise.
11829 (label_to_block): Likewise.
11830 (make_goto_expr_edges): Likewise.
11831 (make_gimple_asm_edges): Likewise.
11832 (main_block_label): Likewise.
11833 (group_case_labels_stmt): Likewise.
11834 (find_taken_edge_computed_goto): Likewise.
11835 (find_taken_edge_switch_expr): Likewise.
11836 (gimple_verify_flow_info): Likewise.
11837 (gimple_redirect_edge_and_branch): Likewise.
11838 (gimple_switch_label_bb): New function.
11839 (gimple_switch_default_bb): Likewise.
11840 (gimple_switch_edge): Likewise.
11841 (gimple_switch_default_edge): Likewise.
11842 * tree-cfg.h (label_to_block_fn): Remove and replace ...
11843 (label_to_block): ... with this.
11844 (gimple_switch_label_bb): New.
11845 (gimple_switch_default_bb): Likewise.
11846 (gimple_switch_edge): Likewise.
11847 (gimple_switch_default_edge): Likewise.
11848 * tree-cfgcleanup.c (convert_single_case_switch): Use
11849 new gimple functions and pass new argument to label_to_block.
11850 (cleanup_control_flow_bb):
11851 * tree-eh.c (make_eh_dispatch_edges): Use label_to_block and pass
11852 cfun argument explicitly.
11853 (make_eh_edges): Likewise.
11854 (redirect_eh_dispatch_edge): Likewise.
11855 (lower_resx): Likewise.
11856 (lower_eh_dispatch): Likewise.
11857 (maybe_remove_unreachable_handlers): Likewise.
11858 (unsplit_eh): Likewise.
11859 (cleanup_empty_eh): Likewise.
11860 (verify_eh_edges): Likewise.
11861 (verify_eh_dispatch_edge): Likewise.
11862 * tree-ssa-dom.c (record_edge_info): Likewise.
11863 * tree-ssa-forwprop.c (simplify_gimple_switch_label_vec): Likewise.
11864 * tree-ssa-threadedge.c (thread_around_empty_blocks): Likewise.
11865 (thread_through_normal_block): Likewise.
11866 * tree-ssa-uncprop.c (associate_equivalences_with_edges): Likewise.
11867 * tree-ssa-uninit.c (convert_control_dep_chain_into_preds):
11868 * tree-switch-conversion.c (switch_conversion::collect): Use new
11869 gimple functions.
11870 (switch_conversion::check_final_bb): Likewise.
11871 (switch_conversion::gather_default_values): Pass new argument
11872 to label_to_block.
11873 (switch_conversion::build_constructors): Likewise.
11874 (switch_decision_tree::compute_cases_per_edge): Use new
11875 gimple_switch_edge function.
11876 (switch_decision_tree::analyze_switch_statement): Pass new argument
11877 to label_to_block.
11878 (switch_decision_tree::try_switch_expansion): Use
11879 gimple_switch_default_edge.
11880 * tree-vrp.c (find_switch_asserts): Pass new argument
11881 to label_to_block.
11882 * vr-values.c (vr_values::vrp_visit_switch_stmt): Likewise.
11883 (vr_values::simplify_switch_using_ranges): Likewise.
11884
11885 2018-08-27 Richard Biener <rguenther@suse.de>
11886
11887 * cfganal.h (rev_post_order_and_mark_dfs_back_seme): Declare.
11888 * cfganal.c (rev_post_order_and_mark_dfs_back_seme): New function.
11889
11890 * tree-ssa-sccvn.h (struct vn_pval): New structure.
11891 (struct vn_nary_op_s): Add unwind_to member. Add
11892 predicated_values flag and put result into a union together
11893 with a linked list of vn_pval.
11894 (struct vn_ssa_aux): Add name member to make maintaining
11895 a map of SSA name to vn_ssa_aux possible. Remove no longer
11896 needed info, dfsnum, low, visited, on_sccstack, use_processed
11897 and range_info_anti_range_p members.
11898 (run_scc_vn, vn_eliminate, free_scc_vn, vn_valueize): Remove.
11899 (do_rpo_vn, run_rpo_vn, eliminate_with_rpo_vn, free_rpo_vn):
11900 New functions.
11901 (vn_valueize): New global.
11902 (vn_context_bb): Likewise.
11903 (VN_INFO_RANGE_INFO, VN_INFO_ANTI_RANGE_P, VN_INFO_RANGE_TYPE,
11904 VN_INFO_PTR_INFO): Remove.
11905 * tree-ssa-sccvn.c: ... (rewrite)
11906 (pass_fre::execute): For -O2+ initialize loops and run
11907 RPO VN in optimistic mode (iterating). For -O1 and -Og
11908 run RPO VN in non-optimistic mode.
11909 * params.def (PARAM_SCCVN_MAX_SCC_SIZE): Remove.
11910 (PARAM_RPO_VN_MAX_LOOP_DEPTH): Add.
11911 * doc/invoke.texi (sccvn-max-scc-size): Remove.
11912 (rpo-vn-max-loop-depth): Document.
11913 * tree-ssa-alias.c (walk_non_aliased_vuses): Stop walking
11914 when valuezing the VUSE signals we walked out of the region.
11915 * tree-ssa-pre.c (phi_translate_1): Ignore predicated values.
11916 (phi_translate): Set VN context block to use for availability
11917 lookup.
11918 (compute_avail): Likewise.
11919 (pre_valueize): New function.
11920 (pass_pre::execute): Adjust to the RPO VN API.
11921
11922 * tree-ssa-loop-ivcanon.c: Include tree-ssa-sccvn.h.
11923 (propagate_constants_for_unrolling): Remove.
11924 (tree_unroll_loops_completely): Perform value-numbering
11925 on the unrolled bodies loop parent.
11926
11927 2018-08-27 Richard Biener <rguenther@suse.de>
11928
11929 * tree-ssa-pre.c (compute_antic): Re-use inverted postorder
11930 for partial antic compute.
11931
11932 2018-08-27 Jakub Jelinek <jakub@redhat.com>
11933
11934 PR rtl-optimization/87065
11935 * combine.c (simplify_if_then_else): Formatting fix.
11936 (if_then_else_cond): Guard MULT optimization with SCALAR_INT_MODE_P
11937 check.
11938 (known_cond): Don't return const_true_rtx for vector modes. Use
11939 CONST0_RTX instead of const0_rtx. Formatting fixes.
11940
11941 2018-08-27 Martin Liska <mliska@suse.cz>
11942
11943 PR gcov-profile/87069
11944 * gcov.c (process_file): Record files already processed
11945 and warn about a file being processed multiple times.
11946
11947 2018-08-27 Martin Liska <mliska@suse.cz>
11948
11949 PR driver/83193
11950 * config/aarch64/aarch64.c (aarch64_override_options_internal):
11951 Set default values for x_aarch64_*_string strings.
11952 * config/aarch64/aarch64.opt: Remove --{march,mcpu,mtune}==
11953 prefix. For -mabi do not print '=ABI' in help and use
11954 <option_value> format for -msve-vector-bits and -moverride
11955 options.
11956
11957 2018-08-26 Jeff Law <law@redhat.com>
11958
11959 * config/mips/frame-header-opt.c: Include "backend.h" rather than
11960 "cfg.h"
11961
11962 2018-08-26 Marek Polacek <polacek@redhat.com>
11963
11964 PR c++/87029, Implement -Wredundant-move.
11965 * doc/invoke.texi: Document -Wredundant-move.
11966
11967 2018-08-25 Martin Sebor <msebor@redhat.com>
11968
11969 PR tree-optimization/87059
11970 * builtins.c (expand_builtin_strncmp): Convert MIN_EXPR operand
11971 to the same type as the other.
11972 * fold-const.c (fold_binary_loc): Assert expectation.
11973
11974 2018-08-25 Iain Sandoe <iain@sandoe.co.uk>
11975
11976 * config/darwin.c (machopic_legitimize_pic_address): Clean up
11977 extraneous parentheses, dead code section and formatting.
11978
11979 2018-08-24 David Malcolm <dmalcolm@redhat.com>
11980
11981 PR c++/87091
11982 * diagnostic-show-locus.c (layout::layout): Ensure the margin is
11983 wide enough for jumps in the line-numbering to be visible.
11984 (layout::print_gap_in_line_numbering): New member function.
11985 (layout::calculate_line_spans): When using line numbering, merge
11986 line spans that are only 1 line apart.
11987 (diagnostic_show_locus): When printing line numbers, show gaps in
11988 line numbering directly, rather than printing headers.
11989 (selftest::test_diagnostic_show_locus_fixit_lines): Add test of
11990 line-numbering with multiple line spans.
11991 (selftest::test_fixit_insert_containing_newline_2): Add test of
11992 line-numbering, in which the spans are close enough to be merged.
11993
11994 2018-08-24 Aldy Hernandez <aldyh@redhat.com>
11995
11996 * gimple-ssa-evrp-analyze.c (set_ssa_range_info): Pass value_range
11997 to range_includes_zero_p. Do not special case VR_ANTI_RANGE.
11998 * tree-vrp.c (range_is_nonnull): Remove.
11999 (range_includes_zero_p): Accept value_range instead of min/max.
12000 (extract_range_from_binary_expr_1): Do not early bail on
12001 POINTER_PLUS_EXPR.
12002 Use range_includes_zero_p instead of range_is_nonnull.
12003 (extract_range_from_unary_expr): Use range_includes_zero_p instead
12004 of range_is_nonnull.
12005 (vrp_meet_1): Pass value_range to range_includes_zero_p. Do not
12006 special case VR_ANTI_RANGE.
12007 (vrp_finalize): Same.
12008 * tree-vrp.h (range_includes_zero_p): Pass value_range as argument
12009 instead of min/max.
12010 (range_is_nonnull): Remove.
12011 * vr-values.c (vrp_stmt_computes_nonzero): Use
12012 range_includes_zero_p instead of range_is_nonnull.
12013 (extract_range_basic): Pass value_range to range_includes_zero_p
12014 instead of range_is_nonnull.
12015
12016 2018-08-24 Uros Bizjak <ubizjak@gmail.com>
12017
12018 * emit-rtl.c (init_emit_once): Do not emit MODE_POINTER_BOUNDS RTXes.
12019 * emit-rtl.h (rtl_data): Remove return_bnd.
12020 * explow.c (trunc_int_for_mode): Do not handle POINTER_BOUNDS_MODE_P.
12021 * function.c (diddle_return_value): Do not handle crtl->return_bnd.
12022 * genmodes.c (complete_mode): Do not handle MODE_POINTER_BOUNDS.
12023 (POINTER_BOUNDS_MODE): Remove definition.
12024 (make_pointer_bounds_mode): Remove.
12025 (get_mode_class): Do not handle MODE_POINTER_BOUNDS.
12026 * machmode.h (POINTER_BOUNDS_MODE_P): Remove definition.
12027 (scalare_mode::includes_p): Do not handle MODE_POINTER_BOUNDS.
12028 * mode-classes.def: Do not define MODE_POINTER_BOUNDS.
12029 * stor-layout.c (int_mode_for_mode): Do not handle MODE_POINTER_BOUNDS.
12030 * tree-core.h (enum tree_index): Remove TI_POINTER_BOUNDS_TYPE.
12031 * varasm.c (output_constant_pool_2): Do not handle MODE_POINTER_BOUNDS.
12032
12033 * config/i386/i386-modes.def (BND32, BND64): Remove.
12034 * config/i386/i386.c (dbx_register_map): Remove bound registers.
12035 (dbx64_register_map): Ditto.
12036 (svr4_dbx_register_map): Ditto.
12037 (indirect_thunk_bnd_needed): Remove.
12038 (indirect_thunks_bnd_used): Ditto.
12039 (indirect_return_bnd_needed): Ditto.
12040 (indirect_return_via_cx_bnd): Ditto.
12041 (enum indirect_thunk_prefix): Remove indirect_thunk_prefix_bnd.
12042 (indirect_thunk_name): Remove handling of indirect_thunk_prefix_bnd.
12043 (output_indirect_thunk): Ditto. Remove need_prefix argument.
12044 (output_indirect_thunk_function): Remove handling of
12045 indirect_return_bnd_needed, indirect_return_via_cx_bnd,
12046 indirect_thunk_bnd_needed and indirect_thunks_bnd_used variables.
12047 (ix86_save_reg): Remove handling of crtl->return_bnd.
12048 (ix86_legitimate_constant_p): Remove handling of POINTER_BOUNDS_MODE_P.
12049 (ix86_print_operand_address_as): Remove handling of UNSPEC_BNDMK_ADDR
12050 and UNSPEC_BNDLX_ADDR.
12051 (ix86_output_indirect_branch_via_reg): Remove handling of
12052 indirect_thunk_prefix_bnd.
12053 (ix86_output_indirect_branch_via_push): Ditto.
12054 (ix86_output_function_return): Ditto.
12055 (ix86_output_indirect_function_return): Ditto.
12056 (avoid_func_arg_motion): Do not handle UNSPEC_BNDSTX.
12057 * config/i386/i386.h (FIXED_REGISTERS): Remove bound registers.
12058 (CALL_USED_REGISTERS): Ditto.
12059 (REG_ALLOC_ORDER): Update for removal of bound registers.
12060 (HI_REGISTER_NAMES): Ditto.
12061 * config/i386/i386.md (UNSPEC_BNDMK, UNSPEC_BNDMK_ADDR, UNSPEC_BNDSTX)
12062 (UNSPEC_BNDLDX, UNSPEC_BNDLDX_ADDR, UNSPEC_BNDCL, UNSPEC_BNDCU)
12063 (UNSPEC_BNDCN, UNSPEC_MPX_FENCE): Remove.
12064 (BND0_REG, BND1_REG, BND2_REG, BND3_REG): Remove
12065 (FIRST_PSEUDO_REG): Update.
12066 (BND): Remove mode iterator.
12067 * config/i386/predicates.md (bnd_mem_operator): Remove.
12068
12069 2018-08-24 Richard Sandiford <richard.sandiford@arm.com>
12070
12071 * tree-vect-stmts.c (vectorizable_bswap): Handle variable-length
12072 vectors.
12073
12074 2018-08-24 Richard Sandiford <richard.sandiford@arm.com>
12075
12076 * tree-vect-slp.c (vect_transform_slp_perm_load): Separate out
12077 the case in which the permute needs only a single element and
12078 repeats for every vector of the result. Extend that case to
12079 handle variable-length vectors.
12080 * tree-vect-stmts.c (vectorizable_load): Update accordingly.
12081
12082 2018-08-24 H.J. Lu <hongjiu.lu@intel.com>
12083
12084 PR debug/79342
12085 * dwarf2out.c (save_macinfo_strings): Call set_indirect_string
12086 on DW_MACINFO_start_file for -gsplit-dwarf -g3.
12087
12088 2018-08-24 Richard Biener <rguenther@suse.de>
12089
12090 * cfg.h (struct control_flow_graph): Add edge_flags_allocated and
12091 bb_flags_allocated members.
12092 (auto_flag): New RAII class for allocating flags.
12093 (auto_edge_flag): New RAII class for allocating edge flags.
12094 (auto_bb_flag): New RAII class for allocating bb flags.
12095 * cfgloop.c (verify_loop_structure): Allocate temporary edge
12096 flag dynamically.
12097 * cfganal.c (dfs_enumerate_from): Remove use of visited sbitmap
12098 in favor of temporarily allocated BB flag.
12099 * hsa-brig.c: Re-order includes.
12100 * hsa-dump.c: Likewise.
12101 * hsa-regalloc.c: Likewise.
12102 * print-rtl.c: Likewise.
12103 * profile-count.c: Likewise.
12104
12105 2018-08-24 Segher Boessenkool <segher@kernel.crashing.org>
12106
12107 PR target/86989
12108 * config/rs6000/rs6000.c (toc_relative_expr_p): Check that the base is
12109 the TOC register.
12110
12111 2018-08-24 Aldy Hernandez <aldyh@redhat.com>
12112
12113 PR 87073/bootstrap
12114 * wide-int-range.cc (wide_int_range_div): Do not ignore result
12115 from wide_int_range_multiplicative_op.
12116
12117 2018-08-23 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
12118
12119 * tree-vect-data-refs.c (vect_grouped_store_supported): Fix typo
12120 "permutaion".
12121
12122 2018-08-23 Giuliano Belinassi <giuliano.belinassi@usp.br>
12123
12124 * genmatch.c (parser::parse_operation): Fix typo 'exapnded'
12125 to 'expanded'.
12126
12127 2018-08-23 Alexander Monakov <amonakov@ispras.ru>
12128
12129 * tree-scalar-evolution.c (final_value_replacement_loop): Dump
12130 full GENERIC expression used for replacement.
12131
12132 2018-08-23 Aldy Hernandez <aldyh@redhat.com>
12133
12134 * tree-vrp.c (abs_extent_range): Remove.
12135 (extract_range_into_wide_ints): Pass wide ints by reference.
12136 (extract_range_from_binary_expr_1): Rewrite the *DIV_EXPR code.
12137 Pass wide ints by reference in all calls to
12138 extract_range_into_wide_ints.
12139 * wide-int-range.cc (wide_int_range_div): New.
12140 * wide-int-range.h (wide_int_range_div): New.
12141 (wide_int_range_includes_zero_p): New.
12142 (wide_int_range_zero_p): New.
12143
12144 2018-08-23 Matthew Malcomson <matthew.malcomson@arm.com>
12145
12146 * config/aarch64/aarch64.md (arches): New enum.
12147 (arch): New enum attr.
12148 (arch_enabled): New attr.
12149 (enabled): Now uses arch_enabled only.
12150 (simd, sve, fp16): Removed attribute.
12151 (fp): Attr now defined in terms of 'arch'.
12152 (*mov<mode>_aarch64, *movsi_aarch64, *movdi_aarch64, *movti_aarch64,
12153 *movhf_aarch64, <optab><fcvt_target><GPF:mode>2,
12154 <FCVT_F2FIXED:fcvt_fixed_insn><GPF:mode>3,
12155 <FCVT_FIXED2F:fcvt_fixed_insn><GPI:mode>3): Merge 'fp' and 'simd'
12156 attributes into 'arch'.
12157 (*movsf_aarch64, *movdf_aarch64, *movtf_aarch64, *add<mode>3_aarch64,
12158 subdi3, neg<mode>2, <optab><mode>3, one_cmpl<mode>2,
12159 *<NLOGICAL:optab>_one_cmpl<mode>3, *xor_one_cmpl<mode>3,
12160 *aarch64_ashl_sisd_or_int_<mode>3, *aarch64_lshr_sisd_or_int_<mode>3,
12161 *aarch64_ashr_sisd_or_int_<mode>3, *aarch64_sisd_ushl): Convert use of
12162 'simd' attribute into 'arch'.
12163 (load_pair_sw_<SX:mode><SX2:mode>, load_pair_dw_<DX:mode><DX2:mode>,
12164 store_pair_sw_<SX:mode><SX2:mode>, store_pair_dw_<DX:mode><DX2:mode>):
12165 Convert use of 'fp' attribute to 'arch'.
12166 * config/aarch64/aarch64-simd.md (move_lo_quad_internal_<mode>,
12167 move_lo_quad_internal_<mode>): (different modes) Merge 'fp' and 'simd'
12168 into 'arch'.
12169 (move_lo_quad_internal_be_<mode>, move_lo_quad_internal_be_<mode>):
12170 (different modes) Merge 'fp' and 'simd' into 'arch'.
12171 (*aarch64_combinez<mode>, *aarch64_combinez_be<mode>): Merge 'fp' and
12172 'simd' into 'arch'.
12173
12174 2018-08-23 Segher Boessenkool <segher@kernel.crashing.org>
12175
12176 PR rtl-optimization/87026
12177 * expmed.c (canonicalize_comparison): If we can no longer create
12178 pseudoregisters, don't.
12179
12180 2018-08-23 Richard Earnshaw <rearnsha@arm.com>
12181
12182 PR target/86951
12183 * config/arm/arm-protos.h (arm_emit_speculation_barrier): New
12184 prototype.
12185 * config/arm/arm.c (speculation_barrier_libfunc): New static
12186 variable.
12187 (arm_init_libfuncs): Initialize it.
12188 (arm_emit_speculation_barrier): New function.
12189 * config/arm/arm.md (speculation_barrier): Call
12190 arm_emit_speculation_barrier for architectures that do not have
12191 DSB or ISB.
12192 (speculation_barrier_insn): Only match on Armv7 or later.
12193
12194 2018-08-23 Richard Biener <rguenther@suse.de>
12195
12196 PR middle-end/87024
12197 * tree-inline.c (copy_bb): Drop unused __builtin_va_arg_pack_len
12198 calls.
12199
12200 2018-08-23 Richard Sandiford <richard.sandiford@arm.com>
12201
12202 * config/aarch64/aarch64.c (aarch64_evpc_sve_tbl): Fix handling
12203 of single-vector TBLs.
12204 (aarch64_vectorize_vec_perm_const): Set one_vector_p when only
12205 one input is given.
12206
12207 2018-08-23 Richard Sandiford <richard.sandiford@arm.com>
12208
12209 PR target/85910
12210 * config/aarch64/aarch64.c (aarch64_expand_vec_perm_const_1): Fix
12211 aarch64_evpc_tbl guard.
12212
12213 2018-08-22 Bernd Edlinger <bernd.edlinger@hotmail.de>
12214
12215 * tree-ssa-dse.c (compute_trims): Avoid folding away undefined
12216 behaviour.
12217
12218 2018-08-22 Martin Sebor <msebor@redhat.com>
12219
12220 PR middle-end/87052
12221 * tree-pretty-print.c (pretty_print_string): Add argument.
12222 (dump_generic_node): Call to pretty_print_string with string size.
12223
12224 2018-08-22 Segher Boessenkool <segher@kernel.crashing.org>
12225
12226 PR rtl-optimization/86771
12227 * combine.c (try_combine): Do not allow splitting a resulting PARALLEL
12228 of two SETs into those two SETs, one to be placed at i2, if that SETs
12229 destination is modified between i2 and i3.
12230
12231 2018-08-22 Richard Sandiford <richard.sandiford@arm.com>
12232
12233 PR tree-optimization/86725
12234 * tree-vect-loop.c (vect_inner_phi_in_double_reduction_p): New
12235 function.
12236 (vect_analyze_scalar_cycles_1): Check it.
12237
12238 2018-08-22 Richard Sandiford <richard.sandiford@arm.com>
12239
12240 PR tree-optimization/86725
12241 * tree-vect-loop.c (vect_is_simple_reduction): When treating
12242 an outer loop phi as a double reduction, make sure that the
12243 single user of the phi result is an inner loop phi.
12244
12245 2018-08-22 Richard Sandiford <richard.sandiford@arm.com>
12246
12247 * tree-vect-data-refs.c (vect_analyze_group_access_1): Convert
12248 grouped stores with gaps to a strided group.
12249
12250 2018-08-22 Richard Sandiford <richard.sandiford@arm.com>
12251
12252 * tree-vect-stmts.c (get_group_load_store_type)
12253 (get_load_store_type): Only test STMT_VINFO_STRIDED_P for the
12254 first statement in a group.
12255
12256 2018-08-22 Iain Sandoe <iain@sandoe.co.uk>
12257
12258 * config/darwin.h (LINK_COMMAND_SPEC_A): Sync LTO options with
12259 the sequence used in gcc/gcc.c.
12260
12261 2018-08-22 Iain Sandoe <iain@sandoe.co.uk>
12262
12263 PR other/704
12264 * gcc-ar.c (main): Don’t try to invoke the plug-in if we’re not
12265 building it.
12266
12267 2018-08-22 Iain Sandoe <iain@sandoe.co.uk>
12268
12269 * config/darwin10.h (LINK_GCC_C_SEQUENCE_SPEC): Adjust to use the
12270 Darwin10-specific unwinder-shim.
12271 * config/darwin12.h (LINK_GCC_C_SEQUENCE_SPEC): Remove.
12272 * config/rs6000/darwin.h (DARWIN_CRT1_SPEC, DARWIN_DYLIB1_SPEC):
12273 New to cater for Darwin10 Rosetta.
12274
12275 2018-08-22 Iain Sandoe <iain@sandoe.co.uk>
12276
12277 * config/i386/i386.c (ix86_output_addr_diff_elt): Move the MACH-O
12278 specific test before the one for HAVE_AS_GOTOFF_IN_DATA.
12279
12280 2018-08-22 Iain Sandoe <iain@sandoe.co.uk>
12281
12282 PR bootstrap/81033
12283 PR target/81733
12284 PR target/52795
12285 * gcc/dwarf2out.c (FUNC_SECOND_SECT_LABEL): New.
12286 (dwarf2out_switch_text_section): Generate a local label for the
12287 second function sub-section and apply it as the second FDE start
12288 label.
12289 * gcc/final.c (final_scan_insn_1): Emit second FDE label after the
12290 second sub-section start.
12291
12292 2018-08-22 Richard Biener <rguenther@suse.de>
12293
12294 PR tree-optimization/86988
12295 * tree-vrp.c (vrp_prop::check_mem_ref): Bail out on VLAs.
12296
12297 2018-08-22 Richard Biener <rguenther@suse.de>
12298
12299 PR tree-optimization/86945
12300 * tree-cfg.c (generate_range_test): Use unsigned arithmetic.
12301
12302 2018-08-22 Alexandre Oliva <oliva@adacore.com>
12303
12304 * config/rs6000/rs6000.c (SMALL_DATA_RELOC, SMALL_DATA_REG): Add
12305 a comment about how uses of r2 for .sdata2 come about.
12306
12307 2018-08-22 Alexandre Oliva <aoliva@redhat.com>
12308
12309 * tree-ssa-reassoc.c (is_reassociable_op): Fix cut&pasto.
12310
12311 2018-08-21 Marek Polacek <polacek@redhat.com>
12312
12313 PR c++/86981, Implement -Wpessimizing-move.
12314 * doc/invoke.texi: Document -Wpessimizing-move.
12315
12316 2018-08-21 Jan Hubicka <jh@suse.cz>
12317
12318 * tree.c (find_decls_types_r): Do not check for redundant typedefs.
12319 * tree.h (is_redundant_typedef): Remove.
12320 * dwarf2out.c (is_redundant_typedef): Turn into static function.
12321
12322 2018-08-21 Jan Hubicka <jh@suse.cz>
12323
12324 * tree.c (free_lang_data_in_decl): Remove types from DECL_CONTEXT
12325 when possible.
12326
12327 2018-08-21 Tamar Christina <tamar.christina@arm.com>
12328
12329 * expmed.c (extract_low_bits): Reject invalid subregs early.
12330
12331 2018-08-21 Bernd Edlinger <bernd.edlinger@hotmail.de>
12332
12333 PR middle-end/86121
12334 * tree-ssa-strlen.c (adjust_last_stmt): Avoid folding away undefined
12335 behaviour.
12336
12337 2018-08-21 Rasmus Villemoes <rv@rasmusvillemoes.dk>
12338
12339 * config/vxworks.h: Guard vxworks_asm_out_constructor and
12340 vxworks_asm_out_destructor by !HAVE_INITFINI_ARRAY_SUPPORT
12341 * config/vxworks.c: Likewise.
12342
12343 2018-08-21 Rasmus Villemoes <rv@rasmusvillemoes.dk>
12344
12345 * config/vxworks.c: Set targetm.have_ctors_dtors
12346 if HAVE_INITFINI_ARRAY_SUPPORT.
12347 * config/vxworks.h: Set SUPPORTS_INIT_PRIORITY
12348 if HAVE_INITFINI_ARRAY_SUPPORT.
12349
12350 2018-08-21 Rasmus Villemoes <rv@rasmusvillemoes.dk>
12351
12352 * config/vxworks.h: Add $(WIND_BASE)/target/h/wrn/coreip to
12353 default search path for VxWorks < 7.
12354
12355 2018-08-21 Bernd Edlinger <bernd.edlinger@hotmail.de>
12356
12357 * gimple-ssa-sprintf.c (decl_constant_value): Remove.
12358 (get_format_string): Refer to c_getstr.
12359
12360 2018-08-21 Tom de Vries <tdevries@suse.de>
12361
12362 * cgraph.h (debuginfo_early_init, debuginfo_init, debuginfo_fini)
12363 (debuginfo_start, debuginfo_stop, debuginfo_early_start)
12364 (debuginfo_early_stop): Declare.
12365 * cgraphunit.c (debuginfo_early_init, debuginfo_init, debuginfo_fini)
12366 (debuginfo_start, debuginfo_stop, debuginfo_early_start)
12367 (debuginfo_early_stop): New function.
12368 (symbol_table::finalize_compilation_unit): Call debuginfo_early_start
12369 and debuginfo_early_stop.
12370 * dwarf2out.c (dwarf2out_finish, dwarf2out_early_finish): Dump dwarf.
12371 * toplev.c (compile_file): Call debuginfo_start and debuginfo_stop.
12372 (general_init): Call debuginfo_early_init.
12373 (finalize): Call debuginfo_fini.
12374 (do_compile): Call debuginfo_init.
12375 * doc/invoke.texi (@gccoptlist): Add -fdump-debug and
12376 -fdump-early-debug.
12377 (@item -fdump-debug, @item -fdump-earlydebug): Add.
12378
12379 2018-08-21 Tom de Vries <tdevries@suse.de>
12380
12381 * dwarf2out.c (print_dw_val, print_loc_descr, print_die): Handle
12382 flag_dump_noaddr and flag_dump_unnumbered.
12383
12384 2018-08-21 Aldy Hernandez <aldyh@redhat.com>
12385
12386 * wide-int-range.cc (wide_int_range_abs): New.
12387 (wide_int_range_order_set): Rename from wide_int_range_min_max.
12388 * wide-int-range.h (wide_int_range_abs): New.
12389 (wide_int_range_min_max): New.
12390 * tree-vrp.c (extract_range_from_unary_expr): Rewrite ABS_EXPR
12391 case to call wide_int_range_abs.
12392 Rewrite MIN/MAX_EXPR to call wide_int_range_min_max.
12393 (extract_range_from_abs_expr): Delete.
12394
12395 2018-08-20 Michael Meissner <meissner@linux.ibm.com>
12396
12397 PR target/87033
12398 * config/rs6000/rs6000.md (extendsi<mode>2): Change constraints
12399 from 'Y' to 'YZ' to enable the LWAX instruction to be generated
12400 for indexed loads.
12401
12402 2018-08-20 Nathan Sidwell <nathan@acm.org>
12403 Jeff Law <law@redhat.com>
12404
12405 * config/s390/s390-c (s390_macro_to_expand): Use cpp_macro_p.
12406 * config/spu/spu-c.c (spu_macro_to_expand): Likewise.
12407
12408 2018-08-20 David Malcolm <dmalcolm@redhat.com>
12409
12410 PR other/84889
12411 * attribs.c (diag_attr_exclusions): Add auto_diagnostic_group instance.
12412 (decl_attributes): Likewise.
12413 * calls.c (maybe_warn_nonstring_arg): Add auto_diagnostic_group
12414 instance.
12415 * cgraphunit.c (maybe_diag_incompatible_alias): Likewise.
12416 * diagnostic-core.h (class auto_diagnostic_group): New class.
12417 * diagnostic.c (diagnostic_initialize): Initialize the new fields.
12418 (diagnostic_report_diagnostic): Handle the first diagnostics within
12419 a group.
12420 (emit_diagnostic): Add auto_diagnostic_group instance.
12421 (inform): Likewise.
12422 (inform_n): Likewise.
12423 (warning): Likewise.
12424 (warning_at): Likewise.
12425 (warning_n): Likewise.
12426 (pedwarn): Likewise.
12427 (permerror): Likewise.
12428 (error): Likewise.
12429 (error_n): Likewise.
12430 (error_at): Likewise.
12431 (sorry): Likewise.
12432 (fatal_error): Likewise.
12433 (internal_error): Likewise.
12434 (internal_error_no_backtrace): Likewise.
12435 (auto_diagnostic_group::auto_diagnostic_group): New ctor.
12436 (auto_diagnostic_group::~auto_diagnostic_group): New dtor.
12437 * diagnostic.h (struct diagnostic_context): Add fields
12438 "diagnostic_group_nesting_depth",
12439 "diagnostic_group_emission_count", "begin_group_cb",
12440 "end_group_cb".
12441 * gimple-ssa-isolate-paths.c (find_implicit_erroneous_behavior):
12442 Add auto_diagnostic_group instance(s).
12443 (find_explicit_erroneous_behavior): Likewise.
12444 * gimple-ssa-warn-alloca.c (pass_walloca::execute): Likewise.
12445 * gimple-ssa-warn-restrict.c (maybe_diag_offset_bounds): Likewise.
12446 * gimplify.c (warn_implicit_fallthrough_r): Likewise.
12447 (gimplify_va_arg_expr): Likewise.
12448 * hsa-gen.c (HSA_SORRY_ATV): Likewise.
12449 (HSA_SORRY_AT): Likewise.
12450 * ipa-devirt.c (compare_virtual_tables): Likewise.
12451 (warn_odr): Likewise.
12452 * multiple_target.c (expand_target_clones): Likewise.
12453 * opts-common.c (cmdline_handle_error): Likewise.
12454 * reginfo.c (globalize_reg): Likewise.
12455 * substring-locations.c (format_warning_n_va): Likewise.
12456 * tree-inline.c (expand_call_inline): Likewise.
12457 * tree-ssa-ccp.c (pass_post_ipa_warn::execute): Likewise.
12458 * tree-ssa-loop-niter.c
12459 (do_warn_aggressive_loop_optimizations): Likewise.
12460 * tree-ssa-uninit.c (warn_uninit): Likewise.
12461 * tree.c (warn_deprecated_use): Likewise.
12462
12463 2018-08-20 H.J. Lu <hongjiu.lu@intel.com>
12464
12465 PR target/87014
12466 * config/i386/i386.md (eh_return): Always update EH return
12467 address in word_mode.
12468
12469 2018-08-20 Chung-Lin Tang <cltang@codesourcery.com>
12470
12471 * targhooks.c (std_gimplify_va_arg_expr): Properly handle case of when
12472 TARGET_SPLIT_COMPLEX_ARG is defined.
12473
12474 2018-08-20 Bernd Edlinger <bernd.edlinger@hotmail.de>
12475
12476 * expr.c (store_field): Change gcc_assert to gcc_checking_assert.
12477
12478 2018-08-20 Bernd Edlinger <bernd.edlinger@hotmail.de>
12479
12480 PR target/86984
12481 * expr.c (expand_assignment): Assert that bitpos is positive.
12482 (store_field): Likewise
12483 (expand_expr_real_1): Make sure that bitpos is positive.
12484 * config/alpha/alpha.h (CONSTANT_ADDRESS_P): Avoid signed
12485 integer overflow.
12486
12487 2018-08-20 Nathan Sidwell <nathan@acm.org>
12488
12489 * Makefile.in (CPP_ID_DATA_H): Delete.
12490 (CPP_INTERNAL_H): Don't add it.
12491 (GTFILES): Replace CPP_ID_DATA_H with CPPLIB_H.
12492 * gengtype.c (open_base_files): Replace cpp-id-data.h with cpplib.h
12493
12494 2018-08-20 Richard Biener <rguenther@suse.de>
12495
12496 PR tree-optimization/78655
12497 * tree-vrp.c (extract_range_from_binary_expr_1): Make
12498 pointer + offset nonnull if either operand is nonnull work.
12499
12500 2018-08-20 Tom de Vries <tdevries@suse.de>
12501
12502 * dwarf2out.c (add_scalar_info): Don't add reference to existing die
12503 unless the referenced die describes the added property using
12504 DW_AT_location or DW_AT_const_value. Fall back to exprloc case.
12505 Otherwise, add a DW_AT_location to the referenced die.
12506
12507 2018-08-19 Uros Bizjak <ubizjak@gmail.com>
12508
12509 PR target/86994
12510 * config/i386/i386.c (ix86_rtx_costs) [case SET]: Check source for
12511 register_operand when calling ix86_set_reg_reg_cost.
12512 [case CONST_INT, case CONST, case LABEL_REF, case SYMBOL_REF]:
12513 Set *total to 0 for operands that satisfy x86_64_immediate_operand
12514 predicate and to 1 otherwise.
12515
12516 2018-08-18 Iain Sandoe <iain@sandoe.co.uk>
12517
12518 * config/darwin.c (darwin_override_options): If -gsplit-dwarf is set,
12519 emit a diagnostic that it is not supported and reset the option.
12520 * config/darwin.h (DRIVER_SELF_SPECS): Note that gsplit-dwarf is not
12521 supported and consume the option. (ASM_FINAL_SPEC): New.
12522
12523 2018-08-17 Segher Boessenkool <segher@kernel.crashing.org>
12524
12525 * doc/md.texi (Patterns): Use @ref instead of @xref in the middle of
12526 a sentence.
12527
12528 2018-08-17 Sandra Loosemore <sandra@codesourcery.com>
12529
12530 C-SKY port: Documentation
12531
12532 * doc/extend.texi (C-SKY Function Attributes): New section.
12533 * doc/invoke.texi (Option Summary): Add C-SKY options.
12534 (C-SKY Options): New section.
12535 * doc/md.texi (Machine Constraints): Document C-SKY constraints.
12536
12537 2018-08-17 Jojo <jijie_rong@c-sky.com>
12538 Huibin Wang <huibin_wang@c-sky.com>
12539 Sandra Loosemore <sandra@codesourcery.com>
12540 Chung-Lin Tang <cltang@codesourcery.com>
12541
12542 C-SKY port: Backend implementation
12543
12544 * config/csky/*: New.
12545 * common/config/csky/*: New.
12546
12547 2018-08-17 Jojo <jijie_rong@c-sky.com>
12548 Huibin Wang <huibin_wang@c-sky.com>
12549 Sandra Loosemore <sandra@codesourcery.com>
12550 Chung-Lin Tang <cltang@codesourcery.com>
12551 Andrew Jenner <andrew@codesourcery.com>
12552
12553 C-SKY port: Configury
12554
12555 * config.gcc (csky-*-*): New.
12556 * configure.ac: Add csky to targets for dwarf2 debug_line support.
12557 * configure: Regenerated.
12558
12559 2018-08-17 David Malcolm <dmalcolm@redhat.com>
12560
12561 * dump-context.h: Include "dumpfile.h".
12562 (dump_context::dump_printf_va): Convert final param from va_list
12563 to va_list *. Convert from ATTRIBUTE_PRINTF to
12564 ATTRIBUTE_GCC_DUMP_PRINTF.
12565 (dump_context::dump_printf_loc_va): Likewise.
12566 * dumpfile.c: Include "stringpool.h".
12567 (make_item_for_dump_printf_va): Delete.
12568 (make_item_for_dump_printf): Delete.
12569 (class dump_pretty_printer): New class.
12570 (dump_pretty_printer::dump_pretty_printer): New ctor.
12571 (dump_pretty_printer::emit_items): New member function.
12572 (dump_pretty_printer::emit_any_pending_textual_chunks): New member
12573 function.
12574 (dump_pretty_printer::emit_item): New member function.
12575 (dump_pretty_printer::stash_item): New member function.
12576 (dump_pretty_printer::format_decoder_cb): New member function.
12577 (dump_pretty_printer::decode_format): New member function.
12578 (dump_context::dump_printf_va): Reimplement in terms of
12579 dump_pretty_printer.
12580 (dump_context::dump_printf_loc_va): Convert final param from va_list
12581 to va_list *.
12582 (dump_context::begin_scope): Reimplement call to
12583 make_item_for_dump_printf.
12584 (dump_printf): Update for change to dump_printf_va.
12585 (dump_printf_loc): Likewise.
12586 (selftest::test_capture_of_dump_calls): Convert "stmt" from
12587 greturn * to gimple *. Add a test_decl. Add tests of dump_printf
12588 with %T, %E, and %G.
12589 * dumpfile.h (ATTRIBUTE_GCC_DUMP_PRINTF): New macro.
12590 (dump_printf): Replace ATTRIBUTE_PRINTF_2 with
12591 ATTRIBUTE_GCC_DUMP_PRINTF (2, 3).
12592 (dump_printf_loc): Replace ATTRIBUTE_PRINTF_3 with
12593 ATTRIBUTE_GCC_DUMP_PRINTF (3, 0).
12594 * tree-vect-data-refs.c (vect_lanes_optab_supported_p): Convert
12595 use of HOST_WIDE_INT_PRINT_DEC on unsigned HOST_WIDE_INT "count"
12596 within a dump_printf_loc call to "%wu".
12597 (vector_alignment_reachable_p): Merge two dump_printf[_loc] calls,
12598 converting a use of HOST_WIDE_INT_PRINT_DEC to "%wd". Add a
12599 missing space after "=".
12600 * tree-vect-loop.c (vect_analyze_loop_2) Within a dump_printf
12601 call, convert use of HOST_WIDE_INT_PRINT_DEC to "%wd".
12602 * tree-vect-slp.c (vect_slp_bb): Within a dump_printf_loc call,
12603 convert use of HOST_WIDE_INT_PRINT_UNSIGNED to "%wu".
12604 * tree-vectorizer.c (try_vectorize_loop_1): Likewise. Remove
12605 duplicate "vectorized" from message.
12606
12607 2018-08-17 Szabolcs Nagy <szabolcs.nagy@arm.com>
12608
12609 * config/arm/arm-builtins.c (arm_init_simd_builtin_types): Clear
12610 polyNxK_t element's TYPE_STRING_FLAG.
12611
12612 2018-08-17 Segher Boessenkool <segher@kernel.crashing.org>
12613
12614 * config/rs6000/rs6000.md (*cbranch, *creturn): Name these patterns
12615 (they were unnamed before). Fix comments.
12616
12617 2018-08-17 Nathan Sidwell <nathan@acm.org>
12618
12619 * cppbuiltin.c: Include "cpplib.h", not "cpp-id-data.h".
12620
12621 2018-08-17 Richard Biener <rguenther@suse.de>
12622
12623 PR tree-optimization/86841
12624 * wide-int-range.cc (wide_int_range_lshift): Use to_uhwi.
12625
12626 2018-08-17 Martin Liska <mliska@suse.cz>
12627
12628 * common.opt: Remove Warn, Init and Report for options with
12629 Ignore/Deprecated flag. Warning is done automatically for
12630 Deprecated flags.
12631 * config/i386/i386.opt: Likewise.
12632 * config/ia64/ia64.opt: Likewise.
12633 * config/rs6000/rs6000.opt: Likewise.
12634 * cppbuiltin.c (define_builtin_macros_for_compilation_flags):
12635 Remove usage of flag_check_pointer_bounds.
12636 * lto-wrapper.c (merge_and_complain): Do not handle
12637 OPT_fcheck_pointer_bounds.
12638 (append_compiler_options): Likewise.
12639 * opt-functions.awk: Do not handle Deprecated.
12640 * optc-gen.awk: Check that Var, Report and Init are not
12641 used for an option with Ignore/Deprecated flag.
12642 * opts-common.c (decode_cmdline_option): Do not report
12643 CL_ERR_DEPRECATED.
12644 (read_cmdline_option): Report warning for OPT_SPECIAL_deprecated
12645 options.
12646 * opts.h (struct cl_option): Remove cl_deprecated flag.
12647 (CL_ERR_DEPRECATED): Remove error enum value.
12648
12649 2018-08-17 Richard Biener <rguenther@suse.de>
12650
12651 PR middle-end/86505
12652 * tree-inline.c (copy_bb): When inlining __builtin_va_arg_pack_len ()
12653 across a va-arg-pack using call adjust its return value accordingly.
12654
12655 2018-08-16 Martin Sebor <msebor@redhat.com>
12656
12657 PR tree-optimization/86853
12658 * gimple-ssa-sprintf.c (struct format_result): Rename member.
12659 (struct fmtresult): Add member and initialize it in ctors.
12660 (format_character): Handle %C. Extend range to NUL. Set MAYFAIL.
12661 (format_string): Handle %S the same as %ls. Set MAYFAIL.
12662 (format_directive): Set POSUNDER4K when MAYFAIL is set.
12663 (parse_directive): Handle %C same as %c.
12664 (sprintf_dom_walker::compute_format_length): Adjust.
12665 (is_call_safe): Adjust.
12666
12667 2018-08-16 Bernd Edlinger <bernd.edlinger@hotmail.de>
12668
12669 * builtins.c (c_strlen): Add new parameter eltsize. Use it
12670 for determining how to count the elements.
12671 * builtins.h (c_strlen): Adjust prototype.
12672 * expr.c (string_constant): Add new parameter mem_size.
12673 Set *mem_size appropriately.
12674 * expr.h (string_constant): Adjust protoype.
12675 * gimple-fold.c (get_range_strlen): Add new parameter eltsize.
12676 * gimple-fold.h (get_range_strlen): Adjust prototype.
12677 * gimple-ssa-sprintf.c (get_string_length): Add new parameter eltsize.
12678 (format_string): Call get_string_length with eltsize.
12679
12680 2018-08-16 David Malcolm <dmalcolm@redhat.com>
12681
12682 * diagnostic.c (default_diagnostic_start_span_fn): Call pp_string
12683 to emit the span, rather than setting it as the prefix.
12684
12685 2018-08-16 David Malcolm <dmalcolm@redhat.com>
12686
12687 * diagnostic-show-locus.c (layout::start_annotation_line): Add
12688 "margin_char" parameter, defaulting to space. Use it in place
12689 of pp_space for the initial part of the margin.
12690 (layout::print_leading_fixits): Use '+' when filling the margin
12691 of line-insertion fix-it hints.
12692
12693 2018-08-16 Segher Boessenkool <segher@kernel.crashing.org>
12694
12695 * config/rs6000/rs6000.md (two unnamed define_insn and define_split):
12696 Delete.
12697
12698 2018-08-16 Segher Boessenkool <segher@kernel.crashing.org>
12699
12700 * config/rs6000/altivec.md: Don't set length attribute to the default
12701 value.
12702 * config/rs6000/darwin.md: Ditto.
12703 * config/rs6000/dfp.md: Ditto.
12704 * config/rs6000/htm.md: Ditto.
12705 * config/rs6000/rs6000.md: Ditto.
12706 * config/rs6000/sync.md: Ditto.
12707 * config/rs6000/vsx.md: Ditto.
12708
12709 2018-08-16 Segher Boessenkool <segher@kernel.crashing.org>
12710
12711 * config/rs6000/altivec.md: Don't set length attribute to the default
12712 value, for branch instructions.
12713 * config/rs6000/darwin.md: Ditto.
12714 * config/rs6000/rs6000.md: Ditto.
12715
12716 2018-08-16 Segher Boessenkool <segher@kernel.crashing.org>
12717
12718 * config/rs6000/rs6000.md (length): Always define as const_int 4.
12719 (unnamed conditional branch define_insn): Set length to 4 or 8
12720 depending on offset.
12721 (<bd>_<mode>): Similar, for alternative 0.
12722 (<bd>tf_<mode>): Ditto.
12723
12724 2018-08-16 Tamar Christina <tamar.christina@arm.com>
12725
12726 * expr.c (copy_blkmode_to_reg): Perform larger copies when safe.
12727
12728 2018-08-16 Matthew Malcomson <matthew.malcomson@arm.com>
12729
12730 * doc/rtl.texi: Replace old RTX class names with new names.
12731
12732
12733 2018-08-16 Vlad Lazar <vlad.lazar@arm.com>
12734
12735 * expmed.h (canonicalize_comparison): New declaration.
12736 * expmed.c (canonicalize_comparison, equivalent_cmp_code): New function.
12737 * expmed.c (emit_store_flag_1): Add call to canonicalize_comparison.
12738 * optabs.c (prepare_cmp_insn): Likewise.
12739 * rtl.h (unsigned_condition_p): New function which checks if a
12740 comparison operator is unsigned.
12741
12742 2018-08-16 Nathan Sidwell <nathan@acm.org>
12743
12744 * config/rs6000/rs6000-c.c (rs6000_macro_to_expend): Use cpp_macro_p.
12745 * config/powerpcspc/powerpcspe-c.c (rs6000_macro_to_expend): Likewise.
12746
12747 2018-08-16 Tamar Christina <tamar.christina@arm.com>
12748
12749 PR target/84711
12750 * config/arm/arm.c (arm_can_change_mode_class): Disallow subreg.
12751 * config/arm/neon.md (movv4hf, movv8hf): Refactored to..
12752 (mov<mov>): ..this and enable unconditionally.
12753
12754 2018-08-16 Tamar Christina <tamar.christina@arm.com>
12755
12756 * config/arm/neon.md (*neon_mov<mode>): Remove reg-to-reg alternative.
12757
12758 2018-08-16 Sam Tebbs <sam.tebbs@arm.com>
12759
12760 * config/aarch64/aarch64.opt (mlow-precision-recip-sqrt)
12761 (mlow-precision-sqrt, mlow-precision-div, mverbose-cost-dump): Replace
12762 "Common" with "Target".
12763
12764 2018-08-15 Uros Bizjak <ubizjak@gmail.com>
12765
12766 * config/i386/i386.opt (mmitigate-rop): Mark as deprecated.
12767 * doc/invoke.texi (mmitigate-rop): Remove.
12768 * config/i386/i386.c: Do not include "regrename.h".
12769 (ix86_rop_should_change_byte_p, reg_encoded_number)
12770 (ix86_get_modrm_for_rop, set_rop_modrm_reg_bits, ix86_mitigate_rop):
12771 Remove.
12772 (ix86_reorg): Remove call to ix86_mitigate_rop.
12773 * config/i386/i386.md (attr "modrm_class"): Remove.
12774 (cmp<mode>_ccno_1, mov<mode>_xor, movstrict<mode>_xor)
12775 (x86_mov<mode>cc_0_m1. x86_mov<mode>cc_0_m1_se)
12776 (x86_mov<mode>cc_0_m1_neg): Remove modrm_class attribute override.
12777
12778 2018-08-15 Will Schmidt <will_schmidt@vnet.ibm.com>
12779
12780 * config/rs6000/rs600.c (rs6000_gimple_fold_builtin): Add entries to
12781 allow folding of mergeh() and mergel() for the float and double types.
12782 (fold_mergehl_helper): Rework to handle building a permute tree
12783 for float vectors.
12784
12785 2018-08-15 Uros Bizjak <ubizjak@gmail.com>
12786
12787 * config/i386/i386.c (expand_vec_perm_movs): Enable V4SFmode
12788 for TARGET_SSE.
12789
12790 2018-08-15 David Malcolm <dmalcolm@redhat.com>
12791
12792 * common.opt (fdiagnostics-show-labels): New option.
12793 * diagnostic-show-locus.c (class layout_range): Add field
12794 "m_label".
12795 (class layout): Add field "m_show_labels_p".
12796 (layout_range::layout_range): Add param "label" and use it to
12797 initialize m_label.
12798 (make_range): Pass in NULL for new "label" param of layout_range's
12799 ctor.
12800 (layout::layout): Initialize m_show_labels_p.
12801 (layout::maybe_add_location_range): Pass in loc_range->m_label
12802 when constructing layout_range instances.
12803 (struct line_label): New struct.
12804 (layout::print_any_labels): New member function.
12805 (layout::print_line): Call it if label-printing is enabled.
12806 (selftest::test_one_liner_labels): New test.
12807 (selftest::test_diagnostic_show_locus_one_liner): Call it.
12808 * diagnostic.c (diagnostic_initialize): Initialize
12809 context->show_labels_p.
12810 * diagnostic.h (struct diagnostic_context): Add field
12811 "show_labels_p".
12812 * doc/invoke.texi (Diagnostic Message Formatting Options): Add
12813 -fno-diagnostics-show-labels.
12814 * dwarf2out.c (gen_producer_string): Add
12815 OPT_fdiagnostics_show_labels to the ignored options.
12816 * gcc-rich-location.c (gcc_rich_location::add_expr): Add "label"
12817 param.
12818 (gcc_rich_location::maybe_add_expr): Likewise.
12819 * gcc-rich-location.h (gcc_rich_location::gcc_rich_location): Add
12820 label" param, defaulting to NULL.
12821 (gcc_rich_location::add_expr): Add "label" param.
12822 (gcc_rich_location::maybe_add_expr): Likewise.
12823 (class text_range_label): New class.
12824 (class range_label_for_type_mismatch): New class.
12825 * gimple-ssa-sprintf.c (fmtwarn): Pass NULL for new label params
12826 of format_warning_va.
12827 (fmtwarn_n): Likewise for new params of format_warning_n_va.
12828 * lto-wrapper.c (merge_and_complain): Add
12829 OPT_fdiagnostics_show_labels to the "pick one setting" options.
12830 (append_compiler_options): Likewise to the dropped options.
12831 (append_diag_options): Likewise to the passed-on options.
12832 * opts.c (common_handle_option): Handle the new option.
12833 * selftest-diagnostic.c
12834 (test_diagnostic_context::test_diagnostic_context): Enable
12835 show_labels_p.
12836 * substring-locations.c: Include "gcc-rich-location.h".
12837 (format_warning_n_va): Add "fmt_label" and "param_label" params
12838 and use them as appropriate.
12839 (format_warning_va): Add "fmt_label" and "param_label" params,
12840 passing them on to format_warning_n_va.
12841 (format_warning_at_substring): Likewise.
12842 (format_warning_at_substring_n): Likewise.
12843 * substring-locations.h (format_warning_va): Add "fmt_label" and
12844 "param_label" params.
12845 (format_warning_n_va): Likewise.
12846 (format_warning_at_substring): Likewise.
12847 (format_warning_at_substring_n): Likewise.
12848 * toplev.c (general_init): Initialize global_dc->show_labels_p.
12849
12850 2018-08-15 Qing Zhao <qing.zhao@oracle.com>
12851
12852 PR testsuite/86519
12853 * builtins.c (expand_builtin_memcmp): Do not expand the call
12854 when overflow is detected.
12855
12856 2018-08-15 Martin Sebor <msebor@redhat.com>
12857
12858 PR tree-optimization/71625
12859 * config/aarch64/aarch64-builtins.c
12860 (aarch64_init_simd_builtin_types): Clear Poly8_t's TYPE_STRING_FLAG.
12861
12862 2018-08-15 Ilya Leoshkevich <iii@linux.ibm.com>
12863
12864 * config/s390/s390.c (s390_reorg): Remove loop.
12865
12866 2018-08-15 Iain Sandoe <iain@sandoe.co.uk>
12867
12868 * config/darwin.c
12869 (darwin_function_switched_text_sections): Delete.
12870 * gcc/config/darwin.h
12871 (TARGET_ASM_FUNCTION_SWITCHED_TEXT_SECTIONS): Likewise.
12872
12873 2018-08-15 Iain Sandoe <iain@sandoe.co.uk>
12874
12875 PR target/81685
12876 * config/darwin.h: (DEBUG_STR_OFFSETS_SECTION, DEBUG_LOCLISTS_SECTION,
12877 DEBUG_RNGLISTS_SECTION) new macros. (DEBUG_PUBNAMES_SECTION,
12878 DEBUG_PUBTYPES_SECTION) update to include GNU variant.
12879
12880 2018-08-15 Martin Liska <mliska@suse.cz>
12881
12882 PR tree-optimization/86925
12883 * predict.c (expr_expected_value_1): When taking
12884 later predictor, assign also probability.
12885 Use fold_build2_initializer_loc in order to fold
12886 the expression in -frounding-math.
12887
12888 2018-08-14 Allan Sandfeld Jensen <allan.jensen@qt.io>
12889
12890 * config/i386/i386.c (expand_vec_perm_movs): New method matching movs
12891 patterns.
12892 (expand_vec_perm_1): Try the new method.
12893
12894 2018-08-14 Ilya Leoshkevich <iii@linux.ibm.com>
12895
12896 PR target/86547
12897 * lra-lives.c (remove_some_program_points_and_update_live_ranges):
12898 Check whether lra_live_max_point is 0 before dividing.
12899
12900 2018-08-14 Martin Sebor <msebor@redhat.com>
12901
12902 PR tree-optimization/86650
12903 * tree-vrp.c (vrp_prop::check_array_ref): Print an inform message.
12904 (vrp_prop::check_mem_ref): Same.
12905
12906 2018-08-13 Liu Hao <lh_mouse@126.com>
12907
12908 * pretty-print.c (eat_esc_sequence): Swap the foreground and
12909 background colors if the COMMON_LVB_REVERSE_VIDEO flag is set,
12910 and clear it thereafter, as it only works for DBCS.
12911
12912 2018-08-13 Liu Hao <lh_mouse@126.com>
12913
12914 * pretty-print.c (mingw_ansi_fputs): Do not call _close() on the
12915 handle returned by _get_osf_handle().
12916
12917 2018-08-13 Will Schmidt <will_schmidt@vnet.ibm.com>
12918
12919 * gcc/config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Add support
12920 for folding vec_perm.
12921
12922 2018-08-13 Will Schmidt <will_schmidt@vnet.ibm.com>
12923
12924 * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin):
12925 Add support for gimple-folding of vec_pack() and vec_unpack()
12926 intrinsics.
12927
12928 2018-08-13 Will Schmidt <will_schmidt@vnet.ibm.com>
12929
12930 * config/rs6000/rs6000.c (rs6000_builtin_valid_without_lhs): Add
12931 vec_xst variants to the list.
12932 (rs6000_gimple_fold_builtin): Add support for folding unaligned
12933 vector loads and stores.
12934
12935 2018-08-13 David Edelsohn <dje.gcc@gmail.com>
12936
12937 * config.gcc (rs6000-ibm-aix4.x): Delete.
12938 (rs6000-ibm-aix5.1): Delete.
12939 (rs6000-ibm-aix5.2): Delete.
12940 (rs6000-ibm-aix5.3): Delete.
12941 * config/rs6000/aix43.h: Delete.
12942 * config/rs6000/aix51.h: Delete.
12943 * config/rs6000/aix52.h: Delete.
12944 * config/rs6000/t-aix43: Delete.
12945
12946 2018-08-13 Ilya Leoshkevich <iii@linux.ibm.com>
12947
12948 * config/s390/s390.c (s390_decompose_constant_pool_ref):
12949 New function.
12950 (s390_decompose_address): Factor out constant pool ref
12951 decomposition.
12952
12953 2018-08-12 Chung-Ju Wu <jasonwucj@gmail.com>
12954
12955 * config/nds32/nds32-predicates.c
12956 (nds32_can_use_bclr_p): Change return type as bool.
12957 (nds32_can_use_bset_p): Ditto.
12958 (nds32_can_use_btgl_p): Ditto.
12959 (nds32_can_use_bitci_p): Ditto.
12960 * config/nds32/nds32-protos.h
12961 (nds32_can_use_bclr_p): Change declaration.
12962 (nds32_can_use_bset_p): Ditto.
12963 (nds32_can_use_btgl_p): Ditto.
12964 (nds32_can_use_bitci_p): Ditto.
12965
12966 2018-08-12 Chung-Ju Wu <jasonwucj@gmail.com>
12967
12968 * config/nds32/nds32.c (nds32_expand_prologue, nds32_expand_epilogue):
12969 Support -msched-prolog-epilog option.
12970 * config/nds32/nds32.opt (msched-prolog-epilog): New option.
12971
12972 2018-08-12 Chung-Ju Wu <jasonwucj@gmail.com>
12973
12974 * common/config/nds32/nds32-common.c
12975 (nds32_option_optimization_table): Enalbe -malways-align.
12976
12977 2018-08-12 Chung-Ju Wu <jasonwucj@gmail.com>
12978
12979 * config.gcc (nds32*): Add nds32_isr.h and nds32_init.inc in
12980 extra_headers.
12981 * common/config/nds32/nds32-common.c (nds32_handle_option): Handle
12982 OPT_misr_secure_ case.
12983 * config/nds32/nds32-isr.c: Implementation of backward compatibility.
12984 * config/nds32/nds32-protos.h (nds32_isr_function_critical_p): New.
12985 * config/nds32/nds32.c (nds32_attribute_table): Add critical and
12986 secure attribute.
12987 * config/nds32/nds32.h (nds32_isr_nested_type): Add NDS32_CRITICAL.
12988 (nds32_isr_info): New field security_level.
12989 (TARGET_ISR_VECTOR_SIZE_4_BYTE): New macro.
12990 * config/nds32/nds32.md (return_internal): Consider critical attribute.
12991 * config/nds32/nds32.opt (misr-secure): New option.
12992 * config/nds32/nds32_init.inc: New file.
12993 * config/nds32/nds32_isr.h: New file.
12994
12995 2018-08-11 John David Anglin <danglin@gcc.gnu.org>
12996
12997 * config/pa/pa.md (UNSPEC_MEMORY_BARRIER): New unspec enum.
12998 Update comment for atomic instructions.
12999 (atomic_storeqi, atomic_storehi, atomic_storesi, atomic_storesf,
13000 atomic_loaddf, atomic_loaddf_1, atomic_storedf, atomic_storedf_1):
13001 Remove.
13002 (atomic_loaddi): Revise fence expansion to only emit fence prior to
13003 load for __ATOMIC_SEQ_CST model.
13004 (atomic_loaddi_1): Remove float register target.
13005 (atomic_storedi): Handle CONST_INT values.
13006 (atomic_storedi_1): Remove float register source. Add special case
13007 for zero value.
13008 (memory_barrier): New expander and insn.
13009
13010 2018-08-11 Jakub Jelinek <jakub@redhat.com>
13011
13012 PR tree-optimization/86835
13013 * tree-ssa-math-opts.c (insert_reciprocals): Even when inserting
13014 new_stmt after def_gsi, make sure to insert new_square_stmt after
13015 that stmt, not 2 stmts before it.
13016
13017 2018-08-10 Alexander Monakov <amonakov@ispras.ru>
13018
13019 PR target/82418
13020 * config/i386/i386.md (<s>mul<mode>3_highpart): Use DWIH mode iterator
13021 instead of SWI48.
13022
13023 2018-08-10 Martin Liska <mliska@suse.cz>
13024
13025 PR target/83610
13026 * builtin-types.def (BT_FN_LONG_LONG_LONG_DOUBLE): Add new
13027 function type.
13028 * builtins.c (expand_builtin_expect_with_probability):
13029 New function.
13030 (expand_builtin_expect_with_probability): New function.
13031 (build_builtin_expect_predicate): Add new argumnet probability
13032 for BUILT_IN_EXPECT_WITH_PROBABILITY.
13033 (fold_builtin_expect):
13034 (fold_builtin_2):
13035 (fold_builtin_3):
13036 * builtins.def (BUILT_IN_EXPECT_WITH_PROBABILITY):
13037 * builtins.h (fold_builtin_expect): Set new argument.
13038 * doc/extend.texi: Document __builtin_expect_with_probability.
13039 * doc/invoke.texi: Likewise.
13040 * gimple-fold.c (gimple_fold_call): Pass new argument.
13041 * ipa-fnsummary.c (find_foldable_builtin_expect): Handle
13042 also BUILT_IN_EXPECT_WITH_PROBABILITY.
13043 * predict.c (get_predictor_value): New function.
13044 (expr_expected_value): Add new argument probability. Assume
13045 that predictor and probability are always non-null.
13046 (expr_expected_value_1): Likewise. For __builtin_expect and
13047 __builtin_expect_with_probability set probability. Handle
13048 combination in binary expressions.
13049 (tree_predict_by_opcode): Simplify code by simply calling
13050 get_predictor_value.
13051 (pass_strip_predict_hints::execute): Add handling of
13052 BUILT_IN_EXPECT_WITH_PROBABILITY.
13053 * predict.def (PRED_BUILTIN_EXPECT_WITH_PROBABILITY): Add
13054 new predictor.
13055 * tree.h (DECL_BUILT_IN_P): New function.
13056
13057 2018-08-10 Martin Liska <mliska@suse.cz>
13058
13059 PR tree-optimization/85799
13060 * passes.def: Add argument for pass_strip_predict_hints.
13061 * predict.c (class pass_strip_predict_hints): Add new argument
13062 early_p.
13063 (strip_predictor_early): New function.
13064 (pass_strip_predict_hints::execute): Call the function to
13065 strip predictors.
13066 (strip_predict_hints): New function.
13067 * predict.def: Fix comment.
13068
13069 2018-08-10 Thomas Preud'homme <thomas.preudhomme@linaro.org>
13070
13071 * Makefile.in: Clarify which tm.texi to copy over to assert the
13072 right to grant a GFDL license for all.
13073
13074 2018-08-09 Jeff Law <law@redhat.com>
13075
13076 * config/m68k/m68k.c (m68k_adjust_decorated_operand): Remove
13077 unused variable.
13078
13079 2018-08-09 Andreas Schwab <schwab@linux-m68k.org>
13080
13081 * config/m68k/m68k-protos.h (m68k_final_prescan_insn): Remove
13082 prototype.
13083
13084 2018-08-09 Richard Sandiford <richard.sandiford@arm.com>
13085
13086 * tree-vect-loop.c (vectorizable_reduction): Allow inner-loop
13087 reductions for variable-length vectors.
13088
13089 2018-08-09 David Malcolm <dmalcolm@redhat.com>
13090
13091 PR other/84889
13092 * common.opt (fdiagnostics-show-line-numbers): New option.
13093 * diagnostic-show-locus.c (class layout): Add fields
13094 "m_show_line_numbers_p" and "m_linenum_width";
13095 (num_digits): New function.
13096 (test_num_digits): New function.
13097 (layout::layout): Initialize new fields. Update m_x_offset
13098 logic to handle any left margin.
13099 (layout::print_source_line): Print line number when requested.
13100 (layout::start_annotation_line): New member function.
13101 (layout::print_annotation_line): Call it.
13102 (layout::print_leading_fixits): Likewise.
13103 (layout::print_trailing_fixits): Likewise. Update calls to
13104 move_to_column for new parameter.
13105 (layout::get_x_bound_for_row): Add "add_left_margin" param and use
13106 it to potentially call start_annotation_line.
13107 (layout::show_ruler): Call start_annotation_line.
13108 (selftest::test_line_numbers_multiline_range): New selftest.
13109 (selftest::diagnostic_show_locus_c_tests): Call test_num_digits
13110 and selftest::test_line_numbers_multiline_range.
13111 * diagnostic.c (diagnostic_initialize): Initialize
13112 show_line_numbers_p.
13113 * diagnostic.h (struct diagnostic_context): Add field
13114 "show_line_numbers_p".
13115 * doc/invoke.texi (Diagnostic Message Formatting Options): Add
13116 -fno-diagnostics-show-line-numbers.
13117 * dwarf2out.c (gen_producer_string): Add
13118 OPT_fdiagnostics_show_line_numbers to the ignored options.
13119 * lto-wrapper.c (merge_and_complain): Likewise to the "pick
13120 one setting" options.
13121 (append_compiler_options): Likewise to the dropped options.
13122 (append_diag_options): Likewise to the passed-on options.
13123 * opts.c (common_handle_option): Handle the new option.
13124 * toplev.c (general_init): Set up global_dc->show_line_numbers_p.
13125
13126 2018-08-09 Kelvin Nilsen <kelvin@gcc.gnu.org>
13127
13128 * doc/extend.texi (PowerPC AltiVec Built-in Functions Available on
13129 ISA 2.07): Correct spelling of bcdsub to be __builtin_bcdsub. Add
13130 third argument of type "const signed char" to descriptions of
13131 __builtin_bcdadd, __builtin_bcdadd_lt, __builtin_bcdadd_eq,
13132 __builtin_bcdadd_gt, __builtin_bcdadd_ov, __builtin_bcdsub,
13133 __builtin_bcdsub_lt, __builtin_bcdsub_eq, __builtin_bcdsub_gt,
13134 __builtin_bcdsub_ov functions.
13135
13136 2018-08-09 Richard Sandiford <richard.sandiford@arm.com>
13137
13138 PR tree-optimization/86858
13139 * tree-vect-loop.c (vect_is_simple_reduction): Restore
13140 flow_bb_inside_loop_p calls.
13141
13142 2018-08-09 Richard Sandiford <richard.sandiford@arm.com>
13143
13144 PR tree-optimization/86871
13145 * tree-vect-stmts.c (vect_transform_stmt): Use gimple_get_lhs
13146 instead of gimple_assign_lhs.
13147
13148 2018-08-09 Richard Earnshaw <rearnsha@arm.com>
13149
13150 PR target/86887
13151 * config/aarch64/aarch64.md (add<mode>3_carryinC_zero): Add missing
13152 register constraint to operand 0.
13153 (add<mode>3_carryinC): Likewise.
13154 (add<mode>3_carryinV_zero, add<mode>3_carryinV): Likewise.
13155
13156 2018-08-09 Martin Liska <mliska@suse.cz>
13157
13158 PR c/86895
13159 * common.opt: Remove extra line.
13160
13161 2018-08-09 Martin Liska <mliska@suse.cz>
13162
13163 * params.def (PARAM_ALIGN_LOOP_ITERATIONS): Remove double dots
13164 at the end of a line, make first letter capital and end up
13165 a sentence with a dot.
13166 (PARAM_LOOP_INTERCHANGE_STRIDE_RATIO): Likewise.
13167 (PARAM_LOOP_BLOCK_TILE_SIZE): Likewise.
13168 (PARAM_GRAPHITE_MAX_NB_SCOP_PARAMS): Likewise.
13169 (PARAM_GRAPHITE_MAX_ARRAYS_PER_SCOP): Likewise.
13170 (PARAM_MAX_ISL_OPERATIONS): Likewise.
13171 (PARAM_GRAPHITE_ALLOW_CODEGEN_ERRORS): Likewise.
13172 (PARAM_PROFILE_FUNC_INTERNAL_ID): Likewise.
13173 (PARAM_INDIR_CALL_TOPN_PROFILE): Likewise.
13174 (PARAM_SLP_MAX_INSNS_IN_BB): Likewise.
13175 (PARAM_IPA_CP_EVAL_THRESHOLD): Likewise.
13176 (PARAM_IPA_CP_RECURSION_PENALTY): Likewise.
13177 (PARAM_IPA_CP_SINGLE_CALL_PENALTY): Likewise.
13178 (PARAM_IPA_CP_LOOP_HINT_BONUS): Likewise.
13179 (PARAM_IPA_CP_ARRAY_INDEX_HINT_BONUS): Likewise.
13180 (PARAM_TREE_REASSOC_WIDTH): Likewise.
13181 (PARAM_HSA_GEN_DEBUG_STORES): Likewise.
13182 (PARAM_MAX_SPECULATIVE_DEVIRT_MAYDEFS): Likewise.
13183 (PARAM_MAX_VRP_SWITCH_ASSERTIONS): Likewise.
13184
13185 2018-08-09 Andreas Krebbel <krebbel@linux.ibm.com>
13186
13187 PR target/84332
13188 * config/s390/s390.c (s390_option_override_internal): Reduce the
13189 stack-clash-protection-probe-interval param if it would be too big
13190 for z900.
13191
13192 2018-08-08 Andreas Schwab <schwab@linux-m68k.org>
13193
13194 PR target/46179
13195 * config/m68k/m68k.h (FINAL_PRESCAN_INSN): Don't define.
13196 * config/m68k/m68k.c (handle_move_double): Don't call
13197 m68k_final_prescan_insn.
13198 (m68k_adjust_decorated_operand): Renamed from
13199 m68k_final_prescan_insn, remove first and third operand and
13200 simplify.
13201 (print_operand): Call it.
13202 (print_operand_address): Call it.
13203
13204 2018-08-08 Nathan Sidwell <nathan@acm.org>
13205
13206 * diagnostic.c (diagnostic_report_current_module): Use
13207 linemap_included_from & linemap_included_from_linemap.
13208
13209 2018-08-08 Hongbo Zhang <hongbo.zhang@linaro.org>
13210
13211 * config/aarch64/aarch64-cores.def: Add phecda core.
13212 * config/aarch64/aarch64-tune.md: Regenerate.
13213 * doc/invoke.texi: Add phecda core.
13214
13215 2018-08-08 Andreas Krebbel <krebbel@linux.ibm.com>
13216
13217 PR target/85295
13218 * config/s390/constraints.md ("NxHD0", "NxSD0"): New constraint
13219 definitions.
13220 * config/s390/s390.md ("movti"): Add more alternatives for
13221 constant to GPR copies.
13222
13223 2018-08-08 Andreas Krebbel <krebbel@linux.ibm.com>
13224
13225 * config/s390/s390.c: Fix whitespace damage throughout the file.
13226 * config/s390/s390.h: Likewise.
13227 * config/s390/tpf.h: Likewise.
13228
13229 2018-08-08 Ilya Leoshkevich <iii@linux.ibm.com>
13230
13231 * config/s390/s390.c (s390_loadrelative_operand_p):
13232 Remove TARGET_CPU_ZARCH usages.
13233 (s390_rtx_costs): Likewise.
13234 (s390_legitimate_constant_p): Likewise.
13235 (s390_cannot_force_const_mem): Likewise.
13236 (legitimate_reload_constant_p): Likewise.
13237 (s390_preferred_reload_class): Likewise.
13238 (legitimize_pic_address): Likewise.
13239 (legitimize_tls_address): Likewise.
13240 (s390_split_branches): Removed.
13241 (s390_add_execute): Removed.
13242 (s390_dump_pool): Remove TARGET_CPU_ZARCH usages.
13243 (s390_mainpool_start): Likewise.
13244 (s390_mainpool_finish): Likewise.
13245 (s390_mainpool_cancel): Removed.
13246 (s390_chunkify_start): Remove TARGET_CPU_ZARCH usages.
13247 (s390_chunkify_cancel): Likewise.
13248 (s390_return_addr_rtx): Likewise.
13249 (s390_register_info): Remove split_branches_pending_p uages.
13250 (s390_optimize_register_info): Likewise.
13251 (s390_init_frame_layout): Remove TARGET_CPU_ZARCH and
13252 split_branches_pending_p usages.
13253 (s390_can_eliminate): Remove TARGET_CPU_ZARCH usages.
13254 (s390_load_got): Likewise.
13255 (s390_expand_split_stack_prologue): Likewise.
13256 (output_asm_nops): Likewise.
13257 (s390_function_profiler): Likewise.
13258 (s390_emit_call): Likewise.
13259 (s390_conditional_register_usage): Likewise.
13260 (s390_optimize_prologue): Likewise.
13261 (s390_reorg): Remove TARGET_CPU_ZARCH and
13262 split_branches_pending_p usages.
13263 (s390_option_override_internal): Remove TARGET_CPU_ZARCH
13264 usages.
13265 (s390_output_indirect_thunk_function): Likewise.
13266 * config/s390/s390.h (TARGET_CPU_ZARCH): Removed.
13267 (TARGET_CPU_ZARCH_P): Removed.
13268 (struct machine_function): Remove split_branches_pending_p.
13269 * config/s390/s390.md: Remove TARGET_CPU_ZARCH usages.
13270
13271 2018-08-08 Ilya Leoshkevich <iii@linux.ibm.com>
13272
13273 * common/config/s390/s390-common.c (processor_flags_table):
13274 Remove flags.
13275 * config.gcc: Remove with_arch/with_tune support.
13276 * config/s390/2064.md: Remove cpu attribute comparisons.
13277 * config/s390/driver-native.c (s390_host_detect_local_cpu):
13278 Remove MTN.
13279 * config/s390/linux.h (ASM_SPEC):
13280 Remove -march support.
13281 * config/s390/s390-c.c (s390_cpu_cpp_builtins_internal):
13282 Use a table to get an arch level.
13283 * config/s390/s390-opts.h (enum processor_type):
13284 Remove enum values.
13285 * config/s390/s390.c
13286 (processor_table): Remove entries, add arch_level values.
13287 (s390_issue_rate): Remove cases.
13288 (s390_option_override): Adjust
13289 s390_option_override_internal() call.
13290 (s390_option_override_internal): Remove deprecation warning.
13291 (s390_valid_target_attribute_tree): Adjust
13292 s390_option_override_internal() call.
13293 * config/s390/s390.h (struct s390_processor):
13294 Share with s390-c.c, add arch_level field.
13295 * config/s390/s390.md:
13296 Remove occurrences in cpu attribute.
13297 * config/s390/s390.opt: Remove -march/-mtune support.
13298 * config/s390/tpf.h (ASM_SPEC): Remove -march support.
13299 * doc/invoke.texi: Remove deprecation warning.
13300
13301 2018-08-08 Luis Machado <luis.machado@linaro.org>
13302
13303 * config/aarch64/aarch64.c (qdf24xx_vector_cost): New static
13304 global.
13305 (qdf24xx_tunings): Set vector cost structure to
13306 qdf24xx_vector_cost.
13307
13308 * config/aarch64/aarch64.c (qdf24xx_addrcost_table)
13309 <register_sextend>: Set to 3.
13310
13311 2018-08-07 Richard Sandiford <richard.sandiford@arm.com>
13312
13313 PR target/86838
13314 * config/aarch64/iterators.md (FRECP, frecp_suffix): Delete.
13315 * config/aarch64/aarch64-simd.md
13316 (aarch64_frecp<FRECP:frecp_suffix><mode>): Fold FRECPE into...
13317 (@aarch64_frecpe<mode>): ...here and the move FRECPX to...
13318 (aarch64_frecpx<mode>): ...this new pattern.
13319 * config/aarch64/aarch64-simd-builtins.def: Remove comment
13320 about aarch64_frecp<FRECP:frecp_suffix><mode>.
13321
13322 2018-08-07 Martin Liska <mliska@suse.cz>
13323
13324 PR middle-end/83023
13325 * predict.c (expr_expected_value_1): Handle DECL_IS_MALLOC,
13326 BUILT_IN_REALLOC and DECL_IS_OPERATOR_NEW.
13327 * predict.def (PRED_MALLOC_NONNULL): New predictor.
13328 * doc/extend.texi: Document that malloc attribute adds
13329 hit to compiler.
13330
13331 2018-08-06 John David Anglin <danglin@gcc.gnu.org>
13332
13333 PR target/86785
13334 * config/pa/pa.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
13335 Define to speculation_safe_value_not_needed.
13336
13337 2018-08-06 Jeff Law <law@redhat.com>
13338
13339 * tree-ssa-dom.c (dom_opt_dom_walker::optimize_stmt): Pass down
13340 the vr_values instance to cprop_into_stmt.
13341 (cprop_into_stmt): Pass vr_values instance down to cprop_operand.
13342 (cprop_operand): Also query EVRP to determine if OP is a constant.
13343
13344 2018-08-06 Nathan Sidwell <nathan@acm.org>
13345
13346 * diagnostic.c (diagnostic_report_current_module): Reroll
13347 included-at loop. Translate text.
13348
13349 2018-08-06 David Malcolm <dmalcolm@redhat.com>
13350
13351 * function-tests.c (selftest::test_expansion_to_rtl): Call
13352 free_after_compilation.
13353
13354 2018-08-06 Alan Hayward <alan.hayward@arm.com>
13355
13356 * config/aarch64/aarch64.md: Add clobber highs to tls_desc.
13357
13358 2018-08-06 Andreas Krebbel <krebbel@linux.ibm.com>
13359
13360 * config/s390/s390.c (s390_loop_unroll_adjust): Prevent small
13361 loops with memory block operations from getting unrolled.
13362
13363 2018-08-06 Ulrich Weigand <uweigand@de.ibm.com>
13364
13365 PR target/86807
13366 * config/spu/spu.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
13367 Define to speculation_safe_value_not_needed.
13368
13369 2018-08-06 Jeff Law <law@redhat.com>
13370
13371 * reload1.c (forget_old_reloads_1): Adjust CLOBBER_HIGH
13372 assert.
13373
13374 2018-08-06 Jozef Lawrynowicz <jozef.l@mittosystems.com>
13375
13376 PR target/86662
13377 * gcc/tree.c (build_common_tree_nodes): Initialize integer_types array
13378 with all enabled __intN types.
13379
13380 * gcc/testsuite/gcc.target/msp430/pr86662.c: New test.
13381
13382 2018-08-06 Alan Hayward <alan.hayward@arm.com>
13383
13384 * alias.c (record_set): Check for clobber high.
13385 * cfgexpand.c (expand_gimple_stmt): Likewise.
13386 * combine-stack-adj.c (single_set_for_csa): Likewise.
13387 * combine.c (find_single_use_1): Likewise.
13388 (set_nonzero_bits_and_sign_copies): Likewise.
13389 (get_combine_src_dest): Likewise.
13390 (is_parallel_of_n_reg_sets): Likewise.
13391 (try_combine): Likewise.
13392 (record_dead_and_set_regs_1): Likewise.
13393 (reg_dead_at_p_1): Likewise.
13394 (reg_dead_at_p): Likewise.
13395 * dce.c (deletable_insn_p): Likewise.
13396 (mark_nonreg_stores_1): Likewise.
13397 (mark_nonreg_stores_2): Likewise.
13398 * df-scan.c (df_find_hard_reg_defs): Likewise.
13399 (df_uses_record): Likewise.
13400 (df_get_call_refs): Likewise.
13401 * dwarf2out.c (mem_loc_descriptor): Likewise.
13402 * haifa-sched.c (haifa_classify_rtx): Likewise.
13403 * ira-build.c (create_insn_allocnos): Likewise.
13404 * ira-costs.c (scan_one_insn): Likewise.
13405 * ira.c (equiv_init_movable_p): Likewise.
13406 (rtx_moveable_p): Likewise.
13407 (interesting_dest_for_shprep): Likewise.
13408 * jump.c (mark_jump_label_1): Likewise.
13409 * postreload-gcse.c (record_opr_changes): Likewise.
13410 * postreload.c (reload_cse_simplify): Likewise.
13411 (struct reg_use): Add source expr.
13412 (reload_combine): Check for clobber high.
13413 (reload_combine_note_use): Likewise.
13414 (reload_cse_move2add): Likewise.
13415 (move2add_note_store): Likewise.
13416 * print-rtl.c (print_pattern): Likewise.
13417 * recog.c (decode_asm_operands): Likewise.
13418 (store_data_bypass_p): Likewise.
13419 (if_test_bypass_p): Likewise.
13420 * regcprop.c (kill_clobbered_value): Likewise.
13421 (kill_set_value): Likewise.
13422 * reginfo.c (reg_scan_mark_refs): Likewise.
13423 * reload1.c (maybe_fix_stack_asms): Likewise.
13424 (eliminate_regs_1): Likewise.
13425 (elimination_effects): Likewise.
13426 (mark_not_eliminable): Likewise.
13427 (scan_paradoxical_subregs): Likewise.
13428 (forget_old_reloads_1): Likewise.
13429 * reorg.c (find_end_label): Likewise.
13430 (try_merge_delay_insns): Likewise.
13431 (redundant_insn): Likewise.
13432 (own_thread_p): Likewise.
13433 (fill_simple_delay_slots): Likewise.
13434 (fill_slots_from_thread): Likewise.
13435 (dbr_schedule): Likewise.
13436 * resource.c (update_live_status): Likewise.
13437 (mark_referenced_resources): Likewise.
13438 (mark_set_resources): Likewise.
13439 * rtl.c (copy_rtx): Likewise.
13440 * rtlanal.c (reg_referenced_p): Likewise.
13441 (single_set_2): Likewise.
13442 (noop_move_p): Likewise.
13443 (note_stores): Likewise.
13444 * sched-deps.c (sched_analyze_reg): Likewise.
13445 (sched_analyze_insn): Likewise.
13446
13447 2018-08-06 Alan Hayward <alan.hayward@arm.com>
13448
13449 * cse.c (invalidate_reg): New function extracted from...
13450 (invalidate): ...here.
13451 (canonicalize_insn): Check for clobber high.
13452 (invalidate_from_clobbers): invalidate clobber highs.
13453 (invalidate_from_sets_and_clobbers): Likewise.
13454 (count_reg_usage): Check for clobber high.
13455 (insn_live_p): Likewise.
13456 * cselib.c (cselib_expand_value_rtx_1):Likewise.
13457 (cselib_invalidate_regno): Check for clobber in setter.
13458 (cselib_invalidate_rtx): Pass through setter.
13459 (cselib_invalidate_rtx_note_stores):
13460 (cselib_process_insn): Check for clobber high.
13461 * cselib.h (cselib_invalidate_rtx): Add operand.
13462
13463 2018-08-06 Alan Hayward <alan.hayward@arm.com>
13464
13465 * lra-eliminations.c (lra_eliminate_regs_1): Check for clobber high.
13466 (mark_not_eliminable): Likewise.
13467 * lra-int.h (struct lra_insn_reg): Add clobber high marker.
13468 * lra-lives.c (process_bb_lives): Check for clobber high.
13469 * lra.c (new_insn_reg): Remember clobber highs.
13470 (collect_non_operand_hard_regs): Check for clobber high.
13471 (lra_set_insn_recog_data): Likewise.
13472 (add_regs_to_insn_regno_info): Likewise.
13473 (lra_update_insn_regno_info): Likewise.
13474
13475 2018-08-06 Alan Hayward <alan.hayward@arm.com>
13476
13477 * rtl.h (reg_is_clobbered_by_clobber_high): Add declarations.
13478 * rtlanal.c (reg_is_clobbered_by_clobber_high): Add function.
13479
13480 2018-08-06 Alan Hayward <alan.hayward@arm.com>
13481
13482 * emit-rtl.c (verify_rtx_sharing): Check for CLOBBER_HIGH.
13483 (copy_insn_1): Likewise.
13484 (gen_hard_reg_clobber_high): New gen function.
13485 * genconfig.c (walk_insn_part): Check for CLOBBER_HIGH.
13486 * genemit.c (gen_exp): Likewise.
13487 (gen_emit_seq): Pass through info.
13488 (gen_insn): Check for CLOBBER_HIGH.
13489 (gen_expand): Pass through info.
13490 (gen_split): Likewise.
13491 (output_add_clobbers): Likewise.
13492 * genrecog.c (validate_pattern): Check for CLOBBER_HIGH.
13493 (remove_clobbers): Likewise.
13494 * rtl.h (gen_hard_reg_clobber_high): New declaration.
13495
13496 2018-08-06 Alan Hayward <alan.hayward@arm.com>
13497
13498 * doc/rtl.texi (clobber_high): Add.
13499 (parallel): Add in clobber high
13500 * rtl.c (rtl_check_failed_code3): Add function.
13501 * rtl.def (CLOBBER_HIGH): Add expression.
13502 * rtl.h (RTL_CHECKC3): Add macro.
13503 (rtl_check_failed_code3): Add declaration.
13504 (XC3EXP): Add macro.
13505
13506 2018-08-05 H.J. Lu <hongjiu.lu@intel.com>
13507
13508 PR target/86386
13509 * config/i386/i386.c (ix86_finalize_stack_frame_flags): Set
13510 cfun->machine->max_used_stack_alignment if needed.
13511
13512 2018-08-04 Martin Sebor <msebor@redhat.com>
13513
13514 PR tree-optimization/86571
13515 * gimple-ssa-sprintf.c (format_floating): Extend upper bound of
13516 NaN output to 4.
13517
13518 2018-08-03 Sandra Loosemore <sandra@codesourcery.com>
13519
13520 PR target/86799
13521 * config/nios2/nios2.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
13522 Define.
13523
13524 2018-08-03 Jeff Law <law@redhat.com>
13525
13526 PR target/86795
13527 * config/mn10300/mn10300.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
13528 Define to speculation_safe_value_not_needed.
13529
13530 2018-08-03 David Malcolm <dmalcolm@redhat.com>
13531
13532 * doc/gcov.texi (-x): Remove duplicate "to".
13533 * doc/invoke.texi (-Wnoexcept-type): Remove duplicate "calls".
13534 (-Wif-not-aligned): Remove duplicate "is".
13535 (-flto): Remove duplicate "the".
13536 (MicroBlaze Options): In examples of "-mcpu=cpu-type", remove
13537 duplicate "v5.00.b".
13538 (MSP430 Options): Remove duplicate "and" from the description
13539 of "-mgprel-sec=regexp".
13540 (x86 Options): Remove duplicate copies of "vmldLog102" and
13541 vmlsLog104 from description of "-mveclibabi=type".
13542
13543 2018-08-03 Richard Sandiford <richard.sandiford@arm.com>
13544
13545 * internal-fn.h (first_commutative_argument): Declare.
13546 * internal-fn.c (first_commutative_argument): New function.
13547 * tree-vect-slp.c (vect_get_and_check_slp_defs): Remove extra
13548 restrictions for pattern statements. Use first_commutative_argument
13549 to look for commutative operands in calls to internal functions.
13550
13551 2018-08-03 Aldy Hernandez <aldyh@redhat.com>
13552
13553 * Makefile.in (wide-int-range.o): New.
13554 * tree-vrp.c: Move all the wide_int_* functions to...
13555 * wide-int-range.cc: ...here.
13556 * tree-vrp.h: Move all the wide_int_* prototypes to...
13557 * wide-int-range.h: ...here.
13558
13559 2018-08-03 Tom de Vries <tdevries@suse.de>
13560
13561 * common/config/nvptx/nvptx-common.c (nvptx_except_unwind_info): Return
13562 UI_NONE.
13563 * config/nvptx/nvptx.c (TARGET_ASM_BYTE_OP): Remove define.
13564 * except.c (output_function_exception_table): Do early exit if
13565 targetm_common.except_unwind_info (&global_options) == UI_NONE.
13566
13567 2018-08-03 Martin Liska <mliska@suse.cz>
13568
13569 * predict.c (dump_prediction): Change to 2 digits
13570 in fraction part.
13571
13572 2018-08-03 Siddhesh Poyarekar <siddhesh@sourceware.org>
13573
13574 * config/aarch64/falkor.md (falkor_am_1_vxvy_vxvy): Move
13575 neon_dup_q to...
13576 (falkor_am_1_gtov_gtov): ... a new insn reservation.
13577
13578 2018-07-19 Ilya Leoshkevich <iii@linux.ibm.com>
13579
13580 * config/nds32/nds32.c (nds32_hard_regno_mode_ok): Replace > with >=.
13581 * df-problems.c (df_remove_dead_eq_notes): Replace > with >=.
13582 * dwarf2out.c (mem_loc_descriptor): Replace > with >=.
13583 * lra-constraints.c (spill_hard_reg_in_range): Replace <= with <.
13584 * lra-remat.c (call_used_input_regno_present_p): Replace <= with <.
13585
13586 2018-08-02 David Malcolm <dmalcolm@redhat.com>
13587
13588 * diagnostic-show-locus.c (diagnostic_show_locus): Use
13589 pp_take_prefix when saving the existing prefix.
13590 * diagnostic.c (diagnostic_append_note): Likewise.
13591 * langhooks.c (lhd_print_error_function): Likewise.
13592 * pretty-print.c (pp_set_prefix): Drop the "const" from "prefix"
13593 param's type. Free the existing prefix.
13594 (pp_take_prefix): New function.
13595 (pretty_printer::pretty_printer): Drop the prefix parameter.
13596 Rename the length parameter to match the comment.
13597 (pretty_printer::~pretty_printer): Free the prefix.
13598 * pretty-print.h (pretty_printer::pretty_printer): Drop the prefix
13599 parameter.
13600 (struct pretty_printer): Drop the "const" from "prefix" field's
13601 type and clarify memory management.
13602 (pp_set_prefix): Drop the "const" from the 2nd param.
13603 (pp_take_prefix): New decl.
13604
13605 2018-08-02 Aaron Sawdey <acsawdey@linux.ibm.com>
13606
13607 * config/rs6000/rs6000-string.c (select_block_compare_mode): Move test
13608 for word_mode_ok here instead of passing as argument.
13609 (expand_block_compare): Change select_block_compare_mode() call.
13610 (expand_strncmp_gpr_sequence): New function.
13611 (expand_strn_compare): Make use of expand_strncmp_gpr_sequence.
13612
13613 2018-08-02 Jeff Law <law@redhat.com>
13614
13615 PR target/86790
13616 * config/m68k/m68k.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
13617 Define to speculation_safe_value_not_needed.
13618
13619 PR target/86784
13620 * config/h8300/h8300.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
13621 Define to speculation_safe_value_not_needed.
13622
13623 2018-08-02 Tom de Vries <tdevries@suse.de>
13624
13625 PR target/86660
13626 * common/config/nvptx/nvptx-common.c (nvptx_except_unwind_info): New
13627 function. Return UI_TARGET unconditionally.
13628 (TARGET_EXCEPT_UNWIND_INFO): Redefine to nvptx_except_unwind_info.
13629 * config/nvptx/nvptx.c (TARGET_ASM_BYTE_OP): Emit commented out '.byte'.
13630
13631 2018-08-02 Richard Sandiford <richard.sandiford@arm.com>
13632
13633 * genemit.c (print_overload_test): Fix typo.
13634
13635 2018-08-02 Richard Biener <rguenther@suse.de>
13636
13637 PR tree-optimization/86816
13638 * tree-ssa-tail-merge.c (tail_merge_valueize): New function
13639 which checks for value availability before querying it.
13640 (gvn_uses_equal): Use it.
13641 (same_succ_hash): Likewise.
13642 (gimple_equal_p): Likewise.
13643
13644 2018-08-02 Nick Clifton <nickc@redhat.com>
13645
13646 PR target/86813
13647 * config/stormy16/stormy16.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
13648 Define to speculation_safe_value_not_needed.
13649
13650 PR target/86810
13651 * config/v850/v850.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
13652 Define to speculation_safe_value_not_needed.
13653
13654 PR target/86810
13655 * config/v850/v850.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
13656 Define to speculation_safe_value_not_needed.
13657
13658 PR target/86803
13659 * config/rx/rx.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
13660 Define to speculation_safe_value_not_needed.
13661
13662 PR target/86797
13663 * config/msp430/msp430.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
13664 Define to speculation_safe_value_not_needed.
13665
13666 PR target/86791
13667 * config/mcore/mcore.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
13668 Define to speculation_safe_value_not_needed.
13669
13670 PR target/86789
13671 * config/m32r/m32r.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
13672 Define to speculation_safe_value_not_needed.
13673
13674 PR target/86787
13675 * config/iq2000/iq2000.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
13676 Define to speculation_safe_value_not_needed.
13677
13678 PR target/86782
13679 * config/frv/frv.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Define to
13680 speculation_safe_value_not_needed.
13681
13682 PR target/86781
13683 * config/fr30/fr30.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Define
13684 to speculation_safe_value_not_needed.
13685
13686 2018-08-02 Richard Sandiford <richard.sandiford@arm.com>
13687
13688 * doc/md.texi: Expand the documentation of instruction names
13689 to mention port-local uses. Document '@' in pattern names.
13690 * read-md.h (overloaded_instance, overloaded_name): New structs.
13691 (mapping): Declare.
13692 (md_reader::handle_overloaded_name): New member function.
13693 (md_reader::get_overloads): Likewise.
13694 (md_reader::m_first_overload): New member variable.
13695 (md_reader::m_next_overload_ptr): Likewise.
13696 (md_reader::m_overloads_htab): Likewise.
13697 * read-md.c (md_reader::md_reader): Initialize m_first_overload,
13698 m_next_overload_ptr and m_overloads_htab.
13699 * read-rtl.c (iterator_group): Add "type" and "get_c_token" fields.
13700 (get_mode_token, get_code_token, get_int_token): New functions.
13701 (map_attr_string): Add an optional argument that passes back
13702 the associated iterator.
13703 (overloaded_name_hash, overloaded_name_eq_p, named_rtx_p):
13704 (md_reader::handle_overloaded_name, add_overload_instance): New
13705 functions.
13706 (apply_iterators): Handle '@' names. Report an error if '@'
13707 is used without iterators.
13708 (initialize_iterators): Initialize the new iterator_group fields.
13709 * genopinit.c (handle_overloaded_code_for)
13710 (handle_overloaded_gen): New functions.
13711 (main): Use them to print declarations of maybe_code_for_* and
13712 maybe_gen_* functions, and inline definitions of code_for_* and gen_*.
13713 * genemit.c (print_overload_arguments, print_overload_test)
13714 (handle_overloaded_code_for, handle_overloaded_gen): New functions.
13715 (main): Use it to print definitions of maybe_code_for_* and
13716 maybe_gen_* functions.
13717 * config/aarch64/aarch64.c (aarch64_split_128bit_move): Use
13718 gen_aarch64_mov{low,high}_di and gen_aarch64_movdi_{low,high}
13719 instead of explicit mode checks.
13720 (aarch64_split_simd_combine): Likewise gen_aarch64_simd_combine.
13721 (aarch64_split_simd_move): Likewise gen_aarch64_split_simd_mov.
13722 (aarch64_emit_load_exclusive): Likewise gen_aarch64_load_exclusive.
13723 (aarch64_emit_store_exclusive): Likewise gen_aarch64_store_exclusive.
13724 (aarch64_expand_compare_and_swap): Likewise
13725 gen_aarch64_compare_and_swap and gen_aarch64_compare_and_swap_lse
13726 (aarch64_gen_atomic_cas): Likewise gen_aarch64_atomic_cas.
13727 (aarch64_emit_atomic_swap): Likewise gen_aarch64_atomic_swp.
13728 (aarch64_constant_pool_reload_icode): Delete.
13729 (aarch64_secondary_reload): Use code_for_aarch64_reload_movcp
13730 instead of aarch64_constant_pool_reload_icode. Use
13731 code_for_aarch64_reload_mov instead of explicit mode checks.
13732 (rsqrte_type, get_rsqrte_type, rsqrts_type, get_rsqrts_type): Delete.
13733 (aarch64_emit_approx_sqrt): Use gen_aarch64_rsqrte instead of
13734 get_rsqrte_type and gen_aarch64_rsqrts instead of gen_rqrts_type.
13735 (recpe_type, get_recpe_type, recps_type, get_recps_type): Delete.
13736 (aarch64_emit_approx_div): Use gen_aarch64_frecpe instead of
13737 get_recpe_type and gen_aarch64_frecps instead of get_recps_type.
13738 (aarch64_atomic_load_op_code): Delete.
13739 (aarch64_emit_atomic_load_op): Likewise.
13740 (aarch64_gen_atomic_ldop): Use UNSPECV_ATOMIC_* instead of
13741 aarch64_atomic_load_op_code. Use gen_aarch64_atomic_load
13742 instead of aarch64_emit_atomic_load_op.
13743 * config/aarch64/aarch64.md (aarch64_reload_movcp<GPF_TF:mode><P:mode>)
13744 (aarch64_reload_movcp<VALL:mode><P:mode>, aarch64_reload_mov<mode>)
13745 (aarch64_movdi_<mode>low, aarch64_movdi_<mode>high)
13746 (aarch64_mov<mode>high_di, aarch64_mov<mode>low_di): Add a '@'
13747 character before the pattern name.
13748 * config/aarch64/aarch64-simd.md (aarch64_split_simd_mov<mode>)
13749 (aarch64_rsqrte<mode>, aarch64_rsqrts<mode>)
13750 (aarch64_simd_combine<mode>, aarch64_frecpe<mode>)
13751 (aarch64_frecps<mode>): Likewise.
13752 * config/aarch64/atomics.md (atomic_compare_and_swap<mode>)
13753 (aarch64_compare_and_swap<mode>, aarch64_compare_and_swap<mode>_lse)
13754 (aarch64_load_exclusive<mode>, aarch64_store_exclusive<mode>)
13755 (aarch64_atomic_swp<mode>, aarch64_atomic_cas<mode>)
13756 (aarch64_atomic_load<atomic_ldop><mode>): Likewise.
13757
13758 2018-08-02 Richard Sandiford <richard.sandiford@arm.com>
13759
13760 * config/aarch64/aarch64.c (aarch64_float_const_representable_p):
13761 Allow HFmode constants if TARGET_FP_F16INST.
13762
13763 2018-08-02 Jackson Woodruff <jackson.woodruff@arm.com>
13764
13765 PR target/86014
13766 * config/aarch64/aarch64.c (aarch64_operands_adjust_ok_for_ldpstp):
13767 No longer check last store for clobber of address register.
13768
13769 2018-08-02 Martin Liska <mliska@suse.cz>
13770
13771 PR gcov-profile/86817
13772 * gcov.c (process_all_functions): New function.
13773 (main): Call it.
13774 (process_file): Move functions processing to
13775 process_all_functions.
13776
13777 2018-08-02 David Malcolm <dmalcolm@redhat.com>
13778
13779 * dumpfile.c (dump_user_location_t::dump_user_location_t): Add
13780 "const" to the "gimple *" and "rtx_insn *" parameters.
13781 * dumpfile.h (dump_user_location_t::dump_user_location_t):
13782 Likewise.
13783 (dump_location_t::dump_location_t): Likewise.
13784
13785 2018-08-01 Martin Sebor <msebor@redhat.com>
13786
13787 PR tree-optimization/86650
13788 * gimple-pretty-print.c (percent_G_format): Accept a "gimple *"
13789 rather than a "gcall *". Directly pass the data of interest
13790 to percent_K_format, rather than building a temporary CALL_EXPR
13791 to hold it.
13792 * gimple-fold.c (gimple_fold_builtin_strncpy): Adjust.
13793 (gimple_fold_builtin_strncat): Adjust.
13794 * gimple-ssa-warn-restrict.h (check_bounds_or_overlap): Replace
13795 gcall* argument with gimple*.
13796 * gimple-ssa-warn-restrict.c (check_call): Same.
13797 (wrestrict_dom_walker::before_dom_children): Same.
13798 (builtin_access::builtin_access): Same.
13799 (check_bounds_or_overlap): Same
13800 (maybe_diag_overlap): Same.
13801 (maybe_diag_offset_bounds): Same.
13802 * tree-diagnostic.c (default_tree_printer): Move usage of
13803 EXPR_LOCATION (t) and TREE_BLOCK (t) from within percent_K_format
13804 to this callsite.
13805 * tree-pretty-print.c (percent_K_format): Add argument.
13806 * tree-pretty-print.h: Add argument.
13807 * tree-ssa-ccp.c (pass_post_ipa_warn::execute): Adjust.
13808 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Adjust.
13809 (maybe_diag_stxncpy_trunc): Same.
13810 (handle_builtin_stxncpy): Same.
13811 (handle_builtin_strcat): Same.
13812
13813 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
13814
13815 * match.pd: Optimise pointer range checks.
13816
13817 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
13818
13819 PR tree-optimization/86758
13820 * tree-vect-stmts.c (vectorizable_simd_clone_call): Don't try
13821 to remove pattern statements.
13822
13823 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
13824
13825 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Use the
13826 result of dfs_enumerate_from when constructing stmt_vec_infos,
13827 instead of additionally calling get_loop_body.
13828
13829 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
13830
13831 * tree-vectorizer.h (vect_create_data_ref_ptr): Remove inv_p
13832 parameter.
13833 * tree-vect-data-refs.c (vect_create_data_ref_ptr): Likewise.
13834 When creating an iv, assert that the step is not known to be zero.
13835 (vect_setup_realignment): Update call accordingly.
13836 * tree-vect-stmts.c (vectorizable_store): Likewise.
13837 (vectorizable_load): Likewise. Handle VMAT_INVARIANT separately.
13838
13839 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
13840
13841 * tree-vectorizer.h (vect_stmt_to_vectorize): New function.
13842 * tree-vect-loop.c (vect_update_vf_for_slp): Use it.
13843 (vectorizable_reduction): Likewise.
13844 * tree-vect-slp.c (vect_analyze_slp_instance): Likewise.
13845 (vect_detect_hybrid_slp_stmts): Likewise.
13846 * tree-vect-stmts.c (vect_is_simple_use): Likewise.
13847
13848 2018-08-01 Aldy Hernandez <aldyh@redhat.com>
13849
13850 * tree-vrp (zero_nonzero_bits_from_bounds): Rename to...
13851 (wide_int_set_zero_nonzero_bits): ...this.
13852 (zero_nonzero_bits_from_vr): Rename to...
13853 (vrp_set_zero_nonzero_bits): ...this.
13854 (extract_range_from_multiplicative_op_1): Abstract wide int
13855 code...
13856 (wide_int_range_multiplicative_op): ...here.
13857 (extract_range_from_binary_expr_1): Extract wide int binary
13858 operations into their own functions.
13859 (wide_int_range_lshift): New.
13860 (wide_int_range_can_optimize_bit_op): New.
13861 (wide_int_range_shift_undefined_p): New.
13862 (wide_int_range_bit_xor): New.
13863 (wide_int_range_bit_ior): New.
13864 (wide_int_range_bit_and): New.
13865 (wide_int_range_trunc_mod): New.
13866 (extract_range_into_wide_ints): New.
13867 (vrp_shift_undefined_p): New.
13868 (extract_range_from_multiplicative_op): New.
13869 (vrp_can_optimize_bit_op): New.
13870 * tree-vrp.h (value_range::dump): New.
13871 (wide_int_range_multiplicative_op): New.
13872 (wide_int_range_lshift):New.
13873 (wide_int_range_shift_undefined_p): New.
13874 (wide_int_range_bit_xor): New.
13875 (wide_int_range_bit_ior): New.
13876 (wide_int_range_bit_and): New.
13877 (wide_int_range_trunc_mod): New.
13878 (zero_nonzero_bits_from_bounds): Rename to...
13879 (wide_int_set_zero_nonzero_bits): ...this.
13880 (zero_nonzero_bits_from_vr): Rename to...
13881 (vrp_set_zero_nonzero_bits): ...this.
13882 (range_easy_mask_min_max): Rename to...
13883 (wide_int_range_can_optimize_bit_op): this.
13884 * vr-values.c (simplify_bit_ops_using_ranges): Rename
13885 zero_nonzero_bits_from_vr into vrp_set_zero_nonzero_bits.
13886
13887 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
13888
13889 * tree-vectorizer.h (vect_orig_stmt): New function.
13890 * tree-vect-data-refs.c (vect_preserves_scalar_order_p): Use it.
13891 * tree-vect-loop.c (vect_model_reduction_cost): Likewise.
13892 (vect_create_epilog_for_reduction): Likewise.
13893 (vectorizable_live_operation): Likewise.
13894 * tree-vect-slp.c (vect_find_last_scalar_stmt_in_slp): Likewise.
13895 (vect_detect_hybrid_slp_stmts, vect_schedule_slp): Likewise.
13896 * tree-vect-stmts.c (vectorizable_call): Likewise.
13897 (vectorizable_simd_clone_call, vect_remove_stores): Likewise.
13898
13899 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
13900
13901 * tree-vectorizer.h (vect_transform_stmt): Remove grouped_store
13902 argument.
13903 * tree-vect-stmts.c (vect_transform_stmt): Likewise.
13904 * tree-vect-loop.c (vect_transform_loop_stmt): Update call accordingly.
13905 (vect_transform_loop): Likewise.
13906 * tree-vect-slp.c (vect_schedule_slp_instance): Likewise.
13907
13908 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
13909
13910 * tree-vectorizer.h (vect_schedule_slp): Return void.
13911 * tree-vect-slp.c (vect_schedule_slp_instance): Likewise.
13912 (vect_schedule_slp): Likewise.
13913
13914 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
13915
13916 * tree-vect-loop.c (vect_transform_loop_stmt): Remove slp_scheduled
13917 argument.
13918 (vect_transform_loop): Update calls accordingly. Schedule SLP
13919 instances before the main loop, if any exist.
13920
13921 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
13922
13923 PR tree-optimization/86749
13924 * tree-vect-patterns.c (vect_determine_min_output_precision_1):
13925 If the lhs is used in a COND_EXPR, check that it is being used
13926 as the "then" or "else" value.
13927
13928 2018-08-01 Tom de Vries <tdevries@suse.de>
13929
13930 PR target/86800
13931 * config/nvptx/nvptx.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Define to
13932 speculation_safe_value_not_needed.
13933
13934 2018-08-01 Richard Biener <rguenther@suse.de>
13935
13936 * tree-ssa-sccvn.c (visit_phi): Compare invariant addresses
13937 as base and offset.
13938
13939 2018-08-01 Martin Liska <mliska@suse.cz>
13940
13941 * value-prof.c (gimple_divmod_fixed_value_transform): Unify
13942 format how successful transformation is dumped.
13943 (gimple_mod_pow2_value_transform): Likewise.
13944 (gimple_mod_subtract_transform): Likewise.
13945 (gimple_stringops_transform): Likewise.
13946
13947 2018-08-01 Martin Liska <mliska@suse.cz>
13948
13949 PR value-prof/35543
13950 * value-prof.c (interesting_stringop_to_profile_p):
13951 Simplify the code and add BUILT_IN_MEMMOVE.
13952 (gimple_stringops_transform): Likewise.
13953
13954 2018-08-01 Sam Tebbs <sam.tebbs@arm.com>
13955
13956 * config/aarch64/aarch64-simd.md
13957 (*aarch64_get_lane_zero_extendsi<mode>): Rename to...
13958 (*aarch64_get_lane_zero_extend<GPI:mode><VDQQH:mode>): ... This and
13959 use GPI iterator instead of SI mode.
13960
13961 2018-08-01 Richard Earnshaw <rearnsha@arm.com>
13962
13963 * config/rs6000/rs6000.md (speculation_barrier): Renamed from
13964 rs6000_speculation_barrier.
13965 * config/rs6000/rs6000.c (rs6000_expand_builtin): Adjust for
13966 new barrier pattern name.
13967
13968 2018-08-01 Richard Earnshaw <rearnsha@arm.com>
13969
13970 * config/i386/i386.md (unspecv): Add UNSPECV_SPECULATION_BARRIER.
13971 (speculation_barrier): New insn.
13972
13973 2018-08-01 Richard Biener <rguenther@suse.de>
13974
13975 PR bootstrap/86724
13976 * graphite.h: Include isl/id.h and isl/space.h to allow build
13977 with ISL 0.20.
13978
13979 2018-08-01 Jan Willem Jagersma <jwjagersma@gmail.com>
13980
13981 PR target/86651
13982 * dwarf2out.c (dwarf2out_early_finish): Do not generate assembly in LTO
13983 mode for COFF targets.
13984 * defaults.h (TARGET_COFF): Define.
13985 * config/i386/djgpp.h (TARGET_ASM_LTO_START, TARGET_ASM_LTO_END,
13986 TARGET_COFF): Define.
13987 (i386_djgpp_asm_lto_start, i386_djgpp_asm_lto_end): Declare.
13988 * config/i386/djgpp.c (saved_debug_info_level): New static variable.
13989 (i386_djgpp_asm_lto_start, i386_djgpp_asm_lto_end): New functions.
13990
13991 2018-07-31 Alexandre Oliva <oliva@adacore.com>
13992
13993 * gimple-streamer-in.c (input_bb): Restore BB discriminator.
13994 * gimple-streamer-out.c (output_bb): Save it.
13995 * lto-streamer-in.c (input_struct_function_base): Restore
13996 instance discriminator if available. Create map on demand.
13997 * lto-streamer-out.c (output_struct_function_base): Save it if
13998 available.
13999 * final.c (decl_to_instance_map): Document LTO strategy.
14000
14001 2018-07-31 Alexandre Oliva <oliva@adacore.com>
14002 Olivier Hainque <hainque@adacore.com>
14003
14004 * debug.h (decl_to_instance_map_t): New type.
14005 (decl_to_instance_map): Declare.
14006 (maybe_create_decl_to_instance_map): New inline function.
14007 * final.c (bb_discriminator, last_bb_discriminator): New statics,
14008 to track basic block discriminators.
14009 (final_start_function_1): Initialize them.
14010 (final_scan_insn_1): On NOTE_INSN_BASIC_BLOCK, track
14011 bb_discriminator.
14012 (decl_to_instance_map): New variable.
14013 (map_decl_to_instance, maybe_set_discriminator): New functions.
14014 (notice_source_line): Set discriminator.
14015
14016 2018-07-31 Ian Lance Taylor <iant@golang.org>
14017
14018 * targhooks.c (default_have_speculation_safe_value): Add
14019 ATTRIBUTE_UNUSED.
14020
14021 2018-07-31 David Malcolm <dmalcolm@redhat.com>
14022
14023 * dump-context.h: Include "pretty-print.h".
14024 (dump_context::refresh_dumps_are_enabled): New decl.
14025 (dump_context::emit_item): New decl.
14026 (class dump_context): Add fields "m_test_pp" and
14027 "m_test_pp_flags".
14028 (temp_dump_context::temp_dump_context): Add param "test_pp_flags".
14029 (temp_dump_context::get_dumped_text): New decl.
14030 (class temp_dump_context): Add field "m_pp".
14031 * dumpfile.c (refresh_dumps_are_enabled): Convert to...
14032 (dump_context::refresh_dumps_are_enabled): ...and add a test for
14033 m_test_pp.
14034 (set_dump_file): Update for above change.
14035 (set_alt_dump_file): Likewise.
14036 (dump_loc): New overload, taking a pretty_printer *.
14037 (dump_context::dump_loc): Call end_any_optinfo. Dump the location
14038 to any test pretty-printer.
14039 (make_item_for_dump_gimple_stmt): New function, adapted from
14040 optinfo::add_gimple_stmt.
14041 (dump_context::dump_gimple_stmt): Call it, and use the result,
14042 eliminating the direct usage of dump_file and alt_dump_file in
14043 favor of indirectly using them via emit_item.
14044 (make_item_for_dump_gimple_expr): New function, adapted from
14045 optinfo::add_gimple_expr.
14046 (dump_context::dump_gimple_expr): Call it, and use the result,
14047 eliminating the direct usage of dump_file and alt_dump_file in
14048 favor of indirectly using them via emit_item.
14049 (make_item_for_dump_generic_expr): New function, adapted from
14050 optinfo::add_tree.
14051 (dump_context::dump_generic_expr): Call it, and use the result,
14052 eliminating the direct usage of dump_file and alt_dump_file in
14053 favor of indirectly using them via emit_item.
14054 (make_item_for_dump_printf_va): New function, adapted from
14055 optinfo::add_printf_va.
14056 (make_item_for_dump_printf): New function.
14057 (dump_context::dump_printf_va): Call make_item_for_dump_printf_va,
14058 and use the result, eliminating the direct usage of dump_file and
14059 alt_dump_file in favor of indirectly using them via emit_item.
14060 (make_item_for_dump_dec): New function.
14061 (dump_context::dump_dec): Call it, and use the result,
14062 eliminating the direct usage of dump_file and alt_dump_file in
14063 favor of indirectly using them via emit_item.
14064 (make_item_for_dump_symtab_node): New function, adapted from
14065 optinfo::add_symtab_node.
14066 (dump_context::dump_symtab_node): Call it, and use the result,
14067 eliminating the direct usage of dump_file and alt_dump_file in
14068 favor of indirectly using them via emit_item.
14069 (dump_context::begin_scope): Reimplement, avoiding direct usage
14070 of dump_file and alt_dump_file in favor of indirectly using them
14071 via emit_item.
14072 (dump_context::emit_item): New member function.
14073 (temp_dump_context::temp_dump_context): Add param "test_pp_flags".
14074 Set up test pretty-printer on the underlying context. Call
14075 refresh_dumps_are_enabled.
14076 (temp_dump_context::~temp_dump_context): Call
14077 refresh_dumps_are_enabled.
14078 (temp_dump_context::get_dumped_text): New member function.
14079 (selftest::verify_dumped_text): New function.
14080 (ASSERT_DUMPED_TEXT_EQ): New macro.
14081 (selftest::test_capture_of_dump_calls): Run all tests twice, with
14082 and then without optinfo enabled. Add uses of
14083 ASSERT_DUMPED_TEXT_EQ to all tests. Add test of nested scopes.
14084 * dumpfile.h: Update comment for the dump_* API.
14085 * optinfo-emit-json.cc
14086 (selftest::test_building_json_from_dump_calls): Update for new
14087 param for temp_dump_context ctor.
14088 * optinfo.cc (optinfo_item::optinfo_item): Remove "owned" param
14089 and "m_owned" field.
14090 (optinfo_item::~optinfo_item): Likewise.
14091 (optinfo::add_item): New member function.
14092 (optinfo::emit): Update comment.
14093 (optinfo::add_string): Delete.
14094 (optinfo::add_printf): Delete.
14095 (optinfo::add_printf_va): Delete.
14096 (optinfo::add_gimple_stmt): Delete.
14097 (optinfo::add_gimple_expr): Delete.
14098 (optinfo::add_tree): Delete.
14099 (optinfo::add_symtab_node): Delete.
14100 (optinfo::add_dec): Delete.
14101 * optinfo.h (class dump_context): New forward decl.
14102 (optinfo::add_item): New decl.
14103 (optinfo::add_string): Delete.
14104 (optinfo::add_printf): Delete.
14105 (optinfo::add_printf_va): Delete.
14106 (optinfo::add_gimple_stmt): Delete.
14107 (optinfo::add_gimple_expr): Delete.
14108 (optinfo::add_tree): Delete.
14109 (optinfo::add_symtab_node): Delete.
14110 (optinfo::add_dec): Delete.
14111 (optinfo::add_poly_int): Delete.
14112 (optinfo_item::optinfo_item): Remove "owned" param.
14113 (class optinfo_item): Remove field "m_owned".
14114
14115 2018-07-31 Jozef Lawrynowicz <jozef.l@mittosystems.com>
14116
14117 PR middle-end/86705
14118 * gcc/cfgexpand.c (set_parm_rtl): Use the alignment of Pmode when
14119 MAX_SUPPORTED_STACK_ALIGNMENT would otherwise be exceeded by the
14120 requested variable alignment.
14121 (expand_one_ssa_partition): Likewise.
14122 (expand_one_var): Likewise.
14123
14124 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
14125
14126 * config/pdp11/pdp11.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Redefine
14127 to speculation_safe_value_not_needed.
14128
14129 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
14130
14131 * targhooks.h (speculation_safe_value_not_needed): New prototype.
14132 * targhooks.c (speculation_safe_value_not_needed): New function.
14133 * target.def (have_speculation_safe_value): Update documentation.
14134 * doc/tm.texi: Regenerated.
14135
14136 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
14137
14138 * config/aarch64/iterators.md (ALLI_TI): New iterator.
14139 * config/aarch64/aarch64.md (despeculate_copy<ALLI_TI:mode>): New
14140 expand.
14141 (despeculate_copy<ALLI:mode>_insn): New insn.
14142 (despeculate_copyti_insn): New insn.
14143 (despeculate_simple<ALLI:mode>): New insn
14144 (despeculate_simpleti): New insn.
14145 * config/aarch64/aarch64.c (aarch64_speculation_safe_value): New
14146 function.
14147 (TARGET_SPECULATION_SAFE_VALUE): Redefine to
14148 aarch64_speculation_safe_value.
14149 (aarch64_print_operand): Handle const0_rtx in modifier 'H'.
14150
14151 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
14152
14153 * config/aarch64/aarch64-speculation.cc: New file.
14154 * config/aarch64/aarch64-passes.def (pass_track_speculation): Add
14155 before pass_reorder_blocks.
14156 * config/aarch64/aarch64-protos.h (make_pass_track_speculation): Add
14157 prototype.
14158 * config/aarch64/aarch64.c (aarch64_conditional_register_usage): Fix
14159 X14 and X15 when tracking speculation.
14160 * config/aarch64/aarch64.md (register name constants): Add
14161 SPECULATION_TRACKER_REGNUM and SPECULATION_SCRATCH_REGNUM.
14162 (unspec): Add UNSPEC_SPECULATION_TRACKER.
14163 (speculation_barrier): New insn attribute.
14164 (cmp<mode>): Allow SP in comparisons.
14165 (speculation_tracker): New insn.
14166 (speculation_barrier): Add speculation_barrier attribute.
14167 * config/aarch64/t-aarch64: Add make rule for aarch64-speculation.o.
14168 * config.gcc (aarch64*-*-*): Add aarch64-speculation.o to extra_objs.
14169 * doc/invoke.texi (AArch64 Options): Document -mtrack-speculation.
14170
14171 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
14172
14173 * config/aarch64/aarch64.md (cb<optab><mode>1): Disable when
14174 aarch64_track_speculation is true.
14175 (tb<optab><mode>1): Likewise.
14176 * config/aarch64/aarch64.c (aarch64_split_compare_regs): Do not
14177 generate CB[N]Z when tracking speculation.
14178 (aarch64_split_compare_and_swap): Likewise.
14179 (aarch64_split_atomic_op): Likewise.
14180
14181 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
14182
14183 * config/aarch64/aarch64.opt (mtrack-speculation): New target option.
14184
14185 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
14186
14187 * config/aarch64.md (unspecv): Add UNSPECV_SPECULAION_BARRIER.
14188 (speculation_barrier): New insn.
14189
14190 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
14191
14192 * config/arm/unspecs.md (unspecv): Add VUNSPEC_SPECULATION_BARRIER.
14193 * config/arm/arm.md (speculation_barrier): New expand.
14194 (speculation_barrier_insn): New pattern.
14195
14196 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
14197
14198 * builtin-types.def (BT_FN_PTR_PTR_VAR): New function type.
14199 (BT_FN_I1_I1_VAR, BT_FN_I2_I2_VAR, BT_FN_I4_I4_VAR): Likewise.
14200 (BT_FN_I8_I8_VAR, BT_FN_I16_I16_VAR): Likewise.
14201 * builtin-attrs.def (ATTR_NOVOPS_NOTHROW_LEAF_LIST): New attribute
14202 list.
14203 * builtins.def (BUILT_IN_SPECULATION_SAFE_VALUE_N): New builtin.
14204 (BUILT_IN_SPECULATION_SAFE_VALUE_PTR): New internal builtin.
14205 (BUILT_IN_SPECULATION_SAFE_VALUE_1): Likewise.
14206 (BUILT_IN_SPECULATION_SAFE_VALUE_2): Likewise.
14207 (BUILT_IN_SPECULATION_SAFE_VALUE_4): Likewise.
14208 (BUILT_IN_SPECULATION_SAFE_VALUE_8): Likewise.
14209 (BUILT_IN_SPECULATION_SAFE_VALUE_16): Likewise.
14210 * builtins.c (expand_speculation_safe_value): New function.
14211 (expand_builtin): Call it.
14212 * doc/cpp.texi: Document predefine __HAVE_SPECULATION_SAFE_VALUE.
14213 * doc/extend.texi: Document __builtin_speculation_safe_value.
14214 * doc/md.texi: Document "speculation_barrier" pattern.
14215 * doc/tm.texi.in: Pull in TARGET_SPECULATION_SAFE_VALUE and
14216 TARGET_HAVE_SPECULATION_SAFE_VALUE.
14217 * doc/tm.texi: Regenerated.
14218 * target.def (have_speculation_safe_value, speculation_safe_value): New
14219 hooks.
14220 * targhooks.c (default_have_speculation_safe_value): New function.
14221 (default_speculation_safe_value): New function.
14222 * targhooks.h (default_have_speculation_safe_value): Add prototype.
14223 (default_speculation_safe_value): Add prototype.
14224
14225 2018-07-31 David Malcolm <dmalcolm@redhat.com>
14226
14227 * dump-context.h (dump_context::dump_loc): New decl.
14228 * dumpfile.c (dump_context::dump_loc): New member function.
14229 (dump_context::dump_gimple_stmt_loc): Reimplement using dump_loc
14230 and dump_gimple_stmt.
14231 (dump_context::dump_gimple_expr_loc): Likewise, using
14232 dump_gimple_expr.
14233 (dump_context::dump_generic_expr_loc): Likewise, using
14234 dump_generic_expr.
14235 (dump_context::dump_printf_loc_va): Likewise, using
14236 dump_printf_va.
14237 (dump_context::begin_scope): Explicitly using the global function
14238 "dump_loc", rather than the member function.
14239
14240 2018-07-31 Martin Sebor <msebor@redhat.com>
14241
14242 PR tree-optimization/86741
14243 * tree-vrp.c (vrp_prop::check_mem_ref): Avoid incomplete types.
14244
14245 2018-07-31 Andreas Krebbel <krebbel@linux.ibm.com>
14246
14247 * config/s390/s390.c (s390_expand_setmem): Make the unrolling to
14248 depend on whether prefetch instructions will be emitted or not.
14249 Use TARGET_SETMEM_PFD for checking whether prefetch instructions
14250 will be emitted or not.
14251 * config/s390/s390.h (TARGET_SETMEM_PREFETCH_DISTANCE)
14252 (TARGET_SETMEM_PFD): New macros.
14253
14254 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14255
14256 * tree-vectorizer.h (stmt_vec_info): Turn back into a typedef.
14257 (NULL_STMT_VEC_INFO): Delete.
14258 (stmt_vec_info::operator*): Likewise.
14259 (stmt_vec_info::operator gimple *): Likewise.
14260 * tree-vect-loop.c (vectorizable_reduction): Use NULL instead
14261 of NULL_STMT_VEC_INFO.
14262 * tree-vect-patterns.c (vect_init_pattern_stmt): Likewise.
14263 (vect_reassociating_reduction_p): Likewise.
14264 * tree-vect-stmts.c (vect_build_gather_load_calls): Likewise.
14265 (vectorizable_store): Likewise.
14266 * tree-vectorizer.c (vec_info::set_vinfo_for_stmt): Likewise.
14267 (vec_info::free_stmt_vec_infos): Likewise.
14268
14269 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14270
14271 * tree-vectorizer.h (vect_stmt_in_region_p): Delete.
14272 * tree-vectorizer.c (vect_stmt_in_region_p): Likewise.
14273
14274 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14275
14276 * tree-vectorizer.h (vec_info::new_vinfo_for_stmt)
14277 (vec_info::set_vinfo_for_stmt, vec_info::free_stmt_vec_infos)
14278 (vec_info::free_stmt_vec_info): New private member functions.
14279 (set_stmt_vec_info_vec, free_stmt_vec_infos, vinfo_for_stmt)
14280 (set_vinfo_for_stmt, new_stmt_vec_info, free_stmt_vec_info): Delete.
14281 * tree-parloops.c (gather_scalar_reductions): Remove calls to
14282 set_stmt_vec_info_vec and free_stmt_vec_infos.
14283 * tree-vect-loop.c (_loop_vec_info): Remove call to
14284 set_stmt_vec_info_vec.
14285 * tree-vect-stmts.c (new_stmt_vec_info, set_stmt_vec_info_vec)
14286 (free_stmt_vec_infos, free_stmt_vec_info): Delete in favor of...
14287 * tree-vectorizer.c (vec_info::new_stmt_vec_info)
14288 (vec_info::set_vinfo_for_stmt, vec_info::free_stmt_vec_infos)
14289 (vec_info::free_stmt_vec_info): ...these new functions. Remove
14290 assignments in {vec_info::,}new_stmt_vec_info that are redundant
14291 with the clearing in the xcalloc.
14292 (stmt_vec_info_vec): Delete.
14293 (vec_info::vec_info): Don't call set_stmt_vec_info_vec.
14294 (vectorize_loops): Likewise.
14295 (vec_info::~vec_info): Remove argument from call to
14296 free_stmt_vec_infos.
14297 (vec_info::add_stmt): Remove vinfo argument from call to
14298 new_stmt_vec_info.
14299
14300 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14301
14302 * tree-vectorizer.h (free_stmt_vec_info): Take a stmt_vec_info
14303 rather than a gimple stmt.
14304 * tree-vect-stmts.c (free_stmt_vec_info): Likewise. Don't free
14305 information for pattern statements when passed the original
14306 statement; instead wait to be passed the pattern statement itself.
14307 Don't call set_vinfo_for_stmt here.
14308 (free_stmt_vec_infos): Update call to free_stmt_vec_info.
14309 * tree-vect-loop.c (_loop_vec_info::~loop_vec_info): Don't free
14310 stmt_vec_infos here.
14311 * tree-vect-slp.c (_bb_vec_info::~bb_vec_info): Likewise.
14312 * tree-vectorizer.c (vec_info::remove_stmt): Nullify the statement's
14313 stmt_vec_infos entry.
14314
14315 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14316
14317 * tree-vectorizer.h (vec_info::replace_stmt): Declare.
14318 * tree-vectorizer.c (vec_info::replace_stmt): New function.
14319 * tree-vect-slp.c (vect_remove_slp_scalar_calls): Use it.
14320 * tree-vect-stmts.c (vectorizable_call): Likewise.
14321 (vectorizable_simd_clone_call): Likewise.
14322
14323 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14324
14325 * tree-vectorizer.h (vec_info::remove_stmt): Declare.
14326 * tree-vectorizer.c (vec_info::remove_stmt): New function.
14327 * tree-vect-loop-manip.c (vect_set_loop_condition): Use it.
14328 * tree-vect-loop.c (vect_transform_loop): Likewise.
14329 * tree-vect-slp.c (vect_schedule_slp): Likewise.
14330 * tree-vect-stmts.c (vect_remove_stores): Likewise.
14331
14332 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14333
14334 * tree-vectorizer.h (vec_info::lookup_dr): New member function.
14335 (vect_dr_stmt): Delete.
14336 * tree-vectorizer.c (vec_info::lookup_dr): New function.
14337 * tree-vect-loop-manip.c (vect_update_inits_of_drs): Use it instead
14338 of DR_VECT_AUX.
14339 * tree-vect-data-refs.c (vect_analyze_possibly_independent_ddr)
14340 (vect_analyze_data_ref_dependence, vect_record_base_alignments)
14341 (vect_verify_datarefs_alignment, vect_peeling_supportable)
14342 (vect_analyze_data_ref_accesses, vect_prune_runtime_alias_test_list)
14343 (vect_analyze_data_refs): Likewise.
14344 (vect_slp_analyze_data_ref_dependence): Likewise. Take a vec_info
14345 argument.
14346 (vect_find_same_alignment_drs): Likewise.
14347 (vect_slp_analyze_node_dependences): Update calls accordingly.
14348 (vect_analyze_data_refs_alignment): Likewise. Use vec_info::lookup_dr
14349 instead of DR_VECT_AUX.
14350 (vect_get_peeling_costs_all_drs): Take a loop_vec_info instead
14351 of a vector data references. Use vec_info::lookup_dr instead of
14352 DR_VECT_AUX.
14353 (vect_peeling_hash_get_lowest_cost): Update calls accordingly.
14354 (vect_enhance_data_refs_alignment): Likewise. Use vec_info::lookup_dr
14355 instead of DR_VECT_AUX.
14356
14357 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14358
14359 * tree-vectorizer.h (_loop_vec_info::unaligned_dr): Change to
14360 dr_vec_info.
14361 * tree-vect-data-refs.c (vect_enhance_data_refs_alignment): Update
14362 accordingly.
14363 * tree-vect-loop.c (vect_analyze_loop_2): Likewise.
14364 * tree-vect-loop-manip.c (get_misalign_in_elems): Likewise.
14365 (vect_gen_prolog_loop_niters): Likewise.
14366
14367 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14368
14369 * tree-vectorizer.h (set_dr_misalignment, dr_misalignment)
14370 (DR_TARGET_ALIGNMENT, aligned_access_p, known_alignment_for_access_p)
14371 (vect_known_alignment_in_bytes, vect_dr_behavior)
14372 (vect_get_scalar_dr_size): Take references as dr_vec_infos
14373 instead of data_references. Update calls to other routines for
14374 which the same change has been made.
14375 * tree-vect-data-refs.c (vect_preserves_scalar_order_p): Take
14376 dr_vec_infos instead of stmt_vec_infos.
14377 (vect_analyze_data_ref_dependence): Update call accordingly.
14378 (vect_slp_analyze_data_ref_dependence)
14379 (vect_record_base_alignments): Use DR_VECT_AUX.
14380 (vect_calculate_target_alignment, vect_compute_data_ref_alignment)
14381 (vect_update_misalignment_for_peel, verify_data_ref_alignment)
14382 (vector_alignment_reachable_p, vect_get_data_access_cost)
14383 (vect_peeling_supportable, vect_analyze_group_access_1)
14384 (vect_analyze_group_access, vect_analyze_data_ref_access)
14385 (vect_vfa_segment_size, vect_vfa_access_size, vect_vfa_align)
14386 (vect_compile_time_alias, vect_small_gap_p)
14387 (vectorizable_with_step_bound_p, vect_duplicate_ssa_name_ptr_info):
14388 (vect_supportable_dr_alignment): Take references as dr_vec_infos
14389 instead of data_references. Update calls to other routines for
14390 which the same change has been made.
14391 (vect_verify_datarefs_alignment, vect_get_peeling_costs_all_drs)
14392 (vect_find_same_alignment_drs, vect_analyze_data_refs_alignment)
14393 (vect_slp_analyze_and_verify_node_alignment)
14394 (vect_analyze_data_ref_accesses, vect_prune_runtime_alias_test_list)
14395 (vect_create_addr_base_for_vector_ref, vect_create_data_ref_ptr)
14396 (vect_setup_realignment): Use dr_vec_infos. Update calls after
14397 above changes.
14398 (_vect_peel_info::dr): Replace with...
14399 (_vect_peel_info::dr_info): ...this new field.
14400 (vect_peeling_hash_get_most_frequent)
14401 (vect_peeling_hash_choose_best_peeling): Update accordingly.
14402 (vect_peeling_hash_get_lowest_cost):
14403 (vect_enhance_data_refs_alignment): Likewise. Update calls to other
14404 routines for which the same change has been made.
14405 (vect_peeling_hash_insert): Likewise. Take a dr_vec_info instead of a
14406 data_reference.
14407 * tree-vect-loop-manip.c (get_misalign_in_elems)
14408 (vect_gen_prolog_loop_niters): Use dr_vec_infos. Update calls after
14409 above changes.
14410 * tree-vect-loop.c (vect_analyze_loop_2): Likewise.
14411 * tree-vect-stmts.c (vect_get_store_cost, vect_get_load_cost)
14412 (vect_truncate_gather_scatter_offset, compare_step_with_zero)
14413 (get_group_load_store_type, get_negative_load_store_type)
14414 (vect_get_data_ptr_increment, vectorizable_store)
14415 (vectorizable_load): Likewise.
14416 (ensure_base_align): Take a dr_vec_info instead of a data_reference.
14417 Update calls to other routines for which the same change has been made.
14418
14419 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14420
14421 * tree-vectorizer.h (vec_info::move_dr): New member function.
14422 (dataref_aux): Rename to...
14423 (dr_vec_info): ...this and add "dr" and "stmt" fields.
14424 (_stmt_vec_info::dr_aux): Update accordingly.
14425 (_stmt_vec_info::data_ref_info): Delete.
14426 (STMT_VINFO_GROUPED_ACCESS, DR_GROUP_FIRST_ELEMENT)
14427 (DR_GROUP_NEXT_ELEMENT, DR_GROUP_SIZE, DR_GROUP_STORE_COUNT)
14428 (DR_GROUP_GAP, DR_GROUP_SAME_DR_STMT, REDUC_GROUP_FIRST_ELEMENT):
14429 (REDUC_GROUP_NEXT_ELEMENT, REDUC_GROUP_SIZE): Use dr_aux.dr instead
14430 of data_ref.
14431 (STMT_VINFO_DATA_REF): Likewise. Turn into an lvalue.
14432 (STMT_VINFO_DR_INFO): New macro.
14433 (DR_VECT_AUX): Use STMT_VINFO_DR_INKFO and vect_dr_stmt.
14434 (set_dr_misalignment): Update after rename of dataref_aux.
14435 (vect_dr_stmt): Move earlier in file. Return dr_aux.stmt.
14436 * tree-vect-stmts.c (new_stmt_vec_info): Remove redundant
14437 initialization of STMT_VINFO_DATA_REF.
14438 * tree-vectorizer.c (vec_info::move_dr): New function.
14439 * tree-vect-patterns.c (vect_recog_bool_pattern)
14440 (vect_recog_mask_conversion_pattern)
14441 (vect_recog_gather_scatter_pattern): Use it.
14442 * tree-vect-data-refs.c (vect_analyze_data_refs): Initialize
14443 the "dr" and "stmt" fields of dr_vec_info instead of
14444 STMT_VINFO_DATA_REF.
14445
14446 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14447
14448 * tree-vectorizer.h (_stmt_vec_info::pattern_stmt_p): New field.
14449 (is_pattern_stmt_p): Use it.
14450 * tree-vect-patterns.c (vect_init_pattern_stmt): Set pattern_stmt_p
14451 on pattern statements.
14452
14453 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14454
14455 * tree-vect-patterns.c (vect_mark_pattern_stmts): Take the
14456 original stmt as a stmt_vec_info rather than a gimple stmt.
14457 (vect_pattern_recog_1): Take the statement directly as a
14458 stmt_vec_info, rather than via a gimple_stmt_iterator.
14459 Update call to vect_mark_pattern_stmts.
14460 (vect_pattern_recog): Update calls accordingly.
14461
14462 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14463
14464 * tree-vectorizer.h (vect_get_vec_defs_for_stmt_copy)
14465 (vect_get_vec_def_for_stmt_copy): Take a vec_info rather than
14466 a vect_def_type for the first argument.
14467 * tree-vect-stmts.c (vect_get_vec_defs_for_stmt_copy): Likewise.
14468 (vect_get_vec_def_for_stmt_copy): Likewise. Return the original
14469 operand if it isn't defined by a vectorized statement.
14470 (vect_build_gather_load_calls): Remove the mask_dt argument and
14471 update calls to vect_get_vec_def_for_stmt_copy.
14472 (vectorizable_bswap): Likewise the dt argument.
14473 (vectorizable_call): Update calls to vectorizable_bswap and
14474 vect_get_vec_def_for_stmt_copy.
14475 (vectorizable_simd_clone_call, vectorizable_assignment)
14476 (vectorizable_shift, vectorizable_operation, vectorizable_condition)
14477 (vectorizable_comparison): Update calls to
14478 vect_get_vec_def_for_stmt_copy.
14479 (vectorizable_store): Likewise. Remove now-unnecessary calls to
14480 vect_is_simple_use.
14481 (vect_get_loop_based_defs): Remove dt argument and update call
14482 to vect_get_vec_def_for_stmt_copy.
14483 (vectorizable_conversion): Update calls to vect_get_loop_based_defs
14484 and vect_get_vec_def_for_stmt_copy.
14485 (vectorizable_load): Update calls to vect_build_gather_load_calls
14486 and vect_get_vec_def_for_stmt_copy.
14487 * tree-vect-loop.c (vect_create_epilog_for_reduction)
14488 (vectorizable_reduction, vectorizable_live_operation): Update calls
14489 to vect_get_vec_def_for_stmt_copy.
14490
14491 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14492
14493 * tree-vect-data-refs.c (vect_record_base_alignment): Replace vec_info
14494 and gimple stmt arguments with a stmt_vec_info.
14495 (vect_record_base_alignments): Update calls accordingly.
14496 * tree-vect-slp.c (vect_record_max_nunits): Replace vec_info
14497 and gimple stmt arguments with a stmt_vec_info.
14498 (vect_build_slp_tree_1): Remove vinfo argument and update call
14499 to vect_record_max_nunits.
14500 (vect_build_slp_tree_2): Update calls to vect_build_slp_tree_1
14501 and vect_record_max_nunits.
14502
14503 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14504
14505 * tree-vectorizer.h (nested_in_vect_loop_p): Move further down
14506 file and take a stmt_vec_info instead of a gimple stmt.
14507 (supportable_widening_operation, vect_finish_replace_stmt)
14508 (vect_finish_stmt_generation, vect_get_store_rhs)
14509 (vect_get_vec_def_for_operand_1, vect_get_vec_def_for_operand)
14510 (vect_get_vec_defs, vect_init_vector, vect_transform_stmt)
14511 (vect_remove_stores, vect_analyze_stmt, vectorizable_condition)
14512 (vect_get_smallest_scalar_type, vect_check_gather_scatter)
14513 (vect_create_data_ref_ptr, bump_vector_ptr)
14514 (vect_permute_store_chain, vect_setup_realignment)
14515 (vect_transform_grouped_load, vect_record_grouped_load_vectors)
14516 (vect_create_addr_base_for_vector_ref, vectorizable_live_operation)
14517 (vectorizable_reduction, vectorizable_induction)
14518 (get_initial_def_for_reduction, is_simple_and_all_uses_invariant)
14519 (vect_get_place_in_interleaving_chain): Take stmt_vec_infos rather
14520 than gimple stmts as arguments.
14521 * tree-vect-data-refs.c (vect_get_smallest_scalar_type)
14522 (vect_preserves_scalar_order_p, vect_slp_analyze_node_dependences)
14523 (can_group_stmts_p, vect_check_gather_scatter)
14524 (vect_create_addr_base_for_vector_ref, vect_create_data_ref_ptr)
14525 (bump_vector_ptr, vect_permute_store_chain, vect_setup_realignment)
14526 (vect_permute_load_chain, vect_shift_permute_load_chain)
14527 (vect_transform_grouped_load)
14528 (vect_record_grouped_load_vectors): Likewise.
14529 * tree-vect-loop.c (vect_fixup_reduc_chain)
14530 (get_initial_def_for_reduction, vect_create_epilog_for_reduction)
14531 (vectorize_fold_left_reduction, is_nonwrapping_integer_induction)
14532 (vectorizable_reduction, vectorizable_induction)
14533 (vectorizable_live_operation, vect_loop_kill_debug_uses): Likewise.
14534 * tree-vect-patterns.c (type_conversion_p, adjust_bool_stmts)
14535 (vect_get_load_store_mask): Likewise.
14536 * tree-vect-slp.c (vect_get_place_in_interleaving_chain)
14537 (vect_analyze_slp_instance, vect_mask_constant_operand_p): Likewise.
14538 * tree-vect-stmts.c (vect_mark_relevant)
14539 (is_simple_and_all_uses_invariant)
14540 (exist_non_indexing_operands_for_use_p, process_use)
14541 (vect_init_vector_1, vect_init_vector, vect_get_vec_def_for_operand_1)
14542 (vect_get_vec_def_for_operand, vect_get_vec_defs)
14543 (vect_finish_stmt_generation_1, vect_finish_replace_stmt)
14544 (vect_finish_stmt_generation, vect_truncate_gather_scatter_offset)
14545 (compare_step_with_zero, vect_get_store_rhs, get_group_load_store_type)
14546 (get_negative_load_store_type, get_load_store_type)
14547 (vect_check_load_store_mask, vect_check_store_rhs)
14548 (vect_build_gather_load_calls, vect_get_strided_load_store_ops)
14549 (vectorizable_bswap, vectorizable_call, vectorizable_simd_clone_call)
14550 (vect_create_vectorized_demotion_stmts, vectorizable_conversion)
14551 (vectorizable_assignment, vectorizable_shift, vectorizable_operation)
14552 (get_group_alias_ptr_type, vectorizable_store, hoist_defs_of_uses)
14553 (vectorizable_load, vectorizable_condition, vectorizable_comparison)
14554 (vect_analyze_stmt, vect_transform_stmt, vect_remove_stores)
14555 (supportable_widening_operation): Likewise.
14556
14557 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14558
14559 * tree-vect-data-refs.c (vect_describe_gather_scatter_call): Take
14560 a stmt_vec_info instead of a gcall.
14561 (vect_check_gather_scatter): Update call accordingly.
14562 * tree-vect-loop-manip.c (iv_phi_p): Take a stmt_vec_info instead
14563 of a gphi.
14564 (vect_can_advance_ivs_p, vect_update_ivs_after_vectorizer)
14565 (slpeel_update_phi_nodes_for_loops):): Update calls accordingly.
14566 * tree-vect-loop.c (vect_transform_loop_stmt): Take a stmt_vec_info
14567 instead of a gimple stmt.
14568 (vect_transform_loop): Update calls accordingly.
14569 * tree-vect-slp.c (vect_split_slp_store_group): Take and return
14570 stmt_vec_infos instead of gimple stmts.
14571 (vect_analyze_slp_instance): Update use accordingly.
14572 * tree-vect-stmts.c (read_vector_array, write_vector_array)
14573 (vect_clobber_variable, vect_stmt_relevant_p, permute_vec_elements)
14574 (vect_use_strided_gather_scatters_p, vect_build_all_ones_mask)
14575 (vect_build_zero_merge_argument, vect_get_gather_scatter_ops)
14576 (vect_gen_widened_results_half, vect_get_loop_based_defs)
14577 (vect_create_vectorized_promotion_stmts, can_vectorize_live_stmts):
14578 Take a stmt_vec_info instead of a gimple stmt and pass stmt_vec_infos
14579 down to subroutines.
14580
14581 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14582
14583 * tree-vect-loop.c (vect_analyze_scalar_cycles_1): Change the type
14584 of the worklist from a vector of gimple stmts to a vector of
14585 stmt_vec_infos.
14586 * tree-vect-stmts.c (vect_mark_relevant, process_use)
14587 (vect_mark_stmts_to_be_vectorized): Likewise
14588
14589 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14590
14591 * tree-vect-loop.c (vect_analyze_loop_operations): Look up the
14592 statement before passing it to vect_analyze_stmt.
14593 (vect_create_epilog_for_reduction): Use a stmt_vec_info to walk
14594 the chain of phi vector definitions. Track the exit phi via its
14595 stmt_vec_info.
14596 (vectorizable_reduction): Set cond_stmt_vinfo directly from the
14597 STMT_VINFO_REDUC_DEF.
14598 * tree-vect-slp.c (vect_get_place_in_interleaving_chain): Use
14599 stmt_vec_infos to handle the statement chains.
14600 (vect_get_slp_defs): Record the first statement in the node
14601 using a stmt_vec_info.
14602 * tree-vect-stmts.c (vect_mark_stmts_to_be_vectorized): Look up
14603 statements here and pass their stmt_vec_info down to subroutines.
14604 (vect_init_vector_1): Hoist call to vinfo_for_stmt and pass it
14605 down to vect_finish_stmt_generation.
14606 (vect_init_vector, vect_get_vec_defs, vect_finish_replace_stmt)
14607 (vect_finish_stmt_generation): Call vinfo_for_stmt and pass
14608 stmt_vec_infos to subroutines.
14609 (vect_remove_stores): Use stmt_vec_infos to handle the statement
14610 chains.
14611
14612 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14613
14614 * tree-vect-data-refs.c (vect_slp_analyze_node_dependences):
14615 (vect_check_gather_scatter, vect_create_data_ref_ptr, bump_vector_ptr)
14616 (vect_permute_store_chain, vect_setup_realignment)
14617 (vect_permute_load_chain, vect_shift_permute_load_chain)
14618 (vect_transform_grouped_load): Use stmt_vec_info rather than gimple
14619 stmts internally, and when passing values to other vectorizer routines.
14620 * tree-vect-loop-manip.c (vect_can_advance_ivs_p): Likewise.
14621 * tree-vect-loop.c (vect_analyze_scalar_cycles_1)
14622 (vect_analyze_loop_operations, get_initial_def_for_reduction)
14623 (vect_create_epilog_for_reduction, vectorize_fold_left_reduction)
14624 (vectorizable_reduction, vectorizable_induction)
14625 (vectorizable_live_operation, vect_transform_loop_stmt)
14626 (vect_transform_loop): Likewise.
14627 * tree-vect-patterns.c (vect_reassociating_reduction_p)
14628 (vect_recog_widen_op_pattern, vect_recog_mixed_size_cond_pattern)
14629 (vect_recog_bool_pattern, vect_recog_gather_scatter_pattern): Likewise.
14630 * tree-vect-slp.c (vect_analyze_slp_instance): Likewise.
14631 (vect_slp_analyze_node_operations_1): Likewise.
14632 * tree-vect-stmts.c (vect_mark_relevant, process_use)
14633 (exist_non_indexing_operands_for_use_p, vect_init_vector_1)
14634 (vect_mark_stmts_to_be_vectorized, vect_get_vec_def_for_operand)
14635 (vect_finish_stmt_generation_1, get_group_load_store_type)
14636 (get_load_store_type, vect_build_gather_load_calls)
14637 (vectorizable_bswap, vectorizable_call, vectorizable_simd_clone_call)
14638 (vect_create_vectorized_demotion_stmts, vectorizable_conversion)
14639 (vectorizable_assignment, vectorizable_shift, vectorizable_operation)
14640 (vectorizable_store, vectorizable_load, vectorizable_condition)
14641 (vectorizable_comparison, vect_analyze_stmt, vect_transform_stmt)
14642 (supportable_widening_operation): Likewise.
14643 (vect_get_vector_types_for_stmt): Likewise.
14644 * tree-vectorizer.h (vect_dr_behavior): Likewise.
14645
14646 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14647
14648 * tree-vect-data-refs.c (vect_analyze_data_ref_dependence)
14649 (vect_slp_analyze_node_dependences, vect_analyze_data_ref_accesses)
14650 (vect_permute_store_chain, vect_permute_load_chain)
14651 (vect_shift_permute_load_chain, vect_transform_grouped_load): Avoid
14652 repeated stmt_vec_info lookups.
14653 * tree-vect-loop-manip.c (vect_can_advance_ivs_p): Likewise.
14654 (vect_update_ivs_after_vectorizer): Likewise.
14655 * tree-vect-loop.c (vect_is_simple_reduction): Likewise.
14656 (vect_create_epilog_for_reduction, vectorizable_reduction): Likewise.
14657 * tree-vect-patterns.c (adjust_bool_stmts): Likewise.
14658 * tree-vect-slp.c (vect_analyze_slp_instance): Likewise.
14659 (vect_bb_slp_scalar_cost): Likewise.
14660 * tree-vect-stmts.c (get_group_alias_ptr_type): Likewise.
14661
14662 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14663
14664 * tree-vect-data-refs.c (vect_check_gather_scatter): Pass the
14665 gcall rather than the generic gimple stmt to gimple_call_internal_fn.
14666 (vect_get_smallest_scalar_type, can_group_stmts_p): Use dyn_cast
14667 to get gassigns and gcalls, rather than operating on generc gimple
14668 stmts.
14669 * tree-vect-stmts.c (exist_non_indexing_operands_for_use_p)
14670 (vect_mark_stmts_to_be_vectorized, vectorizable_store)
14671 (vectorizable_load, vect_analyze_stmt): Likewise.
14672 * tree-vect-loop.c (vectorizable_reduction): Likewise gphi.
14673
14674 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14675
14676 * tree-vectorizer.h (get_earlier_stmt, get_later_stmt): Take and
14677 return stmt_vec_infos rather than gimple stmts. Do not accept
14678 null arguments.
14679 (vect_find_last_scalar_stmt_in_slp): Return a stmt_vec_info instead
14680 of a gimple stmt.
14681 * tree-vect-slp.c (vect_find_last_scalar_stmt_in_slp): Likewise.
14682 Update use of get_later_stmt.
14683 (vect_get_constant_vectors): Update call accordingly.
14684 (vect_schedule_slp_instance): Likewise
14685 * tree-vect-data-refs.c (vect_slp_analyze_node_dependences): Likewise.
14686 (vect_slp_analyze_instance_dependence): Likewise.
14687 (vect_preserves_scalar_order_p): Update use of get_earlier_stmt.
14688
14689 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14690
14691 * tree-vectorizer.h (stmt_info_for_cost::stmt): Replace with...
14692 (stmt_info_for_cost::stmt_info): ...this new field.
14693 (add_stmt_costs): Update accordingly.
14694 * tree-vect-loop.c (vect_compute_single_scalar_iteration_cost)
14695 (vect_get_known_peeling_cost): Likewise.
14696 (vect_estimate_min_profitable_iters): Likewise.
14697 * tree-vect-stmts.c (record_stmt_cost): Likewise.
14698
14699 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14700
14701 * tree-vectorizer.h (_loop_vec_info::may_misalign_stmts): Change
14702 from an auto_vec<gimple *> to an auto_vec<stmt_vec_info>.
14703 * tree-vect-data-refs.c (vect_enhance_data_refs_alignment): Update
14704 accordingly.
14705 * tree-vect-loop-manip.c (vect_create_cond_for_align_checks): Likewise.
14706
14707 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14708
14709 * tree-vectorizer.h (_stmt_vec_info::same_dr_stmt): Change from
14710 a gimple stmt to a stmt_vec_info.
14711 * tree-vect-stmts.c (vectorizable_load): Update accordingly.
14712
14713 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14714
14715 * tree-vectorizer.h (vec_info::grouped_stores): Change from
14716 an auto_vec<gimple *> to an auto_vec<stmt_vec_info>.
14717 (_loop_vec_info::reduction_chains): Likewise.
14718 * tree-vect-loop.c (vect_fixup_scalar_cycles_with_patterns): Update
14719 accordingly.
14720 * tree-vect-slp.c (vect_analyze_slp): Likewise.
14721
14722 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14723
14724 * tree-vectorizer.h (_stmt_vec_info::first_element): Change from
14725 a gimple stmt to a stmt_vec_info.
14726 (_stmt_vec_info::next_element): Likewise.
14727 * tree-vect-data-refs.c (vect_update_misalignment_for_peel)
14728 (vect_slp_analyze_and_verify_node_alignment)
14729 (vect_analyze_group_access_1, vect_analyze_group_access)
14730 (vect_small_gap_p, vect_prune_runtime_alias_test_list)
14731 (vect_create_data_ref_ptr, vect_record_grouped_load_vectors)
14732 (vect_supportable_dr_alignment): Update accordingly.
14733 * tree-vect-loop.c (vect_fixup_reduc_chain): Likewise.
14734 (vect_fixup_scalar_cycles_with_patterns, vect_is_slp_reduction)
14735 (vect_is_simple_reduction, vectorizable_reduction): Likewise.
14736 * tree-vect-patterns.c (vect_reassociating_reduction_p): Likewise.
14737 * tree-vect-slp.c (vect_build_slp_tree_1)
14738 (vect_attempt_slp_rearrange_stmts, vect_supported_load_permutation_p)
14739 (vect_split_slp_store_group, vect_analyze_slp_instance)
14740 (vect_analyze_slp, vect_transform_slp_perm_load): Likewise.
14741 * tree-vect-stmts.c (vect_model_store_cost, vect_model_load_cost)
14742 (get_group_load_store_type, get_load_store_type)
14743 (get_group_alias_ptr_type, vectorizable_store, vectorizable_load)
14744 (vect_transform_stmt, vect_remove_stores): Likewise.
14745
14746 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14747
14748 * tree-vectorizer.h (vect_dr_stmt): Return a stmt_vec_info rather
14749 than a gimple stmt.
14750 * tree-vect-data-refs.c (vect_analyze_data_ref_dependence)
14751 (vect_slp_analyze_data_ref_dependence, vect_record_base_alignments)
14752 (vect_calculate_target_alignmentm, vect_compute_data_ref_alignment)
14753 (vect_update_misalignment_for_peel, vect_verify_datarefs_alignment)
14754 (vector_alignment_reachable_p, vect_get_data_access_cost)
14755 (vect_get_peeling_costs_all_drs, vect_peeling_hash_get_lowest_cost)
14756 (vect_peeling_supportable, vect_enhance_data_refs_alignment)
14757 (vect_find_same_alignment_drs, vect_analyze_data_refs_alignment)
14758 (vect_analyze_group_access_1, vect_analyze_group_access)
14759 (vect_analyze_data_ref_access, vect_analyze_data_ref_accesses)
14760 (vect_vfa_access_size, vect_small_gap_p, vect_analyze_data_refs)
14761 (vect_supportable_dr_alignment): Remove vinfo_for_stmt from the
14762 result of vect_dr_stmt and use the stmt_vec_info instead of
14763 the associated gimple stmt.
14764 * tree-vect-loop-manip.c (get_misalign_in_elems): Likewise.
14765 (vect_gen_prolog_loop_niters): Likewise.
14766 * tree-vect-loop.c (vect_analyze_loop_2): Likewise.
14767
14768 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14769
14770 * tree-vectorizer.h (_slp_tree::stmts): Change from a vec<gimple *>
14771 to a vec<stmt_vec_info>.
14772 * tree-vect-slp.c (vect_free_slp_tree): Update accordingly.
14773 (vect_create_new_slp_node): Take a vec<gimple *> instead of a
14774 vec<stmt_vec_info>.
14775 (_slp_oprnd_info::def_stmts): Change from a vec<gimple *>
14776 to a vec<stmt_vec_info>.
14777 (bst_traits::value_type, bst_traits::value_type): Likewise.
14778 (bst_traits::hash): Update accordingly.
14779 (vect_get_and_check_slp_defs): Change the stmts parameter from
14780 a vec<gimple *> to a vec<stmt_vec_info>.
14781 (vect_two_operations_perm_ok_p, vect_build_slp_tree_1): Likewise.
14782 (vect_build_slp_tree): Likewise.
14783 (vect_build_slp_tree_2): Likewise. Update uses of
14784 SLP_TREE_SCALAR_STMTS.
14785 (vect_print_slp_tree): Update uses of SLP_TREE_SCALAR_STMTS.
14786 (vect_mark_slp_stmts, vect_mark_slp_stmts_relevant)
14787 (vect_slp_rearrange_stmts, vect_attempt_slp_rearrange_stmts)
14788 (vect_supported_load_permutation_p, vect_find_last_scalar_stmt_in_slp)
14789 (vect_detect_hybrid_slp_stmts, vect_slp_analyze_node_operations_1)
14790 (vect_slp_analyze_node_operations, vect_slp_analyze_operations)
14791 (vect_bb_slp_scalar_cost, vect_slp_analyze_bb_1)
14792 (vect_get_constant_vectors, vect_get_slp_defs)
14793 (vect_transform_slp_perm_load, vect_schedule_slp_instance)
14794 (vect_remove_slp_scalar_calls, vect_schedule_slp): Likewise.
14795 (vect_analyze_slp_instance): Build up a vec of stmt_vec_infos
14796 instead of gimple stmts.
14797 * tree-vect-data-refs.c (vect_slp_analyze_node_dependences): Change
14798 the stores parameter for a vec<gimple *> to a vec<stmt_vec_info>.
14799 (vect_slp_analyze_instance_dependence): Update uses of
14800 SLP_TREE_SCALAR_STMTS.
14801 (vect_slp_analyze_and_verify_node_alignment): Likewise.
14802 (vect_slp_analyze_and_verify_instance_alignment): Likewise.
14803 * tree-vect-loop.c (neutral_op_for_slp_reduction): Likewise.
14804 (get_initial_defs_for_reduction): Likewise.
14805 (vect_create_epilog_for_reduction): Likewise.
14806 (vectorize_fold_left_reduction): Likewise.
14807 * tree-vect-stmts.c (vect_prologue_cost_for_slp_op): Likewise.
14808 (vect_model_simple_cost, vectorizable_shift, vectorizable_load)
14809 (can_vectorize_live_stmts): Likewise.
14810
14811 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14812
14813 * tree-vectorizer.h (_loop_vec_info::reductions): Change from an
14814 auto_vec<gimple *> to an auto_vec<stmt_vec_info>.
14815 (vect_force_simple_reduction): Take and return stmt_vec_infos rather
14816 than gimple stmts.
14817 * tree-parloops.c (valid_reduction_p): Take a stmt_vec_info instead
14818 of a gimple stmt.
14819 (gather_scalar_reductions): Update after above interface changes.
14820 * tree-vect-loop.c (vect_analyze_scalar_cycles_1): Likewise.
14821 (vect_is_simple_reduction): Take and return stmt_vec_infos rather
14822 than gimple stmts.
14823 (vect_force_simple_reduction): Likewise.
14824 * tree-vect-patterns.c (vect_pattern_recog_1): Update use of
14825 LOOP_VINFO_REDUCTIONS.
14826 * tree-vect-slp.c (vect_analyze_slp_instance): Likewise.
14827
14828 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14829
14830 * tree-vectorizer.h (_stmt_vec_info::reduc_def): Change from
14831 a gimple stmt to a stmt_vec_info.
14832 * tree-vect-loop.c (vect_active_double_reduction_p)
14833 (vect_force_simple_reduction, vectorizable_reduction): Update
14834 accordingly.
14835
14836 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14837
14838 * tree-vectorizer.h (_slp_tree::vec_stmts): Change from a
14839 vec<gimple *> to a vec<stmt_vec_info>.
14840 * tree-vect-loop.c (vect_create_epilog_for_reduction): Change
14841 the reduction_phis argument from a vec<gimple *> to a
14842 vec<stmt_vec_info>.
14843 (vectorizable_reduction): Likewise the phis local variable that
14844 is passed to vect_create_epilog_for_reduction. Update for new type
14845 of SLP_TREE_VEC_STMTS.
14846 (vectorizable_induction): Update for new type of SLP_TREE_VEC_STMTS.
14847 (vectorizable_live_operation): Likewise.
14848 * tree-vect-slp.c (vect_get_slp_vect_defs): Likewise.
14849 (vect_transform_slp_perm_load, vect_schedule_slp_instance): Likewise.
14850
14851 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14852
14853 * tree-vectorizer.h (_stmt_vec_info::vectorized_stmt): Change from
14854 a gimple stmt to a stmt_vec_info.
14855 (vectorizable_condition, vectorizable_live_operation)
14856 (vectorizable_reduction, vectorizable_induction): Pass back the
14857 vectorized statement as a stmt_vec_info.
14858 * tree-vect-data-refs.c (vect_record_grouped_load_vectors): Update
14859 use of STMT_VINFO_VEC_STMT.
14860 * tree-vect-loop.c (vect_create_epilog_for_reduction): Likewise,
14861 accumulating the inner phis that feed the STMT_VINFO_VEC_STMT
14862 as stmt_vec_infos rather than gimple stmts.
14863 (vectorize_fold_left_reduction): Change vec_stmt from a gimple stmt
14864 to a stmt_vec_info.
14865 (vectorizable_live_operation): Likewise.
14866 (vectorizable_reduction, vectorizable_induction): Likewise,
14867 updating use of STMT_VINFO_VEC_STMT.
14868 * tree-vect-stmts.c (vect_get_vec_def_for_operand_1): Update use
14869 of STMT_VINFO_VEC_STMT.
14870 (vect_build_gather_load_calls, vectorizable_bswap, vectorizable_call)
14871 (vectorizable_simd_clone_call, vectorizable_conversion)
14872 (vectorizable_assignment, vectorizable_shift, vectorizable_operation)
14873 (vectorizable_store, vectorizable_load, vectorizable_condition)
14874 (vectorizable_comparison, can_vectorize_live_stmts): Change vec_stmt
14875 from a gimple stmt to a stmt_vec_info.
14876 (vect_transform_stmt): Update use of STMT_VINFO_VEC_STMT. Pass a
14877 pointer to a stmt_vec_info to the vectorizable_* routines.
14878
14879 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14880
14881 * tree-vectorizer.h (_stmt_vec_info::related_stmt): Change from
14882 a gimple stmt to a stmt_vec_info.
14883 (is_pattern_stmt_p): Update accordingly.
14884 * tree-vect-data-refs.c (vect_preserves_scalar_order_p): Likewise.
14885 (vect_record_grouped_load_vectors): Likewise.
14886 * tree-vect-loop.c (vect_determine_vf_for_stmt): Likewise.
14887 (vect_fixup_reduc_chain, vect_update_vf_for_slp): Likewise.
14888 (vect_model_reduction_cost): Likewise.
14889 (vect_create_epilog_for_reduction): Likewise.
14890 (vectorizable_reduction, vectorizable_induction): Likewise.
14891 * tree-vect-patterns.c (vect_init_pattern_stmt): Likewise.
14892 Return the stmt_vec_info for the pattern statement.
14893 (vect_set_pattern_stmt): Update use of STMT_VINFO_RELATED_STMT.
14894 (vect_split_statement, vect_mark_pattern_stmts): Likewise.
14895 * tree-vect-slp.c (vect_detect_hybrid_slp_stmts): Likewise.
14896 (vect_detect_hybrid_slp, vect_get_slp_defs): Likewise.
14897 * tree-vect-stmts.c (vect_mark_relevant): Likewise.
14898 (vect_get_vec_def_for_operand_1, vectorizable_call): Likewise.
14899 (vectorizable_simd_clone_call, vect_analyze_stmt, new_stmt_vec_info)
14900 (free_stmt_vec_info, vect_is_simple_use): Likewise.
14901
14902 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14903
14904 * tree-vectorizer.h (vect_finish_replace_stmt): Return a stmt_vec_info
14905 (vect_finish_stmt_generation): Likewise.
14906 * tree-vect-stmts.c (vect_finish_stmt_generation_1): Likewise.
14907 (vect_finish_replace_stmt, vect_finish_stmt_generation): Likewise.
14908 (vect_build_gather_load_calls): Use the return value of the above
14909 functions instead of a separate call to vinfo_for_stmt. Use narrow
14910 scopes for the input gimple stmt and wider scopes for the associated
14911 stmt_vec_info. Use vec_info::lookup_def when setting these
14912 stmt_vec_infos from an SSA_NAME definition.
14913 (vectorizable_bswap, vectorizable_call, vectorizable_simd_clone_call)
14914 (vect_create_vectorized_demotion_stmts, vectorizable_conversion)
14915 (vectorizable_assignment, vectorizable_shift, vectorizable_operation)
14916 (vectorizable_store, vectorizable_load, vectorizable_condition)
14917 (vectorizable_comparison): Likewise.
14918 * tree-vect-loop.c (vectorize_fold_left_reduction): Likewise.
14919 (vectorizable_reduction): Likewise.
14920
14921 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14922
14923 * tree-vectorizer.h (vect_is_simple_use): Add an optional
14924 stmt_vec_info * parameter before the optional gimple **.
14925 * tree-vect-stmts.c (vect_is_simple_use): Likewise.
14926 (process_use, vect_get_vec_def_for_operand_1): Update callers.
14927 (vect_get_vec_def_for_operand, vectorizable_shift): Likewise.
14928 * tree-vect-loop.c (vectorizable_reduction): Likewise.
14929 (vectorizable_live_operation): Likewise.
14930 * tree-vect-patterns.c (type_conversion_p): Likewise.
14931 (vect_look_through_possible_promotion): Likewise.
14932 (vect_recog_rotate_pattern): Likewise.
14933 * tree-vect-slp.c (vect_get_and_check_slp_defs): Likewise.
14934
14935 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14936
14937 * tree-vectorizer.h (stmt_vec_info): Temporarily change from
14938 a typedef to a wrapper class.
14939 (NULL_STMT_VEC_INFO): New macro.
14940 (vec_info::stmt_infos): Change to vec<stmt_vec_info>.
14941 (stmt_vec_info::operator*): New function.
14942 (stmt_vec_info::operator gimple *): Likewise.
14943 (set_vinfo_for_stmt): Use NULL_STMT_VEC_INFO.
14944 (add_stmt_costs): Likewise.
14945 * tree-vect-loop-manip.c (iv_phi_p): Likewise.
14946 * tree-vect-loop.c (vect_compute_single_scalar_iteration_cost)
14947 (vect_get_known_peeling_cost): Likewise.
14948 (vect_estimate_min_profitable_iters): Likewise.
14949 * tree-vect-patterns.c (vect_init_pattern_stmt): Likewise.
14950 * tree-vect-slp.c (vect_remove_slp_scalar_calls): Likewise.
14951 * tree-vect-stmts.c (vect_build_gather_load_calls): Likewise.
14952 (vectorizable_store, free_stmt_vec_infos): Likewise.
14953 (new_stmt_vec_info): Change return type of xcalloc to
14954 _stmt_vec_info *.
14955
14956 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14957
14958 * tree-vectorizer.h (vec_info::lookup_single_use): Declare.
14959 * tree-vectorizer.c (vec_info::lookup_single_use): New function.
14960 * tree-vect-loop.c (vectorizable_reduction): Use it instead of
14961 a single_imm_use-based sequence.
14962 * tree-vect-stmts.c (supportable_widening_operation): Likewise.
14963
14964 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14965
14966 * tree-vectorizer.h (vec_info::lookup_def): Declare.
14967 * tree-vectorizer.c (vec_info::lookup_def): New function.
14968 * tree-vect-patterns.c (vect_get_internal_def): Use it.
14969 (vect_widened_op_tree): Likewise.
14970 * tree-vect-stmts.c (vect_is_simple_use): Likewise.
14971 * tree-vect-loop.c (vect_analyze_loop_operations): Likewise.
14972 (vectorizable_reduction): Likewise.
14973 (vect_valid_reduction_input_p): Take a stmt_vec_info instead
14974 of a gimple *.
14975 (vect_is_slp_reduction): Update calls accordingly. Use
14976 vec_info::lookup_def.
14977 (vect_is_simple_reduction): Likewise
14978 * tree-vect-slp.c (vect_detect_hybrid_slp_1): Use vec_info::lookup_def.
14979
14980 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14981
14982 * tree-vectorizer.h (vec_info::lookup_stmt): Declare.
14983 * tree-vectorizer.c (vec_info::lookup_stmt): New function.
14984 * tree-vect-loop.c (vect_determine_vf_for_stmt): Use it instead
14985 of vinfo_for_stmt.
14986 (vect_determine_vectorization_factor, vect_analyze_scalar_cycles_1)
14987 (vect_compute_single_scalar_iteration_cost, vect_analyze_loop_form)
14988 (vect_update_vf_for_slp, vect_analyze_loop_operations)
14989 (vect_is_slp_reduction, vectorizable_induction)
14990 (vect_transform_loop_stmt, vect_transform_loop): Likewise.
14991 * tree-vect-patterns.c (vect_init_pattern_stmt):
14992 (vect_determine_min_output_precision_1, vect_determine_precisions)
14993 (vect_pattern_recog): Likewise.
14994 * tree-vect-stmts.c (vect_analyze_stmt, vect_transform_stmt): Likewise.
14995 * config/powerpcspe/powerpcspe.c (rs6000_density_test): Likewise.
14996 * config/rs6000/rs6000.c (rs6000_density_test): Likewise.
14997 * tree-vect-slp.c (vect_detect_hybrid_slp_stmts): Likewise.
14998 (vect_detect_hybrid_slp_1, vect_detect_hybrid_slp_2)
14999 (vect_detect_hybrid_slp): Likewise. Change the walk_stmt_info
15000 info field from a loop to a loop_vec_info.
15001
15002 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
15003
15004 * tree-vectorizer.h (stmt_vec_info): Move typedef earlier in file.
15005 (vec_info::add_stmt): Declare.
15006 * tree-vectorizer.c (vec_info::add_stmt): New function.
15007 * tree-vect-data-refs.c (vect_create_data_ref_ptr): Use it.
15008 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Likewise.
15009 (vect_create_epilog_for_reduction, vectorizable_reduction): Likewise.
15010 (vectorizable_induction): Likewise.
15011 * tree-vect-slp.c (_bb_vec_info::_bb_vec_info): Likewise.
15012 * tree-vect-stmts.c (vect_finish_stmt_generation_1): Likewise.
15013 (vectorizable_simd_clone_call, vectorizable_store): Likewise.
15014 (vectorizable_load): Likewise.
15015 * tree-vect-patterns.c (vect_init_pattern_stmt): Likewise.
15016 (vect_recog_bool_pattern, vect_recog_mask_conversion_pattern)
15017 (vect_recog_gather_scatter_pattern): Likewise.
15018 (append_pattern_def_seq): Likewise. Remove a check that is
15019 performed by add_stmt itself.
15020
15021 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
15022
15023 * tree-vect-loop.c (vectorizable_reduction): Fix an instance in
15024 which make_ssa_name was called with new_stmt before new_stmt
15025 had been created.
15026
15027 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
15028
15029 * tree-vect-loop.c (vect_valid_reduction_input_p): New function,
15030 split out from...
15031 (vect_is_slp_reduction): ...here...
15032 (vect_is_simple_reduction): ...and here. Remove repetition of tests
15033 that are already known to be false.
15034
15035 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
15036
15037 * tree-vectorizer.h (vect_free_slp_instance): Add a final_p parameter.
15038 * tree-vect-slp.c (vect_free_slp_tree): Likewise. Don't update
15039 STMT_VINFO_NUM_SLP_USES when it's true.
15040 (vect_free_slp_instance): Add a final_p parameter and pass it to
15041 vect_free_slp_tree.
15042 (vect_build_slp_tree_2): Update call to vect_free_slp_instance.
15043 (vect_analyze_slp_instance): Likewise.
15044 (vect_slp_analyze_operations): Likewise.
15045 (vect_slp_analyze_bb_1): Likewise.
15046 * tree-vectorizer.c (vec_info): Likewise.
15047 * tree-vect-loop.c (vect_transform_loop): Likewise.
15048
15049 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
15050
15051 * tree-vect-loop.c (vectorizable_reduction): Assert that the
15052 function is not called for second and subsequent members of
15053 a reduction group.
15054
15055 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
15056
15057 * tree-vect-loop.c (get_initial_def_for_reduction): Move special
15058 cases for nested loops from here to ...
15059 (vect_create_epilog_for_reduction): ...here. Only call
15060 vect_is_simple_use for inner-loop reductions.
15061
15062 2018-07-31 Martin Liska <mliska@suse.cz>
15063
15064 PR gcov-profile/85338
15065 PR gcov-profile/85350
15066 PR gcov-profile/85372
15067 * profile.c (struct location_triplet): New.
15068 (struct location_triplet_hash): Likewise.
15069 (output_location): Do not output a BB that
15070 is already recorded for a line.
15071 (branch_prob): Use streamed_locations.
15072
15073 2018-07-31 Martin Liska <mliska@suse.cz>
15074
15075 PR gcov-profile/85370
15076 * coverage.c (coverage_begin_function): Do not mark target
15077 clones as artificial functions.
15078
15079 2018-07-31 Martin Liska <mliska@suse.cz>
15080
15081 PR gcov-profile/83813
15082 PR gcov-profile/84758
15083 PR gcov-profile/85217
15084 PR gcov-profile/85332
15085 * profile.c (branch_prob): Do not record GOTO expressions
15086 for GIMPLE statements which locations are already streamed.
15087
15088 2018-07-31 Olivier Hainque <hainque@adacore.com>
15089
15090 * gcc.c (handle_spec_function): Accept a soft_matched_part
15091 argument, as do_spec_1. Pass it down to ...
15092 (eval_spec_function): Accept a soft_matched_part argument,
15093 and pass it down to ...
15094 (do_spec_2): Accept a soft_matched_part argument, and pass
15095 it down to do_spec_1.
15096 (do_spec_1): Pass soft_matched_part to handle_spec_function.
15097 (handle_braces): Update call to handle_spec_function.
15098 (driver::set_up_specs): Update calls to do_spec_2.
15099 (compare_debug_dump_opt_spec_function): Likewise.
15100 (compare_debug_self_opt_spec_function): Likewise.
15101
15102 2018-07-31 Olivier Hainque <hainque@adacore.com>
15103
15104 * common.opt (nolibc): New option.
15105 * doc/invoke.texi (Link Options): Document it.
15106 * gcc.c (LINK_GCC_C_SEQUENCE_SPEC): Honor nolibc.
15107 * config/alpha/linux.h: Likewise.
15108 * config/arc/elf.h: Likewise.
15109 * config/arm/uclinux-elf.h: Likewise.
15110 * config/arm/unknown-elf.h: Likewise.
15111 * config/avr/avrlibc.h: Likewise.
15112 * config/bfin/bfin.h: Likewise.
15113 * config/bfin/linux.h: Likewise.
15114 * config/bfin/uclinux.h: Likewise.
15115 * config/darwin.h: Likewise.
15116 * config/darwin10.h: Likewise.
15117 * config/darwin12.h: Likewise.
15118 * config/gnu-user.h: Likewise.
15119 * config/lm32/uclinux-elf.h: Likewise.
15120 * config/pa/pa-hpux11.h: Likewise.
15121 * config/pa/pa64-hpux.h: Likewise.
15122 * config/sparc/sparc.h: Likewise.
15123
15124 2018-07-31 Olivier Hainque <hainque@adacore.com>
15125
15126 * gcc.c (getenv_spec_function): Prepend '/' to value for allowed
15127 undefined variables.
15128
15129 2018-07-30 Segher Boessenkool <segher@kernel.crashing.org>
15130
15131 PR target/86640
15132 * config/arm/arm.c (arm_block_set_aligned_vect): Use gen_int_mode
15133 instead of GEN_INT.
15134
15135 2018-07-30 Bernd Edlinger <bernd.edlinger@hotmail.de>
15136
15137 * tree-ssa-forwprop.c (simplify_builtin_call): Don't create a not NUL
15138 terminated string literal.
15139
15140 2018-07-30 Segher Boessenkool <segher@kernel.crashing.org>
15141
15142 PR rtl-optimization/85160
15143 * combine.c (is_just_move): New function.
15144 (try_combine): Allow combining two instructions into two if neither of
15145 the original instructions was a move.
15146
15147 2018-07-30 Alexander Monakov <amonakov@ispras.ru>
15148
15149 PR target/86673
15150 * doc/extend.texi (Global Register Variables): Discourage use of type
15151 qualifiers.
15152 (Local Register Variables): Likewise.
15153
15154 2018-07-30 Richard Sandiford <richard.sandiford@arm.com>
15155
15156 PR tree-optimization/86506
15157 * hwint.h (ceil_log2): Resync with hwint.c implementation.
15158
15159 2018-07-30 Ilya Leoshkevich <iii@linux.ibm.com>
15160
15161 PR target/86547
15162 * lra-constraints.c (spill_hard_reg_in_range): When selecting the
15163 hard_regno, make sure no insn between `from` and `to` clobbers it.
15164
15165 2018-07-30 Cesar Philippidis <cesar@codesourcery.com>
15166 Tom de Vries <tdevries@suse.de>
15167
15168 * config/nvptx/nvptx.c (PTX_GANG_DEFAULT): Rename to ...
15169 (PTX_DEFAULT_RUNTIME_DIM): ... this.
15170 (nvptx_goacc_validate_dims): Set default worker and gang dims to
15171 PTX_DEFAULT_RUNTIME_DIM.
15172 (nvptx_dim_limit): Ignore GOMP_DIM_WORKER.
15173
15174 2018-07-29 John David Anglin <danglin@gcc.gnu.org>
15175
15176 * config/pa/pa.c (pa_output_addr_vec): Align address table.
15177 * config/pa/pa.h (JUMP_TABLES_IN_TEXT_SECTION): Revise comment.
15178 * config/pa/pa32-linux.h (JUMP_TABLES_IN_TEXT_SECTION): Define.
15179
15180 2018-07-27 Michael Meissner <meissner@linux.ibm.com>
15181
15182 * config/rs6000/constraints.md (wG constraint): Delete, no longer
15183 used.
15184 * config/rs6000/predicates.md (p9_fusion_reg_operand): Rename
15185 predicate to reflect toc fusion has been deleted.
15186 (toc_fusion_mem_raw): Delete, no longer used.
15187 (toc_fusion_mem_wrapped): Likewise.
15188 * config/rs6000/rs6000-cpus.def (POWERPC_MASKS): Delete toc
15189 fusion mask bit.
15190 * config/rs6000/rs6000-protos.h (fusion_wrap_memory_address):
15191 Delete, no longer used.
15192 * config/rs6000/rs6000.c (struct rs6000_reg_addr): Delete fields
15193 meant to be used for toc fusion.
15194 (rs6000_debug_print_mode): Delete toc fusion debugging.
15195 (rs6000_debug_reg_global): Likewise.
15196 (rs6000_init_hard_regno_mode_ok): Delete setting up fields for toc
15197 fusion and secondary reload support that were never used.
15198 (rs6000_option_override_internal): Delete TOC fusion, that was only
15199 partially defined, and it did not work unless you also used the
15200 -mcmodel= switch.
15201 (rs6000_legitimate_address_p): Delete TOC fusion support.
15202 (rs6000_opt_masks): Likewise.
15203 (fusion_wrap_memory_address): Delete function, no longer used.
15204 (fusion_split_address); Delete TOC fusion support.
15205 * config/rs6000/rs6000.h (TARGET_TOC_FUSION_INT): Delete, no
15206 longer used with toc fusion being deleted.
15207 (TARGET_TOC_FUSION_FP): Likewise.
15208 * config/rs6000/rs6000.md (UNSPEC_FUSION_ADDIS): Delete TOC fusion
15209 UNSPEC.
15210 (toc fusion spliter): Delete TOC fusion support.
15211 (toc_fusionload_<mode>): Likewise.
15212 (toc_fusionload_di): Likewise.
15213 (fusion_gpr_load_<mode>): Delete generator function, this insn no
15214 longer needs to be named. Rename predicate to delete TOC fusion.
15215 (fusion_gpr_<P:mode>_<GPR_FUSION:mode>_load): Likewise.
15216 (fusion_gpr_<P:mode>_<GPR_FUSION:mode>_store): Likewise.
15217 (fusion_vsx_<P:mode>_<GPR_FUSION:mode>_load): Likewise.
15218 (fusion_vsx_<P:mode>_<GPR_FUSION:mode>_store): Likewise.
15219 (p9 fusion peephole2s): Rename predicate to delete TOC fusion.
15220
15221 2018-07-27 Kelvin Nilsen <kelvin@gcc.gnu.org>
15222
15223 * doc/extend.texi (Basic PowerPC Built-in Functions Available on
15224 ISA 2.05): Replace __uint128_t with __uint128 and __int128_t with
15225 __int128 in built-in function prototypes.
15226 (PowerPC AltiVec Built-in Functions on ISA 2.07): Likewise.
15227 (PowerPC AltiVec Built-in Functions on ISA 3.0): Likewise.
15228
15229 2018-07-27 Martin Sebor <msebor@redhat.com>
15230
15231 PR tree-optimization/86696
15232 * tree-ssa-strlen.c (get_min_string_length): Handle all integer
15233 types, including enums.
15234 (handle_char_store): Be prepared for the above function to fail.
15235
15236 2018-07-26 Qing Zhao <qing.zhao@oracle.com>
15237
15238 * builtins.c (inline_expand_builtin_string_cmp): Disable inlining
15239 when optimization level is lower than 2 or optimize for size.
15240
15241 2018-07-26 Martin Sebor <msebor@redhat.com>
15242
15243 PR tree-optimization/86043
15244 PR tree-optimization/86042
15245 * tree-ssa-strlen.c (handle_builtin_memcpy): Handle strict overlaps.
15246 (get_string_cst_length): Rename...
15247 (get_min_string_length): ...to this. Add argument.
15248 (handle_char_store): Extend to handle multi-character stores by
15249 MEM_REF.
15250 * tree.c (initializer_zerop): Use new argument. Handle MEM_REF.
15251 * tree.h (initializer_zerop): Add argument.
15252
15253 2018-07-26 Jakub Jelinek <jakub@redhat.com>
15254
15255 PR middle-end/86660
15256 * omp-low.c (scan_sharing_clauses): Don't ignore map clauses for
15257 declare target to variables if they have always,{to,from,tofrom} map
15258 kinds.
15259
15260 2018-07-26 Martin Liska <mliska@suse.cz>
15261
15262 PR lto/86548
15263 * lto-wrapper.c: Add linker_output as prefix
15264 for ltrans_output_file.
15265
15266 2018-07-26 Segher Boessenkool <segher@kernel.crashing.org>
15267
15268 PR rtl-optimization/85805
15269 * combine.c (reg_nonzero_bits_for_combine): Only use the last set
15270 value for hard registers if that was written in the same mode.
15271
15272 2018-07-26 Martin Liska <mliska@suse.cz>
15273
15274 PR gcov-profile/86536
15275 * gcov.c (format_gcov): Use printf format %.*f directly
15276 and do not handle special values.
15277
15278 2018-07-25 Claudiu Zissulescu <claziss@synopsys.com>
15279
15280 * common/config/arc/arc-common.c (arc_option_optimization_table):
15281 Update default optimizations for size.
15282
15283 2018-07-25 Claudiu Zissulescu <claziss@synopsys.com>
15284
15285 * config/arc/arc.md (movsf_insn): Add short instruction selection.
15286 * config/arc/constraints.md (CfZ): New constraint.
15287 * config/arc/fpu.md (addssf3_fpu): Use CfZ constraint.
15288 (subsf3_fpu): Likewise.
15289 (cmpsf_fpu): Likewise.
15290 (cmpsf_fpu_uneq): Likewise.
15291
15292 2018-07-25 Claudiu Zissulescu <claziss@synopsys.com>
15293
15294 * config/arc/arc.c (compact_memory_operand_p): Check for uncached
15295 accesses as well.
15296 (arc_is_uncached_mem_p): uncached applies to both the variable and
15297 the pointer.
15298
15299 2018-07-25 Claudiu Zissulescu <claziss@synopsys.com>
15300
15301 * config/arc/arc.h (ADDITIONAL_REGISTER_NAMES): Add additional
15302 register names.
15303
15304 2018-07-25 David Malcolm <dmalcolm@redhat.com>
15305
15306 * optinfo-emit-json.cc (class optrecord_json_writer): Convert
15307 field "m_scopes" from vec to auto_vec.
15308
15309 2018-07-25 Martin Liska <mliska@suse.cz>
15310
15311 * config/powerpcspe/powerpcspe-protos.h (rs6000_loop_align): Fix
15312 return type.
15313
15314 2018-07-25 Richard Biener <rguenther@suse.de>
15315
15316 PR debug/86654
15317 * dwarf2out.c (dwarf2out_decl): Do not handle nested functions
15318 special wrt context_die late.
15319 (gen_subprogram_die): Re-use DIEs in local scope.
15320
15321 2018-07-25 Richard Sandiford <richard.sandiford@arm.com>
15322
15323 PR tree-optimization/86644
15324 * hwint.c (ceil_log2): Fix comment. Return 0 for 0.
15325
15326 2018-07-25 Martin Liska <mliska@suse.cz>
15327
15328 PR middle-end/86645
15329 * dumpfile.c: And excluded values with TDF_ALL_VALUES.
15330 * dumpfile.h (enum dump_flag): Defince TDF_ALL_VALUES.
15331
15332 2018-07-25 Martin Liska <mliska@suse.cz>
15333
15334 PR sanitizer/79635
15335 * params.def: Explain ASan abbreviation and provide
15336 a documentation link.
15337
15338 2018-07-24 Martin Sebor <msebor@redhat.com>
15339
15340 PR tree-optimization/86622
15341 PR tree-optimization/86532
15342 * builtins.h (string_length): Declare.
15343 * builtins.c (c_strlen): Correct handling of non-constant offsets.
15344 (check_access): Be prepared for non-constant length ranges.
15345 (string_length): Make extern.
15346 * expr.c (string_constant): Only handle the minor non-constant
15347 array index. Use string_constant to compute the length of
15348 a generic string constant.
15349
15350 2018-07-24 Richard Sandiford <richard.sandiford@arm.com>
15351
15352 PR tree-optimization/86618
15353 * tree-vect-stmts.c (vectorizable_call): Don't take the address
15354 of LOOP_VINFO_MASKS (loop_vinfo) when loop_vinfo is null.
15355
15356 2018-07-24 David Malcolm <dmalcolm@redhat.com>
15357
15358 PR tree-optimization/86636
15359 * json.cc (json::object::set): Fix comment. Add assertions.
15360 (json::array::append): Move here from json.h. Add comment and an
15361 assertion.
15362 (json::string::string): Likewise.
15363 * json.h (json::array::append): Move to json.cc.
15364 (json::string::string): Likewise.
15365 * optinfo-emit-json.cc
15366 (optrecord_json_writer::impl_location_to_json): Assert that we
15367 aren't attempting to write out UNKNOWN_LOCATION, or an ad-hoc
15368 wrapper around it. Expand the location once, rather than three
15369 times.
15370 (optrecord_json_writer::inlining_chain_to_json): Fix the check for
15371 UNKNOWN_LOCATION, to use LOCATION_LOCUS to look through ad-hoc
15372 wrappers.
15373 (optrecord_json_writer::optinfo_to_json): Likewise, in four
15374 places. Fix some overlong lines.
15375
15376 2018-07-24 Matthew Malcomson <matthew.malcomson@arm.com>
15377
15378 * config/aarch64/aarch64-simd.md
15379 (aarch64_<ANY_EXTEND:su><ADDSUB:optab>w<mode>): Split into...
15380 (aarch64_<ANY_EXTEND:su>subw<mode>): ... This...
15381 (aarch64_<ANY_EXTEND:su>addw<mode>): ... And this.
15382 (aarch64_<ANY_EXTEND:su><ADDSUB:optab>w<mode>_internal): Split into...
15383 (aarch64_<ANY_EXTEND:su>subw<mode>_internal): ... This...
15384 (aarch64_<ANY_EXTEND:su>addw<mode>_internal): ... And this.
15385 (aarch64_<ANY_EXTEND:su><ADDSUB:optab>w2<mode>_internal): Split into...
15386 (aarch64_<ANY_EXTEND:su>subw2<mode>_internal): ... This...
15387 (aarch64_<ANY_EXTEND:su>addw2<mode>_internal): ... And this.
15388
15389 2018-07-24 Jakub Jelinek <jakub@redhat.com>
15390
15391 PR middle-end/86627
15392 * expmed.c (expand_divmod): Punt if d == HOST_WIDE_INT_MIN
15393 and size > HOST_BITS_PER_WIDE_INT. For size > HOST_BITS_PER_WIDE_INT
15394 and abs_d == d, do the power of two handling if profitable.
15395
15396 2018-07-24 Richard Biener <rguenther@suse.de>
15397
15398 * match.pd: Add BIT_FIELD_REF canonicalizations.
15399
15400 2018-07-23 Bernd Edlinger <bernd.edlinger@hotmail.de>
15401
15402 PR c/86617
15403 * genmatch.c (dt_operand::gen_match_op): Avoid folding volatile values.
15404
15405 2018-07-23 Bernd Edlinger <bernd.edlinger@hotmail.de>
15406
15407 * gimple-fold.c (gimple_fold_builtin_printf): Don't create a not NUL
15408 terminated STRING_CST object.
15409
15410 2018-07-23 Bernd Edlinger <bernd.edlinger@hotmail.de>
15411
15412 hsa-dump.c (dump_hsa_symbol): Avoid out of scope access to buf.
15413
15414 2018-07-23 Segher Boessenkool <segher@kernel.crashing.org>
15415
15416 * config/rs6000/rs6000-p8swap.c (rtx_is_swappable_p): Adjust.
15417 * config/rs6000/rs6000-protos.h (rs6000_split_v4si_init): Delete.
15418 * config/rs6000/rs6000.c (rs6000_expand_vector_init): Always force
15419 the elements into a register.
15420 (rs6000_split_v4si_init_di_reg): Delete.
15421 (rs6000_split_v4si_init): Delete.
15422 * config/rs6000/vsx.md (unspec): Delete UNSPEC_VSX_VEC_INIT.
15423 (vsx_init_v4si): Rewrite as a define_expand.
15424
15425 2018-07-23 Segher Boessenkool <segher@kernel.crashing.org>
15426
15427 * config/rs6000/rs6000.md (splitters for rldimi and rlwimi with the
15428 zero_extend argument from memory): New.
15429
15430 2018-07-22 Martin Sebor <msebor@redhat.com>
15431
15432 PR bootstrap/86621
15433 * gimple-ssa-warn-alloca.c (alloca_call_type_by_arg): Avoid
15434 diagnosing calls with unknown arguments unless -Walloca-larger-than
15435 is restricted to less than PTRDIFF_MAX bytes.
15436
15437 2018-07-22 Gerald Pfeifer <gerald@pfeifer.com>
15438
15439 * doc/gcov.texi (Invoking Gcov): Editorial changes.
15440
15441 2018-07-20 David Malcolm <dmalcolm@redhat.com>
15442
15443 * pretty-print.c (text_info::set_location): Remove redundant
15444 "line_table" parameter from call to rich_location::set_range.
15445
15446 2018-07-20 Martin Sebor <msebor@redhat.com>
15447
15448 PR middle-end/82063
15449 * builtins.c (expand_builtin_alloca): Adjust.
15450 * calls.c (alloc_max_size): Simplify.
15451 * cgraphunit.c (cgraph_node::expand): Adjust.
15452 * common.opt (larger_than_size, warn_frame_larger_than): Remove
15453 variables.
15454 (frame_larger_than_size): Same.
15455 (-Wframe-larger-than, -Wlarger-than, -Wstack-usage): Change options
15456 to take a HOST_WIDE_INT argument and accept a byte-size suffix.
15457 Initialize.
15458 * doc/invoke.texi (GCC Command Options): Document option arguments.
15459 Explain byte-size arguments and suffixes.
15460 (-Wvla-larger-than, -Wno-alloc-size-larger-than): Update.
15461 (-Wno-alloca-larger-than, -Wno-vla-larger-than): Same.
15462 (-Wframe-larger-than, -Wlarger-than, -Wstack-usage): Same.
15463 * doc/options.texi (UInteger): Expand.
15464 (Host_Wide_Int, ByteSize): Document new properties.
15465 * final.c (final_start_function_1): Include sizes in an error message.
15466 * function.c (frame_offset_overflow): Same.
15467 * gimple-ssa-warn-alloca.c (pass_walloca::gate): Adjust.
15468 (alloca_call_type_by_arg): Change function argument to HOST_WIDE_INT.
15469 Diagnose unbounded alloca calls only for limits of less than
15470 PTRDIFF_MAX.
15471 (alloca_call_type): Adjust. Diagnose possibly out-of-bounds alloca
15472 calls and VLA size only for limits of less than PTRDIFF_MAX. Same
15473 for alloca(0).
15474 (pass_walloca::execute): Adjust. Diagnose alloca calls in loops
15475 only for limits of less than PTRDIFF_MAX.
15476 * langhooks-def.h (lhd_handle_option): Change function argument
15477 to HOST_WIDE_INT.
15478 * langhooks.c (lhd_handle_option): Same.
15479 * langhooks.h (handle_option): Same.
15480 * opt-functions.awk (switch_bit_fields): Handle Host_Wide_Int and
15481 ByteSize flags.
15482 (var_type, var_type_struct): Same.
15483 (var_set): Handle ByteSize flag.
15484 * optc-gen.awk: Add comments to output to ease debugging. Make
15485 use of HOST_WIDE_INT where appropriate.
15486 * opts-gen-save.awk: Use %lx to format unsigned long.
15487 * opth-gen.awk: Change function argument to HOST_WIDE_INT.
15488 * opts-common.c (integral_argument): Return HOST_WIDE_INT and add
15489 arguments. Parse bytes-size suffixes.
15490 (enum_arg_to_value): Change function argument to HOST_WIDE_INT.
15491 (enum_value_to_arg): Same.
15492 (decode_cmdline_option): Handle cl_host_wide_int. Adjust.
15493 (handle_option): Adjust.
15494 (generate_option): Change function argument to HOST_WIDE_INT.
15495 (cmdline_handle_error): Adjust.
15496 (read_cmdline_option): Change function argument to HOST_WIDE_INT.
15497 (set_option): Change function argument to HOST_WIDE_INT.
15498 (option_enabled): Handle cl_host_wide_int.
15499 (get_option_state): Handle CLVC_SIZE.
15500 (control_warning_option): Same.
15501 * opts.c (common_handle_option): Change function argument to
15502 HOST_WIDE_INT. Remove handling of OPT_Walloca_larger_than_ and
15503 OPT_Wvla_larger_than_.
15504 * opts.h (enum cl_var_type): Add an enumerator.
15505 * stor-layout.c (layout_decl): Print a more meaningful warning.
15506 * toplev.c (output_stack_usage): Adjust.
15507
15508 2018-07-20 Qing Zhao <qing.zhao@oracle.com>
15509
15510 * builtins.c (expand_builtin_memcmp): Delete the last parameter for
15511 call to inline_expand_builtin_string_cmp.
15512 (expand_builtin_strcmp): Likewise.
15513 (expand_builtin_strncmp): Likewise.
15514 (inline_string_cmp): Delete the last parameter, change char_type_node
15515 to unsigned_char_type_node for strcmp/strncmp, add conversions to the
15516 two operands.
15517 (inline_expand_builtin_string_cmp): Delete the last parameter, give up
15518 the inlining expansion on target where the type of the call has same or
15519 narrower precision than unsigned char.
15520
15521 2018-07-20 David Malcolm <dmalcolm@redhat.com>
15522
15523 * Makefile.in (OBJS): Add json.o and optinfo-emit-json.o.
15524 (CFLAGS-optinfo-emit-json.o): Define TARGET_NAME.
15525 * common.opt (fsave-optimization-record): New option.
15526 * coretypes.h (struct kv_pair): Move here from dumpfile.c.
15527 * doc/invoke.texi (-fsave-optimization-record): New option.
15528 * dumpfile.c: Include "optinfo-emit-json.h".
15529 (struct kv_pair): Move to coretypes.h.
15530 (optgroup_options): Make non-static.
15531 (dump_context::end_scope): Call
15532 optimization_records_maybe_pop_dump_scope.
15533 * dumpfile.h (optgroup_options): New decl.
15534 * json.cc: New file.
15535 * json.h: New file.
15536 * optinfo-emit-json.cc: New file.
15537 * optinfo-emit-json.h: New file.
15538 * optinfo.cc: Include "optinfo-emit-json.h".
15539 (optinfo::emit): Call optimization_records_maybe_record_optinfo.
15540 (optinfo_enabled_p): Check optimization_records_enabled_p.
15541 (optinfo_wants_inlining_info_p): Likewise.
15542 * optinfo.h: Update comment.
15543 * profile-count.c (profile_quality_as_string): New function.
15544 * profile-count.h (profile_quality_as_string): New decl.
15545 (profile_count::quality): New accessor.
15546 * selftest-run-tests.c (selftest::run_tests): Call json_cc_tests
15547 and optinfo_emit_json_cc_tests.
15548 * selftest.h (selftest::json_cc_tests): New decl.
15549 (selftest::optinfo_emit_json_cc_tests): New decl.
15550 * toplev.c: Include "optinfo-emit-json.h".
15551 (compile_file): Call optimization_records_finish.
15552 (do_compile): Call optimization_records_start.
15553 * tree-ssa-live.c: Include optinfo.h.
15554 (remove_unused_scope_block_p): Retain inlining information if
15555 optinfo_wants_inlining_info_p returns true.
15556
15557 2018-07-20 Richard Biener <rguenther@suse.de>
15558
15559 PR debug/86585
15560 * dwarf2out.c (dwarf2out_die_ref_for_decl): Test in_lto_p
15561 to cover -flto-partition=none.
15562
15563 2018-07-20 Martin Liska <mliska@suse.cz>
15564
15565 * tree.h (DECL_LOCATION_RANGE): Remove unused macro.
15566 (get_decl_source_range): Remove unused function.
15567
15568 2018-07-20 Richard Biener <rguenther@suse.de>
15569
15570 * tree-ssa-sccvn.h (struct vn_nary_op_s): Add next member.
15571 (struct vn_phi_s): Likewise.
15572 (struct vn_reference_s): Likewise.
15573 * tree-ssa-sccvn.c (vn_nary_op_hasher::equal): Add shortcut
15574 for searching the slot of an entry known to be in the hash itself.
15575 (vn_phi_hasher::equal): Likewise.
15576 (vn_reference_hasher::equal): Likewise.
15577 (last_inserted_ref, last_inserted_phi, last_inserted_nary): New
15578 globals.
15579 (optimistic_info, current_info): Remove, keeping only valid_info.
15580 (vn_reference_lookup_1): Remove fallback lookup.
15581 (vn_reference_lookup_2): Likewise.
15582 (vn_nary_op_lookup_1): Likewise.
15583 (vn_phi_lookup): Likewise.
15584 (vn_nary_build_or_lookup_1): Make sure to not chain the built
15585 hash element.
15586 (vn_reference_insert): Adjust, chain the inserted hash element
15587 at last_inserted_ref.
15588 (vn_reference_insert_pieces): Likewise.
15589 (visit_reference_op_call): Likewise.
15590 (vn_nary_op_insert_into): Chain the inserted hash element at
15591 last_inserted_nary.
15592 (vn_nary_op_insert_pieces): Adjust.
15593 (vn_nary_op_insert): Likewise.
15594 (vn_nary_op_insert_stmt): Likewise.
15595 (vn_phi_insert): Adjust, chain the inserted hash element at
15596 last_inserted_phi.
15597 (process_scc): Remove clearing and copying the optimistic
15598 table. Instead remove elements inserted during an optimistic
15599 iteration from the single table we maintain.
15600 (init_scc_vn): Adjust.
15601 (free_scc_vn): Likewise.
15602 (sccvn_dom_walker::record_cond): Likewise.
15603 (sccvn_dom_walker::after_dom_children): Likewise.
15604
15605 2018-07-19 Martin Sebor <msebor@redhat.com>
15606
15607 PR tree-optimization/84047
15608 PR tree-optimization/83776
15609 * tree-vrp.c (vrp_prop::check_mem_ref): New function.
15610 (check_array_bounds): Call it.
15611
15612 2018-07-19 Martin Sebor <msebor@redhat.com>
15613
15614 * align.h (align_flags): Use member initialization.
15615
15616 2018-07-19 David Malcolm <dmalcolm@redhat.com>
15617
15618 * Makefile.in (OBJS): Add optinfo.o.
15619 * coretypes.h (class symtab_node): New forward decl.
15620 (struct cgraph_node): New forward decl.
15621 (class varpool_node): New forward decl.
15622 * dump-context.h: New file.
15623 * dumpfile.c: Include "optinfo.h", "dump-context.h", "cgraph.h",
15624 "tree-pass.h".
15625 (refresh_dumps_are_enabled): Use optinfo_enabled_p.
15626 (set_dump_file): Call dumpfile_ensure_any_optinfo_are_flushed.
15627 (set_alt_dump_file): Likewise.
15628 (dump_context::~dump_context): New dtor.
15629 (dump_gimple_stmt): Move implementation to...
15630 (dump_context::dump_gimple_stmt): ...this new member function.
15631 Add the stmt to any pending optinfo, creating one if need be.
15632 (dump_gimple_stmt_loc): Move implementation to...
15633 (dump_context::dump_gimple_stmt_loc): ...this new member function.
15634 Start a new optinfo and add the stmt to it.
15635 (dump_gimple_expr): Move implementation to...
15636 (dump_context::dump_gimple_expr): ...this new member function.
15637 Add the stmt to any pending optinfo, creating one if need be.
15638 (dump_gimple_expr_loc): Move implementation to...
15639 (dump_context::dump_gimple_expr_loc): ...this new member function.
15640 Start a new optinfo and add the stmt to it.
15641 (dump_generic_expr): Move implementation to...
15642 (dump_context::dump_generic_expr): ...this new member function.
15643 Add the tree to any pending optinfo, creating one if need be.
15644 (dump_generic_expr_loc): Move implementation to...
15645 (dump_context::dump_generic_expr_loc): ...this new member
15646 function. Add the tree to any pending optinfo, creating one if
15647 need be.
15648 (dump_printf): Move implementation to...
15649 (dump_context::dump_printf_va): ...this new member function. Add
15650 the text to any pending optinfo, creating one if need be.
15651 (dump_printf_loc): Move implementation to...
15652 (dump_context::dump_printf_loc_va): ...this new member function.
15653 Start a new optinfo and add the stmt to it.
15654 (dump_dec): Move implementation to...
15655 (dump_context::dump_dec): ...this new member function. Add the
15656 value to any pending optinfo, creating one if need be.
15657 (dump_context::dump_symtab_node): New member function.
15658 (dump_context::get_scope_depth): New member function.
15659 (dump_context::begin_scope): New member function.
15660 (dump_context::end_scope): New member function.
15661 (dump_context::ensure_pending_optinfo): New member function.
15662 (dump_context::begin_next_optinfo): New member function.
15663 (dump_context::end_any_optinfo): New member function.
15664 (dump_context::s_current): New global.
15665 (dump_context::s_default): New global.
15666 (dump_scope_depth): Delete global.
15667 (dumpfile_ensure_any_optinfo_are_flushed): New function.
15668 (dump_symtab_node): New function.
15669 (get_dump_scope_depth): Reimplement in terms of dump_context.
15670 (dump_begin_scope): Likewise.
15671 (dump_end_scope): Likewise.
15672 (selftest::temp_dump_context::temp_dump_context): New ctor.
15673 (selftest::temp_dump_context::~temp_dump_context): New dtor.
15674 (selftest::verify_item): New function.
15675 (ASSERT_IS_TEXT): New macro.
15676 (ASSERT_IS_TREE): New macro.
15677 (ASSERT_IS_GIMPLE): New macro.
15678 (selftest::test_capture_of_dump_calls): New test.
15679 (selftest::dumpfile_c_tests): Call it.
15680 * dumpfile.h (dump_printf, dump_printf_loc, dump_basic_block)
15681 (dump_generic_expr_loc, dump_generic_expr, dump_gimple_stmt_loc)
15682 (dump_gimple_stmt, dump_dec): Gather these related decls and add a
15683 descriptive comment.
15684 (dump_function, print_combine_total_stats, enable_rtl_dump_file)
15685 (dump_node, dump_bb): Move these unrelated decls.
15686 (class dump_manager): Add leading comment.
15687 * optinfo.cc: New file.
15688 * optinfo.h: New file.
15689
15690 2018-07-19 Michael Collison <michael.collison@arm.com>
15691 Richard Henderson <rth@redhat.com>
15692
15693 * config/aarch64/aarch64.md (subv<GPI>4, usubv<GPI>4): New patterns.
15694 (subti): Handle op1 zero.
15695 (subvti4, usub4ti4): New.
15696 (*sub<GPI>3_compare1_imm): New.
15697 (sub<GPI>3_carryinCV): New.
15698 (*sub<GPI>3_carryinCV_z1_z2, *sub<GPI>3_carryinCV_z1): New.
15699 (*sub<GPI>3_carryinCV_z2, *sub<GPI>3_carryinCV): New.
15700
15701 2018-07-19 Michael Collison <michael.collison@arm.com>
15702 Richard Henderson <rth@redhat.com>
15703
15704 * config/aarch64/aarch64.md: (addv<GPI>4, uaddv<GPI>4): New.
15705 (addti3): Create simpler code if low part is already known to be 0.
15706 (addvti4, uaddvti4): New.
15707 (*add<GPI>3_compareC_cconly_imm): New.
15708 (*add<GPI>3_compareC_cconly): New.
15709 (*add<GPI>3_compareC_imm): New.
15710 (*add<GPI>3_compareC): Rename from add<GPI>3_compare1; do not
15711 handle constants within this pattern..
15712 (*add<GPI>3_compareV_cconly_imm): New.
15713 (*add<GPI>3_compareV_cconly): New.
15714 (*add<GPI>3_compareV_imm): New.
15715 (add<GPI>3_compareV): New.
15716 (add<GPI>3_carryinC, add<GPI>3_carryinV): New.
15717 (*add<GPI>3_carryinC_zero, *add<GPI>3_carryinV_zero): New.
15718 (*add<GPI>3_carryinC, *add<GPI>3_carryinV): New.
15719 ((*add<GPI>3_compareC_cconly_imm): Replace 'ne' operator
15720 with 'comparison' operator.
15721 (*add<GPI>3_compareV_cconly_imm): Ditto.
15722 (*add<GPI>3_compareV_cconly): Ditto.
15723 (*add<GPI>3_compareV_imm): Ditto.
15724 (add<GPI>3_compareV): Ditto.
15725 (add<mode>3_carryinC): Ditto.
15726 (*add<mode>3_carryinC_zero): Ditto.
15727 (*add<mode>3_carryinC): Ditto.
15728 (add<mode>3_carryinV): Ditto.
15729 (*add<mode>3_carryinV_zero): Ditto.
15730 (*add<mode>3_carryinV): Ditto.
15731
15732 2018-07-19 Michael Collison <michael.collison@arm.com>
15733 Richard Henderson <rth@redhat.com>
15734
15735 * config/aarch64/aarch64-modes.def (CC_V): New.
15736 * config/aarch64/aarch64-protos.h
15737 (aarch64_addti_scratch_regs): Declare
15738 (aarch64_subvti_scratch_regs): Declare.
15739 (aarch64_expand_subvti): Declare.
15740 (aarch64_gen_unlikely_cbranch): Declare
15741 * config/aarch64/aarch64.c (aarch64_select_cc_mode): Test
15742 for signed overflow using CC_Vmode.
15743 (aarch64_get_condition_code_1): Handle CC_Vmode.
15744 (aarch64_gen_unlikely_cbranch): New function.
15745 (aarch64_addti_scratch_regs): New function.
15746 (aarch64_subvti_scratch_regs): New function.
15747 (aarch64_expand_subvti): New function.
15748
15749 2018-07-19 Andre Vieira <andre.simoesdiasvieira@arm.com>
15750
15751 * config/aarch64/aarch64-option-extensions.def: New entry for profile
15752 extension.
15753 * config/aarch64/aarch64.h (AARCH64_FL_PROFILE): New.
15754 * doc/invoke.texi (aarch64-feature-modifiers): New entry for profile
15755 extension.
15756
15757 2018-07-19 Andre Vieira <andre.simoesdiasvieira@arm.com>
15758
15759 PR target/83009
15760 * config/aarch64/predicates.md (aarch64_mem_pair_lanes_operand): Make
15761 address check not strict.
15762
15763 2018-07-19 Andre Vieira <andre.simoesdiasvieira@arm.com>
15764
15765 * config/aarch64/aarch64-simd.md (aarch64_simd_mov<VQ:mode>): Replace
15766 Umq with Umn.
15767 (store_pair_lanes<mode>): Likewise.
15768 * config/aarch64/aarch64-protos.h (aarch64_addr_query_type): Add new
15769 enum value 'ADDR_QUERY_LDP_STP_N'.
15770 * config/aarch64/aarch64.c (aarch64_addr_query_type): Likewise.
15771 (aarch64_print_address_internal): Add declaration.
15772 (aarch64_print_ldpstp_address): Remove.
15773 (aarch64_classify_address): Adapt mode for 'ADDR_QUERY_LDP_STP_N'.
15774 (aarch64_print_operand): Change printing of 'y'.
15775 * config/aarch64/predicates.md (aarch64_mem_pair_lanes_operand): Use
15776 new enum value 'ADDR_QUERY_LDP_STP_N', don't hardcode mode and use
15777 'true' rather than '1'.
15778 * config/aarch64/constraints.md (Uml): Likewise.
15779 (Uml): Rename to Umn.
15780 (Umq): Remove.
15781
15782 2018-07-19 Richard Biener <rguenther@suse.de>
15783
15784 * tree-ssa-sccvn.h (struct vn_phi_s): Make phiargs member
15785 a trailing array.
15786 * tree-ssa-sccvn.c: Remove alloc-pool.h use.
15787 (vn_phi_hasher): Derive from nofree_ptr_hash and remove remove method.
15788 (vn_reference_hasher): Likewise.
15789 (struct vn_tables_s): Remove obstack and alloc-pool members.
15790 (vn_tables_obstack, vn_tables_insert_obstack): New global obstacks.
15791 (vn_nary_build_or_lookup_1): Manually build in vn_tables_insert_obstack.
15792 (vn_reference_insert): Allocate from obstack instead of from alloc-pool.
15793 (vn_reference_insert_pieces): Likewise.
15794 (alloc_vn_nary_op_noinit): Adjust.
15795 (vn_nary_op_insert_stmt): Allocate phiargs in-place.
15796 (vn_phi_eq): Adjust.
15797 (shared_lookup_phiargs): Remove.
15798 (vn_phi_lookup): Allocate temporary vn_phi_s on the stack.
15799 (vn_phi_insert): Allocate from obstack instead of from alloc-pool.
15800 (visit_reference_op_call): Likewise.
15801 (copy_nary, copy_phi, copy_reference): Remove.
15802 (process_scc): Rewind the obstack when iterating. Do not
15803 copy the elements to valid_info but just move them from one
15804 hashtable to the other.
15805 (allocate_vn_table): Adjust.
15806 (free_vn_table): Likewise.
15807 (init_scc_vn): Likewise.
15808 (free_scc_vn): Likewise.
15809
15810 2018-07-19 H.J. Lu <hongjiu.lu@intel.com>
15811
15812 PR target/86560
15813 * config/i386/i386.c (rest_of_insert_endbranch): Lookup
15814 indirect_return as function type attribute.
15815 (ix86_attribute_table): Change indirect_return to function
15816 type attribute.
15817 * doc/extend.texi: Update indirect_return attribute.
15818
15819 2018-07-19 Aldy Hernandez <aldyh@redhat.com>
15820
15821 * wide-int.h (widest2_int): New.
15822 * gimple-fold.c (arith_overflowed_p): Use it.
15823 * tree.h (widest2_int_cst): New.
15824 * tree-vrp.c (wide_int_binop_overflow): Rename from
15825 vrp_int_const_binop.
15826 Rewrite to work on trees.
15827 (extract_range_from_multiplicative_op_1): Abstract code to...
15828 (wide_int_range_min_max): ...here.
15829 (wide_int_range_cross_product): ...and here.
15830 (extract_range_from_binary_expr_1): Abstract overflow code to...
15831 (wide_int_range_mult_wrapping): ...here.
15832 * tree-vrp.h (wide_int_range_cross_product): New.
15833 (wide_int_range_mult_wrapping): New.
15834
15835 2018-07-19 Andrew Senkevich <andrew.senkevich@intel.com>
15836 Julia Koval <julia.koval@intel.com>
15837
15838 * config/i386/x86-tune-costs.h (skylake_memcpy,
15839 skylake_memset): Replace rep_prefix with unrolling for size 512.
15840
15841 2018-07-18 Kugan Vivekanandarajah <kuganv@linaro.org>
15842
15843 PR middle-end/86544
15844 * tree-ssa-phiopt.c (cond_removal_in_popcount_pattern): Handle
15845 comparision with EQ_EXPR in last stmt.
15846
15847 2018-07-18 Kelvin Nilsen <kelvin@gcc.gnu.org>
15848
15849 * doc/extend.texi (PowerPC AltiVec Built-in Functions): Rename
15850 this subsection to "PowerPC AltiVec/VSX Built-in Functions".
15851 (PowerPC AltiVec/VSX Built-in Functions): New name for subsection
15852 previously known as "PowerPC AltiVec Built-in Functions". Move
15853 some material to new subsubsections "PowerPC AltiVec Built-in
15854 Functions on ISA 2.06" and "PowerPC AltiVec Built-in Functions on
15855 ISA 2.07".
15856 (PowerPC Altivec Built-in Functions on ISA 2.05): New subsubsection.
15857 (PowerPC Altivec Built-in Functions on ISA 2.06): Likewise.
15858 (PowerPC Altivec Built-in Functions on ISA 2.07): Likewise.
15859 (PowerPC Altivec Built-in Functions on ISA 3.0): Likewise.
15860
15861 2018-07-18 Richard Biener <rguenther@suse.de>
15862
15863 PR tree-optimization/86557
15864 * tree-vect-patterns.c (vect_recog_divmod_pattern): Also handle
15865 EXACT_DIV_EXPR.
15866
15867 2018-07-18 Ilya Leoshkevich <iii@linux.ibm.com>
15868
15869 * config/s390/s390.c (s390_function_profiler): Generate CFI.
15870
15871 2018-07-17 Jeff Law <law@redhat.com>
15872
15873 * config/arm/arm.c (get_label_padding): Update for recent
15874 changes to label_to_alignment.
15875
15876 PR tree-optimization/86010
15877 * tree-ssa-dse.c (compute_trims): Fix typo/thinko.
15878
15879 * config/mips/mips.c (vr4130_align_insns): Update for recent
15880 changes to label_to_alignment.
15881
15882 * config/frv/frv.c (frv_label_align): Update for recent changes
15883 to label_to_alignment.
15884
15885 * config/nios2/nios2.c (nios2_label_align): Update for recent
15886 changes which dropped ALIGN_LABELS_LOG.
15887
15888 2018-07-17 Andreas Schwab <schwab@linux-m68k.org>
15889
15890 * config/m68k/m68k.md (umulsi3_highpart+1, const_umulsi3_highpart)
15891 (smulsi3_highpart+1, const_smulsi3_highpart): Add CC_STATUS_INIT.
15892
15893 2018-07-17 Claudiu Zissulescu <claziss@synopsys.com>
15894
15895 * config/arc/arc.c (arc_label_align): Use align_labels instead of
15896 deprecated align_labels_log.
15897
15898 2018-07-17 Richard Biener <rguenther@suse.de>
15899
15900 PR lto/86456
15901 * dwarf2out.c (init_sections_and_labels): Always generate
15902 a debug_line_str_section for early LTO debug.
15903 (dwarf2out_finish): Reset debug_line_str_hash output early.
15904 Bump counter for extra dwarf5 .debug_loc labels to not conflict
15905 with fat LTO part.
15906 (dwarf2out_early_finish): Output debug_line_str.
15907
15908 2018-07-17 Robin Dapp <rdapp@linux.ibm.com>
15909
15910 * config/s390/s390.c (preferred_la_operand_p): Do not use LA with
15911 index register on z196 or later.
15912
15913 2018-07-17 Robin Dapp <rdapp@linux.ibm.com>
15914
15915 * config/s390/s390.c (s390_default_align): Set default function
15916 alignment to 16.
15917 (s390_override_options_after_change): Call s390_default align.
15918 (s390_option_override_internal): Call s390_default_align.
15919 (TARGET_OVERRIDE_OPTIONS_AFTER_CHANGE): Define.
15920
15921 2018-07-17 Jakub Jelinek <jakub@redhat.com>
15922
15923 PR middle-end/86542
15924 * omp-low.c (create_task_copyfn): Copy over also fields corresponding
15925 to _looptemp_ clauses, other than the first two.
15926
15927 2018-07-17 Martin Liska <mliska@suse.cz>
15928
15929 * opts.c: Do not enable OPT_falign_* for -Os.
15930
15931 2018-07-17 Martin Liska <mliska@suse.cz>
15932
15933 * align.h (MAX_CODE_ALIGN): New.
15934 (MAX_CODE_ALIGN_VALUE): New.
15935 * common/config/i386/i386-common.c (ix86_handle_option):
15936 (MAX_CODE_ALIGN): Moved to align.h.
15937 * final.c (MAX_CODE_ALIGN): Likewise.
15938 * opts.c (parse_and_check_align_values):
15939 (MAX_CODE_ALIGN): Likewise.
15940 (MAX_CODE_ALIGN_VALUE): Likewise.
15941
15942 2018-07-17 Martin Liska <mliska@suse.cz>
15943
15944 * config/i386/att.h (ASM_OUTPUT_ALIGN): Fix spacing
15945 in order to fulfil coding style.
15946 * config/i386/cygming.h (ASM_OUTPUT_ALIGN): Likewise.
15947 * config/i386/gas.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
15948 * config/i386/x86-64.h (ASM_OUTPUT_MAX_SKIP_PAD): Likewise.
15949 * config/iq2000/iq2000.h (ASM_OUTPUT_ALIGN): Likewise.
15950 * config/pa/pa.h (ASM_OUTPUT_ALIGN): Likewise.
15951 * config/sparc/sol2.h (ASM_OUTPUT_ALIGN_WITH_NOP): Likewise.
15952 * config/sparc/sparc.h (ASM_OUTPUT_ALIGN): Likewise.
15953 * config/visium/visium.h (ASM_OUTPUT_ALIGN): Likewise.
15954 (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
15955
15956 2018-07-17 Martin Liska <mliska@suse.cz>
15957
15958 * align.h: New file.
15959 * config/alpha/alpha.c (alpha_align_insns_1): Use align_functions
15960 directly.
15961 * config/i386/i386.c (ix86_avoid_jump_mispredicts): Use new return type
15962 align_flags of label_to_alignment.
15963 * config/m32r/m32r.h (LOOP_ALIGN): Wrap returned values into
15964 align_flags class.
15965 * config/m68k/m68k.c: Do not use removed align_labels_value and
15966 align_loops_value.
15967 * config/nds32/nds32.h (JUMP_ALIGN): Wrap result into align_flags class.
15968 (LOOP_ALIGN): Likewise.
15969 (LABEL_ALIGN): Likewise.
15970 * config/powerpcspe/powerpcspe.c (TARGET_ASM_LOOP_ALIGN_MAX_SKIP):
15971 Remove not used macro.
15972 (rs6000_loop_align): Change return type to align_flags.
15973 (rs6000_loop_align_max_skip): Remove.
15974 * config/rs6000/rs6000-protos.h (rs6000_loop_align):
15975 Change return type to align_flags.
15976 * config/rs6000/rs6000.c (TARGET_ASM_LOOP_ALIGN_MAX_SKIP):
15977 Remove not used macro.
15978 (rs6000_loop_align): Change return type to align_flags.
15979 (rs6000_loop_align_max_skip): Remove.
15980 * config/rx/rx.h (JUMP_ALIGN): Wrap integer values
15981 * config/rx/rx-protos.h (rx_align_for_label): Make it
15982 static function.
15983 * config/rx/rx.c (rx_align_for_label): Change return type
15984 to align_flags.
15985 (rx_max_skip_for_label): Remove TARGET_ASM_*_ALIGN_MAX_SKIP
15986 macro definitions.
15987 into align_flags class.
15988 (LABEL_ALIGN): Likewise.
15989 (LOOP_ALIGN): Likewise.
15990 * config/s390/s390.c (s390_label_align): Use align_flags
15991 class member.
15992 (s390_asm_output_function_label): Likewise.
15993 * config/sh/sh.c (sh_override_options_after_change):
15994 Use align_flags class directly without macros.
15995 (find_barrier): Likewise.
15996 (barrier_align): Likewise.
15997 (sh_loop_align): Likewise.
15998 * config/spu/spu.c (spu_option_override):
15999 Use align_flags_tuple::get_value instead of removed macros.
16000 (spu_sched_init): Likewise.
16001 * config/spu/spu.h (GTY): Likewise.
16002 * config/visium/visium.c (visium_option_override):
16003 Set "8" as default secondary alignment.
16004 * config/visium/visium.h (SUBALIGN_LOG): Define to 3
16005 in order to guarantee secondary alignment of 8.
16006 * coretypes.h: Include align.h header file.
16007 * doc/tm.texi: Remove TARGET_ASM_JUMP_ALIGN_MAX_SKIP,
16008 TARGET_ASM_LOOP_ALIGN_MAX_SKIP, TARGET_ASM_LABEL_ALIGN_MAX_SKIP
16009 and TARGET_ASM_LABEL_ALIGN_AFTER_BARRIER_MAX_SKIP macros.
16010 * doc/tm.texi.in: Likewise.
16011 * final.c (struct label_alignment): Remove not used structure.
16012 (LABEL_ALIGN): Change type to align_flags.
16013 (LOOP_ALIGN): Likewise.
16014 (JUMP_ALIGN): Likewise.
16015 (default_loop_align_max_skip): Remove.
16016 (default_label_align_max_skip): Likewise.
16017 (default_jump_align_max_skip): Likewise.
16018 (default_label_align_after_barrier_max_skip):
16019 (LABEL_TO_ALIGNMENT): Change to access label_align vector.
16020 (LABEL_TO_MAX_SKIP): Remove.
16021 (label_to_alignment): Return align_flags type instead of integer.
16022 (label_to_max_skip): Remove.
16023 (align_fuzz): Use align_flags type.
16024 (compute_alignments): Use align_flags type and use align_flags::max
16025 to combine multiple alignments.
16026 (grow_label_align): Grow vec instead of C array.
16027 (update_alignments): Assign just LABEL_TO_ALIGNMENT.
16028 (shorten_branches): Use align_flags type and use align_flags::max
16029 to combine multiple alignments.
16030 (final_scan_insn_1): Remove usage of secondary alignment that comes
16031 from label alignment, but instead use proper secondary alignment
16032 which is computed in grow_label_align.
16033 * flags.h (struct align_flags_tuple): Move to align.h.
16034 (struct align_flags): Likewise.
16035 (state_align_loops): Rename to align_loops.
16036 (state_align_jumps): Rename to align_jumps.
16037 (state_align_labels): Rename to align_labels.
16038 (state_align_functions): Rename to align_functions.
16039 (align_loops_log): Remove.
16040 (align_jumps_log): Remove.
16041 (align_labels_log): Remove.
16042 (align_functions_log): Remove.
16043 (align_loops_max_skip): Remove.
16044 (align_jumps_max_skip): Remove.
16045 (align_labels_max_skip): Remove.
16046 (align_functions_max_skip): Remove.
16047 (align_loops_value): Remove.
16048 (align_jumps_value): Remove.
16049 (align_labels_value): Remove.
16050 (align_functions_value): Remove.
16051 * output.h (label_to_alignment): Change return type to align_flags.
16052 (label_to_max_skip): Remove.
16053 * target.def: Remove loop_align_max_skip, label_align_max_skip,
16054 jump_align_max_skip macros.
16055 * targhooks.h (default_loop_align_max_skip): Remove.
16056 (default_label_align_max_skip): Likewise.
16057 (default_jump_align_max_skip): Likewise.
16058 (default_label_align_after_barrier_max_skip): Remove.
16059 * toplev.c (read_log_maxskip): Use ::normalize function.
16060 (parse_N_M): Remove not used argument and also call ::normalize.
16061 (parse_alignment_opts): Do not pass unused arguments.
16062 * varasm.c (assemble_start_function): Use directly align_functions
16063 instead of removed macros.
16064 * system.h: Do not poison removed macros.
16065
16066 2018-07-17 Jakub Jelinek <jakub@redhat.com>
16067
16068 PR middle-end/86539
16069 * gimplify.c (gimplify_omp_for): Ensure taskloop firstprivatized init
16070 and cond temporaries don't have reference type if iterator has
16071 pointer type. For init use &for_pre_body instead of pre_p if
16072 for_pre_body is non-empty.
16073
16074 2018-07-16 Segher Boessenkool <segher@kernel.crashing.org>
16075
16076 * config/rs6000/rs6000.md (trunc<mode>sf2): Expand truncates of
16077 double-double modes to SFmode directly directly.
16078 (trunc<mode>sf2_fprs): Delete.
16079
16080 2018-07-16 Segher Boessenkool <segher@kernel.crashing.org>
16081
16082 * config/rs6000/rs6000.c (init_float128_ibm): Use the correct names
16083 for conversions between IFmode and the decimal floating point modes.
16084 (init_float128_ieee): Use the correct names for conversions between
16085 KFmode and the decimal floating point modes.
16086
16087 2018-07-16 Segher Boessenkool <segher@kernel.crashing.org>
16088
16089 * config/rs6000/rs6000.c (init_float128_ibm): Use more correct names
16090 for the conversions between TDmode and IFmode.
16091 (init_float128_ieee): Use more correct names for the conversions
16092 between TDmode and KFmode.
16093
16094 2018-07-16 Jakub Jelinek <jakub@redhat.com>
16095
16096 PR tree-optimization/86526
16097 * builtins.c (expand_builtin_memcmp): Formatting fixes.
16098 (inline_expand_builtin_string_cmp): Likewise.
16099 (inline_string_cmp): Likewise. Use c_readstr instead of
16100 builtin_memcpy_read_str. Add unit_mode temporary.
16101
16102 2018-07-16 Bernd Edlinger <bernd.edlinger@hotmail.de>
16103
16104 PR middle-end/86528
16105 * builtins.c (check_access): Bail out if range[0] is no INTEGER_CST.
16106 * expr.c (string_constant): Fix the element size of ARRAY_TYPE.
16107
16108 2018-07-16 Kelvin Nilsen <kelvin@gcc.gnu.org>
16109
16110 * doc/extend.texi (PowerPC AltiVec Built-in Functions):
16111 Alphabetize prototypes of built-in functions, separating out
16112 built-in functions that are listed in this section but should be
16113 described elsewhere.
16114
16115 2018-07-16 Uros Bizjak <ubizjak@gmail.com>
16116
16117 PR target/86511
16118 * expmed.c (emit_store_flag): Do not emit setcc followed by a
16119 conditional move when trapping comparison was split to a
16120 non-trapping one (and vice versa).
16121
16122 2018-07-16 Ilya Leoshkevich <iii@linux.ibm.com>
16123
16124 * config/s390/s390.c (s390_function_profiler): Generate nops
16125 instead of profiler call sequences.
16126 * config/s390/s390.opt: Add the new option.
16127
16128 2018-07-16 Ilya Leoshkevich <iii@linux.ibm.com>
16129
16130 * config/s390/s390.c (s390_function_profiler): Generate
16131 __mcount_loc section.
16132 * config/s390/s390.opt: Add the new option.
16133
16134 2018-07-16 Ilya Leoshkevich <iii@linux.ibm.com>
16135
16136 * common.opt: Add the new warning.
16137 * config/s390/s390.c (s390_function_profiler): Emit "brasl
16138 %r0,__fentry__" when -mfentry is specified.
16139 (s390_option_override_internal): Disallow -mfentry for 31-bit
16140 CPUs.
16141 * config/s390/s390.opt: Add the new option.
16142
16143 2018-07-16 Richard Biener <rguenther@suse.de>
16144
16145 PR lto/86523
16146 * dwarf2out.c (dwarf2out_register_external_die): Assign DIE parents
16147 for function-local FUNCTION_DECL and RESULT_DECL immediately.
16148
16149 2018-07-16 Martin Liska <mliska@suse.cz>
16150
16151 PR ipa/86529
16152 * ipa-pure-const.c (malloc_candidate_p): Revert ::get
16153 to ::get_create.
16154
16155 2017-07-16 Claudiu Zissulescu <claziss@synopsys.com>
16156
16157 * config/arc/arcHS.md: Update ARCHS scheduling rules.
16158
16159 2017-07-16 Claudiu Zissulescu <claziss@synopsys.com>
16160
16161 * config/arc/arc-arch.h (arc_tune_attr): Add new tune parameters
16162 for ARCHS4x.
16163 * config/arc/arc-cpus.def (hs4x): New cpu.
16164 (hs4xd): Likewise.
16165 * config/arc/arc-tables.opt: Regenerate.
16166 * config/arc/arc.c (arc_sched_issue_rate): New function.
16167 (TARGET_SCHED_ISSUE_RATE): Define.
16168 (TARGET_SCHED_EXPOSED_PIPELINE): Likewise.
16169 * config/arc/arc.md (attr type): Add fpu_fuse, fpu_sdiv, fpu_ddiv,
16170 fpu_cvt.
16171 (attr tune): Add ARCHS4x tune values.
16172 (attr tune_dspmpy): Define.
16173 (*tst): Correct instruction type.
16174 * config/arc/arcHS.md: Don't use this automaton for ARCHS4x cpus.
16175 * config/arc/arcHS4x.md: New file.
16176 * config/arc/fpu.md: Update instruction type attributes.
16177 * config/arc/t-multilib: Regenerate.
16178
16179 2018-07-16 Tom de Vries <tdevries@suse.de>
16180
16181 PR debug/86455
16182 * var-tracking.c (vt_initialize): Fix pre_dec handling.
16183
16184 2018-07-16 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
16185
16186 * config/aarch64/atomics.md (aarch64_store_execlusive<mode>): Add
16187 early clobber.
16188
16189 2018-07-16 Eric Botcazou <ebotcazou@adacore.com>
16190
16191 PR tree-optimization/86514
16192 * tree-ssa-reassoc.c (init_range_entry) <CASE_CONVERT>: Return for a
16193 conversion to a boolean type from a type with greater precision.
16194
16195 2018-07-16 Tom de Vries <tdevries@suse.de>
16196
16197 * var-tracking.c (vt_initialize): Print adjusted insn slim if
16198 dump_flags request TDF_SLIM.
16199
16200 2018-07-16 Aldy Hernandez <aldyh@redhat.com>
16201
16202 * fold-const.c (int_const_binop_1): Abstract...
16203 (wide_int_binop): ...wide int code here.
16204 (poly_int_binop): ...poly int code here.
16205 Abstract the rest of int_const_binop_1 into int_const_binop.
16206 * fold-const.h (wide_int_binop): New.
16207 * tree-vrp.c (vrp_int_const_binop): Call wide_int_binop.
16208 Remove useless PLUS/MINUS_EXPR case.
16209 (zero_nonzero_bits_from_vr): Move wide int code...
16210 (zero_nonzero_bits_from_bounds): ...here.
16211 (extract_range_from_binary_expr_1): Move mask optimization code...
16212 (range_easy_mask_min_max): ...here.
16213 * tree-vrp.h (zero_nonzero_bits_from_bounds): New.
16214 (range_easy_mask_min_max): New.
16215
16216 2018-07-15 Jeff Law <law@redhat.com>
16217
16218 PR target/85993
16219 * config/sh/sh.c (output_mi_thunk): Remove dead conditional
16220 block.
16221
16222 2018-07-14 Jim Wilson <jimw@sifive.com>
16223
16224 * config/riscv/linux.h (TARGET_ASM_FILE_END): New.
16225
16226 2018-07-14 Paul Koning <ni1d@arrl.net>
16227
16228 * config/pdp11/pdp11.c (pdp11_rtx_costs): Bugfixes.
16229
16230 2018-07-13 Jan Hubicka <hubicka@ucw.cz>
16231
16232 * lto-streamer-out.c (copy_function_or_variable): Dump info about
16233 copying section.
16234
16235 2018-07-13 Bill Schmidt <wschmidt@linux.ibm.com>
16236 Steve Munroe <munroesj52@gmail.com>
16237
16238 * config/rs6000/emmintrin.h (_mm_and_si128): New function.
16239 (_mm_andnot_si128): Likewise.
16240 (_mm_or_si128): Likewise.
16241 (_mm_xor_si128): Likewise.
16242
16243 2018-07-13 Qing Zhao <qing.zhao@oracle.com>
16244
16245 PR middle-end/78809
16246 * builtins.c (expand_builtin_memcmp): Inline the calls first
16247 when result_eq is false.
16248 (expand_builtin_strcmp): Inline the calls first.
16249 (expand_builtin_strncmp): Likewise.
16250 (inline_string_cmp): New routine. Expand a string compare
16251 call by using a sequence of char comparison.
16252 (inline_expand_builtin_string_cmp): New routine. Inline expansion
16253 a call to str(n)cmp/memcmp.
16254 * doc/invoke.texi (--param builtin-string-cmp-inline-length):
16255 New option.
16256 * params.def (BUILTIN_STRING_CMP_INLINE_LENGTH): New.
16257
16258 2018-07-13 Richard Earnshaw <rearnsha@arm.com>
16259
16260 * config/arm/driver-arm.c: Include arm-native.h.
16261 (host_detect_local_cpu): Use auto-generated data tables.
16262 (vendors, arm_cpu_table): Delete. Move part information to ...
16263 * config/arm/arm-cpus.in: ... here.
16264 * config/arm/parsecpu.awk (gen_native): New function.
16265 (vendor, part): New CPU fields.
16266 (END): Add support for building the native CPU detection tables.
16267 * config/arm/t-arm (arm-native.h): Add build rule.
16268 (driver-arm.o): Add dependency on arm-native.h.
16269
16270 2018-07-13 Richard Biener <rguenther@suse.de>
16271
16272 PR middle-end/85974
16273 * match.pd (addr1 - addr2): Allow either of the operand to
16274 have a conversion.
16275
16276 2018-07-13 Tom de Vries <tdevries@suse.de>
16277
16278 * tree-inline.c (remap_ssa_name): Save and reuse debug exprs generated
16279 in remap_ssa_name.
16280
16281 2018-07-13 Jackson Woodruff <jackson.woodruff@arm.com>
16282
16283 * config/aarch64/aarch64.c (aarch64_operands_adjust_ok_for_ldpstp): Use
16284 arrays instead of numbered variables.
16285
16286 2018-07-13 Eric Botcazou <ebotcazou@adacore.com>
16287
16288 * config/sparc/sparc-protos.h (sparc_compute_frame_size): Delete.
16289 * config/sparc/sparc.c (sparc_compute_frame_size): Make static.
16290
16291 2018-07-13 Richard Biener <rguenther@suse.de>
16292
16293 PR debug/86452
16294 * dwarf2out.c (gen_type_die_with_usage): Use scope_die_for
16295 instead of get_context_die.
16296
16297 2018-07-13 Kugan Vivekanandarajah <kuganv@linaro.org>
16298 Richard Biener <rguenther@suse.de>
16299
16300 PR middle-end/86489
16301 * tree-ssa-loop-niter.c (number_of_iterations_popcount): Check
16302 that the loop latch destination where phi is defined.
16303
16304 2018-07-12 Kito Cheng <kito.cheng@gmail.com>
16305
16306 * config/riscv/riscv.c (enum riscv_privilege_levels): Add UNKNOWN_MODE.
16307 (riscv_expand_epilogue): Add assertion to check interrupt mode.
16308 (riscv_set_current_function): Extract getting interrupt type to new
16309 function.
16310 (riscv_get_interrupt_type): New function.
16311 (riscv_merge_decl_attributes): New function, checking interrupt type is
16312 same.
16313 (TARGET_MERGE_DECL_ATTRIBUTES): Define.
16314
16315 2018-07-12 Paul Koning <ni1d@arrl.net>
16316
16317 * config/pdp11/pdp11.c (pdp11_output_def): Fix typo in .set
16318 directive.
16319
16320 2018-07-12 Paul Koning <ni1d@arrl.net>
16321
16322 * doc/rtl.texi (REG_NONNEG): Remove decrement and branch until
16323 zero reference, add doloop_end instead.
16324 * doc/md.texi (decrement_and_branch_until_zero): Remove.
16325 (Looping patterns): Remove decrement_and_branch_until_zero. Add
16326 detail for doloop_end.
16327
16328 2018-07-12 Martin Sebor <msebor@redhat.com>
16329
16330 PR c/86453
16331 * attribs.c (decl_attributes): Reject conflicting attributes before
16332 calling attribute handlers.
16333
16334 2018-07-12 Jan Hubicka <hubicka@ucw.cz>
16335
16336 * dumpfile.c (gcc::dump_manager::get_dump_file_name): Add PART
16337 parameter.
16338 (gcc::dump_manager::get_dump_file_name): likewise.
16339 (dump_begin): Likewise.
16340 * dumpfile.h (dump_begin): Update prototype.
16341 (gcc::dump_manager::get_dump_file_name,
16342 gcc::dump_manager::get_dump_file_name): Update prototype.
16343
16344 2018-07-12 Richard Sandiford <richard.sandiford@linaro.org>
16345
16346 * internal-fn.h (vectorizable_internal_fn_p): New function.
16347 * tree-vect-slp.c (compatible_calls_p): Likewise.
16348 (vect_build_slp_tree_1): Remove nops argument. Handle calls
16349 to internal functions.
16350 (vect_build_slp_tree_2): Update call to vect_build_slp_tree_1.
16351
16352 2018-07-12 Richard Sandiford <richard.sandiford@linaro.org>
16353
16354 * fold-const.h (inverse_conditions_p): Declare.
16355 * fold-const.c (inverse_conditions_p): New function.
16356 * match.pd: Use inverse_conditions_p. Add folds of view_converts
16357 that test the inverse condition of a conditional internal function.
16358 * internal-fn.h (vectorized_internal_fn_supported_p): Declare.
16359 * internal-fn.c (internal_fn_mask_index): Handle conditional
16360 internal functions.
16361 (vectorized_internal_fn_supported_p): New function.
16362 * tree-if-conv.c: Include internal-fn.h and fold-const.h.
16363 (any_pred_load_store): Replace with...
16364 (need_to_predicate): ...this new variable.
16365 (redundant_ssa_names): New variable.
16366 (ifcvt_can_use_mask_load_store): Move initial checks to...
16367 (ifcvt_can_predicate): ...this new function. Handle tree codes
16368 for which a conditional internal function exists.
16369 (if_convertible_gimple_assign_stmt_p): Use ifcvt_can_predicate
16370 instead of ifcvt_can_use_mask_load_store. Update after variable
16371 name change.
16372 (predicate_load_or_store): New function, split out from
16373 predicate_mem_writes.
16374 (check_redundant_cond_expr): New function.
16375 (value_available_p): Likewise.
16376 (predicate_rhs_code): Likewise.
16377 (predicate_mem_writes): Rename to...
16378 (predicate_statements): ...this. Use predicate_load_or_store
16379 and predicate_rhs_code.
16380 (combine_blocks, tree_if_conversion): Update after above name changes.
16381 (ifcvt_local_dce): Handle redundant_ssa_names.
16382 * tree-vect-patterns.c (vect_recog_mask_conversion_pattern): Handle
16383 general conditional functions.
16384 * tree-vect-stmts.c (vectorizable_call): Likewise.
16385
16386 2018-07-12 Richard Sandiford <richard.sandiford@linaro.org>
16387 Alan Hayward <alan.hayward@arm.com>
16388 David Sherwood <david.sherwood@arm.com>
16389
16390 * internal-fn.h (can_interpret_as_conditional_op_p): Declare.
16391 * internal-fn.c (can_interpret_as_conditional_op_p): New function.
16392 * tree-ssa-math-opts.c (convert_mult_to_fma_1): Handle conditional
16393 plus and minus and convert them into IFN_COND_FMA-based sequences.
16394 (convert_mult_to_fma): Handle conditional plus and minus.
16395
16396 2018-07-12 Richard Sandiford <richard.sandiford@linaro.org>
16397
16398 * doc/md.texi (cond_fma, cond_fms, cond_fnma, cond_fnms): Document.
16399 * optabs.def (cond_fma_optab, cond_fms_optab, cond_fnma_optab)
16400 (cond_fnms_optab): New optabs.
16401 * internal-fn.def (COND_FMA, COND_FMS, COND_FNMA, COND_FNMS): New
16402 internal functions.
16403 (FMA): Use DEF_INTERNAL_FLT_FN rather than DEF_INTERNAL_FLT_FLOATN_FN.
16404 * internal-fn.h (get_conditional_internal_fn): Declare.
16405 (get_unconditional_internal_fn): Likewise.
16406 * internal-fn.c (cond_ternary_direct): New macro.
16407 (expand_cond_ternary_optab_fn): Likewise.
16408 (direct_cond_ternary_optab_supported_p): Likewise.
16409 (FOR_EACH_COND_FN_PAIR): Likewise.
16410 (get_conditional_internal_fn): New function.
16411 (get_unconditional_internal_fn): Likewise.
16412 * gimple-match.h (gimple_match_op::MAX_NUM_OPS): Bump to 5.
16413 (gimple_match_op::gimple_match_op): Add a new overload for 5
16414 operands.
16415 (gimple_match_op::set_op): Likewise.
16416 (gimple_resimplify5): Declare.
16417 * genmatch.c (decision_tree::gen): Generate simplifications for
16418 5 operands.
16419 * gimple-match-head.c (gimple_simplify): Define an overload for
16420 5 operands. Handle calls with 5 arguments in the top-level overload.
16421 (convert_conditional_op): Handle conversions from unconditional
16422 internal functions to conditional ones.
16423 (gimple_resimplify5): New function.
16424 (build_call_internal): Pass a fifth operand.
16425 (maybe_push_res_to_seq): Likewise.
16426 (try_conditional_simplification): Try converting conditional
16427 internal functions to unconditional internal functions.
16428 Handle 3-operand unconditional forms.
16429 * match.pd (UNCOND_TERNARY, COND_TERNARY): Operator lists.
16430 Define ternary equivalents of the current rules for binary conditional
16431 internal functions.
16432 * config/aarch64/aarch64.c (aarch64_preferred_else_value): Handle
16433 ternary operations.
16434 * config/aarch64/iterators.md (UNSPEC_COND_FMLA, UNSPEC_COND_FMLS)
16435 (UNSPEC_COND_FNMLA, UNSPEC_COND_FNMLS): New unspecs.
16436 (optab): Handle them.
16437 (SVE_COND_FP_TERNARY): New int iterator.
16438 (sve_fmla_op, sve_fmad_op): New int attributes.
16439 * config/aarch64/aarch64-sve.md (cond_<optab><mode>)
16440 (*cond_<optab><mode>_2, *cond_<optab><mode_4)
16441 (*cond_<optab><mode>_any): New SVE_COND_FP_TERNARY patterns.
16442
16443 2018-07-12 Richard Sandiford <richard.sandiford@linaro.org>
16444
16445 * target.def (preferred_else_value): New target hook.
16446 * doc/tm.texi.in (TARGET_PREFERRED_ELSE_VALUE): New hook.
16447 * doc/tm.texi: Regenerate.
16448 * targhooks.h (default_preferred_else_value): Declare.
16449 * targhooks.c (default_preferred_else_value): New function.
16450 * internal-fn.h (conditional_internal_fn_code): Declare.
16451 * internal-fn.c (FOR_EACH_CODE_MAPPING): New macro.
16452 (get_conditional_internal_fn): Use it.
16453 (conditional_internal_fn_code): New function.
16454 * gimple-match.h (gimple_match_cond): New struct.
16455 (gimple_match_op): Add a cond member function.
16456 (gimple_match_op::gimple_match_op): Update all forms to take a
16457 gimple_match_cond.
16458 * genmatch.c (expr::gen_transform): Use the same condition as res_op
16459 for the suboperation, but don't specify a particular else_value.
16460 * tree-ssa-sccvn.c (vn_nary_simplify, vn_reference_lookup_3)
16461 (visit_nary_op, visit_reference_op_load): Pass
16462 gimple_match_cond::UNCOND to the gimple_match_op constructor.
16463 * gimple-match-head.c: Include tree-eh.h
16464 (convert_conditional_op): New function.
16465 (maybe_resimplify_conditional_op): Likewise.
16466 (gimple_resimplify1): Call maybe_resimplify_conditional_op.
16467 (gimple_resimplify2): Likewise.
16468 (gimple_resimplify3): Likewise.
16469 (gimple_resimplify4): Likewise.
16470 (maybe_push_res_to_seq): Return null for conditional operations.
16471 (try_conditional_simplification): New function.
16472 (gimple_simplify): Call it. Pass conditions to the gimple_match_op
16473 constructor.
16474 * match.pd: Fold VEC_COND_EXPRs of an IFN_COND_* call to a new
16475 IFN_COND_* call.
16476 * config/aarch64/aarch64.c (aarch64_preferred_else_value): New
16477 function.
16478 (TARGET_PREFERRED_ELSE_VALUE): Redefine.
16479
16480 2018-07-12 Jan Hubicka <hubicka@ucw.cz>
16481
16482 * lto-streamer-out.c (DFS::DFS_write_tree_body): Do not stream
16483 DECL_FCONTEXT
16484 (hash_tree): Do not hash DECL_FCONTEXT
16485 * tree-streamer-in.c (lto_input_ts_field_decl_tree_pointers):
16486 Do not stream DECL_FCONTEXT.
16487 * tree-streamer-out.c (write_ts_field_decl_tree_pointers): Likewise.
16488 * tree.c (free_lang_data_in_decl): Free DECL_FCONTEXT.
16489
16490 2018-07-12 Richard Biener <rguenther@suse.de>
16491
16492 PR debug/86462
16493 * dwarf2out.c (gen_block_die): Only output blocks when they have
16494 at least one !DECL_IGNORED_P variable.
16495
16496 2018-07-12 Richard Biener <rguenther@suse.de>
16497
16498 PR target/84829
16499 * config/gnu-user.h (GNU_USER_TARGET_NO_PTHREADS_LIB_SPEC):
16500 Remove -mieee-fp handling.
16501
16502 2018-07-12 Richard Biener <rguenther@suse.de>
16503
16504 * tree-ssa-sccvn.c (vn_lookup_simplify_result): Remove bogus
16505 left-over from last patch.
16506
16507 2018-07-12 Jakub Jelinek <jakub@redhat.com>
16508
16509 PR tree-optimization/86492
16510 * gimple-ssa-store-merging.c
16511 (imm_store_chain_info::coalesce_immediate_stores): Call
16512 check_no_overlap even for the merge_overlapping case. Formatting fix.
16513
16514 2018-07-12 Richard Biener <rguenther@suse.de>
16515
16516 PR middle-end/86479
16517 * fold-const.c (fold_binary_op_with_conditional_arg): Do not
16518 move possibly trapping operations into the conditional.
16519
16520 2018-07-12 Richard Biener <rguenther@suse.de>
16521
16522 * tree-ssa-sccvn.c (mprts_hook_cnt): Remove.
16523 (vn_lookup_simplify_result): Remove recursion limit applied
16524 here.
16525 (vn_nary_build_or_lookup_1): Adjust.
16526 (try_to_simplify): Likewise.
16527 * gimple-match-head.c (gimple_resimplify1): Instead apply one
16528 here.
16529 (gimple_resimplify2): Likewise.
16530 (gimple_resimplify3): Likewise.
16531 (gimple_resimplify4): Likewise.
16532
16533 2018-07-11 Jakub Jelinek <jakub@redhat.com>
16534
16535 * config/i386/avx512bitalgintrin.h (_mm512_mask_bitshuffle_epi64_mask):
16536 Use __mmask64 type instead of __mmask8 for __M argument.
16537 * config/i386/avx512fintrin.h (_mm512_mask_xor_epi64,
16538 _mm512_maskz_xor_epi64): Use __mmask8 type instead of __mmask16 for
16539 __U argument.
16540 (_mm512_mask_cmpneq_epi64_mask): Use __mmask8 type instead of
16541 __mmask16 for __M argument.
16542 (_mm512_maskz_insertf32x4, _mm512_maskz_inserti32x4,
16543 _mm512_mask_insertf32x4, _mm512_mask_inserti32x4): Cast last argument
16544 to __mmask16 instead of __mmask8.
16545 * config/i386/avx512vlintrin.h (_mm_mask_add_ps, _mm_maskz_add_ps,
16546 _mm256_mask_add_ps, _mm256_maskz_add_ps, _mm_mask_sub_ps,
16547 _mm_maskz_sub_ps, _mm256_mask_sub_ps, _mm256_maskz_sub_ps,
16548 _mm256_maskz_cvtepi32_ps, _mm_maskz_cvtepi32_ps): Use __mmask8 type
16549 instead of __mmask16 for __U argument.
16550 * config/i386/avx512vlbwintrin.h (_mm_mask_cmp_epi8_mask): Use
16551 __mmask16 instead of __mmask8 for __U argument.
16552 (_mm256_mask_cmp_epi8_mask): Use __mmask32 instead of __mmask16 for
16553 __U argument.
16554 (_mm256_cmp_epi8_mask): Use __mmask32 return type instead of
16555 __mmask16.
16556 (_mm_mask_cmp_epu8_mask): Use __mmask16 instead of __mmask8 for __U
16557 argument.
16558 (_mm256_mask_cmp_epu8_mask): Use __mmask32 instead of __mmask16 for
16559 __U argument.
16560 (_mm256_cmp_epu8_mask): Use __mmask32 return type instead of
16561 __mmask16.
16562 (_mm_mask_cmp_epi16_mask): Cast last argument to __mmask8 instead
16563 of __mmask16.
16564 (_mm256_mask_cvtepi8_epi16): Use __mmask16 instead of __mmask32 for
16565 __U argument.
16566 (_mm_mask_cvtepi8_epi16): Use __mmask8 instead of __mmask32 for
16567 __U argument.
16568 (_mm256_mask_cvtepu8_epi16): Use __mmask16 instead of __mmask32 for
16569 __U argument.
16570 (_mm_mask_cvtepu8_epi16): Use __mmask8 instead of __mmask32 for
16571 __U argument.
16572 (_mm256_mask_cmpneq_epu8_mask, _mm256_mask_cmplt_epu8_mask,
16573 _mm256_mask_cmpge_epu8_mask, _mm256_mask_cmple_epu8_mask): Change
16574 return type as well as __M argument type and all casts from __mmask8
16575 to __mmask32.
16576 (_mm256_mask_cmpneq_epu16_mask, _mm256_mask_cmplt_epu16_mask,
16577 _mm256_mask_cmpge_epu16_mask, _mm256_mask_cmple_epu16_mask): Change
16578 return type as well as __M argument type and all casts from __mmask8
16579 to __mmask16.
16580 (_mm256_mask_cmpneq_epi8_mask, _mm256_mask_cmplt_epi8_mask,
16581 _mm256_mask_cmpge_epi8_mask, _mm256_mask_cmple_epi8_mask): Change
16582 return type as well as __M argument type and all casts from __mmask8
16583 to __mmask32.
16584 (_mm256_mask_cmpneq_epi16_mask, _mm256_mask_cmplt_epi16_mask,
16585 _mm256_mask_cmpge_epi16_mask, _mm256_mask_cmple_epi16_mask): Change
16586 return type as well as __M argument type and all casts from __mmask8
16587 to __mmask16.
16588 * config/i386/avx512vbmi2vlintrin.h (_mm_mask_shrdi_epi32,
16589 _mm_mask_shldi_epi32): Cast last argument to __mmask8 instead of
16590 __mmask16.
16591
16592 2018-07-11 Grazvydas Ignotas <notasas@gmail.com>
16593
16594 * config/i386/avx512bwintrin.h: (_mm512_mask_cmp_epi8_mask,
16595 _mm512_mask_cmp_epu8_mask): Use __mmask64 type instead of __mmask32
16596 for __U argument.
16597
16598 2018-07-11 Paul Koning <ni1d@arrl.net>
16599
16600 * doc/md.texi (define_subst): Document how multiple occurrences of
16601 the same argument in the replacement pattern are handled.
16602
16603 2018-07-11 Paul Koning <ni1d@arrl.net>
16604
16605 * doc/extend.texi (Common Variable Attributes): Move "mode" into
16606 alphabetical order.
16607 (Common Type Attributes): Add "mode" attribute.
16608
16609 2018-07-11 Jan Hubicka <hubicka@ucw.cz>
16610
16611 * lto-streamer-out.c (DFS::DFS_write_tree_body): Do not
16612 stream DECL_ORIGINAL_TYPE.
16613 (DFS::DFS_write_tree_body): Drop hack handling local external decls.
16614 (hash_tree): Do not walk DECL_ORIGINAL_TYPE.
16615 * tree-streamer-in.c (lto_input_ts_decl_non_common_tree_pointers):
16616 Do not walk original type.
16617 * tree-streamer-out.c (streamer_write_chain): Drop hack handling
16618 external decls.
16619 (write_ts_decl_non_common_tree_pointers): Do not stream
16620 DECL_ORIGINAL_TYPE
16621 * tree.c (free_lang_data_in_decl): Clear DECL_ORIGINAL_TYPE.
16622 (find_decls_types_r): Do not walk DEC_ORIGINAL_TYPE.
16623
16624 2018-07-11 Aldy Hernandez <aldyh@redhat.com>
16625
16626 * tree-ssa-threadupdate.c (thread_through_all_blocks): Do not jump
16627 thread twice from the same starting edge.
16628
16629 2018-07-11 Aldy Hernandez <aldyh@redhat.com>
16630
16631 * vr-values.c (gimple_stmt_nonzero_p): Abstract common code to...
16632 * gimple.c (gimple_call_nonnull_result_p): ...here...
16633 (gimple_call_nonnull_arg): ...and here.
16634 * gimple.h (gimple_call_nonnull_result_p): New.
16635 (gimple_call_nonnull_arg): New.
16636
16637 2018-07-11 Richard Earnshaw <rearnsha@arm.com>
16638
16639 * config/arm/arm-cpus.in: Move information from fpu field of each
16640 cpu definition to the isa field.
16641 * config/arm/parsecpu.awk (fpu): Delete match rule.
16642 (gen_comm_data): Don't add bits from the CPU's FPU entry.
16643
16644 2018-07-11 Richard Biener <rguenther@suse.de>
16645
16646 PR debug/86457
16647 * dwarf2out.c (init_sections_and_labels): Use
16648 output_asm_line_debug_info consistently.
16649 (dwarf2out_early_finish): Likewise.
16650 (dwarf2out_finish): Remove DW_AT_stmt_list from early generated
16651 type units.
16652
16653 2018-07-11 Richard Biener <rguenther@suse.de>
16654
16655 * tree-ssa-loop-ivcanon.c (tree_unroll_loops_completely_1):
16656 Rework father_bb setting in a way to avoid propagating constants
16657 multiple times on a loop body.
16658
16659 2018-07-10 Mark Wielaard <mark@klomp.org>
16660
16661 PR debug/86459
16662 * dwarf2out.c (output_macinfo_op): Fix dwarf_FORM typo in gcc_assert.
16663
16664 2018-07-10 Richard Biener <rguenther@suse.de>
16665
16666 * hash-map.h (hash_map::iterator::operator*): Return
16667 references to key and value.
16668
16669 2018-07-10 Jakub Jelinek <jakub@redhat.com>
16670
16671 PR c++/86443
16672 * gimplify.c (find_combined_omp_for): Add DATA argument, in addition
16673 to finding the inner OMP_FOR/OMP_SIMD stmt find non-trivial wrappers,
16674 BLOCKs with BLOCK_VARs, OMP_PARALLEL in between, OMP_FOR in between.
16675 (gimplify_omp_for): For composite loops, move outer
16676 OMP_{DISTRIBUTE,TASKLOOP,FOR,PARALLEL} right around innermost
16677 OMP_FOR/OMP_SIMD if there are any non-trivial wrappers. For class
16678 iterators add any needed clauses. Allow OMP_FOR_ORIG_DECLS to contain
16679 TREE_LIST for both the original class iterator and the "last" helper
16680 var. Gimplify OMP_FOR_PRE_BODY before the outermost composite
16681 loop, remember has_decl_expr from outer composite loops for the
16682 innermost OMP_SIMD in TREE_PRIVATE bit on OMP_FOR_INIT.
16683
16684 2018-07-09 Martin Sebor <msebor@redhat.com>
16685
16686 PR middle-end/77357
16687 PR middle-end/86428
16688 * builtins.c (c_strlen): Avoid out-of-bounds warnings when
16689 accessing implicitly initialized array elements.
16690 * expr.c (string_constant): Handle string initializers of
16691 character arrays within aggregates.
16692 * gimple-fold.c (fold_array_ctor_reference): Add argument.
16693 Store element offset. As a special case, handle zero size.
16694 (fold_nonarray_ctor_reference): Same.
16695 (fold_ctor_reference): Add argument. Store subobject offset.
16696 * gimple-fold.h (fold_ctor_reference): Add argument.
16697
16698 2018-07-09 Paul Koning <ni1d@arrl.net>
16699
16700 * config/pdp11/pdp11.c (pdp11_addr_cost): New function.
16701 (pdp11_insn_cost): New function.
16702 (pdp11_md_asm_adjust): New function.
16703 (TARGET_INVALID_WITHIN_DOLOOP): Define.
16704 (pdp11_rtx_costs): Update to match machine better.
16705 (output_addr_const_pdp11): Correct format mismatch warnings.
16706 * config/pdp11/pdp11.h (SLOW_BYTE_ACCESS): Correct definition.
16707 * config/pdp11/pdp11.md: General change to add base_cost and/or
16708 length attributes for use by new pdp11_insn_cost function.
16709 (MIN_BRANCH): Correct definition.
16710 (MIN_SOB): Ditto.
16711 (doloop_end): Use standard pattern name for looping pattern.
16712 (doloop_end_nocc): New.
16713 (movsf): Add another constraint alternative.
16714 (zero_extendqihi2): Add constraint alternatives for not in place
16715 extend.
16716 (zero_extendhisi2): Remove.
16717 (shift patterns): Add CC handling variants.
16718 (bswaphi2): New.
16719 (bswapsi2): New.
16720 (rothi3): New.
16721 (define_peephole2): New peephole to recognize mov that sets CC for
16722 subsequent test.
16723
16724 2018-07-09 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
16725
16726 * config/sparc/sparc.c (sparc_fold_builtin) <SPARC_BUILTIN_PDIST,
16727 SPARC_BUILTIN_PDISTN>: Adapt for signature change of wi::neg,
16728 wi::add.
16729
16730 2018-07-09 Jakub Jelinek <jakub@redhat.com>
16731
16732 PR c/86420
16733 * real.c (real_nextafter): Return true if result is denormal.
16734
16735 2018-07-09 Martin Liska <mliska@suse.cz>
16736
16737 * common.opt: Add back wrongly removed attribute.
16738
16739 2018-07-09 Richard Biener <rguenther@suse.de>
16740
16741 PR debug/86413
16742 * dwarf2out.c (gen_block_die): For an early generated DIE
16743 always output high/low PC attributes.
16744
16745 2018-07-09 Tom de Vries <tdevries@suse.de>
16746
16747 * cfgexpand.c (expand_debug_source_expr): Handle VAR_DECL.
16748 * tree-inline.c (remap_ssa_name): Handle default def ssa_name mapping
16749 onto VAR_DECL with abstract origin.
16750
16751 2018-07-07 Jim Wilson <jimw@sifive.com>
16752
16753 * config/riscv/riscv.c (TARGET_CUSTOM_FUNCTION_DESCRIPTORS): New.
16754
16755 2018-07-07 Tom de Vries <tdevries@suse.de>
16756
16757 * tree-dfa.c (dump_enumerated_decls): Handle cfun->cfg == NULL.
16758
16759 2018-07-07 Aldy Hernandez <aldyh@redhat.com>
16760
16761 * tree-vrp.c (vrp_int_const_binop): Change overflow type to
16762 overflow_type.
16763 (combine_bound): Use wide-int overflow calculation instead of
16764 rolling our own.
16765 * calls.c (maybe_warn_alloc_args_overflow): Change overflow type to
16766 overflow_type.
16767 * fold-const.c (int_const_binop_2): Same.
16768 (extract_muldiv_1): Same.
16769 (fold_div_compare): Same.
16770 (fold_abs_const): Same.
16771 * match.pd: Same.
16772 * poly-int.h (add): Same.
16773 (sub): Same.
16774 (neg): Same.
16775 (mul): Same.
16776 * predict.c (predict_iv_comparison): Same.
16777 * profile-count.c (slow_safe_scale_64bit): Same.
16778 * simplify-rtx.c (simplify_const_binary_operation): Same.
16779 * tree-chrec.c (tree_fold_binomial): Same.
16780 * tree-data-ref.c (split_constant_offset_1): Same.
16781 * tree-if-conv.c (idx_within_array_bound): Same.
16782 * tree-scalar-evolution.c (iv_can_overflow_p): Same.
16783 * tree-ssa-phiopt.c (minmax_replacement): Same.
16784 * tree-vect-loop.c (is_nonwrapping_integer_induction): Same.
16785 * tree-vect-stmts.c (vect_truncate_gather_scatter_offset): Same.
16786 * vr-values.c (vr_values::adjust_range_with_scev): Same.
16787 * wide-int.cc (wi::add_large): Same.
16788 (wi::mul_internal): Same.
16789 (wi::sub_large): Same.
16790 (wi::divmod_internal): Same.
16791 * wide-int.h: Change overflow type to overflow_type for neg, add,
16792 mul, smul, umul, div_trunc, div_floor, div_ceil, div_round,
16793 mod_trunc, mod_ceil, mod_round, add_large, sub_large,
16794 mul_internal, divmod_internal.
16795 (overflow_type): New enum.
16796 (accumulate_overflow): New.
16797
16798 2018-07-06 Kugan Vivekanandarajah <kugan.vivekanandarajah@linaro.org>
16799
16800 * tree-ssa-phiopt.c (cond_removal_in_popcount_pattern): New.
16801 (tree_ssa_phiopt_worker): Call cond_removal_in_popcount_pattern.
16802
16803 2018-07-06 Kugan Vivekanandarajah <kuganv@linaro.org>
16804
16805 * tree-ssa-loop-niter.c (number_of_iterations_popcount): If popcount
16806 argument is checked for zero before entering loop, avoid checking again.
16807
16808 2018-07-06 Kugan Vivekanandarajah <kuganv@linaro.org>
16809
16810 * gimplify.h (generic_expr_could_trap_p): Set as global function.
16811 * gimplify.h (generic_expr_could_trap_p): Likwise.
16812 * tree-scalar-evolution.c (expression_expensive_p): Handle COND_EXPR.
16813
16814 2018-07-06 Jakub Jelinek <jakub@redhat.com>
16815
16816 PR tree-optimization/86401
16817 * fold-const.c (fold_binary_loc) <case BIT_AND_EXPR>: Move the
16818 ((A & N) + B) & M -> (A + B) & M etc. optimization into ...
16819 (fold_bit_and_mask): ... here. New helper function for match.pd.
16820 * fold-const.h (fold_bit_and_mask): Declare.
16821 * match.pd (((A & N) + B) & M -> (A + B) & M): New optimization.
16822
16823 2018-07-06 Peter Bergner <bergner@linux.ibm.com>
16824
16825 PR target/86324
16826 * target.def (translate_mode_attribute): New hook.
16827 * targhooks.h (default_translate_mode_attribute): Declare.
16828 * targhooks.c (default_translate_mode_attribute): New function.
16829 * doc/tm.texi.in (TARGET_TRANSLATE_MODE_ATTRIBUTE): New hook.
16830 * doc/tm.texi: Regenerate.
16831 * config/rs6000/rs6000.c (TARGET_TRANSLATE_MODE_ATTRIBUTE): Define.
16832 (rs6000_translate_mode_attribute): New function.
16833
16834 2018-07-06 Paul Koning <ni1d@arrl.net>
16835
16836 * doc/md.texi (define_split): Document DONE and FAIL.
16837 (define_peephole2): Ditto.
16838
16839 2018-07-05 Jeff Law <law@redhat.com>
16840
16841 PR tree-optimization/86010
16842 * tree-ssa-dse.c (compute_trims): More aggressively trim at
16843 both the head and tail of mem* and str* calls.
16844
16845 2018-07-05 Jim Wilson <jimw@sifive.com>
16846
16847 * config.gcc (riscv*-*-*): When setting xlen, handle riscv-*.
16848
16849 2018-07-05 Indu Bhagat <indu.bhagat@oracle.com>
16850
16851 * config/aarch64/aarch64-simd.md: correct flags text for
16852 MIN_EXPR replacement.
16853
16854 2018-07-05 James Clarke <jrtc27@jrtc27.com>
16855
16856 * configure: Regenerated.
16857
16858 2018-07-05 Carl Love <cel@us.ibm.com>
16859
16860 * config/rs6000/rs6000-c.c: Map ALTIVEC_BUILTIN_VEC_UNPACKH for
16861 float argument to VSX_BUILTIN_DOUBLEH_V4SF.
16862 Map ALTIVEC_BUILTIN_VEC_UNPACKL for float argument to
16863 VSX_BUILTIN_DOUBLEL_V4SF.
16864
16865 2018-07-05 Martin Sebor <msebor@redhat.com>
16866
16867 PR c++/86400
16868 * tree-ssa-strlen.c (maybe_set_strlen_range): Use type size rather
16869 than its domain to compute its the upper bound of a char array.
16870
16871 2018-07-05 Nathan Sidwell <nathan@acm.org>
16872
16873 Replace NO_IMPLICIT_EXTERN_C with SYSTEM_IMPLICIT_EXTERN_C.
16874 * doc/cpp.texi: Update comment.
16875 * doc/tm.texi: Rebuilt.
16876 * doc/tm.texi.in (NO_IMPLICIT_EXTERN_C): Replace with ...
16877 (SYSTEM_IMPLICIT_EXTERN_C): ... this, opposite sense.
16878 * doc/extend.texi (Backwards Compatibility): Clarify it is system
16879 headers affected by extern "C".
16880 * system.h: Poison NO_IMPLICIT_EXTERN_C.
16881 * config/alpha/alpha.h, config/arm/uclinux-elf.h,
16882 config/bfin/elf.h, config/cris/cris.h, config/darwin.h,
16883 config/dragonfly.h, config/freebsd.h, config/gnu-user.h,
16884 config/i386/cygming.h, config/i386/djgpp.h, config/i386/nto.h,
16885 config/ia64/hpux.h, config/lm32/lm32.h, config/lm32/uclinux-elf.h,
16886 config/lynx.h, config/mips/elf.h, config/mmix/mmix.h,
16887 config/netbsd.h, config/pa/pa-hpux.h, config/powerpcspe/sysv4.h,
16888 config/riscv/elf.h, config/rs6000/sysv4.h, config/rtems.h,
16889 config/s390/tpf.h, config/sh/newlib.h, config/sol2.h,
16890 config/sparc/openbsd64.h, config/sparc/sp-elf.h,
16891 config/sparc/sp64-elf.h, config/spu/spu.h,
16892 config/stormy16/stormy16.h, config/v850/v850.h,
16893 config/visium/visium.h, config/vx-common.h, config/xtensa/elf.h: Don't
16894 define NO_IMPLICIT_EXTERN_C.
16895 * config/rs6000/aix.h: Set SYSTEM_IMPLICIT_EXTERN_C.
16896
16897 2018-07-05 Tamar Christina <tamar.christina@arm.com>
16898
16899 PR target/84711
16900 * config/arm/arm.c (arm_can_change_mode_class): Use GET_MODE_UNIT_SIZE
16901 instead of GET_MODE_SIZE when comparing Units.
16902
16903 2018-07-05 Tamar Christina <tamar.christina@arm.com>
16904
16905 PR target/84711
16906 * rtlanal.c (set_noop_p): Constrain on mode change,
16907 include hard-reg-set.h
16908
16909 2018-07-05 Tamar Christina <tamar.christina@arm.com>
16910
16911 * config/aarch64/aarch64.c (aarch64_expand_movmem): Fix mode size.
16912
16913 2018-07-05 Jakub Jelinek <jakub@redhat.com>
16914
16915 Revert
16916 2018-07-04 Maxim Ostapenko <m.ostapenko@samsung.com>
16917
16918 PR sanitizer/84250
16919 * config/gnu-user.h (LIBASAN_EARLY_SPEC): Pass -lstdc++ for static
16920 libasan.
16921 * gcc.c: Do not pass LIBUBSAN_SPEC if ASan is enabled with UBSan.
16922
16923 2018-07-04 Maxim Ostapenko <m.ostapenko@samsung.com>
16924
16925 PR sanitizer/84250
16926 * config/gnu-user.h (LIBASAN_EARLY_SPEC): Pass -lstdc++ for static
16927 libasan.
16928 * gcc.c: Do not pass LIBUBSAN_SPEC if ASan is enabled with UBSan.
16929
16930 2018-07-04 Eric Botcazou <ebotcazou@adacore.com>
16931
16932 PR middle-end/86380
16933 * expmed.c (choose_multiplier): Fix incorrect comparison with mask.
16934
16935 2018-07-04 Aldy Hernandez <aldyh@redhat.com>
16936
16937 * tree-vrp.c (extract_range_from_binary_expr_1): Initialize
16938 neg_*_op* variables.
16939
16940 2018-07-04 Martin Liska <mliska@suse.cz>
16941
16942 * tree-switch-conversion.c: Define
16943 max_ratio_for_speed and max_ratio_for_size constants.
16944
16945 2018-07-04 Denys Vlasenko <dvlasenk@redhat.com>
16946 Martin Liska <mliska@suse.cz>
16947
16948 PR middle-end/66240
16949 PR target/45996
16950 PR c/84100
16951 * common.opt: Rename align options with 'str_' prefix.
16952 * common/config/i386/i386-common.c (set_malign_value): New
16953 function.
16954 (ix86_handle_option): Use it to set -falign-* options/
16955 * config/aarch64/aarch64-protos.h (struct tune_params): Change
16956 type from int to string.
16957 * config/aarch64/aarch64.c: Update default values from int
16958 to string.
16959 * config/alpha/alpha.c (alpha_override_options_after_change):
16960 Likewise.
16961 * config/arm/arm.c (arm_override_options_after_change_1): Likewise.
16962 * config/i386/dragonfly.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Print
16963 max skip conditionally.
16964 * config/i386/freebsd.h (SUBALIGN_LOG): New.
16965 (ASM_OUTPUT_MAX_SKIP_ALIGN): Print
16966 max skip conditionally.
16967 * config/i386/gas.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Print
16968 max skip conditionally.
16969 * config/i386/gnu-user.h (SUBALIGN_LOG): New.
16970 (ASM_OUTPUT_MAX_SKIP_ALIGN): Print
16971 max skip conditionally.
16972 * config/i386/i386.c (struct ptt): Change type from int to
16973 string.
16974 (ix86_default_align): Set default values.
16975 * config/i386/i386.h (ASM_OUTPUT_MAX_SKIP_PAD): Print
16976 max skip conditionally.
16977 * config/i386/iamcu.h (SUBALIGN_LOG): New.
16978 (ASM_OUTPUT_MAX_SKIP_ALIGN):
16979 * config/i386/lynx.h (ASM_OUTPUT_MAX_SKIP_ALIGN):
16980 * config/i386/netbsd-elf.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Print
16981 max skip conditionally.
16982 * config/i386/openbsdelf.h (SUBALIGN_LOG): New.
16983 (ASM_OUTPUT_MAX_SKIP_ALIGN) Print max skip conditionally.:
16984 * config/i386/x86-64.h (SUBALIGN_LOG): New.
16985 (ASM_OUTPUT_MAX_SKIP_ALIGN): Print
16986 max skip conditionally.
16987 (ASM_OUTPUT_MAX_SKIP_PAD): Likewise.
16988 * config/ia64/ia64.c (ia64_option_override): Set default values
16989 for alignment options.
16990 * config/m68k/m68k.c: Handle new str_align_* options.
16991 * config/mips/mips.c (mips_set_compression_mode): Change
16992 type of constants.
16993 (mips_option_override): Set default values for options.
16994 * config/powerpcspe/powerpcspe.c (rs6000_option_override_internal):
16995 Likewise.
16996 * config/rs6000/rs6000.c (rs6000_option_override_internal):
16997 Likewise.
16998 * config/rx/rx.c (rx_option_override): Likewise.
16999 * config/rx/rx.h (JUMP_ALIGN): Use align_jumps_log.
17000 (LABEL_ALIGN): Use align_labels_log.
17001 (LOOP_ALIGN): Use align_loops_align.
17002 * config/s390/s390.c (s390_asm_output_function_label): Use new
17003 macros.
17004 * config/sh/sh.c (sh_override_options_after_change):
17005 Change type of constants.
17006 * config/spu/spu.c (spu_sched_init): Likewise.
17007 * config/sparc/sparc.c (sparc_option_override): Set default
17008 values for options.
17009 * config/visium/visium.c (visium_option_override): Likewise.
17010 * config/visium/visium.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Do not
17011 emit p2align format with last argument if it's not needed.
17012 * doc/invoke.texi: Document extended format of -falign-*.
17013 * final.c: Use align_labels alignment.
17014 * flags.h (struct target_flag_state): Change type to use
17015 align_flags.
17016 (struct align_flags_tuple): New.
17017 (struct align_flags): Likewise.
17018 (align_loops_log): Redefine macro to use new types.
17019 (align_loops_max_skip): Redefine macro to use new types.
17020 (align_jumps_log): Redefine macro to use new types.
17021 (align_jumps_max_skip): Redefine macro to use new types.
17022 (align_labels_log): Redefine macro to use new types.
17023 (align_labels_max_skip): Redefine macro to use new types.
17024 (align_functions_log): Redefine macro to use new types.
17025 (align_loops): Redefine macro to use new types.
17026 (align_jumps): Redefine macro to use new types.
17027 (align_labels): Redefine macro to use new types.
17028 (align_functions): Redefine macro to use new types.
17029 (align_functions_max_skip): Redefine macro to use new types.
17030 (align_loops_value): New macro.
17031 (align_jumps_value): New macro.
17032 (align_labels_value): New macro.
17033 (align_functions_value): New macro.
17034 * function.c (invoke_set_current_function_hook): Propagate
17035 alignment values from flags to global variables default in
17036 topleev.h.
17037 * ipa-icf.c (sem_function::equals_wpa): Use
17038 cl_optimization_option_eq instead of memcmp.
17039 * lto-streamer.h (cl_optimization_stream_out): Support streaming
17040 of string types.
17041 (cl_optimization_stream_in): Likewise.
17042 * optc-save-gen.awk: Support strings in cl_optimization.
17043 * opth-gen.awk: Likewise.
17044 * opts.c (finish_options): Remove error checking of invalid
17045 value ranges.
17046 (MAX_CODE_ALIGN): Remove.
17047 (MAX_CODE_ALIGN_VALUE): Likewise.
17048 (parse_and_check_align_values): New function.
17049 (check_alignment_argument): Likewise.
17050 (common_handle_option): Use check_alignment_argument.
17051 * opts.h (parse_and_check_align_values): Declare.
17052 * toplev.c (init_alignments): Remove.
17053 (read_log_maxskip): New.
17054 (parse_N_M): Likewise.
17055 (parse_alignment_opts): Likewise.
17056 (backend_init_target): Remove usage of init_alignments.
17057 * toplev.h (parse_alignment_opts): Declare.
17058 * tree-streamer-in.c (streamer_read_tree_bitfields): Add new
17059 argument.
17060 * tree-streamer-out.c (streamer_write_tree_bitfields): Likewise.
17061 * tree.c (cl_option_hasher::equal): New.
17062 * varasm.c: Use new global macros.
17063
17064 2018-07-04 Denys Vlasenko <dvlasenk@redhat.com>
17065
17066 * config/i386/dragonfly.h: (ASM_OUTPUT_MAX_SKIP_ALIGN):
17067 Use a simpler align directive also if MAXSKIP = ALIGN-1.
17068 * config/i386/gas.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
17069 * config/i386/lynx.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
17070 * config/i386/netbsd-elf.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
17071 * config/i386/i386.h (ASM_OUTPUT_MAX_SKIP_PAD): Likewise.
17072 * config/i386/freebsd.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Remove "If N
17073 is large, do at least 8 byte alignment" code. Add SUBALIGN_LOG
17074 define. Use a simpler align directive also if MAXSKIP = ALIGN-1.
17075 * config/i386/gnu-user.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
17076 * config/i386/iamcu.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
17077 * config/i386/openbsdelf.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
17078 * config/i386/x86-64.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
17079
17080 2018-07-04 Martin Liska <mliska@suse.cz>
17081 Jonathan Wakely <jwakely@redhat.com>
17082
17083 * coverage.c: Use correct type.
17084 * doc/invoke.texi: Language correction.
17085
17086 2018-07-03 H.J. Lu <hongjiu.lu@intel.com>
17087
17088 PR target/85620
17089 * config/i386/i386.c (rest_of_insert_endbranch): Also generate
17090 ENDBRANCH for non-tail call which may return via indirect branch.
17091 * doc/extend.texi: Document indirect_return attribute.
17092
17093 2018-07-03 Martin Sebor <msebor@redhat.com>
17094
17095 PR tree-optimization/86274
17096 * gimple-ssa-sprintf.c (fmtresult::type_max_digits): Verify
17097 precondition.
17098 (format_floating): Correct handling of infinities and NaNs.
17099
17100 2018-07-03 Martin Sebor <msebor@redhat.com>
17101
17102 * print-tree.c (print_real_cst): New function.
17103 (print_node_brief): Call it.
17104 (print_node): Ditto.
17105
17106 2018-07-03 Jeff Law <law@redhat.com>
17107
17108 * config/h8300/h8300.md (logical<mode>3_sn, logical<mode>3): Merge
17109 into a single pattern.
17110
17111 * config/h8300/h8300.md (ors code_iterator): New.
17112 (bsetqi_msx, bnotqi_msx patterns and splitters): Consolidate into
17113 a single pattern and single splitter.
17114 (bsethi_msx, bnothi_msx patterns): Consolidate into a single pattern.
17115 (iorqi3_1, xorqi3_1): Likewise.
17116 (iorqi3, xorqi3 expanders): Similarly.
17117
17118 * config/h8300/h8300.md (movmd_internal_normal): Consolidated with
17119 (movmd_internal) into a single pattern using the P mode iterator.
17120 (movmd splitters): Similarly.
17121 (stpcpy_internal_normal, stpcpy_internal): Similarly for thes patterns.
17122 (movsd splitters): Similarly.
17123
17124 * config/h8300/h8300.c (h8300_insn_length_from_table): Consolidate
17125 ADDB, ADDW and ADDL into a single ADD attribute which selects the
17126 right table based on the size of the operand.
17127 * config/h8300/h8300.md (length_table): Corresponding changes. All
17128 references to "addb", "addw" and "addl" changed to "add".
17129 (btst patterns): Merge two variants into a single pattern.
17130 (tstqi, tsthi): Likewise.
17131 (addhi3_incdec, addsi3_incdec): Likewise.
17132 (subhi3_h8300hs, subsi3_h8300hs): Likewise.
17133 (mulhi3, mulsi3): Likewise.
17134 (udivhi3, udivsi3): Likewise.
17135 (divhi3, divsi3): Likewise.
17136 (andorqi3, andorhi3, andorsi3): Likewise.
17137
17138 2018-07-03 Uros Bizjak <ubizjak@gmail.com>
17139
17140 PR target/85694
17141 * config/i386/sse.md (uavg<mode>3_ceil): New expander.
17142 (<sse2_avx2>_uavg<mode>3<mask_name>): Simplify expander.
17143
17144 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
17145
17146 PR tree-optimization/85694
17147 * config/aarch64/iterators.md (HADD, RHADD): New int iterators.
17148 (u): Handle UNSPEC_SHADD, UNSPEC_UHADD, UNSPEC_SRHADD and
17149 UNSPEC_URHADD.
17150 * config/aarch64/aarch64-simd.md (<u>avg<mode>3_floor)
17151 (<u>avg<mode>3_ceil): New patterns.
17152
17153 2018-07-03 David Malcolm <dmalcolm@redhat.com>
17154
17155 * gcc.dg/vect/slp-perm-1.c: Remove "note: " prefix from
17156 scan-tree-dump directive.
17157 * gcc.dg/vect/slp-perm-2.c: Likewise.
17158 * gcc.dg/vect/slp-perm-3.c: Likewise.
17159 * gcc.dg/vect/slp-perm-5.c: Likewise.
17160 * gcc.dg/vect/slp-perm-6.c: Likewise.
17161 * gcc.dg/vect/slp-perm-7.c: Likewise.
17162 * gcc.dg/vect/slp-perm-8.c: Likewise.
17163
17164 2018-07-03 Marek Polacek <polacek@redhat.com>
17165
17166 PR middle-end/86202
17167 * gimple-fold.c (size_must_be_zero_p): Check the type of the size.
17168
17169 2018-07-03 Richard Biener <rguenther@suse.de>
17170
17171 PR ipa/86389
17172 * tree-ssa-structalias.c (find_func_clobbers): Properly
17173 handle indirect calls.
17174
17175 2018-07-03 Jeff Law <law@redhat.com>
17176
17177 * config/h8300/h8300.md (HSI, QHSI, QHSIF): New mode iterators.
17178 (shifts): New code iterator.
17179 (movqi, movhi, movsi, movsf expanders): Consolidate into a single
17180 expander. Fix HImode handling on H8/SX.
17181 (addqi3, addhi3, addsi3 expanders): Consolidate into a single expander.
17182 (subqi3, subhi3, subsi3 expanders): Likewise.
17183 (andqi3, andhi3, andsi3 expanders): Likewise.
17184 (iorqi3, iorhi3, iorsi3 expanders): Likewise.
17185 (xorqi3, xorhi3, xorsi3 expanders): Likewise.
17186 (negqi2, neghi2, negsi2, negsf2 expanders): Likewise.
17187 (one_cmplqi2, one_cmplhi2, one_cmplsi2): Likewise.
17188 (zero_extendqihi2, zero_extendqisi2): Likewise.
17189 (extendqihi2, extendqisi2): Likewise.
17190 (rotlqi3, rotlhi3, rotlsi3): Likewise.
17191 (neghi2_h8300, negsi2_h8300): Likewise for these patterns.
17192 (rotlqi3_1, rotlhi3_1): Likewise.
17193 (logicalhi3_sn, logicalsi3_sn): Likewise.
17194 (logicalhi3, logicalsi3): Likewise.
17195
17196 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
17197
17198 * tree-vect-patterns.c (vect_recog_rotate_pattern)
17199 (vect_recog_vector_vector_shift_pattern, vect_recog_divmod_pattern)
17200 (vect_recog_mixed_size_cond_pattern, adjust_bool_pattern_cast)
17201 (adjust_bool_pattern, vect_recog_bool_pattern): Pass the vector
17202 type to append_pattern_def_seq instead of creating a stmt_vec_info
17203 directly.
17204 (build_mask_conversion): Likewise. Remove vinfo argument.
17205 (vect_add_conversion_to_patterm): Likewise, renaming to...
17206 (vect_add_conversion_to_pattern): ...this.
17207 (vect_recog_mask_conversion_pattern): Update call to
17208 build_mask_conversion. Pass the vector type to
17209 append_pattern_def_seq here too.
17210 (vect_recog_gather_scatter_pattern): Update call to
17211 vect_add_conversion_to_pattern.
17212
17213 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
17214
17215 * tree-vect-patterns.c (new_pattern_def_seq): Delete.
17216 (vect_recog_dot_prod_pattern, vect_recog_sad_pattern)
17217 (vect_recog_widen_op_pattern, vect_recog_over_widening_pattern)
17218 (vect_recog_rotate_pattern, vect_synth_mult_by_constant): Don't set
17219 STMT_VINFO_PATTERN_DEF_SEQ to null here.
17220 (vect_recog_pow_pattern, vect_recog_vector_vector_shift_pattern)
17221 (vect_recog_mixed_size_cond_pattern, vect_recog_bool_pattern): Use
17222 append_pattern_def_seq instead of new_pattern_def_seq.
17223 (vect_recog_divmod_pattern): Do both of the above.
17224 (vect_pattern_recog_1): Assert that STMT_VINO_PATTERN_DEF_SEQ
17225 is null.
17226
17227 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
17228
17229 * tree-vect-patterns.c (vect_recog_dot_prod_pattern):
17230 (vect_recog_sad_pattern, vect_recog_widen_op_pattern)
17231 (vect_recog_widen_mult_pattern, vect_recog_pow_pattern):
17232 (vect_recog_widen_sum_pattern, vect_recog_over_widening_pattern)
17233 (vect_recog_average_pattern, vect_recog_cast_forwprop_pattern)
17234 (vect_recog_widen_shift_pattern, vect_recog_rotate_pattern)
17235 (vect_recog_vector_vector_shift_pattern, vect_synth_mult_by_constant)
17236 (vect_recog_mult_pattern, vect_recog_divmod_pattern)
17237 (vect_recog_mixed_size_cond_pattern, vect_recog_bool_pattern)
17238 (vect_recog_mask_conversion_pattern): Replace vec<gimple *>
17239 parameter with a single stmt_vec_info.
17240 (vect_recog_func_ptr): Likewise.
17241 (vect_recog_gather_scatter_pattern): Likewise, folding in...
17242 (vect_try_gather_scatter_pattern): ...this.
17243 (vect_pattern_recog_1): Remove stmts_to_replace and just pass
17244 the stmt_vec_info of the statement to be matched. Don't clear
17245 STMT_VINFO_RELATED_STMT.
17246 (vect_pattern_recog): Update call accordingly.
17247
17248 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
17249
17250 PR tree-optimization/85694
17251 * doc/md.texi (avgM3_floor, uavgM3_floor, avgM3_ceil)
17252 (uavgM3_ceil): Document new optabs.
17253 * doc/sourcebuild.texi (vect_avg_qi): Document new target selector.
17254 * internal-fn.def (IFN_AVG_FLOOR, IFN_AVG_CEIL): New internal
17255 functions.
17256 * optabs.def (savg_floor_optab, uavg_floor_optab, savg_ceil_optab)
17257 (savg_ceil_optab): New optabs.
17258 * tree-vect-patterns.c (vect_recog_average_pattern): New function.
17259 (vect_vect_recog_func_ptrs): Add it.
17260 * tree-vect-stmts.c (vectorizable_call): Get the type of the zero
17261 constant directly from the associated lhs.
17262
17263 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
17264
17265 * tree-vect-patterns.c (vect_split_statement): New function.
17266 (vect_convert_input): Use it to try to split an existing cast.
17267
17268 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
17269
17270 * poly-int.h (print_hex): New function.
17271 * dumpfile.h (dump_dec, dump_hex): Declare.
17272 * dumpfile.c (dump_dec, dump_hex): New poly_wide_int functions.
17273 * tree-vectorizer.h (_stmt_vec_info): Add min_output_precision,
17274 min_input_precision, operation_precision and operation_sign.
17275 * tree-vect-patterns.c (vect_get_range_info): New function.
17276 (vect_same_loop_or_bb_p, vect_single_imm_use)
17277 (vect_operation_fits_smaller_type): Delete.
17278 (vect_look_through_possible_promotion): Add an optional
17279 single_use_p parameter.
17280 (vect_recog_over_widening_pattern): Rewrite to use new
17281 stmt_vec_info infomration. Handle one operation at a time.
17282 (vect_recog_cast_forwprop_pattern, vect_narrowable_type_p)
17283 (vect_truncatable_operation_p, vect_set_operation_type)
17284 (vect_set_min_input_precision): New functions.
17285 (vect_determine_min_output_precision_1): Likewise.
17286 (vect_determine_min_output_precision): Likewise.
17287 (vect_determine_precisions_from_range): Likewise.
17288 (vect_determine_precisions_from_users): Likewise.
17289 (vect_determine_stmt_precisions, vect_determine_precisions): Likewise.
17290 (vect_vect_recog_func_ptrs): Put over_widening first.
17291 Add cast_forwprop.
17292 (vect_pattern_recog): Call vect_determine_precisions.
17293
17294 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
17295
17296 * tree-vect-patterns.c (vect_mark_pattern_stmts): Remove pattern
17297 statements that have been replaced by further pattern statements.
17298 (vect_pattern_recog_1): Clear STMT_VINFO_PATTERN_DEF_SEQ on failure.
17299
17300 2018-07-03 Richard Biener <rguenther@suse.de>
17301
17302 * tree-vect-stmts.c (vect_is_simple_use): Consolidate dumping,
17303 always set *dt. Dump vectype in vectype overload.
17304 * dumpfile.h (dump_gimple_expr): New function.
17305 (dump_gimple_expr_loc): Likewise.
17306 * dumpfile.c (dump_gimple_expr): New function.
17307 (dump_gimple_expr_loc): Likewise.
17308
17309 2018-07-02 Jeff Law <law@redhat.com>
17310
17311 * config/h8300/h8300.md (movqi_h8300, movqi_h8300hs): Consolidate
17312 the H8/300, H8/300H and H8/S variants into a single pattern.
17313 (movhi_h8300, movqi_h8300hs): Similarly.
17314 (pushqi_h8300hs, pushhi_h8300hs): Consolidate into a single pattern.
17315 (QHI mode iterator): New.
17316
17317 * config/h8300/h8300.md: Remove trailing whitespace.
17318
17319 2018-07-02 Jim Wilson <jimw@sifive.com>
17320
17321 * config/riscv/riscv.c (riscv_expand_epilogue): Use emit_jump_insn
17322 instead of emit_insn for interrupt returns.
17323 * config/riscv/riscv.md (riscv_met): Add (return) to rtl.
17324 (riscv_sret, riscv_uret): Likewise.
17325
17326 2018-07-02 David Malcolm <dmalcolm@redhat.com>
17327
17328 * pretty-print.c (selftest::test_pp_format): Move save and restore
17329 of quotes to class auto_fix_quotes, and add an instance.
17330 * selftest.c: Include "intl.h".
17331 (selftest::auto_fix_quotes::auto_fix_quotes): New ctor.
17332 (selftest::auto_fix_quotes::~auto_fix_quotes): New dtor.
17333 * selftest.h (selftest::auto_fix_quotes): New class.
17334
17335 2018-07-02 Richard Henderson <richard.henderson@linaro.org>
17336
17337 * config/aarch64/aarch64-protos.h, config/aarch64/aarch64.c
17338 (aarch64_sve_prepare_conditional_op): Remove.
17339 * config/aarch64/aarch64-sve.md (cond_<SVE_INT_BINARY><SVE_I>):
17340 Allow aarch64_simd_reg_or_zero as select operand; remove
17341 the aarch64_sve_prepare_conditional_op call.
17342 (cond_<SVE_INT_BINARY_SD><SVE_SDI>): Likewise.
17343 (cond_<SVE_COND_FP_BINARY><SVE_F>): Likewise.
17344 (*cond_<SVE_INT_BINARY><SVE_I>_z): New pattern.
17345 (*cond_<SVE_INT_BINARY_SD><SVE_SDI>_z): New pattern.
17346 (*cond_<SVE_COND_FP_BINARY><SVE_F>_z): New pattern.
17347 (*cond_<SVE_INT_BINARY><SVE_I>_any): New pattern.
17348 (*cond_<SVE_INT_BINARY_SD><SVE_SDI>_any): New pattern.
17349 (*cond_<SVE_COND_FP_BINARY><SVE_F>_any): New pattern
17350 and a splitters to match all of the *_any patterns.
17351 * config/aarch64/predicates.md (aarch64_sve_any_binary_operator): New.
17352
17353 * config/aarch64/iterators.md (SVE_INT_BINARY_REV): Remove.
17354 (SVE_COND_FP_BINARY_REV): Remove.
17355 (sve_int_op_rev, sve_fp_op_rev): New.
17356 * config/aarch64/aarch64-sve.md (*cond_<SVE_INT_BINARY><SVE_I>_0): New.
17357 (*cond_<SVE_INT_BINARY_SD><SVE_SDI>_0): New.
17358 (*cond_<SVE_COND_FP_BINARY><SVE_F>_0): New.
17359 (*cond_<SVE_INT_BINARY><SVE_I>_2): Rename, add movprfx alternative.
17360 (*cond_<SVE_INT_BINARY_SD><SVE_SDI>_2): Similarly.
17361 (*cond_<SVE_COND_FP_BINARY><SVE_F>_2): Similarly.
17362 (*cond_<SVE_INT_BINARY><SVE_I>_3): Similarly; use sve_int_op_rev.
17363 (*cond_<SVE_INT_BINARY_SD><SVE_SDI>_3): Similarly.
17364 (*cond_<SVE_COND_FP_BINARY><SVE_F>_3): Similarly; use sve_fp_op_rev.
17365
17366 * config/aarch64/aarch64-sve.md (cond_<SVE_COND_FP_BINARY><SVE_F>):
17367 Remove match_dup 1 from the inner unspec.
17368 (*cond_<SVE_COND_FP_BINARY><SVE_F>): Likewise.
17369
17370 * config/aarch64/aarch64.md (movprfx): New attr.
17371 (length): Default movprfx to 8.
17372 * config/aarch64/aarch64-sve.md (*mul<SVE_I>3): Add movprfx alt.
17373 (*madd<SVE_I>, *msub<SVE_I): Likewise.
17374 (*<su>mul<SVE_I>3_highpart): Likewise.
17375 (*<SVE_INT_BINARY_SD><SVE_SDI>3): Likewise.
17376 (*v<ASHIFT><SVE_I>3): Likewise.
17377 (*<su><MAXMIN><SVE_I>3): Likewise.
17378 (*<su><MAXMIN><SVE_F>3): Likewise.
17379 (*fma<SVE_F>4, *fnma<SVE_F>4): Likewise.
17380 (*fms<SVE_F>4, *fnms<SVE_F>4): Likewise.
17381 (*div<SVE_F>4): Likewise.
17382
17383 2018-07-02 Richard Sandiford <richard.sandiford@arm.com>
17384
17385 * tree-vect-patterns.c (vect_recog_widen_shift_pattern): Fix typo
17386 in dump string.
17387
17388 2018-07-02 Richard Biener <rguenther@suse.de>
17389
17390 PR tree-optimization/86363
17391 * tree-ssa-sccvn.c (vn_reference_lookup_3): Check the
17392 memset argument refers to a non-variable address.
17393
17394 2018-07-02 Aldy Hernandez <aldyh@redhat.com>
17395
17396 * tree-vrp.c (extract_range_from_binary_expr_1): Abstract a lot of the
17397 {PLUS,MINUS}_EXPR code to...
17398 (adjust_symbolic_bound): ...here,
17399 (combine_bound): ...here,
17400 (set_value_range_with_overflow): ...and here.
17401
17402 2018-07-02 Aldy Hernandez <aldyh@redhat.com>
17403
17404 * tree-vrp.c (extract_range_from_unary_expr): Abstract ABS_EXPR
17405 code...
17406 (extract_range_from_abs_expr): ...here.
17407
17408 2018-07-02 Eric Botcazou <ebotcazou@adacore.com>
17409
17410 * config/i386/i386.c (ix86_finalize_stack_frame_flags): Do not overrule
17411 -fno-omit-frame-pointer when not optimizing.
17412
17413 2018-07-02 Martin Liska <mliska@suse.cz>
17414
17415 PR ipa/86279
17416 * ipa-pure-const.c (malloc_candidate_p): Revert usage of ::get.
17417 (propagate_nothrow): Likewise.
17418
17419 2018-07-02 Martin Liska <mliska@suse.cz>
17420
17421 PR ipa/86323
17422 * ipa-inline.c (early_inliner): Revert wrongly added ::get call.
17423
17424 2018-07-02 David Malcolm <dmalcolm@redhat.com>
17425
17426 * dumpfile.c (dump_generic_expr_loc): Undo removal of this
17427 function in r262149, changing "loc" param from source_location to
17428 const dump_location_t &.
17429 * dumpfile.h (dump_generic_expr_loc): Undo removal of this
17430 declaration, as above.
17431
17432 2018-07-01 Paul Koning <ni1d@arrl.net>
17433
17434 * common/config/pdp11/pdp11-common.c (pdp11_handle_option): Handle
17435 -munit-asm, -mgnu-asm, -mdec-asm.
17436 * config/pdp11/pdp11-protos.h (pdp11_gen_int_label): New.
17437 (pdp11_output_labelref): New.
17438 (pdp11_output_def): New.
17439 (pdp11_output_addr_vec_elt): New.
17440 * config/pdp11/pdp11.c: Use tab between opcode and operands. Use
17441 %# and %@ format codes.
17442 (pdp11_option_override): New.
17443 (TARGET_ASM_FILE_START_FILE_DIRECTIVE): Define.
17444 (pdp11_output_ident): New.
17445 (pdp11_asm_named_section): New.
17446 (pdp11_asm_init_sections): New.
17447 (pdp11_file_start): New.
17448 (pdp11_file_end): New.
17449 (output_ascii): Use .ascii/.asciz for -mdec-asm.
17450 (pdp11_asm_print_operand): Update %# and %$ for -mdec-asm. Add
17451 %o, like %c but octal.
17452 (pdp11_option_override): New.
17453 * config/pdp11/pdp11.h (TEXT_SECTION_ASM_OP): Update for
17454 -mdec-asm.
17455 (DATA_SECTION_ASM_OP): Ditto.
17456 (READONLY_DATA_SECTION_ASM_OP): New.
17457 (IS_ASM_LOGICAL_LINE_SEPARATOR): New.
17458 (ASM_GENERATE_INTERNAL_LABEL): Use new function.
17459 (ASM_OUTPUT_LABELREF): Ditto.
17460 (ASM_OUTPUT_DEF): Ditto.
17461 (ASM_OUTPUT_EXTERNAL): New.
17462 (ASM_OUTPUT_SOURCE_FILENAME): New.
17463 (ASM_OUTPUT_ADDR_VEC_ELT): Use new function.
17464 (ASM_OUTPUT_SKIP): Update for -mdec-asm.
17465 * config/pdp11/pdp11.md: Use tab between opcode and operands. Use
17466 %# and %@ format codes.
17467 * config/pdp11/pdp11.opt (mgnu-asm): New.
17468 (mdec-asm): Conflicts with -mgnu-asm and -munix-asm.
17469 (munix-asm): Conflicts with -mdec-asm and -mgnu-asm.
17470 * doc/invoke.txt (PDP-11 Options): Add -mgnu-asm.
17471
17472 2018-07-01 Aldy Hernandez <aldyh@redhat.com>
17473
17474 * tree-ssa-threadupdate.c (mark_threaded_blocks): Avoid
17475 dereferencing path[] beyond its length.
17476 (debug_path): New.
17477 (debug_all_paths): New.
17478 (rewire_first_differing_edge): New.
17479 (adjust_paths_after_duplication): New.
17480 (duplicate_thread_path): Call adjust_paths_after_duplication.
17481 Add new argument.
17482 (thread_through_all_blocks): Add new argument to
17483 duplicate_thread_path.
17484
17485 2018-06-30 Jim Wilson <jimw@sifive.com>
17486
17487 * config/riscv/predicates.md (p2m1_shift_operand): New.
17488 (high_mask_shift_operand): New.
17489 * config/riscv/riscv.md (lshrsi3_zero_extend_3+1): New combiner
17490 pattern using p2m1_shift_operand.
17491 (lshsi3_zero_extend_3+2): New combiner pattern using
17492 high_mask_shift_operand.
17493
17494 2018-06-30 Richard Sandiford <richard.sandiford@arm.com>
17495
17496 * tree-vect-patterns.c (vect_get_external_def_edge): New function,
17497 split out from...
17498 (vect_recog_rotate_pattern): ...here.
17499 (vect_convert_input): Try to insert casts of invariants in the
17500 preheader.
17501 * tree-vect-loop-manip.c (vect_loop_versioning): Don't require the
17502 preheader to be empty.
17503
17504 2018-06-30 Richard Sandiford <richard.sandiford@arm.com>
17505
17506 * tree-vect-patterns.c (append_pattern_def_seq): Take an optional
17507 vector type. If given, install it in the new statement's
17508 STMT_VINFO_VECTYPE.
17509 (vect_element_precision): New function.
17510 (vect_unpromoted_value): New struct.
17511 (vect_unpromoted_value::vect_unpromoted_value): New function.
17512 (vect_unpromoted_value::set_op): Likewise.
17513 (vect_look_through_possible_promotion): Likewise.
17514 (vect_joust_widened_integer, vect_joust_widened_type): Likewise.
17515 (vect_widened_op_tree, vect_convert_input): Likewise.
17516 (vect_convert_inputs, vect_convert_output): Likewise.
17517 (vect_recog_dot_prod_pattern): Use vect_look_through_possible_promotion
17518 to handle the optional cast of the multiplication result and
17519 vect_widened_op_tree to detect the widened multiplication itself.
17520 Do not require the input and output of promotion casts to have
17521 the same sign, but base the signedness of the operation on the
17522 input rather than the result. If the pattern includes two
17523 promotions, check that those promotions have the same sign.
17524 Do not restrict the MULT_EXPR handling to a double-width result;
17525 handle quadruple-width results and wider. Use vect_convert_inputs
17526 to convert the inputs to the common type.
17527 (vect_recog_sad_pattern): Use vect_look_through_possible_promotion
17528 to handle the optional cast of the ABS result. Also allow a sign
17529 change or a sign extension between the ABS and MINUS.
17530 Use vect_widened_op_tree to detect the widened subtraction and use
17531 vect_convert_inputs to convert the inputs to the common type.
17532 (vect_handle_widen_op_by_const): Delete.
17533 (vect_recog_widen_op_pattern): New function.
17534 (vect_recog_widen_mult_pattern): Use it.
17535 (vect_recog_widen_shift_pattern): Likewise.
17536 (vect_recog_widen_sum_pattern): Use
17537 vect_look_through_possible_promotion to handle the promoted
17538 PLUS_EXPR operand.
17539
17540 2018-06-30 Richard Sandiford <richard.sandiford@arm.com>
17541
17542 * gimple-iterator.c (gsi_for_stmt): Add a new overload that takes
17543 the containing gimple_seq *.
17544 * gimple-iterator.h (gsi_for_stmt): Declare it.
17545 * tree-vect-patterns.c (vect_recog_dot_prod_pattern)
17546 (vect_recog_sad_pattern, vect_recog_widen_sum_pattern)
17547 (vect_recog_widen_shift_pattern, vect_recog_rotate_pattern)
17548 (vect_recog_vector_vector_shift_pattern, vect_recog_divmod_pattern)
17549 (vect_recog_mask_conversion_pattern): Remove STMT_VINFO_IN_PATTERN_P
17550 checks.
17551 (vect_init_pattern_stmt, vect_set_pattern_stmt): New functions,
17552 split out from...
17553 (vect_mark_pattern_stmts): ...here. Handle cases in which the
17554 statement being replaced is part of an existing pattern
17555 definition sequence, inserting the new pattern statements before
17556 the original one.
17557 (vect_pattern_recog_1): Don't return a bool. If the statement
17558 is already part of a pattern, instead apply pattern matching
17559 to the pattern definition statements. Don't clear the
17560 STMT_VINFO_RELATED_STMT if is_pattern_stmt_p.
17561 (vect_pattern_recog): Don't break after the first match;
17562 continue processing the pattern definition statements instead.
17563 Don't bail out for STMT_VINFO_IN_PATTERN_P here.
17564
17565 2018-06-30 Richard Sandiford <richard.sandiford@arm.com>
17566
17567 * tree-vect-patterns.c (vect_reassociating_reduction_p): New function.
17568 (vect_recog_dot_prod_pattern, vect_recog_sad_pattern)
17569 (vect_recog_widen_sum_pattern): Use it.
17570
17571 2018-06-30 Richard Sandiford <richard.sandiford@arm.com>
17572
17573 * tree-vect-loop.c (vectorizable_reduction): Assert that the
17574 phi is not a pattern statement and has not been replaced by
17575 a pattern statement.
17576 * tree-vect-patterns.c (type_conversion_p): Don't check
17577 STMT_VINFO_IN_PATTERN_P.
17578 (vect_recog_vector_vector_shift_pattern): Likewise.
17579 (vect_recog_dot_prod_pattern): Expect vect_is_simple_use to return
17580 the pattern statement rather than the original statement; check
17581 directly for a WIDEN_MULT_EXPR here.
17582 * tree-vect-slp.c (vect_get_and_check_slp_defs): Expect
17583 vect_is_simple_use to return the pattern statement rather
17584 than the original statement; use is_pattern_stmt_p to check
17585 for such a pattern statement.
17586 * tree-vect-stmts.c (process_use): Expect vect_is_simple_use
17587 to return the pattern statement rather than the original statement;
17588 don't do the same transformation here.
17589 (vect_is_simple_use): If the defining statement has been replaced
17590 by a pattern statement, return the pattern statement instead.
17591 Remove the corresponding (local) transformation from the vectype
17592 overload.
17593
17594 2018-06-30 Richard Sandiford <richard.sandiford@arm.com>
17595
17596 * tree-vectorizer.h (vect_is_simple_use): Move the gimple ** to the
17597 end and default to null.
17598 * tree-vect-loop.c (vect_create_epilog_for_reduction)
17599 (vectorizable_reduction): Update calls accordingly, dropping the
17600 gimple ** argument if the passed-back statement isn't needed.
17601 * tree-vect-patterns.c (vect_get_internal_def, type_conversion_p)
17602 (vect_recog_rotate_pattern): Likewise.
17603 (vect_recog_mask_conversion_pattern): Likewise.
17604 * tree-vect-slp.c (vect_get_and_check_slp_defs): Likewise.
17605 (vect_mask_constant_operand_p): Likewise.
17606 * tree-vect-stmts.c (is_simple_and_all_uses_invariant, process_use):
17607 (vect_model_simple_cost, vect_get_vec_def_for_operand): Likewise.
17608 (get_group_load_store_type, get_load_store_type): Likewise.
17609 (vect_check_load_store_mask, vect_check_store_rhs): Likewise.
17610 (vectorizable_call, vectorizable_simd_clone_call): Likewise.
17611 (vectorizable_conversion, vectorizable_assignment): Likewise.
17612 (vectorizable_shift, vectorizable_operation): Likewise.
17613 (vectorizable_store, vect_is_simple_cond): Likewise.
17614 (vectorizable_condition, vectorizable_comparison): Likewise.
17615 (get_same_sized_vectype, vect_get_mask_type_for_stmt): Likewise.
17616 (vect_is_simple_use): Rename the def_stmt argument to def_stmt_out
17617 and move it to the end. Cope with null def_stmt_outs.
17618
17619 2018-06-30 Bernd Edlinger <bernd.edlinger@hotmail.de>
17620
17621 * Makefile.in (FLAGS_TO_PASS): Add RANLIB_FOR_TARGET.
17622
17623 2018-06-29 Jeff Law <law@redhat.com>
17624
17625 * config/v850/v850.c (v850_legitimate_address_p): Handle large
17626 displacements for TARGET_V850E2V3 and newer.
17627 (TARGET_LRA_P): Remove. Defaults to LRA now.
17628 * config/v850/v850.md (sign23byte_load): Remove.
17629 (unsign23byte_load, sign23hword_load, unsign23hword_load): Likewise.
17630 (23word_load, 23byte_store, 23hword_store, 23word_store): Likewise.
17631
17632 2018-06-29 Martin Liska <mliska@suse.cz>
17633
17634 PR lto/85759
17635 * coverage.c (coverage_init): Mangle full path name.
17636 * doc/invoke.texi: Document the change.
17637 * gcov-io.c (mangle_path): New.
17638 * gcov-io.h (mangle_path): Likewise.
17639 * gcov.c (mangle_name): Use mangle_path for path mangling.
17640
17641 2018-06-29 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
17642
17643 * config/arm/arm.c (output_move_double): Don't allow STRD instructions
17644 if starting source register is not even.
17645
17646 2018-06-29 Martin Liska <mliska@suse.cz>
17647
17648 PR tree-optimization/86263
17649 * tree-switch-conversion.c (switch_decision_tree::try_switch_expansion):
17650 Make edge redirection.
17651
17652 2018-06-29 David Malcolm <dmalcolm@redhat.com>
17653
17654 * dumpfile.c (dump_loc): Add indentation based on scope depth.
17655 (dump_scope_depth): New variable.
17656 (get_dump_scope_depth): New function.
17657 (dump_begin_scope): New function.
17658 (dump_end_scope): New function.
17659 * dumpfile.h (get_dump_scope_depth): New declaration.
17660 (dump_begin_scope): New declaration.
17661 (dump_end_scope): New declaration.
17662 (class auto_dump_scope): New class.
17663 (AUTO_DUMP_SCOPE): New macro.
17664 * tree-vectorizer.h (DUMP_VECT_SCOPE): Reimplement in terms of
17665 AUTO_DUMP_SCOPE.
17666
17667 2018-06-29 Richard Biener <rguenther@suse.de>
17668
17669 * tree-vect-data-refs.c (vect_analyze_data_ref_dependences): Assert
17670 compute_all_dependences succeeds.
17671 * tree-vect-loop.c (vect_get_datarefs_in_loop): Fail early if we
17672 exceed --param loop-max-datarefs-for-datadeps.
17673
17674 2018-06-29 Jakub Jelinek <jakub@redhat.com>
17675
17676 * config/rs6000/t-rs6000: Append rs6000-modes.h to TM_H.
17677
17678 2018-06-28 Uros Bizjak <ubizjak@gmail.com>
17679
17680 PR target/86348
17681 * config/i386/sse.md (*vec_extractv4si_0_zext_sse4): Use
17682 alternative 0 in preferred_for_speed attribute.
17683
17684 2018-06-28 Paul Koning <ni1d@arrl.net>
17685
17686 * config/pdp11/pdp11-protos.h (pdp11_shift_length): New function.
17687 * config/pdp11/pdp11.c (pdp11_shift_length): New function.
17688 * config/pdp11/pdp11.h (ADJUST_INSN_LENGTH): Remove.
17689 * config/pdp11/pdp11.md: Correct "length" attribute calculation
17690 for shift insn patterns.
17691
17692 2018-06-28 David Malcolm <dmalcolm@redhat.com>
17693
17694 * cgraph.c (cgraph_node::get_body): Replace assignments to
17695 "dump_file" with calls to set_dump_file.
17696 * dumpfile.c (alt_dump_file): Make static, and group with...
17697 (alt_flags): ...this definition.
17698 (dumps_are_enabled): New variable.
17699 (refresh_dumps_are_enabled): New function.
17700 (set_dump_file): New function.
17701 (set_alt_dump_file): New function.
17702 (gcc::dump_manager::dump_start): Replace assignments to
17703 "dump_file" and "alt_dump_file" with calls to set_dump_file and
17704 set_alt_dump_file.
17705 (gcc::dump_manager::dump_finish): Likewise.
17706 * dumpfile.h (alt_dump_file): Delete decl.
17707 (dumps_are_enabled): New variable decl.
17708 (set_dump_file): New function decl.
17709 (dump_enabled_p): Rewrite in terms of new "dumps_are_enabled"
17710 global.
17711 * tree-nested.c (lower_nested_functions): Replace assignments to
17712 "dump_file" with calls to set_dump_file.
17713
17714 2018-06-28 Eric Botcazou <ebotcazou@adacore.com>
17715
17716 * tree-cfg.c (verify_gimple_in_cfg): Call verify_location on the
17717 goto_locus of each outgoing edge of each basic block.
17718
17719 2018-06-28 Richard Biener <rguenther@suse.de>
17720
17721 * dwarf2out.c (decl_scope_table): Remove.
17722 (push_decl_scope): Likewise.
17723 (pop_decl_scope): Likewise.
17724 (gen_type_die_for_member): Do not call push/pop_decl_scope.
17725 (gen_struct_or_union_type_die): Likewise.
17726 (gen_tagged_type_die): Likewise.
17727 (dwarf2out_init): Do not initialize decl_scope_table.
17728 (dwarf2out_c_finalize): Do not free it.
17729
17730 2018-06-28 Richard Biener <rguenther@suse.de>
17731
17732 * dwarf2out.c (gen_subprogram_die): Use is_unit_die when
17733 deciding whether to not re-use a DIE.
17734
17735 2018-06-28 Richard Biener <rguenther@suse.de>
17736
17737 * dwarf2out.c (gen_subprogram_die): Always re-use DIEs with an
17738 DW_AT_abstract_origin attribute.
17739
17740 2018-06-28 Martin Liska <mliska@suse.cz>
17741
17742 * tree-switch-conversion.c (jump_table_cluster::can_be_handled):
17743 Use newly introduced constants.
17744 * tree-switch-conversion.h (struct jump_table_cluster):
17745 Define max_ratio_for_size and max_ratio_for_speed.
17746
17747 2018-06-28 Martin Liska <mliska@suse.cz>
17748
17749 * tree-switch-conversion.c (jump_table_cluster::find_jump_tables):
17750 Add new checking assert to catch invalid state.
17751 (jump_table_cluster::can_be_handled): Handle single case
17752 clusters.
17753 (jump_table_cluster::is_beneficial): Bail out for such case.
17754 (bit_test_cluster::find_bit_tests):
17755 Add new checking assert to catch invalid state.
17756 (bit_test_cluster::can_be_handled): Handle single case
17757 clusters.
17758 (bit_test_cluster::is_beneficial): Bail out for such case.
17759 (switch_decision_tree::analyze_switch_statement):
17760 Fix comment.
17761
17762 2018-06-28 Martin Liska <mliska@suse.cz>
17763
17764 * common.opt: Introduce -completion option.
17765 * gcc.c (driver_handle_option): Handle it.
17766 (driver::main): Print completions if completion
17767 is set.
17768 * opt-suggestions.c (option_proposer::get_completions):
17769 New function.
17770 (option_proposer::suggest_completion): Likewise.
17771 (option_proposer::find_param_completions): Likewise.
17772 (verify_autocompletions): Likewise.
17773 (test_completion_valid_options): Likewise.
17774 (test_completion_valid_params): Likewise.
17775 (in_completion_p): Likewise.
17776 (empty_completion_p): Likewise.
17777 (test_completion_partial_match): Likewise.
17778 (test_completion_garbage): Likewise.
17779 (opt_proposer_c_tests): Likewise.
17780 * opt-suggestions.h: Declare new functions.
17781 * opts.c (common_handle_option): Handle OPT__completion_.
17782 * selftest-run-tests.c (selftest::run_tests): Add
17783 opt_proposer_c_tests.
17784 * selftest.c (assert_str_startswith): New.
17785 * selftest.h (assert_str_startswith): Likewise.
17786 (opt_proposer_c_tests): New.
17787 (ASSERT_STR_STARTSWITH): Likewise.
17788
17789 2018-06-28 Martin Liska <mliska@suse.cz>
17790
17791 * Makefile.in: Add opt-suggestions.o.
17792 * gcc-main.c: Include opt-suggestions.h.
17793 * gcc.c (driver::driver): Likewise.
17794 (driver::~driver): Remove m_option_suggestions.
17795 (driver::build_option_suggestions): Moved to option_proposer.
17796 (driver::suggest_option): Likewise.
17797 (driver::handle_unrecognized_options): Use option_proposer.
17798 * gcc.h (class driver): Add new memver m_option_proposer.
17799 * opt-suggestions.c: New file.
17800 * opt-suggestions.h: New file.
17801
17802 2018-06-28 Martin Liska <mliska@suse.cz>
17803
17804 * vec.h (class auto_string_vec): New (moved from auto_argvec).
17805 (auto_string_vec::~auto_string_vec): Likewise.
17806
17807 2018-06-28 Eric Botcazou <ebotcazou@adacore.com>
17808
17809 * tree-inline.h (struct copy_body_data): Move remapping_type_depth and
17810 prevent_decl_creation_for_types fields up and add reset_location field.
17811 * tree-inline.c (remap_gimple_stmt): Force input_location on the new
17812 statement if id->reset_location is true.
17813 (copy_edges_for_bb): Do not set goto_locus on the new edges if
17814 id->reset_location is true.
17815 (copy_phis_for_bb): Force input_location on the arguments if
17816 id->reset_location is true.
17817 (expand_call_inline): Set id->reset_location if DECL_IGNORED_P
17818 is set on the function to be inlined.
17819
17820 2018-06-27 Stephan Bergmann <sbergman@redhat.com>
17821
17822 * doc/invoke.texi (Debugging Options): Add -gsplit-dwarf.
17823
17824 2018-06-27 Dimitar Dimitrov <dimitar@dinux.eu>
17825
17826 * lra-eliminations.c (update_reg_eliminate): Mark all spanning hard
17827 registers for Pmode.
17828 * lra-lives.c (check_pseudos_live_through_calls): Mark all spanning
17829 hard registers for the clobbered pseudo.
17830
17831 2018-06-27 Paul Koning <ni1d@arrl.net>
17832
17833 * common/config/pdp11/pdp11-common.c (pdp11_handle_option): Handle
17834 mutually exclusive options.
17835 * config/pdp11/constraints.md (h): New constraint.
17836 (O): Update definition to match shift code generation.
17837 (D): New constraint.
17838 * config/pdp11/pdp11-modes.def (CCNZ): Define mode.
17839 (CCFP): Remove.
17840 * config/pdp11/pdp11-protos.h (int_no_side_effect_operand): New
17841 function.
17842 (output_jump): Change arguments.
17843 (pdp11_fixed_cc_regs): New function.
17844 (pdp11_cc_mode): Ditto.
17845 (pdp11_expand_shift): Ditto.
17846 (pdp11_assemble_shift): Ditto.
17847 (pdp11_small_shift): Ditto.
17848 (pdp11_branch_cost): Remove.
17849 * config/pdp11/pdp11.c (pdp11_assemble_integer): Remove comments
17850 from output.
17851 (pdp11_register_move_cost): Update for CC registers.
17852 (pdp11_rtx_costs): Add case for LSHIFTRT.
17853 (pdp11_output_jump): Add CCNZ mode conditional branches.
17854 (notice_update_cc_on_set): Remove.
17855 (pdp11_cc_mode): New function.
17856 (simple_memory_operand): Correct pre/post decrement case.
17857 (no_side_effect_operand): New function.
17858 (pdp11_regno_reg_class): Add CC_REGS class.
17859 (pdp11_fixed_cc_regs): New function.
17860 (pdp11_small_shift): New function.
17861 (pdp11_expand_shift): New function to expand shift insns.
17862 (pdp11_assemble_shift): New function to output shifts.
17863 (pdp11_branch_cost): Remove.
17864 (pdp11_modes_tieable_p): Make QI/HI modes tieable.
17865 * config/pdp11/pdp11.h (SIZE_TYPE): Ensure 16-bit type.
17866 (WCHAR_TYPE): Ditto.
17867 (PTRDIFF_TYPE): Ditto.
17868 (ADJUST_INSN_LENGTH): New macro.
17869 (FIXED_REGISTERS): Add CC registers.
17870 (CALL_USED_REGISTERS): Ditto.
17871 (reg_class): Ditto.
17872 (REG_CLASS_NAMES): Ditto.
17873 (REG_CLASS_CONTENTS): Ditto.
17874 (SELECT_CC_MODE): Use new function.
17875 (TARGET_FLAGS_REGNUM): New macro.
17876 (TARGET_FIXED_CONDITION_CODE_REGS): Ditto.
17877 (cc0_reg_rtx): Remove.
17878 (CC_STATUS_MDEP): Remove.
17879 (CC_STATUS_MDEFP_INIT): Remove.
17880 (CC_IN_FPU): Remove.
17881 (NOTICE_UPDATE_CC): Remove.
17882 (REGISTER_NAMES): Add CC registers.
17883 (BRANCH_COST): Change to constant 1.
17884 * config/pdp11/pdp11.md: Rewrite for CCmode condition code
17885 handling.
17886 * config/pdp11/pdp11.opt (mbcopy): Remove.
17887 (mbcopy-builtin): Remove.
17888 (mbranch-cheap): Remove.
17889 (mbranch-expensive): Remove.
17890 * config/pdp11/predicates.md (expand_shift_operand): Update to
17891 match shift code generation.
17892 (ccnz_operator): New predicate.
17893 * doc/invoke.texi (PDP-11 Options): Remove deleted options
17894 -mbcopy, -mbcopy-builtin, -mbranch-cheap, -mbranch-expensive.
17895 Remove non-existent option -mabshi, -mno-abshi. Document mutually
17896 exclusive options.
17897 * doc/md.texi (PDP-11): Document new D and h constraints. Update
17898 description of O constraint.
17899
17900 2018-06-27 Jeff Law <law@redhat.com>
17901 Austin Law <austinklaw@gmail.com>
17902
17903 * config/v850/v850.md (addsi3_set_flags): New pattern.
17904 (subsi3_set_flags, negsi2_set_flags, andsi3_set_flags): Likewise.
17905 (iorsi3_set_flags, xorsi3_set_flags, one_cmplsi2_set_flags): Likewise.
17906 (zero_extendhisi2_v850_set_flags): Likewise.
17907 (zero_extendqisi2_v850_set_flags): Likewise.
17908 (ashlsi3_set_flags, ashlsi3_v850e2_set_flags): Likewise.
17909 (lshrsi3_set_flags, lshrsi3_v850e2_set_flags): Likewise.
17910 (ashrsi3_set_flags, ashrsi3_v850e2_set_flags): Likewise.
17911
17912 * config/v850/v850-protos.h (notice_update_cc): Remove.
17913 * config/v850/v850.c (v850_compare_op0, v850_compare_op1): Remove.
17914 (v850_print_operand): Handle 'D' and "d".
17915 (v850_select_cc_mode): Remove ATTRIBUTE_UNUSED for last argument.
17916 Add handling of arithmetic/logical operations compared against zero.
17917 (v850_gen_float_compare): Remove ATTRIBUTE_UNUSED for last argument.
17918 Do not look at v850_compare_op, instead get mode from last argument.
17919 (v850_gen_compare): Remove
17920 (increment_stack): Use addsi3_clobber_flags to avoid splitting failure
17921 after reload for prologue insns.
17922 (expand_prologue): Account for CLOBBER of CC_REGNUM in various
17923 patterns.
17924 (construct_save_jarl): Likewise.
17925 (TARGET_FLAGS_REGNUM): Define.
17926 * config/v850/v850.h (v850_compare_op0, v850_compare_op1): Remove.
17927 (NOTICE_UPDATE_CC): Remove.
17928 * config/v850/v850.md (v850_tst1): Use (reg:CCZ CC_REGNUM) rather
17929 than cc0. Conditionalize on reload_completed.
17930 (cmpsi_insn, setfcc_insn): Likewise.
17931 (tst1 splitter): Turn into define_and_split which sets the flags
17932 after reload.
17933 (cstoresi4, cbranchsf4, cbranchdf4, cbranchsi4_insn): Likewise.
17934 (cbranchsi4, branch_normal, branch_invert): Do not expose cc0 here.
17935 (cstoresf4, cstoredf4): Clobber the flags.
17936 (cmpsi, cmpsf, cmpdf): Remove expanders.
17937 (setf_insn): Remove pattern.
17938 (addsi3): Turn into define_and_split which clobbers the flags after
17939 reload and a suitable pattern (addsi3_clobber_flags) for use after
17940 reload.
17941 (subsi3, negsi2, andsi3, iorsi3, xorsi3, one_cmplsi2) Likewise.
17942 (ashlsi3, ashlsi3_v850e2, lshrsi3, lsh4si3_v850e2): Likewise.
17943 (ashrsi3, ashrsi3_v850e2): Likewise.
17944 (bins): Clobber the flags.
17945 (movsicc_normal_cc, movsicc_normal, movsicc_tst1): Likewise.
17946 (movsicc_tst1_revesed, sasf, swap and rotate patterns): Likewise.
17947 (fix_loop_counter, call_internal_short, call_internal_long): Likewise.
17948 (call_value_internal_short, call_value_internal_long): Likewise.
17949 (callt_save_interrupt, callt_return_interrupt): Likewise.
17950 (save_interrupt, return_interrupt): Likewise.
17951 (callt_save_all_interrupt, save_all_interrupt): Likewise.
17952 (_save_all_interrupt, callt_restore_all_interrupt): Likewise.
17953 (restore_all_interrupt, _restore_all_interrupt): Likewise.
17954 (All FP comparisons): Only allow after reload has completed.
17955 (trfsr): Likewise.
17956 (divh, divhu): Tweak output template.
17957 (branch_z_normal, branch_z_invert): Remove
17958 (branch_nz_normal, branch_nz_invert): Likewise.
17959 (extendhisi_insn, extendqisi_insn): Do not clobber flags.
17960
17961 * config/v850/v850-modes.def (CCZ, CCNZ): Add new modes.
17962 * config/v850/v850.c (notice_update_cc): Remove.
17963 * config/v850/v850.h (CC_OVERFLOW_UNUSABLE): Remove
17964 (CC_NO_CARRY): Likewise.
17965 (NOTICE_UPDATE_CC): Define to nothing.
17966 * config/v850/v850.md: Remove block comment on cc0 handling
17967 Remove "cc" attribute from all patterns. Remove cc_status handling
17968 from all patterns. Minor formatting fixes.
17969
17970 2018-06-27 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
17971
17972 * config/aarch64/aarch64-cores.def (cortex-a76): New entry.
17973 (cortex-a76.cortex-a55): Likewise.
17974 * config/aarch64/aarch64-tune.md: Regenerate.
17975 * doc/invoke.texi (AArch64 Options): Document cortex-a76 and
17976 cortex-a76.cortex-a55.
17977
17978 2018-06-27 Jeff Law <law@redhat.com>
17979
17980 * config/v850/t-v850 (MULTILIB_OPTIONS): Remove 8byte-align.
17981 (MULTILIB_DIRNAMES): Similarly.
17982
17983 2018-06-27 Eric Botcazou <ebotcazou@adacore.com>
17984
17985 * gimple.h (gimple_return_retbnd): Delete.
17986 (gimple_return_set_retbnd): Likewise.
17987 * cgraphunit.c (cgraph_node::expand_thunk): Remove call to
17988 gimple_return_set_retbnd.
17989 * gimple-pretty-print.c (dump_gimple_return): Remove call to
17990 gimple_return_retbnd and adjust.
17991 * tree-inline.h (struct copy_body_data): Remove retbnd field.
17992 * tree-inline.c (remap_gimple_stmt): Remove handling of retbnd.
17993 Explicitly return NULL in a couple more cases. Move assertion
17994 on debug statements and remove unreachable code.
17995 (reset_debug_binding): Do not test id->retbnd.
17996 (expand_call_inline): Do not set it.
17997
17998 2018-06-27 Rasmus Villemoes <rv@rasmusvillemoes.dk>
17999
18000 * configure.ac: Add --disable-gcov option.
18001 * configure: Regenerate.
18002 * Makefile.in: Honour @enable_gcov@.
18003 * doc/install.texi: Document --disable-gcov.
18004
18005 2018-06-27 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
18006
18007 * config/arm/arm-cpus.in (cortex-a76): New entry.
18008 (cortex-a76.cortex-a55): Likewise.
18009 * config/arm/arm-tables.opt: Regenerate.
18010 * config/arm/arm-tune.md: Likewise.
18011 * config/arm/driver-arm.c (arm_cpu_table): Add Cortex-A76 entry.
18012 * doc/invoke.texi (ARM Options): Document cortex-a76 and
18013 cortex-a76.cortex-a55.
18014
18015 2018-06-27 Tamar Christina <tamar.christina@arm.com>
18016
18017 PR target/85769
18018 * config/aarch64/aarch64.md (*movhf_aarch64): Add dup v0.4h pattern.
18019
18020 2018-06-27 Siddhesh Poyarekar <siddhesh@sourceware.org>
18021
18022 * config/aarch64/aarch64.h (CALL_USE_REGISTERS): Fix obsolete
18023 comment.
18024 (EPILOGUE_USES): Likewise.
18025
18026 2018-06-26 Eric Botcazou <ebotcazou@adacore.com>
18027
18028 * tree-inline.c (remap_location): New function extracted from...
18029 (copy_edges_for_bb): Add ID parameter. Remap goto_locus.
18030 (copy_phis_for_bb): ...here. Call remap_location.
18031 (copy_cfg_body): Adjust call to copy_edges_for_bb.
18032
18033 2018-06-26 Aaron Sawdey <acsawdey@linux.ibm.com>
18034
18035 * config/rs6000/rs6000-string.c (expand_block_clear): Don't use
18036 unaligned vsx for 16B memset.
18037
18038 2018-06-26 Segher Boessenkool <segher@kernel.crashing.org>
18039
18040 PR target/86285
18041 * config/rs6000/rs6000.c (rs6000_init_builtins): Do not set
18042 ieee128_float_type_node to long_double_type_node unless
18043 TARGET_LONG_DOUBLE_128 is set.
18044
18045 2018-06-26 David Malcolm <dmalcolm@redhat.com>
18046
18047 * cfgloop.c (get_loop_location): Convert return type from
18048 location_t to dump_user_location_t, replacing INSN_LOCATION lookups
18049 by implicit construction from rtx_insn *, and using
18050 dump_user_location_t::from_function_decl for the fallback case.
18051 * cfgloop.h (get_loop_location): Convert return type from
18052 location_t to dump_user_location_t.
18053 * cgraphunit.c (walk_polymorphic_call_targets): Update call to
18054 dump_printf_loc to pass in a dump_location_t rather than a
18055 location_t, via the gimple stmt.
18056 * coverage.c (get_coverage_counts): Update calls to
18057 dump_printf_loc to pass in dump_location_t rather than a
18058 location_t.
18059 * doc/optinfo.texi (Dump types): Convert example of
18060 dump_printf_loc from taking "locus" to taking "insn". Update
18061 description of the "_loc" calls to cover dump_location_t.
18062 * dumpfile.c: Include "backend.h", "gimple.h", "rtl.h", and
18063 "selftest.h".
18064 (dump_user_location_t::dump_user_location_t): New constructors,
18065 from gimple *stmt and rtx_insn *.
18066 (dump_user_location_t::from_function_decl): New function.
18067 (dump_loc): Make static.
18068 (dump_gimple_stmt_loc): Convert param "loc" from location_t to
18069 const dump_location_t &.
18070 (dump_generic_expr_loc): Delete.
18071 (dump_printf_loc): Convert param "loc" from location_t to
18072 const dump_location_t &.
18073 (selftest::test_impl_location): New function.
18074 (selftest::dumpfile_c_tests): New function.
18075 * dumpfile.h: Include "profile-count.h".
18076 (class dump_user_location_t): New class.
18077 (struct dump_impl_location_t): New struct.
18078 (class dump_location_t): New class.
18079 (dump_printf_loc): Convert 2nd param from source_location to
18080 const dump_location_t &.
18081 (dump_generic_expr_loc): Delete.
18082 (dump_gimple_stmt_loc): Convert 2nd param from source_location to
18083 const dump_location_t &.
18084 * gimple-fold.c (fold_gimple_assign): Update call to
18085 dump_printf_loc to pass in a dump_location_t rather than a
18086 location_t, via the gimple stmt.
18087 (gimple_fold_call): Likewise.
18088 * gimple-loop-interchange.cc
18089 (loop_cand::analyze_iloop_reduction_var): Update for change to
18090 check_reduction_path.
18091 (tree_loop_interchange::interchange): Update for change to
18092 find_loop_location.
18093 * graphite-isl-ast-to-gimple.c (scop_to_isl_ast): Update for
18094 change in return-type of find_loop_location.
18095 (graphite_regenerate_ast_isl): Likewise.
18096 * graphite-optimize-isl.c (optimize_isl): Likewise.
18097 * graphite.c (graphite_transform_loops): Likewise.
18098 * ipa-devirt.c (ipa_devirt): Update call to dump_printf_loc to
18099 pass in a dump_location_t rather than a location_t, via the
18100 gimple stmt.
18101 * ipa-prop.c (ipa_make_edge_direct_to_target): Likewise.
18102 * ipa.c (walk_polymorphic_call_targets): Likewise.
18103 * loop-unroll.c (report_unroll): Convert "locus" param from
18104 location_t to dump_location_t.
18105 (decide_unrolling): Update for change to get_loop_location's
18106 return type.
18107 * omp-grid.c (struct grid_prop): Convert field "target_loc" from
18108 location_t to dump_user_location_t.
18109 (grid_find_single_omp_among_assignments_1): Updates calls to
18110 dump_printf_loc to pass in a dump_location_t rather than a
18111 location_t, via the gimple stmt.
18112 (grid_parallel_clauses_gridifiable): Convert "tloc" from
18113 location_t to dump_location_t. Updates calls to dump_printf_loc
18114 to pass in a dump_location_t rather than a location_t, via the
18115 gimple stmt.
18116 (grid_inner_loop_gridifiable_p): Likewise.
18117 (grid_dist_follows_simple_pattern): Likewise.
18118 (grid_gfor_follows_tiling_pattern): Likewise.
18119 (grid_target_follows_gridifiable_pattern): Likewise.
18120 (grid_attempt_target_gridification): Convert initialization
18121 of local "grid" from memset to zero-initialization; FIXME: does
18122 this require C++11? Update call to dump_printf_loc to pass in a
18123 optinfo_location rather than a location_t, via the gimple stmt.
18124 * profile.c (read_profile_edge_counts): Updates call to
18125 dump_printf_loc to pass in a dump_location_t rather than a
18126 location_t
18127 (compute_branch_probabilities): Likewise.
18128 * selftest-run-tests.c (selftest::run_tests): Call
18129 dumpfile_c_tests.
18130 * selftest.h (dumpfile_c_tests): New decl.
18131 * tree-loop-distribution.c (pass_loop_distribution::execute):
18132 Update for change in return type of find_loop_location.
18133 * tree-parloops.c (parallelize_loops): Likewise.
18134 * tree-ssa-loop-ivcanon.c (try_unroll_loop_completely): Convert
18135 "locus" from location_t to dump_user_location_t.
18136 (canonicalize_loop_induction_variables): Likewise.
18137 * tree-ssa-loop-ivopts.c (tree_ssa_iv_optimize_loop): Update
18138 for change in return type of find_loop_location.
18139 * tree-ssa-loop-niter.c (number_of_iterations_exit): Update call
18140 to dump_printf_loc to pass in a dump_location_t rather than a
18141 location_t, via the stmt.
18142 * tree-ssa-sccvn.c (eliminate_dom_walker::before_dom_children):
18143 Likewise.
18144 * tree-vect-loop-manip.c (find_loop_location): Convert return
18145 type from source_location to dump_user_location_t.
18146 (vect_do_peeling): Update for above change.
18147 (vect_loop_versioning): Update for change in type of
18148 vect_location.
18149 * tree-vect-loop.c (check_reduction_path): Convert "loc" param
18150 from location_t to dump_user_location_t.
18151 (vect_estimate_min_profitable_iters): Update for change in type
18152 of vect_location.
18153 * tree-vect-slp.c (vect_print_slp_tree): Convert param "loc" from
18154 location_t to dump_location_t.
18155 (vect_slp_bb): Update for change in type of vect_location.
18156 * tree-vectorizer.c (vect_location): Convert from source_location
18157 to dump_user_location_t.
18158 (try_vectorize_loop_1): Update for change in vect_location's type.
18159 (vectorize_loops): Likewise.
18160 (increase_alignment): Likewise.
18161 * tree-vectorizer.h (vect_location): Convert from source_location
18162 to dump_user_location_t.
18163 (find_loop_location): Convert return type from source_location to
18164 dump_user_location_t.
18165 (check_reduction_path): Convert 1st param from location_t to
18166 dump_user_location_t.
18167 * value-prof.c (check_counter): Update call to dump_printf_loc to
18168 pass in a dump_user_location_t rather than a location_t; update
18169 call to error_at for change in type of "locus".
18170 (check_ic_target): Update call to dump_printf_loc to
18171 pass in a dump_user_location_t rather than a location_t, via the
18172 call_stmt.
18173
18174 2018-06-26 Robin Dapp <rdapp@linux.vnet.ibm.com>
18175
18176 * config/s390/s390.h (enum processor_flags): Do not use
18177 default tune parameter when -march was specified.
18178
18179 2018-06-26 Jakub Jelinek <jakub@redhat.com>
18180
18181 PR target/86314
18182 * config/i386/i386.md (setcc + movzbl to xor + setcc peephole2s):
18183 Check reg_overlap_mentioned_p in addition to reg_set_p with the same
18184 operands.
18185
18186 2018-06-26 Richard Biener <rguenther@suse.de>
18187
18188 PR tree-optimization/86287
18189 PR bootstrap/86316
18190 * tree-vect-loop.c (vect_transform_loop_stmt): Fix read-after-free.
18191 (vect_analyze_loop): Initialize n_stmts.
18192
18193 2018-06-26 Richard Biener <rguenther@suse.de>
18194
18195 PR middle-end/86271
18196 * fold-const.c (fold_convertible_p): Pointer extension
18197 isn't valid.
18198
18199 2018-06-26 Alexandre Oliva <aoliva@redhat.com>
18200
18201 PR debug/86064
18202 * dwarf2out.c (loc_list_has_views): Adjust comments.
18203 (dw_loc_list): Split single cross-partition range with
18204 nonzero locview.
18205
18206 2018-06-25 Jeff Law <law@redhat.com>
18207
18208 * common/config/v850/v850-common.c (TARGET_DEFAULT_TARGET_FLAGS): Turn
18209 on -mbig-switch by default.
18210
18211 * config/v850/predicates.md (const_float_1_operand): Fix match_code
18212 test.
18213 (const_float_0_operand): Remove unused predicate.
18214 * config/v850/v850.md (define_constants): Remove UNSPEC_LOOP.
18215 (define_c_enum unspec): Add LOOP, RCP and RSQRT constants.
18216 (recipsf2): New expander. Original pattern now called
18217 (recipsf2_insn).
18218 (recipdf2, recipdf2_insn): Similarly.
18219 (rsqrtsf2, rsqrtsf2_insn): Similarly
18220 (rsqrtdf2, rsqrtdf2_insn): Similarly
18221
18222 2018-06-26 Gerald Pfeifer <gerald@pfeifer.com>
18223
18224 * ginclude/stddef.h: Remove an obsolete comment on FreeBSD 5.
18225 Simplify logic for FreeBSD (twice).
18226
18227 2018-06-25 Martin Sebor <msebor@redhat.com>
18228
18229 PR tree-optimization/86204
18230 * tree-ssa-strlen.c (handle_builtin_strlen): Avoid storing
18231 a strnlen result if it's less than the length of the string.
18232
18233 2018-06-25 Martin Sebor <msebor@redhat.com>
18234
18235 PR tree-optimization/85700
18236 * gimple-fold.c (gimple_fold_builtin_strncat): Adjust comment.
18237 * tree-ssa-strlen.c (is_strlen_related_p): Handle integer subtraction.
18238 (maybe_diag_stxncpy_trunc): Distinguish strncat from strncpy.
18239
18240 2018-06-25 Martin Sebor <msebor@redhat.com>
18241
18242 * doc/extend.texi (Zero-length arrays): Update and clarify.
18243
18244 2018-06-25 Michael Meissner <meissner@linux.ibm.com>
18245
18246 * config.gcc (powerpc64le*): Revert January 16th, 2018 patch that
18247 added IEEE/IBM long double multilib support on PowerPC little
18248 endian Linux systems.
18249 * config/rs6000/linux64.h (MULTILIB_DEFAULTS_IEEE): Likewise.
18250 (MULTILIB_DEFAULTS): Likewise.
18251 * config/rs6000/rs6000.c (rs6000_option_override_internal):
18252 Likewise.
18253 * config/rs6000/rs6000.h (TARGET_IEEEQUAD_MULTILIB): Likewise.
18254 * config/rs6000/t-ldouble-linux64le-ibm: Delete, no longer used.
18255 * config/rs6000/t-ldouble-linux64le-ieee: Delete, no longer used.
18256
18257 2018-06-25 Alexander Monakov <amonakov@ispras.ru>
18258
18259 PR middle-end/86311
18260 * sort.cc (REORDER_23): Avoid memcpy with same destination and source.
18261 (REORDER_45): Likewise.
18262
18263 2018-06-25 Jeff Law <law@redhat.com>
18264
18265 * config/v850/v850.md (divmodhi4): Make sure to sign extend the
18266 dividend to 32 bits. Adjust length.
18267 (udivmodhi4): Cleanup output template. Fix length.
18268
18269 2018-06-25 Carl Love <cel@us.ibm.com>
18270
18271 * config/rs6000/vsx.md: Change word selector to prefered location.
18272
18273 2018-06-25 Richard Biener <rguenther@suse.de>
18274
18275 PR tree-optimization/86304
18276 * tree-vectorizer.c (vectorize_loops): Walk over new possibly
18277 epilogue-if-converted loops as well.
18278
18279 2018-06-25 Jan Hubicka <hubicka@ucw.cz>
18280
18281 * lto-section-out.c (lto_begin_section): Do not print section
18282 name for noaddr and unnumbered dumps.
18283
18284 2018-06-25 Richard Biener <rguenther@suse.de>
18285
18286 * tree-vectorizer.h (struct vec_info_shared): New structure
18287 with parts split out from struct vec_info and loop_nest from
18288 struct _loop_vec_info.
18289 (struct vec_info): Adjust accordingly.
18290 (struct _loop_vec_info): Likewise.
18291 (LOOP_VINFO_LOOP_NEST): Adjust.
18292 (LOOP_VINFO_DATAREFS): Likewise.
18293 (LOOP_VINFO_DDRS): Likewise.
18294 (struct _bb_vec_info): Likewise.
18295 (BB_VINFO_DATAREFS): Likewise.
18296 (BB_VINFO_DDRS): Likewise.
18297 (struct _stmt_vec_info): Add dr_aux member.
18298 (DR_VECT_AUX): Adjust to refer to member of DR_STMTs vinfo.
18299 (DR_MISALIGNMENT_UNINITIALIZED): New.
18300 (set_dr_misalignment): Adjust.
18301 (dr_misalignment): Assert misalign isn't DR_MISALIGNMENT_UNINITIALIZED.
18302 (vect_analyze_loop): Adjust prototype.
18303 (vect_analyze_loop_form): Likewise.
18304 * tree-vect-data-refs.c (vect_analyze_data_ref_dependences):
18305 Compute dependences lazily.
18306 (vect_record_base_alignments): Use shared datarefs/ddrs.
18307 (vect_verify_datarefs_alignment): Likewise.
18308 (vect_analyze_data_refs_alignment): Likewise.
18309 (vect_analyze_data_ref_accesses): Likewise.
18310 (vect_analyze_data_refs): Likewise.
18311 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Add
18312 constructor parameter for shared part.
18313 (vect_analyze_loop_form): Pass in shared part and adjust.
18314 (vect_analyze_loop_2): Pass in storage for the number of
18315 stmts. Move loop nest finding to the caller. Compute
18316 datarefs lazily.
18317 (vect_analyze_loop): Pass in shared part.
18318 (vect_transform_loop): Verify shared datarefs are unchanged.
18319 * tree-vect-slp.c (_bb_vec_info::_bb_vec_info): Add
18320 constructor parameter for shared part.
18321 (vect_slp_analyze_bb_1): Pass in shared part and adjust.
18322 (vect_slp_bb): Verify shared datarefs are unchanged before
18323 transform.
18324 * tree-vect-stmts.c (ensure_base_align): Adjust for DR_AUX
18325 change.
18326 (new_stmt_vec_info): Initialize DR_AUX misalignment to
18327 DR_MISALIGNMENT_UNINITIALIZED.
18328 * tree-vectorizer.c (vec_info::vec_info): Add constructor
18329 parameter for shared part.
18330 (vec_info::~vec_info): Adjust.
18331 (vec_info_shared::vec_info_shared): New.
18332 (vec_info_shared::~vec_info_shared): Likewise.
18333 (vec_info_shared::save_datarefs): Likewise.
18334 (vec_info_shared::check_datarefs): Likewise.
18335 (try_vectorize_loop_1): Construct shared part live for analyses
18336 of a single loop for multiple vector sizes.
18337 * tree-parloops.c (gather_scalar_reductions): Adjust.
18338
18339 2018-06-25 Richard Biener <rguenther@suse.de>
18340
18341 * tree-vect-data-refs.c (vect_find_stmt_data_reference): Modify
18342 DR for SIMD lane accesses here and mark DR with (void *)-1 aux.
18343 (vect_analyze_data_refs): Remove similar code from here and
18344 simplify accordingly.
18345
18346 2018-06-25 Richard Biener <rguenther@suse.de>
18347
18348 * tree-vect-data-refs.c (vect_check_gather_scatter): Fail
18349 for reverse storage order accesses rather than asserting
18350 they cannot happen here.
18351
18352 2018-06-25 Tom de Vries <tdevries@suse.de>
18353
18354 PR debug/86257
18355 * config/i386/i386.md (define_insn "*tls_global_dynamic_64_<mode>"):
18356 Use data16 instead of .byte for insn prefix.
18357
18358 2018-06-25 Andreas Krebbel <krebbel@linux.ibm.com>
18359
18360 PR C++/86082
18361 * parser.c (make_char_string_pack): Pass this literal chars
18362 through cpp_interpret_string.
18363 (cp_parser_userdef_numeric_literal): Check the result of
18364 make_char_string_pack.
18365
18366 2018-06-24 Maya Rashish <coypu@sdf.org>
18367
18368 * ginclude/stddef.h: Simplify conditions around avoiding
18369 re-definition of __size_t.
18370
18371 2018-06-22 Jan Hubicka <hubicka@ucw.cz>
18372
18373 * lto-streamer-out.c (tree_is_indexable): Make LABEL_DECL nonindexable
18374 unless it is forced or nonlocal; assert that we stream no IMPORTED_DECL.
18375
18376 2018-06-22 Maya Rashish <coypu@sdf.org>
18377
18378 * doc/invoke.texi (mno-fancy-math-387): Update for changes
18379 made to OpenBSD and NetBSD through the years.
18380
18381 2018-06-22 Kelvin Nilsen <kelvin@gcc.gnu.org>
18382
18383 * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Change
18384 behavior of vec_pack (vector double, vector double) to match
18385 behavior of vec_float2 (vector double, vector double).
18386
18387 2018-06-22 Olivier Hainque <hainque@adacore.com>
18388
18389 * gimplify.c (gimplify_function_tree): Prevent creation
18390 of a trampoline for the address of the current function
18391 passed to entry/exit instrumentation hooks.
18392
18393 2018-06-22 Aaron Sawdey <acsawdey@linux.ibm.com>
18394
18395 PR target/86222
18396 * config/rs6000/rs6000-string.c (expand_strn_compare): Handle -m32
18397 correctly.
18398
18399 2018-06-22 Martin Liska <mliska@suse.cz>
18400
18401 PR tree-optimization/86263
18402 * tree-switch-conversion.c (jump_table_cluster::find_jump_tables):
18403 Bail out if is_enabled is false.
18404 * tree-switch-conversion.h (jump_table_cluster::is_enabled):
18405 New declaration.
18406 (jump_table_cluster::is_enabled): New function.
18407
18408 2018-06-22 Jan Hubicka <hubicka@ucw.cz>
18409
18410 * lto-streamer-out.c (DFS::DFS_write_tree_body): Do not stream
18411 BINFO_BASE_ACCESSES and BINFO_VPTR_FIELD.
18412 * tree-streamer-in.c (streamer_read_tree_bitfields): Likewise.
18413 (lto_input_ts_binfo_tree_pointers): Likewise.
18414 * tree-streamer-out.c (streamer_write_tree_bitfields,
18415 write_ts_binfo_tree_pointers): Likewise.
18416 * tree.c (free_lang_data_in_binfo): Clear BINFO_VPTR_FIELD.
18417
18418 2018-06-22 Jan Hubicka <hubicka@ucw.cz>
18419
18420 * tree.c (free_lang_data_in_type): Free all TYPE_VFIELDs.
18421
18422 2018-06-22 Martin Liska <mliska@suse.cz>
18423
18424 * symbol-summary.h (get): Make it pure and inline move
18425 functionality from ::get function.
18426 (get): Remove and inline into ::get and ::get_create.
18427 (get_create): Move code from ::get function.
18428
18429 2018-06-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
18430
18431 PR target/85994
18432 * config/i386/sol2.h (CPP_SPEC): Don't pass -P for
18433 -x assembler-with-cpp.
18434
18435 2018-06-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
18436
18437 * config/sol2.h (TARGET_OS_CPP_BUILTINS): Define
18438 _FILE_OFFSET_BITS=64 for C++.
18439
18440 2018-06-21 Michael Meissner <meissner@linux.ibm.com>
18441
18442 * config/rs6000/rs6000.md (extendtfif2): Add missing 128-bit
18443 conversion insn that shows up when pr85657-3.c is compiled using
18444 IEEE 128-bit long double.
18445 (neg<mode>2_internal): Use the correct mode to check whether the
18446 mode is IBM extended.
18447 * config/rs6000/rs6000.c (init_float128_ieee): Prevent complex
18448 multiply and divide external functions from being created more
18449 than once.
18450
18451 2018-06-21 Eric Botcazou <ebotcazou@adacore.com>
18452
18453 * cfgrtl.c (fixup_reorder_chain): Do not emit NOPs in DECL_IGNORED_P
18454 functions.
18455 (rtl_merge_blocks): Likewise. Do not emit a NOP if the location of
18456 the edge can be forwarded.
18457 (cfg_layout_merge_blocks): Likewise.
18458
18459 2018-06-21 Eric Botcazou <ebotcazou@adacore.com>
18460
18461 * except.c (finish_eh_generation): Commit edge insertions only after
18462 the EH edges have been redirected from post-landing to landing pads.
18463
18464 2018-06-21 Eric Botcazou <ebotcazou@adacore.com>
18465
18466 * tree-nested.c (get_frame_type): Use create_tmp_var_raw instead of
18467 create_tmp_var_for to create the FRAME decl.
18468 (finalize_nesting_tree_1): Do not unchain the FRAME decl.
18469
18470 2018-06-21 Eric Botcazou <ebotcazou@adacore.com>
18471
18472 * tree-inline.c (copy_edges_for_bb): Minor tweak.
18473 (maybe_move_debug_stmts_to_successors): Also reset the locus of the
18474 debug statement when resetting its value.
18475 (expand_call_inline): Copy the locus of the call onto the assignment
18476 of the return value, if any. Use local variable in more cases.
18477
18478 2018-06-21 Martin Liska <mliska@suse.cz>
18479
18480 * ipa-pure-const.c (propagate_nothrow): Use
18481 funct_state_summaries->get.
18482 (dump_malloc_lattice): Likewise.
18483 (propagate_malloc): Likewise.
18484
18485 2018-06-21 Richard Biener <rguenther@suse.de>
18486
18487 * lto-streamer-out.c (DFS::DFS_write_tree_body): Update outdated
18488 comment. Follow BLOCK_ABSTRACT_ORIGIN unconditionally.
18489 * tree-streamer-in.c (lto_input_ts_block_tree_pointers): Update
18490 comment.
18491 * tree-streamer-out.c (write_ts_block_tree_pointers): Stream
18492 BLOCK_ABSTRACT_ORIGIN unconditionally.
18493
18494 2018-06-21 David Malcolm <dmalcolm@redhat.com>
18495
18496 * ipa-cp.c (ipcp_driver): Set edge_clone_summaries to NULL after
18497 deleting it.
18498 * ipa-reference.c (ipa_reference_c_finalize): Delete
18499 ipa_ref_opt_sum_summaries and set it to NULL.
18500
18501 2018-06-21 Tom de Vries <tdevries@suse.de>
18502
18503 PR tree-optimization/85859
18504 * tree-ssa-tail-merge.c (stmt_local_def): Copy gimple_is_call
18505 test with comment from bb_no_side_effects_p.
18506
18507 2018-06-21 Richard Biener <rguenther@suse.de>
18508
18509 PR tree-optimization/86232
18510 * tree-ssa-loop-niter.c (number_of_iterations_popcount): Adjust
18511 max for constant niter.
18512
18513 2018-06-21 Andre Vieira <andre.simoesdiasvieira@arm.com>
18514
18515 * config/aarch64/aarch64-simd.md
18516 (*aarch64_crypto_aes<aes_op>v16qi_xor_combine): New.
18517
18518 2018-06-21 Andre Vieira <andre.simoesdiasvieira@arm.com>
18519
18520 * config/aarch64/aarch64-simd.md (aarch64_crypto_aes<aes_op>v16qi):
18521 Make opernads of the unspec commutative.
18522
18523 2018-06-21 Richard Biener <rguenther@suse.de>
18524
18525 * tree-data-ref.c (dr_step_indicator): Handle NULL DR_STEP.
18526 * tree-vect-data-refs.c (vect_analyze_possibly_independent_ddr):
18527 Avoid calling vect_mark_for_runtime_alias_test with gathers or scatters.
18528 (vect_analyze_data_ref_dependence): Re-order checks to deal with
18529 NULL DR_STEP.
18530 (vect_record_base_alignments): Do not record base alignment
18531 for gathers or scatters.
18532 (vect_compute_data_ref_alignment): Drop return value that is always
18533 true. Bail out early for gathers or scatters.
18534 (vect_enhance_data_refs_alignment): Bail out early for gathers
18535 or scatters.
18536 (vect_find_same_alignment_drs): Likewise.
18537 (vect_analyze_data_refs_alignment): Remove dead code.
18538 (vect_slp_analyze_and_verify_node_alignment): Likewise.
18539 (vect_analyze_data_refs): For possible gathers or scatters do
18540 not create an alternate DR, just check their possible validity
18541 and mark them. Adjust DECL_NONALIASED handling to not rely
18542 on DR_BASE_ADDRESS.
18543 * tree-vect-loop-manip.c (vect_update_inits_of_drs): Do not
18544 update inits of gathers or scatters.
18545 * tree-vect-patterns.c (vect_recog_mask_conversion_pattern):
18546 Also copy gather/scatter flag to pattern vinfo.
18547
18548 2018-06-20 Kelvin Nilsen <kelvin@gcc.gnu.org>
18549
18550 * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Change
18551 behavior of vec_packsu (vector unsigned long long, vector unsigned
18552 long long) to match behavior of vec_packs with same signature.
18553
18554 2018-06-20 Chung-Lin Tang <cltang@codesourcery.com>
18555 Thomas Schwinge <thomas@codesourcery.com>
18556 Cesar Philippidis <cesar@codesourcery.com>
18557
18558 * gimplify.c (gimplify_scan_omp_clauses): Add support for
18559 OMP_CLAUSE_{IF_PRESENT,FINALIZE}.
18560 (gimplify_adjust_omp_clauses): Likewise.
18561 (gimplify_oacc_declare_1): Add support for GOMP_MAP_RELEASE, remove
18562 support for GOMP_MAP_FORCE_{ALLOC,TO,FROM,TOFROM}.
18563 (gimplify_omp_target_update): Update handling of acc update and
18564 enter/exit data.
18565 * omp-low.c (install_var_field): Remove unused parameter
18566 base_pointers_restrict.
18567 (scan_sharing_clauses): Remove base_pointers_restrict parameter.
18568 Update call to install_var_field. Handle OMP_CLAUSE_{IF_PRESENT,
18569 FINALIZE}
18570 (omp_target_base_pointers_restrict_p): Delete.
18571 (scan_omp_target): Update call to scan_sharing_clauses.
18572 * tree-core.h (enum omp_clause_code): Add OMP_CLAUSE_{IF_PRESENT,
18573 FINALIZE}.
18574 * tree-nested.c (convert_nonlocal_omp_clauses): Handle
18575 OMP_CLAUSE_{IF_PRESENT,FINALIZE}.
18576 (convert_local_omp_clauses): Likewise.
18577 * tree-pretty-print.c (dump_omp_clause): Likewise.
18578 * tree.c (omp_clause_num_ops): Add entries for OMP_CLAUSE_{IF_PRESENT,
18579 FINALIZE}.
18580 (omp_clause_code_name): Likewise.
18581
18582 2018-06-20 Jakub Jelinek <jakub@redhat.com>
18583
18584 PR debug/86194
18585 * var-tracking.c (use_narrower_mode_test): Check if shift amount can
18586 be narrowed.
18587
18588 PR tree-optimization/86231
18589 * tree-vrp.c (union_ranges): For ( [ ) ] or ( )[ ] range and
18590 anti-range don't overwrite *vr0min before using it to compute *vr0max.
18591
18592 2018-06-20 Tom de Vries <tdevries@suse.de>
18593
18594 PR tree-optimization/86097
18595 * tree-ssa-loop-manip.c (canonicalize_loop_ivs): Also convert *nit to
18596 iv type if signedness of iv type is not the same as that of *nit.
18597
18598 2018-06-20 Jakub Jelinek <jakub@redhat.com>
18599
18600 * cfgrtl.c (rtl_verify_edges): Formatting fix. If bb->preds has any
18601 EDGE_EH edges, verify they are all EDGE_EH.
18602
18603 2018-06-20 Maya Rashish <coypu@sdf.org>
18604
18605 * ginclude/stddef.h: Limit #include <machine/ansi.h> to NetBSD.
18606
18607 2018-06-20 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
18608
18609 * config/aarch64/aarch64-tuning-flags.def (no_ldp_stp_qregs): New.
18610 * config/aarch64/aarch64.c (xgene1_tunings): Add
18611 AARCH64_EXTRA_TUNE_NO_LDP_STP_QREGS to tune_flags.
18612 (aarch64_mode_valid_for_sched_fusion_p):
18613 Allow 16-byte modes.
18614 (aarch64_classify_address): Allow 16-byte modes for load_store_pair_p.
18615 * config/aarch64/aarch64-ldpstp.md: Add peepholes for LDP STP of
18616 128-bit modes.
18617 * config/aarch64/aarch64-simd.md (load_pair<VQ:mode><VQ2:mode>):
18618 New pattern.
18619 (vec_store_pair<VQ:mode><VQ2:mode>): Likewise.
18620 * config/aarch64/iterators.md (VQ2): New mode iterator.
18621
18622 2018-06-20 Martin Liska <mliska@suse.cz>
18623
18624 * tree-switch-conversion.c (jump_table_cluster::can_be_handled):
18625 Change default ratio from 10 to 8.
18626
18627 2018-06-20 Martin Liska <mliska@suse.cz>
18628
18629 * tree-switch-conversion.c (jump_table_cluster::find_jump_tables):
18630 New.
18631 (bit_test_cluster::find_bit_tests): Likewise.
18632 (switch_decision_tree::analyze_switch_statement): Find clusters.
18633 * tree-switch-conversion.h (struct jump_table_cluster): Document
18634 hierarchy.
18635
18636 2018-06-20 Martin Liska <mliska@suse.cz>
18637
18638 * tree-switch-conversion.c (switch_conversion::collect):
18639 Record m_uniq property.
18640 (switch_conversion::expand): Bail out for special conditions.
18641 (group_cluster::~group_cluster): New.
18642 (group_cluster::group_cluster): Likewise.
18643 (group_cluster::dump): Likewise.
18644 (jump_table_cluster::emit): New.
18645 (switch_decision_tree::fix_phi_operands_for_edges): New.
18646 (struct case_node): Remove struct.
18647 (jump_table_cluster::can_be_handled): New.
18648 (case_values_threshold): Moved to header.
18649 (reset_out_edges_aux): Likewise.
18650 (jump_table_cluster::is_beneficial): New.
18651 (bit_test_cluster::can_be_handled): Likewise.
18652 (add_case_node): Remove.
18653 (bit_test_cluster::is_beneficial): New.
18654 (case_bit_test::cmp): New.
18655 (bit_test_cluster::emit): New.
18656 (expand_switch_as_decision_tree_p): Remove.
18657 (bit_test_cluster::hoist_edge_and_branch_if_true): New.
18658 (fix_phi_operands_for_edge): Likewise.
18659 (switch_decision_tree::analyze_switch_statement): New.
18660 (compute_cases_per_edge): Move ...
18661 (switch_decision_tree::compute_cases_per_edge): ... here.
18662 (try_switch_expansion): Likewise.
18663 (switch_decision_tree::try_switch_expansion): Likewise.
18664 (record_phi_operand_mapping): Likewise.
18665 (switch_decision_tree::record_phi_operand_mapping): Likewise.
18666 (emit_case_decision_tree): Likewise.
18667 (switch_decision_tree::emit): Likewise.
18668 (balance_case_nodes): Likewise.
18669 (switch_decision_tree::balance_case_nodes): Likewise.
18670 (dump_case_nodes): Likewise.
18671 (switch_decision_tree::dump_case_nodes): Likewise.
18672 (emit_jump): Likewise.
18673 (switch_decision_tree::emit_jump): Likewise.
18674 (emit_cmp_and_jump_insns): Likewise.
18675 (switch_decision_tree::emit_cmp_and_jump_insns): Likewise.
18676 (emit_case_nodes): Likewise.
18677 (switch_decision_tree::emit_case_nodes): Likewise.
18678 (conditional_probability): Remove.
18679 * tree-switch-conversion.h (enum cluster_type): New.
18680 (PRINT_CASE): New.
18681 (struct cluster): Likewise.
18682 (cluster::cluster): Likewise.
18683 (struct simple_cluster): Likewise.
18684 (simple_cluster::simple_cluster): Likewise.
18685 (struct group_cluster): Likewise.
18686 (struct jump_table_cluster): Likewise.
18687 (struct bit_test_cluster): Likewise.
18688 (struct min_cluster_item): Likewise.
18689 (struct case_tree_node): Likewise.
18690 (case_tree_node::case_tree_node): Likewise.
18691 (jump_table_cluster::case_values_threshold): Likewise.
18692 (struct case_bit_test): Likewise.
18693 (struct switch_decision_tree): Likewise.
18694 (struct switch_conversion): Likewise.
18695 (switch_decision_tree::reset_out_edges_aux): Likewise.
18696
18697 2018-06-20 Martin Liska <mliska@suse.cz>
18698
18699 * tree-switch-conversion.c (MAX_CASE_BIT_TESTS): Remove.
18700 (hoist_edge_and_branch_if_true): Likewise.
18701 (expand_switch_using_bit_tests_p): Likewise.
18702 (struct case_bit_test): Likewise.
18703 (case_bit_test_cmp): Likewise.
18704 (emit_case_bit_tests): Likewise.
18705 (switch_conversion::switch_conversion): New class.
18706 (struct switch_conv_info): Remove old struct.
18707 (collect_switch_conv_info): More to ...
18708 (switch_conversion::collect): ... this.
18709 (check_range): Likewise.
18710 (switch_conversion::check_range): Likewise.
18711 (check_all_empty_except_final): Likewise.
18712 (switch_conversion::check_all_empty_except_final): Likewise.
18713 (check_final_bb): Likewise.
18714 (switch_conversion::check_final_bb): Likewise.
18715 (create_temp_arrays): Likewise.
18716 (switch_conversion::create_temp_arrays): Likewise.
18717 (free_temp_arrays): Likewise.
18718 (gather_default_values): Likewise.
18719 (switch_conversion::gather_default_values): Likewise.
18720 (build_constructors): Likewise.
18721 (switch_conversion::build_constructors): Likewise.
18722 (constructor_contains_same_values_p): Likewise.
18723 (switch_conversion::contains_same_values_p): Likewise.
18724 (array_value_type): Likewise.
18725 (switch_conversion::array_value_type): Likewise.
18726 (build_one_array): Likewise.
18727 (switch_conversion::build_one_array): Likewise.
18728 (build_arrays): Likewise.
18729 (switch_conversion::build_arrays): Likewise.
18730 (gen_def_assigns): Likewise.
18731 (switch_conversion::gen_def_assigns): Likewise.
18732 (prune_bbs): Likewise.
18733 (switch_conversion::prune_bbs): Likewise.
18734 (fix_phi_nodes): Likewise.
18735 (switch_conversion::fix_phi_nodes): Likewise.
18736 (gen_inbound_check): Likewise.
18737 (switch_conversion::gen_inbound_check): Likewise.
18738 (process_switch): Use the newly created class.
18739 (switch_conversion::expand): New.
18740 (switch_conversion::~switch_conversion): New.
18741 * tree-switch-conversion.h: New file.
18742
18743 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
18744
18745 * tree-vectorizer.h (NUM_PATTERNS, vect_recog_func_ptr): Move to
18746 tree-vect-patterns.c.
18747 * tree-vect-patterns.c (vect_supportable_direct_optab_p): New function.
18748 (vect_recog_dot_prod_pattern): Use it. Remove the type_in argument.
18749 (vect_recog_sad_pattern): Likewise.
18750 (vect_recog_widen_sum_pattern): Likewise.
18751 (vect_recog_pow_pattern): Likewise. Check for a null vectype.
18752 (vect_recog_widen_shift_pattern): Remove the type_in argument.
18753 (vect_recog_rotate_pattern): Likewise.
18754 (vect_recog_mult_pattern): Likewise.
18755 (vect_recog_vector_vector_shift_pattern): Likewise.
18756 (vect_recog_divmod_pattern): Likewise.
18757 (vect_recog_mixed_size_cond_pattern): Likewise.
18758 (vect_recog_bool_pattern): Likewise.
18759 (vect_recog_mask_conversion_pattern): Likewise.
18760 (vect_try_gather_scatter_pattern): Likewise.
18761 (vect_recog_widen_mult_pattern): Likewise. Check for a null vectype.
18762 (vect_recog_over_widening_pattern): Likewise.
18763 (vect_recog_gather_scatter_pattern): Likewise.
18764 (vect_recog_func_ptr): Move from tree-vectorizer.h
18765 (vect_vect_recog_func_ptrs): Move further down the file.
18766 (vect_recog_func): Likewise. Remove the third argument.
18767 (NUM_PATTERNS): Define based on vect_vect_recog_func_ptrs.
18768 (vect_pattern_recog_1): Expect the pattern function to do any
18769 necessary target tests. Also expect it to provide a vector type.
18770 Remove the type_in handling.
18771
18772 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
18773
18774 * tree-vect-patterns.c (vect_pattern_detected): New function.
18775 (vect_recog_dot_prod_patternm, vect_recog_sad_pattern)
18776 (vect_recog_widen_mult_pattern, vect_recog_widen_sum_pattern)
18777 (vect_recog_over_widening_pattern, vect_recog_widen_shift_pattern
18778 (vect_recog_rotate_pattern, vect_recog_vector_vector_shift_pattern)
18779 (vect_recog_mult_pattern, vect_recog_divmod_pattern)
18780 (vect_recog_mixed_size_cond_pattern, vect_recog_bool_pattern)
18781 (vect_recog_mask_conversion_pattern)
18782 (vect_try_gather_scatter_pattern): Likewise.
18783
18784 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
18785
18786 * tree-vect-patterns.c (vect_get_internal_def): New function.
18787 (vect_recog_dot_prod_pattern, vect_recog_sad_pattern)
18788 (vect_recog_vector_vector_shift_pattern, check_bool_pattern)
18789 (search_type_for_mask_1): Use it.
18790
18791 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
18792
18793 * tree-vect-patterns.c (vect_recog_dot_prod_pattern): Remove
18794 redundant WIDEN_SUM_EXPR handling.
18795 (vect_recog_sad_pattern): Likewise.
18796
18797 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
18798
18799 * tree-vect-patterns.c (vect_recog_dot_prod_pattern): Remove
18800 redundant check that the types of a PLUS_EXPR or MULT_EXPR agree.
18801 (vect_recog_sad_pattern): Likewise PLUS_EXPR, ABS_EXPR and MINUS_EXPR.
18802 (vect_recog_widen_mult_pattern): Likewise MULT_EXPR.
18803 (vect_recog_widen_sum_pattern): Likewise PLUS_EXPR.
18804
18805 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
18806
18807 * tree-vect-stmts.c (vectorizable_call): Make sure that we
18808 use the stmt_vec_info of the original bb statement for the
18809 new zero assignment, even if the call is part of a pattern.
18810
18811 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
18812
18813 * tree-vectorizer.h (_stmt_vec_info): Note above pattern_def_seq
18814 that the sequence is attached to the original statement rather
18815 than the pattern statement.
18816 * tree-vect-loop.c (vect_determine_vf_for_stmt): Take the
18817 PATTERN_DEF_SEQ from the original statement rather than
18818 the main pattern statement.
18819 * tree-vect-stmts.c (free_stmt_vec_info): Likewise.
18820 * tree-vect-patterns.c (vect_recog_dot_prod_pattern): Likewise.
18821 (vect_mark_pattern_stmts): Don't copy the PATTERN_DEF_SEQ.
18822
18823 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
18824
18825 * tree-vect-stmts.c (vect_analyze_stmt): Move the handling of pattern
18826 definition statements before the early exit for statements that aren't
18827 live or relevant.
18828 * tree-vect-loop.c (vect_transform_loop_stmt): New function,
18829 split out from...
18830 (vect_transform_loop): ...here. Process pattern definition
18831 statements without first checking whether the main pattern
18832 statement is live or relevant.
18833
18834 2018-06-19 Eric Botcazou <ebotcazou@adacore.com>
18835
18836 * tree-cfgcleanup.c (tree_forwarder_block_p): Do not return false at
18837 -O0 if the locus represent UNKNOWN_LOCATION but have different values.
18838
18839 2018-06-19 Aaron Sawdey <acsawdey@linux.ibm.com>
18840
18841 * config/rs6000/rs6000-string.c (select_block_compare_mode): Check
18842 TARGET_EFFICIENT_OVERLAPPING_UNALIGNED here instead of in caller.
18843 (do_and3, do_and3_mask, do_compb3, do_rotl3): New functions.
18844 (expand_block_compare): Change select_block_compare_mode call.
18845 (expand_strncmp_align_check): Use new functions, fix comment.
18846 (emit_final_str_compare_gpr): New function.
18847 (expand_strn_compare): Refactor and clean up code.
18848 * config/rs6000/vsx.md (vsx_mov<mode>_64bit): Remove *.
18849
18850 2018-06-19 Tony Reix <tony.reix@atos.com>
18851 Damien Bergamini <damien.bergamini@atos.com>
18852 David Edelsohn <dje.gcc@gmail.com>
18853
18854 * collect2.c (static_obj): New variable.
18855 (static_libs): New variable.
18856 (is_in_list): Uncomment declaration.
18857 (main): Track AIX libraries linked statically.
18858 (is_in_list): Uncomment definition.
18859 (scan_prog_file): Don't add AIX shared libraries initializer
18860 to constructor list if linking statically.
18861
18862 2018-06-19 Max Filippov <jcmvbkbc@gmail.com>
18863
18864 * config/xtensa/xtensa.md (UNSPEC_FRAME_BLOCKAGE): New unspec
18865 constant.
18866 (allocate_stack, frame_blockage, *frame_blockage): New patterns.
18867
18868 2018-06-19 Jan Hubicka <hubicka@ucw.cz>
18869
18870 * tree.c (find_decls_types_r): Remove all non-VAR_DECLs from
18871 blocks.
18872
18873 2018-06-19 Martin Liska <mliska@suse.cz>
18874
18875 * config/i386/i386.c (ix86_can_inline_p): Do not use
18876 ipa_fn_summaries::get_create.
18877 * ipa-cp.c (ipcp_cloning_candidate_p): Replace get_create with
18878 get.
18879 (devirtualization_time_bonus): Likewise.
18880 (ipcp_propagate_stage): Likewise.
18881 * ipa-fnsummary.c (redirect_to_unreachable): Likewise.
18882 (edge_set_predicate): Likewise.
18883 (evaluate_conditions_for_known_args): Likewise.
18884 (evaluate_properties_for_edge): Likewise.
18885 (ipa_call_summary::reset): Tranform to ...
18886 (ipa_call_summary::~ipa_call_summary): ... this.
18887 (ipa_fn_summary::reset): Transform to ...
18888 (ipa_fn_summary::~ipa_fn_summary): ... this.
18889 (ipa_fn_summary_t::remove): Rename to ...
18890 (ipa_fn_summary_t::remove_callees): ... this.
18891 (ipa_fn_summary_t::duplicate): Use placement new
18892 instead of memory copy.
18893 (ipa_call_summary_t::duplicate): Likewise.
18894 (ipa_call_summary_t::remove): Remove.
18895 (dump_ipa_call_summary): Change get_create to get.
18896 (ipa_dump_fn_summary): Dump only when summary exists.
18897 (analyze_function_body): Use symbol_summary::get instead
18898 of get_create.
18899 (compute_fn_summary): Likewise.
18900 (estimate_edge_devirt_benefit): Likewise.
18901 (estimate_edge_size_and_time): Likewise.
18902 (inline_update_callee_summaries): Likewise.
18903 (remap_edge_change_prob): Likewise.
18904 (remap_edge_summaries): Likewise.
18905 (ipa_merge_fn_summary_after_inlining): Likewise.
18906 (write_ipa_call_summary): Likewise.
18907 (ipa_fn_summary_write): Likewise.
18908 (ipa_free_fn_summary): Likewise.
18909 * ipa-fnsummary.h (struct GTY): Add new ctor and copy ctor.
18910 (struct ipa_call_summary): Likewise.
18911 * ipa-icf.c (sem_function::merge): Use symbol_summary::get instead
18912 of get_create.
18913 * ipa-inline-analysis.c (do_estimate_edge_time): Likewise.
18914 (estimate_size_after_inlining): Likewise.
18915 (estimate_growth): Likewise.
18916 (growth_likely_positive): Likewise.
18917 * ipa-inline-transform.c (clone_inlined_nodes): Likewise.
18918 (inline_call): Likewise.
18919 * ipa-inline.c (caller_growth_limits): Likewise.
18920 (can_inline_edge_p): Likewise.
18921 (can_inline_edge_by_limits_p): Likewise.
18922 (compute_uninlined_call_time): Likewise.
18923 (compute_inlined_call_time): Likewise.
18924 (want_inline_small_function_p): Likewise.
18925 (edge_badness): Likewise.
18926 (update_caller_keys): Likewise.
18927 (update_callee_keys): Likewise.
18928 (inline_small_functions): Likewise.
18929 (inline_to_all_callers_1): Likewise.
18930 (dump_overall_stats): Likewise.
18931 (early_inline_small_functions): Likewise.
18932 (early_inliner): Likewise.
18933 * ipa-profile.c (ipa_propagate_frequency_1): Likewise.
18934 * ipa-prop.c (ipa_make_edge_direct_to_target): Likewise.
18935 * ipa-pure-const.c (malloc_candidate_p): Likewise.
18936 * ipa-split.c (execute_split_functions): Likewise.
18937 * symbol-summary.h: Likewise.
18938 * tree-sra.c (ipa_sra_preliminary_function_checks): Likewise.
18939
18940 2018-06-19 Richard Biener <rguenther@suse.de>
18941
18942 * tree-vectorizer.c (try_vectorize_loop_1): Split out of ...
18943 (vectorize_loops): ... here. Fix dbgcnt handling.
18944 (try_vectorize_loop): Wrap try_vectorize_loop_1.
18945
18946 2018-06-19 Segher Boessenkool <segher@kernel.crashing.org>
18947
18948 PR target/86197
18949 * config/rs6000/rs6000.md (rs6000_discover_homogeneous_aggregate): An
18950 ieee128 argument takes up only one (vector) register, not two (floating
18951 point) registers.
18952
18953 2018-06-19 Eric Botcazou <ebotcazou@adacore.com>
18954
18955 * gimplify.c (gimplify_init_constructor): Really never clear for an
18956 incomplete constructor if CONSTRUCTOR_NO_CLEARING is set.
18957
18958 2018-06-19 Richard Biener <rguenther@suse.de>
18959
18960 PR tree-optimization/86179
18961 * tree-vect-patterns.c (vect_pattern_recog_1): Clean up
18962 after failed recognition.
18963
18964 2018-06-18 Martin Sebor <msebor@redhat.com>
18965
18966 PR middle-end/85602
18967 * calls.c (maybe_warn_nonstring_arg): Handle strncat.
18968 * tree-ssa-strlen.c (is_strlen_related_p): Make extern.
18969 Handle integer subtraction.
18970 (maybe_diag_stxncpy_trunc): Handle nonstring source arguments.
18971 * tree-ssa-strlen.h (is_strlen_related_p): Declare.
18972
18973 2018-06-18 David Malcolm <dmalcolm@redhat.com>
18974
18975 * config/frv/frv-protos.h (frv_ifcvt_modify_insn): Strengthen 3rd
18976 param from rtx to rtx_insn *.
18977 * config/frv/frv.c (frv_ifcvt_add_insn): Likewise for "insn"
18978 param.
18979 (frv_ifcvt_modify_insn): Likwise.
18980 (frv_ifcvt_modify_final): Likwise for local "existing_insn",
18981 adding an as_a <rtx_insn *> cast. Likewise for local "insn".
18982 * config/mips/mips.c (r10k_insert_cache_barriers): Add an
18983 as_a <rtx_insn *> cast to local "unprotected_region" once
18984 it's been established that it's not NULL or pc_rtx.
18985 * config/nds32/nds32-relax-opt.c (nds32_group_insns): Strengthen
18986 param "sethi" from rtx to rtx_insn *.
18987 (nds32_group_float_insns): Likewise for param "insn".
18988 * config/vax/vax-protos.h (vax_output_int_add): Likewise for 1st
18989 param.
18990 (vax_output_int_subtract): Likewise.
18991 * config/vax/vax.c (vax_output_int_add): Likewise for param
18992 "insn".
18993 (vax_output_int_subtract): Likewise.
18994 * emit-rtl.c (set_insn_deleted): Likewise, removing cast.
18995 (emit_pattern_after): Likewise for param "after".
18996 (emit_insn_after): Likewise.
18997 (emit_jump_insn_after): Likewise.
18998 (emit_call_insn_after): Likewise.
18999 (emit_debug_insn_after): Likewise.
19000 (emit_pattern_before): Likewise for param "before".
19001 (emit_insn_before): Likewise.
19002 (emit_jump_insn_before): Likewise.
19003 * final.c (get_insn_template): Likewise for param "insn", removing
19004 a cast.
19005 * output.h (get_insn_template): Likewise for 2nd param.
19006 * rtl.h (emit_insn_before): Likewise.
19007 (emit_jump_insn_before): Likewise.
19008 (emit_debug_insn_before_noloc): Likewise.
19009 (emit_insn_after): Likewise.
19010 (emit_jump_insn_after): Likewise.
19011 (emit_call_insn_after): Likewise.
19012 (emit_debug_insn_after): Likewise.
19013 (set_insn_deleted): Likewise for param.
19014
19015 2018-06-18 Michael Meissner <meissner@linux.ibm.com>
19016
19017 PR target/85358
19018 * config/rs6000/rs6000-modes.def (toplevel): Rework the 128-bit
19019 floating point modes, so that IFmode is numerically greater than
19020 TFmode, which is greater than KFmode using FRACTIONAL_FLOAT_MODE
19021 to declare the ordering. This prevents IFmode from being
19022 converted to TFmode when long double is IEEE 128-bit on an ISA 3.0
19023 machine. Include rs6000-modes.h to share the fractional values
19024 between genmodes* and the rest of the compiler.
19025 (IFmode): Likewise.
19026 (KFmode): Likewise.
19027 (TFmode): Likewise.
19028 * config/rs6000/rs6000-modes.h: New file.
19029 * config/rs6000/rs6000.c (rs6000_debug_reg_global): Change the
19030 meaning of rs6000_long_double_size so that 126..128 selects an
19031 appropriate 128-bit floating point type.
19032 (rs6000_option_override_internal): Likewise.
19033 * config/rs6000/rs6000.h (toplevel): Include rs6000-modes.h.
19034 (TARGET_LONG_DOUBLE_128): Change the meaning of
19035 rs6000_long_double_size so that 126..128 selects an appropriate
19036 128-bit floating point type.
19037 (LONG_DOUBLE_TYPE_SIZE): Update comment.
19038 * config/rs6000/rs6000.md (trunciftf2): Correct the modes of the
19039 source and destination to match the standard usage.
19040 (truncifkf2): Likewise.
19041 (copysign<mode>3, IEEE iterator): Rework copysign of float128 on
19042 ISA 2.07 to use an explicit clobber, instead of passing in a
19043 temporary.
19044 (copysign<mode>3_soft): Likewise.
19045
19046 2018-06-18 David Malcolm <dmalcolm@redhat.com>
19047
19048 * tree-vect-data-refs.c (vect_analyze_data_ref_dependences):
19049 Replace dump_printf_loc call with DUMP_VECT_SCOPE.
19050 (vect_slp_analyze_instance_dependence): Likewise.
19051 (vect_enhance_data_refs_alignment): Likewise.
19052 (vect_analyze_data_refs_alignment): Likewise.
19053 (vect_slp_analyze_and_verify_instance_alignment
19054 (vect_analyze_data_ref_accesses): Likewise.
19055 (vect_prune_runtime_alias_test_list): Likewise.
19056 (vect_analyze_data_refs): Likewise.
19057 * tree-vect-loop-manip.c (vect_update_inits_of_drs): Likewise.
19058 * tree-vect-loop.c (vect_determine_vectorization_factor): Likewise.
19059 (vect_analyze_scalar_cycles_1): Likewise.
19060 (vect_get_loop_niters): Likewise.
19061 (vect_analyze_loop_form_1): Likewise.
19062 (vect_update_vf_for_slp): Likewise.
19063 (vect_analyze_loop_operations): Likewise.
19064 (vect_analyze_loop): Likewise.
19065 (vectorizable_induction): Likewise.
19066 (vect_transform_loop): Likewise.
19067 * tree-vect-patterns.c (vect_pattern_recog): Likewise.
19068 * tree-vect-slp.c (vect_analyze_slp): Likewise.
19069 (vect_make_slp_decision): Likewise.
19070 (vect_detect_hybrid_slp): Likewise.
19071 (vect_slp_analyze_operations): Likewise.
19072 (vect_slp_bb): Likewise.
19073 * tree-vect-stmts.c (vect_mark_stmts_to_be_vectorized): Likewise.
19074 (vectorizable_bswap): Likewise.
19075 (vectorizable_call): Likewise.
19076 (vectorizable_simd_clone_call): Likewise.
19077 (vectorizable_conversion): Likewise.
19078 (vectorizable_assignment): Likewise.
19079 (vectorizable_shift): Likewise.
19080 (vectorizable_operation): Likewise.
19081 * tree-vectorizer.h (DUMP_VECT_SCOPE): New macro.
19082
19083 2018-06-18 Martin Sebor <msebor@redhat.com>
19084
19085 PR tree-optimization/81384
19086 * builtin-types.def (BT_FN_SIZE_CONST_STRING_SIZE): New.
19087 * builtins.c (expand_builtin_strnlen): New function.
19088 (expand_builtin): Call it.
19089 (fold_builtin_n): Avoid setting TREE_NO_WARNING.
19090 * builtins.def (BUILT_IN_STRNLEN): New.
19091 * calls.c (maybe_warn_nonstring_arg): Handle BUILT_IN_STRNLEN.
19092 Warn for bounds in excess of maximum object size.
19093 * tree-ssa-strlen.c (maybe_set_strlen_range): Return tree representing
19094 single-value ranges. Handle strnlen.
19095 (handle_builtin_strlen): Handle strnlen.
19096 (strlen_check_and_optimize_stmt): Same.
19097 * doc/extend.texi (Other Builtins): Document strnlen.
19098
19099 2018-06-18 Maya Rashish <coypu@sdf.org>
19100
19101 * config/alpha/openbsd.h (TARGET_DEFAULT): Define.
19102 (LINK_SPEC, STARTFILE_SPEC, ENDFILE_SPEC): Likewise.
19103 (INTMAX_TYPE, UINTMAX_TYPE, WINT_TYPE): Likewise.
19104
19105 * config/alpha/elf.h (STARTFILE_SPEC, ENDFILE_SPEC): Move from
19106 here to ...
19107 * config/alpha/linux.h (STARTFILE_SPEC, ENDFILE_SPEC): Here.
19108
19109 2018-06-18 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
19110
19111 * tree.c (escaped_string::escape): Replace cast to char * by
19112 const_cast<char *> (unescaped).
19113
19114 2018-06-18 Nick Clifton <nickc@redhat.com>
19115
19116 PR 84195
19117 * tree.c (escaped_string): New class. Converts an unescaped
19118 string into its escaped equivalent.
19119 (warn_deprecated_use): Use the new class to convert the
19120 deprecation message, if present.
19121 (test_escaped_strings): New self test.
19122 (test_c_tests): Add test_escaped_strings.
19123 * doc/extend.texi (deprecated): Add a note that the
19124 deprecation message is affected by the -fmessage-length
19125 option, and that control characters will be escaped.
19126 (#pragma GCC error): Document this pragma.
19127 (#pragma GCC warning): Likewise.
19128 * doc/invoke.texi (-fmessage-length): Document this option's
19129 effect on the #warning and #error preprocessor directives and
19130 the deprecated attribute.
19131
19132 2018-06-18 Eric Botcazou <ebotcazou@adacore.com>
19133
19134 * tree.c (decl_value_expr_lookup): Revert latest change.
19135 (decl_value_expr_insert): Likewise.
19136
19137 2018-06-17 Eric Botcazou <ebotcazou@adacore.com>
19138
19139 * gimplify.c (nonlocal_vlas): Delete.
19140 (nonlocal_vla_vars): Likewise.
19141 (gimplify_var_or_parm_decl): Do not add debug VAR_DECLs for non-local
19142 referenced VLAs.
19143 (gimplify_body): Do not create and destroy nonlocal_vlas.
19144 * tree-nested.c: Include diagnostic.h.
19145 (use_pointer_in_frame): Tweak.
19146 (lookup_field_for_decl): Add assertion and declare the transformation.
19147 (convert_nonlocal_reference_op) <PARM_DECL>: Rework and issue an
19148 internal error when the reference is in a wrong context. Do not
19149 create a debug decl by default.
19150 (note_nonlocal_block_vlas): Delete.
19151 (convert_nonlocal_reference_stmt) <GIMPLE_BIND>: Do not call it.
19152 (convert_local_reference_op) <PARM_DECL>: Skip the frame decl. Do not
19153 create a debug decl by default.
19154 (convert_gimple_call) <GIMPLE_CALL>: Issue an internal error when the
19155 call is in a wrong context.
19156 (fixup_vla_decls): New function.
19157 (finalize_nesting_tree_1): Adjust comment. Call fixup_vla_decls if no
19158 debug variables were created.
19159 * tree.c (decl_value_expr_lookup): Add checking assertion.
19160 (decl_value_expr_insert): Likewise.
19161
19162 2018-06-16 Kugan Vivekanandarajah <kuganv@linaro.org>
19163
19164 PR middle-end/82479
19165 * ipa-fnsummary.c (will_be_nonconstant_expr_predicate): Handle CALL_EXPR.
19166 * tree-scalar-evolution.c (interpret_expr): Likewise.
19167 (expression_expensive_p): Likewise.
19168 * tree-ssa-loop-ivopts.c (contains_abnormal_ssa_name_p): Likewise.
19169 * tree-ssa-loop-niter.c (number_of_iterations_popcount): New.
19170 (number_of_iterations_exit_assumptions): Use number_of_iterations_popcount.
19171 (ssa_defined_by_minus_one_stmt_p): New.
19172
19173 2018-06-16 Kugan Vivekanandarajah <kuganv@linaro.org>
19174
19175 PR middle-end/64946
19176 * cfgexpand.c (expand_debug_expr): Hande ABSU_EXPR.
19177 * config/i386/i386.c (ix86_add_stmt_cost): Likewise.
19178 * dojump.c (do_jump): Likewise.
19179 * expr.c (expand_expr_real_2): Check operand type's sign.
19180 * fold-const.c (const_unop): Handle ABSU_EXPR.
19181 (fold_abs_const): Likewise.
19182 * gimple-pretty-print.c (dump_unary_rhs): Likewise.
19183 * gimple-ssa-backprop.c (backprop::process_assign_use): Likesie.
19184 (strip_sign_op_1): Likesise.
19185 * match.pd: Add new pattern to generate ABSU_EXPR.
19186 * optabs-tree.c (optab_for_tree_code): Handle ABSU_EXPR.
19187 * tree-cfg.c (verify_gimple_assign_unary): Likewise.
19188 * tree-eh.c (operation_could_trap_helper_p): Likewise.
19189 * tree-inline.c (estimate_operator_cost): Likewise.
19190 * tree-pretty-print.c (dump_generic_node): Likewise.
19191 * tree-vect-patterns.c (vect_recog_sad_pattern): Likewise.
19192 * tree.def (ABSU_EXPR): New.
19193
19194 2018-06-16 Jakub Jelinek <jakub@redhat.com>
19195
19196 PR middle-end/86095
19197 * common.opt (Wunsafe-loop-optimizations): Add Ignore, remove Var,
19198 documented as preserved for backward compatibility only.
19199 * doc/invoke.texi: Remove -Wunsafe-loop-optimizations documentation.
19200
19201 PR rtl-optimization/86108
19202 * bb-reorder.c (create_forwarder_block): Renamed to ...
19203 (create_eh_forwarder_block): ... this. Split OLD_BB after labels and
19204 jump from new landing pad to the second part.
19205 (sjlj_fix_up_crossing_landing_pad, dw2_fix_up_crossing_landing_pad):
19206 Adjust callers.
19207
19208 2018-06-15 Jakub Jelinek <jakub@redhat.com>
19209
19210 PR middle-end/85878
19211 * expr.c (expand_assignment): Remove now redundant COMPLEX_MODE_P
19212 check from first store_expr, use to_mode instead of GET_MODE (to_rtx).
19213 Only call store_expr for halves if the mode is the same.
19214
19215 PR middle-end/86123
19216 * match.pd ((X / Y) == 0 -> X < Y): Don't transform complex divisions.
19217 Fix up comment formatting.
19218
19219 2018-06-15 Bernd Edlinger <bernd.edlinger@hotmail.de>
19220
19221 * typed-splay-tree.h (typed_splay_tree::remove): New function.
19222 (typed_splay_tree::closure,
19223 typed_splay_tree::inner_foreach_fn, typed_splay_tree::m_inner): Deleted.
19224 (typed_splay_tree::typed_splay_tree,
19225 typed_splay_tree::operator =): Declared private.
19226 (typed_splay_tree::splay_tree_key, typed_splay_tree::splay_tree_value,
19227 typed_splay_tree::splay_tree_node_s, typed_splay_tree::KDEL,
19228 typed_splay_tree::VDEL, typed_splay_tree::splay_tree_delete_helper,
19229 typed_splay_tree::rotate_left, typed_splay_tree::rotate_right,
19230 typed_splay_tree::splay_tree_splay,
19231 typed_splay_tree::splay_tree_foreach_helper,
19232 typed_splay_tree::splay_tree_insert,
19233 typed_splay_tree::splay_tree_remove,
19234 typed_splay_tree::splay_tree_lookup,
19235 typed_splay_tree::splay_tree_predecessor,
19236 typed_splay_tree::splay_tree_successor,
19237 typed_splay_tree::splay_tree_min,
19238 typed_splay_tree::splay_tree_max): Took over from splay-tree.c/.h.
19239 (typed_splay_tree::root, typed_splay_tree::comp,
19240 typed_splay_tree::delete_key,
19241 typed_splay_tree::delete_value): New data members.
19242 * typed-splay-tree.c (selftest::test_str_to_int): Add a test for
19243 typed_splay_tree::remove.
19244
19245 2018-06-15 Matthew Fortune <matthew.fortune@mips.com>
19246
19247 * config/mips/mips.h (ASM_SPEC): Pass through -mcrc, -mno-crc,
19248 -mginv and -mno-ginv to the assembler.
19249 * config/mips/mips.opt (-mcrc): New option.
19250 (-mginv): Likewise.
19251 * doc/invoke.text (-mcrc): Document.
19252 (-mginv): Likewise.
19253
19254 2018-06-15 Nick Clifton <nickc@redhat.com>
19255
19256 PR 84195
19257 * tree.c (escaped_string): New class. Converts an unescaped
19258 string into its escaped equivalent.
19259 (warn_deprecated_use): Use the new class to convert the
19260 deprecation message, if present.
19261 (test_escaped_strings): New self test.
19262 (test_c_tests): Add test_escaped_strings.
19263 * doc/extend.texi (deprecated): Add a note that the
19264 deprecation message is affected by the -fmessage-length
19265 option, and that control characters will be escaped.
19266 (#pragma GCC error): Document this pragma.
19267 (#pragma GCC warning): Likewise.
19268 * doc/invoke.texi (-fmessage-length): Document this option's
19269 effect on the #warning and #error preprocessor directives and
19270 the deprecated attribute.
19271
19272 2018-06-15 Richard Biener <rguenther@suse.de>
19273
19274 * tree-vect-slp.c (vect_slp_bb): Dump MSG_OPTIMIZED_LOCATIONS
19275 here, also noting vector size used.
19276 * tree-vectorizer.c (vectorize_loops): Adjust. Note vector
19277 size used in MSG_OPTIMIZED_LOCATIONS dump.
19278 (pass_slp_vectorize::execute): Adjust.
19279
19280 2018-06-15 Claudiu Zissulescu <claziss@synopsys.com>
19281
19282 PR target/85968
19283 * config/arc/arc.c (arc_return_address_register): Fix
19284 if-condition.
19285
19286 2018-06-15 Richard Biener <rguenther@suse.de>
19287
19288 PR middle-end/86159
19289 * tree-cfg.c (gimplify_build3): Do not strip sign conversions,
19290 leave useless conversion stripping to force_gimple_operand_gsi.
19291 (gimplify_build2): Likewise.
19292 (gimplify_build1): Likewise.
19293
19294 2018-06-15 Richard Biener <rguenther@suse.de>
19295
19296 PR middle-end/86076
19297 * tree-cfg.c (move_stmt_op): unshare invariant addresses
19298 before adjusting their block.
19299
19300 2018-06-15 Sebastian Huber <sebastian.huber@embedded-brains.de>
19301
19302 * config.gcc (riscv*-*-elf* | riscv*-*-rtems*): Use custom
19303 multilibs for *-*-rtems*.
19304 * config/riscv/t-rtems: New file.
19305
19306 2018-06-14 Jakub Jelinek <jakub@redhat.com>
19307
19308 PR middle-end/86122
19309 * match.pd ((A +- CST1) +- CST2): Punt if last resort
19310 unsigned_type_for returns NULL.
19311
19312 PR target/85945
19313 * lower-subreg.c (find_decomposable_subregs): Don't decompose float
19314 subregs of multi-word pseudos unless the float mode has word size.
19315
19316 2018-06-14 Richard Biener <rguenther@suse.de>
19317
19318 PR middle-end/86139
19319 * tree-vect-generic.c (build_word_mode_vector_type): Remove
19320 duplicate and harmful type_hash_canon.
19321 * tree.c (type_hash_canon): Assert we didn't find ourselves.
19322
19323 2018-06-14 Richard Biener <rguenther@suse.de>
19324
19325 PR ipa/86124
19326 * tree-ssa-struct-alias.c (create_variable_info_for): Handle
19327 NULL cgraph_node.
19328
19329 2018-06-14 Sebastian Huber <sebastian.huber@embedded-brains.de>
19330
19331 * config/rtems.h (STDINT_LONG32): Define.
19332
19333 2018-06-13 Matthew Fortune <matthew.fortune@mips.com>
19334 Prachi Godbole <prachi.godbole@imgtec.com>
19335
19336 * config/mips/mips-cpus.def: Define P6600.
19337 * config/mips/mips-tables.opt: Regenerate.
19338 * config/mips/mips.c (mips_ucbranch_type): New enum.
19339 (mips_rtx_cost_data): Add support for P6600.
19340 (mips_issue_rate): Likewise.
19341 (mips_multipass_dfa_lookahead): Likewise.
19342 (mips_avoid_hazard): Likewise.
19343 (mips_reorg_process_insns): Likewise.
19344 (mips_classify_branch_p6600): New function.
19345 * config/mips/mips.h (TUNE_P6600): New define.
19346 (MIPS_ISA_LEVEL_SPEC): Infer mips64r6 from p6600.
19347 (ENABLE_LD_ST_PAIRS): Enable load/store bonding for p6600.
19348 * config/mips/mips.md: Include p6600.md.
19349 (processor): Add p6600.
19350 * config/mips/p6600.md: New file.
19351 * doc/invoke.texi: Add p6600 to supported architectures.
19352
19353 2018-06-13 Martin Sebor <msebor@redhat.com>
19354
19355 PR tree-optimization/86114
19356 * gimple-fold.c (gimple_fold_builtin_strlen): Only handle LHS
19357 of integer types.
19358 * tree-ssa-strlen.c (maybe_set_strlen_range): Same.
19359
19360 2018-06-13 Richard Biener <rguenther@suse.de>
19361
19362 * tree-vect-patterns.c (vect_recog_vector_vector_shift_pattern):
19363 Properly set vector type of the intermediate stmt.
19364 * tree-vect-stmts.c (vectorizable_operation): The destination
19365 var always has vectype_out type.
19366
19367 2018-06-13 Jeff Law <law@redhat.com>
19368
19369 * config/rl78/rl78.c (move_elim_pass): Use TDF_NONE rather than
19370 integer 0 for argument to print_rtl_with_bb.
19371 (rl78_reorg): Likewise.
19372
19373 2018-06-13 David Malcolm <dmalcolm@redhat.com>
19374
19375 * config/arc/arc.c (hwloop_optimize): Strengthen local "end_label"
19376 from rtx to rtx_insn *.
19377 * config/bfin/bfin.c (hwloop_optimize): Likewise for local
19378 "label".
19379 (add_sched_insns_for_speculation): Likewise for local "target",
19380 converting usage of JUMP_LABEL to JUMP_LABEL_AS_INSN.
19381 * config/c6x/c6x.c (reorg_split_calls): Strengthen param "call_labels"
19382 from rtx_insn ** to rtx_code_label **.
19383 (reorg_emit_nops): Likewise.
19384 (c6x_reorg): Likewise for local "call_labels".
19385 * config/sh/sh-protos.h (get_dest_uid): Strengthen 1st param from
19386 rtx to rtx_insn *.
19387 * config/sh/sh.c (dump_table): Strengthen local "lab" from rtx to
19388 rtx_code_label *, adding safe_as_a <rtx_code_label *> casts to
19389 the loops over LABEL_REFS.
19390 (fixup_addr_diff_vecs): Add as_a <rtx_insn *> to usage of
19391 braf_label.
19392 (barrier_align): Convert usage of JUMP_LABEL to JUMP_LABEL_AS_INSN.
19393 (get_dest_uid): Strengthen param "label" from rtx to rtx_insn *.
19394 (split_branches): Strengthen local "olabel" from rtx to
19395 rtx_insn *, adding a safe_as_a cast.
19396 * emit-rtl.c (next_real_insn): Strengthen param from "rtx"
19397 to "rtx_insn *".
19398 (add_insn_after): Likewise for first two params.
19399 (add_insn_before): Likewise.
19400 (remove_insn): Likewise for param.
19401 (emit_pattern_before_noloc): Likewise for second and third params.
19402 (emit_jump_insn_before_noloc): Convert NULL_RTX to NULL.
19403 (emit_call_insn_before_noloc): Likewise.
19404 (emit_debug_insn_before_noloc): Strengthen "before" param from "rtx"
19405 to "rtx_insn *".
19406 (emit_barrier_before): Likewise.
19407 (emit_label_before): Strengthen "label" param from "rtx" to
19408 "rtx_code_label *". Strengthen "before" param from "rtx" to
19409 "rtx_insn *".
19410 (emit_insn_after_1): Strengthen "after" param from "rtx" to
19411 "rtx_insn *".
19412 (emit_pattern_after_noloc): Likewise.
19413 (emit_insn_after_noloc): Likewise.
19414 (emit_jump_insn_after_noloc): Likewise.
19415 (emit_call_insn_after_noloc): Likewise.
19416 (emit_debug_insn_after_noloc): Likewise.
19417 (emit_barrier_after): Likewise.
19418 (emit_label_after): Likewise for both params.
19419 (emit_pattern_after_setloc): Likewise for "after" param. Convert
19420 "loc" param from "int" to "location_t".
19421 (emit_insn_after_setloc): Likewise.
19422 (emit_jump_insn_after_setloc): Likewise.
19423 (emit_call_insn_after_setloc): Likewise.
19424 (emit_debug_insn_after_setloc): Likewise.
19425 (emit_pattern_before_setloc): Likewise for "before" param. Convert
19426 "loc" param from "int" to "location_t".
19427 (emit_pattern_before): Convert NULL_RTX to NULL.
19428 (emit_insn_before_setloc): Convert "loc" param from "int" to
19429 "location_t".
19430 (emit_jump_insn_before_setloc): Likewise.
19431 (emit_call_insn_before_setloc): Likewise.
19432 (emit_debug_insn_before_setloc): Strengthen "before" param from rtx to
19433 rtx_insn *. Convert "loc" param from "int" to "location_t".
19434 * rtl.h (emit_insn_before_setloc, emit_jump_insn_before_setloc,
19435 emit_call_insn_before_setloc, emit_debug_insn_before_setloc):
19436 Convert 3rd param from "int" to "location_t".
19437 (emit_barrier_before, emit_barrier_after, next_real_insn):
19438 Strengthen param from rtx to rtx_insn *.
19439 (emit_label_before): Strengthen 1st param from "rtx" to
19440 "rtx_code_label *". Strengthen 2nd param from "rtx" to
19441 "rtx_insn *".
19442 (emit_insn_after_noloc, emit_jump_insn_after_noloc,
19443 emit_call_insn_after_noloc, emit_debug_insn_after_noloc):
19444 Strengthen 2nd param from "rtx" to "rtx_insn *".
19445 (emit_insn_after_setloc, emit_jump_insn_after_setloc)
19446 emit_call_insn_after_setloc, emit_debug_insn_after_setloc):
19447 Likewise. Convert 3rd param from "int" to "location_t".
19448 (emit_label_after): Strengthen 1st param from "rtx" to
19449 "rtx_code_label *".
19450 (next_real_insn, remove_insn): Strengthen param from "rtx" to
19451 "rtx_insn *".
19452 (add_insn_before, add_insn_after): Strengthen 1st and 2nd params
19453 from "rtx" to "rtx_insn *".
19454
19455 2018-06-13 Jan Hubicka <hubicka@gcc.gnu.org>
19456
19457 * cgraph.c (cgraph_node::get_untransformed_body): Dump function
19458 bodies streamed in with -Q.
19459 * dumpfile.c (dump_files): Add lto-stream-out dump file.
19460 * dumpfile.h (tree_dump_index): Add lto_stream_out.
19461 * gimple-streamer-out.c: Include gimple-pretty-print.h
19462 (output_bb): Dump stmts streamed.
19463 * lto-section-out.c: Include print-tree.h
19464 (lto_begin_section): Dump sections created.
19465 (lto_output_decl_index): Dump decl encoded.
19466 * lto-streamer-out.c: Include print-tree.h
19467 (create_output_block): Dump output block created.
19468 (DFS::DFS_write_tree_body): Dump DFS SCCs streamed.
19469 (output_function): Dump function output.
19470 (output_constructor): Dump constructor streamed.
19471 (write_global_stream): Output indexes encoded.
19472 (produce_asm_for_decls): Dump streams encoded.
19473 * lto-streamer.c (streamer_dump_file): New global var.
19474 * lto-streamer.h (streamer_dump_file): Declare.
19475 * passes.c (ipa_write_summaries): Initialize streamer dump.
19476 * varpool.c (varpool_node::get_constructor): Dump constructors streamed
19477 in.
19478
19479 2018-06-13 Eric Botcazou <ebotcazou@adacore.com>
19480
19481 PR target/86048
19482 * config/i386/winnt.c (i386_pe_seh_cold_init): Do not emit negative
19483 offsets for register save directives. Emit a second batch of save
19484 directives, if need be, when the function accesses prior frames.
19485
19486 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
19487
19488 * config/arc/fpu.md (fmasf4): Force operand to register.
19489 (fnmasf4): Likewise.
19490
19491 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
19492
19493 * config/arc/arc-protos.h (arc_pad_return): Remove.
19494 * config/arc/arc.c (machine_function): Remove force_short_suffix
19495 and size_reason.
19496 (arc_print_operand): Adjust printing of '&'.
19497 (arc_verify_short): Remove conditional printing of short suffix.
19498 (arc_final_prescan_insn): Remove reference to size_reason.
19499 (pad_return): New function.
19500 (arc_reorg): Call pad_return.
19501 (arc_pad_return): Remove.
19502 (arc_init_machine_status): Remove reference to force_short_suffix.
19503 * config/arc/arc.md (vunspec): Add VUNSPEC_ARC_BLOCKAGE.
19504 (attr length): When attribute iscompact is true force to 2
19505 regardless; in the case of maybe check if we want to force the
19506 instruction to have 4 bytes length.
19507 (nopv): Change it to generate 4 byte long nop as well.
19508 (blockage): New pattern.
19509 (simple_return): Remove call to arc_pad_return.
19510 (p_return_i): Likewise.
19511
19512 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
19513
19514 * config/arc/elf.h (LINK_GCC_C_SEQUENCE_SPEC): Define.
19515
19516 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
19517
19518 * config/arc/builtins.def (SYNC): SYNC instruction is valid on all
19519 ARC cores.
19520
19521 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
19522
19523 * config/arc/arc.c (atomic_exchangesi): EX instruction is default
19524 for ARC700 and ARCv2.
19525
19526 2018-06-13 Chenghua Xu <paul.hua.gm@gmail.com>
19527
19528 PR target/86076
19529 * config/mips/loongson.md (vec_setv4hi): Gen_lowpart for
19530 operands[2] instead of operands[1].
19531
19532
19533 2018-06-12 Richard Sandiford <richard.sandiford@linaro.org>
19534
19535 * lra-constraints.c (simplify_operand_subreg): In the paradoxical
19536 case, check whether the outer register overlaps an unallocatable
19537 register, not just whether it fits the required class.
19538
19539 2018-06-12 Richard Sandiford <richard.sandiford@linaro.org>
19540
19541 * poly-int.h (can_div_trunc_p): Add new overload in which all values
19542 are poly_ints.
19543 * alias.c (get_addr): Extend CONST_INT handling to poly_int_rtx_p.
19544 (memrefs_conflict_p): Likewise.
19545 (init_alias_analysis): Likewise.
19546 * cfgexpand.c (expand_debug_expr): Likewise.
19547 * combine.c (combine_simplify_rtx, force_int_to_mode): Likewise.
19548 * cse.c (fold_rtx): Likewise.
19549 * explow.c (adjust_stack, anti_adjust_stack): Likewise.
19550 * expr.c (emit_block_move_hints): Likewise.
19551 (clear_storage_hints, push_block, emit_push_insn): Likewise.
19552 (store_expr_with_bounds, reduce_to_bit_field_precision): Likewise.
19553 (emit_group_load_1): Use rtx_to_poly_int64 for group offsets.
19554 (emit_group_store): Likewise.
19555 (find_args_size_adjust): Use strip_offset. Use rtx_to_poly_int64
19556 to read the PRE/POST_MODIFY increment.
19557 * calls.c (store_one_arg): Use strip_offset.
19558 * rtlanal.c (rtx_addr_can_trap_p_1): Extend CONST_INT handling to
19559 poly_int_rtx_p.
19560 (set_noop_p): Use rtx_to_poly_int64 for the elements selected
19561 by a VEC_SELECT.
19562 * simplify-rtx.c (avoid_constant_pool_reference): Use strip_offset.
19563 (simplify_binary_operation_1): Extend CONST_INT handling to
19564 poly_int_rtx_p.
19565 * var-tracking.c (compute_cfa_pointer): Take a poly_int64 rather
19566 than a HOST_WIDE_INT.
19567 (hard_frame_pointer_adjustment): Change from HOST_WIDE_INT to
19568 poly_int64.
19569 (adjust_mems, add_stores): Update accodingly.
19570 (vt_canonicalize_addr): Track polynomial offsets.
19571 (emit_note_insn_var_location): Likewise.
19572 (vt_add_function_parameter): Likewise.
19573 (vt_initialize): Likewise.
19574
19575 2018-06-12 Jeff Law <law@redhat.com>
19576
19577 * config.gcc (alpha*-*-freebsd*): Remove.
19578 * config/alpha/freebsd.h: Remove.
19579
19580 2018-06-12 David Malcolm <dmalcolm@redhat.com>
19581
19582 PR other/69968
19583 * spellcheck-tree.c (levenshtein_distance): Rename to...
19584 (get_edit_distance): ...this, and update for underlying renaming.
19585 * spellcheck-tree.h (levenshtein_distance): Rename to...
19586 (get_edit_distance): ...this.
19587 * spellcheck.c (levenshtein_distance): Rename to...
19588 (get_edit_distance): ...this. Convert from Levenshtein distance
19589 to Damerau-Levenshtein distance by supporting transpositions of
19590 adjacent characters. Rename "v1" to "v_next" and "v0" to
19591 "v_one_ago".
19592 (selftest::levenshtein_distance_unit_test_oneway): Rename to...
19593 (selftest::test_edit_distance_unit_test_oneway): ...this, and
19594 update for underlying renaming.
19595 (selftest::levenshtein_distance_unit_test): Rename to...
19596 (selftest::test_get_edit_distance_unit): ...this, and update for
19597 underlying renaming.
19598 (selftest::test_find_closest_string): Add example from PR 69968
19599 where transposition helps
19600 (selftest::test_metric_conditions): Update for renaming.
19601 (selftest::test_metric_conditions): Likewise.
19602 (selftest::spellcheck_c_tests): Likewise.
19603 * spellcheck.h (levenshtein_distance): Rename both overloads to...
19604 (get_edit_distance): ...this.
19605 (best_match::consider): Update for renaming.
19606
19607 2018-06-12 Martin Sebor <msebor@redhat.com>
19608
19609 PR tree-optimization/85259
19610 * builtins.c (compute_objsize): Handle constant offsets.
19611 * gimple-ssa-warn-restrict.c (maybe_diag_offset_bounds): Return
19612 true iff a warning has been issued.
19613 * gimple.h (gimple_nonartificial_location): New function.
19614 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Call
19615 gimple_nonartificial_location and handle -Wno-system-headers.
19616 (handle_builtin_stxncpy): Same.
19617
19618 2018-06-12 Martin Sebor <msebor@redhat.com>
19619
19620 PR c/85931
19621 * fold-const.c (operand_equal_p): Handle SAVE_EXPR.
19622
19623 2018-06-12 Will Schmidt <will_schmidt@vnet.ibm.com>
19624
19625 * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Add
19626 BUILTIN_VEC_XST entries for pointer to double and long long.
19627
19628 2018-06-12 H.J. Lu <hongjiu.lu@intel.com>
19629
19630 PR target/85990
19631 * config/i386/gnu-user.h (TARGET_THREAD_SPLIT_STACK_OFFSET):
19632 Update comments.
19633 * config/i386/gnu-user64.h (TARGET_THREAD_SPLIT_STACK_OFFSET):
19634 Likewise.
19635
19636 2018-06-12 Martin Liska <mliska@suse.cz>
19637
19638 * doc/options.texi: Document IntegerRange.
19639
19640 2018-06-12 Martin Liska <mliska@suse.cz>
19641
19642 * config/i386/i386.opt: Make MPX-related options as Deprecated.
19643 * opt-functions.awk: Handle Deprecated flag.
19644 * opts-common.c (decode_cmdline_option): Handle cl_deprecated
19645 and report error.
19646 (read_cmdline_option): Report warning for a deprecated option.
19647 * opts.h (struct cl_option): Add new field cl_deprecated.
19648 (CL_ERR_DEPRECATED): New.
19649
19650 2018-06-12 Martin Liska <mliska@suse.cz>
19651
19652 * doc/options.texi: Document Deprecated option flag.
19653
19654 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
19655
19656 * config/arc/arc-arch.h (arc_extras): New enum.
19657 (arc_cpu_t):Add field extra.
19658 (arc_cpu_types): Consider the extras.
19659 * config/arc/arc-cpus.def: Add extras info.
19660 * config/arc/arc-opts.h (processor_type): Consider extra field.
19661 * config/arc/arc.c (arc_override_options): Handle extra field.
19662
19663 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
19664
19665 * config/arc/arc-arch.h: Update ARC_OPTX macro.
19666 * config/arc/arc-options.def (ARC_OPTX): Introduce a new doc
19667 field.
19668 * config/arc/arc.c (arc_init): Update pic warning.
19669 (irq_range): Update irq range parsing warnings.
19670 (arc_override_options): Update various warning messages.
19671 (arc_handle_aux_attribute): Likewise.
19672
19673 2018-06-12 Robert Suchanek <robert.suchanek@mips.com>
19674
19675 * config/mips/i6400.md (i6400_fpu_fadd): Remove frint.
19676
19677 2018-06-12 Jozef Lawrynowicz <jozef.l@mittosystems.com>
19678
19679 * doc/sourcebuild.texi: Document usage of line number 0 in verify
19680 compiler messages directives.
19681
19682 2018-06-12 Matthew Fortune <mfortune@gmail.com>
19683
19684 * config/mips/mips-cpus.def: New MIPS_CPU for i6500.
19685 * config/mips/mips-tables.opt: Regenerate.
19686 * config/mips/mips.h (MIPS_ISA_LEVEL_SPEC): Mark i6500 as
19687 mips64r6.
19688 * doc/invoke.texi: Document -march=i6500.
19689
19690 2018-06-12 Prachi Godbole <prachi.godbole@imgtec.com>
19691
19692 * config/mips/i6400.md (i6400_gpmuldiv): Remove cpu_unit.
19693 (i6400_gpmul): Add cpu_unit.
19694 (i6400_gpdiv): Likewise.
19695 (i6400_msa_add_d): Update reservations.
19696 (i6400_msa_int_add) Likewise.
19697 (i6400_msa_short_logic3) Likewise.
19698 (i6400_msa_short_logic2) Likewise.
19699 (i6400_msa_short_logic) Likewise.
19700 (i6400_msa_move) Likewise.
19701 (i6400_msa_cmp) Likewise.
19702 (i6400_msa_short_float2) Likewise.
19703 (i6400_msa_div_d) Likewise.
19704 (i6400_msa_long_logic1) Likewise.
19705 (i6400_msa_long_logic2) Likewise.
19706 (i6400_msa_mult) Likewise.
19707 (i6400_msa_long_float2) Likewise.
19708 (i6400_msa_long_float4) Likewise.
19709 (i6400_msa_long_float5) Likewise.
19710 (i6400_msa_long_float8) Likewise.
19711 (i6400_fpu_fadd): Include frint type.
19712 (i6400_fpu_store): New define_insn_reservation.
19713 (i6400_fpu_load): Likewise.
19714 (i6400_fpu_move): Likewise.
19715 (i6400_fpu_fcmp): Likewise.
19716 (i6400_fpu_fmadd): Likewise.
19717 (i6400_int_mult): Include imul3nc type and update reservation.
19718 (i6400_int_div): Include idiv3 type and update reservation.
19719 (i6400_int_load): Update to check type not move_type.
19720 (i6400_int_store): Likewise.
19721 (i6400_int_prefetch): Set zero latency.
19722
19723 2018-06-12 Eric Botcazou <ebotcazou@adacore.com>
19724
19725 * gcc.c: Document new %@{...} sequence.
19726 (LINK_COMMAND_SPEC): Use it for the -L switches.
19727 (cpp_unique_options): Use it for the -I switches.
19728 (at_file_argbuf): New global variable.
19729 (in_at_file): Likewise.
19730 (alloc_args): Create at_file_argbuf.
19731 (clear_args): Truncate at_file_argbuf.
19732 (store_arg): If in_at_file, push the argument onto at_file_argbuf.
19733 (open_at_file): New function.
19734 (close_at_file): Likewise.
19735 (create_at_file): Delete.
19736 (do_spec_1) <'i'>: Use open_at_file/close_at_file.
19737 <'o'>: Likewise.
19738 <'@'>: New case.
19739 (validate_switches_from_spec): Deal with %@{...} sequence.
19740 (validate_switches): Likewise.
19741 (driver::finalize): Call clear_args.
19742
19743 2018-06-11 Rasmus Villemoes <rasmus.villemoes@prevas.dk>
19744
19745 * config/vx-common.h (USE_TM_CLONE_REGISTRY): #define to 0.
19746
19747 2018-06-11 Martin Sebor <msebor@redhat.com>
19748
19749 * doc/invoke.texi (-Wall): List -Wc++17-compat.
19750 (Wno-class-memaccess): Add @opindex.
19751 (Wno-templates, Wno-multiple-inheritance): Same.
19752 (Wno-virtual-inheritance, Wno-namespaces): Same.
19753 (Wno-pedantic, Wno-chkp, Wcoverage-mismatch): Same.
19754 (Wno-format-overflow, Wno-format-truncation): Same.
19755 (Wno-unused-local-typedefs, Walloc-size-larger-than): Same.
19756 (Wno-alloc-size-larger-than, Wframe-larger-than): Same
19757 (Wno-stack-usage, Wno-c++-compat, Wno-c++11-compat): Same.
19758 (Wno-c++14-compat, Wno-c++17-compat, Wno-openmp-simd): Same.
19759 (Wno-unsuffixed-float-constants, Wno-addr-space-convert): Same.
19760 (Wno-misspelled-isr): Same.
19761
19762 2018-06-11 Martin Sebor <msebor@redhat.com>
19763
19764 * PR tree-optimization/86083
19765 * tree-ssa-strlen.c (handle_char_store): Use tree_expr_nonzero_p.
19766
19767 2018-06-11 Zhouyi Zhou <zhouzhouyi@gmail.com>
19768
19769 * tree-eh.c (lower_eh_constructs_2): Add a comma to comment.
19770
19771 2018-06-11 Segher Boessenkool <segher@kernel.crashing.org>
19772
19773 PR target/85755
19774 * config/rs6000/rs6000.md (*movdi_internal32): Put constraint modifiers
19775 on the correct operand.
19776 (*movdi_internal64): Ditto.
19777
19778 2018-06-11 Martin Liska <mliska@suse.cz>
19779
19780 PR tree-optimization/86089
19781 * tree-ssa-strlen.c (get_string_length): Move back removed hunk.
19782
19783 2018-06-11 Julia Koval <julia.koval@intel.com>
19784
19785 * config/i386/vaesintrin.h (_mm_aesdec_epi128, _mm_aesdeclast_epi128)
19786 _mm_aesenc_epi128, _mm_aesenclast_epi128: Remove.
19787 * config/i386/vpclmulqdqintrin.h (_mm_clmulepi64_epi128): Remove.
19788
19789 2018-06-11 Olivier Hainque <hainque@adacore.com>
19790
19791 * dwarf2out.c (gen_compile_unit_die): Fallout to DW_LANG_Ada83
19792 for Ada with strict dwarf2.
19793
19794 2018-06-08 Peter Bergner <bergner@vnet.ibm.com>
19795
19796 PR target/85755
19797 * config/rs6000/rs6000.c (mem_operand_gpr): Enable PRE_INC and PRE_DEC
19798 addresses.
19799
19800 2018-06-08 Jan Hubicka <hubicka@ucw.cz>
19801
19802 * dumpfile.c (FIRST_ME_AUTO_NUMBERED_DUMP): Bump to 4.
19803
19804 2018-06-08 David Edelsohn <dje.gcc@gmail.com>
19805
19806 * config/rs6000/rs6000.c (rs6000_passes_ieee128): Protect with #if
19807 TARGET_ELF.
19808
19809 2018-06-08 Martin Liska <mliska@suse.cz>
19810
19811 * tree-cfg.h (debug_function): Fix argument type to match
19812 implementation.
19813
19814 2018-06-08 Martin Liska <mliska@suse.cz>
19815
19816 * config/powerpcspe/powerpcspe.c (rs6000_xcoff_visibility):
19817 Remove usage of MPX-related (and removed) fields.
19818 * config/rs6000/rs6000.c (rs6000_xcoff_visibility): Likewise.
19819
19820 2018-06-08 David Malcolm <dmalcolm@redhat.com>
19821
19822 * cfg.c (debug): Use TDF_NONE rather than 0.
19823 * cfghooks.c (debug): Likewise.
19824 * dumpfile.c (DUMP_FILE_INFO): Likewise; also for OPTGROUP.
19825 (struct dump_option_value_info): Convert to...
19826 (struct kv_pair): ...this template type.
19827 (dump_options): Convert to kv_pair<dump_flags_t>; use TDF_NONE
19828 rather than 0.
19829 (optinfo_verbosity_options): Likewise.
19830 (optgroup_options): Convert to kv_pair<optgroup_flags_t>; use
19831 OPTGROUP_NONE.
19832 (gcc::dump_manager::dump_register): Use optgroup_flags_t rather
19833 than int for "optgroup_flags" param.
19834 (dump_generic_expr_loc): Use dump_flags_t rather than int for
19835 "dump_kind" param.
19836 (dump_dec): Likewise.
19837 (dump_finish): Use TDF_NONE rather than 0.
19838 (gcc::dump_manager::opt_info_enable_passes): Use optgroup_flags_t
19839 rather than int for "optgroup_flags" param. Use TDF_NONE rather
19840 than 0. Update for change to option_ptr.
19841 (opt_info_switch_p_1): Convert "optgroup_flags" param from int *
19842 to optgroup_flags_t *. Use TDF_NONE and OPTGROUP_NONE rather than
19843 0. Update for changes to optinfo_verbosity_options and
19844 optgroup_options.
19845 (opt_info_switch_p): Convert optgroup_flags from int to
19846 optgroup_flags_t.
19847 (dump_basic_block): Use dump_flags_t rather than int
19848 for "dump_kind" param.
19849 * dumpfile.h (TDF_ADDRESS, TDF_SLIM, TDF_RAW, TDF_DETAILS,
19850 TDF_STATS, TDF_BLOCKS, TDF_VOPS, TDF_LINENO, TDF_UID)
19851 TDF_STMTADDR, TDF_GRAPH, TDF_MEMSYMS, TDF_RHS_ONLY, TDF_ASMNAME,
19852 TDF_EH, TDF_NOUID, TDF_ALIAS, TDF_ENUMERATE_LOCALS, TDF_CSELIB,
19853 TDF_SCEV, TDF_GIMPLE, TDF_FOLDING, MSG_OPTIMIZED_LOCATIONS,
19854 MSG_MISSED_OPTIMIZATION, MSG_NOTE, MSG_ALL, TDF_COMPARE_DEBUG,
19855 TDF_NONE): Convert from macros to...
19856 (enum dump_flag): ...this new enum.
19857 (dump_flags_t): Update to use enum.
19858 (operator|, operator&, operator~, operator|=, operator&=):
19859 Implement for dump_flags_t.
19860 (OPTGROUP_NONE, OPTGROUP_IPA, OPTGROUP_LOOP, OPTGROUP_INLINE,
19861 OPTGROUP_OMP, OPTGROUP_VEC, OPTGROUP_OTHER, OPTGROUP_ALL):
19862 Convert from macros to...
19863 (enum optgroup_flag): ...this new enum.
19864 (optgroup_flags_t): New typedef.
19865 (operator|, operator|=): Implement for optgroup_flags_t.
19866 (struct dump_file_info): Convert field "alt_flags" to
19867 dump_flags_t. Convert field "optgroup_flags" to
19868 optgroup_flags_t.
19869 (dump_basic_block): Use dump_flags_t rather than int for param.
19870 (dump_generic_expr_loc): Likewise.
19871 (dump_dec): Likewise.
19872 (dump_register): Convert param "optgroup_flags" to
19873 optgroup_flags_t.
19874 (opt_info_enable_passes): Likewise.
19875 * early-remat.c (early_remat::dump_edge_list): Use TDF_NONE rather
19876 than 0.
19877 * gimple-pretty-print.c (debug): Likewise.
19878 * gimple-ssa-store-merging.c (bswap_replace): Likewise.
19879 (merged_store_group::apply_stores): Likewise.
19880 * gimple-ssa-strength-reduction.c (insert_initializers): Likewise.
19881 * gimple.c (verify_gimple_pp): Likewise.
19882 * graphite-poly.c (print_pbb_body): Likewise.
19883 * passes.c (pass_manager::register_one_dump_file): Convert
19884 local "optgroup_flags" to optgroup_flags_t.
19885 * print-tree.c (print_node): Use TDF_NONE rather than 0.
19886 (debug): Likewise.
19887 (debug_body): Likewise.
19888 * tree-pass.h (struct pass_data): Convert field "optgroup_flags"
19889 to optgroup_flags_t.
19890 * tree-pretty-print.c (print_struct_decl): Use TDF_NONE rather
19891 than 0.
19892 * tree-ssa-math-opts.c (convert_mult_to_fma_1): Likewise.
19893 (convert_mult_to_fma): Likewise.
19894 * tree-ssa-reassoc.c (undistribute_ops_list): Likewise.
19895 * tree-ssa-sccvn.c (vn_eliminate): Likewise.
19896 * tree-vect-data-refs.c (dump_lower_bound): Convert param
19897 "dump_kind" to dump_flags_t.
19898
19899 2018-06-08 Segher Boessenkool <segher@kernel.crashing.org>
19900
19901 * config/rs6000/rs6000.c (min, max): Delete.
19902
19903 2018-06-08 Segher Boessenkool <segher@kernel.crashing.org>
19904
19905 * doc/invoke.texi (RS/6000 and PowerPC Options): Delete mention of
19906 -mabi=spe and -mabi=no-spe.
19907
19908 2018-06-08 Martin Liska <mliska@suse.cz>
19909
19910 * ipa-pure-const.c (propagate_pure_const): Use ::get at places
19911 where we expect an existing summary.
19912
19913 2018-06-08 Martin Liska <mliska@suse.cz>
19914
19915 * ipa-inline-analysis.c (simple_edge_hints): Use ::get method.
19916 * ipa-inline.h (estimate_edge_growth): Likewise.
19917
19918 2018-06-08 Martin Liska <mliska@suse.cz>
19919
19920 * cgraph.c (function_version_hasher::hash): Use
19921 cgraph_node::get_uid ().
19922 (function_version_hasher::equal):
19923 * cgraph.h (cgraph_node::get_uid): New method.
19924 * ipa-inline.c (update_caller_keys): Use
19925 cgraph_node::get_uid ().
19926 (update_callee_keys): Likewise.
19927 * ipa-utils.c (searchc): Likewise.
19928 (ipa_reduced_postorder): Likewise.
19929 * lto-cgraph.c (input_node): Likewise.
19930 * passes.c (is_pass_explicitly_enabled_or_disabled): Likewise.
19931 * symbol-summary.h (symtab_insertion): Likewise.
19932 (symtab_removal): Likewise.
19933 (symtab_duplication): Likewise.
19934 * tree-pretty-print.c (dump_function_header): Likewise.
19935 * tree-sra.c (convert_callers_for_node): Likewise.
19936
19937 2018-06-08 Martin Liska <mliska@suse.cz>
19938
19939 * cgraph.c (symbol_table::create_edge): Always assign a new
19940 unique number.
19941 (symbol_table::free_edge): Do not recycle numbers.
19942 * cgraph.h (cgraph_edge::get): New method.
19943 * symbol-summary.h (symtab_removal): Use it.
19944 (symtab_duplication): Likewise.
19945 (call_summary::hashable_uid): Remove.
19946
19947 2018-06-08 Martin Liska <mliska@suse.cz>
19948
19949 * ipa-inline-analysis.c (inline_edge_removal_hook): Remove.
19950 (initialize_growth_caches): Remove.
19951 (free_growth_caches): Likewise.
19952 (do_estimate_edge_time): Use edge_growth_cache.
19953 (do_estimate_edge_size): Likewise.
19954 (do_estimate_edge_hints): Likewise.
19955 * ipa-inline.c (reset_edge_caches): Likewise.
19956 (recursive_inlining): Likewise.
19957 (inline_small_functions): Likewise.
19958 * ipa-inline.h (initialize_growth_caches): Remove.
19959 (estimate_edge_size): Likewise.
19960 (estimate_edge_time): Likewise.
19961 (estimate_edge_hints): Likewise.
19962 (reset_edge_growth_cache): Likewise.
19963 * symbol-summary.h (call_summary::remove): New method.
19964
19965 2018-06-08 Martin Liska <mliska@suse.cz>
19966
19967 * ipa-cp.c (class edge_clone_summary): New summary.
19968 (grow_edge_clone_vectors): Remove.
19969 (ipcp_edge_duplication_hook): Remove.
19970 (class edge_clone_summary_t): New call_summary class.
19971 (ipcp_edge_removal_hook): Remove.
19972 (edge_clone_summary_t::duplicate): New function.
19973 (get_next_cgraph_edge_clone): Use edge_clone_summaries.
19974 (create_specialized_node): Likewise.
19975 (ipcp_driver): Initialize edge_clone_summaries and do not
19976 register hooks.
19977
19978 2018-06-08 Martin Liska <mliska@suse.cz>
19979
19980 * symbol-summary.h (get): New function.
19981 (call_summary::m_initialize_when_cloning): New class member.
19982
19983 2018-06-08 Martin Liska <mliska@suse.cz>
19984
19985 * cgraph.c (cgraph_node::remove): Do not recycle uid.
19986 * cgraph.h (symbol_table::release_symbol): Do not pass uid.
19987 (symbol_table::allocate_cgraph_symbol): Do not set uid.
19988 * passes.c (uid_hash_t): Record removed_nodes by their uids.
19989 (remove_cgraph_node_from_order): Use the removed_nodes set.
19990 (do_per_function_toporder): Likwise.
19991 * symbol-summary.h (symtab_insertion): Use cgraph_node::uid
19992 instead of summary_uid.
19993 (symtab_removal): Likewise.
19994 (symtab_duplication): Likewise.
19995
19996 2018-06-08 Martin Liska <mliska@suse.cz>
19997
19998 * ipa-cp.c (ipcp_store_bits_results): Use
19999 ipcp_transformation_sum.
20000 (ipcp_store_vr_results): Likewise.
20001 * ipa-prop.c (ipcp_grow_transformations_if_necessary): Renamed
20002 to ...
20003 (ipcp_transformation_initialize): ... this.
20004 (ipa_set_node_agg_value_chain):
20005 (ipa_node_params_t::duplicate): Use ipcp_transformation_sum.
20006 (write_ipcp_transformation_info): Likewise.
20007 (read_ipcp_transformation_info): Likewise.
20008 (ipcp_update_bits): Likewise.
20009 (ipcp_update_vr): Likewise.
20010 (ipcp_transform_function): Likewise.
20011 * ipa-prop.h: Rename ipcp_transformation_summary to
20012 ipcp_transformation.
20013 (class ipcp_transformation_t): New function summary.
20014 (ipcp_get_transformation_summary): Use ipcp_transformation_sum.
20015 (ipa_get_agg_replacements_for_node): Likewise.
20016
20017 2018-06-08 Martin Liska <mliska@suse.cz>
20018
20019 * ipa-pure-const.c (struct funct_state_d): Do it class instead
20020 of struct.
20021 (class funct_state_summary_t): New function_summary class.
20022 (has_function_state): Remove.
20023 (get_function_state): Likewise.
20024 (set_function_state): Likewise.
20025 (add_new_function): Likewise.
20026 (funct_state_summary_t::insert): New function.
20027 (duplicate_node_data): Remove.
20028 (remove_node_data): Remove.
20029 (funct_state_summary_t::duplicate): New function.
20030 (register_hooks): Create new funct_state_summaries.
20031 (pure_const_generate_summary): Use it.
20032 (pure_const_write_summary): Likewise.
20033 (pure_const_read_summary): Likewise.
20034 (propagate_pure_const): Likewise.
20035 (propagate_nothrow): Likewise.
20036 (dump_malloc_lattice): Likewise.
20037 (propagate_malloc): Likewise.
20038 (execute): Do not register hooks, just remove summary
20039 instead.
20040 (pass_ipa_pure_const::pass_ipa_pure_const): Simplify
20041 constructor.
20042
20043 2018-06-08 Martin Liska <mliska@suse.cz>
20044
20045 * ipa-reference.c (remove_node_data): Remove.
20046 (duplicate_node_data): Likewise.
20047 (class ipa_ref_var_info_summary_t): New class.
20048 (class ipa_ref_opt_summary_t): Likewise.
20049 (get_reference_vars_info): Use ipa_ref_var_info_summaries.
20050 (get_reference_optimization_summary): Use
20051 ipa_ref_opt_sum_summaries.
20052 (set_reference_vars_info): Remove.
20053 (set_reference_optimization_summary): Likewise.
20054 (ipa_init): Create summaries.
20055 (init_function_info): Use function summary.
20056 (ipa_ref_opt_summary_t::duplicate): New function.
20057 (ipa_ref_opt_summary_t::remove): New function.
20058 (get_read_write_all_from_node): Fix GNU coding style.
20059 (propagate): Use function summary.
20060 (write_node_summary_p): Fix GNU coding style.
20061 (stream_out_bitmap): Likewise.
20062 (ipa_reference_read_optimization_summary): Use function summary.
20063 (ipa_reference_c_finalize): Do not release hooks.
20064
20065 2018-06-08 Martin Liska <mliska@suse.cz>
20066
20067 * ipa-fnsummary.c (dump_ipa_call_summary): Use ::get method.
20068 (analyze_function_body): Extract multiple calls of get_create.
20069 * ipa-inline-analysis.c (simple_edge_hints): Likewise.
20070 * ipa-inline.c (recursive_inlining): Use ::get method.
20071 * ipa-inline.h (estimate_edge_growth): Likewise.
20072
20073 2018-06-08 Martin Liska <mliska@suse.cz>
20074
20075 * hsa-common.h (enum hsa_function_kind): Rename HSA_NONE to
20076 HSA_INVALID.
20077 (hsa_function_summary::hsa_function_summary): Use the new enum
20078 value.
20079 (hsa_gpu_implementation_p): Use hsa_summaries::get.
20080 * hsa-gen.c (hsa_get_host_function): Likewise.
20081 (get_brig_function_name): Likewise.
20082 * ipa-hsa.c (process_hsa_functions): Likewise.
20083 (ipa_hsa_write_summary): Likewise.
20084 * symbol-summary.h (symtab_duplication): Use ::get function/
20085 (get): New function.
20086
20087 2018-06-08 Martin Liska <mliska@suse.cz>
20088
20089 * config/i386/i386.c (ix86_can_inline_p): Use get_create instead
20090 of get.
20091 * hsa-common.c (hsa_summary_t::link_functions): Likewise.
20092 (hsa_register_kernel): Likewise.
20093 * hsa-common.h (hsa_gpu_implementation_p): Likewise.
20094 * hsa-gen.c (hsa_get_host_function): Likewise.
20095 (get_brig_function_name): Likewise.
20096 (generate_hsa): Likewise.
20097 (pass_gen_hsail::execute): Likewise.
20098 * ipa-cp.c (ipcp_cloning_candidate_p): Likewise.
20099 (devirtualization_time_bonus): Likewise.
20100 (ipcp_propagate_stage): Likewise.
20101 * ipa-fnsummary.c (redirect_to_unreachable): Likewise.
20102 (edge_set_predicate): Likewise.
20103 (evaluate_conditions_for_known_args): Likewise.
20104 (evaluate_properties_for_edge): Likewise.
20105 (ipa_fn_summary::reset): Likewise.
20106 (ipa_fn_summary_t::duplicate): Likewise.
20107 (dump_ipa_call_summary): Likewise.
20108 (ipa_dump_fn_summary): Likewise.
20109 (analyze_function_body): Likewise.
20110 (compute_fn_summary): Likewise.
20111 (estimate_edge_devirt_benefit): Likewise.
20112 (estimate_edge_size_and_time): Likewise.
20113 (estimate_calls_size_and_time): Likewise.
20114 (estimate_node_size_and_time): Likewise.
20115 (inline_update_callee_summaries): Likewise.
20116 (remap_edge_change_prob): Likewise.
20117 (remap_edge_summaries): Likewise.
20118 (ipa_merge_fn_summary_after_inlining): Likewise.
20119 (ipa_update_overall_fn_summary): Likewise.
20120 (read_ipa_call_summary): Likewise.
20121 (inline_read_section): Likewise.
20122 (write_ipa_call_summary): Likewise.
20123 (ipa_fn_summary_write): Likewise.
20124 (ipa_free_fn_summary): Likewise.
20125 * ipa-hsa.c (process_hsa_functions): Likewise.
20126 (ipa_hsa_write_summary): Likewise.
20127 (ipa_hsa_read_section): Likewise.
20128 * ipa-icf.c (sem_function::merge): Likewise.
20129 * ipa-inline-analysis.c (simple_edge_hints): Likewise.
20130 (do_estimate_edge_time): Likewise.
20131 (estimate_size_after_inlining): Likewise.
20132 (estimate_growth): Likewise.
20133 (growth_likely_positive): Likewise.
20134 * ipa-inline-transform.c (clone_inlined_nodes): Likewise.
20135 (inline_call): Likewise.
20136 * ipa-inline.c (caller_growth_limits): Likewise.
20137 (can_inline_edge_p): Likewise.
20138 (can_inline_edge_by_limits_p): Likewise.
20139 (compute_uninlined_call_time): Likewise.
20140 (compute_inlined_call_time): Likewise.
20141 (want_inline_small_function_p): Likewise.
20142 (edge_badness): Likewise.
20143 (update_caller_keys): Likewise.
20144 (update_callee_keys): Likewise.
20145 (recursive_inlining): Likewise.
20146 (inline_small_functions): Likewise.
20147 (inline_to_all_callers_1): Likewise.
20148 (dump_overall_stats): Likewise.
20149 (early_inline_small_functions): Likewise.
20150 (early_inliner): Likewise.
20151 * ipa-inline.h (estimate_edge_growth): Likewise.
20152 * ipa-profile.c (ipa_propagate_frequency_1): Likewise.
20153 * ipa-prop.c (ipa_make_edge_direct_to_target): Likewise.
20154 * ipa-prop.h (IPA_NODE_REF): Likewise.
20155 (IPA_EDGE_REF): Likewise.
20156 * ipa-pure-const.c (malloc_candidate_p): Likewise.
20157 (propagate_malloc): Likewise.
20158 * ipa-split.c (execute_split_functions): Likewise.
20159 * symbol-summary.h: Rename get to get_create.
20160 (get): Likewise.
20161 (get_create): Likewise.
20162 * tree-sra.c (ipa_sra_preliminary_function_checks): Likewise.
20163
20164 2018-06-08 Martin Liska <mliska@suse.cz>
20165
20166 * symbol-summary.h (release): Move definition out of class
20167 declaration.
20168 (symtab_removal): Likewise.
20169 (symtab_duplication): Likewise.
20170
20171 2018-06-08 Martin Liska <mliska@suse.cz>
20172
20173 * symbol-summary.h (function_summary): Move constructor
20174 implementation out of class declaration.
20175 (release): Likewise.
20176 (symtab_insertion): Likewise.
20177 (symtab_removal): Likewise.
20178 (symtab_duplication): Likewise.
20179 (get): Likewise.
20180
20181 2018-06-08 Martin Liska <mliska@suse.cz>
20182
20183 * Makefile.in: Remove support for MPX (macros, related functions,
20184 fields in cgraph_node, ...).
20185 * builtin-types.def (BT_BND): Likewise.
20186 (BT_FN_BND_CONST_PTR): Likewise.
20187 (BT_FN_CONST_PTR_BND): Likewise.
20188 (BT_FN_VOID_PTR_BND): Likewise.
20189 (BT_FN_BND_CONST_PTR_SIZE): Likewise.
20190 (BT_FN_VOID_CONST_PTR_BND_CONST_PTR): Likewise.
20191 * builtins.c (expand_builtin_memcpy_with_bounds): Likewise.
20192 (expand_builtin_mempcpy_with_bounds): Likewise.
20193 (expand_builtin_memset_with_bounds): Likewise.
20194 (expand_builtin_memset_args): Likewise.
20195 (std_expand_builtin_va_start): Likewise.
20196 (expand_builtin): Likewise.
20197 (expand_builtin_with_bounds): Likewise.
20198 * builtins.def (DEF_BUILTIN_CHKP): Likewise.
20199 (DEF_LIB_BUILTIN_CHKP): Likewise.
20200 (DEF_EXT_LIB_BUILTIN_CHKP): Likewise.
20201 (DEF_CHKP_BUILTIN): Likewise.
20202 (BUILT_IN_MEMCPY): Likewise.
20203 (BUILT_IN_MEMMOVE): Likewise.
20204 (BUILT_IN_MEMPCPY): Likewise.
20205 (BUILT_IN_MEMSET): Likewise.
20206 (BUILT_IN_STPCPY): Likewise.
20207 (BUILT_IN_STRCAT): Likewise.
20208 (BUILT_IN_STRCHR): Likewise.
20209 (BUILT_IN_STRCPY): Likewise.
20210 (BUILT_IN_STRLEN): Likewise.
20211 (BUILT_IN_MEMCPY_CHK): Likewise.
20212 (BUILT_IN_MEMMOVE_CHK): Likewise.
20213 (BUILT_IN_MEMPCPY_CHK): Likewise.
20214 (BUILT_IN_MEMSET_CHK): Likewise.
20215 (BUILT_IN_STPCPY_CHK): Likewise.
20216 (BUILT_IN_STRCAT_CHK): Likewise.
20217 (BUILT_IN_STRCPY_CHK): Likewise.
20218 * calls.c (store_bounds): Likewise.
20219 (emit_call_1): Likewise.
20220 (special_function_p): Likewise.
20221 (maybe_warn_nonstring_arg): Likewise.
20222 (initialize_argument_information): Likewise.
20223 (finalize_must_preallocate): Likewise.
20224 (compute_argument_addresses): Likewise.
20225 (expand_call): Likewise.
20226 * cfgexpand.c (expand_call_stmt): Likewise.
20227 (expand_return): Likewise.
20228 (expand_gimple_stmt_1): Likewise.
20229 (pass_expand::execute): Likewise.
20230 * cgraph.c (cgraph_edge::redirect_call_stmt_to_callee): Likewise.
20231 (cgraph_node::remove): Likewise.
20232 (cgraph_node::dump): Likewise.
20233 (cgraph_node::verify_node): Likewise.
20234 * cgraph.h (chkp_function_instrumented_p): Likewise.
20235 (symtab_node::get_alias_target): Likewise.
20236 (cgraph_node::can_remove_if_no_direct_calls_and_refs_p): Likewise.
20237 (cgraph_local_p): Likewise.
20238 * cgraphbuild.c (cgraph_edge::rebuild_edges): Likewise.
20239 (cgraph_edge::rebuild_references): Likewise.
20240 * cgraphunit.c (varpool_node::finalize_decl): Likewise.
20241 (walk_polymorphic_call_targets): Likewise.
20242 (cgraph_node::expand_thunk): Likewise.
20243 (symbol_table::output_weakrefs): Likewise.
20244 * common/config/i386/i386-common.c (OPTION_MASK_ISA2_GENERAL_REGS_ONLY_UNSET): Likewise.
20245 (ix86_handle_option): Likewise.
20246 * config/i386/constraints.md: Likewise.
20247 * config/i386/i386-builtin-types.def (BND): Likewise.
20248 (VOID): Likewise.
20249 (PVOID): Likewise.
20250 (ULONG): Likewise.
20251 * config/i386/i386-builtin.def (BDESC_END): Likewise.
20252 (BDESC_FIRST): Likewise.
20253 (BDESC): Likewise.
20254 * config/i386/i386-c.c (ix86_target_macros_internal): Likewise.
20255 * config/i386/i386-protos.h (ix86_bnd_prefixed_insn_p): Likewise.
20256 * config/i386/i386.c (enum reg_class): Likewise.
20257 (ix86_target_string): Likewise.
20258 (ix86_option_override_internal): Likewise.
20259 (ix86_conditional_register_usage): Likewise.
20260 (ix86_valid_target_attribute_inner_p): Likewise.
20261 (ix86_set_indirect_branch_type): Likewise.
20262 (ix86_set_current_function): Likewise.
20263 (ix86_function_arg_regno_p): Likewise.
20264 (init_cumulative_args): Likewise.
20265 (ix86_function_arg_advance): Likewise.
20266 (ix86_function_arg): Likewise.
20267 (ix86_pass_by_reference): Likewise.
20268 (ix86_function_value_regno_p): Likewise.
20269 (ix86_function_value_1): Likewise.
20270 (ix86_function_value_bounds): Likewise.
20271 (ix86_return_in_memory): Likewise.
20272 (ix86_setup_incoming_vararg_bounds): Likewise.
20273 (ix86_va_start): Likewise.
20274 (indirect_thunk_need_prefix): Likewise.
20275 (print_reg): Likewise.
20276 (ix86_print_operand): Likewise.
20277 (ix86_expand_call): Likewise.
20278 (ix86_output_function_return): Likewise.
20279 (reg_encoded_number): Likewise.
20280 (BDESC_VERIFYS): Likewise.
20281 (ix86_init_mpx_builtins): Likewise.
20282 (ix86_init_builtins): Likewise.
20283 (ix86_emit_cmove): Likewise.
20284 (ix86_emit_move_max): Likewise.
20285 (ix86_expand_builtin): Likewise.
20286 (ix86_builtin_mpx_function): Likewise.
20287 (ix86_get_arg_address_for_bt): Likewise.
20288 (ix86_load_bounds): Likewise.
20289 (ix86_store_bounds): Likewise.
20290 (ix86_load_returned_bounds): Likewise.
20291 (ix86_store_returned_bounds): Likewise.
20292 (ix86_class_likely_spilled_p): Likewise.
20293 (ix86_hard_regno_mode_ok): Likewise.
20294 (x86_order_regs_for_local_alloc): Likewise.
20295 (ix86_mitigate_rop): Likewise.
20296 (ix86_bnd_prefixed_insn_p): Likewise.
20297 (ix86_mpx_bound_mode): Likewise.
20298 (ix86_make_bounds_constant): Likewise.
20299 (ix86_initialize_bounds): Likewise.
20300 (TARGET_LOAD_BOUNDS_FOR_ARG): Likewise.
20301 (TARGET_STORE_BOUNDS_FOR_ARG): Likewise.
20302 (TARGET_LOAD_RETURNED_BOUNDS): Likewise.
20303 (TARGET_STORE_RETURNED_BOUNDS): Likewise.
20304 (TARGET_CHKP_BOUND_MODE): Likewise.
20305 (TARGET_BUILTIN_CHKP_FUNCTION): Likewise.
20306 (TARGET_CHKP_FUNCTION_VALUE_BOUNDS): Likewise.
20307 (TARGET_CHKP_MAKE_BOUNDS_CONSTANT): Likewise.
20308 (TARGET_CHKP_INITIALIZE_BOUNDS): Likewise.
20309 * config/i386/i386.h (TARGET_MPX): Likewise.
20310 (TARGET_MPX_P): Likewise.
20311 (VALID_BND_REG_MODE): Likewise.
20312 (FIRST_BND_REG): Likewise.
20313 (LAST_BND_REG): Likewise.
20314 (enum reg_class): Likewise.
20315 (BND_REG_P): Likewise.
20316 (BND_REGNO_P): Likewise.
20317 (BNDmode): Likewise.
20318 (ADJUST_INSN_LENGTH): Likewise.
20319 * config/i386/i386.md: Likewise.
20320 * config/i386/i386.opt: Likewise.
20321 * config/i386/linux-common.h (LIBMPX_LIBS): Likewise.
20322 (defined): Likewise.
20323 (LINK_MPX): Likewise.
20324 (MPX_SPEC): Likewise.
20325 (LIBMPX_SPEC): Likewise.
20326 (LIBMPXWRAPPERS_SPEC): Likewise.
20327 (CHKP_SPEC): Likewise.
20328 * config/i386/predicates.md: Likewise.
20329 * dbxout.c (dbxout_type): Likewise.
20330 * doc/extend.texi: Likewise.
20331 * doc/invoke.texi: Likewise.
20332 * doc/md.texi: Likewise.
20333 * doc/tm.texi: Likewise.
20334 * doc/tm.texi.in: Likewise.
20335 * dwarf2out.c (is_base_type): Likewise.
20336 (gen_formal_types_die): Likewise.
20337 (gen_subprogram_die): Likewise.
20338 (gen_type_die_with_usage): Likewise.
20339 (gen_decl_die): Likewise.
20340 (dwarf2out_late_global_decl): Likewise.
20341 * expr.c (expand_assignment): Likewise.
20342 (emit_storent_insn): Likewise.
20343 (store_expr_with_bounds): Likewise.
20344 (store_expr): Likewise.
20345 (expand_expr_real_1): Likewise.
20346 * expr.h (store_expr_with_bounds): Likewise.
20347 * function.c (use_register_for_decl): Likewise.
20348 (struct bounds_parm_data): Likewise.
20349 (assign_parms_augmented_arg_list): Likewise.
20350 (assign_parm_find_entry_rtl): Likewise.
20351 (assign_parm_is_stack_parm): Likewise.
20352 (assign_parm_load_bounds): Likewise.
20353 (assign_bounds): Likewise.
20354 (assign_parms): Likewise.
20355 (expand_function_start): Likewise.
20356 * gcc.c (CHKP_SPEC): Likewise.
20357 * gimple-fold.c (gimple_fold_builtin_memory_op): Likewise.
20358 * gimple-ssa-warn-restrict.c (builtin_access::builtin_access): Likewise.
20359 (wrestrict_dom_walker::check_call): Likewise.
20360 * gimple.c (gimple_build_call_from_tree): Likewise.
20361 * gimple.h (enum gf_mask): Likewise.
20362 (gimple_call_with_bounds_p): Likewise.
20363 (gimple_call_set_with_bounds): Likewise.
20364 * gimplify.c (gimplify_init_constructor): Likewise.
20365 * ipa-cp.c (initialize_node_lattices): Likewise.
20366 (propagate_constants_across_call): Likewise.
20367 (find_more_scalar_values_for_callers_subset): Likewise.
20368 * ipa-hsa.c (process_hsa_functions): Likewise.
20369 * ipa-icf-gimple.c (func_checker::compare_gimple_call): Likewise.
20370 * ipa-icf.c (sem_function::merge): Likewise.
20371 * ipa-inline.c (early_inliner): Likewise.
20372 * ipa-pure-const.c (warn_function_noreturn): Likewise.
20373 (warn_function_cold): Likewise.
20374 (propagate_pure_const): Likewise.
20375 * ipa-ref.h (enum GTY): Likewise.
20376 * ipa-split.c (find_retbnd): Likewise.
20377 (consider_split): Likewise.
20378 (split_function): Likewise.
20379 * ipa-visibility.c (cgraph_externally_visible_p): Likewise.
20380 * ipa.c (walk_polymorphic_call_targets): Likewise.
20381 (symbol_table::remove_unreachable_nodes): Likewise.
20382 (process_references): Likewise.
20383 (cgraph_build_static_cdtor_1): Likewise.
20384 * lto-cgraph.c (lto_output_node): Likewise.
20385 (output_refs): Likewise.
20386 (compute_ltrans_boundary): Likewise.
20387 (input_overwrite_node): Likewise.
20388 (input_node): Likewise.
20389 (input_cgraph_1): Likewise.
20390 * params.def (PARAM_CHKP_MAX_CTOR_SIZE): Likewise.
20391 * passes.c (pass_manager::execute_early_local_passes): Likewise.
20392 (class pass_chkp_instrumentation_passes): Likewise.
20393 (make_pass_chkp_instrumentation_passes): Likewise.
20394 * passes.def: Likewise.
20395 * rtl.h (struct GTY): Likewise.
20396 (CALL_EXPR_WITH_BOUNDS_P): Likewise.
20397 * stor-layout.c (layout_type): Likewise.
20398 * symtab.c: Likewise.
20399 * target.def: Likewise.
20400 * targhooks.c (default_chkp_bound_type): Likewise.
20401 (default_chkp_bound_mode): Likewise.
20402 (default_builtin_chkp_function): Likewise.
20403 (default_chkp_function_value_bounds): Likewise.
20404 (default_chkp_make_bounds_constant): Likewise.
20405 (default_chkp_initialize_bounds): Likewise.
20406 * targhooks.h (default_chkp_bound_type): Likewise.
20407 (default_chkp_bound_mode): Likewise.
20408 (default_builtin_chkp_function): Likewise.
20409 (default_chkp_function_value_bounds): Likewise.
20410 (default_chkp_make_bounds_constant): Likewise.
20411 (default_chkp_initialize_bounds): Likewise.
20412 * toplev.c (compile_file): Likewise.
20413 (process_options): Likewise.
20414 * tree-core.h (DEF_BUILTIN): Likewise.
20415 (DEF_BUILTIN_CHKP): Likewise.
20416 * tree-inline.c (declare_return_variable): Likewise.
20417 (remap_gimple_stmt): Likewise.
20418 (copy_bb): Likewise.
20419 (initialize_inlined_parameters): Likewise.
20420 (expand_call_inline): Likewise.
20421 * tree-pass.h (make_pass_ipa_chkp_versioning): Likewise.
20422 (make_pass_ipa_chkp_early_produce_thunks): Likewise.
20423 (make_pass_ipa_chkp_produce_thunks): Likewise.
20424 (make_pass_chkp): Likewise.
20425 (make_pass_chkp_opt): Likewise.
20426 (make_pass_chkp_instrumentation_passes): Likewise.
20427 * tree-pretty-print.c (dump_generic_node): Likewise.
20428 * tree-ssa-ccp.c (insert_clobber_before_stack_restore): Likewise.
20429 * tree-ssa-dce.c (propagate_necessity): Likewise.
20430 (eliminate_unnecessary_stmts): Likewise.
20431 * tree-ssa-pre.c (create_expression_by_pieces): Likewise.
20432 * tree-ssa-sccvn.c (copy_reference_ops_from_call): Likewise.
20433 * tree-ssa-sccvn.h: Likewise.
20434 * tree-ssa-strlen.c (get_string_length): Likewise.
20435 (valid_builtin_call): Likewise.
20436 (adjust_last_stmt): Likewise.
20437 (handle_builtin_strchr): Likewise.
20438 (handle_builtin_strcpy): Likewise.
20439 (handle_builtin_stxncpy): Likewise.
20440 (handle_builtin_memcpy): Likewise.
20441 (handle_builtin_strcat): Likewise.
20442 (strlen_check_and_optimize_stmt): Likewise.
20443 * tree-stdarg.c (expand_ifn_va_arg_1): Likewise.
20444 * tree-streamer-in.c: Likewise.
20445 * tree-streamer.c (record_common_node): Likewise.
20446 * tree.c (tree_code_size): Likewise.
20447 (wide_int_to_tree_1): Likewise.
20448 (type_contains_placeholder_1): Likewise.
20449 (build_common_tree_nodes): Likewise.
20450 * tree.def (POINTER_BOUNDS_TYPE): Likewise.
20451 * tree.h (POINTER_BOUNDS_TYPE_P): Likewise.
20452 (POINTER_BOUNDS_P): Likewise.
20453 (BOUNDED_TYPE_P): Likewise.
20454 (BOUNDED_P): Likewise.
20455 (CALL_WITH_BOUNDS_P): Likewise.
20456 (pointer_bounds_type_node): Likewise.
20457 * value-prof.c (gimple_ic): Likewise.
20458 * var-tracking.c (vt_add_function_parameters): Likewise.
20459 * varasm.c (make_decl_rtl): Likewise.
20460 (assemble_start_function): Likewise.
20461 (output_constant): Likewise.
20462 (maybe_assemble_visibility): Likewise.
20463 * varpool.c (ctor_for_folding): Likewise.
20464 * chkp-builtins.def: Remove.
20465 * ipa-chkp.c: Remove.
20466 * ipa-chkp.h: Remove.
20467 * rtl-chkp.c: Remove.
20468 * rtl-chkp.h: Remove.
20469 * tree-chkp-opt.c: Remove.
20470 * tree-chkp.c: Remove.
20471 * tree-chkp.h: Remove.
20472
20473 2018-06-07 Carl Love <cel@us.ibm.com>
20474
20475 * config/rs6000/vsx.md (vextract_fp_from_shorth,
20476 vextract_fp_from_shortl): Add BE support.
20477
20478 2018-06-07 Paul Koning <ni1d@arrl.net>
20479
20480 * compare-elim.c (try_merge_compare): Don't merge compare if
20481 address contains a side effect.
20482 (try_eliminate_compare): Likewise.
20483
20484 2018-06-07 Olga Makhotina <olga.makhotina@intel.com>
20485
20486 * config.gcc: Support "tremont".
20487 * config/i386/driver-i386.c (host_detect_local_cpu): Detect "tremont".
20488 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
20489 PROCESSOR_TREMONT.
20490 * config/i386/i386.c (m_TREMONT): Define.
20491 (processor_target_table): Add "tremont".
20492 (PTA_TREMONT): Define.
20493 (ix86_lea_outperforms): Add TARGET_TREMONT.
20494 (get_builtin_code_for_version): Handle PROCESSOR_TREMONT.
20495 (fold_builtin_cpu): Add M_INTEL_TREMONT, replace M_INTEL_GOLDMONT
20496 and M_INTEL_GOLDMONT_PLUS.
20497 (fold_builtin_cpu): Add "tremont".
20498 (ix86_add_stmt_cost): Add TARGET_TREMONT.
20499 (ix86_option_override_internal): Add "tremont".
20500 * config/i386/i386.h (processor_costs): Define TARGET_TREMONT.
20501 (processor_type): Add PROCESSOR_TREMONT.
20502 * config/i386/x86-tune.def: Add m_TREMONT.
20503 * doc/invoke.texi: Add tremont as x86 -march=/-mtune= CPU type.
20504
20505 2018-06-07 Jozef Lawrynowicz <jozef.l@mittosystems.com>
20506
20507 * config/msp430/msp430.c (msp430_mcu_name): Set the "i" in the
20508 symbol defined for msp430i* devices to be lower case.
20509
20510 2018-06-07 Richard Biener <rguenther@suse.de>
20511
20512 * graphite-sese-to-poly.c (extract_affine): Avoid unneded
20513 wrapping. Properly wrap the result of a BIT_NOT_EXPR.
20514 Properly wrap signed arithmetic if overflow wraps.
20515
20516 2018-06-07 Jakub Jelinek <jakub@redhat.com>
20517
20518 PR tree-optimization/69615
20519 * tree-ssa-reassoc.c (optimize_range_tests_var_bound): If rhs2 is lhs
20520 of a cast from a same precision integral SSA_NAME in a bb dominated
20521 by first_bb, retry with rhs2 set to the rhs1 of the cast. Don't emit
20522 cast to utype if rhs2 has already a compatible type.
20523
20524 2018-06-07 Richard Biener <rguenther@suse.de>
20525
20526 PR tree-optimization/85935
20527 * graphite-scop-detection.c (find_params_in_bb): Analyze
20528 condition operands with respect to the correct loop. Assert
20529 the analysis doesn't fail.
20530
20531 2018-06-04 Carl Love <cel@us.ibm.com>
20532
20533 * config/rs6000/vsx.md (first_match_index_<mode>): Calculate index
20534 using natural element order. Use gen_lshrsi3 instead of gen_ashrsi3
20535 as it is slightly cheaper.
20536 (first_match_or_eos_index_<mode>):
20537 Calculate index using natural element order.
20538 (first_match_index_<mode>):
20539 Calculate index using natural element order.
20540 (first_match_or_eos_index_<mode>):
20541 Calculate index using natural order.
20542 (define_insn vclzlsbb): Change to define_insn vclzlsbb_<mode>.
20543 for BE and LE modes.
20544 * config/rs6000/rs6000-c.c: Rename P9V_BUILTIN_VCLZLSBB,
20545 P9V_BUILTIN_VCLZLSBB_V16QI.
20546 * config/rs6000/rs6000-builtin.def: Make VCLZLSBB mode
20547 specific.
20548
20549 2018-06-06 Kelvin Nilsen <kelvin@gcc.gnu.org>
20550
20551 * doc/extend.texi (PowerPC AltiVec Built-in Functions): Adjust
20552 indentation and line wrap for many prototypes. Add missing
20553 @smallexample directives around block of prototypes for vec_xl and
20554 vec_xst.
20555
20556 2018-06-05 Michael Meissner <meissner@linux.ibm.com>
20557
20558 * config/rs6000/rs6000.c (rs6000_passes_ieee128): New boolean to
20559 track if we pass or return IEEE 128-bit floating point.
20560 (ieee128_mangling_gcc_8_1): New boolean to say whether to generate
20561 C++ mangling that is compatible with GCC 8.1.
20562 (TARGET_ASM_GLOBALIZE_DECL_NAME): Override target hook.
20563 (init_cumulative_args): Note if we pass or return IEEE 128-bit
20564 floating point types.
20565 (rs6000_function_arg_advance_1): Likewise.
20566 (rs6000_mangle_type): Optionally generate mangled names that match
20567 what GCC 8.1 generated for IEEE 128-bit floating point types.
20568 (rs6000_globalize_decl_name): If we have an external function that
20569 passes or returns IEEE 128-bit types, generate a weak reference
20570 from the mangled name used in GCC 8.1 to the current mangled
20571 name.
20572 (rs6000_init_builtins): Make __ibm128 use the long double type if
20573 long double is IBM extended double. Make __float128 use the long
20574 double type if long double is IEEE 128-bit.
20575
20576 PR target/85657
20577 * config/rs6000/rs6000-builtin.def (BU_IBM128_2): New helper
20578 macro for __ibm128 built-in functions.
20579 (PACK_IF): Add __ibm128 pack/unpack functions.
20580 (UNPACK_IF): Likewise.
20581 * config/rs6000/rs6000.c (rs6000_builtin_mask_calculate): Do not
20582 enable long double built-in functions if long double is IEEE
20583 128-bit floating point.
20584 (rs6000_invalid_builtin): Update long double built-in function
20585 error message.
20586 (rs6000_expand_builtin): For PACK_IF and UNPACK_IF built-in
20587 functions, adjust the built-in function to use the long double
20588 built-in function if __ibm128 and long double are the same type.
20589 * doc/extend.texi (PowerPC builtins): Update documention for
20590 __builtin_{,un}pack_longdouble. Add documentation for
20591 __builtin_{,un}pack_ibm128.
20592
20593 2018-06-06 Jim Wilson <jimw@sifive.com>
20594
20595 * config/riscv/riscv.c (enum riscv_privilege_levels): New.
20596 (struct machine_function): New field interrupt_mode.
20597 (riscv_handle_type_attribute): New function. Add forward declaration.
20598 (riscv_attribute_table) <interrupt>: Use riscv_handle_type_attribute.
20599 (riscv_expand_epilogue): Check interrupt_mode field.
20600 (riscv_set_current_function): Check interrupt attribute args and
20601 set interrupt_mode field.
20602 * config/riscv/riscv.md (UNSPECV_SRET, UNSPECV_URET): New.
20603 (riscv_sret, riscv_uret): New.
20604 * doc/extend.texi (RISC-V Function Attributes) <interrupt>: Document
20605 new arguments to interrupt attribute.
20606
20607 2018-06-06 Peter Bergner <bergner@vnet.ibm.com>
20608
20609 PR target/63177
20610 * /config/rs6000/rs6000.h (ASM_CPU_SPEC): Add support for -mpower9.
20611 Don't handle -mcpu=power8 if -mpower9-vector is also used.
20612
20613 2018-06-06 Kelvin Nilsen <kelvin@gcc.gnu.org>
20614
20615 * config/rs6000/rs6000-builtin.def (VSX_BUILTIN_VEC_LD,
20616 VSX_BUILTIN_VEC_ST): Add comment to explain non-traditional uses.
20617 * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Remove
20618 several redundant entries.
20619
20620 2018-06-06 David Malcolm <dmalcolm@redhat.com>
20621
20622 * config/i386/i386-protos.h (ix86_expand_call): Strengthen return
20623 type from "rtx" to "rtx_insn *".
20624 * config/i386/i386.c (ix86_expand_split_stack_prologue): Likewise
20625 for local "call_insn", removing cast.
20626 (ix86_expand_call): Likewise, introducing a "call_insn" local.
20627
20628 2018-06-06 Eric Botcazou <ebotcazou@adacore.com>
20629
20630 PR tree-optimization/86066
20631 * gimple-ssa-store-merging.c (process_store): Do not bypass BIT_NOT_EXPR
20632 for BIT_INSERT_EXPR stores.
20633
20634 2018-06-06 Richard Biener <rguenther@suse.de>
20635
20636 PR tree-optimization/86062
20637 * tree-ssa-sccvn.c (vn_reference_lookup_3): Handle arbitrary
20638 component refs ontop
20639 of to be offsetted base.
20640
20641 2018-06-06 Jozef Lawrynowicz <jozef.l@mittosystems.com>
20642
20643 * config/msp430/msp430.c (msp430_attr): Allow interrupt handlers
20644 to be static and remove check on interrupt attribute name.
20645
20646 2018-06-05 Kelvin Nilsen <kelvin@gcc.gnu.org>
20647
20648 * doc/extend.texi (PowerPC AltiVec Built-in Functions): Remove
20649 volatile qualifier from vec_lvsl and vec_lvsr argument prototypes.
20650
20651 2018-06-05 Steve Ellcey <sellcey@cavium.com>
20652
20653 PR target/79924
20654 * config/aarch64/aarch64-protos.h (aarch64_err_no_fpadvsimd): Remove
20655 second argument.
20656 * config/aarch64/aarch64-protos..c (aarch64_err_no_fpadvsimd):
20657 Remove second argument, change how error is called.
20658 (aarch64_layout_arg): Remove second argument from
20659 aarch64_err_no_fpadvsimd call.
20660 (aarch64_init_cumulative_args): Ditto.
20661 (aarch64_gimplify_va_arg_expr): Ditto.
20662 * config/aarch64/aarch64.md (mov<mode>): Ditto.
20663
20664 2018-06-05 Uros Bizjak <ubizjak@gmail.com>
20665
20666 * config/i386/i386.md (simple_return_indirect_internal): New expander.
20667 (*simple_return_indirect_internal<mode>): Rename from
20668 simple_return_indirect_internal. Use W mode iterator.
20669 (rstorssp): New expander.
20670 (*rstorssp<mode>): Rename from rstorssp. Use P mode iterator.
20671 (clrssbsy): New expander.
20672 (*clrssbsy<mode>): Rename from clrssbsy. Use P mode iterator.
20673
20674 2018-06-05 Andre Vieira <andre.simoesdiasvieira@arm.com>
20675
20676 * config/arm/arm_cmse.h (cmse_nsfptr_create): Change typeof to
20677 __typeof__.
20678 (cmse_check_pointed_object): Likewise.
20679
20680 2018-06-05 Martin Liska <mliska@suse.cz>
20681
20682 PR gcov-profile/47618
20683 * doc/invoke.texi: Document how -fprofile-dir format
20684 is extended.
20685
20686 2018-06-05 Richard Biener <rguenther@suse.de>
20687
20688 * tree-cfgcleanup.c (cleanup_control_flow_pre): For edge
20689 removal pretend DOM info isn't available so we do not update
20690 it and only remove edges, not dominated blocks. Actually free
20691 DOM info in case we removed something. Remove unreachable blocks.
20692 (mfb_keep_latches): Work with either DOM info or marked backedges.
20693 (cleanup_tree_cfg_noloop): Do not remove unreachable blocks
20694 first. Mark backedges if DOM info isn't available.
20695 (Re-)compute DOM info after cleanup_control_flow_pre.
20696
20697 2018-06-05 Richard Biener <rguenther@suse.de>
20698
20699 * tree-cfg.c (struct locus_discrim_map): Store line, not location.
20700 (locus_discrim_hasher::hash): Adjust.
20701 (locus_discrim_hasher::equal): Likewise.
20702 (next_discriminator_for_locus): Work on line directly.
20703 (same_line_p): Pass in expanded locus1 as well.
20704 (assign_discriminators): Avoid redundant location expansions.
20705
20706 2018-06-05 Richard Biener <rguenther@suse.de>
20707
20708 PR tree-optimization/86046
20709 * tree-ssa.c (maybe_optimize_var): Clear DECL_GIMPLE_REG_P
20710 if required after clearing TREE_ADDRESSABLE.
20711
20712 2018-06-05 Richard Biener <rguenther@suse.de>
20713
20714 PR tree-optimization/86047
20715 * tree-ssa-loop.c (for_each_index): Glob handling of all
20716 decls and constants and really handle all of them.
20717
20718 2018-06-05 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
20719
20720 PR target/81497
20721 * config/arm/arm-builtins.c (arm_type_qualifiers): Add
20722 qualifier_void_pointer and qualifier_const_void_pointer.
20723 (arm_ldc_qualifiers, arm_stc_qualifiers): Use the above.
20724 (arm_init_builtins): Handle the above.
20725 * config/arm/arm_acle.h (__arm_cdp, __arm_ldc, __arm_ldcl, __arm_stc,
20726 __arm_stcl, __arm_mcr, __arm_cdp2, __arm_ldc2, __arm_ldcl2, __arm_stc2,
20727 __arm_stcl2,__arm_mcr2, __arm_mcrr, __arm_mcrr2): Remove return for
20728 void intrinsics.
20729
20730 2018-06-05 Martin Liska <mliska@suse.cz>
20731
20732 * auto-profile.c (read_autofdo_file): Do not use
20733 gcov_ctr_summary struct.
20734 (afdo_callsite_hot_enough_for_early_inline): Likewise.
20735 * coverage.c (struct counts_entry): Likewise.
20736 (read_counts_file): Read just single summary entry.
20737 (get_coverage_counts): Use gcov_summary struct.
20738 * coverage.h (get_coverage_counts): Likewise.
20739 * gcov-dump.c (dump_working_sets): Likewise.
20740 (tag_summary): Dump just single summary.
20741 * gcov-io.c (gcov_write_summary): Write just histogram
20742 summary.
20743 (gcov_read_summary): Read just single summary.
20744 (compute_working_sets): Use gcov_summary struct.
20745 * gcov-io.h (GCOV_TAG_SUMMARY_LENGTH): Remove usage
20746 of GCOV_COUNTERS_SUMMABLE.
20747 (GCOV_COUNTERS_SUMMABLE): Remove.
20748 (GCOV_FIRST_VALUE_COUNTER): Replace with
20749 GCOV_COUNTER_V_INTERVAL.
20750 (struct gcov_ctr_summary): Remove.
20751 (struct gcov_summary): Directly use fields of former
20752 gcov_ctr_summary.
20753 (compute_working_sets): Use gcov_summary struct.
20754 * gcov.c (read_count_file): Do not use ctrs fields.
20755 * lto-cgraph.c (merge_profile_summaries): Use gcov_summary
20756 struct.
20757 * lto-streamer.h (struct GTY): Make profile_info gcov_summary
20758 struct.
20759 * profile.c: Likewise.
20760 * profile.h: Likewise.
20761
20762 2018-06-05 Martin Liska <mliska@suse.cz>
20763
20764 PR gcov-profile/84846
20765 * gcov.c (output_lines): Print working directory only
20766 in intermediate format.
20767
20768 2018-06-05 Andreas Krebbel <krebbel@linux.ibm.com>
20769
20770 * config/s390/s390-builtin-types.def: Add void function type.
20771 * config/s390/s390-builtins.def: Use the function type for the
20772 tbeginc builtin.
20773
20774 2018-06-04 Jim Wilson <jimw@sifive.com>
20775
20776 * config/riscv/riscv-protos.h (riscv_expand_epilogue): Change bool arg
20777 to int.
20778 * config/riscv/riscv.c (riscv_for_each_saved_reg): New args epilogue
20779 and maybe_eh_return. Change regno to unsigned int. Use new args to
20780 handle EH_RETURN_DATA_REGNO registers properly.
20781 (riscv_expand_prologue): Pass new args to riscv_for_each_saved_reg.
20782 (riscv_expand_epilogue): Update comment. Change argument name and
20783 type. Update code to use new name and type. Pass new args to
20784 riscv_for_each_saved_reg. Only use EH_RETURN_STACKADJ_RTX when
20785 EXCEPTION_RETURN.
20786 * config/riscv/riscv.md (NORMAL_RETURN): New.
20787 (SIBCALL_RETURN, EXCEPTION_RETURN): New.
20788 (epilogue, sibcall_epilogue): Update riscv_expand_epilogue arg.
20789 (eh_return): Call gen_eh_return_internal and emit barrier.
20790 (eh_return_internal): Call riscv_expand_epilogue.
20791
20792 2018-06-04 Eric Botcazou <ebotcazou@adacore.com>
20793
20794 * gimple-ssa-store-merging.c (struct merged_store_group): Move up
20795 bit_insertion field and declare can_be_merged_into method.
20796 (merged_store_group::can_be_merged_into): New method.
20797 (imm_store_chain_info::coalesce_immediate): Call it to decide whether
20798 consecutive non-overlapping stores can be merged. Turn MEM_REF stores
20799 into BIT_INSERT_EXPR stores if the group contains a non-MEM_REF store.
20800
20801 2018-06-04 Richard Biener <rguenther@suse.de>
20802
20803 PR tree-optimization/85955
20804 * builtins.c (fold_builtin_sincos): Convert pointers to
20805 destination to appropriate type before dereferencing.
20806
20807 2018-06-04 Segher Boessenkool <segher@kernel.crashing.org>
20808
20809 * config/rs6000/rs6000.md (abs<mode>2 for FLOAT128): Handle IFmode.
20810
20811 2018-06-04 Richard Sandiford <richard.sandiford@linaro.org>
20812
20813 * expr.c (expand_expr_real_1): Force the operand into memory if
20814 its TYPE_MODE is BLKmode and if there is no integer mode for
20815 the number of bits being extracted.
20816
20817 2018-06-04 Jakub Jelinek <jakub@redhat.com>
20818
20819 PR target/85832
20820 PR target/86036
20821 * config/i386/sse.md (<avx512>_eq<mode>3<mask_scalar_merge_name>_1):
20822 Use vptestnm rather than vptestm in (=Yc,v,C) variant.
20823
20824 2018-06-04 Richard Biener <rguenther@suse.de>
20825
20826 * tree-cfgcleanup.c (cleanup_tree_cfg_1): Fold into...
20827 (cleanup_tree_cfg_noloop): ... single caller. Do
20828 start_recording_case_labels later.
20829
20830 2018-06-04 Sebastian Peryt <sebastian.peryt@intel.com>
20831
20832 * config/i386/cldemoteintrin.h: Change define from _X86INTRIN_H_INCLUDED
20833 to _IMMINTRIN_H_INCLUDED.
20834 * config/i386/pconfigintrin.h: Ditto.
20835 * config/i386/waitpkgintrin.h: Ditto.
20836 * config/i386/immintrin.h: Add includes for sgxintrin.h,
20837 pconfigintrin.h, waitpkgintrin.h and cldemoteintrin.h.
20838 * config/i386/x86intrin.h: Remove includes for mintrin.h, xmmintrin.h,
20839 emmintrin.h, pmmintrin.h, tmmintrin.h, smmintrin.h, wmmintrin.h,
20840 bmiintrin.h, bmi2intrin.h, lzcntintrin.h, sgxintrin.h, pconfigintrin.h,
20841 waitpkgintrin.h and cldemoteintrin.h.
20842
20843 2018-06-04 Richard Biener <rguenther@suse.de>
20844
20845 PR tree-optimization/86038
20846 * tracer.c (find_best_successor): Check probability for
20847 being initialized, bail out if not.
20848
20849 2018-06-04 Richard Earnshaw <rearnsha@arm.com>
20850
20851 PR target/86003
20852 * config/arm/arm-cpus.in (ALL_QUIRKS): Add xscale feature to the list
20853 of bits to ignore when comparing architectures.
20854
20855 2018-06-04 Jakub Jelinek <jakub@redhat.com>
20856
20857 PR tree-optimization/69615
20858 * fold-const.c (merge_ranges): If range1 is - [x, x] and x is the
20859 maximum or minimum of the type, try to merge it also as if
20860 range1 is + [-, x - 1] or + [x + 1, -].
20861
20862 PR c++/86025
20863 * tree.c (inchash::add_expr): Handle IDENTIFIER_NODE.
20864
20865 2018-06-03 Eric Botcazou <ebotcazou@adacore.com>
20866
20867 PR tree-optimization/86034
20868 * gimple-ssa-store-merging.c (output_merged_store): Convert the RHS to
20869 the unsigned bitfield type in a bit insertion sequence if it does not
20870 have a larger precision than the bitfield size.
20871 (process_store): Also bypass widening conversions for BIT_INSERT_EXPR.
20872
20873 2018-06-03 Kito Cheng <kito.cheng@gmail.com>
20874
20875 * config/nds32/nds32-peephole2.md: Add new patterns for code size.
20876
20877 2018-06-03 Chung-Ju Wu <jasonwucj@gmail.com>
20878
20879 * config/nds32/nds32-opts.h (nds32_arch_type): Add ARCH_V3J.
20880 * config/nds32/nds32.c (nds32_option_override): Consider ARCH_V3J.
20881 * config/nds32/nds32.h (TARGET_ISA_V3): Add ARCH_V3J checking.
20882 * config/nds32/nds32.opt (march): Add enum value Value(ARCH_V3J).
20883
20884 2018-06-03 Chung-Ju Wu <jasonwucj@gmail.com>
20885
20886 * common/config/nds32/nds32-common.c (nds32_option_optimization_table):
20887 Disable -fdelete-null-pointer-checks for ELF toolchain.
20888
20889 2018-06-02 Chung-Ju Wu <jasonwucj@gmail.com>
20890 Kito Cheng <kito.cheng@gmail.com>
20891
20892 * config.gcc (nds32*): Use nds32-linux.opt and nds32-elf.opt.
20893 (nds32le-*-*, nds32be-*-*): Integrate checking process.
20894 (nds32*-*-*): Add glibc and uclibc conditions.
20895 * common/config/nds32/nds32-common.c (nds32_except_unwind_info): New.
20896 (TARGET_EXCEPT_UNWIND_INFO): Define.
20897 * config/nds32/elf.h: New file.
20898 * config/nds32/linux.h: New file.
20899 * config/nds32/nds32-elf.opt: New file.
20900 * config/nds32/nds32-linux.opt: New file.
20901 * config/nds32/nds32-fp-as-gp.c
20902 (pass_nds32_fp_as_gp::gate): Consider TARGET_LINUX_ABI.
20903 * config/nds32/nds32.c (nds32_conditional_register_usage): Consider
20904 TARGET_LINUX_ABI.
20905 (nds32_asm_file_end): Ditto.
20906 (nds32_print_operand): Ditto.
20907 (nds32_insert_attributes): Ditto.
20908 (nds32_init_libfuncs): New function.
20909 (TARGET_HAVE_TLS): Define.
20910 (TARGET_INIT_LIBFUNCS): Define.
20911 * config/nds32/nds32.h (TARGET_DEFAULT_RELAX): Apply different relax
20912 spec content.
20913 (TARGET_ELF): Apply different mcmodel setting.
20914 (LINK_SPEC, LIB_SPEC, STARTFILE_SPEC, ENDFILE_SPEC): The content has
20915 been migrated into elf.h and linux.h files.
20916 * config/nds32/nds32.md (add_pc): Consider TARGET_LINUX_ABI.
20917 * config/nds32/nds32.opt (mvh): Consider TARGET_LINUX_ABI.
20918 (mcmodel): The content has been migrated into nds32-elf.opt and
20919 nds32-linux.opt files.
20920 * config/nds32/t-elf: New file.
20921 * config/nds32/t-linux: New file.
20922
20923 2018-06-02 Chung-Ju Wu <jasonwucj@gmail.com>
20924 Shiva Chen <shiva0217@gmail.com>
20925
20926 * config/nds32/constants.md (unspec_volatile_element): Add
20927 UNSPEC_VOLATILE_OMIT_FP_BEGIN and UNSPEC_VOLATILE_OMIT_FP_END.
20928 * config/nds32/nds32-fp-as-gp.c: New implementation of fp_as_gp
20929 optimization.
20930 * config/nds32/nds32-protos.h (nds32_naked_function_p): Declare.
20931 (make_pass_nds32_fp_as_gp): Declare.
20932 * config/nds32/nds32.c (nds32_register_passes): Add fp_as_gp as one
20933 optmization pass.
20934 (nds32_asm_function_end_prologue): Remove unused asm output.
20935 (nds32_asm_function_begin_epilogue): Remove unused asm output.
20936 (nds32_asm_file_start): Output necessary fp_as_gp information.
20937 (nds32_option_override): Adjust register usage.
20938 (nds32_expand_prologue): Consider fp_as_gp situation.
20939 (nds32_expand_prologue_v3push): Consider fp_as_gp situation.
20940 * config/nds32/nds32.md (prologue): Check fp_as_gp_p and naked_p.
20941 (epilogue): Ditto.
20942 (return): Ditto.
20943 (simple_return): Ditto.
20944 (omit_fp_begin): Output special directive for fp_as_gp.
20945 (omit_fp_end): Output special directive for fp_as_gp.
20946 * config/nds32/nds32.opt (mfp-as-gp, mno-fp-as-gp, mforce-fp-as-gp,
20947 mforbid-fp-as-gp): New options.
20948
20949 2018-06-01 Mark Wielaard <mark@klomp.org>
20950
20951 * dwarf2out.c (dwarf2out_finish): Remove generation of
20952 DW_AT_loclists_base.
20953
20954 2018-06-01 Eric Botcazou <ebotcazou@adacore.com>
20955
20956 * gimple-ssa-store-merging.c: Include gimple-fold.h.
20957 (struct store_immediate_info): Document BIT_INSERT_EXPR stores.
20958 (struct merged_store_group): Add bit_insertion field.
20959 (dump_char_array): Use standard hexadecimal format.
20960 (merged_store_group::merged_store_group): Set bit_insertion to false.
20961 (merged_store_group::apply_stores): Use optimal buffer size. Deal
20962 with BIT_INSERT_EXPR stores. Move up code updating the mask and
20963 also print the mask in the dump file.
20964 (pass_store_merging::gate): Minor tweak.
20965 (imm_store_chain_info::coalesce_immediate): Fix wrong association
20966 of stores with groups in dump. Allow coalescing of BIT_INSERT_EXPR
20967 stores with INTEGER_CST stores.
20968 (count_multiple_uses) <BIT_INSERT_EXPR>: New case.
20969 (imm_store_chain_info::output_merged_store): Add try_bitpos variable
20970 and use it throughout. Generate bit insertion sequences if need be.
20971 (pass_store_merging::process_store): Remove redundant condition.
20972 Record stores from a SSA name to a bit-field with BIT_INSERT_EXPR.
20973
20974 2018-06-01 Segher Boessenkool <segher@kernel.crashing.org>
20975
20976 * config/rs6000/rs6000.c (rs6000_mangle_type): Change the mangling of
20977 the 128-bit floating point types. Fix function comment.
20978
20979 2018-06-01 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
20980
20981 * config/aarch64/aarch64-simd.md
20982 (aarch64_simd_vec_unpack<su>_lo_<mode>): Use UXTL and SXTL assembler
20983 mnemonics.
20984 (aarch64_simd_vec_unpack<su>_hi_<mode>): Use UXTL2 and SXTL2 assembler
20985 mnemonics.
20986
20987 2018-06-01 Richard Sandiford <richard.sandiford@linaro.org>
20988
20989 PR tree-optimization/85989
20990 * gimple-ssa-backprop.c (backprop::m_visited_phis): New member
20991 variable.
20992 (backprop::intersect_uses): Check it when deciding whether this
20993 is a backedge reference.
20994 (backprop::process_block): Add each phi to m_visited_phis
20995 after visiting it, then clear it at the end.
20996
20997 2018-06-01 Richard Biener <rguenther@suse.de>
20998
20999 * tree-vectorizer.h (vect_dr_stmt): New function.
21000 (vect_get_load_cost): Adjust.
21001 (vect_get_store_cost): Likewise.
21002 * tree-vect-data-refs.c (vect_analyze_data_ref_dependence):
21003 Use vect_dr_stmt instead of DR_SMTT.
21004 (vect_record_base_alignments): Likewise.
21005 (vect_calculate_target_alignment): Likewise.
21006 (vect_compute_data_ref_alignment): Likewise and make static.
21007 (vect_update_misalignment_for_peel): Likewise.
21008 (vect_verify_datarefs_alignment): Likewise.
21009 (vector_alignment_reachable_p): Likewise.
21010 (vect_get_data_access_cost): Likewise. Pass down
21011 vinfo to vect_get_load_cost/vect_get_store_cost instead of DR.
21012 (vect_get_peeling_costs_all_drs): Likewise.
21013 (vect_peeling_hash_get_lowest_cost): Likewise.
21014 (vect_enhance_data_refs_alignment): Likewise.
21015 (vect_find_same_alignment_drs): Likewise.
21016 (vect_analyze_data_refs_alignment): Likewise.
21017 (vect_analyze_group_access_1): Likewise.
21018 (vect_analyze_group_access): Likewise.
21019 (vect_analyze_data_ref_access): Likewise.
21020 (vect_analyze_data_ref_accesses): Likewise.
21021 (vect_vfa_segment_size): Likewise.
21022 (vect_small_gap_p): Likewise.
21023 (vectorizable_with_step_bound_p): Likewise.
21024 (vect_prune_runtime_alias_test_list): Likewise.
21025 (vect_analyze_data_refs): Likewise.
21026 (vect_supportable_dr_alignment): Likewise.
21027 * tree-vect-loop-manip.c (get_misalign_in_elems): Likewise.
21028 (vect_gen_prolog_loop_niters): Likewise.
21029 * tree-vect-loop.c (vect_analyze_loop_2): Likewise.
21030 * tree-vect-patterns.c (vect_recog_bool_pattern): Do not
21031 modify DR_STMT.
21032 (vect_recog_mask_conversion_pattern): Likewise.
21033 (vect_try_gather_scatter_pattern): Likewise.
21034 * tree-vect-stmts.c (vect_model_store_cost): Pass stmt_info
21035 to vect_get_store_cost.
21036 (vect_get_store_cost): Get stmt_info instead of DR.
21037 (vect_model_load_cost): Pass stmt_info to vect_get_load_cost.
21038 (vect_get_load_cost): Get stmt_info instead of DR.
21039
21040 2018-06-01 Richard Biener <rguenther@suse.de>
21041
21042 PR middle-end/86017
21043 * gimple-fold.c (var_decl_component_p): Also allow offsetted
21044 vars wrapped in MEM_REFs.
21045
21046 2018-06-01 Richard Sandiford <richard.sandiford@linaro.org>
21047
21048 * config/aarch64/aarch64.c (aarch64_ira_change_pseudo_allocno_class):
21049 Fix subreg tests so that we only return a choice between
21050 GENERAL_REGS and FP_REGS if the original classes included both.
21051
21052 2018-06-01 Richard Biener <rguenther@suse.de>
21053
21054 PR ipa/85960
21055 * tree-ssa-structalias.c (get_function_part_constraint):
21056 Handle NULL fi->decl.
21057 (find_func_aliases_for_call): Properly handle indirect
21058 fi from direct call.
21059 (find_func_clobbers): Likewise.
21060 (ipa_pta_execute): Likewise.
21061 (create_variable_info_for): For functions that are ifunc_resolver
21062 resolve to a varinfo that contains the result of the resolver call.
21063 (associate_varinfo_to_alias): Do not treat ifunc resolvers as
21064 aliases.
21065
21066 2018-05-31 Michael Collison <michael.collison@arm.com>
21067
21068 * config/aarch64/aarch64.md:
21069 (*fix_to_zero_extenddfdi2): New pattern.
21070 * gcc.target/aarch64/fix_extend1.c: New testcase.
21071
21072 2018-05-31 Qing Zhao <qing.zhao@oracle.com>
21073
21074 PR middle-end/78809
21075 PR middle-end/83026
21076 * builtins.c (expand_builtin): Add the handling of BUILT_IN_STRCMP_EQ
21077 and BUILT_IN_STRNCMP_EQ.
21078 * builtins.def: Add new builtins BUILT_IN_STRCMP_EQ and
21079 BUILT_IN_STRNCMP_EQ.
21080 * gimple-fold.c (gimple_fold_builtin_string_compare): Add the
21081 handling of BUILTIN_IN_STRCMP_EQ and BUILT_IN_STRNCMP_EQ.
21082 (gimple_fold_builtin): Likewise.
21083 * tree-ssa-strlen.c (compute_string_length): New function.
21084 (determine_min_obsize): New function.
21085 (handle_builtin_string_cmp): New function to handle calls to
21086 string compare functions.
21087 (strlen_optimize_stmt): Add handling to builtin string compare
21088 calls.
21089 * tree-ssa-structalias.c (find_func_aliases_for_builtin_call):
21090 Add the handling of BUILT_IN_STRCMP_EQ and BUILT_IN_STRNCMP_EQ.
21091 * tree.c (build_common_builtin_nodes): Add new defines of
21092 BUILT_IN_STRNCMP_EQ and BUILT_IN_STRCMP_EQ.
21093
21094 2018-05-31 Jakub Jelinek <jakub@redhat.com>
21095
21096 PR target/85984
21097 * bb-reorder.c (pass_partition_blocks::gate): Return false for
21098 functions with naked attribute.
21099
21100 2018-05-31 Uros Bizjak <ubizjak@gmail.com>
21101
21102 * config/i386/sse.md (avx_vec_concat<mode>):
21103 Substitute concat_tg_mode mode attribute with xtg_mode.
21104 (<mask_codefor>avx512dq_broadcast<mode><mask_name>_1): Ditto.
21105 (concat_tg_mode): Remove mode attribute.
21106
21107 2018-05-31 Martin Sebor <msebor@redhat.com>
21108
21109 PR c/82063
21110 * calls.c (alloc_max_size): Correct a logic error/typo.
21111 Treat excessive arguments as infinite. Warn for invalid arguments.
21112 * doc/invoke.texi (-Walloc-size-larger-than): Update.
21113
21114 2018-05-31 H.J. Lu <hongjiu.lu@intel.com>
21115
21116 PR target/85829
21117 * config/i386/x86-tune.def: Re-enable partial_reg_dependency
21118 and movx for Haswell.
21119
21120 2018-05-31 Chung-Lin Tang <cltang@codesourcery.com>
21121 Cesar Philippidis <cesar@codesourcery.com>
21122
21123 PR middle-end/85879
21124 * gimplify.c (gimplify_adjust_omp_clauses): Add 'remove = true'
21125 when emitting error on private/firstprivate reductions.
21126 * omp-low.c (lower_omp_target): Avoid reference-type processing
21127 on pointers for firstprivate clause.
21128
21129 2018-05-31 Sameera Deshpande <sameera.deshpande@linaro.org>
21130
21131 * config/aarch64/aarch64-simd-builtins.def (ld1x3): New.
21132 (st1x2): Likewise.
21133 (st1x3): Likewise.
21134 * config/aarch64/aarch64-simd.md
21135 (aarch64_ld1x3<VALLDIF:mode>): New pattern.
21136 (aarch64_ld1_x3_<mode>): Likewise
21137 (aarch64_st1x2<VALLDIF:mode>): Likewise
21138 (aarch64_st1_x2_<mode>): Likewise
21139 (aarch64_st1x3<VALLDIF:mode>): Likewise
21140 (aarch64_st1_x3_<mode>): Likewise
21141 * config/aarch64/arm_neon.h (vld1_u8_x3): New function.
21142 (vld1_s8_x3): Likewise.
21143 (vld1_u16_x3): Likewise.
21144 (vld1_s16_x3): Likewise.
21145 (vld1_u32_x3): Likewise.
21146 (vld1_s32_x3): Likewise.
21147 (vld1_u64_x3): Likewise.
21148 (vld1_s64_x3): Likewise.
21149 (vld1_f16_x3): Likewise.
21150 (vld1_f32_x3): Likewise.
21151 (vld1_f64_x3): Likewise.
21152 (vld1_p8_x3): Likewise.
21153 (vld1_p16_x3): Likewise.
21154 (vld1_p64_x3): Likewise.
21155 (vld1q_u8_x3): Likewise.
21156 (vld1q_s8_x3): Likewise.
21157 (vld1q_u16_x3): Likewise.
21158 (vld1q_s16_x3): Likewise.
21159 (vld1q_u32_x3): Likewise.
21160 (vld1q_s32_x3): Likewise.
21161 (vld1q_u64_x3): Likewise.
21162 (vld1q_s64_x3): Likewise.
21163 (vld1q_f16_x3): Likewise.
21164 (vld1q_f32_x3): Likewise.
21165 (vld1q_f64_x3): Likewise.
21166 (vld1q_p8_x3): Likewise.
21167 (vld1q_p16_x3): Likewise.
21168 (vld1q_p64_x3): Likewise.
21169 (vst1_s64_x2): Likewise.
21170 (vst1_u64_x2): Likewise.
21171 (vst1_f64_x2): Likewise.
21172 (vst1_s8_x2): Likewise.
21173 (vst1_p8_x2): Likewise.
21174 (vst1_s16_x2): Likewise.
21175 (vst1_p16_x2): Likewise.
21176 (vst1_s32_x2): Likewise.
21177 (vst1_u8_x2): Likewise.
21178 (vst1_u16_x2): Likewise.
21179 (vst1_u32_x2): Likewise.
21180 (vst1_f16_x2): Likewise.
21181 (vst1_f32_x2): Likewise.
21182 (vst1_p64_x2): Likewise.
21183 (vst1q_s8_x2): Likewise.
21184 (vst1q_p8_x2): Likewise.
21185 (vst1q_s16_x2): Likewise.
21186 (vst1q_p16_x2): Likewise.
21187 (vst1q_s32_x2): Likewise.
21188 (vst1q_s64_x2): Likewise.
21189 (vst1q_u8_x2): Likewise.
21190 (vst1q_u16_x2): Likewise.
21191 (vst1q_u32_x2): Likewise.
21192 (vst1q_u64_x2): Likewise.
21193 (vst1q_f16_x2): Likewise.
21194 (vst1q_f32_x2): Likewise.
21195 (vst1q_f64_x2): Likewise.
21196 (vst1q_p64_x2): Likewise.
21197 (vst1_s64_x3): Likewise.
21198 (vst1_u64_x3): Likewise.
21199 (vst1_f64_x3): Likewise.
21200 (vst1_s8_x3): Likewise.
21201 (vst1_p8_x3): Likewise.
21202 (vst1_s16_x3): Likewise.
21203 (vst1_p16_x3): Likewise.
21204 (vst1_s32_x3): Likewise.
21205 (vst1_u8_x3): Likewise.
21206 (vst1_u16_x3): Likewise.
21207 (vst1_u32_x3): Likewise.
21208 (vst1_f16_x3): Likewise.
21209 (vst1_f32_x3): Likewise.
21210 (vst1_p64_x3): Likewise.
21211 (vst1q_s8_x3): Likewise.
21212 (vst1q_p8_x3): Likewise.
21213 (vst1q_s16_x3): Likewise.
21214 (vst1q_p16_x3): Likewise.
21215 (vst1q_s32_x3): Likewise.
21216 (vst1q_s64_x3): Likewise.
21217 (vst1q_u8_x3): Likewise.
21218 (vst1q_u16_x3): Likewise.
21219 (vst1q_u32_x3): Likewise.
21220 (vst1q_u64_x3): Likewise.
21221 (vst1q_f16_x3): Likewise.
21222 (vst1q_f32_x3): Likewise.
21223 (vst1q_f64_x3): Likewise.
21224 (vst1q_p64_x3): Likewise.
21225
21226 2018-05-30 Jozef Lawrynowicz <jozef.l@mittosystems.com>
21227
21228 * config/msp430/msp430.c (msp430_output_labelref): Prepend
21229 user_label_prefix to name.
21230
21231 * tree-core.h: Update comment about the format of NAME string
21232 passed to handler in attribute_spec.
21233
21234 * config/msp430/msp430.md: Remove erroneous subreg expression from
21235 zero_extendqisi2 insn pattern. Remove msp430x ISA restriction on
21236 zero_extend{q,h}isi2.
21237
21238 2018-05-30 Borislav Petkov <bp@suse.de>
21239
21240 * doc/extend.texi: Document some architecture specific
21241 constraints and sort entries.
21242
21243 2018-05-30 Martin Sebor <msebor@redhat.com>
21244
21245 PR middle-end/85369
21246 * builtins.c (expand_builtin_stpcpy_1): New function.
21247 (expand_builtin_stpcpy): Call it, and call maybe_warn_nonstring_arg
21248 only if the former succeeds.
21249
21250 2018-05-31 Sameera Deshpande <sameera.deshpande@linaro.org>
21251
21252 * config/aarch64/aarch64-cores.def (saphira) : Add support for ARMv8.4
21253 in saphira.
21254
21255 2018-05-30 Jan Hubicka <hubicka@ucw.cz>
21256
21257 * doc/invoke.texi (-flinker-output): Document
21258
21259 2018-05-30 Jan Hubicka <hubicka@ucw.cz>
21260
21261 * passes.c (ipa_write_summaries): Only modify statements if body
21262 is in memory.
21263 * cgraphunit.c (ipa_passes): Also produce intermeidate code when
21264 incrementally linking.
21265 (ipa_passes): Likewise.
21266 * lto-cgraph.c (lto_output_node): When incrementally linking do not
21267 pass down resolution info.
21268 * common.opt (flag_incremental_link): Update info.
21269 * gcc.c (plugin specs): Turn flinker-output=* to
21270 -plugin-opt=-linker-output-known
21271 * toplev.c (compile_file): Also cut compilation when doing incremental
21272 link.
21273 * flag-types. (enum lto_partition_model): Add
21274 LTO_LINKER_OUTPUT_NOLTOREL.
21275 (invoke.texi): Add -flinker-output docs.
21276 * ipa.c (symbol_table::remove_unreachable_nodes): Handle LTO incremental
21277 link same way as WPA; do not stream in dead initializers.
21278
21279 * dwarf2out.c (dwarf2out_die_ref_for_decl,
21280 darf2out_register_external_decl): Support incremental link.
21281
21282 2018-05-30 Jan Hubicka <hubicka@ucw.cz>
21283
21284 * lto-opts.c (lto_write_options): Skip OPT_dumpdir, OPT_fresolution_.
21285
21286 2018-05-30 Jan Hubicka <hubicka@ucw.cz>
21287
21288 * lto-wrapper.c (debug_objcopy): Add rename parameter; pass
21289 it down to simple_object_copy_lto_debug_sections.
21290 (run_gcc): Determine incremental LTO link time and configure
21291 lto1 into non-wpa mode, disable renaming of debug sections.
21292
21293 2018-05-30 Kelvin Nilsen <kelvin@gcc.gnu.org>
21294
21295 * doc/extend.texi (PowerPC AltiVec Built-in Functions): Remove
21296 descriptions of various incorrectly documented functions.
21297
21298 2018-05-30 Andre Vieira <andre.simoesdiasvieira@arm.com>
21299
21300 Revert:
21301 * config/aarch64/predicates.md (aarch64_mem_pair_lanes_operand): Make
21302 address check not strict.
21303
21304 2018-05-30 Richard Biener <rguenther@suse.de>
21305
21306 PR tree-optimization/85964
21307 * tracer.c (better_p): Drop initialized count check, we only
21308 call the function with initialized counts now.
21309 (find_best_successor): Do find a best edge if one
21310 has uninitialized count.
21311 (find_best_predecessor): Likewise. Do BB frequency check only
21312 if count is initialized.
21313
21314 2017-05-30 Jackson Woodruff <jackson.woodruff@arm.com>
21315
21316 * config/aarch64/aarch64.c (aarch64_host_wide_int_compare): New.
21317 (aarch64_ldrstr_offset_compare): New.
21318 (aarch64_operands_adjust_ok_for_ldpstp): Update to consider all
21319 load/store orderings.
21320 (aarch64_gen_adjusted_ldpstp): Likewise.
21321
21322 2018-05-30 Wilco Dijkstra <wdijkstr@arm.com>
21323
21324 * config/aarch64/aarch64.c (aarch64_ira_change_pseudo_allocno_class):
21325 Check for subset of GENERAL_REGS and FP_REGS.
21326 * config/aarch64/aarch64-simd.md (aarch64_get_lane): Increase cost of
21327 r=w alternative.
21328
21329 2018-05-30 Richard Sandiford <richard.sandiford@linaro.org>
21330
21331 * alias.c (adjust_offset_for_component_ref): Use poly_int_tree_p
21332 and wi::to_poly_offset. Add the current offset and then check
21333 whether the sum fits, rather than using an unchecked addition of
21334 a checked term. Check for a shwi rather than a uhwi.
21335 * expr.c (get_bit_range): Use tree_to_poly_uint64.
21336 (store_constructor): Use poly_int_tree_p.
21337 (expand_expr_real_1): Likewise.
21338 * function.c (assign_temp): Likewise.
21339 * fold-const.c (const_binop): Use poly_int_tree_p and
21340 wi::to_poly_offset.
21341 (fold_indirect_ref_1): Likewise. Use multiple_p to attempt an exact
21342 division.
21343 * ipa-icf-gimple.c (func_checker::compare_operand): Use
21344 to_poly_offset for MEM offsets.
21345 * ipa-icf.c (sem_variable::equals): Likewise.
21346 * stor-layout.c (compute_record_mode): Use poly_int_tree_p.
21347 * tree-ssa-sccvn.c (ao_ref_init_from_vn_reference): Use
21348 wi::to_poly_offset for BIT_FIELD_REF offsets.
21349 (vn_reference_maybe_forwprop_address): Use poly_int_tree_p and
21350 wi::to_poly_offset.
21351 * var-tracking.c (emit_note_insn_var_location): Use
21352 tree_to_poly_uint64.
21353
21354 2018-05-29 Jim Wilson <jimw@sifive.com>
21355
21356 * config/riscv/riscv.c (riscv_interrupt_type): Fix comment typo.
21357
21358 2018-05-29 Uros Bizjak <ubizjak@gmail.com>
21359
21360 PR target/85950
21361 * config/i386/i386.md (l<rounding_insn><MODEF:mode><SWI48:mode>2):
21362 Enable for TARGET_SSE4_1 and generate rounds{s,d} and cvtts{s,d}2si{,q}
21363 sequence.
21364 (sse4_1_round<mode>2): Use nonimmediate_operand
21365 for operand 1 predicate.
21366
21367 2018-05-29 Martin Sebor <msebor@redhat.com>
21368 Richard Biener <rguenther@suse.de>
21369
21370 PR testsuite/85888
21371 * calls.c (get_size_range): Call determine_value_range instead
21372 of get_value_range..
21373 * tree-vrp.h (determine_value_range): Declared new function.
21374 * tree-vrp.c (determine_value_range_1, determine_value_range): New.
21375
21376 2018-05-29 Richard Biener <rguenther@suse.de>
21377
21378 * tree-vect-data-refs.c (vect_preserves_scalar_order_p): Make
21379 sure to use non-pattern stmts for get_earlier_stmt arguments.
21380 * tree-vectorizer.h (get_earlier_stmt): Assert we do not get
21381 called on pattern stmts.
21382 (get_later_stmt): Likewise.
21383
21384 2018-05-29 Martin Liska <mliska@suse.cz>
21385
21386 PR gcov-profile/85759
21387 * doc/gcov.texi: Document GCOV_ERROR_FILE and GCOV_EXIT_AT_ERROR
21388 env variables.
21389
21390 2018-05-29 Jakub Jelinek <jakub@redhat.com>
21391
21392 * tree-cfg.c (verify_gimple_assign_unary): Add checking for
21393 VEC_UNPACK_*_EXPR.
21394 (verify_gimple_assign_binary): Check TYPE_VECTOR_SUBPARTS for
21395 VEC_PACK_*_EXPR.
21396
21397 PR target/85918
21398 * tree.def (VEC_UNPACK_FIX_TRUNC_HI_EXPR, VEC_UNPACK_FIX_TRUNC_LO_EXPR,
21399 VEC_PACK_FLOAT_EXPR): New tree codes.
21400 * tree-pretty-print.c (op_code_prio): Handle
21401 VEC_UNPACK_FIX_TRUNC_HI_EXPR and VEC_UNPACK_FIX_TRUNC_LO_EXPR.
21402 (dump_generic_node): Handle VEC_UNPACK_FIX_TRUNC_HI_EXPR,
21403 VEC_UNPACK_FIX_TRUNC_LO_EXPR and VEC_PACK_FLOAT_EXPR.
21404 * tree-inline.c (estimate_operator_cost): Likewise.
21405 * gimple-pretty-print.c (dump_binary_rhs): Handle VEC_PACK_FLOAT_EXPR.
21406 * fold-const.c (const_binop): Likewise.
21407 (const_unop): Handle VEC_UNPACK_FIX_TRUNC_HI_EXPR and
21408 VEC_UNPACK_FIX_TRUNC_LO_EXPR.
21409 * tree-cfg.c (verify_gimple_assign_unary): Likewise.
21410 (verify_gimple_assign_binary): Handle VEC_PACK_FLOAT_EXPR.
21411 * cfgexpand.c (expand_debug_expr): Handle VEC_UNPACK_FIX_TRUNC_HI_EXPR,
21412 VEC_UNPACK_FIX_TRUNC_LO_EXPR and VEC_PACK_FLOAT_EXPR.
21413 * expr.c (expand_expr_real_2): Likewise.
21414 * optabs.def (vec_packs_float_optab, vec_packu_float_optab,
21415 vec_unpack_sfix_trunc_hi_optab, vec_unpack_sfix_trunc_lo_optab,
21416 vec_unpack_ufix_trunc_hi_optab, vec_unpack_ufix_trunc_lo_optab): New
21417 optabs.
21418 * optabs.c (expand_widen_pattern_expr): For
21419 VEC_UNPACK_FIX_TRUNC_HI_EXPR and VEC_UNPACK_FIX_TRUNC_LO_EXPR use
21420 sign from result type rather than operand's type.
21421 (expand_binop_directly): For vec_packu_float_optab and
21422 vec_packs_float_optab allow result type to be different from operand's
21423 type.
21424 * optabs-tree.c (optab_for_tree_code): Handle
21425 VEC_UNPACK_FIX_TRUNC_HI_EXPR, VEC_UNPACK_FIX_TRUNC_LO_EXPR and
21426 VEC_PACK_FLOAT_EXPR. Formatting fixes.
21427 * tree-vect-generic.c (expand_vector_operations_1): Handle
21428 VEC_UNPACK_FIX_TRUNC_HI_EXPR, VEC_UNPACK_FIX_TRUNC_LO_EXPR and
21429 VEC_PACK_FLOAT_EXPR.
21430 * tree-vect-stmts.c (supportable_widening_operation): Handle
21431 FIX_TRUNC_EXPR.
21432 (supportable_narrowing_operation): Handle FLOAT_EXPR.
21433 * config/i386/i386.md (fixprefix, floatprefix): New code attributes.
21434 * config/i386/sse.md (*float<floatunssuffix>v2div2sf2): Rename to ...
21435 (float<floatunssuffix>v2div2sf2): ... this. Formatting fix.
21436 (vpckfloat_concat_mode, vpckfloat_temp_mode, vpckfloat_op_mode): New
21437 mode attributes.
21438 (vec_pack<floatprefix>_float_<mode>): New expander.
21439 (vunpckfixt_mode, vunpckfixt_model, vunpckfixt_extract_mode): New mode
21440 attributes.
21441 (vec_unpack_<fixprefix>fix_trunc_lo_<mode>,
21442 vec_unpack_<fixprefix>fix_trunc_hi_<mode>): New expanders.
21443 * doc/md.texi (vec_packs_float_@var{m}, vec_packu_float_@var{m},
21444 vec_unpack_sfix_trunc_hi_@var{m}, vec_unpack_sfix_trunc_lo_@var{m},
21445 vec_unpack_ufix_trunc_hi_@var{m}, vec_unpack_ufix_trunc_lo_@var{m}):
21446 Document.
21447 * doc/generic.texi (VEC_UNPACK_FLOAT_HI_EXPR,
21448 VEC_UNPACK_FLOAT_LO_EXPR): Fix pasto in description.
21449 (VEC_UNPACK_FIX_TRUNC_HI_EXPR, VEC_UNPACK_FIX_TRUNC_LO_EXPR,
21450 VEC_PACK_FLOAT_EXPR): Document.
21451
21452 2018-05-29 Richard Biener <rguenther@suse.de>
21453
21454 * tree-vectorizer.h (struct vec_info): Add stmt_vec_infos
21455 member.
21456 (stmt_vec_info_vec): Make pointer.
21457 (init_stmt_vec_info_vec): Remove.
21458 (free_stmt_vec_info_vec): Likewise.
21459 (set_stmt_vec_info_vec): New function.
21460 (free_stmt_vec_infos): Likewise.
21461 (vinfo_for_stmt): Adjust for stmt_vec_info_vec indirection.
21462 (set_vinfo_for_stmt): Likewise.
21463 (get_earlier_stmt): Likewise.
21464 (get_later_stmt): Likewise.
21465 * tree-vectorizer.c (stmt_vec_info_vec): Make pointer.
21466 (vec_info::vec_info): Allocate stmt_vec_infos and set the global.
21467 (vec_info::~vec_info): Free stmt_vec_infos.
21468 (vectorize_loops): Set the global stmt_vec_info_vec to NULL.
21469 Remove old init_stmt_vec_info_vec/free_stmt_vec_info_vec calls.
21470 (pass_slp_vectorize::execute): Likewise.
21471 * tree-vect-stmts.c (init_stmt_vec_info_vec): Remove.
21472 (free_stmt_vec_info_vec): Likewise.
21473 (set_stmt_vec_info_vec): New function.
21474 (free_stmt_vec_infos): Likewise.
21475 * tree-vect-loop.c (_loop_vec_info::~_loop_vec_info): Set
21476 the global stmt_vec_info_vec.
21477 * tree-parloops.c (gather_scalar_reductions): Use
21478 set_stmt_vec_info_vec/free_stmt_vec_infos and maintain a local
21479 vector.
21480
21481 2018-05-29 Richard Biener <rguenther@suse.de>
21482
21483 * dominance.c (iterate_fix_dominators): Push/pop TV_DOMINANCE.
21484
21485 2018-05-29 Martin Liska <mliska@suse.cz>
21486 David Malcolm <dmalcolm@redhat.com>
21487
21488 * vec.c (test_reverse): New.
21489 (vec_c_tests): Add new test.
21490 * vec.h (vl_ptr>::reverse): New function.
21491
21492 2018-05-29 Gerald Pfeifer <gerald@pfeifer.com>
21493
21494 * config.gcc: Identify FreeBSD 3.x and 4.x as unsupported.
21495
21496 * config/freebsd-spec.h (FBSD_LIB_SPEC): Only consider FreeBSD 5
21497 and later.
21498
21499 2018-05-28 Bernd Edlinger <bernd.edlinger@hotmail.de>
21500
21501 * tree-dump.c (dump_node): Use splay_tree_delete_pointers.
21502
21503 2018-05-28 Richard Biener <rguenther@suse.de>
21504
21505 PR tree-optimization/85933
21506 * tree-vect-data-refs.c (vect_record_base_alignments): Only
21507 look at stmts marked as vectorizable.
21508
21509 2018-05-28 Richard Biener <rguenther@suse.de>
21510
21511 PR tree-optimization/85934
21512 * tree-vect-generic.c (expand_vector_operations_1): Hoist
21513 vector boolean check before scalar optimization.
21514
21515 2018-05-28 Jakub Jelinek <jakub@redhat.com>
21516
21517 * doc/invoke.texi (ARM Options): Use @item instead of @itemx
21518 for armv5te.
21519
21520 2018-05-28 Mark Wielaard <mark@klomp.org>
21521
21522 * dwarf2asm.c (dw2_asm_output_delta_uleb128): Add brackets around lab2
21523 if it is an expression containing a minus sign.
21524
21525 2018-05-27 John David Anglin <danglin@gcc.gnu.org>
21526
21527 * config/pa/pa-linux.h (NEED_INDICATE_EXEC_STACK): Define to 0.
21528
21529 2018-05-27 Paul Koning <ni1d@arrl.net>
21530
21531 * config/pdp11/pdp11.md (truncsihi2): Remove.
21532
21533 2018-05-27 Monk Chiang <sh.chiang04@gmail.com>
21534 Chung-Ju Wu <jasonwucj@gmail.com>
21535
21536 * config/nds32/nds32-intrinsic.md (unaligned_storedi): Modify patterns
21537 implementation.
21538 (unaligned_store_dw): Ditto.
21539 * config/nds32/nds32-memory-manipulation.c
21540 (nds32_expand_movmemsi_loop_known_size): Refactoring implementation.
21541 (nds32_gen_dup_4_byte_to_word_value): Rename to ...
21542 (nds32_gen_dup_4_byte_to_word_value_aux): ... this.
21543 (emit_setmem_word_loop): Rename to ...
21544 (emit_setmem_doubleword_loop): ... this.
21545 (nds32_gen_dup_4_byte_to_word_value): New function.
21546 (nds32_gen_dup_8_byte_to_double_word_value): New function.
21547 (nds32_expand_setmem_loop): Refine implementation.
21548 (nds32_expand_setmem_loop_v3m): Ditto.
21549 * config/nds32/nds32-multiple.md (unaligned_store_update_base_dw): New
21550 pattern.
21551
21552 2018-05-27 Chung-Ju Wu <jasonwucj@gmail.com>
21553
21554 * config/nds32/nds32.md (bswapsi2, bswaphi2): New patterns.
21555
21556 2018-05-27 Chung-Ju Wu <jasonwucj@gmail.com>
21557
21558 * config/nds32/nds32.c (nds32_attribute_table): Add "no_prologue".
21559 (nds32_init_machine_status): Initialize machine->attr_naked_p and
21560 machine->attr_no_prologue_p.
21561 (nds32_compute_stack_frame): Check "naked" and "no_prologue" attributes.
21562 (nds32_naked_function_p): Handle "naked" and "no_prologue" attributes.
21563 (nds32_expand_epilogue): Consider attr_naked_p.
21564 (nds32_expand_epilogue_v3pop): Likewise.
21565 (nds32_can_use_return_insn): Likewise.
21566 * config/nds32/nds32.h (machine_function): Add attr_naked_p and
21567 attr_no_prologue_p fields.
21568 * config/nds32/nds32.opt (mret-in-naked-func): New option.
21569
21570 2018-05-27 Jakub Jelinek <jakub@redhat.com>
21571
21572 PR target/85918
21573 * config/i386/i386.md (fixunssuffix, floatunssuffix): New code
21574 attributes.
21575 * config/i386/sse.md
21576 (<floatsuffix>float<sseintvecmodelower><mode>2<mask_name><round_name>):
21577 Rename to ...
21578 (float<floatunssuffix><sseintvecmodelower><mode>2<mask_name><round_name>):
21579 ... this.
21580 (<floatsuffix>float<sselongvecmodelower><mode>2<mask_name><round_name>):
21581 Rename to ...
21582 (float<floatunssuffix><sselongvecmodelower><mode>2<mask_name><round_name>):
21583 ... this.
21584 (*<floatsuffix>floatv2div2sf2): Rename to ...
21585 (*float<floatunssuffix>v2div2sf2): ... this.
21586 (<floatsuffix>floatv2div2sf2_mask): Rename to ...
21587 (float<floatunssuffix>v2div2sf2_mask): ... this.
21588 (*<floatsuffix>floatv2div2sf2_mask_1): Rename to ...
21589 (*float<floatunssuffix>v2div2sf2_mask_1): ... this.
21590 (<fixsuffix>fix_truncv8dfv8si2<mask_name><round_saeonly_name>): Rename
21591 to ...
21592 (fix<fixunssuffix>_truncv8dfv8si2<mask_name><round_saeonly_name>):
21593 ... this.
21594 (<fixsuffix>fix_trunc<mode><sseintvecmodelower>2<mask_name><round_saeonly_name>):
21595 Rename to ...
21596 (fix<fixunssuffix>_trunc<mode><sseintvecmodelower>2<mask_name><round_saeonly_name>):
21597 ... this.
21598 (<fixsuffix>fix_trunc<mode><sselongvecmodelower>2<mask_name><round_saeonly_name>):
21599 Rename to ...
21600 (fix<fixunssuffix>_trunc<mode><sselongvecmodelower>2<mask_name><round_saeonly_name>):
21601 ... this.
21602 (<fixsuffix>fix_truncv2sfv2di2<mask_name>): Rename to ...
21603 (fix<fixunssuffix>_truncv2sfv2di2<mask_name>): ... this.
21604 (vec_pack_ufix_trunc_<mode>): Use gen_fixuns_truncv8dfv8si2 instead of
21605 gen_ufix_truncv8dfv8si2.
21606 * config/i386/i386-builtin.def (__builtin_ia32_cvttpd2uqq256_mask,
21607 __builtin_ia32_cvttpd2uqq128_mask, __builtin_ia32_cvttps2uqq256_mask,
21608 __builtin_ia32_cvttps2uqq128_mask, __builtin_ia32_cvtuqq2ps256_mask,
21609 __builtin_ia32_cvtuqq2ps128_mask, __builtin_ia32_cvtuqq2pd256_mask,
21610 __builtin_ia32_cvtuqq2pd128_mask, __builtin_ia32_cvttpd2udq512_mask,
21611 __builtin_ia32_cvtuqq2ps512_mask, __builtin_ia32_cvtuqq2pd512_mask,
21612 __builtin_ia32_cvttps2uqq512_mask, __builtin_ia32_cvttpd2uqq512_mask):
21613 Use fixuns instead ufix or floatuns instead ufloat in CODE_FOR_ names.
21614
21615 2018-05-24 H.J. Lu <hongjiu.lu@intel.com>
21616
21617 PR target/85900
21618 PR target/85345
21619 * varasm.c (assemble_alias): Lookup ifunc attribute on error.
21620
21621 2018-05-25 Jim Wilson <jimw@sifive.com>
21622
21623 * config/riscv/riscv-protos.h (riscv_epilogue_uses): New.
21624 * config/riscv/riscv.c (struct machine_function): Add
21625 interrupt_handler_p and attribute_checked_p fields.
21626 (riscv_attribute_table): Add interrupt.
21627 (riscv_interrupt_type_p): New.
21628 (riscv_save_reg_p): Save extra regs for interrupt handler.
21629 (riscv_use_save_libcall): Return false for interrupt handler.
21630 (riscv_first_stack_step): Add forward declaration.
21631 (riscv_compute_frame_info): New local interrupt_save_t1. Set it
21632 for interrupt handler with large frame. Use it for saved reg list.
21633 (riscv_expand_prologue): Move flag_stack_usage_info support to
21634 eliminate duplication.
21635 (riscv_expand_epilogue): Generate mret for interrupt handler.
21636 (riscv_epilogue_uses): New.
21637 (riscv_can_use_return_insn): Return false for interrupt handler.
21638 (riscv_function_ok_for_sibcall): Likewise.
21639 (riscv_set_current_function): Add interrupt handler support.
21640 * config/riscv/riscv.h (EPILOGUE_USES): Call riscv_epilogue_uses.
21641 * config/riscv/riscv.md (UNSPECV_MRET): New.
21642 (GP_REGNUM): New.
21643 (riscv_frflags, riscv_fsflags): Use tab after opcode.
21644 (riscv_mret): New.
21645 * doc/extend.texi (RISC-V Function Attributes) <interrupt>: New.
21646
21647 2018-05-25 Bill Schmidt <wschmidt@linux.ibm.com>
21648
21649 PR tree-optimization/85712
21650 * gimple-ssa-strength-reduction.c (replace_one_candidate): Skip if
21651 this candidate has already been replaced in-situ by a copy.
21652
21653 2018-05-25 Jason Merrill <jason@redhat.com>
21654
21655 PR c++/80485 - inline function non-zero address.
21656 * symtab.c (nonzero_address): Check DECL_COMDAT.
21657
21658 2018-05-25 Uros Bizjak <ubizjak@gmail.com>
21659
21660 PR target/83628
21661 * config/alpha/alpha.md (ashlsi3): New insn pattern.
21662 (*ashlsi_se): Rename from *ashldi_se. Define as sign
21663 extension of SImode operation. Use const123_operand predicate.
21664 (*saddsi_1): Remove.
21665 (*saddl_se_1): Ditto.
21666 (*ssubsi_1): Ditto.
21667 (*ssubl_se_1): Ditto.
21668 * config/alpha/predicates.md (const123_operand): New predicate.
21669 * config/alpha/constraints.md (P): Use IN_RANGE.
21670
21671 2018-05-25 Richard Biener <rguenther@suse.de>
21672
21673 * tree-ssa-alias.h (refs_may_alias_p): Add tbaa_p bool parameter,
21674 defaulted to true.
21675 (ref_maybe_used_by_stmt_p): Likewise.
21676 (stmt_may_clobber_ref_p): Likewise.
21677 (stmt_may_clobber_ref_p_1): Likewise.
21678 * tree-ssa-alias.c (refs_may_alias_p): Add tbaa_p bool parameter
21679 and pass it along.
21680 (ref_maybe_used_by_stmt_p): Likewise.
21681 (stmt_may_clobber_ref_p): Likewise.
21682 (stmt_may_clobber_ref_p_1): Likewise.
21683 * tree-vect-data-refs.c (vect_slp_analyze_node_dependences): Use
21684 the alias oracle to disambiguate DRs with stmts DR analysis
21685 couldn't handle.
21686 (vect_analyze_data_refs): Do not give up on not analyzable
21687 DRs for BB vectorization. Remove code truncating the dataref
21688 vector.
21689
21690 2018-05-25 Jakub Jelinek <jakub@redhat.com>
21691
21692 PR target/85832
21693 * config/i386/sse.md (<avx512>_eq<mode>3<mask_scalar_merge_name>_1):
21694 Add (=Yk,v,C) variant using vptestm insn. Use TARGET_AVX512BW
21695 in test instead of TARGET_AVX512F for VI12_AVX512VL iterator.
21696
21697 2018-05-25 Richard Biener <rguenther@suse.de>
21698
21699 * tree-vect-data-refs.c (vect_find_stmt_data_reference): New
21700 function, combining stmt data ref gathering and fatal analysis
21701 parts.
21702 (vect_analyze_data_refs): Remove now redudnant code and simplify.
21703 * tree-vect-loop.c (vect_get_datarefs_in_loop): Factor out from
21704 vect_analyze_loop_2 and use vect_find_stmt_data_reference.
21705 * tree-vect-slp.c (vect_slp_bb): Use vect_find_stmt_data_reference.
21706 * tree-vectorizer.h (vect_find_stmt_data_reference): Declare.
21707
21708 2018-05-25 Bin Cheng <bin.cheng@arm.com>
21709
21710 PR tree-optimization/85720
21711 * tree-loop-distribution.c (break_alias_scc_partitions): Don't merge
21712 SCC if all partitions are builtins.
21713 (version_loop_by_alias_check): New parameter. Generate cancelable
21714 runtime alias check if all partitions are builtins.
21715 (distribute_loop): Update call to above function.
21716
21717 2018-05-25 Bin Cheng <bin.cheng@arm.com>
21718
21719 * tree-outof-ssa.c (tree-ssa.h, tree-dfa.h): Include header files.
21720 (create_default_def, for_all_parms): Moved from tree-ssa-coalesce.c.
21721 (parm_default_def_partition_arg): Ditto.
21722 (set_parm_default_def_partition): Ditto.
21723 (get_parm_default_def_partitions): Ditto and make it static.
21724 (get_undefined_value_partitions): Ditto and make it static.
21725 (remove_ssa_form): Refactor call to init_var_map here.
21726 * tree-ssa-coalesce.c (build_ssa_conflict_graph): Support live range
21727 computation for loop region.
21728 (coalesce_partitions, compute_optimized_partition_bases): Ditto.
21729 (register_default_def): Delete.
21730 (for_all_parms, create_default_def): Move to tree-outof-ssa.c.
21731 (parm_default_def_partition_arg): Ditto.
21732 (set_parm_default_def_partition): Ditto.
21733 (get_parm_default_def_partitions): Ditto and make it static.
21734 (get_undefined_value_partitions): Ditto and make it static.
21735 (coalesce_with_default, coalesce_with_default): Update comment.
21736 (create_coalesce_list_for_region): New func factored out from
21737 create_outofssa_var_map.
21738 (populate_coalesce_list_for_outofssa): New func factored out from
21739 create_outofssa_var_map and coalesce_ssa_name.
21740 (create_outofssa_var_map): Delete.
21741 (coalesce_ssa_name): Refactor to support live range computation.
21742 * tree-ssa-coalesce.h (coalesce_ssa_name): Change decl.
21743 (get_parm_default_def_partitions): Delete.
21744 (get_undefined_value_partitions): Ditto.
21745 * tree-ssa-live.c (init_var_map, delete_var_map): Support live range
21746 computation for loop region.
21747 (new_tree_live_info, loe_visit_block): Ditto.
21748 (live_worklist, set_var_live_on_entry): Ditto.
21749 (calculate_live_on_exit, verify_live_on_entry): Ditto.
21750 * tree-ssa-live.h (struct _var_map): New fields.
21751 (init_var_map): Change decl.
21752 (region_contains_p): New.
21753
21754 2018-05-25 Bin Cheng <bin.cheng@arm.com>
21755
21756 * tree-ssa-live.h (live_merge_and_clear): Delete.
21757
21758 2018-05-25 Richard Biener <rguenther@suse.de>
21759
21760 PR c++/85912
21761 * tree-dump.c (dequeue_and_dump): Remove access to removed
21762 operand 2 of a SWITCH_EXPR.
21763
21764 2018-05-25 Richard Sandiford <richard.sandiford@linaro.org>
21765
21766 * doc/sourcebuild.texi (vect_double_cond_arith): Include
21767 multiplication and division.
21768 * doc/md.texi (cond_mul@var{m}, cond_div@var{m}, cond_mod@var{m})
21769 (cond_udiv@var{m}, cond_umod@var{m}): Document.
21770 * optabs.def (cond_smul_optab, cond_sdiv_optab, cond_smod_optab)
21771 (cond_udiv_optab, cond_umod_optab): New optabs.
21772 * internal-fn.def (IFN_COND_MUL, IFN_COND_DIV, IFN_COND_MOD)
21773 (IFN_COND_RDIV): New internal functions.
21774 * internal-fn.c (get_conditional_internal_fn): Handle TRUNC_DIV_EXPR,
21775 TRUNC_MOD_EXPR and RDIV_EXPR.
21776 * match.pd (UNCOND_BINARY, COND_BINARY): Handle them.
21777 * config/aarch64/iterators.md (UNSPEC_COND_MUL, UNSPEC_COND_DIV):
21778 New unspecs.
21779 (SVE_INT_BINARY): Include mult.
21780 (SVE_COND_FP_BINARY): Include UNSPEC_MUL and UNSPEC_DIV.
21781 (optab, sve_int_op): Handle mult.
21782 (optab, sve_fp_op, commutative): Handle UNSPEC_COND_MUL and
21783 UNSPEC_COND_DIV.
21784 * config/aarch64/aarch64-sve.md (cond_<optab><mode>): New pattern
21785 for SVE_INT_BINARY_SD.
21786
21787 2018-05-25 Richard Sandiford <richard.sandiford@linaro.org>
21788
21789 * config/aarch64/iterators.md (SVE_INT_BINARY_SD): New code iterator.
21790 (optab, sve_int_op): Handle div and udiv.
21791 * config/aarch64/aarch64-sve.md (<optab><mode>3): New expander
21792 for SVE_INT_BINARY_SD.
21793 (*<optab><mode>3): New insn for the same.
21794
21795 2018-05-25 Richard Sandiford <richard.sandiford@linaro.org>
21796
21797 * tree-vect-patterns.c: Include predict.h.
21798 (vect_recog_divmod_pattern): Restrict check for division support
21799 to when optimizing for size.
21800
21801 2018-05-25 Richard Sandiford <richard.sandiford@linaro.org>
21802
21803 * doc/sourcebuild.texi (vect_double_cond_arith: Document.
21804 * gimple-match.h (gimple_match_op::MAX_NUM_OPS): Bump to 4.
21805 (gimple_match_op::gimple_match_op): Add an overload for 4 operands.
21806 (gimple_match_op::set_op): Likewise.
21807 (gimple_resimplify4): Declare.
21808 * genmatch.c (get_operand_type): Handle CFN_COND_* functions.
21809 (expr::gen_transform): Likewise.
21810 (decision_tree::gen): Generate a simplification routine for 4 operands.
21811 * gimple-match-head.c (gimple_simplify): Add an overload for
21812 4 operands. In the top-level function, handle up to 4 call
21813 arguments and call gimple_resimplify4.
21814 (gimple_resimplify4): New function.
21815 (build_call_internal): Pass a fourth operand.
21816 (maybe_push_to_seq): Likewise.
21817 * match.pd (UNCOND_BINARY, COND_BINARY): New operator lists.
21818 Fold VEC_COND_EXPRs of an operation and a default value into
21819 an IFN_COND_* function if possible.
21820 * config/aarch64/iterators.md (UNSPEC_COND_MAX, UNSPEC_COND_MIN):
21821 New unspecs.
21822 (SVE_COND_FP_BINARY): Include them.
21823 (optab, sve_fp_op): Handle them.
21824 (SVE_INT_BINARY_REV): New code iterator.
21825 (SVE_COND_FP_BINARY_REV): New int iterator.
21826 (commutative): New int attribute.
21827 * config/aarch64/aarch64-protos.h (aarch64_sve_prepare_conditional_op):
21828 Declare.
21829 * config/aarch64/aarch64.c (aarch64_sve_prepare_conditional_op): New
21830 function.
21831 * config/aarch64/aarch64-sve.md (cond_<optab><mode>): Use it.
21832 (*cond_<optab><mode>): New patterns for reversed operands.
21833
21834 2018-05-25 Richard Biener <rguenther@suse.de>
21835
21836 * tree-vectorizer.h (STMT_VINFO_GROUP_*, GROUP_*): Remove.
21837 (DR_GROUP_*): New, assert we have non-NULL ->data_ref_info.
21838 (REDUC_GROUP_*): New, assert we have NULL ->data_ref_info.
21839 (STMT_VINFO_GROUPED_ACCESS): Adjust.
21840 * tree-vect-data-refs.c (everywhere): Adjust users.
21841 * tree-vect-loop.c (everywhere): Likewise.
21842 * tree-vect-slp.c (everywhere): Likewise.
21843 * tree-vect-stmts.c (everywhere): Likewise.
21844 * tree-vect-patterns.c (vect_reassociating_reduction_p): Likewise.
21845
21846 2018-05-25 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
21847
21848 * configure.ac (gcc_cv_as_section_has_e): Move to common section.
21849 Rename to...
21850 (gcc_cv_as_section_exclude): ... this.
21851 Try Solaris as #exclude syntax.
21852 * configure: Regenerate.
21853 * config.in: Regenerate.
21854 * config/i386/i386.c (i386_solaris_elf_named_section): Handle
21855 SECTION_EXCLUDE.
21856 * config/sparc/sparc.c (sparc_solaris_elf_asm_named_section)
21857 [HAVE_GAS_SECTION_EXCLUDE]: Handle SECTION_EXCLUDE.
21858
21859 * varasm.c (default_elf_asm_named_section): Don't check if
21860 HAVE_GAS_SECTION_EXCLUDE is defined.
21861
21862 2018-05-25 Richard Sandiford <richard.sandiford@linaro.org>
21863
21864 * doc/md.texi: Update the documentation of the cond_* optabs
21865 to mention the new final operand. Fix GET_MODE_NUNITS call.
21866 Describe the scalar case too.
21867 * internal-fn.def (IFN_EXTRACT_LAST): Change type to fold_left.
21868 * internal-fn.c (expand_cond_unary_optab_fn): Expect 3 operands
21869 instead of 2.
21870 (expand_cond_binary_optab_fn): Expect 4 operands instead of 3.
21871 (get_conditional_internal_fn): Update comment.
21872 * tree-vect-loop.c (vectorizable_reduction): Pass the original
21873 accumulator value as a final argument to conditional functions.
21874 * config/aarch64/aarch64-sve.md (cond_<optab><mode>): Turn into
21875 a define_expand and add an "else" operand. Assert for now that
21876 the else operand is equal to operand 2. Use SVE_INT_BINARY and
21877 SVE_COND_FP_BINARY instead of SVE_COND_INT_OP and SVE_COND_FP_OP.
21878 (*cond_<optab><mode>): New patterns.
21879 * config/aarch64/iterators.md (UNSPEC_COND_SMAX, UNSPEC_COND_UMAX)
21880 (UNSPEC_COND_SMIN, UNSPEC_COND_UMIN, UNSPEC_COND_AND, UNSPEC_COND_ORR)
21881 (UNSPEC_COND_EOR): Delete.
21882 (optab): Remove associated mappings.
21883 (SVE_INT_BINARY): New code iterator.
21884 (sve_int_op): Remove int attribute and add "minus" to the code
21885 attribute.
21886 (SVE_COND_INT_OP): Delete.
21887 (SVE_COND_FP_OP): Rename to...
21888 (SVE_COND_FP_BINARY): ...this.
21889
21890 2018-05-25 Richard Sandiford <richard.sandiford@linaro.org>
21891
21892 * optabs.c (can_reuse_operands_p): New function.
21893 (maybe_legitimize_operands): Try to reuse the results for
21894 earlier operands.
21895
21896 2018-05-24 Uros Bizjak <ubizjak@gmail.com>
21897
21898 * config/i386/sse.md (cvtusi2<ssescalarmodesuffix>64<round_name>):
21899 Add {q} suffix to insn mnemonic.
21900
21901 2018-05-23 Jozef Lawrynowicz <jozef.l@mittosystems.com>
21902
21903 * config/msp430/msp430.c (TARGET_WARN_FUNC_RETURN): Define.
21904 (msp430_warn_func_return): New.
21905
21906 2018-05-24 Roger Sayle <roger@nextmovesoftware.com>
21907
21908 * fold-const.c (tree_nonzero_bits): New function.
21909 * fold-const.h (tree_nonzero_bits): Likewise.
21910 * match.pd (POPCOUNT): New patterns to fold BUILTIN_POPCOUNT and
21911 friends. POPCOUNT(x&1) => x&1, POPCOUNT(x)==0 => x==0, etc.
21912
21913 2018-05-24 H.J. Lu <hongjiu.lu@intel.com>
21914
21915 PR target/85900
21916 PR target/85345
21917 * varasm.c (assemble_alias): Check ifunc_resolver only on
21918 FUNCTION_DECL.
21919
21920 2018-05-24 Uros Bizjak <ubizjak@gmail.com>
21921
21922 PR target/85903
21923 * config/i386/sse.md (movdi_to_sse): Do not generate pseudo
21924 when memory input operand is handled.
21925
21926 2018-05-24 Luis Machado <luis.machado@linaro.org>
21927
21928 * config/aarch64/aarch64.c (qdf24xx_addrcost_table): New static
21929 global.
21930 (qdf24xx_tunings) <addr_costs>: Set to qdf24xx_addrcost_table.
21931
21932 2018-05-24 Richard Sandiford <richard.sandiford@linaro.org>
21933
21934 * match.pd: Delay FMA folds until after vectorization.
21935
21936 2018-05-24 Andre Vieira <andre.simoesdiasvieira@arm.com>
21937
21938 PR target/83009
21939 * config/aarch64/predicates.md (aarch64_mem_pair_lanes_operand): Make
21940 address check not strict.
21941
21942 2018-05-24 Richard Sandiford <richard.sandiford@linaro.org>
21943
21944 * gimple-match.h (gimple_match_op): New class.
21945 (mprts_hook): Replace parameters with a gimple_match_op *.
21946 (maybe_build_generic_op): Likewise.
21947 (gimple_simplified_result_is_gimple_val): Replace parameters with
21948 a const gimple_match_op *.
21949 (gimple_simplify): Replace code_helper * and tree * parameters with
21950 a gimple_match_op * parameter.
21951 (gimple_resimplify1): Replace code_helper *, tree and tree *
21952 parameters with a gimple_match_op * parameter.
21953 (gimple_resimplify2): Likewise.
21954 (gimple_resimplify3): Likewise.
21955 (maybe_push_res_to_seq): Replace code_helper, tree and tree *
21956 parameters with a gimple_match_op * parameter.
21957 * gimple-match-head.c (gimple_simplify): Change prototypes of
21958 auto-generated functions to take a gimple_match_op * instead of
21959 separate code_helper * and tree * parameters. Make the same
21960 change in the top-level overload and update calls to the
21961 gimple_resimplify routines. Update calls to the auto-generated
21962 functions and to maybe_push_res_to_seq in the publicly-facing
21963 operation-specific gimple_simplify overloads.
21964 (gimple_match_op::MAX_NUM_OPS): Define.
21965 (gimple_resimplify1): Replace rcode and ops with a single res_op
21966 parameter. Update call to gimple_simplify.
21967 (gimple_resimplify2): Likewise.
21968 (gimple_resimplify3): Likewise.
21969 (mprts_hook): Replace parameters with a gimple_match_op *.
21970 (maybe_build_generic_op): Likewise.
21971 (build_call_internal): Replace type, nargs and ops with
21972 a gimple_match_op *.
21973 (maybe_push_res_to_seq): Replace res_code, type and ops parameters
21974 with a single gimple_match_op *. Update calls to mprts_hook,
21975 build_call_internal and gimple_simplified_result_is_gimple_val.
21976 Factor out code that is common to the tree_code and combined_fn cases.
21977 * genmatch.c (expr::gen_transform): Replace tem_code and
21978 tem_ops with a gimple_match_op called tem_op. Update calls
21979 to the gimple_resimplify functions and maybe_push_res_to_seq.
21980 (dt_simplify::gen_1): Manipulate res_op instead of res_code and
21981 res_ops. Update call to the gimple_resimplify functions.
21982 (dt_simplify::gen): Pass res_op instead of res_code and res_ops.
21983 (decision_tree::gen): Make the functions take a gimple_match_op *
21984 called res_op instead of separate res_code and res_ops parameters.
21985 Update call accordingly.
21986 * gimple-fold.c (replace_stmt_with_simplification): Replace rcode
21987 and ops with a single res_op parameter. Update calls to
21988 maybe_build_generic_op and maybe_push_res_to_seq.
21989 (fold_stmt_1): Update calls to gimple_simplify and
21990 replace_stmt_with_simplification.
21991 (gimple_fold_stmt_to_constant_1): Update calls to gimple_simplify
21992 and gimple_simplified_result_is_gimple_val.
21993 * tree-cfgcleanup.c (cleanup_control_expr_graph): Update call to
21994 gimple_simplify.
21995 * tree-ssa-sccvn.c (vn_lookup_simplify_result): Replace parameters
21996 with a gimple_match_op *.
21997 (vn_nary_build_or_lookup): Likewise. Update call to
21998 vn_nary_build_or_lookup_1.
21999 (vn_nary_build_or_lookup_1): Replace rcode, type and ops with a
22000 gimple_match_op *. Update calls to the gimple_resimplify routines
22001 and to gimple_simplified_result_is_gimple_val.
22002 (vn_nary_simplify): Update call to vn_nary_build_or_lookup_1.
22003 Use gimple_match_op::MAX_NUM_OPS instead of a hard-coded 3.
22004 (vn_reference_lookup_3): Update call to vn_nary_build_or_lookup.
22005 (visit_nary_op): Likewise.
22006 (visit_reference_op_load): Likewise.
22007
22008 2018-05-23 Luis Machado <luis.machado@linaro.org>
22009
22010 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Use correct type
22011 modifier for printing the step amount.
22012
22013 2018-05-23 Jozef Lawrynowicz <jozef.l@somniumtech.com>
22014
22015 PR target/78849
22016 * tree.c (build_common_tree_nodes): Dont set TYPE_SIZE for __intN
22017 types.
22018
22019 2018-05-23 Segher Boessenkool <segher@kernel.crashing.org>
22020
22021 * doc/sourcebuild.texi (Endianness): New subsubsection.
22022
22023 2018-05-23 Luis Machado <luis.machado@linaro.org>
22024
22025 * config/aarch64/aarch64-protos.h (cpu_prefetch_tune)
22026 <prefetch_dynamic_strides>: New const bool field.
22027 * config/aarch64/aarch64.c (generic_prefetch_tune): Update to include
22028 prefetch_dynamic_strides.
22029 (exynosm1_prefetch_tune): Likewise.
22030 (thunderxt88_prefetch_tune): Likewise.
22031 (thunderx_prefetch_tune): Likewise.
22032 (thunderx2t99_prefetch_tune): Likewise.
22033 (qdf24xx_prefetch_tune): Likewise. Set prefetch_dynamic_strides to
22034 false.
22035 (aarch64_override_options_internal): Update to set
22036 PARAM_PREFETCH_DYNAMIC_STRIDES.
22037 * doc/invoke.texi (prefetch-dynamic-strides): Document new option.
22038 * params.def (PARAM_PREFETCH_DYNAMIC_STRIDES): New.
22039 * params.h (PARAM_PREFETCH_DYNAMIC_STRIDES): Define.
22040 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Account for
22041 prefetch-dynamic-strides setting.
22042
22043 2018-05-23 Luis Machado <luis.machado@linaro.org>
22044
22045 * config/aarch64/aarch64-protos.h (cpu_prefetch_tune)
22046 <minimum_stride>: New const int field.
22047 * config/aarch64/aarch64.c (generic_prefetch_tune): Update to include
22048 minimum_stride field defaulting to -1.
22049 (exynosm1_prefetch_tune): Likewise.
22050 (thunderxt88_prefetch_tune): Likewise.
22051 (thunderx_prefetch_tune): Likewise.
22052 (thunderx2t99_prefetch_tune): Likewise.
22053 (qdf24xx_prefetch_tune) <minimum_stride>: Set to 2048.
22054 <default_opt_level>: Set to 3.
22055 (aarch64_override_options_internal): Update to set
22056 PARAM_PREFETCH_MINIMUM_STRIDE.
22057 * doc/invoke.texi (prefetch-minimum-stride): Document new option.
22058 * params.def (PARAM_PREFETCH_MINIMUM_STRIDE): New.
22059 * params.h (PARAM_PREFETCH_MINIMUM_STRIDE): Define.
22060 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Return false if
22061 stride is constant and is below the minimum stride threshold.
22062
22063 2018-05-23 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
22064
22065 * config/arm/arm-cpus.in (mode26): Delete.
22066 (armv4): Delete mode26 reference.
22067 * config/arm/arm.c (arm_configure_build_target): Delete use of
22068 isa_bit_mode26.
22069
22070 2018-05-23 Uros Bizjak <ubizjak@gmail.com>
22071
22072 * config/i386/i386.md (*floatuns<SWI48:mode><MODEF:mode>2_avx512):
22073 New insn pattern.
22074 (floatunssi<mode>2): Also enable for AVX512F and TARGET_SSE_MATH.
22075 Rewrite expander pattern. Emit gen_floatunssi<mode>2_i387_with_xmm
22076 for non-SSE modes.
22077 (floatunsdisf2): Rewrite expander pattern. Hanlde TARGET_AVX512F.
22078 (floatunsdidf2): Ditto.
22079
22080 2018-05-23 Uros Bizjak <ubizjak@gmail.com>
22081
22082 * config/i386/i386.md (fixuns_trunc<mode>di2): New insn pattern.
22083 (fixuns_trunc<mode>si2_avx512f): Ditto.
22084 (*fixuns_trunc<mode>si2_avx512f_zext): Ditto.
22085 (fixuns_trunc<mode>si2): Also enable for AVX512F and TARGET_SSE_MATH.
22086 Emit fixuns_trunc<mode>si2_avx512f for AVX512F targets.
22087
22088 2018-05-23 Alexander Monakov <amonakov@ispras.ru>
22089
22090 PR rtl-optimization/79985
22091 * df-scan.c (df_insn_refs_collect): Remove special case for
22092 global registers and asm statements.
22093
22094 2018-05-23 Alexander Monakov <amonakov@ispras.ru>
22095
22096 * extend.texi (Global Register Variables): Rewrite the bullet list.
22097 Note that the register is available for allocation. Note that access
22098 via inline asm must use constraints. Add note about async-signal
22099 handlers. Remove paragraph about automagic register selection.
22100
22101 2018-05-23 Richard Biener <rguenther@suse.de>
22102
22103 * tree-ssa-sccvn.c (vn_reference_lookup_3): Remove restriction
22104 of fixed offset from memset VN.
22105
22106 2018-05-23 Bill Schmidt <wschmidt@linux.ibm.com>
22107
22108 * gimple-ssa-strength-reduction.c (struct slsr_cand_d): Add
22109 first_interp field.
22110 (alloc_cand_and_find_basis): Initialize first_interp field.
22111 (slsr_process_mul): Modify first_interp field.
22112 (slsr_process_add): Likewise.
22113 (slsr_process_cast): Modify first_interp field for each new
22114 interpretation.
22115 (slsr_process_copy): Likewise.
22116 (dump_candidate): Dump first_interp field.
22117 (replace_mult_candidate): Process all interpretations, not just
22118 subsequent ones.
22119 (replace_rhs_if_not_dup): Likewise.
22120 (replace_one_candidate): Likewise.
22121
22122 2018-05-23 Wilco Dijkstra <wdijkstr@arm.com>
22123
22124 * config/aarch64/aarch64.c (aarch64_use_frame_pointer):
22125 Add new boolean.
22126 (aarch64_needs_frame_chain): New function.
22127 (aarch64_parse_override_string): Set aarch64_use_frame_pointer.
22128
22129 2018-05-23 Sudakshina Das <sudi.das@arm.com>
22130
22131 PR target/84882
22132 * common/config/aarch64/aarch64-common.c (aarch64_handle_option):
22133 Check val before adding MASK_STRICT_ALIGN to opts->x_target_flags.
22134 * config/aarch64/aarch64.opt (mstrict-align): Remove RejectNegative.
22135 * config/aarch64/aarch64.c (aarch64_attributes): Mark allow_neg
22136 as true for strict-align.
22137 (aarch64_can_inline_p): Perform checks even when callee has no
22138 attributes to check for strict alignment.
22139 * doc/extend.texi (AArch64 Function Attributes): Document
22140 no-strict-align.
22141 * doc/invoke.texi: (AArch64 Options): Likewise.
22142
22143 2018-05-23 Richard Sandiford <richard.sandiford@linaro.org>
22144
22145 PR tree-optimization/85853
22146 * tree-vect-slp.c (vect_slp_analyze_node_operations): Split out
22147 the handling of the root of the node to...
22148 (vect_slp_analyze_node_operations_1): ...this new function,
22149 and run the whole thing with the child nodes' def types
22150 set according to their SLP node's def type.
22151
22152 2018-05-23 Richard Biener <rguenther@suse.de>
22153
22154 PR middle-end/85874
22155 * tree-data-ref.c (create_runtime_alias_checks): Defer
22156 and ignore overflow warnings.
22157
22158 2018-05-23 Yury Gribov <tetra2005@gmail.com>
22159
22160 PR tree-optimization/85822
22161 * tree-vrp.c (is_masked_range_test): Fix handling of negative
22162 constants.
22163
22164 2018-05-23 Richard Biener <rguenther@suse.de>
22165
22166 * tree-ssa-sccvn.c (vn_reference_lookup_3): Handle arbitrary
22167 memset constants via native_interpret_expr.
22168
22169 2018-05-22 H.J. Lu <hongjiu.lu@intel.com>
22170
22171 PR target/85345
22172 * cgraph.h (cgraph_node::create): Set ifunc_resolver for ifunc
22173 attribute.
22174 (cgraph_node::create_alias): Likewise.
22175 (cgraph_node::get_availability): Check ifunc_resolver instead
22176 of looking up ifunc attribute.
22177 * cgraphunit.c (maybe_diag_incompatible_alias): Likewise.
22178 * varasm.c (do_assemble_alias): Likewise.
22179 (assemble_alias): Likewise.
22180 (default_binds_local_p_3): Likewise.
22181 * cgraph.h (cgraph_node): Add ifunc_resolver.
22182 (cgraph_node::only_called_directly_or_aliased_p): Return false
22183 for IFUNC resolver.
22184 * lto-cgraph.c (input_node): Set ifunc_resolver for ifunc
22185 attribute.
22186 * symtab.c (symtab_node::verify_base): Verify that ifunc_resolver
22187 is equivalent to lookup_attribute ("ifunc", DECL_ATTRIBUTES (decl)).
22188 (symtab_node::binds_to_current_def_p): Check ifunc_resolver
22189 instead of looking up ifunc attribute.
22190
22191 2018-05-22 Luis Machado <luis.machado@linaro.org>
22192
22193 * config/aarch64/aarch64.md (*ashift<mode>_extv_bfiz): New pattern.
22194
22195 2018-05-22 Martin Sebor <msebor@redhat.com>
22196
22197 PR middle-end/85359
22198 * builtins.c (expand_builtin_strcpy): Call maybe_warn_nonstring_arg
22199 only when expasion succeeds.
22200 (expand_builtin_strcmp): Same.
22201 (expand_builtin_strncmp): Same.
22202
22203 2018-05-22 Martin Sebor <msebor@redhat.com>
22204
22205 * calls.c (maybe_warn_nonstring_arg): Fix a typo in a comment.
22206
22207 2018-05-22 Jackson Woodruff <jackson.woodruff@arm.com>
22208 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
22209
22210 * config/aarch64/aarch64-ldpstp.md: Replace uses of
22211 aarch64_mem_pair_operand with memory_operand and delete operand swapping
22212 code.
22213 * config/aarch64/aarch64.c (aarch64_operands_ok_for_ldpstp):
22214 Add check for legitimate_address.
22215 (aarch64_gen_adjusted_ldpstp): Swap operands where appropriate.
22216 (aarch64_swap_ldrstr_operands): New.
22217 * config/aarch64/aarch64-protos.h (aarch64_swap_ldrstr_operands):
22218 Define prototype.
22219
22220 2018-05-22 Jackson Woodruff <jackson.woodruff@arm.com>
22221 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
22222
22223 * config/aarch64/aarch64.md: New patterns to generate stp
22224 and ldp.
22225 (store_pair_sw, store_pair_dw): New patterns to generate stp for
22226 single words and double words.
22227 (load_pair_sw, load_pair_dw): Likewise.
22228 (store_pair_sf, store_pair_df, store_pair_si, store_pair_di):
22229 Delete.
22230 (load_pair_sf, load_pair_df, load_pair_si, load_pair_di):
22231 Delete.
22232 * config/aarch64/aarch64-ldpstp.md: Modify peephole
22233 for different mode ldpstp and add peephole for merged zero stores.
22234 Likewise for loads.
22235 * config/aarch64/aarch64.c (aarch64_operands_ok_for_ldpstp):
22236 Add size check.
22237 (aarch64_gen_store_pair): Rename calls to match new patterns.
22238 (aarch64_gen_load_pair): Rename calls to match new patterns.
22239 * config/aarch64/aarch64-simd.md (load_pair<mode>): Rename to...
22240 (load_pair<DREG:mode><DREG2:mode>): ... This.
22241 (store_pair<mode>): Rename to...
22242 (vec_store_pair<DREG:mode><DREG2:mode>): ... This.
22243 * config/aarch64/iterators.md (DREG, DREG2, DX2, SX, SX2, DSX):
22244 New mode iterators.
22245 (V_INT_EQUIV): Handle SImode.
22246 * config/aarch64/predicates.md (aarch64_reg_zero_or_fp_zero):
22247 New predicate.
22248
22249 2018-05-22 Martin Sebor <msebor@redhat.com>
22250
22251 PR c/85623
22252 * calls.c (maybe_warn_nonstring_arg): Use string length to set
22253 or ajust the presumed bound on an operation to avoid unnecessary
22254 warnings.
22255
22256 2018-05-22 Martin Sebor <msebor@redhat.com>
22257
22258 PR tree-optimization/85826
22259 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): Avoid
22260 assuming that a DECL necesarily has a constant size.
22261
22262 2018-05-22 Richard Sandiford <richard.sandiford@linaro.org>
22263
22264 PR middle-end/85862
22265 * internal-fn.c (expand_direct_optab_fn): Cope with a null lhs.
22266
22267 2018-05-22 Richard Biener <rguenther@suse.de>
22268
22269 PR tree-optimization/85834
22270 * tree-ssa-sccvn.c (vn_reference_lookup_3): Properly handle
22271 non-constant and non-zero memset arguments.
22272
22273 2018-05-22 Martin Liska <mliska@suse.cz>
22274
22275 PR ipa/85607
22276 * ipa-icf.c (sem_item::add_type): Do not ICE for incomplete types.
22277
22278 2018-05-22 Richard Biener <rguenther@suse.de>
22279
22280 PR tree-optimization/85863
22281 * tree-vect-stmts.c (vect_is_simple_cond): Only widen invariant
22282 comparisons when vectype is specified.
22283 (vectorizable_condition): Do not specify vectype for
22284 vect_is_simple_cond when SLP vectorizing.
22285
22286 2018-05-21 Michael Meissner <meissner@linux.ibm.com>
22287
22288 PR target/85657
22289 * config/rs6000/rs6000-c.c (rs6000_cpu_cpp_builtins): Do not
22290 define __ibm128 as long double.
22291 * config/rs6000/rs6000.c (rs6000_init_builtins): Create __ibm128
22292 as a distinct type when IEEE 128-bit support is enabled.
22293 (init_float128_ieee): Fix up conversions between IFmode and IEEE
22294 128-bit types to use the correct functions.
22295 (rs6000_expand_float128_convert): Use explicit FLOAT_EXTEND to
22296 convert between 128-bit floating point types that have different
22297 modes but the same representation, instead of using gen_lowpart to
22298 makean alias.
22299 * config/rs6000/rs6000.md (IFKF): New iterator for IFmode and
22300 KFmode.
22301 (IFKF_reg): New attributes to give the register constraints for
22302 IFmode and KFmode.
22303 (extend<mode>tf2_internal): New insns to mark an explicit
22304 conversion between 128-bit floating point types that have a
22305 different mode but share the same representation.
22306
22307 2018-05-21 Richard Sandiford <richard.sandiford@linaro.org>
22308
22309 PR tree-optimization/85814
22310 * tree-ssa-strlen.c (get_stridx_plus_constant): Cope with
22311 a null return from get_strinfo when unsharing the next
22312 strinfo in the chain.
22313
22314 2018-05-21 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
22315
22316 PR gcc/84923
22317 * varasm.c (weak_finish): Clean up weak_decls.
22318
22319 2018-05-21 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
22320
22321 * config/aarch64/aarch64.md ("unspec"): Define UNSPEC_SABAL,
22322 UNSPEC_SABDL2, UNSPEC_SADALP, UNSPEC_UABAL, UNSPEC_UABDL2,
22323 UNSPEC_UADALP values.
22324 * config/aarch64/iterators.md (ABAL): New int iterator.
22325 (ABDL2): Likewise.
22326 (ADALP): Likewise.
22327 (sur): Add mappings for the above.
22328 * config/aarch64/aarch64-simd.md (aarch64_<sur>abdl2<mode>_3):
22329 New define_insn.
22330 (aarch64_<sur>abal<mode>_4): Likewise.
22331 (aarch64_<sur>adalp<mode>_3): Likewise.
22332 (<sur>sadv16qi): New define_expand.
22333
22334 2018-05-21 Alexander Nesterovskiy <alexander.nesterovskiy@intel.com>
22335
22336 * config/i386/i386.md (*movsf_internal): AVX falsedep fix.
22337 (*movdf_internal): Ditto.
22338 (*rcpsf2_sse): Ditto.
22339 (*rsqrtsf2_sse): Ditto.
22340 (*sqrt<mode>2_sse): Ditto.
22341
22342 2018-05-21 Tamar Christina <tamar.christina@arm.com>
22343
22344 * config/aarch64/aarch64-simd.md (aarch64_eor3qv8hi): Change to
22345 eor3q<mode>4.
22346 (aarch64_bcaxqv8hi): Change to bcaxq<mode>4.
22347 * config/aarch64/aarch64-simd-builtins.def (veor3q_u8, veor3q_u32,
22348 veor3q_u64, veor3q_s8, veor3q_s16, veor3q_s32, veor3q_s64, vbcaxq_u8,
22349 vbcaxq_u32, vbcaxq_u64, vbcaxq_s8, vbcaxq_s16, vbcaxq_s32,
22350 vbcaxq_s64): New.
22351 * config/aarch64/arm_neon.h: Likewise.
22352 * config/aarch64/iterators.md (VQ_I): New.
22353
22354 2018-05-21 Alexey Brodkin <abrodkin@synopsys.com>
22355
22356 * config.gcc: Add arc/t-multilib-linux to tmake_file for
22357 arc*-*-linux*.
22358 * config/arc/t-multilib-linux: Specify MULTILIB_OPTIONS and
22359 MULTILIB_DIRNAMES
22360
22361 2018-05-20 Chung-Ju Wu <jasonwucj@gmail.com>
22362
22363 * config/nds32/constraints.md (S): New constraint.
22364 * config/nds32/nds32.md (call_internal): Use constraint S.
22365 (call_value_internal): Likewise.
22366 (sibcall_internal): Likewise.
22367 (sibcall_value_internal): Likewise.
22368
22369 2018-05-20 Kito Cheng <kito.cheng@gmail.com>
22370 Chung-Ju Wu <jasonwucj@gmail.com>
22371
22372 * config/nds32/nds32.c (nds32_register_move_cost): Take garywolf cpu
22373 into consideration.
22374
22375 2018-05-20 Kito Cheng <kito.cheng@gmail.com>
22376 Chung-Ju Wu <jasonwucj@gmail.com>
22377
22378 * config/nds32/nds32-cost.c (rtx_cost_model_t): New structure.
22379 (insn_size_16bit, insn_size_32bit): New variables for cost evaluation.
22380 (nds32_rtx_costs_impl): Simplify.
22381 (nds32_address_cost_impl): Simplify.
22382 (nds32_init_rtx_costs): New function.
22383 (nds32_rtx_costs_speed_prefer): Likewise.
22384 (nds32_rtx_costs_size_prefer): Likewise.
22385 (nds32_address_cost_speed_prefer): Likewise.
22386 (nds32_address_cost_speed_fwprop): Likewise.
22387 (nds32_address_cost_size_prefer): Likewise.
22388 * config/nds32/nds32-protos.h (nds32_init_rtx_costs): Declare.
22389 * config/nds32/nds32.c (nds32_option_override): Use
22390 nds32_init_rtx_costs function.
22391
22392 2018-05-20 Chung-Ju Wu <jasonwucj@gmail.com>
22393
22394 * config/nds32/nds32.c (nds32_asm_file_start): Output pipeline model.
22395 * config/nds32/nds32.h (TARGET_PIPELINE_N7): Define.
22396 (TARGET_PIPELINE_N8): Likewise.
22397 (TARGET_PIPELINE_N10): Likewise.
22398 (TARGET_PIPELINE_N13): Likewise.
22399 (TARGET_PIPELINE_GRAYWOLF): Likewise.
22400
22401 2018-05-19 Monk Chiang <sh.chiang04@gmail.com>
22402
22403 * config/nds32/nds32-fpu.md: Update copyright year.
22404
22405 2018-05-19 Chung-Ju Wu <jasonwucj@gmail.com>
22406
22407 * config/nds32/nds32.h (ASM_SPEC): Adjust spec rule.
22408
22409 2018-05-19 Chung-Ju Wu <jasonwucj@gmail.com>
22410
22411 * config/nds32/nds32.c
22412 (nds32_md_asm_adjust): Consider flag_inline_asm_r15 variable.
22413 * config/nds32/nds32.opt (minline-asm-r15): New option.
22414
22415 2018-05-19 Chung-Ju Wu <jasonwucj@gmail.com>
22416
22417 * common/config/nds32/nds32-common.c (TARGET_DEFAULT_TARGET_FLAGS): Add
22418 MASK_HW_ABS.
22419 * config/nds32/nds32.md (abssi2): New pattern.
22420
22421 2018-05-19 Uros Bizjak <ubizjak@gmail.com>
22422
22423 * config/i386/i386.md (rex64namesuffix): New mode attribute.
22424 * config/i386/sse.md (sse_cvtsi2ss<rex64namesuffix><round_name>):
22425 Merge insn pattern from sse_cvtsi2ss<round_name> and
22426 sse_cvtsi2ssq<round_name> using SWI48 mode iterator.
22427 (sse_cvtss2si<rex64namesuffix><round_name>): Merge insn pattern
22428 from sse_cvtss2si<round_name> and sse_cvtss2siq<round_name>
22429 using SWI48 mode iterator.
22430 (sse_cvtss2si<rex64namesuffix>_2): Merge insn pattern from
22431 sse_cvtss2si_2 and sse_cvtss2siq_2 using SWI48 mode iterator.
22432 (sse_cvttss2si<rex64namesuffix><round_saeonly_name>): Merge insn
22433 pattern from sse_cvttss2si<round_saeonly_name>
22434 and sse_cvttss2siq<round_saeonly_name> using SWI48 mode iterator.
22435 (avx512f_vcvtss2usi<rex64namesuffix><round_name>): Merge insn pattern
22436 from avx512f_vcvtss2usi<round_name> and avx512f_vcvtss2usiq<round_name>
22437 using SWI48 mode iterator.
22438 (avx512f_vcvttss2usi<rex64namesuffix><round_saeonly_name>): Merge
22439 insn pattern from avx512f_vcvttss2usi<round_saeonly_name> and
22440 avx512f_vcvttss2usiq<round_saeonly_name> using SWI48 mode iterator.
22441 (avx512f_vcvtsd2usi<rex64namesuffix><round_name>): Merge insn pattern
22442 from avx512f_vcvtsd2usi<round_name> and avx512f_vcvtsd2usiq<round_name>
22443 using SWI48 mode iterator.
22444 (avx512f_vcvttsd2usi<rex64namesuffix><round_saeonly_name>): Merge
22445 insn pattern from avx512f_vcvttsd2usi<round_saeonly_name> and
22446 avx512f_vcvttsd2usiq<round_saeonly_name> using SWI48 mode iterator.
22447 (sse2_cvtsd2si<rex64namesuffix><round_name>): Merge insn pattern from
22448 sse2_cvtsd2si<round_name> and sse2_cvtsd2siq<round_name> using
22449 SWI48 mode iterator.
22450 (sse2_cvtsd2si<rex64namesuffix>_2): Merge insn pattern from
22451 sse2_cvtsd2si_2 and sse2_cvtsd2siq_2 using SWI48 mode iterator.
22452 (sse_cvttsd2si<rex64namesuffix><round_saeonly_name>): Merge insn
22453 pattern from sse_cvttsd2si<round_saeonly_name>
22454 and sse_cvttsd2siq<round_saeonly_name> using SWI48 mode iterator.
22455
22456 2018-05-19 Chung-Ju Wu <jasonwucj@gmail.com>
22457
22458 * config/nds32/nds32-md-auxiliary.c
22459 (nds32_valid_smw_lwm_base_p): Refine.
22460 (nds32_output_smw_single_word): Refine.
22461 (nds32_output_smw_double_word): New.
22462 * config/nds32/nds32-protos.h (nds32_output_smw_double_word): New.
22463
22464 2018-05-19 Chung-Ju Wu <jasonwucj@gmail.com>
22465
22466 * config/nds32/nds32-md-auxiliary.c (nds32_output_stack_push): Refine.
22467 (nds32_output_stack_pop): Refine.
22468 (nds32_expand_unaligned_load): Refine.
22469 (nds32_expand_unaligned_store): Refine.
22470
22471 2018-05-19 Kuan-Lin Chen <kuanlinchentw@gmail.com>
22472 Chung-Ju Wu <jasonwucj@gmail.com>
22473
22474 * config/nds32/constants.md: Add TP_REGNUM constant.
22475 (unspec_element): Add UNSPEC_GOTINIT, UNSPEC_GOT, UNSPEC_GOTOFF,
22476 UNSPEC_PLT, UNSPEC_TLSGD, UNSPEC_TLSLD, UNSPEC_TLSIE, UNSPEC_TLSLE and
22477 UNSPEC_ADD32.
22478 * config/nds32/nds32-doubleword.md: Consider flag_pic.
22479 * config/nds32/nds32-dspext.md (mov<mode>): Expand TLS and PIC cases.
22480 * config/nds32/nds32-predicates.c (nds32_const_unspec_p): New.
22481 * config/nds32/nds32-md-auxiliary.c: Implementation that support TLS
22482 and PIC code generation.
22483 * config/nds32/nds32-protos.h: Declarations that support TLS and PIC
22484 code generation.
22485 * config/nds32/nds32-relax-opt.c: Consider TLS and PIC for relax
22486 optimization.
22487 * config/nds32/nds32.md: Support TLS and PIC.
22488 * config/nds32/nds32.c: Support TLS and PIC.
22489 * config/nds32/nds32.h (nds32_relax_insn_type): New enum type.
22490 * config/nds32/predicates.md (nds32_nonunspec_symbolic_operand): New
22491 predicate.
22492
22493 2018-05-19 Chung-Ju Wu <jasonwucj@gmail.com>
22494
22495 * config/nds32/nds32-predicates.c (const_vector_to_hwint): Use machine
22496 mode with E_ prefix.
22497
22498 2018-05-19 Kuan-Lin Chen <kuanlinchentw@gmail.com>
22499 Chung-Ju Wu <jasonwucj@gmail.com>
22500
22501 * config/nds32/constants.md (unspec_element): Add UNSPEC_ICT.
22502 * config/nds32/nds32-md-auxiliary.c
22503 (symbolic_reference_mentioned_p): New.
22504 (nds32_legitimize_ict_address): New.
22505 (nds32_expand_ict_move): New.
22506 (nds32_indirect_call_referenced_p): New.
22507 (nds32_symbol_binds_local_p): Delete.
22508 (nds32_long_call_p): Modify.
22509 * config/nds32/nds32-opts.h (nds32_ict_model_type): New enum type.
22510 * config/nds32/nds32-protos.h
22511 (symbolic_reference_mentioned_p): Declare.
22512 (nds32_legitimize_ict_address): Declare.
22513 (nds32_expand_ict_move): Declare.
22514 (nds32_indirect_call_referenced_p): Declare.
22515 * config/nds32/nds32-relax-opt.c (nds32_ict_const_p): New.
22516 (nds32_relax_group): Use nds32_ict_const_p as condition.
22517 * config/nds32/nds32.c (nds32_attribute_table): Add "indirect_call".
22518 (nds32_asm_file_start): Output ict_model directive in asm code.
22519 (nds32_legitimate_address_p): Consider indirect call.
22520 (nds32_print_operand): Consider indirect call.
22521 (nds32_print_operand_address): Consider indirect call.
22522 (nds32_insert_attributes): Handle "indirect_call" attribute.
22523 (TARGET_LEGITIMATE_ADDRESS_P): Define.
22524 (TARGET_LEGITIMATE_CONSTANT_P): Define.
22525 (TARGET_CANNOT_FORCE_CONST_MEM): Define.
22526 (TARGET_DELEGITIMIZE_ADDRESS): Define.
22527 (TARGET_ASM_OUTPUT_ADDR_CONST_EXTRA): Define.
22528 * config/nds32/nds32.h (SYMBOLIC_CONST_P): Define.
22529 (TARGET_ICT_MODEL_SMALL): Define.
22530 (TARGET_ICT_MODEL_LARGE): Define.
22531 * config/nds32/nds32.md (movsi): Consider ict model.
22532 (call, call_value): Consider ict model.
22533 (sibcall, sibcall_value): Consider ict model.
22534 * config/nds32/nds32.opt (mict-model): New option.
22535 * config/nds32/predicates.md (nds32_symbolic_operand): Consider ict
22536 model.
22537
22538 2018-05-18 Kito Cheng <kito.cheng@gmail.com>
22539 Monk Chiang <sh.chiang04@gmail.com>
22540 Jim Wilson <jimw@sifive.com>
22541
22542 * common/config/riscv/riscv-common.c (riscv_parse_arch_string):
22543 Add support to parse rv32e*. Clear MASK_RVE for rv32i and rv64i.
22544 * config.gcc (riscv*-*-*): Add support for rv32e* and ilp32e.
22545 * config/riscv/riscv-c.c (riscv_cpu_cpp_builtins): Define
22546 __riscv_32e when TARGET_RVE. Handle ABI_ILP32E as soft-float ABI.
22547 * config/riscv/riscv-opts.h (riscv_abi_type): Add ABI_ILP32E.
22548 * config/riscv/riscv.c (riscv_compute_frame_info): When TARGET_RVE,
22549 compute save_libcall_adjustment properly.
22550 (riscv_option_override): Call error if TARGET_RVE and not ABI_ILP32E.
22551 (riscv_conditional_register_usage): Handle TARGET_RVE and ABI_ILP32E.
22552 * config/riscv/riscv.h (UNITS_PER_FP_ARG): Handle ABI_ILP32E.
22553 (STACK_BOUNDARY, ABI_STACK_BOUNDARY): Handle TARGET_RVE.
22554 (GP_REG_LAST, MAX_ARGS_IN_REGISTERS): Likewise.
22555 (ABI_SPEC): Handle mabi=ilp32e.
22556 * config/riscv/riscv.opt (abi_type): Add ABI_ILP32E.
22557 (RVE): Add RVE mask.
22558 * doc/invoke.texi (RISC-V options) <-mabi>: Add ilp32e info.
22559 <-march>: Add rv32e as an example.
22560
22561 2018-05-18 Marc Glisse <marc.glisse@inria.fr>
22562
22563 PR c++/82899
22564 * tree-ssa-structalias.c (create_variable_info_for_1): Extra argument.
22565 (intra_create_variable_infos): Handle C++ constructors.
22566
22567 2018-05-18 Martin Liska <mliska@suse.cz>
22568
22569 * passes.def: Remove a redundant pass.
22570
22571 2018-05-18 Eric Botcazou <ebotcazou@adacore.com>
22572
22573 PR bootstrap/85838
22574 * config/sparc/sparc.c (sparc_expand_builtin): Always initialize op[0].
22575
22576 2018-05-18 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
22577
22578 * config/arm/arm-cpus.in (armv3m, mode32): Delete features.
22579 (ARMv4): Update.
22580 (ARMv2, ARMv3, ARMv3m): Delete fgroups.
22581 (ARMv6m): Update.
22582 (armv2, armv2a, armv3, armv3m): Delete architectures.
22583 (arm2, arm250, arm3, arm6, arm60, arm600, arm610, arm620,
22584 arm7, arm7d, arm7di, arm70, arm700, arm700i, arm710, arm720,
22585 arm710c, arm7100, arm7500, arm7500fe, arm7m, arm7dm, arm7dmi):
22586 Delete cpus.
22587 * config/arm/arm.md (maddsidi4): Remove check for arm_arch3m.
22588 (*mulsidi3adddi): Likewise.
22589 (mulsidi3): Likewise.
22590 (*mulsidi3_nov6): Likewise.
22591 (umulsidi3): Likewise.
22592 (umulsidi3_nov6): Likewise.
22593 (umaddsidi4): Likewise.
22594 (*umulsidi3adddi): Likewise.
22595 (smulsi3_highpart): Likewise.
22596 (*smulsi3_highpart_nov6): Likewise.
22597 (umulsi3_highpart): Likewise.
22598 (*umulsi3_highpart_nov6): Likewise.
22599 * config/arm/arm.h (arm_arch3m): Delete.
22600 * config/arm/arm.c (arm_arch3m): Delete.
22601 (arm_option_override_internal): Update armv3-related comment.
22602 (arm_configure_build_target): Delete use of isa_bit_mode32.
22603 (arm_option_reconfigure_globals): Delete set of arm_ach3m.
22604 (arm_rtx_costs_internal): Delete check of arm_arch3m.
22605 * config/arm/arm-fixed.md (mulsq3): Delete check for arm_arch3m.
22606 (mulsa3): Likewise.
22607 (mulusa3): Likewise.
22608 * config/arm/arm-protos.h (arm_arch3m): Delete.
22609 * config/arm/arm-tables.opt: Regenerate.
22610 * config/arm/arm-tune.md: Likewise.
22611 * config/arm/t-arm-elf (all_early_nofp): Delete mentions of
22612 deleted architectures.
22613
22614 2018-05-18 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
22615
22616 * config/arm/arm-cpus.in (armv5, armv5e): Delete features.
22617 (armv5t, armv5te): New features.
22618 (ARMv5, ARMv5e): Delete fgroups.
22619 (ARMv5t, ARMv5te): Adjust for above changes.
22620 (ARMv6m): Likewise.
22621 (armv5, armv5e): Delete arches.
22622 * config/arm/arm.md (*call_reg_armv5): Use arm_arch5t instead of
22623 arm_arch5.
22624 (*call_reg_arm): Likewise.
22625 (*call_value_reg_armv5): Likewise.
22626 (*call_value_reg_arm): Likewise.
22627 (*call_symbol): Likewise.
22628 (*call_value_symbol): Likewise.
22629 (*sibcall_insn): Likewise.
22630 (*sibcall_value_insn): Likewise.
22631 (clzsi2): Likewise.
22632 (prefetch): Likewise.
22633 (define_split and define_peephole2 dependent on arm_arch5):
22634 Likewise.
22635 * config/arm/arm.h (TARGET_LDRD): Use arm_arch5te instead of
22636 arm_arch5e.
22637 (TARGET_ARM_QBIT): Likewise.
22638 (TARGET_DSP_MULTIPLY): Likewise.
22639 (enum base_architecture): Delete BASE_ARCH_5, BASE_ARCH_5E.
22640 (arm_arch5, arm_arch5e): Delete.
22641 (arm_arch5t, arm_arch5te): Declare.
22642 * config/arm/arm.c (arm_arch5, arm_arch5e): Delete.
22643 (arm_arch5t): Declare.
22644 (arm_option_reconfigure_globals): Update for the above.
22645 (arm_options_perform_arch_sanity_checks): Update comment, replace
22646 use of arm_arch5 with arm_arch5t.
22647 (use_return_insn): Likewise.
22648 (arm_emit_call_insn): Likewise.
22649 (output_return_instruction): Likewise.
22650 (arm_final_prescan_insn): Likewise.
22651 (arm_coproc_builtin_available): Likewise.
22652 * config/arm/arm-c.c (arm_cpu_builtins): Replace arm_arch5 and
22653 arm_arch5e with arm_arch5t and arm_arch5te.
22654 * config/arm/arm-protos.h (arm_arch5, arm_arch5e): Delete.
22655 (arm_arch5t, arm_arch5te): Declare.
22656 * config/arm/arm-tables.opt: Regenerate.
22657 * config/arm/t-arm-elf: Remove references to armv5, armv5e.
22658 * config/arm/t-multilib: Likewise.
22659 * config/arm/thumb1.md (*call_reg_thumb1_v5): Check arm_arch5t
22660 instead of arm_arch5.
22661 (*call_reg_thumb1): Likewise.
22662 (*call_value_reg_thumb1_v5): Likewise.
22663 (*call_value_reg_thumb1): Likewise.
22664 * config/arm/vxworks.h (TARGET_OS_CPP_BUILTINS): Remove now
22665 unreachable path.
22666 * doc/invoke.texi (ARM Options): Remove references to armv5, armv5e.
22667
22668 2018-05-18 Martin Liska <mliska@suse.cz>
22669
22670 PR gcov-profile/84846
22671 * doc/gcov.texi: Document -t option of gcov tool.
22672
22673 2018-05-18 Martin Liska <mliska@suse.cz>
22674
22675 PR gcov-profile/84846
22676 * gcov.c (print_usage): Add new -t option.
22677 (process_args): Handle the option.
22678 (generate_results): Use stdout as output when requested by
22679 the option.
22680
22681 2018-05-18 Martin Liska <mliska@suse.cz>
22682
22683 PR gcov-profile/84846
22684 * coverage.c (coverage_init): Write PWD to .gcno file.
22685 * doc/gcov.texi: Document how working directory is printed.
22686 * gcov-dump.c (dump_gcov_file): Print PWD.
22687 * gcov.c (output_intermediate_file): Likewise.
22688 (read_graph_file): Read PWD string.
22689 (output_lines): Print PWD.
22690
22691 2018-05-18 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
22692
22693 PR middle-end/85817
22694 * ipa-pure-const.c (malloc_candidate_p): Remove the check integer_zerop
22695 for retval and return false if all args to phi are zero.
22696
22697 2018-05-18 Richard Biener <rguenther@suse.de>
22698
22699 * gimple-ssa-evrp.c (class evrp_folder): Add simplify_stmt_using_ranges
22700 method.
22701 (evrp_dom_walker::before_dom_children): Call it.
22702
22703 2018-05-18 Richard Biener <rguenther@suse.de>
22704
22705 * tree-dfa.c (get_ref_base_and_extent): Use range-info to refine
22706 results when processing array refs with variable index.
22707
22708 2018-05-18 Toon Moene <toon@moene.org>
22709
22710 * doc/invoke.texi: Move -floop-unroll-and-jam documentation
22711 directly after that of -floop-interchange. Indicate that both
22712 options are enabled by default when specifying -O3.
22713
22714 2018-05-18 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
22715
22716 * config/aarch64/aarch64-simd.md (vec_set<mode>): Use VALL_F16 mode
22717 iterator. Delete separate integer-mode vec_set<mode> expander.
22718 (aarch64_simd_vec_setv2di): Delete.
22719 (vec_setv2di): Delete.
22720 (aarch64_simd_vec_set<mode>): Delete all other patterns with that name.
22721 Use VALL_F16 mode iterator. Add LD1 alternative and use vwcore for
22722 the "w, r" alternative.
22723
22724 2018-05-18 Martin Liska <mliska@suse.cz>
22725
22726 * passes.def: Add pass_lower_switch and pass_lower_switch_O0.
22727 * tree-pass.h (make_pass_lower_switch_O0): New function.
22728 * tree-switch-conversion.c (node_has_low_bound): Remove.
22729 (node_has_high_bound): Likewise.
22730 (node_is_bounded): Likewise.
22731 (class pass_lower_switch): Make it a template type and create
22732 two instances.
22733 (pass_lower_switch::execute): Add template argument.
22734 (make_pass_lower_switch): New function.
22735 (make_pass_lower_switch_O0): New function.
22736 (do_jump_if_equal): Remove.
22737 (emit_case_nodes): Simplify to just handle all 3 cases and leave
22738 all the hard work to tree optimization passes.
22739
22740 2018-05-18 Martin Liska <mliska@suse.cz>
22741
22742 * dbgcnt.c (limit_low): Renamed from limit.
22743 (limit_high): New variable.
22744 (dbg_cnt_is_enabled): Check for upper limit.
22745 (dbg_cnt): Adjust dumping.
22746 (dbg_cnt_set_limit_by_index): Add new argument for high
22747 value.
22748 (dbg_cnt_set_limit_by_name): Likewise.
22749 (dbg_cnt_process_single_pair): Parse new format.
22750 (dbg_cnt_process_opt): Use strtok.
22751 (dbg_cnt_list_all_counters): Remove 'value' and add
22752 'limit_high'.
22753 * doc/invoke.texi: Document changes.
22754
22755 2018-05-18 Richard Sandiford <richard.sandiford@linaro.org>
22756
22757 * doc/sourcebuild.texi (scalar_all_fma): Document.
22758 * tree.def (FMA_EXPR): Delete.
22759 * internal-fn.def (FMA, FMS, FNMA, FNMS): New internal functions.
22760 * internal-fn.c (ternary_direct): New macro.
22761 (expand_ternary_optab_fn): Likewise.
22762 (direct_ternary_optab_supported_p): Likewise.
22763 * Makefile.in (build/genmatch.o): Depend on case-fn-macros.h.
22764 * builtins.c (fold_builtin_fma): Delete.
22765 (fold_builtin_3): Don't call it.
22766 * cfgexpand.c (expand_debug_expr): Remove FMA_EXPR handling.
22767 * expr.c (expand_expr_real_2): Likewise.
22768 * fold-const.c (operand_equal_p): Likewise.
22769 (fold_ternary_loc): Likewise.
22770 * gimple-pretty-print.c (dump_ternary_rhs): Likewise.
22771 * gimple.c (DEFTREECODE): Likewise.
22772 * gimplify.c (gimplify_expr): Likewise.
22773 * optabs-tree.c (optab_for_tree_code): Likewise.
22774 * tree-cfg.c (verify_gimple_assign_ternary): Likewise.
22775 * tree-eh.c (operation_could_trap_p): Likewise.
22776 (stmt_could_throw_1_p): Likewise.
22777 * tree-inline.c (estimate_operator_cost): Likewise.
22778 * tree-pretty-print.c (dump_generic_node): Likewise.
22779 (op_code_prio): Likewise.
22780 * tree-ssa-loop-im.c (stmt_cost): Likewise.
22781 * tree-ssa-operands.c (get_expr_operands): Likewise.
22782 * tree.c (commutative_ternary_tree_code, add_expr): Likewise.
22783 * fold-const-call.h (fold_fma): Delete.
22784 * fold-const-call.c (fold_const_call_ssss): Handle CFN_FMS,
22785 CFN_FNMA and CFN_FNMS.
22786 (fold_fma): Delete.
22787 * genmatch.c (combined_fn): New enum.
22788 (commutative_ternary_tree_code): Remove FMA_EXPR handling.
22789 (commutative_op): New function.
22790 (commutate): Use it. Handle more than 2 operands.
22791 (dt_operand::gen_gimple_expr): Use commutative_op.
22792 (parser::parse_expr): Allow :c to be used with non-binary
22793 operators if the commutative operand is known.
22794 * gimple-ssa-backprop.c (backprop::process_builtin_call_use): Handle
22795 CFN_FMS, CFN_FNMA and CFN_FNMS.
22796 (backprop::process_assign_use): Remove FMA_EXPR handling.
22797 * hsa-gen.c (gen_hsa_insns_for_operation_assignment): Likewise.
22798 (gen_hsa_fma): New function.
22799 (gen_hsa_insn_for_internal_fn_call): Use it for IFN_FMA, IFN_FMS,
22800 IFN_FNMA and IFN_FNMS.
22801 * match.pd: Add folds for IFN_FMS, IFN_FNMA and IFN_FNMS.
22802 * gimple-fold.h (follow_all_ssa_edges): Declare.
22803 * gimple-fold.c (follow_all_ssa_edges): New function.
22804 * tree-ssa-math-opts.c (convert_mult_to_fma_1): Use the
22805 gimple_build interface and use follow_all_ssa_edges to fold the result.
22806 (convert_mult_to_fma): Use direct_internal_fn_suppoerted_p
22807 instead of checking for optabs directly.
22808 * config/i386/i386.c (ix86_add_stmt_cost): Recognize FMAs as calls
22809 rather than FMA_EXPRs.
22810 * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Create a
22811 call to IFN_FMA instead of an FMA_EXPR.
22812
22813 2018-05-17 Jim Wilson <jimw@sifive.com>
22814
22815 * expr.c (do_tablejump): When converting index to Pmode, if we have a
22816 sign extended promoted subreg, and the range does not have the sign bit
22817 set, then do a sign extend.
22818
22819 * config/riscv/riscv.c (riscv_extend_comparands): In unsigned QImode
22820 test, check for sign extended subreg and/or constant operands, and
22821 do a sign extend in that case.
22822
22823 2018-05-17 Steve Ellcey <sellcey@cavium.com>
22824
22825 * config/aarch64/thunderx2t99.md (thunderx2t99_ls_both): Delete.
22826 (thunderx2t99_multiple): Delete psuedo-units from used cpus.
22827 Add untyped.
22828 (thunderx2t99_alu_shift): Remove alu_shift_reg, alus_shift_reg.
22829 Change logics_shift_reg to logics_shift_imm.
22830 (thunderx2t99_fp_loadpair_basic): Delete.
22831 (thunderx2t99_fp_storepair_basic): Delete.
22832 (thunderx2t99_asimd_int): Add neon_sub and neon_sub_q types.
22833 (thunderx2t99_asimd_polynomial): Delete.
22834 (thunderx2t99_asimd_fp_simple): Add neon_fp_mul_s_scalar_q
22835 and neon_fp_mul_d_scalar_q.
22836 (thunderx2t99_asimd_fp_conv): Add *int_to_fp* types.
22837 (thunderx2t99_asimd_misc): Delete neon_dup and neon_dup_q.
22838 (thunderx2t99_asimd_recip_step): Add missing *sqrt* types.
22839 (thunderx2t99_asimd_lut): Add missing tbl types.
22840 (thunderx2t99_asimd_ext): Delete.
22841 (thunderx2t99_asimd_load1_1_mult): Delete.
22842 (thunderx2t99_asimd_load1_2_mult): Delete.
22843 (thunderx2t99_asimd_load1_ldp): New.
22844 (thunderx2t99_asimd_load1): New.
22845 (thunderx2t99_asimd_load2): Add missing *load2* types.
22846 (thunderx2t99_asimd_load3): New.
22847 (thunderx2t99_asimd_load4): New.
22848 (thunderx2t99_asimd_store1_1_mult): Delete.
22849 (thunderx2t99_asimd_store1_2_mult): Delete.
22850 (thunderx2t99_asimd_store2_mult): Delete.
22851 (thunderx2t99_asimd_store2_onelane): Delete.
22852 (thunderx2t99_asimd_store_stp): New.
22853 (thunderx2t99_asimd_store1): New.
22854 (thunderx2t99_asimd_store2): New.
22855 (thunderx2t99_asimd_store3): New.
22856 (thunderx2t99_asimd_store4): New.
22857
22858 2018-05-17 Jerome Lambourg <lambourg@adacore.com>
22859
22860 * config/arm/arm_cmse.h (cmse_nsfptr_create, cmse_is_nsfptr): Remove
22861 #include <stdint.h>. Replace intptr_t with __INTPTR_TYPE__.
22862
22863 2018-05-17 Pat Haugen <pthaugen@us.ibm.com>
22864 Segher Boessenkool <segher@kernel.crashing.org>
22865
22866 PR target/85698
22867 * config/rs6000/rs6000.c (rs6000_output_move_128bit): Check dest
22868 operand.
22869
22870 2018-05-17 Richard Biener <rguenther@suse.de>
22871
22872 * tree-ssa-dse.c (dse_classify_store): Fix iterator increment
22873 for pruning loop and prune defs feeding only already visited PHIs.
22874
22875 2018-05-17 Richard Biener <rguenther@suse.de>
22876
22877 * tree-ssa-sccvn.c (vn_reference_lookup_3): Improve memset handling.
22878
22879 2018-05-17 Bin Cheng <bin.cheng@arm.com>
22880 Richard Biener <rguenther@suse.de>
22881
22882 PR tree-optimization/85793
22883 * tree-vect-stmts.c (vectorizable_load): Handle 1 element-wise load
22884 for VMAT_ELEMENTWISE.
22885
22886 2018-05-17 Richard Sandiford <richard.sandiford@linaro.org>
22887
22888 * internal-fn.h (lookup_internal_fn): Declare
22889 * internal-fn.c (lookup_internal_fn): New function.
22890 * gimple.c (gimple_build_call_from_tree): Handle calls to
22891 internal functions.
22892 * gimple-pretty-print.c (dump_gimple_call): Print "." before
22893 internal function names.
22894 * tree-pretty-print.c (dump_generic_node): Likewise.
22895 * tree-ssa-scopedtables.c (expr_hash_elt::print): Likewise.
22896
22897 2018-05-17 Richard Sandiford <richard.sandiford@linaro.org>
22898
22899 * gimple-fold.h (gimple_build): Make the function forms take
22900 combined_fn rather than built_in_function.
22901 (gimple_simplify): Likewise.
22902 * gimple-match-head.c (gimple_simplify): Likewise.
22903 * gimple-fold.c (gimple_build): Likewise.
22904 * tree-vect-loop.c (get_initial_def_for_reduction): Use gimple_build
22905 rather than gimple_build_call_internal.
22906 (get_initial_defs_for_reduction): Likewise.
22907 (vect_create_epilog_for_reduction): Likewise.
22908 (vectorizable_live_operation): Likewise.
22909
22910 2018-05-17 Martin Liska <mliska@suse.cz>
22911
22912 * gimple-ssa-sprintf.c (format_directive): Do not use
22913 space in between 'G_' and '('.
22914
22915 2018-05-17 Jakub Jelinek <jakub@redhat.com>
22916
22917 PR target/85323
22918 * config/i386/i386.c (ix86_fold_builtin): Handle masked shifts
22919 even if the mask is not all ones.
22920
22921 PR target/85323
22922 * config/i386/i386.c (ix86_fold_builtin): Fold shift builtins by
22923 vector.
22924 (ix86_gimple_fold_builtin): Likewise.
22925
22926 PR target/85323
22927 * config/i386/i386.c: Include tree-vector-builder.h.
22928 (ix86_vector_shift_count): New function.
22929 (ix86_fold_builtin): Fold shift builtins by scalar count.
22930 (ix86_gimple_fold_builtin): Likewise.
22931
22932 * config/i386/avx512fintrin.h (_mm512_set_epi16, _mm512_set_epi8,
22933 _mm512_setzero): New intrinsics.
22934
22935 2018-05-17 James Greenhalgh <james.greenhalgh@arm.com>
22936 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
22937
22938 * config/aarch64/aarch64.c (aarch64_expand_vector_init): Modify
22939 code generation for cases where splatting a value is not useful.
22940 * simplify-rtx.c (simplify_ternary_operation): Simplify
22941 vec_merge across a vec_duplicate and a paradoxical subreg forming
22942 a vector mode to a vec_concat.
22943
22944 2018-05-17 Olga Makhotina <olga.makhotina@intel.com>
22945
22946 * config.gcc: Support "goldmont-plus".
22947 * config/i386/driver-i386.c (host_detect_local_cpu): Detect
22948 "goldmont-plus".
22949 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
22950 PROCESSOR_GOLDMONT_PLUS.
22951 * config/i386/i386.c (m_GOLDMONT_PLUS): Define.
22952 (processor_target_table): Add "goldmont-plus".
22953 (PTA_GOLDMONT_PLUS): Define.
22954 (ix86_lea_outperforms): Add TARGET_GOLDMONT_PLUS.
22955 (get_builtin_code_for_version): Handle PROCESSOR_GOLDMONT_PLUS.
22956 (fold_builtin_cpu): Add M_INTEL_GOLDMONT_PLUS.
22957 (fold_builtin_cpu): Add "goldmont-plus".
22958 (ix86_add_stmt_cost): Add TARGET_GOLDMONT_PLUS.
22959 (ix86_option_override_internal): Add "goldmont-plus".
22960 * config/i386/i386.h (processor_costs): Define TARGET_GOLDMONT_PLUS.
22961 (processor_type): Add PROCESSOR_GOLDMONT_PLUS.
22962 * config/i386/x86-tune.def: Add m_GOLDMONT_PLUS.
22963 * doc/invoke.texi: Add goldmont-plus as x86 -march=/-mtune= CPU type.
22964
22965 2018-05-17 Richard Biener <rguenther@suse.de>
22966
22967 PR tree-optimization/85757
22968 * tree-ssa-dse.c (dse_classify_store): Record a PHI def and
22969 remove defs that only feed that PHI from further processing.
22970
22971 2018-05-16 Jim Wilson <jimw@sifive.com>
22972
22973 * config/riscv/riscv.md (<optab>si3_mask, <optab>si3_mask_1): Prepend
22974 asterisk to name.
22975 (<optab>di3_mask, <optab>di3_mask_1): Likewise.
22976
22977 2018-05-16 Mark Wielaard <mark@klomp.org>
22978
22979 * dwarf2out.c (count_index_strings): New function.
22980 (output_indirect_strings): Call count_index_strings and generate
22981 header for dwarf_version >= 5.
22982
22983 2018-05-16 Mark Wielaard <mark@klomp.org>
22984
22985 * dwarf2out.c (dwarf_FORM): New function.
22986 (set_indirect_string): Use dwarf_FORM.
22987 (reset_indirect_string): Likewise.
22988 (size_of_die): Likewise.
22989 (value_format): Likewise.
22990 (output_die): Likewise.
22991 (add_skeleton_AT_string): Likewise.
22992 (output_macinfo_op): Likewise.
22993 (index_string): Likewise.
22994 (output_index_string_offset): Likewise.
22995 (output_index_string): Likewise.
22996 (count_index_strings): Likewise.
22997
22998 2018-05-16 Carl Love <cel@us.ibm.com>
22999
23000 * config/rs6000/rs6000.md (prefetch): Generate ISA 2.06 instructions
23001 dcbt and dcbtstt with TH=16 if operands[2] is 0 and Power 8 or newer.
23002
23003 2018-05-16 Martin Jambor <mjambor@suse.cz>
23004
23005 * ipa-prop.c (ipa_free_all_edge_args): Remove.
23006 * ipa-prop.h (ipa_free_all_edge_args): Likewise.
23007
23008 2018-05-16 Wilco Dijkstra <wdijkstr@arm.com>
23009
23010 * config/aarch64/aarch64.md (fma<mode>4): Change into expand pattern.
23011 (fnma<mode>4): Likewise.
23012 (fms<mode>4): Likewise.
23013 (fnms<mode>4): Likewise.
23014 (aarch64_fma<mode>4): Rename insn, reorder accumulator operand.
23015 (aarch64_fnma<mode>4): Likewise.
23016 (aarch64_fms<mode>4): Likewise.
23017 (aarch64_fnms<mode>4): Likewise.
23018 (aarch64_fnmadd<mode>4): Likewise.
23019
23020 2018-05-16 Jason Merrill <jason@redhat.com>
23021
23022 * tree.c (warn_deprecated_use): Return bool. Simplify logic.
23023
23024 2018-05-16 Richard Biener <rguenther@suse.de>
23025
23026 * tree-vectorizer.h (struct stmt_info_for_cost): Add where member.
23027 (dump_stmt_cost): Declare.
23028 (add_stmt_cost): Dump cost we add.
23029 (add_stmt_costs): New function.
23030 (vect_model_simple_cost, vect_model_store_cost, vect_model_load_cost):
23031 No longer exported.
23032 (vect_analyze_stmt): Adjust prototype.
23033 (vectorizable_condition): Likewise.
23034 (vectorizable_live_operation): Likewise.
23035 (vectorizable_reduction): Likewise.
23036 (vectorizable_induction): Likewise.
23037 * tree-vect-loop.c (vect_analyze_loop_operations): Create local
23038 cost vector to pass to vectorizable_ and record afterwards.
23039 (vect_model_reduction_cost): Take cost vector argument and adjust.
23040 (vect_model_induction_cost): Likewise.
23041 (vectorizable_reduction): Likewise.
23042 (vectorizable_induction): Likewise.
23043 (vectorizable_live_operation): Likewise.
23044 * tree-vect-slp.c (vect_create_new_slp_node): Initialize
23045 SLP_TREE_NUMBER_OF_VEC_STMTS.
23046 (vect_analyze_slp_cost_1): Remove.
23047 (vect_analyze_slp_cost): Likewise.
23048 (vect_slp_analyze_node_operations): Take visited args and
23049 a target cost vector. Avoid processing already visited stmt sets.
23050 (vect_slp_analyze_operations): Use a local cost vector to gather
23051 costs and register those of non-discarded instances.
23052 (vect_bb_vectorization_profitable_p): Use add_stmt_costs.
23053 (vect_schedule_slp_instance): Remove copying of
23054 SLP_TREE_NUMBER_OF_VEC_STMTS. Instead assert that it is not
23055 zero.
23056 * tree-vect-stmts.c (record_stmt_cost): Remove path directly
23057 adding cost. Record cost entry location.
23058 (vect_prologue_cost_for_slp_op): Function to compute cost of
23059 a constant or invariant generated for SLP vect in the prologue,
23060 split out from vect_analyze_slp_cost_1.
23061 (vect_model_simple_cost): Make static. Adjust for SLP costing.
23062 (vect_model_promotion_demotion_cost): Likewise.
23063 (vect_model_store_cost): Likewise, make static.
23064 (vect_model_load_cost): Likewise.
23065 (vectorizable_bswap): Add cost vector arg and adjust.
23066 (vectorizable_call): Likewise.
23067 (vectorizable_simd_clone_call): Likewise.
23068 (vectorizable_conversion): Likewise.
23069 (vectorizable_assignment): Likewise.
23070 (vectorizable_shift): Likewise.
23071 (vectorizable_operation): Likewise.
23072 (vectorizable_store): Likewise.
23073 (vectorizable_load): Likewise.
23074 (vectorizable_condition): Likewise.
23075 (vectorizable_comparison): Likewise.
23076 (can_vectorize_live_stmts): Likewise.
23077 (vect_analyze_stmt): Likewise.
23078 (vect_transform_stmt): Adjust calls to vectorizable_*.
23079 * tree-vectorizer.c: Include gimple-pretty-print.h.
23080 (dump_stmt_cost): New function.
23081
23082 2018-05-16 Richard Biener <rguenther@suse.de>
23083
23084 * params.def (PARAM_DSE_MAX_ALIAS_QUERIES_PER_STORE): New param.
23085 * doc/invoke.texi (dse-max-alias-queries-per-store): Document.
23086 * tree-ssa-dse.c: Include tree-ssa-loop.h.
23087 (check_name): New callback.
23088 (dse_classify_store): Track cycles via a visited bitmap of PHI
23089 defs and simplify handling of in-loop and across loop dead stores
23090 and properly fail for loop-variant refs. Handle byte-tracking with
23091 multiple defs. Use PARAM_DSE_MAX_ALIAS_QUERIES_PER_STORE for
23092 limiting the walk.
23093
23094 2018-05-16 Richard Sandiford <richard.sandiford@linaro.org>
23095
23096 * tree-vectorizer.h (vect_get_vector_types_for_stmt): Declare.
23097 (vect_get_mask_type_for_stmt): Likewise.
23098 * tree-vect-slp.c (vect_two_operations_perm_ok_p): New function,
23099 split out from...
23100 (vect_build_slp_tree_1): ...here. Use vect_get_vector_types_for_stmt
23101 to determine the statement's vector type and the vector type that
23102 should be used for calculating nunits. Deal with cases in which
23103 the type has to be deferred.
23104 (vect_slp_analyze_node_operations): Use vect_get_vector_types_for_stmt
23105 and vect_get_mask_type_for_stmt to calculate STMT_VINFO_VECTYPE.
23106 * tree-vect-loop.c (vect_determine_vf_for_stmt_1)
23107 (vect_determine_vf_for_stmt): New functions, split out from...
23108 (vect_determine_vectorization_factor): ...here.
23109 * tree-vect-stmts.c (vect_get_vector_types_for_stmt)
23110 (vect_get_mask_type_for_stmt): New functions, split out from
23111 vect_determine_vectorization_factor.
23112
23113 2018-05-16 Richard Biener <rguenther@suse.de>
23114
23115 * tree-cfg.c (verify_gimple_assign_ternary): Properly
23116 verify the [VEC_]COND_EXPR embedded comparison.
23117
23118 2018-05-15 Martin Sebor <msebor@redhat.com>
23119
23120 PR tree-optimization/85753
23121 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): Handle
23122 RECORD_TYPE in addition to ARRAY_TYPE.
23123
23124 2018-05-15 Martin Sebor <msebor@redhat.com>
23125
23126 PR middle-end/85643
23127 * calls.c (get_attr_nonstring_decl): Handle MEM_REF.
23128
23129 2018-05-15 Richard Biener <rguenther@suse.de>
23130
23131 * tree-ssa-dse.c (dse_classify_store): Remove use_stmt parameter,
23132 add by_clobber_p one. Change algorithm to collect all defs
23133 representing uses we need to walk and try reducing them to
23134 a single one before failing.
23135 (dse_dom_walker::dse_optimize_stmt): Adjust.
23136
23137 2018-05-13 Mark Wielaard <mark@klomp.org>
23138
23139 * dwarf2out.c (dwarf_OP): Handle DW_OP_addrx and DW_OP_constx.
23140 (size_of_loc_descr): Likewise.
23141 (output_loc_operands): Likewise.
23142 (output_loc_operands_raw): Likewise.
23143 (dw_addr_op): Use dwarf_OP () for DW_OP_constx and DW_OP_addrx.
23144 (resolve_addr_in_expr): Handle DW_OP_addrx and DW_OP_constx.
23145 (hash_loc_operands): Likewise.
23146 (compare_loc_operands): Likewise.
23147
23148 2018-05-14 Mark Wielaard <mark@klomp.org>
23149
23150 * dwarf2out.c (count_index_addrs): New function.
23151 (dwarf2out_finish): Use count_index_addrs to calculate addrs_length.
23152
23153 2018-05-15 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
23154
23155 PR tree-optimization/83648
23156 * ipa-pure-const.c (malloc_candidate_p): Allow function with NULL
23157 return value as malloc candidate.
23158
23159 2018-05-15 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
23160
23161 PR ipa/85734
23162 * ipa-pure-const.c (warn_function_malloc): Pass value of known_finite
23163 param as true in call to suggest_attribute.
23164
23165 2018-05-14 Segher Boessenkool <segher@kernel.crashing.org>
23166
23167 * doc/invoke.texi (RS/6000 and PowerPC Options): Delete @itemx for
23168 -mreadonly-in-sdata.
23169
23170 2018-05-14 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
23171
23172 * config/aarch64/aarch64-simd.md (*aarch64_crypto_aese_fused):
23173 New pattern.
23174 (aarch64_crypto_aesd_fused): Likewise.
23175
23176 2018-05-14 Wilco Dijkstra <wdijkstr@arm.com>
23177
23178 * config/aarch64/aarch64.md (mov<mode>): Remove '*' in alternatives.
23179 (movsi_aarch64): Likewise.
23180 (load_pairsi): Likewise.
23181 (load_pairdi): Likewise.
23182 (store_pairsi): Likewise.
23183 (store_pairdi): Likewise.
23184 (load_pairsf): Likewise.
23185 (load_pairdf): Likewise.
23186 (store_pairsf): Likewise.
23187 (store_pairdf): Likewise.
23188 (zero_extend): Likewise.
23189 (trunc): Swap alternatives.
23190 (fcvt_target): Add '?' to prefer w over r.
23191
23192 2018-05-14 Jakub Jelinek <jakub@redhat.com>
23193
23194 PR target/85756
23195 * config/i386/i386.md: Disallow non-commutative arithmetics in
23196 last twpeephole for mem {+,-,&,|,^}= x; mem != 0 after cmpelim
23197 optimization. Use COMMUTATIVE_ARITH_P test rather than != MINUS
23198 in the peephole2 before it.
23199
23200 2018-05-14 Sebastian Peryt <sebastian.peryt@intel.com>
23201
23202 * common/config/i386/i386-common.c (OPTION_MASK_ISA_CLDEMOTE_SET,
23203 OPTION_MASK_ISA_CLDEMOTE_UNSET): New defines.
23204 (ix86_handle_option): Handle -mcldemote.
23205 * config.gcc: New header.
23206 * config/i386/cldemoteintrin.h: New file.
23207 * config/i386/cpuid.h (bit_CLDEMOTE): New bit.
23208 * config/i386/driver-i386.c (host_detect_local_cpu): Detect
23209 -mcldemote.
23210 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
23211 OPTION_MASK_ISA_CLDEMOTE.
23212 * config/i386/i386.c (ix86_target_string): Add -mcldemote.
23213 (ix86_valid_target_attribute_inner_p): Ditto.
23214 (enum ix86_builtins): Add IX86_BUILTIN_CLDEMOTE.
23215 (ix86_init_mmx_sse_builtins): Define __builtin_ia32_cldemote.
23216 (ix86_expand_builtin): Expand IX86_BUILTIN_CLDEMOTE.
23217 * config/i386/i386.h (TARGET_CLDEMOTE, TARGET_CLDEMOTE_P): New.
23218 * config/i386/i386.md (UNSPECV_CLDEMOTE): New.
23219 (cldemote): New.
23220 * config/i386/i386.opt: Add -mcldemote.
23221 * config/i386/x86intrin.h: New header.
23222 * doc/invoke.texi: Add -mcldemote.
23223
23224 2018-05-14 Richard Biener <rguenther@suse.de>
23225
23226 * doc/match-and-simplify.texi: Adjust :s documentation.
23227
23228 2018-05-14 Alexander Monakov <amonakov@ispras.ru>
23229
23230 * sort.cc (REORDER_23): Pass the type for the temporaries instead of
23231 intended memcpy size.
23232 (REORDER_45): Likewise.
23233
23234 2018-05-13 Alexander Monakov <amonakov@ispras.ru>
23235
23236 * sort.cc: New file.
23237 * system.h [!CHECKING_P] (qsort): Redirect to gcc_qsort.
23238 * vec.c (qsort_chk): Use gcc_qsort.
23239 * Makefile.in (OBJS-libcommon): Add sort.o.
23240 (build/sort.o): New target. Use it...
23241 (BUILD_RTL): ... here, and...
23242 (build/gencfn-macros): ... here, and...
23243 (build/genmatch): ... here.
23244
23245 2018-05-13 Kito Cheng <kito.cheng@gmail.com>
23246 Chung-Ju Wu <jasonwucj@gmail.com>
23247
23248 * config.gcc (nds32*-*-*): Check that n15 is valid to --with-cpu.
23249 * config/nds32/nds32-graywolf.md: New file.
23250 * config/nds32/nds32-opts.h (nds32_cpu_type): Add CPU_GRAYWOLF.
23251 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n15
23252 pipeline.
23253 * config/nds32/nds32-protos.h: More declarations for n15 pipeline.
23254 * config/nds32/nds32-utils.c: More implementations for n15 pipeline.
23255 * config/nds32/nds32.md (pipeline_model): Add graywolf.
23256 * config/nds32/nds32.opt (mcpu): Support n15 pipeline cpus.
23257 * config/nds32/pipelines.md: Include n15 settings.
23258
23259 2018-05-13 Kito Cheng <kito.cheng@gmail.com>
23260 Chung-Ju Wu <jasonwucj@gmail.com>
23261
23262 * config.gcc (nds32*-*-*): Check that n12/n13 are valid to --with-cpu.
23263 * config/nds32/nds32-n13.md: New file.
23264 * config/nds32/nds32-opts.h (nds32_cpu_type): Add CPU_N12 and CPU_N13.
23265 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n12/n13
23266 pipeline.
23267 * config/nds32/nds32-protos.h: More declarations for n12/n13 pipeline.
23268 * config/nds32/nds32.md (pipeline_model): Add n13.
23269 * config/nds32/nds32.opt (mcpu): Support n12/n13 pipeline cpus.
23270 * config/nds32/pipelines.md: Include n13 settings.
23271
23272 2018-05-13 Kito Cheng <kito.cheng@gmail.com>
23273 Chung-Ju Wu <jasonwucj@gmail.com>
23274
23275 * config.gcc (nds32*-*-*): Check that n10/d10 are valid to --with-cpu.
23276 * config/nds32/nds32-n10.md: New file.
23277 * config/nds32/nds32-opts.h (nds32_cpu_type): Add CPU_N10.
23278 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n10
23279 pipeline.
23280 * config/nds32/nds32-protos.h: More declarations for n10 pipeline.
23281 * config/nds32/nds32-utils.c: More implementations for n10 pipeline.
23282 * config/nds32/nds32.md (pipeline_model): Add n10.
23283 * config/nds32/nds32.opt (mcpu): Support n10 pipeline cpus.
23284 * config/nds32/pipelines.md: Include n10 settings.
23285
23286 2018-05-13 Monk Chiang <sh.chiang04@gmail.com>
23287 Kito Cheng <kito.cheng@gmail.com>
23288 Chung-Ju Wu <jasonwucj@gmail.com>
23289
23290 * config.gcc (nds32be-*-*): Handle --with-ext-dsp.
23291 * config/nds32/constants.md (unspec_element, unspec_volatile_element):
23292 Add enum values for DSP extension instructions.
23293 * config/nds32/constraints.md (Iu06, IU06, CVp5, CVs5, CVs2, CVhi):
23294 New constraints.
23295 * config/nds32/iterators.md (shifts, shiftrt, sat_plus, all_plus,
23296 sat_minus, all_minus, plus_minus, extend, sumax, sumin, sumin_max):
23297 New code iterators.
23298 (su, zs, uk, opcode, add_rsub, add_sub): New code attributes.
23299 * config/nds32/nds32-dspext.md: New file for DSP implementation.
23300 * config/nds32/nds32-intrinsic.c: Implementation of DSP extension.
23301 * config/nds32/nds32-intrinsic.md: Likewise.
23302 * config/nds32/nds32_intrinsic.h: Likewise.
23303 * config/nds32/nds32-md-auxiliary.c: Likewise.
23304 * config/nds32/nds32-memory-manipulation.c: Consider DSP extension.
23305 * config/nds32/nds32-predicates.c (const_vector_to_hwint): New.
23306 (nds32_valid_CVp5_p, nds32_valid_CVs5_p): New.
23307 (nds32_valid_CVs2_p, nds32_valid_CVhi_p): New.
23308 * config/nds32/nds32-protos.h: New declarations for DSP extension.
23309 * config/nds32/nds32-utils.c (extract_mac_non_acc_rtx): New case
23310 TYPE_DMAC in switch statement.
23311 * config/nds32/nds32.c: New checking and implementation for DSP
23312 extension instructions.
23313 * config/nds32/nds32.h: Likewise.
23314 * config/nds32/nds32.md: Likewise.
23315 * config/nds32/nds32.opt (mhw-abs, mext-dsp): New options.
23316 * config/nds32/predicates.md: Implement new predicates for DSP
23317 extension.
23318
23319 2018-05-11 Michael Meissner <meissner@linux.vnet.ibm.com>
23320
23321 * config/rs6000/rs6000.md (mov<mode>_softfloat, FMOVE32):
23322 Reformat alternatives and attributes so it is easier to identify
23323 which constraints/attributes go with which instruction.
23324 (mov<mode>_hardfloat32, FMOVE64): Likewise.
23325 (mov<mode>_softfloat32, FMOVE64): Likewise.
23326 (mov<mode>_hardfloat64, FMOVE64): Likewise.
23327 (mov<mode>_softfloat64, FMOVE64): Likewise.
23328
23329 2018-05-11 Kelvin Nilsen <kelvin@gcc.gnu.org>
23330
23331 * doc/extend.texi (PowerPC Built-in Functions): Rename this
23332 subsection.
23333 (Basic PowerPC Built-in Functions): The new name of the
23334 subsection previously known as "PowerPC Built-in Functions".
23335 (Basic PowerPC Built-in Functions Available on all Configurations):
23336 New subsubsection.
23337 (Basic PowerPC Built-in Functions Available on ISA 2.05): Likewise.
23338 (Basic PowerPC Built-in Functions Available on ISA 2.06): Likewise.
23339 (Basic PowerPC Built-in Functions Available on ISA 2.07): Likewise.
23340 (Basic PowerPC Built-in Functions Available on ISA 3.0): Likewise.
23341
23342 2018-05-11 Martin Jambor <mjambor@suse.cz>
23343
23344 PR ipa/85655
23345 * ipa-cp.c (intersect_with_plats): Check that the lattice contains
23346 single const.
23347
23348 2018-05-11 Richard Earnshaw <rearnsha@arm.com>
23349
23350 PR target/85733
23351 * config/arm/arm-cpus.in (fgroup ARMv6m): Add be8 feature.
23352
23353 2018-05-11 Sebastian Peryt <sebastian.peryt@intel.com>
23354
23355 * common/config/i386/i386-common.c (OPTION_MASK_ISA_WAITPKG_SET,
23356 OPTION_MASK_ISA_WAITPKG_UNSET): New defines.
23357 (ix86_handle_option): Handle -mwaitpkg.
23358 * config.gcc: New header.
23359 * config/i386/cpuid.h (bit_WAITPKG): New bit.
23360 * config/i386/driver-i386.c (host_detect_local_cpu): Detect -mwaitpkg.
23361 * config/i386/i386-builtin-types.def ((UINT8, UNSIGNED, UINT64)): New
23362 function type.
23363 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
23364 OPTION_MASK_ISA_WAITPKG.
23365 * config/i386/i386.c (ix86_target_string): Add -mwaitpkg.
23366 (ix86_option_override_internal): Add PTA_WAITPKG.
23367 (ix86_valid_target_attribute_inner_p): Add -mwaitpkg.
23368 (enum ix86_builtins): Add IX86_BUILTIN_UMONITOR, IX86_BUILTIN_UMWAIT,
23369 IX86_BUILTIN_TPAUSE.
23370 (ix86_init_mmx_sse_builtins): Define __builtin_ia32_umonitor,
23371 __builtin_ia32_umwait and __builtin_ia32_tpause.
23372 (ix86_expand_builtin): Expand IX86_BUILTIN_UMONITOR,
23373 IX86_BUILTIN_UMWAIT, IX86_BUILTIN_TPAUSE.
23374 * config/i386/i386.h (TARGET_WAITPKG, TARGET_WAITPKG_P): New.
23375 * config/i386/i386.md (UNSPECV_UMWAIT, UNSPECV_UMONITOR,
23376 UNSPECV_TPAUSE): New.
23377 (umwait, umwait_rex64, umonitor_<mode>, tpause, tpause_rex64): New.
23378 * config/i386/i386.opt: Add -mwaitpkg.
23379 * config/i386/waitpkgintrin.h: New file.
23380 * config/i386/x86intrin.h: New header.
23381 * doc/invoke.texi: Add -mwaitpkg.
23382
23383 2018-05-11 Richard Earnshaw <rearnsha@arm.com>
23384
23385 PR target/85606
23386 * config/arm/arm-cpus.in: Add comment that ARMv6-m and ARMv6S-m are now
23387 equivalent.
23388 (cortex-m0): Use armv6s-m isa.
23389 (cortex-m0plus): Likewise.
23390 (cortex-m1): Likewise.
23391 (cortex-m0.small-multiply): Likewise.
23392 (cortex-m0plus.small-multiply): Likewise.
23393 (cortex-m1.small-multiply): Likewise.
23394
23395 2018-05-11 Allan Sandfeld Jensen <allan.jensen@qt.io>
23396 Jakub Jelinek <jakub@redhat.com>
23397
23398 PR tree-optimization/85692
23399 * tree-ssa-forwprop.c (simplify_vector_constructor): Try two
23400 source permute as well.
23401
23402 2018-05-11 Martin Liska <mliska@suse.cz>
23403
23404 PR sanitizer/85556
23405 * doc/extend.texi: Document LLVM style format for no_sanitize
23406 attribute.
23407
23408 2018-05-10 Michael Meissner <meissner@linux.vnet.ibm.com>
23409
23410 * config/rs6000/rs6000.c (mode_supports_dq_form): Rename
23411 mode_supports_vsx_dform_quad to mode_supports_dq_form.
23412 (mode_supports_vsx_dform_quad): Likewise.
23413 (mode_supports_vmx_dform): Move these functions to be next to the
23414 other mode_supports functions.
23415 (mode_supports_dq_form): Likewise.
23416 (quad_address_p): Change calls of mode_supports_vsx_dform_quad to
23417 mode_supports_dq_form.
23418 (reg_offset_addressing_ok_p): Likewise.
23419 (offsettable_ok_by_alignment): Likewise.
23420 (rs6000_legitimate_offset_address_p): Likewise.
23421 (legitimate_lo_sum_address_p): Likewise.
23422 (rs6000_legitimize_address): Likewise.
23423 (rs6000_legitimize_reload_address): Likewise.
23424 (rs6000_secondary_reload_inner): Likewise.
23425 (rs6000_preferred_reload_class): Likewise.
23426 (rs6000_output_move_128bit): Likewise.
23427
23428 2018-05-10 Uros Bizjak <ubizjak@gmail.com>
23429
23430 * config/i386/i386.c (ix86_expand_builtin) <case IX86_BUILTIN_RDPID>:
23431 Generate SImode target register for null target.
23432 <case IX86_BUILTIN_XGETBV>: Ditto.
23433 <case IX86_BUILTIN_XSETBV>: Optimize LSHIFTRT generation.
23434 * config/i386/xsaveintrin.h (_xgetbv): Add missing return.
23435
23436 2018-05-10 Carl Love <cel@us.ibm.com>
23437
23438 * config/rs6000/rs6000.md (prefetch): Generate ISA 2.06 instructions
23439 dcbtt and dcbtstt if operands[2] is 0.
23440
23441 2018-05-10 Uros Bizjak <ubizjak@gmail.com>
23442
23443 PR target/85693
23444 * config/i386/sse.md (usadv64qi): New expander.
23445
23446 2018-05-10 Segher Boessenkool <segher@kernel.crashing.org>
23447
23448 * config/rs6000/altivec.md (altivec_vmrghb, altivec_vmrghh,
23449 altivec_vmrghw, altivec_vmrglb, altivec_vmrglh, altivec_vmrglw): Remove
23450 -maltivec=be support.
23451 (vec_widen_umult_even_v16qi, vec_widen_smult_even_v16qi,
23452 vec_widen_umult_even_v8hi, vec_widen_smult_even_v8hi,
23453 vec_widen_umult_even_v4si, vec_widen_smult_even_v4si,
23454 vec_widen_umult_odd_v16qi, vec_widen_smult_odd_v16qi,
23455 vec_widen_umult_odd_v8hi, vec_widen_smult_odd_v8hi,
23456 vec_widen_umult_odd_v4si, vec_widen_smult_odd_v4si, altivec_vpkpx,
23457 altivec_vpks<VI_char>ss, altivec_vpks<VI_char>us,
23458 altivec_vpku<VI_char>us, altivec_vpku<VI_char>um, altivec_vsum2sws,
23459 altivec_vsumsws): Adjust.
23460 (altivec_vspltb *altivec_vspltb_internal, altivec_vsplth,
23461 *altivec_vsplth_internal, altivec_vspltw, *altivec_vspltw_internal,
23462 altivec_vspltsf, *altivec_vspltsf_internal): Remove -maltivec=be
23463 support.
23464 (altivec_vperm_<mode>, altivec_vperm_<mode>_uns,
23465 altivec_vupkhs<VU_char>, altivec_vupkls<VU_char>, altivec_vupkhpx,
23466 altivec_vupklpx, altivec_lvsl, altivec_lvsr): Adjust.
23467 (altivec_lve<VI_char>x): Delete expand.
23468 (*altivec_lve<VI_char>x_internal): Rename to...
23469 (altivec_lve<VI_char>x): ... this.
23470 (altivec_lvxl_<mode>): Delete expand.
23471 (*altivec_lvxl_<mode>_internal): Rename to ...
23472 (altivec_lvxl_<mode>): ... this.
23473 (altivec_stvxl_<mode>): Delete expand.
23474 (*altivec_stvxl_<mode>_internal): Rename to ...
23475 (altivec_stvxl_<mode>): ... this.
23476 (altivec_stve<VI_char>x): Delete expand.
23477 (*altivec_stve<VI_char>x_internal): Rename to ...
23478 (altivec_stve<VI_char>x): ... this.
23479 (doublee<mode>2, unsdoubleev4si2, doubleo<mode>2, unsdoubleov4si2,
23480 doubleh<mode>2, unsdoublehv4si2, doublel<mode>2, unsdoublelv4si2,
23481 reduc_plus_scal_<mode>): Adjust.
23482 * config/rs6000/rs6000-c.c (rs6000_target_modify_macros): Adjust
23483 comment.
23484 (rs6000_cpu_cpp_builtins): Adjust.
23485 (altivec_resolve_overloaded_builtin): Remove -maltivec=be support.
23486 * config/rs6000/rs6000-protos.h (altivec_expand_lvx_be,
23487 altivec_expand_stvx_be, altivec_expand_stvex_be): Delete.
23488 * config/rs6000/rs6000.c (rs6000_option_override_internal): Remove
23489 -maltivec=be support.
23490 (rs6000_split_vec_extract_var): Adjust.
23491 (rs6000_split_v4si_init): Adjust.
23492 (swap_selector_for_mode): Delete.
23493 (altivec_expand_lvx_be, altivec_expand_stvx_be,
23494 altivec_expand_stvex_be): Delete.
23495 (altivec_expand_lv_builtin, altivec_expand_stv_builtin): Remove
23496 -maltivec=be support.
23497 (rs6000_gimple_fold_builtin): Ditto.
23498 (rs6000_generate_float2_double_code, rs6000_generate_float2_code):
23499 Adjust.
23500 * config/rs6000/rs6000.h (VECTOR_ELT_ORDER_BIG): Delete.
23501 (TARGET_DIRECT_MOVE_64BIT): Adjust.
23502 * config/rs6000/rs6000.md (split for extendsidi2 for vectors): Adjust.
23503 * config/rs6000/rs6000.opt (maltivec=le, maltivec=be): Delete.
23504 * config/rs6000/vsx.md (floate<mode>, unsfloatev2di, floato<mode>,
23505 unsfloatov2di, vsignedo_v2df, vsignede_v2df, vunsignedo_v2df,
23506 vunsignede_v2df, vsx_extract_<mode>_p9, *vsx_extract_si,
23507 *vsx_extract_<mode>_p8, *vsx_extract_si_<uns>float_df,
23508 *vsx_extract_si_<uns>float_<mode>, vsx_set_<mode>_p9, vsx_set_v4sf_p9,
23509 *vsx_insert_extract_v4sf_p9, *vsx_insert_extract_v4sf_p9_2, and an
23510 anonymous split): Adjust.
23511 (vsx_mergel_<mode>, vsx_mergeh_<mode>): Remove -maltivec=be support.
23512 (vsx_xxspltd_<mode>, extract4b, insert4b): Adjust.
23513
23514 2018-05-10 Eric Botcazou <ebotcazou@adacore.com>
23515
23516 * configure.ac (gcc_gxx_include_dir_add_sysroot): Set it to 1 only
23517 when --with-gxx-include-dir is also specified.
23518 * configure: Regenerate.
23519
23520 2018-05-09 Jim Wilson <jimw@sifive.com>
23521
23522 PR target/84797
23523 * config.gcc (riscv*-*-*): Handle --with-multilib-list.
23524 * config/riscv/t-withmultilib: New.
23525 * config/riscv/withmultilib.h: New.
23526 * doc/install.texi: Document RISC-V --with-multilib-list support.
23527
23528 2018-05-09 Richard Biener <rguenther@suse.de>
23529
23530 * tree-vect-slp.c (vect_bb_slp_scalar_cost): Fill a cost
23531 vector.
23532 (vect_bb_vectorization_profitable_p): Adjust. Compute
23533 actual scalar cost using the cost vector and the add_stmt_cost
23534 machinery.
23535
23536 2018-05-09 Segher Boessenkool <segher@kernel.crashing.org>
23537
23538 PR rtl-optimization/85645
23539 * config/rs6000/rs6000.c (rs6000_emit_prologue_components): Put a SET
23540 in the REG_CFA_REGISTER note for LR, don't leave it empty.
23541
23542 2018-05-09 Segher Boessenkool <segher@kernel.crashing.org>
23543
23544 PR rtl-optimization/85645
23545 * shrink-wrap.c (spread_components): Return a boolean saying if
23546 anything was changed.
23547 (try_shrink_wrapping_separate): Iterate spread_components until
23548 nothing changes anymore.
23549
23550 2018-05-09 Segher Boessenkool <segher@kernel.crashing.org>
23551
23552 PR rtl-optimization/85645
23553 * regrename.c (build_def_use): Also kill the chains that include the
23554 destination of a REG_CFA_REGISTER note.
23555
23556 2018-05-09 Segher Boessenkool <segher@kernel.crashing.org>
23557
23558 PR rtl-optimization/85645
23559 * regcprop.c (copyprop_hardreg_forward_1): Don't propagate into an
23560 insn that has a REG_CFA_REGISTER note.
23561
23562 2018-05-09 Richard Sandiford <richard.sandiford@linaro.org>
23563
23564 * cfgexpand.c (expand_clobber): New function.
23565 (expand_gimple_stmt_1): Use it.
23566 * tree-vect-stmts.c (vect_clobber_variable): New function,
23567 split out from...
23568 (vectorizable_simd_clone_call): ...here.
23569 (vectorizable_store): Emit a clobber either side of an
23570 IFN_STORE_LANES sequence.
23571 (vectorizable_load): Emit a clobber after an IFN_LOAD_LANES sequence.
23572
23573 2018-05-09 Tom de Vries <tom@codesourcery.com>
23574
23575 PR target/85626
23576 * config/nvptx/nvptx.md (define_insn "trap", define_insn "trap_if_true")
23577 (define_insn "trap_if_false"): Add exit after trap.
23578
23579 2018-05-09 Eric Botcazou <ebotcazou@adacore.com>
23580
23581 PR rtl-optimization/85638
23582 * bb-reorder.c: Include common/common-target.h.
23583 (create_forwarder_block): New function extracted from...
23584 (fix_up_crossing_landing_pad): ...here. Rename into...
23585 (dw2_fix_up_crossing_landing_pad): ...this.
23586 (sjlj_fix_up_crossing_landing_pad): New function.
23587 (find_rarely_executed_basic_blocks_and_crossing_edges): In SJLJ mode,
23588 call sjlj_fix_up_crossing_landing_pad if there are incoming EH edges
23589 from both partitions and exit the loop after one iteration.
23590
23591 2018-05-08 Kelvin Nilsen <kelvin@gcc.gnu.org>
23592
23593 Revert:
23594 * doc/extend.texi (PowerPC Built-in Functions): Rename this
23595 subsection.
23596 (Basic PowerPC Built-in Functions): The new name of the
23597 subsection previously known as "PowerPC Built-in Functions".
23598 (Basic PowerPC Built-in Functions Available on all Configurations):
23599 New subsubsection.
23600 (Basic PowerPC Built-in Functions Available on ISA 2.05): New
23601 subsubsection.
23602 (Basic PowerPC Built-in Functions Available on ISA 2.06): New
23603 subsubsection.
23604 (Basic PowerPC Built-in Functions Available on ISA 2.07): New
23605 subsubsection.
23606 (Basic PowerPC Built-in Functions Available on ISA 3.0): New
23607 subsubsection.
23608
23609 2018-05-08 Jim Wilson <jimw@sifive.com>
23610
23611 * config/riscv/linux.h (MUSL_ABI_SUFFIX): Delete unnecessary backslash.
23612 (LD_EMUL_SUFFIX): New.
23613 (LINK_SPEC): Use it.
23614
23615 2018-05-08 Kelvin Nilsen <kelvin@gcc.gnu.org>
23616
23617 * doc/extend.texi (PowerPC Built-in Functions): Rename this
23618 subsection.
23619 (Basic PowerPC Built-in Functions): The new name of the
23620 subsection previously known as "PowerPC Built-in Functions".
23621 (Basic PowerPC Built-in Functions Available on all Configurations):
23622 New subsubsection.
23623 (Basic PowerPC Built-in Functions Available on ISA 2.05): New
23624 subsubsection.
23625 (Basic PowerPC Built-in Functions Available on ISA 2.06): New
23626 subsubsection.
23627 (Basic PowerPC Built-in Functions Available on ISA 2.07): New
23628 subsubsection.
23629 (Basic PowerPC Built-in Functions Available on ISA 3.0): New
23630 subsubsection.
23631
23632 2018-05-08 Jakub Jelinek <jakub@redhat.com>
23633
23634 PR target/85683
23635 * config/i386/i386.md: Add peepholes for mem {+,-,&,|,^}= x; mem != 0
23636 after cmpelim optimization.
23637
23638 2018-05-08 Olga Makhotina <olga.makhotina@intel.com>
23639
23640 * config.gcc: Support "goldmont".
23641 * config/i386/driver-i386.c (host_detect_local_cpu): Detect "goldmont".
23642 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
23643 PROCESSOR_GOLDMONT.
23644 * config/i386/i386.c (m_GOLDMONT): Define.
23645 (processor_target_table): Add "goldmont".
23646 (PTA_GOLDMONT): Define.
23647 (ix86_lea_outperforms): Add TARGET_GOLDMONT.
23648 (get_builtin_code_for_version): Handle PROCESSOR_GOLDMONT.
23649 (fold_builtin_cpu): Add M_INTEL_GOLDMONT.
23650 (fold_builtin_cpu): Add "goldmont".
23651 (ix86_add_stmt_cost): Add TARGET_GOLDMONT.
23652 (ix86_option_override_internal): Add "goldmont".
23653 * config/i386/i386.h (processor_costs): Define TARGET_GOLDMONT.
23654 (processor_type): Add PROCESSOR_GOLDMONT.
23655 * config/i386/i386.md: Add CPU "glm".
23656 * config/i386/glm.md: New file.
23657 * config/i386/x86-tune.def: Add m_GOLDMONT.
23658 * doc/invoke.texi: Add goldmont as x86 -march=/-mtune= CPU type.
23659
23660 2018-05-08 Jakub Jelinek <jakub@redhat.com>
23661
23662 PR target/85572
23663 * config/i386/i386.c (ix86_expand_sse2_abs): Handle E_V2DImode and
23664 E_V4DImode.
23665 * config/i386/sse.md (abs<mode>2): Use VI_AVX2 iterator instead of
23666 VI1248_AVX512VL_AVX512BW. Handle V2DImode and V4DImode if not
23667 TARGET_AVX512VL using ix86_expand_sse2_abs. Formatting fixes.
23668
23669 PR target/85317
23670 * config/i386/i386.c (ix86_fold_builtin): Handle
23671 IX86_BUILTIN_{,P}MOVMSK{PS,PD,B}{,128,256}.
23672
23673 PR target/85480
23674 * config/i386/sse.md (ssequaterinsnmode): New mode attribute.
23675 (*<extract_type>_vinsert<shuffletype><extract_suf>_0): New pattern.
23676
23677 2018-05-08 Richard Earnshaw <rearnsha@arm.com>
23678
23679 PR target/85658
23680 * config/arm/parsecpu.awk (check_cpu): Fix operator precedence.
23681 (check_arch): Likewise.
23682 (check_fpu): Return the result rather than printing it.
23683 (end arch): Fix operator precedence.
23684 (end cpu): Likewise.
23685 (END): Print the result from check_fpu.
23686
23687 2018-05-08 Richard Sandiford <richard.sandiford@linaro.org>
23688 Alan Hayward <alan.hayward@arm.com>
23689 David Sherwood <david.sherwood@arm.com>
23690
23691 * config/aarch64/aarch64-sve.md (*pred_cmp<cmp_op><mode>_combine)
23692 (*pred_cmp<cmp_op><mode>, *fcm<cmp_op><mode>_and_combine)
23693 (*fcmuo<mode>_and_combine, *fcm<cmp_op><mode>_and)
23694 (*fcmuo<mode>_and): New patterns.
23695
23696 2018-05-08 Richard Sandiford <richard.sandiford@linaro.org>
23697
23698 * config/aarch64/iterators.md (UNSPEC_COND_LO, UNSPEC_COND_LS)
23699 (UNSPEC_COND_HI, UNSPEC_COND_HS, UNSPEC_COND_UO): Delete.
23700 (SVE_INT_CMP, SVE_FP_CMP): New code iterators.
23701 (cmp_op, sve_imm_con): New code attributes.
23702 (SVE_COND_INT_CMP, imm_con): Delete.
23703 (cmp_op): Remove above unspecs from int attribute.
23704 * config/aarch64/aarch64-sve.md (*vec_cmp<cmp_op>_<mode>): Rename
23705 to...
23706 (*cmp<cmp_op><mode>): ...this. Use UNSPEC_MERGE_PTRUE instead of
23707 comparison-specific unspecs.
23708 (*vec_cmp<cmp_op>_<mode>_ptest): Rename to...
23709 (*cmp<cmp_op><mode>_ptest): ...this and adjust likewise.
23710 (*vec_cmp<cmp_op>_<mode>_cc): Rename to...
23711 (*cmp<cmp_op><mode>_cc): ...this and adjust likewise.
23712 (*vec_fcm<cmp_op><mode>): Rename to...
23713 (*fcm<cmp_op><mode>): ...this and adjust likewise.
23714 (*vec_fcmuo<mode>): Rename to...
23715 (*fcmuo<mode>): ...this and adjust likewise.
23716 (*pred_fcm<cmp_op><mode>): New pattern.
23717 * config/aarch64/aarch64.c (aarch64_emit_unop, aarch64_emit_binop)
23718 (aarch64_emit_sve_ptrue_op, aarch64_emit_sve_ptrue_op_cc): New
23719 functions.
23720 (aarch64_unspec_cond_code): Remove handling of LTU, GTU, LEU, GEU
23721 and UNORDERED.
23722 (aarch64_gen_unspec_cond, aarch64_emit_unspec_cond): Delete.
23723 (aarch64_emit_sve_predicated_cond): New function.
23724 (aarch64_expand_sve_vec_cmp_int): Use aarch64_emit_sve_ptrue_op_cc.
23725 (aarch64_emit_unspec_cond_or): Replace with...
23726 (aarch64_emit_sve_or_conds): ...this new function. Use
23727 aarch64_emit_sve_ptrue_op for the individual comparisons and
23728 aarch64_emit_binop to OR them together.
23729 (aarch64_emit_inverted_unspec_cond): Replace with...
23730 (aarch64_emit_sve_inverted_cond): ...this new function. Use
23731 aarch64_emit_sve_ptrue_op for the comparison and
23732 aarch64_emit_unop to invert the result.
23733 (aarch64_expand_sve_vec_cmp_float): Update after the above
23734 changes. Use aarch64_emit_sve_ptrue_op for native comparisons.
23735
23736 2018-05-07 Nathan Sidwell <nathan@acm.org>
23737
23738 * doc/invoke.texi (C++ Dialect Options): Remove -ffor-scope.
23739 * doc/extend.texi (Deprecated Features): Remove -fno-for-scope
23740 (Backwards Compatibility): Likewise.
23741
23742 2018-05-07 Luis Machado <luis.machado@linaro.org>
23743
23744 PR bootstrap/85681
23745 Revert:
23746 2018-05-07 Luis Machado <luis.machado@linaro.org>
23747
23748 * config/aarch64/aarch64-protos.h (cpu_prefetch_tune)
23749 <prefetch_dynamic_strides>: New const bool field.
23750 * config/aarch64/aarch64.c (generic_prefetch_tune): Update to include
23751 prefetch_dynamic_strides.
23752 (exynosm1_prefetch_tune): Likewise.
23753 (thunderxt88_prefetch_tune): Likewise.
23754 (thunderx_prefetch_tune): Likewise.
23755 (thunderx2t99_prefetch_tune): Likewise.
23756 (qdf24xx_prefetch_tune): Likewise. Set prefetch_dynamic_strides
23757 to false.
23758 (aarch64_override_options_internal): Update to set
23759 PARAM_PREFETCH_DYNAMIC_STRIDES.
23760 * doc/invoke.texi (prefetch-dynamic-strides): Document new option.
23761 * params.def (PARAM_PREFETCH_DYNAMIC_STRIDES): New.
23762 * params.h (PARAM_PREFETCH_DYNAMIC_STRIDES): Define.
23763 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Account for
23764 prefetch-dynamic-strides setting.
23765
23766 2018-05-07 Luis Machado <luis.machado@linaro.org>
23767
23768 * config/aarch64/aarch64-protos.h (cpu_prefetch_tune)
23769 <minimum_stride>: New const int field.
23770 * config/aarch64/aarch64.c (generic_prefetch_tune): Update to include
23771 minimum_stride field.
23772 (exynosm1_prefetch_tune): Likewise.
23773 (thunderxt88_prefetch_tune): Likewise.
23774 (thunderx_prefetch_tune): Likewise.
23775 (thunderx2t99_prefetch_tune): Likewise.
23776 (qdf24xx_prefetch_tune): Likewise. Set minimum_stride to 2048.
23777 (aarch64_override_options_internal): Update to set
23778 PARAM_PREFETCH_MINIMUM_STRIDE.
23779 * doc/invoke.texi (prefetch-minimum-stride): Document new option.
23780 * params.def (PARAM_PREFETCH_MINIMUM_STRIDE): New.
23781 * params.h (PARAM_PREFETCH_MINIMUM_STRIDE): Define.
23782 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Return false if
23783 stride is constant and is below the minimum stride threshold.
23784
23785 2018-05-07 Luis Machado <luis.machado@linaro.org>
23786
23787 * config/aarch64/aarch64.c (qdf24xx_prefetch_tune) <l2_cache_size>: Set
23788 to 512.
23789
23790 2018-05-07 Luis Machado <luis.machado@linaro.org>
23791
23792 * config/aarch64/aarch64-protos.h (cpu_prefetch_tune)
23793 <prefetch_dynamic_strides>: New const bool field.
23794 * config/aarch64/aarch64.c (generic_prefetch_tune): Update to include
23795 prefetch_dynamic_strides.
23796 (exynosm1_prefetch_tune): Likewise.
23797 (thunderxt88_prefetch_tune): Likewise.
23798 (thunderx_prefetch_tune): Likewise.
23799 (thunderx2t99_prefetch_tune): Likewise.
23800 (qdf24xx_prefetch_tune): Likewise. Set prefetch_dynamic_strides
23801 to false.
23802 (aarch64_override_options_internal): Update to set
23803 PARAM_PREFETCH_DYNAMIC_STRIDES.
23804 * doc/invoke.texi (prefetch-dynamic-strides): Document new option.
23805 * params.def (PARAM_PREFETCH_DYNAMIC_STRIDES): New.
23806 * params.h (PARAM_PREFETCH_DYNAMIC_STRIDES): Define.
23807 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Account for
23808 prefetch-dynamic-strides setting.
23809
23810 2018-05-07 Luis Machado <luis.machado@linaro.org>
23811
23812 * config/aarch64/aarch64-protos.h (cpu_prefetch_tune)
23813 <minimum_stride>: New const int field.
23814 * config/aarch64/aarch64.c (generic_prefetch_tune): Update to include
23815 minimum_stride field.
23816 (exynosm1_prefetch_tune): Likewise.
23817 (thunderxt88_prefetch_tune): Likewise.
23818 (thunderx_prefetch_tune): Likewise.
23819 (thunderx2t99_prefetch_tune): Likewise.
23820 (qdf24xx_prefetch_tune): Likewise. Set minimum_stride to 2048.
23821 (aarch64_override_options_internal): Update to set
23822 PARAM_PREFETCH_MINIMUM_STRIDE.
23823 * doc/invoke.texi (prefetch-minimum-stride): Document new option.
23824 * params.def (PARAM_PREFETCH_MINIMUM_STRIDE): New.
23825 * params.h (PARAM_PREFETCH_MINIMUM_STRIDE): Define.
23826 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Return false if
23827 stride is constant and is below the minimum stride threshold.
23828
23829 2018-05-06 Jakub Jelinek <jakub@redhat.com>
23830
23831 PR c++/85659
23832 * cfgexpand.c (expand_asm_stmt): Don't create a temporary if
23833 the type is addressable. Don't force op into register if it has
23834 BLKmode.
23835
23836 2018-05-05 Roland McGrath <mcgrathr@google.com>
23837
23838 PR other/77609
23839 * varasm.c (default_section_type_flags): Set SECTION_NOTYPE for
23840 any section for which we don't know a specific type it should have,
23841 regardless of name. Previously this was done only for the exact
23842 names ".init_array", ".fini_array", and ".preinit_array".
23843 (default_elf_asm_named_section): Add comment about
23844 relationship with default_section_type_flags and SECTION_NOTYPE.
23845 (get_section): Don't consider it a type conflict if one side has
23846 SECTION_NOTYPE and the other doesn't, as long as neither has the
23847 SECTION_BSS et al used in the default_section_type_flags logic.
23848
23849 2018-05-05 Tom de Vries <tom@codesourcery.com>
23850
23851 PR target/85653
23852 * config/nvptx/nvptx.c (WORKAROUND_PTXJIT_BUG_3): Define.
23853 (workaround_barsyncs): New function.
23854 (nvptx_reorg): Use workaround_barsyncs.
23855 * config/nvptx/nvptx.md (define_c_enum "unspecv"): Add UNSPECV_MEMBAR.
23856 (define_expand "nvptx_membar_cta"): New define_expand.
23857 (define_insn "*nvptx_membar_cta"): New insn.
23858
23859 2018-05-04 Pekka Jääskeläinen <pekka.jaaskelainen@parmance.com>
23860
23861 * brig-builtins.def: Add consts to ptrs etc. in BRIG builtin defs.
23862 To improve optimization opportunities.
23863 * builtin-types.def: The new needed builtin types for the above.
23864
23865 2018-05-04 Richard Biener <rguenther@suse.de>
23866
23867 * bb-reorder.c (sanitize_hot_paths): Release hot_bbs_to_check.
23868 * gimple-ssa-store-merging.c
23869 (imm_store_chain_info::output_merged_store): Remove redundant create,
23870 release split_store vector contents on failure.
23871 * tree-vect-slp.c (vect_schedule_slp_instance): Avoid leaking
23872 scalar stmt vector on cache hit.
23873
23874 2018-05-04 Segher Boessenkool <segher@kernel.crashing.org>
23875
23876 * common/config/rs6000/rs6000-common.c (rs6000_handle_option): Remove
23877 Xilinx FP support.
23878 * config.gcc (powerpc-xilinx-eabi*): Remove.
23879 * config/rs6000/predicates.md (easy_fp_constant): Remove Xilinx FP
23880 support.
23881 (fusion_addis_mem_combo_load): Ditto.
23882 * config/rs6000/rs6000-c.c (rs6000_target_modify_macros): Remove Xilinx
23883 FP support.
23884 (rs6000_cpu_cpp_builtins): Ditto.
23885 * config/rs6000/rs6000-linux.c
23886 (rs6000_linux_float_exceptions_rounding_supported_p): Ditto.
23887 * config/rs6000/rs6000-opts.h (enum fpu_type_t): Delete.
23888 * config/rs6000/rs6000.c (rs6000_debug_reg_global): Remove Xilinx FP
23889 support.
23890 (rs6000_setup_reg_addr_masks): Ditto.
23891 (rs6000_init_hard_regno_mode_ok): Ditto.
23892 (rs6000_option_override_internal): Ditto.
23893 (legitimate_lo_sum_address_p): Ditto.
23894 (rs6000_legitimize_address): Ditto.
23895 (rs6000_legitimize_reload_address): Ditto.
23896 (rs6000_legitimate_address_p): Ditto.
23897 (abi_v4_pass_in_fpr): Ditto.
23898 (setup_incoming_varargs): Ditto.
23899 (rs6000_gimplify_va_arg): Ditto.
23900 (rs6000_split_multireg_move): Ditto.
23901 (rs6000_savres_strategy): Ditto.
23902 (rs6000_emit_prologue_components): Ditto.
23903 (rs6000_emit_epilogue_components): Ditto.
23904 (rs6000_emit_prologue): Ditto.
23905 (rs6000_emit_epilogue): Ditto.
23906 (rs6000_elf_file_end): Ditto.
23907 (rs6000_function_value): Ditto.
23908 (rs6000_libcall_value): Ditto.
23909 * config/rs6000/rs6000.h: Ditto.
23910 (TARGET_MINMAX_SF, TARGET_MINMAX_DF): Delete, merge to ...
23911 (TARGET_MINMAX): ... this. New.
23912 (TARGET_SF_FPR, TARGET_DF_FPR, TARGET_SF_INSN, TARGET_DF_INSN): Delete.
23913 * config/rs6000/rs6000.md: Remove Xilinx FP support.
23914 (*movsi_internal1_single): Delete.
23915 * config/rs6000/rs6000.opt (msingle-float, mdouble-float, msimple-fpu,
23916 mfpu=, mxilinx-fpu): Delete.
23917 * config/rs6000/singlefp.h: Delete.
23918 * config/rs6000/sysv4.h: Remove Xilinx FP support.
23919 * config/rs6000/t-rs6000: Ditto.
23920 * config/rs6000/t-xilinx: Delete.
23921 * config/rs6000/titan.md: Adjust for fp_type removal.
23922 * config/rs6000/vsx.md: Remove Xilinx FP support.
23923 (VStype_simple): Delete.
23924 (VSfptype_simple, VSfptype_mul, VSfptype_div, VSfptype_sqrt): Delete.
23925 * config/rs6000/xfpu.h: Delete.
23926 * config/rs6000/xfpu.md: Delete.
23927 * config/rs6000/xilinx.h: Delete.
23928 * config/rs6000/xilinx.opt: Delete.
23929 * doc/invoke.texi (RS/6000 and PowerPC Options): Remove
23930 -msingle-float, -mdouble-float, -msimple-fpu, -mfpu=, and -mxilinx-fpu.
23931
23932 2018-05-04 Tom de Vries <tom@codesourcery.com>
23933
23934 PR libgomp/85639
23935 * builtins.c (expand_builtin_goacc_parlevel_id_size): Handle null target
23936 if ignore == 0.
23937
23938 2018-05-04 Richard Biener <rguenther@suse.de>
23939
23940 PR middle-end/85627
23941 * tree-complex.c (update_complex_assignment): We are always in SSA form.
23942 (expand_complex_div_wide): Likewise.
23943 (expand_complex_operations_1): Likewise.
23944 (expand_complex_libcall): Preserve EH info of the original stmt.
23945 (tree_lower_complex): Handle removed blocks.
23946 * tree.c (build_common_builtin_nodes): Do not set ECF_NOTRHOW
23947 on complex multiplication and division libcall builtins.
23948
23949 2018-05-04 Richard Biener <rguenther@suse.de>
23950
23951 PR middle-end/85574
23952 * fold-const.c (negate_expr_p): Restrict negation of operand
23953 zero of a division to when we know that can happen without
23954 overflow.
23955 (fold_negate_expr_1): Likewise.
23956
23957 2018-05-04 Jakub Jelinek <jakub@redhat.com>
23958
23959 PR libstdc++/85466
23960 * real.h (real_nextafter): Declare.
23961 * real.c (real_nextafter): New function.
23962 * fold-const-call.c (fold_const_nextafter): New function.
23963 (fold_const_call_sss): Call it for CASE_CFN_NEXTAFTER and
23964 CASE_CFN_NEXTTOWARD.
23965 (fold_const_call_1): For CASE_CFN_NEXTTOWARD call fold_const_call_sss
23966 even when arg1_mode is different from arg0_mode.
23967
23968 2018-05-03 Nathan Sidwell <nathan@acm.org>
23969
23970 * doc/extend.texi (Deprecated Features): Remove
23971 -ffriend-injection.
23972 (Backwards Compatibility): Likewise.
23973 * doc/invoke.texi (C++ Language Options): Likewise.
23974 (C++ Dialect Options): Likewise.
23975
23976 2018-05-03 Jakub Jelinek <jakub@redhat.com>
23977
23978 PR target/85530
23979 * config/i386/avx512fintrin.h (_mm512_mullox_epi64,
23980 _mm512_mask_mullox_epi64): New intrinsics.
23981
23982 2018-05-03 Tom de Vries <tom@codesourcery.com>
23983
23984 PR testsuite/85106
23985 * doc/sourcebuild.texi (Commands for use in dg-final, Scan optimization
23986 dump files): Add offload-tree.
23987
23988 2018-05-03 Richard Biener <rguenther@suse.de>
23989
23990 PR tree-optimization/85615
23991 * tree-ssa-threadupdate.c (thread_block_1): Only allow exits
23992 to loops not nested in BBs loop father to avoid creating multi-entry
23993 loops.
23994
23995 2018-05-03 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
23996
23997 PR tree-optimization/70291
23998 * tree-complex.c (expand_complex_libcall): Add type, inplace_p
23999 arguments. Change return type to tree. Emit libcall as a new
24000 statement rather than replacing existing one when inplace_p is true.
24001 (expand_complex_multiplication_components): New function.
24002 (expand_complex_multiplication): Expand floating-point complex
24003 multiplication using the above.
24004 (expand_complex_division): Rename inner_type parameter to type.
24005 Update expand_complex_libcall call-site.
24006 (expand_complex_operations_1): Update expand_complex_multiplication
24007 and expand_complex_division call-sites.
24008
24009 2018-05-02 Jakub Jelinek <jakub@redhat.com>
24010
24011 PR target/85582
24012 * config/i386/i386.md (*ashl<dwi>3_doubleword_mask,
24013 *ashl<dwi>3_doubleword_mask_1, *<shift_insn><dwi>3_doubleword_mask,
24014 *<shift_insn><dwi>3_doubleword_mask_1): In condition require that
24015 the highest significant bit of the shift count mask is clear. In
24016 check whether and[sq]i3 is needed verify that all significant bits
24017 of the shift count other than the highest are set.
24018
24019 2018-05-02 Tom de Vries <tom@codesourcery.com>
24020
24021 PR libgomp/82428
24022 * builtins.def (DEF_GOACC_BUILTIN_ONLY): Define.
24023 * omp-builtins.def (BUILT_IN_GOACC_PARLEVEL_ID)
24024 (BUILT_IN_GOACC_PARLEVEL_SIZE): New builtin.
24025 * builtins.c (expand_builtin_goacc_parlevel_id_size): New function.
24026 (expand_builtin): Call expand_builtin_goacc_parlevel_id_size.
24027 * doc/extend.texi (Other Builtins): Add __builtin_goacc_parlevel_id and
24028 __builtin_goacc_parlevel_size.
24029
24030 2018-05-02 Richard Biener <rguenther@suse.de>
24031
24032 PR tree-optimization/85597
24033 * tree-vect-stmts.c (vectorizable_operation): For ternary SLP
24034 do not use split vect_get_vec_defs call but call vect_get_slp_defs
24035 directly.
24036
24037 2018-05-02 Tom de Vries <tom@codesourcery.com>
24038
24039 PR testsuite/85106
24040 * doc/sourcebuild.texi (Commands for use in dg-final, Scan optimization
24041 dump files): Add ltrans-tree.
24042
24043 2018-05-02 Tom de Vries <tom@codesourcery.com>
24044
24045 PR testsuite/85106
24046 * doc/sourcebuild.texi (Commands for use in dg-final, Scan optimization
24047 dump files): Add wpa-ipa.
24048
24049 2018-05-02 Segher Boessenkool <segher@kernel.crashing.org>
24050
24051 * config.gcc (powerpc*-*-*): Remove paired.h. Unsupport the
24052 powerpc*-*-linux*paired* target.
24053 * config/rs6000/750cl.h: Delete.
24054 * config/rs6000/paired.h: Delete.
24055 * config/rs6000/paired.md: Delete.
24056 * config/rs6000/predicates.md (easy_vector_constant): Remove paired
24057 float support.
24058 * config/rs6000/rs6000-builtin.def: Remove paired float support.
24059 * config/rs6000/rs6000-c.c (rs6000_target_modify_macros): Update
24060 comment. Remove paired float support.
24061 * config/rs6000/rs6000-modes.def: Remove V2SF and V2SI.
24062 * config/rs6000/rs6000-opts.h (enum rs6000_vector): Delete
24063 VECTOR_PAIRED.
24064 * config/rs6000/rs6000-protos.h (paired_expand_vector_init,
24065 paired_emit_vector_cond_expr, paired_expand_vector_move): Delete
24066 declarations.
24067 * config/rs6000/rs6000.c: Remove paired float support.
24068 (paired_expand_vector_init, paired_expand_vector_move,
24069 paired_emit_vector_compare, paired_emit_vector_cond_expr,
24070 (paired_expand_lv_builtin, paired_expand_stv_builtin,
24071 paired_expand_builtin, paired_expand_predicate_builtin,
24072 paired_init_builtins): Delete.
24073 * config/rs6000/rs6000.h: Remove paired float support.
24074 * config/rs6000/rs6000.md: Remove paired float support.
24075 (move_from_CR_ov_bit): Delete.
24076 * config/rs6000/rs6000.opt (mpaired): Delete.
24077 * config/rs6000/t-rs6000: Remove paired.md from MD_INCLUDES.
24078 * doc/invoke.texi (RS/6000 and PowerPC Options): Delete -mpaired.
24079
24080 2018-05-02 Richard Biener <rguenther@suse.de>
24081
24082 PR middle-end/85567
24083 * gimplify.c (gimplify_save_expr): When in SSA form allow
24084 SAVE_EXPRs to compute to SSA vars.
24085
24086 2018-05-02 Jakub Jelinek <jakub@redhat.com>
24087
24088 PR target/85582
24089 * config/i386/i386.md (*ashl<dwi>3_doubleword_mask,
24090 *ashl<dwi>3_doubleword_mask_1, *<shift_insn><dwi>3_doubleword_mask,
24091 *<shift_insn><dwi>3_doubleword_mask_1): If and[sq]i3 is needed, don't
24092 clobber operands[2], instead use a new pseudo. Formatting fixes.
24093
24094 2018-05-02 Richard Sandiford <richard.sandiford@linaro.org>
24095
24096 PR tree-optimization/85586
24097 * tree-vect-data-refs.c (vect_analyze_data_ref_dependence): Only
24098 exit early for statements in the same group if the accesses are
24099 not strided.
24100
24101 2018-05-02 Tom de Vries <tom@codesourcery.com>
24102
24103 PR lto/85451
24104 * lto-wrapper.c (compile_offload_image): Add "could not find mkoffload"
24105 error message.
24106
24107 2018-05-01 Marc Glisse <marc.glisse@inria.fr>
24108
24109 PR tree-optimization/85143
24110 * match.pd (A<B&A<C): Extend to BIT_IOR_EXPR.
24111
24112 2018-05-01 Tom de Vries <tom@codesourcery.com>
24113
24114 PR lto/85451
24115 * config/nvptx/mkoffload.c (main): Suggest using -B in "offload compiler
24116 not found" error message.
24117
24118 2018-05-01 Tom de Vries <tom@codesourcery.com>
24119
24120 PR other/83786
24121 * vec.h (VEC_ORDERED_REMOVE_IF, VEC_ORDERED_REMOVE_IF_FROM_TO): Define.
24122 * vec.c (test_ordered_remove_if): New function.
24123 (vec_c_tests): Call test_ordered_remove_if.
24124 * dwarf2cfi.c (connect_traces): Use VEC_ORDERED_REMOVE_IF_FROM_TO.
24125 * lto-streamer-out.c (prune_offload_funcs): Use VEC_ORDERED_REMOVE_IF.
24126 * tree-vect-patterns.c (vect_pattern_recog_1): Use
24127 VEC_ORDERED_REMOVE_IF.
24128
24129 2018-05-01 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
24130
24131 PR tree-optimization/82665
24132 * vr-values.c (vr_values::extract_range_from_binary_expr): Handle
24133 pointer subtraction where arguments come from a memchr call.
24134
24135 2018-05-01 Jakub Jelinek <jakub@redhat.com>
24136
24137 * configure.ac (LD_AS_NEEDED_OPTION, LD_NO_AS_NEEDED_OPTION): Use
24138 --push-state --as-needed and --pop-state instead of --as-needed and
24139 --no-as-needed if ld supports it.
24140 * configure: Regenerated.
24141
24142 PR web/85578
24143 * doc/install.texi2html: Replace _002d with - and _002a with * in
24144 generated html files using sed.
24145
24146 2018-04-30 David Malcolm <dmalcolm@redhat.com>
24147
24148 PR c++/85523
24149 * gcc-rich-location.c (blank_line_before_p): New function.
24150 (use_new_line): New function.
24151 (gcc_rich_location::add_fixit_insert_formatted): New function.
24152 * gcc-rich-location.h
24153 (gcc_rich_location::add_fixit_insert_formatted): New function.
24154
24155 2018-04-30 David Malcolm <dmalcolm@redhat.com>
24156
24157 * selftest.c (assert_streq): Rename "expected" and "actual" to
24158 "val1" and "val2". Extend NULL-handling to cover both inputs
24159 symmetrically, while still requiring both to be non-NULL for a pass.
24160 * selftest.h (assert_streq): Rename "expected" and "actual" to
24161 "val1" and "val2".
24162 (ASSERT_EQ): Likewise.
24163 (ASSERT_EQ_AT): Likewise.
24164 (ASSERT_KNOWN_EQ): Likewise.
24165 (ASSERT_KNOWN_EQ_AT): Likewise.
24166 (ASSERT_NE): Likewise.
24167 (ASSERT_MAYBE_NE): Likewise.
24168 (ASSERT_MAYBE_NE_AT): Likewise.
24169 (ASSERT_STREQ): Likewise. Clarify that both must be non-NULL for
24170 the assertion to pass.
24171 (ASSERT_STREQ_AT): Likewise.
24172
24173 2018-04-30 Jonathan Wakely <jwakely@redhat.com>
24174
24175 * doc/invoke.texi (-fpie, -fPIE): Fix grammar and clarify
24176 interaction with -pie.
24177
24178 2018-04-30 David Malcolm <dmalcolm@redhat.com>
24179
24180 * selftest.h: Fix alphabetization of per-source-file selftest
24181 declarations.
24182
24183 2018-04-30 Jason Merrill <jason@redhat.com>
24184
24185 PR c++/61982 - dead stores to destroyed objects.
24186 * gimplify.c (gimplify_modify_expr): Simplify complex lvalue on LHS
24187 of clobber.
24188
24189 2018-04-30 Jason Merrill <jason@redhat.com>
24190
24191 * tree.c (build_clobber): New.
24192 * tree.h: Declare it.
24193 * gimplify.c (gimplify_bind_expr, gimplify_target_expr): Use it.
24194
24195 2018-04-30 David Malcolm <dmalcolm@redhat.com>
24196
24197 * diagnostic-show-locus.c (layout::layout): Update for
24198 location_get_source_line returning a char_span.
24199 (struct char_span): Move to input.h.
24200 (struct correction): Update for fields in char_span becoming
24201 private.
24202 (struct source_line): Update for location_get_source_line
24203 returning a char_span.
24204 (layout::print_line): Likewise.
24205 * edit-context.c (edited_file::print_content): Likewise.
24206 (edited_file::print_diff_hunk): Likewise.
24207 (edited_file::print_run_of_changed_lines): Likewise.
24208 (edited_file::get_num_lines): Likewise.
24209 (edited_line::edited_line): Likewise.
24210 * final.c (asm_show_source): Likewise.
24211 * input.c (location_get_source_line): Convert return type
24212 from const char * to char_span, losing the final "line_len"
24213 param.
24214 (dump_location_info): Update for the above.
24215 (get_substring_ranges_for_loc): Likewise. Use a char_span
24216 when handling the literal within the line.
24217 (test_reading_source_line): Update for location_get_source_line
24218 returning a char_span.
24219 * input.h (class char_span): Move here from
24220 diagnostic-show-locus.c, converting from a struct to a class.
24221 Make data members private.
24222 (char_span::operator bool): New.
24223 (char_span::length): New.
24224 (char_span::get_buffer): New.
24225 (char_span::operator[]): New.
24226 (char_span::subspan): Make const.
24227 (char_span::xstrdup): New.
24228 (location_get_source_line): Convert return type from const char *
24229 to char_span, losing the final "line_size" param.
24230
24231 2018-04-30 Jan Hubicka <jh@suse.cz>
24232
24233 * lto-wrapper.c (ltrans_priorities): New static var.
24234 (cmp_priority): New.
24235 (run_gcc): Read priorities and if doing parallel build order
24236 the Makefile by them.
24237
24238 2018-04-30 David Malcolm <dmalcolm@redhat.com>
24239
24240 * input.h (builtins_location_check): Convert to a STATIC_ASSERT.
24241
24242 2018-04-30 Richard Biener <rguenther@suse.de>
24243
24244 * tree-cfg.c (verify_address): Remove base argument, add
24245 flag whether to check TREE_ADDRESSABLE and do that.
24246 (verify_expr): Remove.
24247 (verify_types_in_gimple_reference): Add pieces from verify_expr.
24248 (verify_gimple_assign_single): Likewise.
24249 (verify_gimple_switch): Likewise.
24250 (verify_expr_location_1): Dereference tp once. Add (disabled)
24251 piece from verify_expr.
24252 (verify_gimple_in_cfg): Do not call verify_expr on all ops.
24253
24254 2018-04-30 Claudiu Zissulescu <claziss@synopsys.com>
24255
24256 * config/arc/linux.h (CLEAR_INSN_CACHE): Define.
24257
24258 2018-04-30 Claudiu Zissulescu <claziss@synopsys.com>
24259
24260 * config/arc/arc-protos.h (prepare_extend_operands): Remove.
24261 (small_data_pattern): Likewise.
24262 (arc_rewrite_small_data): Likewise.
24263 * config/arc/arc.c (LEGITIMATE_SMALL_DATA_OFFSET_P): Remove.
24264 (LEGITIMATE_SMALL_DATA_ADDRESS_P): Likewise.
24265 (get_symbol_alignment): New function.
24266 (legitimate_small_data_address_p): Likewise.
24267 (legitimate_scaled_address): Update, call
24268 legitimate_small_data_address_p.
24269 (output_sdata): New static variable.
24270 (arc_print_operand): Update how we handle small data operands.
24271 (arc_print_operand_address): Likewise.
24272 (arc_legitimate_address_p): Update, use
24273 legitimate_small_data_address_p.
24274 (arc_rewrite_small_data_p): Remove.
24275 (arc_rewrite_small_data_1): Likewise.
24276 (arc_rewrite_small_data): Likewise.
24277 (small_data_pattern): Likewise.
24278 (compact_sda_memory_operand): Update to use
24279 legitimate_small_data_address_p and get_symbol_alignment.
24280 (prepare_move_operands): Don't rewite sdata pattern.
24281 (prepare_extend_operands): Remove.
24282 * config/arc/arc.md (zero_extendqihi2): Don't rewrite sdata
24283 pattern.
24284 (zero_extendqisi2): Likewise.
24285 (zero_extendhisi2): Likewise.
24286 (extendqihi2): Likewise.
24287 (extendqisi2): Likewise.
24288 (extendhisi2): Likewise.
24289 (addsi3): Likewise.
24290 (subsi3): Likewise.
24291 (andsi3): Likewise.
24292 * config/arc/constraints.md (Usd): Change it to memory constraint.
24293
24294 2018-04-30 Claudiu Zissulescu <claziss@synopsys.com>
24295
24296 * config/arc/arc.c (arc_split_move): Allow signed 6-bit constants
24297 as source of std instructions.
24298 * config/arc/arc.md (movsi_insn): Update pattern predicate to
24299 allow 6-bit constants as source for store instructions.
24300 (movdi_insn): Update instruction pattern to allow 6-bit constants
24301 as source for store instructions.
24302
24303 2018-04-30 Jonathan Wakely <jwakely@redhat.com>
24304
24305 * doc/invoke.texi (-fdebug-types-section): Fix grammar.
24306
24307 2018-04-30 Nathan Sidwell <nathan@acm.org>
24308 Sandra Loosemore <sandra@codesourcery.com>
24309
24310 * dumpfile.c (dump_open): Allow '-' for stdout.
24311 * doc/invoke.texi (Developer Options): Document dump filename
24312 determination early. Document stdin/stdout selection.
24313
24314 2018-04-30 Andrew Sadek <andrew.sadek.se@gmail.com>
24315
24316 Microblaze Target: PIC data text relative
24317
24318 * config/microblaze/microblaze.opt: add new option -mpic-data-text-rel.
24319 * config/microblaze/microblaze-protos.h (microblaze_constant_address_p):
24320 Add declaration.
24321 * config/microblaze/microblaze.h (microblaze_constant_address_p):
24322 CONSTANT_ADDRESS_P definition to microblaze_constant_address_p.
24323 * config/microblaze/microblaze.c (TARGET_PIC_DATA_TEXT_REL):
24324 New addressing mode for data-text relative position indepenedent code.
24325 (microblaze_classify_unspec): add 'UNSPEC_TEXT' case ->
24326 'ADDRESS_SYMBOLIC_TXT_REL'.
24327 (microblaze_classify_address): Add handling for UNSPEC + CONST_INT.
24328 (microblaze_legitimate_pic_operand): Exclude function calls from
24329 pic operands in case of TARGET_PIC_DATA_TEXT_REL option.
24330 (microblaze_legitimize_address): Generate 'UNSPEC_TEXT' for all possible
24331 addresses cases.
24332 (microblaze_address_insns): Add 'ADDRESS_SYMBOLIC_TXT_REL' case.
24333 (print_operand): Add 'ADDRESS_SYMBOLIC_TXT_REL' case.
24334 (print_operand_address): Add 'ADDRESS_SYMBOLIC_TXT_REL' case + handling
24335 for 'address + offset'.
24336 (microblaze_expand_prologue): Add new function prologue call for
24337 'r20' assignation.
24338 (microblaze_asm_generate_pic_addr_dif_vec): Override new target hook
24339 'TARGET_ASM_GENERATE_PIC_ADDR_DIFF_VEC' to disable address diff vector
24340 table in case of TARGET_PIC_DATA_TEXT_REL.
24341 (expand_pic_symbol_ref): Add handling for 'UNSPEC_TEXT'.
24342 * config/microblaze/microblaze.md (TARGET_PIC_DATA_TEXT_REL):
24343 Add new macros 'UNSPEC_TEXT',
24344 'UNSPEC_SET_TEXT' + add rule for setting r20 in function prologue
24345 + exclude function calls from 'UNSPEC_PLT' in case of data text
24346 relative mode.
24347 * doc/tm.texi.in (TARGET_ASM_GENERATE_PIC_ADDR_DIFF_VEC): Add
24348 new target hook for generating address diff vector tables in case of
24349 flag_pic.
24350 * doc/tm.texi : Regenerate.
24351 * stmt.c (TARGET_ASM_GENERATE_PIC_ADDR_DIFF_VEC): Append new condition
24352 'targetm.asm_out.generate_pic_addr_diff_vec' to flag_pic in case
24353 of addr diff vector generation.
24354 * target.def (TARGET_ASM_GENERATE_PIC_ADDR_DIFF_VEC): Add
24355 target hook definition.
24356 * targhooks.h, targhooks.c (TARGET_ASM_GENERATE_PIC_ADDR_DIFF_VEC):
24357 Add default function for generate_pic_addr_diff_vec -> flag_pic.
24358 * doc/invoke.texi (Add new pic option): Add new microblaze pic
24359 option for data text relative.
24360
24361 2018-04-30 Richard Biener <rguenther@suse.de>
24362
24363 * tree-chrec.h (evolution_function_is_constant_p): Remove
24364 redundant check.
24365 * tree-cfg.c (tree_node_can_be_shared): Re-order checks.
24366
24367 2018-04-30 Richard Biener <rguenther@suse.de>
24368
24369 PR bootstrap/85571
24370 * dwarf2out.c (gen_producer_string): Ignore -fchecking[=].
24371
24372 2018-04-30 Richard Biener <rguenther@suse.de>
24373
24374 PR tree-optimization/28364
24375 PR tree-optimization/85275
24376 * tree-ssa-loop-ch.c (ch_base::copy_headers): Stop after
24377 copying first exit test.
24378
24379 2018-04-28 Mark Wielaard <mark@klomp.org>
24380
24381 * dwarf2out.c (dwarf2out_finish): Add .debug_addr table header for
24382 dwarf_version >= 5.
24383 (dwarf_AT): Handle DW_AT_addr_base.
24384 (add_top_level_skeleton_die_attrs): Use dwarf_AT for DW_AT_addr_base.
24385
24386 2018-04-28 Uros Bizjak <ubizjak@gmail.com>
24387
24388 PR target/84431
24389 * config/i386/i386.md (*ashl<dwi>3_doubleword_mask): New pattern.
24390 (*ashl<dwi>3_doubleword_mask_1): Ditto.
24391 (*<shift_insn><dwi>3_doubleword_mask): Ditto.
24392 (*<shift_insn><dwi>3_doubleword_mask_1): Ditto.
24393
24394 2018-04-28 Richard Biener <rguenther@suse.de>
24395
24396 * tree-cfg.c (verify_gimple_phi): Take a gphi * argument.
24397 (verify_gimple_in_cfg): Rename visited_stmts to visited_throwing_stmts
24398 to reflect use. Only add interesting stmts.
24399
24400 2018-04-27 Martin Jambor <mjambor@suse.cz>
24401
24402 PR ipa/85549
24403 * ipa-cp.c (find_aggregate_values_for_callers_subset): Make sure
24404 the jump function allows for passing through aggregate values.
24405
24406 2018-04-27 David Malcolm <dmalcolm@redhat.com>
24407
24408 * input.h (in_system_header_at): Convert from macro to inline
24409 function.
24410 (from_macro_expansion_at): Likewise.
24411 (from_macro_definition_at): Likewise.
24412
24413 2018-04-27 Jeff Law <law@redhat.com>
24414
24415 * config.gcc: Mark tile* targets as deprecated/obsolete.
24416
24417 2018-04-27 Richard Biener <rguenther@suse.de>
24418
24419 * config/aarch64/aarch64.c: Simplify ap.__stack advance and
24420 fix for ILP32.
24421
24422 2018-04-27 Richard Biener <rguenther@suse.de>
24423
24424 * tree-cfg.c (verify_expr): Make dead code hit gcc_unreachable.
24425
24426 2018-04-27 Uros Bizjak <ubizjak@gmail.com>
24427
24428 * config/i386/i386.md (*movti_internal): Substitute Ye constraint
24429 with Yd constraint. Set "preferred_for_speed" attribute from
24430 TARGET_INTER_UNIT_MOVES_{FROM,TO}_VEC for alternatives
24431 with Yd constraint.
24432 (*movdi_internal): Ditto.
24433 (movti_interunit splitters): Remove
24434 TARGET_INTER_UNIT_MOVES_{FROM,TO}_VEC from insn condition.
24435 (movdi_interunit splitters): Ditto.
24436 * config/i386/constraints.md (Ye): Remove.
24437 (Yd): Do not depend on TARGET_INTER_UNIT_MOVES_{FROM,TO}_VEC.
24438
24439 2018-04-27 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
24440
24441 PR target/85512
24442 * config/aarch64/constraints.md (Usg): Limit to 31.
24443 (Usj): Limit to 63.
24444
24445 2018-04-27 Jakub Jelinek <jakub@redhat.com>
24446
24447 PR tree-optimization/85529
24448 * tree-ssa-reassoc.c (optimize_range_tests_var_bound): Add FIRST_BB
24449 argument. Don't call get_nonzero_bits if opcode is ERROR_MARK_NODE,
24450 rhs2 def stmt's bb is dominated by first_bb and it isn't an obvious
24451 zero extension or masking of the MSB bit.
24452 (optimize_range_tests): Add FIRST_BB argument, pass it through
24453 to optimize_range_tests_var_bound.
24454 (maybe_optimize_range_tests, reassociate_bb): Adjust
24455 optimize_range_tests callers.
24456
24457 2018-04-26 Richard Biener <rguenther@suse.de>
24458 Jakub Jelinek <jakub@redhat.com>
24459
24460 * cgraph.h (symbol_table): Just declare debug method here.
24461 * symtab.c (symbol_table::debug): Define.
24462
24463 2018-04-26 Eric Botcazou <ebotcazou@adacore.com>
24464
24465 * loop-invariant.c (may_assign_reg_p): Return false for frame pointer.
24466
24467 2018-04-26 Uros Bizjak <ubizjak@gmail.com>
24468
24469 * config/i386/i386.md ("isa" attribute): Add x64_sse2.
24470 ("enabled" attribute): Handle x64_sse2 "isa" attribute.
24471 (*movdi_internal): Substitute Yi and Yj constraint with x
24472 and Ym and Yn constraint with y constraint. Update "isa"
24473 attribute and set "preferred_for_speed" attribute from
24474 TARGET_INTER_UNIT_MOVES_{FROM,TO}_VEC for updated alternatives.
24475 (*movsi_internal): Ditto.
24476 (*movdf_internal): Ditto.
24477 (*movsf_internal): Ditto.
24478 (*zero_extendsidi2): Ditto.
24479 * config/i386/sse.md (vec_set<mode>_0): Ditto.
24480 (sse2_loadld): Ditto.
24481 (*vec_extract<ssevecmodelower>_0): Ditto.
24482 (*vec_extractv4si_0_zext_sse4): Ditto.
24483 (vec_concatv2di): Ditto.
24484 (*vec_dup<mode>): Ditto.
24485 * config/i386/mmx.md (*mov<mode>_internal): Ditto.
24486 * config/i386/constraints.md (Yi): Remove.
24487 (Yj): Remove.
24488 (Ym): Remove.
24489 (Yn): Remove.
24490
24491 2018-04-26 Nathan Sidwell <nathan@acm.org>
24492
24493 * dumpfile.c (dump_open): New.
24494 (dump_open_alternate_stream, dump_start, dump_begin): Call it.
24495 (dump_finish): Detect stdio/stderr by value not name.
24496
24497 2018-04-26 Jonathan Wakely <jwakely@redhat.com>
24498
24499 * doc/invoke.texi (-Wreturn-type): Document default status for C++.
24500
24501 2018-04-26 Tom de Vries <tom@codesourcery.com>
24502
24503 PR target/84952
24504 * config/nvptx/nvptx.c (verify_neutering_jumps)
24505 (verify_neutering_labels): New function
24506 (nvptx_single): Use verify_neutering_jumps and verify_neutering_labels.
24507
24508 2018-04-26 Tom de Vries <tom@codesourcery.com>
24509
24510 PR target/84025
24511 * config/nvptx/nvptx.c (needs_neutering_p): New function.
24512 (nvptx_single): Use needs_neutering_p to skip over insns that do not
24513 need neutering.
24514
24515 2018-04-26 Richard Biener <rguenther@suse.de>
24516 Tom de Vries <tom@codesourcery.com>
24517
24518 PR lto/85422
24519 * lto-streamer-out.c (output_function): Fixup loops if required to match
24520 discovery done in the reader.
24521
24522 2018-04-26 Richard Biener <rguenther@suse.de>
24523
24524 PR tree-optimization/85116
24525 * tree-ssa-loop-ch.c (do_while_loop_p): A do-while loop should
24526 have a loop exit from the single latch predecessor. Remove
24527 case of header with just condition.
24528 (ch_base::copy_headers): Exclude infinite loops from any
24529 processing.
24530 (pass_ch::execute): Record exits.
24531
24532 2018-04-26 Richard Biener <rguenther@suse.de>
24533
24534 * tree-vect-data-refs.c (vect_get_data_access_cost): Get
24535 prologue cost vector and pass it to vect_get_load_cost.
24536 (vect_get_peeling_costs_all_drs): Likewise.
24537 (vect_peeling_hash_get_lowest_cost): Likewise.
24538 (vect_enhance_data_refs_alignment): Likewise.
24539
24540 2018-04-26 Richard Biener <rguenther@suse.de>
24541
24542 PR middle-end/85450
24543 * tree-cfg.c (verify_gimple_assign_unary): Restore proper
24544 checking of integer<->pointer conversions.
24545 * omp-expand.c (expand_omp_for_static_nochunk): Avoid
24546 sign-/zero-extending pointer types.
24547 (expand_omp_for_static_chunk): Likewise.
24548
24549 2018-03-22 Hans-Peter Nilsson <hp@axis.com>
24550 Jean Lee <xiaoyur347@gmail.com>
24551
24552 * config/mips/mips.c (mips_asan_shadow_offset): New function.
24553 (TARGET_ASAN_SHADOW_OFFSET): Define.
24554 * config/mips/mips.h (FRAME_GROWS_DOWNWARD): Augment to also be
24555 true for -fsanitize=address.
24556
24557 2018-04-25 Mark Wielaard <mark@klomp.org>
24558
24559 * dwarf2out.c (file_info_cmp): Sort longer dir prefixes before
24560 shorter ones.
24561
24562 2018-04-25 Jakub Jelinek <jakub@redhat.com>
24563
24564 * config/i386/i386.md (*x86_mov<mode>cc_0_m1): Use type "alu1" rather
24565 than "alu", remove explicit "memory" and "imm_disp" attributes.
24566 (*x86_mov<mode>cc_0_m1_se, *x86_mov<mode>cc_0_m1_neg): Likewise.
24567
24568 PR middle-end/85414
24569 * simplify-rtx.c (simplify_unary_operation_1) <case SIGN_EXTEND,
24570 case ZERO_EXTEND>: Pass SUBREG_REG (op) rather than op to
24571 gen_lowpart_no_emit.
24572
24573 2018-04-25 Sebastian Peryt <sebastian.peryt@intel.com>
24574
24575 PR target/85473
24576 * config/i386/i386.c (ix86_expand_builtin): Change memory
24577 operand to XI, extend p0 to Pmode.
24578 * config/i386/i386.md: Change unspec volatile and operand
24579 1 mode to XI, change operand 0 mode to P.
24580
24581 2018-04-25 Chung-Ju Wu <jasonwucj@gmail.com>
24582
24583 * config/nds32/nds32-predicates.c (nds32_can_use_bclr_p): Mask with
24584 GET_MODE_MASK before any checking.
24585 (nds32_can_use_bset_p): Likewise.
24586 (nds32_can_use_btgl_p): Likewise.
24587
24588 2018-04-25 Chung-Ju Wu <jasonwucj@gmail.com>
24589
24590 * config/nds32/nds32-doubleword.md: New define_split pattern for
24591 illegal register number.
24592
24593 2018-04-25 Chung-Ju Wu <jasonwucj@gmail.com>
24594
24595 * config/nds32/nds32.c (nds32_print_operand): Set op_value ealier.
24596
24597 2018-04-25 Chung-Ju Wu <jasonwucj@gmail.com>
24598
24599 * config/nds32/nds32.h (ASM_APP_ON): Add missing newline character.
24600
24601 2018-04-25 Richard Biener <rguenther@suse.de>
24602
24603 * lto-streamer.h (LTO_major_version): Bump to 8.
24604
24605 2018-04-25 Jakub Jelinek <jakub@redhat.com>
24606
24607 * BASE-VER: Set to 9.0.0.
24608
24609 2018-04-24 Segher Boessenkool <segher@kernel.crashing.org>
24610
24611 * config/rs6000/rs6000.c (init_float128_ieee): Fix spelling mistakes
24612 in __abskf2 and __powikf2.
24613
24614 2018-04-24 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
24615
24616 PR target/85512
24617 * config/aarch64/constraints.md (Usg, Usj): New constraints.
24618 * config/aarch64/iterators.md (cmode_simd): New mode attribute.
24619 * config/aarch64/aarch64.md (*aarch64_ashr_sisd_or_int_<mode>3):
24620 Use the above on operand 2. Reindent.
24621 (*aarch64_lshr_sisd_or_int_<mode>3): Likewise.
24622
24623 2018-04-24 H.J. Lu <hongjiu.lu@intel.com>
24624
24625 PR target/85485
24626 * common/config/i386/i386-common.c (ix86_handle_option): Don't
24627 handle OPT_mcet.
24628 * config/i386/i386.opt (mcet): Removed.
24629 * doc/install.texi: Remove -mcet documentation.
24630 * doc/invoke.texi: Likewise.
24631
24632 2018-04-24 H.J. Lu <hongjiu.lu@intel.com>
24633
24634 PR target/85485
24635 * doc/install.texi: Remove -mcet from bootstrap-cet.
24636
24637 2018-04-24 Jakub Jelinek <jakub@redhat.com>
24638
24639 PR target/85511
24640 * config/i386/i386.c (ix86_init_mmx_sse_builtins): Don't define
24641 __builtin_ia32_readeflags_u32 and __builtin_ia32_writeeflags_u32
24642 if TARGET_64BIT.
24643
24644 PR target/85503
24645 * config/rs6000/rs6000-p8swap.c (const_load_sequence_p): Punt if
24646 const_vector is not CONST_VECTOR or SYMBOL_REF for a constant pool
24647 containing a CONST_VECTOR.
24648
24649 2018-04-24 Cesar Philippidis <cesar@codesourcery.com>
24650
24651 * doc/install.texi: Update newlib dependency for nvptx.
24652
24653 2018-04-24 Jakub Jelinek <jakub@redhat.com>
24654
24655 PR target/85508
24656 * config/i386/i386.c (ix86_expand_vector_init_one_var): Use UINTVAL
24657 instead of INTVAL when shifting x left.
24658
24659 2018-04-24 Andreas Krebbel <krebbel@linux.ibm.com>
24660
24661 PR tree-optimization/85478
24662 * tree-vect-loop.c (vect_analyze_loop_2): Do not call
24663 vect_grouped_store_supported for single element vectors.
24664
24665 2018-04-24 Richard Biener <rguenther@suse.de>
24666
24667 PR target/85491
24668 * config/i386/i386.c (ix86_add_stmt_cost): Restrict strided
24669 load cost increase to the case of non-constant step.
24670
24671 2018-04-24 Jakub Jelinek <jakub@redhat.com>
24672
24673 PR target/84828
24674 * reg-stack.c (move_for_stack_reg): Don't fail assertion about dead
24675 destination if any_malformed_asm.
24676
24677 2018-04-23 Eric Botcazou <ebotcazou@adacore.com>
24678
24679 PR middle-end/85496
24680 * expr.c (store_field): In the bitfield case, if the value comes from
24681 a function call and is returned in registers by means of a PARALLEL,
24682 do not change the mode of the temporary unless BLKmode and VOIDmode.
24683
24684 2018-04-23 Andrey Belevantsev <abel@ispras.ru>
24685
24686 PR rtl-optimization/85423
24687 * sel-sched-ir.c (has_dependence_note_mem_dep): Only discard
24688 dependencies to debug insns when the previous insn is non-debug.
24689
24690 2018-04-23 Claudiu Zissulescu <claziss@synopsys.com>
24691
24692 * config/arc/arc.md ("vunspec"): Delete it, unify all the unspec
24693 enums into a single definition.
24694 (fls): Fix predicates and printing.
24695 (seti): Likewise.
24696
24697 2018-04-23 Claudiu Zissulescu <claziss@synopsys.com>
24698
24699 * config/arc/arc-protos.h (check_if_valid_sleep_operand): Remove.
24700 * config/arc/arc.c (arc_expand_builtin): Sleep accepts registers
24701 and short u6 immediate.
24702 (check_if_valid_sleep_operand): Remove.
24703 * config/arc/arc.md (Sleep): Accepts registers and u6 immediates.
24704
24705 2018-04-22 Chung-Ju Wu <jasonwucj@gmail.com>
24706
24707 * config/nds32/nds32.c (nds32_compute_stack_frame): Consider
24708 flag_always_save_lp condition.
24709 * config/nds32/nds32.opt (malways-save-lp): New option.
24710
24711 2018-04-22 Shiva Chen <shiva0217@gmail.com>
24712
24713 * config/nds32/nds32-protos.h (nds32_use_load_post_increment): Declare.
24714 * config/nds32/nds32.c (nds32_use_load_post_increment): New.
24715 * config/nds32/nds32.h
24716 (USE_LOAD_POST_INCREMENT, USE_LOAD_POST_DECREMENT): Define.
24717 (USE_STORE_POST_INCREMENT, USE_STORE_POST_DECREMENT): Define.
24718
24719 2018-04-22 Shiva Chen <shiva0217@gmail.com>
24720
24721 * config/nds32/nds32-protos.h (nds32_ls_333_p): Remove.
24722 * config/nds32/nds32.c (nds32_ls_333_p): Remove.
24723
24724 2018-04-22 Shiva Chen <shiva0217@gmail.com>
24725 Chung-Ju Wu <jasonwucj@gmail.com>
24726
24727 * config/nds32/nds32-protos.h (nds32_case_vector_shorten_mode):
24728 Declare.
24729 * config/nds32/nds32.c (nds32_case_vector_shorten_mode): New function.
24730 * config/nds32/nds32.h (CASE_VECTOR_SHORTEN_MODE): Modify.
24731
24732 2018-04-22 Chung-Ju Wu <jasonwucj@gmail.com>
24733
24734 * config/nds32/nds32.c (nds32_compute_stack_frame): Fix wrong value.
24735
24736 2018-04-22 Chung-Ju Wu <jasonwucj@gmail.com>
24737
24738 * config/nds32/nds32-protos.h (nds32_data_alignment,
24739 nds32_local_alignment): Declare.
24740 * config/nds32/nds32.c (nds32_data_alignment, nds32_constant_alignment,
24741 nds32_local_alignment): New functions.
24742 (TARGET_CONSTANT_ALIGNMENT): Define.
24743 * config/nds32/nds32.h (DATA_ALIGNMENT, LOCAL_ALIGNMENT): Define.
24744
24745 2018-04-22 Chung-Ju Wu <jasonwucj@gmail.com>
24746
24747 * config/nds32/nds32.c
24748 (TARGET_HARD_REGNO_MODE_OK): Move to the bottom of file.
24749 (TARGET_MODES_TIEABLE_P): Likewise.
24750
24751 2018-04-22 Chung-Ju Wu <jasonwucj@gmail.com>
24752
24753 * config/nds32/nds32.c (nds32_asm_file_start): Display optimization
24754 level Ofast and Og.
24755
24756 2018-04-22 Monk Chiang <sh.chiang04@gmail.com>
24757 Chung-Ju Wu <jasonwucj@gmail.com>
24758
24759 * config/nds32/constants.md (unspec_volatile_element): Add enum values
24760 for unaligned access.
24761 * config/nds32/nds32-intrinsic.c: Implementation of expanding
24762 unaligned access.
24763 * config/nds32/nds32-intrinsic.md: Likewise.
24764 * config/nds32/nds32_intrinsic.h: Likewise.
24765 * config/nds32/nds32.h (nds32_builtins): Likewise.
24766 * config/nds32/nds32.opt (munaligned-access): New option.
24767 * config/nds32/nds32.c (nds32_asm_file_start): Display
24768 flag_unaligned_access status.
24769
24770 2018-04-20 Kito Cheng <kito.cheng@gmail.com>
24771
24772 * config/riscv/elf.h (LINK_SPEC): Pass --no-relax if
24773 -mno-relax is present.
24774 * config/riscv/linux.h (LINK_SPEC): Ditto.
24775
24776 2018-04-20 Martin Sebor <msebor@redhat.com>
24777
24778 PR c/85365
24779 * gimple-fold.c (gimple_fold_builtin_strcpy): Suppress -Wrestrict
24780 for null pointers.
24781 (gimple_fold_builtin_stxcpy_chk): Same.
24782 * gimple-ssa-warn-restrict.c (check_bounds_or_overlap): Same.
24783
24784 2018-04-20 Michael Meissner <meissner@linux.ibm.com>
24785
24786 PR target/85456
24787 * config/rs6000/rs6000.c (init_float128_ieee): Add support to call
24788 __powikf2 when long double is IEEE 128-bit.
24789
24790 2018-04-20 Kito Cheng <kito.cheng@gmail.com>
24791
24792 * config/riscv/riscv.c (riscv_first_stack_step): Round up min
24793 step to make sure stack always aligned.
24794
24795 2018-04-20 Carl Love <cel@us.ibm.com>
24796
24797 PR target/83402
24798 * config/rs6000/rs6000-c.c (rs6000_gimple_fold_builtin): Add
24799 size check for arg0.
24800
24801 2018-04-20 Nathan Sidwell <nathan@codesourcery.com>
24802 Tom de Vries <tom@codesourcery.com>
24803
24804 PR target/85445
24805 * config/nvptx/nvptx.c (nvptx_emit_forking, nvptx_emit_joining):
24806 Emit insns for calls too.
24807 (nvptx_find_par): Always look for worker-level predecessor insn.
24808 (nvptx_propagate): Add is_call parm, return bool. Copy frame for
24809 calls.
24810 (nvptx_vpropagate, nvptx_wpropagate): Adjust.
24811 (nvptx_process_pars): Propagate frames for calls.
24812
24813 2018-04-20 H.J. Lu <hongjiu.lu@intel.com>
24814
24815 PR target/85469
24816 * common/config/i386/i386-common.c (OPTION_MASK_ISA_IBT_SET):
24817 Removed.
24818 (OPTION_MASK_ISA_IBT_UNSET): Likewise.
24819 (ix86_handle_option): Don't handle OPT_mibt.
24820 * config/i386/cet.h: Check __CET__ instead of __IBT__ and
24821 __SHSTK__.
24822 * config/i386/driver-i386.c (host_detect_local_cpu): Remove
24823 has_ibt and ibt.
24824 * config/i386/i386-c.c (ix86_target_macros_internal): Don't
24825 check OPTION_MASK_ISA_IBT nor flag_cf_protection.
24826 (ix86_target_macros): Define __CET__ with flag_cf_protection
24827 for -fcf-protection.
24828 * config/i386/i386.c (isa2_opts): Remove -mibt.
24829 * config/i386/i386.h (TARGET_IBT): Removed.
24830 (TARGET_IBT_P): Likewise.
24831 (ix86_valid_target_attribute_inner_p): Don't check OPT_mibt.
24832 * config/i386/i386.md (nop_endbr): Don't check TARGET_IBT.
24833 * config/i386/i386.opt (mcet): Update help message.
24834 (mshstk): Likewise.
24835 (mibt): Removed.
24836 * doc/invoke.texi: Remove -mibt. Document __CET__. Document
24837 -mcet as an alias for -mshstk.
24838
24839 2018-04-20 Richard Biener <rguenther@suse.de>
24840
24841 PR middle-end/85475
24842 * match.pd ((X * CST) * Y -> (X * Y) * CST): Avoid exponential
24843 complexity by forcing a single use of the multiply operand.
24844
24845 2018-04-20 Martin Jambor <mjambor@suse.cz>
24846
24847 ipa/85449
24848 * ipa-cp.c (cgraph_edge_brings_value_p): Move check for self-feeding
24849 recursion dependency to only apply to non-clones.
24850
24851 2018-04-20 Martin Jambor <mjambor@suse.cz>
24852
24853 ipa/85447
24854 * ipa-cp.c (create_specialized_node): Check that clones of
24855 self-recursive edges exist during IPA-CP.
24856
24857 2018-04-19 Toon Moene <toon@moene.org>
24858
24859 * doc/invoke.texi: Add -floop-unroll-and-jam to options enabled
24860 by -O3.
24861
24862 2018-04-19 Jakub Jelinek <jakub@redhat.com>
24863
24864 PR tree-optimization/85467
24865 * fold-const.c (fold_ternary_loc) <case BIT_FIELD_REF>: Use
24866 VECTOR_TYPE_P macro. If type is vector type, VIEW_CONVERT_EXPR the
24867 VECTOR_CST element to type.
24868
24869 2018-04-19 H.J. Lu <hongjiu.lu@intel.com>
24870
24871 PR target/85397
24872 * config/i386/i386.h (STACK_SAVEAREA_MODE): New.
24873 * config/i386/i386.md (builtin_setjmp_setup): Removed.
24874 (builtin_longjmp): Likewise.
24875 (save_stack_nonlocal): New pattern.
24876 (restore_stack_nonlocal): Likewise.
24877
24878 2018-04-19 H.J. Lu <hongjiu.lu@intel.com>
24879
24880 PR target/85404
24881 * config/i386/cet.c (file_end_indicate_exec_stack_and_cet):
24882 Replace ASM_OUTPUT_LABEL with fprintf.
24883
24884 2018-04-19 H.J. Lu <hongjiu.lu@intel.com>
24885
24886 PR target/85417
24887 * config/i386/cet.c (file_end_indicate_exec_stack_and_cet):
24888 Check flag_cf_protection instead of TARGET_IBT and TARGET_SHSTK.
24889 * config/i386/i386-c.c (ix86_target_macros_internal): Also
24890 define __IBT__ and __SHSTK__ for -fcf-protection.
24891 * config/i386/i386.c (pass_insert_endbranch::gate): Don't check
24892 TARGET_IBT.
24893 (ix86_trampoline_init): Likewise.
24894 (x86_output_mi_thunk): Likewise.
24895 (ix86_notrack_prefixed_insn_p): Likewise.
24896 (ix86_option_override_internal): Don't disallow -fcf-protection.
24897 * config/i386/i386.md (rdssp<mode>): Also enable for
24898 -fcf-protection.
24899 (incssp<mode>): Likewise.
24900 (nop_endbr): Likewise.
24901 * config/i386/i386.opt (mcet): Change help message to built-in
24902 functions only.
24903 (mibt): Likewise.
24904 (mshstk): Likewise.
24905 * doc/invoke.texi: Remove -mcet, -mibt and -mshstk condition
24906 on -fcf-protection. Change -mcet, -mibt and -mshstk to only
24907 enable CET built-in functions.
24908
24909 2018-04-19 Sebastian Peryt <sebastian.peryt@intel.com>
24910
24911 * common/config/i386/i386-common.c
24912 (OPTION_MASK_ISA_MOVDIRI_SET, OPTION_MASK_ISA_MOVDIR64B_SET,
24913 OPTION_MASK_ISA_MOVDIRI_UNSET,
24914 OPTION_MASK_ISA_MOVDIR64B_UNSET): New defines.
24915 (ix86_handle_option): Handle -mmovdiri and -mmovdir64b.
24916 * config.gcc (movdirintrin.h): New header.
24917 * config/i386/cpuid.h (bit_MOVDIRI,
24918 bit_MOVDIR64B): New bits.
24919 * config/i386/driver-i386.c (host_detect_local_cpu): Detect -mmovdiri
24920 and -mmvodir64b.
24921 * config/i386/i386-builtin-types.def ((VOID, PUNSIGNED, UNSIGNED),
24922 (VOID, PVOID, PCVOID)): New function types.
24923 * config/i386/i386-builtin.def (__builtin_ia32_directstoreu_u32,
24924 __builtin_ia32_directstoreu_u64,
24925 __builtin_ia32_movdir64b): New builtins.
24926 * config/i386/i386-c.c (__MOVDIRI__, __MOVDIR64B__): New.
24927 * config/i386/i386.c (ix86_target_string): Added -mmovdir64b
24928 and -mmovdiri.
24929 (ix86_valid_target_attribute_inner_p): Ditto.
24930 (ix86_expand_special_args_builtin): Added VOID_FTYPE_PUNSIGNED_UNSIGNED
24931 and VOID_FTYPE_PUNSIGNED_UNSIGNED.
24932 (ix86_expand_builtin): Expand IX86_BUILTIN_MOVDIR64B.
24933 * config/i386/i386.h (TARGET_MOVDIRI, TARGET_MOVDIRI_P,
24934 TARGET_MOVDIR64B, TARGET_MOVDIR64B_P): New.
24935 * config/i386/i386.md (UNSPECV_MOVDIRI, UNSPECV_MOVDIR64B): New.
24936 (movdiri<mode>, movdir64b_<mode>): New.
24937 * config/i386/i386.opt: Add -mmovdiri and -mmovdir64b.
24938 * config/i386/immintrin.h: Include movdirintrin.h.
24939 * config/i386/movdirintrin.h: New file.
24940 * doc/invoke.texi: Added -mmovdiri and -mmovdir64b.
24941
24942 2018-04-19 Richard Biener <rguenther@suse.de>
24943
24944 PR middle-end/85455
24945 * cfg.c (clear_bb_flags): When loop state says we have
24946 marked irreducible regions also preserve BB_IRREDUCIBLE_LOOP.
24947
24948 2018-04-19 Richard Biener <rguenther@suse.de>
24949
24950 PR tree-optimization/84737
24951 * tree-vect-data-refs.c (vect_copy_ref_info): New function
24952 copying restrict info.
24953 (vect_setup_realignment): Use it.
24954 * tree-vectorizer.h (vect_copy_ref_info): Declare.
24955 * tree-vect-stmts.c (vectorizable_store): Copy ref info from
24956 the first DR to all generated stores.
24957 (vectorizable_load): Likewise for loads.
24958
24959 2018-04-19 Jakub Jelinek <jakub@redhat.com>
24960
24961 PR tree-optimization/85446
24962 * match.pd ((intptr_t) x eq/ne CST to x eq/ne (typeof x) cst): Require
24963 the integral and pointer types to have the same precision.
24964
24965 * doc/install.texi: Document --disable-cet being the default and
24966 --enable-cet=auto.
24967
24968 2018-04-18 Martin Liska <mliska@suse.cz>
24969
24970 * ipa-devirt.c (odr_subtypes_equivalent_p): Fix GNU coding
24971 style.
24972
24973 2018-04-18 Martin Liska <mliska@suse.cz>
24974
24975 Revert
24976 2018-03-02 Eric Botcazou <ebotcazou@adacore.com>
24977
24978 PR ipa/83983
24979 * ipa-devirt.c (odr_subtypes_equivalent_p): Get the ODR type of both
24980 arguments if they are comparable.
24981
24982 2018-04-18 Martin Liska <mliska@suse.cz>
24983
24984 Revert
24985 2018-03-13 Eric Botcazou <ebotcazou@adacore.com>
24986
24987 PR lto/84805
24988 * ipa-devirt.c (odr_subtypes_equivalent_p): Do not get the ODR type of
24989 incomplete types.
24990
24991 2018-04-18 H.J. Lu <hongjiu.lu@intel.com>
24992
24993 PR target/85388
24994 * config/i386/i386.c (ix86_expand_split_stack_prologue): Insert
24995 ENDBR after calling __morestack.
24996
24997 2018-04-18 David Malcolm <dmalcolm@redhat.com>
24998
24999 PR jit/85384
25000 * configure.ac (gcc-driver-name.h): Honor --with-gcc-major-version
25001 by using gcc_base_ver to generate a gcc_driver_version, and use
25002 it when generating GCC_DRIVER_NAME.
25003 * configure: Regenerate.
25004
25005 2018-04-18 Jakub Jelinek <jakub@redhat.com>
25006
25007 PR target/81084
25008 * config.gcc: Obsolete powerpc*-*-*spe*.
25009
25010 2018-04-17 Jakub Jelinek <jakub@redhat.com>
25011
25012 PR debug/84637
25013 * dbxout.c (dbxout_int): Perform negation in unsigned int type.
25014 (stabstr_D): Change type of unum from unsigned int to
25015 unsigned HOST_WIDE_INT. Perform negation in unsigned HOST_WIDE_INT
25016 type.
25017
25018 2018-04-17 Jim Wilson <jimw@sifive.com>
25019
25020 PR 84856
25021 * config/riscv/riscv.c (riscv_compute_frame_info): Add calls to
25022 RISCV_STACK_ALIGN when using outgoing_args_size and pretend_args_size.
25023 Set arg_pointer_offset after using pretend_args_size.
25024
25025 2018-04-17 Jakub Jelinek <jakub@redhat.com>
25026
25027 PR rtl-optimization/85431
25028 * dse.c (record_store): Ignore zero width stores.
25029
25030 PR sanitizer/85230
25031 * asan.c (handle_builtin_stack_restore): Adjust comment. Emit
25032 __asan_allocas_unpoison call and last_alloca_addr = new_sp before
25033 __builtin_stack_restore rather than after it.
25034 * builtins.c (expand_asan_emit_allocas_unpoison): Pass
25035 arg1 + (virtual_dynamic_stack_rtx - stack_pointer_rtx) as second
25036 argument instead of virtual_dynamic_stack_rtx.
25037
25038 2018-04-17 Kelvin Nilsen <kelvin@gcc.gnu.org>
25039
25040 * config/rs6000/rs6000-protos.h (rs6000_builtin_is_supported_p):
25041 New prototype.
25042 * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin):
25043 Add note to error message to explain internal mapping of overloaded
25044 built-in function name to non-overloaded built-in function name.
25045 * config/rs6000/rs6000.c (rs6000_builtin_is_supported_p): New
25046 function.
25047
25048 2018-04-17 Michael Meissner <meissner@linux.vnet.ibm.com>
25049
25050 PR target/85424
25051 * config/rs6000/rs6000.md (pack<mode>): Do not try handle a pack
25052 where the inputs overlap with the output.
25053
25054 2018-04-17 Jakub Jelinek <jakub@redhat.com>
25055
25056 * config/i386/sse.md (vec_extract_lo_<mode><mask_name>): Add
25057 (=v, v) alternative and explicit "memory" attribute.
25058 (vec_extract_lo_<mode><mask_name>): Likewise. Also add
25059 "type", "prefix", "prefix_extra", "length_immediate" and "mode"
25060 attributes.
25061 (vec_extract_lo_<mode><mask_name>): Add (=v, v) alternative and use
25062 "sselog1" type instead of "sselog".
25063 (vec_extract_hi_<mode><mask_name>): Use "sselog1" type instead of
25064 "sselog". Remove explicit "memory" attribute.
25065 (vec_extract_lo_v32hi): Add (=v, v) alternative and explicit "memory",
25066 "type", "prefix", "prefix_extra", "length_immediate" and "mode"
25067 attributes.
25068 (vec_extract_hi_v32hi): Merge all alternatives into one, use
25069 "sselog1" type instead of "sselog". Remove explicit "memory"
25070 attribute.
25071 (vec_extract_hi_v16hi): Merge each pair of alternatives into one,
25072 use "sselog1" type instead of "sselog". Remove explicit "memory"
25073 attribute.
25074 (vec_extract_lo_v64qi): Add (=v, v) alternative and explicit "memory",
25075 "type", "prefix", "prefix_extra", "length_immediate" and "mode"
25076 attributes.
25077 (vec_extract_hi_v64qi): Merge all alternatives into one, use
25078 "sselog1" type instead of "sselog". Remove explicit "memory"
25079 attribute.
25080 (vec_extract_hi_v32qi): Merge each pair of alternatives into one,
25081 use "sselog1" type instead of "sselog". Remove explicit "memory"
25082 attribute.
25083
25084 PR target/85430
25085 * config/i386/i386.md (*ashlqi3_1_slp): Use alu1 type instead of alu.
25086
25087 PR middle-end/85414
25088 * rtlhooks.c (gen_lowpart_if_possible): Don't call gen_lowpart_SUBREG
25089 on a SUBREG.
25090
25091 2018-04-17 Martin Jambor <mjambor@suse.cz>
25092
25093 PR ipa/85421
25094 * ipa-cp.c (create_specialized_node): Call
25095 expand_all_artificial_thunks if necessary.
25096
25097 2018-04-17 Martin Liska <mliska@suse.cz>
25098
25099 PR lto/85405
25100 * ipa-devirt.c (odr_types_equivalent_p): Remove trailing
25101 in message, remote space in between '_G' and '('.
25102
25103 2018-04-17 Jakub Jelinek <jakub@redhat.com>
25104
25105 PR target/85281
25106 * config/i386/sse.md (reduces<mode><mask_scalar_name>,
25107 avx512f_vmcmp<mode>3<round_saeonly_name>,
25108 avx512f_vmcmp<mode>3_mask<round_saeonly_name>,
25109 avx512f_sgetexp<mode><mask_scalar_name><round_saeonly_scalar_name>,
25110 avx512f_rndscale<mode><round_saeonly_name>,
25111 avx512dq_ranges<mode><mask_scalar_name><round_saeonly_scalar_name>,
25112 avx512f_vgetmant<mode><mask_scalar_name><round_saeonly_scalar_name>):
25113 Use %<iptr>2 instead of %2 for -masm=intel.
25114 (avx512f_vcvtss2usi<round_name>, avx512f_vcvtss2usiq<round_name>,
25115 avx512f_vcvttss2usi<round_saeonly_name>,
25116 avx512f_vcvttss2usiq<round_saeonly_name>): Use %k1 instead of %1 for
25117 -masm=intel.
25118 (avx512f_vcvtsd2usi<round_name>, avx512f_vcvtsd2usiq<round_name>,
25119 avx512f_vcvttsd2usi<round_saeonly_name>,
25120 avx512f_vcvttsd2usiq<round_saeonly_name>, ufloatv2siv2df2<mask_name>):
25121 Use %q1 instead of %1 for -masm=intel.
25122 (avx512f_sfixupimm<mode><sd_maskz_name><round_saeonly_name>,
25123 avx512f_sfixupimm<mode>_mask<round_saeonly_name>): Use %<iptr>3 instead
25124 of %3 for -masm=intel.
25125 (sse2_shufpd_v2df_mask): Fix a typo, change %{6%} to %{%6%} for
25126 -masm=intel.
25127 (*avx512vl_<code>v2div2qi2_store): Use %w0 instead of %0 for
25128 -masm=intel.
25129 (*avx512vl_<code><mode>v4qi2_store): Use %k0 instead of %0 for
25130 -masm=intel.
25131 (avx512vl_<code><mode>v4qi2_mask_store): Use a single pattern with
25132 %k0 and %1 for -masm=intel rather than two patterns, one with %0 and
25133 %g1.
25134 (*avx512vl_<code><mode>v8qi2_store): Use %q0 instead of %0 for
25135 -masm=intel.
25136 (avx512vl_<code><mode>v8qi2_mask_store): Use a single pattern with
25137 %q0 and %1 for -masm=intel rather than two patterns, one with %0 and
25138 %g1 and one with %0 and %1.
25139 (avx512er_vmrcp28<mode><round_saeonly_name>,
25140 avx512er_vmrsqrt28<mode><round_saeonly_name>): Use %<iptr>1 instead of
25141 %1 for -masm=intel.
25142 (avx5124fmaddps_4fmaddps_mask, avx5124fmaddps_4fmaddss_mask,
25143 avx5124fmaddps_4fnmaddps_mask, avx5124fmaddps_4fnmaddss_mask,
25144 avx5124vnniw_vp4dpwssd_mask, avx5124vnniw_vp4dpwssds_mask): Swap order
25145 of %0 and %{%4%} for -masm=intel.
25146 (avx5124fmaddps_4fmaddps_maskz, avx5124fmaddps_4fmaddss_maskz,
25147 avx5124fmaddps_4fnmaddps_maskz, avx5124fmaddps_4fnmaddss_maskz,
25148 avx5124vnniw_vp4dpwssd_maskz, avx5124vnniw_vp4dpwssds_maskz): Swap
25149 order of %0 and %{%5%}%{z%} for -masm=intel.
25150
25151 2018-04-17 Jan Hubicka <jh@suse.cz>
25152
25153 PR lto/85405
25154 * ipa-devirt.c (odr_types_equivalent_p): Handle bit fields.
25155
25156 2018-04-17 Martin Liska <mliska@suse.cz>
25157
25158 PR ipa/85329
25159 * multiple_target.c (create_dispatcher_calls): Set apostrophes
25160 for target_clone error message. Make default implementation
25161 clone to be a local declaration.
25162 (separate_attrs): Add new argument and check for an empty
25163 string.
25164 (expand_target_clones): Handle it.
25165 (ipa_target_clone): Make redirection just for target_clones
25166 functions.
25167
25168 2018-04-16 Cesar Philippidis <cesar@codesourcery.com>
25169 Tom de Vries <tom@codesourcery.com>
25170
25171 PR middle-end/84955
25172 * omp-expand.c (expand_oacc_for): Add dummy false branch for
25173 tiled basic blocks without omp continue statements.
25174
25175 2018-04-16 Aaron Sawdey <acsawdey@linux.ibm.com>
25176
25177 PR target/83660
25178 * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin): Mark
25179 vec_extract expression as having side effects to make sure it gets
25180 a cleanup point.
25181
25182 2018-04-16 H.J. Lu <hongjiu.lu@intel.com>
25183
25184 PR target/85403
25185 * config/i386/i386.c (get_builtin_code_for_version): Check
25186 error_mark_node.
25187
25188 2018-04-16 Olga Makhotina <olga.makhotina@intel.com>
25189
25190 PR target/84331
25191 * config.gcc: Support "skylake".
25192 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
25193 PROCESSOR_SKYLAKE.
25194 * config/i386/i386.c (m_SKYLAKE): Define.
25195 (processor_target_table): Add "skylake".
25196 (ix86_option_override_internal): Add "skylake".
25197 (get_builtin_code_for_version): Handle PROCESSOR_SKYLAKE,
25198 PROCESSOR_CANNONLAKE.
25199 (get_builtin_code_for_version): Fix priority for
25200 PROCESSOR_ICELAKE_CLIENT, PROCESSOR_ICELAKE_SERVER,
25201 PROCESSOR_SKYLAKE-AVX512.
25202 * config/i386/i386.h (processor_costs): Define TARGET_SKYLAKE.
25203 (processor_type): Add PROCESSOR_SKYLAKE.
25204
25205 2018-04-16 Paolo Carlini <paolo.carlini@oracle.com>
25206 Jason Merrill <jason@redhat.com>
25207
25208 PR c++/85112
25209 * convert.c (convert_to_integer_1): Use direct recursion for
25210 enumeral types and types with a precision less than the number
25211 of bits in their mode.
25212
25213 2018-04-16 Julia Koval <julia.koval@intel.com>
25214
25215 PR target/84413
25216 * config/i386/x86-tune.def (X86_TUNE_SSE_UNALIGNED_LOAD_OPTIMAL,
25217 X86_TUNE_SSE_UNALIGNED_STORE_OPTIMAL): Add m_SKYLAKE_AVX512
25218
25219 2018-04-14 Segher Boessenkool <segher@kernel.crashing.org>
25220
25221 PR target/85293
25222 * config/rs6000/rs6000.opt (mdirect-move): Make deprecated.
25223 * doc/invoke.texi (RS/6000 and PowerPC Options): Remove -mdirect-move
25224 and -mno-direct-move.
25225
25226 2018-04-13 Paul A. Clarke <pc@us.ibm.com>
25227
25228 PR target/83402
25229 * config/rs6000/emmintrin.h (_mm_slli_epi{16,32,64}):
25230 Ensure that vec_splat_s32 is only called with 0 <= shift < 16.
25231 Ensure negative shifts result in {0}.
25232
25233 2018-04-13 Vladimir Makarov <vmakarov@redhat.com>
25234
25235 PR rtl-optimization/79916
25236 * config/rs6000/rs6000.c (rs6000_emit_move): Use assigned hard
25237 regs (if any) to define how to gnerate SD moves when LRA is in
25238 progress.
25239
25240 2018-04-13 Jakub Jelinek <jakub@redhat.com>
25241
25242 PR rtl-optimization/85393
25243 * except.h (expand_dw2_landing_pad_for_region): Remove declaration.
25244 * except.c (expand_dw2_landing_pad_for_region): Make static.
25245 * bb-reorder.c (fix_up_crossing_landing_pad): In new_bb emit just
25246 a label and unconditional jump to old_bb, rather than
25247 expand_dw2_landing_pad_for_region insn(s) and jump to single_succ
25248 basic block.
25249
25250 PR rtl-optimization/85376
25251 * simplify-rtx.c (simplify_const_unary_operation): For CLZ and CTZ and
25252 zero op0, if C?Z_DEFINED_VALUE_AT_ZERO is false, return NULL_RTX
25253 instead of a specific value.
25254
25255 2018-04-13 Jan Hubicka <hubicka@ucw.cz>
25256 Bin Cheng <bin.cheng@arm.com>
25257
25258 PR tree-optimization/82965
25259 PR tree-optimization/83991
25260 * cfgloopanal.c (expected_loop_iterations_unbounded): Add
25261 by_profile_only parameter.
25262 * cfgloopmanip.c (scale_loop_profile): Further scale loop's profile
25263 information if the loop was predicted to iterate too many times.
25264 * cfgloop.h (expected_loop_iterations_unbounded): Update prototype
25265
25266 2018-04-13 Jan Hubicka <hubicka@ucw.cz>
25267
25268 PR lto/71991
25269 * config/i386/i386.c (ix86_can_inline_p): Allow safe transitions for
25270 always inline.
25271
25272 2018-04-13 Martin Liska <mliska@suse.cz>
25273 Jakub Jelinek <jakub@redhat.com>
25274
25275 PR middle-end/81657
25276 * expr.h (enum block_op_methods): Add BLOCK_OP_NO_LIBCALL_RET.
25277 * expr.c (emit_block_move_hints): Handle BLOCK_OP_NO_LIBCALL_RET.
25278 * builtins.c (expand_builtin_memory_copy_args): Use
25279 BLOCK_OP_NO_LIBCALL_RET method for mempcpy with non-ignored target,
25280 handle dest_addr == pc_rtx.
25281
25282 2018-04-12 Segher Boessenkool <segher@kernel.crashing.org>
25283
25284 PR target/85291
25285 * config/rs6000/rs6000.md (fix_trunc<mode>si2): Use legacy code if
25286 asked to not generate direct moves.
25287 (fix_trunc<mode>si2_stfiwx): Similar.
25288 (fix_trunc<mode>si2_internal): Similar.
25289
25290 2018-04-12 Jakub Jelinek <jakub@redhat.com>
25291
25292 PR debug/83157
25293 * var-tracking.c (add_stores): Handle STRICT_LOW_PART SET_DEST.
25294 * cselib.c (cselib_record_sets): For STRICT_LOW_PART dest,
25295 lookup if dest in some wider mode is known to be const0_rtx and
25296 if so, record permanent equivalence for it to be ZERO_EXTEND of
25297 the narrower mode destination.
25298
25299 2018-04-12 Cesar Philippidis <cesar@codesourcery.com>
25300
25301 * lto-streamer-out.c (output_function): Revert 259346.
25302 * omp-expand.c (expand_oacc_for): Likewise.
25303
25304 2018-04-12 Alexander Monakov <amonakov@ispras.ru>
25305
25306 PR rtl-optimization/85354
25307 * sel-sched-ir.c (sel_init_pipelining): Move cfg_cleanup call...
25308 * sel-sched.c (sel_global_init): ... here.
25309
25310 2018-04-12 Eric Botcazou <ebotcazou@adacore.com>
25311
25312 PR target/85238
25313 * lto-wrapper.c (debug_objcopy): Open the files in binary mode.
25314 * dwarf2out.c (dwarf2out_early_finish): Do not generate assembly in LTO
25315 mode for PE-COFF targets.
25316 * config/i386/i386-protos.h (i386_pe_asm_lto_start): Declare.
25317 (i386_pe_asm_lto_end): Likewise.
25318 * config/i386/cygming.h (TARGET_ASM_LTO_START): Define.
25319 (TARGET_ASM_LTO_END): Likewise.
25320 * config/i386/winnt.c (saved_debug_info_level): New static variable.
25321 (i386_pe_asm_lto_start): New function.
25322 (i386_pe_asm_lto_end): Likewise.
25323
25324 2018-04-12 Cesar Philippidis <cesar@codesourcery.com>
25325 Richard Biener <rguenther@suse.de>
25326
25327 PR middle-end/84955
25328 * lto-streamer-out.c (output_function): Fix CFG loop state before
25329 streaming out.
25330 * omp-expand.c (expand_oacc_for): Handle calls to internal
25331 functions like regular functions.
25332
25333 2018-04-12 Richard Biener <rguenther@suse.de>
25334
25335 PR lto/85371
25336 * dwarf2out.c (init_sections_and_labels): Use debug_line_section[_label]
25337 for the early LTO debug to properly generate references to it
25338 during DIE emission. Do not re-use that for the skeleton for
25339 split-dwarf.
25340 (dwarf2out_early_finish): Likewise.
25341
25342 2018-04-12 Jakub Jelinek <jakub@redhat.com>
25343
25344 PR target/85328
25345 * config/i386/sse.md
25346 (<mask_codefor>avx512dq_vextract<shuffletype>64x2_1<mask_name> split,
25347 <mask_codefor>avx512f_vextract<shuffletype>32x4_1<mask_name> split,
25348 vec_extract_lo_<mode><mask_name> split, vec_extract_lo_v32hi,
25349 vec_extract_lo_v64qi): For non-AVX512VL if input is xmm16+ reg
25350 and output is a reg, avoid creating invalid lowpart subreg, but
25351 instead split into a 512-bit move. Don't split if not AVX512VL,
25352 input is xmm16+ reg and output is a mem.
25353 (vec_extract_lo_<mode><mask_name>, vec_extract_lo_v32hi,
25354 vec_extract_lo_v64qi): Don't require split if not AVX512VL, input is
25355 xmm16+ reg and output is a mem.
25356
25357 2018-04-12 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
25358
25359 * config/s390/s390.c (s390_output_indirect_thunk_function): Check
25360 also for flag_dwarf2_cfi_asm.
25361
25362 2018-04-12 Jakub Jelinek <jakub@redhat.com>
25363
25364 PR rtl-optimization/85342
25365 * regcprop.c (copyprop_hardreg_forward_1): Remove replaced array, use
25366 a bool scalar var inside of the loop instead. Don't try to update
25367 recog_data.operand after failed apply_change_group.
25368
25369 2018-04-12 Tom de Vries <tom@codesourcery.com>
25370
25371 PR target/85296
25372 * config/nvptx/nvptx.c (flexible_array_member_type_p): New function.
25373 (nvptx_assemble_decl_begin): Add undefined param. Declare undefined
25374 array with flexible array member as array without given dimension.
25375 (nvptx_assemble_undefined_decl): Set nvptx_assemble_decl_begin call
25376 argument for undefined param to true.
25377
25378 2018-04-11 Aaron Sawdey <acsawdey@linux.ibm.com>
25379
25380 PR target/85321
25381 * doc/invoke.texi (RS/6000 and PowerPC Options): Document options
25382 -mcall- and -mtraceback=. Remove options -mabi=spe and -mabi=no-spe
25383 from PowerPC section.
25384 * config/rs6000/sysv4.opt (mcall-): Improve help text.
25385 * config/rs6000/rs6000.opt (mblock-compare-inline-limit=): Trim
25386 help text that is too long.
25387 * config/rs6000/rs6000.opt (mblock-compare-inline-loop-limit=): Trim
25388 help text that is too long.
25389 * config/rs6000/rs6000.opt (mstring-compare-inline-limit=): Trim
25390 help text that is too long.
25391
25392 2018-04-11 Uros Bizjak <ubizjak@gmail.com>
25393
25394 * config/alpha/alpha.md (stack_probe_internal): Rename
25395 from "probe_stack". Update all callers.
25396
25397 2018-04-11 Alexander Monakov <amonakov@ispras.ru>
25398
25399 PR rtl-optimization/84566
25400 * sched-deps.c (sched_analyze_insn): Check deps->readonly when invoking
25401 sched_macro_fuse_insns.
25402
25403 2018-04-11 Alexander Monakov <amonakov@ispras.ru>
25404
25405 PR target/84301
25406 * sched-rgn.c (add_branch_dependences): Move sel_sched_p check here...
25407 (compute_block_dependences): ... from here.
25408
25409 2018-04-11 Jakub Jelinek <jakub@redhat.com>
25410
25411 PR tree-optimization/85331
25412 * vec-perm-indices.h (vec_perm_indices::clamp): Change input type
25413 from int to HOST_WIDE_INT.
25414
25415 2018-04-11 Martin Jambor <mjambor@suse.cz>
25416
25417 PR ipa/84149
25418 * ipa-cp.c (propagate_vals_across_pass_through): Expand comment.
25419 (cgraph_edge_brings_value_p): New parameter dest_val, check if it is
25420 not the same as the source val.
25421 (cgraph_edge_brings_value_p): New parameter.
25422 (gather_edges_for_value): Pass destination value to
25423 cgraph_edge_brings_value_p.
25424 (perhaps_add_new_callers): Likewise.
25425 (get_info_about_necessary_edges): Likewise and exclude values brought
25426 only by self-recursive edges.
25427 (create_specialized_node): Redirect only clones of self-calling edges.
25428 (+self_recursive_pass_through_p): New function.
25429 (find_more_scalar_values_for_callers_subset): Use it.
25430 (find_aggregate_values_for_callers_subset): Likewise.
25431 (known_aggs_to_agg_replacement_list): Removed.
25432 (decide_whether_version_node): Re-calculate known constants for all
25433 remaining context clones.
25434
25435 2018-04-11 Richard Biener <rguenther@suse.de>
25436
25437 PR lto/85339
25438 * dwarf2out.c (dwarf2out_finish): Remove DW_AT_stmt_list attribute
25439 from early DWARF output.
25440 (dwarf2out_early_finish): Output line info unconditionally into
25441 early DWARF and add reference to it.
25442
25443 2018-04-11 Jakub Jelinek <jakub@redhat.com>
25444
25445 PR target/85281
25446 * config/i386/sse.md (iptr): Add V16SFmode and V8DFmode cases.
25447 (<avx512>_vec_dup<mode><mask_name>): Use a single pattern for modes
25448 other than V2DFmode using iptr mode attribute.
25449 (<avx512>_vec_dup<mode><mask_name>): Use iptr mode attribute.
25450
25451 2018-04-11 Alexander Monakov <amonakov@ispras.ru>
25452
25453 PR rtl-optimization/84659
25454 * sel-sched-ir.c (sel_init_pipelining): Invoke cleanup_cfg.
25455
25456 2018-04-11 Jakub Jelinek <jakub@redhat.com>
25457
25458 PR debug/85302
25459 * dwarf2out.c (skip_loc_list_entry): Don't call size_of_locs if
25460 SIZEP is NULL.
25461 (output_loc_list): Pass address of a dummy size variable even in the
25462 locview handling loop.
25463 (index_location_lists): Add comment on why skip_loc_list_entry can't
25464 call size_of_locs.
25465
25466 2018-04-11 Thomas Preud'homme <thomas.preudhomme@arm.com>
25467
25468 PR target/85261
25469 * config/arm/arm-builtins.c (arm_expand_builtin): Force input operand
25470 into register.
25471
25472 2018-04-10 Aaron Sawdey <acsawdey@linux.ibm.com>
25473
25474 PR target/85321
25475 * doc/invoke.texi (RS/6000 and PowerPC Options): Document options
25476 -mblock-compare-inline-limit, -mblock-compare-inline-loop-limit,
25477 and -mstring-compare-inline-limit.
25478
25479 2018-04-10 Segher Boessenkool <segher@kernel.crashing.org>
25480
25481 PR target/85287
25482 * config/rs6000/rs6000.md (allocate_stack): Put the residual size
25483 for stack clash protection in a register whenever we need it to be in
25484 a register.
25485
25486 2018-04-10 Segher Boessenkool <segher@kernel.crashing.org>
25487
25488 * common/config/rs6000/rs6000-common.c (rs6000_option_init_struct):
25489 Enable -fasynchronous-unwind-tables by default if OBJECT_FORMAT_ELF.
25490
25491 2018-04-10 Segher Boessenkool <segher@kernel.crashing.org>
25492
25493 PR target/85321
25494 * config/rs6000/rs6000.opt (mtraceback=): Show the allowed values in
25495 the help text.
25496 (mlong-double-): Ditto.
25497 * config/rs6000/sysv4.opt (msdata=): Ditto.
25498 (mtls-size=): Ditto.
25499
25500 2018-04-10 Kelvin Nilsen <kelvin@gcc.gnu.org>
25501
25502 * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Remove
25503 erroneous entries for
25504 "vector int vec_ldl (int, long int *)", and
25505 "vector unsigned int vec_ldl (int, unsigned long int *)".
25506 Add comments and entries for
25507 "vector bool char vec_ldl (int, bool char *)",
25508 "vector bool short vec_ldl (int, bool short *)",
25509 "vector bool int vec_ldl (int, bool int *)",
25510 "vector bool long long vec_ldl (int, bool long long *)",
25511 "vector pixel vec_ldl (int, pixel *)",
25512 "vector long long vec_ldl (int, long long *)",
25513 "vector unsigned long long vec_ldl (int, unsigned long long *)".
25514 * config/rs6000/rs6000.c (rs6000_init_builtins): Initialize new
25515 type tree bool_long_long_type_node and correct definition of
25516 bool_V2DI_type_node to make reference to this new type tree.
25517 (rs6000_mangle_type): Replace erroneous reference to
25518 bool_long_type_node with bool_long_long_type_node.
25519 * config/rs6000/rs6000.h (enum rs6000_builtin_type_index): Add
25520 comments to emphasize sign distinctions for char and int types and
25521 replace RS6000_BTI_bool_long constant with
25522 RS6000_BTI_bool_long_long constant. Also add comment to restrict
25523 use of RS6000_BTI_pixel.
25524 (bool_long_type_node): Remove this macro definition.
25525 (bool_long_long_type_node): New macro definition
25526
25527 2018-04-10 Jakub Jelinek <jakub@redhat.com>
25528
25529 PR rtl-optimization/85300
25530 * combine.c (subst): Handle subst of CONST_SCALAR_INT_P new_rtx also
25531 into FLOAT and UNSIGNED_FLOAT like ZERO_EXTEND, return a CLOBBER if
25532 simplify_unary_operation fails.
25533
25534 2018-04-10 Martin Liska <mliska@suse.cz>
25535
25536 * gdbhooks.py: Add pretty-printers for varpool_node, symtab_node,
25537 cgraph_edge and ipa_ref.
25538
25539 2018-04-10 Jakub Jelinek <jakub@redhat.com>
25540
25541 PR target/85177
25542 PR target/85255
25543 * config/i386/sse.md
25544 (<extract_type>_vinsert<shuffletype><extract_suf>_mask): Fix
25545 computation of the VEC_MERGE selector from mask.
25546 (<extract_type>_vinsert<shuffletype><extract_suf>_1<mask_name>):
25547 Fix decoding of the VEC_MERGE selector into mask.
25548
25549 2018-04-10 Richard Sandiford <richard.sandiford@linaro.org>
25550
25551 PR tree-optimization/85286
25552 * tree-vect-data-refs.c (vect_get_smallest_scalar_type):
25553
25554 2018-04-10 Richard Sandiford <richard.sandiford@linaro.org>
25555
25556 * final.c (final_1): Set insn_last_address as well as
25557 insn_current_address.
25558
25559 2018-04-10 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
25560
25561 PR target/85173
25562 * explow.c (emit_stack_probe): Call validize_mem on memory location
25563 before passing it to gen_probe_stack. Create address operand and
25564 legitimize it for the probe_stack_address case.
25565
25566 2018-04-09 Jan Hubicka <jh@suse.cz>
25567
25568 PR lto/85078
25569 * ipa-devirt.c (rebuild_type_inheritance-hash): New.
25570 * ipa-utils.h (rebuild_type_inheritance-hash): Declare.
25571 * tree.c (free_lang_data_in_type): Fix handling of binfos;
25572 walk basetypes.
25573 (free_lang_data): Rebuild type inheritance graph.
25574
25575 2018-04-09 Martin Sebor <msebor@redhat.com>
25576
25577 * invoke.texi (-finline-small-functions): Mention other optimization
25578 options.
25579 (-findirect-inlining, -fpartial-inlining): Same.
25580 (-finline-functions-called-once): Same.
25581 (-freorder-blocks-and-partition): Same.
25582
25583 2018-04-09 Jan Hubicka <jh@suse.cz>
25584
25585 PR rtl/84058
25586 * cfgcleanup.c (try_forward_edges): Do not give up on crossing
25587 jumps; choose last target that matches the criteria (i.e.
25588 no partition changes for non-crossing jumps).
25589 * cfgrtl.c (cfg_layout_redirect_edge_and_branch): Add basic
25590 support for redirecting crossing jumps to non-crossing.
25591
25592 2018-04-09 Alexey Brodkin <abrodkin@synopsys.com>
25593
25594 * config/arc/arc.c (arc_expand_prologue): Set stack usage info
25595 also for naked functions.
25596
25597 2018-04-09 Claudiu Zissulescu <claziss@synopsys.com>
25598
25599 * config/arc/arc.md (add_shift): New pattern.
25600 (add_shift2): Likewise.
25601 (sub_shift): Likewise.
25602 (sub_shift_cmp0_noout): Likewise.
25603 (compare_si_ashiftsi): Likewise.
25604 (xbfu_cmp0_noout): New combine pattern.
25605 (xbfu_cmp0"): Likewise.
25606 (movsi_set_cc_insn): Place the predicable variant first.
25607 (commutative_binary_cmp0_noout): Remove clobber.
25608 (commutative_binary_cmp0): New pattern.
25609 (noncommutative_binary_cmp0): Likewise.
25610 (noncommutative_binary_cmp0_noout): Likewise.
25611 (noncommutative_binary_comparison_result_used): Removed.
25612 (rsub_cmp0): New pattern.
25613 (rsub_cmp0_noout): Likewise.
25614 (extzvsi): Changed, keep only meaningful variants.
25615 (SQH, SEZ): New iterators.
25616 (SQH_postfix): New mode attribute.
25617 (SEZ_prefix): New code attribute.
25618 (<SEZ_prefix>xt<SQH_postfix>_cmp0_noout): New instruction pattern.
25619 (<SEZ_prefix>xt<SQH_postfix>_cmp0): Likewise.
25620 * config/arc/predicates.md (cc_set_register): Use CC_REG instead
25621 of numerical value.
25622 (noncommutative_operator): Check the availability of barrel
25623 shifter option.
25624
25625 2018-04-09 Richard Biener <rguenther@suse.de>
25626
25627 PR tree-optimization/85284
25628 * tree-ssa-loop-niter.c (number_of_iterations_exit_assumptions):
25629 Only use the niter constraining form of simple_iv when the exit
25630 is always executed.
25631
25632 2018-04-09 Tom de Vries <tom@codesourcery.com>
25633
25634 PR target/84041
25635 * config/nvptx/nvptx.md (define_c_enum "unspecv"): Add UNSPECV_MEMBAR.
25636 (define_expand "*memory_barrier"): New define_expand.
25637 (define_insn "memory_barrier"): New insn.
25638
25639 2018-04-09 Andrey Belevantsev <abel@ispras.ru>
25640
25641 PR rtl-optimization/80463
25642 PR rtl-optimization/83972
25643 PR rtl-optimization/83480
25644
25645 * sel-sched-ir.c (has_dependence_note_mem_dep): Take into account the
25646 correct producer for the insn.
25647 (tidy_control_flow): Fixup seqnos in case of debug insns.
25648
25649 2018-04-09 Andrey Belevantsev <abel@ispras.ru>
25650
25651 PR rtl-optimization/83913
25652
25653 * sel-sched-ir.c (merge_expr_data): Choose the middle between two
25654 different sched-times when merging exprs.
25655
25656 2018-04-09 Andrey Belevantsev <abel@ispras.ru>
25657
25658 PR rtl-optimization/83962
25659
25660 * sel-sched-ir.c (tidy_control_flow): Correct the order in which we call
25661 tidy_fallthru_edge and tidy_control_flow.
25662
25663 2018-04-09 Andrey Belevantsev <abel@ispras.ru>
25664
25665 PR rtl-optimization/83530
25666
25667 * sel-sched.c (force_next_insn): New global variable.
25668 (remove_insn_for_debug): When force_next_insn is true, also leave only
25669 next insn in the ready list.
25670 (sel_sched_region): When the region wasn't scheduled, make another pass
25671 over it with force_next_insn set to 1.
25672
25673 2018-04-08 Monk Chiang <sh.chiang04@gmail.com>
25674
25675 * config.gcc (nds32le-*-*, nds32be-*-*): Add nds32/nds32_intrinsic.h
25676 into tm_file.
25677 * config/nds32/constants.md (unspec_volatile_element): Add enum values
25678 for interrupt control.
25679 * config/nds32/nds32-intrinsic.c: Implementation of intrinsic
25680 functions for interrupt control.
25681 * config/nds32/nds32-intrinsic.md: Likewise.
25682 * config/nds32/nds32_intrinsic.h: Likewise.
25683 * config/nds32/nds32.h (nds32_builtins): Likewise.
25684
25685 2018-04-08 Chung-Ju Wu <jasonwucj@gmail.com>
25686
25687 * config/nds32/nds32.c (nds32_init_machine_status,
25688 nds32_legitimate_index_p, nds32_legitimate_address_p): Consider
25689 strict_aligned_p field.
25690 (nds32_expand_to_rtl_hook): New function.
25691 (TARGET_EXPAND_TO_RTL_HOOK): Define.
25692 * config/nds32/nds32.h (machine_function): Add strict_aligned_p field.
25693
25694 2018-04-08 Kito Cheng <kito.cheng@gmail.com>
25695 Chung-Ju Wu <jasonwucj@gmail.com>
25696
25697 * config.gcc (nds32*-*-*): Check that n7 is valid to --with-cpu.
25698 * config/nds32/nds32-n7.md: New file.
25699 * config/nds32/nds32-opts.h (nds32_cpu_type): Add CPU_N7.
25700 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n7
25701 pipeline.
25702 * config/nds32/nds32-protos.h: More declarations for n7 pipeline.
25703 * config/nds32/nds32.md (pipeline_model): Add n7.
25704 * config/nds32/nds32.opt (mcpu): Support n7 pipeline cpus.
25705 * config/nds32/pipelines.md: Include n7 settings.
25706
25707 2018-04-08 Kito Cheng <kito.cheng@gmail.com>
25708 Chung-Ju Wu <jasonwucj@gmail.com>
25709
25710 * config.gcc (nds32*-*-*): Check that e8 is valid to --with-cpu.
25711 * config/nds32/nds32-e8.md: New file.
25712 * config/nds32/nds32-opts.h (nds32-cpu_type): Add CPU_E8.
25713 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for e8
25714 pipeline.
25715 * config/nds32/nds32-protos.h: More declarations for e8 pipeline.
25716 * config/nds32/nds32.md (pipeline_model): Add e8.
25717 * config/nds32/nds32.opt (mcpu): Support e8 pipeline cpus.
25718 * config/nds32/pipelines.md: Include e8 settings.
25719
25720 2018-04-08 Kito Cheng <kito.cheng@gmail.com>
25721 Chung-Ju Wu <jasonwucj@gmail.com>
25722
25723 * config.gcc (nds32*-*-*): Check that n6/n8/s8 are valid to --with-cpu.
25724 * config/nds32/nds32-n8.md: New file.
25725 * config/nds32/nds32-opts.h (nds32_cpu_type): Add CPU_N6 and CPU_N8.
25726 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n8
25727 pipeline.
25728 * config/nds32/nds32-protos.h: More declarations for n8 pipeline.
25729 * config/nds32/nds32-utils.c: More implementations for n8 pipeline.
25730 * config/nds32/nds32.md (pipeline_model): Add n8.
25731 * config/nds32/nds32.opt (mcpu): Support n8 pipeline cpus.
25732 * config/nds32/pipelines.md: Include n8 settings.
25733
25734 2018-04-08 Kito Cheng <kito.cheng@gmail.com>
25735 Chung-Ju Wu <jasonwucj@gmail.com>
25736
25737 * config.gcc (nds32*): Add nds32-utils.o into extra_objs.
25738 * config/nds32/nds32-n9-2r1w.md: New file.
25739 * config/nds32/nds32-n9-3r2w.md: New file.
25740 * config/nds32/nds32-opts.h (nds32_cpu_type, nds32_mul_type,
25741 nds32_register_ports): New or modify for cpu n9.
25742 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n9
25743 pipeline.
25744 * config/nds32/nds32-protos.h: More declarations for n9 pipeline.
25745 * config/nds32/nds32-utils.c: New file.
25746 * config/nds32/nds32.h (TARGET_PIPELINE_N9, TARGET_PIPELINE_SIMPLE,
25747 TARGET_MUL_SLOW): Define.
25748 * config/nds32/nds32.md (pipeline_model): New attribute.
25749 * config/nds32/nds32.opt (mcpu, mconfig-mul, mconfig-register-ports):
25750 New options that support cpu n9.
25751 * config/nds32/pipelines.md: Include n9 settings.
25752 * config/nds32/t-nds32 (nds32-utils.o): Add dependency.
25753
25754 2018-04-08 Chung-Ju Wu <jasonwucj@gmail.com>
25755
25756 * config/nds32/nds32-md-auxiliary.c (output_cond_branch): Output align
25757 information if necessary.
25758 (output_cond_branch_compare_zero): Likewise.
25759 * config/nds32/nds32.c (nds32_adjust_insn_length): Consider align case.
25760 (nds32_target_alignment): Refine for alignment.
25761 * config/nds32/nds32.h (NDS32_ALIGN_P): Define.
25762 (FUNCTION_BOUNDARY): Modify.
25763 * config/nds32/nds32.md (call_internal, call_value_internal): Consider
25764 align case.
25765 * config/nds32/nds32.opt (malways-align, malign-functions): New.
25766
25767 2018-04-08 Monk Chiang <sh.chiang04@gmail.com>
25768
25769 * config/nds32/constants.md (unspec_volatile_element): Add values for
25770 TLB operation and data prefetch.
25771 * config/nds32/nds32-intrinsic.c: Implementation of intrinsic
25772 functions for TLB operation and data prefetch.
25773 * config/nds32/nds32-intrinsic.md: Likewise.
25774 * config/nds32/nds32_intrinsic.h: Likewise.
25775 * config/nds32/nds32.c (nds32_dpref_names): Likewise.
25776 (nds32_print_operand): Likewise.
25777 * config/nds32/nds32.h (nds32_builtins): Likewise.
25778
25779 2018-04-07 Thomas Koenig <tkoenig@gcc.gnu.org>
25780 Andrew Pinski <pinsika@gcc.gnu.org>
25781
25782 PR middle-end/82976
25783 * match.pd: Use constant_boolean_node of correct type instead of
25784 boolean_true_node or boolean_false_node for simplifying
25785 pointer comparisons to zero.
25786
25787 2018-04-07 Jakub Jelinek <jakub@redhat.com>
25788
25789 PR tree-optimization/80021
25790 * tree.c (verify_type_variant): Make error call in verify_variant_match
25791 translatable and remove final full stop.
25792
25793 2018-04-07 Chung-Ju Wu <jasonwucj@gmail.com>
25794
25795 * config/nds32/constants.md (unspec_volatile_element): Add
25796 UNSPEC_VOLATILE_EH_RETURN.
25797 * config/nds32/nds32-md-auxiliary.c (nds32_output_stack_push,
25798 nds32_output_stack_pop): Support dwarf exception handling process.
25799 * config/nds32/nds32-protos.h (nds32_dynamic_chain_address): Declare.
25800 * config/nds32/nds32.c (nds32_init_machine_status): Support dwarf
25801 exception handling process.
25802 (nds32_compute_stack_frame): Likewise.
25803 (nds32_return_addr_rtx): Likewise.
25804 (nds32_initial_elimination_offset): Likewise.
25805 (nds32_expand_prologue): Likewise.
25806 (nds32_expand_epilogue): Likewise.
25807 (nds32_dynamic_chain_address): New function.
25808 * config/nds32/nds32.h (machine_function): Add fields for dwarf
25809 exception handling.
25810 (DYNAMIC_CHAIN_ADDRESS): Define.
25811 (EH_RETURN_DATA_REGNO): Define.
25812 (EH_RETURN_STACKADJ_RTX): Define.
25813 * config/nds32/nds32.md (eh_return, nds32_eh_return): Implement
25814 patterns for dwarf exception handling.
25815
25816 2018-04-07 Chung-Ju Wu <jasonwucj@gmail.com>
25817
25818 * config/nds32/nds32.h: Clean up obsolete macros.
25819
25820 2018-04-07 Monk Chiang <sh.chiang04@gmail.com>
25821
25822 * config/nds32/constants.md (unspec_element, unspec_volatile_element):
25823 Add enum values for particular instructions.
25824 * config/nds32/nds32-intrinsic.c: Implementation of expanding
25825 particular intrinsic functions.
25826 * config/nds32/nds32-intrinsic.md: Likewise.
25827 * config/nds32/nds32_intrinsic.h: Likewise.
25828 * config/nds32/nds32.h (nds32_builtins): Likewise.
25829 * config/nds32/nds32.md (type): Add pbsad and pbsada.
25830 (btst, ave): New patterns for particular instructions.
25831
25832 2018-04-07 Monk Chiang <sh.chiang04@gmail.com>
25833
25834 * config/nds32/constants.md (unspec_element, unspec_volatile_element):
25835 Add enum values for atomic load/store and memory sync.
25836 * config/nds32/nds32-intrinsic.c: Implementation for atomic load/store
25837 and memory sync.
25838 * config/nds32/nds32-intrinsic.md: Likewise.
25839 * config/nds32/nds32_intrinsic.h: Likewise.
25840 * config/nds32/nds32.h (nds32_builtins): Likewise.
25841
25842 2018-04-07 Jakub Jelinek <jakub@redhat.com>
25843
25844 PR tree-optimization/85257
25845 * fold-const.c (native_encode_vector): If not all elts could fit
25846 and off is -1, return 0 rather than offset.
25847 * tree-ssa-sccvn.c (vn_reference_lookup_3): Pass
25848 (offseti - offset2) / BITS_PER_UNIT as 4th argument to
25849 native_encode_expr. Verify len * BITS_PER_UNIT >= maxsizei. Don't
25850 adjust buffer in native_interpret_expr call.
25851
25852 2018-04-07 Monk Chiang <sh.chiang04@gmail.com>
25853
25854 * config/nds32/constants.md (unspec_volatile_element): Add cache
25855 control enum values.
25856 * config/nds32/nds32-intrinsic.c: Add cache control expand functions.
25857 * config/nds32/nds32-intrinsic.md: Add cache control patterns.
25858 * config/nds32/nds32.c (nds32_cctl_names): New.
25859 (nds32_print_operand): Handle cache control register names.
25860 * config/nds32/nds32.h (nds32_builtins): New enum values.
25861 * config/nds32/nds32_intrinsic.h: Add cache control enum types and
25862 macros.
25863 * config/nds32/nds32.md (type): Add mmu.
25864 * config/nds32/pipelines.md (simple_insn): Add mmu.
25865
25866 2018-04-07 Chung-Ju Wu <jasonwucj@gmail.com>
25867
25868 * config/nds32/nds32.md (type): Remove call.
25869 * config/nds32/pipelines.md (simple_insn): Likewise.
25870
25871 2018-04-07 Monk Chiang <sh.chiang04@gmail.com>
25872
25873 * config/nds32/constants.md (unspec_volatile_element): Add
25874 UNSPEC_VOLATILE_FMFCSR, UNSPEC_VOLATILE_FMTCSR and
25875 UNSPEC_VOLATILE_FMFCFG.
25876 * config/nds32/nds32-intrinsic.c (bdesc_noarg): New builtin
25877 description for fmfcfg and fmfcsr.
25878 (bdesc_1arg): Add fmtcsr.
25879 (bdesc_2arg): Add fcpynss, fcpyss, fcpynsd and fcpysd.
25880 (nds32_expand_builtin_impl): Deal with FPU intrinsic functions.
25881 * config/nds32/nds32-intrinsic.md (unspec_fcpynsd, unspec_fcpysd,
25882 unspec_fcpynss, unspec_fcpysd, unspec_fcpyss, unspec_fmfcsr,
25883 unspec_fmfcfg): New patterns.
25884 * config/nds32/nds32.h (nds32_builtins): Add NDS32_BUILTIN_FMFCFG,
25885 NDS32_BUILTIN_FMFCSR, NDS32_BUILTIN_FMTCSR, NDS32_BUILTIN_FCPYNSS,
25886 NDS32_BUILTIN_FCPYSS,NDS32_BUILTIN_FCPYNSD and NDS32_BUILTIN_FCPYSD.
25887 * config/nds32/nds32_intrinsic.h (__nds32__fcpynsd, __nds32__fcpynss,
25888 __nds32__fcpysd, __nds32__fcpyss, __nds32__fmfcsr, __nds32__fmtcsr,
25889 __nds32__fmfcfg): Define.
25890
25891 2018-04-07 Monk Chiang <sh.chiang04@gmail.com>
25892
25893 * config/nds32/nds32.c (nds32_intrinsic_register_names): Add more
25894 intrinsic register names.
25895 * config/nds32/nds32_intrinsic.h (nds32_intrinsic_registers): Add more
25896 intrinsic register enum values and macros.
25897
25898 2018-04-07 Chung-Ju Wu <jasonwucj@gmail.com>
25899
25900 * config/nds32/nds32.c (nds32_legitimate_index_p): Modify condition
25901 for load/store addressing form.
25902 (nds32_print_operand_address): Likewise.
25903
25904 2018-04-06 Eric Botcazou <ebotcazou@adacore.com>
25905
25906 PR target/85196
25907 * config/sparc/sparc.c (sparc_expand_move): Deal with symbolic operands
25908 based on LABEL_REF. Remove useless assertion.
25909 (pic_address_needs_scratch): Fix formatting.
25910 (sparc_legitimize_pic_address): Minor tweaks.
25911 (sparc_delegitimize_address): Adjust assertion accordingly.
25912 * config/sparc/sparc.md (movsi_pic_label_ref): Change label_ref_operand
25913 into symbolic_operand.
25914 (movsi_high_pic_label_ref): Likewise.
25915 (movsi_lo_sum_pic_label_ref): Likewise.
25916 (movdi_pic_label_ref): Likewise.
25917 (movdi_high_pic_label_ref): Likewise.
25918 (movdi_lo_sum_pic_label_ref): Likewise.
25919
25920 2018-04-06 Amaan Cheval <amaan.cheval@gmail.com>
25921
25922 * config.gcc (x86_64-*-rtems*): Add rtems.h to tm_file for
25923 custom LIB_SPEC setup.
25924
25925 2018-04-06 Ruslan Bukin <br@bsdpad.com>
25926 Kito Cheng <kito.cheng@gmail.com>
25927
25928 * config.gcc (riscv*-*-freebsd*): Add RISC-V FreeBSD support.
25929 * config/riscv/freebsd.h: New.
25930
25931 2018-04-06 Chung-Ju Wu <jasonwucj@gmail.com>
25932
25933 * config/nds32/nds32.c (nds32_adjust_insn_length): Refine.
25934 * config/nds32/nds32.h (ADJUST_INSN_LENGTH): Change the location in
25935 file.
25936
25937 2018-04-06 Chung-Ju Wu <jasonwucj@gmail.com>
25938 Kito Cheng <kito.cheng@gmail.com>
25939
25940 * config/nds32/nds32-md-auxiliary.c (nds32_output_return,
25941 nds32_output_call, nds32_symbol_binds_local_p): New functions.
25942 * config/nds32/nds32-protos.h (nds32_output_call,
25943 nds32_output_return): Declare.
25944 * config/nds32/nds32.md: Refine all the call and return patterns.
25945
25946 2018-04-06 Jakub Jelinek <jakub@redhat.com>
25947
25948 PR debug/85252
25949 * dwarf2out.c (rtl_for_decl_init): For STRING_CST initializer only
25950 build CONST_STRING if TYPE_MAX_VALUE is non-NULL and is INTEGER_CST.
25951
25952 PR rtl-optimization/84872
25953 * cfgloopmanip.c (create_preheader): Use make_forwarder_block even if
25954 nentry == 1 when CP_FALLTHRU_PREHEADERS and single_entry is
25955 EDGE_CROSSING edge.
25956
25957 2018-04-06 Tamar Christina <tamar.christina@arm.com>
25958
25959 * expr.c (copy_blkmode_to_reg): Revert 254862.
25960 * doc/sourcebuild.texi (word_mode_no_slow_unalign): Likewise.
25961
25962 2018-04-06 Richard Biener <rguenther@suse.de>
25963
25964 PR middle-end/85244
25965 * tree-dfa.c (get_ref_base_and_extent): Reset seen_variable_array_ref
25966 after seeing a component reference with an adjacent field. Treat
25967 refs to arrays at struct end of external decls similar to
25968 refs to unconstrained commons.
25969
25970 2018-04-06 Jakub Jelinek <jakub@redhat.com>
25971
25972 PR sanitizer/85213
25973 * fold-const.c (twoval_comparison_p): Remove SAVE_P argument and don't
25974 look through SAVE_EXPRs with non-side-effects argument. Adjust
25975 recursive calls.
25976 (fold_comparison): Adjust twoval_comparison_p caller, don't handle
25977 save_p here.
25978
25979 2018-04-06 Richard Biener <rguenther@suse.de>
25980
25981 PR middle-end/85180
25982 * alias.c (find_base_term): New wrapper around find_base_term
25983 unwinding CSELIB_VAL_PTR changes.
25984 (find_base_term): Do not restore CSELIB_VAL_PTR during the
25985 recursion.
25986
25987 2018-04-06 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
25988
25989 * config/s390/s390.c (s390_z10_optimize_cmp): Expand dedicated NOP
25990 instructions.
25991 * config/s390/s390.md (UNSPECV_NOP_LR_0, UNSPECV_NOP_LR_1): New
25992 constant definitions.
25993 ("nop"): lr 0,0 -> nopr r0
25994 ("nop_lr0", "nop_lr1"): New insn definitions.
25995
25996 2018-04-06 Chung-Ju Wu <jasonwucj@gmail.com>
25997
25998 * config/nds32/nds32.md (*stack_push, *stack_pop): Use
25999 NDS32_V3PUSH_AVAILABLE_P macro.
26000
26001 2018-04-06 Monk Chiang <sh.chiang04@gmail.com>
26002 Chung-Ju Wu <jasonwucj@gmail.com>
26003
26004 * config.gcc (nds32*-*-*): Add v2j v3f v3s checking.
26005 (nds32*-*-*): Add float and fpu_config into supported_defaults.
26006 * common/config/nds32/nds32-common.c (TARGET_DEFAULT_TARGET_FLAGS):
26007 Include TARGET_DEFAULT_FPU_ISA and TARGET_DEFAULT_FPU_FMA.
26008 * config/nds32/constants.md (unspec_element): Add UNSPEC_COPYSIGN,
26009 UNSPEC_FCPYNSD, UNSPEC_FCPYNSS, UNSPEC_FCPYSD and UNSPEC_FCPYSS.
26010 * config/nds32/constraints.md: New constraints and checking for hard
26011 float configuration.
26012 * config/nds32/iterators.md: New mode iterator and attribute for hard
26013 float configuration.
26014 * config/nds32/nds32-doubleword.md: Use hard float alternatives and
26015 patterns.
26016 * config/nds32/nds32-fpu.md: New file.
26017 * config/nds32/nds32-md-auxiliary.c: New functions and checkings to
26018 deal with hard float code generation.
26019 * config/nds32/nds32-opts.h (nds32_arch_type): Add ARCH_V3F and
26020 ARCH_V3S.
26021 (abi_type, float_reg_number): New enum type.
26022 * config/nds32/nds32-predicates.c: New predicates for hard float.
26023 * config/nds32/nds32-protos.h: Declare functions for hard float.
26024 * config/nds32/nds32.c: Implementation for hard float configuration.
26025 * config/nds32/nds32.h: Definitions for hard float configuration.
26026 * config/nds32/nds32.md: Include hard float machine description and
26027 modify patterns for hard float configuration.
26028 * config/nds32/nds32.opt: New options for hard float configuration.
26029 * config/nds32/predicates.md: New predicates for hard float
26030 configuration.
26031
26032 2018-04-06 Kuan-Lin Chen <kuanlinchentw@gmail.com>
26033
26034 * common/config/nds32/nds32-common.c
26035 (nds32_option_optimization_table): Enable -mreleax-hint by default.
26036
26037 2018-04-05 Jakub Jelinek <jakub@redhat.com>
26038
26039 PR middle-end/85195
26040 * match.pd (BIT_FIELD_REF CONSTRUCTOR@0 @1 @2): Use view_convert around
26041 CONSTRUCTOR_ELT (ctor, ...)->value.
26042
26043 2018-04-05 Uros Bizjak <ubizjak@gmail.com>
26044
26045 PR target/85193
26046 * config/i386/i386.md (define_attr "memory"): Handle rotate1 type.
26047
26048 2018-04-05 Tom de Vries <tom@codesourcery.com>
26049
26050 PR target/85204
26051 * config/nvptx/nvptx.c (nvptx_single): Fix neutering of bb with only
26052 cond jump.
26053
26054 2018-04-05 Shiva Chen <shiva0217@gmail.com>
26055 Kito Cheng <kito.cheng@gmail.com>
26056
26057 * config/nds32/constraints.md (U33): Fine-tune checking condition.
26058 * config/nds32/nds32-md-auxiliary.c (nds32_mem_format): Ditto.
26059 * config/nds32/nds32.h (nds32_16bit_address_type): Add
26060 ADDRESS_POST_MODIFY_LO_REG_IMM3U.
26061
26062 2018-04-05 Shiva Chen <shiva0217@gmail.com>
26063 Kito Cheng <kito.cheng@gmail.com>
26064
26065 * config/nds32/constraints.md (Ufe): New memory constraint.
26066 * config/nds32/nds32-md-auxiliary.c (nds32_mem_format,
26067 nds32_output_16bit_load): Consider r8 register for lwi45.fe format.
26068 * config/nds32/nds32.c (nds32_print_operand): Output lwi45.fe
26069 operands.
26070 * config/nds32/nds32.h (nds32_16bit_address_type): Add ADDRESS_R8_IMM7U.
26071 * config/nds32/nds32.md (*mov<mode>): Adjust pattern.
26072
26073 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
26074
26075 * config/nds32/nds32.md: Use optimize_size in the condition for
26076 alu-shift instructions.
26077
26078 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
26079
26080 * config/nds32/nds32.md (divsi4, udivsi4): New patterns.
26081
26082 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
26083
26084 * config/nds32/nds32.md (negsi2): Refine pattern.
26085
26086 2018-04-05 Kito Cheng <kito.cheng@gmail.com>
26087 Chung-Ju Wu <jasonwucj@gmail.com>
26088
26089 * config/nds32/iterators.md (shift_rotate): New code iterator.
26090 (shift): New code attribute.
26091 * config/nds32/nds32-md-auxiliary.c (nds32_expand_constant): New.
26092 * config/nds32/nds32-protos.h (nds32_expand_constant): Declare.
26093 * config/nds32/nds32.c (nds32_print_operand): Deal with more cases.
26094 * config/nds32/nds32.md (addsi3, *add_srli): Refine implementation for
26095 bit-wise operations.
26096 (andsi3, *andsi3): Ditto.
26097 (iorsi3, *iorsi3, *or_slli, *or_srli): Ditto.
26098 (xorsi3, *xorsi3, *xor_slli, *xor_srli): Ditto.
26099 (<shift>si3, *ashlsi3, *ashrsi3, *lshrsi3, *rotrsi3): Ditto.
26100 * config/nds32/predicates.md (nds32_rimm5u_operand, nds32_and_operand,
26101 nds32_ior_operand, nds32_xor_operand): New predicates.
26102
26103 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
26104
26105 * config/nds32/nds32.md (add<mode>3, sub<mode>3): Rename to ...
26106 (addsi3, subsi3): ... this.
26107
26108 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
26109
26110 * config/nds32/nds32.md (*sub_srli, *and_slli): Fine-tune predicator.
26111
26112 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
26113
26114 * config/nds32/nds32.md: Adjust indention.
26115
26116 2018-04-05 Kito Cheng <kito.cheng@gmail.com>
26117
26118 * config/nds32/nds32.md (feature): New attribute.
26119
26120 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
26121
26122 * config/nds32/nds32.md (subtype): New attribute.
26123
26124 2018-04-04 Thomas Preud'homme <thomas.preudhomme@arm.com>
26125
26126 PR target/85203
26127 * config/arm/arm-builtins.c (arm_expand_builtin): Change
26128 expansion to perform a bitwise AND of the argument followed by a
26129 boolean negation of the result.
26130
26131 2018-04-04 Peter Bergner <bergner@vnet.ibm.com>
26132
26133 PR rtl-optimization/84878
26134 * ddg.c (add_cross_iteration_register_deps): Use DF_REF_BB to determine
26135 the basic block. Assert the use reference is not artificial and that
26136 it has an associated insn.
26137
26138 2018-04-04 Michael Matz <matz@suse.de>
26139
26140 * builtins.c (compute_objsize): Pass correct operand
26141 to array_at_struct_end_p.
26142
26143 2018-04-04 Richard Biener <rguenther@suse.de>
26144
26145 PR lto/85176
26146 * dwarf2out.c (dwarf2out_register_external_die): Peel namespaces
26147 from contexts for DINFO_LEVEL_TERSE and below.
26148
26149 2018-04-04 Kito Cheng <kito.cheng@gmail.com>
26150
26151 * config/nds32/nds32-doubleword.md (move_<mode>): Require
26152 resiter_operand condition.
26153 * config/nds32/nds32.md (*move<mode>): Ditto.
26154
26155 2018-04-04 Kito Cheng <kito.cheng@gmail.com>
26156 Monk Chiang <sh.chiang04@gmail.com>
26157
26158 * config/nds32/nds32.md (movmisalign<mode>): New pattern.
26159
26160 2018-04-04 Chung-Ju Wu <jasonwucj@gmail.com>
26161
26162 * config/nds32/nds32.md (movqi, movhi): Merge into mov<mode>.
26163
26164 2018-04-04 Chung-Ju Wu <jasonwucj@gmail.com>
26165 Kito Cheng <kito.cheng@gmail.com>
26166
26167 * config/nds32/nds32-md-auxiliary.c (nds32_inverse_cond_code,
26168 nds32_cond_code_str, output_cond_branch,
26169 output_cond_branch_compare_zero, nds32_expand_cbranch,
26170 nds32_expand_cstore, nds32_expand_movcc,
26171 nds32_output_cbranchsi4_equality_zero,
26172 nds32_output_cbranchsi4_equality_reg,
26173 nds32_output_cbranchsi4_equality_reg_or_const_int,
26174 nds32_output_cbranchsi4_greater_less_zero: New functions.
26175 * config/nds32/nds32-protos.h (nds32_expand_cbranch,
26176 nds32_expand_cstore, nds32_expand_movcc,
26177 nds32_output_cbranchsi4_equality_zero,
26178 nds32_output_cbranchsi4_equality_reg,
26179 nds32_output_cbranchsi4_equality_reg_or_const_int,
26180 nds32_output_cbranchsi4_greater_less_zero): Declare.
26181 * config/nds32/predicates.md (nds32_movecc_comparison_operator,
26182 nds32_rimm11s_operand): New predicates.
26183 * config/nds32/nds32.h (nds32_expand_result_type): New enum type.
26184 * config/nds32/nds32.md: Rewrite all the branch and conditional move
26185 patterns.
26186
26187 2018-04-04 Kito Cheng <kito.cheng@gmail.com>
26188
26189 * config/nds32/nds32-doubleword.md: Refine all the instruction type.
26190 * config/nds32/nds32.md: Ditto.
26191 * config/nds32/pipelines.md: Ditto.
26192
26193 2018-04-04 Richard Biener <rguenther@suse.de>
26194
26195 PR tree-optimization/85168
26196 * tree-ssa-sccvn.c (vn_reference_maybe_forwprop_address): Avoid
26197 propagating abnormals.
26198
26199 2018-04-04 Chung-Ju Wu <jasonwucj@gmail.com>
26200
26201 * config/nds32/nds32.md (enabled): Use yes/no for this attribute.
26202
26203 2018-04-04 Chung-Ju Wu <jasonwucj@gmail.com>
26204 Kito Cheng <kito.cheng@gmail.com>
26205
26206 * config/nds32/nds32-md-auxiliary.c (nds32_long_call_p): New function.
26207 * config/nds32/nds32-protos.h (nds32_long_call_p): Declare.
26208 * config/nds32/nds32.c (nds32_function_ok_for_sibcall): New function.
26209 (TARGET_FUNCTION_OK_FOR_SIBCALL): Define.
26210 * config/nds32/nds32.md (sibcall_internal): New.
26211 (sibcall_register): Remove.
26212 (sibcall_immediate): Remove.
26213 (sibcall_value_internal): New.
26214 (sibcall_value_register): Remove.
26215 (sibcall_value_immediate): Remove.
26216 * config/nds32/predicates.md (nds32_general_register_operand): New.
26217 (nds32_call_address_operand): New.
26218
26219 2018-04-03 Jakub Jelinek <jakub@redhat.com>
26220
26221 PR rtl-optimization/85167
26222 * shrink-wrap.c (move_insn_for_shrink_wrap): Don't set bb_uses and
26223 bb_defs if *split_p, instead preinitialize it to NULL.
26224
26225 PR tree-optimization/85156
26226 * builtins.c (fold_builtin_expect): Use save_expr on arg1 to avoid
26227 evaluating the argument multiple times.
26228
26229 2018-04-03 Bill Schmidt <wschmidt@linux.ibm.com>
26230
26231 * config/rs6000/emmintrin.h (_mm_cvtpd_epi32): Use __vector rather
26232 than vector.
26233 (_mm_cvtpd_ps): Likewise.
26234 (_mm_cvttpd_epi32): Likewise.
26235 * config/rs6000/mmintrin.h (_mm_unpacklo_pi8): Likewise.
26236 * config/rs6000/xmmintrin.h: For strict-ANSI C++ or C11, undefine
26237 vector, pixel, and bool following altivec.h include.
26238
26239 2018-04-03 Martin Sebor <msebor@redhat.com>
26240
26241 * doc/extend.texi (Common Function Attributes): Clarify.
26242 (const attribute): Likewise.
26243 (pure attribute): Likewise.
26244
26245 2018-04-03 Jakub Jelinek <jakub@redhat.com>
26246
26247 PR target/85169
26248 * config/i386/i386.c (ix86_expand_vector_set): Use
26249 HOST_WIDE_INT_1U << elt instead of 1 << elt. Formatting fix.
26250
26251 2018-04-03 Uros Bizjak <ubizjak@gmail.com>
26252
26253 * config/i386/i386.c (emit_i387_cw_initialization): Always use logic
26254 instructions when changing rounding bits to preserve precision bits
26255 in the x87 control word.
26256
26257 2018-04-03 Martin Liska <mliska@suse.cz>
26258
26259 PR tree-optimization/82491
26260 * rtl.h (strip_offset_and_add): Replace += suboffset with
26261 poly_uint64 () + suboffset.
26262
26263 2018-03-29 Martin Liska <mliska@suse.cz>
26264 Martin Jambor <mjambor@suse.cz>
26265
26266 PR ipa/84947
26267 * ipa-cp.c (propagate_bits_across_jump_function): Bail out if
26268 param_type is not an integral or pointer type.
26269
26270 2018-04-03 Richard Biener <rguenther@suse.de>
26271
26272 * sese.h (recompute_all_dominators): Remove.
26273
26274 2018-04-02 Martin Sebor <msebor@redhat.com>
26275
26276 * doc/invoke.texi (-Wrestrict): Fix typos.
26277
26278 2018-04-02 Jim Wilson <jimw@sifive.com>
26279
26280 * config/riscv/riscv.h (SHIFT_COUNT_TRUNCATED): Set to zero.
26281 * config/riscv/riscv.md (<optab>si3): Use QImode shift count.
26282 (<optab>di3, <optab>si3_extend): Likewise.
26283 (<optab>si3_mask, <optab>si3_mask_1): New.
26284 (<optab>di3_mask, <optab>di3_mask_1): New.
26285 (<optab>si3_extend_mask, <optab>si3_extend_mask_1): New.
26286 (lshrsi3_zero_extend_1): Use VOIDmode shift count.
26287 * config/riscv/sync.md (atomic_test_and_set): Emit QImode shift count.
26288
26289 2018-04-02 Gerald Pfeifer <gerald@pfeifer.com>
26290
26291 * doc/cpp.texi (Variadic Macros): Fix line continuation in an
26292 example.
26293
26294 2018-04-02 Chung-Ju Wu <jasonwucj@gmail.com>
26295
26296 * config/nds32/nds32.c (TARGET_CANONICALIZE_COMPARISON): Define.
26297 (nds32_canonicalize_comparison): New function.
26298
26299 2018-04-01 Chung-Ju Wu <jasonwucj@gmail.com>
26300 Kito Cheng <kito.cheng@gmail.com>
26301 Kuan-Lin Chen <kuanlinchentw@gmail.com>
26302
26303 * config.gcc (nds32): Add nds32-relax-opt.o into extra_objs.
26304 * config/nds32/constants.md (unspec_volatile_element): Add
26305 UNSPEC_VOLATILE_RELAX_GROUP.
26306 * config/nds32/nds32-relax-opt.c: New file.
26307 * config/nds32/nds32-predicates.c
26308 (nds32_symbol_load_store_p): New function.
26309 * config/nds32/nds32-protos.h
26310 (nds32_symbol_load_store_p): Declare function.
26311 (make_pass_nds32_relax_opt): Declare new rtl pass function.
26312 * config/nds32/nds32.c
26313 (nds32_register_pass): New function to register pass.
26314 (nds32_register_passes): New function to register passes.
26315 * config/nds32/nds32.md (relax_group): New pattern.
26316 * config/nds32/nds32.opt (mrelax-hint): New option.
26317 * config/nds32/t-nds32 (nds32-relax-opt.o): New dependency.
26318
26319 2018-04-01 Kito Cheng <kito.cheng@gmail.com>
26320
26321 * config/nds32/t-nds32: Modify files dependency.
26322
26323 2018-04-01 Chung-Ju Wu <jasonwucj@gmail.com>
26324
26325 * config/nds32/nds32.h (FUNCTION_PROFILER): Output newline character.
26326 (PROFILE_HOOK): Define its implementation.
26327
26328 2018-04-01 Chung-Ju Wu <jasonwucj@gmail.com>
26329
26330 * config/nds32/nds32.h (WCHAR_TYPE, WCHAR_TYPE_SIZE): Use unsigned int
26331 type and 32-bit size.
26332
26333 2018-04-01 Jakub Jelinek <jakub@redhat.com>
26334
26335 PR middle-end/85090
26336 * config/i386/sse.md (V): Add V64QI and V32HI for TARGET_AVX512F.
26337 (V_128_256): New mode iterator.
26338 (*avx512dq_vextract<shuffletype>64x2_1 splitter): New define_split.
26339 (*avx512f_vextract<shuffletype>32x4_1 splitter): Likewise.
26340 (xop_pcmov_<mode><avxsizesuffix>): Use V_128_256 mode iterator instead
26341 of V.
26342 * config/i386/i386.c (ix86_expand_vector_set): Improve V32HImode and
26343 V64QImode expansion for !TARGET_AVX512BW && TARGET_AVX512F.
26344
26345 2018-03-31 Segher Boessenkool <segher@kernel.crashing.org>
26346
26347 PR target/83315
26348 * config/rs6000/xmmintrin.h (_mm_set_ps, _mm_max_ps): Handle (quiet)
26349 NaN inputs correctly.
26350
26351 2018-03-30 Peter Bergner <bergner@vnet.ibm.com>
26352
26353 PR target/80546
26354 * config/rs6000/vsx.md (??r): New mode attribute.
26355 (*vsx_mov<mode>_64bit): Use it.
26356 (*vsx_mov<mode>_32bit): Likewise.
26357
26358 2018-03-30 Martin Sebor <msebor@redhat.com>
26359
26360 PR tree-optimization/84818
26361 * builtins.c (check_access): Use warning_n.
26362
26363 2018-03-30 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
26364
26365 PR target/83822
26366 * config/rs6000/rs6000-string.c (expand_compare_loop): Fix redundant
26367 condition.
26368 * config/rs6000/rs6000-c.c (rs6000_cpu_cpp_builtins): Fix redundant
26369 condition.
26370
26371 2018-03-30 Julia Koval <julia.koval@intel.com>
26372
26373 PR target/84413
26374 * x86-tune.def (movx, partial_reg_dependency): Enable for
26375 m_SKYLAKE_AVX512.
26376
26377 2018-03-29 Vladimir Makarov <vmakarov@redhat.com>
26378
26379 PR inline-asm/84985
26380 * lra-constraints.c (process_alt_operands): Move setting
26381 this_alternative_matches below.
26382
26383 2018-03-29 Martin Liska <mliska@suse.cz>
26384
26385 PR lto/84995.
26386 * doc/invoke.texi: Document how LTO works with debug info.
26387 Describe auto-load support of binutils. Mention 'x86-64'
26388 as valid option value of -march option.
26389
26390 2018-03-29 Jakub Jelinek <jakub@redhat.com>
26391
26392 * config/i386/sse.md (<avx512>_blendm<mode>): Use <sseintprefix>.
26393
26394 PR c/85094
26395 * fold-const.c (operand_equal_p): Handle DEBUG_BEGIN_STMT.
26396 For STATEMENT_LIST, pass down OEP_LEXICOGRAPHIC and maybe
26397 OEP_NO_HASH_CHECK for recursive call, to avoid exponential
26398 checking.
26399
26400 2018-03-28 Peter Bergner <bergner@vnet.ibm.com>
26401
26402 PR target/84912
26403 * config/rs6000/rs6000.h (RS6000_BTM_POWERPC64): New define.
26404 (RS6000_BTM_COMMON): Add RS6000_BTM_POWERPC64.
26405 * config/rs6000/rs6000.c (rs6000_builtin_mask_calculate): Add support
26406 for RS6000_BTM_POWERPC64.
26407 (rs6000_invalid_builtin): Add handling for RS6000_BTM_POWERPC64
26408 (rs6000_builtin_mask_names): Add RS6000_BTM_POWERPC64.
26409 * config/rs6000/rs6000-builtin.def (BU_P7_POWERPC64_MISC_2): New macro
26410 definition.
26411 (DIVDE): Use it.
26412 (DIVDEU): Likewise.
26413
26414 2018-03-28 Carl Love <cel@us.ibm.com>
26415
26416 Revert
26417 2017-09-27 Carl Love <cel@us.ibm.com>
26418
26419 * config/rs6000/rs6000-builtin.def (BU_FP_1MISC_1): Add define macro.
26420 (FCTID, FCTIW): Add BU_FP_MISC_1 macro expansion for builtins.
26421 * config/rs6000/rs6000.md (lrintsfsi2): Add define_insn for the
26422 fctiw instruction.
26423
26424 2018-03-28 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
26425
26426 * config/rs6000/xmmintrin.h (_mm_max_pi16): Use __vector __bool
26427 instead of __vector bool.
26428 (_mm_max_pu8): Likewise.
26429 (_mm_min_pi16): Likewise.
26430
26431 2018-03-28 Peter Bergner <bergner@vnet.ibm.com>
26432
26433 PR target/84912
26434 * config/rs6000/rs6000-builtin.def (DIVWEO): Delete macro expansion.
26435 (DIVWEUO): Likewise.
26436 (DIVDEO): Likewise.
26437 (DIVDEUO): Likewise.
26438 * config/rs6000/rs6000.c (builtin_function_type): Remove support for
26439 DIVWEUO and DIVDEUO.
26440 * config/rs6000/rs6000.md (UNSPEC_DIVEO, UNSPEC_DIVEUO): Delete unspecs.
26441 (UNSPEC_DIV_EXTEND): Remove deleted unspecs.
26442 (div_extend): Likewise.
26443 * doc/extend.texi (__builtin_divweo): Remove documentation for deleted
26444 builtin function.
26445 (__builtin_divweuo): Likewise.
26446 (__builtin_divdeo): Likewise.
26447 (__builtin_divdeuo): Likewise.
26448
26449 2018-03-28 Jakub Jelinek <jakub@redhat.com>
26450
26451 PR target/85095
26452 * config/i386/i386.md (*add<mode>3_carry_0, *addsi3_carry_zext_0,
26453 *sub<mode>3_carry_0, *subsi3_carry_zext_0): New patterns.
26454
26455 PR tree-optimization/82004
26456 * gimple-match-head.c (optimize_pow_to_exp): New function.
26457 * match.pd (pow(C,x) -> exp(log(C)*x)): Wrap with #if GIMPLE.
26458 Don't fold to exp if optimize_pow_to_exp is false.
26459
26460 2018-03-28 Martin Liska <mliska@suse.cz>
26461
26462 PR other/84819
26463 * calls.c (initialize_argument_information): Fix trailing space.
26464 * common.opt: Fix typo and provide better explanation for
26465 -fsanitize-coverage option.
26466 * config/i386/i386.opt: Fix typo.
26467
26468 2018-03-28 Jakub Jelinek <jakub@redhat.com>
26469 Martin Liska <mliska@suse.cz>
26470
26471 PR sanitizer/85081
26472 * gimplify.c (asan_poison_variable): Don't do the check for
26473 gimplify_omp_ctxp here.
26474 (gimplify_decl_expr): Do it here.
26475 (gimplify_target_expr): Likewise.
26476
26477 2018-03-28 Martin Liska <mliska@suse.cz>
26478
26479 PR target/84988
26480 * config/i386/i386.c (ix86_function_arg_advance): Do not call
26481 chkp_type_bounds_count if MPX is not enabled.
26482
26483 2018-03-27 Chung-Ju Wu <jasonwucj@gmail.com>
26484
26485 * config/nds32/nds32.h (BRANCH_COST): Adjust cost.
26486
26487 2018-03-27 Michael Meissner <meissner@linux.vnet.ibm.com>
26488
26489 PR target/84914
26490 * config/rs6000/rs6000.c (create_complex_muldiv): New helper
26491 function to create the function decl for complex long double
26492 multiply and divide for -mabi=ieeelongdouble.
26493 (init_float128_ieee): Call it.
26494
26495 2018-03-27 H.J. Lu <hongjiu.lu@intel.com>
26496
26497 PR target/85044
26498 * config/i386/i386.c (ix86_trampoline_init): Insert ENDBR for
26499 -fcf-protection=branch -mibt.
26500 * config/i386/i386.h (TRAMPOLINE_SIZE): Increased by 4 bytes.
26501
26502 2018-03-27 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
26503
26504 PR target/81863
26505 * config/arm/arm.c (arm_valid_symbolic_address): Handle
26506 arm_word_relocations.
26507
26508 2018-03-27 Cesar Philippidis <cesar@codesourcery.com>
26509
26510 PR target/85056
26511 * config/nvptx/nvptx.c (nvptx_assemble_decl_begin): Add '[]' to
26512 extern array declarations.
26513
26514 2018-03-27 Richard Biener <rguenther@suse.de>
26515
26516 PR middle-end/84067
26517 * match.pd ((A * C) +- (B * C) -> (A+-B) * C): Guard with
26518 explicit single_use checks.
26519
26520 2018-03-27 Richard Biener <rguenther@suse.de>
26521
26522 PR tree-optimization/85082
26523 * tree-ssa-sccvn.c (vn_reference_lookup_or_insert_for_pieces):
26524 Valueize the VUSE.
26525
26526 2018-03-27 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
26527
26528 * config.gcc (aarch64*-*-linux*): New TARGET_DEFAULT_ASYNC_UNWIND_TABLES
26529 * common/config/aarch64/aarch64-common.c (aarch64_optimization_table[]):
26530 Turn on fasynchronous-unwind-tables and funwind-tables.
26531
26532 2018-03-26 Uros Bizjak <ubizjak@gmail.com>
26533
26534 PR target/85073
26535 * config/i386/i386.md (*bmi_blsr_<mode>_cmp): New insn pattern.
26536 (*bmi_blsr_<mode>_ccz): Ditto.
26537
26538 2018-03-26 Tom de Vries <tom@codesourcery.com>
26539
26540 PR tree-optimization/85063
26541 * omp-general.c (offloading_function_p): New function. Factor out
26542 of ...
26543 * omp-offload.c (pass_omp_target_link::gate): ... here.
26544 * omp-general.h (offloading_function_p): Declare.
26545 * tree-switch-conversion.c (build_one_array): Mark CSWTCH.x variable
26546 with attribute omp declare target for offloading functions.
26547
26548 2018-03-24 Richard Sandiford <richard.sandiford@linaro.org>
26549
26550 PR tree-optimization/84005
26551 * tree-data-ref.h (get_base_for_alignment): Declare.
26552 * tree-data-ref.c (get_base_for_alignment_1): New function.
26553 (get_base_for_alignment): Likewise.
26554 * tree-vect-data-refs.c (vect_compute_data_ref_alignment): Use
26555 get_base_for_alignment to find a suitable base object, instead
26556 of always using drb->base_address.
26557
26558 2018-03-23 Jakub Jelinek <jakub@redhat.com>
26559
26560 PR inline-asm/85022
26561 * emit-rtl.c (init_emit_regs): Indicate that VOIDmode MEMs don't have
26562 known size by default.
26563
26564 2018-03-23 Vladimir Makarov <vmakarov@redhat.com>
26565
26566 PR inline-asm/85030
26567 * lra-constraints.c (process_alt_operands): Don't match BLKmode
26568 and non BLKmode operands.
26569
26570 2018-03-23 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
26571
26572 PR target/85026
26573 * config/arm/arm.md (unaligned_loadhis): Remove first alternative.
26574 Clean up attributes.
26575
26576 2018-03-23 Richard Biener <rguenther@suse.de>
26577
26578 PR debug/85020
26579 * dwarf2out.c (rtl_for_decl_location): Do not generate RTL early when
26580 we are going to emit early debug for LTO.
26581
26582 2018-03-23 Jakub Jelinek <jakub@redhat.com>
26583
26584 PR inline-asm/85034
26585 * function.c (match_asm_constraints_1): Don't optimize if input
26586 doesn't satisfy general_operand predicate for output's mode.
26587
26588 PR inline-asm/85022
26589 * alias.c (write_dependence_p): Don't require for x_canonicalized
26590 non-VOIDmode if x has VOIDmode.
26591
26592 PR sanitizer/85029
26593 * sanopt.c (maybe_optimize_ubsan_ptr_ifn): If DECL_REGISTER (base),
26594 just don't try to optimize it rather than assert it never happens.
26595
26596 2018-03-22 Kelvin Nilsen <kelvin@gcc.gnu.org>
26597
26598 * config/rs6000/rs6000-builtin.def: Remove various BU_ALTIVEC_X
26599 macro expansions for definition of ST_INTERNAL_<mode> and
26600 LD_INTERNAL_<mode> builtins.
26601 * config/rs6000/rs6000-protos.h (rs6000_address_for_altivec):
26602 Remove prototype.
26603 * config/rs6000/rs6000.c (altivec_expand_ld_builtin): Delete this
26604 function.
26605 (altivec_expand_st_builtin): Likewise.
26606 (altivec_expand_builtin): Remove calls to deleted functions.
26607 (rs6000_address_for_altivec): Delete this function.
26608 * config/rs6000/vector.md: Remove expands for
26609 vector_altivec_load_<mode> and vector_altivec_store_<mode>.
26610
26611 2018-03-22 Sudakshina Das <sudi.das@arm.com>
26612
26613 PR target/84826
26614 * config/arm/arm.h (machine_function): Add static_chain_stack_bytes.
26615 * config/arm/arm.c (arm_compute_static_chain_stack_bytes): Avoid
26616 re-computing once computed.
26617 (arm_expand_prologue): Compute machine->static_chain_stack_bytes.
26618 (arm_init_machine_status): Initialize
26619 machine->static_chain_stack_bytes.
26620
26621 2018-03-22 Kelvin Nilsen <kelvin@gcc.gnu.org>
26622
26623 PR target/84760
26624 * doc/extend.texi: Add four new prototypes for vec_ld.
26625 * config/rs6000/rs6000-builtin.def (LVX_V1TI): Reorder symbol
26626 definitions for more logical presentation.
26627 * config/rs6000/rs6000-c.c: (altivec_overloaded_builtins): Add
26628 entries for V1TI variants of __builtin_altivec_ld builtin.
26629 * config/rs6000/rs6000.c: (altivec_expand_lv_builtin): Add test and
26630 handling of V1TI variant of LVX icode pattern.
26631 (altivec_expand_builtin): Add case for ALTIVEC_BUILTIN_LVX_V1TI.
26632 (rs6000_gimple_fold_builtin): Likewise.
26633 (altivec_init_builtins): Add code to define
26634 __builtin_altivec_lvx_v1ti function.
26635
26636 2018-03-22 Jakub Jelinek <jakub@redhat.com>
26637
26638 PR inline-asm/84941
26639 * function.c (match_asm_constraints_1): Don't do the optimization
26640 if input isn't a REG, SUBREG, MEM or constant.
26641
26642 2018-03-22 Tom de Vries <tom@codesourcery.com>
26643
26644 PR tree-optimization/84956
26645 * tree-ssa-tail-merge.c (find_clusters_1): Skip bbs with
26646 bb_has_abnormal_pred.
26647
26648 2018-03-22 Jakub Jelinek <jakub@redhat.com>
26649
26650 PR sanitizer/85018
26651 * dwarf2asm.c (dw2_output_indirect_constant_1): Set
26652 DECL_INITIAL (decl) to decl at the end.
26653 * varasm.c (use_blocks_for_decl_p): Revert the 2018-03-20 change,
26654 adjust the comment.
26655
26656 2018-03-21 Joseph Myers <joseph@codesourcery.com>
26657
26658 * doc/extend.texi (__builtin_tgmath): Document when complex
26659 integer types are treated as _Complex _Float64.
26660
26661 2018-03-21 Tom de Vries <tom@codesourcery.com>
26662
26663 * doc/extend.texi (__builtin_extend_pointer): Remove pasto.
26664
26665 2018-03-21 Jakub Jelinek <jakub@redhat.com>
26666
26667 PR tree-optimization/84960
26668 * tree-cfg.c (remove_bb): Don't move forced labels into bb->prev_bb
26669 if it is ENTRY block, move them into single succ of ENTRY in that case.
26670
26671 2018-03-21 Richard Sandiford <richard.sandiford@linaro.org>
26672
26673 PR tree-optimization/84811
26674 * poly-int.h (poly_span_traits): Remove the T3 parameter and
26675 promote HOST_WIDE_INT T2 - T1 results to unsigned HOST_WIDE_INT.
26676 (maybe_in_range_p, known_in_range_p, ranges_known_overlap_p):
26677 (known_subrange_p): Update accordingly. Cast each value involved
26678 in the size comparison, rather than casting the result of the
26679 subtraction.
26680
26681 2018-03-21 Jakub Jelinek <jakub@redhat.com>
26682
26683 PR tree-optimization/84982
26684 * gimple-ssa-store-merging.c (invert_op): Handle boolean inversion
26685 by flipping the least significant bit rather than all bits from
26686 bitpos to bitpos + bitsize - 1.
26687
26688 2018-03-21 Nathan Sidwell <nathan@acm.org>
26689
26690 * doc/extend.texi (Deprecated Features): Remove mention of
26691 long-deleted deprecations.
26692
26693 2018-03-21 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
26694
26695 PR jit/84288
26696 * configure.ac (gcc_cv_ld_soname) <*-*-solaris2*>: Set.
26697 * configure: Regenerate.
26698
26699 2018-03-21 Tom de Vries <tom@codesourcery.com>
26700
26701 PR tree-optimization/83126
26702 * tree-parloops.c (num_phis): New function.
26703 (gen_parallel_loop): Detect and handle canonicalize_loop_ivs failure.
26704
26705 2018-03-21 Nathan Sidwell <nathan@acm.org>
26706
26707 * doc/extend.texi (Deprecated Features): Update deprecated flags,
26708 mention anon-struct/union members and trailing attributes.
26709
26710 2018-03-21 Bin Cheng <bin.cheng@arm.com>
26711
26712 PR tree-optimization/84969
26713 * tree-loop-distribution.c (fuse_memset_builtins): Don't reorder
26714 builtin memset partitions if they set different rhs values.
26715
26716 2018-03-21 Jakub Jelinek <jakub@redhat.com>
26717
26718 PR rtl-optimization/84989
26719 * simplify-rtx.c (simplify_unary_operation_1): Don't try to simplify
26720 VEC_DUPLICATE with scalar result mode.
26721
26722 2018-03-21 Martin Liska <mliska@suse.cz>
26723
26724 PR ipa/84963
26725 * ipa-icf.c (sem_item_optimizer::fixup_points_to_sets): Remove
26726 not intended return statement.
26727
26728 2018-03-21 Martin Liska <mliska@suse.cz>
26729
26730 PR target/84988
26731 * tree-chkp.c (CHKP_ARRAY_MAX_CHECK_STEPS): Define a new macro.
26732 (chkp_find_bound_slots_1): Limit number of iterations.
26733
26734 2018-03-20 David H. Gutteridge <dhgutteridge@sympatico.ca>
26735
26736 PR target/84838
26737 * Minor grammar fixes for x86 options.
26738
26739 2018-03-20 Jakub Jelinek <jakub@redhat.com>
26740
26741 PR debug/84875
26742 * dce.c (delete_unmarked_insns): Don't remove frame related noop moves
26743 holding REG_CFA_RESTORE notes, instead turn them into a USE.
26744
26745 2018-03-20 Peter Bergner <bergner@vnet.ibm.com>
26746
26747 PR target/83789
26748 * config/rs6000/altivec.md (altivec_lvx_<mode>_2op): Delete define_insn.
26749 (altivec_lvx_<mode>_1op): Likewise.
26750 (altivec_stvx_<mode>_2op): Likewise.
26751 (altivec_stvx_<mode>_1op): Likewise.
26752 (altivec_lvx_<VM2:mode>): New define_expand.
26753 (altivec_stvx_<VM2:mode>): Likewise.
26754 (altivec_lvx_<VM2:mode>_2op_<P:mptrsize>): New define_insn.
26755 (altivec_lvx_<VM2:mode>_1op_<P:mptrsize>): Likewise.
26756 (altivec_stvx_<VM2:mode>_2op_<P:mptrsize>): Likewise.
26757 (altivec_stvx_<VM2:mode>_1op_<P:mptrsize>): Likewise.
26758 * config/rs6000/rs6000-p8swap.c (rs6000_gen_stvx): Use new expanders.
26759 (rs6000_gen_lvx): Likewise.
26760 * config/rs6000/rs6000.c (altivec_expand_lv_builtin): Likewise.
26761 (altivec_expand_stv_builtin): Likewise.
26762 (altivec_expand_builtin): Likewise.
26763 * config/rs6000/vector.md: Likewise.
26764
26765 2018-03-20 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
26766
26767 PR target/82518
26768 * config/arm/arm.c (arm_array_mode_supported_p): Return false for
26769 BYTES_BIG_ENDIAN.
26770
26771 2018-03-20 Richard Biener <rguenther@suse.de>
26772
26773 PR target/84986
26774 * config/i386/i386.c (ix86_add_stmt_cost): Only cost
26775 sign-conversions as zero, fall back to standard scalar_stmt
26776 cost for the rest.
26777
26778 2018-03-20 Martin Liska <mliska@suse.cz>
26779
26780 PR ipa/84825
26781 * predict.c (rebuild_frequencies): Handle case when we have
26782 PROFILE_ABSENT, but flag_guess_branch_prob is false.
26783
26784 2018-03-20 Jakub Jelinek <jakub@redhat.com>
26785
26786 PR target/84990
26787 * dwarf2asm.c (dw2_output_indirect_constant_1): Temporarily turn off
26788 flag_section_anchors.
26789 * varasm.c (use_blocks_for_decl_p): Remove hack for
26790 dw2_force_const_mem.
26791
26792 PR target/84845
26793 * config/aarch64/aarch64.md (*aarch64_reg_<mode>3_neg_mask2): Rename
26794 to ...
26795 (*aarch64_<optab>_reg_<mode>3_neg_mask2): ... this. If pseudos can't
26796 be created, use lowpart_subreg of operands[0] rather than operands[0]
26797 itself.
26798 (*aarch64_reg_<mode>3_minus_mask): Rename to ...
26799 (*aarch64_ashl_reg_<mode>3_minus_mask): ... this.
26800 (*aarch64_<optab>_reg_di3_mask2): Use const_int_operand predicate
26801 and n constraint instead of aarch64_shift_imm_di and Usd.
26802 (*aarch64_reg_<optab>_minus<mode>3): Rename to ...
26803 (*aarch64_<optab>_reg_minus<mode>3): ... this.
26804
26805 2018-03-20 Sudakshina Das <sudi.das@arm.com>
26806
26807 PR target/82989
26808 * config/arm/neon.md (ashldi3_neon): Update ?s for constraints
26809 to favor GPR over NEON registers.
26810 (<shift>di3_neon): Likewise.
26811
26812 2018-03-20 Tom de Vries <tom@codesourcery.com>
26813
26814 PR target/84952
26815 * config/nvptx/nvptx.c (nvptx_single): Don't neuter bar.sync.
26816 (nvptx_process_pars): Emit bar.sync asap and alap.
26817
26818 2018-03-20 Tom de Vries <tom@codesourcery.com>
26819
26820 PR target/84954
26821 * config/nvptx/nvptx.c (prevent_branch_around_nothing): Also update
26822 seen_label if seen_label is already set.
26823
26824 2018-03-20 Jakub Jelinek <jakub@redhat.com>
26825
26826 PR target/84945
26827 * config/i386/i386.c (fold_builtin_cpu): For features above 31
26828 use __cpu_features2 variable instead of __cpu_model.__cpu_features[0].
26829 Use 1U instead of 1. Formatting fixes.
26830
26831 PR c/84953
26832 * builtins.c (fold_builtin_strpbrk): For strpbrk(x, "") use type
26833 instead of TREE_TYPE (s1) for the return value.
26834
26835 2018-03-19 Jakub Jelinek <jakub@redhat.com>
26836
26837 PR tree-optimization/84946
26838 * gimple-ssa-store-merging.c (mem_valid_for_store_merging): Compute
26839 bitsize + bitsize in poly_uint64 rather than poly_int64.
26840
26841 PR sanitizer/78651
26842 * dwarf2asm.c: Include fold-const.c.
26843 (dw2_output_indirect_constant_1): Set DECL_INITIAL (decl) to ADDR_EXPR
26844 of decl rather than decl itself.
26845
26846 PR rtl-optimization/84643
26847 * memmodel.h (enum memmodel): Add MEMMODEL_MAX enumerator.
26848
26849 2018-03-19 Maxim Ostapenko <m.ostapenko@samsung.com>
26850
26851 PR sanitizer/78651
26852 * dwarf2asm.c (dw2_output_indirect_constant_1): Disable ASan before
26853 calling assemble_variable.
26854
26855 2018-03-19 Sudakshina Das <sudi.das@arm.com>
26856
26857 PR target/81647
26858 * config/aarch64/aarch64-simd.md (vec_cmp<mode><v_int_equiv>): Modify
26859 instructions for UNLT, UNLE, UNGT, UNGE, UNEQ, UNORDERED and ORDERED.
26860
26861 2018-03-19 Jim Wilson <jimw@sifive.com>
26862
26863 PR bootstrap/84856
26864 * config/riscv/riscv.c (riscv_function_arg_boundary): Use
26865 PREFERRED_STACK_BOUNDARY instead of STACK_BOUNDARY.
26866 (riscv_first_stack_step): Likewise.
26867 (riscv_option_override): Use STACK_BOUNDARY instead of
26868 MIN_STACK_BOUNDARY.
26869 * config/riscv/riscv.h (STACK_BOUNDARY): Renamed from
26870 MIN_STACK_BOUNDARY.
26871 (BIGGEST_ALIGNMENT): Set to 128.
26872 (PREFERRED_STACK_BOUNDARY): Renamed from STACK_BOUNDARY.
26873 (RISCV_STACK_ALIGN): Use PREFERRED_STACK_BOUNDARY instead of
26874 STACK_BOUNDARY.
26875
26876 2018-03-19 Richard Biener <rguenther@suse.de>
26877
26878 PR tree-optimization/84933
26879 * tree-vrp.c (set_and_canonicalize_value_range): Treat out-of-bound
26880 values as -INF/INF when canonicalizing an ANTI_RANGE to a RANGE.
26881
26882 2018-03-19 Richard Biener <rguenther@suse.de>
26883
26884 PR tree-optimization/84859
26885 * tree-ssa-phiopt.c (single_trailing_store_in_bb): New function.
26886 (cond_if_else_store_replacement): Perform sinking operation on
26887 single-store BBs regardless of MAX_STORES_TO_SINK setting.
26888 Generalize what a BB with a single eligible store is.
26889
26890 2018-03-19 Richard Biener <rguenther@suse.de>
26891
26892 PR tree-optimization/84929
26893 * tree-data-ref.c (analyze_siv_subscript_cst_affine): Guard
26894 chrec_is_positive against non-chrec arg.
26895
26896 2018-03-19 Tamar Christina <tamar.christina@arm.com>
26897
26898 PR target/84711
26899 * config/arm/arm.c (arm_can_change_mode_class): revert r258554.
26900
26901 2018-03-18 Martin Liska <mliska@suse.cz>
26902
26903 PR rtl-optimization/84635
26904 * regrename.c (build_def_use): Use matches_mode only when
26905 matches >= 0.
26906
26907 2018-03-18 Richard Sandiford <richard.sandiford@linaro.org>
26908
26909 PR tree-optimization/84913
26910 * tree-vect-loop.c (vectorizable_reduction): Don't try to
26911 vectorize chains of COND_EXPRs.
26912
26913 2018-03-18 Chung-Ju Wu <jasonwucj@gmail.com>
26914
26915 * config/nds32/nds32.h (MAX_REGS_PER_ADDRESS): Fix the value.
26916
26917 2018-03-18 Chung-Ju Wu <jasonwucj@gmail.com>
26918
26919 * config/nds32/nds32.h (LOGICAL_OP_NON_SHORT_CIRCUIT): Define.
26920
26921 2018-03-18 Chung-Ju Wu <jasonwucj@gmail.com>
26922
26923 * config/nds32/nds32.h (CLZ_DEFINED_VALUE_AT_ZERO): Define.
26924
26925 2018-03-17 Chung-Ju Wu <jasonwucj@gmail.com>
26926 Kito Cheng <kito.cheng@gmail.com>
26927
26928 * config/nds32/nds32-protos.h (nds32_adjust_reg_alloc_order): Declare.
26929 * config/nds32/nds32.c (nds32_reg_alloc_order_for_speed): New array.
26930 (nds32_adjust_reg_alloc_order): New function.
26931 * config/nds32/nds32.h (ADJUST_REG_ALLOC_ORDER): Define.
26932
26933 2018-03-17 Kito Cheng <kito.cheng@gmail.com>
26934
26935 * config/nds32/nds32.c (nds32_asm_output_mi_thunk,
26936 nds32_print_operand, nds32_print_operand_address): Use
26937 HOST_WIDE_INT_PRINT_DEC instead.
26938
26939 2018-03-17 Chung-Ju Wu <jasonwucj@gmail.com>
26940
26941 * config/nds32/nds32.c (nds32_register_priority): Modify cost.
26942
26943 2018-03-17 Jakub Jelinek <jakub@redhat.com>
26944
26945 PR target/84902
26946 * config/i386/i386.c (initial_ix86_tune_features,
26947 initial_ix86_arch_features): Use unsigned HOST_WIDE_INT rather than
26948 unsigned long long.
26949 (set_ix86_tune_features): Change ix86_tune_mask from unsigned int
26950 to unsigned HOST_WIDE_INT, initialize to HOST_WIDE_INT_1U << ix86_tune
26951 rather than 1u << ix86_tune. Formatting fix.
26952 (ix86_option_override_internal): Change ix86_arch_mask from
26953 unsigned int to unsigned HOST_WIDE_INT, initialize to
26954 HOST_WIDE_INT_1U << ix86_arch rather than 1u << ix86_arch.
26955 (ix86_function_specific_restore): Likewise.
26956
26957 2018-03-16 Jakub Jelinek <jakub@redhat.com>
26958
26959 PR target/84899
26960 * postreload.c (reload_combine_recognize_pattern): Perform
26961 INTVAL addition in unsigned HOST_WIDE_INT type to avoid UB and
26962 truncate_int_for_mode the result for the destination's mode.
26963
26964 PR c/84909
26965 * hsa-gen.c (mem_type_for_type): Fix comment typo.
26966 * tree-vect-loop-manip.c (vect_create_cond_for_niters_checks):
26967 Likewise.
26968 * gimple-ssa-warn-restrict.c (builtin_memref::set_base_and_offset):
26969 Likewise.
26970
26971 2018-03-16 Vladimir Makarov <vmakarov@redhat.com>
26972
26973 PR target/84876
26974 * lra-assigns.c (lra_split_hard_reg_for): Don't use
26975 regno_allocno_class_array and sorted_pseudos.
26976 * lra-constraints.c (spill_hard_reg_in_range): Ignore hard regs in
26977 insns where regno is used.
26978
26979 2018-03-16 Martin Liska <mliska@suse.cz>
26980
26981 PR ipa/84833
26982 * multiple_target.c (create_dispatcher_calls): Redirect
26983 reference in the symbol table.
26984
26985 2018-03-16 Martin Liska <mliska@suse.cz>
26986
26987 PR ipa/84722
26988 * multiple_target.c (create_dispatcher_calls): Redirect also
26989 an alias.
26990
26991 2018-03-16 Jakub Jelinek <jakub@redhat.com>
26992
26993 PR c++/79937
26994 PR c++/82410
26995 * tree.h (TARGET_EXPR_NO_ELIDE): Define.
26996 * gimplify.c (gimplify_modify_expr_rhs): Don't elide TARGET_EXPRs with
26997 TARGET_EXPR_NO_ELIDE flag set unless *expr_p is INIT_EXPR.
26998
26999 2018-03-16 Julia Koval <julia.koval@intel.com>
27000
27001 * doc/invoke.texi (Skylake Server): Add CLWB.
27002 Cannonlake): Remove CLWB.
27003
27004 2018-03-16 Jakub Jelinek <jakub@redhat.com>
27005
27006 PR tree-optimization/84841
27007 * tree-ssa-reassoc.c (INTEGER_CONST_TYPE): Change to 1 << 4 from
27008 1 << 3.
27009 (FLOAT_ONE_CONST_TYPE): Define.
27010 (constant_type): Return FLOAT_ONE_CONST_TYPE for -1.0 and 1.0.
27011 (sort_by_operand_rank): Put entries with higher constant_type last
27012 rather than first to match comments.
27013
27014 2018-03-15 Sandra Loosemore <sandra@codesourcery.com>
27015
27016 * config/nios2/nios2.md (movsi_internal): Fix thinko in
27017 split predicate.
27018
27019 2018-03-15 Jakub Jelinek <jakub@redhat.com>
27020
27021 PR c++/79085
27022 * calls.c (expand_call): For TREE_ADDRESSABLE rettype ignore alignment
27023 check and use address of target always.
27024
27025 2018-03-15 H.J. Lu <hongjiu.lu@intel.com>
27026
27027 PR target/84574
27028 * config/i386/i386.c (indirect_thunk_needed): Update comments.
27029 (indirect_thunk_bnd_needed): Likewise.
27030 (indirect_thunks_used): Likewise.
27031 (indirect_thunks_bnd_used): Likewise.
27032 (indirect_return_needed): New.
27033 (indirect_return_bnd_needed): Likewise.
27034 (output_indirect_thunk_function): Add a bool argument for
27035 function return.
27036 (output_indirect_thunk_function): Don't generate alias for
27037 function return thunk.
27038 (ix86_code_end): Call output_indirect_thunk_function to generate
27039 function return thunks.
27040 (ix86_output_function_return): Set indirect_return_bnd_needed
27041 and indirect_return_needed instead of indirect_thunk_bnd_needed
27042 and indirect_thunk_needed.
27043
27044 2018-03-15 Olga Makhotina <olga.makhotina@intel.com>
27045
27046 * config/i386/sgxintrin.h (_enclv_u32): New intrinsic.
27047 (__enclv_bc, __enclv_cd, __enclv_generic): New definitions.
27048 (ERDINFO, ETRACKC, ELDBC, ELDUC): New leaves.
27049
27050 2018-03-15 David Malcolm <dmalcolm@redhat.com>
27051 Paul Hua <paul.hua.gm@gmail.com>
27052
27053 PR c/84852
27054 * gcc.dg/fixits-pr84852-1.c: Fix filename in dg-regexp.
27055
27056 2018-03-15 Segher Boessenkool <segher@kernel.crashing.org>
27057
27058 * config/rs6000/rs6000.c (abi_v4_pass_in_fpr): Add back the
27059 TARGET_DOUBLE_FLOAT and TARGET_SINGLE_FLOAT conditions on the DFmode
27060 resp. SFmode cases.
27061
27062 2018-03-15 Tamar Christina <tamar.christina@arm.com>
27063
27064 PR target/84711
27065 * config/arm/arm.c (arm_can_change_mode_class): Use GET_MODE_UNIT_SIZE
27066 instead of GET_MODE_SIZE when comparing Units.
27067
27068 2018-03-15 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
27069
27070 PR target/68256
27071 * varasm.c (hash_section): Return an unchangeble hash value
27072 * config/aarch64/aarch64.c (aarch64_use_blocks_for_constant_p):
27073 Return !aarch64_can_use_per_function_literal_pools_p ().
27074
27075 2018-03-15 Jakub Jelinek <jakub@redhat.com>
27076
27077 PR target/84860
27078 * optabs.c (emit_conditional_move): Pass address of cmode's copy
27079 rather than address of cmode as last argument to prepare_cmp_insn.
27080
27081 2018-03-15 Julia Koval <julia.koval@intel.com>
27082
27083 * config/i386/i386.c (F_AVX512VBMI2, F_GFNI, F_VPCLMULQDQ,
27084 F_AVX512VNNI, F_AVX512BITALG): New.
27085
27086 2018-03-14 John David Anglin <danglin@gcc.gnu.org>
27087
27088 PR target/83451
27089 * config/pa/pa.c (pa_emit_move_sequence): Always emit secondary reload
27090 insn for floating-point loads and stores.
27091
27092 2018-03-14 Carl Love <cel@us.ibm.com>
27093
27094 * config/rs6000/rs6000-c.c: Add macro definitions for
27095 ALTIVEC_BUILTIN_VEC_PERMXOR.
27096 * config/rs6000/rs6000.h: Add #define for vec_permxor builtin.
27097 * config/rs6000/rs6000-builtin.def: Add macro expansions for VPERMXOR.
27098 * config/rs6000/altivec.md (altivec_vpermxor): New define expand.
27099 * config/rs6000/rs6000-p8swap.c (rtx_is_swappable_p): Add case
27100 UNSPEC_VPERMXOR.
27101 * config/doc/extend.texi: Add prototypes for vec_permxor.
27102
27103 2018-03-14 David Malcolm <dmalcolm@redhat.com>
27104
27105 PR c/84852
27106 * diagnostic-show-locus.c (class layout_point): Convert m_line
27107 from int to linenum_type.
27108 (line_span::comparator): Use linenum "compare" function when
27109 comparing line numbers.
27110 (test_line_span): New function.
27111 (layout_range::contains_point): Convert param "row" from int to
27112 linenum_type.
27113 (layout_range::intersects_line_p): Likewise.
27114 (layout::will_show_line_p): Likewise.
27115 (layout::print_source_line): Likewise.
27116 (layout::should_print_annotation_line_p): Likewise.
27117 (layout::print_annotation_line): Likewise.
27118 (layout::print_leading_fixits): Likewise.
27119 (layout::annotation_line_showed_range_p): Likewise.
27120 (struct line_corrections): Likewise for field m_row.
27121 (line_corrections::line_corrections): Likewise for param "row".
27122 (layout::print_trailing_fixits): Likewise.
27123 (layout::get_state_at_point): Likewise.
27124 (layout::get_x_bound_for_row): Likewise.
27125 (layout::print_line): Likewise.
27126 (diagnostic_show_locus): Likewise for locals "last_line" and "row".
27127 (selftest::diagnostic_show_locus_c_tests): Call test_line_span.
27128 * input.c (selftest::test_linenum_comparisons): New function.
27129 (selftest::input_c_tests): Call it.
27130 * selftest.c (selftest::test_assertions): Test ASSERT_GT,
27131 ASSERT_GT_AT, ASSERT_LT, and ASSERT_LT_AT.
27132 * selftest.h (ASSERT_GT): New macro.
27133 (ASSERT_GT_AT): New macro.
27134 (ASSERT_LT): New macro.
27135 (ASSERT_LT_AT): New macro.
27136
27137 2018-03-14 Segher Boessenkool <segher@kernel.crashing.org>
27138
27139 PR rtl-optimization/84780
27140 * combine.c (distribute_links): Don't make a link based on pc_rtx.
27141
27142 2018-03-14 Martin Liska <mliska@suse.cz>
27143
27144 * tree.c (record_node_allocation_statistics): Use
27145 get_stats_node_kind.
27146 (get_stats_node_kind): New function extracted from
27147 record_node_allocation_statistics.
27148 (free_node): Use get_stats_node_kind.
27149
27150 2018-03-14 Richard Biener <rguenther@suse.de>
27151
27152 * tree-ssa-pre.c (compute_antic_aux): Remove code that asserts
27153 that the value-set of ANTIC_IN doesn't grow.
27154
27155 Revert
27156 * tree-ssa-pre.c (struct bb_bitmap_sets): Add visited_with_visited_succs
27157 member.
27158 (BB_VISITED_WITH_VISITED_SUCCS): New define.
27159 (compute_antic): Initialize BB_VISITED_WITH_VISITED_SUCCS.
27160
27161 2018-03-14 Julia Koval <julia.koval@intel.com>
27162
27163 * config.gcc (icelake-client, icelake-server): New.
27164 (icelake): Remove.
27165 * config/i386/i386.c (initial_ix86_tune_features): Extend to 64 bit.
27166 (initial_ix86_arch_features): Ditto.
27167 (PTA_SKYLAKE): Add SGX.
27168 (PTA_ICELAKE): Remove.
27169 (PTA_ICELAKE_CLIENT): New.
27170 (PTA_ICELAKE_SERVER): New.
27171 (ix86_option_override_internal): Split up icelake on icelake client and
27172 icelake server.
27173 (get_builtin_code_for_version): Ditto.
27174 (fold_builtin_cpu): Ditto.
27175 * config/i386/driver-i386.c (config/i386/driver-i386.c): Ditto.
27176 * config/i386/i386-c.c (ix86_target_macros_internal): Ditto
27177 * config/i386/i386.h (processor_type): Ditto.
27178 * doc/invoke.texi: Ditto.
27179
27180 2018-03-14 Jakub Jelinek <jakub@redhat.com>
27181
27182 PR sanitizer/83392
27183 * sanopt.c (maybe_optimize_ubsan_ptr_ifn): Handle also
27184 INTEGER_CST offset, add it together with bitpos / 8 and
27185 sign extend based on POINTER_SIZE.
27186
27187 PR target/84844
27188 Revert
27189 2017-04-20 Uros Bizjak <ubizjak@gmail.com>
27190
27191 PR target/78090
27192 * config/i386/constraints.md (Yc): New register constraint.
27193 * config/i386/i386.md (*float<SWI48:mode><MODEF:mode>2_mixed):
27194 Use Yc constraint for alternative 2 of operand 0. Remove
27195 preferred_for_speed attribute.
27196
27197 2018-03-14 Richard Biener <rguenther@suse.de>
27198
27199 PR tree-optimization/84830
27200 * tree-ssa-pre.c (compute_antic_aux): Intersect the new ANTIC_IN
27201 with the old one to avoid oscillations.
27202
27203 2018-03-13 Vladimir Makarov <vmakarov@redhat.com>
27204
27205 PR target/83712
27206 * lra-assigns.c (find_all_spills_for): Ignore uninteresting
27207 pseudos.
27208 (assign_by_spills): Return a flag of reload assignment failure.
27209 Do not process the reload assignment failures. Do not spill other
27210 reload pseudos if they has the same reg class. Update n if
27211 necessary.
27212 (lra_assign): Add a return arg. Set up from the result of
27213 assign_by_spills call.
27214 (find_reload_regno_insns, lra_split_hard_reg_for): New functions.
27215 * lra-constraints.c (split_reg): Add a new arg. Use it instead of
27216 usage_insns if it is not NULL.
27217 (spill_hard_reg_in_range): New function.
27218 (split_if_necessary, inherit_in_ebb): Pass a new arg to split_reg.
27219 * lra-int.h (spill_hard_reg_in_range, lra_split_hard_reg_for): New
27220 function prototypes.
27221 (lra_assign): Change prototype.
27222 * lra.c (lra): Add code to deal with fails by splitting hard reg
27223 live ranges.
27224
27225 2018-03-01 Palmer Dabbelt <palmer@sifive.com>
27226
27227 * config/riscv/riscv.opt (mrelax): New option.
27228 * config/riscv/riscv.c (riscv_file_start): Emit ".option
27229 "norelax" when riscv_mrelax is disabled.
27230 * doc/invoke.texi (RISC-V): Document "-mrelax" and "-mno-relax".
27231
27232 2018-03-13 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
27233
27234 PR target/84743
27235 * config/rs6000/rs6000.c (rs6000_reassociation_width): Disable parallel
27236 reassociation for int modes.
27237
27238 2018-03-13 Richard Sandiford <richard.sandiford@linaro.org>
27239
27240 * tree-vect-loop-manip.c (vect_maybe_permute_loop_masks):
27241 Reverse the choice between VEC_UNPACK_LO_EXPR and VEC_UNPACK_HI_EXPR
27242 for big-endian.
27243 * config/aarch64/iterators.md (hi_lanes_optab): New int attribute.
27244 * config/aarch64/aarch64-sve.md
27245 (*aarch64_sve_<perm_insn><perm_hilo><mode>): Rename to...
27246 (aarch64_sve_<perm_insn><perm_hilo><mode>): ...this.
27247 (*extend<mode><Vwide>2): Rename to...
27248 (aarch64_sve_extend<mode><Vwide>2): ...this.
27249 (vec_unpack<su>_<perm_hilo>_<mode>): Turn into a define_expand,
27250 renaming the old pattern to...
27251 (aarch64_sve_punpk<perm_hilo>_<mode>): ...this. Only define
27252 unsigned packs.
27253 (vec_unpack<su>_<perm_hilo>_<SVE_BHSI:mode>): Turn into a
27254 define_expand, renaming the old pattern to...
27255 (aarch64_sve_<su>unpk<perm_hilo>_<SVE_BHSI:mode>): ...this.
27256 (*vec_unpacku_<perm_hilo>_<mode>_no_convert): Delete.
27257 (vec_unpacks_<perm_hilo>_<mode>): Take BYTES_BIG_ENDIAN into
27258 account when deciding which SVE instruction the optab should use.
27259 (vec_unpack<su_optab>_float_<perm_hilo>_vnx4si): Likewise.
27260
27261 2018-03-13 Richard Sandiford <richard.sandiford@linaro.org>
27262
27263 * config/aarch64/aarch64.md (V4_REGNUM, V8_REGNUM, V12_REGNUM)
27264 (V20_REGNUM, V24_REGNUM, V28_REGNUM, P1_REGNUM, P2_REGNUM, P3_REGNUM)
27265 (P4_REGNUM, P5_REGNUM, P6_REGNUM, P8_REGNUM, P9_REGNUM, P10_REGNUM)
27266 (P11_REGNUM, P12_REGNUM, P13_REGNUM, P14_REGNUM): New define_constants.
27267 (tlsdesc_small_<mode>): Turn a define_expand and use
27268 tlsdesc_small_sve_<mode> for SVE. Rename original define_insn to...
27269 (tlsdesc_small_advsimd_<mode>): ...this.
27270 (tlsdesc_small_sve_<mode>): New pattern.
27271
27272 2018-03-13 Richard Sandiford <richard.sandiford@linaro.org>
27273
27274 * config/aarch64/iterators.md (UNSPEC_SMUL_HIGHPART)
27275 (UNSPEC_UMUL_HIGHPART): New constants.
27276 (MUL_HIGHPART): New int iteraor.
27277 (su): Handle UNSPEC_SMUL_HIGHPART and UNSPEC_UMUL_HIGHPART.
27278 * config/aarch64/aarch64-sve.md (<su>mul<mode>3_highpart): New
27279 define_expand.
27280 (*<su>mul<mode>3_highpart): New define_insn.
27281
27282 2018-03-13 Eric Botcazou <ebotcazou@adacore.com>
27283
27284 PR lto/84805
27285 * ipa-devirt.c (odr_subtypes_equivalent_p): Do not get the ODR type of
27286 incomplete types.
27287
27288 2018-03-13 Martin Liska <mliska@suse.cz>
27289
27290 PR ipa/84658.
27291 * (sem_item_optimizer::sem_item_optimizer): Initialize new
27292 vector.
27293 (sem_item_optimizer::~sem_item_optimizer): Release it.
27294 (sem_item_optimizer::merge_classes): Register variable aliases.
27295 (sem_item_optimizer::fixup_pt_set): New function.
27296 (sem_item_optimizer::fixup_points_to_sets): Likewise.
27297 * ipa-icf.h: Declare new variables and functions.
27298
27299 2018-03-13 Jakub Jelinek <jakub@redhat.com>
27300
27301 PR middle-end/84834
27302 * match.pd ((A & C) != 0 ? D : 0): Use INTEGER_CST@2 instead of
27303 integer_pow2p@2 and test integer_pow2p in condition.
27304 (A < 0 ? C : 0): Similarly for @1.
27305
27306 PR middle-end/84831
27307 * stmt.c (parse_output_constraint): If the CONSTRAINT_LEN (*p, p)
27308 characters starting at p contain '\0' character, don't look beyond
27309 that.
27310
27311 PR target/84827
27312 * config/i386/i386.md (round<mode>2): For 387 fancy math, disable
27313 pattern if -ftrapping-math -fno-fp-int-builtin-inexact.
27314
27315 PR target/84828
27316 * reg-stack.c (change_stack): Change update_end var from int to
27317 rtx_insn *, if non-NULL don't update just BB_END (current_block), but
27318 also call set_block_for_insn on the newly added insns and rescan.
27319
27320 PR target/84786
27321 * config/i386/sse.md (sse2_loadhpd): Use Yv constraint rather than v
27322 on the last operand.
27323
27324 PR c++/84704
27325 * tree.c (stabilize_reference_1): Return save_expr (e) for
27326 STATEMENT_LIST even if it doesn't have side-effects.
27327
27328 2018-03-12 Jonathan Wakely <jwakely@redhat.com>
27329
27330 * doc/invoke.texi (-mclflushopt): Fix spelling of option.
27331
27332 2018-03-12 Renlin Li <renlin.li@arm.com>
27333
27334 * config/aarch64/aarch64.md (movhf_aarch64): Fix mode argument to
27335 aarch64_output_scalar_simd_mov_immediate.
27336
27337 2018-03-12 Martin Sebor <msebor@redhat.com>
27338
27339 PR tree-optimization/83456
27340 * gimple-fold.c (gimple_fold_builtin_memory_op): Avoid warning
27341 for perfectly overlapping calls to memcpy.
27342 (gimple_fold_builtin_memory_chk): Same.
27343 (gimple_fold_builtin_strcpy): Handle no-warning.
27344 (gimple_fold_builtin_stxcpy_chk): Same.
27345 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Handle no-warning.
27346
27347 2018-03-12 Segher Boessenkool <segher@kernel.crashing.org>
27348
27349 * config/rs6000/rs6000.c (abi_v4_pass_in_fpr): Add bool "named"
27350 parameter. Use it for SFmode.
27351 (rs6000_function_arg_advance_1): Adjust.
27352 (rs6000_function_arg): Adjust.
27353 (rs6000_gimplify_va_arg): Pass false for that new parameter.
27354
27355 2018-03-12 Segher Boessenkool <segher@kernel.crashing.org>
27356
27357 PR rtl-optimization/84169
27358 PR rtl-optimization/84780
27359 * combine.c (can_combine_p): Check for a 2-insn combination whether
27360 the destination register is used between the two insns, too.
27361
27362 2018-03-12 Richard Biener <rguenther@suse.de>
27363
27364 PR tree-optimization/84803
27365 * tree-if-conv.c (ifcvt_memrefs_wont_trap): Don't do anything
27366 for refs DR analysis didn't process.
27367
27368 2018-03-12 Richard Biener <rguenther@suse.de>
27369
27370 PR tree-optimization/84777
27371 * tree-ssa-loop-ch.c (should_duplicate_loop_header_p): For
27372 force-vectorize loops ignore whether we are optimizing for size.
27373
27374 2018-03-12 Chung-Ju Wu <jasonwucj@gmail.com>
27375
27376 * config/nds32/nds32.c (nds32_md_asm_adjust): New function.
27377 (TARGET_MD_ASM_ADJUST): Define.
27378
27379 2018-03-12 Monk Chiang <sh.chiang04@gmail.com>
27380 Kito Cheng <kito.cheng@gmail.com>
27381 Chung-Ju Wu <jasonwucj@gmail.com>
27382
27383 * config/nds32/nds32.c (nds32_compute_stack_frame,
27384 nds32_emit_stack_push_multiple, nds32_emit_stack_pop_multiple,
27385 nds32_emit_stack_v3push, nds32_emit_stack_v3pop,
27386 nds32_emit_adjust_frame, nds32_expand_prologue, nds32_expand_epilogue,
27387 nds32_expand_prologue_v3push, nds32_expand_epilogue_v3pop): Refine.
27388 * config/nds32/nds32.h (NDS32_FIRST_CALLEE_SAVE_GPR_REGNUM,
27389 NDS32_LAST_CALLEE_SAVE_GPR_REGNUM, NDS32_V3PUSH_AVAILABLE_P): New.
27390 * config/nds32/nds32.md (prologue, epilogue): Use macro
27391 NDS32_V3PUSH_AVAILABLE_P to do checking.
27392
27393 2018-03-11 Jakub Jelinek <jakub@redhat.com>
27394
27395 PR debug/58150
27396 * dwarf2out.c (gen_enumeration_type_die): Don't guard adding
27397 DW_AT_declaration for ENUM_IS_OPAQUE on -gdwarf-4 or -gno-strict-dwarf,
27398 but on TYPE_SIZE. Don't do anything for ENUM_IS_OPAQUE if not creating
27399 a new die. Don't set TREE_ASM_WRITTEN if ENUM_IS_OPAQUE. Guard
27400 addition of most attributes on !orig_type_die or the attribute not
27401 being present already. Assert TYPE_VALUES is NULL for ENUM_IS_OPAQUE.
27402
27403 2018-03-11 Kito Cheng <kito.cheng@gmail.com>
27404 Chung-Ju Wu <jasonwucj@gmail.com>
27405
27406 * config/nds32/nds32.c (nds32_cpu_cpp_builtins): Modify to define
27407 __NDS32_VH__ macro.
27408 * config/nds32/nds32.opt (mvh): New option.
27409
27410 2018-03-11 Kito Cheng <kito.cheng@gmail.com>
27411 Chung-Ju Wu <jasonwucj@gmail.com>
27412
27413 * config/nds32/nds32-protos.h (nds32_cpu_cpp_builtins): Declare
27414 function.
27415 * config/nds32/nds32.c (nds32_cpu_cpp_builtins): New function.
27416 * config/nds32/nds32.h (TARGET_CPU_CPP_BUILTINS): Modify its
27417 definition.
27418
27419 2018-03-11 Kito Cheng <kito.cheng@gmail.com>
27420 Chung-Ju Wu <jasonwucj@gmail.com>
27421
27422 * config/nds32/nds32-memory-manipulation.c (nds32_expand_strlen): New
27423 function.
27424 * config/nds32/nds32-multiple.md (strlensi): New pattern.
27425 * config/nds32/nds32-protos.h (nds32_expand_strlen): Declare function.
27426
27427 2018-03-11 Monk Chiang <sh.chiang04@gmail.com>
27428 Kito Cheng <kito.cheng@gmail.com>
27429 Chung-Ju Wu <jasonwucj@gmail.com>
27430
27431 * config/nds32/constants.md (unspec_element): Add UNSPEC_FFB,
27432 UNSPEC_FFMISM and UNSPEC_FLMISM.
27433 * config/nds32/nds32-intrinsic.c (bdesc_2arg): Add builtin description
27434 for ffb, ffmism and flmism.
27435 * config/nds32/nds32-intrinsic.md (unspec_ffb): Define new pattern.
27436 (unspec_ffmism): Ditto.
27437 (unspec_flmism): Ditto.
27438 (nds32_expand_builtin_impl): Check if string extension is available.
27439 * config/nds32/nds32.h (nds32_builtins): Add NDS32_BUILTIN_FFB,
27440 NDS32_BUILTIN_FFMISM and NDS32_BUILTIN_FLMISM.
27441
27442 2018-03-10 Vladimir Makarov <vmakarov@redhat.com>
27443
27444 Reverting patch:
27445 2018-03-09 Vladimir Makarov <vmakarov@redhat.com>
27446
27447 PR target/83712
27448 * lra-assigns.c (assign_by_spills): Return a flag of reload
27449 assignment failure. Do not process the reload assignment
27450 failures. Do not spill other reload pseudos if they has the same
27451 reg class.
27452 (lra_assign): Add a return arg. Set up from the result of
27453 assign_by_spills call.
27454 (find_reload_regno_insns, lra_split_hard_reg_for): New functions.
27455 * lra-constraints.c (split_reg): Add a new arg. Use it instead of
27456 usage_insns if it is not NULL.
27457 (spill_hard_reg_in_range): New function.
27458 (split_if_necessary, inherit_in_ebb): Pass a new arg to split_reg.
27459 * lra-int.h (spill_hard_reg_in_range, lra_split_hard_reg_for): New
27460 function prototypes.
27461 (lra_assign): Change prototype.
27462 * lra.c (lra): Add code to deal with fails by splitting hard reg
27463 live ranges.
27464
27465 2018-03-10 H.J. Lu <hongjiu.lu@intel.com>
27466
27467 PR target/84807
27468 * config/i386/i386.opt: Replace Enforcment with Enforcement.
27469
27470 2018-03-10 Alexandre Oliva <aoliva@redhat.com>
27471
27472 PR debug/84620
27473 * dwarf2out.h (dw_val_class): Add dw_val_class_symview.
27474 (dw_val_node): Add val_symbolic_view.
27475 * dwarf2out.c (dw_line_info_table): Add symviews_since_reset.
27476 (symview_upper_bound): New.
27477 (new_line_info_table): Initialize symviews_since_reset.
27478 (dwarf2out_source_line): Count symviews_since_reset and set
27479 symview_upper_bound.
27480 (dw_val_equal_p): Handle symview.
27481 (add_AT_symview): New.
27482 (print_dw_val): Handle symview.
27483 (attr_checksum, attr_checksum_ordered): Likewise.
27484 (same_dw_val_p, size_of_die): Likewise.
27485 (value_format, output_die): Likewise.
27486 (add_high_low_attributes): Use add_AT_symview for entry_view.
27487 (dwarf2out_finish): Reset symview_upper_bound, clear
27488 zero_view_p.
27489
27490 2018-03-09 Peter Bergner <bergner@vnet.ibm.com>
27491
27492 PR target/83969
27493 * config/rs6000/rs6000.c (rs6000_offsettable_memref_p): New prototype.
27494 Add strict argument and use it.
27495 (rs6000_split_multireg_move): Update for new strict argument.
27496 (mem_operand_gpr): Disallow all non-offsettable addresses.
27497 * config/rs6000/rs6000.md (*movdi_internal64): Use YZ constraint.
27498
27499 2018-03-09 Jakub Jelinek <jakub@redhat.com>
27500
27501 PR target/84772
27502 * config/rs6000/rs6000.c (rs6000_gimplify_va_arg): Mark va_arg_tmp
27503 temporary TREE_ADDRESSABLE before gimplification of BUILT_IN_MEMCPY.
27504 * config/powerpcspe/powerpcspe.c (rs6000_gimplify_va_arg): Likewise.
27505
27506 PR c++/84767
27507 * tree-inline.c (copy_tree_body_r): For INDIRECT_REF of a remapped
27508 decl, use remap_type if we want to use the type.
27509
27510 2018-03-09 Martin Sebor <msebor@redhat.com>
27511
27512 PR tree-optimization/84526
27513 * gimple-ssa-warn-restrict.c (builtin_memref::set_base_and_offset):
27514 Remove dead code.
27515 (builtin_access::generic_overlap): Be prepared to handle non-array
27516 base objects.
27517
27518 2018-03-09 Alexandre Oliva <aoliva@redhat.com>
27519
27520 PR rtl-optimization/84682
27521 * lra-constraints.c (process_address_1): Check is_address flag
27522 for address constraints.
27523 (process_alt_operands): Likewise.
27524 * lra.c (lra_set_insn_recog_data): Pass asm operand locs to
27525 preprocess_constraints.
27526 * recog.h (preprocess_constraints): Add oploc parameter.
27527 Adjust callers.
27528 * recog.c (preprocess_constraints): Test address_operand for
27529 CT_ADDRESS constraints.
27530
27531 2018-03-09 Vladimir Makarov <vmakarov@redhat.com>
27532
27533 PR target/83712
27534 * lra-assigns.c (assign_by_spills): Return a flag of reload
27535 assignment failure. Do not process the reload assignment
27536 failures. Do not spill other reload pseudos if they has the same
27537 reg class.
27538 (lra_assign): Add a return arg. Set up from the result of
27539 assign_by_spills call.
27540 (find_reload_regno_insns, lra_split_hard_reg_for): New functions.
27541 * lra-constraints.c (split_reg): Add a new arg. Use it instead of
27542 usage_insns if it is not NULL.
27543 (spill_hard_reg_in_range): New function.
27544 (split_if_necessary, inherit_in_ebb): Pass a new arg to split_reg.
27545 * lra-int.h (spill_hard_reg_in_range, lra_split_hard_reg_for): New
27546 function prototypes.
27547 (lra_assign): Change prototype.
27548 * lra.c (lra): Add code to deal with fails by splitting hard reg
27549 live ranges.
27550
27551 2018-03-09 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
27552
27553 PR target/83193
27554 * common/config/arm/arm-common.c (arm_parse_arch_option_name):
27555 Accept complain bool parameter. Only emit errors if it is true.
27556 (arm_parse_cpu_option_name): Likewise.
27557 (arm_target_thumb_only): Adjust callers of the above.
27558 * config/arm/arm-protos.h (arm_parse_cpu_option_name): Adjust
27559 prototype to take a default true bool parameter.
27560 (arm_parse_arch_option_name): Likewise.
27561
27562 2018-03-09 David Malcolm <dmalcolm@redhat.com>
27563 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
27564
27565 PR jit/64089
27566 PR jit/84288
27567 * Makefile.in (LD_VERSION_SCRIPT_OPTION, LD_SONAME_OPTION): New.
27568 * configure: Regenerate.
27569 * configure.ac ("linker --version-script option"): New.
27570 ("linker soname option"): New.
27571
27572 2018-03-09 Richard Biener <rguenther@suse.de>
27573
27574 PR tree-optimization/84775
27575 * tree-if-conv.c (add_bb_predicate_gimplified_stmts): Delink
27576 immediate uses of predicate stmts and mark them modified.
27577
27578 Revert
27579 PR tree-optimization/84178
27580 * tree-if-conv.c (combine_blocks): Move insert_gimplified_predicates
27581 to caller.
27582 (version_loop_for_if_conversion): Delay update_ssa call.
27583 (tree_if_conversion): Delay update_ssa until after predicate
27584 insertion.
27585
27586 2018-03-09 Eric Botcazou <ebotcazou@adacore.com>
27587
27588 PR target/84763
27589 * config/i386/winnt.c (i386_pe_seh_cold_init): Use small pre-allocation
27590 when the function accesses prior frames.
27591
27592 2018-03-08 Jakub Jelinek <jakub@redhat.com>
27593
27594 PR debug/84456
27595 * dwarf2out.c (dw_loc_list): If list && loc_list->first->next, call
27596 gen_llsym, otherwise call maybe_gen_llsym.
27597
27598 PR inline-asm/84742
27599 * recog.c (asm_operand_ok): Return 0 if multi-character constraint
27600 has ',' character inside of it.
27601
27602 2018-03-08 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
27603
27604 PR target/84748
27605 * config/aarch64/aarch64.md (*compare_cstore<mode>_insn): Mark pattern
27606 as clobbering CC_REGNUM.
27607
27608 2018-03-08 Richard Biener <rguenther@suse.de>
27609
27610 PR middle-end/84552
27611 * tree-scalar-evolution.c: Include tree-into-ssa.h.
27612 (follow_copies_to_constant): Do not follow SSA names registered
27613 for update.
27614
27615 2018-03-08 Richard Biener <rguenther@suse.de>
27616
27617 PR tree-optimization/84178
27618 * tree-if-conv.c (combine_blocks): Move insert_gimplified_predicates
27619 to caller.
27620 (version_loop_for_if_conversion): Delay update_ssa call.
27621 (tree_if_conversion): Delay update_ssa until after predicate
27622 insertion.
27623
27624 2018-03-08 David Malcolm <dmalcolm@redhat.com>
27625
27626 PR tree-optimization/84178
27627 * tree-if-conv.c (release_bb_predicate): Remove the
27628 the assertion that the stmts have NULL use_ops.
27629 Discard the statements, asserting that they haven't
27630 yet been added to a BB.
27631
27632 2018-03-08 Richard Biener <rguenther@suse.de>
27633
27634 PR tree-optimization/84746
27635 * tree-ssa-pre.c (find_leader_in_sets): Deal with SET1 being NULL.
27636 (phi_translate): Pass in destination ANTIC_OUT set.
27637 (phi_translate_1): Likewise. For a simplified result lookup
27638 a leader in ANTIC_OUT and AVAIL_OUT, not the ANTIC_IN sets.
27639 (phi_translate_set): Adjust.
27640 (do_pre_regular_insertion): Likewise.
27641 (do_pre_partial_partial_insertion): Likewise.
27642
27643 2018-03-08 Martin Liska <mliska@suse.cz>
27644
27645 PR gcov-profile/84735
27646 * doc/gcov.texi: Document usage of profile files.
27647 * gcov-io.h: Document changes in the format.
27648
27649 2018-03-08 Alexandre Oliva <aoliva@redhat.com>
27650
27651 PR debug/84404
27652 PR debug/84408
27653 * dwarf2out.c (struct dw_line_info_table): Update comments for
27654 view == -1.
27655 (FORCE_RESET_NEXT_VIEW): New.
27656 (FORCE_RESETTING_VIEW_P): New.
27657 (RESETTING_VIEW_P): Check for -1 too.
27658 (ZERO_VIEW_P): Likewise.
27659 (new_line_info_table): Force-reset next view.
27660 (dwarf2out_begin_function): Likewise.
27661 (dwarf2out_source_line): Simplify zero_view_p initialization.
27662 Test FORCE_RESETTING_VIEW_P and RESETTING_VIEW_P instead of
27663 view directly. Omit view when omitting .loc at line 0.
27664
27665 2018-03-08 Jakub Jelinek <jakub@redhat.com>
27666
27667 PR tree-optimization/84740
27668 * tree-switch-conversion.c (process_switch): Call build_constructors
27669 only if info.phi_count is non-zero.
27670
27671 PR tree-optimization/84739
27672 * tree-tailcall.c (find_tail_calls): Check call arguments against
27673 DECL_ARGUMENTS (current_function_decl) rather than
27674 DECL_ARGUMENTS (func) when checking for tail recursion.
27675
27676 2018-03-07 Jakub Jelinek <jakub@redhat.com>
27677
27678 * doc/contrib.texi: Add entries for Martin Liska, David Malcolm,
27679 Marek Polacek, extend Vladimir Makarov's, Jonathan Wakely's and
27680 Volker Reichelt's entry and add entries for people that perform
27681 GCC fuzzy testing and report numerous bugs.
27682
27683 2018-03-07 Segher Boessenkool <segher@kernel.crashing.org>
27684
27685 PR target/82411
27686 * config/rs6000/rs6000.c (rs6000_elf_in_small_data_p): Don't put
27687 readonly data in sdata, if that is disabled.
27688 * config/rs6000/sysv4.opt (mreadonly-in-sdata): New option.
27689 * doc/invoke.texi (RS/6000 and PowerPC Options): Document
27690 -mreadonly-in-sdata option.
27691
27692 2018-03-07 Martin Sebor <msebor@redhat.com>
27693
27694 PR tree-optimization/84468
27695 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Consider successor
27696 basic block when looking for nul assignment.
27697
27698 2018-03-07 Eric Botcazou <ebotcazou@adacore.com>
27699
27700 PR target/84277
27701 * except.h (output_function_exception_table): Adjust prototype.
27702 * except.c (output_function_exception_table): Remove FNNAME parameter
27703 and add SECTION parameter. Ouput one part of the table at a time.
27704 * final.c (final_scan_insn_1) <NOTE_INSN_SWITCH_TEXT_SECTIONS>: Output
27705 the first part of the exception table and emit unwind directives.
27706 * config/i386/i386-protos.h (i386_pe_end_cold_function): Declare.
27707 (i386_pe_seh_cold_init): Likewise.
27708 * config/i386/cygming.h (ASM_DECLARE_COLD_FUNCTION_NAME): New macro.
27709 (ASM_DECLARE_COLD_FUNCTION_SIZE): Likewise.
27710 * config/i386/i386.c (x86_expand_epilogue): Fix wording in comment.
27711 (ix86_output_call_insn): Emit a nop in one more case for SEH.
27712 * config/i386/winnt.c: Include except.h.
27713 (struct seh_frame_state): Add reg_offset, after_prologue and
27714 in_cold_section fields.
27715 (i386_pe_seh_end_prologue): Set seh->after_prologue.
27716 (i386_pe_seh_cold_init): New function.
27717 (i386_pe_seh_fini): Add COLD parameter and bail out if it is not equal
27718 to seh->in_cold_section.
27719 (seh_emit_push): Record the offset of the push.
27720 (seh_emit_save): Record the offet of the save.
27721 (i386_pe_seh_unwind_emit): Deal with NOTE_INSN_SWITCH_TEXT_SECTIONS.
27722 Test seh->after_prologue to disregard the epilogue.
27723 (i386_pe_end_function): Pass FALSE to i386_pe_seh_fini.
27724 (i386_pe_end_cold_function): New function.
27725
27726 2018-03-07 Jakub Jelinek <jakub@redhat.com>
27727
27728 PR fortran/84565
27729 * config/aarch64/predicates.md (aarch64_simd_reg_or_zero): Use
27730 aarch64_simd_or_scalar_imm_zero rather than aarch64_simd_imm_zero.
27731
27732 PR c++/84704
27733 * gimple-expr.c (create_tmp_var_raw): Set DECL_NAMELESS flag
27734 on tmp_var.
27735 * tree-pretty-print.c (dump_decl_name): For TDF_COMPARE_DEBUG,
27736 don't print names of DECL_NAMELESS DECL_IGNORED_P decls.
27737
27738 PR middle-end/84723
27739 * multiple_target.c: Include tree-inline.h and intl.h.
27740 (expand_target_clones): Diagnose and fail if node->definition and
27741 !tree_versionable_function_p (node->decl).
27742
27743 2018-03-06 John David Anglin <danglin@gcc.gnu.org>
27744
27745 * config/pa/pa.h (ASM_GENERATE_INTERNAL_LABEL): Revise to use
27746 sprint_ul.
27747 (ASM_OUTPUT_ADDR_VEC_ELT): Revise for above change.
27748 (ASM_OUTPUT_ADDR_DIFF_ELT): Likewise.
27749 * config/pa/pa64-hpux.h (ASM_GENERATE_INTERNAL_LABEL): Revise as above.
27750
27751 2018-03-06 Jakub Jelinek <jakub@redhat.com>
27752
27753 PR target/84710
27754 * combine.c (try_combine): Use reg_or_subregno instead of handling
27755 just paradoxical SUBREGs and REGs.
27756
27757 2018-03-06 Claudiu Zissulescu <claziss@synopsys.com>
27758
27759 * config/arc/arc.c (arc_finalize_pic): Remove function.
27760 (arc_must_save_register): We use single base PIC register, remove
27761 checks to save/restore the PIC register.
27762 (arc_expand_prologue): Likewise.
27763 * config/arc/arc-protos.h (arc_set_default_type_attributes):
27764 Remove.
27765 (arc_verify_short): Likewise.
27766 (arc_attr_type): Likewise.
27767 * config/arc/arc.c (arc_set_default_type_attributes): Remove.
27768 (walk_stores): Likewise.
27769 (arc_address_cost): Make it static.
27770 (arc_verify_short): Likewise.
27771 (branch_dest): Likewise.
27772 (arc_attr_type): Likewise.
27773 * config/arc/arc.c (TARGET_ADJUST_INSN_LENGTH): Remove.
27774 (TARGET_INSN_LENGTH_PARAMETERS): Likewise.
27775 (arc_final_prescan_insn): Remove inserting the nops due to
27776 hardware hazards. It is done in reorg step.
27777 (insn_length_variant_t): Remove.
27778 (insn_length_parameters_t): Likewise.
27779 (arc_insn_length_parameters): Likewise.
27780 (arc_get_insn_variants): Likewise.
27781 * config/arc/arc.h (TARGET_UPSIZE_DBR): Remove.
27782
27783 2018-03-06 Jakub Jelinek <jakub@redhat.com>
27784
27785 PR inline-asm/84683
27786 * reg-stack.c (move_for_stack_reg): If any_malformed_asm, avoid
27787 assertion failure.
27788
27789 PR tree-optimization/84687
27790 * omp-simd-clone.c (simd_clone_create): Clear DECL_BUILT_IN_CLASS
27791 on new_node->decl.
27792 * match.pd (pow(C,x)*expN(y) -> expN(logN(C)*x+y)): New optimization.
27793
27794 2018-03-05 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
27795
27796 * config/rs6000/rs6000-builtin.def (rs6000_speculation_barrier):
27797 Rename to ppc_speculation_barrier.
27798 * config/rs6000/rs6000.c (rs6000_init_builtins): Rename builtin to
27799 __builtin_ppc_speculation_barrier.
27800
27801 2018-03-05 Jakub Jelinek <jakub@redhat.com>
27802
27803 PR target/84700
27804 * combine.c (combine_simplify_rtx): Don't try to simplify if
27805 if_then_else_cond returned non-NULL, but either true_rtx or false_rtx
27806 are equal to x.
27807
27808 2018-03-05 Segher Boessenkool <segher@kernel.crashing.org>
27809
27810 * config/rs6000/rs6000.c (rs6000_loop_align): Don't align tiny loops
27811 to 32 bytes when compiling for POWER9.
27812
27813 2018-03-05 Jakub Jelinek <jakub@redhat.com>
27814
27815 PR target/84564
27816 * config/i386/i386.c (ix86_function_ok_for_sibcall): Check for
27817 regparm >= 3 with no arg reg available also for calls with
27818 flag_force_indirect_call. Pass decl to ix86_function_regparm.
27819
27820 PR target/84524
27821 * config/i386/sse.md (*<code><mode>3): Replace <mask_prefix3> with
27822 orig,vex.
27823 (*<plusminus_insn><mode>3): Likewise. Remove <mask_operand3> uses.
27824
27825 2018-03-05 Peter Bergner <bergner@vnet.ibm.com>
27826
27827 PR target/84264
27828 * config/rs6000/vector.md (mov<mode>): Disallow altivec memory operands.
27829
27830 2018-03-05 Richard Biener <rguenther@suse.de>
27831
27832 PR tree-optimization/84486
27833 * tree-ssa-pre.c (create_expression_by_pieces): Remove dead code.
27834 When inserting a __builtin_assume_aligned call set the LHS
27835 SSA name alignment info accordingly.
27836
27837 2018-03-05 Wilco Dijkstra <wdijkstr@arm.com>
27838
27839 PR tree-optimization/84114
27840 * config/aarch64/aarch64.c (aarch64_reassociation_width)
27841 Avoid reassociation of FLOAT_MODE addition.
27842
27843 2018-03-05 Olga Makhotina <olga.makhotina@intel.com>
27844
27845 * common/config/i386/i386-common.c (OPTION_MASK_ISA_PCONFIG_SET,
27846 OPTION_MASK_ISA_PCONFIG_UNSET, OPTION_MASK_ISA_WBNOINVD_SET,
27847 OPTION_MASK_ISA_WBNOINVD_UNSET): New definitions.
27848 (ix86_handle_option): Handle -mpconfig and -mwbnoinvd.
27849 * config.gcc (pconfigintrin.h, wbnoinvdintrin.h) : Add headers.
27850 * config/i386/cpuid.h (bit_PCONFIG, bit_WBNOINVD): New.
27851 * config/i386/driver-i386.c (host_detect_local_cpu): Detect -mpconfig
27852 and -mwbnoinvd.
27853 * config/i386/i386-builtin.def (__builtin_ia32_wbnoinvd,
27854 __builtin_ia32_wbinvd): New builtins.
27855 (SPECIAL_ARGS2): New.
27856 * config/i386/i386-c.c (__WBNOINVD__, __PCONFIG__): New.
27857 (SPECIAL_ARGS2): New.
27858 * config/i386/i386.c (ix86_target_string): Add -mpconfig and -mwbnoinvd.
27859 (ix86_valid_target_attribute_inner_p): Ditto.
27860 (ix86_init_mmx_sse_builtins): Add special_args2.
27861 * config/i386/i386.h (TARGET_PCONFIG, TARGET_PCONFIG_P, TARGET_WBNOINVD,
27862 TARGET_WBNOINVD_P): New.
27863 * config/i386/i386.md (UNSPECV_WBINVD, UNSPECV_WBNOINVD): New.
27864 (define_insn "wbinvd", define_insn "wbnoinvd"): New.
27865 * config/i386/i386.opt: Add -mpconfig and -mwbnoinvd.
27866 * config/i386/immintrin.h (_wbinvd): New intrinsic.
27867 * config/i386/pconfigintrin.h: New file.
27868 * config/i386/wbnoinvdintrin.h: Ditto.
27869 * config/i386/x86intrin.h: Add headers pconfigintrin.h and
27870 wbnoinvdintrin.h.
27871 * doc/invoke.texi (-mpconfig, -mwbnoinvd): New.
27872
27873 2018-03-05 Richard Biener <rguenther@suse.de>
27874
27875 PR tree-optimization/84670
27876 * tree-ssa-pre.c (struct bb_bitmap_sets): Add visited_with_visited_succs
27877 member.
27878 (BB_VISITED_WITH_VISITED_SUCCS): New define.
27879 (compute_antic): Initialize BB_VISITED_WITH_VISITED_SUCCS.
27880 (compute_antic_aux): Only assert the number of values in ANTIC_IN
27881 doesn't grow if all successors (recursively) were visited at least
27882 once.
27883
27884 2018-03-05 Richard Biener <rguenther@suse.de>
27885
27886 PR tree-optimization/84650
27887 * tree-ssa-loop-im.c (pass_lim::execute): Reset the SCEV cache
27888 if executed in the loop pipeline.
27889
27890 2018-03-05 Sandra Loosemore <sandra@codesourcery.com>
27891
27892 * doc/configfiles.texi (Configuration Files): Move info about
27893 conditionalizing $target-protos.h to...
27894 * doc/sourcebuild.texi (Back End): Here. Explain how $target.h
27895 differs from $target-protos.h.
27896
27897 2018-03-05 Kito Cheng <kito.cheng@gmail.com>
27898 Chung-Ju Wu <jasonwucj@gmail.com>
27899
27900 * config/nds32/nds32-protos.h (nds32_expand_setmem): Declare.
27901 * config/nds32/nds32-multiple.md (setmemsi): Define.
27902 * config/nds32/nds32-memory-manipulation.c
27903 (nds32_gen_dup_4_byte_to_word_value): New.
27904 (emit_setmem_word_loop): New.
27905 (emit_setmem_byte_loop): New.
27906 (nds32_expand_setmem_loop): New.
27907 (nds32_expand_setmem_loop_v3m): New.
27908 (nds32_expand_setmem_unroll): New.
27909 (nds32_expand_setmem): New.
27910
27911 2018-03-04 Kito Cheng <kito.cheng@gmail.com>
27912 Chung-Ju Wu <jasonwucj@gmail.com>
27913
27914 * config/nds32/nds32-memory-manipulation.c
27915 (nds32_emit_load_store): New.
27916 (nds32_emit_post_inc_load_store): New.
27917 (nds32_emit_mem_move): New.
27918 (nds32_emit_mem_move_block): New.
27919 (nds32_expand_movmemsi_loop_unknown_size): New.
27920 (nds32_expand_movmemsi_loop_known_size): New.
27921 (nds32_expand_movmemsi_loop): New.
27922 (nds32_expand_movmemsi_unroll): New.
27923 (nds32_expand_movmemqi): Rename ...
27924 (nds32_expand_movmemsi): ... to this.
27925 * config/nds32/nds32-multiple.md (movmemqi): Rename ...
27926 (movmemsi): ... to this.
27927 * config/nds32/nds32-protos.h (nds32_expand_movmemqi): Rename ...
27928 (nds32_expand_movmemsi): ... to this.
27929
27930 2018-03-04 Kito Cheng <kito.cheng@gmail.com>
27931 Monk Chiang <sh.chiang04@gmail.com>
27932 Chung-Ju Wu <jasonwucj@gmail.com>
27933
27934 * config/nds32/nds32-protos.h
27935 (nds32_expand_load_multiple): New arguments.
27936 (nds32_expand_store_multiple): Ditto.
27937 (nds32_valid_multiple_load_store): Rename ...
27938 (nds32_valid_multiple_load_store_p): ... to this.
27939 * config/nds32/nds32-memory-manipulation.c
27940 (nds32_expand_load_multiple): Refine implementation.
27941 (nds32_expand_store_multiple): Ditto.
27942 * config/nds32/nds32-multiple.md
27943 (load_multiple): Update nds32_expand_load_multiple interface.
27944 (store_multiple): Update nds32_expand_store_multiple interface.
27945 * config/nds32/nds32-predicates.c
27946 (nds32_valid_multiple_load_store): Rename ...
27947 (nds32_valid_multiple_load_store_p): ... to this and refine
27948 implementation.
27949 * config/nds32/predicates.md
27950 (nds32_load_multiple_and_update_address_operation): New predicate.
27951 (nds32_store_multiple_and_update_address_operation): New predicate.
27952
27953 2018-03-04 Kito Cheng <kito.cheng@gmail.com>
27954 Chung-Ju Wu <jasonwucj@gmail.com>
27955
27956 * config/nds32/nds32.md (type): Add load_multiple and store_multiple.
27957 (combo): New attribute.
27958 * config/nds32/nds32-multiple.md: Refine patterns with new attributes.
27959
27960 2018-03-03 Chung-Ju Wu <jasonwucj@gmail.com>
27961
27962 * config/nds32/nds32.opt: Change -mcmodel= default value.
27963
27964 2018-03-03 Kito Cheng <kito.cheng@gmail.com>
27965 Monk Chiang <sh.chiang04@gmail.com>
27966 Chung-Ju Wu <jasonwucj@gmail.com>
27967
27968 * config/nds32/constants.md (unspec_element): New enum.
27969 * config/nds32/constraints.md (Umw): New constraint.
27970 * config/nds32/nds32-intrinsic.c: Add more builtin functions.
27971 * config/nds32/nds32-intrinsic.md: Likewise.
27972 * config/nds32/nds32-md-auxiliary.c (nds32_regno_to_enable4): New.
27973 (nds32_valid_smw_lwm_base_p): New.
27974 (nds32_output_smw_single_word): New.
27975 (nds32_output_lmw_single_word): New.
27976 (nds32_expand_unaligned_load): New.
27977 (nds32_expand_unaligned_store): New.
27978 * config/nds32/nds32-protos.h (nds32_valid_smw_lwm_base_p): Declare.
27979 (nds32_output_smw_single_word): Declare.
27980 (nds32_output_lmw_single_word): Declare.
27981 (nds32_expand_unaligned_load): Declare.
27982 (nds32_expand_unaligned_store): Declare.
27983 * config/nds32/nds32.h (nds32_builtins): Add NDS32_BUILTIN_UALOAD_HW,
27984 NDS32_BUILTIN_UALOAD_W, NDS32_BUILTIN_UALOAD_DW,
27985 NDS32_BUILTIN_UASTORE_HW, NDS32_BUILTIN_UASTORE_W,
27986 NDS32_BUILTIN_UASTORE_DW.
27987 * config/nds32/predicates.md (nds32_lmw_smw_base_operand): New
27988 predicate.
27989
27990 2018-03-03 Monk Chiang <sh.chiang04@gmail.com>
27991 Kito Cheng <kito.cheng@gmail.com>
27992 Chung-Ju Wu <jasonwucj@gmail.com>
27993
27994 * config/nds32/nds32-intrinsic.c
27995 (nds32_expand_builtin_null_ftype_reg): Delete.
27996 (nds32_expand_builtin_reg_ftype_imm): Ditto.
27997 (nds32_expand_builtin_null_ftype_reg_imm): Ditto.
27998 (nds32_read_argument): New.
27999 (nds32_legitimize_target): Ditto.
28000 (nds32_legitimize_argument): Ditto.
28001 (nds32_check_constant_argument): Ditto.
28002 (nds32_expand_unop_builtin): Ditto.
28003 (nds32_expand_unopimm_builtin): Ditto.
28004 (nds32_expand_binop_builtin): Ditto.
28005 (nds32_builtin_decl_impl): Ditto.
28006 (builtin_description): Ditto.
28007 (nds32_expand_builtin_impl): Rewrite with new infrastructure.
28008 (nds32_init_builtins_impl): Ditto.
28009 * config/nds32/nds32.c (TARGET_BUILTIN_DECL): Define.
28010 (nds32_builtin_decl): New.
28011 * config/nds32/nds32.h (nds32_builtins): Add NDS32_BUILTIN_COUNT.
28012 * config/nds32/nds32-protos.h (nds32_builtin_decl_impl): Declare.
28013
28014 2018-03-02 Jeff Law <law@redhat.com>
28015
28016 * reorg.c (stop_search_p): Handle DEBUG_INSN.
28017 (redundant_insn, fill_simple_delay_slots): Likewise.
28018 (fill_slots_from_thread): Likewise.
28019 * resource.c (mark_referenced_resources): Likewise.
28020 (mark_set_resources, find_dead_or_set_registers): Likewise.
28021
28022 2018-03-02 Jakub Jelinek <jakub@redhat.com>
28023
28024 * substring-locations.h (format_warning_va): Formatting fix for
28025 ATTRIBUTE_GCC_DIAG.
28026 (format_warning_at_substring): Fix up ATTRIBUTE_GCC_DIAG second
28027 argument.
28028 (format_warning_n_va, format_warning_at_substring_n): New prototypes.
28029 * substring-locations.c: Include intl.h.
28030 (format_warning_va): Turned into small wrapper around
28031 format_warning_n_va, renamed to ...
28032 (format_warning_n_va): ... this, add N and PLURAL_GMSGID arguments,
28033 rename GMSGID to SINGULAR_GMSGID, if SINGULAR_GMSGID != PLURAL_GMSGID,
28034 use ngettext.
28035 (format_warning_at_substring_n): New function.
28036 * gimple-ssa-sprintf.c: Remove GCC diagnostic ignored pragma.
28037 (fmtwarn): Add ATTRIBUTE_GCC_DIAG. Turn into a copy of
28038 format_warning_at_substring with just a shorter name instead of
28039 const function pointer.
28040 (fmtwarn_n): New function.
28041 (maybe_warn, format_directive, parse_directive): Use fmtwarn_n where
28042 appropriate, get rid of all the fmtstr temporaries, move conditionals
28043 with G_() wrapped string literals directly into fmtwarn arguments,
28044 cast dir.len to (int), formatting fixes.
28045
28046 2018-03-02 Thomas Schwinge <thomas@codesourcery.com>
28047
28048 * doc/invoke.texi: Remove "Cilk Plus" references.
28049
28050 2018-03-02 Jakub Jelinek <jakub@redhat.com>
28051 Richard Biener <rguenther@suse.de>
28052
28053 PR ipa/84628
28054 * expr.c (expand_expr_real_1) <case CALL_EXPR>: Don't emit diagnostics
28055 for error or warning attributes if CALL_FROM_THUNK_P is set.
28056 Formatting fixes.
28057
28058 2018-03-02 Jakub Jelinek <jakub@redhat.com>
28059
28060 PR target/56540
28061 * config/pa/pa.h (TARGET_CPU_CPP_BUILTINS): Predefine
28062 __SIZEOF_128__ macro if HPUX_LONG_DOUBLE_LIBRARY.
28063
28064 PR target/56540
28065 * config/ia64/ia64.h (TARGET_CPU_CPP_BUILTINS): Predefine
28066 __SIZEOF_{FPREG,FLOAT{80,128}}__ macros.
28067
28068 * predict.c (test_prediction_value_range): Use PROB_UNINITIALIZED
28069 instead of -1U in last predictors element's probability member.
28070
28071 2018-03-02 Eric Botcazou <ebotcazou@adacore.com>
28072
28073 PR ipa/83983
28074 * ipa-devirt.c (odr_subtypes_equivalent_p): Get the ODR type of both
28075 arguments if they are comparable.
28076
28077 2018-03-02 Richard Sandiford <richard.sandiford@linaro.org>
28078
28079 PR tree-optimization/84634
28080 * tree-vect-stmts.c (vectorizable_store, vectorizable_load): Replace
28081 masks and masked_loop_p with a single loop_masks, making sure it's
28082 null for bb vectorization.
28083
28084 2018-03-02 Richard Sandiford <richard.sandiford@linaro.org>
28085
28086 * tree-vect-data-refs.c (vect_analyze_data_ref_dependence)
28087 (vect_analyze_data_ref_access): Use loop->safe_len rather than
28088 loop->force_vectorize to check whether there is no alias.
28089
28090 2018-03-02 Jakub Jelinek <jakub@redhat.com>
28091
28092 PR target/84614
28093 * rtl.h (prev_real_nondebug_insn, next_real_nondebug_insn): New
28094 prototypes.
28095 * emit-rtl.c (next_real_insn, prev_real_insn): Fix up function
28096 comments.
28097 (next_real_nondebug_insn, prev_real_nondebug_insn): New functions.
28098 * cfgcleanup.c (try_head_merge_bb): Use prev_real_nondebug_insn
28099 instead of a loop around prev_real_insn.
28100 * combine.c (move_deaths): Use prev_real_nondebug_insn instead of
28101 prev_real_insn.
28102
28103 PR inline-asm/84625
28104 * config/i386/i386.c (ix86_print_operand): Use conditional
28105 output_operand_lossage instead of gcc_assert if CONST_VECTOR is not
28106 zero vector.
28107
28108 2018-03-02 Richard Biener <rguenther@suse.de>
28109
28110 PR tree-optimization/84427
28111 * tree-ssa-pre.c (bitmap_remove_expr_from_set): Remove.
28112 (bitmap_set_subtract_values): Rewrite to handle multiple
28113 exprs per value.
28114 (clean): Likewise.
28115 (prune_clobbered_mems): Likewise.
28116 (phi_translate): Take edge instead of pred/phiblock.
28117 (phi_translate_1): Likewise.
28118 (phi_translate_set): Likewise. Insert all translated
28119 exprs for a value into the set, keeping possibly multiple
28120 expressions per value.
28121 (compute_antic_aux): Adjust for phi_translate changes.
28122 When intersecting union the expressions and prune those
28123 not in the final value set, keeping possibly multiple
28124 expressions per value. Do not use value-insertion
28125 for unioning ANTIC_OUT U EXP_GEN - TMP_GEN but merge
28126 all expressions. Add verification that the value-sets
28127 only shrink during iteration.
28128 (compute_partial_antic_aux): Adjust for the phi_translate changes.
28129 (do_pre_regular_insertion): Likewise.
28130 (do_pre_partial_partial_insertion): Likewise.
28131
28132 2018-03-02 Richard Biener <rguenther@suse.de>
28133
28134 PR target/82005
28135 * config/darwin.c (saved_debug_info_level): New static global.
28136 (darwin_asm_lto_start): Disable debug info generation for LTO out.
28137 (darwin_asm_lto_end): Restore debug info generation settings.
28138
28139 2018-03-01 Martin Liska <mliska@suse.cz>
28140
28141 PR sanitizer/82484
28142 * sanopt.c (sanitize_rewrite_addressable_params): Do not handle
28143 volatile arguments.
28144
28145 2018-03-01 Richard Biener <rguenther@suse.de>
28146
28147 PR debug/84645
28148 * dwarf2out.c (gen_variable_die): Properly handle late VLA
28149 type annotation with LTO when debug was disabled at compile-time.
28150
28151 2018-03-01 Matthew Fortune <mfortune@gmail.com>
28152
28153 * config/mips/mips.c (mips_final_prescan_insn): Fix incorrect
28154 XINT with INTVAL.
28155 (mips_final_postscan_insn): Likewise.
28156
28157 2018-03-01 Richard Sandiford <richard.sandiford@linaro.org>
28158
28159 PR rtl-optimization/84528
28160 * alias.c (init_alias_target): Add commentary.
28161 (init_alias_analysis): Only give HARD_FRAME_POINTER_REGNUM
28162 a unique base value if the frame pointer is not eliminated
28163 to the stack pointer.
28164
28165 2018-03-01 Tom de Vries <tom@codesourcery.com>
28166
28167 PR rtl-optimization/83327
28168 * lra-int.h (hard_regs_spilled_into): Declare.
28169 * lra.c (hard_regs_spilled_into): Define.
28170 (init_reg_info): Init hard_regs_spilled_into.
28171 * lra-spills.c (assign_spill_hard_regs): Update hard_regs_spilled_into.
28172 * lra-lives.c (make_hard_regno_born, make_hard_regno_dead)
28173 (process_bb_lives): Handle hard_regs_spilled_into.
28174 (lra_create_live_ranges_1): Before doing liveness propagation, clear
28175 regs in all_hard_regs_bitmap if set in hard_regs_spilled_into.
28176
28177 2018-02-28 David Edelsohn <dje.gcc@gmail.com>
28178
28179 * config.gcc (powerpc-ibm-aix7.1.*): New stanza.
28180 (powerpc-ibm-aix[789]*): Default to AIX 7.2.
28181 * config/rs6000/aix71.h (TARGET_DEFAULT): Revert to Power4 ISA.
28182 * config/rs6000/aix72.h: New file.
28183
28184 2018-02-28 Jakub Jelinek <jakub@redhat.com>
28185
28186 * gimple-ssa-warn-restrict.c (maybe_diag_overlap): Use warning_n
28187 instead of warning_at with conditional singular and plural messages
28188 where possible.
28189
28190 PR target/52991
28191 * stor-layout.c (update_alignment_for_field): For
28192 targetm.ms_bitfield_layout_p (rli->t), if !is_bitfield
28193 && !DECL_PACKED (field), do the alignment update, just use
28194 only desired_align instead of MAX (type_align, desired_align)
28195 as the alignment.
28196 (place_field): Don't do known_align < desired_align handling
28197 early if targetm.ms_bitfield_layout_p (rli->t) and rli->prev_field
28198 is non-NULL, instead do it after rli->prev_field handling and
28199 only if not within a bitfield word. For DECL_PACKED (field)
28200 use type_align of BITS_PER_UNIT.
28201
28202 2018-02-28 Eric Botcazou <ebotcazou@adacore.com>
28203
28204 * config/aarch64/aarch64.c (aarch64_emit_probe_stack_range): Remove
28205 superfluous parentheses and trailing spaces.
28206
28207 2018-02-28 Richard Biener <rguenther@suse.de>
28208
28209 PR tree-optimization/84584
28210 * graphite-scop-detection.c (scop_detection::add_scop): Discard
28211 SCoPs with fake exit edge.
28212
28213 2018-02-28 Martin Liska <mliska@suse.cz>
28214
28215 PR testsuite/84597
28216 * timevar.c (timer::print): Fix format to properly print 100%
28217 values.
28218
28219 2018-02-28 Richard Biener <rguenther@suse.de>
28220
28221 PR middle-end/84607
28222 * genmatch.c (capture_info::walk_match): Do not mark
28223 captured expressions without operands as expr_p given
28224 they act more like predicates and should be subject to
28225 "lost tail" side-effect preserving.
28226
28227 2018-02-28 Alexandre Oliva <aoliva@redhat.com>
28228
28229 PR rtl-optimization/81611
28230 * auto-inc-dec.c (attempt_change): Move dead note from
28231 mem_insn if it's the next use of regno
28232 (find_address): Take address use of reg holding
28233 non-incremented value. Add parm to limit search to the named
28234 reg only.
28235 (merge_in_block): Attempt to use a mem insn that is the next
28236 use of the original regno.
28237
28238 2018-02-27 Martin Sebor <msebor@redhat.com>
28239
28240 PR c++/83871
28241 * doc/invoke.texi (-Wmissing-attributes): New option.
28242 * print-tree.c (print_node): Handle DECL_UNINLINABLE.
28243
28244 2018-02-27 Martin Sebor <msebor@redhat.com>
28245
28246 PR translation/84207
28247 * diagnostic-core.h (warning_n, error_n, inform_n): Change
28248 n argument to unsigned HOST_WIDE_INT.
28249 * diagnostic.c (warning_n, error_n, inform_n): Ditto.
28250 (diagnostic_n_impl): Ditto. Handle arguments in excess of LONG_MAX.
28251 * gimple-ssa-sprintf.c (format_directive): Simplify inform_n call.
28252 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Use warning_n.
28253
28254 2018-02-27 Richard Biener <rguenther@suse.de>
28255
28256 PR tree-optimization/84512
28257 * tree-vect-loop.c (vect_compute_single_scalar_iteration_cost):
28258 Do not use the estimate returned from record_stmt_cost for
28259 the scalar iteration cost but sum properly using add_stmt_cost.
28260
28261 2018-02-27 Richard Biener <rguenther@suse.de>
28262
28263 PR tree-optimization/84466
28264 * graphite-scop-detection.c (scop_detection::stmt_simple_for_scop_p):
28265 Adjust last change to less strictly validate use operands.
28266
28267 2018-02-27 Martin Liska <mliska@suse.cz>
28268
28269 PR gcov-profile/84548
28270 * gcov.c (process_file): Allow partial overlap and consider it
28271 also as group functions.
28272 (output_lines): Properly calculate range of lines for a group.
28273
28274 2018-02-27 Martin Liska <mliska@suse.cz>
28275
28276 * timevar.c (timer::print_row): Remove 'usr', 'sys', 'wall' and
28277 'ggc' suffixes. Change first column width.
28278 (timer::print): Fix formatting of the column.
28279
28280 2018-02-27 Alexandre Oliva <aoliva@redhat.com>
28281
28282 * tree-ssa-live.c (remove_unused_scope_block_p): Do not
28283 preserve inline entry blocks for the sake of debug inline
28284 entry point markers alone.
28285 (remove_unused_locals): Suggest in comments a better place to
28286 force the preservation of inline entry blocks that are
28287 otherwise unused, but do not preserve them.
28288
28289 2018-02-26 H.J. Lu <hongjiu.lu@intel.com>
28290
28291 * config/i386/i386.c (ix86_output_indirect_jmp): Update comments.
28292
28293 2018-02-26 H.J. Lu <hongjiu.lu@intel.com>
28294
28295 PR target/84039
28296 * config/i386/constraints.md (Bs): Replace
28297 ix86_indirect_branch_register with
28298 TARGET_INDIRECT_BRANCH_REGISTER.
28299 (Bw): Likewise.
28300 * config/i386/i386.md (indirect_jump): Likewise.
28301 (tablejump): Likewise.
28302 (*sibcall_memory): Likewise.
28303 (*sibcall_value_memory): Likewise.
28304 Peepholes of indirect call and jump via memory: Likewise.
28305 (*sibcall_GOT_32): Disallowed for TARGET_INDIRECT_BRANCH_REGISTER.
28306 (*sibcall_value_GOT_32): Likewise.
28307 * config/i386/predicates.md (indirect_branch_operand): Likewise.
28308 (GOT_memory_operand): Likewise.
28309 (call_insn_operand): Likewise.
28310 (sibcall_insn_operand): Likewise.
28311 (GOT32_symbol_operand): Likewise.
28312 * config/i386/i386.h (TARGET_INDIRECT_BRANCH_REGISTER): New.
28313
28314 2018-02-26 Eric Botcazou <ebotcazou@adacore.com>
28315
28316 PR rtl-optimization/83496
28317 * reorg.c (steal_delay_list_from_target): Change REDUNDANT array from
28318 booleans to RTXes. Call fix_reg_dead_note on every non-null element.
28319 (steal_delay_list_from_fallthrough): Call fix_reg_dead_note on a
28320 redundant insn, if any.
28321 (relax_delay_slots): Likewise.
28322 (update_reg_unused_notes): Rename REDUNDANT_INSN to OTHER_INSN.
28323
28324 2018-02-26 Richard Sandiford <richard.sandiford@linaro.org>
28325
28326 PR tree-optimization/83965
28327 * tree-vect-patterns.c (vect_reassociating_reduction_p): Assume
28328 that grouped statements are part of a reduction chain. Return
28329 true if the statement is not marked as a reduction itself but
28330 is part of a group.
28331 (vect_recog_dot_prod_pattern): Don't check whether the statement
28332 is part of a group here.
28333 (vect_recog_sad_pattern): Likewise.
28334 (vect_recog_widen_sum_pattern): Likewise.
28335
28336 2018-02-26 Eric Botcazou <ebotcazou@adacore.com>
28337
28338 PR debug/84545
28339 * final.c (rest_of_clean_state): Also look for calls inside sequences.
28340
28341 2018-02-26 H.J. Lu <hongjiu.lu@intel.com>
28342
28343 PR target/84530
28344 * config/i386/i386-protos.h (ix86_output_indirect_jmp): Remove
28345 the bool argument.
28346 (ix86_output_indirect_function_return): New prototype.
28347 (ix86_split_simple_return_pop_internal): Likewise.
28348 * config/i386/i386.c (indirect_return_via_cx): New.
28349 (indirect_return_via_cx_bnd): Likewise.
28350 (indirect_thunk_name): Handle return va CX_REG.
28351 (output_indirect_thunk_function): Create alias for
28352 __x86_return_thunk_[re]cx and __x86_return_thunk_[re]cx_bnd.
28353 (ix86_output_indirect_jmp): Remove the bool argument.
28354 (ix86_output_indirect_function_return): New function.
28355 (ix86_split_simple_return_pop_internal): Likewise.
28356 * config/i386/i386.md (*indirect_jump): Don't pass false
28357 to ix86_output_indirect_jmp.
28358 (*tablejump_1): Likewise.
28359 (simple_return_pop_internal): Change it to define_insn_and_split.
28360 Call ix86_split_simple_return_pop_internal to split it for
28361 -mfunction-return=.
28362 (simple_return_indirect_internal): Call
28363 ix86_output_indirect_function_return instead of
28364 ix86_output_indirect_jmp.
28365
28366 2018-02-26 Jakub Jelinek <jakub@redhat.com>
28367
28368 PR bootstrap/84405
28369 * vec.h (vec_default_construct): For BROKEN_VALUE_INITIALIZATION use
28370 memset and value initialization afterwards.
28371
28372 2018-02-26 Christophe Lyon <christophe.lyon@linaro.org>
28373
28374 * Makefile.in (lto-wrapper): Use ALL_LINKERFLAGS.
28375
28376 2018-02-26 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
28377
28378 PR target/84521
28379 * common/config/aarch64/aarch64-common.c
28380 (aarch_option_optimization_table[]): Switch
28381 off fomit-frame-pointer
28382
28383 2018-02-26 Kito Cheng <kito.cheng@gmail.com>
28384 Chung-Ju Wu <jasonwucj@gmail.com>
28385
28386 * config/nds32/nds32-multiple.md (load_multiple): Disallow
28387 volatile memory.
28388 (store_multiple): Ditto.
28389
28390 2018-02-26 Kito Cheng <kito.cheng@gmail.com>
28391
28392 * config.gcc: Add --with-cpu support for nds32 target.
28393 * config/nds32/nds32-opts.h (nds32_cpu_type): New.
28394 * config/nds32/nds32.opt: Add -mcpu= option.
28395
28396 2018-02-25 Segher Boessenkool <segher@kernel.crashing.org>
28397
28398 * config/rs6000/rs6000.opt (mvrsave=no, mvrsave=yes, isel=no,
28399 isel=yes): Warn for these deprecated options.
28400
28401 2018-02-23 David Edelsohn <dje.gcc@gmail.com>
28402
28403 * config/rs6000/aix71.h (TARGET_DEFAULT): Change to
28404 ISA_2_5_MASKS_EMBEDDED.
28405
28406 2018-02-23 Jakub Jelinek <jakub@redhat.com>
28407
28408 * ipa-prop.c (ipa_vr_ggc_hash_traits::hash): Hash p->min and
28409 p->max as pointers rather than using iterative_hash_expr.
28410
28411 2018-02-23 Carl Love <cel@us.ibm.com>
28412
28413 * config/rs6000/rs6000-builtin.def: Change VSIGNED2 and VUNSIGNED2
28414 macro expansions from BU_VSX_2 to BU_P8V_VSX_2 and BU_VSX_OVERLOAD_2 to
28415 BU_P8V_OVERLOAD_2.
28416 * config/rs6000/rs6000-c.c: Change VSX_BUILTIN_VEC_VSIGNED2 to
28417 P8V_BUILTIN_VEC_VSIGNED2. Change VSX_BUILTIN_VEC_VUNSIGNED2 to
28418 P8V_BUILTIN_VEC_VUNSIGNED2.
28419
28420 2018-02-22 Vladimir Makarov <vmakarov@redhat.com>
28421
28422 PR target/81572
28423 * lra-int.h (LRA_UNKNOWN_ALT, LRA_NON_CLOBBERED_ALT): New macros.
28424 * lra.c (lra_set_insn_recog_data, lra_update_insn_recog_data): Use
28425 LRA_UNKNOWN_ALT.
28426 * lra-constraints.c (curr_insn_transform): Set up
28427 LRA_NON_CLOBBERED_ALT for moves processed on the fast path. Use
28428 LRA_UNKNOWN_ALT.
28429 (remove_inheritance_pseudos): Use LRA_UNKNOWN_ALT.
28430 * lra-eliminations.c (spill_pseudos): Ditto.
28431 (process_insn_for_elimination): Ditto.
28432 * lra-lives.c (reg_early_clobber_p): Use the new macros.
28433 * lra-spills.c (spill_pseudos): Use LRA_UNKNOWN_ALT and
28434 LRA_NON_CLOBBERED_ALT.
28435
28436 2018-02-22 Martin Sebor <msebor@redhat.com>
28437
28438 PR tree-optimization/84480
28439 * gimple-fold.c (gimple_fold_builtin_strcpy): Move warnings
28440 to maybe_diag_stxncpy_trunc. Call it.
28441 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Integrate warnings
28442 from gimple_fold_builtin_strcpy. Print inlining stack.
28443 (handle_builtin_stxncpy): Print inlining stack.
28444 * tree-ssa-strlen.h (maybe_diag_stxncpy_trunc): Declare.
28445
28446 2018-02-22 H.J. Lu <hongjiu.lu@intel.com>
28447
28448 PR target/84176
28449 * config/i386/i386.c (ix86_set_indirect_branch_type): Issue an
28450 error when -mindirect-branch=thunk-extern, -fcf-protection=branch
28451 and -fcheck-pointer-bounds are used together.
28452 (indirect_thunk_prefix): New enum.
28453 (indirect_thunk_need_prefix): New function.
28454 (indirect_thunk_name): Replace need_bnd_p with need_prefix. Use
28455 "_nt" instead of "_bnd" for NOTRACK prefix.
28456 (output_indirect_thunk): Replace need_bnd_p with need_prefix.
28457 (output_indirect_thunk_function): Likewise.
28458 (): Likewise.
28459 (ix86_code_end): Update output_indirect_thunk_function calls.
28460 (ix86_output_indirect_branch_via_reg): Replace
28461 ix86_bnd_prefixed_insn_p with indirect_thunk_need_prefix.
28462 (ix86_output_indirect_branch_via_push): Likewise.
28463 (ix86_output_function_return): Likewise.
28464 * doc/invoke.texi: Document -mindirect-branch=thunk-extern is
28465 incompatible with -fcf-protection=branch and
28466 -fcheck-pointer-bounds.
28467
28468 2018-02-22 Steve Ellcey <sellcey@cavium.com>
28469
28470 PR target/83335
28471 * config/aarch64/aarch64.c (aarch64_print_address_internal):
28472 Change gcc_assert call to output_operand_lossage.
28473
28474 2018-02-22 Steve Ellcey <sellcey@cavium.com>
28475
28476 * doc/extend.texi (__builtin_extend_pointer): Document builtin.
28477
28478 2018-02-22 DJ Delorie <dj@redhat.com>
28479 Sebastian Perta <sebastian.perta@renesas.com>
28480 Oleg Endo <olegendo@gcc.gnu.org>
28481
28482 * config/rx/rx.c (rx_rtx_costs): New function.
28483 (TARGET_RTX_COSTS): Override to use rx_rtx_costs.
28484
28485 2018-02-22 Thomas Preud'homme <thomas.preudhomme@arm.com>
28486
28487 * config/arm/t-multilib: Map Armv8-R to Armv7 multilibs.
28488
28489 2018-02-22 Martin Liska <mliska@suse.cz>
28490
28491 PR driver/83193
28492 * common/config/arm/arm-common.c (arm_print_hint_for_cpu_option):
28493 Add "native" as a possible value.
28494
28495 2018-02-22 Martin Liska <mliska@suse.cz>
28496
28497 PR driver/83193
28498 * config/i386/i386.c (ix86_option_override_internal):
28499 Add "native" as a possible value for -march and -mtune.
28500
28501 2018-02-22 Jakub Jelinek <jakub@redhat.com>
28502
28503 PR target/84502
28504 * stor-layout.c (finalize_type_size): Propagate TYPE_EMPTY_P flag
28505 to all type variants.
28506
28507 PR tree-optimization/84503
28508 * gimple-ssa-store-merging.c (merged_store_group::merge_into): Compute
28509 width as info->bitpos + info->bitsize - start.
28510 (merged_store_group::merge_overlapping): Simplify width computation.
28511 (check_no_overlap): New function.
28512 (imm_store_chain_info::try_coalesce_bswap): Compute expected
28513 start + width and last_order of the group, fail if check_no_overlap
28514 fails.
28515 (imm_store_chain_info::coalesce_immediate_stores): Don't merge info
28516 to group if check_no_overlap fails.
28517
28518 2018-02-21 Segher Boessenkool <segher@kernel.crashing.org>
28519
28520 * config/rs6000/altivec.md: Delete contraint arguments to
28521 define_expand, define_split, and define_peephole2, and in
28522 define_insn_and_split if always unused.
28523 * config/rs6000/darwin.md: Ditto.
28524 * config/rs6000/dfp.md: Ditto.
28525 * config/rs6000/rs6000.md: Ditto.
28526 * config/rs6000/sync.md: Ditto.
28527 * config/rs6000/vector.md: Ditto.
28528 * config/rs6000/vsx.md: Ditto.
28529
28530 2018-02-21 Segher Boessenkool <segher@kernel.crashing.org>
28531
28532 * config/rs6000/altivec.md: Write output control strings as braced
28533 blocks instead of double-quoted strings.
28534 * config/rs6000/darwin.md: Ditto.
28535 * config/rs6000/rs6000.md: Ditto.
28536 * config/rs6000/vector.md: Ditto.
28537 * config/rs6000/vsx.md: Ditto.
28538
28539 2018-02-21 Jason Merrill <jason@redhat.com>
28540
28541 PR c++/84314 - ICE with templates and fastcall attribute.
28542 * attribs.c (build_type_attribute_qual_variant): Remove assert.
28543
28544 2018-02-21 Jan Hubicka <hubicka@ucw.cz>
28545
28546 * ipa-cp.c (determine_versionability): Fix comment typos.
28547
28548 2018-02-21 Jan Hubicka <hubicka@ucw.cz>
28549
28550 PR c/84229
28551 * ipa-cp.c (determine_versionability): Do not version functions caling
28552 va_arg_pack.
28553
28554 2018-02-21 Martin Liska <mliska@suse.cz>
28555
28556 PR driver/83193
28557 * config/aarch64/aarch64.c (aarch64_print_hint_for_core_or_arch):
28558 Add "native" as a possible value.
28559 * config/aarch64/aarch64.h (HAVE_LOCAL_CPU_DETECT): Define
28560 the macro when native cpu detection is available.
28561
28562 2018-02-21 Martin Liska <mliska@suse.cz>
28563
28564 PR driver/83193
28565 * common/config/arm/arm-common.c (arm_print_hint_for_arch_option):
28566 Add "native" as a possible value.
28567 * config/arm/arm.h (HAVE_LOCAL_CPU_DETECT): Define the macro
28568 when native cpu detection is available.
28569
28570 2018-02-21 Jakub Jelinek <jakub@redhat.com>
28571 Martin Sebor <msebor@redhat.com>
28572
28573 PR tree-optimization/84478
28574 * gimple-fold.h (get_range_strlen): Add a bool argument defaulted to
28575 false.
28576 * gimple-fold.c (get_range_strlen): Make minlen const and assume it
28577 can't be NULL. Change FUZZY from bool to int, for 1 add PHI/COND_EXPR
28578 support which is conservatively correct, for 2 only stay conservative
28579 for maxlen. Formatting and comment capitalization fixes. Add STRICT
28580 argument to the 2 argument get_range_strlen, adjust 6 arg
28581 get_range_strlen caller and clear minmaxlen[0] and [1] if it returned
28582 false.
28583 (get_maxval_strlen): Adjust 6 arg get_range_strlen caller.
28584 (gimple_fold_builtin_strlen): Pass true as last argument to
28585 get_range_strlen.
28586
28587 2018-02-20 Martin Sebor <msebor@redhat.com>
28588
28589 PR middle-end/84095
28590 * gimple-ssa-warn-restrict.c (builtin_memref::extend_offset_range): New.
28591 (builtin_memref::set_base_and_offset): Same. Handle inner references.
28592 (builtin_memref::builtin_memref): Factor out parts into
28593 set_base_and_offset and call it.
28594
28595 2018-02-20 Richard Sandiford <richard.sandiford@linaro.org>
28596
28597 PR middle-end/84406
28598 * optabs-query.c (find_widening_optab_handler_and_mode): If from_mode
28599 is a scalar_int_mode, assert that to_mode is a scalar_int_mode with
28600 greater precision. If to_mode is a MODE_PARTIAL_INT, stop the
28601 search at the associated MODE_INT.
28602
28603 2018-02-20 Jeff Law <law@redhat.com>
28604
28605 PR middle-end/82123
28606 PR tree-optimization/81592
28607 PR middle-end/79257
28608 * gimple-ssa-sprintf.c (format_integer): Query EVRP range analyzer
28609 for range data rather than using global data.
28610 * gimple-ssa-sprintf.c (get_int_range): Query EVRP range analyzer for
28611 range data rather than using global data.
28612 * gimple-ssa-sprintf.c (get_int_range): Accept vr_values parameter
28613 pass it to children as needed.
28614 (struct directive::fmtresult): Similarly.
28615 (struct directive::set_width): Similarly.
28616 (struct directive::set_precision): Similarly.
28617 (format_integer, format_directive, parse_directive): Similarly.
28618 (format_none): Accept unnamed vr_values parameter.
28619 (format_percent, format_floating, format_character): Similarly.
28620 (format_string, format_plain): Similarly.
28621 * gimple-ssa-sprintf.c (sprintf_dom_walker::handle_gimple_call): Query
28622 the EVRP range analyzer for range data rather than using global data.
28623 * gimple-ssa-sprintf.c: Include alloc-pool.h, vr-values.h and
28624 gimple-ssa-evrp-analyze.h
28625 (class sprintf_dom_walker): Add after_dom_children member function.
28626 Add evrp_range_analyzer member.
28627 (sprintf_dom_walker::before_dom_children): Call into the EVRP
28628 range analyzer as needed.
28629 (sprintf_dom_walker::after_dom_children): New member function.
28630 * gimple-ssa-evrp-analyze.c (evrp_range_analyzer::enter): Do nothing
28631 if not optimizing.
28632 (evrp_range_analyzer::record_ranges_from_stmt): Likewise.
28633 (evrp_range_analyzer::pop_to_marker): Likewise.
28634
28635 2018-02-20 Richard Sandiford <richard.sandiford@linaro.org>
28636
28637 PR tree-optimization/84419
28638 * internal-fn.c (expand_call_mem_ref): Create a TARGET_MEM_REF
28639 with the required type if its current type is compatible but
28640 different.
28641
28642 2018-02-20 Jakub Jelinek <jakub@redhat.com>
28643
28644 PR middle-end/82004
28645 * match.pd (pow(C,x) -> exp(log(C)*x)): Delay all folding until
28646 after vectorization.
28647
28648 2018-02-20 Martin Liska <mliska@suse.cz>
28649
28650 PR driver/83193
28651 * config/aarch64/aarch64.c (aarch64_print_hint_for_core_or_arch): Print
28652 possible values if we don't have a hint.
28653
28654 2018-02-20 Martin Liska <mliska@suse.cz>
28655
28656 PR c/84310
28657 PR target/79747
28658 * final.c (shorten_branches): Build align_tab array with one
28659 more element.
28660 * opts.c (finish_options): Add alignment option limit check.
28661 (MAX_CODE_ALIGN): Likewise.
28662 (MAX_CODE_ALIGN_VALUE): Likewise.
28663 * doc/invoke.texi: Document maximum allowed option value for
28664 all -falign-* options.
28665
28666 2018-02-19 Jakub Jelinek <jakub@redhat.com>
28667
28668 PR target/84146
28669 * reg-notes.def (REG_CALL_ARG_LOCATION): New reg note.
28670 * insn-notes.def (NOTE_INSN_CALL_ARG_LOCATION): Remove.
28671 * var-tracking.c (emit_note_insn_var_location): Remove all references
28672 to NOTE_INSN_CALL_ARG_LOCATION.
28673 (emit_notes_in_bb): Emit arguments as REG_CALL_ARG_LOCATION note on
28674 the CALL_INSN rather than separate NOTE_INSN_CALL_ARG_LOCATION note.
28675 Use copy_rtx_if_shared.
28676 * dwarf2out.c (gen_subprogram_die): Use XEXP with 0 instead of
28677 NOTE_VAR_LOCATION on ca_loc->call_arg_loc_note.
28678 (dwarf2out_var_location): Remove handling of
28679 NOTE_INSN_CALL_ARG_LOCATION, instead handle REG_CALL_ARG_LOCATION note
28680 on call_insn.
28681 * final.c (final_scan_insn): Remove all references to
28682 NOTE_INSN_CALL_ARG_LOCATION.
28683 (rest_of_clean_state): Likewise. Remove REG_CALL_ARG_LOCATION notes
28684 before dumping final insns.
28685 * except.c (emit_note_eh_region_end): Remove all references to
28686 NOTE_INSN_CALL_ARG_LOCATION.
28687 * config/alpha/alpha.c (alpha_pad_function_end): Likewise.
28688 * config/c6x/c6x.c (c6x_gen_bundles): Likewise.
28689 * config/arc/arc.c (hwloop_optimize): Likewise.
28690 * config/arm/arm.c (create_fix_barrier): Likewise.
28691 * config/s390/s390.c (s390_chunkify_start): Likewise.
28692 * config/sh/sh.c (find_barrier): Likewise.
28693 * config/i386/i386.c (rest_of_insert_endbranch,
28694 ix86_seh_fixup_eh_fallthru): Likewise.
28695 * config/xtensa/xtensa.c (hwloop_optimize): Likewise.
28696 * config/iq2000/iq2000.c (final_prescan_insn): Likewise.
28697 * config/frv/frv.c (frv_function_prologue): Likewise.
28698 * emit-rtl.c (try_split): Likewise. Copy over REG_CALL_ARG_LOCATION
28699 reg note.
28700 (note_outside_basic_block_p): Remove all references to
28701 NOTE_INSN_CALL_ARG_LOCATION.
28702 * gengtype.c (adjust_field_rtx_def): Likewise.
28703 * print-rtl.c (rtx_writer::print_rtx_operand_code_0, print_insn):
28704 Likewise.
28705 * jump.c (cleanup_barriers, delete_related_insns): Likewise.
28706 * cfgrtl.c (force_nonfallthru_and_redirect): Likewise.
28707
28708 PR c++/84444
28709 * builtins.c (builtin_mathfn_code): Don't check if CALL_EXPR_FN (t)
28710 is ADDR_EXPR.
28711
28712 PR tree-optimization/84452
28713 * tree-vect-patterns.c (vect_recog_pow_pattern): Don't call
28714 expand_simd_clones if targetm.simd_clone.compute_vecsize_and_simdlen
28715 is NULL.
28716
28717 2018-02-19 Martin Liska <mliska@suse.cz>
28718
28719 PR sanitizer/82183
28720 * passes.def: Put pass_sancov_O0 before pass_lower_switch with -O0.
28721
28722 2018-02-19 Martin Liska <mliska@suse.cz>
28723 Richard Sandiford <richard.sandiford@linaro.org>
28724
28725 PR tree-optimization/82491
28726 * gimple-fold.c (get_base_constructor): Make earlier bail out
28727 to prevent ubsan.
28728
28729 2018-02-19 Carl Love <cel@us.ibm.com>
28730
28731 * config/rs6000/rs6000-builtin.def: Change NEG macro expansions from
28732 BU_ALTIVEC_A to BU_P8V_AV_1 and BU_ALTIVEC_OVERLOAD_1 to
28733 BU_P8V_OVERLOAD_1.
28734 * config/rs6000/rs6000-c.c: Change ALTIVEC_BUILTIN_VEC_NEG to
28735 P8V_BUILTIN_VEC_NEG.
28736
28737 2018-02-19 Sebastian Perta <sebastian.perta@renesas.com>
28738
28739 * config/rl78/rl78.md (movdf): New define expand.
28740
28741 2018-02-19 Martin Liska <mliska@suse.cz>
28742
28743 PR other/80589
28744 * doc/invoke.texi: Fix typo.
28745 * params.def (PARAM_MAX_LOOP_HEADER_INSNS): Likewise.
28746
28747 2018-02-18 Segher Boessenkool <segher@kernel.crashing.org>
28748
28749 * config/rs6000/rs6000.c (rs6000_option_override_internal): Don't
28750 handle rs6000_single_float and rs6000_double_float specially for
28751 e500 family CPUs.
28752
28753 2018-02-16 Jeff Law <law@redhat.com>
28754
28755 * config/rx/rx.c (add_pop_cfi_notes): New function.;
28756 (pop_regs): Use it.
28757
28758 2018-02-16 Jakub Jelinek <jakub@redhat.com>
28759
28760 PR ipa/84425
28761 * ipa-inline.c (inline_small_functions): Fix a typo.
28762
28763 2018-02-16 Nathan Sidwell <nathan@acm.org>
28764
28765 * doc/extend.texi (Backwards Compatibility): Americanize 'behaviour'.
28766
28767 2018-02-16 Carl Love <cel@us.ibm.com>
28768
28769 * config/rs6000/rs6000-builtin.def: Add BU_P8V_VSX_2 macro definition.
28770 Change FLOAT2 expansions from BU_VSX_2 to BU_P8V_VSX_2 and
28771 from BU_VSX_OVERLOAD_2 to BU_P8V_OVERLOAD_2.
28772 * config/rs6000/rs6000-c.c: Changed macro VSX_BUILTIN_VEC_FLOAT2
28773 expansion to P8V_BUILTIN_VEC_FLOAT2.
28774
28775 2018-02-16 Vladimir Makarov <vmakarov@redhat.com>
28776
28777 PR rtl-optimization/70023
28778 * lra-constraints.c (inherit_in_ebb): Take hard reg mode of
28779 src_regno into account.
28780
28781 2018-02-16 Carl Love <cel@us.ibm.com>
28782
28783 * config/rs6000/altivec.h: Remove vec_vextract4b and vec_vinsert4b.
28784 * config/rs6000/rs6000-builtin.def: Remove macro expansion for
28785 VEXTRACT4B, VINSERT4B, VINSERT4B_DI and VEXTRACT4B.
28786 * config/rs6000/rs6000.c: Remove case statements for
28787 P9V_BUILTIN_VEXTRACT4B, P9V_BUILTIN_VEC_VEXTRACT4B,
28788 P9V_BUILTIN_VINSERT4B, P9V_BUILTIN_VINSERT4B_DI,
28789 and P9V_BUILTIN_VEC_VINSERT4B.
28790 * config/rs6000/rs6000-c.c (altivec_expand_builtin): Remove entries for
28791 P9V_BUILTIN_VEC_VEXTRACT4B and P9V_BUILTIN_VEC_VINSERT4B.
28792 * config/rs6000/vsx.md:
28793 * doc/extend.texi: Remove vec_vextract4b, non ABI definitions for
28794 vec_insert4b.
28795
28796 2018-02-16 Carl Love <cel@us.ibm.com>
28797
28798 * config/rs6000/altivec.h: Add builtin names vec_extract4b
28799 vec_insert4b.
28800 * config/rs6000/rs6000-builtin.def: Add INSERT4B and EXTRACT4B
28801 definitions.
28802 * config/rs6000/rs6000-c.c: Add the definitions for
28803 P9V_BUILTIN_VEC_EXTRACT4B and P9V_BUILTIN_VEC_INSERT4B.
28804 * config/rs6000/rs6000.c (altivec_expand_builtin): Add
28805 P9V_BUILTIN_EXTRACT4B and P9V_BUILTIN_INSERT4B case statements.
28806 * config/rs6000/vsx.md: Add define_insn extract4b. Add define_expand
28807 definition for insert4b and define insn *insert3b_internal.
28808 * doc/extend.texi: Add documentation for vec_extract4b.
28809
28810 2018-02-16 Nathan Sidwell <nathan@acm.org>
28811
28812 * doc/extend.texi (Backwards Compatibility): Mention friend
28813 injection. Note for-scope is deprecated.
28814 * doc/invoke.texi (-ffriend-injection): Deprecate.
28815
28816 2018-02-16 Segher Boessenkool <segher@kernel.crashing.org>
28817
28818 * combine.c (try_combine): When adjusting LOG_LINKS for the destination
28819 that moved to I2, also allow destinations that are a paradoxical
28820 subreg (instead of a normal reg).
28821
28822 2018-02-16 Oleg Endo <olegendo@gcc.gnu.org>
28823
28824 PR target/83831
28825 * config/rx/rx.c (rx_fuse_in_memory_bitop): Convert shift operand
28826 to QImode.
28827
28828 2018-02-16 Richard Biener <rguenther@suse.de>
28829
28830 PR tree-optimization/84037
28831 PR tree-optimization/84016
28832 PR target/82862
28833 * config/i386/i386.c (ix86_builtin_vectorization_cost):
28834 Adjust vec_construct for the fact we need additional higher latency
28835 128bit inserts for AVX256 and AVX512 vector builds.
28836 (ix86_add_stmt_cost): Scale vector construction cost for
28837 elementwise loads.
28838
28839 2018-02-16 Richard Biener <rguenther@suse.de>
28840
28841 PR tree-optimization/84417
28842 * tree-ssa.c (non_rewritable_mem_ref_base): Properly constrain
28843 the MEM_REF offset when conversion to BIT_FIELD_REF is desired.
28844 (non_rewritable_lvalue_p): Likewise, use poly-ints.
28845
28846 2018-02-16 Martin Liska <mliska@suse.cz>
28847
28848 PR sanitizer/84307
28849 * internal-fn.def (ASAN_CHECK): Set proper flags.
28850 (ASAN_MARK): Likewise.
28851
28852 2018-02-16 Julia Koval <julia.koval@intel.com>
28853
28854 * config/i386/i386.c (ix86_option_override_internal): Remove PTA_CLWB
28855 from PTA_CANNONLAKE.
28856
28857 2018-02-16 Jakub Jelinek <jakub@redhat.com>
28858
28859 PR target/84272
28860 * config/aarch64/cortex-a57-fma-steering.c (fma_forest::merge_forest):
28861 Use ++iter rather than iter++ for std::list iterators.
28862 (func_fma_steering::dfs): Likewise. Don't delete nodes right away,
28863 defer deleting them until all nodes in the forest are processed. Do
28864 free even leaf nodes. Change to_process into auto_vec.
28865
28866 PR bootstrap/84405
28867 * system.h (BROKEN_VALUE_INITIALIZATION): Define for GCC < 4.3.
28868 * vec.h (vec_default_construct): Use memset instead of placement new
28869 if BROKEN_VALUE_INITIALIZATION is defined.
28870 * hash-table.h (hash_table<Descriptor, Allocator>::empty_slow): Use
28871 memset instead of value initialization if BROKEN_VALUE_INITIALIZATION
28872 is defined.
28873
28874 PR rtl-optimization/83723
28875 * lra-int.h (lra_substitute_pseudo): Add DEBUG_P argument.
28876 * lra.c (lra_substitute_pseudo): Likewise. If true, use
28877 gen_rtx_raw_SUBREG instead of gen_rtx_SUBREG. Pass DEBUG_P to
28878 recursive calls.
28879 (lra_substitute_pseudo_within_insn): Adjust lra_substitute_pseudo
28880 callers.
28881 * lra-constraints.c (inherit_reload_reg, split_reg): Likewise.
28882
28883 2018-02-16 Eric Botcazou <ebotcazou@adacore.com>
28884
28885 PR rtl-optimization/81443
28886 * rtlanal.c (num_sign_bit_copies1) <SUBREG>: Do not propagate results
28887 from inner REGs to paradoxical SUBREGs.
28888
28889 2018-02-16 Richard Biener <rguenther@suse.de>
28890
28891 PR tree-optimization/84399
28892 * graphite-scop-detection.c (scop_detection::stmt_simple_for_scop_p):
28893 For operands we can analyze at their definition make sure we can
28894 analyze them at each use as well.
28895
28896 2018-02-16 Richard Biener <rguenther@suse.de>
28897
28898 PR tree-optimization/84190
28899 * tree-ssa.c (non_rewritable_mem_ref_base): Do not touch
28900 volatile accesses if the decl isn't volatile.
28901
28902 2018-02-15 Jason Merrill <jason@redhat.com>
28903
28904 PR c++/84314 - ICE with templates and fastcall attribute.
28905 * attribs.c (build_type_attribute_qual_variant): Don't clobber
28906 TYPE_CANONICAL on an existing type.
28907
28908 2018-02-15 Jakub Jelinek <jakub@redhat.com>
28909
28910 PR tree-optimization/84383
28911 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Don't look at
28912 dstoff nor call operand_equal_p if dstbase is NULL.
28913
28914 PR tree-optimization/84334
28915 * match.pd ((A +- CST1) +- CST2 -> A + CST3): If A is
28916 also a CONSTANT_CLASS_P, punt.
28917
28918 2018-02-14 Jim Wilson <jimw@sifive.com>
28919
28920 * config/riscv/riscv.c (riscv_first_stack_step): Move locals after
28921 first SMALL_OPERAND check. New local min_second_step. Move assert
28922 to where locals are set. Add TARGET_RVC support.
28923 * config/riscv/riscv.h (C_SxSP_BITS, SWSP_REACH, SDSP_REACH): New.
28924
28925 2018-02-14 Indu Bhagat <indu.bhagat@oracle.com>
28926
28927 * doc/invoke.texi: Correct -Wformat-overflow code sample.
28928
28929 2018-02-14 Martin Sebor <msebor@redhat.com>
28930
28931 PR tree-optimization/83698
28932 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): For
28933 arrays constrain the offset range to their bounds.
28934 (builtin_access::strcat_overlap): Adjust the bounds of overlap offset.
28935 (builtin_access::overlap): Avoid setting the size of overlap if it's
28936 already been set.
28937 (maybe_diag_overlap): Also consider arrays when deciding what values
28938 of offsets to include in diagnostics.
28939
28940 2018-02-14 Martin Sebor <msebor@redhat.com>
28941
28942 PR c/84108
28943 * attribs.c (diag_attr_exclusions): Consider the exclusion(s)
28944 that correspond to the kind of a declaration.
28945
28946 2018-02-14 John David Anglin <danglin@gcc.gnu.org>
28947
28948 PR target/83984
28949 * config/pa/pa.md: Load address of PIC label using the linkage table
28950 if the label is nonlocal.
28951
28952 2018-02-14 Kelvin Nilsen <kelvin@gcc.gnu.org>
28953
28954 * config/rs6000/rs6000.c (rs6000_option_override_internal): Issue
28955 warning message if user requests -maltivec=be.
28956 * doc/invoke.texi: Document deprecation of -maltivec=be.
28957
28958 2018-02-14 Will Schmidt <will_schmidt@vnet.ibm.com>
28959
28960 PR target/84220
28961 * config/rs6000/rs6000-c.c: Update definitions for
28962 ALTIVEC_BUILTIN_VEC_SLD, ALTIVEC_BUILTIN_VEC_SLDW,
28963 VEC_XXSLDWI and ALTIVEC_BUILTIN_VEC_XXPERMDI builtins.
28964
28965 2018-02-14 Igor Tsimbalist <igor.v.tsimbalist@intel.com>
28966
28967 PR target/84239
28968 * config/i386/cetintrin.h: Remove _rdssp[d|q] and
28969 add _get_ssp intrinsics. Remove argument from
28970 __builtin_ia32_rdssp[d|q].
28971 * config/i386/i386-builtin-types.def: Add UINT_FTYPE_VOID.
28972 * config/i386/i386-builtin.def: Remove argument from
28973 __builtin_ia32_rdssp[d|q].
28974 * config/i386/i386.c: Use UINT_FTYPE_VOID. Use
28975 ix86_expand_special_args_builtin for _rdssp[d|q].
28976 * config/i386/i386.md: Remove argument from rdssp[si|di] insn.
28977 Clear register before usage.
28978 * doc/extend.texi: Remove argument from __builtin_ia32_rdssp[d|q].
28979 Add documentation for new _get_ssp and _inc_ssp intrinsics.
28980
28981 2018-02-14 Richard Sandiford <richard.sandiford@linaro.org>
28982
28983 PR tree-optimization/84357
28984 * tree-data-ref.c (object_address_invariant_in_loop_p): Check
28985 operand 1 of an ARRAY_REF too.
28986
28987 2018-02-14 Oleg Endo <olegendo@gcc.gnu.org>
28988
28989 PR target/83831
28990 * config/rx/rx-protos.h (rx_reg_dead_or_unused_after_insn,
28991 rx_copy_reg_dead_or_unused_notes, rx_fuse_in_memory_bitop): New
28992 declarations.
28993 (set_of_reg): New struct.
28994 (rx_find_set_of_reg, rx_find_use_of_reg): New functions.
28995 * config/rx/rx.c (rx_reg_dead_or_unused_after_insn,
28996 rx_copy_reg_dead_or_unused_notes, rx_fuse_in_memory_bitop): New
28997 functions.
28998 * config/rx/rx.md (andsi3, iorsi3, xorsi3): Convert to insn_and_split.
28999 Split into bitclr, bitset, bitinvert patterns if appropriate.
29000 (*bitset, *bitinvert, *bitclr): Convert to named insn_and_split and
29001 use rx_fuse_in_memory_bitop.
29002 (*bitset_in_memory, *bitinvert_in_memory, *bitclr_in_memory): Convert
29003 to named insn, correct maximum insn length.
29004
29005 2018-02-14 Jozef Lawrynowicz <jozefl.gcc@gmail.com>
29006
29007 PR target/79242
29008 * machmode.def: Define a complex mode for PARTIAL_INT.
29009 * genmodes.c (complex_class): Return MODE_COMPLEX_INT for
29010 MODE_PARTIAL_INT.
29011 * doc/rtl.texi: Document CSPImode.
29012 * config/msp430/msp430.c (msp430_hard_regno_nregs): Add CPSImode
29013 handling.
29014 (msp430_hard_regno_nregs_with_padding): Likewise.
29015
29016 2018-02-13 Peter Bergner <bergner@vnet.ibm.com>
29017
29018 PR target/84279
29019 * config/rs6000/rs6000.c (mem_operand_gpr): Disallow altivec addresses.
29020
29021 2018-02-13 Segher Boessenkool <segher@kernel.crashing.org>
29022
29023 PR rtl-optimization/84169
29024 * combine.c (try_combine): New variable split_i2i3. Set it to true if
29025 we generated a parallel as new i3 and we split that to new i2 and i3
29026 instructions. Handle split_i2i3 similar to swap_i2i3: scan the
29027 LOG_LINKs of i3 to see which of those need to link to i2 now. Link
29028 those to i2, not i1. Partially rewrite this scan code.
29029
29030 2018-02-13 Jakub Jelinek <jakub@redhat.com>
29031
29032 PR c/82210
29033 * stor-layout.c (place_field): For variable length fields, adjust
29034 offset_align afterwards not just based on the field's alignment,
29035 but also on the size.
29036
29037 PR middle-end/84309
29038 * match.pd (pow(C,x) -> exp(log(C)*x)): Use exp2s and log2s instead
29039 of exps and logs in the use_exp2 case.
29040
29041 2018-02-13 Jeff Law <law@redhat.com>
29042
29043 * config/rl/rl78.c (rl78_attribute_table): Fix terminator and
29044 entry for "vector".
29045
29046 * config/rl78/rl78.c (rl78_handle_func_attribute): Mark
29047 ARGS as unused.
29048
29049 2018-02-13 Alexandre Oliva <aoliva@redhat.com>
29050
29051 PR debug/84342
29052 PR debug/84319
29053 * common.opt (gas-loc-support, gas-locview-support): New.
29054 (ginline-points, ginternal-reset-location-views): New.
29055 * doc/invoke.texi: Document them. Use @itemx where intended.
29056 (gvariable-location-views): Adjust.
29057 * target.def (reset_location_view): New.
29058 * doc/tm.texi.in (DWARF2_ASM_VIEW_DEBUG_INFO): New.
29059 (TARGET_RESET_LOCATION_VIEW): New.
29060 * doc/tm.texi: Rebuilt.
29061 * dwarf2out.c (dwarf2out_default_as_loc_support): New.
29062 (dwarf2out_default_as_locview_support): New.
29063 (output_asm_line_debug_info): Use option variables.
29064 (dwarf2out_maybe_output_loclist_view_pair): Likewise.
29065 (output_loc_list): Likewise.
29066 (add_high_low_attributes): Check option variables.
29067 Don't output entry view attribute in strict mode.
29068 (gen_inlined_subroutine_die): Check option variables.
29069 (dwarf2out_inline_entry): Likewise.
29070 (init_sections_and_labels): Likewise.
29071 (dwarf2out_early_finish): Likewise.
29072 (maybe_reset_location_view): New, from...
29073 (dwarf2out_var_location): ... here. Call it.
29074 * debug.h (dwarf2out_default_as_loc_support): Declare.
29075 (dwarf2out_default_as_locview_support): Declare.
29076 * hooks.c (hook_int_rtx_insn_0): New.
29077 * hooks.h (hook_int_rtx_insn_0): Declare.
29078 * toplev.c (process_options): Take -gas-loc-support and
29079 -gas-locview-support from dwarf2out. Enable
29080 -gvariable-location-views by default only with locview
29081 assembler support. Enable -ginternal-reset-location-views by
29082 default only if the target defines the corresponding hook.
29083 Enable -ginline-points by default if location views are
29084 enabled; force it disabled if statement frontiers are
29085 disabled.
29086 * tree-inline.c (expand_call_inline): Check option variables.
29087 * tree-ssa-live.c (remove_unused_scope_block_p): Likewise.
29088
29089 2018-02-13 Richard Sandiford <richard.sandiford@linaro.org>
29090
29091 PR tree-optimization/84321
29092 * tree-vrp.c (intersect_range_with_nonzero_bits): Fix VR_ANTI_RANGE
29093 handling. Also check whether the anti-range contains any values
29094 that satisfy the mask; switch to a VR_RANGE if not.
29095
29096 2018-02-13 Paolo Bonzini <bonzini@gnu.org>
29097
29098 PR sanitizer/84340
29099 * internal-fn.def (ASAN_CHECK, ASAN_MARK): Revert changes to fnspec.
29100
29101 2018-02-13 Martin Jambor <mjambor@suse.cz>
29102
29103 PR c++/83990
29104 * ipa-param-manipulation.c (ipa_modify_call_arguments): Use location
29105 of call statements, also set location of a load to a temporary.
29106
29107 2018-02-13 Sebastian Perta <sebastian.perta@renesas.com>
29108
29109 * config/rl78/rl78.c (add_vector_labels): New function.
29110 * config/rl78/rl78.c (rl78_handle_vector_attribute): New function.
29111 * config/rl78/rl78.c (rl78_start_function): Call add_vector_labels.
29112 * config/rl78/rl78.c (rl78_handle_func_attribute): Removed the assert
29113 which checks that no arguments are passed.
29114 * config/rl78/rl78.c (rl78_attribute_table): Add "vector" attribute.
29115 * doc/extend.texi: Documentation for the new attribute.
29116
29117 2018-02-13 Andreas Schwab <schwab@suse.de>
29118
29119 * config/riscv/linux.h (CPP_SPEC): Define.
29120
29121 2018-02-13 Jakub Jelinek <jakub@redhat.com>
29122
29123 PR target/84335
29124 * config/i386/i386.c (ix86_init_mmx_sse_builtins): Pass
29125 OPTION_MASK_ISA_AES | OPTION_MASK_ISA_SSE2 instead of
29126 OPTION_MASK_ISA_AES as first argument to def_builtin_const
29127 for AES builtins. Pass OPTION_MASK_ISA_PCLMUL | OPTION_MASK_ISA_SSE2
29128 instead of OPTION_MASK_ISA_PCLMUL as first argument to
29129 def_builtin_const for __builtin_ia32_pclmulqdq128 builtin.
29130 * config/i386/wmmintrin.h: If __SSE2__ is not defined, enable it
29131 temporarily for AES and PCLMUL builtins.
29132
29133 PR tree-optimization/84339
29134 * gimple-fold.c (get_range_strlen): Set *FLEXP to true when handling
29135 ARRAY_REF where first operand is array_at_struct_end_p COMPONENT_REF.
29136 Formatting fixes.
29137
29138 PR middle-end/84309
29139 * match.pd (pow(C,x) -> exp(log(C)*x)): Optimize instead into
29140 exp2(log2(C)*x) if C is a power of 2 and c99 runtime is available.
29141 * generic-match-head.c (canonicalize_math_after_vectorization_p): New
29142 inline function.
29143 * gimple-match-head.c (canonicalize_math_after_vectorization_p): New
29144 inline function.
29145 * omp-simd-clone.h: New file.
29146 * omp-simd-clone.c: Include omp-simd-clone.h.
29147 (expand_simd_clones): No longer static.
29148 * tree-vect-patterns.c: Include fold-const-call.h, attribs.h,
29149 cgraph.h and omp-simd-clone.h.
29150 (vect_recog_pow_pattern): Optimize pow(C,x) to exp(log(C)*x).
29151 (vect_recog_widen_shift_pattern): Formatting fix.
29152 (vect_pattern_recog_1): Don't check optab for calls.
29153
29154 PR target/84336
29155 * config/i386/sse.md (<avx512>_vpermi2var<mode>3_mask): Force
29156 operands[2] into a REG before using gen_lowpart on it.
29157
29158 2018-02-12 Jeff Law <law@redhat.com>
29159
29160 PR target/83760
29161 * config/sh/sh.c (find_barrier): Consider a sibling call
29162 a barrier as well.
29163
29164 * cse.c (try_back_substitute_reg): Move any REG_ARGS_SIZE note when
29165 successfully back substituting a reg.
29166
29167 2018-02-12 Richard Biener <rguenther@suse.de>
29168
29169 PR tree-optimization/84037
29170 * tree-vect-slp.c (vect_analyze_slp_cost): Add visited
29171 parameter, move visited init to caller.
29172 (vect_slp_analyze_operations): Separate cost from validity
29173 check, initialize visited once for all instances.
29174 (vect_schedule_slp): Analyze map to CSE vectorized nodes once
29175 for all instances.
29176 * tree-vect-stmts.c (vect_model_simple_cost): Make early
29177 out an assert.
29178 (vect_model_promotion_demotion_cost): Likewise.
29179 (vectorizable_bswap): Guard cost modeling with !slp_node
29180 instead of !PURE_SLP_STMT to avoid double-counting on hybrid
29181 SLP stmts.
29182 (vectorizable_call): Likewise.
29183 (vectorizable_conversion): Likewise.
29184 (vectorizable_assignment): Likewise.
29185 (vectorizable_shift): Likewise.
29186 (vectorizable_operation): Likewise.
29187 (vectorizable_store): Likewise.
29188 (vectorizable_load): Likewise.
29189 (vectorizable_condition): Likewise.
29190 (vectorizable_comparison): Likewise.
29191
29192 2018-02-12 Paolo Bonzini <bonzini@gnu.org>
29193
29194 PR sanitizer/84307
29195 * internal-fn.def (ASAN_CHECK): Fix fnspec to account for return value.
29196 (ASAN_MARK): Fix fnspec to account for return value, change pointer
29197 argument from 'R' to 'W' so that the pointed-to datum is clobbered.
29198
29199 2018-02-08 Jan Hubicka <hubicka@ucw.cz>
29200
29201 PR middle-end/83665
29202 * params.def (inline-min-speedup): Increase from 8 to 15.
29203 (max-inline-insns-auto): Decrease from 40 to 30.
29204 * ipa-split.c (consider_split): Add some buffer for function to
29205 be considered inlining candidate.
29206 * invoke.texi (max-inline-insns-auto, inline-min-speedup): UPdate
29207 default values.
29208
29209 2018-02-12 Richard Biener <rguenther@suse.de>
29210
29211 PR tree-optimization/84037
29212 * tree-vect-slp.c (vect_build_slp_tree_2): Try swapping the
29213 matched stmts if we cannot swap the non-matched ones.
29214
29215 2018-02-12 Olga Makhotina <olga.makhotina@intel.com>
29216
29217 * config/i386/avx512fintrin.h (_mm_mask_scalef_round_sd,
29218 _mm_maskz_scalef_round_sd, _mm_mask_scalef_round_ss,
29219 _mm_maskz_scalef_round_ss): New intrinsics.
29220 (__builtin_ia32_scalefsd_round, __builtin_ia32_scalefss_round): Fix.
29221 * config/i386/i386-builtin.def (__builtin_ia32_scalefsd_round,
29222 __builtin_ia32_scalefss_round): Remove.
29223 (__builtin_ia32_scalefsd_mask_round,
29224 __builtin_ia32_scalefss_mask_round): New intrinsics.
29225 * config/i386/sse.md (vmscalef<mode><round_name>): Renamed to ...
29226 (vmscalef<mode><mask_scalar_name><round_scalar_name>): ... this.
29227 ((match_operand:VF_128 2 "<round_nimm_predicate>"
29228 "<round_constraint>")): Changed to ...
29229 ((match_operand:VF_128 2 "<round_scalar_nimm_predicate>"
29230 "<round_scalar_constraint>")): ... this.
29231 ("vscalef<ssescalarmodesuffix>\t{<round_op3>%2, %1, %0|
29232 %0, %1, %2<round_op3>}"): Changed to ...
29233 ("vscalef<ssescalarmodesuffix>\t{<round_scalar_mask_op3>%2, %1,
29234 %0<mask_scalar_operand3>|%0<mask_scalar_operand3>, %1,
29235 %2<round_scalar_mask_op3>}"): ... this.
29236 * config/i386/subst.md (round_scalar_nimm_predicate): New.
29237
29238 2018-02-12 Olga Makhotina <olga.makhotina@intel.com>
29239
29240 * config/i386/avx512fintrin.h (_mm_mask_sqrt_round_sd)
29241 (_mm_maskz_sqrt_round_sd, _mm_mask_sqrt_round_ss)
29242 (_mm_maskz_sqrt_round_ss): New intrinsics.
29243 (__builtin_ia32_sqrtsd_round, __builtin_ia32_sqrtss_round): Remove.
29244 (__builtin_ia32_sqrtsd_mask_round)
29245 (__builtin_ia32_sqrtss_mask_round): New builtins.
29246 * config/i386/i386-builtin.def (__builtin_ia32_sqrtsd_round)
29247 (__builtin_ia32_sqrtss_round): Remove.
29248 (__builtin_ia32_sqrtsd_mask_round)
29249 (__builtin_ia32_sqrtss_mask_round): New builtins.
29250 * config/i386/sse.md (vmsqrt<mode>2<round_name>): Renamed to ...
29251 (vmsqrt<mode>2<mask_scalar_name><round_scalar_name>): ... this.
29252 ((match_operand:VF_128 1 "vector_operand"
29253 "xBm,<round_constraint>")): Changed to ...
29254 ((match_operand:VF_128 1 "vector_operand"
29255 "xBm,<round_scalar_constraint>")): ... this.
29256 (vsqrt<ssescalarmodesuffix>\t{<round_op3>%1, %2, %0|
29257 %0, %2, %<iptr>1<round_op3>}): Changed to ...
29258 (vsqrt<ssescalarmodesuffix>\t{<round_scalar_mask_op3>%1, %2,
29259 %0<mask_scalar_operand3>|%0<mask_scalar_operand3>, %2,
29260 %<iptr>1<round_scalar_mask_op3>}): ... this.
29261 ((set_attr "prefix" "<round_prefix>")): Changed to ...
29262 ((set_attr "prefix" "<round_scalar_prefix>")): ... this.
29263
29264 2018-02-11 Steven Munroe <munroesj@gcc.gnu.org>
29265
29266 PR target/84266
29267 * config/rs6000/mmintrin.h (_mm_cmpeq_pi32 [_ARCH_PWR9]):
29268 Cast vec_cmpeq result to correct type.
29269 * config/rs6000/mmintrin.h (_mm_cmpgt_pi32 [_ARCH_PWR9]):
29270 Cast vec_cmpgt result to correct type.
29271
29272 2018-02-11 Alexandre Oliva <aoliva@redhat.com>
29273
29274 * final.c (final_scan_insn_1): Renamed from...
29275 (final_scan_insn): ... this. New wrapper, to recover
29276 seen from the outermost call in recursive ones.
29277 * config/sparc/sparc.c (output_return): Drop seen from call.
29278 (output_sibcall): Likewise.
29279 * config/visium/visium.c (output_branch): Likewise.
29280
29281 2018-02-10 John David Anglin <danglin@gcc.gnu.org>
29282
29283 * config/pa/pa.c (hppa_profile_hook): Mark SYMBOL_REF for _mcount as
29284 function label.
29285
29286 2018-02-10 Alan Modra <amodra@gmail.com>
29287
29288 PR target/84300
29289 * config/rs6000/rs6000.md (split_stack_return): Remove (use ..).
29290 Specify LR as an input.
29291
29292 2018-02-10 Jakub Jelinek <jakub@redhat.com>
29293
29294 PR sanitizer/83987
29295 * omp-low.c (maybe_remove_omp_member_access_dummy_vars,
29296 remove_member_access_dummy_vars): New functions.
29297 (lower_omp_for, lower_omp_taskreg, lower_omp_target,
29298 lower_omp_1, execute_lower_omp): Use them.
29299
29300 PR rtl-optimization/84308
29301 * shrink-wrap.c (spread_components): Release todo vector.
29302
29303 2018-02-09 Vladimir Makarov <vmakarov@redhat.com>
29304
29305 PR rtl-optimization/57193
29306 * ira-color.c (struct allocno_color_data): Add member
29307 conflict_allocno_hard_prefs.
29308 (update_conflict_allocno_hard_prefs): New.
29309 (bucket_allocno_compare_func): Add a preference based on
29310 conflict_allocno_hard_prefs.
29311 (push_allocno_to_stack): Update conflict_allocno_hard_prefs.
29312 (color_allocnos): Remove a dead code. Initiate
29313 conflict_allocno_hard_prefs. Call update_costs_from_prefs.
29314
29315 2018-02-09 Jakub Jelinek <jakub@redhat.com>
29316
29317 PR target/84226
29318 * config/rs6000/vsx.md (p9_xxbrq_v16qi): Change input operand
29319 constraint from =wa to wa. Avoid a subreg on the output operand,
29320 instead use a pseudo and subreg it in a move.
29321 (p9_xxbrd_<mode>): Changed to ...
29322 (p9_xxbrd_v2di): ... this insn, without VSX_D iterator.
29323 (p9_xxbrd_v2df): New expander.
29324 (p9_xxbrw_<mode>): Changed to ...
29325 (p9_xxbrw_v4si): ... this insn, without VSX_W iterator.
29326 (p9_xxbrw_v4sf): New expander.
29327
29328 2018-02-09 Sebastian Perta <sebastian.perta@renesas.com>
29329
29330 * config/rx/rx.md (movsicc): Update expander to be matched by GCC.
29331
29332 2018-02-09 Peter Bergner <bergner@vnet.ibm.com>
29333
29334 PR target/83926
29335 * config/rs6000/vsx.md (vsx_mul_v2di): Handle generating a 64-bit
29336 multiply in 32-bit mode.
29337 (vsx_div_v2di): Handle generating a 64-bit signed divide in 32-bit mode.
29338 (vsx_udiv_v2di): Handle generating a 64-bit unsigned divide in 32-bit
29339 mode.
29340
29341 2018-02-09 Sebastian Perta <sebastian.perta@renesas.com>
29342
29343 * config/rx/constraints.md (CALL_OP_SYMBOL_REF): Added new constraint
29344 to allow or block "symbol_ref" depending on the value of TARGET_JSR.
29345 * config/rx/rx.md (call_internal): Use CALL_OP_SYMBOL_REF.
29346 * config/rx/rx.md (call_value_internal): Use CALL_OP_SYMBOL_REF.
29347
29348 2018-02-09 Pierre-Marie de Rodat <derodat@adacore.com>
29349
29350 PR lto/84213
29351 * dwarf2out.c (is_trivial_indirect_ref): New function.
29352 (dwarf2out_late_global_decl): Do not generate a location
29353 attribute for variables that have a non-trivial DECL_VALUE_EXPR
29354 and that are not defined in the current unit.
29355
29356 2018-02-09 Eric Botcazou <ebotcazou@adacore.com>
29357
29358 * optabs.c (prepare_cmp_insn): Try harder to emit a direct comparison
29359 instead of a libcall for UNORDERED.
29360
29361 2018-02-09 Tamar Christina <tamar.christina@arm.com>
29362
29363 PR target/82641
29364 * config/arm/arm-c.c (arm_cpu_builtins): Un-define __ARM_FEATURE_LDREX,
29365 __ARM_ARCH_PROFILE, __ARM_ARCH_ISA_THUMB, __ARM_FP and __ARM_NEON_FP.
29366
29367 2018-02-09 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
29368
29369 PR target/PR84295
29370 * config/s390/s390.c (s390_set_current_function): Invoke
29371 s390_indirect_branch_settings also if fndecl didn't change.
29372
29373 2018-02-09 Alexandre Oliva <aoliva@redhat.com>
29374
29375 * config/rs6000/rs6000.md (blockage): Set length to zero.
29376
29377 2018-02-09 Eric Botcazou <ebotcazou@adacore.com>
29378
29379 * expr.c (optimize_bitfield_assignment_op): Remove obsolete assertion.
29380
29381 2018-02-09 Jakub Jelinek <jakub@redhat.com>
29382
29383 PR sanitizer/84285
29384 * gcc.c (STATIC_LIBASAN_LIBS, STATIC_LIBTSAN_LIBS,
29385 STATIC_LIBLSAN_LIBS, STATIC_LIBUBSAN_LIBS): Handle -static like
29386 -static-lib*san.
29387
29388 PR debug/84252
29389 * var-tracking.c (vt_add_function_parameter): Punt for non-onepart
29390 PARALLEL incoming that failed vt_get_decl_and_offset check.
29391
29392 PR middle-end/84237
29393 * output.h (bss_initializer_p): Add NAMED argument, defaulted to false.
29394 * varasm.c (bss_initializer_p): Add NAMED argument, if true, ignore
29395 TREE_READONLY bit.
29396 (get_variable_section): For decls in named .bss* sections pass true as
29397 second argument to bss_initializer_p.
29398
29399 2018-02-09 Marek Polacek <polacek@redhat.com>
29400 Jakub Jelinek <jakub@redhat.com>
29401
29402 PR c++/83659
29403 * fold-const.c (fold_indirect_ref_1): Use VECTOR_TYPE_P macro.
29404 Formatting fixes. Verify first that tree_fits_poly_int64_p (op01).
29405 Sync some changes from cxx_fold_indirect_ref.
29406
29407 2018-02-09 Alexandre Oliva <aoliva@redhat.com>
29408
29409 * cfgexpand.c (expand_gimple_basic_block): Handle inline entry
29410 markers.
29411 * dwarf2out.c (dwarf2_debug_hooks): Enable inline_entry hook.
29412 (BLOCK_INLINE_ENTRY_LABEL): New.
29413 (dwarf2out_var_location): Disregard inline entry markers.
29414 (inline_entry_data): New struct.
29415 (inline_entry_data_hasher): New hashtable type.
29416 (inline_entry_data_hasher::hash): New.
29417 (inline_entry_data_hasher::equal): New.
29418 (inline_entry_data_table): New variable.
29419 (add_high_low_attributes): Add DW_AT_entry_pc and
29420 DW_AT_GNU_entry_view attributes if a pending entry is found
29421 in inline_entry_data_table. Add old entry_pc attribute only
29422 if debug nonbinding markers are disabled.
29423 (gen_inlined_subroutine_die): Set BLOCK_DIE if nonbinding
29424 markers are enabled.
29425 (block_within_block_p, dwarf2out_inline_entry): New.
29426 (dwarf2out_finish): Check that no entries remained in
29427 inline_entry_data_table.
29428 * final.c (reemit_insn_block_notes): Handle inline entry notes.
29429 (final_scan_insn, notice_source_line): Likewise.
29430 (rest_of_clean_state): Skip inline entry markers.
29431 * gimple-pretty-print.c (dump_gimple_debug): Handle inline entry
29432 markers.
29433 * gimple.c (gimple_build_debug_inline_entry): New.
29434 * gimple.h (enum gimple_debug_subcode): Add
29435 GIMPLE_DEBUG_INLINE_ENTRY.
29436 (gimple_build_debug_inline_entry): Declare.
29437 (gimple_debug_inline_entry_p): New.
29438 (gimple_debug_nonbind_marker_p): Adjust.
29439 * insn-notes.def (INLINE_ENTRY): New.
29440 * print-rtl.c (rtx_writer::print_rtx_operand_code_0): Handle
29441 inline entry marker notes.
29442 (print_insn): Likewise.
29443 * rtl.h (NOTE_MARKER_P): Add INLINE_ENTRY support.
29444 (INSN_DEBUG_MARKER_KIND): Likewise.
29445 (GEN_RTX_DEBUG_MARKER_INLINE_ENTRY_PAT): New.
29446 * tree-inline.c (expand_call_inline): Build and insert
29447 debug_inline_entry stmt.
29448 * tree-ssa-live.c (remove_unused_scope_block_p): Preserve
29449 inline entry blocks early, if nonbind markers are enabled.
29450 (dump_scope_block): Dump fragment info.
29451 * var-tracking.c (reemit_marker_as_note): Handle inline entry note.
29452 * doc/gimple.texi (gimple_debug_inline_entry_p): New.
29453 (gimple_build_debug_inline_entry): New.
29454 * doc/invoke.texi (gstatement-frontiers, gno-statement-frontiers):
29455 Enable/disable inline entry points too.
29456 * doc/rtl.texi (NOTE_INSN_INLINE_ENTRY): New.
29457 (DEBUG_INSN): Describe inline entry markers.
29458
29459 * common.opt (gvariable-location-views): New.
29460 (gvariable-location-views=incompat5): New.
29461 * config.in: Rebuilt.
29462 * configure: Rebuilt.
29463 * configure.ac: Test assembler for view support.
29464 * dwarf2asm.c (dw2_asm_output_symname_uleb128): New.
29465 * dwarf2asm.h (dw2_asm_output_symname_uleb128): Declare.
29466 * dwarf2out.c (var_loc_view): New typedef.
29467 (struct dw_loc_list_struct): Add vl_symbol, vbegin, vend.
29468 (dwarf2out_locviews_in_attribute): New.
29469 (dwarf2out_locviews_in_loclist): New.
29470 (dw_val_equal_p): Compare val_view_list of dw_val_class_view_lists.
29471 (enum dw_line_info_opcode): Add LI_adv_address.
29472 (struct dw_line_info_table): Add view.
29473 (RESET_NEXT_VIEW, RESETTING_VIEW_P): New macros.
29474 (DWARF2_ASM_VIEW_DEBUG_INFO): Define default.
29475 (zero_view_p): New variable.
29476 (ZERO_VIEW_P): New macro.
29477 (output_asm_line_debug_info): New.
29478 (struct var_loc_node): Add view.
29479 (add_AT_view_list, AT_loc_list): New.
29480 (add_var_loc_to_decl): Add view param. Test it against last.
29481 (new_loc_list): Add view params. Record them.
29482 (AT_loc_list_ptr): Handle loc and view lists.
29483 (view_list_to_loc_list_val_node): New.
29484 (print_dw_val): Handle dw_val_class_view_list.
29485 (size_of_die): Likewise.
29486 (value_format): Likewise.
29487 (loc_list_has_views): New.
29488 (gen_llsym): Set vl_symbol too.
29489 (maybe_gen_llsym, skip_loc_list_entry): New.
29490 (dwarf2out_maybe_output_loclist_view_pair): New.
29491 (output_loc_list): Output view list or entries too.
29492 (output_view_list_offset): New.
29493 (output_die): Handle dw_val_class_view_list.
29494 (output_dwarf_version): New.
29495 (output_compilation_unit_header): Use it.
29496 (output_skeleton_debug_sections): Likewise.
29497 (output_rnglists, output_line_info): Likewise.
29498 (output_pubnames, output_aranges): Update version comments.
29499 (output_one_line_info_table): Output view numbers in asm comments.
29500 (dw_loc_list): Determine current endview, pass it to new_loc_list.
29501 Call maybe_gen_llsym.
29502 (loc_list_from_tree_1): Adjust.
29503 (add_AT_location_description): Create view list attribute if
29504 needed, check it's absent otherwise.
29505 (convert_cfa_to_fb_loc_list): Adjust.
29506 (maybe_emit_file): Call output_asm_line_debug_info for test.
29507 (dwarf2out_var_location): Reset views as needed. Precompute
29508 add_var_loc_to_decl args. Call get_attr_min_length only if we have the
29509 attribute. Set view.
29510 (new_line_info_table): Reset next view.
29511 (set_cur_line_info_table): Call output_asm_line_debug_info for test.
29512 (dwarf2out_source_line): Likewise. Output view resets and labels to
29513 the assembler, or select appropriate line info opcodes.
29514 (prune_unused_types_walk_attribs): Handle dw_val_class_view_list.
29515 (optimize_string_length): Catch it. Adjust.
29516 (resolve_addr): Copy vl_symbol along with ll_symbol. Handle
29517 dw_val_class_view_list, and remove it if no longer needed.
29518 (hash_loc_list): Hash view numbers.
29519 (loc_list_hasher::equal): Compare them.
29520 (optimize_location_lists): Check whether a view list symbol is
29521 needed, and whether the locview attribute is present, and
29522 whether they match. Remove the locview attribute if no longer
29523 needed.
29524 (index_location_lists): Call skip_loc_list_entry for test.
29525 (dwarf2out_finish): Call output_asm_line_debug_info for test.
29526 Use output_dwarf_version.
29527 * dwarf2out.h (enum dw_val_class): Add dw_val_class_view_list.
29528 (struct dw_val_node): Add val_view_list.
29529 * final.c (SEEN_NEXT_VIEW): New.
29530 (set_next_view_needed): New.
29531 (clear_next_view_needed): New.
29532 (maybe_output_next_view): New.
29533 (final_start_function): Rename to...
29534 (final_start_function_1): ... this. Take pointer to FIRST,
29535 add SEEN parameter. Emit param bindings in the initial view.
29536 (final_start_function): Reintroduce SEEN-less interface.
29537 (final): Rename to...
29538 (final_1): ... this. Take SEEN parameter. Output final pending
29539 next view at the end.
29540 (final): Reintroduce seen-less interface.
29541 (final_scan_insn): Output pending next view before switching
29542 sections or ending a block. Mark the next view as needed when
29543 outputting variable locations. Notify debug backend of section
29544 changes, and of location view changes.
29545 (rest_of_handle_final): Adjust.
29546 * toplev.c (process_options): Autodetect value for debug variable
29547 location views option. Warn on incompat5 without -gdwarf-5.
29548 * doc/invoke.texi (gvariable-location-views): New.
29549 (gvariable-location-views=incompat5): New.
29550 (gno-variable-location-views): New.
29551
29552 2018-02-08 David Malcolm <dmalcolm@redhat.com>
29553
29554 PR tree-optimization/84136
29555 * tree-cfg.c (find_taken_edge_computed_goto): Remove assertion
29556 that the result of find_edge is non-NULL.
29557
29558 2018-02-08 Sergey Shalnov <sergey.shalnov@intel.com>
29559
29560 PR target/83008
29561 * config/i386/x86-tune-costs.h (skylake_cost): Fix cost of
29562 storing integer register in SImode. Fix cost of 256 and 512
29563 byte aligned SSE register store.
29564
29565 2018-02-08 Sergey Shalnov <sergey.shalnov@intel.com>
29566
29567 * config/i386/i386.c (ix86_multiplication_cost): Fix
29568 multiplication cost for TARGET_AVX512DQ.
29569
29570 2018-02-08 Marek Polacek <polacek@redhat.com>
29571
29572 PR tree-optimization/84238
29573 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Verify the result of
29574 get_range_strlen.
29575
29576 2018-02-08 Richard Sandiford <richard.sandiford@linaro.org>
29577
29578 PR tree-optimization/84265
29579 * tree-vect-stmts.c (vectorizable_store): Don't treat
29580 VMAT_CONTIGUOUS accesses as grouped.
29581 (vectorizable_load): Likewise.
29582
29583 2018-02-08 Richard Sandiford <richard.sandiford@linaro.org>
29584
29585 PR tree-optimization/81635
29586 * wide-int.h (wi::round_down_for_mask, wi::round_up_for_mask): Declare.
29587 * wide-int.cc (wi::round_down_for_mask, wi::round_up_for_mask)
29588 (test_round_for_mask): New functions.
29589 (wide_int_cc_tests): Call test_round_for_mask.
29590 * tree-vrp.h (intersect_range_with_nonzero_bits): Declare.
29591 * tree-vrp.c (intersect_range_with_nonzero_bits): New function.
29592 * tree-data-ref.c (split_constant_offset_1): Use it to refine the
29593 range returned by get_range_info.
29594
29595 2018-02-08 Jan Hubicka <hubicka@ucw.cz>
29596
29597 PR ipa/81360
29598 * cgraph.h (symtab_node::output_to_lto_symbol_table_p): Declare
29599 * symtab.c: Include builtins.h
29600 (symtab_node::output_to_lto_symbol_table_p): Move here
29601 from lto-streamer-out.c:output_symbol_p.
29602 * lto-streamer-out.c (write_symbol): Turn early exit to assert.
29603 (output_symbol_p): Move all logic to symtab.c
29604 (produce_symtab): Update.
29605
29606 2018-02-08 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
29607
29608 * config/s390/s390-opts.h (enum indirect_branch): Define.
29609 * config/s390/s390-protos.h (s390_return_addr_from_memory)
29610 (s390_indirect_branch_via_thunk)
29611 (s390_indirect_branch_via_inline_thunk): Add function prototypes.
29612 (enum s390_indirect_branch_type): Define.
29613 * config/s390/s390.c (struct s390_frame_layout, struct
29614 machine_function): Remove.
29615 (indirect_branch_prez10thunk_mask, indirect_branch_z10thunk_mask)
29616 (indirect_branch_table_label_no, indirect_branch_table_name):
29617 Define variables.
29618 (INDIRECT_BRANCH_NUM_OPTIONS): Define macro.
29619 (enum s390_indirect_branch_option): Define.
29620 (s390_return_addr_from_memory): New function.
29621 (s390_handle_string_attribute): New function.
29622 (s390_attribute_table): Add new attribute handler.
29623 (s390_execute_label): Handle UNSPEC_EXECUTE_JUMP patterns.
29624 (s390_indirect_branch_via_thunk): New function.
29625 (s390_indirect_branch_via_inline_thunk): New function.
29626 (s390_function_ok_for_sibcall): When jumping via thunk disallow
29627 sibling call optimization for non z10 compiles.
29628 (s390_emit_call): Force indirect branch target to be a single
29629 register. Add r1 clobber for non-z10 compiles.
29630 (s390_emit_epilogue): Emit return jump via return_use expander.
29631 (s390_reorg): Handle JUMP_INSNs as execute targets.
29632 (s390_option_override_internal): Perform validity checks for the
29633 new command line options.
29634 (s390_indirect_branch_attrvalue): New function.
29635 (s390_indirect_branch_settings): New function.
29636 (s390_set_current_function): Invoke s390_indirect_branch_settings.
29637 (s390_output_indirect_thunk_function): New function.
29638 (s390_code_end): Implement target hook.
29639 (s390_case_values_threshold): Implement target hook.
29640 (TARGET_ASM_CODE_END, TARGET_CASE_VALUES_THRESHOLD): Define target
29641 macros.
29642 * config/s390/s390.h (struct s390_frame_layout)
29643 (struct machine_function): Move here from s390.c.
29644 (TARGET_INDIRECT_BRANCH_NOBP_RET)
29645 (TARGET_INDIRECT_BRANCH_NOBP_JUMP)
29646 (TARGET_INDIRECT_BRANCH_NOBP_JUMP_THUNK)
29647 (TARGET_INDIRECT_BRANCH_NOBP_JUMP_INLINE_THUNK)
29648 (TARGET_INDIRECT_BRANCH_NOBP_CALL)
29649 (TARGET_DEFAULT_INDIRECT_BRANCH_TABLE)
29650 (TARGET_INDIRECT_BRANCH_THUNK_NAME_EXRL)
29651 (TARGET_INDIRECT_BRANCH_THUNK_NAME_EX)
29652 (TARGET_INDIRECT_BRANCH_TABLE): Define macros.
29653 * config/s390/s390.md (UNSPEC_EXECUTE_JUMP)
29654 (INDIRECT_BRANCH_THUNK_REGNUM): Define constants.
29655 (mnemonic attribute): Add values which aren't recognized
29656 automatically.
29657 ("*cjump_long", "*icjump_long", "*basr", "*basr_r"): Disable
29658 pattern for branch conversion. Fix mnemonic attribute.
29659 ("*c<code>", "*sibcall_br", "*sibcall_value_br", "*return"): Emit
29660 indirect branch via thunk if requested.
29661 ("indirect_jump", "<code>"): Expand patterns for branch conversion.
29662 ("*indirect_jump"): Disable for branch conversion using out of
29663 line thunks.
29664 ("indirect_jump_via_thunk<mode>_z10")
29665 ("indirect_jump_via_thunk<mode>")
29666 ("indirect_jump_via_inlinethunk<mode>_z10")
29667 ("indirect_jump_via_inlinethunk<mode>", "*casesi_jump")
29668 ("casesi_jump_via_thunk<mode>_z10", "casesi_jump_via_thunk<mode>")
29669 ("casesi_jump_via_inlinethunk<mode>_z10")
29670 ("casesi_jump_via_inlinethunk<mode>", "*basr_via_thunk<mode>_z10")
29671 ("*basr_via_thunk<mode>", "*basr_r_via_thunk_z10")
29672 ("*basr_r_via_thunk", "return<mode>_prez10"): New pattern.
29673 ("*indirect2_jump"): Disable for branch conversion.
29674 ("casesi_jump"): Turn into expander and expand patterns for branch
29675 conversion.
29676 ("return_use"): New expander.
29677 ("*return"): Emit return via thunk and rename it to ...
29678 ("*return<mode>"): ... this one.
29679 * config/s390/s390.opt: Add new options and and enum for the
29680 option values.
29681
29682 2018-02-08 Richard Sandiford <richard.sandiford@linaro.org>
29683
29684 * lra-constraints.c (match_reload): Unconditionally use
29685 gen_lowpart_SUBREG, rather than selecting between that
29686 and equivalent gen_rtx_SUBREG code.
29687
29688 2018-02-08 Richard Biener <rguenther@suse.de>
29689
29690 PR tree-optimization/84233
29691 * tree-ssa-phiprop.c (propagate_with_phi): Use separate
29692 changed flag instead of boguously re-using phi_inserted.
29693
29694 2018-02-08 Martin Jambor <mjambor@suse.cz>
29695
29696 * hsa-gen.c (get_symbol_for_decl): Set program allocation for
29697 static local variables.
29698
29699 2018-02-08 Richard Biener <rguenther@suse.de>
29700
29701 PR tree-optimization/84278
29702 * tree-vect-stmts.c (vectorizable_store): When looking for
29703 smaller vector types to perform grouped strided loads/stores
29704 make sure the mode is supported by the target.
29705 (vectorizable_load): Likewise.
29706
29707 2018-02-08 Wilco Dijkstra <wdijkstr@arm.com>
29708
29709 * config/aarch64/aarch64.c (aarch64_components_for_bb):
29710 Increase LDP/STP opportunities by adding adjacent callee-saves.
29711
29712 2018-02-08 Wilco Dijkstra <wdijkstr@arm.com>
29713
29714 PR rtl-optimization/84068
29715 PR rtl-optimization/83459
29716 * haifa-sched.c (rank_for_schedule): Fix SCHED_PRESSURE_MODEL sorting.
29717
29718 2018-02-08 Aldy Hernandez <aldyh@redhat.com>
29719
29720 PR tree-optimization/84224
29721 * gimple-ssa-warn-alloca.c (pass_walloca::execute): Remove assert.
29722 * calls.c (gimple_alloca_call_p): Only return TRUE when we have
29723 non-zero arguments.
29724
29725 2018-02-07 Iain Sandoe <iain@codesourcery.com>
29726
29727 PR target/84113
29728 * config/rs6000/altivec.md (*restore_world): Remove LR use.
29729 * config/rs6000/predicates.md (restore_world_operation): Adjust op
29730 count, remove one USE.
29731
29732 2018-02-07 Michael Meissner <meissner@linux.vnet.ibm.com>
29733
29734 * doc/install.texi (Configuration): Document the
29735 --with-long-double-format={ibm,ieee} PowerPC configuration
29736 options.
29737
29738 PR target/84154
29739 * config/rs6000/rs6000.md (fix_trunc<SFDF:mode><QHI:mode>2):
29740 Convert from define_expand to be define_insn_and_split. Rework
29741 float/double/_Float128 conversions to QI/HI/SImode to work with
29742 both ISA 2.07 (power8) or ISA 3.0 (power9). Fix regression where
29743 conversions to QI/HImode types did a store and then a load to
29744 truncate the value. For conversions to VSX registers, don't split
29745 the insn, instead emit the code directly. Use the code iterator
29746 any_fix to combine signed and unsigned conversions.
29747 (fix<uns>_trunc<SFDF:mode>si2_p8): Likewise.
29748 (fixuns_trunc<SFDF:mode><QHI:mode>2): Likewise.
29749 (fix_trunc<IEEE128:mode><QHI:mode>2): Likewise.
29750 (fix<uns>_trunc<SFDF:mode><QHI:mode>2): Likewise.
29751 (fix_<mode>di2_hw): Likewise.
29752 (fixuns_<mode>di2_hw): Likewise.
29753 (fix_<mode>si2_hw): Likewise.
29754 (fixuns_<mode>si2_hw): Likewise.
29755 (fix<uns>_<IEEE128:mode><SDI:mode>2_hw): Likewise.
29756 (fix<uns>_trunc<IEEE128:mode><QHI:mode>2): Likewise.
29757 (fctiw<u>z_<mode>_smallint): Rename fctiw<u>z_<mode>_smallint to
29758 fix<uns>_trunc<SFDF:mode>si2_p8.
29759 (fix_trunc<SFDF:mode><QHI:mode>2_internal): Delete, no longer used.
29760 (fixuns_trunc<SFDF:mode><QHI:mode>2_internal): Likewise.
29761 (fix<uns>_<mode>_mem): Likewise.
29762 (fctiw<u>z_<mode>_mem): Likewise.
29763 (fix<uns>_<mode>_mem): Likewise.
29764 (fix<uns>_trunc<SFDF:mode><QHSI:mode>2_mem): On ISA 3.0, prevent
29765 the register allocator from doing a direct move to the GPRs to do
29766 a store, and instead use the ISA 3.0 store byte/half-word from
29767 vector register instruction. For IEEE 128-bit floating point,
29768 also optimize stores of 32-bit ints.
29769 (fix<uns>_trunc<IEEE128:mode><QHSI:mode>2_mem): Likewise.
29770
29771 2018-02-07 Alan Hayward <alan.hayward@arm.com>
29772
29773 * genextract.c (push_pathstr_operand): New function to support
29774 [a-zA-Z].
29775 (walk_rtx): Call push_pathstr_operand.
29776 (print_path): Support [a-zA-Z].
29777
29778 2018-02-07 Richard Biener <rguenther@suse.de>
29779
29780 PR tree-optimization/84037
29781 * tree-vectorizer.h (struct _loop_vec_info): Add ivexpr_map member.
29782 (cse_and_gimplify_to_preheader): Declare.
29783 (vect_get_place_in_interleaving_chain): Likewise.
29784 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Initialize
29785 ivexpr_map.
29786 (_loop_vec_info::~_loop_vec_info): Delete it.
29787 (cse_and_gimplify_to_preheader): New function.
29788 * tree-vect-slp.c (vect_get_place_in_interleaving_chain): Export.
29789 * tree-vect-stmts.c (vectorizable_store): CSE base and steps.
29790 (vectorizable_load): Likewise. For grouped stores always base
29791 the IV on the first element.
29792 * tree-vect-loop-manip.c (vect_loop_versioning): Unshare versioning
29793 condition before gimplifying.
29794
29795 2018-02-07 Jakub Jelinek <jakub@redhat.com>
29796
29797 * tree-eh.c (operation_could_trap_helper_p): Ignore honor_trapv for
29798 *DIV_EXPR and *MOD_EXPR.
29799
29800 2018-02-07 H.J. Lu <hongjiu.lu@intel.com>
29801
29802 PR target/84248
29803 * config/i386/i386.c (ix86_option_override_internal): Mask out
29804 the CF_SET bit when checking -fcf-protection.
29805
29806 2018-02-07 Tom de Vries <tom@codesourcery.com>
29807
29808 PR libgomp/84217
29809 * omp-expand.c (expand_oacc_collapse_init): Ensure diff_type is large
29810 enough.
29811
29812 2018-02-07 Richard Biener <rguenther@suse.de>
29813
29814 PR tree-optimization/84204
29815 * tree-chrec.c (chrec_fold_plus_1): Remove size limiting in
29816 this place.
29817
29818 PR tree-optimization/84205
29819 * graphite-isl-ast-to-gimple.c (binary_op_to_tree): Also
29820 special-case isl_ast_op_zdiv_r.
29821
29822 PR tree-optimization/84223
29823 * graphite-scop-detection.c (gather_bbs::before_dom_children):
29824 Only add conditions from within the region.
29825 (gather_bbs::after_dom_children): Adjust.
29826
29827 2018-02-07 Georg-Johann Lay <avr@gjlay.de>
29828
29829 PR target/84209
29830 * config/avr/avr.h (GENERAL_REGNO_P, GENERAL_REG_P): New macros.
29831 * config/avr/avr.md: Only post-reload split REG-REG moves if
29832 either register is GENERAL_REG_P.
29833
29834 2018-02-07 Jakub Jelinek <jakub@redhat.com>
29835
29836 PR tree-optimization/84235
29837 * tree-ssa-scopedtables.c
29838 (avail_exprs_stack::simplify_binary_operation): Fir MINUS_EXPR, punt
29839 if the subtraction is performed in floating point type where NaNs are
29840 honored. For *DIV_EXPR, punt for ALL_FRACT_MODE_Ps where we can't
29841 build 1. Formatting fix.
29842
29843 2018-02-06 Jakub Jelinek <jakub@redhat.com>
29844
29845 PR target/84146
29846 * config/i386/i386.c (rest_of_insert_endbranch): Only skip
29847 NOTE_INSN_CALL_ARG_LOCATION after a call, not anything else,
29848 and skip it regardless of bb boundaries. Use CALL_P macro,
29849 don't test INSN_P (insn) together with CALL_P or JUMP_P check
29850 unnecessarily, formatting fix.
29851
29852 2018-02-06 Michael Collison <michael.collison@arm.com>
29853
29854 * config/arm/thumb2.md:
29855 (*thumb2_mov_negscc): Split only if TARGET_THUMB2 && !arm_restrict_it.
29856 (*thumb_mov_notscc): Ditto.
29857
29858 2018-02-06 Michael Meissner <meissner@linux.vnet.ibm.com>
29859
29860 PR target/84154
29861 * config/rs6000/rs6000.md (su code attribute): Use "u" for
29862 unsigned_fix, not "s".
29863
29864 2018-02-06 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
29865
29866 * configure.ac (gcc_fn_eh_frame_ro): New function.
29867 (gcc_cv_as_cfi_directive): Check both 32 and 64-bit assembler for
29868 correct .eh_frame permissions.
29869 * configure: Regenerate.
29870
29871 2018-02-06 Andrew Jenner <andrew@codeourcery.com>
29872
29873 * doc/invoke.texi: Add section for the PowerPC SPE backend. Remove
29874 irrelevant options.
29875
29876 2018-02-06 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
29877
29878 * config/rs6000/rs6000.c (rs6000_option_override_internal):
29879 Display warning message for -mno-speculate-indirect-jumps.
29880
29881 2018-02-06 Andrew Jenner <andrew@codesourcery.com>
29882
29883 * config/powerpcspe/powerpcspe.opt: (msimple-fpu, mfpu) Add
29884 Undocumented.
29885 * config/powerpcspe/sysv4.opt (mbit-align): Likewise.
29886
29887 2018-02-06 Aldy Hernandez <aldyh@redhat.com>
29888
29889 PR tree-optimization/84225
29890 * tree-eh.c (find_trapping_overflow): Only call
29891 operation_no_trapping_overflow when ANY_INTEGRAL_TYPE_P.
29892
29893 2018-02-06 Igor Tsimbalist <igor.v.tsimbalist@intel.com>
29894
29895 PR target/84145
29896 * config/i386/i386.c: Reimplement the check of possible options
29897 -mibt/-mshstk conbination. Change error messages.
29898 * doc/invoke.texi: Fix a typo: remove extra '='.
29899
29900 2018-02-06 Marek Polacek <polacek@redhat.com>
29901
29902 PR tree-optimization/84228
29903 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Skip debug statements.
29904
29905 2018-02-06 Tamar Christina <tamar.christina@arm.com>
29906
29907 PR target/82641
29908 * config/arm/arm.c (arm_print_asm_arch_directives): Record already
29909 emitted arch directives.
29910 * config/arm/arm-c.c (arm_cpu_builtins): Undefine __ARM_ARCH and
29911 __ARM_FEATURE_COPROC before changing architectures.
29912
29913 2018-02-06 Richard Biener <rguenther@suse.de>
29914
29915 * config/i386/i386.c (print_reg): Fix typo.
29916 (ix86_loop_unroll_adjust): Do not unroll beyond the original nunroll.
29917
29918 2018-02-06 Eric Botcazou <ebotcazou@adacore.com>
29919
29920 * configure: Regenerate.
29921
29922 2018-02-05 Martin Sebor <msebor@redhat.com>
29923
29924 PR tree-optimization/83369
29925 * tree-ssa-ccp.c (pass_post_ipa_warn::execute): Use %G to print
29926 inlining context.
29927
29928 2018-02-05 Martin Liska <mliska@suse.cz>
29929
29930 * doc/invoke.texi: Cherry-pick upstream r323995.
29931
29932 2018-02-05 Richard Sandiford <richard.sandiford@linaro.org>
29933
29934 * ira.c (ira_init_register_move_cost): Adjust comment.
29935
29936 2018-02-05 Martin Liska <mliska@suse.cz>
29937
29938 PR gcov-profile/84137
29939 * doc/gcov.texi: Fix typo in documentation.
29940
29941 2018-02-05 Martin Liska <mliska@suse.cz>
29942
29943 PR gcov-profile/83879
29944 * doc/gcov.texi: Document necessity of --dynamic-list-data when
29945 using dlopen functionality.
29946
29947 2018-02-05 Olga Makhotina <olga.makhotina@intel.com>
29948
29949 * config/i386/avx512dqintrin.h (_mm_mask_range_sd, _mm_maskz_range_sd,
29950 _mm_mask_range_round_sd, _mm_maskz_range_round_sd, _mm_mask_range_ss,
29951 _mm_maskz_range_ss, _mm_mask_range_round_ss,
29952 _mm_maskz_range_round_ss): New intrinsics.
29953 (__builtin_ia32_rangesd128_round)
29954 (__builtin_ia32_rangess128_round): Remove.
29955 (__builtin_ia32_rangesd128_mask_round,
29956 __builtin_ia32_rangess128_mask_round): New builtins.
29957 * config/i386/i386-builtin.def (__builtin_ia32_rangesd128_round,
29958 __builtin_ia32_rangess128_round): Remove.
29959 (__builtin_ia32_rangesd128_mask_round,
29960 __builtin_ia32_rangess128_mask_round): New builtins.
29961 * config/i386/sse.md (ranges<mode><round_saeonly_name>): Renamed to ...
29962 (ranges<mode><mask_scalar_name><round_saeonly_scalar_name>): ... this.
29963 ((match_operand:VF_128 2 "<round_saeonly_nimm_predicate>"
29964 "<round_saeonly_constraint>")): Changed to ...
29965 ((match_operand:VF_128 2 "<round_saeonly_scalar_nimm_predicate>"
29966 "<round_saeonly_scalar_constraint>")): ... this.
29967 ("vrange<ssescalarmodesuffix>\t{%3, <round_saeonly_op4>%2, %1, %0|
29968 %0, %1, %2<round_saeonly_op4>, %3}"): Changed to ...
29969 ("vrange<ssescalarmodesuffix>\t{%3, <round_saeonly_scalar_mask_op4>%2,
29970 %1, %0<mask_scalar_operand4>|%0<mask_scalar_operand4>, %1,
29971 %2<round_saeonly_scalar_mask_op4>, %3}"): ... this.
29972
29973 2018-02-02 Andrew Jenner <andrew@codesourcery.com>
29974
29975 * config/powerpcspe/powerpcspe.opt: Add Undocumented to irrelevant
29976 options.
29977 * config/powerpcspe/powerpcspe-tables.opt (rs6000_cpu_opt_value):
29978 Remove all values except native, 8540 and 8548.
29979
29980 2018-02-02 H.J. Lu <hongjiu.lu@intel.com>
29981
29982 * config/i386/i386.c (ix86_output_function_return): Pass
29983 INVALID_REGNUM, instead of -1, as invalid register number to
29984 indirect_thunk_name and output_indirect_thunk.
29985
29986 2018-02-02 Julia Koval <julia.koval@intel.com>
29987
29988 * config.gcc: Add -march=icelake.
29989 * config/i386/driver-i386.c (host_detect_local_cpu): Detect icelake.
29990 * config/i386/i386-c.c (ix86_target_macros_internal): Handle icelake.
29991 * config/i386/i386.c (processor_costs): Add m_ICELAKE.
29992 (PTA_ICELAKE, PTA_AVX512VNNI, PTA_GFNI, PTA_VAES, PTA_AVX512VBMI2,
29993 PTA_VPCLMULQDQ, PTA_RDPID, PTA_AVX512BITALG): New.
29994 (processor_target_table): Add icelake.
29995 (ix86_option_override_internal): Handle new PTAs.
29996 (get_builtin_code_for_version): Handle icelake.
29997 (M_INTEL_COREI7_ICELAKE): New.
29998 (fold_builtin_cpu): Handle icelake.
29999 * config/i386/i386.h (TARGET_ICELAKE, PROCESSOR_ICELAKE): New.
30000 * doc/invoke.texi: Add -march=icelake.
30001
30002 2018-02-02 Julia Koval <julia.koval@intel.com>
30003
30004 * config/i386/i386.c (ix86_option_override_internal): Change flags type
30005 to wide_int_bitmask.
30006 * wide-int-bitmask.h: New.
30007
30008 2018-02-02 Igor Tsimbalist <igor.v.tsimbalist@intel.com>
30009
30010 PR target/84066
30011 * config/i386/i386.md: Replace Pmode with word_mode in
30012 builtin_setjmp_setup and builtin_longjmp to support x32.
30013
30014 2018-02-01 Peter Bergner <bergner@vnet.ibm.com>
30015
30016 PR target/56010
30017 PR target/83743
30018 * config/rs6000/driver-rs6000.c: #include "diagnostic.h".
30019 #include "opts.h".
30020 (rs6000_supported_cpu_names): New static variable.
30021 (linux_cpu_translation_table): Likewise.
30022 (elf_platform) <cpu>: Define new static variable and use it.
30023 Translate kernel AT_PLATFORM name to canonical name if needed.
30024 Error if platform name is unknown.
30025
30026 2018-02-01 Aldy Hernandez <aldyh@redhat.com>
30027
30028 PR target/84089
30029 * config/pa/predicates.md (base14_operand): Handle E_VOIDmode.
30030
30031 2018-02-01 Jeff Law <law@redhat.com>
30032
30033 PR target/84128
30034 * config/i386/i386.c (release_scratch_register_on_entry): Add new
30035 OFFSET and RELEASE_VIA_POP arguments. Use SP+OFFSET to restore
30036 the scratch if RELEASE_VIA_POP is false.
30037 (ix86_adjust_stack_and_probe_stack_clash): Un-constify SIZE.
30038 If we have to save a temporary register, decrement SIZE appropriately.
30039 Pass new arguments to release_scratch_register_on_entry.
30040 (ix86_adjust_stack_and_probe): Likewise.
30041 (ix86_emit_probe_stack_range): Pass new arguments to
30042 release_scratch_register_on_entry.
30043
30044 2018-02-01 Uros Bizjak <ubizjak@gmail.com>
30045
30046 PR rtl-optimization/84157
30047 * combine.c (change_zero_ext): Use REG_P predicate in
30048 front of HARD_REGISTER_P predicate.
30049
30050 2018-02-01 Georg-Johann Lay <avr@gjlay.de>
30051
30052 * config/avr/avr.c (avr_option_override): Move disabling of
30053 -fdelete-null-pointer-checks to...
30054 * common/config/avr/avr-common.c (avr_option_optimization_table):
30055 ...here.
30056
30057 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
30058
30059 PR tree-optimization/81635
30060 * tree-data-ref.c (split_constant_offset_1): For types that
30061 wrap on overflow, try to use range info to prove that wrapping
30062 cannot occur.
30063
30064 2018-02-01 Renlin Li <renlin.li@arm.com>
30065
30066 PR target/83370
30067 * config/aarch64/aarch64.c (aarch64_class_max_nregs): Handle
30068 TAILCALL_ADDR_REGS.
30069 (aarch64_register_move_cost): Likewise.
30070 * config/aarch64/aarch64.h (reg_class): Rename CALLER_SAVE_REGS to
30071 TAILCALL_ADDR_REGS.
30072 (REG_CLASS_NAMES): Likewise.
30073 (REG_CLASS_CONTENTS): Rename CALLER_SAVE_REGS to
30074 TAILCALL_ADDR_REGS. Remove IP registers.
30075 * config/aarch64/aarch64.md (Ucs): Update register constraint.
30076
30077 2018-02-01 Richard Biener <rguenther@suse.de>
30078
30079 * domwalk.h (dom_walker::dom_walker): Add additional constructor
30080 for specifying RPO order and allow NULL for that.
30081 * domwalk.c (dom_walker::dom_walker): Likewise.
30082 (dom_walker::walk): Handle NULL RPO order.
30083 * tree-into-ssa.c (rewrite_dom_walker): Do not walk dom children
30084 in RPO order.
30085 (rewrite_update_dom_walker): Likewise.
30086 (mark_def_dom_walker): Likewise.
30087
30088 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
30089
30090 * config/aarch64/aarch64-protos.h (aarch64_split_sve_subreg_move)
30091 (aarch64_maybe_expand_sve_subreg_move): Declare.
30092 * config/aarch64/aarch64.md (UNSPEC_REV_SUBREG): New unspec.
30093 * config/aarch64/predicates.md (aarch64_any_register_operand): New
30094 predicate.
30095 * config/aarch64/aarch64-sve.md (mov<mode>): Optimize subreg moves
30096 that are semantically a reverse operation.
30097 (*aarch64_sve_mov<mode>_subreg_be): New pattern.
30098 * config/aarch64/aarch64.c (aarch64_maybe_expand_sve_subreg_move):
30099 (aarch64_replace_reg_mode, aarch64_split_sve_subreg_move): New
30100 functions.
30101 (aarch64_can_change_mode_class): For big-endian, forbid changes
30102 between two SVE modes if they have different element sizes.
30103
30104 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
30105
30106 * config/aarch64/aarch64.c (aarch64_expand_sve_const_vector): Prefer
30107 the TImode handling for big-endian targets.
30108
30109 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
30110
30111 * config/aarch64/aarch64-sve.md (sve_ld1rq): Replace with...
30112 (*sve_ld1rq<Vesize>): ... this new pattern. Handle all element sizes,
30113 not just bytes.
30114 * config/aarch64/aarch64.c (aarch64_expand_sve_widened_duplicate):
30115 Remove BSWAP handing for big-endian targets and use the form of
30116 LD1RQ appropariate for the mode.
30117
30118 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
30119
30120 * config/aarch64/aarch64.c (aarch64_simd_valid_immediate): Handle
30121 all CONST_VECTOR_DUPLICATE_P vectors, not just those with a single
30122 duplicated element.
30123
30124 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
30125
30126 PR tearget/83845
30127 * config/aarch64/aarch64.c (aarch64_secondary_reload): Tighten
30128 check for operands that need to go through aarch64_sve_reload_be.
30129
30130 2018-02-01 Jakub Jelinek <jakub@redhat.com>
30131
30132 PR tree-optimization/81661
30133 PR tree-optimization/84117
30134 * tree-eh.h (rewrite_to_non_trapping_overflow): Declare.
30135 * tree-eh.c: Include gimplify.h.
30136 (find_trapping_overflow, replace_trapping_overflow,
30137 rewrite_to_non_trapping_overflow): New functions.
30138 * tree-vect-loop.c: Include tree-eh.h.
30139 (vect_get_loop_niters): Use rewrite_to_non_trapping_overflow.
30140 * tree-data-ref.c: Include tree-eh.h.
30141 (get_segment_min_max): Use rewrite_to_non_trapping_overflow.
30142
30143 2018-01-31 Uros Bizjak <ubizjak@gmail.com>
30144
30145 PR rtl-optimization/84123
30146 * combine.c (change_zero_ext): Check if hard register satisfies
30147 can_change_dest_mode before calling gen_lowpart_SUBREG.
30148
30149 2018-01-31 Vladimir Makarov <vmakarov@redhat.com>
30150
30151 PR target/82444
30152 * ira.c (ira_init_register_move_cost): Remove assert.
30153
30154 2018-01-31 Eric Botcazou <ebotcazou@adacore.com>
30155
30156 PR rtl-optimization/84071
30157 * doc/tm.texi.in (WORD_REGISTER_OPERATIONS): Add explicit case.
30158 * doc/tm.texi: Regenerate.
30159
30160 2018-01-31 Richard Biener <rguenther@suse.de>
30161
30162 PR tree-optimization/84132
30163 * tree-data-ref.c (analyze_miv_subscript): Properly
30164 check whether evolution_function_is_affine_multivariate_p
30165 before calling gcd_of_steps_may_divide_p.
30166
30167 2018-01-31 Julia Koval <julia.koval@intel.com>
30168
30169 PR target/83618
30170 * config/i386/i386.c (ix86_expand_builtin): Handle IX86_BUILTIN_RDPID.
30171 * config/i386/i386.md (rdpid_rex64) New.
30172 (rdpid): Make 32bit only.
30173
30174 2018-01-29 Aldy Hernandez <aldyh@redhat.com>
30175
30176 PR lto/84105
30177 * tree-pretty-print.c (dump_generic_node): Handle a TYPE_NAME with
30178 an IDENTIFIER_NODE for FUNCTION_TYPE's.
30179
30180 2018-01-31 Eric Botcazou <ebotcazou@adacore.com>
30181
30182 Revert
30183 2018-01-12 Eric Botcazou <ebotcazou@adacore.com>
30184
30185 * config/sparc/sparc.md (vxworks_load_got): Set the GOT register.
30186
30187 2018-01-31 Eric Botcazou <ebotcazou@adacore.com>
30188
30189 PR rtl-optimization/84071
30190 * combine.c (record_dead_and_set_regs_1): Record the source unmodified
30191 for a paradoxical SUBREG on a WORD_REGISTER_OPERATIONS target.
30192
30193 2018-01-31 Claudiu Zissulescu <claziss@synopsys.com>
30194
30195 * config/arc/arc.c (arc_handle_aux_attribute): New function.
30196 (arc_attribute_table): Add 'aux' attribute.
30197 (arc_in_small_data_p): Consider aux like variables.
30198 (arc_is_aux_reg_p): New function.
30199 (arc_asm_output_aligned_decl_local): Ignore 'aux' like variables.
30200 (arc_get_aux_arg): New function.
30201 (prepare_move_operands): Handle aux-register access.
30202 (arc_handle_aux_attribute): New function.
30203 * doc/extend.texi (ARC Variable attributes): Add subsection.
30204
30205 2018-01-31 Claudiu Zissulescu <claziss@synopsys.com>
30206
30207 * config/arc/arc-protos.h (arc_is_uncached_mem_p): Function proto.
30208 * config/arc/arc.c (arc_handle_uncached_attribute): New function.
30209 (arc_attribute_table): Add 'uncached' attribute.
30210 (arc_print_operand): Print '.di' flag for uncached memory
30211 accesses.
30212 (arc_in_small_data_p): Do not consider for small data the uncached
30213 types.
30214 (arc_is_uncached_mem_p): New function.
30215 * config/arc/predicates.md (compact_store_memory_operand): Check
30216 for uncached memory accesses.
30217 (nonvol_nonimm_operand): Likewise.
30218 * doc/extend.texi (ARC Type Attribute): New subsection.
30219
30220 2018-01-31 Jakub Jelinek <jakub@redhat.com>
30221
30222 PR c/84100
30223 * common.opt (falign-functions=, falign-jumps=, falign-labels=,
30224 falign-loops=): Add Optimization flag.
30225
30226 2018-01-30 Jeff Law <law@redhat.com>
30227
30228 PR target/84064
30229 * i386.c (ix86_adjust_stack_and_probe_stack_clash): New argument
30230 INT_REGISTERS_SAVED. Check it prior to calling
30231 get_scratch_register_on_entry.
30232 (ix86_adjust_stack_and_probe): Similarly.
30233 (ix86_emit_probe_stack_range): Similarly.
30234 (ix86_expand_prologue): Corresponding changes.
30235
30236 2018-01-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
30237
30238 PR target/40411
30239 * config/sol2.h (STARTFILE_ARCH_SPEC): Use -std=c*,
30240 -std=iso9899:199409 instead of -pedantic to select values-Xc.o.
30241
30242 2018-01-30 Vladimir Makarov <vmakarov@redhat.com>
30243
30244 PR target/84112
30245 * lra-constraints.c (curr_insn_transform): Process AND in the
30246 address.
30247
30248 2018-01-30 Jakub Jelinek <jakub@redhat.com>
30249
30250 PR rtl-optimization/83986
30251 * sched-deps.c (sched_analyze_insn): For frame related insns, add anti
30252 dependence against last_pending_memory_flush in addition to
30253 pending_jump_insns.
30254
30255 2018-01-30 Alexandre Oliva <aoliva@redhat.com>
30256
30257 PR tree-optimization/81611
30258 * tree-ssa-dom.c (simple_iv_increment_p): Skip intervening
30259 copies.
30260
30261 2018-01-30 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
30262
30263 PR target/83758
30264 * config/rs6000/rs6000.c (rs6000_internal_arg_pointer): Only return
30265 a reg rtx.
30266
30267 2018-01-30 Richard Biener <rguenther@suse.de>
30268 Jakub Jelinek <jakub@redhat.com>
30269
30270 PR tree-optimization/84111
30271 * tree-ssa-loop-ivcanon.c (tree_unroll_loops_completely_1): Skip
30272 inner loops added during recursion, as they don't have up-to-date
30273 SSA form.
30274
30275 2018-01-30 Jan Hubicka <hubicka@ucw.cz>
30276
30277 PR ipa/81360
30278 * ipa-inline.c (can_inline_edge_p): Break out late tests to...
30279 (can_inline_edge_by_limits_p): ... here.
30280 (can_early_inline_edge_p, check_callers,
30281 update_caller_keys, update_callee_keys, recursive_inlining,
30282 add_new_edges_to_heap, speculation_useful_p,
30283 inline_small_functions,
30284 inline_small_functions, flatten_function,
30285 inline_to_all_callers_1): Update.
30286
30287 2018-01-30 Jan Hubicka <hubicka@ucw.cz>
30288
30289 * profile-count.c (profile_count::combine_with_ipa_count): Handle
30290 zeros correctly.
30291
30292 2018-01-30 Richard Biener <rguenther@suse.de>
30293
30294 PR tree-optimization/83008
30295 * tree-vect-slp.c (vect_analyze_slp_cost_1): Properly cost
30296 invariant and constant vector uses in stmts when they need
30297 more than one stmt.
30298
30299 2018-01-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
30300
30301 PR bootstrap/84017
30302 * configure.ac (gcc_cv_as_shf_merge): Disable on Solaris 10/x86.
30303 * configure: Regenerate.
30304
30305 2018-01-30 Richard Sandiford <richard.sandiford@linaro.org>
30306
30307 * config/aarch64/aarch64-sve.md (*vec_extract<mode><Vel>_0): New
30308 pattern.
30309 (*vec_extract<mode><Vel>_v128): Require a nonzero lane number.
30310 Use gen_rtx_REG rather than gen_lowpart.
30311
30312 2018-01-30 Richard Sandiford <richard.sandiford@linaro.org>
30313
30314 * lra-constraints.c (match_reload): Use subreg_lowpart_offset
30315 rather than 0 when creating partial subregs.
30316
30317 2018-01-30 Richard Sandiford <richard.sandiford@linaro.org>
30318
30319 * vec-perm-indices.c (vec_perm_indices::series_p): Give examples
30320 of usage.
30321
30322 2018-01-29 Michael Meissner <meissner@linux.vnet.ibm.com>
30323
30324 PR target/81550
30325 * config/rs6000/rs6000.c (rs6000_setup_reg_addr_masks): If DFmode
30326 and SFmode can go in Altivec registers (-mcpu=power7 for DFmode,
30327 -mcpu=power8 for SFmode) don't set the PRE_INCDEC or PRE_MODIFY
30328 flags. This restores the settings used before the 2017-07-24.
30329 Turning off pre increment/decrement/modify allows IVOPTS to
30330 optimize DF/SF loops where the index is an int.
30331
30332 2018-01-29 Richard Biener <rguenther@suse.de>
30333 Kelvin Nilsen <kelvin@gcc.gnu.org>
30334
30335 PR bootstrap/80867
30336 * tree-vect-stmts.c (vectorizable_call): Don't call
30337 targetm.vectorize_builtin_md_vectorized_function if callee is
30338 NULL.
30339
30340 2018-01-22 Carl Love <cel@us.ibm.com>
30341
30342 * doc/extend.tex: Fix typo in second arg in
30343 __builtin_bcdadd_{lt|eq|gt|ov} and __builtin_bcdsub_{lt|eq|gt|ov}.
30344
30345 2018-01-29 Richard Biener <rguenther@suse.de>
30346
30347 PR tree-optimization/84086
30348 * tree-ssanames.c: Include cfgloop.h and tree-scalar-evolution.h.
30349 (flush_ssaname_freelist): When SSA names were released reset
30350 the SCEV hash table.
30351
30352 2018-01-29 Richard Biener <rguenther@suse.de>
30353
30354 PR tree-optimization/84057
30355 * tree-ssa-loop-ivcanon.c (unloop_loops): Deal with already
30356 removed paths when removing edges.
30357
30358 2018-01-27 H.J. Lu <hongjiu.lu@intel.com>
30359
30360 * doc/invoke.texi: Replace -mfunction-return==@var{choice} with
30361 -mfunction-return=@var{choice}.
30362
30363 2018-01-27 Bernd Edlinger <bernd.edlinger@hotmail.de>
30364
30365 PR diagnostic/84034
30366 * diagnostic-show-locus.c (get_line_width_without_trailing_whitespace):
30367 Handle CR like TAB.
30368 (layout::print_source_line): Likewise.
30369 (test_get_line_width_without_trailing_whitespace): Add test cases.
30370
30371 2018-01-27 Jakub Jelinek <jakub@redhat.com>
30372
30373 PR middle-end/84040
30374 * sched-deps.c (sched_macro_fuse_insns): Return immediately for
30375 debug insns.
30376
30377 2018-01-26 Jim Wilson <jimw@sifive.com>
30378
30379 * config/riscv/riscv.h (MAX_FIXED_MODE_SIZE): New.
30380
30381 * config/riscv/elf.h (LIB_SPEC): Don't include -lgloss when nosys.specs
30382 specified.
30383
30384 2018-01-26 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
30385
30386 * config/aarch64/aarch64.md: Add peepholes for CMP + SUB -> SUBS
30387 and CMP + SUB-immediate -> SUBS.
30388
30389 2018-01-26 Martin Sebor <msebor@redhat.com>
30390
30391 PR tree-optimization/83896
30392 * tree-ssa-strlen.c (get_string_len): Rename...
30393 (get_string_cst_length): ...to this. Return HOST_WIDE_INT.
30394 Avoid assuming length is constant.
30395 (handle_char_store): Use HOST_WIDE_INT for string length.
30396
30397 2018-01-26 Uros Bizjak <ubizjak@gmail.com>
30398
30399 PR target/81763
30400 * config/i386/i386.md (*andndi3_doubleword): Add earlyclobber
30401 to (=&r,r,rm) alternative. Add (=r,0,rm) and (=r,r,0) alternatives.
30402
30403 2018-01-26 Richard Biener <rguenther@suse.de>
30404
30405 PR rtl-optimization/84003
30406 * dse.c (record_store): Only record redundant stores when
30407 the earlier store aliases at least all accesses the later one does.
30408
30409 2018-01-26 Jakub Jelinek <jakub@redhat.com>
30410
30411 PR rtl-optimization/83985
30412 * dce.c (deletable_insn_p): Return false for separate shrink wrapping
30413 REG_CFA_RESTORE insns.
30414 (delete_unmarked_insns): Don't ignore separate shrink wrapping
30415 REG_CFA_RESTORE insns here.
30416
30417 PR c/83989
30418 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): Don't
30419 use SSA_NAME_VAR as base for SSA_NAMEs with non-NULL SSA_NAME_VAR.
30420
30421 2018-01-26 Claudiu Zissulescu <claziss@synopsys.com>
30422
30423 * config/arc/arc-arch.h (arc_tune_attr): Add ARC_TUNE_CORE_3.
30424 * config/arc/arc.c (arc_sched_issue_rate): Use ARC_TUNE_... .
30425 (arc_init): Likewise.
30426 (arc_override_options): Likewise.
30427 (arc_file_start): Choose Tag_ARC_CPU_variation based on arc_tune
30428 value.
30429 (hwloop_fail): Use TARGET_DBNZ when we want to check for dbnz insn
30430 support.
30431 * config/arc/arc.h (TARGET_DBNZ): Define.
30432 * config/arc/arc.md (attr tune): Add core_3, use ARC_TUNE_... to
30433 properly set the tune attribute.
30434 (dbnz): Use TARGET_DBNZ guard.
30435 * config/arc/arc.opt (mtune): Add core3 option.
30436
30437 2018-01-26 Claudiu Zissulescu <claziss@synopsys.com>
30438
30439 * config/arc/arc.c (arc_delegitimize_address_0): Refactored to
30440 recognize new pic like addresses.
30441 (arc_delegitimize_address): Clean up.
30442
30443 2018-01-26 Claudiu Zissulescu <claziss@synopsys.com>
30444
30445 * config/arc/arc-arches.def: Option mrf16 valid for all
30446 architectures.
30447 * config/arc/arc-c.def (__ARC_RF16__): New predefined macro.
30448 * config/arc/arc-cpus.def (em_mini): New cpu with rf16 on.
30449 * config/arc/arc-options.def (FL_RF16): Add mrf16 option.
30450 * config/arc/arc-tables.opt: Regenerate.
30451 * config/arc/arc.c (arc_conditional_register_usage): Handle
30452 reduced register file case.
30453 (arc_file_start): Set must have build attributes.
30454 * config/arc/arc.h (MAX_ARC_PARM_REGS): Conditional define using
30455 mrf16 option value.
30456 * config/arc/arc.opt (mrf16): Add new option.
30457 * config/arc/elf.h (ATTRIBUTE_PCS): Define.
30458 * config/arc/genmultilib.awk: Handle new mrf16 option.
30459 * config/arc/linux.h (ATTRIBUTE_PCS): Define.
30460 * config/arc/t-multilib: Regenerate.
30461 * doc/invoke.texi (ARC Options): Document mrf16 option.
30462
30463 2018-01-26 Claudiu Zissulescu <claziss@synopsys.com>
30464
30465 * config/arc/arc-protos.h: Add arc_is_secure_call_p proto.
30466 * config/arc/arc.c (arc_handle_secure_attribute): New function.
30467 (arc_attribute_table): Add 'secure_call' attribute.
30468 (arc_print_operand): Print secure call operand.
30469 (arc_function_ok_for_sibcall): Don't optimize tail calls when
30470 secure.
30471 (arc_is_secure_call_p): New function. * config/arc/arc.md
30472 (call_i): Add support for sjli instruction.
30473 (call_value_i): Likewise.
30474 * config/arc/constraints.md (Csc): New constraint.
30475
30476 2018-01-26 Claudiu Zissulescu <claziss@synopsys.com>
30477 John Eric Martin <John.Martin@emmicro-us.com>
30478
30479 * config/arc/arc-protos.h: Add arc_is_jli_call_p proto.
30480 * config/arc/arc.c (_arc_jli_section): New struct.
30481 (arc_jli_section): New type.
30482 (rc_jli_sections): New static variable.
30483 (arc_handle_jli_attribute): New function.
30484 (arc_attribute_table): Add jli_always and jli_fixed attribute.
30485 (arc_file_end): New function.
30486 (TARGET_ASM_FILE_END): Define.
30487 (arc_print_operand): Reuse 'S' letter for JLI output instruction.
30488 (arc_add_jli_section): New function.
30489 (jli_call_scan): Likewise.
30490 (arc_reorg): Call jli_call_scan.
30491 (arc_output_addsi): Remove 'S' from printing asm operand.
30492 (arc_is_jli_call_p): New function.
30493 * config/arc/arc.md (movqi_insn): Remove 'S' from printing asm
30494 operand.
30495 (movhi_insn): Likewise.
30496 (movsi_insn): Likewise.
30497 (movsi_set_cc_insn): Likewise.
30498 (loadqi_update): Likewise.
30499 (load_zeroextendqisi_update): Likewise.
30500 (load_signextendqisi_update): Likewise.
30501 (loadhi_update): Likewise.
30502 (load_zeroextendhisi_update): Likewise.
30503 (load_signextendhisi_update): Likewise.
30504 (loadsi_update): Likewise.
30505 (loadsf_update): Likewise.
30506 (movsicc_insn): Likewise.
30507 (bset_insn): Likewise.
30508 (bxor_insn): Likewise.
30509 (bclr_insn): Likewise.
30510 (bmsk_insn): Likewise.
30511 (bicsi3_insn): Likewise.
30512 (cmpsi_cc_c_insn): Likewise.
30513 (movsi_ne): Likewise.
30514 (movsi_cond_exec): Likewise.
30515 (clrsbsi2): Likewise.
30516 (norm_f): Likewise.
30517 (normw): Likewise.
30518 (swap): Likewise.
30519 (divaw): Likewise.
30520 (flag): Likewise.
30521 (sr): Likewise.
30522 (kflag): Likewise.
30523 (ffs): Likewise.
30524 (ffs_f): Likewise.
30525 (fls): Likewise.
30526 (call_i): Remove 'S' asm letter, add jli instruction.
30527 (call_value_i): Likewise.
30528 * config/arc/arc.op (mjli-always): New option.
30529 * config/arc/constraints.md (Cji): New constraint.
30530 * config/arc/fpx.md (addsf3_fpx): Remove 'S' from printing asm
30531 operand.
30532 (subsf3_fpx): Likewise.
30533 (mulsf3_fpx): Likewise.
30534 * config/arc/simdext.md (vendrec_insn): Remove 'S' from printing
30535 asm operand.
30536 * doc/extend.texi (ARC): Document 'jli-always' and 'jli-fixed'
30537 function attrbutes.
30538 * doc/invoke.texi (ARC): Document mjli-always option.
30539
30540 2018-01-26 Sebastian Perta <sebastian.perta@renesas.com>
30541
30542 * config/rl78/rl78.c (rl78_addsi3_internal): If operand 2 is const
30543 avoid addition with 0 and use incw and decw where possible.
30544
30545 2018-01-26 Richard Biener <rguenther@suse.de>
30546
30547 PR tree-optimization/81082
30548 * fold-const.c (fold_plusminus_mult_expr): Do not perform the
30549 association if it requires casting to unsigned.
30550 * match.pd ((A * C) +- (B * C) -> (A+-B)): New patterns derived
30551 from fold_plusminus_mult_expr to catch important cases late when
30552 range info is available.
30553
30554 2018-01-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
30555
30556 * config/i386/sol2.h (USE_HIDDEN_LINKONCE): Remove.
30557 * configure.ac (hidden_linkonce): New test.
30558 * configure: Regenerate.
30559 * config.in: Regenerate.
30560
30561 2018-01-26 Julia Koval <julia.koval@intel.com>
30562
30563 * config/i386/avx512bitalgintrin.h (_mm512_bitshuffle_epi64_mask,
30564 _mm512_mask_bitshuffle_epi64_mask, _mm256_bitshuffle_epi64_mask,
30565 _mm256_mask_bitshuffle_epi64_mask, _mm_bitshuffle_epi64_mask,
30566 _mm_mask_bitshuffle_epi64_mask): Fix type.
30567 * config/i386/i386-builtin-types.def (UHI_FTYPE_V2DI_V2DI_UHI,
30568 USI_FTYPE_V4DI_V4DI_USI): Remove.
30569 * config/i386/i386-builtin.def (__builtin_ia32_vpshufbitqmb512_mask,
30570 __builtin_ia32_vpshufbitqmb256_mask,
30571 __builtin_ia32_vpshufbitqmb128_mask): Fix types.
30572 * config/i386/i386.c (ix86_expand_args_builtin): Remove old types.
30573 * config/i386/sse.md (VI1_AVX512VLBW): Change types.
30574
30575 2018-01-26 Alan Modra <amodra@gmail.com>
30576
30577 PR target/84033
30578 * config/rs6000/rs6000-p8swap.c (rtx_is_swappable_p): Exclude
30579 UNSPEC_VBPERMQ. Sort other unspecs.
30580
30581 2018-01-25 David Edelsohn <dje.gcc@gmail.com>
30582
30583 * doc/invoke.texi (PowerPC Options): Document 'native' cpu type.
30584
30585 2018-01-25 Jan Hubicka <hubicka@ucw.cz>
30586
30587 PR middle-end/83055
30588 * predict.c (drop_profile): Do not push/pop cfun; update also
30589 node->count.
30590 (handle_missing_profiles): Fix logic looking for zero profiles.
30591
30592 2018-01-25 Jakub Jelinek <jakub@redhat.com>
30593
30594 PR middle-end/83977
30595 * ipa-fnsummary.c (compute_fn_summary): Clear can_change_signature
30596 on functions with #pragma omp declare simd or functions with simd
30597 attribute.
30598 * omp-simd-clone.c (expand_simd_clones): Revert 2018-01-24 change.
30599 * config/i386/i386.c (ix86_simd_clone_compute_vecsize_and_simdlen):
30600 Remove trailing \n from warning_at calls.
30601
30602 2018-01-25 Tom de Vries <tom@codesourcery.com>
30603
30604 PR target/84028
30605 * config/nvptx/nvptx.c (nvptx_single): Add exit insn after noreturn call
30606 for neutered workers.
30607
30608 2018-01-24 Joseph Myers <joseph@codesourcery.com>
30609
30610 PR target/68467
30611 * config/m68k/m68k.c (m68k_promote_function_mode): New function.
30612 (TARGET_PROMOTE_FUNCTION_MODE): New macro.
30613
30614 2018-01-24 Jeff Law <law@redhat.com>
30615
30616 PR target/83994
30617 * i386.c (get_probe_interval): Move to earlier point.
30618 (ix86_compute_frame_layout): If -fstack-clash-protection and
30619 the frame is larger than the probe interval, then use pushes
30620 to save registers rather than reg->mem moves.
30621 (ix86_expand_prologue): Remove conditional for int_registers_saved
30622 assertion.
30623
30624 2018-01-24 Vladimir Makarov <vmakarov@redhat.com>
30625
30626 PR target/84014
30627 * ira-build.c (setup_min_max_allocno_live_range_point): Set up
30628 min/max for never referenced object.
30629
30630 2018-01-24 Jakub Jelinek <jakub@redhat.com>
30631
30632 PR middle-end/83977
30633 * tree.c (free_lang_data_in_decl): Don't clear DECL_ABSTRACT_ORIGIN
30634 here.
30635 * omp-low.c (create_omp_child_function): Remove "omp declare simd"
30636 attributes from DECL_ATTRIBUTES (decl) without affecting
30637 DECL_ATTRIBUTES (current_function_decl).
30638 * omp-simd-clone.c (expand_simd_clones): Ignore DECL_ARTIFICIAL
30639 functions with non-NULL DECL_ABSTRACT_ORIGIN.
30640
30641 2018-01-24 Richard Sandiford <richard.sandiford@linaro.org>
30642
30643 PR tree-optimization/83979
30644 * fold-const.c (fold_comparison): Use constant_boolean_node
30645 instead of boolean_{true,false}_node.
30646
30647 2018-01-24 Jan Hubicka <hubicka@ucw.cz>
30648
30649 * ipa-profile.c (ipa_propagate_frequency_1): Fix logic skipping calls
30650 with zero counts.
30651
30652 2018-01-24 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
30653
30654 * config/rs6000/rs6000.md (*call_indirect_nonlocal_sysv<mode>):
30655 Simplify the clause that sets the length attribute.
30656 (*call_value_indirect_nonlocal_sysv<mode>): Likewise.
30657 (*sibcall_nonlocal_sysv<mode>): Clean up code block; simplify the
30658 clause that sets the length attribute.
30659 (*sibcall_value_nonlocal_sysv<mode>): Likewise.
30660
30661 2018-01-24 Tom de Vries <tom@codesourcery.com>
30662
30663 PR target/83589
30664 * config/nvptx/nvptx.c (WORKAROUND_PTXJIT_BUG_2): Define to 1.
30665 (nvptx_pc_set, nvptx_condjump_label): New function. Copy from jump.c.
30666 Add strict parameter.
30667 (prevent_branch_around_nothing): Insert dummy insn between branch to
30668 label and label with no ptx insn inbetween.
30669 * config/nvptx/nvptx.md (define_insn "fake_nop"): New insn.
30670
30671 2018-01-24 Tom de Vries <tom@codesourcery.com>
30672
30673 PR target/81352
30674 * config/nvptx/nvptx.c (nvptx_single): Add exit insn after noreturn call
30675 for neutered threads in warp.
30676 * config/nvptx/nvptx.md (define_insn "exit"): New insn.
30677
30678 2018-01-24 Richard Biener <rguenther@suse.de>
30679
30680 PR tree-optimization/83176
30681 * tree-chrec.c (chrec_fold_plus_1): Handle (signed T){(T) .. }
30682 operands.
30683
30684 2018-01-24 Richard Biener <rguenther@suse.de>
30685
30686 PR tree-optimization/82819
30687 * graphite-isl-ast-to-gimple.c (binary_op_to_tree): Avoid
30688 code generating pluses that are no-ops in the target precision.
30689
30690 2018-01-24 Richard Biener <rguenther@suse.de>
30691
30692 PR middle-end/84000
30693 * tree-cfg.c (replace_loop_annotate): Handle annot_expr_parallel_kind.
30694
30695 2018-01-23 Jan Hubicka <hubicka@ucw.cz>
30696
30697 * cfgcleanup.c (try_crossjump_to_edge): Use combine_with_count
30698 to merge probabilities.
30699 * predict.c (probably_never_executed): Also mark as cold functions
30700 with global 0 profile and guessed local profile.
30701 * profile-count.c (profile_probability::combine_with_count): New
30702 member function.
30703 * profile-count.h (profile_probability::operator*,
30704 profile_probability::operator*=, profile_probability::operator/,
30705 profile_probability::operator/=): Reduce precision to adjusted
30706 and set value to guessed on contradictory divisions.
30707 (profile_probability::combine_with_freq): Remove.
30708 (profile_probability::combine_wiht_count): Declare.
30709 (profile_count::force_nonzero):: Set to adjusted.
30710 (profile_count::probability_in):: Set quality to adjusted.
30711 * tree-ssa-tail-merge.c (replace_block_by): Use
30712 combine_with_count.
30713
30714 2018-01-23 Andrew Waterman <andrew@sifive.com>
30715 Jim Wilson <jimw@sifive.com>
30716
30717 * config/riscv/riscv.c (riscv_stack_boundary): New.
30718 (riscv_option_override): Set riscv_stack_boundary. Handle
30719 riscv_preferred_stack_boundary_arg.
30720 * config/riscv/riscv.h (MIN_STACK_BOUNDARY, ABI_STACK_BOUNDARY): New.
30721 (BIGGEST_ALIGNMENT): Set to STACK_BOUNDARY.
30722 (STACK_BOUNDARY): Set to riscv_stack_boundary.
30723 (RISCV_STACK_ALIGN): Use STACK_BOUNDARY.
30724 * config/riscv/riscv.opt (mpreferred-stack-boundary): New.
30725 * doc/invoke.tex (RISC-V Options): Add -mpreferred-stack-boundary.
30726
30727 2018-01-23 H.J. Lu <hongjiu.lu@intel.com>
30728
30729 PR target/83905
30730 * config/i386/i386.c (ix86_expand_prologue): Use cost reference
30731 of struct ix86_frame.
30732 (ix86_expand_epilogue): Likewise. Add a local variable for
30733 the reg_save_offset field in struct ix86_frame.
30734
30735 2018-01-23 Bin Cheng <bin.cheng@arm.com>
30736
30737 PR tree-optimization/82604
30738 * tree-loop-distribution.c (enum partition_kind): New enum item
30739 PKIND_PARTIAL_MEMSET.
30740 (partition_builtin_p): Support above new enum item.
30741 (generate_code_for_partition): Ditto.
30742 (compute_access_range): Differentiate cases that equality can be
30743 proven at all loops, the innermost loops or no loops.
30744 (classify_builtin_st, classify_builtin_ldst): Adjust call to above
30745 function. Set PKIND_PARTIAL_MEMSET for partition appropriately.
30746 (finalize_partitions, distribute_loop): Don't fuse partition of
30747 PKIND_PARTIAL_MEMSET kind when distributing 3-level loop nest.
30748 (prepare_perfect_loop_nest): Distribute 3-level loop nest only if
30749 parloop is enabled.
30750
30751 2018-01-23 Martin Liska <mliska@suse.cz>
30752
30753 * predict.def (PRED_INDIR_CALL): Set probability to PROB_EVEN in
30754 order to ignore the predictor.
30755 (PRED_POLYMORPHIC_CALL): Likewise.
30756 (PRED_RECURSIVE_CALL): Likewise.
30757
30758 2018-01-23 Martin Liska <mliska@suse.cz>
30759
30760 * tree-profile.c (tree_profiling): Print function header to
30761 aware reader which function we are working on.
30762 * value-prof.c (gimple_find_values_to_profile): Do not print
30763 not interesting value histograms.
30764
30765 2018-01-23 Martin Liska <mliska@suse.cz>
30766
30767 * profile-count.h (enum profile_quality): Add
30768 profile_uninitialized as the first value. Do not number values
30769 as they are zero based.
30770 (profile_count::verify): Update sanity check.
30771 (profile_probability::verify): Likewise.
30772
30773 2018-01-23 Nathan Sidwell <nathan@acm.org>
30774
30775 * doc/invoke.texi (ffor-scope): Deprecate.
30776
30777 2018-01-23 David Malcolm <dmalcolm@redhat.com>
30778
30779 PR tree-optimization/83510
30780 * domwalk.c (set_all_edges_as_executable): New function.
30781 (dom_walker::dom_walker): Convert bool param
30782 "skip_unreachable_blocks" to enum reachability. Move setup of
30783 edge flags to set_all_edges_as_executable and only do it when
30784 reachability is REACHABLE_BLOCKS.
30785 * domwalk.h (enum dom_walker::reachability): New enum.
30786 (dom_walker::dom_walker): Convert bool param
30787 "skip_unreachable_blocks" to enum reachability.
30788 (set_all_edges_as_executable): New decl.
30789 * graphite-scop-detection.c (gather_bbs::gather_bbs): Convert
30790 from false for "skip_unreachable_blocks" to ALL_BLOCKS for
30791 "reachability".
30792 * tree-ssa-dom.c (dom_opt_dom_walker::dom_opt_dom_walker): Likewise,
30793 but converting true to REACHABLE_BLOCKS.
30794 * tree-ssa-sccvn.c (sccvn_dom_walker::sccvn_dom_walker): Likewise.
30795 * tree-vrp.c
30796 (check_array_bounds_dom_walker::check_array_bounds_dom_walker):
30797 Likewise, but converting it to REACHABLE_BLOCKS_PRESERVING_FLAGS.
30798 (vrp_dom_walker::vrp_dom_walker): Likewise, but converting it to
30799 REACHABLE_BLOCKS.
30800 (vrp_prop::vrp_finalize): Call set_all_edges_as_executable
30801 if check_all_array_refs will be called.
30802
30803 2018-01-23 David Malcolm <dmalcolm@redhat.com>
30804
30805 * tree.c (selftest::test_location_wrappers): Add more test
30806 coverage.
30807
30808 2018-01-23 David Malcolm <dmalcolm@redhat.com>
30809
30810 * sbitmap.c (selftest::test_set_range): Fix memory leaks.
30811 (selftest::test_bit_in_range): Likewise.
30812
30813 2018-01-23 Richard Sandiford <richard.sandiford@linaro.org>
30814
30815 PR testsuite/83888
30816 * doc/sourcebuild.texi (vect_float): Say that the selector
30817 only describes the situation when -funsafe-math-optimizations is on.
30818 (vect_float_strict): Document.
30819
30820 2018-01-23 Richard Sandiford <richard.sandiford@linaro.org>
30821
30822 PR tree-optimization/83965
30823 * tree-vect-patterns.c (vect_reassociating_reduction_p): New function.
30824 (vect_recog_dot_prod_pattern, vect_recog_sad_pattern): Use it
30825 instead of checking only for a reduction.
30826 (vect_recog_widen_sum_pattern): Likewise.
30827
30828 2018-01-23 Jan Hubicka <hubicka@ucw.cz>
30829
30830 * predict.c (probably_never_executed): Only use precise profile info.
30831 (compute_function_frequency): Skip after inlining hack since we now
30832 have quality checking.
30833
30834 2018-01-23 Jan Hubicka <hubicka@ucw.cz>
30835
30836 * profile-count.h (profile_probability::very_unlikely,
30837 profile_probability::unlikely, profile_probability::even): Set
30838 precision to guessed.
30839
30840 2018-01-23 Richard Biener <rguenther@suse.de>
30841
30842 PR tree-optimization/83963
30843 * graphite-scop-detection.c (scop_detection::harmful_loop_in_region):
30844 Properly terminate dominator walk when crossing the exit edge not
30845 when visiting its source block.
30846
30847 2018-01-23 Jakub Jelinek <jakub@redhat.com>
30848
30849 PR c++/83918
30850 * tree.c (maybe_wrap_with_location): Use NON_LVALUE_EXPR rather than
30851 VIEW_CONVERT_EXPR to wrap CONST_DECLs.
30852
30853 2018-01-22 Jakub Jelinek <jakub@redhat.com>
30854
30855 PR tree-optimization/83957
30856 * omp-expand.c (expand_omp_for_generic): Ignore virtual PHIs. Remove
30857 semicolon after for body surrounded by braces.
30858
30859 PR tree-optimization/83081
30860 * profile-count.h (profile_probability::split): New method.
30861 * dojump.c (do_jump_1) <case TRUTH_ANDIF_EXPR, case TRUTH_ORIF_EXPR>:
30862 Use profile_probability::split.
30863 (do_compare_rtx_and_jump): Fix adjustment of probabilities
30864 when splitting a single conditional jump into 2.
30865
30866 2018-01-22 David Malcolm <dmalcolm@redhat.com>
30867
30868 PR tree-optimization/69452
30869 * tree-ssa-loop-im.c (class move_computations_dom_walker): Remove
30870 decl.
30871
30872 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
30873
30874 * config/rl78/rl78-expand.md (bswaphi2): New define_expand.
30875 * config/rl78/rl78-virt.md (*bswaphi2_virt): New define_insn.
30876 * config/rl78/rl78-real.md (*bswaphi2_real): New define_insn.
30877
30878 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
30879
30880 * config/rl78/rl78-protos.h (rl78_split_movdi): New function
30881 declaration.
30882 * config/rl78/rl78.md (movdi): New define_expand.
30883 * config/rl78/rl78.c (rl78_split_movdi): New function.
30884
30885 2018-01-22 Michael Meissner <meissner@linux.vnet.ibm.com>
30886
30887 PR target/83862
30888 * config/rs6000/rs6000-protos.h (rs6000_split_signbit): Delete,
30889 no longer used.
30890 * config/rs6000/rs6000.c (rs6000_split_signbit): Likewise.
30891 * config/rs6000/rs6000.md (signbit<mode>2): Change code for IEEE
30892 128-bit to produce an UNSPEC move to get the double word with the
30893 signbit and then a shift directly to do signbit.
30894 (signbit<mode>2_dm): Replace old IEEE 128-bit signbit
30895 implementation with a new version that just does either a direct
30896 move or a regular move. Move memory interface to separate insns.
30897 Move insns so they are next to the expander.
30898 (signbit<mode>2_dm_mem_be): New combiner insns to combine load
30899 with signbit move. Split big and little endian case.
30900 (signbit<mode>2_dm_mem_le): Likewise.
30901 (signbit<mode>2_dm_<su>ext): Delete, no longer used.
30902 (signbit<mode>2_dm2): Likewise.
30903
30904 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
30905
30906 * config/rl78/rl78.md (anddi3): New define_expand.
30907
30908 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
30909
30910 * config/rl78/rl78.md (umindi3): New define_expand.
30911
30912 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
30913
30914 * config/rl78/rl78.md (smindi3): New define_expand.
30915
30916 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
30917
30918 * config/rl78/rl78.md (smaxdi3): New define_expand.
30919
30920 2018-01-22 Carl Love <cel@us.ibm.com>
30921
30922 * config/rs6000/rs6000-builtin.def (ST_ELEMREV_V1TI, LD_ELEMREV_V1TI,
30923 LVX_V1TI): Add macro expansion.
30924 * config/rs6000/rs6000-c.c (altivec_builtin_types): Add argument
30925 definitions for VSX_BUILTIN_VEC_XST_BE, VSX_BUILTIN_VEC_ST,
30926 VSX_BUILTIN_VEC_XL, LD_ELEMREV_V1TI builtins.
30927 * config/rs6000/rs6000-p8swap.c (insn_is_swappable_p);
30928 Change check to determine if the instruction is a byte reversing
30929 entry. Fix typo in comment.
30930 * config/rs6000/rs6000.c (altivec_expand_builtin): Add case entry
30931 for VSX_BUILTIN_ST_ELEMREV_V1TI and VSX_BUILTIN_LD_ELEMREV_V1TI.
30932 Add def_builtin calls for new builtins.
30933 * config/rs6000/vsx.md (vsx_st_elemrev_v1ti, vsx_ld_elemrev_v1ti):
30934 Add define_insn expansion.
30935
30936 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
30937
30938 * config/rl78/rl78.md (umaxdi3): New define_expand.
30939
30940 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
30941
30942 * config/rl78/rl78.c (rl78_note_reg_set): Fixed dead reg check
30943 for non-QImode registers.
30944
30945 2018-01-22 Richard Biener <rguenther@suse.de>
30946
30947 PR tree-optimization/83963
30948 * graphite-scop-detection.c (scop_detection::get_sese): Delay
30949 including the loop exit block.
30950 (scop_detection::merge_sese): Likewise.
30951 (scop_detection::add_scop): Do it here instead.
30952
30953 2018-01-22 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
30954
30955 * doc/sourcebuild.texi (arm_softfloat): Document.
30956
30957 2018-01-21 John David Anglin <danglin@gcc.gnu.org>
30958
30959 PR gcc/77734
30960 * config/pa/pa.c (pa_function_ok_for_sibcall): Use
30961 targetm.binds_local_p instead of TREE_PUBLIC to check local binding.
30962 Move TARGET_PORTABLE_RUNTIME check after TARGET_64BIT check.
30963
30964 2018-01-21 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
30965 David Edelsohn <dje.gcc@gmail.com>
30966
30967 PR target/83946
30968 * config/rs6000/rs6000.md (*call_indirect_nonlocal_sysv<mode>):
30969 Change "crset eq" to "crset 2".
30970 (*call_value_indirect_nonlocal_sysv<mode>): Likewise.
30971 (*call_indirect_aix<mode>_nospec): Likewise.
30972 (*call_value_indirect_aix<mode>_nospec): Likewise.
30973 (*call_indirect_elfv2<mode>_nospec): Likewise.
30974 (*call_value_indirect_elfv2<mode>_nospec): Likewise.
30975 (*sibcall_nonlocal_sysv<mode>): Change "crset eq" to "crset 2";
30976 change assembly output from . to $.
30977 (*sibcall_value_nonlocal_sysv<mode>): Likewise.
30978 (indirect_jump<mode>_nospec): Change assembly output from . to $.
30979 (*tablejump<mode>_internal1_nospec): Likewise.
30980
30981 2018-01-21 Oleg Endo <olegendo@gcc.gnu.org>
30982
30983 PR target/80870
30984 * config/sh/sh_optimize_sett_clrt.cc:
30985 Use INCLUDE_ALGORITHM and INCLUDE_VECTOR instead of direct includes.
30986
30987 2018-01-20 Richard Sandiford <richard.sandiford@linaro.org>
30988
30989 PR tree-optimization/83940
30990 * tree-vect-stmts.c (vect_truncate_gather_scatter_offset): Set
30991 offset_dt to vect_constant_def rather than vect_unknown_def_type.
30992 (vect_check_load_store_mask): Add a mask_dt_out parameter and
30993 use it to pass back the definition type.
30994 (vect_check_store_rhs): Likewise rhs_dt_out.
30995 (vect_build_gather_load_calls): Add a mask_dt argument and use
30996 it instead of a call to vect_is_simple_use.
30997 (vectorizable_store): Update calls to vect_check_load_store_mask
30998 and vect_check_store_rhs. Use the dt returned by the latter instead
30999 of scatter_src_dt. Use the cached mask_dt and gs_info.offset_dt
31000 instead of calls to vect_is_simple_use. Pass the scalar rather
31001 than the vector operand to vect_is_simple_use when handling
31002 second and subsequent copies of an rhs value.
31003 (vectorizable_load): Update calls to vect_check_load_store_mask
31004 and vect_build_gather_load_calls. Use the cached mask_dt and
31005 gs_info.offset_dt instead of calls to vect_is_simple_use.
31006
31007 2018-01-20 Jakub Jelinek <jakub@redhat.com>
31008
31009 PR middle-end/83945
31010 * tree-emutls.c: Include gimplify.h.
31011 (lower_emutls_2): New function.
31012 (lower_emutls_1): If ADDR_EXPR is a gimple invariant and walk_tree
31013 with lower_emutls_2 callback finds some TLS decl in it, unshare_expr
31014 it before further processing.
31015
31016 PR target/83930
31017 * simplify-rtx.c (simplify_binary_operation_1) <case UMOD>: Use
31018 UINTVAL (trueop1) instead of INTVAL (op1).
31019
31020 2018-01-19 Jakub Jelinek <jakub@redhat.com>
31021
31022 PR debug/81570
31023 PR debug/83728
31024 * dwarf2cfi.c (DEFAULT_INCOMING_FRAME_SP_OFFSET): Define to
31025 INCOMING_FRAME_SP_OFFSET if not defined.
31026 (scan_trace): Add ENTRY argument. If true and
31027 DEFAULT_INCOMING_FRAME_SP_OFFSET != INCOMING_FRAME_SP_OFFSET,
31028 emit a note to adjust the CFA offset.
31029 (create_cfi_notes): Adjust scan_trace callers.
31030 (create_cie_data): Use DEFAULT_INCOMING_FRAME_SP_OFFSET rather than
31031 INCOMING_FRAME_SP_OFFSET in the CIE.
31032 * config/i386/i386.h (DEFAULT_INCOMING_FRAME_SP_OFFSET): Define.
31033 * config/stormy16/stormy16.h (DEFAULT_INCOMING_FRAME_SP_OFFSET):
31034 Likewise.
31035 * doc/tm.texi.in (DEFAULT_INCOMING_FRAME_SP_OFFSET): Document.
31036 * doc/tm.texi: Regenerated.
31037
31038 2018-01-19 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
31039
31040 PR rtl-optimization/83147
31041 * lra-constraints.c (remove_inheritance_pseudos): Use
31042 lra_substitute_pseudo_within_insn.
31043
31044 2018-01-19 Tom de Vries <tom@codesourcery.com>
31045 Cesar Philippidis <cesar@codesourcery.com>
31046
31047 PR target/83920
31048 * config/nvptx/nvptx.c (nvptx_single): Fix jit workaround.
31049
31050 2018-01-19 Cesar Philippidis <cesar@codesourcery.com>
31051
31052 PR target/83790
31053 * config/nvptx/nvptx.c (output_init_frag): Don't use generic address
31054 spaces for function labels.
31055
31056 2018-01-19 Martin Liska <mliska@suse.cz>
31057
31058 * predict.def (PRED_LOOP_EXIT): Change from 85 to 89.
31059 (PRED_LOOP_EXIT_WITH_RECURSION): Change from 72 to 78.
31060 (PRED_LOOP_EXTRA_EXIT): Change from 83 to 67.
31061 (PRED_OPCODE_POSITIVE): Change from 64 to 59.
31062 (PRED_TREE_OPCODE_POSITIVE): Change from 64 to 59.
31063 (PRED_CONST_RETURN): Change from 69 to 65.
31064 (PRED_NULL_RETURN): Change from 91 to 71.
31065 (PRED_LOOP_IV_COMPARE_GUESS): Change from 98 to 64.
31066 (PRED_LOOP_GUARD): Change from 66 to 73.
31067
31068 2018-01-19 Martin Liska <mliska@suse.cz>
31069
31070 * predict.c (predict_insn_def): Add new assert.
31071 (struct branch_predictor): Change type to signed integer.
31072 (test_prediction_value_range): Amend test to cover
31073 PROB_UNINITIALIZED.
31074 * predict.def (PRED_LOOP_ITERATIONS): Use the new constant.
31075 (PRED_LOOP_ITERATIONS_GUESSED): Likewise.
31076 (PRED_LOOP_ITERATIONS_MAX): Likewise.
31077 (PRED_LOOP_IV_COMPARE): Likewise.
31078 * predict.h (PROB_UNINITIALIZED): Define new constant.
31079
31080 2018-01-19 Martin Liska <mliska@suse.cz>
31081
31082 * predict.c (dump_prediction): Add new format for
31083 analyze_brprob.py script which is enabled with -details
31084 suboption.
31085 * profile-count.h (precise_p): New function.
31086
31087 2018-01-19 Richard Sandiford <richard.sandiford@linaro.org>
31088
31089 PR tree-optimization/83922
31090 * tree-vect-loop.c (vect_verify_full_masking): Return false if
31091 there are no statements that need masking.
31092 (vect_active_double_reduction_p): New function.
31093 (vect_analyze_loop_operations): Use it when handling phis that
31094 are not in the loop header.
31095
31096 2018-01-19 Richard Sandiford <richard.sandiford@linaro.org>
31097
31098 PR tree-optimization/83914
31099 * tree-vect-loop.c (vectorizable_induction): Don't convert
31100 init_expr or apply the peeling adjustment for inductions
31101 that are nested within the vectorized loop.
31102
31103 2018-01-19 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
31104
31105 * config/arm/thumb2.md (*thumb2_negsi2_short): Use RSB mnemonic
31106 instead of NEG.
31107
31108 2018-01-18 Jakub Jelinek <jakub@redhat.com>
31109
31110 PR sanitizer/81715
31111 PR testsuite/83882
31112 * function.h (gimplify_parameters): Add gimple_seq * argument.
31113 * function.c: Include gimple.h and options.h.
31114 (gimplify_parameters): Add cleanup argument, add CLOBBER stmts
31115 for the added local temporaries if needed.
31116 * gimplify.c (gimplify_body): Adjust gimplify_parameters caller,
31117 if there are any parameter cleanups, wrap whole body into a
31118 try/finally with the cleanups.
31119
31120 2018-01-18 Wilco Dijkstra <wdijkstr@arm.com>
31121
31122 PR target/82964
31123 * config/aarch64/aarch64.c (aarch64_legitimate_constant_p):
31124 Use GET_MODE_CLASS for scalar floating point.
31125
31126 2018-01-18 Jan Hubicka <hubicka@ucw.cz>
31127
31128 PR ipa/82256
31129 patch by PaX Team
31130 * cgraphclones.c (cgraph_node::create_version_clone_with_body):
31131 Fix call of call_cgraph_insertion_hooks.
31132
31133 2018-01-18 Martin Sebor <msebor@redhat.com>
31134
31135 * doc/invoke.texi (-Wclass-memaccess): Tweak text.
31136
31137 2018-01-18 Jan Hubicka <hubicka@ucw.cz>
31138
31139 PR ipa/83619
31140 * cgraph.c (cgraph_edge::redirect_call_stmt_to_callee): Update edge
31141 frequencies.
31142
31143 2018-01-18 Boris Kolpackov <boris@codesynthesis.com>
31144
31145 PR other/70268
31146 * common.opt: (-ffile-prefix-map): New option.
31147 * opts.c (common_handle_option): Defer it.
31148 * opts-global.c (handle_common_deferred_options): Handle it.
31149 * debug.h (remap_debug_filename, add_debug_prefix_map): Move to...
31150 * file-prefix-map.h: New file.
31151 (remap_debug_filename, add_debug_prefix_map): ...here.
31152 (add_macro_prefix_map, add_file_prefix_map, remap_macro_filename): New.
31153 * final.c (debug_prefix_map, add_debug_prefix_map
31154 remap_debug_filename): Move to...
31155 * file-prefix-map.c: New file.
31156 (file_prefix_map, add_prefix_map, remap_filename) ...here and rename,
31157 generalize, get rid of alloca(), use strrchr() instead of strchr().
31158 (add_macro_prefix_map, add_debug_prefix_map, add_file_prefix_map):
31159 Implement in terms of add_prefix_map().
31160 (remap_macro_filename, remap_debug_filename): Implement in term of
31161 remap_filename().
31162 * Makefile.in (OBJS, PLUGIN_HEADERS): Add new files.
31163 * builtins.c (fold_builtin_FILE): Call remap_macro_filename().
31164 * dbxout.c: Include file-prefix-map.h.
31165 * varasm.c: Likewise.
31166 * vmsdbgout.c: Likewise.
31167 * xcoffout.c: Likewise.
31168 * dwarf2out.c: Likewise plus omit new options from DW_AT_producer.
31169 * doc/cppopts.texi (-fmacro-prefix-map): Document.
31170 * doc/invoke.texi (-ffile-prefix-map): Document.
31171 (-fdebug-prefix-map): Update description.
31172
31173 2018-01-18 Martin Liska <mliska@suse.cz>
31174
31175 * config/i386/i386.c (indirect_thunk_name): Document that also
31176 lfence is emitted.
31177 (output_indirect_thunk): Document why both instructions
31178 (pause and lfence) are generated.
31179
31180 2018-01-18 Richard Biener <rguenther@suse.de>
31181
31182 PR tree-optimization/83887
31183 * graphite-scop-detection.c
31184 (scop_detection::get_nearest_dom_with_single_entry): Remove.
31185 (scop_detection::get_nearest_pdom_with_single_exit): Likewise.
31186 (scop_detection::merge_sese): Re-implement with a flood-fill
31187 algorithm that properly finds a SESE region if it exists.
31188
31189 2018-01-18 Jakub Jelinek <jakub@redhat.com>
31190
31191 PR c/61240
31192 * match.pd ((P + A) - P, P - (P + A), (P + A) - (P + B)): For
31193 pointer_diff optimizations use view_convert instead of convert.
31194
31195 2018-01-17 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
31196
31197 * config/rs6000/rs6000.md (*call_indirect_nonlocal_sysv<mode>):
31198 Generate different code for -mno-speculate-indirect-jumps.
31199 (*call_value_indirect_nonlocal_sysv<mode>): Likewise.
31200 (*call_indirect_aix<mode>): Disable for
31201 -mno-speculate-indirect-jumps.
31202 (*call_indirect_aix<mode>_nospec): New define_insn.
31203 (*call_value_indirect_aix<mode>): Disable for
31204 -mno-speculate-indirect-jumps.
31205 (*call_value_indirect_aix<mode>_nospec): New define_insn.
31206 (*sibcall_nonlocal_sysv<mode>): Generate different code for
31207 -mno-speculate-indirect-jumps.
31208 (*sibcall_value_nonlocal_sysv<mode>): Likewise.
31209
31210 2018-01-17 Michael Meissner <meissner@linux.vnet.ibm.com>
31211
31212 * config/rs6000/rs6000.c (rs6000_emit_move): If we load or store a
31213 long double type, set the flags for noting the default long double
31214 type, even if we don't pass or return a long double type.
31215
31216 2018-01-17 Jan Hubicka <hubicka@ucw.cz>
31217
31218 PR ipa/83051
31219 * ipa-inline.c (flatten_function): Do not overwrite final inlining
31220 failure.
31221
31222 2018-01-17 Will Schmidt <will_schmidt@vnet.ibm.com>
31223
31224 * config/rs6000/rs6000.c (rs6000_gimple_builtin): Add gimple folding
31225 support for merge[hl].
31226 (fold_mergehl_helper): New helper function.
31227 (tree-vector-builder.h): New #include for tree_vector_builder usage.
31228 * config/rs6000/altivec.md (altivec_vmrghw_direct): Add xxmrghw insn.
31229 (altivec_vmrglw_direct): Add xxmrglw insn.
31230
31231 2018-01-17 Andrew Waterman <andrew@sifive.com>
31232
31233 * config/riscv/riscv.c (riscv_conditional_register_usage): If
31234 UNITS_PER_FP_ARG is 0, set call_used_regs to 1 for all FP regs.
31235
31236 2018-01-17 David Malcolm <dmalcolm@redhat.com>
31237
31238 PR lto/83121
31239 * ipa-devirt.c (add_type_duplicate): When comparing memory layout,
31240 call the lto_location_cache before reading the
31241 DECL_SOURCE_LOCATION of the types.
31242
31243 2018-01-17 Wilco Dijkstra <wdijkstr@arm.com>
31244 Richard Sandiford <richard.sandiford@linaro.org>
31245
31246 * config/aarch64/aarch64.md (movti_aarch64): Use Uti constraint.
31247 * config/aarch64/aarch64.c (aarch64_mov128_immediate): New function.
31248 (aarch64_legitimate_constant_p): Just support CONST_DOUBLE
31249 SF/DF/TF mode to avoid creating illegal CONST_WIDE_INT immediates.
31250 * config/aarch64/aarch64-protos.h (aarch64_mov128_immediate):
31251 Add declaration.
31252 * config/aarch64/constraints.md (aarch64_movti_operand):
31253 Limit immediates.
31254 * config/aarch64/predicates.md (Uti): Add new constraint.
31255
31256 2018-01-17 Carl Love <cel@us.ibm.com>
31257
31258 * config/rs6000/vsx.md (define_expand xl_len_r,
31259 define_expand stxvl, define_expand *stxvl): Add match_dup argument.
31260 (define_insn): Add, match_dup 1 argument to define_insn stxvll and
31261 lxvll.
31262 (define_expand, define_insn): Move the shift left from the
31263 define_insn to the define_expand for lxvl and stxvl instructions.
31264 * config/rs6000/rs6000-builtin.def (BU_P9V_64BIT_VSX_2): Change LXVL
31265 and XL_LEN_R definitions to PURE.
31266
31267 2018-01-17 Uros Bizjak <ubizjak@gmail.com>
31268
31269 * config/i386/i386.c (indirect_thunk_name): Declare regno
31270 as unsigned int. Compare regno with INVALID_REGNUM.
31271 (output_indirect_thunk): Ditto.
31272 (output_indirect_thunk_function): Ditto.
31273 (ix86_code_end): Declare regno as unsigned int. Use INVALID_REGNUM
31274 in the call to output_indirect_thunk_function.
31275
31276 2018-01-17 Richard Sandiford <richard.sandiford@linaro.org>
31277
31278 PR middle-end/83884
31279 * expr.c (expand_expr_real_1): Use the size of GET_MODE (op0)
31280 rather than the size of inner_type to determine the stack slot size
31281 when handling VIEW_CONVERT_EXPRs on strict-alignment targets.
31282
31283 2018-01-16 Sebastian Peryt <sebastian.peryt@intel.com>
31284
31285 PR target/83546
31286 * config/i386/i386.c (ix86_option_override_internal): Add PTA_RDRND
31287 to PTA_SILVERMONT.
31288
31289 2018-01-16 Michael Meissner <meissner@linux.vnet.ibm.com>
31290
31291 * config.gcc (powerpc*-linux*-*): Add support for 64-bit little
31292 endian Linux systems to optionally enable multilibs for selecting
31293 the long double type if the user configured an explicit type.
31294 * config/rs6000/rs6000.h (TARGET_IEEEQUAD_MULTILIB): Indicate we
31295 have no long double multilibs if not defined.
31296 * config/rs6000/rs6000.c (rs6000_option_override_internal): Do not
31297 warn if the user used -mabi={ieee,ibm}longdouble and we built
31298 multilibs for long double.
31299 * config/rs6000/linux64.h (MULTILIB_DEFAULTS_IEEE): Define as the
31300 appropriate multilib option.
31301 (MULTILIB_DEFAULTS): Add MULTILIB_DEFAULTS_IEEE to the default
31302 multilib options.
31303 * config/rs6000/t-ldouble-linux64le-ibm: New configuration files
31304 for building long double multilibs.
31305 * config/rs6000/t-ldouble-linux64le-ieee: Likewise.
31306
31307 2018-01-16 John David Anglin <danglin@gcc.gnu.org>
31308
31309 * config.gcc (hppa*-*-linux*): Change callee copies ABI to caller
31310 copies.
31311
31312 * config/pa.h (MALLOC_ABI_ALIGNMENT): Set 32-bit alignment default to
31313 64 bits.
31314 * config/pa/pa32-linux.h (MALLOC_ABI_ALIGNMENT): Set alignment to
31315 128 bits.
31316
31317 * config/pa/som.h (ASM_DECLARE_FUNCTION_NAME): Cleanup type and mode
31318 variables.
31319
31320 * config/pa/pa.c (pa_function_arg_size): Apply CEIL to GET_MODE_SIZE
31321 return value.
31322
31323 2018-01-16 Eric Botcazou <ebotcazou@adacore.com>
31324
31325 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): For an
31326 ADDR_EXPR, do not count the offset of a COMPONENT_REF twice.
31327
31328 2018-01-16 Kelvin Nilsen <kelvin@gcc.gnu.org>
31329
31330 * config/rs6000/rs6000-p8swap.c (rs6000_gen_stvx): Generate
31331 different rtl trees depending on TARGET_64BIT.
31332 (rs6000_gen_lvx): Likewise.
31333
31334 2018-01-16 Eric Botcazou <ebotcazou@adacore.com>
31335
31336 * config/visium/visium.md (nop): Tweak comment.
31337 (hazard_nop): Likewise.
31338
31339 2018-01-16 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
31340
31341 * config/rs6000/rs6000.c (rs6000_opt_vars): Add entry for
31342 -mspeculate-indirect-jumps.
31343 * config/rs6000/rs6000.md (*call_indirect_elfv2<mode>): Disable
31344 for -mno-speculate-indirect-jumps.
31345 (*call_indirect_elfv2<mode>_nospec): New define_insn.
31346 (*call_value_indirect_elfv2<mode>): Disable for
31347 -mno-speculate-indirect-jumps.
31348 (*call_value_indirect_elfv2<mode>_nospec): New define_insn.
31349 (indirect_jump): Emit different RTL for
31350 -mno-speculate-indirect-jumps.
31351 (*indirect_jump<mode>): Disable for
31352 -mno-speculate-indirect-jumps.
31353 (*indirect_jump<mode>_nospec): New define_insn.
31354 (tablejump): Emit different RTL for
31355 -mno-speculate-indirect-jumps.
31356 (tablejumpsi): Disable for -mno-speculate-indirect-jumps.
31357 (tablejumpsi_nospec): New define_expand.
31358 (tablejumpdi): Disable for -mno-speculate-indirect-jumps.
31359 (tablejumpdi_nospec): New define_expand.
31360 (*tablejump<mode>_internal1): Disable for
31361 -mno-speculate-indirect-jumps.
31362 (*tablejump<mode>_internal1_nospec): New define_insn.
31363 * config/rs6000/rs6000.opt (mspeculate-indirect-jumps): New
31364 option.
31365
31366 2018-01-16 Artyom Skrobov tyomitch@gmail.com
31367
31368 * caller-save.c (insert_save): Drop unnecessary parameter. All
31369 callers updated.
31370
31371 2018-01-16 Jakub Jelinek <jakub@redhat.com>
31372 Richard Biener <rguenth@suse.de>
31373
31374 PR libgomp/83590
31375 * gimplify.c (gimplify_one_sizepos): For is_gimple_constant (expr)
31376 return early, inline manually is_gimple_sizepos. Make sure if we
31377 call gimplify_expr we don't end up with a gimple constant.
31378 * tree.c (variably_modified_type_p): Don't return true for
31379 is_gimple_constant (_t). Inline manually is_gimple_sizepos.
31380 * gimplify.h (is_gimple_sizepos): Remove.
31381
31382 2018-01-16 Richard Sandiford <richard.sandiford@linaro.org>
31383
31384 PR tree-optimization/83857
31385 * tree-vect-loop.c (vect_analyze_loop_operations): Don't call
31386 vectorizable_live_operation for pure SLP statements.
31387 (vectorizable_live_operation): Handle PHIs.
31388
31389 2018-01-16 Richard Biener <rguenther@suse.de>
31390
31391 PR tree-optimization/83867
31392 * tree-vect-stmts.c (vect_transform_stmt): Precompute
31393 nested_in_vect_loop_p since the scalar stmt may get invalidated.
31394
31395 2018-01-16 Jakub Jelinek <jakub@redhat.com>
31396
31397 PR c/83844
31398 * stor-layout.c (handle_warn_if_not_align): Use byte_position and
31399 multiple_of_p instead of unchecked tree_to_uhwi and UHWI check.
31400 If off is not INTEGER_CST, issue a may not be aligned warning
31401 rather than isn't aligned. Use isn%'t rather than isn't.
31402 * fold-const.c (multiple_of_p) <case BIT_AND_EXPR>: Don't fall through
31403 into MULT_EXPR.
31404 <case MULT_EXPR>: Improve the case when bottom and one of the
31405 MULT_EXPR operands are INTEGER_CSTs and bottom is multiple of that
31406 operand, in that case check if the other operand is multiple of
31407 bottom divided by the INTEGER_CST operand.
31408
31409 2018-01-16 Richard Sandiford <richard.sandiford@linaro.org>
31410
31411 PR target/83858
31412 * config/pa/pa.h (FUNCTION_ARG_SIZE): Delete.
31413 * config/pa/pa-protos.h (pa_function_arg_size): Declare.
31414 * config/pa/som.h (ASM_DECLARE_FUNCTION_NAME): Use
31415 pa_function_arg_size instead of FUNCTION_ARG_SIZE.
31416 * config/pa/pa.c (pa_function_arg_advance): Likewise.
31417 (pa_function_arg, pa_arg_partial_bytes): Likewise.
31418 (pa_function_arg_size): New function.
31419
31420 2018-01-16 Richard Sandiford <richard.sandiford@linaro.org>
31421
31422 * fold-const.c (fold_ternary_loc): Construct the vec_perm_indices
31423 in a separate statement.
31424
31425 2018-01-16 Richard Sandiford <richard.sandiford@linaro.org>
31426
31427 PR tree-optimization/83847
31428 * tree-vect-data-refs.c (vect_analyze_data_ref_accesses): Don't
31429 group gathers and scatters.
31430
31431 2018-01-16 Jakub Jelinek <jakub@redhat.com>
31432
31433 PR rtl-optimization/86620
31434 * params.def (max-sched-ready-insns): Bump minimum value to 1.
31435
31436 PR rtl-optimization/83213
31437 * recog.c (peep2_attempt): Copy over CROSSING_JUMP_P from peepinsn
31438 to last if both are JUMP_INSNs.
31439
31440 PR tree-optimization/83843
31441 * gimple-ssa-store-merging.c
31442 (imm_store_chain_info::output_merged_store): Handle bit_not_p on
31443 store_immediate_info for bswap/nop orig_stores.
31444
31445 2018-01-15 Andrew Waterman <andrew@sifive.com>
31446
31447 * config/riscv/riscv.c (riscv_rtx_costs) <MULT>: Increase cost if
31448 !TARGET_MUL.
31449 <UDIV>: Increase cost if !TARGET_DIV.
31450
31451 2018-01-15 Segher Boessenkool <segher@kernel.crashing.org>
31452
31453 * config/rs6000/rs6000.md (define_attr "type"): Remove delayed_cr.
31454 (define_attr "cr_logical_3op"): New.
31455 (cceq_ior_compare): Adjust.
31456 (cceq_ior_compare_complement): Adjust.
31457 (*cceq_rev_compare): Adjust.
31458 * config/rs6000/rs6000.c (rs6000_adjust_cost): Adjust.
31459 (is_cracked_insn): Adjust.
31460 (insn_must_be_first_in_group): Adjust.
31461 * config/rs6000/40x.md: Adjust.
31462 * config/rs6000/440.md: Adjust.
31463 * config/rs6000/476.md: Adjust.
31464 * config/rs6000/601.md: Adjust.
31465 * config/rs6000/603.md: Adjust.
31466 * config/rs6000/6xx.md: Adjust.
31467 * config/rs6000/7450.md: Adjust.
31468 * config/rs6000/7xx.md: Adjust.
31469 * config/rs6000/8540.md: Adjust.
31470 * config/rs6000/cell.md: Adjust.
31471 * config/rs6000/e300c2c3.md: Adjust.
31472 * config/rs6000/e500mc.md: Adjust.
31473 * config/rs6000/e500mc64.md: Adjust.
31474 * config/rs6000/e5500.md: Adjust.
31475 * config/rs6000/e6500.md: Adjust.
31476 * config/rs6000/mpc.md: Adjust.
31477 * config/rs6000/power4.md: Adjust.
31478 * config/rs6000/power5.md: Adjust.
31479 * config/rs6000/power6.md: Adjust.
31480 * config/rs6000/power7.md: Adjust.
31481 * config/rs6000/power8.md: Adjust.
31482 * config/rs6000/power9.md: Adjust.
31483 * config/rs6000/rs64.md: Adjust.
31484 * config/rs6000/titan.md: Adjust.
31485
31486 2018-01-15 H.J. Lu <hongjiu.lu@intel.com>
31487
31488 * config/i386/predicates.md (indirect_branch_operand): Rewrite
31489 ix86_indirect_branch_register logic.
31490
31491 2018-01-15 H.J. Lu <hongjiu.lu@intel.com>
31492
31493 * config/i386/constraints.md (Bs): Update
31494 ix86_indirect_branch_register check. Don't check
31495 ix86_indirect_branch_register with GOT_memory_operand.
31496 (Bw): Likewise.
31497 * config/i386/predicates.md (GOT_memory_operand): Don't check
31498 ix86_indirect_branch_register here.
31499 (GOT32_symbol_operand): Likewise.
31500
31501 2018-01-15 H.J. Lu <hongjiu.lu@intel.com>
31502
31503 * config/i386/predicates.md (constant_call_address_operand):
31504 Rewrite ix86_indirect_branch_register logic.
31505 (sibcall_insn_operand): Likewise.
31506
31507 2018-01-15 H.J. Lu <hongjiu.lu@intel.com>
31508
31509 * config/i386/constraints.md (Bs): Replace
31510 ix86_indirect_branch_thunk_register with
31511 ix86_indirect_branch_register.
31512 (Bw): Likewise.
31513 * config/i386/i386.md (indirect_jump): Likewise.
31514 (tablejump): Likewise.
31515 (*sibcall_memory): Likewise.
31516 (*sibcall_value_memory): Likewise.
31517 Peepholes of indirect call and jump via memory: Likewise.
31518 * config/i386/i386.opt: Likewise.
31519 * config/i386/predicates.md (indirect_branch_operand): Likewise.
31520 (GOT_memory_operand): Likewise.
31521 (call_insn_operand): Likewise.
31522 (sibcall_insn_operand): Likewise.
31523 (GOT32_symbol_operand): Likewise.
31524
31525 2018-01-15 Jakub Jelinek <jakub@redhat.com>
31526
31527 PR middle-end/83837
31528 * omp-expand.c (expand_omp_atomic_pipeline): Use loaded_val
31529 type rather than type addr's type points to.
31530 (expand_omp_atomic_mutex): Likewise.
31531 (expand_omp_atomic): Likewise.
31532
31533 2018-01-15 H.J. Lu <hongjiu.lu@intel.com>
31534
31535 PR target/83839
31536 * config/i386/i386.c (output_indirect_thunk_function): Use
31537 ASM_OUTPUT_LABEL, instead of ASM_OUTPUT_DEF, for TARGET_MACHO
31538 for __x86_return_thunk.
31539
31540 2018-01-15 Richard Biener <rguenther@suse.de>
31541
31542 PR middle-end/83850
31543 * expmed.c (extract_bit_field_1): Fix typo.
31544
31545 2018-01-15 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
31546
31547 PR target/83687
31548 * config/arm/iterators.md (VF): New mode iterator.
31549 * config/arm/neon.md (neon_vabd<mode>_2): Use the above.
31550 Remove integer-related logic from pattern.
31551 (neon_vabd<mode>_3): Likewise.
31552
31553 2018-01-15 Jakub Jelinek <jakub@redhat.com>
31554
31555 PR middle-end/82694
31556 * common.opt (fstrict-overflow): No longer an alias.
31557 (fwrapv-pointer): New option.
31558 * tree.h (TYPE_OVERFLOW_WRAPS, TYPE_OVERFLOW_UNDEFINED): Define
31559 also for pointer types based on flag_wrapv_pointer.
31560 * opts.c (common_handle_option) <case OPT_fstrict_overflow>: Set
31561 opts->x_flag_wrap[pv] to !value, clear opts->x_flag_trapv if
31562 opts->x_flag_wrapv got set.
31563 * fold-const.c (fold_comparison, fold_binary_loc): Revert 2017-08-01
31564 changes, just use TYPE_OVERFLOW_UNDEFINED on pointer type instead of
31565 POINTER_TYPE_OVERFLOW_UNDEFINED.
31566 * match.pd: Likewise in address comparison pattern.
31567 * doc/invoke.texi: Document -fwrapv and -fstrict-overflow.
31568
31569 2018-01-15 Richard Biener <rguenther@suse.de>
31570
31571 PR lto/83804
31572 * tree.c (free_lang_data_in_type): Always unlink TYPE_DECLs
31573 from TYPE_FIELDS. Free TYPE_BINFO if not used by devirtualization.
31574 Reset type names to their identifier if their TYPE_DECL doesn't
31575 have linkage (and thus is used for ODR and devirt).
31576 (save_debug_info_for_decl): Remove.
31577 (save_debug_info_for_type): Likewise.
31578 (add_tree_to_fld_list): Adjust.
31579 * tree-pretty-print.c (dump_generic_node): Make dumping of
31580 type names more robust.
31581
31582 2018-01-15 Richard Biener <rguenther@suse.de>
31583
31584 * BASE-VER: Bump to 8.0.1.
31585
31586 2018-01-14 Martin Sebor <msebor@redhat.com>
31587
31588 PR other/83508
31589 * builtins.c (check_access): Avoid warning when the no-warning bit
31590 is set.
31591
31592 2018-01-14 Cory Fields <cory-nospam-@coryfields.com>
31593
31594 * tree-ssa-loop-im.c (sort_bbs_in_loop_postorder_cmp): Stabilize sort.
31595 * ira-color (allocno_hard_regs_compare): Likewise.
31596
31597 2018-01-14 Nathan Rossi <nathan@nathanrossi.com>
31598
31599 PR target/83013
31600 * config/microblaze/microblaze.c (microblaze_asm_output_ident):
31601 Use .pushsection/.popsection.
31602
31603 2018-01-14 Martin Sebor <msebor@redhat.com>
31604
31605 PR c++/81327
31606 * doc/invoke.texi (-Wlass-memaccess): Document suppression by casting.
31607
31608 2018-01-14 Jakub Jelinek <jakub@redhat.com>
31609
31610 * config.gcc (i[34567]86-*-*): Remove one duplicate gfniintrin.h
31611 entry from extra_headers.
31612 (x86_64-*-*): Remove two duplicate gfniintrin.h entries from
31613 extra_headers, make the list bitwise identical to the i?86-*-* one.
31614
31615 2018-01-14 H.J. Lu <hongjiu.lu@intel.com>
31616
31617 * config/i386/i386.c (ix86_set_indirect_branch_type): Disallow
31618 -mcmodel=large with -mindirect-branch=thunk,
31619 -mindirect-branch=thunk-extern, -mfunction-return=thunk and
31620 -mfunction-return=thunk-extern.
31621 * doc/invoke.texi: Document -mcmodel=large is incompatible with
31622 -mindirect-branch=thunk, -mindirect-branch=thunk-extern,
31623 -mfunction-return=thunk and -mfunction-return=thunk-extern.
31624
31625 2018-01-14 H.J. Lu <hongjiu.lu@intel.com>
31626
31627 * config/i386/i386.c (print_reg): Print the name of the full
31628 integer register without '%'.
31629 (ix86_print_operand): Handle 'V'.
31630 * doc/extend.texi: Document 'V' modifier.
31631
31632 2018-01-14 H.J. Lu <hongjiu.lu@intel.com>
31633
31634 * config/i386/constraints.md (Bs): Disallow memory operand for
31635 -mindirect-branch-register.
31636 (Bw): Likewise.
31637 * config/i386/predicates.md (indirect_branch_operand): Likewise.
31638 (GOT_memory_operand): Likewise.
31639 (call_insn_operand): Likewise.
31640 (sibcall_insn_operand): Likewise.
31641 (GOT32_symbol_operand): Likewise.
31642 * config/i386/i386.md (indirect_jump): Call convert_memory_address
31643 for -mindirect-branch-register.
31644 (tablejump): Likewise.
31645 (*sibcall_memory): Likewise.
31646 (*sibcall_value_memory): Likewise.
31647 Disallow peepholes of indirect call and jump via memory for
31648 -mindirect-branch-register.
31649 (*call_pop): Replace m with Bw.
31650 (*call_value_pop): Likewise.
31651 (*sibcall_pop_memory): Replace m with Bs.
31652 * config/i386/i386.opt (mindirect-branch-register): New option.
31653 * doc/invoke.texi: Document -mindirect-branch-register option.
31654
31655 2018-01-14 H.J. Lu <hongjiu.lu@intel.com>
31656
31657 * config/i386/i386-protos.h (ix86_output_function_return): New.
31658 * config/i386/i386.c (ix86_set_indirect_branch_type): Also
31659 set function_return_type.
31660 (indirect_thunk_name): Add ret_p to indicate thunk for function
31661 return.
31662 (output_indirect_thunk_function): Pass false to
31663 indirect_thunk_name.
31664 (ix86_output_indirect_branch_via_reg): Likewise.
31665 (ix86_output_indirect_branch_via_push): Likewise.
31666 (output_indirect_thunk_function): Create alias for function
31667 return thunk if regno < 0.
31668 (ix86_output_function_return): New function.
31669 (ix86_handle_fndecl_attribute): Handle function_return.
31670 (ix86_attribute_table): Add function_return.
31671 * config/i386/i386.h (machine_function): Add
31672 function_return_type.
31673 * config/i386/i386.md (simple_return_internal): Use
31674 ix86_output_function_return.
31675 (simple_return_internal_long): Likewise.
31676 * config/i386/i386.opt (mfunction-return=): New option.
31677 (indirect_branch): Mention -mfunction-return=.
31678 * doc/extend.texi: Document function_return function attribute.
31679 * doc/invoke.texi: Document -mfunction-return= option.
31680
31681 2018-01-14 H.J. Lu <hongjiu.lu@intel.com>
31682
31683 * config/i386/i386-opts.h (indirect_branch): New.
31684 * config/i386/i386-protos.h (ix86_output_indirect_jmp): Likewise.
31685 * config/i386/i386.c (ix86_using_red_zone): Disallow red-zone
31686 with local indirect jump when converting indirect call and jump.
31687 (ix86_set_indirect_branch_type): New.
31688 (ix86_set_current_function): Call ix86_set_indirect_branch_type.
31689 (indirectlabelno): New.
31690 (indirect_thunk_needed): Likewise.
31691 (indirect_thunk_bnd_needed): Likewise.
31692 (indirect_thunks_used): Likewise.
31693 (indirect_thunks_bnd_used): Likewise.
31694 (INDIRECT_LABEL): Likewise.
31695 (indirect_thunk_name): Likewise.
31696 (output_indirect_thunk): Likewise.
31697 (output_indirect_thunk_function): Likewise.
31698 (ix86_output_indirect_branch_via_reg): Likewise.
31699 (ix86_output_indirect_branch_via_push): Likewise.
31700 (ix86_output_indirect_branch): Likewise.
31701 (ix86_output_indirect_jmp): Likewise.
31702 (ix86_code_end): Call output_indirect_thunk_function if needed.
31703 (ix86_output_call_insn): Call ix86_output_indirect_branch if
31704 needed.
31705 (ix86_handle_fndecl_attribute): Handle indirect_branch.
31706 (ix86_attribute_table): Add indirect_branch.
31707 * config/i386/i386.h (machine_function): Add indirect_branch_type
31708 and has_local_indirect_jump.
31709 * config/i386/i386.md (indirect_jump): Set has_local_indirect_jump
31710 to true.
31711 (tablejump): Likewise.
31712 (*indirect_jump): Use ix86_output_indirect_jmp.
31713 (*tablejump_1): Likewise.
31714 (simple_return_indirect_internal): Likewise.
31715 * config/i386/i386.opt (mindirect-branch=): New option.
31716 (indirect_branch): New.
31717 (keep): Likewise.
31718 (thunk): Likewise.
31719 (thunk-inline): Likewise.
31720 (thunk-extern): Likewise.
31721 * doc/extend.texi: Document indirect_branch function attribute.
31722 * doc/invoke.texi: Document -mindirect-branch= option.
31723
31724 2018-01-14 Jan Hubicka <hubicka@ucw.cz>
31725
31726 PR ipa/83051
31727 * ipa-inline.c (edge_badness): Tolerate roundoff errors.
31728
31729 2018-01-14 Richard Sandiford <richard.sandiford@linaro.org>
31730
31731 * ipa-inline.c (want_inline_small_function_p): Return false if
31732 inlining has already failed with CIF_FINAL_ERROR.
31733 (update_caller_keys): Call want_inline_small_function_p before
31734 can_inline_edge_p.
31735 (update_callee_keys): Likewise.
31736
31737 2018-01-10 Kelvin Nilsen <kelvin@gcc.gnu.org>
31738
31739 * config/rs6000/rs6000-p8swap.c (rs6000_sum_of_two_registers_p):
31740 New function.
31741 (rs6000_quadword_masked_address_p): Likewise.
31742 (quad_aligned_load_p): Likewise.
31743 (quad_aligned_store_p): Likewise.
31744 (const_load_sequence_p): Add comment to describe the outer-most loop.
31745 (mimic_memory_attributes_and_flags): New function.
31746 (rs6000_gen_stvx): Likewise.
31747 (replace_swapped_aligned_store): Likewise.
31748 (rs6000_gen_lvx): Likewise.
31749 (replace_swapped_aligned_load): Likewise.
31750 (replace_swapped_load_constant): Capitalize argument name in
31751 comment describing this function.
31752 (rs6000_analyze_swaps): Add a third pass to search for vector loads
31753 and stores that access quad-word aligned addresses and replace
31754 with stvx or lvx instructions when appropriate.
31755 * config/rs6000/rs6000-protos.h (rs6000_sum_of_two_registers_p):
31756 New function prototype.
31757 (rs6000_quadword_masked_address_p): Likewise.
31758 (rs6000_gen_lvx): Likewise.
31759 (rs6000_gen_stvx): Likewise.
31760 * config/rs6000/vsx.md (*vsx_le_perm_load_<mode>): For modes
31761 VSX_D (V2DF, V2DI), modify this split to select lvx instruction
31762 when memory address is aligned.
31763 (*vsx_le_perm_load_<mode>): For modes VSX_W (V4SF, V4SI), modify
31764 this split to select lvx instruction when memory address is aligned.
31765 (*vsx_le_perm_load_v8hi): Modify this split to select lvx
31766 instruction when memory address is aligned.
31767 (*vsx_le_perm_load_v16qi): Likewise.
31768 (four unnamed splitters): Modify to select the stvx instruction
31769 when memory is aligned.
31770
31771 2018-01-13 Jan Hubicka <hubicka@ucw.cz>
31772
31773 * predict.c (determine_unlikely_bbs): Handle correctly BBs
31774 which appears in the queue multiple times.
31775
31776 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
31777 Alan Hayward <alan.hayward@arm.com>
31778 David Sherwood <david.sherwood@arm.com>
31779
31780 * tree-vectorizer.h (vec_lower_bound): New structure.
31781 (_loop_vec_info): Add check_nonzero and lower_bounds.
31782 (LOOP_VINFO_CHECK_NONZERO): New macro.
31783 (LOOP_VINFO_LOWER_BOUNDS): Likewise.
31784 (LOOP_REQUIRES_VERSIONING_FOR_ALIAS): Check lower_bounds too.
31785 * tree-data-ref.h (dr_with_seg_len): Add access_size and align
31786 fields. Make seg_len the distance travelled, not including the
31787 access size.
31788 (dr_direction_indicator): Declare.
31789 (dr_zero_step_indicator): Likewise.
31790 (dr_known_forward_stride_p): Likewise.
31791 * tree-data-ref.c: Include stringpool.h, tree-vrp.h and
31792 tree-ssanames.h.
31793 (runtime_alias_check_p): Allow runtime alias checks with
31794 variable strides.
31795 (operator ==): Compare access_size and align.
31796 (prune_runtime_alias_test_list): Rework for new distinction between
31797 the access_size and seg_len.
31798 (create_intersect_range_checks_index): Likewise. Cope with polynomial
31799 segment lengths.
31800 (get_segment_min_max): New function.
31801 (create_intersect_range_checks): Use it.
31802 (dr_step_indicator): New function.
31803 (dr_direction_indicator): Likewise.
31804 (dr_zero_step_indicator): Likewise.
31805 (dr_known_forward_stride_p): Likewise.
31806 * tree-loop-distribution.c (data_ref_segment_size): Return
31807 DR_STEP * (niters - 1).
31808 (compute_alias_check_pairs): Update call to the dr_with_seg_len
31809 constructor.
31810 * tree-vect-data-refs.c (vect_check_nonzero_value): New function.
31811 (vect_preserves_scalar_order_p): New function, split out from...
31812 (vect_analyze_data_ref_dependence): ...here. Check for zero steps.
31813 (vect_vfa_segment_size): Return DR_STEP * (length_factor - 1).
31814 (vect_vfa_access_size): New function.
31815 (vect_vfa_align): Likewise.
31816 (vect_compile_time_alias): Take access_size_a and access_b arguments.
31817 (dump_lower_bound): New function.
31818 (vect_check_lower_bound): Likewise.
31819 (vect_small_gap_p): Likewise.
31820 (vectorizable_with_step_bound_p): Likewise.
31821 (vect_prune_runtime_alias_test_list): Ignore cross-iteration
31822 depencies if the vectorization factor is 1. Convert the checks
31823 for nonzero steps into checks on the bounds of DR_STEP. Try using
31824 a bunds check for variable steps if the minimum required step is
31825 relatively small. Update calls to the dr_with_seg_len
31826 constructor and to vect_compile_time_alias.
31827 * tree-vect-loop-manip.c (vect_create_cond_for_lower_bounds): New
31828 function.
31829 (vect_loop_versioning): Call it.
31830 * tree-vect-loop.c (vect_analyze_loop_2): Clear LOOP_VINFO_LOWER_BOUNDS
31831 when retrying.
31832 (vect_estimate_min_profitable_iters): Account for any bounds checks.
31833
31834 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
31835 Alan Hayward <alan.hayward@arm.com>
31836 David Sherwood <david.sherwood@arm.com>
31837
31838 * doc/sourcebuild.texi (vect_scatter_store): Document.
31839 * optabs.def (scatter_store_optab, mask_scatter_store_optab): New
31840 optabs.
31841 * doc/md.texi (scatter_store@var{m}, mask_scatter_store@var{m}):
31842 Document.
31843 * genopinit.c (main): Add supports_vec_scatter_store and
31844 supports_vec_scatter_store_cached to target_optabs.
31845 * gimple.h (gimple_expr_type): Handle IFN_SCATTER_STORE and
31846 IFN_MASK_SCATTER_STORE.
31847 * internal-fn.def (SCATTER_STORE, MASK_SCATTER_STORE): New internal
31848 functions.
31849 * internal-fn.h (internal_store_fn_p): Declare.
31850 (internal_fn_stored_value_index): Likewise.
31851 * internal-fn.c (scatter_store_direct): New macro.
31852 (expand_scatter_store_optab_fn): New function.
31853 (direct_scatter_store_optab_supported_p): New macro.
31854 (internal_store_fn_p): New function.
31855 (internal_gather_scatter_fn_p): Handle IFN_SCATTER_STORE and
31856 IFN_MASK_SCATTER_STORE.
31857 (internal_fn_mask_index): Likewise.
31858 (internal_fn_stored_value_index): New function.
31859 (internal_gather_scatter_fn_supported_p): Adjust operand numbers
31860 for scatter stores.
31861 * optabs-query.h (supports_vec_scatter_store_p): Declare.
31862 * optabs-query.c (supports_vec_scatter_store_p): New function.
31863 * tree-vectorizer.h (vect_get_store_rhs): Declare.
31864 * tree-vect-data-refs.c (vect_analyze_data_ref_access): Return
31865 true for scatter stores.
31866 (vect_gather_scatter_fn_p): Handle scatter stores too.
31867 (vect_check_gather_scatter): Consider using scatter stores if
31868 supports_vec_scatter_store_p.
31869 * tree-vect-patterns.c (vect_try_gather_scatter_pattern): Handle
31870 scatter stores too.
31871 * tree-vect-stmts.c (exist_non_indexing_operands_for_use_p): Use
31872 internal_fn_stored_value_index.
31873 (check_load_store_masking): Handle scatter stores too.
31874 (vect_get_store_rhs): Make public.
31875 (vectorizable_call): Use internal_store_fn_p.
31876 (vectorizable_store): Handle scatter store internal functions.
31877 (vect_transform_stmt): Compare GROUP_STORE_COUNT with GROUP_SIZE
31878 when deciding whether the end of the group has been reached.
31879 * config/aarch64/aarch64.md (UNSPEC_ST1_SCATTER): New unspec.
31880 * config/aarch64/aarch64-sve.md (scatter_store<mode>): New expander.
31881 (mask_scatter_store<mode>): New insns.
31882
31883 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
31884 Alan Hayward <alan.hayward@arm.com>
31885 David Sherwood <david.sherwood@arm.com>
31886
31887 * tree-vectorizer.h (vect_gather_scatter_fn_p): Declare.
31888 * tree-vect-data-refs.c (vect_gather_scatter_fn_p): Make public.
31889 * tree-vect-stmts.c (vect_truncate_gather_scatter_offset): New
31890 function.
31891 (vect_use_strided_gather_scatters_p): Take a masked_p argument.
31892 Use vect_truncate_gather_scatter_offset if we can't treat the
31893 operation as a normal gather load or scatter store.
31894 (get_group_load_store_type): Take the gather_scatter_info
31895 as argument. Try using a gather load or scatter store for
31896 single-element groups.
31897 (get_load_store_type): Update calls to get_group_load_store_type
31898 and vect_use_strided_gather_scatters_p.
31899
31900 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
31901 Alan Hayward <alan.hayward@arm.com>
31902 David Sherwood <david.sherwood@arm.com>
31903
31904 * tree-vectorizer.h (vect_create_data_ref_ptr): Take an extra
31905 optional tree argument.
31906 * tree-vect-data-refs.c (vect_check_gather_scatter): Check for
31907 null target hooks.
31908 (vect_create_data_ref_ptr): Take the iv_step as an optional argument,
31909 but continue to use the current value as a fallback.
31910 (bump_vector_ptr): Use operand_equal_p rather than tree_int_cst_compare
31911 to compare the updates.
31912 * tree-vect-stmts.c (vect_use_strided_gather_scatters_p): New function.
31913 (get_load_store_type): Use it when handling a strided access.
31914 (vect_get_strided_load_store_ops): New function.
31915 (vect_get_data_ptr_increment): Likewise.
31916 (vectorizable_load): Handle strided gather loads. Always pass
31917 a step to vect_create_data_ref_ptr and bump_vector_ptr.
31918
31919 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
31920 Alan Hayward <alan.hayward@arm.com>
31921 David Sherwood <david.sherwood@arm.com>
31922
31923 * doc/md.texi (gather_load@var{m}): Document.
31924 (mask_gather_load@var{m}): Likewise.
31925 * genopinit.c (main): Add supports_vec_gather_load and
31926 supports_vec_gather_load_cached to target_optabs.
31927 * optabs-tree.c (init_tree_optimization_optabs): Use
31928 ggc_cleared_alloc to allocate target_optabs.
31929 * optabs.def (gather_load_optab, mask_gather_laod_optab): New optabs.
31930 * internal-fn.def (GATHER_LOAD, MASK_GATHER_LOAD): New internal
31931 functions.
31932 * internal-fn.h (internal_load_fn_p): Declare.
31933 (internal_gather_scatter_fn_p): Likewise.
31934 (internal_fn_mask_index): Likewise.
31935 (internal_gather_scatter_fn_supported_p): Likewise.
31936 * internal-fn.c (gather_load_direct): New macro.
31937 (expand_gather_load_optab_fn): New function.
31938 (direct_gather_load_optab_supported_p): New macro.
31939 (direct_internal_fn_optab): New function.
31940 (internal_load_fn_p): Likewise.
31941 (internal_gather_scatter_fn_p): Likewise.
31942 (internal_fn_mask_index): Likewise.
31943 (internal_gather_scatter_fn_supported_p): Likewise.
31944 * optabs-query.c (supports_at_least_one_mode_p): New function.
31945 (supports_vec_gather_load_p): Likewise.
31946 * optabs-query.h (supports_vec_gather_load_p): Declare.
31947 * tree-vectorizer.h (gather_scatter_info): Add ifn, element_type
31948 and memory_type field.
31949 (NUM_PATTERNS): Bump to 15.
31950 * tree-vect-data-refs.c: Include internal-fn.h.
31951 (vect_gather_scatter_fn_p): New function.
31952 (vect_describe_gather_scatter_call): Likewise.
31953 (vect_check_gather_scatter): Try using internal functions for
31954 gather loads. Recognize existing calls to a gather load function.
31955 (vect_analyze_data_refs): Consider using gather loads if
31956 supports_vec_gather_load_p.
31957 * tree-vect-patterns.c (vect_get_load_store_mask): New function.
31958 (vect_get_gather_scatter_offset_type): Likewise.
31959 (vect_convert_mask_for_vectype): Likewise.
31960 (vect_add_conversion_to_patterm): Likewise.
31961 (vect_try_gather_scatter_pattern): Likewise.
31962 (vect_recog_gather_scatter_pattern): New pattern recognizer.
31963 (vect_vect_recog_func_ptrs): Add it.
31964 * tree-vect-stmts.c (exist_non_indexing_operands_for_use_p): Use
31965 internal_fn_mask_index and internal_gather_scatter_fn_p.
31966 (check_load_store_masking): Take the gather_scatter_info as an
31967 argument and handle gather loads.
31968 (vect_get_gather_scatter_ops): New function.
31969 (vectorizable_call): Check internal_load_fn_p.
31970 (vectorizable_load): Likewise. Handle gather load internal
31971 functions.
31972 (vectorizable_store): Update call to check_load_store_masking.
31973 * config/aarch64/aarch64.md (UNSPEC_LD1_GATHER): New unspec.
31974 * config/aarch64/iterators.md (SVE_S, SVE_D): New mode iterators.
31975 * config/aarch64/predicates.md (aarch64_gather_scale_operand_w)
31976 (aarch64_gather_scale_operand_d): New predicates.
31977 * config/aarch64/aarch64-sve.md (gather_load<mode>): New expander.
31978 (mask_gather_load<mode>): New insns.
31979
31980 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
31981 Alan Hayward <alan.hayward@arm.com>
31982 David Sherwood <david.sherwood@arm.com>
31983
31984 * optabs.def (fold_left_plus_optab): New optab.
31985 * doc/md.texi (fold_left_plus_@var{m}): Document.
31986 * internal-fn.def (IFN_FOLD_LEFT_PLUS): New internal function.
31987 * internal-fn.c (fold_left_direct): Define.
31988 (expand_fold_left_optab_fn): Likewise.
31989 (direct_fold_left_optab_supported_p): Likewise.
31990 * fold-const-call.c (fold_const_fold_left): New function.
31991 (fold_const_call): Use it to fold CFN_FOLD_LEFT_PLUS.
31992 * tree-parloops.c (valid_reduction_p): New function.
31993 (gather_scalar_reductions): Use it.
31994 * tree-vectorizer.h (FOLD_LEFT_REDUCTION): New vect_reduction_type.
31995 (vect_finish_replace_stmt): Declare.
31996 * tree-vect-loop.c (fold_left_reduction_fn): New function.
31997 (needs_fold_left_reduction_p): New function, split out from...
31998 (vect_is_simple_reduction): ...here. Accept reductions that
31999 forbid reassociation, but give them type FOLD_LEFT_REDUCTION.
32000 (vect_force_simple_reduction): Also store the reduction type in
32001 the assignment's STMT_VINFO_REDUC_TYPE.
32002 (vect_model_reduction_cost): Handle FOLD_LEFT_REDUCTION.
32003 (merge_with_identity): New function.
32004 (vect_expand_fold_left): Likewise.
32005 (vectorize_fold_left_reduction): Likewise.
32006 (vectorizable_reduction): Handle FOLD_LEFT_REDUCTION. Leave the
32007 scalar phi in place for it. Check for target support and reject
32008 cases that would reassociate the operation. Defer the transform
32009 phase to vectorize_fold_left_reduction.
32010 * config/aarch64/aarch64.md (UNSPEC_FADDA): New unspec.
32011 * config/aarch64/aarch64-sve.md (fold_left_plus_<mode>): New expander.
32012 (*fold_left_plus_<mode>, *pred_fold_left_plus_<mode>): New insns.
32013
32014 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32015
32016 * tree-if-conv.c (predicate_mem_writes): Remove redundant
32017 call to ifc_temp_var.
32018
32019 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32020 Alan Hayward <alan.hayward@arm.com>
32021 David Sherwood <david.sherwood@arm.com>
32022
32023 * target.def (legitimize_address_displacement): Take the original
32024 offset as a poly_int.
32025 * targhooks.h (default_legitimize_address_displacement): Update
32026 accordingly.
32027 * targhooks.c (default_legitimize_address_displacement): Likewise.
32028 * doc/tm.texi: Regenerate.
32029 * lra-constraints.c (base_plus_disp_to_reg): Take the displacement
32030 as an argument, moving assert of ad->disp == ad->disp_term to...
32031 (process_address_1): ...here. Update calls to base_plus_disp_to_reg.
32032 Try calling targetm.legitimize_address_displacement before expanding
32033 the address rather than afterwards, and adjust for the new interface.
32034 * config/aarch64/aarch64.c (aarch64_legitimize_address_displacement):
32035 Match the new hook interface. Handle SVE addresses.
32036 * config/sh/sh.c (sh_legitimize_address_displacement): Make the
32037 new hook interface.
32038
32039 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32040
32041 * Makefile.in (OBJS): Add early-remat.o.
32042 * target.def (select_early_remat_modes): New hook.
32043 * doc/tm.texi.in (TARGET_SELECT_EARLY_REMAT_MODES): New hook.
32044 * doc/tm.texi: Regenerate.
32045 * targhooks.h (default_select_early_remat_modes): Declare.
32046 * targhooks.c (default_select_early_remat_modes): New function.
32047 * timevar.def (TV_EARLY_REMAT): New timevar.
32048 * passes.def (pass_early_remat): New pass.
32049 * tree-pass.h (make_pass_early_remat): Declare.
32050 * early-remat.c: New file.
32051 * config/aarch64/aarch64.c (aarch64_select_early_remat_modes): New
32052 function.
32053 (TARGET_SELECT_EARLY_REMAT_MODES): Define.
32054
32055 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32056 Alan Hayward <alan.hayward@arm.com>
32057 David Sherwood <david.sherwood@arm.com>
32058
32059 * tree-vect-loop-manip.c (vect_gen_scalar_loop_niters): Replace
32060 vfm1 with a bound_epilog parameter.
32061 (vect_do_peeling): Update calls accordingly, and move the prologue
32062 call earlier in the function. Treat the base bound_epilog as 0 for
32063 fully-masked loops and retain vf - 1 for other loops. Add 1 to
32064 this base when peeling for gaps.
32065 * tree-vect-loop.c (vect_analyze_loop_2): Allow peeling for gaps
32066 with fully-masked loops.
32067 (vect_estimate_min_profitable_iters): Handle the single peeled
32068 iteration in that case.
32069
32070 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32071 Alan Hayward <alan.hayward@arm.com>
32072 David Sherwood <david.sherwood@arm.com>
32073
32074 * tree-vect-data-refs.c (vect_analyze_group_access_1): Allow
32075 single-element interleaving even if the size is not a power of 2.
32076 * tree-vect-stmts.c (get_load_store_type): Disallow elementwise
32077 accesses for single-element interleaving if the group size is
32078 not a power of 2.
32079
32080 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32081 Alan Hayward <alan.hayward@arm.com>
32082 David Sherwood <david.sherwood@arm.com>
32083
32084 * doc/md.texi (fold_extract_last_@var{m}): Document.
32085 * doc/sourcebuild.texi (vect_fold_extract_last): Likewise.
32086 * optabs.def (fold_extract_last_optab): New optab.
32087 * internal-fn.def (FOLD_EXTRACT_LAST): New internal function.
32088 * internal-fn.c (fold_extract_direct): New macro.
32089 (expand_fold_extract_optab_fn): Likewise.
32090 (direct_fold_extract_optab_supported_p): Likewise.
32091 * tree-vectorizer.h (EXTRACT_LAST_REDUCTION): New vect_reduction_type.
32092 * tree-vect-loop.c (vect_model_reduction_cost): Handle
32093 EXTRACT_LAST_REDUCTION.
32094 (get_initial_def_for_reduction): Do not create an initial vector
32095 for EXTRACT_LAST_REDUCTION reductions.
32096 (vectorizable_reduction): Leave the scalar phi in place for
32097 EXTRACT_LAST_REDUCTIONs. Try using EXTRACT_LAST_REDUCTION
32098 ahead of INTEGER_INDUC_COND_REDUCTION. Do not check for an
32099 epilogue code for EXTRACT_LAST_REDUCTION and defer the
32100 transform phase to vectorizable_condition.
32101 * tree-vect-stmts.c (vect_finish_stmt_generation_1): New function,
32102 split out from...
32103 (vect_finish_stmt_generation): ...here.
32104 (vect_finish_replace_stmt): New function.
32105 (vectorizable_condition): Handle EXTRACT_LAST_REDUCTION.
32106 * config/aarch64/aarch64-sve.md (fold_extract_last_<mode>): New
32107 pattern.
32108 * config/aarch64/aarch64.md (UNSPEC_CLASTB): New unspec.
32109
32110 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32111 Alan Hayward <alan.hayward@arm.com>
32112 David Sherwood <david.sherwood@arm.com>
32113
32114 * doc/md.texi (extract_last_@var{m}): Document.
32115 * optabs.def (extract_last_optab): New optab.
32116 * internal-fn.def (EXTRACT_LAST): New internal function.
32117 * internal-fn.c (cond_unary_direct): New macro.
32118 (expand_cond_unary_optab_fn): Likewise.
32119 (direct_cond_unary_optab_supported_p): Likewise.
32120 * tree-vect-loop.c (vectorizable_live_operation): Allow fully-masked
32121 loops using EXTRACT_LAST.
32122 * config/aarch64/aarch64-sve.md (aarch64_sve_lastb<mode>): Rename to...
32123 (extract_last_<mode>): ...this optab.
32124 (vec_extract<mode><Vel>): Update accordingly.
32125
32126 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32127 Alan Hayward <alan.hayward@arm.com>
32128 David Sherwood <david.sherwood@arm.com>
32129
32130 * target.def (empty_mask_is_expensive): New hook.
32131 * doc/tm.texi.in (TARGET_VECTORIZE_EMPTY_MASK_IS_EXPENSIVE): New hook.
32132 * doc/tm.texi: Regenerate.
32133 * targhooks.h (default_empty_mask_is_expensive): Declare.
32134 * targhooks.c (default_empty_mask_is_expensive): New function.
32135 * tree-vectorizer.c (vectorize_loops): Only call optimize_mask_stores
32136 if the target says that empty masks are expensive.
32137 * config/aarch64/aarch64.c (aarch64_empty_mask_is_expensive):
32138 New function.
32139 (TARGET_VECTORIZE_EMPTY_MASK_IS_EXPENSIVE): Redefine.
32140
32141 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32142 Alan Hayward <alan.hayward@arm.com>
32143 David Sherwood <david.sherwood@arm.com>
32144
32145 * tree-vectorizer.h (_loop_vec_info::mask_skip_niters): New field.
32146 (LOOP_VINFO_MASK_SKIP_NITERS): New macro.
32147 (vect_use_loop_mask_for_alignment_p): New function.
32148 (vect_prepare_for_masked_peels, vect_gen_while_not): Declare.
32149 * tree-vect-loop-manip.c (vect_set_loop_masks_directly): Add an
32150 niters_skip argument. Make sure that the first niters_skip elements
32151 of the first iteration are inactive.
32152 (vect_set_loop_condition_masked): Handle LOOP_VINFO_MASK_SKIP_NITERS.
32153 Update call to vect_set_loop_masks_directly.
32154 (get_misalign_in_elems): New function, split out from...
32155 (vect_gen_prolog_loop_niters): ...here.
32156 (vect_update_init_of_dr): Take a code argument that specifies whether
32157 the adjustment should be added or subtracted.
32158 (vect_update_init_of_drs): Likewise.
32159 (vect_prepare_for_masked_peels): New function.
32160 (vect_do_peeling): Skip prologue peeling if we're using a mask
32161 instead. Update call to vect_update_inits_of_drs.
32162 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Initialize
32163 mask_skip_niters.
32164 (vect_analyze_loop_2): Allow fully-masked loops with peeling for
32165 alignment. Do not include the number of peeled iterations in
32166 the minimum threshold in that case.
32167 (vectorizable_induction): Adjust the start value down by
32168 LOOP_VINFO_MASK_SKIP_NITERS iterations.
32169 (vect_transform_loop): Call vect_prepare_for_masked_peels.
32170 Take the number of skipped iterations into account when calculating
32171 the loop bounds.
32172 * tree-vect-stmts.c (vect_gen_while_not): New function.
32173
32174 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32175 Alan Hayward <alan.hayward@arm.com>
32176 David Sherwood <david.sherwood@arm.com>
32177
32178 * doc/sourcebuild.texi (vect_fully_masked): Document.
32179 * params.def (PARAM_MIN_VECT_LOOP_BOUND): Change minimum and
32180 default value to 0.
32181 * tree-vect-loop.c (vect_analyze_loop_costing): New function,
32182 split out from...
32183 (vect_analyze_loop_2): ...here. Don't check the vectorization
32184 factor against the number of loop iterations if the loop is
32185 fully-masked.
32186
32187 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32188 Alan Hayward <alan.hayward@arm.com>
32189 David Sherwood <david.sherwood@arm.com>
32190
32191 * tree-ssa-loop-ivopts.c (USE_ADDRESS): Split into...
32192 (USE_REF_ADDRESS, USE_PTR_ADDRESS): ...these new use types.
32193 (dump_groups): Update accordingly.
32194 (iv_use::mem_type): New member variable.
32195 (address_p): New function.
32196 (record_use): Add a mem_type argument and initialize the new
32197 mem_type field.
32198 (record_group_use): Add a mem_type argument. Use address_p.
32199 Remove obsolete null checks of base_object. Update call to record_use.
32200 (find_interesting_uses_op): Update call to record_group_use.
32201 (find_interesting_uses_cond): Likewise.
32202 (find_interesting_uses_address): Likewise.
32203 (get_mem_type_for_internal_fn): New function.
32204 (find_address_like_use): Likewise.
32205 (find_interesting_uses_stmt): Try find_address_like_use before
32206 calling find_interesting_uses_op.
32207 (addr_offset_valid_p): Use the iv mem_type field as the type
32208 of the addressed memory.
32209 (add_autoinc_candidates): Likewise.
32210 (get_address_cost): Likewise.
32211 (split_small_address_groups_p): Use address_p.
32212 (split_address_groups): Likewise.
32213 (add_iv_candidate_for_use): Likewise.
32214 (autoinc_possible_for_pair): Likewise.
32215 (rewrite_groups): Likewise.
32216 (get_use_type): Check for USE_REF_ADDRESS instead of USE_ADDRESS.
32217 (determine_group_iv_cost): Update after split of USE_ADDRESS.
32218 (get_alias_ptr_type_for_ptr_address): New function.
32219 (rewrite_use_address): Rewrite address uses in calls that were
32220 identified by find_address_like_use.
32221
32222 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32223 Alan Hayward <alan.hayward@arm.com>
32224 David Sherwood <david.sherwood@arm.com>
32225
32226 * expr.c (expand_expr_addr_expr_1): Handle ADDR_EXPRs of
32227 TARGET_MEM_REFs.
32228 * gimple-expr.h (is_gimple_addressable: Likewise.
32229 * gimple-expr.c (is_gimple_address): Likewise.
32230 * internal-fn.c (expand_call_mem_ref): New function.
32231 (expand_mask_load_optab_fn): Use it.
32232 (expand_mask_store_optab_fn): Likewise.
32233
32234 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32235 Alan Hayward <alan.hayward@arm.com>
32236 David Sherwood <david.sherwood@arm.com>
32237
32238 * doc/md.texi (cond_add@var{mode}, cond_sub@var{mode})
32239 (cond_and@var{mode}, cond_ior@var{mode}, cond_xor@var{mode})
32240 (cond_smin@var{mode}, cond_smax@var{mode}, cond_umin@var{mode})
32241 (cond_umax@var{mode}): Document.
32242 * optabs.def (cond_add_optab, cond_sub_optab, cond_and_optab)
32243 (cond_ior_optab, cond_xor_optab, cond_smin_optab, cond_smax_optab)
32244 (cond_umin_optab, cond_umax_optab): New optabs.
32245 * internal-fn.def (COND_ADD, COND_SUB, COND_MIN, COND_MAX, COND_AND)
32246 (COND_IOR, COND_XOR): New internal functions.
32247 * internal-fn.h (get_conditional_internal_fn): Declare.
32248 * internal-fn.c (cond_binary_direct): New macro.
32249 (expand_cond_binary_optab_fn): Likewise.
32250 (direct_cond_binary_optab_supported_p): Likewise.
32251 (get_conditional_internal_fn): New function.
32252 * tree-vect-loop.c (vectorizable_reduction): Handle fully-masked loops.
32253 Cope with reduction statements that are vectorized as calls rather
32254 than assignments.
32255 * config/aarch64/aarch64-sve.md (cond_<optab><mode>): New insns.
32256 * config/aarch64/iterators.md (UNSPEC_COND_ADD, UNSPEC_COND_SUB)
32257 (UNSPEC_COND_SMAX, UNSPEC_COND_UMAX, UNSPEC_COND_SMIN)
32258 (UNSPEC_COND_UMIN, UNSPEC_COND_AND, UNSPEC_COND_ORR)
32259 (UNSPEC_COND_EOR): New unspecs.
32260 (optab): Add mappings for them.
32261 (SVE_COND_INT_OP, SVE_COND_FP_OP): New int iterators.
32262 (sve_int_op, sve_fp_op): New int attributes.
32263
32264 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32265 Alan Hayward <alan.hayward@arm.com>
32266 David Sherwood <david.sherwood@arm.com>
32267
32268 * optabs.def (while_ult_optab): New optab.
32269 * doc/md.texi (while_ult@var{m}@var{n}): Document.
32270 * internal-fn.def (WHILE_ULT): New internal function.
32271 * internal-fn.h (direct_internal_fn_supported_p): New override
32272 that takes two types as argument.
32273 * internal-fn.c (while_direct): New macro.
32274 (expand_while_optab_fn): New function.
32275 (convert_optab_supported_p): Likewise.
32276 (direct_while_optab_supported_p): New macro.
32277 * wide-int.h (wi::udiv_ceil): New function.
32278 * tree-vectorizer.h (rgroup_masks): New structure.
32279 (vec_loop_masks): New typedef.
32280 (_loop_vec_info): Add masks, mask_compare_type, can_fully_mask_p
32281 and fully_masked_p.
32282 (LOOP_VINFO_CAN_FULLY_MASK_P, LOOP_VINFO_FULLY_MASKED_P)
32283 (LOOP_VINFO_MASKS, LOOP_VINFO_MASK_COMPARE_TYPE): New macros.
32284 (vect_max_vf): New function.
32285 (slpeel_make_loop_iterate_ntimes): Delete.
32286 (vect_set_loop_condition, vect_get_loop_mask_type, vect_gen_while)
32287 (vect_halve_mask_nunits, vect_double_mask_nunits): Declare.
32288 (vect_record_loop_mask, vect_get_loop_mask): Likewise.
32289 * tree-vect-loop-manip.c: Include tree-ssa-loop-niter.h,
32290 internal-fn.h, stor-layout.h and optabs-query.h.
32291 (vect_set_loop_mask): New function.
32292 (add_preheader_seq): Likewise.
32293 (add_header_seq): Likewise.
32294 (interleave_supported_p): Likewise.
32295 (vect_maybe_permute_loop_masks): Likewise.
32296 (vect_set_loop_masks_directly): Likewise.
32297 (vect_set_loop_condition_masked): Likewise.
32298 (vect_set_loop_condition_unmasked): New function, split out from
32299 slpeel_make_loop_iterate_ntimes.
32300 (slpeel_make_loop_iterate_ntimes): Rename to..
32301 (vect_set_loop_condition): ...this. Use vect_set_loop_condition_masked
32302 for fully-masked loops and vect_set_loop_condition_unmasked otherwise.
32303 (vect_do_peeling): Update call accordingly.
32304 (vect_gen_vector_loop_niters): Use VF as the step for fully-masked
32305 loops.
32306 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Initialize
32307 mask_compare_type, can_fully_mask_p and fully_masked_p.
32308 (release_vec_loop_masks): New function.
32309 (_loop_vec_info): Use it to free the loop masks.
32310 (can_produce_all_loop_masks_p): New function.
32311 (vect_get_max_nscalars_per_iter): Likewise.
32312 (vect_verify_full_masking): Likewise.
32313 (vect_analyze_loop_2): Save LOOP_VINFO_CAN_FULLY_MASK_P around
32314 retries, and free the mask rgroups before retrying. Check loop-wide
32315 reasons for disallowing fully-masked loops. Make the final decision
32316 about whether use a fully-masked loop or not.
32317 (vect_estimate_min_profitable_iters): Do not assume that peeling
32318 for the number of iterations will be needed for fully-masked loops.
32319 (vectorizable_reduction): Disable fully-masked loops.
32320 (vectorizable_live_operation): Likewise.
32321 (vect_halve_mask_nunits): New function.
32322 (vect_double_mask_nunits): Likewise.
32323 (vect_record_loop_mask): Likewise.
32324 (vect_get_loop_mask): Likewise.
32325 (vect_transform_loop): Handle the case in which the final loop
32326 iteration might handle a partial vector. Call vect_set_loop_condition
32327 instead of slpeel_make_loop_iterate_ntimes.
32328 * tree-vect-stmts.c: Include tree-ssa-loop-niter.h and gimple-fold.h.
32329 (check_load_store_masking): New function.
32330 (prepare_load_store_mask): Likewise.
32331 (vectorizable_store): Handle fully-masked loops.
32332 (vectorizable_load): Likewise.
32333 (supportable_widening_operation): Use vect_halve_mask_nunits for
32334 booleans.
32335 (supportable_narrowing_operation): Likewise vect_double_mask_nunits.
32336 (vect_gen_while): New function.
32337 * config/aarch64/aarch64.md (umax<mode>3): New expander.
32338 (aarch64_uqdec<mode>): New insn.
32339
32340 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32341 Alan Hayward <alan.hayward@arm.com>
32342 David Sherwood <david.sherwood@arm.com>
32343
32344 * optabs.def (reduc_and_scal_optab, reduc_ior_scal_optab)
32345 (reduc_xor_scal_optab): New optabs.
32346 * doc/md.texi (reduc_and_scal_@var{m}, reduc_ior_scal_@var{m})
32347 (reduc_xor_scal_@var{m}): Document.
32348 * doc/sourcebuild.texi (vect_logical_reduc): Likewise.
32349 * internal-fn.def (IFN_REDUC_AND, IFN_REDUC_IOR, IFN_REDUC_XOR): New
32350 internal functions.
32351 * fold-const-call.c (fold_const_call): Handle them.
32352 * tree-vect-loop.c (reduction_fn_for_scalar_code): Return the new
32353 internal functions for BIT_AND_EXPR, BIT_IOR_EXPR and BIT_XOR_EXPR.
32354 * config/aarch64/aarch64-sve.md (reduc_<bit_reduc>_scal_<mode>):
32355 (*reduc_<bit_reduc>_scal_<mode>): New patterns.
32356 * config/aarch64/iterators.md (UNSPEC_ANDV, UNSPEC_ORV)
32357 (UNSPEC_XORV): New unspecs.
32358 (optab): Add entries for them.
32359 (BITWISEV): New int iterator.
32360 (bit_reduc_op): New int attributes.
32361
32362 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32363 Alan Hayward <alan.hayward@arm.com>
32364 David Sherwood <david.sherwood@arm.com>
32365
32366 * doc/md.texi (vec_shl_insert_@var{m}): New optab.
32367 * internal-fn.def (VEC_SHL_INSERT): New internal function.
32368 * optabs.def (vec_shl_insert_optab): New optab.
32369 * tree-vectorizer.h (can_duplicate_and_interleave_p): Declare.
32370 (duplicate_and_interleave): Likewise.
32371 * tree-vect-loop.c: Include internal-fn.h.
32372 (neutral_op_for_slp_reduction): New function, split out from
32373 get_initial_defs_for_reduction.
32374 (get_initial_def_for_reduction): Handle option 2 for variable-length
32375 vectors by loading the neutral value into a vector and then shifting
32376 the initial value into element 0.
32377 (get_initial_defs_for_reduction): Replace the code argument with
32378 the neutral value calculated by neutral_op_for_slp_reduction.
32379 Use gimple_build_vector for constant-length vectors.
32380 Use IFN_VEC_SHL_INSERT for variable-length vectors if all
32381 but the first group_size elements have a neutral value.
32382 Use duplicate_and_interleave otherwise.
32383 (vect_create_epilog_for_reduction): Take a neutral_op parameter.
32384 Update call to get_initial_defs_for_reduction. Handle SLP
32385 reductions for variable-length vectors by creating one vector
32386 result for each scalar result, with the elements associated
32387 with other scalar results stubbed out with the neutral value.
32388 (vectorizable_reduction): Call neutral_op_for_slp_reduction.
32389 Require IFN_VEC_SHL_INSERT for double reductions on
32390 variable-length vectors, or SLP reductions that have
32391 a neutral value. Require can_duplicate_and_interleave_p
32392 support for variable-length unchained SLP reductions if there
32393 is no neutral value, such as for MIN/MAX reductions. Also require
32394 the number of vector elements to be a multiple of the number of
32395 SLP statements when doing variable-length unchained SLP reductions.
32396 Update call to vect_create_epilog_for_reduction.
32397 * tree-vect-slp.c (can_duplicate_and_interleave_p): Make public
32398 and remove initial values.
32399 (duplicate_and_interleave): Make public.
32400 * config/aarch64/aarch64.md (UNSPEC_INSR): New unspec.
32401 * config/aarch64/aarch64-sve.md (vec_shl_insert_<mode>): New insn.
32402
32403 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32404 Alan Hayward <alan.hayward@arm.com>
32405 David Sherwood <david.sherwood@arm.com>
32406
32407 * tree-vect-slp.c: Include gimple-fold.h and internal-fn.h
32408 (can_duplicate_and_interleave_p): New function.
32409 (vect_get_and_check_slp_defs): Take the vector of statements
32410 rather than just the current one. Remove excess parentheses.
32411 Restriction rejectinon of vect_constant_def and vect_external_def
32412 for variable-length vectors to boolean types, or types for which
32413 can_duplicate_and_interleave_p is false.
32414 (vect_build_slp_tree_2): Update call to vect_get_and_check_slp_defs.
32415 (duplicate_and_interleave): New function.
32416 (vect_get_constant_vectors): Use gimple_build_vector for
32417 constant-length vectors and suitable variable-length constant
32418 vectors. Use duplicate_and_interleave for other variable-length
32419 vectors. Don't defer the update when inserting new statements.
32420
32421 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32422 Alan Hayward <alan.hayward@arm.com>
32423 David Sherwood <david.sherwood@arm.com>
32424
32425 * tree-vect-loop.c (vect_estimate_min_profitable_iters): Make sure
32426 min_profitable_iters doesn't go negative.
32427
32428 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32429 Alan Hayward <alan.hayward@arm.com>
32430 David Sherwood <david.sherwood@arm.com>
32431
32432 * doc/md.texi (vec_mask_load_lanes@var{m}@var{n}): Document.
32433 (vec_mask_store_lanes@var{m}@var{n}): Likewise.
32434 * optabs.def (vec_mask_load_lanes_optab): New optab.
32435 (vec_mask_store_lanes_optab): Likewise.
32436 * internal-fn.def (MASK_LOAD_LANES): New internal function.
32437 (MASK_STORE_LANES): Likewise.
32438 * internal-fn.c (mask_load_lanes_direct): New macro.
32439 (mask_store_lanes_direct): Likewise.
32440 (expand_mask_load_optab_fn): Handle masked operations.
32441 (expand_mask_load_lanes_optab_fn): New macro.
32442 (expand_mask_store_optab_fn): Handle masked operations.
32443 (expand_mask_store_lanes_optab_fn): New macro.
32444 (direct_mask_load_lanes_optab_supported_p): Likewise.
32445 (direct_mask_store_lanes_optab_supported_p): Likewise.
32446 * tree-vectorizer.h (vect_store_lanes_supported): Take a masked_p
32447 parameter.
32448 (vect_load_lanes_supported): Likewise.
32449 * tree-vect-data-refs.c (strip_conversion): New function.
32450 (can_group_stmts_p): Likewise.
32451 (vect_analyze_data_ref_accesses): Use it instead of checking
32452 for a pair of assignments.
32453 (vect_store_lanes_supported): Take a masked_p parameter.
32454 (vect_load_lanes_supported): Likewise.
32455 * tree-vect-loop.c (vect_analyze_loop_2): Update calls to
32456 vect_store_lanes_supported and vect_load_lanes_supported.
32457 * tree-vect-slp.c (vect_analyze_slp_instance): Likewise.
32458 * tree-vect-stmts.c (get_group_load_store_type): Take a masked_p
32459 parameter. Don't allow gaps for masked accesses.
32460 Use vect_get_store_rhs. Update calls to vect_store_lanes_supported
32461 and vect_load_lanes_supported.
32462 (get_load_store_type): Take a masked_p parameter and update
32463 call to get_group_load_store_type.
32464 (vectorizable_store): Update call to get_load_store_type.
32465 Handle IFN_MASK_STORE_LANES.
32466 (vectorizable_load): Update call to get_load_store_type.
32467 Handle IFN_MASK_LOAD_LANES.
32468
32469 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32470 Alan Hayward <alan.hayward@arm.com>
32471 David Sherwood <david.sherwood@arm.com>
32472
32473 * config/aarch64/aarch64-modes.def: Define x2, x3 and x4 vector
32474 modes for SVE.
32475 * config/aarch64/aarch64-protos.h
32476 (aarch64_sve_struct_memory_operand_p): Declare.
32477 * config/aarch64/iterators.md (SVE_STRUCT): New mode iterator.
32478 (vector_count, insn_length, VSINGLE, vsingle): New mode attributes.
32479 (VPRED, vpred): Handle SVE structure modes.
32480 * config/aarch64/constraints.md (Utx): New constraint.
32481 * config/aarch64/predicates.md (aarch64_sve_struct_memory_operand)
32482 (aarch64_sve_struct_nonimmediate_operand): New predicates.
32483 * config/aarch64/aarch64.md (UNSPEC_LDN, UNSPEC_STN): New unspecs.
32484 * config/aarch64/aarch64-sve.md (mov<mode>, *aarch64_sve_mov<mode>_le)
32485 (*aarch64_sve_mov<mode>_be, pred_mov<mode>): New patterns for
32486 structure modes. Split into pieces after RA.
32487 (vec_load_lanes<mode><vsingle>, vec_mask_load_lanes<mode><vsingle>)
32488 (vec_store_lanes<mode><vsingle>, vec_mask_store_lanes<mode><vsingle>):
32489 New patterns.
32490 * config/aarch64/aarch64.c (aarch64_classify_vector_mode): Handle
32491 SVE structure modes.
32492 (aarch64_classify_address): Likewise.
32493 (sizetochar): Move earlier in file.
32494 (aarch64_print_operand): Handle SVE register lists.
32495 (aarch64_array_mode): New function.
32496 (aarch64_sve_struct_memory_operand_p): Likewise.
32497 (TARGET_ARRAY_MODE): Redefine.
32498
32499 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32500 Alan Hayward <alan.hayward@arm.com>
32501 David Sherwood <david.sherwood@arm.com>
32502
32503 * target.def (array_mode): New target hook.
32504 * doc/tm.texi.in (TARGET_ARRAY_MODE): New hook.
32505 * doc/tm.texi: Regenerate.
32506 * hooks.h (hook_optmode_mode_uhwi_none): Declare.
32507 * hooks.c (hook_optmode_mode_uhwi_none): New function.
32508 * tree-vect-data-refs.c (vect_lanes_optab_supported_p): Use
32509 targetm.array_mode.
32510 * stor-layout.c (mode_for_array): Likewise. Support polynomial
32511 type sizes.
32512
32513 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32514 Alan Hayward <alan.hayward@arm.com>
32515 David Sherwood <david.sherwood@arm.com>
32516
32517 * fold-const.c (fold_binary_loc): Check the argument types
32518 rather than the result type when testing for a vector operation.
32519
32520 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32521
32522 * doc/tm.texi.in (DWARF_LAZY_REGISTER_VALUE): Document.
32523 * doc/tm.texi: Regenerate.
32524
32525 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32526 Alan Hayward <alan.hayward@arm.com>
32527 David Sherwood <david.sherwood@arm.com>
32528
32529 * doc/invoke.texi (-msve-vector-bits=): Document new option.
32530 (sve): Document new AArch64 extension.
32531 * doc/md.texi (w): Extend the description of the AArch64
32532 constraint to include SVE vectors.
32533 (Upl, Upa): Document new AArch64 predicate constraints.
32534 * config/aarch64/aarch64-opts.h (aarch64_sve_vector_bits_enum): New
32535 enum.
32536 * config/aarch64/aarch64.opt (sve_vector_bits): New enum.
32537 (msve-vector-bits=): New option.
32538 * config/aarch64/aarch64-option-extensions.def (fp, simd): Disable
32539 SVE when these are disabled.
32540 (sve): New extension.
32541 * config/aarch64/aarch64-modes.def: Define SVE vector and predicate
32542 modes. Adjust their number of units based on aarch64_sve_vg.
32543 (MAX_BITSIZE_MODE_ANY_MODE): Define.
32544 * config/aarch64/aarch64-protos.h (ADDR_QUERY_ANY): New
32545 aarch64_addr_query_type.
32546 (aarch64_const_vec_all_same_in_range_p, aarch64_sve_pred_mode)
32547 (aarch64_sve_cnt_immediate_p, aarch64_sve_addvl_addpl_immediate_p)
32548 (aarch64_sve_inc_dec_immediate_p, aarch64_add_offset_temporaries)
32549 (aarch64_split_add_offset, aarch64_output_sve_cnt_immediate)
32550 (aarch64_output_sve_addvl_addpl, aarch64_output_sve_inc_dec_immediate)
32551 (aarch64_output_sve_mov_immediate, aarch64_output_ptrue): Declare.
32552 (aarch64_simd_imm_zero_p): Delete.
32553 (aarch64_check_zero_based_sve_index_immediate): Declare.
32554 (aarch64_sve_index_immediate_p, aarch64_sve_arith_immediate_p)
32555 (aarch64_sve_bitmask_immediate_p, aarch64_sve_dup_immediate_p)
32556 (aarch64_sve_cmp_immediate_p, aarch64_sve_float_arith_immediate_p)
32557 (aarch64_sve_float_mul_immediate_p): Likewise.
32558 (aarch64_classify_symbol): Take the offset as a HOST_WIDE_INT
32559 rather than an rtx.
32560 (aarch64_sve_ld1r_operand_p, aarch64_sve_ldr_operand_p): Declare.
32561 (aarch64_expand_mov_immediate): Take a gen_vec_duplicate callback.
32562 (aarch64_emit_sve_pred_move, aarch64_expand_sve_mem_move): Declare.
32563 (aarch64_expand_sve_vec_cmp_int, aarch64_expand_sve_vec_cmp_float)
32564 (aarch64_expand_sve_vcond, aarch64_expand_sve_vec_perm): Declare.
32565 (aarch64_regmode_natural_size): Likewise.
32566 * config/aarch64/aarch64.h (AARCH64_FL_SVE): New macro.
32567 (AARCH64_FL_V8_3, AARCH64_FL_RCPC, AARCH64_FL_DOTPROD): Shift
32568 left one place.
32569 (AARCH64_ISA_SVE, TARGET_SVE): New macros.
32570 (FIXED_REGISTERS, CALL_USED_REGISTERS, REGISTER_NAMES): Add entries
32571 for VG and the SVE predicate registers.
32572 (V_ALIASES): Add a "z"-prefixed alias.
32573 (FIRST_PSEUDO_REGISTER): Change to P15_REGNUM + 1.
32574 (AARCH64_DWARF_VG, AARCH64_DWARF_P0): New macros.
32575 (PR_REGNUM_P, PR_LO_REGNUM_P): Likewise.
32576 (PR_LO_REGS, PR_HI_REGS, PR_REGS): New reg_classes.
32577 (REG_CLASS_NAMES): Add entries for them.
32578 (REG_CLASS_CONTENTS): Likewise. Update ALL_REGS to include VG
32579 and the predicate registers.
32580 (aarch64_sve_vg): Declare.
32581 (BITS_PER_SVE_VECTOR, BYTES_PER_SVE_VECTOR, BYTES_PER_SVE_PRED)
32582 (SVE_BYTE_MODE, MAX_COMPILE_TIME_VEC_BYTES): New macros.
32583 (REGMODE_NATURAL_SIZE): Define.
32584 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins): Handle
32585 SVE macros.
32586 * config/aarch64/aarch64.c: Include cfgrtl.h.
32587 (simd_immediate_info): Add a constructor for series vectors,
32588 and an associated step field.
32589 (aarch64_sve_vg): New variable.
32590 (aarch64_dbx_register_number): Handle VG and the predicate registers.
32591 (aarch64_vect_struct_mode_p, aarch64_vector_mode_p): Delete.
32592 (VEC_ADVSIMD, VEC_SVE_DATA, VEC_SVE_PRED, VEC_STRUCT, VEC_ANY_SVE)
32593 (VEC_ANY_DATA, VEC_STRUCT): New constants.
32594 (aarch64_advsimd_struct_mode_p, aarch64_sve_pred_mode_p)
32595 (aarch64_classify_vector_mode, aarch64_vector_data_mode_p)
32596 (aarch64_sve_data_mode_p, aarch64_sve_pred_mode)
32597 (aarch64_get_mask_mode): New functions.
32598 (aarch64_hard_regno_nregs): Handle SVE data modes for FP_REGS
32599 and FP_LO_REGS. Handle PR_REGS, PR_LO_REGS and PR_HI_REGS.
32600 (aarch64_hard_regno_mode_ok): Handle VG. Also handle the SVE
32601 predicate modes and predicate registers. Explicitly restrict
32602 GPRs to modes of 16 bytes or smaller. Only allow FP registers
32603 to store a vector mode if it is recognized by
32604 aarch64_classify_vector_mode.
32605 (aarch64_regmode_natural_size): New function.
32606 (aarch64_hard_regno_caller_save_mode): Return the original mode
32607 for predicates.
32608 (aarch64_sve_cnt_immediate_p, aarch64_output_sve_cnt_immediate)
32609 (aarch64_sve_addvl_addpl_immediate_p, aarch64_output_sve_addvl_addpl)
32610 (aarch64_sve_inc_dec_immediate_p, aarch64_output_sve_inc_dec_immediate)
32611 (aarch64_add_offset_1_temporaries, aarch64_offset_temporaries): New
32612 functions.
32613 (aarch64_add_offset): Add a temp2 parameter. Assert that temp1
32614 does not overlap dest if the function is frame-related. Handle
32615 SVE constants.
32616 (aarch64_split_add_offset): New function.
32617 (aarch64_add_sp, aarch64_sub_sp): Add temp2 parameters and pass
32618 them aarch64_add_offset.
32619 (aarch64_allocate_and_probe_stack_space): Add a temp2 parameter
32620 and update call to aarch64_sub_sp.
32621 (aarch64_add_cfa_expression): New function.
32622 (aarch64_expand_prologue): Pass extra temporary registers to the
32623 functions above. Handle the case in which we need to emit new
32624 DW_CFA_expressions for registers that were originally saved
32625 relative to the stack pointer, but now have to be expressed
32626 relative to the frame pointer.
32627 (aarch64_output_mi_thunk): Pass extra temporary registers to the
32628 functions above.
32629 (aarch64_expand_epilogue): Likewise. Prevent inheritance of
32630 IP0 and IP1 values for SVE frames.
32631 (aarch64_expand_vec_series): New function.
32632 (aarch64_expand_sve_widened_duplicate): Likewise.
32633 (aarch64_expand_sve_const_vector): Likewise.
32634 (aarch64_expand_mov_immediate): Add a gen_vec_duplicate parameter.
32635 Handle SVE constants. Use emit_move_insn to move a force_const_mem
32636 into the register, rather than emitting a SET directly.
32637 (aarch64_emit_sve_pred_move, aarch64_expand_sve_mem_move)
32638 (aarch64_get_reg_raw_mode, offset_4bit_signed_scaled_p)
32639 (offset_6bit_unsigned_scaled_p, aarch64_offset_7bit_signed_scaled_p)
32640 (offset_9bit_signed_scaled_p): New functions.
32641 (aarch64_replicate_bitmask_imm): New function.
32642 (aarch64_bitmask_imm): Use it.
32643 (aarch64_cannot_force_const_mem): Reject expressions involving
32644 a CONST_POLY_INT. Update call to aarch64_classify_symbol.
32645 (aarch64_classify_index): Handle SVE indices, by requiring
32646 a plain register index with a scale that matches the element size.
32647 (aarch64_classify_address): Handle SVE addresses. Assert that
32648 the mode of the address is VOIDmode or an integer mode.
32649 Update call to aarch64_classify_symbol.
32650 (aarch64_classify_symbolic_expression): Update call to
32651 aarch64_classify_symbol.
32652 (aarch64_const_vec_all_in_range_p): New function.
32653 (aarch64_print_vector_float_operand): Likewise.
32654 (aarch64_print_operand): Handle 'N' and 'C'. Use "zN" rather than
32655 "vN" for FP registers with SVE modes. Handle (const ...) vectors
32656 and the FP immediates 1.0 and 0.5.
32657 (aarch64_print_address_internal): Handle SVE addresses.
32658 (aarch64_print_operand_address): Use ADDR_QUERY_ANY.
32659 (aarch64_regno_regclass): Handle predicate registers.
32660 (aarch64_secondary_reload): Handle big-endian reloads of SVE
32661 data modes.
32662 (aarch64_class_max_nregs): Handle SVE modes and predicate registers.
32663 (aarch64_rtx_costs): Check for ADDVL and ADDPL instructions.
32664 (aarch64_convert_sve_vector_bits): New function.
32665 (aarch64_override_options): Use it to handle -msve-vector-bits=.
32666 (aarch64_classify_symbol): Take the offset as a HOST_WIDE_INT
32667 rather than an rtx.
32668 (aarch64_legitimate_constant_p): Use aarch64_classify_vector_mode.
32669 Handle SVE vector and predicate modes. Accept VL-based constants
32670 that need only one temporary register, and VL offsets that require
32671 no temporary registers.
32672 (aarch64_conditional_register_usage): Mark the predicate registers
32673 as fixed if SVE isn't available.
32674 (aarch64_vector_mode_supported_p): Use aarch64_classify_vector_mode.
32675 Return true for SVE vector and predicate modes.
32676 (aarch64_simd_container_mode): Take the number of bits as a poly_int64
32677 rather than an unsigned int. Handle SVE modes.
32678 (aarch64_preferred_simd_mode): Update call accordingly. Handle
32679 SVE modes.
32680 (aarch64_autovectorize_vector_sizes): Add BYTES_PER_SVE_VECTOR
32681 if SVE is enabled.
32682 (aarch64_sve_index_immediate_p, aarch64_sve_arith_immediate_p)
32683 (aarch64_sve_bitmask_immediate_p, aarch64_sve_dup_immediate_p)
32684 (aarch64_sve_cmp_immediate_p, aarch64_sve_float_arith_immediate_p)
32685 (aarch64_sve_float_mul_immediate_p): New functions.
32686 (aarch64_sve_valid_immediate): New function.
32687 (aarch64_simd_valid_immediate): Use it as the fallback for SVE vectors.
32688 Explicitly reject structure modes. Check for INDEX constants.
32689 Handle PTRUE and PFALSE constants.
32690 (aarch64_check_zero_based_sve_index_immediate): New function.
32691 (aarch64_simd_imm_zero_p): Delete.
32692 (aarch64_mov_operand_p): Use aarch64_simd_valid_immediate for
32693 vector modes. Accept constants in the range of CNT[BHWD].
32694 (aarch64_simd_scalar_immediate_valid_for_move): Explicitly
32695 ask for an Advanced SIMD mode.
32696 (aarch64_sve_ld1r_operand_p, aarch64_sve_ldr_operand_p): New functions.
32697 (aarch64_simd_vector_alignment): Handle SVE predicates.
32698 (aarch64_vectorize_preferred_vector_alignment): New function.
32699 (aarch64_simd_vector_alignment_reachable): Use it instead of
32700 the vector size.
32701 (aarch64_shift_truncation_mask): Use aarch64_vector_data_mode_p.
32702 (aarch64_output_sve_mov_immediate, aarch64_output_ptrue): New
32703 functions.
32704 (MAX_VECT_LEN): Delete.
32705 (expand_vec_perm_d): Add a vec_flags field.
32706 (emit_unspec2, aarch64_expand_sve_vec_perm): New functions.
32707 (aarch64_evpc_trn, aarch64_evpc_uzp, aarch64_evpc_zip)
32708 (aarch64_evpc_ext): Don't apply a big-endian lane correction
32709 for SVE modes.
32710 (aarch64_evpc_rev): Rename to...
32711 (aarch64_evpc_rev_local): ...this. Use a predicated operation for SVE.
32712 (aarch64_evpc_rev_global): New function.
32713 (aarch64_evpc_dup): Enforce a 64-byte range for SVE DUP.
32714 (aarch64_evpc_tbl): Use MAX_COMPILE_TIME_VEC_BYTES instead of
32715 MAX_VECT_LEN.
32716 (aarch64_evpc_sve_tbl): New function.
32717 (aarch64_expand_vec_perm_const_1): Update after rename of
32718 aarch64_evpc_rev. Handle SVE permutes too, trying
32719 aarch64_evpc_rev_global and using aarch64_evpc_sve_tbl rather
32720 than aarch64_evpc_tbl.
32721 (aarch64_vectorize_vec_perm_const): Initialize vec_flags.
32722 (aarch64_sve_cmp_operand_p, aarch64_unspec_cond_code)
32723 (aarch64_gen_unspec_cond, aarch64_expand_sve_vec_cmp_int)
32724 (aarch64_emit_unspec_cond, aarch64_emit_unspec_cond_or)
32725 (aarch64_emit_inverted_unspec_cond, aarch64_expand_sve_vec_cmp_float)
32726 (aarch64_expand_sve_vcond): New functions.
32727 (aarch64_modes_tieable_p): Use aarch64_vector_data_mode_p instead
32728 of aarch64_vector_mode_p.
32729 (aarch64_dwarf_poly_indeterminate_value): New function.
32730 (aarch64_compute_pressure_classes): Likewise.
32731 (aarch64_can_change_mode_class): Likewise.
32732 (TARGET_GET_RAW_RESULT_MODE, TARGET_GET_RAW_ARG_MODE): Redefine.
32733 (TARGET_VECTORIZE_PREFERRED_VECTOR_ALIGNMENT): Likewise.
32734 (TARGET_VECTORIZE_GET_MASK_MODE): Likewise.
32735 (TARGET_DWARF_POLY_INDETERMINATE_VALUE): Likewise.
32736 (TARGET_COMPUTE_PRESSURE_CLASSES): Likewise.
32737 (TARGET_CAN_CHANGE_MODE_CLASS): Likewise.
32738 * config/aarch64/constraints.md (Upa, Upl, Uav, Uat, Usv, Usi, Utr)
32739 (Uty, Dm, vsa, vsc, vsd, vsi, vsn, vsl, vsm, vsA, vsM, vsN): New
32740 constraints.
32741 (Dn, Dl, Dr): Accept const as well as const_vector.
32742 (Dz): Likewise. Compare against CONST0_RTX.
32743 * config/aarch64/iterators.md: Refer to "Advanced SIMD" instead
32744 of "vector" where appropriate.
32745 (SVE_ALL, SVE_BH, SVE_BHS, SVE_BHSI, SVE_HSDI, SVE_HSF, SVE_SD)
32746 (SVE_SDI, SVE_I, SVE_F, PRED_ALL, PRED_BHS): New mode iterators.
32747 (UNSPEC_SEL, UNSPEC_ANDF, UNSPEC_IORF, UNSPEC_XORF, UNSPEC_COND_LT)
32748 (UNSPEC_COND_LE, UNSPEC_COND_EQ, UNSPEC_COND_NE, UNSPEC_COND_GE)
32749 (UNSPEC_COND_GT, UNSPEC_COND_LO, UNSPEC_COND_LS, UNSPEC_COND_HS)
32750 (UNSPEC_COND_HI, UNSPEC_COND_UO): New unspecs.
32751 (Vetype, VEL, Vel, VWIDE, Vwide, vw, vwcore, V_INT_EQUIV)
32752 (v_int_equiv): Extend to SVE modes.
32753 (Vesize, V128, v128, Vewtype, V_FP_EQUIV, v_fp_equiv, VPRED): New
32754 mode attributes.
32755 (LOGICAL_OR, SVE_INT_UNARY, SVE_FP_UNARY): New code iterators.
32756 (optab): Handle popcount, smin, smax, umin, umax, abs and sqrt.
32757 (logical_nn, lr, sve_int_op, sve_fp_op): New code attributs.
32758 (LOGICALF, OPTAB_PERMUTE, UNPACK, UNPACK_UNSIGNED, SVE_COND_INT_CMP)
32759 (SVE_COND_FP_CMP): New int iterators.
32760 (perm_hilo): Handle the new unpack unspecs.
32761 (optab, logicalf_op, su, perm_optab, cmp_op, imm_con): New int
32762 attributes.
32763 * config/aarch64/predicates.md (aarch64_sve_cnt_immediate)
32764 (aarch64_sve_addvl_addpl_immediate, aarch64_split_add_offset_immediate)
32765 (aarch64_pluslong_or_poly_operand, aarch64_nonmemory_operand)
32766 (aarch64_equality_operator, aarch64_constant_vector_operand)
32767 (aarch64_sve_ld1r_operand, aarch64_sve_ldr_operand): New predicates.
32768 (aarch64_sve_nonimmediate_operand): Likewise.
32769 (aarch64_sve_general_operand): Likewise.
32770 (aarch64_sve_dup_operand, aarch64_sve_arith_immediate): Likewise.
32771 (aarch64_sve_sub_arith_immediate, aarch64_sve_inc_dec_immediate)
32772 (aarch64_sve_logical_immediate, aarch64_sve_mul_immediate): Likewise.
32773 (aarch64_sve_dup_immediate, aarch64_sve_cmp_vsc_immediate): Likewise.
32774 (aarch64_sve_cmp_vsd_immediate, aarch64_sve_index_immediate): Likewise.
32775 (aarch64_sve_float_arith_immediate): Likewise.
32776 (aarch64_sve_float_arith_with_sub_immediate): Likewise.
32777 (aarch64_sve_float_mul_immediate, aarch64_sve_arith_operand): Likewise.
32778 (aarch64_sve_add_operand, aarch64_sve_logical_operand): Likewise.
32779 (aarch64_sve_lshift_operand, aarch64_sve_rshift_operand): Likewise.
32780 (aarch64_sve_mul_operand, aarch64_sve_cmp_vsc_operand): Likewise.
32781 (aarch64_sve_cmp_vsd_operand, aarch64_sve_index_operand): Likewise.
32782 (aarch64_sve_float_arith_operand): Likewise.
32783 (aarch64_sve_float_arith_with_sub_operand): Likewise.
32784 (aarch64_sve_float_mul_operand): Likewise.
32785 (aarch64_sve_vec_perm_operand): Likewise.
32786 (aarch64_pluslong_operand): Include aarch64_sve_addvl_addpl_immediate.
32787 (aarch64_mov_operand): Accept const_poly_int and const_vector.
32788 (aarch64_simd_lshift_imm, aarch64_simd_rshift_imm): Accept const
32789 as well as const_vector.
32790 (aarch64_simd_imm_zero, aarch64_simd_imm_minus_one): Move earlier
32791 in file. Use CONST0_RTX and CONSTM1_RTX.
32792 (aarch64_simd_or_scalar_imm_zero): Likewise. Add match_codes.
32793 (aarch64_simd_reg_or_zero): Accept const as well as const_vector.
32794 Use aarch64_simd_imm_zero.
32795 * config/aarch64/aarch64-sve.md: New file.
32796 * config/aarch64/aarch64.md: Include it.
32797 (VG_REGNUM, P0_REGNUM, P7_REGNUM, P15_REGNUM): New register numbers.
32798 (UNSPEC_REV, UNSPEC_LD1_SVE, UNSPEC_ST1_SVE, UNSPEC_MERGE_PTRUE)
32799 (UNSPEC_PTEST_PTRUE, UNSPEC_UNPACKSHI, UNSPEC_UNPACKUHI)
32800 (UNSPEC_UNPACKSLO, UNSPEC_UNPACKULO, UNSPEC_PACK)
32801 (UNSPEC_FLOAT_CONVERT, UNSPEC_WHILE_LO): New unspec constants.
32802 (sve): New attribute.
32803 (enabled): Disable instructions with the sve attribute unless
32804 TARGET_SVE.
32805 (movqi, movhi): Pass CONST_POLY_INT operaneds through
32806 aarch64_expand_mov_immediate.
32807 (*mov<mode>_aarch64, *movsi_aarch64, *movdi_aarch64): Handle
32808 CNT[BHSD] immediates.
32809 (movti): Split CONST_POLY_INT moves into two halves.
32810 (add<mode>3): Accept aarch64_pluslong_or_poly_operand.
32811 Split additions that need a temporary here if the destination
32812 is the stack pointer.
32813 (*add<mode>3_aarch64): Handle ADDVL and ADDPL immediates.
32814 (*add<mode>3_poly_1): New instruction.
32815 (set_clobber_cc): New expander.
32816
32817 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32818
32819 * simplify-rtx.c (simplify_immed_subreg): Add an inner_bytes
32820 parameter and use it instead of GET_MODE_SIZE (innermode). Use
32821 inner_bytes * BITS_PER_UNIT instead of GET_MODE_BITSIZE (innermode).
32822 Use CEIL (inner_bytes, GET_MODE_UNIT_SIZE (innermode)) instead of
32823 GET_MODE_NUNITS (innermode). Also add a first_elem parameter.
32824 Change innermode from fixed_mode_size to machine_mode.
32825 (simplify_subreg): Update call accordingly. Handle a constant-sized
32826 subreg of a variable-length CONST_VECTOR.
32827
32828 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32829 Alan Hayward <alan.hayward@arm.com>
32830 David Sherwood <david.sherwood@arm.com>
32831
32832 * tree-ssa-address.c (mem_ref_valid_without_offset_p): New function.
32833 (add_offset_to_base): New function, split out from...
32834 (create_mem_ref): ...here. When handling a scale other than 1,
32835 check first whether the address is valid without the offset.
32836 Add it into the base if so, leaving the index and scale as-is.
32837
32838 2018-01-12 Jakub Jelinek <jakub@redhat.com>
32839
32840 PR c++/83778
32841 * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin): Call
32842 fold_for_warn before checking if arg2 is INTEGER_CST.
32843
32844 2018-01-12 Segher Boessenkool <segher@kernel.crashing.org>
32845
32846 * config/rs6000/predicates.md (load_multiple_operation): Delete.
32847 (store_multiple_operation): Delete.
32848 * config/rs6000/rs6000-cpus.def (601): Remove MASK_STRING.
32849 * config/rs6000/rs6000-protos.h (rs6000_output_load_multiple): Delete.
32850 * config/rs6000/rs6000-string.c (expand_block_move): Delete everything
32851 guarded by TARGET_STRING.
32852 (rs6000_output_load_multiple): Delete.
32853 * config/rs6000/rs6000.c (rs6000_option_override_internal): Delete
32854 OPTION_MASK_STRING / TARGET_STRING handling.
32855 (print_operand) <'N', 'O'>: Add comment that these are unused now.
32856 (const rs6000_opt_masks) <"string">: Change mask to 0.
32857 * config/rs6000/rs6000.h (TARGET_DEFAULT): Remove MASK_STRING.
32858 (MASK_STRING): Delete.
32859 * config/rs6000/rs6000.md (*mov<mode>_string): Delete TARGET_STRING
32860 parts. Simplify.
32861 (load_multiple): Delete.
32862 (*ldmsi8): Delete.
32863 (*ldmsi7): Delete.
32864 (*ldmsi6): Delete.
32865 (*ldmsi5): Delete.
32866 (*ldmsi4): Delete.
32867 (*ldmsi3): Delete.
32868 (store_multiple): Delete.
32869 (*stmsi8): Delete.
32870 (*stmsi7): Delete.
32871 (*stmsi6): Delete.
32872 (*stmsi5): Delete.
32873 (*stmsi4): Delete.
32874 (*stmsi3): Delete.
32875 (movmemsi_8reg): Delete.
32876 (corresponding unnamed define_insn): Delete.
32877 (movmemsi_6reg): Delete.
32878 (corresponding unnamed define_insn): Delete.
32879 (movmemsi_4reg): Delete.
32880 (corresponding unnamed define_insn): Delete.
32881 (movmemsi_2reg): Delete.
32882 (corresponding unnamed define_insn): Delete.
32883 (movmemsi_1reg): Delete.
32884 (corresponding unnamed define_insn): Delete.
32885 * config/rs6000/rs6000.opt (mno-string): New.
32886 (mstring): Replace by deprecation warning stub.
32887 * doc/invoke.texi (RS/6000 and PowerPC Options): Delete -mstring.
32888
32889 2018-01-12 Jakub Jelinek <jakub@redhat.com>
32890
32891 * regrename.c (regrename_do_replace): If replacing the same
32892 reg multiple times, try to reuse last created gen_raw_REG.
32893
32894 PR debug/81155
32895 * bb-reorder.c (pass_partition_blocks::gate): In lto don't partition
32896 main to workaround a bug in GDB.
32897
32898 2018-01-12 Tom de Vries <tom@codesourcery.com>
32899
32900 PR target/83737
32901 * config.gcc (nvptx*-*-*): Set use_gcc_stdint=wrap.
32902
32903 2018-01-12 Vladimir Makarov <vmakarov@redhat.com>
32904
32905 PR rtl-optimization/80481
32906 * ira-color.c (get_cap_member): New function.
32907 (allocnos_conflict_by_live_ranges_p): Use it.
32908 (slot_coalesced_allocno_live_ranges_intersect_p): Add assert.
32909 (setup_slot_coalesced_allocno_live_ranges): Ditto.
32910
32911 2018-01-12 Uros Bizjak <ubizjak@gmail.com>
32912
32913 PR target/83628
32914 * config/alpha/alpha.md (*saddsi_1): New insn_ans_split pattern.
32915 (*saddl_se_1): Ditto.
32916 (*ssubsi_1): Ditto.
32917 (*ssubl_se_1): Ditto.
32918
32919 2018-01-12 Richard Sandiford <richard.sandiford@linaro.org>
32920
32921 * tree-predcom.c (aff_combination_dr_offset): Use wi::to_poly_widest
32922 rather than wi::to_widest for DR_INITs.
32923 * tree-vect-data-refs.c (vect_find_same_alignment_drs): Use
32924 wi::to_poly_offset rather than wi::to_offset for DR_INIT.
32925 (vect_analyze_data_ref_accesses): Require both DR_INITs to be
32926 INTEGER_CSTs.
32927 (vect_analyze_group_access_1): Note that here.
32928
32929 2018-01-12 Richard Sandiford <richard.sandiford@linaro.org>
32930
32931 * tree-vectorizer.c (get_vec_alignment_for_array_type): Handle
32932 polynomial type sizes.
32933
32934 2018-01-12 Richard Sandiford <richard.sandiford@linaro.org>
32935
32936 * gimplify.c (gimple_add_tmp_var_fn): Allow variables to have a
32937 poly_uint64 size, rather than requiring an unsigned HOST_WIDE_INT size.
32938 (gimple_add_tmp_var): Likewise.
32939
32940 2018-01-12 Martin Liska <mliska@suse.cz>
32941
32942 * gimple.c (gimple_alloc_counts): Use uint64_t instead of int.
32943 (gimple_alloc_sizes): Likewise.
32944 (dump_gimple_statistics): Use PRIu64 in printf format.
32945 * gimple.h: Change uint64_t to int.
32946
32947 2018-01-12 Martin Liska <mliska@suse.cz>
32948
32949 * tree-core.h: Use uint64_t instead of int.
32950 * tree.c (tree_node_counts): Likewise.
32951 (tree_node_sizes): Likewise.
32952 (dump_tree_statistics): Use PRIu64 in printf format.
32953
32954 2018-01-12 Martin Liska <mliska@suse.cz>
32955
32956 * Makefile.in: As qsort_chk is implemented in vec.c, add
32957 vec.o to linkage of gencfn-macros.
32958 * tree.c (build_new_poly_int_cst): Add CXX_MEM_STAT_INFO as it's
32959 passing the info to record_node_allocation_statistics.
32960 (test_vector_cst_patterns): Add CXX_MEM_STAT_INFO to declaration
32961 and pass the info.
32962 * ggc-common.c (struct ggc_usage): Add operator== and use
32963 it in operator< and compare function.
32964 * mem-stats.h (struct mem_usage): Likewise.
32965 * vec.c (struct vec_usage): Remove operator< and compare
32966 function. Can be simply inherited.
32967
32968 2018-01-12 Martin Jambor <mjambor@suse.cz>
32969
32970 PR target/81616
32971 * params.def: New parameter PARAM_AVOID_FMA_MAX_BITS.
32972 * tree-ssa-math-opts.c: Include domwalk.h.
32973 (convert_mult_to_fma_1): New function.
32974 (fma_transformation_info): New type.
32975 (fma_deferring_state): Likewise.
32976 (cancel_fma_deferring): New function.
32977 (result_of_phi): Likewise.
32978 (last_fma_candidate_feeds_initial_phi): Likewise.
32979 (convert_mult_to_fma): Added deferring logic, split actual
32980 transformation to convert_mult_to_fma_1.
32981 (math_opts_dom_walker): New type.
32982 (math_opts_dom_walker::after_dom_children): New method, body moved
32983 here from pass_optimize_widening_mul::execute, added deferring logic
32984 bits.
32985 (pass_optimize_widening_mul::execute): Moved most of code to
32986 math_opts_dom_walker::after_dom_children.
32987 * config/i386/x86-tune.def (X86_TUNE_AVOID_128FMA_CHAINS): New.
32988 * config/i386/i386.c (ix86_option_override_internal): Added
32989 maybe_setting of PARAM_AVOID_FMA_MAX_BITS.
32990
32991 2018-01-12 Richard Biener <rguenther@suse.de>
32992
32993 PR debug/83157
32994 * dwarf2out.c (gen_variable_die): Do not reset old_die for
32995 inline instance vars.
32996
32997 2018-01-12 Oleg Endo <olegendo@gcc.gnu.org>
32998
32999 PR target/81819
33000 * config/rx/rx.c (rx_is_restricted_memory_address):
33001 Handle SUBREG case.
33002
33003 2018-01-12 Richard Biener <rguenther@suse.de>
33004
33005 PR tree-optimization/80846
33006 * target.def (split_reduction): New target hook.
33007 * targhooks.c (default_split_reduction): New function.
33008 * targhooks.h (default_split_reduction): Declare.
33009 * tree-vect-loop.c (vect_create_epilog_for_reduction): If the
33010 target requests first reduce vectors by combining low and high
33011 parts.
33012 * tree-vect-stmts.c (vect_gen_perm_mask_any): Adjust.
33013 (get_vectype_for_scalar_type_and_size): Export.
33014 * tree-vectorizer.h (get_vectype_for_scalar_type_and_size): Declare.
33015 * doc/tm.texi.in (TARGET_VECTORIZE_SPLIT_REDUCTION): Document.
33016 * doc/tm.texi: Regenerate.
33017 * config/i386/i386.c (ix86_split_reduction): Implement
33018 TARGET_VECTORIZE_SPLIT_REDUCTION.
33019
33020 2018-01-12 Eric Botcazou <ebotcazou@adacore.com>
33021
33022 PR target/83368
33023 * config/sparc/sparc.h (PIC_OFFSET_TABLE_REGNUM): Set to INVALID_REGNUM
33024 in PIC mode except for TARGET_VXWORKS_RTP.
33025 * config/sparc/sparc.c: Include cfgrtl.h.
33026 (TARGET_INIT_PIC_REG): Define.
33027 (TARGET_USE_PSEUDO_PIC_REG): Likewise.
33028 (sparc_pic_register_p): New predicate.
33029 (sparc_legitimate_address_p): Use it.
33030 (sparc_legitimize_pic_address): Likewise.
33031 (sparc_delegitimize_address): Likewise.
33032 (sparc_mode_dependent_address_p): Likewise.
33033 (gen_load_pcrel_sym): Remove 4th parameter.
33034 (load_got_register): Adjust call to above. Remove obsolete stuff.
33035 (sparc_expand_prologue): Do not call load_got_register here.
33036 (sparc_flat_expand_prologue): Likewise.
33037 (sparc_output_mi_thunk): Set the pic_offset_table_rtx object.
33038 (sparc_use_pseudo_pic_reg): New function.
33039 (sparc_init_pic_reg): Likewise.
33040 * config/sparc/sparc.md (vxworks_load_got): Set the GOT register.
33041 (builtin_setjmp_receiver): Enable only for TARGET_VXWORKS_RTP.
33042
33043 2018-01-12 Christophe Lyon <christophe.lyon@linaro.org>
33044
33045 * doc/sourcebuild.texi (Effective-Target Keywords, Other attributes):
33046 Add item for branch_cost.
33047
33048 2018-01-12 Eric Botcazou <ebotcazou@adacore.com>
33049
33050 PR rtl-optimization/83565
33051 * rtlanal.c (nonzero_bits1): On WORD_REGISTER_OPERATIONS machines, do
33052 not extend the result to a larger mode for rotate operations.
33053 (num_sign_bit_copies1): Likewise.
33054
33055 2018-01-12 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
33056
33057 PR target/40411
33058 * config/sol2.h (STARTFILE_ARCH_SPEC): Don't use with -shared or
33059 -symbolic.
33060 Use values-Xc.o for -pedantic.
33061 Link with values-xpg4.o for C90, values-xpg6.o otherwise.
33062
33063 2018-01-12 Martin Liska <mliska@suse.cz>
33064
33065 PR ipa/83054
33066 * ipa-devirt.c (final_warning_record::grow_type_warnings):
33067 New function.
33068 (possible_polymorphic_call_targets): Use it.
33069 (ipa_devirt): Likewise.
33070
33071 2018-01-12 Martin Liska <mliska@suse.cz>
33072
33073 * profile-count.h (enum profile_quality): Use 0 as invalid
33074 enum value of profile_quality.
33075
33076 2018-01-12 Chung-Ju Wu <jasonwucj@gmail.com>
33077
33078 * doc/invoke.texi (NDS32 Options): Add -mext-perf, -mext-perf2 and
33079 -mext-string options.
33080
33081 2018-01-12 Richard Biener <rguenther@suse.de>
33082
33083 * lto-streamer-out.c (DFS::DFS_write_tree_body): Process
33084 DECL_DEBUG_EXPR conditional on DECL_HAS_DEBUG_EXPR_P.
33085 * tree-streamer-in.c (lto_input_ts_decl_common_tree_pointers):
33086 Likewise.
33087 * tree-streamer-out.c (write_ts_decl_common_tree_pointers): Likewise.
33088
33089 2018-01-11 Michael Meissner <meissner@linux.vnet.ibm.com>
33090
33091 * configure.ac (--with-long-double-format): Add support for the
33092 configuration option to change the default long double format on
33093 PowerPC systems.
33094 * config.gcc (powerpc*-linux*-*): Likewise.
33095 * configure: Regenerate.
33096 * config/rs6000/rs6000-c.c (rs6000_cpu_cpp_builtins): If long
33097 double is IEEE, define __KC__ and __KF__ to allow floatn.h to be
33098 used without modification.
33099
33100 2018-01-11 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
33101
33102 * config/rs6000/rs6000-builtin.def (BU_P7_MISC_X): New #define.
33103 (SPEC_BARRIER): New instantiation of BU_P7_MISC_X.
33104 * config/rs6000/rs6000.c (rs6000_expand_builtin): Handle
33105 MISC_BUILTIN_SPEC_BARRIER.
33106 (rs6000_init_builtins): Likewise.
33107 * config/rs6000/rs6000.md (UNSPECV_SPEC_BARRIER): New UNSPECV
33108 enum value.
33109 (speculation_barrier): New define_insn.
33110 * doc/extend.texi: Document __builtin_speculation_barrier.
33111
33112 2018-01-11 Jakub Jelinek <jakub@redhat.com>
33113
33114 PR target/83203
33115 * config/i386/i386.c (ix86_expand_vector_init_one_nonzero): If one_var
33116 is 0, for V{8,16}S[IF] and V[48]D[IF]mode use gen_vec_set<mode>_0.
33117 * config/i386/sse.md (VI8_AVX_AVX512F, VI4F_256_512): New mode
33118 iterators.
33119 (ssescalarmodesuffix): Add 512-bit vectors. Use "d" or "q" for
33120 integral modes instead of "ss" and "sd".
33121 (vec_set<mode>_0): New define_insns for 256-bit and 512-bit
33122 vectors with 32-bit and 64-bit elements.
33123 (vecdupssescalarmodesuffix): New mode attribute.
33124 (vec_dup<mode>): Use it.
33125
33126 2018-01-11 H.J. Lu <hongjiu.lu@intel.com>
33127
33128 PR target/83330
33129 * config/i386/i386.c (ix86_compute_frame_layout): Align stack
33130 frame if argument is passed on stack.
33131
33132 2018-01-11 Jakub Jelinek <jakub@redhat.com>
33133
33134 PR target/82682
33135 * ree.c (combine_reaching_defs): Optimize also
33136 reg2=exp; reg1=reg2; reg2=any_extend(reg1); into
33137 reg2=any_extend(exp); reg1=reg2;, formatting fix.
33138
33139 2018-01-11 Jan Hubicka <hubicka@ucw.cz>
33140
33141 PR middle-end/83189
33142 * gimple-ssa-isolate-paths.c (isolate_path): Fix profile update.
33143
33144 2018-01-11 Jan Hubicka <hubicka@ucw.cz>
33145
33146 PR middle-end/83718
33147 * tree-inline.c (copy_cfg_body): Adjust num&den for scaling
33148 after they are computed.
33149
33150 2018-01-11 Bin Cheng <bin.cheng@arm.com>
33151
33152 PR tree-optimization/83695
33153 * gimple-loop-linterchange.cc
33154 (tree_loop_interchange::interchange_loops): Call scev_reset_htab to
33155 reset cached scev information after interchange.
33156 (pass_linterchange::execute): Remove call to scev_reset_htab.
33157
33158 2018-01-11 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
33159
33160 * config/arm/arm_neon.h (vfmlal_lane_low_u32, vfmlal_lane_high_u32,
33161 vfmlalq_laneq_low_u32, vfmlalq_lane_low_u32, vfmlal_laneq_low_u32,
33162 vfmlalq_laneq_high_u32, vfmlalq_lane_high_u32, vfmlal_laneq_high_u32,
33163 vfmlsl_lane_low_u32, vfmlsl_lane_high_u32, vfmlslq_laneq_low_u32,
33164 vfmlslq_lane_low_u32, vfmlsl_laneq_low_u32, vfmlslq_laneq_high_u32,
33165 vfmlslq_lane_high_u32, vfmlsl_laneq_high_u32): Define.
33166 * config/arm/arm_neon_builtins.def (vfmal_lane_low,
33167 vfmal_lane_lowv4hf, vfmal_lane_lowv8hf, vfmal_lane_high,
33168 vfmal_lane_highv4hf, vfmal_lane_highv8hf, vfmsl_lane_low,
33169 vfmsl_lane_lowv4hf, vfmsl_lane_lowv8hf, vfmsl_lane_high,
33170 vfmsl_lane_highv4hf, vfmsl_lane_highv8hf): New sets of builtins.
33171 * config/arm/iterators.md (VFMLSEL2, vfmlsel2): New mode attributes.
33172 (V_lane_reg): Likewise.
33173 * config/arm/neon.md (neon_vfm<vfml_op>l_lane_<vfml_half><VCVTF:mode>):
33174 New define_expand.
33175 (neon_vfm<vfml_op>l_lane_<vfml_half><vfmlsel2><mode>): Likewise.
33176 (vfmal_lane_low<mode>_intrinsic,
33177 vfmal_lane_low<vfmlsel2><mode>_intrinsic,
33178 vfmal_lane_high<vfmlsel2><mode>_intrinsic,
33179 vfmal_lane_high<mode>_intrinsic, vfmsl_lane_low<mode>_intrinsic,
33180 vfmsl_lane_low<vfmlsel2><mode>_intrinsic,
33181 vfmsl_lane_high<vfmlsel2><mode>_intrinsic,
33182 vfmsl_lane_high<mode>_intrinsic): New define_insns.
33183
33184 2018-01-11 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
33185
33186 * config/arm/arm-cpus.in (fp16fml): New feature.
33187 (ALL_SIMD): Add fp16fml.
33188 (armv8.2-a): Add fp16fml as an option.
33189 (armv8.3-a): Likewise.
33190 (armv8.4-a): Add fp16fml as part of fp16.
33191 * config/arm/arm.h (TARGET_FP16FML): Define.
33192 * config/arm/arm-c.c (arm_cpu_builtins): Define __ARM_FEATURE_FP16_FML
33193 when appropriate.
33194 * config/arm/arm-modes.def (V2HF): Define.
33195 * config/arm/arm_neon.h (vfmlal_low_u32, vfmlsl_low_u32,
33196 vfmlal_high_u32, vfmlsl_high_u32, vfmlalq_low_u32,
33197 vfmlslq_low_u32, vfmlalq_high_u32, vfmlslq_high_u32): Define.
33198 * config/arm/arm_neon_builtins.def (vfmal_low, vfmal_high,
33199 vfmsl_low, vfmsl_high): New set of builtins.
33200 * config/arm/iterators.md (PLUSMINUS): New code iterator.
33201 (vfml_op): New code attribute.
33202 (VFMLHALVES): New int iterator.
33203 (VFML, VFMLSEL): New mode attributes.
33204 (V_reg): Define mapping for V2HF.
33205 (V_hi, V_lo): New mode attributes.
33206 (VF_constraint): Likewise.
33207 (vfml_half, vfml_half_selector): New int attributes.
33208 * config/arm/neon.md (neon_vfm<vfml_op>l_<vfml_half><mode>): New
33209 define_expand.
33210 (vfmal_low<mode>_intrinsic, vfmsl_high<mode>_intrinsic,
33211 vfmal_high<mode>_intrinsic, vfmsl_low<mode>_intrinsic):
33212 New define_insn.
33213 * config/arm/t-arm-elf (v8_fps): Add fp16fml.
33214 * config/arm/t-multilib (v8_2_a_simd_variants): Add fp16fml.
33215 * config/arm/unspecs.md (UNSPEC_VFML_LO, UNSPEC_VFML_HI): New unspecs.
33216 * doc/invoke.texi (ARM Options): Document fp16fml. Update armv8.4-a
33217 documentation.
33218 * doc/sourcebuild.texi (arm_fp16fml_neon_ok, arm_fp16fml_neon):
33219 Document new effective target and option set.
33220
33221 2018-01-11 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
33222
33223 * config/arm/arm-cpus.in (armv8_4): New feature.
33224 (ARMv8_4a): New fgroup.
33225 (armv8.4-a): New arch.
33226 * config/arm/arm-tables.opt: Regenerate.
33227 * config/arm/t-aprofile: Add matching rules for -march=armv8.4-a.
33228 * config/arm/t-arm-elf (all_v8_archs): Add armv8.4-a.
33229 * config/arm/t-multilib (v8_4_a_simd_variants): New variable.
33230 Add matching rules for -march=armv8.4-a and extensions.
33231 * doc/invoke.texi (ARM Options): Document -march=armv8.4-a.
33232
33233 2018-01-11 Oleg Endo <olegendo@gcc.gnu.org>
33234
33235 PR target/81821
33236 * config/rx/rx.md (BW): New mode attribute.
33237 (sync_lock_test_and_setsi): Add mode suffix to insn output.
33238
33239 2018-01-11 Richard Biener <rguenther@suse.de>
33240
33241 PR tree-optimization/83435
33242 * graphite.c (canonicalize_loop_form): Ignore fake loop exit edges.
33243 * graphite-scop-detection.c (scop_detection::get_sese): Likewise.
33244 * tree-vrp.c (add_assert_info): Drop TREE_OVERFLOW if they appear.
33245
33246 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
33247 Alan Hayward <alan.hayward@arm.com>
33248 David Sherwood <david.sherwood@arm.com>
33249
33250 * config/aarch64/aarch64.c (aarch64_address_info): Add a const_offset
33251 field.
33252 (aarch64_classify_address): Initialize it. Track polynomial offsets.
33253 (aarch64_print_address_internal): Use it to check for a zero offset.
33254
33255 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
33256 Alan Hayward <alan.hayward@arm.com>
33257 David Sherwood <david.sherwood@arm.com>
33258
33259 * config/aarch64/aarch64-modes.def (NUM_POLY_INT_COEFFS): Set to 2.
33260 * config/aarch64/aarch64-protos.h (aarch64_initial_elimination_offset):
33261 Return a poly_int64 rather than a HOST_WIDE_INT.
33262 (aarch64_offset_7bit_signed_scaled_p): Take the offset as a poly_int64
33263 rather than a HOST_WIDE_INT.
33264 * config/aarch64/aarch64.h (aarch64_frame): Protect with
33265 HAVE_POLY_INT_H rather than HOST_WIDE_INT. Change locals_offset,
33266 hard_fp_offset, frame_size, initial_adjust, callee_offset and
33267 final_offset from HOST_WIDE_INT to poly_int64.
33268 * config/aarch64/aarch64-builtins.c (aarch64_simd_expand_args): Use
33269 to_constant when getting the number of units in an Advanced SIMD
33270 mode.
33271 (aarch64_builtin_vectorized_function): Check for a constant number
33272 of units.
33273 * config/aarch64/aarch64-simd.md (mov<mode>): Handle polynomial
33274 GET_MODE_SIZE.
33275 (aarch64_ld<VSTRUCT:nregs>_lane<VALLDIF:mode>): Use the nunits
33276 attribute instead of GET_MODE_NUNITS.
33277 * config/aarch64/aarch64.c (aarch64_hard_regno_nregs)
33278 (aarch64_class_max_nregs): Use the constant_lowest_bound of the
33279 GET_MODE_SIZE for fixed-size registers.
33280 (aarch64_const_vec_all_same_in_range_p): Use const_vec_duplicate_p.
33281 (aarch64_hard_regno_call_part_clobbered, aarch64_classify_index)
33282 (aarch64_mode_valid_for_sched_fusion_p, aarch64_classify_address)
33283 (aarch64_legitimize_address_displacement, aarch64_secondary_reload)
33284 (aarch64_print_operand, aarch64_print_address_internal)
33285 (aarch64_address_cost, aarch64_rtx_costs, aarch64_register_move_cost)
33286 (aarch64_short_vector_p, aapcs_vfp_sub_candidate)
33287 (aarch64_simd_attr_length_rglist, aarch64_operands_ok_for_ldpstp):
33288 Handle polynomial GET_MODE_SIZE.
33289 (aarch64_hard_regno_caller_save_mode): Likewise. Return modes
33290 wider than SImode without modification.
33291 (tls_symbolic_operand_type): Use strip_offset instead of split_const.
33292 (aarch64_pass_by_reference, aarch64_layout_arg, aarch64_pad_reg_upward)
33293 (aarch64_gimplify_va_arg_expr): Assert that we don't yet handle
33294 passing and returning SVE modes.
33295 (aarch64_function_value, aarch64_layout_arg): Use gen_int_mode
33296 rather than GEN_INT.
33297 (aarch64_emit_probe_stack_range): Take the size as a poly_int64
33298 rather than a HOST_WIDE_INT, but call sorry if it isn't constant.
33299 (aarch64_allocate_and_probe_stack_space): Likewise.
33300 (aarch64_layout_frame): Cope with polynomial offsets.
33301 (aarch64_save_callee_saves, aarch64_restore_callee_saves): Take the
33302 start_offset as a poly_int64 rather than a HOST_WIDE_INT. Track
33303 polynomial offsets.
33304 (offset_9bit_signed_unscaled_p, offset_12bit_unsigned_scaled_p)
33305 (aarch64_offset_7bit_signed_scaled_p): Take the offset as a
33306 poly_int64 rather than a HOST_WIDE_INT.
33307 (aarch64_get_separate_components, aarch64_process_components)
33308 (aarch64_expand_prologue, aarch64_expand_epilogue)
33309 (aarch64_use_return_insn_p): Handle polynomial frame offsets.
33310 (aarch64_anchor_offset): New function, split out from...
33311 (aarch64_legitimize_address): ...here.
33312 (aarch64_builtin_vectorization_cost): Handle polynomial
33313 TYPE_VECTOR_SUBPARTS.
33314 (aarch64_simd_check_vect_par_cnst_half): Handle polynomial
33315 GET_MODE_NUNITS.
33316 (aarch64_simd_make_constant, aarch64_expand_vector_init): Get the
33317 number of elements from the PARALLEL rather than the mode.
33318 (aarch64_shift_truncation_mask): Use GET_MODE_UNIT_BITSIZE
33319 rather than GET_MODE_BITSIZE.
33320 (aarch64_evpc_trn, aarch64_evpc_uzp, aarch64_evpc_ext)
33321 (aarch64_evpc_rev, aarch64_evpc_dup, aarch64_evpc_zip)
33322 (aarch64_expand_vec_perm_const_1): Handle polynomial
33323 d->perm.length () and d->perm elements.
33324 (aarch64_evpc_tbl): Likewise. Use nelt rather than GET_MODE_NUNITS.
33325 Apply to_constant to d->perm elements.
33326 (aarch64_simd_valid_immediate, aarch64_vec_fpconst_pow_of_2): Handle
33327 polynomial CONST_VECTOR_NUNITS.
33328 (aarch64_move_pointer): Take amount as a poly_int64 rather
33329 than an int.
33330 (aarch64_progress_pointer): Avoid temporary variable.
33331 * config/aarch64/aarch64.md (aarch64_<crc_variant>): Use
33332 the mode attribute instead of GET_MODE.
33333
33334 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
33335 Alan Hayward <alan.hayward@arm.com>
33336 David Sherwood <david.sherwood@arm.com>
33337
33338 * config/aarch64/aarch64.c (aarch64_force_temporary): Assert that
33339 x exists before using it.
33340 (aarch64_add_constant_internal): Rename to...
33341 (aarch64_add_offset_1): ...this. Replace regnum with separate
33342 src and dest rtxes. Handle the case in which they're different,
33343 including when the offset is zero. Replace scratchreg with an rtx.
33344 Use 2 additions if there is no spare register into which we can
33345 move a 16-bit constant.
33346 (aarch64_add_constant): Delete.
33347 (aarch64_add_offset): Replace reg with separate src and dest
33348 rtxes. Take a poly_int64 offset instead of a HOST_WIDE_INT.
33349 Use aarch64_add_offset_1.
33350 (aarch64_add_sp, aarch64_sub_sp): Take the scratch register as
33351 an rtx rather than an int. Take the delta as a poly_int64
33352 rather than a HOST_WIDE_INT. Use aarch64_add_offset.
33353 (aarch64_expand_mov_immediate): Update uses of aarch64_add_offset.
33354 (aarch64_expand_prologue): Update calls to aarch64_sub_sp,
33355 aarch64_allocate_and_probe_stack_space and aarch64_add_offset.
33356 (aarch64_expand_epilogue): Update calls to aarch64_add_offset
33357 and aarch64_add_sp.
33358 (aarch64_output_mi_thunk): Use aarch64_add_offset rather than
33359 aarch64_add_constant.
33360
33361 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
33362
33363 * config/aarch64/aarch64.c (aarch64_reinterpret_float_as_int):
33364 Use scalar_float_mode.
33365
33366 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
33367
33368 * config/aarch64/aarch64-simd.md
33369 (aarch64_fml<f16mac1>l<f16quad>_low<mode>): Avoid GET_MODE_NUNITS.
33370 (aarch64_fml<f16mac1>l<f16quad>_high<mode>): Likewise.
33371 (aarch64_fml<f16mac1>l_lane_lowv2sf): Likewise.
33372 (aarch64_fml<f16mac1>l_lane_highv2sf): Likewise.
33373 (aarch64_fml<f16mac1>lq_laneq_lowv4sf): Likewise.
33374 (aarch64_fml<f16mac1>lq_laneq_highv4sf): Likewise.
33375 (aarch64_fml<f16mac1>l_laneq_lowv2sf): Likewise.
33376 (aarch64_fml<f16mac1>l_laneq_highv2sf): Likewise.
33377 (aarch64_fml<f16mac1>lq_lane_lowv4sf): Likewise.
33378 (aarch64_fml<f16mac1>lq_lane_highv4sf): Likewise.
33379
33380 2018-01-11 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
33381
33382 PR target/83514
33383 * config/arm/arm.c (arm_declare_function_name): Set arch_to_print if
33384 targ_options->x_arm_arch_string is non NULL.
33385
33386 2018-01-11 Tamar Christina <tamar.christina@arm.com>
33387
33388 * config/aarch64/aarch64.h
33389 (AARCH64_FL_FOR_ARCH8_4): Add AARCH64_FL_DOTPROD.
33390
33391 2018-01-11 Sudakshina Das <sudi.das@arm.com>
33392
33393 PR target/82096
33394 * expmed.c (emit_store_flag_force): Swap if const op0
33395 and change VOIDmode to mode of op0.
33396
33397 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
33398
33399 PR rtl-optimization/83761
33400 * caller-save.c (replace_reg_with_saved_mem): Pass bits rather
33401 than bytes to mode_for_size.
33402
33403 2018-01-10 Jan Hubicka <hubicka@ucw.cz>
33404
33405 PR middle-end/83189
33406 * gfortran.fortran-torture/compile/pr83189.f90: New testcase.
33407 * tree-ssa-loop-manip.c (tree_transform_and_unroll_loop): Handle zero
33408 profile.
33409
33410 2018-01-10 Jan Hubicka <hubicka@ucw.cz>
33411
33412 PR middle-end/83575
33413 * cfgrtl.c (rtl_verify_edges): Only verify fixability of partition
33414 when in layout mode.
33415 (cfg_layout_finalize): Do not verify cfg before we are out of layout.
33416 * cfgcleanup.c (try_optimize_cfg): Only verify flow info when doing
33417 partition fixup.
33418
33419 2018-01-10 Michael Collison <michael.collison@arm.com>
33420
33421 * config/aarch64/aarch64-modes.def (V2HF): New VECTOR_MODE.
33422 * config/aarch64/aarch64-option-extension.def: Add
33423 AARCH64_OPT_EXTENSION of 'fp16fml'.
33424 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins):
33425 (__ARM_FEATURE_FP16_FML): Define if TARGET_F16FML is true.
33426 * config/aarch64/predicates.md (aarch64_lane_imm3): New predicate.
33427 * config/aarch64/constraints.md (Ui7): New constraint.
33428 * config/aarch64/iterators.md (VFMLA_W): New mode iterator.
33429 (VFMLA_SEL_W): Ditto.
33430 (f16quad): Ditto.
33431 (f16mac1): Ditto.
33432 (VFMLA16_LOW): New int iterator.
33433 (VFMLA16_HIGH): Ditto.
33434 (UNSPEC_FMLAL): New unspec.
33435 (UNSPEC_FMLSL): Ditto.
33436 (UNSPEC_FMLAL2): Ditto.
33437 (UNSPEC_FMLSL2): Ditto.
33438 (f16mac): New code attribute.
33439 * config/aarch64/aarch64-simd-builtins.def
33440 (aarch64_fmlal_lowv2sf): Ditto.
33441 (aarch64_fmlsl_lowv2sf): Ditto.
33442 (aarch64_fmlalq_lowv4sf): Ditto.
33443 (aarch64_fmlslq_lowv4sf): Ditto.
33444 (aarch64_fmlal_highv2sf): Ditto.
33445 (aarch64_fmlsl_highv2sf): Ditto.
33446 (aarch64_fmlalq_highv4sf): Ditto.
33447 (aarch64_fmlslq_highv4sf): Ditto.
33448 (aarch64_fmlal_lane_lowv2sf): Ditto.
33449 (aarch64_fmlsl_lane_lowv2sf): Ditto.
33450 (aarch64_fmlal_laneq_lowv2sf): Ditto.
33451 (aarch64_fmlsl_laneq_lowv2sf): Ditto.
33452 (aarch64_fmlalq_lane_lowv4sf): Ditto.
33453 (aarch64_fmlsl_lane_lowv4sf): Ditto.
33454 (aarch64_fmlalq_laneq_lowv4sf): Ditto.
33455 (aarch64_fmlsl_laneq_lowv4sf): Ditto.
33456 (aarch64_fmlal_lane_highv2sf): Ditto.
33457 (aarch64_fmlsl_lane_highv2sf): Ditto.
33458 (aarch64_fmlal_laneq_highv2sf): Ditto.
33459 (aarch64_fmlsl_laneq_highv2sf): Ditto.
33460 (aarch64_fmlalq_lane_highv4sf): Ditto.
33461 (aarch64_fmlsl_lane_highv4sf): Ditto.
33462 (aarch64_fmlalq_laneq_highv4sf): Ditto.
33463 (aarch64_fmlsl_laneq_highv4sf): Ditto.
33464 * config/aarch64/aarch64-simd.md:
33465 (aarch64_fml<f16mac1>l<f16quad>_low<mode>): New pattern.
33466 (aarch64_fml<f16mac1>l<f16quad>_high<mode>): Ditto.
33467 (aarch64_simd_fml<f16mac1>l<f16quad>_low<mode>): Ditto.
33468 (aarch64_simd_fml<f16mac1>l<f16quad>_high<mode>): Ditto.
33469 (aarch64_fml<f16mac1>l_lane_lowv2sf): Ditto.
33470 (aarch64_fml<f16mac1>l_lane_highv2sf): Ditto.
33471 (aarch64_simd_fml<f16mac>l_lane_lowv2sf): Ditto.
33472 (aarch64_simd_fml<f16mac>l_lane_highv2sf): Ditto.
33473 (aarch64_fml<f16mac1>lq_laneq_lowv4sf): Ditto.
33474 (aarch64_fml<f16mac1>lq_laneq_highv4sf): Ditto.
33475 (aarch64_simd_fml<f16mac>lq_laneq_lowv4sf): Ditto.
33476 (aarch64_simd_fml<f16mac>lq_laneq_highv4sf): Ditto.
33477 (aarch64_fml<f16mac1>l_laneq_lowv2sf): Ditto.
33478 (aarch64_fml<f16mac1>l_laneq_highv2sf): Ditto.
33479 (aarch64_simd_fml<f16mac>l_laneq_lowv2sf): Ditto.
33480 (aarch64_simd_fml<f16mac>l_laneq_highv2sf): Ditto.
33481 (aarch64_fml<f16mac1>lq_lane_lowv4sf): Ditto.
33482 (aarch64_fml<f16mac1>lq_lane_highv4sf): Ditto.
33483 (aarch64_simd_fml<f16mac>lq_lane_lowv4sf): Ditto.
33484 (aarch64_simd_fml<f16mac>lq_lane_highv4sf): Ditto.
33485 * config/aarch64/arm_neon.h (vfmlal_low_u32): New intrinsic.
33486 (vfmlsl_low_u32): Ditto.
33487 (vfmlalq_low_u32): Ditto.
33488 (vfmlslq_low_u32): Ditto.
33489 (vfmlal_high_u32): Ditto.
33490 (vfmlsl_high_u32): Ditto.
33491 (vfmlalq_high_u32): Ditto.
33492 (vfmlslq_high_u32): Ditto.
33493 (vfmlal_lane_low_u32): Ditto.
33494 (vfmlsl_lane_low_u32): Ditto.
33495 (vfmlal_laneq_low_u32): Ditto.
33496 (vfmlsl_laneq_low_u32): Ditto.
33497 (vfmlalq_lane_low_u32): Ditto.
33498 (vfmlslq_lane_low_u32): Ditto.
33499 (vfmlalq_laneq_low_u32): Ditto.
33500 (vfmlslq_laneq_low_u32): Ditto.
33501 (vfmlal_lane_high_u32): Ditto.
33502 (vfmlsl_lane_high_u32): Ditto.
33503 (vfmlal_laneq_high_u32): Ditto.
33504 (vfmlsl_laneq_high_u32): Ditto.
33505 (vfmlalq_lane_high_u32): Ditto.
33506 (vfmlslq_lane_high_u32): Ditto.
33507 (vfmlalq_laneq_high_u32): Ditto.
33508 (vfmlslq_laneq_high_u32): Ditto.
33509 * config/aarch64/aarch64.h (AARCH64_FL_F16SML): New flag.
33510 (AARCH64_FL_FOR_ARCH8_4): New.
33511 (AARCH64_ISA_F16FML): New ISA flag.
33512 (TARGET_F16FML): New feature flag for fp16fml.
33513 (doc/invoke.texi): Document new fp16fml option.
33514
33515 2018-01-10 Michael Collison <michael.collison@arm.com>
33516
33517 * config/aarch64/aarch64-builtins.c:
33518 (aarch64_types_ternopu_imm_qualifiers, TYPES_TERNOPUI): New.
33519 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins):
33520 (__ARM_FEATURE_SHA3): Define if TARGET_SHA3 is true.
33521 * config/aarch64/aarch64.h (AARCH64_FL_SHA3): New flags.
33522 (AARCH64_ISA_SHA3): New ISA flag.
33523 (TARGET_SHA3): New feature flag for sha3.
33524 * config/aarch64/iterators.md (sha512_op): New int attribute.
33525 (CRYPTO_SHA512): New int iterator.
33526 (UNSPEC_SHA512H): New unspec.
33527 (UNSPEC_SHA512H2): Ditto.
33528 (UNSPEC_SHA512SU0): Ditto.
33529 (UNSPEC_SHA512SU1): Ditto.
33530 * config/aarch64/aarch64-simd-builtins.def
33531 (aarch64_crypto_sha512hqv2di): New builtin.
33532 (aarch64_crypto_sha512h2qv2di): Ditto.
33533 (aarch64_crypto_sha512su0qv2di): Ditto.
33534 (aarch64_crypto_sha512su1qv2di): Ditto.
33535 (aarch64_eor3qv8hi): Ditto.
33536 (aarch64_rax1qv2di): Ditto.
33537 (aarch64_xarqv2di): Ditto.
33538 (aarch64_bcaxqv8hi): Ditto.
33539 * config/aarch64/aarch64-simd.md:
33540 (aarch64_crypto_sha512h<sha512_op>qv2di): New pattern.
33541 (aarch64_crypto_sha512su0qv2di): Ditto.
33542 (aarch64_crypto_sha512su1qv2di): Ditto.
33543 (aarch64_eor3qv8hi): Ditto.
33544 (aarch64_rax1qv2di): Ditto.
33545 (aarch64_xarqv2di): Ditto.
33546 (aarch64_bcaxqv8hi): Ditto.
33547 * config/aarch64/arm_neon.h (vsha512hq_u64): New intrinsic.
33548 (vsha512h2q_u64): Ditto.
33549 (vsha512su0q_u64): Ditto.
33550 (vsha512su1q_u64): Ditto.
33551 (veor3q_u16): Ditto.
33552 (vrax1q_u64): Ditto.
33553 (vxarq_u64): Ditto.
33554 (vbcaxq_u16): Ditto.
33555 * config/arm/types.md (crypto_sha512): New type attribute.
33556 (crypto_sha3): Ditto.
33557 (doc/invoke.texi): Document new sha3 option.
33558
33559 2018-01-10 Michael Collison <michael.collison@arm.com>
33560
33561 * config/aarch64/aarch64-builtins.c:
33562 (aarch64_types_quadopu_imm_qualifiers, TYPES_QUADOPUI): New.
33563 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins):
33564 (__ARM_FEATURE_SM3): Define if TARGET_SM4 is true.
33565 (__ARM_FEATURE_SM4): Define if TARGET_SM4 is true.
33566 * config/aarch64/aarch64.h (AARCH64_FL_SM4): New flags.
33567 (AARCH64_ISA_SM4): New ISA flag.
33568 (TARGET_SM4): New feature flag for sm4.
33569 * config/aarch64/aarch64-simd-builtins.def
33570 (aarch64_sm3ss1qv4si): Ditto.
33571 (aarch64_sm3tt1aq4si): Ditto.
33572 (aarch64_sm3tt1bq4si): Ditto.
33573 (aarch64_sm3tt2aq4si): Ditto.
33574 (aarch64_sm3tt2bq4si): Ditto.
33575 (aarch64_sm3partw1qv4si): Ditto.
33576 (aarch64_sm3partw2qv4si): Ditto.
33577 (aarch64_sm4eqv4si): Ditto.
33578 (aarch64_sm4ekeyqv4si): Ditto.
33579 * config/aarch64/aarch64-simd.md:
33580 (aarch64_sm3ss1qv4si): Ditto.
33581 (aarch64_sm3tt<sm3tt_op>qv4si): Ditto.
33582 (aarch64_sm3partw<sm3part_op>qv4si): Ditto.
33583 (aarch64_sm4eqv4si): Ditto.
33584 (aarch64_sm4ekeyqv4si): Ditto.
33585 * config/aarch64/iterators.md (sm3tt_op): New int iterator.
33586 (sm3part_op): Ditto.
33587 (CRYPTO_SM3TT): Ditto.
33588 (CRYPTO_SM3PART): Ditto.
33589 (UNSPEC_SM3SS1): New unspec.
33590 (UNSPEC_SM3TT1A): Ditto.
33591 (UNSPEC_SM3TT1B): Ditto.
33592 (UNSPEC_SM3TT2A): Ditto.
33593 (UNSPEC_SM3TT2B): Ditto.
33594 (UNSPEC_SM3PARTW1): Ditto.
33595 (UNSPEC_SM3PARTW2): Ditto.
33596 (UNSPEC_SM4E): Ditto.
33597 (UNSPEC_SM4EKEY): Ditto.
33598 * config/aarch64/constraints.md (Ui2): New constraint.
33599 * config/aarch64/predicates.md (aarch64_imm2): New predicate.
33600 * config/arm/types.md (crypto_sm3): New type attribute.
33601 (crypto_sm4): Ditto.
33602 * config/aarch64/arm_neon.h (vsm3ss1q_u32): New intrinsic.
33603 (vsm3tt1aq_u32): Ditto.
33604 (vsm3tt1bq_u32): Ditto.
33605 (vsm3tt2aq_u32): Ditto.
33606 (vsm3tt2bq_u32): Ditto.
33607 (vsm3partw1q_u32): Ditto.
33608 (vsm3partw2q_u32): Ditto.
33609 (vsm4eq_u32): Ditto.
33610 (vsm4ekeyq_u32): Ditto.
33611 (doc/invoke.texi): Document new sm4 option.
33612
33613 2018-01-10 Michael Collison <michael.collison@arm.com>
33614
33615 * config/aarch64/aarch64-arches.def (armv8.4-a): New architecture.
33616 * config/aarch64/aarch64.h (AARCH64_ISA_V8_4): New ISA flag.
33617 (AARCH64_FL_FOR_ARCH8_4): New.
33618 (AARCH64_FL_V8_4): New flag.
33619 (doc/invoke.texi): Document new armv8.4-a option.
33620
33621 2018-01-10 Michael Collison <michael.collison@arm.com>
33622
33623 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins):
33624 (__ARM_FEATURE_AES): Define if TARGET_AES is true.
33625 (__ARM_FEATURE_SHA2): Define if TARGET_SHA2 is true.
33626 * config/aarch64/aarch64-option-extension.def: Add
33627 AARCH64_OPT_EXTENSION of 'sha2'.
33628 (aes): Add AARCH64_OPT_EXTENSION of 'aes'.
33629 (crypto): Disable sha2 and aes if crypto disabled.
33630 (crypto): Enable aes and sha2 if enabled.
33631 (simd): Disable sha2 and aes if simd disabled.
33632 * config/aarch64/aarch64.h (AARCH64_FL_AES, AARCH64_FL_SHA2):
33633 New flags.
33634 (AARCH64_ISA_AES, AARCH64_ISA_SHA2): New ISA flags.
33635 (TARGET_SHA2): New feature flag for sha2.
33636 (TARGET_AES): New feature flag for aes.
33637 * config/aarch64/aarch64-simd.md:
33638 (aarch64_crypto_aes<aes_op>v16qi): Make pattern
33639 conditional on TARGET_AES.
33640 (aarch64_crypto_aes<aesmc_op>v16qi): Ditto.
33641 (aarch64_crypto_sha1hsi): Make pattern conditional
33642 on TARGET_SHA2.
33643 (aarch64_crypto_sha1hv4si): Ditto.
33644 (aarch64_be_crypto_sha1hv4si): Ditto.
33645 (aarch64_crypto_sha1su1v4si): Ditto.
33646 (aarch64_crypto_sha1<sha1_op>v4si): Ditto.
33647 (aarch64_crypto_sha1su0v4si): Ditto.
33648 (aarch64_crypto_sha256h<sha256_op>v4si): Ditto.
33649 (aarch64_crypto_sha256su0v4si): Ditto.
33650 (aarch64_crypto_sha256su1v4si): Ditto.
33651 (doc/invoke.texi): Document new aes and sha2 options.
33652
33653 2018-01-10 Martin Sebor <msebor@redhat.com>
33654
33655 PR tree-optimization/83781
33656 * gimple-fold.c (get_range_strlen): Avoid treating arrays of pointers
33657 as string arrays.
33658
33659 2018-01-11 Martin Sebor <msebor@gmail.com>
33660 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
33661
33662 PR tree-optimization/83501
33663 PR tree-optimization/81703
33664
33665 * tree-ssa-strlen.c (get_string_cst): Rename...
33666 (get_string_len): ...to this. Handle global constants.
33667 (handle_char_store): Adjust.
33668
33669 2018-01-10 Kito Cheng <kito.cheng@gmail.com>
33670 Jim Wilson <jimw@sifive.com>
33671
33672 * config/riscv/riscv-protos.h (riscv_output_return): New.
33673 * config/riscv/riscv.c (struct machine_function): New naked_p field.
33674 (riscv_attribute_table, riscv_output_return),
33675 (riscv_handle_fndecl_attribute, riscv_naked_function_p),
33676 (riscv_allocate_stack_slots_for_args, riscv_warn_func_return): New.
33677 (riscv_compute_frame_info): Only compute frame->mask if not a naked
33678 function.
33679 (riscv_expand_prologue): Add early return for naked function.
33680 (riscv_expand_epilogue): Likewise.
33681 (riscv_function_ok_for_sibcall): Return false for naked function.
33682 (riscv_set_current_function): New.
33683 (TARGET_SET_CURRENT_FUNCTION, TARGET_ALLOCATE_STACK_SLOTS_FOR_ARGS),
33684 (TARGET_ATTRIBUTE_TABLE, TARGET_WARN_FUNC_RETURN): New.
33685 * config/riscv/riscv.md (simple_return): Call riscv_output_return.
33686 * doc/extend.texi (RISC-V Function Attributes): New.
33687
33688 2018-01-10 Michael Meissner <meissner@linux.vnet.ibm.com>
33689
33690 * config/rs6000/rs6000.c (is_complex_IBM_long_double): Explicitly
33691 check for 128-bit long double before checking TCmode.
33692 * config/rs6000/rs6000.h (FLOAT128_IEEE_P): Explicitly check for
33693 128-bit long doubles before checking TFmode or TCmode.
33694 (FLOAT128_IBM_P): Likewise.
33695
33696 2018-01-10 Martin Sebor <msebor@redhat.com>
33697
33698 PR tree-optimization/83671
33699 * builtins.c (c_strlen): Unconditionally return zero for the empty
33700 string.
33701 Use -Warray-bounds for warnings.
33702 * gimple-fold.c (get_range_strlen): Handle non-constant lengths
33703 for non-constant array indices with COMPONENT_REF, arrays of
33704 arrays, and pointers to arrays.
33705 (gimple_fold_builtin_strlen): Determine and set length range for
33706 non-constant character arrays.
33707
33708 2018-01-10 Aldy Hernandez <aldyh@redhat.com>
33709
33710 PR middle-end/81897
33711 * tree-ssa-uninit.c (convert_control_dep_chain_into_preds): Skip
33712 empty blocks.
33713
33714 2018-01-10 Eric Botcazou <ebotcazou@adacore.com>
33715
33716 * dwarf2out.c (dwarf2out_var_location): Do not pass NULL to fprintf.
33717
33718 2018-01-10 Peter Bergner <bergner@vnet.ibm.com>
33719
33720 PR target/83399
33721 * config/rs6000/rs6000.c (print_operand) <'y'>: Use
33722 VECTOR_MEM_ALTIVEC_OR_VSX_P.
33723 * config/rs6000/vsx.md (*vsx_le_perm_load_<mode> for VSX_D): Use
33724 indexed_or_indirect_operand predicate.
33725 (*vsx_le_perm_load_<mode> for VSX_W): Likewise.
33726 (*vsx_le_perm_load_v8hi): Likewise.
33727 (*vsx_le_perm_load_v16qi): Likewise.
33728 (*vsx_le_perm_store_<mode> for VSX_D): Likewise.
33729 (*vsx_le_perm_store_<mode> for VSX_W): Likewise.
33730 (*vsx_le_perm_store_v8hi): Likewise.
33731 (*vsx_le_perm_store_v16qi): Likewise.
33732 (eight unnamed splitters): Likewise.
33733
33734 2018-01-10 Peter Bergner <bergner@vnet.ibm.com>
33735
33736 * config/rs6000/x86intrin.h: Change #warning to #error. Update message.
33737 * config/rs6000/emmintrin.h: Likewise.
33738 * config/rs6000/mmintrin.h: Likewise.
33739 * config/rs6000/xmmintrin.h: Likewise.
33740
33741 2018-01-10 David Malcolm <dmalcolm@redhat.com>
33742
33743 PR c++/43486
33744 * tree-core.h: Document EXPR_LOCATION_WRAPPER_P's usage of
33745 "public_flag".
33746 * tree.c (tree_nop_conversion): Return true for location wrapper
33747 nodes.
33748 (maybe_wrap_with_location): New function.
33749 (selftest::check_strip_nops): New function.
33750 (selftest::test_location_wrappers): New function.
33751 (selftest::tree_c_tests): Call it.
33752 * tree.h (STRIP_ANY_LOCATION_WRAPPER): New macro.
33753 (maybe_wrap_with_location): New decl.
33754 (EXPR_LOCATION_WRAPPER_P): New macro.
33755 (location_wrapper_p): New inline function.
33756 (tree_strip_any_location_wrapper): New inline function.
33757
33758 2018-01-10 H.J. Lu <hongjiu.lu@intel.com>
33759
33760 PR target/83735
33761 * config/i386/i386.c (ix86_compute_frame_layout): Always adjust
33762 stack_realign_offset for the largest alignment of stack slot
33763 actually used.
33764 (ix86_find_max_used_stack_alignment): New function.
33765 (ix86_finalize_stack_frame_flags): Use it. Set
33766 max_used_stack_alignment if we don't realign stack.
33767 * config/i386/i386.h (machine_function): Add
33768 max_used_stack_alignment.
33769
33770 2018-01-10 Christophe Lyon <christophe.lyon@linaro.org>
33771
33772 * config/arm/arm.opt (-mbranch-cost): New option.
33773 * config/arm/arm.h (BRANCH_COST): Take arm_branch_cost into
33774 account.
33775
33776 2018-01-10 Segher Boessenkool <segher@kernel.crashing.org>
33777
33778 PR target/83629
33779 * config/rs6000/rs6000.md (load_toc_v4_PIC_2, load_toc_v4_PIC_3b,
33780 load_toc_v4_PIC_3c): Wrap const term in CONST RTL.
33781
33782 2018-01-10 Richard Biener <rguenther@suse.de>
33783
33784 PR debug/83765
33785 * dwarf2out.c (gen_subprogram_die): Hoist old_die && declaration
33786 early out so it also covers the case where we have a non-NULL
33787 origin.
33788
33789 2018-01-10 Richard Sandiford <richard.sandiford@linaro.org>
33790
33791 PR tree-optimization/83753
33792 * tree-vect-stmts.c (get_group_load_store_type): Use VMAT_CONTIGUOUS
33793 for non-strided grouped accesses if the number of elements is 1.
33794
33795 2018-01-10 Jan Hubicka <hubicka@ucw.cz>
33796
33797 PR target/81616
33798 * i386.c (ix86_vectorize_builtin_gather): Check TARGET_USE_GATHER.
33799 * i386.h (TARGET_USE_GATHER): Define.
33800 * x86-tune.def (X86_TUNE_USE_GATHER): New.
33801
33802 2018-01-10 Martin Liska <mliska@suse.cz>
33803
33804 PR bootstrap/82831
33805 * basic-block.h (CLEANUP_NO_PARTITIONING): New define.
33806 * bb-reorder.c (pass_reorder_blocks::execute): Do not clean up
33807 partitioning.
33808 * cfgcleanup.c (try_optimize_cfg): Fix up partitioning if
33809 CLEANUP_NO_PARTITIONING is not set.
33810
33811 2018-01-10 Richard Sandiford <richard.sandiford@linaro.org>
33812
33813 * doc/rtl.texi: Remove documentation of (const ...) wrappers
33814 for vectors, as a partial revert of r254296.
33815 * rtl.h (const_vec_p): Delete.
33816 (const_vec_duplicate_p): Don't test for vector CONSTs.
33817 (unwrap_const_vec_duplicate, const_vec_series_p): Likewise.
33818 * expmed.c (make_tree): Likewise.
33819
33820 Revert:
33821 * common.md (E, F): Use CONSTANT_P instead of checking for
33822 CONST_VECTOR.
33823 * emit-rtl.c (gen_lowpart_common): Use const_vec_p instead of
33824 checking for CONST_VECTOR.
33825
33826 2018-01-09 Jan Hubicka <hubicka@ucw.cz>
33827
33828 PR middle-end/83575
33829 * predict.c (force_edge_cold): Handle in more sane way edges
33830 with no prediction.
33831
33832 2018-01-09 Carl Love <cel@us.ibm.com>
33833
33834 * config/rs6002/altivec.md (p8_vmrgow): Add support for V2DI, V2DF,
33835 V4SI, V4SF types.
33836 (p8_vmrgew): Add support for V2DI, V2DF, V4SF types.
33837 * config/rs6000/rs6000-builtin.def: Add definitions for FLOAT2_V2DF,
33838 VMRGEW_V2DI, VMRGEW_V2DF, VMRGEW_V4SF, VMRGOW_V4SI, VMRGOW_V4SF,
33839 VMRGOW_V2DI, VMRGOW_V2DF. Remove definition for VMRGOW.
33840 * config/rs6000/rs6000-c.c (VSX_BUILTIN_VEC_FLOAT2,
33841 P8V_BUILTIN_VEC_VMRGEW, P8V_BUILTIN_VEC_VMRGOW): Add definitions.
33842 * config/rs6000/rs6000-protos.h: Add extern defition for
33843 rs6000_generate_float2_double_code.
33844 * config/rs6000/rs6000.c (rs6000_generate_float2_double_code): Add
33845 function.
33846 * config/rs6000/vsx.md (vsx_xvcdpsp): Add define_insn.
33847 (float2_v2df): Add define_expand.
33848
33849 2018-01-09 Uros Bizjak <ubizjak@gmail.com>
33850
33851 PR target/83628
33852 * combine.c (force_int_to_mode) <case ASHIFT>: Use mode instead of
33853 op_mode in the force_to_mode call.
33854
33855 2018-01-09 Richard Sandiford <richard.sandiford@linaro.org>
33856
33857 * config/aarch64/aarch64.c (aarch64_evpc_trn): Use d.perm.series_p
33858 instead of checking each element individually.
33859 (aarch64_evpc_uzp): Likewise.
33860 (aarch64_evpc_zip): Likewise.
33861 (aarch64_evpc_ext): Likewise.
33862 (aarch64_evpc_rev): Likewise.
33863 (aarch64_evpc_dup): Test the encoding for a single duplicated element,
33864 instead of checking each element individually. Return true without
33865 generating rtl if
33866 (aarch64_vectorize_vec_perm_const): Use all_from_input_p to test
33867 whether all selected elements come from the same input, instead of
33868 checking each element individually. Remove calls to gen_rtx_REG,
33869 start_sequence and end_sequence and instead assert that no rtl is
33870 generated.
33871
33872 2018-01-09 Richard Sandiford <richard.sandiford@linaro.org>
33873
33874 * config/aarch64/aarch64.c (aarch64_legitimate_constant_p): Fix
33875 order of HIGH and CONST checks.
33876
33877 2018-01-09 Richard Sandiford <richard.sandiford@linaro.org>
33878
33879 * tree-vect-stmts.c (permute_vec_elements): Create a fresh variable
33880 if the destination isn't an SSA_NAME.
33881
33882 2018-01-09 Richard Biener <rguenther@suse.de>
33883
33884 PR tree-optimization/83668
33885 * graphite.c (canonicalize_loop_closed_ssa): Add edge argument,
33886 move prologue...
33887 (canonicalize_loop_form): ... here, renamed from ...
33888 (canonicalize_loop_closed_ssa_form): ... this and amended to
33889 swap successor edges for loop exit blocks to make us use
33890 the RPO order we need for initial schedule generation.
33891
33892 2018-01-09 Joseph Myers <joseph@codesourcery.com>
33893
33894 PR tree-optimization/64811
33895 * match.pd: When optimizing comparisons with Inf, avoid
33896 introducing or losing exceptions from comparisons with NaN.
33897
33898 2018-01-09 Martin Liska <mliska@suse.cz>
33899
33900 PR sanitizer/82517
33901 * asan.c (shadow_mem_size): Add gcc_assert.
33902
33903 2018-01-09 Georg-Johann Lay <avr@gjlay.de>
33904
33905 Don't save registers in main().
33906
33907 PR target/83738
33908 * doc/invoke.texi (AVR Options) [-mmain-is-OS_task]: Document it.
33909 * config/avr/avr.opt (-mmain-is-OS_task): New target option.
33910 * config/avr/avr.c (avr_set_current_function): Don't error if
33911 naked, OS_task or OS_main are specified at the same time.
33912 (avr_function_ok_for_sibcall): Don't disable sibcalls for OS_task,
33913 OS_main.
33914 (avr_insert_attributes) [-mmain-is-OS_task] <main>: Add OS_task
33915 attribute.
33916 * common/config/avr/avr-common.c (avr_option_optimization_table):
33917 Switch on -mmain-is-OS_task for optimizing compilations.
33918
33919 2018-01-09 Richard Biener <rguenther@suse.de>
33920
33921 PR tree-optimization/83572
33922 * graphite.c: Include cfganal.h.
33923 (graphite_transform_loops): Connect infinite loops to exit
33924 and remove fake edges at the end.
33925
33926 2018-01-09 Jan Hubicka <hubicka@ucw.cz>
33927
33928 * ipa-inline.c (edge_badness): Revert accidental checkin.
33929
33930 2018-01-09 Jan Hubicka <hubicka@ucw.cz>
33931
33932 PR ipa/80763
33933 * ipa-comdats.c (set_comdat_group): Only set comdat group of real
33934 symbols; not inline clones.
33935
33936 2018-01-09 Jakub Jelinek <jakub@redhat.com>
33937
33938 PR target/83507
33939 * modulo-sched.c (schedule_reg_moves): Punt if we'd need to move
33940 hard registers. Formatting fixes.
33941
33942 PR preprocessor/83722
33943 * gcc.c (try_generate_repro): Pass
33944 &temp_stderr_files[RETRY_ICE_ATTEMPTS - 1] rather than
33945 &temp_stdout_files[RETRY_ICE_ATTEMPTS - 1] as last argument to
33946 do_report_bug.
33947
33948 2018-01-08 Monk Chiang <sh.chiang04@gmail.com>
33949 Kito Cheng <kito.cheng@gmail.com>
33950
33951 * config/riscv/riscv.c (machine_function::is_leaf): Remove field.
33952 (riscv_leaf_function_p): Delete.
33953 (riscv_function_ok_for_sibcall): Return false when TARGET_SAVE_RESTORE.
33954
33955 2018-01-08 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
33956
33957 * config/rs6000/rs6000-string.c (do_load_for_compare_from_addr): New
33958 function.
33959 (do_ifelse): New function.
33960 (do_isel): New function.
33961 (do_sub3): New function.
33962 (do_add3): New function.
33963 (do_load_mask_compare): New function.
33964 (do_overlap_load_compare): New function.
33965 (expand_compare_loop): New function.
33966 (expand_block_compare): Call expand_compare_loop() when appropriate.
33967 * config/rs6000/rs6000.opt (-mblock-compare-inline-limit): Change
33968 option description.
33969 (-mblock-compare-inline-loop-limit): New option.
33970
33971 2018-01-08 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
33972
33973 PR target/83677
33974 * config/rs6000/altivec.md (*altivec_vpermr_<mode>_internal):
33975 Reverse order of second and third operands in first alternative.
33976 * config/rs6000/rs6000.c (rs6000_expand_vector_set): Reverse order
33977 of first and second elements in UNSPEC_VPERMR vector.
33978 (altivec_expand_vec_perm_le): Likewise.
33979
33980 2018-01-08 Jeff Law <law@redhat.com>
33981
33982 PR rtl-optimizatin/81308
33983 * tree-switch-conversion.c (cfg_altered): New file scoped static.
33984 (process_switch): If group_case_labels makes a change, then set
33985 cfg_altered.
33986 (pass_convert_switch::execute): If a switch is converted, then
33987 set cfg_altered. Return TODO_cfg_cleanup if cfg_altered is true.
33988
33989 PR rtl-optimization/81308
33990 * recog.c (split_all_insns): Conditionally cleanup the CFG after
33991 splitting insns.
33992
33993 2018-01-08 Vidya Praveen <vidyapraveen@arm.com>
33994
33995 PR target/83663 - Revert r255946
33996 * config/aarch64/aarch64.c (aarch64_expand_vector_init): Modify code
33997 generation for cases where splatting a value is not useful.
33998 * simplify-rtx.c (simplify_ternary_operation): Simplify vec_merge
33999 across a vec_duplicate and a paradoxical subreg forming a vector
34000 mode to a vec_concat.
34001
34002 2018-01-08 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
34003
34004 * config/arm/t-aprofile (MULTILIB_MATCHES): Add mapping rules for
34005 -march=armv8.3-a variants.
34006 * config/arm/t-multilib: Likewise.
34007 * config/arm/t-arm-elf: Likewise. Handle dotprod extension.
34008
34009 2018-01-08 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
34010
34011 * config/rs6000/rs6000.md (cceq_ior_compare): Remove * so I can use it
34012 to generate rtl.
34013 (cceq_ior_compare_complement): Give it a name so I can use it, and
34014 change boolean_or_operator predicate to boolean_operator so it can
34015 be used to generate a crand.
34016 (eqne): New code iterator.
34017 (bd/bd_neg): New code_attrs.
34018 (<bd>_<mode>): New name for ctr<mode>_internal[12] now combined into
34019 a single define_insn.
34020 (<bd>tf_<mode>): A new insn pattern for the conditional form branch
34021 decrement (bdnzt/bdnzf/bdzt/bdzf).
34022 * config/rs6000/rs6000.c (rs6000_legitimate_combined_insn): Updated
34023 with the new names of the branch decrement patterns, and added the
34024 names of the branch decrement conditional patterns.
34025
34026 2018-01-08 Richard Biener <rguenther@suse.de>
34027
34028 PR tree-optimization/83563
34029 * graphite.c (canonicalize_loop_closed_ssa_form): Reset the SCEV
34030 cache.
34031
34032 2018-01-08 Richard Biener <rguenther@suse.de>
34033
34034 PR middle-end/83713
34035 * convert.c (do_narrow): Properly guard TYPE_OVERFLOW_WRAPS checks.
34036
34037 2018-01-08 Richard Biener <rguenther@suse.de>
34038
34039 PR tree-optimization/83685
34040 * tree-ssa-pre.c (create_expression_by_pieces): Do not insert
34041 references to abnormals.
34042
34043 2018-01-08 Richard Biener <rguenther@suse.de>
34044
34045 PR lto/83719
34046 * dwarf2out.c (output_indirect_strings): Handle empty
34047 skeleton_debug_str_hash.
34048 (dwarf2out_early_finish): Index strings for -gsplit-dwarf.
34049
34050 2018-01-08 Claudiu Zissulescu <claziss@synopsys.com>
34051
34052 * config/arc/arc.c (TARGET_TRAMPOLINE_ADJUST_ADDRESS): Delete.
34053 (emit_store_direct): Likewise.
34054 (arc_trampoline_adjust_address): Likewise.
34055 (arc_asm_trampoline_template): New function.
34056 (arc_initialize_trampoline): Use asm_trampoline_template.
34057 (TARGET_ASM_TRAMPOLINE_TEMPLATE): Define.
34058 * config/arc/arc.h (TRAMPOLINE_SIZE): Adjust to 16.
34059 * config/arc/arc.md (flush_icache): Delete pattern.
34060
34061 2018-01-08 Claudiu Zissulescu <claziss@synopsys.com>
34062
34063 * config/arc/arc-c.def (__ARC_UNALIGNED__): New define.
34064 * config/arc/arc.h (STRICT_ALIGNMENT): Control this macro using
34065 munaligned-access.
34066
34067 2018-01-08 Sebastian Huber <sebastian.huber@embedded-brains.de>
34068
34069 PR target/83681
34070 * config/epiphany/epiphany.h (make_pass_mode_switch_use): Guard
34071 by not USED_FOR_TARGET.
34072 (make_pass_resolve_sw_modes): Likewise.
34073
34074 2018-01-08 Sebastian Huber <sebastian.huber@embedded-brains.de>
34075
34076 * config/nios2/nios2.h (nios2_section_threshold): Guard by not
34077 USED_FOR_TARGET.
34078
34079 2018-01-08 Richard Biener <rguenther@suse.de>
34080
34081 PR middle-end/83580
34082 * tree-data-ref.c (split_constant_offset): Remove STRIP_NOPS.
34083
34084 2018-01-08 Richard Biener <rguenther@suse.de>
34085
34086 PR middle-end/83517
34087 * match.pd ((t * 2) / 2) -> t): Add missing :c.
34088
34089 2018-01-06 Aldy Hernandez <aldyh@redhat.com>
34090
34091 PR middle-end/81897
34092 * tree-ssa-uninit.c (compute_control_dep_chain): Do not bail on
34093 basic blocks with a small number of successors.
34094 (convert_control_dep_chain_into_preds): Improve handling of
34095 forwarder blocks.
34096 (dump_predicates): Split apart into...
34097 (dump_pred_chain): ...here...
34098 (dump_pred_info): ...and here.
34099 (can_one_predicate_be_invalidated_p): Add debugging printfs.
34100 (can_chain_union_be_invalidated_p): Improve check for invalidation
34101 of paths.
34102 (uninit_uses_cannot_happen): Avoid unnecessary if
34103 convert_control_dep_chain_into_preds yielded nothing.
34104
34105 2018-01-06 Martin Sebor <msebor@redhat.com>
34106
34107 PR tree-optimization/83640
34108 * gimple-ssa-warn-restrict.c (builtin_access::builtin_access): Avoid
34109 subtracting negative offset from size.
34110 (builtin_access::overlap): Adjust offset bounds of the access to fall
34111 within the size of the object if possible.
34112
34113 2018-01-06 Richard Sandiford <richard.sandiford@linaro.org>
34114
34115 PR rtl-optimization/83699
34116 * expmed.c (extract_bit_field_1): Restrict the vector usage of
34117 extract_bit_field_as_subreg to cases in which the extracted
34118 value is also a vector.
34119
34120 * lra-constraints.c (process_alt_operands): Test for the equivalence
34121 substitutions when detecting a possible reload cycle.
34122
34123 2018-01-06 Jakub Jelinek <jakub@redhat.com>
34124
34125 PR debug/83480
34126 * toplev.c (process_options): Don't enable debug_nonbind_markers_p
34127 by default if flag_selective_schedling{,2}. Formatting fixes.
34128
34129 PR rtl-optimization/83682
34130 * rtl.h (const_vec_duplicate_p): Only return true for VEC_DUPLICATE
34131 if it has non-VECTOR_MODE element mode.
34132 (vec_duplicate_p): Likewise.
34133
34134 PR middle-end/83694
34135 * cfgexpand.c (expand_debug_expr): Punt if mode1 is VOIDmode
34136 and bitsize might be greater than MAX_BITSIZE_MODE_ANY_INT.
34137
34138 2018-01-05 Jakub Jelinek <jakub@redhat.com>
34139
34140 PR target/83604
34141 * config/i386/i386-builtin.def
34142 (__builtin_ia32_vgf2p8affineinvqb_v64qi,
34143 __builtin_ia32_vgf2p8affineqb_v64qi, __builtin_ia32_vgf2p8mulb_v64qi):
34144 Require also OPTION_MASK_ISA_AVX512F in addition to
34145 OPTION_MASK_ISA_GFNI.
34146 (__builtin_ia32_vgf2p8affineinvqb_v16qi_mask,
34147 __builtin_ia32_vgf2p8affineqb_v16qi_mask): Require
34148 OPTION_MASK_ISA_AVX512VL instead of OPTION_MASK_ISA_SSE in addition
34149 to OPTION_MASK_ISA_GFNI.
34150 (__builtin_ia32_vgf2p8mulb_v32qi_mask): Require
34151 OPTION_MASK_ISA_AVX512VL in addition to OPTION_MASK_ISA_GFNI and
34152 OPTION_MASK_ISA_AVX512BW.
34153 (__builtin_ia32_vgf2p8mulb_v16qi_mask): Require
34154 OPTION_MASK_ISA_AVX512VL instead of OPTION_MASK_ISA_AVX512BW in
34155 addition to OPTION_MASK_ISA_GFNI.
34156 (__builtin_ia32_vgf2p8affineinvqb_v16qi,
34157 __builtin_ia32_vgf2p8affineqb_v16qi, __builtin_ia32_vgf2p8mulb_v16qi):
34158 Require OPTION_MASK_ISA_SSE2 instead of OPTION_MASK_ISA_SSE in addition
34159 to OPTION_MASK_ISA_GFNI.
34160 * config/i386/i386.c (def_builtin): Change to builtin isa/isa2 being
34161 a requirement for all ISAs rather than any of them with a few
34162 exceptions.
34163 (ix86_add_new_builtins): Clear OPTION_MASK_ISA_64BIT from isa before
34164 processing.
34165 (ix86_expand_builtin): Require all ISAs from builtin's isa and isa2
34166 bitmasks to be enabled with 3 exceptions, instead of requiring any
34167 enabled ISA with lots of exceptions.
34168 * config/i386/sse.md (vgf2p8affineinvqb_<mode><mask_name>,
34169 vgf2p8affineqb_<mode><mask_name>, vgf2p8mulb_<mode><mask_name>):
34170 Change avx512bw in isa attribute to avx512f.
34171 * config/i386/sgxintrin.h: Add license boilerplate.
34172 * config/i386/vaesintrin.h: Likewise. Fix macro spelling __AVX512F
34173 to __AVX512F__ and __AVX512VL to __AVX512VL__.
34174 (_mm256_aesdec_epi128, _mm256_aesdeclast_epi128, _mm256_aesenc_epi128,
34175 _mm256_aesenclast_epi128): Enable temporarily avx if __AVX__ is not
34176 defined.
34177 * config/i386/gfniintrin.h (_mm_gf2p8mul_epi8,
34178 _mm_gf2p8affineinv_epi64_epi8, _mm_gf2p8affine_epi64_epi8): Enable
34179 temporarily sse2 rather than sse if not enabled already.
34180
34181 PR target/83604
34182 * config/i386/sse.md (VI248_VLBW): Rename to ...
34183 (VI248_AVX512VL): ... this. Don't guard V32HI with TARGET_AVX512BW.
34184 (vpshrd_<mode><mask_name>, vpshld_<mode><mask_name>,
34185 vpshrdv_<mode>, vpshrdv_<mode>_mask, vpshrdv_<mode>_maskz,
34186 vpshrdv_<mode>_maskz_1, vpshldv_<mode>, vpshldv_<mode>_mask,
34187 vpshldv_<mode>_maskz, vpshldv_<mode>_maskz_1): Use VI248_AVX512VL
34188 mode iterator instead of VI248_VLBW.
34189
34190 2018-01-05 Jan Hubicka <hubicka@ucw.cz>
34191
34192 * ipa-fnsummary.c (record_modified_bb_info): Add OP.
34193 (record_modified): Skip clobbers; add debug output.
34194 (param_change_prob): Use sreal frequencies.
34195
34196 2018-01-05 Richard Sandiford <richard.sandiford@linaro.org>
34197
34198 * tree-vect-data-refs.c (vect_compute_data_ref_alignment): Don't
34199 punt for user-aligned variables.
34200
34201 2018-01-05 Richard Sandiford <richard.sandiford@linaro.org>
34202
34203 * tree-chrec.c (chrec_contains_symbols): Return true for
34204 POLY_INT_CST.
34205
34206 2018-01-05 Sudakshina Das <sudi.das@arm.com>
34207
34208 PR target/82439
34209 * simplify-rtx.c (simplify_relational_operation_1): Add simplifications
34210 of (x|y) == x for BICS pattern.
34211
34212 2018-01-05 Jakub Jelinek <jakub@redhat.com>
34213
34214 PR tree-optimization/83605
34215 * gimple-ssa-strength-reduction.c: Include tree-eh.h.
34216 (find_candidates_dom_walker::before_dom_children): Ignore stmts that
34217 can throw.
34218
34219 2018-01-05 Sebastian Huber <sebastian.huber@embedded-brains.de>
34220
34221 * config.gcc (epiphany-*-elf*): Add (epiphany-*-rtems*) configuration.
34222 * config/epiphany/rtems.h: New file.
34223
34224 2018-01-04 Jakub Jelinek <jakub@redhat.com>
34225 Uros Bizjak <ubizjak@gmail.com>
34226
34227 PR target/83554
34228 * config/i386/i386.md (*<rotate_insn>hi3_1 splitter): Use
34229 QIreg_operand instead of register_operand predicate.
34230 * config/i386/i386.c (ix86_rop_should_change_byte_p,
34231 set_rop_modrm_reg_bits, ix86_mitigate_rop): Use -mmitigate-rop in
34232 comments instead of -fmitigate[-_]rop.
34233
34234 2018-01-04 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
34235
34236 PR bootstrap/81926
34237 * cgraphunit.c (symbol_table::compile): Switch to text_section
34238 before calling assembly_start debug hook.
34239 * run-rtl-passes.c (run_rtl_passes): Likewise.
34240 Include output.h.
34241
34242 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
34243
34244 * tree-vrp.c (extract_range_from_binary_expr_1): Check
34245 range_int_cst_p rather than !symbolic_range_p before calling
34246 extract_range_from_multiplicative_op_1.
34247
34248 2018-01-04 Jeff Law <law@redhat.com>
34249
34250 * tree-ssa-math-opts.c (execute_cse_reciprocals_1): Remove
34251 redundant test in assertion.
34252
34253 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
34254
34255 * doc/rtl.texi: Document machine_mode wrapper classes.
34256
34257 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
34258
34259 * fold-const.c (fold_ternary_loc): Check tree_fits_uhwi_p before
34260 using tree_to_uhwi.
34261
34262 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
34263
34264 * tree-ssa-forwprop.c (is_combined_permutation_identity): Allow
34265 the VEC_PERM_EXPR fold to fail.
34266
34267 2018-01-04 Jakub Jelinek <jakub@redhat.com>
34268
34269 PR debug/83585
34270 * bb-reorder.c (insert_section_boundary_note): Set has_bb_partition
34271 to switched_sections.
34272
34273 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
34274
34275 PR target/83680
34276 * config/arm/arm.c (arm_vectorize_vec_perm_const): Fix inverted
34277 test for d.testing.
34278
34279 2018-01-04 Peter Bergner <bergner@vnet.ibm.com>
34280
34281 PR target/83387
34282 * config/rs6000/rs6000.c (rs6000_discover_homogeneous_aggregate): Do not
34283 allow arguments in FP registers if TARGET_HARD_FLOAT is false.
34284
34285 2018-01-04 Jakub Jelinek <jakub@redhat.com>
34286
34287 PR debug/83666
34288 * cfgexpand.c (expand_debug_expr) <case BIT_FIELD_REF>: Punt if mode
34289 is BLKmode and bitpos not zero or mode change is needed.
34290
34291 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
34292
34293 PR target/83675
34294 * config/sparc/sparc.c (sparc_vectorize_vec_perm_const): Require
34295 TARGET_VIS2.
34296
34297 2018-01-04 Uros Bizjak <ubizjak@gmail.com>
34298
34299 PR target/83628
34300 * config/alpha/alpha.md (*sadd<modesuffix>): Use ASHIFT
34301 instead of MULT rtx. Update all corresponding splitters.
34302 (*saddl_se): Ditto.
34303 (*ssub<modesuffix>): Ditto.
34304 (*ssubl_se): Ditto.
34305 (*cmp_sadd_di): Update split patterns.
34306 (*cmp_sadd_si): Ditto.
34307 (*cmp_sadd_sidi): Ditto.
34308 (*cmp_ssub_di): Ditto.
34309 (*cmp_ssub_si): Ditto.
34310 (*cmp_ssub_sidi): Ditto.
34311 * config/alpha/predicates.md (const23_operand): New predicate.
34312 * config/alpha/alpha.c (alpha_rtx_costs) [PLUS, MINUS]:
34313 Look for ASHIFT, not MULT inner operand.
34314 (alpha_split_conditional_move): Update for *sadd<modesuffix> change.
34315
34316 2018-01-04 Martin Liska <mliska@suse.cz>
34317
34318 PR gcov-profile/83669
34319 * gcov.c (output_intermediate_file): Add version to intermediate
34320 gcov file.
34321 * doc/gcov.texi: Document new field 'version' in intermediate
34322 file format. Fix location of '-k' option of gcov command.
34323
34324 2018-01-04 Martin Liska <mliska@suse.cz>
34325
34326 PR ipa/82352
34327 * ipa-icf.c (sem_function::merge): Do not cross comdat boundary.
34328
34329 2018-01-04 Jakub Jelinek <jakub@redhat.com>
34330
34331 * gimple-ssa-sprintf.c (parse_directive): Cast second dir.len to uhwi.
34332
34333 2018-01-03 Martin Sebor <msebor@redhat.com>
34334
34335 PR tree-optimization/83655
34336 * gimple-ssa-warn-restrict.c (wrestrict_dom_walker::check_call): Avoid
34337 checking calls with invalid arguments.
34338
34339 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34340
34341 * tree-vect-stmts.c (vect_get_store_rhs): New function.
34342 (vectorizable_mask_load_store): Delete.
34343 (vectorizable_call): Return false for masked loads and stores.
34344 (vectorizable_store): Handle IFN_MASK_STORE. Use vect_get_store_rhs
34345 instead of gimple_assign_rhs1.
34346 (vectorizable_load): Handle IFN_MASK_LOAD.
34347 (vect_transform_stmt): Don't set is_store for call_vec_info_type.
34348
34349 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34350
34351 * tree-vect-stmts.c (vect_build_gather_load_calls): New function,
34352 split out from..,
34353 (vectorizable_mask_load_store): ...here.
34354 (vectorizable_load): ...and here.
34355
34356 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34357
34358 * tree-vect-stmts.c (vect_build_all_ones_mask)
34359 (vect_build_zero_merge_argument): New functions, split out from...
34360 (vectorizable_load): ...here.
34361
34362 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34363
34364 * tree-vect-stmts.c (vect_check_store_rhs): New function,
34365 split out from...
34366 (vectorizable_mask_load_store): ...here.
34367 (vectorizable_store): ...and here.
34368
34369 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34370
34371 * tree-vect-stmts.c (vect_check_load_store_mask): New function,
34372 split out from...
34373 (vectorizable_mask_load_store): ...here.
34374
34375 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34376
34377 * tree-vectorizer.h (vec_load_store_type): Moved from tree-vec-stmts.c
34378 (vect_model_store_cost): Take a vec_load_store_type instead of a
34379 vect_def_type.
34380 * tree-vect-stmts.c (vec_load_store_type): Move to tree-vectorizer.h.
34381 (vect_model_store_cost): Take a vec_load_store_type instead of a
34382 vect_def_type.
34383 (vectorizable_mask_load_store): Update accordingly.
34384 (vectorizable_store): Likewise.
34385 * tree-vect-slp.c (vect_analyze_slp_cost_1): Update accordingly.
34386
34387 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34388
34389 * tree-vect-loop.c (vect_transform_loop): Stub out scalar
34390 IFN_MASK_LOAD calls here rather than...
34391 * tree-vect-stmts.c (vectorizable_mask_load_store): ...here.
34392
34393 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34394 Alan Hayward <alan.hayward@arm.com>
34395 David Sherwood <david.sherwood@arm.com>
34396
34397 * expmed.c (extract_bit_field_1): For vector extracts,
34398 fall back to extract_bit_field_as_subreg if vec_extract
34399 isn't available.
34400
34401 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34402 Alan Hayward <alan.hayward@arm.com>
34403 David Sherwood <david.sherwood@arm.com>
34404
34405 * lra-spills.c (pseudo_reg_slot_compare): Sort slots by whether
34406 they are variable or constant sized.
34407 (assign_stack_slot_num_and_sort_pseudos): Don't reuse variable-sized
34408 slots for constant-sized data.
34409
34410 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34411 Alan Hayward <alan.hayward@arm.com>
34412 David Sherwood <david.sherwood@arm.com>
34413
34414 * tree-vect-patterns.c (vect_recog_mask_conversion_pattern): When
34415 handling COND_EXPRs with boolean comparisons, try to find a better
34416 basis for the mask type than the boolean itself.
34417
34418 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34419
34420 * doc/rtl.texi (MAX_BITSIZE_MODE_ANY_MODE): Describe how the default
34421 is calculated and how it can be overridden.
34422 * genmodes.c (max_bitsize_mode_any_mode): New variable.
34423 (create_modes): Initialize it from MAX_BITSIZE_MODE_ANY_MODE,
34424 if defined.
34425 (emit_max_int): Use it to set the output MAX_BITSIZE_MODE_ANY_MODE,
34426 if nonzero.
34427
34428 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34429 Alan Hayward <alan.hayward@arm.com>
34430 David Sherwood <david.sherwood@arm.com>
34431
34432 * config/aarch64/aarch64-protos.h (aarch64_output_simd_mov_immediate):
34433 Remove the mode argument.
34434 (aarch64_simd_valid_immediate): Remove the mode and inverse
34435 arguments.
34436 * config/aarch64/iterators.md (bitsize): New iterator.
34437 * config/aarch64/aarch64-simd.md (*aarch64_simd_mov<mode>, and<mode>3)
34438 (ior<mode>3): Update calls to aarch64_output_simd_mov_immediate.
34439 * config/aarch64/constraints.md (Do, Db, Dn): Update calls to
34440 aarch64_simd_valid_immediate.
34441 * config/aarch64/predicates.md (aarch64_reg_or_orr_imm): Likewise.
34442 (aarch64_reg_or_bic_imm): Likewise.
34443 * config/aarch64/aarch64.c (simd_immediate_info): Replace mvn
34444 with an insn_type enum and msl with a modifier_type enum.
34445 Replace element_width with a scalar_mode. Change the shift
34446 to unsigned int. Add constructors for scalar_float_mode and
34447 scalar_int_mode elements.
34448 (aarch64_vect_float_const_representable_p): Delete.
34449 (aarch64_can_const_movi_rtx_p)
34450 (aarch64_simd_scalar_immediate_valid_for_move)
34451 (aarch64_simd_make_constant): Update call to
34452 aarch64_simd_valid_immediate.
34453 (aarch64_advsimd_valid_immediate_hs): New function.
34454 (aarch64_advsimd_valid_immediate): Likewise.
34455 (aarch64_simd_valid_immediate): Remove mode and inverse
34456 arguments. Rewrite to use the above. Use const_vec_duplicate_p
34457 to detect duplicated constants and use aarch64_float_const_zero_rtx_p
34458 and aarch64_float_const_representable_p on the result.
34459 (aarch64_output_simd_mov_immediate): Remove mode argument.
34460 Update call to aarch64_simd_valid_immediate and use of
34461 simd_immediate_info.
34462 (aarch64_output_scalar_simd_mov_immediate): Update call
34463 accordingly.
34464
34465 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34466 Alan Hayward <alan.hayward@arm.com>
34467 David Sherwood <david.sherwood@arm.com>
34468
34469 * machmode.h (mode_precision): Prefix with CONST_MODE_PRECISION.
34470 (mode_nunits): Likewise CONST_MODE_NUNITS.
34471 * machmode.def (ADJUST_NUNITS): Document.
34472 * genmodes.c (mode_data::need_nunits_adj): New field.
34473 (blank_mode): Update accordingly.
34474 (adj_nunits): New variable.
34475 (print_maybe_const_decl): Replace CATEGORY with a NEEDS_ADJ
34476 parameter.
34477 (emit_mode_size_inline): Set need_bytesize_adj for all modes
34478 listed in adj_nunits.
34479 (emit_mode_nunits_inline): Set need_nunits_adj for all modes
34480 listed in adj_nunits. Don't emit case statements for such modes.
34481 (emit_insn_modes_h): Emit definitions of CONST_MODE_NUNITS
34482 and CONST_MODE_PRECISION. Make CONST_MODE_SIZE expand to
34483 nothing if adj_nunits is nonnull.
34484 (emit_mode_precision, emit_mode_nunits): Use print_maybe_const_decl.
34485 (emit_mode_unit_size, emit_mode_base_align, emit_mode_ibit)
34486 (emit_mode_fbit): Update use of print_maybe_const_decl.
34487 (emit_move_size): Likewise. Treat the array as non-const
34488 if adj_nunits.
34489 (emit_mode_adjustments): Handle adj_nunits.
34490
34491 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34492
34493 * machmode.def (VECTOR_MODES_WITH_PREFIX): Document.
34494 * genmodes.c (VECTOR_MODES_WITH_PREFIX): New macro.
34495 (VECTOR_MODES): Use it.
34496 (make_vector_modes): Take the prefix as an argument.
34497
34498 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34499 Alan Hayward <alan.hayward@arm.com>
34500 David Sherwood <david.sherwood@arm.com>
34501
34502 * mode-classes.def (MODE_VECTOR_BOOL): New mode class.
34503 * machmode.h (INTEGRAL_MODE_P, VECTOR_MODE_P): Return true
34504 for MODE_VECTOR_BOOL.
34505 * machmode.def (VECTOR_BOOL_MODE): Document.
34506 * genmodes.c (VECTOR_BOOL_MODE): New macro.
34507 (make_vector_bool_mode): New function.
34508 (complete_mode, emit_mode_wider, emit_mode_adjustments): Handle
34509 MODE_VECTOR_BOOL.
34510 * lto-streamer-in.c (lto_input_mode_table): Likewise.
34511 * rtx-vector-builder.c (rtx_vector_builder::find_cached_value):
34512 Likewise.
34513 * stor-layout.c (int_mode_for_mode): Likewise.
34514 * tree.c (build_vector_type_for_mode): Likewise.
34515 * varasm.c (output_constant_pool_2): Likewise.
34516 * emit-rtl.c (init_emit_once): Make sure that CONST1_RTX (BImode) and
34517 CONSTM1_RTX (BImode) are the same thing. Initialize const_tiny_rtx
34518 for MODE_VECTOR_BOOL.
34519 * expr.c (expand_expr_real_1): Use VECTOR_MODE_P instead of a list
34520 of mode class checks.
34521 * tree-vect-generic.c (expand_vector_operation): Use VECTOR_MODE_P
34522 instead of a list of mode class checks.
34523 (expand_vector_scalar_condition): Likewise.
34524 (type_for_widest_vector_mode): Handle BImode as an inner mode.
34525
34526 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34527 Alan Hayward <alan.hayward@arm.com>
34528 David Sherwood <david.sherwood@arm.com>
34529
34530 * machmode.h (mode_size): Change from unsigned short to
34531 poly_uint16_pod.
34532 (mode_to_bytes): Return a poly_uint16 rather than an unsigned short.
34533 (GET_MODE_SIZE): Return a constant if ONLY_FIXED_SIZE_MODES,
34534 or if measurement_type is not polynomial.
34535 (fixed_size_mode::includes_p): Check for constant-sized modes.
34536 * genmodes.c (emit_mode_size_inline): Make mode_size_inline
34537 return a poly_uint16 rather than an unsigned short.
34538 (emit_mode_size): Change the type of mode_size from unsigned short
34539 to poly_uint16_pod. Use ZERO_COEFFS for the initializer.
34540 (emit_mode_adjustments): Cope with polynomial vector sizes.
34541 * lto-streamer-in.c (lto_input_mode_table): Use bp_unpack_poly_value
34542 for GET_MODE_SIZE.
34543 * lto-streamer-out.c (lto_write_mode_table): Use bp_pack_poly_value
34544 for GET_MODE_SIZE.
34545 * auto-inc-dec.c (try_merge): Treat GET_MODE_SIZE as polynomial.
34546 * builtins.c (expand_ifn_atomic_compare_exchange_into_call): Likewise.
34547 * caller-save.c (setup_save_areas): Likewise.
34548 (replace_reg_with_saved_mem): Likewise.
34549 * calls.c (emit_library_call_value_1): Likewise.
34550 * combine-stack-adj.c (combine_stack_adjustments_for_block): Likewise.
34551 * combine.c (simplify_set, make_extraction, simplify_shift_const_1)
34552 (gen_lowpart_for_combine): Likewise.
34553 * convert.c (convert_to_integer_1): Likewise.
34554 * cse.c (equiv_constant, cse_insn): Likewise.
34555 * cselib.c (autoinc_split, cselib_hash_rtx): Likewise.
34556 (cselib_subst_to_values): Likewise.
34557 * dce.c (word_dce_process_block): Likewise.
34558 * df-problems.c (df_word_lr_mark_ref): Likewise.
34559 * dwarf2cfi.c (init_one_dwarf_reg_size): Likewise.
34560 * dwarf2out.c (multiple_reg_loc_descriptor, mem_loc_descriptor)
34561 (concat_loc_descriptor, concatn_loc_descriptor, loc_descriptor)
34562 (rtl_for_decl_location): Likewise.
34563 * emit-rtl.c (gen_highpart, widen_memory_access): Likewise.
34564 * expmed.c (extract_bit_field_1, extract_integral_bit_field): Likewise.
34565 * expr.c (emit_group_load_1, clear_storage_hints): Likewise.
34566 (emit_move_complex, emit_move_multi_word, emit_push_insn): Likewise.
34567 (expand_expr_real_1): Likewise.
34568 * function.c (assign_parm_setup_block_p, assign_parm_setup_block)
34569 (pad_below): Likewise.
34570 * gimple-fold.c (optimize_atomic_compare_exchange_p): Likewise.
34571 * gimple-ssa-store-merging.c (rhs_valid_for_store_merging_p): Likewise.
34572 * ira.c (get_subreg_tracking_sizes): Likewise.
34573 * ira-build.c (ira_create_allocno_objects): Likewise.
34574 * ira-color.c (coalesced_pseudo_reg_slot_compare): Likewise.
34575 (ira_sort_regnos_for_alter_reg): Likewise.
34576 * ira-costs.c (record_operand_costs): Likewise.
34577 * lower-subreg.c (interesting_mode_p, simplify_gen_subreg_concatn)
34578 (resolve_simple_move): Likewise.
34579 * lra-constraints.c (get_reload_reg, operands_match_p): Likewise.
34580 (process_addr_reg, simplify_operand_subreg, curr_insn_transform)
34581 (lra_constraints): Likewise.
34582 (CONST_POOL_OK_P): Reject variable-sized modes.
34583 * lra-spills.c (slot, assign_mem_slot, pseudo_reg_slot_compare)
34584 (add_pseudo_to_slot, lra_spill): Likewise.
34585 * omp-low.c (omp_clause_aligned_alignment): Likewise.
34586 * optabs-query.c (get_best_extraction_insn): Likewise.
34587 * optabs-tree.c (expand_vec_cond_expr_p): Likewise.
34588 * optabs.c (expand_vec_perm_var, expand_vec_cond_expr): Likewise.
34589 (expand_mult_highpart, valid_multiword_target_p): Likewise.
34590 * recog.c (offsettable_address_addr_space_p): Likewise.
34591 * regcprop.c (maybe_mode_change): Likewise.
34592 * reginfo.c (choose_hard_reg_mode, record_subregs_of_mode): Likewise.
34593 * regrename.c (build_def_use): Likewise.
34594 * regstat.c (dump_reg_info): Likewise.
34595 * reload.c (complex_word_subreg_p, push_reload, find_dummy_reload)
34596 (find_reloads, find_reloads_subreg_address): Likewise.
34597 * reload1.c (eliminate_regs_1): Likewise.
34598 * rtlanal.c (for_each_inc_dec_find_inc_dec, rtx_cost): Likewise.
34599 * simplify-rtx.c (avoid_constant_pool_reference): Likewise.
34600 (simplify_binary_operation_1, simplify_subreg): Likewise.
34601 * targhooks.c (default_function_arg_padding): Likewise.
34602 (default_hard_regno_nregs, default_class_max_nregs): Likewise.
34603 * tree-cfg.c (verify_gimple_assign_binary): Likewise.
34604 (verify_gimple_assign_ternary): Likewise.
34605 * tree-inline.c (estimate_move_cost): Likewise.
34606 * tree-ssa-forwprop.c (simplify_vector_constructor): Likewise.
34607 * tree-ssa-loop-ivopts.c (add_autoinc_candidates): Likewise.
34608 (get_address_cost_ainc): Likewise.
34609 * tree-vect-data-refs.c (vect_enhance_data_refs_alignment): Likewise.
34610 (vect_supportable_dr_alignment): Likewise.
34611 * tree-vect-loop.c (vect_determine_vectorization_factor): Likewise.
34612 (vectorizable_reduction): Likewise.
34613 * tree-vect-stmts.c (vectorizable_assignment, vectorizable_shift)
34614 (vectorizable_operation, vectorizable_load): Likewise.
34615 * tree.c (build_same_sized_truth_vector_type): Likewise.
34616 * valtrack.c (cleanup_auto_inc_dec): Likewise.
34617 * var-tracking.c (emit_note_insn_var_location): Likewise.
34618 * config/arc/arc.h (ASM_OUTPUT_CASE_END): Use as_a <scalar_int_mode>.
34619 (ADDR_VEC_ALIGN): Likewise.
34620
34621 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34622 Alan Hayward <alan.hayward@arm.com>
34623 David Sherwood <david.sherwood@arm.com>
34624
34625 * machmode.h (mode_to_bits): Return a poly_uint16 rather than an
34626 unsigned short.
34627 (GET_MODE_BITSIZE): Return a constant if ONLY_FIXED_SIZE_MODES,
34628 or if measurement_type is polynomial.
34629 * calls.c (shift_return_value): Treat GET_MODE_BITSIZE as polynomial.
34630 * combine.c (make_extraction): Likewise.
34631 * dse.c (find_shift_sequence): Likewise.
34632 * dwarf2out.c (mem_loc_descriptor): Likewise.
34633 * expmed.c (store_integral_bit_field, extract_bit_field_1): Likewise.
34634 (extract_bit_field, extract_low_bits): Likewise.
34635 * expr.c (convert_move, convert_modes, emit_move_insn_1): Likewise.
34636 (optimize_bitfield_assignment_op, expand_assignment): Likewise.
34637 (store_expr_with_bounds, store_field, expand_expr_real_1): Likewise.
34638 * fold-const.c (optimize_bit_field_compare, merge_ranges): Likewise.
34639 * gimple-fold.c (optimize_atomic_compare_exchange_p): Likewise.
34640 * reload.c (find_reloads): Likewise.
34641 * reload1.c (alter_reg): Likewise.
34642 * stor-layout.c (bitwise_mode_for_mode, compute_record_mode): Likewise.
34643 * targhooks.c (default_secondary_memory_needed_mode): Likewise.
34644 * tree-if-conv.c (predicate_mem_writes): Likewise.
34645 * tree-ssa-strlen.c (handle_builtin_memcmp): Likewise.
34646 * tree-vect-patterns.c (adjust_bool_pattern): Likewise.
34647 * tree-vect-stmts.c (vectorizable_simd_clone_call): Likewise.
34648 * valtrack.c (dead_debug_insert_temp): Likewise.
34649 * varasm.c (mergeable_constant_section): Likewise.
34650 * config/sh/sh.h (LOCAL_ALIGNMENT): Use as_a <fixed_size_mode>.
34651
34652 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34653 Alan Hayward <alan.hayward@arm.com>
34654 David Sherwood <david.sherwood@arm.com>
34655
34656 * expr.c (expand_assignment): Cope with polynomial mode sizes
34657 when assigning to a CONCAT.
34658
34659 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34660 Alan Hayward <alan.hayward@arm.com>
34661 David Sherwood <david.sherwood@arm.com>
34662
34663 * machmode.h (mode_precision): Change from unsigned short to
34664 poly_uint16_pod.
34665 (mode_to_precision): Return a poly_uint16 rather than an unsigned
34666 short.
34667 (GET_MODE_PRECISION): Return a constant if ONLY_FIXED_SIZE_MODES,
34668 or if measurement_type is not polynomial.
34669 (HWI_COMPUTABLE_MODE_P): Turn into a function. Optimize the case
34670 in which the mode is already known to be a scalar_int_mode.
34671 * genmodes.c (emit_mode_precision): Change the type of mode_precision
34672 from unsigned short to poly_uint16_pod. Use ZERO_COEFFS for the
34673 initializer.
34674 * lto-streamer-in.c (lto_input_mode_table): Use bp_unpack_poly_value
34675 for GET_MODE_PRECISION.
34676 * lto-streamer-out.c (lto_write_mode_table): Use bp_pack_poly_value
34677 for GET_MODE_PRECISION.
34678 * combine.c (update_rsp_from_reg_equal): Treat GET_MODE_PRECISION
34679 as polynomial.
34680 (try_combine, find_split_point, combine_simplify_rtx): Likewise.
34681 (expand_field_assignment, make_extraction): Likewise.
34682 (make_compound_operation_int, record_dead_and_set_regs_1): Likewise.
34683 (get_last_value): Likewise.
34684 * convert.c (convert_to_integer_1): Likewise.
34685 * cse.c (cse_insn): Likewise.
34686 * expr.c (expand_expr_real_1): Likewise.
34687 * lra-constraints.c (simplify_operand_subreg): Likewise.
34688 * optabs-query.c (can_atomic_load_p): Likewise.
34689 * optabs.c (expand_atomic_load): Likewise.
34690 (expand_atomic_store): Likewise.
34691 * ree.c (combine_reaching_defs): Likewise.
34692 * rtl.h (partial_subreg_p, paradoxical_subreg_p): Likewise.
34693 * rtlanal.c (nonzero_bits1, lsb_bitfield_op_p): Likewise.
34694 * tree.h (type_has_mode_precision_p): Likewise.
34695 * ubsan.c (instrument_si_overflow): Likewise.
34696
34697 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34698 Alan Hayward <alan.hayward@arm.com>
34699 David Sherwood <david.sherwood@arm.com>
34700
34701 * tree.h (TYPE_VECTOR_SUBPARTS): Turn into a function and handle
34702 polynomial numbers of units.
34703 (SET_TYPE_VECTOR_SUBPARTS): Likewise.
34704 (valid_vector_subparts_p): New function.
34705 (build_vector_type): Remove temporary shim and take the number
34706 of units as a poly_uint64 rather than an int.
34707 (build_opaque_vector_type): Take the number of units as a
34708 poly_uint64 rather than an int.
34709 * tree.c (build_vector_from_ctor): Handle polynomial
34710 TYPE_VECTOR_SUBPARTS.
34711 (type_hash_canon_hash, type_cache_hasher::equal): Likewise.
34712 (uniform_vector_p, vector_type_mode, build_vector): Likewise.
34713 (build_vector_from_val): If the number of units is variable,
34714 use build_vec_duplicate_cst for constant operands and
34715 VEC_DUPLICATE_EXPR otherwise.
34716 (make_vector_type): Remove temporary is_constant ().
34717 (build_vector_type, build_opaque_vector_type): Take the number of
34718 units as a poly_uint64 rather than an int.
34719 (check_vector_cst): Handle polynomial TYPE_VECTOR_SUBPARTS and
34720 VECTOR_CST_NELTS.
34721 * cfgexpand.c (expand_debug_expr): Likewise.
34722 * expr.c (count_type_elements, categorize_ctor_elements_1): Likewise.
34723 (store_constructor, expand_expr_real_1): Likewise.
34724 (const_scalar_mask_from_tree): Likewise.
34725 * fold-const-call.c (fold_const_reduction): Likewise.
34726 * fold-const.c (const_binop, const_unop, fold_convert_const): Likewise.
34727 (operand_equal_p, fold_vec_perm, fold_ternary_loc): Likewise.
34728 (native_encode_vector, vec_cst_ctor_to_array): Likewise.
34729 (fold_relational_const): Likewise.
34730 (native_interpret_vector): Likewise. Change the size from an
34731 int to an unsigned int.
34732 * gimple-fold.c (gimple_fold_stmt_to_constant_1): Handle polynomial
34733 TYPE_VECTOR_SUBPARTS.
34734 (gimple_fold_indirect_ref, gimple_build_vector): Likewise.
34735 (gimple_build_vector_from_val): Use VEC_DUPLICATE_EXPR when
34736 duplicating a non-constant operand into a variable-length vector.
34737 * hsa-brig.c (hsa_op_immed::emit_to_buffer): Handle polynomial
34738 TYPE_VECTOR_SUBPARTS and VECTOR_CST_NELTS.
34739 * ipa-icf.c (sem_variable::equals): Likewise.
34740 * match.pd: Likewise.
34741 * omp-simd-clone.c (simd_clone_subparts): Likewise.
34742 * print-tree.c (print_node): Likewise.
34743 * stor-layout.c (layout_type): Likewise.
34744 * targhooks.c (default_builtin_vectorization_cost): Likewise.
34745 * tree-cfg.c (verify_gimple_comparison): Likewise.
34746 (verify_gimple_assign_binary): Likewise.
34747 (verify_gimple_assign_ternary): Likewise.
34748 (verify_gimple_assign_single): Likewise.
34749 * tree-pretty-print.c (dump_generic_node): Likewise.
34750 * tree-ssa-forwprop.c (simplify_vector_constructor): Likewise.
34751 (simplify_bitfield_ref, is_combined_permutation_identity): Likewise.
34752 * tree-vect-data-refs.c (vect_permute_store_chain): Likewise.
34753 (vect_grouped_load_supported, vect_permute_load_chain): Likewise.
34754 (vect_shift_permute_load_chain): Likewise.
34755 * tree-vect-generic.c (nunits_for_known_piecewise_op): Likewise.
34756 (expand_vector_condition, optimize_vector_constructor): Likewise.
34757 (lower_vec_perm, get_compute_type): Likewise.
34758 * tree-vect-loop.c (vect_determine_vectorization_factor): Likewise.
34759 (get_initial_defs_for_reduction, vect_transform_loop): Likewise.
34760 * tree-vect-patterns.c (vect_recog_bool_pattern): Likewise.
34761 (vect_recog_mask_conversion_pattern): Likewise.
34762 * tree-vect-slp.c (vect_supported_load_permutation_p): Likewise.
34763 (vect_get_constant_vectors, vect_transform_slp_perm_load): Likewise.
34764 * tree-vect-stmts.c (perm_mask_for_reverse): Likewise.
34765 (get_group_load_store_type, vectorizable_mask_load_store): Likewise.
34766 (vectorizable_bswap, simd_clone_subparts, vectorizable_assignment)
34767 (vectorizable_shift, vectorizable_operation, vectorizable_store)
34768 (vectorizable_load, vect_is_simple_cond, vectorizable_comparison)
34769 (supportable_widening_operation): Likewise.
34770 (supportable_narrowing_operation): Likewise.
34771 * tree-vector-builder.c (tree_vector_builder::binary_encoded_nelts):
34772 Likewise.
34773 * varasm.c (output_constant): Likewise.
34774
34775 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34776 Alan Hayward <alan.hayward@arm.com>
34777 David Sherwood <david.sherwood@arm.com>
34778
34779 * tree-vect-data-refs.c (vect_permute_store_chain): Reorganize
34780 so that both the length == 3 and length != 3 cases set up their
34781 own permute vectors. Add comments explaining why we know the
34782 number of elements is constant.
34783 (vect_permute_load_chain): Likewise.
34784
34785 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34786 Alan Hayward <alan.hayward@arm.com>
34787 David Sherwood <david.sherwood@arm.com>
34788
34789 * machmode.h (mode_nunits): Change from unsigned char to
34790 poly_uint16_pod.
34791 (ONLY_FIXED_SIZE_MODES): New macro.
34792 (pod_mode::measurement_type, scalar_int_mode::measurement_type)
34793 (scalar_float_mode::measurement_type, scalar_mode::measurement_type)
34794 (complex_mode::measurement_type, fixed_size_mode::measurement_type):
34795 New typedefs.
34796 (mode_to_nunits): Return a poly_uint16 rather than an unsigned short.
34797 (GET_MODE_NUNITS): Return a constant if ONLY_FIXED_SIZE_MODES,
34798 or if measurement_type is not polynomial.
34799 * genmodes.c (ZERO_COEFFS): New macro.
34800 (emit_mode_nunits_inline): Make mode_nunits_inline return a
34801 poly_uint16.
34802 (emit_mode_nunits): Change the type of mode_nunits to poly_uint16_pod.
34803 Use ZERO_COEFFS when emitting initializers.
34804 * data-streamer.h (bp_pack_poly_value): New function.
34805 (bp_unpack_poly_value): Likewise.
34806 * lto-streamer-in.c (lto_input_mode_table): Use bp_unpack_poly_value
34807 for GET_MODE_NUNITS.
34808 * lto-streamer-out.c (lto_write_mode_table): Use bp_pack_poly_value
34809 for GET_MODE_NUNITS.
34810 * tree.c (make_vector_type): Remove temporary shim and make
34811 the real function take the number of units as a poly_uint64
34812 rather than an int.
34813 (build_vector_type_for_mode): Handle polynomial nunits.
34814 * dwarf2out.c (loc_descriptor, add_const_value_attribute): Likewise.
34815 * emit-rtl.c (const_vec_series_p_1): Likewise.
34816 (gen_rtx_CONST_VECTOR): Likewise.
34817 * fold-const.c (test_vec_duplicate_folding): Likewise.
34818 * genrecog.c (validate_pattern): Likewise.
34819 * optabs-query.c (can_vec_perm_var_p, can_mult_highpart_p): Likewise.
34820 * optabs-tree.c (expand_vec_cond_expr_p): Likewise.
34821 * optabs.c (expand_vector_broadcast, expand_binop_directly): Likewise.
34822 (shift_amt_for_vec_perm_mask, expand_vec_perm_var): Likewise.
34823 (expand_vec_cond_expr, expand_mult_highpart): Likewise.
34824 * rtlanal.c (subreg_get_info): Likewise.
34825 * tree-vect-data-refs.c (vect_grouped_store_supported): Likewise.
34826 (vect_grouped_load_supported): Likewise.
34827 * tree-vect-generic.c (type_for_widest_vector_mode): Likewise.
34828 * tree-vect-loop.c (have_whole_vector_shift): Likewise.
34829 * simplify-rtx.c (simplify_unary_operation_1): Likewise.
34830 (simplify_const_unary_operation, simplify_binary_operation_1)
34831 (simplify_const_binary_operation, simplify_ternary_operation)
34832 (test_vector_ops_duplicate, test_vector_ops): Likewise.
34833 (simplify_immed_subreg): Use GET_MODE_NUNITS on a fixed_size_mode
34834 instead of CONST_VECTOR_NUNITS.
34835 * varasm.c (output_constant_pool_2): Likewise.
34836 * rtx-vector-builder.c (rtx_vector_builder::build): Only include the
34837 explicit-encoded elements in the XVEC for variable-length vectors.
34838
34839 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34840
34841 * lra-constraints.c (curr_insn_transform): Use partial_subreg_p.
34842
34843 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34844 Alan Hayward <alan.hayward@arm.com>
34845 David Sherwood <david.sherwood@arm.com>
34846
34847 * coretypes.h (fixed_size_mode): Declare.
34848 (fixed_size_mode_pod): New typedef.
34849 * builtins.h (target_builtins::x_apply_args_mode)
34850 (target_builtins::x_apply_result_mode): Change type to
34851 fixed_size_mode_pod.
34852 * builtins.c (apply_args_size, apply_result_size, result_vector)
34853 (expand_builtin_apply_args_1, expand_builtin_apply)
34854 (expand_builtin_return): Update accordingly.
34855
34856 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34857
34858 * cse.c (hash_rtx_cb): Hash only the encoded elements.
34859 * cselib.c (cselib_hash_rtx): Likewise.
34860 * expmed.c (make_tree): Build VECTOR_CSTs directly from the
34861 CONST_VECTOR encoding.
34862
34863 2018-01-03 Jakub Jelinek <jakub@redhat.com>
34864 Jeff Law <law@redhat.com>
34865
34866 PR target/83641
34867 * config/i386/i386.c (ix86_adjust_stack_and_probe_stack_clash): For
34868 noreturn probe, use gen_pop instead of ix86_emit_restore_reg_using_pop,
34869 only set RTX_FRAME_RELATED_P on both the push and pop if cfa_reg is sp
34870 and add REG_CFA_ADJUST_CFA notes in that case to both insns.
34871
34872 PR target/83641
34873 * config/i386/i386.c (ix86_adjust_stack_and_probe_stack_clash): Do not
34874 explicitly probe *sp in a noreturn function if there were any callee
34875 register saves or frame pointer is needed.
34876
34877 2018-01-03 Jakub Jelinek <jakub@redhat.com>
34878
34879 PR debug/83621
34880 * cfgexpand.c (expand_debug_expr): Return NULL if mode is
34881 BLKmode for ternary, binary or unary expressions.
34882
34883 PR debug/83645
34884 * var-tracking.c (delete_vta_debug_insn): New inline function.
34885 (delete_vta_debug_insns): Add USE_CFG argument, if true, walk just
34886 insns from get_insns () to NULL instead of each bb separately.
34887 Use delete_vta_debug_insn. No longer static.
34888 (vt_debug_insns_local, variable_tracking_main_1): Adjust
34889 delete_vta_debug_insns callers.
34890 * rtl.h (delete_vta_debug_insns): Declare.
34891 * final.c (rest_of_handle_final): Call delete_vta_debug_insns
34892 instead of variable_tracking_main.
34893
34894 2018-01-03 Martin Sebor <msebor@redhat.com>
34895
34896 PR tree-optimization/83603
34897 * calls.c (maybe_warn_nonstring_arg): Avoid accessing function
34898 arguments past the endof the argument list in functions declared
34899 without a prototype.
34900 * gimple-ssa-warn-restrict.c (wrestrict_dom_walker::check_call):
34901 Avoid checking when arguments are null.
34902
34903 2018-01-03 Martin Sebor <msebor@redhat.com>
34904
34905 PR c/83559
34906 * doc/extend.texi (attribute const): Fix a typo.
34907 * ipa-pure-const.c ((warn_function_const, warn_function_pure): Avoid
34908 issuing -Wsuggest-attribute for void functions.
34909
34910 2018-01-03 Martin Sebor <msebor@redhat.com>
34911
34912 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): Use
34913 offset_int::from instead of wide_int::to_shwi.
34914 (maybe_diag_overlap): Remove assertion.
34915 Use HOST_WIDE_INT_PRINT_DEC instead of %lli.
34916 * gimple-ssa-sprintf.c (format_directive): Same.
34917 (parse_directive): Same.
34918 (sprintf_dom_walker::compute_format_length): Same.
34919 (try_substitute_return_value): Same.
34920
34921 2018-01-03 Jeff Law <law@redhat.com>
34922
34923 PR middle-end/83654
34924 * explow.c (anti_adjust_stack_and_probe_stack_clash): Test a
34925 non-constant residual for zero at runtime and avoid probing in
34926 that case. Reorganize code for trailing problem to mirror handling
34927 of the residual.
34928
34929 2018-01-03 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
34930
34931 PR tree-optimization/83501
34932 * tree-ssa-strlen.c (get_string_cst): New.
34933 (handle_char_store): Call get_string_cst.
34934
34935 2018-01-03 Martin Liska <mliska@suse.cz>
34936
34937 PR tree-optimization/83593
34938 * tree-ssa-strlen.c: Include tree-cfg.h.
34939 (strlen_check_and_optimize_stmt): Add new argument cleanup_eh.
34940 (strlen_dom_walker): Add new member variable m_cleanup_cfg.
34941 (strlen_dom_walker::strlen_dom_walker): Initialize m_cleanup_cfg
34942 to false.
34943 (strlen_dom_walker::before_dom_children): Call
34944 gimple_purge_dead_eh_edges. Dump tranformation with details
34945 dump flags.
34946 (strlen_dom_walker::before_dom_children): Update call by adding
34947 new argument cleanup_eh.
34948 (pass_strlen::execute): Return TODO_cleanup_cfg if needed.
34949
34950 2018-01-03 Martin Liska <mliska@suse.cz>
34951
34952 PR ipa/83549
34953 * cif-code.def (VARIADIC_THUNK): New enum value.
34954 * ipa-fnsummary.c (compute_fn_summary): Do not inline variadic
34955 thunks.
34956
34957 2018-01-03 Jan Beulich <jbeulich@suse.com>
34958
34959 * sse.md (mov<mode>_internal): Tighten condition for when to use
34960 vmovdqu<ssescalarsize> for TI and OI modes.
34961
34962 2018-01-03 Jakub Jelinek <jakub@redhat.com>
34963
34964 Update copyright years.
34965
34966 2018-01-03 Martin Liska <mliska@suse.cz>
34967
34968 PR ipa/83594
34969 * ipa-visibility.c (function_and_variable_visibility): Skip
34970 functions with noipa attribure.
34971
34972 2018-01-03 Jakub Jelinek <jakub@redhat.com>
34973
34974 * gcc.c (process_command): Update copyright notice dates.
34975 * gcov-dump.c (print_version): Ditto.
34976 * gcov.c (print_version): Ditto.
34977 * gcov-tool.c (print_version): Ditto.
34978 * gengtype.c (create_file): Ditto.
34979 * doc/cpp.texi: Bump @copying's copyright year.
34980 * doc/cppinternals.texi: Ditto.
34981 * doc/gcc.texi: Ditto.
34982 * doc/gccint.texi: Ditto.
34983 * doc/gcov.texi: Ditto.
34984 * doc/install.texi: Ditto.
34985 * doc/invoke.texi: Ditto.
34986
34987 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34988
34989 * vector-builder.h (vector_builder::m_full_nelts): Change from
34990 unsigned int to poly_uint64.
34991 (vector_builder::full_nelts): Update prototype accordingly.
34992 (vector_builder::new_vector): Likewise.
34993 (vector_builder::encoded_full_vector_p): Handle polynomial full_nelts.
34994 (vector_builder::operator ==): Likewise.
34995 (vector_builder::finalize): Likewise.
34996 * int-vector-builder.h (int_vector_builder::int_vector_builder):
34997 Take the number of elements as a poly_uint64 rather than an
34998 unsigned int.
34999 * vec-perm-indices.h (vec_perm_indices::m_nelts_per_input): Change
35000 from unsigned int to poly_uint64.
35001 (vec_perm_indices::vec_perm_indices): Update prototype accordingly.
35002 (vec_perm_indices::new_vector): Likewise.
35003 (vec_perm_indices::length): Likewise.
35004 (vec_perm_indices::nelts_per_input): Likewise.
35005 (vec_perm_indices::input_nelts): Likewise.
35006 * vec-perm-indices.c (vec_perm_indices::new_vector): Take the
35007 number of elements per input as a poly_uint64 rather than an
35008 unsigned int. Use the original encoding for variable-length
35009 vectors, rather than clamping each individual element.
35010 For the second and subsequent elements in each pattern,
35011 clamp the step and base before clamping their sum.
35012 (vec_perm_indices::series_p): Handle polynomial element counts.
35013 (vec_perm_indices::all_in_range_p): Likewise.
35014 (vec_perm_indices_to_tree): Likewise.
35015 (vec_perm_indices_to_rtx): Likewise.
35016 * tree-vect-stmts.c (vect_gen_perm_mask_any): Likewise.
35017 * tree-vector-builder.c (tree_vector_builder::new_unary_operation)
35018 (tree_vector_builder::new_binary_operation): Handle polynomial
35019 element counts. Return false if we need to know the number
35020 of elements at compile time.
35021 * fold-const.c (fold_vec_perm): Punt if the number of elements
35022 isn't known at compile time.
35023
35024 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35025
35026 * vec-perm-indices.h (vec_perm_builder): Change element type
35027 from HOST_WIDE_INT to poly_int64.
35028 (vec_perm_indices::element_type): Update accordingly.
35029 (vec_perm_indices::clamp): Handle polynomial element_types.
35030 * vec-perm-indices.c (vec_perm_indices::series_p): Likewise.
35031 (vec_perm_indices::all_in_range_p): Likewise.
35032 (tree_to_vec_perm_builder): Check for poly_int64 trees rather
35033 than shwi trees.
35034 * vector-builder.h (vector_builder::stepped_sequence_p): Handle
35035 polynomial vec_perm_indices element types.
35036 * int-vector-builder.h (int_vector_builder::equal_p): Likewise.
35037 * fold-const.c (fold_vec_perm): Likewise.
35038 * optabs.c (shift_amt_for_vec_perm_mask): Likewise.
35039 * tree-vect-generic.c (lower_vec_perm): Likewise.
35040 * tree-vect-slp.c (vect_transform_slp_perm_load): Likewise.
35041 * config/aarch64/aarch64.c (aarch64_evpc_tbl): Cast d->perm
35042 element type to HOST_WIDE_INT.
35043
35044 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35045 Alan Hayward <alan.hayward@arm.com>
35046 David Sherwood <david.sherwood@arm.com>
35047
35048 * alias.c (addr_side_effect_eval): Take the size as a poly_int64
35049 rather than an int. Use plus_constant.
35050 (memrefs_conflict_p): Take the sizes as poly_int64s rather than ints.
35051 Take the offset "c" as a poly_int64 rather than a HOST_WIDE_INT.
35052
35053 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35054 Alan Hayward <alan.hayward@arm.com>
35055 David Sherwood <david.sherwood@arm.com>
35056
35057 * calls.c (emit_call_1, expand_call): Change struct_value_size from
35058 a HOST_WIDE_INT to a poly_int64.
35059
35060 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35061 Alan Hayward <alan.hayward@arm.com>
35062 David Sherwood <david.sherwood@arm.com>
35063
35064 * calls.c (load_register_parameters): Cope with polynomial
35065 mode sizes. Require a constant size for BLKmode parameters
35066 that aren't described by a PARALLEL. If BLOCK_REG_PADDING
35067 forces a parameter to be padded at the lsb end in order to
35068 fill a complete number of words, require the parameter size
35069 to be ordered wrt UNITS_PER_WORD.
35070
35071 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35072 Alan Hayward <alan.hayward@arm.com>
35073 David Sherwood <david.sherwood@arm.com>
35074
35075 * reload1.c (spill_stack_slot_width): Change element type
35076 from unsigned int to poly_uint64_pod.
35077 (alter_reg): Treat mode sizes as polynomial.
35078
35079 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35080 Alan Hayward <alan.hayward@arm.com>
35081 David Sherwood <david.sherwood@arm.com>
35082
35083 * reload.c (complex_word_subreg_p): New function.
35084 (reload_inner_reg_of_subreg, push_reload): Use it.
35085
35086 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35087 Alan Hayward <alan.hayward@arm.com>
35088 David Sherwood <david.sherwood@arm.com>
35089
35090 * lra-constraints.c (process_alt_operands): Reject matched
35091 operands whose sizes aren't ordered.
35092 (match_reload): Refer to this check here.
35093
35094 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35095 Alan Hayward <alan.hayward@arm.com>
35096 David Sherwood <david.sherwood@arm.com>
35097
35098 * builtins.c (expand_ifn_atomic_compare_exchange_into_call): Assert
35099 that the mode size is in the set {1, 2, 4, 8, 16}.
35100
35101 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35102 Alan Hayward <alan.hayward@arm.com>
35103 David Sherwood <david.sherwood@arm.com>
35104
35105 * var-tracking.c (adjust_mems): Treat mode sizes as polynomial.
35106 Use plus_constant instead of gen_rtx_PLUS.
35107
35108 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35109 Alan Hayward <alan.hayward@arm.com>
35110 David Sherwood <david.sherwood@arm.com>
35111
35112 * config/cr16/cr16-protos.h (cr16_push_rounding): Declare.
35113 * config/cr16/cr16.h (PUSH_ROUNDING): Move implementation to...
35114 * config/cr16/cr16.c (cr16_push_rounding): ...this new function.
35115 * config/h8300/h8300-protos.h (h8300_push_rounding): Declare.
35116 * config/h8300/h8300.h (PUSH_ROUNDING): Move implementation to...
35117 * config/h8300/h8300.c (h8300_push_rounding): ...this new function.
35118 * config/i386/i386-protos.h (ix86_push_rounding): Declare.
35119 * config/i386/i386.h (PUSH_ROUNDING): Move implementation to...
35120 * config/i386/i386.c (ix86_push_rounding): ...this new function.
35121 * config/m32c/m32c-protos.h (m32c_push_rounding): Take and return
35122 a poly_int64.
35123 * config/m32c/m32c.c (m32c_push_rounding): Likewise.
35124 * config/m68k/m68k-protos.h (m68k_push_rounding): Declare.
35125 * config/m68k/m68k.h (PUSH_ROUNDING): Move implementation to...
35126 * config/m68k/m68k.c (m68k_push_rounding): ...this new function.
35127 * config/pdp11/pdp11-protos.h (pdp11_push_rounding): Declare.
35128 * config/pdp11/pdp11.h (PUSH_ROUNDING): Move implementation to...
35129 * config/pdp11/pdp11.c (pdp11_push_rounding): ...this new function.
35130 * config/stormy16/stormy16-protos.h (xstormy16_push_rounding): Declare.
35131 * config/stormy16/stormy16.h (PUSH_ROUNDING): Move implementation to...
35132 * config/stormy16/stormy16.c (xstormy16_push_rounding): ...this new
35133 function.
35134 * expr.c (emit_move_resolve_push): Treat the input and result
35135 of PUSH_ROUNDING as a poly_int64.
35136 (emit_move_complex_push, emit_single_push_insn_1): Likewise.
35137 (emit_push_insn): Likewise.
35138 * lra-eliminations.c (mark_not_eliminable): Likewise.
35139 * recog.c (push_operand): Likewise.
35140 * reload1.c (elimination_effects): Likewise.
35141 * rtlanal.c (nonzero_bits1): Likewise.
35142 * calls.c (store_one_arg): Likewise. Require the padding to be
35143 known at compile time.
35144
35145 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35146 Alan Hayward <alan.hayward@arm.com>
35147 David Sherwood <david.sherwood@arm.com>
35148
35149 * expr.c (emit_single_push_insn_1): Treat mode sizes as polynomial.
35150 Use plus_constant instead of gen_rtx_PLUS.
35151
35152 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35153 Alan Hayward <alan.hayward@arm.com>
35154 David Sherwood <david.sherwood@arm.com>
35155
35156 * auto-inc-dec.c (set_inc_state): Take the mode size as a poly_int64
35157 rather than an int.
35158
35159 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35160 Alan Hayward <alan.hayward@arm.com>
35161 David Sherwood <david.sherwood@arm.com>
35162
35163 * expr.c (expand_expr_real_1): Use tree_to_poly_uint64
35164 instead of int_size_in_bytes when handling VIEW_CONVERT_EXPRs
35165 via stack temporaries. Treat the mode size as polynomial too.
35166
35167 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35168 Alan Hayward <alan.hayward@arm.com>
35169 David Sherwood <david.sherwood@arm.com>
35170
35171 * expr.c (expand_expr_real_2): When handling conversions involving
35172 unions, apply tree_to_poly_uint64 to the TYPE_SIZE rather than
35173 multiplying int_size_in_bytes by BITS_PER_UNIT. Treat GET_MODE_BISIZE
35174 as a poly_uint64 too.
35175
35176 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35177 Alan Hayward <alan.hayward@arm.com>
35178 David Sherwood <david.sherwood@arm.com>
35179
35180 * rtlanal.c (subreg_get_info): Handle polynomial mode sizes.
35181
35182 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35183 Alan Hayward <alan.hayward@arm.com>
35184 David Sherwood <david.sherwood@arm.com>
35185
35186 * combine.c (can_change_dest_mode): Handle polynomial
35187 REGMODE_NATURAL_SIZE.
35188 * expmed.c (store_bit_field_1): Likewise.
35189 * expr.c (store_constructor): Likewise.
35190 * emit-rtl.c (validate_subreg): Operate on polynomial mode sizes
35191 and polynomial REGMODE_NATURAL_SIZE.
35192 (gen_lowpart_common): Likewise.
35193 * reginfo.c (record_subregs_of_mode): Likewise.
35194 * rtlanal.c (read_modify_subreg_p): Likewise.
35195
35196 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35197 Alan Hayward <alan.hayward@arm.com>
35198 David Sherwood <david.sherwood@arm.com>
35199
35200 * internal-fn.c (expand_vector_ubsan_overflow): Handle polynomial
35201 numbers of elements.
35202
35203 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35204 Alan Hayward <alan.hayward@arm.com>
35205 David Sherwood <david.sherwood@arm.com>
35206
35207 * match.pd: Cope with polynomial numbers of vector elements.
35208
35209 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35210 Alan Hayward <alan.hayward@arm.com>
35211 David Sherwood <david.sherwood@arm.com>
35212
35213 * fold-const.c (fold_indirect_ref_1): Handle polynomial offsets
35214 in a POINTER_PLUS_EXPR.
35215
35216 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35217 Alan Hayward <alan.hayward@arm.com>
35218 David Sherwood <david.sherwood@arm.com>
35219
35220 * omp-simd-clone.c (simd_clone_subparts): New function.
35221 (simd_clone_init_simd_arrays): Use it instead of TYPE_VECTOR_SUBPARTS.
35222 (ipa_simd_modify_function_body): Likewise.
35223
35224 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35225 Alan Hayward <alan.hayward@arm.com>
35226 David Sherwood <david.sherwood@arm.com>
35227
35228 * tree-vect-generic.c (nunits_for_known_piecewise_op): New function.
35229 (expand_vector_piecewise): Use it instead of TYPE_VECTOR_SUBPARTS.
35230 (expand_vector_addition, add_rshift, expand_vector_divmod): Likewise.
35231 (expand_vector_condition, vector_element): Likewise.
35232 (subparts_gt): New function.
35233 (get_compute_type): Use subparts_gt.
35234 (count_type_subparts): Delete.
35235 (expand_vector_operations_1): Use subparts_gt instead of
35236 count_type_subparts.
35237
35238 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35239 Alan Hayward <alan.hayward@arm.com>
35240 David Sherwood <david.sherwood@arm.com>
35241
35242 * tree-vect-data-refs.c (vect_no_alias_p): Replace with...
35243 (vect_compile_time_alias): ...this new function. Do the calculation
35244 on poly_ints rather than trees.
35245 (vect_prune_runtime_alias_test_list): Update call accordingly.
35246
35247 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35248 Alan Hayward <alan.hayward@arm.com>
35249 David Sherwood <david.sherwood@arm.com>
35250
35251 * tree-vect-slp.c (vect_build_slp_tree_1): Handle polynomial
35252 numbers of units.
35253 (vect_schedule_slp_instance): Likewise.
35254
35255 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35256 Alan Hayward <alan.hayward@arm.com>
35257 David Sherwood <david.sherwood@arm.com>
35258
35259 * tree-vect-slp.c (vect_get_and_check_slp_defs): Reject
35260 constant and extern definitions for variable-length vectors.
35261 (vect_get_constant_vectors): Note that the number of units
35262 is known to be constant.
35263
35264 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35265 Alan Hayward <alan.hayward@arm.com>
35266 David Sherwood <david.sherwood@arm.com>
35267
35268 * tree-vect-stmts.c (vectorizable_conversion): Treat the number
35269 of units as polynomial. Choose between WIDE and NARROW based
35270 on multiple_p.
35271
35272 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35273 Alan Hayward <alan.hayward@arm.com>
35274 David Sherwood <david.sherwood@arm.com>
35275
35276 * tree-vect-stmts.c (simd_clone_subparts): New function.
35277 (vectorizable_simd_clone_call): Use it instead of TYPE_VECTOR_SUBPARTS.
35278
35279 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35280 Alan Hayward <alan.hayward@arm.com>
35281 David Sherwood <david.sherwood@arm.com>
35282
35283 * tree-vect-stmts.c (vectorizable_call): Treat the number of
35284 vectors as polynomial. Use build_index_vector for
35285 IFN_GOMP_SIMD_LANE.
35286
35287 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35288 Alan Hayward <alan.hayward@arm.com>
35289 David Sherwood <david.sherwood@arm.com>
35290
35291 * tree-vect-stmts.c (get_load_store_type): Treat the number of
35292 units as polynomial. Reject VMAT_ELEMENTWISE and VMAT_STRIDED_SLP
35293 for variable-length vectors.
35294 (vectorizable_mask_load_store): Treat the number of units as
35295 polynomial, asserting that it is constant if the condition has
35296 already been enforced.
35297 (vectorizable_store, vectorizable_load): Likewise.
35298
35299 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35300 Alan Hayward <alan.hayward@arm.com>
35301 David Sherwood <david.sherwood@arm.com>
35302
35303 * tree-vect-loop.c (vectorizable_live_operation): Treat the number
35304 of units as polynomial. Punt if we can't tell at compile time
35305 which vector contains the final result.
35306
35307 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35308 Alan Hayward <alan.hayward@arm.com>
35309 David Sherwood <david.sherwood@arm.com>
35310
35311 * tree-vect-loop.c (vectorizable_induction): Treat the number
35312 of units as polynomial. Punt on SLP inductions. Use an integer
35313 VEC_SERIES_EXPR for variable-length integer reductions. Use a
35314 cast of such a series for variable-length floating-point
35315 reductions.
35316
35317 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35318 Alan Hayward <alan.hayward@arm.com>
35319 David Sherwood <david.sherwood@arm.com>
35320
35321 * tree.h (build_index_vector): Declare.
35322 * tree.c (build_index_vector): New function.
35323 * tree-vect-loop.c (get_initial_defs_for_reduction): Treat the number
35324 of units as polynomial, forcibly converting it to a constant if
35325 vectorizable_reduction has already enforced the condition.
35326 (vect_create_epilog_for_reduction): Likewise. Use build_index_vector
35327 to create a {1,2,3,...} vector.
35328 (vectorizable_reduction): Treat the number of units as polynomial.
35329 Choose vectype_in based on the largest scalar element size rather
35330 than the smallest number of units. Enforce the restrictions
35331 relied on above.
35332
35333 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35334 Alan Hayward <alan.hayward@arm.com>
35335 David Sherwood <david.sherwood@arm.com>
35336
35337 * tree-vect-data-refs.c (vector_alignment_reachable_p): Treat the
35338 number of units as polynomial.
35339
35340 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35341 Alan Hayward <alan.hayward@arm.com>
35342 David Sherwood <david.sherwood@arm.com>
35343
35344 * target.h (vector_sizes, auto_vector_sizes): New typedefs.
35345 * target.def (autovectorize_vector_sizes): Return the vector sizes
35346 by pointer, using vector_sizes rather than a bitmask.
35347 * targhooks.h (default_autovectorize_vector_sizes): Update accordingly.
35348 * targhooks.c (default_autovectorize_vector_sizes): Likewise.
35349 * config/aarch64/aarch64.c (aarch64_autovectorize_vector_sizes):
35350 Likewise.
35351 * config/arc/arc.c (arc_autovectorize_vector_sizes): Likewise.
35352 * config/arm/arm.c (arm_autovectorize_vector_sizes): Likewise.
35353 * config/i386/i386.c (ix86_autovectorize_vector_sizes): Likewise.
35354 * config/mips/mips.c (mips_autovectorize_vector_sizes): Likewise.
35355 * omp-general.c (omp_max_vf): Likewise.
35356 * omp-low.c (omp_clause_aligned_alignment): Likewise.
35357 * optabs-query.c (can_vec_mask_load_store_p): Likewise.
35358 * tree-vect-loop.c (vect_analyze_loop): Likewise.
35359 * tree-vect-slp.c (vect_slp_bb): Likewise.
35360 * doc/tm.texi: Regenerate.
35361 * tree-vectorizer.h (current_vector_size): Change from an unsigned int
35362 to a poly_uint64.
35363 * tree-vect-stmts.c (get_vectype_for_scalar_type_and_size): Take
35364 the vector size as a poly_uint64 rather than an unsigned int.
35365 (current_vector_size): Change from an unsigned int to a poly_uint64.
35366 (get_vectype_for_scalar_type): Update accordingly.
35367 * tree.h (build_truth_vector_type): Take the size and number of
35368 units as a poly_uint64 rather than an unsigned int.
35369 (build_vector_type): Add a temporary overload that takes
35370 the number of units as a poly_uint64 rather than an unsigned int.
35371 * tree.c (make_vector_type): Likewise.
35372 (build_truth_vector_type): Take the number of units as a poly_uint64
35373 rather than an unsigned int.
35374
35375 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35376 Alan Hayward <alan.hayward@arm.com>
35377 David Sherwood <david.sherwood@arm.com>
35378
35379 * target.def (get_mask_mode): Take the number of units and length
35380 as poly_uint64s rather than unsigned ints.
35381 * targhooks.h (default_get_mask_mode): Update accordingly.
35382 * targhooks.c (default_get_mask_mode): Likewise.
35383 * config/i386/i386.c (ix86_get_mask_mode): Likewise.
35384 * doc/tm.texi: Regenerate.
35385
35386 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35387 Alan Hayward <alan.hayward@arm.com>
35388 David Sherwood <david.sherwood@arm.com>
35389
35390 * omp-general.h (omp_max_vf): Return a poly_uint64 instead of an int.
35391 * omp-general.c (omp_max_vf): Likewise.
35392 * omp-expand.c (omp_adjust_chunk_size): Update call to omp_max_vf.
35393 (expand_omp_simd): Handle polynomial safelen.
35394 * omp-low.c (omplow_simd_context): Add a default constructor.
35395 (omplow_simd_context::max_vf): Change from int to poly_uint64.
35396 (lower_rec_simd_input_clauses): Update accordingly.
35397 (lower_rec_input_clauses): Likewise.
35398
35399 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35400 Alan Hayward <alan.hayward@arm.com>
35401 David Sherwood <david.sherwood@arm.com>
35402
35403 * tree-vectorizer.h (vect_nunits_for_cost): New function.
35404 * tree-vect-loop.c (vect_model_reduction_cost): Use it.
35405 * tree-vect-slp.c (vect_analyze_slp_cost_1): Likewise.
35406 (vect_analyze_slp_cost): Likewise.
35407 * tree-vect-stmts.c (vect_model_store_cost): Likewise.
35408 (vect_model_load_cost): Likewise.
35409
35410 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35411 Alan Hayward <alan.hayward@arm.com>
35412 David Sherwood <david.sherwood@arm.com>
35413
35414 * tree-vect-slp.c (vect_record_max_nunits, vect_build_slp_tree_1)
35415 (vect_build_slp_tree_2, vect_build_slp_tree): Change max_nunits
35416 from an unsigned int * to a poly_uint64_pod *.
35417 (calculate_unrolling_factor): New function.
35418 (vect_analyze_slp_instance): Use it. Track polynomial max_nunits.
35419
35420 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35421 Alan Hayward <alan.hayward@arm.com>
35422 David Sherwood <david.sherwood@arm.com>
35423
35424 * tree-vectorizer.h (_slp_instance::unrolling_factor): Change
35425 from an unsigned int to a poly_uint64.
35426 (_loop_vec_info::slp_unrolling_factor): Likewise.
35427 (_loop_vec_info::vectorization_factor): Change from an int
35428 to a poly_uint64.
35429 (MAX_VECTORIZATION_FACTOR): Bump from 64 to INT_MAX.
35430 (vect_get_num_vectors): New function.
35431 (vect_update_max_nunits, vect_vf_for_cost): Likewise.
35432 (vect_get_num_copies): Use vect_get_num_vectors.
35433 (vect_analyze_data_ref_dependences): Change max_vf from an int *
35434 to an unsigned int *.
35435 (vect_analyze_data_refs): Change min_vf from an int * to a
35436 poly_uint64 *.
35437 (vect_transform_slp_perm_load): Take the vf as a poly_uint64 rather
35438 than an unsigned HOST_WIDE_INT.
35439 * tree-vect-data-refs.c (vect_analyze_possibly_independent_ddr)
35440 (vect_analyze_data_ref_dependence): Change max_vf from an int *
35441 to an unsigned int *.
35442 (vect_analyze_data_ref_dependences): Likewise.
35443 (vect_compute_data_ref_alignment): Handle polynomial vf.
35444 (vect_enhance_data_refs_alignment): Likewise.
35445 (vect_prune_runtime_alias_test_list): Likewise.
35446 (vect_shift_permute_load_chain): Likewise.
35447 (vect_supportable_dr_alignment): Likewise.
35448 (dependence_distance_ge_vf): Take the vectorization factor as a
35449 poly_uint64 rather than an unsigned HOST_WIDE_INT.
35450 (vect_analyze_data_refs): Change min_vf from an int * to a
35451 poly_uint64 *.
35452 * tree-vect-loop-manip.c (vect_gen_scalar_loop_niters): Take
35453 vfm1 as a poly_uint64 rather than an int. Make the same change
35454 for the returned bound_scalar.
35455 (vect_gen_vector_loop_niters): Handle polynomial vf.
35456 (vect_do_peeling): Likewise. Update call to
35457 vect_gen_scalar_loop_niters and handle polynomial bound_scalars.
35458 (vect_gen_vector_loop_niters_mult_vf): Assert that the vf must
35459 be constant.
35460 * tree-vect-loop.c (vect_determine_vectorization_factor)
35461 (vect_update_vf_for_slp, vect_analyze_loop_2): Handle polynomial vf.
35462 (vect_get_known_peeling_cost): Likewise.
35463 (vect_estimate_min_profitable_iters, vectorizable_reduction): Likewise.
35464 (vect_worthwhile_without_simd_p, vectorizable_induction): Likewise.
35465 (vect_transform_loop): Likewise. Use the lowest possible VF when
35466 updating the upper bounds of the loop.
35467 (vect_min_worthwhile_factor): Make static. Return an unsigned int
35468 rather than an int.
35469 * tree-vect-slp.c (vect_attempt_slp_rearrange_stmts): Cope with
35470 polynomial unroll factors.
35471 (vect_analyze_slp_cost_1, vect_analyze_slp_instance): Likewise.
35472 (vect_make_slp_decision): Likewise.
35473 (vect_supported_load_permutation_p): Likewise, and polynomial
35474 vf too.
35475 (vect_analyze_slp_cost): Handle polynomial vf.
35476 (vect_slp_analyze_node_operations): Likewise.
35477 (vect_slp_analyze_bb_1): Likewise.
35478 (vect_transform_slp_perm_load): Take the vf as a poly_uint64 rather
35479 than an unsigned HOST_WIDE_INT.
35480 * tree-vect-stmts.c (vectorizable_simd_clone_call, vectorizable_store)
35481 (vectorizable_load): Handle polynomial vf.
35482 * tree-vectorizer.c (simduid_to_vf::vf): Change from an int to
35483 a poly_uint64.
35484 (adjust_simduid_builtins, shrink_simd_arrays): Update accordingly.
35485
35486 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35487 Alan Hayward <alan.hayward@arm.com>
35488 David Sherwood <david.sherwood@arm.com>
35489
35490 * match.pd: Handle bit operations involving three constants
35491 and try to fold one pair.
35492
35493 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35494
35495 * tree-vect-loop-manip.c: Include gimple-fold.h.
35496 (slpeel_make_loop_iterate_ntimes): Add step, final_iv and
35497 niters_maybe_zero parameters. Handle other cases besides a step of 1.
35498 (vect_gen_vector_loop_niters): Add a step_vector_ptr parameter.
35499 Add a path that uses a step of VF instead of 1, but disable it
35500 for now.
35501 (vect_do_peeling): Add step_vector, niters_vector_mult_vf_var
35502 and niters_no_overflow parameters. Update calls to
35503 slpeel_make_loop_iterate_ntimes and vect_gen_vector_loop_niters.
35504 Create a new SSA name if the latter choses to use a ste other
35505 than zero, and return it via niters_vector_mult_vf_var.
35506 * tree-vect-loop.c (vect_transform_loop): Update calls to
35507 vect_do_peeling, vect_gen_vector_loop_niters and
35508 slpeel_make_loop_iterate_ntimes.
35509 * tree-vectorizer.h (slpeel_make_loop_iterate_ntimes, vect_do_peeling)
35510 (vect_gen_vector_loop_niters): Update declarations after above changes.
35511
35512 2018-01-02 Michael Meissner <meissner@linux.vnet.ibm.com>
35513
35514 * config/rs6000/rs6000.md (floor<mode>2): Add support for IEEE
35515 128-bit round to integer instructions.
35516 (ceil<mode>2): Likewise.
35517 (btrunc<mode>2): Likewise.
35518 (round<mode>2): Likewise.
35519
35520 2018-01-02 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
35521
35522 * config/rs6000/rs6000-string.c (expand_block_move): Allow the use of
35523 unaligned VSX load/store on P8/P9.
35524 (expand_block_clear): Allow the use of unaligned VSX
35525 load/store on P8/P9.
35526
35527 2018-01-02 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
35528
35529 * config/rs6000/rs6000-p8swap.c (swap_feeds_both_load_and_store):
35530 New function.
35531 (rs6000_analyze_swaps): Mark a web unoptimizable if it contains a
35532 swap associated with both a load and a store.
35533
35534 2018-01-02 Andrew Waterman <andrew@sifive.com>
35535
35536 * config/riscv/linux.h (ICACHE_FLUSH_FUNC): New.
35537 * config/riscv/riscv.md (clear_cache): Use it.
35538
35539 2018-01-02 Artyom Skrobov <tyomitch@gmail.com>
35540
35541 * web.c: Remove out-of-date comment.
35542
35543 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
35544
35545 * expr.c (fixup_args_size_notes): Check that any existing
35546 REG_ARGS_SIZE notes are correct, and don't try to re-add them.
35547 (emit_single_push_insn_1): Move stack_pointer_delta adjustment to...
35548 (emit_single_push_insn): ...here.
35549
35550 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
35551
35552 * rtl.h (CONST_VECTOR_ELT): Redefine to const_vector_elt.
35553 (const_vector_encoded_nelts): New function.
35554 (CONST_VECTOR_NUNITS): Redefine to use GET_MODE_NUNITS.
35555 (const_vector_int_elt, const_vector_elt): Declare.
35556 * emit-rtl.c (const_vector_int_elt_1): New function.
35557 (const_vector_elt): Likewise.
35558 * simplify-rtx.c (simplify_immed_subreg): Avoid taking the address
35559 of CONST_VECTOR_ELT.
35560
35561 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
35562
35563 * expr.c: Include rtx-vector-builder.h.
35564 (const_vector_mask_from_tree): Use rtx_vector_builder and operate
35565 directly on the tree encoding.
35566 (const_vector_from_tree): Likewise.
35567 * optabs.c: Include rtx-vector-builder.h.
35568 (expand_vec_perm_var): Use rtx_vector_builder and create a repeating
35569 sequence of "u" values.
35570 * vec-perm-indices.c: Include rtx-vector-builder.h.
35571 (vec_perm_indices_to_rtx): Use rtx_vector_builder and operate
35572 directly on the vec_perm_indices encoding.
35573
35574 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
35575
35576 * doc/rtl.texi (const_vector): Describe new encoding scheme.
35577 * Makefile.in (OBJS): Add rtx-vector-builder.o.
35578 * rtx-vector-builder.h: New file.
35579 * rtx-vector-builder.c: Likewise.
35580 * rtl.h (rtx_def::u2): Add a const_vector field.
35581 (CONST_VECTOR_NPATTERNS): New macro.
35582 (CONST_VECTOR_NELTS_PER_PATTERN): Likewise.
35583 (CONST_VECTOR_DUPLICATE_P): Likewise.
35584 (CONST_VECTOR_STEPPED_P): Likewise.
35585 (CONST_VECTOR_ENCODED_ELT): Likewise.
35586 (const_vec_duplicate_p): Check for a duplicated vector encoding.
35587 (unwrap_const_vec_duplicate): Likewise.
35588 (const_vec_series_p): Check for a non-duplicated vector encoding.
35589 Say that the function only returns true for integer vectors.
35590 * emit-rtl.c: Include rtx-vector-builder.h.
35591 (gen_const_vec_duplicate_1): Delete.
35592 (gen_const_vector): Call gen_const_vec_duplicate instead of
35593 gen_const_vec_duplicate_1.
35594 (const_vec_series_p_1): Operate directly on the CONST_VECTOR encoding.
35595 (gen_const_vec_duplicate): Use rtx_vector_builder.
35596 (gen_const_vec_series): Likewise.
35597 (gen_rtx_CONST_VECTOR): Likewise.
35598 * config/powerpcspe/powerpcspe.c: Include rtx-vector-builder.h.
35599 (swap_const_vector_halves): Take an rtx pointer rather than rtx.
35600 Build a new vector rather than modifying a CONST_VECTOR in-place.
35601 (handle_special_swappables): Update call accordingly.
35602 * config/rs6000/rs6000-p8swap.c: Include rtx-vector-builder.h.
35603 (swap_const_vector_halves): Take an rtx pointer rather than rtx.
35604 Build a new vector rather than modifying a CONST_VECTOR in-place.
35605 (handle_special_swappables): Update call accordingly.
35606
35607 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
35608
35609 * simplify-rtx.c (simplify_const_binary_operation): Use
35610 CONST_VECTOR_ELT instead of XVECEXP.
35611
35612 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
35613
35614 * tree-cfg.c (verify_gimple_assign_ternary): Allow the size of
35615 the selector elements to be different from the data elements
35616 if the selector is a VECTOR_CST.
35617 * tree-vect-stmts.c (vect_gen_perm_mask_any): Use a vector of
35618 ssizetype for the selector.
35619
35620 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
35621
35622 * optabs.c (shift_amt_for_vec_perm_mask): Try using series_p
35623 before testing each element individually.
35624 * tree-vect-generic.c (lower_vec_perm): Likewise.
35625
35626 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
35627
35628 * selftest.h (selftest::vec_perm_indices_c_tests): Declare.
35629 * selftest-run-tests.c (selftest::run_tests): Call it.
35630 * vector-builder.h (vector_builder::operator ==): New function.
35631 (vector_builder::operator !=): Likewise.
35632 * vec-perm-indices.h (vec_perm_indices::series_p): Declare.
35633 (vec_perm_indices::all_from_input_p): New function.
35634 * vec-perm-indices.c (vec_perm_indices::series_p): Likewise.
35635 (test_vec_perm_12, selftest::vec_perm_indices_c_tests): Likewise.
35636 * fold-const.c (fold_ternary_loc): Use tree_to_vec_perm_builder
35637 instead of reading the VECTOR_CST directly. Detect whether both
35638 vector inputs are the same before constructing the vec_perm_indices,
35639 and update the number of inputs argument accordingly. Use the
35640 utility functions added above. Only construct sel2 if we need to.
35641
35642 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
35643
35644 * optabs.c (expand_vec_perm_var): Use an explicit encoding for
35645 the broadcast of the low byte.
35646 (expand_mult_highpart): Use an explicit encoding for the permutes.
35647 * optabs-query.c (can_mult_highpart_p): Likewise.
35648 * tree-vect-loop.c (calc_vec_perm_mask_for_shift): Likewise.
35649 * tree-vect-stmts.c (perm_mask_for_reverse): Likewise.
35650 (vectorizable_bswap): Likewise.
35651 * tree-vect-data-refs.c (vect_grouped_store_supported): Use an
35652 explicit encoding for the power-of-2 permutes.
35653 (vect_permute_store_chain): Likewise.
35654 (vect_grouped_load_supported): Likewise.
35655 (vect_permute_load_chain): Likewise.
35656
35657 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
35658
35659 * vec-perm-indices.h (vec_perm_indices_to_tree): Declare.
35660 * vec-perm-indices.c (vec_perm_indices_to_tree): New function.
35661 * tree-ssa-forwprop.c (simplify_vector_constructor): Use it.
35662 * tree-vect-slp.c (vect_transform_slp_perm_load): Likewise.
35663 * tree-vect-stmts.c (vectorizable_bswap): Likewise.
35664 (vect_gen_perm_mask_any): Likewise.
35665
35666 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
35667
35668 * int-vector-builder.h: New file.
35669 * vec-perm-indices.h: Include int-vector-builder.h.
35670 (vec_perm_indices): Redefine as an int_vector_builder.
35671 (auto_vec_perm_indices): Delete.
35672 (vec_perm_builder): Redefine as a stand-alone class.
35673 (vec_perm_indices::vec_perm_indices): New function.
35674 (vec_perm_indices::clamp): Likewise.
35675 * vec-perm-indices.c: Include fold-const.h and tree-vector-builder.h.
35676 (vec_perm_indices::new_vector): New function.
35677 (vec_perm_indices::new_expanded_vector): Update for new
35678 vec_perm_indices class.
35679 (vec_perm_indices::rotate_inputs): New function.
35680 (vec_perm_indices::all_in_range_p): Operate directly on the
35681 encoded form, without computing elided elements.
35682 (tree_to_vec_perm_builder): Operate directly on the VECTOR_CST
35683 encoding. Update for new vec_perm_indices class.
35684 * optabs.c (expand_vec_perm_const): Create a vec_perm_indices for
35685 the given vec_perm_builder.
35686 (expand_vec_perm_var): Update vec_perm_builder constructor.
35687 (expand_mult_highpart): Use vec_perm_builder instead of
35688 auto_vec_perm_indices.
35689 * optabs-query.c (can_mult_highpart_p): Use vec_perm_builder and
35690 vec_perm_indices instead of auto_vec_perm_indices. Use a single
35691 or double series encoding as appropriate.
35692 * fold-const.c (fold_ternary_loc): Use vec_perm_builder and
35693 vec_perm_indices instead of auto_vec_perm_indices.
35694 * tree-ssa-forwprop.c (simplify_vector_constructor): Likewise.
35695 * tree-vect-data-refs.c (vect_grouped_store_supported): Likewise.
35696 (vect_permute_store_chain): Likewise.
35697 (vect_grouped_load_supported): Likewise.
35698 (vect_permute_load_chain): Likewise.
35699 (vect_shift_permute_load_chain): Likewise.
35700 * tree-vect-slp.c (vect_build_slp_tree_1): Likewise.
35701 (vect_transform_slp_perm_load): Likewise.
35702 (vect_schedule_slp_instance): Likewise.
35703 * tree-vect-stmts.c (perm_mask_for_reverse): Likewise.
35704 (vectorizable_mask_load_store): Likewise.
35705 (vectorizable_bswap): Likewise.
35706 (vectorizable_store): Likewise.
35707 (vectorizable_load): Likewise.
35708 * tree-vect-generic.c (lower_vec_perm): Use vec_perm_builder and
35709 vec_perm_indices instead of auto_vec_perm_indices. Use
35710 tree_to_vec_perm_builder to read the vector from a tree.
35711 * tree-vect-loop.c (calc_vec_perm_mask_for_shift): Take a
35712 vec_perm_builder instead of a vec_perm_indices.
35713 (have_whole_vector_shift): Use vec_perm_builder and
35714 vec_perm_indices instead of auto_vec_perm_indices. Leave the
35715 truncation to calc_vec_perm_mask_for_shift.
35716 (vect_create_epilog_for_reduction): Likewise.
35717 * config/aarch64/aarch64.c (expand_vec_perm_d::perm): Change
35718 from auto_vec_perm_indices to vec_perm_indices.
35719 (aarch64_expand_vec_perm_const_1): Use rotate_inputs on d.perm
35720 instead of changing individual elements.
35721 (aarch64_vectorize_vec_perm_const): Use new_vector to install
35722 the vector in d.perm.
35723 * config/arm/arm.c (expand_vec_perm_d::perm): Change
35724 from auto_vec_perm_indices to vec_perm_indices.
35725 (arm_expand_vec_perm_const_1): Use rotate_inputs on d.perm
35726 instead of changing individual elements.
35727 (arm_vectorize_vec_perm_const): Use new_vector to install
35728 the vector in d.perm.
35729 * config/powerpcspe/powerpcspe.c (rs6000_expand_extract_even):
35730 Update vec_perm_builder constructor.
35731 (rs6000_expand_interleave): Likewise.
35732 * config/rs6000/rs6000.c (rs6000_expand_extract_even): Likewise.
35733 (rs6000_expand_interleave): Likewise.
35734
35735 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
35736
35737 * optabs-query.c (can_vec_perm_var_p): Check whether lowering
35738 to qimode could truncate the indices.
35739 * optabs.c (expand_vec_perm_var): Likewise.
35740
35741 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
35742
35743 * Makefile.in (OBJS): Add vec-perm-indices.o.
35744 * vec-perm-indices.h: New file.
35745 * vec-perm-indices.c: Likewise.
35746 * target.h (vec_perm_indices): Replace with a forward class
35747 declaration.
35748 (auto_vec_perm_indices): Move to vec-perm-indices.h.
35749 * optabs.h: Include vec-perm-indices.h.
35750 (expand_vec_perm): Delete.
35751 (selector_fits_mode_p, expand_vec_perm_var): Declare.
35752 (expand_vec_perm_const): Declare.
35753 * target.def (vec_perm_const_ok): Replace with...
35754 (vec_perm_const): ...this new hook.
35755 * doc/tm.texi.in (TARGET_VECTORIZE_VEC_PERM_CONST_OK): Replace with...
35756 (TARGET_VECTORIZE_VEC_PERM_CONST): ...this new hook.
35757 * doc/tm.texi: Regenerate.
35758 * optabs.def (vec_perm_const): Delete.
35759 * doc/md.texi (vec_perm_const): Likewise.
35760 (vec_perm): Refer to TARGET_VECTORIZE_VEC_PERM_CONST.
35761 * expr.c (expand_expr_real_2): Use expand_vec_perm_const rather than
35762 expand_vec_perm for constant permutation vectors. Assert that
35763 the mode of variable permutation vectors is the integer equivalent
35764 of the mode that is being permuted.
35765 * optabs-query.h (selector_fits_mode_p): Declare.
35766 * optabs-query.c: Include vec-perm-indices.h.
35767 (selector_fits_mode_p): New function.
35768 (can_vec_perm_const_p): Check whether targetm.vectorize.vec_perm_const
35769 is defined, instead of checking whether the vec_perm_const_optab
35770 exists. Use targetm.vectorize.vec_perm_const instead of
35771 targetm.vectorize.vec_perm_const_ok. Check whether the indices
35772 fit in the vector mode before using a variable permute.
35773 * optabs.c (shift_amt_for_vec_perm_mask): Take a mode and a
35774 vec_perm_indices instead of an rtx.
35775 (expand_vec_perm): Replace with...
35776 (expand_vec_perm_const): ...this new function. Take the selector
35777 as a vec_perm_indices rather than an rtx. Also take the mode of
35778 the selector. Update call to shift_amt_for_vec_perm_mask.
35779 Use targetm.vectorize.vec_perm_const instead of vec_perm_const_optab.
35780 Use vec_perm_indices::new_expanded_vector to expand the original
35781 selector into bytes. Check whether the indices fit in the vector
35782 mode before using a variable permute.
35783 (expand_vec_perm_var): Make global.
35784 (expand_mult_highpart): Use expand_vec_perm_const.
35785 * fold-const.c: Includes vec-perm-indices.h.
35786 * tree-ssa-forwprop.c: Likewise.
35787 * tree-vect-data-refs.c: Likewise.
35788 * tree-vect-generic.c: Likewise.
35789 * tree-vect-loop.c: Likewise.
35790 * tree-vect-slp.c: Likewise.
35791 * tree-vect-stmts.c: Likewise.
35792 * config/aarch64/aarch64-protos.h (aarch64_expand_vec_perm_const):
35793 Delete.
35794 * config/aarch64/aarch64-simd.md (vec_perm_const<mode>): Delete.
35795 * config/aarch64/aarch64.c (aarch64_expand_vec_perm_const)
35796 (aarch64_vectorize_vec_perm_const_ok): Fuse into...
35797 (aarch64_vectorize_vec_perm_const): ...this new function.
35798 (TARGET_VECTORIZE_VEC_PERM_CONST_OK): Delete.
35799 (TARGET_VECTORIZE_VEC_PERM_CONST): Redefine.
35800 * config/arm/arm-protos.h (arm_expand_vec_perm_const): Delete.
35801 * config/arm/vec-common.md (vec_perm_const<mode>): Delete.
35802 * config/arm/arm.c (TARGET_VECTORIZE_VEC_PERM_CONST_OK): Delete.
35803 (TARGET_VECTORIZE_VEC_PERM_CONST): Redefine.
35804 (arm_expand_vec_perm_const, arm_vectorize_vec_perm_const_ok): Merge
35805 into...
35806 (arm_vectorize_vec_perm_const): ...this new function. Explicitly
35807 check for NEON modes.
35808 * config/i386/i386-protos.h (ix86_expand_vec_perm_const): Delete.
35809 * config/i386/sse.md (VEC_PERM_CONST, vec_perm_const<mode>): Delete.
35810 * config/i386/i386.c (ix86_expand_vec_perm_const_1): Update comment.
35811 (ix86_expand_vec_perm_const, ix86_vectorize_vec_perm_const_ok): Merge
35812 into...
35813 (ix86_vectorize_vec_perm_const): ...this new function. Incorporate
35814 the old VEC_PERM_CONST conditions.
35815 * config/ia64/ia64-protos.h (ia64_expand_vec_perm_const): Delete.
35816 * config/ia64/vect.md (vec_perm_const<mode>): Delete.
35817 * config/ia64/ia64.c (ia64_expand_vec_perm_const)
35818 (ia64_vectorize_vec_perm_const_ok): Merge into...
35819 (ia64_vectorize_vec_perm_const): ...this new function.
35820 * config/mips/loongson.md (vec_perm_const<mode>): Delete.
35821 * config/mips/mips-msa.md (vec_perm_const<mode>): Delete.
35822 * config/mips/mips-ps-3d.md (vec_perm_constv2sf): Delete.
35823 * config/mips/mips-protos.h (mips_expand_vec_perm_const): Delete.
35824 * config/mips/mips.c (mips_expand_vec_perm_const)
35825 (mips_vectorize_vec_perm_const_ok): Merge into...
35826 (mips_vectorize_vec_perm_const): ...this new function.
35827 * config/powerpcspe/altivec.md (vec_perm_constv16qi): Delete.
35828 * config/powerpcspe/paired.md (vec_perm_constv2sf): Delete.
35829 * config/powerpcspe/spe.md (vec_perm_constv2si): Delete.
35830 * config/powerpcspe/vsx.md (vec_perm_const<mode>): Delete.
35831 * config/powerpcspe/powerpcspe-protos.h (altivec_expand_vec_perm_const)
35832 (rs6000_expand_vec_perm_const): Delete.
35833 * config/powerpcspe/powerpcspe.c (TARGET_VECTORIZE_VEC_PERM_CONST_OK):
35834 Delete.
35835 (TARGET_VECTORIZE_VEC_PERM_CONST): Redefine.
35836 (altivec_expand_vec_perm_const_le): Take each operand individually.
35837 Operate on constant selectors rather than rtxes.
35838 (altivec_expand_vec_perm_const): Likewise. Update call to
35839 altivec_expand_vec_perm_const_le.
35840 (rs6000_expand_vec_perm_const): Delete.
35841 (rs6000_vectorize_vec_perm_const_ok): Delete.
35842 (rs6000_vectorize_vec_perm_const): New function.
35843 (rs6000_do_expand_vec_perm): Take a vec_perm_builder instead of
35844 an element count and rtx array.
35845 (rs6000_expand_extract_even): Update call accordingly.
35846 (rs6000_expand_interleave): Likewise.
35847 * config/rs6000/altivec.md (vec_perm_constv16qi): Delete.
35848 * config/rs6000/paired.md (vec_perm_constv2sf): Delete.
35849 * config/rs6000/vsx.md (vec_perm_const<mode>): Delete.
35850 * config/rs6000/rs6000-protos.h (altivec_expand_vec_perm_const)
35851 (rs6000_expand_vec_perm_const): Delete.
35852 * config/rs6000/rs6000.c (TARGET_VECTORIZE_VEC_PERM_CONST_OK): Delete.
35853 (TARGET_VECTORIZE_VEC_PERM_CONST): Redefine.
35854 (altivec_expand_vec_perm_const_le): Take each operand individually.
35855 Operate on constant selectors rather than rtxes.
35856 (altivec_expand_vec_perm_const): Likewise. Update call to
35857 altivec_expand_vec_perm_const_le.
35858 (rs6000_expand_vec_perm_const): Delete.
35859 (rs6000_vectorize_vec_perm_const_ok): Delete.
35860 (rs6000_vectorize_vec_perm_const): New function. Remove stray
35861 reference to the SPE evmerge intructions.
35862 (rs6000_do_expand_vec_perm): Take a vec_perm_builder instead of
35863 an element count and rtx array.
35864 (rs6000_expand_extract_even): Update call accordingly.
35865 (rs6000_expand_interleave): Likewise.
35866 * config/sparc/sparc.md (vec_perm_constv8qi): Delete in favor of...
35867 * config/sparc/sparc.c (sparc_vectorize_vec_perm_const): ...this
35868 new function.
35869 (TARGET_VECTORIZE_VEC_PERM_CONST): Redefine.
35870
35871 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
35872
35873 * optabs.c (expand_vec_perm_1): Assert that SEL has an integer
35874 vector mode and that that mode matches the mode of the data
35875 being permuted.
35876 (expand_vec_perm): Split handling of non-CONST_VECTOR selectors
35877 out into expand_vec_perm_var. Do all CONST_VECTOR handling here,
35878 directly using expand_vec_perm_1 when forcing selectors into
35879 registers.
35880 (expand_vec_perm_var): New function, split out from expand_vec_perm.
35881
35882 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
35883
35884 * optabs-query.h (can_vec_perm_p): Delete.
35885 (can_vec_perm_var_p, can_vec_perm_const_p): Declare.
35886 * optabs-query.c (can_vec_perm_p): Split into...
35887 (can_vec_perm_var_p, can_vec_perm_const_p): ...these two functions.
35888 (can_mult_highpart_p): Use can_vec_perm_const_p to test whether a
35889 particular selector is valid.
35890 * tree-ssa-forwprop.c (simplify_vector_constructor): Likewise.
35891 * tree-vect-data-refs.c (vect_grouped_store_supported): Likewise.
35892 (vect_grouped_load_supported): Likewise.
35893 (vect_shift_permute_load_chain): Likewise.
35894 * tree-vect-slp.c (vect_build_slp_tree_1): Likewise.
35895 (vect_transform_slp_perm_load): Likewise.
35896 * tree-vect-stmts.c (perm_mask_for_reverse): Likewise.
35897 (vectorizable_bswap): Likewise.
35898 (vect_gen_perm_mask_checked): Likewise.
35899 * fold-const.c (fold_ternary_loc): Likewise. Don't take
35900 implementations of variable permutation vectors into account
35901 when deciding which selector to use.
35902 * tree-vect-loop.c (have_whole_vector_shift): Don't check whether
35903 vec_perm_const_optab is supported; instead use can_vec_perm_const_p
35904 with a false third argument.
35905 * tree-vect-generic.c (lower_vec_perm): Use can_vec_perm_const_p
35906 to test whether the constant selector is valid and can_vec_perm_var_p
35907 to test whether a variable selector is valid.
35908
35909 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
35910
35911 * optabs-query.h (can_vec_perm_p): Take a const vec_perm_indices *.
35912 * optabs-query.c (can_vec_perm_p): Likewise.
35913 * fold-const.c (fold_vec_perm): Take a const vec_perm_indices &
35914 instead of vec_perm_indices.
35915 * tree-vectorizer.h (vect_gen_perm_mask_any): Likewise,
35916 (vect_gen_perm_mask_checked): Likewise,
35917 * tree-vect-stmts.c (vect_gen_perm_mask_any): Likewise,
35918 (vect_gen_perm_mask_checked): Likewise,
35919
35920 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
35921
35922 * optabs-query.h (qimode_for_vec_perm): Declare.
35923 * optabs-query.c (can_vec_perm_p): Split out qimode search to...
35924 (qimode_for_vec_perm): ...this new function.
35925 * optabs.c (expand_vec_perm): Use qimode_for_vec_perm.
35926
35927 2018-01-02 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
35928
35929 * rtlanal.c (canonicalize_condition): Return 0 if final rtx
35930 does not have a conditional at the top.
35931
35932 2018-01-02 Richard Biener <rguenther@suse.de>
35933
35934 * ipa-inline.c (big_speedup_p): Fix expression.
35935
35936 2018-01-02 Jan Hubicka <hubicka@ucw.cz>
35937
35938 PR target/81616
35939 * config/i386/x86-tune-costs.h: Increase cost of integer load costs
35940 for generic 4->6.
35941
35942 2018-01-02 Jan Hubicka <hubicka@ucw.cz>
35943
35944 PR target/81616
35945 Generic tuning.
35946 * x86-tune-costs.h (generic_cost): Reduce cost of FDIV 20->17,
35947 cost of sqrt 20->14, DIVSS 18->13, DIVSD 32->17, SQRtSS 30->14
35948 and SQRTsD 58->18, cond_not_taken_branch_cost. 2->1. Increase
35949 cond_taken_branch_cost 3->4.
35950
35951 2018-01-01 Jakub Jelinek <jakub@redhat.com>
35952
35953 PR tree-optimization/83581
35954 * tree-loop-distribution.c (pass_loop_distribution::execute): Return
35955 TODO_cleanup_cfg if any changes have been made.
35956
35957 PR middle-end/83608
35958 * expr.c (store_expr_with_bounds): Use simplify_gen_subreg instead of
35959 convert_modes if target mode has the right side, but different mode
35960 class.
35961
35962 PR middle-end/83609
35963 * expr.c (expand_assignment): Fix up a typo in simplify_gen_subreg
35964 last argument when extracting from CONCAT. If either from_real or
35965 from_imag is NULL, use expansion through memory. If result is not
35966 a CONCAT and simplify_gen_subreg fails, try to simplify_gen_subreg
35967 the parts directly to inner mode, if even that fails, use expansion
35968 through memory.
35969
35970 PR middle-end/83623
35971 * expmed.c (expand_shift_1): For 2-byte rotates by BITS_PER_UNIT,
35972 check for bswap in mode rather than HImode and use that in expand_unop
35973 too.
35974 \f
35975 Copyright (C) 2018 Free Software Foundation, Inc.
35976
35977 Copying and distribution of this file, with or without modification,
35978 are permitted in any medium without royalty provided the copyright
35979 notice and this notice are preserved.