HN2
new
|
past
|
comments
|
ask
|
show
|
jobs
|
submit
login
Filligree
on March 11, 2022
|
parent
|
context
|
favorite
| on:
Toward a better list iterator for the Linux kernel
Does Rust apply aliasing optimisations now? Last I heard of that, they kept having to turn it back off because of LLVM bugs concerning aliasing.
pcwalton
on March 11, 2022
|
next
[–]
Rust (and, for that matter, C++ compilers) have always applied optimizations that rely on alias analysis. What I assume this thread is referring to is the noalias LLVM attribute on &mut function parameters. Rust now applies this.
coolreader18
on March 11, 2022
|
prev
|
next
[–]
In any case, it's still UB under the language guidelines, it's just not exploited yet.
oconnor663
on March 11, 2022
|
prev
|
next
[–]
I believe since the last time they were turned on they have stayed on, yes.
kzrdude
on March 16, 2022
|
prev
[–]
Rust does not use type-based alias analysis (the "strict aliasing" problem), however.
Guidelines
|
FAQ
|
Lists
|
API
|
Security
|
Legal
|
Apply to YC
|
Contact
Search: