diff options
author | Denis Vlasenko <vda.linux@googlemail.com> | 2008-06-27 02:52:20 +0000 |
---|---|---|
committer | Denis Vlasenko <vda.linux@googlemail.com> | 2008-06-27 02:52:20 +0000 |
commit | defc1ea34074e7882724c460260d307cdf981a70 (patch) | |
tree | fca9b9a5fe243f9c0c76b84824ea2ff92ea8e589 /include/xatonum.h | |
parent | 26bc57d8b26425f23f4be974cce7bf35c95c9a1a (diff) | |
download | busybox-w32-defc1ea34074e7882724c460260d307cdf981a70.tar.gz busybox-w32-defc1ea34074e7882724c460260d307cdf981a70.tar.bz2 busybox-w32-defc1ea34074e7882724c460260d307cdf981a70.zip |
*: introduce and use FAST_FUNC: regparm on i386, otherwise no-on
text data bss dec hex filename
808035 611 6868 815514 c719a busybox_old
804472 611 6868 811951 c63af busybox_unstripped
Diffstat (limited to 'include/xatonum.h')
-rw-r--r-- | include/xatonum.h | 40 |
1 files changed, 20 insertions, 20 deletions
diff --git a/include/xatonum.h b/include/xatonum.h index 6cf1299b3..944ee7742 100644 --- a/include/xatonum.h +++ b/include/xatonum.h | |||
@@ -14,20 +14,20 @@ | |||
14 | /* Provides extern declarations of functions */ | 14 | /* Provides extern declarations of functions */ |
15 | #define DECLARE_STR_CONV(type, T, UT) \ | 15 | #define DECLARE_STR_CONV(type, T, UT) \ |
16 | \ | 16 | \ |
17 | unsigned type xstrto##UT##_range_sfx(const char *str, int b, unsigned type l, unsigned type u, const struct suffix_mult *sfx); \ | 17 | unsigned type xstrto##UT##_range_sfx(const char *str, int b, unsigned type l, unsigned type u, const struct suffix_mult *sfx) FAST_FUNC; \ |
18 | unsigned type xstrto##UT##_range(const char *str, int b, unsigned type l, unsigned type u); \ | 18 | unsigned type xstrto##UT##_range(const char *str, int b, unsigned type l, unsigned type u) FAST_FUNC; \ |
19 | unsigned type xstrto##UT##_sfx(const char *str, int b, const struct suffix_mult *sfx); \ | 19 | unsigned type xstrto##UT##_sfx(const char *str, int b, const struct suffix_mult *sfx) FAST_FUNC; \ |
20 | unsigned type xstrto##UT(const char *str, int b); \ | 20 | unsigned type xstrto##UT(const char *str, int b) FAST_FUNC; \ |
21 | unsigned type xato##UT##_range_sfx(const char *str, unsigned type l, unsigned type u, const struct suffix_mult *sfx); \ | 21 | unsigned type xato##UT##_range_sfx(const char *str, unsigned type l, unsigned type u, const struct suffix_mult *sfx) FAST_FUNC; \ |
22 | unsigned type xato##UT##_range(const char *str, unsigned type l, unsigned type u); \ | 22 | unsigned type xato##UT##_range(const char *str, unsigned type l, unsigned type u) FAST_FUNC; \ |
23 | unsigned type xato##UT##_sfx(const char *str, const struct suffix_mult *sfx); \ | 23 | unsigned type xato##UT##_sfx(const char *str, const struct suffix_mult *sfx) FAST_FUNC; \ |
24 | unsigned type xato##UT(const char *str); \ | 24 | unsigned type xato##UT(const char *str) FAST_FUNC; \ |
25 | type xstrto##T##_range_sfx(const char *str, int b, type l, type u, const struct suffix_mult *sfx); \ | 25 | type xstrto##T##_range_sfx(const char *str, int b, type l, type u, const struct suffix_mult *sfx) FAST_FUNC; \ |
26 | type xstrto##T##_range(const char *str, int b, type l, type u); \ | 26 | type xstrto##T##_range(const char *str, int b, type l, type u) FAST_FUNC; \ |
27 | type xato##T##_range_sfx(const char *str, type l, type u, const struct suffix_mult *sfx); \ | 27 | type xato##T##_range_sfx(const char *str, type l, type u, const struct suffix_mult *sfx) FAST_FUNC; \ |
28 | type xato##T##_range(const char *str, type l, type u); \ | 28 | type xato##T##_range(const char *str, type l, type u) FAST_FUNC; \ |
29 | type xato##T##_sfx(const char *str, const struct suffix_mult *sfx); \ | 29 | type xato##T##_sfx(const char *str, const struct suffix_mult *sfx) FAST_FUNC; \ |
30 | type xato##T(const char *str); \ | 30 | type xato##T(const char *str) FAST_FUNC; \ |
31 | 31 | ||
32 | /* Unsigned long long functions always exist */ | 32 | /* Unsigned long long functions always exist */ |
33 | DECLARE_STR_CONV(long long, ll, ull) | 33 | DECLARE_STR_CONV(long long, ll, ull) |
@@ -122,8 +122,8 @@ static ALWAYS_INLINE uint32_t xatou32(const char *numstr) | |||
122 | * return value is all-ones in this case. | 122 | * return value is all-ones in this case. |
123 | */ | 123 | */ |
124 | 124 | ||
125 | unsigned long long bb_strtoull(const char *arg, char **endp, int base); | 125 | unsigned long long bb_strtoull(const char *arg, char **endp, int base) FAST_FUNC; |
126 | long long bb_strtoll(const char *arg, char **endp, int base); | 126 | long long bb_strtoll(const char *arg, char **endp, int base) FAST_FUNC; |
127 | 127 | ||
128 | #if ULONG_MAX == ULLONG_MAX | 128 | #if ULONG_MAX == ULLONG_MAX |
129 | static ALWAYS_INLINE | 129 | static ALWAYS_INLINE |
@@ -133,8 +133,8 @@ static ALWAYS_INLINE | |||
133 | long bb_strtol(const char *arg, char **endp, int base) | 133 | long bb_strtol(const char *arg, char **endp, int base) |
134 | { return bb_strtoll(arg, endp, base); } | 134 | { return bb_strtoll(arg, endp, base); } |
135 | #else | 135 | #else |
136 | unsigned long bb_strtoul(const char *arg, char **endp, int base); | 136 | unsigned long bb_strtoul(const char *arg, char **endp, int base) FAST_FUNC; |
137 | long bb_strtol(const char *arg, char **endp, int base); | 137 | long bb_strtol(const char *arg, char **endp, int base) FAST_FUNC; |
138 | #endif | 138 | #endif |
139 | 139 | ||
140 | #if UINT_MAX == ULLONG_MAX | 140 | #if UINT_MAX == ULLONG_MAX |
@@ -152,8 +152,8 @@ static ALWAYS_INLINE | |||
152 | int bb_strtoi(const char *arg, char **endp, int base) | 152 | int bb_strtoi(const char *arg, char **endp, int base) |
153 | { return bb_strtol(arg, endp, base); } | 153 | { return bb_strtol(arg, endp, base); } |
154 | #else | 154 | #else |
155 | unsigned bb_strtou(const char *arg, char **endp, int base); | 155 | unsigned bb_strtou(const char *arg, char **endp, int base) FAST_FUNC; |
156 | int bb_strtoi(const char *arg, char **endp, int base); | 156 | int bb_strtoi(const char *arg, char **endp, int base) FAST_FUNC; |
157 | #endif | 157 | #endif |
158 | 158 | ||
159 | int BUG_bb_strtou32_unimplemented(void); | 159 | int BUG_bb_strtou32_unimplemented(void); |