From c3a4177fe14190fda53e6a31236dcb8e23cf28f8 Mon Sep 17 00:00:00 2001 From: Richard Guenther Date: Sun, 29 Oct 2006 15:18:24 +0000 Subject: genopinit.c (optabs): Change lfloor_optab and lceil_optab to conversion optabs. 2006-10-29 Richard Guenther * genopinit.c (optabs): Change lfloor_optab and lceil_optab to conversion optabs. * optabs.c (init_optabs): Initialize lfloor_optab and lceil_optab as conversion optab. * optabs.h (enum optab_index): Remove OTI_lfloor and OTI_lceil. (enum convert_optab_index): Add COI_lfloor and COI_lceil. (lfloor_optab, lceil_optab): Adjust defines. * builtins.c (expand_builtin_int_roundingfn): Adjust for lfloor and lceil optabs now being conversion optabs. * config/i386/i386-protos.h (ix86_expand_lfloorceil): Declare. * config/i386/i386.c (ix86_expand_sse_compare_and_jump): New static helper function. (ix86_expand_lfloorceil): New function to expand lfloor and lceil inline. * config/i386/i386.md (lfloor2): Split into ... (lfloorxf2): ... x87 variant (lfloordi2, lfloorsi2): ... and SSE variants using ix86_expand_lfloorceil. (lceil2, lceilxf2, lceildi2, lceilsi2): Likewise. * doc/md.texi (lfloorMN, lceilMN): Document. * gcc.target/i386/math-torture/lfloor.c: New testcase. * gcc.target/i386/math-torture/lceil.c: Likewise. From-SVN: r118143 --- gcc/optabs.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'gcc/optabs.h') diff --git a/gcc/optabs.h b/gcc/optabs.h index 0afc2ecc68c..0f84c9828d5 100644 --- a/gcc/optabs.h +++ b/gcc/optabs.h @@ -189,9 +189,7 @@ enum optab_index OTI_log1p, /* Rounding functions */ OTI_floor, - OTI_lfloor, OTI_ceil, - OTI_lceil, OTI_btrunc, OTI_round, OTI_nearbyint, @@ -337,9 +335,7 @@ extern GTY(()) optab optab_table[OTI_MAX]; #define log2_optab (optab_table[OTI_log2]) #define log1p_optab (optab_table[OTI_log1p]) #define floor_optab (optab_table[OTI_floor]) -#define lfloor_optab (optab_table[OTI_lfloor]) #define ceil_optab (optab_table[OTI_ceil]) -#define lceil_optab (optab_table[OTI_lceil]) #define btrunc_optab (optab_table[OTI_btrunc]) #define round_optab (optab_table[OTI_round]) #define nearbyint_optab (optab_table[OTI_nearbyint]) @@ -407,6 +403,8 @@ enum convert_optab_index COI_lrint, COI_lround, + COI_lfloor, + COI_lceil, COI_MAX }; @@ -424,6 +422,8 @@ extern GTY(()) convert_optab convert_optab_table[COI_MAX]; #define ufloat_optab (convert_optab_table[COI_ufloat]) #define lrint_optab (convert_optab_table[COI_lrint]) #define lround_optab (convert_optab_table[COI_lround]) +#define lfloor_optab (convert_optab_table[COI_lfloor]) +#define lceil_optab (convert_optab_table[COI_lceil]) /* These arrays record the insn_code of insns that may be needed to perform input and output reloads of special objects. They provide a -- cgit v1.2.1