[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH v4 07/22] vhost: alloc shareable log
From: |
Marc-André Lureau |
Subject: |
Re: [Qemu-devel] [PATCH v4 07/22] vhost: alloc shareable log |
Date: |
Tue, 22 Sep 2015 13:50:47 +0200 |
hi
On Tue, Sep 22, 2015 at 1:41 PM, Michael S. Tsirkin <address@hidden> wrote:
> There's a single log at the moment:
> static struct vhost_log *vhost_log;
>
> But all devices are updated by the memory core, we don't
> have a list in the vhost code.
Do you mean that all devices will have their memory listener restart
the log, so they all point to the same global vhost_log?
>> >> Is there a clear benefit
>> >> of this? since the memory isn't shared without the memfd passed to
>> >> another process and the overhead of memfd is probably quite small, and
>> >> pre-shm or future resize will not use the shared memory already.
>> >
>> > For example, THP doesn't work for memfd at the moment,
>> > so all accesses are a bit slower.
>>
>> What's THP? How is it slower once the fd is mmap?
>
> Transparent huge page. This process doesn't work for
> memfd AFAIK.
>
>> > Really, I don't want to merge hacks. Switching from non memfd
>> > to memfd but not back has all the signs of one.
>> > Let's do it cleanly please.
>>
>> The current code isn't switching existing logs either. What would be
>> simpler to do is to allocate a different log region for the "share"
>> case. So there would be no need to switch other non-shareable logs (to
>> the cost of using twice the memory needed).
>
> OK, that's not too bad. Let's go for it.
ok, working on new patch
--
Marc-André Lureau
- [Qemu-devel] [PATCH v4 05/22] util: add linux-only memfd fallback, (continued)
- [Qemu-devel] [PATCH v4 05/22] util: add linux-only memfd fallback, marcandre . lureau, 2015/09/19
- [Qemu-devel] [PATCH v4 06/22] util: add memfd helpers, marcandre . lureau, 2015/09/19
- [Qemu-devel] [PATCH v4 07/22] vhost: alloc shareable log, marcandre . lureau, 2015/09/19
- Re: [Qemu-devel] [PATCH v4 07/22] vhost: alloc shareable log, Michael S. Tsirkin, 2015/09/21
- Re: [Qemu-devel] [PATCH v4 07/22] vhost: alloc shareable log, Marc-André Lureau, 2015/09/21
- Re: [Qemu-devel] [PATCH v4 07/22] vhost: alloc shareable log, Michael S. Tsirkin, 2015/09/21
- Re: [Qemu-devel] [PATCH v4 07/22] vhost: alloc shareable log, Marc-André Lureau, 2015/09/21
- Re: [Qemu-devel] [PATCH v4 07/22] vhost: alloc shareable log, Michael S. Tsirkin, 2015/09/22
- Re: [Qemu-devel] [PATCH v4 07/22] vhost: alloc shareable log, Marc-André Lureau, 2015/09/22
- Re: [Qemu-devel] [PATCH v4 07/22] vhost: alloc shareable log, Michael S. Tsirkin, 2015/09/22
- Re: [Qemu-devel] [PATCH v4 07/22] vhost: alloc shareable log,
Marc-André Lureau <=
- Re: [Qemu-devel] [PATCH v4 07/22] vhost: alloc shareable log, Michael S. Tsirkin, 2015/09/22
[Qemu-devel] [PATCH v4 08/22] vhost: document log resizing, marcandre . lureau, 2015/09/19
[Qemu-devel] [PATCH v4 09/22] vhost: use a function for each call, marcandre . lureau, 2015/09/19
[Qemu-devel] [PATCH v4 10/22] vhost-user: remove vhost_user_request_translate(), marcandre . lureau, 2015/09/19
[Qemu-devel] [PATCH v4 11/22] vhost-user: send log shm fd along with log_base, marcandre . lureau, 2015/09/19