3 ms·
Rust's problem with aliasing in LLVM is caused exactly by limited usefulness of C's restrict. LLVM implements only coarse per-function aliasing information nee
by pornel 6y ago
Rust's problem with aliasing in LLVM is caused exactly by limited usefulness of C's restrict.
LLVM implements only coarse per-function aliasing information needed by C, and doesn't properly preserve fine-grained aliasing information that Rust can provide.
- zucker42 6y agoI thought the problem was there is simply a bug in the implementation because restrict isn't used frequently enough to have exposed the bug earlier.
- jcranmer 6y agoNote that Rust's issue was that LLVM is buggy with restrict (because it isn't exercised frequently). That said, there is a series of patches in-flight to get actual working full restrict support: https://reviews.llvm.org/D69542 https://reviews.llvm.org/D69542