; assembly | /* r2dec pseudo code output */ | /* bdlc_flathashset.t/none @ 0x44ed40 */ | #include | | uint32_t rotate_left32 (uint32_t value, uint32_t count) { | const uint32_t mask = (CHAR_BIT * sizeof (value)) - 1; | count &= mask; | return (value << count) | (value >> (-count & mask)); | } | ; (fcn) method.BloombergLP::bdlc::FlatHashTable_int__int__BloombergLP::bdlc::FlatHashSet_EntryUtil_int___SeedIsHash_int___bsl::equal_to_int___.rehashRaw_unsigned_long_ () | uint64_t method_BloombergLP::bdlc::FlatHashTable_int_int_BloombergLP::bdlc::FlatHashSet_EntryUtil_int_SeedIsHash_int_bsl::equal_to_int_rehashRaw_unsigned_long_ (int64_t arg2, void ** s) { | int64_t var_8h; | int64_t var_10h; | rsi = arg2; | rdi = s; | /* BloombergLP::bdlc::FlatHashTable, SeedIsHash, bsl::equal_to >::rehashRaw(unsigned long) */ 0x0044ed40 push rbp | 0x0044ed41 push r15 | 0x0044ed43 push r14 | 0x0044ed45 push r13 | 0x0044ed47 push r12 | 0x0044ed49 push rbx | 0x0044ed4a sub rsp, 0x18 | 0x0044ed4e mov rbx, rsi | rbx = rsi; 0x0044ed51 mov r15, rdi | r15 = rdi; 0x0044ed54 mov r14, qword [rdi + 0x28] | r14 = *((rdi + 0x28)); 0x0044ed58 mov rdi, qword [rdi + 0x38] | rdi = *((rdi + 0x38)); 0x0044ed5c test rdi, rdi | | if (rdi == 0) { 0x0044ed5f jne 0x44ed75 | 0x0044ed61 mov rdi, qword [rip + 0x253d20] | rdi = BloombergLP::bslma::Default::s_defaultAllocator; 0x0044ed68 test rdi, rdi | | if (rdi != 0) { 0x0044ed6b jne 0x44ed75 | goto label_4; | } 0x0044ed6d call 0x457f90 | rax = BloombergLP::bslma::Default::determineAndReturnDefaultAllocator() (); 0x0044ed72 mov rdi, rax | rdi = rax; | } | label_4: 0x0044ed75 test rbx, rbx | 0x0044ed78 mov qword [rsp], rdi | *(rsp) = rdi; | if (rbx != 0) { 0x0044ed7c je 0x44ee07 | 0x0044ed82 mov r13d, 0x20 | r13d = 0x20; 0x0044ed88 cmp rbx, 0x21 | | if (rbx >= 0x21) { 0x0044ed8c jb 0x44edb3 | 0x0044ed8e dec rbx | rbx--; 0x0044ed91 or rbx, 1 | rbx |= 1; 0x0044ed95 bsr rax, rbx | __asm ("bsr rax, rbx"); 0x0044ed99 xor rax, 0x3f | rax ^= 0x3f; 0x0044ed9d mov ecx, eax | ecx = eax; 0x0044ed9f neg cl | cl = -cl; 0x0044eda1 mov r13d, 1 | r13d = 1; 0x0044eda7 shl r13, cl | r13 <<= cl; 0x0044edaa test rax, rax | | if (rax == 0) { 0x0044edad je 0x44ef50 | goto label_5; | } | } | label_3: 0x0044edb3 lea rsi, [r13*4] | rsi = r13*4; 0x0044edbb mov rax, qword [rdi] | rax = *(rdi); 0x0044edbe mov rbx, rdi | rbx = rdi; 0x0044edc1 call qword [rax + 0x10] | rax = uint64_t (*rax + 0x10)() (); 0x0044edc4 mov r12, rax | r12 = rax; 0x0044edc7 mov rax, qword [rbx] | rax = *(rbx); 0x0044edca mov rdi, rbx | rdi = rbx; 0x0044edcd mov rsi, r13 | rsi = r13; 0x0044edd0 call qword [rax + 0x10] | rax = uint64_t (*rax + 0x10)() (); 0x0044edd3 mov rbx, rax | rbx = rax; 0x0044edd6 mov rax, r13 | rax = r13; 0x0044edd9 shr rax, 4 | rax >>= 4; 0x0044eddd dec rax | rax--; 0x0044ede0 mov rcx, rax | rcx = rax; 0x0044ede3 or rcx, 1 | rcx |= 1; 0x0044ede7 bsr rbp, rcx | __asm ("bsr rbp, rcx"); 0x0044edeb xor ebp, 0x3f | ebp ^= 0x3f; 0x0044edee cmp rax, 1 | 0x0044edf2 adc ebp, 0 | ebp += 0; 0x0044edf5 mov rdi, rbx | 0x0044edf8 mov esi, 0x80 | 0x0044edfd mov rdx, r13 | 0x0044ee00 call 0x403820 | memset (rbx, 0x80, r13); 0x0044ee05 jmp 0x44ee11 | | } else { 0x0044ee07 xor ebp, ebp | ebp = 0; 0x0044ee09 xor r13d, r13d | r13d = 0; 0x0044ee0c xor ebx, ebx | ebx = 0; 0x0044ee0e xor r12d, r12d | r12d = 0; | } 0x0044ee11 mov rax, qword [r15 + 0x18] | rax = *((r15 + 0x18)); 0x0044ee15 test rax, rax | 0x0044ee18 mov qword [rsp + 8], rbp | *((rsp + 8)) = rbp; | if (rax == 0) { 0x0044ee1d je 0x44ef0c | goto label_6; | } 0x0044ee23 mov r9, r14 | r9 = r14; 0x0044ee26 mov ecx, ebp | ecx = ebp; 0x0044ee28 shr r9, cl | r9 >>= cl; 0x0044ee2b shl r9, 4 | r9 <<= 4; 0x0044ee2f lea rdx, [r13 - 1] | rdx = r13 - 1; 0x0044ee33 and r14b, 0x7f | r14b &= 0x7f; 0x0044ee37 xor esi, esi | esi = 0; 0x0044ee39 xor ebp, ebp | ebp = 0; 0x0044ee3b jmp 0x44ee56 | goto label_7; | label_0: 0x0044ee40 mov rax, qword [r15 + 0x18] | rax = *((r15 + 0x18)); 0x0044ee44 mov rsi, qword [rsp + 0x10] | rsi = *((rsp + 0x10)); | do { 0x0044ee49 add rsi, 0x10 | rsi += 0x10; 0x0044ee4d cmp rsi, rax | | if (rsi >= rax) { 0x0044ee50 jae 0x44ef0e | goto label_8; | } | label_7: 0x0044ee56 mov r10, qword [r15 + 8] | r10 = *((r15 + 8)); 0x0044ee5a movdqu xmm0, xmmword [r10 + rsi] | __asm ("movdqu xmm0, xmmword [r10 + rsi]"); 0x0044ee60 pmovmskb ecx, xmm0 | __asm ("pmovmskb ecx, xmm0"); 0x0044ee64 cmp cx, 0xffff | 0x0044ee68 je 0x44ee49 | | } while (cx == 0xffff); 0x0044ee6a add r10, rsi | r10 += rsi; 0x0044ee6d mov qword [rsp + 0x10], rsi | *((rsp + 0x10)) = rsi; 0x0044ee72 lea r11, [rsi*4] | r11 = rsi*4; 0x0044ee7a add r11, qword [r15] | r11 += *(r15); 0x0044ee7d not ecx | ecx = ~ecx; 0x0044ee7f movzx eax, cx | eax = (int32_t) cx; 0x0044ee82 jmp 0x44eeac | goto label_9; | label_1: 0x0044ee90 xor edi, edi | edi = 0; | label_2: 0x0044ee92 mov esi, dword [r11 + rcx*4] | esi = *((r11 + rcx*4)); 0x0044ee96 mov dword [r12 + rdi*4], esi | *((r12 + rdi*4)) = esi; 0x0044ee9a mov byte [rbx + rdi], r14b | *((rbx + rdi)) = r14b; 0x0044ee9e inc rbp | rbp++; 0x0044eea1 mov esi, 0xfffffffe | esi = 0xfffffffe; 0x0044eea6 rol esi, cl | esi = rotate_left32 (esi, cl); 0x0044eea8 and eax, esi | eax &= esi; | if (eax == 0) { 0x0044eeaa je 0x44ee40 | goto label_0; | } | label_9: 0x0044eeac bsf ecx, eax | __asm ("bsf ecx, eax"); 0x0044eeaf mov byte [r10 + rcx], 0xc0 | *((r10 + rcx)) = 0xc0; 0x0044eeb4 dec qword [r15 + 0x10] | *((r15 + 0x10))--; 0x0044eeb8 test r13, r13 | | if (r13 == 0) { 0x0044eebb je 0x44ee90 | goto label_1; | } 0x0044eebd mov rdi, r9 | rdi = r9; 0x0044eec0 xor esi, esi | esi = 0; 0x0044eec2 nop word cs:[rax + rax] | 0x0044eecc nop dword [rax] | | do { 0x0044eed0 movdqu xmm0, xmmword [rbx + rdi] | __asm ("movdqu xmm0, xmmword [rbx + rdi]"); 0x0044eed5 pmovmskb r8d, xmm0 | __asm ("pmovmskb r8d, xmm0"); 0x0044eeda test r8w, r8w | | if (r8w != 0) { 0x0044eede jne 0x44ef00 | goto label_10; | } 0x0044eee0 add rdi, 0x10 | rdi += 0x10; 0x0044eee4 and rdi, rdx | rdi &= rdx; 0x0044eee7 add rsi, 0x10 | rsi += 0x10; 0x0044eeeb cmp rsi, r13 | 0x0044eeee jb 0x44eed0 | | } while (rsi < r13); 0x0044eef0 mov rdi, r13 | rdi = r13; 0x0044eef3 jmp 0x44ee92 | goto label_2; | label_10: 0x0044ef00 movzx esi, r8w | esi = (int32_t) r8w; 0x0044ef04 bsf esi, esi | __asm ("bsf esi, esi"); 0x0044ef07 add rdi, rsi | rdi += rsi; 0x0044ef0a jmp 0x44ee92 | goto label_2; | label_6: 0x0044ef0c xor ebp, ebp | ebp = 0; | label_8: 0x0044ef0e mov rsi, qword [r15] | rsi = *(r15); 0x0044ef11 mov rdi, qword [r15 + 0x38] | rdi = *((r15 + 0x38)); 0x0044ef15 mov rax, qword [rdi] | rax = *(rdi); 0x0044ef18 call qword [rax + 0x18] | uint64_t (*rax + 0x18)() (); 0x0044ef1b mov rsi, qword [r15 + 8] | rsi = *((r15 + 8)); 0x0044ef1f mov rdi, qword [r15 + 0x38] | rdi = *((r15 + 0x38)); 0x0044ef23 mov rax, qword [rdi] | rax = *(rdi); 0x0044ef26 call qword [rax + 0x18] | uint64_t (*rax + 0x18)() (); 0x0044ef29 mov qword [r15], r12 | *(r15) = r12; 0x0044ef2c mov qword [r15 + 8], rbx | *((r15 + 8)) = rbx; 0x0044ef30 mov qword [r15 + 0x10], rbp | *((r15 + 0x10)) = rbp; 0x0044ef34 mov qword [r15 + 0x18], r13 | *((r15 + 0x18)) = r13; 0x0044ef38 mov rax, qword [rsp + 8] | rax = *((rsp + 8)); 0x0044ef3d mov dword [r15 + 0x20], eax | *((r15 + 0x20)) = eax; 0x0044ef41 add rsp, 0x18 | 0x0044ef45 pop rbx | 0x0044ef46 pop r12 | 0x0044ef48 pop r13 | 0x0044ef4a pop r14 | 0x0044ef4c pop r15 | 0x0044ef4e pop rbp | 0x0044ef4f ret | return rax; | label_5: 0x0044ef50 xor r13d, r13d | r13d = 0; 0x0044ef53 jmp 0x44edb3 | goto label_3; | }