diff options
author | Richard Sandiford <richard@codesourcery.com> | 2006-05-23 19:29:36 +0000 |
---|---|---|
committer | Richard Sandiford <rsandifo@gcc.gnu.org> | 2006-05-23 19:29:36 +0000 |
commit | b2a203c8e07fd3f8bb81f15780d6be9e6333f708 (patch) | |
tree | 45df1f817aceb17a9a8345af8607433bd5cbddea /gcc/libgcc2.c | |
parent | 550ab0c644e22dd5521ed75a5da8f73b15d274df (diff) | |
download | gcc-b2a203c8e07fd3f8bb81f15780d6be9e6333f708.zip gcc-b2a203c8e07fd3f8bb81f15780d6be9e6333f708.tar.gz gcc-b2a203c8e07fd3f8bb81f15780d6be9e6333f708.tar.bz2 |
libgcc2.c (LIBGCC2_MAX_UNITS_PER_WORD): New macro.
* libgcc2.c (LIBGCC2_MAX_UNITS_PER_WORD): New macro.
(LIBGCC2_UNITS_PER_WORD): Use LIBGCC2_MAX_UNITS_PER_WORD rather than
MIN_UNITS_PER_WORD to set the default. Also use it in the guard.
From-SVN: r114022
Diffstat (limited to 'gcc/libgcc2.c')
-rw-r--r-- | gcc/libgcc2.c | 23 |
1 files changed, 14 insertions, 9 deletions
diff --git a/gcc/libgcc2.c b/gcc/libgcc2.c index 3fce731..d093616 100644 --- a/gcc/libgcc2.c +++ b/gcc/libgcc2.c @@ -44,18 +44,23 @@ Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA #define MIN_UNITS_PER_WORD UNITS_PER_WORD #endif +/* Work out the largest "word" size that we can deal with on this target. */ +#if MIN_UNITS_PER_WORD > 4 +# define LIBGCC2_MAX_UNITS_PER_WORD 8 +#elif (MIN_UNITS_PER_WORD > 2 \ + || (MIN_UNITS_PER_WORD > 1 && LONG_LONG_TYPE_SIZE > 32)) +# define LIBGCC2_MAX_UNITS_PER_WORD 4 +#else +# define LIBGCC2_MAX_UNITS_PER_WORD MIN_UNITS_PER_WORD +#endif + +/* Work out what word size we are using for this compilation. + The value can be set on the command line. */ #ifndef LIBGCC2_UNITS_PER_WORD -# if MIN_UNITS_PER_WORD > 4 -# define LIBGCC2_UNITS_PER_WORD 8 -# elif (MIN_UNITS_PER_WORD > 2 \ - || (MIN_UNITS_PER_WORD > 1 && LONG_LONG_TYPE_SIZE > 32)) -# define LIBGCC2_UNITS_PER_WORD 4 -# else -# define LIBGCC2_UNITS_PER_WORD MIN_UNITS_PER_WORD -# endif +#define LIBGCC2_UNITS_PER_WORD LIBGCC2_MAX_UNITS_PER_WORD #endif -#if LIBGCC2_UNITS_PER_WORD <= MIN_UNITS_PER_WORD +#if LIBGCC2_UNITS_PER_WORD <= LIBGCC2_MAX_UNITS_PER_WORD #include "libgcc2.h" |