diff options
author | Steven Bosscher <steven@gcc.gnu.org> | 2012-10-16 22:05:17 +0000 |
---|---|---|
committer | Steven Bosscher <steven@gcc.gnu.org> | 2012-10-16 22:05:17 +0000 |
commit | da4fdf2d3ff45366d9378882ad1646306ceee305 (patch) | |
tree | eafbca96b0b0771fa77620d1cff5cfc0a8a8b8be /gcc/calls.c | |
parent | f841b68397bb8b15ea570a7a86c5414f62cc9774 (diff) | |
download | gcc-da4fdf2d3ff45366d9378882ad1646306ceee305.zip gcc-da4fdf2d3ff45366d9378882ad1646306ceee305.tar.gz gcc-da4fdf2d3ff45366d9378882ad1646306ceee305.tar.bz2 |
rtl.h (get_call_rtx_from): New prototype.
* 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.
From-SVN: r192516
Diffstat (limited to 'gcc/calls.c')
-rw-r--r-- | gcc/calls.c | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/gcc/calls.c b/gcc/calls.c index 2180a62..d4ef639 100644 --- a/gcc/calls.c +++ b/gcc/calls.c @@ -384,13 +384,8 @@ emit_call_1 (rtx funexp, tree fntree ATTRIBUTE_UNUSED, tree fndecl ATTRIBUTE_UNU /* Some target create a fresh MEM instead of reusing the one provided above. Set its MEM_EXPR. */ - call = PATTERN (call_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)) + call = get_call_rtx_from (call_insn); + if (call && MEM_EXPR (XEXP (call, 0)) == NULL_TREE && MEM_EXPR (funmem) != NULL_TREE) set_mem_expr (XEXP (call, 0), MEM_EXPR (funmem)); |