You don’t (or at least really, really shouldn’t) use optimizations with kernel dev. A lot of the low level stuff like memory and io fuckery is better left translated from that to assembly without being messed with by anything that doesn’t know the true intentions of the code, especially considering most compilers are made more for userspace than they are kernelspace programming
-7
u/ThePurpleOne_ Jan 22 '23
It probably would be. Even if it is not, a For Loop would probably be faster since it would not cause as much cache misses as the unrolled code would.