; assembly | /* r2dec pseudo code output */ | /* balber_berutil.t/assume @ 0x476830 */ | #include | ; (fcn) method.BloombergLP::bdldfp::DecimalImpUtil.decompose_int__unsigned_int__int__BloombergLP::bdldfp::DecimalImpUtil_IntelDfp::ValueType32_ () | int64_t method_BloombergLP::bdldfp::DecimalImpUtil_decompose_int_unsigned_int_int_BloombergLP::bdldfp::DecimalImpUtil_IntelDfp::ValueType32_ (int64_t arg4, int64_t arg3, int64_t arg2, int64_t arg1) { | rcx = arg4; | rdx = arg3; | rsi = arg2; | rdi = arg1; | /* BloombergLP::bdldfp::DecimalImpUtil::decompose(int*, unsigned int*, int*, BloombergLP::bdldfp::DecimalImpUtil_IntelDfp::ValueType32) */ 0x00476830 push rbp | 0x00476831 push r15 | 0x00476833 push r14 | 0x00476835 push rbx | 0x00476836 push rax | 0x00476837 mov ebp, ecx | 0x00476839 mov r14, rdx | r14 = rdx; 0x0047683c mov r15, rsi | r15 = rsi; 0x0047683f mov rbx, rdi | rbx = rdi; 0x00476842 mov edi, ecx | edi = ecx; 0x00476844 call 0x4851a0 | _bid32_class (); 0x00476849 cdqe | rax = (int64_t) eax; 0x0047684b mov eax, dword [rax*4 + 0x50a110] | eax = *((rax*4 + 0x50a110)); 0x00476852 mov ecx, ebp | ecx = ebp; 0x00476854 sar ecx, 0x1f | ecx >>= 0x1f; 0x00476857 or ecx, 1 | ecx |= 1; 0x0047685a mov dword [rbx], ecx | *(rbx) = ecx; 0x0047685c mov ecx, ebp | ecx = ebp; 0x0047685e and ecx, 0x60000000 | ecx &= 0x60000000; 0x00476864 cmp ecx, 0x60000000 | | if (ecx == 0x60000000) { 0x0047686a jne 0x47689c | 0x0047686c mov edx, ebp | edx = ebp; 0x0047686e and edx, 0x78000000 | edx &= 0x78000000; 0x00476874 mov ecx, ebp | ecx = ebp; 0x00476876 and ecx, 0x1fffff | ecx &= 0x1fffff; 0x0047687c or ecx, 0x800000 | ecx |= 0x800000; 0x00476882 shr ebp, 0x15 | ebp >>= 0x15; 0x00476885 mov dword [r15], ecx | *(r15) = ecx; 0x00476888 movzx ecx, bpl | ecx = (int32_t) bpl; 0x0047688c cmp edx, 0x78000000 | | if (edx != 0x78000000) { 0x00476892 je 0x476897 | 0x00476894 add ecx, 0xffffff9b | ecx += 0xffffff9b; | } 0x00476897 mov dword [r14], ecx | *(r14) = ecx; 0x0047689a jmp 0x4768b3 | | } else { 0x0047689c mov ecx, ebp | ecx = ebp; 0x0047689e shr ecx, 0x17 | ecx >>= 0x17; 0x004768a1 movzx ecx, cl | ecx = (int32_t) cl; 0x004768a4 add ecx, 0xffffff9b | ecx += 0xffffff9b; 0x004768a7 mov dword [r14], ecx | *(r14) = ecx; 0x004768aa and ebp, 0x7fffff | ebp &= 0x7fffff; 0x004768b0 mov dword [r15], ebp | *(r15) = ebp; | } 0x004768b3 add rsp, 8 | 0x004768b7 pop rbx | 0x004768b8 pop r14 | 0x004768ba pop r15 | 0x004768bc pop rbp | 0x004768bd ret | return rax; | }