; assembly | /* r2dec pseudo code output */ | /* balber_berdecoder.t/assume @ 0x442340 */ | #include | ; (fcn) method.int_BloombergLP::balber::BerEncoder.encode_unsigned_int__std::__1::basic_streambuf_char__std::__1::char_traits_char_____unsigned_int_const_ () | int64_t method_int_BloombergLP::balber::BerEncoder_encode_unsigned_int_std::_1::basic_streambuf_char_std::_1::char_traits_char_unsigned_int_const_ (int64_t arg3, int64_t arg2, int64_t arg1) { | rdx = arg3; | rsi = arg2; | rdi = arg1; | /* int BloombergLP::balber::BerEncoder::encode(std::__1::basic_streambuf >*, unsigned int const&) */ 0x00442340 push rbp | 0x00442341 push r15 | 0x00442343 push r14 | 0x00442345 push r12 | 0x00442347 push rbx | 0x00442348 sub rsp, 0x10 | 0x0044234c mov r12, rdx | r12 = rdx; 0x0044234f mov r14, rsi | r14 = rsi; 0x00442352 mov rbx, rdi | rbx = rdi; 0x00442355 mov qword [rdi + 0x108], rsi | *((rdi + 0x108)) = rsi; 0x0044235c mov dword [rdi + 0x100], 0 | *((rdi + 0x100)) = 0; 0x00442366 mov rbp, qword [rdi + 0xf8] | rbp = *((rdi + 0xf8)); 0x0044236d test rbp, rbp | | if (rbp != 0) { 0x00442370 je 0x44238f | 0x00442372 mov rsi, qword [rbp + 0x30] | rsi = *((rbp + 0x30)); 0x00442376 mov rdi, qword [rbp + 0x48] | rdi = *((rbp + 0x48)); 0x0044237a mov rax, qword [rdi] | rax = *(rdi); 0x0044237d call qword [rax + 0x18] | uint64_t (*rax + 0x18)() (); 0x00442380 xorps xmm0, xmm0 | __asm ("xorps xmm0, xmm0"); 0x00442383 movups xmmword [rbp + 0x30], xmm0 | __asm ("movups xmmword [rbp + 0x30], xmm0"); 0x00442387 mov qword [rbp + 0x40], 0 | *((rbp + 0x40)) = 0; | } 0x0044238f mov dword [rbx + 0x110], 0 | *((rbx + 0x110)) = 0; 0x00442399 cmp qword [rbx], 0 | | if (*(rbx) != 0) { 0x0044239d je 0x4423ea | 0x0044239f mov dword [rbx + 0x110], 1 | *((rbx + 0x110)) = 1; 0x004423a9 xor r15d, r15d | r15d = 0; 0x004423ac mov rdi, rbx | 0x004423af mov rsi, r12 | 0x004423b2 xor edx, edx | 0x004423b4 mov ecx, 2 | 0x004423b9 xor r8d, r8d | r8d = 0; 0x004423bc call 0x44d7e0 | eax = intBloombergLP::balber::BerEncoder::encodeImpl(unsignedintconst&,BloombergLP::balber::BerConstants::TagClass,int,int,BloombergLP::bdlat_TypeCategory::Simple) (rbx, r12, 0, 2); 0x004423c1 test eax, eax | | if (eax != 0) { 0x004423c3 je 0x4423e2 | 0x004423c5 mov r15d, 0xffffffff | r15d = 0xffffffff; 0x004423cb mov rdi, rbx | 0x004423ce xor esi, esi | 0x004423d0 mov edx, 2 | 0x004423d5 xor ecx, ecx | 0x004423d7 mov r8d, 0xffffffff | 0x004423dd call 0x452720 | BloombergLP::balber::BerEncoder::logError(BloombergLP::balber::BerConstants::TagClass,int,char const*,int) (rbx, 0, 2, 0, 0xffffffff); | } 0x004423e2 dec dword [rbx + 0x110] | *((rbx + 0x110))--; 0x004423e8 jmp 0x44244c | | } else { 0x004423ea mov r15, rsp | r15 = rsp; 0x004423ed mov rdi, r15 | rdi = rsp; 0x004423f0 call 0x453260 | BloombergLP::balber::BerEncoderOptions::BerEncoderOptions() (); 0x004423f5 mov qword [rbx], r15 | *(rbx) = r15; 0x004423f8 inc dword [rbx + 0x110] | *((rbx + 0x110))++; 0x004423fe xor r15d, r15d | r15d = 0; 0x00442401 mov rdi, rbx | 0x00442404 mov rsi, r12 | 0x00442407 xor edx, edx | 0x00442409 mov ecx, 2 | 0x0044240e xor r8d, r8d | r8d = 0; 0x00442411 call 0x44d7e0 | eax = intBloombergLP::balber::BerEncoder::encodeImpl(unsignedintconst&,BloombergLP::balber::BerConstants::TagClass,int,int,BloombergLP::bdlat_TypeCategory::Simple) (rbx, r12, 0, 2); 0x00442416 test eax, eax | | if (eax != 0) { 0x00442418 je 0x442437 | 0x0044241a mov r15d, 0xffffffff | r15d = 0xffffffff; 0x00442420 mov rdi, rbx | 0x00442423 xor esi, esi | 0x00442425 mov edx, 2 | 0x0044242a xor ecx, ecx | 0x0044242c mov r8d, 0xffffffff | 0x00442432 call 0x452720 | BloombergLP::balber::BerEncoder::logError(BloombergLP::balber::BerConstants::TagClass,int,char const*,int) (rbx, 0, 2, 0, 0xffffffff); | } 0x00442437 mov qword [rbx], 0 | *(rbx) = 0; 0x0044243e dec dword [rbx + 0x110] | *((rbx + 0x110))--; 0x00442444 mov rdi, rsp | rdi = rsp; 0x00442447 call 0x4532b0 | BloombergLP::balber::BerEncoderOptions::~BerEncoderOptions() (); | } 0x0044244c mov qword [rbx + 0x108], 0 | *((rbx + 0x108)) = 0; 0x00442457 mov rax, qword [r14] | rax = *(r14); 0x0044245a mov rdi, r14 | rdi = r14; 0x0044245d call qword [rax + 0x30] | uint64_t (*rax + 0x30)() (); 0x00442460 mov eax, r15d | eax = r15d; 0x00442463 add rsp, 0x10 | 0x00442467 pop rbx | 0x00442468 pop r12 | 0x0044246a pop r14 | 0x0044246c pop r15 | 0x0044246e pop rbp | 0x0044246f ret | return rax; | }