Re: [PATCH 2/2] xor/kunit: add a benchmark

From: Eric Biggers

Date: Thu Jun 18 2026 - 13:16:12 EST


On Thu, Jun 18, 2026 at 11:22:24AM +0200, Christoph Hellwig wrote:
> On Wed, Jun 17, 2026 at 05:14:48PM +0000, Eric Biggers wrote:
> > The #ifdef can be avoided using kunit_skip(), as the crypto and CRC
> > tests do:
> >
> > if (!IS_ENABLED(CONFIG_XOR_BENCHMARK))
> > kunit_skip(test, "not enabled");
>
> I saw that, but what's the point or just not compiling it?

Just the usual point of avoiding #ifdefs. Developers won't have to
build the file with two different kconfigs to ensure it builds.

- Eric