Re: [PATCH v6 2/2] refs.c: SSE4.2 optimizations for check_refname_component

2 messages, 2 authors, 2016-06-15 · open the first message on its own page

Re: [PATCH v6 2/2] refs.c: SSE4.2 optimizations for check_refname_component

From: Junio C Hamano <hidden>
Date: 2016-06-15 23:01:29

David Turner [off-list ref] writes:
On Wed, 2014-06-04 at 10:04 +0200, Torsten Bögershausen wrote:
[snip discussion of compiler flags; I'll look into a cpuid approach]
Hmmmm, I am not sure if the complexity is really worth it.

In any case, [PATCH 1/2] is fairly uncontroversial, so I am inclined
to queue it by itself early without waiting for the discussion on
2/2 to settle.
quoted
The name check_refname_component_1() doesn't tell too much,
(check_refname_component_sse42()  or check_refname_component_nonsse42() say more)
I'll go with "_bytewise", since that's how it works.
That naming assumes that there will never be any alternative
implementation of the bytewise checker other than the one that uses
sse42, no?
quoted
can I suggest to move all SSE code out to a file under compat/,
like compat/refs_sse42.c, or something similar ?
Since this is a relatively small section of code, I think that would be
overkill.  Does anyone else have an opinion?
If we foresee people on other architectures to invent different
vectorized implementations on their favourite archs, we may end up
separating it out into compat/.  I have no opinion on how likely
that will happen, though, and because this is a small piece of code
right now, it shouldn't be too painful to reorganize when the time
comes.

Re: [PATCH v6 2/2] refs.c: SSE4.2 optimizations for check_refname_component

From: David Turner <hidden>
Date: 2016-06-15 23:01:29

On Wed, 2014-06-04 at 14:46 -0700, Junio C Hamano wrote:
David Turner [off-list ref] writes:
quoted
On Wed, 2014-06-04 at 10:04 +0200, Torsten Bögershausen wrote:
[snip discussion of compiler flags; I'll look into a cpuid approach]
Hmmmm, I am not sure if the complexity is really worth it.

In any case, [PATCH 1/2] is fairly uncontroversial, so I am inclined
to queue it by itself early without waiting for the discussion on
2/2 to settle.
quoted
quoted
The name check_refname_component_1() doesn't tell too much,
(check_refname_component_sse42()  or check_refname_component_nonsse42() say more)
I'll go with "_bytewise", since that's how it works.
That naming assumes that there will never be any alternative
implementation of the bytewise checker other than the one that uses
sse42, no?
check_refname_component_1 is the non-sse (LUT) one; I assume that there
will only be one implementation of that (and if there's later another
one we can rename it).  I guess this is strong evidence for _1 being a
bad name.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help