From: Andrew Cooper <andrew.cooper3@citrix.com>
To: Jan Beulich <JBeulich@suse.com>, Corneliu ZUZU <czuzu@bitdefender.com>
Cc: Keir Fraser <keir@xen.org>, xen-devel@lists.xen.org
Subject: Re: X86 arch_domain ginormous, sizeof(struct domain) already == PAGE_SIZE
Date: Fri, 29 Jan 2016 17:12:37 +0000 [thread overview]
Message-ID: <56AB9D85.1000407@citrix.com> (raw)
In-Reply-To: <56ABAAF302000078000CC864@prv-mh.provo.novell.com>
On 29/01/16 17:09, Jan Beulich wrote:
>>>> On 29.01.16 at 17:24, <czuzu@bitdefender.com> wrote:
>> To investigate I compiled the unaltered domain.c & used the pahole tool
>> (part of dwarves package) to obtain the complete layout of the domain
>> structure (& its members).
>> What I obtained:
>> * sizeof(struct domain) is already = 4096 bytes (= PAGE_SIZE)
>> * sizeof(struct arch_domain) [x86] = sizeof(domain.arch) = 3328
>> bytes (arch_domain is marked __cacheline_aligned, i.e. aligned to 128 bytes)
>> * sizeof(domain.arch.hvm_domain) = 2224 bytes
>> * sizeof(domain.arch.hvm_domain.pl_time) = 1088 bytes
>>
>> => overall, X86 timers-related information occupies the most.
>>
>> One could shrink the domain structure by transforming some of its fields
>> to pointers, e.g. I could transform the pl_time field into a pointer and
>> dynamically allocate its data when domain_create is called.
> Sounds like a reasonable measure. I wasn't aware we're exactly on
> the boundary right now.
It has been teatering on the edge for a while now.
I keep on meaning to see about sliming it down somewhat (probably by
pulling an optional structure out into an explicit allocation), but
haven't had the time.
~Andrew
next prev parent reply other threads:[~2016-01-29 17:12 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-01-29 16:24 X86 arch_domain ginormous, sizeof(struct domain) already == PAGE_SIZE Corneliu ZUZU
2016-01-29 16:47 ` Lengyel, Tamas
2016-01-29 21:32 ` Corneliu ZUZU
2016-01-31 0:22 ` Lengyel, Tamas
2016-01-29 17:09 ` Jan Beulich
2016-01-29 17:12 ` Andrew Cooper [this message]
2016-01-29 21:45 ` Corneliu ZUZU
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=56AB9D85.1000407@citrix.com \
--to=andrew.cooper3@citrix.com \
--cc=JBeulich@suse.com \
--cc=czuzu@bitdefender.com \
--cc=keir@xen.org \
--cc=xen-devel@lists.xen.org \
/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.