diff options
author | Manfred Hollstein <mh@suse.com> | 2005-07-25 16:17:01 +0000 |
---|---|---|
committer | Manfred Hollstein <manfred@gcc.gnu.org> | 2005-07-25 16:17:01 +0000 |
commit | 1490f93a3c1bdce96d2dddfae1825821c703ab1c (patch) | |
tree | 17a9c480a057f2826a9bb761e91c952fbd5dc9f4 /gcc/calls.c | |
parent | 76e20664f62d3da317b2594c5ee15c1dd09e1709 (diff) | |
download | gcc-1490f93a3c1bdce96d2dddfae1825821c703ab1c.zip gcc-1490f93a3c1bdce96d2dddfae1825821c703ab1c.tar.gz gcc-1490f93a3c1bdce96d2dddfae1825821c703ab1c.tar.bz2 |
* calls.c (store_one_arg): Fix unsigned comparison warning.
From-SVN: r102363
Diffstat (limited to 'gcc/calls.c')
-rw-r--r-- | gcc/calls.c | 21 |
1 files changed, 13 insertions, 8 deletions
diff --git a/gcc/calls.c b/gcc/calls.c index ea6eaeb..08d73a6 100644 --- a/gcc/calls.c +++ b/gcc/calls.c @@ -4080,7 +4080,7 @@ store_one_arg (struct arg_data *arg, rtx argblock, int flags, if ((flags & ECF_SIBCALL) && MEM_P (arg->value)) { int i = -1; - unsigned int k; + unsigned HOST_WIDE_INT k; rtx x = arg->value; if (XEXP (x, 0) == current_function_internal_arg_pointer) @@ -4098,13 +4098,18 @@ store_one_arg (struct arg_data *arg, rtx argblock, int flags, #ifdef ARGS_GROW_DOWNWARD i = -i - arg->locate.size.constant; #endif - for (k = 0; k < arg->locate.size.constant; k++) - if (i + k < stored_args_map->n_bits - && TEST_BIT (stored_args_map, i + k)) - { - sibcall_failure = 1; - break; - } + if (arg->locate.size.constant > 0) + { + unsigned HOST_WIDE_INT sc = arg->locate.size.constant; + + for (k = 0; k < sc; k++) + if (i + k < stored_args_map->n_bits + && TEST_BIT (stored_args_map, i + k)) + { + sibcall_failure = 1; + break; + } + } } } |