|
|
|
|
|
by mhh__
1558 days ago
|
|
Even ignoring the usual optimizations like using SIMD and loop unrolling to find parallelism when doing memcpy, the compiler actually has techniques for spotting certain loop idioms so it can actually replace the loop with a memcpy library call if it deems it profitable (e.g. tell it it's likely to have N>bigNumber and it'll go for a library) |
|
https://godbolt.org/z/dvdzE4M6T