aboutsummaryrefslogtreecommitdiff
path: root/gcc/calls.c
diff options
context:
space:
mode:
authorH.J. Lu <hongjiu.lu@intel.com>2008-05-10 00:41:39 +0000
committerH.J. Lu <hjl@gcc.gnu.org>2008-05-09 17:41:39 -0700
commit17b29c0a1700733775c8190c57117fe3bbbd91cf (patch)
tree735fd06cfce1ffc7f37782aff0f57f0032845332 /gcc/calls.c
parentb0d2eb9a1a64313dd406ce1fe949be18b8e0f100 (diff)
downloadgcc-17b29c0a1700733775c8190c57117fe3bbbd91cf.zip
gcc-17b29c0a1700733775c8190c57117fe3bbbd91cf.tar.gz
gcc-17b29c0a1700733775c8190c57117fe3bbbd91cf.tar.bz2
calls.c (expand_call): Don't use callgraph to increase preferred_stack_boundary.
2008-05-09 H.J. Lu <hongjiu.lu@intel.com> * calls.c (expand_call): Don't use callgraph to increase preferred_stack_boundary. * cgraph.h (cgraph_rtl_info): Use unsigned on preferred_incoming_stack_boundary. * final.c (rest_of_clean_state): Use unsigned on preferred_stack_boundary. From-SVN: r135134
Diffstat (limited to 'gcc/calls.c')
-rw-r--r--gcc/calls.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/gcc/calls.c b/gcc/calls.c
index bbb9b76..ac83982 100644
--- a/gcc/calls.c
+++ b/gcc/calls.c
@@ -2109,7 +2109,14 @@ expand_call (tree exp, rtx target, int ignore)
if (fndecl)
{
struct cgraph_rtl_info *i = cgraph_rtl_info (fndecl);
- if (i && i->preferred_incoming_stack_boundary)
+ /* Without automatic stack alignment, we can't increase preferred
+ stack boundary. With automatic stack alignment, it is
+ unnecessary since unless we can guarantee that all callers will
+ align the outgoing stack properly, callee has to align its
+ stack anyway. */
+ if (i
+ && i->preferred_incoming_stack_boundary
+ && i->preferred_incoming_stack_boundary < preferred_stack_boundary)
preferred_stack_boundary = i->preferred_incoming_stack_boundary;
}