coreutils
[Top][All Lists]
Advanced

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

Re: [PATCH] wc: Add AVX2 optimization when counting only lines


From: Pádraig Brady
Subject: Re: [PATCH] wc: Add AVX2 optimization when counting only lines
Date: Fri, 23 Apr 2021 10:26:00 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:84.0) Gecko/20100101 Thunderbird/84.0

On 22/04/2021 19:54, Bernhard Voelker wrote:
On 4/21/21 8:13 PM, Assaf Gordon wrote:
I'm attaching the patch (copied from the Github's pull-request),
hopefully we can continue the discussion here on the mailing list.

Phew, so I see it's about getting 0-5x better performance versus decreased 
maintainability
due having yet another implementation of the counting in wc: we already have 
different cases
for multi-byte, for !count_chars etc.
I'm not sure whether it's worth complicating the tool, and - as Rasmus 
mentioned - the
bottleneck is probably somewhere else.

Yes a fair point,
but the gains are worth it IMHO.
The awkward maintenance issue with separated flags in separate libs
is already developed and in place.
Going forward I think there will be a less homogenous landscape of CPUs,
so believe this will be of future benefit.

I plan to work on wc-avx2 this weekend.

cheers,
Pádraig



reply via email to

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