diff options
author | steven <steven@138bc75d-0d04-0410-961f-82ee72b054a4> | 2012-10-16 22:05:17 +0000 |
---|---|---|
committer | steven <steven@138bc75d-0d04-0410-961f-82ee72b054a4> | 2012-10-16 22:05:17 +0000 |
commit | cf7fb72d3b3a94549e5b32d2ef34863c5477d758 (patch) | |
tree | eafbca96b0b0771fa77620d1cff5cfc0a8a8b8be /gcc/config/sh | |
parent | 01dd0067b62af36b93ffcd6a9ff9070a64ed1b45 (diff) | |
download | gcc-cf7fb72d3b3a94549e5b32d2ef34863c5477d758.tar.gz |
* rtl.h (get_call_rtx_from): New prototype.
* rtlanal.c (get_call_rtx_from): New function.
* calls.c (emit_call_1): Use it.
* dse.c (scan_insn): Likewise
* dwarf2out.c (dwarf2out_var_location): Likewise.
* sched-deps.c (call_may_noreturn_p): Likewise.
* var-tracking.c (prepare_call_arguments): Likewise.
* config/sh/sh.c (sh_adjust_cost): Likewise.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@192516 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/config/sh')
-rw-r--r-- | gcc/config/sh/sh.c | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/gcc/config/sh/sh.c b/gcc/config/sh/sh.c index df5b4e519b3..b81c0c35fca 100644 --- a/gcc/config/sh/sh.c +++ b/gcc/config/sh/sh.c @@ -10811,13 +10811,8 @@ sh_adjust_cost (rtx insn, rtx link ATTRIBUTE_UNUSED, rtx dep_insn, int cost) function's address. */ if (CALL_P (insn)) { - rtx call = PATTERN (insn); - - if (GET_CODE (call) == PARALLEL) - call = XVECEXP (call, 0 ,0); - if (GET_CODE (call) == SET) - call = SET_SRC (call); - if (GET_CODE (call) == CALL && MEM_P (XEXP (call, 0)) + rtx call = get_call_rtx_from (insn); + if (call /* sibcalli_thunk uses a symbol_ref in an unspec. */ && (GET_CODE (XEXP (XEXP (call, 0), 0)) == UNSPEC || ! reg_set_p (XEXP (XEXP (call, 0), 0), dep_insn))) |