index
int64
0
66.5k
func_name
stringlengths
2
5.36k
func_dep
stringlengths
16
2.19k
func
stringlengths
8
55.3k
test
stringlengths
0
7.07k
opt
stringclasses
4 values
language
stringclasses
2 values
asm
stringlengths
0
45.4k
ida_asm
stringlengths
0
44.7k
ida_pseudo
stringlengths
0
44.3k
ghidra_asm
stringlengths
0
49.1k
ghidra_pseudo
stringlengths
0
64.7k
60,800
aimrt::runtime::core::logger::LoggerManager::GetLoggerProxy(aimrt::runtime::core::util::ModuleDetailInfo const&)
aimrt_mujoco_sim/_deps/aimrt-src/src/runtime/core/logger/logger_manager.cc
const LoggerProxy& LoggerManager::GetLoggerProxy(const util::ModuleDetailInfo& module_info) { AIMRT_CHECK_ERROR_THROW( state_.load() == State::kInit, "Method can only be called when state is 'Init'."); const std::string& real_module_name = (module_info.name.empty()) ? "core" : module_info.name; auto itr = logger_proxy_map_.find(real_module_name); if (itr != logger_proxy_map_.end()) return *(itr->second); aimrt_log_level_t log_lvl = (real_module_name == "core") ? options_.core_lvl : (module_info.use_default_log_lvl ? options_.default_module_lvl : module_info.log_lvl); auto emplace_ret = logger_proxy_map_.emplace( real_module_name, std::make_unique<LoggerProxy>(real_module_name, log_lvl, logger_backend_vec_)); return *(emplace_ret.first->second); }
O3
cpp
aimrt::runtime::core::logger::LoggerManager::GetLoggerProxy(aimrt::runtime::core::util::ModuleDetailInfo const&): pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x48, %rsp movq %rdi, %rbx movl 0x20(%rdi), %eax cmpl $0x1, %eax jne 0x566ea movq %rsi, %r15 movq 0x8(%rsi), %rdx leaq 0x20(%rsp), %r13 movq %r13, -0x10(%r13) testq %rdx, %rdx je 0x565d2 movq (%r15), %rsi addq %rsi, %rdx leaq 0x10(%rsp), %rdi callq 0x1e640 jmp 0x565ea leaq 0x2ffea(%rip), %rsi # 0x865c3 leaq 0x2ffe7(%rip), %rdx # 0x865c7 leaq 0x10(%rsp), %rdi callq 0x1e620 leaq 0xa8(%rbx), %r14 leaq 0x10(%rsp), %rsi movq %r14, %rdi callq 0x5aff8 movq %rax, %r12 testq %rax, %rax jne 0x566bc leaq 0x2ffb2(%rip), %rsi # 0x865c3 leaq 0x10(%rsp), %rdi callq 0x1f2f0 movq %rbx, %rcx testl %eax, %eax je 0x5663c cmpb $0x1, 0x94(%r15) jne 0x56632 leaq 0x4(%rbx), %rcx jmp 0x5663c addq $0x90, %r15 movq %r15, %rcx movl (%rcx), %ebp movl $0x48, %edi callq 0x1f220 movq %rax, %r15 movq 0x10(%rsp), %rsi addq $0x10, %rax movq 0x18(%rsp), %rdx addq %rsi, %rdx movq %rax, (%r15) movq %r15, %rdi callq 0x1e620 addq $0x90, %rbx movl %ebp, 0x20(%r15) movq %rbx, 0x28(%r15) leaq 0x4a77(%rip), %rax # 0x5b0f4 movq %rax, 0x30(%r15) leaq 0x4a70(%rip), %rax # 0x5b0f8 movq %rax, 0x38(%r15) movq %r15, 0x40(%r15) leaq 0x30(%rsp), %rdx movq %r15, (%rdx) leaq 0x10(%rsp), %rsi movq %r14, %rdi callq 0x5b21e movq %rax, %r12 movq 0x30(%rsp), %rsi testq %rsi, %rsi je 0x566bc leaq 0x30(%rsp), %rdi callq 0x5b1f0 movq 0x28(%r12), %rbx movq 0x10(%rsp), %rdi cmpq %r13, %rdi je 0x566d8 movq 0x20(%rsp), %rsi incq %rsi callq 0x1f250 movq %rbx, %rax addq $0x48, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq leaq 0x2f347(%rip), %rsi # 0x85a38 leaq 0x10(%rsp), %rdi leaq 0x30(%rsp), %r8 movl $0x2f, %edx xorl %ecx, %ecx callq 0x25059 movq 0x28(%rbx), %rbx cmpq $0x0, 0x10(%rbx) jne 0x56717 callq 0x1e580 movq %rbx, %rdi callq *0x18(%rbx) cmpl $0x4, %eax ja 0x56754 movq 0x10(%rsp), %r9 movq 0x18(%rsp), %rax addq $0x20, %rbx movq %rax, (%rsp) leaq 0x309e6(%rip), %rcx # 0x87121 leaq 0x30b6d(%rip), %r8 # 0x872af movq %rbx, %rdi movl $0x4, %esi movl $0xa1, %edx callq 0x1ff80 movl $0x28, %edi callq 0x1e7e0 leaq 0x57ceb(%rip), %rcx # 0xae450 movq %rcx, (%rax) leaq 0x18(%rax), %rdx movq %rdx, 0x8(%rax) leaq 0x20(%rsp), %rcx movq -0x10(%rcx), %rsi cmpq %rcx, %rsi jne 0x56786 movups (%rcx), %xmm0 movups %xmm0, (%rdx) jmp 0x56793 movq %rsi, 0x8(%rax) movq 0x20(%rsp), %rdx movq %rdx, 0x18(%rax) movq 0x18(%rsp), %rdx movq %rdx, 0x10(%rax) movq %rcx, 0x10(%rsp) movq $0x0, 0x18(%rsp) movb $0x0, 0x20(%rsp) leaq 0x57bca(%rip), %rsi # 0xae380 leaq -0x32a89(%rip), %rdx # 0x23d34 movq %rax, %rdi callq 0x1fec0 movq %rax, %rbx movq 0x30(%rsp), %rsi testq %rsi, %rsi je 0x567f5 leaq 0x30(%rsp), %rdi callq 0x5b1f0 jmp 0x567f5 movq %rax, %rbx movl $0x48, %esi movq %r15, %rdi callq 0x1f250 jmp 0x567f5 jmp 0x567f2 movq %rax, %rbx movq 0x10(%rsp), %rdi cmpq %r13, %rdi jne 0x56814 jmp 0x56821 jmp 0x56803 movq %rax, %rbx leaq 0x20(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0x56821 movq 0x20(%rsp), %rsi incq %rsi callq 0x1f250 movq %rbx, %rdi callq 0x1ffd0 nop
_ZN5aimrt7runtime4core6logger13LoggerManager14GetLoggerProxyERKNS1_4util16ModuleDetailInfoE: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 48h mov rbx, rdi mov eax, [rdi+20h] cmp eax, 1 jnz loc_566EA mov r15, rsi mov rdx, [rsi+8] lea r13, [rsp+78h+var_58] mov [r13-10h], r13 test rdx, rdx jz short loc_565D2 mov rsi, [r15] add rdx, rsi lea rdi, [rsp+78h+var_68] call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIPcEEvT_S7_St20forward_iterator_tag; std::string::_M_construct<char *>(char *,char *,std::forward_iterator_tag) jmp short loc_565EA loc_565D2: lea rsi, aUnderscore+6; "core" lea rdx, aUnderscore+0Ah; "" lea rdi, [rsp+78h+var_68] call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIPKcEEvT_S8_St20forward_iterator_tag; std::string::_M_construct<char const*>(char const*,char const*,std::forward_iterator_tag) loc_565EA: lea r14, [rbx+0A8h] lea rsi, [rsp+78h+var_68] mov rdi, r14 call _ZNSt10_HashtableINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt4pairIKS5_St10unique_ptrIN5aimrt7runtime4core6logger11LoggerProxyESt14default_deleteISD_EEESaISH_ENSt8__detail10_Select1stESt8equal_toIvENS9_6common4util10StringHashENSJ_18_Mod_range_hashingENSJ_20_Default_ranged_hashENSJ_20_Prime_rehash_policyENSJ_17_Hashtable_traitsILb1ELb0ELb1EEEE4findERS7_; std::_Hashtable<std::string,std::pair<std::string const,std::unique_ptr<aimrt::runtime::core::logger::LoggerProxy>>,std::allocator<std::pair<std::string const,std::unique_ptr<aimrt::runtime::core::logger::LoggerProxy>>>,std::__detail::_Select1st,std::equal_to<void>,aimrt::common::util::StringHash,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<true,false,true>>::find(std::string const&) mov r12, rax test rax, rax jnz loc_566BC lea rsi, aUnderscore+6; "core" lea rdi, [rsp+78h+var_68] call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE7compareEPKc; std::string::compare(char const*) mov rcx, rbx test eax, eax jz short loc_5663C cmp byte ptr [r15+94h], 1 jnz short loc_56632 lea rcx, [rbx+4] jmp short loc_5663C loc_56632: add r15, 90h mov rcx, r15 loc_5663C: mov ebp, [rcx] mov edi, 48h ; 'H'; unsigned __int64 call __Znwm; operator new(ulong) mov r15, rax mov rsi, [rsp+78h+var_68] add rax, 10h mov rdx, [rsp+78h+var_60] add rdx, rsi mov [r15], rax mov rdi, r15 call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIPKcEEvT_S8_St20forward_iterator_tag; std::string::_M_construct<char const*>(char const*,char const*,std::forward_iterator_tag) add rbx, 90h mov [r15+20h], ebp mov [r15+28h], rbx lea rax, _ZZN5aimrt7runtime4core6logger11LoggerProxy7GenBaseEPvENUlS4_E_8__invokeES4_; aimrt::runtime::core::logger::LoggerProxy::GenBase(void *)::{lambda(void *)#1}::__invoke(void *) mov [r15+30h], rax lea rax, _ZZN5aimrt7runtime4core6logger11LoggerProxy7GenBaseEPvENUlS4_17aimrt_log_level_tjPKcS7_S7_mE_8__invokeES4_S5_jS7_S7_S7_m; aimrt::runtime::core::logger::LoggerProxy::GenBase(void *)::{lambda(void *,aimrt_log_level_t,uint,char const*,char const*,char const*,ulong)#1}::__invoke(void *,aimrt_log_level_t,uint,char const*,char const*,char const*,ulong) mov [r15+38h], rax mov [r15+40h], r15 lea rdx, [rsp+78h+var_48] mov [rdx], r15 lea rsi, [rsp+78h+var_68] mov rdi, r14 call _ZNSt10_HashtableINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt4pairIKS5_St10unique_ptrIN5aimrt7runtime4core6logger11LoggerProxyESt14default_deleteISD_EEESaISH_ENSt8__detail10_Select1stESt8equal_toIvENS9_6common4util10StringHashENSJ_18_Mod_range_hashingENSJ_20_Default_ranged_hashENSJ_20_Prime_rehash_policyENSJ_17_Hashtable_traitsILb1ELb0ELb1EEEE10_M_emplaceIJRS7_SG_EEES6_INSJ_14_Node_iteratorISH_Lb0ELb1EEEbESt17integral_constantIbLb1EEDpOT_; std::_Hashtable<std::string,std::pair<std::string const,std::unique_ptr<aimrt::runtime::core::logger::LoggerProxy>>,std::allocator<std::pair<std::string const,std::unique_ptr<aimrt::runtime::core::logger::LoggerProxy>>>,std::__detail::_Select1st,std::equal_to<void>,aimrt::common::util::StringHash,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<true,false,true>>::_M_emplace<std::string const&,std::unique_ptr<aimrt::runtime::core::logger::LoggerProxy>>(std::integral_constant<bool,true>,std::string const&,std::unique_ptr<aimrt::runtime::core::logger::LoggerProxy> &&) mov r12, rax mov rsi, qword ptr [rsp+78h+var_48] test rsi, rsi jz short loc_566BC lea rdi, [rsp+78h+var_48] call _ZNKSt14default_deleteIN5aimrt7runtime4core6logger11LoggerProxyEEclEPS4_; std::default_delete<aimrt::runtime::core::logger::LoggerProxy>::operator()(aimrt::runtime::core::logger::LoggerProxy*) loc_566BC: mov rbx, [r12+28h] mov rdi, [rsp+78h+var_68]; void * cmp rdi, r13 jz short loc_566D8 mov rsi, [rsp+78h+var_58] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_566D8: mov rax, rbx add rsp, 48h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn loc_566EA: lea rsi, aMethodCanOnlyB; "Method can only be called when state is"... lea rdi, [rsp+78h+var_68]; int lea r8, [rsp+78h+var_48]; int mov edx, 2Fh ; '/'; int xor ecx, ecx; int call _ZN3fmt3v107vformatB5cxx11ENS0_17basic_string_viewIcEENS0_17basic_format_argsINS0_20basic_format_contextINS0_8appenderEcEEEE; fmt::v10::vformat(fmt::v10::basic_string_view<char>,fmt::v10::basic_format_args<fmt::v10::basic_format_context<fmt::v10::appender,char>>) mov rbx, [rbx+28h] cmp qword ptr [rbx+10h], 0 jnz short loc_56717 call __ZSt25__throw_bad_function_callv; std::__throw_bad_function_call(void) loc_56717: mov rdi, rbx call qword ptr [rbx+18h] cmp eax, 4 ja short loc_56754 mov r9, [rsp+78h+var_68] mov rax, [rsp+78h+var_60] add rbx, 20h ; ' ' mov [rsp+78h+var_78], rax lea rcx, aWorkspaceLlm4b_2; "/workspace/llm4binary/github2025/aimrt_"... lea r8, aGetloggerproxy; "GetLoggerProxy" mov rdi, rbx mov esi, 4 mov edx, 0A1h call __ZNKSt8functionIFvjjPKcS1_S1_mEEclEjjS1_S1_S1_m; std::function<void ()(uint,uint,char const*,char const*,char const*,ulong)>::operator()(uint,uint,char const*,char const*,char const*,ulong) loc_56754: mov edi, 28h ; '('; thrown_size call ___cxa_allocate_exception lea rcx, off_AE450 mov [rax], rcx lea rdx, [rax+18h] mov [rax+8], rdx lea rcx, [rsp+78h+var_58] mov rsi, [rcx-10h] cmp rsi, rcx jnz short loc_56786 movups xmm0, xmmword ptr [rcx] movups xmmword ptr [rdx], xmm0 jmp short loc_56793 loc_56786: mov [rax+8], rsi mov rdx, [rsp+78h+var_58] mov [rax+18h], rdx loc_56793: mov rdx, [rsp+78h+var_60] mov [rax+10h], rdx mov [rsp+78h+var_68], rcx mov [rsp+78h+var_60], 0 mov byte ptr [rsp+78h+var_58], 0 lea rsi, _ZTIN5aimrt6common4util14AimRTExceptionE; lptinfo lea rdx, _ZN5aimrt6common4util14AimRTExceptionD2Ev; void (*)(void *) mov rdi, rax; void * call ___cxa_throw mov rbx, rax mov rsi, qword ptr [rsp+78h+var_48] test rsi, rsi jz short loc_567F5 lea rdi, [rsp+78h+var_48] call _ZNKSt14default_deleteIN5aimrt7runtime4core6logger11LoggerProxyEEclEPS4_; std::default_delete<aimrt::runtime::core::logger::LoggerProxy>::operator()(aimrt::runtime::core::logger::LoggerProxy*) jmp short loc_567F5 mov rbx, rax mov esi, 48h ; 'H'; unsigned __int64 mov rdi, r15; void * call __ZdlPvm; operator delete(void *,ulong) jmp short loc_567F5 jmp short $+2 loc_567F2: mov rbx, rax loc_567F5: mov rdi, [rsp+78h+var_68] cmp rdi, r13 jnz short loc_56814 jmp short loc_56821 jmp short $+2 loc_56803: mov rbx, rax lea rax, [rsp+78h+var_58] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_56821 loc_56814: mov rsi, [rsp+78h+var_58] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_56821: mov rdi, rbx call __Unwind_Resume
long long aimrt::runtime::core::logger::LoggerManager::GetLoggerProxy(long long a1, long long a2) { long long v2; // rdx long long v3; // r12 int v4; // eax int *v5; // rcx int v6; // ebp long long v7; // r15 void *v8; // rsi char *v9; // rdx long long v10; // rbx long long v12; // rbx char *exception; // rax void *v14; // [rsp+10h] [rbp-68h] BYREF long long v15; // [rsp+18h] [rbp-60h] __int128 v16; // [rsp+20h] [rbp-58h] BYREF int v17[2]; // [rsp+30h] [rbp-48h] BYREF if ( *(_DWORD *)(a1 + 32) != 1 ) { fmt::v10::vformat[abi:cxx11](&v14); v12 = *(_QWORD *)(a1 + 40); if ( !*(_QWORD *)(v12 + 16) ) std::__throw_bad_function_call(); if ( (*(unsigned int ( **)(long long, const char *))(v12 + 24))( v12, "Method can only be called when state is 'Init'.") <= 4 ) std::function<void ()(unsigned int,unsigned int,char const*,char const*,char const*,unsigned long)>::operator()( v12 + 32, 4, 161, (unsigned int)"/workspace/llm4binary/github2025/aimrt_mujoco_sim/_deps/aimrt-src/src/runtime/core/logger/logger_manager.cc", (unsigned int)"GetLoggerProxy", (_DWORD)v14, v15); exception = (char *)__cxa_allocate_exception(0x28uLL); *(_QWORD *)exception = off_AE450; *((_QWORD *)exception + 1) = exception + 24; if ( v14 == &v16 ) { *(_OWORD *)(exception + 24) = v16; } else { *((_QWORD *)exception + 1) = v14; *((_QWORD *)exception + 3) = v16; } *((_QWORD *)exception + 2) = v15; v14 = &v16; v15 = 0LL; LOBYTE(v16) = 0; __cxa_throw( exception, (struct type_info *)&`typeinfo for'aimrt::common::util::AimRTException, (void (*)(void *))aimrt::common::util::AimRTException::~AimRTException); } v2 = *(_QWORD *)(a2 + 8); v14 = &v16; if ( v2 ) std::string::_M_construct<char *>(&v14, *(_QWORD *)a2, *(_QWORD *)a2 + v2); else std::string::_M_construct<char const*>(&v14, "core", ""); v3 = std::_Hashtable<std::string,std::pair<std::string const,std::unique_ptr<aimrt::runtime::core::logger::LoggerProxy>>,std::allocator<std::pair<std::string const,std::unique_ptr<aimrt::runtime::core::logger::LoggerProxy>>>,std::__detail::_Select1st,std::equal_to<void>,aimrt::common::util::StringHash,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<true,false,true>>::find( a1 + 168, &v14); if ( !v3 ) { v4 = std::string::compare(&v14, "core"); v5 = (int *)a1; if ( v4 ) { if ( *(_BYTE *)(a2 + 148) == 1 ) v5 = (int *)(a1 + 4); else v5 = (int *)(a2 + 144); } v6 = *v5; v7 = operator new(0x48uLL); v8 = v14; v9 = (char *)v14 + v15; *(_QWORD *)v7 = v7 + 16; std::string::_M_construct<char const*>(v7, v8, v9); *(_DWORD *)(v7 + 32) = v6; *(_QWORD *)(v7 + 40) = a1 + 144; *(_QWORD *)(v7 + 48) = aimrt::runtime::core::logger::LoggerProxy::GenBase(void *)::{lambda(void *)#1}::__invoke; *(_QWORD *)(v7 + 56) = aimrt::runtime::core::logger::LoggerProxy::GenBase(void *)::{lambda(void *,aimrt_log_level_t,unsigned int,char const*,char const*,char const*,unsigned long)#1}::__invoke; *(_QWORD *)(v7 + 64) = v7; *(_QWORD *)v17 = v7; v3 = std::_Hashtable<std::string,std::pair<std::string const,std::unique_ptr<aimrt::runtime::core::logger::LoggerProxy>>,std::allocator<std::pair<std::string const,std::unique_ptr<aimrt::runtime::core::logger::LoggerProxy>>>,std::__detail::_Select1st,std::equal_to<void>,aimrt::common::util::StringHash,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<true,false,true>>::_M_emplace<std::string const&,std::unique_ptr<aimrt::runtime::core::logger::LoggerProxy>>( a1 + 168, &v14); if ( *(_QWORD *)v17 ) std::default_delete<aimrt::runtime::core::logger::LoggerProxy>::operator()(v17); } v10 = *(_QWORD *)(v3 + 40); if ( v14 != &v16 ) operator delete(v14, v16 + 1); return v10; }
GetLoggerProxy: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x48 MOV RBX,RDI MOV EAX,dword ptr [RDI + 0x20] CMP EAX,0x1 JNZ 0x001566ea MOV R15,RSI MOV RDX,qword ptr [RSI + 0x8] LEA R13,[RSP + 0x20] MOV qword ptr [R13 + -0x10],R13 TEST RDX,RDX JZ 0x001565d2 MOV RSI,qword ptr [R15] ADD RDX,RSI LEA RDI,[RSP + 0x10] CALL 0x0011e640 JMP 0x001565ea LAB_001565d2: LEA RSI,[0x1865c3] LEA RDX,[0x1865c7] LEA RDI,[RSP + 0x10] CALL 0x0011e620 LAB_001565ea: LEA R14,[RBX + 0xa8] LAB_001565f1: LEA RSI,[RSP + 0x10] MOV RDI,R14 CALL 0x0015aff8 MOV R12,RAX TEST RAX,RAX JNZ 0x001566bc LEA RSI,[0x1865c3] LEA RDI,[RSP + 0x10] CALL 0x0011f2f0 MOV RCX,RBX TEST EAX,EAX JZ 0x0015663c CMP byte ptr [R15 + 0x94],0x1 JNZ 0x00156632 LEA RCX,[RBX + 0x4] JMP 0x0015663c LAB_00156632: ADD R15,0x90 MOV RCX,R15 LAB_0015663c: MOV EBP,dword ptr [RCX] LAB_0015663e: MOV EDI,0x48 CALL 0x0011f220 MOV R15,RAX MOV RSI,qword ptr [RSP + 0x10] ADD RAX,0x10 MOV RDX,qword ptr [RSP + 0x18] ADD RDX,RSI MOV qword ptr [R15],RAX LAB_0015665f: MOV RDI,R15 CALL 0x0011e620 ADD RBX,0x90 MOV dword ptr [R15 + 0x20],EBP MOV qword ptr [R15 + 0x28],RBX LEA RAX,[0x15b0f4] MOV qword ptr [R15 + 0x30],RAX LEA RAX,[0x15b0f8] MOV qword ptr [R15 + 0x38],RAX MOV qword ptr [R15 + 0x40],R15 LEA RDX,[RSP + 0x30] MOV qword ptr [RDX],R15 LAB_00156698: LEA RSI,[RSP + 0x10] MOV RDI,R14 CALL 0x0015b21e LAB_001566a5: MOV R12,RAX MOV RSI,qword ptr [RSP + 0x30] TEST RSI,RSI JZ 0x001566bc LEA RDI,[RSP + 0x30] CALL 0x0015b1f0 LAB_001566bc: MOV RBX,qword ptr [R12 + 0x28] MOV RDI,qword ptr [RSP + 0x10] CMP RDI,R13 JZ 0x001566d8 MOV RSI,qword ptr [RSP + 0x20] INC RSI CALL 0x0011f250 LAB_001566d8: MOV RAX,RBX ADD RSP,0x48 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET LAB_001566ea: LEA RSI,[0x185a38] LEA RDI,[RSP + 0x10] LEA R8,[RSP + 0x30] MOV EDX,0x2f XOR ECX,ECX CALL 0x00125059 MOV RBX,qword ptr [RBX + 0x28] CMP qword ptr [RBX + 0x10],0x0 JNZ 0x00156717 LAB_00156712: CALL 0x0011e580 LAB_00156717: MOV RDI,RBX CALL qword ptr [RBX + 0x18] CMP EAX,0x4 JA 0x00156754 MOV R9,qword ptr [RSP + 0x10] MOV RAX,qword ptr [RSP + 0x18] ADD RBX,0x20 LAB_00156730: MOV qword ptr [RSP],RAX LEA RCX,[0x187121] LEA R8,[0x1872af] MOV RDI,RBX MOV ESI,0x4 MOV EDX,0xa1 CALL 0x0011ff80 LAB_00156754: MOV EDI,0x28 CALL 0x0011e7e0 LEA RCX,[0x1ae450] MOV qword ptr [RAX],RCX LEA RDX,[RAX + 0x18] MOV qword ptr [RAX + 0x8],RDX LEA RCX,[RSP + 0x20] MOV RSI,qword ptr [RCX + -0x10] CMP RSI,RCX JNZ 0x00156786 MOVUPS XMM0,xmmword ptr [RCX] MOVUPS xmmword ptr [RDX],XMM0 JMP 0x00156793 LAB_00156786: MOV qword ptr [RAX + 0x8],RSI MOV RDX,qword ptr [RSP + 0x20] MOV qword ptr [RAX + 0x18],RDX LAB_00156793: MOV RDX,qword ptr [RSP + 0x18] MOV qword ptr [RAX + 0x10],RDX MOV qword ptr [RSP + 0x10],RCX MOV qword ptr [RSP + 0x18],0x0 MOV byte ptr [RSP + 0x20],0x0 LAB_001567af: LEA RSI,[0x1ae380] LEA RDX,[0x123d34] MOV RDI,RAX CALL 0x0011fec0
/* aimrt::runtime::core::logger::LoggerManager::GetLoggerProxy(aimrt::runtime::core::util::ModuleDetailInfo const&) */ int8 __thiscall aimrt::runtime::core::logger::LoggerManager::GetLoggerProxy (LoggerManager *this,ModuleDetailInfo *param_1) { int4 uVar1; int8 uVar2; int iVar3; uint uVar4; long lVar5; LoggerProxy *pLVar6; int8 *puVar7; ModuleDetailInfo *pMVar8; uint *local_68; long local_60; uint local_58; int4 uStack_54; int4 uStack_50; int4 uStack_4c; LoggerProxy *local_48 [3]; if (*(int *)(this + 0x20) == 1) { local_68 = &local_58; if (*(long *)(param_1 + 8) == 0) { std::__cxx11::string::_M_construct<char_const*>(&local_68,"core",""); } else { std::__cxx11::string::_M_construct<char*> (&local_68,*(long *)param_1,*(long *)(param_1 + 8) + *(long *)param_1); } /* try { // try from 001565f1 to 001565fd has its CatchHandler @ 001567f2 */ lVar5 = std:: _Hashtable<std::__cxx11::string,std::pair<std::__cxx11::string_const,std::unique_ptr<aimrt::runtime::core::logger::LoggerProxy,std::default_delete<aimrt::runtime::core::logger::LoggerProxy>>>,std::allocator<std::pair<std::__cxx11::string_const,std::unique_ptr<aimrt::runtime::core::logger::LoggerProxy,std::default_delete<aimrt::runtime::core::logger::LoggerProxy>>>>,std::__detail::_Select1st,std::equal_to<void>,aimrt::common::util::StringHash,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<true,false,true>> ::find((_Hashtable<std::__cxx11::string,std::pair<std::__cxx11::string_const,std::unique_ptr<aimrt::runtime::core::logger::LoggerProxy,std::default_delete<aimrt::runtime::core::logger::LoggerProxy>>>,std::allocator<std::pair<std::__cxx11::string_const,std::unique_ptr<aimrt::runtime::core::logger::LoggerProxy,std::default_delete<aimrt::runtime::core::logger::LoggerProxy>>>>,std::__detail::_Select1st,std::equal_to<void>,aimrt::common::util::StringHash,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<true,false,true>> *)(this + 0xa8),(string *)&local_68); if (lVar5 == 0) { iVar3 = std::__cxx11::string::compare((string *)&local_68,"core"); pMVar8 = (ModuleDetailInfo *)this; if (iVar3 != 0) { if (param_1[0x94] == (ModuleDetailInfo)0x1) { pMVar8 = (ModuleDetailInfo *)(this + 4); } else { pMVar8 = param_1 + 0x90; } } uVar1 = *(int4 *)pMVar8; /* try { // try from 0015663e to 00156647 has its CatchHandler @ 001567f0 */ pLVar6 = (LoggerProxy *)operator_new(0x48); *(LoggerProxy **)pLVar6 = pLVar6 + 0x10; /* try { // try from 0015665f to 00156666 has its CatchHandler @ 001567de */ std::__cxx11::string::_M_construct<char_const*>(pLVar6,local_68,local_60 + (long)local_68); *(int4 *)(pLVar6 + 0x20) = uVar1; *(LoggerManager **)(pLVar6 + 0x28) = this + 0x90; *(code **)(pLVar6 + 0x30) = LoggerProxy::GenBase(void*)::{lambda(void*)#1}::__invoke; *(code **)(pLVar6 + 0x38) = LoggerProxy::GenBase(void*):: {lambda(void*,aimrt_log_level_t,unsigned_int,char_const*,char_const*,char_const*,unsigned_long)#1} ::__invoke; *(LoggerProxy **)(pLVar6 + 0x40) = pLVar6; /* try { // try from 00156698 to 001566a4 has its CatchHandler @ 001567c5 */ local_48[0] = pLVar6; lVar5 = std:: _Hashtable<std::__cxx11::string,std::pair<std::__cxx11::string_const,std::unique_ptr<aimrt::runtime::core::logger::LoggerProxy,std::default_delete<aimrt::runtime::core::logger::LoggerProxy>>>,std::allocator<std::pair<std::__cxx11::string_const,std::unique_ptr<aimrt::runtime::core::logger::LoggerProxy,std::default_delete<aimrt::runtime::core::logger::LoggerProxy>>>>,std::__detail::_Select1st,std::equal_to<void>,aimrt::common::util::StringHash,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<true,false,true>> :: _M_emplace<std::__cxx11::string_const&,std::unique_ptr<aimrt::runtime::core::logger::LoggerProxy,std::default_delete<aimrt::runtime::core::logger::LoggerProxy>>> ((_Hashtable<std::__cxx11::string,std::pair<std::__cxx11::string_const,std::unique_ptr<aimrt::runtime::core::logger::LoggerProxy,std::default_delete<aimrt::runtime::core::logger::LoggerProxy>>>,std::allocator<std::pair<std::__cxx11::string_const,std::unique_ptr<aimrt::runtime::core::logger::LoggerProxy,std::default_delete<aimrt::runtime::core::logger::LoggerProxy>>>>,std::__detail::_Select1st,std::equal_to<void>,aimrt::common::util::StringHash,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<true,false,true>> *)(this + 0xa8),&local_68); if (local_48[0] != (LoggerProxy *)0x0) { std::default_delete<aimrt::runtime::core::logger::LoggerProxy>::operator() ((default_delete<aimrt::runtime::core::logger::LoggerProxy> *)local_48,local_48[0] ); } } uVar2 = *(int8 *)(lVar5 + 0x28); if (local_68 != &local_58) { operator_delete(local_68,CONCAT44(uStack_54,local_58) + 1); } return uVar2; } fmt::v10::vformat_abi_cxx11_ (&local_68,"Method can only be called when state is \'Init\'.",0x2f,0,local_48); lVar5 = *(long *)(this + 0x28); if (*(long *)(lVar5 + 0x10) == 0) { /* WARNING: Subroutine does not return */ /* try { // try from 00156712 to 0015671c has its CatchHandler @ 00156803 */ std::__throw_bad_function_call(); } uVar4 = (**(code **)(lVar5 + 0x18))(lVar5); if (uVar4 < 5) { /* try { // try from 00156730 to 00156753 has its CatchHandler @ 00156801 */ std::function<void(unsigned_int,unsigned_int,char_const*,char_const*,char_const*,unsigned_long)> ::operator()((int)lVar5 + 0x20,4,(char *)0xa1, "/workspace/llm4binary/github2025/aimrt_mujoco_sim/_deps/aimrt-src/src/runtime/core/logger/logger_manager.cc" ,"GetLoggerProxy",(ulong)local_68); } puVar7 = (int8 *)__cxa_allocate_exception(0x28); *puVar7 = &PTR__AimRTException_001ae450; puVar7[1] = puVar7 + 3; if (local_68 == &local_58) { *(uint *)(puVar7 + 3) = local_58; *(int4 *)((long)puVar7 + 0x1c) = uStack_54; *(int4 *)(puVar7 + 4) = uStack_50; *(int4 *)((long)puVar7 + 0x24) = uStack_4c; } else { puVar7[1] = local_68; puVar7[3] = CONCAT44(uStack_54,local_58); } puVar7[2] = local_60; local_60 = 0; local_58 = local_58 & 0xffffff00; local_68 = &local_58; /* try { // try from 001567af to 001567c4 has its CatchHandler @ 00156803 */ /* WARNING: Subroutine does not return */ __cxa_throw(puVar7,&common::util::AimRTException::typeinfo, common::util::AimRTException::~AimRTException); }
60,801
my_convert
eloqsql/strings/ctype.c
uint32 my_convert(char *to, uint32 to_length, CHARSET_INFO *to_cs, const char *from, uint32 from_length, CHARSET_INFO *from_cs, uint *errors) { uint32 length, length2; /* If any of the character sets is not ASCII compatible, immediately switch to slow mb_wc->wc_mb method. */ if ((to_cs->state | from_cs->state) & MY_CS_NONASCII) return my_convert_using_func(to, to_length, to_cs, to_cs->cset->wc_mb, from, from_length, from_cs, from_cs->cset->mb_wc, errors); length= length2= MY_MIN(to_length, from_length); #if defined(__i386__) || defined(__x86_64__) /* Special loop for i386, it allows to refer to a non-aligned memory block as UINT32, which makes it possible to copy four bytes at once. This gives about 10% performance improvement comparing to byte-by-byte loop. */ for ( ; length >= 4; length-= 4, from+= 4, to+= 4) { if ((*(uint32*)from) & 0x80808080) break; *((uint32*) to)= *((const uint32*) from); } #endif /* __i386__ */ for (; ; *to++= *from++, length--) { if (!length) { *errors= 0; return length2; } if (*((unsigned char*) from) > 0x7F) /* A non-ASCII character */ { uint32 copied_length= length2 - length; to_length-= copied_length; from_length-= copied_length; return copied_length + my_convert_using_func(to, to_length, to_cs, to_cs->cset->wc_mb, from, from_length, from_cs, from_cs->cset->mb_wc, errors); } } DBUG_ASSERT(FALSE); // Should never get to here return 0; // Make compiler happy }
O3
c
my_convert: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %rbx pushq %rax movq %r9, %rax movl %r8d, %r9d movq %rcx, %r8 movq 0x10(%rbp), %r10 movl 0xc(%rax), %ecx orl 0xc(%rdx), %ecx btl $0xd, %ecx jb 0xf19b0 cmpl %r9d, %esi movl %r9d, %ebx cmovbl %esi, %ebx movl %ebx, %ecx cmpl $0x4, %ebx jb 0xf1989 movl (%r8), %r11d testl $0x80808080, %r11d # imm = 0x80808080 jne 0xf198d movl %r11d, (%rdi) addl $-0x4, %ecx addq $0x4, %r8 addq $0x4, %rdi cmpl $0x3, %ecx ja 0xf196a testl %ecx, %ecx je 0xf19a7 movl %ecx, %r14d xorl %r15d, %r15d movb (%r8,%r15), %cl testb %cl, %cl js 0xf19dd movb %cl, (%rdi,%r15) incq %r15 cmpl %r15d, %r14d jne 0xf1993 movl $0x0, (%r10) jmp 0xf1a22 movl %esi, %esi movq 0xb8(%rdx), %rcx movq 0x30(%rcx), %rcx movl %r9d, %r9d movq 0xb8(%rax), %r11 subq $0x8, %rsp pushq %r10 pushq 0x28(%r11) pushq %rax callq 0xf183f addq $0x28, %rsp jmp 0xf1a28 addl %r14d, %esi subl %ebx, %esi subl %r15d, %esi addl %r14d, %r9d subl %ebx, %r9d subl %r15d, %r9d movq 0xb8(%rdx), %rcx movq 0x30(%rcx), %rcx movq 0xb8(%rax), %r11 addq %r15, %rdi addq %r15, %r8 subq $0x8, %rsp pushq %r10 pushq 0x28(%r11) pushq %rax callq 0xf183f addq $0x20, %rsp subl %r14d, %ebx addl %r15d, %ebx addl %eax, %ebx movl %ebx, %eax addq $0x8, %rsp popq %rbx popq %r14 popq %r15 popq %rbp retq
my_convert: push rbp mov rbp, rsp push r15 push r14 push rbx push rax mov rax, r9 mov r9d, r8d mov r8, rcx mov r10, [rbp+arg_0] mov ecx, [rax+0Ch] or ecx, [rdx+0Ch] bt ecx, 0Dh jb short loc_F19B0 cmp esi, r9d mov ebx, r9d cmovb ebx, esi mov ecx, ebx cmp ebx, 4 jb short loc_F1989 loc_F196A: mov r11d, [r8] test r11d, 80808080h jnz short loc_F198D mov [rdi], r11d add ecx, 0FFFFFFFCh add r8, 4 add rdi, 4 cmp ecx, 3 ja short loc_F196A loc_F1989: test ecx, ecx jz short loc_F19A7 loc_F198D: mov r14d, ecx xor r15d, r15d loc_F1993: mov cl, [r8+r15] test cl, cl js short loc_F19DD mov [rdi+r15], cl inc r15 cmp r14d, r15d jnz short loc_F1993 loc_F19A7: mov dword ptr [r10], 0 jmp short loc_F1A22 loc_F19B0: mov esi, esi mov rcx, [rdx+0B8h] mov rcx, [rcx+30h] mov r9d, r9d mov r11, [rax+0B8h] sub rsp, 8 push r10 push qword ptr [r11+28h] push rax call my_convert_using_func add rsp, 28h jmp short loc_F1A28 loc_F19DD: add esi, r14d sub esi, ebx sub esi, r15d add r9d, r14d sub r9d, ebx sub r9d, r15d mov rcx, [rdx+0B8h] mov rcx, [rcx+30h] mov r11, [rax+0B8h] add rdi, r15 add r8, r15 sub rsp, 8 push r10 push qword ptr [r11+28h] push rax call my_convert_using_func add rsp, 20h sub ebx, r14d add ebx, r15d add ebx, eax loc_F1A22: mov eax, ebx add rsp, 8 loc_F1A28: pop rbx pop r14 pop r15 pop rbp retn
long long my_convert( _DWORD *a1, unsigned int a2, long long a3, long long a4, unsigned int a5, long long a6, _DWORD *a7) { _DWORD *v9; // r8 unsigned int v10; // ebx unsigned int v11; // ecx unsigned int v12; // r14d long long v13; // r15 char v14; // cl v9 = (_DWORD *)a4; if ( ((*(_DWORD *)(a3 + 12) | *(_DWORD *)(a6 + 12)) & 0x2000) != 0 ) return my_convert_using_func( (long long)a1, a2, a3, *(long long ( **)(long long, long long, long long, long long))(*(_QWORD *)(a3 + 184) + 48LL), a4, a5, a6, *(long long ( **)(long long, long long *, long long, unsigned long long))(*(_QWORD *)(a6 + 184) + 40LL), a7); v10 = a5; if ( a2 < a5 ) v10 = a2; v11 = v10; if ( v10 >= 4 ) { while ( (*v9 & 0x80808080) == 0 ) { *a1 = *v9; v11 -= 4; ++v9; ++a1; if ( v11 <= 3 ) goto LABEL_7; } goto LABEL_8; } LABEL_7: if ( v11 ) { LABEL_8: v12 = v11; v13 = 0LL; do { v14 = *((_BYTE *)v9 + v13); if ( v14 < 0 ) return (unsigned int)my_convert_using_func( (long long)a1 + v13, v12 + a2 - v10 - (unsigned int)v13, a3, *(long long ( **)(long long, long long, long long, long long))(*(_QWORD *)(a3 + 184) + 48LL), (long long)v9 + v13, v12 + a5 - v10 - (unsigned int)v13, a6, *(long long ( **)(long long, long long *, long long, unsigned long long))(*(_QWORD *)(a6 + 184) + 40LL), a7) + (_DWORD)v13 + v10 - v12; *((_BYTE *)a1 + v13++) = v14; } while ( v12 != (_DWORD)v13 ); } *a7 = 0; return v10; }
my_convert: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH RBX PUSH RAX MOV RAX,R9 MOV R9D,R8D MOV R8,RCX MOV R10,qword ptr [RBP + 0x10] MOV ECX,dword ptr [RAX + 0xc] OR ECX,dword ptr [RDX + 0xc] BT ECX,0xd JC 0x001f19b0 CMP ESI,R9D MOV EBX,R9D CMOVC EBX,ESI MOV ECX,EBX CMP EBX,0x4 JC 0x001f1989 LAB_001f196a: MOV R11D,dword ptr [R8] TEST R11D,0x80808080 JNZ 0x001f198d MOV dword ptr [RDI],R11D ADD ECX,-0x4 ADD R8,0x4 ADD RDI,0x4 CMP ECX,0x3 JA 0x001f196a LAB_001f1989: TEST ECX,ECX JZ 0x001f19a7 LAB_001f198d: MOV R14D,ECX XOR R15D,R15D LAB_001f1993: MOV CL,byte ptr [R8 + R15*0x1] TEST CL,CL JS 0x001f19dd MOV byte ptr [RDI + R15*0x1],CL INC R15 CMP R14D,R15D JNZ 0x001f1993 LAB_001f19a7: MOV dword ptr [R10],0x0 JMP 0x001f1a22 LAB_001f19b0: MOV ESI,ESI MOV RCX,qword ptr [RDX + 0xb8] MOV RCX,qword ptr [RCX + 0x30] MOV R9D,R9D MOV R11,qword ptr [RAX + 0xb8] SUB RSP,0x8 PUSH R10 PUSH qword ptr [R11 + 0x28] PUSH RAX CALL 0x001f183f ADD RSP,0x28 JMP 0x001f1a28 LAB_001f19dd: ADD ESI,R14D SUB ESI,EBX SUB ESI,R15D ADD R9D,R14D SUB R9D,EBX SUB R9D,R15D MOV RCX,qword ptr [RDX + 0xb8] MOV RCX,qword ptr [RCX + 0x30] MOV R11,qword ptr [RAX + 0xb8] ADD RDI,R15 ADD R8,R15 SUB RSP,0x8 PUSH R10 PUSH qword ptr [R11 + 0x28] PUSH RAX CALL 0x001f183f ADD RSP,0x20 SUB EBX,R14D ADD EBX,R15D ADD EBX,EAX LAB_001f1a22: MOV EAX,EBX ADD RSP,0x8 LAB_001f1a28: POP RBX POP R14 POP R15 POP RBP RET
ulong my_convert(uint *param_1,uint param_2,long param_3,uint *param_4,uint param_5,long param_6, int4 *param_7) { int iVar1; ulong uVar2; uint uVar3; uint uVar5; int iVar6; long lVar7; ulong uVar4; uVar2 = (ulong)param_5; if (((*(uint *)(param_6 + 0xc) | *(uint *)(param_3 + 0xc)) >> 0xd & 1) == 0) { if (param_2 < param_5) { uVar2 = (ulong)param_2; } uVar5 = (uint)uVar2; uVar3 = uVar5; uVar4 = uVar2; while (3 < uVar3) { uVar3 = (uint)uVar4; if ((*param_4 & 0x80808080) != 0) goto LAB_001f198d; *param_1 = *param_4; uVar3 = uVar3 - 4; uVar4 = (ulong)uVar3; param_4 = param_4 + 1; param_1 = param_1 + 1; } if (uVar3 != 0) { LAB_001f198d: lVar7 = 0; do { if (*(char *)((long)param_4 + lVar7) < '\0') { iVar6 = (int)lVar7; iVar1 = my_convert_using_func ((long)param_1 + lVar7,((param_2 + uVar3) - uVar5) - iVar6,param_3, *(int8 *)(*(long *)(param_3 + 0xb8) + 0x30),(long)param_4 + lVar7 ,((param_5 + uVar3) - uVar5) - iVar6,param_6, *(int8 *)(*(long *)(param_6 + 0xb8) + 0x28),param_7); return (ulong)((uVar5 - uVar3) + iVar6 + iVar1); } *(char *)((long)param_1 + lVar7) = *(char *)((long)param_4 + lVar7); lVar7 = lVar7 + 1; } while (uVar3 != (uint)lVar7); } *param_7 = 0; } else { uVar2 = my_convert_using_func (param_1,param_2,param_3,*(int8 *)(*(long *)(param_3 + 0xb8) + 0x30), param_4,uVar2,param_6,*(int8 *)(*(long *)(param_6 + 0xb8) + 0x28), param_7); } return uVar2; }
60,802
minja::ArgumentsValue::has_named(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&)
monkey531[P]llama/common/minja.hpp
bool has_named(const std::string & name) { for (const auto & p : kwargs) { if (p.first == name) return true; } return false; }
O2
cpp
minja::ArgumentsValue::has_named(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&): pushq %r15 pushq %r14 pushq %rbx movq %rsi, %rbx movq 0x18(%rdi), %rcx movq 0x20(%rdi), %r15 movq %rcx, %r14 cmpq %r15, %rcx je 0x86f89 movq %r14, %rdi movq %rbx, %rsi callq 0x2961f leaq 0x70(%r14), %rcx testb %al, %al je 0x86f6e cmpq %r15, %r14 setne %al popq %rbx popq %r14 popq %r15 retq nop
_ZN5minja14ArgumentsValue9has_namedERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE: push r15 push r14 push rbx mov rbx, rsi mov rcx, [rdi+18h] mov r15, [rdi+20h] loc_86F6E: mov r14, rcx cmp rcx, r15 jz short loc_86F89 mov rdi, r14 mov rsi, rbx call _ZSteqIcEN9__gnu_cxx11__enable_ifIXsr9__is_charIT_EE7__valueEbE6__typeERKNSt7__cxx1112basic_stringIS2_St11char_traitsIS2_ESaIS2_EEESC_ lea rcx, [r14+70h] test al, al jz short loc_86F6E loc_86F89: cmp r14, r15 setnz al pop rbx pop r14 pop r15 retn
bool minja::ArgumentsValue::has_named(long long a1, long long *a2) { long long *v2; // rcx long long *v3; // r15 long long *v4; // r14 bool v5; // al v2 = *(long long **)(a1 + 24); v3 = *(long long **)(a1 + 32); do { v4 = v2; if ( v2 == v3 ) break; v5 = std::operator==<char>(v2, a2); v2 = v4 + 14; } while ( !v5 ); return v4 != v3; }
has_named: PUSH R15 PUSH R14 PUSH RBX MOV RBX,RSI MOV RCX,qword ptr [RDI + 0x18] MOV R15,qword ptr [RDI + 0x20] LAB_00186f6e: MOV R14,RCX CMP RCX,R15 JZ 0x00186f89 MOV RDI,R14 MOV RSI,RBX CALL 0x0012961f LEA RCX,[R14 + 0x70] TEST AL,AL JZ 0x00186f6e LAB_00186f89: CMP R14,R15 SETNZ AL POP RBX POP R14 POP R15 RET
/* minja::ArgumentsValue::has_named(std::__cxx11::string const&) */ bool __thiscall minja::ArgumentsValue::has_named(ArgumentsValue *this,string *param_1) { string *psVar1; string *psVar2; char cVar3; string *psVar4; psVar1 = *(string **)(this + 0x20); psVar2 = *(string **)(this + 0x18); do { psVar4 = psVar2; if (psVar4 == psVar1) break; cVar3 = std::operator==(psVar4,param_1); psVar2 = psVar4 + 0x70; } while (cVar3 == '\0'); return psVar4 != psVar1; }
60,803
nlohmann::json_abi_v3_11_3::basic_json<std::map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>::type_name() const
msxemulator/build_O0/_deps/picotool-src/lib/nlohmann_json/single_include/nlohmann/json.hpp
JSON_HEDLEY_RETURNS_NON_NULL const char* type_name() const noexcept { switch (m_data.m_type) { case value_t::null: return "null"; case value_t::object: return "object"; case value_t::array: return "array"; case value_t::string: return "string"; case value_t::boolean: return "boolean"; case value_t::binary: return "binary"; case value_t::discarded: return "discarded"; case value_t::number_integer: case value_t::number_unsigned: case value_t::number_float: default: return "number"; } }
O0
cpp
nlohmann::json_abi_v3_11_3::basic_json<std::map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>::type_name() const: movq %rdi, -0x10(%rsp) movq -0x10(%rsp), %rax movzbl (%rax), %eax movq %rax, -0x18(%rsp) subq $0x9, %rax ja 0x9acd1 movq -0x18(%rsp), %rax leaq 0xd3d3c(%rip), %rcx # 0x16e9a0 movslq (%rcx,%rax,4), %rax addq %rcx, %rax jmpq *%rax leaq 0xd6d8d(%rip), %rax # 0x171a01 movq %rax, -0x8(%rsp) jmp 0x9acdd leaq 0xd6d84(%rip), %rax # 0x171a06 movq %rax, -0x8(%rsp) jmp 0x9acdd leaq 0xd6d7d(%rip), %rax # 0x171a0d movq %rax, -0x8(%rsp) jmp 0x9acdd leaq 0xd5ba9(%rip), %rax # 0x170847 movq %rax, -0x8(%rsp) jmp 0x9acdd leaq 0xd6d67(%rip), %rax # 0x171a13 movq %rax, -0x8(%rsp) jmp 0x9acdd leaq 0xd695c(%rip), %rax # 0x171616 movq %rax, -0x8(%rsp) jmp 0x9acdd leaq 0xd6d53(%rip), %rax # 0x171a1b movq %rax, -0x8(%rsp) jmp 0x9acdd jmp 0x9acd1 leaq 0xe29ea(%rip), %rax # 0x17d6c2 movq %rax, -0x8(%rsp) movq -0x8(%rsp), %rax retq nopw %cs:(%rax,%rax) nopl (%rax)
_ZNK8nlohmann16json_abi_v3_11_310basic_jsonISt3mapSt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE9type_nameEv: mov [rsp+var_10], rdi mov rax, [rsp+var_10] movzx eax, byte ptr [rax] mov [rsp+var_18], rax sub rax, 9; switch 10 cases ja short def_9AC6B; jumptable 000000000009AC6B default case mov rax, [rsp+var_18] lea rcx, jpt_9AC6B movsxd rax, ds:(jpt_9AC6B - 16E9A0h)[rcx+rax*4] add rax, rcx jmp rax; switch jump loc_9AC6D: lea rax, aNull; jumptable 000000000009AC6B case 0 mov [rsp+var_8], rax jmp short loc_9ACDD loc_9AC7B: lea rax, aObject; jumptable 000000000009AC6B case 1 mov [rsp+var_8], rax jmp short loc_9ACDD loc_9AC89: lea rax, aArray; jumptable 000000000009AC6B case 2 mov [rsp+var_8], rax jmp short loc_9ACDD loc_9AC97: lea rax, aXIsNotAValidFi+30h; jumptable 000000000009AC6B case 3 mov [rsp+var_8], rax jmp short loc_9ACDD loc_9ACA5: lea rax, aBoolean; jumptable 000000000009AC6B case 4 mov [rsp+var_8], rax jmp short loc_9ACDD loc_9ACB3: lea rax, aToolForInterac+27h; jumptable 000000000009AC6B case 8 mov [rsp+var_8], rax jmp short loc_9ACDD loc_9ACC1: lea rax, aDiscarded; jumptable 000000000009AC6B case 9 mov [rsp+var_8], rax jmp short loc_9ACDD loc_9ACCF: jmp short $+2; jumptable 000000000009AC6B cases 5-7 def_9AC6B: lea rax, aSerialNumber+7; jumptable 000000000009AC6B default case mov [rsp+var_8], rax loc_9ACDD: mov rax, [rsp+var_8] retn
char * nlohmann::json_abi_v3_11_3::basic_json<std::map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::type_name( _BYTE *a1) { char *v2; // [rsp+10h] [rbp-8h] switch ( *a1 ) { case 0: v2 = "null"; break; case 1: v2 = "object"; break; case 2: v2 = "array"; break; case 3: v2 = (char *)"string"; break; case 4: v2 = "boolean"; break; case 8: v2 = "binary"; break; case 9: v2 = "discarded"; break; default: v2 = "number"; break; } return v2; }
type_name: MOV qword ptr [RSP + -0x10],RDI MOV RAX,qword ptr [RSP + -0x10] MOVZX EAX,byte ptr [RAX] MOV qword ptr [RSP + -0x18],RAX SUB RAX,0x9 JA 0x0019acd1 MOV RAX,qword ptr [RSP + -0x18] LEA RCX,[0x26e9a0] MOVSXD RAX,dword ptr [RCX + RAX*0x4] ADD RAX,RCX switchD: JMP RAX caseD_0: LEA RAX,[0x271a01] MOV qword ptr [RSP + -0x8],RAX JMP 0x0019acdd caseD_1: LEA RAX,[0x271a06] MOV qword ptr [RSP + -0x8],RAX JMP 0x0019acdd caseD_2: LEA RAX,[0x271a0d] MOV qword ptr [RSP + -0x8],RAX JMP 0x0019acdd caseD_3: LEA RAX,[0x270847] MOV qword ptr [RSP + -0x8],RAX JMP 0x0019acdd caseD_4: LEA RAX,[0x271a13] MOV qword ptr [RSP + -0x8],RAX JMP 0x0019acdd caseD_8: LEA RAX,[0x271616] MOV qword ptr [RSP + -0x8],RAX JMP 0x0019acdd caseD_9: LEA RAX,[0x271a1b] MOV qword ptr [RSP + -0x8],RAX JMP 0x0019acdd caseD_5: JMP 0x0019acd1 default: LEA RAX,[0x27d6c2] MOV qword ptr [RSP + -0x8],RAX LAB_0019acdd: MOV RAX,qword ptr [RSP + -0x8] RET
/* nlohmann::json_abi_v3_11_3::basic_json<std::map, std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char> >, void>::type_name() const */ char * __thiscall nlohmann::json_abi_v3_11_3:: basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> ::type_name(basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> *this) { char *local_8; switch(*this) { case (basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> )0x0: local_8 = "null"; break; case (basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> )0x1: local_8 = "object"; break; case (basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> )0x2: local_8 = "array"; break; case (basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> )0x3: local_8 = "string"; break; case (basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> )0x4: local_8 = "boolean"; break; case (basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> )0x5: case (basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> )0x6: case (basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> )0x7: default: local_8 = "number"; break; case (basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> )0x8: local_8 = "binary"; break; case (basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> )0x9: local_8 = "discarded"; } return local_8; }
60,804
cli_report_progress
eloqsql/libmariadb/libmariadb/mariadb_lib.c
static int cli_report_progress(MYSQL *mysql, uchar *packet, uint length) { uint stage, max_stage, proc_length; double progress; uchar *start= packet; if (length < 5) return 1; /* Wrong packet */ if (!(mysql->options.extension && mysql->options.extension->report_progress)) return 0; /* No callback, ignore packet */ packet++; /* Ignore number of strings */ stage= (uint) *packet++; max_stage= (uint) *packet++; progress= uint3korr(packet)/1000.0; packet+= 3; proc_length= net_field_length(&packet); if (packet + proc_length > start + length) return 1; /* Wrong packet */ (*mysql->options.extension->report_progress)(mysql, stage, max_stage, progress, (char*) packet, proc_length); return 0; }
O0
c
cli_report_progress: pushq %rbp movq %rsp, %rbp subq $0x40, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movl %edx, -0x1c(%rbp) movq -0x18(%rbp), %rax movq %rax, -0x38(%rbp) cmpl $0x5, -0x1c(%rbp) jae 0x309dd movl $0x1, -0x4(%rbp) jmp 0x30ad0 movq -0x10(%rbp), %rax cmpq $0x0, 0x480(%rax) je 0x30a00 movq -0x10(%rbp), %rax movq 0x480(%rax), %rax cmpq $0x0, 0x80(%rax) jne 0x30a0c movl $0x0, -0x4(%rbp) jmp 0x30ad0 movq -0x18(%rbp), %rax incq %rax movq %rax, -0x18(%rbp) movq -0x18(%rbp), %rax movq %rax, %rcx incq %rcx movq %rcx, -0x18(%rbp) movzbl (%rax), %eax movl %eax, -0x20(%rbp) movq -0x18(%rbp), %rax movq %rax, %rcx incq %rcx movq %rcx, -0x18(%rbp) movzbl (%rax), %eax movl %eax, -0x24(%rbp) movq -0x18(%rbp), %rcx movzwl (%rcx), %eax movzbl 0x2(%rcx), %ecx shll $0x10, %ecx orl %ecx, %eax cvtsi2sd %eax, %xmm0 movsd 0x34a95(%rip), %xmm1 # 0x654f0 divsd %xmm1, %xmm0 movsd %xmm0, -0x30(%rbp) movq -0x18(%rbp), %rax addq $0x3, %rax movq %rax, -0x18(%rbp) leaq -0x18(%rbp), %rdi callq 0x30ae0 movl %eax, -0x28(%rbp) movq -0x18(%rbp), %rax movl -0x28(%rbp), %ecx addq %rcx, %rax movq -0x38(%rbp), %rcx movl -0x1c(%rbp), %edx addq %rdx, %rcx cmpq %rcx, %rax jbe 0x30a9e movl $0x1, -0x4(%rbp) jmp 0x30ad0 movq -0x10(%rbp), %rax movq 0x480(%rax), %rax movq 0x80(%rax), %rax movq -0x10(%rbp), %rdi movl -0x20(%rbp), %esi movl -0x24(%rbp), %edx movsd -0x30(%rbp), %xmm0 movq -0x18(%rbp), %rcx movl -0x28(%rbp), %r8d callq *%rax movl $0x0, -0x4(%rbp) movl -0x4(%rbp), %eax addq $0x40, %rsp popq %rbp retq nopl (%rax)
cli_report_progress: push rbp mov rbp, rsp sub rsp, 40h mov [rbp+var_10], rdi mov [rbp+var_18], rsi mov [rbp+var_1C], edx mov rax, [rbp+var_18] mov [rbp+var_38], rax cmp [rbp+var_1C], 5 jnb short loc_309DD mov [rbp+var_4], 1 jmp loc_30AD0 loc_309DD: mov rax, [rbp+var_10] cmp qword ptr [rax+480h], 0 jz short loc_30A00 mov rax, [rbp+var_10] mov rax, [rax+480h] cmp qword ptr [rax+80h], 0 jnz short loc_30A0C loc_30A00: mov [rbp+var_4], 0 jmp loc_30AD0 loc_30A0C: mov rax, [rbp+var_18] inc rax mov [rbp+var_18], rax mov rax, [rbp+var_18] mov rcx, rax inc rcx mov [rbp+var_18], rcx movzx eax, byte ptr [rax] mov [rbp+var_20], eax mov rax, [rbp+var_18] mov rcx, rax inc rcx mov [rbp+var_18], rcx movzx eax, byte ptr [rax] mov [rbp+var_24], eax mov rcx, [rbp+var_18] movzx eax, word ptr [rcx] movzx ecx, byte ptr [rcx+2] shl ecx, 10h or eax, ecx cvtsi2sd xmm0, eax movsd xmm1, cs:qword_654F0 divsd xmm0, xmm1 movsd [rbp+var_30], xmm0 mov rax, [rbp+var_18] add rax, 3 mov [rbp+var_18], rax lea rdi, [rbp+var_18] call net_field_length mov [rbp+var_28], eax mov rax, [rbp+var_18] mov ecx, [rbp+var_28] add rax, rcx mov rcx, [rbp+var_38] mov edx, [rbp+var_1C] add rcx, rdx cmp rax, rcx jbe short loc_30A9E mov [rbp+var_4], 1 jmp short loc_30AD0 loc_30A9E: mov rax, [rbp+var_10] mov rax, [rax+480h] mov rax, [rax+80h] mov rdi, [rbp+var_10] mov esi, [rbp+var_20] mov edx, [rbp+var_24] movsd xmm0, [rbp+var_30] mov rcx, [rbp+var_18] mov r8d, [rbp+var_28] call rax mov [rbp+var_4], 0 loc_30AD0: mov eax, [rbp+var_4] add rsp, 40h pop rbp retn
long long cli_report_progress(long long a1, unsigned __int16 *a2, unsigned int a3) { unsigned __int16 *v3; // rax unsigned __int16 *v4; // rax double v6; // [rsp+10h] [rbp-30h] unsigned int v7; // [rsp+18h] [rbp-28h] unsigned int v8; // [rsp+1Ch] [rbp-24h] unsigned int v9; // [rsp+20h] [rbp-20h] unsigned __int16 *v11; // [rsp+28h] [rbp-18h] BYREF long long v12; // [rsp+30h] [rbp-10h] v12 = a1; v11 = a2; if ( a3 >= 5 ) { if ( *(_QWORD *)(v12 + 1152) && *(_QWORD *)(*(_QWORD *)(v12 + 1152) + 128LL) ) { v11 = (unsigned __int16 *)((char *)v11 + 1); v3 = v11; v11 = (unsigned __int16 *)((char *)v11 + 1); v9 = *(unsigned __int8 *)v3; v4 = v11; v11 = (unsigned __int16 *)((char *)v11 + 1); v8 = *(unsigned __int8 *)v4; v6 = (double)((*((unsigned __int8 *)v11 + 2) << 16) | (unsigned int)*v11) / 1000.0; v11 = (unsigned __int16 *)((char *)v11 + 3); v7 = net_field_length(&v11); if ( (char *)v11 + v7 <= (char *)a2 + a3 ) { (*(void ( **)(long long, _QWORD, _QWORD, unsigned __int16 *, _QWORD, double))(*(_QWORD *)(v12 + 1152) + 128LL))( v12, v9, v8, v11, v7, v6); return 0; } else { return 1; } } else { return 0; } } else { return 1; } }
cli_report_progress: PUSH RBP MOV RBP,RSP SUB RSP,0x40 MOV qword ptr [RBP + -0x10],RDI MOV qword ptr [RBP + -0x18],RSI MOV dword ptr [RBP + -0x1c],EDX MOV RAX,qword ptr [RBP + -0x18] MOV qword ptr [RBP + -0x38],RAX CMP dword ptr [RBP + -0x1c],0x5 JNC 0x001309dd MOV dword ptr [RBP + -0x4],0x1 JMP 0x00130ad0 LAB_001309dd: MOV RAX,qword ptr [RBP + -0x10] CMP qword ptr [RAX + 0x480],0x0 JZ 0x00130a00 MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x480] CMP qword ptr [RAX + 0x80],0x0 JNZ 0x00130a0c LAB_00130a00: MOV dword ptr [RBP + -0x4],0x0 JMP 0x00130ad0 LAB_00130a0c: MOV RAX,qword ptr [RBP + -0x18] INC RAX MOV qword ptr [RBP + -0x18],RAX MOV RAX,qword ptr [RBP + -0x18] MOV RCX,RAX INC RCX MOV qword ptr [RBP + -0x18],RCX MOVZX EAX,byte ptr [RAX] MOV dword ptr [RBP + -0x20],EAX MOV RAX,qword ptr [RBP + -0x18] MOV RCX,RAX INC RCX MOV qword ptr [RBP + -0x18],RCX MOVZX EAX,byte ptr [RAX] MOV dword ptr [RBP + -0x24],EAX MOV RCX,qword ptr [RBP + -0x18] MOVZX EAX,word ptr [RCX] MOVZX ECX,byte ptr [RCX + 0x2] SHL ECX,0x10 OR EAX,ECX CVTSI2SD XMM0,EAX MOVSD XMM1,qword ptr [0x001654f0] DIVSD XMM0,XMM1 MOVSD qword ptr [RBP + -0x30],XMM0 MOV RAX,qword ptr [RBP + -0x18] ADD RAX,0x3 MOV qword ptr [RBP + -0x18],RAX LEA RDI,[RBP + -0x18] CALL 0x00130ae0 MOV dword ptr [RBP + -0x28],EAX MOV RAX,qword ptr [RBP + -0x18] MOV ECX,dword ptr [RBP + -0x28] ADD RAX,RCX MOV RCX,qword ptr [RBP + -0x38] MOV EDX,dword ptr [RBP + -0x1c] ADD RCX,RDX CMP RAX,RCX JBE 0x00130a9e MOV dword ptr [RBP + -0x4],0x1 JMP 0x00130ad0 LAB_00130a9e: MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x480] MOV RAX,qword ptr [RAX + 0x80] MOV RDI,qword ptr [RBP + -0x10] MOV ESI,dword ptr [RBP + -0x20] MOV EDX,dword ptr [RBP + -0x24] MOVSD XMM0,qword ptr [RBP + -0x30] MOV RCX,qword ptr [RBP + -0x18] MOV R8D,dword ptr [RBP + -0x28] CALL RAX MOV dword ptr [RBP + -0x4],0x0 LAB_00130ad0: MOV EAX,dword ptr [RBP + -0x4] ADD RSP,0x40 POP RBP RET
int4 cli_report_progress(long param_1,long param_2,uint param_3) { int1 uVar1; int1 uVar2; uint uVar3; double dVar4; long local_20; long local_18; int4 local_c; if (param_3 < 5) { local_c = 1; } else if ((*(long *)(param_1 + 0x480) == 0) || (*(long *)(*(long *)(param_1 + 0x480) + 0x80) == 0)) { local_c = 0; } else { uVar1 = *(int1 *)(param_2 + 1); uVar2 = *(int1 *)(param_2 + 2); dVar4 = (double)*(uint3 *)(param_2 + 3) / DAT_001654f0; local_20 = param_2 + 6; local_18 = param_1; uVar3 = net_field_length(&local_20); if (param_2 + (ulong)param_3 < local_20 + (ulong)uVar3) { local_c = 1; } else { (**(code **)(*(long *)(local_18 + 0x480) + 0x80))(dVar4,local_18,uVar1,uVar2,local_20,uVar3); local_c = 0; } } return local_c; }
60,805
void msgpack23::Packer<false>::pack_type<std::__cxx11::list<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>>>(std::__cxx11::list<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>> const&)
msgpack23/include/msgpack23/msgpack23.h
void pack_type(T const &value) { if (!pack_array_header(value.size())) { throw std::length_error("Collection is too long to be serialized."); } for (auto const &item: value) { pack_type(item); } }
O0
c
void msgpack23::Packer<false>::pack_type<std::__cxx11::list<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>>>(std::__cxx11::list<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>> const&): pushq %rbp movq %rsp, %rbp subq $0x50, %rsp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq -0x8(%rbp), %rax movq %rax, -0x48(%rbp) movq -0x10(%rbp), %rdi callq 0x7aeb0 movq -0x48(%rbp), %rdi movq %rax, %rsi callq 0x26980 testb $0x1, %al jne 0x7ae41 movl $0x10, %edi callq 0x16280 movq %rax, %rdi movq %rdi, %rax movq %rax, -0x50(%rbp) leaq 0x53398(%rip), %rsi # 0xce1a4 callq 0x166e0 jmp 0x7ae13 movq -0x50(%rbp), %rdi movq 0xbb172(%rip), %rsi # 0x135f90 movq 0xbb10b(%rip), %rdx # 0x135f30 callq 0x16aa0 movq -0x50(%rbp), %rdi movq %rax, %rcx movl %edx, %eax movq %rcx, -0x18(%rbp) movl %eax, -0x1c(%rbp) callq 0x163d0 jmp 0x7aea3 movq -0x10(%rbp), %rax movq %rax, -0x28(%rbp) movq -0x28(%rbp), %rdi callq 0x7aee0 movq %rax, -0x30(%rbp) movq -0x28(%rbp), %rdi callq 0x7af10 movq %rax, -0x38(%rbp) leaq -0x30(%rbp), %rdi leaq -0x38(%rbp), %rsi callq 0x7af40 xorb $-0x1, %al testb $0x1, %al jne 0x7ae78 jmp 0x7ae9d leaq -0x30(%rbp), %rdi callq 0x7af70 movq -0x48(%rbp), %rdi movq %rax, -0x40(%rbp) movq -0x40(%rbp), %rsi callq 0x3a200 leaq -0x30(%rbp), %rdi callq 0x7afa0 jmp 0x7ae63 addq $0x50, %rsp popq %rbp retq movq -0x18(%rbp), %rdi callq 0x16af0 nopl (%rax)
_ZN9msgpack236PackerILb0EE9pack_typeITkNS_14CollectionLikeENSt7__cxx114listINS3_12basic_stringIcSt11char_traitsIcESaIcEEESaIS9_EEEQaant7MapLikeITL0__Ent8EnumLikeISC_EEEvRKT_: push rbp mov rbp, rsp sub rsp, 50h mov [rbp+var_8], rdi mov [rbp+var_10], rsi mov rax, [rbp+var_8] mov [rbp+var_48], rax mov rdi, [rbp+var_10] call _ZNKSt7__cxx114listINS_12basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE4sizeEv; std::list<std::string>::size(void) mov rdi, [rbp+var_48] mov rsi, rax call _ZN9msgpack236PackerILb0EE17pack_array_headerEm; msgpack23::Packer<false>::pack_array_header(ulong) test al, 1 jnz short loc_7AE41 mov edi, 10h; thrown_size call ___cxa_allocate_exception mov rdi, rax; this mov rax, rdi mov [rbp+var_50], rax lea rsi, aCollectionIsTo; "Collection is too long to be serialized"... call __ZNSt12length_errorC1EPKc; std::length_error::length_error(char const*) jmp short $+2 loc_7AE13: mov rdi, [rbp+var_50]; void * mov rsi, cs:lptinfo; lptinfo mov rdx, cs:_ZNSt12length_errorD1Ev_ptr; void (*)(void *) call ___cxa_throw mov rdi, [rbp+var_50]; void * mov rcx, rax mov eax, edx mov [rbp+var_18], rcx mov [rbp+var_1C], eax call ___cxa_free_exception jmp short loc_7AEA3 loc_7AE41: mov rax, [rbp+var_10] mov [rbp+var_28], rax mov rdi, [rbp+var_28] call _ZNKSt7__cxx114listINS_12basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE5beginEv; std::list<std::string>::begin(void) mov [rbp+var_30], rax mov rdi, [rbp+var_28] call _ZNKSt7__cxx114listINS_12basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE3endEv; std::list<std::string>::end(void) mov [rbp+var_38], rax loc_7AE63: lea rdi, [rbp+var_30] lea rsi, [rbp+var_38] call _ZSteqRKSt20_List_const_iteratorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEES8_; std::operator==(std::_List_const_iterator<std::string> const&,std::_List_const_iterator<std::string> const&) xor al, 0FFh test al, 1 jnz short loc_7AE78 jmp short loc_7AE9D loc_7AE78: lea rdi, [rbp+var_30] call _ZNKSt20_List_const_iteratorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEdeEv; std::_List_const_iterator<std::string>::operator*(void) mov rdi, [rbp+var_48] mov [rbp+var_40], rax mov rsi, [rbp+var_40] call _ZN9msgpack236PackerILb0EE9pack_typeERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; msgpack23::Packer<false>::pack_type(std::string const&) lea rdi, [rbp+var_30] call _ZNSt20_List_const_iteratorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEppEv; std::_List_const_iterator<std::string>::operator++(void) jmp short loc_7AE63 loc_7AE9D: add rsp, 50h pop rbp retn loc_7AEA3: mov rdi, [rbp+var_18] call __Unwind_Resume
char ZN9msgpack236PackerILb0EE9pack_typeITkNS_14CollectionLikeENSt7__cxx114listINS3_12basic_stringIcSt11char_traitsIcESaIcEEESaIS9_EEEQaant7MapLikeITL0__Ent8EnumLikeISC_EEEvRKT_( long long a1, long long a2) { unsigned long long v2; // rsi char result; // al long long v4; // rsi std::length_error *exception; // [rsp+0h] [rbp-50h] long long v6; // [rsp+18h] [rbp-38h] BYREF _QWORD v7[2]; // [rsp+20h] [rbp-30h] BYREF long long v8; // [rsp+40h] [rbp-10h] long long v9; // [rsp+48h] [rbp-8h] v9 = a1; v8 = a2; v2 = std::list<std::string>::size(a2); if ( (msgpack23::Packer<false>::pack_array_header(a1, v2) & 1) == 0 ) { exception = (std::length_error *)__cxa_allocate_exception(0x10uLL); std::length_error::length_error(exception, "Collection is too long to be serialized."); __cxa_throw( exception, (struct type_info *)&`typeinfo for'std::length_error, (void (*)(void *))&std::length_error::~length_error); } v7[1] = v8; v7[0] = std::list<std::string>::begin(v8); v6 = std::list<std::string>::end(v8); while ( 1 ) { result = ~(unsigned __int8)std::operator==(v7, &v6); if ( (result & 1) == 0 ) break; v4 = std::_List_const_iterator<std::string>::operator*(v7); msgpack23::Packer<false>::pack_type(a1, v4); std::_List_const_iterator<std::string>::operator++(v7); } return result; }
_ZN9msgpack236PackerILb0EE9pack_typeITkNS_14CollectionLikeENSt7__cxx114listINS3_12basic_stringIcSt11char_traitsIcESaIcEEESaIS9_EEEQaant7MapLikeITL0__Ent8EnumLikeISC_EEEvRKT_: PUSH RBP MOV RBP,RSP SUB RSP,0x50 MOV qword ptr [RBP + -0x8],RDI MOV qword ptr [RBP + -0x10],RSI MOV RAX,qword ptr [RBP + -0x8] MOV qword ptr [RBP + -0x48],RAX MOV RDI,qword ptr [RBP + -0x10] CALL 0x0017aeb0 MOV RDI,qword ptr [RBP + -0x48] MOV RSI,RAX CALL 0x00126980 TEST AL,0x1 JNZ 0x0017ae41 MOV EDI,0x10 CALL 0x00116280 MOV RDI,RAX MOV RAX,RDI MOV qword ptr [RBP + -0x50],RAX LAB_0017ae05: LEA RSI,[0x1ce1a4] CALL 0x001166e0 LAB_0017ae11: JMP 0x0017ae13 LAB_0017ae13: MOV RDI,qword ptr [RBP + -0x50] MOV RSI,qword ptr [0x00235f90] MOV RDX,qword ptr [0x00235f30] CALL 0x00116aa0 LAB_0017ae41: MOV RAX,qword ptr [RBP + -0x10] MOV qword ptr [RBP + -0x28],RAX MOV RDI,qword ptr [RBP + -0x28] CALL 0x0017aee0 MOV qword ptr [RBP + -0x30],RAX MOV RDI,qword ptr [RBP + -0x28] CALL 0x0017af10 MOV qword ptr [RBP + -0x38],RAX LAB_0017ae63: LEA RDI,[RBP + -0x30] LEA RSI,[RBP + -0x38] CALL 0x0017af40 XOR AL,0xff TEST AL,0x1 JNZ 0x0017ae78 JMP 0x0017ae9d LAB_0017ae78: LEA RDI,[RBP + -0x30] CALL 0x0017af70 MOV RDI,qword ptr [RBP + -0x48] MOV qword ptr [RBP + -0x40],RAX MOV RSI,qword ptr [RBP + -0x40] CALL 0x0013a200 LEA RDI,[RBP + -0x30] CALL 0x0017afa0 JMP 0x0017ae63 LAB_0017ae9d: ADD RSP,0x50 POP RBP RET
void _ZN9msgpack236PackerILb0EE9pack_typeITkNS_14CollectionLikeENSt7__cxx114listINS3_12basic_stringIcSt11char_traitsIcESaIcEEESaIS9_EEEQaant7MapLikeITL0__Ent8EnumLikeISC_EEEvRKT_ (Packer<false> *param_1, list<std::__cxx11::string,std::allocator<std::__cxx11::string>> *param_2) { byte bVar1; ulong uVar2; length_error *this; string *psVar3; int8 local_40; int8 local_38; list<std::__cxx11::string,std::allocator<std::__cxx11::string>> *local_30; list<std::__cxx11::string,std::allocator<std::__cxx11::string>> *local_18; Packer<false> *local_10; local_18 = param_2; local_10 = param_1; uVar2 = std::__cxx11::list<std::__cxx11::string,std::allocator<std::__cxx11::string>>::size (param_2); uVar2 = msgpack23::Packer<false>::pack_array_header(param_1,uVar2); if ((uVar2 & 1) == 0) { this = (length_error *)__cxa_allocate_exception(0x10); /* try { // try from 0017ae05 to 0017ae10 has its CatchHandler @ 0017ae2a */ std::length_error::length_error(this,"Collection is too long to be serialized."); /* WARNING: Subroutine does not return */ __cxa_throw(this,PTR_typeinfo_00235f90,PTR__length_error_00235f30); } local_30 = local_18; local_38 = std::__cxx11::list<std::__cxx11::string,std::allocator<std::__cxx11::string>>::begin (local_18); local_40 = std::__cxx11::list<std::__cxx11::string,std::allocator<std::__cxx11::string>>::end (local_30); while( true ) { bVar1 = std::operator==((_List_const_iterator *)&local_38,(_List_const_iterator *)&local_40); if (((bVar1 ^ 0xff) & 1) == 0) break; psVar3 = (string *) std::_List_const_iterator<std::__cxx11::string>::operator* ((_List_const_iterator<std::__cxx11::string> *)&local_38); msgpack23::Packer<false>::pack_type(param_1,psVar3); std::_List_const_iterator<std::__cxx11::string>::operator++ ((_List_const_iterator<std::__cxx11::string> *)&local_38); } return; }
60,806
ByteBufferPositionException::ByteBufferPositionException(bool, unsigned long, unsigned long, unsigned long)
SylCore-WoTLK/src/server/shared/Packets/ByteBuffer.cpp
ByteBufferPositionException::ByteBufferPositionException(bool add, std::size_t pos, std::size_t size, std::size_t valueSize) { std::ostringstream ss; ss << "Attempted to " << (add ? "put" : "get") << " value with size: " << valueSize << " in ByteBuffer (pos: " << pos << " size: " << size << ")"; message().assign(ss.str()); }
O0
cpp
ByteBufferPositionException::ByteBufferPositionException(bool, unsigned long, unsigned long, unsigned long): subq $0x228, %rsp # imm = 0x228 movb %sil, %al movq %rdi, 0x220(%rsp) andb $0x1, %al movb %al, 0x21f(%rsp) movq %rdx, 0x210(%rsp) movq %rcx, 0x208(%rsp) movq %r8, 0x200(%rsp) movq 0x220(%rsp), %rdi movq %rdi, 0x50(%rsp) callq 0x859b0 movq 0x50(%rsp), %rax leaq 0x339b3f(%rip), %rcx # 0x3ce6b0 movq %rcx, (%rax) leaq 0x88(%rsp), %rdi callq 0x22570 jmp 0x94b83 leaq 0x281ee6(%rip), %rsi # 0x316a70 leaq 0x88(%rsp), %rdi callq 0x21b70 movq %rax, 0x48(%rsp) jmp 0x94b9e testb $0x1, 0x21f(%rsp) je 0x94bb6 leaq 0x281ecf(%rip), %rax # 0x316a7e movq %rax, 0x40(%rsp) jmp 0x94bc4 leaq 0x28155d(%rip), %rax # 0x31611a movq %rax, 0x40(%rsp) jmp 0x94bc4 movq 0x48(%rsp), %rdi movq 0x40(%rsp), %rsi callq 0x21b70 movq %rax, 0x38(%rsp) jmp 0x94bda movq 0x38(%rsp), %rdi leaq 0x281e9c(%rip), %rsi # 0x316a82 callq 0x21b70 movq %rax, 0x30(%rsp) jmp 0x94bf2 movq 0x30(%rsp), %rdi movq 0x200(%rsp), %rsi callq 0x227e0 movq %rax, 0x28(%rsp) jmp 0x94c0b movq 0x28(%rsp), %rdi leaq 0x281e7e(%rip), %rsi # 0x316a95 callq 0x21b70 movq %rax, 0x20(%rsp) jmp 0x94c23 movq 0x20(%rsp), %rdi movq 0x210(%rsp), %rsi callq 0x227e0 movq %rax, 0x18(%rsp) jmp 0x94c3c movq 0x18(%rsp), %rdi leaq 0x281e45(%rip), %rsi # 0x316a8d callq 0x21b70 movq %rax, 0x10(%rsp) jmp 0x94c54 movq 0x10(%rsp), %rdi movq 0x208(%rsp), %rsi callq 0x227e0 movq %rax, 0x8(%rsp) jmp 0x94c6d movq 0x8(%rsp), %rdi leaq 0x293e79(%rip), %rsi # 0x328af2 callq 0x21b70 jmp 0x94c80 movq 0x50(%rsp), %rdi callq 0x97850 movq %rax, (%rsp) leaq 0x58(%rsp), %rdi leaq 0x88(%rsp), %rsi callq 0x21f10 jmp 0x94ca2 movq (%rsp), %rdi leaq 0x58(%rsp), %rsi callq 0x97860 leaq 0x58(%rsp), %rdi callq 0x2de90 leaq 0x88(%rsp), %rdi callq 0x223a0 addq $0x228, %rsp # imm = 0x228 retq movq %rax, %rcx movl %edx, %eax movq %rcx, 0x80(%rsp) movl %eax, 0x7c(%rsp) jmp 0x94d00 movq %rax, %rcx movl %edx, %eax movq %rcx, 0x80(%rsp) movl %eax, 0x7c(%rsp) leaq 0x88(%rsp), %rdi callq 0x223a0 movq 0x50(%rsp), %rdi callq 0x859f0 movq 0x80(%rsp), %rdi callq 0x21d50 nopw (%rax,%rax)
_ZN27ByteBufferPositionExceptionC2Ebmmm: sub rsp, 228h mov al, sil mov [rsp+228h+var_8], rdi and al, 1 mov [rsp+228h+var_9], al mov [rsp+228h+var_18], rdx mov [rsp+228h+var_20], rcx mov [rsp+228h+var_28], r8 mov rdi, [rsp+228h+var_8]; this mov [rsp+228h+var_1D8], rdi call _ZN19ByteBufferExceptionC2Ev; ByteBufferException::ByteBufferException(void) mov rax, [rsp+228h+var_1D8] lea rcx, off_3CE6B0 mov [rax], rcx lea rdi, [rsp+228h+var_1A0] call __ZNSt7__cxx1119basic_ostringstreamIcSt11char_traitsIcESaIcEEC1Ev; std::ostringstream::basic_ostringstream(void) jmp short $+2 loc_94B83: lea rsi, aAttemptedTo; "Attempted to " lea rdi, [rsp+228h+var_1A0] call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*) mov [rsp+228h+var_1E0], rax jmp short $+2 loc_94B9E: test [rsp+228h+var_9], 1 jz short loc_94BB6 lea rax, aPut; "put" mov [rsp+228h+var_1E8], rax jmp short loc_94BC4 loc_94BB6: lea rax, aBadLexicalCast+43h; "get" mov [rsp+228h+var_1E8], rax jmp short $+2 loc_94BC4: mov rdi, [rsp+228h+var_1E0] mov rsi, [rsp+228h+var_1E8] call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*) mov [rsp+228h+var_1F0], rax jmp short $+2 loc_94BDA: mov rdi, [rsp+228h+var_1F0] lea rsi, aValueWithSize; " value with size: " call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*) mov [rsp+228h+var_1F8], rax jmp short $+2 loc_94BF2: mov rdi, [rsp+228h+var_1F8] mov rsi, [rsp+228h+var_28] call __ZNSolsEm; std::ostream::operator<<(ulong) mov [rsp+228h+var_200], rax jmp short $+2 loc_94C0B: mov rdi, [rsp+228h+var_200] lea rsi, aInBytebufferPo; " in ByteBuffer (pos: " call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*) mov [rsp+228h+var_208], rax jmp short $+2 loc_94C23: mov rdi, [rsp+228h+var_208] mov rsi, [rsp+228h+var_18] call __ZNSolsEm; std::ostream::operator<<(ulong) mov [rsp+228h+var_210], rax jmp short $+2 loc_94C3C: mov rdi, [rsp+228h+var_210] lea rsi, aValueWithSize+0Bh; " size: " call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*) mov [rsp+228h+var_218], rax jmp short $+2 loc_94C54: mov rdi, [rsp+228h+var_218] mov rsi, [rsp+228h+var_20] call __ZNSolsEm; std::ostream::operator<<(ulong) mov [rsp+228h+var_220], rax jmp short $+2 loc_94C6D: mov rdi, [rsp+228h+var_220] lea rsi, aItSeemsLikeThe+0A2h; ")" call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*) jmp short $+2 loc_94C80: mov rdi, [rsp+228h+var_1D8] call _ZN19ByteBufferException7messageB5cxx11Ev; ByteBufferException::message(void) mov [rsp+228h+var_228], rax lea rdi, [rsp+228h+var_1D0] lea rsi, [rsp+228h+var_1A0] call __ZNKRSt7__cxx1119basic_ostringstreamIcSt11char_traitsIcESaIcEE3strEv; std::ostringstream::str(void) jmp short $+2 loc_94CA2: mov rdi, [rsp+228h+var_228] lea rsi, [rsp+228h+var_1D0] call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6assignEOS4_; std::string::assign(std::string&&) lea rdi, [rsp+228h+var_1D0]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() lea rdi, [rsp+228h+var_1A0] call __ZNSt7__cxx1119basic_ostringstreamIcSt11char_traitsIcESaIcEED1Ev; std::ostringstream::~ostringstream() add rsp, 228h retn mov rcx, rax mov eax, edx mov [rsp+arg_78], rcx mov [rsp+arg_74], eax jmp short loc_94D00 mov rcx, rax mov eax, edx mov [rsp+arg_78], rcx mov [rsp+arg_74], eax lea rdi, [rsp+arg_80] call __ZNSt7__cxx1119basic_ostringstreamIcSt11char_traitsIcESaIcEED1Ev; std::ostringstream::~ostringstream() loc_94D00: mov rdi, [rsp+arg_48]; void * call _ZN19ByteBufferExceptionD2Ev; ByteBufferException::~ByteBufferException() mov rdi, [rsp+arg_78] call __Unwind_Resume
void ByteBufferPositionException::ByteBufferPositionException( ByteBufferPositionException *this, char a2, long long a3, long long a4, long long a5) { long long v5; // rax long long v6; // [rsp+0h] [rbp-228h] long long v7; // [rsp+8h] [rbp-220h] long long v8; // [rsp+10h] [rbp-218h] long long v9; // [rsp+18h] [rbp-210h] long long v10; // [rsp+20h] [rbp-208h] long long v11; // [rsp+28h] [rbp-200h] long long v12; // [rsp+30h] [rbp-1F8h] long long v13; // [rsp+48h] [rbp-1E0h] _BYTE v14[48]; // [rsp+58h] [rbp-1D0h] BYREF _BYTE v15[376]; // [rsp+88h] [rbp-1A0h] BYREF long long v16; // [rsp+200h] [rbp-28h] long long v17; // [rsp+208h] [rbp-20h] long long v18; // [rsp+210h] [rbp-18h] char v19; // [rsp+21Fh] [rbp-9h] ByteBufferException *v20; // [rsp+220h] [rbp-8h] v20 = this; v19 = a2 & 1; v18 = a3; v17 = a4; v16 = a5; ByteBufferException::ByteBufferException(this); *(_QWORD *)this = off_3CE6B0; std::ostringstream::basic_ostringstream(v15); v13 = std::operator<<<std::char_traits<char>>(v15, "Attempted to "); if ( (v19 & 1) != 0 ) v5 = std::operator<<<std::char_traits<char>>(v13, "put"); else v5 = std::operator<<<std::char_traits<char>>(v13, "get"); v12 = std::operator<<<std::char_traits<char>>(v5, " value with size: "); v11 = std::ostream::operator<<(v12, v16); v10 = std::operator<<<std::char_traits<char>>(v11, " in ByteBuffer (pos: "); v9 = std::ostream::operator<<(v10, v18); v8 = std::operator<<<std::char_traits<char>>(v9, " size: "); v7 = std::ostream::operator<<(v8, v17); std::operator<<<std::char_traits<char>>(v7, ")"); v6 = ByteBufferException::message[abi:cxx11](this); std::ostringstream::str(v14, v15); std::string::assign(v6, v14); std::string::~string(v14); std::ostringstream::~ostringstream(v15); }
ByteBufferPositionException: SUB RSP,0x228 MOV AL,SIL MOV qword ptr [RSP + 0x220],RDI AND AL,0x1 MOV byte ptr [RSP + 0x21f],AL MOV qword ptr [RSP + 0x210],RDX MOV qword ptr [RSP + 0x208],RCX MOV qword ptr [RSP + 0x200],R8 MOV RDI,qword ptr [RSP + 0x220] MOV qword ptr [RSP + 0x50],RDI CALL 0x001859b0 MOV RAX,qword ptr [RSP + 0x50] LEA RCX,[0x4ce6b0] MOV qword ptr [RAX],RCX LAB_00194b74: LEA RDI,[RSP + 0x88] CALL 0x00122570 JMP 0x00194b83 LAB_00194b83: LEA RSI,[0x416a70] LEA RDI,[RSP + 0x88] CALL 0x00121b70 MOV qword ptr [RSP + 0x48],RAX JMP 0x00194b9e LAB_00194b9e: TEST byte ptr [RSP + 0x21f],0x1 JZ 0x00194bb6 LEA RAX,[0x416a7e] MOV qword ptr [RSP + 0x40],RAX JMP 0x00194bc4 LAB_00194bb6: LEA RAX,[0x41611a] MOV qword ptr [RSP + 0x40],RAX JMP 0x00194bc4 LAB_00194bc4: MOV RDI,qword ptr [RSP + 0x48] MOV RSI,qword ptr [RSP + 0x40] CALL 0x00121b70 MOV qword ptr [RSP + 0x38],RAX JMP 0x00194bda LAB_00194bda: MOV RDI,qword ptr [RSP + 0x38] LEA RSI,[0x416a82] CALL 0x00121b70 MOV qword ptr [RSP + 0x30],RAX JMP 0x00194bf2 LAB_00194bf2: MOV RDI,qword ptr [RSP + 0x30] MOV RSI,qword ptr [RSP + 0x200] CALL 0x001227e0 MOV qword ptr [RSP + 0x28],RAX JMP 0x00194c0b LAB_00194c0b: MOV RDI,qword ptr [RSP + 0x28] LEA RSI,[0x416a95] CALL 0x00121b70 MOV qword ptr [RSP + 0x20],RAX JMP 0x00194c23 LAB_00194c23: MOV RDI,qword ptr [RSP + 0x20] MOV RSI,qword ptr [RSP + 0x210] CALL 0x001227e0 MOV qword ptr [RSP + 0x18],RAX JMP 0x00194c3c LAB_00194c3c: MOV RDI,qword ptr [RSP + 0x18] LEA RSI,[0x416a8d] CALL 0x00121b70 MOV qword ptr [RSP + 0x10],RAX JMP 0x00194c54 LAB_00194c54: MOV RDI,qword ptr [RSP + 0x10] MOV RSI,qword ptr [RSP + 0x208] CALL 0x001227e0 MOV qword ptr [RSP + 0x8],RAX JMP 0x00194c6d LAB_00194c6d: MOV RDI,qword ptr [RSP + 0x8] LEA RSI,[0x428af2] CALL 0x00121b70 JMP 0x00194c80 LAB_00194c80: MOV RDI,qword ptr [RSP + 0x50] CALL 0x00197850 MOV qword ptr [RSP],RAX LEA RDI,[RSP + 0x58] LEA RSI,[RSP + 0x88] CALL 0x00121f10 LAB_00194ca0: JMP 0x00194ca2 LAB_00194ca2: MOV RDI,qword ptr [RSP] LEA RSI,[RSP + 0x58] CALL 0x00197860 LEA RDI,[RSP + 0x58] CALL 0x0012de90 LEA RDI,[RSP + 0x88] CALL 0x001223a0 ADD RSP,0x228 RET
/* ByteBufferPositionException::ByteBufferPositionException(bool, unsigned long, unsigned long, unsigned long) */ void __thiscall ByteBufferPositionException::ByteBufferPositionException (ByteBufferPositionException *this,bool param_1,ulong param_2,ulong param_3,ulong param_4) { ostream *poVar1; string *this_00; char *local_1e8; string local_1d0 [48]; ostringstream local_1a0 [376]; ulong local_28; ulong local_20; ulong local_18; byte local_9; ByteBufferPositionException *local_8; local_28 = param_4; local_20 = param_3; local_18 = param_2; local_9 = param_1; local_8 = this; ByteBufferException::ByteBufferException((ByteBufferException *)this); *(int ***)this = &PTR__ByteBufferPositionException_004ce6b0; /* try { // try from 00194b74 to 00194b80 has its CatchHandler @ 00194ccf */ std::__cxx11::ostringstream::ostringstream(local_1a0); /* try { // try from 00194b83 to 00194c9f has its CatchHandler @ 00194ce2 */ poVar1 = std::operator<<((ostream *)local_1a0,"Attempted to "); if ((local_9 & 1) == 0) { local_1e8 = "get"; } else { local_1e8 = "put"; } poVar1 = std::operator<<(poVar1,local_1e8); poVar1 = std::operator<<(poVar1," value with size: "); poVar1 = (ostream *)std::ostream::operator<<(poVar1,local_28); poVar1 = std::operator<<(poVar1," in ByteBuffer (pos: "); poVar1 = (ostream *)std::ostream::operator<<(poVar1,local_18); poVar1 = std::operator<<(poVar1," size: "); poVar1 = (ostream *)std::ostream::operator<<(poVar1,local_20); std::operator<<(poVar1,")"); this_00 = (string *)ByteBufferException::message_abi_cxx11_((ByteBufferException *)this); std::__cxx11::ostringstream::str(); std::__cxx11::string::assign(this_00,local_1d0); std::__cxx11::string::~string(local_1d0); std::__cxx11::ostringstream::~ostringstream(local_1a0); return; }
60,807
alloc_free
eloqsql/mysys/lf_alloc-pin.c
static void alloc_free(uchar *first, uchar volatile *last, LF_ALLOCATOR *allocator) { /* we need a union here to access type-punned pointer reliably. otherwise gcc -fstrict-aliasing will not see 'tmp' changed in the loop */ union { uchar * node; void *ptr; } tmp; tmp.node= allocator->top; do { anext_node(last)= tmp.node; } while (!my_atomic_casptr((void **)(char *)&allocator->top, (void **)&tmp.ptr, first) && LF_BACKOFF()); }
O0
c
alloc_free: pushq %rbp movq %rsp, %rbp subq $0x40, %rsp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq %rdx, -0x18(%rbp) movq -0x18(%rbp), %rax movq 0x48(%rax), %rax movq %rax, -0x20(%rbp) movq -0x20(%rbp), %rdx movq -0x10(%rbp), %rax movq -0x18(%rbp), %rcx movl 0x38(%rcx), %ecx movq %rdx, (%rax,%rcx) movq -0x18(%rbp), %rcx movq -0x8(%rbp), %rax movq %rax, -0x28(%rbp) movq -0x20(%rbp), %rax movq -0x28(%rbp), %rdx lock cmpxchgq %rdx, 0x48(%rcx) movq %rax, %rcx sete %al movb %al, -0x39(%rbp) movq %rcx, -0x38(%rbp) testb $0x1, %al jne 0xfdc36 movq -0x38(%rbp), %rax movq %rax, -0x20(%rbp) movb -0x39(%rbp), %al andb $0x1, %al movb %al, -0x29(%rbp) xorl %eax, %eax testb $0x1, -0x29(%rbp) movb %al, -0x3a(%rbp) jne 0xfdc57 callq 0xfde20 cmpl $0x0, %eax setne %al movb %al, -0x3a(%rbp) movb -0x3a(%rbp), %al testb $0x1, %al jne 0xfdbf0 addq $0x40, %rsp popq %rbp retq nopw %cs:(%rax,%rax)
alloc_free: push rbp mov rbp, rsp sub rsp, 40h mov [rbp+var_8], rdi mov [rbp+var_10], rsi mov [rbp+var_18], rdx mov rax, [rbp+var_18] mov rax, [rax+48h] mov [rbp+var_20], rax loc_FDBF0: mov rdx, [rbp+var_20] mov rax, [rbp+var_10] mov rcx, [rbp+var_18] mov ecx, [rcx+38h] mov [rax+rcx], rdx mov rcx, [rbp+var_18] mov rax, [rbp+var_8] mov [rbp+var_28], rax mov rax, [rbp+var_20] mov rdx, [rbp+var_28] lock cmpxchg [rcx+48h], rdx mov rcx, rax setz al mov [rbp+var_39], al mov [rbp+var_38], rcx test al, 1 jnz short loc_FDC36 mov rax, [rbp+var_38] mov [rbp+var_20], rax loc_FDC36: mov al, [rbp+var_39] and al, 1 mov [rbp+var_29], al xor eax, eax test [rbp+var_29], 1 mov [rbp+var_3A], al jnz short loc_FDC57 call LF_BACKOFF cmp eax, 0 setnz al mov [rbp+var_3A], al loc_FDC57: mov al, [rbp+var_3A] test al, 1 jnz short loc_FDBF0 add rsp, 40h pop rbp retn
bool alloc_free(signed long long a1, long long a2, long long a3) { signed long long v3; // rcx bool result; // al bool v5; // [rsp+6h] [rbp-3Ah] bool v6; // [rsp+7h] [rbp-39h] signed long long v7; // [rsp+20h] [rbp-20h] v7 = *(_QWORD *)(a3 + 72); do { *(_QWORD *)(a2 + *(unsigned int *)(a3 + 56)) = v7; v3 = _InterlockedCompareExchange64((volatile signed long long *)(a3 + 72), a1, v7); v6 = v7 == v3; if ( v7 != v3 ) v7 = v3; v5 = 0; if ( !v6 ) v5 = (unsigned int)LF_BACKOFF() != 0; result = v5; } while ( v5 ); return result; }
alloc_free: PUSH RBP MOV RBP,RSP SUB RSP,0x40 MOV qword ptr [RBP + -0x8],RDI MOV qword ptr [RBP + -0x10],RSI MOV qword ptr [RBP + -0x18],RDX MOV RAX,qword ptr [RBP + -0x18] MOV RAX,qword ptr [RAX + 0x48] MOV qword ptr [RBP + -0x20],RAX LAB_001fdbf0: MOV RDX,qword ptr [RBP + -0x20] MOV RAX,qword ptr [RBP + -0x10] MOV RCX,qword ptr [RBP + -0x18] MOV ECX,dword ptr [RCX + 0x38] MOV qword ptr [RAX + RCX*0x1],RDX MOV RCX,qword ptr [RBP + -0x18] MOV RAX,qword ptr [RBP + -0x8] MOV qword ptr [RBP + -0x28],RAX MOV RAX,qword ptr [RBP + -0x20] MOV RDX,qword ptr [RBP + -0x28] CMPXCHG.LOCK qword ptr [RCX + 0x48],RDX MOV RCX,RAX SETZ AL MOV byte ptr [RBP + -0x39],AL MOV qword ptr [RBP + -0x38],RCX TEST AL,0x1 JNZ 0x001fdc36 MOV RAX,qword ptr [RBP + -0x38] MOV qword ptr [RBP + -0x20],RAX LAB_001fdc36: MOV AL,byte ptr [RBP + -0x39] AND AL,0x1 MOV byte ptr [RBP + -0x29],AL XOR EAX,EAX TEST byte ptr [RBP + -0x29],0x1 MOV byte ptr [RBP + -0x3a],AL JNZ 0x001fdc57 CALL 0x001fde20 CMP EAX,0x0 SETNZ AL MOV byte ptr [RBP + -0x3a],AL LAB_001fdc57: MOV AL,byte ptr [RBP + -0x3a] TEST AL,0x1 JNZ 0x001fdbf0 ADD RSP,0x40 POP RBP RET
void alloc_free(long param_1,long param_2,long param_3) { int iVar1; long lVar2; bool bVar3; bool bVar4; int8 local_28; local_28 = *(long *)(param_3 + 0x48); do { *(long *)(param_2 + (ulong)*(uint *)(param_3 + 0x38)) = local_28; LOCK(); lVar2 = *(long *)(param_3 + 0x48); bVar3 = local_28 == lVar2; if (bVar3) { *(long *)(param_3 + 0x48) = param_1; lVar2 = local_28; } UNLOCK(); if (!bVar3) { local_28 = lVar2; } bVar4 = false; if (!bVar3) { iVar1 = LF_BACKOFF(); bVar4 = iVar1 != 0; } } while (bVar4); return; }
60,808
get_collation_number_internal
eloqsql/mysys/charset.c
static uint get_collation_number_internal(const char *name) { CHARSET_INFO **cs; for (cs= all_charsets; cs < all_charsets + array_elements(all_charsets); cs++) { if (cs[0] && cs[0]->coll_name.str && !my_strcasecmp(&my_charset_latin1, cs[0]->coll_name.str, name)) return cs[0]->number; } return 0; }
O0
c
get_collation_number_internal: pushq %rbp movq %rsp, %rbp subq $0x20, %rsp movq %rdi, -0x10(%rbp) leaq 0x35c42d(%rip), %rax # 0x384420 movq %rax, -0x18(%rbp) leaq 0x35c422(%rip), %rax # 0x384420 addq $0x4000, %rax # imm = 0x4000 cmpq %rax, -0x18(%rbp) jae 0x2806f movq -0x18(%rbp), %rax cmpq $0x0, (%rax) je 0x2805f movq -0x18(%rbp), %rax movq (%rax), %rax cmpq $0x0, 0x20(%rax) je 0x2805f leaq 0x24a737(%rip), %rax # 0x272760 movq 0xc0(%rax), %rax movq 0x40(%rax), %rax movq -0x18(%rbp), %rcx movq (%rcx), %rcx movq 0x20(%rcx), %rsi movq -0x10(%rbp), %rdx leaq 0x24a716(%rip), %rdi # 0x272760 callq *%rax cmpl $0x0, %eax jne 0x2805f movq -0x18(%rbp), %rax movq (%rax), %rax movl (%rax), %eax movl %eax, -0x4(%rbp) jmp 0x28076 jmp 0x28061 movq -0x18(%rbp), %rax addq $0x8, %rax movq %rax, -0x18(%rbp) jmp 0x27ff7 movl $0x0, -0x4(%rbp) movl -0x4(%rbp), %eax addq $0x20, %rsp popq %rbp retq nop
get_collation_number_internal: push rbp mov rbp, rsp sub rsp, 20h mov [rbp+var_10], rdi lea rax, all_charsets mov [rbp+var_18], rax loc_27FF7: lea rax, all_charsets add rax, 4000h cmp [rbp+var_18], rax jnb short loc_2806F mov rax, [rbp+var_18] cmp qword ptr [rax], 0 jz short loc_2805F mov rax, [rbp+var_18] mov rax, [rax] cmp qword ptr [rax+20h], 0 jz short loc_2805F lea rax, my_charset_latin1 mov rax, [rax+0C0h] mov rax, [rax+40h] mov rcx, [rbp+var_18] mov rcx, [rcx] mov rsi, [rcx+20h] mov rdx, [rbp+var_10] lea rdi, my_charset_latin1 call rax cmp eax, 0 jnz short loc_2805F mov rax, [rbp+var_18] mov rax, [rax] mov eax, [rax] mov [rbp+var_4], eax jmp short loc_28076 loc_2805F: jmp short $+2 loc_28061: mov rax, [rbp+var_18] add rax, 8 mov [rbp+var_18], rax jmp short loc_27FF7 loc_2806F: mov [rbp+var_4], 0 loc_28076: mov eax, [rbp+var_4] add rsp, 20h pop rbp retn
long long get_collation_number_internal(long long a1) { unsigned int **i; // [rsp+8h] [rbp-18h] for ( i = (unsigned int **)all_charsets; i < &all_charsets[2048]; ++i ) { if ( *i && *((_QWORD *)*i + 4) && !(*(unsigned int ( **)(void *, _QWORD, long long))(*((_QWORD *)&my_charset_latin1 + 24) + 64LL))( &my_charset_latin1, *((_QWORD *)*i + 4), a1) ) { return **i; } } return 0; }
get_collation_number_internal: PUSH RBP MOV RBP,RSP SUB RSP,0x20 MOV qword ptr [RBP + -0x10],RDI LEA RAX,[0x484420] MOV qword ptr [RBP + -0x18],RAX LAB_00127ff7: LEA RAX,[0x484420] ADD RAX,0x4000 CMP qword ptr [RBP + -0x18],RAX JNC 0x0012806f MOV RAX,qword ptr [RBP + -0x18] CMP qword ptr [RAX],0x0 JZ 0x0012805f MOV RAX,qword ptr [RBP + -0x18] MOV RAX,qword ptr [RAX] CMP qword ptr [RAX + 0x20],0x0 JZ 0x0012805f LEA RAX,[0x372760] MOV RAX,qword ptr [RAX + 0xc0] MOV RAX,qword ptr [RAX + 0x40] MOV RCX,qword ptr [RBP + -0x18] MOV RCX,qword ptr [RCX] MOV RSI,qword ptr [RCX + 0x20] MOV RDX,qword ptr [RBP + -0x10] LEA RDI,[0x372760] CALL RAX CMP EAX,0x0 JNZ 0x0012805f MOV RAX,qword ptr [RBP + -0x18] MOV RAX,qword ptr [RAX] MOV EAX,dword ptr [RAX] MOV dword ptr [RBP + -0x4],EAX JMP 0x00128076 LAB_0012805f: JMP 0x00128061 LAB_00128061: MOV RAX,qword ptr [RBP + -0x18] ADD RAX,0x8 MOV qword ptr [RBP + -0x18],RAX JMP 0x00127ff7 LAB_0012806f: MOV dword ptr [RBP + -0x4],0x0 LAB_00128076: MOV EAX,dword ptr [RBP + -0x4] ADD RSP,0x20 POP RBP RET
int4 get_collation_number_internal(int8 param_1) { int iVar1; long *local_20; local_20 = &all_charsets; while( true ) { if ((long *)0x48841f < local_20) { return 0; } if (((*local_20 != 0) && (*(long *)(*local_20 + 0x20) != 0)) && (iVar1 = (**(code **)(PTR_my_collation_8bit_simple_ci_handler_00372820 + 0x40)) (&my_charset_latin1,*(int8 *)(*local_20 + 0x20),param_1), iVar1 == 0 )) break; local_20 = local_20 + 1; } return *(int4 *)*local_20; }
60,809
strmake
eloqsql/strings/strmake.c
char *strmake(register char *dst, register const char *src, size_t length) { while (length--) { if (! (*dst++ = *src++)) { #ifdef EXTRA_DEBUG /* 'length' is the maximum length of the string; the buffer needs to be one character larger to accommodate the terminating '\0'. This is easy to get wrong, so we make sure we write to the entire length of the buffer to identify incorrect buffer-sizes. We only initialism the "unused" part of the buffer here, a) for efficiency, and b) because dst==src is allowed, so initializing the entire buffer would overwrite the source-string. Also, we write a character rather than '\0' as this makes spotting these problems in the results easier. If we are using purify/valgrind, we only set one character at end to be able to detect also wrong accesses after the end of dst. */ if (length) { #ifdef HAVE_valgrind dst[length-1]= 'Z'; #else bfill(dst, length-1, (int) 'Z'); #endif /* HAVE_valgrind */ } #endif /* EXTRA_DEBUG */ return dst-1; } } *dst=0; return dst; }
O0
c
strmake: pushq %rbp movq %rsp, %rbp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq %rdx, -0x20(%rbp) movq -0x20(%rbp), %rax movq %rax, %rcx addq $-0x1, %rcx movq %rcx, -0x20(%rbp) cmpq $0x0, %rax je 0x7956b movq -0x18(%rbp), %rax movq %rax, %rcx addq $0x1, %rcx movq %rcx, -0x18(%rbp) movb (%rax), %al movq -0x10(%rbp), %rcx movq %rcx, %rdx addq $0x1, %rdx movq %rdx, -0x10(%rbp) movb %al, (%rcx) cmpb $0x0, %al jne 0x79569 movq -0x10(%rbp), %rax addq $-0x1, %rax movq %rax, -0x8(%rbp) jmp 0x7957a jmp 0x79520 movq -0x10(%rbp), %rax movb $0x0, (%rax) movq -0x10(%rbp), %rax movq %rax, -0x8(%rbp) movq -0x8(%rbp), %rax popq %rbp retq
strmake: push rbp mov rbp, rsp mov [rbp+var_10], rdi mov [rbp+var_18], rsi mov [rbp+var_20], rdx loc_79520: mov rax, [rbp+var_20] mov rcx, rax add rcx, 0FFFFFFFFFFFFFFFFh mov [rbp+var_20], rcx cmp rax, 0 jz short loc_7956B mov rax, [rbp+var_18] mov rcx, rax add rcx, 1 mov [rbp+var_18], rcx mov al, [rax] mov rcx, [rbp+var_10] mov rdx, rcx add rdx, 1 mov [rbp+var_10], rdx mov [rcx], al cmp al, 0 jnz short loc_79569 mov rax, [rbp+var_10] add rax, 0FFFFFFFFFFFFFFFFh mov [rbp+var_8], rax jmp short loc_7957A loc_79569: jmp short loc_79520 loc_7956B: mov rax, [rbp+var_10] mov byte ptr [rax], 0 mov rax, [rbp+var_10] mov [rbp+var_8], rax loc_7957A: mov rax, [rbp+var_8] pop rbp retn
_BYTE * strmake(_BYTE *a1, _BYTE *a2, long long a3) { _BYTE *v4; // rax _BYTE *v5; // rcx while ( a3-- ) { v4 = a2++; LOBYTE(v4) = *v4; v5 = a1++; *v5 = (_BYTE)v4; if ( !(_BYTE)v4 ) return a1 - 1; } *a1 = 0; return a1; }
strmake: PUSH RBP MOV RBP,RSP MOV qword ptr [RBP + -0x10],RDI MOV qword ptr [RBP + -0x18],RSI MOV qword ptr [RBP + -0x20],RDX LAB_00179520: MOV RAX,qword ptr [RBP + -0x20] MOV RCX,RAX ADD RCX,-0x1 MOV qword ptr [RBP + -0x20],RCX CMP RAX,0x0 JZ 0x0017956b MOV RAX,qword ptr [RBP + -0x18] MOV RCX,RAX ADD RCX,0x1 MOV qword ptr [RBP + -0x18],RCX MOV AL,byte ptr [RAX] MOV RCX,qword ptr [RBP + -0x10] MOV RDX,RCX ADD RDX,0x1 MOV qword ptr [RBP + -0x10],RDX MOV byte ptr [RCX],AL CMP AL,0x0 JNZ 0x00179569 MOV RAX,qword ptr [RBP + -0x10] ADD RAX,-0x1 MOV qword ptr [RBP + -0x8],RAX JMP 0x0017957a LAB_00179569: JMP 0x00179520 LAB_0017956b: MOV RAX,qword ptr [RBP + -0x10] MOV byte ptr [RAX],0x0 MOV RAX,qword ptr [RBP + -0x10] MOV qword ptr [RBP + -0x8],RAX LAB_0017957a: MOV RAX,qword ptr [RBP + -0x8] POP RBP RET
char * strmake(char *param_1,char *param_2,long param_3) { char cVar1; char *pcVar2; long local_28; char *local_20; char *local_18; local_28 = param_3; local_20 = param_2; pcVar2 = param_1; do { local_18 = pcVar2; if (local_28 == 0) { *local_18 = '\0'; return local_18; } cVar1 = *local_20; *local_18 = cVar1; local_28 = local_28 + -1; local_20 = local_20 + 1; pcVar2 = local_18 + 1; } while (cVar1 != '\0'); return local_18; }
60,810
js_set_module_evaluated
bluesky950520[P]quickjs/quickjs.c
static void js_set_module_evaluated(JSContext *ctx, JSModuleDef *m) { m->status = JS_MODULE_STATUS_EVALUATED; if (!JS_IsUndefined(m->promise)) { JSValue value, ret_val; assert(m->cycle_root == m); value = JS_UNDEFINED; ret_val = JS_Call(ctx, m->resolving_funcs[0], JS_UNDEFINED, 1, (JSValueConst *)&value); JS_FreeValue(ctx, ret_val); } }
O1
c
js_set_module_evaluated: movb $0x5, 0x83(%rsi) cmpl $0x3, 0xc8(%rsi) je 0x451c7 pushq %rbx subq $0x40, %rsp movq %rdi, %rbx xorl %ecx, %ecx leaq 0x30(%rsp), %rdi movl %ecx, (%rdi) movl $0x3, %r8d movq %r8, 0x8(%rdi) movq 0xd0(%rsi), %rax movq 0xd8(%rsi), %rdx movl %ecx, 0x20(%rsp) movq %r8, 0x28(%rsp) movups 0x20(%rsp), %xmm0 movups %xmm0, (%rsp) movq %rdi, 0x10(%rsp) movl $0x2, 0x18(%rsp) movq %rbx, %rdi movq %rax, %rsi xorl %ecx, %ecx movl $0x1, %r9d callq 0x284ca movq 0x18(%rbx), %rdi movq %rax, %rsi callq 0x1d8c6 addq $0x40, %rsp popq %rbx retq
js_set_module_evaluated: mov byte ptr [rsi+83h], 5 cmp dword ptr [rsi+0C8h], 3 jz short locret_451C7 push rbx sub rsp, 40h mov rbx, rdi xor ecx, ecx lea rdi, [rsp+48h+var_18] mov [rdi], ecx mov r8d, 3 mov [rdi+8], r8 mov rax, [rsi+0D0h] mov rdx, [rsi+0D8h] mov dword ptr [rsp+48h+var_28], ecx mov qword ptr [rsp+48h+var_28+8], r8 movups xmm0, [rsp+48h+var_28] movups [rsp+48h+var_48], xmm0 mov [rsp+48h+var_38], rdi mov [rsp+48h+var_30], 2 mov rdi, rbx mov rsi, rax xor ecx, ecx mov r9d, 1 call JS_CallInternal mov rdi, [rbx+18h] mov rsi, rax call JS_FreeValueRT add rsp, 40h pop rbx locret_451C7: retn
void js_set_module_evaluated( long long a1, long long a2, double a3, __m128 a4, __m128 a5, __m128 a6, __m128 a7, __m128 a8, __m128 a9, __m128 a10) { _DWORD *v10; // rax long long v11; // rdx __m128 v12; // [rsp+20h] [rbp-28h] int v13; // [rsp+30h] [rbp-18h] BYREF long long v14; // [rsp+38h] [rbp-10h] *(_BYTE *)(a2 + 131) = 5; if ( *(_DWORD *)(a2 + 200) != 3 ) { v13 = 0; v14 = 3LL; v12.m128_i32[0] = 0; v12.m128_u64[1] = 3LL; v10 = (_DWORD *)JS_CallInternal( a1, *(_QWORD *)(a2 + 208), *(_QWORD *)(a2 + 216), 0LL, 3LL, 1LL, v12, a4, a5, a6, a7, a8, a9, a10, v12.m128_i8[0], 3, (long long)&v13, 2u); JS_FreeValueRT(*(_QWORD *)(a1 + 24), v10, v11); } }
60,811
js_set_module_evaluated
bluesky950520[P]quickjs/quickjs.c
static void js_set_module_evaluated(JSContext *ctx, JSModuleDef *m) { m->status = JS_MODULE_STATUS_EVALUATED; if (!JS_IsUndefined(m->promise)) { JSValue value, ret_val; assert(m->cycle_root == m); value = JS_UNDEFINED; ret_val = JS_Call(ctx, m->resolving_funcs[0], JS_UNDEFINED, 1, (JSValueConst *)&value); JS_FreeValue(ctx, ret_val); } }
O2
c
js_set_module_evaluated: movb $0x5, 0x83(%rsi) cmpl $0x3, 0xc8(%rsi) je 0x3cd98 pushq %rbx subq $0x20, %rsp movq %rdi, %rbx leaq 0x10(%rsp), %rcx andl $0x0, (%rcx) movq $0x3, 0x8(%rcx) movq 0xd0(%rsi), %rax movq 0xd8(%rsi), %rdx movq %rcx, (%rsp) pushq $0x3 popq %r8 pushq $0x1 popq %r9 movq %rax, %rsi xorl %ecx, %ecx callq 0x21eb6 movq %rbx, %rdi movq %rax, %rsi callq 0x1801e addq $0x20, %rsp popq %rbx retq
js_set_module_evaluated: mov byte ptr [rsi+83h], 5 cmp dword ptr [rsi+0C8h], 3 jz short locret_3CD98 push rbx sub rsp, 20h mov rbx, rdi lea rcx, [rsp+28h+var_18] and dword ptr [rcx], 0 mov qword ptr [rcx+8], 3 mov rax, [rsi+0D0h] mov rdx, [rsi+0D8h] mov [rsp+28h+var_28], rcx push 3 pop r8 push 1 pop r9 mov rsi, rax xor ecx, ecx call JS_Call mov rdi, rbx mov rsi, rax call JS_FreeValue add rsp, 20h pop rbx locret_3CD98: retn
void js_set_module_evaluated(long long a1, long long a2) { long long v2; // rax long long v3; // rdx int v4; // [rsp+10h] [rbp-18h] BYREF long long v5; // [rsp+18h] [rbp-10h] *(_BYTE *)(a2 + 131) = 5; if ( *(_DWORD *)(a2 + 200) != 3 ) { v4 = 0; v5 = 3LL; v2 = JS_Call(a1, *(_QWORD *)(a2 + 208), *(_QWORD *)(a2 + 216), 0, 3, 1, (long long)&v4); JS_FreeValue(a1, v2, v3); } }
js_set_module_evaluated: MOV byte ptr [RSI + 0x83],0x5 CMP dword ptr [RSI + 0xc8],0x3 JZ 0x0013cd98 PUSH RBX SUB RSP,0x20 MOV RBX,RDI LEA RCX,[RSP + 0x10] AND dword ptr [RCX],0x0 MOV qword ptr [RCX + 0x8],0x3 MOV RAX,qword ptr [RSI + 0xd0] MOV RDX,qword ptr [RSI + 0xd8] MOV qword ptr [RSP],RCX PUSH 0x3 POP R8 PUSH 0x1 POP R9 MOV RSI,RAX XOR ECX,ECX CALL 0x00121eb6 MOV RDI,RBX MOV RSI,RAX CALL 0x0011801e ADD RSP,0x20 POP RBX LAB_0013cd98: RET
void js_set_module_evaluated(int8 param_1,long param_2) { int8 uVar1; int4 local_18 [2]; int8 local_10; *(int1 *)(param_2 + 0x83) = 5; if (*(int *)(param_2 + 200) != 3) { local_18[0] = 0; local_10 = 3; uVar1 = JS_Call(param_1,*(int8 *)(param_2 + 0xd0),*(int8 *)(param_2 + 0xd8),0,3,1, local_18); JS_FreeValue(param_1,uVar1); } return; }
60,812
my_scan_mb2
eloqsql/strings/ctype-ucs2.c
static size_t my_scan_mb2(CHARSET_INFO *cs __attribute__((unused)), const char *str, const char *end, int sequence_type) { const char *str0= str; my_wc_t wc; my_charset_conv_mb_wc mb_wc= cs->cset->mb_wc; int res; switch (sequence_type) { case MY_SEQ_SPACES: for (res= mb_wc(cs, &wc, (const uchar *) str, (const uchar *) end); res > 0 && wc == ' '; str+= res, res= mb_wc(cs, &wc, (const uchar *) str, (const uchar *) end)) { } return (size_t) (str - str0); case MY_SEQ_NONSPACES: DBUG_ASSERT(0); /* Not implemented */ /* pass through */ default: return 0; } }
O0
c
my_scan_mb2: pushq %rbp movq %rsp, %rbp subq $0x50, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq %rdx, -0x20(%rbp) movl %ecx, -0x24(%rbp) movq -0x18(%rbp), %rax movq %rax, -0x30(%rbp) movq -0x10(%rbp), %rax movq 0xb8(%rax), %rax movq 0x28(%rax), %rax movq %rax, -0x40(%rbp) movl -0x24(%rbp), %eax movl %eax, -0x48(%rbp) subl $0x2, %eax je 0xae3f9 jmp 0xae3ef movl -0x48(%rbp), %eax subl $0x3, %eax je 0xae470 jmp 0xae476 movq -0x40(%rbp), %rax movq -0x10(%rbp), %rdi movq -0x18(%rbp), %rdx movq -0x20(%rbp), %rcx leaq -0x38(%rbp), %rsi callq *%rax movl %eax, -0x44(%rbp) xorl %eax, %eax cmpl $0x0, -0x44(%rbp) movb %al, -0x49(%rbp) jle 0xae428 cmpq $0x20, -0x38(%rbp) sete %al movb %al, -0x49(%rbp) movb -0x49(%rbp), %al testb $0x1, %al jne 0xae431 jmp 0xae45f jmp 0xae433 movl -0x44(%rbp), %ecx movq -0x18(%rbp), %rax movslq %ecx, %rcx addq %rcx, %rax movq %rax, -0x18(%rbp) movq -0x40(%rbp), %rax movq -0x10(%rbp), %rdi movq -0x18(%rbp), %rdx movq -0x20(%rbp), %rcx leaq -0x38(%rbp), %rsi callq *%rax movl %eax, -0x44(%rbp) jmp 0xae412 movq -0x18(%rbp), %rax movq -0x30(%rbp), %rcx subq %rcx, %rax movq %rax, -0x8(%rbp) jmp 0xae47e jmp 0xae472 jmp 0xae474 jmp 0xae476 movq $0x0, -0x8(%rbp) movq -0x8(%rbp), %rax addq $0x50, %rsp popq %rbp retq nopl (%rax,%rax)
my_scan_mb2: push rbp mov rbp, rsp sub rsp, 50h mov [rbp+var_10], rdi mov [rbp+var_18], rsi mov [rbp+var_20], rdx mov [rbp+var_24], ecx mov rax, [rbp+var_18] mov [rbp+var_30], rax mov rax, [rbp+var_10] mov rax, [rax+0B8h] mov rax, [rax+28h] mov [rbp+var_40], rax mov eax, [rbp+var_24] mov [rbp+var_48], eax sub eax, 2 jz short loc_AE3F9 jmp short $+2 loc_AE3EF: mov eax, [rbp+var_48] sub eax, 3 jz short loc_AE470 jmp short loc_AE476 loc_AE3F9: mov rax, [rbp+var_40] mov rdi, [rbp+var_10] mov rdx, [rbp+var_18] mov rcx, [rbp+var_20] lea rsi, [rbp+var_38] call rax mov [rbp+var_44], eax loc_AE412: xor eax, eax cmp [rbp+var_44], 0 mov [rbp+var_49], al jle short loc_AE428 cmp [rbp+var_38], 20h ; ' ' setz al mov [rbp+var_49], al loc_AE428: mov al, [rbp+var_49] test al, 1 jnz short loc_AE431 jmp short loc_AE45F loc_AE431: jmp short $+2 loc_AE433: mov ecx, [rbp+var_44] mov rax, [rbp+var_18] movsxd rcx, ecx add rax, rcx mov [rbp+var_18], rax mov rax, [rbp+var_40] mov rdi, [rbp+var_10] mov rdx, [rbp+var_18] mov rcx, [rbp+var_20] lea rsi, [rbp+var_38] call rax mov [rbp+var_44], eax jmp short loc_AE412 loc_AE45F: mov rax, [rbp+var_18] mov rcx, [rbp+var_30] sub rax, rcx mov [rbp+var_8], rax jmp short loc_AE47E loc_AE470: jmp short $+2 loc_AE472: jmp short $+2 loc_AE474: jmp short $+2 loc_AE476: mov [rbp+var_8], 0 loc_AE47E: mov rax, [rbp+var_8] add rsp, 50h pop rbp retn
long long my_scan_mb2(long long a1, long long a2, long long a3, int a4) { bool v5; // [rsp+7h] [rbp-49h] int i; // [rsp+Ch] [rbp-44h] long long ( *v7)(long long, long long *, long long, long long); // [rsp+10h] [rbp-40h] long long v8; // [rsp+18h] [rbp-38h] BYREF long long v9; // [rsp+20h] [rbp-30h] int v10; // [rsp+2Ch] [rbp-24h] long long v11; // [rsp+30h] [rbp-20h] long long v12; // [rsp+38h] [rbp-18h] long long v13; // [rsp+40h] [rbp-10h] v13 = a1; v12 = a2; v11 = a3; v10 = a4; v9 = a2; v7 = *(long long ( **)(long long, long long *, long long, long long))(*(_QWORD *)(a1 + 184) + 40LL); if ( a4 != 2 ) return 0LL; for ( i = v7(v13, &v8, v12, v11); ; i = v7(v13, &v8, v12, v11) ) { v5 = 0; if ( i > 0 ) v5 = v8 == 32; if ( !v5 ) break; v12 += i; } return v12 - v9; }
my_scan_mb2: PUSH RBP MOV RBP,RSP SUB RSP,0x50 MOV qword ptr [RBP + -0x10],RDI MOV qword ptr [RBP + -0x18],RSI MOV qword ptr [RBP + -0x20],RDX MOV dword ptr [RBP + -0x24],ECX MOV RAX,qword ptr [RBP + -0x18] MOV qword ptr [RBP + -0x30],RAX MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0xb8] MOV RAX,qword ptr [RAX + 0x28] MOV qword ptr [RBP + -0x40],RAX MOV EAX,dword ptr [RBP + -0x24] MOV dword ptr [RBP + -0x48],EAX SUB EAX,0x2 JZ 0x001ae3f9 JMP 0x001ae3ef LAB_001ae3ef: MOV EAX,dword ptr [RBP + -0x48] SUB EAX,0x3 JZ 0x001ae470 JMP 0x001ae476 LAB_001ae3f9: MOV RAX,qword ptr [RBP + -0x40] MOV RDI,qword ptr [RBP + -0x10] MOV RDX,qword ptr [RBP + -0x18] MOV RCX,qword ptr [RBP + -0x20] LEA RSI,[RBP + -0x38] CALL RAX MOV dword ptr [RBP + -0x44],EAX LAB_001ae412: XOR EAX,EAX CMP dword ptr [RBP + -0x44],0x0 MOV byte ptr [RBP + -0x49],AL JLE 0x001ae428 CMP qword ptr [RBP + -0x38],0x20 SETZ AL MOV byte ptr [RBP + -0x49],AL LAB_001ae428: MOV AL,byte ptr [RBP + -0x49] TEST AL,0x1 JNZ 0x001ae431 JMP 0x001ae45f LAB_001ae431: JMP 0x001ae433 LAB_001ae433: MOV ECX,dword ptr [RBP + -0x44] MOV RAX,qword ptr [RBP + -0x18] MOVSXD RCX,ECX ADD RAX,RCX MOV qword ptr [RBP + -0x18],RAX MOV RAX,qword ptr [RBP + -0x40] MOV RDI,qword ptr [RBP + -0x10] MOV RDX,qword ptr [RBP + -0x18] MOV RCX,qword ptr [RBP + -0x20] LEA RSI,[RBP + -0x38] CALL RAX MOV dword ptr [RBP + -0x44],EAX JMP 0x001ae412 LAB_001ae45f: MOV RAX,qword ptr [RBP + -0x18] MOV RCX,qword ptr [RBP + -0x30] SUB RAX,RCX MOV qword ptr [RBP + -0x8],RAX JMP 0x001ae47e LAB_001ae470: JMP 0x001ae472 LAB_001ae472: JMP 0x001ae474 LAB_001ae474: JMP 0x001ae476 LAB_001ae476: MOV qword ptr [RBP + -0x8],0x0 LAB_001ae47e: MOV RAX,qword ptr [RBP + -0x8] ADD RSP,0x50 POP RBP RET
long my_scan_mb2(long param_1,long param_2,int8 param_3,int param_4) { code *pcVar1; int local_4c; long local_40; long local_38; int local_2c; int8 local_28; long local_20; long local_18; long local_10; pcVar1 = *(code **)(*(long *)(param_1 + 0xb8) + 0x28); if (param_4 == 2) { local_38 = param_2; local_2c = param_4; local_28 = param_3; local_20 = param_2; local_18 = param_1; local_4c = (*pcVar1)(param_1,&local_40,param_2,param_3); while (0 < local_4c && local_40 == 0x20) { local_20 = local_20 + local_4c; local_4c = (*pcVar1)(local_18,&local_40,local_20,local_28); } local_10 = local_20 - local_38; } else { local_10 = 0; } return local_10; }
60,813
my_scan_mb2
eloqsql/strings/ctype-ucs2.c
static size_t my_scan_mb2(CHARSET_INFO *cs __attribute__((unused)), const char *str, const char *end, int sequence_type) { const char *str0= str; my_wc_t wc; my_charset_conv_mb_wc mb_wc= cs->cset->mb_wc; int res; switch (sequence_type) { case MY_SEQ_SPACES: for (res= mb_wc(cs, &wc, (const uchar *) str, (const uchar *) end); res > 0 && wc == ' '; str+= res, res= mb_wc(cs, &wc, (const uchar *) str, (const uchar *) end)) { } return (size_t) (str - str0); case MY_SEQ_NONSPACES: DBUG_ASSERT(0); /* Not implemented */ /* pass through */ default: return 0; } }
O3
c
my_scan_mb2: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x18, %rsp cmpl $0x2, %ecx jne 0x7fd40 movq %rdx, %r14 movq %rsi, %r12 movq %rdi, %r15 movq 0xb8(%rdi), %rax movq 0x28(%rax), %rbx leaq -0x38(%rbp), %rsi movq %r12, %rdx movq %r14, %rcx callq *%rbx movq %r12, -0x30(%rbp) testl %eax, %eax jle 0x7fd3a cmpq $0x20, -0x38(%rbp) movq -0x30(%rbp), %r12 jne 0x7fd3a leaq -0x38(%rbp), %r13 movq -0x30(%rbp), %r12 movq %r12, %rcx movl %eax, %r12d addq %rcx, %r12 movq %r15, %rdi movq %r13, %rsi movq %r12, %rdx movq %r14, %rcx callq *%rbx testl %eax, %eax jle 0x7fd3a cmpq $0x20, -0x38(%rbp) je 0x7fd18 subq -0x30(%rbp), %r12 jmp 0x7fd43 xorl %r12d, %r12d movq %r12, %rax addq $0x18, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
my_scan_mb2: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx sub rsp, 18h cmp ecx, 2 jnz short loc_7FD40 mov r14, rdx mov r12, rsi mov r15, rdi mov rax, [rdi+0B8h] mov rbx, [rax+28h] lea rsi, [rbp+var_38] mov rdx, r12 mov rcx, r14 call rbx mov [rbp+var_30], r12 test eax, eax jle short loc_7FD3A cmp [rbp+var_38], 20h ; ' ' mov r12, [rbp+var_30] jnz short loc_7FD3A lea r13, [rbp+var_38] mov r12, [rbp+var_30] loc_7FD18: mov rcx, r12 mov r12d, eax add r12, rcx mov rdi, r15 mov rsi, r13 mov rdx, r12 mov rcx, r14 call rbx test eax, eax jle short loc_7FD3A cmp [rbp+var_38], 20h ; ' ' jz short loc_7FD18 loc_7FD3A: sub r12, [rbp+var_30] jmp short loc_7FD43 loc_7FD40: xor r12d, r12d loc_7FD43: mov rax, r12 add rsp, 18h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
long long my_scan_mb2(long long a1, long long a2, long long a3, int a4) { long long v5; // r12 long long ( *v6)(long long, long long *, long long, long long); // rbx int v7; // eax long long v10; // [rsp+8h] [rbp-38h] BYREF long long v11; // [rsp+10h] [rbp-30h] if ( a4 != 2 ) return 0LL; v5 = a2; v6 = *(long long ( **)(long long, long long *, long long, long long))(*(_QWORD *)(a1 + 184) + 40LL); v7 = v6(a1, &v10, a2, a3); v11 = a2; if ( v7 > 0 ) { v5 = v11; if ( v10 == 32 ) { v5 = v11; do { v5 += (unsigned int)v7; v7 = v6(a1, &v10, v5, a3); } while ( v7 > 0 && v10 == 32 ); } } return v5 - v11; }
my_scan_mb2: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x18 CMP ECX,0x2 JNZ 0x0017fd40 MOV R14,RDX MOV R12,RSI MOV R15,RDI MOV RAX,qword ptr [RDI + 0xb8] MOV RBX,qword ptr [RAX + 0x28] LEA RSI,[RBP + -0x38] MOV RDX,R12 MOV RCX,R14 CALL RBX MOV qword ptr [RBP + -0x30],R12 TEST EAX,EAX JLE 0x0017fd3a CMP qword ptr [RBP + -0x38],0x20 MOV R12,qword ptr [RBP + -0x30] JNZ 0x0017fd3a LEA R13,[RBP + -0x38] MOV R12,qword ptr [RBP + -0x30] LAB_0017fd18: MOV RCX,R12 MOV R12D,EAX ADD R12,RCX MOV RDI,R15 MOV RSI,R13 MOV RDX,R12 MOV RCX,R14 CALL RBX TEST EAX,EAX JLE 0x0017fd3a CMP qword ptr [RBP + -0x38],0x20 JZ 0x0017fd18 LAB_0017fd3a: SUB R12,qword ptr [RBP + -0x30] JMP 0x0017fd43 LAB_0017fd40: XOR R12D,R12D LAB_0017fd43: MOV RAX,R12 ADD RSP,0x18 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
long my_scan_mb2(long param_1,long param_2,int8 param_3,int param_4) { code *pcVar1; uint uVar2; long local_40; long local_38; if (param_4 == 2) { pcVar1 = *(code **)(*(long *)(param_1 + 0xb8) + 0x28); uVar2 = (*pcVar1)(param_1,&local_40,param_2,param_3); local_38 = param_2; if ((0 < (int)uVar2) && (local_40 == 0x20)) { do { param_2 = (ulong)uVar2 + param_2; uVar2 = (*pcVar1)(param_1,&local_40,param_2,param_3); if ((int)uVar2 < 1) break; } while (local_40 == 0x20); } param_2 = param_2 - local_38; } else { param_2 = 0; } return param_2; }
60,814
ftxui::(anonymous namespace)::HBox::ComputeRequirement()
Andrewchistyakov[P]flashcards_lyc/build_O2/_deps/ftxui-src/src/ftxui/dom/hbox.cpp
void ComputeRequirement() override { requirement_.min_x = 0; requirement_.min_y = 0; requirement_.flex_grow_x = 0; requirement_.flex_grow_y = 0; requirement_.flex_shrink_x = 0; requirement_.flex_shrink_y = 0; requirement_.selection = Requirement::NORMAL; for (auto& child : children_) { child->ComputeRequirement(); if (requirement_.selection < child->requirement().selection) { requirement_.selection = child->requirement().selection; requirement_.selected_box = child->requirement().selected_box; requirement_.selected_box.x_min += requirement_.min_x; requirement_.selected_box.x_max += requirement_.min_x; } requirement_.min_x += child->requirement().min_x; requirement_.min_y = std::max(requirement_.min_y, child->requirement().min_y); } }
O2
cpp
ftxui::(anonymous namespace)::HBox::ComputeRequirement(): pushq %r15 pushq %r14 pushq %r12 pushq %rbx pushq %rax movq %rdi, %rbx pxor %xmm0, %xmm0 movdqu %xmm0, 0x2c(%rdi) movdqu %xmm0, 0x20(%rdi) movq 0x8(%rdi), %r14 movq 0x10(%rdi), %r15 leaq 0x3c(%rdi), %r12 cmpq %r15, %r14 je 0x1ecd9 movq (%r14), %rdi movq (%rdi), %rax callq *0x10(%rax) movl 0x20(%rbx), %eax movq (%r14), %rcx movl 0x38(%rcx), %edx cmpl %edx, 0x38(%rbx) jge 0x1ecbf movl %edx, 0x38(%rbx) movups 0x3c(%rcx), %xmm0 movups %xmm0, (%r12) movq 0x3c(%rbx), %xmm0 movd %eax, %xmm1 pshufd $0x50, %xmm1, %xmm1 # xmm1 = xmm1[0,0,1,1] paddd %xmm0, %xmm1 movq %xmm1, 0x3c(%rbx) movq (%r14), %rcx addl 0x20(%rcx), %eax movl %eax, 0x20(%rbx) movl 0x24(%rcx), %eax movl 0x24(%rbx), %ecx cmpl %eax, %ecx cmovgl %ecx, %eax movl %eax, 0x24(%rbx) addq $0x10, %r14 jmp 0x1ec7d addq $0x8, %rsp popq %rbx popq %r12 popq %r14 popq %r15 retq nop
_ZN5ftxui12_GLOBAL__N_14HBox18ComputeRequirementEv: push r15 push r14 push r12 push rbx push rax mov rbx, rdi pxor xmm0, xmm0 movdqu xmmword ptr [rdi+2Ch], xmm0 movdqu xmmword ptr [rdi+20h], xmm0 mov r14, [rdi+8] mov r15, [rdi+10h] lea r12, [rdi+3Ch] loc_1EC7D: cmp r14, r15 jz short loc_1ECD9 mov rdi, [r14] mov rax, [rdi] call qword ptr [rax+10h] mov eax, [rbx+20h] mov rcx, [r14] mov edx, [rcx+38h] cmp [rbx+38h], edx jge short loc_1ECBF mov [rbx+38h], edx movups xmm0, xmmword ptr [rcx+3Ch] movups xmmword ptr [r12], xmm0 movq xmm0, qword ptr [rbx+3Ch] movd xmm1, eax pshufd xmm1, xmm1, 50h ; 'P' paddd xmm1, xmm0 movq qword ptr [rbx+3Ch], xmm1 mov rcx, [r14] loc_1ECBF: add eax, [rcx+20h] mov [rbx+20h], eax mov eax, [rcx+24h] mov ecx, [rbx+24h] cmp ecx, eax cmovg eax, ecx mov [rbx+24h], eax add r14, 10h jmp short loc_1EC7D loc_1ECD9: add rsp, 8 pop rbx pop r12 pop r14 pop r15 retn
long long ftxui::`anonymous namespace'::HBox::ComputeRequirement(ftxui::_anonymous_namespace_::HBox *this) { long long result; // rax _QWORD *v2; // r14 _QWORD *v3; // r15 unsigned int v4; // eax long long v5; // rcx int v6; // edx int v7; // ecx *(_OWORD *)((char *)this + 44) = 0LL; *((_OWORD *)this + 2) = 0LL; v2 = (_QWORD *)*((_QWORD *)this + 1); v3 = (_QWORD *)*((_QWORD *)this + 2); while ( v2 != v3 ) { (*(void ( **)(_QWORD))(*(_QWORD *)*v2 + 16LL))(*v2); v4 = *((_DWORD *)this + 8); v5 = *v2; v6 = *(_DWORD *)(*v2 + 56LL); if ( *((_DWORD *)this + 14) < v6 ) { *((_DWORD *)this + 14) = v6; *(_OWORD *)((char *)this + 60) = *(_OWORD *)(v5 + 60); *(_QWORD *)((char *)this + 60) = _mm_add_epi32( _mm_shuffle_epi32(_mm_cvtsi32_si128(v4), 80), _mm_loadl_epi64((const __m128i *)((char *)this + 60))).m128i_u64[0]; v5 = *v2; } *((_DWORD *)this + 8) = *(_DWORD *)(v5 + 32) + v4; result = *(unsigned int *)(v5 + 36); v7 = *((_DWORD *)this + 9); if ( v7 > (int)result ) result = (unsigned int)v7; *((_DWORD *)this + 9) = result; v2 += 2; } return result; }
ComputeRequirement: PUSH R15 PUSH R14 PUSH R12 PUSH RBX PUSH RAX MOV RBX,RDI PXOR XMM0,XMM0 MOVDQU xmmword ptr [RDI + 0x2c],XMM0 MOVDQU xmmword ptr [RDI + 0x20],XMM0 MOV R14,qword ptr [RDI + 0x8] MOV R15,qword ptr [RDI + 0x10] LEA R12,[RDI + 0x3c] LAB_0011ec7d: CMP R14,R15 JZ 0x0011ecd9 MOV RDI,qword ptr [R14] MOV RAX,qword ptr [RDI] CALL qword ptr [RAX + 0x10] MOV EAX,dword ptr [RBX + 0x20] MOV RCX,qword ptr [R14] MOV EDX,dword ptr [RCX + 0x38] CMP dword ptr [RBX + 0x38],EDX JGE 0x0011ecbf MOV dword ptr [RBX + 0x38],EDX MOVUPS XMM0,xmmword ptr [RCX + 0x3c] MOVUPS xmmword ptr [R12],XMM0 MOVQ XMM0,qword ptr [RBX + 0x3c] MOVD XMM1,EAX PSHUFD XMM1,XMM1,0x50 PADDD XMM1,XMM0 MOVQ qword ptr [RBX + 0x3c],XMM1 MOV RCX,qword ptr [R14] LAB_0011ecbf: ADD EAX,dword ptr [RCX + 0x20] MOV dword ptr [RBX + 0x20],EAX MOV EAX,dword ptr [RCX + 0x24] MOV ECX,dword ptr [RBX + 0x24] CMP ECX,EAX CMOVG EAX,ECX MOV dword ptr [RBX + 0x24],EAX ADD R14,0x10 JMP 0x0011ec7d LAB_0011ecd9: ADD RSP,0x8 POP RBX POP R12 POP R14 POP R15 RET
/* ftxui::(anonymous namespace)::HBox::ComputeRequirement() */ void __thiscall ftxui::(anonymous_namespace)::HBox::ComputeRequirement(HBox *this) { long *plVar1; int8 uVar2; int iVar3; long lVar4; long *plVar5; *(int1 (*) [16])(this + 0x2c) = (int1 [16])0x0; *(int1 (*) [16])(this + 0x20) = (int1 [16])0x0; plVar1 = *(long **)(this + 0x10); for (plVar5 = *(long **)(this + 8); plVar5 != plVar1; plVar5 = plVar5 + 2) { (**(code **)(*(long *)*plVar5 + 0x10))(); iVar3 = *(int *)(this + 0x20); lVar4 = *plVar5; if (*(int *)(this + 0x38) < *(int *)(lVar4 + 0x38)) { *(int *)(this + 0x38) = *(int *)(lVar4 + 0x38); uVar2 = *(int8 *)(lVar4 + 0x44); *(int8 *)(this + 0x3c) = *(int8 *)(lVar4 + 0x3c); *(int8 *)(this + 0x44) = uVar2; *(ulong *)(this + 0x3c) = CONCAT44(iVar3 + (int)((ulong)*(int8 *)(this + 0x3c) >> 0x20), iVar3 + (int)*(int8 *)(this + 0x3c)); lVar4 = *plVar5; } *(int *)(this + 0x20) = iVar3 + *(int *)(lVar4 + 0x20); iVar3 = *(int *)(lVar4 + 0x24); if (*(int *)(lVar4 + 0x24) < *(int *)(this + 0x24)) { iVar3 = *(int *)(this + 0x24); } *(int *)(this + 0x24) = iVar3; } return; }
60,815
common_sampler_sample_and_accept_n(common_sampler*, llama_context*, std::vector<int, std::allocator<int>> const&, bool)
monkey531[P]llama/common/sampling.cpp
std::vector<llama_token> common_sampler_sample_and_accept_n(struct common_sampler * gsmpl, struct llama_context * ctx, const llama_tokens & draft, bool grammar_first) { std::vector<int> idxs(draft.size() + 1); for (size_t i = 0; i < idxs.size(); ++i) { idxs[i] = i; } return common_sampler_sample_and_accept_n(gsmpl, ctx, idxs, draft, grammar_first); }
O1
cpp
common_sampler_sample_and_accept_n(common_sampler*, llama_context*, std::vector<int, std::allocator<int>> const&, bool): pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x28, %rsp movl %r8d, %ebp movq %rcx, %r14 movq %rdx, %r15 movq %rsi, %r12 movq %rdi, %rbx movq 0x8(%rcx), %rsi subq (%rcx), %rsi sarq $0x2, %rsi incq %rsi leaq 0x10(%rsp), %r13 leaq 0xf(%rsp), %rdx movq %r13, %rdi callq 0x7a2ac movq (%r13), %rax movq 0x8(%r13), %rdx subq %rax, %rdx je 0xcfbd6 sarq $0x2, %rdx cmpq $0x1, %rdx adcq $0x0, %rdx leaq 0x1(%rdx), %rcx andq $-0x2, %rcx decq %rdx movq %rdx, %xmm0 pshufd $0x44, %xmm0, %xmm0 # xmm0 = xmm0[0,1,0,1] movdqa 0x1952c(%rip), %xmm1 # 0xe9090 xorl %edx, %edx movdqa 0x19532(%rip), %xmm2 # 0xe90a0 pxor %xmm2, %xmm0 pcmpeqd %xmm3, %xmm3 movdqa 0x286c2(%rip), %xmm4 # 0xf8240 movdqa %xmm1, %xmm5 pxor %xmm2, %xmm5 movdqa %xmm5, %xmm6 pcmpgtd %xmm0, %xmm6 pcmpeqd %xmm0, %xmm5 pshufd $0xf5, %xmm5, %xmm7 # xmm7 = xmm5[1,1,3,3] pand %xmm6, %xmm7 pshufd $0xf5, %xmm6, %xmm5 # xmm5 = xmm6[1,1,3,3] por %xmm7, %xmm5 movd %xmm5, %esi notl %esi testb $0x1, %sil je 0xcfbb3 movl %edx, (%rax,%rdx,4) pxor %xmm3, %xmm5 pextrw $0x4, %xmm5, %esi testb $0x1, %sil je 0xcfbc9 leal 0x1(%rdx), %esi movl %esi, 0x4(%rax,%rdx,4) addq $0x2, %rdx paddq %xmm4, %xmm1 cmpq %rdx, %rcx jne 0xcfb7e movzbl %bpl, %r9d leaq 0x10(%rsp), %rcx movq %rbx, %rdi movq %r12, %rsi movq %r15, %rdx movq %r14, %r8 callq 0xcf955 movq 0x10(%rsp), %rdi testq %rdi, %rdi je 0xcfc07 movq 0x20(%rsp), %rsi subq %rdi, %rsi callq 0x1b8e0 movq %rbx, %rax addq $0x28, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq movq %rax, %rbx movq 0x10(%rsp), %rdi testq %rdi, %rdi je 0xcfc33 movq 0x20(%rsp), %rsi subq %rdi, %rsi callq 0x1b8e0 movq %rbx, %rdi callq 0x1bf90
_Z34common_sampler_sample_and_accept_nP14common_samplerP13llama_contextRKSt6vectorIiSaIiEEb: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 28h mov ebp, r8d mov r14, rcx mov r15, rdx mov r12, rsi mov rbx, rdi mov rsi, [rcx+8] sub rsi, [rcx] sar rsi, 2 inc rsi lea r13, [rsp+58h+var_48] lea rdx, [rsp+58h+var_49] mov rdi, r13 call _ZNSt6vectorIiSaIiEEC2EmRKS0_; std::vector<int>::vector(ulong,std::allocator<int> const&) mov rax, [r13+0] mov rdx, [r13+8] sub rdx, rax jz loc_CFBD6 sar rdx, 2 cmp rdx, 1 adc rdx, 0 lea rcx, [rdx+1] and rcx, 0FFFFFFFFFFFFFFFEh dec rdx movq xmm0, rdx pshufd xmm0, xmm0, 44h ; 'D' movdqa xmm1, cs:xmmword_E9090 xor edx, edx movdqa xmm2, cs:xmmword_E90A0 pxor xmm0, xmm2 pcmpeqd xmm3, xmm3 movdqa xmm4, cs:xmmword_F8240 loc_CFB7E: movdqa xmm5, xmm1 pxor xmm5, xmm2 movdqa xmm6, xmm5 pcmpgtd xmm6, xmm0 pcmpeqd xmm5, xmm0 pshufd xmm7, xmm5, 0F5h pand xmm7, xmm6 pshufd xmm5, xmm6, 0F5h por xmm5, xmm7 movd esi, xmm5 not esi test sil, 1 jz short loc_CFBB3 mov [rax+rdx*4], edx loc_CFBB3: pxor xmm5, xmm3 pextrw esi, xmm5, 4 test sil, 1 jz short loc_CFBC9 lea esi, [rdx+1] mov [rax+rdx*4+4], esi loc_CFBC9: add rdx, 2 paddq xmm1, xmm4 cmp rcx, rdx jnz short loc_CFB7E loc_CFBD6: movzx r9d, bpl lea rcx, [rsp+58h+var_48] mov rdi, rbx mov rsi, r12 mov rdx, r15 mov r8, r14 call _Z34common_sampler_sample_and_accept_nP14common_samplerP13llama_contextRKSt6vectorIiSaIiEES7_b; common_sampler_sample_and_accept_n(common_sampler *,llama_context *,std::vector<int> const&,std::vector<int> const&,bool) mov rdi, [rsp+58h+var_48]; void * test rdi, rdi jz short loc_CFC07 mov rsi, [rsp+58h+var_38] sub rsi, rdi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_CFC07: mov rax, rbx add rsp, 28h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn mov rbx, rax mov rdi, [rsp+arg_8]; void * test rdi, rdi jz short loc_CFC33 mov rsi, [rsp+arg_18] sub rsi, rdi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_CFC33: mov rdi, rbx call __Unwind_Resume
long long * common_sampler_sample_and_accept_n( long long *a1, _QWORD *a2, long long a3, _QWORD *a4, unsigned __int8 a5) { _DWORD *v8; // rax long long v9; // rdx unsigned long long v10; // rcx __m128i v11; // xmm0 __m128i si128; // xmm1 long long v13; // rdx __m128i v14; // xmm2 __m128i v15; // xmm0 __m128i v16; // xmm4 __m128i v17; // xmm5 __m128i v18; // xmm6 __m128i v19; // xmm5 void *v21; // [rsp+10h] [rbp-48h] BYREF _BYTE *v22; // [rsp+18h] [rbp-40h] long long v23; // [rsp+20h] [rbp-38h] std::vector<int>::vector((long long)&v21, ((long long)(a4[1] - *a4) >> 2) + 1); v8 = v21; if ( v22 != v21 ) { v9 = ((v22 - (_BYTE *)v21) >> 2 == 0) + ((v22 - (_BYTE *)v21) >> 2); v10 = (v9 + 1) & 0xFFFFFFFFFFFFFFFELL; v11 = _mm_shuffle_epi32((__m128i)(unsigned long long)(v9 - 1), 68); si128 = _mm_load_si128((const __m128i *)&xmmword_E9090); v13 = 0LL; v14 = _mm_load_si128((const __m128i *)&xmmword_E90A0); v15 = _mm_xor_si128(v11, v14); v16 = _mm_load_si128((const __m128i *)&xmmword_F8240); do { v17 = _mm_xor_si128(si128, v14); v18 = _mm_cmpgt_epi32(v17, v15); v19 = _mm_or_si128( _mm_shuffle_epi32(v18, 245), _mm_and_si128(_mm_shuffle_epi32(_mm_cmpeq_epi32(v17, v15), 245), v18)); if ( (~_mm_cvtsi128_si32(v19) & 1) != 0 ) v8[v13] = v13; if ( (_mm_extract_epi16(_mm_xor_si128(v19, (__m128i)-1LL), 4) & 1) != 0 ) v8[v13 + 1] = v13 + 1; v13 += 2LL; si128 = _mm_add_epi64(si128, v16); } while ( v10 != v13 ); } common_sampler_sample_and_accept_n(a1, a2, a3, &v21, a4, a5); if ( v21 ) operator delete(v21, v23 - (_QWORD)v21); return a1; }
common_sampler_sample_and_accept_n: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x28 MOV EBP,R8D MOV R14,RCX MOV R15,RDX MOV R12,RSI MOV RBX,RDI MOV RSI,qword ptr [RCX + 0x8] SUB RSI,qword ptr [RCX] SAR RSI,0x2 INC RSI LEA R13,[RSP + 0x10] LEA RDX,[RSP + 0xf] MOV RDI,R13 CALL 0x0017a2ac MOV RAX,qword ptr [R13] MOV RDX,qword ptr [R13 + 0x8] SUB RDX,RAX JZ 0x001cfbd6 SAR RDX,0x2 CMP RDX,0x1 ADC RDX,0x0 LEA RCX,[RDX + 0x1] AND RCX,-0x2 DEC RDX MOVQ XMM0,RDX PSHUFD XMM0,XMM0,0x44 MOVDQA XMM1,xmmword ptr [0x001e9090] XOR EDX,EDX MOVDQA XMM2,xmmword ptr [0x001e90a0] PXOR XMM0,XMM2 PCMPEQD XMM3,XMM3 MOVDQA XMM4,xmmword ptr [0x001f8240] LAB_001cfb7e: MOVDQA XMM5,XMM1 PXOR XMM5,XMM2 MOVDQA XMM6,XMM5 PCMPGTD XMM6,XMM0 PCMPEQD XMM5,XMM0 PSHUFD XMM7,XMM5,0xf5 PAND XMM7,XMM6 PSHUFD XMM5,XMM6,0xf5 POR XMM5,XMM7 MOVD ESI,XMM5 NOT ESI TEST SIL,0x1 JZ 0x001cfbb3 MOV dword ptr [RAX + RDX*0x4],EDX LAB_001cfbb3: PXOR XMM5,XMM3 PEXTRW ESI,XMM5,0x4 TEST SIL,0x1 JZ 0x001cfbc9 LEA ESI,[RDX + 0x1] MOV dword ptr [RAX + RDX*0x4 + 0x4],ESI LAB_001cfbc9: ADD RDX,0x2 PADDQ XMM1,XMM4 CMP RCX,RDX JNZ 0x001cfb7e LAB_001cfbd6: MOVZX R9D,BPL LEA RCX,[RSP + 0x10] MOV RDI,RBX MOV RSI,R12 MOV RDX,R15 MOV R8,R14 CALL 0x001cf955 LAB_001cfbf0: MOV RDI,qword ptr [RSP + 0x10] TEST RDI,RDI JZ 0x001cfc07 MOV RSI,qword ptr [RSP + 0x20] SUB RSI,RDI CALL 0x0011b8e0 LAB_001cfc07: MOV RAX,RBX ADD RSP,0x28 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
/* WARNING: Globals starting with '_' overlap smaller symbols at the same address */ /* common_sampler_sample_and_accept_n(common_sampler*, llama_context*, std::vector<int, std::allocator<int> > const&, bool) */ common_sampler * common_sampler_sample_and_accept_n (common_sampler *param_1,llama_context *param_2,vector *param_3,bool param_4) { int1 auVar1 [16]; long lVar2; long lVar3; int7 in_register_00000009; long lVar4; long lVar5; ulong uVar6; int1 auVar7 [16]; int1 auVar8 [16]; int1 auVar9 [16]; void *local_48; long local_40; long local_38; std::vector<int,std::allocator<int>>::vector ((ulong)&local_48, (allocator *) ((((long *)CONCAT71(in_register_00000009,param_4))[1] - *(long *)CONCAT71(in_register_00000009,param_4) >> 2) + 1)); lVar3 = _UNK_001f8248; lVar2 = _DAT_001f8240; auVar1 = _DAT_001e90a0; if (local_40 - (long)local_48 != 0) { lVar4 = local_40 - (long)local_48 >> 2; lVar4 = lVar4 + (ulong)(lVar4 == 0); lVar5 = lVar4 + -1; auVar7._8_4_ = (int)lVar5; auVar7._0_8_ = lVar5; auVar7._12_4_ = (int)((ulong)lVar5 >> 0x20); uVar6 = 0; auVar7 = auVar7 ^ _DAT_001e90a0; auVar8 = _DAT_001e9090; do { auVar9 = auVar8 ^ auVar1; if ((bool)(~(auVar9._4_4_ == auVar7._4_4_ && auVar7._0_4_ < auVar9._0_4_ || auVar7._4_4_ < auVar9._4_4_) & 1)) { *(int *)((long)local_48 + uVar6 * 4) = (int)uVar6; } if ((auVar9._12_4_ != auVar7._12_4_ || auVar9._8_4_ <= auVar7._8_4_) && auVar9._12_4_ <= auVar7._12_4_) { *(int *)((long)local_48 + uVar6 * 4 + 4) = (int)uVar6 + 1; } uVar6 = uVar6 + 2; lVar5 = auVar8._8_8_; auVar8._0_8_ = auVar8._0_8_ + lVar2; auVar8._8_8_ = lVar5 + lVar3; } while ((lVar4 + 1U & 0xfffffffffffffffe) != uVar6); } /* try { // try from 001cfbd6 to 001cfbef has its CatchHandler @ 001cfc19 */ common_sampler_sample_and_accept_n(param_1,param_2,param_3,(vector *)&local_48,param_4); if (local_48 != (void *)0x0) { operator_delete(local_48,local_38 - (long)local_48); } return param_1; }
60,816
common_sampler_sample_and_accept_n(common_sampler*, llama_context*, std::vector<int, std::allocator<int>> const&, bool)
monkey531[P]llama/common/sampling.cpp
std::vector<llama_token> common_sampler_sample_and_accept_n(struct common_sampler * gsmpl, struct llama_context * ctx, const llama_tokens & draft, bool grammar_first) { std::vector<int> idxs(draft.size() + 1); for (size_t i = 0; i < idxs.size(); ++i) { idxs[i] = i; } return common_sampler_sample_and_accept_n(gsmpl, ctx, idxs, draft, grammar_first); }
O3
cpp
common_sampler_sample_and_accept_n(common_sampler*, llama_context*, std::vector<int, std::allocator<int>> const&, bool): pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x28, %rsp movl %r8d, %ebp movq %rcx, %r14 movq %rdx, %r15 movq %rsi, %r12 movq %rdi, %rbx movq 0x8(%rcx), %rsi subq (%rcx), %rsi sarq $0x2, %rsi incq %rsi leaq 0x10(%rsp), %r13 leaq 0xf(%rsp), %rdx movq %r13, %rdi callq 0x7985e movq (%r13), %rax movq 0x8(%r13), %rdx subq %rax, %rdx je 0xce110 sarq $0x2, %rdx cmpq $0x1, %rdx adcq $0x0, %rdx leaq 0x1(%rdx), %rcx andq $-0x2, %rcx decq %rdx movq %rdx, %xmm0 pshufd $0x44, %xmm0, %xmm0 # xmm0 = xmm0[0,1,0,1] movdqa 0x17ff2(%rip), %xmm1 # 0xe6090 xorl %edx, %edx movdqa 0x17ff8(%rip), %xmm2 # 0xe60a0 pxor %xmm2, %xmm0 pcmpeqd %xmm3, %xmm3 movdqa 0x27178(%rip), %xmm4 # 0xf5230 movdqa %xmm1, %xmm5 pxor %xmm2, %xmm5 movdqa %xmm5, %xmm6 pcmpgtd %xmm0, %xmm6 pcmpeqd %xmm0, %xmm5 pshufd $0xf5, %xmm5, %xmm7 # xmm7 = xmm5[1,1,3,3] pand %xmm6, %xmm7 pshufd $0xf5, %xmm6, %xmm5 # xmm5 = xmm6[1,1,3,3] por %xmm7, %xmm5 movd %xmm5, %esi notl %esi testb $0x1, %sil je 0xce0ed movl %edx, (%rax,%rdx,4) pxor %xmm3, %xmm5 pextrw $0x4, %xmm5, %esi testb $0x1, %sil je 0xce103 leal 0x1(%rdx), %esi movl %esi, 0x4(%rax,%rdx,4) addq $0x2, %rdx paddq %xmm4, %xmm1 cmpq %rdx, %rcx jne 0xce0b8 movzbl %bpl, %r9d leaq 0x10(%rsp), %rcx movq %rbx, %rdi movq %r12, %rsi movq %r15, %rdx movq %r14, %r8 callq 0xcde91 movq 0x10(%rsp), %rdi testq %rdi, %rdi je 0xce141 movq 0x20(%rsp), %rsi subq %rdi, %rsi callq 0x1a8e0 movq %rbx, %rax addq $0x28, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq movq %rax, %rbx movq 0x10(%rsp), %rdi testq %rdi, %rdi je 0xce16d movq 0x20(%rsp), %rsi subq %rdi, %rsi callq 0x1a8e0 movq %rbx, %rdi callq 0x1af90
_Z34common_sampler_sample_and_accept_nP14common_samplerP13llama_contextRKSt6vectorIiSaIiEEb: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 28h mov ebp, r8d mov r14, rcx mov r15, rdx mov r12, rsi mov rbx, rdi mov rsi, [rcx+8] sub rsi, [rcx] sar rsi, 2 inc rsi lea r13, [rsp+58h+var_48] lea rdx, [rsp+58h+var_49] mov rdi, r13 call _ZNSt6vectorIiSaIiEEC2EmRKS0_; std::vector<int>::vector(ulong,std::allocator<int> const&) mov rax, [r13+0] mov rdx, [r13+8] sub rdx, rax jz loc_CE110 sar rdx, 2 cmp rdx, 1 adc rdx, 0 lea rcx, [rdx+1] and rcx, 0FFFFFFFFFFFFFFFEh dec rdx movq xmm0, rdx pshufd xmm0, xmm0, 44h ; 'D' movdqa xmm1, cs:xmmword_E6090 xor edx, edx movdqa xmm2, cs:xmmword_E60A0 pxor xmm0, xmm2 pcmpeqd xmm3, xmm3 movdqa xmm4, cs:xmmword_F5230 loc_CE0B8: movdqa xmm5, xmm1 pxor xmm5, xmm2 movdqa xmm6, xmm5 pcmpgtd xmm6, xmm0 pcmpeqd xmm5, xmm0 pshufd xmm7, xmm5, 0F5h pand xmm7, xmm6 pshufd xmm5, xmm6, 0F5h por xmm5, xmm7 movd esi, xmm5 not esi test sil, 1 jz short loc_CE0ED mov [rax+rdx*4], edx loc_CE0ED: pxor xmm5, xmm3 pextrw esi, xmm5, 4 test sil, 1 jz short loc_CE103 lea esi, [rdx+1] mov [rax+rdx*4+4], esi loc_CE103: add rdx, 2 paddq xmm1, xmm4 cmp rcx, rdx jnz short loc_CE0B8 loc_CE110: movzx r9d, bpl lea rcx, [rsp+58h+var_48] mov rdi, rbx mov rsi, r12 mov rdx, r15 mov r8, r14 call _Z34common_sampler_sample_and_accept_nP14common_samplerP13llama_contextRKSt6vectorIiSaIiEES7_b; common_sampler_sample_and_accept_n(common_sampler *,llama_context *,std::vector<int> const&,std::vector<int> const&,bool) mov rdi, [rsp+58h+var_48]; void * test rdi, rdi jz short loc_CE141 mov rsi, [rsp+58h+var_38] sub rsi, rdi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_CE141: mov rax, rbx add rsp, 28h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn mov rbx, rax mov rdi, [rsp+arg_8]; void * test rdi, rdi jz short loc_CE16D mov rsi, [rsp+arg_18] sub rsi, rdi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_CE16D: mov rdi, rbx call __Unwind_Resume
long long * common_sampler_sample_and_accept_n( long long *a1, _QWORD *a2, long long a3, long long *a4, unsigned __int8 a5) { _DWORD *v8; // rax long long v9; // rdx unsigned long long v10; // rcx __m128i v11; // xmm0 __m128i si128; // xmm1 long long v13; // rdx __m128i v14; // xmm2 __m128i v15; // xmm0 __m128i v16; // xmm4 __m128i v17; // xmm5 __m128i v18; // xmm6 __m128i v19; // xmm5 void *v21; // [rsp+10h] [rbp-48h] BYREF _BYTE *v22; // [rsp+18h] [rbp-40h] long long v23; // [rsp+20h] [rbp-38h] std::vector<int>::vector((long long)&v21, ((a4[1] - *a4) >> 2) + 1); v8 = v21; if ( v22 != v21 ) { v9 = ((v22 - (_BYTE *)v21) >> 2 == 0) + ((v22 - (_BYTE *)v21) >> 2); v10 = (v9 + 1) & 0xFFFFFFFFFFFFFFFELL; v11 = _mm_shuffle_epi32((__m128i)(unsigned long long)(v9 - 1), 68); si128 = _mm_load_si128((const __m128i *)&xmmword_E6090); v13 = 0LL; v14 = _mm_load_si128((const __m128i *)&xmmword_E60A0); v15 = _mm_xor_si128(v11, v14); v16 = _mm_load_si128((const __m128i *)&xmmword_F5230); do { v17 = _mm_xor_si128(si128, v14); v18 = _mm_cmpgt_epi32(v17, v15); v19 = _mm_or_si128( _mm_shuffle_epi32(v18, 245), _mm_and_si128(_mm_shuffle_epi32(_mm_cmpeq_epi32(v17, v15), 245), v18)); if ( (~_mm_cvtsi128_si32(v19) & 1) != 0 ) v8[v13] = v13; if ( (_mm_extract_epi16(_mm_xor_si128(v19, (__m128i)-1LL), 4) & 1) != 0 ) v8[v13 + 1] = v13 + 1; v13 += 2LL; si128 = _mm_add_epi64(si128, v16); } while ( v10 != v13 ); } common_sampler_sample_and_accept_n(a1, a2, a3, &v21, a4, a5); if ( v21 ) operator delete(v21, v23 - (_QWORD)v21); return a1; }
common_sampler_sample_and_accept_n: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x28 MOV EBP,R8D MOV R14,RCX MOV R15,RDX MOV R12,RSI MOV RBX,RDI MOV RSI,qword ptr [RCX + 0x8] SUB RSI,qword ptr [RCX] SAR RSI,0x2 INC RSI LEA R13,[RSP + 0x10] LEA RDX,[RSP + 0xf] MOV RDI,R13 CALL 0x0017985e MOV RAX,qword ptr [R13] MOV RDX,qword ptr [R13 + 0x8] SUB RDX,RAX JZ 0x001ce110 SAR RDX,0x2 CMP RDX,0x1 ADC RDX,0x0 LEA RCX,[RDX + 0x1] AND RCX,-0x2 DEC RDX MOVQ XMM0,RDX PSHUFD XMM0,XMM0,0x44 MOVDQA XMM1,xmmword ptr [0x001e6090] XOR EDX,EDX MOVDQA XMM2,xmmword ptr [0x001e60a0] PXOR XMM0,XMM2 PCMPEQD XMM3,XMM3 MOVDQA XMM4,xmmword ptr [0x001f5230] LAB_001ce0b8: MOVDQA XMM5,XMM1 PXOR XMM5,XMM2 MOVDQA XMM6,XMM5 PCMPGTD XMM6,XMM0 PCMPEQD XMM5,XMM0 PSHUFD XMM7,XMM5,0xf5 PAND XMM7,XMM6 PSHUFD XMM5,XMM6,0xf5 POR XMM5,XMM7 MOVD ESI,XMM5 NOT ESI TEST SIL,0x1 JZ 0x001ce0ed MOV dword ptr [RAX + RDX*0x4],EDX LAB_001ce0ed: PXOR XMM5,XMM3 PEXTRW ESI,XMM5,0x4 TEST SIL,0x1 JZ 0x001ce103 LEA ESI,[RDX + 0x1] MOV dword ptr [RAX + RDX*0x4 + 0x4],ESI LAB_001ce103: ADD RDX,0x2 PADDQ XMM1,XMM4 CMP RCX,RDX JNZ 0x001ce0b8 LAB_001ce110: MOVZX R9D,BPL LEA RCX,[RSP + 0x10] MOV RDI,RBX MOV RSI,R12 MOV RDX,R15 MOV R8,R14 CALL 0x001cde91 LAB_001ce12a: MOV RDI,qword ptr [RSP + 0x10] TEST RDI,RDI JZ 0x001ce141 MOV RSI,qword ptr [RSP + 0x20] SUB RSI,RDI CALL 0x0011a8e0 LAB_001ce141: MOV RAX,RBX ADD RSP,0x28 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
/* WARNING: Globals starting with '_' overlap smaller symbols at the same address */ /* common_sampler_sample_and_accept_n(common_sampler*, llama_context*, std::vector<int, std::allocator<int> > const&, bool) */ common_sampler * common_sampler_sample_and_accept_n (common_sampler *param_1,llama_context *param_2,vector *param_3,bool param_4) { int1 auVar1 [16]; long lVar2; long lVar3; int7 in_register_00000009; long lVar4; long lVar5; ulong uVar6; int1 auVar7 [16]; int1 auVar8 [16]; int1 auVar9 [16]; void *local_48; long local_40; long local_38; std::vector<int,std::allocator<int>>::vector ((ulong)&local_48, (allocator *) ((((long *)CONCAT71(in_register_00000009,param_4))[1] - *(long *)CONCAT71(in_register_00000009,param_4) >> 2) + 1)); lVar3 = _UNK_001f5238; lVar2 = _DAT_001f5230; auVar1 = _DAT_001e60a0; if (local_40 - (long)local_48 != 0) { lVar4 = local_40 - (long)local_48 >> 2; lVar4 = lVar4 + (ulong)(lVar4 == 0); lVar5 = lVar4 + -1; auVar7._8_4_ = (int)lVar5; auVar7._0_8_ = lVar5; auVar7._12_4_ = (int)((ulong)lVar5 >> 0x20); uVar6 = 0; auVar7 = auVar7 ^ _DAT_001e60a0; auVar8 = _DAT_001e6090; do { auVar9 = auVar8 ^ auVar1; if ((bool)(~(auVar9._4_4_ == auVar7._4_4_ && auVar7._0_4_ < auVar9._0_4_ || auVar7._4_4_ < auVar9._4_4_) & 1)) { *(int *)((long)local_48 + uVar6 * 4) = (int)uVar6; } if ((auVar9._12_4_ != auVar7._12_4_ || auVar9._8_4_ <= auVar7._8_4_) && auVar9._12_4_ <= auVar7._12_4_) { *(int *)((long)local_48 + uVar6 * 4 + 4) = (int)uVar6 + 1; } uVar6 = uVar6 + 2; lVar5 = auVar8._8_8_; auVar8._0_8_ = auVar8._0_8_ + lVar2; auVar8._8_8_ = lVar5 + lVar3; } while ((lVar4 + 1U & 0xfffffffffffffffe) != uVar6); } /* try { // try from 001ce110 to 001ce129 has its CatchHandler @ 001ce153 */ common_sampler_sample_and_accept_n(param_1,param_2,param_3,(vector *)&local_48,param_4); if (local_48 != (void *)0x0) { operator_delete(local_48,local_38 - (long)local_48); } return param_1; }
60,817
read_line(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&)
ami-iit[P]serial_cpp/src/impl/list_ports/list_ports_linux.cc
string read_line(const string& file) { ifstream ifs(file.c_str(), ifstream::in); string line; if(ifs) { getline(ifs, line); } return line; }
O0
cpp
read_line(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&): pushq %rbp movq %rsp, %rbp subq $0x240, %rsp # imm = 0x240 movq %rdi, -0x238(%rbp) movq %rdi, %rax movq %rax, -0x240(%rbp) movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq -0x10(%rbp), %rdi callq 0x3150 movq %rax, %rsi leaq -0x218(%rbp), %rdi movl $0x8, %edx callq 0x3620 movq -0x238(%rbp), %rdi movb $0x0, -0x219(%rbp) callq 0x34b0 movq -0x218(%rbp), %rax movq -0x18(%rax), %rax leaq -0x218(%rbp,%rax), %rdi callq 0x3430 movb %al, -0x22d(%rbp) jmp 0xe784 movb -0x22d(%rbp), %al testb $0x1, %al jne 0xe790 jmp 0xe7d3 movq -0x238(%rbp), %rsi leaq -0x218(%rbp), %rdi callq 0x30a0 jmp 0xe7a5 jmp 0xe7d3 movq -0x238(%rbp), %rdi movq %rax, %rcx movl %edx, %eax movq %rcx, -0x228(%rbp) movl %eax, -0x22c(%rbp) callq 0x31e0 leaq -0x218(%rbp), %rdi callq 0x30d0 jmp 0xe80b movb $0x1, -0x219(%rbp) testb $0x1, -0x219(%rbp) jne 0xe7ef movq -0x238(%rbp), %rdi callq 0x31e0 leaq -0x218(%rbp), %rdi callq 0x30d0 movq -0x240(%rbp), %rax addq $0x240, %rsp # imm = 0x240 popq %rbp retq movq -0x228(%rbp), %rdi callq 0x35d0 nopw (%rax,%rax)
_ZL9read_lineRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE: push rbp mov rbp, rsp sub rsp, 240h mov [rbp+var_238], rdi mov rax, rdi mov [rbp+var_240], rax mov [rbp+var_8], rdi mov [rbp+var_10], rsi mov rdi, [rbp+var_10] call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5c_strEv; std::string::c_str(void) mov rsi, rax lea rdi, [rbp+var_218] mov edx, 8 call __ZNSt14basic_ifstreamIcSt11char_traitsIcEEC1EPKcSt13_Ios_Openmode; std::ifstream::basic_ifstream(char const*,std::_Ios_Openmode) mov rdi, [rbp+var_238] mov [rbp+var_219], 0 call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC1Ev; std::string::basic_string(void) mov rax, [rbp+var_218] mov rax, [rax-18h] lea rdi, [rbp+rax+var_218] call __ZNKSt9basic_iosIcSt11char_traitsIcEEcvbEv; std::ios::operator bool(void) mov [rbp+var_22D], al jmp short $+2 loc_E784: mov al, [rbp+var_22D] test al, 1 jnz short loc_E790 jmp short loc_E7D3 loc_E790: mov rsi, [rbp+var_238] lea rdi, [rbp+var_218] call __ZSt7getlineIcSt11char_traitsIcESaIcEERSt13basic_istreamIT_T0_ES7_RNSt7__cxx1112basic_stringIS4_S5_T1_EE; std::getline<char,std::char_traits<char>,std::allocator<char>>(std::istream &,std::string &) jmp short $+2 loc_E7A5: jmp short loc_E7D3 mov rdi, [rbp+var_238] mov rcx, rax mov eax, edx mov [rbp+var_228], rcx mov [rbp+var_22C], eax call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string() lea rdi, [rbp+var_218] call __ZNSt14basic_ifstreamIcSt11char_traitsIcEED1Ev; std::ifstream::~ifstream() jmp short loc_E80B loc_E7D3: mov [rbp+var_219], 1 test [rbp+var_219], 1 jnz short loc_E7EF mov rdi, [rbp+var_238] call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string() loc_E7EF: lea rdi, [rbp+var_218] call __ZNSt14basic_ifstreamIcSt11char_traitsIcEED1Ev; std::ifstream::~ifstream() mov rax, [rbp+var_240] add rsp, 240h pop rbp retn loc_E80B: mov rdi, [rbp+var_228] call __Unwind_Resume
long long read_line(long long a1, long long a2) { long long v2; // rax _QWORD v4[67]; // [rsp+28h] [rbp-218h] BYREF v4[66] = a1; v4[65] = a2; v2 = std::string::c_str(a2); std::ifstream::basic_ifstream(v4, v2, 8LL); std::string::basic_string(a1); if ( (std::ios::operator bool((char *)v4 + *(_QWORD *)(v4[0] - 24LL)) & 1) != 0 ) std::getline<char,std::char_traits<char>,std::allocator<char>>(v4, a1); std::ifstream::~ifstream(v4); return a1; }
read_line: PUSH RBP MOV RBP,RSP SUB RSP,0x240 MOV qword ptr [RBP + -0x238],RDI MOV RAX,RDI MOV qword ptr [RBP + -0x240],RAX MOV qword ptr [RBP + -0x8],RDI MOV qword ptr [RBP + -0x10],RSI MOV RDI,qword ptr [RBP + -0x10] CALL 0x00103150 MOV RSI,RAX LEA RDI,[RBP + -0x218] MOV EDX,0x8 CALL 0x00103620 MOV RDI,qword ptr [RBP + -0x238] MOV byte ptr [RBP + -0x219],0x0 CALL 0x001034b0 MOV RAX,qword ptr [RBP + -0x218] MOV RAX,qword ptr [RAX + -0x18] LEA RDI,[RBP + RAX*0x1 + -0x218] LAB_0010e777: CALL 0x00103430 MOV byte ptr [RBP + -0x22d],AL JMP 0x0010e784 LAB_0010e784: MOV AL,byte ptr [RBP + -0x22d] TEST AL,0x1 JNZ 0x0010e790 JMP 0x0010e7d3 LAB_0010e790: MOV RSI,qword ptr [RBP + -0x238] LEA RDI,[RBP + -0x218] CALL 0x001030a0 LAB_0010e7a3: JMP 0x0010e7a5 LAB_0010e7a5: JMP 0x0010e7d3 LAB_0010e7d3: MOV byte ptr [RBP + -0x219],0x1 TEST byte ptr [RBP + -0x219],0x1 JNZ 0x0010e7ef MOV RDI,qword ptr [RBP + -0x238] CALL 0x001031e0 LAB_0010e7ef: LEA RDI,[RBP + -0x218] CALL 0x001030d0 MOV RAX,qword ptr [RBP + -0x240] ADD RSP,0x240 POP RBP RET
/* WARNING: Removing unreachable block (ram,0x0010e7e3) */ /* read_line(std::__cxx11::string const&) */ string * read_line(string *param_1) { bool bVar1; int8 uVar2; long local_220 [66]; string *local_10; local_10 = param_1; uVar2 = std::__cxx11::string::c_str(); std::ifstream::ifstream((ifstream *)local_220,uVar2,8); std::__cxx11::string::string(param_1); /* try { // try from 0010e777 to 0010e7a2 has its CatchHandler @ 0010e7a7 */ bVar1 = std::ios::operator_cast_to_bool ((ios *)((long)local_220 + *(long *)(local_220[0] + -0x18))); if (bVar1) { std::getline<char,std::char_traits<char>,std::allocator<char>>((istream *)local_220,param_1); } std::ifstream::~ifstream((ifstream *)local_220); return param_1; }
60,818
asio::execution::any_executor<asio::execution::context_as_t<asio::execution_context&>, asio::execution::detail::blocking::never_t<0>, asio::execution::prefer_only<asio::execution::detail::blocking::possibly_t<0>>, asio::execution::prefer_only<asio::execution::detail::outstanding_work::tracked_t<0>>, asio::execution::prefer_only<asio::execution::detail::outstanding_work::untracked_t<0>>, asio::execution::prefer_only<asio::execution::detail::relationship::fork_t<0>>, asio::execution::prefer_only<asio::execution::detail::relationship::continuation_t<0>>> asio::execution::detail::any_executor_base::require_fn_impl<asio::execution::any_executor<asio::execution::context_as_t<asio::execution_context&>, asio::execution::detail::blocking::never_t<0>, asio::execution::prefer_only<asio::execution::detail::blocking::possibly_t<0>>, asio::execution::prefer_only<asio::execution::detail::outstanding_work::tracked_t<0>>, asio::execution::prefer_only<asio::execution::detail::outstanding_work::untracked_t<0>>, asio::execution::prefer_only<asio::execution::detail::relationship::fork_t<0>>, asio::execution::prefer_only<asio::execution::detail::relationship::continuation_t<0>>>, asio::io_context::basic_executor_type<std::allocator<void>, 4ul>, asio::execution::detail::blocking::never_t<0>>(void const*, void const*, std::enable_if<!is_same<asio::io_context::basic_executor_type<std::allocator<void>, 4ul>, void>::value && asio::execution::detail::blocking::never_t<0>::is_requirable, void>::type*)
aimrt_mujoco_sim/_deps/asio-src/asio/include/asio/execution/any_executor.hpp
static Poly require_fn_impl(const void* ex, const void* prop, enable_if_t< !is_same<Ex, void>::value && Prop::is_requirable >*) { return asio::require(*static_cast<const Ex*>(ex), *static_cast<const Prop*>(prop)); }
O3
cpp
asio::execution::any_executor<asio::execution::context_as_t<asio::execution_context&>, asio::execution::detail::blocking::never_t<0>, asio::execution::prefer_only<asio::execution::detail::blocking::possibly_t<0>>, asio::execution::prefer_only<asio::execution::detail::outstanding_work::tracked_t<0>>, asio::execution::prefer_only<asio::execution::detail::outstanding_work::untracked_t<0>>, asio::execution::prefer_only<asio::execution::detail::relationship::fork_t<0>>, asio::execution::prefer_only<asio::execution::detail::relationship::continuation_t<0>>> asio::execution::detail::any_executor_base::require_fn_impl<asio::execution::any_executor<asio::execution::context_as_t<asio::execution_context&>, asio::execution::detail::blocking::never_t<0>, asio::execution::prefer_only<asio::execution::detail::blocking::possibly_t<0>>, asio::execution::prefer_only<asio::execution::detail::outstanding_work::tracked_t<0>>, asio::execution::prefer_only<asio::execution::detail::outstanding_work::untracked_t<0>>, asio::execution::prefer_only<asio::execution::detail::relationship::fork_t<0>>, asio::execution::prefer_only<asio::execution::detail::relationship::continuation_t<0>>>, asio::io_context::basic_executor_type<std::allocator<void>, 4ul>, asio::execution::detail::blocking::never_t<0>>(void const*, void const*, std::enable_if<!is_same<asio::io_context::basic_executor_type<std::allocator<void>, 4ul>, void>::value && asio::execution::detail::blocking::never_t<0>::is_requirable, void>::type*): pushq %r14 pushq %rbx subq $0x18, %rsp movq %rdi, %rbx movq (%rsi), %rcx movq %rcx, %rax orq $0x1, %rax movq %rax, 0x8(%rsp) andq $-0x4, %rcx je 0xf9190 movq 0x8(%rcx), %rax lock incq 0xd8(%rax) movq 0x8(%rsp), %rax xorl %ecx, %ecx leaq 0x8(%rsp), %r14 movq %rcx, (%r14) movq 0x1a7e0f(%rip), %rdx # 0x2a0fb0 movq %rdx, 0x28(%rbx) movq 0x1a77dc(%rip), %rdx # 0x2a0988 movq %rdx, 0x18(%rbx) movq %rax, (%rbx) leaq 0x10(%rsp), %rdi movq %rcx, (%rdi) movq %rbx, 0x20(%rbx) callq 0x809b0 movq 0x1a7c3d(%rip), %rax # 0x2a0e08 movq %rax, 0x30(%rbx) movq %r14, %rdi callq 0x809b0 movq %rbx, %rax addq $0x18, %rsp popq %rbx popq %r14 retq
_ZN4asio9execution6detail17any_executor_base15require_fn_implINS0_12any_executorIJNS0_12context_as_tIRNS_17execution_contextEEENS1_8blocking7never_tILi0EEENS0_11prefer_onlyINS9_10possibly_tILi0EEEEENSC_INS1_16outstanding_work9tracked_tILi0EEEEENSC_INSG_11untracked_tILi0EEEEENSC_INS1_12relationship6fork_tILi0EEEEENSC_INSN_14continuation_tILi0EEEEEEEENS_10io_context19basic_executor_typeISaIvELm4EEESB_EET_PKvS11_PNSt9enable_ifIXaantsr7is_sameIT0_vEE5valuesrT1_13is_requirableEvE4typeE: push r14 push rbx sub rsp, 18h mov rbx, rdi mov rcx, [rsi] mov rax, rcx or rax, 1 mov [rsp+28h+var_20], rax and rcx, 0FFFFFFFFFFFFFFFCh jz short loc_F9190 mov rax, [rcx+8] lock inc qword ptr [rax+0D8h] mov rax, [rsp+28h+var_20] loc_F9190: xor ecx, ecx lea r14, [rsp+28h+var_20] mov [r14], rcx mov rdx, cs:_ZZN4asio9execution6detail17any_executor_base16target_fns_tableINS_10io_context19basic_executor_typeISaIvELm4EEEEEPKNS2_10target_fnsEbPNSt9enable_ifIXntsr7is_sameIT_vEE5valueEvE4typeEE16fns_with_execute_ptr mov [rbx+28h], rdx mov rdx, cs:_ZZN4asio9execution6detail17any_executor_base16object_fns_tableINS_10io_context19basic_executor_typeISaIvELm4EEEEEPKNS2_10object_fnsEPNSt9enable_ifIXaantsr7is_sameIT_vEE5valuentsr7is_sameISC_NS1_22shared_target_executorEEE5valueEvE4typeEE3fns_ptr mov [rbx+18h], rdx mov [rbx], rax lea rdi, [rsp+28h+var_18] mov [rdi], rcx mov [rbx+20h], rbx call __ZN4asio10io_context19basic_executor_typeISaIvELm4EED2Ev; asio::io_context::basic_executor_type<std::allocator<void>,4ul>::~basic_executor_type() mov rax, cs:_ZZN4asio9execution12any_executorIJNS0_12context_as_tIRNS_17execution_contextEEENS0_6detail8blocking7never_tILi0EEENS0_11prefer_onlyINS7_10possibly_tILi0EEEEENSA_INS6_16outstanding_work9tracked_tILi0EEEEENSA_INSE_11untracked_tILi0EEEEENSA_INS6_12relationship6fork_tILi0EEEEENSA_INSL_14continuation_tILi0EEEEEEE14prop_fns_tableINS_10io_context19basic_executor_typeISaIvELm4EEEEEPKNS6_17any_executor_base8prop_fnsISS_EEvE3fns_ptr mov [rbx+30h], rax mov rdi, r14 call __ZN4asio10io_context19basic_executor_typeISaIvELm4EED2Ev; asio::io_context::basic_executor_type<std::allocator<void>,4ul>::~basic_executor_type() mov rax, rbx add rsp, 18h pop rbx pop r14 retn
long long * asio::execution::detail::any_executor_base::require_fn_impl<asio::execution::any_executor<asio::execution::context_as_t<asio::execution_context &>,asio::execution::detail::blocking::never_t<0>,asio::execution::prefer_only<asio::execution::detail::blocking::possibly_t<0>>,asio::execution::prefer_only<asio::execution::detail::outstanding_work::tracked_t<0>>,asio::execution::prefer_only<asio::execution::detail::outstanding_work::untracked_t<0>>,asio::execution::prefer_only<asio::execution::detail::relationship::fork_t<0>>,asio::execution::prefer_only<asio::execution::detail::relationship::continuation_t<0>>>,asio::io_context::basic_executor_type<std::allocator<void>,4ul>,asio::execution::detail::blocking::never_t<0>>( long long *a1, long long *a2) { long long v2; // rcx long long v3; // rax unsigned long long v4; // rcx long long v6; // [rsp+8h] [rbp-20h] BYREF _QWORD v7[3]; // [rsp+10h] [rbp-18h] BYREF v2 = *a2; v3 = *a2 | 1; v6 = v3; v4 = v2 & 0xFFFFFFFFFFFFFFFCLL; if ( v4 ) { _InterlockedIncrement64((volatile signed long long *)(*(_QWORD *)(v4 + 8) + 216LL)); v3 = v6; } v6 = 0LL; a1[5] = (long long)ZZN4asio9execution6detail17any_executor_base16target_fns_tableINS_10io_context19basic_executor_typeISaIvELm4EEEEEPKNS2_10target_fnsEbPNSt9enable_ifIXntsr7is_sameIT_vEE5valueEvE4typeEE16fns_with_execute; a1[3] = (long long)ZZN4asio9execution6detail17any_executor_base16object_fns_tableINS_10io_context19basic_executor_typeISaIvELm4EEEEEPKNS2_10object_fnsEPNSt9enable_ifIXaantsr7is_sameIT_vEE5valuentsr7is_sameISC_NS1_22shared_target_executorEEE5valueEvE4typeEE3fns; *a1 = v3; v7[0] = 0LL; a1[4] = (long long)a1; asio::io_context::basic_executor_type<std::allocator<void>,4ul>::~basic_executor_type(v7); a1[6] = (long long)asio::execution::any_executor<asio::execution::context_as_t<asio::execution_context &>,asio::execution::detail::blocking::never_t<0>,asio::execution::prefer_only<asio::execution::detail::blocking::possibly_t<0>>,asio::execution::prefer_only<asio::execution::detail::outstanding_work::tracked_t<0>>,asio::execution::prefer_only<asio::execution::detail::outstanding_work::untracked_t<0>>,asio::execution::prefer_only<asio::execution::detail::relationship::fork_t<0>>,asio::execution::prefer_only<asio::execution::detail::relationship::continuation_t<0>>>::prop_fns_table<asio::io_context::basic_executor_type<std::allocator<void>,4ul>>(void)::fns; asio::io_context::basic_executor_type<std::allocator<void>,4ul>::~basic_executor_type(&v6); return a1; }
require_fn_impl<asio::execution::any_executor<asio::execution::context_as_t<asio::execution_context&>,asio::execution::detail::blocking::never_t<0>,asio::execution::prefer_only<asio::execution::detail::blocking::possibly_t<0>>,asio::execution::prefer_only<asio::execution::detail::outstanding_work::tracked_t<0>>,asio::execution::prefer_only<asio::execution::detail::outstanding_work::untracked_t<0>>,asio::execution::prefer_only<asio::execution::detail::relationship::fork_t<0>>,asio::execution::prefer_only<asio::execution::detail::relationship::continuation_t<0>>>,asio::io_context::basic_executor_type<std::allocator<void>,4ul>,asio::execution::detail::blocking::never_t<0>>: PUSH R14 PUSH RBX SUB RSP,0x18 MOV RBX,RDI MOV RCX,qword ptr [RSI] MOV RAX,RCX OR RAX,0x1 MOV qword ptr [RSP + 0x8],RAX AND RCX,-0x4 JZ 0x001f9190 MOV RAX,qword ptr [RCX + 0x8] INC.LOCK qword ptr [RAX + 0xd8] MOV RAX,qword ptr [RSP + 0x8] LAB_001f9190: XOR ECX,ECX LEA R14,[RSP + 0x8] MOV qword ptr [R14],RCX MOV RDX,qword ptr [0x003a0fb0] MOV qword ptr [RBX + 0x28],RDX MOV RDX,qword ptr [0x003a0988] MOV qword ptr [RBX + 0x18],RDX MOV qword ptr [RBX],RAX LEA RDI,[RSP + 0x10] MOV qword ptr [RDI],RCX MOV qword ptr [RBX + 0x20],RBX CALL 0x001809b0 MOV RAX,qword ptr [0x003a0e08] MOV qword ptr [RBX + 0x30],RAX MOV RDI,R14 CALL 0x001809b0 MOV RAX,RBX ADD RSP,0x18 POP RBX POP R14 RET
/* asio::execution::any_executor<asio::execution::context_as_t<asio::execution_context&>, asio::execution::detail::blocking::never_t<0>, asio::execution::prefer_only<asio::execution::detail::blocking::possibly_t<0> >, asio::execution::prefer_only<asio::execution::detail::outstanding_work::tracked_t<0> >, asio::execution::prefer_only<asio::execution::detail::outstanding_work::untracked_t<0> >, asio::execution::prefer_only<asio::execution::detail::relationship::fork_t<0> >, asio::execution::prefer_only<asio::execution::detail::relationship::continuation_t<0> > > asio::execution::detail::any_executor_base::require_fn_impl<asio::execution::any_executor<asio::execution::context_as_t<asio::execution_context&>, asio::execution::detail::blocking::never_t<0>, asio::execution::prefer_only<asio::execution::detail::blocking::possibly_t<0> >, asio::execution::prefer_only<asio::execution::detail::outstanding_work::tracked_t<0> >, asio::execution::prefer_only<asio::execution::detail::outstanding_work::untracked_t<0> >, asio::execution::prefer_only<asio::execution::detail::relationship::fork_t<0> >, asio::execution::prefer_only<asio::execution::detail::relationship::continuation_t<0> > >, asio::io_context::basic_executor_type<std::allocator<void>, 4ul>, asio::execution::detail::blocking::never_t<0> >(void const*, void const*, std::enable_if<(!is_same<asio::io_context::basic_executor_type<std::allocator<void>, 4ul>, void>::value)&&asio::execution::detail::blocking::never_t<0>::is_requirable, void>::type*) */ void * asio::execution::detail::any_executor_base:: require_fn_impl<asio::execution::any_executor<asio::execution::context_as_t<asio::execution_context&>,asio::execution::detail::blocking::never_t<0>,asio::execution::prefer_only<asio::execution::detail::blocking::possibly_t<0>>,asio::execution::prefer_only<asio::execution::detail::outstanding_work::tracked_t<0>>,asio::execution::prefer_only<asio::execution::detail::outstanding_work::untracked_t<0>>,asio::execution::prefer_only<asio::execution::detail::relationship::fork_t<0>>,asio::execution::prefer_only<asio::execution::detail::relationship::continuation_t<0>>>,asio::io_context::basic_executor_type<std::allocator<void>,4ul>,asio::execution::detail::blocking::never_t<0>> (void *param_1,void *param_2,type *param_3) { long *plVar1; ulong uVar2; ulong uVar3; int8 local_20; int8 local_18; /* WARNING: Load size is inaccurate */ uVar2 = *param_2; uVar3 = uVar2 & 0xfffffffffffffffc; if (uVar3 != 0) { LOCK(); plVar1 = (long *)(*(long *)(uVar3 + 8) + 0xd8); *plVar1 = *plVar1 + 1; UNLOCK(); } local_20 = 0; *(int **)((long)param_1 + 0x28) = PTR_fns_with_execute_003a0fb0; *(int **)((long)param_1 + 0x18) = PTR_fns_003a0988; *(ulong *)param_1 = uVar2 | 1; local_18 = 0; *(void **)((long)param_1 + 0x20) = param_1; io_context::basic_executor_type<std::allocator<void>,4ul>::~basic_executor_type ((basic_executor_type<std::allocator<void>,4ul> *)&local_18); *(int **)((long)param_1 + 0x30) = PTR_fns_003a0e08; io_context::basic_executor_type<std::allocator<void>,4ul>::~basic_executor_type ((basic_executor_type<std::allocator<void>,4ul> *)&local_20); return param_1; }
60,819
google::protobuf::DescriptorPool::NewPlaceholderFileWithMutexHeld(google::protobuf::stringpiece_internal::StringPiece, google::protobuf::internal::FlatAllocator&) const
aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/descriptor.cc
FileDescriptor* DescriptorPool::NewPlaceholderFileWithMutexHeld( StringPiece name, internal::FlatAllocator& alloc) const { if (mutex_) { mutex_->AssertHeld(); } FileDescriptor* placeholder = alloc.AllocateArray<FileDescriptor>(1); memset(static_cast<void*>(placeholder), 0, sizeof(*placeholder)); placeholder->name_ = alloc.AllocateStrings(name); placeholder->package_ = &internal::GetEmptyString(); placeholder->pool_ = this; placeholder->options_ = &FileOptions::default_instance(); placeholder->tables_ = &FileDescriptorTables::GetEmptyInstance(); placeholder->source_code_info_ = &SourceCodeInfo::default_instance(); placeholder->is_placeholder_ = true; placeholder->syntax_ = FileDescriptor::SYNTAX_UNKNOWN; placeholder->finished_building_ = true; // All other fields are zero or nullptr. return placeholder; }
O0
cpp
google::protobuf::DescriptorPool::NewPlaceholderFileWithMutexHeld(google::protobuf::stringpiece_internal::StringPiece, google::protobuf::internal::FlatAllocator&) const: subq $0x38, %rsp movq %rsi, 0x28(%rsp) movq %rdx, 0x30(%rsp) movq %rdi, 0x20(%rsp) movq %rcx, 0x18(%rsp) movq 0x20(%rsp), %rax movq %rax, 0x8(%rsp) cmpq $0x0, (%rax) je 0x451a5 movq 0x8(%rsp), %rax movq (%rax), %rdi callq 0x77090 movq 0x18(%rsp), %rdi movl $0x1, %esi callq 0x45ef0 movq %rax, 0x10(%rsp) movq 0x10(%rsp), %rdi xorl %esi, %esi movl $0x90, %edx callq 0x13200 movq 0x18(%rsp), %rdi leaq 0x28(%rsp), %rsi callq 0x46110 movq %rax, %rcx movq 0x10(%rsp), %rax movq %rcx, 0x8(%rax) callq 0x77580 movq 0x8(%rsp), %rcx movq %rax, %rdx movq 0x10(%rsp), %rax movq %rdx, 0x10(%rax) movq 0x10(%rsp), %rax movq %rcx, 0x18(%rax) callq 0x75d50 movq %rax, %rcx movq 0x10(%rsp), %rax movq %rcx, 0x78(%rax) callq 0x77590 movq %rax, %rcx movq 0x10(%rsp), %rax movq %rcx, 0x80(%rax) callq 0x75e10 movq %rax, %rcx movq 0x10(%rsp), %rax movq %rcx, 0x88(%rax) movq 0x10(%rsp), %rax movb $0x1, 0x1(%rax) movq 0x10(%rsp), %rax movb $0x0, 0x3(%rax) movq 0x10(%rsp), %rax movb $0x1, 0x2(%rax) movq 0x10(%rsp), %rax addq $0x38, %rsp retq nopw %cs:(%rax,%rax)
_ZNK6google8protobuf14DescriptorPool31NewPlaceholderFileWithMutexHeldENS0_20stringpiece_internal11StringPieceERNS0_8internal13FlatAllocatorE: sub rsp, 38h mov [rsp+38h+var_10], rsi mov [rsp+38h+var_8], rdx mov [rsp+38h+var_18], rdi mov [rsp+38h+var_20], rcx mov rax, [rsp+38h+var_18] mov [rsp+38h+var_30], rax cmp qword ptr [rax], 0 jz short loc_451A5 mov rax, [rsp+38h+var_30] mov rdi, [rax]; this call _ZNK6google8protobuf8internal12WrappedMutex10AssertHeldEv; google::protobuf::internal::WrappedMutex::AssertHeld(void) loc_451A5: mov rdi, [rsp+38h+var_20] mov esi, 1 call _ZN6google8protobuf12_GLOBAL__N_117FlatAllocatorImplIJcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEENS0_14SourceCodeInfoENS0_20FileDescriptorTablesENS0_14MessageOptionsENS0_12FieldOptionsENS0_11EnumOptionsENS0_16EnumValueOptionsENS0_21ExtensionRangeOptionsENS0_12OneofOptionsENS0_14ServiceOptionsENS0_13MethodOptionsENS0_11FileOptionsEEE13AllocateArrayINS0_14FileDescriptorEEEPT_i; google::protobuf::`anonymous namespace'::FlatAllocatorImpl<char,std::string,google::protobuf::SourceCodeInfo,google::protobuf::FileDescriptorTables,google::protobuf::MessageOptions,google::protobuf::FieldOptions,google::protobuf::EnumOptions,google::protobuf::EnumValueOptions,google::protobuf::ExtensionRangeOptions,google::protobuf::OneofOptions,google::protobuf::ServiceOptions,google::protobuf::MethodOptions,google::protobuf::FileOptions>::AllocateArray<google::protobuf::FileDescriptor>(int) mov [rsp+38h+var_28], rax mov rdi, [rsp+38h+var_28] xor esi, esi mov edx, 90h call _memset mov rdi, [rsp+38h+var_20]; this lea rsi, [rsp+38h+var_10] call _ZN6google8protobuf12_GLOBAL__N_117FlatAllocatorImplIJcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEENS0_14SourceCodeInfoENS0_20FileDescriptorTablesENS0_14MessageOptionsENS0_12FieldOptionsENS0_11EnumOptionsENS0_16EnumValueOptionsENS0_21ExtensionRangeOptionsENS0_12OneofOptionsENS0_14ServiceOptionsENS0_13MethodOptionsENS0_11FileOptionsEEE15AllocateStringsIJRNS0_20stringpiece_internal11StringPieceEEEEPKS8_DpOT_; google::protobuf::`anonymous namespace'::FlatAllocatorImpl<char,std::string,google::protobuf::SourceCodeInfo,google::protobuf::FileDescriptorTables,google::protobuf::MessageOptions,google::protobuf::FieldOptions,google::protobuf::EnumOptions,google::protobuf::EnumValueOptions,google::protobuf::ExtensionRangeOptions,google::protobuf::OneofOptions,google::protobuf::ServiceOptions,google::protobuf::MethodOptions,google::protobuf::FileOptions>::AllocateStrings<google::protobuf::stringpiece_internal::StringPiece &>(google::protobuf::stringpiece_internal::StringPiece &) mov rcx, rax mov rax, [rsp+38h+var_28] mov [rax+8], rcx call _ZN6google8protobuf8internal14GetEmptyStringB5cxx11Ev; google::protobuf::internal::GetEmptyString(void) mov rcx, [rsp+38h+var_30] mov rdx, rax mov rax, [rsp+38h+var_28] mov [rax+10h], rdx mov rax, [rsp+38h+var_28] mov [rax+18h], rcx call _ZN6google8protobuf11FileOptions16default_instanceEv; google::protobuf::FileOptions::default_instance(void) mov rcx, rax mov rax, [rsp+38h+var_28] mov [rax+78h], rcx call _ZN6google8protobuf20FileDescriptorTables16GetEmptyInstanceEv; google::protobuf::FileDescriptorTables::GetEmptyInstance(void) mov rcx, rax mov rax, [rsp+38h+var_28] mov [rax+80h], rcx call _ZN6google8protobuf14SourceCodeInfo16default_instanceEv; google::protobuf::SourceCodeInfo::default_instance(void) mov rcx, rax mov rax, [rsp+38h+var_28] mov [rax+88h], rcx mov rax, [rsp+38h+var_28] mov byte ptr [rax+1], 1 mov rax, [rsp+38h+var_28] mov byte ptr [rax+3], 0 mov rax, [rsp+38h+var_28] mov byte ptr [rax+2], 1 mov rax, [rsp+38h+var_28] add rsp, 38h retn
NewPlaceholderFileWithMutexHeld: SUB RSP,0x38 MOV qword ptr [RSP + 0x28],RSI MOV qword ptr [RSP + 0x30],RDX MOV qword ptr [RSP + 0x20],RDI MOV qword ptr [RSP + 0x18],RCX MOV RAX,qword ptr [RSP + 0x20] MOV qword ptr [RSP + 0x8],RAX CMP qword ptr [RAX],0x0 JZ 0x001451a5 MOV RAX,qword ptr [RSP + 0x8] MOV RDI,qword ptr [RAX] CALL 0x00177090 LAB_001451a5: MOV RDI,qword ptr [RSP + 0x18] MOV ESI,0x1 CALL 0x00145ef0 MOV qword ptr [RSP + 0x10],RAX MOV RDI,qword ptr [RSP + 0x10] XOR ESI,ESI MOV EDX,0x90 CALL 0x00113200 MOV RDI,qword ptr [RSP + 0x18] LEA RSI,[RSP + 0x28] CALL 0x00146110 MOV RCX,RAX MOV RAX,qword ptr [RSP + 0x10] MOV qword ptr [RAX + 0x8],RCX CALL 0x00177580 MOV RCX,qword ptr [RSP + 0x8] MOV RDX,RAX MOV RAX,qword ptr [RSP + 0x10] MOV qword ptr [RAX + 0x10],RDX MOV RAX,qword ptr [RSP + 0x10] MOV qword ptr [RAX + 0x18],RCX CALL 0x00175d50 MOV RCX,RAX MOV RAX,qword ptr [RSP + 0x10] MOV qword ptr [RAX + 0x78],RCX CALL 0x00177590 MOV RCX,RAX MOV RAX,qword ptr [RSP + 0x10] MOV qword ptr [RAX + 0x80],RCX CALL 0x00175e10 MOV RCX,RAX MOV RAX,qword ptr [RSP + 0x10] MOV qword ptr [RAX + 0x88],RCX MOV RAX,qword ptr [RSP + 0x10] MOV byte ptr [RAX + 0x1],0x1 MOV RAX,qword ptr [RSP + 0x10] MOV byte ptr [RAX + 0x3],0x0 MOV RAX,qword ptr [RSP + 0x10] MOV byte ptr [RAX + 0x2],0x1 MOV RAX,qword ptr [RSP + 0x10] ADD RSP,0x38 RET
/* google::protobuf::DescriptorPool::NewPlaceholderFileWithMutexHeld(google::protobuf::stringpiece_internal::StringPiece, google::protobuf::internal::FlatAllocator&) const */ FileDescriptor * google::protobuf::DescriptorPool::NewPlaceholderFileWithMutexHeld (long *param_1,int8 param_2,int8 param_3, FlatAllocatorImpl<char,std::__cxx11::string,google::protobuf::SourceCodeInfo,google::protobuf::FileDescriptorTables,google::protobuf::MessageOptions,google::protobuf::FieldOptions,google::protobuf::EnumOptions,google::protobuf::EnumValueOptions,google::protobuf::ExtensionRangeOptions,google::protobuf::OneofOptions,google::protobuf::ServiceOptions,google::protobuf::MethodOptions,google::protobuf::FileOptions> *param_4) { FileDescriptor *__s; string *psVar1; int8 uVar2; int8 local_10; int8 local_8; local_10 = param_2; local_8 = param_3; if (*param_1 != 0) { internal::WrappedMutex::AssertHeld(); } __s = (anonymous_namespace):: FlatAllocatorImpl<char,std::__cxx11::string,google::protobuf::SourceCodeInfo,google::protobuf::FileDescriptorTables,google::protobuf::MessageOptions,google::protobuf::FieldOptions,google::protobuf::EnumOptions,google::protobuf::EnumValueOptions,google::protobuf::ExtensionRangeOptions,google::protobuf::OneofOptions,google::protobuf::ServiceOptions,google::protobuf::MethodOptions,google::protobuf::FileOptions> ::AllocateArray<google::protobuf::FileDescriptor>(param_4,1); memset(__s,0,0x90); psVar1 = (anonymous_namespace):: FlatAllocatorImpl<char,std::__cxx11::string,google::protobuf::SourceCodeInfo,google::protobuf::FileDescriptorTables,google::protobuf::MessageOptions,google::protobuf::FieldOptions,google::protobuf::EnumOptions,google::protobuf::EnumValueOptions,google::protobuf::ExtensionRangeOptions,google::protobuf::OneofOptions,google::protobuf::ServiceOptions,google::protobuf::MethodOptions,google::protobuf::FileOptions> ::AllocateStrings<google::protobuf::stringpiece_internal::StringPiece&> (param_4,(StringPiece *)&local_10); *(string **)(__s + 8) = psVar1; uVar2 = internal::GetEmptyString_abi_cxx11_(); *(int8 *)(__s + 0x10) = uVar2; *(long **)(__s + 0x18) = param_1; uVar2 = FileOptions::default_instance(); *(int8 *)(__s + 0x78) = uVar2; uVar2 = FileDescriptorTables::GetEmptyInstance(); *(int8 *)(__s + 0x80) = uVar2; uVar2 = SourceCodeInfo::default_instance(); *(int8 *)(__s + 0x88) = uVar2; __s[1] = (FileDescriptor)0x1; __s[3] = (FileDescriptor)0x0; __s[2] = (FileDescriptor)0x1; return __s; }
60,820
google::protobuf::DescriptorPool::NewPlaceholderFileWithMutexHeld(google::protobuf::stringpiece_internal::StringPiece, google::protobuf::internal::FlatAllocator&) const
aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/descriptor.cc
FileDescriptor* DescriptorPool::NewPlaceholderFileWithMutexHeld( StringPiece name, internal::FlatAllocator& alloc) const { if (mutex_) { mutex_->AssertHeld(); } FileDescriptor* placeholder = alloc.AllocateArray<FileDescriptor>(1); memset(static_cast<void*>(placeholder), 0, sizeof(*placeholder)); placeholder->name_ = alloc.AllocateStrings(name); placeholder->package_ = &internal::GetEmptyString(); placeholder->pool_ = this; placeholder->options_ = &FileOptions::default_instance(); placeholder->tables_ = &FileDescriptorTables::GetEmptyInstance(); placeholder->source_code_info_ = &SourceCodeInfo::default_instance(); placeholder->is_placeholder_ = true; placeholder->syntax_ = FileDescriptor::SYNTAX_UNKNOWN; placeholder->finished_building_ = true; // All other fields are zero or nullptr. return placeholder; }
O3
cpp
google::protobuf::DescriptorPool::NewPlaceholderFileWithMutexHeld(google::protobuf::stringpiece_internal::StringPiece, google::protobuf::internal::FlatAllocator&) const: pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x30, %rsp movq %rcx, %r15 movq %rdi, %r14 movq %rsp, %r12 movq %rsi, (%r12) movq %rdx, 0x8(%r12) movq %rcx, %rdi callq 0x29b86 movq %rax, %rbx movl $0x90, %edx movq %rax, %rdi xorl %esi, %esi callq 0xf1d0 movq %r15, %rdi movl $0x1, %esi callq 0x3b316 movq %rax, %r15 leaq 0x10(%rsp), %r13 movq %r13, %rdi movq %r12, %rsi callq 0x16b0e movq %r15, %rdi movq %r13, %rsi callq 0xf620 movq (%r13), %rdi leaq 0x20(%rsp), %rax cmpq %rax, %rdi je 0x295ab callq 0xf330 movq %r15, 0x8(%rbx) leaq 0xd9ce2(%rip), %rax # 0x103298 movb (%rax), %al testb $0x1, %al je 0x29617 leaq 0xd9cb5(%rip), %rax # 0x103278 movq %rax, 0x10(%rbx) movq %r14, 0x18(%rbx) leaq 0xd919e(%rip), %rax # 0x102770 movq %rax, 0x78(%rbx) movb 0xd98dc(%rip), %al # 0x102eb8 testb %al, %al je 0x2961e movq 0xd98c9(%rip), %rax # 0x102eb0 movq %rax, 0x80(%rbx) leaq 0xd954b(%rip), %rax # 0x102b40 movq %rax, 0x88(%rbx) movw $0x101, 0x1(%rbx) # imm = 0x101 movb $0x0, 0x3(%rbx) movq %rbx, %rax addq $0x30, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 retq callq 0x9c76d jmp 0x295bc leaq 0xd9893(%rip), %rdi # 0x102eb8 callq 0xf580 testl %eax, %eax je 0x295e0 movl $0x160, %edi # imm = 0x160 callq 0xf350 movq %rax, %r14 movq %rax, %rdi callq 0x1c0a8 leaq 0x16f26(%rip), %rdi # 0x40570 movq %r14, %rsi callq 0x9e9d5 movq %r14, 0xd9857(%rip) # 0x102eb0 leaq 0xd9858(%rip), %rdi # 0x102eb8 callq 0xf230 jmp 0x295e0 movq %rax, %rbx leaq 0xd9844(%rip), %rdi # 0x102eb8 callq 0xf220 movq %rbx, %rdi callq 0xf570 nop
_ZNK6google8protobuf14DescriptorPool31NewPlaceholderFileWithMutexHeldENS0_20stringpiece_internal11StringPieceERNS0_8internal13FlatAllocatorE: push r15 push r14 push r13 push r12 push rbx sub rsp, 30h mov r15, rcx mov r14, rdi mov r12, rsp mov [r12], rsi mov [r12+8], rdx mov rdi, rcx call _ZN6google8protobuf12_GLOBAL__N_117FlatAllocatorImplIJcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEENS0_14SourceCodeInfoENS0_20FileDescriptorTablesENS0_14MessageOptionsENS0_12FieldOptionsENS0_11EnumOptionsENS0_16EnumValueOptionsENS0_21ExtensionRangeOptionsENS0_12OneofOptionsENS0_14ServiceOptionsENS0_13MethodOptionsENS0_11FileOptionsEEE13AllocateArrayINS0_14FileDescriptorEEEPT_i; google::protobuf::`anonymous namespace'::FlatAllocatorImpl<char,std::string,google::protobuf::SourceCodeInfo,google::protobuf::FileDescriptorTables,google::protobuf::MessageOptions,google::protobuf::FieldOptions,google::protobuf::EnumOptions,google::protobuf::EnumValueOptions,google::protobuf::ExtensionRangeOptions,google::protobuf::OneofOptions,google::protobuf::ServiceOptions,google::protobuf::MethodOptions,google::protobuf::FileOptions>::AllocateArray<google::protobuf::FileDescriptor>(int) mov rbx, rax mov edx, 90h mov rdi, rax xor esi, esi call _memset mov rdi, r15 mov esi, 1 call _ZN6google8protobuf12_GLOBAL__N_117FlatAllocatorImplIJcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEENS0_14SourceCodeInfoENS0_20FileDescriptorTablesENS0_14MessageOptionsENS0_12FieldOptionsENS0_11EnumOptionsENS0_16EnumValueOptionsENS0_21ExtensionRangeOptionsENS0_12OneofOptionsENS0_14ServiceOptionsENS0_13MethodOptionsENS0_11FileOptionsEEE13AllocateArrayIS8_EEPT_i; google::protobuf::`anonymous namespace'::FlatAllocatorImpl<char,std::string,google::protobuf::SourceCodeInfo,google::protobuf::FileDescriptorTables,google::protobuf::MessageOptions,google::protobuf::FieldOptions,google::protobuf::EnumOptions,google::protobuf::EnumValueOptions,google::protobuf::ExtensionRangeOptions,google::protobuf::OneofOptions,google::protobuf::ServiceOptions,google::protobuf::MethodOptions,google::protobuf::FileOptions>::AllocateArray<std::string>(int) mov r15, rax lea r13, [rsp+58h+var_48] mov rdi, r13 mov rsi, r12 call _ZNK6google8protobuf20stringpiece_internal11StringPiece8ToStringB5cxx11Ev; google::protobuf::stringpiece_internal::StringPiece::ToString(void) mov rdi, r15 mov rsi, r13 call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEaSEOS4_; std::string::operator=(std::string&&) mov rdi, [r13+0]; this lea rax, [rsp+58h+var_38] cmp rdi, rax jz short loc_295AB call __ZdlPv; operator delete(void *) loc_295AB: mov [rbx+8], r15 lea rax, _ZN6google8protobuf8internal28init_protobuf_defaults_stateE; google::protobuf::internal::init_protobuf_defaults_state mov al, [rax] test al, 1 jz short loc_29617 loc_295BC: lea rax, _ZN6google8protobuf8internal26fixed_address_empty_stringB5cxx11E; google::protobuf::internal::fixed_address_empty_string mov [rbx+10h], rax mov [rbx+18h], r14 lea rax, _ZN6google8protobuf30_FileOptions_default_instance_E; google::protobuf::_FileOptions_default_instance_ mov [rbx+78h], rax mov al, cs:_ZGVZN6google8protobuf20FileDescriptorTables16GetEmptyInstanceEvE22file_descriptor_tables; `guard variable for'google::protobuf::FileDescriptorTables::GetEmptyInstance(void)::file_descriptor_tables test al, al jz short loc_2961E loc_295E0: mov rax, cs:_ZZN6google8protobuf20FileDescriptorTables16GetEmptyInstanceEvE22file_descriptor_tables; google::protobuf::FileDescriptorTables::GetEmptyInstance(void)::file_descriptor_tables mov [rbx+80h], rax lea rax, _ZN6google8protobuf33_SourceCodeInfo_default_instance_E; google::protobuf::_SourceCodeInfo_default_instance_ mov [rbx+88h], rax mov word ptr [rbx+1], 101h mov byte ptr [rbx+3], 0 mov rax, rbx add rsp, 30h pop rbx pop r12 pop r13 pop r14 pop r15 retn loc_29617: call _ZN6google8protobuf8internal24InitProtobufDefaultsSlowEv; google::protobuf::internal::InitProtobufDefaultsSlow(void) jmp short loc_295BC loc_2961E: lea rdi, _ZGVZN6google8protobuf20FileDescriptorTables16GetEmptyInstanceEvE22file_descriptor_tables; __guard * call ___cxa_guard_acquire test eax, eax jz short loc_295E0 mov edi, 160h; unsigned __int64 call __Znwm; operator new(ulong) mov r14, rax mov rdi, rax; this call _ZN6google8protobuf20FileDescriptorTablesC2Ev; google::protobuf::FileDescriptorTables::FileDescriptorTables(void) lea rdi, _ZZN6google8protobuf8internal16OnShutdownDeleteINS0_20FileDescriptorTablesEEEPT_S5_ENUlPKvE_8__invokeES7_; this mov rsi, r14; void (*)(const void *) call _ZN6google8protobuf8internal13OnShutdownRunEPFvPKvES3_; google::protobuf::internal::OnShutdownRun(void (*)(void const*),void const*) mov cs:_ZZN6google8protobuf20FileDescriptorTables16GetEmptyInstanceEvE22file_descriptor_tables, r14; google::protobuf::FileDescriptorTables::GetEmptyInstance(void)::file_descriptor_tables lea rdi, _ZGVZN6google8protobuf20FileDescriptorTables16GetEmptyInstanceEvE22file_descriptor_tables; __guard * call ___cxa_guard_release jmp loc_295E0 mov rbx, rax lea rdi, _ZGVZN6google8protobuf20FileDescriptorTables16GetEmptyInstanceEvE22file_descriptor_tables; __guard * call ___cxa_guard_abort mov rdi, rbx call __Unwind_Resume
long long google::protobuf::DescriptorPool::NewPlaceholderFileWithMutexHeld( long long a1, long long a2, long long a3, int a4, int a5, int a6) { long long v8; // rbx int v9; // edx int v10; // ecx int v11; // r8d int v12; // r9d _QWORD *v13; // r15 google::protobuf::internal *v14; // rdi google::protobuf::FileDescriptorTables *v16; // r14 const void *v17; // rdx int v18; // [rsp+0h] [rbp-58h] BYREF char v19; // [rsp+8h] [rbp-50h] void *v20[2]; // [rsp+10h] [rbp-48h] BYREF char v21; // [rsp+20h] [rbp-38h] BYREF v8 = google::protobuf::`anonymous namespace'::FlatAllocatorImpl<char,std::string,google::protobuf::SourceCodeInfo,google::protobuf::FileDescriptorTables,google::protobuf::MessageOptions,google::protobuf::FieldOptions,google::protobuf::EnumOptions,google::protobuf::EnumValueOptions,google::protobuf::ExtensionRangeOptions,google::protobuf::OneofOptions,google::protobuf::ServiceOptions,google::protobuf::MethodOptions,google::protobuf::FileOptions>::AllocateArray<google::protobuf::FileDescriptor>( a4, a2, a3, a4, a5, a6, a2, a3); memset(v8, 0LL, 144LL); v13 = (_QWORD *)google::protobuf::`anonymous namespace'::FlatAllocatorImpl<char,std::string,google::protobuf::SourceCodeInfo,google::protobuf::FileDescriptorTables,google::protobuf::MessageOptions,google::protobuf::FieldOptions,google::protobuf::EnumOptions,google::protobuf::EnumValueOptions,google::protobuf::ExtensionRangeOptions,google::protobuf::OneofOptions,google::protobuf::ServiceOptions,google::protobuf::MethodOptions,google::protobuf::FileOptions>::AllocateArray<std::string>( a4, 1, v9, v10, v11, v12, v18, v19); google::protobuf::stringpiece_internal::StringPiece::ToString[abi:cxx11](v20, (long long)&v18); std::string::operator=(v13, (long long)v20); v14 = (google::protobuf::internal *)v20[0]; if ( v20[0] != &v21 ) operator delete(v20[0]); *(_QWORD *)(v8 + 8) = v13; if ( (google::protobuf::internal::init_protobuf_defaults_state & 1) == 0 ) google::protobuf::internal::InitProtobufDefaultsSlow(v14); *(_QWORD *)(v8 + 16) = google::protobuf::internal::fixed_address_empty_string[abi:cxx11]; *(_QWORD *)(v8 + 24) = a1; *(_QWORD *)(v8 + 120) = &google::protobuf::_FileOptions_default_instance_; if ( !(_BYTE)`guard variable for'google::protobuf::FileDescriptorTables::GetEmptyInstance(void)::file_descriptor_tables && __cxa_guard_acquire(&`guard variable for'google::protobuf::FileDescriptorTables::GetEmptyInstance(void)::file_descriptor_tables) ) { v16 = (google::protobuf::FileDescriptorTables *)operator new(0x160uLL); google::protobuf::FileDescriptorTables::FileDescriptorTables(v16); google::protobuf::internal::OnShutdownRun( (google::protobuf::internal *)google::protobuf::internal::OnShutdownDelete<google::protobuf::FileDescriptorTables>(google::protobuf::FileDescriptorTables *)::{lambda(void const*)#1}::__invoke, (void (*)(const void *))v16, v17); google::protobuf::FileDescriptorTables::GetEmptyInstance(void)::file_descriptor_tables = (long long)v16; __cxa_guard_release(&`guard variable for'google::protobuf::FileDescriptorTables::GetEmptyInstance(void)::file_descriptor_tables); } *(_QWORD *)(v8 + 128) = google::protobuf::FileDescriptorTables::GetEmptyInstance(void)::file_descriptor_tables; *(_QWORD *)(v8 + 136) = &google::protobuf::_SourceCodeInfo_default_instance_; *(_WORD *)(v8 + 1) = 257; *(_BYTE *)(v8 + 3) = 0; return v8; }
NewPlaceholderFileWithMutexHeld: PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x30 MOV R15,RCX MOV R14,RDI MOV R12,RSP MOV qword ptr [R12],RSI MOV qword ptr [R12 + 0x8],RDX MOV RDI,RCX CALL 0x00129b86 MOV RBX,RAX MOV EDX,0x90 MOV RDI,RAX XOR ESI,ESI CALL 0x0010f1d0 MOV RDI,R15 MOV ESI,0x1 CALL 0x0013b316 MOV R15,RAX LEA R13,[RSP + 0x10] MOV RDI,R13 MOV RSI,R12 CALL 0x00116b0e MOV RDI,R15 MOV RSI,R13 CALL 0x0010f620 MOV RDI,qword ptr [R13] LEA RAX,[RSP + 0x20] CMP RDI,RAX JZ 0x001295ab CALL 0x0010f330 LAB_001295ab: MOV qword ptr [RBX + 0x8],R15 LEA RAX,[0x203298] MOV AL,byte ptr [RAX] TEST AL,0x1 JZ 0x00129617 LAB_001295bc: LEA RAX,[0x203278] MOV qword ptr [RBX + 0x10],RAX MOV qword ptr [RBX + 0x18],R14 LEA RAX,[0x202770] MOV qword ptr [RBX + 0x78],RAX MOV AL,byte ptr [0x00202eb8] TEST AL,AL JZ 0x0012961e LAB_001295e0: MOV RAX,qword ptr [0x00202eb0] MOV qword ptr [RBX + 0x80],RAX LEA RAX,[0x202b40] MOV qword ptr [RBX + 0x88],RAX MOV word ptr [RBX + 0x1],0x101 MOV byte ptr [RBX + 0x3],0x0 MOV RAX,RBX ADD RSP,0x30 POP RBX POP R12 POP R13 POP R14 POP R15 RET LAB_00129617: CALL 0x0019c76d JMP 0x001295bc LAB_0012961e: LEA RDI,[0x202eb8] CALL 0x0010f580 TEST EAX,EAX JZ 0x001295e0 LAB_0012962e: MOV EDI,0x160 CALL 0x0010f350 MOV R14,RAX MOV RDI,RAX CALL 0x0011c0a8 LEA RDI,[0x140570] MOV RSI,R14 CALL 0x0019e9d5 LAB_00129652: MOV qword ptr [0x00202eb0],R14 LEA RDI,[0x202eb8] CALL 0x0010f230 JMP 0x001295e0
/* google::protobuf::DescriptorPool::NewPlaceholderFileWithMutexHeld(google::protobuf::stringpiece_internal::StringPiece, google::protobuf::internal::FlatAllocator&) const */ FileDescriptor * google::protobuf::DescriptorPool::NewPlaceholderFileWithMutexHeld (int8 param_1,int8 param_2,int8 param_3, FlatAllocatorImpl<char,std::__cxx11::string,google::protobuf::SourceCodeInfo,google::protobuf::FileDescriptorTables,google::protobuf::MessageOptions,google::protobuf::FieldOptions,google::protobuf::EnumOptions,google::protobuf::EnumValueOptions,google::protobuf::ExtensionRangeOptions,google::protobuf::OneofOptions,google::protobuf::ServiceOptions,google::protobuf::MethodOptions,google::protobuf::FileOptions> *param_4) { int iVar1; FileDescriptor *__s; string *this; FileDescriptorTables *this_00; int1 *local_48 [2]; int1 local_38 [16]; __s = (anonymous_namespace):: FlatAllocatorImpl<char,std::__cxx11::string,google::protobuf::SourceCodeInfo,google::protobuf::FileDescriptorTables,google::protobuf::MessageOptions,google::protobuf::FieldOptions,google::protobuf::EnumOptions,google::protobuf::EnumValueOptions,google::protobuf::ExtensionRangeOptions,google::protobuf::OneofOptions,google::protobuf::ServiceOptions,google::protobuf::MethodOptions,google::protobuf::FileOptions> ::AllocateArray<google::protobuf::FileDescriptor>((int)param_4); memset(__s,0,0x90); this = (anonymous_namespace):: FlatAllocatorImpl<char,std::__cxx11::string,google::protobuf::SourceCodeInfo,google::protobuf::FileDescriptorTables,google::protobuf::MessageOptions,google::protobuf::FieldOptions,google::protobuf::EnumOptions,google::protobuf::EnumValueOptions,google::protobuf::ExtensionRangeOptions,google::protobuf::OneofOptions,google::protobuf::ServiceOptions,google::protobuf::MethodOptions,google::protobuf::FileOptions> ::AllocateArray<std::__cxx11::string>(param_4,1); stringpiece_internal::StringPiece::ToString_abi_cxx11_(); std::__cxx11::string::operator=(this,(string *)local_48); if (local_48[0] != local_38) { operator_delete(local_48[0]); } *(string **)(__s + 8) = this; if ((internal::init_protobuf_defaults_state & 1) == 0) { internal::InitProtobufDefaultsSlow(); } *(int8 **)(__s + 0x10) = &internal::fixed_address_empty_string_abi_cxx11_; *(int8 *)(__s + 0x18) = param_1; *(int1 **)(__s + 0x78) = _FileOptions_default_instance_; if (FileDescriptorTables::GetEmptyInstance()::file_descriptor_tables == '\0') { iVar1 = __cxa_guard_acquire(&FileDescriptorTables::GetEmptyInstance()::file_descriptor_tables); if (iVar1 != 0) { /* try { // try from 0012962e to 00129651 has its CatchHandler @ 0012966a */ this_00 = (FileDescriptorTables *)operator_new(0x160); FileDescriptorTables::FileDescriptorTables(this_00); internal::OnShutdownRun (internal:: OnShutdownDelete<google::protobuf::FileDescriptorTables>(google::protobuf::FileDescriptorTables*) ::{lambda(void_const*)#1}::__invoke,this_00); FileDescriptorTables::GetEmptyInstance()::file_descriptor_tables = this_00; __cxa_guard_release(&FileDescriptorTables::GetEmptyInstance()::file_descriptor_tables); } } *(FileDescriptorTables **)(__s + 0x80) = FileDescriptorTables::GetEmptyInstance()::file_descriptor_tables; *(int1 **)(__s + 0x88) = _SourceCodeInfo_default_instance_; *(int2 *)(__s + 1) = 0x101; __s[3] = (FileDescriptor)0x0; return __s; }
60,821
translog_sync
eloqsql/storage/maria/ma_loghandler.c
void translog_sync() { DBUG_ENTER("ma_translog_sync"); /* The following is only true if initalization of translog succeded */ if (log_descriptor.open_files.elements != 0) { uint32 max= get_current_logfile()->number; uint32 min; min= soft_sync_min; if (!min) min= max; translog_sync_files(min, max, sync_log_dir >= TRANSLOG_SYNC_DIR_ALWAYS); } DBUG_VOID_RETURN; }
O0
c
translog_sync: pushq %rbp movq %rsp, %rbp subq $0x10, %rsp cmpl $0x0, 0x3f6391(%rip) # 0x488650 je 0x922fe callq 0x970c0 movl (%rax), %eax movl %eax, -0x4(%rbp) movl 0xbf707b(%rip), %eax # 0xc8934c movl %eax, -0x8(%rbp) cmpl $0x0, -0x8(%rbp) jne 0x922e0 movl -0x4(%rbp), %eax movl %eax, -0x8(%rbp) movl -0x8(%rbp), %edi movl -0x4(%rbp), %esi cmpq $0x2, 0x238d5a(%rip) # 0x2cb048 setae %al andb $0x1, %al movzbl %al, %eax movsbl %al, %edx callq 0x90fe0 jmp 0x92300 jmp 0x92302 addq $0x10, %rsp popq %rbp retq nopl (%rax,%rax)
translog_sync: push rbp mov rbp, rsp sub rsp, 10h cmp cs:dword_488650, 0 jz short loc_922FE call get_current_logfile mov eax, [rax] mov [rbp+var_4], eax mov eax, cs:soft_sync_min mov [rbp+var_8], eax cmp [rbp+var_8], 0 jnz short loc_922E0 mov eax, [rbp+var_4] mov [rbp+var_8], eax loc_922E0: mov edi, [rbp+var_8] mov esi, [rbp+var_4] cmp cs:sync_log_dir, 2 setnb al and al, 1 movzx eax, al movsx edx, al call translog_sync_files loc_922FE: jmp short $+2 loc_92300: jmp short $+2 loc_92302: add rsp, 10h pop rbp retn
void translog_sync() { unsigned int v0; // [rsp+8h] [rbp-8h] unsigned int v1; // [rsp+Ch] [rbp-4h] if ( dword_488650 ) { v1 = *(_DWORD *)get_current_logfile(); v0 = soft_sync_min; if ( !soft_sync_min ) v0 = v1; translog_sync_files(v0, v1, (unsigned long long)sync_log_dir >= 2); } }
translog_sync: PUSH RBP MOV RBP,RSP SUB RSP,0x10 CMP dword ptr [0x00588650],0x0 JZ 0x001922fe CALL 0x001970c0 MOV EAX,dword ptr [RAX] MOV dword ptr [RBP + -0x4],EAX MOV EAX,dword ptr [0x00d8934c] MOV dword ptr [RBP + -0x8],EAX CMP dword ptr [RBP + -0x8],0x0 JNZ 0x001922e0 MOV EAX,dword ptr [RBP + -0x4] MOV dword ptr [RBP + -0x8],EAX LAB_001922e0: MOV EDI,dword ptr [RBP + -0x8] MOV ESI,dword ptr [RBP + -0x4] CMP qword ptr [0x003cb048],0x2 SETNC AL AND AL,0x1 MOVZX EAX,AL MOVSX EDX,AL CALL 0x00190fe0 LAB_001922fe: JMP 0x00192300 LAB_00192300: JMP 0x00192302 LAB_00192302: ADD RSP,0x10 POP RBP RET
void translog_sync(void) { int *piVar1; int4 local_10; if (DAT_00588650 != 0) { piVar1 = (int *)get_current_logfile(); local_10 = soft_sync_min; if (soft_sync_min == 0) { local_10 = *piVar1; } translog_sync_files(local_10,*piVar1,1 < sync_log_dir); } return; }
60,822
cs_copy_data
eloqsql/mysys/charset.c
static int cs_copy_data(struct charset_info_st *to, CHARSET_INFO *from) { to->number= from->number ? from->number : to->number; /* Don't replace csname if already set */ if (from->cs_name.str && !to->cs_name.str) { if (!(to->cs_name.str= my_once_memdup(from->cs_name.str, from->cs_name.length + 1, MYF(MY_WME)))) goto err; to->cs_name.length= from->cs_name.length; } if (from->coll_name.str) { if (!(to->coll_name.str= my_once_memdup(from->coll_name.str, from->coll_name.length + 1, MYF(MY_WME)))) goto err; to->coll_name.length= from->coll_name.length; } if (from->comment) if (!(to->comment= my_once_strdup(from->comment,MYF(MY_WME)))) goto err; if (from->m_ctype) { if (!(to->m_ctype= (uchar*) my_once_memdup((char*) from->m_ctype, MY_CS_CTYPE_TABLE_SIZE, MYF(MY_WME)))) goto err; if (init_state_maps(to)) goto err; } if (from->to_lower) if (!(to->to_lower= (uchar*) my_once_memdup((char*) from->to_lower, MY_CS_TO_LOWER_TABLE_SIZE, MYF(MY_WME)))) goto err; if (from->to_upper) if (!(to->to_upper= (uchar*) my_once_memdup((char*) from->to_upper, MY_CS_TO_UPPER_TABLE_SIZE, MYF(MY_WME)))) goto err; if (from->sort_order) { if (!(to->sort_order= (uchar*) my_once_memdup((char*) from->sort_order, MY_CS_SORT_ORDER_TABLE_SIZE, MYF(MY_WME)))) goto err; } if (from->tab_to_uni) { uint sz= MY_CS_TO_UNI_TABLE_SIZE*sizeof(uint16); if (!(to->tab_to_uni= (uint16*) my_once_memdup((char*)from->tab_to_uni, sz, MYF(MY_WME)))) goto err; } if (from->tailoring) if (!(to->tailoring= my_once_strdup(from->tailoring,MYF(MY_WME)))) goto err; return 0; err: return 1; }
O0
c
cs_copy_data: pushq %rbp movq %rsp, %rbp subq $0x20, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq -0x18(%rbp), %rax cmpl $0x0, (%rax) je 0x2be04 movq -0x18(%rbp), %rax movl (%rax), %eax movl %eax, -0x20(%rbp) jmp 0x2be0d movq -0x10(%rbp), %rax movl (%rax), %eax movl %eax, -0x20(%rbp) movl -0x20(%rbp), %ecx movq -0x10(%rbp), %rax movl %ecx, (%rax) movq -0x18(%rbp), %rax cmpq $0x0, 0x10(%rax) je 0x2be6d movq -0x10(%rbp), %rax cmpq $0x0, 0x10(%rax) jne 0x2be6d movq -0x18(%rbp), %rax movq 0x10(%rax), %rdi movq -0x18(%rbp), %rax movq 0x18(%rax), %rsi addq $0x1, %rsi movl $0x10, %edx callq 0x376e0 movq -0x10(%rbp), %rcx movq %rax, 0x10(%rcx) cmpq $0x0, %rax jne 0x2be5d jmp 0x2c049 movq -0x18(%rbp), %rax movq 0x18(%rax), %rcx movq -0x10(%rbp), %rax movq %rcx, 0x18(%rax) movq -0x18(%rbp), %rax cmpq $0x0, 0x20(%rax) je 0x2beb9 movq -0x18(%rbp), %rax movq 0x20(%rax), %rdi movq -0x18(%rbp), %rax movq 0x28(%rax), %rsi addq $0x1, %rsi movl $0x10, %edx callq 0x376e0 movq -0x10(%rbp), %rcx movq %rax, 0x20(%rcx) cmpq $0x0, %rax jne 0x2bea9 jmp 0x2c049 movq -0x18(%rbp), %rax movq 0x28(%rax), %rcx movq -0x10(%rbp), %rax movq %rcx, 0x28(%rax) movq -0x18(%rbp), %rax cmpq $0x0, 0x30(%rax) je 0x2beeb movq -0x18(%rbp), %rax movq 0x30(%rax), %rdi movl $0x10, %esi callq 0x37680 movq -0x10(%rbp), %rcx movq %rax, 0x30(%rcx) cmpq $0x0, %rax jne 0x2bee9 jmp 0x2c049 jmp 0x2beeb movq -0x18(%rbp), %rax cmpq $0x0, 0x40(%rax) je 0x2bf34 movq -0x18(%rbp), %rax movq 0x40(%rax), %rdi movl $0x101, %esi # imm = 0x101 movl $0x10, %edx callq 0x376e0 movq -0x10(%rbp), %rcx movq %rax, 0x40(%rcx) cmpq $0x0, %rax jne 0x2bf20 jmp 0x2c049 movq -0x10(%rbp), %rdi callq 0x2c160 cmpb $0x0, %al je 0x2bf32 jmp 0x2c049 jmp 0x2bf34 movq -0x18(%rbp), %rax cmpq $0x0, 0x48(%rax) je 0x2bf6b movq -0x18(%rbp), %rax movq 0x48(%rax), %rdi movl $0x100, %esi # imm = 0x100 movl $0x10, %edx callq 0x376e0 movq -0x10(%rbp), %rcx movq %rax, 0x48(%rcx) cmpq $0x0, %rax jne 0x2bf69 jmp 0x2c049 jmp 0x2bf6b movq -0x18(%rbp), %rax cmpq $0x0, 0x50(%rax) je 0x2bfa2 movq -0x18(%rbp), %rax movq 0x50(%rax), %rdi movl $0x100, %esi # imm = 0x100 movl $0x10, %edx callq 0x376e0 movq -0x10(%rbp), %rcx movq %rax, 0x50(%rcx) cmpq $0x0, %rax jne 0x2bfa0 jmp 0x2c049 jmp 0x2bfa2 movq -0x18(%rbp), %rax cmpq $0x0, 0x58(%rax) je 0x2bfd6 movq -0x18(%rbp), %rax movq 0x58(%rax), %rdi movl $0x100, %esi # imm = 0x100 movl $0x10, %edx callq 0x376e0 movq -0x10(%rbp), %rcx movq %rax, 0x58(%rcx) cmpq $0x0, %rax jne 0x2bfd4 jmp 0x2c049 jmp 0x2bfd6 movq -0x18(%rbp), %rax cmpq $0x0, 0x68(%rax) je 0x2c011 movl $0x200, -0x1c(%rbp) # imm = 0x200 movq -0x18(%rbp), %rax movq 0x68(%rax), %rdi movl -0x1c(%rbp), %eax movl %eax, %esi movl $0x10, %edx callq 0x376e0 movq -0x10(%rbp), %rcx movq %rax, 0x68(%rcx) cmpq $0x0, %rax jne 0x2c00f jmp 0x2c049 jmp 0x2c011 movq -0x18(%rbp), %rax cmpq $0x0, 0x38(%rax) je 0x2c040 movq -0x18(%rbp), %rax movq 0x38(%rax), %rdi movl $0x10, %esi callq 0x37680 movq -0x10(%rbp), %rcx movq %rax, 0x38(%rcx) cmpq $0x0, %rax jne 0x2c03e jmp 0x2c049 jmp 0x2c040 movl $0x0, -0x4(%rbp) jmp 0x2c050 movl $0x1, -0x4(%rbp) movl -0x4(%rbp), %eax addq $0x20, %rsp popq %rbp retq nopl (%rax)
cs_copy_data: push rbp mov rbp, rsp sub rsp, 20h mov [rbp+var_10], rdi mov [rbp+var_18], rsi mov rax, [rbp+var_18] cmp dword ptr [rax], 0 jz short loc_2BE04 mov rax, [rbp+var_18] mov eax, [rax] mov [rbp+var_20], eax jmp short loc_2BE0D loc_2BE04: mov rax, [rbp+var_10] mov eax, [rax] mov [rbp+var_20], eax loc_2BE0D: mov ecx, [rbp+var_20] mov rax, [rbp+var_10] mov [rax], ecx mov rax, [rbp+var_18] cmp qword ptr [rax+10h], 0 jz short loc_2BE6D mov rax, [rbp+var_10] cmp qword ptr [rax+10h], 0 jnz short loc_2BE6D mov rax, [rbp+var_18] mov rdi, [rax+10h] mov rax, [rbp+var_18] mov rsi, [rax+18h] add rsi, 1 mov edx, 10h call my_once_memdup mov rcx, [rbp+var_10] mov [rcx+10h], rax cmp rax, 0 jnz short loc_2BE5D jmp loc_2C049 loc_2BE5D: mov rax, [rbp+var_18] mov rcx, [rax+18h] mov rax, [rbp+var_10] mov [rax+18h], rcx loc_2BE6D: mov rax, [rbp+var_18] cmp qword ptr [rax+20h], 0 jz short loc_2BEB9 mov rax, [rbp+var_18] mov rdi, [rax+20h] mov rax, [rbp+var_18] mov rsi, [rax+28h] add rsi, 1 mov edx, 10h call my_once_memdup mov rcx, [rbp+var_10] mov [rcx+20h], rax cmp rax, 0 jnz short loc_2BEA9 jmp loc_2C049 loc_2BEA9: mov rax, [rbp+var_18] mov rcx, [rax+28h] mov rax, [rbp+var_10] mov [rax+28h], rcx loc_2BEB9: mov rax, [rbp+var_18] cmp qword ptr [rax+30h], 0 jz short loc_2BEEB mov rax, [rbp+var_18] mov rdi, [rax+30h] mov esi, 10h call my_once_strdup mov rcx, [rbp+var_10] mov [rcx+30h], rax cmp rax, 0 jnz short loc_2BEE9 jmp loc_2C049 loc_2BEE9: jmp short $+2 loc_2BEEB: mov rax, [rbp+var_18] cmp qword ptr [rax+40h], 0 jz short loc_2BF34 mov rax, [rbp+var_18] mov rdi, [rax+40h] mov esi, 101h mov edx, 10h call my_once_memdup mov rcx, [rbp+var_10] mov [rcx+40h], rax cmp rax, 0 jnz short loc_2BF20 jmp loc_2C049 loc_2BF20: mov rdi, [rbp+var_10] call init_state_maps cmp al, 0 jz short loc_2BF32 jmp loc_2C049 loc_2BF32: jmp short $+2 loc_2BF34: mov rax, [rbp+var_18] cmp qword ptr [rax+48h], 0 jz short loc_2BF6B mov rax, [rbp+var_18] mov rdi, [rax+48h] mov esi, 100h mov edx, 10h call my_once_memdup mov rcx, [rbp+var_10] mov [rcx+48h], rax cmp rax, 0 jnz short loc_2BF69 jmp loc_2C049 loc_2BF69: jmp short $+2 loc_2BF6B: mov rax, [rbp+var_18] cmp qword ptr [rax+50h], 0 jz short loc_2BFA2 mov rax, [rbp+var_18] mov rdi, [rax+50h] mov esi, 100h mov edx, 10h call my_once_memdup mov rcx, [rbp+var_10] mov [rcx+50h], rax cmp rax, 0 jnz short loc_2BFA0 jmp loc_2C049 loc_2BFA0: jmp short $+2 loc_2BFA2: mov rax, [rbp+var_18] cmp qword ptr [rax+58h], 0 jz short loc_2BFD6 mov rax, [rbp+var_18] mov rdi, [rax+58h] mov esi, 100h mov edx, 10h call my_once_memdup mov rcx, [rbp+var_10] mov [rcx+58h], rax cmp rax, 0 jnz short loc_2BFD4 jmp short loc_2C049 loc_2BFD4: jmp short $+2 loc_2BFD6: mov rax, [rbp+var_18] cmp qword ptr [rax+68h], 0 jz short loc_2C011 mov [rbp+var_1C], 200h mov rax, [rbp+var_18] mov rdi, [rax+68h] mov eax, [rbp+var_1C] mov esi, eax mov edx, 10h call my_once_memdup mov rcx, [rbp+var_10] mov [rcx+68h], rax cmp rax, 0 jnz short loc_2C00F jmp short loc_2C049 loc_2C00F: jmp short $+2 loc_2C011: mov rax, [rbp+var_18] cmp qword ptr [rax+38h], 0 jz short loc_2C040 mov rax, [rbp+var_18] mov rdi, [rax+38h] mov esi, 10h call my_once_strdup mov rcx, [rbp+var_10] mov [rcx+38h], rax cmp rax, 0 jnz short loc_2C03E jmp short loc_2C049 loc_2C03E: jmp short $+2 loc_2C040: mov [rbp+var_4], 0 jmp short loc_2C050 loc_2C049: mov [rbp+var_4], 1 loc_2C050: mov eax, [rbp+var_4] add rsp, 20h pop rbp retn
long long cs_copy_data(int *a1, int *a2) { long long v2; // rax long long v3; // rax long long v4; // rax long long v5; // rax long long v6; // rax long long v7; // rax long long v8; // rax long long v9; // rax long long v10; // rax int v12; // [rsp+0h] [rbp-20h] if ( *a2 ) v12 = *a2; else v12 = *a1; *a1 = v12; if ( *((_QWORD *)a2 + 2) && !*((_QWORD *)a1 + 2) ) { v2 = my_once_memdup(*((_QWORD *)a2 + 2), *((_QWORD *)a2 + 3) + 1LL, 16LL); *((_QWORD *)a1 + 2) = v2; if ( !v2 ) return 1; *((_QWORD *)a1 + 3) = *((_QWORD *)a2 + 3); } if ( !*((_QWORD *)a2 + 4) ) goto LABEL_11; v3 = my_once_memdup(*((_QWORD *)a2 + 4), *((_QWORD *)a2 + 5) + 1LL, 16LL); *((_QWORD *)a1 + 4) = v3; if ( !v3 ) return 1; *((_QWORD *)a1 + 5) = *((_QWORD *)a2 + 5); LABEL_11: if ( *((_QWORD *)a2 + 6) ) { v4 = my_once_strdup(*((_QWORD *)a2 + 6), 16LL); *((_QWORD *)a1 + 6) = v4; if ( !v4 ) return 1; } if ( *((_QWORD *)a2 + 8) ) { v5 = my_once_memdup(*((_QWORD *)a2 + 8), 257LL, 16LL); *((_QWORD *)a1 + 8) = v5; if ( !v5 || (unsigned __int8)init_state_maps(a1) ) return 1; } if ( *((_QWORD *)a2 + 9) ) { v6 = my_once_memdup(*((_QWORD *)a2 + 9), 256LL, 16LL); *((_QWORD *)a1 + 9) = v6; if ( !v6 ) return 1; } if ( *((_QWORD *)a2 + 10) ) { v7 = my_once_memdup(*((_QWORD *)a2 + 10), 256LL, 16LL); *((_QWORD *)a1 + 10) = v7; if ( !v7 ) return 1; } if ( *((_QWORD *)a2 + 11) ) { v8 = my_once_memdup(*((_QWORD *)a2 + 11), 256LL, 16LL); *((_QWORD *)a1 + 11) = v8; if ( !v8 ) return 1; } if ( *((_QWORD *)a2 + 13) ) { v9 = my_once_memdup(*((_QWORD *)a2 + 13), 512LL, 16LL); *((_QWORD *)a1 + 13) = v9; if ( !v9 ) return 1; } if ( *((_QWORD *)a2 + 7) ) { v10 = my_once_strdup(*((_QWORD *)a2 + 7), 16LL); *((_QWORD *)a1 + 7) = v10; if ( !v10 ) return 1; } return 0; }
cs_copy_data: PUSH RBP MOV RBP,RSP SUB RSP,0x20 MOV qword ptr [RBP + -0x10],RDI MOV qword ptr [RBP + -0x18],RSI MOV RAX,qword ptr [RBP + -0x18] CMP dword ptr [RAX],0x0 JZ 0x0012be04 MOV RAX,qword ptr [RBP + -0x18] MOV EAX,dword ptr [RAX] MOV dword ptr [RBP + -0x20],EAX JMP 0x0012be0d LAB_0012be04: MOV RAX,qword ptr [RBP + -0x10] MOV EAX,dword ptr [RAX] MOV dword ptr [RBP + -0x20],EAX LAB_0012be0d: MOV ECX,dword ptr [RBP + -0x20] MOV RAX,qword ptr [RBP + -0x10] MOV dword ptr [RAX],ECX MOV RAX,qword ptr [RBP + -0x18] CMP qword ptr [RAX + 0x10],0x0 JZ 0x0012be6d MOV RAX,qword ptr [RBP + -0x10] CMP qword ptr [RAX + 0x10],0x0 JNZ 0x0012be6d MOV RAX,qword ptr [RBP + -0x18] MOV RDI,qword ptr [RAX + 0x10] MOV RAX,qword ptr [RBP + -0x18] MOV RSI,qword ptr [RAX + 0x18] ADD RSI,0x1 MOV EDX,0x10 CALL 0x001376e0 MOV RCX,qword ptr [RBP + -0x10] MOV qword ptr [RCX + 0x10],RAX CMP RAX,0x0 JNZ 0x0012be5d JMP 0x0012c049 LAB_0012be5d: MOV RAX,qword ptr [RBP + -0x18] MOV RCX,qword ptr [RAX + 0x18] MOV RAX,qword ptr [RBP + -0x10] MOV qword ptr [RAX + 0x18],RCX LAB_0012be6d: MOV RAX,qword ptr [RBP + -0x18] CMP qword ptr [RAX + 0x20],0x0 JZ 0x0012beb9 MOV RAX,qword ptr [RBP + -0x18] MOV RDI,qword ptr [RAX + 0x20] MOV RAX,qword ptr [RBP + -0x18] MOV RSI,qword ptr [RAX + 0x28] ADD RSI,0x1 MOV EDX,0x10 CALL 0x001376e0 MOV RCX,qword ptr [RBP + -0x10] MOV qword ptr [RCX + 0x20],RAX CMP RAX,0x0 JNZ 0x0012bea9 JMP 0x0012c049 LAB_0012bea9: MOV RAX,qword ptr [RBP + -0x18] MOV RCX,qword ptr [RAX + 0x28] MOV RAX,qword ptr [RBP + -0x10] MOV qword ptr [RAX + 0x28],RCX LAB_0012beb9: MOV RAX,qword ptr [RBP + -0x18] CMP qword ptr [RAX + 0x30],0x0 JZ 0x0012beeb MOV RAX,qword ptr [RBP + -0x18] MOV RDI,qword ptr [RAX + 0x30] MOV ESI,0x10 CALL 0x00137680 MOV RCX,qword ptr [RBP + -0x10] MOV qword ptr [RCX + 0x30],RAX CMP RAX,0x0 JNZ 0x0012bee9 JMP 0x0012c049 LAB_0012bee9: JMP 0x0012beeb LAB_0012beeb: MOV RAX,qword ptr [RBP + -0x18] CMP qword ptr [RAX + 0x40],0x0 JZ 0x0012bf34 MOV RAX,qword ptr [RBP + -0x18] MOV RDI,qword ptr [RAX + 0x40] MOV ESI,0x101 MOV EDX,0x10 CALL 0x001376e0 MOV RCX,qword ptr [RBP + -0x10] MOV qword ptr [RCX + 0x40],RAX CMP RAX,0x0 JNZ 0x0012bf20 JMP 0x0012c049 LAB_0012bf20: MOV RDI,qword ptr [RBP + -0x10] CALL 0x0012c160 CMP AL,0x0 JZ 0x0012bf32 JMP 0x0012c049 LAB_0012bf32: JMP 0x0012bf34 LAB_0012bf34: MOV RAX,qword ptr [RBP + -0x18] CMP qword ptr [RAX + 0x48],0x0 JZ 0x0012bf6b MOV RAX,qword ptr [RBP + -0x18] MOV RDI,qword ptr [RAX + 0x48] MOV ESI,0x100 MOV EDX,0x10 CALL 0x001376e0 MOV RCX,qword ptr [RBP + -0x10] MOV qword ptr [RCX + 0x48],RAX CMP RAX,0x0 JNZ 0x0012bf69 JMP 0x0012c049 LAB_0012bf69: JMP 0x0012bf6b LAB_0012bf6b: MOV RAX,qword ptr [RBP + -0x18] CMP qword ptr [RAX + 0x50],0x0 JZ 0x0012bfa2 MOV RAX,qword ptr [RBP + -0x18] MOV RDI,qword ptr [RAX + 0x50] MOV ESI,0x100 MOV EDX,0x10 CALL 0x001376e0 MOV RCX,qword ptr [RBP + -0x10] MOV qword ptr [RCX + 0x50],RAX CMP RAX,0x0 JNZ 0x0012bfa0 JMP 0x0012c049 LAB_0012bfa0: JMP 0x0012bfa2 LAB_0012bfa2: MOV RAX,qword ptr [RBP + -0x18] CMP qword ptr [RAX + 0x58],0x0 JZ 0x0012bfd6 MOV RAX,qword ptr [RBP + -0x18] MOV RDI,qword ptr [RAX + 0x58] MOV ESI,0x100 MOV EDX,0x10 CALL 0x001376e0 MOV RCX,qword ptr [RBP + -0x10] MOV qword ptr [RCX + 0x58],RAX CMP RAX,0x0 JNZ 0x0012bfd4 JMP 0x0012c049 LAB_0012bfd4: JMP 0x0012bfd6 LAB_0012bfd6: MOV RAX,qword ptr [RBP + -0x18] CMP qword ptr [RAX + 0x68],0x0 JZ 0x0012c011 MOV dword ptr [RBP + -0x1c],0x200 MOV RAX,qword ptr [RBP + -0x18] MOV RDI,qword ptr [RAX + 0x68] MOV EAX,dword ptr [RBP + -0x1c] MOV ESI,EAX MOV EDX,0x10 CALL 0x001376e0 MOV RCX,qword ptr [RBP + -0x10] MOV qword ptr [RCX + 0x68],RAX CMP RAX,0x0 JNZ 0x0012c00f JMP 0x0012c049 LAB_0012c00f: JMP 0x0012c011 LAB_0012c011: MOV RAX,qword ptr [RBP + -0x18] CMP qword ptr [RAX + 0x38],0x0 JZ 0x0012c040 MOV RAX,qword ptr [RBP + -0x18] MOV RDI,qword ptr [RAX + 0x38] MOV ESI,0x10 CALL 0x00137680 MOV RCX,qword ptr [RBP + -0x10] MOV qword ptr [RCX + 0x38],RAX CMP RAX,0x0 JNZ 0x0012c03e JMP 0x0012c049 LAB_0012c03e: JMP 0x0012c040 LAB_0012c040: MOV dword ptr [RBP + -0x4],0x0 JMP 0x0012c050 LAB_0012c049: MOV dword ptr [RBP + -0x4],0x1 LAB_0012c050: MOV EAX,dword ptr [RBP + -0x4] ADD RSP,0x20 POP RBP RET
int4 cs_copy_data(int *param_1,int *param_2) { char cVar1; long lVar2; int local_28; int4 local_c; if (*param_2 == 0) { local_28 = *param_1; } else { local_28 = *param_2; } *param_1 = local_28; if ((*(long *)(param_2 + 4) == 0) || (*(long *)(param_1 + 4) != 0)) { LAB_0012be6d: if (*(long *)(param_2 + 8) != 0) { lVar2 = my_once_memdup(*(int8 *)(param_2 + 8),*(long *)(param_2 + 10) + 1,0x10); *(long *)(param_1 + 8) = lVar2; if (lVar2 == 0) goto LAB_0012c049; *(int8 *)(param_1 + 10) = *(int8 *)(param_2 + 10); } if (*(long *)(param_2 + 0xc) != 0) { lVar2 = my_once_strdup(*(int8 *)(param_2 + 0xc),0x10); *(long *)(param_1 + 0xc) = lVar2; if (lVar2 == 0) goto LAB_0012c049; } if (*(long *)(param_2 + 0x10) != 0) { lVar2 = my_once_memdup(*(int8 *)(param_2 + 0x10),0x101,0x10); *(long *)(param_1 + 0x10) = lVar2; if ((lVar2 == 0) || (cVar1 = init_state_maps(param_1), cVar1 != '\0')) goto LAB_0012c049; } if (*(long *)(param_2 + 0x12) != 0) { lVar2 = my_once_memdup(*(int8 *)(param_2 + 0x12),0x100,0x10); *(long *)(param_1 + 0x12) = lVar2; if (lVar2 == 0) goto LAB_0012c049; } if (*(long *)(param_2 + 0x14) != 0) { lVar2 = my_once_memdup(*(int8 *)(param_2 + 0x14),0x100,0x10); *(long *)(param_1 + 0x14) = lVar2; if (lVar2 == 0) goto LAB_0012c049; } if (*(long *)(param_2 + 0x16) != 0) { lVar2 = my_once_memdup(*(int8 *)(param_2 + 0x16),0x100,0x10); *(long *)(param_1 + 0x16) = lVar2; if (lVar2 == 0) goto LAB_0012c049; } if (*(long *)(param_2 + 0x1a) != 0) { lVar2 = my_once_memdup(*(int8 *)(param_2 + 0x1a),0x200,0x10); *(long *)(param_1 + 0x1a) = lVar2; if (lVar2 == 0) goto LAB_0012c049; } if (*(long *)(param_2 + 0xe) != 0) { lVar2 = my_once_strdup(*(int8 *)(param_2 + 0xe),0x10); *(long *)(param_1 + 0xe) = lVar2; if (lVar2 == 0) goto LAB_0012c049; } local_c = 0; } else { lVar2 = my_once_memdup(*(int8 *)(param_2 + 4),*(long *)(param_2 + 6) + 1,0x10); *(long *)(param_1 + 4) = lVar2; if (lVar2 != 0) { *(int8 *)(param_1 + 6) = *(int8 *)(param_2 + 6); goto LAB_0012be6d; } LAB_0012c049: local_c = 1; } return local_c; }
60,823
ma_write_static_record
eloqsql/storage/maria/ma_statrec.c
my_bool _ma_write_static_record(MARIA_HA *info, const uchar *record) { uchar temp[8]; /* max pointer length */ if (info->s->state.dellink != HA_OFFSET_ERROR && !info->append_insert_at_end) { my_off_t filepos=info->s->state.dellink; info->rec_cache.seek_not_done=1; /* We have done a seek */ if (info->s->file_read(info, &temp[0],info->s->base.rec_reflength, info->s->state.dellink+1, MYF(MY_NABP))) goto err; info->s->state.dellink= _ma_rec_pos(info->s, temp); info->state->del--; info->state->empty-=info->s->base.pack_reclength; if (info->s->file_write(info, record, info->s->base.reclength, filepos, MYF(MY_NABP))) goto err; } else { if (info->state->data_file_length > info->s->base.max_data_file_length- info->s->base.pack_reclength) { my_errno=HA_ERR_RECORD_FILE_FULL; return(2); } if (info->opt_flag & WRITE_CACHE_USED) { /* Cash in use */ if (my_b_write(&info->rec_cache, record, info->s->base.reclength)) goto err; if (info->s->base.pack_reclength != info->s->base.reclength) { uint length=info->s->base.pack_reclength - info->s->base.reclength; bzero(temp,length); if (my_b_write(&info->rec_cache, temp,length)) goto err; } } else { info->rec_cache.seek_not_done=1; /* We have done a seek */ if (info->s->file_write(info, record, info->s->base.reclength, info->state->data_file_length, info->s->write_flag)) goto err; if (info->s->base.pack_reclength != info->s->base.reclength) { uint length=info->s->base.pack_reclength - info->s->base.reclength; bzero(temp,length); if (info->s->file_write(info, temp,length, info->state->data_file_length+ info->s->base.reclength, info->s->write_flag)) goto err; } } info->state->data_file_length+=info->s->base.pack_reclength; info->s->state.split++; } return 0; err: return 1; }
O3
c
ma_write_static_record: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x18, %rsp movq %rsi, %r14 movq %rdi, %rbx movq %fs:0x28, %rax movq %rax, -0x30(%rbp) movq (%rdi), %rax movq 0xc8(%rax), %r15 cmpq $-0x1, %r15 je 0x5b3a9 cmpb $0x0, 0x681(%rbx) je 0x5b47c movq 0x20(%rbx), %rcx movq 0x368(%rax), %rdx subq 0x3a0(%rax), %rdx cmpq %rdx, 0x28(%rcx) jbe 0x5b3d4 callq 0xa1b22 movl $0x87, (%rax) movb $0x2, %r14b jmp 0x5b5f1 testb $0x10, 0x61c(%rbx) jne 0x5b50e movl $0x1, 0x598(%rbx) movq 0x398(%rax), %rdx movq 0x28(%rcx), %rcx movq 0x7c8(%rax), %r8 movq %rbx, %rdi movq %r14, %rsi callq *0x6e8(%rax) movb $0x1, %r14b testq %rax, %rax jne 0x5b5f1 movq (%rbx), %r13 movq 0x398(%r13), %rax movq 0x3a0(%r13), %r15 cmpq %rax, %r15 je 0x5b5d2 subl %eax, %r15d leaq -0x38(%rbp), %r12 movl $0x8, %ecx movq %r12, %rdi xorl %esi, %esi movq %r15, %rdx callq 0x297f0 movq 0x20(%rbx), %rax movq 0x398(%r13), %rcx addq 0x28(%rax), %rcx movq 0x7c8(%r13), %r8 movq %rbx, %rdi movq %r12, %rsi movq %r15, %rdx callq *0x6e8(%r13) testq %rax, %rax jne 0x5b5f1 jmp 0x5b5d2 movl $0x1, 0x598(%rbx) movl 0x3e0(%rax), %edx movq 0xc8(%rax), %rcx incq %rcx leaq -0x38(%rbp), %rsi movl $0x4, %r8d movq %rbx, %rdi callq *0x6e0(%rax) testq %rax, %rax jne 0x5b506 movq (%rbx), %rdi leaq -0x38(%rbp), %rsi callq 0x57159 movq (%rbx), %rcx movq %rax, 0xc8(%rcx) movq 0x20(%rbx), %rax decq 0x8(%rax) movq (%rbx), %rax movq 0x20(%rbx), %rcx movq 0x3a0(%rax), %rax subq %rax, 0x10(%rcx) movq (%rbx), %rax movq 0x398(%rax), %rdx movl $0x4, %r8d movq %rbx, %rdi movq %r14, %rsi movq %r15, %rcx callq *0x6e8(%rax) testq %rax, %rax je 0x5b5ee movb $0x1, %r14b jmp 0x5b5f1 leaq 0x4b8(%rbx), %r15 movq 0x398(%rax), %r12 movq 0x4f8(%rbx), %rdi leaq (%rdi,%r12), %rax cmpq 0x500(%rbx), %rax jbe 0x5b54b movq %r15, %rdi movq %r14, %rsi movq %r12, %rdx callq 0x95823 movb $0x1, %r14b testl %eax, %eax jne 0x5b5f1 jmp 0x5b562 testq %r12, %r12 je 0x5b562 movq %r14, %rsi movq %r12, %rdx callq 0x29080 addq %r12, 0x4f8(%rbx) movq (%rbx), %rcx movq 0x398(%rcx), %rax movq 0x3a0(%rcx), %r14 cmpq %rax, %r14 je 0x5b5d2 subl %eax, %r14d leaq -0x38(%rbp), %rdi movl $0x8, %ecx xorl %esi, %esi movq %r14, %rdx callq 0x297f0 movq 0x4f8(%rbx), %rdi leaq (%rdi,%r14), %rax cmpq 0x500(%rbx), %rax jbe 0x5b5ba leaq -0x38(%rbp), %rsi movq %r15, %rdi movq %r14, %rdx callq 0x95823 movb $0x1, %r14b testl %eax, %eax jne 0x5b5f1 jmp 0x5b5d2 testq %r14, %r14 je 0x5b5d2 leaq -0x38(%rbp), %rsi movq %r14, %rdx callq 0x29080 addq %r14, 0x4f8(%rbx) movq (%rbx), %rax movq 0x20(%rbx), %rcx movq 0x3a0(%rax), %rax addq %rax, 0x28(%rcx) movq (%rbx), %rax incq 0xc0(%rax) xorl %r14d, %r14d movq %fs:0x28, %rax cmpq -0x30(%rbp), %rax jne 0x5b612 movl %r14d, %eax addq $0x18, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq callq 0x29270
_ma_write_static_record: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx sub rsp, 18h mov r14, rsi mov rbx, rdi mov rax, fs:28h mov [rbp+var_30], rax mov rax, [rdi] mov r15, [rax+0C8h] cmp r15, 0FFFFFFFFFFFFFFFFh jz short loc_5B3A9 cmp byte ptr [rbx+681h], 0 jz loc_5B47C loc_5B3A9: mov rcx, [rbx+20h] mov rdx, [rax+368h] sub rdx, [rax+3A0h] cmp [rcx+28h], rdx jbe short loc_5B3D4 call _my_thread_var mov dword ptr [rax], 87h mov r14b, 2 jmp loc_5B5F1 loc_5B3D4: test byte ptr [rbx+61Ch], 10h jnz loc_5B50E mov dword ptr [rbx+598h], 1 mov rdx, [rax+398h] mov rcx, [rcx+28h] mov r8, [rax+7C8h] mov rdi, rbx mov rsi, r14 call qword ptr [rax+6E8h] mov r14b, 1 test rax, rax jnz loc_5B5F1 mov r13, [rbx] mov rax, [r13+398h] mov r15, [r13+3A0h] cmp r15, rax jz loc_5B5D2 sub r15d, eax lea r12, [rbp+var_38] mov ecx, 8 mov rdi, r12 xor esi, esi mov rdx, r15 call ___memset_chk mov rax, [rbx+20h] mov rcx, [r13+398h] add rcx, [rax+28h] mov r8, [r13+7C8h] mov rdi, rbx mov rsi, r12 mov rdx, r15 call qword ptr [r13+6E8h] test rax, rax jnz loc_5B5F1 jmp loc_5B5D2 loc_5B47C: mov dword ptr [rbx+598h], 1 mov edx, [rax+3E0h] mov rcx, [rax+0C8h] inc rcx lea rsi, [rbp+var_38] mov r8d, 4 mov rdi, rbx call qword ptr [rax+6E0h] test rax, rax jnz short loc_5B506 mov rdi, [rbx] lea rsi, [rbp+var_38] call _ma_rec_pos mov rcx, [rbx] mov [rcx+0C8h], rax mov rax, [rbx+20h] dec qword ptr [rax+8] mov rax, [rbx] mov rcx, [rbx+20h] mov rax, [rax+3A0h] sub [rcx+10h], rax mov rax, [rbx] mov rdx, [rax+398h] mov r8d, 4 mov rdi, rbx mov rsi, r14 mov rcx, r15 call qword ptr [rax+6E8h] test rax, rax jz loc_5B5EE loc_5B506: mov r14b, 1 jmp loc_5B5F1 loc_5B50E: lea r15, [rbx+4B8h] mov r12, [rax+398h] mov rdi, [rbx+4F8h] lea rax, [rdi+r12] cmp rax, [rbx+500h] jbe short loc_5B54B mov rdi, r15 mov rsi, r14 mov rdx, r12 call _my_b_write mov r14b, 1 test eax, eax jnz loc_5B5F1 jmp short loc_5B562 loc_5B54B: test r12, r12 jz short loc_5B562 mov rsi, r14 mov rdx, r12 call _memcpy add [rbx+4F8h], r12 loc_5B562: mov rcx, [rbx] mov rax, [rcx+398h] mov r14, [rcx+3A0h] cmp r14, rax jz short loc_5B5D2 sub r14d, eax lea rdi, [rbp+var_38] mov ecx, 8 xor esi, esi mov rdx, r14 call ___memset_chk mov rdi, [rbx+4F8h] lea rax, [rdi+r14] cmp rax, [rbx+500h] jbe short loc_5B5BA lea rsi, [rbp+var_38] mov rdi, r15 mov rdx, r14 call _my_b_write mov r14b, 1 test eax, eax jnz short loc_5B5F1 jmp short loc_5B5D2 loc_5B5BA: test r14, r14 jz short loc_5B5D2 lea rsi, [rbp+var_38] mov rdx, r14 call _memcpy add [rbx+4F8h], r14 loc_5B5D2: mov rax, [rbx] mov rcx, [rbx+20h] mov rax, [rax+3A0h] add [rcx+28h], rax mov rax, [rbx] inc qword ptr [rax+0C0h] loc_5B5EE: xor r14d, r14d loc_5B5F1: mov rax, fs:28h cmp rax, [rbp+var_30] jnz short loc_5B612 mov eax, r14d add rsp, 18h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn loc_5B612: call ___stack_chk_fail
long long ma_write_static_record(_DWORD *a1, const char *a2) { long long v2; // r14 long long v4; // rax long long v5; // r15 long long v6; // rcx long long v7; // r13 long long v8; // rax long long v9; // r15 long long v10; // r15 long long v11; // rdx long long v12; // r12 long long v13; // rdi long long v14; // rax long long v15; // r14 long long v16; // rdi int v17; // eax __int16 v19; // [rsp+8h] [rbp-38h] BYREF unsigned long long v20; // [rsp+10h] [rbp-30h] LODWORD(v2) = (_DWORD)a2; v20 = __readfsqword(0x28u); v4 = *(_QWORD *)a1; v5 = *(_QWORD *)(*(_QWORD *)a1 + 200LL); if ( v5 != -1 && !*((_BYTE *)a1 + 1665) ) { a1[358] = 1; if ( (*(long long ( **)(_DWORD *, __int16 *, _QWORD, long long, long long))(v4 + 1760))( a1, &v19, *(unsigned int *)(v4 + 992), *(_QWORD *)(v4 + 200) + 1LL, 4LL) || (*(_QWORD *)(*(_QWORD *)a1 + 200LL) = ma_rec_pos(*(_QWORD *)a1, &v19, v11), --*(_QWORD *)(*((_QWORD *)a1 + 4) + 8LL), *(_QWORD *)(*((_QWORD *)a1 + 4) + 16LL) -= *(_QWORD *)(*(_QWORD *)a1 + 928LL), (*(long long ( **)(_DWORD *, const char *, _QWORD, long long, long long))(*(_QWORD *)a1 + 1768LL))( a1, a2, *(_QWORD *)(*(_QWORD *)a1 + 920LL), v5, 4LL)) ) { LOBYTE(v2) = 1; return (unsigned int)v2; } LABEL_25: LODWORD(v2) = 0; return (unsigned int)v2; } v6 = *((_QWORD *)a1 + 4); if ( *(_QWORD *)(v6 + 40) > *(_QWORD *)(v4 + 872) - *(_QWORD *)(v4 + 928) ) { *(_DWORD *)my_thread_var(a1, a2) = 135; LOBYTE(v2) = 2; return (unsigned int)v2; } if ( (a1[391] & 0x10) != 0 ) { v12 = *(_QWORD *)(v4 + 920); v13 = *((_QWORD *)a1 + 159); if ( (unsigned long long)(v13 + v12) <= *((_QWORD *)a1 + 160) ) { if ( v12 ) { memcpy(v13, a2, v12); *((_QWORD *)a1 + 159) += v12; } } else { LOBYTE(v2) = 1; if ( (unsigned int)my_b_write(a1 + 302, a2, v12) ) return (unsigned int)v2; } v14 = *(_QWORD *)(*(_QWORD *)a1 + 920LL); v15 = *(_QWORD *)(*(_QWORD *)a1 + 928LL); if ( v15 != v14 ) { v2 = (unsigned int)(v15 - v14); __memset_chk(&v19, 0LL, v2, 8LL); v16 = *((_QWORD *)a1 + 159); if ( (unsigned long long)(v16 + v2) <= *((_QWORD *)a1 + 160) ) { if ( v2 ) { memcpy(v16, &v19, v2); *((_QWORD *)a1 + 159) += v2; } } else { v17 = my_b_write(a1 + 302, &v19, v2); LOBYTE(v2) = 1; if ( v17 ) return (unsigned int)v2; } } goto LABEL_24; } a1[358] = 1; LOBYTE(v2) = 1; if ( !(*(long long ( **)(_DWORD *, const char *, _QWORD, _QWORD, _QWORD))(v4 + 1768))( a1, a2, *(_QWORD *)(v4 + 920), *(_QWORD *)(v6 + 40), *(_QWORD *)(v4 + 1992)) ) { v7 = *(_QWORD *)a1; v8 = *(_QWORD *)(*(_QWORD *)a1 + 920LL); v9 = *(_QWORD *)(*(_QWORD *)a1 + 928LL); if ( v9 == v8 || (v10 = (unsigned int)(v9 - v8), __memset_chk(&v19, 0LL, v10, 8LL), !(*(long long ( **)(_DWORD *, __int16 *, long long, _QWORD, _QWORD))(v7 + 1768))( a1, &v19, v10, *(_QWORD *)(*((_QWORD *)a1 + 4) + 40LL) + *(_QWORD *)(v7 + 920), *(_QWORD *)(v7 + 1992))) ) { LABEL_24: *(_QWORD *)(*((_QWORD *)a1 + 4) + 40LL) += *(_QWORD *)(*(_QWORD *)a1 + 928LL); ++*(_QWORD *)(*(_QWORD *)a1 + 192LL); goto LABEL_25; } } return (unsigned int)v2; }
_ma_write_static_record: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x18 MOV R14,RSI MOV RBX,RDI MOV RAX,qword ptr FS:[0x28] MOV qword ptr [RBP + -0x30],RAX MOV RAX,qword ptr [RDI] MOV R15,qword ptr [RAX + 0xc8] CMP R15,-0x1 JZ 0x0015b3a9 CMP byte ptr [RBX + 0x681],0x0 JZ 0x0015b47c LAB_0015b3a9: MOV RCX,qword ptr [RBX + 0x20] MOV RDX,qword ptr [RAX + 0x368] SUB RDX,qword ptr [RAX + 0x3a0] CMP qword ptr [RCX + 0x28],RDX JBE 0x0015b3d4 CALL 0x001a1b22 MOV dword ptr [RAX],0x87 MOV R14B,0x2 JMP 0x0015b5f1 LAB_0015b3d4: TEST byte ptr [RBX + 0x61c],0x10 JNZ 0x0015b50e MOV dword ptr [RBX + 0x598],0x1 MOV RDX,qword ptr [RAX + 0x398] MOV RCX,qword ptr [RCX + 0x28] MOV R8,qword ptr [RAX + 0x7c8] MOV RDI,RBX MOV RSI,R14 CALL qword ptr [RAX + 0x6e8] MOV R14B,0x1 TEST RAX,RAX JNZ 0x0015b5f1 MOV R13,qword ptr [RBX] MOV RAX,qword ptr [R13 + 0x398] MOV R15,qword ptr [R13 + 0x3a0] CMP R15,RAX JZ 0x0015b5d2 SUB R15D,EAX LEA R12,[RBP + -0x38] MOV ECX,0x8 MOV RDI,R12 XOR ESI,ESI MOV RDX,R15 CALL 0x001297f0 MOV RAX,qword ptr [RBX + 0x20] MOV RCX,qword ptr [R13 + 0x398] ADD RCX,qword ptr [RAX + 0x28] MOV R8,qword ptr [R13 + 0x7c8] MOV RDI,RBX MOV RSI,R12 MOV RDX,R15 CALL qword ptr [R13 + 0x6e8] TEST RAX,RAX JNZ 0x0015b5f1 JMP 0x0015b5d2 LAB_0015b47c: MOV dword ptr [RBX + 0x598],0x1 MOV EDX,dword ptr [RAX + 0x3e0] MOV RCX,qword ptr [RAX + 0xc8] INC RCX LEA RSI,[RBP + -0x38] MOV R8D,0x4 MOV RDI,RBX CALL qword ptr [RAX + 0x6e0] TEST RAX,RAX JNZ 0x0015b506 MOV RDI,qword ptr [RBX] LEA RSI,[RBP + -0x38] CALL 0x00157159 MOV RCX,qword ptr [RBX] MOV qword ptr [RCX + 0xc8],RAX MOV RAX,qword ptr [RBX + 0x20] DEC qword ptr [RAX + 0x8] MOV RAX,qword ptr [RBX] MOV RCX,qword ptr [RBX + 0x20] MOV RAX,qword ptr [RAX + 0x3a0] SUB qword ptr [RCX + 0x10],RAX MOV RAX,qword ptr [RBX] MOV RDX,qword ptr [RAX + 0x398] MOV R8D,0x4 MOV RDI,RBX MOV RSI,R14 MOV RCX,R15 CALL qword ptr [RAX + 0x6e8] TEST RAX,RAX JZ 0x0015b5ee LAB_0015b506: MOV R14B,0x1 JMP 0x0015b5f1 LAB_0015b50e: LEA R15,[RBX + 0x4b8] MOV R12,qword ptr [RAX + 0x398] MOV RDI,qword ptr [RBX + 0x4f8] LEA RAX,[RDI + R12*0x1] CMP RAX,qword ptr [RBX + 0x500] JBE 0x0015b54b MOV RDI,R15 MOV RSI,R14 MOV RDX,R12 CALL 0x00195823 MOV R14B,0x1 TEST EAX,EAX JNZ 0x0015b5f1 JMP 0x0015b562 LAB_0015b54b: TEST R12,R12 JZ 0x0015b562 MOV RSI,R14 MOV RDX,R12 CALL 0x00129080 ADD qword ptr [RBX + 0x4f8],R12 LAB_0015b562: MOV RCX,qword ptr [RBX] MOV RAX,qword ptr [RCX + 0x398] MOV R14,qword ptr [RCX + 0x3a0] CMP R14,RAX JZ 0x0015b5d2 SUB R14D,EAX LEA RDI,[RBP + -0x38] MOV ECX,0x8 XOR ESI,ESI MOV RDX,R14 CALL 0x001297f0 MOV RDI,qword ptr [RBX + 0x4f8] LEA RAX,[RDI + R14*0x1] CMP RAX,qword ptr [RBX + 0x500] JBE 0x0015b5ba LEA RSI,[RBP + -0x38] MOV RDI,R15 MOV RDX,R14 CALL 0x00195823 MOV R14B,0x1 TEST EAX,EAX JNZ 0x0015b5f1 JMP 0x0015b5d2 LAB_0015b5ba: TEST R14,R14 JZ 0x0015b5d2 LEA RSI,[RBP + -0x38] MOV RDX,R14 CALL 0x00129080 ADD qword ptr [RBX + 0x4f8],R14 LAB_0015b5d2: MOV RAX,qword ptr [RBX] MOV RCX,qword ptr [RBX + 0x20] MOV RAX,qword ptr [RAX + 0x3a0] ADD qword ptr [RCX + 0x28],RAX MOV RAX,qword ptr [RBX] INC qword ptr [RAX + 0xc0] LAB_0015b5ee: XOR R14D,R14D LAB_0015b5f1: MOV RAX,qword ptr FS:[0x28] CMP RAX,qword ptr [RBP + -0x30] JNZ 0x0015b612 MOV EAX,R14D ADD RSP,0x18 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET LAB_0015b612: CALL 0x00129270
ulong _ma_write_static_record(long *param_1,void *param_2) { long lVar1; size_t __n; int4 *puVar2; long lVar3; int8 uVar4; uint uVar5; int7 uVar7; ulong uVar6; int iVar8; long in_FS_OFFSET; int1 local_40 [8]; long local_38; local_38 = *(long *)(in_FS_OFFSET + 0x28); lVar3 = *param_1; lVar1 = *(long *)(lVar3 + 200); uVar7 = (int7)((ulong)param_2 >> 8); if ((lVar1 == -1) || (*(char *)((long)param_1 + 0x681) != '\0')) { if ((ulong)(*(long *)(lVar3 + 0x368) - *(long *)(lVar3 + 0x3a0)) < *(ulong *)(param_1[4] + 0x28) ) { puVar2 = (int4 *)_my_thread_var(); *puVar2 = 0x87; uVar6 = CONCAT71(uVar7,2); goto LAB_0015b5f1; } if ((*(byte *)((long)param_1 + 0x61c) & 0x10) == 0) { *(int4 *)(param_1 + 0xb3) = 1; lVar3 = (**(code **)(lVar3 + 0x6e8)) (param_1,param_2,*(int8 *)(lVar3 + 0x398), *(int8 *)(param_1[4] + 0x28),*(int8 *)(lVar3 + 0x7c8)); uVar6 = CONCAT71(uVar7,1); if (lVar3 != 0) goto LAB_0015b5f1; lVar3 = *param_1; if (*(long *)(lVar3 + 0x3a0) != *(long *)(lVar3 + 0x398)) { iVar8 = (int)*(long *)(lVar3 + 0x3a0) - (int)*(long *)(lVar3 + 0x398); __memset_chk(local_40,0,iVar8,8); lVar3 = (**(code **)(lVar3 + 0x6e8)) (param_1,local_40,iVar8, *(long *)(lVar3 + 0x398) + *(long *)(param_1[4] + 0x28), *(int8 *)(lVar3 + 0x7c8)); if (lVar3 != 0) goto LAB_0015b5f1; } } else { __n = *(size_t *)(lVar3 + 0x398); if ((ulong)param_1[0xa0] < param_1[0x9f] + __n) { iVar8 = _my_b_write(param_1 + 0x97,param_2,__n); uVar6 = CONCAT71(uVar7,1); if (iVar8 != 0) goto LAB_0015b5f1; } else if (__n != 0) { memcpy((void *)param_1[0x9f],param_2,__n); param_1[0x9f] = param_1[0x9f] + __n; } lVar3 = *(long *)(*param_1 + 0x398); lVar1 = *(long *)(*param_1 + 0x3a0); if (lVar1 != lVar3) { uVar5 = (int)lVar1 - (int)lVar3; uVar6 = (ulong)uVar5; __memset_chk(local_40,0,uVar6,8); if ((ulong)param_1[0xa0] < param_1[0x9f] + uVar6) { iVar8 = _my_b_write(param_1 + 0x97,local_40,uVar6); uVar6 = CONCAT71((uint7)(uint3)(uVar5 >> 8),1); if (iVar8 != 0) goto LAB_0015b5f1; } else if (uVar6 != 0) { memcpy((void *)param_1[0x9f],local_40,uVar6); param_1[0x9f] = param_1[0x9f] + uVar6; } } } *(long *)(param_1[4] + 0x28) = *(long *)(param_1[4] + 0x28) + *(long *)(*param_1 + 0x3a0); *(long *)(*param_1 + 0xc0) = *(long *)(*param_1 + 0xc0) + 1; LAB_0015b5ee: uVar6 = 0; } else { *(int4 *)(param_1 + 0xb3) = 1; lVar3 = (**(code **)(lVar3 + 0x6e0)) (param_1,local_40,*(int4 *)(lVar3 + 0x3e0),*(long *)(lVar3 + 200) + 1,4) ; if (lVar3 == 0) { uVar4 = _ma_rec_pos(*param_1,local_40); *(int8 *)(*param_1 + 200) = uVar4; *(long *)(param_1[4] + 8) = *(long *)(param_1[4] + 8) + -1; *(long *)(param_1[4] + 0x10) = *(long *)(param_1[4] + 0x10) - *(long *)(*param_1 + 0x3a0); lVar3 = (**(code **)(*param_1 + 0x6e8)) (param_1,param_2,*(int8 *)(*param_1 + 0x398),lVar1,4); if (lVar3 == 0) goto LAB_0015b5ee; } uVar6 = CONCAT71(uVar7,1); } LAB_0015b5f1: if (*(long *)(in_FS_OFFSET + 0x28) != local_38) { /* WARNING: Subroutine does not return */ __stack_chk_fail(); } return uVar6 & 0xffffffff; }
60,824
sampler_tester::sampler_tester(std::vector<float, std::allocator<float>> const&, std::vector<float, std::allocator<float>> const&)
monkey531[P]llama/tests/test-sampling.cpp
sampler_tester(const std::vector<float> & probs, const std::vector<float> & probs_expected) : probs_expected(probs_expected) { cur.reserve(probs.size()); for (llama_token token_id = 0; token_id < (llama_token)probs.size(); token_id++) { const float logit = logf(probs[token_id]); cur.emplace_back(llama_token_data{token_id, logit, probs[token_id]}); } cur_p = llama_token_data_array { cur.data(), cur.size(), -1, false }; }
O2
cpp
sampler_tester::sampler_tester(std::vector<float, std::allocator<float>> const&, std::vector<float, std::allocator<float>> const&): pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x18, %rsp movq %rsi, %r12 movq %rdi, %r14 leaq 0x20(%rdi), %rbx movq %rbx, %rdi movq %rdx, %rsi callq 0x5258 leaq 0x38(%r14), %r15 xorps %xmm0, %xmm0 movups %xmm0, 0x38(%r14) andq $0x0, 0x48(%r14) movq 0x8(%r12), %rsi subq (%r12), %rsi sarq $0x2, %rsi movq %r15, %rdi callq 0x52a6 xorl %ebp, %ebp leaq 0xc(%rsp), %r13 movq (%r12), %rax movq 0x8(%r12), %rcx subq %rax, %rcx shrq $0x2, %rcx movslq %ecx, %rcx cmpq %rcx, %rbp jge 0x5147 movss (%rax,%rbp,4), %xmm0 callq 0x22b0 movl %ebp, 0xc(%rsp) movss %xmm0, 0x10(%rsp) movq (%r12), %rax movss (%rax,%rbp,4), %xmm0 movss %xmm0, 0x14(%rsp) movq %r15, %rdi movq %r13, %rsi callq 0x5352 incq %rbp jmp 0x50fc movq 0x38(%r14), %rcx movq 0x40(%r14), %rax subq %rcx, %rax pushq $0xc popq %rsi cqto idivq %rsi movq %rcx, (%r14) movq %rax, 0x8(%r14) orq $-0x1, 0x10(%r14) movb $0x0, 0x18(%r14) addq $0x18, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq jmp 0x517c movq %rax, %r14 movq %r15, %rdi callq 0x55ae movq %rbx, %rdi callq 0x5390 movq %r14, %rdi callq 0x2270 nop
_ZN14sampler_testerC2ERKSt6vectorIfSaIfEES4_: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 18h mov r12, rsi mov r14, rdi lea rbx, [rdi+20h] mov rdi, rbx mov rsi, rdx call _ZNSt6vectorIfSaIfEEC2ERKS1_; std::vector<float>::vector(std::vector<float> const&) lea r15, [r14+38h] xorps xmm0, xmm0 movups xmmword ptr [r14+38h], xmm0 and qword ptr [r14+48h], 0 mov rsi, [r12+8] sub rsi, [r12] sar rsi, 2 mov rdi, r15 call _ZNSt6vectorI16llama_token_dataSaIS0_EE7reserveEm; std::vector<llama_token_data>::reserve(ulong) xor ebp, ebp lea r13, [rsp+48h+var_3C] loc_50FC: mov rax, [r12] mov rcx, [r12+8] sub rcx, rax shr rcx, 2 movsxd rcx, ecx cmp rbp, rcx jge short loc_5147 movss xmm0, dword ptr [rax+rbp*4] call _logf mov [rsp+48h+var_3C], ebp movss [rsp+48h+var_38], xmm0 mov rax, [r12] movss xmm0, dword ptr [rax+rbp*4] movss [rsp+48h+var_34], xmm0 mov rdi, r15 mov rsi, r13 call _ZNSt6vectorI16llama_token_dataSaIS0_EE12emplace_backIJS0_EEERS0_DpOT_; std::vector<llama_token_data>::emplace_back<llama_token_data>(llama_token_data &&) inc rbp jmp short loc_50FC loc_5147: mov rcx, [r14+38h] mov rax, [r14+40h] sub rax, rcx push 0Ch pop rsi cqo idiv rsi mov [r14], rcx mov [r14+8], rax or qword ptr [r14+10h], 0FFFFFFFFFFFFFFFFh mov byte ptr [r14+18h], 0 add rsp, 18h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn jmp short $+2 loc_517C: mov r14, rax mov rdi, r15 call _ZNSt12_Vector_baseI16llama_token_dataSaIS0_EED2Ev; std::_Vector_base<llama_token_data>::~_Vector_base() mov rdi, rbx call _ZNSt12_Vector_baseIfSaIfEED2Ev; std::_Vector_base<float>::~_Vector_base() mov rdi, r14 call __Unwind_Resume
long long sampler_tester::sampler_tester(long long a1, _QWORD *a2, long long a3) { long long i; // rbp float v4; // xmm0_4 long long v5; // rcx long long result; // rax _DWORD v7[15]; // [rsp+Ch] [rbp-3Ch] BYREF std::vector<float>::vector(a1 + 32, a3); *(_OWORD *)(a1 + 56) = 0LL; *(_QWORD *)(a1 + 72) = 0LL; std::vector<llama_token_data>::reserve(a1 + 56, (long long)(a2[1] - *a2) >> 2); for ( i = 0LL; i < (int)((a2[1] - *a2) >> 2); ++i ) { v4 = logf(*(float *)(*a2 + 4 * i)); v7[0] = i; *(float *)&v7[1] = v4; v7[2] = *(_DWORD *)(*a2 + 4 * i); std::vector<llama_token_data>::emplace_back<llama_token_data>(a1 + 56, v7); } v5 = *(_QWORD *)(a1 + 56); result = (*(_QWORD *)(a1 + 64) - v5) / 12; *(_QWORD *)a1 = v5; *(_QWORD *)(a1 + 8) = result; *(_QWORD *)(a1 + 16) = -1LL; *(_BYTE *)(a1 + 24) = 0; return result; }
sampler_tester: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x18 MOV R12,RSI MOV R14,RDI LEA RBX,[RDI + 0x20] MOV RDI,RBX MOV RSI,RDX CALL 0x00105258 LEA R15,[R14 + 0x38] XORPS XMM0,XMM0 MOVUPS xmmword ptr [R14 + 0x38],XMM0 AND qword ptr [R14 + 0x48],0x0 MOV RSI,qword ptr [R12 + 0x8] SUB RSI,qword ptr [R12] SAR RSI,0x2 LAB_001050ed: MOV RDI,R15 CALL 0x001052a6 XOR EBP,EBP LEA R13,[RSP + 0xc] LAB_001050fc: MOV RAX,qword ptr [R12] MOV RCX,qword ptr [R12 + 0x8] SUB RCX,RAX SHR RCX,0x2 MOVSXD RCX,ECX CMP RBP,RCX JGE 0x00105147 MOVSS XMM0,dword ptr [RAX + RBP*0x4] CALL 0x001022b0 MOV dword ptr [RSP + 0xc],EBP MOVSS dword ptr [RSP + 0x10],XMM0 MOV RAX,qword ptr [R12] MOVSS XMM0,dword ptr [RAX + RBP*0x4] MOVSS dword ptr [RSP + 0x14],XMM0 LAB_00105137: MOV RDI,R15 MOV RSI,R13 CALL 0x00105352 LAB_00105142: INC RBP JMP 0x001050fc LAB_00105147: MOV RCX,qword ptr [R14 + 0x38] MOV RAX,qword ptr [R14 + 0x40] SUB RAX,RCX PUSH 0xc POP RSI CQO IDIV RSI MOV qword ptr [R14],RCX MOV qword ptr [R14 + 0x8],RAX OR qword ptr [R14 + 0x10],-0x1 MOV byte ptr [R14 + 0x18],0x0 ADD RSP,0x18 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
/* sampler_tester::sampler_tester(std::vector<float, std::allocator<float> > const&, std::vector<float, std::allocator<float> > const&) */ void __thiscall sampler_tester::sampler_tester(sampler_tester *this,vector *param_1,vector *param_2) { long lVar1; int4 local_3c; float local_38; int4 local_34; std::vector<float,std::allocator<float>>::vector ((vector<float,std::allocator<float>> *)(this + 0x20),param_2); *(int8 *)(this + 0x38) = 0; *(int8 *)(this + 0x40) = 0; *(int8 *)(this + 0x48) = 0; /* try { // try from 001050ed to 001050f4 has its CatchHandler @ 0010517a */ std::vector<llama_token_data,std::allocator<llama_token_data>>::reserve ((vector<llama_token_data,std::allocator<llama_token_data>> *)(this + 0x38), *(long *)(param_1 + 8) - *(long *)param_1 >> 2); for (lVar1 = 0; lVar1 < (int)((ulong)(*(long *)(param_1 + 8) - *(long *)param_1) >> 2); lVar1 = lVar1 + 1) { local_38 = logf(*(float *)(*(long *)param_1 + lVar1 * 4)); local_3c = (int4)lVar1; local_34 = *(int4 *)(*(long *)param_1 + lVar1 * 4); /* try { // try from 00105137 to 00105141 has its CatchHandler @ 0010517c */ std::vector<llama_token_data,std::allocator<llama_token_data>>::emplace_back<llama_token_data> ((vector<llama_token_data,std::allocator<llama_token_data>> *)(this + 0x38), (llama_token_data *)&local_3c); } *(long *)this = *(long *)(this + 0x38); *(long *)(this + 8) = (*(long *)(this + 0x40) - *(long *)(this + 0x38)) / 0xc; *(int8 *)(this + 0x10) = 0xffffffffffffffff; this[0x18] = (sampler_tester)0x0; return; }
60,825
trnman_get_min_safe_trid
eloqsql/storage/maria/trnman.c
TrID trnman_get_min_safe_trid() { TrID trid; mysql_mutex_lock(&LOCK_trn_list); trid= MY_MIN(active_list_min.next->min_read_from, global_trid_generator); mysql_mutex_unlock(&LOCK_trn_list); return trid; }
O3
c
trnman_get_min_safe_trid: pushq %rbp movq %rsp, %rbp pushq %r14 pushq %rbx cmpq $0x0, 0x3b6016(%rip) # 0x3fd560 jne 0x47594 leaq 0x3b5fcd(%rip), %rdi # 0x3fd520 callq 0x29220 movq 0x3b5c81(%rip), %rax # 0x3fd1e0 movq 0x80(%rax), %r14 movq 0x3b5ee3(%rip), %rbx # 0x3fd450 movq 0x3b5fec(%rip), %rdi # 0x3fd560 testq %rdi, %rdi jne 0x4759b cmpq %rbx, %r14 cmovbq %r14, %rbx leaq 0x3b5f99(%rip), %rdi # 0x3fd520 callq 0x291e0 movq %rbx, %rax popq %rbx popq %r14 popq %rbp retq callq 0x2a5b4 jmp 0x47558 leaq 0x33ea6e(%rip), %rax # 0x386010 movq (%rax), %rax callq *0x160(%rax) jmp 0x47579
trnman_get_min_safe_trid: push rbp mov rbp, rsp push r14 push rbx cmp cs:qword_3FD560, 0 jnz short loc_47594 lea rdi, LOCK_trn_list call _pthread_mutex_lock loc_47558: mov rax, cs:qword_3FD1E0 mov r14, [rax+80h] mov rbx, cs:global_trid_generator mov rdi, cs:qword_3FD560 test rdi, rdi jnz short loc_4759B loc_47579: cmp r14, rbx cmovb rbx, r14 lea rdi, LOCK_trn_list call _pthread_mutex_unlock mov rax, rbx pop rbx pop r14 pop rbp retn loc_47594: call trnman_get_min_safe_trid_cold_1 jmp short loc_47558 loc_4759B: lea rax, PSI_server mov rax, [rax] call qword ptr [rax+160h] jmp short loc_47579
unsigned long long trnman_get_min_safe_trid() { unsigned long long v0; // r14 unsigned long long v1; // rbx if ( qword_3FD560 ) trnman_get_min_safe_trid_cold_1(); else pthread_mutex_lock(&LOCK_trn_list); v0 = *(_QWORD *)(qword_3FD1E0 + 128); v1 = global_trid_generator; if ( qword_3FD560 ) PSI_server[44](); if ( v0 < v1 ) v1 = v0; pthread_mutex_unlock(&LOCK_trn_list); return v1; }
trnman_get_min_safe_trid: PUSH RBP MOV RBP,RSP PUSH R14 PUSH RBX CMP qword ptr [0x004fd560],0x0 JNZ 0x00147594 LEA RDI,[0x4fd520] CALL 0x00129220 LAB_00147558: MOV RAX,qword ptr [0x004fd1e0] MOV R14,qword ptr [RAX + 0x80] MOV RBX,qword ptr [0x004fd450] MOV RDI,qword ptr [0x004fd560] TEST RDI,RDI JNZ 0x0014759b LAB_00147579: CMP R14,RBX CMOVC RBX,R14 LEA RDI,[0x4fd520] CALL 0x001291e0 MOV RAX,RBX POP RBX POP R14 POP RBP RET LAB_00147594: CALL 0x0012a5b4 JMP 0x00147558 LAB_0014759b: LEA RAX,[0x486010] MOV RAX,qword ptr [RAX] CALL qword ptr [RAX + 0x160] JMP 0x00147579
ulong trnman_get_min_safe_trid(void) { ulong uVar1; ulong uVar2; if (LOCK_trn_list._64_8_ == 0) { pthread_mutex_lock((pthread_mutex_t *)LOCK_trn_list); } else { trnman_get_min_safe_trid_cold_1(); } uVar2 = global_trid_generator; uVar1 = *(ulong *)(active_list_min._104_8_ + 0x80); if (LOCK_trn_list._64_8_ != 0) { (**(code **)(PSI_server + 0x160))(); } if (uVar1 < uVar2) { uVar2 = uVar1; } pthread_mutex_unlock((pthread_mutex_t *)LOCK_trn_list); return uVar2; }
60,826
stbi__jpeg_get_bits(stbi__jpeg*, int)
7CodeWizard[P]stablediffusion/thirdparty/stb_image.h
stbi_inline static int stbi__jpeg_get_bits(stbi__jpeg *j, int n) { unsigned int k; if (j->code_bits < n) stbi__grow_buffer_unsafe(j); if (j->code_bits < n) return 0; // ran out of bits from stream, return 0s intead of continuing k = stbi_lrot(j->code_buffer, n); j->code_buffer = k & ~stbi__bmask[n]; k &= stbi__bmask[n]; j->code_bits -= n; return k; }
O0
c
stbi__jpeg_get_bits(stbi__jpeg*, int): subq $0x18, %rsp movq %rdi, 0x8(%rsp) movl %esi, 0x4(%rsp) movq 0x8(%rsp), %rax movl 0x4824(%rax), %eax cmpl 0x4(%rsp), %eax jge 0x2ac98 movq 0x8(%rsp), %rdi callq 0x29e80 movq 0x8(%rsp), %rax movl 0x4824(%rax), %eax cmpl 0x4(%rsp), %eax jge 0x2acb6 movl $0x0, 0x14(%rsp) jmp 0x2ad39 movq 0x8(%rsp), %rax movl 0x4820(%rax), %eax movl 0x4(%rsp), %ecx shll %cl, %eax movq 0x8(%rsp), %rcx movl 0x4820(%rcx), %edx xorl %ecx, %ecx subl 0x4(%rsp), %ecx andl $0x1f, %ecx shrl %cl, %edx movl %edx, %ecx orl %ecx, %eax movl %eax, (%rsp) movl (%rsp), %ecx movslq 0x4(%rsp), %rdx leaq 0x1525ed(%rip), %rax # 0x17d2e0 movl (%rax,%rdx,4), %eax xorl $-0x1, %eax andl %eax, %ecx movq 0x8(%rsp), %rax movl %ecx, 0x4820(%rax) movslq 0x4(%rsp), %rcx leaq 0x1525ce(%rip), %rax # 0x17d2e0 movl (%rax,%rcx,4), %eax andl (%rsp), %eax movl %eax, (%rsp) movl 0x4(%rsp), %edx movq 0x8(%rsp), %rax movl 0x4824(%rax), %ecx subl %edx, %ecx movl %ecx, 0x4824(%rax) movl (%rsp), %eax movl %eax, 0x14(%rsp) movl 0x14(%rsp), %eax addq $0x18, %rsp retq nopw %cs:(%rax,%rax)
_ZL19stbi__jpeg_get_bitsP10stbi__jpegi: sub rsp, 18h mov [rsp+18h+var_10], rdi mov [rsp+18h+var_14], esi mov rax, [rsp+18h+var_10] mov eax, [rax+4824h] cmp eax, [rsp+18h+var_14] jge short loc_2AC98 mov rdi, [rsp+18h+var_10] call _ZL24stbi__grow_buffer_unsafeP10stbi__jpeg; stbi__grow_buffer_unsafe(stbi__jpeg *) loc_2AC98: mov rax, [rsp+18h+var_10] mov eax, [rax+4824h] cmp eax, [rsp+18h+var_14] jge short loc_2ACB6 mov [rsp+18h+var_4], 0 jmp loc_2AD39 loc_2ACB6: mov rax, [rsp+18h+var_10] mov eax, [rax+4820h] mov ecx, [rsp+18h+var_14] shl eax, cl mov rcx, [rsp+18h+var_10] mov edx, [rcx+4820h] xor ecx, ecx sub ecx, [rsp+18h+var_14] and ecx, 1Fh shr edx, cl mov ecx, edx or eax, ecx mov [rsp+18h+var_18], eax mov ecx, [rsp+18h+var_18] movsxd rdx, [rsp+18h+var_14] lea rax, _ZL11stbi__bmask; stbi__bmask mov eax, [rax+rdx*4] xor eax, 0FFFFFFFFh and ecx, eax mov rax, [rsp+18h+var_10] mov [rax+4820h], ecx movsxd rcx, [rsp+18h+var_14] lea rax, _ZL11stbi__bmask; stbi__bmask mov eax, [rax+rcx*4] and eax, [rsp+18h+var_18] mov [rsp+18h+var_18], eax mov edx, [rsp+18h+var_14] mov rax, [rsp+18h+var_10] mov ecx, [rax+4824h] sub ecx, edx mov [rax+4824h], ecx mov eax, [rsp+18h+var_18] mov [rsp+18h+var_4], eax loc_2AD39: mov eax, [rsp+18h+var_4] add rsp, 18h retn
long long stbi__jpeg_get_bits(long long a1, int a2) { int v3; // [rsp+0h] [rbp-18h] unsigned int v4; // [rsp+0h] [rbp-18h] if ( *(_DWORD *)(a1 + 18468) < a2 ) stbi__grow_buffer_unsafe(a1); if ( *(_DWORD *)(a1 + 18468) >= a2 ) { v3 = (*(_DWORD *)(a1 + 18464) >> (-(char)a2 & 0x1F)) | (*(_DWORD *)(a1 + 18464) << a2); *(_DWORD *)(a1 + 18464) = ~stbi__bmask[a2] & v3; v4 = v3 & stbi__bmask[a2]; *(_DWORD *)(a1 + 18468) -= a2; return v4; } else { return 0; } }
stbi__jpeg_get_bits: SUB RSP,0x18 MOV qword ptr [RSP + 0x8],RDI MOV dword ptr [RSP + 0x4],ESI MOV RAX,qword ptr [RSP + 0x8] MOV EAX,dword ptr [RAX + 0x4824] CMP EAX,dword ptr [RSP + 0x4] JGE 0x0012ac98 MOV RDI,qword ptr [RSP + 0x8] CALL 0x00129e80 LAB_0012ac98: MOV RAX,qword ptr [RSP + 0x8] MOV EAX,dword ptr [RAX + 0x4824] CMP EAX,dword ptr [RSP + 0x4] JGE 0x0012acb6 MOV dword ptr [RSP + 0x14],0x0 JMP 0x0012ad39 LAB_0012acb6: MOV RAX,qword ptr [RSP + 0x8] MOV EAX,dword ptr [RAX + 0x4820] MOV ECX,dword ptr [RSP + 0x4] SHL EAX,CL MOV RCX,qword ptr [RSP + 0x8] MOV EDX,dword ptr [RCX + 0x4820] XOR ECX,ECX SUB ECX,dword ptr [RSP + 0x4] AND ECX,0x1f SHR EDX,CL MOV ECX,EDX OR EAX,ECX MOV dword ptr [RSP],EAX MOV ECX,dword ptr [RSP] MOVSXD RDX,dword ptr [RSP + 0x4] LEA RAX,[0x27d2e0] MOV EAX,dword ptr [RAX + RDX*0x4] XOR EAX,0xffffffff AND ECX,EAX MOV RAX,qword ptr [RSP + 0x8] MOV dword ptr [RAX + 0x4820],ECX MOVSXD RCX,dword ptr [RSP + 0x4] LEA RAX,[0x27d2e0] MOV EAX,dword ptr [RAX + RCX*0x4] AND EAX,dword ptr [RSP] MOV dword ptr [RSP],EAX MOV EDX,dword ptr [RSP + 0x4] MOV RAX,qword ptr [RSP + 0x8] MOV ECX,dword ptr [RAX + 0x4824] SUB ECX,EDX MOV dword ptr [RAX + 0x4824],ECX MOV EAX,dword ptr [RSP] MOV dword ptr [RSP + 0x14],EAX LAB_0012ad39: MOV EAX,dword ptr [RSP + 0x14] ADD RSP,0x18 RET
/* stbi__jpeg_get_bits(stbi__jpeg*, int) */ uint stbi__jpeg_get_bits(stbi__jpeg *param_1,int param_2) { uint local_4; if (*(int *)(param_1 + 0x4824) < param_2) { stbi__grow_buffer_unsafe(param_1); } if (*(int *)(param_1 + 0x4824) < param_2) { local_4 = 0; } else { local_4 = *(int *)(param_1 + 0x4820) << ((byte)param_2 & 0x1f) | *(uint *)(param_1 + 0x4820) >> (-(byte)param_2 & 0x1f); *(uint *)(param_1 + 0x4820) = local_4 & (*(uint *)(stbi__bmask + (long)param_2 * 4) ^ 0xffffffff); local_4 = *(uint *)(stbi__bmask + (long)param_2 * 4) & local_4; *(int *)(param_1 + 0x4824) = *(int *)(param_1 + 0x4824) - param_2; } return local_4; }
60,827
hi0bits
eloqsql/strings/dtoa.c
static int hi0bits(register ULong x) { register int k= 0; if (!(x & 0xffff0000)) { k= 16; x<<= 16; } if (!(x & 0xff000000)) { k+= 8; x<<= 8; } if (!(x & 0xf0000000)) { k+= 4; x<<= 4; } if (!(x & 0xc0000000)) { k+= 2; x<<= 2; } if (!(x & 0x80000000)) { k++; if (!(x & 0x40000000)) return 32; } return k; }
O3
c
hi0bits: pushq %rbp movq %rsp, %rbp movl %edi, %eax shll $0x10, %eax xorl %ecx, %ecx cmpl $0x10000, %edi # imm = 0x10000 setb %cl cmovael %edi, %eax shll $0x4, %ecx movl %eax, %edx shll $0x8, %edx cmpl $0x1000000, %eax # imm = 0x1000000 cmovael %eax, %edx leal 0x8(%rcx), %eax cmovael %ecx, %eax movl %edx, %ecx shll $0x4, %ecx cmpl $0x10000000, %edx # imm = 0x10000000 cmovael %edx, %ecx leal 0x4(%rax), %edx cmovael %eax, %edx leal (,%rcx,4), %esi movl $0x40000000, %eax # imm = 0x40000000 cmpl %eax, %ecx cmovael %ecx, %esi leal 0x2(%rdx), %ecx cmovael %edx, %ecx leal 0x1(%rcx), %edx cmpl %eax, %esi movl $0x20, %eax cmovael %edx, %eax testl %esi, %esi cmovsl %ecx, %eax popq %rbp retq
hi0bits: push rbp mov rbp, rsp mov eax, edi shl eax, 10h xor ecx, ecx cmp edi, 10000h setb cl cmovnb eax, edi shl ecx, 4 mov edx, eax shl edx, 8 cmp eax, 1000000h cmovnb edx, eax lea eax, [rcx+8] cmovnb eax, ecx mov ecx, edx shl ecx, 4 cmp edx, 10000000h cmovnb ecx, edx lea edx, [rax+4] cmovnb edx, eax lea esi, ds:0[rcx*4] mov eax, 40000000h cmp ecx, eax cmovnb esi, ecx lea ecx, [rdx+2] cmovnb ecx, edx lea edx, [rcx+1] cmp esi, eax mov eax, 20h ; ' ' cmovnb eax, edx test esi, esi cmovs eax, ecx pop rbp retn
long long hi0bits(unsigned int a1) { unsigned int v1; // eax unsigned int v2; // edx bool v3; // cf int v4; // eax unsigned int v5; // ecx bool v6; // cf int v7; // edx int v8; // esi bool v9; // cf unsigned int v10; // ecx long long result; // rax v1 = a1 << 16; if ( a1 >= 0x10000 ) v1 = a1; v2 = v1 << 8; v3 = v1 < 0x1000000; if ( v1 >= 0x1000000 ) v2 = v1; v4 = 16 * (a1 < 0x10000) + 8; if ( !v3 ) v4 = 16 * (a1 < 0x10000); v5 = 16 * v2; v6 = v2 < 0x10000000; if ( v2 >= 0x10000000 ) v5 = v2; v7 = v4 + 4; if ( !v6 ) v7 = v4; v8 = 4 * v5; v9 = v5 < 0x40000000; if ( v5 >= 0x40000000 ) v8 = v5; v10 = v7 + 2; if ( !v9 ) v10 = v7; result = 32LL; if ( (unsigned int)v8 >= 0x40000000 ) result = v10 + 1; if ( v8 < 0 ) return v10; return result; }
hi0bits: PUSH RBP MOV RBP,RSP MOV EAX,EDI SHL EAX,0x10 XOR ECX,ECX CMP EDI,0x10000 SETC CL CMOVNC EAX,EDI SHL ECX,0x4 MOV EDX,EAX SHL EDX,0x8 CMP EAX,0x1000000 CMOVNC EDX,EAX LEA EAX,[RCX + 0x8] CMOVNC EAX,ECX MOV ECX,EDX SHL ECX,0x4 CMP EDX,0x10000000 CMOVNC ECX,EDX LEA EDX,[RAX + 0x4] CMOVNC EDX,EAX LEA ESI,[RCX*0x4] MOV EAX,0x40000000 CMP ECX,EAX CMOVNC ESI,ECX LEA ECX,[RDX + 0x2] CMOVNC ECX,EDX LEA EDX,[RCX + 0x1] CMP ESI,EAX MOV EAX,0x20 CMOVNC EAX,EDX TEST ESI,ESI CMOVS EAX,ECX POP RBP RET
int hi0bits(uint param_1) { uint uVar1; uint uVar2; int iVar3; int iVar4; uVar2 = param_1 << 0x10; if (param_1 >= 0x10000) { uVar2 = param_1; } iVar4 = (uint)(param_1 < 0x10000) * 0x10; uVar1 = uVar2 << 8; if (0xffffff < uVar2) { uVar1 = uVar2; } iVar3 = iVar4 + 8; if (0xffffff < uVar2) { iVar3 = iVar4; } uVar2 = uVar1 << 4; if (0xfffffff < uVar1) { uVar2 = uVar1; } iVar4 = iVar3 + 4; if (0xfffffff < uVar1) { iVar4 = iVar3; } uVar1 = uVar2 * 4; if (0x3fffffff < uVar2) { uVar1 = uVar2; } iVar3 = iVar4 + 2; if (0x3fffffff < uVar2) { iVar3 = iVar4; } iVar4 = 0x20; if (0x3fffffff < uVar1) { iVar4 = iVar3 + 1; } if ((int)uVar1 < 0) { iVar4 = iVar3; } return iVar4; }
60,828
minja::ArgumentsValue::expectArgs(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, std::pair<unsigned long, unsigned long> const&, std::pair<unsigned long, unsigned long> const&)
monkey531[P]llama/common/minja.hpp
void expectArgs(const std::string & method_name, const std::pair<size_t, size_t> & pos_count, const std::pair<size_t, size_t> & kw_count) { if (args.size() < pos_count.first || args.size() > pos_count.second || kwargs.size() < kw_count.first || kwargs.size() > kw_count.second) { std::ostringstream out; out << method_name << " must have between " << pos_count.first << " and " << pos_count.second << " positional arguments and between " << kw_count.first << " and " << kw_count.second << " keyword arguments"; throw std::runtime_error(out.str()); } }
O2
cpp
minja::ArgumentsValue::expectArgs(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, std::pair<unsigned long, unsigned long> const&, std::pair<unsigned long, unsigned long> const&): pushq %rbp pushq %r15 pushq %r14 pushq %r12 pushq %rbx subq $0x1a0, %rsp # imm = 0x1A0 movq %rcx, %rbx movq %rdx, %r14 movq 0x8(%rdi), %rax subq (%rdi), %rax movq %rsi, %r15 pushq $0x50 popq %rcx cqto idivq %rcx cmpq (%r14), %rax jb 0x6d58b cmpq 0x8(%r14), %rax ja 0x6d58b movq 0x20(%rdi), %rax subq 0x18(%rdi), %rax pushq $0x70 popq %rcx cqto idivq %rcx cmpq (%rbx), %rax jb 0x6d58b cmpq 0x8(%rbx), %rax ja 0x6d58b addq $0x1a0, %rsp # imm = 0x1A0 popq %rbx popq %r12 popq %r14 popq %r15 popq %rbp retq leaq 0x28(%rsp), %r12 movq %r12, %rdi callq 0x23bb0 movq %r12, %rdi movq %r15, %rsi callq 0x237e0 leaq 0x46fb8(%rip), %rsi # 0xb4562 movq %rax, %rdi callq 0x238b0 movq (%r14), %rsi movq %rax, %rdi callq 0x23620 leaq 0x46fb2(%rip), %rsi # 0xb4576 movq %rax, %rdi callq 0x238b0 movq 0x8(%r14), %rsi movq %rax, %rdi callq 0x23620 leaq 0x46f9d(%rip), %rsi # 0xb457c movq %rax, %rdi callq 0x238b0 movq (%rbx), %rsi movq %rax, %rdi callq 0x23620 leaq 0x46f7d(%rip), %rsi # 0xb4576 movq %rax, %rdi callq 0x238b0 movq 0x8(%rbx), %rsi movq %rax, %rdi callq 0x23620 leaq 0x46f8b(%rip), %rsi # 0xb459f movq %rax, %rdi callq 0x238b0 pushq $0x10 popq %rdi callq 0x23450 movq %rax, %rbx leaq 0x30(%rsp), %rsi leaq 0x8(%rsp), %rdi callq 0x23dd0 movb $0x1, %bpl leaq 0x8(%rsp), %rsi movq %rbx, %rdi callq 0x23e50 xorl %ebp, %ebp movq 0x909a1(%rip), %rsi # 0xfdff0 movq 0x90902(%rip), %rdx # 0xfdf58 movq %rbx, %rdi callq 0x23f20 movq %rax, %r14 leaq 0x8(%rsp), %rdi callq 0x241f8 testb %bpl, %bpl jne 0x6d675 jmp 0x6d682 movq %rax, %r14 movq %rbx, %rdi callq 0x23690 jmp 0x6d682 movq %rax, %r14 leaq 0x28(%rsp), %rdi callq 0x231e0 movq %r14, %rdi callq 0x23fb0
_ZN5minja14ArgumentsValue10expectArgsERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKSt4pairImmESC_: push rbp push r15 push r14 push r12 push rbx sub rsp, 1A0h mov rbx, rcx mov r14, rdx mov rax, [rdi+8] sub rax, [rdi] mov r15, rsi push 50h ; 'P' pop rcx cqo idiv rcx cmp rax, [r14] jb short loc_6D58B cmp rax, [r14+8] ja short loc_6D58B mov rax, [rdi+20h] sub rax, [rdi+18h] push 70h ; 'p' pop rcx cqo idiv rcx cmp rax, [rbx] jb short loc_6D58B cmp rax, [rbx+8] ja short loc_6D58B add rsp, 1A0h pop rbx pop r12 pop r14 pop r15 pop rbp retn loc_6D58B: lea r12, [rsp+1C8h+var_1A0] mov rdi, r12 call __ZNSt7__cxx1119basic_ostringstreamIcSt11char_traitsIcESaIcEEC1Ev; std::ostringstream::basic_ostringstream(void) mov rdi, r12 mov rsi, r15 call __ZStlsIcSt11char_traitsIcESaIcEERSt13basic_ostreamIT_T0_ES7_RKNSt7__cxx1112basic_stringIS4_S5_T1_EE; std::operator<<<char>(std::ostream &,std::string const&) lea rsi, aMustHaveBetwee; " must have between " mov rdi, rax call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*) mov rsi, [r14] mov rdi, rax call __ZNSo9_M_insertImEERSoT_; std::ostream::_M_insert<ulong>(ulong) lea rsi, aAnd; " and " mov rdi, rax call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*) mov rsi, [r14+8] mov rdi, rax call __ZNSo9_M_insertImEERSoT_; std::ostream::_M_insert<ulong>(ulong) lea rsi, aPositionalArgu; " positional arguments and between " mov rdi, rax call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*) mov rsi, [rbx] mov rdi, rax call __ZNSo9_M_insertImEERSoT_; std::ostream::_M_insert<ulong>(ulong) lea rsi, aAnd; " and " mov rdi, rax call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*) mov rsi, [rbx+8] mov rdi, rax call __ZNSo9_M_insertImEERSoT_; std::ostream::_M_insert<ulong>(ulong) lea rsi, aKeywordArgumen; " keyword arguments" mov rdi, rax call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*) push 10h pop rdi; thrown_size call ___cxa_allocate_exception mov rbx, rax lea rsi, [rsp+1C8h+var_198] lea rdi, [rsp+1C8h+var_1C0] call __ZNKSt7__cxx1115basic_stringbufIcSt11char_traitsIcESaIcEE3strEv; std::stringbuf::str(void) mov bpl, 1 lea rsi, [rsp+1C8h+var_1C0] mov rdi, rbx call __ZNSt13runtime_errorC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; std::runtime_error::runtime_error(std::string const&) xor ebp, ebp mov rsi, cs:_ZTISt13runtime_error_ptr; lptinfo mov rdx, cs:_ZNSt13runtime_errorD1Ev_ptr; void (*)(void *) mov rdi, rbx; void * call ___cxa_throw mov r14, rax lea rdi, [rsp+1C8h+var_1C0]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() test bpl, bpl jnz short loc_6D675 jmp short loc_6D682 mov r14, rax loc_6D675: mov rdi, rbx; void * call ___cxa_free_exception jmp short loc_6D682 mov r14, rax loc_6D682: lea rdi, [rsp+1C8h+var_1A0] call __ZNSt7__cxx1119basic_ostringstreamIcSt11char_traitsIcESaIcEED1Ev; std::ostringstream::~ostringstream() mov rdi, r14 call __Unwind_Resume
unsigned long long minja::ArgumentsValue::expectArgs( _QWORD *a1, long long a2, unsigned long long *a3, unsigned long long *a4) { unsigned long long v6; // rax unsigned long long result; // rax long long v8; // rax long long v9; // rax long long v10; // rax long long v11; // rax long long v12; // rax long long v13; // rax long long v14; // rax long long v15; // rax long long v16; // rax void *exception; // rbx _BYTE v18[32]; // [rsp+8h] [rbp-1C0h] BYREF _BYTE v19[8]; // [rsp+28h] [rbp-1A0h] BYREF _BYTE v20[408]; // [rsp+30h] [rbp-198h] BYREF v6 = (a1[1] - *a1) / 80LL; if ( v6 < *a3 || v6 > a3[1] || (result = (a1[4] - a1[3]) / 112LL, result < *a4) || result > a4[1] ) { std::ostringstream::basic_ostringstream(v19); v8 = std::operator<<<char>(v19, a2); v9 = std::operator<<<std::char_traits<char>>(v8, " must have between "); v10 = std::ostream::_M_insert<unsigned long>(v9, *a3); v11 = std::operator<<<std::char_traits<char>>(v10, " and "); v12 = std::ostream::_M_insert<unsigned long>(v11, a3[1]); v13 = std::operator<<<std::char_traits<char>>(v12, " positional arguments and between "); v14 = std::ostream::_M_insert<unsigned long>(v13, *a4); v15 = std::operator<<<std::char_traits<char>>(v14, " and "); v16 = std::ostream::_M_insert<unsigned long>(v15, a4[1]); std::operator<<<std::char_traits<char>>(v16, " keyword arguments"); exception = __cxa_allocate_exception(0x10uLL); std::stringbuf::str(v18, v20); std::runtime_error::runtime_error(exception, v18); __cxa_throw( exception, (struct type_info *)&`typeinfo for'std::runtime_error, (void (*)(void *))&std::runtime_error::~runtime_error); } return result; }
expectArgs: PUSH RBP PUSH R15 PUSH R14 PUSH R12 PUSH RBX SUB RSP,0x1a0 MOV RBX,RCX MOV R14,RDX MOV RAX,qword ptr [RDI + 0x8] SUB RAX,qword ptr [RDI] MOV R15,RSI PUSH 0x50 POP RCX CQO IDIV RCX CMP RAX,qword ptr [R14] JC 0x0016d58b CMP RAX,qword ptr [R14 + 0x8] JA 0x0016d58b MOV RAX,qword ptr [RDI + 0x20] SUB RAX,qword ptr [RDI + 0x18] PUSH 0x70 POP RCX CQO IDIV RCX CMP RAX,qword ptr [RBX] JC 0x0016d58b CMP RAX,qword ptr [RBX + 0x8] JA 0x0016d58b ADD RSP,0x1a0 POP RBX POP R12 POP R14 POP R15 POP RBP RET LAB_0016d58b: LEA R12,[RSP + 0x28] MOV RDI,R12 CALL 0x00123bb0 LAB_0016d598: MOV RDI,R12 MOV RSI,R15 CALL 0x001237e0 LEA RSI,[0x1b4562] MOV RDI,RAX CALL 0x001238b0 MOV RSI,qword ptr [R14] MOV RDI,RAX CALL 0x00123620 LEA RSI,[0x1b4576] MOV RDI,RAX CALL 0x001238b0 MOV RSI,qword ptr [R14 + 0x8] MOV RDI,RAX CALL 0x00123620 LEA RSI,[0x1b457c] MOV RDI,RAX CALL 0x001238b0 MOV RSI,qword ptr [RBX] MOV RDI,RAX CALL 0x00123620 LEA RSI,[0x1b4576] MOV RDI,RAX CALL 0x001238b0 MOV RSI,qword ptr [RBX + 0x8] MOV RDI,RAX CALL 0x00123620 LEA RSI,[0x1b459f] MOV RDI,RAX CALL 0x001238b0 LAB_0016d61c: PUSH 0x10 POP RDI CALL 0x00123450 MOV RBX,RAX LEA RSI,[RSP + 0x30] LAB_0016d62c: LEA RDI,[RSP + 0x8] CALL 0x00123dd0 MOV BPL,0x1 LAB_0016d639: LEA RSI,[RSP + 0x8] MOV RDI,RBX CALL 0x00123e50 XOR EBP,EBP MOV RSI,qword ptr [0x001fdff0] MOV RDX,qword ptr [0x001fdf58] MOV RDI,RBX CALL 0x00123f20
/* minja::ArgumentsValue::expectArgs(std::__cxx11::string const&, std::pair<unsigned long, unsigned long> const&, std::pair<unsigned long, unsigned long> const&) */ void __thiscall minja::ArgumentsValue::expectArgs(ArgumentsValue *this,string *param_1,pair *param_2,pair *param_3) { ulong uVar1; ostream *poVar2; runtime_error *this_00; string local_1c0 [32]; ostringstream local_1a0 [376]; uVar1 = (*(long *)(this + 8) - *(long *)this) / 0x50; if ((*(ulong *)param_2 <= uVar1) && (uVar1 <= *(ulong *)(param_2 + 8))) { uVar1 = (*(long *)(this + 0x20) - *(long *)(this + 0x18)) / 0x70; if ((*(ulong *)param_3 <= uVar1) && (uVar1 <= *(ulong *)(param_3 + 8))) { return; } } std::__cxx11::ostringstream::ostringstream(local_1a0); /* try { // try from 0016d598 to 0016d61b has its CatchHandler @ 0016d67f */ poVar2 = std::operator<<((ostream *)local_1a0,param_1); poVar2 = std::operator<<(poVar2," must have between "); poVar2 = std::ostream::_M_insert<unsigned_long>((ulong)poVar2); poVar2 = std::operator<<(poVar2," and "); poVar2 = std::ostream::_M_insert<unsigned_long>((ulong)poVar2); poVar2 = std::operator<<(poVar2," positional arguments and between "); poVar2 = std::ostream::_M_insert<unsigned_long>((ulong)poVar2); poVar2 = std::operator<<(poVar2," and "); poVar2 = std::ostream::_M_insert<unsigned_long>((ulong)poVar2); std::operator<<(poVar2," keyword arguments"); this_00 = (runtime_error *)__cxa_allocate_exception(0x10); /* try { // try from 0016d62c to 0016d635 has its CatchHandler @ 0016d672 */ std::__cxx11::stringbuf::str(); /* try { // try from 0016d639 to 0016d65d has its CatchHandler @ 0016d65e */ std::runtime_error::runtime_error(this_00,local_1c0); /* WARNING: Subroutine does not return */ __cxa_throw(this_00,PTR_typeinfo_001fdff0,PTR__runtime_error_001fdf58); }
60,829
ma_alloc_dynamic
eloqsql/libmariadb/libmariadb/ma_array.c
unsigned char *ma_alloc_dynamic(DYNAMIC_ARRAY *array) { if (array->elements == array->max_element) { char *new_ptr; if (!(new_ptr=(char*) realloc(array->buffer,(array->max_element+ array->alloc_increment)* array->size_of_element))) return 0; array->buffer=new_ptr; array->max_element+=array->alloc_increment; } return (unsigned char *)array->buffer+(array->elements++ * array->size_of_element); }
O0
c
ma_alloc_dynamic: pushq %rbp movq %rsp, %rbp subq $0x20, %rsp movq %rdi, -0x10(%rbp) movq -0x10(%rbp), %rax movl 0x8(%rax), %eax movq -0x10(%rbp), %rcx cmpl 0xc(%rcx), %eax jne 0x43832 movq -0x10(%rbp), %rax movq (%rax), %rdi movq -0x10(%rbp), %rax movl 0xc(%rax), %eax movq -0x10(%rbp), %rcx addl 0x10(%rcx), %eax movq -0x10(%rbp), %rcx imull 0x14(%rcx), %eax movl %eax, %eax movl %eax, %esi callq 0x13700 movq %rax, -0x18(%rbp) cmpq $0x0, %rax jne 0x43816 movq $0x0, -0x8(%rbp) jmp 0x43859 movq -0x18(%rbp), %rcx movq -0x10(%rbp), %rax movq %rcx, (%rax) movq -0x10(%rbp), %rax movl 0x10(%rax), %ecx movq -0x10(%rbp), %rax addl 0xc(%rax), %ecx movl %ecx, 0xc(%rax) movq -0x10(%rbp), %rax movq (%rax), %rax movq -0x10(%rbp), %rdx movl 0x8(%rdx), %ecx movl %ecx, %esi addl $0x1, %esi movl %esi, 0x8(%rdx) movq -0x10(%rbp), %rdx imull 0x14(%rdx), %ecx movl %ecx, %ecx addq %rcx, %rax movq %rax, -0x8(%rbp) movq -0x8(%rbp), %rax addq $0x20, %rsp popq %rbp retq nopw %cs:(%rax,%rax)
ma_alloc_dynamic: push rbp mov rbp, rsp sub rsp, 20h mov [rbp+var_10], rdi mov rax, [rbp+var_10] mov eax, [rax+8] mov rcx, [rbp+var_10] cmp eax, [rcx+0Ch] jnz short loc_43832 mov rax, [rbp+var_10] mov rdi, [rax] mov rax, [rbp+var_10] mov eax, [rax+0Ch] mov rcx, [rbp+var_10] add eax, [rcx+10h] mov rcx, [rbp+var_10] imul eax, [rcx+14h] mov eax, eax mov esi, eax call _realloc mov [rbp+var_18], rax cmp rax, 0 jnz short loc_43816 mov [rbp+var_8], 0 jmp short loc_43859 loc_43816: mov rcx, [rbp+var_18] mov rax, [rbp+var_10] mov [rax], rcx mov rax, [rbp+var_10] mov ecx, [rax+10h] mov rax, [rbp+var_10] add ecx, [rax+0Ch] mov [rax+0Ch], ecx loc_43832: mov rax, [rbp+var_10] mov rax, [rax] mov rdx, [rbp+var_10] mov ecx, [rdx+8] mov esi, ecx add esi, 1 mov [rdx+8], esi mov rdx, [rbp+var_10] imul ecx, [rdx+14h] mov ecx, ecx add rax, rcx mov [rbp+var_8], rax loc_43859: mov rax, [rbp+var_8] add rsp, 20h pop rbp retn
long long ma_alloc_dynamic(long long *a1) { long long v1; // rax int v2; // ecx long long v4; // [rsp+8h] [rbp-18h] if ( *((_DWORD *)a1 + 2) != *((_DWORD *)a1 + 3) ) goto LABEL_5; v4 = realloc(*a1, (unsigned int)(*((_DWORD *)a1 + 5) * (*((_DWORD *)a1 + 4) + *((_DWORD *)a1 + 3)))); if ( v4 ) { *a1 = v4; *((_DWORD *)a1 + 3) += *((_DWORD *)a1 + 4); LABEL_5: v1 = *a1; v2 = *((_DWORD *)a1 + 2); *((_DWORD *)a1 + 2) = v2 + 1; return (unsigned int)(*((_DWORD *)a1 + 5) * v2) + v1; } return 0LL; }
ma_alloc_dynamic: PUSH RBP MOV RBP,RSP SUB RSP,0x20 MOV qword ptr [RBP + -0x10],RDI MOV RAX,qword ptr [RBP + -0x10] MOV EAX,dword ptr [RAX + 0x8] MOV RCX,qword ptr [RBP + -0x10] CMP EAX,dword ptr [RCX + 0xc] JNZ 0x00143832 MOV RAX,qword ptr [RBP + -0x10] MOV RDI,qword ptr [RAX] MOV RAX,qword ptr [RBP + -0x10] MOV EAX,dword ptr [RAX + 0xc] MOV RCX,qword ptr [RBP + -0x10] ADD EAX,dword ptr [RCX + 0x10] MOV RCX,qword ptr [RBP + -0x10] IMUL EAX,dword ptr [RCX + 0x14] MOV EAX,EAX MOV ESI,EAX CALL 0x00113700 MOV qword ptr [RBP + -0x18],RAX CMP RAX,0x0 JNZ 0x00143816 MOV qword ptr [RBP + -0x8],0x0 JMP 0x00143859 LAB_00143816: MOV RCX,qword ptr [RBP + -0x18] MOV RAX,qword ptr [RBP + -0x10] MOV qword ptr [RAX],RCX MOV RAX,qword ptr [RBP + -0x10] MOV ECX,dword ptr [RAX + 0x10] MOV RAX,qword ptr [RBP + -0x10] ADD ECX,dword ptr [RAX + 0xc] MOV dword ptr [RAX + 0xc],ECX LAB_00143832: MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX] MOV RDX,qword ptr [RBP + -0x10] MOV ECX,dword ptr [RDX + 0x8] MOV ESI,ECX ADD ESI,0x1 MOV dword ptr [RDX + 0x8],ESI MOV RDX,qword ptr [RBP + -0x10] IMUL ECX,dword ptr [RDX + 0x14] MOV ECX,ECX ADD RAX,RCX MOV qword ptr [RBP + -0x8],RAX LAB_00143859: MOV RAX,qword ptr [RBP + -0x8] ADD RSP,0x20 POP RBP RET
long ma_alloc_dynamic(long *param_1) { long lVar1; void *pvVar2; if ((int)param_1[1] == *(int *)((long)param_1 + 0xc)) { pvVar2 = realloc((void *)*param_1, (ulong)(uint)((*(int *)((long)param_1 + 0xc) + (int)param_1[2]) * *(int *)((long)param_1 + 0x14))); if (pvVar2 == (void *)0x0) { return 0; } *param_1 = (long)pvVar2; *(int *)((long)param_1 + 0xc) = (int)param_1[2] + *(int *)((long)param_1 + 0xc); } lVar1 = param_1[1]; *(int *)(param_1 + 1) = (int)lVar1 + 1; return *param_1 + (ulong)(uint)((int)lVar1 * *(int *)((long)param_1 + 0x14)); }
60,830
nlohmann::json_abi_v3_11_3::detail::dtoa_impl::get_cached_power_for_binary_exponent(int)
monkey531[P]llama/common/json.hpp
inline cached_power get_cached_power_for_binary_exponent(int e) { // Now // // alpha <= e_c + e + q <= gamma (1) // ==> f_c * 2^alpha <= c * 2^e * 2^q // // and since the c's are normalized, 2^(q-1) <= f_c, // // ==> 2^(q - 1 + alpha) <= c * 2^(e + q) // ==> 2^(alpha - e - 1) <= c // // If c were an exact power of ten, i.e. c = 10^k, one may determine k as // // k = ceil( log_10( 2^(alpha - e - 1) ) ) // = ceil( (alpha - e - 1) * log_10(2) ) // // From the paper: // "In theory the result of the procedure could be wrong since c is rounded, // and the computation itself is approximated [...]. In practice, however, // this simple function is sufficient." // // For IEEE double precision floating-point numbers converted into // normalized diyfp's w = f * 2^e, with q = 64, // // e >= -1022 (min IEEE exponent) // -52 (p - 1) // -52 (p - 1, possibly normalize denormal IEEE numbers) // -11 (normalize the diyfp) // = -1137 // // and // // e <= +1023 (max IEEE exponent) // -52 (p - 1) // -11 (normalize the diyfp) // = 960 // // This binary exponent range [-1137,960] results in a decimal exponent // range [-307,324]. One does not need to store a cached power for each // k in this range. For each such k it suffices to find a cached power // such that the exponent of the product lies in [alpha,gamma]. // This implies that the difference of the decimal exponents of adjacent // table entries must be less than or equal to // // floor( (gamma - alpha) * log_10(2) ) = 8. // // (A smaller distance gamma-alpha would require a larger table.) // NB: // Actually this function returns c, such that -60 <= e_c + e + 64 <= -34. constexpr int kCachedPowersMinDecExp = -300; constexpr int kCachedPowersDecStep = 8; static constexpr std::array<cached_power, 79> kCachedPowers = { { { 0xAB70FE17C79AC6CA, -1060, -300 }, { 0xFF77B1FCBEBCDC4F, -1034, -292 }, { 0xBE5691EF416BD60C, -1007, -284 }, { 0x8DD01FAD907FFC3C, -980, -276 }, { 0xD3515C2831559A83, -954, -268 }, { 0x9D71AC8FADA6C9B5, -927, -260 }, { 0xEA9C227723EE8BCB, -901, -252 }, { 0xAECC49914078536D, -874, -244 }, { 0x823C12795DB6CE57, -847, -236 }, { 0xC21094364DFB5637, -821, -228 }, { 0x9096EA6F3848984F, -794, -220 }, { 0xD77485CB25823AC7, -768, -212 }, { 0xA086CFCD97BF97F4, -741, -204 }, { 0xEF340A98172AACE5, -715, -196 }, { 0xB23867FB2A35B28E, -688, -188 }, { 0x84C8D4DFD2C63F3B, -661, -180 }, { 0xC5DD44271AD3CDBA, -635, -172 }, { 0x936B9FCEBB25C996, -608, -164 }, { 0xDBAC6C247D62A584, -582, -156 }, { 0xA3AB66580D5FDAF6, -555, -148 }, { 0xF3E2F893DEC3F126, -529, -140 }, { 0xB5B5ADA8AAFF80B8, -502, -132 }, { 0x87625F056C7C4A8B, -475, -124 }, { 0xC9BCFF6034C13053, -449, -116 }, { 0x964E858C91BA2655, -422, -108 }, { 0xDFF9772470297EBD, -396, -100 }, { 0xA6DFBD9FB8E5B88F, -369, -92 }, { 0xF8A95FCF88747D94, -343, -84 }, { 0xB94470938FA89BCF, -316, -76 }, { 0x8A08F0F8BF0F156B, -289, -68 }, { 0xCDB02555653131B6, -263, -60 }, { 0x993FE2C6D07B7FAC, -236, -52 }, { 0xE45C10C42A2B3B06, -210, -44 }, { 0xAA242499697392D3, -183, -36 }, { 0xFD87B5F28300CA0E, -157, -28 }, { 0xBCE5086492111AEB, -130, -20 }, { 0x8CBCCC096F5088CC, -103, -12 }, { 0xD1B71758E219652C, -77, -4 }, { 0x9C40000000000000, -50, 4 }, { 0xE8D4A51000000000, -24, 12 }, { 0xAD78EBC5AC620000, 3, 20 }, { 0x813F3978F8940984, 30, 28 }, { 0xC097CE7BC90715B3, 56, 36 }, { 0x8F7E32CE7BEA5C70, 83, 44 }, { 0xD5D238A4ABE98068, 109, 52 }, { 0x9F4F2726179A2245, 136, 60 }, { 0xED63A231D4C4FB27, 162, 68 }, { 0xB0DE65388CC8ADA8, 189, 76 }, { 0x83C7088E1AAB65DB, 216, 84 }, { 0xC45D1DF942711D9A, 242, 92 }, { 0x924D692CA61BE758, 269, 100 }, { 0xDA01EE641A708DEA, 295, 108 }, { 0xA26DA3999AEF774A, 322, 116 }, { 0xF209787BB47D6B85, 348, 124 }, { 0xB454E4A179DD1877, 375, 132 }, { 0x865B86925B9BC5C2, 402, 140 }, { 0xC83553C5C8965D3D, 428, 148 }, { 0x952AB45CFA97A0B3, 455, 156 }, { 0xDE469FBD99A05FE3, 481, 164 }, { 0xA59BC234DB398C25, 508, 172 }, { 0xF6C69A72A3989F5C, 534, 180 }, { 0xB7DCBF5354E9BECE, 561, 188 }, { 0x88FCF317F22241E2, 588, 196 }, { 0xCC20CE9BD35C78A5, 614, 204 }, { 0x98165AF37B2153DF, 641, 212 }, { 0xE2A0B5DC971F303A, 667, 220 }, { 0xA8D9D1535CE3B396, 694, 228 }, { 0xFB9B7CD9A4A7443C, 720, 236 }, { 0xBB764C4CA7A44410, 747, 244 }, { 0x8BAB8EEFB6409C1A, 774, 252 }, { 0xD01FEF10A657842C, 800, 260 }, { 0x9B10A4E5E9913129, 827, 268 }, { 0xE7109BFBA19C0C9D, 853, 276 }, { 0xAC2820D9623BF429, 880, 284 }, { 0x80444B5E7AA7CF85, 907, 292 }, { 0xBF21E44003ACDD2D, 933, 300 }, { 0x8E679C2F5E44FF8F, 960, 308 }, { 0xD433179D9C8CB841, 986, 316 }, { 0x9E19DB92B4E31BA9, 1013, 324 }, } }; // This computation gives exactly the same results for k as // k = ceil((kAlpha - e - 1) * 0.30102999566398114) // for |e| <= 1500, but doesn't require floating-point operations. // NB: log_10(2) ~= 78913 / 2^18 JSON_ASSERT(e >= -1500); JSON_ASSERT(e <= 1500); const int f = kAlpha - e - 1; const int k = (f * 78913) / (1 << 18) + static_cast<int>(f > 0); const int index = (-kCachedPowersMinDecExp + k + (kCachedPowersDecStep - 1)) / kCachedPowersDecStep; JSON_ASSERT(index >= 0); JSON_ASSERT(static_cast<std::size_t>(index) < kCachedPowers.size()); const cached_power cached = kCachedPowers[static_cast<std::size_t>(index)]; JSON_ASSERT(kAlpha <= cached.e + e + 64); JSON_ASSERT(kGamma >= cached.e + e + 64); return cached; }
O1
cpp
nlohmann::json_abi_v3_11_3::detail::dtoa_impl::get_cached_power_for_binary_exponent(int): pushq %rax cmpl $0xfffffa23, %edi # imm = 0xFFFFFA23 jle 0xb789f cmpl $0x5dd, %edi # imm = 0x5DD jge 0xb78be movl $0xffffffc3, %ecx # imm = 0xFFFFFFC3 subl %edi, %ecx imull $0x13441, %ecx, %eax # imm = 0x13441 leal 0x3ffff(%rax), %edx testl %eax, %eax cmovnsl %eax, %edx sarl $0x12, %edx xorl %eax, %eax testl %ecx, %ecx setg %al addl %edx, %eax cmpl $0xfffffec5, %eax # imm = 0xFFFFFEC5 jle 0xb78da leal 0x133(%rax), %ecx addl $0x13a, %eax # imm = 0x13A testl %ecx, %ecx cmovnsl %ecx, %eax sarl $0x3, %eax cmpl $0x4f, %eax jae 0xb78f6 movl %eax, %eax shlq $0x4, %rax leaq 0x3d138(%rip), %rcx # 0xf49b8 movq 0x8(%rcx,%rax), %rdx addl %edx, %edi cmpl $-0x7d, %edi jle 0xb7912 cmpl $-0x5f, %edi jge 0xb792e movq (%rcx,%rax), %rax popq %rcx retq leaq 0x35333(%rip), %rdi # 0xecbd9 leaq 0x35376(%rip), %rdx # 0xecc23 leaq 0x3ab6b(%rip), %rcx # 0xf241f movl $0x43e4, %esi # imm = 0x43E4 jmp 0xb7948 leaq 0x35314(%rip), %rdi # 0xecbd9 leaq 0x35357(%rip), %rdx # 0xecc23 leaq 0x3ab57(%rip), %rcx # 0xf242a movl $0x43e5, %esi # imm = 0x43E5 jmp 0xb7948 leaq 0x352f8(%rip), %rdi # 0xecbd9 leaq 0x3533b(%rip), %rdx # 0xecc23 leaq 0x3ab45(%rip), %rcx # 0xf2434 movl $0x43ea, %esi # imm = 0x43EA jmp 0xb7948 leaq 0x352dc(%rip), %rdi # 0xecbd9 leaq 0x3531f(%rip), %rdx # 0xecc23 leaq 0x3ab34(%rip), %rcx # 0xf243f movl $0x43eb, %esi # imm = 0x43EB jmp 0xb7948 leaq 0x352c0(%rip), %rdi # 0xecbd9 leaq 0x35303(%rip), %rdx # 0xecc23 leaq 0x3ab4f(%rip), %rcx # 0xf2476 movl $0x43ee, %esi # imm = 0x43EE jmp 0xb7948 leaq 0x352a4(%rip), %rdi # 0xecbd9 leaq 0x352e7(%rip), %rdx # 0xecc23 leaq 0x3ab4f(%rip), %rcx # 0xf2492 movl $0x43ef, %esi # imm = 0x43EF xorl %eax, %eax callq 0x1ae30 nop
_ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl36get_cached_power_for_binary_exponentEi: push rax cmp edi, 0FFFFFA23h jle loc_B789F cmp edi, 5DDh jge loc_B78BE mov ecx, 0FFFFFFC3h sub ecx, edi imul eax, ecx, 13441h lea edx, [rax+3FFFFh] test eax, eax cmovns edx, eax sar edx, 12h xor eax, eax test ecx, ecx setnle al add eax, edx cmp eax, 0FFFFFEC5h jle loc_B78DA lea ecx, [rax+133h] add eax, 13Ah test ecx, ecx cmovns eax, ecx sar eax, 3 cmp eax, 4Fh ; 'O' jnb loc_B78F6 mov eax, eax shl rax, 4 lea rcx, _ZZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl36get_cached_power_for_binary_exponentEiE13kCachedPowers; nlohmann::json_abi_v3_11_3::detail::dtoa_impl::get_cached_power_for_binary_exponent(int)::kCachedPowers mov rdx, [rcx+rax+8] add edi, edx cmp edi, 0FFFFFF83h jle loc_B7912 cmp edi, 0FFFFFFA1h jge loc_B792E mov rax, [rcx+rax] pop rcx retn loc_B789F: lea rdi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github/2025_star3"... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aE1500; "e >= -1500" mov esi, 43E4h jmp loc_B7948 loc_B78BE: lea rdi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github/2025_star3"... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aE1500_0; "e <= 1500" mov esi, 43E5h jmp short loc_B7948 loc_B78DA: lea rdi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github/2025_star3"... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aIndex0; "index >= 0" mov esi, 43EAh jmp short loc_B7948 loc_B78F6: lea rdi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github/2025_star3"... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aStaticCastStdS; "static_cast<std::size_t>(index) < kCach"... mov esi, 43EBh jmp short loc_B7948 loc_B7912: lea rdi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github/2025_star3"... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aKalphaCachedEE; "kAlpha <= cached.e + e + 64" mov esi, 43EEh jmp short loc_B7948 loc_B792E: lea rdi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github/2025_star3"... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aKgammaCachedEE; "kGamma >= cached.e + e + 64" mov esi, 43EFh loc_B7948: xor eax, eax call _ggml_abort nop
long long nlohmann::json_abi_v3_11_3::detail::dtoa_impl::get_cached_power_for_binary_exponent( nlohmann::json_abi_v3_11_3::detail::dtoa_impl *this) { int v1; // eax int v2; // ecx int v3; // eax unsigned int v4; // eax long long v5; // rax int v6; // edi long long v8; // rsi if ( (int)this <= -1501 ) { v8 = 17380LL; ggml_abort( "/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp", 17380LL, "GGML_ASSERT(%s) failed", "e >= -1500"); } else if ( (int)this >= 1501 ) { v8 = 17381LL; ggml_abort( "/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp", 17381LL, "GGML_ASSERT(%s) failed", "e <= 1500"); } else { v1 = 78913 * (-61 - (int)this) / 0x40000 + (-61 - (int)this > 0); if ( v1 <= -315 ) { v8 = 17386LL; ggml_abort( "/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp", 17386LL, "GGML_ASSERT(%s) failed", "index >= 0"); } else { v2 = v1 + 307; v3 = v1 + 314; if ( v2 >= 0 ) v3 = v2; v4 = v3 >> 3; if ( v4 >= 0x4F ) { v8 = 17387LL; ggml_abort( "/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp", 17387LL, "GGML_ASSERT(%s) failed", "static_cast<std::size_t>(index) < kCachedPowers.size()"); } else { v5 = 16LL * v4; v6 = *(_QWORD *)((char *)&nlohmann::json_abi_v3_11_3::detail::dtoa_impl::get_cached_power_for_binary_exponent(int)::kCachedPowers + v5 + 8) + (_DWORD)this; if ( v6 <= -125 ) { v8 = 17390LL; ggml_abort( "/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp", 17390LL, "GGML_ASSERT(%s) failed", "kAlpha <= cached.e + e + 64"); } else { if ( v6 < -95 ) return *(_QWORD *)((char *)&nlohmann::json_abi_v3_11_3::detail::dtoa_impl::get_cached_power_for_binary_exponent(int)::kCachedPowers + v5); v8 = 17391LL; ggml_abort( "/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp", 17391LL, "GGML_ASSERT(%s) failed", "kGamma >= cached.e + e + 64"); } } } } return nlohmann::json_abi_v3_11_3::detail::dtoa_impl::diyfp::mul( "/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp", v8); }
get_cached_power_for_binary_exponent: PUSH RAX CMP EDI,0xfffffa23 JLE 0x001b789f CMP EDI,0x5dd JGE 0x001b78be MOV ECX,0xffffffc3 SUB ECX,EDI IMUL EAX,ECX,0x13441 LEA EDX,[RAX + 0x3ffff] TEST EAX,EAX CMOVNS EDX,EAX SAR EDX,0x12 XOR EAX,EAX TEST ECX,ECX SETG AL ADD EAX,EDX CMP EAX,0xfffffec5 JLE 0x001b78da LEA ECX,[RAX + 0x133] ADD EAX,0x13a TEST ECX,ECX CMOVNS EAX,ECX SAR EAX,0x3 CMP EAX,0x4f JNC 0x001b78f6 MOV EAX,EAX SHL RAX,0x4 LEA RCX,[0x1f49b8] MOV RDX,qword ptr [RCX + RAX*0x1 + 0x8] ADD EDI,EDX CMP EDI,-0x7d JLE 0x001b7912 CMP EDI,-0x5f JGE 0x001b792e MOV RAX,qword ptr [RCX + RAX*0x1] POP RCX RET LAB_001b789f: LEA RDI,[0x1ecbd9] LEA RDX,[0x1ecc23] LEA RCX,[0x1f241f] MOV ESI,0x43e4 JMP 0x001b7948 LAB_001b78be: LEA RDI,[0x1ecbd9] LEA RDX,[0x1ecc23] LEA RCX,[0x1f242a] MOV ESI,0x43e5 JMP 0x001b7948 LAB_001b78da: LEA RDI,[0x1ecbd9] LEA RDX,[0x1ecc23] LEA RCX,[0x1f2434] MOV ESI,0x43ea JMP 0x001b7948 LAB_001b78f6: LEA RDI,[0x1ecbd9] LEA RDX,[0x1ecc23] LEA RCX,[0x1f243f] MOV ESI,0x43eb JMP 0x001b7948 LAB_001b7912: LEA RDI,[0x1ecbd9] LEA RDX,[0x1ecc23] LEA RCX,[0x1f2476] MOV ESI,0x43ee JMP 0x001b7948 LAB_001b792e: LEA RDI,[0x1ecbd9] LEA RDX,[0x1ecc23] LEA RCX,[0x1f2492] MOV ESI,0x43ef LAB_001b7948: XOR EAX,EAX CALL 0x0011ae30
/* nlohmann::json_abi_v3_11_3::detail::dtoa_impl::get_cached_power_for_binary_exponent(int) */ int8 nlohmann::json_abi_v3_11_3::detail::dtoa_impl::get_cached_power_for_binary_exponent(int param_1) { int iVar1; int iVar2; long lVar3; char *pcVar4; int8 uVar5; if (param_1 < -0x5dc) { pcVar4 = "e >= -1500"; uVar5 = 0x43e4; } else if (param_1 < 0x5dd) { iVar1 = (-0x3d - param_1) * 0x13441; iVar2 = iVar1 + 0x3ffff; if (-1 < iVar1) { iVar2 = iVar1; } iVar2 = (uint)(0 < -0x3d - param_1) + (iVar2 >> 0x12); if (iVar2 < -0x13a) { pcVar4 = "index >= 0"; uVar5 = 0x43ea; } else { iVar1 = iVar2 + 0x13a; if (-1 < iVar2 + 0x133) { iVar1 = iVar2 + 0x133; } if ((uint)(iVar1 >> 3) < 0x4f) { lVar3 = (ulong)(uint)(iVar1 >> 3) * 0x10; iVar2 = param_1 + (int)*(int8 *) (get_cached_power_for_binary_exponent(int)::kCachedPowers + lVar3 + 8); if (iVar2 < -0x7c) { pcVar4 = "kAlpha <= cached.e + e + 64"; uVar5 = 0x43ee; } else { if (iVar2 < -0x5f) { return *(int8 *)(get_cached_power_for_binary_exponent(int)::kCachedPowers + lVar3) ; } pcVar4 = "kGamma >= cached.e + e + 64"; uVar5 = 0x43ef; } } else { pcVar4 = "static_cast<std::size_t>(index) < kCachedPowers.size()"; uVar5 = 0x43eb; } } } else { pcVar4 = "e <= 1500"; uVar5 = 0x43e5; } /* WARNING: Subroutine does not return */ ggml_abort("/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",uVar5, "GGML_ASSERT(%s) failed",pcVar4); }
60,831
my_strtoll10_utf32
eloqsql/strings/ctype-ucs2.c
static longlong my_strtoll10_utf32(CHARSET_INFO *cs __attribute__((unused)), const char *nptr, char **endptr, int *error) { const char *s, *end, *start, *n_end, *true_end; uchar c; unsigned long i, j, k; ulonglong li; int negative; ulong cutoff, cutoff2, cutoff3; s= nptr; /* If fixed length string */ if (endptr) { /* Make sure string length is even */ end= s + ((*endptr - s) / 4) * 4; while (s < end && !s[0] && !s[1] && !s[2] && (s[3] == ' ' || s[3] == '\t')) s+= 4; if (s == end) goto no_conv; } else { /* We don't support null terminated strings in UCS2 */ goto no_conv; } /* Check for a sign. */ negative= 0; if (!s[0] && !s[1] && !s[2] && s[3] == '-') { *error= -1; /* Mark as negative number */ negative= 1; s+= 4; if (s == end) goto no_conv; cutoff= MAX_NEGATIVE_NUMBER / LFACTOR2; cutoff2= (MAX_NEGATIVE_NUMBER % LFACTOR2) / 100; cutoff3= MAX_NEGATIVE_NUMBER % 100; } else { *error= 0; if (!s[0] && !s[1] && !s[2] && s[3] == '+') { s+= 4; if (s == end) goto no_conv; } cutoff= ULONGLONG_MAX / LFACTOR2; cutoff2= ULONGLONG_MAX % LFACTOR2 / 100; cutoff3= ULONGLONG_MAX % 100; } /* Handle case where we have a lot of pre-zero */ if (!s[0] && !s[1] && !s[2] && s[3] == '0') { i= 0; do { s+= 4; if (s == end) goto end_i; /* Return 0 */ } while (!s[0] && !s[1] && !s[2] && s[3] == '0'); n_end= s + 4 * INIT_CNT; } else { /* Read first digit to check that it's a valid number */ if (s[0] || s[1] || s[2] || (c= (s[3]-'0')) > 9) goto no_conv; i= c; s+= 4; n_end= s + 4 * (INIT_CNT-1); } /* Handle first 9 digits and store them in i */ if (n_end > end) n_end= end; for (; s != n_end ; s+= 4) { if (s[0] || s[1] || s[2] || (c= (s[3] - '0')) > 9) goto end_i; i= i * 10 + c; } if (s == end) goto end_i; /* Handle next 9 digits and store them in j */ j= 0; start= s; /* Used to know how much to shift i */ n_end= true_end= s + 4 * INIT_CNT; if (n_end > end) n_end= end; do { if (s[0] || s[1] || s[2] || (c= (s[3] - '0')) > 9) goto end_i_and_j; j= j * 10 + c; s+= 4; } while (s != n_end); if (s == end) { if (s != true_end) goto end_i_and_j; goto end3; } if (s[0] || s[1] || s[2] || (c= (s[3] - '0')) > 9) goto end3; /* Handle the next 1 or 2 digits and store them in k */ k=c; s+= 4; if (s == end || s[0] || s[1] || s[2] || (c= (s[3]-'0')) > 9) goto end4; k= k * 10 + c; s+= 4; *endptr= (char*) s; /* number string should have ended here */ if (s != end && !s[0] && !s[1] && !s[2] && (c= (s[3] - '0')) <= 9) goto overflow; /* Check that we didn't get an overflow with the last digit */ if (i > cutoff || (i == cutoff && ((j > cutoff2 || j == cutoff2) && k > cutoff3))) goto overflow; li= i * LFACTOR2+ (ulonglong) j * 100 + k; return (longlong) li; overflow: /* *endptr is set here */ *error= MY_ERRNO_ERANGE; return negative ? LONGLONG_MIN : (longlong) ULONGLONG_MAX; end_i: *endptr= (char*) s; return (negative ? ((longlong) -(long) i) : (longlong) i); end_i_and_j: li= (ulonglong) i * lfactor[(size_t) (s-start) / 4] + j; *endptr= (char*) s; return (negative ? -((longlong) li) : (longlong) li); end3: li= (ulonglong) i*LFACTOR+ (ulonglong) j; *endptr= (char*) s; return (negative ? -((longlong) li) : (longlong) li); end4: li= (ulonglong) i*LFACTOR1+ (ulonglong) j * 10 + k; *endptr= (char*) s; if (negative) { if (li > MAX_NEGATIVE_NUMBER) goto overflow; return -((longlong) li); } return (longlong) li; no_conv: /* There was no number to convert. */ *error= MY_ERRNO_EDOM; *endptr= (char *) nptr; return 0; }
O3
c
my_strtoll10_utf32: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx testq %rdx, %rdx je 0xcae0e movq (%rdx), %rdi subq %rsi, %rdi leaq 0x3(%rdi), %rax testq %rdi, %rdi cmovnsq %rdi, %rax andq $-0x4, %rax addq %rsi, %rax movq %rsi, %r11 cmpq $0x4, %rdi jl 0xcad18 movq %rsi, %r11 cmpb $0x0, (%r11) jne 0xcad18 cmpb $0x0, 0x1(%r11) jne 0xcad18 cmpb $0x0, 0x2(%r11) jne 0xcad18 movzbl 0x3(%r11), %edi cmpl $0x20, %edi je 0xcad0f cmpl $0x9, %edi jne 0xcad18 addq $0x4, %r11 cmpq %rax, %r11 jb 0xcacec cmpq %rax, %r11 je 0xcae0e cmpb $0x0, (%r11) jne 0xcad65 cmpb $0x0, 0x1(%r11) jne 0xcad65 cmpb $0x0, 0x2(%r11) jne 0xcad65 cmpb $0x2d, 0x3(%r11) jne 0xcad65 movl $0xffffffff, (%rcx) # imm = 0xFFFFFFFF addq $0x4, %r11 cmpq %rax, %r11 je 0xcae0e movl $0x8, %r8d movl $0x15f797ae, %r9d # imm = 0x15F797AE movl $0x57f5ff8, %r10d # imm = 0x57F5FF8 xorl %edi, %edi jmp 0xcada8 movl $0x0, (%rcx) cmpb $0x0, (%r11) jne 0xcae0e movl $0xf, %r8d movl $0x2bef2f5c, %r9d # imm = 0x2BEF2F5C movl $0xafebff0, %r10d # imm = 0xAFEBFF0 movb $0x1, %dil cmpb $0x0, 0x1(%r11) jne 0xcada8 cmpb $0x0, 0x2(%r11) jne 0xcada8 cmpb $0x2b, 0x3(%r11) jne 0xcada8 addq $0x4, %r11 cmpq %rax, %r11 je 0xcae0e cmpb $0x0, (%r11) jne 0xcae0e cmpb $0x0, 0x1(%r11) jne 0xcae0e cmpb $0x0, 0x2(%r11) jne 0xcadfb cmpb $0x30, 0x3(%r11) jne 0xcadfb addq $0x28, %r11 xorl %esi, %esi leaq -0x24(%r11), %rbx cmpq %rax, %rbx je 0xcafb1 movq %r11, %r14 cmpb $0x0, (%rbx) jne 0xcadf7 cmpb $0x0, -0x23(%r14) jne 0xcadf7 cmpb $0x0, -0x22(%r14) jne 0xcadf7 leaq 0x4(%r14), %r11 cmpb $0x30, -0x21(%r14) je 0xcadc9 xorl %esi, %esi jmp 0xcae32 cmpb $0x0, 0x2(%r11) jne 0xcae0e movb 0x3(%r11), %bl addb $-0x30, %bl cmpb $0x9, %bl jbe 0xcae24 movl $0x21, (%rcx) movq %rsi, (%rdx) xorl %eax, %eax popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq movzbl %bl, %esi leaq 0x4(%r11), %rbx addq $0x24, %r11 movq %r11, %r14 cmpq %rax, %r14 cmovaq %rax, %r14 cmpq %r14, %rbx je 0xcae7f cmpb $0x0, (%rbx) jne 0xcafae cmpb $0x0, 0x1(%rbx) jne 0xcafae cmpb $0x0, 0x2(%rbx) jne 0xcafae movb 0x3(%rbx), %r11b addb $-0x30, %r11b cmpb $0x9, %r11b ja 0xcafae leaq (%rsi,%rsi,4), %rsi movzbl %r11b, %r11d leaq (%r11,%rsi,2), %rsi addq $0x4, %rbx jmp 0xcae39 cmpq %rax, %rbx je 0xcafae leaq 0x24(%rbx), %r12 cmpq %rax, %r12 cmovaq %rax, %r12 leaq 0x8(%rbx), %r14 movl $0x24, %r13d xorl %r11d, %r11d cmpb $0x0, -0x8(%r14) jne 0xcafb6 cmpb $0x0, -0x7(%r14) jne 0xcafb6 cmpb $0x0, -0x6(%r14) jne 0xcafb6 movb -0x5(%r14), %r15b addb $-0x30, %r15b cmpb $0x9, %r15b ja 0xcafb6 leaq (%r11,%r11,4), %r11 movzbl %r15b, %r15d leaq (%r15,%r11,2), %r11 leaq 0x4(%r14), %r15 addq $-0x4, %r14 addq $-0x4, %r13 cmpq %r12, %r14 movq %r15, %r14 jne 0xcaea0 leaq -0x8(%r15), %r14 cmpq %rax, %r12 je 0xcafe8 cmpb $0x0, (%r14) jne 0xcafed cmpb $0x0, -0x7(%r15) jne 0xcafed cmpb $0x0, -0x6(%r15) jne 0xcafed movb -0x5(%r15), %bl addb $-0x30, %bl cmpb $0x9, %bl ja 0xcafed movzbl %bl, %ebx leaq -0x4(%r15), %r12 cmpq %rax, %r12 je 0xcaf63 cmpb $0x0, -0x4(%r15) jne 0xcaf63 cmpb $0x0, -0x3(%r15) jne 0xcaf63 cmpb $0x0, -0x2(%r15) jne 0xcaf63 movb -0x1(%r15), %r14b addb $-0x30, %r14b cmpb $0x9, %r14b jbe 0xcb014 movabsq $0x2540be400, %rax # imm = 0x2540BE400 imulq %rax, %rsi leaq (%r11,%r11,4), %rax leaq (%rsi,%rax,2), %rax addq %rbx, %rax movq %r12, (%rdx) testb %dil, %dil jne 0xcae19 movabsq $-0x8000000000000000, %rdx # imm = 0x8000000000000000 cmpq %rdx, %rax jbe 0xcb00c movl $0x22, (%rcx) movzbl %dil, %eax negq %rax btsq $0x3f, %rax jmp 0xcae19 movq %rbx, %rax movq %rax, (%rdx) jmp 0xcafd6 addq $-0x8, %r14 movq %r14, %rax subq %rbx, %rax andq $-0x4, %rax leaq 0x211425(%rip), %rcx # 0x2dc3f0 imulq (%rcx,%rax,2), %rsi addq %r11, %rsi movq %r14, (%rdx) movq %rsi, %rax negq %rax testb %dil, %dil cmovneq %rsi, %rax jmp 0xcae19 testq %r13, %r13 jne 0xcafba imulq $0x3b9aca00, %rsi, %rax # imm = 0x3B9ACA00 addq %rax, %r11 movq %r14, (%rdx) movq %r11, %rax negq %rax testb %dil, %dil cmovneq %r11, %rax jmp 0xcae19 negq %rax jmp 0xcae19 movq %r15, (%rdx) cmpq %rax, %r15 je 0xcb03e cmpb $0x0, (%r15) jne 0xcb03e cmpb $0x0, 0x1(%r15) jne 0xcb03e cmpb $0x0, 0x2(%r15) jne 0xcb03e movb 0x3(%r15), %al addb $-0x30, %al cmpb $0xa, %al jb 0xcaf97 cmpq %r10, %rsi ja 0xcaf97 leaq (%rbx,%rbx,4), %rax movzbl %r14b, %edx leaq (%rdx,%rax,2), %rax cmpq %r10, %rsi jne 0xcb066 cmpq %r9, %r11 jb 0xcb066 cmpl %r8d, %eax ja 0xcaf97 movabsq $0x174876e800, %rcx # imm = 0x174876E800 imulq %rcx, %rsi imulq $0x64, %r11, %rcx addq %rax, %rsi addq %rcx, %rsi movq %rsi, %rax jmp 0xcae19
my_strtoll10_utf32: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx test rdx, rdx jz loc_CAE0E mov rdi, [rdx] sub rdi, rsi lea rax, [rdi+3] test rdi, rdi cmovns rax, rdi and rax, 0FFFFFFFFFFFFFFFCh add rax, rsi mov r11, rsi cmp rdi, 4 jl short loc_CAD18 mov r11, rsi loc_CACEC: cmp byte ptr [r11], 0 jnz short loc_CAD18 cmp byte ptr [r11+1], 0 jnz short loc_CAD18 cmp byte ptr [r11+2], 0 jnz short loc_CAD18 movzx edi, byte ptr [r11+3] cmp edi, 20h ; ' ' jz short loc_CAD0F cmp edi, 9 jnz short loc_CAD18 loc_CAD0F: add r11, 4 cmp r11, rax jb short loc_CACEC loc_CAD18: cmp r11, rax jz loc_CAE0E cmp byte ptr [r11], 0 jnz short loc_CAD65 cmp byte ptr [r11+1], 0 jnz short loc_CAD65 cmp byte ptr [r11+2], 0 jnz short loc_CAD65 cmp byte ptr [r11+3], 2Dh ; '-' jnz short loc_CAD65 mov dword ptr [rcx], 0FFFFFFFFh add r11, 4 cmp r11, rax jz loc_CAE0E mov r8d, 8 mov r9d, 15F797AEh mov r10d, 57F5FF8h xor edi, edi jmp short loc_CADA8 loc_CAD65: mov dword ptr [rcx], 0 cmp byte ptr [r11], 0 jnz loc_CAE0E mov r8d, 0Fh mov r9d, 2BEF2F5Ch mov r10d, 0AFEBFF0h mov dil, 1 cmp byte ptr [r11+1], 0 jnz short loc_CADA8 cmp byte ptr [r11+2], 0 jnz short loc_CADA8 cmp byte ptr [r11+3], 2Bh ; '+' jnz short loc_CADA8 add r11, 4 cmp r11, rax jz short loc_CAE0E loc_CADA8: cmp byte ptr [r11], 0 jnz short loc_CAE0E cmp byte ptr [r11+1], 0 jnz short loc_CAE0E cmp byte ptr [r11+2], 0 jnz short loc_CADFB cmp byte ptr [r11+3], 30h ; '0' jnz short loc_CADFB add r11, 28h ; '(' xor esi, esi loc_CADC9: lea rbx, [r11-24h] cmp rbx, rax jz loc_CAFB1 mov r14, r11 cmp byte ptr [rbx], 0 jnz short loc_CADF7 cmp byte ptr [r14-23h], 0 jnz short loc_CADF7 cmp byte ptr [r14-22h], 0 jnz short loc_CADF7 lea r11, [r14+4] cmp byte ptr [r14-21h], 30h ; '0' jz short loc_CADC9 loc_CADF7: xor esi, esi jmp short loc_CAE32 loc_CADFB: cmp byte ptr [r11+2], 0 jnz short loc_CAE0E mov bl, [r11+3] add bl, 0D0h cmp bl, 9 jbe short loc_CAE24 loc_CAE0E: mov dword ptr [rcx], 21h ; '!' mov [rdx], rsi xor eax, eax loc_CAE19: pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn loc_CAE24: movzx esi, bl lea rbx, [r11+4] add r11, 24h ; '$' mov r14, r11 loc_CAE32: cmp r14, rax cmova r14, rax loc_CAE39: cmp rbx, r14 jz short loc_CAE7F cmp byte ptr [rbx], 0 jnz loc_CAFAE cmp byte ptr [rbx+1], 0 jnz loc_CAFAE cmp byte ptr [rbx+2], 0 jnz loc_CAFAE mov r11b, [rbx+3] add r11b, 0D0h cmp r11b, 9 ja loc_CAFAE lea rsi, [rsi+rsi*4] movzx r11d, r11b lea rsi, [r11+rsi*2] add rbx, 4 jmp short loc_CAE39 loc_CAE7F: cmp rbx, rax jz loc_CAFAE lea r12, [rbx+24h] cmp r12, rax cmova r12, rax lea r14, [rbx+8] mov r13d, 24h ; '$' xor r11d, r11d loc_CAEA0: cmp byte ptr [r14-8], 0 jnz loc_CAFB6 cmp byte ptr [r14-7], 0 jnz loc_CAFB6 cmp byte ptr [r14-6], 0 jnz loc_CAFB6 mov r15b, [r14-5] add r15b, 0D0h cmp r15b, 9 ja loc_CAFB6 lea r11, [r11+r11*4] movzx r15d, r15b lea r11, [r15+r11*2] lea r15, [r14+4] add r14, 0FFFFFFFFFFFFFFFCh add r13, 0FFFFFFFFFFFFFFFCh cmp r14, r12 mov r14, r15 jnz short loc_CAEA0 lea r14, [r15-8] cmp r12, rax jz loc_CAFE8 cmp byte ptr [r14], 0 jnz loc_CAFED cmp byte ptr [r15-7], 0 jnz loc_CAFED cmp byte ptr [r15-6], 0 jnz loc_CAFED mov bl, [r15-5] add bl, 0D0h cmp bl, 9 ja loc_CAFED movzx ebx, bl lea r12, [r15-4] cmp r12, rax jz short loc_CAF63 cmp byte ptr [r15-4], 0 jnz short loc_CAF63 cmp byte ptr [r15-3], 0 jnz short loc_CAF63 cmp byte ptr [r15-2], 0 jnz short loc_CAF63 mov r14b, [r15-1] add r14b, 0D0h cmp r14b, 9 jbe loc_CB014 loc_CAF63: mov rax, 2540BE400h imul rsi, rax lea rax, [r11+r11*4] lea rax, [rsi+rax*2] add rax, rbx mov [rdx], r12 test dil, dil jnz loc_CAE19 mov rdx, 8000000000000000h cmp rax, rdx jbe short loc_CB00C loc_CAF97: mov dword ptr [rcx], 22h ; '"' movzx eax, dil neg rax bts rax, 3Fh ; '?' jmp loc_CAE19 loc_CAFAE: mov rax, rbx loc_CAFB1: mov [rdx], rax jmp short loc_CAFD6 loc_CAFB6: add r14, 0FFFFFFFFFFFFFFF8h loc_CAFBA: mov rax, r14 sub rax, rbx and rax, 0FFFFFFFFFFFFFFFCh lea rcx, lfactor imul rsi, [rcx+rax*2] add rsi, r11 mov [rdx], r14 loc_CAFD6: mov rax, rsi neg rax test dil, dil cmovnz rax, rsi jmp loc_CAE19 loc_CAFE8: test r13, r13 jnz short loc_CAFBA loc_CAFED: imul rax, rsi, 3B9ACA00h add r11, rax mov [rdx], r14 mov rax, r11 neg rax test dil, dil cmovnz rax, r11 jmp loc_CAE19 loc_CB00C: neg rax jmp loc_CAE19 loc_CB014: mov [rdx], r15 cmp r15, rax jz short loc_CB03E cmp byte ptr [r15], 0 jnz short loc_CB03E cmp byte ptr [r15+1], 0 jnz short loc_CB03E cmp byte ptr [r15+2], 0 jnz short loc_CB03E mov al, [r15+3] add al, 0D0h cmp al, 0Ah jb loc_CAF97 loc_CB03E: cmp rsi, r10 ja loc_CAF97 lea rax, [rbx+rbx*4] movzx edx, r14b lea rax, [rdx+rax*2] cmp rsi, r10 jnz short loc_CB066 cmp r11, r9 jb short loc_CB066 cmp eax, r8d ja loc_CAF97 loc_CB066: mov rcx, 174876E800h imul rsi, rcx imul rcx, r11, 64h ; 'd' add rsi, rax add rsi, rcx mov rax, rsi jmp loc_CAE19
unsigned long long my_strtoll10_utf32(long long a1, _BYTE *a2, unsigned long long *a3, _DWORD *a4) { long long v4; // rdi long long v5; // rax unsigned long long v6; // rax _BYTE *v7; // r11 int v8; // edi unsigned int v9; // r8d unsigned long long v10; // r9 unsigned long long v11; // r10 unsigned __int8 v12; // di _BYTE *v13; // r11 unsigned long long v14; // rsi _BYTE *v15; // rbx _BYTE *v16; // r14 unsigned __int8 v17; // bl unsigned long long result; // rax unsigned __int8 v19; // r11 _BYTE *v20; // r12 _BYTE *v21; // r14 long long v22; // r13 unsigned long long v23; // r11 unsigned __int8 v24; // r15 _BYTE *v25; // r15 bool v26; // zf _BYTE *v27; // r14 unsigned __int8 v28; // bl unsigned __int8 v29; // r14 unsigned long long v30; // r11 long long v31; // rax if ( !a3 ) goto LABEL_37; v4 = *a3 - (_QWORD)a2; v5 = v4 + 3; if ( v4 >= 0 ) v5 = *a3 - (_QWORD)a2; v6 = (unsigned long long)&a2[v5 & 0xFFFFFFFFFFFFFFFCLL]; v7 = a2; if ( v4 >= 4 ) { v7 = a2; do { if ( *v7 ) break; if ( v7[1] ) break; if ( v7[2] ) break; v8 = (unsigned __int8)v7[3]; if ( v8 != 32 && v8 != 9 ) break; v7 += 4; } while ( (unsigned long long)v7 < v6 ); } if ( v7 == (_BYTE *)v6 ) goto LABEL_37; if ( *v7 || v7[1] || v7[2] || v7[3] != 45 ) { *a4 = 0; if ( *v7 ) goto LABEL_37; v9 = 15; v10 = 737095516LL; v11 = 184467440LL; v12 = 1; if ( !v7[1] && !v7[2] && v7[3] == 43 ) { v7 += 4; if ( v7 == (_BYTE *)v6 ) goto LABEL_37; } } else { *a4 = -1; v7 += 4; if ( v7 == (_BYTE *)v6 ) goto LABEL_37; v9 = 8; v10 = 368547758LL; v11 = 92233720LL; v12 = 0; } if ( *v7 || v7[1] ) goto LABEL_37; if ( !v7[2] && v7[3] == 48 ) { v13 = v7 + 40; v14 = 0LL; while ( 1 ) { v15 = v13 - 36; if ( v13 - 36 == (_BYTE *)v6 ) goto LABEL_71; v16 = v13; if ( !*v15 && !*(v13 - 35) && !*(v13 - 34) ) { v13 += 4; if ( *(v16 - 33) == 48 ) continue; } v14 = 0LL; goto LABEL_40; } } if ( v7[2] || (v17 = v7[3] - 48, v17 > 9u) ) { LABEL_37: *a4 = 33; *a3 = (unsigned long long)a2; return 0LL; } v14 = v17; v15 = v7 + 4; v16 = v7 + 36; LABEL_40: if ( (unsigned long long)v16 > v6 ) v16 = (_BYTE *)v6; while ( v15 != v16 ) { if ( *v15 ) goto LABEL_70; if ( v15[1] ) goto LABEL_70; if ( v15[2] ) goto LABEL_70; v19 = v15[3] - 48; if ( v19 > 9u ) goto LABEL_70; v14 = v19 + 10 * v14; v15 += 4; } if ( v15 != (_BYTE *)v6 ) { v20 = v15 + 36; if ( (unsigned long long)(v15 + 36) > v6 ) v20 = (_BYTE *)v6; v21 = v15 + 8; v22 = 36LL; v23 = 0LL; while ( !*(v21 - 8) ) { if ( *(v21 - 7) ) break; if ( *(v21 - 6) ) break; v24 = *(v21 - 5) - 48; if ( v24 > 9u ) break; v23 = v24 + 10 * v23; v25 = v21 + 4; v22 -= 4LL; v26 = v21 - 4 == v20; v21 += 4; if ( v26 ) { v27 = v25 - 8; if ( v20 != (_BYTE *)v6 ) { if ( !*v27 && !*(v25 - 7) && !*(v25 - 6) ) { v28 = *(v25 - 5) - 48; if ( v28 <= 9u ) { if ( v25 - 4 == (_BYTE *)v6 || *(v25 - 4) || *(v25 - 3) || *(v25 - 2) || (v29 = *(v25 - 1) - 48, v29 > 9u) ) { result = v28 + 10000000000LL * v14 + 10 * v23; *a3 = (unsigned long long)(v25 - 4); if ( v12 ) return result; if ( result > 0x8000000000000000LL ) goto LABEL_69; return -(long long)result; } else { *a3 = (unsigned long long)v25; if ( v25 != (_BYTE *)v6 && !*v25 && !v25[1] && !v25[2] && (unsigned __int8)(v25[3] - 48) < 0xAu || v14 > v11 || (v31 = v29 + 10LL * v28, v14 == v11) && v23 >= v10 && (unsigned int)v31 > v9 ) { LABEL_69: *a4 = 34; return -(long long)v12 | 0x8000000000000000LL; } return 100 * v23 + v31 + 100000000000LL * v14; } } } LABEL_78: v30 = 1000000000 * v14 + v23; *a3 = (unsigned long long)v27; result = -(long long)v30; if ( v12 ) return v30; return result; } if ( !v22 ) goto LABEL_78; LABEL_73: v14 = v23 + *(_QWORD *)((char *)&lfactor + 2 * ((v27 - v15) & 0xFFFFFFFFFFFFFFFCLL)) * v14; *a3 = (unsigned long long)v27; goto LABEL_74; } } v27 = v21 - 8; goto LABEL_73; } LABEL_70: v6 = (unsigned long long)v15; LABEL_71: *a3 = v6; LABEL_74: result = -(long long)v14; if ( v12 ) return v14; return result; }
my_strtoll10_utf32: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX TEST RDX,RDX JZ 0x001cae0e MOV RDI,qword ptr [RDX] SUB RDI,RSI LEA RAX,[RDI + 0x3] TEST RDI,RDI CMOVNS RAX,RDI AND RAX,-0x4 ADD RAX,RSI MOV R11,RSI CMP RDI,0x4 JL 0x001cad18 MOV R11,RSI LAB_001cacec: CMP byte ptr [R11],0x0 JNZ 0x001cad18 CMP byte ptr [R11 + 0x1],0x0 JNZ 0x001cad18 CMP byte ptr [R11 + 0x2],0x0 JNZ 0x001cad18 MOVZX EDI,byte ptr [R11 + 0x3] CMP EDI,0x20 JZ 0x001cad0f CMP EDI,0x9 JNZ 0x001cad18 LAB_001cad0f: ADD R11,0x4 CMP R11,RAX JC 0x001cacec LAB_001cad18: CMP R11,RAX JZ 0x001cae0e CMP byte ptr [R11],0x0 JNZ 0x001cad65 CMP byte ptr [R11 + 0x1],0x0 JNZ 0x001cad65 CMP byte ptr [R11 + 0x2],0x0 JNZ 0x001cad65 CMP byte ptr [R11 + 0x3],0x2d JNZ 0x001cad65 MOV dword ptr [RCX],0xffffffff ADD R11,0x4 CMP R11,RAX JZ 0x001cae0e MOV R8D,0x8 MOV R9D,0x15f797ae MOV R10D,0x57f5ff8 XOR EDI,EDI JMP 0x001cada8 LAB_001cad65: MOV dword ptr [RCX],0x0 CMP byte ptr [R11],0x0 JNZ 0x001cae0e MOV R8D,0xf MOV R9D,0x2bef2f5c MOV R10D,0xafebff0 MOV DIL,0x1 CMP byte ptr [R11 + 0x1],0x0 JNZ 0x001cada8 CMP byte ptr [R11 + 0x2],0x0 JNZ 0x001cada8 CMP byte ptr [R11 + 0x3],0x2b JNZ 0x001cada8 ADD R11,0x4 CMP R11,RAX JZ 0x001cae0e LAB_001cada8: CMP byte ptr [R11],0x0 JNZ 0x001cae0e CMP byte ptr [R11 + 0x1],0x0 JNZ 0x001cae0e CMP byte ptr [R11 + 0x2],0x0 JNZ 0x001cadfb CMP byte ptr [R11 + 0x3],0x30 JNZ 0x001cadfb ADD R11,0x28 XOR ESI,ESI LAB_001cadc9: LEA RBX,[R11 + -0x24] CMP RBX,RAX JZ 0x001cafb1 MOV R14,R11 CMP byte ptr [RBX],0x0 JNZ 0x001cadf7 CMP byte ptr [R14 + -0x23],0x0 JNZ 0x001cadf7 CMP byte ptr [R14 + -0x22],0x0 JNZ 0x001cadf7 LEA R11,[R14 + 0x4] CMP byte ptr [R14 + -0x21],0x30 JZ 0x001cadc9 LAB_001cadf7: XOR ESI,ESI JMP 0x001cae32 LAB_001cadfb: CMP byte ptr [R11 + 0x2],0x0 JNZ 0x001cae0e MOV BL,byte ptr [R11 + 0x3] ADD BL,0xd0 CMP BL,0x9 JBE 0x001cae24 LAB_001cae0e: MOV dword ptr [RCX],0x21 MOV qword ptr [RDX],RSI XOR EAX,EAX LAB_001cae19: POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET LAB_001cae24: MOVZX ESI,BL LEA RBX,[R11 + 0x4] ADD R11,0x24 MOV R14,R11 LAB_001cae32: CMP R14,RAX CMOVA R14,RAX LAB_001cae39: CMP RBX,R14 JZ 0x001cae7f CMP byte ptr [RBX],0x0 JNZ 0x001cafae CMP byte ptr [RBX + 0x1],0x0 JNZ 0x001cafae CMP byte ptr [RBX + 0x2],0x0 JNZ 0x001cafae MOV R11B,byte ptr [RBX + 0x3] ADD R11B,0xd0 CMP R11B,0x9 JA 0x001cafae LEA RSI,[RSI + RSI*0x4] MOVZX R11D,R11B LEA RSI,[R11 + RSI*0x2] ADD RBX,0x4 JMP 0x001cae39 LAB_001cae7f: CMP RBX,RAX JZ 0x001cafae LEA R12,[RBX + 0x24] CMP R12,RAX CMOVA R12,RAX LEA R14,[RBX + 0x8] MOV R13D,0x24 XOR R11D,R11D LAB_001caea0: CMP byte ptr [R14 + -0x8],0x0 JNZ 0x001cafb6 CMP byte ptr [R14 + -0x7],0x0 JNZ 0x001cafb6 CMP byte ptr [R14 + -0x6],0x0 JNZ 0x001cafb6 MOV R15B,byte ptr [R14 + -0x5] ADD R15B,0xd0 CMP R15B,0x9 JA 0x001cafb6 LEA R11,[R11 + R11*0x4] MOVZX R15D,R15B LEA R11,[R15 + R11*0x2] LEA R15,[R14 + 0x4] ADD R14,-0x4 ADD R13,-0x4 CMP R14,R12 MOV R14,R15 JNZ 0x001caea0 LEA R14,[R15 + -0x8] CMP R12,RAX JZ 0x001cafe8 CMP byte ptr [R14],0x0 JNZ 0x001cafed CMP byte ptr [R15 + -0x7],0x0 JNZ 0x001cafed CMP byte ptr [R15 + -0x6],0x0 JNZ 0x001cafed MOV BL,byte ptr [R15 + -0x5] ADD BL,0xd0 CMP BL,0x9 JA 0x001cafed MOVZX EBX,BL LEA R12,[R15 + -0x4] CMP R12,RAX JZ 0x001caf63 CMP byte ptr [R15 + -0x4],0x0 JNZ 0x001caf63 CMP byte ptr [R15 + -0x3],0x0 JNZ 0x001caf63 CMP byte ptr [R15 + -0x2],0x0 JNZ 0x001caf63 MOV R14B,byte ptr [R15 + -0x1] ADD R14B,0xd0 CMP R14B,0x9 JBE 0x001cb014 LAB_001caf63: MOV RAX,0x2540be400 IMUL RSI,RAX LEA RAX,[R11 + R11*0x4] LEA RAX,[RSI + RAX*0x2] ADD RAX,RBX MOV qword ptr [RDX],R12 TEST DIL,DIL JNZ 0x001cae19 MOV RDX,-0x8000000000000000 CMP RAX,RDX JBE 0x001cb00c LAB_001caf97: MOV dword ptr [RCX],0x22 MOVZX EAX,DIL NEG RAX BTS RAX,0x3f JMP 0x001cae19 LAB_001cafae: MOV RAX,RBX LAB_001cafb1: MOV qword ptr [RDX],RAX JMP 0x001cafd6 LAB_001cafb6: ADD R14,-0x8 LAB_001cafba: MOV RAX,R14 SUB RAX,RBX AND RAX,-0x4 LEA RCX,[0x3dc3f0] IMUL RSI,qword ptr [RCX + RAX*0x2] ADD RSI,R11 MOV qword ptr [RDX],R14 LAB_001cafd6: MOV RAX,RSI NEG RAX TEST DIL,DIL CMOVNZ RAX,RSI JMP 0x001cae19 LAB_001cafe8: TEST R13,R13 JNZ 0x001cafba LAB_001cafed: IMUL RAX,RSI,0x3b9aca00 ADD R11,RAX MOV qword ptr [RDX],R14 MOV RAX,R11 NEG RAX TEST DIL,DIL CMOVNZ RAX,R11 JMP 0x001cae19 LAB_001cb00c: NEG RAX JMP 0x001cae19 LAB_001cb014: MOV qword ptr [RDX],R15 CMP R15,RAX JZ 0x001cb03e CMP byte ptr [R15],0x0 JNZ 0x001cb03e CMP byte ptr [R15 + 0x1],0x0 JNZ 0x001cb03e CMP byte ptr [R15 + 0x2],0x0 JNZ 0x001cb03e MOV AL,byte ptr [R15 + 0x3] ADD AL,0xd0 CMP AL,0xa JC 0x001caf97 LAB_001cb03e: CMP RSI,R10 JA 0x001caf97 LEA RAX,[RBX + RBX*0x4] MOVZX EDX,R14B LEA RAX,[RDX + RAX*0x2] CMP RSI,R10 JNZ 0x001cb066 CMP R11,R9 JC 0x001cb066 CMP EAX,R8D JA 0x001caf97 LAB_001cb066: MOV RCX,0x174876e800 IMUL RSI,RCX IMUL RCX,R11,0x64 ADD RSI,RAX ADD RSI,RCX MOV RAX,RSI JMP 0x001cae19
ulong my_strtoll10_utf32(int8 param_1,char *param_2,long *param_3,int4 *param_4) { char *pcVar1; char cVar2; char *pcVar3; byte bVar4; char *pcVar5; ulong uVar6; byte bVar7; ulong uVar8; uint uVar9; ulong uVar10; char *pcVar11; ulong uVar12; long lVar13; char *pcVar14; char *pcVar15; if (param_3 != (long *)0x0) { uVar8 = *param_3 - (long)param_2; uVar10 = uVar8 + 3; if (-1 < (long)uVar8) { uVar10 = uVar8; } pcVar3 = param_2 + (uVar10 & 0xfffffffffffffffc); pcVar11 = param_2; if (3 < (long)uVar8) { do { if ((((*pcVar11 != '\0') || (pcVar11[1] != '\0')) || (pcVar11[2] != '\0')) || ((pcVar11[3] != ' ' && (pcVar11[3] != '\t')))) break; pcVar11 = pcVar11 + 4; } while (pcVar11 < pcVar3); } if (pcVar11 != pcVar3) { if (((*pcVar11 == '\0') && (pcVar11[1] == '\0')) && ((pcVar11[2] == '\0' && (pcVar11[3] == '-')))) { *param_4 = 0xffffffff; pcVar11 = pcVar11 + 4; if (pcVar11 == pcVar3) goto LAB_001cae0e; uVar9 = 8; uVar10 = 0x15f797ae; uVar8 = 0x57f5ff8; bVar7 = 0; } else { *param_4 = 0; if (*pcVar11 != '\0') goto LAB_001cae0e; uVar9 = 0xf; uVar10 = 0x2bef2f5c; uVar8 = 0xafebff0; bVar7 = 1; if ((((pcVar11[1] == '\0') && (pcVar11[2] == '\0')) && (pcVar11[3] == '+')) && (pcVar11 = pcVar11 + 4, pcVar11 == pcVar3)) goto LAB_001cae0e; } if ((*pcVar11 == '\0') && (pcVar11[1] == '\0')) { if ((pcVar11[2] == '\0') && (pcVar11[3] == '0')) { uVar6 = 0; pcVar5 = pcVar11 + 0x28; do { pcVar11 = pcVar5; pcVar1 = pcVar11 + -0x24; pcVar5 = pcVar3; if (pcVar1 == pcVar3) goto LAB_001cafb1; } while ((((*pcVar1 == '\0') && (pcVar11[-0x23] == '\0')) && (pcVar11[-0x22] == '\0')) && (pcVar5 = pcVar11 + 4, pcVar11[-0x21] == '0')); uVar6 = 0; pcVar5 = pcVar1; } else { if ((pcVar11[2] != '\0') || (9 < (byte)(pcVar11[3] - 0x30U))) goto LAB_001cae0e; uVar6 = (ulong)(byte)(pcVar11[3] - 0x30U); pcVar5 = pcVar11 + 4; pcVar11 = pcVar11 + 0x24; } if (pcVar3 < pcVar11) { pcVar11 = pcVar3; } for (; pcVar5 != pcVar11; pcVar5 = pcVar5 + 4) { if (((*pcVar5 != '\0') || (pcVar5[1] != '\0')) || ((pcVar5[2] != '\0' || (9 < (byte)(pcVar5[3] - 0x30U))))) goto LAB_001cafb1; uVar6 = (ulong)(byte)(pcVar5[3] - 0x30U) + uVar6 * 10; } if (pcVar5 != pcVar3) { pcVar11 = pcVar5 + 0x24; if (pcVar3 < pcVar5 + 0x24) { pcVar11 = pcVar3; } lVar13 = 0x24; uVar12 = 0; pcVar1 = pcVar5 + 8; do { pcVar14 = pcVar1; if (((pcVar14[-8] != '\0') || (pcVar14[-7] != '\0')) || ((pcVar14[-6] != '\0' || (9 < (byte)(pcVar14[-5] - 0x30U))))) { pcVar15 = pcVar14 + -8; goto LAB_001cafba; } uVar12 = (ulong)(byte)(pcVar14[-5] - 0x30U) + uVar12 * 10; pcVar1 = pcVar14 + 4; lVar13 = lVar13 + -4; } while (pcVar14 + -4 != pcVar11); pcVar15 = pcVar14 + -4; if (pcVar11 == pcVar3) { if (lVar13 != 0) { LAB_001cafba: uVar6 = uVar6 * *(long *)((long)&lfactor + ((long)pcVar15 - (long)pcVar5 & 0xfffffffffffffffcU) * 2) + uVar12; *param_3 = (long)pcVar15; goto LAB_001cafd6; } } else if ((((*pcVar15 == '\0') && (pcVar14[-3] == '\0')) && (pcVar14[-2] == '\0')) && (bVar4 = pcVar14[-1] - 0x30, bVar4 < 10)) { if (((pcVar14 == pcVar3) || (*pcVar14 != '\0')) || ((pcVar14[1] != '\0' || ((pcVar14[2] != '\0' || (cVar2 = pcVar14[3], 9 < (byte)(cVar2 - 0x30U))))))) { uVar10 = uVar6 * 10000000000 + uVar12 * 10 + (ulong)bVar4; *param_3 = (long)pcVar14; if (bVar7 != 0) { return uVar10; } if (uVar10 < 0x8000000000000001) { return -uVar10; } } else { *param_3 = (long)pcVar1; if ((((((pcVar1 == pcVar3) || (*pcVar1 != '\0')) || (pcVar14[5] != '\0')) || ((pcVar14[6] != '\0' || (9 < (byte)(pcVar14[7] - 0x30U))))) && (uVar6 <= uVar8)) && (((lVar13 = (ulong)(byte)(cVar2 - 0x30U) + (ulong)bVar4 * 10, uVar6 != uVar8 || (uVar12 < uVar10)) || ((uint)lVar13 <= uVar9)))) { return uVar6 * 100000000000 + lVar13 + uVar12 * 100; } } *param_4 = 0x22; return -(ulong)bVar7 | 0x8000000000000000; } uVar12 = uVar12 + uVar6 * 1000000000; *param_3 = (long)pcVar15; if (bVar7 == 0) { return -uVar12; } return uVar12; } LAB_001cafb1: *param_3 = (long)pcVar5; LAB_001cafd6: if (bVar7 == 0) { return -uVar6; } return uVar6; } } } LAB_001cae0e: *param_4 = 0x21; *param_3 = (long)param_2; return 0; }
60,832
mi_recinfo_write
eloqsql/storage/myisam/mi_open.c
uint mi_recinfo_write(File file, MI_COLUMNDEF *recinfo) { uchar buff[MI_COLUMNDEF_SIZE]; uchar *ptr=buff; mi_int2store(ptr,recinfo->type); ptr +=2; mi_int2store(ptr,recinfo->length); ptr +=2; *ptr++ = recinfo->null_bit; mi_int2store(ptr,recinfo->null_pos); ptr+= 2; return mysql_file_write(file, buff, (size_t) (ptr-buff), MYF(MY_NABP)) != 0; }
O0
c
mi_recinfo_write: pushq %rbp movq %rsp, %rbp subq $0x40, %rsp movq %fs:0x28, %rax movq %rax, -0x8(%rbp) movl %edi, -0x14(%rbp) movq %rsi, -0x20(%rbp) leaq -0xf(%rbp), %rcx movq %rcx, -0x28(%rbp) movq -0x20(%rbp), %rax movl (%rax), %eax movl %eax, -0x2c(%rbp) movb -0x2c(%rbp), %dl movq -0x28(%rbp), %rax movb %dl, 0x1(%rax) movb -0x2b(%rbp), %dl movq -0x28(%rbp), %rax movb %dl, (%rax) movq -0x28(%rbp), %rax addq $0x2, %rax movq %rax, -0x28(%rbp) movq -0x20(%rbp), %rax movzwl 0x4(%rax), %eax movl %eax, -0x30(%rbp) movb -0x30(%rbp), %dl movq -0x28(%rbp), %rax movb %dl, 0x1(%rax) movb -0x2f(%rbp), %dl movq -0x28(%rbp), %rax movb %dl, (%rax) movq -0x28(%rbp), %rax addq $0x2, %rax movq %rax, -0x28(%rbp) movq -0x20(%rbp), %rax movb 0xc(%rax), %dl movq -0x28(%rbp), %rax movq %rax, %rsi incq %rsi movq %rsi, -0x28(%rbp) movb %dl, (%rax) movq -0x20(%rbp), %rax movzwl 0xe(%rax), %eax movl %eax, -0x34(%rbp) movb -0x34(%rbp), %dl movq -0x28(%rbp), %rax movb %dl, 0x1(%rax) movb -0x33(%rbp), %dl movq -0x28(%rbp), %rax movb %dl, (%rax) movq -0x28(%rbp), %rax addq $0x2, %rax movq %rax, -0x28(%rbp) movl -0x14(%rbp), %edx movq -0x28(%rbp), %r8 subq %rcx, %r8 leaq 0x99d97(%rip), %rdi # 0x153b7f movl $0x4e3, %esi # imm = 0x4E3 movl $0x4, %r9d callq 0xb8b00 testq %rax, %rax setne %al movzbl %al, %eax movl %eax, -0x38(%rbp) movq %fs:0x28, %rax movq -0x8(%rbp), %rcx cmpq %rcx, %rax jne 0xb9e1f movl -0x38(%rbp), %eax addq $0x40, %rsp popq %rbp retq callq 0x2a270 nopw %cs:(%rax,%rax)
mi_recinfo_write: push rbp mov rbp, rsp sub rsp, 40h mov rax, fs:28h mov [rbp+var_8], rax mov [rbp+var_14], edi mov [rbp+var_20], rsi lea rcx, [rbp+var_F] mov [rbp+var_28], rcx mov rax, [rbp+var_20] mov eax, [rax] mov [rbp+var_2C], eax mov dl, byte ptr [rbp+var_2C] mov rax, [rbp+var_28] mov [rax+1], dl mov dl, byte ptr [rbp+var_2C+1] mov rax, [rbp+var_28] mov [rax], dl mov rax, [rbp+var_28] add rax, 2 mov [rbp+var_28], rax mov rax, [rbp+var_20] movzx eax, word ptr [rax+4] mov [rbp+var_30], eax mov dl, byte ptr [rbp+var_30] mov rax, [rbp+var_28] mov [rax+1], dl mov dl, byte ptr [rbp+var_30+1] mov rax, [rbp+var_28] mov [rax], dl mov rax, [rbp+var_28] add rax, 2 mov [rbp+var_28], rax mov rax, [rbp+var_20] mov dl, [rax+0Ch] mov rax, [rbp+var_28] mov rsi, rax inc rsi mov [rbp+var_28], rsi mov [rax], dl mov rax, [rbp+var_20] movzx eax, word ptr [rax+0Eh] mov [rbp+var_34], eax mov dl, byte ptr [rbp+var_34] mov rax, [rbp+var_28] mov [rax+1], dl mov dl, byte ptr [rbp+var_34+1] mov rax, [rbp+var_28] mov [rax], dl mov rax, [rbp+var_28] add rax, 2 mov [rbp+var_28], rax mov edx, [rbp+var_14] mov r8, [rbp+var_28] sub r8, rcx lea rdi, aWorkspaceLlm4b_29; "/workspace/llm4binary/github2025/eloqsq"... mov esi, 4E3h mov r9d, 4 call inline_mysql_file_write_2 test rax, rax setnz al movzx eax, al mov [rbp+var_38], eax mov rax, fs:28h mov rcx, [rbp+var_8] cmp rax, rcx jnz short loc_B9E1F mov eax, [rbp+var_38] add rsp, 40h pop rbp retn loc_B9E1F: call ___stack_chk_fail
_BOOL8 mi_recinfo_write(unsigned int a1, long long a2) { __int16 v2; // kr00_2 __int16 v3; // kr02_2 __int16 v4; // kr04_2 _BYTE v6[7]; // [rsp+31h] [rbp-Fh] BYREF unsigned long long v7; // [rsp+38h] [rbp-8h] v7 = __readfsqword(0x28u); v2 = *(_DWORD *)a2; v6[0] = HIBYTE(v2); v6[1] = v2; v3 = *(_WORD *)(a2 + 4); v6[2] = HIBYTE(v3); v6[3] = v3; v6[4] = *(_BYTE *)(a2 + 12); v4 = *(_WORD *)(a2 + 14); v6[5] = HIBYTE(v4); v6[6] = v4; return inline_mysql_file_write_2( (long long)"/workspace/llm4binary/github2025/eloqsql/storage/myisam/mi_open.c", 0x4E3u, a1, (long long)v6, 7LL, 4LL) != 0; }
mi_recinfo_write: PUSH RBP MOV RBP,RSP SUB RSP,0x40 MOV RAX,qword ptr FS:[0x28] MOV qword ptr [RBP + -0x8],RAX MOV dword ptr [RBP + -0x14],EDI MOV qword ptr [RBP + -0x20],RSI LEA RCX,[RBP + -0xf] MOV qword ptr [RBP + -0x28],RCX MOV RAX,qword ptr [RBP + -0x20] MOV EAX,dword ptr [RAX] MOV dword ptr [RBP + -0x2c],EAX MOV DL,byte ptr [RBP + -0x2c] MOV RAX,qword ptr [RBP + -0x28] MOV byte ptr [RAX + 0x1],DL MOV DL,byte ptr [RBP + -0x2b] MOV RAX,qword ptr [RBP + -0x28] MOV byte ptr [RAX],DL MOV RAX,qword ptr [RBP + -0x28] ADD RAX,0x2 MOV qword ptr [RBP + -0x28],RAX MOV RAX,qword ptr [RBP + -0x20] MOVZX EAX,word ptr [RAX + 0x4] MOV dword ptr [RBP + -0x30],EAX MOV DL,byte ptr [RBP + -0x30] MOV RAX,qword ptr [RBP + -0x28] MOV byte ptr [RAX + 0x1],DL MOV DL,byte ptr [RBP + -0x2f] MOV RAX,qword ptr [RBP + -0x28] MOV byte ptr [RAX],DL MOV RAX,qword ptr [RBP + -0x28] ADD RAX,0x2 MOV qword ptr [RBP + -0x28],RAX MOV RAX,qword ptr [RBP + -0x20] MOV DL,byte ptr [RAX + 0xc] MOV RAX,qword ptr [RBP + -0x28] MOV RSI,RAX INC RSI MOV qword ptr [RBP + -0x28],RSI MOV byte ptr [RAX],DL MOV RAX,qword ptr [RBP + -0x20] MOVZX EAX,word ptr [RAX + 0xe] MOV dword ptr [RBP + -0x34],EAX MOV DL,byte ptr [RBP + -0x34] MOV RAX,qword ptr [RBP + -0x28] MOV byte ptr [RAX + 0x1],DL MOV DL,byte ptr [RBP + -0x33] MOV RAX,qword ptr [RBP + -0x28] MOV byte ptr [RAX],DL MOV RAX,qword ptr [RBP + -0x28] ADD RAX,0x2 MOV qword ptr [RBP + -0x28],RAX MOV EDX,dword ptr [RBP + -0x14] MOV R8,qword ptr [RBP + -0x28] SUB R8,RCX LEA RDI,[0x253b7f] MOV ESI,0x4e3 MOV R9D,0x4 CALL 0x001b8b00 TEST RAX,RAX SETNZ AL MOVZX EAX,AL MOV dword ptr [RBP + -0x38],EAX MOV RAX,qword ptr FS:[0x28] MOV RCX,qword ptr [RBP + -0x8] CMP RAX,RCX JNZ 0x001b9e1f MOV EAX,dword ptr [RBP + -0x38] ADD RSP,0x40 POP RBP RET LAB_001b9e1f: CALL 0x0012a270
bool mi_recinfo_write(int4 param_1,int4 *param_2) { long lVar1; long in_FS_OFFSET; int1 local_3c; int1 uStack_3b; int1 local_38; int1 uStack_37; int1 local_34; int1 uStack_33; int1 local_17; int1 local_16; int1 local_15; int1 local_14; int1 local_13; int1 local_12; int1 local_11; long local_10; local_10 = *(long *)(in_FS_OFFSET + 0x28); local_34 = (int1)*param_2; local_16 = local_34; uStack_33 = (int1)((uint)*param_2 >> 8); local_17 = uStack_33; local_38 = (int1)*(int2 *)(param_2 + 1); local_14 = local_38; uStack_37 = (int1)((ushort)*(int2 *)(param_2 + 1) >> 8); local_15 = uStack_37; local_13 = *(int1 *)(param_2 + 3); local_3c = (int1)*(int2 *)((long)param_2 + 0xe); local_11 = local_3c; uStack_3b = (int1)((ushort)*(int2 *)((long)param_2 + 0xe) >> 8); local_12 = uStack_3b; lVar1 = inline_mysql_file_write ("/workspace/llm4binary/github2025/eloqsql/storage/myisam/mi_open.c",0x4e3, param_1,&local_17,(long)&local_10 - (long)&local_17,4); if (*(long *)(in_FS_OFFSET + 0x28) == local_10) { return lVar1 != 0; } /* WARNING: Subroutine does not return */ __stack_chk_fail(); }
60,833
my_dir
eloqsql/mysys/my_lib.c
MY_DIR *my_dir(const char *path, myf MyFlags) { MY_DIR_HANDLE *dirh; FILEINFO finfo; DIR *dirp; struct dirent *dp; char tmp_path[FN_REFLEN + 2], *tmp_file; char dirent_tmp[sizeof(struct dirent)+_POSIX_PATH_MAX+1]; DBUG_ENTER("my_dir"); DBUG_PRINT("my",("path: '%s' MyFlags: %lu",path,MyFlags)); tmp_file= directory_file_name(tmp_path, path); if (!(dirp= opendir(tmp_path))) { my_errno= errno; goto err_open; } if (!(dirh= my_malloc(key_memory_MY_DIR, sizeof(*dirh), MYF(MyFlags | MY_ZEROFILL)))) goto err_alloc; if (my_init_dynamic_array(key_memory_MY_DIR, &dirh->array, sizeof(FILEINFO), ENTRIES_START_SIZE, ENTRIES_INCREMENT, MYF(MyFlags))) goto error; init_alloc_root(key_memory_MY_DIR, &dirh->root, NAMES_START_SIZE, NAMES_START_SIZE, MYF(MyFlags)); dp= (struct dirent*) dirent_tmp; while (!(READDIR(dirp,(struct dirent*) dirent_tmp,dp))) { MY_STAT statbuf, *mystat= 0; if (dp->d_name[0] == '.' && (dp->d_name[1] == '\0' || (dp->d_name[1] == '.' && dp->d_name[2] == '\0'))) continue; /* . or .. */ if (MyFlags & MY_WANT_STAT) { mystat= &statbuf; bzero(mystat, sizeof(*mystat)); (void) strmov(tmp_file, dp->d_name); (void) my_stat(tmp_path, mystat, MyFlags); if (!(mystat->st_mode & MY_S_IREAD)) continue; } if (!(finfo.name= strdup_root(&dirh->root, dp->d_name))) goto error; if (mystat && !((mystat= memdup_root(&dirh->root, mystat, sizeof(*mystat))))) goto error; finfo.mystat= mystat; if (push_dynamic(&dirh->array, (uchar*)&finfo)) goto error; } (void) closedir(dirp); if (MyFlags & MY_WANT_SORT) sort_dynamic(&dirh->array, (qsort_cmp) comp_names); dirh->dir.dir_entry= dynamic_element(&dirh->array, 0, FILEINFO *); dirh->dir.number_of_files= dirh->array.elements; DBUG_RETURN(&dirh->dir); error: my_dirend(&dirh->dir); err_alloc: (void) closedir(dirp); err_open: if (MyFlags & (MY_FAE | MY_WME)) my_error(EE_DIR, MYF(ME_BELL), path, my_errno); DBUG_RETURN(NULL); }
O0
c
my_dir: pushq %rbp movq %rsp, %rbp subq $0x530, %rsp # imm = 0x530 movq %fs:0x28, %rax movq %rax, -0x8(%rbp) movq %rdi, -0x440(%rbp) movq %rsi, -0x448(%rbp) jmp 0x2ea18 leaq -0x210(%rbp), %rdi movq -0x440(%rbp), %rsi callq 0x2edc0 movq %rax, -0x478(%rbp) leaq -0x210(%rbp), %rdi callq 0x24470 movq %rax, -0x468(%rbp) cmpq $0x0, %rax jne 0x2ea6a callq 0x24050 movl (%rax), %eax movl %eax, -0x514(%rbp) callq 0x26720 movl -0x514(%rbp), %ecx movl %ecx, (%rax) jmp 0x2ed3b leaq 0x356913(%rip), %rax # 0x385384 movl (%rax), %edi movq -0x448(%rbp), %rdx orq $0x20, %rdx movl $0x78, %esi callq 0x2efd0 movq %rax, -0x450(%rbp) cmpq $0x0, %rax jne 0x2ea9a jmp 0x2ed2f leaq 0x3568e3(%rip), %rax # 0x385384 movl (%rax), %edi movq -0x450(%rbp), %rsi addq $0x10, %rsi movq -0x448(%rbp), %rax movl $0x10, %edx xorl %ecx, %ecx movl $0x200, %r8d # imm = 0x200 movl $0x1000, %r9d # imm = 0x1000 movq %rax, (%rsp) callq 0x30430 cmpb $0x0, %al je 0x2eada jmp 0x2ed23 leaq 0x3568a3(%rip), %rax # 0x385384 movl (%rax), %edi movq -0x450(%rbp), %rsi addq $0x38, %rsi movq -0x448(%rbp), %r8 movl $0x8000, %ecx # imm = 0x8000 movq %rcx, %rdx callq 0x33270 leaq -0x430(%rbp), %rax movq %rax, -0x470(%rbp) movq -0x468(%rbp), %rdi callq 0x241c0 movq %rax, -0x470(%rbp) cmpq $0x0, %rax setne %al xorb $-0x1, %al xorb $-0x1, %al testb $0x1, %al jne 0x2eb37 jmp 0x2ec9c movq $0x0, -0x510(%rbp) movq -0x470(%rbp), %rax movsbl 0x13(%rax), %eax cmpl $0x2e, %eax jne 0x2eb84 movq -0x470(%rbp), %rax movsbl 0x14(%rax), %eax cmpl $0x0, %eax je 0x2eb82 movq -0x470(%rbp), %rax movsbl 0x14(%rax), %eax cmpl $0x2e, %eax jne 0x2eb84 movq -0x470(%rbp), %rax movsbl 0x15(%rax), %eax cmpl $0x0, %eax jne 0x2eb84 jmp 0x2eb10 movq -0x448(%rbp), %rax andq $0x4000, %rax # imm = 0x4000 cmpq $0x0, %rax je 0x2ec04 leaq -0x508(%rbp), %rax movq %rax, -0x510(%rbp) movq -0x510(%rbp), %rdi xorl %esi, %esi movl $0x90, %edx callq 0x24190 movq -0x478(%rbp), %rdi movq -0x470(%rbp), %rsi addq $0x13, %rsi callq 0x242b0 leaq -0x210(%rbp), %rdi movq -0x510(%rbp), %rsi movq -0x448(%rbp), %rdx callq 0x2ee30 movq -0x510(%rbp), %rax movl 0x18(%rax), %eax andl $0x100, %eax # imm = 0x100 cmpl $0x0, %eax jne 0x2ec02 jmp 0x2eb10 jmp 0x2ec04 movq -0x450(%rbp), %rdi addq $0x38, %rdi movq -0x470(%rbp), %rsi addq $0x13, %rsi callq 0x33da0 movq %rax, -0x460(%rbp) cmpq $0x0, %rax jne 0x2ec31 jmp 0x2ed23 cmpq $0x0, -0x510(%rbp) je 0x2ec69 movq -0x450(%rbp), %rdi addq $0x38, %rdi movq -0x510(%rbp), %rsi movl $0x90, %edx callq 0x33e40 movq %rax, -0x510(%rbp) cmpq $0x0, %rax jne 0x2ec69 jmp 0x2ed23 movq -0x510(%rbp), %rax movq %rax, -0x458(%rbp) movq -0x450(%rbp), %rdi addq $0x10, %rdi leaq -0x460(%rbp), %rsi callq 0x30560 cmpb $0x0, %al je 0x2ec97 jmp 0x2ed23 jmp 0x2eb10 movq -0x468(%rbp), %rdi callq 0x244d0 movq -0x448(%rbp), %rax andq $0x2000, %rax # imm = 0x2000 cmpq $0x0, %rax je 0x2ecea movq -0x450(%rbp), %rax movq 0x10(%rax), %rdi movq -0x450(%rbp), %rax movl 0x18(%rax), %eax movl %eax, %esi movq -0x450(%rbp), %rax movl 0x24(%rax), %eax movl %eax, %edx leaq 0x23b(%rip), %rcx # 0x2ef20 callq 0x318a0 movq -0x450(%rbp), %rax movq 0x10(%rax), %rcx movq -0x450(%rbp), %rax movq %rcx, (%rax) movq -0x450(%rbp), %rax movl 0x18(%rax), %ecx movq -0x450(%rbp), %rax movl %ecx, 0x8(%rax) movq -0x450(%rbp), %rax movq %rax, -0x438(%rbp) jmp 0x2ed86 movq -0x450(%rbp), %rdi callq 0x2e9a0 movq -0x468(%rbp), %rdi callq 0x244d0 movq -0x448(%rbp), %rax andq $0x18, %rax cmpq $0x0, %rax je 0x2ed79 movq -0x440(%rbp), %rax movq %rax, -0x520(%rbp) callq 0x26720 movq -0x520(%rbp), %rdx movl (%rax), %ecx movl $0xc, %edi movl $0x4, %esi movb $0x0, %al callq 0x2e060 jmp 0x2ed7b movq $0x0, -0x438(%rbp) movq -0x438(%rbp), %rax movq %rax, -0x528(%rbp) movq %fs:0x28, %rax movq -0x8(%rbp), %rcx cmpq %rcx, %rax jne 0x2edb6 movq -0x528(%rbp), %rax addq $0x530, %rsp # imm = 0x530 popq %rbp retq callq 0x242e0 nopl (%rax,%rax)
my_dir: push rbp mov rbp, rsp sub rsp, 530h mov rax, fs:28h mov [rbp+var_8], rax mov [rbp+var_440], rdi mov [rbp+var_448], rsi jmp short $+2 loc_2EA18: lea rdi, [rbp+var_210] mov rsi, [rbp+var_440] call directory_file_name mov [rbp+var_478], rax lea rdi, [rbp+var_210] call _opendir mov [rbp+var_468], rax cmp rax, 0 jnz short loc_2EA6A call ___errno_location mov eax, [rax] mov [rbp+var_514], eax call _my_thread_var mov ecx, [rbp+var_514] mov [rax], ecx jmp loc_2ED3B loc_2EA6A: lea rax, key_memory_MY_DIR mov edi, [rax] mov rdx, [rbp+var_448] or rdx, 20h mov esi, 78h ; 'x' call my_malloc mov [rbp+var_450], rax cmp rax, 0 jnz short loc_2EA9A jmp loc_2ED2F loc_2EA9A: lea rax, key_memory_MY_DIR mov edi, [rax] mov rsi, [rbp+var_450] add rsi, 10h mov rax, [rbp+var_448] mov edx, 10h xor ecx, ecx mov r8d, 200h mov r9d, 1000h mov [rsp+530h+var_530], rax call init_dynamic_array2 cmp al, 0 jz short loc_2EADA jmp loc_2ED23 loc_2EADA: lea rax, key_memory_MY_DIR mov edi, [rax] mov rsi, [rbp+var_450] add rsi, 38h ; '8' mov r8, [rbp+var_448] mov ecx, 8000h mov rdx, rcx call init_alloc_root lea rax, [rbp+var_430] mov [rbp+var_470], rax loc_2EB10: mov rdi, [rbp+var_468] call _readdir64 mov [rbp+var_470], rax cmp rax, 0 setnz al xor al, 0FFh xor al, 0FFh test al, 1 jnz short loc_2EB37 jmp loc_2EC9C loc_2EB37: mov [rbp+var_510], 0 mov rax, [rbp+var_470] movsx eax, byte ptr [rax+13h] cmp eax, 2Eh ; '.' jnz short loc_2EB84 mov rax, [rbp+var_470] movsx eax, byte ptr [rax+14h] cmp eax, 0 jz short loc_2EB82 mov rax, [rbp+var_470] movsx eax, byte ptr [rax+14h] cmp eax, 2Eh ; '.' jnz short loc_2EB84 mov rax, [rbp+var_470] movsx eax, byte ptr [rax+15h] cmp eax, 0 jnz short loc_2EB84 loc_2EB82: jmp short loc_2EB10 loc_2EB84: mov rax, [rbp+var_448] and rax, 4000h cmp rax, 0 jz short loc_2EC04 lea rax, [rbp+var_508] mov [rbp+var_510], rax mov rdi, [rbp+var_510] xor esi, esi mov edx, 90h call _memset mov rdi, [rbp+var_478] mov rsi, [rbp+var_470] add rsi, 13h call _stpcpy lea rdi, [rbp+var_210] mov rsi, [rbp+var_510] mov rdx, [rbp+var_448] call my_stat mov rax, [rbp+var_510] mov eax, [rax+18h] and eax, 100h cmp eax, 0 jnz short loc_2EC02 jmp loc_2EB10 loc_2EC02: jmp short $+2 loc_2EC04: mov rdi, [rbp+var_450] add rdi, 38h ; '8' mov rsi, [rbp+var_470] add rsi, 13h call strdup_root mov [rbp+var_460], rax cmp rax, 0 jnz short loc_2EC31 jmp loc_2ED23 loc_2EC31: cmp [rbp+var_510], 0 jz short loc_2EC69 mov rdi, [rbp+var_450] add rdi, 38h ; '8' mov rsi, [rbp+var_510] mov edx, 90h call memdup_root mov [rbp+var_510], rax cmp rax, 0 jnz short loc_2EC69 jmp loc_2ED23 loc_2EC69: mov rax, [rbp+var_510] mov [rbp+var_458], rax mov rdi, [rbp+var_450] add rdi, 10h lea rsi, [rbp+var_460] call insert_dynamic cmp al, 0 jz short loc_2EC97 jmp loc_2ED23 loc_2EC97: jmp loc_2EB10 loc_2EC9C: mov rdi, [rbp+var_468] call _closedir mov rax, [rbp+var_448] and rax, 2000h cmp rax, 0 jz short loc_2ECEA mov rax, [rbp+var_450] mov rdi, [rax+10h] mov rax, [rbp+var_450] mov eax, [rax+18h] mov esi, eax mov rax, [rbp+var_450] mov eax, [rax+24h] mov edx, eax lea rcx, comp_names call my_qsort loc_2ECEA: mov rax, [rbp+var_450] mov rcx, [rax+10h] mov rax, [rbp+var_450] mov [rax], rcx mov rax, [rbp+var_450] mov ecx, [rax+18h] mov rax, [rbp+var_450] mov [rax+8], ecx mov rax, [rbp+var_450] mov [rbp+var_438], rax jmp short loc_2ED86 loc_2ED23: mov rdi, [rbp+var_450] call my_dirend loc_2ED2F: mov rdi, [rbp+var_468] call _closedir loc_2ED3B: mov rax, [rbp+var_448] and rax, 18h cmp rax, 0 jz short loc_2ED79 mov rax, [rbp+var_440] mov [rbp+var_520], rax call _my_thread_var mov rdx, [rbp+var_520] mov ecx, [rax] mov edi, 0Ch mov esi, 4 mov al, 0 call my_error loc_2ED79: jmp short $+2 loc_2ED7B: mov [rbp+var_438], 0 loc_2ED86: mov rax, [rbp+var_438] mov [rbp+var_528], rax mov rax, fs:28h mov rcx, [rbp+var_8] cmp rax, rcx jnz short loc_2EDB6 mov rax, [rbp+var_528] add rsp, 530h pop rbp retn loc_2EDB6: call ___stack_chk_fail
long long my_dir(long long a1, long long a2) { unsigned int *v2; // rax long long v4; // [rsp+10h] [rbp-520h] int v5; // [rsp+1Ch] [rbp-514h] _BYTE *v6; // [rsp+20h] [rbp-510h] _BYTE v7[24]; // [rsp+28h] [rbp-508h] BYREF __int16 v8; // [rsp+40h] [rbp-4F0h] long long v9; // [rsp+B8h] [rbp-478h] char *v10; // [rsp+C0h] [rbp-470h] long long v11; // [rsp+C8h] [rbp-468h] _QWORD v12[2]; // [rsp+D0h] [rbp-460h] BYREF long long v13; // [rsp+E0h] [rbp-450h] long long v14; // [rsp+E8h] [rbp-448h] long long v15; // [rsp+F0h] [rbp-440h] char v17; // [rsp+100h] [rbp-430h] BYREF _BYTE v18[520]; // [rsp+320h] [rbp-210h] BYREF unsigned long long v19; // [rsp+528h] [rbp-8h] v19 = __readfsqword(0x28u); v15 = a1; v14 = a2; v9 = directory_file_name(v18, a1); v11 = opendir(v18); if ( !v11 ) { v5 = *(_DWORD *)__errno_location(); *(_DWORD *)my_thread_var() = v5; LABEL_24: if ( (v14 & 0x18) != 0 ) { v4 = v15; v2 = (unsigned int *)my_thread_var(); my_error(0xCu, 4LL, v4, *v2); } return 0LL; } v13 = my_malloc(key_memory_MY_DIR, 120LL, v14 | 0x20); if ( !v13 ) { LABEL_23: closedir(v11); goto LABEL_24; } if ( (unsigned __int8)init_dynamic_array2(key_memory_MY_DIR, (int)v13 + 16, 16, 0, 512, 4096, v14) ) { LABEL_22: my_dirend(v13); goto LABEL_23; } init_alloc_root(key_memory_MY_DIR, v13 + 56, 0x8000LL, 0x8000LL, v14); v10 = &v17; while ( 1 ) { v10 = (char *)readdir64(v11); if ( !v10 ) break; v6 = 0LL; if ( v10[19] != 46 || v10[20] && (v10[20] != 46 || v10[21]) ) { if ( (v14 & 0x4000) == 0 || (v6 = v7, memset(v7, 0LL, 144LL), stpcpy(v9, v10 + 19), my_stat(v18, v7, v14), (v8 & 0x100) != 0) ) { v12[0] = strdup_root(v13 + 56, v10 + 19); if ( !v12[0] ) goto LABEL_22; if ( v6 ) { v6 = (_BYTE *)memdup_root(v13 + 56, v6, 144LL); if ( !v6 ) goto LABEL_22; } v12[1] = v6; if ( (unsigned __int8)insert_dynamic(v13 + 16, v12) ) goto LABEL_22; } } } closedir(v11); if ( (v14 & 0x2000) != 0 ) my_qsort(*(_QWORD *)(v13 + 16), *(unsigned int *)(v13 + 24), *(unsigned int *)(v13 + 36), comp_names); *(_QWORD *)v13 = *(_QWORD *)(v13 + 16); *(_DWORD *)(v13 + 8) = *(_DWORD *)(v13 + 24); return v13; }
my_dir: PUSH RBP MOV RBP,RSP SUB RSP,0x530 MOV RAX,qword ptr FS:[0x28] MOV qword ptr [RBP + -0x8],RAX MOV qword ptr [RBP + -0x440],RDI MOV qword ptr [RBP + -0x448],RSI JMP 0x0012ea18 LAB_0012ea18: LEA RDI,[RBP + -0x210] MOV RSI,qword ptr [RBP + -0x440] CALL 0x0012edc0 MOV qword ptr [RBP + -0x478],RAX LEA RDI,[RBP + -0x210] CALL 0x00124470 MOV qword ptr [RBP + -0x468],RAX CMP RAX,0x0 JNZ 0x0012ea6a CALL 0x00124050 MOV EAX,dword ptr [RAX] MOV dword ptr [RBP + -0x514],EAX CALL 0x00126720 MOV ECX,dword ptr [RBP + -0x514] MOV dword ptr [RAX],ECX JMP 0x0012ed3b LAB_0012ea6a: LEA RAX,[0x485384] MOV EDI,dword ptr [RAX] MOV RDX,qword ptr [RBP + -0x448] OR RDX,0x20 MOV ESI,0x78 CALL 0x0012efd0 MOV qword ptr [RBP + -0x450],RAX CMP RAX,0x0 JNZ 0x0012ea9a JMP 0x0012ed2f LAB_0012ea9a: LEA RAX,[0x485384] MOV EDI,dword ptr [RAX] MOV RSI,qword ptr [RBP + -0x450] ADD RSI,0x10 MOV RAX,qword ptr [RBP + -0x448] MOV EDX,0x10 XOR ECX,ECX MOV R8D,0x200 MOV R9D,0x1000 MOV qword ptr [RSP],RAX CALL 0x00130430 CMP AL,0x0 JZ 0x0012eada JMP 0x0012ed23 LAB_0012eada: LEA RAX,[0x485384] MOV EDI,dword ptr [RAX] MOV RSI,qword ptr [RBP + -0x450] ADD RSI,0x38 MOV R8,qword ptr [RBP + -0x448] MOV ECX,0x8000 MOV RDX,RCX CALL 0x00133270 LEA RAX,[RBP + -0x430] MOV qword ptr [RBP + -0x470],RAX LAB_0012eb10: MOV RDI,qword ptr [RBP + -0x468] CALL 0x001241c0 MOV qword ptr [RBP + -0x470],RAX CMP RAX,0x0 SETNZ AL XOR AL,0xff XOR AL,0xff TEST AL,0x1 JNZ 0x0012eb37 JMP 0x0012ec9c LAB_0012eb37: MOV qword ptr [RBP + -0x510],0x0 MOV RAX,qword ptr [RBP + -0x470] MOVSX EAX,byte ptr [RAX + 0x13] CMP EAX,0x2e JNZ 0x0012eb84 MOV RAX,qword ptr [RBP + -0x470] MOVSX EAX,byte ptr [RAX + 0x14] CMP EAX,0x0 JZ 0x0012eb82 MOV RAX,qword ptr [RBP + -0x470] MOVSX EAX,byte ptr [RAX + 0x14] CMP EAX,0x2e JNZ 0x0012eb84 MOV RAX,qword ptr [RBP + -0x470] MOVSX EAX,byte ptr [RAX + 0x15] CMP EAX,0x0 JNZ 0x0012eb84 LAB_0012eb82: JMP 0x0012eb10 LAB_0012eb84: MOV RAX,qword ptr [RBP + -0x448] AND RAX,0x4000 CMP RAX,0x0 JZ 0x0012ec04 LEA RAX,[RBP + -0x508] MOV qword ptr [RBP + -0x510],RAX MOV RDI,qword ptr [RBP + -0x510] XOR ESI,ESI MOV EDX,0x90 CALL 0x00124190 MOV RDI,qword ptr [RBP + -0x478] MOV RSI,qword ptr [RBP + -0x470] ADD RSI,0x13 CALL 0x001242b0 LEA RDI,[RBP + -0x210] MOV RSI,qword ptr [RBP + -0x510] MOV RDX,qword ptr [RBP + -0x448] CALL 0x0012ee30 MOV RAX,qword ptr [RBP + -0x510] MOV EAX,dword ptr [RAX + 0x18] AND EAX,0x100 CMP EAX,0x0 JNZ 0x0012ec02 JMP 0x0012eb10 LAB_0012ec02: JMP 0x0012ec04 LAB_0012ec04: MOV RDI,qword ptr [RBP + -0x450] ADD RDI,0x38 MOV RSI,qword ptr [RBP + -0x470] ADD RSI,0x13 CALL 0x00133da0 MOV qword ptr [RBP + -0x460],RAX CMP RAX,0x0 JNZ 0x0012ec31 JMP 0x0012ed23 LAB_0012ec31: CMP qword ptr [RBP + -0x510],0x0 JZ 0x0012ec69 MOV RDI,qword ptr [RBP + -0x450] ADD RDI,0x38 MOV RSI,qword ptr [RBP + -0x510] MOV EDX,0x90 CALL 0x00133e40 MOV qword ptr [RBP + -0x510],RAX CMP RAX,0x0 JNZ 0x0012ec69 JMP 0x0012ed23 LAB_0012ec69: MOV RAX,qword ptr [RBP + -0x510] MOV qword ptr [RBP + -0x458],RAX MOV RDI,qword ptr [RBP + -0x450] ADD RDI,0x10 LEA RSI,[RBP + -0x460] CALL 0x00130560 CMP AL,0x0 JZ 0x0012ec97 JMP 0x0012ed23 LAB_0012ec97: JMP 0x0012eb10 LAB_0012ec9c: MOV RDI,qword ptr [RBP + -0x468] CALL 0x001244d0 MOV RAX,qword ptr [RBP + -0x448] AND RAX,0x2000 CMP RAX,0x0 JZ 0x0012ecea MOV RAX,qword ptr [RBP + -0x450] MOV RDI,qword ptr [RAX + 0x10] MOV RAX,qword ptr [RBP + -0x450] MOV EAX,dword ptr [RAX + 0x18] MOV ESI,EAX MOV RAX,qword ptr [RBP + -0x450] MOV EAX,dword ptr [RAX + 0x24] MOV EDX,EAX LEA RCX,[0x12ef20] CALL 0x001318a0 LAB_0012ecea: MOV RAX,qword ptr [RBP + -0x450] MOV RCX,qword ptr [RAX + 0x10] MOV RAX,qword ptr [RBP + -0x450] MOV qword ptr [RAX],RCX MOV RAX,qword ptr [RBP + -0x450] MOV ECX,dword ptr [RAX + 0x18] MOV RAX,qword ptr [RBP + -0x450] MOV dword ptr [RAX + 0x8],ECX MOV RAX,qword ptr [RBP + -0x450] MOV qword ptr [RBP + -0x438],RAX JMP 0x0012ed86 LAB_0012ed23: MOV RDI,qword ptr [RBP + -0x450] CALL 0x0012e9a0 LAB_0012ed2f: MOV RDI,qword ptr [RBP + -0x468] CALL 0x001244d0 LAB_0012ed3b: MOV RAX,qword ptr [RBP + -0x448] AND RAX,0x18 CMP RAX,0x0 JZ 0x0012ed79 MOV RAX,qword ptr [RBP + -0x440] MOV qword ptr [RBP + -0x520],RAX CALL 0x00126720 MOV RDX,qword ptr [RBP + -0x520] MOV ECX,dword ptr [RAX] MOV EDI,0xc MOV ESI,0x4 MOV AL,0x0 CALL 0x0012e060 LAB_0012ed79: JMP 0x0012ed7b LAB_0012ed7b: MOV qword ptr [RBP + -0x438],0x0 LAB_0012ed86: MOV RAX,qword ptr [RBP + -0x438] MOV qword ptr [RBP + -0x528],RAX MOV RAX,qword ptr FS:[0x28] MOV RCX,qword ptr [RBP + -0x8] CMP RAX,RCX JNZ 0x0012edb6 MOV RAX,qword ptr [RBP + -0x528] ADD RSP,0x530 POP RBP RET LAB_0012edb6: CALL 0x001242e0
int8 * my_dir(int8 param_1,ulong param_2) { int iVar1; int8 uVar2; char cVar3; int *piVar4; int4 *puVar5; long in_FS_OFFSET; int1 *local_518; int1 local_510 [24]; uint local_4f8; char *local_480; dirent64 *local_478; DIR *local_470; long local_468; int1 *local_460; int8 *local_458; ulong local_450; int8 local_448; int8 *local_440; dirent64 local_438; char local_218 [520]; long local_10; local_10 = *(long *)(in_FS_OFFSET + 0x28); local_450 = param_2; local_448 = param_1; local_480 = (char *)directory_file_name(local_218,param_1); local_470 = opendir(local_218); if (local_470 == (DIR *)0x0) { piVar4 = __errno_location(); iVar1 = *piVar4; piVar4 = (int *)_my_thread_var(); *piVar4 = iVar1; } else { local_458 = (int8 *)my_malloc(key_memory_MY_DIR,0x78,local_450 | 0x20); if (local_458 != (int8 *)0x0) { cVar3 = init_dynamic_array2(key_memory_MY_DIR,local_458 + 2,0x10,0,0x200,0x1000,local_450); if (cVar3 == '\0') { init_alloc_root(key_memory_MY_DIR,local_458 + 7,0x8000,0x8000,local_450); local_478 = &local_438; LAB_0012eb10: do { do { local_478 = readdir64(local_470); if (local_478 == (dirent64 *)0x0) { closedir(local_470); if ((local_450 & 0x2000) != 0) { my_qsort(local_458[2],*(int4 *)(local_458 + 3), *(int4 *)((long)local_458 + 0x24),comp_names); } *local_458 = local_458[2]; *(int4 *)(local_458 + 1) = *(int4 *)(local_458 + 3); local_440 = local_458; goto LAB_0012ed86; } local_518 = (int1 *)0x0; } while ((local_478->d_name[0] == '.') && ((local_478->d_name[1] == '\0' || ((local_478->d_name[1] == '.' && (local_478->d_name[2] == '\0')))))); if ((local_450 & 0x4000) != 0) { local_518 = local_510; memset(local_518,0,0x90); stpcpy(local_480,local_478->d_name); my_stat(local_218,local_518,local_450); if ((local_4f8 & 0x100) == 0) goto LAB_0012eb10; } local_468 = strdup_root(local_458 + 7,local_478->d_name); if ((local_468 == 0) || ((local_518 != (int1 *)0x0 && (local_518 = (int1 *)memdup_root(local_458 + 7,local_518,0x90), local_518 == (int1 *)0x0)))) break; local_460 = local_518; cVar3 = insert_dynamic(local_458 + 2); if (cVar3 != '\0') break; } while( true ); } my_dirend(local_458); } closedir(local_470); } uVar2 = local_448; if ((local_450 & 0x18) != 0) { puVar5 = (int4 *)_my_thread_var(); my_error(0xc,4,uVar2,*puVar5); } local_440 = (int8 *)0x0; LAB_0012ed86: if (*(long *)(in_FS_OFFSET + 0x28) != local_10) { /* WARNING: Subroutine does not return */ __stack_chk_fail(); } return local_440; }
60,834
my_mb_wc_euc_kr
eloqsql/strings/ctype-euc_kr.c
static int my_mb_wc_euc_kr(CHARSET_INFO *cs __attribute__((unused)), my_wc_t *pwc, const uchar *s, const uchar *e) { int hi; if (s >= e) return MY_CS_TOOSMALL; if ((hi= s[0]) < 0x80) { pwc[0]=hi; return 1; } if (s+2>e) return MY_CS_TOOSMALL2; if (!IS_MB2_CHAR(hi, s[1])) return MY_CS_ILSEQ; if (!(pwc[0]=func_ksc5601_uni_onechar((hi<<8)+s[1]))) return -2; return 2; }
O3
c
my_mb_wc_euc_kr: movl $0xffffff9b, %eax # imm = 0xFFFFFF9B cmpq %rcx, %rdx jae 0x314a9 movsbq (%rdx), %rdi testq %rdi, %rdi js 0x31468 movq %rdi, (%rsi) movl $0x1, %eax retq leaq 0x2(%rdx), %r8 movl $0xffffff9a, %eax # imm = 0xFFFFFF9A cmpq %rcx, %r8 ja 0x314a9 movzbl %dil, %ecx xorl %eax, %eax cmpl $0x80, %ecx je 0x314a9 cmpl $0xff, %ecx je 0x314a9 movzbl 0x1(%rdx), %edx leal 0x1(%rdx), %edi cmpb $-0x7f, %dil ja 0x314aa movl %edx, %edi andb $-0x21, %dil addb $-0x5b, %dil cmpb $-0x1a, %dil jae 0x314aa retq pushq %rbp movq %rsp, %rbp shll $0x8, %ecx leal (%rcx,%rdx), %eax addl $0xffff7ebf, %eax # imm = 0xFFFF7EBF cmpl $0x47bd, %eax # imm = 0x47BD ja 0x314cb movl %eax, %eax leaq 0x865a7(%rip), %rcx # 0xb7a70 jmp 0x314e4 orl %edx, %ecx addl $0xffff355f, %ecx # imm = 0xFFFF355F cmpl $0x335e, %ecx # imm = 0x335E jae 0x314fd movl %ecx, %eax leaq 0x8f50c(%rip), %rcx # 0xc09f0 leaq (%rcx,%rax,2), %rax movzwl (%rax), %eax movzwl %ax, %ecx movq %rcx, (%rsi) movl $0x2, %eax testw %cx, %cx jne 0x31509 jmp 0x31504 movq $0x0, (%rsi) movl $0xfffffffe, %eax # imm = 0xFFFFFFFE popq %rbp retq
my_mb_wc_euc_kr: mov eax, 0FFFFFF9Bh cmp rdx, rcx jnb short locret_314A9 movsx rdi, byte ptr [rdx] test rdi, rdi js short loc_31468 mov [rsi], rdi mov eax, 1 retn loc_31468: lea r8, [rdx+2] mov eax, 0FFFFFF9Ah cmp r8, rcx ja short locret_314A9 movzx ecx, dil xor eax, eax cmp ecx, 80h jz short locret_314A9 cmp ecx, 0FFh jz short locret_314A9 movzx edx, byte ptr [rdx+1] lea edi, [rdx+1] cmp dil, 81h ja short loc_314AA mov edi, edx and dil, 0DFh add dil, 0A5h cmp dil, 0E6h jnb short loc_314AA locret_314A9: retn loc_314AA: push rbp mov rbp, rsp shl ecx, 8 lea eax, [rcx+rdx] add eax, 0FFFF7EBFh cmp eax, 47BDh ja short loc_314CB mov eax, eax lea rcx, tab_ksc5601_uni0 jmp short loc_314E4 loc_314CB: or ecx, edx add ecx, 0FFFF355Fh cmp ecx, 335Eh jnb short loc_314FD mov eax, ecx lea rcx, tab_ksc5601_uni1 loc_314E4: lea rax, [rcx+rax*2] movzx eax, word ptr [rax] movzx ecx, ax mov [rsi], rcx mov eax, 2 test cx, cx jnz short loc_31509 jmp short loc_31504 loc_314FD: mov qword ptr [rsi], 0 loc_31504: mov eax, 0FFFFFFFEh loc_31509: pop rbp retn
long long my_mb_wc_euc_kr(long long a1, long long *a2, char *a3, unsigned long long a4) { long long result; // rax long long v5; // rdi int v6; // edx int v7; // ecx long long v8; // rax unsigned __int16 *v9; // rcx unsigned int v10; // ecx long long v11; // rcx result = 4294967195LL; if ( (unsigned long long)a3 < a4 ) { v5 = *a3; if ( v5 >= 0 ) { *a2 = v5; return 1LL; } result = 4294967194LL; if ( (unsigned long long)(a3 + 2) <= a4 ) { result = 0LL; if ( (unsigned __int8)v5 != 128 && (unsigned __int8)v5 != 255 ) { v6 = (unsigned __int8)a3[1]; if ( (unsigned __int8)(v6 + 1) > 0x81u || (unsigned __int8)((v6 & 0xDF) - 91) >= 0xE6u ) { v7 = (unsigned __int8)v5 << 8; LODWORD(v8) = v7 + v6 - 33089; if ( (unsigned int)v8 > 0x47BD ) { v10 = (v6 | v7) - 51873; if ( v10 >= 0x335E ) { *a2 = 0LL; return 4294967294LL; } v8 = v10; v9 = (unsigned __int16 *)&tab_ksc5601_uni1; } else { v8 = (unsigned int)v8; v9 = (unsigned __int16 *)&tab_ksc5601_uni0; } v11 = v9[v8]; *a2 = v11; result = 2LL; if ( (_WORD)v11 ) return result; return 4294967294LL; } } } } return result; }
my_mb_wc_euc_kr: MOV EAX,0xffffff9b CMP RDX,RCX JNC 0x001314a9 MOVSX RDI,byte ptr [RDX] TEST RDI,RDI JS 0x00131468 MOV qword ptr [RSI],RDI MOV EAX,0x1 RET LAB_00131468: LEA R8,[RDX + 0x2] MOV EAX,0xffffff9a CMP R8,RCX JA 0x001314a9 MOVZX ECX,DIL XOR EAX,EAX CMP ECX,0x80 JZ 0x001314a9 CMP ECX,0xff JZ 0x001314a9 MOVZX EDX,byte ptr [RDX + 0x1] LEA EDI,[RDX + 0x1] CMP DIL,0x81 JA 0x001314aa MOV EDI,EDX AND DIL,0xdf ADD DIL,0xa5 CMP DIL,0xe6 JNC 0x001314aa LAB_001314a9: RET LAB_001314aa: PUSH RBP MOV RBP,RSP SHL ECX,0x8 LEA EAX,[RCX + RDX*0x1] ADD EAX,0xffff7ebf CMP EAX,0x47bd JA 0x001314cb MOV EAX,EAX LEA RCX,[0x1b7a70] JMP 0x001314e4 LAB_001314cb: OR ECX,EDX ADD ECX,0xffff355f CMP ECX,0x335e JNC 0x001314fd MOV EAX,ECX LEA RCX,[0x1c09f0] LAB_001314e4: LEA RAX,[RCX + RAX*0x2] MOVZX EAX,word ptr [RAX] MOVZX ECX,AX MOV qword ptr [RSI],RCX MOV EAX,0x2 TEST CX,CX JNZ 0x00131509 JMP 0x00131504 LAB_001314fd: MOV qword ptr [RSI],0x0 LAB_00131504: MOV EAX,0xfffffffe LAB_00131509: POP RBP RET
int8 my_mb_wc_euc_kr(int8 param_1,ulong *param_2,byte *param_3,byte *param_4) { byte bVar1; byte bVar2; ushort uVar3; uint uVar4; int1 *puVar5; if (param_4 <= param_3) { return 0xffffff9b; } bVar1 = *param_3; if (-1 < (long)(char)bVar1) { *param_2 = (long)(char)bVar1; return 1; } if (param_4 < param_3 + 2) { return 0xffffff9a; } if (bVar1 == 0x80) { return 0; } if (bVar1 == 0xff) { return 0; } bVar2 = param_3[1]; if (((byte)(bVar2 + 1) < 0x82) && ((byte)((bVar2 & 0xdf) + 0xa5) < 0xe6)) { return 0; } uVar4 = ((uint)bVar1 * 0x100 + (uint)bVar2) - 0x8141; if (uVar4 < 0x47be) { puVar5 = tab_ksc5601_uni0; } else { uVar4 = CONCAT11(bVar1,bVar2) - 0xcaa1; if (0x335d < uVar4) { *param_2 = 0; return 0xfffffffe; } puVar5 = tab_ksc5601_uni1; } uVar3 = *(ushort *)(puVar5 + (ulong)uVar4 * 2); *param_2 = (ulong)uVar3; if (uVar3 == 0) { return 0xfffffffe; } return 2; }
60,835
mi_copy_status
eloqsql/storage/myisam/mi_locking.c
void mi_copy_status(void* to,void *from) { MI_INFO *info= (MI_INFO*) to; DBUG_ENTER("mi_copy_status"); info->state= &((MI_INFO*) from)->save_state; DBUG_PRINT("info",("key_file: %ld data_file: %ld", (long) info->state->key_file_length, (long) info->state->data_file_length)); DBUG_VOID_RETURN; }
O0
c
mi_copy_status: pushq %rbp movq %rsp, %rbp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq -0x8(%rbp), %rax movq %rax, -0x18(%rbp) movq -0x10(%rbp), %rcx addq $0x10, %rcx movq -0x18(%rbp), %rax movq %rcx, 0x8(%rax) jmp 0xb2d96 jmp 0xb2d98 jmp 0xb2d9a popq %rbp retq nopl (%rax)
mi_copy_status: push rbp mov rbp, rsp mov [rbp+var_8], rdi mov [rbp+var_10], rsi mov rax, [rbp+var_8] mov [rbp+var_18], rax mov rcx, [rbp+var_10] add rcx, 10h mov rax, [rbp+var_18] mov [rax+8], rcx jmp short $+2 loc_B2D96: jmp short $+2 loc_B2D98: jmp short $+2 loc_B2D9A: pop rbp retn
long long mi_copy_status(long long a1, long long a2) { long long result; // rax result = a1; *(_QWORD *)(a1 + 8) = a2 + 16; return result; }
mi_copy_status: PUSH RBP MOV RBP,RSP MOV qword ptr [RBP + -0x8],RDI MOV qword ptr [RBP + -0x10],RSI MOV RAX,qword ptr [RBP + -0x8] MOV qword ptr [RBP + -0x18],RAX MOV RCX,qword ptr [RBP + -0x10] ADD RCX,0x10 MOV RAX,qword ptr [RBP + -0x18] MOV qword ptr [RAX + 0x8],RCX JMP 0x001b2d96 LAB_001b2d96: JMP 0x001b2d98 LAB_001b2d98: JMP 0x001b2d9a LAB_001b2d9a: POP RBP RET
void mi_copy_status(long param_1,long param_2) { *(long *)(param_1 + 8) = param_2 + 0x10; return; }
60,836
nlohmann::json_abi_v3_11_3::detail::dtoa_impl::append_exponent(char*, int)
monkey531[P]llama/common/json.hpp
inline char* append_exponent(char* buf, int e) { JSON_ASSERT(e > -1000); JSON_ASSERT(e < 1000); if (e < 0) { e = -e; *buf++ = '-'; } else { *buf++ = '+'; } auto k = static_cast<std::uint32_t>(e); if (k < 10) { // Always print at least two digits in the exponent. // This is for compatibility with printf("%g"). *buf++ = '0'; *buf++ = static_cast<char>('0' + k); } else if (k < 100) { *buf++ = static_cast<char>('0' + k / 10); k %= 10; *buf++ = static_cast<char>('0' + k); } else { *buf++ = static_cast<char>('0' + k / 100); k %= 100; *buf++ = static_cast<char>('0' + k / 10); k %= 10; *buf++ = static_cast<char>('0' + k); } return buf; }
O2
cpp
nlohmann::json_abi_v3_11_3::detail::dtoa_impl::append_exponent(char*, int): pushq %rax cmpl $0xfffffc18, %esi # imm = 0xFFFFFC18 jle 0x4f4ee cmpl $0x3e8, %esi # imm = 0x3E8 jge 0x4f50a movl %esi, %ecx shrl $0x1f, %ecx addb %cl, %cl addb $0x2b, %cl movl %esi, %eax negl %eax cmovsl %esi, %eax movb %cl, (%rdi) cmpl $0x9, %eax ja 0x4f49c leaq 0x2(%rdi), %rdx movb $0x30, 0x1(%rdi) jmp 0x4f4b7 cmpl $0x63, %eax ja 0x4f4bb movzbl %al, %eax movb $0xa, %cl divb %cl movl %eax, %ecx movzbl %ah, %eax orb $0x30, %cl leaq 0x2(%rdi), %rdx movb %cl, 0x1(%rdi) pushq $0x3 jmp 0x4f4e1 movw $0x64, %cx xorl %edx, %edx divw %cx addb $0x30, %al movb %al, 0x1(%rdi) movzbl %dl, %eax movb $0xa, %cl divb %cl movl %eax, %ecx movzbl %ah, %eax orb $0x30, %cl leaq 0x3(%rdi), %rdx movb %cl, 0x2(%rdi) pushq $0x4 popq %rcx orb $0x30, %al addq %rcx, %rdi movb %al, (%rdx) movq %rdi, %rax popq %rcx retq leaq 0x49f80(%rip), %rdi # 0x99475 leaq 0x458ce(%rip), %rdx # 0x94dca leaq 0x4b15d(%rip), %rcx # 0x9a660 movl $0x45ae, %esi # imm = 0x45AE jmp 0x4f524 leaq 0x49f64(%rip), %rdi # 0x99475 leaq 0x458b2(%rip), %rdx # 0x94dca leaq 0x4b14b(%rip), %rcx # 0x9a66a movl $0x45af, %esi # imm = 0x45AF xorl %eax, %eax callq 0x21b30 nop
_ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl15append_exponentEPci: push rax cmp esi, 0FFFFFC18h jle loc_4F4EE cmp esi, 3E8h jge loc_4F50A mov ecx, esi shr ecx, 1Fh add cl, cl add cl, 2Bh ; '+' mov eax, esi neg eax cmovs eax, esi mov [rdi], cl cmp eax, 9 ja short loc_4F49C lea rdx, [rdi+2] mov byte ptr [rdi+1], 30h ; '0' jmp short loc_4F4B7 loc_4F49C: cmp eax, 63h ; 'c' ja short loc_4F4BB movzx eax, al mov cl, 0Ah div cl mov ecx, eax movzx eax, ah or cl, 30h lea rdx, [rdi+2] mov [rdi+1], cl loc_4F4B7: push 3 jmp short loc_4F4E1 loc_4F4BB: mov cx, 64h ; 'd' xor edx, edx div cx add al, 30h ; '0' mov [rdi+1], al movzx eax, dl mov cl, 0Ah div cl mov ecx, eax movzx eax, ah or cl, 30h lea rdx, [rdi+3] mov [rdi+2], cl push 4 loc_4F4E1: pop rcx or al, 30h add rdi, rcx mov [rdx], al mov rax, rdi pop rcx retn loc_4F4EE: lea rdi, aWorkspaceLlm4b_2; "/workspace/llm4binary/github/2025_star3"... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aE1000; "e > -1000" mov esi, 45AEh jmp short loc_4F524 loc_4F50A: lea rdi, aWorkspaceLlm4b_2; "/workspace/llm4binary/github/2025_star3"... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aE1000_0; "e < 1000" mov esi, 45AFh loc_4F524: xor eax, eax call _ggml_abort nop
long long nlohmann::json_abi_v3_11_3::detail::dtoa_impl::append_exponent( nlohmann::json_abi_v3_11_3::detail::dtoa_impl *this, char *a2) { unsigned int v2; // eax _BYTE *v3; // rdx char v4; // cl char v5; // cl int v7; // esi int v8; // edx int v9; // ecx int v10; // r8d int v11; // r9d long long v12; // [rsp-10h] [rbp-10h] if ( (int)a2 <= -1000 ) { v7 = 17838; ggml_abort( "/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp", 17838LL, "GGML_ASSERT(%s) failed", "e > -1000"); } else { if ( (int)a2 < 1000 ) { v2 = -(int)a2; if ( (int)a2 > 0 ) v2 = (unsigned int)a2; *(_BYTE *)this = 2 * ((int)a2 < 0) + 43; if ( v2 > 9 ) { if ( v2 > 0x63 ) { *((_BYTE *)this + 1) = (unsigned __int16)v2 / 0x64u + 48; v5 = (unsigned __int16)v2 % 0x64u / 0xA; LOBYTE(v2) = (unsigned __int16)v2 % 0x64u % 0xA; v3 = (char *)this + 3; *((_BYTE *)this + 2) = v5 | 0x30; v12 = 4LL; goto LABEL_11; } v4 = (unsigned __int8)v2 / 0xAu; LOBYTE(v2) = (unsigned __int8)v2 % 0xAu; v3 = (char *)this + 2; *((_BYTE *)this + 1) = v4 | 0x30; } else { v3 = (char *)this + 2; *((_BYTE *)this + 1) = 48; } v12 = 3LL; LABEL_11: *v3 = v2 | 0x30; return (long long)this + v12; } v7 = 17839; ggml_abort( "/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp", 17839LL, "GGML_ASSERT(%s) failed", "e < 1000"); } return SchemaConverter::resolve_refs( (unsigned int)"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp", v7, v8, v9, v10, v11); }
append_exponent: PUSH RAX CMP ESI,0xfffffc18 JLE 0x0014f4ee CMP ESI,0x3e8 JGE 0x0014f50a MOV ECX,ESI SHR ECX,0x1f ADD CL,CL ADD CL,0x2b MOV EAX,ESI NEG EAX CMOVS EAX,ESI MOV byte ptr [RDI],CL CMP EAX,0x9 JA 0x0014f49c LEA RDX,[RDI + 0x2] MOV byte ptr [RDI + 0x1],0x30 JMP 0x0014f4b7 LAB_0014f49c: CMP EAX,0x63 JA 0x0014f4bb MOVZX EAX,AL MOV CL,0xa DIV CL MOV ECX,EAX MOVZX EAX,AH OR CL,0x30 LEA RDX,[RDI + 0x2] MOV byte ptr [RDI + 0x1],CL LAB_0014f4b7: PUSH 0x3 JMP 0x0014f4e1 LAB_0014f4bb: MOV CX,0x64 XOR EDX,EDX DIV CX ADD AL,0x30 MOV byte ptr [RDI + 0x1],AL MOVZX EAX,DL MOV CL,0xa DIV CL MOV ECX,EAX MOVZX EAX,AH OR CL,0x30 LEA RDX,[RDI + 0x3] MOV byte ptr [RDI + 0x2],CL PUSH 0x4 LAB_0014f4e1: POP RCX OR AL,0x30 ADD RDI,RCX MOV byte ptr [RDX],AL MOV RAX,RDI POP RCX RET LAB_0014f4ee: LEA RDI,[0x199475] LEA RDX,[0x194dca] LEA RCX,[0x19a660] MOV ESI,0x45ae JMP 0x0014f524 LAB_0014f50a: LEA RDI,[0x199475] LEA RDX,[0x194dca] LEA RCX,[0x19a66a] MOV ESI,0x45af LAB_0014f524: XOR EAX,EAX CALL 0x00121b30
/* nlohmann::json_abi_v3_11_3::detail::dtoa_impl::append_exponent(char*, int) */ char * nlohmann::json_abi_v3_11_3::detail::dtoa_impl::append_exponent(char *param_1,int param_2) { byte bVar2; uint uVar1; char *pcVar3; ushort uVar4; byte *pbVar5; int8 uVar6; long lStack_10; if (param_2 < -999) { pcVar3 = "e > -1000"; uVar6 = 0x45ae; LAB_0014f524: /* WARNING: Subroutine does not return */ ggml_abort("/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",uVar6, "GGML_ASSERT(%s) failed",pcVar3); } if (999 < param_2) { pcVar3 = "e < 1000"; uVar6 = 0x45af; goto LAB_0014f524; } uVar1 = -param_2; if (0 < param_2) { uVar1 = param_2; } *param_1 = (char)(param_2 >> 0x1f) * -2 + '+'; if (uVar1 < 10) { param_1[1] = '0'; } else { if (99 < uVar1) { uVar4 = (ushort)((uVar1 & 0xffff) % 100); param_1[1] = (char)((uVar1 & 0xffff) / 100) + '0'; bVar2 = (byte)(uVar4 % 10); pbVar5 = (byte *)(param_1 + 3); param_1[2] = (byte)(uVar4 / 10) | 0x30; lStack_10 = 4; goto LAB_0014f4e1; } uVar4 = (ushort)uVar1 & 0xff; uVar1 = (uint)(byte)(uVar4 % 10); param_1[1] = (byte)(uVar4 / 10) | 0x30; } pbVar5 = (byte *)(param_1 + 2); bVar2 = (byte)uVar1; lStack_10 = 3; LAB_0014f4e1: *pbVar5 = bVar2 | 0x30; return param_1 + lStack_10; }
60,837
ma_tls_read
eloqsql/libmariadb/libmariadb/secure/openssl.c
ssize_t ma_tls_read(MARIADB_TLS *ctls, const uchar* buffer, size_t length) { int rc; MARIADB_PVIO *pvio= ctls->pvio; while ((rc= SSL_read((SSL *)ctls->ssl, (void *)buffer, (int)length)) <= 0) { int error= SSL_get_error((SSL *)ctls->ssl, rc); if (error != SSL_ERROR_WANT_READ) break; if (pvio->methods->wait_io_or_timeout(pvio, TRUE, pvio->mysql->options.read_timeout) < 1) break; } if (rc <= 0) { MYSQL *mysql= SSL_get_app_data(ctls->ssl); ma_tls_set_error(mysql); } return rc; }
O3
c
ma_tls_read: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx pushq %rax movq %rdx, %rbx movq %rsi, %r12 movq %rdi, %r15 movq 0x8(%rdi), %r13 movq 0x10(%r15), %rdi movq %r12, %rsi movl %ebx, %edx callq 0x13070 movl %eax, %r14d testl %eax, %eax jg 0x28598 movq 0x10(%r15), %rdi movl %r14d, %esi callq 0x13050 cmpl $0x2, %eax jne 0x28585 movq 0x40(%r13), %rax movq 0x48(%r13), %rcx movl 0x394(%rax), %edx movq %r13, %rdi movl $0x1, %esi callq *0x30(%rcx) testl %eax, %eax jg 0x28542 movq 0x10(%r15), %rdi xorl %esi, %esi callq 0x13160 movq %rax, %rdi callq 0x28318 movslq %r14d, %rax addq $0x8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
ma_tls_read: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx push rax mov rbx, rdx mov r12, rsi mov r15, rdi mov r13, [rdi+8] loc_28542: mov rdi, [r15+10h] mov rsi, r12 mov edx, ebx call _SSL_read mov r14d, eax test eax, eax jg short loc_28598 mov rdi, [r15+10h] mov esi, r14d call _SSL_get_error cmp eax, 2 jnz short loc_28585 mov rax, [r13+40h] mov rcx, [r13+48h] mov edx, [rax+394h] mov rdi, r13 mov esi, 1 call qword ptr [rcx+30h] test eax, eax jg short loc_28542 loc_28585: mov rdi, [r15+10h] xor esi, esi call _SSL_get_ex_data mov rdi, rax call ma_tls_set_error loc_28598: movsxd rax, r14d add rsp, 8 pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
long long ma_tls_read(long long a1, long long a2, unsigned int a3) { long long v4; // r13 int v5; // eax int v6; // r14d long long *v7; // rax v4 = *(_QWORD *)(a1 + 8); while ( 1 ) { v5 = SSL_read(*(_QWORD *)(a1 + 16), a2, a3); v6 = v5; if ( v5 > 0 ) break; if ( (unsigned int)SSL_get_error(*(_QWORD *)(a1 + 16), (unsigned int)v5) != 2 || (*(int ( **)(long long, long long, _QWORD))(*(_QWORD *)(v4 + 72) + 48LL))( v4, 1LL, *(unsigned int *)(*(_QWORD *)(v4 + 64) + 916LL)) <= 0 ) { v7 = (long long *)SSL_get_ex_data(*(_QWORD *)(a1 + 16), 0LL); ma_tls_set_error(v7); return v6; } } return v6; }
ma_tls_read: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX PUSH RAX MOV RBX,RDX MOV R12,RSI MOV R15,RDI MOV R13,qword ptr [RDI + 0x8] LAB_00128542: MOV RDI,qword ptr [R15 + 0x10] MOV RSI,R12 MOV EDX,EBX CALL 0x00113070 MOV R14D,EAX TEST EAX,EAX JG 0x00128598 MOV RDI,qword ptr [R15 + 0x10] MOV ESI,R14D CALL 0x00113050 CMP EAX,0x2 JNZ 0x00128585 MOV RAX,qword ptr [R13 + 0x40] MOV RCX,qword ptr [R13 + 0x48] MOV EDX,dword ptr [RAX + 0x394] MOV RDI,R13 MOV ESI,0x1 CALL qword ptr [RCX + 0x30] TEST EAX,EAX JG 0x00128542 LAB_00128585: MOV RDI,qword ptr [R15 + 0x10] XOR ESI,ESI CALL 0x00113160 MOV RDI,RAX CALL 0x00128318 LAB_00128598: MOVSXD RAX,R14D ADD RSP,0x8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
long ma_tls_read(long param_1,void *param_2,int param_3) { long lVar1; int ret_code; int iVar2; void *pvVar3; lVar1 = *(long *)(param_1 + 8); do { ret_code = SSL_read(*(SSL **)(param_1 + 0x10),param_2,param_3); if (0 < ret_code) goto LAB_00128598; iVar2 = SSL_get_error(*(SSL **)(param_1 + 0x10),ret_code); if (iVar2 != 2) break; iVar2 = (**(code **)(*(long *)(lVar1 + 0x48) + 0x30)) (lVar1,1,*(int4 *)(*(long *)(lVar1 + 0x40) + 0x394)); } while (0 < iVar2); pvVar3 = SSL_get_ex_data(*(SSL **)(param_1 + 0x10),0); ma_tls_set_error(pvVar3); LAB_00128598: return (long)ret_code; }
60,838
ftxui::yflex_grow(std::shared_ptr<ftxui::Node>)
Andrewchistyakov[P]flashcards_lyc/build_O1/_deps/ftxui-src/src/ftxui/dom/flex.cpp
Element yflex_grow(Element child) { return std::make_shared<Flex>(function_yflex_grow, std::move(child)); }
O1
cpp
ftxui::yflex_grow(std::shared_ptr<ftxui::Node>): pushq %r14 pushq %rbx subq $0x18, %rsp movq %rsi, %rdx movq %rdi, %rbx leaq 0x30(%rip), %rsi # 0x23ae6 leaq 0x8(%rsp), %r14 movq %r14, %rdi callq 0x23876 movq (%r14), %rax movq %rax, (%rbx) xorl %eax, %eax movq %rax, 0x8(%rbx) movq 0x8(%r14), %rcx movq %rax, 0x8(%r14) movq %rcx, 0x8(%rbx) movq %rbx, %rax addq $0x18, %rsp popq %rbx popq %r14 retq
_ZN5ftxui10yflex_growESt10shared_ptrINS_4NodeEE: push r14 push rbx sub rsp, 18h mov rdx, rsi mov rbx, rdi lea rsi, _ZN5ftxui12_GLOBAL__N_119function_yflex_growERNS_11RequirementE; ftxui::`anonymous namespace'::function_yflex_grow(ftxui::Requirement &) lea r14, [rsp+28h+var_20] mov rdi, r14 call _ZSt11make_sharedIN5ftxui12_GLOBAL__N_14FlexEJRFvRNS0_11RequirementEESt10shared_ptrINS0_4NodeEEEES7_IT_EDpOT0_; std::make_shared<ftxui::`anonymous namespace'::Flex,void (&)(ftxui::Requirement &),std::shared_ptr<ftxui::Node>>(void (&)(ftxui::Requirement &),std::shared_ptr<ftxui::Node> &&) mov rax, [r14] mov [rbx], rax xor eax, eax mov [rbx+8], rax mov rcx, [r14+8] mov [r14+8], rax mov [rbx+8], rcx mov rax, rbx add rsp, 18h pop rbx pop r14 retn
_QWORD * ftxui::yflex_grow(_QWORD *a1, __int128 *a2) { _QWORD v3[4]; // [rsp+8h] [rbp-20h] BYREF std::make_shared<ftxui::`anonymous namespace'::Flex,void (&)(ftxui::Requirement &),std::shared_ptr<ftxui::Node>>( v3, (long long)ftxui::`anonymous namespace'::function_yflex_grow, a2); *a1 = v3[0]; a1[1] = 0LL; a1[1] = v3[1]; return a1; }
yflex_grow: PUSH R14 PUSH RBX SUB RSP,0x18 MOV RDX,RSI MOV RBX,RDI LEA RSI,[0x123ae6] LEA R14,[RSP + 0x8] MOV RDI,R14 CALL 0x00123876 MOV RAX,qword ptr [R14] MOV qword ptr [RBX],RAX XOR EAX,EAX MOV qword ptr [RBX + 0x8],RAX MOV RCX,qword ptr [R14 + 0x8] MOV qword ptr [R14 + 0x8],RAX MOV qword ptr [RBX + 0x8],RCX MOV RAX,RBX ADD RSP,0x18 POP RBX POP R14 RET
/* ftxui::yflex_grow(std::shared_ptr<ftxui::Node>) */ int8 * ftxui::yflex_grow(int8 *param_1) { int8 local_20; int8 local_18; std:: make_shared<ftxui::(anonymous_namespace)::Flex,void(&)(ftxui::Requirement&),std::shared_ptr<ftxui::Node>> ((_func_void_Requirement_ptr *)&local_20, (shared_ptr *)(anonymous_namespace)::function_yflex_grow); *param_1 = local_20; param_1[1] = 0; param_1[1] = local_18; return param_1; }
60,839
nlohmann::json_abi_v3_11_3::ordered_map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>, std::less<void>, std::allocator<std::pair<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>>>::emplace(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>&&)
monkey531[P]llama/common/json.hpp
std::pair<iterator, bool> emplace(const key_type& key, T&& t) { for (auto it = this->begin(); it != this->end(); ++it) { if (m_compare(it->first, key)) { return {it, false}; } } Container::emplace_back(key, std::forward<T>(t)); return {std::prev(this->end()), true}; }
O0
cpp
nlohmann::json_abi_v3_11_3::ordered_map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>, std::less<void>, std::allocator<std::pair<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>>>::emplace(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>&&): subq $0x68, %rsp movq %rdi, 0x50(%rsp) movq %rsi, 0x48(%rsp) movq %rdx, 0x40(%rsp) movq 0x50(%rsp), %rdi movq %rdi, 0x8(%rsp) callq 0xc2140 movq %rax, 0x38(%rsp) movq 0x8(%rsp), %rdi callq 0xc2170 movq %rax, 0x30(%rsp) leaq 0x38(%rsp), %rdi leaq 0x30(%rsp), %rsi callq 0xc21a0 testb $0x1, %al jne 0xc4cdb jmp 0xc4d32 movq 0x8(%rsp), %rax addq $0x18, %rax movq %rax, (%rsp) leaq 0x38(%rsp), %rdi callq 0xc3310 movq (%rsp), %rdi movq %rax, %rsi movq 0x48(%rsp), %rdx callq 0xc4d90 testb $0x1, %al jne 0xc4d09 jmp 0xc4d24 movb $0x0, 0x2f(%rsp) leaq 0x58(%rsp), %rdi leaq 0x38(%rsp), %rsi leaq 0x2f(%rsp), %rdx callq 0xc4dc0 jmp 0xc4d82 jmp 0xc4d26 leaq 0x38(%rsp), %rdi callq 0xc2220 jmp 0xc4cb7 movq 0x8(%rsp), %rdi movq 0x48(%rsp), %rsi movq 0x40(%rsp), %rdx callq 0xc4df0 movq 0x8(%rsp), %rdi callq 0xc2170 movq %rax, 0x18(%rsp) movq 0x18(%rsp), %rdi movl $0x1, %esi callq 0xc4e80 movq %rax, 0x20(%rsp) movb $0x1, 0x17(%rsp) leaq 0x58(%rsp), %rdi leaq 0x20(%rsp), %rsi leaq 0x17(%rsp), %rdx callq 0xc4ec0 movq 0x58(%rsp), %rax movb 0x60(%rsp), %dl addq $0x68, %rsp retq
_ZN8nlohmann16json_abi_v3_11_311ordered_mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEENS0_10basic_jsonIS1_St6vectorS7_blmdSaNS0_14adl_serializerES9_IhSaIhEEvEESt4lessIvESaISt4pairIKS7_SD_EEE7emplaceERSH_OSD_: sub rsp, 68h mov [rsp+68h+var_18], rdi mov [rsp+68h+var_20], rsi mov [rsp+68h+var_28], rdx mov rdi, [rsp+68h+var_18] mov [rsp+68h+var_60], rdi call _ZNSt6vectorISt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINS9_11ordered_mapES_S6_blmdSaNS9_14adl_serializerES_IhSaIhEEvEEESaISG_EE5beginEv; std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>::begin(void) mov [rsp+68h+var_30], rax loc_C4CB7: mov rdi, [rsp+68h+var_60] call _ZNSt6vectorISt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINS9_11ordered_mapES_S6_blmdSaNS9_14adl_serializerES_IhSaIhEEvEEESaISG_EE3endEv; std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>::end(void) mov [rsp+68h+var_38], rax lea rdi, [rsp+68h+var_30] lea rsi, [rsp+68h+var_38] call _ZN9__gnu_cxxneIPSt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINSA_11ordered_mapESt6vectorS7_blmdSaNSA_14adl_serializerESD_IhSaIhEEvEEESD_ISI_SaISI_EEEEbRKNS_17__normal_iteratorIT_T0_EESR_; __gnu_cxx::operator!=<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>> *,std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>>(__gnu_cxx::__normal_iterator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>> *,std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>> const&,__gnu_cxx::__normal_iterator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>> *,std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>> const&) test al, 1 jnz short loc_C4CDB jmp short loc_C4D32 loc_C4CDB: mov rax, [rsp+68h+var_60] add rax, 18h mov [rsp+68h+var_68], rax lea rdi, [rsp+68h+var_30] call _ZNK9__gnu_cxx17__normal_iteratorIPSt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINSA_11ordered_mapESt6vectorS7_blmdSaNSA_14adl_serializerESD_IhSaIhEEvEEESD_ISI_SaISI_EEEptEv; __gnu_cxx::__normal_iterator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>> *,std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>>::operator->(void) mov rdi, [rsp+68h+var_68] mov rsi, rax mov rdx, [rsp+68h+var_20] call _ZNKSt8equal_toIvEclIRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES9_EEDTeqclsr3stdE7forwardIT_Efp_Eclsr3stdE7forwardIT0_Efp0_EEOSA_OSB_ test al, 1 jnz short loc_C4D09 jmp short loc_C4D24 loc_C4D09: mov [rsp+68h+var_39], 0 lea rdi, [rsp+68h+var_10] lea rsi, [rsp+68h+var_30] lea rdx, [rsp+68h+var_39] call _ZNSt4pairIN9__gnu_cxx17__normal_iteratorIPS_IKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINSA_11ordered_mapESt6vectorS7_blmdSaNSA_14adl_serializerESD_IhSaIhEEvEEESD_ISI_SaISI_EEEEbEC2IRSM_bTnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairISR_SS_EEEbE4typeELb1EEEOSR_OSS_ jmp short loc_C4D82 loc_C4D24: jmp short $+2 loc_C4D26: lea rdi, [rsp+68h+var_30] call _ZN9__gnu_cxx17__normal_iteratorIPSt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINSA_11ordered_mapESt6vectorS7_blmdSaNSA_14adl_serializerESD_IhSaIhEEvEEESD_ISI_SaISI_EEEppEv; __gnu_cxx::__normal_iterator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>> *,std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>>::operator++(void) jmp short loc_C4CB7 loc_C4D32: mov rdi, [rsp+68h+var_60] mov rsi, [rsp+68h+var_20] mov rdx, [rsp+68h+var_28] call _ZNSt6vectorISt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINS9_11ordered_mapES_S6_blmdSaNS9_14adl_serializerES_IhSaIhEEvEEESaISG_EE12emplace_backIJRS7_SF_EEERSG_DpOT_; std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>::emplace_back<std::string const&,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>(std::string const&,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> &&) mov rdi, [rsp+68h+var_60] call _ZNSt6vectorISt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINS9_11ordered_mapES_S6_blmdSaNS9_14adl_serializerES_IhSaIhEEvEEESaISG_EE3endEv; std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>::end(void) mov [rsp+68h+var_50], rax mov rdi, [rsp+68h+var_50] mov esi, 1 call _ZSt4prevIN9__gnu_cxx17__normal_iteratorIPSt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINSB_11ordered_mapESt6vectorS8_blmdSaNSB_14adl_serializerESE_IhSaIhEEvEEESE_ISJ_SaISJ_EEEEET_SO_NSt15iterator_traitsISO_E15difference_typeE; std::prev<__gnu_cxx::__normal_iterator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>> *,std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>>>(__gnu_cxx::__normal_iterator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>> *,std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>>,std::iterator_traits<__gnu_cxx::__normal_iterator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>> *,std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>>>::difference_type) mov [rsp+68h+var_48], rax mov [rsp+68h+var_51], 1 lea rdi, [rsp+68h+var_10] lea rsi, [rsp+68h+var_48] lea rdx, [rsp+68h+var_51] call _ZNSt4pairIN9__gnu_cxx17__normal_iteratorIPS_IKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINSA_11ordered_mapESt6vectorS7_blmdSaNSA_14adl_serializerESD_IhSaIhEEvEEESD_ISI_SaISI_EEEEbEC2ISM_bTnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairISQ_SR_EEEbE4typeELb1EEEOSQ_OSR_ loc_C4D82: mov rax, [rsp+68h+var_10] mov dl, [rsp+68h+var_8] add rsp, 68h retn
long long nlohmann::json_abi_v3_11_3::ordered_map<std::string,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,std::less<void>,std::allocator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>>>::emplace( long long a1, long long a2, long long a3) { long long v3; // rax char v5; // [rsp+17h] [rbp-51h] BYREF long long v6; // [rsp+18h] [rbp-50h] long long v7; // [rsp+20h] [rbp-48h] BYREF char v8; // [rsp+2Fh] [rbp-39h] BYREF long long v9; // [rsp+30h] [rbp-38h] BYREF long long i; // [rsp+38h] [rbp-30h] BYREF long long v11; // [rsp+40h] [rbp-28h] long long v12; // [rsp+48h] [rbp-20h] long long v13; // [rsp+50h] [rbp-18h] long long v14; // [rsp+58h] [rbp-10h] BYREF v13 = a1; v12 = a2; v11 = a3; for ( i = std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>>::begin(a1); ; __gnu_cxx::__normal_iterator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>> *,std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>>>::operator++(&i) ) { v9 = std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>>::end(a1); if ( !__gnu_cxx::operator!=<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>> *,std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>>>( (long long)&i, (long long)&v9) ) break; v3 = __gnu_cxx::__normal_iterator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>> *,std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>>>::operator->((long long)&i); if ( (std::equal_to<void>::operator()<std::string const&,std::string const&>(a1 + 24, v3, v12) & 1) != 0 ) { v8 = 0; ZNSt4pairIN9__gnu_cxx17__normal_iteratorIPS_IKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINSA_11ordered_mapESt6vectorS7_blmdSaNSA_14adl_serializerESD_IhSaIhEEvEEESD_ISI_SaISI_EEEEbEC2IRSM_bTnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairISR_SS_EEEbE4typeELb1EEEOSR_OSS_( &v14, &i, &v8); return v14; } } std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>>::emplace_back<std::string const&,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>( a1, v12, v11); v6 = std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>>::end(a1); v7 = std::prev<__gnu_cxx::__normal_iterator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>> *,std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>>>>( v6, 1LL); v5 = 1; ZNSt4pairIN9__gnu_cxx17__normal_iteratorIPS_IKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINSA_11ordered_mapESt6vectorS7_blmdSaNSA_14adl_serializerESD_IhSaIhEEvEEESD_ISI_SaISI_EEEEbEC2ISM_bTnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairISQ_SR_EEEbE4typeELb1EEEOSQ_OSR_( &v14, &v7, &v5); return v14; }
emplace: SUB RSP,0x68 MOV qword ptr [RSP + 0x50],RDI MOV qword ptr [RSP + 0x48],RSI MOV qword ptr [RSP + 0x40],RDX MOV RDI,qword ptr [RSP + 0x50] MOV qword ptr [RSP + 0x8],RDI CALL 0x001c2140 MOV qword ptr [RSP + 0x38],RAX LAB_001c4cb7: MOV RDI,qword ptr [RSP + 0x8] CALL 0x001c2170 MOV qword ptr [RSP + 0x30],RAX LEA RDI,[RSP + 0x38] LEA RSI,[RSP + 0x30] CALL 0x001c21a0 TEST AL,0x1 JNZ 0x001c4cdb JMP 0x001c4d32 LAB_001c4cdb: MOV RAX,qword ptr [RSP + 0x8] ADD RAX,0x18 MOV qword ptr [RSP],RAX LEA RDI,[RSP + 0x38] CALL 0x001c3310 MOV RDI,qword ptr [RSP] MOV RSI,RAX MOV RDX,qword ptr [RSP + 0x48] CALL 0x001c4d90 TEST AL,0x1 JNZ 0x001c4d09 JMP 0x001c4d24 LAB_001c4d09: MOV byte ptr [RSP + 0x2f],0x0 LEA RDI,[RSP + 0x58] LEA RSI,[RSP + 0x38] LEA RDX,[RSP + 0x2f] CALL 0x001c4dc0 JMP 0x001c4d82 LAB_001c4d24: JMP 0x001c4d26 LAB_001c4d26: LEA RDI,[RSP + 0x38] CALL 0x001c2220 JMP 0x001c4cb7 LAB_001c4d32: MOV RDI,qword ptr [RSP + 0x8] MOV RSI,qword ptr [RSP + 0x48] MOV RDX,qword ptr [RSP + 0x40] CALL 0x001c4df0 MOV RDI,qword ptr [RSP + 0x8] CALL 0x001c2170 MOV qword ptr [RSP + 0x18],RAX MOV RDI,qword ptr [RSP + 0x18] MOV ESI,0x1 CALL 0x001c4e80 MOV qword ptr [RSP + 0x20],RAX MOV byte ptr [RSP + 0x17],0x1 LEA RDI,[RSP + 0x58] LEA RSI,[RSP + 0x20] LEA RDX,[RSP + 0x17] CALL 0x001c4ec0 LAB_001c4d82: MOV RAX,qword ptr [RSP + 0x58] MOV DL,byte ptr [RSP + 0x60] ADD RSP,0x68 RET
/* nlohmann::json_abi_v3_11_3::ordered_map<std::__cxx11::string, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char> >, void>, std::less<void>, std::allocator<std::pair<std::__cxx11::string const, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char> >, void> > > >::emplace(std::__cxx11::string const&, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char> >, void>&&) */ int1 [16] __thiscall nlohmann::json_abi_v3_11_3:: ordered_map<std::__cxx11::string,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,std::less<void>,std::allocator<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>> ::emplace(ordered_map<std::__cxx11::string,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,std::less<void>,std::allocator<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>> *this,string *param_1,basic_json *param_2) { bool bVar1; string *psVar2; ulong uVar3; int8 extraout_RDX; int8 extraout_RDX_00; int8 uVar4; int1 auVar5 [16]; int1 local_51; int8 local_50; int8 local_48; int1 local_39; int8 local_38; int8 local_30; basic_json *local_28; string *local_20; ordered_map<std::__cxx11::string,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,std::less<void>,std::allocator<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>> *local_18; int8 local_10; int1 local_8; local_28 = param_2; local_20 = param_1; local_18 = this; local_30 = std:: vector<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>,std::allocator<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>> ::begin((vector<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>,std::allocator<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>> *)this); do { local_38 = std:: vector<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>,std::allocator<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>> ::end((vector<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>,std::allocator<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>> *)this); bVar1 = __gnu_cxx::operator!=((__normal_iterator *)&local_30,(__normal_iterator *)&local_38); if (!bVar1) { std:: vector<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>,std::allocator<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>> :: emplace_back<std::__cxx11::string_const&,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>> ((vector<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>,std::allocator<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>> *)this,local_20,local_28); local_50 = std:: vector<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>,std::allocator<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>> ::end((vector<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>,std::allocator<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>> *)this); local_48 = std:: prev<__gnu_cxx::__normal_iterator<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>*,std::vector<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>,std::allocator<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>>>> (local_50,1); local_51 = 1; _ZNSt4pairIN9__gnu_cxx17__normal_iteratorIPS_IKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINSA_11ordered_mapESt6vectorS7_blmdSaNSA_14adl_serializerESD_IhSaIhEEvEEESD_ISI_SaISI_EEEEbEC2ISM_bTnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairISQ_SR_EEEbE4typeELb1EEEOSQ_OSR_ (&local_10,&local_48,&local_51); uVar4 = extraout_RDX_00; LAB_001c4d82: auVar5._9_7_ = (int7)((ulong)uVar4 >> 8); auVar5[8] = local_8; auVar5._0_8_ = local_10; return auVar5; } psVar2 = (string *) __gnu_cxx:: __normal_iterator<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>*,std::vector<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>,std::allocator<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>>> ::operator->((__normal_iterator<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>*,std::vector<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>,std::allocator<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>>> *)&local_30); uVar3 = std::equal_to<void>::operator()((equal_to<void> *)(this + 0x18),psVar2,local_20); if ((uVar3 & 1) != 0) { local_39 = 0; _ZNSt4pairIN9__gnu_cxx17__normal_iteratorIPS_IKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINSA_11ordered_mapESt6vectorS7_blmdSaNSA_14adl_serializerESD_IhSaIhEEvEEESD_ISI_SaISI_EEEEbEC2IRSM_bTnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairISR_SS_EEEbE4typeELb1EEEOSR_OSS_ (&local_10,&local_30,&local_39); uVar4 = extraout_RDX; goto LAB_001c4d82; } __gnu_cxx:: __normal_iterator<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>*,std::vector<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>,std::allocator<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>>> ::operator++((__normal_iterator<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>*,std::vector<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>,std::allocator<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>>> *)&local_30); } while( true ); }
60,840
nlohmann::json_abi_v3_11_3::ordered_map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>, std::less<void>, std::allocator<std::pair<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>>>::emplace(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>&&)
monkey531[P]llama/common/json.hpp
std::pair<iterator, bool> emplace(const key_type& key, T&& t) { for (auto it = this->begin(); it != this->end(); ++it) { if (m_compare(it->first, key)) { return {it, false}; } } Container::emplace_back(key, std::forward<T>(t)); return {std::prev(this->end()), true}; }
O1
cpp
nlohmann::json_abi_v3_11_3::ordered_map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>, std::less<void>, std::allocator<std::pair<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>>>::emplace(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>&&): pushq %rbp pushq %r15 pushq %r14 pushq %r12 pushq %rbx movq %rdx, %r15 movq %rsi, %r12 movq %rdi, %r14 movq (%rdi), %rbx cmpq 0x8(%rdi), %rbx sete %bpl je 0x94106 movq %rbx, %rdi movq %r12, %rsi callq 0x92429 testb %al, %al jne 0x94101 addq $0x60, %rbx cmpq 0x8(%r14), %rbx jmp 0x940e2 testb %bpl, %bpl je 0x94120 movq %r14, %rdi movq %r12, %rsi movq %r15, %rdx callq 0x9412e movq 0x8(%r14), %rbx addq $-0x60, %rbx movb $0x1, %dl jmp 0x94122 xorl %edx, %edx movq %rbx, %rax popq %rbx popq %r12 popq %r14 popq %r15 popq %rbp retq
_ZN8nlohmann16json_abi_v3_11_311ordered_mapINS0_10basic_jsonIS1_St6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEEN5minja5ValueESt4lessISD_ESaISt4pairIKSD_SF_EEE7emplaceERSJ_OSF_: push rbp push r15 push r14 push r12 push rbx mov r15, rdx mov r12, rsi mov r14, rdi mov rbx, [rdi] cmp rbx, [rdi+8] loc_940E2: setz bpl jz short loc_94106 mov rdi, rbx mov rsi, r12 call _ZN8nlohmann16json_abi_v3_11_3eqERKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEESF_; nlohmann::json_abi_v3_11_3::operator==(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const&,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const&) test al, al jnz short loc_94101 add rbx, 60h ; '`' cmp rbx, [r14+8] jmp short loc_940E2 loc_94101: test bpl, bpl jz short loc_94120 loc_94106: mov rdi, r14 mov rsi, r12 mov rdx, r15 call _ZNSt6vectorISt4pairIKN8nlohmann16json_abi_v3_11_310basic_jsonINS2_11ordered_mapES_NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS2_14adl_serializerES_IhSaIhEEvEEN5minja5ValueEESaISI_EE12emplace_backIJRSF_SH_EEERSI_DpOT_; std::vector<std::pair<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const,minja::Value>>::emplace_back<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const&,minja::Value>(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const&,minja::Value &&) mov rbx, [r14+8] add rbx, 0FFFFFFFFFFFFFFA0h mov dl, 1 jmp short loc_94122 loc_94120: xor edx, edx loc_94122: mov rax, rbx pop rbx pop r12 pop r14 pop r15 pop rbp retn
long long nlohmann::json_abi_v3_11_3::ordered_map<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,minja::Value,std::less<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>,std::allocator<std::pair<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void> const,minja::Value>>>::emplace( long long a1, unsigned __int8 *a2, long long a3, __m128d a4) { unsigned __int8 *v5; // rbx bool i; // zf bool v7; // bp v5 = *(unsigned __int8 **)a1; for ( i = *(_QWORD *)a1 == *(_QWORD *)(a1 + 8); ; i = v5 == *(unsigned __int8 **)(a1 + 8) ) { v7 = i; if ( i ) break; if ( (unsigned __int8)nlohmann::json_abi_v3_11_3::operator==(v5, a2, a4) ) { if ( !v7 ) return (long long)v5; break; } v5 += 96; } std::vector<std::pair<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void> const,minja::Value>>::emplace_back<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void> const&,minja::Value>( a1, a2, a3); return *(_QWORD *)(a1 + 8) - 96LL; }
emplace: PUSH RBP PUSH R15 PUSH R14 PUSH R12 PUSH RBX MOV R15,RDX MOV R12,RSI MOV R14,RDI MOV RBX,qword ptr [RDI] CMP RBX,qword ptr [RDI + 0x8] LAB_001940e2: SETZ BPL JZ 0x00194106 MOV RDI,RBX MOV RSI,R12 CALL 0x00192429 TEST AL,AL JNZ 0x00194101 ADD RBX,0x60 CMP RBX,qword ptr [R14 + 0x8] JMP 0x001940e2 LAB_00194101: TEST BPL,BPL JZ 0x00194120 LAB_00194106: MOV RDI,R14 MOV RSI,R12 MOV RDX,R15 CALL 0x0019412e MOV RBX,qword ptr [R14 + 0x8] ADD RBX,-0x60 MOV DL,0x1 JMP 0x00194122 LAB_00194120: XOR EDX,EDX LAB_00194122: MOV RAX,RBX POP RBX POP R12 POP R14 POP R15 POP RBP RET
/* nlohmann::json_abi_v3_11_3::ordered_map<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char> >, void>, minja::Value, std::less<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char> >, void> >, std::allocator<std::pair<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char> >, void> const, minja::Value> > >::emplace(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char> >, void> const&, minja::Value&&) */ int1 [16] __thiscall nlohmann::json_abi_v3_11_3:: ordered_map<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,minja::Value,std::less<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>,std::allocator<std::pair<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const,minja::Value>>> ::emplace(ordered_map<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,minja::Value,std::less<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>,std::allocator<std::pair<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const,minja::Value>>> *this,basic_json *param_1,Value *param_2) { char cVar1; int8 extraout_RDX; int8 uVar2; basic_json *pbVar3; bool bVar4; int1 auVar5 [16]; pbVar3 = *(basic_json **)this; bVar4 = pbVar3 == *(basic_json **)(this + 8); do { if (bVar4) { LAB_00194106: std:: vector<std::pair<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const,minja::Value>,std::allocator<std::pair<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const,minja::Value>>> :: emplace_back<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const&,minja::Value> ((vector<std::pair<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const,minja::Value>,std::allocator<std::pair<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const,minja::Value>>> *)this,param_1,param_2); pbVar3 = (basic_json *)(*(long *)(this + 8) + -0x60); uVar2 = CONCAT71((int7)((ulong)extraout_RDX >> 8),1); LAB_00194122: auVar5._8_8_ = uVar2; auVar5._0_8_ = pbVar3; return auVar5; } cVar1 = operator==(pbVar3,param_1); if (cVar1 != '\0') { if (!bVar4) { uVar2 = 0; goto LAB_00194122; } goto LAB_00194106; } pbVar3 = pbVar3 + 0x60; bVar4 = pbVar3 == *(basic_json **)(this + 8); } while( true ); }
60,841
SettingValue_Language::layout() const
untodesu[P]voxelius/game/client/settings.cc
void SettingValue_Language::layout(void) const { auto current_language = language::get_current(); if(ImGui::BeginCombo(wid.c_str(), current_language->endonym.c_str())) { for(auto it = language::cbegin(); it != language::cend(); ++it) { if(ImGui::Selectable(it->display.c_str(), it == current_language)) { language::set(it); continue; } } ImGui::EndCombo(); } layout_label(); layout_tooltip(); }
O1
cpp
SettingValue_Language::layout() const: pushq %r15 pushq %r14 pushq %r12 pushq %rbx pushq %rax movq %rdi, %rbx callq 0x537ee movq %rax, %r14 movq 0x78(%rbx), %rdi movq (%rax), %rsi xorl %edx, %edx callq 0xd1415 testb %al, %al je 0x69636 callq 0x5387e movq %rax, %r15 callq 0x53886 cmpq %rax, %r15 je 0x69631 movq %rsp, %r12 movq 0x20(%r15), %rdi xorl %esi, %esi cmpq %r14, %r15 sete %sil movq $0x0, (%rsp) xorl %edx, %edx movq %r12, %rcx callq 0xd218c testb %al, %al je 0x69623 movq %r15, %rdi callq 0x53490 addq $0x60, %r15 callq 0x53886 cmpq %rax, %r15 jne 0x695f8 callq 0xd1cbe movss 0x12c91e(%rip), %xmm1 # 0x195f5c xorps %xmm0, %xmm0 callq 0x10f0da movq 0x30(%rbx), %rdi xorl %esi, %esi callq 0xcc66c movq %rbx, %rdi callq 0x68138 addq $0x8, %rsp popq %rbx popq %r12 popq %r14 popq %r15 retq
_ZNK21SettingValue_Language6layoutEv: push r15; int push r14; void * push r12; int push rbx; int push rax mov rbx, rdi call _ZN8language11get_currentEv; language::get_current(void) mov r14, rax mov rdi, [rbx+78h]; this mov rsi, [rax]; ImGui * xor edx, edx; char * call _ZN5ImGui10BeginComboEPKcS1_i; ImGui::BeginCombo(char const*,char const*,int) test al, al jz short loc_69636 call _ZN8language6cbeginEv; language::cbegin(void) mov r15, rax call _ZN8language4cendEv; language::cend(void) cmp r15, rax jz short loc_69631 mov r12, rsp loc_695F8: mov rdi, [r15+20h]; char * xor esi, esi cmp r15, r14 setz sil mov qword ptr [rsp+28h+var_28], 0; int xor edx, edx mov rcx, r12 call _ZN5ImGui10SelectableEPKcbiRK6ImVec2; ImGui::Selectable(char const*,bool,int,ImVec2 const&) test al, al jz short loc_69623 mov rdi, r15; this call _ZN8language3setEN9__gnu_cxx17__normal_iteratorIPK12LanguageInfoSt6vectorIS2_SaIS2_EEEE; language::set(__gnu_cxx::__normal_iterator<LanguageInfo const*,std::vector<LanguageInfo>>) loc_69623: add r15, 60h ; '`' call _ZN8language4cendEv; language::cend(void) cmp r15, rax jnz short loc_695F8 loc_69631: call _ZN5ImGui8EndComboEv; ImGui::EndCombo(void) loc_69636: movss xmm1, cs:flt_195F5C; float xorps xmm0, xmm0; float call _ZN5ImGui8SameLineEff; ImGui::SameLine(float,float) mov rdi, [rbx+30h]; this xor esi, esi; char * call _ZN5ImGui15TextUnformattedEPKcS1_; ImGui::TextUnformatted(char const*,char const*) mov rdi, rbx; this call _ZNK12SettingValue14layout_tooltipEv; SettingValue::layout_tooltip(void) add rsp, 8 pop rbx pop r12 pop r14 pop r15 retn
void SettingValue_Language::layout(ImGui **this) { ImGui **current; // r14 language *v3; // rdi int v4; // ecx long long i; // r15 int v6; // edx int v7; // ecx int v8; // r8d int v9; // r9d const char *v10; // rdx current = (ImGui **)language::get_current((language *)this); v3 = this[15]; if ( (unsigned __int8)ImGui::BeginCombo(v3, *current, 0LL, v4) ) { for ( i = language::cbegin(v3); i != language::cend(v3); i += 96LL ) { v3 = *(language **)(i + 32); if ( (unsigned __int8)ImGui::Selectable((char *)v3) ) { v3 = (language *)i; language::set(i, i == (_QWORD)current, v6, v7, v8, v9); } } ImGui::EndCombo(v3); } ImGui::SameLine(v3, 0.0, -1.0); ImGui::TextUnformatted(this[6], 0LL, v10); SettingValue::layout_tooltip(this, 0LL); }
layout: PUSH R15 PUSH R14 PUSH R12 PUSH RBX PUSH RAX MOV RBX,RDI CALL 0x001537ee MOV R14,RAX MOV RDI,qword ptr [RBX + 0x78] MOV RSI,qword ptr [RAX] XOR EDX,EDX CALL 0x001d1415 TEST AL,AL JZ 0x00169636 CALL 0x0015387e MOV R15,RAX CALL 0x00153886 CMP R15,RAX JZ 0x00169631 MOV R12,RSP LAB_001695f8: MOV RDI,qword ptr [R15 + 0x20] XOR ESI,ESI CMP R15,R14 SETZ SIL MOV qword ptr [RSP],0x0 XOR EDX,EDX MOV RCX,R12 CALL 0x001d218c TEST AL,AL JZ 0x00169623 MOV RDI,R15 CALL 0x00153490 LAB_00169623: ADD R15,0x60 CALL 0x00153886 CMP R15,RAX JNZ 0x001695f8 LAB_00169631: CALL 0x001d1cbe LAB_00169636: MOVSS XMM1,dword ptr [0x00295f5c] XORPS XMM0,XMM0 CALL 0x0020f0da MOV RDI,qword ptr [RBX + 0x30] XOR ESI,ESI CALL 0x001cc66c MOV RDI,RBX CALL 0x00168138 ADD RSP,0x8 POP RBX POP R12 POP R14 POP R15 RET
/* SettingValue_Language::layout() const */ void __thiscall SettingValue_Language::layout(SettingValue_Language *this) { int8 *puVar1; int1 in_AL; char cVar2; int7 in_register_00000001; int8 *puVar3; int8 *puVar4; int8 local_28; local_28 = CONCAT71(in_register_00000001,in_AL); puVar3 = (int8 *)language::get_current(); cVar2 = ImGui::BeginCombo(*(char **)(this + 0x78),(char *)*puVar3,0); if (cVar2 != '\0') { puVar4 = (int8 *)language::cbegin(); puVar1 = (int8 *)language::cend(); if (puVar4 != puVar1) { do { local_28 = 0; cVar2 = ImGui::Selectable((char *)puVar4[4],puVar4 == puVar3,0,(ImVec2 *)&local_28); if (cVar2 != '\0') { language::set(puVar4); } puVar4 = puVar4 + 0xc; puVar1 = (int8 *)language::cend(); } while (puVar4 != puVar1); } ImGui::EndCombo(); } ImGui::SameLine(0.0,DAT_00295f5c); ImGui::TextUnformatted(*(char **)(this + 0x30),(char *)0x0); SettingValue::layout_tooltip((SettingValue *)this); return; }
60,842
unpack_dirname
eloqsql/mysys/mf_pack.c
size_t unpack_dirname(char * to, const char *from) { size_t length, h_length; char buff[FN_REFLEN+1+4],*suffix,*tilde_expansion; DBUG_ENTER("unpack_dirname"); length= normalize_dirname(buff, from); if (buff[0] == FN_HOMELIB) { suffix=buff+1; tilde_expansion=expand_tilde(&suffix); if (tilde_expansion) { length-= (size_t) (suffix-buff)-1; if (length+(h_length= strlen(tilde_expansion)) <= FN_REFLEN) { if ((h_length > 0) && (tilde_expansion[h_length-1] == FN_LIBCHAR)) h_length--; if (buff+h_length < suffix) bmove(buff+h_length,suffix,length); else bmove_upp((uchar*) buff+h_length+length, (uchar*) suffix+length, length); bmove(buff,tilde_expansion,h_length); } } } #ifdef USE_SYMDIR if (my_use_symdir) symdirget(buff); #endif DBUG_RETURN(system_filename(to,buff)); /* Fix for open */ }
O3
c
unpack_dirname: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x228, %rsp # imm = 0x228 movq %rdi, -0x250(%rbp) movq %fs:0x28, %rax movq %rax, -0x30(%rbp) leaq -0x240(%rbp), %r13 movq %r13, %rdi callq 0x9c30b cmpb $0x7e, (%r13) jne 0x9c4cd movq %rax, %r14 leaq -0x23f(%rbp), %r15 cmpb $0x2f, (%r15) jne 0x9c3ed leaq 0xb6dc5d(%rip), %rbx # 0xc0a048 jmp 0x9c446 movq %r15, %rdi movl $0x2f, %esi callq 0x29440 movq %rax, %r12 testq %rax, %rax jne 0x9c40d movq %r15, %rdi callq 0xd806c movq %rax, %r12 movb (%r12), %al movb %al, -0x241(%rbp) movb $0x0, (%r12) movq %r15, %rdi callq 0x295b0 movq %rax, %rbx movb -0x241(%rbp), %al movb %al, (%r12) callq 0x298b0 testq %rbx, %rbx je 0x9c4cd addq $0x20, %rbx movq %r12, %r15 movq (%rbx), %r12 testq %r12, %r12 je 0x9c4cd addq %r13, %r14 subq %r15, %r14 movq %r12, %rdi callq 0x29350 movq %rax, %r13 addq %r14, %rax incq %rax cmpq $0x200, %rax # imm = 0x200 ja 0x9c4cd testq %r13, %r13 je 0x9c482 xorl %eax, %eax cmpb $0x2f, -0x1(%r12,%r13) sete %al subq %rax, %r13 jmp 0x9c485 xorl %r13d, %r13d incq %r14 leaq -0x240(,%r13), %rdi addq %rbp, %rdi cmpq %r15, %rdi jae 0x9c4a5 movq %r15, %rsi movq %r14, %rdx callq 0x29120 jmp 0x9c4b6 addq %r14, %rdi addq %r14, %r15 movq %r15, %rsi movq %r14, %rdx callq 0xabbb4 leaq -0x240(%rbp), %rdi movl $0x205, %ecx # imm = 0x205 movq %r12, %rsi movq %r13, %rdx callq 0x294c0 leaq -0x240(%rbp), %rsi movl $0x1ff, %edx # imm = 0x1FF movq -0x250(%rbp), %rbx movq %rbx, %rdi callq 0xd80b4 movq %fs:0x28, %rcx cmpq -0x30(%rbp), %rcx jne 0x9c50c subq %rbx, %rax addq $0x228, %rsp # imm = 0x228 popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq callq 0x29270
unpack_dirname: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx sub rsp, 228h mov [rbp+var_250], rdi mov rax, fs:28h mov [rbp+var_30], rax lea r13, [rbp+var_240] mov rdi, r13 call normalize_dirname cmp byte ptr [r13+0], 7Eh ; '~' jnz loc_9C4CD mov r14, rax lea r15, [rbp+var_23F] cmp byte ptr [r15], 2Fh ; '/' jnz short loc_9C3ED lea rbx, home_dir jmp short loc_9C446 loc_9C3ED: mov rdi, r15 mov esi, 2Fh ; '/' call _strchr mov r12, rax test rax, rax jnz short loc_9C40D mov rdi, r15 call strend mov r12, rax loc_9C40D: mov al, [r12] mov [rbp+var_241], al mov byte ptr [r12], 0 mov rdi, r15 call _getpwnam mov rbx, rax mov al, [rbp+var_241] mov [r12], al call _endpwent test rbx, rbx jz loc_9C4CD add rbx, 20h ; ' ' mov r15, r12 loc_9C446: mov r12, [rbx] test r12, r12 jz short loc_9C4CD add r14, r13 sub r14, r15 mov rdi, r12 call _strlen mov r13, rax add rax, r14 inc rax cmp rax, 200h ja short loc_9C4CD test r13, r13 jz short loc_9C482 xor eax, eax cmp byte ptr [r12+r13-1], 2Fh ; '/' setz al sub r13, rax jmp short loc_9C485 loc_9C482: xor r13d, r13d loc_9C485: inc r14 lea rdi, ds:0FFFFFFFFFFFFFDC0h[r13] add rdi, rbp cmp rdi, r15 jnb short loc_9C4A5 mov rsi, r15 mov rdx, r14 call _memmove jmp short loc_9C4B6 loc_9C4A5: add rdi, r14 add r15, r14 mov rsi, r15 mov rdx, r14 call bmove_upp loc_9C4B6: lea rdi, [rbp+var_240] mov ecx, 205h mov rsi, r12 mov rdx, r13 call ___memmove_chk loc_9C4CD: lea rsi, [rbp+var_240] mov edx, 1FFh mov rbx, [rbp+var_250] mov rdi, rbx call strmake mov rcx, fs:28h cmp rcx, [rbp+var_30] jnz short loc_9C50C sub rax, rbx add rsp, 228h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn loc_9C50C: call ___stack_chk_fail
long long unpack_dirname(long long a1, _BYTE *a2) { long long v2; // rax long long v3; // r14 char *v4; // r15 _QWORD *v5; // rbx char *v6; // r12 long long v7; // rbx long long v8; // r12 _BYTE *v9; // r14 long long v10; // r13 long long v11; // r13 _BYTE *v12; // r14 char *v13; // rdi char v16; // [rsp+Fh] [rbp-241h] char v17; // [rsp+10h] [rbp-240h] BYREF _BYTE v18[527]; // [rsp+11h] [rbp-23Fh] BYREF unsigned long long v19; // [rsp+220h] [rbp-30h] long long savedregs; // [rsp+250h] [rbp+0h] BYREF v19 = __readfsqword(0x28u); v2 = normalize_dirname((long long)&v17, a2); if ( v17 != 126 ) return strmake(a1, &v17, 511LL) - a1; v3 = v2; v4 = v18; if ( v18[0] == 47 ) { v5 = &home_dir; LABEL_8: v8 = *v5; if ( *v5 ) { v9 = (_BYTE *)(&v18[v3 - 1] - v4); v10 = strlen(*v5); if ( (unsigned long long)&v9[v10 + 1] <= 0x200 ) { if ( v10 ) v11 = v10 - (*(_BYTE *)(v8 + v10 - 1) == 47); else v11 = 0LL; v12 = v9 + 1; v13 = (char *)&savedregs + v11 - 576; if ( v13 >= v4 ) bmove_upp(&v13[(_QWORD)v12], &v4[(_QWORD)v12]); else memmove(v13, v4, v12); __memmove_chk(&v17, v8, v11, 517LL); } } return strmake(a1, &v17, 511LL) - a1; } v6 = (char *)strchr(v18, 47LL); if ( !v6 ) v6 = (char *)strend(v18); v16 = *v6; *v6 = 0; v7 = getpwnam(v18); *v6 = v16; endpwent(); if ( v7 ) { v5 = (_QWORD *)(v7 + 32); v4 = v6; goto LABEL_8; } return strmake(a1, &v17, 511LL) - a1; }
unpack_dirname: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x228 MOV qword ptr [RBP + -0x250],RDI MOV RAX,qword ptr FS:[0x28] MOV qword ptr [RBP + -0x30],RAX LEA R13,[RBP + -0x240] MOV RDI,R13 CALL 0x0019c30b CMP byte ptr [R13],0x7e JNZ 0x0019c4cd MOV R14,RAX LEA R15,[RBP + -0x23f] CMP byte ptr [R15],0x2f JNZ 0x0019c3ed LEA RBX,[0xd0a048] JMP 0x0019c446 LAB_0019c3ed: MOV RDI,R15 MOV ESI,0x2f CALL 0x00129440 MOV R12,RAX TEST RAX,RAX JNZ 0x0019c40d MOV RDI,R15 CALL 0x001d806c MOV R12,RAX LAB_0019c40d: MOV AL,byte ptr [R12] MOV byte ptr [RBP + -0x241],AL MOV byte ptr [R12],0x0 MOV RDI,R15 CALL 0x001295b0 MOV RBX,RAX MOV AL,byte ptr [RBP + -0x241] MOV byte ptr [R12],AL CALL 0x001298b0 TEST RBX,RBX JZ 0x0019c4cd ADD RBX,0x20 MOV R15,R12 LAB_0019c446: MOV R12,qword ptr [RBX] TEST R12,R12 JZ 0x0019c4cd ADD R14,R13 SUB R14,R15 MOV RDI,R12 CALL 0x00129350 MOV R13,RAX ADD RAX,R14 INC RAX CMP RAX,0x200 JA 0x0019c4cd TEST R13,R13 JZ 0x0019c482 XOR EAX,EAX CMP byte ptr [R12 + R13*0x1 + -0x1],0x2f SETZ AL SUB R13,RAX JMP 0x0019c485 LAB_0019c482: XOR R13D,R13D LAB_0019c485: INC R14 LEA RDI,[-0x240 + R13*0x1] ADD RDI,RBP CMP RDI,R15 JNC 0x0019c4a5 MOV RSI,R15 MOV RDX,R14 CALL 0x00129120 JMP 0x0019c4b6 LAB_0019c4a5: ADD RDI,R14 ADD R15,R14 MOV RSI,R15 MOV RDX,R14 CALL 0x001abbb4 LAB_0019c4b6: LEA RDI,[RBP + -0x240] MOV ECX,0x205 MOV RSI,R12 MOV RDX,R13 CALL 0x001294c0 LAB_0019c4cd: LEA RSI,[RBP + -0x240] MOV EDX,0x1ff MOV RBX,qword ptr [RBP + -0x250] MOV RDI,RBX CALL 0x001d80b4 MOV RCX,qword ptr FS:[0x28] CMP RCX,qword ptr [RBP + -0x30] JNZ 0x0019c50c SUB RAX,RBX ADD RSP,0x228 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET LAB_0019c50c: CALL 0x00129270
long unpack_dirname(long param_1) { char *pcVar1; long lVar2; char *__src; passwd *ppVar3; size_t sVar4; char **ppcVar5; char *__dest; long lVar6; char *__n; long in_FS_OFFSET; char acStack_48f [559]; code *pcStack_260; long local_258; char local_249; char local_248 [528]; long local_38; local_38 = *(long *)(in_FS_OFFSET + 0x28); pcStack_260 = (code *)0x19c3c9; local_258 = param_1; lVar2 = normalize_dirname(local_248); if (local_248[0] == '~') { pcVar1 = local_248 + 1; if (local_248[1] == '/') { ppcVar5 = (char **)&home_dir; __src = pcVar1; } else { pcStack_260 = (code *)0x19c3fa; __src = strchr(pcVar1,0x2f); if (__src == (char *)0x0) { pcStack_260 = (code *)0x19c40a; __src = (char *)strend(pcVar1); } local_249 = *__src; *__src = '\0'; pcStack_260 = (code *)0x19c424; ppVar3 = getpwnam(pcVar1); *__src = local_249; pcStack_260 = (code *)0x19c436; endpwent(); if (ppVar3 == (passwd *)0x0) goto LAB_0019c4cd; ppcVar5 = &ppVar3->pw_dir; } pcVar1 = *ppcVar5; if (pcVar1 != (char *)0x0) { pcStack_260 = (code *)0x19c45c; sVar4 = strlen(pcVar1); if (local_248 + sVar4 + (lVar2 - (long)__src) + 1 < (char *)0x201) { if (sVar4 == 0) { lVar6 = 0; } else { lVar6 = sVar4 - (pcVar1[sVar4 - 1] == '/'); } __n = local_248 + (lVar2 - (long)__src) + 1; __dest = local_248 + lVar6; if (__dest < __src) { pcStack_260 = (code *)0x19c4a3; memmove(__dest,__src,(size_t)__n); } else { pcStack_260 = (code *)0x19c4b6; bmove_upp(__dest + (long)__n,__src + (long)__n,__n); } pcStack_260 = (code *)0x19c4cd; __memmove_chk(local_248,pcVar1,lVar6,0x205); } } } LAB_0019c4cd: lVar2 = local_258; pcStack_260 = (code *)0x19c4e8; lVar6 = strmake(local_258,local_248,0x1ff); if (*(long *)(in_FS_OFFSET + 0x28) == local_38) { return lVar6 - lVar2; } /* WARNING: Subroutine does not return */ pcStack_260 = system_filename; __stack_chk_fail(); }
60,843
add_role_user_mapping(char const*, char const*, char const*)
eloqsql/sql/sql_acl.cc
static bool add_role_user_mapping(const char *uname, const char *hname, const char *rname) { ACL_USER_BASE *grantee= find_acl_user_base(uname, hname); ACL_ROLE *role= find_acl_role(rname); if (grantee == NULL || role == NULL) return 1; /* because all arrays are rebuilt completely, and counters were also reset, we can increment them here, and after the rebuild all counters will have correct values (equal to the number of roles granted). */ if (grantee->flags & IS_ROLE) ((ACL_ROLE*)grantee)->counter++; return add_role_user_mapping(grantee, role); }
O0
cpp
add_role_user_mapping(char const*, char const*, char const*): pushq %rbp movq %rsp, %rbp subq $0x30, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq %rdx, -0x20(%rbp) movq -0x10(%rbp), %rdi movq -0x18(%rbp), %rsi callq 0x930b10 movq %rax, -0x28(%rbp) movq -0x20(%rbp), %rdi callq 0x91db70 movq %rax, -0x30(%rbp) cmpq $0x0, -0x28(%rbp) je 0x939390 cmpq $0x0, -0x30(%rbp) jne 0x939396 movb $0x1, -0x1(%rbp) jmp 0x9393c7 movq -0x28(%rbp), %rax movzbl 0x10(%rax), %eax andq $0x1, %rax cmpq $0x0, %rax je 0x9393b5 movq -0x28(%rbp), %rax movl 0x58(%rax), %ecx addl $0x1, %ecx movl %ecx, 0x58(%rax) movq -0x28(%rbp), %rdi movq -0x30(%rbp), %rsi callq 0x927230 andb $0x1, %al movb %al, -0x1(%rbp) movb -0x1(%rbp), %al andb $0x1, %al addq $0x30, %rsp popq %rbp retq nopw %cs:(%rax,%rax)
_ZL21add_role_user_mappingPKcS0_S0_: push rbp mov rbp, rsp sub rsp, 30h mov [rbp+var_10], rdi mov [rbp+var_18], rsi mov [rbp+var_20], rdx mov rdi, [rbp+var_10]; char * mov rsi, [rbp+var_18]; char * call _ZL18find_acl_user_basePKcS0_; find_acl_user_base(char const*,char const*) mov [rbp+var_28], rax mov rdi, [rbp+var_20]; char * call _ZL13find_acl_rolePKc; find_acl_role(char const*) mov [rbp+var_30], rax cmp [rbp+var_28], 0 jz short loc_939390 cmp [rbp+var_30], 0 jnz short loc_939396 loc_939390: mov [rbp+var_1], 1 jmp short loc_9393C7 loc_939396: mov rax, [rbp+var_28] movzx eax, byte ptr [rax+10h] and rax, 1 cmp rax, 0 jz short loc_9393B5 mov rax, [rbp+var_28] mov ecx, [rax+58h] add ecx, 1 mov [rax+58h], ecx loc_9393B5: mov rdi, [rbp+var_28] mov rsi, [rbp+var_30] call _ZL21add_role_user_mappingP13ACL_USER_BASEP8ACL_ROLE; add_role_user_mapping(ACL_USER_BASE *,ACL_ROLE *) and al, 1 mov [rbp+var_1], al loc_9393C7: mov al, [rbp+var_1] and al, 1 add rsp, 30h pop rbp retn
bool add_role_user_mapping(const char *a1, const char *a2, const char *a3) { long long acl_role; // [rsp+0h] [rbp-30h] long long acl_user_base; // [rsp+8h] [rbp-28h] acl_user_base = find_acl_user_base(a1, a2); acl_role = find_acl_role(a3); if ( !acl_user_base || !acl_role ) return 1; if ( (*(_BYTE *)(acl_user_base + 16) & 1) != 0 ) ++*(_DWORD *)(acl_user_base + 88); return add_role_user_mapping(acl_user_base, acl_role); }
purge_log_get_error_code: PUSH RBP MOV RBP,RSP MOV dword ptr [RBP + -0x4],EDI MOV dword ptr [RBP + -0x8],0x0 MOV EAX,dword ptr [RBP + -0x4] ADD EAX,0x9 MOV ECX,EAX MOV qword ptr [RBP + -0x10],RCX SUB EAX,0x9 JA 0x009393cd MOV RAX,qword ptr [RBP + -0x10] LEA RCX,[0x15abc80] MOVSXD RAX,dword ptr [RCX + RAX*0x4] ADD RAX,RCX switchD: JMP RAX caseD_0: JMP 0x009393d4 caseD_ffffffff: MOV dword ptr [RBP + -0x8],0x55d JMP 0x009393d4 caseD_fffffffe: MOV dword ptr [RBP + -0x8],0x55e JMP 0x009393d4 caseD_fffffffd: MOV dword ptr [RBP + -0x8],0x55f JMP 0x009393d4 caseD_fffffffc: MOV dword ptr [RBP + -0x8],0x560 JMP 0x009393d4 caseD_fffffffa: MOV dword ptr [RBP + -0x8],0x411 JMP 0x009393d4 caseD_fffffff9: MOV dword ptr [RBP + -0x8],0x561 JMP 0x009393d4 caseD_fffffff8: MOV dword ptr [RBP + -0x8],0x562 JMP 0x009393d4 caseD_fffffff7: MOV dword ptr [RBP + -0x8],0x633 JMP 0x009393d4 caseD_fffffffb: MOV dword ptr [RBP + -0x8],0x563 LAB_009393d4: MOV EAX,dword ptr [RBP + -0x8] POP RBP RET
/* purge_log_get_error_code(int) */ int4 purge_log_get_error_code(int param_1) { int4 local_10; local_10 = 0; switch(param_1) { case 0: break; case -9: local_10 = 0x633; break; case -8: local_10 = 0x562; break; case -7: local_10 = 0x561; break; case -6: local_10 = 0x411; break; default: local_10 = 0x563; break; case -4: local_10 = 0x560; break; case -3: local_10 = 0x55f; break; case -2: local_10 = 0x55e; break; case -1: local_10 = 0x55d; } return local_10; }
60,844
HttpClient::init(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>> const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, bool, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>*)
llama.cpp/examples/run/run.cpp
int init(const std::string & url, const std::vector<std::string> & headers, const std::string & output_file, const bool progress, std::string * response_str = nullptr) { if (std::filesystem::exists(output_file)) { return 0; } std::string output_file_partial; curl = curl_easy_init(); if (!curl) { return 1; } progress_data data; File out; if (!output_file.empty()) { output_file_partial = output_file + ".partial"; if (!out.open(output_file_partial, "ab")) { printe("Failed to open file for writing\n"); return 1; } if (out.lock()) { printe("Failed to exclusively lock file\n"); return 1; } } set_write_options(response_str, out); data.file_size = set_resume_point(output_file_partial); set_progress_options(progress, data); set_headers(headers); CURLcode res = perform(url); if (res != CURLE_OK){ printe("Fetching resource '%s' failed: %s\n", url.c_str(), curl_easy_strerror(res)); return 1; } if (!output_file.empty()) { std::filesystem::rename(output_file_partial, output_file); } return 0; }
O3
cpp
HttpClient::init(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>> const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, bool, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>*): pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0xa8, %rsp movq %r9, %r13 movl %r8d, %ebp movq %rcx, %rbx movq %rdx, %r12 movq %rsi, 0x60(%rsp) movq %rdi, %r15 leaq 0x18(%rsp), %r14 movq %r14, %rdi movq %rcx, %rsi movl $0x2, %edx callq 0x248e2 movq %r14, %rdi callq 0x1d180 movq %rax, %r14 leaq 0x18(%rsp), %rdi callq 0x2495e testb %r14b, %r14b je 0x2fac8 movzbl %r14b, %eax xorl %r14d, %r14d cmpl $0xff, %eax jne 0x2fc83 leaq 0x50(%rsp), %rax movq %rax, -0x10(%rax) movq $0x0, -0x8(%rax) movb $0x0, (%rax) callq 0x1ddd0 movq %rax, (%r15) testq %rax, %rax je 0x2fc61 xorl %r14d, %r14d movq %r14, 0x68(%rsp) callq 0x1dd80 movq %rax, 0x70(%rsp) movb $0x0, 0x78(%rsp) movq %r14, 0x8(%rsp) movl $0xffffffff, 0x10(%rsp) # imm = 0xFFFFFFFF movq 0x8(%rbx), %rdx testq %rdx, %rdx je 0x2fba5 leaq 0x28(%rsp), %rax movq %rax, -0x10(%rax) movq (%rbx), %rsi addq %rsi, %rdx leaq 0x18(%rsp), %rdi callq 0x2398e leaq 0x9b386(%rip), %rsi # 0xcaec4 leaq 0x18(%rsp), %rdi callq 0x1d920 leaq 0x40(%rsp), %rdi leaq 0x18(%rsp), %r14 movq %r14, %rsi callq 0x1d720 movq (%r14), %rdi leaq 0x28(%rsp), %rax cmpq %rax, %rdi je 0x2fb74 movq 0x28(%rsp), %rsi incq %rsi callq 0x1d160 movq 0x40(%rsp), %rdi leaq 0xa39ab(%rip), %rsi # 0xd352b callq 0x1d800 movq %rax, 0x8(%rsp) testq %rax, %rax je 0x2fcb8 leaq 0x8(%rsp), %rdi callq 0x2fd92 testl %eax, %eax jne 0x2fcc1 leaq 0x8(%rsp), %rdx movq %r15, %rdi movq %r13, %rsi callq 0x2fdd4 leaq 0x40(%rsp), %rsi movq %r15, %rdi callq 0x2fe34 leaq 0x68(%rsp), %rdx movq %rax, (%rdx) movzbl %bpl, %esi movq %r15, %rdi callq 0x2fed8 movq %r15, %rdi movq %r12, %rsi callq 0x2ff28 movq %r15, %rdi movq 0x60(%rsp), %r14 movq %r14, %rsi callq 0x2ffa4 testl %eax, %eax jne 0x2fc98 xorl %r14d, %r14d cmpq $0x0, 0x8(%rbx) je 0x2fc55 leaq 0x18(%rsp), %rdi leaq 0x40(%rsp), %rsi movl $0x2, %edx callq 0x248e2 leaq 0x80(%rsp), %rdi movq %rbx, %rsi movl $0x2, %edx callq 0x248e2 leaq 0x18(%rsp), %rdi leaq 0x80(%rsp), %rsi callq 0x1d5a0 leaq 0x80(%rsp), %rdi callq 0x2495e leaq 0x18(%rsp), %rdi callq 0x2495e leaq 0x8(%rsp), %rdi callq 0x30002 jmp 0x2fc67 movl $0x1, %r14d movq 0x40(%rsp), %rdi leaq 0x50(%rsp), %rax cmpq %rax, %rdi je 0x2fc83 movq 0x50(%rsp), %rsi incq %rsi callq 0x1d160 movl %r14d, %eax addq $0xa8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq movq (%r14), %rbx movl %eax, %edi callq 0x1d5f0 leaq 0x9b266(%rip), %rdi # 0xcaf0f movq %rbx, %rsi movq %rax, %rdx xorl %eax, %eax callq 0x1e130 jmp 0x2fccf leaq 0x9b20e(%rip), %rdi # 0xcaecd jmp 0x2fcc8 leaq 0x9b226(%rip), %rdi # 0xcaeee xorl %eax, %eax callq 0x1e130 movl $0x1, %r14d jmp 0x2fc55 movq %rax, %rbx leaq 0x80(%rsp), %rdi callq 0x2495e jmp 0x2fcef movq %rax, %rbx leaq 0x18(%rsp), %rdi callq 0x2495e jmp 0x2fd39 jmp 0x2fd36 movq %rax, %rbx movq 0x18(%rsp), %rdi leaq 0x28(%rsp), %rax cmpq %rax, %rdi je 0x2fd39 movq 0x28(%rsp), %rsi incq %rsi callq 0x1d160 jmp 0x2fd39 jmp 0x2fd36 movq %rax, %rbx jmp 0x2fd43 jmp 0x2fd36 movq %rax, %rbx leaq 0x18(%rsp), %rdi callq 0x2495e jmp 0x2fd5f movq %rax, %rbx leaq 0x8(%rsp), %rdi callq 0x30002 movq 0x40(%rsp), %rdi leaq 0x50(%rsp), %rax cmpq %rax, %rdi je 0x2fd5f movq 0x50(%rsp), %rsi incq %rsi callq 0x1d160 movq %rbx, %rdi callq 0x1d8e0 nop
_ZN10HttpClient4initERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKSt6vectorIS5_SaIS5_EES7_bPS5_: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 0A8h mov r13, r9 mov ebp, r8d mov rbx, rcx mov r12, rdx mov [rsp+0D8h+var_78], rsi mov r15, rdi lea r14, [rsp+0D8h+var_C0] mov rdi, r14; this mov rsi, rcx; std::filesystem::__cxx11::path * mov edx, 2 call _ZNSt10filesystem7__cxx114pathC2INSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES1_EERKT_NS1_6formatE; std::filesystem::__cxx11::path::path<std::string,std::filesystem::__cxx11::path>(std::string const&,std::filesystem::__cxx11::path::format) mov rdi, r14; this call __ZNSt10filesystem6statusERKNS_7__cxx114pathE; std::filesystem::status(std::filesystem::__cxx11::path const&) mov r14, rax lea rdi, [rsp+0D8h+var_C0]; this call _ZNSt10filesystem7__cxx114pathD2Ev; std::filesystem::__cxx11::path::~path() test r14b, r14b jz short loc_2FAC8 movzx eax, r14b xor r14d, r14d cmp eax, 0FFh jnz loc_2FC83 loc_2FAC8: lea rax, [rsp+0D8h+var_88] mov [rax-10h], rax mov qword ptr [rax-8], 0 mov byte ptr [rax], 0 call _curl_easy_init mov [r15], rax test rax, rax jz loc_2FC61 xor r14d, r14d mov [rsp+0D8h+var_70], r14 call __ZNSt6chrono3_V212steady_clock3nowEv; std::chrono::_V2::steady_clock::now(void) mov [rsp+0D8h+var_68], rax mov [rsp+0D8h+var_60], 0 mov [rsp+0D8h+var_D0], r14 mov [rsp+0D8h+var_C8], 0FFFFFFFFh mov rdx, [rbx+8] test rdx, rdx jz loc_2FBA5 lea rax, [rsp+0D8h+var_B0] mov [rax-10h], rax mov rsi, [rbx] add rdx, rsi lea rdi, [rsp+0D8h+var_C0] call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIPcEEvT_S7_St20forward_iterator_tag; std::string::_M_construct<char *>(char *,char *,std::forward_iterator_tag) lea rsi, aPartial; ".partial" lea rdi, [rsp+0D8h+var_C0] call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendEPKc; std::string::append(char const*) lea rdi, [rsp+0D8h+var_98] lea r14, [rsp+0D8h+var_C0] mov rsi, r14 call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEaSEOS4_; std::string::operator=(std::string&&) mov rdi, [r14]; void * lea rax, [rsp+0D8h+var_B0] cmp rdi, rax jz short loc_2FB74 mov rsi, [rsp+0D8h+var_B0] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_2FB74: mov rdi, [rsp+0D8h+var_98] lea rsi, aVerticalTab+0Ah; "ab" call _ggml_fopen mov [rsp+0D8h+var_D0], rax test rax, rax jz loc_2FCB8 lea rdi, [rsp+0D8h+var_D0]; this call _ZN4File4lockEv; File::lock(void) test eax, eax jnz loc_2FCC1 loc_2FBA5: lea rdx, [rsp+0D8h+var_D0] mov rdi, r15 mov rsi, r13 call _ZN10HttpClient17set_write_optionsEPNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERK4File; HttpClient::set_write_options(std::string *,File const&) lea rsi, [rsp+0D8h+var_98] mov rdi, r15 call _ZN10HttpClient16set_resume_pointERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; HttpClient::set_resume_point(std::string const&) lea rdx, [rsp+0D8h+var_70] mov [rdx], rax movzx esi, bpl mov rdi, r15 call _ZN10HttpClient20set_progress_optionsEbR13progress_data; HttpClient::set_progress_options(bool,progress_data &) mov rdi, r15 mov rsi, r12 call _ZN10HttpClient11set_headersERKSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS6_EE; HttpClient::set_headers(std::vector<std::string> const&) mov rdi, r15 mov r14, [rsp+0D8h+var_78] mov rsi, r14 call _ZN10HttpClient7performERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; HttpClient::perform(std::string const&) test eax, eax jnz loc_2FC98 xor r14d, r14d cmp qword ptr [rbx+8], 0 jz short loc_2FC55 lea rdi, [rsp+0D8h+var_C0]; this lea rsi, [rsp+0D8h+var_98] mov edx, 2 call _ZNSt10filesystem7__cxx114pathC2INSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES1_EERKT_NS1_6formatE; std::filesystem::__cxx11::path::path<std::string,std::filesystem::__cxx11::path>(std::string const&,std::filesystem::__cxx11::path::format) lea rdi, [rsp+0D8h+var_58]; this mov rsi, rbx mov edx, 2 call _ZNSt10filesystem7__cxx114pathC2INSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES1_EERKT_NS1_6formatE; std::filesystem::__cxx11::path::path<std::string,std::filesystem::__cxx11::path>(std::string const&,std::filesystem::__cxx11::path::format) lea rdi, [rsp+0D8h+var_C0]; this lea rsi, [rsp+0D8h+var_58]; std::filesystem::__cxx11::path * call __ZNSt10filesystem6renameERKNS_7__cxx114pathES3_; std::filesystem::rename(std::filesystem::__cxx11::path const&,std::filesystem::__cxx11::path const&) lea rdi, [rsp+0D8h+var_58]; this call _ZNSt10filesystem7__cxx114pathD2Ev; std::filesystem::__cxx11::path::~path() lea rdi, [rsp+0D8h+var_C0]; this call _ZNSt10filesystem7__cxx114pathD2Ev; std::filesystem::__cxx11::path::~path() loc_2FC55: lea rdi, [rsp+0D8h+var_D0]; this call _ZN4FileD2Ev; File::~File() jmp short loc_2FC67 loc_2FC61: mov r14d, 1 loc_2FC67: mov rdi, [rsp+0D8h+var_98]; void * lea rax, [rsp+0D8h+var_88] cmp rdi, rax jz short loc_2FC83 mov rsi, [rsp+0D8h+var_88] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_2FC83: mov eax, r14d add rsp, 0A8h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn loc_2FC98: mov rbx, [r14] mov edi, eax call _curl_easy_strerror lea rdi, aFetchingResour; "Fetching resource '%s' failed: %s\n" mov rsi, rbx mov rdx, rax xor eax, eax call _ZL6printePKcz; printe(char const*,...) jmp short loc_2FCCF loc_2FCB8: lea rdi, aFailedToOpenFi; "Failed to open file for writing\n" jmp short loc_2FCC8 loc_2FCC1: lea rdi, aFailedToExclus; "Failed to exclusively lock file\n" loc_2FCC8: xor eax, eax call _ZL6printePKcz; printe(char const*,...) loc_2FCCF: mov r14d, 1 jmp loc_2FC55 mov rbx, rax lea rdi, [rsp+arg_78]; this call _ZNSt10filesystem7__cxx114pathD2Ev; std::filesystem::__cxx11::path::~path() jmp short loc_2FCEF mov rbx, rax loc_2FCEF: lea rdi, [rsp+arg_10]; this call _ZNSt10filesystem7__cxx114pathD2Ev; std::filesystem::__cxx11::path::~path() jmp short loc_2FD39 jmp short loc_2FD36 mov rbx, rax mov rdi, [rsp+arg_10]; void * lea rax, [rsp+arg_20] cmp rdi, rax jz short loc_2FD39 mov rsi, [rsp+arg_20] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) jmp short loc_2FD39 jmp short loc_2FD36 mov rbx, rax jmp short loc_2FD43 jmp short loc_2FD36 mov rbx, rax lea rdi, [rsp+arg_10]; this call _ZNSt10filesystem7__cxx114pathD2Ev; std::filesystem::__cxx11::path::~path() jmp short loc_2FD5F loc_2FD36: mov rbx, rax loc_2FD39: lea rdi, [rsp+arg_0]; this call _ZN4FileD2Ev; File::~File() loc_2FD43: mov rdi, [rsp+arg_38]; void * lea rax, [rsp+arg_48] cmp rdi, rax jz short loc_2FD5F mov rsi, [rsp+arg_48] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_2FD5F: mov rdi, rbx call __Unwind_Resume
long long HttpClient::init( long long *a1, long long *a2, long long a3, const std::filesystem::__cxx11::path *a4, unsigned __int8 a5, long long a6, __m128 a7, __m128 a8, __m128 a9, __m128 a10, double a11, double a12, __m128 a13, __m128 a14) { unsigned __int8 v19; // r14 int v20; // eax unsigned int v21; // r14d long long v22; // rax _BYTE *v23; // rdx long long v24; // rdx long long v25; // rcx long long v26; // r8 long long v27; // r9 __m128 v28; // xmm4 __m128 v29; // xmm5 long long *v30; // r14 unsigned int v31; // eax const std::filesystem::__cxx11::path *v32; // rdx long long v34; // rbx long long v35; // rax long long v36; // rcx long long v37; // r8 long long v38; // r9 __m128 v39; // xmm4 __m128 v40; // xmm5 const char *v41; // rdi char v42; // [rsp+0h] [rbp-D8h] long long v43; // [rsp+8h] [rbp-D0h] BYREF int v44; // [rsp+10h] [rbp-C8h] void *v45[2]; // [rsp+18h] [rbp-C0h] BYREF _QWORD v46[3]; // [rsp+28h] [rbp-B0h] BYREF void *v47[2]; // [rsp+40h] [rbp-98h] BYREF _QWORD v48[2]; // [rsp+50h] [rbp-88h] BYREF long long *v49; // [rsp+60h] [rbp-78h] long long v50; // [rsp+68h] [rbp-70h] long long v51; // [rsp+70h] [rbp-68h] char v52; // [rsp+78h] [rbp-60h] _BYTE v53[88]; // [rsp+80h] [rbp-58h] BYREF v49 = a2; std::filesystem::__cxx11::path::path<std::string,std::filesystem::__cxx11::path>( (std::filesystem::__cxx11::path *)v45, a4); v19 = std::filesystem::status((std::filesystem *)v45, a4); std::filesystem::__cxx11::path::~path((std::filesystem::__cxx11::path *)v45); if ( v19 ) { v20 = v19; v21 = 0; if ( v20 != 255 ) return v21; } v47[0] = v48; v47[1] = 0LL; LOBYTE(v48[0]) = 0; v22 = curl_easy_init(); *a1 = v22; if ( v22 ) { v50 = 0LL; v51 = std::chrono::_V2::steady_clock::now((std::chrono::_V2::steady_clock *)v45); v52 = 0; v43 = 0LL; v44 = -1; v23 = (_BYTE *)*((_QWORD *)a4 + 1); if ( v23 ) { v45[0] = v46; std::string::_M_construct<char *>((long long)v45, *(_BYTE **)a4, (long long)&v23[*(_QWORD *)a4]); std::string::append(v45, ".partial"); std::string::operator=(v47, v45); if ( v45[0] != v46 ) operator delete(v45[0], v46[0] + 1LL); v43 = ggml_fopen(v47[0], "ab"); if ( v43 ) { if ( !(unsigned int)File::lock((File *)&v43) ) goto LABEL_9; v41 = "Failed to exclusively lock file\n"; } else { v41 = "Failed to open file for writing\n"; } printe(v41, (long long)"ab", v24, v25, v26, v27, a7, a8, a9, a10, v28, v29, a13, a14, v42); goto LABEL_21; } LABEL_9: HttpClient::set_write_options(a1, a6, &v43); v50 = HttpClient::set_resume_point(a1, v47); HttpClient::set_progress_options(a1, a5); HttpClient::set_headers(a1, a3); v30 = v49; v31 = HttpClient::perform(a1, v49); if ( !v31 ) { v21 = 0; if ( *((_QWORD *)a4 + 1) ) { std::filesystem::__cxx11::path::path<std::string,std::filesystem::__cxx11::path>( (std::filesystem::__cxx11::path *)v45, v47); std::filesystem::__cxx11::path::path<std::string,std::filesystem::__cxx11::path>( (std::filesystem::__cxx11::path *)v53, a4); std::filesystem::rename((std::filesystem *)v45, (const std::filesystem::__cxx11::path *)v53, v32); std::filesystem::__cxx11::path::~path((std::filesystem::__cxx11::path *)v53); std::filesystem::__cxx11::path::~path((std::filesystem::__cxx11::path *)v45); } goto LABEL_12; } v34 = *v30; v35 = curl_easy_strerror(v31); printe("Fetching resource '%s' failed: %s\n", v34, v35, v36, v37, v38, a7, a8, a9, a10, v39, v40, a13, a14, v42); LABEL_21: v21 = 1; LABEL_12: File::~File((File *)&v43); goto LABEL_14; } v21 = 1; LABEL_14: if ( v47[0] != v48 ) operator delete(v47[0], v48[0] + 1LL); return v21; }
init: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0xa8 MOV R13,R9 MOV EBP,R8D MOV RBX,RCX MOV R12,RDX MOV qword ptr [RSP + 0x60],RSI MOV R15,RDI LEA R14,[RSP + 0x18] MOV RDI,R14 MOV RSI,RCX MOV EDX,0x2 CALL 0x001248e2 LAB_0012fa9c: MOV RDI,R14 CALL 0x0011d180 MOV R14,RAX LEA RDI,[RSP + 0x18] CALL 0x0012495e TEST R14B,R14B JZ 0x0012fac8 MOVZX EAX,R14B XOR R14D,R14D CMP EAX,0xff JNZ 0x0012fc83 LAB_0012fac8: LEA RAX,[RSP + 0x50] MOV qword ptr [RAX + -0x10],RAX MOV qword ptr [RAX + -0x8],0x0 MOV byte ptr [RAX],0x0 LAB_0012fadc: CALL 0x0011ddd0 MOV qword ptr [R15],RAX TEST RAX,RAX JZ 0x0012fc61 XOR R14D,R14D MOV qword ptr [RSP + 0x68],R14 CALL 0x0011dd80 MOV qword ptr [RSP + 0x70],RAX MOV byte ptr [RSP + 0x78],0x0 MOV qword ptr [RSP + 0x8],R14 MOV dword ptr [RSP + 0x10],0xffffffff MOV RDX,qword ptr [RBX + 0x8] TEST RDX,RDX JZ 0x0012fba5 LEA RAX,[RSP + 0x28] MOV qword ptr [RAX + -0x10],RAX MOV RSI,qword ptr [RBX] ADD RDX,RSI LAB_0012fb2d: LEA RDI,[RSP + 0x18] CALL 0x0012398e LAB_0012fb37: LEA RSI,[0x1caec4] LEA RDI,[RSP + 0x18] CALL 0x0011d920 LEA RDI,[RSP + 0x40] LEA R14,[RSP + 0x18] MOV RSI,R14 CALL 0x0011d720 MOV RDI,qword ptr [R14] LEA RAX,[RSP + 0x28] CMP RDI,RAX JZ 0x0012fb74 MOV RSI,qword ptr [RSP + 0x28] INC RSI CALL 0x0011d160 LAB_0012fb74: MOV RDI,qword ptr [RSP + 0x40] LAB_0012fb79: LEA RSI,[0x1d352b] CALL 0x0011d800 MOV qword ptr [RSP + 0x8],RAX TEST RAX,RAX JZ 0x0012fcb8 LEA RDI,[RSP + 0x8] CALL 0x0012fd92 TEST EAX,EAX JNZ 0x0012fcc1 LAB_0012fba5: LEA RDX,[RSP + 0x8] MOV RDI,R15 MOV RSI,R13 CALL 0x0012fdd4 LEA RSI,[RSP + 0x40] MOV RDI,R15 CALL 0x0012fe34 LEA RDX,[RSP + 0x68] MOV qword ptr [RDX],RAX MOVZX ESI,BPL MOV RDI,R15 CALL 0x0012fed8 MOV RDI,R15 MOV RSI,R12 CALL 0x0012ff28 LAB_0012fbe1: MOV RDI,R15 MOV R14,qword ptr [RSP + 0x60] MOV RSI,R14 CALL 0x0012ffa4 TEST EAX,EAX JNZ 0x0012fc98 XOR R14D,R14D CMP qword ptr [RBX + 0x8],0x0 JZ 0x0012fc55 LAB_0012fc03: LEA RDI,[RSP + 0x18] LEA RSI,[RSP + 0x40] MOV EDX,0x2 CALL 0x001248e2 LAB_0012fc17: LEA RDI,[RSP + 0x80] MOV RSI,RBX MOV EDX,0x2 CALL 0x001248e2 LAB_0012fc2c: LEA RDI,[RSP + 0x18] LEA RSI,[RSP + 0x80] CALL 0x0011d5a0 LEA RDI,[RSP + 0x80] CALL 0x0012495e LEA RDI,[RSP + 0x18] CALL 0x0012495e LAB_0012fc55: LEA RDI,[RSP + 0x8] CALL 0x00130002 JMP 0x0012fc67 LAB_0012fc61: MOV R14D,0x1 LAB_0012fc67: MOV RDI,qword ptr [RSP + 0x40] LEA RAX,[RSP + 0x50] CMP RDI,RAX JZ 0x0012fc83 MOV RSI,qword ptr [RSP + 0x50] INC RSI CALL 0x0011d160 LAB_0012fc83: MOV EAX,R14D ADD RSP,0xa8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET LAB_0012fc98: MOV RBX,qword ptr [R14] LAB_0012fc9b: MOV EDI,EAX CALL 0x0011d5f0 LAB_0012fca2: LEA RDI,[0x1caf0f] MOV RSI,RBX MOV RDX,RAX XOR EAX,EAX CALL 0x0011e130 JMP 0x0012fccf LAB_0012fcb8: LEA RDI,[0x1caecd] JMP 0x0012fcc8 LAB_0012fcc1: LEA RDI,[0x1caeee] LAB_0012fcc8: XOR EAX,EAX CALL 0x0011e130 LAB_0012fccf: MOV R14D,0x1 JMP 0x0012fc55
/* HttpClient::init(std::__cxx11::string const&, std::vector<std::__cxx11::string, std::allocator<std::__cxx11::string > > const&, std::__cxx11::string const&, bool, std::__cxx11::string*) */ int8 __thiscall HttpClient::init(HttpClient *this,string *param_1,vector *param_2,string *param_3,bool param_4, string *param_5) { string *psVar1; char cVar2; int iVar3; long lVar4; int8 uVar5; char *pcVar6; int8 uVar7; long local_d0; int4 local_c8; long *local_c0 [2]; long local_b0 [3]; int1 *local_98; int8 local_90; int1 local_88; int7 uStack_87; string *local_78; int8 local_70; int8 local_68; int1 local_60; path local_58 [40]; local_78 = param_1; std::filesystem::__cxx11::path::path<std::__cxx11::string,std::filesystem::__cxx11::path> ((path *)local_c0,param_3,2); /* try { // try from 0012fa9c to 0012faa3 has its CatchHandler @ 0012fd27 */ cVar2 = std::filesystem::status((path *)local_c0); std::filesystem::__cxx11::path::~path((path *)local_c0); if ((cVar2 != '\0') && (cVar2 != -1)) { return 0; } local_98 = &local_88; local_90 = 0; local_88 = 0; /* try { // try from 0012fadc to 0012fae0 has its CatchHandler @ 0012fd20 */ lVar4 = curl_easy_init(); *(long *)this = lVar4; if (lVar4 == 0) { uVar7 = 1; goto LAB_0012fc67; } local_70 = 0; local_68 = std::chrono::_V2::steady_clock::now(); local_60 = 0; local_d0 = 0; local_c8 = 0xffffffff; if (*(long *)(param_3 + 8) == 0) { LAB_0012fba5: set_write_options(this,param_5,(File *)&local_d0); local_70 = set_resume_point(this,(string *)&local_98); set_progress_options(this,param_4,(progress_data *)&local_70); set_headers(this,param_2); psVar1 = local_78; /* try { // try from 0012fbe1 to 0012fbf0 has its CatchHandler @ 0012fd25 */ iVar3 = perform(this,local_78); if (iVar3 != 0) { uVar7 = *(int8 *)psVar1; /* try { // try from 0012fc9b to 0012fca1 has its CatchHandler @ 0012fd25 */ uVar5 = curl_easy_strerror(iVar3); printe("Fetching resource \'%s\' failed: %s\n",uVar7,uVar5); goto LAB_0012fccf; } uVar7 = 0; if (*(long *)(param_3 + 8) != 0) { /* try { // try from 0012fc03 to 0012fc16 has its CatchHandler @ 0012fcfb */ std::filesystem::__cxx11::path::path<std::__cxx11::string,std::filesystem::__cxx11::path> ((path *)local_c0,&local_98,2); /* try { // try from 0012fc17 to 0012fc2b has its CatchHandler @ 0012fcec */ std::filesystem::__cxx11::path::path<std::__cxx11::string,std::filesystem::__cxx11::path> (local_58,param_3,2); /* try { // try from 0012fc2c to 0012fc3d has its CatchHandler @ 0012fcda */ std::filesystem::rename((path *)local_c0,local_58); std::filesystem::__cxx11::path::~path(local_58); std::filesystem::__cxx11::path::~path((path *)local_c0); } } else { local_c0[0] = local_b0; /* try { // try from 0012fb2d to 0012fb36 has its CatchHandler @ 0012fd1e */ std::__cxx11::string::_M_construct<char*> (local_c0,*(long *)param_3,*(long *)(param_3 + 8) + *(long *)param_3); /* try { // try from 0012fb37 to 0012fb47 has its CatchHandler @ 0012fcfd */ std::__cxx11::string::append((char *)local_c0); std::__cxx11::string::operator=((string *)&local_98,(string *)local_c0); if (local_c0[0] != local_b0) { operator_delete(local_c0[0],local_b0[0] + 1); } /* try { // try from 0012fb79 to 0012fbe0 has its CatchHandler @ 0012fd36 */ local_d0 = ggml_fopen(local_98,"ab"); if (local_d0 == 0) { pcVar6 = "Failed to open file for writing\n"; } else { iVar3 = File::lock((File *)&local_d0); if (iVar3 == 0) goto LAB_0012fba5; pcVar6 = "Failed to exclusively lock file\n"; } printe(pcVar6); LAB_0012fccf: uVar7 = 1; } File::~File((File *)&local_d0); LAB_0012fc67: if (local_98 != &local_88) { operator_delete(local_98,CONCAT71(uStack_87,local_88) + 1); } return uVar7; }
60,845
heap_rprev
eloqsql/storage/heap/hp_rprev.c
int heap_rprev(HP_INFO *info, uchar *record) { uchar *pos; HP_SHARE *share=info->s; HP_KEYDEF *keyinfo; DBUG_ENTER("heap_rprev"); if (info->lastinx < 0) DBUG_RETURN(my_errno=HA_ERR_WRONG_INDEX); keyinfo = share->keydef + info->lastinx; if (keyinfo->algorithm == HA_KEY_ALG_BTREE) { heap_rb_param custom_arg; /* If no active record and last was not deleted */ if (!(info->update & (HA_STATE_AKTIV | HA_STATE_NO_KEY | HA_STATE_DELETED))) { if (info->update & HA_STATE_PREV_FOUND) pos= 0; /* Can't search before first row */ else { /* Last was 'next' after last record; search after last record */ pos= tree_search_edge(&keyinfo->rb_tree, info->parents, &info->last_pos, offsetof(TREE_ELEMENT, right)); } } else if (info->last_pos) pos = tree_search_next(&keyinfo->rb_tree, &info->last_pos, offsetof(TREE_ELEMENT, right), offsetof(TREE_ELEMENT, left)); else { custom_arg.keyseg = keyinfo->seg; custom_arg.key_length = keyinfo->length; custom_arg.search_flag = SEARCH_SAME; info->last_find_flag= HA_READ_KEY_OR_PREV; pos = tree_search_key(&keyinfo->rb_tree, info->lastkey, info->parents, &info->last_pos, info->last_find_flag, &custom_arg); } if (pos) { memcpy(&pos, pos + (*keyinfo->get_key_length)(keyinfo, pos), sizeof(uchar*)); info->current_ptr = pos; } else { my_errno = HA_ERR_KEY_NOT_FOUND; } } else { if (info->current_ptr || (info->update & HA_STATE_NEXT_FOUND)) { if ((info->update & HA_STATE_DELETED)) pos= hp_search(info, share->keydef + info->lastinx, info->lastkey, 3); else pos= hp_search(info, share->keydef + info->lastinx, info->lastkey, 2); } else { pos=0; /* Read next after last */ my_errno=HA_ERR_KEY_NOT_FOUND; } } if (!pos) { info->update=HA_STATE_PREV_FOUND; /* For heap_rprev */ if (my_errno == HA_ERR_KEY_NOT_FOUND) my_errno=HA_ERR_END_OF_FILE; DBUG_RETURN(my_errno); } memcpy(record,pos,(size_t) share->reclength); info->update=HA_STATE_AKTIV | HA_STATE_PREV_FOUND; DBUG_RETURN(0); }
O0
c
heap_rprev: pushq %rbp movq %rsp, %rbp subq $0x50, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq -0x10(%rbp), %rax movq (%rax), %rax movq %rax, -0x28(%rbp) movq -0x10(%rbp), %rax cmpl $0x0, 0x28(%rax) jge 0x2c22e jmp 0x2c217 callq 0x31370 movl $0x7c, (%rax) movl $0x7c, -0x4(%rbp) jmp 0x2c4ba movq -0x28(%rbp), %rax movq 0x98(%rax), %rax movq -0x10(%rbp), %rcx movslq 0x28(%rcx), %rcx imulq $0x368, %rcx, %rcx # imm = 0x368 addq %rcx, %rax movq %rax, -0x30(%rbp) movq -0x30(%rbp), %rax movzbl 0xc(%rax), %eax cmpl $0x1, %eax jne 0x2c3a6 movq -0x10(%rbp), %rax movl 0x38(%rax), %eax andl $0x4a, %eax cmpl $0x0, %eax jne 0x2c2b9 movq -0x10(%rbp), %rax movl 0x38(%rax), %eax andl $0x20, %eax cmpl $0x0, %eax je 0x2c288 movq $0x0, -0x20(%rbp) jmp 0x2c2b4 movq -0x30(%rbp), %rdi addq $0xb8, %rdi movq -0x10(%rbp), %rsi addq $0x58, %rsi movq -0x10(%rbp), %rdx addq $0x260, %rdx # imm = 0x260 movl $0x8, %ecx callq 0x36160 movq %rax, -0x20(%rbp) jmp 0x2c354 movq -0x10(%rbp), %rax cmpq $0x0, 0x260(%rax) je 0x2c2ef movq -0x30(%rbp), %rdi addq $0xb8, %rdi movq -0x10(%rbp), %rsi addq $0x260, %rsi # imm = 0x260 movl $0x8, %edx xorl %ecx, %ecx callq 0x36240 movq %rax, -0x20(%rbp) jmp 0x2c352 movq -0x30(%rbp), %rax movq 0x10(%rax), %rax movq %rax, -0x40(%rbp) movq -0x30(%rbp), %rax movl 0x8(%rax), %eax movl %eax, -0x38(%rbp) movl $0x4, -0x34(%rbp) movq -0x10(%rbp), %rax movl $0x2, 0x50(%rax) movq -0x30(%rbp), %rdi addq $0xb8, %rdi movq -0x10(%rbp), %rax movq 0x40(%rax), %rsi movq -0x10(%rbp), %rdx addq $0x58, %rdx movq -0x10(%rbp), %rcx addq $0x260, %rcx # imm = 0x260 movq -0x10(%rbp), %rax movl 0x50(%rax), %r8d leaq -0x40(%rbp), %r9 callq 0x35e70 movq %rax, -0x20(%rbp) jmp 0x2c354 cmpq $0x0, -0x20(%rbp) je 0x2c396 movq -0x20(%rbp), %rax movq %rax, -0x48(%rbp) movq -0x30(%rbp), %rax movq 0x360(%rax), %rax movq -0x30(%rbp), %rdi movq -0x20(%rbp), %rsi callq *%rax movl %eax, %ecx movq -0x48(%rbp), %rax movl %ecx, %ecx movq (%rax,%rcx), %rax movq %rax, -0x20(%rbp) movq -0x20(%rbp), %rcx movq -0x10(%rbp), %rax movq %rcx, 0x8(%rax) jmp 0x2c3a1 callq 0x31370 movl $0x78, (%rax) jmp 0x2c45a movq -0x10(%rbp), %rax cmpq $0x0, 0x8(%rax) jne 0x2c3c4 movq -0x10(%rbp), %rax movl 0x38(%rax), %eax andl $0x10, %eax cmpl $0x0, %eax je 0x2c445 movq -0x10(%rbp), %rax movl 0x38(%rax), %eax andl $0x8, %eax cmpl $0x0, %eax je 0x2c40c movq -0x10(%rbp), %rdi movq -0x28(%rbp), %rax movq 0x98(%rax), %rsi movq -0x10(%rbp), %rax movslq 0x28(%rax), %rax imulq $0x368, %rax, %rax # imm = 0x368 addq %rax, %rsi movq -0x10(%rbp), %rax movq 0x40(%rax), %rdx movl $0x3, %ecx callq 0x29380 movq %rax, -0x20(%rbp) jmp 0x2c443 movq -0x10(%rbp), %rdi movq -0x28(%rbp), %rax movq 0x98(%rax), %rsi movq -0x10(%rbp), %rax movslq 0x28(%rax), %rax imulq $0x368, %rax, %rax # imm = 0x368 addq %rax, %rsi movq -0x10(%rbp), %rax movq 0x40(%rax), %rdx movl $0x2, %ecx callq 0x29380 movq %rax, -0x20(%rbp) jmp 0x2c458 movq $0x0, -0x20(%rbp) callq 0x31370 movl $0x78, (%rax) jmp 0x2c45a cmpq $0x0, -0x20(%rbp) jne 0x2c48f movq -0x10(%rbp), %rax movl $0x20, 0x38(%rax) callq 0x31370 cmpl $0x78, (%rax) jne 0x2c481 callq 0x31370 movl $0x89, (%rax) jmp 0x2c483 callq 0x31370 movl (%rax), %eax movl %eax, -0x4(%rbp) jmp 0x2c4ba movq -0x18(%rbp), %rdi movq -0x20(%rbp), %rsi movq -0x28(%rbp), %rax movl 0xf4(%rax), %eax movl %eax, %edx callq 0x24200 movq -0x10(%rbp), %rax movl $0x22, 0x38(%rax) movl $0x0, -0x4(%rbp) movl -0x4(%rbp), %eax addq $0x50, %rsp popq %rbp retq nopw %cs:(%rax,%rax) nopl (%rax)
heap_rprev: push rbp mov rbp, rsp sub rsp, 50h mov [rbp+var_10], rdi mov [rbp+var_18], rsi mov rax, [rbp+var_10] mov rax, [rax] mov [rbp+var_28], rax mov rax, [rbp+var_10] cmp dword ptr [rax+28h], 0 jge short loc_2C22E jmp short $+2 loc_2C217: call _my_thread_var mov dword ptr [rax], 7Ch ; '|' mov [rbp+var_4], 7Ch ; '|' jmp loc_2C4BA loc_2C22E: mov rax, [rbp+var_28] mov rax, [rax+98h] mov rcx, [rbp+var_10] movsxd rcx, dword ptr [rcx+28h] imul rcx, 368h add rax, rcx mov [rbp+var_30], rax mov rax, [rbp+var_30] movzx eax, byte ptr [rax+0Ch] cmp eax, 1 jnz loc_2C3A6 mov rax, [rbp+var_10] mov eax, [rax+38h] and eax, 4Ah cmp eax, 0 jnz short loc_2C2B9 mov rax, [rbp+var_10] mov eax, [rax+38h] and eax, 20h cmp eax, 0 jz short loc_2C288 mov [rbp+var_20], 0 jmp short loc_2C2B4 loc_2C288: mov rdi, [rbp+var_30] add rdi, 0B8h mov rsi, [rbp+var_10] add rsi, 58h ; 'X' mov rdx, [rbp+var_10] add rdx, 260h mov ecx, 8 call tree_search_edge mov [rbp+var_20], rax loc_2C2B4: jmp loc_2C354 loc_2C2B9: mov rax, [rbp+var_10] cmp qword ptr [rax+260h], 0 jz short loc_2C2EF mov rdi, [rbp+var_30] add rdi, 0B8h mov rsi, [rbp+var_10] add rsi, 260h mov edx, 8 xor ecx, ecx call tree_search_next mov [rbp+var_20], rax jmp short loc_2C352 loc_2C2EF: mov rax, [rbp+var_30] mov rax, [rax+10h] mov [rbp+var_40], rax mov rax, [rbp+var_30] mov eax, [rax+8] mov [rbp+var_38], eax mov [rbp+var_34], 4 mov rax, [rbp+var_10] mov dword ptr [rax+50h], 2 mov rdi, [rbp+var_30] add rdi, 0B8h mov rax, [rbp+var_10] mov rsi, [rax+40h] mov rdx, [rbp+var_10] add rdx, 58h ; 'X' mov rcx, [rbp+var_10] add rcx, 260h mov rax, [rbp+var_10] mov r8d, [rax+50h] lea r9, [rbp+var_40] call tree_search_key mov [rbp+var_20], rax loc_2C352: jmp short $+2 loc_2C354: cmp [rbp+var_20], 0 jz short loc_2C396 mov rax, [rbp+var_20] mov [rbp+var_48], rax mov rax, [rbp+var_30] mov rax, [rax+360h] mov rdi, [rbp+var_30] mov rsi, [rbp+var_20] call rax mov ecx, eax mov rax, [rbp+var_48] mov ecx, ecx mov rax, [rax+rcx] mov [rbp+var_20], rax mov rcx, [rbp+var_20] mov rax, [rbp+var_10] mov [rax+8], rcx jmp short loc_2C3A1 loc_2C396: call _my_thread_var mov dword ptr [rax], 78h ; 'x' loc_2C3A1: jmp loc_2C45A loc_2C3A6: mov rax, [rbp+var_10] cmp qword ptr [rax+8], 0 jnz short loc_2C3C4 mov rax, [rbp+var_10] mov eax, [rax+38h] and eax, 10h cmp eax, 0 jz loc_2C445 loc_2C3C4: mov rax, [rbp+var_10] mov eax, [rax+38h] and eax, 8 cmp eax, 0 jz short loc_2C40C mov rdi, [rbp+var_10] mov rax, [rbp+var_28] mov rsi, [rax+98h] mov rax, [rbp+var_10] movsxd rax, dword ptr [rax+28h] imul rax, 368h add rsi, rax mov rax, [rbp+var_10] mov rdx, [rax+40h] mov ecx, 3 call hp_search mov [rbp+var_20], rax jmp short loc_2C443 loc_2C40C: mov rdi, [rbp+var_10] mov rax, [rbp+var_28] mov rsi, [rax+98h] mov rax, [rbp+var_10] movsxd rax, dword ptr [rax+28h] imul rax, 368h add rsi, rax mov rax, [rbp+var_10] mov rdx, [rax+40h] mov ecx, 2 call hp_search mov [rbp+var_20], rax loc_2C443: jmp short loc_2C458 loc_2C445: mov [rbp+var_20], 0 call _my_thread_var mov dword ptr [rax], 78h ; 'x' loc_2C458: jmp short $+2 loc_2C45A: cmp [rbp+var_20], 0 jnz short loc_2C48F mov rax, [rbp+var_10] mov dword ptr [rax+38h], 20h ; ' ' call _my_thread_var cmp dword ptr [rax], 78h ; 'x' jnz short loc_2C481 call _my_thread_var mov dword ptr [rax], 89h loc_2C481: jmp short $+2 loc_2C483: call _my_thread_var mov eax, [rax] mov [rbp+var_4], eax jmp short loc_2C4BA loc_2C48F: mov rdi, [rbp+var_18] mov rsi, [rbp+var_20] mov rax, [rbp+var_28] mov eax, [rax+0F4h] mov edx, eax call _memcpy mov rax, [rbp+var_10] mov dword ptr [rax+38h], 22h ; '"' mov [rbp+var_4], 0 loc_2C4BA: mov eax, [rbp+var_4] add rsp, 50h pop rbp retn
long long heap_rprev(long long *a1, long long a2) { long long v3; // [rsp+8h] [rbp-48h] long long v4; // [rsp+10h] [rbp-40h] BYREF int v5; // [rsp+18h] [rbp-38h] int v6; // [rsp+1Ch] [rbp-34h] long long v7; // [rsp+20h] [rbp-30h] long long v8; // [rsp+28h] [rbp-28h] long long v9; // [rsp+30h] [rbp-20h] long long v10; // [rsp+38h] [rbp-18h] _QWORD *v11; // [rsp+40h] [rbp-10h] v11 = a1; v10 = a2; v8 = *a1; if ( *((int *)a1 + 10) >= 0 ) { v7 = 872LL * *((int *)v11 + 10) + *(_QWORD *)(v8 + 152); if ( *(_BYTE *)(v7 + 12) == 1 ) { if ( (v11[7] & 0x4A) != 0 ) { if ( v11[76] ) { v9 = tree_search_next(v7 + 184, v11 + 76, 8LL, 0LL); } else { v4 = *(_QWORD *)(v7 + 16); v5 = *(_DWORD *)(v7 + 8); v6 = 4; *((_DWORD *)v11 + 20) = 2; v9 = tree_search_key(v7 + 184, v11[8], v11 + 11, v11 + 76, *((unsigned int *)v11 + 20), &v4); } } else if ( (v11[7] & 0x20) != 0 ) { v9 = 0LL; } else { v9 = tree_search_edge(v7 + 184, v11 + 11, v11 + 76, 8LL); } if ( v9 ) { v3 = v9; v9 = *(_QWORD *)(v3 + (*(unsigned int ( **)(long long, long long))(v7 + 864))(v7, v9)); v11[1] = v9; } else { *(_DWORD *)my_thread_var() = 120; } } else if ( v11[1] || (v11[7] & 0x10) != 0 ) { if ( (v11[7] & 8) != 0 ) v9 = hp_search(v11, 872LL * *((int *)v11 + 10) + *(_QWORD *)(v8 + 152), v11[8], 3); else v9 = hp_search(v11, 872LL * *((int *)v11 + 10) + *(_QWORD *)(v8 + 152), v11[8], 2); } else { v9 = 0LL; *(_DWORD *)my_thread_var() = 120; } if ( v9 ) { memcpy(v10, v9, *(unsigned int *)(v8 + 244)); *((_DWORD *)v11 + 14) = 34; return 0; } else { *((_DWORD *)v11 + 14) = 32; if ( *(_DWORD *)my_thread_var() == 120 ) *(_DWORD *)my_thread_var() = 137; return *(unsigned int *)my_thread_var(); } } else { *(_DWORD *)my_thread_var() = 124; return 124; } }
heap_rprev: PUSH RBP MOV RBP,RSP SUB RSP,0x50 MOV qword ptr [RBP + -0x10],RDI MOV qword ptr [RBP + -0x18],RSI MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX] MOV qword ptr [RBP + -0x28],RAX MOV RAX,qword ptr [RBP + -0x10] CMP dword ptr [RAX + 0x28],0x0 JGE 0x0012c22e JMP 0x0012c217 LAB_0012c217: CALL 0x00131370 MOV dword ptr [RAX],0x7c MOV dword ptr [RBP + -0x4],0x7c JMP 0x0012c4ba LAB_0012c22e: MOV RAX,qword ptr [RBP + -0x28] MOV RAX,qword ptr [RAX + 0x98] MOV RCX,qword ptr [RBP + -0x10] MOVSXD RCX,dword ptr [RCX + 0x28] IMUL RCX,RCX,0x368 ADD RAX,RCX MOV qword ptr [RBP + -0x30],RAX MOV RAX,qword ptr [RBP + -0x30] MOVZX EAX,byte ptr [RAX + 0xc] CMP EAX,0x1 JNZ 0x0012c3a6 MOV RAX,qword ptr [RBP + -0x10] MOV EAX,dword ptr [RAX + 0x38] AND EAX,0x4a CMP EAX,0x0 JNZ 0x0012c2b9 MOV RAX,qword ptr [RBP + -0x10] MOV EAX,dword ptr [RAX + 0x38] AND EAX,0x20 CMP EAX,0x0 JZ 0x0012c288 MOV qword ptr [RBP + -0x20],0x0 JMP 0x0012c2b4 LAB_0012c288: MOV RDI,qword ptr [RBP + -0x30] ADD RDI,0xb8 MOV RSI,qword ptr [RBP + -0x10] ADD RSI,0x58 MOV RDX,qword ptr [RBP + -0x10] ADD RDX,0x260 MOV ECX,0x8 CALL 0x00136160 MOV qword ptr [RBP + -0x20],RAX LAB_0012c2b4: JMP 0x0012c354 LAB_0012c2b9: MOV RAX,qword ptr [RBP + -0x10] CMP qword ptr [RAX + 0x260],0x0 JZ 0x0012c2ef MOV RDI,qword ptr [RBP + -0x30] ADD RDI,0xb8 MOV RSI,qword ptr [RBP + -0x10] ADD RSI,0x260 MOV EDX,0x8 XOR ECX,ECX CALL 0x00136240 MOV qword ptr [RBP + -0x20],RAX JMP 0x0012c352 LAB_0012c2ef: MOV RAX,qword ptr [RBP + -0x30] MOV RAX,qword ptr [RAX + 0x10] MOV qword ptr [RBP + -0x40],RAX MOV RAX,qword ptr [RBP + -0x30] MOV EAX,dword ptr [RAX + 0x8] MOV dword ptr [RBP + -0x38],EAX MOV dword ptr [RBP + -0x34],0x4 MOV RAX,qword ptr [RBP + -0x10] MOV dword ptr [RAX + 0x50],0x2 MOV RDI,qword ptr [RBP + -0x30] ADD RDI,0xb8 MOV RAX,qword ptr [RBP + -0x10] MOV RSI,qword ptr [RAX + 0x40] MOV RDX,qword ptr [RBP + -0x10] ADD RDX,0x58 MOV RCX,qword ptr [RBP + -0x10] ADD RCX,0x260 MOV RAX,qword ptr [RBP + -0x10] MOV R8D,dword ptr [RAX + 0x50] LEA R9,[RBP + -0x40] CALL 0x00135e70 MOV qword ptr [RBP + -0x20],RAX LAB_0012c352: JMP 0x0012c354 LAB_0012c354: CMP qword ptr [RBP + -0x20],0x0 JZ 0x0012c396 MOV RAX,qword ptr [RBP + -0x20] MOV qword ptr [RBP + -0x48],RAX MOV RAX,qword ptr [RBP + -0x30] MOV RAX,qword ptr [RAX + 0x360] MOV RDI,qword ptr [RBP + -0x30] MOV RSI,qword ptr [RBP + -0x20] CALL RAX MOV ECX,EAX MOV RAX,qword ptr [RBP + -0x48] MOV ECX,ECX MOV RAX,qword ptr [RAX + RCX*0x1] MOV qword ptr [RBP + -0x20],RAX MOV RCX,qword ptr [RBP + -0x20] MOV RAX,qword ptr [RBP + -0x10] MOV qword ptr [RAX + 0x8],RCX JMP 0x0012c3a1 LAB_0012c396: CALL 0x00131370 MOV dword ptr [RAX],0x78 LAB_0012c3a1: JMP 0x0012c45a LAB_0012c3a6: MOV RAX,qword ptr [RBP + -0x10] CMP qword ptr [RAX + 0x8],0x0 JNZ 0x0012c3c4 MOV RAX,qword ptr [RBP + -0x10] MOV EAX,dword ptr [RAX + 0x38] AND EAX,0x10 CMP EAX,0x0 JZ 0x0012c445 LAB_0012c3c4: MOV RAX,qword ptr [RBP + -0x10] MOV EAX,dword ptr [RAX + 0x38] AND EAX,0x8 CMP EAX,0x0 JZ 0x0012c40c MOV RDI,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RBP + -0x28] MOV RSI,qword ptr [RAX + 0x98] MOV RAX,qword ptr [RBP + -0x10] MOVSXD RAX,dword ptr [RAX + 0x28] IMUL RAX,RAX,0x368 ADD RSI,RAX MOV RAX,qword ptr [RBP + -0x10] MOV RDX,qword ptr [RAX + 0x40] MOV ECX,0x3 CALL 0x00129380 MOV qword ptr [RBP + -0x20],RAX JMP 0x0012c443 LAB_0012c40c: MOV RDI,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RBP + -0x28] MOV RSI,qword ptr [RAX + 0x98] MOV RAX,qword ptr [RBP + -0x10] MOVSXD RAX,dword ptr [RAX + 0x28] IMUL RAX,RAX,0x368 ADD RSI,RAX MOV RAX,qword ptr [RBP + -0x10] MOV RDX,qword ptr [RAX + 0x40] MOV ECX,0x2 CALL 0x00129380 MOV qword ptr [RBP + -0x20],RAX LAB_0012c443: JMP 0x0012c458 LAB_0012c445: MOV qword ptr [RBP + -0x20],0x0 CALL 0x00131370 MOV dword ptr [RAX],0x78 LAB_0012c458: JMP 0x0012c45a LAB_0012c45a: CMP qword ptr [RBP + -0x20],0x0 JNZ 0x0012c48f MOV RAX,qword ptr [RBP + -0x10] MOV dword ptr [RAX + 0x38],0x20 CALL 0x00131370 CMP dword ptr [RAX],0x78 JNZ 0x0012c481 CALL 0x00131370 MOV dword ptr [RAX],0x89 LAB_0012c481: JMP 0x0012c483 LAB_0012c483: CALL 0x00131370 MOV EAX,dword ptr [RAX] MOV dword ptr [RBP + -0x4],EAX JMP 0x0012c4ba LAB_0012c48f: MOV RDI,qword ptr [RBP + -0x18] MOV RSI,qword ptr [RBP + -0x20] MOV RAX,qword ptr [RBP + -0x28] MOV EAX,dword ptr [RAX + 0xf4] MOV EDX,EAX CALL 0x00124200 MOV RAX,qword ptr [RBP + -0x10] MOV dword ptr [RAX + 0x38],0x22 MOV dword ptr [RBP + -0x4],0x0 LAB_0012c4ba: MOV EAX,dword ptr [RBP + -0x4] ADD RSP,0x50 POP RBP RET
int4 heap_rprev(long *param_1,void *param_2) { void *pvVar1; uint uVar2; int4 *puVar3; int *piVar4; int8 local_48; int4 local_40; int4 local_3c; long local_38; long local_30; void *local_28; void *local_20; long *local_18; int4 local_c; local_30 = *param_1; local_20 = param_2; local_18 = param_1; if ((int)param_1[5] < 0) { puVar3 = (int4 *)_my_thread_var(); *puVar3 = 0x7c; local_c = 0x7c; } else { local_38 = *(long *)(local_30 + 0x98) + (long)(int)param_1[5] * 0x368; if (*(char *)(local_38 + 0xc) == '\x01') { if ((*(uint *)(param_1 + 7) & 0x4a) == 0) { if ((*(uint *)(param_1 + 7) & 0x20) == 0) { local_28 = (void *)tree_search_edge(local_38 + 0xb8,param_1 + 0xb,param_1 + 0x4c,8); } else { local_28 = (void *)0x0; } } else if (param_1[0x4c] == 0) { local_48 = *(int8 *)(local_38 + 0x10); local_40 = *(int4 *)(local_38 + 8); local_3c = 4; *(int4 *)(param_1 + 10) = 2; local_28 = (void *)tree_search_key(local_38 + 0xb8,param_1[8],param_1 + 0xb,param_1 + 0x4c, (int)param_1[10],&local_48); } else { local_28 = (void *)tree_search_next(local_38 + 0xb8,param_1 + 0x4c,8,0); } pvVar1 = local_28; if (local_28 == (void *)0x0) { puVar3 = (int4 *)_my_thread_var(); *puVar3 = 0x78; } else { uVar2 = (**(code **)(local_38 + 0x360))(local_38,local_28); local_28 = *(void **)((long)pvVar1 + (ulong)uVar2); local_18[1] = (long)local_28; } } else if ((param_1[1] == 0) && ((*(uint *)(param_1 + 7) & 0x10) == 0)) { local_28 = (void *)0x0; puVar3 = (int4 *)_my_thread_var(); *puVar3 = 0x78; } else if ((*(uint *)(param_1 + 7) & 8) == 0) { local_28 = (void *)hp_search(param_1,*(long *)(local_30 + 0x98) + (long)(int)param_1[5] * 0x368,param_1[8],2); } else { local_28 = (void *)hp_search(param_1,*(long *)(local_30 + 0x98) + (long)(int)param_1[5] * 0x368,param_1[8],3); } if (local_28 == (void *)0x0) { *(int4 *)(local_18 + 7) = 0x20; piVar4 = (int *)_my_thread_var(); if (*piVar4 == 0x78) { puVar3 = (int4 *)_my_thread_var(); *puVar3 = 0x89; } puVar3 = (int4 *)_my_thread_var(); local_c = *puVar3; } else { memcpy(local_20,local_28,(ulong)*(uint *)(local_30 + 0xf4)); *(int4 *)(local_18 + 7) = 0x22; local_c = 0; } } return local_c; }
60,846
key_cache_insert
eloqsql/mysys/mf_keycache.c
int key_cache_insert(KEY_CACHE *keycache, File file, my_off_t filepos, int level, uchar *buff, uint length) { if (keycache->can_be_used) return keycache->interface_funcs->insert(keycache->keycache_cb, file, filepos, level, buff, length); return 0; }
O0
c
key_cache_insert: pushq %rbp movq %rsp, %rbp subq $0x40, %rsp movq %rdi, -0x10(%rbp) movl %esi, -0x14(%rbp) movq %rdx, -0x20(%rbp) movl %ecx, -0x24(%rbp) movq %r8, -0x30(%rbp) movl %r9d, -0x34(%rbp) movq -0x10(%rbp), %rax cmpb $0x0, 0x49(%rax) je 0xe45b5 movq -0x10(%rbp), %rax movq 0x10(%rax), %rax movq 0x20(%rax), %rax movq -0x10(%rbp), %rcx movq 0x8(%rcx), %rdi movl -0x14(%rbp), %esi movq -0x20(%rbp), %rdx movl -0x24(%rbp), %ecx movq -0x30(%rbp), %r8 movl -0x34(%rbp), %r9d callq *%rax movl %eax, -0x4(%rbp) jmp 0xe45bc movl $0x0, -0x4(%rbp) movl -0x4(%rbp), %eax addq $0x40, %rsp popq %rbp retq nopw %cs:(%rax,%rax)
key_cache_insert: push rbp mov rbp, rsp sub rsp, 40h mov [rbp+var_10], rdi mov [rbp+var_14], esi mov [rbp+var_20], rdx mov [rbp+var_24], ecx mov [rbp+var_30], r8 mov [rbp+var_34], r9d mov rax, [rbp+var_10] cmp byte ptr [rax+49h], 0 jz short loc_E45B5 mov rax, [rbp+var_10] mov rax, [rax+10h] mov rax, [rax+20h] mov rcx, [rbp+var_10] mov rdi, [rcx+8] mov esi, [rbp+var_14] mov rdx, [rbp+var_20] mov ecx, [rbp+var_24] mov r8, [rbp+var_30] mov r9d, [rbp+var_34] call rax mov [rbp+var_4], eax jmp short loc_E45BC loc_E45B5: mov [rbp+var_4], 0 loc_E45BC: mov eax, [rbp+var_4] add rsp, 40h pop rbp retn
long long key_cache_insert( long long a1, unsigned int a2, long long a3, unsigned int a4, long long a5, unsigned int a6) { if ( *(_BYTE *)(a1 + 73) ) return (unsigned int)(*(long long ( **)(_QWORD, _QWORD, long long, _QWORD, long long, _QWORD))(*(_QWORD *)(a1 + 16) + 32LL))( *(_QWORD *)(a1 + 8), a2, a3, a4, a5, a6); else return 0; }
key_cache_insert: PUSH RBP MOV RBP,RSP SUB RSP,0x40 MOV qword ptr [RBP + -0x10],RDI MOV dword ptr [RBP + -0x14],ESI MOV qword ptr [RBP + -0x20],RDX MOV dword ptr [RBP + -0x24],ECX MOV qword ptr [RBP + -0x30],R8 MOV dword ptr [RBP + -0x34],R9D MOV RAX,qword ptr [RBP + -0x10] CMP byte ptr [RAX + 0x49],0x0 JZ 0x001e45b5 MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x10] MOV RAX,qword ptr [RAX + 0x20] MOV RCX,qword ptr [RBP + -0x10] MOV RDI,qword ptr [RCX + 0x8] MOV ESI,dword ptr [RBP + -0x14] MOV RDX,qword ptr [RBP + -0x20] MOV ECX,dword ptr [RBP + -0x24] MOV R8,qword ptr [RBP + -0x30] MOV R9D,dword ptr [RBP + -0x34] CALL RAX MOV dword ptr [RBP + -0x4],EAX JMP 0x001e45bc LAB_001e45b5: MOV dword ptr [RBP + -0x4],0x0 LAB_001e45bc: MOV EAX,dword ptr [RBP + -0x4] ADD RSP,0x40 POP RBP RET
int4 key_cache_insert(long param_1,int4 param_2,int8 param_3,int4 param_4, int8 param_5,int4 param_6) { int4 local_c; if (*(char *)(param_1 + 0x49) == '\0') { local_c = 0; } else { local_c = (**(code **)(*(long *)(param_1 + 0x10) + 0x20)) (*(int8 *)(param_1 + 8),param_2,param_3,param_4,param_5,param_6); } return local_c; }
60,847
ma_pvio_cache_read
eloqsql/libmariadb/libmariadb/ma_pvio.c
ssize_t ma_pvio_cache_read(MARIADB_PVIO *pvio, uchar *buffer, size_t length) { ssize_t r; if (!pvio) return -1; if (!pvio->cache) return ma_pvio_read(pvio, buffer, length); if (pvio->cache + pvio->cache_size > pvio->cache_pos) { ssize_t remaining = pvio->cache + pvio->cache_size - pvio->cache_pos; assert(remaining > 0); r= MIN((ssize_t)length, remaining); memcpy(buffer, pvio->cache_pos, r); pvio->cache_pos+= r; } else if (length >= PVIO_READ_AHEAD_CACHE_MIN_SIZE) { r= ma_pvio_read(pvio, buffer, length); } else { r= ma_pvio_read(pvio, pvio->cache, PVIO_READ_AHEAD_CACHE_SIZE); if (r > 0) { if (length < (size_t)r) { pvio->cache_size= r; pvio->cache_pos= pvio->cache + length; r= length; } memcpy(buffer, pvio->cache, r); } } return r; }
O0
c
ma_pvio_cache_read: pushq %rbp movq %rsp, %rbp subq $0x40, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq %rdx, -0x20(%rbp) cmpq $0x0, -0x10(%rbp) jne 0xabd48 movq $-0x1, -0x8(%rbp) jmp 0xabe89 movq -0x10(%rbp), %rax cmpq $0x0, 0x8(%rax) jne 0xabd6d movq -0x10(%rbp), %rdi movq -0x18(%rbp), %rsi movq -0x20(%rbp), %rdx callq 0xab940 movq %rax, -0x8(%rbp) jmp 0xabe89 movq -0x10(%rbp), %rax movq 0x8(%rax), %rax movq -0x10(%rbp), %rcx addq 0x18(%rcx), %rax movq -0x10(%rbp), %rcx cmpq 0x10(%rcx), %rax jbe 0xabdf4 movq -0x10(%rbp), %rax movq 0x8(%rax), %rax movq -0x10(%rbp), %rcx addq 0x18(%rcx), %rax movq -0x10(%rbp), %rcx movq 0x10(%rcx), %rcx subq %rcx, %rax movq %rax, -0x30(%rbp) movq -0x20(%rbp), %rax cmpq -0x30(%rbp), %rax jge 0xabdba movq -0x20(%rbp), %rax movq %rax, -0x38(%rbp) jmp 0xabdc2 movq -0x30(%rbp), %rax movq %rax, -0x38(%rbp) movq -0x38(%rbp), %rax movq %rax, -0x28(%rbp) movq -0x18(%rbp), %rdi movq -0x10(%rbp), %rax movq 0x10(%rax), %rsi movq -0x28(%rbp), %rdx callq 0x3a0b0 movq -0x28(%rbp), %rcx movq -0x10(%rbp), %rax addq 0x10(%rax), %rcx movq %rcx, 0x10(%rax) jmp 0xabe81 cmpq $0x800, -0x20(%rbp) # imm = 0x800 jb 0xabe15 movq -0x10(%rbp), %rdi movq -0x18(%rbp), %rsi movq -0x20(%rbp), %rdx callq 0xab940 movq %rax, -0x28(%rbp) jmp 0xabe7f movq -0x10(%rbp), %rdi movq -0x10(%rbp), %rax movq 0x8(%rax), %rsi movl $0x4000, %edx # imm = 0x4000 callq 0xab940 movq %rax, -0x28(%rbp) cmpq $0x0, -0x28(%rbp) jle 0xabe7d movq -0x20(%rbp), %rax cmpq -0x28(%rbp), %rax jae 0xabe68 movq -0x28(%rbp), %rcx movq -0x10(%rbp), %rax movq %rcx, 0x18(%rax) movq -0x10(%rbp), %rax movq 0x8(%rax), %rcx addq -0x20(%rbp), %rcx movq -0x10(%rbp), %rax movq %rcx, 0x10(%rax) movq -0x20(%rbp), %rax movq %rax, -0x28(%rbp) movq -0x18(%rbp), %rdi movq -0x10(%rbp), %rax movq 0x8(%rax), %rsi movq -0x28(%rbp), %rdx callq 0x3a0b0 jmp 0xabe7f jmp 0xabe81 movq -0x28(%rbp), %rax movq %rax, -0x8(%rbp) movq -0x8(%rbp), %rax addq $0x40, %rsp popq %rbp retq nopw %cs:(%rax,%rax)
ma_pvio_cache_read: push rbp mov rbp, rsp sub rsp, 40h mov [rbp+var_10], rdi mov [rbp+var_18], rsi mov [rbp+var_20], rdx cmp [rbp+var_10], 0 jnz short loc_ABD48 mov [rbp+var_8], 0FFFFFFFFFFFFFFFFh jmp loc_ABE89 loc_ABD48: mov rax, [rbp+var_10] cmp qword ptr [rax+8], 0 jnz short loc_ABD6D mov rdi, [rbp+var_10] mov rsi, [rbp+var_18] mov rdx, [rbp+var_20] call ma_pvio_read mov [rbp+var_8], rax jmp loc_ABE89 loc_ABD6D: mov rax, [rbp+var_10] mov rax, [rax+8] mov rcx, [rbp+var_10] add rax, [rcx+18h] mov rcx, [rbp+var_10] cmp rax, [rcx+10h] jbe short loc_ABDF4 mov rax, [rbp+var_10] mov rax, [rax+8] mov rcx, [rbp+var_10] add rax, [rcx+18h] mov rcx, [rbp+var_10] mov rcx, [rcx+10h] sub rax, rcx mov [rbp+var_30], rax mov rax, [rbp+var_20] cmp rax, [rbp+var_30] jge short loc_ABDBA mov rax, [rbp+var_20] mov [rbp+var_38], rax jmp short loc_ABDC2 loc_ABDBA: mov rax, [rbp+var_30] mov [rbp+var_38], rax loc_ABDC2: mov rax, [rbp+var_38] mov [rbp+var_28], rax mov rdi, [rbp+var_18] mov rax, [rbp+var_10] mov rsi, [rax+10h] mov rdx, [rbp+var_28] call _memcpy mov rcx, [rbp+var_28] mov rax, [rbp+var_10] add rcx, [rax+10h] mov [rax+10h], rcx jmp loc_ABE81 loc_ABDF4: cmp [rbp+var_20], 800h jb short loc_ABE15 mov rdi, [rbp+var_10] mov rsi, [rbp+var_18] mov rdx, [rbp+var_20] call ma_pvio_read mov [rbp+var_28], rax jmp short loc_ABE7F loc_ABE15: mov rdi, [rbp+var_10] mov rax, [rbp+var_10] mov rsi, [rax+8] mov edx, 4000h call ma_pvio_read mov [rbp+var_28], rax cmp [rbp+var_28], 0 jle short loc_ABE7D mov rax, [rbp+var_20] cmp rax, [rbp+var_28] jnb short loc_ABE68 mov rcx, [rbp+var_28] mov rax, [rbp+var_10] mov [rax+18h], rcx mov rax, [rbp+var_10] mov rcx, [rax+8] add rcx, [rbp+var_20] mov rax, [rbp+var_10] mov [rax+10h], rcx mov rax, [rbp+var_20] mov [rbp+var_28], rax loc_ABE68: mov rdi, [rbp+var_18] mov rax, [rbp+var_10] mov rsi, [rax+8] mov rdx, [rbp+var_28] call _memcpy loc_ABE7D: jmp short $+2 loc_ABE7F: jmp short $+2 loc_ABE81: mov rax, [rbp+var_28] mov [rbp+var_8], rax loc_ABE89: mov rax, [rbp+var_8] add rsp, 40h pop rbp retn
long long ma_pvio_cache_read(_QWORD *a1, long long a2, unsigned long long a3) { unsigned long long v4; // [rsp+8h] [rbp-38h] long long v5; // [rsp+18h] [rbp-28h] if ( !a1 ) return -1LL; if ( !a1[1] ) return ma_pvio_read(a1, a2, a3); if ( a1[3] + a1[1] <= a1[2] ) { if ( a3 < 0x800 ) { v5 = ma_pvio_read(a1, a1[1], 0x4000LL); if ( v5 > 0 ) { if ( a3 < v5 ) { a1[3] = v5; a1[2] = a3 + a1[1]; v5 = a3; } memcpy(a2, a1[1], v5); } } else { return ma_pvio_read(a1, a2, a3); } } else { if ( (signed long long)a3 >= a1[3] + a1[1] - a1[2] ) v4 = a1[3] + a1[1] - a1[2]; else v4 = a3; v5 = v4; memcpy(a2, a1[2], v4); a1[2] += v4; } return v5; }
ma_pvio_cache_read: PUSH RBP MOV RBP,RSP SUB RSP,0x40 MOV qword ptr [RBP + -0x10],RDI MOV qword ptr [RBP + -0x18],RSI MOV qword ptr [RBP + -0x20],RDX CMP qword ptr [RBP + -0x10],0x0 JNZ 0x001abd48 MOV qword ptr [RBP + -0x8],-0x1 JMP 0x001abe89 LAB_001abd48: MOV RAX,qword ptr [RBP + -0x10] CMP qword ptr [RAX + 0x8],0x0 JNZ 0x001abd6d MOV RDI,qword ptr [RBP + -0x10] MOV RSI,qword ptr [RBP + -0x18] MOV RDX,qword ptr [RBP + -0x20] CALL 0x001ab940 MOV qword ptr [RBP + -0x8],RAX JMP 0x001abe89 LAB_001abd6d: MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x8] MOV RCX,qword ptr [RBP + -0x10] ADD RAX,qword ptr [RCX + 0x18] MOV RCX,qword ptr [RBP + -0x10] CMP RAX,qword ptr [RCX + 0x10] JBE 0x001abdf4 MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x8] MOV RCX,qword ptr [RBP + -0x10] ADD RAX,qword ptr [RCX + 0x18] MOV RCX,qword ptr [RBP + -0x10] MOV RCX,qword ptr [RCX + 0x10] SUB RAX,RCX MOV qword ptr [RBP + -0x30],RAX MOV RAX,qword ptr [RBP + -0x20] CMP RAX,qword ptr [RBP + -0x30] JGE 0x001abdba MOV RAX,qword ptr [RBP + -0x20] MOV qword ptr [RBP + -0x38],RAX JMP 0x001abdc2 LAB_001abdba: MOV RAX,qword ptr [RBP + -0x30] MOV qword ptr [RBP + -0x38],RAX LAB_001abdc2: MOV RAX,qword ptr [RBP + -0x38] MOV qword ptr [RBP + -0x28],RAX MOV RDI,qword ptr [RBP + -0x18] MOV RAX,qword ptr [RBP + -0x10] MOV RSI,qword ptr [RAX + 0x10] MOV RDX,qword ptr [RBP + -0x28] CALL 0x0013a0b0 MOV RCX,qword ptr [RBP + -0x28] MOV RAX,qword ptr [RBP + -0x10] ADD RCX,qword ptr [RAX + 0x10] MOV qword ptr [RAX + 0x10],RCX JMP 0x001abe81 LAB_001abdf4: CMP qword ptr [RBP + -0x20],0x800 JC 0x001abe15 MOV RDI,qword ptr [RBP + -0x10] MOV RSI,qword ptr [RBP + -0x18] MOV RDX,qword ptr [RBP + -0x20] CALL 0x001ab940 MOV qword ptr [RBP + -0x28],RAX JMP 0x001abe7f LAB_001abe15: MOV RDI,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RBP + -0x10] MOV RSI,qword ptr [RAX + 0x8] MOV EDX,0x4000 CALL 0x001ab940 MOV qword ptr [RBP + -0x28],RAX CMP qword ptr [RBP + -0x28],0x0 JLE 0x001abe7d MOV RAX,qword ptr [RBP + -0x20] CMP RAX,qword ptr [RBP + -0x28] JNC 0x001abe68 MOV RCX,qword ptr [RBP + -0x28] MOV RAX,qword ptr [RBP + -0x10] MOV qword ptr [RAX + 0x18],RCX MOV RAX,qword ptr [RBP + -0x10] MOV RCX,qword ptr [RAX + 0x8] ADD RCX,qword ptr [RBP + -0x20] MOV RAX,qword ptr [RBP + -0x10] MOV qword ptr [RAX + 0x10],RCX MOV RAX,qword ptr [RBP + -0x20] MOV qword ptr [RBP + -0x28],RAX LAB_001abe68: MOV RDI,qword ptr [RBP + -0x18] MOV RAX,qword ptr [RBP + -0x10] MOV RSI,qword ptr [RAX + 0x8] MOV RDX,qword ptr [RBP + -0x28] CALL 0x0013a0b0 LAB_001abe7d: JMP 0x001abe7f LAB_001abe7f: JMP 0x001abe81 LAB_001abe81: MOV RAX,qword ptr [RBP + -0x28] MOV qword ptr [RBP + -0x8],RAX LAB_001abe89: MOV RAX,qword ptr [RBP + -0x8] ADD RSP,0x40 POP RBP RET
ulong ma_pvio_cache_read(long param_1,void *param_2,ulong param_3) { size_t local_40; ulong local_30; ulong local_10; if (param_1 == 0) { local_10 = 0xffffffffffffffff; } else if (*(long *)(param_1 + 8) == 0) { local_10 = ma_pvio_read(param_1,param_2,param_3); } else { if (*(ulong *)(param_1 + 0x10) < (ulong)(*(long *)(param_1 + 8) + *(long *)(param_1 + 0x18))) { local_40 = (*(long *)(param_1 + 8) + *(long *)(param_1 + 0x18)) - *(long *)(param_1 + 0x10); if ((long)param_3 < (long)local_40) { local_40 = param_3; } local_30 = local_40; memcpy(param_2,*(void **)(param_1 + 0x10),local_40); *(size_t *)(param_1 + 0x10) = local_40 + *(long *)(param_1 + 0x10); } else if (param_3 < 0x800) { local_30 = ma_pvio_read(param_1,*(int8 *)(param_1 + 8),0x4000); if (0 < (long)local_30) { if (param_3 < local_30) { *(ulong *)(param_1 + 0x18) = local_30; *(ulong *)(param_1 + 0x10) = *(long *)(param_1 + 8) + param_3; local_30 = param_3; } memcpy(param_2,*(void **)(param_1 + 8),local_30); } } else { local_30 = ma_pvio_read(param_1,param_2,param_3); } local_10 = local_30; } return local_10; }
60,848
mthd_stmt_read_prepare_response
eloqsql/libmariadb/libmariadb/mariadb_stmt.c
my_bool mthd_stmt_read_prepare_response(MYSQL_STMT *stmt) { ulong packet_length; uchar *p; if ((packet_length= ma_net_safe_read(stmt->mysql)) == packet_error) return(1); p= (uchar *)stmt->mysql->net.read_pos; if (0xFF == p[0]) /* Error occurred */ { return(1); } p++; stmt->stmt_id= uint4korr(p); p+= 4; stmt->field_count= uint2korr(p); p+= 2; stmt->param_count= uint2korr(p); p+= 2; /* filler */ p++; /* for backward compatibility we also update mysql->warning_count */ stmt->mysql->warning_count= stmt->upsert_status.warning_count= uint2korr(p); /* metadata not supported yet */ if (stmt->param_count && stmt->mysql->methods->db_stmt_get_param_metadata(stmt)) { return 1; } /* allocated bind buffer for parameters */ if (stmt->field_count && stmt->mysql->methods->db_stmt_get_result_metadata(stmt)) { return 1; } if (stmt->param_count) { if (stmt->prebind_params) { if (stmt->prebind_params != stmt->param_count) { SET_CLIENT_STMT_ERROR(stmt, CR_INVALID_PARAMETER_NO, SQLSTATE_UNKNOWN, 0); stmt->param_count= stmt->prebind_params; return 1; } } else { if (!(stmt->params= (MYSQL_BIND *)ma_alloc_root(&stmt->mem_root, stmt->param_count * sizeof(MYSQL_BIND)))) { SET_CLIENT_STMT_ERROR(stmt, CR_OUT_OF_MEMORY, SQLSTATE_UNKNOWN, 0); return 1; } memset(stmt->params, '\0', stmt->param_count * sizeof(MYSQL_BIND)); } } /* allocated bind buffer for result */ if (stmt->field_count) { MA_MEM_ROOT *fields_ma_alloc_root= &((MADB_STMT_EXTENSION *)stmt->extension)->fields_ma_alloc_root; if (!(stmt->bind= (MYSQL_BIND *)ma_alloc_root(fields_ma_alloc_root, stmt->field_count * sizeof(MYSQL_BIND)))) { SET_CLIENT_STMT_ERROR(stmt, CR_OUT_OF_MEMORY, SQLSTATE_UNKNOWN, 0); return 1; } memset(stmt->bind, 0, sizeof(MYSQL_BIND) * stmt->field_count); } stmt->state = MYSQL_STMT_PREPARED; return(0); }
O0
c
mthd_stmt_read_prepare_response: pushq %rbp movq %rsp, %rbp subq $0x30, %rsp movq %rdi, -0x10(%rbp) movq -0x10(%rbp), %rax movq 0x38(%rax), %rdi callq 0x478c0 movq %rax, -0x18(%rbp) movl $0xffffffff, %ecx # imm = 0xFFFFFFFF cmpq %rcx, %rax jne 0x5bf20 movb $0x1, -0x1(%rbp) jmp 0x5c2e0 movq -0x10(%rbp), %rax movq 0x38(%rax), %rax movq 0x20(%rax), %rax movq %rax, -0x20(%rbp) movq -0x20(%rbp), %rax movzbl (%rax), %ecx movl $0xff, %eax cmpl %ecx, %eax jne 0x5bf49 movb $0x1, -0x1(%rbp) jmp 0x5c2e0 movq -0x20(%rbp), %rax addq $0x1, %rax movq %rax, -0x20(%rbp) movq -0x20(%rbp), %rax movzbl (%rax), %eax movq -0x20(%rbp), %rcx movzbl 0x1(%rcx), %ecx shll $0x8, %ecx addl %ecx, %eax movq -0x20(%rbp), %rcx movzbl 0x2(%rcx), %ecx shll $0x10, %ecx addl %ecx, %eax movq -0x20(%rbp), %rcx movzbl 0x3(%rcx), %ecx shll $0x18, %ecx addl %ecx, %eax movl %eax, %eax movl %eax, %ecx movq -0x10(%rbp), %rax movq %rcx, 0x40(%rax) movq -0x20(%rbp), %rax addq $0x4, %rax movq %rax, -0x20(%rbp) movq -0x20(%rbp), %rax movzbl (%rax), %eax movzwl %ax, %eax movq -0x20(%rbp), %rcx movzbl 0x1(%rcx), %ecx movzwl %cx, %ecx shll $0x8, %ecx addl %ecx, %eax movzwl %ax, %ecx movq -0x10(%rbp), %rax movl %ecx, 0x60(%rax) movq -0x20(%rbp), %rax addq $0x2, %rax movq %rax, -0x20(%rbp) movq -0x20(%rbp), %rax movzbl (%rax), %eax movzwl %ax, %eax movq -0x20(%rbp), %rcx movzbl 0x1(%rcx), %ecx movzwl %cx, %ecx shll $0x8, %ecx addl %ecx, %eax movzwl %ax, %ecx movq -0x10(%rbp), %rax movl %ecx, 0x64(%rax) movq -0x20(%rbp), %rax addq $0x2, %rax movq %rax, -0x20(%rbp) movq -0x20(%rbp), %rax addq $0x1, %rax movq %rax, -0x20(%rbp) movq -0x20(%rbp), %rax movzbl (%rax), %eax movzwl %ax, %eax movq -0x20(%rbp), %rcx movzbl 0x1(%rcx), %ecx movzwl %cx, %ecx shll $0x8, %ecx addl %ecx, %eax movzwl %ax, %ecx movq -0x10(%rbp), %rax movl %ecx, 0xf0(%rax) movq -0x10(%rbp), %rax movq 0x38(%rax), %rax movl %ecx, 0x388(%rax) movq -0x10(%rbp), %rax cmpl $0x0, 0x64(%rax) je 0x5c070 movq -0x10(%rbp), %rax movq 0x38(%rax), %rax movq 0x4d0(%rax), %rax movq 0x58(%rax), %rax movq -0x10(%rbp), %rdi callq *%rax movsbl %al, %eax cmpl $0x0, %eax je 0x5c070 movb $0x1, -0x1(%rbp) jmp 0x5c2e0 movq -0x10(%rbp), %rax cmpl $0x0, 0x60(%rax) je 0x5c0a4 movq -0x10(%rbp), %rax movq 0x38(%rax), %rax movq 0x4d0(%rax), %rax movq 0x50(%rax), %rax movq -0x10(%rbp), %rdi callq *%rax movsbl %al, %eax cmpl $0x0, %eax je 0x5c0a4 movb $0x1, -0x1(%rbp) jmp 0x5c2e0 movq -0x10(%rbp), %rax cmpl $0x0, 0x64(%rax) je 0x5c20d movq -0x10(%rbp), %rax cmpl $0x0, 0x378(%rax) je 0x5c161 movq -0x10(%rbp), %rax movl 0x378(%rax), %eax movq -0x10(%rbp), %rcx cmpl 0x64(%rcx), %eax je 0x5c15c jmp 0x5c0dc movq -0x10(%rbp), %rax movl $0x7f2, 0x108(%rax) # imm = 0x7F2 movq -0x10(%rbp), %rdi addq $0x30d, %rdi # imm = 0x30D leaq 0x1ed8d4(%rip), %rax # 0x2499d0 movq (%rax), %rsi movl $0x5, %edx callq 0x38140 movq -0x10(%rbp), %rax movb $0x0, 0x312(%rax) movq -0x10(%rbp), %rdi addq $0x10c, %rdi # imm = 0x10C leaq 0x1ed8ba(%rip), %rax # 0x2499e0 movq 0x110(%rax), %rsi movl $0x200, %edx # imm = 0x200 callq 0x38140 movq -0x10(%rbp), %rax movb $0x0, 0x30b(%rax) movq -0x10(%rbp), %rax movl 0x378(%rax), %ecx movq -0x10(%rbp), %rax movl %ecx, 0x64(%rax) movb $0x1, -0x1(%rbp) jmp 0x5c2e0 jmp 0x5c20b movq -0x10(%rbp), %rdi movq -0x10(%rbp), %rax movl 0x64(%rax), %eax imulq $0x70, %rax, %rsi callq 0x565c0 movq -0x10(%rbp), %rcx movq %rax, 0x70(%rcx) cmpq $0x0, %rax jne 0x5c1f1 jmp 0x5c185 movq -0x10(%rbp), %rax movl $0x7d8, 0x108(%rax) # imm = 0x7D8 movq -0x10(%rbp), %rdi addq $0x30d, %rdi # imm = 0x30D leaq 0x1ed82b(%rip), %rax # 0x2499d0 movq (%rax), %rsi movl $0x5, %edx callq 0x38140 movq -0x10(%rbp), %rax movb $0x0, 0x312(%rax) movq -0x10(%rbp), %rdi addq $0x10c, %rdi # imm = 0x10C leaq 0x1ed811(%rip), %rax # 0x2499e0 movq 0x40(%rax), %rsi movl $0x200, %edx # imm = 0x200 callq 0x38140 movq -0x10(%rbp), %rax movb $0x0, 0x30b(%rax) movb $0x1, -0x1(%rbp) jmp 0x5c2e0 movq -0x10(%rbp), %rax movq 0x70(%rax), %rdi movq -0x10(%rbp), %rax movl 0x64(%rax), %eax imulq $0x70, %rax, %rdx xorl %esi, %esi callq 0x38300 jmp 0x5c20d movq -0x10(%rbp), %rax cmpl $0x0, 0x60(%rax) je 0x5c2d1 movq -0x10(%rbp), %rax movq 0x340(%rax), %rax movq %rax, -0x28(%rbp) movq -0x28(%rbp), %rdi movq -0x10(%rbp), %rax movl 0x60(%rax), %eax imulq $0x70, %rax, %rsi callq 0x565c0 movq -0x10(%rbp), %rcx movq %rax, 0x78(%rcx) cmpq $0x0, %rax jne 0x5c2b7 jmp 0x5c24e movq -0x10(%rbp), %rax movl $0x7d8, 0x108(%rax) # imm = 0x7D8 movq -0x10(%rbp), %rdi addq $0x30d, %rdi # imm = 0x30D leaq 0x1ed762(%rip), %rax # 0x2499d0 movq (%rax), %rsi movl $0x5, %edx callq 0x38140 movq -0x10(%rbp), %rax movb $0x0, 0x312(%rax) movq -0x10(%rbp), %rdi addq $0x10c, %rdi # imm = 0x10C leaq 0x1ed748(%rip), %rax # 0x2499e0 movq 0x40(%rax), %rsi movl $0x200, %edx # imm = 0x200 callq 0x38140 movq -0x10(%rbp), %rax movb $0x0, 0x30b(%rax) movb $0x1, -0x1(%rbp) jmp 0x5c2e0 movq -0x10(%rbp), %rax movq 0x78(%rax), %rdi movq -0x10(%rbp), %rax movl 0x60(%rax), %eax imulq $0x70, %rax, %rdx xorl %esi, %esi callq 0x38300 movq -0x10(%rbp), %rax movl $0x1, 0x50(%rax) movb $0x0, -0x1(%rbp) movb -0x1(%rbp), %al addq $0x30, %rsp popq %rbp retq nopl (%rax)
mthd_stmt_read_prepare_response: push rbp mov rbp, rsp sub rsp, 30h mov [rbp+var_10], rdi mov rax, [rbp+var_10] mov rdi, [rax+38h] call ma_net_safe_read mov [rbp+var_18], rax mov ecx, 0FFFFFFFFh cmp rax, rcx jnz short loc_5BF20 mov [rbp+var_1], 1 jmp loc_5C2E0 loc_5BF20: mov rax, [rbp+var_10] mov rax, [rax+38h] mov rax, [rax+20h] mov [rbp+var_20], rax mov rax, [rbp+var_20] movzx ecx, byte ptr [rax] mov eax, 0FFh cmp eax, ecx jnz short loc_5BF49 mov [rbp+var_1], 1 jmp loc_5C2E0 loc_5BF49: mov rax, [rbp+var_20] add rax, 1 mov [rbp+var_20], rax mov rax, [rbp+var_20] movzx eax, byte ptr [rax] mov rcx, [rbp+var_20] movzx ecx, byte ptr [rcx+1] shl ecx, 8 add eax, ecx mov rcx, [rbp+var_20] movzx ecx, byte ptr [rcx+2] shl ecx, 10h add eax, ecx mov rcx, [rbp+var_20] movzx ecx, byte ptr [rcx+3] shl ecx, 18h add eax, ecx mov eax, eax mov ecx, eax mov rax, [rbp+var_10] mov [rax+40h], rcx mov rax, [rbp+var_20] add rax, 4 mov [rbp+var_20], rax mov rax, [rbp+var_20] movzx eax, byte ptr [rax] movzx eax, ax mov rcx, [rbp+var_20] movzx ecx, byte ptr [rcx+1] movzx ecx, cx shl ecx, 8 add eax, ecx movzx ecx, ax mov rax, [rbp+var_10] mov [rax+60h], ecx mov rax, [rbp+var_20] add rax, 2 mov [rbp+var_20], rax mov rax, [rbp+var_20] movzx eax, byte ptr [rax] movzx eax, ax mov rcx, [rbp+var_20] movzx ecx, byte ptr [rcx+1] movzx ecx, cx shl ecx, 8 add eax, ecx movzx ecx, ax mov rax, [rbp+var_10] mov [rax+64h], ecx mov rax, [rbp+var_20] add rax, 2 mov [rbp+var_20], rax mov rax, [rbp+var_20] add rax, 1 mov [rbp+var_20], rax mov rax, [rbp+var_20] movzx eax, byte ptr [rax] movzx eax, ax mov rcx, [rbp+var_20] movzx ecx, byte ptr [rcx+1] movzx ecx, cx shl ecx, 8 add eax, ecx movzx ecx, ax mov rax, [rbp+var_10] mov [rax+0F0h], ecx mov rax, [rbp+var_10] mov rax, [rax+38h] mov [rax+388h], ecx mov rax, [rbp+var_10] cmp dword ptr [rax+64h], 0 jz short loc_5C070 mov rax, [rbp+var_10] mov rax, [rax+38h] mov rax, [rax+4D0h] mov rax, [rax+58h] mov rdi, [rbp+var_10] call rax movsx eax, al cmp eax, 0 jz short loc_5C070 mov [rbp+var_1], 1 jmp loc_5C2E0 loc_5C070: mov rax, [rbp+var_10] cmp dword ptr [rax+60h], 0 jz short loc_5C0A4 mov rax, [rbp+var_10] mov rax, [rax+38h] mov rax, [rax+4D0h] mov rax, [rax+50h] mov rdi, [rbp+var_10] call rax movsx eax, al cmp eax, 0 jz short loc_5C0A4 mov [rbp+var_1], 1 jmp loc_5C2E0 loc_5C0A4: mov rax, [rbp+var_10] cmp dword ptr [rax+64h], 0 jz loc_5C20D mov rax, [rbp+var_10] cmp dword ptr [rax+378h], 0 jz loc_5C161 mov rax, [rbp+var_10] mov eax, [rax+378h] mov rcx, [rbp+var_10] cmp eax, [rcx+64h] jz loc_5C15C jmp short $+2 loc_5C0DC: mov rax, [rbp+var_10] mov dword ptr [rax+108h], 7F2h mov rdi, [rbp+var_10] add rdi, 30Dh lea rax, SQLSTATE_UNKNOWN mov rsi, [rax] mov edx, 5 call _strncpy mov rax, [rbp+var_10] mov byte ptr [rax+312h], 0 mov rdi, [rbp+var_10] add rdi, 10Ch lea rax, client_errors mov rsi, [rax+110h] mov edx, 200h call _strncpy mov rax, [rbp+var_10] mov byte ptr [rax+30Bh], 0 mov rax, [rbp+var_10] mov ecx, [rax+378h] mov rax, [rbp+var_10] mov [rax+64h], ecx mov [rbp+var_1], 1 jmp loc_5C2E0 loc_5C15C: jmp loc_5C20B loc_5C161: mov rdi, [rbp+var_10] mov rax, [rbp+var_10] mov eax, [rax+64h] imul rsi, rax, 70h ; 'p' call ma_alloc_root mov rcx, [rbp+var_10] mov [rcx+70h], rax cmp rax, 0 jnz short loc_5C1F1 jmp short $+2 loc_5C185: mov rax, [rbp+var_10] mov dword ptr [rax+108h], 7D8h mov rdi, [rbp+var_10] add rdi, 30Dh lea rax, SQLSTATE_UNKNOWN mov rsi, [rax] mov edx, 5 call _strncpy mov rax, [rbp+var_10] mov byte ptr [rax+312h], 0 mov rdi, [rbp+var_10] add rdi, 10Ch lea rax, client_errors mov rsi, [rax+40h] mov edx, 200h call _strncpy mov rax, [rbp+var_10] mov byte ptr [rax+30Bh], 0 mov [rbp+var_1], 1 jmp loc_5C2E0 loc_5C1F1: mov rax, [rbp+var_10] mov rdi, [rax+70h] mov rax, [rbp+var_10] mov eax, [rax+64h] imul rdx, rax, 70h ; 'p' xor esi, esi call _memset loc_5C20B: jmp short $+2 loc_5C20D: mov rax, [rbp+var_10] cmp dword ptr [rax+60h], 0 jz loc_5C2D1 mov rax, [rbp+var_10] mov rax, [rax+340h] mov [rbp+var_28], rax mov rdi, [rbp+var_28] mov rax, [rbp+var_10] mov eax, [rax+60h] imul rsi, rax, 70h ; 'p' call ma_alloc_root mov rcx, [rbp+var_10] mov [rcx+78h], rax cmp rax, 0 jnz short loc_5C2B7 jmp short $+2 loc_5C24E: mov rax, [rbp+var_10] mov dword ptr [rax+108h], 7D8h mov rdi, [rbp+var_10] add rdi, 30Dh lea rax, SQLSTATE_UNKNOWN mov rsi, [rax] mov edx, 5 call _strncpy mov rax, [rbp+var_10] mov byte ptr [rax+312h], 0 mov rdi, [rbp+var_10] add rdi, 10Ch lea rax, client_errors mov rsi, [rax+40h] mov edx, 200h call _strncpy mov rax, [rbp+var_10] mov byte ptr [rax+30Bh], 0 mov [rbp+var_1], 1 jmp short loc_5C2E0 loc_5C2B7: mov rax, [rbp+var_10] mov rdi, [rax+78h] mov rax, [rbp+var_10] mov eax, [rax+60h] imul rdx, rax, 70h ; 'p' xor esi, esi call _memset loc_5C2D1: mov rax, [rbp+var_10] mov dword ptr [rax+50h], 1 mov [rbp+var_1], 0 loc_5C2E0: mov al, [rbp+var_1] add rsp, 30h pop rbp retn
char mthd_stmt_read_prepare_response(long long a1, long long a2, long long a3, long long a4, int a5, int a6) { int v6; // ecx char *v7; // rax char *v8; // rax unsigned __int8 *v10; // [rsp+10h] [rbp-20h] unsigned __int8 *v11; // [rsp+10h] [rbp-20h] if ( ma_net_safe_read(*(_QWORD *)(a1 + 56), a2, a3, a4, a5, a6) != 0xFFFFFFFFLL ) { v10 = *(unsigned __int8 **)(*(_QWORD *)(a1 + 56) + 32LL); if ( *v10 == 255 ) return 1; v11 = v10 + 1; *(_QWORD *)(a1 + 64) = (v11[3] << 24) + (v11[2] << 16) + (v11[1] << 8) + (unsigned int)*v11; v11 += 4; *(_DWORD *)(a1 + 96) = (unsigned __int16)((v11[1] << 8) + *v11); v11 += 2; *(_DWORD *)(a1 + 100) = (unsigned __int16)((v11[1] << 8) + *v11); v6 = (unsigned __int16)((v11[4] << 8) + v11[3]); *(_DWORD *)(a1 + 240) = v6; *(_DWORD *)(*(_QWORD *)(a1 + 56) + 904LL) = v6; if ( *(_DWORD *)(a1 + 100) && (*(unsigned __int8 ( **)(long long))(*(_QWORD *)(*(_QWORD *)(a1 + 56) + 1232LL) + 88LL))(a1) ) { return 1; } if ( *(_DWORD *)(a1 + 96) && (*(unsigned __int8 ( **)(long long))(*(_QWORD *)(*(_QWORD *)(a1 + 56) + 1232LL) + 80LL))(a1) ) { return 1; } if ( *(_DWORD *)(a1 + 100) ) { if ( *(_DWORD *)(a1 + 888) ) { if ( *(_DWORD *)(a1 + 888) != *(_DWORD *)(a1 + 100) ) { *(_DWORD *)(a1 + 264) = 2034; strncpy(a1 + 781, SQLSTATE_UNKNOWN, 5LL); *(_BYTE *)(a1 + 786) = 0; strncpy(a1 + 268, client_errors[34], 512LL); *(_BYTE *)(a1 + 779) = 0; *(_DWORD *)(a1 + 100) = *(_DWORD *)(a1 + 888); return 1; } } else { v7 = ma_alloc_root((_QWORD **)a1, 112LL * *(unsigned int *)(a1 + 100)); *(_QWORD *)(a1 + 112) = v7; if ( !v7 ) goto LABEL_17; memset(*(_QWORD *)(a1 + 112), 0LL, 112LL * *(unsigned int *)(a1 + 100)); } } if ( !*(_DWORD *)(a1 + 96) ) { LABEL_22: *(_DWORD *)(a1 + 80) = 1; return 0; } v8 = ma_alloc_root(*(_QWORD ***)(a1 + 832), 112LL * *(unsigned int *)(a1 + 96)); *(_QWORD *)(a1 + 120) = v8; if ( v8 ) { memset(*(_QWORD *)(a1 + 120), 0LL, 112LL * *(unsigned int *)(a1 + 96)); goto LABEL_22; } LABEL_17: *(_DWORD *)(a1 + 264) = 2008; strncpy(a1 + 781, SQLSTATE_UNKNOWN, 5LL); *(_BYTE *)(a1 + 786) = 0; strncpy(a1 + 268, client_errors[8], 512LL); *(_BYTE *)(a1 + 779) = 0; return 1; } return 1; }
mthd_stmt_read_prepare_response: PUSH RBP MOV RBP,RSP SUB RSP,0x30 MOV qword ptr [RBP + -0x10],RDI MOV RAX,qword ptr [RBP + -0x10] MOV RDI,qword ptr [RAX + 0x38] CALL 0x001478c0 MOV qword ptr [RBP + -0x18],RAX MOV ECX,0xffffffff CMP RAX,RCX JNZ 0x0015bf20 MOV byte ptr [RBP + -0x1],0x1 JMP 0x0015c2e0 LAB_0015bf20: MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x38] MOV RAX,qword ptr [RAX + 0x20] MOV qword ptr [RBP + -0x20],RAX MOV RAX,qword ptr [RBP + -0x20] MOVZX ECX,byte ptr [RAX] MOV EAX,0xff CMP EAX,ECX JNZ 0x0015bf49 MOV byte ptr [RBP + -0x1],0x1 JMP 0x0015c2e0 LAB_0015bf49: MOV RAX,qword ptr [RBP + -0x20] ADD RAX,0x1 MOV qword ptr [RBP + -0x20],RAX MOV RAX,qword ptr [RBP + -0x20] MOVZX EAX,byte ptr [RAX] MOV RCX,qword ptr [RBP + -0x20] MOVZX ECX,byte ptr [RCX + 0x1] SHL ECX,0x8 ADD EAX,ECX MOV RCX,qword ptr [RBP + -0x20] MOVZX ECX,byte ptr [RCX + 0x2] SHL ECX,0x10 ADD EAX,ECX MOV RCX,qword ptr [RBP + -0x20] MOVZX ECX,byte ptr [RCX + 0x3] SHL ECX,0x18 ADD EAX,ECX MOV EAX,EAX MOV ECX,EAX MOV RAX,qword ptr [RBP + -0x10] MOV qword ptr [RAX + 0x40],RCX MOV RAX,qword ptr [RBP + -0x20] ADD RAX,0x4 MOV qword ptr [RBP + -0x20],RAX MOV RAX,qword ptr [RBP + -0x20] MOVZX EAX,byte ptr [RAX] MOVZX EAX,AX MOV RCX,qword ptr [RBP + -0x20] MOVZX ECX,byte ptr [RCX + 0x1] MOVZX ECX,CX SHL ECX,0x8 ADD EAX,ECX MOVZX ECX,AX MOV RAX,qword ptr [RBP + -0x10] MOV dword ptr [RAX + 0x60],ECX MOV RAX,qword ptr [RBP + -0x20] ADD RAX,0x2 MOV qword ptr [RBP + -0x20],RAX MOV RAX,qword ptr [RBP + -0x20] MOVZX EAX,byte ptr [RAX] MOVZX EAX,AX MOV RCX,qword ptr [RBP + -0x20] MOVZX ECX,byte ptr [RCX + 0x1] MOVZX ECX,CX SHL ECX,0x8 ADD EAX,ECX MOVZX ECX,AX MOV RAX,qword ptr [RBP + -0x10] MOV dword ptr [RAX + 0x64],ECX MOV RAX,qword ptr [RBP + -0x20] ADD RAX,0x2 MOV qword ptr [RBP + -0x20],RAX MOV RAX,qword ptr [RBP + -0x20] ADD RAX,0x1 MOV qword ptr [RBP + -0x20],RAX MOV RAX,qword ptr [RBP + -0x20] MOVZX EAX,byte ptr [RAX] MOVZX EAX,AX MOV RCX,qword ptr [RBP + -0x20] MOVZX ECX,byte ptr [RCX + 0x1] MOVZX ECX,CX SHL ECX,0x8 ADD EAX,ECX MOVZX ECX,AX MOV RAX,qword ptr [RBP + -0x10] MOV dword ptr [RAX + 0xf0],ECX MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x38] MOV dword ptr [RAX + 0x388],ECX MOV RAX,qword ptr [RBP + -0x10] CMP dword ptr [RAX + 0x64],0x0 JZ 0x0015c070 MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x38] MOV RAX,qword ptr [RAX + 0x4d0] MOV RAX,qword ptr [RAX + 0x58] MOV RDI,qword ptr [RBP + -0x10] CALL RAX MOVSX EAX,AL CMP EAX,0x0 JZ 0x0015c070 MOV byte ptr [RBP + -0x1],0x1 JMP 0x0015c2e0 LAB_0015c070: MOV RAX,qword ptr [RBP + -0x10] CMP dword ptr [RAX + 0x60],0x0 JZ 0x0015c0a4 MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x38] MOV RAX,qword ptr [RAX + 0x4d0] MOV RAX,qword ptr [RAX + 0x50] MOV RDI,qword ptr [RBP + -0x10] CALL RAX MOVSX EAX,AL CMP EAX,0x0 JZ 0x0015c0a4 MOV byte ptr [RBP + -0x1],0x1 JMP 0x0015c2e0 LAB_0015c0a4: MOV RAX,qword ptr [RBP + -0x10] CMP dword ptr [RAX + 0x64],0x0 JZ 0x0015c20d MOV RAX,qword ptr [RBP + -0x10] CMP dword ptr [RAX + 0x378],0x0 JZ 0x0015c161 MOV RAX,qword ptr [RBP + -0x10] MOV EAX,dword ptr [RAX + 0x378] MOV RCX,qword ptr [RBP + -0x10] CMP EAX,dword ptr [RCX + 0x64] JZ 0x0015c15c JMP 0x0015c0dc LAB_0015c0dc: MOV RAX,qword ptr [RBP + -0x10] MOV dword ptr [RAX + 0x108],0x7f2 MOV RDI,qword ptr [RBP + -0x10] ADD RDI,0x30d LEA RAX,[0x3499d0] MOV RSI,qword ptr [RAX] MOV EDX,0x5 CALL 0x00138140 MOV RAX,qword ptr [RBP + -0x10] MOV byte ptr [RAX + 0x312],0x0 MOV RDI,qword ptr [RBP + -0x10] ADD RDI,0x10c LEA RAX,[0x3499e0] MOV RSI,qword ptr [RAX + 0x110] MOV EDX,0x200 CALL 0x00138140 MOV RAX,qword ptr [RBP + -0x10] MOV byte ptr [RAX + 0x30b],0x0 MOV RAX,qword ptr [RBP + -0x10] MOV ECX,dword ptr [RAX + 0x378] MOV RAX,qword ptr [RBP + -0x10] MOV dword ptr [RAX + 0x64],ECX MOV byte ptr [RBP + -0x1],0x1 JMP 0x0015c2e0 LAB_0015c15c: JMP 0x0015c20b LAB_0015c161: MOV RDI,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RBP + -0x10] MOV EAX,dword ptr [RAX + 0x64] IMUL RSI,RAX,0x70 CALL 0x001565c0 MOV RCX,qword ptr [RBP + -0x10] MOV qword ptr [RCX + 0x70],RAX CMP RAX,0x0 JNZ 0x0015c1f1 JMP 0x0015c185 LAB_0015c185: MOV RAX,qword ptr [RBP + -0x10] MOV dword ptr [RAX + 0x108],0x7d8 MOV RDI,qword ptr [RBP + -0x10] ADD RDI,0x30d LEA RAX,[0x3499d0] MOV RSI,qword ptr [RAX] MOV EDX,0x5 CALL 0x00138140 MOV RAX,qword ptr [RBP + -0x10] MOV byte ptr [RAX + 0x312],0x0 MOV RDI,qword ptr [RBP + -0x10] ADD RDI,0x10c LEA RAX,[0x3499e0] MOV RSI,qword ptr [RAX + 0x40] MOV EDX,0x200 CALL 0x00138140 MOV RAX,qword ptr [RBP + -0x10] MOV byte ptr [RAX + 0x30b],0x0 MOV byte ptr [RBP + -0x1],0x1 JMP 0x0015c2e0 LAB_0015c1f1: MOV RAX,qword ptr [RBP + -0x10] MOV RDI,qword ptr [RAX + 0x70] MOV RAX,qword ptr [RBP + -0x10] MOV EAX,dword ptr [RAX + 0x64] IMUL RDX,RAX,0x70 XOR ESI,ESI CALL 0x00138300 LAB_0015c20b: JMP 0x0015c20d LAB_0015c20d: MOV RAX,qword ptr [RBP + -0x10] CMP dword ptr [RAX + 0x60],0x0 JZ 0x0015c2d1 MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x340] MOV qword ptr [RBP + -0x28],RAX MOV RDI,qword ptr [RBP + -0x28] MOV RAX,qword ptr [RBP + -0x10] MOV EAX,dword ptr [RAX + 0x60] IMUL RSI,RAX,0x70 CALL 0x001565c0 MOV RCX,qword ptr [RBP + -0x10] MOV qword ptr [RCX + 0x78],RAX CMP RAX,0x0 JNZ 0x0015c2b7 JMP 0x0015c24e LAB_0015c24e: MOV RAX,qword ptr [RBP + -0x10] MOV dword ptr [RAX + 0x108],0x7d8 MOV RDI,qword ptr [RBP + -0x10] ADD RDI,0x30d LEA RAX,[0x3499d0] MOV RSI,qword ptr [RAX] MOV EDX,0x5 CALL 0x00138140 MOV RAX,qword ptr [RBP + -0x10] MOV byte ptr [RAX + 0x312],0x0 MOV RDI,qword ptr [RBP + -0x10] ADD RDI,0x10c LEA RAX,[0x3499e0] MOV RSI,qword ptr [RAX + 0x40] MOV EDX,0x200 CALL 0x00138140 MOV RAX,qword ptr [RBP + -0x10] MOV byte ptr [RAX + 0x30b],0x0 MOV byte ptr [RBP + -0x1],0x1 JMP 0x0015c2e0 LAB_0015c2b7: MOV RAX,qword ptr [RBP + -0x10] MOV RDI,qword ptr [RAX + 0x78] MOV RAX,qword ptr [RBP + -0x10] MOV EAX,dword ptr [RAX + 0x60] IMUL RDX,RAX,0x70 XOR ESI,ESI CALL 0x00138300 LAB_0015c2d1: MOV RAX,qword ptr [RBP + -0x10] MOV dword ptr [RAX + 0x50],0x1 MOV byte ptr [RBP + -0x1],0x0 LAB_0015c2e0: MOV AL,byte ptr [RBP + -0x1] ADD RSP,0x30 POP RBP RET
int1 mthd_stmt_read_prepare_response(long param_1) { char *pcVar1; char cVar2; long lVar3; uint uVar4; int1 local_9; lVar3 = ma_net_safe_read(*(int8 *)(param_1 + 0x38)); if (lVar3 == 0xffffffff) { local_9 = 1; } else { pcVar1 = *(char **)(*(long *)(param_1 + 0x38) + 0x20); if (*pcVar1 == -1) { local_9 = 1; } else { *(ulong *)(param_1 + 0x40) = (ulong)((uint)(byte)pcVar1[1] + (uint)(byte)pcVar1[2] * 0x100 + (uint)(byte)pcVar1[3] * 0x10000 + (uint)(byte)pcVar1[4] * 0x1000000); *(uint *)(param_1 + 0x60) = (uint)(byte)pcVar1[5] + (uint)(byte)pcVar1[6] * 0x100 & 0xffff; *(uint *)(param_1 + 100) = (uint)(byte)pcVar1[7] + (uint)(byte)pcVar1[8] * 0x100 & 0xffff; uVar4 = (uint)(byte)pcVar1[10] + (uint)(byte)pcVar1[0xb] * 0x100 & 0xffff; *(uint *)(param_1 + 0xf0) = uVar4; *(uint *)(*(long *)(param_1 + 0x38) + 0x388) = uVar4; if ((*(int *)(param_1 + 100) == 0) || (cVar2 = (**(code **)(*(long *)(*(long *)(param_1 + 0x38) + 0x4d0) + 0x58))(param_1), cVar2 == '\0')) { if ((*(int *)(param_1 + 0x60) == 0) || (cVar2 = (**(code **)(*(long *)(*(long *)(param_1 + 0x38) + 0x4d0) + 0x50))(param_1), cVar2 == '\0')) { if (*(int *)(param_1 + 100) != 0) { if (*(int *)(param_1 + 0x378) == 0) { lVar3 = ma_alloc_root(param_1); *(long *)(param_1 + 0x70) = lVar3; if (lVar3 == 0) { *(int4 *)(param_1 + 0x108) = 0x7d8; strncpy((char *)(param_1 + 0x30d),SQLSTATE_UNKNOWN,5); *(int1 *)(param_1 + 0x312) = 0; strncpy((char *)(param_1 + 0x10c),PTR_s_Client_run_out_of_memory_00349a20,0x200); *(int1 *)(param_1 + 0x30b) = 0; return 1; } memset(*(void **)(param_1 + 0x70),0,(ulong)*(uint *)(param_1 + 100) * 0x70); } else if (*(int *)(param_1 + 0x378) != *(int *)(param_1 + 100)) { *(int4 *)(param_1 + 0x108) = 0x7f2; strncpy((char *)(param_1 + 0x30d),SQLSTATE_UNKNOWN,5); *(int1 *)(param_1 + 0x312) = 0; strncpy((char *)(param_1 + 0x10c),PTR_s_Invalid_parameter_number_00349af0,0x200); *(int1 *)(param_1 + 0x30b) = 0; *(int4 *)(param_1 + 100) = *(int4 *)(param_1 + 0x378); return 1; } } if (*(int *)(param_1 + 0x60) != 0) { lVar3 = ma_alloc_root(*(int8 *)(param_1 + 0x340)); *(long *)(param_1 + 0x78) = lVar3; if (lVar3 == 0) { *(int4 *)(param_1 + 0x108) = 0x7d8; strncpy((char *)(param_1 + 0x30d),SQLSTATE_UNKNOWN,5); *(int1 *)(param_1 + 0x312) = 0; strncpy((char *)(param_1 + 0x10c),PTR_s_Client_run_out_of_memory_00349a20,0x200); *(int1 *)(param_1 + 0x30b) = 0; return 1; } memset(*(void **)(param_1 + 0x78),0,(ulong)*(uint *)(param_1 + 0x60) * 0x70); } *(int4 *)(param_1 + 0x50) = 1; local_9 = 0; } else { local_9 = 1; } } else { local_9 = 1; } } } return local_9; }
60,849
ImageDrawCircle
csit-sgu[P]mit-game-2025_1/Libraries/raylib/src/rtextures.c
void ImageDrawCircle(Image* dst, int centerX, int centerY, int radius, Color color) { int x = 0; int y = radius; int decesionParameter = 3 - 2*radius; while (y >= x) { ImageDrawRectangle(dst, centerX - x, centerY + y, x*2, 1, color); ImageDrawRectangle(dst, centerX - x, centerY - y, x*2, 1, color); ImageDrawRectangle(dst, centerX - y, centerY + x, y*2, 1, color); ImageDrawRectangle(dst, centerX - y, centerY - x, y*2, 1, color); x++; if (decesionParameter > 0) { y--; decesionParameter = decesionParameter + 4*(x - y) + 10; } else decesionParameter = decesionParameter + 4*x + 6; } }
O0
c
ImageDrawCircle: pushq %rbp movq %rsp, %rbp subq $0x30, %rsp movl %r8d, -0x4(%rbp) movq %rdi, -0x10(%rbp) movl %esi, -0x14(%rbp) movl %edx, -0x18(%rbp) movl %ecx, -0x1c(%rbp) movl $0x0, -0x20(%rbp) movl -0x1c(%rbp), %eax movl %eax, -0x24(%rbp) movl -0x1c(%rbp), %ecx shll %ecx movl $0x3, %eax subl %ecx, %eax movl %eax, -0x28(%rbp) movl -0x24(%rbp), %eax cmpl -0x20(%rbp), %eax jl 0x107b75 movq -0x10(%rbp), %rdi movl -0x14(%rbp), %esi subl -0x20(%rbp), %esi movl -0x18(%rbp), %edx addl -0x24(%rbp), %edx movl -0x20(%rbp), %ecx shll %ecx movl -0x4(%rbp), %r9d movl $0x1, %r8d callq 0x107b80 movq -0x10(%rbp), %rdi movl -0x14(%rbp), %esi subl -0x20(%rbp), %esi movl -0x18(%rbp), %edx subl -0x24(%rbp), %edx movl -0x20(%rbp), %ecx shll %ecx movl -0x4(%rbp), %r9d movl $0x1, %r8d callq 0x107b80 movq -0x10(%rbp), %rdi movl -0x14(%rbp), %esi subl -0x24(%rbp), %esi movl -0x18(%rbp), %edx addl -0x20(%rbp), %edx movl -0x24(%rbp), %ecx shll %ecx movl -0x4(%rbp), %r9d movl $0x1, %r8d callq 0x107b80 movq -0x10(%rbp), %rdi movl -0x14(%rbp), %esi subl -0x24(%rbp), %esi movl -0x18(%rbp), %edx subl -0x20(%rbp), %edx movl -0x24(%rbp), %ecx shll %ecx movl -0x4(%rbp), %r9d movl $0x1, %r8d callq 0x107b80 movl -0x20(%rbp), %eax addl $0x1, %eax movl %eax, -0x20(%rbp) cmpl $0x0, -0x28(%rbp) jle 0x107b5f movl -0x24(%rbp), %eax addl $-0x1, %eax movl %eax, -0x24(%rbp) movl -0x28(%rbp), %eax movl -0x20(%rbp), %ecx subl -0x24(%rbp), %ecx shll $0x2, %ecx addl %ecx, %eax addl $0xa, %eax movl %eax, -0x28(%rbp) jmp 0x107b70 movl -0x28(%rbp), %eax movl -0x20(%rbp), %ecx shll $0x2, %ecx addl %ecx, %eax addl $0x6, %eax movl %eax, -0x28(%rbp) jmp 0x107a95 addq $0x30, %rsp popq %rbp retq nopl (%rax,%rax)
ImageDrawCircle: push rbp mov rbp, rsp sub rsp, 30h mov [rbp+var_4], r8d mov [rbp+var_10], rdi mov [rbp+var_14], esi mov [rbp+var_18], edx mov [rbp+var_1C], ecx mov [rbp+var_20], 0 mov eax, [rbp+var_1C] mov [rbp+var_24], eax mov ecx, [rbp+var_1C] shl ecx, 1 mov eax, 3 sub eax, ecx mov [rbp+var_28], eax loc_107A95: mov eax, [rbp+var_24] cmp eax, [rbp+var_20] jl loc_107B75 mov rdi, [rbp+var_10] mov esi, [rbp+var_14] sub esi, [rbp+var_20] mov edx, [rbp+var_18] add edx, [rbp+var_24] mov ecx, [rbp+var_20] shl ecx, 1 mov r9d, [rbp+var_4] mov r8d, 1 call ImageDrawRectangle mov rdi, [rbp+var_10] mov esi, [rbp+var_14] sub esi, [rbp+var_20] mov edx, [rbp+var_18] sub edx, [rbp+var_24] mov ecx, [rbp+var_20] shl ecx, 1 mov r9d, [rbp+var_4] mov r8d, 1 call ImageDrawRectangle mov rdi, [rbp+var_10] mov esi, [rbp+var_14] sub esi, [rbp+var_24] mov edx, [rbp+var_18] add edx, [rbp+var_20] mov ecx, [rbp+var_24] shl ecx, 1 mov r9d, [rbp+var_4] mov r8d, 1 call ImageDrawRectangle mov rdi, [rbp+var_10] mov esi, [rbp+var_14] sub esi, [rbp+var_24] mov edx, [rbp+var_18] sub edx, [rbp+var_20] mov ecx, [rbp+var_24] shl ecx, 1 mov r9d, [rbp+var_4] mov r8d, 1 call ImageDrawRectangle mov eax, [rbp+var_20] add eax, 1 mov [rbp+var_20], eax cmp [rbp+var_28], 0 jle short loc_107B5F mov eax, [rbp+var_24] add eax, 0FFFFFFFFh mov [rbp+var_24], eax mov eax, [rbp+var_28] mov ecx, [rbp+var_20] sub ecx, [rbp+var_24] shl ecx, 2 add eax, ecx add eax, 0Ah mov [rbp+var_28], eax jmp short loc_107B70 loc_107B5F: mov eax, [rbp+var_28] mov ecx, [rbp+var_20] shl ecx, 2 add eax, ecx add eax, 6 mov [rbp+var_28], eax loc_107B70: jmp loc_107A95 loc_107B75: add rsp, 30h pop rbp retn
long long ImageDrawCircle(long long a1, int a2, int a3, unsigned int a4, unsigned int a5) { long long result; // rax int v6; // [rsp+8h] [rbp-28h] unsigned int v7; // [rsp+Ch] [rbp-24h] int v8; // [rsp+10h] [rbp-20h] v8 = 0; v7 = a4; v6 = 3 - 2 * a4; while ( 1 ) { result = v7; if ( (int)v7 < v8 ) break; ImageDrawRectangle(a1, (unsigned int)(a2 - v8), v7 + a3, (unsigned int)(2 * v8), 1LL, a5); ImageDrawRectangle(a1, (unsigned int)(a2 - v8), a3 - v7, (unsigned int)(2 * v8), 1LL, a5); ImageDrawRectangle(a1, a2 - v7, (unsigned int)(v8 + a3), 2 * v7, 1LL, a5); ImageDrawRectangle(a1, a2 - v7, (unsigned int)(a3 - v8++), 2 * v7, 1LL, a5); if ( v6 <= 0 ) { v6 += 4 * v8 + 6; } else { --v7; v6 += 4 * (v8 - v7) + 10; } } return result; }
60,850
ImageDrawCircle
csit-sgu[P]mit-game-2025_1/Libraries/raylib/src/rtextures.c
void ImageDrawCircle(Image* dst, int centerX, int centerY, int radius, Color color) { int x = 0; int y = radius; int decesionParameter = 3 - 2*radius; while (y >= x) { ImageDrawRectangle(dst, centerX - x, centerY + y, x*2, 1, color); ImageDrawRectangle(dst, centerX - x, centerY - y, x*2, 1, color); ImageDrawRectangle(dst, centerX - y, centerY + x, y*2, 1, color); ImageDrawRectangle(dst, centerX - y, centerY - x, y*2, 1, color); x++; if (decesionParameter > 0) { y--; decesionParameter = decesionParameter + 4*(x - y) + 10; } else decesionParameter = decesionParameter + 4*x + 6; } }
O3
c
ImageDrawCircle: pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x58, %rsp movl %r8d, 0x1c(%rsp) movq %rdx, 0x28(%rsp) movl %esi, 0x4(%rsp) movq %rdi, 0x50(%rsp) testl %ecx, %ecx js 0x9a119 movl %ecx, %r14d leal (%r14,%r14), %eax movl $0x3, %ecx subl %eax, %ecx movq %rcx, 0x10(%rsp) movl $0xffffffff, %ebp # imm = 0xFFFFFFFF movl $0xa, %edx xorl %ecx, %ecx movl 0x4(%rsp), %ebx movq 0x28(%rsp), %rax movl %eax, %r13d movl $0x0, 0xc(%rsp) movq 0x50(%rsp), %r12 movl 0x1c(%rsp), %r15d movl %r13d, 0x20(%rsp) movl %edx, 0x8(%rsp) cvtsi2ss %ebx, %xmm3 movaps %xmm3, 0x40(%rsp) movq 0x28(%rsp), %r13 leal (%r14,%r13), %eax cvtsi2ss %eax, %xmm2 movaps 0x3537f(%rip), %xmm1 # 0xcf3a0 movl %ecx, 0x24(%rsp) cvtsi2ss %ecx, %xmm1 movaps %xmm1, 0x30(%rsp) movaps %xmm3, %xmm0 unpcklps %xmm2, %xmm0 # xmm0 = xmm0[0],xmm2[0],xmm0[1],xmm2[1] movq %r12, %rdi movl %r15d, %esi callq 0x9a306 movl %r13d, %eax subl %r14d, %eax xorps %xmm1, %xmm1 cvtsi2ss %eax, %xmm1 movaps 0x40(%rsp), %xmm0 unpcklps %xmm1, %xmm0 # xmm0 = xmm0[0],xmm1[0],xmm0[1],xmm1[1] movq %r12, %rdi movaps 0x30(%rsp), %xmm1 movl %r15d, %esi callq 0x9a306 movl 0x4(%rsp), %eax subl %r14d, %eax xorps %xmm0, %xmm0 cvtsi2ss %eax, %xmm0 movaps %xmm0, 0x40(%rsp) leal 0x1(%r13,%rbp), %eax movl 0x20(%rsp), %r13d xorps %xmm1, %xmm1 cvtsi2ss %eax, %xmm1 leal (%r14,%r14), %eax unpcklps %xmm1, %xmm0 # xmm0 = xmm0[0],xmm1[0],xmm0[1],xmm1[1] movaps 0x3530a(%rip), %xmm1 # 0xcf3a0 cvtsi2ss %eax, %xmm1 movaps %xmm1, 0x30(%rsp) movq %r12, %rdi movl %r15d, %esi callq 0x9a306 xorps %xmm1, %xmm1 cvtsi2ss %r13d, %xmm1 movaps 0x40(%rsp), %xmm0 unpcklps %xmm1, %xmm0 # xmm0 = xmm0[0],xmm1[0],xmm0[1],xmm1[1] movq %r12, %rdi movaps 0x30(%rsp), %xmm1 movl %r15d, %esi callq 0x9a306 movl 0xc(%rsp), %eax incl %eax movq 0x10(%rsp), %rcx testl %ecx, %ecx movl %eax, 0xc(%rsp) jle 0x9a0f4 decl %r14d subl %r14d, %eax leal (%rcx,%rax,4), %ecx addl $0xa, %ecx movq %rcx, 0x10(%rsp) movl 0x8(%rsp), %edx jmp 0x9a0ff movl 0x8(%rsp), %edx addl %edx, %ecx movq %rcx, 0x10(%rsp) incl %ebp addl $0x4, %edx decl %r13d decl %ebx movl 0x24(%rsp), %ecx addl $0x2, %ecx cmpl %ebp, %r14d jg 0x99ffb addq $0x58, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
ImageDrawCircle: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 58h mov [rsp+88h+var_6C], r8d mov [rsp+88h+var_60], rdx mov [rsp+88h+var_84], esi mov [rsp+88h+var_38], rdi test ecx, ecx js loc_9A119 mov r14d, ecx lea eax, [r14+r14] mov ecx, 3 sub ecx, eax mov [rsp+88h+var_78], rcx mov ebp, 0FFFFFFFFh mov edx, 0Ah xor ecx, ecx mov ebx, [rsp+88h+var_84] mov rax, [rsp+88h+var_60] mov r13d, eax mov [rsp+88h+var_7C], 0 mov r12, [rsp+88h+var_38] mov r15d, [rsp+88h+var_6C] loc_99FFB: mov [rsp+88h+var_68], r13d mov [rsp+88h+var_80], edx cvtsi2ss xmm3, ebx movaps [rsp+88h+var_48], xmm3 mov r13, [rsp+88h+var_60] lea eax, [r14+r13] cvtsi2ss xmm2, eax movaps xmm1, cs:xmmword_CF3A0 mov [rsp+88h+var_64], ecx cvtsi2ss xmm1, ecx movaps [rsp+88h+var_58], xmm1 movaps xmm0, xmm3 unpcklps xmm0, xmm2 mov rdi, r12 mov esi, r15d call ImageDrawRectangleRec mov eax, r13d sub eax, r14d xorps xmm1, xmm1 cvtsi2ss xmm1, eax movaps xmm0, [rsp+88h+var_48] unpcklps xmm0, xmm1 mov rdi, r12 movaps xmm1, [rsp+88h+var_58] mov esi, r15d call ImageDrawRectangleRec mov eax, [rsp+88h+var_84] sub eax, r14d xorps xmm0, xmm0 cvtsi2ss xmm0, eax movaps [rsp+88h+var_48], xmm0 lea eax, [r13+rbp+1] mov r13d, [rsp+88h+var_68] xorps xmm1, xmm1 cvtsi2ss xmm1, eax lea eax, [r14+r14] unpcklps xmm0, xmm1 movaps xmm1, cs:xmmword_CF3A0 cvtsi2ss xmm1, eax movaps [rsp+88h+var_58], xmm1 mov rdi, r12 mov esi, r15d call ImageDrawRectangleRec xorps xmm1, xmm1 cvtsi2ss xmm1, r13d movaps xmm0, [rsp+88h+var_48] unpcklps xmm0, xmm1 mov rdi, r12 movaps xmm1, [rsp+88h+var_58] mov esi, r15d call ImageDrawRectangleRec mov eax, [rsp+88h+var_7C] inc eax mov rcx, [rsp+88h+var_78] test ecx, ecx mov [rsp+88h+var_7C], eax jle short loc_9A0F4 dec r14d sub eax, r14d lea ecx, [rcx+rax*4] add ecx, 0Ah mov [rsp+88h+var_78], rcx mov edx, [rsp+88h+var_80] jmp short loc_9A0FF loc_9A0F4: mov edx, [rsp+88h+var_80] add ecx, edx mov [rsp+88h+var_78], rcx loc_9A0FF: inc ebp add edx, 4 dec r13d dec ebx mov ecx, [rsp+88h+var_64] add ecx, 2 cmp r14d, ebp jg loc_99FFB loc_9A119: add rsp, 58h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
void ImageDrawCircle( long long a1, int a2, int a3, int a4, unsigned int a5, double a6, double a7, __m128 a8, __m128 a9) { int v9; // r14d int v10; // ebp int v11; // edx int v12; // ecx int v13; // ebx int v14; // r13d __m128 v16; // xmm1 __m128 v17; // xmm0 __m128 v18; // xmm1 __m128 v19; // xmm1 int v20; // eax int v21; // edx int v22; // [rsp+8h] [rbp-80h] int v23; // [rsp+Ch] [rbp-7Ch] int v24; // [rsp+10h] [rbp-78h] int v25; // [rsp+24h] [rbp-64h] if ( a4 >= 0 ) { v9 = a4; v24 = 3 - 2 * a4; v10 = -1; v11 = 10; v12 = 0; v13 = a2; v14 = a3; v23 = 0; do { v22 = v11; a9.m128_f32[0] = (float)v13; a8.m128_f32[0] = (float)(v9 + a3); v25 = v12; ImageDrawRectangleRec(a1, a5, *(double *)_mm_unpacklo_ps(a9, a8).m128_u64); v16 = 0LL; v16.m128_f32[0] = (float)(a3 - v9); ImageDrawRectangleRec(a1, a5, *(double *)_mm_unpacklo_ps(a9, v16).m128_u64); v17 = 0LL; v17.m128_f32[0] = (float)(a2 - v9); v18 = 0LL; v18.m128_f32[0] = (float)(a3 + v10 + 1); ImageDrawRectangleRec(a1, a5, *(double *)_mm_unpacklo_ps(v17, v18).m128_u64); v19 = 0LL; v19.m128_f32[0] = (float)v14; ImageDrawRectangleRec(a1, a5, *(double *)_mm_unpacklo_ps(v17, v19).m128_u64); v20 = ++v23; if ( v24 <= 0 ) { v21 = v22; v24 += v22; } else { --v9; v24 += 4 * (v20 - v9) + 10; v21 = v22; } ++v10; v11 = v21 + 4; --v14; --v13; v12 = v25 + 2; } while ( v9 > v10 ); } }
ImageDrawCircle: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x58 MOV dword ptr [RSP + 0x1c],R8D MOV qword ptr [RSP + 0x28],RDX MOV dword ptr [RSP + 0x4],ESI MOV qword ptr [RSP + 0x50],RDI TEST ECX,ECX JS 0x0019a119 MOV R14D,ECX LEA EAX,[R14 + R14*0x1] MOV ECX,0x3 SUB ECX,EAX MOV qword ptr [RSP + 0x10],RCX MOV EBP,0xffffffff MOV EDX,0xa XOR ECX,ECX MOV EBX,dword ptr [RSP + 0x4] MOV RAX,qword ptr [RSP + 0x28] MOV R13D,EAX MOV dword ptr [RSP + 0xc],0x0 MOV R12,qword ptr [RSP + 0x50] MOV R15D,dword ptr [RSP + 0x1c] LAB_00199ffb: MOV dword ptr [RSP + 0x20],R13D MOV dword ptr [RSP + 0x8],EDX CVTSI2SS XMM3,EBX MOVAPS xmmword ptr [RSP + 0x40],XMM3 MOV R13,qword ptr [RSP + 0x28] LEA EAX,[R14 + R13*0x1] CVTSI2SS XMM2,EAX MOVAPS XMM1,xmmword ptr [0x001cf3a0] MOV dword ptr [RSP + 0x24],ECX CVTSI2SS XMM1,ECX MOVAPS xmmword ptr [RSP + 0x30],XMM1 MOVAPS XMM0,XMM3 UNPCKLPS XMM0,XMM2 MOV RDI,R12 MOV ESI,R15D CALL 0x0019a306 MOV EAX,R13D SUB EAX,R14D XORPS XMM1,XMM1 CVTSI2SS XMM1,EAX MOVAPS XMM0,xmmword ptr [RSP + 0x40] UNPCKLPS XMM0,XMM1 MOV RDI,R12 MOVAPS XMM1,xmmword ptr [RSP + 0x30] MOV ESI,R15D CALL 0x0019a306 MOV EAX,dword ptr [RSP + 0x4] SUB EAX,R14D XORPS XMM0,XMM0 CVTSI2SS XMM0,EAX MOVAPS xmmword ptr [RSP + 0x40],XMM0 LEA EAX,[R13 + RBP*0x1 + 0x1] MOV R13D,dword ptr [RSP + 0x20] XORPS XMM1,XMM1 CVTSI2SS XMM1,EAX LEA EAX,[R14 + R14*0x1] UNPCKLPS XMM0,XMM1 MOVAPS XMM1,xmmword ptr [0x001cf3a0] CVTSI2SS XMM1,EAX MOVAPS xmmword ptr [RSP + 0x30],XMM1 MOV RDI,R12 MOV ESI,R15D CALL 0x0019a306 XORPS XMM1,XMM1 CVTSI2SS XMM1,R13D MOVAPS XMM0,xmmword ptr [RSP + 0x40] UNPCKLPS XMM0,XMM1 MOV RDI,R12 MOVAPS XMM1,xmmword ptr [RSP + 0x30] MOV ESI,R15D CALL 0x0019a306 MOV EAX,dword ptr [RSP + 0xc] INC EAX MOV RCX,qword ptr [RSP + 0x10] TEST ECX,ECX MOV dword ptr [RSP + 0xc],EAX JLE 0x0019a0f4 DEC R14D SUB EAX,R14D LEA ECX,[RCX + RAX*0x4] ADD ECX,0xa MOV qword ptr [RSP + 0x10],RCX MOV EDX,dword ptr [RSP + 0x8] JMP 0x0019a0ff LAB_0019a0f4: MOV EDX,dword ptr [RSP + 0x8] ADD ECX,EDX MOV qword ptr [RSP + 0x10],RCX LAB_0019a0ff: INC EBP ADD EDX,0x4 DEC R13D DEC EBX MOV ECX,dword ptr [RSP + 0x24] ADD ECX,0x2 CMP R14D,EBP JG 0x00199ffb LAB_0019a119: ADD RSP,0x58 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
/* WARNING: Globals starting with '_' overlap smaller symbols at the same address */ void ImageDrawCircle(int8 param_1,int param_2,int param_3,int param_4,int4 param_5) { int iVar1; int iVar2; int iVar3; int iVar4; int iVar5; int4 local_7c; if (-1 < param_4) { iVar1 = param_4 * -2 + 3; iVar5 = -1; iVar3 = 10; iVar2 = 0; local_7c = 0; iVar4 = param_2; do { ImageDrawRectangleRec((float)iVar4,(float)iVar2,(float)(param_4 + param_3),param_1,param_5); ImageDrawRectangleRec((float)iVar4,(float)iVar2,param_1,param_5); ImageDrawRectangleRec(param_1,param_5); ImageDrawRectangleRec((float)(param_2 - param_4),(float)(param_4 * 2),param_1,param_5); local_7c = local_7c + 1; if (iVar1 < 1) { iVar1 = iVar1 + iVar3; } else { param_4 = param_4 + -1; iVar1 = iVar1 + (local_7c - param_4) * 4 + 10; } iVar5 = iVar5 + 1; iVar3 = iVar3 + 4; iVar4 = iVar4 + -1; iVar2 = iVar2 + 2; } while (iVar5 < param_4); } return; }
60,851
std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> ParseFieldsToJson<Checked<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>> const&, Checked<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>> const&, Checked<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>> const&, Checked<bool> const&, Checked<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>> const&, Checked<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>> const&, Checked<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>> const&>(Checked<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>> const&, Checked<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>> const&, Checked<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>> const&, Checked<bool> const&, Checked<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>> const&, Checked<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>> const&, Checked<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>> const&)
kubecpp/include/kubecpp/common/json_utils.h
inline std::string ParseFieldsToJson(Fields&&... fields) { rapidjson::StringBuffer lStringBuffer; rapidjson::Writer lWriter(lStringBuffer); lWriter.StartObject(); (SetField(lWriter, fields), ...); lWriter.EndObject(); return lStringBuffer.GetString(); }
O0
c
std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> ParseFieldsToJson<Checked<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>> const&, Checked<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>> const&, Checked<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>> const&, Checked<bool> const&, Checked<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>> const&, Checked<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>> const&, Checked<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>> const&>(Checked<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>> const&, Checked<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>> const&, Checked<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>> const&, Checked<bool> const&, Checked<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>> const&, Checked<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>> const&, Checked<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>> const&): subq $0xe8, %rsp movq %rdi, 0x18(%rsp) movq %rdi, %rax movq %rax, 0x20(%rsp) movq 0xf0(%rsp), %rax movq %rdi, 0xe0(%rsp) movq %rsi, 0xd8(%rsp) movq %rdx, 0xd0(%rsp) movq %rcx, 0xc8(%rsp) movq %r8, 0xc0(%rsp) movq %r9, 0xb8(%rsp) xorl %eax, %eax movl %eax, %esi movq %rsi, 0x30(%rsp) leaq 0x88(%rsp), %rdi movq %rdi, 0x28(%rsp) movl $0x100, %edx # imm = 0x100 callq 0x111b30 movq 0x28(%rsp), %rsi movq 0x30(%rsp), %rdx leaq 0x48(%rsp), %rdi movl $0x20, %ecx callq 0x111b60 jmp 0x2016c7 leaq 0x48(%rsp), %rdi callq 0x111bc0 jmp 0x2016d3 movq 0xd8(%rsp), %rsi leaq 0x48(%rsp), %rdi callq 0x111ca0 jmp 0x2016e7 movq 0xd0(%rsp), %rsi leaq 0x48(%rsp), %rdi callq 0x111ca0 jmp 0x2016fb movq 0xc8(%rsp), %rsi leaq 0x48(%rsp), %rdi callq 0x111ca0 jmp 0x20170f movq 0xc0(%rsp), %rsi leaq 0x48(%rsp), %rdi callq 0x113150 jmp 0x201723 movq 0xb8(%rsp), %rsi leaq 0x48(%rsp), %rdi callq 0x111ca0 jmp 0x201737 movq 0xf0(%rsp), %rsi leaq 0x48(%rsp), %rdi callq 0x111ca0 jmp 0x20174b leaq 0x48(%rsp), %rdi xorl %esi, %esi callq 0x111ea0 jmp 0x201759 leaq 0x88(%rsp), %rdi callq 0x111ef0 movq %rax, 0x10(%rsp) jmp 0x20176d leaq 0x3b(%rsp), %rdi movq %rdi, 0x8(%rsp) callq 0x8d2d0 movq 0x18(%rsp), %rdi movq 0x10(%rsp), %rsi movq 0x8(%rsp), %rdx callq 0x8f540 jmp 0x201792 leaq 0x3b(%rsp), %rdi callq 0x8d740 leaq 0x48(%rsp), %rdi callq 0x111fc0 leaq 0x88(%rsp), %rdi callq 0x111fe0 movq 0x20(%rsp), %rax addq $0xe8, %rsp retq movq %rax, %rcx movl %edx, %eax movq %rcx, 0x40(%rsp) movl %eax, 0x3c(%rsp) jmp 0x201802 movq %rax, %rcx movl %edx, %eax movq %rcx, 0x40(%rsp) movl %eax, 0x3c(%rsp) jmp 0x2017f8 movq %rax, %rcx movl %edx, %eax movq %rcx, 0x40(%rsp) movl %eax, 0x3c(%rsp) leaq 0x3b(%rsp), %rdi callq 0x8d740 leaq 0x48(%rsp), %rdi callq 0x111fc0 leaq 0x88(%rsp), %rdi callq 0x111fe0 movq 0x40(%rsp), %rdi callq 0x8ccd0 nopl (%rax)
_Z17ParseFieldsToJsonIJRK7CheckedINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEES9_S9_RKS0_IbES9_S9_EES6_DpOT_: sub rsp, 0E8h mov qword ptr [rsp+0E8h+var_D0], rdi; int mov rax, rdi mov qword ptr [rsp+0E8h+var_C8], rax; int mov rax, qword ptr [rsp+0E8h+arg_0] mov [rsp+0E8h+var_8], rdi mov qword ptr [rsp+0E8h+var_10], rsi mov qword ptr [rsp+0E8h+var_18], rdx mov qword ptr [rsp+0E8h+var_20], rcx mov qword ptr [rsp+0E8h+var_28], r8 mov qword ptr [rsp+0E8h+var_30], r9 xor eax, eax mov esi, eax mov qword ptr [rsp+0E8h+var_B8], rsi; char lea rdi, [rsp+0E8h+var_60] mov qword ptr [rsp+0E8h+var_C0], rdi; int mov edx, 100h call _ZN9rapidjson19GenericStringBufferINS_4UTF8IcEENS_12CrtAllocatorEEC2EPS3_m; rapidjson::GenericStringBuffer<rapidjson::UTF8<char>,rapidjson::CrtAllocator>::GenericStringBuffer(rapidjson::CrtAllocator*,ulong) mov rsi, qword ptr [rsp+0E8h+var_C0] mov rdx, qword ptr [rsp+0E8h+var_B8] lea rdi, [rsp+0E8h+var_A0] mov ecx, 20h ; ' ' call _ZN9rapidjson6WriterINS_19GenericStringBufferINS_4UTF8IcEENS_12CrtAllocatorEEES3_S3_S4_Lj0EEC2ERS5_PS4_m; rapidjson::Writer<rapidjson::GenericStringBuffer<rapidjson::UTF8<char>,rapidjson::CrtAllocator>,rapidjson::UTF8<char>,rapidjson::UTF8<char>,rapidjson::CrtAllocator,0u>::Writer(rapidjson::GenericStringBuffer<rapidjson::UTF8<char>,rapidjson::CrtAllocator>&,rapidjson::CrtAllocator*,ulong) jmp short $+2 loc_2016C7: lea rdi, [rsp+0E8h+var_A0] call _ZN9rapidjson6WriterINS_19GenericStringBufferINS_4UTF8IcEENS_12CrtAllocatorEEES3_S3_S4_Lj0EE11StartObjectEv; rapidjson::Writer<rapidjson::GenericStringBuffer<rapidjson::UTF8<char>,rapidjson::CrtAllocator>,rapidjson::UTF8<char>,rapidjson::UTF8<char>,rapidjson::CrtAllocator,0u>::StartObject(void) jmp short $+2 loc_2016D3: mov rsi, qword ptr [rsp+0E8h+var_10]; int lea rdi, [rsp+0E8h+var_A0]; int call _Z8SetFieldINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEvRN9rapidjson6WriterINS6_19GenericStringBufferINS6_4UTF8IcEENS6_12CrtAllocatorEEESA_SA_SB_Lj0EEERK7CheckedIT_E; SetField<std::string>(rapidjson::Writer<rapidjson::GenericStringBuffer<rapidjson::UTF8<char>,rapidjson::CrtAllocator>,rapidjson::UTF8<char>,rapidjson::UTF8<char>,rapidjson::CrtAllocator,0u> &,Checked<std::string> const&) jmp short $+2 loc_2016E7: mov rsi, qword ptr [rsp+0E8h+var_18]; int lea rdi, [rsp+0E8h+var_A0]; int call _Z8SetFieldINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEvRN9rapidjson6WriterINS6_19GenericStringBufferINS6_4UTF8IcEENS6_12CrtAllocatorEEESA_SA_SB_Lj0EEERK7CheckedIT_E; SetField<std::string>(rapidjson::Writer<rapidjson::GenericStringBuffer<rapidjson::UTF8<char>,rapidjson::CrtAllocator>,rapidjson::UTF8<char>,rapidjson::UTF8<char>,rapidjson::CrtAllocator,0u> &,Checked<std::string> const&) jmp short $+2 loc_2016FB: mov rsi, qword ptr [rsp+0E8h+var_20]; int lea rdi, [rsp+0E8h+var_A0]; int call _Z8SetFieldINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEvRN9rapidjson6WriterINS6_19GenericStringBufferINS6_4UTF8IcEENS6_12CrtAllocatorEEESA_SA_SB_Lj0EEERK7CheckedIT_E; SetField<std::string>(rapidjson::Writer<rapidjson::GenericStringBuffer<rapidjson::UTF8<char>,rapidjson::CrtAllocator>,rapidjson::UTF8<char>,rapidjson::UTF8<char>,rapidjson::CrtAllocator,0u> &,Checked<std::string> const&) jmp short $+2 loc_20170F: mov rsi, qword ptr [rsp+0E8h+var_28]; int lea rdi, [rsp+0E8h+var_A0]; int call _Z8SetFieldIbEvRN9rapidjson6WriterINS0_19GenericStringBufferINS0_4UTF8IcEENS0_12CrtAllocatorEEES4_S4_S5_Lj0EEERK7CheckedIT_E; SetField<bool>(rapidjson::Writer<rapidjson::GenericStringBuffer<rapidjson::UTF8<char>,rapidjson::CrtAllocator>,rapidjson::UTF8<char>,rapidjson::UTF8<char>,rapidjson::CrtAllocator,0u> &,Checked<bool> const&) jmp short $+2 loc_201723: mov rsi, qword ptr [rsp+0E8h+var_30]; int lea rdi, [rsp+0E8h+var_A0]; int call _Z8SetFieldINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEvRN9rapidjson6WriterINS6_19GenericStringBufferINS6_4UTF8IcEENS6_12CrtAllocatorEEESA_SA_SB_Lj0EEERK7CheckedIT_E; SetField<std::string>(rapidjson::Writer<rapidjson::GenericStringBuffer<rapidjson::UTF8<char>,rapidjson::CrtAllocator>,rapidjson::UTF8<char>,rapidjson::UTF8<char>,rapidjson::CrtAllocator,0u> &,Checked<std::string> const&) jmp short $+2 loc_201737: mov rsi, qword ptr [rsp+0E8h+arg_0]; int lea rdi, [rsp+0E8h+var_A0]; int call _Z8SetFieldINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEvRN9rapidjson6WriterINS6_19GenericStringBufferINS6_4UTF8IcEENS6_12CrtAllocatorEEESA_SA_SB_Lj0EEERK7CheckedIT_E; SetField<std::string>(rapidjson::Writer<rapidjson::GenericStringBuffer<rapidjson::UTF8<char>,rapidjson::CrtAllocator>,rapidjson::UTF8<char>,rapidjson::UTF8<char>,rapidjson::CrtAllocator,0u> &,Checked<std::string> const&) jmp short $+2 loc_20174B: lea rdi, [rsp+0E8h+var_A0] xor esi, esi call _ZN9rapidjson6WriterINS_19GenericStringBufferINS_4UTF8IcEENS_12CrtAllocatorEEES3_S3_S4_Lj0EE9EndObjectEj; rapidjson::Writer<rapidjson::GenericStringBuffer<rapidjson::UTF8<char>,rapidjson::CrtAllocator>,rapidjson::UTF8<char>,rapidjson::UTF8<char>,rapidjson::CrtAllocator,0u>::EndObject(uint) jmp short $+2 loc_201759: lea rdi, [rsp+0E8h+var_60] call _ZNK9rapidjson19GenericStringBufferINS_4UTF8IcEENS_12CrtAllocatorEE9GetStringEv; rapidjson::GenericStringBuffer<rapidjson::UTF8<char>,rapidjson::CrtAllocator>::GetString(void) mov [rsp+0E8h+var_D8], rax jmp short $+2 loc_20176D: lea rdi, [rsp+0E8h+var_AD] mov [rsp+0E8h+var_E0], rdi call __ZNSaIcEC1Ev; std::allocator<char>::allocator(void) mov rdi, qword ptr [rsp+0E8h+var_D0] mov rsi, [rsp+0E8h+var_D8] mov rdx, [rsp+0E8h+var_E0] call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&) jmp short $+2 loc_201792: lea rdi, [rsp+0E8h+var_AD] call __ZNSaIcED1Ev; std::allocator<char>::~allocator() lea rdi, [rsp+0E8h+var_A0] call _ZN9rapidjson6WriterINS_19GenericStringBufferINS_4UTF8IcEENS_12CrtAllocatorEEES3_S3_S4_Lj0EED2Ev; rapidjson::Writer<rapidjson::GenericStringBuffer<rapidjson::UTF8<char>,rapidjson::CrtAllocator>,rapidjson::UTF8<char>,rapidjson::UTF8<char>,rapidjson::CrtAllocator,0u>::~Writer() lea rdi, [rsp+0E8h+var_60] call _ZN9rapidjson19GenericStringBufferINS_4UTF8IcEENS_12CrtAllocatorEED2Ev; rapidjson::GenericStringBuffer<rapidjson::UTF8<char>,rapidjson::CrtAllocator>::~GenericStringBuffer() mov rax, qword ptr [rsp+0E8h+var_C8] add rsp, 0E8h retn mov rcx, rax mov eax, edx mov [rsp+arg_38], rcx mov [rsp+arg_34], eax jmp short loc_201802 mov rcx, rax mov eax, edx mov [rsp+arg_38], rcx mov [rsp+arg_34], eax jmp short loc_2017F8 mov rcx, rax mov eax, edx mov [rsp+arg_38], rcx mov [rsp+arg_34], eax lea rdi, [rsp+arg_33] call __ZNSaIcED1Ev; std::allocator<char>::~allocator() loc_2017F8: lea rdi, [rsp+arg_40] call _ZN9rapidjson6WriterINS_19GenericStringBufferINS_4UTF8IcEENS_12CrtAllocatorEEES3_S3_S4_Lj0EED2Ev; rapidjson::Writer<rapidjson::GenericStringBuffer<rapidjson::UTF8<char>,rapidjson::CrtAllocator>,rapidjson::UTF8<char>,rapidjson::UTF8<char>,rapidjson::CrtAllocator,0u>::~Writer() loc_201802: lea rdi, [rsp+arg_80] call _ZN9rapidjson19GenericStringBufferINS_4UTF8IcEENS_12CrtAllocatorEED2Ev; rapidjson::GenericStringBuffer<rapidjson::UTF8<char>,rapidjson::CrtAllocator>::~GenericStringBuffer() mov rdi, [rsp+arg_38] call __Unwind_Resume
long long ParseFieldsToJson<Checked<std::string> const&,Checked<std::string> const&,Checked<std::string> const&,Checked const&<bool>,Checked<std::string> const&,Checked<std::string> const&>( long long a1, long long a2, long long a3, long long a4, long long a5, long long a6, long long a7) { long long v7; // r8 long long v8; // r9 long long v9; // rdx long long String; // [rsp+10h] [rbp-D8h] _BYTE v12[13]; // [rsp+3Bh] [rbp-ADh] BYREF _QWORD v13[8]; // [rsp+48h] [rbp-A0h] BYREF char v14[48]; // [rsp+88h] [rbp-60h] BYREF int v15[2]; // [rsp+B8h] [rbp-30h] int v16[2]; // [rsp+C0h] [rbp-28h] int v17[2]; // [rsp+C8h] [rbp-20h] int v18[2]; // [rsp+D0h] [rbp-18h] int v19[2]; // [rsp+D8h] [rbp-10h] long long v20; // [rsp+E0h] [rbp-8h] v20 = a1; *(_QWORD *)v19 = a2; *(_QWORD *)v18 = a3; *(_QWORD *)v17 = a4; *(_QWORD *)v16 = a5; *(_QWORD *)v15 = a6; rapidjson::GenericStringBuffer<rapidjson::UTF8<char>,rapidjson::CrtAllocator>::GenericStringBuffer( (long long)v14, 0LL, 256LL, a4, a5, a6); rapidjson::Writer<rapidjson::GenericStringBuffer<rapidjson::UTF8<char>,rapidjson::CrtAllocator>,rapidjson::UTF8<char>,rapidjson::UTF8<char>,rapidjson::CrtAllocator,0u>::Writer( v13, (long long)v14, 0LL, 32LL, v7, v8); rapidjson::Writer<rapidjson::GenericStringBuffer<rapidjson::UTF8<char>,rapidjson::CrtAllocator>,rapidjson::UTF8<char>,rapidjson::UTF8<char>,rapidjson::CrtAllocator,0u>::StartObject((long long)v13); SetField<std::string>((long long)v13, *(long long *)v19); SetField<std::string>((long long)v13, *(long long *)v18); SetField<std::string>((long long)v13, *(long long *)v17); SetField<bool>((long long)v13, *(long long *)v16); SetField<std::string>((long long)v13, *(long long *)v15); SetField<std::string>((long long)v13, a7); rapidjson::Writer<rapidjson::GenericStringBuffer<rapidjson::UTF8<char>,rapidjson::CrtAllocator>,rapidjson::UTF8<char>,rapidjson::UTF8<char>,rapidjson::CrtAllocator,0u>::EndObject((long long)v13); String = rapidjson::GenericStringBuffer<rapidjson::UTF8<char>,rapidjson::CrtAllocator>::GetString((long long)v14); std::allocator<char>::allocator(v12, 0LL, v9); std::string::basic_string<std::allocator<char>>(a1, String, (long long)v12); std::allocator<char>::~allocator(v12); rapidjson::Writer<rapidjson::GenericStringBuffer<rapidjson::UTF8<char>,rapidjson::CrtAllocator>,rapidjson::UTF8<char>,rapidjson::UTF8<char>,rapidjson::CrtAllocator,0u>::~Writer((long long)v13); rapidjson::GenericStringBuffer<rapidjson::UTF8<char>,rapidjson::CrtAllocator>::~GenericStringBuffer((long long)v14); return a1; }
set_option<cpr::Url,std::map<std::__cxx11::string,std::__cxx11::string,cpr::CaseInsensitiveCompare,std::allocator<std::pair<std::__cxx11::string_const,std::__cxx11::string>>>const&,cpr::Body,cpr::SslOptions_const&,cpr::Bearer>: SUB RSP,0x38 MOV qword ptr [RSP + 0x30],RDI MOV qword ptr [RSP + 0x28],RSI MOV qword ptr [RSP + 0x20],RDX MOV qword ptr [RSP + 0x18],RCX MOV qword ptr [RSP + 0x10],R8 MOV qword ptr [RSP + 0x8],R9 MOV RDI,qword ptr [RSP + 0x30] MOV RSI,qword ptr [RSP + 0x28] MOV RDX,qword ptr [RSP + 0x20] MOV RCX,qword ptr [RSP + 0x18] MOV R8,qword ptr [RSP + 0x10] MOV R9,qword ptr [RSP + 0x8] CALL 0x00201770 ADD RSP,0x38 RET
/* void cpr::priv::set_option<cpr::Url, std::map<std::__cxx11::string, std::__cxx11::string, cpr::CaseInsensitiveCompare, std::allocator<std::pair<std::__cxx11::string const, std::__cxx11::string > > > const&, cpr::Body, cpr::SslOptions const&, cpr::Bearer>(cpr::Session&, cpr::Url&&, std::map<std::__cxx11::string, std::__cxx11::string, cpr::CaseInsensitiveCompare, std::allocator<std::pair<std::__cxx11::string const, std::__cxx11::string > > > const&, cpr::Body&&, cpr::SslOptions const&, cpr::Bearer&&) */ void cpr::priv:: set_option<cpr::Url,std::map<std::__cxx11::string,std::__cxx11::string,cpr::CaseInsensitiveCompare,std::allocator<std::pair<std::__cxx11::string_const,std::__cxx11::string>>>const&,cpr::Body,cpr::SslOptions_const&,cpr::Bearer> (Session *param_1,Url *param_2,map *param_3,Body *param_4,SslOptions *param_5, Bearer *param_6) { set_option_internal<false,cpr::Url,std::map<std::__cxx11::string,std::__cxx11::string,cpr::CaseInsensitiveCompare,std::allocator<std::pair<std::__cxx11::string_const,std::__cxx11::string>>>const&,cpr::Body,cpr::SslOptions_const&,cpr::Bearer> (param_1,param_2,param_3,param_4,param_5,param_6); return; }
60,852
httplib::detail::make_multipart_data_boundary[abi:cxx11]()
nickolajgrishuk[P]metricz-cpp/build_O2/_deps/httplib-src/httplib.h
inline std::string make_multipart_data_boundary() { static const char data[] = "0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz"; // std::random_device might actually be deterministic on some // platforms, but due to lack of support in the c++ standard library, // doing better requires either some ugly hacks or breaking portability. std::random_device seed_gen; // Request 128 bits of entropy for initialization std::seed_seq seed_sequence{seed_gen(), seed_gen(), seed_gen(), seed_gen()}; std::mt19937 engine(seed_sequence); std::string result = "--cpp-httplib-multipart-data-"; for (auto i = 0; i < 16; i++) { result += data[engine() % (sizeof(data) - 1)]; } return result; }
O2
c
httplib::detail::make_multipart_data_boundary[abi:cxx11](): pushq %rbp pushq %r15 pushq %r14 pushq %r12 pushq %rbx subq $0x2730, %rsp # imm = 0x2730 movq %rdi, %rbx leaq 0x13a8(%rsp), %r14 movq %r14, %rdi callq 0x193c4 movq %r14, %rdi callq 0x87e0 movl %eax, 0x20(%rsp) leaq 0x13a8(%rsp), %rdi callq 0x87e0 movl %eax, 0x24(%rsp) leaq 0x13a8(%rsp), %rdi callq 0x87e0 movl %eax, 0x28(%rsp) leaq 0x13a8(%rsp), %rdi callq 0x87e0 leaq 0x20(%rsp), %rsi movl %eax, 0xc(%rsi) leaq 0x8(%rsp), %rdi pushq $0x4 popq %rdx callq 0x1941a leaq 0x20(%rsp), %rdi leaq 0x8(%rsp), %rsi callq 0x19702 leaq 0x10344(%rip), %rsi # 0x29291 leaq 0x7(%rsp), %rdx movq %rbx, %rdi callq 0x8220 pushq $0x10 popq %rbp leaq 0x20(%rsp), %r14 pushq $0x3e popq %r15 leaq 0x115f3(%rip), %r12 # 0x2a560 subl $0x1, %ebp jb 0x18f8e movq %r14, %rdi callq 0x19490 xorl %edx, %edx divq %r15 movsbl (%rdx,%r12), %esi movq %rbx, %rdi callq 0x84b0 jmp 0x18f6d leaq 0x8(%rsp), %rdi callq 0x196f4 leaq 0x13a8(%rsp), %rdi callq 0x194f4 movq %rbx, %rax addq $0x2730, %rsp # imm = 0x2730 popq %rbx popq %r12 popq %r14 popq %r15 popq %rbp retq jmp 0x18fba movq %rax, %r14 jmp 0x18fcf movq %rax, %r14 jmp 0x18fd9 movq %rax, %r14 movq %rbx, %rdi callq 0x8ac8 leaq 0x8(%rsp), %rdi callq 0x196f4 leaq 0x13a8(%rsp), %rdi callq 0x194f4 movq %r14, %rdi callq 0x89d0
_ZN7httplib6detail28make_multipart_data_boundaryB5cxx11Ev: push rbp push r15 push r14 push r12 push rbx sub rsp, 2730h mov rbx, rdi lea r14, [rsp+2758h+var_13B0] mov rdi, r14; this call _ZNSt13random_deviceC2Ev; std::random_device::random_device(void) mov rdi, r14; this call __ZNSt13random_device9_M_getvalEv; std::random_device::_M_getval(void) mov [rsp+2758h+var_2738], eax lea rdi, [rsp+2758h+var_13B0]; this call __ZNSt13random_device9_M_getvalEv; std::random_device::_M_getval(void) mov [rsp+2758h+var_2734], eax lea rdi, [rsp+2758h+var_13B0]; this call __ZNSt13random_device9_M_getvalEv; std::random_device::_M_getval(void) mov [rsp+2758h+var_2730], eax lea rdi, [rsp+2758h+var_13B0]; this call __ZNSt13random_device9_M_getvalEv; std::random_device::_M_getval(void) lea rsi, [rsp+2758h+var_2738] mov [rsi+0Ch], eax lea rdi, [rsp+2758h+var_2750] push 4 pop rdx call _ZNSt8seed_seqC2IjvEESt16initializer_listIT_E; std::seed_seq::seed_seq<uint,void>(std::initializer_list<uint>) lea rdi, [rsp+2758h+var_2738] lea rsi, [rsp+2758h+var_2750] call _ZNSt23mersenne_twister_engineImLm32ELm624ELm397ELm31ELm2567483615ELm11ELm4294967295ELm7ELm2636928640ELm15ELm4022730752ELm18ELm1812433253EE4seedISt8seed_seqEENSt9enable_ifIXsr8__detail13__is_seed_seqIT_S0_mEE5valueEvE4typeERS4_ lea rsi, aCppHttplibMult; "--cpp-httplib-multipart-data-" lea rdx, [rsp+2758h+var_2751] mov rdi, rbx call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2EPKcRKS3_; std::string::basic_string(char const*,std::allocator<char> const&) push 10h pop rbp lea r14, [rsp+2758h+var_2738] push 3Eh ; '>' pop r15 lea r12, _ZZN7httplib6detail28make_multipart_data_boundaryB5cxx11EvE4data; "0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabc"... loc_18F6D: sub ebp, 1 jb short loc_18F8E mov rdi, r14 call _ZNSt23mersenne_twister_engineImLm32ELm624ELm397ELm31ELm2567483615ELm11ELm4294967295ELm7ELm2636928640ELm15ELm4022730752ELm18ELm1812433253EEclEv; std::mersenne_twister_engine<ulong,32ul,624ul,397ul,31ul,2567483615ul,11ul,4294967295ul,7ul,2636928640ul,15ul,4022730752ul,18ul,1812433253ul>::operator()(void) xor edx, edx div r15 movsx esi, byte ptr [rdx+r12] mov rdi, rbx call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9push_backEc; std::string::push_back(char) jmp short loc_18F6D loc_18F8E: lea rdi, [rsp+2758h+var_2750] call _ZNSt12_Vector_baseIjSaIjEED2Ev; std::_Vector_base<uint>::~_Vector_base() lea rdi, [rsp+2758h+var_13B0]; this call _ZNSt13random_deviceD2Ev; std::random_device::~random_device() mov rax, rbx add rsp, 2730h pop rbx pop r12 pop r14 pop r15 pop rbp retn jmp short $+2 loc_18FBA: mov r14, rax jmp short loc_18FCF mov r14, rax jmp short loc_18FD9 mov r14, rax mov rdi, rbx; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() loc_18FCF: lea rdi, [rsp+arg_0] call _ZNSt12_Vector_baseIjSaIjEED2Ev; std::_Vector_base<uint>::~_Vector_base() loc_18FD9: lea rdi, [rsp+arg_13A0]; this call _ZNSt13random_deviceD2Ev; std::random_device::~random_device() mov rdi, r14 call __Unwind_Resume
long long httplib::detail::make_multipart_data_boundary[abi:cxx11](long long a1) { int v1; // ebp unsigned long long v3; // rax char v5; // [rsp+7h] [rbp-2751h] BYREF _BYTE v6[24]; // [rsp+8h] [rbp-2750h] BYREF _DWORD v7[1250]; // [rsp+20h] [rbp-2738h] BYREF _BYTE v8[5040]; // [rsp+13A8h] [rbp-13B0h] BYREF std::random_device::random_device((std::random_device *)v8); v7[0] = std::random_device::_M_getval((std::random_device *)v8); v7[1] = std::random_device::_M_getval((std::random_device *)v8); v7[2] = std::random_device::_M_getval((std::random_device *)v8); v7[3] = std::random_device::_M_getval((std::random_device *)v8); std::seed_seq::seed_seq<unsigned int,void>(v6, v7, 4LL); std::mersenne_twister_engine<unsigned long,32ul,624ul,397ul,31ul,2567483615ul,11ul,4294967295ul,7ul,2636928640ul,15ul,4022730752ul,18ul,1812433253ul>::seed<std::seed_seq>( v7, v6); std::string::basic_string(a1, "--cpp-httplib-multipart-data-", &v5); v1 = 16; while ( v1-- != 0 ) { v3 = std::mersenne_twister_engine<unsigned long,32ul,624ul,397ul,31ul,2567483615ul,11ul,4294967295ul,7ul,2636928640ul,15ul,4022730752ul,18ul,1812433253ul>::operator()(v7); std::string::push_back( a1, (unsigned int)httplib::detail::make_multipart_data_boundary[abi:cxx11](void)::data[v3 % 0x3E]); } std::_Vector_base<unsigned int>::~_Vector_base(v6); std::random_device::~random_device((std::random_device *)v8); return a1; }
make_multipart_data_boundary[abi:cxx11]: PUSH RBP PUSH R15 PUSH R14 PUSH R12 PUSH RBX SUB RSP,0x2730 MOV RBX,RDI LEA R14,[RSP + 0x13a8] MOV RDI,R14 CALL 0x001193c4 LAB_00118ee7: MOV RDI,R14 CALL 0x001087e0 MOV dword ptr [RSP + 0x20],EAX LEA RDI,[RSP + 0x13a8] CALL 0x001087e0 MOV dword ptr [RSP + 0x24],EAX LEA RDI,[RSP + 0x13a8] CALL 0x001087e0 MOV dword ptr [RSP + 0x28],EAX LEA RDI,[RSP + 0x13a8] CALL 0x001087e0 LEA RSI,[RSP + 0x20] MOV dword ptr [RSI + 0xc],EAX LEA RDI,[RSP + 0x8] PUSH 0x4 POP RDX CALL 0x0011941a LAB_00118f37: LEA RDI,[RSP + 0x20] LEA RSI,[RSP + 0x8] CALL 0x00119702 LAB_00118f46: LEA RSI,[0x129291] LEA RDX,[RSP + 0x7] MOV RDI,RBX CALL 0x00108220 PUSH 0x10 POP RBP LEA R14,[RSP + 0x20] PUSH 0x3e POP R15 LEA R12,[0x12a560] LAB_00118f6d: SUB EBP,0x1 JC 0x00118f8e LAB_00118f72: MOV RDI,R14 CALL 0x00119490 XOR EDX,EDX DIV R15 MOVSX ESI,byte ptr [RDX + R12*0x1] MOV RDI,RBX CALL 0x001084b0 LAB_00118f8c: JMP 0x00118f6d LAB_00118f8e: LEA RDI,[RSP + 0x8] CALL 0x001196f4 LEA RDI,[RSP + 0x13a8] CALL 0x001194f4 MOV RAX,RBX ADD RSP,0x2730 POP RBX POP R12 POP R14 POP R15 POP RBP RET
/* httplib::detail::make_multipart_data_boundary[abi:cxx11]() */ detail * __thiscall httplib::detail::make_multipart_data_boundary_abi_cxx11_(detail *this) { int iVar1; bool bVar2; allocator local_2751; seed_seq local_2750 [24]; int4 local_2738; int4 local_2734; int4 local_2730; int4 local_272c; random_device local_13b0 [5000]; std::random_device::random_device(local_13b0); /* try { // try from 00118ee7 to 00118f36 has its CatchHandler @ 00118fbf */ local_2738 = std::random_device::_M_getval(); local_2734 = std::random_device::_M_getval(); local_2730 = std::random_device::_M_getval(); local_272c = std::random_device::_M_getval(); std::seed_seq::seed_seq<unsigned_int,void>(local_2750,&local_2738,4); /* try { // try from 00118f37 to 00118f45 has its CatchHandler @ 00118fba */ std:: mersenne_twister_engine<unsigned_long,32ul,624ul,397ul,31ul,2567483615ul,11ul,4294967295ul,7ul,2636928640ul,15ul,4022730752ul,18ul,1812433253ul> ::seed<std::seed_seq> ((mersenne_twister_engine<unsigned_long,32ul,624ul,397ul,31ul,2567483615ul,11ul,4294967295ul,7ul,2636928640ul,15ul,4022730752ul,18ul,1812433253ul> *)&local_2738,local_2750); /* try { // try from 00118f46 to 00118f59 has its CatchHandler @ 00118fb8 */ std::__cxx11::string::string((string *)this,"--cpp-httplib-multipart-data-",&local_2751); iVar1 = 0x10; while (bVar2 = iVar1 != 0, iVar1 = iVar1 + -1, bVar2) { /* try { // try from 00118f72 to 00118f8b has its CatchHandler @ 00118fc4 */ std:: mersenne_twister_engine<unsigned_long,32ul,624ul,397ul,31ul,2567483615ul,11ul,4294967295ul,7ul,2636928640ul,15ul,4022730752ul,18ul,1812433253ul> ::operator()((mersenne_twister_engine<unsigned_long,32ul,624ul,397ul,31ul,2567483615ul,11ul,4294967295ul,7ul,2636928640ul,15ul,4022730752ul,18ul,1812433253ul> *)&local_2738); std::__cxx11::string::push_back((char)this); } std::_Vector_base<unsigned_int,std::allocator<unsigned_int>>::~_Vector_base ((_Vector_base<unsigned_int,std::allocator<unsigned_int>> *)local_2750); std::random_device::~random_device(local_13b0); return this; }
60,853
Item_func_as_wkt::fix_length_and_dec()
eloqsql/sql/item_geofunc.cc
bool Item_func_as_wkt::fix_length_and_dec() { collation.set(default_charset(), DERIVATION_COERCIBLE, MY_REPERTOIRE_ASCII); max_length= (uint32) UINT_MAX32; set_maybe_null(); return FALSE; }
O3
cpp
Item_func_as_wkt::fix_length_and_dec(): pushq %rbp movq %rsp, %rbp pushq %rbx pushq %rax movq %rdi, %rbx callq 0x9a0ab0 movq %rax, 0x10(%rbx) movabsq $0x100000004, %rax # imm = 0x100000004 movq %rax, 0x18(%rbx) movl $0xffffffff, 0x8(%rbx) # imm = 0xFFFFFFFF orb $0x1, 0x60(%rbx) xorl %eax, %eax addq $0x8, %rsp popq %rbx popq %rbp retq
_ZN16Item_func_as_wkt18fix_length_and_decEv: push rbp mov rbp, rsp push rbx push rax mov rbx, rdi call _ZN4Item15default_charsetEv; Item::default_charset(void) mov [rbx+10h], rax mov rax, 100000004h mov [rbx+18h], rax mov dword ptr [rbx+8], 0FFFFFFFFh or byte ptr [rbx+60h], 1 xor eax, eax add rsp, 8 pop rbx pop rbp retn
long long Item_func_as_wkt::fix_length_and_dec(Item_func_as_wkt *this) { *((_QWORD *)this + 2) = Item::default_charset(this); *((_QWORD *)this + 3) = 0x100000004LL; *((_DWORD *)this + 2) = -1; *((_BYTE *)this + 96) |= 1u; return 0LL; }
~Field_dependency_recorder: PUSH RBP MOV RBP,RSP MOV ESI,0x18 POP RBP JMP 0x00728290
/* Field_dependency_recorder::~Field_dependency_recorder() */ void __thiscall Field_dependency_recorder::~Field_dependency_recorder(Field_dependency_recorder *this) { operator_delete(this,0x18); return; }
60,854
ggml_threadpool_params_from_cpu_params(cpu_params const&)
monkey531[P]llama/common/common.cpp
struct ggml_threadpool_params ggml_threadpool_params_from_cpu_params(const cpu_params & params) { struct ggml_threadpool_params tpp; ggml_threadpool_params_init(&tpp, params.n_threads); // setup the defaults if (params.mask_valid) { std::memcpy(&tpp.cpumask, &params.cpumask, GGML_MAX_N_THREADS); } tpp.prio = params.priority; tpp.poll = params.poll; tpp.strict_cpu = params.strict_cpu; return tpp; }
O3
cpp
ggml_threadpool_params_from_cpu_params(cpu_params const&): pushq %r14 pushq %rbx pushq %rax movq %rsi, %r14 movq %rdi, %rbx movl (%rsi), %esi callq 0x1b7b0 cmpb $0x1, 0x204(%r14) jne 0x753af leaq 0x4(%r14), %rsi movl $0x200, %edx # imm = 0x200 movq %rbx, %rdi callq 0x1b710 movl 0x208(%r14), %eax movl %eax, 0x204(%rbx) movl 0x210(%r14), %eax movl %eax, 0x208(%rbx) movb 0x20c(%r14), %al movb %al, 0x20c(%rbx) movq %rbx, %rax addq $0x8, %rsp popq %rbx popq %r14 retq
_Z38ggml_threadpool_params_from_cpu_paramsRK10cpu_params: push r14 push rbx push rax mov r14, rsi mov rbx, rdi mov esi, [rsi] call _ggml_threadpool_params_init cmp byte ptr [r14+204h], 1 jnz short loc_753AF lea rsi, [r14+4] mov edx, 200h mov rdi, rbx call _memcpy loc_753AF: mov eax, [r14+208h] mov [rbx+204h], eax mov eax, [r14+210h] mov [rbx+208h], eax mov al, [r14+20Ch] mov [rbx+20Ch], al mov rax, rbx add rsp, 8 pop rbx pop r14 retn
long long ggml_threadpool_params_from_cpu_params(long long a1, unsigned int *a2) { ggml_threadpool_params_init(a1, *a2); if ( *((_BYTE *)a2 + 516) == 1 ) memcpy(a1, a2 + 1, 512LL); *(_DWORD *)(a1 + 516) = a2[130]; *(_DWORD *)(a1 + 520) = a2[132]; *(_BYTE *)(a1 + 524) = *((_BYTE *)a2 + 524); return a1; }
ggml_threadpool_params_from_cpu_params: PUSH R14 PUSH RBX PUSH RAX MOV R14,RSI MOV RBX,RDI MOV ESI,dword ptr [RSI] CALL 0x0011b7b0 CMP byte ptr [R14 + 0x204],0x1 JNZ 0x001753af LEA RSI,[R14 + 0x4] MOV EDX,0x200 MOV RDI,RBX CALL 0x0011b710 LAB_001753af: MOV EAX,dword ptr [R14 + 0x208] MOV dword ptr [RBX + 0x204],EAX MOV EAX,dword ptr [R14 + 0x210] MOV dword ptr [RBX + 0x208],EAX MOV AL,byte ptr [R14 + 0x20c] MOV byte ptr [RBX + 0x20c],AL MOV RAX,RBX ADD RSP,0x8 POP RBX POP R14 RET
/* ggml_threadpool_params_from_cpu_params(cpu_params const&) */ cpu_params * ggml_threadpool_params_from_cpu_params(cpu_params *param_1) { int4 *in_RSI; ggml_threadpool_params_init(param_1,*in_RSI); if (*(char *)(in_RSI + 0x81) == '\x01') { memcpy(param_1,in_RSI + 1,0x200); } *(int4 *)(param_1 + 0x204) = in_RSI[0x82]; *(int4 *)(param_1 + 0x208) = in_RSI[0x84]; param_1[0x20c] = *(cpu_params *)(in_RSI + 0x83); return param_1; }
60,855
create_temp_file
eloqsql/mysys/mf_tempfile.c
File create_temp_file(char *to, const char *dir, const char *prefix, int mode, myf MyFlags) { File file= -1; DBUG_ENTER("create_temp_file"); DBUG_PRINT("enter", ("dir: %s, prefix: %s", dir ? dir : "(null)", prefix)); DBUG_ASSERT((mode & (O_EXCL | O_TRUNC | O_CREAT | O_RDWR)) == 0); mode|= O_TRUNC | O_CREAT | O_RDWR; /* not O_EXCL, see Windows code below */ #ifdef _WIN32 { TCHAR path_buf[MAX_PATH-14]; /* Use GetTempPath to determine path for temporary files. This is because the documentation for GetTempFileName has the following to say about this parameter: "If this parameter is NULL, the function fails." */ if (!dir) { if(GetTempPath(sizeof(path_buf), path_buf) > 0) dir = path_buf; } /* Use GetTempFileName to generate a unique filename, create the file and release it's handle - uses up to the first three letters from prefix */ if (GetTempFileName(dir, prefix, 0, to) == 0) DBUG_RETURN(-1); DBUG_PRINT("info", ("name: %s", to)); if (MyFlags & MY_TEMPORARY) mode|= O_SHORT_LIVED | O_TEMPORARY; /* Open the file without O_EXCL flag since the file has already been created by GetTempFileName */ if ((file= my_open(to, mode, MyFlags)) < 0) { /* Open failed, remove the file created by GetTempFileName */ int tmp= my_errno; (void) my_delete(to, MYF(0)); my_errno= tmp; } } #elif defined(HAVE_MKSTEMP) if (!dir && ! (dir =getenv("TMPDIR"))) dir= DEFAULT_TMPDIR; #ifdef O_TMPFILE { static int O_TMPFILE_works= 1; if ((MyFlags & MY_TEMPORARY) && O_TMPFILE_works) { /* explictly don't use O_EXCL here has it has a different meaning with O_TMPFILE */ if ((file= open(dir, (mode & ~O_CREAT) | O_TMPFILE | O_CLOEXEC, S_IRUSR | S_IWUSR | S_IRGRP | S_IWGRP)) >= 0) { my_snprintf(to, FN_REFLEN, "%s/#sql/fd=%d", dir, file); file=my_register_filename(file, to, FILE_BY_O_TMPFILE, EE_CANTCREATEFILE, MyFlags); } else if (errno == EOPNOTSUPP || errno == EINVAL) { my_printf_error(EE_CANTCREATEFILE, "O_TMPFILE is not supported on %s " "(disabling future attempts)", MYF(ME_NOTE | ME_ERROR_LOG_ONLY), dir); O_TMPFILE_works= 0; } } } if (file == -1) #endif /* O_TMPFILE */ { char prefix_buff[30]; uint pfx_len; File org_file; pfx_len= (uint) (strmov(strnmov(prefix_buff, prefix ? prefix : "tmp.", sizeof(prefix_buff)-7),"XXXXXX") - prefix_buff); if (strlen(dir)+ pfx_len > FN_REFLEN-2) { errno=my_errno= ENAMETOOLONG; DBUG_RETURN(file); } strmov(convert_dirname(to,dir,NullS),prefix_buff); org_file=mkstemp(to); if (org_file >= 0 && (MyFlags & MY_TEMPORARY)) (void) my_delete(to, MYF(MY_WME)); file=my_register_filename(org_file, to, FILE_BY_MKSTEMP, EE_CANTCREATEFILE, MyFlags); /* If we didn't manage to register the name, remove the temp file */ if (org_file >= 0 && file < 0) { int tmp=my_errno; close(org_file); (void) my_delete(to, MYF(MY_WME)); my_errno=tmp; } } #else #error No implementation found for create_temp_file #endif if (file >= 0) statistic_increment(my_tmp_file_created,&THR_LOCK_open); DBUG_RETURN(file); }
O3
c
create_temp_file: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x28, %rsp movq %r8, %r14 movl %ecx, %r13d movq %rdx, %r12 movq %rsi, %r15 movq %rdi, %rbx movq %fs:0x28, %rax movq %rax, -0x30(%rbp) testq %rsi, %rsi jne 0xa8d44 leaq 0x3432e(%rip), %rdi # 0xdd05f callq 0x29610 testq %rax, %rax leaq 0x34326(%rip), %r15 # 0xdd066 cmovneq %rax, %r15 testb $0x40, %r14b je 0xa8df8 testb $0x1, 0xb5fc33(%rip) # 0xc08988 jne 0xa8df8 andl $0xffb6fdbd, %r13d # imm = 0xFFB6FDBD orl $0x490202, %r13d # imm = 0x490202 movq %r15, %rdi movl %r13d, %esi movl $0x1b0, %edx # imm = 0x1B0 xorl %eax, %eax callq 0x299a0 movl %eax, %r13d testl %eax, %eax js 0xa8dbb leaq 0x342e2(%rip), %rdx # 0xdd06b movl $0x200, %esi # imm = 0x200 movq %rbx, %rdi movq %r15, %rcx movl %r13d, %r8d xorl %eax, %eax callq 0xd6d3a movl %r13d, %edi movq %rbx, %rsi movl $0x5, %edx movl $0x1, %ecx movq %r14, %r8 callq 0xa0446 movl %eax, %r13d jmp 0xa8dee callq 0x29790 movl (%rax), %eax cmpl $0x5f, %eax je 0xa8dcc cmpl $0x16, %eax jne 0xa8dee leaq 0x342a6(%rip), %rsi # 0xdd079 movl $0x480, %edx # imm = 0x480 movl $0x1, %edi movq %r15, %rcx xorl %eax, %eax callq 0x9e0ed movb $0x1, 0xb5fb9a(%rip) # 0xc08988 cmpl $-0x1, %r13d jne 0xa8ee1 testq %r12, %r12 leaq 0x342b4(%rip), %rsi # 0xdd0b6 cmovneq %r12, %rsi leaq -0x50(%rbp), %r12 movl $0x17, %edx movq %r12, %rdi callq 0xd713c movq %rax, %r13 movl $0x58585858, (%rax) # imm = 0x58585858 movl $0x585858, 0x3(%rax) # imm = 0x585858 subl %r12d, %r13d addl $0x6, %r13d movq %r15, %rdi callq 0x29340 addq %rax, %r13 cmpq $0x1fe, %r13 # imm = 0x1FE ja 0xa8ef2 testb $0x40, %r14b sete %r12b movq %rbx, %rdi movq %r15, %rsi xorl %edx, %edx callq 0x94777 leaq -0x50(%rbp), %rsi movq %rax, %rdi callq 0x29350 movq %rbx, %rdi movl $0x80000, %esi # imm = 0x80000 callq 0x29550 movl %eax, %r15d testl %eax, %eax sets %al orb %r12b, %al jne 0xa8e8e movl $0x10, %esi movq %rbx, %rdi callq 0x9dd5c testl %r15d, %r15d setns %r12b movl %r15d, %edi movq %rbx, %rsi movl $0x6, %edx movl $0x1, %ecx movq %r14, %r8 callq 0xa0446 movl %eax, %r13d testl %eax, %eax sets %al andb %r12b, %al cmpb $0x1, %al jne 0xa8ee1 callq 0xa1ac2 movl (%rax), %r14d movl %r15d, %edi callq 0x29190 movl $0x10, %esi movq %rbx, %rdi callq 0x9dd5c callq 0xa1ac2 movl %r14d, (%rax) testl %r13d, %r13d js 0xa8f0b leaq 0xb5ee0b(%rip), %rax # 0xc07cf8 incq (%rax) jmp 0xa8f0b callq 0xa1ac2 movl $0x24, %ebx movl %ebx, (%rax) callq 0x29790 movl %ebx, (%rax) movl $0xffffffff, %r13d # imm = 0xFFFFFFFF movq %fs:0x28, %rax cmpq -0x30(%rbp), %rax jne 0xa8f2c movl %r13d, %eax addq $0x28, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq callq 0x29250 nopl (%rax)
create_temp_file: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx sub rsp, 28h mov r14, r8 mov r13d, ecx mov r12, rdx mov r15, rsi mov rbx, rdi mov rax, fs:28h mov [rbp+var_30], rax test rsi, rsi jnz short loc_A8D44 lea rdi, aTmpdir; "TMPDIR" call _getenv test rax, rax lea r15, aTmp_0; "/tmp" cmovnz r15, rax loc_A8D44: test r14b, 40h jz loc_A8DF8 test cs:create_temp_file_O_TMPFILE_works, 1 jnz loc_A8DF8 and r13d, 0FFB6FDBDh or r13d, 490202h mov rdi, r15 mov esi, r13d mov edx, 1B0h xor eax, eax call _open64 mov r13d, eax test eax, eax js short loc_A8DBB lea rdx, aSSqlFdD; "%s/#sql/fd=%d" mov esi, 200h mov rdi, rbx mov rcx, r15 mov r8d, r13d xor eax, eax call my_snprintf mov edi, r13d mov rsi, rbx mov edx, 5 mov ecx, 1 mov r8, r14 call my_register_filename mov r13d, eax jmp short loc_A8DEE loc_A8DBB: call ___errno_location mov eax, [rax] cmp eax, 5Fh ; '_' jz short loc_A8DCC cmp eax, 16h jnz short loc_A8DEE loc_A8DCC: lea rsi, aOTmpfileIsNotS; "O_TMPFILE is not supported on %s (disab"... mov edx, 480h mov edi, 1 mov rcx, r15 xor eax, eax call my_printf_error mov cs:create_temp_file_O_TMPFILE_works, 1 loc_A8DEE: cmp r13d, 0FFFFFFFFh jnz loc_A8EE1 loc_A8DF8: test r12, r12 lea rsi, aTmp_1; "tmp." cmovnz rsi, r12 lea r12, [rbp+var_50] mov edx, 17h mov rdi, r12 call strnmov mov r13, rax mov dword ptr [rax], 58585858h mov dword ptr [rax+3], offset unk_585858 sub r13d, r12d add r13d, 6 mov rdi, r15 call _strlen add r13, rax cmp r13, 1FEh ja loc_A8EF2 test r14b, 40h setz r12b mov rdi, rbx mov rsi, r15 xor edx, edx call convert_dirname lea rsi, [rbp+var_50] mov rdi, rax call _strcpy mov rdi, rbx mov esi, 80000h call _mkostemp64 mov r15d, eax test eax, eax sets al or al, r12b jnz short loc_A8E8E mov esi, 10h mov rdi, rbx call my_delete loc_A8E8E: test r15d, r15d setns r12b mov edi, r15d mov rsi, rbx mov edx, 6 mov ecx, 1 mov r8, r14 call my_register_filename mov r13d, eax test eax, eax sets al and al, r12b cmp al, 1 jnz short loc_A8EE1 call _my_thread_var mov r14d, [rax] mov edi, r15d call _close mov esi, 10h mov rdi, rbx call my_delete call _my_thread_var mov [rax], r14d loc_A8EE1: test r13d, r13d js short loc_A8F0B lea rax, my_tmp_file_created inc qword ptr [rax] jmp short loc_A8F0B loc_A8EF2: call _my_thread_var mov ebx, 24h ; '$' mov [rax], ebx call ___errno_location mov [rax], ebx mov r13d, 0FFFFFFFFh loc_A8F0B: mov rax, fs:28h cmp rax, [rbp+var_30] jnz short loc_A8F2C mov eax, r13d add rsp, 28h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn loc_A8F2C: call ___stack_chk_fail
long long create_temp_file( _WORD *a1, const char *a2, const char *a3, int a4, __int16 a5, __m128 a6, __m128 a7, __m128 a8, __m128 a9, double a10, double a11, __m128 a12, __m128 a13) { const char *v16; // r15 long long v17; // rax int v18; // eax int v19; // r9d int v20; // r13d int v21; // eax long long v22; // r8 long long v23; // r9 __m128 v24; // xmm4 __m128 v25; // xmm5 const char *v26; // rsi _DWORD *v27; // rax _WORD *v28; // rax int v29; // r15d int v30; // r14d char v32[32]; // [rsp+0h] [rbp-50h] BYREF unsigned long long v33; // [rsp+20h] [rbp-30h] v16 = a2; v33 = __readfsqword(0x28u); if ( !a2 ) { v17 = getenv("TMPDIR"); v16 = "/tmp"; if ( v17 ) v16 = (const char *)v17; } if ( (a5 & 0x40) == 0 || (create_temp_file_O_TMPFILE_works & 1) != 0 ) goto LABEL_12; v18 = open64(v16, a4 & 0xFFB6FDBD | 0x490202, 432LL); v20 = v18; if ( v18 < 0 ) { v21 = *(_DWORD *)__errno_location(v16); if ( v21 == 95 || v21 == 22 ) { my_printf_error( 1, (long long)"O_TMPFILE is not supported on %s (disabling future attempts)", 1152, (long long)v16, v22, v23, a6, a7, a8, a9, v24, v25, a12, a13, v32[0]); create_temp_file_O_TMPFILE_works = 1; } } else { my_snprintf((_DWORD)a1, 512, (unsigned int)"%s/#sql/fd=%d", (_DWORD)v16, v18, v19); v20 = my_register_filename((unsigned int)v20, (long long)a1, 5, 1u, a5); } if ( v20 == -1 ) { LABEL_12: v26 = "tmp."; if ( a3 ) v26 = a3; v27 = (_DWORD *)strnmov(v32, v26, 23LL); *v27 = 1482184792; *(_DWORD *)((char *)v27 + 3) = (_DWORD)&unk_585858; if ( strlen(v16) + (unsigned long long)((unsigned int)v27 - (unsigned int)v32 + 6) > 0x1FE ) { *(_DWORD *)my_thread_var() = 36; *(_DWORD *)__errno_location(v16) = 36; return (unsigned int)-1; } v28 = convert_dirname(a1, (long long)v16, 0LL); strcpy(v28, v32); v29 = mkostemp64(a1, 0x80000LL); if ( (a5 & 0x40) != 0 && v29 >= 0 ) my_delete((long long)a1, 16LL); v20 = my_register_filename((unsigned int)v29, (long long)a1, 6, 1u, a5); if ( v29 >= 0 && v20 < 0 ) { v30 = *(_DWORD *)my_thread_var(); close((unsigned int)v29); my_delete((long long)a1, 16LL); *(_DWORD *)my_thread_var() = v30; } } if ( v20 >= 0 ) ++my_tmp_file_created; return (unsigned int)v20; }
create_temp_file: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x28 MOV R14,R8 MOV R13D,ECX MOV R12,RDX MOV R15,RSI MOV RBX,RDI MOV RAX,qword ptr FS:[0x28] MOV qword ptr [RBP + -0x30],RAX TEST RSI,RSI JNZ 0x001a8d44 LEA RDI,[0x1dd05f] CALL 0x00129610 TEST RAX,RAX LEA R15,[0x1dd066] CMOVNZ R15,RAX LAB_001a8d44: TEST R14B,0x40 JZ 0x001a8df8 TEST byte ptr [0x00d08988],0x1 JNZ 0x001a8df8 AND R13D,0xffb6fdbd OR R13D,0x490202 MOV RDI,R15 MOV ESI,R13D MOV EDX,0x1b0 XOR EAX,EAX CALL 0x001299a0 MOV R13D,EAX TEST EAX,EAX JS 0x001a8dbb LEA RDX,[0x1dd06b] MOV ESI,0x200 MOV RDI,RBX MOV RCX,R15 MOV R8D,R13D XOR EAX,EAX CALL 0x001d6d3a MOV EDI,R13D MOV RSI,RBX MOV EDX,0x5 MOV ECX,0x1 MOV R8,R14 CALL 0x001a0446 MOV R13D,EAX JMP 0x001a8dee LAB_001a8dbb: CALL 0x00129790 MOV EAX,dword ptr [RAX] CMP EAX,0x5f JZ 0x001a8dcc CMP EAX,0x16 JNZ 0x001a8dee LAB_001a8dcc: LEA RSI,[0x1dd079] MOV EDX,0x480 MOV EDI,0x1 MOV RCX,R15 XOR EAX,EAX CALL 0x0019e0ed MOV byte ptr [0x00d08988],0x1 LAB_001a8dee: CMP R13D,-0x1 JNZ 0x001a8ee1 LAB_001a8df8: TEST R12,R12 LEA RSI,[0x1dd0b6] CMOVNZ RSI,R12 LEA R12,[RBP + -0x50] MOV EDX,0x17 MOV RDI,R12 CALL 0x001d713c MOV R13,RAX MOV dword ptr [RAX],0x58585858 MOV dword ptr [RAX + 0x3],0x585858 SUB R13D,R12D ADD R13D,0x6 MOV RDI,R15 CALL 0x00129340 ADD R13,RAX CMP R13,0x1fe JA 0x001a8ef2 TEST R14B,0x40 SETZ R12B MOV RDI,RBX MOV RSI,R15 XOR EDX,EDX CALL 0x00194777 LEA RSI,[RBP + -0x50] MOV RDI,RAX CALL 0x00129350 MOV RDI,RBX MOV ESI,0x80000 CALL 0x00129550 MOV R15D,EAX TEST EAX,EAX SETS AL OR AL,R12B JNZ 0x001a8e8e MOV ESI,0x10 MOV RDI,RBX CALL 0x0019dd5c LAB_001a8e8e: TEST R15D,R15D SETNS R12B MOV EDI,R15D MOV RSI,RBX MOV EDX,0x6 MOV ECX,0x1 MOV R8,R14 CALL 0x001a0446 MOV R13D,EAX TEST EAX,EAX SETS AL AND AL,R12B CMP AL,0x1 JNZ 0x001a8ee1 CALL 0x001a1ac2 MOV R14D,dword ptr [RAX] MOV EDI,R15D CALL 0x00129190 MOV ESI,0x10 MOV RDI,RBX CALL 0x0019dd5c CALL 0x001a1ac2 MOV dword ptr [RAX],R14D LAB_001a8ee1: TEST R13D,R13D JS 0x001a8f0b LEA RAX,[0xd07cf8] INC qword ptr [RAX] JMP 0x001a8f0b LAB_001a8ef2: CALL 0x001a1ac2 MOV EBX,0x24 MOV dword ptr [RAX],EBX CALL 0x00129790 MOV dword ptr [RAX],EBX MOV R13D,0xffffffff LAB_001a8f0b: MOV RAX,qword ptr FS:[0x28] CMP RAX,qword ptr [RBP + -0x30] JNZ 0x001a8f2c MOV EAX,R13D ADD RSP,0x28 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET LAB_001a8f2c: CALL 0x00129250
int create_temp_file(char *param_1,char *param_2,int *param_3,uint param_4,ulong param_5) { int4 uVar1; int iVar2; int __fd; char *pcVar3; int4 *puVar4; size_t sVar5; int *piVar6; int *puVar7; long in_FS_OFFSET; char local_58 [32]; long local_38; local_38 = *(long *)(in_FS_OFFSET + 0x28); if (param_2 == (char *)0x0) { pcVar3 = getenv("TMPDIR"); param_2 = "/tmp"; if (pcVar3 != (char *)0x0) { param_2 = pcVar3; } } if (((param_5 & 0x40) == 0) || ((create_temp_file_O_TMPFILE_works & 1) != 0)) { LAB_001a8df8: puVar7 = &DAT_001dd0b6; if (param_3 != (int *)0x0) { puVar7 = param_3; } puVar4 = (int4 *)strnmov(local_58,puVar7,0x17); *puVar4 = 0x58585858; *(int4 *)((long)puVar4 + 3) = 0x585858; sVar5 = strlen(param_2); if (0x1fe < (((int)puVar4 - (int)local_58) + 6) + sVar5) { puVar4 = (int4 *)_my_thread_var(); *puVar4 = 0x24; piVar6 = __errno_location(); *piVar6 = 0x24; iVar2 = -1; goto LAB_001a8f0b; } pcVar3 = (char *)convert_dirname(param_1,param_2,0); strcpy(pcVar3,local_58); __fd = mkostemp64(param_1,0x80000); if (-1 < __fd && (param_5 & 0x40) != 0) { my_delete(param_1,0x10); } iVar2 = my_register_filename(__fd,param_1,6,1,param_5); if (iVar2 < 0 && -1 < __fd) { puVar4 = (int4 *)_my_thread_var(); uVar1 = *puVar4; close(__fd); my_delete(param_1,0x10); puVar4 = (int4 *)_my_thread_var(); *puVar4 = uVar1; } } else { iVar2 = open64(param_2,param_4 & 0xffb6fdbd | 0x490202,0x1b0); if (iVar2 < 0) { piVar6 = __errno_location(); if ((*piVar6 == 0x5f) || (*piVar6 == 0x16)) { my_printf_error(1,"O_TMPFILE is not supported on %s (disabling future attempts)",0x480, param_2); create_temp_file_O_TMPFILE_works = 1; } } else { my_snprintf(param_1,0x200,"%s/#sql/fd=%d",param_2,iVar2); iVar2 = my_register_filename(iVar2,param_1,5,1,param_5); } if (iVar2 == -1) goto LAB_001a8df8; } if (-1 < iVar2) { my_tmp_file_created = my_tmp_file_created + 1; } LAB_001a8f0b: if (*(long *)(in_FS_OFFSET + 0x28) == local_38) { return iVar2; } /* WARNING: Subroutine does not return */ __stack_chk_fail(); }
60,856
nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>, nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>>>::~lexer()
monkey531[P]llama/common/json.hpp
~lexer() = default;
O3
cpp
nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>, nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>>>::~lexer(): pushq %rbx movq %rdi, %rbx movq 0x50(%rdi), %rdi leaq 0x60(%rbx), %rax cmpq %rax, %rdi je 0x8928a movq (%rax), %rsi incq %rsi callq 0x1dc50 movq 0x38(%rbx), %rdi testq %rdi, %rdi je 0x892a0 movq 0x48(%rbx), %rsi subq %rdi, %rsi popq %rbx jmp 0x1dc50 popq %rbx retq
_ZN8nlohmann16json_abi_v3_11_36detail5lexerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEENS1_22iterator_input_adapterIN9__gnu_cxx17__normal_iteratorIPKcSB_EEEEED2Ev: push rbx mov rbx, rdi mov rdi, [rdi+50h]; void * lea rax, [rbx+60h] cmp rdi, rax jz short loc_8928A mov rsi, [rax] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_8928A: mov rdi, [rbx+38h]; void * test rdi, rdi jz short loc_892A0 mov rsi, [rbx+48h] sub rsi, rdi; unsigned __int64 pop rbx jmp __ZdlPvm; operator delete(void *,ulong) loc_892A0: pop rbx retn
void nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::~lexer( _QWORD *a1) { _QWORD *v2; // rdi void *v3; // rdi v2 = (_QWORD *)a1[10]; if ( v2 != a1 + 12 ) operator delete(v2, a1[12] + 1LL); v3 = (void *)a1[7]; if ( v3 ) operator delete(v3, a1[9] - (_QWORD)v3); }
~lexer: PUSH RBX MOV RBX,RDI MOV RDI,qword ptr [RDI + 0x50] LEA RAX,[RBX + 0x60] CMP RDI,RAX JZ 0x0018928a MOV RSI,qword ptr [RAX] INC RSI CALL 0x0011dc50 LAB_0018928a: MOV RDI,qword ptr [RBX + 0x38] TEST RDI,RDI JZ 0x001892a0 MOV RSI,qword ptr [RBX + 0x48] SUB RSI,RDI POP RBX JMP 0x0011dc50 LAB_001892a0: POP RBX RET
/* nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char> >, void>, nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*, std::__cxx11::string > > >::~lexer() */ void __thiscall nlohmann::json_abi_v3_11_3::detail:: lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>>> ::~lexer(lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>>> *this) { void *pvVar1; if (*(lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>>> **)(this + 0x50) != this + 0x60) { operator_delete(*(lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>>> **)(this + 0x50),*(long *)(this + 0x60) + 1); } pvVar1 = *(void **)(this + 0x38); if (pvVar1 != (void *)0x0) { operator_delete(pvVar1,*(long *)(this + 0x48) - (long)pvVar1); return; } return; }
60,857
ggml_vec_dot_iq4_xs_q8_K
ngxson[P]ggml-easy/ggml/src/ggml-cpu/ggml-cpu-quants.c
void ggml_vec_dot_iq4_xs_q8_K(int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, size_t bx, const void * GGML_RESTRICT vy, size_t by, int nrc) { assert(nrc == 1); UNUSED(nrc); UNUSED(bx); UNUSED(by); UNUSED(bs); assert(n % QK_K == 0); const block_iq4_xs * GGML_RESTRICT x = vx; const block_q8_K * GGML_RESTRICT y = vy; const int nb = n / QK_K; #if defined __ARM_NEON const int8x16_t values = vld1q_s8(kvalues_iq4nl); const uint8x16_t m4b = vdupq_n_u8(0x0f); ggml_uint8x16x2_t q4bits; ggml_int8x16x4_t q4b; ggml_int8x16x4_t q8b; int32x4_t prod_1, prod_2; float sumf = 0; for (int ibl = 0; ibl < nb; ++ibl) { const int8_t * q8 = y[ibl].qs; const uint8_t * q4 = x[ibl].qs; uint16_t h = x[ibl].scales_h; int sumi1 = 0, sumi2 = 0; for (int ib = 0; ib < QK_K/64; ++ib) { q4bits = ggml_vld1q_u8_x2(q4); q4 += 32; q8b = ggml_vld1q_s8_x4(q8); q8 += 64; q4b.val[0] = ggml_vqtbl1q_s8(values, vandq_u8 (q4bits.val[0], m4b)); q4b.val[1] = ggml_vqtbl1q_s8(values, vshrq_n_u8(q4bits.val[0], 4)); q4b.val[2] = ggml_vqtbl1q_s8(values, vandq_u8 (q4bits.val[1], m4b)); q4b.val[3] = ggml_vqtbl1q_s8(values, vshrq_n_u8(q4bits.val[1], 4)); prod_1 = ggml_vdotq_s32(ggml_vdotq_s32(vdupq_n_s32(0), q4b.val[0], q8b.val[0]), q4b.val[1], q8b.val[1]); prod_2 = ggml_vdotq_s32(ggml_vdotq_s32(vdupq_n_s32(0), q4b.val[2], q8b.val[2]), q4b.val[3], q8b.val[3]); int ls1 = ((x[ibl].scales_l[ib] & 0xf) | ((h << 4) & 0x30)) - 32; int ls2 = ((x[ibl].scales_l[ib] >> 4) | ((h << 2) & 0x30)) - 32; h >>= 4; sumi1 += vaddvq_s32(prod_1) * ls1; sumi2 += vaddvq_s32(prod_2) * ls2; } sumf += GGML_FP16_TO_FP32(x[ibl].d) * y[ibl].d * (sumi1 + sumi2); } *s = sumf; #elif defined __AVX2__ const __m128i values128 = _mm_loadu_si128((const __m128i*)kvalues_iq4nl); const __m128i m4b = _mm_set1_epi8(0x0f); __m256 accum = _mm256_setzero_ps(); for (int ibl = 0; ibl < nb; ++ibl) { const uint8_t * qs = x[ibl].qs; const int8_t * q8 = y[ibl].qs; uint16_t sh = x[ibl].scales_h; __m256i sumi1 = _mm256_setzero_si256(); __m256i sumi2 = _mm256_setzero_si256(); for (int ib = 0; ib < QK_K/32; ib += 2) { const __m128i q4bits_1 = _mm_loadu_si128((const __m128i*)qs); qs += 16; const __m128i q4bits_2 = _mm_loadu_si128((const __m128i*)qs); qs += 16; const __m256i q8b_1 = _mm256_loadu_si256((const __m256i *)q8); q8 += 32; const __m256i q8b_2 = _mm256_loadu_si256((const __m256i *)q8); q8 += 32; const __m256i q4b_1 = MM256_SET_M128I(_mm_shuffle_epi8(values128, _mm_and_si128(_mm_srli_epi16(q4bits_1, 4), m4b)), _mm_shuffle_epi8(values128, _mm_and_si128(q4bits_1, m4b))); const __m256i q4b_2 = MM256_SET_M128I(_mm_shuffle_epi8(values128, _mm_and_si128(_mm_srli_epi16(q4bits_2, 4), m4b)), _mm_shuffle_epi8(values128, _mm_and_si128(q4bits_2, m4b))); const __m256i p16_1 = mul_add_epi8(q4b_1, q8b_1); const __m256i p16_2 = mul_add_epi8(q4b_2, q8b_2); const int16_t ls1 = ((x[ibl].scales_l[ib/2] & 0xf) | ((sh << 4) & 0x30)) - 32; const int16_t ls2 = ((x[ibl].scales_l[ib/2] >> 4) | ((sh << 2) & 0x30)) - 32; sh >>= 4; const __m256i p_1 = _mm256_madd_epi16(p16_1, _mm256_set1_epi16(ls1)); const __m256i p_2 = _mm256_madd_epi16(p16_2, _mm256_set1_epi16(ls2)); sumi1 = _mm256_add_epi32(p_1, sumi1); sumi2 = _mm256_add_epi32(p_2, sumi2); } accum = _mm256_fmadd_ps(_mm256_set1_ps(GGML_FP16_TO_FP32(x[ibl].d)*y[ibl].d), _mm256_cvtepi32_ps(_mm256_add_epi32(sumi1, sumi2)), accum); } *s = hsum_float_8(accum); #elif defined __AVX__ const __m128i values128 = _mm_loadu_si128((const __m128i*)kvalues_iq4nl); const __m128i m4b = _mm_set1_epi8(0x0f); __m256 accum = _mm256_setzero_ps(); for (int ibl = 0; ibl < nb; ++ibl) { const uint8_t * qs = x[ibl].qs; const int8_t * q8 = y[ibl].qs; uint16_t sh = x[ibl].scales_h; __m128i sumi1_0 = _mm_setzero_si128(); __m128i sumi1_1 = _mm_setzero_si128(); __m128i sumi2_0 = _mm_setzero_si128(); __m128i sumi2_1 = _mm_setzero_si128(); for (int ib = 0; ib < QK_K/32; ib += 2) { const __m128i q4bits_1 = _mm_loadu_si128((const __m128i *)qs); qs += 16; const __m128i q4bits_2 = _mm_loadu_si128((const __m128i *)qs); qs += 16; const __m128i q8b_1_0 = _mm_loadu_si128((const __m128i *)q8); q8 += 16; const __m128i q8b_1_1 = _mm_loadu_si128((const __m128i *)q8); q8 += 16; const __m128i q8b_2_0 = _mm_loadu_si128((const __m128i *)q8); q8 += 16; const __m128i q8b_2_1 = _mm_loadu_si128((const __m128i *)q8); q8 += 16; const __m128i q4b_1_0 = _mm_shuffle_epi8(values128, _mm_and_si128(q4bits_1, m4b)); const __m128i q4b_1_1 = _mm_shuffle_epi8(values128, _mm_and_si128(_mm_srli_epi16(q4bits_1, 4), m4b)); const __m128i q4b_2_0 = _mm_shuffle_epi8(values128, _mm_and_si128(q4bits_2, m4b)); const __m128i q4b_2_1 = _mm_shuffle_epi8(values128, _mm_and_si128(_mm_srli_epi16(q4bits_2, 4), m4b)); const __m128i p16_1_0 = mul_add_epi8_sse(q4b_1_0, q8b_1_0); const __m128i p16_1_1 = mul_add_epi8_sse(q4b_1_1, q8b_1_1); const __m128i p16_2_0 = mul_add_epi8_sse(q4b_2_0, q8b_2_0); const __m128i p16_2_1 = mul_add_epi8_sse(q4b_2_1, q8b_2_1); const int16_t ls1 = ((x[ibl].scales_l[ib/2] & 0xf) | ((sh << 4) & 0x30)) - 32; const int16_t ls2 = ((x[ibl].scales_l[ib/2] >> 4) | ((sh << 2) & 0x30)) - 32; sh >>= 4; const __m128i p_1_0 = _mm_madd_epi16(p16_1_0, _mm_set1_epi16(ls1)); const __m128i p_1_1 = _mm_madd_epi16(p16_1_1, _mm_set1_epi16(ls1)); const __m128i p_2_0 = _mm_madd_epi16(p16_2_0, _mm_set1_epi16(ls2)); const __m128i p_2_1 = _mm_madd_epi16(p16_2_1, _mm_set1_epi16(ls2)); sumi1_0 = _mm_add_epi32(p_1_0, sumi1_0); sumi1_1 = _mm_add_epi32(p_1_1, sumi1_1); sumi2_0 = _mm_add_epi32(p_2_0, sumi2_0); sumi2_1 = _mm_add_epi32(p_2_1, sumi2_1); } __m128i sumi12_0 = _mm_add_epi32(sumi1_0, sumi2_0); __m128i sumi12_1 = _mm_add_epi32(sumi1_1, sumi2_1); accum = _mm256_add_ps(_mm256_mul_ps(_mm256_set1_ps(GGML_FP16_TO_FP32(x[ibl].d)*y[ibl].d), _mm256_cvtepi32_ps(MM256_SET_M128I(sumi12_1, sumi12_0))), accum); } *s = hsum_float_8(accum); #elif defined(__POWER9_VECTOR__) const vector signed char lowMask = vec_splats((signed char)0xF); const vector int v0 = vec_splats((int32_t)0); const vector unsigned char v4 = vec_splats((unsigned char)0x4); vector float vsumf0 = vec_splats(0.0f); vector float vsumf1 = vec_splats(0.0f); vector float vsumf2 = vec_splats(0.0f); vector float vsumf3 = vec_splats(0.0f); const vector signed char values = vec_xl( 0, kvalues_iq4nl); for (int ibl = 0; ibl < nb; ++ibl) { vector float vxd = vec_splats(GGML_FP16_TO_FP32(x[ibl].d)); vector float vyd = vec_splats(y[ibl].d); vector float vd = vec_mul(vxd, vyd); vector signed int vsumi0 = v0; vector signed int vsumi1 = v0; vector signed int vsumi2 = v0; vector signed int vsumi3 = v0; uint16_t h = x[ibl].scales_h; const uint8_t * GGML_RESTRICT q4 = x[ibl].qs; const uint8_t * GGML_RESTRICT sc = x[ibl].scales_l; const int8_t * GGML_RESTRICT q8 = y[ibl].qs; for (int ib = 0; ib < QK_K/64; ib ++ ) { __builtin_prefetch(q4, 0, 1); __builtin_prefetch(q8, 0, 1); vector signed char qxs0 = (vector signed char)vec_xl( 0, q4); vector signed char qxs1 = (vector signed char)vec_xl(16, q4); q4 += 32; vector signed char q4x00 = (vector signed char)vec_and(qxs0, lowMask); vector signed char q4x01 = (vector signed char)vec_sr(qxs0, v4); vector signed char q4x10 = (vector signed char)vec_and(qxs1, lowMask); vector signed char q4x11 = (vector signed char)vec_sr(qxs1, v4); q4x00 = vec_perm(values, values, (vector unsigned char)q4x00); q4x01 = vec_perm(values, values, (vector unsigned char)q4x01); q4x10 = vec_perm(values, values, (vector unsigned char)q4x10); q4x11 = vec_perm(values, values, (vector unsigned char)q4x11); vector signed char q8y0 = vec_xl( 0, q8); vector signed char q8y1 = vec_xl(16, q8); vector signed char q8y2 = vec_xl(32, q8); vector signed char q8y3 = vec_xl(48, q8); q8 += 64; vector signed short qv0 = vec_add(vec_mule(q4x00, q8y0), vec_mulo(q4x00, q8y0)); vector signed short qv1 = vec_add(vec_mule(q4x01, q8y1), vec_mulo(q4x01, q8y1)); vector signed short qv2 = vec_add(vec_mule(q4x10, q8y2), vec_mulo(q4x10, q8y2)); vector signed short qv3 = vec_add(vec_mule(q4x11, q8y3), vec_mulo(q4x11, q8y3)); const uint16_t ls0 = (uint16_t)(((sc[0] & 0xf) | ((h << 4) & 0x30)) - 32); const uint16_t ls1 = (uint16_t)(((sc[0] >> 4) | ((h << 2) & 0x30)) - 32); h >>= 4; sc ++; vector signed short vscales01 = vec_splats((int16_t)ls0); vector signed short vscales23 = vec_splats((int16_t)ls1); vsumi0 = vec_msum(qv0, vscales01, vsumi0); vsumi1 = vec_msum(qv1, vscales01, vsumi1); vsumi2 = vec_msum(qv2, vscales23, vsumi2); vsumi3 = vec_msum(qv3, vscales23, vsumi3); } vsumf0 = vec_madd(vec_ctf(vsumi0, 0), vd, vsumf0); vsumf1 = vec_madd(vec_ctf(vsumi1, 0), vd, vsumf1); vsumf2 = vec_madd(vec_ctf(vsumi2, 0), vd, vsumf2); vsumf3 = vec_madd(vec_ctf(vsumi3, 0), vd, vsumf3); } vsumf0 = vec_add(vsumf0, vsumf2); vsumf1 = vec_add(vsumf1, vsumf3); vsumf0 = vec_add(vsumf0, vsumf1); vsumf0 = vec_add(vsumf0, vec_sld(vsumf0, vsumf0, 4)); vsumf0 = vec_add(vsumf0, vec_sld(vsumf0, vsumf0, 8)); *s = vec_extract(vsumf0, 0); #elif defined(__loongarch_asx) const __m128i values128 = __lsx_vld((const __m128i*)kvalues_iq4nl, 0); __m256 accum = (__m256)__lasx_xvldi(0); for (int ibl = 0; ibl < nb; ++ibl) { const uint8_t * qs = x[ibl].qs; const int8_t * q8 = y[ibl].qs; uint16_t sh = x[ibl].scales_h; __m256i sumi1 = __lasx_xvldi(0); __m256i sumi2 = __lasx_xvldi(0); for (int ib = 0; ib < QK_K/32; ib += 2) { const __m128i q4bits_1 = __lsx_vld((const __m128i*)qs, 0); qs += 16; const __m128i q4bits_2 = __lsx_vld((const __m128i*)qs, 0); qs += 16; const __m256i q8b_1 = __lasx_xvld((const __m256i *)q8, 0); q8 += 32; const __m256i q8b_2 = __lasx_xvld((const __m256i *)q8, 0); q8 += 32; const __m256i q4b_1 = lasx_insertf128(__lsx_vshuf_b(values128, values128, __lsx_vsrli_b(q4bits_1, 4)), __lsx_vshuf_b(values128, values128, __lsx_vandi_b(q4bits_1, 0xf))); const __m256i q4b_2 = lasx_insertf128(__lsx_vshuf_b(values128, values128, __lsx_vsrli_b(q4bits_2, 4)), __lsx_vshuf_b(values128, values128, __lsx_vandi_b(q4bits_2, 0xf))); const __m256i p16_1 = mul_add_epi8(q4b_1, q8b_1); const __m256i p16_2 = mul_add_epi8(q4b_2, q8b_2); const int16_t ls1 = ((x[ibl].scales_l[ib/2] & 0xf) | ((sh << 4) & 0x30)) - 32; const int16_t ls2 = ((x[ibl].scales_l[ib/2] >> 4) | ((sh << 2) & 0x30)) - 32; sh >>= 4; const __m256i p_1 = lasx_madd_h(p16_1, __lasx_xvreplgr2vr_h(ls1)); const __m256i p_2 = lasx_madd_h(p16_2, __lasx_xvreplgr2vr_h(ls2)); sumi1 = __lasx_xvadd_w(p_1, sumi1); sumi2 = __lasx_xvadd_w(p_2, sumi2); } accum = __lasx_xvfmadd_s(__lasx_xvreplfr2vr_s(GGML_FP16_TO_FP32(x[ibl].d)*y[ibl].d), __lasx_xvffint_s_w(__lasx_xvadd_w(sumi1, sumi2)), accum); } *s = hsum_float_8(accum); #elif defined(__VXE__) || defined(__VXE2__) const int8x16_t v_k = vec_xl(0, kvalues_iq4nl); const uint8x16_t v_m = vec_splat_u8(0x0F); float sumf = 0; for (int ibl = 0; ibl < nb; ++ibl) { const uint8_t * GGML_RESTRICT q4 = x[ibl].qs; const int8_t * GGML_RESTRICT q8 = y[ibl].qs; uint16_t h = x[ibl].scales_h; int sumi1 = 0, sumi2 = 0; for (int ib = 0; ib < QK_K/64; ++ib) { const uint8x16_t v_x0 = vec_xl(0 , q4); const uint8x16_t v_x1 = vec_xl(QK4_NL/2, q4); q4 += 32; int8x16_t v_x0l = (int8x16_t)vec_and(v_x0, v_m); int8x16_t v_x0h = (int8x16_t)vec_sr(v_x0, 4); int8x16_t v_x1l = (int8x16_t)vec_and(v_x1, v_m); int8x16_t v_x1h = (int8x16_t)vec_sr(v_x1, 4); v_x0l = vec_perm(v_k, v_k, (uchar8x16_t)v_x0l); v_x0h = vec_perm(v_k, v_k, (uchar8x16_t)v_x0h); v_x1l = vec_perm(v_k, v_k, (uchar8x16_t)v_x1l); v_x1h = vec_perm(v_k, v_k, (uchar8x16_t)v_x1h); const int8x16_t v_y0 = vec_xl( 0, q8); const int8x16_t v_y1 = vec_xl(16, q8); const int8x16_t v_y2 = vec_xl(32, q8); const int8x16_t v_y3 = vec_xl(48, q8); q8 += 64; int32x4_t vsumi0 = ggml_vec_dot(ggml_vec_dot(vec_splats(0), v_x0l, v_y0), v_x0h, v_y1); int32x4_t vsumi1 = ggml_vec_dot(ggml_vec_dot(vec_splats(0), v_x1l, v_y2), v_x1h, v_y3); int ls1 = ((x[ibl].scales_l[ib] & 0xF) | ((h << 4) & 0x30)) - 32; int ls2 = ((x[ibl].scales_l[ib] >> 4) | ((h << 2) & 0x30)) - 32; h >>= 4; sumi1 += (vsumi0[0] + vsumi0[1] + vsumi0[2] + vsumi0[3]) * ls1; sumi2 += (vsumi1[0] + vsumi1[1] + vsumi1[2] + vsumi1[3]) * ls2; } sumf += GGML_FP16_TO_FP32(x[ibl].d) * y[ibl].d * (sumi1 + sumi2); } *s = sumf; #else float sumf = 0; for (int ibl = 0; ibl < nb; ++ibl) { const float d4d8 = GGML_FP16_TO_FP32(x[ibl].d) * y[ibl].d; uint16_t h = x[ibl].scales_h; const uint8_t * qs = x[ibl].qs; const int8_t * q8 = y[ibl].qs; for (int ib = 0; ib < QK_K/32; ib += 2) { const uint8_t ls1 = (x[ibl].scales_l[ib/2] & 0xf) | ((h << 4) & 0x30); const uint8_t ls2 = (x[ibl].scales_l[ib/2] >> 4) | ((h << 2) & 0x30); h >>= 4; const float d1 = d4d8*(ls1 - 32); const float d2 = d4d8*(ls2 - 32); int sumi1 = 0, sumi2 = 0; for (int j = 0; j < 16; ++j) { sumi1 += q8[j+ 0] * kvalues_iq4nl[qs[j] & 0xf]; sumi2 += q8[j+16] * kvalues_iq4nl[qs[j] >> 4]; } sumf += d1 * (sumi1 + sumi2); qs += 16; q8 += 32; sumi1 = sumi2 = 0; for (int j = 0; j < 16; ++j) { sumi1 += q8[j+ 0] * kvalues_iq4nl[qs[j] & 0xf]; sumi2 += q8[j+16] * kvalues_iq4nl[qs[j] >> 4]; } sumf += d2 * (sumi1 + sumi2); qs += 16; q8 += 32; } } *s = sumf; #endif }
O1
c
ggml_vec_dot_iq4_xs_q8_K: pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx movq %r9, -0x10(%rsp) movq %rsi, -0x8(%rsp) vpxor %xmm3, %xmm3, %xmm3 cmpl $0x100, %edi # imm = 0x100 jl 0x20a1e shrl $0x8, %edi leaq 0x4(%rcx), %r11 leaq 0x8(%rcx), %rdx movq -0x10(%rsp), %rax leaq 0x4(%rax), %r8 vxorps %xmm2, %xmm2, %xmm2 xorl %r10d, %r10d vpbroadcastb 0x29fed(%rip), %ymm0 # 0x4a8c2 vbroadcasti128 0x29812(%rip), %ymm1 # ymm1 = mem[0,1,0,1] movq %r10, %rax shlq $0x7, %rax leaq (%rax,%r10,8), %rax leaq (%rcx,%rax), %r15 imulq $0x124, %r10, %r14 # imm = 0x124 addq -0x10(%rsp), %r14 movzwl 0x2(%rcx,%rax), %ebp movq $-0x2, %r12 xorl %r13d, %r13d movq %r11, %rax vpxor %xmm3, %xmm3, %xmm3 vpxor %xmm4, %xmm4, %xmm4 vmovdqu (%rdx,%r13), %xmm5 vmovdqu 0x10(%rdx,%r13), %xmm6 vmovdqu (%r8,%r13,2), %ymm7 vmovdqu 0x20(%r8,%r13,2), %ymm8 vpsrlw $0x4, %xmm5, %xmm9 vpsrlw $0x4, %xmm6, %xmm10 vinserti128 $0x1, %xmm9, %ymm5, %ymm5 vpand %ymm0, %ymm5, %ymm5 vpshufb %ymm5, %ymm1, %ymm5 vpsignb %ymm5, %ymm5, %ymm9 vpsignb %ymm5, %ymm7, %ymm5 vpmaddubsw %ymm5, %ymm9, %ymm5 vinserti128 $0x1, %xmm10, %ymm6, %ymm6 vpand %ymm0, %ymm6, %ymm6 vpshufb %ymm6, %ymm1, %ymm6 vpsignb %ymm6, %ymm6, %ymm7 vpsignb %ymm6, %ymm8, %ymm6 vpmaddubsw %ymm6, %ymm7, %ymm6 movzbl (%rax), %ebx movl %ebx, %esi andl $0xf, %esi movzwl %bp, %ebp movl %ebp, %r9d shll $0x4, %r9d andl $0x30, %r9d addl %r9d, %esi addl $-0x20, %esi shrl $0x4, %ebx movl %ebp, %r9d andl $0xc, %r9d leal (%rbx,%r9,4), %r9d addl $-0x20, %r9d shrl $0x4, %ebp vpbroadcastw %esi, %ymm7 vpmaddwd %ymm7, %ymm5, %ymm5 vpaddd %ymm3, %ymm5, %ymm3 vpbroadcastw %r9d, %ymm5 vpmaddwd %ymm5, %ymm6, %ymm5 vpaddd %ymm4, %ymm5, %ymm4 addq $0x2, %r12 incq %rax addq $0x20, %r13 cmpq $0x6, %r12 jb 0x20913 movzwl (%r15), %eax movq 0x3b580(%rip), %rsi # 0x5bf60 vmovss (%rsi,%rax,4), %xmm5 vmulss (%r14), %xmm5, %xmm5 vbroadcastss %xmm5, %ymm5 vpaddd %ymm4, %ymm3, %ymm3 vcvtdq2ps %ymm3, %ymm3 vfmadd213ps %ymm2, %ymm5, %ymm3 # ymm3 = (ymm5 * ymm3) + ymm2 incq %r10 movl $0x88, %eax addq %rax, %r11 addq %rax, %rdx addq $0x124, %r8 # imm = 0x124 vmovaps %ymm3, %ymm2 cmpq %rdi, %r10 jne 0x208de vextracti128 $0x1, %ymm3, %xmm0 vaddps %xmm3, %xmm0, %xmm0 vshufpd $0x1, %xmm0, %xmm0, %xmm1 # xmm1 = xmm0[1,0] vaddps %xmm1, %xmm0, %xmm0 vhaddps %xmm0, %xmm0, %xmm0 movq -0x8(%rsp), %rax vmovss %xmm0, (%rax) popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp vzeroupper retq
ggml_vec_dot_iq4_xs_q8_K: push rbp push r15 push r14 push r13 push r12 push rbx mov [rsp+30h+var_40], r9 mov [rsp+30h+var_38], rsi vpxor xmm3, xmm3, xmm3 cmp edi, 100h jl loc_20A1E shr edi, 8 lea r11, [rcx+4] lea rdx, [rcx+8] mov rax, [rsp+30h+var_40] lea r8, [rax+4] vxorps xmm2, xmm2, xmm2 xor r10d, r10d vpbroadcastb ymm0, cs:byte_4A8C2 vbroadcasti128 ymm1, cs:kvalues_iq4nl loc_208DE: mov rax, r10 shl rax, 7 lea rax, [rax+r10*8] lea r15, [rcx+rax] imul r14, r10, 124h add r14, [rsp+30h+var_40] movzx ebp, word ptr [rcx+rax+2] mov r12, 0FFFFFFFFFFFFFFFEh xor r13d, r13d mov rax, r11 vpxor xmm3, xmm3, xmm3 vpxor xmm4, xmm4, xmm4 loc_20913: vmovdqu xmm5, xmmword ptr [rdx+r13] vmovdqu xmm6, xmmword ptr [rdx+r13+10h] vmovdqu ymm7, ymmword ptr [r8+r13*2] vmovdqu ymm8, ymmword ptr [r8+r13*2+20h] vpsrlw xmm9, xmm5, 4 vpsrlw xmm10, xmm6, 4 vinserti128 ymm5, ymm5, xmm9, 1 vpand ymm5, ymm5, ymm0 vpshufb ymm5, ymm1, ymm5 vpsignb ymm9, ymm5, ymm5 vpsignb ymm5, ymm7, ymm5 vpmaddubsw ymm5, ymm9, ymm5 vinserti128 ymm6, ymm6, xmm10, 1 vpand ymm6, ymm6, ymm0 vpshufb ymm6, ymm1, ymm6 vpsignb ymm7, ymm6, ymm6 vpsignb ymm6, ymm8, ymm6 vpmaddubsw ymm6, ymm7, ymm6 movzx ebx, byte ptr [rax] mov esi, ebx and esi, 0Fh movzx ebp, bp mov r9d, ebp shl r9d, 4 and r9d, 30h add esi, r9d add esi, 0FFFFFFE0h shr ebx, 4 mov r9d, ebp and r9d, 0Ch lea r9d, [rbx+r9*4] add r9d, 0FFFFFFE0h shr ebp, 4 vpbroadcastw ymm7, esi vpmaddwd ymm5, ymm5, ymm7 vpaddd ymm3, ymm5, ymm3 vpbroadcastw ymm5, r9d vpmaddwd ymm5, ymm6, ymm5 vpaddd ymm4, ymm5, ymm4 add r12, 2 inc rax add r13, 20h ; ' ' cmp r12, 6 jb loc_20913 movzx eax, word ptr [r15] mov rsi, cs:ggml_table_f32_f16_ptr vmovss xmm5, dword ptr [rsi+rax*4] vmulss xmm5, xmm5, dword ptr [r14] vbroadcastss ymm5, xmm5 vpaddd ymm3, ymm3, ymm4 vcvtdq2ps ymm3, ymm3 vfmadd213ps ymm3, ymm5, ymm2 inc r10 mov eax, 88h add r11, rax add rdx, rax add r8, 124h vmovaps ymm2, ymm3 cmp r10, rdi jnz loc_208DE loc_20A1E: vextracti128 xmm0, ymm3, 1 vaddps xmm0, xmm0, xmm3 vshufpd xmm1, xmm0, xmm0, 1 vaddps xmm0, xmm0, xmm1 vhaddps xmm0, xmm0, xmm0 mov rax, [rsp+30h+var_38] vmovss dword ptr [rax], xmm0 pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp vzeroupper retn
long long ggml_vec_dot_iq4_xs_q8_K( int a1, long long a2, double a3, double a4, __m128 _XMM2, __m128 _XMM3, __m128 _XMM4, long long a8, long long a9, long long a10, long long a11) { long long v15; // rdi _BYTE *v16; // r11 long long v20; // r10 unsigned __int16 *v23; // r15 int v24; // ebp unsigned long long v25; // r12 _BYTE *v27; // rax long long result; // rax __asm { vpxor xmm3, xmm3, xmm3 } if ( a1 >= 256 ) { v15 = (unsigned int)a1 >> 8; v16 = (_BYTE *)(a9 + 4); _RDX = a9 + 8; _R8 = a11 + 4; __asm { vxorps xmm2, xmm2, xmm2 } v20 = 0LL; __asm { vpbroadcastb ymm0, cs:byte_4A8C2 vbroadcasti128 ymm1, cs:kvalues_iq4nl } do { v23 = (unsigned __int16 *)(a9 + 136 * v20); LOWORD(v24) = v23[1]; v25 = -2LL; _R13 = 0LL; v27 = v16; __asm { vpxor xmm3, xmm3, xmm3 vpxor xmm4, xmm4, xmm4 } do { __asm { vmovdqu xmm5, xmmword ptr [rdx+r13] vmovdqu xmm6, xmmword ptr [rdx+r13+10h] vmovdqu ymm7, ymmword ptr [r8+r13*2] vmovdqu ymm8, ymmword ptr [r8+r13*2+20h] vpsrlw xmm9, xmm5, 4 vpsrlw xmm10, xmm6, 4 vinserti128 ymm5, ymm5, xmm9, 1 vpand ymm5, ymm5, ymm0 vpshufb ymm5, ymm1, ymm5 vpsignb ymm9, ymm5, ymm5 vpsignb ymm5, ymm7, ymm5 vpmaddubsw ymm5, ymm9, ymm5 vinserti128 ymm6, ymm6, xmm10, 1 vpand ymm6, ymm6, ymm0 vpshufb ymm6, ymm1, ymm6 vpsignb ymm7, ymm6, ymm6 vpsignb ymm6, ymm8, ymm6 vpmaddubsw ymm6, ymm7, ymm6 } _ESI = ((16 * (_BYTE)v24) & 0x30) + (*v27 & 0xF) - 32; _R9D = ((unsigned __int8)*v27 >> 4) + 4 * (v24 & 0xC) - 32; v24 = (unsigned __int16)v24 >> 4; __asm { vpbroadcastw ymm7, esi vpmaddwd ymm5, ymm5, ymm7 vpaddd ymm3, ymm5, ymm3 vpbroadcastw ymm5, r9d vpmaddwd ymm5, ymm6, ymm5 vpaddd ymm4, ymm5, ymm4 } v25 += 2LL; ++v27; _R13 += 32LL; } while ( v25 < 6 ); _RAX = *v23; _RSI = &ggml_table_f32_f16; __asm { vmovss xmm5, dword ptr [rsi+rax*4] vmulss xmm5, xmm5, dword ptr [r14] vbroadcastss ymm5, xmm5 vpaddd ymm3, ymm3, ymm4 vcvtdq2ps ymm3, ymm3 vfmadd213ps ymm3, ymm5, ymm2 } ++v20; v16 += 136; _RDX += 136LL; _R8 += 292LL; __asm { vmovaps ymm2, ymm3 } } while ( v20 != v15 ); } __asm { vextracti128 xmm0, ymm3, 1 vaddps xmm0, xmm0, xmm3 vshufpd xmm1, xmm0, xmm0, 1 vaddps xmm0, xmm0, xmm1 vhaddps xmm0, xmm0, xmm0 } result = a2; __asm { vmovss dword ptr [rax], xmm0 vzeroupper } return result; }
ggml_vec_dot_iq4_xs_q8_K: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX MOV qword ptr [RSP + -0x10],R9 MOV qword ptr [RSP + -0x8],RSI VPXOR XMM3,XMM3,XMM3 CMP EDI,0x100 JL 0x00120a1e SHR EDI,0x8 LEA R11,[RCX + 0x4] LEA RDX,[RCX + 0x8] MOV RAX,qword ptr [RSP + -0x10] LEA R8,[RAX + 0x4] VXORPS XMM2,XMM2,XMM2 XOR R10D,R10D VPBROADCASTB YMM0,byte ptr [0x0014a8c2] VBROADCASTI128 YMM1,xmmword ptr [0x0014a0f0] LAB_001208de: MOV RAX,R10 SHL RAX,0x7 LEA RAX,[RAX + R10*0x8] LEA R15,[RCX + RAX*0x1] IMUL R14,R10,0x124 ADD R14,qword ptr [RSP + -0x10] MOVZX EBP,word ptr [RCX + RAX*0x1 + 0x2] MOV R12,-0x2 XOR R13D,R13D MOV RAX,R11 VPXOR XMM3,XMM3,XMM3 VPXOR XMM4,XMM4,XMM4 LAB_00120913: VMOVDQU XMM5,xmmword ptr [RDX + R13*0x1] VMOVDQU XMM6,xmmword ptr [RDX + R13*0x1 + 0x10] VMOVDQU YMM7,ymmword ptr [R8 + R13*0x2] VMOVDQU YMM8,ymmword ptr [R8 + R13*0x2 + 0x20] VPSRLW XMM9,XMM5,0x4 VPSRLW XMM10,XMM6,0x4 VINSERTI128 YMM5,YMM5,XMM9,0x1 VPAND YMM5,YMM5,YMM0 VPSHUFB YMM5,YMM1,YMM5 VPSIGNB YMM9,YMM5,YMM5 VPSIGNB YMM5,YMM7,YMM5 VPMADDUBSW YMM5,YMM9,YMM5 VINSERTI128 YMM6,YMM6,XMM10,0x1 VPAND YMM6,YMM6,YMM0 VPSHUFB YMM6,YMM1,YMM6 VPSIGNB YMM7,YMM6,YMM6 VPSIGNB YMM6,YMM8,YMM6 VPMADDUBSW YMM6,YMM7,YMM6 MOVZX EBX,byte ptr [RAX] MOV ESI,EBX AND ESI,0xf MOVZX EBP,BP MOV R9D,EBP SHL R9D,0x4 AND R9D,0x30 ADD ESI,R9D ADD ESI,-0x20 SHR EBX,0x4 MOV R9D,EBP AND R9D,0xc LEA R9D,[RBX + R9*0x4] ADD R9D,-0x20 SHR EBP,0x4 VPBROADCASTW YMM7 VPMADDWD YMM5,YMM5,YMM7 VPADDD YMM3,YMM5,YMM3 VPBROADCASTW YMM5 VPMADDWD YMM5,YMM6,YMM5 VPADDD YMM4,YMM5,YMM4 ADD R12,0x2 INC RAX ADD R13,0x20 CMP R12,0x6 JC 0x00120913 MOVZX EAX,word ptr [R15] MOV RSI,qword ptr [0x0015bf60] VMOVSS XMM5,dword ptr [RSI + RAX*0x4] VMULSS XMM5,XMM5,dword ptr [R14] VBROADCASTSS YMM5,XMM5 VPADDD YMM3,YMM3,YMM4 VCVTDQ2PS YMM3,YMM3 VFMADD213PS YMM3,YMM5,YMM2 INC R10 MOV EAX,0x88 ADD R11,RAX ADD RDX,RAX ADD R8,0x124 VMOVAPS YMM2,YMM3 CMP R10,RDI JNZ 0x001208de LAB_00120a1e: VEXTRACTI128 XMM0,YMM3,0x1 VADDPS XMM0,XMM0,XMM3 VSHUFPD XMM1,XMM0,XMM0,0x1 VADDPS XMM0,XMM0,XMM1 VHADDPS XMM0,XMM0,XMM0 MOV RAX,qword ptr [RSP + -0x8] VMOVSS dword ptr [RAX],XMM0 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP VZEROUPPER RET
void ggml_vec_dot_iq4_xs_q8_K (uint param_1,int4 *param_2,int8 param_3,long param_4,int8 param_5, long param_6) { float fVar1; long lVar2; long lVar3; ulong uVar4; ulong uVar5; long lVar6; int1 auVar7 [32]; int1 auVar8 [32]; int1 auVar9 [16]; int1 auVar10 [32]; int1 auVar11 [32]; int1 auVar12 [16]; int1 auVar13 [64]; int1 auVar14 [64]; int1 auVar15 [32]; int1 auVar16 [32]; int1 auVar17 [16]; int1 auVar18 [16]; auVar7 = SUB6432(ZEXT1664((int1 [16])0x0),0); if (0xff < (int)param_1) { lVar2 = param_4 + 8; lVar3 = param_6 + 4; auVar12 = ZEXT816(0) << 0x40; uVar4 = 0; auVar10[1] = DAT_0014a8c2; auVar10[0] = DAT_0014a8c2; auVar10[2] = DAT_0014a8c2; auVar10[3] = DAT_0014a8c2; auVar10[4] = DAT_0014a8c2; auVar10[5] = DAT_0014a8c2; auVar10[6] = DAT_0014a8c2; auVar10[7] = DAT_0014a8c2; auVar10[8] = DAT_0014a8c2; auVar10[9] = DAT_0014a8c2; auVar10[10] = DAT_0014a8c2; auVar10[0xb] = DAT_0014a8c2; auVar10[0xc] = DAT_0014a8c2; auVar10[0xd] = DAT_0014a8c2; auVar10[0xe] = DAT_0014a8c2; auVar10[0xf] = DAT_0014a8c2; auVar10[0x10] = DAT_0014a8c2; auVar10[0x11] = DAT_0014a8c2; auVar10[0x12] = DAT_0014a8c2; auVar10[0x13] = DAT_0014a8c2; auVar10[0x14] = DAT_0014a8c2; auVar10[0x15] = DAT_0014a8c2; auVar10[0x16] = DAT_0014a8c2; auVar10[0x17] = DAT_0014a8c2; auVar10[0x18] = DAT_0014a8c2; auVar10[0x19] = DAT_0014a8c2; auVar10[0x1a] = DAT_0014a8c2; auVar10[0x1b] = DAT_0014a8c2; auVar10[0x1c] = DAT_0014a8c2; auVar10[0x1d] = DAT_0014a8c2; auVar10[0x1e] = DAT_0014a8c2; auVar10[0x1f] = DAT_0014a8c2; auVar11._16_16_ = kvalues_iq4nl; auVar11._0_16_ = kvalues_iq4nl; do { uVar5 = 0xfffffffffffffffe; lVar6 = 0; auVar13 = ZEXT1664((int1 [16])0x0); auVar14 = ZEXT1664((int1 [16])0x0); do { auVar9 = *(int1 (*) [16])(lVar2 + 0x10 + lVar6); auVar17 = vpsrlw_avx(*(int1 (*) [16])(lVar2 + lVar6),4); auVar18 = vpsrlw_avx(auVar9,4); auVar7._0_16_ = ZEXT116(0) * auVar17 + ZEXT116(1) * *(int1 (*) [16])(lVar2 + lVar6); auVar7._16_16_ = ZEXT116(0) * SUB4816((int1 [48])0x0,0) + ZEXT116(1) * auVar17; auVar7 = vpand_avx2(auVar7,auVar10); auVar7 = vpshufb_avx2(auVar11,auVar7); auVar8 = vpsignb_avx2(auVar7,auVar7); auVar7 = vpsignb_avx2(*(int1 (*) [32])(lVar3 + lVar6 * 2),auVar7); auVar8 = vpmaddubsw_avx2(auVar8,auVar7); auVar16._0_16_ = ZEXT116(0) * auVar18 + ZEXT116(1) * auVar9; auVar16._16_16_ = ZEXT116(0) * SUB4816((int1 [48])0x0,0) + ZEXT116(1) * auVar18; auVar7 = vpand_avx2(auVar16,auVar10); auVar7 = vpshufb_avx2(auVar11,auVar7); auVar16 = vpsignb_avx2(auVar7,auVar7); auVar7 = vpsignb_avx2(*(int1 (*) [32])(lVar3 + 0x20 + lVar6 * 2),auVar7); auVar16 = vpmaddubsw_avx2(auVar16,auVar7); auVar7 = vpbroadcastw_avx512vl(); auVar7 = vpmaddwd_avx2(auVar8,auVar7); auVar7 = vpaddd_avx2(auVar7,auVar13._0_32_); auVar13 = ZEXT3264(auVar7); auVar8 = vpbroadcastw_avx512vl(); auVar8 = vpmaddwd_avx2(auVar16,auVar8); auVar8 = vpaddd_avx2(auVar8,auVar14._0_32_); auVar14 = ZEXT3264(auVar8); uVar5 = uVar5 + 2; lVar6 = lVar6 + 0x20; } while (uVar5 < 6); fVar1 = *(float *)(PTR_ggml_table_f32_f16_0015bf60 + (ulong)*(ushort *)(param_4 + uVar4 * 0x88) * 4) * *(float *)(uVar4 * 0x124 + param_6); auVar15._4_4_ = fVar1; auVar15._0_4_ = fVar1; auVar15._8_4_ = fVar1; auVar15._12_4_ = fVar1; auVar15._16_4_ = fVar1; auVar15._20_4_ = fVar1; auVar15._24_4_ = fVar1; auVar15._28_4_ = fVar1; auVar7 = vpaddd_avx2(auVar7,auVar8); auVar7 = vcvtdq2ps_avx(auVar7); auVar12 = vfmadd213ps_fma(auVar7,auVar15,ZEXT1632(auVar12)); auVar7 = ZEXT1632(auVar12); uVar4 = uVar4 + 1; lVar2 = lVar2 + 0x88; lVar3 = lVar3 + 0x124; } while (uVar4 != param_1 >> 8); } auVar9._0_4_ = auVar7._16_4_ + auVar7._0_4_; auVar9._4_4_ = auVar7._20_4_ + auVar7._4_4_; auVar9._8_4_ = auVar7._24_4_ + auVar7._8_4_; auVar9._12_4_ = auVar7._28_4_ + auVar7._12_4_; auVar12 = vshufpd_avx(auVar9,auVar9,1); auVar17._0_4_ = auVar9._0_4_ + auVar12._0_4_; auVar17._4_4_ = auVar9._4_4_ + auVar12._4_4_; auVar17._8_4_ = auVar9._8_4_ + auVar12._8_4_; auVar17._12_4_ = auVar9._12_4_ + auVar12._12_4_; auVar12 = vhaddps_avx(auVar17,auVar17); *param_2 = auVar12._0_4_; return; }
60,858
my_strxfrm_pad_unicode
eloqsql/strings/ctype-utf8.c
size_t my_strxfrm_pad_unicode(uchar *str, uchar *strend) { uchar *str0= str; DBUG_ASSERT(str && str <= strend); for ( ; str < strend ; ) { *str++= 0x00; if (str < strend) *str++= 0x20; } return str - str0; }
O3
c
my_strxfrm_pad_unicode: movq %rdi, %rax cmpq %rsi, %rdi jae 0x6146c pushq %rbp movq %rsp, %rbp movq %rdi, %rcx leaq 0x1(%rcx), %rax movb $0x0, (%rcx) cmpq %rsi, %rax jae 0x61463 movb $0x20, 0x1(%rcx) addq $0x2, %rcx movq %rcx, %rax movq %rax, %rcx cmpq %rsi, %rax jb 0x6144c popq %rbp subq %rdi, %rax retq
my_strxfrm_pad_unicode: mov rax, rdi cmp rdi, rsi jnb short loc_6146C push rbp mov rbp, rsp mov rcx, rdi loc_6144C: lea rax, [rcx+1] mov byte ptr [rcx], 0 cmp rax, rsi jnb short loc_61463 mov byte ptr [rcx+1], 20h ; ' ' add rcx, 2 mov rax, rcx loc_61463: mov rcx, rax cmp rax, rsi jb short loc_6144C pop rbp loc_6146C: sub rax, rdi retn
long long my_strxfrm_pad_unicode(_BYTE *a1, unsigned long long a2) { _BYTE *v2; // rax _BYTE *v3; // rcx v2 = a1; if ( (unsigned long long)a1 < a2 ) { v3 = a1; do { v2 = v3 + 1; *v3 = 0; if ( (unsigned long long)(v3 + 1) < a2 ) { v3[1] = 32; v2 = v3 + 2; } v3 = v2; } while ( (unsigned long long)v2 < a2 ); } return v2 - a1; }
my_strxfrm_pad_unicode: MOV RAX,RDI CMP RDI,RSI JNC 0x0016146c PUSH RBP MOV RBP,RSP MOV RCX,RDI LAB_0016144c: LEA RAX,[RCX + 0x1] MOV byte ptr [RCX],0x0 CMP RAX,RSI JNC 0x00161463 MOV byte ptr [RCX + 0x1],0x20 ADD RCX,0x2 MOV RAX,RCX LAB_00161463: MOV RCX,RAX CMP RAX,RSI JC 0x0016144c POP RBP LAB_0016146c: SUB RAX,RDI RET
long my_strxfrm_pad_unicode(int1 *param_1,int1 *param_2) { int1 *puVar1; int1 *puVar2; puVar2 = param_1; puVar1 = param_1; if (param_1 < param_2) { do { puVar2 = puVar1 + 1; *puVar1 = 0; if (puVar2 < param_2) { puVar1[1] = 0x20; puVar2 = puVar1 + 2; } puVar1 = puVar2; } while (puVar2 < param_2); } return (long)puVar2 - (long)param_1; }
60,859
ma_ft_del
eloqsql/storage/maria/ma_ft_update.c
int _ma_ft_del(MARIA_HA *info, uint keynr, uchar *keybuf, const uchar *record, my_off_t pos) { int error= -1; FT_WORD *wlist; DBUG_ENTER("_ma_ft_del"); DBUG_PRINT("enter",("keynr: %d",keynr)); if ((wlist= _ma_ft_parserecord(info, keynr, record, &info->ft_memroot))) error= _ma_ft_erase(info,keynr,keybuf,wlist,pos); free_root(&info->ft_memroot, MYF(MY_MARK_BLOCKS_FREE)); DBUG_PRINT("exit",("Return: %d",error)); DBUG_RETURN(error); }
O0
c
ma_ft_del: pushq %rbp movq %rsp, %rbp subq $0x40, %rsp movq %rdi, -0x8(%rbp) movl %esi, -0xc(%rbp) movq %rdx, -0x18(%rbp) movq %rcx, -0x20(%rbp) movq %r8, -0x28(%rbp) movl $0xffffffff, -0x2c(%rbp) # imm = 0xFFFFFFFF jmp 0x7a2a4 movq -0x8(%rbp), %rdi movl -0xc(%rbp), %esi movq -0x20(%rbp), %rdx movq -0x8(%rbp), %rcx addq $0x328, %rcx # imm = 0x328 callq 0x79b10 movq %rax, -0x38(%rbp) cmpq $0x0, %rax je 0x7a2e4 movq -0x8(%rbp), %rdi movl -0xc(%rbp), %esi movq -0x18(%rbp), %rdx movq -0x38(%rbp), %rcx movq -0x28(%rbp), %r8 callq 0x7a0e0 movl %eax, -0x2c(%rbp) movq -0x8(%rbp), %rdi addq $0x328, %rdi # imm = 0x328 movl $0x2, %esi callq 0xf1df0 jmp 0x7a2fb jmp 0x7a2fd movl -0x2c(%rbp), %eax movl %eax, -0x3c(%rbp) movl -0x3c(%rbp), %eax addq $0x40, %rsp popq %rbp retq nopl (%rax)
_ma_ft_del: push rbp mov rbp, rsp sub rsp, 40h mov [rbp+var_8], rdi mov [rbp+var_C], esi mov [rbp+var_18], rdx mov [rbp+var_20], rcx mov [rbp+var_28], r8 mov [rbp+var_2C], 0FFFFFFFFh jmp short $+2 loc_7A2A4: mov rdi, [rbp+var_8] mov esi, [rbp+var_C] mov rdx, [rbp+var_20] mov rcx, [rbp+var_8] add rcx, 328h call _ma_ft_parserecord mov [rbp+var_38], rax cmp rax, 0 jz short loc_7A2E4 mov rdi, [rbp+var_8] mov esi, [rbp+var_C] mov rdx, [rbp+var_18] mov rcx, [rbp+var_38] mov r8, [rbp+var_28] call _ma_ft_erase mov [rbp+var_2C], eax loc_7A2E4: mov rdi, [rbp+var_8] add rdi, 328h mov esi, 2 call free_root jmp short $+2 loc_7A2FB: jmp short $+2 loc_7A2FD: mov eax, [rbp+var_2C] mov [rbp+var_3C], eax mov eax, [rbp+var_3C] add rsp, 40h pop rbp retn
long long ma_ft_del(long long *a1, unsigned int a2, _BYTE *a3, long long a4, long long a5) { _QWORD *v6; // [rsp+8h] [rbp-38h] unsigned int v7; // [rsp+14h] [rbp-2Ch] v7 = -1; v6 = (_QWORD *)ma_ft_parserecord(a1, a2, a4, (long long)(a1 + 101)); if ( v6 ) v7 = ma_ft_erase(a1, a2, a3, v6, a5); free_root(a1 + 101, 2LL); return v7; }
_ma_ft_del: PUSH RBP MOV RBP,RSP SUB RSP,0x40 MOV qword ptr [RBP + -0x8],RDI MOV dword ptr [RBP + -0xc],ESI MOV qword ptr [RBP + -0x18],RDX MOV qword ptr [RBP + -0x20],RCX MOV qword ptr [RBP + -0x28],R8 MOV dword ptr [RBP + -0x2c],0xffffffff JMP 0x0017a2a4 LAB_0017a2a4: MOV RDI,qword ptr [RBP + -0x8] MOV ESI,dword ptr [RBP + -0xc] MOV RDX,qword ptr [RBP + -0x20] MOV RCX,qword ptr [RBP + -0x8] ADD RCX,0x328 CALL 0x00179b10 MOV qword ptr [RBP + -0x38],RAX CMP RAX,0x0 JZ 0x0017a2e4 MOV RDI,qword ptr [RBP + -0x8] MOV ESI,dword ptr [RBP + -0xc] MOV RDX,qword ptr [RBP + -0x18] MOV RCX,qword ptr [RBP + -0x38] MOV R8,qword ptr [RBP + -0x28] CALL 0x0017a0e0 MOV dword ptr [RBP + -0x2c],EAX LAB_0017a2e4: MOV RDI,qword ptr [RBP + -0x8] ADD RDI,0x328 MOV ESI,0x2 CALL 0x001f1df0 JMP 0x0017a2fb LAB_0017a2fb: JMP 0x0017a2fd LAB_0017a2fd: MOV EAX,dword ptr [RBP + -0x2c] MOV dword ptr [RBP + -0x3c],EAX MOV EAX,dword ptr [RBP + -0x3c] ADD RSP,0x40 POP RBP RET
int4 _ma_ft_del(long param_1,int4 param_2,int8 param_3,int8 param_4,int8 param_5) { long lVar1; int4 local_34; local_34 = 0xffffffff; lVar1 = _ma_ft_parserecord(param_1,param_2,param_4,param_1 + 0x328); if (lVar1 != 0) { local_34 = _ma_ft_erase(param_1,param_2,param_3,lVar1,param_5); } free_root(param_1 + 0x328,2); return local_34; }
60,860
double minja::Value::get<double>() const
llama.cpp/common/minja/minja.hpp
T get() const { if (is_primitive()) return primitive_.get<T>(); throw std::runtime_error("get<T> not defined for this value type: " + dump()); }
O3
cpp
double minja::Value::get<double>() const: pushq %rbp pushq %r14 pushq %rbx subq $0x40, %rsp movq %rdi, %r14 cmpq $0x0, 0x10(%rdi) jne 0xc8b12 cmpq $0x0, 0x20(%r14) jne 0xc8b12 cmpq $0x0, 0x30(%r14) jne 0xc8b12 addq $0x40, %r14 leaq 0x20(%rsp), %rbx movq $0x0, (%rbx) movq %r14, %rdi movq %rbx, %rsi callq 0x3745d movsd (%rbx), %xmm0 addq $0x40, %rsp popq %rbx popq %r14 popq %rbp retq movl $0x10, %edi callq 0x21660 movq %rax, %rbx movq %rsp, %rdi movq %r14, %rsi movl $0xffffffff, %edx # imm = 0xFFFFFFFF xorl %ecx, %ecx callq 0xc030c leaq 0x610a7(%rip), %rsi # 0x129bdf leaq 0x20(%rsp), %rdi movq %rsp, %rdx callq 0xba080 movb $0x1, %bpl leaq 0x20(%rsp), %rsi movq %rbx, %rdi callq 0x21480 xorl %ebp, %ebp movq 0xa5462(%rip), %rsi # 0x16dfc0 movq 0xa541b(%rip), %rdx # 0x16df80 movq %rbx, %rdi callq 0x21a80 movq %rax, %r14 leaq 0x30(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0xc8b8b movq 0x30(%rsp), %rsi incq %rsi callq 0x21180 leaq 0x10(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0xc8ba6 movq 0x10(%rsp), %rsi incq %rsi callq 0x21180 testb %bpl, %bpl jne 0xc8bd0 jmp 0xc8bd8 movq %rax, %r14 leaq 0x10(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0xc8bd0 movq 0x10(%rsp), %rsi incq %rsi callq 0x21180 jmp 0xc8bd0 movq %rax, %r14 movq %rbx, %rdi callq 0x21f50 movq %r14, %rdi callq 0x21b20
_ZNK5minja5Value3getIdEET_v: push rbp push r14 push rbx sub rsp, 40h mov r14, rdi cmp qword ptr [rdi+10h], 0 jnz short loc_C8B12 cmp qword ptr [r14+20h], 0 jnz short loc_C8B12 cmp qword ptr [r14+30h], 0 jnz short loc_C8B12 add r14, 40h ; '@' lea rbx, [rsp+58h+var_38] mov qword ptr [rbx], 0 mov rdi, r14 mov rsi, rbx call _ZN8nlohmann16json_abi_v3_11_36detail20get_arithmetic_valueINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEdTnNSt9enable_ifIXaasr3std13is_arithmeticIT0_EE5valuentsr3std7is_sameISH_NT_9boolean_tEEE5valueEiE4typeELi0EEEvRKSI_RSH_ movsd xmm0, qword ptr [rbx] add rsp, 40h pop rbx pop r14 pop rbp retn loc_C8B12: mov edi, 10h; thrown_size call ___cxa_allocate_exception mov rbx, rax mov rdi, rsp mov rsi, r14 mov edx, 0FFFFFFFFh xor ecx, ecx call _ZNK5minja5Value4dumpB5cxx11Eib; minja::Value::dump(int,bool) lea rsi, aGetTNotDefined; "get<T> not defined for this value type:"... lea rdi, [rsp+58h+var_38] mov rdx, rsp call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_OS8_; std::operator+<char>(char const*,std::string&&) mov bpl, 1 lea rsi, [rsp+58h+var_38] mov rdi, rbx call __ZNSt13runtime_errorC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; std::runtime_error::runtime_error(std::string const&) xor ebp, ebp mov rsi, cs:_ZTISt13runtime_error_ptr; lptinfo mov rdx, cs:_ZNSt13runtime_errorD1Ev_ptr; void (*)(void *) mov rdi, rbx; void * call ___cxa_throw mov r14, rax lea rax, [rsp+58h+var_28] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_C8B8B mov rsi, [rsp+58h+var_28] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_C8B8B: lea rax, [rsp+58h+var_48] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_C8BA6 mov rsi, [rsp+58h+var_48] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_C8BA6: test bpl, bpl jnz short loc_C8BD0 jmp short loc_C8BD8 mov r14, rax lea rax, [rsp+58h+var_48] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_C8BD0 mov rsi, [rsp+58h+var_48] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) jmp short loc_C8BD0 mov r14, rax loc_C8BD0: mov rdi, rbx; void * call ___cxa_free_exception loc_C8BD8: mov rdi, r14 call __Unwind_Resume
double minja::Value::get<double>(long long a1) { void *exception; // rbx _BYTE v3[16]; // [rsp+0h] [rbp-58h] BYREF double v4[2]; // [rsp+20h] [rbp-38h] BYREF if ( *(_QWORD *)(a1 + 16) || *(_QWORD *)(a1 + 32) || *(_QWORD *)(a1 + 48) ) { exception = __cxa_allocate_exception(0x10uLL); minja::Value::dump[abi:cxx11]((long long)v3, a1, 0xFFFFFFFF, 0); std::operator+<char>(v4, (long long)"get<T> not defined for this value type: ", (long long)v3); std::runtime_error::runtime_error(exception, v4); __cxa_throw( exception, (struct type_info *)&`typeinfo for'std::runtime_error, (void (*)(void *))&std::runtime_error::~runtime_error); } v4[0] = 0.0; ZN8nlohmann16json_abi_v3_11_36detail20get_arithmetic_valueINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEdTnNSt9enable_ifIXaasr3std13is_arithmeticIT0_EE5valuentsr3std7is_sameISH_NT_9boolean_tEEE5valueEiE4typeELi0EEEvRKSI_RSH_( (unsigned __int8 *)(a1 + 64), v4); return v4[0]; }
get<double>: PUSH RBP PUSH R14 PUSH RBX SUB RSP,0x40 MOV R14,RDI CMP qword ptr [RDI + 0x10],0x0 JNZ 0x001c8b12 CMP qword ptr [R14 + 0x20],0x0 JNZ 0x001c8b12 CMP qword ptr [R14 + 0x30],0x0 JNZ 0x001c8b12 ADD R14,0x40 LEA RBX,[RSP + 0x20] MOV qword ptr [RBX],0x0 MOV RDI,R14 MOV RSI,RBX CALL 0x0013745d MOVSD XMM0,qword ptr [RBX] ADD RSP,0x40 POP RBX POP R14 POP RBP RET LAB_001c8b12: MOV EDI,0x10 CALL 0x00121660 MOV RBX,RAX LAB_001c8b1f: MOV RDI,RSP MOV RSI,R14 MOV EDX,0xffffffff XOR ECX,ECX CALL 0x001c030c LAB_001c8b31: LEA RSI,[0x229bdf] LEA RDI,[RSP + 0x20] MOV RDX,RSP CALL 0x001ba080 MOV BPL,0x1 LAB_001c8b48: LEA RSI,[RSP + 0x20] MOV RDI,RBX CALL 0x00121480 XOR EBP,EBP MOV RSI,qword ptr [0x0026dfc0] MOV RDX,qword ptr [0x0026df80] MOV RDI,RBX CALL 0x00121a80
/* double minja::Value::get<double>() const */ double __thiscall minja::Value::get<double>(Value *this) { runtime_error *this_00; int1 auStack_58 [32]; double local_38 [4]; if (((*(long *)(this + 0x10) == 0) && (*(long *)(this + 0x20) == 0)) && (*(long *)(this + 0x30) == 0)) { local_38[0] = 0.0; _ZN8nlohmann16json_abi_v3_11_36detail20get_arithmetic_valueINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEdTnNSt9enable_ifIXaasr3std13is_arithmeticIT0_EE5valuentsr3std7is_sameISH_NT_9boolean_tEEE5valueEiE4typeELi0EEEvRKSI_RSH_ (this + 0x40,local_38); return local_38[0]; } this_00 = (runtime_error *)__cxa_allocate_exception(0x10); /* try { // try from 001c8b1f to 001c8b30 has its CatchHandler @ 001c8bcd */ dump_abi_cxx11_((int)auStack_58,SUB81(this,0)); /* try { // try from 001c8b31 to 001c8b44 has its CatchHandler @ 001c8bad */ std::operator+((char *)local_38,(string *)"get<T> not defined for this value type: "); /* try { // try from 001c8b48 to 001c8b6c has its CatchHandler @ 001c8b6d */ std::runtime_error::runtime_error(this_00,(string *)local_38); /* WARNING: Subroutine does not return */ __cxa_throw(this_00,PTR_typeinfo_0026dfc0,PTR__runtime_error_0026df80); }
60,861
Encoder::get_num_tensors()
7CodeWizard[P]stablediffusion/vae.hpp
size_t get_num_tensors() { int num_tensors = 6; // mid num_tensors += 10 * 3; int len_mults = sizeof(ch_mult) / sizeof(int); for (int i = len_mults - 1; i >= 0; i--) { for (int j = 0; j < num_res_blocks + 1; j++) { num_tensors += 10; } if (i != 0) { num_tensors += 2; } } return num_tensors; }
O0
cpp
Encoder::get_num_tensors(): movq %rdi, -0x8(%rsp) movq -0x8(%rsp), %rax movq %rax, -0x20(%rsp) movl $0x6, -0xc(%rsp) movl -0xc(%rsp), %eax addl $0x1e, %eax movl %eax, -0xc(%rsp) movl $0x4, -0x10(%rsp) movl -0x10(%rsp), %eax subl $0x1, %eax movl %eax, -0x14(%rsp) cmpl $0x0, -0x14(%rsp) jl 0x4a2d0 movl $0x0, -0x18(%rsp) movq -0x20(%rsp), %rcx movl -0x18(%rsp), %eax movl 0x10(%rcx), %ecx addl $0x1, %ecx cmpl %ecx, %eax jge 0x4a2af movl -0xc(%rsp), %eax addl $0xa, %eax movl %eax, -0xc(%rsp) movl -0x18(%rsp), %eax addl $0x1, %eax movl %eax, -0x18(%rsp) jmp 0x4a284 cmpl $0x0, -0x14(%rsp) je 0x4a2c1 movl -0xc(%rsp), %eax addl $0x2, %eax movl %eax, -0xc(%rsp) jmp 0x4a2c3 movl -0x14(%rsp), %eax addl $-0x1, %eax movl %eax, -0x14(%rsp) jmp 0x4a275 movslq -0xc(%rsp), %rax retq nopw %cs:(%rax,%rax)
_ZN7Encoder15get_num_tensorsEv: mov [rsp+var_8], rdi mov rax, [rsp+var_8] mov [rsp+var_20], rax mov [rsp+var_C], 6 mov eax, [rsp+var_C] add eax, 1Eh mov [rsp+var_C], eax mov [rsp+var_10], 4 mov eax, [rsp+var_10] sub eax, 1 mov [rsp+var_14], eax loc_4A275: cmp [rsp+var_14], 0 jl short loc_4A2D0 mov [rsp+var_18], 0 loc_4A284: mov rcx, [rsp+var_20] mov eax, [rsp+var_18] mov ecx, [rcx+10h] add ecx, 1 cmp eax, ecx jge short loc_4A2AF mov eax, [rsp+var_C] add eax, 0Ah mov [rsp+var_C], eax mov eax, [rsp+var_18] add eax, 1 mov [rsp+var_18], eax jmp short loc_4A284 loc_4A2AF: cmp [rsp+var_14], 0 jz short loc_4A2C1 mov eax, [rsp+var_C] add eax, 2 mov [rsp+var_C], eax loc_4A2C1: jmp short $+2 loc_4A2C3: mov eax, [rsp+var_14] add eax, 0FFFFFFFFh mov [rsp+var_14], eax jmp short loc_4A275 loc_4A2D0: movsxd rax, [rsp+var_C] retn
long long Encoder::get_num_tensors(Encoder *this) { int j; // [rsp+8h] [rbp-18h] int i; // [rsp+Ch] [rbp-14h] int v4; // [rsp+14h] [rbp-Ch] v4 = 36; for ( i = 3; i >= 0; --i ) { for ( j = 0; j < *((_DWORD *)this + 4) + 1; ++j ) v4 += 10; if ( i ) v4 += 2; } return v4; }
get_num_tensors: MOV qword ptr [RSP + -0x8],RDI MOV RAX,qword ptr [RSP + -0x8] MOV qword ptr [RSP + -0x20],RAX MOV dword ptr [RSP + -0xc],0x6 MOV EAX,dword ptr [RSP + -0xc] ADD EAX,0x1e MOV dword ptr [RSP + -0xc],EAX MOV dword ptr [RSP + -0x10],0x4 MOV EAX,dword ptr [RSP + -0x10] SUB EAX,0x1 MOV dword ptr [RSP + -0x14],EAX LAB_0014a275: CMP dword ptr [RSP + -0x14],0x0 JL 0x0014a2d0 MOV dword ptr [RSP + -0x18],0x0 LAB_0014a284: MOV RCX,qword ptr [RSP + -0x20] MOV EAX,dword ptr [RSP + -0x18] MOV ECX,dword ptr [RCX + 0x10] ADD ECX,0x1 CMP EAX,ECX JGE 0x0014a2af MOV EAX,dword ptr [RSP + -0xc] ADD EAX,0xa MOV dword ptr [RSP + -0xc],EAX MOV EAX,dword ptr [RSP + -0x18] ADD EAX,0x1 MOV dword ptr [RSP + -0x18],EAX JMP 0x0014a284 LAB_0014a2af: CMP dword ptr [RSP + -0x14],0x0 JZ 0x0014a2c1 MOV EAX,dword ptr [RSP + -0xc] ADD EAX,0x2 MOV dword ptr [RSP + -0xc],EAX LAB_0014a2c1: JMP 0x0014a2c3 LAB_0014a2c3: MOV EAX,dword ptr [RSP + -0x14] ADD EAX,-0x1 MOV dword ptr [RSP + -0x14],EAX JMP 0x0014a275 LAB_0014a2d0: MOVSXD RAX,dword ptr [RSP + -0xc] RET
/* Encoder::get_num_tensors() */ long __thiscall Encoder::get_num_tensors(Encoder *this) { int local_18; int local_14; int local_c; local_c = 0x24; for (local_14 = 3; -1 < local_14; local_14 = local_14 + -1) { for (local_18 = 0; local_18 < *(int *)(this + 0x10) + 1; local_18 = local_18 + 1) { local_c = local_c + 10; } if (local_14 != 0) { local_c = local_c + 2; } } return (long)local_c; }
60,862
Encoder::get_num_tensors()
7CodeWizard[P]stablediffusion/vae.hpp
size_t get_num_tensors() { int num_tensors = 6; // mid num_tensors += 10 * 3; int len_mults = sizeof(ch_mult) / sizeof(int); for (int i = len_mults - 1; i >= 0; i--) { for (int j = 0; j < num_res_blocks + 1; j++) { num_tensors += 10; } if (i != 0) { num_tensors += 2; } } return num_tensors; }
O2
cpp
Encoder::get_num_tensors(): movl 0x10(%rdi), %eax testl %eax, %eax pushq $-0x1 popq %rcx cmovnsl %eax, %ecx imull $0xa, %ecx, %eax addl $0xa, %eax pushq $0x3 popq %rdx pushq $0x24 popq %rcx testl %edx, %edx js 0x24222 leal (%rax,%rcx), %esi subl $0x1, %edx leal 0x2(%rax,%rcx), %ecx cmovbl %esi, %ecx jmp 0x2420f movslq %ecx, %rax retq
_ZN7Encoder15get_num_tensorsEv: mov eax, [rdi+10h] test eax, eax push 0FFFFFFFFFFFFFFFFh pop rcx cmovns ecx, eax imul eax, ecx, 0Ah add eax, 0Ah push 3 pop rdx push 24h ; '$' pop rcx loc_2420F: test edx, edx js short loc_24222 lea esi, [rax+rcx] sub edx, 1 lea ecx, [rax+rcx+2] cmovb ecx, esi jmp short loc_2420F loc_24222: movsxd rax, ecx retn
long long Encoder::get_num_tensors(Encoder *this) { int v1; // ecx int v2; // eax int v3; // edx int v4; // ecx int v5; // esi bool v6; // cf v1 = -1; if ( *((int *)this + 4) >= 0 ) v1 = *((_DWORD *)this + 4); v2 = 10 * v1 + 10; v3 = 3; v4 = 36; while ( v3 >= 0 ) { v5 = v2 + v4; v6 = v3-- == 0; v4 += v2 + 2; if ( v6 ) v4 = v5; } return v4; }
get_num_tensors: MOV EAX,dword ptr [RDI + 0x10] TEST EAX,EAX PUSH -0x1 POP RCX CMOVNS ECX,EAX IMUL EAX,ECX,0xa ADD EAX,0xa PUSH 0x3 POP RDX PUSH 0x24 POP RCX LAB_0012420f: TEST EDX,EDX JS 0x00124222 LEA ESI,[RAX + RCX*0x1] SUB EDX,0x1 LEA ECX,[RAX + RCX*0x1 + 0x2] CMOVC ECX,ESI JMP 0x0012420f LAB_00124222: MOVSXD RAX,ECX RET
/* Encoder::get_num_tensors() */ long __thiscall Encoder::get_num_tensors(Encoder *this) { int iVar1; int iVar2; int iVar3; int iVar4; bool bVar5; iVar2 = -1; if (-1 < *(int *)(this + 0x10)) { iVar2 = *(int *)(this + 0x10); } iVar4 = 3; iVar3 = 0x24; while (-1 < iVar4) { bVar5 = iVar4 == 0; iVar4 = iVar4 + -1; iVar1 = iVar2 * 10 + 0xc; if (bVar5) { iVar1 = iVar2 * 10 + 10; } iVar3 = iVar1 + iVar3; } return (long)iVar3; }
60,863
HeapPrintStatus
seiftnesse[P]memoryallocator/src/custom_alloc_debug.c
void HeapPrintStatus() { if (!heap_initialized) { HEAP_LOG("Heap not initialized\n"); return; } #ifdef CUSTOM_ALLOC_ENABLE_LOGGING if (heap_log_function) { heap_log_function("=== Memory Allocator Status ===\n"); heap_log_function("Total allocated: %zu bytes\n", allocation_stats.total_allocated); heap_log_function("Total freed: %zu bytes\n", allocation_stats.total_freed); heap_log_function("Active allocations: %zu\n", allocation_stats.allocation_count); heap_log_function("Peak memory usage: %zu bytes\n", allocation_stats.peak_allocation); heap_log_function("Small pool usage: %zu/%zu bytes\n", allocation_stats.small_pool_used, SMALL_POOL_SIZE); heap_log_function("Fragmentation: %.2f%%\n", HeapGetFragmentation() * 100.0f); // Add zero-on-free configuration to status report const char* depth_str; switch (zero_on_free_depth) { case ZERO_DEPTH_NONE: depth_str = "none (best performance)"; break; case ZERO_DEPTH_SHALLOW: depth_str = "shallow (headers/pointers only)"; break; case ZERO_DEPTH_MEDIUM: depth_str = "medium (50% of memory)"; break; case ZERO_DEPTH_DEEP: depth_str = "deep (entire memory block)"; break; default: depth_str = "unknown"; } heap_log_function("Zero-on-free depth: %s\n", depth_str); if (zero_on_free_depth == ZERO_DEPTH_SHALLOW) { heap_log_function("Shallow zero size: %zu bytes\n", shallow_zero_size); } if (track_allocations) { heap_log_function("\n=== Active Allocations ===\n"); segment_t *s = segments; while (s) { if (!s->is_free) { if (s->allocation_file) { heap_log_function("ID: %u, Size: %d blocks, Location: %s:%d\n", s->allocation_id, s->size, s->allocation_file, s->allocation_line); } else { heap_log_function("ID: %u, Size: %d blocks, Location: unknown\n", s->allocation_id, s->size); } } s = s->next; } } heap_log_function("==============================\n"); } #endif }
O1
c
HeapPrintStatus: retq
HeapPrintStatus: retn
void HeapPrintStatus() { ; }
HeapPrintStatus: RET
void HeapPrintStatus(void) { return; }
60,864
mz_zip_array_ensure_capacity
7CodeWizard[P]stablediffusion/thirdparty/miniz.h
static mz_bool mz_zip_array_ensure_capacity(mz_zip_archive *pZip, mz_zip_array *pArray, size_t min_new_capacity, mz_uint growing) { void *pNew_p; size_t new_capacity = min_new_capacity; MZ_ASSERT(pArray->m_element_size); if (pArray->m_capacity >= min_new_capacity) return MZ_TRUE; if (growing) { new_capacity = MZ_MAX(1, pArray->m_capacity); while (new_capacity < min_new_capacity) new_capacity *= 2; } if (NULL == (pNew_p = pZip->m_pRealloc(pZip->m_pAlloc_opaque, pArray->m_p, pArray->m_element_size, new_capacity))) return MZ_FALSE; pArray->m_p = pNew_p; pArray->m_capacity = new_capacity; return MZ_TRUE; }
O0
c
mz_zip_array_ensure_capacity: subq $0x48, %rsp movq %rdi, 0x38(%rsp) movq %rsi, 0x30(%rsp) movq %rdx, 0x28(%rsp) movl %ecx, 0x24(%rsp) movq 0x28(%rsp), %rax movq %rax, 0x10(%rsp) movq 0x30(%rsp), %rax movq 0x10(%rax), %rax cmpq 0x28(%rsp), %rax jb 0x118bfe movl $0x1, 0x44(%rsp) jmp 0x118cbd cmpl $0x0, 0x24(%rsp) je 0x118c56 movq 0x30(%rsp), %rcx movl $0x1, %eax cmpq 0x10(%rcx), %rax jbe 0x118c21 movl $0x1, %eax movq %rax, 0x8(%rsp) jmp 0x118c2f movq 0x30(%rsp), %rax movq 0x10(%rax), %rax movq %rax, 0x8(%rsp) movq 0x8(%rsp), %rax movq %rax, 0x10(%rsp) movq 0x10(%rsp), %rax cmpq 0x28(%rsp), %rax jae 0x118c54 movq 0x10(%rsp), %rax shlq %rax movq %rax, 0x10(%rsp) jmp 0x118c39 jmp 0x118c56 movq 0x38(%rsp), %rax movq 0x38(%rax), %rax movq 0x38(%rsp), %rcx movq 0x40(%rcx), %rdi movq 0x30(%rsp), %rcx movq (%rcx), %rsi movq 0x30(%rsp), %rcx movl 0x18(%rcx), %ecx movl %ecx, %edx movq 0x10(%rsp), %rcx callq *%rax movq %rax, %rcx movq %rcx, 0x18(%rsp) xorl %eax, %eax cmpq %rcx, %rax jne 0x118c9a movl $0x0, 0x44(%rsp) jmp 0x118cbd movq 0x18(%rsp), %rcx movq 0x30(%rsp), %rax movq %rcx, (%rax) movq 0x10(%rsp), %rcx movq 0x30(%rsp), %rax movq %rcx, 0x10(%rax) movl $0x1, 0x44(%rsp) movl 0x44(%rsp), %eax addq $0x48, %rsp retq nopw %cs:(%rax,%rax)
mz_zip_array_ensure_capacity: sub rsp, 48h mov [rsp+48h+var_10], rdi mov [rsp+48h+var_18], rsi mov [rsp+48h+var_20], rdx mov [rsp+48h+var_24], ecx mov rax, [rsp+48h+var_20] mov [rsp+48h+var_38], rax mov rax, [rsp+48h+var_18] mov rax, [rax+10h] cmp rax, [rsp+48h+var_20] jb short loc_118BFE mov [rsp+48h+var_4], 1 jmp loc_118CBD loc_118BFE: cmp [rsp+48h+var_24], 0 jz short loc_118C56 mov rcx, [rsp+48h+var_18] mov eax, 1 cmp rax, [rcx+10h] jbe short loc_118C21 mov eax, 1 mov [rsp+48h+var_40], rax jmp short loc_118C2F loc_118C21: mov rax, [rsp+48h+var_18] mov rax, [rax+10h] mov [rsp+48h+var_40], rax loc_118C2F: mov rax, [rsp+48h+var_40] mov [rsp+48h+var_38], rax loc_118C39: mov rax, [rsp+48h+var_38] cmp rax, [rsp+48h+var_20] jnb short loc_118C54 mov rax, [rsp+48h+var_38] shl rax, 1 mov [rsp+48h+var_38], rax jmp short loc_118C39 loc_118C54: jmp short $+2 loc_118C56: mov rax, [rsp+48h+var_10] mov rax, [rax+38h] mov rcx, [rsp+48h+var_10] mov rdi, [rcx+40h] mov rcx, [rsp+48h+var_18] mov rsi, [rcx] mov rcx, [rsp+48h+var_18] mov ecx, [rcx+18h] mov edx, ecx mov rcx, [rsp+48h+var_38] call rax mov rcx, rax mov [rsp+48h+var_30], rcx xor eax, eax cmp rax, rcx jnz short loc_118C9A mov [rsp+48h+var_4], 0 jmp short loc_118CBD loc_118C9A: mov rcx, [rsp+48h+var_30] mov rax, [rsp+48h+var_18] mov [rax], rcx mov rcx, [rsp+48h+var_38] mov rax, [rsp+48h+var_18] mov [rax+10h], rcx mov [rsp+48h+var_4], 1 loc_118CBD: mov eax, [rsp+48h+var_4] add rsp, 48h retn
long long mz_zip_array_ensure_capacity(long long a1, long long a2, unsigned long long a3, int a4) { long long v5; // [rsp+8h] [rbp-40h] unsigned long long i; // [rsp+10h] [rbp-38h] long long v7; // [rsp+18h] [rbp-30h] i = a3; if ( *(_QWORD *)(a2 + 16) < a3 ) { if ( a4 ) { if ( *(_QWORD *)(a2 + 16) ) v5 = *(_QWORD *)(a2 + 16); else v5 = 1LL; for ( i = v5; i < a3; i *= 2LL ) ; } v7 = (*(long long ( **)(_QWORD, _QWORD, _QWORD, unsigned long long))(a1 + 56))( *(_QWORD *)(a1 + 64), *(_QWORD *)a2, *(unsigned int *)(a2 + 24), i); if ( v7 ) { *(_QWORD *)a2 = v7; *(_QWORD *)(a2 + 16) = i; return 1; } else { return 0; } } else { return 1; } }
60,865
mz_zip_array_ensure_capacity
7CodeWizard[P]stablediffusion/thirdparty/miniz.h
static mz_bool mz_zip_array_ensure_capacity(mz_zip_archive *pZip, mz_zip_array *pArray, size_t min_new_capacity, mz_uint growing) { void *pNew_p; size_t new_capacity = min_new_capacity; MZ_ASSERT(pArray->m_element_size); if (pArray->m_capacity >= min_new_capacity) return MZ_TRUE; if (growing) { new_capacity = MZ_MAX(1, pArray->m_capacity); while (new_capacity < min_new_capacity) new_capacity *= 2; } if (NULL == (pNew_p = pZip->m_pRealloc(pZip->m_pAlloc_opaque, pArray->m_p, pArray->m_element_size, new_capacity))) return MZ_FALSE; pArray->m_p = pNew_p; pArray->m_capacity = new_capacity; return MZ_TRUE; }
O1
c
mz_zip_array_ensure_capacity: pushq %r15 pushq %r14 pushq %rbx movq %rsi, %r14 movq 0x10(%rsi), %rsi movl $0x1, %ebx cmpq %rdx, %rsi jae 0x8d92b movq %rdi, %rax testl %ecx, %ecx je 0x8d907 cmpq $0x1, %rsi adcq $0x0, %rsi movq %rsi, %r15 addq %rsi, %rsi cmpq %rdx, %r15 jb 0x8d8fa jmp 0x8d90a movq %rdx, %r15 movq 0x40(%rax), %rdi movq (%r14), %rsi movl 0x18(%r14), %edx movq %r15, %rcx callq *0x38(%rax) testq %rax, %rax je 0x8d929 movq %rax, (%r14) movq %r15, 0x10(%r14) jmp 0x8d92b xorl %ebx, %ebx movl %ebx, %eax popq %rbx popq %r14 popq %r15 retq
mz_zip_array_ensure_capacity: push r15 push r14 push rbx mov r14, rsi mov rsi, [rsi+10h] mov ebx, 1 cmp rsi, rdx jnb short loc_8D92B mov rax, rdi test ecx, ecx jz short loc_8D907 cmp rsi, 1 adc rsi, 0 loc_8D8FA: mov r15, rsi add rsi, rsi cmp r15, rdx jb short loc_8D8FA jmp short loc_8D90A loc_8D907: mov r15, rdx loc_8D90A: mov rdi, [rax+40h] mov rsi, [r14] mov edx, [r14+18h] mov rcx, r15 call qword ptr [rax+38h] test rax, rax jz short loc_8D929 mov [r14], rax mov [r14+10h], r15 jmp short loc_8D92B loc_8D929: xor ebx, ebx loc_8D92B: mov eax, ebx pop rbx pop r14 pop r15 retn
long long mz_zip_array_ensure_capacity(long long a1, long long a2, unsigned long long a3, int a4) { unsigned long long v5; // rsi unsigned int v6; // ebx unsigned long long v7; // rsi unsigned long long v8; // r15 long long v9; // rax v5 = *(_QWORD *)(a2 + 16); v6 = 1; if ( v5 < a3 ) { if ( a4 ) { v7 = (v5 == 0) + v5; do { v8 = v7; v7 *= 2LL; } while ( v8 < a3 ); } else { v8 = a3; } v9 = (*(long long ( **)(_QWORD, _QWORD, _QWORD, unsigned long long))(a1 + 56))( *(_QWORD *)(a1 + 64), *(_QWORD *)a2, *(unsigned int *)(a2 + 24), v8); if ( v9 ) { *(_QWORD *)a2 = v9; *(_QWORD *)(a2 + 16) = v8; } else { return 0; } } return v6; }
60,866
mz_zip_array_ensure_capacity
7CodeWizard[P]stablediffusion/thirdparty/miniz.h
static mz_bool mz_zip_array_ensure_capacity(mz_zip_archive *pZip, mz_zip_array *pArray, size_t min_new_capacity, mz_uint growing) { void *pNew_p; size_t new_capacity = min_new_capacity; MZ_ASSERT(pArray->m_element_size); if (pArray->m_capacity >= min_new_capacity) return MZ_TRUE; if (growing) { new_capacity = MZ_MAX(1, pArray->m_capacity); while (new_capacity < min_new_capacity) new_capacity *= 2; } if (NULL == (pNew_p = pZip->m_pRealloc(pZip->m_pAlloc_opaque, pArray->m_p, pArray->m_element_size, new_capacity))) return MZ_FALSE; pArray->m_p = pNew_p; pArray->m_capacity = new_capacity; return MZ_TRUE; }
O2
c
mz_zip_array_ensure_capacity: pushq %r15 pushq %r14 pushq %rbx movq %rsi, %r14 movq 0x10(%rsi), %rsi pushq $0x1 popq %rbx cmpq %rdx, %rsi jae 0x67545 movq %rdi, %rax testl %ecx, %ecx je 0x67521 cmpq $0x1, %rsi adcq $0x0, %rsi movq %rsi, %r15 addq %rsi, %rsi cmpq %rdx, %r15 jb 0x67514 jmp 0x67524 movq %rdx, %r15 movq 0x40(%rax), %rdi movq (%r14), %rsi movl 0x18(%r14), %edx movq %r15, %rcx callq *0x38(%rax) testq %rax, %rax je 0x67543 movq %rax, (%r14) movq %r15, 0x10(%r14) jmp 0x67545 xorl %ebx, %ebx movl %ebx, %eax popq %rbx popq %r14 popq %r15 retq nopl (%rax)
mz_zip_array_ensure_capacity: push r15 push r14 push rbx mov r14, rsi mov rsi, [rsi+10h] push 1 pop rbx cmp rsi, rdx jnb short loc_67545 mov rax, rdi test ecx, ecx jz short loc_67521 cmp rsi, 1 adc rsi, 0 loc_67514: mov r15, rsi add rsi, rsi cmp r15, rdx jb short loc_67514 jmp short loc_67524 loc_67521: mov r15, rdx loc_67524: mov rdi, [rax+40h] mov rsi, [r14] mov edx, [r14+18h] mov rcx, r15 call qword ptr [rax+38h] test rax, rax jz short loc_67543 mov [r14], rax mov [r14+10h], r15 jmp short loc_67545 loc_67543: xor ebx, ebx loc_67545: mov eax, ebx pop rbx pop r14 pop r15 retn
long long mz_zip_array_ensure_capacity(long long a1, long long a2, unsigned long long a3, int a4) { unsigned long long v5; // rsi unsigned int v6; // ebx unsigned long long v7; // rsi unsigned long long v8; // r15 long long v9; // rax v5 = *(_QWORD *)(a2 + 16); v6 = 1; if ( v5 < a3 ) { if ( a4 ) { v7 = (v5 == 0) + v5; do { v8 = v7; v7 *= 2LL; } while ( v8 < a3 ); } else { v8 = a3; } v9 = (*(long long ( **)(_QWORD, _QWORD, _QWORD, unsigned long long))(a1 + 56))( *(_QWORD *)(a1 + 64), *(_QWORD *)a2, *(unsigned int *)(a2 + 24), v8); if ( v9 ) { *(_QWORD *)a2 = v9; *(_QWORD *)(a2 + 16) = v8; } else { return 0; } } return v6; }
mz_zip_array_ensure_capacity: PUSH R15 PUSH R14 PUSH RBX MOV R14,RSI MOV RSI,qword ptr [RSI + 0x10] PUSH 0x1 POP RBX CMP RSI,RDX JNC 0x00167545 MOV RAX,RDI TEST ECX,ECX JZ 0x00167521 CMP RSI,0x1 ADC RSI,0x0 LAB_00167514: MOV R15,RSI ADD RSI,RSI CMP R15,RDX JC 0x00167514 JMP 0x00167524 LAB_00167521: MOV R15,RDX LAB_00167524: MOV RDI,qword ptr [RAX + 0x40] MOV RSI,qword ptr [R14] MOV EDX,dword ptr [R14 + 0x18] MOV RCX,R15 CALL qword ptr [RAX + 0x38] TEST RAX,RAX JZ 0x00167543 MOV qword ptr [R14],RAX MOV qword ptr [R14 + 0x10],R15 JMP 0x00167545 LAB_00167543: XOR EBX,EBX LAB_00167545: MOV EAX,EBX POP RBX POP R14 POP R15 RET
int8 mz_zip_array_ensure_capacity(long param_1,long *param_2,ulong param_3,int param_4) { ulong uVar1; long lVar2; int8 uVar3; ulong uVar4; uVar1 = param_2[2]; uVar3 = 1; if (uVar1 < param_3) { uVar4 = param_3; if (param_4 != 0) { uVar1 = uVar1 + (uVar1 == 0); do { uVar4 = uVar1; uVar1 = uVar4 * 2; } while (uVar4 < param_3); } lVar2 = (**(code **)(param_1 + 0x38)) (*(int8 *)(param_1 + 0x40),*param_2,(int)param_2[3],uVar4); if (lVar2 == 0) { uVar3 = 0; } else { *param_2 = lVar2; param_2[2] = uVar4; } } return uVar3; }
60,867
mz_zip_array_ensure_capacity
7CodeWizard[P]stablediffusion/thirdparty/miniz.h
static mz_bool mz_zip_array_ensure_capacity(mz_zip_archive *pZip, mz_zip_array *pArray, size_t min_new_capacity, mz_uint growing) { void *pNew_p; size_t new_capacity = min_new_capacity; MZ_ASSERT(pArray->m_element_size); if (pArray->m_capacity >= min_new_capacity) return MZ_TRUE; if (growing) { new_capacity = MZ_MAX(1, pArray->m_capacity); while (new_capacity < min_new_capacity) new_capacity *= 2; } if (NULL == (pNew_p = pZip->m_pRealloc(pZip->m_pAlloc_opaque, pArray->m_p, pArray->m_element_size, new_capacity))) return MZ_FALSE; pArray->m_p = pNew_p; pArray->m_capacity = new_capacity; return MZ_TRUE; }
O3
c
mz_zip_array_ensure_capacity: pushq %r15 pushq %r14 pushq %rbx movq %rsi, %r14 movq 0x10(%rsi), %rsi movl $0x1, %ebx cmpq %rdx, %rsi jae 0x8c657 movq %rdi, %rax testl %ecx, %ecx je 0x8c633 cmpq $0x1, %rsi adcq $0x0, %rsi movq %rsi, %r15 addq %rsi, %rsi cmpq %rdx, %r15 jb 0x8c626 jmp 0x8c636 movq %rdx, %r15 movq 0x40(%rax), %rdi movq (%r14), %rsi movl 0x18(%r14), %edx movq %r15, %rcx callq *0x38(%rax) testq %rax, %rax je 0x8c655 movq %rax, (%r14) movq %r15, 0x10(%r14) jmp 0x8c657 xorl %ebx, %ebx movl %ebx, %eax popq %rbx popq %r14 popq %r15 retq
mz_zip_array_ensure_capacity: push r15 push r14 push rbx mov r14, rsi mov rsi, [rsi+10h] mov ebx, 1 cmp rsi, rdx jnb short loc_8C657 mov rax, rdi test ecx, ecx jz short loc_8C633 cmp rsi, 1 adc rsi, 0 loc_8C626: mov r15, rsi add rsi, rsi cmp r15, rdx jb short loc_8C626 jmp short loc_8C636 loc_8C633: mov r15, rdx loc_8C636: mov rdi, [rax+40h] mov rsi, [r14] mov edx, [r14+18h] mov rcx, r15 call qword ptr [rax+38h] test rax, rax jz short loc_8C655 mov [r14], rax mov [r14+10h], r15 jmp short loc_8C657 loc_8C655: xor ebx, ebx loc_8C657: mov eax, ebx pop rbx pop r14 pop r15 retn
long long mz_zip_array_ensure_capacity(long long a1, long long a2, unsigned long long a3, int a4) { unsigned long long v5; // rsi unsigned int v6; // ebx unsigned long long v7; // rsi unsigned long long v8; // r15 long long v9; // rax v5 = *(_QWORD *)(a2 + 16); v6 = 1; if ( v5 < a3 ) { if ( a4 ) { v7 = (v5 == 0) + v5; do { v8 = v7; v7 *= 2LL; } while ( v8 < a3 ); } else { v8 = a3; } v9 = (*(long long ( **)(_QWORD, _QWORD, _QWORD, unsigned long long))(a1 + 56))( *(_QWORD *)(a1 + 64), *(_QWORD *)a2, *(unsigned int *)(a2 + 24), v8); if ( v9 ) { *(_QWORD *)a2 = v9; *(_QWORD *)(a2 + 16) = v8; } else { return 0; } } return v6; }
60,868
GetWindowHandle
csit-sgu[P]mit-game-2025_1/Libraries/raylib/src/platforms/rcore_desktop_glfw.c
void *GetWindowHandle(void) { #if defined(_WIN32) // NOTE: Returned handle is: void *HWND (windows.h) return glfwGetWin32Window(platform.handle); #endif #if defined(__linux__) // NOTE: Returned handle is: unsigned long Window (X.h) // typedef unsigned long XID; // typedef XID Window; //unsigned long id = (unsigned long)glfwGetX11Window(platform.handle); //return NULL; // TODO: Find a way to return value... cast to void *? return (void *)platform.handle; #endif #if defined(__APPLE__) // NOTE: Returned handle is: (objc_object *) return (void *)glfwGetCocoaWindow(platform.handle); #endif return NULL; }
O2
c
GetWindowHandle: movq 0xc9a87(%rip), %rax # 0x1286c8 retq
GetWindowHandle: mov rax, cs:platform_0 retn
long long GetWindowHandle() { return platform_0; }
GetWindowHandle: MOV RAX,qword ptr [0x002286c8] RET
int8 GetWindowHandle(void) { return platform_0; }
60,869
quantize_row_q4_0_impl
Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml-quants.c
static void quantize_row_q4_0_impl(const float * restrict x, block_q4_0 * restrict y, int64_t n_per_row, const float * quant_weights) { static_assert(QK4_0 == 32, "QK4_0 must be 32"); if (!quant_weights) { quantize_row_q4_0_ref(x, y, n_per_row); return; } float weight[QK4_0]; int8_t L[QK4_0]; float sum_x2 = 0; for (int j = 0; j < n_per_row; ++j) sum_x2 += x[j]*x[j]; float sigma2 = sum_x2/n_per_row; const int64_t nb = n_per_row/QK4_0; for (int ib = 0; ib < nb; ++ib) { const float * xb = x + QK4_0 * ib; const float * qw = quant_weights + QK4_0 * ib; for (int j = 0; j < QK4_0; ++j) weight[j] = qw[j] * sqrtf(sigma2 + xb[j]*xb[j]); float d = make_qx_quants(QK4_0, 8, xb, L, 1, weight); y[ib].d = GGML_FP32_TO_FP16(d); for (int j = 0; j < 16; ++j) { y[ib].qs[j] = L[j] | (L[j+16] << 4); } } }
O0
c
quantize_row_q4_0_impl: pushq %rbp movq %rsp, %rbp subq $0x100, %rsp # imm = 0x100 movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq %rdx, -0x18(%rbp) movq %rcx, -0x20(%rbp) cmpq $0x0, -0x20(%rbp) jne 0x76af8 movq -0x8(%rbp), %rdi movq -0x10(%rbp), %rsi movq -0x18(%rbp), %rdx callq 0x46b10 jmp 0x76d64 xorps %xmm0, %xmm0 movss %xmm0, -0xc4(%rbp) movl $0x0, -0xc8(%rbp) movslq -0xc8(%rbp), %rax cmpq -0x18(%rbp), %rax jge 0x76b63 movq -0x8(%rbp), %rax movslq -0xc8(%rbp), %rcx movss (%rax,%rcx,4), %xmm0 movq -0x8(%rbp), %rax movslq -0xc8(%rbp), %rcx movss (%rax,%rcx,4), %xmm2 movss -0xc4(%rbp), %xmm1 mulss %xmm2, %xmm0 addss %xmm1, %xmm0 movss %xmm0, -0xc4(%rbp) movl -0xc8(%rbp), %eax addl $0x1, %eax movl %eax, -0xc8(%rbp) jmp 0x76b0d movss -0xc4(%rbp), %xmm0 cvtsi2ssq -0x18(%rbp), %xmm1 divss %xmm1, %xmm0 movss %xmm0, -0xcc(%rbp) movq -0x18(%rbp), %rax movl $0x20, %ecx cqto idivq %rcx movq %rax, -0xd8(%rbp) movl $0x0, -0xdc(%rbp) movslq -0xdc(%rbp), %rax cmpq -0xd8(%rbp), %rax jge 0x76d64 movq -0x8(%rbp), %rax movl -0xdc(%rbp), %ecx shll $0x5, %ecx movslq %ecx, %rcx shlq $0x2, %rcx addq %rcx, %rax movq %rax, -0xe8(%rbp) movq -0x20(%rbp), %rax movl -0xdc(%rbp), %ecx shll $0x5, %ecx movslq %ecx, %rcx shlq $0x2, %rcx addq %rcx, %rax movq %rax, -0xf0(%rbp) movl $0x0, -0xf4(%rbp) cmpl $0x20, -0xf4(%rbp) jge 0x76c8c movq -0xf0(%rbp), %rax movslq -0xf4(%rbp), %rcx movss (%rax,%rcx,4), %xmm0 movss %xmm0, -0x100(%rbp) movss -0xcc(%rbp), %xmm1 movq -0xe8(%rbp), %rax movslq -0xf4(%rbp), %rcx movss (%rax,%rcx,4), %xmm0 movq -0xe8(%rbp), %rax movslq -0xf4(%rbp), %rcx movss (%rax,%rcx,4), %xmm2 mulss %xmm2, %xmm0 addss %xmm1, %xmm0 callq 0x49320 movaps %xmm0, %xmm1 movss -0x100(%rbp), %xmm0 mulss %xmm1, %xmm0 movslq -0xf4(%rbp), %rax movss %xmm0, -0xa0(%rbp,%rax,4) movl -0xf4(%rbp), %eax addl $0x1, %eax movl %eax, -0xf4(%rbp) jmp 0x76bf6 movq -0xe8(%rbp), %rdx leaq -0xc0(%rbp), %rcx leaq -0xa0(%rbp), %r9 movl $0x20, %edi movl $0x8, %esi movl $0x1, %r8d callq 0x755e0 movss %xmm0, -0xf8(%rbp) movss -0xf8(%rbp), %xmm0 callq 0x6d750 movw %ax, %cx movq -0x10(%rbp), %rax movslq -0xdc(%rbp), %rdx imulq $0x12, %rdx, %rdx addq %rdx, %rax movw %cx, (%rax) movl $0x0, -0xfc(%rbp) cmpl $0x10, -0xfc(%rbp) jge 0x76d4e movslq -0xfc(%rbp), %rax movsbl -0xc0(%rbp,%rax), %eax movl -0xfc(%rbp), %ecx addl $0x10, %ecx movslq %ecx, %rcx movsbl -0xc0(%rbp,%rcx), %ecx shll $0x4, %ecx orl %ecx, %eax movb %al, %dl movq -0x10(%rbp), %rax movslq -0xdc(%rbp), %rcx imulq $0x12, %rcx, %rcx addq %rcx, %rax movslq -0xfc(%rbp), %rcx movb %dl, 0x2(%rax,%rcx) movl -0xfc(%rbp), %eax addl $0x1, %eax movl %eax, -0xfc(%rbp) jmp 0x76ced jmp 0x76d50 movl -0xdc(%rbp), %eax addl $0x1, %eax movl %eax, -0xdc(%rbp) jmp 0x76b9c addq $0x100, %rsp # imm = 0x100 popq %rbp retq nopl (%rax)
quantize_row_q4_0_impl: push rbp mov rbp, rsp sub rsp, 100h mov [rbp+var_8], rdi mov [rbp+var_10], rsi mov [rbp+var_18], rdx mov [rbp+var_20], rcx cmp [rbp+var_20], 0 jnz short loc_76AF8 mov rdi, [rbp+var_8] mov rsi, [rbp+var_10] mov rdx, [rbp+var_18] call _quantize_row_q4_0_ref jmp loc_76D64 loc_76AF8: xorps xmm0, xmm0 movss [rbp+var_C4], xmm0 mov [rbp+var_C8], 0 loc_76B0D: movsxd rax, [rbp+var_C8] cmp rax, [rbp+var_18] jge short loc_76B63 mov rax, [rbp+var_8] movsxd rcx, [rbp+var_C8] movss xmm0, dword ptr [rax+rcx*4] mov rax, [rbp+var_8] movsxd rcx, [rbp+var_C8] movss xmm2, dword ptr [rax+rcx*4] movss xmm1, [rbp+var_C4] mulss xmm0, xmm2 addss xmm0, xmm1 movss [rbp+var_C4], xmm0 mov eax, [rbp+var_C8] add eax, 1 mov [rbp+var_C8], eax jmp short loc_76B0D loc_76B63: movss xmm0, [rbp+var_C4] cvtsi2ss xmm1, [rbp+var_18] divss xmm0, xmm1 movss [rbp+var_CC], xmm0 mov rax, [rbp+var_18] mov ecx, 20h ; ' ' cqo idiv rcx mov [rbp+var_D8], rax mov [rbp+var_DC], 0 loc_76B9C: movsxd rax, [rbp+var_DC] cmp rax, [rbp+var_D8] jge loc_76D64 mov rax, [rbp+var_8] mov ecx, [rbp+var_DC] shl ecx, 5 movsxd rcx, ecx shl rcx, 2 add rax, rcx mov [rbp+var_E8], rax mov rax, [rbp+var_20] mov ecx, [rbp+var_DC] shl ecx, 5 movsxd rcx, ecx shl rcx, 2 add rax, rcx mov [rbp+var_F0], rax mov [rbp+var_F4], 0 loc_76BF6: cmp [rbp+var_F4], 20h ; ' ' jge loc_76C8C mov rax, [rbp+var_F0] movsxd rcx, [rbp+var_F4] movss xmm0, dword ptr [rax+rcx*4] movss [rbp+var_100], xmm0 movss xmm1, [rbp+var_CC] mov rax, [rbp+var_E8] movsxd rcx, [rbp+var_F4] movss xmm0, dword ptr [rax+rcx*4] mov rax, [rbp+var_E8] movsxd rcx, [rbp+var_F4] movss xmm2, dword ptr [rax+rcx*4] mulss xmm0, xmm2 addss xmm0, xmm1 call _sqrtf movaps xmm1, xmm0 movss xmm0, [rbp+var_100] mulss xmm0, xmm1 movsxd rax, [rbp+var_F4] movss [rbp+rax*4+var_A0], xmm0 mov eax, [rbp+var_F4] add eax, 1 mov [rbp+var_F4], eax jmp loc_76BF6 loc_76C8C: mov rdx, [rbp+var_E8] lea rcx, [rbp+var_C0] lea r9, [rbp+var_A0] mov edi, 20h ; ' ' mov esi, 8 mov r8d, 1 call make_qx_quants movss [rbp+var_F8], xmm0 movss xmm0, [rbp+var_F8] call ggml_compute_fp32_to_fp16_0 mov cx, ax mov rax, [rbp+var_10] movsxd rdx, [rbp+var_DC] imul rdx, 12h add rax, rdx mov [rax], cx mov [rbp+var_FC], 0 loc_76CED: cmp [rbp+var_FC], 10h jge short loc_76D4E movsxd rax, [rbp+var_FC] movsx eax, [rbp+rax+var_C0] mov ecx, [rbp+var_FC] add ecx, 10h movsxd rcx, ecx movsx ecx, [rbp+rcx+var_C0] shl ecx, 4 or eax, ecx mov dl, al mov rax, [rbp+var_10] movsxd rcx, [rbp+var_DC] imul rcx, 12h add rax, rcx movsxd rcx, [rbp+var_FC] mov [rax+rcx+2], dl mov eax, [rbp+var_FC] add eax, 1 mov [rbp+var_FC], eax jmp short loc_76CED loc_76D4E: jmp short $+2 loc_76D50: mov eax, [rbp+var_DC] add eax, 1 mov [rbp+var_DC], eax jmp loc_76B9C loc_76D64: add rsp, 100h pop rbp retn
long long quantize_row_q4_0_impl(long long a1, long long a2, long long a3, long long a4) { long long result; // rax double v5; // xmm0_8 float qx_quants; // xmm0_4 float v7; // [rsp+0h] [rbp-100h] int m; // [rsp+4h] [rbp-FCh] int k; // [rsp+Ch] [rbp-F4h] long long v10; // [rsp+10h] [rbp-F0h] long long v11; // [rsp+18h] [rbp-E8h] int j; // [rsp+24h] [rbp-DCh] long long v13; // [rsp+28h] [rbp-D8h] float v14; // [rsp+34h] [rbp-CCh] int i; // [rsp+38h] [rbp-C8h] float v16; // [rsp+3Ch] [rbp-C4h] _BYTE v17[32]; // [rsp+40h] [rbp-C0h] BYREF float v18[32]; // [rsp+60h] [rbp-A0h] BYREF long long v19; // [rsp+E0h] [rbp-20h] long long v20; // [rsp+E8h] [rbp-18h] long long v21; // [rsp+F0h] [rbp-10h] long long v22; // [rsp+F8h] [rbp-8h] v22 = a1; v21 = a2; v20 = a3; v19 = a4; if ( !a4 ) return quantize_row_q4_0_ref(v22, v21, v20); v16 = 0.0; for ( i = 0; i < v20; ++i ) v16 = (float)(*(float *)(v22 + 4LL * i) * *(float *)(v22 + 4LL * i)) + v16; v14 = v16 / (float)(int)v20; v13 = v20 / 32; for ( j = 0; ; ++j ) { result = j; if ( j >= v13 ) break; v11 = 128LL * j + v22; v10 = 128LL * j + v19; for ( k = 0; k < 32; ++k ) { v7 = *(float *)(v10 + 4LL * k); v5 = sqrtf((float)(*(float *)(v11 + 4LL * k) * *(float *)(v11 + 4LL * k)) + v14); v18[k] = v7 * *(float *)&v5; } qx_quants = make_qx_quants(32, 8, v11, (long long)v17, 1, (long long)v18); *(_WORD *)(18LL * j + v21) = ggml_compute_fp32_to_fp16_0(qx_quants); for ( m = 0; m < 16; ++m ) *(_BYTE *)(18LL * j + v21 + m + 2) = (16 * v17[m + 16]) | v17[m]; } return result; }
quantize_row_q4_0_impl: PUSH RBP MOV RBP,RSP SUB RSP,0x100 MOV qword ptr [RBP + -0x8],RDI MOV qword ptr [RBP + -0x10],RSI MOV qword ptr [RBP + -0x18],RDX MOV qword ptr [RBP + -0x20],RCX CMP qword ptr [RBP + -0x20],0x0 JNZ 0x00176af8 MOV RDI,qword ptr [RBP + -0x8] MOV RSI,qword ptr [RBP + -0x10] MOV RDX,qword ptr [RBP + -0x18] CALL 0x00146b10 JMP 0x00176d64 LAB_00176af8: XORPS XMM0,XMM0 MOVSS dword ptr [RBP + -0xc4],XMM0 MOV dword ptr [RBP + -0xc8],0x0 LAB_00176b0d: MOVSXD RAX,dword ptr [RBP + -0xc8] CMP RAX,qword ptr [RBP + -0x18] JGE 0x00176b63 MOV RAX,qword ptr [RBP + -0x8] MOVSXD RCX,dword ptr [RBP + -0xc8] MOVSS XMM0,dword ptr [RAX + RCX*0x4] MOV RAX,qword ptr [RBP + -0x8] MOVSXD RCX,dword ptr [RBP + -0xc8] MOVSS XMM2,dword ptr [RAX + RCX*0x4] MOVSS XMM1,dword ptr [RBP + -0xc4] MULSS XMM0,XMM2 ADDSS XMM0,XMM1 MOVSS dword ptr [RBP + -0xc4],XMM0 MOV EAX,dword ptr [RBP + -0xc8] ADD EAX,0x1 MOV dword ptr [RBP + -0xc8],EAX JMP 0x00176b0d LAB_00176b63: MOVSS XMM0,dword ptr [RBP + -0xc4] CVTSI2SS XMM1,qword ptr [RBP + -0x18] DIVSS XMM0,XMM1 MOVSS dword ptr [RBP + -0xcc],XMM0 MOV RAX,qword ptr [RBP + -0x18] MOV ECX,0x20 CQO IDIV RCX MOV qword ptr [RBP + -0xd8],RAX MOV dword ptr [RBP + -0xdc],0x0 LAB_00176b9c: MOVSXD RAX,dword ptr [RBP + -0xdc] CMP RAX,qword ptr [RBP + -0xd8] JGE 0x00176d64 MOV RAX,qword ptr [RBP + -0x8] MOV ECX,dword ptr [RBP + -0xdc] SHL ECX,0x5 MOVSXD RCX,ECX SHL RCX,0x2 ADD RAX,RCX MOV qword ptr [RBP + -0xe8],RAX MOV RAX,qword ptr [RBP + -0x20] MOV ECX,dword ptr [RBP + -0xdc] SHL ECX,0x5 MOVSXD RCX,ECX SHL RCX,0x2 ADD RAX,RCX MOV qword ptr [RBP + -0xf0],RAX MOV dword ptr [RBP + -0xf4],0x0 LAB_00176bf6: CMP dword ptr [RBP + -0xf4],0x20 JGE 0x00176c8c MOV RAX,qword ptr [RBP + -0xf0] MOVSXD RCX,dword ptr [RBP + -0xf4] MOVSS XMM0,dword ptr [RAX + RCX*0x4] MOVSS dword ptr [RBP + -0x100],XMM0 MOVSS XMM1,dword ptr [RBP + -0xcc] MOV RAX,qword ptr [RBP + -0xe8] MOVSXD RCX,dword ptr [RBP + -0xf4] MOVSS XMM0,dword ptr [RAX + RCX*0x4] MOV RAX,qword ptr [RBP + -0xe8] MOVSXD RCX,dword ptr [RBP + -0xf4] MOVSS XMM2,dword ptr [RAX + RCX*0x4] MULSS XMM0,XMM2 ADDSS XMM0,XMM1 CALL 0x00149320 MOVAPS XMM1,XMM0 MOVSS XMM0,dword ptr [RBP + -0x100] MULSS XMM0,XMM1 MOVSXD RAX,dword ptr [RBP + -0xf4] MOVSS dword ptr [RBP + RAX*0x4 + -0xa0],XMM0 MOV EAX,dword ptr [RBP + -0xf4] ADD EAX,0x1 MOV dword ptr [RBP + -0xf4],EAX JMP 0x00176bf6 LAB_00176c8c: MOV RDX,qword ptr [RBP + -0xe8] LEA RCX,[RBP + -0xc0] LEA R9,[RBP + -0xa0] MOV EDI,0x20 MOV ESI,0x8 MOV R8D,0x1 CALL 0x001755e0 MOVSS dword ptr [RBP + -0xf8],XMM0 MOVSS XMM0,dword ptr [RBP + -0xf8] CALL 0x0016d750 MOV CX,AX MOV RAX,qword ptr [RBP + -0x10] MOVSXD RDX,dword ptr [RBP + -0xdc] IMUL RDX,RDX,0x12 ADD RAX,RDX MOV word ptr [RAX],CX MOV dword ptr [RBP + -0xfc],0x0 LAB_00176ced: CMP dword ptr [RBP + -0xfc],0x10 JGE 0x00176d4e MOVSXD RAX,dword ptr [RBP + -0xfc] MOVSX EAX,byte ptr [RBP + RAX*0x1 + -0xc0] MOV ECX,dword ptr [RBP + -0xfc] ADD ECX,0x10 MOVSXD RCX,ECX MOVSX ECX,byte ptr [RBP + RCX*0x1 + -0xc0] SHL ECX,0x4 OR EAX,ECX MOV DL,AL MOV RAX,qword ptr [RBP + -0x10] MOVSXD RCX,dword ptr [RBP + -0xdc] IMUL RCX,RCX,0x12 ADD RAX,RCX MOVSXD RCX,dword ptr [RBP + -0xfc] MOV byte ptr [RAX + RCX*0x1 + 0x2],DL MOV EAX,dword ptr [RBP + -0xfc] ADD EAX,0x1 MOV dword ptr [RBP + -0xfc],EAX JMP 0x00176ced LAB_00176d4e: JMP 0x00176d50 LAB_00176d50: MOV EAX,dword ptr [RBP + -0xdc] ADD EAX,0x1 MOV dword ptr [RBP + -0xdc],EAX JMP 0x00176b9c LAB_00176d64: ADD RSP,0x100 POP RBP RET
void quantize_row_q4_0_impl(long param_1,long param_2,long param_3,long param_4) { float fVar1; int2 uVar2; long lVar3; long lVar4; float fVar5; int4 uVar6; int local_104; int local_fc; int local_e4; int local_d0; float local_cc; byte local_c8 [16]; byte abStack_b8 [16]; float local_a8 [32]; long local_28; long local_20; long local_18; long local_10; local_28 = param_4; local_20 = param_3; local_18 = param_2; local_10 = param_1; if (param_4 == 0) { quantize_row_q4_0_ref(param_1,param_2,param_3); } else { local_cc = 0.0; for (local_d0 = 0; local_d0 < param_3; local_d0 = local_d0 + 1) { local_cc = *(float *)(param_1 + (long)local_d0 * 4) * *(float *)(param_1 + (long)local_d0 * 4) + local_cc; } for (local_e4 = 0; (long)local_e4 < param_3 / 0x20; local_e4 = local_e4 + 1) { lVar3 = local_10 + (long)(local_e4 << 5) * 4; lVar4 = local_28 + (long)(local_e4 << 5) * 4; for (local_fc = 0; local_fc < 0x20; local_fc = local_fc + 1) { fVar1 = *(float *)(lVar4 + (long)local_fc * 4); fVar5 = sqrtf(*(float *)(lVar3 + (long)local_fc * 4) * *(float *)(lVar3 + (long)local_fc * 4) + local_cc / (float)param_3); local_a8[local_fc] = fVar1 * fVar5; } uVar6 = make_qx_quants(0x20,8,lVar3,local_c8,1,local_a8); uVar2 = ggml_compute_fp32_to_fp16(uVar6); *(int2 *)(local_18 + (long)local_e4 * 0x12) = uVar2; for (local_104 = 0; local_104 < 0x10; local_104 = local_104 + 1) { *(byte *)(local_18 + (long)local_e4 * 0x12 + 2 + (long)local_104) = local_c8[local_104] | (byte)((int)(char)local_c8[local_104 + 0x10] << 4); } } } return; }
60,870
add_rpc_devices(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>)
monkey531[P]llama/common/arg.cpp
static void add_rpc_devices(std::string servers) { auto rpc_servers = string_split<std::string>(servers, ','); if (rpc_servers.empty()) { throw std::invalid_argument("no RPC servers specified"); } ggml_backend_reg_t rpc_reg = ggml_backend_reg_by_name("RPC"); if (!rpc_reg) { throw std::invalid_argument("failed to find RPC backend"); } typedef ggml_backend_dev_t (*ggml_backend_rpc_add_device_t)(const char * endpoint); ggml_backend_rpc_add_device_t ggml_backend_rpc_add_device_fn = (ggml_backend_rpc_add_device_t) ggml_backend_reg_get_proc_address(rpc_reg, "ggml_backend_rpc_add_device"); if (!ggml_backend_rpc_add_device_fn) { throw std::invalid_argument("failed to find RPC device add function"); } for (const auto & server : rpc_servers) { ggml_backend_dev_t dev = ggml_backend_rpc_add_device_fn(server.c_str()); if (dev) { ggml_backend_device_register(dev); } else { throw std::invalid_argument("failed to register RPC device"); } } }
O0
cpp
add_rpc_devices(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>): subq $0xa8, %rsp movq %rdi, %rsi movq %rsi, 0xa0(%rsp) leaq 0x88(%rsp), %rdi movl $0x2c, %edx callq 0x86950 leaq 0x88(%rsp), %rdi callq 0x91070 testb $0x1, %al jne 0x8a837 jmp 0x8a8ad movl $0x10, %edi callq 0x5a6b0 movq %rax, %rdi movq %rdi, %rax movq %rax, 0x38(%rsp) leaq 0x18740c(%rip), %rsi # 0x211c5f callq 0x5a310 jmp 0x8a85a movq 0x38(%rsp), %rdi movq 0x21b6b2(%rip), %rsi # 0x2a5f18 movq 0x21b6a3(%rip), %rdx # 0x2a5f10 callq 0x5ab40 jmp 0x8aaea movq 0x38(%rsp), %rdi movq %rax, %rcx movl %edx, %eax movq %rcx, 0x80(%rsp) movl %eax, 0x7c(%rsp) callq 0x5b020 jmp 0x8aad0 movq %rax, %rcx movl %edx, %eax movq %rcx, 0x80(%rsp) movl %eax, 0x7c(%rsp) jmp 0x8aad0 leaq 0x183457(%rip), %rdi # 0x20dd0b callq 0x5af80 movq %rax, 0x30(%rsp) jmp 0x8a8c0 movq 0x30(%rsp), %rax movq %rax, 0x70(%rsp) cmpq $0x0, 0x70(%rsp) jne 0x8a932 movl $0x10, %edi callq 0x5a6b0 movq %rax, %rdi movq %rdi, %rax movq %rax, 0x28(%rsp) leaq 0x18738a(%rip), %rsi # 0x211c78 callq 0x5a310 jmp 0x8a8f5 movq 0x28(%rsp), %rdi movq 0x21b617(%rip), %rsi # 0x2a5f18 movq 0x21b608(%rip), %rdx # 0x2a5f10 callq 0x5ab40 jmp 0x8aaea movq 0x28(%rsp), %rdi movq %rax, %rcx movl %edx, %eax movq %rcx, 0x80(%rsp) movl %eax, 0x7c(%rsp) callq 0x5b020 jmp 0x8aad0 movq 0x70(%rsp), %rdi leaq 0x187355(%rip), %rsi # 0x211c93 callq 0x5a410 movq %rax, 0x20(%rsp) jmp 0x8a94a movq 0x20(%rsp), %rax movq %rax, 0x68(%rsp) cmpq $0x0, 0x68(%rsp) jne 0x8a9bc movl $0x10, %edi callq 0x5a6b0 movq %rax, %rdi movq %rdi, %rax movq %rax, 0x18(%rsp) leaq 0x187337(%rip), %rsi # 0x211caf callq 0x5a310 jmp 0x8a97f movq 0x18(%rsp), %rdi movq 0x21b58d(%rip), %rsi # 0x2a5f18 movq 0x21b57e(%rip), %rdx # 0x2a5f10 callq 0x5ab40 jmp 0x8aaea movq 0x18(%rsp), %rdi movq %rax, %rcx movl %edx, %eax movq %rcx, 0x80(%rsp) movl %eax, 0x7c(%rsp) callq 0x5b020 jmp 0x8aad0 leaq 0x88(%rsp), %rax movq %rax, 0x60(%rsp) movq 0x60(%rsp), %rdi callq 0x910f0 movq %rax, 0x58(%rsp) movq 0x60(%rsp), %rdi callq 0x91120 movq %rax, 0x50(%rsp) leaq 0x58(%rsp), %rdi leaq 0x50(%rsp), %rsi callq 0x960c0 testb $0x1, %al jne 0x8a9ff jmp 0x8aabb leaq 0x58(%rsp), %rdi callq 0x96100 movq %rax, 0x48(%rsp) movq 0x68(%rsp), %rax movq %rax, 0x8(%rsp) movq 0x48(%rsp), %rdi callq 0x5a1b0 movq %rax, %rdi movq 0x8(%rsp), %rax callq *%rax movq %rax, 0x10(%rsp) jmp 0x8aa33 movq 0x10(%rsp), %rax movq %rax, 0x40(%rsp) cmpq $0x0, 0x40(%rsp) je 0x8aa53 movq 0x40(%rsp), %rdi callq 0x5b0d0 jmp 0x8aa51 jmp 0x8aaaa movl $0x10, %edi callq 0x5a6b0 movq %rax, %rdi movq %rdi, %rax movq %rax, (%rsp) leaq 0x187268(%rip), %rsi # 0x211cd6 callq 0x5a310 jmp 0x8aa75 movq (%rsp), %rdi movq 0x21b498(%rip), %rsi # 0x2a5f18 movq 0x21b489(%rip), %rdx # 0x2a5f10 callq 0x5ab40 jmp 0x8aaea movq (%rsp), %rdi movq %rax, %rcx movl %edx, %eax movq %rcx, 0x80(%rsp) movl %eax, 0x7c(%rsp) callq 0x5b020 jmp 0x8aad0 jmp 0x8aaac leaq 0x58(%rsp), %rdi callq 0x96110 jmp 0x8a9e7 leaq 0x88(%rsp), %rdi callq 0x65630 addq $0xa8, %rsp retq leaq 0x88(%rsp), %rdi callq 0x65630 movq 0x80(%rsp), %rdi callq 0x5ac00 nopw (%rax,%rax)
_ZL15add_rpc_devicesNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE: sub rsp, 0A8h mov rsi, rdi mov [rsp+0A8h+var_8], rsi lea rdi, [rsp+0A8h+var_20] mov edx, 2Ch ; ',' call _ZL12string_splitINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEESt6vectorIT_SaIS7_EERKS5_c; string_split<std::string>(std::string const&,char) lea rdi, [rsp+0A8h+var_20] call _ZNKSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE5emptyEv; std::vector<std::string>::empty(void) test al, 1 jnz short loc_8A837 jmp short loc_8A8AD loc_8A837: mov edi, 10h; thrown_size call ___cxa_allocate_exception mov rdi, rax; this mov rax, rdi mov [rsp+0A8h+var_70], rax lea rsi, aNoRpcServersSp; "no RPC servers specified" call __ZNSt16invalid_argumentC1EPKc; std::invalid_argument::invalid_argument(char const*) jmp short $+2 loc_8A85A: mov rdi, [rsp+0A8h+var_70]; void * mov rsi, cs:lptinfo; lptinfo mov rdx, cs:_ZNSt16invalid_argumentD1Ev_ptr; void (*)(void *) call ___cxa_throw jmp loc_8AAEA mov rdi, [rsp+arg_30]; void * mov rcx, rax mov eax, edx mov [rsp+arg_78], rcx mov [rsp+arg_74], eax call ___cxa_free_exception jmp loc_8AAD0 mov rcx, rax mov eax, edx mov [rsp+arg_78], rcx mov [rsp+arg_74], eax jmp loc_8AAD0 loc_8A8AD: lea rdi, aLlamaArgRpc+0Ah; "RPC" call _ggml_backend_reg_by_name mov [rsp+0A8h+var_78], rax jmp short $+2 loc_8A8C0: mov rax, [rsp+0A8h+var_78] mov [rsp+0A8h+var_38], rax cmp [rsp+0A8h+var_38], 0 jnz short loc_8A932 mov edi, 10h; thrown_size call ___cxa_allocate_exception mov rdi, rax; this mov rax, rdi mov [rsp+0A8h+var_80], rax lea rsi, aFailedToFindRp; "failed to find RPC backend" call __ZNSt16invalid_argumentC1EPKc; std::invalid_argument::invalid_argument(char const*) jmp short $+2 loc_8A8F5: mov rdi, [rsp+0A8h+var_80]; void * mov rsi, cs:lptinfo; lptinfo mov rdx, cs:_ZNSt16invalid_argumentD1Ev_ptr; void (*)(void *) call ___cxa_throw jmp loc_8AAEA mov rdi, [rsp+arg_20]; void * mov rcx, rax mov eax, edx mov [rsp+arg_78], rcx mov [rsp+arg_74], eax call ___cxa_free_exception jmp loc_8AAD0 loc_8A932: mov rdi, [rsp+0A8h+var_38] lea rsi, aGgmlBackendRpc; "ggml_backend_rpc_add_device" call _ggml_backend_reg_get_proc_address mov [rsp+0A8h+var_88], rax jmp short $+2 loc_8A94A: mov rax, [rsp+0A8h+var_88] mov [rsp+0A8h+var_40], rax cmp [rsp+0A8h+var_40], 0 jnz short loc_8A9BC mov edi, 10h; thrown_size call ___cxa_allocate_exception mov rdi, rax; this mov rax, rdi mov [rsp+0A8h+var_90], rax lea rsi, aFailedToFindRp_0; "failed to find RPC device add function" call __ZNSt16invalid_argumentC1EPKc; std::invalid_argument::invalid_argument(char const*) jmp short $+2 loc_8A97F: mov rdi, [rsp+0A8h+var_90]; void * mov rsi, cs:lptinfo; lptinfo mov rdx, cs:_ZNSt16invalid_argumentD1Ev_ptr; void (*)(void *) call ___cxa_throw jmp loc_8AAEA mov rdi, [rsp+arg_10]; void * mov rcx, rax mov eax, edx mov [rsp+arg_78], rcx mov [rsp+arg_74], eax call ___cxa_free_exception jmp loc_8AAD0 loc_8A9BC: lea rax, [rsp+0A8h+var_20] mov [rsp+0A8h+var_48], rax mov rdi, [rsp+0A8h+var_48] call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE5beginEv; std::vector<std::string>::begin(void) mov [rsp+0A8h+var_50], rax mov rdi, [rsp+0A8h+var_48] call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE3endEv; std::vector<std::string>::end(void) mov [rsp+0A8h+var_58], rax loc_8A9E7: lea rdi, [rsp+0A8h+var_50] lea rsi, [rsp+0A8h+var_58] call _ZN9__gnu_cxxneIPNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt6vectorIS6_SaIS6_EEEEbRKNS_17__normal_iteratorIT_T0_EESG_; __gnu_cxx::operator!=<std::string *,std::vector<std::string>>(__gnu_cxx::__normal_iterator<std::string *,std::vector<std::string>> const&,__gnu_cxx::__normal_iterator<std::string *,std::vector<std::string>> const&) test al, 1 jnz short loc_8A9FF jmp loc_8AABB loc_8A9FF: lea rdi, [rsp+0A8h+var_50] call _ZNK9__gnu_cxx17__normal_iteratorIPNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt6vectorIS6_SaIS6_EEEdeEv; __gnu_cxx::__normal_iterator<std::string *,std::vector<std::string>>::operator*(void) mov [rsp+0A8h+var_60], rax mov rax, [rsp+0A8h+var_40] mov [rsp+0A8h+var_A0], rax mov rdi, [rsp+0A8h+var_60] call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5c_strEv; std::string::c_str(void) mov rdi, rax mov rax, [rsp+0A8h+var_A0] call rax mov [rsp+0A8h+var_98], rax jmp short $+2 loc_8AA33: mov rax, [rsp+0A8h+var_98] mov [rsp+0A8h+var_68], rax cmp [rsp+0A8h+var_68], 0 jz short loc_8AA53 mov rdi, [rsp+0A8h+var_68] call _ggml_backend_device_register jmp short $+2 loc_8AA51: jmp short loc_8AAAA loc_8AA53: mov edi, 10h; thrown_size call ___cxa_allocate_exception mov rdi, rax; this mov rax, rdi mov [rsp+0A8h+var_A8], rax lea rsi, aFailedToRegist; "failed to register RPC device" call __ZNSt16invalid_argumentC1EPKc; std::invalid_argument::invalid_argument(char const*) jmp short $+2 loc_8AA75: mov rdi, [rsp+0A8h+var_A8]; void * mov rsi, cs:lptinfo; lptinfo mov rdx, cs:_ZNSt16invalid_argumentD1Ev_ptr; void (*)(void *) call ___cxa_throw jmp short loc_8AAEA mov rdi, [rsp+0]; void * mov rcx, rax mov eax, edx mov [rsp+arg_78], rcx mov [rsp+arg_74], eax call ___cxa_free_exception jmp short loc_8AAD0 loc_8AAAA: jmp short $+2 loc_8AAAC: lea rdi, [rsp+0A8h+var_50] call _ZN9__gnu_cxx17__normal_iteratorIPNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt6vectorIS6_SaIS6_EEEppEv; __gnu_cxx::__normal_iterator<std::string *,std::vector<std::string>>::operator++(void) jmp loc_8A9E7 loc_8AABB: lea rdi, [rsp+0A8h+var_20] call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EED2Ev; std::vector<std::string>::~vector() add rsp, 0A8h retn loc_8AAD0: lea rdi, [rsp+arg_80] call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EED2Ev; std::vector<std::string>::~vector() mov rdi, [rsp+arg_78] call __Unwind_Resume loc_8AAEA: nop word ptr [rax+rax+00h]
long long add_rpc_devices(long long a1) { long long v1; // rax std::invalid_argument *v3; // [rsp+0h] [rbp-A8h] long long ( *v4)(long long); // [rsp+8h] [rbp-A0h] std::invalid_argument *v5; // [rsp+18h] [rbp-90h] std::invalid_argument *v6; // [rsp+28h] [rbp-80h] std::invalid_argument *exception; // [rsp+38h] [rbp-70h] long long v8; // [rsp+40h] [rbp-68h] long long v9; // [rsp+48h] [rbp-60h] long long v10; // [rsp+50h] [rbp-58h] BYREF _QWORD v11[2]; // [rsp+58h] [rbp-50h] BYREF long long proc_address; // [rsp+68h] [rbp-40h] long long v13; // [rsp+70h] [rbp-38h] long long v14[4]; // [rsp+88h] [rbp-20h] BYREF v14[3] = a1; string_split<std::string>((long long)v14, a1, 44); if ( (std::vector<std::string>::empty(v14) & 1) != 0 ) { exception = (std::invalid_argument *)__cxa_allocate_exception(0x10uLL); std::invalid_argument::invalid_argument(exception, "no RPC servers specified"); __cxa_throw( exception, (struct type_info *)&`typeinfo for'std::invalid_argument, (void (*)(void *))&std::invalid_argument::~invalid_argument); } v13 = ggml_backend_reg_by_name("RPC"); if ( !v13 ) { v6 = (std::invalid_argument *)__cxa_allocate_exception(0x10uLL); std::invalid_argument::invalid_argument(v6, "failed to find RPC backend"); __cxa_throw( v6, (struct type_info *)&`typeinfo for'std::invalid_argument, (void (*)(void *))&std::invalid_argument::~invalid_argument); } proc_address = ggml_backend_reg_get_proc_address(v13, "ggml_backend_rpc_add_device"); if ( !proc_address ) { v5 = (std::invalid_argument *)__cxa_allocate_exception(0x10uLL); std::invalid_argument::invalid_argument(v5, "failed to find RPC device add function"); __cxa_throw( v5, (struct type_info *)&`typeinfo for'std::invalid_argument, (void (*)(void *))&std::invalid_argument::~invalid_argument); } v11[1] = v14; v11[0] = std::vector<std::string>::begin(v14); v10 = std::vector<std::string>::end(v14); while ( (__gnu_cxx::operator!=<std::string *,std::vector<std::string>>(v11, &v10) & 1) != 0 ) { v9 = __gnu_cxx::__normal_iterator<std::string *,std::vector<std::string>>::operator*(v11); v4 = (long long ( *)(long long))proc_address; v1 = std::string::c_str(v9); v8 = v4(v1); if ( !v8 ) { v3 = (std::invalid_argument *)__cxa_allocate_exception(0x10uLL); std::invalid_argument::invalid_argument(v3, "failed to register RPC device"); __cxa_throw( v3, (struct type_info *)&`typeinfo for'std::invalid_argument, (void (*)(void *))&std::invalid_argument::~invalid_argument); } ggml_backend_device_register(v8); __gnu_cxx::__normal_iterator<std::string *,std::vector<std::string>>::operator++(v11); } return std::vector<std::string>::~vector(v14); }
add_rpc_devices: SUB RSP,0xa8 MOV RSI,RDI MOV qword ptr [RSP + 0xa0],RSI LEA RDI,[RSP + 0x88] MOV EDX,0x2c CALL 0x00186950 LEA RDI,[RSP + 0x88] CALL 0x00191070 TEST AL,0x1 JNZ 0x0018a837 JMP 0x0018a8ad LAB_0018a837: MOV EDI,0x10 CALL 0x0015a6b0 MOV RDI,RAX MOV RAX,RDI MOV qword ptr [RSP + 0x38],RAX LAB_0018a84c: LEA RSI,[0x311c5f] CALL 0x0015a310 JMP 0x0018a85a LAB_0018a85a: MOV RDI,qword ptr [RSP + 0x38] MOV RSI,qword ptr [0x003a5f18] MOV RDX,qword ptr [0x003a5f10] CALL 0x0015ab40 LAB_0018a8ad: LEA RDI,[0x30dd0b] CALL 0x0015af80 LAB_0018a8b9: MOV qword ptr [RSP + 0x30],RAX JMP 0x0018a8c0 LAB_0018a8c0: MOV RAX,qword ptr [RSP + 0x30] MOV qword ptr [RSP + 0x70],RAX CMP qword ptr [RSP + 0x70],0x0 JNZ 0x0018a932 MOV EDI,0x10 CALL 0x0015a6b0 MOV RDI,RAX MOV RAX,RDI MOV qword ptr [RSP + 0x28],RAX LAB_0018a8e7: LEA RSI,[0x311c78] CALL 0x0015a310 JMP 0x0018a8f5 LAB_0018a8f5: MOV RDI,qword ptr [RSP + 0x28] MOV RSI,qword ptr [0x003a5f18] MOV RDX,qword ptr [0x003a5f10] CALL 0x0015ab40 LAB_0018a932: MOV RDI,qword ptr [RSP + 0x70] LAB_0018a937: LEA RSI,[0x311c93] CALL 0x0015a410 LAB_0018a943: MOV qword ptr [RSP + 0x20],RAX JMP 0x0018a94a LAB_0018a94a: MOV RAX,qword ptr [RSP + 0x20] MOV qword ptr [RSP + 0x68],RAX CMP qword ptr [RSP + 0x68],0x0 JNZ 0x0018a9bc MOV EDI,0x10 CALL 0x0015a6b0 MOV RDI,RAX MOV RAX,RDI MOV qword ptr [RSP + 0x18],RAX LAB_0018a971: LEA RSI,[0x311caf] CALL 0x0015a310 JMP 0x0018a97f LAB_0018a97f: MOV RDI,qword ptr [RSP + 0x18] MOV RSI,qword ptr [0x003a5f18] MOV RDX,qword ptr [0x003a5f10] CALL 0x0015ab40 LAB_0018a9bc: LEA RAX,[RSP + 0x88] MOV qword ptr [RSP + 0x60],RAX MOV RDI,qword ptr [RSP + 0x60] CALL 0x001910f0 MOV qword ptr [RSP + 0x58],RAX MOV RDI,qword ptr [RSP + 0x60] CALL 0x00191120 MOV qword ptr [RSP + 0x50],RAX LAB_0018a9e7: LEA RDI,[RSP + 0x58] LEA RSI,[RSP + 0x50] CALL 0x001960c0 TEST AL,0x1 JNZ 0x0018a9ff JMP 0x0018aabb LAB_0018a9ff: LEA RDI,[RSP + 0x58] CALL 0x00196100 MOV qword ptr [RSP + 0x48],RAX MOV RAX,qword ptr [RSP + 0x68] MOV qword ptr [RSP + 0x8],RAX MOV RDI,qword ptr [RSP + 0x48] CALL 0x0015a1b0 MOV RDI,RAX MOV RAX,qword ptr [RSP + 0x8] LAB_0018aa2a: CALL RAX MOV qword ptr [RSP + 0x10],RAX JMP 0x0018aa33 LAB_0018aa33: MOV RAX,qword ptr [RSP + 0x10] MOV qword ptr [RSP + 0x40],RAX CMP qword ptr [RSP + 0x40],0x0 JZ 0x0018aa53 MOV RDI,qword ptr [RSP + 0x40] CALL 0x0015b0d0 LAB_0018aa4f: JMP 0x0018aa51 LAB_0018aa51: JMP 0x0018aaaa LAB_0018aa53: MOV EDI,0x10 CALL 0x0015a6b0 MOV RDI,RAX MOV RAX,RDI MOV qword ptr [RSP],RAX LAB_0018aa67: LEA RSI,[0x311cd6] CALL 0x0015a310 JMP 0x0018aa75 LAB_0018aa75: MOV RDI,qword ptr [RSP] MOV RSI,qword ptr [0x003a5f18] MOV RDX,qword ptr [0x003a5f10] CALL 0x0015ab40 LAB_0018aaaa: JMP 0x0018aaac LAB_0018aaac: LEA RDI,[RSP + 0x58] CALL 0x00196110 JMP 0x0018a9e7 LAB_0018aabb: LEA RDI,[RSP + 0x88] CALL 0x00165630 ADD RSP,0xa8 RET
/* add_rpc_devices(std::__cxx11::string) */ void add_rpc_devices(int8 param_1) { code *pcVar1; bool bVar2; ulong uVar3; invalid_argument *piVar4; int8 uVar5; long lVar6; int8 local_58; int8 local_50; vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *local_48; code *local_40; long local_38; string local_20 [24]; int8 local_8; local_8 = param_1; string_split<std::__cxx11::string>(local_20,(char)param_1); uVar3 = std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::empty ((vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *)local_20); if ((uVar3 & 1) != 0) { piVar4 = (invalid_argument *)__cxa_allocate_exception(0x10); /* try { // try from 0018a84c to 0018a857 has its CatchHandler @ 0018a877 */ std::invalid_argument::invalid_argument(piVar4,"no RPC servers specified"); /* try { // try from 0018a85a to 0018a871 has its CatchHandler @ 0018a897 */ /* WARNING: Subroutine does not return */ __cxa_throw(piVar4,PTR_typeinfo_003a5f18,PTR__invalid_argument_003a5f10); } /* try { // try from 0018a8ad to 0018a8b8 has its CatchHandler @ 0018a897 */ local_38 = ggml_backend_reg_by_name("RPC"); if (local_38 == 0) { piVar4 = (invalid_argument *)__cxa_allocate_exception(0x10); /* try { // try from 0018a8e7 to 0018a8f2 has its CatchHandler @ 0018a912 */ std::invalid_argument::invalid_argument(piVar4,"failed to find RPC backend"); /* try { // try from 0018a8f5 to 0018a90c has its CatchHandler @ 0018a897 */ /* WARNING: Subroutine does not return */ __cxa_throw(piVar4,PTR_typeinfo_003a5f18,PTR__invalid_argument_003a5f10); } /* try { // try from 0018a937 to 0018a942 has its CatchHandler @ 0018a897 */ local_40 = (code *)ggml_backend_reg_get_proc_address(local_38,"ggml_backend_rpc_add_device"); if (local_40 == (code *)0x0) { piVar4 = (invalid_argument *)__cxa_allocate_exception(0x10); /* try { // try from 0018a971 to 0018a97c has its CatchHandler @ 0018a99c */ std::invalid_argument::invalid_argument(piVar4,"failed to find RPC device add function"); /* try { // try from 0018a97f to 0018a996 has its CatchHandler @ 0018a897 */ /* WARNING: Subroutine does not return */ __cxa_throw(piVar4,PTR_typeinfo_003a5f18,PTR__invalid_argument_003a5f10); } local_48 = (vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *)local_20; local_50 = std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::begin(local_48) ; local_58 = std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::end(local_48); while( true ) { bVar2 = __gnu_cxx::operator!=((__normal_iterator *)&local_50,(__normal_iterator *)&local_58); if (!bVar2) { std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::~vector ((vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *)local_20); return; } __gnu_cxx:: __normal_iterator<std::__cxx11::string*,std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>> ::operator*((__normal_iterator<std::__cxx11::string*,std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>> *)&local_50); pcVar1 = local_40; uVar5 = std::__cxx11::string::c_str(); /* try { // try from 0018aa2a to 0018aa4e has its CatchHandler @ 0018a897 */ lVar6 = (*pcVar1)(uVar5); if (lVar6 == 0) break; ggml_backend_device_register(lVar6); __gnu_cxx:: __normal_iterator<std::__cxx11::string*,std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>> ::operator++((__normal_iterator<std::__cxx11::string*,std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>> *)&local_50); } piVar4 = (invalid_argument *)__cxa_allocate_exception(0x10); /* try { // try from 0018aa67 to 0018aa72 has its CatchHandler @ 0018aa8e */ std::invalid_argument::invalid_argument(piVar4,"failed to register RPC device"); /* try { // try from 0018aa75 to 0018aa8b has its CatchHandler @ 0018a897 */ /* WARNING: Subroutine does not return */ __cxa_throw(piVar4,PTR_typeinfo_003a5f18,PTR__invalid_argument_003a5f10); }
60,871
reset_pagecache_counters
eloqsql/storage/maria/ma_pagecache.c
int reset_pagecache_counters(const char *name __attribute__((unused)), PAGECACHE *pagecache) { DBUG_ENTER("reset_pagecache_counters"); if (!pagecache->inited) { DBUG_PRINT("info", ("Key cache %s not initialized.", name)); DBUG_RETURN(0); } DBUG_PRINT("info", ("Resetting counters for key cache %s.", name)); pagecache->global_blocks_changed= 0; /* Key_blocks_not_flushed */ pagecache->global_cache_r_requests= 0; /* Key_read_requests */ pagecache->global_cache_read= 0; /* Key_reads */ pagecache->global_cache_w_requests= 0; /* Key_write_requests */ pagecache->global_cache_write= 0; /* Key_writes */ DBUG_RETURN(0); }
O0
c
reset_pagecache_counters: pushq %rbp movq %rsp, %rbp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq -0x18(%rbp), %rax cmpb $0x0, 0x1a8(%rax) jne 0x5ccf8 jmp 0x5cceb jmp 0x5cced jmp 0x5ccef movl $0x0, -0x4(%rbp) jmp 0x5cd4e jmp 0x5ccfa jmp 0x5ccfc movq -0x18(%rbp), %rax movq $0x0, 0x168(%rax) movq -0x18(%rbp), %rax movq $0x0, 0x180(%rax) movq -0x18(%rbp), %rax movq $0x0, 0x188(%rax) movq -0x18(%rbp), %rax movq $0x0, 0x170(%rax) movq -0x18(%rbp), %rax movq $0x0, 0x178(%rax) movl $0x0, -0x4(%rbp) movl -0x4(%rbp), %eax popq %rbp retq nopw %cs:(%rax,%rax)
reset_pagecache_counters: push rbp mov rbp, rsp mov [rbp+var_10], rdi mov [rbp+var_18], rsi mov rax, [rbp+var_18] cmp byte ptr [rax+1A8h], 0 jnz short loc_5CCF8 jmp short $+2 loc_5CCEB: jmp short $+2 loc_5CCED: jmp short $+2 loc_5CCEF: mov [rbp+var_4], 0 jmp short loc_5CD4E loc_5CCF8: jmp short $+2 loc_5CCFA: jmp short $+2 loc_5CCFC: mov rax, [rbp+var_18] mov qword ptr [rax+168h], 0 mov rax, [rbp+var_18] mov qword ptr [rax+180h], 0 mov rax, [rbp+var_18] mov qword ptr [rax+188h], 0 mov rax, [rbp+var_18] mov qword ptr [rax+170h], 0 mov rax, [rbp+var_18] mov qword ptr [rax+178h], 0 mov [rbp+var_4], 0 loc_5CD4E: mov eax, [rbp+var_4] pop rbp retn
long long reset_pagecache_counters(long long a1, long long a2) { if ( *(_BYTE *)(a2 + 424) ) { *(_QWORD *)(a2 + 360) = 0LL; *(_QWORD *)(a2 + 384) = 0LL; *(_QWORD *)(a2 + 392) = 0LL; *(_QWORD *)(a2 + 368) = 0LL; *(_QWORD *)(a2 + 376) = 0LL; } return 0LL; }
reset_pagecache_counters: PUSH RBP MOV RBP,RSP MOV qword ptr [RBP + -0x10],RDI MOV qword ptr [RBP + -0x18],RSI MOV RAX,qword ptr [RBP + -0x18] CMP byte ptr [RAX + 0x1a8],0x0 JNZ 0x0015ccf8 JMP 0x0015cceb LAB_0015cceb: JMP 0x0015cced LAB_0015cced: JMP 0x0015ccef LAB_0015ccef: MOV dword ptr [RBP + -0x4],0x0 JMP 0x0015cd4e LAB_0015ccf8: JMP 0x0015ccfa LAB_0015ccfa: JMP 0x0015ccfc LAB_0015ccfc: MOV RAX,qword ptr [RBP + -0x18] MOV qword ptr [RAX + 0x168],0x0 MOV RAX,qword ptr [RBP + -0x18] MOV qword ptr [RAX + 0x180],0x0 MOV RAX,qword ptr [RBP + -0x18] MOV qword ptr [RAX + 0x188],0x0 MOV RAX,qword ptr [RBP + -0x18] MOV qword ptr [RAX + 0x170],0x0 MOV RAX,qword ptr [RBP + -0x18] MOV qword ptr [RAX + 0x178],0x0 MOV dword ptr [RBP + -0x4],0x0 LAB_0015cd4e: MOV EAX,dword ptr [RBP + -0x4] POP RBP RET
int4 reset_pagecache_counters(int8 param_1,long param_2) { if (*(char *)(param_2 + 0x1a8) != '\0') { *(int8 *)(param_2 + 0x168) = 0; *(int8 *)(param_2 + 0x180) = 0; *(int8 *)(param_2 + 0x188) = 0; *(int8 *)(param_2 + 0x170) = 0; *(int8 *)(param_2 + 0x178) = 0; } return 0; }
60,872
js_std_dump_error1
bluesky950520[P]quickjs/quickjs-libc.c
void js_std_dump_error1(JSContext *ctx, JSValue exception_val) { JSValue val; BOOL is_error; is_error = JS_IsError(ctx, exception_val); js_dump_obj(ctx, stderr, exception_val); if (is_error) { val = JS_GetPropertyStr(ctx, exception_val, "stack"); if (!JS_IsUndefined(val)) { js_dump_obj(ctx, stderr, val); } JS_FreeValue(ctx, val); } }
O3
c
js_std_dump_error1: pushq %rbp pushq %r15 pushq %r14 pushq %r12 pushq %rbx movq %rdx, %r14 movq %rsi, %r15 movq %rdi, %rbx callq 0x27c3c movl %eax, %ebp movq 0xba12c(%rip), %r12 # 0xcfff0 movq (%r12), %rsi movq %rbx, %rdi movq %r15, %rdx movq %r14, %rcx callq 0x15f2c testl %ebp, %ebp je 0x15f23 leaq 0x88a7d(%rip), %rcx # 0x9e95e movq %rbx, %rdi movq %r15, %rsi movq %r14, %rdx callq 0x2491d movq %rax, %r14 movq %rdx, %r15 cmpl $0x3, %r15d je 0x15f0d movq (%r12), %rsi movq %rbx, %rdi movq %r14, %rdx movq %r15, %rcx callq 0x15f2c movq %rbx, %rdi movq %r14, %rsi movq %r15, %rdx popq %rbx popq %r12 popq %r14 popq %r15 popq %rbp jmp 0x1e1d5 popq %rbx popq %r12 popq %r14 popq %r15 popq %rbp retq
js_std_dump_error1: push rbp push r15 push r14 push r12 push rbx mov r14, rdx mov r15, rsi mov rbx, rdi call JS_IsError mov ebp, eax mov r12, cs:stderr_ptr mov rsi, [r12] mov rdi, rbx mov rdx, r15 mov rcx, r14 call js_dump_obj test ebp, ebp jz short loc_15F23 lea rcx, aStack; "stack" mov rdi, rbx mov rsi, r15 mov rdx, r14 call JS_GetPropertyStr mov r14, rax mov r15, rdx cmp r15d, 3 jz short loc_15F0D mov rsi, [r12] mov rdi, rbx mov rdx, r14 mov rcx, r15 call js_dump_obj loc_15F0D: mov rdi, rbx mov rsi, r14 mov rdx, r15 pop rbx pop r12 pop r14 pop r15 pop rbp jmp JS_FreeValue loc_15F23: pop rbx pop r12 pop r14 pop r15 pop rbp retn
long long js_std_dump_error1(long long a1, long long a2, long long a3) { int IsError; // ebp long long result; // rax long long PropertyStr; // rax long long v7; // rdx long long v8; // r14 long long v9; // r15 IsError = JS_IsError(); result = js_dump_obj(a1, stderr, a2, a3); if ( IsError ) { PropertyStr = JS_GetPropertyStr(a1, a2, a3, "stack"); v8 = PropertyStr; v9 = v7; if ( (_DWORD)v7 != 3 ) js_dump_obj(a1, stderr, PropertyStr, v7); return JS_FreeValue(a1, v8, v9); } return result; }
js_std_dump_error1: PUSH RBP PUSH R15 PUSH R14 PUSH R12 PUSH RBX MOV R14,RDX MOV R15,RSI MOV RBX,RDI CALL 0x00127c3c MOV EBP,EAX MOV R12,qword ptr [0x001cfff0] MOV RSI,qword ptr [R12] MOV RDI,RBX MOV RDX,R15 MOV RCX,R14 CALL 0x00115f2c TEST EBP,EBP JZ 0x00115f23 LEA RCX,[0x19e95e] MOV RDI,RBX MOV RSI,R15 MOV RDX,R14 CALL 0x0012491d MOV R14,RAX MOV R15,RDX CMP R15D,0x3 JZ 0x00115f0d MOV RSI,qword ptr [R12] MOV RDI,RBX MOV RDX,R14 MOV RCX,R15 CALL 0x00115f2c LAB_00115f0d: MOV RDI,RBX MOV RSI,R14 MOV RDX,R15 POP RBX POP R12 POP R14 POP R15 POP RBP JMP 0x0011e1d5 LAB_00115f23: POP RBX POP R12 POP R14 POP R15 POP RBP RET
void js_std_dump_error1(int8 param_1,int8 param_2,int8 param_3) { int8 uVar1; int *puVar2; int iVar3; int8 extraout_RDX; iVar3 = JS_IsError(); puVar2 = PTR_stderr_001cfff0; js_dump_obj(param_1,*(int8 *)PTR_stderr_001cfff0,param_2,param_3); if (iVar3 != 0) { uVar1 = JS_GetPropertyStr(param_1,param_2,param_3,"stack"); if ((int)extraout_RDX != 3) { js_dump_obj(param_1,*(int8 *)puVar2,uVar1,extraout_RDX); } JS_FreeValue(param_1,uVar1,extraout_RDX); return; } return; }
60,873
el::Configurations::hasConfiguration(el::Level, el::ConfigurationType)
opengl-water/src/easylogging++.cc
bool Configurations::hasConfiguration(Level level, ConfigurationType configurationType) { base::threading::ScopedLock scopedLock(lock()); #if ELPP_COMPILER_INTEL // We cant specify template types here, Intel C++ throws compilation error // "error: type name is not allowed" return RegistryWithPred::get(level, configurationType) != nullptr; #else return RegistryWithPred<Configuration, Configuration::Predicate>::get(level, configurationType) != nullptr; #endif // ELPP_COMPILER_INTEL }
O3
cpp
el::Configurations::hasConfiguration(el::Level, el::ConfigurationType): pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %rbx pushq %rax movl %edx, %ebx movq %rdi, %r14 leaq -0x1c(%rbp), %r15 movl %esi, (%r15) movq (%rdi), %rax callq *0x10(%rax) movq %r14, %rdi movq %r15, %rsi movl %ebx, %edx callq 0x3399a testq %rax, %rax setne %al addq $0x8, %rsp popq %rbx popq %r14 popq %r15 popq %rbp retq
_ZN2el14Configurations16hasConfigurationENS_5LevelENS_17ConfigurationTypeE: push rbp mov rbp, rsp push r15 push r14 push rbx push rax mov ebx, edx mov r14, rdi lea r15, [rbp+var_1C] mov [r15], esi mov rax, [rdi] call qword ptr [rax+10h] mov rdi, r14 mov rsi, r15 mov edx, ebx call _ZN2el4base5utils16RegistryWithPredINS_13ConfigurationENS3_9PredicateEE3getINS_5LevelENS_17ConfigurationTypeEEEPS3_RKT_T0_; el::base::utils::RegistryWithPred<el::Configuration,el::Configuration::Predicate>::get<el::Level,el::ConfigurationType>(el::Level const&,el::ConfigurationType) test rax, rax setnz al add rsp, 8 pop rbx pop r14 pop r15 pop rbp retn
bool el::Configurations::hasConfiguration(long long a1, int a2, unsigned int a3) { _DWORD v5[7]; // [rsp+0h] [rbp-1Ch] BYREF v5[0] = a2; (*(void ( **)(long long))(*(_QWORD *)a1 + 16LL))(a1); return el::base::utils::RegistryWithPred<el::Configuration,el::Configuration::Predicate>::get<el::Level,el::ConfigurationType>( a1, v5, a3) != 0; }
hasConfiguration: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH RBX PUSH RAX MOV EBX,EDX MOV R14,RDI LEA R15,[RBP + -0x1c] MOV dword ptr [R15],ESI MOV RAX,qword ptr [RDI] CALL qword ptr [RAX + 0x10] MOV RDI,R14 MOV RSI,R15 MOV EDX,EBX CALL 0x0013399a TEST RAX,RAX SETNZ AL ADD RSP,0x8 POP RBX POP R14 POP R15 POP RBP RET
/* el::Configurations::hasConfiguration(el::Level, el::ConfigurationType) */ bool __thiscall el::Configurations::hasConfiguration(Configurations *this,int8 param_2,int4 param_3) { Configuration *pCVar1; int1 local_24 [4]; (**(code **)(*(long *)this + 0x10))(); pCVar1 = base::utils::RegistryWithPred<el::Configuration,el::Configuration::Predicate>:: get<el::Level,el::ConfigurationType> ((RegistryWithPred<el::Configuration,el::Configuration::Predicate> *)this, local_24,param_3); return pCVar1 != (Configuration *)0x0; }
60,874
minja::Value::operator<(minja::Value const&) const
llama.cpp/common/minja/minja.hpp
bool operator<(const Value & other) const { if (is_null()) throw std::runtime_error("Undefined value or reference"); if (is_number() && other.is_number()) return get<double>() < other.get<double>(); if (is_string() && other.is_string()) return get<std::string>() < other.get<std::string>(); throw std::runtime_error("Cannot compare values: " + dump() + " < " + other.dump()); }
O3
cpp
minja::Value::operator<(minja::Value const&) const: pushq %rbp pushq %r15 pushq %r14 pushq %r12 pushq %rbx subq $0xb0, %rsp movq %rsi, %r14 movq %rdi, %r15 cmpq $0x0, 0x20(%rdi) movb 0x40(%rdi), %al jne 0xc6065 cmpq $0x0, 0x10(%r15) jne 0xc6065 testb %al, %al jne 0xc6065 cmpq $0x0, 0x30(%r15) je 0xc6168 leal -0x5(%rax), %ecx cmpb $0x2, %cl ja 0xc609f movb 0x40(%r14), %al addb $-0x5, %al cmpb $0x2, %al ja 0xc619a movq %r15, %rdi callq 0xbf228 movsd %xmm0, 0x48(%rsp) movq %r14, %rdi callq 0xbf228 ucomisd 0x48(%rsp), %xmm0 seta %bl jmp 0xc6156 cmpb $0x3, %al jne 0xc619a cmpb $0x3, 0x40(%r14) jne 0xc619a leaq 0x8(%rsp), %rdi movq %r15, %rsi callq 0xbf33e leaq 0x28(%rsp), %rdi movq %r14, %rsi callq 0xbf33e movq 0x10(%rsp), %r15 movq 0x28(%rsp), %r14 movq 0x30(%rsp), %r12 cmpq %r15, %r12 movq %r15, %rdx cmovbq %r12, %rdx testq %rdx, %rdx je 0xc60fd movq 0x8(%rsp), %rdi movq %r14, %rsi callq 0x21290 movl %eax, %ebx testl %eax, %eax jne 0xc611e subq %r12, %r15 cmpq $-0x7fffffff, %r15 # imm = 0x80000001 movq $-0x80000000, %rbx # imm = 0x80000000 cmovgeq %r15, %rbx movl $0x7fffffff, %eax # imm = 0x7FFFFFFF cmpq %rax, %rbx cmovgeq %rax, %rbx leaq 0x38(%rsp), %rax cmpq %rax, %r14 je 0xc6138 movq 0x38(%rsp), %rsi incq %rsi movq %r14, %rdi callq 0x20180 shrl $0x1f, %ebx leaq 0x18(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0xc6156 movq 0x18(%rsp), %rsi incq %rsi callq 0x20180 movl %ebx, %eax addq $0xb0, %rsp popq %rbx popq %r12 popq %r14 popq %r15 popq %rbp retq movl $0x10, %edi callq 0x20650 movq %rax, %rbx leaq 0x59ea2(%rip), %rsi # 0x12001e movq %rax, %rdi callq 0x20430 movq 0x9ce35(%rip), %rsi # 0x162fc0 movq 0x9cdee(%rip), %rdx # 0x162f80 movq %rbx, %rdi callq 0x20a50 movl $0x10, %edi callq 0x20650 movq %rax, %rbx leaq 0x50(%rsp), %rdi movq %r15, %rsi movl $0xffffffff, %edx # imm = 0xFFFFFFFF xorl %ecx, %ecx callq 0xb6330 leaq 0x5a110(%rip), %rsi # 0x1202d2 leaq 0x90(%rsp), %rdi leaq 0x50(%rsp), %rdx callq 0xafbd0 leaq 0x5a10f(%rip), %rdx # 0x1202ea leaq 0x28(%rsp), %rdi leaq 0x90(%rsp), %rsi callq 0xb05bd leaq 0x70(%rsp), %rdi movq %r14, %rsi movl $0xffffffff, %edx # imm = 0xFFFFFFFF xorl %ecx, %ecx callq 0xb6330 leaq 0x8(%rsp), %rdi leaq 0x28(%rsp), %rsi leaq 0x70(%rsp), %rdx callq 0xb1399 movb $0x1, %bpl leaq 0x8(%rsp), %rsi movq %rbx, %rdi callq 0x20480 xorl %ebp, %ebp movq 0x9cd92(%rip), %rsi # 0x162fc0 movq 0x9cd4b(%rip), %rdx # 0x162f80 movq %rbx, %rdi callq 0x20a50 movq %rax, %r14 leaq 0x18(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0xc6263 movq 0x18(%rsp), %rsi incq %rsi callq 0x20180 jmp 0xc6263 movq %rax, %r14 movb $0x1, %bpl leaq 0x80(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0xc628c movq 0x80(%rsp), %rsi incq %rsi callq 0x20180 jmp 0xc628c movq %rax, %r14 movb $0x1, %bpl leaq 0x38(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0xc62af movq 0x38(%rsp), %rsi incq %rsi callq 0x20180 jmp 0xc62af movq %rax, %r14 movb $0x1, %bpl leaq 0xa0(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0xc62d0 movq 0xa0(%rsp), %rsi incq %rsi callq 0x20180 leaq 0x60(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0xc62eb movq 0x60(%rsp), %rsi incq %rsi callq 0x20180 testb %bpl, %bpl jne 0xc6337 jmp 0xc633f movq %rax, %r14 leaq 0x60(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0xc6337 movq 0x60(%rsp), %rsi incq %rsi callq 0x20180 jmp 0xc6337 movq %rax, %r14 leaq 0x18(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0xc633f movq 0x18(%rsp), %rsi incq %rsi callq 0x20180 jmp 0xc633f jmp 0xc6334 movq %rax, %r14 movq %rbx, %rdi callq 0x20f00 movq %r14, %rdi callq 0x20af0
_ZNK5minja5ValueltERKS0_: push rbp push r15 push r14 push r12 push rbx sub rsp, 0B0h mov r14, rsi mov r15, rdi cmp qword ptr [rdi+20h], 0 mov al, [rdi+40h] jnz short loc_C6065 cmp qword ptr [r15+10h], 0 jnz short loc_C6065 test al, al jnz short loc_C6065 cmp qword ptr [r15+30h], 0 jz loc_C6168 loc_C6065: lea ecx, [rax-5] cmp cl, 2 ja short loc_C609F mov al, [r14+40h] add al, 0FBh cmp al, 2 ja loc_C619A mov rdi, r15 call _ZNK5minja5Value3getIdEET_v; minja::Value::get<double>(void) movsd [rsp+0D8h+var_90], xmm0 mov rdi, r14 call _ZNK5minja5Value3getIdEET_v; minja::Value::get<double>(void) ucomisd xmm0, [rsp+0D8h+var_90] setnbe bl jmp loc_C6156 loc_C609F: cmp al, 3 jnz loc_C619A cmp byte ptr [r14+40h], 3 jnz loc_C619A lea rdi, [rsp+0D8h+var_D0] mov rsi, r15 call _ZNK5minja5Value3getINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEET_v; minja::Value::get<std::string>(void) lea rdi, [rsp+0D8h+var_B0] mov rsi, r14 call _ZNK5minja5Value3getINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEET_v; minja::Value::get<std::string>(void) mov r15, [rsp+0D8h+var_C8] mov r14, [rsp+0D8h+var_B0] mov r12, [rsp+0D8h+var_A8] cmp r12, r15 mov rdx, r15 cmovb rdx, r12 test rdx, rdx jz short loc_C60FD mov rdi, [rsp+0D8h+var_D0] mov rsi, r14 call _memcmp mov ebx, eax test eax, eax jnz short loc_C611E loc_C60FD: sub r15, r12 cmp r15, 0FFFFFFFF80000001h mov rbx, 0FFFFFFFF80000000h cmovge rbx, r15 mov eax, 7FFFFFFFh cmp rbx, rax cmovge rbx, rax loc_C611E: lea rax, [rsp+0D8h+var_A0] cmp r14, rax jz short loc_C6138 mov rsi, [rsp+0D8h+var_A0] inc rsi; unsigned __int64 mov rdi, r14; void * call __ZdlPvm; operator delete(void *,ulong) loc_C6138: shr ebx, 1Fh lea rax, [rsp+0D8h+var_C0] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_C6156 mov rsi, [rsp+0D8h+var_C0] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_C6156: mov eax, ebx add rsp, 0B0h pop rbx pop r12 pop r14 pop r15 pop rbp retn loc_C6168: mov edi, 10h; thrown_size call ___cxa_allocate_exception mov rbx, rax lea rsi, aUndefinedValue; "Undefined value or reference" mov rdi, rax; this call __ZNSt13runtime_errorC1EPKc; std::runtime_error::runtime_error(char const*) mov rsi, cs:_ZTISt13runtime_error_ptr; lptinfo mov rdx, cs:_ZNSt13runtime_errorD1Ev_ptr; void (*)(void *) mov rdi, rbx; void * call ___cxa_throw loc_C619A: mov edi, 10h; thrown_size call ___cxa_allocate_exception mov rbx, rax lea rdi, [rsp+0D8h+var_88] mov rsi, r15 mov edx, 0FFFFFFFFh xor ecx, ecx call _ZNK5minja5Value4dumpB5cxx11Eib; minja::Value::dump(int,bool) lea rsi, aCannotCompareV; "Cannot compare values: " lea rdi, [rsp+0D8h+var_48] lea rdx, [rsp+0D8h+var_88] call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_OS8_; std::operator+<char>(char const*,std::string&&) lea rdx, asc_1202EA; " < " lea rdi, [rsp+0D8h+var_B0] lea rsi, [rsp+0D8h+var_48] call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEOS8_PKS5_; std::operator+<char>(std::string&&,char const*) lea rdi, [rsp+0D8h+var_68] mov rsi, r14 mov edx, 0FFFFFFFFh xor ecx, ecx call _ZNK5minja5Value4dumpB5cxx11Eib; minja::Value::dump(int,bool) lea rdi, [rsp+0D8h+var_D0] lea rsi, [rsp+0D8h+var_B0] lea rdx, [rsp+0D8h+var_68] call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEOS8_S9_; std::operator+<char>(std::string&&,std::string&) mov bpl, 1 lea rsi, [rsp+0D8h+var_D0] mov rdi, rbx call __ZNSt13runtime_errorC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; std::runtime_error::runtime_error(std::string const&) xor ebp, ebp mov rsi, cs:_ZTISt13runtime_error_ptr; lptinfo mov rdx, cs:_ZNSt13runtime_errorD1Ev_ptr; void (*)(void *) mov rdi, rbx; void * call ___cxa_throw mov r14, rax lea rax, [rsp+0D8h+var_C0] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_C6263 mov rsi, [rsp+0D8h+var_C0] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) jmp short loc_C6263 mov r14, rax mov bpl, 1 loc_C6263: lea rax, [rsp+0D8h+var_58] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_C628C mov rsi, [rsp+0D8h+var_58] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) jmp short loc_C628C mov r14, rax mov bpl, 1 loc_C628C: lea rax, [rsp+0D8h+var_A0] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_C62AF mov rsi, [rsp+0D8h+var_A0] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) jmp short loc_C62AF mov r14, rax mov bpl, 1 loc_C62AF: lea rax, [rsp+0D8h+var_38] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_C62D0 mov rsi, [rsp+0D8h+var_38] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_C62D0: lea rax, [rsp+0D8h+var_78] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_C62EB mov rsi, [rsp+0D8h+var_78] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_C62EB: test bpl, bpl jnz short loc_C6337 jmp short loc_C633F mov r14, rax lea rax, [rsp+0D8h+var_78] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_C6337 mov rsi, [rsp+0D8h+var_78] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) jmp short loc_C6337 mov r14, rax lea rax, [rsp+0D8h+var_C0] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_C633F mov rsi, [rsp+0D8h+var_C0] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) jmp short loc_C633F jmp short $+2 loc_C6334: mov r14, rax loc_C6337: mov rdi, rbx; void * call ___cxa_free_exception loc_C633F: mov rdi, r14 call __Unwind_Resume
long long minja::Value::operator<(long long a1, long long a2) { unsigned int v2; // ebx char v3; // al unsigned long long v4; // r15 long long *v5; // r14 unsigned long long v6; // r12 unsigned long long v7; // rdx long long v8; // rbx long long v9; // r15 std::runtime_error *exception; // rbx void *v12; // rbx long long *v13; // [rsp+8h] [rbp-D0h] BYREF unsigned long long v14; // [rsp+10h] [rbp-C8h] long long v15; // [rsp+18h] [rbp-C0h] BYREF void *v16; // [rsp+28h] [rbp-B0h] BYREF unsigned long long v17; // [rsp+30h] [rbp-A8h] long long v18; // [rsp+38h] [rbp-A0h] BYREF double v19; // [rsp+48h] [rbp-90h] _BYTE v20[16]; // [rsp+50h] [rbp-88h] BYREF _QWORD v21[2]; // [rsp+70h] [rbp-68h] BYREF _QWORD v22[2]; // [rsp+90h] [rbp-48h] BYREF v3 = *(_BYTE *)(a1 + 64); if ( !*(_QWORD *)(a1 + 32) && !*(_QWORD *)(a1 + 16) && !v3 && !*(_QWORD *)(a1 + 48) ) { exception = (std::runtime_error *)__cxa_allocate_exception(0x10uLL); std::runtime_error::runtime_error(exception, "Undefined value or reference"); __cxa_throw( exception, (struct type_info *)&`typeinfo for'std::runtime_error, (void (*)(void *))&std::runtime_error::~runtime_error); } if ( (unsigned __int8)(v3 - 5) <= 2u ) { if ( (unsigned __int8)(*(_BYTE *)(a2 + 64) - 5) <= 2u ) { v19 = minja::Value::get<double>((_QWORD *)a1); LOBYTE(v2) = minja::Value::get<double>((_QWORD *)a2) > v19; return v2; } LABEL_24: v12 = __cxa_allocate_exception(0x10uLL); minja::Value::dump[abi:cxx11]((long long)v20, a1, 0xFFFFFFFF, 0); std::operator+<char>(v22, (long long)"Cannot compare values: ", (long long)v20); std::operator+<char>(&v16, (long long)v22, (long long)" < "); minja::Value::dump[abi:cxx11]((long long)v21, a2, 0xFFFFFFFF, 0); std::operator+<char>(&v13, &v16, v21); std::runtime_error::runtime_error(v12, &v13); __cxa_throw( v12, (struct type_info *)&`typeinfo for'std::runtime_error, (void (*)(void *))&std::runtime_error::~runtime_error); } if ( v3 != 3 || *(_BYTE *)(a2 + 64) != 3 ) goto LABEL_24; minja::Value::get<std::string>((long long)&v13, (_QWORD *)a1); minja::Value::get<std::string>((long long)&v16, (_QWORD *)a2); v4 = v14; v5 = (long long *)v16; v6 = v17; v7 = v14; if ( v17 < v14 ) v7 = v17; if ( !v7 || (LODWORD(v8) = memcmp(v13, v16), !(_DWORD)v8) ) { v9 = v4 - v6; v8 = 0xFFFFFFFF80000000LL; if ( v9 >= -2147483647 ) v8 = v9; if ( v8 >= 0x7FFFFFFF ) LODWORD(v8) = 0x7FFFFFFF; } if ( v5 != &v18 ) operator delete(v5, v18 + 1); v2 = (unsigned int)v8 >> 31; if ( v13 != &v15 ) operator delete(v13, v15 + 1); return v2; }
operator<: PUSH RBP PUSH R15 PUSH R14 PUSH R12 PUSH RBX SUB RSP,0xb0 MOV R14,RSI MOV R15,RDI CMP qword ptr [RDI + 0x20],0x0 MOV AL,byte ptr [RDI + 0x40] JNZ 0x001c6065 CMP qword ptr [R15 + 0x10],0x0 JNZ 0x001c6065 TEST AL,AL JNZ 0x001c6065 CMP qword ptr [R15 + 0x30],0x0 JZ 0x001c6168 LAB_001c6065: LEA ECX,[RAX + -0x5] CMP CL,0x2 JA 0x001c609f MOV AL,byte ptr [R14 + 0x40] ADD AL,0xfb CMP AL,0x2 JA 0x001c619a MOV RDI,R15 CALL 0x001bf228 MOVSD qword ptr [RSP + 0x48],XMM0 MOV RDI,R14 CALL 0x001bf228 UCOMISD XMM0,qword ptr [RSP + 0x48] SETA BL JMP 0x001c6156 LAB_001c609f: CMP AL,0x3 JNZ 0x001c619a CMP byte ptr [R14 + 0x40],0x3 JNZ 0x001c619a LEA RDI,[RSP + 0x8] MOV RSI,R15 CALL 0x001bf33e LAB_001c60bf: LEA RDI,[RSP + 0x28] MOV RSI,R14 CALL 0x001bf33e LAB_001c60cc: MOV R15,qword ptr [RSP + 0x10] MOV R14,qword ptr [RSP + 0x28] MOV R12,qword ptr [RSP + 0x30] CMP R12,R15 MOV RDX,R15 CMOVC RDX,R12 TEST RDX,RDX JZ 0x001c60fd MOV RDI,qword ptr [RSP + 0x8] MOV RSI,R14 CALL 0x00121290 MOV EBX,EAX TEST EAX,EAX JNZ 0x001c611e LAB_001c60fd: SUB R15,R12 CMP R15,-0x7fffffff MOV RBX,-0x80000000 CMOVGE RBX,R15 MOV EAX,0x7fffffff CMP RBX,RAX CMOVGE RBX,RAX LAB_001c611e: LEA RAX,[RSP + 0x38] CMP R14,RAX JZ 0x001c6138 MOV RSI,qword ptr [RSP + 0x38] INC RSI MOV RDI,R14 CALL 0x00120180 LAB_001c6138: SHR EBX,0x1f LEA RAX,[RSP + 0x18] MOV RDI,qword ptr [RAX + -0x10] CMP RDI,RAX JZ 0x001c6156 MOV RSI,qword ptr [RSP + 0x18] INC RSI CALL 0x00120180 LAB_001c6156: MOV EAX,EBX ADD RSP,0xb0 POP RBX POP R12 POP R14 POP R15 POP RBP RET LAB_001c6168: MOV EDI,0x10 CALL 0x00120650 MOV RBX,RAX LAB_001c6175: LEA RSI,[0x22001e] MOV RDI,RAX CALL 0x00120430 LAB_001c6184: MOV RSI,qword ptr [0x00262fc0] MOV RDX,qword ptr [0x00262f80] MOV RDI,RBX CALL 0x00120a50 LAB_001c619a: MOV EDI,0x10 CALL 0x00120650 MOV RBX,RAX LAB_001c61a7: LEA RDI,[RSP + 0x50] MOV RSI,R15 MOV EDX,0xffffffff XOR ECX,ECX CALL 0x001b6330 LAB_001c61bb: LEA RSI,[0x2202d2] LEA RDI,[RSP + 0x90] LEA RDX,[RSP + 0x50] CALL 0x001afbd0 LAB_001c61d4: LEA RDX,[0x2202ea] LEA RDI,[RSP + 0x28] LEA RSI,[RSP + 0x90] CALL 0x001b05bd LAB_001c61ed: LEA RDI,[RSP + 0x70] MOV RSI,R14 MOV EDX,0xffffffff XOR ECX,ECX CALL 0x001b6330 LAB_001c6201: LEA RDI,[RSP + 0x8] LEA RSI,[RSP + 0x28] LEA RDX,[RSP + 0x70] CALL 0x001b1399 MOV BPL,0x1 LAB_001c6218: LEA RSI,[RSP + 0x8] MOV RDI,RBX CALL 0x00120480 XOR EBP,EBP MOV RSI,qword ptr [0x00262fc0] MOV RDX,qword ptr [0x00262f80] MOV RDI,RBX CALL 0x00120a50
/* minja::Value::TEMPNAMEPLACEHOLDERVALUE(minja::Value const&) const */ ulong __thiscall minja::Value::operator<(Value *this,Value *param_1) { Value VVar1; uint uVar2; runtime_error *prVar3; ulong uVar4; int8 unaff_RBX; double dVar5; long *local_d0; ulong local_c8; long local_c0 [2]; long *local_b0; ulong local_a8; long local_a0 [2]; double local_90; int1 local_88 [32]; int1 local_68 [32]; char local_48 [32]; VVar1 = this[0x40]; if ((((*(long *)(this + 0x20) == 0) && (*(long *)(this + 0x10) == 0)) && (VVar1 == (Value)0x0)) && (*(long *)(this + 0x30) == 0)) { prVar3 = (runtime_error *)__cxa_allocate_exception(0x10); /* try { // try from 001c6175 to 001c6183 has its CatchHandler @ 001c6334 */ std::runtime_error::runtime_error(prVar3,"Undefined value or reference"); /* WARNING: Subroutine does not return */ __cxa_throw(prVar3,PTR_typeinfo_00262fc0,PTR__runtime_error_00262f80); } if ((byte)((char)VVar1 - 5U) < 3) { if (2 < (byte)((char)param_1[0x40] - 5U)) { LAB_001c619a: prVar3 = (runtime_error *)__cxa_allocate_exception(0x10); /* try { // try from 001c61a7 to 001c61ba has its CatchHandler @ 001c6332 */ dump_abi_cxx11_((int)local_88,SUB81(this,0)); /* try { // try from 001c61bb to 001c61d3 has its CatchHandler @ 001c62f2 */ std::operator+(local_48,(string *)"Cannot compare values: "); /* try { // try from 001c61d4 to 001c61ec has its CatchHandler @ 001c62a9 */ std::operator+((string *)&local_b0,local_48); /* try { // try from 001c61ed to 001c6200 has its CatchHandler @ 001c6286 */ dump_abi_cxx11_((int)local_68,SUB81(param_1,0)); /* try { // try from 001c6201 to 001c6214 has its CatchHandler @ 001c625d */ std::operator+((string *)&local_d0,(string *)&local_b0); /* try { // try from 001c6218 to 001c623c has its CatchHandler @ 001c623d */ std::runtime_error::runtime_error(prVar3,(string *)&local_d0); /* WARNING: Subroutine does not return */ __cxa_throw(prVar3,PTR_typeinfo_00262fc0,PTR__runtime_error_00262f80); } local_90 = get<double>(this); dVar5 = get<double>(param_1); uVar4 = CONCAT71((int7)((ulong)unaff_RBX >> 8),local_90 < dVar5); goto LAB_001c6156; } if ((VVar1 != (Value)0x3) || (param_1[0x40] != (Value)0x3)) goto LAB_001c619a; get<std::__cxx11::string>(); /* try { // try from 001c60bf to 001c60cb has its CatchHandler @ 001c6312 */ get<std::__cxx11::string>(); uVar4 = local_c8; if (local_a8 < local_c8) { uVar4 = local_a8; } if (uVar4 == 0) { LAB_001c60fd: uVar4 = 0xffffffff80000000; if (-0x80000000 < (long)(local_c8 - local_a8)) { uVar4 = local_c8 - local_a8; } if (0x7ffffffe < (long)uVar4) { uVar4 = 0; } } else { uVar2 = memcmp(local_d0,local_b0,uVar4); uVar4 = (ulong)uVar2; if (uVar2 == 0) goto LAB_001c60fd; } if (local_b0 != local_a0) { operator_delete(local_b0,local_a0[0] + 1); } uVar4 = uVar4 >> 0x1f & 1; if (local_d0 != local_c0) { operator_delete(local_d0,local_c0[0] + 1); } LAB_001c6156: return uVar4 & 0xffffffff; }
60,875
write_hook_for_undo_bulk_insert
eloqsql/storage/maria/ma_blockrec.c
my_bool write_hook_for_undo_bulk_insert(enum translog_record_type type __attribute__ ((unused)), TRN *trn, MARIA_HA *tbl_info, LSN *lsn, void *hook_arg) { /* We are going to call maria_delete_all_rows(), but without logging and syncing, as an optimization (if we crash before commit, the UNDO will empty; if we crash after commit, we have flushed and forced the files). Status still needs to be reset under log mutex, in case of a concurrent checkpoint. */ _ma_reset_status(tbl_info); return write_hook_for_undo(type, trn, tbl_info, lsn, hook_arg); }
O3
c
write_hook_for_undo_bulk_insert: pushq %rbp movq %rsp, %rbp pushq %r14 pushq %rbx movq %rcx, %r14 movq %rdx, %rdi movq %rsi, %rbx callq 0x6a285 movq (%r14), %rax movq %rax, 0x98(%rbx) movq 0xa0(%rbx), %rcx movq %rcx, %rdx shlq $0x8, %rdx je 0x5ef39 xorl %eax, %eax popq %rbx popq %r14 popq %rbp retq orq %rax, %rcx movq %rcx, 0xa0(%rbx) jmp 0x5ef32
write_hook_for_undo_bulk_insert: push rbp mov rbp, rsp push r14 push rbx mov r14, rcx mov rdi, rdx mov rbx, rsi call _ma_reset_status mov rax, [r14] mov [rbx+98h], rax mov rcx, [rbx+0A0h] mov rdx, rcx shl rdx, 8 jz short loc_5EF39 loc_5EF32: xor eax, eax pop rbx pop r14 pop rbp retn loc_5EF39: or rcx, rax mov [rbx+0A0h], rcx jmp short loc_5EF32
long long write_hook_for_undo_bulk_insert(long long a1, long long a2, long long a3, long long *a4) { long long v5; // rax ma_reset_status(a3); v5 = *a4; *(_QWORD *)(a2 + 152) = *a4; if ( !(*(_QWORD *)(a2 + 160) << 8) ) *(_QWORD *)(a2 + 160) |= v5; return 0LL; }
write_hook_for_undo_bulk_insert: PUSH RBP MOV RBP,RSP PUSH R14 PUSH RBX MOV R14,RCX MOV RDI,RDX MOV RBX,RSI CALL 0x0016a285 MOV RAX,qword ptr [R14] MOV qword ptr [RBX + 0x98],RAX MOV RCX,qword ptr [RBX + 0xa0] MOV RDX,RCX SHL RDX,0x8 JZ 0x0015ef39 LAB_0015ef32: XOR EAX,EAX POP RBX POP R14 POP RBP RET LAB_0015ef39: OR RCX,RAX MOV qword ptr [RBX + 0xa0],RCX JMP 0x0015ef32
int8 write_hook_for_undo_bulk_insert(int8 param_1,long param_2,int8 param_3,ulong *param_4) { ulong uVar1; _ma_reset_status(param_3); uVar1 = *param_4; *(ulong *)(param_2 + 0x98) = uVar1; if ((*(ulong *)(param_2 + 0xa0) & 0xffffffffffffff) == 0) { *(ulong *)(param_2 + 0xa0) = *(ulong *)(param_2 + 0xa0) | uVar1; } return 0; }
60,876
my_hash_sort_utf16_nopad
eloqsql/strings/ctype-ucs2.c
static void my_hash_sort_utf16_nopad(CHARSET_INFO *cs, const uchar *s, size_t slen, ulong *nr1, ulong *nr2) { my_wc_t wc; my_charset_conv_mb_wc mb_wc= cs->cset->mb_wc; int res; const uchar *e= s + slen; MY_UNICASE_INFO *uni_plane= cs->caseinfo; register ulong m1= *nr1, m2= *nr2; while ((s < e) && (res= mb_wc(cs, &wc, (uchar *) s, (uchar *) e)) > 0) { my_tosort_utf16(uni_plane, &wc); MY_HASH_ADD_16(m1, m2, wc); s+= res; } *nr1= m1; *nr2= m2; }
O0
c
my_hash_sort_utf16_nopad: pushq %rbp movq %rsp, %rbp subq $0x70, %rsp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq %rdx, -0x18(%rbp) movq %rcx, -0x20(%rbp) movq %r8, -0x28(%rbp) movq -0x8(%rbp), %rax movq 0xb8(%rax), %rax movq 0x28(%rax), %rax movq %rax, -0x38(%rbp) movq -0x10(%rbp), %rax addq -0x18(%rbp), %rax movq %rax, -0x48(%rbp) movq -0x8(%rbp), %rax movq 0x78(%rax), %rax movq %rax, -0x50(%rbp) movq -0x20(%rbp), %rax movq (%rax), %rax movq %rax, -0x58(%rbp) movq -0x28(%rbp), %rax movq (%rax), %rax movq %rax, -0x60(%rbp) movq -0x10(%rbp), %rcx xorl %eax, %eax cmpq -0x48(%rbp), %rcx movb %al, -0x61(%rbp) jae 0xb084e movq -0x38(%rbp), %rax movq -0x8(%rbp), %rdi movq -0x10(%rbp), %rdx movq -0x48(%rbp), %rcx leaq -0x30(%rbp), %rsi callq *%rax movl %eax, -0x3c(%rbp) cmpl $0x0, %eax setg %al movb %al, -0x61(%rbp) movb -0x61(%rbp), %al testb $0x1, %al jne 0xb085a jmp 0xb08f4 movq -0x50(%rbp), %rdi leaq -0x30(%rbp), %rsi callq 0xb0910 jmp 0xb0869 movq -0x58(%rbp), %rax andq $0x3f, %rax addq -0x60(%rbp), %rax movq -0x30(%rbp), %rcx andq $0xff, %rcx imulq %rcx, %rax movq -0x58(%rbp), %rcx shlq $0x8, %rcx addq %rcx, %rax xorq -0x58(%rbp), %rax movq %rax, -0x58(%rbp) movq -0x60(%rbp), %rax addq $0x3, %rax movq %rax, -0x60(%rbp) jmp 0xb08a5 movq -0x58(%rbp), %rax andq $0x3f, %rax addq -0x60(%rbp), %rax movq -0x30(%rbp), %rcx shrq $0x8, %rcx imulq %rcx, %rax movq -0x58(%rbp), %rcx shlq $0x8, %rcx addq %rcx, %rax xorq -0x58(%rbp), %rax movq %rax, -0x58(%rbp) movq -0x60(%rbp), %rax addq $0x3, %rax movq %rax, -0x60(%rbp) jmp 0xb08de movl -0x3c(%rbp), %ecx movq -0x10(%rbp), %rax movslq %ecx, %rcx addq %rcx, %rax movq %rax, -0x10(%rbp) jmp 0xb081d movq -0x58(%rbp), %rcx movq -0x20(%rbp), %rax movq %rcx, (%rax) movq -0x60(%rbp), %rcx movq -0x28(%rbp), %rax movq %rcx, (%rax) addq $0x70, %rsp popq %rbp retq
my_hash_sort_utf16_nopad: push rbp mov rbp, rsp sub rsp, 70h mov [rbp+var_8], rdi mov [rbp+var_10], rsi mov [rbp+var_18], rdx mov [rbp+var_20], rcx mov [rbp+var_28], r8 mov rax, [rbp+var_8] mov rax, [rax+0B8h] mov rax, [rax+28h] mov [rbp+var_38], rax mov rax, [rbp+var_10] add rax, [rbp+var_18] mov [rbp+var_48], rax mov rax, [rbp+var_8] mov rax, [rax+78h] mov [rbp+var_50], rax mov rax, [rbp+var_20] mov rax, [rax] mov [rbp+var_58], rax mov rax, [rbp+var_28] mov rax, [rax] mov [rbp+var_60], rax loc_B081D: mov rcx, [rbp+var_10] xor eax, eax cmp rcx, [rbp+var_48] mov [rbp+var_61], al jnb short loc_B084E mov rax, [rbp+var_38] mov rdi, [rbp+var_8] mov rdx, [rbp+var_10] mov rcx, [rbp+var_48] lea rsi, [rbp+var_30] call rax mov [rbp+var_3C], eax cmp eax, 0 setnle al mov [rbp+var_61], al loc_B084E: mov al, [rbp+var_61] test al, 1 jnz short loc_B085A jmp loc_B08F4 loc_B085A: mov rdi, [rbp+var_50] lea rsi, [rbp+var_30] call my_tosort_utf16 jmp short $+2 loc_B0869: mov rax, [rbp+var_58] and rax, 3Fh add rax, [rbp+var_60] mov rcx, [rbp+var_30] and rcx, 0FFh imul rax, rcx mov rcx, [rbp+var_58] shl rcx, 8 add rax, rcx xor rax, [rbp+var_58] mov [rbp+var_58], rax mov rax, [rbp+var_60] add rax, 3 mov [rbp+var_60], rax jmp short $+2 loc_B08A5: mov rax, [rbp+var_58] and rax, 3Fh add rax, [rbp+var_60] mov rcx, [rbp+var_30] shr rcx, 8 imul rax, rcx mov rcx, [rbp+var_58] shl rcx, 8 add rax, rcx xor rax, [rbp+var_58] mov [rbp+var_58], rax mov rax, [rbp+var_60] add rax, 3 mov [rbp+var_60], rax jmp short $+2 loc_B08DE: mov ecx, [rbp+var_3C] mov rax, [rbp+var_10] movsxd rcx, ecx add rax, rcx mov [rbp+var_10], rax jmp loc_B081D loc_B08F4: mov rcx, [rbp+var_58] mov rax, [rbp+var_20] mov [rax], rcx mov rcx, [rbp+var_60] mov rax, [rbp+var_28] mov [rax], rcx add rsp, 70h pop rbp retn
_QWORD * my_hash_sort_utf16_nopad( long long a1, unsigned long long a2, long long a3, unsigned long long *a4, _QWORD *a5) { _QWORD *result; // rax bool v6; // [rsp+Fh] [rbp-61h] long long v7; // [rsp+10h] [rbp-60h] long long v8; // [rsp+10h] [rbp-60h] unsigned long long v9; // [rsp+18h] [rbp-58h] long long v10; // [rsp+18h] [rbp-58h] long long v11; // [rsp+20h] [rbp-50h] unsigned long long v12; // [rsp+28h] [rbp-48h] int v13; // [rsp+34h] [rbp-3Ch] long long ( *v14)(long long, unsigned long long *, unsigned long long, unsigned long long); // [rsp+38h] [rbp-38h] unsigned long long v15; // [rsp+40h] [rbp-30h] BYREF _QWORD *v16; // [rsp+48h] [rbp-28h] unsigned long long *v17; // [rsp+50h] [rbp-20h] long long v18; // [rsp+58h] [rbp-18h] unsigned long long v19; // [rsp+60h] [rbp-10h] long long v20; // [rsp+68h] [rbp-8h] v20 = a1; v19 = a2; v18 = a3; v17 = a4; v16 = a5; v14 = *(long long ( **)(long long, unsigned long long *, unsigned long long, unsigned long long))(*(_QWORD *)(a1 + 184) + 40LL); v12 = a3 + a2; v11 = *(_QWORD *)(a1 + 120); v9 = *a4; v7 = *a5; while ( 1 ) { v6 = 0; if ( v19 < v12 ) { v13 = v14(v20, &v15, v19, v12); v6 = v13 > 0; } if ( !v6 ) break; my_tosort_utf16(v11, &v15); v10 = v9 ^ ((v9 << 8) + (unsigned __int8)v15 * (v7 + (v9 & 0x3F))); v8 = v7 + 3; v9 = v10 ^ ((v10 << 8) + (v15 >> 8) * (v8 + (v10 & 0x3F))); v7 = v8 + 3; v19 += v13; } *v17 = v9; result = v16; *v16 = v7; return result; }
my_hash_sort_utf16_nopad: PUSH RBP MOV RBP,RSP SUB RSP,0x70 MOV qword ptr [RBP + -0x8],RDI MOV qword ptr [RBP + -0x10],RSI MOV qword ptr [RBP + -0x18],RDX MOV qword ptr [RBP + -0x20],RCX MOV qword ptr [RBP + -0x28],R8 MOV RAX,qword ptr [RBP + -0x8] MOV RAX,qword ptr [RAX + 0xb8] MOV RAX,qword ptr [RAX + 0x28] MOV qword ptr [RBP + -0x38],RAX MOV RAX,qword ptr [RBP + -0x10] ADD RAX,qword ptr [RBP + -0x18] MOV qword ptr [RBP + -0x48],RAX MOV RAX,qword ptr [RBP + -0x8] MOV RAX,qword ptr [RAX + 0x78] MOV qword ptr [RBP + -0x50],RAX MOV RAX,qword ptr [RBP + -0x20] MOV RAX,qword ptr [RAX] MOV qword ptr [RBP + -0x58],RAX MOV RAX,qword ptr [RBP + -0x28] MOV RAX,qword ptr [RAX] MOV qword ptr [RBP + -0x60],RAX LAB_001b081d: MOV RCX,qword ptr [RBP + -0x10] XOR EAX,EAX CMP RCX,qword ptr [RBP + -0x48] MOV byte ptr [RBP + -0x61],AL JNC 0x001b084e MOV RAX,qword ptr [RBP + -0x38] MOV RDI,qword ptr [RBP + -0x8] MOV RDX,qword ptr [RBP + -0x10] MOV RCX,qword ptr [RBP + -0x48] LEA RSI,[RBP + -0x30] CALL RAX MOV dword ptr [RBP + -0x3c],EAX CMP EAX,0x0 SETG AL MOV byte ptr [RBP + -0x61],AL LAB_001b084e: MOV AL,byte ptr [RBP + -0x61] TEST AL,0x1 JNZ 0x001b085a JMP 0x001b08f4 LAB_001b085a: MOV RDI,qword ptr [RBP + -0x50] LEA RSI,[RBP + -0x30] CALL 0x001b0910 JMP 0x001b0869 LAB_001b0869: MOV RAX,qword ptr [RBP + -0x58] AND RAX,0x3f ADD RAX,qword ptr [RBP + -0x60] MOV RCX,qword ptr [RBP + -0x30] AND RCX,0xff IMUL RAX,RCX MOV RCX,qword ptr [RBP + -0x58] SHL RCX,0x8 ADD RAX,RCX XOR RAX,qword ptr [RBP + -0x58] MOV qword ptr [RBP + -0x58],RAX MOV RAX,qword ptr [RBP + -0x60] ADD RAX,0x3 MOV qword ptr [RBP + -0x60],RAX JMP 0x001b08a5 LAB_001b08a5: MOV RAX,qword ptr [RBP + -0x58] AND RAX,0x3f ADD RAX,qword ptr [RBP + -0x60] MOV RCX,qword ptr [RBP + -0x30] SHR RCX,0x8 IMUL RAX,RCX MOV RCX,qword ptr [RBP + -0x58] SHL RCX,0x8 ADD RAX,RCX XOR RAX,qword ptr [RBP + -0x58] MOV qword ptr [RBP + -0x58],RAX MOV RAX,qword ptr [RBP + -0x60] ADD RAX,0x3 MOV qword ptr [RBP + -0x60],RAX JMP 0x001b08de LAB_001b08de: MOV ECX,dword ptr [RBP + -0x3c] MOV RAX,qword ptr [RBP + -0x10] MOVSXD RCX,ECX ADD RAX,RCX MOV qword ptr [RBP + -0x10],RAX JMP 0x001b081d LAB_001b08f4: MOV RCX,qword ptr [RBP + -0x58] MOV RAX,qword ptr [RBP + -0x20] MOV qword ptr [RAX],RCX MOV RCX,qword ptr [RBP + -0x60] MOV RAX,qword ptr [RBP + -0x28] MOV qword ptr [RAX],RCX ADD RSP,0x70 POP RBP RET
void my_hash_sort_utf16_nopad(long param_1,ulong param_2,long param_3,ulong *param_4,long *param_5) { code *pcVar1; int8 uVar2; bool bVar3; long local_68; ulong local_60; int local_44; ulong local_38; long *local_30; ulong *local_28; long local_20; ulong local_18; long local_10; pcVar1 = *(code **)(*(long *)(param_1 + 0xb8) + 0x28); uVar2 = *(int8 *)(param_1 + 0x78); local_60 = *param_4; local_68 = *param_5; local_30 = param_5; local_28 = param_4; local_20 = param_3; local_18 = param_2; local_10 = param_1; while( true ) { bVar3 = false; if (local_18 < param_2 + param_3) { local_44 = (*pcVar1)(local_10,&local_38,local_18,param_2 + param_3); bVar3 = 0 < local_44; } if (!bVar3) break; my_tosort_utf16(uVar2,&local_38); local_60 = ((local_60 & 0x3f) + local_68) * (local_38 & 0xff) + local_60 * 0x100 ^ local_60; local_60 = ((local_60 & 0x3f) + local_68 + 3) * (local_38 >> 8) + local_60 * 0x100 ^ local_60; local_68 = local_68 + 6; local_18 = local_18 + (long)local_44; } *local_28 = local_60; *local_30 = local_68; return; }
60,877
my_hash_sort_utf16_nopad
eloqsql/strings/ctype-ucs2.c
static void my_hash_sort_utf16_nopad(CHARSET_INFO *cs, const uchar *s, size_t slen, ulong *nr1, ulong *nr2) { my_wc_t wc; my_charset_conv_mb_wc mb_wc= cs->cset->mb_wc; int res; const uchar *e= s + slen; MY_UNICASE_INFO *uni_plane= cs->caseinfo; register ulong m1= *nr1, m2= *nr2; while ((s < e) && (res= mb_wc(cs, &wc, (uchar *) s, (uchar *) e)) > 0) { my_tosort_utf16(uni_plane, &wc); MY_HASH_ADD_16(m1, m2, wc); s+= res; } *nr1= m1; *nr2= m2; }
O3
c
my_hash_sort_utf16_nopad: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x28, %rsp movq %rcx, -0x40(%rbp) movq (%rcx), %rbx movq %r8, -0x48(%rbp) movq (%r8), %r14 testq %rdx, %rdx jle 0x8130d movq %rdx, %r15 movq %rsi, %r12 movq 0x78(%rdi), %rax movq %rax, -0x30(%rbp) movq 0xb8(%rdi), %rax movq 0x28(%rax), %rax movq %rax, -0x50(%rbp) addq %rsi, %r15 movq %rdi, %r13 leaq -0x38(%rbp), %rsi movq %r12, %rdx movq %r15, %rcx callq *-0x50(%rbp) testl %eax, %eax jle 0x8130d movq -0x38(%rbp), %rdx movl $0xfffd, %esi # imm = 0xFFFD movq -0x30(%rbp), %rcx cmpq (%rcx), %rdx movq %r13, %rdi ja 0x812b6 movq -0x30(%rbp), %rcx movq 0x8(%rcx), %rsi movq %rdx, %rcx shrq $0x8, %rcx movq (%rsi,%rcx,8), %rsi testq %rsi, %rsi je 0x812c2 movzbl %dl, %ecx leaq (%rcx,%rcx,2), %rcx movl 0x8(%rsi,%rcx,4), %esi movq %rsi, -0x38(%rbp) movl %esi, %ecx shrl $0x8, %ecx movq %rsi, %rdx movl %ebx, %esi andl $0x3f, %esi addq %r14, %rsi movzbl %dl, %edx imulq %rsi, %rdx movq %rbx, %rsi shlq $0x8, %rsi addq %rdx, %rsi xorq %rbx, %rsi movl %esi, %edx andl $0x3f, %edx addq %r14, %rdx addq $0x3, %rdx imulq %rcx, %rdx movq %rsi, %rbx shlq $0x8, %rbx addq %rdx, %rbx xorq %rsi, %rbx addq $0x6, %r14 movl %eax, %eax addq %rax, %r12 cmpq %r15, %r12 jb 0x81266 movq -0x40(%rbp), %rax movq %rbx, (%rax) movq -0x48(%rbp), %rax movq %r14, (%rax) addq $0x28, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
my_hash_sort_utf16_nopad: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx sub rsp, 28h mov [rbp+var_40], rcx mov rbx, [rcx] mov [rbp+var_48], r8 mov r14, [r8] test rdx, rdx jle loc_8130D mov r15, rdx mov r12, rsi mov rax, [rdi+78h] mov [rbp+var_30], rax mov rax, [rdi+0B8h] mov rax, [rax+28h] mov [rbp+var_50], rax add r15, rsi loc_81266: mov r13, rdi lea rsi, [rbp+var_38] mov rdx, r12 mov rcx, r15 call [rbp+var_50] test eax, eax jle loc_8130D mov rdx, [rbp+var_38] mov esi, 0FFFDh mov rcx, [rbp+var_30] cmp rdx, [rcx] mov rdi, r13 ja short loc_812B6 mov rcx, [rbp+var_30] mov rsi, [rcx+8] mov rcx, rdx shr rcx, 8 mov rsi, [rsi+rcx*8] test rsi, rsi jz short loc_812C2 movzx ecx, dl lea rcx, [rcx+rcx*2] mov esi, [rsi+rcx*4+8] loc_812B6: mov [rbp+var_38], rsi mov ecx, esi shr ecx, 8 mov rdx, rsi loc_812C2: mov esi, ebx and esi, 3Fh add rsi, r14 movzx edx, dl imul rdx, rsi mov rsi, rbx shl rsi, 8 add rsi, rdx xor rsi, rbx mov edx, esi and edx, 3Fh add rdx, r14 add rdx, 3 imul rdx, rcx mov rbx, rsi shl rbx, 8 add rbx, rdx xor rbx, rsi add r14, 6 mov eax, eax add r12, rax cmp r12, r15 jb loc_81266 loc_8130D: mov rax, [rbp+var_40] mov [rax], rbx mov rax, [rbp+var_48] mov [rax], r14 add rsp, 28h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
_QWORD * my_hash_sort_utf16_nopad(long long a1, unsigned long long a2, long long a3, long long *a4, _QWORD *a5) { long long v5; // rbx long long v6; // r14 unsigned long long v7; // r12 unsigned long long v8; // r15 int v9; // eax unsigned __int8 v10; // dl long long v11; // rsi unsigned long long v12; // rcx long long v13; // rsi long long v14; // rsi _QWORD *result; // rax long long ( *v16)(long long, unsigned long long *, unsigned long long, unsigned long long); // [rsp+0h] [rbp-50h] unsigned long long v19; // [rsp+18h] [rbp-38h] BYREF unsigned long long *v20; // [rsp+20h] [rbp-30h] v5 = *a4; v6 = *a5; if ( a3 > 0 ) { v7 = a2; v20 = *(unsigned long long **)(a1 + 120); v16 = *(long long ( **)(long long, unsigned long long *, unsigned long long, unsigned long long))(*(_QWORD *)(a1 + 184) + 40LL); v8 = a2 + a3; while ( 1 ) { v9 = v16(a1, &v19, v7, v8); if ( v9 <= 0 ) goto LABEL_9; v10 = v19; v11 = 65533LL; if ( v19 > *v20 ) goto LABEL_7; v12 = v19 >> 8; v13 = *(_QWORD *)(v20[1] + 8 * (v19 >> 8)); if ( v13 ) break; LABEL_8: v14 = v5 ^ ((v6 + (v5 & 0x3F)) * v10 + (v5 << 8)); v5 = v14 ^ (v12 * (v6 + (((unsigned __int8)v5 ^ (unsigned __int8)((v6 + (v5 & 0x3F)) * v10)) & 0x3F) + 3) + (v14 << 8)); v6 += 6LL; v7 += (unsigned int)v9; if ( v7 >= v8 ) goto LABEL_9; } v11 = *(unsigned int *)(v13 + 12LL * (unsigned __int8)v19 + 8); LABEL_7: v19 = v11; v12 = (unsigned int)v11 >> 8; v10 = v11; goto LABEL_8; } LABEL_9: *a4 = v5; result = a5; *a5 = v6; return result; }
my_hash_sort_utf16_nopad: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x28 MOV qword ptr [RBP + -0x40],RCX MOV RBX,qword ptr [RCX] MOV qword ptr [RBP + -0x48],R8 MOV R14,qword ptr [R8] TEST RDX,RDX JLE 0x0018130d MOV R15,RDX MOV R12,RSI MOV RAX,qword ptr [RDI + 0x78] MOV qword ptr [RBP + -0x30],RAX MOV RAX,qword ptr [RDI + 0xb8] MOV RAX,qword ptr [RAX + 0x28] MOV qword ptr [RBP + -0x50],RAX ADD R15,RSI LAB_00181266: MOV R13,RDI LEA RSI,[RBP + -0x38] MOV RDX,R12 MOV RCX,R15 CALL qword ptr [RBP + -0x50] TEST EAX,EAX JLE 0x0018130d MOV RDX,qword ptr [RBP + -0x38] MOV ESI,0xfffd MOV RCX,qword ptr [RBP + -0x30] CMP RDX,qword ptr [RCX] MOV RDI,R13 JA 0x001812b6 MOV RCX,qword ptr [RBP + -0x30] MOV RSI,qword ptr [RCX + 0x8] MOV RCX,RDX SHR RCX,0x8 MOV RSI,qword ptr [RSI + RCX*0x8] TEST RSI,RSI JZ 0x001812c2 MOVZX ECX,DL LEA RCX,[RCX + RCX*0x2] MOV ESI,dword ptr [RSI + RCX*0x4 + 0x8] LAB_001812b6: MOV qword ptr [RBP + -0x38],RSI MOV ECX,ESI SHR ECX,0x8 MOV RDX,RSI LAB_001812c2: MOV ESI,EBX AND ESI,0x3f ADD RSI,R14 MOVZX EDX,DL IMUL RDX,RSI MOV RSI,RBX SHL RSI,0x8 ADD RSI,RDX XOR RSI,RBX MOV EDX,ESI AND EDX,0x3f ADD RDX,R14 ADD RDX,0x3 IMUL RDX,RCX MOV RBX,RSI SHL RBX,0x8 ADD RBX,RDX XOR RBX,RSI ADD R14,0x6 MOV EAX,EAX ADD R12,RAX CMP R12,R15 JC 0x00181266 LAB_0018130d: MOV RAX,qword ptr [RBP + -0x40] MOV qword ptr [RAX],RBX MOV RAX,qword ptr [RBP + -0x48] MOV qword ptr [RAX],R14 ADD RSP,0x28 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
void my_hash_sort_utf16_nopad(long param_1,ulong param_2,long param_3,ulong *param_4,long *param_5) { code *pcVar1; long lVar2; uint uVar3; ulong uVar4; ulong uVar5; ulong uVar6; long lVar7; ulong uVar8; ulong local_40; ulong *local_38; uVar6 = *param_4; lVar7 = *param_5; if (0 < param_3) { local_38 = *(ulong **)(param_1 + 0x78); pcVar1 = *(code **)(*(long *)(param_1 + 0xb8) + 0x28); uVar8 = param_3 + param_2; do { uVar3 = (*pcVar1)(param_1,&local_40,param_2,uVar8); if ((int)uVar3 < 1) break; uVar5 = 0xfffd; if (*local_38 < local_40) { LAB_001812b6: uVar4 = uVar5 >> 8; local_40 = uVar5; } else { uVar4 = local_40 >> 8; lVar2 = *(long *)(local_38[1] + uVar4 * 8); if (lVar2 != 0) { uVar5 = (ulong)*(uint *)(lVar2 + 8 + (local_40 & 0xff) * 0xc); goto LAB_001812b6; } } uVar6 = uVar6 * 0x100 + (local_40 & 0xff) * ((ulong)((uint)uVar6 & 0x3f) + lVar7) ^ uVar6; uVar6 = uVar6 * 0x100 + ((ulong)((uint)uVar6 & 0x3f) + lVar7 + 3) * uVar4 ^ uVar6; lVar7 = lVar7 + 6; param_2 = param_2 + uVar3; } while (param_2 < uVar8); } *param_4 = uVar6; *param_5 = lVar7; return; }
60,878
tailoring_append2
eloqsql/strings/ctype.c
static int tailoring_append2(MY_XML_PARSER *st, const char *fmt, size_t len1, const char *attr1, size_t len2, const char *attr2) { struct my_cs_file_info *i= (struct my_cs_file_info *) st->user_data; size_t newlen= i->tailoring_length + len1 + len2 + 64; /* 64 for format */ if (MY_XML_OK == my_charset_file_tailoring_realloc(i, newlen)) { char *dst= i->tailoring + i->tailoring_length; sprintf(dst, fmt, (int) len1, attr1, (int) len2, attr2); i->tailoring_length+= strlen(dst); return MY_XML_OK; } return MY_XML_ERROR; }
O0
c
tailoring_append2: pushq %rbp movq %rsp, %rbp subq $0x50, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq %rdx, -0x20(%rbp) movq %rcx, -0x28(%rbp) movq %r8, -0x30(%rbp) movq %r9, -0x38(%rbp) movq -0x10(%rbp), %rax movq 0x140(%rax), %rax movq %rax, -0x40(%rbp) movq -0x40(%rbp), %rax movq 0x690(%rax), %rax addq -0x20(%rbp), %rax addq -0x30(%rbp), %rax addq $0x40, %rax movq %rax, -0x48(%rbp) movq -0x40(%rbp), %rdi movq -0x48(%rbp), %rsi callq 0x6da30 movl %eax, %ecx xorl %eax, %eax cmpl %ecx, %eax jne 0x6de24 movq -0x40(%rbp), %rax movq 0x688(%rax), %rax movq -0x40(%rbp), %rcx addq 0x690(%rcx), %rax movq %rax, -0x50(%rbp) movq -0x50(%rbp), %rdi movq -0x18(%rbp), %rsi movq -0x20(%rbp), %rax movl %eax, %edx movq -0x28(%rbp), %rcx movq -0x30(%rbp), %rax movl %eax, %r8d movq -0x38(%rbp), %r9 movb $0x0, %al callq 0x240b0 movq -0x50(%rbp), %rdi callq 0x24130 movq %rax, %rcx movq -0x40(%rbp), %rax addq 0x690(%rax), %rcx movq %rcx, 0x690(%rax) movl $0x0, -0x4(%rbp) jmp 0x6de2b movl $0x1, -0x4(%rbp) movl -0x4(%rbp), %eax addq $0x50, %rsp popq %rbp retq nopw %cs:(%rax,%rax)
tailoring_append2: push rbp mov rbp, rsp sub rsp, 50h mov [rbp+var_10], rdi mov [rbp+var_18], rsi mov [rbp+var_20], rdx mov [rbp+var_28], rcx mov [rbp+var_30], r8 mov [rbp+var_38], r9 mov rax, [rbp+var_10] mov rax, [rax+140h] mov [rbp+var_40], rax mov rax, [rbp+var_40] mov rax, [rax+690h] add rax, [rbp+var_20] add rax, [rbp+var_30] add rax, 40h ; '@' mov [rbp+var_48], rax mov rdi, [rbp+var_40] mov rsi, [rbp+var_48] call my_charset_file_tailoring_realloc mov ecx, eax xor eax, eax cmp eax, ecx jnz short loc_6DE24 mov rax, [rbp+var_40] mov rax, [rax+688h] mov rcx, [rbp+var_40] add rax, [rcx+690h] mov [rbp+var_50], rax mov rdi, [rbp+var_50] mov rsi, [rbp+var_18] mov rax, [rbp+var_20] mov edx, eax mov rcx, [rbp+var_28] mov rax, [rbp+var_30] mov r8d, eax mov r9, [rbp+var_38] mov al, 0 call _sprintf mov rdi, [rbp+var_50] call _strlen mov rcx, rax mov rax, [rbp+var_40] add rcx, [rax+690h] mov [rax+690h], rcx mov [rbp+var_4], 0 jmp short loc_6DE2B loc_6DE24: mov [rbp+var_4], 1 loc_6DE2B: mov eax, [rbp+var_4] add rsp, 50h pop rbp retn
long long tailoring_append2(long long a1, const char *a2, long long a3, long long a4, long long a5, long long a6) { long long v7; // [rsp+0h] [rbp-50h] _QWORD *v8; // [rsp+10h] [rbp-40h] unsigned int v10; // [rsp+20h] [rbp-30h] unsigned int v12; // [rsp+30h] [rbp-20h] v12 = a3; v10 = a5; v8 = *(_QWORD **)(a1 + 320); if ( (unsigned int)my_charset_file_tailoring_realloc(v8, a5 + a3 + v8[210] + 64) ) { return 1; } else { v7 = v8[210] + v8[209]; sprintf(v7, a2, v12, a4, v10, a6); v8[210] += strlen(v7); return 0; } }
tailoring_append2: PUSH RBP MOV RBP,RSP SUB RSP,0x50 MOV qword ptr [RBP + -0x10],RDI MOV qword ptr [RBP + -0x18],RSI MOV qword ptr [RBP + -0x20],RDX MOV qword ptr [RBP + -0x28],RCX MOV qword ptr [RBP + -0x30],R8 MOV qword ptr [RBP + -0x38],R9 MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x140] MOV qword ptr [RBP + -0x40],RAX MOV RAX,qword ptr [RBP + -0x40] MOV RAX,qword ptr [RAX + 0x690] ADD RAX,qword ptr [RBP + -0x20] ADD RAX,qword ptr [RBP + -0x30] ADD RAX,0x40 MOV qword ptr [RBP + -0x48],RAX MOV RDI,qword ptr [RBP + -0x40] MOV RSI,qword ptr [RBP + -0x48] CALL 0x0016da30 MOV ECX,EAX XOR EAX,EAX CMP EAX,ECX JNZ 0x0016de24 MOV RAX,qword ptr [RBP + -0x40] MOV RAX,qword ptr [RAX + 0x688] MOV RCX,qword ptr [RBP + -0x40] ADD RAX,qword ptr [RCX + 0x690] MOV qword ptr [RBP + -0x50],RAX MOV RDI,qword ptr [RBP + -0x50] MOV RSI,qword ptr [RBP + -0x18] MOV RAX,qword ptr [RBP + -0x20] MOV EDX,EAX MOV RCX,qword ptr [RBP + -0x28] MOV RAX,qword ptr [RBP + -0x30] MOV R8D,EAX MOV R9,qword ptr [RBP + -0x38] MOV AL,0x0 CALL 0x001240b0 MOV RDI,qword ptr [RBP + -0x50] CALL 0x00124130 MOV RCX,RAX MOV RAX,qword ptr [RBP + -0x40] ADD RCX,qword ptr [RAX + 0x690] MOV qword ptr [RAX + 0x690],RCX MOV dword ptr [RBP + -0x4],0x0 JMP 0x0016de2b LAB_0016de24: MOV dword ptr [RBP + -0x4],0x1 LAB_0016de2b: MOV EAX,dword ptr [RBP + -0x4] ADD RSP,0x50 POP RBP RET
bool tailoring_append2(long param_1,char *param_2,ulong param_3,int8 param_4,ulong param_5, int8 param_6) { long lVar1; int iVar2; char *__s; size_t sVar3; lVar1 = *(long *)(param_1 + 0x140); iVar2 = my_charset_file_tailoring_realloc (lVar1,*(long *)(lVar1 + 0x690) + param_3 + param_5 + 0x40); if (iVar2 == 0) { __s = (char *)(*(long *)(lVar1 + 0x688) + *(long *)(lVar1 + 0x690)); sprintf(__s,param_2,param_3 & 0xffffffff,param_4,param_5 & 0xffffffff,param_6); sVar3 = strlen(__s); *(size_t *)(lVar1 + 0x690) = sVar3 + *(long *)(lVar1 + 0x690); } return iVar2 != 0; }
60,879
google::protobuf::FileOptions::unknown_fields() const
aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/descriptor.pb.h
inline const ::PROTOBUF_NAMESPACE_ID::UnknownFieldSet& unknown_fields() const { return _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance); }
O0
c
google::protobuf::FileOptions::unknown_fields() const: subq $0x38, %rsp movq %rdi, 0x8(%rsp) movq 0x8(%rsp), %rax addq $0x8, %rax movq %rax, 0x18(%rsp) leaq 0xc0a32(%rip), %rax # 0x162af0 movq %rax, 0x10(%rsp) movq 0x18(%rsp), %rax movq %rax, (%rsp) movq %rax, 0x28(%rsp) movq 0x28(%rsp), %rax movq %rax, 0x30(%rsp) movq 0x30(%rsp), %rax movq (%rax), %rax andq $0x1, %rax cmpq $0x0, %rax je 0xa2101 movq (%rsp), %rdi callq 0x9cd40 addq $0x8, %rax movq %rax, 0x20(%rsp) jmp 0xa210a callq *0x10(%rsp) movq %rax, 0x20(%rsp) movq 0x20(%rsp), %rax addq $0x38, %rsp retq nopw %cs:(%rax,%rax) nop
_ZNK6google8protobuf13MethodOptions14unknown_fieldsEv: sub rsp, 38h mov [rsp+38h+var_30], rdi mov rax, [rsp+38h+var_30] add rax, 8 mov [rsp+38h+var_20], rax lea rax, _ZN6google8protobuf15UnknownFieldSet16default_instanceEv; google::protobuf::UnknownFieldSet::default_instance(void) mov [rsp+38h+var_28], rax mov rax, [rsp+38h+var_20] mov [rsp+38h+var_38], rax mov [rsp+38h+var_10], rax mov rax, [rsp+38h+var_10] mov [rsp+38h+var_8], rax mov rax, [rsp+38h+var_8] mov rax, [rax] and rax, 1 cmp rax, 0 jz short loc_A2101 mov rdi, [rsp+38h+var_38] call _ZNK6google8protobuf8internal16InternalMetadata8PtrValueINS2_9ContainerINS0_15UnknownFieldSetEEEEEPT_v; google::protobuf::internal::InternalMetadata::PtrValue<google::protobuf::internal::InternalMetadata::Container<google::protobuf::UnknownFieldSet>>(void) add rax, 8 mov [rsp+38h+var_18], rax jmp short loc_A210A loc_A2101: call [rsp+38h+var_28] mov [rsp+38h+var_18], rax loc_A210A: mov rax, [rsp+38h+var_18] add rsp, 38h retn
unsigned long long google::protobuf::MethodOptions::unknown_fields( google::protobuf::MethodOptions *this, long long a2, long long a3, long long a4) { if ( (*((_QWORD *)this + 1) & 1LL) != 0 ) return google::protobuf::internal::InternalMetadata::PtrValue<google::protobuf::internal::InternalMetadata::Container<google::protobuf::UnknownFieldSet>>((_QWORD *)this + 1) + 8; else return ((long long ( *)(google::protobuf::MethodOptions *, long long, long long, long long))google::protobuf::UnknownFieldSet::default_instance)( this, a2, a3, a4); }
unknown_fields: SUB RSP,0x38 MOV qword ptr [RSP + 0x8],RDI MOV RAX,qword ptr [RSP + 0x8] ADD RAX,0x8 MOV qword ptr [RSP + 0x18],RAX LEA RAX,[0x262af0] MOV qword ptr [RSP + 0x10],RAX MOV RAX,qword ptr [RSP + 0x18] MOV qword ptr [RSP],RAX MOV qword ptr [RSP + 0x28],RAX MOV RAX,qword ptr [RSP + 0x28] MOV qword ptr [RSP + 0x30],RAX MOV RAX,qword ptr [RSP + 0x30] MOV RAX,qword ptr [RAX] AND RAX,0x1 CMP RAX,0x0 JZ 0x001a2101 MOV RDI,qword ptr [RSP] CALL 0x0019cd40 ADD RAX,0x8 MOV qword ptr [RSP + 0x20],RAX JMP 0x001a210a LAB_001a2101: CALL qword ptr [RSP + 0x10] MOV qword ptr [RSP + 0x20],RAX LAB_001a210a: MOV RAX,qword ptr [RSP + 0x20] ADD RSP,0x38 RET
/* google::protobuf::MethodOptions::unknown_fields() const */ Container * __thiscall google::protobuf::MethodOptions::unknown_fields(MethodOptions *this) { Container *local_18; if ((*(ulong *)(this + 8) & 1) == 0) { local_18 = (Container *)UnknownFieldSet::default_instance(); } else { local_18 = internal::InternalMetadata:: PtrValue<google::protobuf::internal::InternalMetadata::Container<google::protobuf::UnknownFieldSet>> ((InternalMetadata *)(this + 8)); local_18 = local_18 + 8; } return local_18; }
60,880
account_hash_get_key(unsigned char const*, unsigned long*, char)
eloqsql/storage/perfschema/pfs_account.cc
C_MODE_START static uchar *account_hash_get_key(const uchar *entry, size_t *length, my_bool) { const PFS_account * const *typed_entry; const PFS_account *account; const void *result; typed_entry= reinterpret_cast<const PFS_account* const *> (entry); assert(typed_entry != NULL); account= *typed_entry; assert(account != NULL); *length= account->m_key.m_key_length; result= account->m_key.m_hash_key; return const_cast<uchar*> (reinterpret_cast<const uchar*> (result)); }
O0
cpp
account_hash_get_key(unsigned char const*, unsigned long*, char): pushq %rbp movq %rsp, %rbp movb %dl, %al movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movb %al, -0x11(%rbp) movq -0x8(%rbp), %rax movq %rax, -0x20(%rbp) movq -0x20(%rbp), %rax movq (%rax), %rax movq %rax, -0x28(%rbp) movq -0x28(%rbp), %rax movl 0xa68(%rax), %eax movl %eax, %ecx movq -0x10(%rbp), %rax movq %rcx, (%rax) movq -0x28(%rbp), %rax addq $0x7e4, %rax # imm = 0x7E4 movq %rax, -0x30(%rbp) movq -0x30(%rbp), %rax popq %rbp retq nopl (%rax,%rax)
_ZL20account_hash_get_keyPKhPmc: push rbp mov rbp, rsp mov al, dl mov [rbp+var_8], rdi mov [rbp+var_10], rsi mov [rbp+var_11], al mov rax, [rbp+var_8] mov [rbp+var_20], rax mov rax, [rbp+var_20] mov rax, [rax] mov [rbp+var_28], rax mov rax, [rbp+var_28] mov eax, [rax+0A68h] mov ecx, eax mov rax, [rbp+var_10] mov [rax], rcx mov rax, [rbp+var_28] add rax, 7E4h mov [rbp+var_30], rax mov rax, [rbp+var_30] pop rbp retn
long long account_hash_get_key(const unsigned __int8 *a1, unsigned long long *a2) { long long v3; // [rsp+8h] [rbp-28h] v3 = *(_QWORD *)a1; *a2 = *(unsigned int *)(*(_QWORD *)a1 + 2664LL); return v3 + 2020; }
account_hash_get_key: PUSH RBP MOV RBP,RSP MOV AL,DL MOV qword ptr [RBP + -0x8],RDI MOV qword ptr [RBP + -0x10],RSI MOV byte ptr [RBP + -0x11],AL MOV RAX,qword ptr [RBP + -0x8] MOV qword ptr [RBP + -0x20],RAX MOV RAX,qword ptr [RBP + -0x20] MOV RAX,qword ptr [RAX] MOV qword ptr [RBP + -0x28],RAX MOV RAX,qword ptr [RBP + -0x28] MOV EAX,dword ptr [RAX + 0xa68] MOV ECX,EAX MOV RAX,qword ptr [RBP + -0x10] MOV qword ptr [RAX],RCX MOV RAX,qword ptr [RBP + -0x28] ADD RAX,0x7e4 MOV qword ptr [RBP + -0x30],RAX MOV RAX,qword ptr [RBP + -0x30] POP RBP RET
/* account_hash_get_key(unsigned char const*, unsigned long*, char) */ long account_hash_get_key(uchar *param_1,ulong *param_2,char param_3) { long lVar1; lVar1 = *(long *)param_1; *param_2 = (ulong)*(uint *)(lVar1 + 0xa68); return lVar1 + 0x7e4; }
60,881
js_free_function_def
bluesky950520[P]quickjs/quickjs.c
static void js_free_function_def(JSContext *ctx, JSFunctionDef *fd) { int i; struct list_head *el, *el1; /* free the child functions */ list_for_each_safe(el, el1, &fd->child_list) { JSFunctionDef *fd1; fd1 = list_entry(el, JSFunctionDef, link); js_free_function_def(ctx, fd1); } free_bytecode_atoms(ctx->rt, fd->byte_code.buf, fd->byte_code.size, fd->use_short_opcodes); dbuf_free(&fd->byte_code); js_free(ctx, fd->jump_slots); js_free(ctx, fd->label_slots); js_free(ctx, fd->source_loc_slots); /* free ic */ if (fd->ic) free_ic(ctx->rt, fd->ic); for(i = 0; i < fd->cpool_count; i++) { JS_FreeValue(ctx, fd->cpool[i]); } js_free(ctx, fd->cpool); JS_FreeAtom(ctx, fd->func_name); for(i = 0; i < fd->var_count; i++) { JS_FreeAtom(ctx, fd->vars[i].var_name); } js_free(ctx, fd->vars); js_free(ctx, fd->vars_htab); // XXX can probably be freed earlier? for(i = 0; i < fd->arg_count; i++) { JS_FreeAtom(ctx, fd->args[i].var_name); } js_free(ctx, fd->args); for(i = 0; i < fd->global_var_count; i++) { JS_FreeAtom(ctx, fd->global_vars[i].var_name); } js_free(ctx, fd->global_vars); for(i = 0; i < fd->closure_var_count; i++) { JSClosureVar *cv = &fd->closure_var[i]; JS_FreeAtom(ctx, cv->var_name); } js_free(ctx, fd->closure_var); if (fd->scopes != fd->def_scope_array) js_free(ctx, fd->scopes); JS_FreeAtom(ctx, fd->filename); dbuf_free(&fd->pc2line); js_free(ctx, fd->source); if (fd->parent) { /* remove in parent list */ list_del(&fd->link); } js_free(ctx, fd); }
O1
c
js_free_function_def: pushq %r15 pushq %r14 pushq %r12 pushq %rbx pushq %rax movq %rsi, %rbx movq %rdi, %r14 leaq 0x18(%rsi), %r15 movq 0x20(%rsi), %rsi cmpq %r15, %rsi je 0x585fa movq 0x8(%rsi), %r12 addq $-0x28, %rsi movq %r14, %rdi callq 0x585c7 movq %r12, %rsi cmpq %r15, %r12 jne 0x585e2 movq 0x18(%r14), %rdi leaq 0x138(%rbx), %r15 movq 0x138(%rbx), %rsi movl 0x140(%rbx), %edx movl 0x16c(%rbx), %ecx callq 0x3c944 movq %r15, %rdi callq 0x1b62a movq 0x1a8(%rbx), %rsi movq %r14, %rdi callq 0x1cb99 movq 0x170(%rbx), %rsi movq %r14, %rdi callq 0x1cb99 movq 0x1b8(%rbx), %rsi movq %r14, %rdi callq 0x1cb99 movq 0x230(%rbx), %rsi testq %rsi, %rsi je 0x58667 movq 0x18(%r14), %rdi callq 0x3c9da cmpl $0x0, 0x190(%rbx) jle 0x586a5 movl $0x8, %r15d xorl %r12d, %r12d movq 0x188(%rbx), %rax movq -0x8(%rax,%r15), %rsi movq (%rax,%r15), %rdx movq 0x18(%r14), %rdi callq 0x1d8c6 incq %r12 movslq 0x190(%rbx), %rax addq $0x10, %r15 cmpq %rax, %r12 jl 0x58679 movq 0x188(%rbx), %rsi movq %r14, %rdi callq 0x1cb99 movl 0x88(%rbx), %esi movq %r14, %rdi callq 0x207d8 cmpl $0x0, 0xa4(%rbx) jle 0x586f7 xorl %r15d, %r15d xorl %r12d, %r12d movq 0x90(%rbx), %rax movl (%rax,%r15), %esi movq %r14, %rdi callq 0x207d8 incq %r12 movslq 0xa4(%rbx), %rax addq $0x10, %r15 cmpq %rax, %r12 jl 0x586d1 movq 0x90(%rbx), %rsi movq %r14, %rdi callq 0x1cb99 movq 0x98(%rbx), %rsi movq %r14, %rdi callq 0x1cb99 cmpl $0x0, 0xb4(%rbx) jle 0x5874a xorl %r15d, %r15d xorl %r12d, %r12d movq 0xa8(%rbx), %rax movl (%rax,%r15), %esi movq %r14, %rdi callq 0x207d8 incq %r12 movslq 0xb4(%rbx), %rax addq $0x10, %r15 cmpq %rax, %r12 jl 0x58724 movq 0xa8(%rbx), %rsi movq %r14, %rdi callq 0x1cb99 cmpl $0x0, 0x124(%rbx) jle 0x58791 movl $0xc, %r15d xorl %r12d, %r12d movq 0x130(%rbx), %rax movl (%rax,%r15), %esi movq %r14, %rdi callq 0x207d8 incq %r12 movslq 0x124(%rbx), %rax addq $0x10, %r15 cmpq %rax, %r12 jl 0x5876b movq 0x130(%rbx), %rsi movq %r14, %rdi callq 0x1cb99 cmpl $0x0, 0x198(%rbx) jle 0x587cf xorl %r15d, %r15d movq 0x1a0(%rbx), %rax movl 0x4(%rax,%r15,8), %esi movq %r14, %rdi callq 0x207d8 incq %r15 movslq 0x198(%rbx), %rax cmpq %rax, %r15 jl 0x587ac movq 0x1a0(%rbx), %rsi movq %r14, %rdi callq 0x1cb99 movq 0xf8(%rbx), %rsi leaq 0x100(%rbx), %rax cmpq %rax, %rsi je 0x587f9 movq %r14, %rdi callq 0x1cb99 movl 0x1d4(%rbx), %esi movq %r14, %rdi callq 0x207d8 leaq 0x1e0(%rbx), %rdi callq 0x1b62a movq 0x210(%rbx), %rsi movq %r14, %rdi callq 0x1cb99 cmpq $0x0, 0x8(%rbx) je 0x5883f movq 0x28(%rbx), %rax movq 0x30(%rbx), %rcx movq %rcx, 0x8(%rax) movq %rax, (%rcx) xorps %xmm0, %xmm0 movups %xmm0, 0x28(%rbx) movq %r14, %rdi movq %rbx, %rsi addq $0x8, %rsp popq %rbx popq %r12 popq %r14 popq %r15 jmp 0x1cb99
js_free_function_def: push r15 push r14 push r12 push rbx push rax mov rbx, rsi mov r14, rdi lea r15, [rsi+18h] mov rsi, [rsi+20h] cmp rsi, r15 jz short loc_585FA loc_585E2: mov r12, [rsi+8] add rsi, 0FFFFFFFFFFFFFFD8h mov rdi, r14 call js_free_function_def mov rsi, r12 cmp r12, r15 jnz short loc_585E2 loc_585FA: mov rdi, [r14+18h] lea r15, [rbx+138h] mov rsi, [rbx+138h] mov edx, [rbx+140h] mov ecx, [rbx+16Ch] call free_bytecode_atoms mov rdi, r15 call dbuf_free mov rsi, [rbx+1A8h] mov rdi, r14 call js_free mov rsi, [rbx+170h] mov rdi, r14 call js_free mov rsi, [rbx+1B8h] mov rdi, r14 call js_free mov rsi, [rbx+230h] test rsi, rsi jz short loc_58667 mov rdi, [r14+18h] call free_ic loc_58667: cmp dword ptr [rbx+190h], 0 jle short loc_586A5 mov r15d, 8 xor r12d, r12d loc_58679: mov rax, [rbx+188h] mov rsi, [rax+r15-8] mov rdx, [rax+r15] mov rdi, [r14+18h] call JS_FreeValueRT inc r12 movsxd rax, dword ptr [rbx+190h] add r15, 10h cmp r12, rax jl short loc_58679 loc_586A5: mov rsi, [rbx+188h] mov rdi, r14 call js_free mov esi, [rbx+88h] mov rdi, r14 call JS_FreeAtom cmp dword ptr [rbx+0A4h], 0 jle short loc_586F7 xor r15d, r15d xor r12d, r12d loc_586D1: mov rax, [rbx+90h] mov esi, [rax+r15] mov rdi, r14 call JS_FreeAtom inc r12 movsxd rax, dword ptr [rbx+0A4h] add r15, 10h cmp r12, rax jl short loc_586D1 loc_586F7: mov rsi, [rbx+90h] mov rdi, r14 call js_free mov rsi, [rbx+98h] mov rdi, r14 call js_free cmp dword ptr [rbx+0B4h], 0 jle short loc_5874A xor r15d, r15d xor r12d, r12d loc_58724: mov rax, [rbx+0A8h] mov esi, [rax+r15] mov rdi, r14 call JS_FreeAtom inc r12 movsxd rax, dword ptr [rbx+0B4h] add r15, 10h cmp r12, rax jl short loc_58724 loc_5874A: mov rsi, [rbx+0A8h] mov rdi, r14 call js_free cmp dword ptr [rbx+124h], 0 jle short loc_58791 mov r15d, 0Ch xor r12d, r12d loc_5876B: mov rax, [rbx+130h] mov esi, [rax+r15] mov rdi, r14 call JS_FreeAtom inc r12 movsxd rax, dword ptr [rbx+124h] add r15, 10h cmp r12, rax jl short loc_5876B loc_58791: mov rsi, [rbx+130h] mov rdi, r14 call js_free cmp dword ptr [rbx+198h], 0 jle short loc_587CF xor r15d, r15d loc_587AC: mov rax, [rbx+1A0h] mov esi, [rax+r15*8+4] mov rdi, r14 call JS_FreeAtom inc r15 movsxd rax, dword ptr [rbx+198h] cmp r15, rax jl short loc_587AC loc_587CF: mov rsi, [rbx+1A0h] mov rdi, r14 call js_free mov rsi, [rbx+0F8h] lea rax, [rbx+100h] cmp rsi, rax jz short loc_587F9 mov rdi, r14 call js_free loc_587F9: mov esi, [rbx+1D4h] mov rdi, r14 call JS_FreeAtom lea rdi, [rbx+1E0h] call dbuf_free mov rsi, [rbx+210h] mov rdi, r14 call js_free cmp qword ptr [rbx+8], 0 jz short loc_5883F mov rax, [rbx+28h] mov rcx, [rbx+30h] mov [rax+8], rcx mov [rcx], rax xorps xmm0, xmm0 movups xmmword ptr [rbx+28h], xmm0 loc_5883F: mov rdi, r14 mov rsi, rbx add rsp, 8 pop rbx pop r12 pop r14 pop r15 jmp js_free
long long js_free_function_def(long long a1, long long a2) { long long v3; // r15 long long v4; // rsi long long v5; // r12 unsigned int *v6; // rsi long long v7; // r15 long long v8; // r12 long long v9; // r15 long long v10; // r12 long long v11; // r15 long long v12; // r12 long long v13; // r15 long long v14; // r12 long long v15; // r15 long long v16; // rsi long long v17; // rax _QWORD *v18; // rcx v3 = a2 + 24; v4 = *(_QWORD *)(a2 + 32); if ( v4 != v3 ) { do { v5 = *(_QWORD *)(v4 + 8); js_free_function_def(a1, v4 - 40); v4 = v5; } while ( v5 != v3 ); } free_bytecode_atoms(*(_QWORD *)(a1 + 24), *(_QWORD *)(a2 + 312), *(_DWORD *)(a2 + 320), *(_DWORD *)(a2 + 364)); dbuf_free(a2 + 312); js_free(a1, *(_QWORD *)(a2 + 424)); js_free(a1, *(_QWORD *)(a2 + 368)); js_free(a1, *(_QWORD *)(a2 + 440)); v6 = *(unsigned int **)(a2 + 560); if ( v6 ) free_ic(*(_QWORD *)(a1 + 24), v6); if ( *(int *)(a2 + 400) > 0 ) { v7 = 8LL; v8 = 0LL; do { JS_FreeValueRT( *(_QWORD *)(a1 + 24), *(_DWORD **)(*(_QWORD *)(a2 + 392) + v7 - 8), *(_QWORD *)(*(_QWORD *)(a2 + 392) + v7)); ++v8; v7 += 16LL; } while ( v8 < *(int *)(a2 + 400) ); } js_free(a1, *(_QWORD *)(a2 + 392)); JS_FreeAtom(a1, *(_DWORD *)(a2 + 136)); if ( *(int *)(a2 + 164) > 0 ) { v9 = 0LL; v10 = 0LL; do { JS_FreeAtom(a1, *(_DWORD *)(*(_QWORD *)(a2 + 144) + v9)); ++v10; v9 += 16LL; } while ( v10 < *(int *)(a2 + 164) ); } js_free(a1, *(_QWORD *)(a2 + 144)); js_free(a1, *(_QWORD *)(a2 + 152)); if ( *(int *)(a2 + 180) > 0 ) { v11 = 0LL; v12 = 0LL; do { JS_FreeAtom(a1, *(_DWORD *)(*(_QWORD *)(a2 + 168) + v11)); ++v12; v11 += 16LL; } while ( v12 < *(int *)(a2 + 180) ); } js_free(a1, *(_QWORD *)(a2 + 168)); if ( *(int *)(a2 + 292) > 0 ) { v13 = 12LL; v14 = 0LL; do { JS_FreeAtom(a1, *(_DWORD *)(*(_QWORD *)(a2 + 304) + v13)); ++v14; v13 += 16LL; } while ( v14 < *(int *)(a2 + 292) ); } js_free(a1, *(_QWORD *)(a2 + 304)); if ( *(int *)(a2 + 408) > 0 ) { v15 = 0LL; do JS_FreeAtom(a1, *(_DWORD *)(*(_QWORD *)(a2 + 416) + 8 * v15++ + 4)); while ( v15 < *(int *)(a2 + 408) ); } js_free(a1, *(_QWORD *)(a2 + 416)); v16 = *(_QWORD *)(a2 + 248); if ( v16 != a2 + 256 ) js_free(a1, v16); JS_FreeAtom(a1, *(_DWORD *)(a2 + 468)); dbuf_free(a2 + 480); js_free(a1, *(_QWORD *)(a2 + 528)); if ( *(_QWORD *)(a2 + 8) ) { v17 = *(_QWORD *)(a2 + 40); v18 = *(_QWORD **)(a2 + 48); *(_QWORD *)(v17 + 8) = v18; *v18 = v17; *(_OWORD *)(a2 + 40) = 0LL; } return js_free(a1, a2); }
60,882
js_free_function_def
bluesky950520[P]quickjs/quickjs.c
static void js_free_function_def(JSContext *ctx, JSFunctionDef *fd) { int i; struct list_head *el, *el1; /* free the child functions */ list_for_each_safe(el, el1, &fd->child_list) { JSFunctionDef *fd1; fd1 = list_entry(el, JSFunctionDef, link); js_free_function_def(ctx, fd1); } free_bytecode_atoms(ctx->rt, fd->byte_code.buf, fd->byte_code.size, fd->use_short_opcodes); dbuf_free(&fd->byte_code); js_free(ctx, fd->jump_slots); js_free(ctx, fd->label_slots); js_free(ctx, fd->source_loc_slots); /* free ic */ if (fd->ic) free_ic(ctx->rt, fd->ic); for(i = 0; i < fd->cpool_count; i++) { JS_FreeValue(ctx, fd->cpool[i]); } js_free(ctx, fd->cpool); JS_FreeAtom(ctx, fd->func_name); for(i = 0; i < fd->var_count; i++) { JS_FreeAtom(ctx, fd->vars[i].var_name); } js_free(ctx, fd->vars); js_free(ctx, fd->vars_htab); // XXX can probably be freed earlier? for(i = 0; i < fd->arg_count; i++) { JS_FreeAtom(ctx, fd->args[i].var_name); } js_free(ctx, fd->args); for(i = 0; i < fd->global_var_count; i++) { JS_FreeAtom(ctx, fd->global_vars[i].var_name); } js_free(ctx, fd->global_vars); for(i = 0; i < fd->closure_var_count; i++) { JSClosureVar *cv = &fd->closure_var[i]; JS_FreeAtom(ctx, cv->var_name); } js_free(ctx, fd->closure_var); if (fd->scopes != fd->def_scope_array) js_free(ctx, fd->scopes); JS_FreeAtom(ctx, fd->filename); dbuf_free(&fd->pc2line); js_free(ctx, fd->source); if (fd->parent) { /* remove in parent list */ list_del(&fd->link); } js_free(ctx, fd); }
O2
c
js_free_function_def: pushq %r15 pushq %r14 pushq %r12 pushq %rbx pushq %rax movq %rsi, %rbx movq %rdi, %r14 leaq 0x18(%rsi), %r15 movq 0x20(%rsi), %rsi cmpq %r15, %rsi je 0x4bad4 movq 0x8(%rsi), %r12 addq $-0x28, %rsi movq %r14, %rdi callq 0x4baa4 movq %r12, %rsi jmp 0x4baba movq 0x18(%r14), %rdi leaq 0x138(%rbx), %r15 movq 0x138(%rbx), %rsi movl 0x140(%rbx), %edx movl 0x16c(%rbx), %ecx callq 0x355d8 movq %r15, %rdi callq 0x15e89 movq 0x1a8(%rbx), %rsi movq %r14, %rdi callq 0x1726e movq 0x170(%rbx), %rsi movq %r14, %rdi callq 0x1726e movq 0x1b8(%rbx), %rsi movq %r14, %rdi callq 0x1726e movq 0x230(%rbx), %rsi testq %rsi, %rsi je 0x4bb41 movq 0x18(%r14), %rdi callq 0x3564b pushq $0x8 popq %r15 xorl %r12d, %r12d movslq 0x190(%rbx), %rax movq 0x188(%rbx), %rsi cmpq %rax, %r12 jge 0x4bb78 movq -0x8(%rsi,%r15), %rax movq (%rsi,%r15), %rdx movq %r14, %rdi movq %rax, %rsi callq 0x1801e incq %r12 addq $0x10, %r15 jmp 0x4bb48 movq %r14, %rdi callq 0x1726e movl 0x88(%rbx), %esi movq %r14, %rdi callq 0x1a995 xorl %r15d, %r15d xorl %r12d, %r12d movslq 0xa4(%rbx), %rax movq 0x90(%rbx), %rsi cmpq %rax, %r12 jge 0x4bbbc movl (%rsi,%r15), %esi movq %r14, %rdi callq 0x1a995 incq %r12 addq $0x10, %r15 jmp 0x4bb94 movq %r14, %rdi callq 0x1726e movq 0x98(%rbx), %rsi movq %r14, %rdi callq 0x1726e xorl %r15d, %r15d xorl %r12d, %r12d movslq 0xb4(%rbx), %rax movq 0xa8(%rbx), %rsi cmpq %rax, %r12 jge 0x4bc01 movl (%rsi,%r15), %esi movq %r14, %rdi callq 0x1a995 incq %r12 addq $0x10, %r15 jmp 0x4bbd9 movq %r14, %rdi callq 0x1726e pushq $0xc popq %r15 xorl %r12d, %r12d movslq 0x124(%rbx), %rax movq 0x130(%rbx), %rsi cmpq %rax, %r12 jge 0x4bc38 movl (%rsi,%r15), %esi movq %r14, %rdi callq 0x1a995 incq %r12 addq $0x10, %r15 jmp 0x4bc10 movq %r14, %rdi callq 0x1726e xorl %r15d, %r15d movslq 0x198(%rbx), %rax movq 0x1a0(%rbx), %rsi cmpq %rax, %r15 jge 0x4bc68 movl 0x4(%rsi,%r15,8), %esi movq %r14, %rdi callq 0x1a995 incq %r15 jmp 0x4bc43 movq %r14, %rdi callq 0x1726e movq 0xf8(%rbx), %rsi leaq 0x100(%rbx), %rax cmpq %rax, %rsi je 0x4bc8b movq %r14, %rdi callq 0x1726e movl 0x1d4(%rbx), %esi movq %r14, %rdi callq 0x1a995 leaq 0x1e0(%rbx), %rdi callq 0x15e89 movq 0x210(%rbx), %rsi movq %r14, %rdi callq 0x1726e cmpq $0x0, 0x8(%rbx) je 0x4bcd1 movq 0x28(%rbx), %rax movq 0x30(%rbx), %rcx movq %rcx, 0x8(%rax) movq %rax, (%rcx) xorps %xmm0, %xmm0 movups %xmm0, 0x28(%rbx) movq %r14, %rdi movq %rbx, %rsi addq $0x8, %rsp popq %rbx popq %r12 popq %r14 popq %r15 jmp 0x1726e
js_free_function_def: push r15 push r14 push r12 push rbx push rax mov rbx, rsi mov r14, rdi lea r15, [rsi+18h] mov rsi, [rsi+20h] loc_4BABA: cmp rsi, r15 jz short loc_4BAD4 mov r12, [rsi+8] add rsi, 0FFFFFFFFFFFFFFD8h mov rdi, r14 call js_free_function_def mov rsi, r12 jmp short loc_4BABA loc_4BAD4: mov rdi, [r14+18h] lea r15, [rbx+138h] mov rsi, [rbx+138h] mov edx, [rbx+140h] mov ecx, [rbx+16Ch] call free_bytecode_atoms mov rdi, r15 call dbuf_free mov rsi, [rbx+1A8h] mov rdi, r14 call js_free mov rsi, [rbx+170h] mov rdi, r14 call js_free mov rsi, [rbx+1B8h] mov rdi, r14 call js_free mov rsi, [rbx+230h] test rsi, rsi jz short loc_4BB41 mov rdi, [r14+18h] call free_ic loc_4BB41: push 8 pop r15 xor r12d, r12d loc_4BB48: movsxd rax, dword ptr [rbx+190h] mov rsi, [rbx+188h] cmp r12, rax jge short loc_4BB78 mov rax, [rsi+r15-8] mov rdx, [rsi+r15] mov rdi, r14 mov rsi, rax call JS_FreeValue inc r12 add r15, 10h jmp short loc_4BB48 loc_4BB78: mov rdi, r14 call js_free mov esi, [rbx+88h] mov rdi, r14 call JS_FreeAtom xor r15d, r15d xor r12d, r12d loc_4BB94: movsxd rax, dword ptr [rbx+0A4h] mov rsi, [rbx+90h] cmp r12, rax jge short loc_4BBBC mov esi, [rsi+r15] mov rdi, r14 call JS_FreeAtom inc r12 add r15, 10h jmp short loc_4BB94 loc_4BBBC: mov rdi, r14 call js_free mov rsi, [rbx+98h] mov rdi, r14 call js_free xor r15d, r15d xor r12d, r12d loc_4BBD9: movsxd rax, dword ptr [rbx+0B4h] mov rsi, [rbx+0A8h] cmp r12, rax jge short loc_4BC01 mov esi, [rsi+r15] mov rdi, r14 call JS_FreeAtom inc r12 add r15, 10h jmp short loc_4BBD9 loc_4BC01: mov rdi, r14 call js_free push 0Ch pop r15 xor r12d, r12d loc_4BC10: movsxd rax, dword ptr [rbx+124h] mov rsi, [rbx+130h] cmp r12, rax jge short loc_4BC38 mov esi, [rsi+r15] mov rdi, r14 call JS_FreeAtom inc r12 add r15, 10h jmp short loc_4BC10 loc_4BC38: mov rdi, r14 call js_free xor r15d, r15d loc_4BC43: movsxd rax, dword ptr [rbx+198h] mov rsi, [rbx+1A0h] cmp r15, rax jge short loc_4BC68 mov esi, [rsi+r15*8+4] mov rdi, r14 call JS_FreeAtom inc r15 jmp short loc_4BC43 loc_4BC68: mov rdi, r14 call js_free mov rsi, [rbx+0F8h] lea rax, [rbx+100h] cmp rsi, rax jz short loc_4BC8B mov rdi, r14 call js_free loc_4BC8B: mov esi, [rbx+1D4h] mov rdi, r14 call JS_FreeAtom lea rdi, [rbx+1E0h] call dbuf_free mov rsi, [rbx+210h] mov rdi, r14 call js_free cmp qword ptr [rbx+8], 0 jz short loc_4BCD1 mov rax, [rbx+28h] mov rcx, [rbx+30h] mov [rax+8], rcx mov [rcx], rax xorps xmm0, xmm0 movups xmmword ptr [rbx+28h], xmm0 loc_4BCD1: mov rdi, r14 mov rsi, rbx add rsp, 8 pop rbx pop r12 pop r14 pop r15 jmp js_free
long long js_free_function_def(long long a1, long long a2) { long long v3; // r15 long long i; // rsi long long v5; // r12 unsigned int *v6; // rsi long long v7; // r15 long long j; // r12 long long v9; // rsi long long v10; // r15 long long k; // r12 long long v12; // rsi long long v13; // r15 long long m; // r12 long long v15; // rsi long long v16; // r15 long long n; // r12 long long v18; // rsi long long ii; // r15 long long v20; // rsi long long v21; // rsi long long v22; // rax _QWORD *v23; // rcx v3 = a2 + 24; for ( i = *(_QWORD *)(a2 + 32); i != v3; i = v5 ) { v5 = *(_QWORD *)(i + 8); js_free_function_def(a1, i - 40); } free_bytecode_atoms(*(_QWORD *)(a1 + 24), *(_QWORD *)(a2 + 312), *(_DWORD *)(a2 + 320), *(_DWORD *)(a2 + 364)); dbuf_free(a2 + 312); js_free(a1, *(_QWORD *)(a2 + 424)); js_free(a1, *(_QWORD *)(a2 + 368)); js_free(a1, *(_QWORD *)(a2 + 440)); v6 = *(unsigned int **)(a2 + 560); if ( v6 ) free_ic(*(_QWORD *)(a1 + 24), v6); v7 = 8LL; for ( j = 0LL; ; ++j ) { v9 = *(_QWORD *)(a2 + 392); if ( j >= *(int *)(a2 + 400) ) break; JS_FreeValue(a1, *(_QWORD *)(v9 + v7 - 8), *(_QWORD *)(v9 + v7)); v7 += 16LL; } js_free(a1, v9); JS_FreeAtom(a1, *(_DWORD *)(a2 + 136)); v10 = 0LL; for ( k = 0LL; ; ++k ) { v12 = *(_QWORD *)(a2 + 144); if ( k >= *(int *)(a2 + 164) ) break; JS_FreeAtom(a1, *(_DWORD *)(v12 + v10)); v10 += 16LL; } js_free(a1, v12); js_free(a1, *(_QWORD *)(a2 + 152)); v13 = 0LL; for ( m = 0LL; ; ++m ) { v15 = *(_QWORD *)(a2 + 168); if ( m >= *(int *)(a2 + 180) ) break; JS_FreeAtom(a1, *(_DWORD *)(v15 + v13)); v13 += 16LL; } js_free(a1, v15); v16 = 12LL; for ( n = 0LL; ; ++n ) { v18 = *(_QWORD *)(a2 + 304); if ( n >= *(int *)(a2 + 292) ) break; JS_FreeAtom(a1, *(_DWORD *)(v18 + v16)); v16 += 16LL; } js_free(a1, v18); for ( ii = 0LL; ; ++ii ) { v20 = *(_QWORD *)(a2 + 416); if ( ii >= *(int *)(a2 + 408) ) break; JS_FreeAtom(a1, *(_DWORD *)(v20 + 8 * ii + 4)); } js_free(a1, v20); v21 = *(_QWORD *)(a2 + 248); if ( v21 != a2 + 256 ) js_free(a1, v21); JS_FreeAtom(a1, *(_DWORD *)(a2 + 468)); dbuf_free(a2 + 480); js_free(a1, *(_QWORD *)(a2 + 528)); if ( *(_QWORD *)(a2 + 8) ) { v22 = *(_QWORD *)(a2 + 40); v23 = *(_QWORD **)(a2 + 48); *(_QWORD *)(v22 + 8) = v23; *v23 = v22; *(_OWORD *)(a2 + 40) = 0LL; } return js_free(a1, a2); }
js_free_function_def: PUSH R15 PUSH R14 PUSH R12 PUSH RBX PUSH RAX MOV RBX,RSI MOV R14,RDI LEA R15,[RSI + 0x18] MOV RSI,qword ptr [RSI + 0x20] LAB_0014baba: CMP RSI,R15 JZ 0x0014bad4 MOV R12,qword ptr [RSI + 0x8] ADD RSI,-0x28 MOV RDI,R14 CALL 0x0014baa4 MOV RSI,R12 JMP 0x0014baba LAB_0014bad4: MOV RDI,qword ptr [R14 + 0x18] LEA R15,[RBX + 0x138] MOV RSI,qword ptr [RBX + 0x138] MOV EDX,dword ptr [RBX + 0x140] MOV ECX,dword ptr [RBX + 0x16c] CALL 0x001355d8 MOV RDI,R15 CALL 0x00115e89 MOV RSI,qword ptr [RBX + 0x1a8] MOV RDI,R14 CALL 0x0011726e MOV RSI,qword ptr [RBX + 0x170] MOV RDI,R14 CALL 0x0011726e MOV RSI,qword ptr [RBX + 0x1b8] MOV RDI,R14 CALL 0x0011726e MOV RSI,qword ptr [RBX + 0x230] TEST RSI,RSI JZ 0x0014bb41 MOV RDI,qword ptr [R14 + 0x18] CALL 0x0013564b LAB_0014bb41: PUSH 0x8 POP R15 XOR R12D,R12D LAB_0014bb48: MOVSXD RAX,dword ptr [RBX + 0x190] MOV RSI,qword ptr [RBX + 0x188] CMP R12,RAX JGE 0x0014bb78 MOV RAX,qword ptr [RSI + R15*0x1 + -0x8] MOV RDX,qword ptr [RSI + R15*0x1] MOV RDI,R14 MOV RSI,RAX CALL 0x0011801e INC R12 ADD R15,0x10 JMP 0x0014bb48 LAB_0014bb78: MOV RDI,R14 CALL 0x0011726e MOV ESI,dword ptr [RBX + 0x88] MOV RDI,R14 CALL 0x0011a995 XOR R15D,R15D XOR R12D,R12D LAB_0014bb94: MOVSXD RAX,dword ptr [RBX + 0xa4] MOV RSI,qword ptr [RBX + 0x90] CMP R12,RAX JGE 0x0014bbbc MOV ESI,dword ptr [RSI + R15*0x1] MOV RDI,R14 CALL 0x0011a995 INC R12 ADD R15,0x10 JMP 0x0014bb94 LAB_0014bbbc: MOV RDI,R14 CALL 0x0011726e MOV RSI,qword ptr [RBX + 0x98] MOV RDI,R14 CALL 0x0011726e XOR R15D,R15D XOR R12D,R12D LAB_0014bbd9: MOVSXD RAX,dword ptr [RBX + 0xb4] MOV RSI,qword ptr [RBX + 0xa8] CMP R12,RAX JGE 0x0014bc01 MOV ESI,dword ptr [RSI + R15*0x1] MOV RDI,R14 CALL 0x0011a995 INC R12 ADD R15,0x10 JMP 0x0014bbd9 LAB_0014bc01: MOV RDI,R14 CALL 0x0011726e PUSH 0xc POP R15 XOR R12D,R12D LAB_0014bc10: MOVSXD RAX,dword ptr [RBX + 0x124] MOV RSI,qword ptr [RBX + 0x130] CMP R12,RAX JGE 0x0014bc38 MOV ESI,dword ptr [RSI + R15*0x1] MOV RDI,R14 CALL 0x0011a995 INC R12 ADD R15,0x10 JMP 0x0014bc10 LAB_0014bc38: MOV RDI,R14 CALL 0x0011726e XOR R15D,R15D LAB_0014bc43: MOVSXD RAX,dword ptr [RBX + 0x198] MOV RSI,qword ptr [RBX + 0x1a0] CMP R15,RAX JGE 0x0014bc68 MOV ESI,dword ptr [RSI + R15*0x8 + 0x4] MOV RDI,R14 CALL 0x0011a995 INC R15 JMP 0x0014bc43 LAB_0014bc68: MOV RDI,R14 CALL 0x0011726e MOV RSI,qword ptr [RBX + 0xf8] LEA RAX,[RBX + 0x100] CMP RSI,RAX JZ 0x0014bc8b MOV RDI,R14 CALL 0x0011726e LAB_0014bc8b: MOV ESI,dword ptr [RBX + 0x1d4] MOV RDI,R14 CALL 0x0011a995 LEA RDI,[RBX + 0x1e0] CALL 0x00115e89 MOV RSI,qword ptr [RBX + 0x210] MOV RDI,R14 CALL 0x0011726e CMP qword ptr [RBX + 0x8],0x0 JZ 0x0014bcd1 MOV RAX,qword ptr [RBX + 0x28] MOV RCX,qword ptr [RBX + 0x30] MOV qword ptr [RAX + 0x8],RCX MOV qword ptr [RCX],RAX XORPS XMM0,XMM0 MOVUPS xmmword ptr [RBX + 0x28],XMM0 LAB_0014bcd1: MOV RDI,R14 MOV RSI,RBX ADD RSP,0x8 POP RBX POP R12 POP R14 POP R15 JMP 0x0011726e
void js_free_function_def(long param_1,long param_2) { long *plVar1; long lVar2; long lVar3; lVar3 = *(long *)(param_2 + 0x20); while (lVar3 != param_2 + 0x18) { lVar2 = *(long *)(lVar3 + 8); js_free_function_def(param_1,lVar3 + -0x28); lVar3 = lVar2; } free_bytecode_atoms(*(int8 *)(param_1 + 0x18),*(int8 *)(param_2 + 0x138), *(int4 *)(param_2 + 0x140),*(int4 *)(param_2 + 0x16c)); dbuf_free(param_2 + 0x138); js_free(param_1,*(int8 *)(param_2 + 0x1a8)); js_free(param_1,*(int8 *)(param_2 + 0x170)); js_free(param_1,*(int8 *)(param_2 + 0x1b8)); if (*(long *)(param_2 + 0x230) != 0) { free_ic(*(int8 *)(param_1 + 0x18)); } lVar3 = 8; for (lVar2 = 0; lVar2 < *(int *)(param_2 + 400); lVar2 = lVar2 + 1) { JS_FreeValue(param_1,*(int8 *)(*(long *)(param_2 + 0x188) + -8 + lVar3), *(int8 *)(*(long *)(param_2 + 0x188) + lVar3)); lVar3 = lVar3 + 0x10; } js_free(param_1); JS_FreeAtom(param_1,*(int4 *)(param_2 + 0x88)); lVar2 = 0; for (lVar3 = 0; lVar3 < *(int *)(param_2 + 0xa4); lVar3 = lVar3 + 1) { JS_FreeAtom(param_1,*(int4 *)(*(long *)(param_2 + 0x90) + lVar2)); lVar2 = lVar2 + 0x10; } js_free(param_1); js_free(param_1,*(int8 *)(param_2 + 0x98)); lVar2 = 0; for (lVar3 = 0; lVar3 < *(int *)(param_2 + 0xb4); lVar3 = lVar3 + 1) { JS_FreeAtom(param_1,*(int4 *)(*(long *)(param_2 + 0xa8) + lVar2)); lVar2 = lVar2 + 0x10; } js_free(param_1); lVar3 = 0xc; for (lVar2 = 0; lVar2 < *(int *)(param_2 + 0x124); lVar2 = lVar2 + 1) { JS_FreeAtom(param_1,*(int4 *)(*(long *)(param_2 + 0x130) + lVar3)); lVar3 = lVar3 + 0x10; } js_free(param_1); for (lVar3 = 0; lVar3 < *(int *)(param_2 + 0x198); lVar3 = lVar3 + 1) { JS_FreeAtom(param_1,*(int4 *)(*(long *)(param_2 + 0x1a0) + 4 + lVar3 * 8)); } js_free(param_1); if (*(long *)(param_2 + 0xf8) != param_2 + 0x100) { js_free(param_1); } JS_FreeAtom(param_1,*(int4 *)(param_2 + 0x1d4)); dbuf_free(param_2 + 0x1e0); js_free(param_1,*(int8 *)(param_2 + 0x210)); if (*(long *)(param_2 + 8) != 0) { lVar3 = *(long *)(param_2 + 0x28); plVar1 = *(long **)(param_2 + 0x30); *(long **)(lVar3 + 8) = plVar1; *plVar1 = lVar3; *(int8 *)(param_2 + 0x28) = 0; *(int8 *)(param_2 + 0x30) = 0; } js_free(param_1,param_2); return; }
60,883
OpenSubdiv::v3_6_0::Bfr::IrregularPatchBuilder::gatherControlVertexSharpness(int*, float*) const
NVIDIA-RTX[P]OSD-Lite/opensubdiv/bfr/irregularPatchBuilder.cpp
int IrregularPatchBuilder::gatherControlVertexSharpness( int vertIndices[], float vertSharpness[]) const { int nSharpVerts = 0; for (int i = 0; i < _surface.GetFaceSize(); ++i) { FaceVertexSubset const & cSub = _surface.GetCornerSubset(i); if (cSub._tag.IsInfSharp()) { vertSharpness[nSharpVerts] = Sdc::Crease::SHARPNESS_INFINITE; vertIndices[nSharpVerts++] = i; } else if (cSub._tag.IsSemiSharp()) { vertSharpness[nSharpVerts] = (cSub._localSharpness > 0.0f) ? cSub._localSharpness : _surface.GetCornerTopology(i).GetVertexSharpness(); vertIndices[nSharpVerts++] = i; } } return nSharpVerts; }
O0
cpp
OpenSubdiv::v3_6_0::Bfr::IrregularPatchBuilder::gatherControlVertexSharpness(int*, float*) const: pushq %rbp movq %rsp, %rbp subq $0x40, %rsp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq %rdx, -0x18(%rbp) movq -0x8(%rbp), %rax movq %rax, -0x30(%rbp) movl $0x0, -0x1c(%rbp) movl $0x0, -0x20(%rbp) movq -0x30(%rbp), %rax movl -0x20(%rbp), %ecx movl %ecx, -0x34(%rbp) movq (%rax), %rdi callq 0xc6430 movl %eax, %ecx movl -0x34(%rbp), %eax cmpl %ecx, %eax jge 0x18efc2 movq -0x30(%rbp), %rax movq (%rax), %rdi movl -0x20(%rbp), %esi callq 0xc87d0 movq %rax, -0x28(%rbp) movq -0x28(%rbp), %rdi callq 0xc75c0 testb $0x1, %al jne 0x18ef0b jmp 0x18ef3a movq -0x18(%rbp), %rax movslq -0x1c(%rbp), %rcx movss 0x5b0f1(%rip), %xmm0 # 0x1ea00c movss %xmm0, (%rax,%rcx,4) movl -0x20(%rbp), %edx movq -0x10(%rbp), %rax movl -0x1c(%rbp), %ecx movl %ecx, %esi addl $0x1, %esi movl %esi, -0x1c(%rbp) movslq %ecx, %rcx movl %edx, (%rax,%rcx,4) jmp 0x18efb2 movq -0x28(%rbp), %rdi callq 0xd4380 testb $0x1, %al jne 0x18ef49 jmp 0x18efb0 movq -0x28(%rbp), %rax movss 0x8(%rax), %xmm0 xorps %xmm1, %xmm1 ucomiss %xmm1, %xmm0 jbe 0x18ef6a movq -0x28(%rbp), %rax movss 0x8(%rax), %xmm0 movss %xmm0, -0x38(%rbp) jmp 0x18ef86 movq -0x30(%rbp), %rax movq (%rax), %rdi movl -0x20(%rbp), %esi callq 0xc9dd0 movq %rax, %rdi callq 0xc31d0 movss %xmm0, -0x38(%rbp) movss -0x38(%rbp), %xmm0 movq -0x18(%rbp), %rax movslq -0x1c(%rbp), %rcx movss %xmm0, (%rax,%rcx,4) movl -0x20(%rbp), %edx movq -0x10(%rbp), %rax movl -0x1c(%rbp), %ecx movl %ecx, %esi addl $0x1, %esi movl %esi, -0x1c(%rbp) movslq %ecx, %rcx movl %edx, (%rax,%rcx,4) jmp 0x18efb2 jmp 0x18efb4 movl -0x20(%rbp), %eax addl $0x1, %eax movl %eax, -0x20(%rbp) jmp 0x18eeca movl -0x1c(%rbp), %eax addq $0x40, %rsp popq %rbp retq nopl (%rax,%rax)
_ZNK10OpenSubdiv6v3_6_03Bfr21IrregularPatchBuilder28gatherControlVertexSharpnessEPiPf: push rbp mov rbp, rsp sub rsp, 40h mov [rbp+var_8], rdi mov [rbp+var_10], rsi mov [rbp+var_18], rdx mov rax, [rbp+var_8] mov [rbp+var_30], rax mov [rbp+var_1C], 0 mov [rbp+var_20], 0 loc_18EECA: mov rax, [rbp+var_30] mov ecx, [rbp+var_20] mov [rbp+var_34], ecx mov rdi, [rax]; this call __ZNK10OpenSubdiv6v3_6_03Bfr11FaceSurface11GetFaceSizeEv; OpenSubdiv::v3_6_0::Bfr::FaceSurface::GetFaceSize(void) mov ecx, eax mov eax, [rbp+var_34] cmp eax, ecx jge loc_18EFC2 mov rax, [rbp+var_30] mov rdi, [rax]; this mov esi, [rbp+var_20]; int call __ZNK10OpenSubdiv6v3_6_03Bfr11FaceSurface15GetCornerSubsetEi; OpenSubdiv::v3_6_0::Bfr::FaceSurface::GetCornerSubset(int) mov [rbp+var_28], rax mov rdi, [rbp+var_28]; this call __ZNK10OpenSubdiv6v3_6_03Bfr9VertexTag10IsInfSharpEv; OpenSubdiv::v3_6_0::Bfr::VertexTag::IsInfSharp(void) test al, 1 jnz short loc_18EF0B jmp short loc_18EF3A loc_18EF0B: mov rax, [rbp+var_18] movsxd rcx, [rbp+var_1C] movss xmm0, cs:dword_1EA00C movss dword ptr [rax+rcx*4], xmm0 mov edx, [rbp+var_20] mov rax, [rbp+var_10] mov ecx, [rbp+var_1C] mov esi, ecx add esi, 1 mov [rbp+var_1C], esi movsxd rcx, ecx mov [rax+rcx*4], edx jmp short loc_18EFB2 loc_18EF3A: mov rdi, [rbp+var_28]; this call __ZNK10OpenSubdiv6v3_6_03Bfr9VertexTag11IsSemiSharpEv; OpenSubdiv::v3_6_0::Bfr::VertexTag::IsSemiSharp(void) test al, 1 jnz short loc_18EF49 jmp short loc_18EFB0 loc_18EF49: mov rax, [rbp+var_28] movss xmm0, dword ptr [rax+8] xorps xmm1, xmm1 ucomiss xmm0, xmm1 jbe short loc_18EF6A mov rax, [rbp+var_28] movss xmm0, dword ptr [rax+8] movss [rbp+var_38], xmm0 jmp short loc_18EF86 loc_18EF6A: mov rax, [rbp+var_30] mov rdi, [rax]; this mov esi, [rbp+var_20]; int call __ZNK10OpenSubdiv6v3_6_03Bfr11FaceSurface17GetCornerTopologyEi; OpenSubdiv::v3_6_0::Bfr::FaceSurface::GetCornerTopology(int) mov rdi, rax; this call __ZNK10OpenSubdiv6v3_6_03Bfr10FaceVertex18GetVertexSharpnessEv; OpenSubdiv::v3_6_0::Bfr::FaceVertex::GetVertexSharpness(void) movss [rbp+var_38], xmm0 loc_18EF86: movss xmm0, [rbp+var_38] mov rax, [rbp+var_18] movsxd rcx, [rbp+var_1C] movss dword ptr [rax+rcx*4], xmm0 mov edx, [rbp+var_20] mov rax, [rbp+var_10] mov ecx, [rbp+var_1C] mov esi, ecx add esi, 1 mov [rbp+var_1C], esi movsxd rcx, ecx mov [rax+rcx*4], edx loc_18EFB0: jmp short $+2 loc_18EFB2: jmp short $+2 loc_18EFB4: mov eax, [rbp+var_20] add eax, 1 mov [rbp+var_20], eax jmp loc_18EECA loc_18EFC2: mov eax, [rbp+var_1C] add rsp, 40h pop rbp retn
long long OpenSubdiv::v3_6_0::Bfr::IrregularPatchBuilder::gatherControlVertexSharpness( OpenSubdiv::v3_6_0::Bfr::FaceSurface **this, int *a2, float *a3) { int v3; // ecx float v4; // xmm0_4 OpenSubdiv::v3_6_0::Bfr::FaceVertex *CornerTopology; // rax int v6; // ecx float v8; // [rsp+8h] [rbp-38h] float *CornerSubset; // [rsp+18h] [rbp-28h] int i; // [rsp+20h] [rbp-20h] unsigned int v11; // [rsp+24h] [rbp-1Ch] v11 = 0; for ( i = 0; i < (int)OpenSubdiv::v3_6_0::Bfr::FaceSurface::GetFaceSize(*this); ++i ) { CornerSubset = (float *)OpenSubdiv::v3_6_0::Bfr::FaceSurface::GetCornerSubset(*this, i); if ( (OpenSubdiv::v3_6_0::Bfr::VertexTag::IsInfSharp((OpenSubdiv::v3_6_0::Bfr::VertexTag *)CornerSubset) & 1) != 0 ) { a3[v11] = 10.0; v3 = v11++; a2[v3] = i; } else if ( (OpenSubdiv::v3_6_0::Bfr::VertexTag::IsSemiSharp((OpenSubdiv::v3_6_0::Bfr::VertexTag *)CornerSubset) & 1) != 0 ) { v4 = CornerSubset[2]; if ( v4 <= 0.0 ) { CornerTopology = (OpenSubdiv::v3_6_0::Bfr::FaceVertex *)OpenSubdiv::v3_6_0::Bfr::FaceSurface::GetCornerTopology( *this, i); OpenSubdiv::v3_6_0::Bfr::FaceVertex::GetVertexSharpness(CornerTopology); v8 = v4; } else { v8 = CornerSubset[2]; } a3[v11] = v8; v6 = v11++; a2[v6] = i; } } return v11; }
60,884
OpenSubdiv::v3_6_0::Bfr::IrregularPatchBuilder::gatherControlVertexSharpness(int*, float*) const
NVIDIA-RTX[P]OSD-Lite/opensubdiv/bfr/irregularPatchBuilder.cpp
int IrregularPatchBuilder::gatherControlVertexSharpness( int vertIndices[], float vertSharpness[]) const { int nSharpVerts = 0; for (int i = 0; i < _surface.GetFaceSize(); ++i) { FaceVertexSubset const & cSub = _surface.GetCornerSubset(i); if (cSub._tag.IsInfSharp()) { vertSharpness[nSharpVerts] = Sdc::Crease::SHARPNESS_INFINITE; vertIndices[nSharpVerts++] = i; } else if (cSub._tag.IsSemiSharp()) { vertSharpness[nSharpVerts] = (cSub._localSharpness > 0.0f) ? cSub._localSharpness : _surface.GetCornerTopology(i).GetVertexSharpness(); vertIndices[nSharpVerts++] = i; } } return nSharpVerts; }
O1
cpp
OpenSubdiv::v3_6_0::Bfr::IrregularPatchBuilder::gatherControlVertexSharpness(int*, float*) const: movq (%rdi), %rax movq (%rax), %rcx cmpl $0x0, 0x8(%rcx) jle 0x8a898 movq 0x10(%rax), %rdi addq $0x8, %rdi xorl %r8d, %r8d movl $0x4, %r9d movss 0x277c1(%rip), %xmm0 # 0xb2004 xorps %xmm1, %xmm1 xorl %eax, %eax movzwl -0x8(%rdi), %r10d movaps %xmm0, %xmm2 testb $0x2, %r10b jne 0x8a86f testb $0x10, %r10b je 0x8a880 movss (%rdi), %xmm2 ucomiss %xmm1, %xmm2 ja 0x8a86f movq 0x18(%rcx), %r10 movss (%r10,%r9), %xmm2 movslq %eax, %r10 movss %xmm2, (%rdx,%r10,4) leal 0x1(%r10), %eax movl %r8d, (%rsi,%r10,4) incq %r8 movslq 0x8(%rcx), %r10 addq $0xc, %rdi addq $0xe0, %r9 cmpq %r10, %r8 jl 0x8a848 retq xorl %eax, %eax retq nop
_ZNK10OpenSubdiv6v3_6_03Bfr21IrregularPatchBuilder28gatherControlVertexSharpnessEPiPf: mov rax, [rdi] mov rcx, [rax] cmp dword ptr [rcx+8], 0 jle short loc_8A898 mov rdi, [rax+10h] add rdi, 8 xor r8d, r8d mov r9d, 4 movss xmm0, cs:dword_B2004 xorps xmm1, xmm1 xor eax, eax loc_8A848: movzx r10d, word ptr [rdi-8] movaps xmm2, xmm0 test r10b, 2 jnz short loc_8A86F test r10b, 10h jz short loc_8A880 movss xmm2, dword ptr [rdi] ucomiss xmm2, xmm1 ja short loc_8A86F mov r10, [rcx+18h] movss xmm2, dword ptr [r10+r9] loc_8A86F: movsxd r10, eax movss dword ptr [rdx+r10*4], xmm2 lea eax, [r10+1] mov [rsi+r10*4], r8d loc_8A880: inc r8 movsxd r10, dword ptr [rcx+8] add rdi, 0Ch add r9, 0E0h cmp r8, r10 jl short loc_8A848 retn loc_8A898: xor eax, eax retn
long long OpenSubdiv::v3_6_0::Bfr::IrregularPatchBuilder::gatherControlVertexSharpness( long long **this, int *a2, float *a3) { long long v3; // rcx _DWORD *v4; // rdi long long v5; // r8 long long v6; // r9 long long result; // rax __int16 v8; // r10 float v9; // xmm2_4 long long v10; // r10 v3 = **this; if ( *(int *)(v3 + 8) > 0 ) { v4 = (_DWORD *)((*this)[2] + 8); v5 = 0LL; v6 = 4LL; result = 0LL; while ( 1 ) { v8 = *((_WORD *)v4 - 4); v9 = 10.0; if ( (v8 & 2) != 0 ) goto LABEL_7; if ( (v8 & 0x10) != 0 ) break; LABEL_8: ++v5; v4 += 3; v6 += 224LL; if ( v5 >= *(int *)(v3 + 8) ) return result; } v9 = *(float *)v4; if ( *(float *)v4 <= 0.0 ) v9 = *(float *)(*(_QWORD *)(v3 + 24) + v6); LABEL_7: v10 = (int)result; a3[(int)result] = v9; result = (unsigned int)(result + 1); a2[v10] = v5; goto LABEL_8; } return 0LL; }
gatherControlVertexSharpness: MOV RAX,qword ptr [RDI] MOV RCX,qword ptr [RAX] CMP dword ptr [RCX + 0x8],0x0 JLE 0x0018a898 MOV RDI,qword ptr [RAX + 0x10] ADD RDI,0x8 XOR R8D,R8D MOV R9D,0x4 MOVSS XMM0,dword ptr [0x001b2004] XORPS XMM1,XMM1 XOR EAX,EAX LAB_0018a848: MOVZX R10D,word ptr [RDI + -0x8] MOVAPS XMM2,XMM0 TEST R10B,0x2 JNZ 0x0018a86f TEST R10B,0x10 JZ 0x0018a880 MOVSS XMM2,dword ptr [RDI] UCOMISS XMM2,XMM1 JA 0x0018a86f MOV R10,qword ptr [RCX + 0x18] MOVSS XMM2,dword ptr [R10 + R9*0x1] LAB_0018a86f: MOVSXD R10,EAX MOVSS dword ptr [RDX + R10*0x4],XMM2 LEA EAX,[R10 + 0x1] MOV dword ptr [RSI + R10*0x4],R8D LAB_0018a880: INC R8 MOVSXD R10,dword ptr [RCX + 0x8] ADD RDI,0xc ADD R9,0xe0 CMP R8,R10 JL 0x0018a848 RET LAB_0018a898: XOR EAX,EAX RET
/* OpenSubdiv::v3_6_0::Bfr::IrregularPatchBuilder::gatherControlVertexSharpness(int*, float*) const */ int __thiscall OpenSubdiv::v3_6_0::Bfr::IrregularPatchBuilder::gatherControlVertexSharpness (IrregularPatchBuilder *this,int *param_1,float *param_2) { long lVar1; float fVar2; int iVar3; float *pfVar4; long lVar5; long lVar6; float fVar7; fVar2 = DAT_001b2004; lVar1 = **(long **)this; if (*(int *)(lVar1 + 8) < 1) { return 0; } pfVar4 = (float *)((*(long **)this)[2] + 8); lVar5 = 0; lVar6 = 4; iVar3 = 0; do { fVar7 = fVar2; if (((uint)pfVar4[-2] & 2) == 0) { if (((uint)pfVar4[-2] & 0x10) != 0) { fVar7 = *pfVar4; if (fVar7 <= 0.0) { fVar7 = *(float *)(*(long *)(lVar1 + 0x18) + lVar6); } goto LAB_0018a86f; } } else { LAB_0018a86f: param_2[iVar3] = fVar7; param_1[iVar3] = (int)lVar5; iVar3 = iVar3 + 1; } lVar5 = lVar5 + 1; pfVar4 = pfVar4 + 3; lVar6 = lVar6 + 0xe0; if (*(int *)(lVar1 + 8) <= lVar5) { return iVar3; } } while( true ); }
60,885
OpenSubdiv::v3_6_0::Bfr::IrregularPatchBuilder::gatherControlVertexSharpness(int*, float*) const
NVIDIA-RTX[P]OSD-Lite/opensubdiv/bfr/irregularPatchBuilder.cpp
int IrregularPatchBuilder::gatherControlVertexSharpness( int vertIndices[], float vertSharpness[]) const { int nSharpVerts = 0; for (int i = 0; i < _surface.GetFaceSize(); ++i) { FaceVertexSubset const & cSub = _surface.GetCornerSubset(i); if (cSub._tag.IsInfSharp()) { vertSharpness[nSharpVerts] = Sdc::Crease::SHARPNESS_INFINITE; vertIndices[nSharpVerts++] = i; } else if (cSub._tag.IsSemiSharp()) { vertSharpness[nSharpVerts] = (cSub._localSharpness > 0.0f) ? cSub._localSharpness : _surface.GetCornerTopology(i).GetVertexSharpness(); vertIndices[nSharpVerts++] = i; } } return nSharpVerts; }
O2
cpp
OpenSubdiv::v3_6_0::Bfr::IrregularPatchBuilder::gatherControlVertexSharpness(int*, float*) const: pushq %rbx movq (%rdi), %rcx movq (%rcx), %rdi xorl %r8d, %r8d movabsq $0x8, %r9 movabsq $0x4, %r10 movss 0x22dfa(%rip), %xmm0 # 0xbc004 xorps %xmm1, %xmm1 xorl %eax, %eax movslq 0x8(%rdi), %r11 cmpq %r11, %r8 jge 0x99263 movq 0x10(%rcx), %r11 movzwl -0x8(%r11,%r9), %ebx movaps %xmm0, %xmm2 testb $0x2, %bl jne 0x99244 testb $0x10, %bl je 0x99253 movss (%r11,%r9), %xmm2 ucomiss %xmm1, %xmm2 ja 0x99244 movq 0x18(%rdi), %r11 movss (%r11,%r10), %xmm2 movslq %eax, %r11 movss %xmm2, (%rdx,%r11,4) incl %eax movl %r8d, (%rsi,%r11,4) incq %r8 addq $0xc, %r9 addq $0xe0, %r10 jmp 0x9920f popq %rbx retq nop
_ZNK10OpenSubdiv6v3_6_03Bfr21IrregularPatchBuilder28gatherControlVertexSharpnessEPiPf: push rbx mov rcx, [rdi] mov rdi, [rcx] xor r8d, r8d mov r9, 8 mov r10, 4 movss xmm0, cs:dword_BC004 xorps xmm1, xmm1 xor eax, eax loc_9920F: movsxd r11, dword ptr [rdi+8] cmp r8, r11 jge short loc_99263 mov r11, [rcx+10h] movzx ebx, word ptr [r11+r9-8] movaps xmm2, xmm0 test bl, 2 jnz short loc_99244 test bl, 10h jz short loc_99253 movss xmm2, dword ptr [r11+r9] ucomiss xmm2, xmm1 ja short loc_99244 mov r11, [rdi+18h] movss xmm2, dword ptr [r11+r10] loc_99244: movsxd r11, eax movss dword ptr [rdx+r11*4], xmm2 inc eax mov [rsi+r11*4], r8d loc_99253: inc r8 add r9, 0Ch add r10, 0E0h jmp short loc_9920F loc_99263: pop rbx retn
long long OpenSubdiv::v3_6_0::Bfr::IrregularPatchBuilder::gatherControlVertexSharpness( long long **this, int *a2, float *a3) { long long *v3; // rcx long long v4; // rdi long long v5; // r8 long long v6; // r9 long long v7; // r10 long long result; // rax long long v9; // r11 __int16 v10; // bx float v11; // xmm2_4 long long v12; // r11 v3 = *this; v4 = **this; v5 = 0LL; v6 = 8LL; v7 = 4LL; result = 0LL; while ( v5 < *(int *)(v4 + 8) ) { v9 = v3[2]; v10 = *(_WORD *)(v9 + v6 - 8); v11 = 10.0; if ( (v10 & 2) == 0 ) { if ( (v10 & 0x10) == 0 ) goto LABEL_8; v11 = *(float *)(v9 + v6); if ( v11 <= 0.0 ) v11 = *(float *)(*(_QWORD *)(v4 + 24) + v7); } v12 = (int)result; a3[(int)result] = v11; result = (unsigned int)(result + 1); a2[v12] = v5; LABEL_8: ++v5; v6 += 12LL; v7 += 224LL; } return result; }
gatherControlVertexSharpness: PUSH RBX MOV RCX,qword ptr [RDI] MOV RDI,qword ptr [RCX] XOR R8D,R8D MOV R9,0x8 MOV R10,0x4 MOVSS XMM0,dword ptr [0x001bc004] XORPS XMM1,XMM1 XOR EAX,EAX LAB_0019920f: MOVSXD R11,dword ptr [RDI + 0x8] CMP R8,R11 JGE 0x00199263 MOV R11,qword ptr [RCX + 0x10] MOVZX EBX,word ptr [R11 + R9*0x1 + -0x8] MOVAPS XMM2,XMM0 TEST BL,0x2 JNZ 0x00199244 TEST BL,0x10 JZ 0x00199253 MOVSS XMM2,dword ptr [R11 + R9*0x1] UCOMISS XMM2,XMM1 JA 0x00199244 MOV R11,qword ptr [RDI + 0x18] MOVSS XMM2,dword ptr [R11 + R10*0x1] LAB_00199244: MOVSXD R11,EAX MOVSS dword ptr [RDX + R11*0x4],XMM2 INC EAX MOV dword ptr [RSI + R11*0x4],R8D LAB_00199253: INC R8 ADD R9,0xc ADD R10,0xe0 JMP 0x0019920f LAB_00199263: POP RBX RET
/* OpenSubdiv::v3_6_0::Bfr::IrregularPatchBuilder::gatherControlVertexSharpness(int*, float*) const */ void __thiscall OpenSubdiv::v3_6_0::Bfr::IrregularPatchBuilder::gatherControlVertexSharpness (IrregularPatchBuilder *this,int *param_1,float *param_2) { ushort uVar1; long *plVar2; long lVar3; long lVar4; float fVar5; int iVar6; long lVar7; long lVar8; long lVar9; float fVar10; fVar5 = DAT_001bc004; plVar2 = *(long **)this; lVar3 = *plVar2; lVar7 = 0; lVar8 = 8; lVar9 = 4; iVar6 = 0; do { if (*(int *)(lVar3 + 8) <= lVar7) { return; } lVar4 = plVar2[2]; uVar1 = *(ushort *)(lVar4 + -8 + lVar8); fVar10 = fVar5; if ((uVar1 & 2) == 0) { if ((uVar1 & 0x10) != 0) { fVar10 = *(float *)(lVar4 + lVar8); if (fVar10 <= 0.0) { fVar10 = *(float *)(*(long *)(lVar3 + 0x18) + lVar9); } goto LAB_00199244; } } else { LAB_00199244: param_2[iVar6] = fVar10; param_1[iVar6] = (int)lVar7; iVar6 = iVar6 + 1; } lVar7 = lVar7 + 1; lVar8 = lVar8 + 0xc; lVar9 = lVar9 + 0xe0; } while( true ); }
60,886
ma_log_new
eloqsql/storage/maria/ma_write.c
my_bool _ma_log_new(MARIA_PAGE *ma_page, my_bool root_page) { LSN lsn; uchar log_data[FILEID_STORE_SIZE + PAGE_STORE_SIZE * 2 + KEY_NR_STORE_SIZE +1]; uint page_length; LEX_CUSTRING log_array[TRANSLOG_INTERNAL_PARTS + 2]; MARIA_HA *info= ma_page->info; MARIA_SHARE *share= info->s; my_off_t page= ma_page->pos / share->block_size; DBUG_ENTER("_ma_log_new"); DBUG_PRINT("enter", ("page: %lu", (ulong) page)); DBUG_ASSERT(share->now_transactional); /* Store address of new root page */ page_store(log_data + FILEID_STORE_SIZE, page); /* Store link to next unused page */ if (info->key_del_used == 2) page= 0; /* key_del not changed */ else page= ((share->key_del_current == HA_OFFSET_ERROR) ? IMPOSSIBLE_PAGE_NO : share->key_del_current / share->block_size); page_store(log_data + FILEID_STORE_SIZE + PAGE_STORE_SIZE, page); key_nr_store(log_data + FILEID_STORE_SIZE + PAGE_STORE_SIZE*2, ma_page->keyinfo->key_nr); log_data[FILEID_STORE_SIZE + PAGE_STORE_SIZE*2 + KEY_NR_STORE_SIZE]= (uchar) root_page; log_array[TRANSLOG_INTERNAL_PARTS + 0].str= log_data; log_array[TRANSLOG_INTERNAL_PARTS + 0].length= sizeof(log_data); page_length= ma_page->size - LSN_STORE_SIZE; log_array[TRANSLOG_INTERNAL_PARTS + 1].str= ma_page->buff + LSN_STORE_SIZE; log_array[TRANSLOG_INTERNAL_PARTS + 1].length= page_length; /* Remember new page length for future log entires for same page */ ma_page->org_size= ma_page->size; if (translog_write_record(&lsn, LOGREC_REDO_INDEX_NEW_PAGE, info->trn, info, (translog_size_t) (sizeof(log_data) + page_length), TRANSLOG_INTERNAL_PARTS + 2, log_array, log_data, NULL)) DBUG_RETURN(1); DBUG_RETURN(0); }
O3
c
ma_log_new: pushq %rbp movq %rsp, %rbp subq $0x60, %rsp movq %fs:0x28, %rax movq %rax, -0x8(%rbp) movq (%rdi), %rcx movq 0x18(%rdi), %rax movq (%rcx), %r10 movl 0x7bc(%r10), %r9d xorl %r8d, %r8d xorl %edx, %edx divq %r9 movl %eax, -0x14(%rbp) shrq $0x20, %rax movb %al, -0x10(%rbp) cmpb $0x2, 0x67e(%rcx) je 0x65142 movq 0x700(%r10), %rax cmpq $-0x1, %rax je 0x65138 xorl %edx, %edx divq %r9 movq %rax, %r8 jmp 0x65142 movabsq $0xffffffffff, %r8 # imm = 0xFFFFFFFFFF leaq -0x16(%rbp), %rax movl %r8d, 0x7(%rax) shrq $0x20, %r8 movb %r8b, 0xb(%rax) movq 0x8(%rdi), %rdx movb 0xa5(%rdx), %dl movb %dl, 0xc(%rax) movb %sil, 0xd(%rax) leaq -0x60(%rbp), %r10 movq %rax, 0x20(%r10) movq $0xe, 0x28(%r10) movl 0x20(%rdi), %r8d leal -0x7(%r8), %edx movq 0x10(%rdi), %rsi addq $0x7, %rsi movq %rsi, 0x30(%r10) movq %rdx, 0x38(%r10) movl %r8d, 0x24(%rdi) movq 0x8(%rcx), %rdx addl $0x7, %r8d subq $0x8, %rsp leaq -0x20(%rbp), %rdi movl $0xd, %esi movl $0x4, %r9d pushq $0x0 pushq %rax pushq %r10 callq 0x2a8ac addq $0x20, %rsp testb %al, %al setne %al movq %fs:0x28, %rcx cmpq -0x8(%rbp), %rcx jne 0x651d2 addq $0x60, %rsp popq %rbp retq callq 0x29270
_ma_log_new: push rbp mov rbp, rsp sub rsp, 60h mov rax, fs:28h mov [rbp+var_8], rax mov rcx, [rdi] mov rax, [rdi+18h] mov r10, [rcx] mov r9d, [r10+7BCh] xor r8d, r8d xor edx, edx div r9 mov [rbp+var_14], eax shr rax, 20h mov [rbp+var_10], al cmp byte ptr [rcx+67Eh], 2 jz short loc_65142 mov rax, [r10+700h] cmp rax, 0FFFFFFFFFFFFFFFFh jz short loc_65138 xor edx, edx div r9 mov r8, rax jmp short loc_65142 loc_65138: mov r8, 0FFFFFFFFFFh loc_65142: lea rax, [rbp+var_16] mov [rax+7], r8d shr r8, 20h mov [rax+0Bh], r8b mov rdx, [rdi+8] mov dl, [rdx+0A5h] mov [rax+0Ch], dl mov [rax+0Dh], sil lea r10, [rbp+var_60] mov [r10+20h], rax mov qword ptr [r10+28h], 0Eh mov r8d, [rdi+20h] lea edx, [r8-7] mov rsi, [rdi+10h] add rsi, 7 mov [r10+30h], rsi mov [r10+38h], rdx mov [rdi+24h], r8d mov rdx, [rcx+8] add r8d, 7 sub rsp, 8 lea rdi, [rbp+var_20] mov esi, 0Dh mov r9d, 4 push 0 push rax push r10 call translog_write_record add rsp, 20h test al, al setnz al mov rcx, fs:28h cmp rcx, [rbp+var_8] jnz short loc_651D2 add rsp, 60h pop rbp retn loc_651D2: call ___stack_chk_fail
bool ma_log_new(long long **a1, char a2) { long long *v2; // rcx long long v3; // r10 unsigned long long v4; // r9 long long v5; // r8 unsigned long long v6; // rax int v7; // r8d __int128 v9; // [rsp+0h] [rbp-60h] BYREF __int16 *v10; // [rsp+20h] [rbp-40h] long long v11; // [rsp+28h] [rbp-38h] long long v12; // [rsp+30h] [rbp-30h] long long v13; // [rsp+38h] [rbp-28h] _BYTE v14[10]; // [rsp+40h] [rbp-20h] BYREF __int16 v15; // [rsp+4Ah] [rbp-16h] BYREF int v16; // [rsp+4Ch] [rbp-14h] char v17; // [rsp+50h] [rbp-10h] int v18; // [rsp+51h] [rbp-Fh] char v19; // [rsp+55h] [rbp-Bh] char v20; // [rsp+56h] [rbp-Ah] char v21; // [rsp+57h] [rbp-9h] unsigned long long v22; // [rsp+58h] [rbp-8h] v22 = __readfsqword(0x28u); v2 = *a1; v3 = **a1; v4 = *(unsigned int *)(v3 + 1980); v5 = 0LL; v6 = (unsigned long long)a1[3] / v4; v16 = v6; v17 = BYTE4(v6); if ( *((_BYTE *)v2 + 1662) != 2 ) { if ( *(_QWORD *)(v3 + 1792) == -1LL ) v5 = 0xFFFFFFFFFFLL; else v5 = *(_QWORD *)(v3 + 1792) / v4; } v18 = v5; v19 = BYTE4(v5); v20 = *((_BYTE *)a1[1] + 165); v21 = a2; v10 = &v15; v11 = 14LL; v7 = *((_DWORD *)a1 + 8); v12 = (long long)a1[2] + 7; v13 = (unsigned int)(v7 - 7); *((_DWORD *)a1 + 9) = v7; return (unsigned __int8)translog_write_record((unsigned long long)v14, &byte_9[4], v2[1], v2, v7 + 7, 4, &v9, &v15, 0LL) != 0; }
_ma_log_new: PUSH RBP MOV RBP,RSP SUB RSP,0x60 MOV RAX,qword ptr FS:[0x28] MOV qword ptr [RBP + -0x8],RAX MOV RCX,qword ptr [RDI] MOV RAX,qword ptr [RDI + 0x18] MOV R10,qword ptr [RCX] MOV R9D,dword ptr [R10 + 0x7bc] XOR R8D,R8D XOR EDX,EDX DIV R9 MOV dword ptr [RBP + -0x14],EAX SHR RAX,0x20 MOV byte ptr [RBP + -0x10],AL CMP byte ptr [RCX + 0x67e],0x2 JZ 0x00165142 MOV RAX,qword ptr [R10 + 0x700] CMP RAX,-0x1 JZ 0x00165138 XOR EDX,EDX DIV R9 MOV R8,RAX JMP 0x00165142 LAB_00165138: MOV R8,0xffffffffff LAB_00165142: LEA RAX,[RBP + -0x16] MOV dword ptr [RAX + 0x7],R8D SHR R8,0x20 MOV byte ptr [RAX + 0xb],R8B MOV RDX,qword ptr [RDI + 0x8] MOV DL,byte ptr [RDX + 0xa5] MOV byte ptr [RAX + 0xc],DL MOV byte ptr [RAX + 0xd],SIL LEA R10,[RBP + -0x60] MOV qword ptr [R10 + 0x20],RAX MOV qword ptr [R10 + 0x28],0xe MOV R8D,dword ptr [RDI + 0x20] LEA EDX,[R8 + -0x7] MOV RSI,qword ptr [RDI + 0x10] ADD RSI,0x7 MOV qword ptr [R10 + 0x30],RSI MOV qword ptr [R10 + 0x38],RDX MOV dword ptr [RDI + 0x24],R8D MOV RDX,qword ptr [RCX + 0x8] ADD R8D,0x7 SUB RSP,0x8 LEA RDI,[RBP + -0x20] MOV ESI,0xd MOV R9D,0x4 PUSH 0x0 PUSH RAX PUSH R10 CALL 0x0012a8ac ADD RSP,0x20 TEST AL,AL SETNZ AL MOV RCX,qword ptr FS:[0x28] CMP RCX,qword ptr [RBP + -0x8] JNZ 0x001651d2 ADD RSP,0x60 POP RBP RET LAB_001651d2: CALL 0x00129270
bool _ma_log_new(long *param_1,int1 param_2) { int iVar1; long *plVar2; int1 auVar3 [16]; int1 auVar4 [16]; char cVar5; ulong uVar6; ulong uVar7; long in_FS_OFFSET; int1 local_68 [32]; int1 *local_48; int8 local_40; long local_38; ulong local_30; int1 local_28 [10]; int1 local_1e [2]; int4 local_1c; int1 local_18; int4 local_17; int1 local_13; int1 local_12; int1 local_11; long local_10; local_10 = *(long *)(in_FS_OFFSET + 0x28); plVar2 = (long *)*param_1; uVar7 = CONCAT44(0,*(uint *)(*plVar2 + 0x7bc)); uVar6 = 0; auVar3._8_8_ = 0; auVar3._0_8_ = uVar7; auVar4._8_8_ = 0; auVar4._0_8_ = param_1[3]; local_1c = SUB164(auVar4 / auVar3,0); local_18 = SUB161(auVar4 / auVar3,4); if (*(char *)((long)plVar2 + 0x67e) != '\x02') { uVar6 = *(ulong *)(*plVar2 + 0x700); if (uVar6 == 0xffffffffffffffff) { uVar6 = 0xffffffffff; } else { uVar6 = uVar6 / uVar7; } } local_48 = local_1e; local_17 = (int4)uVar6; local_13 = (int1)(uVar6 >> 0x20); local_12 = *(int1 *)(param_1[1] + 0xa5); local_40 = 0xe; iVar1 = (int)param_1[4]; local_30 = (ulong)(iVar1 - 7); local_38 = param_1[2] + 7; *(int *)((long)param_1 + 0x24) = iVar1; local_11 = param_2; cVar5 = translog_write_record(local_28,0xd,plVar2[1],plVar2,iVar1 + 7,4,local_68,local_48,0); if (*(long *)(in_FS_OFFSET + 0x28) == local_10) { return cVar5 != '\0'; } /* WARNING: Subroutine does not return */ __stack_chk_fail(); }
60,887
httplib::Server::~Server()
hkr04[P]cpp-mcp/common/httplib.h
inline Server::~Server() = default;
O1
c
httplib::Server::~Server(): pushq %rbx movq %rdi, %rbx leaq 0x5fed3(%rip), %rax # 0x7bb20 movq %rax, (%rdi) movq 0x328(%rdi), %rax testq %rax, %rax je 0x1bc6d leaq 0x318(%rbx), %rdi movq %rdi, %rsi movl $0x3, %edx callq *%rax leaq 0x2e0(%rbx), %rdi callq 0x1f32a movq 0x2d0(%rbx), %rax testq %rax, %rax je 0x1bc96 leaq 0x2c0(%rbx), %rdi movq %rdi, %rsi movl $0x3, %edx callq *%rax movq 0x2a8(%rbx), %rax testq %rax, %rax je 0x1bcb3 leaq 0x298(%rbx), %rdi movq %rdi, %rsi movl $0x3, %edx callq *%rax movq 0x288(%rbx), %rax testq %rax, %rax je 0x1bcd0 leaq 0x278(%rbx), %rdi movq %rdi, %rsi movl $0x3, %edx callq *%rax movq 0x268(%rbx), %rax testq %rax, %rax je 0x1bced leaq 0x258(%rbx), %rdi movq %rdi, %rsi movl $0x3, %edx callq *%rax movq 0x248(%rbx), %rax testq %rax, %rax je 0x1bd0a leaq 0x238(%rbx), %rdi movq %rdi, %rsi movl $0x3, %edx callq *%rax movq 0x228(%rbx), %rax testq %rax, %rax je 0x1bd27 leaq 0x218(%rbx), %rdi movq %rdi, %rsi movl $0x3, %edx callq *%rax movq 0x208(%rbx), %rax testq %rax, %rax je 0x1bd44 leaq 0x1f8(%rbx), %rdi movq %rdi, %rsi movl $0x3, %edx callq *%rax leaq 0x1e0(%rbx), %rdi callq 0x1bb9a leaq 0x1c8(%rbx), %rdi callq 0x1bbca leaq 0x1b0(%rbx), %rdi callq 0x1bb9a leaq 0x198(%rbx), %rdi callq 0x1bbca leaq 0x180(%rbx), %rdi callq 0x1bb9a leaq 0x168(%rbx), %rdi callq 0x1bbca leaq 0x150(%rbx), %rdi callq 0x1bb9a leaq 0x138(%rbx), %rdi callq 0x1bbca leaq 0x120(%rbx), %rdi callq 0x1bb9a leaq 0x108(%rbx), %rdi callq 0x1bb9a movq 0xf8(%rbx), %rax testq %rax, %rax je 0x1bdd9 leaq 0xe8(%rbx), %rdi movq %rdi, %rsi movl $0x3, %edx callq *%rax movq 0xc8(%rbx), %rdi leaq 0xd8(%rbx), %rax cmpq %rax, %rdi je 0x1bdf7 movq (%rax), %rsi incq %rsi callq 0xa630 leaq 0x98(%rbx), %rdi callq 0x1f3fe leaq 0x80(%rbx), %rdi callq 0x1bbfa movq 0x18(%rbx), %rax testq %rax, %rax je 0x1be29 addq $0x8, %rbx movq %rbx, %rdi movq %rbx, %rsi movl $0x3, %edx callq *%rax popq %rbx retq jmp 0x1be3d jmp 0x1be3d jmp 0x1be3d jmp 0x1be3d jmp 0x1be3d jmp 0x1be3d jmp 0x1be3d jmp 0x1be3d jmp 0x1be3d movq %rax, %rdi callq 0xe901 nop
_ZN7httplib6ServerD2Ev: push rbx mov rbx, rdi lea rax, off_7BB20 mov [rdi], rax mov rax, [rdi+328h] test rax, rax jz short loc_1BC6D lea rdi, [rbx+318h] mov rsi, rdi mov edx, 3 call rax loc_1BC6D: lea rdi, [rbx+2E0h] call _ZNSt10_HashtableINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt4pairIKS5_S5_ESaIS8_ENSt8__detail10_Select1stEN7httplib6detail11case_ignore8equal_toENSE_4hashENSA_18_Mod_range_hashingENSA_20_Default_ranged_hashENSA_20_Prime_rehash_policyENSA_17_Hashtable_traitsILb1ELb0ELb0EEEED2Ev; std::_Hashtable<std::string,std::pair<std::string const,std::string>,std::allocator<std::pair<std::string const,std::string>>,std::__detail::_Select1st,httplib::detail::case_ignore::equal_to,httplib::detail::case_ignore::hash,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<true,false,false>>::~_Hashtable() mov rax, [rbx+2D0h] test rax, rax jz short loc_1BC96 lea rdi, [rbx+2C0h] mov rsi, rdi mov edx, 3 call rax loc_1BC96: mov rax, [rbx+2A8h] test rax, rax jz short loc_1BCB3 lea rdi, [rbx+298h] mov rsi, rdi mov edx, 3 call rax loc_1BCB3: mov rax, [rbx+288h] test rax, rax jz short loc_1BCD0 lea rdi, [rbx+278h] mov rsi, rdi mov edx, 3 call rax loc_1BCD0: mov rax, [rbx+268h] test rax, rax jz short loc_1BCED lea rdi, [rbx+258h] mov rsi, rdi mov edx, 3 call rax loc_1BCED: mov rax, [rbx+248h] test rax, rax jz short loc_1BD0A lea rdi, [rbx+238h] mov rsi, rdi mov edx, 3 call rax loc_1BD0A: mov rax, [rbx+228h] test rax, rax jz short loc_1BD27 lea rdi, [rbx+218h] mov rsi, rdi mov edx, 3 call rax loc_1BD27: mov rax, [rbx+208h] test rax, rax jz short loc_1BD44 lea rdi, [rbx+1F8h] mov rsi, rdi mov edx, 3 call rax loc_1BD44: lea rdi, [rbx+1E0h] call _ZNSt6vectorISt4pairISt10unique_ptrIN7httplib6detail11MatcherBaseESt14default_deleteIS4_EESt8functionIFvRKNS2_7RequestERNS2_8ResponseEEEESaISG_EED2Ev; std::vector<std::pair<std::unique_ptr<httplib::detail::MatcherBase>,std::function<void ()(httplib::Request const&,httplib::Response &)>>>::~vector() lea rdi, [rbx+1C8h] call _ZNSt6vectorISt4pairISt10unique_ptrIN7httplib6detail11MatcherBaseESt14default_deleteIS4_EESt8functionIFvRKNS2_7RequestERNS2_8ResponseERKNS2_13ContentReaderEEEESaISJ_EED2Ev; std::vector<std::pair<std::unique_ptr<httplib::detail::MatcherBase>,std::function<void ()(httplib::Request const&,httplib::Response &,httplib::ContentReader const&)>>>::~vector() lea rdi, [rbx+1B0h] call _ZNSt6vectorISt4pairISt10unique_ptrIN7httplib6detail11MatcherBaseESt14default_deleteIS4_EESt8functionIFvRKNS2_7RequestERNS2_8ResponseEEEESaISG_EED2Ev; std::vector<std::pair<std::unique_ptr<httplib::detail::MatcherBase>,std::function<void ()(httplib::Request const&,httplib::Response &)>>>::~vector() lea rdi, [rbx+198h] call _ZNSt6vectorISt4pairISt10unique_ptrIN7httplib6detail11MatcherBaseESt14default_deleteIS4_EESt8functionIFvRKNS2_7RequestERNS2_8ResponseERKNS2_13ContentReaderEEEESaISJ_EED2Ev; std::vector<std::pair<std::unique_ptr<httplib::detail::MatcherBase>,std::function<void ()(httplib::Request const&,httplib::Response &,httplib::ContentReader const&)>>>::~vector() lea rdi, [rbx+180h] call _ZNSt6vectorISt4pairISt10unique_ptrIN7httplib6detail11MatcherBaseESt14default_deleteIS4_EESt8functionIFvRKNS2_7RequestERNS2_8ResponseEEEESaISG_EED2Ev; std::vector<std::pair<std::unique_ptr<httplib::detail::MatcherBase>,std::function<void ()(httplib::Request const&,httplib::Response &)>>>::~vector() lea rdi, [rbx+168h] call _ZNSt6vectorISt4pairISt10unique_ptrIN7httplib6detail11MatcherBaseESt14default_deleteIS4_EESt8functionIFvRKNS2_7RequestERNS2_8ResponseERKNS2_13ContentReaderEEEESaISJ_EED2Ev; std::vector<std::pair<std::unique_ptr<httplib::detail::MatcherBase>,std::function<void ()(httplib::Request const&,httplib::Response &,httplib::ContentReader const&)>>>::~vector() lea rdi, [rbx+150h] call _ZNSt6vectorISt4pairISt10unique_ptrIN7httplib6detail11MatcherBaseESt14default_deleteIS4_EESt8functionIFvRKNS2_7RequestERNS2_8ResponseEEEESaISG_EED2Ev; std::vector<std::pair<std::unique_ptr<httplib::detail::MatcherBase>,std::function<void ()(httplib::Request const&,httplib::Response &)>>>::~vector() lea rdi, [rbx+138h] call _ZNSt6vectorISt4pairISt10unique_ptrIN7httplib6detail11MatcherBaseESt14default_deleteIS4_EESt8functionIFvRKNS2_7RequestERNS2_8ResponseERKNS2_13ContentReaderEEEESaISJ_EED2Ev; std::vector<std::pair<std::unique_ptr<httplib::detail::MatcherBase>,std::function<void ()(httplib::Request const&,httplib::Response &,httplib::ContentReader const&)>>>::~vector() lea rdi, [rbx+120h] call _ZNSt6vectorISt4pairISt10unique_ptrIN7httplib6detail11MatcherBaseESt14default_deleteIS4_EESt8functionIFvRKNS2_7RequestERNS2_8ResponseEEEESaISG_EED2Ev; std::vector<std::pair<std::unique_ptr<httplib::detail::MatcherBase>,std::function<void ()(httplib::Request const&,httplib::Response &)>>>::~vector() lea rdi, [rbx+108h] call _ZNSt6vectorISt4pairISt10unique_ptrIN7httplib6detail11MatcherBaseESt14default_deleteIS4_EESt8functionIFvRKNS2_7RequestERNS2_8ResponseEEEESaISG_EED2Ev; std::vector<std::pair<std::unique_ptr<httplib::detail::MatcherBase>,std::function<void ()(httplib::Request const&,httplib::Response &)>>>::~vector() mov rax, [rbx+0F8h] test rax, rax jz short loc_1BDD9 lea rdi, [rbx+0E8h] mov rsi, rdi mov edx, 3 call rax loc_1BDD9: mov rdi, [rbx+0C8h]; void * lea rax, [rbx+0D8h] cmp rdi, rax jz short loc_1BDF7 mov rsi, [rax] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_1BDF7: lea rdi, [rbx+98h] call _ZNSt8_Rb_treeINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt4pairIKS5_S5_ESt10_Select1stIS8_ESt4lessIS5_ESaIS8_EED2Ev; std::_Rb_tree<std::string,std::pair<std::string const,std::string>,std::_Select1st<std::pair<std::string const,std::string>>,std::less<std::string>,std::allocator<std::pair<std::string const,std::string>>>::~_Rb_tree() lea rdi, [rbx+80h] call _ZNSt6vectorIN7httplib6Server15MountPointEntryESaIS2_EED2Ev; std::vector<httplib::Server::MountPointEntry>::~vector() mov rax, [rbx+18h] test rax, rax jz short loc_1BE29 add rbx, 8 mov rdi, rbx mov rsi, rbx mov edx, 3 call rax loc_1BE29: pop rbx retn jmp short loc_1BE3D jmp short loc_1BE3D jmp short loc_1BE3D jmp short loc_1BE3D jmp short loc_1BE3D jmp short loc_1BE3D jmp short loc_1BE3D jmp short loc_1BE3D jmp short $+2 loc_1BE3D: mov rdi, rax call __clang_call_terminate
void httplib::Server::~Server(httplib::Server *this) { void ( *v2)(char *, char *, long long); // rax void ( *v3)(char *, char *, long long); // rax void ( *v4)(char *, char *, long long); // rax void ( *v5)(char *, char *, long long); // rax void ( *v6)(char *, char *, long long); // rax void ( *v7)(char *, char *, long long); // rax void ( *v8)(char *, char *, long long); // rax void ( *v9)(char *, char *, long long); // rax void ( *v10)(char *, char *, long long); // rax char *v11; // rdi void ( *v12)(char *, char *, long long); // rax *(_QWORD *)this = off_7BB20; v2 = (void ( *)(char *, char *, long long))*((_QWORD *)this + 101); if ( v2 ) v2((char *)this + 792, (char *)this + 792, 3LL); std::_Hashtable<std::string,std::pair<std::string const,std::string>,std::allocator<std::pair<std::string const,std::string>>,std::__detail::_Select1st,httplib::detail::case_ignore::equal_to,httplib::detail::case_ignore::hash,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<true,false,false>>::~_Hashtable((char *)this + 736); v3 = (void ( *)(char *, char *, long long))*((_QWORD *)this + 90); if ( v3 ) v3((char *)this + 704, (char *)this + 704, 3LL); v4 = (void ( *)(char *, char *, long long))*((_QWORD *)this + 85); if ( v4 ) v4((char *)this + 664, (char *)this + 664, 3LL); v5 = (void ( *)(char *, char *, long long))*((_QWORD *)this + 81); if ( v5 ) v5((char *)this + 632, (char *)this + 632, 3LL); v6 = (void ( *)(char *, char *, long long))*((_QWORD *)this + 77); if ( v6 ) v6((char *)this + 600, (char *)this + 600, 3LL); v7 = (void ( *)(char *, char *, long long))*((_QWORD *)this + 73); if ( v7 ) v7((char *)this + 568, (char *)this + 568, 3LL); v8 = (void ( *)(char *, char *, long long))*((_QWORD *)this + 69); if ( v8 ) v8((char *)this + 536, (char *)this + 536, 3LL); v9 = (void ( *)(char *, char *, long long))*((_QWORD *)this + 65); if ( v9 ) v9((char *)this + 504, (char *)this + 504, 3LL); std::vector<std::pair<std::unique_ptr<httplib::detail::MatcherBase>,std::function<void ()(httplib::Request const&,httplib::Response &)>>>::~vector((_QWORD *)this + 60); std::vector<std::pair<std::unique_ptr<httplib::detail::MatcherBase>,std::function<void ()(httplib::Request const&,httplib::Response &,httplib::ContentReader const&)>>>::~vector((_QWORD *)this + 57); std::vector<std::pair<std::unique_ptr<httplib::detail::MatcherBase>,std::function<void ()(httplib::Request const&,httplib::Response &)>>>::~vector((_QWORD *)this + 54); std::vector<std::pair<std::unique_ptr<httplib::detail::MatcherBase>,std::function<void ()(httplib::Request const&,httplib::Response &,httplib::ContentReader const&)>>>::~vector((_QWORD *)this + 51); std::vector<std::pair<std::unique_ptr<httplib::detail::MatcherBase>,std::function<void ()(httplib::Request const&,httplib::Response &)>>>::~vector((_QWORD *)this + 48); std::vector<std::pair<std::unique_ptr<httplib::detail::MatcherBase>,std::function<void ()(httplib::Request const&,httplib::Response &,httplib::ContentReader const&)>>>::~vector((_QWORD *)this + 45); std::vector<std::pair<std::unique_ptr<httplib::detail::MatcherBase>,std::function<void ()(httplib::Request const&,httplib::Response &)>>>::~vector((_QWORD *)this + 42); std::vector<std::pair<std::unique_ptr<httplib::detail::MatcherBase>,std::function<void ()(httplib::Request const&,httplib::Response &,httplib::ContentReader const&)>>>::~vector((_QWORD *)this + 39); std::vector<std::pair<std::unique_ptr<httplib::detail::MatcherBase>,std::function<void ()(httplib::Request const&,httplib::Response &)>>>::~vector((_QWORD *)this + 36); std::vector<std::pair<std::unique_ptr<httplib::detail::MatcherBase>,std::function<void ()(httplib::Request const&,httplib::Response &)>>>::~vector((_QWORD *)this + 33); v10 = (void ( *)(char *, char *, long long))*((_QWORD *)this + 31); if ( v10 ) v10((char *)this + 232, (char *)this + 232, 3LL); v11 = (char *)*((_QWORD *)this + 25); if ( v11 != (char *)this + 216 ) operator delete(v11, *((_QWORD *)this + 27) + 1LL); std::_Rb_tree<std::string,std::pair<std::string const,std::string>,std::_Select1st<std::pair<std::string const,std::string>>,std::less<std::string>,std::allocator<std::pair<std::string const,std::string>>>::~_Rb_tree((char *)this + 152); std::vector<httplib::Server::MountPointEntry>::~vector((_QWORD *)this + 16); v12 = (void ( *)(char *, char *, long long))*((_QWORD *)this + 3); if ( v12 ) v12((char *)this + 8, (char *)this + 8, 3LL); }
~Server: PUSH RBX MOV RBX,RDI LEA RAX,[0x17bb20] MOV qword ptr [RDI],RAX MOV RAX,qword ptr [RDI + 0x328] TEST RAX,RAX JZ 0x0011bc6d LEA RDI,[RBX + 0x318] LAB_0011bc63: MOV RSI,RDI MOV EDX,0x3 CALL RAX LAB_0011bc6d: LEA RDI,[RBX + 0x2e0] CALL 0x0011f32a MOV RAX,qword ptr [RBX + 0x2d0] TEST RAX,RAX JZ 0x0011bc96 LEA RDI,[RBX + 0x2c0] LAB_0011bc8c: MOV RSI,RDI MOV EDX,0x3 CALL RAX LAB_0011bc96: MOV RAX,qword ptr [RBX + 0x2a8] TEST RAX,RAX JZ 0x0011bcb3 LEA RDI,[RBX + 0x298] LAB_0011bca9: MOV RSI,RDI MOV EDX,0x3 CALL RAX LAB_0011bcb3: MOV RAX,qword ptr [RBX + 0x288] TEST RAX,RAX JZ 0x0011bcd0 LEA RDI,[RBX + 0x278] LAB_0011bcc6: MOV RSI,RDI MOV EDX,0x3 CALL RAX LAB_0011bcd0: MOV RAX,qword ptr [RBX + 0x268] TEST RAX,RAX JZ 0x0011bced LEA RDI,[RBX + 0x258] LAB_0011bce3: MOV RSI,RDI MOV EDX,0x3 CALL RAX LAB_0011bced: MOV RAX,qword ptr [RBX + 0x248] TEST RAX,RAX JZ 0x0011bd0a LEA RDI,[RBX + 0x238] LAB_0011bd00: MOV RSI,RDI MOV EDX,0x3 CALL RAX LAB_0011bd0a: MOV RAX,qword ptr [RBX + 0x228] TEST RAX,RAX JZ 0x0011bd27 LEA RDI,[RBX + 0x218] LAB_0011bd1d: MOV RSI,RDI MOV EDX,0x3 CALL RAX LAB_0011bd27: MOV RAX,qword ptr [RBX + 0x208] TEST RAX,RAX JZ 0x0011bd44 LEA RDI,[RBX + 0x1f8] LAB_0011bd3a: MOV RSI,RDI MOV EDX,0x3 CALL RAX LAB_0011bd44: LEA RDI,[RBX + 0x1e0] CALL 0x0011bb9a LEA RDI,[RBX + 0x1c8] CALL 0x0011bbca LEA RDI,[RBX + 0x1b0] CALL 0x0011bb9a LEA RDI,[RBX + 0x198] CALL 0x0011bbca LEA RDI,[RBX + 0x180] CALL 0x0011bb9a LEA RDI,[RBX + 0x168] CALL 0x0011bbca LEA RDI,[RBX + 0x150] CALL 0x0011bb9a LEA RDI,[RBX + 0x138] CALL 0x0011bbca LEA RDI,[RBX + 0x120] CALL 0x0011bb9a LEA RDI,[RBX + 0x108] CALL 0x0011bb9a MOV RAX,qword ptr [RBX + 0xf8] TEST RAX,RAX JZ 0x0011bdd9 LEA RDI,[RBX + 0xe8] LAB_0011bdcf: MOV RSI,RDI MOV EDX,0x3 CALL RAX LAB_0011bdd9: MOV RDI,qword ptr [RBX + 0xc8] LEA RAX,[RBX + 0xd8] CMP RDI,RAX JZ 0x0011bdf7 MOV RSI,qword ptr [RAX] INC RSI CALL 0x0010a630 LAB_0011bdf7: LEA RDI,[RBX + 0x98] CALL 0x0011f3fe LEA RDI,[RBX + 0x80] CALL 0x0011bbfa MOV RAX,qword ptr [RBX + 0x18] TEST RAX,RAX JZ 0x0011be29 ADD RBX,0x8 LAB_0011be1c: MOV RDI,RBX MOV RSI,RBX MOV EDX,0x3 CALL RAX LAB_0011be29: POP RBX RET
/* httplib::Server::~Server() */ void __thiscall httplib::Server::~Server(Server *this) { *(int ***)this = &PTR__Server_0017bb20; if (*(code **)(this + 0x328) != (code *)0x0) { /* try { // try from 0011bc63 to 0011bc6c has its CatchHandler @ 0011be3d */ (**(code **)(this + 0x328))(this + 0x318,this + 0x318,3); } std:: _Hashtable<std::__cxx11::string,std::pair<std::__cxx11::string_const,std::__cxx11::string>,std::allocator<std::pair<std::__cxx11::string_const,std::__cxx11::string>>,std::__detail::_Select1st,httplib::detail::case_ignore::equal_to,httplib::detail::case_ignore::hash,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<true,false,false>> ::~_Hashtable((_Hashtable<std::__cxx11::string,std::pair<std::__cxx11::string_const,std::__cxx11::string>,std::allocator<std::pair<std::__cxx11::string_const,std::__cxx11::string>>,std::__detail::_Select1st,httplib::detail::case_ignore::equal_to,httplib::detail::case_ignore::hash,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<true,false,false>> *)(this + 0x2e0)); if (*(code **)(this + 0x2d0) != (code *)0x0) { /* try { // try from 0011bc8c to 0011bc95 has its CatchHandler @ 0011be3b */ (**(code **)(this + 0x2d0))(this + 0x2c0,this + 0x2c0,3); } if (*(code **)(this + 0x2a8) != (code *)0x0) { /* try { // try from 0011bca9 to 0011bcb2 has its CatchHandler @ 0011be39 */ (**(code **)(this + 0x2a8))(this + 0x298,this + 0x298,3); } if (*(code **)(this + 0x288) != (code *)0x0) { /* try { // try from 0011bcc6 to 0011bccf has its CatchHandler @ 0011be37 */ (**(code **)(this + 0x288))(this + 0x278,this + 0x278,3); } if (*(code **)(this + 0x268) != (code *)0x0) { /* try { // try from 0011bce3 to 0011bcec has its CatchHandler @ 0011be35 */ (**(code **)(this + 0x268))(this + 600,this + 600,3); } if (*(code **)(this + 0x248) != (code *)0x0) { /* try { // try from 0011bd00 to 0011bd09 has its CatchHandler @ 0011be33 */ (**(code **)(this + 0x248))(this + 0x238,this + 0x238,3); } if (*(code **)(this + 0x228) != (code *)0x0) { /* try { // try from 0011bd1d to 0011bd26 has its CatchHandler @ 0011be31 */ (**(code **)(this + 0x228))(this + 0x218,this + 0x218,3); } if (*(code **)(this + 0x208) != (code *)0x0) { /* try { // try from 0011bd3a to 0011bd43 has its CatchHandler @ 0011be2f */ (**(code **)(this + 0x208))(this + 0x1f8,this + 0x1f8,3); } std:: vector<std::pair<std::unique_ptr<httplib::detail::MatcherBase,std::default_delete<httplib::detail::MatcherBase>>,std::function<void(httplib::Request_const&,httplib::Response&)>>,std::allocator<std::pair<std::unique_ptr<httplib::detail::MatcherBase,std::default_delete<httplib::detail::MatcherBase>>,std::function<void(httplib::Request_const&,httplib::Response&)>>>> ::~vector((vector<std::pair<std::unique_ptr<httplib::detail::MatcherBase,std::default_delete<httplib::detail::MatcherBase>>,std::function<void(httplib::Request_const&,httplib::Response&)>>,std::allocator<std::pair<std::unique_ptr<httplib::detail::MatcherBase,std::default_delete<httplib::detail::MatcherBase>>,std::function<void(httplib::Request_const&,httplib::Response&)>>>> *)(this + 0x1e0)); std:: vector<std::pair<std::unique_ptr<httplib::detail::MatcherBase,std::default_delete<httplib::detail::MatcherBase>>,std::function<void(httplib::Request_const&,httplib::Response&,httplib::ContentReader_const&)>>,std::allocator<std::pair<std::unique_ptr<httplib::detail::MatcherBase,std::default_delete<httplib::detail::MatcherBase>>,std::function<void(httplib::Request_const&,httplib::Response&,httplib::ContentReader_const&)>>>> ::~vector((vector<std::pair<std::unique_ptr<httplib::detail::MatcherBase,std::default_delete<httplib::detail::MatcherBase>>,std::function<void(httplib::Request_const&,httplib::Response&,httplib::ContentReader_const&)>>,std::allocator<std::pair<std::unique_ptr<httplib::detail::MatcherBase,std::default_delete<httplib::detail::MatcherBase>>,std::function<void(httplib::Request_const&,httplib::Response&,httplib::ContentReader_const&)>>>> *)(this + 0x1c8)); std:: vector<std::pair<std::unique_ptr<httplib::detail::MatcherBase,std::default_delete<httplib::detail::MatcherBase>>,std::function<void(httplib::Request_const&,httplib::Response&)>>,std::allocator<std::pair<std::unique_ptr<httplib::detail::MatcherBase,std::default_delete<httplib::detail::MatcherBase>>,std::function<void(httplib::Request_const&,httplib::Response&)>>>> ::~vector((vector<std::pair<std::unique_ptr<httplib::detail::MatcherBase,std::default_delete<httplib::detail::MatcherBase>>,std::function<void(httplib::Request_const&,httplib::Response&)>>,std::allocator<std::pair<std::unique_ptr<httplib::detail::MatcherBase,std::default_delete<httplib::detail::MatcherBase>>,std::function<void(httplib::Request_const&,httplib::Response&)>>>> *)(this + 0x1b0)); std:: vector<std::pair<std::unique_ptr<httplib::detail::MatcherBase,std::default_delete<httplib::detail::MatcherBase>>,std::function<void(httplib::Request_const&,httplib::Response&,httplib::ContentReader_const&)>>,std::allocator<std::pair<std::unique_ptr<httplib::detail::MatcherBase,std::default_delete<httplib::detail::MatcherBase>>,std::function<void(httplib::Request_const&,httplib::Response&,httplib::ContentReader_const&)>>>> ::~vector((vector<std::pair<std::unique_ptr<httplib::detail::MatcherBase,std::default_delete<httplib::detail::MatcherBase>>,std::function<void(httplib::Request_const&,httplib::Response&,httplib::ContentReader_const&)>>,std::allocator<std::pair<std::unique_ptr<httplib::detail::MatcherBase,std::default_delete<httplib::detail::MatcherBase>>,std::function<void(httplib::Request_const&,httplib::Response&,httplib::ContentReader_const&)>>>> *)(this + 0x198)); std:: vector<std::pair<std::unique_ptr<httplib::detail::MatcherBase,std::default_delete<httplib::detail::MatcherBase>>,std::function<void(httplib::Request_const&,httplib::Response&)>>,std::allocator<std::pair<std::unique_ptr<httplib::detail::MatcherBase,std::default_delete<httplib::detail::MatcherBase>>,std::function<void(httplib::Request_const&,httplib::Response&)>>>> ::~vector((vector<std::pair<std::unique_ptr<httplib::detail::MatcherBase,std::default_delete<httplib::detail::MatcherBase>>,std::function<void(httplib::Request_const&,httplib::Response&)>>,std::allocator<std::pair<std::unique_ptr<httplib::detail::MatcherBase,std::default_delete<httplib::detail::MatcherBase>>,std::function<void(httplib::Request_const&,httplib::Response&)>>>> *)(this + 0x180)); std:: vector<std::pair<std::unique_ptr<httplib::detail::MatcherBase,std::default_delete<httplib::detail::MatcherBase>>,std::function<void(httplib::Request_const&,httplib::Response&,httplib::ContentReader_const&)>>,std::allocator<std::pair<std::unique_ptr<httplib::detail::MatcherBase,std::default_delete<httplib::detail::MatcherBase>>,std::function<void(httplib::Request_const&,httplib::Response&,httplib::ContentReader_const&)>>>> ::~vector((vector<std::pair<std::unique_ptr<httplib::detail::MatcherBase,std::default_delete<httplib::detail::MatcherBase>>,std::function<void(httplib::Request_const&,httplib::Response&,httplib::ContentReader_const&)>>,std::allocator<std::pair<std::unique_ptr<httplib::detail::MatcherBase,std::default_delete<httplib::detail::MatcherBase>>,std::function<void(httplib::Request_const&,httplib::Response&,httplib::ContentReader_const&)>>>> *)(this + 0x168)); std:: vector<std::pair<std::unique_ptr<httplib::detail::MatcherBase,std::default_delete<httplib::detail::MatcherBase>>,std::function<void(httplib::Request_const&,httplib::Response&)>>,std::allocator<std::pair<std::unique_ptr<httplib::detail::MatcherBase,std::default_delete<httplib::detail::MatcherBase>>,std::function<void(httplib::Request_const&,httplib::Response&)>>>> ::~vector((vector<std::pair<std::unique_ptr<httplib::detail::MatcherBase,std::default_delete<httplib::detail::MatcherBase>>,std::function<void(httplib::Request_const&,httplib::Response&)>>,std::allocator<std::pair<std::unique_ptr<httplib::detail::MatcherBase,std::default_delete<httplib::detail::MatcherBase>>,std::function<void(httplib::Request_const&,httplib::Response&)>>>> *)(this + 0x150)); std:: vector<std::pair<std::unique_ptr<httplib::detail::MatcherBase,std::default_delete<httplib::detail::MatcherBase>>,std::function<void(httplib::Request_const&,httplib::Response&,httplib::ContentReader_const&)>>,std::allocator<std::pair<std::unique_ptr<httplib::detail::MatcherBase,std::default_delete<httplib::detail::MatcherBase>>,std::function<void(httplib::Request_const&,httplib::Response&,httplib::ContentReader_const&)>>>> ::~vector((vector<std::pair<std::unique_ptr<httplib::detail::MatcherBase,std::default_delete<httplib::detail::MatcherBase>>,std::function<void(httplib::Request_const&,httplib::Response&,httplib::ContentReader_const&)>>,std::allocator<std::pair<std::unique_ptr<httplib::detail::MatcherBase,std::default_delete<httplib::detail::MatcherBase>>,std::function<void(httplib::Request_const&,httplib::Response&,httplib::ContentReader_const&)>>>> *)(this + 0x138)); std:: vector<std::pair<std::unique_ptr<httplib::detail::MatcherBase,std::default_delete<httplib::detail::MatcherBase>>,std::function<void(httplib::Request_const&,httplib::Response&)>>,std::allocator<std::pair<std::unique_ptr<httplib::detail::MatcherBase,std::default_delete<httplib::detail::MatcherBase>>,std::function<void(httplib::Request_const&,httplib::Response&)>>>> ::~vector((vector<std::pair<std::unique_ptr<httplib::detail::MatcherBase,std::default_delete<httplib::detail::MatcherBase>>,std::function<void(httplib::Request_const&,httplib::Response&)>>,std::allocator<std::pair<std::unique_ptr<httplib::detail::MatcherBase,std::default_delete<httplib::detail::MatcherBase>>,std::function<void(httplib::Request_const&,httplib::Response&)>>>> *)(this + 0x120)); std:: vector<std::pair<std::unique_ptr<httplib::detail::MatcherBase,std::default_delete<httplib::detail::MatcherBase>>,std::function<void(httplib::Request_const&,httplib::Response&)>>,std::allocator<std::pair<std::unique_ptr<httplib::detail::MatcherBase,std::default_delete<httplib::detail::MatcherBase>>,std::function<void(httplib::Request_const&,httplib::Response&)>>>> ::~vector((vector<std::pair<std::unique_ptr<httplib::detail::MatcherBase,std::default_delete<httplib::detail::MatcherBase>>,std::function<void(httplib::Request_const&,httplib::Response&)>>,std::allocator<std::pair<std::unique_ptr<httplib::detail::MatcherBase,std::default_delete<httplib::detail::MatcherBase>>,std::function<void(httplib::Request_const&,httplib::Response&)>>>> *)(this + 0x108)); if (*(code **)(this + 0xf8) != (code *)0x0) { /* try { // try from 0011bdcf to 0011bdd8 has its CatchHandler @ 0011be2d */ (**(code **)(this + 0xf8))(this + 0xe8,this + 0xe8,3); } if (*(Server **)(this + 200) != this + 0xd8) { operator_delete(*(Server **)(this + 200),*(long *)(this + 0xd8) + 1); } std:: _Rb_tree<std::__cxx11::string,std::pair<std::__cxx11::string_const,std::__cxx11::string>,std::_Select1st<std::pair<std::__cxx11::string_const,std::__cxx11::string>>,std::less<std::__cxx11::string>,std::allocator<std::pair<std::__cxx11::string_const,std::__cxx11::string>>> ::~_Rb_tree((_Rb_tree<std::__cxx11::string,std::pair<std::__cxx11::string_const,std::__cxx11::string>,std::_Select1st<std::pair<std::__cxx11::string_const,std::__cxx11::string>>,std::less<std::__cxx11::string>,std::allocator<std::pair<std::__cxx11::string_const,std::__cxx11::string>>> *)(this + 0x98)); std::vector<httplib::Server::MountPointEntry,std::allocator<httplib::Server::MountPointEntry>>:: ~vector((vector<httplib::Server::MountPointEntry,std::allocator<httplib::Server::MountPointEntry>> *)(this + 0x80)); if (*(code **)(this + 0x18) != (code *)0x0) { /* try { // try from 0011be1c to 0011be28 has its CatchHandler @ 0011be2b */ (**(code **)(this + 0x18))(this + 8,this + 8,3); } return; }
60,888
get_record_position
eloqsql/storage/maria/ma_blockrec.c
static uchar *get_record_position(MARIA_SHARE *share, uchar *buff, uint record_number, uchar **end_of_data) { uint block_size= share->block_size; uint number_of_records= (uint) buff[DIR_COUNT_OFFSET]; uchar *dir; uchar *data; uint offset, length; #ifdef SANITY_CHECKS if (record_number >= number_of_records || record_number > ((block_size - PAGE_HEADER_SIZE(share) - PAGE_SUFFIX_SIZE) / DIR_ENTRY_SIZE)) { DBUG_PRINT("error", ("Wrong row number: record_number: %u number_of_records: %u", record_number, number_of_records)); return 0; } #endif dir= dir_entry_pos(buff, block_size, record_number); offset= uint2korr(dir); length= uint2korr(dir + 2); #ifdef SANITY_CHECKS if (offset < PAGE_HEADER_SIZE(share) || offset + length > (block_size - number_of_records * DIR_ENTRY_SIZE - PAGE_SUFFIX_SIZE)) { DBUG_PRINT("error", ("Wrong row position: record_number: %u offset: %u " "length: %u number_of_records: %u", record_number, offset, length, number_of_records)); return 0; } #endif data= buff + offset; *end_of_data= data + length; return data; }
O0
c
get_record_position: pushq %rbp movq %rsp, %rbp subq $0x50, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movl %edx, -0x1c(%rbp) movq %rcx, -0x28(%rbp) movq -0x10(%rbp), %rax movl 0x7bc(%rax), %eax movl %eax, -0x2c(%rbp) movq -0x18(%rbp), %rax movzbl 0x8(%rax), %eax movl %eax, -0x30(%rbp) movl -0x1c(%rbp), %eax cmpl -0x30(%rbp), %eax jae 0x58d56 movl -0x1c(%rbp), %eax movl -0x2c(%rbp), %ecx movq -0x10(%rbp), %rdx movl 0xc18(%rdx), %edx addl $0xc, %edx subl %edx, %ecx subl $0x4, %ecx shrl $0x2, %ecx cmpl %ecx, %eax jbe 0x58d67 jmp 0x58d58 jmp 0x58d5a movq $0x0, -0x8(%rbp) jmp 0x58df0 movq -0x18(%rbp), %rdi movl -0x2c(%rbp), %esi movl -0x1c(%rbp), %edx callq 0x55690 movq %rax, -0x38(%rbp) movq -0x38(%rbp), %rax movzwl (%rax), %eax movl %eax, -0x44(%rbp) movq -0x38(%rbp), %rax movzwl 0x2(%rax), %eax movl %eax, -0x48(%rbp) movl -0x44(%rbp), %eax movq -0x10(%rbp), %rcx movl 0xc18(%rcx), %ecx addl $0xc, %ecx cmpl %ecx, %eax jb 0x58dbb movl -0x44(%rbp), %eax addl -0x48(%rbp), %eax movl -0x2c(%rbp), %ecx movl -0x30(%rbp), %edx shll $0x2, %edx subl %edx, %ecx subl $0x4, %ecx cmpl %ecx, %eax jbe 0x58dc9 jmp 0x58dbd jmp 0x58dbf movq $0x0, -0x8(%rbp) jmp 0x58df0 movq -0x18(%rbp), %rax movl -0x44(%rbp), %ecx addq %rcx, %rax movq %rax, -0x40(%rbp) movq -0x40(%rbp), %rcx movl -0x48(%rbp), %eax addq %rax, %rcx movq -0x28(%rbp), %rax movq %rcx, (%rax) movq -0x40(%rbp), %rax movq %rax, -0x8(%rbp) movq -0x8(%rbp), %rax addq $0x50, %rsp popq %rbp retq nopw (%rax,%rax)
get_record_position: push rbp mov rbp, rsp sub rsp, 50h mov [rbp+var_10], rdi mov [rbp+var_18], rsi mov [rbp+var_1C], edx mov [rbp+var_28], rcx mov rax, [rbp+var_10] mov eax, [rax+7BCh] mov [rbp+var_2C], eax mov rax, [rbp+var_18] movzx eax, byte ptr [rax+8] mov [rbp+var_30], eax mov eax, [rbp+var_1C] cmp eax, [rbp+var_30] jnb short loc_58D56 mov eax, [rbp+var_1C] mov ecx, [rbp+var_2C] mov rdx, [rbp+var_10] mov edx, [rdx+0C18h] add edx, 0Ch sub ecx, edx sub ecx, 4 shr ecx, 2 cmp eax, ecx jbe short loc_58D67 loc_58D56: jmp short $+2 loc_58D58: jmp short $+2 loc_58D5A: mov [rbp+var_8], 0 jmp loc_58DF0 loc_58D67: mov rdi, [rbp+var_18] mov esi, [rbp+var_2C] mov edx, [rbp+var_1C] call dir_entry_pos mov [rbp+var_38], rax mov rax, [rbp+var_38] movzx eax, word ptr [rax] mov [rbp+var_44], eax mov rax, [rbp+var_38] movzx eax, word ptr [rax+2] mov [rbp+var_48], eax mov eax, [rbp+var_44] mov rcx, [rbp+var_10] mov ecx, [rcx+0C18h] add ecx, 0Ch cmp eax, ecx jb short loc_58DBB mov eax, [rbp+var_44] add eax, [rbp+var_48] mov ecx, [rbp+var_2C] mov edx, [rbp+var_30] shl edx, 2 sub ecx, edx sub ecx, 4 cmp eax, ecx jbe short loc_58DC9 loc_58DBB: jmp short $+2 loc_58DBD: jmp short $+2 loc_58DBF: mov [rbp+var_8], 0 jmp short loc_58DF0 loc_58DC9: mov rax, [rbp+var_18] mov ecx, [rbp+var_44] add rax, rcx mov [rbp+var_40], rax mov rcx, [rbp+var_40] mov eax, [rbp+var_48] add rcx, rax mov rax, [rbp+var_28] mov [rax], rcx mov rax, [rbp+var_40] mov [rbp+var_8], rax loc_58DF0: mov rax, [rbp+var_8] add rsp, 50h pop rbp retn
long long get_record_position(long long a1, long long a2, unsigned int a3, _QWORD *a4) { unsigned int v5; // [rsp+Ch] [rbp-44h] unsigned __int16 *v6; // [rsp+18h] [rbp-38h] unsigned int v7; // [rsp+20h] [rbp-30h] unsigned int v8; // [rsp+24h] [rbp-2Ch] v8 = *(_DWORD *)(a1 + 1980); v7 = *(unsigned __int8 *)(a2 + 8); if ( a3 >= v7 || a3 > (v8 - (*(_DWORD *)(a1 + 3096) + 12) - 4) >> 2 ) return 0LL; v6 = (unsigned __int16 *)dir_entry_pos(a2, v8, a3); v5 = *v6; if ( v5 < *(_DWORD *)(a1 + 3096) + 12 || v6[1] + v5 > v8 - 4 * v7 - 4 ) return 0LL; *a4 = v6[1] + *v6 + a2; return v5 + a2; }
get_record_position: PUSH RBP MOV RBP,RSP SUB RSP,0x50 MOV qword ptr [RBP + -0x10],RDI MOV qword ptr [RBP + -0x18],RSI MOV dword ptr [RBP + -0x1c],EDX MOV qword ptr [RBP + -0x28],RCX MOV RAX,qword ptr [RBP + -0x10] MOV EAX,dword ptr [RAX + 0x7bc] MOV dword ptr [RBP + -0x2c],EAX MOV RAX,qword ptr [RBP + -0x18] MOVZX EAX,byte ptr [RAX + 0x8] MOV dword ptr [RBP + -0x30],EAX MOV EAX,dword ptr [RBP + -0x1c] CMP EAX,dword ptr [RBP + -0x30] JNC 0x00158d56 MOV EAX,dword ptr [RBP + -0x1c] MOV ECX,dword ptr [RBP + -0x2c] MOV RDX,qword ptr [RBP + -0x10] MOV EDX,dword ptr [RDX + 0xc18] ADD EDX,0xc SUB ECX,EDX SUB ECX,0x4 SHR ECX,0x2 CMP EAX,ECX JBE 0x00158d67 LAB_00158d56: JMP 0x00158d58 LAB_00158d58: JMP 0x00158d5a LAB_00158d5a: MOV qword ptr [RBP + -0x8],0x0 JMP 0x00158df0 LAB_00158d67: MOV RDI,qword ptr [RBP + -0x18] MOV ESI,dword ptr [RBP + -0x2c] MOV EDX,dword ptr [RBP + -0x1c] CALL 0x00155690 MOV qword ptr [RBP + -0x38],RAX MOV RAX,qword ptr [RBP + -0x38] MOVZX EAX,word ptr [RAX] MOV dword ptr [RBP + -0x44],EAX MOV RAX,qword ptr [RBP + -0x38] MOVZX EAX,word ptr [RAX + 0x2] MOV dword ptr [RBP + -0x48],EAX MOV EAX,dword ptr [RBP + -0x44] MOV RCX,qword ptr [RBP + -0x10] MOV ECX,dword ptr [RCX + 0xc18] ADD ECX,0xc CMP EAX,ECX JC 0x00158dbb MOV EAX,dword ptr [RBP + -0x44] ADD EAX,dword ptr [RBP + -0x48] MOV ECX,dword ptr [RBP + -0x2c] MOV EDX,dword ptr [RBP + -0x30] SHL EDX,0x2 SUB ECX,EDX SUB ECX,0x4 CMP EAX,ECX JBE 0x00158dc9 LAB_00158dbb: JMP 0x00158dbd LAB_00158dbd: JMP 0x00158dbf LAB_00158dbf: MOV qword ptr [RBP + -0x8],0x0 JMP 0x00158df0 LAB_00158dc9: MOV RAX,qword ptr [RBP + -0x18] MOV ECX,dword ptr [RBP + -0x44] ADD RAX,RCX MOV qword ptr [RBP + -0x40],RAX MOV RCX,qword ptr [RBP + -0x40] MOV EAX,dword ptr [RBP + -0x48] ADD RCX,RAX MOV RAX,qword ptr [RBP + -0x28] MOV qword ptr [RAX],RCX MOV RAX,qword ptr [RBP + -0x40] MOV qword ptr [RBP + -0x8],RAX LAB_00158df0: MOV RAX,qword ptr [RBP + -0x8] ADD RSP,0x50 POP RBP RET
long get_record_position(long param_1,long param_2,uint param_3,long *param_4) { byte bVar1; int iVar2; uint uVar3; ushort *puVar4; long local_10; iVar2 = *(int *)(param_1 + 0x7bc); bVar1 = *(byte *)(param_2 + 8); if ((param_3 < bVar1) && (param_3 <= (iVar2 - (*(int *)(param_1 + 0xc18) + 0xc)) - 4U >> 2)) { puVar4 = (ushort *)dir_entry_pos(param_2,iVar2,param_3); uVar3 = (uint)*puVar4; if ((uVar3 < *(int *)(param_1 + 0xc18) + 0xcU) || ((iVar2 + (uint)bVar1 * -4) - 4 < uVar3 + puVar4[1])) { local_10 = 0; } else { local_10 = param_2 + (ulong)uVar3; *param_4 = local_10 + (ulong)(uint)puVar4[1]; } } else { local_10 = 0; } return local_10; }
60,889
spdlog::details::mdc_formatter<spdlog::details::scoped_padder>::format(spdlog::details::log_msg const&, tm const&, fmt::v10::basic_memory_buffer<char, 250ul, std::allocator<char>>&)
AlayaLite/build_O0/_deps/spdlog-src/include/spdlog/pattern_formatter-inl.h
void format(const details::log_msg &, const std::tm &, memory_buf_t &dest) override { auto &mdc_map = mdc::get_context(); if (mdc_map.empty()) { ScopedPadder p(0, padinfo_, dest); return; } else { format_mdc(mdc_map, dest); } }
O0
c
spdlog::details::mdc_formatter<spdlog::details::scoped_padder>::format(spdlog::details::log_msg const&, tm const&, fmt::v10::basic_memory_buffer<char, 250ul, std::allocator<char>>&): subq $0x58, %rsp movq %rdi, 0x50(%rsp) movq %rsi, 0x48(%rsp) movq %rdx, 0x40(%rsp) movq %rcx, 0x38(%rsp) movq 0x50(%rsp), %rax movq %rax, (%rsp) callq 0x4c7c0 movq %rax, 0x30(%rsp) movq 0x30(%rsp), %rdi callq 0x4c830 testb $0x1, %al jne 0x6241b jmp 0x62442 movq (%rsp), %rdx addq $0x8, %rdx movq 0x38(%rsp), %rcx leaq 0x8(%rsp), %rdi xorl %eax, %eax movl %eax, %esi callq 0x539a0 leaq 0x8(%rsp), %rdi callq 0x53a90 jmp 0x62455 movq (%rsp), %rdi movq 0x30(%rsp), %rsi movq 0x38(%rsp), %rdx callq 0x62460 addq $0x58, %rsp retq nopw (%rax,%rax)
_ZN6spdlog7details13mdc_formatterINS0_13scoped_padderEE6formatERKNS0_7log_msgERK2tmRN3fmt3v1019basic_memory_bufferIcLm250ESaIcEEE: sub rsp, 58h mov [rsp+58h+var_8], rdi mov [rsp+58h+var_10], rsi mov [rsp+58h+var_18], rdx mov [rsp+58h+var_20], rcx mov rax, [rsp+58h+var_8] mov [rsp+58h+var_58], rax call _ZN6spdlog3mdc11get_contextB5cxx11Ev; spdlog::mdc::get_context(void) mov [rsp+58h+var_28], rax mov rdi, [rsp+58h+var_28] call _ZNKSt3mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES5_St4lessIS5_ESaISt4pairIKS5_S5_EEE5emptyEv; std::map<std::string,std::string>::empty(void) test al, 1 jnz short loc_6241B jmp short loc_62442 loc_6241B: mov rdx, [rsp+58h+var_58] add rdx, 8 mov rcx, [rsp+58h+var_20] lea rdi, [rsp+58h+var_50] xor eax, eax mov esi, eax call _ZN6spdlog7details13scoped_padderC2EmRKNS0_12padding_infoERN3fmt3v1019basic_memory_bufferIcLm250ESaIcEEE; spdlog::details::scoped_padder::scoped_padder(ulong,spdlog::details::padding_info const&,fmt::v10::basic_memory_buffer<char,250ul,std::allocator<char>> &) lea rdi, [rsp+58h+var_50]; this call _ZN6spdlog7details13scoped_padderD2Ev; spdlog::details::scoped_padder::~scoped_padder() jmp short loc_62455 loc_62442: mov rdi, [rsp+58h+var_58] mov rsi, [rsp+58h+var_28] mov rdx, [rsp+58h+var_20] call _ZN6spdlog7details13mdc_formatterINS0_13scoped_padderEE10format_mdcERKSt3mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESA_St4lessISA_ESaISt4pairIKSA_SA_EEERN3fmt3v1019basic_memory_bufferIcLm250ES9_EE; spdlog::details::mdc_formatter<spdlog::details::scoped_padder>::format_mdc(std::map<std::string,std::string> const&,fmt::v10::basic_memory_buffer<char,250ul,std::allocator<char>> &) loc_62455: add rsp, 58h retn
format: SUB RSP,0x58 MOV qword ptr [RSP + 0x50],RDI MOV qword ptr [RSP + 0x48],RSI MOV qword ptr [RSP + 0x40],RDX MOV qword ptr [RSP + 0x38],RCX MOV RAX,qword ptr [RSP + 0x50] MOV qword ptr [RSP],RAX CALL 0x0014c7c0 MOV qword ptr [RSP + 0x30],RAX MOV RDI,qword ptr [RSP + 0x30] CALL 0x0014c830 TEST AL,0x1 JNZ 0x0016241b JMP 0x00162442 LAB_0016241b: MOV RDX,qword ptr [RSP] ADD RDX,0x8 MOV RCX,qword ptr [RSP + 0x38] LEA RDI,[RSP + 0x8] XOR EAX,EAX MOV ESI,EAX CALL 0x001539a0 LEA RDI,[RSP + 0x8] CALL 0x00153a90 JMP 0x00162455 LAB_00162442: MOV RDI,qword ptr [RSP] MOV RSI,qword ptr [RSP + 0x30] MOV RDX,qword ptr [RSP + 0x38] CALL 0x00162460 LAB_00162455: ADD RSP,0x58 RET
/* spdlog::details::mdc_formatter<spdlog::details::scoped_padder>::format(spdlog::details::log_msg const&, tm const&, fmt::v10::basic_memory_buffer<char, 250ul, std::allocator<char> >&) */ void __thiscall spdlog::details::mdc_formatter<spdlog::details::scoped_padder>::format (mdc_formatter<spdlog::details::scoped_padder> *this,log_msg *param_1,tm *param_2, basic_memory_buffer *param_3) { ulong uVar1; scoped_padder local_50 [40]; map *local_28; basic_memory_buffer *local_20; tm *local_18; log_msg *local_10; mdc_formatter<spdlog::details::scoped_padder> *local_8; local_20 = param_3; local_18 = param_2; local_10 = param_1; local_8 = this; local_28 = (map *)mdc::get_context_abi_cxx11_(); uVar1 = std:: map<std::__cxx11::string,std::__cxx11::string,std::less<std::__cxx11::string>,std::allocator<std::pair<std::__cxx11::string_const,std::__cxx11::string>>> ::empty((map<std::__cxx11::string,std::__cxx11::string,std::less<std::__cxx11::string>,std::allocator<std::pair<std::__cxx11::string_const,std::__cxx11::string>>> *)local_28); if ((uVar1 & 1) == 0) { format_mdc(this,local_28,local_20); } else { scoped_padder::scoped_padder(local_50,0,(padding_info *)(this + 8),local_20); scoped_padder::~scoped_padder(local_50); } return; }
60,890
ma_service_thread_control_init
eloqsql/storage/maria/ma_servicethread.c
int ma_service_thread_control_init(MA_SERVICE_THREAD_CONTROL *control) { int res= 0; DBUG_ENTER("ma_service_thread_control_init"); DBUG_PRINT("init", ("control %p", control)); control->inited= TRUE; control->killed= FALSE; res= (mysql_mutex_init(key_SERVICE_THREAD_CONTROL_lock, control->LOCK_control, MY_MUTEX_INIT_SLOW) || mysql_cond_init(key_SERVICE_THREAD_CONTROL_cond, control->COND_control, 0)); DBUG_PRINT("info", ("init: %s", (res ? "Error" : "OK"))); DBUG_RETURN(res); }
O0
c
ma_service_thread_control_init: pushq %rbp movq %rsp, %rbp subq $0x20, %rsp movq %rdi, -0x8(%rbp) movl $0x0, -0xc(%rbp) jmp 0x42895 movq -0x8(%rbp), %rax movb $0x1, 0x9(%rax) movq -0x8(%rbp), %rax movb $0x0, 0x8(%rax) leaq 0x436210(%rip), %rax # 0x478abc movl (%rax), %edi movq -0x8(%rbp), %rax movq 0x10(%rax), %rsi xorl %eax, %eax movl %eax, %edx callq 0x42910 movl %eax, %ecx movb $0x1, %al cmpl $0x0, %ecx movb %al, -0xd(%rbp) jne 0x428ee leaq 0x4361fa(%rip), %rax # 0x478acc movl (%rax), %edi movq -0x8(%rbp), %rax movq 0x18(%rax), %rsi xorl %eax, %eax movl %eax, %edx callq 0x42980 cmpl $0x0, %eax setne %al movb %al, -0xd(%rbp) movb -0xd(%rbp), %al andb $0x1, %al movzbl %al, %eax movl %eax, -0xc(%rbp) jmp 0x428fb jmp 0x428fd movl -0xc(%rbp), %eax movl %eax, -0x14(%rbp) movl -0x14(%rbp), %eax addq $0x20, %rsp popq %rbp retq nopl (%rax)
ma_service_thread_control_init: push rbp mov rbp, rsp sub rsp, 20h mov [rbp+var_8], rdi mov [rbp+var_C], 0 jmp short $+2 loc_42895: mov rax, [rbp+var_8] mov byte ptr [rax+9], 1 mov rax, [rbp+var_8] mov byte ptr [rax+8], 0 lea rax, key_SERVICE_THREAD_CONTROL_lock mov edi, [rax] mov rax, [rbp+var_8] mov rsi, [rax+10h] xor eax, eax mov edx, eax call inline_mysql_mutex_init_1 mov ecx, eax mov al, 1 cmp ecx, 0 mov [rbp+var_D], al jnz short loc_428EE lea rax, key_SERVICE_THREAD_CONTROL_cond mov edi, [rax] mov rax, [rbp+var_8] mov rsi, [rax+18h] xor eax, eax mov edx, eax call inline_mysql_cond_init_0 cmp eax, 0 setnz al mov [rbp+var_D], al loc_428EE: mov al, [rbp+var_D] and al, 1 movzx eax, al mov [rbp+var_C], eax jmp short $+2 loc_428FB: jmp short $+2 loc_428FD: mov eax, [rbp+var_C] mov [rbp+var_14], eax mov eax, [rbp+var_14] add rsp, 20h pop rbp retn
_BOOL8 ma_service_thread_control_init(long long a1) { bool v2; // [rsp+13h] [rbp-Dh] *(_BYTE *)(a1 + 9) = 1; *(_BYTE *)(a1 + 8) = 0; v2 = 1; if ( !(unsigned int)inline_mysql_mutex_init_1(key_SERVICE_THREAD_CONTROL_lock, *(_QWORD *)(a1 + 16), 0LL) ) return (unsigned int)inline_mysql_cond_init_0(key_SERVICE_THREAD_CONTROL_cond, *(_QWORD *)(a1 + 24), 0LL) != 0; return v2; }
ma_service_thread_control_init: PUSH RBP MOV RBP,RSP SUB RSP,0x20 MOV qword ptr [RBP + -0x8],RDI MOV dword ptr [RBP + -0xc],0x0 JMP 0x00142895 LAB_00142895: MOV RAX,qword ptr [RBP + -0x8] MOV byte ptr [RAX + 0x9],0x1 MOV RAX,qword ptr [RBP + -0x8] MOV byte ptr [RAX + 0x8],0x0 LEA RAX,[0x578abc] MOV EDI,dword ptr [RAX] MOV RAX,qword ptr [RBP + -0x8] MOV RSI,qword ptr [RAX + 0x10] XOR EAX,EAX MOV EDX,EAX CALL 0x00142910 MOV ECX,EAX MOV AL,0x1 CMP ECX,0x0 MOV byte ptr [RBP + -0xd],AL JNZ 0x001428ee LEA RAX,[0x578acc] MOV EDI,dword ptr [RAX] MOV RAX,qword ptr [RBP + -0x8] MOV RSI,qword ptr [RAX + 0x18] XOR EAX,EAX MOV EDX,EAX CALL 0x00142980 CMP EAX,0x0 SETNZ AL MOV byte ptr [RBP + -0xd],AL LAB_001428ee: MOV AL,byte ptr [RBP + -0xd] AND AL,0x1 MOVZX EAX,AL MOV dword ptr [RBP + -0xc],EAX JMP 0x001428fb LAB_001428fb: JMP 0x001428fd LAB_001428fd: MOV EAX,dword ptr [RBP + -0xc] MOV dword ptr [RBP + -0x14],EAX MOV EAX,dword ptr [RBP + -0x14] ADD RSP,0x20 POP RBP RET
bool ma_service_thread_control_init(long param_1) { int iVar1; bool local_15; *(int1 *)(param_1 + 9) = 1; *(int1 *)(param_1 + 8) = 0; iVar1 = inline_mysql_mutex_init(key_SERVICE_THREAD_CONTROL_lock,*(int8 *)(param_1 + 0x10),0) ; local_15 = true; if (iVar1 == 0) { iVar1 = inline_mysql_cond_init (key_SERVICE_THREAD_CONTROL_cond,*(int8 *)(param_1 + 0x18),0); local_15 = iVar1 != 0; } return local_15; }
60,891
reaction::Resource<reaction::SimpleExpr, Person>::setField()
reaction/include/reaction/resource.h
void setField() { FieldGraph::getInstance().setField(this->getRawPtr(), this->getShared()); }
O3
c
reaction::Resource<reaction::SimpleExpr, Person>::setField(): pushq %r15 pushq %r14 pushq %r12 pushq %rbx subq $0x18, %rsp movq %rdi, %rbx callq 0x4234 movq %rax, %r14 movq %rbx, %rdi callq 0x5c54 movq %rax, %r15 addq $0x8, %rbx leaq 0x8(%rsp), %r12 movq %r12, %rdi movq %rbx, %rsi callq 0x5fc4 movq %r14, %rdi movq %r15, %rsi movq %r12, %rdx callq 0x5be0 movq 0x10(%rsp), %rdi testq %rdi, %rdi je 0x3872 callq 0x4f16 addq $0x18, %rsp popq %rbx popq %r12 popq %r14 popq %r15 retq movq %rax, %rbx movq 0x10(%rsp), %rdi testq %rdi, %rdi je 0x3890 callq 0x4f16 movq %rbx, %rdi callq 0x2270
_ZN8reaction8ResourceINS_10SimpleExprE6PersonE8setFieldEv: push r15 push r14 push r12 push rbx sub rsp, 18h mov rbx, rdi call _ZN8reaction10FieldGraph11getInstanceEv; reaction::FieldGraph::getInstance(void) mov r14, rax mov rdi, rbx call _ZNK8reaction12ResourceBaseINS_11ComplexExprE6PersonE9getRawPtrEv; reaction::ResourceBase<reaction::ComplexExpr,Person>::getRawPtr(void) mov r15, rax add rbx, 8 lea r12, [rsp+38h+var_30] mov rdi, r12 mov rsi, rbx call _ZNSt12__shared_ptrIN8reaction16ObserverDataNodeELN9__gnu_cxx12_Lock_policyE2EEC2IS1_vEERKSt10__weak_ptrIT_LS3_2EE; std::__shared_ptr<reaction::ObserverDataNode,(__gnu_cxx::_Lock_policy)2>::__shared_ptr<reaction::ObserverDataNode,void>(std::__weak_ptr<reaction::ObserverDataNode,(__gnu_cxx::_Lock_policy)2> const&) mov rdi, r14 mov rsi, r15 mov rdx, r12 call _ZN8reaction10FieldGraph8setFieldEPNS_15FieldStructBaseESt10shared_ptrINS_16ObserverDataNodeEE; reaction::FieldGraph::setField(reaction::FieldStructBase *,std::shared_ptr<reaction::ObserverDataNode>) mov rdi, [rsp+38h+var_28] test rdi, rdi jz short loc_3872 call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void) loc_3872: add rsp, 18h pop rbx pop r12 pop r14 pop r15 retn mov rbx, rax mov rdi, [rsp+arg_8] test rdi, rdi jz short loc_3890 call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void) loc_3890: mov rdi, rbx call __Unwind_Resume
long long reaction::Resource<reaction::SimpleExpr,Person>::setField(reaction::FieldGraph *a1) { long long Instance; // r14 long long RawPtr; // r15 long long result; // rax _BYTE v4[8]; // [rsp+8h] [rbp-30h] BYREF long long v5; // [rsp+10h] [rbp-28h] Instance = reaction::FieldGraph::getInstance(a1); RawPtr = reaction::ResourceBase<reaction::ComplexExpr,Person>::getRawPtr(a1); std::__shared_ptr<reaction::ObserverDataNode,(__gnu_cxx::_Lock_policy)2>::__shared_ptr<reaction::ObserverDataNode,void>( v4, (char *)a1 + 8); result = reaction::FieldGraph::setField(Instance, RawPtr, v4); if ( v5 ) return std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v5); return result; }
setField: PUSH R15 PUSH R14 PUSH R12 PUSH RBX SUB RSP,0x18 MOV RBX,RDI CALL 0x00104234 MOV R14,RAX MOV RDI,RBX CALL 0x00105c54 MOV R15,RAX ADD RBX,0x8 LEA R12,[RSP + 0x8] MOV RDI,R12 MOV RSI,RBX CALL 0x00105fc4 LAB_00103855: MOV RDI,R14 MOV RSI,R15 MOV RDX,R12 CALL 0x00105be0 LAB_00103863: MOV RDI,qword ptr [RSP + 0x10] TEST RDI,RDI JZ 0x00103872 CALL 0x00104f16 LAB_00103872: ADD RSP,0x18 POP RBX POP R12 POP R14 POP R15 RET
/* reaction::Resource<reaction::SimpleExpr, Person>::setField() */ void __thiscall reaction::Resource<reaction::SimpleExpr,Person>::setField (Resource<reaction::SimpleExpr,Person> *this) { FieldGraph *pFVar1; int8 uVar2; __shared_ptr<reaction::ObserverDataNode,(__gnu_cxx::_Lock_policy)2> local_30 [8]; _Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *local_28; pFVar1 = (FieldGraph *)FieldGraph::getInstance(); uVar2 = ResourceBase<reaction::ComplexExpr,Person>::getRawPtr ((ResourceBase<reaction::ComplexExpr,Person> *)this); std::__shared_ptr<reaction::ObserverDataNode,(__gnu_cxx::_Lock_policy)2>:: __shared_ptr<reaction::ObserverDataNode,void>(local_30,(__weak_ptr *)(this + 8)); /* try { // try from 00103855 to 00103862 has its CatchHandler @ 0010387e */ FieldGraph::setField(pFVar1,uVar2,local_30); if (local_28 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) { std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(local_28); } return; }
60,892
my_b_cache_write
eloqsql/mysys/mf_iocache.c
int _my_b_cache_write(IO_CACHE *info, const uchar *Buffer, size_t Count) { if (Buffer != info->write_buffer) { Count= IO_ROUND_DN(Count); if (!Count) return 0; } if (info->seek_not_done) { /* Whenever a function which operates on IO_CACHE flushes/writes some part of the IO_CACHE to disk it will set the property "seek_not_done" to indicate this to other functions operating on the IO_CACHE. */ if (mysql_file_seek(info->file, info->pos_in_file, MY_SEEK_SET, MYF(info->myflags & MY_WME)) == MY_FILEPOS_ERROR) { info->error= -1; return 1; } info->seek_not_done=0; } if (mysql_file_write(info->file, Buffer, Count, info->myflags | MY_NABP)) return info->error= -1; info->pos_in_file+= Count; return 0; }
O3
c
my_b_cache_write: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x58, %rsp movq %rsi, %r15 movq %rdi, %rbx cmpq %rsi, 0x30(%rdi) je 0x96e7c movl $0xfffff000, %eax # imm = 0xFFFFF000 andq %rax, %rdx je 0x96f4f movq %rdx, -0x30(%rbp) cmpl $0x0, 0xe0(%rbx) je 0x96eeb movl 0xd4(%rbx), %r13d movq (%rbx), %rax movq %rax, -0x38(%rbp) movq 0xf8(%rbx), %r12 andl $0x10, %r12d leaq 0x2ef167(%rip), %rax # 0x386010 movq (%rax), %rax leaq -0x80(%rbp), %rdi movl %r13d, %esi movl $0x8, %edx callq *0x158(%rax) testq %rax, %rax jne 0x96fd0 movl %r13d, %edi movq -0x38(%rbp), %rsi xorl %edx, %edx movq %r12, %rcx callq 0xa0b78 movq %rax, %r12 cmpq $-0x1, %r12 je 0x96f53 movl $0x0, 0xe0(%rbx) movl 0xd4(%rbx), %r13d movq 0xf8(%rbx), %r12 orq $0x4, %r12 leaq 0x2ef10c(%rip), %rax # 0x386010 movq (%rax), %rax leaq -0x80(%rbp), %rdi movl %r13d, %esi movl $0x7, %edx callq *0x158(%rax) testq %rax, %rax jne 0x96f71 movl %r13d, %edi movq %r15, %rsi movq -0x30(%rbp), %r13 movq %r13, %rdx movq %r12, %rcx callq 0x2f004 movq %rax, %r15 testq %r15, %r15 je 0x96f4c movl $0xffffffff, 0xe4(%rbx) # imm = 0xFFFFFFFF movl $0xffffffff, %eax # imm = 0xFFFFFFFF jmp 0x96f62 addq %r13, (%rbx) xorl %eax, %eax jmp 0x96f62 movl $0xffffffff, 0xe4(%rbx) # imm = 0xFFFFFFFF movl $0x1, %eax addq $0x58, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq movq %rax, %r14 leaq 0x2ef095(%rip), %rax # 0x386010 movq (%rax), %rax leaq 0x453a1(%rip), %rdx # 0xdc326 movq %r14, %rdi movq -0x30(%rbp), %rsi movl $0x5f6, %ecx # imm = 0x5F6 callq *0x210(%rax) movl %r13d, %edi movq -0x30(%rbp), %r13 movq %r15, %rsi movq %r13, %rdx movq %r12, %rcx callq 0x2f004 movq %rax, %r15 xorl %esi, %esi testq %rax, %rax cmoveq %r13, %rsi leaq 0x2ef051(%rip), %rax # 0x386010 movq (%rax), %rax movq %r14, %rdi callq *0x218(%rax) jmp 0x96f36 movq %rax, %r14 leaq 0x2ef036(%rip), %rax # 0x386010 movq (%rax), %rax leaq 0x45342(%rip), %rdx # 0xdc326 movq %r14, %rdi xorl %esi, %esi movl $0x5ef, %ecx # imm = 0x5EF callq *0x210(%rax) movl %r13d, %edi movq -0x38(%rbp), %rsi xorl %edx, %edx movq %r12, %rcx callq 0xa0b78 movq %rax, %r12 leaq 0x2ef001(%rip), %rax # 0x386010 movq (%rax), %rax movq %r14, %rdi xorl %esi, %esi callq *0x218(%rax) jmp 0x96edb
_my_b_cache_write: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx sub rsp, 58h mov r15, rsi mov rbx, rdi cmp [rdi+30h], rsi jz short loc_96E7C mov eax, 0FFFFF000h and rdx, rax jz loc_96F4F loc_96E7C: mov [rbp+var_30], rdx cmp dword ptr [rbx+0E0h], 0 jz short loc_96EEB mov r13d, [rbx+0D4h] mov rax, [rbx] mov [rbp+var_38], rax mov r12, [rbx+0F8h] and r12d, 10h lea rax, PSI_server mov rax, [rax] lea rdi, [rbp+var_80] mov esi, r13d mov edx, 8 call qword ptr [rax+158h] test rax, rax jnz loc_96FD0 mov edi, r13d mov rsi, [rbp+var_38] xor edx, edx mov rcx, r12 call my_seek mov r12, rax loc_96EDB: cmp r12, 0FFFFFFFFFFFFFFFFh jz short loc_96F53 mov dword ptr [rbx+0E0h], 0 loc_96EEB: mov r13d, [rbx+0D4h] mov r12, [rbx+0F8h] or r12, 4 lea rax, PSI_server mov rax, [rax] lea rdi, [rbp+var_80] mov esi, r13d mov edx, 7 call qword ptr [rax+158h] test rax, rax jnz short loc_96F71 mov edi, r13d mov rsi, r15 mov r13, [rbp+var_30] mov rdx, r13 mov rcx, r12 call my_write mov r15, rax loc_96F36: test r15, r15 jz short loc_96F4C mov dword ptr [rbx+0E4h], 0FFFFFFFFh mov eax, 0FFFFFFFFh jmp short loc_96F62 loc_96F4C: add [rbx], r13 loc_96F4F: xor eax, eax jmp short loc_96F62 loc_96F53: mov dword ptr [rbx+0E4h], 0FFFFFFFFh mov eax, 1 loc_96F62: add rsp, 58h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn loc_96F71: mov r14, rax lea rax, PSI_server mov rax, [rax] lea rdx, aWorkspaceLlm4b_21; "/workspace/llm4binary/github2025/eloqsq"... mov rdi, r14 mov rsi, [rbp+var_30] mov ecx, 5F6h call qword ptr [rax+210h] mov edi, r13d mov r13, [rbp+var_30] mov rsi, r15 mov rdx, r13 mov rcx, r12 call my_write mov r15, rax xor esi, esi test rax, rax cmovz rsi, r13 lea rax, PSI_server mov rax, [rax] mov rdi, r14 call qword ptr [rax+218h] jmp loc_96F36 loc_96FD0: mov r14, rax lea rax, PSI_server mov rax, [rax] lea rdx, aWorkspaceLlm4b_21; "/workspace/llm4binary/github2025/eloqsq"... mov rdi, r14 xor esi, esi mov ecx, 5EFh call qword ptr [rax+210h] mov edi, r13d mov rsi, [rbp+var_38] xor edx, edx mov rcx, r12 call my_seek mov r12, rax lea rax, PSI_server mov rax, [rax] mov rdi, r14 xor esi, esi call qword ptr [rax+218h] jmp loc_96EDB
long long my_b_cache_write(long long *a1, long long a2, long long a3) { unsigned int v4; // r13d long long v5; // r12 long long v6; // rax long long v7; // r12 unsigned int v8; // r13d long long v9; // r12 long long v10; // rax unsigned int v11; // edi long long v12; // r13 long long v13; // r15 long long v15; // r14 unsigned int v16; // edi long long v17; // rsi long long v18; // r14 _BYTE v19[72]; // [rsp+0h] [rbp-80h] BYREF long long v20; // [rsp+48h] [rbp-38h] long long v21; // [rsp+50h] [rbp-30h] if ( a1[6] != a2 ) { a3 = (unsigned int)a3 & 0xFFFFF000; if ( !a3 ) return 0LL; } v21 = a3; if ( !*((_DWORD *)a1 + 56) ) { LABEL_8: v8 = *((_DWORD *)a1 + 53); v9 = a1[31] | 4; v10 = ((long long ( *)(_BYTE *, _QWORD, long long))PSI_server[43])(v19, v8, 7LL); if ( v10 ) { v15 = v10; ((void ( *)(long long, long long, const char *, long long))PSI_server[66])( v10, v21, "/workspace/llm4binary/github2025/eloqsql/mysys/mf_iocache.c", 1526LL); v16 = v8; v12 = v21; v13 = my_write(v16, a2, v21, v9); v17 = 0LL; if ( !v13 ) v17 = v12; ((void ( *)(long long, long long))PSI_server[67])(v15, v17); } else { v11 = v8; v12 = v21; v13 = my_write(v11, a2, v21, v9); } if ( v13 ) { *((_DWORD *)a1 + 57) = -1; return 0xFFFFFFFFLL; } *a1 += v12; return 0LL; } v4 = *((_DWORD *)a1 + 53); v20 = *a1; v5 = a1[31] & 0x10; v6 = ((long long ( *)(_BYTE *, _QWORD, long long))PSI_server[43])(v19, v4, 8LL); if ( v6 ) { v18 = v6; ((void ( *)(long long, _QWORD, const char *, long long))PSI_server[66])( v6, 0LL, "/workspace/llm4binary/github2025/eloqsql/mysys/mf_iocache.c", 1519LL); v7 = my_seek(v4, v20, 0LL, v5); ((void ( *)(long long, _QWORD))PSI_server[67])(v18, 0LL); } else { v7 = my_seek(v4, v20, 0LL, v5); } if ( v7 != -1 ) { *((_DWORD *)a1 + 56) = 0; goto LABEL_8; } *((_DWORD *)a1 + 57) = -1; return 1LL; }
_my_b_cache_write: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x58 MOV R15,RSI MOV RBX,RDI CMP qword ptr [RDI + 0x30],RSI JZ 0x00196e7c MOV EAX,0xfffff000 AND RDX,RAX JZ 0x00196f4f LAB_00196e7c: MOV qword ptr [RBP + -0x30],RDX CMP dword ptr [RBX + 0xe0],0x0 JZ 0x00196eeb MOV R13D,dword ptr [RBX + 0xd4] MOV RAX,qword ptr [RBX] MOV qword ptr [RBP + -0x38],RAX MOV R12,qword ptr [RBX + 0xf8] AND R12D,0x10 LEA RAX,[0x486010] MOV RAX,qword ptr [RAX] LEA RDI,[RBP + -0x80] MOV ESI,R13D MOV EDX,0x8 CALL qword ptr [RAX + 0x158] TEST RAX,RAX JNZ 0x00196fd0 MOV EDI,R13D MOV RSI,qword ptr [RBP + -0x38] XOR EDX,EDX MOV RCX,R12 CALL 0x001a0b78 MOV R12,RAX LAB_00196edb: CMP R12,-0x1 JZ 0x00196f53 MOV dword ptr [RBX + 0xe0],0x0 LAB_00196eeb: MOV R13D,dword ptr [RBX + 0xd4] MOV R12,qword ptr [RBX + 0xf8] OR R12,0x4 LEA RAX,[0x486010] MOV RAX,qword ptr [RAX] LEA RDI,[RBP + -0x80] MOV ESI,R13D MOV EDX,0x7 CALL qword ptr [RAX + 0x158] TEST RAX,RAX JNZ 0x00196f71 MOV EDI,R13D MOV RSI,R15 MOV R13,qword ptr [RBP + -0x30] MOV RDX,R13 MOV RCX,R12 CALL 0x0012f004 MOV R15,RAX LAB_00196f36: TEST R15,R15 JZ 0x00196f4c MOV dword ptr [RBX + 0xe4],0xffffffff MOV EAX,0xffffffff JMP 0x00196f62 LAB_00196f4c: ADD qword ptr [RBX],R13 LAB_00196f4f: XOR EAX,EAX JMP 0x00196f62 LAB_00196f53: MOV dword ptr [RBX + 0xe4],0xffffffff MOV EAX,0x1 LAB_00196f62: ADD RSP,0x58 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET LAB_00196f71: MOV R14,RAX LEA RAX,[0x486010] MOV RAX,qword ptr [RAX] LEA RDX,[0x1dc326] MOV RDI,R14 MOV RSI,qword ptr [RBP + -0x30] MOV ECX,0x5f6 CALL qword ptr [RAX + 0x210] MOV EDI,R13D MOV R13,qword ptr [RBP + -0x30] MOV RSI,R15 MOV RDX,R13 MOV RCX,R12 CALL 0x0012f004 MOV R15,RAX XOR ESI,ESI TEST RAX,RAX CMOVZ RSI,R13 LEA RAX,[0x486010] MOV RAX,qword ptr [RAX] MOV RDI,R14 CALL qword ptr [RAX + 0x218] JMP 0x00196f36 LAB_00196fd0: MOV R14,RAX LEA RAX,[0x486010] MOV RAX,qword ptr [RAX] LEA RDX,[0x1dc326] MOV RDI,R14 XOR ESI,ESI MOV ECX,0x5ef CALL qword ptr [RAX + 0x210] MOV EDI,R13D MOV RSI,qword ptr [RBP + -0x38] XOR EDX,EDX MOV RCX,R12 CALL 0x001a0b78 MOV R12,RAX LEA RAX,[0x486010] MOV RAX,qword ptr [RAX] MOV RDI,R14 XOR ESI,ESI CALL qword ptr [RAX + 0x218] JMP 0x00196edb
int8 _my_b_cache_write(long *param_1,long param_2,ulong param_3) { int4 uVar1; long lVar2; long lVar3; ulong uVar4; uint uVar5; ulong uVar6; int1 local_88 [72]; long local_40; ulong local_38; if ((param_1[6] == param_2) || (param_3 = param_3 & 0xfffff000, param_3 != 0)) { local_38 = param_3; if ((int)param_1[0x1c] != 0) { uVar1 = *(int4 *)((long)param_1 + 0xd4); local_40 = *param_1; uVar5 = (uint)param_1[0x1f] & 0x10; lVar2 = (**(code **)(PSI_server + 0x158))(local_88,uVar1,8); if (lVar2 == 0) { lVar3 = my_seek(uVar1,local_40,0,uVar5); } else { (**(code **)(PSI_server + 0x210)) (lVar2,0,"/workspace/llm4binary/github2025/eloqsql/mysys/mf_iocache.c",0x5ef); lVar3 = my_seek(uVar1,local_40,0,uVar5); (**(code **)(PSI_server + 0x218))(lVar2,0); } if (lVar3 == -1) { *(int4 *)((long)param_1 + 0xe4) = 0xffffffff; return 1; } *(int4 *)(param_1 + 0x1c) = 0; } uVar1 = *(int4 *)((long)param_1 + 0xd4); uVar4 = param_1[0x1f]; lVar2 = (**(code **)(PSI_server + 0x158))(local_88,uVar1,7); uVar6 = local_38; if (lVar2 == 0) { lVar3 = my_write(uVar1,param_2,local_38,uVar4 | 4); } else { (**(code **)(PSI_server + 0x210)) (lVar2,local_38,"/workspace/llm4binary/github2025/eloqsql/mysys/mf_iocache.c",0x5f6) ; uVar6 = local_38; lVar3 = my_write(uVar1,param_2,local_38,uVar4 | 4); uVar4 = 0; if (lVar3 == 0) { uVar4 = uVar6; } (**(code **)(PSI_server + 0x218))(lVar2,uVar4); } if (lVar3 != 0) { *(int4 *)((long)param_1 + 0xe4) = 0xffffffff; return 0xffffffff; } *param_1 = *param_1 + uVar6; } return 0; }
60,893
mysql_stmt_more_results
eloqsql/libmariadb/libmariadb/mariadb_stmt.c
my_bool STDCALL mysql_stmt_more_results(MYSQL_STMT *stmt) { /* MDEV 4604: Server doesn't set MORE_RESULT flag for OutParam result set, so we need to check for SERVER_MORE_RESULTS_EXIST and for SERVER_PS_OUT_PARAMS) */ return (stmt && stmt->mysql && ((stmt->mysql->server_status & SERVER_MORE_RESULTS_EXIST) || (stmt->mysql->server_status & SERVER_PS_OUT_PARAMS))); }
O0
c
mysql_stmt_more_results: pushq %rbp movq %rsp, %rbp movq %rdi, -0x8(%rbp) xorl %eax, %eax cmpq $0x0, -0x8(%rbp) movb %al, -0x9(%rbp) je 0x30f31 movq -0x8(%rbp), %rcx xorl %eax, %eax cmpq $0x0, 0x38(%rcx) movb %al, -0x9(%rbp) je 0x30f31 movq -0x8(%rbp), %rax movq 0x38(%rax), %rax movl 0x380(%rax), %ecx andl $0x8, %ecx movb $0x1, %al cmpl $0x0, %ecx movb %al, -0xa(%rbp) jne 0x30f2b movq -0x8(%rbp), %rax movq 0x38(%rax), %rax movl 0x380(%rax), %eax andl $0x1000, %eax # imm = 0x1000 cmpl $0x0, %eax setne %al movb %al, -0xa(%rbp) movb -0xa(%rbp), %al movb %al, -0x9(%rbp) movb -0x9(%rbp), %al andb $0x1, %al movzbl %al, %eax popq %rbp retq nopl (%rax,%rax)
mysql_stmt_more_results: push rbp mov rbp, rsp mov [rbp+var_8], rdi xor eax, eax cmp [rbp+var_8], 0 mov [rbp+var_9], al jz short loc_30F31 mov rcx, [rbp+var_8] xor eax, eax cmp qword ptr [rcx+38h], 0 mov [rbp+var_9], al jz short loc_30F31 mov rax, [rbp+var_8] mov rax, [rax+38h] mov ecx, [rax+380h] and ecx, 8 mov al, 1 cmp ecx, 0 mov [rbp+var_A], al jnz short loc_30F2B mov rax, [rbp+var_8] mov rax, [rax+38h] mov eax, [rax+380h] and eax, 1000h cmp eax, 0 setnz al mov [rbp+var_A], al loc_30F2B: mov al, [rbp+var_A] mov [rbp+var_9], al loc_30F31: mov al, [rbp+var_9] and al, 1 movzx eax, al pop rbp retn
_BOOL8 mysql_stmt_more_results(long long a1) { bool v2; // [rsp+0h] [rbp-Ah] bool v3; // [rsp+1h] [rbp-9h] v3 = 0; if ( a1 ) { v3 = 0; if ( *(_QWORD *)(a1 + 56) ) { v2 = 1; if ( (*(_DWORD *)(*(_QWORD *)(a1 + 56) + 896LL) & 8) == 0 ) return (*(_DWORD *)(*(_QWORD *)(a1 + 56) + 896LL) & 0x1000) != 0; return v2; } } return v3; }
mysql_stmt_more_results: PUSH RBP MOV RBP,RSP MOV qword ptr [RBP + -0x8],RDI XOR EAX,EAX CMP qword ptr [RBP + -0x8],0x0 MOV byte ptr [RBP + -0x9],AL JZ 0x00130f31 MOV RCX,qword ptr [RBP + -0x8] XOR EAX,EAX CMP qword ptr [RCX + 0x38],0x0 MOV byte ptr [RBP + -0x9],AL JZ 0x00130f31 MOV RAX,qword ptr [RBP + -0x8] MOV RAX,qword ptr [RAX + 0x38] MOV ECX,dword ptr [RAX + 0x380] AND ECX,0x8 MOV AL,0x1 CMP ECX,0x0 MOV byte ptr [RBP + -0xa],AL JNZ 0x00130f2b MOV RAX,qword ptr [RBP + -0x8] MOV RAX,qword ptr [RAX + 0x38] MOV EAX,dword ptr [RAX + 0x380] AND EAX,0x1000 CMP EAX,0x0 SETNZ AL MOV byte ptr [RBP + -0xa],AL LAB_00130f2b: MOV AL,byte ptr [RBP + -0xa] MOV byte ptr [RBP + -0x9],AL LAB_00130f31: MOV AL,byte ptr [RBP + -0x9] AND AL,0x1 MOVZX EAX,AL POP RBP RET
bool mysql_stmt_more_results(long param_1) { int1 local_12; int1 local_11; local_11 = false; if ((param_1 != 0) && (local_11 = false, *(long *)(param_1 + 0x38) != 0)) { local_12 = true; if ((*(uint *)(*(long *)(param_1 + 0x38) + 0x380) & 8) == 0) { local_12 = (*(uint *)(*(long *)(param_1 + 0x38) + 0x380) & 0x1000) != 0; } local_11 = local_12; } return local_11; }
60,894
mysql_stmt_more_results
eloqsql/libmariadb/libmariadb/mariadb_stmt.c
my_bool STDCALL mysql_stmt_more_results(MYSQL_STMT *stmt) { /* MDEV 4604: Server doesn't set MORE_RESULT flag for OutParam result set, so we need to check for SERVER_MORE_RESULTS_EXIST and for SERVER_PS_OUT_PARAMS) */ return (stmt && stmt->mysql && ((stmt->mysql->server_status & SERVER_MORE_RESULTS_EXIST) || (stmt->mysql->server_status & SERVER_PS_OUT_PARAMS))); }
O3
c
mysql_stmt_more_results: testq %rdi, %rdi je 0x249f2 movq 0x38(%rdi), %rax testq %rax, %rax je 0x249f2 pushq %rbp movq %rsp, %rbp movl 0x380(%rax), %ecx movb $0x1, %al testb $0x8, %cl jne 0x249f0 shrl $0xc, %ecx andb $0x1, %cl movl %ecx, %eax popq %rbp retq xorl %eax, %eax retq
mysql_stmt_more_results: test rdi, rdi jz short loc_249F2 mov rax, [rdi+38h] test rax, rax jz short loc_249F2 push rbp mov rbp, rsp mov ecx, [rax+380h] mov al, 1 test cl, 8 jnz short loc_249F0 shr ecx, 0Ch and cl, 1 mov eax, ecx loc_249F0: pop rbp retn loc_249F2: xor eax, eax retn
bool mysql_stmt_more_results(long long a1) { long long v1; // rax int v2; // ecx bool result; // al if ( !a1 ) return 0; v1 = *(_QWORD *)(a1 + 56); if ( !v1 ) return 0; v2 = *(_DWORD *)(v1 + 896); result = 1; if ( (v2 & 8) == 0 ) return (v2 & 0x1000) != 0; return result; }
mysql_stmt_more_results: TEST RDI,RDI JZ 0x001249f2 MOV RAX,qword ptr [RDI + 0x38] TEST RAX,RAX JZ 0x001249f2 PUSH RBP MOV RBP,RSP MOV ECX,dword ptr [RAX + 0x380] MOV AL,0x1 TEST CL,0x8 JNZ 0x001249f0 SHR ECX,0xc AND CL,0x1 MOV EAX,ECX LAB_001249f0: POP RBP RET LAB_001249f2: XOR EAX,EAX RET
ulong mysql_stmt_more_results(long param_1) { long lVar1; ulong uVar2; if ((param_1 != 0) && (lVar1 = *(long *)(param_1 + 0x38), lVar1 != 0)) { uVar2 = CONCAT71((int7)((ulong)lVar1 >> 8),1); if ((*(uint *)(lVar1 + 0x380) & 8) == 0) { uVar2 = (ulong)(*(uint *)(lVar1 + 0x380) >> 0xc) & 0xffffffffffffff01; } return uVar2; } return 0; }
60,895
stbi__resample_row_hv_2(unsigned char*, unsigned char*, unsigned char*, int, int)
7CodeWizard[P]stablediffusion/thirdparty/stb_image.h
static stbi_uc *stbi__resample_row_hv_2(stbi_uc *out, stbi_uc *in_near, stbi_uc *in_far, int w, int hs) { // need to generate 2x2 samples for every one in input int i,t0,t1; if (w == 1) { out[0] = out[1] = stbi__div4(3*in_near[0] + in_far[0] + 2); return out; } t1 = 3*in_near[0] + in_far[0]; out[0] = stbi__div4(t1+2); for (i=1; i < w; ++i) { t0 = t1; t1 = 3*in_near[i]+in_far[i]; out[i*2-1] = stbi__div16(3*t0 + t1 + 8); out[i*2 ] = stbi__div16(3*t1 + t0 + 8); } out[w*2-1] = stbi__div4(t1+2); STBI_NOTUSED(hs); return out; }
O0
c
stbi__resample_row_hv_2(unsigned char*, unsigned char*, unsigned char*, int, int): movq %rdi, -0x10(%rsp) movq %rsi, -0x18(%rsp) movq %rdx, -0x20(%rsp) movl %ecx, -0x24(%rsp) movl %r8d, -0x28(%rsp) cmpl $0x1, -0x24(%rsp) jne 0x1fa1a movq -0x18(%rsp), %rax movzbl (%rax), %eax imull $0x3, %eax, %eax movq -0x20(%rsp), %rcx movzbl (%rcx), %ecx addl %ecx, %eax addl $0x2, %eax sarl $0x2, %eax movb %al, %cl movq -0x10(%rsp), %rax movb %cl, 0x1(%rax) movq -0x10(%rsp), %rax movb %cl, (%rax) movq -0x10(%rsp), %rax movq %rax, -0x8(%rsp) jmp 0x1fb0a movq -0x18(%rsp), %rax movzbl (%rax), %eax imull $0x3, %eax, %eax movq -0x20(%rsp), %rcx movzbl (%rcx), %ecx addl %ecx, %eax movl %eax, -0x34(%rsp) movl -0x34(%rsp), %eax addl $0x2, %eax sarl $0x2, %eax movb %al, %cl movq -0x10(%rsp), %rax movb %cl, (%rax) movl $0x1, -0x2c(%rsp) movl -0x2c(%rsp), %eax cmpl -0x24(%rsp), %eax jge 0x1fae0 movl -0x34(%rsp), %eax movl %eax, -0x30(%rsp) movq -0x18(%rsp), %rax movslq -0x2c(%rsp), %rcx movzbl (%rax,%rcx), %eax imull $0x3, %eax, %eax movq -0x20(%rsp), %rcx movslq -0x2c(%rsp), %rdx movzbl (%rcx,%rdx), %ecx addl %ecx, %eax movl %eax, -0x34(%rsp) imull $0x3, -0x30(%rsp), %eax addl -0x34(%rsp), %eax addl $0x8, %eax sarl $0x4, %eax movb %al, %dl movq -0x10(%rsp), %rax movl -0x2c(%rsp), %ecx shll %ecx subl $0x1, %ecx movslq %ecx, %rcx movb %dl, (%rax,%rcx) imull $0x3, -0x34(%rsp), %eax addl -0x30(%rsp), %eax addl $0x8, %eax sarl $0x4, %eax movb %al, %dl movq -0x10(%rsp), %rax movl -0x2c(%rsp), %ecx shll %ecx movslq %ecx, %rcx movb %dl, (%rax,%rcx) movl -0x2c(%rsp), %eax addl $0x1, %eax movl %eax, -0x2c(%rsp) jmp 0x1fa4e movl -0x34(%rsp), %eax addl $0x2, %eax sarl $0x2, %eax movb %al, %dl movq -0x10(%rsp), %rax movl -0x24(%rsp), %ecx shll %ecx subl $0x1, %ecx movslq %ecx, %rcx movb %dl, (%rax,%rcx) movq -0x10(%rsp), %rax movq %rax, -0x8(%rsp) movq -0x8(%rsp), %rax retq
_ZL23stbi__resample_row_hv_2PhS_S_ii: mov [rsp+var_10], rdi mov [rsp+var_18], rsi mov [rsp+var_20], rdx mov [rsp+var_24], ecx mov [rsp+var_28], r8d cmp [rsp+var_24], 1 jnz short loc_1FA1A mov rax, [rsp+var_18] movzx eax, byte ptr [rax] imul eax, 3 mov rcx, [rsp+var_20] movzx ecx, byte ptr [rcx] add eax, ecx add eax, 2 sar eax, 2 mov cl, al mov rax, [rsp+var_10] mov [rax+1], cl mov rax, [rsp+var_10] mov [rax], cl mov rax, [rsp+var_10] mov [rsp+var_8], rax jmp loc_1FB0A loc_1FA1A: mov rax, [rsp+var_18] movzx eax, byte ptr [rax] imul eax, 3 mov rcx, [rsp+var_20] movzx ecx, byte ptr [rcx] add eax, ecx mov [rsp+var_34], eax mov eax, [rsp+var_34] add eax, 2 sar eax, 2 mov cl, al mov rax, [rsp+var_10] mov [rax], cl mov [rsp+var_2C], 1 loc_1FA4E: mov eax, [rsp+var_2C] cmp eax, [rsp+var_24] jge loc_1FAE0 mov eax, [rsp+var_34] mov [rsp+var_30], eax mov rax, [rsp+var_18] movsxd rcx, [rsp+var_2C] movzx eax, byte ptr [rax+rcx] imul eax, 3 mov rcx, [rsp+var_20] movsxd rdx, [rsp+var_2C] movzx ecx, byte ptr [rcx+rdx] add eax, ecx mov [rsp+var_34], eax imul eax, [rsp+var_30], 3 add eax, [rsp+var_34] add eax, 8 sar eax, 4 mov dl, al mov rax, [rsp+var_10] mov ecx, [rsp+var_2C] shl ecx, 1 sub ecx, 1 movsxd rcx, ecx mov [rax+rcx], dl imul eax, [rsp+var_34], 3 add eax, [rsp+var_30] add eax, 8 sar eax, 4 mov dl, al mov rax, [rsp+var_10] mov ecx, [rsp+var_2C] shl ecx, 1 movsxd rcx, ecx mov [rax+rcx], dl mov eax, [rsp+var_2C] add eax, 1 mov [rsp+var_2C], eax jmp loc_1FA4E loc_1FAE0: mov eax, [rsp+var_34] add eax, 2 sar eax, 2 mov dl, al mov rax, [rsp+var_10] mov ecx, [rsp+var_24] shl ecx, 1 sub ecx, 1 movsxd rcx, ecx mov [rax+rcx], dl mov rax, [rsp+var_10] mov [rsp+var_8], rax loc_1FB0A: mov rax, [rsp+var_8] retn
unsigned __int8 * stbi__resample_row_hv_2( unsigned __int8 *a1, unsigned __int8 *a2, unsigned __int8 *a3, int a4) { int v4; // eax int v6; // [rsp+0h] [rbp-34h] int v7; // [rsp+4h] [rbp-30h] int i; // [rsp+8h] [rbp-2Ch] if ( a4 == 1 ) { v4 = (*a3 + 3 * *a2 + 2) >> 2; a1[1] = v4; *a1 = v4; return a1; } else { v6 = *a3 + 3 * *a2; *a1 = (v6 + 2) >> 2; for ( i = 1; i < a4; ++i ) { v7 = v6; v6 = a3[i] + 3 * a2[i]; a1[2 * i - 1] = (v6 + 3 * v7 + 8) >> 4; a1[2 * i] = (v7 + 3 * v6 + 8) >> 4; } a1[2 * a4 - 1] = (v6 + 2) >> 2; return a1; } }
stbi__resample_row_hv_2: MOV qword ptr [RSP + -0x10],RDI MOV qword ptr [RSP + -0x18],RSI MOV qword ptr [RSP + -0x20],RDX MOV dword ptr [RSP + -0x24],ECX MOV dword ptr [RSP + -0x28],R8D CMP dword ptr [RSP + -0x24],0x1 JNZ 0x0011fa1a MOV RAX,qword ptr [RSP + -0x18] MOVZX EAX,byte ptr [RAX] IMUL EAX,EAX,0x3 MOV RCX,qword ptr [RSP + -0x20] MOVZX ECX,byte ptr [RCX] ADD EAX,ECX ADD EAX,0x2 SAR EAX,0x2 MOV CL,AL MOV RAX,qword ptr [RSP + -0x10] MOV byte ptr [RAX + 0x1],CL MOV RAX,qword ptr [RSP + -0x10] MOV byte ptr [RAX],CL MOV RAX,qword ptr [RSP + -0x10] MOV qword ptr [RSP + -0x8],RAX JMP 0x0011fb0a LAB_0011fa1a: MOV RAX,qword ptr [RSP + -0x18] MOVZX EAX,byte ptr [RAX] IMUL EAX,EAX,0x3 MOV RCX,qword ptr [RSP + -0x20] MOVZX ECX,byte ptr [RCX] ADD EAX,ECX MOV dword ptr [RSP + -0x34],EAX MOV EAX,dword ptr [RSP + -0x34] ADD EAX,0x2 SAR EAX,0x2 MOV CL,AL MOV RAX,qword ptr [RSP + -0x10] MOV byte ptr [RAX],CL MOV dword ptr [RSP + -0x2c],0x1 LAB_0011fa4e: MOV EAX,dword ptr [RSP + -0x2c] CMP EAX,dword ptr [RSP + -0x24] JGE 0x0011fae0 MOV EAX,dword ptr [RSP + -0x34] MOV dword ptr [RSP + -0x30],EAX MOV RAX,qword ptr [RSP + -0x18] MOVSXD RCX,dword ptr [RSP + -0x2c] MOVZX EAX,byte ptr [RAX + RCX*0x1] IMUL EAX,EAX,0x3 MOV RCX,qword ptr [RSP + -0x20] MOVSXD RDX,dword ptr [RSP + -0x2c] MOVZX ECX,byte ptr [RCX + RDX*0x1] ADD EAX,ECX MOV dword ptr [RSP + -0x34],EAX IMUL EAX,dword ptr [RSP + -0x30],0x3 ADD EAX,dword ptr [RSP + -0x34] ADD EAX,0x8 SAR EAX,0x4 MOV DL,AL MOV RAX,qword ptr [RSP + -0x10] MOV ECX,dword ptr [RSP + -0x2c] SHL ECX,0x1 SUB ECX,0x1 MOVSXD RCX,ECX MOV byte ptr [RAX + RCX*0x1],DL IMUL EAX,dword ptr [RSP + -0x34],0x3 ADD EAX,dword ptr [RSP + -0x30] ADD EAX,0x8 SAR EAX,0x4 MOV DL,AL MOV RAX,qword ptr [RSP + -0x10] MOV ECX,dword ptr [RSP + -0x2c] SHL ECX,0x1 MOVSXD RCX,ECX MOV byte ptr [RAX + RCX*0x1],DL MOV EAX,dword ptr [RSP + -0x2c] ADD EAX,0x1 MOV dword ptr [RSP + -0x2c],EAX JMP 0x0011fa4e LAB_0011fae0: MOV EAX,dword ptr [RSP + -0x34] ADD EAX,0x2 SAR EAX,0x2 MOV DL,AL MOV RAX,qword ptr [RSP + -0x10] MOV ECX,dword ptr [RSP + -0x24] SHL ECX,0x1 SUB ECX,0x1 MOVSXD RCX,ECX MOV byte ptr [RAX + RCX*0x1],DL MOV RAX,qword ptr [RSP + -0x10] MOV qword ptr [RSP + -0x8],RAX LAB_0011fb0a: MOV RAX,qword ptr [RSP + -0x8] RET
/* stbi__resample_row_hv_2(unsigned char*, unsigned char*, unsigned char*, int, int) */ uchar * stbi__resample_row_hv_2 (uchar *param_1,uchar *param_2,uchar *param_3,int param_4,int param_5) { uchar uVar1; int iVar2; int local_34; int local_2c; if (param_4 == 1) { uVar1 = (uchar)((int)((uint)*param_2 * 3 + (uint)*param_3 + 2) >> 2); param_1[1] = uVar1; *param_1 = uVar1; } else { local_34 = (uint)*param_2 * 3 + (uint)*param_3; *param_1 = (uchar)(local_34 + 2 >> 2); for (local_2c = 1; local_2c < param_4; local_2c = local_2c + 1) { iVar2 = (uint)param_2[local_2c] * 3 + (uint)param_3[local_2c]; param_1[local_2c * 2 + -1] = (uchar)(local_34 * 3 + iVar2 + 8 >> 4); param_1[local_2c << 1] = (uchar)(iVar2 * 3 + local_34 + 8 >> 4); local_34 = iVar2; } param_1[param_4 * 2 + -1] = (uchar)(local_34 + 2 >> 2); } return param_1; }
60,896
stbi__resample_row_hv_2(unsigned char*, unsigned char*, unsigned char*, int, int)
7CodeWizard[P]stablediffusion/thirdparty/stb_image.h
static stbi_uc *stbi__resample_row_hv_2(stbi_uc *out, stbi_uc *in_near, stbi_uc *in_far, int w, int hs) { // need to generate 2x2 samples for every one in input int i,t0,t1; if (w == 1) { out[0] = out[1] = stbi__div4(3*in_near[0] + in_far[0] + 2); return out; } t1 = 3*in_near[0] + in_far[0]; out[0] = stbi__div4(t1+2); for (i=1; i < w; ++i) { t0 = t1; t1 = 3*in_near[i]+in_far[i]; out[i*2-1] = stbi__div16(3*t0 + t1 + 8); out[i*2 ] = stbi__div16(3*t1 + t0 + 8); } out[w*2-1] = stbi__div4(t1+2); STBI_NOTUSED(hs); return out; }
O1
c
stbi__resample_row_hv_2(unsigned char*, unsigned char*, unsigned char*, int, int): movq %rdi, %rax movzbl (%rsi), %r8d movzbl (%rdx), %edi cmpl $0x1, %ecx jne 0x2b097 movzwl %r8w, %ecx leal (%rcx,%rcx,2), %ecx movzwl %di, %edx addl %edx, %ecx addl $0x2, %ecx shrl $0x2, %ecx movb %cl, 0x1(%rax) movb %cl, (%rax) retq movzwl %r8w, %r8d leal (%r8,%r8,2), %r8d movzwl %di, %r9d leal (%r8,%r9), %edi addl %r9d, %r8d addl $0x2, %r8d shrl $0x2, %r8d movb %r8b, (%rax) cmpl $0x2, %ecx jl 0x2b106 movl %ecx, %r8d movl $0x1, %r10d movzbl (%rsi,%r10), %r9d leal (%r9,%r9,2), %r11d movzbl (%rdx,%r10), %r9d addl %r11d, %r9d leal (%rdi,%rdi,2), %r11d addl %r9d, %r11d addl $0x8, %r11d shrl $0x4, %r11d movb %r11b, -0x1(%rax,%r10,2) leal (%r9,%r9,2), %r11d addl %r11d, %edi addl $0x8, %edi shrl $0x4, %edi movb %dil, (%rax,%r10,2) incq %r10 movl %r9d, %edi cmpq %r10, %r8 jne 0x2b0c3 jmp 0x2b109 movl %edi, %r9d addl $0x2, %r9d shrl $0x2, %r9d movslq %ecx, %rcx movb %r9b, -0x1(%rax,%rcx,2) retq
_ZL23stbi__resample_row_hv_2PhS_S_ii: mov rax, rdi movzx r8d, byte ptr [rsi] movzx edi, byte ptr [rdx] cmp ecx, 1 jnz short loc_2B097 movzx ecx, r8w lea ecx, [rcx+rcx*2] movzx edx, di add ecx, edx add ecx, 2 shr ecx, 2 mov [rax+1], cl mov [rax], cl retn loc_2B097: movzx r8d, r8w lea r8d, [r8+r8*2] movzx r9d, di lea edi, [r8+r9] add r8d, r9d add r8d, 2 shr r8d, 2 mov [rax], r8b cmp ecx, 2 jl short loc_2B106 mov r8d, ecx mov r10d, 1 loc_2B0C3: movzx r9d, byte ptr [rsi+r10] lea r11d, [r9+r9*2] movzx r9d, byte ptr [rdx+r10] add r9d, r11d lea r11d, [rdi+rdi*2] add r11d, r9d add r11d, 8 shr r11d, 4 mov [rax+r10*2-1], r11b lea r11d, [r9+r9*2] add edi, r11d add edi, 8 shr edi, 4 mov [rax+r10*2], dil inc r10 mov edi, r9d cmp r8, r10 jnz short loc_2B0C3 jmp short loc_2B109 loc_2B106: mov r9d, edi loc_2B109: add r9d, 2 shr r9d, 2 movsxd rcx, ecx mov [rax+rcx*2-1], r9b retn
unsigned __int8 * stbi__resample_row_hv_2( unsigned __int8 *a1, unsigned __int8 *a2, unsigned __int8 *a3, int a4) { unsigned __int8 *result; // rax unsigned int v5; // ecx int v6; // edi long long v7; // r10 int v8; // r9d result = a1; if ( a4 == 1 ) { v5 = (*a3 + 3 * (unsigned int)*a2 + 2) >> 2; a1[1] = v5; *a1 = v5; } else { v6 = 3 * *a2 + *a3; *result = (unsigned int)(v6 + 2) >> 2; if ( a4 < 2 ) { v8 = v6; } else { v7 = 1LL; do { v8 = 3 * a2[v7] + a3[v7]; result[2 * v7 - 1] = (unsigned int)(v8 + 3 * v6 + 8) >> 4; result[2 * v7++] = (unsigned int)(3 * v8 + v6 + 8) >> 4; v6 = v8; } while ( a4 != v7 ); } result[2 * a4 - 1] = (unsigned int)(v8 + 2) >> 2; } return result; }
60,897
init_stage_class(unsigned int)
eloqsql/storage/perfschema/pfs_instr_class.cc
int init_stage_class(uint stage_class_sizing) { int result= 0; stage_class_dirty_count= stage_class_allocated_count= 0; stage_class_max= stage_class_sizing; stage_class_lost= 0; if (stage_class_max > 0) { stage_class_array= PFS_MALLOC_ARRAY(& builtin_memory_stage_class, stage_class_max, sizeof(PFS_stage_class), PFS_stage_class, MYF(MY_ZEROFILL)); if (unlikely(stage_class_array == NULL)) return 1; } else stage_class_array= NULL; return result; }
O0
cpp
init_stage_class(unsigned int): pushq %rbp movq %rsp, %rbp subq $0x10, %rsp movl %edi, -0x8(%rbp) movl $0x0, -0xc(%rbp) movl $0x0, 0x3a0ca0(%rip) # 0x3cec1c movl $0x0, 0x3a0c9a(%rip) # 0x3cec20 movl -0x8(%rbp), %eax movq %rax, 0x3a0400(%rip) # 0x3ce390 movq $0x0, 0x3a03fd(%rip) # 0x3ce398 cmpq $0x0, 0x3a03ed(%rip) # 0x3ce390 jbe 0x2dfe9 movq 0x3a03e4(%rip), %rsi # 0x3ce390 leaq 0x3de04d(%rip), %rdi # 0x40c000 movl $0x100, %edx # imm = 0x100 movl $0x20, %ecx callq 0x39270 movq %rax, 0x3a0c5f(%rip) # 0x3cec28 cmpq $0x0, 0x3a0c57(%rip) # 0x3cec28 sete %al andb $0x1, %al movzbl %al, %eax cmpl $0x0, %eax je 0x2dfe7 movl $0x1, -0x4(%rbp) jmp 0x2dffa jmp 0x2dff4 movq $0x0, 0x3a0c34(%rip) # 0x3cec28 movl -0xc(%rbp), %eax movl %eax, -0x4(%rbp) movl -0x4(%rbp), %eax addq $0x10, %rsp popq %rbp retq nopw %cs:(%rax,%rax)
_Z16init_stage_classj: push rbp mov rbp, rsp sub rsp, 10h mov [rbp+var_8], edi mov [rbp+var_C], 0 mov cs:_ZL27stage_class_allocated_count, 0; stage_class_allocated_count mov cs:_ZL23stage_class_dirty_count, 0; stage_class_dirty_count mov eax, [rbp+var_8] mov cs:stage_class_max, rax mov cs:stage_class_lost, 0 cmp cs:stage_class_max, 0 jbe short loc_2DFE9 mov rsi, cs:stage_class_max; unsigned __int64 lea rdi, builtin_memory_stage_class; PFS_builtin_memory_class * mov edx, 100h; unsigned __int64 mov ecx, 20h ; ' '; unsigned __int64 call _Z16pfs_malloc_arrayP24PFS_builtin_memory_classmmm; pfs_malloc_array(PFS_builtin_memory_class *,ulong,ulong,ulong) mov cs:_ZL17stage_class_array, rax; stage_class_array cmp cs:_ZL17stage_class_array, 0; stage_class_array setz al and al, 1 movzx eax, al cmp eax, 0 jz short loc_2DFE7 mov [rbp+var_4], 1 jmp short loc_2DFFA loc_2DFE7: jmp short loc_2DFF4 loc_2DFE9: mov cs:_ZL17stage_class_array, 0; stage_class_array loc_2DFF4: mov eax, [rbp+var_C] mov [rbp+var_4], eax loc_2DFFA: mov eax, [rbp+var_4] add rsp, 10h pop rbp retn
_BOOL8 init_stage_class(unsigned int a1) { stage_class_allocated_count = 0; stage_class_dirty_count = 0; stage_class_max = a1; stage_class_lost = 0LL; if ( !a1 ) { stage_class_array = 0LL; return 0; } stage_class_array = (void *)pfs_malloc_array( (PFS_builtin_memory_class *)&builtin_memory_stage_class, stage_class_max, 0x100uLL, 0x20uLL); return !stage_class_array; }
init_stage_class: PUSH RBP MOV RBP,RSP SUB RSP,0x10 MOV dword ptr [RBP + -0x8],EDI MOV dword ptr [RBP + -0xc],0x0 MOV dword ptr [0x004cec1c],0x0 MOV dword ptr [0x004cec20],0x0 MOV EAX,dword ptr [RBP + -0x8] MOV qword ptr [0x004ce390],RAX MOV qword ptr [0x004ce398],0x0 CMP qword ptr [0x004ce390],0x0 JBE 0x0012dfe9 MOV RSI,qword ptr [0x004ce390] LEA RDI,[0x50c000] MOV EDX,0x100 MOV ECX,0x20 CALL 0x00139270 MOV qword ptr [0x004cec28],RAX CMP qword ptr [0x004cec28],0x0 SETZ AL AND AL,0x1 MOVZX EAX,AL CMP EAX,0x0 JZ 0x0012dfe7 MOV dword ptr [RBP + -0x4],0x1 JMP 0x0012dffa LAB_0012dfe7: JMP 0x0012dff4 LAB_0012dfe9: MOV qword ptr [0x004cec28],0x0 LAB_0012dff4: MOV EAX,dword ptr [RBP + -0xc] MOV dword ptr [RBP + -0x4],EAX LAB_0012dffa: MOV EAX,dword ptr [RBP + -0x4] ADD RSP,0x10 POP RBP RET
/* init_stage_class(unsigned int) */ int4 init_stage_class(uint param_1) { stage_class_allocated_count = 0; stage_class_dirty_count = 0; stage_class_max = (ulong)param_1; stage_class_lost = 0; if (stage_class_max == 0) { stage_class_array = 0; } else { stage_class_array = pfs_malloc_array((PFS_builtin_memory_class *)builtin_memory_stage_class,stage_class_max, 0x100,0x20); if (stage_class_array == 0) { return 1; } } return 0; }
60,898
js_parseInt
bluesky950520[P]quickjs/quickjs.c
static JSValue js_parseInt(JSContext *ctx, JSValue this_val, int argc, JSValue *argv) { const char *str; int radix, flags; JSValue ret; size_t len; str = JS_ToCStringLen(ctx, &len, argv[0]); if (!str) return JS_EXCEPTION; if (JS_ToInt32(ctx, &radix, argv[1])) { JS_FreeCString(ctx, str); return JS_EXCEPTION; } flags = ATOD_TRIM_SPACES; if (radix == 0) { flags |= ATOD_ACCEPT_HEX_PREFIX; // Only 0x and 0X are supported radix = 10; } ret = js_atof(ctx, str, len, NULL, radix, flags); JS_FreeCString(ctx, str); return ret; }
O3
c
js_parseInt: pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x10, %rsp movq %r8, %r13 movq %rdi, %r15 movq (%r8), %rdx movq 0x8(%r8), %rcx leaq 0x8(%rsp), %rsi xorl %r12d, %r12d xorl %r8d, %r8d callq 0x20717 movl $0x6, %ebx testq %rax, %rax je 0x7b058 movq %rax, %r14 movq 0x10(%r13), %rdx movq 0x18(%r13), %rcx cmpl $-0x9, %ecx jb 0x7b01d incl (%rdx) leaq 0x4(%rsp), %rsi movq %r15, %rdi callq 0x27408 testl %eax, %eax je 0x7b05c movq 0x18(%r15), %rdi movl -0x18(%r14), %eax leal -0x1(%rax), %ecx movl %ecx, -0x18(%r14) cmpl $0x1, %eax jg 0x7b055 addq $-0x18, %r14 movq %r14, %rsi movq $-0x7, %rdx callq 0x20d90 xorl %r12d, %r12d xorl %eax, %eax jmp 0x7b0cc movl 0x4(%rsp), %eax xorl %r9d, %r9d testl %eax, %eax movl $0xa, %r8d cmovnel %eax, %r8d sete %r9b shll $0x5, %r9d incl %r9d movq 0x8(%rsp), %rdx movq %r15, %rdi movq %r14, %rsi xorl %ecx, %ecx callq 0x3f179 movq %rax, %r12 movq %rdx, %rbx movq 0x18(%r15), %rdi movl -0x18(%r14), %eax leal -0x1(%rax), %ecx movl %ecx, -0x18(%r14) cmpl $0x1, %eax jg 0x7b0b9 addq $-0x18, %r14 movq %r14, %rsi movq $-0x7, %rdx callq 0x20d90 movabsq $-0x100000000, %rcx # imm = 0xFFFFFFFF00000000 movq %r12, %rax andq %rcx, %rax movl %r12d, %r12d orq %rax, %r12 movq %r12, %rax movq %rbx, %rdx addq $0x10, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 retq
js_parseInt: push r15 push r14 push r13 push r12 push rbx sub rsp, 10h mov r13, r8 mov r15, rdi mov rdx, [r8] mov rcx, [r8+8] lea rsi, [rsp+38h+var_30] xor r12d, r12d xor r8d, r8d call JS_ToCStringLen2 mov ebx, 6 test rax, rax jz short loc_7B058 mov r14, rax mov rdx, [r13+10h] mov rcx, [r13+18h] cmp ecx, 0FFFFFFF7h jb short loc_7B01D inc dword ptr [rdx] loc_7B01D: lea rsi, [rsp+38h+var_34] mov rdi, r15 call JS_ToInt32Free test eax, eax jz short loc_7B05C mov rdi, [r15+18h] mov eax, [r14-18h] lea ecx, [rax-1] mov [r14-18h], ecx cmp eax, 1 jg short loc_7B055 add r14, 0FFFFFFFFFFFFFFE8h mov rsi, r14 mov rdx, 0FFFFFFFFFFFFFFF9h call js_free_value_rt loc_7B055: xor r12d, r12d loc_7B058: xor eax, eax jmp short loc_7B0CC loc_7B05C: mov eax, [rsp+38h+var_34] xor r9d, r9d test eax, eax mov r8d, 0Ah cmovnz r8d, eax setz r9b shl r9d, 5 inc r9d mov rdx, [rsp+38h+var_30] mov rdi, r15 mov rsi, r14 xor ecx, ecx call js_atof mov r12, rax mov rbx, rdx mov rdi, [r15+18h] mov eax, [r14-18h] lea ecx, [rax-1] mov [r14-18h], ecx cmp eax, 1 jg short loc_7B0B9 add r14, 0FFFFFFFFFFFFFFE8h mov rsi, r14 mov rdx, 0FFFFFFFFFFFFFFF9h call js_free_value_rt loc_7B0B9: mov rcx, 0FFFFFFFF00000000h mov rax, r12 and rax, rcx mov r12d, r12d loc_7B0CC: or r12, rax mov rax, r12 mov rdx, rbx add rsp, 10h pop rbx pop r12 pop r13 pop r14 pop r15 retn
unsigned long long js_parseInt(long long a1, long long a2, long long a3, long long a4, long long a5) { unsigned long long v6; // r12 int *v7; // rax unsigned __int8 *v8; // r14 _DWORD *v9; // rdx long long v10; // rcx long long v11; // r8 long long v12; // r9 long long v13; // rdi int v14; // eax long long v15; // rcx unsigned long long v16; // rax int v17; // r9d long long v18; // r8 long long v19; // r8 long long v20; // r9 long long v21; // rdi int v22; // eax long long v23; // rcx unsigned int v25; // [rsp+4h] [rbp-34h] BYREF long long v26[6]; // [rsp+8h] [rbp-30h] BYREF v6 = 0LL; v7 = JS_ToCStringLen2(a1, v26, *(_DWORD **)a5, *(_QWORD *)(a5 + 8), 0); if ( !v7 ) { LABEL_8: v16 = 0LL; return v16 | v6; } v8 = (unsigned __int8 *)v7; v9 = *(_DWORD **)(a5 + 16); v10 = *(_QWORD *)(a5 + 24); if ( (unsigned int)v10 >= 0xFFFFFFF7 ) ++*v9; if ( (unsigned int)JS_ToInt32Free(a1, (int *)&v25, (unsigned long long)v9, v10) ) { v13 = *(_QWORD *)(a1 + 24); v14 = *((_DWORD *)v8 - 6); v15 = (unsigned int)(v14 - 1); *((_DWORD *)v8 - 6) = v15; if ( v14 <= 1 ) js_free_value_rt(v13, (_QWORD *)v8 - 3, -7LL, v15, v11, v12); v6 = 0LL; goto LABEL_8; } v17 = 0; v18 = 10LL; if ( v25 ) v18 = v25; LOBYTE(v17) = v25 == 0; v6 = (unsigned long long)js_atof(a1, v8, v26[0], 0LL, v18, (unsigned int)(32 * v17 + 1)); v21 = *(_QWORD *)(a1 + 24); v22 = *((_DWORD *)v8 - 6); v23 = (unsigned int)(v22 - 1); *((_DWORD *)v8 - 6) = v23; if ( v22 <= 1 ) js_free_value_rt(v21, (_QWORD *)v8 - 3, -7LL, v23, v19, v20); v16 = v6 & 0xFFFFFFFF00000000LL; v6 = (unsigned int)v6; return v16 | v6; }
js_parseInt: PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x10 MOV R13,R8 MOV R15,RDI MOV RDX,qword ptr [R8] MOV RCX,qword ptr [R8 + 0x8] LEA RSI,[RSP + 0x8] XOR R12D,R12D XOR R8D,R8D CALL 0x00120717 MOV EBX,0x6 TEST RAX,RAX JZ 0x0017b058 MOV R14,RAX MOV RDX,qword ptr [R13 + 0x10] MOV RCX,qword ptr [R13 + 0x18] CMP ECX,-0x9 JC 0x0017b01d INC dword ptr [RDX] LAB_0017b01d: LEA RSI,[RSP + 0x4] MOV RDI,R15 CALL 0x00127408 TEST EAX,EAX JZ 0x0017b05c MOV RDI,qword ptr [R15 + 0x18] MOV EAX,dword ptr [R14 + -0x18] LEA ECX,[RAX + -0x1] MOV dword ptr [R14 + -0x18],ECX CMP EAX,0x1 JG 0x0017b055 ADD R14,-0x18 MOV RSI,R14 MOV RDX,-0x7 CALL 0x00120d90 LAB_0017b055: XOR R12D,R12D LAB_0017b058: XOR EAX,EAX JMP 0x0017b0cc LAB_0017b05c: MOV EAX,dword ptr [RSP + 0x4] XOR R9D,R9D TEST EAX,EAX MOV R8D,0xa CMOVNZ R8D,EAX SETZ R9B SHL R9D,0x5 INC R9D MOV RDX,qword ptr [RSP + 0x8] MOV RDI,R15 MOV RSI,R14 XOR ECX,ECX CALL 0x0013f179 MOV R12,RAX MOV RBX,RDX MOV RDI,qword ptr [R15 + 0x18] MOV EAX,dword ptr [R14 + -0x18] LEA ECX,[RAX + -0x1] MOV dword ptr [R14 + -0x18],ECX CMP EAX,0x1 JG 0x0017b0b9 ADD R14,-0x18 MOV RSI,R14 MOV RDX,-0x7 CALL 0x00120d90 LAB_0017b0b9: MOV RCX,-0x100000000 MOV RAX,R12 AND RAX,RCX MOV R12D,R12D LAB_0017b0cc: OR R12,RAX MOV RAX,R12 MOV RDX,RBX ADD RSP,0x10 POP RBX POP R12 POP R13 POP R14 POP R15 RET
int1 [16] js_parseInt(long param_1) { int8 uVar1; int iVar2; long lVar3; ulong uVar4; int8 uVar5; int8 *in_R8; ulong uVar6; int1 auVar7 [16]; int local_34; int8 local_30; lVar3 = JS_ToCStringLen2(param_1,&local_30,*in_R8,in_R8[1],0); uVar5 = 6; if (lVar3 != 0) { if (0xfffffff6 < (uint)in_R8[3]) { *(int *)in_R8[2] = *(int *)in_R8[2] + 1; } iVar2 = JS_ToInt32Free(param_1,&local_34); if (iVar2 == 0) { iVar2 = 10; if (local_34 != 0) { iVar2 = local_34; } auVar7 = js_atof(param_1,lVar3,local_30,0,iVar2,(local_34 == 0) * ' ' + '\x01'); uVar5 = auVar7._8_8_; uVar1 = *(int8 *)(param_1 + 0x18); iVar2 = *(int *)(lVar3 + -0x18); *(int *)(lVar3 + -0x18) = iVar2 + -1; if (iVar2 < 2) { js_free_value_rt(uVar1,lVar3 + -0x18,0xfffffffffffffff9); } uVar4 = auVar7._0_8_ & 0xffffffff00000000; uVar6 = auVar7._0_8_ & 0xffffffff; goto LAB_0017b0cc; } uVar1 = *(int8 *)(param_1 + 0x18); iVar2 = *(int *)(lVar3 + -0x18); *(int *)(lVar3 + -0x18) = iVar2 + -1; if (iVar2 < 2) { js_free_value_rt(uVar1,lVar3 + -0x18,0xfffffffffffffff9); } } uVar6 = 0; uVar4 = 0; LAB_0017b0cc: auVar7._8_8_ = uVar5; auVar7._0_8_ = uVar6 | uVar4; return auVar7; }
60,899
google::protobuf::io::CodedOutputStream::WriteVarint64ToArray(unsigned long, unsigned char*)
aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/io/coded_stream.h
inline uint8_t* CodedOutputStream::WriteVarint64ToArray(uint64_t value, uint8_t* target) { return EpsCopyOutputStream::UnsafeVarint(value, target); }
O0
c
google::protobuf::io::CodedOutputStream::WriteVarint64ToArray(unsigned long, unsigned char*): movq %rdi, -0x20(%rsp) movq %rsi, -0x28(%rsp) movq -0x20(%rsp), %rcx movq -0x28(%rsp), %rax movq %rcx, -0x10(%rsp) movq %rax, -0x18(%rsp) movq -0x10(%rsp), %rax movb %al, %cl movq -0x18(%rsp), %rax movb %cl, (%rax) cmpq $0x80, -0x10(%rsp) jae 0xde37a movq -0x18(%rsp), %rax addq $0x1, %rax movq %rax, -0x8(%rsp) jmp 0xde421 movq -0x18(%rsp), %rax movzbl (%rax), %ecx orl $0x80, %ecx movb %cl, (%rax) movq -0x10(%rsp), %rax shrq $0x7, %rax movq %rax, -0x10(%rsp) movq -0x10(%rsp), %rax movb %al, %cl movq -0x18(%rsp), %rax movb %cl, 0x1(%rax) cmpq $0x80, -0x10(%rsp) jae 0xde3c2 movq -0x18(%rsp), %rax addq $0x2, %rax movq %rax, -0x8(%rsp) jmp 0xde421 movq -0x18(%rsp), %rax addq $0x2, %rax movq %rax, -0x18(%rsp) movq -0x18(%rsp), %rax movzbl -0x1(%rax), %ecx orl $0x80, %ecx movb %cl, -0x1(%rax) movq -0x10(%rsp), %rax shrq $0x7, %rax movq %rax, -0x10(%rsp) movq -0x10(%rsp), %rax movb %al, %cl movq -0x18(%rsp), %rax movb %cl, (%rax) movq -0x18(%rsp), %rax addq $0x1, %rax movq %rax, -0x18(%rsp) cmpq $0x80, -0x10(%rsp) jae 0xde3d0 movq -0x18(%rsp), %rax movq %rax, -0x8(%rsp) movq -0x8(%rsp), %rax retq nopw (%rax,%rax)
_ZN6google8protobuf2io17CodedOutputStream20WriteVarint64ToArrayEmPh: mov [rsp+var_20], rdi mov [rsp+var_28], rsi mov rcx, [rsp+var_20] mov rax, [rsp+var_28] mov [rsp+var_10], rcx mov [rsp+var_18], rax mov rax, [rsp+var_10] mov cl, al mov rax, [rsp+var_18] mov [rax], cl cmp [rsp+var_10], 80h jnb short loc_DE37A mov rax, [rsp+var_18] add rax, 1 mov [rsp+var_8], rax jmp loc_DE421 loc_DE37A: mov rax, [rsp+var_18] movzx ecx, byte ptr [rax] or ecx, 80h mov [rax], cl mov rax, [rsp+var_10] shr rax, 7 mov [rsp+var_10], rax mov rax, [rsp+var_10] mov cl, al mov rax, [rsp+var_18] mov [rax+1], cl cmp [rsp+var_10], 80h jnb short loc_DE3C2 mov rax, [rsp+var_18] add rax, 2 mov [rsp+var_8], rax jmp short loc_DE421 loc_DE3C2: mov rax, [rsp+var_18] add rax, 2 mov [rsp+var_18], rax loc_DE3D0: mov rax, [rsp+var_18] movzx ecx, byte ptr [rax-1] or ecx, 80h mov [rax-1], cl mov rax, [rsp+var_10] shr rax, 7 mov [rsp+var_10], rax mov rax, [rsp+var_10] mov cl, al mov rax, [rsp+var_18] mov [rax], cl mov rax, [rsp+var_18] add rax, 1 mov [rsp+var_18], rax cmp [rsp+var_10], 80h jnb short loc_DE3D0 mov rax, [rsp+var_18] mov [rsp+var_8], rax loc_DE421: mov rax, [rsp+var_8] retn
_BYTE * google::protobuf::io::CodedOutputStream::WriteVarint64ToArray( unsigned long long this, _BYTE *a2, unsigned __int8 *a3) { _BYTE *v4; // [rsp+10h] [rbp-18h] unsigned long long v5; // [rsp+18h] [rbp-10h] *a2 = this; if ( this < 0x80 ) return a2 + 1; *a2 |= 0x80u; v5 = this >> 7; a2[1] = this >> 7; if ( this >> 7 < 0x80 ) return a2 + 2; v4 = a2 + 2; do { *(v4 - 1) |= 0x80u; v5 >>= 7; *v4++ = v5; } while ( v5 >= 0x80 ); return v4; }
WriteVarint64ToArray: MOV qword ptr [RSP + -0x20],RDI MOV qword ptr [RSP + -0x28],RSI MOV RCX,qword ptr [RSP + -0x20] MOV RAX,qword ptr [RSP + -0x28] MOV qword ptr [RSP + -0x10],RCX MOV qword ptr [RSP + -0x18],RAX MOV RAX,qword ptr [RSP + -0x10] MOV CL,AL MOV RAX,qword ptr [RSP + -0x18] MOV byte ptr [RAX],CL CMP qword ptr [RSP + -0x10],0x80 JNC 0x001de37a MOV RAX,qword ptr [RSP + -0x18] ADD RAX,0x1 MOV qword ptr [RSP + -0x8],RAX JMP 0x001de421 LAB_001de37a: MOV RAX,qword ptr [RSP + -0x18] MOVZX ECX,byte ptr [RAX] OR ECX,0x80 MOV byte ptr [RAX],CL MOV RAX,qword ptr [RSP + -0x10] SHR RAX,0x7 MOV qword ptr [RSP + -0x10],RAX MOV RAX,qword ptr [RSP + -0x10] MOV CL,AL MOV RAX,qword ptr [RSP + -0x18] MOV byte ptr [RAX + 0x1],CL CMP qword ptr [RSP + -0x10],0x80 JNC 0x001de3c2 MOV RAX,qword ptr [RSP + -0x18] ADD RAX,0x2 MOV qword ptr [RSP + -0x8],RAX JMP 0x001de421 LAB_001de3c2: MOV RAX,qword ptr [RSP + -0x18] ADD RAX,0x2 MOV qword ptr [RSP + -0x18],RAX LAB_001de3d0: MOV RAX,qword ptr [RSP + -0x18] MOVZX ECX,byte ptr [RAX + -0x1] OR ECX,0x80 MOV byte ptr [RAX + -0x1],CL MOV RAX,qword ptr [RSP + -0x10] SHR RAX,0x7 MOV qword ptr [RSP + -0x10],RAX MOV RAX,qword ptr [RSP + -0x10] MOV CL,AL MOV RAX,qword ptr [RSP + -0x18] MOV byte ptr [RAX],CL MOV RAX,qword ptr [RSP + -0x18] ADD RAX,0x1 MOV qword ptr [RSP + -0x18],RAX CMP qword ptr [RSP + -0x10],0x80 JNC 0x001de3d0 MOV RAX,qword ptr [RSP + -0x18] MOV qword ptr [RSP + -0x8],RAX LAB_001de421: MOV RAX,qword ptr [RSP + -0x8] RET
/* google::protobuf::io::CodedOutputStream::WriteVarint64ToArray(unsigned long, unsigned char*) */ uchar * google::protobuf::io::CodedOutputStream::WriteVarint64ToArray(ulong param_1,uchar *param_2) { uchar *local_18; ulong local_10; uchar *local_8; *param_2 = (uchar)param_1; if (param_1 < 0x80) { local_8 = param_2 + 1; } else { *param_2 = *param_2 | 0x80; local_10 = param_1 >> 7; param_2[1] = (uchar)local_10; if (local_10 < 0x80) { local_8 = param_2 + 2; } else { local_18 = param_2 + 2; do { local_18[-1] = local_18[-1] | 0x80; local_10 = local_10 >> 7; *local_18 = (uchar)local_10; local_18 = local_18 + 1; local_8 = local_18; } while (0x7f < local_10); } } return local_8; }