diff options
author | Denis Vlasenko <vda.linux@googlemail.com> | 2008-12-26 04:25:09 +0000 |
---|---|---|
committer | Denis Vlasenko <vda.linux@googlemail.com> | 2008-12-26 04:25:09 +0000 |
commit | 0ef4c6b76fcaca59014c4d00828d4079314c1700 (patch) | |
tree | 91ccf816a2b3cbe5d95b4501f1d859316d9b4a7b /libc/misc/regex/regex_internal.h | |
parent | 6eb4415eaaaa2a01209262555f0a115a46deeb36 (diff) |
regex: drop __<funcname> aliases. remove much of unused code.
shrink offset tables. disable "likely/unlikely" BE() macro.
text data bss dec hex filename
- 515032 2731 15424 533187 822c3 lib/libuClibc-0.9.30-svn.so
+ 515014 2731 15424 533169 822b1 lib/libuClibc-0.9.30-svn.so
Diffstat (limited to 'libc/misc/regex/regex_internal.h')
-rw-r--r-- | libc/misc/regex/regex_internal.h | 30 |
1 files changed, 8 insertions, 22 deletions
diff --git a/libc/misc/regex/regex_internal.h b/libc/misc/regex/regex_internal.h index f0499caf0..7b95d2e38 100644 --- a/libc/misc/regex/regex_internal.h +++ b/libc/misc/regex/regex_internal.h @@ -29,23 +29,22 @@ #if defined HAVE_LANGINFO_H || defined HAVE_LANGINFO_CODESET || defined _LIBC # include <langinfo.h> -/* libc_hidden_proto(nl_langinfo) */ #endif #if defined HAVE_LOCALE_H || defined _LIBC # include <locale.h> #endif #if defined HAVE_WCHAR_H || defined _LIBC # include <wchar.h> -#endif /* HAVE_WCHAR_H || _LIBC */ +#endif #if defined HAVE_WCTYPE_H || defined _LIBC # include <wctype.h> -#endif /* HAVE_WCTYPE_H || _LIBC */ +#endif #if defined HAVE_STDBOOL_H || defined _LIBC # include <stdbool.h> -#endif /* HAVE_STDBOOL_H || _LIBC */ +#endif #if defined HAVE_STDINT_H || defined _LIBC # include <stdint.h> -#endif /* HAVE_STDINT_H || _LIBC */ +#endif #if defined _LIBC # include <bits/libc-lock.h> #else @@ -92,7 +91,9 @@ #endif #if __GNUC__ >= 3 -# define BE(expr, val) __builtin_expect (expr, val) +/* uclibc: lean towards smaller size a bit: + * OFF: # define BE(expr, val) __builtin_expect (expr, val) */ +# define BE(expr, val) (expr) #else # define BE(expr, val) (expr) # define inline @@ -112,9 +113,7 @@ # define __wctype wctype # define __iswctype iswctype # define __btowc btowc -# define __mempcpy mempcpy # define __wcrtomb wcrtomb -# define __regfree regfree # define attribute_hidden #endif /* not _LIBC */ @@ -124,9 +123,6 @@ # define __attribute(arg) #endif -extern const char __re_error_msgid[] attribute_hidden; -extern const size_t __re_error_msgid_idx[] attribute_hidden; - /* An integer used to represent a set of bits. It must be unsigned, and must be at least as wide as unsigned int. */ typedef unsigned long int bitset_word_t; @@ -369,18 +365,9 @@ struct re_string_t }; typedef struct re_string_t re_string_t; - struct re_dfa_t; typedef struct re_dfa_t re_dfa_t; -#if !defined _LIBC && !defined __UCLIBC__ -# ifdef __i386__ -# define internal_function __attribute ((regparm (3), stdcall)) -# else -# define internal_function -# endif -#endif - static reg_errcode_t re_string_realloc_buffers (re_string_t *pstr, int new_buf_len) internal_function; @@ -752,9 +739,8 @@ re_string_elem_size_at (const re_string_t *pstr, int idx) tmp = findidx (&p); return p - pstr->mbs - idx; } - else # endif /* _LIBC */ - return 1; + return 1; } #endif /* RE_ENABLE_I18N */ |