@blanchsb the code you are writing controls the ‘multithreadedness’ and speed of the addon.
This is sometimes referred to as code optimization. Used to be super important 😉
Now some people say: ‘ computers are so fast these days, we can afford it to write slow and inefficient code.’ (Last heard this argument yesterday on Blender Today.)
Agner Fog wrote a lot about this (optimizing code) in C++ and Assembly Language (not for beginners!), but a lot of the principles also apply tho other languages…
And here’s a fun little video about branchless programming: https://www.youtube.com/watch?v=bVJ-mWWL7cE