aboutsummaryrefslogtreecommitdiff
path: root/gcc/libgcc2.h
diff options
context:
space:
mode:
authorEric Christopher <echristo@apple.com>2006-11-01 05:14:40 +0000
committerGeoffrey Keating <geoffk@gcc.gnu.org>2006-11-01 05:14:40 +0000
commit167fa32c09eb5d93d23c74365a4ce818762de826 (patch)
tree75385000f3e0304a84896c064ff32d8b0dc1c9bb /gcc/libgcc2.h
parent5880f14fe8b5809110d1c3858c9259641fd5b92d (diff)
downloadgcc-167fa32c09eb5d93d23c74365a4ce818762de826.zip
gcc-167fa32c09eb5d93d23c74365a4ce818762de826.tar.gz
gcc-167fa32c09eb5d93d23c74365a4ce818762de826.tar.bz2
extend.texi (__builtin_bswap32): Document.
2006-09-07 Eric Christopher <echristo@apple.com> Falk Hueffner <falk@debian.org> * doc/extend.texi (__builtin_bswap32): Document. (__builtin_bswap64): Ditto. * doc/libgcc.texi (bswapsi2): Document. (bswapdi2): Ditto. * doc/rtl.texi (bswap): Document. * optabs.c (expand_unop): Don't widen a bswap. (init_optabs): Init bswap. Set libfuncs explicitly for bswapsi2 and bswapdi2. * optabs.h (OTI_bswap): New. (bswap_optab): Ditto. * genopinit.c (optabs): Handle bswap_optab. * tree.h (tree_index): Add TI_UINT32_TYPE and TI_UINT64_TYPE. (uint32_type_node): New. (uint64_type_node): Ditto. * tree.c (build_common_tree_nodes_2): Initialize uint32_type_node and uint64_type_node. * builtins.c (expand_builtin_bswap): New. (expand_builtin): Call. (fold_builtin_bswap): New. (fold_builtin_1): Call. * fold-const.c (tree_expr_nonnegative_p): Return true for bswap. * builtin-types.def (BT_UINT32): New. (BT_UINT64): Ditto. (BT_FN_UINT32_UINT32): Ditto. (BT_FN_UINT64_UINT64): Ditto. * builtins.def (BUILT_IN_BSWAP32): New. (BUILT_IN_BSWAP64): Ditto. * rtl.def (BSWAP): New. * genattrtab.c (check_attr_value): New. * libgcc2.c (__bswapSI2): New. (__bswapDI2): Ditto. * libgcc2.h (__bswapSI2): Declare. (__bswapDI2): Ditto. * mklibgcc.in (lib2funcs): Add _bswapsi2 and _bswapdi2. * simplify-rtx.c (simplify_const_unary_operation): Return 0 for BSWAP. * libgcc-std.ver (__bwapsi2): Add. (__bswapdi2): Ditto. * reload1.c (eliminate_regs_1): Add bswap. (elimination_effects): Ditto. * config/i386/i386.h (x86_bswap): New. (TARGET_BSWAP): Use. * config/i386/i386.c (x86_bswap): Set. Co-Authored-By: Falk Hueffner <falk@debian.org> From-SVN: r118361
Diffstat (limited to 'gcc/libgcc2.h')
-rw-r--r--gcc/libgcc2.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/gcc/libgcc2.h b/gcc/libgcc2.h
index c13f0c7..1182ba3 100644
--- a/gcc/libgcc2.h
+++ b/gcc/libgcc2.h
@@ -304,11 +304,13 @@ typedef int word_type __attribute__ ((mode (__word__)));
#define __ctzSI2 __NW(ctz,2)
#define __popcountSI2 __NW(popcount,2)
#define __paritySI2 __NW(parity,2)
+#define __bswapSI2 __NW(bswap,2)
#define __ffsDI2 __NDW(ffs,2)
#define __clzDI2 __NDW(clz,2)
#define __ctzDI2 __NDW(ctz,2)
#define __popcountDI2 __NDW(popcount,2)
#define __parityDI2 __NDW(parity,2)
+#define __bswapDI2 __NDW(bswap,2)
extern DWtype __muldi3 (DWtype, DWtype);
extern DWtype __divdi3 (DWtype, DWtype);
@@ -345,11 +347,13 @@ extern Wtype __addvSI3 (Wtype, Wtype);
extern Wtype __subvSI3 (Wtype, Wtype);
extern Wtype __mulvSI3 (Wtype, Wtype);
extern Wtype __negvSI2 (Wtype);
+extern UWtype __bswapSI2 (UWtype);
extern DWtype __absvDI2 (DWtype);
extern DWtype __addvDI3 (DWtype, DWtype);
extern DWtype __subvDI3 (DWtype, DWtype);
extern DWtype __mulvDI3 (DWtype, DWtype);
extern DWtype __negvDI2 (DWtype);
+extern UDWtype __bswapDI2 (UDWtype);
#ifdef COMPAT_SIMODE_TRAPPING_ARITHMETIC
extern SItype __absvsi2 (SItype);