mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-01-10 16:19:28 +01:00
49a4e09719
- LEA is a bit silly when the source and the destination are the same. A simple ADD or SHL will do in those cases. 66 8D 04 45 00 00 00 00 lea ax,[rax*2] 66 03 C0 add ax,ax 48 8D 04 00 lea rax,[rax+rax] 48 03 C0 add rax,rax 66 8D 14 D5 00 00 00 00 lea dx,[rdx*8] 66 C1 E2 03 shl dx,3 - When scaling by 2, consider summing the register with itself instead. The former always needs a 32-bit displacement, so the sum is more compact. 66 8D 14 45 00 00 00 00 lea dx,[rax*2] 66 8D 14 00 lea dx,[rax+rax]