Since fixuns_trunc<mode>si2 expander checks optimize_insn_for_size_p
before generating *fixuns_trunc<mode>_1, we should use
optimize_insn_for_speed_p in *fixuns_trunc<mode>_1 for consistency.
PR target/60827
* config/i386/i386.md (*fixuns_trunc<mode>_1): Check
optimize_insn_for_speed_p instead of
optimize_function_for_speed_p.
From-SVN: r209383
* include/bits/stl_vector.h (_Vector_base::_Vector_impl,
_Vector_base::_M_allocate): NullablePointer requirements do not
include initialization from literal zero, use value-initialization.
* include/bits/vector.tcc (vector::_M_insert_aux,
vector::_M_explace_back_aux): Likewise for assignment.
From-SVN: r209377
* snames.ads-tmpl (Name_Ivdep): New pragma-related name.
* sem_prag.adb (Analyze_Pragma) <Pragma_Loop_Optimize>: Add support
for Ivdep hint.
* gnat_rm.texi (Implementation Defined Pragmas): Document new Ivdep
hint for Loop_Optimize.
* gnat_ugn.texi (Vectorization of loops): Mention new Ivdep hint.
* gcc-interface/trans.c (Pragma_to_gnu) <Pragma_Loop_Optimize>: Deal
with new Ivdep hint.
* gcc-interface/ada-tree.h (LOOP_STMT_IVDEP): New macro.
* gcc-interface/trans.c (Pragma_to_gnu) <Pragma_Loop_Optimize>: Deal
with new Ivdep hint.
(gnat_gimplify_stmt) <LOOP_STMT>: Propagate the loop hints.
From-SVN: r209375
2014-04-14 Richard Biener <rguenther@suse.de>
PR tree-optimization/60042
* tree-ssa-pre.c (inhibit_phi_insertion): Remove.
(insert_into_preds_of_block): Do not prevent PHI insertion
for REFERENCE exprs here ...
(eliminate_dom_walker::before_dom_children): ... but prevent
their use here under similar conditions when applied to the
IL after PRE optimizations.
From-SVN: r209374
2014-04-14 Richard Biener <rguenther@suse.de>
* tree-ssa-forwprop.c (simplify_gimple_switch): Enhance
check for which sign-changes we allow when forwarding
a converted value into a switch.
* g++.dg/tree-ssa/forwprop-switch.C: New testcase.
From-SVN: r209372
* opt.ads (Suppress_Back_Annotation): Remove as unused.
* fe.h (Back_Annotate_Rep_Info): Likewise.
(Global_Discard_Names): Likewise.
(List_Representation_Info): Declare.
* types.h (Uint_Minus_1): Likewise.
* repinfo.ads: Document back-annotation change.
* gcc-interface/gigi.h (init_gnat_decl): Declare.
(destroy_gnat_decl): Likewise.
* gcc-interface/decl.c (annotate_value): Do not create the cache of
annotated values here but...
<CALL_EXPR>: Only inline the call if -gnatR3 is specified or we are
in ASIS mode.
(init_gnat_decl): ...here instead. New function.
(destroy_gnat_decl): Likewise.
* gcc-interface/trans.c (gigi): Call {init|destroy}_gnat_decl.
* gcc-interface/utils.c (init_gnat_utils): Minor reformatting.
Co-Authored-By: Robert Dewar <dewar@adacore.com>
From-SVN: r209371
* stor-layout.c (place_field): Finalize non-constant offset for the
field, if any.
ada/
* gcc-interface/decl.c (create_field_decl_from): Finalize non-constant
offset for the field, if any.
From-SVN: r209369
2014-04-14 Richard Biener <rguenther@suse.de>
Marc Glisse <marc.glisse@inria.fr>
PR c/60819
c-family/
* c-common.c (convert_vector_to_pointer_for_subscript): Properly
apply may-alias the scalar pointer type when applicable.
* gcc.target/i386/vec-may_alias.c: New testcase.
Co-Authored-By: Marc Glisse <marc.glisse@inria.fr>
From-SVN: r209365
2014-04-14 Richard Biener <rguenther@suse.de>
* tree-switch-conversion.c (lshift_cheap_p): Get speed_p
as argument.
(expand_switch_using_bit_tests_p): Likewise.
(process_switch): Compute and pass on speed_p based on the
switch stmt.
* tree-ssa-math-opts.c (gimple_expand_builtin_pow): Use
optimize_bb_for_speed_p.
From-SVN: r209364
2014-04-14 Richard Biener <rguenther@suse.de>
PR lto/60720
* lto-streamer-out.c (wrap_refs): New function.
(lto_output): Wrap symbol references in global initializes in
type-preserving MEM_REFs.
* gcc.dg/lto/pr60720_0.c: New testcase.
* gcc.dg/lto/pr60720_1.c: Likewise.
From-SVN: r209359
2014-04-14 Richard Biener <rguenther@suse.de>
PR tree-optimization/59817
PR tree-optimization/60453
* graphite-scop-detection.c (graphite_can_represent_scev): Complete
recursion to catch all CHRECs in the scalar evolution and restrict
the predicate for the remains appropriately.
* gfortran.dg/graphite/pr59817.f: New testcase.
* gcc.dg/graphite/pr59817-1.c: Likewise.
* gcc.dg/graphite/pr59817-2.c: Likewise.
From-SVN: r209355
2014-04-13 Paul Thomas <pault@gcc.gnu.org>
PR fortran/58085
PR fortran/60717
* trans.h: Add 'use_offset' bitfield to gfc_se.
* trans-array.c (gfc_conv_expr_descriptor): Use 'use_offset'
as a trigger to unconditionally recalculate the offset for
array slices and constant arrays.
trans-expr.c (gfc_conv_intrinsic_to_class): Use it.
trans-stmt.c (trans_associate_var): Ditto.
(gfc_conv_procedure_call): Ditto.
2014-04-13 Paul Thomas <pault@gcc.gnu.org>
PR fortran/60717
* gfortran.dg/unlimited_polymorphic_17.f90: New test.
PR fortran/58085
* gfortran.dg/associate_15.f90: New test.
From-SVN: r209347
gcc/c-family/
PR middle-end/60467
* cilk.c (cilk_set_spawn_marker): Remove FUNCTION_DECL
as possible argument for Cilk_spawn.
gcc/testsuite/
PR middle-end/60467
* c-c++-common/cilk-plus/CK/invalid_spawns.c: Add new invalid
case to check.
From-SVN: r209337
2014-04-11 Marc Glisse <marc.glisse@inria.fr>
* include/std/complex (__complex_exp, pow): Specify the template
parameter in calls to std::polar, for expression templates.
From-SVN: r209321
* common/config/epiphany/epiphany-common.c
(epiphany_option_optimization_table): Enable section anchors by
default at -O1 or higher.
* config/epiphany/epiphany.c (TARGET_MAX_ANCHOR_OFFSET): Define.
(TARGET_MIN_ANCHOR_OFFSET): Likewise.
(epiphany_rtx_costs) <SET>: For binary operators, the set as such
carries no extra cost.
(epiphany_legitimate_address_p): For BLKmode, apply SImode check.
* config/epiphany/epiphany.h (ASM_OUTPUT_DEF): Define.
* config/epiphany/predicates.md (memclob_operand): New predicate.
* config/epiphany/epiphany.md (stack_adjust_add, stack_adjust_str):
Use memclob_operand predicate and X constraint for operand 3.
gcc/testsuite:
* gcc.target/epiphany/t1068-2.c: New file.
From-SVN: r209320
gcc:
* config/epiphany/epiphany.c (epiphany_rtx_cost): Compare
with CC_N_NE / CC_C_LTU / CC_C_GTU carries no extra cost for
its operands.
gcc/testsuite:
* gcc.target/epiphany/btst-1.c: New test.
From-SVN: r209319
* parser.h (struct cp_token): Rename ambiguous_p to error_reported.
* parser.c: Adjust.
(cp_lexer_get_preprocessor_token): Always clear it.
(cp_parser_lambda_expression): Use it to avoid duplicate diagnostics.
From-SVN: r209315
gcc:
PR rtl-optimization/60651
* mode-switching.c (optimize_mode_switching): Make sure to emit
sets of a lower numbered entity before sets of a higher numbered
entity to a mode of the same or lower priority.
When creating a seginfo for a basic block that starts with a code
label, move the insertion point past the code label.
(new_seginfo): Document and enforce requirement that
NOTE_INSN_BASIC_BLOCK only appears for empty blocks.
* doc/tm.texi.in: Document ordering constraint for emitted mode sets.
* doc/tm.texi: Regenerate.
gcc/testsuite:
PR rtl-optimization/60651
* gcc.target/epiphany/mode-switch.c: New test.
From-SVN: r209312