From 4d18e21e288680ce2bdcf52ee27978d5cb1afee8 Mon Sep 17 00:00:00 2001 From: Luke Kenneth Casson Leighton Date: Sun, 11 Feb 2024 15:26:07 +0000 Subject: [PATCH] add strncpy TODO background --- .../fosdem2024_ddffirst/fosdem2024_ddffirst.tex | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) 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} } -- 2.30.2