gcc

~vcs-imports/gcc/+git/gcc:hjl/pr67215/master

Last commit made on 2015-08-31
Get this branch:
git clone -b hjl/pr67215/master https://git.launchpad.net/~vcs-imports/gcc/+git/gcc

Branch merges

Branch information

Name:
hjl/pr67215/master
Repository:
lp:~vcs-imports/gcc/+git/gcc

Recent commits

47284e2... by "H.J. Lu" <email address hidden>

Properly handle -fno-plt in ix86_expand_call

It boils down to that -fno-plt should convert calling an external
function, foo, from

call foo@PLT

to

call *foo@GOT

to avoid one extra direct branch to PLT. The proper place for this is
in backend during expanding a function call. The backend already takes
care of many details for calling an external function, like setting up
a PIC register. Using the GOT slot instead of PLT slot is just one of
those details. For x86, it should be done in ix86_expand_call, not
prepare_call_address and hoping for the best, which doesn't always
happen. Also non-PIC case can only be handled in backend.

This patch reverts -fno-plt in prepare_call_address and handles it in
ix86_expand_call. Other backends may need similar changes to support
-fno-plt. Alternately, we can introduce a target hook to indicate
whether an external function should be called via register for -fno-plt
so that i386 backend can disable it in prepare_call_address.

sibcall_memory_operand is also updated to accept the GOT slot so that

call *foo@GOT(%reg)

can be generated by ix86_expand_call for 32-bit and 64-bit large model.

gcc/

 PR target/67215
 * calls.c (prepare_call_address): Don't handle -fno-plt here.
 * config/i386/i386.c (ix86_expand_call): Generate indirect call
 via GOT for -fno-plt. Support indirect call via GOT for x32.

gcc/testsuite/

 PR target/67215
 * gcc.target/i386/pr67215-1.c: New test.
 * gcc.target/i386/pr67215-2.c: Likewise.

e091399... by jwlemke <jwlemke@138bc75d-0d04-0410-961f-82ee72b054a4>

Update my e-mail address.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@227352 138bc75d-0d04-0410-961f-82ee72b054a4

b2d409e... by uweigand <uweigand@138bc75d-0d04-0410-961f-82ee72b054a4>

 * configure.ac: For spu-*-* targets, set have_fcntl to no.
 * configure: Regenerate.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@227348 138bc75d-0d04-0410-961f-82ee72b054a4

04c1414... by fxcoudert <fxcoudert@138bc75d-0d04-0410-961f-82ee72b054a4>

 PR libfortran/47571
 * acinclude.m4 (LIBGFOR_GTHREAD_WEAK): Reinstate.
 * configure.ac: Call LIBGFOR_GTHREAD_WEAK again.
 * config.h.in: Regenerate.
 * configure: Regenerate.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@227347 138bc75d-0d04-0410-961f-82ee72b054a4

06e4870... by glisse <glisse@138bc75d-0d04-0410-961f-82ee72b054a4>

Move some comparison simplifications to match.pd

2015-08-31 Marc Glisse <email address hidden>

gcc/
 * tree.h (zerop): New function.
 * tree.c (zerop): Likewise.
 (element_precision): Handle expressions.
 * match.pd (define_predicates): Add zerop.
 (x <= +Inf): Fix comment.
 (abs (x) == 0, A & C == C, A & C != 0): Converted from ...
 * fold-const.c (fold_binary_loc): ... here. Remove.

gcc/testsuite/
 * gcc.dg/tree-ssa/cmp-1.c: New file.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@227346 138bc75d-0d04-0410-961f-82ee72b054a4

5a7d537... by rguenth <rguenth@138bc75d-0d04-0410-961f-82ee72b054a4>

2015-08-31 Richard Biener <email address hidden>

 lto/
 * lto.c (compare_tree_sccs_1): Compare DECL_ABSTRACT_ORIGIN.
 * lto-symtab.c (lto_symtab_merge): Merge DECL_POSSIBLY_INLINED flag.
 (lto_symtab_prevailing_decl): Do not replace a decl that didn't
 participate in merging with something else.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@227345 138bc75d-0d04-0410-961f-82ee72b054a4

ed1990e... by rguenth <rguenth@138bc75d-0d04-0410-961f-82ee72b054a4>

2015-08-31 Richard Biener <email address hidden>

 PR middle-end/67381
 * genmatch.c (dt_node::gen_kids): Also treat matches as barrier.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@227344 138bc75d-0d04-0410-961f-82ee72b054a4

d92f7c8... by glisse <glisse@138bc75d-0d04-0410-961f-82ee72b054a4>

Move some complex simplifications to match.pd

2015-08-31 Marc Glisse <email address hidden>

gcc/
 * match.pd (SIN, COS, TAN, COSH): Reorder for consistency.
 (CEXPI): New operator list.
 (real (conj (x)), imag (conj (x)), real (x +- y), real (cexpi (x)),
 imag (cexpi (x)), conj (conj (x)), conj (complex (x, y))):
 Converted from ...
 * fold-const.c (fold_unary_loc, fold_binary_loc): ... here. Remove.

gcc/testsuite/
 * gcc.dg/tree-ssa/complex-7.c: New file.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@227343 138bc75d-0d04-0410-961f-82ee72b054a4

303352c... by vries <vries@138bc75d-0d04-0410-961f-82ee72b054a4>

Reimplement rewrite_virtuals_into_loop_closed_ssa

2015-08-31 Tom de Vries <email address hidden>

 * tree-ssa-loop-manip.c (find_uses_to_rename_stmt)
 (find_uses_to_rename_bb, find_uses_to_rename): Add and handle use_flags
 parameter.
 (find_uses_to_rename_def, find_uses_to_rename_in_loop): New function.
 (rewrite_into_loop_closed_ssa_1): New function, factored out of ...
 (rewrite_into_loop_closed_ssa): ... here.
 (replace_uses_in_dominated_bbs): Remove function.
 (rewrite_virtuals_into_loop_closed_ssa): Reimplement using
 rewrite_into_loop_closed_ssa_1.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@227342 138bc75d-0d04-0410-961f-82ee72b054a4

f0d48a7... by matz <matz@138bc75d-0d04-0410-961f-82ee72b054a4>

 * cfganal.c (pre_and_rev_post_order_compute_fn): Correctly
 enter entry and exit blocks for reverse post order.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@227341 138bc75d-0d04-0410-961f-82ee72b054a4