; assembly | /* r2dec pseudo code output */ | /* bdlt_fixutil.t/assume @ 0x43bcb0 */ | #include | ; (fcn) sym._anonymous_namespace_::u::parseTime_char_const__BloombergLP::bdlt::Time__int__bool__char_const__char_const_ () | int64_t anonymous_namespace_::u::parseTime_char_const_BloombergLP::bdlt::Time_int_bool_char_const_char_const_ (uint32_t arg6, int64_t arg5, int64_t arg4, int64_t arg3, int64_t arg2, int64_t arg1) { | uint32_t var_8h; | int64_t var_14h; | int64_t var_18h; | int64_t var_20h; | int64_t var_28h; | int64_t var_30h; | int64_t var_34h; | uint32_t var_38h; | int64_t var_40h; | r9 = arg6; | r8 = arg5; | rcx = arg4; | rdx = arg3; | rsi = arg2; | rdi = arg1; | /* (anonymous namespace)::u::parseTime(char const**, BloombergLP::bdlt::Time*, int*, bool*, char const*, char const*) */ 0x0043bcb0 push rbp | 0x0043bcb1 push r15 | 0x0043bcb3 push r14 | 0x0043bcb5 push r13 | 0x0043bcb7 push r12 | 0x0043bcb9 push rbx | 0x0043bcba sub rsp, 0x48 | 0x0043bcbe mov qword [rsp], r8 | *(rsp) = r8; 0x0043bcc2 mov rax, r9 | rax = r9; 0x0043bcc5 sub rax, r8 | rax -= r8; 0x0043bcc8 mov r13d, 0xffffffff | r13d = 0xffffffff; 0x0043bcce cmp rax, 5 | | if (rax < 5) { 0x0043bcd2 jl 0x43c032 | goto label_0; | } 0x0043bcd8 mov rbp, r9 | 0x0043bcdb mov r14, r8 | r14 = r8; 0x0043bcde mov r15, rcx | r15 = rcx; 0x0043bce1 mov rbx, rdx | rbx = rdx; 0x0043bce4 mov r12, rsi | r12 = rsi; 0x0043bce7 mov qword [rsp + 0x40], rdi | *((rsp + 0x40)) = rdi; 0x0043bcec call 0x404140 | rax = ctype_b_loc (); 0x0043bcf1 mov rsi, qword [rax] | rsi = *(rax); 0x0043bcf4 movsx rcx, byte [r14] | rcx = *(r14); 0x0043bcf8 test byte [rsi + rcx*2 + 1], 8 | | if ((*((rsi + rcx*2 + 1)) & 8) == 0) { 0x0043bcfd je 0x43c032 | goto label_0; | } 0x0043bd03 movsx rdx, byte [r14 + 1] | rdx = *((r14 + 1)); 0x0043bd08 test byte [rsi + rdx*2 + 1], 8 | | if ((*((rsi + rdx*2 + 1)) & 8) == 0) { 0x0043bd0d je 0x43c032 | goto label_0; | } 0x0043bd13 lea ecx, [rcx + rcx*4] | ecx = rcx * 5; 0x0043bd16 lea esi, [rdx + rcx*2 - 0x210] | esi = rdx + rcx*2 - 0x210; 0x0043bd1d cmp esi, 0x17 | | if (esi > 0x17) { 0x0043bd20 jg 0x43c032 | goto label_0; | } 0x0043bd26 cmp byte [r14 + 2], 0x3a | | if (*((r14 + 2)) != 0x3a) { 0x0043bd2b jne 0x43c032 | goto label_0; | } 0x0043bd31 lea rcx, [r14 + 3] | rcx = r14 + 3; 0x0043bd35 mov qword [rsp], rcx | *(rsp) = rcx; 0x0043bd39 mov rcx, qword [rax] | rcx = *(rax); 0x0043bd3c movsx rdi, byte [r14 + 3] | rdi = *((r14 + 3)); 0x0043bd41 test byte [rcx + rdi*2 + 1], 8 | | if ((*((rcx + rdi*2 + 1)) & 8) == 0) { 0x0043bd46 je 0x43c032 | goto label_0; | } 0x0043bd4c movsx r10, byte [r14 + 4] | r10 = *((r14 + 4)); 0x0043bd51 test byte [rcx + r10*2 + 1], 8 | | if ((*((rcx + r10*2 + 1)) & 8) == 0) { 0x0043bd57 je 0x43c032 | goto label_0; | } 0x0043bd5d lea rdx, [r14 + 5] | rdx = r14 + 5; 0x0043bd61 mov qword [rsp], rdx | *(rsp) = rdx; 0x0043bd65 xor r8d, r8d | r8d = 0; 0x0043bd68 xor ecx, ecx | ecx = 0; 0x0043bd6a cmp rdx, rbp | | if (rdx >= rbp) { 0x0043bd6d jae 0x43bf0a | goto label_1; | } 0x0043bd73 cmp byte [rdx], 0x3a | 0x0043bd76 mov r9d, 0 | r9d = 0; 0x0043bd7c mov r11d, 0 | r11d = 0; 0x0043bd82 mov dword [rsp + 8], 0 | *((rsp + 8)) = 0; | if (*(rdx) != 0x3a) { 0x0043bd8a jne 0x43bf18 | goto label_2; | } 0x0043bd90 lea rcx, [r14 + 6] | rcx = r14 + 6; 0x0043bd94 mov qword [rsp], rcx | *(rsp) = rcx; 0x0043bd98 mov rdx, rbp | rdx = rbp; 0x0043bd9b sub rdx, rcx | rdx -= rcx; 0x0043bd9e cmp rdx, 2 | | if (rdx < 2) { 0x0043bda2 jl 0x43c032 | goto label_0; | } 0x0043bda8 mov rdx, qword [rax] | rdx = *(rax); 0x0043bdab movsx r9, byte [r14 + 6] | r9 = *((r14 + 6)); 0x0043bdb0 test byte [rdx + r9*2 + 1], 8 | | if ((*((rdx + r9*2 + 1)) & 8) == 0) { 0x0043bdb6 je 0x43c032 | goto label_0; | } 0x0043bdbc movsx rcx, byte [r14 + 7] | rcx = *((r14 + 7)); 0x0043bdc1 test byte [rdx + rcx*2 + 1], 8 | | if ((*((rdx + rcx*2 + 1)) & 8) == 0) { 0x0043bdc6 je 0x43c032 | goto label_0; | } 0x0043bdcc mov qword [rsp + 8], rcx | *((rsp + 8)) = rcx; 0x0043bdd1 lea rdx, [r14 + 8] | rdx = r14 + 8; 0x0043bdd5 mov qword [rsp], rdx | *(rsp) = rdx; 0x0043bdd9 xor ecx, ecx | ecx = 0; 0x0043bddb mov qword [rsp + 0x18], rcx | *((rsp + 0x18)) = rcx; 0x0043bde0 cmp rdx, rbp | | if (rdx >= rbp) { 0x0043bde3 jae 0x43c044 | goto label_3; | } 0x0043bde9 cmp byte [rdx], 0x2e | 0x0043bdec mov r11d, 0 | r11d = 0; | if (*(rdx) != 0x2e) { 0x0043bdf2 jne 0x43c047 | goto label_4; | } 0x0043bdf8 lea rdx, [r14 + 9] | rdx = r14 + 9; 0x0043bdfc mov qword [rsp], rdx | *(rsp) = rdx; 0x0043be00 cmp rdx, rbp | | if (rdx == rbp) { 0x0043be03 je 0x43c032 | goto label_0; | } 0x0043be09 mov qword [rsp + 0x20], r10 | *((rsp + 0x20)) = r10; 0x0043be0e mov qword [rsp + 0x28], rdi | *((rsp + 0x28)) = rdi; 0x0043be13 mov r10d, esi | r10d = esi; 0x0043be16 movsx rsi, byte [rdx] | rsi = *(rdx); 0x0043be1a mov r8, qword [rax] | r8 = *(rax); 0x0043be1d test byte [r8 + rsi*2 + 1], 8 | | if ((*((r8 + rsi*2 + 1)) & 8) == 0) { 0x0043be23 je 0x43c032 | goto label_0; | } 0x0043be29 lea rcx, [r14 + 0x10] | rcx = r14 + 0x10; 0x0043be2d cmp rcx, rbp | | if (rcx >= rbp) { 0x0043be30 cmovae rcx, rbp | rcx = rbp; | } 0x0043be34 add r14, 0xa | r14 += 0xa; 0x0043be38 cmp rcx, r14 | | if (rcx <= r14) { 0x0043be3b cmovbe rcx, r14 | rcx = r14; | } 0x0043be3f mov eax, 0x989680 | eax = 0x989680; 0x0043be44 xor edi, edi | edi = 0; | do { 0x0043be46 mov rdx, r14 | rdx = r14; 0x0043be49 lea edi, [rdi + rdi*4] | edi = rdi * 5; 0x0043be4c movsx esi, sil | esi = (int32_t) sil; 0x0043be50 lea edi, [rsi + rdi*2 - 0x30] | edi = rsi + rdi*2 - 0x30; 0x0043be54 cdqe | rax = (int64_t) eax; 0x0043be56 imul rax, rax, 0x66666667 | rax *= 0x66666667; 0x0043be5d mov rsi, rax | rsi = rax; 0x0043be60 shr rsi, 0x3f | rsi >>= 0x3f; 0x0043be64 sar rax, 0x22 | rax >>= 0x22; 0x0043be68 add eax, esi | eax += esi; 0x0043be6a cmp rcx, r14 | | if (rcx == r14) { 0x0043be6d je 0x43be7f | goto label_5; | } 0x0043be6f movsx rsi, byte [rdx] | rsi = *(rdx); 0x0043be73 lea r14, [rdx + 1] | r14 = rdx + 1; 0x0043be77 test byte [r8 + rsi*2 + 1], 8 | 0x0043be7d jne 0x43be46 | | } while ((*((r8 + rsi*2 + 1)) & 8) != 0); | label_5: 0x0043be7f imul edi, eax | edi *= eax; 0x0043be82 add edi, 5 | edi += 5; 0x0043be85 movsxd rax, edi | rax = (int64_t) edi; 0x0043be88 imul rcx, rax, 0x66666667 | rcx = rax * 0x66666667; 0x0043be8f mov rsi, rcx | rsi = rcx; 0x0043be92 shr rsi, 0x3f | rsi >>= 0x3f; 0x0043be96 sar rcx, 0x22 | rcx >>= 0x22; 0x0043be9a add ecx, esi | ecx += esi; 0x0043be9c cmp rdx, rbp | | if (rdx >= rbp) { 0x0043be9f jae 0x43beb8 | goto label_6; | } | do { 0x0043bea1 movsx rsi, byte [rdx] | rsi = *(rdx); 0x0043bea5 test byte [r8 + rsi*2 + 1], 8 | | if ((*((r8 + rsi*2 + 1)) & 8) == 0) { 0x0043beab je 0x43beb8 | goto label_6; | } 0x0043bead inc rdx | rdx++; 0x0043beb0 cmp rbp, rdx | 0x0043beb3 jne 0x43bea1 | | } while (rbp != rdx); 0x0043beb5 mov rdx, rbp | rdx = rbp; | label_6: 0x0043beb8 mov qword [rsp], rdx | *(rsp) = rdx; 0x0043bebc imul r11, rax, 0x68db8bad | r11 = rax * 0x68db8bad; 0x0043bec3 mov rax, r11 | rax = r11; 0x0043bec6 shr rax, 0x3f | rax >>= 0x3f; 0x0043beca sar r11, 0x2c | r11 >>= 0x2c; 0x0043bece add r11d, eax | r11d += eax; 0x0043bed1 movsxd rcx, ecx | rcx = (int64_t) ecx; 0x0043bed4 imul rax, rcx, 0x10624dd3 | rax = rcx * 0x10624dd3; 0x0043bedb mov rsi, rax | rsi = rax; 0x0043bede shr rsi, 0x3f | rsi >>= 0x3f; 0x0043bee2 sar rax, 0x26 | rax >>= 0x26; 0x0043bee6 add eax, esi | eax += esi; 0x0043bee8 imul eax, eax, 0x3e8 | eax *= 0x3e8; 0x0043beee sub ecx, eax | ecx -= eax; 0x0043bef0 mov qword [rsp + 0x18], rcx | *((rsp + 0x18)) = rcx; 0x0043bef5 mov esi, r10d | esi = r10d; 0x0043bef8 xor r8d, r8d | r8d = 0; 0x0043befb mov rdi, qword [rsp + 0x28] | rdi = *((rsp + 0x28)); 0x0043bf00 mov r10, qword [rsp + 0x20] | r10 = *((rsp + 0x20)); 0x0043bf05 jmp 0x43c047 | goto label_4; | label_1: 0x0043bf0a xor r9d, r9d | r9d = 0; 0x0043bf0d xor r11d, r11d | r11d = 0; 0x0043bf10 mov dword [rsp + 8], 0 | *((rsp + 8)) = 0; | do { | label_2: 0x0043bf18 cmp r11d, 0x3e8 | 0x0043bf1f mov qword [rsp + 0x38], r11 | *((rsp + 0x38)) = r11; | if (r11d != 0x3e8) { 0x0043bf24 cmovne r8d, r11d | r8d = r11d; | } 0x0043bf28 mov dword [rsp + 0x14], 0 | *((rsp + 0x14)) = 0; 0x0043bf30 cmp rdx, rbp | | if (rdx != rbp) { 0x0043bf33 je 0x43bf93 | 0x0043bf35 mov dword [rsp + 0x30], ecx | *((rsp + 0x30)) = ecx; 0x0043bf39 mov qword [rsp + 0x18], r9 | *((rsp + 0x18)) = r9; 0x0043bf3e mov qword [rsp + 0x20], r10 | *((rsp + 0x20)) = r10; 0x0043bf43 mov qword [rsp + 0x28], rdi | *((rsp + 0x28)) = rdi; 0x0043bf48 mov dword [rsp + 0x34], r8d | *((rsp + 0x34)) = r8d; 0x0043bf4d mov r14d, esi | r14d = esi; 0x0043bf50 mov rdi, rsp | rdi = rsp; 0x0043bf53 lea rsi, [rsp + 0x14] | rsi = rsp + 0x14; 0x0043bf58 mov rcx, rbp | rcx = rbp; 0x0043bf5b call 0x43bb00 | eax = (anonymousnamespace)::u::parseTimezoneOffset(char const**,int*,char const*,char const*) (); 0x0043bf60 mov r13d, 0xffffffff | r13d = 0xffffffff; 0x0043bf66 test eax, eax | | if (eax != 0) { 0x0043bf68 jne 0x43c032 | goto label_0; | } 0x0043bf6e cmp qword [rsp], rbp | 0x0043bf72 mov esi, r14d | esi = r14d; 0x0043bf75 mov r8d, dword [rsp + 0x34] | r8d = *((rsp + 0x34)); 0x0043bf7a mov rdi, qword [rsp + 0x28] | rdi = *((rsp + 0x28)); 0x0043bf7f mov r10, qword [rsp + 0x20] | r10 = *((rsp + 0x20)); 0x0043bf84 mov r9, qword [rsp + 0x18] | r9 = *((rsp + 0x18)); 0x0043bf89 mov ecx, dword [rsp + 0x30] | ecx = *((rsp + 0x30)); | if (*(rsp) != rbp) { 0x0043bf8d jne 0x43c032 | goto label_0; | } | } 0x0043bf93 lea eax, [rdi + rdi*4] | eax = rdi * 5; 0x0043bf96 lea edx, [r10 + rax*2 - 0x210] | edx = r10 + rax*2 - 0x210; 0x0043bf9e cmp r9d, 0x3e7 | | if (r9d <= 0x3e7) { 0x0043bfa5 ja 0x43bfbf | 0x0043bfa7 cmp esi, 0x17 | | if (esi > 0x17) { 0x0043bfaa ja 0x43bfbf | goto label_7; | } 0x0043bfac cmp edx, 0x3b | | if (edx > 0x3b) { 0x0043bfaf ja 0x43bfbf | goto label_7; | } 0x0043bfb1 cmp ecx, 0x3b | | if (ecx > 0x3b) { 0x0043bfb4 ja 0x43bfbf | goto label_7; | } 0x0043bfb6 cmp r8d, 0x3e8 | | if (r8d < 0x3e8) { 0x0043bfbd jb 0x43bfd6 | goto label_8; | } | } | label_7: 0x0043bfbf mov r13d, 0xffffffff | r13d = 0xffffffff; 0x0043bfc5 cmp esi, 0x18 | | if (esi == 0x18) { 0x0043bfc8 jne 0x43c032 | 0x0043bfca mov eax, ecx | eax = ecx; 0x0043bfcc or eax, edx | eax |= edx; 0x0043bfce or eax, r9d | eax |= r9d; 0x0043bfd1 or eax, r8d | eax |= r8d; | if (eax != 0) { 0x0043bfd4 jne 0x43c032 | goto label_0; | } | label_8: 0x0043bfd6 mov rdi, r12 | 0x0043bfd9 call 0x43e1b0 | BloombergLP::bdlt::Time::setTime(int,int,int,int,int) (r12, rsi, rdx, rcx, r8, r9); 0x0043bfde mov eax, dword [rsp + 0x14] | eax = *((rsp + 0x14)); 0x0043bfe2 mov dword [rbx], eax | *(rbx) = eax; 0x0043bfe4 mov byte [r15], 0 | *(r15) = 0; 0x0043bfe8 cmp dword [rsp + 0x38], 0x3e8 | | if (*((rsp + 0x38)) == 0x3e8) { 0x0043bff0 jne 0x43c006 | 0x0043bff2 mov rdi, r12 | 0x0043bff5 mov esi, 1 | 0x0043bffa call 0x43d6b0 | eax = BloombergLP::bdlt::Time::addSeconds(int) (r12, 1); 0x0043bfff cmp eax, 1 | 0x0043c002 sete byte [r15] | r15 = (eax == 1) ? 1 : 0; | } 0x0043c006 cmp byte [rsp + 8], 0 | | if (*((rsp + 8)) != 0) { 0x0043c00b je 0x43c023 | 0x0043c00d mov rdi, r12 | 0x0043c010 mov esi, 1 | 0x0043c015 call 0x43d6b0 | eax = BloombergLP::bdlt::Time::addSeconds(int) (r12, 1); 0x0043c01a cmp eax, 1 | | if (eax != 1) { 0x0043c01d jne 0x43c023 | goto label_9; | } 0x0043c01f mov byte [r15], 1 | *(r15) = 1; | } | label_9: 0x0043c023 mov rax, qword [rsp] | rax = *(rsp); 0x0043c027 mov rcx, qword [rsp + 0x40] | rcx = *((rsp + 0x40)); 0x0043c02c mov qword [rcx], rax | *(rcx) = rax; 0x0043c02f xor r13d, r13d | r13d = 0; | } | label_0: 0x0043c032 mov eax, r13d | eax = r13d; 0x0043c035 add rsp, 0x48 | 0x0043c039 pop rbx | 0x0043c03a pop r12 | 0x0043c03c pop r13 | 0x0043c03e pop r14 | 0x0043c040 pop r15 | 0x0043c042 pop rbp | 0x0043c043 ret | return rax; | label_3: 0x0043c044 xor r11d, r11d | r11d = 0; | label_4: 0x0043c047 lea eax, [r9 + r9*4] | eax = r9 * 5; 0x0043c04b mov rcx, qword [rsp + 8] | rcx = *((rsp + 8)); 0x0043c050 lea eax, [rcx + rax*2 - 0x210] | eax = rcx + rax*2 - 0x210; 0x0043c057 cmp eax, 0x3c | 0x0043c05a sete cl | cl = (eax == 0x3c) ? 1 : 0; 0x0043c05d mov dword [rsp + 8], ecx | *((rsp + 8)) = ecx; 0x0043c061 mov ecx, 0x3b | ecx = 0x3b; | if (eax != 0x3c) { 0x0043c066 cmovne ecx, eax | ecx = eax; | } 0x0043c069 mov r9, qword [rsp + 0x18] | r9 = *((rsp + 0x18)); 0x0043c06e jmp 0x43bf18 | | } while (1); | }