I think the design of alias in Zig hasn’t been fully finalized yet, which is why the related keyword lacks documentation.
The impact of noalias is reflected in @memcpy and @memmove. The former prohibits overlapping memory copies, allowing for better performance, while the latter allows overlapping memory copies, resulting in worse performance.
Languages like C have rules such as ‘strict aliasing,’ which assume that two pointers of ‘non-compatible types’ do not point to overlapping memory. This is a very controversial feature, and at least Linus does not agree with it.
As far as I know, Zig should also not adhere to strict aliasing rules, but perhaps this means that passing any two pointers, regardless of whether they are of the same type, could potentially be optimized further by specifying noalias.
In addition, when using LLVM’s backend, it still seems to try to make some strict aliasing assumptions, which leads to unexpected results.