xfs
[Top] [All Lists]

Re: Large Stack Usage in One More Function

To: Danny Cox <danscox@xxxxxxxxxxxxxx>
Subject: Re: Large Stack Usage in One More Function
From: Steve Lord <lord@xxxxxxx>
Date: 27 Aug 2002 12:04:42 -0500
Cc: XFS Mailing List <linux-xfs@xxxxxxxxxxx>
In-reply-to: <1030467482.1611.14.camel@wiley>
References: <1030467482.1611.14.camel@wiley>
Sender: linux-xfs-bounce@xxxxxxxxxxx
On Tue, 2002-08-27 at 11:58, Danny Cox wrote:
> 
> Hi, Guys!
> 
>       After having read of the stack "issues" awhile back, and then having an
> idea or two gel in my head (it didn't hurt much ;-), I put them
> together, and found that xfs_ioctl() is using 752 bytes of stack.  I
> chose 512 as the number of bytes above which to complain about, and
> looking at the code, I'd guess that the var "vattr_t va" struct is the
> main culprit.

Probably not just the vattr_t, most of the function is a large switch
statement, and each case in there has its own on the stack variables.
If the compiler is not being smart about it they would each get
their own non-overlapping space.

Thanks

  Steve

p.s. and yes, please send the script.

-- 

Steve Lord                                      voice: +1-651-683-3511
Principal Engineer, Filesystem Software         email: lord@xxxxxxx


<Prev in Thread] Current Thread [Next in Thread>