2014-05-30 Tom de Vries <tom@codesourcery.com>
* lra-int.h (struct lra_reg): Add field actual_call_used_reg_set.
* lra.c (initialize_lra_reg_info_element): Add init of
actual_call_used_reg_set field.
(lra): Call lra_create_live_ranges before lra_inheritance for
-fuse-caller-save.
* lra-assigns.c (lra_assign): Allow call_used_regs to cross calls for
-fuse-caller-save.
* lra-constraints.c (need_for_call_save_p): Use actual_call_used_reg_set
instead of call_used_reg_set for -fuse-caller-save.
* lra-lives.c (process_bb_lives): Calculate actual_call_used_reg_set.
From-SVN: r211074
gcc/
* ira.c (ira_get_dup_out_num): Check for output operands at
the start of the loop. Handle cases where an included alternative
follows an excluded one.
From-SVN: r211072
This adds the --without-libatomic configure option, which is useful for building libgo
with a non-gcc compiler.
It disables libgo's dependency on libatomic. This
is useful for platforms where it is known that the libatomic runtime
functions are not required, or where the compiler automatically
provides an implementation of them.
From-SVN: r211065
gcc.target/arm/simd/vextQf32_1.c: New file.
gcc.target/arm/simd/vextQp16_1.c: New file.
gcc.target/arm/simd/vextQp8_1.c: New file.
gcc.target/arm/simd/vextQs16_1.c: New file.
gcc.target/arm/simd/vextQs32_1.c: New file.
gcc.target/arm/simd/vextQs64_1.c: New file.
gcc.target/arm/simd/vextQs8_1.c: New file.
gcc.target/arm/simd/vextQu16_1.c: New file.
gcc.target/arm/simd/vextQu32_1.c: New file.
gcc.target/arm/simd/vextQu64_1.c: New file.
gcc.target/arm/simd/vextQu8_1.c: New file.
gcc.target/arm/simd/vextQp64_1.c: New file.
gcc.target/arm/simd/vextf32_1.c: New file.
gcc.target/arm/simd/vextp16_1.c: New file.
gcc.target/arm/simd/vextp8_1.c: New file.
gcc.target/arm/simd/vexts16_1.c: New file.
gcc.target/arm/simd/vexts32_1.c: New file.
gcc.target/arm/simd/vexts64_1.c: New file.
gcc.target/arm/simd/vexts8_1.c: New file.
gcc.target/arm/simd/vextu16_1.c: New file.
gcc.target/arm/simd/vextu32_1.c: New file.
gcc.target/arm/simd/vextu64_1.c: New file.
gcc.target/arm/simd/vextu8_1.c: New file.
gcc.target/arm/simd/vextp64_1.c: New file.
From-SVN: r211059
LLVM's code generator does not currently support split stacks for vararg
functions, so we disable split stacks for the only function that uses this
feature under Clang. This appears to be OK as long as:
- this function only calls non-inlined, internal-linkage (hence no dynamic
loader) functions compiled with split stacks (i.e. go_vprintf), which can
allocate more stack space as required;
- this function itself does not occupy more than BACKOFF bytes of stack space
(see libgcc/config/i386/morestack.S).
These conditions are currently known to be satisfied by Clang on x86-32 and
x86-64. Note that signal handlers receive slightly less stack space than they
would normally do if they happen to be called while this function is being
run. If this turns out to be a problem we could consider increasing BACKOFF.
From-SVN: r211037
This includes the use of __complex and __builtin_ functions where
unprefixed entities would suffice, and the use of a union for
bit-casting between types.
From-SVN: r211036
Running the demangler's testsuite with CP_DEMANGLE_DEBUG defined
crashes, with:
Program received signal SIGSEGV, Segmentation fault.
0x000000000040a8c3 in d_dump (dc=0x1, indent=12) at ../../src/libiberty/cp-demangle.c:567
567 switch (dc->type)
(gdb) bt 3
#0 0x000000000040a8c3 in d_dump (dc=0x1, indent=12) at ../../src/libiberty/cp-demangle.c:567
#1 0x000000000040ae47 in d_dump (dc=0x7fffffffd098, indent=10) at ../../src/libiberty/cp-demangle.c:787
#2 0x000000000040ae47 in d_dump (dc=0x7fffffffd0c8, indent=8) at ../../src/libiberty/cp-demangle.c:787
Note dc=0x1, which is obviously a bogus pointer. This is the end of
d_dump recursing for a component type that that doesn't actually have
subtrees:
787 d_dump (d_left (dc), indent + 2);
788 d_dump (d_right (dc), indent + 2);
This fixes the two cases the testsuite currently trips on.
libiberty/
2014-05-28 Pedro Alves <palves@redhat.com>
* cp-demangle.c (d_dump): Handle DEMANGLE_COMPONENT_FUNCTION_PARAM
and DEMANGLE_COMPONENT_NUMBER.
From-SVN: r211035
2014-05-28 Tom de Vries <tom@codesourcery.com>
Revert:
2014-05-28 Tom de Vries <tom@codesourcery.com>
* lra-int.h (struct lra_reg): Add field actual_call_used_reg_set.
* lra.c (initialize_lra_reg_info_element): Add init of
actual_call_used_reg_set field.
(lra): Call lra_create_live_ranges before lra_inheritance for
-fuse-caller-save.
* lra-assigns.c (lra_assign): Allow call_used_regs to cross calls for
-fuse-caller-save.
* lra-constraints.c (need_for_call_save_p): Use actual_call_used_reg_set
instead of call_used_reg_set for -fuse-caller-save.
* lra-lives.c (process_bb_lives): Calculate actual_call_used_reg_set.
From-SVN: r211033
gcc/
* doc/md.texi: Document that the % constraint character must
be at the beginning of the string.
* genoutput.c (validate_insn_alternatives): Check that '=',
'+' and '%' only appear at the beginning of a constraint.
* ira.c (commutative_constraint_p): Delete.
(ira_get_dup_out_num): Expect the '%' commutativity marker to be
at the start of the string.
* config/alpha/alpha.md (*movmemdi_1, *clrmemdi_1): Remove
duplicate '='s.
* config/arm/neon.md (bicdi3_neon): Likewise.
* config/iq2000/iq2000.md (addsi3_internal, subsi3_internal, sgt_si)
(slt_si, sltu_si): Likewise.
* config/vax/vax.md (sbcdi3): Likewise.
* config/h8300/h8300.md (*cmpstz): Remove duplicate '+'.
* config/arc/arc.md (mulsi_600, mulsidi_600, umulsidi_600)
(mul64): Move '%' to beginning of constraint.
* config/arm/arm.md (*xordi3_insn): Likewise.
* config/nds32/nds32.md (add<mode>3, mulsi3, andsi3, iorsi3)
(xorsi3): Likewise.
From-SVN: r211031
2014-05-28 Richard Biener <rguenther@suse.de>
* tree-ssa-propagate.c (add_control_edge): Print less vertical space.
* tree-vrp.c (extract_range_from_ssa_name): Also copy VR_UNDEFINED.
(vrp_visit_assignment_or_call): Print less vertical space.
(vrp_visit_stmt): Likewise.
(vrp_visit_phi_node): Likewise. For a PHI argument with
VR_VARYING range consider recording it as copy.
From-SVN: r211022
2014-05-28 Richard Biener <rguenther@suse.de>
Revert
2014-05-28 Richard Biener <rguenther@suse.de>
* hwint.h (HOST_WIDE_INT_PRINT_*): Define in terms of PRI*64.
From-SVN: r211021
2014-05-28 Bernd Edlinger <bernd.edlinger@hotmail.de>
* expr.c (expand_assignment): Fold the bitpos in the to_rtx if
sufficiently aligned and an offset is used at the same time.
(expand_expr_real_1): Likewise.
From-SVN: r211020
2014-05-28 Richard Biener <rguenther@suse.de>
PR middle-end/61045
* fold-const.c (fold_comparison): When folding
X +- C1 CMP Y +- C2 to X CMP Y +- C2 +- C1 also ensure
the sign of the remaining constant operand stays the same.
* gcc.dg/pr61045.c: New testcase.
From-SVN: r211018
2014-05-28 Richard Biener <rguenther@suse.de>
* hwint.h (*_HALF_WIDE_INT*): Move to ...
* wide-int.cc (HOST_BITS_PER_HALF_WIDE_INT, HOST_HALF_WIDE_INT):
... here and remove the rest.
* hwint.h (HOST_WIDE_INT_PRINT_*): Define in terms of PRI*64.
From-SVN: r211013
2014-05-28 Richard Biener <rguenther@suse.de>
PR tree-optimization/61335
* tree-vrp.c (vrp_visit_phi_node): If the compare of old and
new range fails, drop to varying.
* gfortran.dg/pr61335.f90: New testcase.
From-SVN: r211012
2014-05-28 Tom de Vries <tom@codesourcery.com>
* lra-int.h (struct lra_reg): Add field actual_call_used_reg_set.
* lra.c (initialize_lra_reg_info_element): Add init of
actual_call_used_reg_set field.
(lra): Call lra_create_live_ranges before lra_inheritance for
-fuse-caller-save.
* lra-assigns.c (lra_assign): Allow call_used_regs to cross calls for
-fuse-caller-save.
* lra-constraints.c (need_for_call_save_p): Use actual_call_used_reg_set
instead of call_used_reg_set for -fuse-caller-save.
* lra-lives.c (process_bb_lives): Calculate actual_call_used_reg_set.
From-SVN: r211010
2014-05-28 Radovan Obradovic <robradovic@mips.com>
Tom de Vries <tom@codesourcery.com>
* doc/invoke.texi (@item Optimization Options): Add -fuse-caller-save to
gccoptlist.
(@item -fuse-caller-save): New item.
Co-Authored-By: Tom de Vries <tom@codesourcery.com>
From-SVN: r211009
2014-05-28 Radovan Obradovic <robradovic@mips.com>
Tom de Vries <tom@codesourcery.com>
* opts.c (default_options_table): Add OPT_LEVELS_2_PLUS entry with
OPT_fuse_caller_save.
Co-Authored-By: Tom de Vries <tom@codesourcery.com>
From-SVN: r211008
2014-05-28 Radovan Obradovic <robradovic@mips.com>
Tom de Vries <tom@codesourcery.com>
* cgraph.h (struct cgraph_rtl_info): Add function_used_regs
and function_used_regs_valid fields.
* final.c: Move include of hard-reg-set.h to before rtl.h to declare
find_all_hard_reg_sets.
(collect_fn_hard_reg_usage, get_call_fndecl, get_call_cgraph_rtl_info)
(get_call_reg_set_usage): New function.
(rest_of_handle_final): Use collect_fn_hard_reg_usage.
* regs.h (get_call_reg_set_usage): Declare.
Co-Authored-By: Tom de Vries <tom@codesourcery.com>
From-SVN: r211006
2014-05-27 Andrew Pinski <apinski@cavium.com>
* config/aarch64/aarch64.md (stack_protect_set_<mode>):
Use <w> for the register in assembly template.
(stack_protect_test): Use the mode of operands[0] for the
result.
(stack_protect_test_<mode>): Use <w> for the register
in assembly template.
From-SVN: r210996