Earlier quoted context omitted.
I've found the lack of alias guarantees to be far more bark than bite. What's the primary use case? For automatic vectorization? Ultimately the only cost to check is an integer add and an integer comparison. Yeah, aliasing guarantees would eliminate those two ops (and eliminate generating the aliased version's code path). But in general, it isn't some 8x monumental cost that many people think it is.
> What's the primary use case? For automatic vectorization? No. Without aliasing guarantees, every load via a by-ref/by-addr input param after a store via another such param must actually be executed. So either you manually cache your accesses, or you can't do loop unrolling, strength reductions, and possibly other optimization work. > Ultimately the only cost to check is an integer add and an integer comparison 1. M…
> 1. Manually checking that will likely not affect the compiler. Again, you can implement your own optimizations, but that's not what you want to do.
I wasn't implying to do it manually. Compilers do it all the time.
2, I understand and would use. I also want to restrict input alignment.
3, I never knew, but compilers I use for x86 on linux seem to think it's fine to just check memory address distances.