qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH 5/9] util/bufferiszero: Use i386 cpuinfo.h


From: Richard Henderson
Subject: Re: [PATCH 5/9] util/bufferiszero: Use i386 cpuinfo.h
Date: Thu, 18 May 2023 05:48:38 -0700
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.11.0

On 5/18/23 02:49, Juan Quintela wrote:
Richard Henderson <richard.henderson@linaro.org> wrote:
Use cpuinfo_init() during init_accel(), and the variable cpuinfo
during test_buffer_is_zero_next_accel().  Adjust the logic that
cycles through the set of accelerators for testing.

Signed-off-by: Richard Henderson <richard.henderson@linaro.org>

Semi related to this.

For migration, I check every single page to see if it is full of zeros.
But I can promisse that it is just a page (i.e. 4KiB, 16KiB or 64KiB,
correct alignation, correct length, ...).

Will do it make sense to have an special function for that?

Yes, I have found with perf that bufferiszero() is quite high.  No, I
haven't try to experiment using a function that is optimized for the
page size in the architecture.

What do you think?

The optimized bufferiszero functions are already optimized for their blocklength (64, 128, 256). I don't think adding page multiples will do much more.


r~




reply via email to

[Prev in Thread] Current Thread [Next in Thread]