From: Luke Kenneth Casson Leighton Date: Sun, 11 Feb 2024 15:26:07 +0000 (+0000) Subject: add strncpy TODO background X-Git-Url: https://git.libre-soc.org/?p=libreriscv.git;a=commitdiff_plain;h=4d18e21e288680ce2bdcf52ee27978d5cb1afee8 add strncpy TODO background --- diff --git a/conferences/fosdem2024/fosdem2024_ddffirst/fosdem2024_ddffirst.tex b/conferences/fosdem2024/fosdem2024_ddffirst/fosdem2024_ddffirst.tex index edcf5e7a2..c02d755c2 100644 --- a/conferences/fosdem2024/fosdem2024_ddffirst/fosdem2024_ddffirst.tex +++ b/conferences/fosdem2024/fosdem2024_ddffirst/fosdem2024_ddffirst.tex @@ -165,7 +165,14 @@ for (i = 0; i < VL; i++) \lstinputlisting[language={}]{strncpy.c} \begin{itemize} - \item "TODO + \item two simple-looking for-loops, unfortunately sequentially + data-dependent in the first. + \item Power ISA added a hard-coded variant of this inner + data-dependent capacity into VSX - only for strcpy! + \item even the null-ing part is not straightforward as + it could be mis-aligned compared to the VSX width. + \item end-result is that assembler-optimised strncpy on Power + ISA v3.0 is a whopping 240 instructions. SVP64 is 10 \end{itemize} }