Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

restrict is so rarely used that optimizations based on non-aliasing data are broken in both major compilers. A fact which has bitten Rust repeatedly.


FWIW the last round was an issue with the interaction between noaliasing and loop unrolling (after inlining) as unrolling would fail to "split" the noalias between unrolled iteration, so it was not the noalias handling which was broken but the loop unrolling pass.

And my understanding's it's since been fixed in GCC.

I don't doubt for a second there will be new miscompilations discovered after that one's fixed though.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: