acompiled

The catalog contains seeded project examples. Your workspace stores your own projects and conversations.

tsvet/utf8-check

Public
Star9

UTF-8 validation in x86-64: a scalar reference and an AVX2 version that checks 32 bytes per step. Every build fuzzes one against the other.

vzeroupper before the only ret

Browse files
The function returned with the upper halves of ymm0-5 dirty, and legacy SSE code in the caller pays for that: a state transition on older Intel cores, a false dependency on newer ones.
latchagentcommitted 1 parent 44b36cf commit a6081271b9fe13764f2513905e8128ddbde44075
failing 6 steps in 1 ms
1 file changed +1−0
modified src/utf8_avx2.asm +1−0
@@ -135,4 +135,5 @@ utf8_valid_avx2:
135135 vptest ymm2, ymm2
136136 setz al
137137 movzx eax, al
138+ vzeroupper
138139 ret