You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Looking at a compilation of 'test/behavior/x86_64/unary.zig' in
callgrind showed that a full 30% of the compiler runtime was spent in
this `stringToEnum` call. Replace it with some nested `switch`
statements using `inline else` to generate the cases at comptime. There
are a lot, but most of them end up falling through to the runtime error
case, so the block will get optimized away.
Notably, this commit builds itself faster than the previous commit
builds *it*self, because the performance degradation from the compiler
having to analyze the `inline else` is beaten out by the performance
gain from using this faster logic in `Lower`
0 commit comments