Merge 2 32-bits register-based local variables into a single 64-bits one

Hello there!

What is the (simplest) way in the Hex-Rays decompiler to “merge” 2 separate 32-bits register-based local variables into a single 64bits one. Example:

int v37; // r5
int v38; // r9
...
v37 = array[0];
v38 = array[1];
...
function(__SPAIR64__(v38, v37))

How do I create a single __int64 variable whose location is r9:r5 ?

Thanks for your insights!

1 Like

Currently it’s not possible to create manual pairs of non-adjacent registers. In most cases the decompiler should detect when two registers are used for a larger variable. It’s hard to say why it doesn’t happen here without having the binary, but possibly changing the array to contain 64-bit items would help.