2013-07-05 Robert Dewar <dewar@adacore.com>
* a-cfhase.adb, sem_prag.adb, a-cfhama.adb: Minor reformatting.
2013-07-05 Ed Schonberg <schonberg@adacore.com>
* sem_ch12.adb (Copy_Generic_Node): Check that name in function
call is a valid entity name before preserving entity in generic
copy.
2013-07-05 Thomas Quinot <quinot@adacore.com>
* par-ch5.adb: Minor reformatting.
2013-07-05 Thomas Quinot <quinot@adacore.com>
* sinfo.ads: Minor clarification to documentation for
N_Implicit_Label_Declaration.
2013-07-05 Hristian Kirtchev <kirtchev@adacore.com>
* a-except-2005.adb, a-except.adb: Add constant Rmsg_17. Correct the
values of all remaining constants.
(Rcheck_35): New routine along with pragmas Export and No_Return.
(Rcheck_PE_Aliased_Parameters): New routine along with pragmas
Export and No_Return.
(Rcheck_PE_All_Guards_Closed,
Rcheck_PE_Bad_Predicated_Generic_Type,
Rcheck_PE_Current_Task_In_Entry_Body,
Rcheck_PE_Duplicated_Entry_Address, Rcheck_PE_Explicit_Raise,
Rcheck_PE_Implicit_Return, Rcheck_PE_Misaligned_Address_Value,
Rcheck_PE_Missing_Return, Rcheck_PE_Overlaid_Controlled_Object,
Rcheck_PE_Potentially_Blocking_Operation
Rcheck_PE_Stubbed_Subprogram_Called,
Rcheck_PE_Unchecked_Union_Restriction,
Rcheck_PE_Non_Transportable_Actual, Rcheck_SE_Empty_Storage_Pool,
Rcheck_SE_Explicit_Raise, Rcheck_SE_Infinite_Recursion,
Rcheck_SE_Object_Too_Large, Rcheck_PE_Finalize_Raised_Exception):
Update the use of Rmsg_XX.
(Rcheck_17, Rcheck_18, Rcheck_19,
Rcheck_20, Rcheck_21, Rcheck_22, Rcheck_23, Rcheck_24, Rcheck_25,
Rcheck_26, Rcheck_27, Rcheck_28, Rcheck_29, Rcheck_30, Rcheck_31,
Rcheck_32, Rcheck_33, Rcheck_34, Rcheck_35): Update corresponding
renamed subprograms.
* checks.adb: Add with and use clause for Stringt.
(Apply_Parameter_Aliasing_Checks): Make constant Loc visible in
all subprograms of Apply_Parameter_Aliasing_Checks. Remove local
variable Cond. Initialize Check at the start of the routine. Use
routine Overlap_Check to construct a simple or a detailed run-time
check. Update the creation of the simple check.
(Overlap_Check): New routine.
* exp_ch11.adb (Get_RT_Exception_Name): Add a value for
PE_Aliased_Parameters.
* types.ads: Add new enumeration literal
PE_Aliased_Parameters. Update the corresponding integer values
of all RT_Exception_Code literals.
* types.h: Add new constant PE_Aliased_Parameters. Correct the
values of all remaining constants.
2013-07-05 Yannick Moy <moy@adacore.com>
* gnat_rm.texi: Minor renaming of SPARK into SPARK 2005 in
documentation.
From-SVN: r200690
2013-07-05 Ed Schonberg <schonberg@adacore.com>
* sem_prag.adb (Analyze_PPC_In_Decl_Part): For a class-wide
condition, when replacing the name of a formal by a conversion
to the class-wide type, exempt selector names that appear in
parameter associations.
From-SVN: r200689
gcc/c:
PR c/57821
* c-typeck.c (set_init_index): When folding, check for index overflow.
gcc/c-family:
PR c/57821
* c-common.c (complete_array_type): Delay folding first index
like other indices. When folding, check for index overflow.
gcc/testsuite:
PR c/57821
* gcc.dg/large-size-array-6.c: New test.
From-SVN: r200683
PR c++/57771
* parser.c (cp_parser_postfix_expression) <case RID_STATCAST>
Temporarily set parser->greater_than_is_operator_p for
cp_parser_expression and restore from saved value afterwards.
* g++.dg/template/arg9.C: New test.
From-SVN: r200647
PR middle-end/55030
* stmt.c (expand_nl_goto_receiver): Remove almost-copy of
expand_builtin_setjmp_receiver.
(expand_label): Adjust, call expand_builtin_setjmp_receiver
with NULL for the label parameter.
* builtins.c (expand_builtin_setjmp_receiver): Don't clobber
the frame-pointer. Adjust comments.
[HAVE_builtin_setjmp_receiver]: Emit builtin_setjmp_receiver
only if LABEL is non-NULL.
From-SVN: r200643
Allow functions for AVX target inline functions for lower target. This bug was
reported here: http://gcc.gnu.org/ml/gcc-patches/2013-06/msg01620.html
2013-07-02 Sriraman Tallam <tmsriram@google.com>
* config/i386/i386.c (gate_insert_vzeroupper): Check if target
ISA is AVX.
(ix86_option_override_internal):Turn on all -mavx target flags by
default as they are dependent on AVX anyway.
* gcc.target/i386/avx-inline.c: New test.
From-SVN: r200627
/cp
2013-06-28 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/57645
* class.c (deduce_noexcept_on_destructors): Save, set, and restore
TYPE_HAS_NONTRIVIAL_DESTRUCTOR (t) around the main loop over the
destructors.
/testsuite
2013-06-28 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/57645
* g++.dg/cpp0x/noexcept21.C: New.
From-SVN: r200559
2013-06-28 Vladimir Makarov <vmakarov@redhat.com>
Revert:
2013-06-28 Vladimir Makarov <vmakarov@redhat.com>
* lra-constraints.c (need_for_split_p): Check call used hard regs
living through calls.
* lra-constraints.c (inherit_in_ebb): Reset live_hard_regs for
call used regs for call insn.
From-SVN: r200558
PR target/57736
* config/i386/i386.c (ix86_expand_builtin): If target == NULL
and mode is VOIDmode, don't create a VOIDmode pseudo to copy result
into.
* gcc.target/i386/pr57736.c: New test.
From-SVN: r200555
gcc/ChangeLog
2013-06-28 Balaji V. Iyer <balaji.v.iyer@intel.com>
* builtins.def: Fixed the function type of CILKPLUS_BUILTIN.
gcc/c/ChangeLog
2013-06-28 Balaji V. Iyer <balaji.v.iyer@intel.com>
* c-parser.c (c_parser_array_notation): Removed rejection of array
notations in an array of function pointers.
gcc/c-family/ChangeLog
2013-06-28 Balaji V. Iyer <balaji.v.iyer@intel.com>
* array-notation-common.c (length_mismatch_in_expr_p): Collapsed two
if-statements and compared the trees directly using tree_int_cst_equal.
(find_rank): Checked for array notations in function name to handle
array notations in function pointers.
(extract_array_notation_exprs): Likewise.
(replace_array_notations): Likewise.
(cilkplus_extract_an_triplets): Replaced safe_push with
safe_grow_cleared. Also removed an unnecessary check to see if the
node is of type ARRAY_NOTATION_REF.
(fix_sec_implicit_args): Removed an unnecessary check for ADDR_EXPR.
Also switched two if-statements to remove an unnecessary comparison.
gcc/cp/ChangeLog
2013-06-28 Balaji V. Iyer <balaji.v.iyer@intel.com>
* parser.c (cp_parser_array_notation): Removed rejection array notation
of type function pointers. Added handling of array expressions when
Cilk Plus is enabled. Took out type-checking.
(cp_parser_postfix_open_square_expression): Moved normal array expr.
parsing into cp_parser_array_notation when cilkplus is enabled.
(cp_parser_compound_statement): Removed expansion of array notations.
(cp_parser_ctor_initializer_opt_and_function_body): Likewise.
(cp_parser_function_definition_after_declarator): Likewise.
(cp_parser_selection_statement): Removed error reporting.
(cp_parser_iteration_statement): Likewise.
(cp_parser_direct_declarator): Removed error checking/reporting if
array notations are used in the declarator.
* pt.c (instantiate_decl): Likewise.
(type_unification_real): Removed a check for ARRAY_NOTATION_REF.
(cxx_eval_constant_expression): Removed ARRAY_NOTATION_REF case.
(potential_constant_expression_1): Returned false for ARRAY_NOTATION_REF
case.
* cp-gimplify.c (cp_genericize): Added expansion of array notation
expressions here.
* cp-array-notation.c (make_triplet_val_inv): Removed loc and cry
parameters. Replaced build_decls with get_temp_regvar with type as
ptrdiff.
(create_array_refs): Made the type-casting to ptrdiff_type.
(replace_invariant_var): Added a check for void return type before
creating new var. Replaced build_decl and build_min_nt_loc with
get_temp_regvar.
(expand_an_in_modify_expr): Ditto. Replaced body of redundant else with
gcc_unreachable. Removed few unwanted checks. Made induction variable
type as ptrdiff_type. Removed loc and complain arguments passed into
make_triplet_val_inv. Replaced all modify expression's code from NOP
EXPR to INIT EXPR. Replaced all forceful appending into stmt. list
with the non-forceful one. Replaced some integer conversion and
equality-checking to using tree_int_cst_equal.
(expand_sec_reduce_builtin): All changes mentioned in above function
expand_an_in_modify_expr. Made the new variable type of
SEC_REDUCE_ANY/ALL_{NON}ZERO intrinsic functions as bool.
(expand_array_notation_exprs): Removed SWITCH_EXPR case. Moved all
the error reporting from parser to this function. Removed unwanted
statements and checks from SWITCH_STMT, WHILE_STMT, and DO_STMT cases.
(cilkplus_an_triplet_types_ok_p): Removed rejection of array notation
in function pointers.
(cp_expand_cond_array_notations): Added a new if statements to check
if condition has a zero rank. If so, then just return.
(expand_return_expr): Added a check for return expressions with a rank.
Replaced get_tmp_regvar with a create_temporary_var.
(build_array_notation_ref): Simplified and removed unwanted if-stmts.
Moved common code outside if-statements. Moved type-checking from
parser to here.
* semantics.c (finish_return_stmt): Removed a check for return exprs.
with a rank.
* call.c (convert_like_real): Removed a check for array notation
expression in a function.
(build_over_call): Likewise.
(magic_varargs_p): Added a check for builtin array notation function.
Made this function non-static and removed its prototype.
* cp-tree.h (magic_varargs_p): New prototype.
* typeck.c (cp_build_function_call_vec): Removed automatic setting of
nargs to the param->length when builtin reduction function is used.
(convert_arguments): Replaced check for a constant_p function with
margic_varargs_p function call.
(cp_build_binary_op): Removed calling of the function
find_correct_array_notation_type.
(cp_build_addr_expr_1): Removed an unwanted if-statement.
(convert_for_assignment): Removed automatic return of rhs when array
notation builtin function is used.
gcc/testsuite/ChangeLog
2013-06-28 Balaji V. Iyer <balaji.v.iyer@intel.com>
* c-c++-common/cilk-plus/AN/decl-ptr-colon.c (main): Made this testcase
c specific.
* c-c++-common/cilk-plus/AN/decl-ptr-colon.c (main): Changed dg-error
strings to match the fixed error messages.
* c-c++-common/cilk-plus/AN/misc.c (main): Likewise.
* c-c++-common/cilk-plus/AN/rank_mismatch.c (main): Added a new error
message check.
From-SVN: r200554
2013-06-28 Vladimir Makarov <vmakarov@redhat.com>
* lra-constraints.c (need_for_split_p): Check call used hard regs
living through calls.
From-SVN: r200553
[gcc]
2013-06-28 Michael Meissner <meissner@linux.vnet.ibm.com>
PR target/57744
* config/rs6000/rs6000.h (MODES_TIEABLE_P): Do not allow PTImode
to tie with any other modes. Eliminate Altivec vector mode tests,
since these are a subset of ALTIVEC or VSX vector modes. Simplify
code, to return 0 if testing MODE2 for a condition, if we've
already tested MODE1 for the same condition.
[gcc/testsuite]
2013-06-28 Michael Meissner <meissner@linux.vnet.ibm.com>
PR target/57744
* gcc.target/powerpc/pr57744.c: New test to make sure lqarx and
stqcx. get even registers.
From-SVN: r200538