summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authoramodra <amodra@138bc75d-0d04-0410-961f-82ee72b054a4>2003-02-10 06:16:53 +0000
committeramodra <amodra@138bc75d-0d04-0410-961f-82ee72b054a4>2003-02-10 06:16:53 +0000
commitfd2c0c1dce1870a16d89f40709747bb66bb20beb (patch)
treebfb3ef814276bfc2fba2a12c40942b1b606a89ab
parentcf5ebb811d93e913a8a62b4c685263363b5b3bf5 (diff)
downloadppe42-gcc-fd2c0c1dce1870a16d89f40709747bb66bb20beb.tar.gz
ppe42-gcc-fd2c0c1dce1870a16d89f40709747bb66bb20beb.zip
* calls.c (try_to_integrate): Tidy stack_usage_map access.
(emit_library_call_value_1): Likewise. Formatting. (store_one_arg): Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@62622 138bc75d-0d04-0410-961f-82ee72b054a4
-rw-r--r--gcc/ChangeLog6
-rw-r--r--gcc/calls.c50
2 files changed, 33 insertions, 23 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index f46f6234cf9..8cdbe9217a7 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,9 @@
+2003-02-10 Alan Modra <amodra@bigpond.net.au>
+
+ * calls.c (try_to_integrate): Tidy stack_usage_map access.
+ (emit_library_call_value_1): Likewise. Formatting.
+ (store_one_arg): Likewise.
+
2003-02-09 Nick Clifton <nickc@redhat.com>
Aldy Hernandez <aldyh@redhat.com>
diff --git a/gcc/calls.c b/gcc/calls.c
index 31ad51c131d..6bec3df19a0 100644
--- a/gcc/calls.c
+++ b/gcc/calls.c
@@ -1834,9 +1834,11 @@ try_to_integrate (fndecl, actparms, target, ignore, type, structure_value_addr)
the stack before executing the inlined function if it
makes any calls. */
- for (i = reg_parm_stack_space - 1; i >= 0; i--)
- if (i < highest_outgoing_arg_in_use && stack_usage_map[i] != 0)
- break;
+ i = reg_parm_stack_space;
+ if (i > highest_outgoing_arg_in_use)
+ i = highest_outgoing_arg_in_use;
+ while (--i >= 0 && stack_usage_map[i] == 0)
+ ;
if (stack_arg_under_construction || i >= 0)
{
@@ -3727,12 +3729,12 @@ emit_library_call_value_1 (retval, orgfun, value, fn_type, outmode, nargs, p)
{
tree type = (*lang_hooks.types.type_for_mode) (mode, 0);
- slot = gen_rtx_MEM (mode,
- expand_expr (build1 (ADDR_EXPR,
- build_pointer_type
- (type),
- make_tree (type, val)),
- NULL_RTX, VOIDmode, 0));
+ slot
+ = gen_rtx_MEM (mode,
+ expand_expr (build1 (ADDR_EXPR,
+ build_pointer_type (type),
+ make_tree (type, val)),
+ NULL_RTX, VOIDmode, 0));
}
call_fusage = gen_rtx_EXPR_LIST (VOIDmode,
@@ -3923,14 +3925,15 @@ emit_library_call_value_1 (retval, orgfun, value, fn_type, outmode, nargs, p)
upper_bound = lower_bound + argvec[argnum].size.constant;
#endif
- for (i = lower_bound; i < upper_bound; i++)
- if (stack_usage_map[i]
- /* Don't store things in the fixed argument area at this
- point; it has already been saved. */
- && i > reg_parm_stack_space)
- break;
+ i = lower_bound;
+ /* Don't worry about things in the fixed argument area;
+ it has already been saved. */
+ if (i < reg_parm_stack_space)
+ i = reg_parm_stack_space;
+ while (i < upper_bound && stack_usage_map[i] == 0)
+ i++;
- if (i != upper_bound)
+ if (i < upper_bound)
{
/* We need to make a save area. See what mode we can make
it. */
@@ -4301,14 +4304,15 @@ store_one_arg (arg, argblock, flags, variable_size, reg_parm_stack_space)
upper_bound = lower_bound + arg->size.constant;
#endif
- for (i = lower_bound; i < upper_bound; i++)
- if (stack_usage_map[i]
- /* Don't store things in the fixed argument area at this point;
- it has already been saved. */
- && i > reg_parm_stack_space)
- break;
+ i = lower_bound;
+ /* Don't worry about things in the fixed argument area;
+ it has already been saved. */
+ if (i < reg_parm_stack_space)
+ i = reg_parm_stack_space;
+ while (i < upper_bound && stack_usage_map[i] == 0)
+ i++;
- if (i != upper_bound)
+ if (i < upper_bound)
{
/* We need to make a save area. See what mode we can make it. */
enum machine_mode save_mode
OpenPOWER on IntegriCloud