All of lore.kernel.org
 help / color / mirror / Atom feed
From: Oleksii Kurochko <oleksii.kurochko@gmail.com>
To: Julien Grall <julien@xen.org>, Jan Beulich <jbeulich@suse.com>
Cc: "Alistair Francis" <alistair.francis@wdc.com>,
	"Bob Eshleman" <bobbyeshleman@gmail.com>,
	"Connor Davis" <connojdavis@gmail.com>,
	"Andrew Cooper" <andrew.cooper3@citrix.com>,
	"Anthony PERARD" <anthony.perard@vates.tech>,
	"Michal Orzel" <michal.orzel@amd.com>,
	"Roger Pau Monné" <roger.pau@citrix.com>,
	"Stefano Stabellini" <sstabellini@kernel.org>,
	xen-devel@lists.xenproject.org
Subject: Re: [PATCH v1] xen/riscv: Increase XEN_VIRT_SIZE
Date: Tue, 1 Apr 2025 17:46:25 +0200	[thread overview]
Message-ID: <ceec6a5b-89ba-45a9-a023-08f07bcce614@gmail.com> (raw)
In-Reply-To: <33786f0b-eefa-4f1f-ac57-7f1b2c74715e@xen.org>

[-- Attachment #1: Type: text/plain, Size: 1546 bytes --]


On 4/1/25 1:59 PM, Julien Grall wrote:
>
>
> On 01/04/2025 07:24, Jan Beulich wrote:
>> On 31.03.2025 18:17, Julien Grall wrote:
>>> On 31/03/2025 17:14, Jan Beulich wrote:
>>>> On 31.03.2025 17:20, Oleksii Kurochko wrote:
>>>>> A randconfig job failed with the following issue:
>>>>>     riscv64-linux-gnu-ld: Xen too large for early-boot assumptions
>>>>>
>>>>> The reason is that enabling the UBSAN config increased the size of
>>>>> the Xen binary.
>>>>>
>>>>> Increase XEN_VIRT_SIZE to reserve enough space, allowing both UBSAN
>>>>> and GCOV to be enabled together, with some slack for future growth.
>>>>
>>>> At some point you may want to use 2M mappings for .text (rx), .rodata
>>>> (r), and .data (rw).
>>>
>>> OOI, why would we want to switch to 2MB? At least on Arm, Xen is tiny
>>> enough that it can fit in less than a couple of MB. I would expect the
>>> same for RISC-V.
>>
>> For TLB efficiency reasons for example. On x86 we switched to using 2Mb
>> pages quite some time back, just to find that (at least) one of the
>> bootloaders choked on the then larger binary. Hence we ended up with
>> the XEN_ALIGN_2M Kconfig symbol plus the unconditional use of 2Mb
>> mappings for xen.efi. For the original change see cf393624eec3 ("x86:
>> use 2M superpages for text/data/bss mappings").
>
> For Arm, we can using the contiguous bit (it allows to combine a few 
> entries into one TLB on some CPUs) to reduce the TLB usage. Not sure 
> if RISC-V has a similar feature.

Unfortunately, RISC-V doesn't have such option.

~ Oleksii

[-- Attachment #2: Type: text/html, Size: 2779 bytes --]

  reply	other threads:[~2025-04-01 15:46 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-03-31 15:20 [PATCH v1] xen/riscv: Increase XEN_VIRT_SIZE Oleksii Kurochko
2025-03-31 16:14 ` Jan Beulich
2025-03-31 16:17   ` Julien Grall
2025-04-01  6:24     ` Jan Beulich
2025-04-01 11:59       ` Julien Grall
2025-04-01 15:46         ` Oleksii Kurochko [this message]
2025-04-01 15:58   ` Oleksii Kurochko
2025-04-01 16:04     ` Jan Beulich
2025-04-03 16:20       ` Oleksii Kurochko
2025-04-04  6:56         ` Jan Beulich
2025-04-04  7:31           ` Oleksii Kurochko
2025-04-04  7:52             ` Jan Beulich
2025-04-04  8:43               ` Oleksii Kurochko
2025-04-04 10:00                 ` Jan Beulich

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=ceec6a5b-89ba-45a9-a023-08f07bcce614@gmail.com \
    --to=oleksii.kurochko@gmail.com \
    --cc=alistair.francis@wdc.com \
    --cc=andrew.cooper3@citrix.com \
    --cc=anthony.perard@vates.tech \
    --cc=bobbyeshleman@gmail.com \
    --cc=connojdavis@gmail.com \
    --cc=jbeulich@suse.com \
    --cc=julien@xen.org \
    --cc=michal.orzel@amd.com \
    --cc=roger.pau@citrix.com \
    --cc=sstabellini@kernel.org \
    --cc=xen-devel@lists.xenproject.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.