dolphin/Source/Core
Sintendo 50f7a7d248 Jit64: addx - Prefer smaller MOV+ADD sequence
ADD has a smaller encoding for immediates that can be expressed as an
8-bit signed integer (in other words, between -128 and 127). MOV lacks
this compact representation.

Since addition allows us to swap the source registers, we can always get
the shortest sequence here by carefully checking if we're dealing with a
small immediate first. If we are, move the other source into the
destination and add the small immediate onto that. For large immediates
the reverse is preferrable.

Before:
41 BE 40 00 00 00    mov         r14d,40h
44 03 75 A8          add         r14d,dword ptr [rbp-58h]

After:
44 8B 75 A8          mov         r14d,dword ptr [rbp-58h]
41 83 C6 40          add         r14d,40h

Before:
44 8B 7D F8          mov         r15d,dword ptr [rbp-8]
41 81 C7 00 68 00 CC add         r15d,0CC006800h

After:
41 BF 00 68 00 CC    mov         r15d,0CC006800h
44 03 7D F8          add         r15d,dword ptr [rbp-8]
2020-04-21 22:42:02 +02:00
..
AudioCommon Use std::istringstream or std::ostringstream instead of std::stringstream where possible. 2019-12-29 23:45:02 -05:00
Common Merge pull request #8680 from Leseratte10/master 2020-03-24 00:21:29 +01:00
Core Jit64: addx - Prefer smaller MOV+ADD sequence 2020-04-21 22:42:02 +02:00
DiscIO DiscIO: cleanup warnings of -Wmaybe-uninitialized 2020-03-23 14:14:00 +08:00
DolphinNoGUI NoGUI: missing override keyword GetWindowSystemInfo 2020-03-23 16:35:45 +08:00
DolphinQt Merge pull request #8340 from stenzek/max-res 2020-04-16 21:01:14 -04:00
InputCommon InputCommon: cleanup warnings of -Wclass-memaccess 2020-03-23 14:26:36 +08:00
MacUpdater
UICommon Cleanup warnings of -Wunused-const-variable 2020-03-23 16:28:25 +08:00
UpdaterCommon Add an ARM64 target to Visual Studio projects 2019-12-28 19:20:41 +10:00
VideoBackends Vulkan: Switch from vkCreateMacOSSurfaceMVK() to vkCreateMetalSurfaceEXT() 2020-04-07 18:56:55 +10:00
VideoCommon Merge pull request #8717 from stenzek/mismatched-xf-bp 2020-04-21 10:07:36 -04:00
WinUpdater Add an ARM64 target to Visual Studio projects 2019-12-28 19:20:41 +10:00
CMakeLists.txt