Richard Biener [Mon, 23 Jan 2017 12:24:35 +0000 (12:24 +0000)]
re PR testsuite/78421 (vect-strided-a-u8-i2-gap.c fails on armeb)
PR testsuite/78421
* lib/target-supports.exp (check_effective_target_vect_hw_misalign):
If the target is ARM return the result of the
check_effective_target_arm_vect_no_misalign proc.
* gcc.dg/vect/vect-strided-a-u8-i2-gap.c: If the target does not
support unaligned vectors then only expect one of the loops to be
unrolled.
Co-Authored-By: Nick Clifton <nickc@redhat.com>
From-SVN: r244796
Arnaud Charlet [Mon, 23 Jan 2017 12:08:22 +0000 (13:08 +0100)]
Minor editing.
From-SVN: r244795
Arnaud Charlet [Mon, 23 Jan 2017 12:07:34 +0000 (13:07 +0100)]
[multiple changes]
2017-01-23 Ed Schonberg <schonberg@adacore.com>
* par-ch4.adb (P_Aggregate_Or_Parent_Expr): Recognize delta
aggregate construct.
(P_Record_Or_Array_Component_Association): An array aggregate
can start with an Iterated_Component_Association.
* scng.adb: Modify error message on improper use of @ in earlier
versions of the language.
* sinfo.ads: New node kind N_Delta_Aggregate.
* sinfo.adb: An N_Delta_Aggregate has component associations and
an expression.
* sem_res.adb (Resolve): Call Resolve_Delta_Aggregate.
* sem_aggr.ads, sem_aggr.adb (Resolve_Iterated_Component_Association):
Create a new index for each one of the choices in the association,
to prevent spurious homonyms in the scope.
(Resolve_Delta_Aggregate): New.
* sem.adb: An N_Delta_Aggregate is analyzed like an aggregate.
* exp_util.adb (Insert_Actions): Take into account
N_Delta_Aggregate.
* exp_aggr.ads: New procedure Expand_N_Delta_Aggregate.
* exp_aggr.adb: New procedure Expand_N_Delta_Aggregate,
and local procedures Expand_Delta_Array_Aggregate and
expand_Delta_Record_Aggregate.
* sprint.adb: Handle N_Delta_Aggregate.
2017-01-23 Hristian Kirtchev <kirtchev@adacore.com>
* exp_ch11.adb (Expand_N_Exception_Declaration): Generate an
empty name when the exception declaration is subject to pragma
Discard_Names.
(Null_String): New routine.
2017-01-23 Hristian Kirtchev <kirtchev@adacore.com>
* par-ch9.adb (P_Protected_Definition): Parse
any optional and potentially illegal pragmas which appear in
a protected operation declaration list.
(P_Task_Items): Parse
any optional and potentially illegal pragmas which appear in a
task item list.
From-SVN: r244794
Martin Liska [Mon, 23 Jan 2017 12:06:13 +0000 (12:06 +0000)]
use-after-scope: handle writes to a poisoned variable
2017-01-23 Martin Liska <mliska@suse.cz>
* gcc.dg/asan/use-after-scope-10.c: New test.
* gcc.dg/asan/use-after-scope-11.c: New test.
* g++.dg/asan/use-after-scope-5.C: New test.
2017-01-23 Jakub Jelinek <jakub@redhat.com>
Martin Liska <mliska@suse.cz>
* asan.h: Define ASAN_USE_AFTER_SCOPE_ATTRIBUTE.
* asan.c (asan_expand_poison_ifn): Support stores and use
appropriate ASAN report function.
* internal-fn.c (expand_ASAN_POISON_USE): New function.
* internal-fn.def (ASAN_POISON_USE): Declare.
* tree-into-ssa.c (maybe_add_asan_poison_write): New function.
(maybe_register_def): Create ASAN_POISON_USE when sanitizing.
* tree-ssa-dce.c (eliminate_unnecessary_stmts): Remove
ASAN_POISON calls w/o LHS.
* tree-ssa.c (execute_update_addresses_taken): Create clobber
for ASAN_MARK (UNPOISON, &x, ...) in order to prevent usage of a LHS
from ASAN_MARK (POISON, &x, ...) coming to a PHI node.
* gimplify.c (asan_poison_variables): Add attribute
use_after_scope_memory to variables that really needs to live
in memory.
* tree-ssa.c (is_asan_mark_p): Do not rewrite into SSA when
having the attribute.
From-SVN: r244793
Arnaud Charlet [Mon, 23 Jan 2017 12:04:16 +0000 (13:04 +0100)]
[multiple changes]
2017-01-23 Pascal Obry <obry@adacore.com>
* s-taprop-mingw.adb (Enter_Task): Initialize the Thread handle which
is needed when a foreign thread call a Win32 API using a thread handle
like GetThreadTimes() for example.
2017-01-23 Hristian Kirtchev <kirtchev@adacore.com>
* sem_ch13.adb (Analyze_Attribute_Definition_Clause): Do not
allow an 'Address clause to be specified on a prefix of a
class-wide type.
2017-01-23 Hristian Kirtchev <kirtchev@adacore.com>
* checks.adb (Insert_Valid_Check): Ensure that the prefix of
attribute 'Valid is a renaming of the original expression when
the expression denotes a name. For all other kinds of expression,
use a constant to capture the value.
* exp_util.adb (Is_Name_Reference): Moved to Sem_Util.
* sem_util.ads, sem_util.adb (Is_Name_Reference): Moved from Exp_Util.
2017-01-23 Justin Squirek <squirek@adacore.com>
* sem_eval.adb (Eval_Integer_Literal): Add special
case to avoid optimizing out check if the literal appears in
an if-expression.
From-SVN: r244792
Martin Liska [Mon, 23 Jan 2017 12:02:13 +0000 (13:02 +0100)]
Speed up use-after-scope (v2): rewrite into SSA
2017-01-23 Martin Liska <mliska@suse.cz>
* asan.c (create_asan_shadow_var): New function.
(asan_expand_poison_ifn): Likewise.
* asan.h (asan_expand_poison_ifn): New declaration.
* internal-fn.c (expand_ASAN_POISON): Likewise.
* internal-fn.def (ASAN_POISON): New builtin.
* sanopt.c (pass_sanopt::execute): Expand
asan_expand_poison_ifn.
* tree-inline.c (copy_decl_for_dup_finish): Make function
external.
* tree-inline.h (copy_decl_for_dup_finish): Likewise.
* tree-ssa.c (is_asan_mark_p): New function.
(execute_update_addresses_taken): Rewrite local variables
(identified just by use-after-scope as addressable) into SSA.
2017-01-23 Martin Liska <mliska@suse.cz>
* gcc.dg/asan/use-after-scope-3.c: Add additional flags.
* gcc.dg/asan/use-after-scope-9.c: Likewise and grep for
sanopt optimization for ASAN_POISON.
From-SVN: r244791
Ed Schonberg [Mon, 23 Jan 2017 12:00:26 +0000 (12:00 +0000)]
sem_ch4.adb (Try_Primitive_Operations, [...]): argument is valid if it is a derived type with unknown discriminants that...
2017-01-23 Ed Schonberg <schonberg@adacore.com>
* sem_ch4.adb (Try_Primitive_Operations,
Is_Valid_First_Argument_Of): argument is valid if it is a derived
type with unknown discriminants that matches its underlying
record view.
* exp_util.adb (Expand_Subtype_From_Expr): Do not expand
expression if its type is derived from a limited type with
unknown discriminants, because the expansion (which is a call)
must be expanded in the enclosing context to add the proper build-
in-place parameters to the call.
* lib.ads, exp_ch9.adb: Minor fixes in comments.
From-SVN: r244790
Arnaud Charlet [Mon, 23 Jan 2017 11:57:27 +0000 (12:57 +0100)]
[multiple changes]
2017-01-23 Yannick Moy <moy@adacore.com>
* frontend.adb (Frontend): Do not load runtime
unit for GNATprove when parsing failed.
* exp_ch9.adb: minor removal of extra whitespace
* exp_ch6.adb: minor typo in comment
* sem_util.adb: Code cleanup.
* exp_ch9.ads, par-ch2.adb: minor style fixes in whitespace and comment
* a-ngcefu.adb: minor style fix in whitespace
2017-01-23 Thomas Quinot <quinot@adacore.com>
* scos.ads: Document usage of 'd' as default SCO kind for
declarations.
* par_sco.adb (Traverse_Declarations_Or_Statements.
Traverse_Degenerate_Subprogram): New supporting routine for expression
functions and null procedures.
(Traverse_Declarations_Or_Statements.Traverse_One): Add
N_Expression_Function to the subprogram case; add required
support for null procedures and expression functions.
2017-01-23 Bob Duff <duff@adacore.com>
* namet.ads (Bounded_String): Decrease the size of type
Bounded_String to avoid running out of stack space.
* namet.ads (Append): Don't ignore buffer overflow; raise
Program_Error instead.
From-SVN: r244789
Arnaud Charlet [Mon, 23 Jan 2017 11:54:05 +0000 (12:54 +0100)]
[multiple changes]
2017-01-23 Hristian Kirtchev <kirtchev@adacore.com>
* exp_ch5.adb, freeze.adb, par-ch4.adb, scng.adb, sem_ch13.adb,
sem_ch3.adb, sem_ch5.adb, sem_ch5.ads, sem_util.adb, sinfo.ads: Minor
reformatting.
* exp_ch9.adb: minor style fix in comment.
2017-01-23 Ed Schonberg <schonberg@adacore.com>
* sem_ch4.adb (Analyze_Allocator): Handle properly a type derived
for a limited record extension with unknown discriminants whose
full view has no discriminants.
2017-01-23 Yannick Moy <moy@adacore.com>
* exp_spark.adb: Alphabetize with clauses.
From-SVN: r244788
Arnaud Charlet [Mon, 23 Jan 2017 11:51:26 +0000 (12:51 +0100)]
[multiple changes]
2017-01-23 Gary Dismukes <dismukes@adacore.com>
* a-calend.adb, prep.adb, debug.adb, prj.ads, prepcomp.adb,
exp_disp.adb, s-imgrea.adb, g-socket.adb, g-socket.ads, sem_ch13.adb,
prj-tree.ads: Minor spelling change for consistency (behaviour ->
behavior).
2017-01-23 Ed Schonberg <schonberg@adacore.com>
* scng.adb (Scan): Use Ada version Ada_2020 to flag use of
Target_Name.
* par-ch4.adb (P_Primary): Ditto.
* opt.ads: Add Ada_2020 (optimistically) to enumeration list of
Ada_Version_Type.
* switch-c.adb (Scan_Front_End_Switches): Recognize -gnat2020 for
new Ada version Ada_2020.
2017-01-23 Hristian Kirtchev <kirtchev@adacore.com>
* exp_attr.adb (Expand_Loop_Entry_Attribute): Force the generation
of a nominal type for the constant which captures the value of
the attribute prefix. Various clean ups.
* sem_attr.adb (Analyze_Attribute): Clean up the processing of
'Loop_Entry.
2017-01-23 Yannick Moy <moy@adacore.com>
* sem_util.adb (Has_Enabled_Property): Treat
protected objects and variables differently from other variables.
From-SVN: r244787
Thomas Quinot [Mon, 23 Jan 2017 11:33:13 +0000 (11:33 +0000)]
sem_ch13.adb (Adjust_Record_For_Reverse_Bit_Order): Split original Ada 95 part off into new subprogram below.
2017-01-23 Thomas Quinot <quinot@adacore.com>
* sem_ch13.adb (Adjust_Record_For_Reverse_Bit_Order):
Split original Ada 95 part off into new subprogram
below. Call that subprogram (instead of proceeding with
AI95-0133 behaviour) if debug switch -gnatd.p is in use.
(Adjust_Record_For_Reverse_Bit_Order_Ada_95): ... new subprogram
* debug.adb Document new switch -gnatd.p
* freeze.adb (Freeze_Entity.Freeze_Record_Type): Do not adjust
record for reverse bit order if an error has already been posted
on the record type. This avoids generating extraneous "info:"
messages for illegal code.
From-SVN: r244786
Justin Squirek [Mon, 23 Jan 2017 11:31:25 +0000 (11:31 +0000)]
sem_ch3.adb (Analyze_Declarations): Correct comments
2017-01-23 Justin Squirek <squirek@adacore.com>
* sem_ch3.adb (Analyze_Declarations): Correct comments
* freeze.adb (Find_Constant): Add detection of deferred constants
so they are not incorrectly flagged as premature.
From-SVN: r244785
Arnaud Charlet [Mon, 23 Jan 2017 11:29:46 +0000 (12:29 +0100)]
Minor reformatting.
From-SVN: r244784
Ed Schonberg [Mon, 23 Jan 2017 11:29:17 +0000 (11:29 +0000)]
scans.ads: New token At_Sign.
2017-01-23 Ed Schonberg <schonberg@adacore.com>
* scans.ads: New token At_Sign. Remove '@' from list of illegal
characters for future version of the language. '@' is legal name.
* scng.ads, scng.adb (Scan): Handle '@' appropriately.
* scn.adb (Scan_Reserved_Identifier): An occurrence of '@'
denotes a Target_Name.
* par-ch4.adb (P_Name, P_Primary): Handle Target_Name.
* sinfo.ads, sinfo.adb (N_Target_Name): New non-terminal node.
(Has_Target_Names): New flag on N_Assignment_Statement, to
indicate that RHS has occurrences of N_Target_Name.
* sem.adb: Call Analyze_Target_Name.
* sem_ch5.ads, sem_ch5.adb (Analyze_Target_Name): New subpogram.
(urrent_LHS): Global variable that denotes LHS of assignment,
used in the analysis of Target_Name nodes.
* sem_res.adb (Resolve_Target_Name): New procedure.
* exp_ch5.adb (Expand_Assign_With_Target_Names): (AI12-0125):
N is an assignment statement whose RHS contains occurences of @
that designate the value of the LHS of the assignment. If the
LHS is side-effect free the target names can be replaced with
a copy of the LHS; otherwise the semantics of the assignment
is described in terms of a procedure with an in-out parameter,
and expanded as such.
(Expand_N_Assignment_Statement): Call
Expand_Assign_With_Target_Names when needed.
* exp_util.adb (Insert_Actions): Take into account N_Target_Name.
* sprint.adb: Handle N_Target_Name.
From-SVN: r244783
Arnaud Charlet [Mon, 23 Jan 2017 11:27:01 +0000 (12:27 +0100)]
[multiple changes]
2017-01-23 Eric Botcazou <ebotcazou@adacore.com>
* checks.adb: Minor fix in comment.
2017-01-23 Philippe Gil <gil@adacore.com>
* g-debpoo.adb (Do_Report) remove freed chunks from chunks
count in Sort = Memory_Usage or Allocations_Count
2017-01-23 Justin Squirek <squirek@adacore.com>
* sem_ch3.adb: Code cleanup.
2017-01-23 Hristian Kirtchev <kirtchev@adacore.com>
* sem_prag.adb (Analyze_Refined_Depends_In_Decl_Part): Move all global
variables to the local variable section. Update the profile
of various nested routine that previously had visibility
of those globals. One the matching phase has completed,
remove certain classes of clauses which are considered noise.
(Check_Dependency_Clause): Properly detect a match between two
'Result attributes. Update the various post-match cases to use
Is_Already_Matched as this routine now automatically recognizes
a previously matched 'Result attribute.
(Is_Already_Matched): New routine.
(Remove_Extra_Clauses): New routine.
(Report_Extra_Clauses): Remove the detection of ... => null
clauses as this is now done in Remove_Extra_Clauses.
From-SVN: r244782
Arnaud Charlet [Mon, 23 Jan 2017 11:24:32 +0000 (12:24 +0100)]
Fix typo.
From-SVN: r244781
Arnaud Charlet [Mon, 23 Jan 2017 11:23:48 +0000 (12:23 +0100)]
[multiple changes]
2017-01-23 Ed Schonberg <schonberg@adacore.com>
* sem_aggr.adb (Resolve_Array_Aggregate): In ASIS mode do not
report on spurious overlaps between values involving a subtype
with a static predicate, because the expansion of such a subtype
into individual ranges in inhibited in ASIS mode.
2017-01-23 Justin Squirek <squirek@adacore.com>
* sem_ch3.adb (Analyze_Declarations): Add detection
of an edge case and delay freezing if it is present.
From-SVN: r244780
Kyrylo Tkachov [Mon, 23 Jan 2017 11:22:54 +0000 (11:22 +0000)]
[testsuite] Fix FAIL: gcc.dg/lto/pr69188 on bare-metal targets
PR lto/69188
* gcc.dg/lto/pr69188_0.c: Require profiling support for testcase.
From-SVN: r244779
Hristian Kirtchev [Mon, 23 Jan 2017 11:21:37 +0000 (11:21 +0000)]
sem_ch3.adb, [...]: Minor reformatting.
2017-01-23 Hristian Kirtchev <kirtchev@adacore.com>
* sem_ch3.adb, exp_spark.adb, exp_attr.adb, sem_ch9.adb, sem_prag.adb,
sem_util.adb, sem_warn.adb, exp_ch3.adb: Minor reformatting.
2017-01-23 Hristian Kirtchev <kirtchev@adacore.com>
* freeze.adb (Freeze_Subprogram): Ensure that all anonymous
access-to-subprogram types inherit the convention of the
associated subprogram. (Set_Profile_Convention): New routine.
* sem_ch6.adb (Check_Conformance): Do not compare the conventions
of the two entities directly, use Conventions_Match to account
for anonymous access-to-subprogram and subprogram types.
(Conventions_Match): New routine.
From-SVN: r244778
Claire Dross [Mon, 23 Jan 2017 11:19:56 +0000 (11:19 +0000)]
exp_spark.adb (Expand_SPARK_Attribute_Reference): For attributes which return Universal_Integer...
2017-01-23 Claire Dross <dross@adacore.com>
* exp_spark.adb (Expand_SPARK_Attribute_Reference): For attributes
which return Universal_Integer, force the overflow check flag for
Length and Range_Length for types as big as Long_Long_Integer.
From-SVN: r244777
Arnaud Charlet [Mon, 23 Jan 2017 11:19:07 +0000 (12:19 +0100)]
[multiple changes]
2017-01-23 Claire Dross <dross@adacore.com>
* exp_spark.adb (Expand_SPARK_Attribute_Reference): For
attributes which return Universal_Integer, introduce a conversion
to the expected type with the appropriate check flags set.
* sem_res.adb (Resolve_Range): The higher bound can be in Typ's
base type if the range is null. It may still be invalid if it
is higher than the lower bound. This is checked later in the
context in which the range appears.
2017-01-23 Pierre-Marie de Rodat <derodat@adacore.com>
* scos.ads: Introduce a constant to represent ignored
dependencies in SCO_Unit_Table_Entry.
From-SVN: r244776
Arnaud Charlet [Mon, 23 Jan 2017 11:17:23 +0000 (12:17 +0100)]
[multiple changes]
2017-01-23 Hristian Kirtchev <kirtchev@adacore.com>
* exp_ch9.adb (Expand_N_Protected_Type_Declaration): Remove extra
spaces from error messages.
2017-01-23 Ed Schonberg <schonberg@adacore.com>
* exp_ch3.adb (Check_Large_Modular_Array): New procedure,
subsidiary to Expand_N_Object_ Declaration, to compute a guard on
an object declaration for an array type with a modular index type
with the size of Long_Long_Integer. Special processing is needed
in this case to compute reliably the size of the object, and
eventually to raise Storage_Error, when wrap-around arithmetic
might compute a meangingless size for the object.
2017-01-23 Justin Squirek <squirek@adacore.com>
* a-wtenau.adb, par-endh.adb, sem_prag.adb,
sem_type.adb: Code cleanups.
From-SVN: r244775
Bob Duff [Mon, 23 Jan 2017 11:13:23 +0000 (11:13 +0000)]
sem_res.adb (Resolve_Call): In the part of the code where it is deciding whether to turn the call into an...
2017-01-23 Bob Duff <duff@adacore.com>
* sem_res.adb (Resolve_Call): In the part of the code where
it is deciding whether to turn the call into an indexed
component, avoid doing so if the call is to an instance of
Unchecked_Conversion. Otherwise, the compiler turns it into an
indexed component, and resolution of that turns it back into a
function call, and so on, resulting in infinite recursion.
* sem_util.adb (Needs_One_Actual): If the first formal has a
default, then return False.
From-SVN: r244774
Maxim Ostapenko [Mon, 23 Jan 2017 09:12:29 +0000 (11:12 +0200)]
re PR lto/79061 ([LTO][ASAN] LTO plus ASAN fails with "AddressSanitizer: initialization-order-fiasco")
Revert fix for PR lto/79061 due to this regresses compile-time by 100%
on some fortran cases.
From-SVN: r244773
Christophe Lyon [Mon, 23 Jan 2017 08:56:36 +0000 (08:56 +0000)]
[ARM,AArch64][testsuite] Fix format string in AdvSIMD tests.
2017-01-23 Christophe Lyon <christophe.lyon@linaro.org>
* gcc.target/aarch64/advsimd-intrinsics/arm-neon-ref.h (CHECK_POLY): New.
(CHECK_RESULTS_NAMED_NO_FP16): Call CHECK_POLY instead of CHECK
for poly*_t types.
* gcc.target/aarch64/advsimd-intrinsics/vcnt.c (FNNAME): Likewise.
* gcc.target/aarch64/advsimd-intrinsics/vcombine.c (void
exec_vcombine): Likewise.
* gcc.target/aarch64/advsimd-intrinsics/vcreate.c (FNNAME): Likewise.
* gcc.target/aarch64/advsimd-intrinsics/vget_high.c (void exec_vget_high): Likewise.
* gcc.target/aarch64/advsimd-intrinsics/vget_low.c (void exec_vget_low): Likewise.
* gcc.target/aarch64/advsimd-intrinsics/vldX.c (void exec_vldX): Likewise.
* gcc.target/aarch64/advsimd-intrinsics/vldX_dup.c (void exec_vldX_dup): Likewise.
* gcc.target/aarch64/advsimd-intrinsics/vldX_lane.c (void exec_vldX_lane): Likewise.
* gcc.target/aarch64/advsimd-intrinsics/vmul.c: Likewise.
* gcc.target/aarch64/advsimd-intrinsics/vmvn.c: Likewise.
* gcc.target/aarch64/advsimd-intrinsics/vqtbX.c (void exec_vqtbX): Likewise.
* gcc.target/aarch64/advsimd-intrinsics/vreinterpret_p128.c: Likewise.
* gcc.target/aarch64/advsimd-intrinsics/vrev.c (void exec_vrev): Likewise.
* gcc.target/aarch64/advsimd-intrinsics/vsXi_n.inc: Likewise.
* gcc.target/aarch64/advsimd-intrinsics/vshuffle.inc: Likewise.
* gcc.target/aarch64/advsimd-intrinsics/vsli_n.c (void vsli_extra): Likewise.
* gcc.target/aarch64/advsimd-intrinsics/vsri_n.c (void vsri_extra): Likewise.
* gcc.target/aarch64/advsimd-intrinsics/vstX_lane.c (void exec_vstX_lane): Likewise.
* gcc.target/aarch64/advsimd-intrinsics/vtbX.c (void exec_vtbX): Likewise.
* gcc.target/aarch64/advsimd-intrinsics/p64_p128.c (int main):
Likewise.
(TEST_VGET_LANE): Cast to uint to avoid warning.
* gcc.target/aarch64/advsimd-intrinsics/unary_sat_op.inc (void
FNNAME): Fix PRIx format for int16_t, int32_t, uint16_t, uint32_t.
* gcc.target/aarch64/advsimd-intrinsics/vfms_vfma_n.c (void
exec_vfma_vfms_n): Fix PRIx format for float64_t.
* gcc.target/aarch64/advsimd-intrinsics/vmovn.c (void exec_vmovn):
Fix PRIx format for int8_t, int16_t, uint8_t, uint16_t.
* gcc.target/aarch64/advsimd-intrinsics/vmul_lane.c (void
exec_vmul_lane): Fix PRIx format for int16_t, uint16_t.
* gcc.target/aarch64/advsimd-intrinsics/vmul_n.c: Likewise.
* gcc.target/aarch64/advsimd-intrinsics/vmull.c (void exec_vmull):
Fix PRIx format for int16_t, int64_t, uint16_t, uint64_t. Call
CHECK_POLY instead of CHECK for poly64_t types.
* gcc.target/aarch64/advsimd-intrinsics/vmull_lane.c (void
exec_vmull_lane): Fix PRIx format for int64_t, uint64_t.
* gcc.target/aarch64/advsimd-intrinsics/vpXXX.inc:
Fix PRIx format for int8_t, int16_t, uint8_t, uint16_t.
* gcc.target/aarch64/advsimd-intrinsics/vqabs.c (void
vqabs_extra): Fix PRIx format for int16_t, int32_t, uint16_t,
uint32_t.
* gcc.target/aarch64/advsimd-intrinsics/vqdmull.c: Fix PRIx format
for int32_t, int64_t.
* gcc.target/aarch64/advsimd-intrinsics/vqneg.c (void
vqneg_extra): Fix PRIx format for int16_t, int32_t.
* gcc.target/aarch64/advsimd-intrinsics/vreinterpret_p64.c
(TEST_VREINTERPRET_TO_POLY): New. (main): Call
TEST_VREINTERPRET_TO_POLY instead of TEST_VREINTERPRET where
needed.
From-SVN: r244772
Gerald Pfeifer [Mon, 23 Jan 2017 07:24:15 +0000 (07:24 +0000)]
patch_tester.sh (TESTLOGS): Remove $TARGET/libjava/testsuite/libjava.sum.
* patch_tester.sh (TESTLOGS): Remove
$TARGET/libjava/testsuite/libjava.sum.
From-SVN: r244771
Gerald Pfeifer [Mon, 23 Jan 2017 07:18:42 +0000 (07:18 +0000)]
* doc/xml/manual/debug.xml: code.google.com uses https now.
From-SVN: r244770
GCC Administrator [Mon, 23 Jan 2017 00:16:16 +0000 (00:16 +0000)]
Daily bump.
From-SVN: r244769
Gerald Pfeifer [Sun, 22 Jan 2017 20:53:48 +0000 (20:53 +0000)]
* warn_summary: Remove the -java option.
From-SVN: r244766
Gerald Pfeifer [Sun, 22 Jan 2017 20:39:06 +0000 (20:39 +0000)]
* doc/xml/manual/test.xml: Fix link into gccint online manual.
From-SVN: r244765
Gerald Pfeifer [Sun, 22 Jan 2017 20:29:34 +0000 (20:29 +0000)]
install.texi (Specific): opensource.apple.com uses https now.
* doc/install.texi (Specific): opensource.apple.com uses https
now. Remove trailing slash.
From-SVN: r244764
Jakub Jelinek [Sun, 22 Jan 2017 19:36:57 +0000 (20:36 +0100)]
re PR fortran/79154 (omp declare simd in pure function?)
PR fortran/79154
* parse.c (matchs, matcho, matchds, matchdo): Replace return st;
with { ret = st; goto finish; }.
(decode_omp_directive): Allow declare simd, declare target and
simd directives in PURE/ELEMENTAL procedures. Only call
gfc_unset_implicit_pure on successful match of other procedures.
* gfortran.dg/gomp/pr79154-1.f90: New test.
* gfortran.dg/gomp/pr79154-2.f90: New test.
From-SVN: r244763
Matthias Klose [Sun, 22 Jan 2017 18:07:04 +0000 (18:07 +0000)]
2017-01-22 Matthias Klose <doko@ubuntu.com>
* Import zlib 1.2.11.
* configure: Regenerate.
Changes in 1.2.11 (15 Jan 2017)
- Fix deflate stored bug when pulling last block from window
- Permit immediate deflateParams changes before any deflate input
From-SVN: r244762
Gerald Pfeifer [Sun, 22 Jan 2017 15:52:02 +0000 (15:52 +0000)]
* README.Portability: Remove note on an Irix compatibility issue.
From-SVN: r244759
Dimitry Andric [Sun, 22 Jan 2017 15:48:21 +0000 (15:48 +0000)]
gcov.c (INCLUDE_ALGORITHM): Define.
* gcov.c (INCLUDE_ALGORITHM): Define.
(INCLUDE_VECTOR): Define.
No longer include <vector> and <algorithm> directly.
From-SVN: r244758
Andreas Schwab [Sun, 22 Jan 2017 12:46:39 +0000 (12:46 +0000)]
* gcc.dg/tree-ssa/pr77445-2.c: Quote brackets.
From-SVN: r244757
GCC Administrator [Sun, 22 Jan 2017 00:16:13 +0000 (00:16 +0000)]
Daily bump.
From-SVN: r244756
Gerald Pfeifer [Sat, 21 Jan 2017 21:53:32 +0000 (21:53 +0000)]
extend.texi (Thread-Local): Change akkadia.org reference to https.
* doc/extend.texi (Thread-Local): Change www.akkadia.org reference
to https.
* doc/invoke.texi (Code Gen Options): Ditto.
From-SVN: r244751
Gerald Pfeifer [Sat, 21 Jan 2017 20:37:01 +0000 (20:37 +0000)]
gfc-internals.texi (Symbol Versioning): Change references to akkadia.org to https.
* gfc-internals.texi (Symbol Versioning): Change references
to www.akkadia.org to https.
From-SVN: r244750
Jan Hubicka [Sat, 21 Jan 2017 19:36:01 +0000 (20:36 +0100)]
re PR lto/78407 (LTO breaks separate overriding of symbol aliases)
PR lto/78407
* cfg.c (update_bb_profile_for_threading): Fix updating of probablity.
From-SVN: r244749
Ville Voutilainen [Sat, 21 Jan 2017 15:38:23 +0000 (17:38 +0200)]
Make poisoned hashes SFINAE away the call operator of the hash.
* include/bits/functional_hash.h
(__poison_hash::__enable_hash_call): New.
* include/std/optional (__optional_hash_call_base): New.
(hash<optional<_Tp>>): Derive from the new base,
move the hash function into that base.
* include/std/variant (__variant_hash_call_base_impl): New.
(__variant_hash_call_base): Likewise.
(hash<variant<_Types...>>): Derive from the new base,
move the hash function into that base.
* testsuite/20_util/optional/hash.cc: Add tests for is_callable.
* testsuite/20_util/variant/hash.cc: Likewise.
From-SVN: r244748
Marek Polacek [Sat, 21 Jan 2017 12:00:40 +0000 (12:00 +0000)]
re PR testsuite/79169 (g++.dg/warn/Wduplicated-branches1.C fails on powerpc since its introduction in r244705)
PR testsuite/79169
* g++.dg/warn/Wduplicated-branches1.C: Use signed char.
From-SVN: r244747
Jan Hubicka [Sat, 21 Jan 2017 11:33:44 +0000 (12:33 +0100)]
* gcc.dg/tree-ssa/pr77445-2.c: Adjust template.
From-SVN: r244746
Eric Botcazou [Sat, 21 Jan 2017 11:10:00 +0000 (11:10 +0000)]
sem_eval.adb (Compile_Time_Compare): Reinstate the expr+literal (etc) optimizations when...
* sem_eval.adb (Compile_Time_Compare): Reinstate the expr+literal (etc)
optimizations when the type is modular and the offsets are equal.
From-SVN: r244745
Jakub Jelinek [Sat, 21 Jan 2017 10:30:54 +0000 (11:30 +0100)]
gfortran.h (gfc_extract_int): Change return type to bool.
* gfortran.h (gfc_extract_int): Change return type to bool. Add
int argument with = 0.
* decl.c (gfc_match_kind_spec): Adjust gfc_extract_int caller, pass
1 as new last argument to it, don't emit gfc_error.
(match_char_kind): Likewise.
(gfc_match_decl_type_spec): Use gfc_get_string ("%s", x) instead of
gfc_get_string (x).
(gfc_match_derived_decl, match_binding_attributes): Likewise.
(gfc_match_structure_decl): Don't sprintf back to name, call
get_struct_decl directly with gfc_dt_upper_string (name) result.
* trans-stmt.c (gfc_trans_allocate): Use gfc_get_string ("%s", x)
instead of gfc_get_string (x).
* module.c (gfc_dt_lower_string, gfc_dt_upper_string,
gfc_match_use, gfc_match_submodule, find_true_name, mio_pool_string,
mio_symtree_ref, mio_expr, mio_omp_udr_expr, load_generic_interfaces,
load_omp_udrs, load_needed, read_module, dump_module,
create_intrinsic_function, import_iso_c_binding_module,
create_int_parameter, create_int_parameter_array, create_derived_type,
use_iso_fortran_env_module): Likewise.
* error.c (gfc_diagnostic_starter, gfc_diagnostic_start_span): Use
pp_verbatim (context->printer, "%s", x) instead of
pp_verbatim (context->printer, x).
* match.c (gfc_match_small_int): Adjust gfc_extract_int caller, pass
1 as new last argument to it, don't emit gfc_error.
(gfc_match_small_int_expr): Likewise.
* iresolve.c (gfc_get_string): Optimize format "%s" case.
(resolve_bound): Use gfc_get_string ("%s", x) instead of
gfc_get_string (x).
(resolve_transformational): Formatting fix.
(gfc_resolve_char_achar): Change name argument to bool is_achar,
use a single format string and if is_achar add "a" before "char".
(gfc_resolve_achar, gfc_resolve_char): Adjust callers.
* expr.c (gfc_extract_int): Change return type to bool, return true
if some error occurred. Add REPORT_ERROR argument, if non-zero
call either gfc_error or gfc_error_now depending on its sign.
* arith.c (arith_power): Adjust gfc_extract_int caller.
* symbol.c (gfc_add_component): Use gfc_get_string ("%s", x) instead
of gfc_get_string (x).
(gfc_new_symtree, gfc_delete_symtree, gfc_get_uop, gfc_new_symbol,
gfc_get_gsymbol, generate_isocbinding_symbol): Likewise.
* openmp.c (gfc_match_omp_clauses): Adjust gfc_extract_int caller, pass
-1 as new last argument to it, don't emit gfc_error_now.
(gfc_match_omp_declare_reduction): Use gfc_get_string ("%s", x)
instead of gfc_get_string (x).
* check.c (kind_check): Adjust gfc_extract_int caller.
* intrinsic.c (add_sym, find_sym, make_alias): Use
gfc_get_string ("%s", x) instead of gfc_get_string (x).
* simplify.c (get_kind, gfc_simplify_btest, gfc_simplify_maskr,
gfc_simplify_maskl, gfc_simplify_poppar, gfc_simplify_repeat,
gfc_simplify_selected_int_kind, gfc_simplify_selected_real_kind):
Adjust gfc_extract_int callers.
* trans-decl.c (gfc_find_module): Use gfc_get_string ("%s", x)
instead of gfc_get_string (x).
* matchexp.c (expression_syntax): Add const.
* primary.c (match_kind_param, match_hollerith_constant,
match_string_constant): Adjust gfc_extract_int callers.
(match_keyword_arg): Use gfc_get_string ("%s", x) instead of
gfc_get_string (x).
* frontend-passes.c (optimize_minmaxloc): Likewise.
From-SVN: r244744
Gerald Pfeifer [Sat, 21 Jan 2017 08:52:32 +0000 (08:52 +0000)]
* config/i386/cygming-crtbegin.c (LIBGCJ_SONAME): No longer #define.
From-SVN: r244743
Jakub Jelinek [Sat, 21 Jan 2017 08:47:11 +0000 (09:47 +0100)]
re PR other/79046 (g++ -print-file-name=plugin uses full version number in path)
PR other/79046
libatomic/
* testsuite/Makefile.am (gcc_version): Use @get_gcc_base_ver@ instead
of cat to get version from BASE-VER file.
* testsuite/Makefile.in: Regenerated.
libffi/
* configure.ac: Add GCC_BASE_VER.
* include/Makefile.am (gcc_version): Use @get_gcc_base_ver@ instead
of cat to get version from BASE-VER file.
* configure: Regenerated.
* testsuite/Makefile.in: Regenerated.
* include/Makefile.in: Regenerated.
* Makefile.in: Regenerated.
* man/Makefile.in: Regenerated.
libgomp/
* testsuite/Makefile.am (gcc_version): Use @get_gcc_base_ver@ instead
of cat to get version from BASE-VER file.
* testsuite/Makefile.in: Regenerated.
libitm/
* testsuite/Makefile.am (gcc_version): Use @get_gcc_base_ver@ instead
of cat to get version from BASE-VER file.
* testsuite/Makefile.in: Regenerated.
libmpx/
* mpxrt/Makefile.am (gcc_version): Use @get_gcc_base_ver@ instead
of cat to get version from BASE-VER file.
* mpxwrap/Makefile.am (gcc_version): Likewise.
* mpxrt/Makefile.in: Regenerated.
* mpxwrap/Makefile.in: Regenerated.
liboffloadmic/
* plugin/configure.ac: Add GCC_BASE_VER.
* plugin/Makefile.am (gcc_version): Use @get_gcc_base_ver@ instead
of cat to get version from BASE-VER file.
* plugin/configure: Regenerated.
* plugin/aclocal.m4: Regenerated.
* plugin/Makefile.in: Regenerated.
libsanitizer/
* interception/Makefile.am (gcc_version): Use @get_gcc_base_ver@
instead of cat to get version from BASE-VER file.
* asan/Makefile.am (gcc_version): Likewise.
* ubsan/Makefile.am (gcc_version): Likewise.
* sanitizer_common/Makefile.am (gcc_version): Likewise.
* lsan/Makefile.am (gcc_version): Likewise.
* tsan/Makefile.am (gcc_version): Likewise.
* interception/Makefile.in: Regenerated.
* asan/Makefile.in: Regenerated.
* ubsan/Makefile.in: Regenerated.
* sanitizer_common/Makefile.in: Regenerated.
* lsan/Makefile.in: Regenerated.
* tsan/Makefile.in: Regenerated.
libvtv/
* testsuite/Makefile.am (gcc_version): Use @get_gcc_base_ver@ instead
of cat to get version from BASE-VER file.
* testsuite/Makefile.in: Regenerated.
From-SVN: r244742
Bernd Schmidt [Sat, 21 Jan 2017 07:23:47 +0000 (00:23 -0700)]
re PR rtl-optimization/79125 (ICE in rtl_verify_bb_insns, at cfgrtl.c:2661 (error: flow control insn inside a basic block))
2017-01-21 Bernd Schmidt <bschmidt@redhat.com>
rtl-optimization/79125
* cprop.c (local_cprop_pass): Handle cases where we make an
unconditional trap.
PR rtl-optimization/79125
* gcc.dg/torture/pr79125.c: New test.
From-SVN: r244741
Segher Boessenkool [Sat, 21 Jan 2017 03:11:49 +0000 (04:11 +0100)]
rs6000: Small varargs for BE SVR4 (PR61729, PR77850)
The varargs code for SVR4 puts all (integer) arguments in 4-byte slots.
When it then reads an item from there as something not a multiple of 4
bytes, it needs to adjust the address if big endian. We didn't yet do
that.
This fixes the g++.dg/abi/scoped1.C, gcc.dg/compat/scalar-by-value-4,
and gcc.dg/compat/scalar-return-4 testcases.
PR target/61729
PR target/77850
* config/rs6000/rs6000.c (rs6000_gimplify_va_arg): Adjust address to
read from, for big endian.
From-SVN: r244740
GCC Administrator [Sat, 21 Jan 2017 00:16:25 +0000 (00:16 +0000)]
Daily bump.
From-SVN: r244739
Ian Lance Taylor [Fri, 20 Jan 2017 21:18:37 +0000 (21:18 +0000)]
runtime, testing/internal/testdeps: fixes for cgo
Some fixes that permit misc/cgo/test in the master gc repository to
pass using the current gccgo.
Install testing/internal/testdeps.gox; it is needed by `go test`.
Export runtime.lockedOSThread to enable calling via go:linkname; it is
used by misc/cgo/test.
Loop on EAGAIN when creating a new thread; this is what the gc code
does, and misc/cgo/test tests that it works.
Reviewed-on: https://go-review.googlesource.com/35479
From-SVN: r244733
Jiong Wang [Fri, 20 Jan 2017 21:03:41 +0000 (21:03 +0000)]
[AArch64] Only build & test pauth code for LP64
gcc/
* config/aarch64/aarch64-builtins.c (aarch64_init_builtins): Register
register pauth builtins for LP64 only.
libgcc/
* config/aarch64/aarch64-unwind.h: Empty this file on ILP32.
* unwind-dw2.c (execute_cfa_program): Only multiplexing
DW_CFA_GNU_window_save for AArch64 and LP64.
gcc/testsuite/
* testsuite/gcc.target/aarch64/return_address_sign_1.c: Enable on LP64
only.
* testsuite/gcc.target/aarch64/return_address_sign_2.c: Likewise.
* testsuite/gcc.target/aarch64/return_address_sign_3.c: Likewise.
From-SVN: r244732
Ian Lance Taylor [Fri, 20 Jan 2017 20:39:10 +0000 (20:39 +0000)]
re PR go/79146 (Bootstrapping go on s390x fails; redefined symbols)
PR go/79146
math/big: fix build on s390x
Don't build arith_decl_s390x.go for gccgo; it is only for assembly
code that has not yet been ported to gccgo.
For GCC PR 79146.
From-SVN: r244731
Nathan Sidwell [Fri, 20 Jan 2017 17:53:44 +0000 (17:53 +0000)]
PR c++/78495 - wrong code inherited ctor and invisi-ref parm
PR c++/78495 - wrong code inherited ctor and invisi-ref parm
* cp-gimplify.c (cp_generize_r): Don't skip thunks.
PR c++/79495
* g++.dg/cpp1z/inh-ctor38.C: New.
From-SVN: r244728
Joe Seymour [Fri, 20 Jan 2017 17:46:36 +0000 (17:46 +0000)]
Support unsigned __int20 in checks for size_t mangling
2017-01-20 Joe Seymour <joe.s@somniumtech.com>
* acinclude.m4 (GLIBCXX_CHECK_SIZE_T_MANGLING): Support uint20_t.
* configure: Regenerate.
From-SVN: r244727
Marek Polacek [Fri, 20 Jan 2017 16:28:16 +0000 (16:28 +0000)]
re PR c/79152 (-Wimplicit-fallthrough false positive triggered by goto statements)
PR c/79152
* gimplify.c (should_warn_for_implicit_fallthrough): Handle consecutive
non-case labels.
* c-c++-common/Wimplicit-fallthrough-35.c: New test.
From-SVN: r244726
Eric Botcazou [Fri, 20 Jan 2017 15:55:15 +0000 (15:55 +0000)]
Remove orphaned entries
From-SVN: r244725
Thomas Preud'homme [Fri, 20 Jan 2017 15:29:21 +0000 (15:29 +0000)]
Skip optional_mthumb tests if GCC has a default mode
2017-01-20 Thomas Preud'homme <thomas.preudhomme@arm.com>
gcc/testsuite/
* lib/target-supports.exp (check_configured_with): New procedure.
(check_effective_target_default_mode): new effective target.
* gcc.target/arm/optional_thumb-1.c: Skip if GCC was configured with a
default mode. Fix dg-skip-if target selector syntax.
* gcc.target/arm/optional_thumb-2.c: Likewise.
* gcc.target/arm/optional_thumb-3.c: Fix dg-skip-if target selector
syntax.
From-SVN: r244723
Jonathan Wakely [Fri, 20 Jan 2017 15:28:48 +0000 (15:28 +0000)]
PR69240 Define inequality operators for <random> param types
PR libstdc++/69240
* include/bits/random.h (uniform_real_distribution::param_type)
(normal_distribution::param_type, lognormal_distribution::param_type)
(gamma_distribution::param_type, chi_squared_distribution::param_type)
(cauchy_distribution::param_type, fisher_f_distribution::param_type)
(student_t_distribution::param_type)
(bernoulli_distribution::param_type, binomial_distribution::param_type)
(geometric_distribution::param_type)
(negative_binomial_distribution::param_type)
(poisson_distribution::param_type)
(exponential_distribution::param_type)
(weibull_distribution::param_type)
(extreme_value_distribution::param_type)
(discrete_distribution::param_type)
(piecewise_constant_distribution::param_type)
(piecewise_linear_distribution::param_type): Define operator!=.
* include/bits/uniform_int_dist.h
(uniform_int_distribution::param_type): Likewise.
* include/ext/random (beta_distribution::param_type)
(rice_distribution::param_type, nakagami_distribution::param_type)
(pareto_distribution::param_type, k_distribution::param_type)
(arcsine_distribution::param_type, hoyt_distribution::param_type)
(triangular_distribution::param_type)
(von_mises_distribution::param_type)
(hypergeometric_distribution::param_type)
(logistic_distribution::param_type)
(uniform_on_sphere_distribution::param_type)
(uniform_inside_sphere_distribution::param_type): Likewise.
* testsuite/26_numerics/random/bernoulli_distribution/cons/parms.cc:
Test construction with param_type.
* testsuite/26_numerics/random/binomial_distribution/cons/parms.cc:
Likewise.
* testsuite/26_numerics/random/cauchy_distribution/cons/parms.cc:
Likewise.
* testsuite/26_numerics/random/chi_squared_distribution/cons/parms.cc:
Likewise.
* testsuite/26_numerics/random/exponential_distribution/cons/parms.cc:
Likewise.
* testsuite/26_numerics/random/extreme_value_distribution/cons/
parms.cc: Likewise.
* testsuite/26_numerics/random/fisher_f_distribution/cons/parms.cc:
Likewise.
* testsuite/26_numerics/random/gamma_distribution/cons/parms.cc:
Likewise.
* testsuite/26_numerics/random/geometric_distribution/cons/parms.cc:
Likewise.
* testsuite/26_numerics/random/lognormal_distribution/cons/parms.cc:
Likewise.
* testsuite/26_numerics/random/negative_binomial_distribution/cons/
parms.cc: Likewise.
* testsuite/26_numerics/random/normal_distribution/cons/parms.cc:
Likewise.
* testsuite/26_numerics/random/poisson_distribution/cons/parms.cc:
Likewise.
* testsuite/26_numerics/random/student_t_distribution/cons/parms.cc:
Likewise.
* testsuite/26_numerics/random/uniform_int_distribution/cons/parms.cc:
Likewise.
* testsuite/26_numerics/random/uniform_real_distribution/cons/parms.cc:
Likewise.
* testsuite/26_numerics/random/weibull_distribution/cons/parms.cc:
Likewise.
* testsuite/ext/random/arcsine_distribution/cons/parms.cc: Likewise.
* testsuite/ext/random/beta_distribution/cons/parms.cc: Likewise.
* testsuite/ext/random/hoyt_distribution/cons/parms.cc: Likewise.
* testsuite/ext/random/hypergeometric_distribution/cons/parms.cc:
Likewise.
* testsuite/ext/random/k_distribution/cons/parms.cc: Likewise.
* testsuite/ext/random/logistic_distribution/cons/parms.cc: Likewise.
* testsuite/ext/random/nakagami_distribution/cons/parms.cc: Likewise.
* testsuite/ext/random/normal_mv_distribution/cons/parms.cc: Likewise.
* testsuite/ext/random/pareto_distribution/cons/parms.cc: Likewise.
* testsuite/ext/random/rice_distribution/cons/parms.cc: Likewise.
* testsuite/ext/random/triangular_distribution/cons/parms.cc:
Likewise.
* testsuite/ext/random/uniform_inside_sphere_distribution/cons/
parms.cc: Likewise.
* testsuite/ext/random/von_mises_distribution/cons/parms.cc: Likewise.
From-SVN: r244722
Arnaud Charlet [Fri, 20 Jan 2017 14:51:39 +0000 (15:51 +0100)]
[multiple changes]
2017-01-20 Thomas Quinot <quinot@adacore.com>
* sem_warn.adb (Warn_On_Useless_Assignment): Adjust wording of warning
message.
2017-01-20 Nicolas Roche <roche@adacore.com>
* terminals.c: Ignore failures on setpgid and tcsetpgrp commands.
2017-01-20 Bob Duff <duff@adacore.com>
* sem_eval.adb (Compile_Time_Compare): Disable the expr+literal
(etc) optimizations when the type is modular.
2017-01-20 Yannick Moy <moy@adacore.com>
* sem_ch6.adb (Move_Pragmas): move some pragmas,
but copy the SPARK_Mode pragma instead of moving it.
(Build_Subprogram_Declaration): Ensure that the generated spec
and original body share the same SPARK_Pragma aspect/pragma.
* sem_util.adb, sem_util.ads (Copy_SPARK_Mode_Aspect): New
procedure to copy SPARK_Mode aspect.
2017-01-20 Bob Duff <duff@adacore.com>
* sem_ch3.adb (Analyze_Declarations): Disable Resolve_Aspects
even in ASIS mode.
* sem_ch13.adb (Resolve_Name): Enable setting the entity to
Empty even in ASIS mode.
From-SVN: r244720
Gerald Pfeifer [Fri, 20 Jan 2017 14:50:19 +0000 (14:50 +0000)]
* update-copyright.py (LibJavaFilter): Remove.
From-SVN: r244719
Arnaud Charlet [Fri, 20 Jan 2017 14:49:28 +0000 (15:49 +0100)]
[multiple changes]
2017-01-20 Hristian Kirtchev <kirtchev@adacore.com>
* exp_ch9.adb: minor style fixes in comments.
* sem_ch9.adb (Analyze_Delay_Relative): in GNATprove mode a delay
relative statement introduces an implicit dependency on
Ada.Real_Time.Clock_Time.
* sem_util.adb: Minor reformatting.
2017-01-20 Ed Schonberg <schonberg@adacore.com>
* sem_ch13.adb (Analyze_Aspect_Specifications): Aspect Alignment
must be treated as delayed aspect even if the expression is
a literal, because the aspect affects the freezing and the
elaboration of the object to which it applies.
2017-01-20 Tristan Gingold <gingold@adacore.com>
* s-osinte-vxworks.ads (Interrup_Range): New subtype.
2017-01-20 Ed Schonberg <schonberg@adacore.com>
* lib-xref.adb (Generate_Reference): Do not warn about the
presence of a pragma Unreferenced if the entity appears as the
actual in a procedure call that does not come from source.
2017-01-20 Pascal Obry <obry@adacore.com>
* expect.c, terminals.c: Fix some warnings about unused variables.
* gsocket.h, adaint.c, adaint.h: Fix some more warnings in the C part
of the runtime.
2017-01-20 Bob Duff <duff@adacore.com>
* exp_attr.adb (Constrained): Apply an access check (check that
the prefix is not null) when the prefix denotes an object of an
access type; that is, when there is an implicit dereference.
2017-01-20 Gary Dismukes <dismukes@adacore.com>
* s-rident.ads (constant Profile_Info): Remove
No_Calendar from GNAT_Extended_Ravenscar restrictions.
2017-01-20 Tristan Gingold <gingold@adacore.com>
* s-maccod.ads: Add pragma No_Elaboration_Code_All
From-SVN: r244718
Alexander Monakov [Fri, 20 Jan 2017 14:38:18 +0000 (17:38 +0300)]
omp-offload: use PROP_gimple_lomp_dev
* omp-expand.c (expand_omp_simd): Clear PROP_gimple_lomp_dev regardless
of safelen status.
* omp-offload.c (pass_omp_device_lower::gate): Use PROP_gimple_lomp_dev.
* passes.c (dump_properties): Handle PROP_gimple_lomp_dev.
* tree-inline.c (expand_call_inline): Propagate PROP_gimple_lomp_dev.
From-SVN: r244717
Kyrylo Tkachov [Fri, 20 Jan 2017 14:36:57 +0000 (14:36 +0000)]
[ARM] PR target/71270 fix neon_valid_immediate for big-endian
PR target/71270
* config/arm/arm.c (neon_valid_immediate): Reject vector constants
in big-endian mode when they are not a single duplicated value.
From-SVN: r244716
David Malcolm [Fri, 20 Jan 2017 14:36:46 +0000 (14:36 +0000)]
C++: fix fix-it hints for misspellings within explicit namespaces
gcc/cp/ChangeLog:
PR c++/77829
PR c++/78656
* cp-tree.h (suggest_alternatives_for): Add bool param.
(suggest_alternative_in_explicit_scope): New decl.
* error.c (qualified_name_lookup_error): When SCOPE is a namespace
that isn't the global one, call new function
suggest_alternative_in_explicit_scope, only calling
suggest_alternatives_for if it fails, and disabling near match
searches fort that case. When SCOPE is the global namespace,
pass true for new param to suggest_alternatives_for to allow for
fuzzy name lookups.
* lex.c (unqualified_name_lookup_error): Pass true for new param
to suggest_alternatives_for.
* name-lookup.c (consider_binding_level): Add forward decl.
(suggest_alternatives_for): Add "suggest_misspellings" param,
using it to conditionalize the fuzzy name-lookup code.
(suggest_alternative_in_explicit_scope): New function.
* parser.c (cp_parser_primary_expression): When calling
finish_id_expression, pass location of id_expression rather
than that of id_expr_token.
(cp_parser_id_expression): Convert local "unqualified_id" from
tree to cp_expr to avoid implicitly dropping location information.
gcc/testsuite/ChangeLog:
PR c++/77829
PR c++/78656
* g++.dg/spellcheck-pr77829.C: New test case.
* g++.dg/spellcheck-pr78656.C: New test case.
From-SVN: r244715
Richard Biener [Fri, 20 Jan 2017 14:05:48 +0000 (14:05 +0000)]
BASE-VER: Bump to 7.0.1.
2017-01-20 Richard Biener <rguenther@suse.de>
* BASE-VER: Bump to 7.0.1.
From-SVN: r244714
Alexander Monakov [Fri, 20 Jan 2017 14:04:06 +0000 (17:04 +0300)]
omp-low: introduce omplow_simd_context
* omp-low.c (omplow_simd_context): New struct. Use it...
(lower_rec_simd_input_clauses): ...here and...
(lower_rec_input_clauses): ...here to hold common data. Adjust all
references to idx, lane, max_vf, is_simt.
From-SVN: r244713
Graham Markall [Fri, 20 Jan 2017 13:37:28 +0000 (13:37 +0000)]
arc/nps: Use arclinux_nps linker emulation for nps
gcc/ChangeLog:
* config/arc/arc.h (LINK_SPEC): Use arclinux_nps emulation when
mcpu=nps400.
From-SVN: r244712
Martin Jambor [Fri, 20 Jan 2017 13:33:29 +0000 (14:33 +0100)]
[hsa] Rename hsa.[ch] to hsa-common.[ch]
2017-01-20 Martin Jambor <mjambor@suse.cz>
* hsa.h: Renaed to hsa-common.h. Adjusted a comment.
* hsa.c: Renaed to hsa-common.c. Change include of gt-hsa.h to
gt-hsa-common.h.
* Makefile.in (OBJS): Rename hsa.o to hsa-common.o.
(GTFILES): Rename hsa.c to hsa-common.c.
* hsa-brig.c: Change include of hsa.h to hsa-common.h.
* hsa-dump.c: Likewise.
* hsa-gen.c: Likewise.
* hsa-regalloc.c: Likewise.
* ipa-hsa.c: Likewise.
* omp-expand.c: Likewise.
* omp-low.c: Likewise.
* toplev.c: Likewise.
From-SVN: r244711
Jiong Wang [Fri, 20 Jan 2017 12:27:46 +0000 (12:27 +0000)]
[AArch64] Always include linux-unwind.h
libgcc/
* config/aarch64/linux-unwind.h: Always include aarch64-unwind.h.
From-SVN: r244710
Jonathan Wakely [Fri, 20 Jan 2017 12:03:36 +0000 (12:03 +0000)]
PR72792 detect allocator pointer types without invalid rebinding
PR libstdc++/72792
* include/bits/alloc_traits.h (__allocator_traits_base::__diff_type)
(__allocator_traits_base::__size_type): Remove.
(allocator_traits::_Ptr): New class template to detect const and void
pointer types without instantiating pointer_traits::rebind
unnecessarily.
(allocator_traits::_Diff): Likewise for detecting difference_type.
(allocator_traits::_Size): New class template to detect size_type
without instantiating make_unsigned unnecessarily.
* include/bits/ptr_traits.h (pointer_traits::element_type): Use
__detected_or_t instead of __detected_or_t_.
* include/std/type_traits (__detected_or_t_): Remove.
* testsuite/20_util/allocator_traits/members/pointers.cc: New test.
From-SVN: r244706
Marek Polacek [Fri, 20 Jan 2017 12:02:50 +0000 (12:02 +0000)]
re PR c/64279 (Warning missing for "(cond) ? A : A" / if(cond) expr1; else expr1; // same expression in if and else branch)
PR c/64279
* c-common.h (do_warn_duplicated_branches_r): Declare.
* c-gimplify.c (c_genericize): Walk the function tree calling
do_warn_duplicated_branches_r.
* c-warn.c (expr_from_macro_expansion_r): New.
(do_warn_duplicated_branches): New.
(do_warn_duplicated_branches_r): New.
* c.opt (Wduplicated-branches): New option.
* c-typeck.c (build_conditional_expr): Warn about duplicated branches.
* call.c (build_conditional_expr_1): Warn about duplicated branches.
* semantics.c (finish_expr_stmt): Build statement using the proper
location.
* doc/invoke.texi: Document -Wduplicated-branches.
* fold-const.c (operand_equal_p): Handle MODIFY_EXPR, INIT_EXPR,
COMPOUND_EXPR, PREDECREMENT_EXPR, PREINCREMENT_EXPR,
POSTDECREMENT_EXPR, POSTINCREMENT_EXPR, CLEANUP_POINT_EXPR, EXPR_STMT,
STATEMENT_LIST, and RETURN_EXPR. For non-pure non-const functions
return 0 only when not OEP_LEXICOGRAPHIC.
(fold_build_cleanup_point_expr): Use the expression
location when building CLEANUP_POINT_EXPR.
* tree-core.h (enum operand_equal_flag): Add OEP_LEXICOGRAPHIC.
* tree.c (add_expr): Handle error_mark_node.
* c-c++-common/Wduplicated-branches-1.c: New test.
* c-c++-common/Wduplicated-branches-10.c: New test.
* c-c++-common/Wduplicated-branches-11.c: New test.
* c-c++-common/Wduplicated-branches-12.c: New test.
* c-c++-common/Wduplicated-branches-2.c: New test.
* c-c++-common/Wduplicated-branches-3.c: New test.
* c-c++-common/Wduplicated-branches-4.c: New test.
* c-c++-common/Wduplicated-branches-5.c: New test.
* c-c++-common/Wduplicated-branches-6.c: New test.
* c-c++-common/Wduplicated-branches-7.c: New test.
* c-c++-common/Wduplicated-branches-8.c: New test.
* c-c++-common/Wduplicated-branches-9.c: New test.
* c-c++-common/Wimplicit-fallthrough-7.c: Coalesce dg-warning.
* g++.dg/cpp0x/lambda/lambda-switch.C: Move dg-warning.
* g++.dg/ext/builtin-object-size3.C: Likewise.
* g++.dg/gomp/loop-1.C: Likewise.
* g++.dg/warn/Wduplicated-branches1.C: New test.
* g++.dg/warn/Wduplicated-branches2.C: New test.
From-SVN: r244705
Arnaud Charlet [Fri, 20 Jan 2017 11:55:04 +0000 (12:55 +0100)]
[multiple changes]
2017-01-20 Hristian Kirtchev <kirtchev@adacore.com>
* ghost.adb (Mark_Ghost_Clause): New routine.
(Prune_Node): Do not prune compilation unit nodes.
(Remove_Ignored_Ghost_Code): Prune the compilation unit node directly.
This does not touch the node itself, but does prune all its fields.
* ghost.ads (Mark_Ghost_Clause): New routine.
* sem_ch8.adb (Analyze_Use_Package): Emit an error when a use
package clause mentions Ghost and non-Ghost packages. Mark a
use package clause as Ghost when it mentions a Ghost package.
(Analyze_Use_Type): Emit an error when a use type clause mentions
Ghost and non-Ghost types. Mark a use type clause as Ghost when
it mentions a Ghost type.
* sem_ch10.adb (Analyze_With_Clause): Mark a with clause as
Ghost when it withs a Ghost unit.
2017-01-20 Javier Miranda <miranda@adacore.com>
* sem_res.adb (Resolve_Call): If a function call
returns a limited view of a type and at the point of the call the
function is not declared in the extended main unit then replace
it with the non-limited view, which must be available. If the
called function is in the extended main unit then no action is
needed since the back-end handles this case.
2017-01-20 Eric Botcazou <ebotcazou@adacore.com>
* sem_ch7.adb (Contains_Subp_Or_Const_Refs): Rename into...
(Contains_Subprograms_Refs): ...this. Adjust comment
for constants. (Is_Subp_Or_Const_Ref): Rename into...
(Is_Subprogram_Ref): ...this.
(Has_Referencer): Rename Has_Non_Subp_Const_Referencer variable into
Has_Non_Subprograms_Referencer and adjust comment. Remove
incorrect shortcut for package declarations and bodies.
2017-01-20 Ed Schonberg <schonberg@adacore.com>
* sem_ch3.adb (Complete_Private_Subtype): If the scope of the
base type differs from that of the completion and the private
subtype is an itype (created for a constraint on an access
type e.g.), set Delayed_Freeze on both to prevent out-of-scope
anomalies in gigi.
2017-01-20 Hristian Kirtchev <kirtchev@adacore.com>
* sem_ch6.adb (Analyze_Subprogram_Body_Helper):
When inheriting the SPARK_Mode of a prior expression function,
look at the properly resolved entity rather than the initial
candidate which may denote a homonym.
2017-01-20 Ed Schonberg <schonberg@adacore.com>
* sem_prag.adb (Rewrite_Assertion_Kind): If the name is
Precondition or Postcondition, and the context is pragma
Check_Policy, indicate that this Pre-Ada2012 usage is deprecated
and suggest the standard names Assertion_Policy /Pre /Post
instead.
From-SVN: r244704
Hristian Kirtchev [Fri, 20 Jan 2017 11:51:36 +0000 (11:51 +0000)]
sem_ch10.adb, [...]: Minor reformatting.
2017-01-20 Hristian Kirtchev <kirtchev@adacore.com>
* sem_ch10.adb, sem_cat.adb: Minor reformatting.
From-SVN: r244703
Arnaud Charlet [Fri, 20 Jan 2017 10:42:43 +0000 (11:42 +0100)]
[multiple changes]
2017-01-20 Javier Miranda <miranda@adacore.com>
* sem_ch3.adb (Access_Type_Declaration): Protect access to the
Entity attribute.
* sem_ch10.adb (Install_Siblings): Skip processing malformed trees.
* sem_cat.adb (Validate_Categoriztion_Dependency): Skip processing
malformed trees.
2017-01-20 Ed Schonberg <schonberg@adacore.com>
* sem_ch13.adb (Analyze_Aspect_Specification, case
Dynamic_Predicate): If the entity E is a subtype that inherits
a static predicate for its parent P,, the inherited and the
new predicate combine in the generated predicate function,
and E only has a dynamic predicate.
2017-01-20 Tristan Gingold <gingold@adacore.com>
* s-boustr.ads, s-boustr.adb: New package.
* Makefile.rtl: Add s-boustr.
2017-01-20 Hristian Kirtchev <kirtchev@adacore.com>
* inline.adb (Process_Formals): Qualify the
expression of a return statement when it yields a universal type.
2017-01-20 Hristian Kirtchev <kirtchev@adacore.com>
* freeze.adb (Freeze_All): Freeze the default
expressions of all eligible formal parameters that appear in
entries, entry families, and protected subprograms.
From-SVN: r244701
Arnaud Charlet [Fri, 20 Jan 2017 10:38:54 +0000 (11:38 +0100)]
Minor reformatting.
From-SVN: r244700
Arnaud Charlet [Fri, 20 Jan 2017 10:38:41 +0000 (11:38 +0100)]
[multiple changes]
2017-01-20 Ed Schonberg <schonberg@adacore.com>
* sem_ch3.adb (Check_Nonoverridable_Aspects); Refine check
for illegal inherited Implicit_Dereference aspects with renamed
discriminants.
2017-01-20 Javier Miranda <miranda@adacore.com>
* debug.adb (switch d.6): do not avoid declaring unreferenced itypes.
* nlists.ads (Lock_Lists, Unlock_Lists): New subprograms.
* nlists.adb (Lock_Lists, Unlock_Lists): New subprograms.
(Set_First, Set_Last, Set_List_Link, Set_Next, Set_Parent,
Set_Prev, Tree_Read): Adding assertion.
* atree.ads (Lock_Nodes, Unlock_Nodes): New subprograms.
* atree.adb (Lock_Nodes, Unlock_Nodes): New subprograms.
(Set_Analyzed, Set_Check_Actuals, Set_Comes_From_Source,
Set_Ekind, Set_Error_Posted, Set_Has_Aspects,
Set_Is_Ignored_Ghost_Node, Set_Original_Node, Set_Paren_Count,
Set_Parent, Set_Sloc, Set_Nkind, Set_FieldNN, Set_NodeNN,
Set_ListNN, Set_ElistNN, Set_NameN, Set_StrN, Set_UintNN,
Set_UrealNN, Set_FlagNNN, Set_NodeN_With_Parent,
Set_ListN_With_Parent): Adding assertion.
2017-01-20 Ed Schonberg <schonberg@adacore.com>
* sem_prag.adb (Process_Convention): Diagnose properly a pragma
import that applies to several homograph subprograms. when one
of them is declared by a subprogram body.
2017-01-20 Justin Squirek <squirek@adacore.com>
* exp_ch6.adb (Expand_Call): Remove optimization
that nulls out calls to null procedures.
From-SVN: r244699
Arnaud Charlet [Fri, 20 Jan 2017 10:36:01 +0000 (11:36 +0100)]
[multiple changes]
2017-01-20 Yannick Moy <moy@adacore.com>
* inline.adb (Expand_Inlined_Call): Keep more
precise type of actual for inlining whenever possible. In
particular, do not switch to the formal type in GNATprove mode in
some case where the GNAT backend might require it for visibility.
2017-01-20 Ed Schonberg <schonberg@adacore.com>
* sem_ch3.adb (Check_Non_Overridable_Aspects): An inherited
aspect Implicit_Dereference can be inherited by a full view if
the partial view has no discriminants, because there is no way
to apply the aspect to the partial view.
(Build_Derived_Record_Type): If derived type renames discriminants
of the parent, the new discriminant inherits the aspect from
the old one.
* sem_ch4.adb (Analyze_Call): Handle properly a parameterless
call through an access discriminant designating a subprogram.
* sem_ch5.adb (Analyze_Assignment): (Analyze_Call): Handle
properly a parameterless call through an access discriminant on
the left-hand side of an assignment.
* sem_res.adb (resolve): If an interpreation involves a
discriminant with an implicit dereference and the expression is an
entity, resolution takes place later in the appropriate routine.
* sem_ch13.adb (Analyze_Aspect_Implicit_Dereference): Recognize
access discriminants that designate a subprogram type.
2017-01-20 Pascal Obry <obry@adacore.com>
* a-locale.adb, a-locale.ads: Update Ada.Locales for RM 2012 COR:1:2016
From-SVN: r244698
Arnaud Charlet [Fri, 20 Jan 2017 10:32:34 +0000 (11:32 +0100)]
Minor reformatting.
From-SVN: r244697
Arnaud Charlet [Fri, 20 Jan 2017 10:31:58 +0000 (11:31 +0100)]
[multiple changes]
2017-01-20 Yannick Moy <moy@adacore.com>
* sem_ch10.adb (Check_No_Elab_Code_All): Do not issue an error
on implicitly with'ed units in GNATprove mode.
* sinfo.ads (Implicit_With): Document use of flag for implicitly
with'ed units in GNATprove mode.
2017-01-20 Ed Schonberg <schonberg@adacore.com>
* sem_cat.adb (Validate_Static_Object_Name): In a preelaborated
unit Do not report an error on a non-static entity that appears
in the context of a spec expression, such as an aspect expression.
2017-01-20 Hristian Kirtchev <kirtchev@adacore.com>
* einfo.adb: Flag298 now denotes Is_Underlying_Full_View.
(Is_Underlying_Full_View): New routine.
(Set_Is_Underlying_Full_View): New routine.
(Write_Entity_Flags): Add an entry for Is_Underlying_Full_View.
* einfo.ads Add new attribute Is_Underlying_Full_View.
(Is_Underlying_Full_View): New routine along with pragma Inline.
(Set_Is_Underlying_Full_View): New routine along with pragma Inline.
* exp_util.adb (Build_DIC_Procedure_Body): Do not consider
class-wide types and underlying full views. The first subtype
is used as the working type for all Itypes, not just array base types.
(Build_DIC_Procedure_Declaration): Do not consider
class-wide types and underlying full views. The first subtype
is used as the working type for all Itypes, not just array
base types.
* freeze.adb (Freeze_Entity): Inherit the freeze node of a full
view or an underlying full view without clobbering the attributes
of a previous freeze node.
(Inherit_Freeze_Node): New routine.
* sem_ch3.adb (Build_Derived_Private_Type): Mark an underlying
full view as such.
(Build_Underlying_Full_View): Mark an underlying full view as such.
* sem_ch7.adb (Install_Private_Declarations): Mark an underlying
full view as such.
From-SVN: r244696
Arnaud Charlet [Fri, 20 Jan 2017 10:30:28 +0000 (11:30 +0100)]
Revert previous change.
From-SVN: r244695
Arnaud Charlet [Fri, 20 Jan 2017 10:20:02 +0000 (11:20 +0100)]
[multiple changes]
2017-01-20 Arnaud Charlet <charlet@adacore.com>
* exp_ch3.adb: Reenable code.
2017-01-20 Yannick Moy <moy@adacore.com>
* sinfo.ads: Document lack of Do_Division_Check flag
on float exponentiation.
From-SVN: r244693
Martin Liska [Fri, 20 Jan 2017 09:45:04 +0000 (10:45 +0100)]
Do not declare artificial variables in tree-profile.c to have a definition (PR lto/69188).
2017-01-20 Martin Liska <mliska@suse.cz>
PR lto/69188
* gcc.dg/lto/pr69188_0.c: New test.
* gcc.dg/lto/pr69188_1.c: New test.
2017-01-20 Martin Liska <mliska@suse.cz>
PR lto/69188
* tree-profile.c (init_ic_make_global_vars): Do not call
finalize_decl.
(gimple_init_gcov_profiler): Likewise.
From-SVN: r244692
Martin Liska [Fri, 20 Jan 2017 08:44:35 +0000 (09:44 +0100)]
Fix IPA CP where it forgot to add a reference in cgraph (PR ipa/71190).
2017-01-20 Martin Liska <mliska@suse.cz>
PR ipa/71190
* cgraph.h (maybe_create_reference): Remove argument and
update comment.
* cgraphclones.c (cgraph_node::create_virtual_clone): Remove one
argument.
* ipa-cp.c (create_specialized_node): Likewise.
* symtab.c (symtab_node::maybe_create_reference): Handle
VAR_DECLs and ADDR_EXPRs and select ipa_ref_use type.
From-SVN: r244687
Martin Liska [Fri, 20 Jan 2017 08:41:22 +0000 (09:41 +0100)]
Fix --enable-gather-detailed-mem-stats
2017-01-20 Martin Liska <mliska@suse.cz>
* read-rtl-function.c (function_reader::create_function): Use
build_decl instread of build_decl_stat.
From-SVN: r244686
Andrew Senkevich [Fri, 20 Jan 2017 08:37:13 +0000 (08:37 +0000)]
Add AVX512 k-mask intrinsics.
gcc/
* config/i386/avx512bwintrin.h: Add k-mask registers shift intrinsics.
* config/i386/avx512dqintrin.h: Ditto.
* config/i386/avx512fintrin.h: Ditto.
* config/i386/i386-builtin-types.def: Add new types.
* gcc/config/i386/i386.c: Handle new types.
* config/i386/i386-builtin.def (__builtin_ia32_kshiftliqi)
(__builtin_ia32_kshiftlihi, __builtin_ia32_kshiftlisi)
(__builtin_ia32_kshiftlidi, __builtin_ia32_kshiftriqi)
(__builtin_ia32_kshiftrihi, __builtin_ia32_kshiftrisi)
(__builtin_ia32_kshiftridi): New.
* config/i386/sse.md (k<code><mode>): Rename *k<code><mode>.
gcc/testsuite/
* gcc.target/i386/avx512bw-kshiftld-1.c: New test.
* gcc.target/i386/avx512bw-kshiftlq-1.c: Ditto.
* gcc.target/i386/avx512dq-kshiftlb-1.c: Ditto.
* gcc.target/i386/avx512f-kshiftlw-1.c: Ditto.
* gcc.target/i386/avx512bw-kshiftrd-1.c: Ditto.
* gcc.target/i386/avx512bw-kshiftrq-1.c: Ditto.
* gcc.target/i386/avx512dq-kshiftrb-1.c: Ditto.
* gcc.target/i386/avx512f-kshiftrw-1.c: Ditto.
* gcc.target/i386/avx512bw-kshiftld-2.c: Ditto.
* gcc.target/i386/avx512bw-kshiftlq-2.c: Ditto.
* gcc.target/i386/avx512bw-kshiftrd-2.c: Ditto.
* gcc.target/i386/avx512bw-kshiftrq-2.c: Ditto.
* gcc.target/i386/avx512dq-kshiftlb-2.c: Ditto.
* gcc.target/i386/avx512dq-kshiftrb-2.c: Ditto.
* gcc.target/i386/avx512f-kshiftlw-2.c: Ditto.
* gcc.target/i386/avx512f-kshiftrw-2.c: Ditto.
* gcc.target/i386/avx-1.c: Test new intrinsics.
* gcc.target/i386/sse-13.c: Ditto.
* gcc.target/i386/sse-23.c: Ditto.
From-SVN: r244685
Jakub Jelinek [Fri, 20 Jan 2017 08:27:29 +0000 (09:27 +0100)]
re PR other/79046 (g++ -print-file-name=plugin uses full version number in path)
PR other/79046
liboffloadmic/
* aclocal.m4: Regenerated.
* Makefile.in: Regenerated.
libcilkrts/
* aclocal.m4: Regenerated.
* Makefile.in: Regenerated.
From-SVN: r244684
Richard Biener [Fri, 20 Jan 2017 08:01:27 +0000 (08:01 +0000)]
re PR tree-optimization/71264 (ICE in convert_move)
2017-01-20 Richard Biener <rguenther@suse.de>
PR tree-optimization/71264
* gcc.dg/vect/pr71264.c: Make sure memory is aligned.
From-SVN: r244683
Jason Merrill [Fri, 20 Jan 2017 04:43:19 +0000 (23:43 -0500)]
US 20 - forwarding references and class template argument deduction
* cp-tree.h (TEMPLATE_TYPE_PARM_FOR_CLASS): New.
* pt.c (push_template_decl_real): Set it.
(maybe_adjust_types_for_deduction): Check it.
(rewrite_template_parm): Copy it.
From-SVN: r244682
Jason Merrill [Fri, 20 Jan 2017 04:43:13 +0000 (23:43 -0500)]
US 19 - deduction guides and constructors
* call.c (joust): Prefer deduction guides to constructors.
* pt.c (build_deduction_guide): Set DECL_ARTIFICIAL.
(deduction_guide_p): Check DECL_P.
From-SVN: r244681
Jonathan Wakely [Fri, 20 Jan 2017 02:36:16 +0000 (02:36 +0000)]
PR72792 PR72793 relax requirements on rebind members
PR libstdc++/72792
PR libstdc++/72793
* include/bits/alloc_traits.h (__allocator_traits_base::__rebind):
Replace with class template using void_t.
(__alloc_rebind): Define in terms of
__allocator_traits_base::__rebind.
(allocator_traits): Remove unconditional static_assert for
rebind_alloc.
* include/bits/ptr_traits.h (__replace_first_arg): Remove type member.
(pointer_traits::__rebind): Replace with class template using void_t.
(pointer_traits::rebind): Define in terms of __rebind.
(pointer_traits): Remove unconditional static_assert for rebind.
* testsuite/20_util/allocator_traits/members/rebind_alloc.cc: New test.
* testsuite/20_util/pointer_traits/rebind.cc: New test.
From-SVN: r244680
Ian Lance Taylor [Fri, 20 Jan 2017 02:27:46 +0000 (02:27 +0000)]
re PR go/79146 (Bootstrapping go on s390x fails; redefined symbols)
PR go/79146
crypto/elliptic: explicitly ignore p256_s390x.go
The file only works if used in conjunction with assembly code not
(yet) written for gccgo.
Fixes GCC PR 79146.
Reviewed-on: https://go-review.googlesource.com/35477
From-SVN: r244679
Jonathan Wakely [Fri, 20 Jan 2017 01:22:54 +0000 (01:22 +0000)]
PR69321 fix any_cast<T>(any*) for non-copyable T
PR libstdc++/69321
* include/experimental/any (__any_caster): Avoid instantiating
manager function for types that can't be stored in any.
* include/std/any (__any_caster): Likewise.
* testsuite/20_util/any/misc/any_cast.cc: Test non-copyable type.
* testsuite/experimental/any/misc/any_cast.cc: Likewise.
From-SVN: r244678
Segher Boessenkool [Fri, 20 Jan 2017 01:22:27 +0000 (02:22 +0100)]
rs6000: Fix the new SSP guard configuration code (PR79140)
I foolishly tested this with r241087 reverted. After that revision
default_stack_protect_guard is no longer called if the compiler defaults
to using the TLS guard, which of course is the wrong thing to do if
there is some other way to enable the global guard.
This fixes it.
PR target/78875
PR target/79140
* config/rs6000/rs6000.c (TARGET_STACK_PROTECT_GUARD): Unconditionally
define to rs6000_init_stack_protect_guard.
(rs6000_init_stack_protect_guard): New function.
From-SVN: r244677
Matthew Fortune [Fri, 20 Jan 2017 01:05:25 +0000 (01:05 +0000)]
config.gcc (supported_defaults): Add madd4.
gcc/
2017-01-19 Matthew Fortune <matthew.fortune@imgtec.com>
Yunqiang Su <yunqiang.su@imgtec.com>
* config.gcc (supported_defaults): Add madd4.
(with_madd4): Add validation.
(all_defaults): Add madd4.
* config/mips/mips.opt (mmadd4): New option.
* gcc/config/mips/mips.h (OPTION_DEFAULT_SPECS): Add a default for
mmadd4.
(TARGET_CPU_CPP_BUILTINS): Add builtin_define for
__mips_no_madd4.
(ISA_HAS_UNFUSED_MADD4): Gate with mips_madd4.
(ISA_HAS_FUSED_MADD4): Likewise.
* gcc/doc/invoke.texi (-mmadd4): Document the new option.
* gcc/doc/install.texi (--with-madd4): Document the new option.
gcc/testsuite/
2017-01-19 Matthew Fortune <matthew.fortune@imgtec.com>
* gcc.target/mips/madd4-1.c: New file.
* gcc.target/mips/madd4-2.c: Likewise.
* gcc.target/mips/mips.exp (mips_option_groups): Add ghost option
HAS_MADD4.
(mips_option_groups): Add -m[no-]madd4.
(mips-dg-init): Detect default -mno-madd4.
(mips-dg-options): Handle HAS_MADD4 arch upgrade/downgrade.
* gcc.target/mips/mips-ps-type.c: Add -mmadd4 test option.
* gcc.target/mips/mips-ps-type-2.c: Likewise.
* gcc.target/mips/nmadd-1.c: Likewise.
* gcc.target/mips/nmadd-2.c: Likewise.
* gcc.target/mips/nmadd-3.c: Likewise.
Co-Authored-By: Yunqiang Su <yunqiang.su@imgtec.com>
From-SVN: r244676
Jonathan Wakely [Fri, 20 Jan 2017 00:33:25 +0000 (00:33 +0000)]
PR64903 simplify last fix to std::is_partitioned
PR libstdc++/64903
* include/bits/stl_algo.h (is_partitioned): Use increment instead of
std::advance.
From-SVN: r244675
Jiong Wang [Fri, 20 Jan 2017 00:21:34 +0000 (00:21 +0000)]
[AArch64, libgcc] Add missing file, forget "svn add"
From-SVN: r244674
Jiong Wang [Fri, 20 Jan 2017 00:19:01 +0000 (00:19 +0000)]
[AArch64][4/4] libgcc unwinder support for return address signing
libgcc/
* config/aarch64/aarch64-unwind.h: New file.
(DWARF_REGNUM_AARCH64_RA_STATE): Define.
(MD_POST_EXTRACT_ROOT_ADDR): New target marcro and define it on AArch64.
(MD_POST_EXTRACT_FRAME_ADDR): Likewise.
(MD_POST_FROB_EH_HANDLER_ADDR): Likewise.
(MD_FROB_UPDATE_CONTEXT): Define it on AArch64.
(aarch64_post_extract_frame_addr): New function.
(aarch64_post_frob_eh_handler_addr): New function.
(aarch64_frob_update_context): New function.
* config/aarch64/linux-unwind.h: Include aarch64-unwind.h
* config.host (aarch64*-*-elf, aarch64*-*-rtems*,
aarch64*-*-freebsd*):
Initialize md_unwind_header to include aarch64-unwind.h.
* unwind-dw2.c (struct _Unwind_Context): Define "RA_A_SIGNED_BIT".
(execute_cfa_program): Multiplex DW_CFA_GNU_window_save for
__aarch64__.
(uw_update_context): Honor MD_POST_EXTRACT_FRAME_ADDR.
(uw_init_context_1): Honor MD_POST_EXTRACT_ROOT_ADDR.
(uw_frob_return_addr): New function.
(uw_install_context): Use uw_frob_return_addr.
From-SVN: r244673
GCC Administrator [Fri, 20 Jan 2017 00:16:18 +0000 (00:16 +0000)]
Daily bump.
From-SVN: r244672
Jiong Wang [Fri, 20 Jan 2017 00:10:11 +0000 (00:10 +0000)]
[AArch64][3/4] New PAUTH builtins required by libgcc unwinder
gcc/
* config/aarch64/aarch64-builtins.c (enum aarch64_builtins): New
entries for AARCH64_PAUTH_BUILTIN_XPACLRI,
AARCH64_PAUTH_BUILTIN_PACIA1716, AARCH64_PAUTH_BUILTIN_AUTIA1716.
(aarch64_init_pauth_hint_builtins): New.
(aarch64_init_builtins): Call aarch64_init_pauth_hint_builtins.
(aarch64_expand_builtin): Expand new builtins.
From-SVN: r244669