From: Rik van Riel <riel@redhat.com>
To: xen-devel@lists.xensource.com
Subject: Re: [Fwd: stack overflow "cause" found]
Date: Wed, 26 Jul 2006 16:49:21 -0400 [thread overview]
Message-ID: <44C7D551.3030601@redhat.com> (raw)
In-Reply-To: <44C7C789.1030707@redhat.com>
Rik van Riel wrote:
> Xen really should not be doing this. We could either uninline some of
> these functions, or try gcc -O2 or gcc -Os.
OK, with -Os it doesn't quite build due to the built-ins not being
inlined. With -O2 the stack usage changes dramatically...
> Currently the top stack users are:
>
> $ objdump -dS xen-syms | ./checkstack.pl x86_64
> 0xffff8300001c7c47 find_unisys_acpi_oem_table: 1296
> 0xffff83000011182e do_xen_version: 1280
> 0xffff83000015bc3e x86_emulate_memop: 1264
> 0xffff8300001adbaa vmx_world_save: 1040
> 0xffff8300001aeac5 vmx_world_save: 1040
> 0xffff8300001af923 vmx_assist: 224
The function vmx_world_save is inlined into vmx_assist with -O2,
and the combined stack use is only 200 bytes, down from 1264 !
I guess we'll want to build Xen with -O2. I'm testing a -O2 built
hypervisor right now...
--
"Debugging is twice as hard as writing the code in the first place.
Therefore, if you write the code as cleverly as possible, you are,
by definition, not smart enough to debug it." - Brian W. Kernighan
next prev parent reply other threads:[~2006-07-26 20:49 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-07-26 19:50 [Fwd: stack overflow "cause" found] Rik van Riel
2006-07-26 20:49 ` Rik van Riel [this message]
-- strict thread matches above, loose matches on Subject: below --
2006-07-26 21:46 Ian Pratt
2006-07-26 21:49 ` Rik van Riel
2006-07-27 9:20 ` Keir Fraser
2006-07-26 22:29 Nakajima, Jun
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=44C7D551.3030601@redhat.com \
--to=riel@redhat.com \
--cc=xen-devel@lists.xensource.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.