I have decompiled some .elf file with IDA's hex rays, what it gave me:
signed int __fastcall SEC_calc_(unsigned int a1, unsigned int a2, _DWORD *a3)
{
char v30;
v3 = a1;
v4 = a2;
v6 = &v30;
int v7;
unsigned int v9;
unsigned int v8;
v7 = 0;
do
{
v8 = v4 >> v7;
v9 = v3 >> v7;
v7 += 8;
*v6 = v8;
(v6++)[4] = v9;
}
while ( v7 != 32 );
Assume that
a1 = 0xC9A6010C
a2 = 0xF1FFDFEF
I can understand that it's shifting the bits to the right and increasing the shifting value by 8 every loop until v7=32 (means only 4 loops). But what is
*v6 = v8;
(v6++)[4] = v9;
*v6 = v8 is pointer right? so t means v30 will equal v8 value as well? and I completely don't understand
(v6++)[4] = v9;
why its an increment in the [4] array? And why it is signed with v9?