aboutsummaryrefslogtreecommitdiffstats
path: root/gen/bits/intconf.h
diff options
context:
space:
mode:
authorMattias Andrée <maandree@member.fsf.org>2015-12-20 14:31:40 +0100
committerMattias Andrée <maandree@member.fsf.org>2015-12-20 14:31:40 +0100
commit679b8bdb5c40ca1909b025db10ddb5a98967c60e (patch)
treef0c051e0569138a5c292e30892001604b65f851f /gen/bits/intconf.h
parentfix issue #8 on github (diff)
downloadslibc-679b8bdb5c40ca1909b025db10ddb5a98967c60e.tar.gz
slibc-679b8bdb5c40ca1909b025db10ddb5a98967c60e.tar.bz2
slibc-679b8bdb5c40ca1909b025db10ddb5a98967c60e.tar.xz
optimise implementations of {hton,ntoh}{s,l,ll}
Signed-off-by: Mattias Andrée <maandree@member.fsf.org>
Diffstat (limited to 'gen/bits/intconf.h')
-rw-r--r--gen/bits/intconf.h18
1 files changed, 18 insertions, 0 deletions
diff --git a/gen/bits/intconf.h b/gen/bits/intconf.h
index 69ea473..4d22435 100644
--- a/gen/bits/intconf.h
+++ b/gen/bits/intconf.h
@@ -97,6 +97,24 @@
#define __WCHAR_BIT //(bin/gen/bits/intconf | grep ^WCHAR_BIT | sed "s/^[^ ]* //")
/**
+ * The 16-bit integer 0x0102 but with the
+ * bytes swapped to the storage order.
+ */
+#define __INT16_BYTEORDER //(bin/gen/bits/intconf | grep ^INT16_BYTEORDER | sed "s/^[^ ]* //")
+
+/**
+ * The 32-bit integer 0x01020304 but with
+ * the bytes swapped to the storage order.
+ */
+#define __INT32_BYTEORDER //(bin/gen/bits/intconf | grep ^INT32_BYTEORDER | sed "s/^[^ ]* //")
+
+/**
+ * The 64-bit integer 0x0102030405060708 but with
+ * the bytes swapped to the storage order.
+ */
+#define __INT64_BYTEORDER //(bin/gen/bits/intconf | grep ^INT64_BYTEORDER | sed "s/^[^ ]* //")
+
+/**
* The underlaying intrinsic type for `int8_t` or `uint8_t`.
*/
#define __INT8 //(bin/gen/bits/intconf | grep ^INT8 | sed "s/^[^ ]* //" | sed 1q)