; assembly | /* r2dec pseudo code output */ | /* bdlc_compactedarray.t/assume @ 0x430370 */ | #include | ; (fcn) method.BloombergLP::bdlc::CompactedArray_bsl::basic_string_char__std::__1::char_traits_char___bsl::allocator_char_____.insert_unsigned_long__BloombergLP::bdlc::CompactedArray_bsl::basic_string_char__std::__1::char_traits_char___bsl::allocator_char______c () | int64_t method_BloombergLP::bdlc::CompactedArray_bsl::basic_string_char_std::_1::char_traits_char_bsl::allocator_char_insert_unsigned_long_BloombergLP::bdlc::CompactedArray_bsl::basic_string_char_std::_1::char_traits_char_bsl::allocator_char_c (int64_t arg5, int64_t arg4, int64_t arg3, int64_t arg2, uint32_t arg1) { | int64_t var_8h; | int64_t var_10h; | r8 = arg5; | rcx = arg4; | rdx = arg3; | rsi = arg2; | rdi = arg1; | /* BloombergLP::bdlc::CompactedArray, bsl::allocator > >::insert(unsigned long, BloombergLP::bdlc::CompactedArray, bsl::allocator > > const&, unsigned long, unsigned long) */ 0x00430370 push rbp | 0x00430371 push r15 | 0x00430373 push r14 | 0x00430375 push r13 | 0x00430377 push r12 | 0x00430379 push rbx | 0x0043037a sub rsp, 0x18 | 0x0043037e mov r13, r8 | r13 = r8; 0x00430381 mov r12, rcx | r12 = rcx; 0x00430384 mov r14, rdx | r14 = rdx; 0x00430387 mov rbx, rsi | rbx = rsi; 0x0043038a cmp rdx, rdi | | if (rdx == rdi) { 0x0043038d je 0x43045c | goto label_0; | } 0x00430393 mov rcx, rdi | rcx = rdi; 0x00430396 mov qword [rsp + 0x10], r14 | *((rsp + 0x10)) = r14; 0x0043039b mov r14, qword [rdi + 0x28] | r14 = *((rdi + 0x28)); 0x0043039f add r14, r13 | r14 += r13; 0x004303a2 mov rax, qword [rdi + 8] | rax = *((rdi + 8)); 0x004303a6 sub rax, qword [rdi] | rax -= *(rdi); 0x004303a9 sar rax, 3 | rax >>= 3; 0x004303ad movabs rdi, 0x6db6db6db6db6db7 | rdi = 0x6db6db6db6db6db7; 0x004303b7 imul rdi, rax | rdi *= rax; 0x004303bb add rdi, r13 | rdi += r13; 0x004303be mov qword [rsp + 8], rcx | *((rsp + 8)) = rcx; 0x004303c3 mov ebp, dword [rcx + 0x30] | ebp = *((rcx + 0x30)); 0x004303c6 call 0x434590 | eax = BloombergLP::bdlc::PackedIntArrayImp_Unsigned::requiredBytesPerElement(unsigned long) (rdi); 0x004303cb mov rcx, qword [rsp + 8] | rcx = *((rsp + 8)); 0x004303d0 lea r15, [rcx + 0x20] | r15 = rcx + 0x20; 0x004303d4 cmp eax, ebp | | if (eax > ebp) { 0x004303d6 cmovg ebp, eax | | } 0x004303d9 movsxd rax, ebp | rax = (int64_t) ebp; 0x004303dc imul r14, rax | r14 *= rax; 0x004303e0 cmp r14, qword [rcx + 0x38] | | if (r14 > *((rcx + 0x38))) { 0x004303e4 jbe 0x4303f1 | 0x004303e6 mov rdi, r15 | 0x004303e9 mov rsi, r14 | 0x004303ec call 0x439a40 | BloombergLP::bdlc::PackedIntArrayImp::reserveCapacityImp(unsigned long) (r15, r14); | } 0x004303f1 test r13, r13 | 0x004303f4 mov rbp, qword [rsp + 8] | rbp = *((rsp + 8)); | if (r13 == 0) { 0x004303f9 je 0x43044d | goto label_1; | } 0x004303fb mov rax, qword [rsp + 0x10] | rax = *((rsp + 0x10)); 0x00430400 lea r14, [rax + 0x20] | r14 = rax + 0x20; 0x00430404 nop word cs:[rax + rax] | 0x0043040e nop | | do { 0x00430410 mov rdi, r14 | 0x00430413 mov rsi, r12 | rsi = r12; 0x00430416 call 0x43aae0 | rax = BloombergLP::bdlc::PackedIntArrayImp::operator [] (unsigned long)const (r14); 0x0043041b imul rsi, rax, 0x38 | rsi = rax * 0x38; 0x0043041f mov rax, qword [rsp + 0x10] | rax = *((rsp + 0x10)); 0x00430424 add rsi, qword [rax] | rsi += *(rax); 0x00430427 mov edx, 1 | 0x0043042c mov rdi, rbp | 0x0043042f call 0x4317b0 | rax = BloombergLP::bdlc::CompactedArray,bsl::allocator>>::increment(bsl::basic_string,bsl::allocator>const&,unsigned long) (rbp, rsi, 1); 0x00430434 mov rdi, r15 | 0x00430437 mov rsi, rbx | 0x0043043a mov rdx, rax | 0x0043043d call 0x439d60 | BloombergLP::bdlc::PackedIntArrayImp::insert(unsigned long,unsigned long) (r15, rbx, rax, rcx, r8); 0x00430442 inc r12 | r12++; 0x00430445 inc rbx | rbx++; 0x00430448 dec r13 | r13--; 0x0043044b jne 0x430410 | | } while (r13 != 0); | label_1: 0x0043044d add rsp, 0x18 | 0x00430451 pop rbx | 0x00430452 pop r12 | 0x00430454 pop r13 | 0x00430456 pop r14 | 0x00430458 pop r15 | 0x0043045a pop rbp | 0x0043045b ret | return rax; | label_0: 0x0043045c lea rdi, [r14 + 0x20] | 0x00430460 mov rsi, qword [r14 + 0x28] | 0x00430464 add rsi, r13 | rsi += r13; 0x00430467 shl rsi, 3 | rsi <<= 3; 0x0043046b mov qword [rsp + 0x10], rdi | *((rsp + 0x10)) = rdi; 0x00430470 call 0x439a40 | BloombergLP::bdlc::PackedIntArrayImp::reserveCapacityImp(unsigned long) (r14 + 0x20, *((r14 + 0x28))); 0x00430475 test r13, r13 | | if (r13 == 0) { 0x00430478 je 0x4304a1 | goto label_2; | } 0x0043047a mov rbp, r12 | 0x0043047d mov r15, r13 | r15 = r13; | do { 0x00430480 mov rdi, qword [rsp + 0x10] | 0x00430485 mov rsi, rbp | rsi = rbp; 0x00430488 call 0x43aae0 | rax = BloombergLP::bdlc::PackedIntArrayImp::operator [] (unsigned long)const (*((rsp + 0x10))); 0x0043048d mov rcx, qword [r14] | rcx = *(r14); 0x00430490 imul rax, rax, 0x38 | rax *= 0x38; 0x00430494 inc qword [rcx + rax + 0x30] | *((rcx + rax + 0x30))++; 0x00430499 inc rbp | rbp++; 0x0043049c dec r15 | r15--; 0x0043049f jne 0x430480 | | } while (r15 != 0); | label_2: 0x004304a1 mov rdi, qword [rsp + 0x10] | rdi = *((rsp + 0x10)); 0x004304a6 mov rsi, rbx | rsi = rbx; 0x004304a9 mov rdx, rdi | rdx = rdi; 0x004304ac mov rcx, r12 | rcx = r12; 0x004304af mov r8, r13 | r8 = r13; 0x004304b2 add rsp, 0x18 | 0x004304b6 pop rbx | 0x004304b7 pop r12 | 0x004304b9 pop r13 | 0x004304bb pop r14 | 0x004304bd pop r15 | 0x004304bf pop rbp | 0x004304c0 jmp 0x439f90 | return void (*0x439f90)() (); | }