<div dir="ltr"><div dir="ltr">On Fri, 26 Sept 2025 at 22:27, Adhemerval Zanella Netto <<a href="mailto:adhemerval.zanella@linaro.org">adhemerval.zanella@linaro.org</a>> wrote:</div><div class="gmail_quote gmail_quote_container"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><br><br>
And taking the swap function from user is not necessary the best solution,<br>
for small elements the indirect function will most likely dominate. And <br>
it will require changing the ABI, which will require a new symbol.<br><br></blockquote><div><br></div><div>Actually, we don't know what will be the size of the elements. It may be small and it may be big also.  So, sometimes the swap function will be better and sometimes it will not.</div><div><br></div><div>So, in scenarios where no algorithm offers obvious advantages, I actually choose the algorithm which is simpler to implement and understand. So, I would still take the swap function from the user. The implementation will be very simple and in future if someone else takes charge of the code then he/she won't have to spend a lot of time to understand it.</div><div><br></div><div>----</div><div><br></div></div></div>