xfs
[Top] [All Lists]

on stack space....

To: xfs@xxxxxxxxxxx
Subject: on stack space....
From: Eric Sandeen <sandeen@xxxxxxxxxxx>
Date: Fri, 01 Dec 2006 14:28:37 -0600
Sender: xfs-bounce@xxxxxxxxxxx
User-agent: Thunderbird 1.5.0.8 (X11/20061107)
On the issue of stack space & where it goes in xfs...

<arjan> checkstack does not count function call arguments
<arjan> if you pass big-ish structures to functions things get skewed
quickly
<arjan> the caller pushes the arguments
<arjan> just before the 'call'

and also:

<arjan> btw one thing that helps modern gcc is to move variable
declarations into the inner most {} scope possible
<sandeen> does it really help?
<arjan> it'll allow it to share stack slots
<sandeen> older gccs that was actually -worse-
<arjan> yes
<sandeen> xfs was originally largely written that way
<sandeen> how recent?
<arjan> 4.1 and later have this fixed

lots of irix xfs was written this way IIRC, but I think things got moved
out.  Maybe it'd help to move them back in, for things like xfs_bmapi...

although it's a -penalty- for older gcc's still I think.

Anyway, just found that interesting, might help us get some of this
under control without a huge amount of refactoring...

-Eric


<Prev in Thread] Current Thread [Next in Thread>
  • on stack space...., Eric Sandeen <=