| a9c6c9ef | 18-Apr-2024 |
Jamey Sharp <[email protected]> |
cranelift/aarch64: Simplify generating constants (#8403)
While reviewing #8393 I found the existing `load_constant64_full` function nearly incomprehensible, so I rewrote it. It has many fewer cases
cranelift/aarch64: Simplify generating constants (#8403)
While reviewing #8393 I found the existing `load_constant64_full` function nearly incomprehensible, so I rewrote it. It has many fewer cases now.
I've chosen an implementation which I believe generates exactly the same instructions as the prior implementation in all cases. There are some choices we could make which would synthesize the same constants using a different sequence of instructions, but in almost all cases we'd produce the same number of instructions, so it doesn't make much difference. This algorithm is simple and produces readable disassembly listings so we might as well preserve the existing behavior.
show more ...
|