diff options
author | Steven Bosscher <steven@gcc.gnu.org> | 2008-06-17 05:57:04 +0000 |
---|---|---|
committer | Steven Bosscher <steven@gcc.gnu.org> | 2008-06-17 05:57:04 +0000 |
commit | 4a8cae8370a9c7ccaff2df5b552f52db51eb9f9b (patch) | |
tree | 8e1097fff4f927ebe993aa6e075eafcfd576b7bf /gcc/builtins.c | |
parent | e989f2d107b3251230471242c6f78cb220137cb8 (diff) | |
download | gcc-4a8cae8370a9c7ccaff2df5b552f52db51eb9f9b.zip gcc-4a8cae8370a9c7ccaff2df5b552f52db51eb9f9b.tar.gz gcc-4a8cae8370a9c7ccaff2df5b552f52db51eb9f9b.tar.bz2 |
Remove libcall notes.
* see.c (see_analyse_one_def): Do not look for REG_LIBCALL and
REG_RETVAL notes.
(see_update_relevancy): Likewise.
* fwprop.c (try_fwprop_subst): Likewise.
* rtlanal.c (noop_move_p): Likewise.
* builtins.c (expand_buitlin_mathfn): Don't try to add REG_EQUAL
notes to non-existing libcall blocks.
* cse.c (cse_insn): Change prototype. Don't update libcall notes.
Remove orig_set.
(cse_extended_basic_block): Don't track libcall and no-conflict notes.
(dead_libcall_p): Remove.
(delete_trivially_dead_insns): Don't use it.
* web.c (union_defs): Remove comment about keeping nops.
* gcse.c (hash_scan_insn): Don't take libcall pointers.
(compute_hash_table_work): Don't track libcall notes.
(do_local_cprop): Don't take libcall pointers. Don't update
libcall notes.
(adjust_libcall_notes): Deleted.
(local_cprop_pass): Remove stack for nested libcalls (which shouldn't
ever have existed in the first place).
(replace_store_insn): Don't try to remove libcall notes.
* lower-subreg.c (move_libcall_note, move_retval_note): Deleted.
(resolve_reg_notes): Don't call them.
(resolve_simple_move): Likewise.
(decompose_multiword_subregs): Remove block handling REG_RETVAL notes.
Don't remove REG_RETVAL notes.
* emit-rtl.c (try_split): Don't update libcall notes.
(emit_copy_of_insn_after): Dito.
* cselib.c (cselib_current_insn_in_libcall): Remove.
(cselib_process_insn): Don't set/clear it.
(new_elt_loc_list): Don't record it.
(cselib_init): Don't initialize it.
* cselib.c (struct elt_loc_list): Remove in_libcall field.
* loop-invariant.c (find_invariant_insn): Don't look for libcall
notes.
* sched-deps.c (sched_analyze_insn): Don't group libcall blocks.
(sched_analyze): Don't set up deps->libcall_block_tail_insn.
(init_deps): Don't initialize it.
* sched-int.h (struct deps): Rremove libcall_block_tail_insn field.
* combine.c (delete_noop_moves): Don't update libcall notes.
(can_combine_p): Remove now pointless #if 0 block.
(try_combine): Remove another obsolete #if 0 block.
(distribute_notes): Don't distribute libcall notes.
* reg-notes.def (REG_LIBCALL, REG_RETVAL): Remove.
* dce.c (libcall_dead_p): Remove.
(delete_unmarked_insns): Don't handle libcall blocks.
(preserve_libcall_for_dce): Remove.
(prescan_insns_for_dce): Don't special-case libcall block insns.
* reload1 (reload): Don't handle libcall notes.
* doc/rtl.texi (REG_LIBCALL, REG_RETVAL, REG_LIBCALL_ID): Remove
documentation.
From-SVN: r136861
Diffstat (limited to 'gcc/builtins.c')
-rw-r--r-- | gcc/builtins.c | 43 |
1 files changed, 1 insertions, 42 deletions
diff --git a/gcc/builtins.c b/gcc/builtins.c index b3fc304..57d9379 100644 --- a/gcc/builtins.c +++ b/gcc/builtins.c @@ -1945,48 +1945,7 @@ expand_builtin_mathfn (tree exp, rtx target, rtx subtarget) before_call = get_last_insn (); - target = expand_call (exp, target, target == const0_rtx); - - /* If this is a sqrt operation and we don't care about errno, try to - attach a REG_EQUAL note with a SQRT rtx to the emitted libcall. - This allows the semantics of the libcall to be visible to the RTL - optimizers. */ - if (builtin_optab == sqrt_optab && !errno_set) - { - /* Search backwards through the insns emitted by expand_call looking - for the instruction with the REG_RETVAL note. */ - rtx last = get_last_insn (); - while (last != before_call) - { - if (find_reg_note (last, REG_RETVAL, NULL)) - { - rtx note = find_reg_note (last, REG_EQUAL, NULL); - /* Check that the REQ_EQUAL note is an EXPR_LIST with - two elements, i.e. symbol_ref(sqrt) and the operand. */ - if (note - && GET_CODE (note) == EXPR_LIST - && GET_CODE (XEXP (note, 0)) == EXPR_LIST - && XEXP (XEXP (note, 0), 1) != NULL_RTX - && XEXP (XEXP (XEXP (note, 0), 1), 1) == NULL_RTX) - { - rtx operand = XEXP (XEXP (XEXP (note, 0), 1), 0); - /* Check operand is a register with expected mode. */ - if (operand - && REG_P (operand) - && GET_MODE (operand) == mode) - { - /* Replace the REG_EQUAL note with a SQRT rtx. */ - rtx equiv = gen_rtx_SQRT (mode, operand); - set_unique_reg_note (last, REG_EQUAL, equiv); - } - } - break; - } - last = PREV_INSN (last); - } - } - - return target; + return expand_call (exp, target, target == const0_rtx); } /* Expand a call to the builtin binary math functions (pow and atan2). |