[Top] [All Lists]

Re: XFS binary code size

To: Stan Hoeppner <stan@xxxxxxxxxxxxxxxxx>
Subject: Re: XFS binary code size
From: Dave Chinner <david@xxxxxxxxxxxxx>
Date: Tue, 27 Sep 2011 11:47:03 +1000
Cc: xfs@xxxxxxxxxxx
In-reply-to: <4E8106ED.9040909@xxxxxxxxxxxxxxxxx>
References: <4E8106ED.9040909@xxxxxxxxxxxxxxxxx>
User-agent: Mutt/1.5.21 (2010-09-15)
On Mon, Sep 26, 2011 at 06:12:45PM -0500, Stan Hoeppner wrote:
> I'm curious about the footprint of the XFS binary code, specifically
> for 32 bit systems, but knowing the 64 bit case would be educational
> as well for comparison.  I don't use kernel modules or I'd already
> have a rough answer.  My last build was but I'm sure the
> size hasn't changed much in more recent kernels.  My XFS build
> options were:
> $ grep -i xfs .config
> # CONFIG_XFS_QUOTA is not set
> # CONFIG_XFS_POSIX_ACL is not set
> # CONFIG_XFS_RT is not set
> My resulting kernel image is:
> $ la /boot/vmlinuz-
> -rw-r--r--  1 root root 1.6M May 17 23:55 vmlinuz-
> How much of that 1.6MB is XFS?

That's the compressed image that is 1.6MB, so the uncompressed
kernel will be quite a bit bigger than that. As it is, the XFs
binary size can be found from your source tree via:

$ size fs/xfs/xfs.ko
   text    data     bss     dec     hex filename
 468288   59632    1400  529320   813a8 fs/xfs/xfs.ko

So for my current kernel build on x86-64 with these options:

# CONFIG_XFS_DEBUG is not set

the XFS binary footprint is around 520kB. Yours will be smaller
given you don't have RT, ACL and quota configured, but it will still
probably be the largest single code block in your kernel...

> Also, what is the size of the hot
> path code that we want to stay in L1 during heavy IO?

Simple answer: it will stay in the L2 cache if we are lucky and
userspace doesn't trash the L2 cache between syscalls.

More complex answer: run perf w/ sampling on L1/L2 cache misses and
have a look for yourself.


Dave Chinner

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