diff options
author | zack <zack@138bc75d-0d04-0410-961f-82ee72b054a4> | 2001-08-18 19:59:46 +0000 |
---|---|---|
committer | zack <zack@138bc75d-0d04-0410-961f-82ee72b054a4> | 2001-08-18 19:59:46 +0000 |
commit | ad99e708993275cfd0d666486d9c1b8bc7107416 (patch) | |
tree | f45f62817a1ba4ec89643d51d48fc4dea2c0237b /gcc/function.c | |
parent | 9c44ac54d7f5256b72b2e36db6e92e62815ac844 (diff) | |
download | gcc-ad99e708993275cfd0d666486d9c1b8bc7107416.tar.gz |
* optabs.h (OTI_flodiv, flodiv_optab): Kill.
* genopinit.c: Put floating point divide insns in sdiv_optab.
* expr.c (expand_expr): Use sdiv_optab, not flodiv_optab.
* config/gofast.h, config/c4x/c4x.h,
config/ia64/hpux_longdouble.h, config/mips/mips.h,
config/pa/long_double.h, config/rs6000/sysv4.h,
config/sparc/sparc.h: Put floating point divide libcalls in sdiv_optab.
* optabs.c (init_optab): Break into new_optab, init_optab, init_optabv.
(init_optabs): Use init_optabv for overflow-trapping optabs.
Don't init flodiv_optab. Give mov_optab, movstrict_optab, and
cmp_optab RTX codes so have_insn_for can find them.
* optabs.c (expand_simple_binop, expand_simple_unop,
have_insn_for, gen_sub3_insn): New interfaces.
* expr.h: Prototype new functions.
(enum optab_methods): Move here from optabs.h.
* builtins.c, combine.c, doloop.c, function.c, ifcvt.c,
loop.c, profile.c, simplify-rtx.c, stmt.c, unroll.c:
Use new functions instead of working directly with optabs.
* doloop.c, ifcvt.c, loop.c, profile.c, simplify-rtx.c,
unroll.c: Don't include optabs.h.
* caller-save.c, combine.c, function.c, stmt.c: Just include
insn-codes.h, not optabs.h.
* Makefile.in: Update dependencies.
* combine.c (make_compound_operation, simplify_comparison):
Fix typos testing for this or that instruction.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@45008 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/function.c')
-rw-r--r-- | gcc/function.c | 29 |
1 files changed, 15 insertions, 14 deletions
diff --git a/gcc/function.c b/gcc/function.c index 0a6ed73b52e..c2424fd0732 100644 --- a/gcc/function.c +++ b/gcc/function.c @@ -46,11 +46,11 @@ Boston, MA 02111-1307, USA. */ #include "except.h" #include "function.h" #include "expr.h" -#include "optabs.h" #include "libfuncs.h" #include "regs.h" #include "hard-reg-set.h" #include "insn-config.h" +#include "insn-codes.h" #include "recog.h" #include "output.h" #include "basic-block.h" @@ -5693,12 +5693,13 @@ round_trampoline_addr (tramp) #ifdef TRAMPOLINE_ALIGNMENT /* Round address up to desired boundary. */ rtx temp = gen_reg_rtx (Pmode); - temp = expand_binop (Pmode, add_optab, tramp, - GEN_INT (TRAMPOLINE_ALIGNMENT / BITS_PER_UNIT - 1), - temp, 0, OPTAB_LIB_WIDEN); - tramp = expand_binop (Pmode, and_optab, temp, - GEN_INT (-TRAMPOLINE_ALIGNMENT / BITS_PER_UNIT), - temp, 0, OPTAB_LIB_WIDEN); + rtx addend = GEN_INT (TRAMPOLINE_ALIGNMENT / BITS_PER_UNIT - 1); + rtx mask = GEN_INT (-TRAMPOLINE_ALIGNMENT / BITS_PER_UNIT); + + temp = expand_simple_binop (Pmode, PLUS, tramp, addend, + temp, 0, OPTAB_LIB_WIDEN); + tramp = expand_simple_binop (Pmode, AND, temp, mask, + temp, 0, OPTAB_LIB_WIDEN); #endif return tramp; } @@ -6321,15 +6322,15 @@ expand_main_function () int align = PREFERRED_STACK_BOUNDARY / BITS_PER_UNIT; rtx tmp; - /* Forcably align the stack. */ + /* Forcibly align the stack. */ #ifdef STACK_GROWS_DOWNWARD - tmp = expand_binop (Pmode, and_optab, stack_pointer_rtx, - GEN_INT (-align), stack_pointer_rtx, 1, OPTAB_WIDEN); + tmp = expand_simple_binop (Pmode, AND, stack_pointer_rtx, GEN_INT(-align), + stack_pointer_rtx, 1, OPTAB_WIDEN); #else - tmp = expand_binop (Pmode, add_optab, stack_pointer_rtx, - GEN_INT (align - 1), NULL_RTX, 1, OPTAB_WIDEN); - tmp = expand_binop (Pmode, and_optab, tmp, GEN_INT (-align), - stack_pointer_rtx, 1, OPTAB_WIDEN); + tmp = expand_simple_binop (Pmode, PLUS, stack_pointer_rtx, + GEN_INT (align - 1), NULL_RTX, 1, OPTAB_WIDEN); + tmp = expand_simple_binop (Pmode, AND, tmp, GEN_INT (-align), + stack_pointer_rtx, 1, OPTAB_WIDEN); #endif if (tmp != stack_pointer_rtx) emit_move_insn (stack_pointer_rtx, tmp); |