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
47,400
list_reverse
eloqsql/mysys/list.c
LIST *list_reverse(LIST *root) { LIST *last; last=root; while (root) { last=root; root=root->next; last->next=last->prev; last->prev=root; } return last; }
O3
c
list_reverse: testq %rdi, %rdi je 0x99692 pushq %rbp movq %rsp, %rbp movq %rdi, %rax movq (%rdi), %rcx movq 0x8(%rdi), %rdi movq %rcx, 0x8(%rax) movq %rdi, (%rax) testq %rdi, %rdi jne 0x9967a popq %rbp retq xorl %eax, %eax retq
list_reverse: test rdi, rdi jz short loc_99692 push rbp mov rbp, rsp loc_9967A: mov rax, rdi mov rcx, [rdi] mov rdi, [rdi+8] mov [rax+8], rcx mov [rax], rdi test rdi, rdi jnz short loc_9967A pop rbp retn loc_99692: xor eax, eax retn
_QWORD * list_reverse(_QWORD *a1) { _QWORD *result; // rax long long v2; // rcx if ( !a1 ) return 0LL; do { result = a1; v2 = *a1; a1 = (_QWORD *)a1[1]; result[1] = v2; *result = a1; } while ( a1 ); return result; }
list_reverse: TEST RDI,RDI JZ 0x00199692 PUSH RBP MOV RBP,RSP LAB_0019967a: MOV RAX,RDI MOV RCX,qword ptr [RDI] MOV RDI,qword ptr [RDI + 0x8] MOV qword ptr [RAX + 0x8],RCX MOV qword ptr [RAX],RDI TEST RDI,RDI JNZ 0x0019967a POP RBP RET LAB_00199692: XOR EAX,EAX RET
int8 * list_reverse(int8 *param_1) { int8 *puVar1; int8 *puVar2; if (param_1 == (int8 *)0x0) { return (int8 *)0x0; } do { puVar2 = param_1; puVar1 = (int8 *)param_1[1]; param_1[1] = *param_1; *param_1 = puVar1; param_1 = puVar1; } while (puVar1 != (int8 *)0x0); return puVar2; }
47,401
testing::Message::~Message()
AlayaLite/build_O0/_deps/googletest-src/googletest/include/gtest/gtest-message.h
class GTEST_API_ Message { private: // The type of basic IO manipulators (endl, ends, and flush) for // narrow streams. typedef std::ostream& (*BasicNarrowIoManip)(std::ostream&); public: // Constructs an empty Message. Message(); // Copy constructor. Message(const Message& msg) : ss_(new ::std::stringstream) { // NOLINT *ss_ << msg.GetString(); } // Constructs a Message from a C-string. explicit Message(const char* str) : ss_(new ::std::stringstream) { *ss_ << str; } // Streams a non-pointer value to this object. If building a version of // GoogleTest with ABSL, this overload is only enabled if the value does not // have an AbslStringify definition. template < typename T #ifdef GTEST_HAS_ABSL , typename std::enable_if<!absl::HasAbslStringify<T>::value, // NOLINT int>::type = 0 #endif // GTEST_HAS_ABSL > inline Message& operator<<(const T& val) { // Some libraries overload << for STL containers. These // overloads are defined in the global namespace instead of ::std. // // C++'s symbol lookup rule (i.e. Koenig lookup) says that these // overloads are visible in either the std namespace or the global // namespace, but not other namespaces, including the testing // namespace which Google Test's Message class is in. // // To allow STL containers (and other types that has a << operator // defined in the global namespace) to be used in Google Test // assertions, testing::Message must access the custom << operator // from the global namespace. With this using declaration, // overloads of << defined in the global namespace and those // visible via Koenig lookup are both exposed in this function. using ::operator<<; *ss_ << val; return *this; } #ifdef GTEST_HAS_ABSL // Streams a non-pointer value with an AbslStringify definition to this // object. template <typename T, typename std::enable_if<absl::HasAbslStringify<T>::value, // NOLINT int>::type = 0> inline Message& operator<<(const T& val) { // ::operator<< is needed here for a similar reason as with the non-Abseil // version above using ::operator<<; *ss_ << absl::StrCat(val); return *this; } #endif // GTEST_HAS_ABSL // Streams a pointer value to this object. // // This function is an overload of the previous one. When you // stream a pointer to a Message, this definition will be used as it // is more specialized. (The C++ Standard, section // [temp.func.order].) If you stream a non-pointer, then the // previous definition will be used. // // The reason for this overload is that streaming a NULL pointer to // ostream is undefined behavior. Depending on the compiler, you // may get "0", "(nil)", "(null)", or an access violation. To // ensure consistent result across compilers, we always treat NULL // as "(null)". template <typename T> inline Message& operator<<(T* const& pointer) { // NOLINT if (pointer == nullptr) { *ss_ << "(null)"; } else { *ss_ << pointer; } return *this; } // Since the basic IO manipulators are overloaded for both narrow // and wide streams, we have to provide this specialized definition // of operator <<, even though its body is the same as the // templatized version above. Without this definition, streaming // endl or other basic IO manipulators to Message will confuse the // compiler. Message& operator<<(BasicNarrowIoManip val) { *ss_ << val; return *this; } // Instead of 1/0, we want to see true/false for bool values. Message& operator<<(bool b) { return *this << (b ? "true" : "false"); } // These two overloads allow streaming a wide C string to a Message // using the UTF-8 encoding. Message& operator<<(const wchar_t* wide_c_str); Message& operator<<(wchar_t* wide_c_str); #if GTEST_HAS_STD_WSTRING // Converts the given wide string to a narrow string using the UTF-8 // encoding, and streams the result to this Message object. Message& operator<<(const ::std::wstring& wstr); #endif // GTEST_HAS_STD_WSTRING // Gets the text streamed to this object so far as an std::string. // Each '\0' character in the buffer is replaced with "\\0". // // INTERNAL IMPLEMENTATION - DO NOT USE IN A USER PROGRAM. std::string GetString() const; private: // We'll hold the text streamed to this object here. const std::unique_ptr< ::std::stringstream> ss_; // We declare (but don't implement) this to prevent the compiler // from implementing the assignment operator. void operator=(const Message&); }
O0
c
testing::Message::~Message(): pushq %rax movq %rdi, (%rsp) movq (%rsp), %rdi callq 0x1ba40 popq %rax retq
_ZN7testing7MessageD2Ev: push rax mov [rsp+8+var_8], rdi mov rdi, [rsp+8+var_8] call _ZNSt10unique_ptrINSt7__cxx1118basic_stringstreamIcSt11char_traitsIcESaIcEEESt14default_deleteIS5_EED2Ev; std::unique_ptr<std::basic_stringstream<char,std::char_traits<char>,std::allocator<char>>>::~unique_ptr() pop rax retn
void testing::Message::~Message(testing::Message *this) { std::unique_ptr<std::basic_stringstream<char,std::char_traits<char>,std::allocator<char>>>::~unique_ptr(this); }
~Message: PUSH RAX MOV qword ptr [RSP],RDI MOV RDI,qword ptr [RSP] CALL 0x0011ba40 POP RAX RET
/* testing::Message::~Message() */ Message * __thiscall testing::Message::~Message(Message *this) { std::unique_ptr<std::__cxx11::stringstream,std::default_delete<std::__cxx11::stringstream>>:: ~unique_ptr((unique_ptr<std::__cxx11::stringstream,std::default_delete<std::__cxx11::stringstream>> *)this); return this; }
47,402
maria_ft_add_word
eloqsql/storage/maria/ma_ft_parser.c
static int maria_ft_add_word(MYSQL_FTPARSER_PARAM *param, const char *word, int word_len, MYSQL_FTPARSER_BOOLEAN_INFO *boolean_info __attribute__((unused))) { TREE *wtree; FT_WORD w; MY_FT_PARSER_PARAM *ft_param=param->mysql_ftparam; DBUG_ENTER("maria_ft_add_word"); wtree= ft_param->wtree; if (param->flags & MYSQL_FTFLAGS_NEED_COPY) { uchar *ptr; DBUG_ASSERT(wtree->with_delete == 0); ptr= (uchar *)alloc_root(ft_param->mem_root, word_len); memcpy(ptr, word, word_len); w.pos= ptr; } else w.pos= (uchar*) word; w.len= word_len; if (!tree_insert(wtree, &w, 0, wtree->custom_arg)) { delete_tree(wtree, 0); DBUG_RETURN(1); } DBUG_RETURN(0); }
O0
c
maria_ft_add_word: pushq %rbp movq %rsp, %rbp subq $0x60, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movl %edx, -0x1c(%rbp) movq %rcx, -0x28(%rbp) movq -0x10(%rbp), %rax movq 0x18(%rax), %rax movq %rax, -0x50(%rbp) movq -0x50(%rbp), %rax movq (%rax), %rax movq %rax, -0x30(%rbp) movq -0x10(%rbp), %rax movl 0x34(%rax), %eax andl $0x1, %eax cmpl $0x0, %eax je 0x75d21 jmp 0x75cef jmp 0x75cf1 movq -0x50(%rbp), %rax movq 0x8(%rax), %rdi movslq -0x1c(%rbp), %rsi callq 0xf2470 movq %rax, -0x58(%rbp) movq -0x58(%rbp), %rdi movq -0x18(%rbp), %rsi movslq -0x1c(%rbp), %rdx callq 0x2a0b0 movq -0x58(%rbp), %rax movq %rax, -0x48(%rbp) jmp 0x75d29 movq -0x18(%rbp), %rax movq %rax, -0x48(%rbp) movl -0x1c(%rbp), %eax movl %eax, -0x40(%rbp) movq -0x30(%rbp), %rdi movq -0x30(%rbp), %rax movq 0x230(%rax), %rcx leaq -0x48(%rbp), %rsi xorl %edx, %edx callq 0x103100 cmpq $0x0, %rax jne 0x75d63 movq -0x30(%rbp), %rdi xorl %esi, %esi callq 0x102f30 movl $0x1, -0x4(%rbp) jmp 0x75d6c jmp 0x75d65 movl $0x0, -0x4(%rbp) movl -0x4(%rbp), %eax addq $0x60, %rsp popq %rbp retq nopw %cs:(%rax,%rax)
maria_ft_add_word: push rbp mov rbp, rsp sub rsp, 60h 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 rax, [rax+18h] mov [rbp+var_50], rax mov rax, [rbp+var_50] mov rax, [rax] mov [rbp+var_30], rax mov rax, [rbp+var_10] mov eax, [rax+34h] and eax, 1 cmp eax, 0 jz short loc_75D21 jmp short $+2 loc_75CEF: jmp short $+2 loc_75CF1: mov rax, [rbp+var_50] mov rdi, [rax+8] movsxd rsi, [rbp+var_1C] call alloc_root mov [rbp+var_58], rax mov rdi, [rbp+var_58] mov rsi, [rbp+var_18] movsxd rdx, [rbp+var_1C] call _memcpy mov rax, [rbp+var_58] mov [rbp+var_48], rax jmp short loc_75D29 loc_75D21: mov rax, [rbp+var_18] mov [rbp+var_48], rax loc_75D29: mov eax, [rbp+var_1C] mov [rbp+var_40], eax mov rdi, [rbp+var_30] mov rax, [rbp+var_30] mov rcx, [rax+230h] lea rsi, [rbp+var_48] xor edx, edx call tree_insert cmp rax, 0 jnz short loc_75D63 mov rdi, [rbp+var_30] xor esi, esi call delete_tree mov [rbp+var_4], 1 jmp short loc_75D6C loc_75D63: jmp short $+2 loc_75D65: mov [rbp+var_4], 0 loc_75D6C: mov eax, [rbp+var_4] add rsp, 60h pop rbp retn
long long maria_ft_add_word(long long a1, long long a2, int a3, long long a4) { long long v5; // [rsp+8h] [rbp-58h] long long *v6; // [rsp+10h] [rbp-50h] long long v7; // [rsp+18h] [rbp-48h] BYREF int v8; // [rsp+20h] [rbp-40h] long long v9; // [rsp+30h] [rbp-30h] long long v10; // [rsp+38h] [rbp-28h] int v11; // [rsp+44h] [rbp-1Ch] long long v12; // [rsp+48h] [rbp-18h] long long v13; // [rsp+50h] [rbp-10h] v13 = a1; v12 = a2; v11 = a3; v10 = a4; v6 = *(long long **)(a1 + 24); v9 = *v6; if ( (*(_DWORD *)(a1 + 52) & 1) != 0 ) { v5 = alloc_root(v6[1], v11); memcpy(v5, v12, v11); v7 = v5; } else { v7 = v12; } v8 = v11; if ( tree_insert(v9, &v7, 0LL, *(_QWORD *)(v9 + 560)) ) { return 0; } else { delete_tree(v9, 0LL); return 1; } }
maria_ft_add_word: PUSH RBP MOV RBP,RSP SUB RSP,0x60 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 RAX,qword ptr [RAX + 0x18] MOV qword ptr [RBP + -0x50],RAX MOV RAX,qword ptr [RBP + -0x50] MOV RAX,qword ptr [RAX] MOV qword ptr [RBP + -0x30],RAX MOV RAX,qword ptr [RBP + -0x10] MOV EAX,dword ptr [RAX + 0x34] AND EAX,0x1 CMP EAX,0x0 JZ 0x00175d21 JMP 0x00175cef LAB_00175cef: JMP 0x00175cf1 LAB_00175cf1: MOV RAX,qword ptr [RBP + -0x50] MOV RDI,qword ptr [RAX + 0x8] MOVSXD RSI,dword ptr [RBP + -0x1c] CALL 0x001f2470 MOV qword ptr [RBP + -0x58],RAX MOV RDI,qword ptr [RBP + -0x58] MOV RSI,qword ptr [RBP + -0x18] MOVSXD RDX,dword ptr [RBP + -0x1c] CALL 0x0012a0b0 MOV RAX,qword ptr [RBP + -0x58] MOV qword ptr [RBP + -0x48],RAX JMP 0x00175d29 LAB_00175d21: MOV RAX,qword ptr [RBP + -0x18] MOV qword ptr [RBP + -0x48],RAX LAB_00175d29: MOV EAX,dword ptr [RBP + -0x1c] MOV dword ptr [RBP + -0x40],EAX MOV RDI,qword ptr [RBP + -0x30] MOV RAX,qword ptr [RBP + -0x30] MOV RCX,qword ptr [RAX + 0x230] LEA RSI,[RBP + -0x48] XOR EDX,EDX CALL 0x00203100 CMP RAX,0x0 JNZ 0x00175d63 MOV RDI,qword ptr [RBP + -0x30] XOR ESI,ESI CALL 0x00202f30 MOV dword ptr [RBP + -0x4],0x1 JMP 0x00175d6c LAB_00175d63: JMP 0x00175d65 LAB_00175d65: MOV dword ptr [RBP + -0x4],0x0 LAB_00175d6c: MOV EAX,dword ptr [RBP + -0x4] ADD RSP,0x60 POP RBP RET
bool maria_ft_add_word(long param_1,void *param_2,int param_3,int8 param_4) { void *__dest; long lVar1; void *local_50; int local_48; long local_38; int8 local_30; int local_24; void *local_20; long local_18; local_38 = **(long **)(param_1 + 0x18); local_50 = param_2; local_30 = param_4; local_24 = param_3; local_20 = param_2; local_18 = param_1; if ((*(uint *)(param_1 + 0x34) & 1) != 0) { __dest = (void *)alloc_root((*(long **)(param_1 + 0x18))[1],(long)param_3); memcpy(__dest,local_20,(long)local_24); local_50 = __dest; } local_48 = local_24; lVar1 = tree_insert(local_38,&local_50,0,*(int8 *)(local_38 + 0x230)); if (lVar1 == 0) { delete_tree(local_38,0); } return lVar1 == 0; }
47,403
mju_dotSparse
aimrt_mujoco_sim/_deps/mujoco-src/src/engine/engine_util_sparse_avx.h
static inline mjtNum mju_dotSparse_avx(const mjtNum* vec1, const mjtNum* vec2, const int nnz1, const int* ind1, int flg_unc1) { int i = 0; mjtNum res = 0; int nnz1_4 = nnz1 - 4; // vector part if (nnz1_4>=0) { __m256d sum, prod, val1, val2; __m128d vlow, vhigh, high64; // init val2 = _mm256_set_pd(vec2[ind1[3]], vec2[ind1[2]], vec2[ind1[1]], vec2[ind1[0]]); if (flg_unc1) { val1 = _mm256_set_pd(vec1[ind1[3]], vec1[ind1[2]], vec1[ind1[1]], vec1[ind1[0]]); } else { val1 = _mm256_loadu_pd(vec1); } sum = _mm256_mul_pd(val1, val2); i = 4; // parallel computation if (flg_unc1) { while (i<=nnz1_4) { val1 = _mm256_set_pd(vec1[ind1[i+3]], vec1[ind1[i+2]], vec1[ind1[i+1]], vec1[ind1[i+0]]); val2 = _mm256_set_pd(vec2[ind1[i+3]], vec2[ind1[i+2]], vec2[ind1[i+1]], vec2[ind1[i+0]]); prod = _mm256_mul_pd(val1, val2); sum = _mm256_add_pd(sum, prod); i += 4; } } else { while (i<=nnz1_4) { val1 = _mm256_loadu_pd(vec1+i); val2 = _mm256_set_pd(vec2[ind1[i+3]], vec2[ind1[i+2]], vec2[ind1[i+1]], vec2[ind1[i+0]]); prod = _mm256_mul_pd(val1, val2); sum = _mm256_add_pd(sum, prod); i += 4; } } // reduce vlow = _mm256_castpd256_pd128(sum); vhigh = _mm256_extractf128_pd(sum, 1); vlow = _mm_add_pd(vlow, vhigh); high64 = _mm_unpackhi_pd(vlow, vlow); res = _mm_cvtsd_f64(_mm_add_sd(vlow, high64)); } // scalar part if (flg_unc1) { for (; i < nnz1; i++) { res += vec1[ind1[i]] * vec2[ind1[i]]; } } else { for (; i < nnz1; i++) { res += vec1[i] * vec2[ind1[i]]; } } return res; }
O3
c
mju_dotSparse: cmpl $0x4, %edx jl 0xa2b40 pushq %r14 pushq %rbx leal -0x4(%rdx), %r9d movslq 0xc(%rcx), %rax movslq 0x8(%rcx), %r11 movslq 0x4(%rcx), %r10 movslq (%rcx), %rbx vmovsd (%rsi,%r11,8), %xmm0 vmovhps (%rsi,%rax,8), %xmm0, %xmm0 # xmm0 = xmm0[0,1],mem[0,1] vmovsd (%rsi,%rbx,8), %xmm1 vmovhpd (%rsi,%r10,8), %xmm1, %xmm1 # xmm1 = xmm1[0],mem[0] vinsertf128 $0x1, %xmm0, %ymm1, %ymm0 testl %r8d, %r8d je 0xa2b48 vmovsd (%rdi,%r11,8), %xmm1 vmovhps (%rdi,%rax,8), %xmm1, %xmm1 # xmm1 = xmm1[0,1],mem[0,1] vmovsd (%rdi,%rbx,8), %xmm2 vmovhpd (%rdi,%r10,8), %xmm2, %xmm2 # xmm2 = xmm2[0],mem[0] vinsertf128 $0x1, %xmm1, %ymm2, %ymm1 vmulpd %ymm1, %ymm0, %ymm0 movl $0x4, %eax cmpl $0x8, %edx jb 0xa2ba0 movl %r9d, %r9d movl $0x4, %eax movslq 0xc(%rcx,%rax,4), %r10 movslq 0x8(%rcx,%rax,4), %r11 movslq 0x4(%rcx,%rax,4), %rbx vmovsd (%rdi,%r11,8), %xmm1 vmovhps (%rdi,%r10,8), %xmm1, %xmm1 # xmm1 = xmm1[0,1],mem[0,1] movslq (%rcx,%rax,4), %r14 vmovsd (%rdi,%r14,8), %xmm2 vmovhps (%rdi,%rbx,8), %xmm2, %xmm2 # xmm2 = xmm2[0,1],mem[0,1] vinsertf128 $0x1, %xmm1, %ymm2, %ymm1 vmovsd (%rsi,%r11,8), %xmm2 vmovhps (%rsi,%r10,8), %xmm2, %xmm2 # xmm2 = xmm2[0,1],mem[0,1] vmovsd (%rsi,%r14,8), %xmm3 vmovhps (%rsi,%rbx,8), %xmm3, %xmm3 # xmm3 = xmm3[0,1],mem[0,1] vinsertf128 $0x1, %xmm2, %ymm3, %ymm2 vmulpd %ymm2, %ymm1, %ymm1 vaddpd %ymm1, %ymm0, %ymm0 addq $0x4, %rax cmpq %r9, %rax jbe 0xa2ae0 jmp 0xa2ba0 xorl %eax, %eax vxorpd %xmm0, %xmm0, %xmm0 jmp 0xa2bb1 vmulpd (%rdi), %ymm0, %ymm0 movl $0x4, %eax cmpl $0x8, %edx jb 0xa2ba0 movl %r9d, %r9d movl $0x4, %eax movslq 0xc(%rcx,%rax,4), %r10 movslq 0x8(%rcx,%rax,4), %r11 movslq 0x4(%rcx,%rax,4), %rbx vmovsd (%rsi,%r11,8), %xmm1 vmovhps (%rsi,%r10,8), %xmm1, %xmm1 # xmm1 = xmm1[0,1],mem[0,1] movslq (%rcx,%rax,4), %r10 vmovsd (%rsi,%r10,8), %xmm2 vmovhpd (%rsi,%rbx,8), %xmm2, %xmm2 # xmm2 = xmm2[0],mem[0] vinsertf128 $0x1, %xmm1, %ymm2, %ymm1 vmulpd (%rdi,%rax,8), %ymm1, %ymm1 vaddpd %ymm1, %ymm0, %ymm0 addq $0x4, %rax cmpq %r9, %rax jbe 0xa2b5e vextractf128 $0x1, %ymm0, %xmm1 vaddpd %xmm1, %xmm0, %xmm0 vhaddpd %xmm0, %xmm0, %xmm0 popq %rbx popq %r14 testl %r8d, %r8d je 0xa2bdc cmpl %edx, %eax jge 0xa2bff movl %eax, %eax movl %edx, %edx movslq (%rcx,%rax,4), %r8 vmovsd (%rdi,%r8,8), %xmm1 vmulsd (%rsi,%r8,8), %xmm1, %xmm1 vaddsd %xmm0, %xmm1, %xmm0 incq %rax cmpq %rax, %rdx jne 0xa2bbe jmp 0xa2bff cmpl %edx, %eax jge 0xa2bff movl %eax, %eax movl %edx, %edx vmovsd (%rdi,%rax,8), %xmm1 movslq (%rcx,%rax,4), %r8 vmulsd (%rsi,%r8,8), %xmm1, %xmm1 vaddsd %xmm0, %xmm1, %xmm0 incq %rax cmpq %rax, %rdx jne 0xa2be4 vzeroupper retq
mju_dotSparse: cmp edx, 4 jl loc_A2B40 push r14 push rbx lea r9d, [rdx-4] movsxd rax, dword ptr [rcx+0Ch] movsxd r11, dword ptr [rcx+8] movsxd r10, dword ptr [rcx+4] movsxd rbx, dword ptr [rcx] vmovsd xmm0, qword ptr [rsi+r11*8] vmovhps xmm0, xmm0, qword ptr [rsi+rax*8] vmovsd xmm1, qword ptr [rsi+rbx*8] vmovhpd xmm1, xmm1, qword ptr [rsi+r10*8] vinsertf128 ymm0, ymm1, xmm0, 1 test r8d, r8d jz loc_A2B48 vmovsd xmm1, qword ptr [rdi+r11*8] vmovhps xmm1, xmm1, qword ptr [rdi+rax*8] vmovsd xmm2, qword ptr [rdi+rbx*8] vmovhpd xmm2, xmm2, qword ptr [rdi+r10*8] vinsertf128 ymm1, ymm2, xmm1, 1 vmulpd ymm0, ymm0, ymm1 mov eax, 4 cmp edx, 8 jb loc_A2BA0 mov r9d, r9d mov eax, 4 loc_A2AE0: movsxd r10, dword ptr [rcx+rax*4+0Ch] movsxd r11, dword ptr [rcx+rax*4+8] movsxd rbx, dword ptr [rcx+rax*4+4] vmovsd xmm1, qword ptr [rdi+r11*8] vmovhps xmm1, xmm1, qword ptr [rdi+r10*8] movsxd r14, dword ptr [rcx+rax*4] vmovsd xmm2, qword ptr [rdi+r14*8] vmovhps xmm2, xmm2, qword ptr [rdi+rbx*8] vinsertf128 ymm1, ymm2, xmm1, 1 vmovsd xmm2, qword ptr [rsi+r11*8] vmovhps xmm2, xmm2, qword ptr [rsi+r10*8] vmovsd xmm3, qword ptr [rsi+r14*8] vmovhps xmm3, xmm3, qword ptr [rsi+rbx*8] vinsertf128 ymm2, ymm3, xmm2, 1 vmulpd ymm1, ymm1, ymm2 vaddpd ymm0, ymm0, ymm1 add rax, 4 cmp rax, r9 jbe short loc_A2AE0 jmp short loc_A2BA0 loc_A2B40: xor eax, eax vxorpd xmm0, xmm0, xmm0 jmp short loc_A2BB1 loc_A2B48: vmulpd ymm0, ymm0, ymmword ptr [rdi] mov eax, 4 cmp edx, 8 jb short loc_A2BA0 mov r9d, r9d mov eax, 4 loc_A2B5E: movsxd r10, dword ptr [rcx+rax*4+0Ch] movsxd r11, dword ptr [rcx+rax*4+8] movsxd rbx, dword ptr [rcx+rax*4+4] vmovsd xmm1, qword ptr [rsi+r11*8] vmovhps xmm1, xmm1, qword ptr [rsi+r10*8] movsxd r10, dword ptr [rcx+rax*4] vmovsd xmm2, qword ptr [rsi+r10*8] vmovhpd xmm2, xmm2, qword ptr [rsi+rbx*8] vinsertf128 ymm1, ymm2, xmm1, 1 vmulpd ymm1, ymm1, ymmword ptr [rdi+rax*8] vaddpd ymm0, ymm0, ymm1 add rax, 4 cmp rax, r9 jbe short loc_A2B5E loc_A2BA0: vextractf128 xmm1, ymm0, 1 vaddpd xmm0, xmm0, xmm1 vhaddpd xmm0, xmm0, xmm0 pop rbx pop r14 loc_A2BB1: test r8d, r8d jz short loc_A2BDC cmp eax, edx jge short loc_A2BFF mov eax, eax mov edx, edx loc_A2BBE: movsxd r8, dword ptr [rcx+rax*4] vmovsd xmm1, qword ptr [rdi+r8*8] vmulsd xmm1, xmm1, qword ptr [rsi+r8*8] vaddsd xmm0, xmm1, xmm0 inc rax cmp rdx, rax jnz short loc_A2BBE jmp short loc_A2BFF loc_A2BDC: cmp eax, edx jge short loc_A2BFF mov eax, eax mov edx, edx loc_A2BE4: vmovsd xmm1, qword ptr [rdi+rax*8] movsxd r8, dword ptr [rcx+rax*4] vmulsd xmm1, xmm1, qword ptr [rsi+r8*8] vaddsd xmm0, xmm1, xmm0 inc rax cmp rdx, rax jnz short loc_A2BE4 loc_A2BFF: vzeroupper retn
unsigned long long mju_dotSparse(long long _RDI, long long _RSI, int a3, int *a4, int a5, __m128 _XMM0) { unsigned int v9; // r9d unsigned long long result; // rax if ( a3 < 4 ) { result = 0LL; __asm { vxorpd xmm0, xmm0, xmm0 } } else { v9 = a3 - 4; _R11 = a4[2]; _RBX = *a4; __asm { vmovsd xmm0, qword ptr [rsi+r11*8] vmovhps xmm0, xmm0, qword ptr [rsi+rax*8] vmovsd xmm1, qword ptr [rsi+rbx*8] vmovhpd xmm1, xmm1, qword ptr [rsi+r10*8] vinsertf128 ymm0, ymm1, xmm0, 1 } if ( a5 ) { __asm { vmovsd xmm1, qword ptr [rdi+r11*8] vmovhps xmm1, xmm1, qword ptr [rdi+rax*8] vmovsd xmm2, qword ptr [rdi+rbx*8] vmovhpd xmm2, xmm2, qword ptr [rdi+r10*8] vinsertf128 ymm1, ymm2, xmm1, 1 vmulpd ymm0, ymm0, ymm1 } result = 4LL; if ( (unsigned int)a3 >= 8 ) { result = 4LL; do { _R11 = a4[result + 2]; __asm { vmovsd xmm1, qword ptr [rdi+r11*8] vmovhps xmm1, xmm1, qword ptr [rdi+r10*8] } _R14 = a4[result]; __asm { vmovsd xmm2, qword ptr [rdi+r14*8] vmovhps xmm2, xmm2, qword ptr [rdi+rbx*8] vinsertf128 ymm1, ymm2, xmm1, 1 vmovsd xmm2, qword ptr [rsi+r11*8] vmovhps xmm2, xmm2, qword ptr [rsi+r10*8] vmovsd xmm3, qword ptr [rsi+r14*8] vmovhps xmm3, xmm3, qword ptr [rsi+rbx*8] vinsertf128 ymm2, ymm3, xmm2, 1 vmulpd ymm1, ymm1, ymm2 vaddpd ymm0, ymm0, ymm1 } result += 4LL; } while ( result <= v9 ); } } else { __asm { vmulpd ymm0, ymm0, ymmword ptr [rdi] } result = 4LL; if ( (unsigned int)a3 >= 8 ) { result = 4LL; do { _R11 = a4[result + 2]; __asm { vmovsd xmm1, qword ptr [rsi+r11*8] vmovhps xmm1, xmm1, qword ptr [rsi+r10*8] } _R10 = a4[result]; __asm { vmovsd xmm2, qword ptr [rsi+r10*8] vmovhpd xmm2, xmm2, qword ptr [rsi+rbx*8] vinsertf128 ymm1, ymm2, xmm1, 1 vmulpd ymm1, ymm1, ymmword ptr [rdi+rax*8] vaddpd ymm0, ymm0, ymm1 } result += 4LL; } while ( result <= v9 ); } } __asm { vextractf128 xmm1, ymm0, 1 vaddpd xmm0, xmm0, xmm1 vhaddpd xmm0, xmm0, xmm0 } } if ( a5 ) { if ( (int)result < a3 ) { result = (unsigned int)result; do { _R8 = a4[result]; __asm { vmovsd xmm1, qword ptr [rdi+r8*8] vmulsd xmm1, xmm1, qword ptr [rsi+r8*8] vaddsd xmm0, xmm1, xmm0 } ++result; } while ( a3 != result ); } } else if ( (int)result < a3 ) { result = (unsigned int)result; do { __asm { vmovsd xmm1, qword ptr [rdi+rax*8] vmulsd xmm1, xmm1, qword ptr [rsi+r8*8] vaddsd xmm0, xmm1, xmm0 } ++result; } while ( a3 != result ); } __asm { vzeroupper } return result; }
mju_dotSparse: CMP EDX,0x4 JL 0x001a2b40 PUSH R14 PUSH RBX LEA R9D,[RDX + -0x4] MOVSXD RAX,dword ptr [RCX + 0xc] MOVSXD R11,dword ptr [RCX + 0x8] MOVSXD R10,dword ptr [RCX + 0x4] MOVSXD RBX,dword ptr [RCX] VMOVSD XMM0,qword ptr [RSI + R11*0x8] VMOVHPS XMM0,XMM0,qword ptr [RSI + RAX*0x8] VMOVSD XMM1,qword ptr [RSI + RBX*0x8] VMOVHPD XMM1,XMM1,qword ptr [RSI + R10*0x8] VINSERTF128 YMM0,YMM1,XMM0,0x1 TEST R8D,R8D JZ 0x001a2b48 VMOVSD XMM1,qword ptr [RDI + R11*0x8] VMOVHPS XMM1,XMM1,qword ptr [RDI + RAX*0x8] VMOVSD XMM2,qword ptr [RDI + RBX*0x8] VMOVHPD XMM2,XMM2,qword ptr [RDI + R10*0x8] VINSERTF128 YMM1,YMM2,XMM1,0x1 VMULPD YMM0,YMM0,YMM1 MOV EAX,0x4 CMP EDX,0x8 JC 0x001a2ba0 MOV R9D,R9D MOV EAX,0x4 LAB_001a2ae0: MOVSXD R10,dword ptr [RCX + RAX*0x4 + 0xc] MOVSXD R11,dword ptr [RCX + RAX*0x4 + 0x8] MOVSXD RBX,dword ptr [RCX + RAX*0x4 + 0x4] VMOVSD XMM1,qword ptr [RDI + R11*0x8] VMOVHPS XMM1,XMM1,qword ptr [RDI + R10*0x8] MOVSXD R14,dword ptr [RCX + RAX*0x4] VMOVSD XMM2,qword ptr [RDI + R14*0x8] VMOVHPS XMM2,XMM2,qword ptr [RDI + RBX*0x8] VINSERTF128 YMM1,YMM2,XMM1,0x1 VMOVSD XMM2,qword ptr [RSI + R11*0x8] VMOVHPS XMM2,XMM2,qword ptr [RSI + R10*0x8] VMOVSD XMM3,qword ptr [RSI + R14*0x8] VMOVHPS XMM3,XMM3,qword ptr [RSI + RBX*0x8] VINSERTF128 YMM2,YMM3,XMM2,0x1 VMULPD YMM1,YMM1,YMM2 VADDPD YMM0,YMM0,YMM1 ADD RAX,0x4 CMP RAX,R9 JBE 0x001a2ae0 JMP 0x001a2ba0 LAB_001a2b40: XOR EAX,EAX VXORPD XMM0,XMM0,XMM0 JMP 0x001a2bb1 LAB_001a2b48: VMULPD YMM0,YMM0,ymmword ptr [RDI] MOV EAX,0x4 CMP EDX,0x8 JC 0x001a2ba0 MOV R9D,R9D MOV EAX,0x4 LAB_001a2b5e: MOVSXD R10,dword ptr [RCX + RAX*0x4 + 0xc] MOVSXD R11,dword ptr [RCX + RAX*0x4 + 0x8] MOVSXD RBX,dword ptr [RCX + RAX*0x4 + 0x4] VMOVSD XMM1,qword ptr [RSI + R11*0x8] VMOVHPS XMM1,XMM1,qword ptr [RSI + R10*0x8] MOVSXD R10,dword ptr [RCX + RAX*0x4] VMOVSD XMM2,qword ptr [RSI + R10*0x8] VMOVHPD XMM2,XMM2,qword ptr [RSI + RBX*0x8] VINSERTF128 YMM1,YMM2,XMM1,0x1 VMULPD YMM1,YMM1,ymmword ptr [RDI + RAX*0x8] VADDPD YMM0,YMM0,YMM1 ADD RAX,0x4 CMP RAX,R9 JBE 0x001a2b5e LAB_001a2ba0: VEXTRACTF128 XMM1,YMM0,0x1 VADDPD XMM0,XMM0,XMM1 VHADDPD XMM0,XMM0,XMM0 POP RBX POP R14 LAB_001a2bb1: TEST R8D,R8D JZ 0x001a2bdc CMP EAX,EDX JGE 0x001a2bff MOV EAX,EAX MOV EDX,EDX LAB_001a2bbe: MOVSXD R8,dword ptr [RCX + RAX*0x4] VMOVSD XMM1,qword ptr [RDI + R8*0x8] VMULSD XMM1,XMM1,qword ptr [RSI + R8*0x8] VADDSD XMM0,XMM1,XMM0 INC RAX CMP RDX,RAX JNZ 0x001a2bbe JMP 0x001a2bff LAB_001a2bdc: CMP EAX,EDX JGE 0x001a2bff MOV EAX,EAX MOV EDX,EDX LAB_001a2be4: VMOVSD XMM1,qword ptr [RDI + RAX*0x8] MOVSXD R8,dword ptr [RCX + RAX*0x4] VMULSD XMM1,XMM1,qword ptr [RSI + R8*0x8] VADDSD XMM0,XMM1,XMM0 INC RAX CMP RDX,RAX JNZ 0x001a2be4 LAB_001a2bff: VZEROUPPER RET
void mju_dotSparse(long param_1,long param_2,uint param_3,int *param_4,int param_5) { uint uVar1; ulong uVar2; int1 auVar3 [16]; int1 auVar4 [16]; int1 auVar5 [16]; int1 auVar6 [16]; int1 auVar7 [16]; int1 auVar8 [16]; int1 auVar9 [16]; int1 auVar10 [16]; int1 auVar11 [16]; int1 auVar12 [16]; if ((int)param_3 < 4) { uVar1 = 0; } else { auVar3._8_8_ = 0; auVar3._0_8_ = *(ulong *)(param_2 + (long)param_4[2] * 8); vmovhps_avx(auVar3,*(int8 *)(param_2 + (long)param_4[3] * 8)); auVar4._8_8_ = 0; auVar4._0_8_ = *(ulong *)(param_2 + (long)*param_4 * 8); vmovhpd_avx(auVar4,*(int8 *)(param_2 + (long)param_4[1] * 8)); if (param_5 == 0) { uVar2 = 4; if (7 < param_3) { uVar2 = 4; do { auVar7._8_8_ = 0; auVar7._0_8_ = *(ulong *)(param_2 + (long)param_4[uVar2 + 2] * 8); vmovhps_avx(auVar7,*(int8 *)(param_2 + (long)param_4[uVar2 + 3] * 8)); auVar11._8_8_ = 0; auVar11._0_8_ = *(ulong *)(param_2 + (long)param_4[uVar2] * 8); vmovhpd_avx(auVar11,*(int8 *)(param_2 + (long)param_4[uVar2 + 1] * 8)); uVar2 = uVar2 + 4; } while (uVar2 <= param_3 - 4); } } else { auVar5._8_8_ = 0; auVar5._0_8_ = *(ulong *)(param_1 + (long)param_4[2] * 8); vmovhps_avx(auVar5,*(int8 *)(param_1 + (long)param_4[3] * 8)); auVar8._8_8_ = 0; auVar8._0_8_ = *(ulong *)(param_1 + (long)*param_4 * 8); vmovhpd_avx(auVar8,*(int8 *)(param_1 + (long)param_4[1] * 8)); uVar2 = 4; if (7 < param_3) { uVar2 = 4; do { auVar6._8_8_ = 0; auVar6._0_8_ = *(ulong *)(param_1 + (long)param_4[uVar2 + 2] * 8); vmovhps_avx(auVar6,*(int8 *)(param_1 + (long)param_4[uVar2 + 3] * 8)); auVar9._8_8_ = 0; auVar9._0_8_ = *(ulong *)(param_1 + (long)param_4[uVar2] * 8); vmovhps_avx(auVar9,*(int8 *)(param_1 + (long)param_4[uVar2 + 1] * 8)); auVar10._8_8_ = 0; auVar10._0_8_ = *(ulong *)(param_2 + (long)param_4[uVar2 + 2] * 8); vmovhps_avx(auVar10,*(int8 *)(param_2 + (long)param_4[uVar2 + 3] * 8)); auVar12._8_8_ = 0; auVar12._0_8_ = *(ulong *)(param_2 + (long)param_4[uVar2] * 8); vmovhps_avx(auVar12,*(int8 *)(param_2 + (long)param_4[uVar2 + 1] * 8)); uVar2 = uVar2 + 4; } while (uVar2 <= param_3 - 4); } } uVar1 = (uint)uVar2; } if (param_5 == 0) { if ((int)uVar1 < (int)param_3) { uVar2 = (ulong)uVar1; do { uVar2 = uVar2 + 1; } while (param_3 != uVar2); } } else if ((int)uVar1 < (int)param_3) { uVar2 = (ulong)uVar1; do { uVar2 = uVar2 + 1; } while (param_3 != uVar2); } return; }
47,404
write_hook_for_redo
eloqsql/storage/maria/ma_blockrec.c
my_bool write_hook_for_redo(enum translog_record_type type __attribute__ ((unused)), TRN *trn, MARIA_HA *tbl_info __attribute__ ((unused)), LSN *lsn, void *hook_arg __attribute__ ((unused))) { /* Users of dummy_transaction_object must keep this TRN clean as it is used by many threads (like those manipulating non-transactional tables). It might be dangerous if one user sets rec_lsn or some other member and it is picked up by another user (like putting this rec_lsn into a page of a non-transactional table); it's safer if all members stay 0. So non-transactional log records (REPAIR, CREATE, RENAME, DROP) should not call this hook; we trust them but verify ;) */ DBUG_ASSERT(trn->trid != 0); /* If the hook stays so simple, it would be faster to pass !trn->rec_lsn ? trn->rec_lsn : some_dummy_lsn to translog_write_record(), like Monty did in his original code, and not have a hook. For now we keep it like this. */ if (trn->rec_lsn == 0) trn->rec_lsn= *lsn; return 0; }
O3
c
write_hook_for_redo: pushq %rbp movq %rsp, %rbp cmpq $0x0, 0x90(%rsi) jne 0x4d2dc movq (%rcx), %rax movq %rax, 0x90(%rsi) xorl %eax, %eax popq %rbp retq
write_hook_for_redo: push rbp mov rbp, rsp cmp qword ptr [rsi+90h], 0 jnz short loc_4D2DC mov rax, [rcx] mov [rsi+90h], rax loc_4D2DC: xor eax, eax pop rbp retn
long long write_hook_for_redo(long long a1, long long a2, long long a3, _QWORD *a4) { if ( !*(_QWORD *)(a2 + 144) ) *(_QWORD *)(a2 + 144) = *a4; return 0LL; }
write_hook_for_redo: PUSH RBP MOV RBP,RSP CMP qword ptr [RSI + 0x90],0x0 JNZ 0x0014d2dc MOV RAX,qword ptr [RCX] MOV qword ptr [RSI + 0x90],RAX LAB_0014d2dc: XOR EAX,EAX POP RBP RET
int8 write_hook_for_redo(int8 param_1,long param_2,int8 param_3,int8 *param_4) { if (*(long *)(param_2 + 0x90) == 0) { *(int8 *)(param_2 + 0x90) = *param_4; } return 0; }
47,405
find_atom
bluesky950520[P]quickjs/quickjs.c
static JSAtom find_atom(JSContext *ctx, const char *name) { JSAtom atom; int len; if (*name == '[') { name++; len = strlen(name) - 1; /* We assume 8 bit non null strings, which is the case for these symbols */ for(atom = JS_ATOM_Symbol_toPrimitive; atom < JS_ATOM_END; atom++) { JSAtomStruct *p = ctx->rt->atom_array[atom]; JSString *str = p; if (str->len == len && !memcmp(str->u.str8, name, len)) return JS_DupAtom(ctx, atom); } abort(); } else { atom = JS_NewAtom(ctx, name); } return atom; }
O0
c
find_atom: subq $0x38, %rsp movq %rdi, 0x28(%rsp) movq %rsi, 0x20(%rsp) movq 0x20(%rsp), %rax movzbl (%rax), %eax cmpl $0x5b, %eax jne 0x4cc72 movq 0x20(%rsp), %rax addq $0x1, %rax movq %rax, 0x20(%rsp) movq 0x20(%rsp), %rdi callq 0xe240 subq $0x1, %rax movl %eax, 0x18(%rsp) movl $0xd3, 0x1c(%rsp) cmpl $0xe0, 0x1c(%rsp) jae 0x4cc6d movq 0x28(%rsp), %rax movq 0x18(%rax), %rax movq 0x68(%rax), %rax movl 0x1c(%rsp), %ecx movq (%rax,%rcx,8), %rax movq %rax, 0x10(%rsp) movq 0x10(%rsp), %rax movq %rax, 0x8(%rsp) movq 0x8(%rsp), %rax movq 0x4(%rax), %rax andq $0x7fffffff, %rax # imm = 0x7FFFFFFF cmpl 0x18(%rsp), %eax jne 0x4cc5b movq 0x8(%rsp), %rdi addq $0x18, %rdi movq 0x20(%rsp), %rsi movslq 0x18(%rsp), %rdx callq 0xe480 cmpl $0x0, %eax jne 0x4cc5b movq 0x28(%rsp), %rdi movl 0x1c(%rsp), %esi callq 0x27fa0 movl %eax, 0x34(%rsp) jmp 0x4cc8d jmp 0x4cc5d movl 0x1c(%rsp), %eax addl $0x1, %eax movl %eax, 0x1c(%rsp) jmp 0x4cbe7 callq 0xe090 movq 0x28(%rsp), %rdi movq 0x20(%rsp), %rsi callq 0x284c0 movl %eax, 0x1c(%rsp) movl 0x1c(%rsp), %eax movl %eax, 0x34(%rsp) movl 0x34(%rsp), %eax addq $0x38, %rsp retq nopw %cs:(%rax,%rax)
find_atom: sub rsp, 38h mov [rsp+38h+var_10], rdi mov [rsp+38h+var_18], rsi mov rax, [rsp+38h+var_18] movzx eax, byte ptr [rax] cmp eax, 5Bh ; '[' jnz loc_4CC72 mov rax, [rsp+38h+var_18] add rax, 1 mov [rsp+38h+var_18], rax mov rdi, [rsp+38h+var_18] call _strlen sub rax, 1 mov [rsp+38h+var_20], eax mov [rsp+38h+var_1C], 0D3h loc_4CBE7: cmp [rsp+38h+var_1C], 0E0h jnb short loc_4CC6D mov rax, [rsp+38h+var_10] mov rax, [rax+18h] mov rax, [rax+68h] mov ecx, [rsp+38h+var_1C] mov rax, [rax+rcx*8] mov [rsp+38h+var_28], rax mov rax, [rsp+38h+var_28] mov [rsp+38h+var_30], rax mov rax, [rsp+38h+var_30] mov rax, [rax+4] and rax, 7FFFFFFFh cmp eax, [rsp+38h+var_20] jnz short loc_4CC5B mov rdi, [rsp+38h+var_30] add rdi, 18h mov rsi, [rsp+38h+var_18] movsxd rdx, [rsp+38h+var_20] call _memcmp cmp eax, 0 jnz short loc_4CC5B mov rdi, [rsp+38h+var_10] mov esi, [rsp+38h+var_1C] call JS_DupAtom mov [rsp+38h+var_4], eax jmp short loc_4CC8D loc_4CC5B: jmp short $+2 loc_4CC5D: mov eax, [rsp+38h+var_1C] add eax, 1 mov [rsp+38h+var_1C], eax jmp loc_4CBE7 loc_4CC6D: call _abort loc_4CC72: mov rdi, [rsp+38h+var_10] mov rsi, [rsp+38h+var_18] call JS_NewAtom mov [rsp+38h+var_1C], eax mov eax, [rsp+38h+var_1C] mov [rsp+38h+var_4], eax loc_4CC8D: mov eax, [rsp+38h+var_4] add rsp, 38h retn
long long find_atom(long long a1, unsigned __int8 *a2) { const char *v2; // rdi long long v4; // [rsp+8h] [rbp-30h] int v5; // [rsp+18h] [rbp-20h] unsigned int i; // [rsp+1Ch] [rbp-1Ch] if ( *a2 == 91 ) { v2 = (const char *)(a2 + 1); v5 = strlen(a2 + 1) - 1; for ( i = 211; ; ++i ) { if ( i >= 0xE0 ) abort(v2); v4 = *(_QWORD *)(*(_QWORD *)(*(_QWORD *)(a1 + 24) + 104LL) + 8LL * i); if ( (*(_DWORD *)(v4 + 4) & 0x7FFFFFFF) == v5 ) { v2 = (const char *)(v4 + 24); if ( !(unsigned int)memcmp(v4 + 24, a2 + 1, v5) ) break; } } return (unsigned int)JS_DupAtom(a1, i); } else { return (unsigned int)JS_NewAtom(a1, a2); } }
find_atom: SUB RSP,0x38 MOV qword ptr [RSP + 0x28],RDI MOV qword ptr [RSP + 0x20],RSI MOV RAX,qword ptr [RSP + 0x20] MOVZX EAX,byte ptr [RAX] CMP EAX,0x5b JNZ 0x0014cc72 MOV RAX,qword ptr [RSP + 0x20] ADD RAX,0x1 MOV qword ptr [RSP + 0x20],RAX MOV RDI,qword ptr [RSP + 0x20] CALL 0x0010e240 SUB RAX,0x1 MOV dword ptr [RSP + 0x18],EAX MOV dword ptr [RSP + 0x1c],0xd3 LAB_0014cbe7: CMP dword ptr [RSP + 0x1c],0xe0 JNC 0x0014cc6d MOV RAX,qword ptr [RSP + 0x28] MOV RAX,qword ptr [RAX + 0x18] MOV RAX,qword ptr [RAX + 0x68] MOV ECX,dword ptr [RSP + 0x1c] MOV RAX,qword ptr [RAX + RCX*0x8] MOV qword ptr [RSP + 0x10],RAX MOV RAX,qword ptr [RSP + 0x10] MOV qword ptr [RSP + 0x8],RAX MOV RAX,qword ptr [RSP + 0x8] MOV RAX,qword ptr [RAX + 0x4] AND RAX,0x7fffffff CMP EAX,dword ptr [RSP + 0x18] JNZ 0x0014cc5b MOV RDI,qword ptr [RSP + 0x8] ADD RDI,0x18 MOV RSI,qword ptr [RSP + 0x20] MOVSXD RDX,dword ptr [RSP + 0x18] CALL 0x0010e480 CMP EAX,0x0 JNZ 0x0014cc5b MOV RDI,qword ptr [RSP + 0x28] MOV ESI,dword ptr [RSP + 0x1c] CALL 0x00127fa0 MOV dword ptr [RSP + 0x34],EAX JMP 0x0014cc8d LAB_0014cc5b: JMP 0x0014cc5d LAB_0014cc5d: MOV EAX,dword ptr [RSP + 0x1c] ADD EAX,0x1 MOV dword ptr [RSP + 0x1c],EAX JMP 0x0014cbe7 LAB_0014cc6d: CALL 0x0010e090 LAB_0014cc72: MOV RDI,qword ptr [RSP + 0x28] MOV RSI,qword ptr [RSP + 0x20] CALL 0x001284c0 MOV dword ptr [RSP + 0x1c],EAX MOV EAX,dword ptr [RSP + 0x1c] MOV dword ptr [RSP + 0x34],EAX LAB_0014cc8d: MOV EAX,dword ptr [RSP + 0x34] ADD RSP,0x38 RET
int4 find_atom(long param_1,char *param_2) { long lVar1; uint uVar2; int iVar3; int4 uVar4; size_t sVar5; uint local_1c; if (*param_2 != '[') { uVar4 = JS_NewAtom(param_1,param_2); return uVar4; } sVar5 = strlen(param_2 + 1); uVar2 = (int)sVar5 - 1; local_1c = 0xd3; while( true ) { if (0xdf < local_1c) { /* WARNING: Subroutine does not return */ abort(); } lVar1 = *(long *)(*(long *)(*(long *)(param_1 + 0x18) + 0x68) + (ulong)local_1c * 8); if ((((uint)*(int8 *)(lVar1 + 4) & 0x7fffffff) == uVar2) && (iVar3 = memcmp((void *)(lVar1 + 0x18),param_2 + 1,(long)(int)uVar2), iVar3 == 0)) break; local_1c = local_1c + 1; } uVar4 = JS_DupAtom(param_1,local_1c); return uVar4; }
47,406
find_atom
bluesky950520[P]quickjs/quickjs.c
static JSAtom find_atom(JSContext *ctx, const char *name) { JSAtom atom; int len; if (*name == '[') { name++; len = strlen(name) - 1; /* We assume 8 bit non null strings, which is the case for these symbols */ for(atom = JS_ATOM_Symbol_toPrimitive; atom < JS_ATOM_END; atom++) { JSAtomStruct *p = ctx->rt->atom_array[atom]; JSString *str = p; if (str->len == len && !memcmp(str->u.str8, name, len)) return JS_DupAtom(ctx, atom); } abort(); } else { atom = JS_NewAtom(ctx, name); } return atom; }
O1
c
find_atom: pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx pushq %rax movq %rsi, %rbx movq %rdi, %r15 cmpb $0x5b, (%rsi) jne 0x3301b incq %rbx movq %rbx, %rdi callq 0xe240 movq %rax, %r14 decl %r14d movq 0x18(%r15), %rax movq 0x68(%rax), %r15 movl $0xd3, %r12d movl $0x7fffffff, %r13d # imm = 0x7FFFFFFF movq (%r15,%r12,8), %rdi movl 0x4(%rdi), %ecx andl %r13d, %ecx movb $0x1, %al cmpl %r14d, %ecx jne 0x33006 addq $0x18, %rdi movq %rbx, %rsi movq %r14, %rdx callq 0xe6a0 testl %eax, %eax setne %al cmovel %r12d, %ebp testb %al, %al je 0x3303f incq %r12 cmpq $0xe0, %r12 jne 0x32fdd callq 0xe090 movq %rbx, %rdi callq 0xe240 movq %r15, %rdi movq %rbx, %rsi movq %rax, %rdx addq $0x8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp jmp 0x1fdc0 movl %ebp, %eax addq $0x8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
find_atom: push rbp push r15 push r14 push r13 push r12 push rbx push rax mov rbx, rsi mov r15, rdi cmp byte ptr [rsi], 5Bh ; '[' jnz short loc_3301B inc rbx mov rdi, rbx call _strlen mov r14, rax dec r14d mov rax, [r15+18h] mov r15, [rax+68h] mov r12d, 0D3h mov r13d, 7FFFFFFFh loc_32FDD: mov rdi, [r15+r12*8] mov ecx, [rdi+4] and ecx, r13d mov al, 1 cmp ecx, r14d jnz short loc_33006 add rdi, 18h mov rsi, rbx mov rdx, r14 call _bcmp test eax, eax setnz al cmovz ebp, r12d loc_33006: test al, al jz short loc_3303F inc r12 cmp r12, 0E0h jnz short loc_32FDD call _abort loc_3301B: mov rdi, rbx call _strlen mov rdi, r15 mov rsi, rbx mov rdx, rax add rsp, 8 pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp jmp JS_NewAtomLen loc_3303F: mov eax, ebp add rsp, 8 pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
long long find_atom(long long a1, unsigned __int8 *a2) { unsigned int v2; // ebp long long v3; // r14 long long v4; // r15 long long v5; // r12 long long v6; // rdi long long v7; // rcx bool v8; // al long long v9; // rax if ( *a2 == 91 ) { v3 = (unsigned int)strlen(a2 + 1) - 1; v4 = *(_QWORD *)(*(_QWORD *)(a1 + 24) + 104LL); v5 = 211LL; while ( 1 ) { v6 = *(_QWORD *)(v4 + 8 * v5); v7 = *(_DWORD *)(v6 + 4) & 0x7FFFFFFF; v8 = 1; if ( (_DWORD)v7 == (_DWORD)v3 ) { v6 += 24LL; v8 = (unsigned int)bcmp(v6, a2 + 1, v3, v7) != 0; if ( !v8 ) v2 = v5; } if ( !v8 ) break; if ( ++v5 == 224 ) abort((const char *)v6); } return v2; } else { v9 = strlen(a2); return JS_NewAtomLen(a1, a2, v9); } }
47,407
inline_mysql_mutex_init
eloqsql/include/mysql/psi/mysql_thread.h
static inline int inline_mysql_mutex_init( #ifdef HAVE_PSI_MUTEX_INTERFACE PSI_mutex_key key, #endif mysql_mutex_t *that, const pthread_mutexattr_t *attr #ifdef SAFE_MUTEX , const char *src_name, const char *src_file, uint src_line #endif ) { #ifdef HAVE_PSI_MUTEX_INTERFACE that->m_psi= PSI_MUTEX_CALL(init_mutex)(key, &that->m_mutex); #else that->m_psi= NULL; #endif #ifdef COROUTINE_ENABLED that->l.data= that; that->l.prev= that->l.next= NULL; #endif #ifdef SAFE_MUTEX return safe_mutex_init(&that->m_mutex, attr, src_name, src_file, src_line); #else return pthread_mutex_init(&that->m_mutex, attr); #endif }
O0
c
inline_mysql_mutex_init: pushq %rbp movq %rsp, %rbp subq $0x20, %rsp movl %edi, -0x4(%rbp) movq %rsi, -0x10(%rbp) movq %rdx, -0x18(%rbp) leaq 0x1d249e(%rip), %rax # 0x2c8038 movq (%rax), %rax movq 0x40(%rax), %rax movl -0x4(%rbp), %edi movq -0x10(%rbp), %rsi callq *%rax movq %rax, %rcx movq -0x10(%rbp), %rax movq %rcx, 0x40(%rax) movq -0x10(%rbp), %rcx movq -0x10(%rbp), %rax movq %rcx, 0x38(%rax) movq -0x10(%rbp), %rax movq $0x0, 0x30(%rax) movq -0x10(%rbp), %rax movq $0x0, 0x28(%rax) movq -0x10(%rbp), %rdi movq -0x18(%rbp), %rsi callq 0x29310 addq $0x20, %rsp popq %rbp retq nopl (%rax)
inline_mysql_mutex_init_10: push rbp mov rbp, rsp sub rsp, 20h mov [rbp+var_4], edi mov [rbp+var_10], rsi mov [rbp+var_18], rdx lea rax, PSI_server mov rax, [rax] mov rax, [rax+40h] mov edi, [rbp+var_4] mov rsi, [rbp+var_10] call rax mov rcx, rax mov rax, [rbp+var_10] mov [rax+40h], rcx mov rcx, [rbp+var_10] mov rax, [rbp+var_10] mov [rax+38h], rcx mov rax, [rbp+var_10] mov qword ptr [rax+30h], 0 mov rax, [rbp+var_10] mov qword ptr [rax+28h], 0 mov rdi, [rbp+var_10] mov rsi, [rbp+var_18] call _pthread_mutex_init add rsp, 20h pop rbp retn
long long inline_mysql_mutex_init_10(unsigned int a1, _QWORD *a2, long long a3) { a2[8] = ((long long ( *)(_QWORD, _QWORD *))PSI_server[8])(a1, a2); a2[7] = a2; a2[6] = 0LL; a2[5] = 0LL; return pthread_mutex_init(a2, a3); }
inline_mysql_mutex_init: PUSH RBP MOV RBP,RSP SUB RSP,0x20 MOV dword ptr [RBP + -0x4],EDI MOV qword ptr [RBP + -0x10],RSI MOV qword ptr [RBP + -0x18],RDX LEA RAX,[0x3c8038] MOV RAX,qword ptr [RAX] MOV RAX,qword ptr [RAX + 0x40] MOV EDI,dword ptr [RBP + -0x4] MOV RSI,qword ptr [RBP + -0x10] CALL RAX MOV RCX,RAX MOV RAX,qword ptr [RBP + -0x10] MOV qword ptr [RAX + 0x40],RCX MOV RCX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RBP + -0x10] MOV qword ptr [RAX + 0x38],RCX MOV RAX,qword ptr [RBP + -0x10] MOV qword ptr [RAX + 0x30],0x0 MOV RAX,qword ptr [RBP + -0x10] MOV qword ptr [RAX + 0x28],0x0 MOV RDI,qword ptr [RBP + -0x10] MOV RSI,qword ptr [RBP + -0x18] CALL 0x00129310 ADD RSP,0x20 POP RBP RET
void inline_mysql_mutex_init (int4 param_1,pthread_mutex_t *param_2,pthread_mutexattr_t *param_3) { int8 uVar1; uVar1 = (**(code **)(PSI_server + 0x40))(param_1,param_2); *(int8 *)((long)param_2 + 0x40) = uVar1; *(pthread_mutex_t **)((long)param_2 + 0x38) = param_2; *(int8 *)((long)param_2 + 0x30) = 0; param_2[1].__align = 0; pthread_mutex_init(param_2,param_3); return; }
47,408
JS_ToFloat64
bluesky950520[P]quickjs/quickjs.c
int JS_ToFloat64(JSContext *ctx, double *pres, JSValue val) { return JS_ToFloat64Free(ctx, pres, js_dup(val)); }
O1
c
JS_ToFloat64: movq %rdx, -0x8(%rsp) cmpl $-0x9, %ecx jb 0x27692 movq -0x8(%rsp), %rax incl (%rax) cmpl $0x2, %ecx ja 0x276a1 cvtsi2sd %edx, %xmm0 movsd %xmm0, (%rsi) jmp 0x276ad cmpl $0x7, %ecx jne 0x3df2f movq %rdx, (%rsi) xorl %eax, %eax retq
JS_ToFloat64: mov [rsp+var_8], rdx cmp ecx, 0FFFFFFF7h jb short loc_27692 mov rax, [rsp+var_8] inc dword ptr [rax] loc_27692: cmp ecx, 2 ja short loc_276A1 cvtsi2sd xmm0, edx movsd qword ptr [rsi], xmm0 jmp short loc_276AD loc_276A1: cmp ecx, 7 jnz __JS_ToFloat64Free mov [rsi], rdx loc_276AD: xor eax, eax retn
long long JS_ToFloat64(long long a1, double *a2, _DWORD *a3, unsigned int a4) { if ( a4 >= 0xFFFFFFF7 ) ++*a3; if ( a4 <= 2 ) { *a2 = (double)(int)a3; return 0LL; } if ( a4 == 7 ) { *(_QWORD *)a2 = a3; return 0LL; } return _JS_ToFloat64Free(a1, a2, a3); }
JS_ToFloat64: MOV qword ptr [RSP + -0x8],RDX CMP ECX,-0x9 JC 0x00127692 MOV RAX,qword ptr [RSP + -0x8] INC dword ptr [RAX] LAB_00127692: CMP ECX,0x2 JA 0x001276a1 CVTSI2SD XMM0,EDX MOVSD qword ptr [RSI],XMM0 JMP 0x001276ad LAB_001276a1: CMP ECX,0x7 JNZ 0x0013df2f MOV qword ptr [RSI],RDX LAB_001276ad: XOR EAX,EAX RET
int8 JS_ToFloat64(long param_1,double *param_2,int *param_3,int8 param_4) { double dVar1; int8 uVar2; uint uVar3; int iVar4; int1 auVar5 [16]; double dStack_30; int *piStack_28; uVar3 = (uint)param_4; if (0xfffffff6 < uVar3) { *param_3 = *param_3 + 1; } if (uVar3 < 3) { *param_2 = (double)(int)param_3; } else { if (uVar3 != 7) { piStack_28 = param_3; auVar5 = JS_ToNumberHintFree(param_1,param_3,param_4,0); dVar1 = auVar5._0_8_; iVar4 = auVar5._8_4_; if (iVar4 == 6) { uVar2 = 0xffffffff; dStack_30 = DAT_0019e8e8; } else { piStack_28 = (int *)dVar1; if (iVar4 == -9) { bf_get_float64((long)dVar1 + 8,&dStack_30,0); JS_FreeValueRT(*(int8 *)(param_1 + 0x18),dVar1,auVar5._8_8_); } else { dStack_30 = dVar1; if (iVar4 != 7) { if (iVar4 != 0) { /* WARNING: Subroutine does not return */ abort(); } piStack_28._0_4_ = auVar5._0_4_; dStack_30 = (double)(int)piStack_28; } } uVar2 = 0; } *param_2 = dStack_30; return uVar2; } *param_2 = (double)param_3; } return 0; }
47,409
google::protobuf::compiler::Version::SharedCtor(google::protobuf::Arena*, bool)
aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/compiler/plugin.pb.cc
inline void Version::SharedCtor( ::_pb::Arena* arena, bool is_message_owned) { (void)arena; (void)is_message_owned; new (&_impl_) Impl_{ decltype(_impl_._has_bits_){} , /*decltype(_impl_._cached_size_)*/{} , decltype(_impl_.suffix_){} , decltype(_impl_.major_){0} , decltype(_impl_.minor_){0} , decltype(_impl_.patch_){0} }; _impl_.suffix_.InitDefault(); #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING _impl_.suffix_.Set("", GetArenaForAllocation()); #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING }
O0
cpp
google::protobuf::compiler::Version::SharedCtor(google::protobuf::Arena*, bool): subq $0x48, %rsp movb %dl, %al movq %rdi, 0x38(%rsp) movq %rsi, 0x30(%rsp) andb $0x1, %al movb %al, 0x2f(%rsp) movq 0x38(%rsp), %rax movq %rax, 0x8(%rsp) addq $0x10, %rax movq %rax, 0x10(%rsp) movq %rax, 0x40(%rsp) movq 0x40(%rsp), %rax movq %rax, %rcx addq $0x4, %rcx movq %rcx, 0x18(%rsp) movq %rax, 0x20(%rsp) movq 0x20(%rsp), %rax movq 0x18(%rsp), %rcx movl $0x0, (%rax) addq $0x4, %rax cmpq %rcx, %rax movq %rax, 0x20(%rsp) jne 0xaeca4 movq 0x10(%rsp), %rdi addq $0x4, %rdi movq %rdi, (%rsp) xorl %esi, %esi movl $0x4, %edx callq 0x21350 movq (%rsp), %rdi callq 0xaed70 movq 0x10(%rsp), %rdi addq $0x8, %rdi xorl %esi, %esi movl $0x8, %edx callq 0x21350 movq 0x10(%rsp), %rax movq 0x8(%rsp), %rdi movl $0x0, 0x10(%rax) movl $0x0, 0x14(%rax) movl $0x0, 0x18(%rax) addq $0x10, %rdi addq $0x8, %rdi callq 0xaed90 addq $0x48, %rsp retq nopw (%rax,%rax)
_ZN6google8protobuf8compiler7Version10SharedCtorEPNS0_5ArenaEb: sub rsp, 48h mov al, dl mov [rsp+48h+var_10], rdi mov [rsp+48h+var_18], rsi and al, 1 mov [rsp+48h+var_19], al mov rax, [rsp+48h+var_10] mov [rsp+48h+var_40], rax add rax, 10h mov [rsp+48h+var_38], rax mov [rsp+48h+var_8], rax mov rax, [rsp+48h+var_8] mov rcx, rax add rcx, 4 mov [rsp+48h+var_30], rcx mov [rsp+48h+var_28], rax loc_AECA4: mov rax, [rsp+48h+var_28] mov rcx, [rsp+48h+var_30] mov dword ptr [rax], 0 add rax, 4 cmp rax, rcx mov [rsp+48h+var_28], rax jnz short loc_AECA4 mov rdi, [rsp+48h+var_38] add rdi, 4 mov [rsp+48h+var_48], rdi xor esi, esi mov edx, 4 call _memset mov rdi, [rsp+48h+var_48]; this call _ZN6google8protobuf8internal10CachedSizeC2Ev; google::protobuf::internal::CachedSize::CachedSize(void) mov rdi, [rsp+48h+var_38] add rdi, 8 xor esi, esi mov edx, 8 call _memset mov rax, [rsp+48h+var_38] mov rdi, [rsp+48h+var_40] mov dword ptr [rax+10h], 0 mov dword ptr [rax+14h], 0 mov dword ptr [rax+18h], 0 add rdi, 10h add rdi, 8; this call _ZN6google8protobuf8internal14ArenaStringPtr11InitDefaultEv; google::protobuf::internal::ArenaStringPtr::InitDefault(void) add rsp, 48h retn
long long google::protobuf::compiler::Version::SharedCtor( google::protobuf::compiler::Version *this, google::protobuf::Arena *a2) { google::protobuf::compiler::Version *v3; // [rsp+20h] [rbp-28h] v3 = (google::protobuf::compiler::Version *)((char *)this + 16); do { *(_DWORD *)v3 = 0; v3 = (google::protobuf::compiler::Version *)((char *)v3 + 4); } while ( v3 != (google::protobuf::compiler::Version *)((char *)this + 20) ); memset((char *)this + 20, 0LL, 4LL); google::protobuf::internal::CachedSize::CachedSize((google::protobuf::compiler::Version *)((char *)this + 20)); memset((char *)this + 24, 0LL, 8LL); *((_DWORD *)this + 8) = 0; *((_DWORD *)this + 9) = 0; *((_DWORD *)this + 10) = 0; return google::protobuf::internal::ArenaStringPtr::InitDefault((google::protobuf::compiler::Version *)((char *)this + 24)); }
SharedCtor: SUB RSP,0x48 MOV AL,DL MOV qword ptr [RSP + 0x38],RDI MOV qword ptr [RSP + 0x30],RSI AND AL,0x1 MOV byte ptr [RSP + 0x2f],AL MOV RAX,qword ptr [RSP + 0x38] MOV qword ptr [RSP + 0x8],RAX ADD RAX,0x10 MOV qword ptr [RSP + 0x10],RAX MOV qword ptr [RSP + 0x40],RAX MOV RAX,qword ptr [RSP + 0x40] MOV RCX,RAX ADD RCX,0x4 MOV qword ptr [RSP + 0x18],RCX MOV qword ptr [RSP + 0x20],RAX LAB_001aeca4: MOV RAX,qword ptr [RSP + 0x20] MOV RCX,qword ptr [RSP + 0x18] MOV dword ptr [RAX],0x0 ADD RAX,0x4 CMP RAX,RCX MOV qword ptr [RSP + 0x20],RAX JNZ 0x001aeca4 MOV RDI,qword ptr [RSP + 0x10] ADD RDI,0x4 MOV qword ptr [RSP],RDI XOR ESI,ESI MOV EDX,0x4 CALL 0x00121350 MOV RDI,qword ptr [RSP] CALL 0x001aed70 MOV RDI,qword ptr [RSP + 0x10] ADD RDI,0x8 XOR ESI,ESI MOV EDX,0x8 CALL 0x00121350 MOV RAX,qword ptr [RSP + 0x10] MOV RDI,qword ptr [RSP + 0x8] MOV dword ptr [RAX + 0x10],0x0 MOV dword ptr [RAX + 0x14],0x0 MOV dword ptr [RAX + 0x18],0x0 ADD RDI,0x10 ADD RDI,0x8 CALL 0x001aed90 ADD RSP,0x48 RET
/* google::protobuf::compiler::Version::SharedCtor(google::protobuf::Arena*, bool) */ void google::protobuf::compiler::Version::SharedCtor(Arena *param_1,bool param_2) { Arena *local_28; local_28 = param_1 + 0x10; do { *(int4 *)local_28 = 0; local_28 = local_28 + 4; } while (local_28 != param_1 + 0x14); memset((CachedSize *)(param_1 + 0x14),0,4); internal::CachedSize::CachedSize((CachedSize *)(param_1 + 0x14)); memset(param_1 + 0x18,0,8); *(int4 *)(param_1 + 0x20) = 0; *(int4 *)(param_1 + 0x24) = 0; *(int4 *)(param_1 + 0x28) = 0; internal::ArenaStringPtr::InitDefault((ArenaStringPtr *)(param_1 + 0x18)); return; }
47,410
test_diagnostic_context_many
tsotchke[P]eshkol/tests/unit/test_diagnostics.c
static void test_diagnostic_context_many(void) { printf("Testing adding many diagnostics...\n"); Arena* arena = arena_create(1024); assert(arena != NULL); DiagnosticContext* context = diagnostic_context_create(arena); assert(context != NULL); // Create a source location SourceLocation location = source_location_create("test.esk", 10, 5, 3); // Add many diagnostics const int count = 100; char** messages = arena_alloc(arena, count * sizeof(char*)); for (int i = 0; i < count; i++) { char* message = arena_alloc(arena, 64); sprintf(message, "Diagnostic %d", i); messages[i] = message; DiagnosticSeverity severity = (DiagnosticSeverity)(i % 4); diagnostic_context_add(context, severity, location, message, NULL); } // Check the count assert(diagnostic_context_get_count(context) == count); // Check the error count int expected_error_count = count / 2; // DIAGNOSTIC_ERROR and DIAGNOSTIC_FATAL size_t actual_error_count = diagnostic_context_get_error_count(context); printf("Expected error count: %d, Actual error count: %zu\n", expected_error_count, actual_error_count); assert(actual_error_count == expected_error_count); // Print all diagnostics printf("All diagnostics:\n"); for (int i = 0; i < count; i++) { const Diagnostic* diagnostic = diagnostic_context_get(context, i); assert(diagnostic != NULL); printf("Diagnostic at index %d: '%s'\n", i, diagnostic->message); } // Check that we can get all diagnostics for (int i = 0; i < count; i++) { const Diagnostic* diagnostic = diagnostic_context_get(context, i); assert(diagnostic != NULL); // The messages are in reverse order, so we need to adjust the expected message char expected_message[64]; sprintf(expected_message, "Diagnostic %d", i); if (strcmp(diagnostic->message, expected_message) != 0) { printf("Message mismatch at index %d: expected '%s', got '%s'\n", i, expected_message, diagnostic->message); assert(false); } } arena_destroy(arena); printf("PASS: diagnostic_context_many\n"); }
O0
c
test_diagnostic_context_many: pushq %rbp movq %rsp, %rbp subq $0xe0, %rsp leaq 0x283c(%rip), %rdi # 0x483e movb $0x0, %al callq 0x1060 movl $0x400, %edi # imm = 0x400 callq 0x2330 movq %rax, -0x8(%rbp) cmpq $0x0, -0x8(%rbp) je 0x2020 jmp 0x203f leaq 0x2042(%rip), %rdi # 0x4069 leaq 0x2049(%rip), %rsi # 0x4077 movl $0xc3, %edx leaq 0x2828(%rip), %rcx # 0x4862 callq 0x1070 movq -0x8(%rbp), %rdi callq 0x2a60 movq %rax, -0x10(%rbp) cmpq $0x0, -0x10(%rbp) je 0x2055 jmp 0x2074 leaq 0x209d(%rip), %rdi # 0x40f9 leaq 0x2014(%rip), %rsi # 0x4077 movl $0xc6, %edx leaq 0x27f3(%rip), %rcx # 0x4862 callq 0x1070 leaq -0x28(%rbp), %rdi leaq 0x2175(%rip), %rsi # 0x41f4 movl $0xa, %edx movl $0x5, %ecx movl $0x3, %r8d callq 0x2a30 movl $0x64, -0x2c(%rbp) movq -0x8(%rbp), %rdi movl $0x320, %esi # imm = 0x320 callq 0x2430 movq %rax, -0x38(%rbp) movl $0x0, -0x3c(%rbp) cmpl $0x64, -0x3c(%rbp) jge 0x2140 movq -0x8(%rbp), %rdi movl $0x40, %esi callq 0x2430 movq %rax, -0x48(%rbp) movq -0x48(%rbp), %rdi movl -0x3c(%rbp), %edx leaq 0x27ac(%rip), %rsi # 0x488a movb $0x0, %al callq 0x10c0 movq -0x48(%rbp), %rdx movq -0x38(%rbp), %rax movslq -0x3c(%rbp), %rcx movq %rdx, (%rax,%rcx,8) movl -0x3c(%rbp), %eax movl $0x4, %ecx cltd idivl %ecx movl %edx, -0x4c(%rbp) movq -0x10(%rbp), %rdi movl -0x4c(%rbp), %esi movq -0x48(%rbp), %rdx leaq -0x28(%rbp), %rax xorl %ecx, %ecx movq (%rax), %r8 movq %r8, (%rsp) movq 0x8(%rax), %r8 movq %r8, 0x8(%rsp) movq 0x10(%rax), %rax movq %rax, 0x10(%rsp) callq 0x2b10 movl -0x3c(%rbp), %eax addl $0x1, %eax movl %eax, -0x3c(%rbp) jmp 0x20b4 movq -0x10(%rbp), %rdi callq 0x2cb0 cmpq $0x64, %rax jne 0x2151 jmp 0x2170 leaq 0x2740(%rip), %rdi # 0x4898 leaq 0x1f18(%rip), %rsi # 0x4077 movl $0xd8, %edx leaq 0x26f7(%rip), %rcx # 0x4862 callq 0x1070 movl $0x32, -0x50(%rbp) movq -0x10(%rbp), %rdi callq 0x2d70 movq %rax, -0x58(%rbp) movl -0x50(%rbp), %esi movq -0x58(%rbp), %rdx leaq 0x2735(%rip), %rdi # 0x48c7 movb $0x0, %al callq 0x1060 movq -0x58(%rbp), %rax movslq -0x50(%rbp), %rcx cmpq %rcx, %rax jne 0x21a8 jmp 0x21c7 leaq 0x274b(%rip), %rdi # 0x48fa leaq 0x1ec1(%rip), %rsi # 0x4077 movl $0xde, %edx leaq 0x26a0(%rip), %rcx # 0x4862 callq 0x1070 leaq 0x2757(%rip), %rdi # 0x4925 movb $0x0, %al callq 0x1060 movl $0x0, -0x5c(%rbp) cmpl $0x64, -0x5c(%rbp) jge 0x223f movq -0x10(%rbp), %rdi movslq -0x5c(%rbp), %rsi callq 0x2d00 movq %rax, -0x68(%rbp) cmpq $0x0, -0x68(%rbp) je 0x21fc jmp 0x221b leaq 0x2042(%rip), %rdi # 0x4245 leaq 0x1e6d(%rip), %rsi # 0x4077 movl $0xe4, %edx leaq 0x264c(%rip), %rcx # 0x4862 callq 0x1070 movl -0x5c(%rbp), %esi movq -0x68(%rbp), %rax movq 0x20(%rax), %rdx leaq 0x270a(%rip), %rdi # 0x4937 movb $0x0, %al callq 0x1060 movl -0x5c(%rbp), %eax addl $0x1, %eax movl %eax, -0x5c(%rbp) jmp 0x21dc movl $0x0, -0x6c(%rbp) cmpl $0x64, -0x6c(%rbp) jge 0x2309 movq -0x10(%rbp), %rdi movslq -0x6c(%rbp), %rsi callq 0x2d00 movq %rax, -0x78(%rbp) cmpq $0x0, -0x78(%rbp) je 0x226a jmp 0x2289 leaq 0x1fd4(%rip), %rdi # 0x4245 leaq 0x1dff(%rip), %rsi # 0x4077 movl $0xeb, %edx leaq 0x25de(%rip), %rcx # 0x4862 callq 0x1070 leaq -0xc0(%rbp), %rdi movl -0x6c(%rbp), %edx leaq 0x25f0(%rip), %rsi # 0x488a movb $0x0, %al callq 0x10c0 movq -0x78(%rbp), %rax movq 0x20(%rax), %rdi leaq -0xc0(%rbp), %rsi callq 0x1080 cmpl $0x0, %eax je 0x22f9 movl -0x6c(%rbp), %esi leaq -0xc0(%rbp), %rdx movq -0x78(%rbp), %rax movq 0x20(%rax), %rcx leaq 0x2682(%rip), %rdi # 0x4955 movb $0x0, %al callq 0x1060 leaq 0x26ab(%rip), %rdi # 0x498c leaq 0x1d8f(%rip), %rsi # 0x4077 movl $0xf2, %edx leaq 0x256e(%rip), %rcx # 0x4862 callq 0x1070 jmp 0x22fb movl -0x6c(%rbp), %eax addl $0x1, %eax movl %eax, -0x6c(%rbp) jmp 0x2246 movq -0x8(%rbp), %rdi callq 0x2910 leaq 0x2679(%rip), %rdi # 0x4992 movb $0x0, %al callq 0x1060 addq $0xe0, %rsp popq %rbp retq nopl (%rax)
test_diagnostic_context_many: push rbp mov rbp, rsp sub rsp, 0E0h lea rdi, aTestingAddingM; "Testing adding many diagnostics...\n" mov al, 0 call _printf mov edi, 400h call arena_create mov [rbp+var_8], rax cmp [rbp+var_8], 0 jz short loc_2020 jmp short loc_203F loc_2020: lea rdi, aArenaNull; "arena != NULL" lea rsi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"... mov edx, 0C3h lea rcx, aVoidTestDiagno_3; "void test_diagnostic_context_many(void)" call ___assert_fail loc_203F: mov rdi, [rbp+var_8] call diagnostic_context_create mov [rbp+var_10], rax cmp [rbp+var_10], 0 jz short loc_2055 jmp short loc_2074 loc_2055: lea rdi, aContextNull; "context != NULL" lea rsi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"... mov edx, 0C6h lea rcx, aVoidTestDiagno_3; "void test_diagnostic_context_many(void)" call ___assert_fail loc_2074: lea rdi, [rbp+var_28] lea rsi, aTestEsk; "test.esk" mov edx, 0Ah mov ecx, 5 mov r8d, 3 call source_location_create mov [rbp+var_2C], 64h ; 'd' mov rdi, [rbp+var_8] mov esi, 320h call arena_alloc mov [rbp+var_38], rax mov [rbp+var_3C], 0 loc_20B4: cmp [rbp+var_3C], 64h ; 'd' jge loc_2140 mov rdi, [rbp+var_8] mov esi, 40h ; '@' call arena_alloc mov [rbp+var_48], rax mov rdi, [rbp+var_48] mov edx, [rbp+var_3C] lea rsi, aDiagnosticD; "Diagnostic %d" mov al, 0 call _sprintf mov rdx, [rbp+var_48] mov rax, [rbp+var_38] movsxd rcx, [rbp+var_3C] mov [rax+rcx*8], rdx mov eax, [rbp+var_3C] mov ecx, 4 cdq idiv ecx mov [rbp+var_4C], edx mov rdi, [rbp+var_10] mov esi, [rbp+var_4C] mov rdx, [rbp+var_48] lea rax, [rbp+var_28] xor ecx, ecx mov r8, [rax] mov [rsp+0E0h+var_E0], r8 mov r8, [rax+8] mov [rsp+0E0h+var_D8], r8 mov rax, [rax+10h] mov [rsp+0E0h+var_D0], rax call diagnostic_context_add mov eax, [rbp+var_3C] add eax, 1 mov [rbp+var_3C], eax jmp loc_20B4 loc_2140: mov rdi, [rbp+var_10] call diagnostic_context_get_count cmp rax, 64h ; 'd' jnz short loc_2151 jmp short loc_2170 loc_2151: lea rdi, aDiagnosticCont_9; "diagnostic_context_get_count(context) ="... lea rsi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"... mov edx, 0D8h lea rcx, aVoidTestDiagno_3; "void test_diagnostic_context_many(void)" call ___assert_fail loc_2170: mov [rbp+var_50], 32h ; '2' mov rdi, [rbp+var_10] call diagnostic_context_get_error_count mov [rbp+var_58], rax mov esi, [rbp+var_50] mov rdx, [rbp+var_58] lea rdi, aExpectedErrorC; "Expected error count: %d, Actual error "... mov al, 0 call _printf mov rax, [rbp+var_58] movsxd rcx, [rbp+var_50] cmp rax, rcx jnz short loc_21A8 jmp short loc_21C7 loc_21A8: lea rdi, aActualErrorCou; "actual_error_count == expected_error_co"... lea rsi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"... mov edx, 0DEh lea rcx, aVoidTestDiagno_3; "void test_diagnostic_context_many(void)" call ___assert_fail loc_21C7: lea rdi, aAllDiagnostics_0; "All diagnostics:\n" mov al, 0 call _printf mov [rbp+var_5C], 0 loc_21DC: cmp [rbp+var_5C], 64h ; 'd' jge short loc_223F mov rdi, [rbp+var_10] movsxd rsi, [rbp+var_5C] call diagnostic_context_get mov [rbp+var_68], rax cmp [rbp+var_68], 0 jz short loc_21FC jmp short loc_221B loc_21FC: lea rdi, aDiagnosticNull; "diagnostic != NULL" lea rsi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"... mov edx, 0E4h lea rcx, aVoidTestDiagno_3; "void test_diagnostic_context_many(void)" call ___assert_fail loc_221B: mov esi, [rbp+var_5C] mov rax, [rbp+var_68] mov rdx, [rax+20h] lea rdi, aDiagnosticAtIn; "Diagnostic at index %d: '%s'\n" mov al, 0 call _printf mov eax, [rbp+var_5C] add eax, 1 mov [rbp+var_5C], eax jmp short loc_21DC loc_223F: mov [rbp+var_6C], 0 loc_2246: cmp [rbp+var_6C], 64h ; 'd' jge loc_2309 mov rdi, [rbp+var_10] movsxd rsi, [rbp+var_6C] call diagnostic_context_get mov [rbp+var_78], rax cmp [rbp+var_78], 0 jz short loc_226A jmp short loc_2289 loc_226A: lea rdi, aDiagnosticNull; "diagnostic != NULL" lea rsi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"... mov edx, 0EBh lea rcx, aVoidTestDiagno_3; "void test_diagnostic_context_many(void)" call ___assert_fail loc_2289: lea rdi, [rbp+var_C0] mov edx, [rbp+var_6C] lea rsi, aDiagnosticD; "Diagnostic %d" mov al, 0 call _sprintf mov rax, [rbp+var_78] mov rdi, [rax+20h] lea rsi, [rbp+var_C0] call _strcmp cmp eax, 0 jz short loc_22F9 mov esi, [rbp+var_6C] lea rdx, [rbp+var_C0] mov rax, [rbp+var_78] mov rcx, [rax+20h] lea rdi, aMessageMismatc; "Message mismatch at index %d: expected "... mov al, 0 call _printf lea rdi, aFalse; "false" lea rsi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"... mov edx, 0F2h lea rcx, aVoidTestDiagno_3; "void test_diagnostic_context_many(void)" call ___assert_fail loc_22F9: jmp short $+2 loc_22FB: mov eax, [rbp+var_6C] add eax, 1 mov [rbp+var_6C], eax jmp loc_2246 loc_2309: mov rdi, [rbp+var_8] call arena_destroy lea rdi, aPassDiagnostic_3; "PASS: diagnostic_context_many\n" mov al, 0 call _printf add rsp, 0E0h pop rbp retn
long long test_diagnostic_context_many(long long a1, long long a2, long long a3) { int v3; // r9d char v5[72]; // [rsp+20h] [rbp-C0h] BYREF long long v6; // [rsp+68h] [rbp-78h] int k; // [rsp+74h] [rbp-6Ch] long long v8; // [rsp+78h] [rbp-68h] int j; // [rsp+84h] [rbp-5Ch] long long error_count; // [rsp+88h] [rbp-58h] int v11; // [rsp+90h] [rbp-50h] int v12; // [rsp+94h] [rbp-4Ch] long long v13; // [rsp+98h] [rbp-48h] int i; // [rsp+A4h] [rbp-3Ch] long long v15; // [rsp+A8h] [rbp-38h] int v16; // [rsp+B4h] [rbp-2Ch] long long v17; // [rsp+B8h] [rbp-28h] BYREF long long v18; // [rsp+C0h] [rbp-20h] long long v19; // [rsp+C8h] [rbp-18h] long long v20; // [rsp+D0h] [rbp-10h] long long v21; // [rsp+D8h] [rbp-8h] printf("Testing adding many diagnostics...\n", a2, a3); v21 = arena_create(1024LL); if ( !v21 ) __assert_fail( "arena != NULL", "/workspace/llm4binary/github/2025_star3/tsotchke[P]eshkol/tests/unit/test_diagnostics.c", 195LL, "void test_diagnostic_context_many(void)"); v20 = diagnostic_context_create(v21); if ( !v20 ) __assert_fail( "context != NULL", "/workspace/llm4binary/github/2025_star3/tsotchke[P]eshkol/tests/unit/test_diagnostics.c", 198LL, "void test_diagnostic_context_many(void)"); source_location_create(&v17, "test.esk", 10LL, 5LL, 3LL); v16 = 100; v15 = arena_alloc(v21, 800LL); for ( i = 0; i < 100; ++i ) { v13 = arena_alloc(v21, 64LL); sprintf(v13, "Diagnostic %d", i); *(_QWORD *)(v15 + 8LL * i) = v13; v12 = i % 4; diagnostic_context_add(v20, i % 4, v13, 0, v18, v3, v17, v18, v19); } if ( diagnostic_context_get_count(v20) != 100 ) __assert_fail( "diagnostic_context_get_count(context) == count", "/workspace/llm4binary/github/2025_star3/tsotchke[P]eshkol/tests/unit/test_diagnostics.c", 216LL, "void test_diagnostic_context_many(void)"); v11 = 50; error_count = diagnostic_context_get_error_count(v20); printf("Expected error count: %d, Actual error count: %zu\n", 50, error_count); if ( error_count != 50 ) __assert_fail( "actual_error_count == expected_error_count", "/workspace/llm4binary/github/2025_star3/tsotchke[P]eshkol/tests/unit/test_diagnostics.c", 222LL, "void test_diagnostic_context_many(void)"); printf("All diagnostics:\n"); for ( j = 0; j < 100; ++j ) { v8 = diagnostic_context_get(v20, j); if ( !v8 ) __assert_fail( "diagnostic != NULL", "/workspace/llm4binary/github/2025_star3/tsotchke[P]eshkol/tests/unit/test_diagnostics.c", 228LL, "void test_diagnostic_context_many(void)"); printf("Diagnostic at index %d: '%s'\n", j, *(const char **)(v8 + 32)); } for ( k = 0; k < 100; ++k ) { v6 = diagnostic_context_get(v20, k); if ( !v6 ) __assert_fail( "diagnostic != NULL", "/workspace/llm4binary/github/2025_star3/tsotchke[P]eshkol/tests/unit/test_diagnostics.c", 235LL, "void test_diagnostic_context_many(void)"); sprintf(v5, "Diagnostic %d", k); if ( (unsigned int)strcmp(*(_QWORD *)(v6 + 32), v5) ) { printf("Message mismatch at index %d: expected '%s', got '%s'\n", k, v5, *(const char **)(v6 + 32)); __assert_fail( "false", "/workspace/llm4binary/github/2025_star3/tsotchke[P]eshkol/tests/unit/test_diagnostics.c", 242LL, "void test_diagnostic_context_many(void)"); } } arena_destroy(v21); return printf("PASS: diagnostic_context_many\n"); }
test_diagnostic_context_many: PUSH RBP MOV RBP,RSP SUB RSP,0xe0 LEA RDI,[0x10482c] MOV AL,0x0 CALL 0x00101060 MOV EDI,0x400 CALL 0x00102330 MOV qword ptr [RBP + -0x8],RAX CMP qword ptr [RBP + -0x8],0x0 JZ 0x00102020 JMP 0x0010203f LAB_00102020: LEA RDI,[0x104069] LEA RSI,[0x104077] MOV EDX,0xc3 LEA RCX,[0x104850] CALL 0x00101070 LAB_0010203f: MOV RDI,qword ptr [RBP + -0x8] CALL 0x00102a60 MOV qword ptr [RBP + -0x10],RAX CMP qword ptr [RBP + -0x10],0x0 JZ 0x00102055 JMP 0x00102074 LAB_00102055: LEA RDI,[0x1040e7] LEA RSI,[0x104077] MOV EDX,0xc6 LEA RCX,[0x104850] CALL 0x00101070 LAB_00102074: LEA RDI,[RBP + -0x28] LEA RSI,[0x1041e2] MOV EDX,0xa MOV ECX,0x5 MOV R8D,0x3 CALL 0x00102a30 MOV dword ptr [RBP + -0x2c],0x64 MOV RDI,qword ptr [RBP + -0x8] MOV ESI,0x320 CALL 0x00102430 MOV qword ptr [RBP + -0x38],RAX MOV dword ptr [RBP + -0x3c],0x0 LAB_001020b4: CMP dword ptr [RBP + -0x3c],0x64 JGE 0x00102140 MOV RDI,qword ptr [RBP + -0x8] MOV ESI,0x40 CALL 0x00102430 MOV qword ptr [RBP + -0x48],RAX MOV RDI,qword ptr [RBP + -0x48] MOV EDX,dword ptr [RBP + -0x3c] LEA RSI,[0x104878] MOV AL,0x0 CALL 0x001010c0 MOV RDX,qword ptr [RBP + -0x48] MOV RAX,qword ptr [RBP + -0x38] MOVSXD RCX,dword ptr [RBP + -0x3c] MOV qword ptr [RAX + RCX*0x8],RDX MOV EAX,dword ptr [RBP + -0x3c] MOV ECX,0x4 CDQ IDIV ECX MOV dword ptr [RBP + -0x4c],EDX MOV RDI,qword ptr [RBP + -0x10] MOV ESI,dword ptr [RBP + -0x4c] MOV RDX,qword ptr [RBP + -0x48] LEA RAX,[RBP + -0x28] XOR ECX,ECX MOV R8,qword ptr [RAX] MOV qword ptr [RSP],R8 MOV R8,qword ptr [RAX + 0x8] MOV qword ptr [RSP + 0x8],R8 MOV RAX,qword ptr [RAX + 0x10] MOV qword ptr [RSP + 0x10],RAX CALL 0x00102b10 MOV EAX,dword ptr [RBP + -0x3c] ADD EAX,0x1 MOV dword ptr [RBP + -0x3c],EAX JMP 0x001020b4 LAB_00102140: MOV RDI,qword ptr [RBP + -0x10] CALL 0x00102cb0 CMP RAX,0x64 JNZ 0x00102151 JMP 0x00102170 LAB_00102151: LEA RDI,[0x104886] LEA RSI,[0x104077] MOV EDX,0xd8 LEA RCX,[0x104850] CALL 0x00101070 LAB_00102170: MOV dword ptr [RBP + -0x50],0x32 MOV RDI,qword ptr [RBP + -0x10] CALL 0x00102d70 MOV qword ptr [RBP + -0x58],RAX MOV ESI,dword ptr [RBP + -0x50] MOV RDX,qword ptr [RBP + -0x58] LEA RDI,[0x1048b5] MOV AL,0x0 CALL 0x00101060 MOV RAX,qword ptr [RBP + -0x58] MOVSXD RCX,dword ptr [RBP + -0x50] CMP RAX,RCX JNZ 0x001021a8 JMP 0x001021c7 LAB_001021a8: LEA RDI,[0x1048e8] LEA RSI,[0x104077] MOV EDX,0xde LEA RCX,[0x104850] CALL 0x00101070 LAB_001021c7: LEA RDI,[0x104913] MOV AL,0x0 CALL 0x00101060 MOV dword ptr [RBP + -0x5c],0x0 LAB_001021dc: CMP dword ptr [RBP + -0x5c],0x64 JGE 0x0010223f MOV RDI,qword ptr [RBP + -0x10] MOVSXD RSI,dword ptr [RBP + -0x5c] CALL 0x00102d00 MOV qword ptr [RBP + -0x68],RAX CMP qword ptr [RBP + -0x68],0x0 JZ 0x001021fc JMP 0x0010221b LAB_001021fc: LEA RDI,[0x104233] LEA RSI,[0x104077] MOV EDX,0xe4 LEA RCX,[0x104850] CALL 0x00101070 LAB_0010221b: MOV ESI,dword ptr [RBP + -0x5c] MOV RAX,qword ptr [RBP + -0x68] MOV RDX,qword ptr [RAX + 0x20] LEA RDI,[0x104925] MOV AL,0x0 CALL 0x00101060 MOV EAX,dword ptr [RBP + -0x5c] ADD EAX,0x1 MOV dword ptr [RBP + -0x5c],EAX JMP 0x001021dc LAB_0010223f: MOV dword ptr [RBP + -0x6c],0x0 LAB_00102246: CMP dword ptr [RBP + -0x6c],0x64 JGE 0x00102309 MOV RDI,qword ptr [RBP + -0x10] MOVSXD RSI,dword ptr [RBP + -0x6c] CALL 0x00102d00 MOV qword ptr [RBP + -0x78],RAX CMP qword ptr [RBP + -0x78],0x0 JZ 0x0010226a JMP 0x00102289 LAB_0010226a: LEA RDI,[0x104233] LEA RSI,[0x104077] MOV EDX,0xeb LEA RCX,[0x104850] CALL 0x00101070 LAB_00102289: LEA RDI,[RBP + -0xc0] MOV EDX,dword ptr [RBP + -0x6c] LEA RSI,[0x104878] MOV AL,0x0 CALL 0x001010c0 MOV RAX,qword ptr [RBP + -0x78] MOV RDI,qword ptr [RAX + 0x20] LEA RSI,[RBP + -0xc0] CALL 0x00101080 CMP EAX,0x0 JZ 0x001022f9 MOV ESI,dword ptr [RBP + -0x6c] LEA RDX,[RBP + -0xc0] MOV RAX,qword ptr [RBP + -0x78] MOV RCX,qword ptr [RAX + 0x20] LEA RDI,[0x104943] MOV AL,0x0 CALL 0x00101060 LEA RDI,[0x10497a] LEA RSI,[0x104077] MOV EDX,0xf2 LEA RCX,[0x104850] CALL 0x00101070 LAB_001022f9: JMP 0x001022fb LAB_001022fb: MOV EAX,dword ptr [RBP + -0x6c] ADD EAX,0x1 MOV dword ptr [RBP + -0x6c],EAX JMP 0x00102246 LAB_00102309: MOV RDI,qword ptr [RBP + -0x8] CALL 0x00102910 LEA RDI,[0x104980] MOV AL,0x0 CALL 0x00101060 ADD RSP,0xe0 POP RBP RET
void test_diagnostic_context_many(void) { int iVar1; long lVar2; int8 in_R9; char local_c8 [72]; long local_80; uint local_74; long local_70; uint local_64; long local_60; uint local_58; int local_54; char *local_50; uint local_44; long local_40; int4 local_34; int8 local_30; int8 local_28; int8 local_20; long local_18; long local_10; printf("Testing adding many diagnostics...\n"); local_10 = arena_create(0x400); if (local_10 == 0) { /* WARNING: Subroutine does not return */ __assert_fail("arena != NULL", "/workspace/llm4binary/github2025/eshkol/tests/unit/test_diagnostics.c",0xc3, "void test_diagnostic_context_many(void)"); } local_18 = diagnostic_context_create(local_10); if (local_18 != 0) { source_location_create(&local_30,"test.esk",10,5,3); local_34 = 100; local_40 = arena_alloc(local_10,800); for (local_44 = 0; (int)local_44 < 100; local_44 = local_44 + 1) { local_50 = (char *)arena_alloc(local_10,0x40); sprintf(local_50,"Diagnostic %d",(ulong)local_44); *(char **)(local_40 + (long)(int)local_44 * 8) = local_50; local_54 = (int)local_44 % 4; diagnostic_context_add(local_18,local_54,local_50,0,local_28,in_R9,local_30,local_28,local_20) ; } lVar2 = diagnostic_context_get_count(local_18); if (lVar2 == 100) { local_58 = 0x32; local_60 = diagnostic_context_get_error_count(local_18); printf("Expected error count: %d, Actual error count: %zu\n",(ulong)local_58,local_60); if (local_60 != (int)local_58) { /* WARNING: Subroutine does not return */ __assert_fail("actual_error_count == expected_error_count", "/workspace/llm4binary/github2025/eshkol/tests/unit/test_diagnostics.c",0xde, "void test_diagnostic_context_many(void)"); } printf("All diagnostics:\n"); local_64 = 0; while( true ) { if (99 < (int)local_64) { local_74 = 0; while( true ) { if (99 < (int)local_74) { arena_destroy(local_10); printf("PASS: diagnostic_context_many\n"); return; } local_80 = diagnostic_context_get(local_18,(long)(int)local_74); if (local_80 == 0) break; sprintf(local_c8,"Diagnostic %d",(ulong)local_74); iVar1 = strcmp(*(char **)(local_80 + 0x20),local_c8); if (iVar1 != 0) { printf("Message mismatch at index %d: expected \'%s\', got \'%s\'\n",(ulong)local_74, local_c8,*(int8 *)(local_80 + 0x20)); /* WARNING: Subroutine does not return */ __assert_fail("false", "/workspace/llm4binary/github2025/eshkol/tests/unit/test_diagnostics.c", 0xf2,"void test_diagnostic_context_many(void)"); } local_74 = local_74 + 1; } /* WARNING: Subroutine does not return */ __assert_fail("diagnostic != NULL", "/workspace/llm4binary/github2025/eshkol/tests/unit/test_diagnostics.c",0xeb ,"void test_diagnostic_context_many(void)"); } local_70 = diagnostic_context_get(local_18,(long)(int)local_64); if (local_70 == 0) break; printf("Diagnostic at index %d: \'%s\'\n",(ulong)local_64,*(int8 *)(local_70 + 0x20)); local_64 = local_64 + 1; } /* WARNING: Subroutine does not return */ __assert_fail("diagnostic != NULL", "/workspace/llm4binary/github2025/eshkol/tests/unit/test_diagnostics.c",0xe4, "void test_diagnostic_context_many(void)"); } /* WARNING: Subroutine does not return */ __assert_fail("diagnostic_context_get_count(context) == count", "/workspace/llm4binary/github2025/eshkol/tests/unit/test_diagnostics.c",0xd8, "void test_diagnostic_context_many(void)"); } /* WARNING: Subroutine does not return */ __assert_fail("context != NULL", "/workspace/llm4binary/github2025/eshkol/tests/unit/test_diagnostics.c",0xc6, "void test_diagnostic_context_many(void)"); }
47,411
rak_array_inplace_concat
fabiosvm[P]rak/src/array.c
void rak_array_inplace_concat(RakArray *arr1, RakArray *arr2, RakError *err) { if (rak_array_is_empty(arr2)) return; int len1 = rak_array_len(arr1); int len2 = rak_array_len(arr2); int len = len1 + len2; rak_array_ensure_capacity(arr1, len, err); if (!rak_is_ok(err)) return; for (int i = 0; i < len2; ++i) { RakValue val = rak_array_get(arr2, i); rak_slice_set(&arr1->slice, len1 + i, val); rak_value_retain(val); } arr1->slice.len = len; }
O2
c
rak_array_inplace_concat: pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx pushq %rax movl 0xc(%rsi), %r12d testl %r12d, %r12d je 0x27e4 movq %rdx, %r15 movq %rsi, %r14 movq %rdi, %rbx movslq 0xc(%rdi), %r13 leal (%r12,%r13), %ebp movl %ebp, %esi callq 0x2474 cmpb $0x1, (%r15) jne 0x27e4 xorl %eax, %eax testl %r12d, %r12d cmovlel %eax, %r12d shlq $0x4, %r13 orq $0x8, %r13 shlq $0x4, %r12 cmpq %rax, %r12 je 0x27e1 movq 0x10(%r14), %rcx movl (%rcx,%rax), %edx movl 0x4(%rcx,%rax), %esi movq 0x8(%rcx,%rax), %rcx movq 0x10(%rbx), %rdi addq %r13, %rdi movl %edx, -0x8(%rax,%rdi) movl %esi, -0x4(%rax,%rdi) movq %rcx, (%rax,%rdi) testb $0x2, %sil je 0x27db incl (%rcx) addq $0x10, %rax jmp 0x27ab movl %ebp, 0xc(%rbx) addq $0x8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
rak_array_inplace_concat: push rbp push r15 push r14 push r13 push r12 push rbx push rax mov r12d, [rsi+0Ch] test r12d, r12d jz short loc_27E4 mov r15, rdx mov r14, rsi mov rbx, rdi movsxd r13, dword ptr [rdi+0Ch] lea ebp, [r12+r13] mov esi, ebp call rak_array_ensure_capacity cmp byte ptr [r15], 1 jnz short loc_27E4 xor eax, eax test r12d, r12d cmovle r12d, eax shl r13, 4 or r13, 8 shl r12, 4 loc_27AB: cmp r12, rax jz short loc_27E1 mov rcx, [r14+10h] mov edx, [rcx+rax] mov esi, [rcx+rax+4] mov rcx, [rcx+rax+8] mov rdi, [rbx+10h] add rdi, r13 mov [rax+rdi-8], edx mov [rax+rdi-4], esi mov [rax+rdi], rcx test sil, 2 jz short loc_27DB inc dword ptr [rcx] loc_27DB: add rax, 10h jmp short loc_27AB loc_27E1: mov [rbx+0Ch], ebp loc_27E4: add rsp, 8 pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
long long rak_array_inplace_concat(long long a1, long long a2, _BYTE *a3) { long long result; // rax long long v4; // r12 long long v8; // r13 int v9; // ebp long long v10; // r13 long long v11; // r12 long long v12; // rcx int v13; // edx int v14; // esi _DWORD *v15; // rcx long long v16; // rdi v4 = *(unsigned int *)(a2 + 12); if ( (_DWORD)v4 ) { v8 = *(int *)(a1 + 12); v9 = v4 + v8; result = rak_array_ensure_capacity(a1, (int)v4 + (int)v8, a3); if ( *a3 == 1 ) { result = 0LL; if ( (int)v4 <= 0 ) v4 = 0LL; v10 = (16 * v8) | 8; v11 = 16 * v4; while ( v11 != result ) { v12 = *(_QWORD *)(a2 + 16); v13 = *(_DWORD *)(v12 + result); v14 = *(_DWORD *)(v12 + result + 4); v15 = *(_DWORD **)(v12 + result + 8); v16 = v10 + *(_QWORD *)(a1 + 16); *(_DWORD *)(result + v16 - 8) = v13; *(_DWORD *)(result + v16 - 4) = v14; *(_QWORD *)(result + v16) = v15; if ( (v14 & 2) != 0 ) ++*v15; result += 16LL; } *(_DWORD *)(a1 + 12) = v9; } } return result; }
rak_array_inplace_concat: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX PUSH RAX MOV R12D,dword ptr [RSI + 0xc] TEST R12D,R12D JZ 0x001027e4 MOV R15,RDX MOV R14,RSI MOV RBX,RDI MOVSXD R13,dword ptr [RDI + 0xc] LEA EBP,[R12 + R13*0x1] MOV ESI,EBP CALL 0x00102474 CMP byte ptr [R15],0x1 JNZ 0x001027e4 XOR EAX,EAX TEST R12D,R12D CMOVLE R12D,EAX SHL R13,0x4 OR R13,0x8 SHL R12,0x4 LAB_001027ab: CMP R12,RAX JZ 0x001027e1 MOV RCX,qword ptr [R14 + 0x10] MOV EDX,dword ptr [RCX + RAX*0x1] MOV ESI,dword ptr [RCX + RAX*0x1 + 0x4] MOV RCX,qword ptr [RCX + RAX*0x1 + 0x8] MOV RDI,qword ptr [RBX + 0x10] ADD RDI,R13 MOV dword ptr [RAX + RDI*0x1 + -0x8],EDX MOV dword ptr [RAX + RDI*0x1 + -0x4],ESI MOV qword ptr [RAX + RDI*0x1],RCX TEST SIL,0x2 JZ 0x001027db INC dword ptr [RCX] LAB_001027db: ADD RAX,0x10 JMP 0x001027ab LAB_001027e1: MOV dword ptr [RBX + 0xc],EBP LAB_001027e4: ADD RSP,0x8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
void rak_array_inplace_concat(long param_1,long param_2,char *param_3) { uint uVar1; int iVar2; long lVar3; int *piVar4; ulong uVar5; int iVar6; long lVar7; ulong uVar8; uVar1 = *(uint *)(param_2 + 0xc); if (uVar1 != 0) { iVar2 = *(int *)(param_1 + 0xc); iVar6 = uVar1 + iVar2; rak_array_ensure_capacity(param_1,iVar6); if (*param_3 == '\x01') { uVar5 = 0; uVar8 = (ulong)uVar1; if ((int)uVar1 < 1) { uVar8 = uVar5; } for (; uVar8 * 0x10 != uVar5; uVar5 = uVar5 + 0x10) { lVar3 = *(long *)(param_2 + 0x10); uVar1 = *(uint *)(lVar3 + 4 + uVar5); piVar4 = *(int **)(lVar3 + 8 + uVar5); lVar7 = *(long *)(param_1 + 0x10) + ((long)iVar2 << 4 | 8U); *(int4 *)((uVar5 - 8) + lVar7) = *(int4 *)(lVar3 + uVar5); *(uint *)((uVar5 - 4) + lVar7) = uVar1; *(int **)(uVar5 + lVar7) = piVar4; if ((uVar1 & 2) != 0) { *piVar4 = *piVar4 + 1; } } *(int *)(param_1 + 0xc) = iVar6; } } return; }
47,412
rak_array_inplace_concat
fabiosvm[P]rak/src/array.c
void rak_array_inplace_concat(RakArray *arr1, RakArray *arr2, RakError *err) { if (rak_array_is_empty(arr2)) return; int len1 = rak_array_len(arr1); int len2 = rak_array_len(arr2); int len = len1 + len2; rak_array_ensure_capacity(arr1, len, err); if (!rak_is_ok(err)) return; for (int i = 0; i < len2; ++i) { RakValue val = rak_array_get(arr2, i); rak_slice_set(&arr1->slice, len1 + i, val); rak_value_retain(val); } arr1->slice.len = len; }
O3
c
rak_array_inplace_concat: pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx pushq %rax movl 0xc(%rsi), %r12d testq %r12, %r12 je 0x2808 movq %rdx, %r15 movq %rsi, %r14 movq %rdi, %rbx movslq 0xc(%rdi), %r13 leal (%r12,%r13), %ebp movl %ebp, %esi callq 0x249c cmpb $0x1, (%r15) jne 0x2808 testl %r12d, %r12d jle 0x2805 shlq $0x4, %r13 orq $0x8, %r13 shlq $0x4, %r12 xorl %eax, %eax movq 0x10(%r14), %rcx movl (%rcx,%rax), %edx movl 0x4(%rcx,%rax), %esi movq 0x8(%rcx,%rax), %rcx movq 0x10(%rbx), %rdi addq %r13, %rdi movl %edx, -0x8(%rax,%rdi) movl %esi, -0x4(%rax,%rdi) movq %rcx, (%rax,%rdi) testb $0x2, %sil je 0x27fc incl (%rcx) addq $0x10, %rax cmpq %rax, %r12 jne 0x27d1 movl %ebp, 0xc(%rbx) addq $0x8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
rak_array_inplace_concat: push rbp push r15 push r14 push r13 push r12 push rbx push rax mov r12d, [rsi+0Ch] test r12, r12 jz short loc_2808 mov r15, rdx mov r14, rsi mov rbx, rdi movsxd r13, dword ptr [rdi+0Ch] lea ebp, [r12+r13] mov esi, ebp call rak_array_ensure_capacity cmp byte ptr [r15], 1 jnz short loc_2808 test r12d, r12d jle short loc_2805 shl r13, 4 or r13, 8 shl r12, 4 xor eax, eax loc_27D1: mov rcx, [r14+10h] mov edx, [rcx+rax] mov esi, [rcx+rax+4] mov rcx, [rcx+rax+8] mov rdi, [rbx+10h] add rdi, r13 mov [rax+rdi-8], edx mov [rax+rdi-4], esi mov [rax+rdi], rcx test sil, 2 jz short loc_27FC inc dword ptr [rcx] loc_27FC: add rax, 10h cmp r12, rax jnz short loc_27D1 loc_2805: mov [rbx+0Ch], ebp loc_2808: add rsp, 8 pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
long long rak_array_inplace_concat(long long a1, long long a2, _BYTE *a3) { long long result; // rax long long v4; // r12 long long v8; // r13 int v9; // ebp long long v10; // r13 long long v11; // r12 long long v12; // rcx int v13; // edx int v14; // esi _DWORD *v15; // rcx long long v16; // rdi v4 = *(unsigned int *)(a2 + 12); if ( *(_DWORD *)(a2 + 12) ) { v8 = *(int *)(a1 + 12); v9 = v4 + v8; result = rak_array_ensure_capacity(a1, (int)v4 + (int)v8, a3); if ( *a3 == 1 ) { if ( (int)v4 > 0 ) { v10 = (16 * v8) | 8; v11 = 16 * v4; result = 0LL; do { v12 = *(_QWORD *)(a2 + 16); v13 = *(_DWORD *)(v12 + result); v14 = *(_DWORD *)(v12 + result + 4); v15 = *(_DWORD **)(v12 + result + 8); v16 = v10 + *(_QWORD *)(a1 + 16); *(_DWORD *)(result + v16 - 8) = v13; *(_DWORD *)(result + v16 - 4) = v14; *(_QWORD *)(result + v16) = v15; if ( (v14 & 2) != 0 ) ++*v15; result += 16LL; } while ( v11 != result ); } *(_DWORD *)(a1 + 12) = v9; } } return result; }
rak_array_inplace_concat: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX PUSH RAX MOV R12D,dword ptr [RSI + 0xc] TEST R12,R12 JZ 0x00102808 MOV R15,RDX MOV R14,RSI MOV RBX,RDI MOVSXD R13,dword ptr [RDI + 0xc] LEA EBP,[R12 + R13*0x1] MOV ESI,EBP CALL 0x0010249c CMP byte ptr [R15],0x1 JNZ 0x00102808 TEST R12D,R12D JLE 0x00102805 SHL R13,0x4 OR R13,0x8 SHL R12,0x4 XOR EAX,EAX LAB_001027d1: MOV RCX,qword ptr [R14 + 0x10] MOV EDX,dword ptr [RCX + RAX*0x1] MOV ESI,dword ptr [RCX + RAX*0x1 + 0x4] MOV RCX,qword ptr [RCX + RAX*0x1 + 0x8] MOV RDI,qword ptr [RBX + 0x10] ADD RDI,R13 MOV dword ptr [RAX + RDI*0x1 + -0x8],EDX MOV dword ptr [RAX + RDI*0x1 + -0x4],ESI MOV qword ptr [RAX + RDI*0x1],RCX TEST SIL,0x2 JZ 0x001027fc INC dword ptr [RCX] LAB_001027fc: ADD RAX,0x10 CMP R12,RAX JNZ 0x001027d1 LAB_00102805: MOV dword ptr [RBX + 0xc],EBP LAB_00102808: ADD RSP,0x8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
void rak_array_inplace_concat(long param_1,long param_2,char *param_3) { uint uVar1; int iVar2; uint uVar3; long lVar4; int *piVar5; long lVar6; int iVar7; long lVar8; uVar1 = *(uint *)(param_2 + 0xc); if ((ulong)uVar1 != 0) { iVar2 = *(int *)(param_1 + 0xc); iVar7 = uVar1 + iVar2; rak_array_ensure_capacity(param_1,iVar7); if (*param_3 == '\x01') { if (0 < (int)uVar1) { lVar6 = 0; do { lVar4 = *(long *)(param_2 + 0x10); uVar3 = *(uint *)(lVar4 + 4 + lVar6); piVar5 = *(int **)(lVar4 + 8 + lVar6); lVar8 = *(long *)(param_1 + 0x10) + ((long)iVar2 << 4 | 8U); *(int4 *)(lVar6 + -8 + lVar8) = *(int4 *)(lVar4 + lVar6); *(uint *)(lVar6 + -4 + lVar8) = uVar3; *(int **)(lVar6 + lVar8) = piVar5; if ((uVar3 & 2) != 0) { *piVar5 = *piVar5 + 1; } lVar6 = lVar6 + 0x10; } while ((ulong)uVar1 << 4 != lVar6); } *(int *)(param_1 + 0xc) = iVar7; } } return; }
47,413
ftxui::IsControl(unsigned int)
Andrewchistyakov[P]flashcards_lyc/build_O2/_deps/ftxui-src/src/ftxui/screen/string.cpp
bool IsControl(uint32_t ucs) { if (ucs == 0) { return true; } if (ucs < 32) { // NOLINT const uint32_t LINE_FEED = 10; return ucs != LINE_FEED; } if (ucs >= 0x7f && ucs < 0xa0) { // NOLINT return true; } return false; }
O2
cpp
ftxui::IsControl(unsigned int): testl %edi, %edi je 0x31204 cmpl $0x1f, %edi ja 0x31207 cmpl $0xa, %edi setne %al retq movb $0x1, %al retq addl $-0x7f, %edi cmpl $0x21, %edi setb %al retq
_ZN5ftxui9IsControlEj: test edi, edi jz short loc_31204 cmp edi, 1Fh ja short loc_31207 cmp edi, 0Ah setnz al retn loc_31204: mov al, 1 retn loc_31207: add edi, 0FFFFFF81h cmp edi, 21h ; '!' setb al retn
char ftxui::IsControl(ftxui *this) { if ( !(_DWORD)this ) return 1; if ( (unsigned int)this > 0x1F ) return (unsigned int)((_DWORD)this - 127) < 0x21; return (_DWORD)this != 10; }
IsControl: TEST EDI,EDI JZ 0x00131204 CMP EDI,0x1f JA 0x00131207 CMP EDI,0xa SETNZ AL RET LAB_00131204: MOV AL,0x1 RET LAB_00131207: ADD EDI,-0x7f CMP EDI,0x21 SETC AL RET
/* ftxui::IsControl(unsigned int) */ bool ftxui::IsControl(uint param_1) { if (param_1 == 0) { return true; } if (param_1 < 0x20) { return param_1 != 10; } return param_1 - 0x7f < 0x21; }
47,414
my_caseup_utf16
eloqsql/strings/ctype-ucs2.c
static size_t my_caseup_utf16(CHARSET_INFO *cs, const char *src, size_t srclen, char *dst, size_t dstlen) { my_wc_t wc; my_charset_conv_mb_wc mb_wc= cs->cset->mb_wc; my_charset_conv_wc_mb wc_mb= cs->cset->wc_mb; int res; const char *srcend= src + srclen; char *dstend= dst + dstlen; MY_UNICASE_INFO *uni_plane= cs->caseinfo; DBUG_ASSERT(srclen <= dstlen); while ((src < srcend) && (res= mb_wc(cs, &wc, (uchar *) src, (uchar *) srcend)) > 0) { my_toupper_utf16(uni_plane, &wc); if (res != wc_mb(cs, wc, (uchar *) dst, (uchar *) dstend)) break; src+= res; dst+= res; } return srclen; }
O3
c
my_caseup_utf16: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x38, %rsp movq %r8, -0x38(%rbp) movq %rdx, -0x30(%rbp) testq %rdx, %rdx jle 0x4f5c9 movq %rcx, %r15 movq %rsi, %r12 movq %rdi, %r13 movq 0x78(%rdi), %rax movq %rax, -0x50(%rbp) movq 0xb8(%rdi), %rax movq 0x28(%rax), %rcx movq %rcx, -0x58(%rbp) movq 0x30(%rax), %rax movq %rax, -0x48(%rbp) movq -0x30(%rbp), %rax leaq (%rsi,%rax), %r14 addq %r15, -0x38(%rbp) movq %r13, %rdi leaq -0x40(%rbp), %rsi movq %r12, %rdx movq %r14, %rcx callq *-0x58(%rbp) testl %eax, %eax jle 0x4f5c9 movl %eax, %ebx movq -0x40(%rbp), %rsi movq -0x50(%rbp), %rax cmpq (%rax), %rsi ja 0x4f5ab movq 0x8(%rax), %rax movq %rsi, %rcx shrq $0x8, %rcx movq (%rax,%rcx,8), %rax testq %rax, %rax je 0x4f5ab movzbl %sil, %ecx leaq (%rcx,%rcx,2), %rcx movl (%rax,%rcx,4), %esi movq %rsi, -0x40(%rbp) movq %r13, %rdi movq %r15, %rdx movq -0x38(%rbp), %rcx callq *-0x48(%rbp) cmpl %eax, %ebx jne 0x4f5c9 movl %ebx, %eax addq %rax, %r12 addq %rax, %r15 cmpq %r14, %r12 jb 0x4f565 movq -0x30(%rbp), %rax addq $0x38, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
my_caseup_utf16: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx sub rsp, 38h mov [rbp+var_38], r8 mov [rbp+var_30], rdx test rdx, rdx jle loc_4F5C9 mov r15, rcx mov r12, rsi mov r13, rdi mov rax, [rdi+78h] mov [rbp+var_50], rax mov rax, [rdi+0B8h] mov rcx, [rax+28h] mov [rbp+var_58], rcx mov rax, [rax+30h] mov [rbp+var_48], rax mov rax, [rbp+var_30] lea r14, [rsi+rax] add [rbp+var_38], r15 loc_4F565: mov rdi, r13 lea rsi, [rbp+var_40] mov rdx, r12 mov rcx, r14 call [rbp+var_58] test eax, eax jle short loc_4F5C9 mov ebx, eax mov rsi, [rbp+var_40] mov rax, [rbp+var_50] cmp rsi, [rax] ja short loc_4F5AB mov rax, [rax+8] mov rcx, rsi shr rcx, 8 mov rax, [rax+rcx*8] test rax, rax jz short loc_4F5AB movzx ecx, sil lea rcx, [rcx+rcx*2] mov esi, [rax+rcx*4] mov [rbp+var_40], rsi loc_4F5AB: mov rdi, r13 mov rdx, r15 mov rcx, [rbp+var_38] call [rbp+var_48] cmp ebx, eax jnz short loc_4F5C9 mov eax, ebx add r12, rax add r15, rax cmp r12, r14 jb short loc_4F565 loc_4F5C9: mov rax, [rbp+var_30] add rsp, 38h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
long long my_caseup_utf16(long long a1, unsigned long long a2, long long a3, long long a4, long long a5) { long long v5; // r15 unsigned long long v6; // r12 long long v7; // rax unsigned long long v8; // r14 int v9; // eax unsigned int v10; // ebx unsigned long long v11; // rsi long long v12; // rax long long ( *v14)(long long, unsigned long long *, unsigned long long, unsigned long long); // [rsp+8h] [rbp-58h] unsigned long long *v15; // [rsp+10h] [rbp-50h] unsigned int ( *v16)(long long, unsigned long long, long long, long long); // [rsp+18h] [rbp-48h] unsigned long long v17; // [rsp+20h] [rbp-40h] BYREF long long v18; // [rsp+28h] [rbp-38h] long long v19; // [rsp+30h] [rbp-30h] v18 = a5; v19 = a3; if ( a3 > 0 ) { v5 = a4; v6 = a2; v15 = *(unsigned long long **)(a1 + 120); v7 = *(_QWORD *)(a1 + 184); v14 = *(long long ( **)(long long, unsigned long long *, unsigned long long, unsigned long long))(v7 + 40); v16 = *(unsigned int ( **)(long long, unsigned long long, long long, long long))(v7 + 48); v8 = a2 + v19; v18 += a4; do { v9 = v14(a1, &v17, v6, v8); if ( v9 <= 0 ) break; v10 = v9; v11 = v17; if ( v17 <= *v15 ) { v12 = *(_QWORD *)(v15[1] + 8 * (v17 >> 8)); if ( v12 ) { v11 = *(unsigned int *)(v12 + 12LL * (unsigned __int8)v17); v17 = v11; } } if ( v10 != v16(a1, v11, v5, v18) ) break; v6 += v10; v5 += v10; } while ( v6 < v8 ); } return v19; }
my_caseup_utf16: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x38 MOV qword ptr [RBP + -0x38],R8 MOV qword ptr [RBP + -0x30],RDX TEST RDX,RDX JLE 0x0014f5c9 MOV R15,RCX MOV R12,RSI MOV R13,RDI MOV RAX,qword ptr [RDI + 0x78] MOV qword ptr [RBP + -0x50],RAX MOV RAX,qword ptr [RDI + 0xb8] MOV RCX,qword ptr [RAX + 0x28] MOV qword ptr [RBP + -0x58],RCX MOV RAX,qword ptr [RAX + 0x30] MOV qword ptr [RBP + -0x48],RAX MOV RAX,qword ptr [RBP + -0x30] LEA R14,[RSI + RAX*0x1] ADD qword ptr [RBP + -0x38],R15 LAB_0014f565: MOV RDI,R13 LEA RSI,[RBP + -0x40] MOV RDX,R12 MOV RCX,R14 CALL qword ptr [RBP + -0x58] TEST EAX,EAX JLE 0x0014f5c9 MOV EBX,EAX MOV RSI,qword ptr [RBP + -0x40] MOV RAX,qword ptr [RBP + -0x50] CMP RSI,qword ptr [RAX] JA 0x0014f5ab MOV RAX,qword ptr [RAX + 0x8] MOV RCX,RSI SHR RCX,0x8 MOV RAX,qword ptr [RAX + RCX*0x8] TEST RAX,RAX JZ 0x0014f5ab MOVZX ECX,SIL LEA RCX,[RCX + RCX*0x2] MOV ESI,dword ptr [RAX + RCX*0x4] MOV qword ptr [RBP + -0x40],RSI LAB_0014f5ab: MOV RDI,R13 MOV RDX,R15 MOV RCX,qword ptr [RBP + -0x38] CALL qword ptr [RBP + -0x48] CMP EBX,EAX JNZ 0x0014f5c9 MOV EAX,EBX ADD R12,RAX ADD R15,RAX CMP R12,R14 JC 0x0014f565 LAB_0014f5c9: MOV RAX,qword ptr [RBP + -0x30] ADD RSP,0x38 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
long my_caseup_utf16(long param_1,ulong param_2,long param_3,long param_4,long param_5) { ulong uVar1; ulong *puVar2; code *pcVar3; code *pcVar4; long lVar5; uint uVar6; uint uVar7; ulong local_48; long local_40; long local_38; local_38 = param_3; if (0 < param_3) { puVar2 = *(ulong **)(param_1 + 0x78); pcVar3 = *(code **)(*(long *)(param_1 + 0xb8) + 0x28); pcVar4 = *(code **)(*(long *)(param_1 + 0xb8) + 0x30); uVar1 = param_2 + param_3; local_40 = param_5 + param_4; do { uVar6 = (*pcVar3)(param_1,&local_48,param_2,uVar1); if ((int)uVar6 < 1) { return local_38; } if ((local_48 <= *puVar2) && (lVar5 = *(long *)(puVar2[1] + (local_48 >> 8) * 8), lVar5 != 0)) { local_48 = (ulong)*(uint *)(lVar5 + (local_48 & 0xff) * 0xc); } uVar7 = (*pcVar4)(param_1,local_48,param_4,local_40); if (uVar6 != uVar7) { return local_38; } param_2 = param_2 + uVar6; param_4 = param_4 + (ulong)uVar6; } while (param_2 < uVar1); } return local_38; }
47,415
minja::Context::Context(minja::Value&&, std::shared_ptr<minja::Context> const&)
monkey531[P]llama/common/minja.hpp
Context(Value && values, const std::shared_ptr<Context> & parent = nullptr) : values_(std::move(values)), parent_(parent) { if (!values_.is_object()) throw std::runtime_error("Context values must be an object: " + values_.dump()); }
O2
cpp
minja::Context::Context(minja::Value&&, std::shared_ptr<minja::Context> const&): pushq %rbp pushq %r15 pushq %r14 pushq %r12 pushq %rbx subq $0x40, %rsp movq %rdx, %r15 movq %rdi, %rbx xorps %xmm0, %xmm0 movups %xmm0, 0x8(%rdi) leaq 0x7af18(%rip), %rax # 0xe2150 addq $0x10, %rax movq %rax, (%rdi) leaq 0x18(%rdi), %r14 movq %r14, %rdi callq 0x4d89e leaq 0x68(%rbx), %rdi movq %r15, %rsi callq 0x674fc cmpq $0x0, 0x38(%rbx) je 0x6726b addq $0x40, %rsp popq %rbx popq %r12 popq %r14 popq %r15 popq %rbp retq pushq $0x10 popq %rdi callq 0x223e0 movq %rax, %r15 movq %rsp, %rdi pushq $-0x1 popq %rdx movq %r14, %rsi xorl %ecx, %ecx callq 0x4dcc6 leaq 0x38c59(%rip), %rsi # 0x9fee6 leaq 0x20(%rsp), %rdi movq %rsp, %rdx callq 0x3a58f movb $0x1, %bpl leaq 0x20(%rsp), %rsi movq %r15, %rdi callq 0x22c80 xorl %ebp, %ebp movq 0x7bd3d(%rip), %rsi # 0xe2ff0 movq 0x7bcae(%rip), %rdx # 0xe2f68 movq %r15, %rdi callq 0x22d40 movq %rax, %r12 leaq 0x20(%rsp), %rdi callq 0x22f98 jmp 0x672d7 movq %rax, %r12 movb $0x1, %bpl movq %rsp, %rdi callq 0x22f98 testb %bpl, %bpl jne 0x672e9 jmp 0x672f1 movq %rax, %r12 movq %r15, %rdi callq 0x225c0 leaq 0x70(%rbx), %rdi callq 0x3542e movq %r14, %rdi callq 0x4da04 addq $0x10, %rbx movq %rbx, %rdi callq 0x4f5a4 movq %r12, %rdi callq 0x22da0
_ZN5minja7ContextC2EONS_5ValueERKSt10shared_ptrIS0_E: push rbp push r15 push r14 push r12 push rbx sub rsp, 40h mov r15, rdx mov rbx, rdi xorps xmm0, xmm0 movups xmmword ptr [rdi+8], xmm0 lea rax, _ZTVN5minja7ContextE; `vtable for'minja::Context add rax, 10h mov [rdi], rax lea r14, [rdi+18h] mov rdi, r14 call _ZN5minja5ValueC2EOS0_; minja::Value::Value(minja::Value&&) lea rdi, [rbx+68h] mov rsi, r15 call _ZNSt12__shared_ptrIN5minja7ContextELN9__gnu_cxx12_Lock_policyE2EEC2ERKS4_; std::__shared_ptr<minja::Context,(__gnu_cxx::_Lock_policy)2>::__shared_ptr(std::__shared_ptr<minja::Context,(__gnu_cxx::_Lock_policy)2> const&) cmp qword ptr [rbx+38h], 0 jz short loc_6726B add rsp, 40h pop rbx pop r12 pop r14 pop r15 pop rbp retn loc_6726B: push 10h pop rdi; thrown_size call ___cxa_allocate_exception mov r15, rax mov rdi, rsp push 0FFFFFFFFFFFFFFFFh pop rdx mov rsi, r14 xor ecx, ecx call _ZNK5minja5Value4dumpB5cxx11Eib; minja::Value::dump(int,bool) lea rsi, aContextValuesM; "Context values must be an object: " lea rdi, [rsp+68h+var_48] 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+68h+var_48] mov rdi, r15 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, r15; void * call ___cxa_throw mov r12, rax lea rdi, [rsp+68h+var_48]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() jmp short loc_672D7 mov r12, rax mov bpl, 1 loc_672D7: mov rdi, rsp; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() test bpl, bpl jnz short loc_672E9 jmp short loc_672F1 mov r12, rax loc_672E9: mov rdi, r15; void * call ___cxa_free_exception loc_672F1: lea rdi, [rbx+70h] call _ZNSt14__shared_countILN9__gnu_cxx12_Lock_policyE2EED2Ev; std::__shared_count<(__gnu_cxx::_Lock_policy)2>::~__shared_count() mov rdi, r14; this call _ZN5minja5ValueD2Ev; minja::Value::~Value() add rbx, 10h mov rdi, rbx call _ZNSt12__weak_countILN9__gnu_cxx12_Lock_policyE2EED2Ev; std::__weak_count<(__gnu_cxx::_Lock_policy)2>::~__weak_count() mov rdi, r12 call __Unwind_Resume
long long minja::Context::Context(long long a1, long long a2, long long a3) { long long result; // rax void *exception; // r15 _BYTE v6[32]; // [rsp+0h] [rbp-68h] BYREF _BYTE v7[72]; // [rsp+20h] [rbp-48h] BYREF *(_OWORD *)(a1 + 8) = 0LL; *(_QWORD *)a1 = &`vtable for'minja::Context + 2; minja::Value::Value(a1 + 24, a2); result = std::__shared_ptr<minja::Context,(__gnu_cxx::_Lock_policy)2>::__shared_ptr(a1 + 104, a3); if ( !*(_QWORD *)(a1 + 56) ) { exception = __cxa_allocate_exception(0x10uLL); minja::Value::dump[abi:cxx11]((long long)v6, a1 + 24, 0xFFFFFFFF, 0); std::operator+<char>((long long)v7, (long long)"Context values must be an object: ", (long long)v6); std::runtime_error::runtime_error(exception, v7); __cxa_throw( exception, (struct type_info *)&`typeinfo for'std::runtime_error, (void (*)(void *))&std::runtime_error::~runtime_error); } return result; }
Context: PUSH RBP PUSH R15 PUSH R14 PUSH R12 PUSH RBX SUB RSP,0x40 MOV R15,RDX MOV RBX,RDI XORPS XMM0,XMM0 MOVUPS xmmword ptr [RDI + 0x8],XMM0 LEA RAX,[0x1e2150] ADD RAX,0x10 MOV qword ptr [RDI],RAX LEA R14,[RDI + 0x18] MOV RDI,R14 CALL 0x0014d89e LEA RDI,[RBX + 0x68] MOV RSI,R15 CALL 0x001674fc CMP qword ptr [RBX + 0x38],0x0 JZ 0x0016726b ADD RSP,0x40 POP RBX POP R12 POP R14 POP R15 POP RBP RET LAB_0016726b: PUSH 0x10 POP RDI CALL 0x001223e0 MOV R15,RAX LAB_00167276: MOV RDI,RSP PUSH -0x1 POP RDX MOV RSI,R14 XOR ECX,ECX CALL 0x0014dcc6 LAB_00167286: LEA RSI,[0x19fee6] LEA RDI,[RSP + 0x20] MOV RDX,RSP CALL 0x0013a58f MOV BPL,0x1 LAB_0016729d: LEA RSI,[RSP + 0x20] MOV RDI,R15 CALL 0x00122c80 XOR EBP,EBP MOV RSI,qword ptr [0x001e2ff0] MOV RDX,qword ptr [0x001e2f68] MOV RDI,R15 CALL 0x00122d40
/* minja::Context::Context(minja::Value&&, std::shared_ptr<minja::Context> const&) */ void __thiscall minja::Context::Context(Context *this,Value *param_1,shared_ptr *param_2) { runtime_error *this_00; int1 auStack_68 [32]; string local_48 [32]; *(int8 *)(this + 8) = 0; *(int8 *)(this + 0x10) = 0; *(int ***)this = &PTR__Context_001e2160; Value::Value((Value *)(this + 0x18),param_1); std::__shared_ptr<minja::Context,(__gnu_cxx::_Lock_policy)2>::__shared_ptr ((__shared_ptr<minja::Context,(__gnu_cxx::_Lock_policy)2> *)(this + 0x68), (__shared_ptr *)param_2); if (*(long *)(this + 0x38) != 0) { return; } this_00 = (runtime_error *)__cxa_allocate_exception(0x10); /* try { // try from 00167276 to 00167285 has its CatchHandler @ 001672e6 */ Value::dump_abi_cxx11_((int)auStack_68,SUB81((Value *)(this + 0x18),0)); /* try { // try from 00167286 to 00167299 has its CatchHandler @ 001672d1 */ std::operator+((char *)local_48,(string *)"Context values must be an object: "); /* try { // try from 0016729d to 001672c1 has its CatchHandler @ 001672c2 */ std::runtime_error::runtime_error(this_00,local_48); /* WARNING: Subroutine does not return */ __cxa_throw(this_00,PTR_typeinfo_001e2ff0,PTR__runtime_error_001e2f68); }
47,416
std::pair<bool, 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::json_sax_dom_callback_parser<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>>::handle_value<bool&>(bool&, bool)
monkey531[P]llama/common/json.hpp
std::pair<bool, BasicJsonType*> handle_value(Value&& v, const bool skip_callback = false) { JSON_ASSERT(!keep_stack.empty()); // do not handle this value if we know it would be added to a discarded // container if (!keep_stack.back()) { return {false, nullptr}; } // create value auto value = BasicJsonType(std::forward<Value>(v)); // check callback const bool keep = skip_callback || callback(static_cast<int>(ref_stack.size()), parse_event_t::value, value); // do not handle this value if we just learnt it shall be discarded if (!keep) { return {false, nullptr}; } if (ref_stack.empty()) { root = std::move(value); return {true, & root}; } // skip this value if we already decided to skip the parent // (https://github.com/nlohmann/json/issues/971#issuecomment-413678360) if (!ref_stack.back()) { return {false, nullptr}; } // we now only expect arrays and objects JSON_ASSERT(ref_stack.back()->is_array() || ref_stack.back()->is_object()); // array if (ref_stack.back()->is_array()) { ref_stack.back()->m_data.m_value.array->emplace_back(std::move(value)); return {true, & (ref_stack.back()->m_data.m_value.array->back())}; } // object JSON_ASSERT(ref_stack.back()->is_object()); // check if we should store an element for the current key JSON_ASSERT(!key_keep_stack.empty()); const bool store_element = key_keep_stack.back(); key_keep_stack.pop_back(); if (!store_element) { return {false, nullptr}; } JSON_ASSERT(object_element); *object_element = std::move(value); return {true, object_element}; }
O0
cpp
std::pair<bool, 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::json_sax_dom_callback_parser<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>>::handle_value<bool&>(bool&, bool): subq $0x148, %rsp # imm = 0x148 movb %dl, %al movq %rdi, 0x130(%rsp) movq %rsi, 0x128(%rsp) andb $0x1, %al movb %al, 0x127(%rsp) movq 0x130(%rsp), %rdi movq %rdi, 0x40(%rsp) addq $0x20, %rdi callq 0xae730 testb $0x1, %al jne 0xba0de jmp 0xba0ff leaq 0x15528f(%rip), %rdi # 0x20f374 movl $0x1c28, %esi # imm = 0x1C28 leaq 0x14f059(%rip), %rdx # 0x20914a leaq 0x1561fc(%rip), %rcx # 0x2102f4 movb $0x0, %al callq 0x5aed0 movq 0x40(%rsp), %rdi addq $0x20, %rdi callq 0xae7b0 movq %rax, 0x110(%rsp) movq %rdx, 0x118(%rsp) leaq 0x110(%rsp), %rdi callq 0xac7a0 xorb $-0x1, %al testb $0x1, %al jne 0xba132 jmp 0xba168 movb $0x0, 0x10f(%rsp) movq $0x0, 0x100(%rsp) leaq 0x138(%rsp), %rdi leaq 0x10f(%rsp), %rsi leaq 0x100(%rsp), %rdx callq 0xaf2c0 jmp 0xba5d1 movq 0x128(%rsp), %rsi leaq 0xf0(%rsp), %rdi callq 0xba600 movb $0x1, %al testb $0x1, 0x127(%rsp) movb %al, 0x3f(%rsp) jne 0xba1d0 movq 0x40(%rsp), %rdi movq %rdi, %rax subq $-0x80, %rax movq %rax, 0x30(%rsp) addq $0x8, %rdi callq 0xae8b0 movq 0x30(%rsp), %rdi movl %eax, %esi movl $0x5, %edx leaq 0xf0(%rsp), %rcx callq 0xae850 movb %al, 0x3e(%rsp) jmp 0xba1c6 movb 0x3e(%rsp), %al movb %al, 0x3f(%rsp) jmp 0xba1d0 movb 0x3f(%rsp), %al andb $0x1, %al movb %al, 0xef(%rsp) testb $0x1, 0xef(%rsp) jne 0xba250 movb $0x0, 0xdb(%rsp) movq $0x0, 0xd0(%rsp) leaq 0x138(%rsp), %rdi leaq 0xdb(%rsp), %rsi leaq 0xd0(%rsp), %rdx callq 0xaf2c0 jmp 0xba21a movl $0x1, 0xcc(%rsp) jmp 0xba5c4 movq %rax, %rcx movl %edx, %eax movq %rcx, 0xe0(%rsp) movl %eax, 0xdc(%rsp) leaq 0xf0(%rsp), %rdi callq 0xa00f0 jmp 0xba5e8 movq 0x40(%rsp), %rdi addq $0x8, %rdi callq 0xaf2f0 testb $0x1, %al jne 0xba264 jmp 0xba2e1 leaq 0xb8(%rsp), %rdi movq %rdi, 0x28(%rsp) leaq 0xf0(%rsp), %rsi callq 0xaf340 movq 0x28(%rsp), %rsi movq 0x40(%rsp), %rax movq (%rax), %rdi callq 0xa92d0 movq 0x28(%rsp), %rdi callq 0xa00f0 movq 0x40(%rsp), %rax movb $0x1, 0xb7(%rsp) movq (%rax), %rax movq %rax, 0xa8(%rsp) leaq 0x138(%rsp), %rdi leaq 0xb7(%rsp), %rsi leaq 0xa8(%rsp), %rdx callq 0xaf3c0 jmp 0xba2d1 movl $0x1, 0xcc(%rsp) jmp 0xba5c4 movq 0x40(%rsp), %rdi addq $0x8, %rdi callq 0xaeea0 cmpq $0x0, (%rax) jne 0xba338 movb $0x0, 0xa7(%rsp) movq $0x0, 0x98(%rsp) leaq 0x138(%rsp), %rdi leaq 0xa7(%rsp), %rsi leaq 0x98(%rsp), %rdx callq 0xaf2c0 jmp 0xba328 movl $0x1, 0xcc(%rsp) jmp 0xba5c4 movq 0x40(%rsp), %rdi addq $0x8, %rdi callq 0xaeea0 movq (%rax), %rdi callq 0xaf3f0 testb $0x1, %al jne 0xba38f movq 0x40(%rsp), %rdi addq $0x8, %rdi callq 0xaeea0 movq (%rax), %rdi callq 0xaf410 testb $0x1, %al jne 0xba38f leaq 0x155001(%rip), %rdi # 0x20f374 leaq 0x14edd0(%rip), %rdx # 0x20914a leaq 0x155f87(%rip), %rcx # 0x210308 xorl %eax, %eax movl $0x1c4b, %esi # imm = 0x1C4B callq 0x5aed0 jmp 0xba38f movq 0x40(%rsp), %rdi addq $0x8, %rdi callq 0xaeea0 movq (%rax), %rdi callq 0xaf3f0 testb $0x1, %al jne 0xba3ab jmp 0xba428 movq 0x40(%rsp), %rdi addq $0x8, %rdi callq 0xaeea0 movq (%rax), %rax movq 0x8(%rax), %rdi leaq 0xf0(%rsp), %rsi callq 0xaf430 jmp 0xba3cf movq 0x40(%rsp), %rdi movb $0x1, 0x97(%rsp) addq $0x8, %rdi callq 0xaeea0 movq (%rax), %rax movq 0x8(%rax), %rdi callq 0xaf4b0 movq %rax, 0x88(%rsp) leaq 0x138(%rsp), %rdi leaq 0x97(%rsp), %rsi leaq 0x88(%rsp), %rdx callq 0xaf3c0 jmp 0xba418 movl $0x1, 0xcc(%rsp) jmp 0xba5c4 movq 0x40(%rsp), %rdi addq $0x8, %rdi callq 0xaeea0 movq (%rax), %rdi callq 0xaf410 testb $0x1, %al jne 0xba465 leaq 0x154f2b(%rip), %rdi # 0x20f374 leaq 0x14ecfa(%rip), %rdx # 0x20914a leaq 0x155ed1(%rip), %rcx # 0x210328 xorl %eax, %eax movl $0x1c55, %esi # imm = 0x1C55 callq 0x5aed0 jmp 0xba465 movq 0x40(%rsp), %rdi addq $0x48, %rdi callq 0xae730 testb $0x1, %al jne 0xba479 jmp 0xba49c leaq 0x154ef4(%rip), %rdi # 0x20f374 leaq 0x14ecc3(%rip), %rdx # 0x20914a leaq 0x155eb8(%rip), %rcx # 0x210346 xorl %eax, %eax movl $0x1c57, %esi # imm = 0x1C57 callq 0x5aed0 jmp 0xba49c movq 0x40(%rsp), %rdi addq $0x48, %rdi callq 0xae7b0 movq %rdx, 0x18(%rsp) movq %rax, 0x20(%rsp) jmp 0xba4b6 movq 0x18(%rsp), %rax movq 0x20(%rsp), %rcx movq %rcx, 0x70(%rsp) movq %rax, 0x78(%rsp) leaq 0x70(%rsp), %rdi callq 0xac7a0 movq 0x40(%rsp), %rdi movb %al, 0x87(%rsp) addq $0x48, %rdi callq 0xae830 jmp 0xba4eb testb $0x1, 0x87(%rsp) jne 0xba52c movb $0x0, 0x6f(%rsp) movq $0x0, 0x60(%rsp) leaq 0x138(%rsp), %rdi leaq 0x6f(%rsp), %rsi leaq 0x60(%rsp), %rdx callq 0xaf2c0 jmp 0xba51c movl $0x1, 0xcc(%rsp) jmp 0xba5c4 movq 0x40(%rsp), %rax cmpq $0x0, 0x70(%rax) jne 0xba55b leaq 0x154e35(%rip), %rdi # 0x20f374 leaq 0x14ec04(%rip), %rdx # 0x20914a leaq 0x155e11(%rip), %rcx # 0x21035e xorl %eax, %eax movl $0x1c60, %esi # imm = 0x1C60 callq 0x5aed0 jmp 0xba55b leaq 0x50(%rsp), %rdi movq %rdi, 0x8(%rsp) leaq 0xf0(%rsp), %rsi callq 0xaf340 movq 0x40(%rsp), %rax movq 0x8(%rsp), %rsi movq %rax, %rcx addq $0x70, %rcx movq %rcx, 0x10(%rsp) movq 0x70(%rax), %rdi callq 0xa92d0 movq 0x8(%rsp), %rdi callq 0xa00f0 movq 0x10(%rsp), %rdx movb $0x1, 0x4f(%rsp) leaq 0x138(%rsp), %rdi leaq 0x4f(%rsp), %rsi callq 0xaf4f0 jmp 0xba5b9 movl $0x1, 0xcc(%rsp) leaq 0xf0(%rsp), %rdi callq 0xa00f0 movb 0x138(%rsp), %al movq 0x140(%rsp), %rdx addq $0x148, %rsp # imm = 0x148 retq movq 0xe0(%rsp), %rdi callq 0x5aba0 nopw %cs:(%rax,%rax) nop
_ZN8nlohmann16json_abi_v3_11_36detail28json_sax_dom_callback_parserINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12handle_valueIRmEESt4pairIbPSF_EOT_b: sub rsp, 148h mov al, dl mov [rsp+148h+var_18], rdi mov [rsp+148h+var_20], rsi and al, 1 mov [rsp+148h+var_21], al mov rdi, [rsp+148h+var_18] mov [rsp+148h+var_108], rdi add rdi, 20h ; ' ' call _ZNKSt6vectorIbSaIbEE5emptyEv; std::vector<bool>::empty(void) test al, 1 jnz short loc_BA0DE jmp short loc_BA0FF loc_BA0DE: lea rdi, aWorkspaceLlm4b_1; "/workspace/llm4binary/github/2025_star3"... mov esi, 1C28h lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aKeepStackEmpty; "!keep_stack.empty()" mov al, 0 call _ggml_abort loc_BA0FF: mov rdi, [rsp+148h+var_108] add rdi, 20h ; ' ' call _ZNSt6vectorIbSaIbEE4backEv; std::vector<bool>::back(void) mov [rsp+148h+var_38], rax mov [rsp+148h+var_30], rdx lea rdi, [rsp+148h+var_38] call _ZNKSt14_Bit_referencecvbEv; std::_Bit_reference::operator bool(void) xor al, 0FFh test al, 1 jnz short loc_BA132 jmp short loc_BA168 loc_BA132: mov [rsp+148h+var_39], 0 mov [rsp+148h+var_48], 0 lea rdi, [rsp+148h+var_10] lea rsi, [rsp+148h+var_39] lea rdx, [rsp+148h+var_48] call _ZNSt4pairIbPN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES4_IhSaIhEEvEEEC2IbDnTnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairISJ_SK_EEEbE4typeELb1EEEOSJ_OSK_ jmp loc_BA5D1 loc_BA168: mov rsi, [rsp+148h+var_20] lea rdi, [rsp+148h+var_58] call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEC2IRmmTnNSt9enable_ifIXaantsr6detail13is_basic_jsonIT0_EE5valuesr6detail18is_compatible_typeISD_SH_EE5valueEiE4typeELi0EEEOT_ mov al, 1 test [rsp+148h+var_21], 1 mov [rsp+148h+var_109], al jnz short loc_BA1D0 mov rdi, [rsp+148h+var_108] mov rax, rdi sub rax, 0FFFFFFFFFFFFFF80h mov [rsp+148h+var_118], rax add rdi, 8 call _ZNKSt6vectorIPN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapES_NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES_IhSaIhEEvEESaISE_EE4sizeEv; std::vector<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::allocator<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> *>>::size(void) mov rdi, [rsp+148h+var_118] mov esi, eax mov edx, 5 lea rcx, [rsp+148h+var_58] call _ZNKSt8functionIFbiN8nlohmann16json_abi_v3_11_36detail13parse_event_tERNS1_10basic_jsonINS1_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES6_IhSaIhEEvEEEEclEiS3_SH_; std::function<bool ()(int,nlohmann::json_abi_v3_11_3::detail::parse_event_t,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()(int,nlohmann::json_abi_v3_11_3::detail::parse_event_t,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 [rsp+148h+var_10A], al jmp short $+2 loc_BA1C6: mov al, [rsp+148h+var_10A] mov [rsp+148h+var_109], al jmp short $+2 loc_BA1D0: mov al, [rsp+148h+var_109] and al, 1 mov [rsp+148h+var_59], al test [rsp+148h+var_59], 1 jnz short loc_BA250 mov [rsp+148h+var_6D], 0 mov [rsp+148h+var_78], 0 lea rdi, [rsp+148h+var_10] lea rsi, [rsp+148h+var_6D] lea rdx, [rsp+148h+var_78] call _ZNSt4pairIbPN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES4_IhSaIhEEvEEEC2IbDnTnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairISJ_SK_EEEbE4typeELb1EEEOSJ_OSK_ jmp short $+2 loc_BA21A: mov [rsp+148h+var_7C], 1 jmp loc_BA5C4 mov rcx, rax mov eax, edx mov [rsp+arg_D8], rcx mov [rsp+arg_D4], eax lea rdi, [rsp+arg_E8] call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvED2Ev; 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>::~basic_json() jmp loc_BA5E8 loc_BA250: mov rdi, [rsp+148h+var_108] add rdi, 8 call _ZNKSt6vectorIPN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapES_NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES_IhSaIhEEvEESaISE_EE5emptyEv; std::vector<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::allocator<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> *>>::empty(void) test al, 1 jnz short loc_BA264 jmp short loc_BA2E1 loc_BA264: lea rdi, [rsp+148h+var_90] mov [rsp+148h+var_120], rdi lea rsi, [rsp+148h+var_58] call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEC2EOSD_; 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>::basic_json(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 rsi, [rsp+148h+var_120] mov rax, [rsp+148h+var_108] mov rdi, [rax] call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEaSESD_; 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=(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+148h+var_120] call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvED2Ev; 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>::~basic_json() mov rax, [rsp+148h+var_108] mov [rsp+148h+var_91], 1 mov rax, [rax] mov [rsp+148h+var_A0], rax lea rdi, [rsp+148h+var_10] lea rsi, [rsp+148h+var_91] lea rdx, [rsp+148h+var_A0] call _ZNSt4pairIbPN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES4_IhSaIhEEvEEEC2IbSF_TnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairISJ_SK_EEEbE4typeELb1EEEOSJ_OSK_ jmp short $+2 loc_BA2D1: mov [rsp+148h+var_7C], 1 jmp loc_BA5C4 loc_BA2E1: mov rdi, [rsp+148h+var_108] add rdi, 8 call _ZNSt6vectorIPN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapES_NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES_IhSaIhEEvEESaISE_EE4backEv; std::vector<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::allocator<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> *>>::back(void) cmp qword ptr [rax], 0 jnz short loc_BA338 mov [rsp+148h+var_A1], 0 mov [rsp+148h+var_B0], 0 lea rdi, [rsp+148h+var_10] lea rsi, [rsp+148h+var_A1] lea rdx, [rsp+148h+var_B0] call _ZNSt4pairIbPN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES4_IhSaIhEEvEEEC2IbDnTnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairISJ_SK_EEEbE4typeELb1EEEOSJ_OSK_ jmp short $+2 loc_BA328: mov [rsp+148h+var_7C], 1 jmp loc_BA5C4 loc_BA338: mov rdi, [rsp+148h+var_108] add rdi, 8 call _ZNSt6vectorIPN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapES_NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES_IhSaIhEEvEESaISE_EE4backEv; std::vector<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::allocator<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> *>>::back(void) mov rdi, [rax] call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE8is_arrayEv; 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>::is_array(void) test al, 1 jnz short loc_BA38F mov rdi, [rsp+148h+var_108] add rdi, 8 call _ZNSt6vectorIPN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapES_NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES_IhSaIhEEvEESaISE_EE4backEv; std::vector<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::allocator<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> *>>::back(void) mov rdi, [rax] call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE9is_objectEv; 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>::is_object(void) test al, 1 jnz short loc_BA38F lea rdi, aWorkspaceLlm4b_1; "/workspace/llm4binary/github/2025_star3"... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aRefStackBackIs; "ref_stack.back()->is_array() || ref_sta"... xor eax, eax mov esi, 1C4Bh call _ggml_abort jmp short $+2 loc_BA38F: mov rdi, [rsp+148h+var_108] add rdi, 8 call _ZNSt6vectorIPN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapES_NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES_IhSaIhEEvEESaISE_EE4backEv; std::vector<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::allocator<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> *>>::back(void) mov rdi, [rax] call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE8is_arrayEv; 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>::is_array(void) test al, 1 jnz short loc_BA3AB jmp short loc_BA428 loc_BA3AB: mov rdi, [rsp+148h+var_108] add rdi, 8 call _ZNSt6vectorIPN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapES_NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES_IhSaIhEEvEESaISE_EE4backEv; std::vector<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::allocator<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> *>>::back(void) mov rax, [rax] mov rdi, [rax+8] lea rsi, [rsp+148h+var_58] call _ZNSt6vectorIN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapES_NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES_IhSaIhEEvEESaISD_EE12emplace_backIJSD_EEERSD_DpOT_; std::vector<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<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>>(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> &&) jmp short $+2 loc_BA3CF: mov rdi, [rsp+148h+var_108] mov [rsp+148h+var_B1], 1 add rdi, 8 call _ZNSt6vectorIPN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapES_NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES_IhSaIhEEvEESaISE_EE4backEv; std::vector<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::allocator<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> *>>::back(void) mov rax, [rax] mov rdi, [rax+8] call _ZNSt6vectorIN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapES_NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES_IhSaIhEEvEESaISD_EE4backEv; std::vector<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>>::back(void) mov [rsp+148h+var_C0], rax lea rdi, [rsp+148h+var_10] lea rsi, [rsp+148h+var_B1] lea rdx, [rsp+148h+var_C0] call _ZNSt4pairIbPN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES4_IhSaIhEEvEEEC2IbSF_TnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairISJ_SK_EEEbE4typeELb1EEEOSJ_OSK_ jmp short $+2 loc_BA418: mov [rsp+148h+var_7C], 1 jmp loc_BA5C4 loc_BA428: mov rdi, [rsp+148h+var_108] add rdi, 8 call _ZNSt6vectorIPN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapES_NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES_IhSaIhEEvEESaISE_EE4backEv; std::vector<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::allocator<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> *>>::back(void) mov rdi, [rax] call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE9is_objectEv; 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>::is_object(void) test al, 1 jnz short loc_BA465 lea rdi, aWorkspaceLlm4b_1; "/workspace/llm4binary/github/2025_star3"... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aRefStackBackIs+20h; "ref_stack.back()->is_object()" xor eax, eax mov esi, 1C55h call _ggml_abort jmp short $+2 loc_BA465: mov rdi, [rsp+148h+var_108] add rdi, 48h ; 'H' call _ZNKSt6vectorIbSaIbEE5emptyEv; std::vector<bool>::empty(void) test al, 1 jnz short loc_BA479 jmp short loc_BA49C loc_BA479: lea rdi, aWorkspaceLlm4b_1; "/workspace/llm4binary/github/2025_star3"... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aKeyKeepStackEm; "!key_keep_stack.empty()" xor eax, eax mov esi, 1C57h call _ggml_abort jmp short $+2 loc_BA49C: mov rdi, [rsp+148h+var_108] add rdi, 48h ; 'H' call _ZNSt6vectorIbSaIbEE4backEv; std::vector<bool>::back(void) mov [rsp+148h+var_130], rdx mov [rsp+148h+var_128], rax jmp short $+2 loc_BA4B6: mov rax, [rsp+148h+var_130] mov rcx, [rsp+148h+var_128] mov [rsp+148h+var_D8], rcx mov [rsp+148h+var_D0], rax lea rdi, [rsp+148h+var_D8] call _ZNKSt14_Bit_referencecvbEv; std::_Bit_reference::operator bool(void) mov rdi, [rsp+148h+var_108] mov [rsp+148h+var_C1], al add rdi, 48h ; 'H' call _ZNSt6vectorIbSaIbEE8pop_backEv; std::vector<bool>::pop_back(void) jmp short $+2 loc_BA4EB: test [rsp+148h+var_C1], 1 jnz short loc_BA52C mov [rsp+148h+var_D9], 0 mov [rsp+148h+var_E8], 0 lea rdi, [rsp+148h+var_10] lea rsi, [rsp+148h+var_D9] lea rdx, [rsp+148h+var_E8] call _ZNSt4pairIbPN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES4_IhSaIhEEvEEEC2IbDnTnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairISJ_SK_EEEbE4typeELb1EEEOSJ_OSK_ jmp short $+2 loc_BA51C: mov [rsp+148h+var_7C], 1 jmp loc_BA5C4 loc_BA52C: mov rax, [rsp+148h+var_108] cmp qword ptr [rax+70h], 0 jnz short loc_BA55B lea rdi, aWorkspaceLlm4b_1; "/workspace/llm4binary/github/2025_star3"... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aObjectElement; "object_element" xor eax, eax mov esi, 1C60h call _ggml_abort jmp short $+2 loc_BA55B: lea rdi, [rsp+148h+var_F8] mov [rsp+148h+var_140], rdi lea rsi, [rsp+148h+var_58] call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEC2EOSD_; 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>::basic_json(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 rax, [rsp+148h+var_108] mov rsi, [rsp+148h+var_140] mov rcx, rax add rcx, 70h ; 'p' mov [rsp+148h+var_138], rcx mov rdi, [rax+70h] call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEaSESD_; 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=(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+148h+var_140] call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvED2Ev; 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>::~basic_json() mov rdx, [rsp+148h+var_138] mov [rsp+148h+var_F9], 1 lea rdi, [rsp+148h+var_10] lea rsi, [rsp+148h+var_F9] call _ZNSt4pairIbPN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES4_IhSaIhEEvEEEC2IbRSF_TnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairISK_SL_EEEbE4typeELb1EEEOSK_OSL_ jmp short $+2 loc_BA5B9: mov [rsp+148h+var_7C], 1 loc_BA5C4: lea rdi, [rsp+148h+var_58] call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvED2Ev; 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>::~basic_json() loc_BA5D1: mov al, [rsp+148h+var_10] mov rdx, [rsp+148h+var_8] add rsp, 148h retn loc_BA5E8: mov rdi, [rsp+arg_D8] call __Unwind_Resume
char nlohmann::json_abi_v3_11_3::detail::json_sax_dom_callback_parser<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>>::handle_value<unsigned long &>( long long a1, long long a2, char a3) { long long v3; // rdx int v4; // eax _BYTE **v5; // rax _BYTE **v6; // rax _BYTE **v7; // rax long long v8; // rax long long v9; // rax _BYTE **v10; // rax long long v11; // rdx char v13; // [rsp+3Fh] [rbp-109h] char v14; // [rsp+4Fh] [rbp-F9h] BYREF __int128 v15; // [rsp+50h] [rbp-F8h] BYREF long long v16; // [rsp+60h] [rbp-E8h] char v17; // [rsp+6Fh] [rbp-D9h] BYREF _QWORD v18[2]; // [rsp+70h] [rbp-D8h] BYREF bool v19; // [rsp+87h] [rbp-C1h] long long v20; // [rsp+88h] [rbp-C0h] BYREF char v21; // [rsp+97h] [rbp-B1h] BYREF long long v22; // [rsp+98h] [rbp-B0h] char v23; // [rsp+A7h] [rbp-A1h] BYREF long long v24; // [rsp+A8h] [rbp-A0h] BYREF char v25; // [rsp+B7h] [rbp-91h] BYREF __int128 v26; // [rsp+B8h] [rbp-90h] BYREF int v27; // [rsp+CCh] [rbp-7Ch] long long v28; // [rsp+D0h] [rbp-78h] _BYTE v29[21]; // [rsp+DBh] [rbp-6Dh] BYREF _BYTE v30[16]; // [rsp+F0h] [rbp-58h] BYREF long long v31; // [rsp+100h] [rbp-48h] char v32; // [rsp+10Fh] [rbp-39h] BYREF _QWORD v33[2]; // [rsp+110h] [rbp-38h] BYREF char v34; // [rsp+127h] [rbp-21h] long long v35; // [rsp+128h] [rbp-20h] long long v36; // [rsp+130h] [rbp-18h] _BYTE v37[8]; // [rsp+138h] [rbp-10h] BYREF v36 = a1; v35 = a2; v34 = a3 & 1; if ( (std::vector<bool>::empty((unsigned long long **)(a1 + 32)) & 1) != 0 ) ggml_abort( "/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp", 7208LL, "GGML_ASSERT(%s) failed", "!keep_stack.empty()"); v33[0] = std::vector<bool>::back(a1 + 32); v33[1] = v3; if ( std::_Bit_reference::operator bool((long long)v33) ) { ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEC2IRmmTnNSt9enable_ifIXaantsr6detail13is_basic_jsonIT0_EE5valuesr6detail18is_compatible_typeISD_SH_EE5valueEiE4typeELi0EEEOT_( v30, v35); v13 = 1; if ( (v34 & 1) == 0 ) { v4 = std::vector<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<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> *>>::size((_QWORD *)(a1 + 8)); v13 = std::function<bool ()(int,nlohmann::json_abi_v3_11_3::detail::parse_event_t,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()( (std::_Function_base *)(a1 + 128), v4, 5, (long long)v30); } v29[20] = v13 & 1; if ( (v13 & 1) != 0 ) { if ( (std::vector<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<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> *>>::empty(a1 + 8) & 1) != 0 ) { 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>::basic_json( &v26, (long long)v30); 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=( *(_QWORD *)a1, (long long)&v26); 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>::~basic_json((long long)&v26); v25 = 1; v24 = *(_QWORD *)a1; ZNSt4pairIbPN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES4_IhSaIhEEvEEEC2IbSF_TnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairISJ_SK_EEEbE4typeELb1EEEOSJ_OSK_( (long long)v37, &v25, &v24); v27 = 1; } else if ( *(_QWORD *)std::vector<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<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> *>>::back(a1 + 8) ) { v5 = (_BYTE **)std::vector<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<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> *>>::back(a1 + 8); if ( !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>::is_array(*v5) ) { v6 = (_BYTE **)std::vector<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<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> *>>::back(a1 + 8); if ( !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>::is_object(*v6) ) ggml_abort( "/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp", 7243LL, "GGML_ASSERT(%s) failed", "ref_stack.back()->is_array() || ref_stack.back()->is_object()"); } v7 = (_BYTE **)std::vector<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<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> *>>::back(a1 + 8); if ( 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>::is_array(*v7) ) { v8 = std::vector<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<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> *>>::back(a1 + 8); std::vector<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<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>>( *(_QWORD *)(*(_QWORD *)v8 + 8LL), (long long)v30); v21 = 1; v9 = std::vector<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<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> *>>::back(a1 + 8); v20 = std::vector<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>>::back(*(_QWORD *)(*(_QWORD *)v9 + 8LL)); ZNSt4pairIbPN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES4_IhSaIhEEvEEEC2IbSF_TnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairISJ_SK_EEEbE4typeELb1EEEOSJ_OSK_( (long long)v37, &v21, &v20); v27 = 1; } else { v10 = (_BYTE **)std::vector<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<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> *>>::back(a1 + 8); if ( !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>::is_object(*v10) ) ggml_abort( "/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp", 7253LL, "GGML_ASSERT(%s) failed", "ref_stack.back()->is_object()"); if ( (std::vector<bool>::empty((unsigned long long **)(a1 + 72)) & 1) != 0 ) ggml_abort( "/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp", 7255LL, "GGML_ASSERT(%s) failed", "!key_keep_stack.empty()"); v18[0] = std::vector<bool>::back(a1 + 72); v18[1] = v11; v19 = std::_Bit_reference::operator bool((long long)v18); std::vector<bool>::pop_back(a1 + 72); if ( v19 ) { if ( !*(_QWORD *)(a1 + 112) ) ggml_abort( "/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp", 7264LL, "GGML_ASSERT(%s) failed", "object_element"); 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>::basic_json( &v15, (long long)v30); 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=( *(_QWORD *)(a1 + 112), (long long)&v15); 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>::~basic_json((long long)&v15); v14 = 1; ZNSt4pairIbPN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES4_IhSaIhEEvEEEC2IbRSF_TnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairISK_SL_EEEbE4typeELb1EEEOSK_OSL_( (long long)v37, &v14, (_QWORD *)(a1 + 112)); v27 = 1; } else { v17 = 0; v16 = 0LL; ZNSt4pairIbPN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES4_IhSaIhEEvEEEC2IbDnTnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairISJ_SK_EEEbE4typeELb1EEEOSJ_OSK_( (long long)v37, &v17); v27 = 1; } } } else { v23 = 0; v22 = 0LL; ZNSt4pairIbPN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES4_IhSaIhEEvEEEC2IbDnTnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairISJ_SK_EEEbE4typeELb1EEEOSJ_OSK_( (long long)v37, &v23); v27 = 1; } } else { v29[0] = 0; v28 = 0LL; ZNSt4pairIbPN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES4_IhSaIhEEvEEEC2IbDnTnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairISJ_SK_EEEbE4typeELb1EEEOSJ_OSK_( (long long)v37, v29); v27 = 1; } 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>::~basic_json((long long)v30); } else { v32 = 0; v31 = 0LL; ZNSt4pairIbPN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES4_IhSaIhEEvEEEC2IbDnTnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairISJ_SK_EEEbE4typeELb1EEEOSJ_OSK_( (long long)v37, &v32); } return v37[0]; }
handle_value<unsigned_long&>: SUB RSP,0x148 MOV AL,DL MOV qword ptr [RSP + 0x130],RDI MOV qword ptr [RSP + 0x128],RSI AND AL,0x1 MOV byte ptr [RSP + 0x127],AL MOV RDI,qword ptr [RSP + 0x130] MOV qword ptr [RSP + 0x40],RDI ADD RDI,0x20 CALL 0x001ae730 TEST AL,0x1 JNZ 0x001ba0de JMP 0x001ba0ff LAB_001ba0de: LEA RDI,[0x30f374] MOV ESI,0x1c28 LEA RDX,[0x30914a] LEA RCX,[0x3102f4] MOV AL,0x0 CALL 0x0015aed0 LAB_001ba0ff: MOV RDI,qword ptr [RSP + 0x40] ADD RDI,0x20 CALL 0x001ae7b0 MOV qword ptr [RSP + 0x110],RAX MOV qword ptr [RSP + 0x118],RDX LEA RDI,[RSP + 0x110] CALL 0x001ac7a0 XOR AL,0xff TEST AL,0x1 JNZ 0x001ba132 JMP 0x001ba168 LAB_001ba132: MOV byte ptr [RSP + 0x10f],0x0 MOV qword ptr [RSP + 0x100],0x0 LEA RDI,[RSP + 0x138] LEA RSI,[RSP + 0x10f] LEA RDX,[RSP + 0x100] CALL 0x001af2c0 JMP 0x001ba5d1 LAB_001ba168: MOV RSI,qword ptr [RSP + 0x128] LEA RDI,[RSP + 0xf0] CALL 0x001ba600 MOV AL,0x1 TEST byte ptr [RSP + 0x127],0x1 MOV byte ptr [RSP + 0x3f],AL JNZ 0x001ba1d0 MOV RDI,qword ptr [RSP + 0x40] MOV RAX,RDI SUB RAX,-0x80 MOV qword ptr [RSP + 0x30],RAX ADD RDI,0x8 CALL 0x001ae8b0 MOV RDI,qword ptr [RSP + 0x30] MOV ESI,EAX LAB_001ba1ae: MOV EDX,0x5 LEA RCX,[RSP + 0xf0] CALL 0x001ae850 MOV byte ptr [RSP + 0x3e],AL JMP 0x001ba1c6 LAB_001ba1c6: MOV AL,byte ptr [RSP + 0x3e] MOV byte ptr [RSP + 0x3f],AL JMP 0x001ba1d0 LAB_001ba1d0: MOV AL,byte ptr [RSP + 0x3f] AND AL,0x1 MOV byte ptr [RSP + 0xef],AL TEST byte ptr [RSP + 0xef],0x1 JNZ 0x001ba250 MOV byte ptr [RSP + 0xdb],0x0 MOV qword ptr [RSP + 0xd0],0x0 LEA RDI,[RSP + 0x138] LEA RSI,[RSP + 0xdb] LEA RDX,[RSP + 0xd0] CALL 0x001af2c0 JMP 0x001ba21a LAB_001ba21a: MOV dword ptr [RSP + 0xcc],0x1 JMP 0x001ba5c4 LAB_001ba250: MOV RDI,qword ptr [RSP + 0x40] ADD RDI,0x8 CALL 0x001af2f0 TEST AL,0x1 JNZ 0x001ba264 JMP 0x001ba2e1 LAB_001ba264: LEA RDI,[RSP + 0xb8] MOV qword ptr [RSP + 0x28],RDI LEA RSI,[RSP + 0xf0] CALL 0x001af340 MOV RSI,qword ptr [RSP + 0x28] MOV RAX,qword ptr [RSP + 0x40] MOV RDI,qword ptr [RAX] CALL 0x001a92d0 MOV RDI,qword ptr [RSP + 0x28] CALL 0x001a00f0 MOV RAX,qword ptr [RSP + 0x40] MOV byte ptr [RSP + 0xb7],0x1 MOV RAX,qword ptr [RAX] MOV qword ptr [RSP + 0xa8],RAX LEA RDI,[RSP + 0x138] LEA RSI,[RSP + 0xb7] LEA RDX,[RSP + 0xa8] CALL 0x001af3c0 JMP 0x001ba2d1 LAB_001ba2d1: MOV dword ptr [RSP + 0xcc],0x1 JMP 0x001ba5c4 LAB_001ba2e1: MOV RDI,qword ptr [RSP + 0x40] ADD RDI,0x8 CALL 0x001aeea0 CMP qword ptr [RAX],0x0 JNZ 0x001ba338 MOV byte ptr [RSP + 0xa7],0x0 MOV qword ptr [RSP + 0x98],0x0 LEA RDI,[RSP + 0x138] LEA RSI,[RSP + 0xa7] LEA RDX,[RSP + 0x98] CALL 0x001af2c0 JMP 0x001ba328 LAB_001ba328: MOV dword ptr [RSP + 0xcc],0x1 JMP 0x001ba5c4 LAB_001ba338: MOV RDI,qword ptr [RSP + 0x40] ADD RDI,0x8 CALL 0x001aeea0 MOV RDI,qword ptr [RAX] CALL 0x001af3f0 TEST AL,0x1 JNZ 0x001ba38f MOV RDI,qword ptr [RSP + 0x40] ADD RDI,0x8 CALL 0x001aeea0 MOV RDI,qword ptr [RAX] CALL 0x001af410 TEST AL,0x1 JNZ 0x001ba38f LEA RDI,[0x30f374] LEA RDX,[0x30914a] LEA RCX,[0x310308] XOR EAX,EAX MOV ESI,0x1c4b CALL 0x0015aed0 JMP 0x001ba38f LAB_001ba38f: MOV RDI,qword ptr [RSP + 0x40] ADD RDI,0x8 CALL 0x001aeea0 MOV RDI,qword ptr [RAX] CALL 0x001af3f0 TEST AL,0x1 JNZ 0x001ba3ab JMP 0x001ba428 LAB_001ba3ab: MOV RDI,qword ptr [RSP + 0x40] ADD RDI,0x8 CALL 0x001aeea0 MOV RAX,qword ptr [RAX] MOV RDI,qword ptr [RAX + 0x8] LEA RSI,[RSP + 0xf0] CALL 0x001af430 JMP 0x001ba3cf LAB_001ba3cf: MOV RDI,qword ptr [RSP + 0x40] MOV byte ptr [RSP + 0x97],0x1 ADD RDI,0x8 CALL 0x001aeea0 MOV RAX,qword ptr [RAX] MOV RDI,qword ptr [RAX + 0x8] CALL 0x001af4b0 MOV qword ptr [RSP + 0x88],RAX LEA RDI,[RSP + 0x138] LEA RSI,[RSP + 0x97] LEA RDX,[RSP + 0x88] CALL 0x001af3c0 JMP 0x001ba418 LAB_001ba418: MOV dword ptr [RSP + 0xcc],0x1 JMP 0x001ba5c4 LAB_001ba428: MOV RDI,qword ptr [RSP + 0x40] ADD RDI,0x8 CALL 0x001aeea0 MOV RDI,qword ptr [RAX] CALL 0x001af410 TEST AL,0x1 JNZ 0x001ba465 LEA RDI,[0x30f374] LEA RDX,[0x30914a] LEA RCX,[0x310328] XOR EAX,EAX MOV ESI,0x1c55 CALL 0x0015aed0 JMP 0x001ba465 LAB_001ba465: MOV RDI,qword ptr [RSP + 0x40] ADD RDI,0x48 CALL 0x001ae730 TEST AL,0x1 JNZ 0x001ba479 JMP 0x001ba49c LAB_001ba479: LEA RDI,[0x30f374] LEA RDX,[0x30914a] LEA RCX,[0x310346] XOR EAX,EAX MOV ESI,0x1c57 CALL 0x0015aed0 JMP 0x001ba49c LAB_001ba49c: MOV RDI,qword ptr [RSP + 0x40] ADD RDI,0x48 CALL 0x001ae7b0 MOV qword ptr [RSP + 0x18],RDX MOV qword ptr [RSP + 0x20],RAX JMP 0x001ba4b6 LAB_001ba4b6: MOV RAX,qword ptr [RSP + 0x18] MOV RCX,qword ptr [RSP + 0x20] MOV qword ptr [RSP + 0x70],RCX MOV qword ptr [RSP + 0x78],RAX LEA RDI,[RSP + 0x70] CALL 0x001ac7a0 MOV RDI,qword ptr [RSP + 0x40] MOV byte ptr [RSP + 0x87],AL ADD RDI,0x48 CALL 0x001ae830 JMP 0x001ba4eb LAB_001ba4eb: TEST byte ptr [RSP + 0x87],0x1 JNZ 0x001ba52c MOV byte ptr [RSP + 0x6f],0x0 MOV qword ptr [RSP + 0x60],0x0 LEA RDI,[RSP + 0x138] LEA RSI,[RSP + 0x6f] LEA RDX,[RSP + 0x60] CALL 0x001af2c0 JMP 0x001ba51c LAB_001ba51c: MOV dword ptr [RSP + 0xcc],0x1 JMP 0x001ba5c4 LAB_001ba52c: MOV RAX,qword ptr [RSP + 0x40] CMP qword ptr [RAX + 0x70],0x0 JNZ 0x001ba55b LEA RDI,[0x30f374] LEA RDX,[0x30914a] LEA RCX,[0x31035e] XOR EAX,EAX MOV ESI,0x1c60 CALL 0x0015aed0 JMP 0x001ba55b LAB_001ba55b: LEA RDI,[RSP + 0x50] MOV qword ptr [RSP + 0x8],RDI LEA RSI,[RSP + 0xf0] CALL 0x001af340 MOV RAX,qword ptr [RSP + 0x40] MOV RSI,qword ptr [RSP + 0x8] MOV RCX,RAX ADD RCX,0x70 MOV qword ptr [RSP + 0x10],RCX MOV RDI,qword ptr [RAX + 0x70] CALL 0x001a92d0 MOV RDI,qword ptr [RSP + 0x8] CALL 0x001a00f0 MOV RDX,qword ptr [RSP + 0x10] MOV byte ptr [RSP + 0x4f],0x1 LEA RDI,[RSP + 0x138] LEA RSI,[RSP + 0x4f] CALL 0x001af4f0 LAB_001ba5b7: JMP 0x001ba5b9 LAB_001ba5b9: MOV dword ptr [RSP + 0xcc],0x1 LAB_001ba5c4: LEA RDI,[RSP + 0xf0] CALL 0x001a00f0 LAB_001ba5d1: MOV AL,byte ptr [RSP + 0x138] MOV RDX,qword ptr [RSP + 0x140] ADD RSP,0x148 RET
/* std::pair<bool, 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::json_sax_dom_callback_parser<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> >::handle_value<unsigned long&>(unsigned long&, bool) */ int1 [16] __thiscall nlohmann::json_abi_v3_11_3::detail:: json_sax_dom_callback_parser<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>> ::handle_value<unsigned_long&> (json_sax_dom_callback_parser<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,ulong *param_1,bool param_2) { bool bVar1; int4 uVar2; ulong uVar3; long *plVar4; int8 *puVar5; int8 uVar6; int1 auVar7 [16]; byte local_109; int1 local_f9; 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_f8 [16]; int8 local_e8; int1 local_d9; int1 local_d8 [16]; byte local_c1; int8 local_c0; int1 local_b1; int8 local_b0; int1 local_a1; int8 local_a0; int1 local_91; 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_90 [20]; int4 local_7c; int8 local_78; int1 local_6d [20]; byte local_59; 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_58 [16]; int8 local_48; int1 local_39; _Bit_reference local_38 [23]; byte local_21; ulong *local_20; json_sax_dom_callback_parser<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; int1 local_10 [8]; int8 local_8; local_21 = param_2; local_20 = param_1; local_18 = this; uVar3 = std::vector<bool,std::allocator<bool>>::empty ((vector<bool,std::allocator<bool>> *)(this + 0x20)); if ((uVar3 & 1) != 0) { ggml_abort("/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",0x1c28, "GGML_ASSERT(%s) failed","!keep_stack.empty()"); } local_38._0_16_ = std::vector<bool,std::allocator<bool>>::back ((vector<bool,std::allocator<bool>> *)(this + 0x20)); bVar1 = std::_Bit_reference::operator_cast_to_bool(local_38); if (((bVar1 ^ 0xffU) & 1) == 0) { _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEC2IRmmTnNSt9enable_ifIXaantsr6detail13is_basic_jsonIT0_EE5valuesr6detail18is_compatible_typeISD_SH_EE5valueEiE4typeELi0EEEOT_ (local_58,local_20); local_109 = 1; if ((local_21 & 1) == 0) { uVar2 = std:: vector<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<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>*>> ::size((vector<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<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 + 8)); /* try { // try from 001ba1ae to 001ba5b6 has its CatchHandler @ 001ba22a */ local_109 = std:: function<bool(int,nlohmann::json_abi_v3_11_3::detail::parse_event_t,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()((function<bool(int,nlohmann::json_abi_v3_11_3::detail::parse_event_t,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 + 0x80),uVar2,5,local_58); } local_59 = local_109 & 1; if (local_59 == 0) { local_6d[0] = 0; local_78 = 0; _ZNSt4pairIbPN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES4_IhSaIhEEvEEEC2IbDnTnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairISJ_SK_EEEbE4typeELb1EEEOSJ_OSK_ (local_10,local_6d,&local_78); } else { uVar3 = std:: vector<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<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>*>> ::empty((vector<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<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 + 8)); if ((uVar3 & 1) == 0) { plVar4 = (long *)std:: vector<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<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>*>> ::back((vector<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<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 + 8)); if (*plVar4 == 0) { local_a1 = 0; local_b0 = 0; _ZNSt4pairIbPN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES4_IhSaIhEEvEEEC2IbDnTnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairISJ_SK_EEEbE4typeELb1EEEOSJ_OSK_ (local_10,&local_a1,&local_b0); } else { puVar5 = (int8 *) std:: vector<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<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>*>> ::back((vector<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<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 + 8)); uVar3 = 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> ::is_array((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> *)*puVar5); if ((uVar3 & 1) == 0) { puVar5 = (int8 *) std:: vector<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<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>*>> ::back((vector<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<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 + 8)); uVar3 = 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> ::is_object((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> *)*puVar5); if ((uVar3 & 1) == 0) { ggml_abort("/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp" ,0x1c4b,"GGML_ASSERT(%s) failed", "ref_stack.back()->is_array() || ref_stack.back()->is_object()"); } } puVar5 = (int8 *) std:: vector<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<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>*>> ::back((vector<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<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 + 8)); uVar3 = 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> ::is_array((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> *)*puVar5); if ((uVar3 & 1) == 0) { puVar5 = (int8 *) std:: vector<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<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>*>> ::back((vector<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<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 + 8)); uVar3 = 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> ::is_object((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> *)*puVar5); if ((uVar3 & 1) == 0) { ggml_abort("/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp" ,0x1c55,"GGML_ASSERT(%s) failed","ref_stack.back()->is_object()"); } uVar3 = std::vector<bool,std::allocator<bool>>::empty ((vector<bool,std::allocator<bool>> *)(this + 0x48)); if ((uVar3 & 1) != 0) { ggml_abort("/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp" ,0x1c57,"GGML_ASSERT(%s) failed","!key_keep_stack.empty()"); } local_d8 = std::vector<bool,std::allocator<bool>>::back ((vector<bool,std::allocator<bool>> *)(this + 0x48)); local_c1 = std::_Bit_reference::operator_cast_to_bool((_Bit_reference *)local_d8); std::vector<bool,std::allocator<bool>>::pop_back ((vector<bool,std::allocator<bool>> *)(this + 0x48)); if ((local_c1 & 1) == 0) { local_d9 = 0; local_e8 = 0; _ZNSt4pairIbPN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES4_IhSaIhEEvEEEC2IbDnTnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairISJ_SK_EEEbE4typeELb1EEEOSJ_OSK_ (local_10,&local_d9,&local_e8); } else { if (*(long *)(this + 0x70) == 0) { ggml_abort("/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp" ,0x1c60,"GGML_ASSERT(%s) failed","object_element"); } 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> ::basic_json(local_f8,local_58); 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=(*(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 + 0x70),local_f8); 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> ::~basic_json(local_f8); local_f9 = 1; _ZNSt4pairIbPN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES4_IhSaIhEEvEEEC2IbRSF_TnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairISK_SL_EEEbE4typeELb1EEEOSK_OSL_ (local_10,&local_f9,this + 0x70); } } else { plVar4 = (long *)std:: vector<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<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>*>> ::back((vector<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<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 + 8)); std:: vector<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<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<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<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<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>>> **)(*plVar4 + 8),local_58); local_b1 = 1; plVar4 = (long *)std:: vector<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<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>*>> ::back((vector<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<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 + 8)); local_c0 = std:: vector<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<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>>> ::back(*(vector<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<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>>> **)(*plVar4 + 8)); _ZNSt4pairIbPN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES4_IhSaIhEEvEEEC2IbSF_TnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairISJ_SK_EEEbE4typeELb1EEEOSJ_OSK_ (local_10,&local_b1,&local_c0); } } } else { 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> ::basic_json(local_90,local_58); 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=(*(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_90); 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> ::~basic_json(local_90); local_91 = 1; local_a0 = *(int8 *)this; _ZNSt4pairIbPN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES4_IhSaIhEEvEEEC2IbSF_TnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairISJ_SK_EEEbE4typeELb1EEEOSJ_OSK_ (local_10,&local_91,&local_a0); } } local_7c = 1; uVar6 = 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> ::~basic_json(local_58); } else { local_39 = 0; local_48 = 0; uVar6 = _ZNSt4pairIbPN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES4_IhSaIhEEvEEEC2IbDnTnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairISJ_SK_EEEbE4typeELb1EEEOSJ_OSK_ (local_10,&local_39,&local_48); } auVar7._1_7_ = (int7)((ulong)uVar6 >> 8); auVar7[0] = local_10[0]; auVar7._8_8_ = local_8; return auVar7; }
47,417
std::pair<bool, 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::json_sax_dom_callback_parser<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>>::handle_value<bool&>(bool&, bool)
monkey531[P]llama/common/json.hpp
std::pair<bool, BasicJsonType*> handle_value(Value&& v, const bool skip_callback = false) { JSON_ASSERT(!keep_stack.empty()); // do not handle this value if we know it would be added to a discarded // container if (!keep_stack.back()) { return {false, nullptr}; } // create value auto value = BasicJsonType(std::forward<Value>(v)); // check callback const bool keep = skip_callback || callback(static_cast<int>(ref_stack.size()), parse_event_t::value, value); // do not handle this value if we just learnt it shall be discarded if (!keep) { return {false, nullptr}; } if (ref_stack.empty()) { root = std::move(value); return {true, & root}; } // skip this value if we already decided to skip the parent // (https://github.com/nlohmann/json/issues/971#issuecomment-413678360) if (!ref_stack.back()) { return {false, nullptr}; } // we now only expect arrays and objects JSON_ASSERT(ref_stack.back()->is_array() || ref_stack.back()->is_object()); // array if (ref_stack.back()->is_array()) { ref_stack.back()->m_data.m_value.array->emplace_back(std::move(value)); return {true, & (ref_stack.back()->m_data.m_value.array->back())}; } // object JSON_ASSERT(ref_stack.back()->is_object()); // check if we should store an element for the current key JSON_ASSERT(!key_keep_stack.empty()); const bool store_element = key_keep_stack.back(); key_keep_stack.pop_back(); if (!store_element) { return {false, nullptr}; } JSON_ASSERT(object_element); *object_element = std::move(value); return {true, object_element}; }
O1
cpp
std::pair<bool, 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::json_sax_dom_callback_parser<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>>::handle_value<bool&>(bool&, bool): pushq %rbp pushq %r15 pushq %r14 pushq %rbx subq $0x48, %rsp movl %edx, %ebp movq %rdi, %rbx movq 0x30(%rdi), %rax movl 0x38(%rdi), %ecx cmpq %rax, 0x20(%rdi) sete %dl testl %ecx, %ecx sete %dil andb %dl, %dil cmpb $0x1, %dil je 0x610bc movl %ecx, %ecx movabsq $-0x8000000000000000, %r15 # imm = 0x8000000000000000 leaq -0x1(%rcx), %rdx addq $0x3e, %rcx testq %rdx, %rdx cmovnsq %rdx, %rcx sarq $0x6, %rcx leaq (%rax,%rcx,8), %rax leaq 0x3f(%r15), %rcx andq %rdx, %rcx xorl %edi, %edi cmpq %r15, %rcx setbe %dil movq -0x8(%rax,%rdi,8), %rax btq %rdx, %rax jae 0x60f4f xorps %xmm0, %xmm0 leaq 0x10(%rsp), %r14 movaps %xmm0, (%r14) movq (%rsi), %rsi movq %r14, %rdi callq 0x61156 movq %r14, %rdi movl $0x1, %esi callq 0x58ac0 testb %bpl, %bpl jne 0x60efc movq 0x10(%rbx), %rax subq 0x8(%rbx), %rax shrq $0x3, %rax movl %eax, 0xc(%rsp) movb $0x5, 0xb(%rsp) cmpq $0x0, 0x90(%rbx) je 0x610dd leaq 0x80(%rbx), %rdi leaq 0xc(%rsp), %rsi leaq 0xb(%rsp), %rdx leaq 0x10(%rsp), %rcx callq *0x98(%rbx) testb %al, %al je 0x61090 movq 0x10(%rbx), %rax cmpq %rax, 0x8(%rbx) je 0x60f59 movq -0x8(%rax), %rax testq %rax, %rax je 0x61090 movzbl (%rax), %ecx cmpl $0x1, %ecx je 0x60fb3 cmpl $0x2, %ecx jne 0x610e2 movq 0x8(%rax), %rdi leaq 0x10(%rsp), %rsi callq 0x5d8f2 movq 0x10(%rbx), %rax movq -0x8(%rax), %rax movq 0x8(%rax), %rax movq 0x8(%rax), %r14 addq $-0x10, %r14 jmp 0x6108c xorl %ebx, %ebx xorl %r14d, %r14d jmp 0x610ac leaq 0x10(%rsp), %r14 movaps (%r14), %xmm0 leaq 0x30(%rsp), %r15 movaps %xmm0, (%r15) movq %r14, %rdi xorl %esi, %esi callq 0x58ac0 movb $0x0, (%r14) movq $0x0, 0x8(%r14) movq %r15, %rdi movl $0x1, %esi callq 0x58ac0 movq (%rbx), %rdi movq %r15, %rsi callq 0x5b45c movq %r15, %rdi xorl %esi, %esi callq 0x58ac0 movq %r15, %rdi callq 0x5e2ac movq (%rbx), %r14 jmp 0x6108c movq 0x58(%rbx), %rax movl 0x60(%rbx), %ecx cmpq %rax, 0x48(%rbx) sete %dl testl %ecx, %ecx sete %sil andb %dl, %sil cmpb $0x1, %sil je 0x610f0 movl %ecx, %esi leaq -0x1(%rsi), %rcx movq %rsi, %rdx addq $0x3e, %rdx testq %rcx, %rcx cmovnsq %rcx, %rdx sarq $0x6, %rdx leaq (%rax,%rdx,8), %rdi leaq 0x3f(%r15), %rdx andq %rcx, %rdx xorl %r8d, %r8d cmpq %r15, %rdx setbe %r8b movl $0x1, %edx shlq %cl, %rdx andq -0x8(%rdi,%r8,8), %rdx subl $0x1, %esi movl %esi, 0x60(%rbx) jae 0x61025 movl $0x3f, 0x60(%rbx) addq $-0x8, %rax movq %rax, 0x58(%rbx) testq %rdx, %rdx je 0x61090 cmpq $0x0, 0x70(%rbx) je 0x61111 leaq 0x10(%rsp), %r14 movaps (%r14), %xmm0 leaq 0x20(%rsp), %r15 movaps %xmm0, (%r15) movq %r14, %rdi xorl %esi, %esi callq 0x58ac0 movb $0x0, (%r14) movq $0x0, 0x8(%r14) movq %r15, %rdi movl $0x1, %esi callq 0x58ac0 movq 0x70(%rbx), %rdi movq %r15, %rsi callq 0x5b45c movq %r15, %rdi xorl %esi, %esi callq 0x58ac0 movq %r15, %rdi callq 0x5e2ac movq 0x70(%rbx), %r14 movb $0x1, %bl jmp 0x61095 xorl %ebx, %ebx xorl %r14d, %r14d leaq 0x10(%rsp), %r15 movq %r15, %rdi xorl %esi, %esi callq 0x58ac0 movq %r15, %rdi callq 0x5e2ac movl %ebx, %eax movq %r14, %rdx addq $0x48, %rsp popq %rbx popq %r14 popq %r15 popq %rbp retq leaq 0x8dd06(%rip), %rdi # 0xeedc9 leaq 0x88140(%rip), %rdx # 0xe920a leaq 0x8ec5d(%rip), %rcx # 0xefd2e movl $0x1c28, %esi # imm = 0x1C28 xorl %eax, %eax callq 0x1bec0 callq 0x1b330 leaq 0x8ec59(%rip), %rcx # 0xefd42 movl $0x1c4b, %esi # imm = 0x1C4B jmp 0x610fc leaq 0x8ec89(%rip), %rcx # 0xefd80 movl $0x1c57, %esi # imm = 0x1C57 leaq 0x8dcc6(%rip), %rdi # 0xeedc9 leaq 0x88100(%rip), %rdx # 0xe920a xorl %eax, %eax callq 0x1bec0 leaq 0x8dcb1(%rip), %rdi # 0xeedc9 leaq 0x880eb(%rip), %rdx # 0xe920a leaq 0x8ec72(%rip), %rcx # 0xefd98 movl $0x1c60, %esi # imm = 0x1C60 xorl %eax, %eax callq 0x1bec0 jmp 0x61134 movq %rax, %rbx leaq 0x10(%rsp), %r14 movq %r14, %rdi xorl %esi, %esi callq 0x58ac0 movq %r14, %rdi callq 0x5e2ac movq %rbx, %rdi callq 0x1bfd0
_ZN8nlohmann16json_abi_v3_11_36detail28json_sax_dom_callback_parserINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12handle_valueIRmEESt4pairIbPSF_EOT_b: push rbp push r15 push r14 push rbx sub rsp, 48h mov ebp, edx mov rbx, rdi mov rax, [rdi+30h] mov ecx, [rdi+38h] cmp [rdi+20h], rax setz dl test ecx, ecx setz dil and dil, dl cmp dil, 1 jz loc_610BC mov ecx, ecx mov r15, 8000000000000000h lea rdx, [rcx-1] add rcx, 3Eh ; '>' test rdx, rdx cmovns rcx, rdx sar rcx, 6 lea rax, [rax+rcx*8] lea rcx, [r15+3Fh] and rcx, rdx xor edi, edi cmp rcx, r15 setbe dil mov rax, [rax+rdi*8-8] bt rax, rdx jnb loc_60F4F xorps xmm0, xmm0 lea r14, [rsp+68h+var_58] movaps xmmword ptr [r14], xmm0 mov rsi, [rsi] mov rdi, r14 call _ZN8nlohmann16json_abi_v3_11_36detail20external_constructorILNS1_7value_tE6EE9constructINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES8_IhSaIhEEvEEEEvRT_NSJ_17number_unsigned_tE; nlohmann::json_abi_v3_11_3::detail::external_constructor<(nlohmann::json_abi_v3_11_3::detail::value_t)6>::construct<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>>(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> &,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>::number_unsigned_t) mov rdi, r14 mov esi, 1 call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; 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>::assert_invariant(bool) test bpl, bpl jnz short loc_60EFC mov rax, [rbx+10h] sub rax, [rbx+8] shr rax, 3 mov [rsp+68h+var_5C], eax mov [rsp+68h+var_5D], 5 cmp qword ptr [rbx+90h], 0 jz loc_610DD lea rdi, [rbx+80h] lea rsi, [rsp+68h+var_5C] lea rdx, [rsp+68h+var_5D] lea rcx, [rsp+68h+var_58] call qword ptr [rbx+98h] test al, al jz loc_61090 loc_60EFC: mov rax, [rbx+10h] cmp [rbx+8], rax jz short loc_60F59 mov rax, [rax-8] test rax, rax jz loc_61090 movzx ecx, byte ptr [rax] cmp ecx, 1 jz loc_60FB3 cmp ecx, 2 jnz loc_610E2 mov rdi, [rax+8] lea rsi, [rsp+68h+var_58] call _ZNSt6vectorIN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapES_NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES_IhSaIhEEvEESaISD_EE12emplace_backIJSD_EEERSD_DpOT_; std::vector<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<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>>(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 rax, [rbx+10h] mov rax, [rax-8] mov rax, [rax+8] mov r14, [rax+8] add r14, 0FFFFFFFFFFFFFFF0h jmp loc_6108C loc_60F4F: xor ebx, ebx xor r14d, r14d jmp loc_610AC loc_60F59: lea r14, [rsp+68h+var_58] movaps xmm0, xmmword ptr [r14] lea r15, [rsp+68h+var_38] movaps xmmword ptr [r15], xmm0 mov rdi, r14 xor esi, esi call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; 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>::assert_invariant(bool) mov byte ptr [r14], 0 mov qword ptr [r14+8], 0 mov rdi, r15 mov esi, 1 call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; 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>::assert_invariant(bool) mov rdi, [rbx] mov rsi, r15 call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEaSESD_; 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=(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, r15 xor esi, esi call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; 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>::assert_invariant(bool) mov rdi, r15 call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE4dataD2Ev; 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>::data::~data() mov r14, [rbx] jmp loc_6108C loc_60FB3: mov rax, [rbx+58h] mov ecx, [rbx+60h] cmp [rbx+48h], rax setz dl test ecx, ecx setz sil and sil, dl cmp sil, 1 jz loc_610F0 mov esi, ecx lea rcx, [rsi-1] mov rdx, rsi add rdx, 3Eh ; '>' test rcx, rcx cmovns rdx, rcx sar rdx, 6 lea rdi, [rax+rdx*8] lea rdx, [r15+3Fh] and rdx, rcx xor r8d, r8d cmp rdx, r15 setbe r8b mov edx, 1 shl rdx, cl and rdx, [rdi+r8*8-8] sub esi, 1 mov [rbx+60h], esi jnb short loc_61025 mov dword ptr [rbx+60h], 3Fh ; '?' add rax, 0FFFFFFFFFFFFFFF8h mov [rbx+58h], rax loc_61025: test rdx, rdx jz short loc_61090 cmp qword ptr [rbx+70h], 0 jz loc_61111 lea r14, [rsp+68h+var_58] movaps xmm0, xmmword ptr [r14] lea r15, [rsp+68h+var_48] movaps xmmword ptr [r15], xmm0 mov rdi, r14 xor esi, esi call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; 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>::assert_invariant(bool) mov byte ptr [r14], 0 mov qword ptr [r14+8], 0 mov rdi, r15 mov esi, 1 call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; 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>::assert_invariant(bool) mov rdi, [rbx+70h] mov rsi, r15 call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEaSESD_; 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=(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, r15 xor esi, esi call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; 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>::assert_invariant(bool) mov rdi, r15 call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE4dataD2Ev; 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>::data::~data() mov r14, [rbx+70h] loc_6108C: mov bl, 1 jmp short loc_61095 loc_61090: xor ebx, ebx xor r14d, r14d loc_61095: lea r15, [rsp+68h+var_58] mov rdi, r15 xor esi, esi call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; 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>::assert_invariant(bool) mov rdi, r15 call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE4dataD2Ev; 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>::data::~data() loc_610AC: mov eax, ebx mov rdx, r14 add rsp, 48h pop rbx pop r14 pop r15 pop rbp retn loc_610BC: lea rdi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github/2025_star3"... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aKeepStackEmpty; "!keep_stack.empty()" mov esi, 1C28h xor eax, eax call _ggml_abort loc_610DD: call __ZSt25__throw_bad_function_callv; std::__throw_bad_function_call(void) loc_610E2: lea rcx, aRefStackBackIs; "ref_stack.back()->is_array() || ref_sta"... mov esi, 1C4Bh jmp short loc_610FC loc_610F0: lea rcx, aKeyKeepStackEm; "!key_keep_stack.empty()" mov esi, 1C57h loc_610FC: lea rdi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github/2025_star3"... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" xor eax, eax call _ggml_abort loc_61111: lea rdi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github/2025_star3"... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aObjectElement; "object_element" mov esi, 1C60h xor eax, eax call _ggml_abort jmp short $+2 loc_61134: mov rbx, rax lea r14, [rsp+68h+var_58] mov rdi, r14 xor esi, esi call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; 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>::assert_invariant(bool) mov rdi, r14 call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE4dataD2Ev; 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>::data::~data() mov rdi, rbx call __Unwind_Resume
long long nlohmann::json_abi_v3_11_3::detail::json_sax_dom_callback_parser<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>>::handle_value<unsigned long &>( long long a1, _QWORD *a2, char a3) { unsigned int v4; // ebx long long v5; // rax unsigned int v6; // ecx signed long long v7; // rdx long long v8; // rcx long long v9; // rax long long v10; // rax unsigned __int8 *v11; // rax int v12; // ecx long long v13; // rax unsigned int v14; // ecx long long v15; // rsi long long v16; // rcx long long v17; // rdx long long v18; // rdx const char *v20; // rcx long long v21; // rsi long long v22; // rbx char v23; // [rsp+Bh] [rbp-5Dh] BYREF int v24; // [rsp+Ch] [rbp-5Ch] BYREF __int128 v25; // [rsp+10h] [rbp-58h] BYREF __int128 v26; // [rsp+20h] [rbp-48h] BYREF _OWORD v27[3]; // [rsp+30h] [rbp-38h] BYREF v4 = a1; v5 = *(_QWORD *)(a1 + 48); v6 = *(_DWORD *)(a1 + 56); if ( *(_QWORD *)(a1 + 32) == v5 && v6 == 0 ) { ggml_abort( "/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp", 7208LL, "GGML_ASSERT(%s) failed", "!keep_stack.empty()"); goto LABEL_28; } v7 = v6 - 1LL; v8 = v6 + 62LL; if ( v7 >= 0 ) v8 = v7; v9 = *(_QWORD *)(v5 + 8 * (v8 >> 6) + 8LL * ((v7 & 0x800000000000003FLL) <= 0x8000000000000000LL) - 8); if ( _bittest64(&v9, v7) ) { v25 = 0LL; nlohmann::json_abi_v3_11_3::detail::external_constructor<(nlohmann::json_abi_v3_11_3::detail::value_t)6>::construct<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>>( &v25, *a2); 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>::assert_invariant((char *)&v25); if ( a3 ) { LABEL_8: v10 = *(_QWORD *)(a1 + 16); if ( *(_QWORD *)(a1 + 8) == v10 ) { v27[0] = v25; 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>::assert_invariant((char *)&v25); LOBYTE(v25) = 0; *((_QWORD *)&v25 + 1) = 0LL; 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>::assert_invariant((char *)v27); 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=( *(_QWORD *)a1, (long long)v27); 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>::assert_invariant((char *)v27); 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>::data::~data(v27); goto LABEL_23; } v11 = *(unsigned __int8 **)(v10 - 8); if ( v11 ) { v12 = *v11; if ( v12 != 1 ) { if ( v12 == 2 ) { std::vector<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<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>>( *((_QWORD *)v11 + 1), (long long)&v25); LABEL_23: LOBYTE(v4) = 1; LABEL_25: 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>::assert_invariant((char *)&v25); 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>::data::~data(&v25); return v4; } v20 = "ref_stack.back()->is_array() || ref_stack.back()->is_object()"; v21 = 7243LL; goto LABEL_31; } v13 = *(_QWORD *)(a1 + 88); v14 = *(_DWORD *)(a1 + 96); if ( *(_QWORD *)(a1 + 72) == v13 && v14 == 0 ) { v20 = "!key_keep_stack.empty()"; v21 = 7255LL; LABEL_31: ggml_abort( "/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp", v21, "GGML_ASSERT(%s) failed", v20); goto LABEL_32; } v15 = v14; v16 = v14 - 1LL; v17 = v15 + 62; if ( v16 >= 0 ) v17 = v16; v18 = *(_QWORD *)(v13 + 8 * (v17 >> 6) + 8LL * ((v16 & 0x800000000000003FLL) <= 0x8000000000000000LL) - 8) & (1LL << v16); *(_DWORD *)(a1 + 96) = v15 - 1; if ( !(_DWORD)v15 ) { *(_DWORD *)(a1 + 96) = 63; *(_QWORD *)(a1 + 88) = v13 - 8; } if ( v18 ) { if ( *(_QWORD *)(a1 + 112) ) { v26 = v25; 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>::assert_invariant((char *)&v25); LOBYTE(v25) = 0; *((_QWORD *)&v25 + 1) = 0LL; 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>::assert_invariant((char *)&v26); 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=( *(_QWORD *)(a1 + 112), (long long)&v26); 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>::assert_invariant((char *)&v26); 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>::data::~data(&v26); goto LABEL_23; } LABEL_32: v22 = ggml_abort( "/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp", 7264LL, "GGML_ASSERT(%s) failed", "object_element"); 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>::assert_invariant((char *)&v25); 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>::data::~data(&v25); _Unwind_Resume(v22); } } LABEL_24: v4 = 0; goto LABEL_25; } v24 = (*(_QWORD *)(a1 + 16) - *(_QWORD *)(a1 + 8)) >> 3; v23 = 5; if ( *(_QWORD *)(a1 + 144) ) { if ( !(*(unsigned __int8 ( **)(long long, int *, char *, __int128 *))(a1 + 152))( a1 + 128, &v24, &v23, &v25) ) goto LABEL_24; goto LABEL_8; } LABEL_28: std::__throw_bad_function_call(); } return 0; }
handle_value<unsigned_long&>: PUSH RBP PUSH R15 PUSH R14 PUSH RBX SUB RSP,0x48 MOV EBP,EDX MOV RBX,RDI MOV RAX,qword ptr [RDI + 0x30] MOV ECX,dword ptr [RDI + 0x38] CMP qword ptr [RDI + 0x20],RAX SETZ DL TEST ECX,ECX SETZ DIL AND DIL,DL CMP DIL,0x1 JZ 0x001610bc MOV ECX,ECX MOV R15,-0x8000000000000000 LEA RDX,[RCX + -0x1] ADD RCX,0x3e TEST RDX,RDX CMOVNS RCX,RDX SAR RCX,0x6 LEA RAX,[RAX + RCX*0x8] LEA RCX,[R15 + 0x3f] AND RCX,RDX XOR EDI,EDI CMP RCX,R15 SETBE DIL MOV RAX,qword ptr [RAX + RDI*0x8 + -0x8] BT RAX,RDX JNC 0x00160f4f XORPS XMM0,XMM0 LEA R14,[RSP + 0x10] MOVAPS xmmword ptr [R14],XMM0 MOV RSI,qword ptr [RSI] MOV RDI,R14 CALL 0x00161156 MOV RDI,R14 MOV ESI,0x1 CALL 0x00158ac0 TEST BPL,BPL JNZ 0x00160efc MOV RAX,qword ptr [RBX + 0x10] SUB RAX,qword ptr [RBX + 0x8] SHR RAX,0x3 MOV dword ptr [RSP + 0xc],EAX MOV byte ptr [RSP + 0xb],0x5 CMP qword ptr [RBX + 0x90],0x0 JZ 0x001610dd LEA RDI,[RBX + 0x80] LAB_00160edf: LEA RSI,[RSP + 0xc] LEA RDX,[RSP + 0xb] LEA RCX,[RSP + 0x10] CALL qword ptr [RBX + 0x98] TEST AL,AL JZ 0x00161090 LAB_00160efc: MOV RAX,qword ptr [RBX + 0x10] CMP qword ptr [RBX + 0x8],RAX JZ 0x00160f59 MOV RAX,qword ptr [RAX + -0x8] TEST RAX,RAX JZ 0x00161090 MOVZX ECX,byte ptr [RAX] CMP ECX,0x1 JZ 0x00160fb3 CMP ECX,0x2 JNZ 0x001610e2 MOV RDI,qword ptr [RAX + 0x8] LEA RSI,[RSP + 0x10] CALL 0x0015d8f2 LAB_00160f36: MOV RAX,qword ptr [RBX + 0x10] MOV RAX,qword ptr [RAX + -0x8] MOV RAX,qword ptr [RAX + 0x8] MOV R14,qword ptr [RAX + 0x8] ADD R14,-0x10 JMP 0x0016108c LAB_00160f4f: XOR EBX,EBX XOR R14D,R14D JMP 0x001610ac LAB_00160f59: LEA R14,[RSP + 0x10] MOVAPS XMM0,xmmword ptr [R14] LEA R15,[RSP + 0x30] MOVAPS xmmword ptr [R15],XMM0 MOV RDI,R14 XOR ESI,ESI CALL 0x00158ac0 MOV byte ptr [R14],0x0 MOV qword ptr [R14 + 0x8],0x0 MOV RDI,R15 MOV ESI,0x1 CALL 0x00158ac0 MOV RDI,qword ptr [RBX] MOV RSI,R15 CALL 0x0015b45c MOV RDI,R15 XOR ESI,ESI CALL 0x00158ac0 MOV RDI,R15 CALL 0x0015e2ac MOV R14,qword ptr [RBX] JMP 0x0016108c LAB_00160fb3: MOV RAX,qword ptr [RBX + 0x58] MOV ECX,dword ptr [RBX + 0x60] CMP qword ptr [RBX + 0x48],RAX SETZ DL TEST ECX,ECX SETZ SIL AND SIL,DL CMP SIL,0x1 JZ 0x001610f0 MOV ESI,ECX LEA RCX,[RSI + -0x1] MOV RDX,RSI ADD RDX,0x3e TEST RCX,RCX CMOVNS RDX,RCX SAR RDX,0x6 LEA RDI,[RAX + RDX*0x8] LEA RDX,[R15 + 0x3f] AND RDX,RCX XOR R8D,R8D CMP RDX,R15 SETBE R8B MOV EDX,0x1 SHL RDX,CL AND RDX,qword ptr [RDI + R8*0x8 + -0x8] SUB ESI,0x1 MOV dword ptr [RBX + 0x60],ESI JNC 0x00161025 MOV dword ptr [RBX + 0x60],0x3f ADD RAX,-0x8 MOV qword ptr [RBX + 0x58],RAX LAB_00161025: TEST RDX,RDX JZ 0x00161090 CMP qword ptr [RBX + 0x70],0x0 JZ 0x00161111 LEA R14,[RSP + 0x10] MOVAPS XMM0,xmmword ptr [R14] LEA R15,[RSP + 0x20] MOVAPS xmmword ptr [R15],XMM0 MOV RDI,R14 XOR ESI,ESI CALL 0x00158ac0 MOV byte ptr [R14],0x0 MOV qword ptr [R14 + 0x8],0x0 MOV RDI,R15 MOV ESI,0x1 CALL 0x00158ac0 MOV RDI,qword ptr [RBX + 0x70] MOV RSI,R15 CALL 0x0015b45c MOV RDI,R15 XOR ESI,ESI CALL 0x00158ac0 MOV RDI,R15 CALL 0x0015e2ac MOV R14,qword ptr [RBX + 0x70] LAB_0016108c: MOV BL,0x1 JMP 0x00161095 LAB_00161090: XOR EBX,EBX XOR R14D,R14D LAB_00161095: LEA R15,[RSP + 0x10] MOV RDI,R15 XOR ESI,ESI CALL 0x00158ac0 MOV RDI,R15 CALL 0x0015e2ac LAB_001610ac: MOV EAX,EBX MOV RDX,R14 ADD RSP,0x48 POP RBX POP R14 POP R15 POP RBP RET LAB_001610bc: LEA RDI,[0x1eedc9] LEA RDX,[0x1e920a] LEA RCX,[0x1efd2e] MOV ESI,0x1c28 XOR EAX,EAX CALL 0x0011bec0 LAB_001610dd: CALL 0x0011b330 LAB_001610e2: LEA RCX,[0x1efd42] MOV ESI,0x1c4b JMP 0x001610fc LAB_001610f0: LEA RCX,[0x1efd80] MOV ESI,0x1c57 LAB_001610fc: LEA RDI,[0x1eedc9] LEA RDX,[0x1e920a] XOR EAX,EAX CALL 0x0011bec0 LAB_00161111: LEA RDI,[0x1eedc9] LEA RDX,[0x1e920a] LEA RCX,[0x1efd98] MOV ESI,0x1c60 XOR EAX,EAX CALL 0x0011bec0
/* std::pair<bool, 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::json_sax_dom_callback_parser<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> >::handle_value<unsigned long&>(unsigned long&, bool) */ int1 [16] __thiscall nlohmann::json_abi_v3_11_3::detail:: json_sax_dom_callback_parser<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>> ::handle_value<unsigned_long&> (json_sax_dom_callback_parser<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,ulong *param_1,bool param_2) { uint uVar1; char cVar2; ulong uVar3; char *pcVar4; ulong uVar5; int8 uVar6; bool bVar7; long lVar8; int1 auVar9 [16]; int1 local_5d; int4 local_5c; ulong local_58; int8 uStack_50; ulong local_48; int8 uStack_40; ulong local_38; int8 uStack_30; uVar1 = *(uint *)(this + 0x38); if (uVar1 == 0 && *(long *)(this + 0x20) == *(long *)(this + 0x30)) { /* WARNING: Subroutine does not return */ ggml_abort("/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",0x1c28, "GGML_ASSERT(%s) failed","!keep_stack.empty()"); } uVar5 = (ulong)uVar1 - 1; uVar3 = (ulong)uVar1 + 0x3e; if (-1 < (long)uVar5) { uVar3 = uVar5; } if ((*(ulong *)(*(long *)(this + 0x30) + ((long)uVar3 >> 6) * 8 + -8 + (ulong)((uVar5 & 0x800000000000003f) < 0x8000000000000001) * 8) >> (uVar5 & 0x3f) & 1) == 0) { uVar5 = 0; lVar8 = 0; goto LAB_001610ac; } local_58 = 0; uStack_50 = 0; external_constructor<(nlohmann::json_abi_v3_11_3::detail::value_t)6>:: construct<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_58,*param_1); 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> ::assert_invariant(SUB81(&local_58,0)); if (param_2) { LAB_00160efc: if (*(long *)(this + 8) == *(long *)(this + 0x10)) { local_38 = local_58; uStack_30 = uStack_50; 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> ::assert_invariant(SUB81(&local_58,0)); local_58 = local_58 & 0xffffffffffffff00; uStack_50 = 0; bVar7 = SUB81((data *)&local_38,0); 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> ::assert_invariant(bVar7); 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=(*(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,(data *)&local_38); 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> ::assert_invariant(bVar7); 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> ::data::~data((data *)&local_38); lVar8 = *(long *)this; } else { pcVar4 = *(char **)(*(long *)(this + 0x10) + -8); if (pcVar4 == (char *)0x0) goto LAB_00161090; if (*pcVar4 == '\x01') { lVar8 = *(long *)(this + 0x58); uVar1 = *(uint *)(this + 0x60); if (uVar1 == 0 && *(long *)(this + 0x48) == lVar8) { pcVar4 = "!key_keep_stack.empty()"; uVar6 = 0x1c57; goto LAB_001610fc; } uVar5 = (ulong)uVar1 - 1; uVar3 = (ulong)uVar1 + 0x3e; if (-1 < (long)uVar5) { uVar3 = uVar5; } uVar3 = *(ulong *)(lVar8 + ((long)uVar3 >> 6) * 8 + -8 + (ulong)((uVar5 & 0x800000000000003f) < 0x8000000000000001) * 8); *(uint *)(this + 0x60) = uVar1 - 1; if (uVar1 == 0) { *(int4 *)(this + 0x60) = 0x3f; *(long *)(this + 0x58) = lVar8 + -8; } if ((1L << ((byte)uVar5 & 0x3f) & uVar3) == 0) goto LAB_00161090; if (*(long *)(this + 0x70) == 0) { /* try { // try from 00161111 to 00161131 has its CatchHandler @ 00161132 */ /* WARNING: Subroutine does not return */ ggml_abort("/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp", 0x1c60,"GGML_ASSERT(%s) failed","object_element"); } local_48 = local_58; uStack_40 = uStack_50; 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> ::assert_invariant(SUB81(&local_58,0)); local_58 = local_58 & 0xffffffffffffff00; uStack_50 = 0; bVar7 = SUB81((data *)&local_48,0); 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> ::assert_invariant(bVar7); 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=(*(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 + 0x70),(data *)&local_48); 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> ::assert_invariant(bVar7); 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> ::data::~data((data *)&local_48); lVar8 = *(long *)(this + 0x70); } else { if (*pcVar4 != '\x02') { pcVar4 = "ref_stack.back()->is_array() || ref_stack.back()->is_object()"; uVar6 = 0x1c4b; LAB_001610fc: /* WARNING: Subroutine does not return */ ggml_abort("/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp", uVar6,"GGML_ASSERT(%s) failed",pcVar4); } std:: vector<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<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<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<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<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>>> **)(pcVar4 + 8),(basic_json *)&local_58); lVar8 = *(long *)(*(long *)(*(long *)(*(long *)(this + 0x10) + -8) + 8) + 8) + -0x10; } } uVar5 = CONCAT71((int7)((ulong)this >> 8),1); } else { local_5c = (int4)((ulong)(*(long *)(this + 0x10) - *(long *)(this + 8)) >> 3); local_5d = 5; if (*(long *)(this + 0x90) == 0) { /* WARNING: Subroutine does not return */ /* try { // try from 001610dd to 00161110 has its CatchHandler @ 00161134 */ std::__throw_bad_function_call(); } /* try { // try from 00160edf to 00160f35 has its CatchHandler @ 00161134 */ cVar2 = (**(code **)(this + 0x98))(this + 0x80,&local_5c,&local_5d,&local_58); if (cVar2 != '\0') goto LAB_00160efc; LAB_00161090: uVar5 = 0; lVar8 = 0; } 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> ::assert_invariant(SUB81((data *)&local_58,0)); 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> ::data::~data((data *)&local_58); LAB_001610ac: auVar9._0_8_ = uVar5 & 0xffffffff; auVar9._8_8_ = lVar8; return auVar9; }
47,418
std::pair<bool, 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::json_sax_dom_callback_parser<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>>::handle_value<bool&>(bool&, bool)
monkey531[P]llama/common/json.hpp
std::pair<bool, BasicJsonType*> handle_value(Value&& v, const bool skip_callback = false) { JSON_ASSERT(!keep_stack.empty()); // do not handle this value if we know it would be added to a discarded // container if (!keep_stack.back()) { return {false, nullptr}; } // create value auto value = BasicJsonType(std::forward<Value>(v)); // check callback const bool keep = skip_callback || callback(static_cast<int>(ref_stack.size()), parse_event_t::value, value); // do not handle this value if we just learnt it shall be discarded if (!keep) { return {false, nullptr}; } if (ref_stack.empty()) { root = std::move(value); return {true, & root}; } // skip this value if we already decided to skip the parent // (https://github.com/nlohmann/json/issues/971#issuecomment-413678360) if (!ref_stack.back()) { return {false, nullptr}; } // we now only expect arrays and objects JSON_ASSERT(ref_stack.back()->is_array() || ref_stack.back()->is_object()); // array if (ref_stack.back()->is_array()) { ref_stack.back()->m_data.m_value.array->emplace_back(std::move(value)); return {true, & (ref_stack.back()->m_data.m_value.array->back())}; } // object JSON_ASSERT(ref_stack.back()->is_object()); // check if we should store an element for the current key JSON_ASSERT(!key_keep_stack.empty()); const bool store_element = key_keep_stack.back(); key_keep_stack.pop_back(); if (!store_element) { return {false, nullptr}; } JSON_ASSERT(object_element); *object_element = std::move(value); return {true, object_element}; }
O3
cpp
std::pair<bool, 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::json_sax_dom_callback_parser<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>>::handle_value<bool&>(bool&, bool): pushq %rbp pushq %r15 pushq %r14 pushq %rbx subq $0x48, %rsp movl %edx, %ebp movq %rdi, %rbx movq 0x30(%rdi), %rax movl 0x38(%rdi), %ecx cmpq %rax, 0x20(%rdi) sete %dl testl %ecx, %ecx sete %dil andb %dl, %dil cmpb $0x1, %dil je 0x6010c movl %ecx, %ecx movabsq $-0x8000000000000000, %r15 # imm = 0x8000000000000000 leaq -0x1(%rcx), %rdx addq $0x3e, %rcx testq %rdx, %rdx cmovnsq %rdx, %rcx sarq $0x6, %rcx leaq (%rax,%rcx,8), %rax leaq 0x3f(%r15), %rcx andq %rdx, %rcx xorl %edi, %edi cmpq %r15, %rcx setbe %dil movq -0x8(%rax,%rdi,8), %rax btq %rdx, %rax jae 0x5ff9f xorps %xmm0, %xmm0 leaq 0x10(%rsp), %r14 movaps %xmm0, (%r14) movq (%rsi), %rsi movq %r14, %rdi callq 0x601a6 movq %r14, %rdi movl $0x1, %esi callq 0x58484 testb %bpl, %bpl jne 0x5ff4c movq 0x10(%rbx), %rax subq 0x8(%rbx), %rax shrq $0x3, %rax movl %eax, 0xc(%rsp) movb $0x5, 0xb(%rsp) cmpq $0x0, 0x90(%rbx) je 0x6012d leaq 0x80(%rbx), %rdi leaq 0xc(%rsp), %rsi leaq 0xb(%rsp), %rdx leaq 0x10(%rsp), %rcx callq *0x98(%rbx) testb %al, %al je 0x600e0 movq 0x10(%rbx), %rax cmpq %rax, 0x8(%rbx) je 0x5ffa9 movq -0x8(%rax), %rax testq %rax, %rax je 0x600e0 movzbl (%rax), %ecx cmpl $0x1, %ecx je 0x60003 cmpl $0x2, %ecx jne 0x60132 movq 0x8(%rax), %rdi leaq 0x10(%rsp), %rsi callq 0x5d046 movq 0x10(%rbx), %rax movq -0x8(%rax), %rax movq 0x8(%rax), %rax movq 0x8(%rax), %r14 addq $-0x10, %r14 jmp 0x600dc xorl %ebx, %ebx xorl %r14d, %r14d jmp 0x600fc leaq 0x10(%rsp), %r14 movaps (%r14), %xmm0 leaq 0x30(%rsp), %r15 movaps %xmm0, (%r15) movq %r14, %rdi xorl %esi, %esi callq 0x58484 movb $0x0, (%r14) movq $0x0, 0x8(%r14) movq %r15, %rdi movl $0x1, %esi callq 0x58484 movq (%rbx), %rdi movq %r15, %rsi callq 0x5ac26 movq %r15, %rdi xorl %esi, %esi callq 0x58484 movq %r15, %rdi callq 0x5d972 movq (%rbx), %r14 jmp 0x600dc movq 0x58(%rbx), %rax movl 0x60(%rbx), %ecx cmpq %rax, 0x48(%rbx) sete %dl testl %ecx, %ecx sete %sil andb %dl, %sil cmpb $0x1, %sil je 0x60140 movl %ecx, %esi leaq -0x1(%rsi), %rcx movq %rsi, %rdx addq $0x3e, %rdx testq %rcx, %rcx cmovnsq %rcx, %rdx sarq $0x6, %rdx leaq (%rax,%rdx,8), %rdi leaq 0x3f(%r15), %rdx andq %rcx, %rdx xorl %r8d, %r8d cmpq %r15, %rdx setbe %r8b movl $0x1, %edx shlq %cl, %rdx andq -0x8(%rdi,%r8,8), %rdx subl $0x1, %esi movl %esi, 0x60(%rbx) jae 0x60075 movl $0x3f, 0x60(%rbx) addq $-0x8, %rax movq %rax, 0x58(%rbx) testq %rdx, %rdx je 0x600e0 cmpq $0x0, 0x70(%rbx) je 0x60161 leaq 0x10(%rsp), %r14 movaps (%r14), %xmm0 leaq 0x20(%rsp), %r15 movaps %xmm0, (%r15) movq %r14, %rdi xorl %esi, %esi callq 0x58484 movb $0x0, (%r14) movq $0x0, 0x8(%r14) movq %r15, %rdi movl $0x1, %esi callq 0x58484 movq 0x70(%rbx), %rdi movq %r15, %rsi callq 0x5ac26 movq %r15, %rdi xorl %esi, %esi callq 0x58484 movq %r15, %rdi callq 0x5d972 movq 0x70(%rbx), %r14 movb $0x1, %bl jmp 0x600e5 xorl %ebx, %ebx xorl %r14d, %r14d leaq 0x10(%rsp), %r15 movq %r15, %rdi xorl %esi, %esi callq 0x58484 movq %r15, %rdi callq 0x5d972 movl %ebx, %eax movq %r14, %rdx addq $0x48, %rsp popq %rbx popq %r14 popq %r15 popq %rbp retq leaq 0x8bcb6(%rip), %rdi # 0xebdc9 leaq 0x860f0(%rip), %rdx # 0xe620a leaq 0x8cc0d(%rip), %rcx # 0xecd2e movl $0x1c28, %esi # imm = 0x1C28 xorl %eax, %eax callq 0x1aec0 callq 0x1a330 leaq 0x8cc09(%rip), %rcx # 0xecd42 movl $0x1c4b, %esi # imm = 0x1C4B jmp 0x6014c leaq 0x8cc39(%rip), %rcx # 0xecd80 movl $0x1c57, %esi # imm = 0x1C57 leaq 0x8bc76(%rip), %rdi # 0xebdc9 leaq 0x860b0(%rip), %rdx # 0xe620a xorl %eax, %eax callq 0x1aec0 leaq 0x8bc61(%rip), %rdi # 0xebdc9 leaq 0x8609b(%rip), %rdx # 0xe620a leaq 0x8cc22(%rip), %rcx # 0xecd98 movl $0x1c60, %esi # imm = 0x1C60 xorl %eax, %eax callq 0x1aec0 jmp 0x60184 movq %rax, %rbx leaq 0x10(%rsp), %r14 movq %r14, %rdi xorl %esi, %esi callq 0x58484 movq %r14, %rdi callq 0x5d972 movq %rbx, %rdi callq 0x1afd0
_ZN8nlohmann16json_abi_v3_11_36detail28json_sax_dom_callback_parserINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12handle_valueIRlEESt4pairIbPSF_EOT_b: push rbp push r15 push r14 push rbx sub rsp, 48h mov ebp, edx mov rbx, rdi mov rax, [rdi+30h] mov ecx, [rdi+38h] cmp [rdi+20h], rax setz dl test ecx, ecx setz dil and dil, dl cmp dil, 1 jz loc_6010C mov ecx, ecx mov r15, 8000000000000000h lea rdx, [rcx-1] add rcx, 3Eh ; '>' test rdx, rdx cmovns rcx, rdx sar rcx, 6 lea rax, [rax+rcx*8] lea rcx, [r15+3Fh] and rcx, rdx xor edi, edi cmp rcx, r15 setbe dil mov rax, [rax+rdi*8-8] bt rax, rdx jnb loc_5FF9F xorps xmm0, xmm0 lea r14, [rsp+68h+var_58] movaps xmmword ptr [r14], xmm0 mov rsi, [rsi] mov rdi, r14 call _ZN8nlohmann16json_abi_v3_11_36detail20external_constructorILNS1_7value_tE5EE9constructINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES8_IhSaIhEEvEEEEvRT_NSJ_16number_integer_tE; nlohmann::json_abi_v3_11_3::detail::external_constructor<(nlohmann::json_abi_v3_11_3::detail::value_t)5>::construct<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>>(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> &,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>::number_integer_t) mov rdi, r14 mov esi, 1 call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; 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>::assert_invariant(bool) test bpl, bpl jnz short loc_5FF4C mov rax, [rbx+10h] sub rax, [rbx+8] shr rax, 3 mov [rsp+68h+var_5C], eax mov [rsp+68h+var_5D], 5 cmp qword ptr [rbx+90h], 0 jz loc_6012D lea rdi, [rbx+80h] lea rsi, [rsp+68h+var_5C] lea rdx, [rsp+68h+var_5D] lea rcx, [rsp+68h+var_58] call qword ptr [rbx+98h] test al, al jz loc_600E0 loc_5FF4C: mov rax, [rbx+10h] cmp [rbx+8], rax jz short loc_5FFA9 mov rax, [rax-8] test rax, rax jz loc_600E0 movzx ecx, byte ptr [rax] cmp ecx, 1 jz loc_60003 cmp ecx, 2 jnz loc_60132 mov rdi, [rax+8] lea rsi, [rsp+68h+var_58] call _ZNSt6vectorIN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapES_NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES_IhSaIhEEvEESaISD_EE12emplace_backIJSD_EEERSD_DpOT_; std::vector<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<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>>(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 rax, [rbx+10h] mov rax, [rax-8] mov rax, [rax+8] mov r14, [rax+8] add r14, 0FFFFFFFFFFFFFFF0h jmp loc_600DC loc_5FF9F: xor ebx, ebx xor r14d, r14d jmp loc_600FC loc_5FFA9: lea r14, [rsp+68h+var_58] movaps xmm0, xmmword ptr [r14] lea r15, [rsp+68h+var_38] movaps xmmword ptr [r15], xmm0 mov rdi, r14 xor esi, esi call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; 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>::assert_invariant(bool) mov byte ptr [r14], 0 mov qword ptr [r14+8], 0 mov rdi, r15 mov esi, 1 call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; 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>::assert_invariant(bool) mov rdi, [rbx] mov rsi, r15 call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEaSESD_; 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=(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, r15 xor esi, esi call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; 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>::assert_invariant(bool) mov rdi, r15 call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE4dataD2Ev; 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>::data::~data() mov r14, [rbx] jmp loc_600DC loc_60003: mov rax, [rbx+58h] mov ecx, [rbx+60h] cmp [rbx+48h], rax setz dl test ecx, ecx setz sil and sil, dl cmp sil, 1 jz loc_60140 mov esi, ecx lea rcx, [rsi-1] mov rdx, rsi add rdx, 3Eh ; '>' test rcx, rcx cmovns rdx, rcx sar rdx, 6 lea rdi, [rax+rdx*8] lea rdx, [r15+3Fh] and rdx, rcx xor r8d, r8d cmp rdx, r15 setbe r8b mov edx, 1 shl rdx, cl and rdx, [rdi+r8*8-8] sub esi, 1 mov [rbx+60h], esi jnb short loc_60075 mov dword ptr [rbx+60h], 3Fh ; '?' add rax, 0FFFFFFFFFFFFFFF8h mov [rbx+58h], rax loc_60075: test rdx, rdx jz short loc_600E0 cmp qword ptr [rbx+70h], 0 jz loc_60161 lea r14, [rsp+68h+var_58] movaps xmm0, xmmword ptr [r14] lea r15, [rsp+68h+var_48] movaps xmmword ptr [r15], xmm0 mov rdi, r14 xor esi, esi call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; 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>::assert_invariant(bool) mov byte ptr [r14], 0 mov qword ptr [r14+8], 0 mov rdi, r15 mov esi, 1 call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; 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>::assert_invariant(bool) mov rdi, [rbx+70h] mov rsi, r15 call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEaSESD_; 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=(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, r15 xor esi, esi call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; 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>::assert_invariant(bool) mov rdi, r15 call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE4dataD2Ev; 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>::data::~data() mov r14, [rbx+70h] loc_600DC: mov bl, 1 jmp short loc_600E5 loc_600E0: xor ebx, ebx xor r14d, r14d loc_600E5: lea r15, [rsp+68h+var_58] mov rdi, r15 xor esi, esi call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; 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>::assert_invariant(bool) mov rdi, r15 call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE4dataD2Ev; 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>::data::~data() loc_600FC: mov eax, ebx mov rdx, r14 add rsp, 48h pop rbx pop r14 pop r15 pop rbp retn loc_6010C: lea rdi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github/2025_star3"... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aKeepStackEmpty; "!keep_stack.empty()" mov esi, 1C28h xor eax, eax call _ggml_abort loc_6012D: call __ZSt25__throw_bad_function_callv; std::__throw_bad_function_call(void) loc_60132: lea rcx, aRefStackBackIs; "ref_stack.back()->is_array() || ref_sta"... mov esi, 1C4Bh jmp short loc_6014C loc_60140: lea rcx, aKeyKeepStackEm; "!key_keep_stack.empty()" mov esi, 1C57h loc_6014C: lea rdi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github/2025_star3"... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" xor eax, eax call _ggml_abort loc_60161: lea rdi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github/2025_star3"... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aObjectElement; "object_element" mov esi, 1C60h xor eax, eax call _ggml_abort jmp short $+2 loc_60184: mov rbx, rax lea r14, [rsp+68h+var_58] mov rdi, r14 xor esi, esi call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; 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>::assert_invariant(bool) mov rdi, r14 call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE4dataD2Ev; 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>::data::~data() mov rdi, rbx call __Unwind_Resume
long long nlohmann::json_abi_v3_11_3::detail::json_sax_dom_callback_parser<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>>::handle_value<long &>( long long a1, _QWORD *a2, char a3) { unsigned int v4; // ebx long long v5; // rax unsigned int v6; // ecx signed long long v7; // rdx long long v8; // rcx long long v9; // rax long long v10; // rax unsigned __int8 *v11; // rax int v12; // ecx long long v13; // rax unsigned int v14; // ecx long long v15; // rsi long long v16; // rcx long long v17; // rdx long long v18; // rdx const char *v20; // rcx long long v21; // rsi long long v22; // rbx char v23; // [rsp+Bh] [rbp-5Dh] BYREF int v24; // [rsp+Ch] [rbp-5Ch] BYREF __int128 v25; // [rsp+10h] [rbp-58h] BYREF __int128 v26; // [rsp+20h] [rbp-48h] BYREF _OWORD v27[3]; // [rsp+30h] [rbp-38h] BYREF v4 = a1; v5 = *(_QWORD *)(a1 + 48); v6 = *(_DWORD *)(a1 + 56); if ( *(_QWORD *)(a1 + 32) == v5 && v6 == 0 ) { ggml_abort( "/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp", 7208LL, "GGML_ASSERT(%s) failed", "!keep_stack.empty()"); goto LABEL_28; } v7 = v6 - 1LL; v8 = v6 + 62LL; if ( v7 >= 0 ) v8 = v7; v9 = *(_QWORD *)(v5 + 8 * (v8 >> 6) + 8LL * ((v7 & 0x800000000000003FLL) <= 0x8000000000000000LL) - 8); if ( _bittest64(&v9, v7) ) { v25 = 0LL; nlohmann::json_abi_v3_11_3::detail::external_constructor<(nlohmann::json_abi_v3_11_3::detail::value_t)5>::construct<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>>( &v25, *a2); 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>::assert_invariant((char *)&v25); if ( a3 ) { LABEL_8: v10 = *(_QWORD *)(a1 + 16); if ( *(_QWORD *)(a1 + 8) == v10 ) { v27[0] = v25; 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>::assert_invariant((char *)&v25); LOBYTE(v25) = 0; *((_QWORD *)&v25 + 1) = 0LL; 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>::assert_invariant((char *)v27); 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=( *(_QWORD *)a1, (long long)v27); 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>::assert_invariant((char *)v27); 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>::data::~data(v27); goto LABEL_23; } v11 = *(unsigned __int8 **)(v10 - 8); if ( v11 ) { v12 = *v11; if ( v12 != 1 ) { if ( v12 == 2 ) { std::vector<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<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>>( *((_QWORD *)v11 + 1), (long long)&v25); LABEL_23: LOBYTE(v4) = 1; LABEL_25: 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>::assert_invariant((char *)&v25); 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>::data::~data(&v25); return v4; } v20 = "ref_stack.back()->is_array() || ref_stack.back()->is_object()"; v21 = 7243LL; goto LABEL_31; } v13 = *(_QWORD *)(a1 + 88); v14 = *(_DWORD *)(a1 + 96); if ( *(_QWORD *)(a1 + 72) == v13 && v14 == 0 ) { v20 = "!key_keep_stack.empty()"; v21 = 7255LL; LABEL_31: ggml_abort( "/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp", v21, "GGML_ASSERT(%s) failed", v20); goto LABEL_32; } v15 = v14; v16 = v14 - 1LL; v17 = v15 + 62; if ( v16 >= 0 ) v17 = v16; v18 = *(_QWORD *)(v13 + 8 * (v17 >> 6) + 8LL * ((v16 & 0x800000000000003FLL) <= 0x8000000000000000LL) - 8) & (1LL << v16); *(_DWORD *)(a1 + 96) = v15 - 1; if ( !(_DWORD)v15 ) { *(_DWORD *)(a1 + 96) = 63; *(_QWORD *)(a1 + 88) = v13 - 8; } if ( v18 ) { if ( *(_QWORD *)(a1 + 112) ) { v26 = v25; 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>::assert_invariant((char *)&v25); LOBYTE(v25) = 0; *((_QWORD *)&v25 + 1) = 0LL; 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>::assert_invariant((char *)&v26); 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=( *(_QWORD *)(a1 + 112), (long long)&v26); 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>::assert_invariant((char *)&v26); 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>::data::~data(&v26); goto LABEL_23; } LABEL_32: v22 = ggml_abort( "/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp", 7264LL, "GGML_ASSERT(%s) failed", "object_element"); 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>::assert_invariant((char *)&v25); 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>::data::~data(&v25); _Unwind_Resume(v22); } } LABEL_24: v4 = 0; goto LABEL_25; } v24 = (*(_QWORD *)(a1 + 16) - *(_QWORD *)(a1 + 8)) >> 3; v23 = 5; if ( *(_QWORD *)(a1 + 144) ) { if ( !(*(unsigned __int8 ( **)(long long, int *, char *, __int128 *))(a1 + 152))( a1 + 128, &v24, &v23, &v25) ) goto LABEL_24; goto LABEL_8; } LABEL_28: std::__throw_bad_function_call(); } return 0; }
handle_value<long&>: PUSH RBP PUSH R15 PUSH R14 PUSH RBX SUB RSP,0x48 MOV EBP,EDX MOV RBX,RDI MOV RAX,qword ptr [RDI + 0x30] MOV ECX,dword ptr [RDI + 0x38] CMP qword ptr [RDI + 0x20],RAX SETZ DL TEST ECX,ECX SETZ DIL AND DIL,DL CMP DIL,0x1 JZ 0x0016010c MOV ECX,ECX MOV R15,-0x8000000000000000 LEA RDX,[RCX + -0x1] ADD RCX,0x3e TEST RDX,RDX CMOVNS RCX,RDX SAR RCX,0x6 LEA RAX,[RAX + RCX*0x8] LEA RCX,[R15 + 0x3f] AND RCX,RDX XOR EDI,EDI CMP RCX,R15 SETBE DIL MOV RAX,qword ptr [RAX + RDI*0x8 + -0x8] BT RAX,RDX JNC 0x0015ff9f XORPS XMM0,XMM0 LEA R14,[RSP + 0x10] MOVAPS xmmword ptr [R14],XMM0 MOV RSI,qword ptr [RSI] MOV RDI,R14 CALL 0x001601a6 MOV RDI,R14 MOV ESI,0x1 CALL 0x00158484 TEST BPL,BPL JNZ 0x0015ff4c MOV RAX,qword ptr [RBX + 0x10] SUB RAX,qword ptr [RBX + 0x8] SHR RAX,0x3 MOV dword ptr [RSP + 0xc],EAX MOV byte ptr [RSP + 0xb],0x5 CMP qword ptr [RBX + 0x90],0x0 JZ 0x0016012d LEA RDI,[RBX + 0x80] LAB_0015ff2f: LEA RSI,[RSP + 0xc] LEA RDX,[RSP + 0xb] LEA RCX,[RSP + 0x10] CALL qword ptr [RBX + 0x98] TEST AL,AL JZ 0x001600e0 LAB_0015ff4c: MOV RAX,qword ptr [RBX + 0x10] CMP qword ptr [RBX + 0x8],RAX JZ 0x0015ffa9 MOV RAX,qword ptr [RAX + -0x8] TEST RAX,RAX JZ 0x001600e0 MOVZX ECX,byte ptr [RAX] CMP ECX,0x1 JZ 0x00160003 CMP ECX,0x2 JNZ 0x00160132 MOV RDI,qword ptr [RAX + 0x8] LEA RSI,[RSP + 0x10] CALL 0x0015d046 LAB_0015ff86: MOV RAX,qword ptr [RBX + 0x10] MOV RAX,qword ptr [RAX + -0x8] MOV RAX,qword ptr [RAX + 0x8] MOV R14,qword ptr [RAX + 0x8] ADD R14,-0x10 JMP 0x001600dc LAB_0015ff9f: XOR EBX,EBX XOR R14D,R14D JMP 0x001600fc LAB_0015ffa9: LEA R14,[RSP + 0x10] MOVAPS XMM0,xmmword ptr [R14] LEA R15,[RSP + 0x30] MOVAPS xmmword ptr [R15],XMM0 MOV RDI,R14 XOR ESI,ESI CALL 0x00158484 MOV byte ptr [R14],0x0 MOV qword ptr [R14 + 0x8],0x0 MOV RDI,R15 MOV ESI,0x1 CALL 0x00158484 MOV RDI,qword ptr [RBX] MOV RSI,R15 CALL 0x0015ac26 MOV RDI,R15 XOR ESI,ESI CALL 0x00158484 MOV RDI,R15 CALL 0x0015d972 MOV R14,qword ptr [RBX] JMP 0x001600dc LAB_00160003: MOV RAX,qword ptr [RBX + 0x58] MOV ECX,dword ptr [RBX + 0x60] CMP qword ptr [RBX + 0x48],RAX SETZ DL TEST ECX,ECX SETZ SIL AND SIL,DL CMP SIL,0x1 JZ 0x00160140 MOV ESI,ECX LEA RCX,[RSI + -0x1] MOV RDX,RSI ADD RDX,0x3e TEST RCX,RCX CMOVNS RDX,RCX SAR RDX,0x6 LEA RDI,[RAX + RDX*0x8] LEA RDX,[R15 + 0x3f] AND RDX,RCX XOR R8D,R8D CMP RDX,R15 SETBE R8B MOV EDX,0x1 SHL RDX,CL AND RDX,qword ptr [RDI + R8*0x8 + -0x8] SUB ESI,0x1 MOV dword ptr [RBX + 0x60],ESI JNC 0x00160075 MOV dword ptr [RBX + 0x60],0x3f ADD RAX,-0x8 MOV qword ptr [RBX + 0x58],RAX LAB_00160075: TEST RDX,RDX JZ 0x001600e0 CMP qword ptr [RBX + 0x70],0x0 JZ 0x00160161 LEA R14,[RSP + 0x10] MOVAPS XMM0,xmmword ptr [R14] LEA R15,[RSP + 0x20] MOVAPS xmmword ptr [R15],XMM0 MOV RDI,R14 XOR ESI,ESI CALL 0x00158484 MOV byte ptr [R14],0x0 MOV qword ptr [R14 + 0x8],0x0 MOV RDI,R15 MOV ESI,0x1 CALL 0x00158484 MOV RDI,qword ptr [RBX + 0x70] MOV RSI,R15 CALL 0x0015ac26 MOV RDI,R15 XOR ESI,ESI CALL 0x00158484 MOV RDI,R15 CALL 0x0015d972 MOV R14,qword ptr [RBX + 0x70] LAB_001600dc: MOV BL,0x1 JMP 0x001600e5 LAB_001600e0: XOR EBX,EBX XOR R14D,R14D LAB_001600e5: LEA R15,[RSP + 0x10] MOV RDI,R15 XOR ESI,ESI CALL 0x00158484 MOV RDI,R15 CALL 0x0015d972 LAB_001600fc: MOV EAX,EBX MOV RDX,R14 ADD RSP,0x48 POP RBX POP R14 POP R15 POP RBP RET LAB_0016010c: LEA RDI,[0x1ebdc9] LEA RDX,[0x1e620a] LEA RCX,[0x1ecd2e] MOV ESI,0x1c28 XOR EAX,EAX CALL 0x0011aec0 LAB_0016012d: CALL 0x0011a330 LAB_00160132: LEA RCX,[0x1ecd42] MOV ESI,0x1c4b JMP 0x0016014c LAB_00160140: LEA RCX,[0x1ecd80] MOV ESI,0x1c57 LAB_0016014c: LEA RDI,[0x1ebdc9] LEA RDX,[0x1e620a] XOR EAX,EAX CALL 0x0011aec0 LAB_00160161: LEA RDI,[0x1ebdc9] LEA RDX,[0x1e620a] LEA RCX,[0x1ecd98] MOV ESI,0x1c60 XOR EAX,EAX CALL 0x0011aec0
/* std::pair<bool, 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::json_sax_dom_callback_parser<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> >::handle_value<long&>(long&, bool) */ int1 [16] __thiscall nlohmann::json_abi_v3_11_3::detail:: json_sax_dom_callback_parser<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>> ::handle_value<long&> (json_sax_dom_callback_parser<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,long *param_1,bool param_2) { uint uVar1; char cVar2; ulong uVar3; char *pcVar4; ulong uVar5; int8 uVar6; bool bVar7; long lVar8; int1 auVar9 [16]; int1 local_5d; int4 local_5c; ulong local_58; int8 uStack_50; ulong local_48; int8 uStack_40; ulong local_38; int8 uStack_30; uVar1 = *(uint *)(this + 0x38); if (uVar1 == 0 && *(long *)(this + 0x20) == *(long *)(this + 0x30)) { /* WARNING: Subroutine does not return */ ggml_abort("/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",0x1c28, "GGML_ASSERT(%s) failed","!keep_stack.empty()"); } uVar5 = (ulong)uVar1 - 1; uVar3 = (ulong)uVar1 + 0x3e; if (-1 < (long)uVar5) { uVar3 = uVar5; } if ((*(ulong *)(*(long *)(this + 0x30) + ((long)uVar3 >> 6) * 8 + -8 + (ulong)((uVar5 & 0x800000000000003f) < 0x8000000000000001) * 8) >> (uVar5 & 0x3f) & 1) == 0) { uVar5 = 0; lVar8 = 0; goto LAB_001600fc; } local_58 = 0; uStack_50 = 0; external_constructor<(nlohmann::json_abi_v3_11_3::detail::value_t)5>:: construct<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_58,*param_1); 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> ::assert_invariant(SUB81(&local_58,0)); if (param_2) { LAB_0015ff4c: if (*(long *)(this + 8) == *(long *)(this + 0x10)) { local_38 = local_58; uStack_30 = uStack_50; 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> ::assert_invariant(SUB81(&local_58,0)); local_58 = local_58 & 0xffffffffffffff00; uStack_50 = 0; bVar7 = SUB81((data *)&local_38,0); 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> ::assert_invariant(bVar7); 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=(*(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,(data *)&local_38); 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> ::assert_invariant(bVar7); 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> ::data::~data((data *)&local_38); lVar8 = *(long *)this; } else { pcVar4 = *(char **)(*(long *)(this + 0x10) + -8); if (pcVar4 == (char *)0x0) goto LAB_001600e0; if (*pcVar4 == '\x01') { lVar8 = *(long *)(this + 0x58); uVar1 = *(uint *)(this + 0x60); if (uVar1 == 0 && *(long *)(this + 0x48) == lVar8) { pcVar4 = "!key_keep_stack.empty()"; uVar6 = 0x1c57; goto LAB_0016014c; } uVar5 = (ulong)uVar1 - 1; uVar3 = (ulong)uVar1 + 0x3e; if (-1 < (long)uVar5) { uVar3 = uVar5; } uVar3 = *(ulong *)(lVar8 + ((long)uVar3 >> 6) * 8 + -8 + (ulong)((uVar5 & 0x800000000000003f) < 0x8000000000000001) * 8); *(uint *)(this + 0x60) = uVar1 - 1; if (uVar1 == 0) { *(int4 *)(this + 0x60) = 0x3f; *(long *)(this + 0x58) = lVar8 + -8; } if ((1L << ((byte)uVar5 & 0x3f) & uVar3) == 0) goto LAB_001600e0; if (*(long *)(this + 0x70) == 0) { /* try { // try from 00160161 to 00160181 has its CatchHandler @ 00160182 */ /* WARNING: Subroutine does not return */ ggml_abort("/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp", 0x1c60,"GGML_ASSERT(%s) failed","object_element"); } local_48 = local_58; uStack_40 = uStack_50; 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> ::assert_invariant(SUB81(&local_58,0)); local_58 = local_58 & 0xffffffffffffff00; uStack_50 = 0; bVar7 = SUB81((data *)&local_48,0); 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> ::assert_invariant(bVar7); 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=(*(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 + 0x70),(data *)&local_48); 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> ::assert_invariant(bVar7); 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> ::data::~data((data *)&local_48); lVar8 = *(long *)(this + 0x70); } else { if (*pcVar4 != '\x02') { pcVar4 = "ref_stack.back()->is_array() || ref_stack.back()->is_object()"; uVar6 = 0x1c4b; LAB_0016014c: /* WARNING: Subroutine does not return */ ggml_abort("/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp", uVar6,"GGML_ASSERT(%s) failed",pcVar4); } std:: vector<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<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<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<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<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>>> **)(pcVar4 + 8),(basic_json *)&local_58); lVar8 = *(long *)(*(long *)(*(long *)(*(long *)(this + 0x10) + -8) + 8) + 8) + -0x10; } } uVar5 = CONCAT71((int7)((ulong)this >> 8),1); } else { local_5c = (int4)((ulong)(*(long *)(this + 0x10) - *(long *)(this + 8)) >> 3); local_5d = 5; if (*(long *)(this + 0x90) == 0) { /* WARNING: Subroutine does not return */ /* try { // try from 0016012d to 00160160 has its CatchHandler @ 00160184 */ std::__throw_bad_function_call(); } /* try { // try from 0015ff2f to 0015ff85 has its CatchHandler @ 00160184 */ cVar2 = (**(code **)(this + 0x98))(this + 0x80,&local_5c,&local_5d,&local_58); if (cVar2 != '\0') goto LAB_0015ff4c; LAB_001600e0: uVar5 = 0; lVar8 = 0; } 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> ::assert_invariant(SUB81((data *)&local_58,0)); 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> ::data::~data((data *)&local_58); LAB_001600fc: auVar9._0_8_ = uVar5 & 0xffffffff; auVar9._8_8_ = lVar8; return auVar9; }
47,419
new_label_fd
bluesky950520[P]quickjs/quickjs.c
static int new_label_fd(JSFunctionDef *fd, int label) { LabelSlot *ls; if (label < 0) { if (js_resize_array(fd->ctx, (void *)&fd->label_slots, sizeof(fd->label_slots[0]), &fd->label_size, fd->label_count + 1)) return -1; label = fd->label_count++; ls = &fd->label_slots[label]; ls->ref_count = 0; ls->pos = -1; ls->pos2 = -1; ls->addr = -1; ls->first_reloc = NULL; } return label; }
O0
c
new_label_fd: subq $0x28, %rsp movq %rdi, 0x18(%rsp) movl %esi, 0x14(%rsp) cmpl $0x0, 0x14(%rsp) jge 0xb12d4 movq 0x18(%rsp), %rax movq (%rax), %rdi movq 0x18(%rsp), %rsi addq $0x170, %rsi # imm = 0x170 movq 0x18(%rsp), %rcx addq $0x178, %rcx # imm = 0x178 movq 0x18(%rsp), %rax movl 0x17c(%rax), %r8d addl $0x1, %r8d movl $0x18, %edx callq 0x73140 cmpl $0x0, %eax je 0xb1261 movl $0xffffffff, 0x24(%rsp) # imm = 0xFFFFFFFF jmp 0xb12dc movq 0x18(%rsp), %rcx movl 0x17c(%rcx), %eax movl %eax, %edx addl $0x1, %edx movl %edx, 0x17c(%rcx) movl %eax, 0x14(%rsp) movq 0x18(%rsp), %rax movq 0x170(%rax), %rax movslq 0x14(%rsp), %rcx imulq $0x18, %rcx, %rcx addq %rcx, %rax movq %rax, 0x8(%rsp) movq 0x8(%rsp), %rax movl $0x0, (%rax) movq 0x8(%rsp), %rax movl $0xffffffff, 0x4(%rax) # imm = 0xFFFFFFFF movq 0x8(%rsp), %rax movl $0xffffffff, 0x8(%rax) # imm = 0xFFFFFFFF movq 0x8(%rsp), %rax movl $0xffffffff, 0xc(%rax) # imm = 0xFFFFFFFF movq 0x8(%rsp), %rax movq $0x0, 0x10(%rax) movl 0x14(%rsp), %eax movl %eax, 0x24(%rsp) movl 0x24(%rsp), %eax addq $0x28, %rsp retq nopw %cs:(%rax,%rax)
new_label_fd: sub rsp, 28h mov [rsp+28h+var_10], rdi mov [rsp+28h+var_14], esi cmp [rsp+28h+var_14], 0 jge loc_B12D4 mov rax, [rsp+28h+var_10] mov rdi, [rax] mov rsi, [rsp+28h+var_10] add rsi, 170h mov rcx, [rsp+28h+var_10] add rcx, 178h mov rax, [rsp+28h+var_10] mov r8d, [rax+17Ch] add r8d, 1 mov edx, 18h call js_resize_array cmp eax, 0 jz short loc_B1261 mov [rsp+28h+var_4], 0FFFFFFFFh jmp short loc_B12DC loc_B1261: mov rcx, [rsp+28h+var_10] mov eax, [rcx+17Ch] mov edx, eax add edx, 1 mov [rcx+17Ch], edx mov [rsp+28h+var_14], eax mov rax, [rsp+28h+var_10] mov rax, [rax+170h] movsxd rcx, [rsp+28h+var_14] imul rcx, 18h add rax, rcx mov [rsp+28h+var_20], rax mov rax, [rsp+28h+var_20] mov dword ptr [rax], 0 mov rax, [rsp+28h+var_20] mov dword ptr [rax+4], 0FFFFFFFFh mov rax, [rsp+28h+var_20] mov dword ptr [rax+8], 0FFFFFFFFh mov rax, [rsp+28h+var_20] mov dword ptr [rax+0Ch], 0FFFFFFFFh mov rax, [rsp+28h+var_20] mov qword ptr [rax+10h], 0 loc_B12D4: mov eax, [rsp+28h+var_14] mov [rsp+28h+var_4], eax loc_B12DC: mov eax, [rsp+28h+var_4] add rsp, 28h retn
long long new_label_fd(long long a1, int a2) { signed int v2; // eax long long v4; // [rsp+8h] [rbp-20h] unsigned int v5; // [rsp+14h] [rbp-14h] v5 = a2; if ( a2 >= 0 ) return v5; if ( !(unsigned int)js_resize_array(*(_QWORD *)a1, a1 + 368, 0x18u, (_DWORD *)(a1 + 376), *(_DWORD *)(a1 + 380) + 1) ) { v2 = *(_DWORD *)(a1 + 380); *(_DWORD *)(a1 + 380) = v2 + 1; v5 = v2; v4 = 24LL * v2 + *(_QWORD *)(a1 + 368); *(_DWORD *)v4 = 0; *(_DWORD *)(v4 + 4) = -1; *(_DWORD *)(v4 + 8) = -1; *(_DWORD *)(v4 + 12) = -1; *(_QWORD *)(v4 + 16) = 0LL; return v5; } return (unsigned int)-1; }
new_label_fd: SUB RSP,0x28 MOV qword ptr [RSP + 0x18],RDI MOV dword ptr [RSP + 0x14],ESI CMP dword ptr [RSP + 0x14],0x0 JGE 0x001b12d4 MOV RAX,qword ptr [RSP + 0x18] MOV RDI,qword ptr [RAX] MOV RSI,qword ptr [RSP + 0x18] ADD RSI,0x170 MOV RCX,qword ptr [RSP + 0x18] ADD RCX,0x178 MOV RAX,qword ptr [RSP + 0x18] MOV R8D,dword ptr [RAX + 0x17c] ADD R8D,0x1 MOV EDX,0x18 CALL 0x00173140 CMP EAX,0x0 JZ 0x001b1261 MOV dword ptr [RSP + 0x24],0xffffffff JMP 0x001b12dc LAB_001b1261: MOV RCX,qword ptr [RSP + 0x18] MOV EAX,dword ptr [RCX + 0x17c] MOV EDX,EAX ADD EDX,0x1 MOV dword ptr [RCX + 0x17c],EDX MOV dword ptr [RSP + 0x14],EAX MOV RAX,qword ptr [RSP + 0x18] MOV RAX,qword ptr [RAX + 0x170] MOVSXD RCX,dword ptr [RSP + 0x14] IMUL RCX,RCX,0x18 ADD RAX,RCX MOV qword ptr [RSP + 0x8],RAX MOV RAX,qword ptr [RSP + 0x8] MOV dword ptr [RAX],0x0 MOV RAX,qword ptr [RSP + 0x8] MOV dword ptr [RAX + 0x4],0xffffffff MOV RAX,qword ptr [RSP + 0x8] MOV dword ptr [RAX + 0x8],0xffffffff MOV RAX,qword ptr [RSP + 0x8] MOV dword ptr [RAX + 0xc],0xffffffff MOV RAX,qword ptr [RSP + 0x8] MOV qword ptr [RAX + 0x10],0x0 LAB_001b12d4: MOV EAX,dword ptr [RSP + 0x14] MOV dword ptr [RSP + 0x24],EAX LAB_001b12dc: MOV EAX,dword ptr [RSP + 0x24] ADD RSP,0x28 RET
int new_label_fd(int8 *param_1,int param_2) { int iVar1; int4 *puVar2; int local_14; local_14 = param_2; if (param_2 < 0) { iVar1 = js_resize_array(*param_1,param_1 + 0x2e,0x18,param_1 + 0x2f, *(int *)((long)param_1 + 0x17c) + 1); if (iVar1 != 0) { return -1; } local_14 = *(int *)((long)param_1 + 0x17c); *(int *)((long)param_1 + 0x17c) = local_14 + 1; puVar2 = (int4 *)(param_1[0x2e] + (long)local_14 * 0x18); *puVar2 = 0; puVar2[1] = 0xffffffff; puVar2[2] = 0xffffffff; puVar2[3] = 0xffffffff; *(int8 *)(puVar2 + 4) = 0; } return local_14; }
47,420
new_label_fd
bluesky950520[P]quickjs/quickjs.c
static int new_label_fd(JSFunctionDef *fd, int label) { LabelSlot *ls; if (label < 0) { if (js_resize_array(fd->ctx, (void *)&fd->label_slots, sizeof(fd->label_slots[0]), &fd->label_size, fd->label_count + 1)) return -1; label = fd->label_count++; ls = &fd->label_slots[label]; ls->ref_count = 0; ls->pos = -1; ls->pos2 = -1; ls->addr = -1; ls->first_reloc = NULL; } return label; }
O2
c
new_label_fd: movl %esi, %eax testl %esi, %esi js 0x5b883 retq pushq %rbx movq %rdi, %rbx movq (%rdi), %rdi leaq 0x170(%rbx), %rsi leaq 0x178(%rbx), %rcx movl 0x17c(%rbx), %r8d incl %r8d pushq $0x18 popq %rdx callq 0x3b0ef testl %eax, %eax je 0x5b8b3 pushq $-0x1 popq %rax jmp 0x5b8df movslq 0x17c(%rbx), %rax leal 0x1(%rax), %ecx movl %ecx, 0x17c(%rbx) movq 0x170(%rbx), %rcx imulq $0x18, %rax, %rdx movaps 0x29eab(%rip), %xmm0 # 0x85780 movups %xmm0, (%rcx,%rdx) andq $0x0, 0x10(%rcx,%rdx) popq %rbx retq
new_label_fd: mov eax, esi test esi, esi js short loc_5B883 retn loc_5B883: push rbx mov rbx, rdi mov rdi, [rdi] lea rsi, [rbx+170h] lea rcx, [rbx+178h] mov r8d, [rbx+17Ch] inc r8d push 18h pop rdx call js_resize_array test eax, eax jz short loc_5B8B3 push 0FFFFFFFFFFFFFFFFh pop rax jmp short loc_5B8DF loc_5B8B3: movsxd rax, dword ptr [rbx+17Ch] lea ecx, [rax+1] mov [rbx+17Ch], ecx mov rcx, [rbx+170h] imul rdx, rax, 18h movaps xmm0, cs:xmmword_85780 movups xmmword ptr [rcx+rdx], xmm0 and qword ptr [rcx+rdx+10h], 0 loc_5B8DF: pop rbx retn
long long new_label_fd(long long a1, int a2) { long long result; // rax long long v3; // rcx long long v4; // rdx result = (unsigned int)a2; if ( a2 < 0 ) { if ( (unsigned int)js_resize_array(*(_QWORD *)a1, a1 + 368, 24LL, (_DWORD *)(a1 + 376), *(_DWORD *)(a1 + 380) + 1) ) { return -1LL; } else { result = *(int *)(a1 + 380); *(_DWORD *)(a1 + 380) = result + 1; v3 = *(_QWORD *)(a1 + 368); v4 = 24 * result; *(_OWORD *)(v3 + v4) = xmmword_85780; *(_QWORD *)(v3 + v4 + 16) = 0LL; } } return result; }
new_label_fd: MOV EAX,ESI TEST ESI,ESI JS 0x0015b883 RET LAB_0015b883: PUSH RBX MOV RBX,RDI MOV RDI,qword ptr [RDI] LEA RSI,[RBX + 0x170] LEA RCX,[RBX + 0x178] MOV R8D,dword ptr [RBX + 0x17c] INC R8D PUSH 0x18 POP RDX CALL 0x0013b0ef TEST EAX,EAX JZ 0x0015b8b3 PUSH -0x1 POP RAX JMP 0x0015b8df LAB_0015b8b3: MOVSXD RAX,dword ptr [RBX + 0x17c] LEA ECX,[RAX + 0x1] MOV dword ptr [RBX + 0x17c],ECX MOV RCX,qword ptr [RBX + 0x170] IMUL RDX,RAX,0x18 MOVAPS XMM0,xmmword ptr [0x00185780] MOVUPS xmmword ptr [RCX + RDX*0x1],XMM0 AND qword ptr [RCX + RDX*0x1 + 0x10],0x0 LAB_0015b8df: POP RBX RET
/* WARNING: Globals starting with '_' overlap smaller symbols at the same address */ ulong new_label_fd(int8 *param_1,uint param_2) { int8 *puVar1; long lVar2; int8 uVar3; int iVar4; ulong uVar5; if (-1 < (int)param_2) { return (ulong)param_2; } iVar4 = js_resize_array(*param_1,param_1 + 0x2e,0x18,param_1 + 0x2f, *(int *)((long)param_1 + 0x17c) + 1); if (iVar4 == 0) { uVar5 = (ulong)*(int *)((long)param_1 + 0x17c); *(int *)((long)param_1 + 0x17c) = *(int *)((long)param_1 + 0x17c) + 1; uVar3 = _UNK_00185788; lVar2 = param_1[0x2e]; puVar1 = (int8 *)(lVar2 + uVar5 * 0x18); *puVar1 = _DAT_00185780; puVar1[1] = uVar3; *(int8 *)(lVar2 + 0x10 + uVar5 * 0x18) = 0; } else { uVar5 = 0xffffffffffffffff; } return uVar5; }
47,421
compute_gradient
tsotchke[P]eshkol/src/core/utils/vector.c
VectorF* compute_gradient(Arena* arena, ScalarFieldFunc f, const VectorF* v) { assert(arena != NULL); assert(f != NULL); assert(v != NULL); // Create a result vector VectorF* result = vector_f_create(arena, v->dim); if (!result) { return NULL; } // Compute the gradient using finite differences const float h = 1e-4f; // Step size for finite differences const float f_v = f(v); // Value of f at v // For each dimension, compute the partial derivative for (size_t i = 0; i < v->dim; i++) { // Create a perturbed vector VectorF perturbed = *v; perturbed.data[i] += h; // Compute the partial derivative float f_perturbed = f(&perturbed); result->data[i] = (f_perturbed - f_v) / h; } return result; }
O0
c
compute_gradient: pushq %rbp movq %rsp, %rbp andq $-0x20, %rsp subq $0xa0, %rsp movq %rdi, 0x80(%rsp) movq %rsi, 0x78(%rsp) movq %rdx, 0x70(%rsp) cmpq $0x0, 0x80(%rsp) je 0x7e4e jmp 0x7e6d leaq 0x2380(%rip), %rdi # 0xa1d5 leaq 0x38fc(%rip), %rsi # 0xb758 movl $0x4e1, %edx # imm = 0x4E1 leaq 0x40e1(%rip), %rcx # 0xbf49 callq 0x1090 cmpq $0x0, 0x78(%rsp) je 0x7e77 jmp 0x7e96 leaq 0x2a61(%rip), %rdi # 0xa8df leaq 0x38d3(%rip), %rsi # 0xb758 movl $0x4e2, %edx # imm = 0x4E2 leaq 0x40b8(%rip), %rcx # 0xbf49 callq 0x1090 cmpq $0x0, 0x70(%rsp) je 0x7ea0 jmp 0x7ebf leaq 0x32da(%rip), %rdi # 0xb181 leaq 0x38aa(%rip), %rsi # 0xb758 movl $0x4e3, %edx # imm = 0x4E3 leaq 0x408f(%rip), %rcx # 0xbf49 callq 0x1090 movq 0x80(%rsp), %rdi movq 0x70(%rsp), %rax movq 0x10(%rax), %rsi callq 0x49a0 movq %rax, 0x68(%rsp) cmpq $0x0, 0x68(%rsp) jne 0x7ef3 movq $0x0, 0x88(%rsp) jmp 0x7fc7 movss 0x3855(%rip), %xmm0 # 0xb750 movss %xmm0, 0x64(%rsp) movq 0x78(%rsp), %rax movq 0x70(%rsp), %rdi callq *%rax movss %xmm0, 0x60(%rsp) movq $0x0, 0x58(%rsp) movq 0x58(%rsp), %rax movq 0x70(%rsp), %rcx cmpq 0x10(%rcx), %rax jae 0x7fba movq 0x70(%rsp), %rax movq (%rax), %rcx movq %rcx, 0x20(%rsp) movq 0x8(%rax), %rcx movq %rcx, 0x28(%rsp) movq 0x10(%rax), %rcx movq %rcx, 0x30(%rsp) movq 0x18(%rax), %rax movq %rax, 0x38(%rsp) movq 0x58(%rsp), %rax movss 0x37eb(%rip), %xmm0 # 0xb750 addss 0x20(%rsp,%rax,4), %xmm0 movss %xmm0, 0x20(%rsp,%rax,4) leaq 0x20(%rsp), %rdi callq *0x78(%rsp) movss %xmm0, 0x1c(%rsp) movss 0x1c(%rsp), %xmm0 subss 0x60(%rsp), %xmm0 movss 0x37bc(%rip), %xmm1 # 0xb750 divss %xmm1, %xmm0 movq 0x68(%rsp), %rax movq 0x58(%rsp), %rcx movss %xmm0, (%rax,%rcx,4) movq 0x58(%rsp), %rax addq $0x1, %rax movq %rax, 0x58(%rsp) jmp 0x7f1c movq 0x68(%rsp), %rax movq %rax, 0x88(%rsp) movq 0x88(%rsp), %rax movq %rbp, %rsp popq %rbp retq nopw %cs:(%rax,%rax)
compute_gradient: push rbp mov rbp, rsp and rsp, 0FFFFFFFFFFFFFFE0h sub rsp, 0A0h mov [rsp+0A0h+var_20], rdi mov [rsp+0A0h+var_28], rsi mov [rsp+0A0h+var_30], rdx cmp [rsp+0A0h+var_20], 0 jz short loc_7E4E jmp short loc_7E6D loc_7E4E: lea rdi, aArenaNull; "arena != NULL" lea rsi, aWorkspaceLlm4b_1; "/workspace/llm4binary/github/2025_star3"... mov edx, 4E1h lea rcx, aVectorfCompute; "VectorF *compute_gradient(Arena *, Scal"... call ___assert_fail loc_7E6D: cmp [rsp+0A0h+var_28], 0 jz short loc_7E77 jmp short loc_7E96 loc_7E77: lea rdi, aMfNull+1; "f != NULL" lea rsi, aWorkspaceLlm4b_1; "/workspace/llm4binary/github/2025_star3"... mov edx, 4E2h lea rcx, aVectorfCompute; "VectorF *compute_gradient(Arena *, Scal"... call ___assert_fail loc_7E96: cmp [rsp+0A0h+var_30], 0 jz short loc_7EA0 jmp short loc_7EBF loc_7EA0: lea rdi, aVNull; "v != NULL" lea rsi, aWorkspaceLlm4b_1; "/workspace/llm4binary/github/2025_star3"... mov edx, 4E3h lea rcx, aVectorfCompute; "VectorF *compute_gradient(Arena *, Scal"... call ___assert_fail loc_7EBF: mov rdi, [rsp+0A0h+var_20] mov rax, [rsp+0A0h+var_30] mov rsi, [rax+10h] call vector_f_create mov [rsp+0A0h+var_38], rax cmp [rsp+0A0h+var_38], 0 jnz short loc_7EF3 mov [rsp+0A0h+var_18], 0 jmp loc_7FC7 loc_7EF3: movss xmm0, cs:dword_B750 movss [rsp+0A0h+var_3C], xmm0 mov rax, [rsp+0A0h+var_28] mov rdi, [rsp+0A0h+var_30] call rax movss [rsp+0A0h+var_40], xmm0 mov [rsp+0A0h+var_48], 0 loc_7F1C: mov rax, [rsp+0A0h+var_48] mov rcx, [rsp+0A0h+var_30] cmp rax, [rcx+10h] jnb loc_7FBA mov rax, [rsp+0A0h+var_30] mov rcx, [rax] mov [rsp+0A0h+var_80], rcx mov rcx, [rax+8] mov [rsp+0A0h+var_78], rcx mov rcx, [rax+10h] mov [rsp+0A0h+var_70], rcx mov rax, [rax+18h] mov [rsp+0A0h+var_68], rax mov rax, [rsp+0A0h+var_48] movss xmm0, cs:dword_B750 addss xmm0, dword ptr [rsp+rax*4+0A0h+var_80] movss dword ptr [rsp+rax*4+0A0h+var_80], xmm0 lea rdi, [rsp+0A0h+var_80] call [rsp+0A0h+var_28] movss [rsp+0A0h+var_84], xmm0 movss xmm0, [rsp+0A0h+var_84] subss xmm0, [rsp+0A0h+var_40] movss xmm1, cs:dword_B750 divss xmm0, xmm1 mov rax, [rsp+0A0h+var_38] mov rcx, [rsp+0A0h+var_48] movss dword ptr [rax+rcx*4], xmm0 mov rax, [rsp+0A0h+var_48] add rax, 1 mov [rsp+0A0h+var_48], rax jmp loc_7F1C loc_7FBA: mov rax, [rsp+0A0h+var_38] mov [rsp+0A0h+var_18], rax loc_7FC7: mov rax, [rsp+0A0h+var_18] mov rsp, rbp pop rbp retn
long long compute_gradient(_QWORD *a1, float ( *a2)(_QWORD *), _QWORD *a3) { float v3; // xmm0_4 _QWORD v5[7]; // [rsp+20h] [rbp-80h] BYREF unsigned long long i; // [rsp+58h] [rbp-48h] float v7; // [rsp+60h] [rbp-40h] int v8; // [rsp+64h] [rbp-3Ch] long long v9; // [rsp+68h] [rbp-38h] _QWORD *v10; // [rsp+70h] [rbp-30h] float ( *v11)(_QWORD *); // [rsp+78h] [rbp-28h] _QWORD *v12; // [rsp+80h] [rbp-20h] v12 = a1; v11 = a2; v10 = a3; if ( !a1 ) __assert_fail( "arena != NULL", "/workspace/llm4binary/github/2025_star3/tsotchke[P]eshkol/src/core/utils/vector.c", 1249LL, "VectorF *compute_gradient(Arena *, ScalarFieldFunc, const VectorF *)"); if ( !v11 ) __assert_fail( "f != NULL", "/workspace/llm4binary/github/2025_star3/tsotchke[P]eshkol/src/core/utils/vector.c", 1250LL, "VectorF *compute_gradient(Arena *, ScalarFieldFunc, const VectorF *)"); if ( !v10 ) __assert_fail( "v != NULL", "/workspace/llm4binary/github/2025_star3/tsotchke[P]eshkol/src/core/utils/vector.c", 1251LL, "VectorF *compute_gradient(Arena *, ScalarFieldFunc, const VectorF *)"); v9 = vector_f_create(v12, v10[2]); if ( !v9 ) return 0LL; v8 = 953267991; v7 = v11(v10); for ( i = 0LL; i < v10[2]; ++i ) { v5[0] = *v10; v5[1] = v10[1]; v5[2] = v10[2]; v5[3] = v10[3]; *((float *)v5 + i) = *((float *)v5 + i) + 0.000099999997; v3 = v11(v5); *(float *)(v9 + 4 * i) = (float)(v3 - v7) / 0.000099999997; } return v9; }
compute_gradient: PUSH RBP MOV RBP,RSP AND RSP,-0x20 SUB RSP,0xa0 MOV qword ptr [RSP + 0x80],RDI MOV qword ptr [RSP + 0x78],RSI MOV qword ptr [RSP + 0x70],RDX CMP qword ptr [RSP + 0x80],0x0 JZ 0x00107e4e JMP 0x00107e6d LAB_00107e4e: LEA RDI,[0x10a1c3] LEA RSI,[0x10b724] MOV EDX,0x4e1 LEA RCX,[0x10bf03] CALL 0x00101090 LAB_00107e6d: CMP qword ptr [RSP + 0x78],0x0 JZ 0x00107e77 JMP 0x00107e96 LAB_00107e77: LEA RDI,[0x10a8cd] LEA RSI,[0x10b724] MOV EDX,0x4e2 LEA RCX,[0x10bf03] CALL 0x00101090 LAB_00107e96: CMP qword ptr [RSP + 0x70],0x0 JZ 0x00107ea0 JMP 0x00107ebf LAB_00107ea0: LEA RDI,[0x10b16f] LEA RSI,[0x10b724] MOV EDX,0x4e3 LEA RCX,[0x10bf03] CALL 0x00101090 LAB_00107ebf: MOV RDI,qword ptr [RSP + 0x80] MOV RAX,qword ptr [RSP + 0x70] MOV RSI,qword ptr [RAX + 0x10] CALL 0x001049a0 MOV qword ptr [RSP + 0x68],RAX CMP qword ptr [RSP + 0x68],0x0 JNZ 0x00107ef3 MOV qword ptr [RSP + 0x88],0x0 JMP 0x00107fc7 LAB_00107ef3: MOVSS XMM0,dword ptr [0x0010b71c] MOVSS dword ptr [RSP + 0x64],XMM0 MOV RAX,qword ptr [RSP + 0x78] MOV RDI,qword ptr [RSP + 0x70] CALL RAX MOVSS dword ptr [RSP + 0x60],XMM0 MOV qword ptr [RSP + 0x58],0x0 LAB_00107f1c: MOV RAX,qword ptr [RSP + 0x58] MOV RCX,qword ptr [RSP + 0x70] CMP RAX,qword ptr [RCX + 0x10] JNC 0x00107fba MOV RAX,qword ptr [RSP + 0x70] MOV RCX,qword ptr [RAX] MOV qword ptr [RSP + 0x20],RCX MOV RCX,qword ptr [RAX + 0x8] MOV qword ptr [RSP + 0x28],RCX MOV RCX,qword ptr [RAX + 0x10] MOV qword ptr [RSP + 0x30],RCX MOV RAX,qword ptr [RAX + 0x18] MOV qword ptr [RSP + 0x38],RAX MOV RAX,qword ptr [RSP + 0x58] MOVSS XMM0,dword ptr [0x0010b71c] ADDSS XMM0,dword ptr [RSP + RAX*0x4 + 0x20] MOVSS dword ptr [RSP + RAX*0x4 + 0x20],XMM0 LEA RDI,[RSP + 0x20] CALL qword ptr [RSP + 0x78] MOVSS dword ptr [RSP + 0x1c],XMM0 MOVSS XMM0,dword ptr [RSP + 0x1c] SUBSS XMM0,dword ptr [RSP + 0x60] MOVSS XMM1,dword ptr [0x0010b71c] DIVSS XMM0,XMM1 MOV RAX,qword ptr [RSP + 0x68] MOV RCX,qword ptr [RSP + 0x58] MOVSS dword ptr [RAX + RCX*0x4],XMM0 MOV RAX,qword ptr [RSP + 0x58] ADD RAX,0x1 MOV qword ptr [RSP + 0x58],RAX JMP 0x00107f1c LAB_00107fba: MOV RAX,qword ptr [RSP + 0x68] MOV qword ptr [RSP + 0x88],RAX LAB_00107fc7: MOV RAX,qword ptr [RSP + 0x88] MOV RSP,RBP POP RBP RET
long compute_gradient(long param_1,code *param_2,int8 *param_3) { float fVar1; int8 local_a0; int8 local_98; int8 local_90; int8 local_88; ulong local_68; float local_60; float local_5c; long local_58; int8 *local_50; code *local_48; long local_40; long local_38; local_50 = param_3; local_48 = param_2; local_40 = param_1; if (param_1 == 0) { /* WARNING: Subroutine does not return */ __assert_fail("arena != NULL","/workspace/llm4binary/github2025/eshkol/src/core/utils/vector.c", 0x4e1,"VectorF *compute_gradient(Arena *, ScalarFieldFunc, const VectorF *)"); } if (param_2 != (code *)0x0) { if (param_3 != (int8 *)0x0) { local_58 = vector_f_create(param_1,param_3[2]); if (local_58 == 0) { local_38 = 0; } else { local_5c = DAT_0010b71c; local_60 = (float)(*local_48)(local_50); for (local_68 = 0; local_68 < (ulong)local_50[2]; local_68 = local_68 + 1) { local_a0 = *local_50; local_98 = local_50[1]; local_90 = local_50[2]; local_88 = local_50[3]; *(float *)((long)&local_a0 + local_68 * 4) = DAT_0010b71c + *(float *)((long)&local_a0 + local_68 * 4); fVar1 = (float)(*local_48)(&local_a0); *(float *)(local_58 + local_68 * 4) = (fVar1 - local_60) / DAT_0010b71c; } local_38 = local_58; } return local_38; } /* WARNING: Subroutine does not return */ __assert_fail("v != NULL","/workspace/llm4binary/github2025/eshkol/src/core/utils/vector.c", 0x4e3,"VectorF *compute_gradient(Arena *, ScalarFieldFunc, const VectorF *)"); } /* WARNING: Subroutine does not return */ __assert_fail("f != NULL","/workspace/llm4binary/github2025/eshkol/src/core/utils/vector.c",0x4e2, "VectorF *compute_gradient(Arena *, ScalarFieldFunc, const VectorF *)"); }
47,422
diagnostic_debug
tsotchke[P]eshkol/src/core/diagnostics/diagnostics.c
void diagnostic_debug(DiagnosticContext* context, int line, int column, const char* message) { assert(context != NULL); assert(message != NULL); // Only add debug messages if verbosity is debug if (context->verbosity == VERBOSITY_DEBUG) { // Create source location SourceLocation location = source_location_create(NULL, line, column, 0); // Add diagnostic diagnostic_context_add(context, DIAGNOSTIC_INFO, location, message, "DEBUG"); } }
O0
c
diagnostic_debug: pushq %rbp movq %rsp, %rbp subq $0x50, %rsp movq %rdi, -0x8(%rbp) movl %esi, -0xc(%rbp) movl %edx, -0x10(%rbp) movq %rcx, -0x18(%rbp) cmpq $0x0, -0x8(%rbp) je 0x38df jmp 0x38fe leaq 0x127d8(%rip), %rdi # 0x160be leaq 0x12f93(%rip), %rsi # 0x16880 movl $0x100, %edx # imm = 0x100 leaq 0x133b6(%rip), %rcx # 0x16caf callq 0x1120 cmpq $0x0, -0x18(%rbp) je 0x3907 jmp 0x3926 leaq 0x13076(%rip), %rdi # 0x16984 leaq 0x12f6b(%rip), %rsi # 0x16880 movl $0x101, %edx # imm = 0x101 leaq 0x1338e(%rip), %rcx # 0x16caf callq 0x1120 movq -0x8(%rbp), %rax cmpl $0x2, 0x28(%rax) jne 0x3979 movl -0xc(%rbp), %edx movl -0x10(%rbp), %ecx leaq -0x30(%rbp), %rdi xorl %eax, %eax movl %eax, %esi xorl %r8d, %r8d callq 0x2fc0 movq -0x8(%rbp), %rdi movq -0x18(%rbp), %rdx xorl %esi, %esi leaq -0x30(%rbp), %rax leaq 0x13397(%rip), %rcx # 0x16cf2 movq (%rax), %r8 movq %r8, (%rsp) movq 0x8(%rax), %r8 movq %r8, 0x8(%rsp) movq 0x10(%rax), %rax movq %rax, 0x10(%rsp) callq 0x30a0 addq $0x50, %rsp popq %rbp retq nop
diagnostic_debug: push rbp mov rbp, rsp sub rsp, 50h mov [rbp+var_8], rdi mov [rbp+var_C], esi mov [rbp+var_10], edx mov [rbp+var_18], rcx cmp [rbp+var_8], 0 jz short loc_38DF jmp short loc_38FE loc_38DF: lea rdi, aTypeContextNul+5; "context != NULL" lea rsi, aWorkspaceLlm4b_3; "/workspace/llm4binary/github/2025_star3"... mov edx, 100h lea rcx, aVoidDiagnostic_4; "void diagnostic_debug(DiagnosticContext"... call ___assert_fail loc_38FE: cmp [rbp+var_18], 0 jz short loc_3907 jmp short loc_3926 loc_3907: lea rdi, aMessageNull; "message != NULL" lea rsi, aWorkspaceLlm4b_3; "/workspace/llm4binary/github/2025_star3"... mov edx, 101h lea rcx, aVoidDiagnostic_4; "void diagnostic_debug(DiagnosticContext"... call ___assert_fail loc_3926: mov rax, [rbp+var_8] cmp dword ptr [rax+28h], 2 jnz short loc_3979 mov edx, [rbp+var_C] mov ecx, [rbp+var_10] lea rdi, [rbp+var_30] xor eax, eax mov esi, eax xor r8d, r8d call source_location_create mov rdi, [rbp+var_8] mov rdx, [rbp+var_18] xor esi, esi lea rax, [rbp+var_30] lea rcx, aDebug; "DEBUG" mov r8, [rax] mov [rsp+50h+var_50], r8 mov r8, [rax+8] mov [rsp+50h+var_48], r8 mov rax, [rax+10h] mov [rsp+50h+var_40], rax call diagnostic_context_add loc_3979: add rsp, 50h pop rbp retn
long long * diagnostic_debug(long long *a1, int a2, int a3, long long a4) { long long *result; // rax long long v5; // r9 long long v6; // [rsp+20h] [rbp-30h] BYREF long long v7; // [rsp+28h] [rbp-28h] long long v8; // [rsp+30h] [rbp-20h] long long v9; // [rsp+38h] [rbp-18h] int v10; // [rsp+40h] [rbp-10h] int v11; // [rsp+44h] [rbp-Ch] long long *v12; // [rsp+48h] [rbp-8h] v12 = a1; v11 = a2; v10 = a3; v9 = a4; if ( !a1 ) __assert_fail( "context != NULL", "/workspace/llm4binary/github/2025_star3/tsotchke[P]eshkol/src/core/diagnostics/diagnostics.c", 256LL, "void diagnostic_debug(DiagnosticContext *, int, int, const char *)"); if ( !v9 ) __assert_fail( "message != NULL", "/workspace/llm4binary/github/2025_star3/tsotchke[P]eshkol/src/core/diagnostics/diagnostics.c", 257LL, "void diagnostic_debug(DiagnosticContext *, int, int, const char *)"); result = v12; if ( *((_DWORD *)v12 + 10) == 2 ) { source_location_create((long long)&v6, 0LL, v11, v10, 0); return (long long *)diagnostic_context_add(v12, 0, v9, (long long)"DEBUG", v7, v5, v6, v7, v8); } return result; }
diagnostic_debug: PUSH RBP MOV RBP,RSP SUB RSP,0x50 MOV qword ptr [RBP + -0x8],RDI MOV dword ptr [RBP + -0xc],ESI MOV dword ptr [RBP + -0x10],EDX MOV qword ptr [RBP + -0x18],RCX CMP qword ptr [RBP + -0x8],0x0 JZ 0x001038df JMP 0x001038fe LAB_001038df: LEA RDI,[0x1160be] LEA RSI,[0x116880] MOV EDX,0x100 LEA RCX,[0x116caf] CALL 0x00101120 LAB_001038fe: CMP qword ptr [RBP + -0x18],0x0 JZ 0x00103907 JMP 0x00103926 LAB_00103907: LEA RDI,[0x116984] LEA RSI,[0x116880] MOV EDX,0x101 LEA RCX,[0x116caf] CALL 0x00101120 LAB_00103926: MOV RAX,qword ptr [RBP + -0x8] CMP dword ptr [RAX + 0x28],0x2 JNZ 0x00103979 MOV EDX,dword ptr [RBP + -0xc] MOV ECX,dword ptr [RBP + -0x10] LEA RDI,[RBP + -0x30] XOR EAX,EAX MOV ESI,EAX XOR R8D,R8D CALL 0x00102fc0 MOV RDI,qword ptr [RBP + -0x8] MOV RDX,qword ptr [RBP + -0x18] XOR ESI,ESI LEA RAX,[RBP + -0x30] LEA RCX,[0x116cf2] MOV R8,qword ptr [RAX] MOV qword ptr [RSP],R8 MOV R8,qword ptr [RAX + 0x8] MOV qword ptr [RSP + 0x8],R8 MOV RAX,qword ptr [RAX + 0x10] MOV qword ptr [RSP + 0x10],RAX CALL 0x001030a0 LAB_00103979: ADD RSP,0x50 POP RBP RET
void diagnostic_debug(long param_1,int4 param_2,int4 param_3,long param_4, int8 param_5,int8 param_6) { int8 local_38; int8 local_30; int8 local_28; long local_20; int4 local_18; int4 local_14; long local_10; local_20 = param_4; local_18 = param_3; local_14 = param_2; local_10 = param_1; if (param_1 == 0) { /* WARNING: Subroutine does not return */ __assert_fail("context != NULL", "/workspace/llm4binary/github/2025_star3/tsotchke[P]eshkol/src/core/diagnostics/diagnostics.c" ,0x100,"void diagnostic_debug(DiagnosticContext *, int, int, const char *)"); } if (param_4 != 0) { if (*(int *)(param_1 + 0x28) == 2) { source_location_create(&local_38,0,param_2,param_3,0); diagnostic_context_add (local_10,0,local_20,"DEBUG",local_30,param_6,local_38,local_30,local_28); } return; } /* WARNING: Subroutine does not return */ __assert_fail("message != NULL", "/workspace/llm4binary/github/2025_star3/tsotchke[P]eshkol/src/core/diagnostics/diagnostics.c" ,0x101,"void diagnostic_debug(DiagnosticContext *, int, int, const char *)"); }
47,423
TextToUpper
csit-sgu[P]mit-game-2025_1/Libraries/raylib/src/rtext.c
const char *TextToUpper(const char *text) { static char buffer[MAX_TEXT_BUFFER_LENGTH] = { 0 }; memset(buffer, 0, MAX_TEXT_BUFFER_LENGTH); if (text != NULL) { for (int i = 0; (i < MAX_TEXT_BUFFER_LENGTH - 1) && (text[i] != '\0'); i++) { if ((text[i] >= 'a') && (text[i] <= 'z')) buffer[i] = text[i] - 32; else buffer[i] = text[i]; } } return buffer; }
O2
c
TextToUpper: pushq %r14 pushq %rbx pushq %rax movq %rdi, %rbx leaq 0xbe0df(%rip), %r14 # 0x12f960 movl $0x400, %edx # imm = 0x400 movq %r14, %rdi xorl %esi, %esi callq 0x92c0 testq %rbx, %rbx je 0x718c2 xorl %eax, %eax cmpq $0x3ff, %rax # imm = 0x3FF je 0x718c2 movb (%rbx,%rax), %cl testb %cl, %cl je 0x718c2 leal -0x61(%rcx), %edx leal -0x20(%rcx), %esi cmpb $0x1a, %dl movzbl %cl, %ecx movzbl %sil, %edx cmovael %ecx, %edx movb %dl, (%rax,%r14) incq %rax jmp 0x71897 leaq 0xbe097(%rip), %rax # 0x12f960 addq $0x8, %rsp popq %rbx popq %r14 retq
TextToUpper: push r14 push rbx push rax mov rbx, rdi lea r14, TextToUpper_buffer mov edx, 400h mov rdi, r14 xor esi, esi call _memset test rbx, rbx jz short loc_718C2 xor eax, eax loc_71897: cmp rax, 3FFh jz short loc_718C2 mov cl, [rbx+rax] test cl, cl jz short loc_718C2 lea edx, [rcx-61h] lea esi, [rcx-20h] cmp dl, 1Ah movzx ecx, cl movzx edx, sil cmovnb edx, ecx mov [rax+r14], dl inc rax jmp short loc_71897 loc_718C2: lea rax, TextToUpper_buffer add rsp, 8 pop rbx pop r14 retn
char * TextToUpper(long long a1) { long long i; // rax char v2; // cl char v3; // dl memset(TextToUpper_buffer, 0LL, sizeof(TextToUpper_buffer)); if ( a1 ) { for ( i = 0LL; i != 1023; ++i ) { v2 = *(_BYTE *)(a1 + i); if ( !v2 ) break; v3 = v2 - 32; if ( (unsigned __int8)(v2 - 97) >= 0x1Au ) v3 = *(_BYTE *)(a1 + i); TextToUpper_buffer[i] = v3; } } return TextToUpper_buffer; }
TextToUpper: PUSH R14 PUSH RBX PUSH RAX MOV RBX,RDI LEA R14,[0x22f960] MOV EDX,0x400 MOV RDI,R14 XOR ESI,ESI CALL 0x001092c0 TEST RBX,RBX JZ 0x001718c2 XOR EAX,EAX LAB_00171897: CMP RAX,0x3ff JZ 0x001718c2 MOV CL,byte ptr [RBX + RAX*0x1] TEST CL,CL JZ 0x001718c2 LEA EDX,[RCX + -0x61] LEA ESI,[RCX + -0x20] CMP DL,0x1a MOVZX ECX,CL MOVZX EDX,SIL CMOVNC EDX,ECX MOV byte ptr [RAX + R14*0x1],DL INC RAX JMP 0x00171897 LAB_001718c2: LEA RAX,[0x22f960] ADD RSP,0x8 POP RBX POP R14 RET
int1 * TextToUpper(long param_1) { char cVar1; long lVar2; char cVar3; memset(&TextToUpper_buffer,0,0x400); if (param_1 != 0) { for (lVar2 = 0; (lVar2 != 0x3ff && (cVar1 = *(char *)(param_1 + lVar2), cVar1 != '\0')); lVar2 = lVar2 + 1) { cVar3 = cVar1 + -0x20; if (0x19 < (byte)(cVar1 + 0x9fU)) { cVar3 = cVar1; } (&TextToUpper_buffer)[lVar2] = cVar3; } } return &TextToUpper_buffer; }
47,424
TextToUpper
csit-sgu[P]mit-game-2025_1/Libraries/raylib/src/rtext.c
const char *TextToUpper(const char *text) { static char buffer[MAX_TEXT_BUFFER_LENGTH] = { 0 }; memset(buffer, 0, MAX_TEXT_BUFFER_LENGTH); if (text != NULL) { for (int i = 0; (i < MAX_TEXT_BUFFER_LENGTH - 1) && (text[i] != '\0'); i++) { if ((text[i] >= 'a') && (text[i] <= 'z')) buffer[i] = text[i] - 32; else buffer[i] = text[i]; } } return buffer; }
O3
c
TextToUpper: pushq %r14 pushq %rbx pushq %rax movq %rdi, %rbx leaq 0xbedd2(%rip), %r14 # 0x143940 movl $0x400, %edx # imm = 0x400 movq %r14, %rdi xorl %esi, %esi callq 0xa2d0 testq %rbx, %rbx je 0x84bad xorl %eax, %eax movb (%rbx,%rax), %cl testb %cl, %cl je 0x84bad leal -0x61(%rcx), %edx leal -0x20(%rcx), %esi cmpb $0x1a, %dl movzbl %cl, %ecx movzbl %sil, %edx cmovael %ecx, %edx movb %dl, (%rax,%r14) incq %rax cmpq $0x3ff, %rax # imm = 0x3FF jne 0x84b84 leaq 0xbed8c(%rip), %rax # 0x143940 addq $0x8, %rsp popq %rbx popq %r14 retq
TextToUpper: push r14 push rbx push rax mov rbx, rdi lea r14, TextToUpper_buffer mov edx, 400h mov rdi, r14 xor esi, esi call _memset test rbx, rbx jz short loc_84BAD xor eax, eax loc_84B84: mov cl, [rbx+rax] test cl, cl jz short loc_84BAD lea edx, [rcx-61h] lea esi, [rcx-20h] cmp dl, 1Ah movzx ecx, cl movzx edx, sil cmovnb edx, ecx mov [rax+r14], dl inc rax cmp rax, 3FFh jnz short loc_84B84 loc_84BAD: lea rax, TextToUpper_buffer add rsp, 8 pop rbx pop r14 retn
char * TextToUpper(long long a1) { long long i; // rax char v2; // cl char v3; // dl memset(TextToUpper_buffer, 0LL, sizeof(TextToUpper_buffer)); if ( a1 ) { for ( i = 0LL; i != 1023; ++i ) { v2 = *(_BYTE *)(a1 + i); if ( !v2 ) break; v3 = v2 - 32; if ( (unsigned __int8)(v2 - 97) >= 0x1Au ) v3 = *(_BYTE *)(a1 + i); TextToUpper_buffer[i] = v3; } } return TextToUpper_buffer; }
TextToUpper: PUSH R14 PUSH RBX PUSH RAX MOV RBX,RDI LEA R14,[0x243940] MOV EDX,0x400 MOV RDI,R14 XOR ESI,ESI CALL 0x0010a2d0 TEST RBX,RBX JZ 0x00184bad XOR EAX,EAX LAB_00184b84: MOV CL,byte ptr [RBX + RAX*0x1] TEST CL,CL JZ 0x00184bad LEA EDX,[RCX + -0x61] LEA ESI,[RCX + -0x20] CMP DL,0x1a MOVZX ECX,CL MOVZX EDX,SIL CMOVNC EDX,ECX MOV byte ptr [RAX + R14*0x1],DL INC RAX CMP RAX,0x3ff JNZ 0x00184b84 LAB_00184bad: LEA RAX,[0x243940] ADD RSP,0x8 POP RBX POP R14 RET
int1 * TextToUpper(long param_1) { char cVar1; long lVar2; char cVar3; memset(&TextToUpper_buffer,0,0x400); if (param_1 != 0) { lVar2 = 0; do { cVar1 = *(char *)(param_1 + lVar2); if (cVar1 == '\0') { return &TextToUpper_buffer; } cVar3 = cVar1 + -0x20; if (0x19 < (byte)(cVar1 + 0x9fU)) { cVar3 = cVar1; } (&TextToUpper_buffer)[lVar2] = cVar3; lVar2 = lVar2 + 1; } while (lVar2 != 0x3ff); } return &TextToUpper_buffer; }
47,425
format_literal(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&)
monkey531[P]llama/common/json-schema-to-grammar.cpp
static std::string format_literal(const std::string & literal) { std::string escaped = replacePattern(literal, GRAMMAR_LITERAL_ESCAPE_RE, [&](const std::smatch & match) { char c = match.str()[0]; return GRAMMAR_LITERAL_ESCAPES.at(c); }); return "\"" + escaped + "\""; }
O3
cpp
format_literal(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&): pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x88, %rsp movq %rdx, %r14 movq %rsi, %r15 movq %rdi, 0x80(%rsp) xorps %xmm0, %xmm0 leaq 0x60(%rsp), %rcx movaps %xmm0, (%rcx) leaq 0x2ef(%rip), %rax # 0xbd260 movq %rax, 0x18(%rcx) leaq 0x366(%rip), %rax # 0xbd2e2 movq %rax, 0x10(%rcx) movq %rsp, %r12 movaps %xmm0, 0x10(%r12) movaps %xmm0, (%r12) leaq 0x30(%rsp), %rax movq %rax, -0x10(%rax) movq $0x0, -0x8(%rax) movb $0x0, (%rax) addq %rsi, %r14 leaq 0x70364(%rip), %r13 # 0x12d310 leaq 0x20(%rsp), %rbp leaq 0x40(%rsp), %rbx movq %r15, %rdi movq %r14, %rsi movq %r12, %rdx movq %r13, %rcx xorl %r8d, %r8d callq 0x6d587 testb %al, %al je 0xbd090 movq (%rsp), %rax movq 0x8(%rsp), %rcx movq %rcx, %rdx subq %rax, %rdx leaq -0x48(%rcx), %rsi cmpq $0x48, %rdx movq %rax, %rdx cmoveq %rsi, %rdx cmpq %rax, %rcx cmoveq %rsi, %rdx movq (%rdx), %r8 subq 0x18(%rsp), %r8 movq 0x28(%rsp), %rsi movq %rbp, %rdi xorl %edx, %edx movq %r15, %rcx callq 0x1a9f0 cmpq $0x0, 0x70(%rsp) je 0xbd18b movq %rbx, %rdi leaq 0x60(%rsp), %rsi movq %r12, %rdx callq *0x78(%rsp) movq 0x40(%rsp), %rsi movq 0x48(%rsp), %rdx movq %rbp, %rdi callq 0x1a270 movq 0x40(%rsp), %rdi leaq 0x50(%rsp), %rax cmpq %rax, %rdi je 0xbd05a movq 0x50(%rsp), %rsi incq %rsi callq 0x1a8f0 movq 0x8(%rsp), %rax movq %rax, %rcx subq (%rsp), %rcx sarq $0x3, %rcx movabsq $-0x5555555555555555, %rdx # imm = 0xAAAAAAAAAAAAAAAB imulq %rdx, %rcx leaq -0x18(%rax), %rdx addq $-0x48, %rax cmpq $0x4, %rcx cmovaeq %rdx, %rax movq (%rax), %r15 jmp 0xbcfb6 leaq 0x20(%rsp), %rdi movq 0x8(%rdi), %rsi subq %r15, %r14 xorl %edx, %edx movq %r15, %rcx movq %r14, %r8 callq 0x1a9f0 movq (%rsp), %rdi testq %rdi, %rdi movq 0x80(%rsp), %rbx je 0xbd0c7 movq 0x10(%rsp), %rsi subq %rdi, %rsi callq 0x1a8f0 movq 0x70(%rsp), %rax testq %rax, %rax je 0xbd0e0 leaq 0x60(%rsp), %rdi movq %rdi, %rsi movl $0x3, %edx callq *%rax leaq 0x39c98(%rip), %rsi # 0xf6d7f movq %rsp, %rdi leaq 0x20(%rsp), %rdx callq 0x5402d leaq 0x39c84(%rip), %rsi # 0xf6d7f movq %rsp, %rdi callq 0x1b120 leaq 0x10(%rbx), %rdx movq %rdx, (%rbx) movq (%rax), %rsi movq %rax, %rcx addq $0x10, %rcx cmpq %rcx, %rsi je 0xbd125 movq %rsi, (%rbx) movq (%rcx), %rdx movq %rdx, 0x10(%rbx) jmp 0xbd12b movups (%rcx), %xmm0 movups %xmm0, (%rdx) movq 0x8(%rax), %rdx movq %rdx, 0x8(%rbx) movq %rcx, (%rax) movq $0x0, 0x8(%rax) movb $0x0, 0x10(%rax) leaq 0x10(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0xbd15d movq 0x10(%rsp), %rsi incq %rsi callq 0x1a8f0 movq 0x20(%rsp), %rdi leaq 0x30(%rsp), %rax cmpq %rax, %rdi je 0xbd179 movq 0x30(%rsp), %rsi incq %rsi callq 0x1a8f0 addq $0x88, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq callq 0x1a330 jmp 0xbd257 movq %rax, %rbx leaq 0x10(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0xbd1b8 movq 0x10(%rsp), %rsi incq %rsi callq 0x1a8f0 jmp 0xbd1b8 movq %rax, %rbx movq 0x20(%rsp), %rdi leaq 0x30(%rsp), %rax cmpq %rax, %rdi je 0xbd24f movq 0x30(%rsp), %rsi incq %rsi callq 0x1a8f0 jmp 0xbd24f jmp 0xbd201 jmp 0xbd201 movq %rax, %rbx movq 0x40(%rsp), %rdi leaq 0x50(%rsp), %rax cmpq %rax, %rdi je 0xbd204 movq 0x50(%rsp), %rsi incq %rsi callq 0x1a8f0 jmp 0xbd204 jmp 0xbd201 movq %rax, %rbx movq 0x20(%rsp), %rdi leaq 0x30(%rsp), %rax cmpq %rax, %rdi je 0xbd220 movq 0x30(%rsp), %rsi incq %rsi callq 0x1a8f0 movq (%rsp), %rdi testq %rdi, %rdi je 0xbd236 movq 0x10(%rsp), %rsi subq %rdi, %rsi callq 0x1a8f0 movq 0x70(%rsp), %rax testq %rax, %rax je 0xbd24f leaq 0x60(%rsp), %rdi movq %rdi, %rsi movl $0x3, %edx callq *%rax movq %rbx, %rdi callq 0x1afd0 movq %rax, %rdi callq 0x218f5 nop
_ZL14format_literalRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 88h mov r14, rdx mov r15, rsi mov [rsp+0B8h+var_38], rdi xorps xmm0, xmm0 lea rcx, [rsp+0B8h+var_58] movaps xmmword ptr [rcx], xmm0 lea rax, _ZNSt17_Function_handlerIFNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKNS0_13match_resultsIN9__gnu_cxx17__normal_iteratorIPKcS5_EESaINS0_9sub_matchISB_EEEEEEZL14format_literalRKS5_E3$_0E9_M_invokeERKSt9_Any_dataSH_; std::_Function_handler<std::string ()(std::match_results<__gnu_cxx::__normal_iterator<char const*,std::string>> const&),format_literal(std::string const&)::$_0>::_M_invoke(std::_Any_data const&,std::match_results<__gnu_cxx::__normal_iterator<char const*,std::string>> const&) mov [rcx+18h], rax lea rax, _ZNSt17_Function_handlerIFNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKNS0_13match_resultsIN9__gnu_cxx17__normal_iteratorIPKcS5_EESaINS0_9sub_matchISB_EEEEEEZL14format_literalRKS5_E3$_0E10_M_managerERSt9_Any_dataRKSN_St18_Manager_operation; std::_Function_handler<std::string ()(std::match_results<__gnu_cxx::__normal_iterator<char const*,std::string>> const&),format_literal(std::string const&)::$_0>::_M_manager(std::_Any_data &,std::_Any_data const&,std::_Manager_operation) mov [rcx+10h], rax mov r12, rsp movaps xmmword ptr [r12+10h], xmm0 movaps xmmword ptr [r12], xmm0 lea rax, [rsp+0B8h+var_88] mov [rax-10h], rax mov qword ptr [rax-8], 0 mov byte ptr [rax], 0 add r14, rsi lea r13, _Z25GRAMMAR_LITERAL_ESCAPE_REB5cxx11; GRAMMAR_LITERAL_ESCAPE_RE lea rbp, [rsp+0B8h+var_98] lea rbx, [rsp+0B8h+var_78] loc_BCFB6: mov rdi, r15 mov rsi, r14 mov rdx, r12 mov rcx, r13 xor r8d, r8d call _ZNSt8__detail17__regex_algo_implIN9__gnu_cxx17__normal_iteratorIPKcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEESaINS5_9sub_matchISB_EEEcNS5_12regex_traitsIcEELNS_20_RegexExecutorPolicyE0ELb0EEEbT_SI_RNS5_13match_resultsISI_T0_EERKNS5_11basic_regexIT1_T2_EENSt15regex_constants15match_flag_typeE; std::__detail::__regex_algo_impl<__gnu_cxx::__normal_iterator<char const*,std::string>,std::allocator<std::sub_match<__gnu_cxx::__normal_iterator<char const*,std::string>>>,char,std::regex_traits<char>,(std::__detail::_RegexExecutorPolicy)0,false>(__gnu_cxx::__normal_iterator<char const*,std::string>,__gnu_cxx::__normal_iterator<char const*,std::string>,std::match_results<__gnu_cxx::__normal_iterator<char const*,std::string>> &,std::basic_regex<char,std::regex_traits<char>> const&,std::regex_constants::match_flag_type) test al, al jz loc_BD090 mov rax, [rsp+0B8h+var_B8] mov rcx, [rsp+0B8h+var_B0] mov rdx, rcx sub rdx, rax lea rsi, [rcx-48h] cmp rdx, 48h ; 'H' mov rdx, rax cmovz rdx, rsi cmp rcx, rax cmovz rdx, rsi mov r8, [rdx] sub r8, [rsp+0B8h+var_A0] mov rsi, [rsp+0B8h+var_90] mov rdi, rbp xor edx, edx mov rcx, r15 call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE7replaceEmmPKcm; std::string::replace(ulong,ulong,char const*,ulong) cmp [rsp+0B8h+var_48], 0 jz loc_BD18B mov rdi, rbx lea rsi, [rsp+0B8h+var_58] mov rdx, r12 call [rsp+0B8h+var_40] mov rsi, [rsp+0B8h+var_78] mov rdx, [rsp+0B8h+var_70] mov rdi, rbp call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9_M_appendEPKcm; std::string::_M_append(char const*,ulong) mov rdi, [rsp+0B8h+var_78]; void * lea rax, [rsp+0B8h+var_68] cmp rdi, rax jz short loc_BD05A mov rsi, [rsp+0B8h+var_68] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_BD05A: mov rax, [rsp+0B8h+var_B0] mov rcx, rax sub rcx, [rsp+0B8h+var_B8] sar rcx, 3 mov rdx, 0AAAAAAAAAAAAAAABh imul rcx, rdx lea rdx, [rax-18h] add rax, 0FFFFFFFFFFFFFFB8h cmp rcx, 4 cmovnb rax, rdx mov r15, [rax] jmp loc_BCFB6 loc_BD090: lea rdi, [rsp+0B8h+var_98] mov rsi, [rdi+8] sub r14, r15 xor edx, edx mov rcx, r15 mov r8, r14 call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE7replaceEmmPKcm; std::string::replace(ulong,ulong,char const*,ulong) mov rdi, [rsp+0B8h+var_B8]; void * test rdi, rdi mov rbx, [rsp+0B8h+var_38] jz short loc_BD0C7 mov rsi, [rsp+0B8h+var_A8] sub rsi, rdi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_BD0C7: mov rax, [rsp+0B8h+var_48] test rax, rax jz short loc_BD0E0 lea rdi, [rsp+0B8h+var_58] mov rsi, rdi mov edx, 3 call rax loc_BD0E0: lea rsi, aName+9; "\"" mov rdi, rsp lea rdx, [rsp+0B8h+var_98] call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_RKS8_; std::operator+<char>(char const*,std::string const&) lea rsi, aName+9; "\"" mov rdi, rsp call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendEPKc; std::string::append(char const*) lea rdx, [rbx+10h] mov [rbx], rdx mov rsi, [rax] mov rcx, rax add rcx, 10h cmp rsi, rcx jz short loc_BD125 mov [rbx], rsi mov rdx, [rcx] mov [rbx+10h], rdx jmp short loc_BD12B loc_BD125: movups xmm0, xmmword ptr [rcx] movups xmmword ptr [rdx], xmm0 loc_BD12B: mov rdx, [rax+8] mov [rbx+8], rdx mov [rax], rcx mov qword ptr [rax+8], 0 mov byte ptr [rax+10h], 0 lea rax, [rsp+0B8h+var_A8] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_BD15D mov rsi, [rsp+0B8h+var_A8] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_BD15D: mov rdi, [rsp+0B8h+var_98]; void * lea rax, [rsp+0B8h+var_88] cmp rdi, rax jz short loc_BD179 mov rsi, [rsp+0B8h+var_88] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_BD179: add rsp, 88h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn loc_BD18B: call __ZSt25__throw_bad_function_callv; std::__throw_bad_function_call(void) jmp loc_BD257 mov rbx, rax lea rax, [rsp+0B8h+var_A8] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_BD1B8 mov rsi, [rsp+0B8h+var_A8] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) jmp short loc_BD1B8 mov rbx, rax loc_BD1B8: mov rdi, [rsp+0B8h+var_98]; void * lea rax, [rsp+0B8h+var_88] cmp rdi, rax jz loc_BD24F mov rsi, [rsp+0B8h+var_88] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) jmp short loc_BD24F jmp short loc_BD201 jmp short loc_BD201 mov rbx, rax mov rdi, [rsp+0B8h+var_78]; void * lea rax, [rsp+0B8h+var_68] cmp rdi, rax jz short loc_BD204 mov rsi, [rsp+0B8h+var_68] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) jmp short loc_BD204 jmp short $+2 loc_BD201: mov rbx, rax loc_BD204: mov rdi, [rsp+0B8h+var_98]; void * lea rax, [rsp+0B8h+var_88] cmp rdi, rax jz short loc_BD220 mov rsi, [rsp+0B8h+var_88] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_BD220: mov rdi, [rsp+0B8h+var_B8]; void * test rdi, rdi jz short loc_BD236 mov rsi, [rsp+0B8h+var_A8] sub rsi, rdi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_BD236: mov rax, [rsp+0B8h+var_48] test rax, rax jz short loc_BD24F lea rdi, [rsp+0B8h+var_58] mov rsi, rdi mov edx, 3 call rax loc_BD24F: mov rdi, rbx call __Unwind_Resume loc_BD257: mov rdi, rax call __clang_call_terminate
void format_literal(long long a1, long long *a2, long long a3) { long long *v3; // r15 long long v4; // r14 _QWORD *v5; // rdx long long **v6; // rax long long v7; // rbx long long v8; // rax _OWORD *v9; // rcx __int128 v10; // [rsp+0h] [rbp-B8h] BYREF __int128 v11; // [rsp+10h] [rbp-A8h] BYREF void *v12; // [rsp+20h] [rbp-98h] BYREF long long v13; // [rsp+28h] [rbp-90h] _QWORD v14[2]; // [rsp+30h] [rbp-88h] BYREF void *v15[2]; // [rsp+40h] [rbp-78h] BYREF long long v16; // [rsp+50h] [rbp-68h] BYREF __int128 v17; // [rsp+60h] [rbp-58h] BYREF long long ( *v18)(); // [rsp+70h] [rbp-48h] long long ( *v19)(); // [rsp+78h] [rbp-40h] long long v20; // [rsp+80h] [rbp-38h] v3 = a2; v20 = a1; v17 = 0LL; v19 = std::_Function_handler<std::string ()(std::match_results<__gnu_cxx::__normal_iterator<char const*,std::string>> const&),format_literal(std::string const&)::$_0>::_M_invoke; v18 = std::_Function_handler<std::string ()(std::match_results<__gnu_cxx::__normal_iterator<char const*,std::string>> const&),format_literal(std::string const&)::$_0>::_M_manager; v11 = 0LL; v10 = 0LL; v12 = v14; v13 = 0LL; LOBYTE(v14[0]) = 0; v4 = (long long)a2 + a3; while ( std::__detail::__regex_algo_impl<__gnu_cxx::__normal_iterator<char const*,std::string>,std::allocator<std::sub_match<__gnu_cxx::__normal_iterator<char const*,std::string>>>,char,std::regex_traits<char>,(std::__detail::_RegexExecutorPolicy)0,false>( v3, v4, (long long **)&v10, (long long)&GRAMMAR_LITERAL_ESCAPE_RE[abi:cxx11], 0) ) { v5 = (_QWORD *)v10; if ( *((_QWORD *)&v10 + 1) - (_QWORD)v10 == 72LL ) v5 = (_QWORD *)(*((_QWORD *)&v10 + 1) - 72LL); if ( *((_QWORD *)&v10 + 1) == (_QWORD)v10 ) v5 = (_QWORD *)(*((_QWORD *)&v10 + 1) - 72LL); std::string::replace(&v12, v13, 0LL, v3, *v5 - *((_QWORD *)&v11 + 1)); if ( !v18 ) std::__throw_bad_function_call(); ((void ( *)(void **, __int128 *, __int128 *))v19)(v15, &v17, &v10); std::string::_M_append(&v12, v15[0], v15[1]); if ( v15[0] != &v16 ) operator delete(v15[0], v16 + 1); v6 = (long long **)(*((_QWORD *)&v10 + 1) - 72LL); if ( 0xAAAAAAAAAAAAAAABLL * ((long long)(*((_QWORD *)&v10 + 1) - v10) >> 3) >= 4 ) v6 = (long long **)(*((_QWORD *)&v10 + 1) - 24LL); v3 = *v6; } std::string::replace(&v12, v13, 0LL, v3, v4 - (_QWORD)v3); v7 = v20; if ( (_QWORD)v10 ) operator delete((void *)v10, v11 - v10); if ( v18 ) ((void ( *)(__int128 *, __int128 *, long long))v18)(&v17, &v17, 3LL); std::operator+<char>((long long)&v10, (long long)"\"", &v12); v8 = std::string::append(&v10, "\""); *(_QWORD *)v7 = v7 + 16; v9 = (_OWORD *)(v8 + 16); if ( *(_QWORD *)v8 == v8 + 16 ) { *(_OWORD *)(v7 + 16) = *v9; } else { *(_QWORD *)v7 = *(_QWORD *)v8; *(_QWORD *)(v7 + 16) = *(_QWORD *)v9; } *(_QWORD *)(v7 + 8) = *(_QWORD *)(v8 + 8); *(_QWORD *)v8 = v9; *(_QWORD *)(v8 + 8) = 0LL; *(_BYTE *)(v8 + 16) = 0; if ( (__int128 *)v10 != &v11 ) operator delete((void *)v10, v11 + 1); if ( v12 != v14 ) operator delete(v12, v14[0] + 1LL); }
format_literal: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x88 MOV R14,RDX MOV R15,RSI MOV qword ptr [RSP + 0x80],RDI XORPS XMM0,XMM0 LEA RCX,[RSP + 0x60] MOVAPS xmmword ptr [RCX],XMM0 LEA RAX,[0x1bd260] MOV qword ptr [RCX + 0x18],RAX LEA RAX,[0x1bd2e2] MOV qword ptr [RCX + 0x10],RAX MOV R12,RSP MOVAPS xmmword ptr [R12 + 0x10],XMM0 MOVAPS xmmword ptr [R12],XMM0 LEA RAX,[RSP + 0x30] MOV qword ptr [RAX + -0x10],RAX MOV qword ptr [RAX + -0x8],0x0 MOV byte ptr [RAX],0x0 ADD R14,RSI LEA R13,[0x22d310] LEA RBP,[RSP + 0x20] LEA RBX,[RSP + 0x40] LAB_001bcfb6: MOV RDI,R15 MOV RSI,R14 MOV RDX,R12 MOV RCX,R13 XOR R8D,R8D CALL 0x0016d587 TEST AL,AL JZ 0x001bd090 MOV RAX,qword ptr [RSP] MOV RCX,qword ptr [RSP + 0x8] MOV RDX,RCX SUB RDX,RAX LEA RSI,[RCX + -0x48] CMP RDX,0x48 MOV RDX,RAX CMOVZ RDX,RSI CMP RCX,RAX CMOVZ RDX,RSI MOV R8,qword ptr [RDX] SUB R8,qword ptr [RSP + 0x18] MOV RSI,qword ptr [RSP + 0x28] MOV RDI,RBP XOR EDX,EDX MOV RCX,R15 CALL 0x0011a9f0 CMP qword ptr [RSP + 0x70],0x0 JZ 0x001bd18b LAB_001bd01d: MOV RDI,RBX LEA RSI,[RSP + 0x60] MOV RDX,R12 CALL qword ptr [RSP + 0x78] MOV RSI,qword ptr [RSP + 0x40] MOV RDX,qword ptr [RSP + 0x48] LAB_001bd036: MOV RDI,RBP CALL 0x0011a270 MOV RDI,qword ptr [RSP + 0x40] LEA RAX,[RSP + 0x50] CMP RDI,RAX JZ 0x001bd05a MOV RSI,qword ptr [RSP + 0x50] INC RSI CALL 0x0011a8f0 LAB_001bd05a: MOV RAX,qword ptr [RSP + 0x8] MOV RCX,RAX SUB RCX,qword ptr [RSP] SAR RCX,0x3 MOV RDX,-0x5555555555555555 IMUL RCX,RDX LEA RDX,[RAX + -0x18] ADD RAX,-0x48 CMP RCX,0x4 CMOVNC RAX,RDX MOV R15,qword ptr [RAX] JMP 0x001bcfb6 LAB_001bd090: LEA RDI,[RSP + 0x20] MOV RSI,qword ptr [RDI + 0x8] SUB R14,R15 LAB_001bd09c: XOR EDX,EDX MOV RCX,R15 MOV R8,R14 CALL 0x0011a9f0 MOV RDI,qword ptr [RSP] TEST RDI,RDI MOV RBX,qword ptr [RSP + 0x80] JZ 0x001bd0c7 MOV RSI,qword ptr [RSP + 0x10] SUB RSI,RDI CALL 0x0011a8f0 LAB_001bd0c7: MOV RAX,qword ptr [RSP + 0x70] TEST RAX,RAX JZ 0x001bd0e0 LAB_001bd0d1: LEA RDI,[RSP + 0x60] MOV RSI,RDI MOV EDX,0x3 CALL RAX LAB_001bd0e0: LEA RSI,[0x1f6d7f] MOV RDI,RSP LEA RDX,[RSP + 0x20] CALL 0x0015402d LAB_001bd0f4: LEA RSI,[0x1f6d7f] MOV RDI,RSP CALL 0x0011b120 LEA RDX,[RBX + 0x10] MOV qword ptr [RBX],RDX MOV RSI,qword ptr [RAX] MOV RCX,RAX ADD RCX,0x10 CMP RSI,RCX JZ 0x001bd125 MOV qword ptr [RBX],RSI MOV RDX,qword ptr [RCX] MOV qword ptr [RBX + 0x10],RDX JMP 0x001bd12b LAB_001bd125: MOVUPS XMM0,xmmword ptr [RCX] MOVUPS xmmword ptr [RDX],XMM0 LAB_001bd12b: MOV RDX,qword ptr [RAX + 0x8] MOV qword ptr [RBX + 0x8],RDX MOV qword ptr [RAX],RCX MOV qword ptr [RAX + 0x8],0x0 MOV byte ptr [RAX + 0x10],0x0 LEA RAX,[RSP + 0x10] MOV RDI,qword ptr [RAX + -0x10] CMP RDI,RAX JZ 0x001bd15d MOV RSI,qword ptr [RSP + 0x10] INC RSI CALL 0x0011a8f0 LAB_001bd15d: MOV RDI,qword ptr [RSP + 0x20] LEA RAX,[RSP + 0x30] CMP RDI,RAX JZ 0x001bd179 MOV RSI,qword ptr [RSP + 0x30] INC RSI CALL 0x0011a8f0 LAB_001bd179: ADD RSP,0x88 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET LAB_001bd18b: CALL 0x0011a330
/* format_literal(std::__cxx11::string const&) */ void format_literal(string *param_1) { string *psVar1; bool bVar2; ulong *puVar3; int8 *puVar4; long *plVar5; long in_RDX; ulong in_RSI; long lVar6; long *local_b8; long lStack_b0; long local_a8 [2]; int1 *local_98; ulong local_90; int1 local_88; int7 uStack_87; long *local_78 [2]; long local_68 [2]; int8 local_58; int8 uStack_50; code *local_48; code *local_40; string *local_38; local_58 = 0; uStack_50 = 0; local_40 = std:: _Function_handler<std::__cxx11::string(std::__cxx11::match_results<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>,std::allocator<std::__cxx11::sub_match<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>>>>const&),format_literal(std::__cxx11::string_const&)::$_0> ::_M_invoke; local_48 = std:: _Function_handler<std::__cxx11::string(std::__cxx11::match_results<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>,std::allocator<std::__cxx11::sub_match<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>>>>const&),format_literal(std::__cxx11::string_const&)::$_0> ::_M_manager; local_a8[0] = 0; local_a8[1] = 0; local_b8 = (long *)0x0; lStack_b0 = 0; local_98 = &local_88; local_90 = 0; local_88 = 0; lVar6 = in_RDX + in_RSI; local_38 = param_1; while( true ) { /* try { // try from 001bcfb6 to 001bd010 has its CatchHandler @ 001bd201 */ bVar2 = std::__detail:: __regex_algo_impl<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>,std::allocator<std::__cxx11::sub_match<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>>>,char,std::__cxx11::regex_traits<char>,(std::__detail::_RegexExecutorPolicy)0,false> (in_RSI,lVar6,&local_b8,GRAMMAR_LITERAL_ESCAPE_RE_abi_cxx11_,0); if (!bVar2) { /* try { // try from 001bd09c to 001bd0a8 has its CatchHandler @ 001bd1da */ std::__cxx11::string::replace((ulong)&local_98,local_90,(char *)0x0,in_RSI); psVar1 = local_38; if (local_b8 != (long *)0x0) { operator_delete(local_b8,local_a8[0] - (long)local_b8); } if (local_48 != (code *)0x0) { /* try { // try from 001bd0d1 to 001bd0df has its CatchHandler @ 001bd190 */ (*local_48)(&local_58,&local_58,3); } /* try { // try from 001bd0e0 to 001bd0f3 has its CatchHandler @ 001bd1b5 */ std::operator+((char *)&local_b8,(string *)&DAT_001f6d7f); /* try { // try from 001bd0f4 to 001bd102 has its CatchHandler @ 001bd195 */ puVar4 = (int8 *)std::__cxx11::string::append((char *)&local_b8); *(string **)psVar1 = psVar1 + 0x10; plVar5 = puVar4 + 2; if ((long *)*puVar4 == plVar5) { lVar6 = puVar4[3]; *(long *)(psVar1 + 0x10) = *plVar5; *(long *)(psVar1 + 0x18) = lVar6; } else { *(long **)psVar1 = (long *)*puVar4; *(long *)(psVar1 + 0x10) = *plVar5; } *(int8 *)(psVar1 + 8) = puVar4[1]; *puVar4 = plVar5; puVar4[1] = 0; *(int1 *)(puVar4 + 2) = 0; if (local_b8 != local_a8) { operator_delete(local_b8,local_a8[0] + 1); } if (local_98 != &local_88) { operator_delete(local_98,CONCAT71(uStack_87,local_88) + 1); } return; } std::__cxx11::string::replace((ulong)&local_98,local_90,(char *)0x0,in_RSI); if (local_48 == (code *)0x0) break; /* try { // try from 001bd01d to 001bd02b has its CatchHandler @ 001bd1ff */ (*local_40)(local_78,&local_58,&local_b8); /* try { // try from 001bd036 to 001bd03d has its CatchHandler @ 001bd1de */ std::__cxx11::string::_M_append((char *)&local_98,(ulong)local_78[0]); if (local_78[0] != local_68) { operator_delete(local_78[0],local_68[0] + 1); } puVar3 = (ulong *)(lStack_b0 + -0x48); if (3 < (ulong)((lStack_b0 - (long)local_b8 >> 3) * -0x5555555555555555)) { puVar3 = (ulong *)(lStack_b0 + -0x18); } in_RSI = *puVar3; } /* WARNING: Subroutine does not return */ /* try { // try from 001bd18b to 001bd18f has its CatchHandler @ 001bd1dc */ std::__throw_bad_function_call(); }
47,426
google::protobuf::GeneratedCodeInfo_Annotation::MergeImpl(google::protobuf::Message&, google::protobuf::Message const&)
aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/descriptor.pb.cc
void GeneratedCodeInfo_Annotation::MergeImpl(::PROTOBUF_NAMESPACE_ID::Message& to_msg, const ::PROTOBUF_NAMESPACE_ID::Message& from_msg) { auto* const _this = static_cast<GeneratedCodeInfo_Annotation*>(&to_msg); auto& from = static_cast<const GeneratedCodeInfo_Annotation&>(from_msg); // @@protoc_insertion_point(class_specific_merge_from_start:google.protobuf.GeneratedCodeInfo.Annotation) GOOGLE_DCHECK_NE(&from, _this); uint32_t cached_has_bits = 0; (void) cached_has_bits; _this->_impl_.path_.MergeFrom(from._impl_.path_); cached_has_bits = from._impl_._has_bits_[0]; if (cached_has_bits & 0x00000007u) { if (cached_has_bits & 0x00000001u) { _this->_internal_set_source_file(from._internal_source_file()); } if (cached_has_bits & 0x00000002u) { _this->_impl_.begin_ = from._impl_.begin_; } if (cached_has_bits & 0x00000004u) { _this->_impl_.end_ = from._impl_.end_; } _this->_impl_._has_bits_[0] |= cached_has_bits; } _this->_internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_); }
O3
cpp
google::protobuf::GeneratedCodeInfo_Annotation::MergeImpl(google::protobuf::Message&, google::protobuf::Message const&): pushq %rbp pushq %r15 pushq %r14 pushq %rbx pushq %rax movq %rsi, %r14 movq %rdi, %rbx movl 0x18(%rsi), %esi testl %esi, %esi je 0xf9b89 leaq 0x18(%rbx), %rdi movslq 0x18(%rbx), %r15 addl %r15d, %esi callq 0x7f560 movl 0x18(%r14), %eax addl %eax, 0x18(%rbx) shlq $0x2, %r15 addq 0x20(%rbx), %r15 movq 0x20(%r14), %rsi movslq 0x18(%r14), %rdx shlq $0x2, %rdx movq %r15, %rdi callq 0x2ceb0 movl 0x10(%r14), %ebp testb $0x7, %bpl je 0xf9bda testb $0x1, %bpl je 0xf9bbd movq 0x30(%r14), %rsi andq $-0x4, %rsi orl $0x1, 0x10(%rbx) leaq 0x30(%rbx), %rdi movq 0x8(%rbx), %rax movq %rax, %rdx andq $-0x4, %rdx testb $0x1, %al jne 0xf9c0d callq 0x786ce testb $0x2, %bpl je 0xf9bca movl 0x38(%r14), %eax movl %eax, 0x38(%rbx) testb $0x4, %bpl je 0xf9bd7 movl 0x3c(%r14), %eax movl %eax, 0x3c(%rbx) orl %ebp, 0x10(%rbx) movq 0x8(%r14), %rsi testb $0x1, %sil jne 0xf9bef addq $0x8, %rsp popq %rbx popq %r14 popq %r15 popq %rbp retq addq $0x8, %rbx andq $-0x4, %rsi addq $0x8, %rsi movq %rbx, %rdi addq $0x8, %rsp popq %rbx popq %r14 popq %r15 popq %rbp jmp 0x734be movq (%rdx), %rdx jmp 0xf9bb8
_ZN6google8protobuf28GeneratedCodeInfo_Annotation9MergeImplERNS0_7MessageERKS2_: push rbp push r15 push r14 push rbx push rax mov r14, rsi mov rbx, rdi mov esi, [rsi+18h] test esi, esi jz short loc_F9B89 lea rdi, [rbx+18h] movsxd r15, dword ptr [rbx+18h] add esi, r15d call _ZN6google8protobuf13RepeatedFieldIiE7ReserveEi; google::protobuf::RepeatedField<int>::Reserve(int) mov eax, [r14+18h] add [rbx+18h], eax shl r15, 2 add r15, [rbx+20h] mov rsi, [r14+20h] movsxd rdx, dword ptr [r14+18h] shl rdx, 2 mov rdi, r15 call _memcpy loc_F9B89: mov ebp, [r14+10h] test bpl, 7 jz short loc_F9BDA test bpl, 1 jz short loc_F9BBD mov rsi, [r14+30h] and rsi, 0FFFFFFFFFFFFFFFCh or dword ptr [rbx+10h], 1 lea rdi, [rbx+30h] mov rax, [rbx+8] mov rdx, rax and rdx, 0FFFFFFFFFFFFFFFCh test al, 1 jnz short loc_F9C0D loc_F9BB8: call _ZN6google8protobuf8internal14ArenaStringPtr3SetERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEPNS0_5ArenaE; google::protobuf::internal::ArenaStringPtr::Set(std::string const&,google::protobuf::Arena *) loc_F9BBD: test bpl, 2 jz short loc_F9BCA mov eax, [r14+38h] mov [rbx+38h], eax loc_F9BCA: test bpl, 4 jz short loc_F9BD7 mov eax, [r14+3Ch] mov [rbx+3Ch], eax loc_F9BD7: or [rbx+10h], ebp loc_F9BDA: mov rsi, [r14+8] test sil, 1 jnz short loc_F9BEF add rsp, 8 pop rbx pop r14 pop r15 pop rbp retn loc_F9BEF: add rbx, 8 and rsi, 0FFFFFFFFFFFFFFFCh add rsi, 8 mov rdi, rbx add rsp, 8 pop rbx pop r14 pop r15 pop rbp jmp _ZN6google8protobuf8internal16InternalMetadata11DoMergeFromINS0_15UnknownFieldSetEEEvRKT_; google::protobuf::internal::InternalMetadata::DoMergeFrom<google::protobuf::UnknownFieldSet>(google::protobuf::UnknownFieldSet const&) loc_F9C0D: mov rdx, [rdx] jmp short loc_F9BB8
long long google::protobuf::GeneratedCodeInfo_Annotation::MergeImpl( google::protobuf::GeneratedCodeInfo_Annotation *this, google::protobuf::Message *a2, const google::protobuf::Message *a3) { int v4; // esi long long v5; // r15 long long result; // rax int v7; // ebp unsigned long long v8; // rsi google::protobuf::Arena *v9; // rdx long long v10; // rsi v4 = *((_DWORD *)a2 + 6); if ( v4 ) { v5 = *((int *)this + 6); google::protobuf::RepeatedField<int>::Reserve((int *)this + 6, v5 + v4); *((_DWORD *)this + 6) += *((_DWORD *)a2 + 6); result = memcpy(*((_QWORD *)this + 4) + 4 * v5); } v7 = *((_DWORD *)a2 + 4); if ( (v7 & 7) != 0 ) { if ( (v7 & 1) != 0 ) { v8 = *((_QWORD *)a2 + 6) & 0xFFFFFFFFFFFFFFFCLL; *((_DWORD *)this + 4) |= 1u; v9 = (google::protobuf::Arena *)(*((_QWORD *)this + 1) & 0xFFFFFFFFFFFFFFFCLL); if ( (*((_QWORD *)this + 1) & 1) != 0 ) v9 = *(google::protobuf::Arena **)v9; result = google::protobuf::internal::ArenaStringPtr::Set((long long *)this + 6, v8, v9); } if ( (v7 & 2) != 0 ) { result = *((unsigned int *)a2 + 14); *((_DWORD *)this + 14) = result; } if ( (v7 & 4) != 0 ) { result = *((unsigned int *)a2 + 15); *((_DWORD *)this + 15) = result; } *((_DWORD *)this + 4) |= v7; } v10 = *((_QWORD *)a2 + 1); if ( (v10 & 1) != 0 ) return google::protobuf::internal::InternalMetadata::DoMergeFrom<google::protobuf::UnknownFieldSet>( (long long *)this + 1, (const google::protobuf::UnknownFieldSet *)((v10 & 0xFFFFFFFFFFFFFFFCLL) + 8)); return result; }
MergeImpl: PUSH RBP PUSH R15 PUSH R14 PUSH RBX PUSH RAX MOV R14,RSI MOV RBX,RDI MOV ESI,dword ptr [RSI + 0x18] TEST ESI,ESI JZ 0x001f9b89 LEA RDI,[RBX + 0x18] MOVSXD R15,dword ptr [RBX + 0x18] ADD ESI,R15D CALL 0x0017f560 MOV EAX,dword ptr [R14 + 0x18] ADD dword ptr [RBX + 0x18],EAX SHL R15,0x2 ADD R15,qword ptr [RBX + 0x20] MOV RSI,qword ptr [R14 + 0x20] MOVSXD RDX,dword ptr [R14 + 0x18] SHL RDX,0x2 MOV RDI,R15 CALL 0x0012ceb0 LAB_001f9b89: MOV EBP,dword ptr [R14 + 0x10] TEST BPL,0x7 JZ 0x001f9bda TEST BPL,0x1 JZ 0x001f9bbd MOV RSI,qword ptr [R14 + 0x30] AND RSI,-0x4 OR dword ptr [RBX + 0x10],0x1 LEA RDI,[RBX + 0x30] MOV RAX,qword ptr [RBX + 0x8] MOV RDX,RAX AND RDX,-0x4 TEST AL,0x1 JNZ 0x001f9c0d LAB_001f9bb8: CALL 0x001786ce LAB_001f9bbd: TEST BPL,0x2 JZ 0x001f9bca MOV EAX,dword ptr [R14 + 0x38] MOV dword ptr [RBX + 0x38],EAX LAB_001f9bca: TEST BPL,0x4 JZ 0x001f9bd7 MOV EAX,dword ptr [R14 + 0x3c] MOV dword ptr [RBX + 0x3c],EAX LAB_001f9bd7: OR dword ptr [RBX + 0x10],EBP LAB_001f9bda: MOV RSI,qword ptr [R14 + 0x8] TEST SIL,0x1 JNZ 0x001f9bef ADD RSP,0x8 POP RBX POP R14 POP R15 POP RBP RET LAB_001f9bef: ADD RBX,0x8 AND RSI,-0x4 ADD RSI,0x8 MOV RDI,RBX ADD RSP,0x8 POP RBX POP R14 POP R15 POP RBP JMP 0x001734be LAB_001f9c0d: MOV RDX,qword ptr [RDX] JMP 0x001f9bb8
/* google::protobuf::GeneratedCodeInfo_Annotation::MergeImpl(google::protobuf::Message&, google::protobuf::Message const&) */ void google::protobuf::GeneratedCodeInfo_Annotation::MergeImpl(Message *param_1,Message *param_2) { int iVar1; uint uVar2; ulong uVar3; Arena *pAVar4; if (*(int *)(param_2 + 0x18) != 0) { iVar1 = *(int *)(param_1 + 0x18); RepeatedField<int>::Reserve ((RepeatedField<int> *)(param_1 + 0x18),*(int *)(param_2 + 0x18) + iVar1); *(int *)(param_1 + 0x18) = *(int *)(param_1 + 0x18) + *(int *)(param_2 + 0x18); memcpy((void *)((long)iVar1 * 4 + *(long *)(param_1 + 0x20)),*(void **)(param_2 + 0x20), (long)*(int *)(param_2 + 0x18) << 2); } uVar2 = *(uint *)(param_2 + 0x10); if ((uVar2 & 7) != 0) { if ((uVar2 & 1) != 0) { uVar3 = *(ulong *)(param_2 + 0x30); *(uint *)(param_1 + 0x10) = *(uint *)(param_1 + 0x10) | 1; pAVar4 = (Arena *)(*(ulong *)(param_1 + 8) & 0xfffffffffffffffc); if ((*(ulong *)(param_1 + 8) & 1) != 0) { pAVar4 = *(Arena **)pAVar4; } internal::ArenaStringPtr::Set ((ArenaStringPtr *)(param_1 + 0x30),(string *)(uVar3 & 0xfffffffffffffffc),pAVar4); } if ((uVar2 & 2) != 0) { *(int4 *)(param_1 + 0x38) = *(int4 *)(param_2 + 0x38); } if ((uVar2 & 4) != 0) { *(int4 *)(param_1 + 0x3c) = *(int4 *)(param_2 + 0x3c); } *(uint *)(param_1 + 0x10) = *(uint *)(param_1 + 0x10) | uVar2; } if ((*(ulong *)(param_2 + 8) & 1) == 0) { return; } internal::InternalMetadata::DoMergeFrom<google::protobuf::UnknownFieldSet> ((InternalMetadata *)(param_1 + 8), (UnknownFieldSet *)((*(ulong *)(param_2 + 8) & 0xfffffffffffffffc) + 8)); return; }
47,427
my_wildcmp_unicode_impl
eloqsql/strings/ctype-utf8.c
static int my_wildcmp_unicode_impl(CHARSET_INFO *cs, const char *str,const char *str_end, const char *wildstr,const char *wildend, int escape, int w_one, int w_many, MY_UNICASE_INFO *weights, int recurse_level) { int result= -1; /* Not found, using wildcards */ my_wc_t s_wc, w_wc; int scan; my_charset_conv_mb_wc mb_wc= cs->cset->mb_wc; if (my_string_stack_guard && my_string_stack_guard(recurse_level)) return 1; while (wildstr != wildend) { while (1) { my_bool escaped= 0; if ((scan= mb_wc(cs, &w_wc, (const uchar*)wildstr, (const uchar*)wildend)) <= 0) return 1; if (w_wc == (my_wc_t) w_many) { result= 1; /* Found an anchor char */ break; } wildstr+= scan; if (w_wc == (my_wc_t) escape && wildstr < wildend) { if ((scan= mb_wc(cs, &w_wc, (const uchar*)wildstr, (const uchar*)wildend)) <= 0) return 1; wildstr+= scan; escaped= 1; } if ((scan= mb_wc(cs, &s_wc, (const uchar*)str, (const uchar*)str_end)) <= 0) return 1; str+= scan; if (!escaped && w_wc == (my_wc_t) w_one) { result= 1; /* Found an anchor char */ } else { if (weights) { my_tosort_unicode(weights, &s_wc, cs->state); my_tosort_unicode(weights, &w_wc, cs->state); } if (s_wc != w_wc) return 1; /* No match */ } if (wildstr == wildend) return (str != str_end); /* Match if both are at end */ } if (w_wc == (my_wc_t) w_many) { /* Found w_many */ /* Remove any '%' and '_' from the wild search string */ for ( ; wildstr != wildend ; ) { if ((scan= mb_wc(cs, &w_wc, (const uchar*)wildstr, (const uchar*)wildend)) <= 0) return 1; if (w_wc == (my_wc_t) w_many) { wildstr+= scan; continue; } if (w_wc == (my_wc_t) w_one) { wildstr+= scan; if ((scan= mb_wc(cs, &s_wc, (const uchar*)str, (const uchar*)str_end)) <= 0) return 1; str+= scan; continue; } break; /* Not a wild character */ } if (wildstr == wildend) return 0; /* Ok if w_many is last */ if (str == str_end) return -1; if ((scan= mb_wc(cs, &w_wc, (const uchar*)wildstr, (const uchar*)wildend)) <= 0) return 1; wildstr+= scan; if (w_wc == (my_wc_t) escape) { if (wildstr < wildend) { if ((scan= mb_wc(cs, &w_wc, (const uchar*)wildstr, (const uchar*)wildend)) <= 0) return 1; wildstr+= scan; } } while (1) { /* Skip until the first character from wildstr is found */ while (str != str_end) { if ((scan= mb_wc(cs, &s_wc, (const uchar*)str, (const uchar*)str_end)) <= 0) return 1; if (weights) { my_tosort_unicode(weights, &s_wc, cs->state); my_tosort_unicode(weights, &w_wc, cs->state); } if (s_wc == w_wc) break; str+= scan; } if (str == str_end) return -1; str+= scan; result= my_wildcmp_unicode_impl(cs, str, str_end, wildstr, wildend, escape, w_one, w_many, weights, recurse_level + 1); if (result <= 0) return result; } } } return (str != str_end ? 1 : 0); }
O3
c
my_wildcmp_unicode_impl: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x58, %rsp movl %r9d, -0x54(%rbp) movq %r8, %r12 movq %rcx, %r13 movq %rdx, -0x50(%rbp) movq %rsi, -0x38(%rbp) movq %rdi, %r15 movl 0x28(%rbp), %eax movq %rax, -0x60(%rbp) movq 0xb8(%rdi), %rax movq 0x28(%rax), %rax movq %rax, -0x40(%rbp) leaq 0xb6d0ef(%rip), %rax # 0xc5ced8 movq (%rax), %rax testq %rax, %rax je 0xefe03 movl 0x28(%rbp), %edi callq *%rax movl $0x1, %ebx testl %eax, %eax jne 0xf0193 cmpq %r12, %r13 je 0xeff92 movl 0x18(%rbp), %eax movl 0x10(%rbp), %ecx cltq movq %rax, -0x78(%rbp) movslq -0x54(%rbp), %rax movq %rax, -0x70(%rbp) movslq %ecx, %rax movq %rax, -0x68(%rbp) movq %r15, %rdi leaq -0x30(%rbp), %rsi movq %r13, %rdx movq %r12, %rcx movq -0x40(%rbp), %r14 callq *%r14 testl %eax, %eax jle 0xf018e movq -0x30(%rbp), %rcx cmpq -0x78(%rbp), %rcx je 0xeffa4 movl %eax, %eax addq %rax, %r13 cmpq -0x70(%rbp), %rcx jne 0xefeaa cmpq %r12, %r13 jae 0xefeaa movq %r15, %rdi leaq -0x30(%rbp), %rsi movq %r13, %rdx movq %r12, %rcx callq *%r14 testl %eax, %eax jle 0xf018e movl %eax, %ebx movq %r15, %rdi leaq -0x48(%rbp), %rsi movq %r14, %rax movq -0x38(%rbp), %r14 movq %r14, %rdx movq -0x50(%rbp), %rcx callq *%rax testl %eax, %eax jle 0xf018e movl %ebx, %ecx addq %rcx, %r13 movl %eax, %eax addq %rax, %r14 movq %r14, -0x38(%rbp) jmp 0xefede movq %r15, %rdi leaq -0x48(%rbp), %rsi movq -0x38(%rbp), %rbx movq %rbx, %rdx movq -0x50(%rbp), %rcx callq *%r14 testl %eax, %eax jle 0xf018e movl %eax, %eax addq %rax, %rbx movq %rbx, -0x38(%rbp) movq -0x68(%rbp), %rax cmpq %rax, -0x30(%rbp) je 0xeff89 movq -0x48(%rbp), %rax movq 0x20(%rbp), %r8 testq %r8, %r8 je 0xeff77 movl 0xc(%r15), %ecx movq (%r8), %rdx movl $0xfffd, %esi # imm = 0xFFFD cmpq %rdx, %rax ja 0xeff2c movq 0x8(%r8), %rsi movq %rax, %rdi shrq $0x8, %rdi movq (%rsi,%rdi,8), %rsi testq %rsi, %rsi je 0xeff33 xorl %edi, %edi testw %cx, %cx setns %dil movzbl %al, %eax leaq (%rax,%rax,2), %rax leaq (%rsi,%rax,4), %rax movl 0x4(%rax,%rdi,4), %esi movq %rsi, -0x48(%rbp) movq %rsi, %rax movq -0x30(%rbp), %rsi movl $0xfffd, %edi # imm = 0xFFFD cmpq %rdx, %rsi ja 0xeff6e movq 0x8(%r8), %rdx movq %rsi, %rdi shrq $0x8, %rdi movq (%rdx,%rdi,8), %rdx testq %rdx, %rdx je 0xeff7b xorl %edi, %edi testw %cx, %cx setns %dil movzbl %sil, %ecx leaq (%rcx,%rcx,2), %rcx leaq (%rdx,%rcx,4), %rcx movl 0x4(%rcx,%rdi,4), %edi movq %rdi, -0x30(%rbp) movq %rdi, %rsi jmp 0xeff7b movq -0x30(%rbp), %rsi movl $0x1, %ebx cmpq %rsi, %rax jne 0xf0193 cmpq %r12, %r13 jne 0xefe27 xorl %ebx, %ebx movq -0x50(%rbp), %rax cmpq %rax, -0x38(%rbp) setne %bl jmp 0xf0193 xorl %ebx, %ebx cmpq %r12, %r13 je 0xf0193 movq %r15, %rdi leaq -0x30(%rbp), %rsi movq %r13, %rdx movq %r12, %rcx callq *%r14 testl %eax, %eax jle 0xf018e movl %eax, %r14d movq -0x30(%rbp), %rax cmpq -0x78(%rbp), %rax jne 0xeffe8 movl %r14d, %eax addq %rax, %r13 cmpq %r12, %r13 movq -0x40(%rbp), %r14 jne 0xeffaf jmp 0xf0193 cmpq -0x68(%rbp), %rax jne 0xf0016 movq %r15, %rdi leaq -0x48(%rbp), %rsi movq -0x38(%rbp), %rdx movq -0x50(%rbp), %rcx callq *-0x40(%rbp) testl %eax, %eax jle 0xf018e movl %r14d, %ecx addq %rcx, %r13 movl %eax, %eax addq %rax, -0x38(%rbp) jmp 0xeffda movq -0x50(%rbp), %r14 cmpq %r14, -0x38(%rbp) je 0xf01a4 leaq -0x30(%rbp), %rsi movq %r15, %rdi movq %r13, %rdx movq %r12, %rcx callq *-0x40(%rbp) testl %eax, %eax jle 0xf018e movl %eax, %eax addq %rax, %r13 movq -0x70(%rbp), %rax cmpq %rax, -0x30(%rbp) jne 0xf006d cmpq %r12, %r13 jae 0xf006d leaq -0x30(%rbp), %rsi movq %r15, %rdi movq %r13, %rdx movq %r12, %rcx callq *-0x40(%rbp) testl %eax, %eax jle 0xf018e movl %eax, %eax addq %rax, %r13 movq -0x60(%rbp), %rax incl %eax movq %rax, -0x60(%rbp) movq -0x38(%rbp), %rbx cmpq %r14, %rbx je 0xf01a4 movq %r15, %rdi leaq -0x48(%rbp), %rsi movq %rbx, %rdx movq %r14, %rcx callq *-0x40(%rbp) testl %eax, %eax jle 0xf018e movq -0x48(%rbp), %rcx movq 0x20(%rbp), %rsi testq %rsi, %rsi je 0xf0142 movl 0xc(%r15), %edx movq (%rsi), %rsi movl $0xfffd, %edi # imm = 0xFFFD cmpq %rsi, %rcx ja 0xf00f0 movq 0x20(%rbp), %rdi movq 0x8(%rdi), %rdi movq %rcx, %r8 shrq $0x8, %r8 movq (%rdi,%r8,8), %rdi testq %rdi, %rdi je 0xf00f7 xorl %r8d, %r8d testw %dx, %dx setns %r8b movzbl %cl, %ecx leaq (%rcx,%rcx,2), %rcx leaq (%rdi,%rcx,4), %rcx movl 0x4(%rcx,%r8,4), %edi movq %rdi, -0x48(%rbp) movq %rdi, %rcx movq -0x30(%rbp), %rdi movl $0xfffd, %r8d # imm = 0xFFFD cmpq %rsi, %rdi ja 0xf0139 movq 0x20(%rbp), %rsi movq 0x8(%rsi), %rsi movq %rdi, %r8 shrq $0x8, %r8 movq (%rsi,%r8,8), %rsi testq %rsi, %rsi je 0xf0146 xorl %r8d, %r8d testw %dx, %dx setns %r8b movzbl %dil, %edx leaq (%rdx,%rdx,2), %rdx leaq (%rsi,%rdx,4), %rdx movl 0x4(%rdx,%r8,4), %r8d movq %r8, -0x30(%rbp) movq %r8, %rdi jmp 0xf0146 movq -0x30(%rbp), %rdi movl %eax, %eax addq %rax, %rbx cmpq %rdi, %rcx jne 0xf007b movq %r15, %rdi movq %rbx, -0x38(%rbp) movq %rbx, %rsi movq %r14, %rdx movq %r13, %rcx movq %r12, %r8 movl -0x54(%rbp), %r9d pushq -0x60(%rbp) pushq 0x20(%rbp) movl 0x18(%rbp), %eax pushq %rax movl 0x10(%rbp), %eax pushq %rax callq 0xefda6 addq $0x20, %rsp movl %eax, %ebx testl %eax, %eax jg 0xf0077 jmp 0xf0193 movl $0x1, %ebx movl %ebx, %eax addq $0x58, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq movl $0xffffffff, %ebx # imm = 0xFFFFFFFF jmp 0xf0193
my_wildcmp_unicode_impl: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx sub rsp, 58h mov [rbp+var_54], r9d mov r12, r8 mov r13, rcx mov [rbp+var_50], rdx mov [rbp+var_38], rsi mov r15, rdi mov eax, [rbp+arg_18] mov [rbp+var_60], rax mov rax, [rdi+0B8h] mov rax, [rax+28h] mov [rbp+var_40], rax lea rax, my_string_stack_guard mov rax, [rax] test rax, rax jz short loc_EFE03 mov edi, [rbp+arg_18] call rax mov ebx, 1 test eax, eax jnz loc_F0193 loc_EFE03: cmp r13, r12 jz loc_EFF92 mov eax, [rbp+arg_8] mov ecx, [rbp+arg_0] cdqe mov [rbp+var_78], rax movsxd rax, [rbp+var_54] mov [rbp+var_70], rax movsxd rax, ecx mov [rbp+var_68], rax loc_EFE27: mov rdi, r15 lea rsi, [rbp+var_30] mov rdx, r13 mov rcx, r12 mov r14, [rbp+var_40] call r14 test eax, eax jle loc_F018E mov rcx, [rbp+var_30] cmp rcx, [rbp+var_78] jz loc_EFFA4 mov eax, eax add r13, rax cmp rcx, [rbp+var_70] jnz short loc_EFEAA cmp r13, r12 jnb short loc_EFEAA mov rdi, r15 lea rsi, [rbp+var_30] mov rdx, r13 mov rcx, r12 call r14 test eax, eax jle loc_F018E mov ebx, eax mov rdi, r15 lea rsi, [rbp+var_48] mov rax, r14 mov r14, [rbp+var_38] mov rdx, r14 mov rcx, [rbp+var_50] call rax test eax, eax jle loc_F018E mov ecx, ebx add r13, rcx mov eax, eax add r14, rax mov [rbp+var_38], r14 jmp short loc_EFEDE loc_EFEAA: mov rdi, r15 lea rsi, [rbp+var_48] mov rbx, [rbp+var_38] mov rdx, rbx mov rcx, [rbp+var_50] call r14 test eax, eax jle loc_F018E mov eax, eax add rbx, rax mov [rbp+var_38], rbx mov rax, [rbp+var_68] cmp [rbp+var_30], rax jz loc_EFF89 loc_EFEDE: mov rax, [rbp+var_48] mov r8, [rbp+arg_10] test r8, r8 jz loc_EFF77 mov ecx, [r15+0Ch] mov rdx, [r8] mov esi, 0FFFDh cmp rax, rdx ja short loc_EFF2C mov rsi, [r8+8] mov rdi, rax shr rdi, 8 mov rsi, [rsi+rdi*8] test rsi, rsi jz short loc_EFF33 xor edi, edi test cx, cx setns dil movzx eax, al lea rax, [rax+rax*2] lea rax, [rsi+rax*4] mov esi, [rax+rdi*4+4] loc_EFF2C: mov [rbp+var_48], rsi mov rax, rsi loc_EFF33: mov rsi, [rbp+var_30] mov edi, 0FFFDh cmp rsi, rdx ja short loc_EFF6E mov rdx, [r8+8] mov rdi, rsi shr rdi, 8 mov rdx, [rdx+rdi*8] test rdx, rdx jz short loc_EFF7B xor edi, edi test cx, cx setns dil movzx ecx, sil lea rcx, [rcx+rcx*2] lea rcx, [rdx+rcx*4] mov edi, [rcx+rdi*4+4] loc_EFF6E: mov [rbp+var_30], rdi mov rsi, rdi jmp short loc_EFF7B loc_EFF77: mov rsi, [rbp+var_30] loc_EFF7B: mov ebx, 1 cmp rax, rsi jnz loc_F0193 loc_EFF89: cmp r13, r12 jnz loc_EFE27 loc_EFF92: xor ebx, ebx mov rax, [rbp+var_50] cmp [rbp+var_38], rax setnz bl jmp loc_F0193 loc_EFFA4: xor ebx, ebx cmp r13, r12 jz loc_F0193 loc_EFFAF: mov rdi, r15 lea rsi, [rbp+var_30] mov rdx, r13 mov rcx, r12 call r14 test eax, eax jle loc_F018E mov r14d, eax mov rax, [rbp+var_30] cmp rax, [rbp+var_78] jnz short loc_EFFE8 mov eax, r14d add r13, rax loc_EFFDA: cmp r13, r12 mov r14, [rbp+var_40] jnz short loc_EFFAF jmp loc_F0193 loc_EFFE8: cmp rax, [rbp+var_68] jnz short loc_F0016 mov rdi, r15 lea rsi, [rbp+var_48] mov rdx, [rbp+var_38] mov rcx, [rbp+var_50] call [rbp+var_40] loc_F0000: test eax, eax jle loc_F018E mov ecx, r14d add r13, rcx mov eax, eax add [rbp+var_38], rax jmp short loc_EFFDA loc_F0016: mov r14, [rbp+var_50] cmp [rbp+var_38], r14 jz loc_F01A4 lea rsi, [rbp+var_30] mov rdi, r15 mov rdx, r13 mov rcx, r12 call [rbp+var_40] test eax, eax jle loc_F018E mov eax, eax add r13, rax mov rax, [rbp+var_70] cmp [rbp+var_30], rax jnz short loc_F006D cmp r13, r12 jnb short loc_F006D lea rsi, [rbp+var_30] mov rdi, r15 mov rdx, r13 mov rcx, r12 call [rbp+var_40] test eax, eax jle loc_F018E mov eax, eax add r13, rax loc_F006D: mov rax, [rbp+var_60] inc eax mov [rbp+var_60], rax loc_F0077: mov rbx, [rbp+var_38] loc_F007B: cmp rbx, r14 jz loc_F01A4 mov rdi, r15 lea rsi, [rbp+var_48] mov rdx, rbx mov rcx, r14 call [rbp+var_40] test eax, eax jle loc_F018E mov rcx, [rbp+var_48] mov rsi, [rbp+arg_10] test rsi, rsi jz loc_F0142 mov edx, [r15+0Ch] mov rsi, [rsi] mov edi, 0FFFDh cmp rcx, rsi ja short loc_F00F0 mov rdi, [rbp+arg_10] mov rdi, [rdi+8] mov r8, rcx shr r8, 8 mov rdi, [rdi+r8*8] test rdi, rdi jz short loc_F00F7 xor r8d, r8d test dx, dx setns r8b movzx ecx, cl lea rcx, [rcx+rcx*2] lea rcx, [rdi+rcx*4] mov edi, [rcx+r8*4+4] loc_F00F0: mov [rbp+var_48], rdi mov rcx, rdi loc_F00F7: mov rdi, [rbp+var_30] mov r8d, 0FFFDh cmp rdi, rsi ja short loc_F0139 mov rsi, [rbp+arg_10] mov rsi, [rsi+8] mov r8, rdi shr r8, 8 mov rsi, [rsi+r8*8] test rsi, rsi jz short loc_F0146 xor r8d, r8d test dx, dx setns r8b movzx edx, dil lea rdx, [rdx+rdx*2] lea rdx, [rsi+rdx*4] mov r8d, [rdx+r8*4+4] loc_F0139: mov [rbp+var_30], r8 mov rdi, r8 jmp short loc_F0146 loc_F0142: mov rdi, [rbp+var_30] loc_F0146: mov eax, eax add rbx, rax cmp rcx, rdi jnz loc_F007B mov rdi, r15 mov [rbp+var_38], rbx mov rsi, rbx mov rdx, r14 mov rcx, r13 mov r8, r12 mov r9d, [rbp+var_54] push [rbp+var_60] push [rbp+arg_10] mov eax, [rbp+arg_8] push rax mov eax, [rbp+arg_0] push rax call my_wildcmp_unicode_impl add rsp, 20h mov ebx, eax test eax, eax jg loc_F0077 jmp short loc_F0193 loc_F018E: mov ebx, 1 loc_F0193: mov eax, ebx add rsp, 58h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn loc_F01A4: mov ebx, 0FFFFFFFFh jmp short loc_F0193
long long my_wildcmp_unicode_impl( long long a1, long long a2, unsigned long long a3, unsigned long long a4, unsigned long long a5, int a6, int a7, int a8, unsigned long long *a9, unsigned int a10) { unsigned int v13; // ebx long long ( *v14)(long long, unsigned __int8 *, unsigned long long, unsigned long long); // r14 int v15; // eax int v16; // eax unsigned int v17; // ebx long long ( *v18)(long long, unsigned long long *, long long, long long); // rax long long v19; // r14 int v20; // eax long long v21; // rbx int v22; // eax long long v23; // rax int v24; // ecx unsigned long long v25; // rdx long long v26; // rsi long long v27; // rsi long long v28; // rsi long long v29; // rdi long long v30; // rdx int v31; // eax unsigned int v32; // r14d int v33; // eax int v34; // eax unsigned long long v35; // r13 int v36; // eax unsigned long long v37; // rbx int v38; // eax long long v39; // rcx int v40; // edx unsigned long long v41; // rsi long long v42; // rdi long long v43; // rdi long long v44; // rdi long long v45; // r8 long long v46; // rsi unsigned long long v50; // [rsp+38h] [rbp-48h] BYREF long long ( *v51)(long long, unsigned __int8 *, unsigned long long, unsigned long long); // [rsp+40h] [rbp-40h] long long v52; // [rsp+48h] [rbp-38h] unsigned __int8 v53[48]; // [rsp+50h] [rbp-30h] BYREF v52 = a2; v51 = *(long long ( **)(long long, unsigned __int8 *, unsigned long long, unsigned long long))(*(_QWORD *)(a1 + 184) + 40LL); if ( my_string_stack_guard ) { v13 = 1; if ( (unsigned int)my_string_stack_guard(a10) ) return v13; } if ( a4 == a5 ) return v52 != a3; while ( 1 ) { v14 = v51; v15 = v51(a1, v53, a4, a5); if ( v15 <= 0 ) return 1; if ( *(_QWORD *)v53 == a8 ) break; a4 += (unsigned int)v15; if ( *(_QWORD *)v53 == a6 && a4 < a5 ) { v16 = v14(a1, v53, a4, a5); if ( v16 <= 0 ) return 1; v17 = v16; v18 = (long long ( *)(long long, unsigned long long *, long long, long long))v14; v19 = v52; v20 = v18(a1, &v50, v52, a3); if ( v20 <= 0 ) return 1; a4 += v17; v52 = (unsigned int)v20 + v19; LABEL_13: v23 = v50; if ( a9 ) { v24 = *(_DWORD *)(a1 + 12); v25 = *a9; v26 = 65533LL; if ( v50 > *a9 ) goto LABEL_17; v27 = *(_QWORD *)(a9[1] + 8 * (v50 >> 8)); if ( v27 ) { v26 = *(unsigned int *)(v27 + 12LL * (unsigned __int8)v50 + 4LL * ((v24 & 0x8000u) == 0) + 4); LABEL_17: v50 = v26; v23 = v26; } v28 = *(_QWORD *)v53; v29 = 65533LL; if ( *(_QWORD *)v53 > v25 ) { LABEL_21: *(_QWORD *)v53 = v29; v28 = v29; } else { v30 = *(_QWORD *)(a9[1] + 8LL * (*(_QWORD *)v53 >> 8)); if ( v30 ) { v29 = *(unsigned int *)(v30 + 12LL * v53[0] + 4LL * ((v24 & 0x8000u) == 0) + 4); goto LABEL_21; } } } else { v28 = *(_QWORD *)v53; } v13 = 1; if ( v23 != v28 ) return v13; goto LABEL_24; } v21 = v52; v22 = v14(a1, (unsigned __int8 *)&v50, v52, a3); if ( v22 <= 0 ) return 1; v52 = (unsigned int)v22 + v21; if ( *(_QWORD *)v53 != a7 ) goto LABEL_13; LABEL_24: if ( a4 == a5 ) return v52 != a3; } v13 = 0; if ( a4 == a5 ) return v13; while ( 2 ) { v31 = v14(a1, v53, a4, a5); if ( v31 <= 0 ) return 1; v32 = v31; if ( *(_QWORD *)v53 == a8 ) { a4 += (unsigned int)v31; LABEL_30: v14 = v51; if ( a4 == a5 ) return v13; continue; } break; } if ( *(_QWORD *)v53 == a7 ) { v33 = v51(a1, (unsigned __int8 *)&v50, v52, a3); if ( v33 <= 0 ) return 1; a4 += v32; v52 += (unsigned int)v33; goto LABEL_30; } if ( v52 == a3 ) return (unsigned int)-1; v34 = v51(a1, v53, a4, a5); if ( v34 <= 0 ) return 1; v35 = (unsigned int)v34 + a4; if ( *(_QWORD *)v53 != a6 || v35 >= a5 ) { LABEL_41: v37 = v52; while ( 1 ) { if ( v37 == a3 ) return (unsigned int)-1; v38 = v51(a1, (unsigned __int8 *)&v50, v37, a3); if ( v38 <= 0 ) return 1; v39 = v50; if ( !a9 ) { v44 = *(_QWORD *)v53; goto LABEL_54; } v40 = *(_DWORD *)(a1 + 12); v41 = *a9; v42 = 65533LL; if ( v50 <= *a9 ) { v43 = *(_QWORD *)(a9[1] + 8 * (v50 >> 8)); if ( !v43 ) goto LABEL_49; v42 = *(unsigned int *)(v43 + 12LL * (unsigned __int8)v50 + 4LL * ((v40 & 0x8000u) == 0) + 4); } v50 = v42; v39 = v42; LABEL_49: v44 = *(_QWORD *)v53; v45 = 65533LL; if ( *(_QWORD *)v53 > v41 ) goto LABEL_52; v46 = *(_QWORD *)(a9[1] + 8LL * (*(_QWORD *)v53 >> 8)); if ( v46 ) { v45 = *(unsigned int *)(v46 + 12LL * v53[0] + 4LL * ((v40 & 0x8000u) == 0) + 4); LABEL_52: *(_QWORD *)v53 = v45; v44 = v45; } LABEL_54: v37 += (unsigned int)v38; if ( v39 == v44 ) { v52 = v37; v13 = my_wildcmp_unicode_impl(a1, v37, a3, v35, a5, a6, a7, a8, (long long)a9, a10 + 1); if ( (int)v13 > 0 ) goto LABEL_41; return v13; } } } v36 = v51(a1, v53, v35, a5); if ( v36 > 0 ) { LODWORD(v35) = v36 + v35; goto LABEL_41; } return 1; }
my_wildcmp_unicode_impl: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x58 MOV dword ptr [RBP + -0x54],R9D MOV R12,R8 MOV R13,RCX MOV qword ptr [RBP + -0x50],RDX MOV qword ptr [RBP + -0x38],RSI MOV R15,RDI MOV EAX,dword ptr [RBP + 0x28] MOV qword ptr [RBP + -0x60],RAX MOV RAX,qword ptr [RDI + 0xb8] MOV RAX,qword ptr [RAX + 0x28] MOV qword ptr [RBP + -0x40],RAX LEA RAX,[0xd5ced8] MOV RAX,qword ptr [RAX] TEST RAX,RAX JZ 0x001efe03 MOV EDI,dword ptr [RBP + 0x28] CALL RAX MOV EBX,0x1 TEST EAX,EAX JNZ 0x001f0193 LAB_001efe03: CMP R13,R12 JZ 0x001eff92 MOV EAX,dword ptr [RBP + 0x18] MOV ECX,dword ptr [RBP + 0x10] CDQE MOV qword ptr [RBP + -0x78],RAX MOVSXD RAX,dword ptr [RBP + -0x54] MOV qword ptr [RBP + -0x70],RAX MOVSXD RAX,ECX MOV qword ptr [RBP + -0x68],RAX LAB_001efe27: MOV RDI,R15 LEA RSI,[RBP + -0x30] MOV RDX,R13 MOV RCX,R12 MOV R14,qword ptr [RBP + -0x40] CALL R14 TEST EAX,EAX JLE 0x001f018e MOV RCX,qword ptr [RBP + -0x30] CMP RCX,qword ptr [RBP + -0x78] JZ 0x001effa4 MOV EAX,EAX ADD R13,RAX CMP RCX,qword ptr [RBP + -0x70] JNZ 0x001efeaa CMP R13,R12 JNC 0x001efeaa MOV RDI,R15 LEA RSI,[RBP + -0x30] MOV RDX,R13 MOV RCX,R12 CALL R14 TEST EAX,EAX JLE 0x001f018e MOV EBX,EAX MOV RDI,R15 LEA RSI,[RBP + -0x48] MOV RAX,R14 MOV R14,qword ptr [RBP + -0x38] MOV RDX,R14 MOV RCX,qword ptr [RBP + -0x50] CALL RAX TEST EAX,EAX JLE 0x001f018e MOV ECX,EBX ADD R13,RCX MOV EAX,EAX ADD R14,RAX MOV qword ptr [RBP + -0x38],R14 JMP 0x001efede LAB_001efeaa: MOV RDI,R15 LEA RSI,[RBP + -0x48] MOV RBX,qword ptr [RBP + -0x38] MOV RDX,RBX MOV RCX,qword ptr [RBP + -0x50] CALL R14 TEST EAX,EAX JLE 0x001f018e MOV EAX,EAX ADD RBX,RAX MOV qword ptr [RBP + -0x38],RBX MOV RAX,qword ptr [RBP + -0x68] CMP qword ptr [RBP + -0x30],RAX JZ 0x001eff89 LAB_001efede: MOV RAX,qword ptr [RBP + -0x48] MOV R8,qword ptr [RBP + 0x20] TEST R8,R8 JZ 0x001eff77 MOV ECX,dword ptr [R15 + 0xc] MOV RDX,qword ptr [R8] MOV ESI,0xfffd CMP RAX,RDX JA 0x001eff2c MOV RSI,qword ptr [R8 + 0x8] MOV RDI,RAX SHR RDI,0x8 MOV RSI,qword ptr [RSI + RDI*0x8] TEST RSI,RSI JZ 0x001eff33 XOR EDI,EDI TEST CX,CX SETNS DIL MOVZX EAX,AL LEA RAX,[RAX + RAX*0x2] LEA RAX,[RSI + RAX*0x4] MOV ESI,dword ptr [RAX + RDI*0x4 + 0x4] LAB_001eff2c: MOV qword ptr [RBP + -0x48],RSI MOV RAX,RSI LAB_001eff33: MOV RSI,qword ptr [RBP + -0x30] MOV EDI,0xfffd CMP RSI,RDX JA 0x001eff6e MOV RDX,qword ptr [R8 + 0x8] MOV RDI,RSI SHR RDI,0x8 MOV RDX,qword ptr [RDX + RDI*0x8] TEST RDX,RDX JZ 0x001eff7b XOR EDI,EDI TEST CX,CX SETNS DIL MOVZX ECX,SIL LEA RCX,[RCX + RCX*0x2] LEA RCX,[RDX + RCX*0x4] MOV EDI,dword ptr [RCX + RDI*0x4 + 0x4] LAB_001eff6e: MOV qword ptr [RBP + -0x30],RDI MOV RSI,RDI JMP 0x001eff7b LAB_001eff77: MOV RSI,qword ptr [RBP + -0x30] LAB_001eff7b: MOV EBX,0x1 CMP RAX,RSI JNZ 0x001f0193 LAB_001eff89: CMP R13,R12 JNZ 0x001efe27 LAB_001eff92: XOR EBX,EBX MOV RAX,qword ptr [RBP + -0x50] CMP qword ptr [RBP + -0x38],RAX SETNZ BL JMP 0x001f0193 LAB_001effa4: XOR EBX,EBX CMP R13,R12 JZ 0x001f0193 LAB_001effaf: MOV RDI,R15 LEA RSI,[RBP + -0x30] MOV RDX,R13 MOV RCX,R12 CALL R14 TEST EAX,EAX JLE 0x001f018e MOV R14D,EAX MOV RAX,qword ptr [RBP + -0x30] CMP RAX,qword ptr [RBP + -0x78] JNZ 0x001effe8 MOV EAX,R14D ADD R13,RAX LAB_001effda: CMP R13,R12 MOV R14,qword ptr [RBP + -0x40] JNZ 0x001effaf JMP 0x001f0193 LAB_001effe8: CMP RAX,qword ptr [RBP + -0x68] JNZ 0x001f0016 MOV RDI,R15 LEA RSI,[RBP + -0x48] MOV RDX,qword ptr [RBP + -0x38] MOV RCX,qword ptr [RBP + -0x50] CALL qword ptr [RBP + -0x40] TEST EAX,EAX JLE 0x001f018e MOV ECX,R14D ADD R13,RCX MOV EAX,EAX ADD qword ptr [RBP + -0x38],RAX JMP 0x001effda LAB_001f0016: MOV R14,qword ptr [RBP + -0x50] CMP qword ptr [RBP + -0x38],R14 JZ 0x001f01a4 LEA RSI,[RBP + -0x30] MOV RDI,R15 MOV RDX,R13 MOV RCX,R12 CALL qword ptr [RBP + -0x40] TEST EAX,EAX JLE 0x001f018e MOV EAX,EAX ADD R13,RAX MOV RAX,qword ptr [RBP + -0x70] CMP qword ptr [RBP + -0x30],RAX JNZ 0x001f006d CMP R13,R12 JNC 0x001f006d LEA RSI,[RBP + -0x30] MOV RDI,R15 MOV RDX,R13 MOV RCX,R12 CALL qword ptr [RBP + -0x40] TEST EAX,EAX JLE 0x001f018e MOV EAX,EAX ADD R13,RAX LAB_001f006d: MOV RAX,qword ptr [RBP + -0x60] INC EAX MOV qword ptr [RBP + -0x60],RAX LAB_001f0077: MOV RBX,qword ptr [RBP + -0x38] LAB_001f007b: CMP RBX,R14 JZ 0x001f01a4 MOV RDI,R15 LEA RSI,[RBP + -0x48] MOV RDX,RBX MOV RCX,R14 CALL qword ptr [RBP + -0x40] TEST EAX,EAX JLE 0x001f018e MOV RCX,qword ptr [RBP + -0x48] MOV RSI,qword ptr [RBP + 0x20] TEST RSI,RSI JZ 0x001f0142 MOV EDX,dword ptr [R15 + 0xc] MOV RSI,qword ptr [RSI] MOV EDI,0xfffd CMP RCX,RSI JA 0x001f00f0 MOV RDI,qword ptr [RBP + 0x20] MOV RDI,qword ptr [RDI + 0x8] MOV R8,RCX SHR R8,0x8 MOV RDI,qword ptr [RDI + R8*0x8] TEST RDI,RDI JZ 0x001f00f7 XOR R8D,R8D TEST DX,DX SETNS R8B MOVZX ECX,CL LEA RCX,[RCX + RCX*0x2] LEA RCX,[RDI + RCX*0x4] MOV EDI,dword ptr [RCX + R8*0x4 + 0x4] LAB_001f00f0: MOV qword ptr [RBP + -0x48],RDI MOV RCX,RDI LAB_001f00f7: MOV RDI,qword ptr [RBP + -0x30] MOV R8D,0xfffd CMP RDI,RSI JA 0x001f0139 MOV RSI,qword ptr [RBP + 0x20] MOV RSI,qword ptr [RSI + 0x8] MOV R8,RDI SHR R8,0x8 MOV RSI,qword ptr [RSI + R8*0x8] TEST RSI,RSI JZ 0x001f0146 XOR R8D,R8D TEST DX,DX SETNS R8B MOVZX EDX,DIL LEA RDX,[RDX + RDX*0x2] LEA RDX,[RSI + RDX*0x4] MOV R8D,dword ptr [RDX + R8*0x4 + 0x4] LAB_001f0139: MOV qword ptr [RBP + -0x30],R8 MOV RDI,R8 JMP 0x001f0146 LAB_001f0142: MOV RDI,qword ptr [RBP + -0x30] LAB_001f0146: MOV EAX,EAX ADD RBX,RAX CMP RCX,RDI JNZ 0x001f007b MOV RDI,R15 MOV qword ptr [RBP + -0x38],RBX MOV RSI,RBX MOV RDX,R14 MOV RCX,R13 MOV R8,R12 MOV R9D,dword ptr [RBP + -0x54] PUSH qword ptr [RBP + -0x60] PUSH qword ptr [RBP + 0x20] MOV EAX,dword ptr [RBP + 0x18] PUSH RAX MOV EAX,dword ptr [RBP + 0x10] PUSH RAX CALL 0x001efda6 ADD RSP,0x20 MOV EBX,EAX TEST EAX,EAX JG 0x001f0077 JMP 0x001f0193 LAB_001f018e: MOV EBX,0x1 LAB_001f0193: MOV EAX,EBX ADD RSP,0x58 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET LAB_001f01a4: MOV EBX,0xffffffff JMP 0x001f0193
uint my_wildcmp_unicode_impl (long param_1,long param_2,long param_3,ulong param_4,ulong param_5,int param_6, int param_7,int param_8,ulong *param_9,int param_10) { long lVar1; code *pcVar2; ulong uVar3; int iVar4; uint uVar5; uint uVar6; short sVar7; long lVar8; ulong local_50; code *local_48; long local_40; ulong local_38; local_48 = *(code **)(*(long *)(param_1 + 0xb8) + 0x28); local_40 = param_2; if ((my_string_stack_guard != (code *)0x0) && (iVar4 = (*my_string_stack_guard)(param_10), iVar4 != 0)) { return 1; } if (param_4 != param_5) { do { pcVar2 = local_48; uVar5 = (*local_48)(param_1,&local_38,param_4,param_5); lVar8 = local_40; if ((int)uVar5 < 1) { return 1; } if (local_38 == (long)param_8) { do { if (param_4 == param_5) { return 0; } uVar5 = (*pcVar2)(param_1,&local_38,param_4,param_5); if ((int)uVar5 < 1) { return 1; } if (local_38 != (long)param_8) { if (local_38 != (long)param_7) { if (local_40 == param_3) { return 0xffffffff; } uVar5 = (*local_48)(param_1,&local_38,param_4,param_5); if (0 < (int)uVar5) { param_4 = param_4 + uVar5; if ((local_38 == (long)param_6) && (param_4 < param_5)) { uVar5 = (*local_48)(param_1,&local_38,param_4,param_5); if ((int)uVar5 < 1) { return 1; } param_4 = param_4 + uVar5; } lVar8 = local_40; while( true ) { if (lVar8 == param_3) { return 0xffffffff; } uVar5 = (*local_48)(param_1,&local_50,lVar8,param_3); if ((int)uVar5 < 1) break; uVar3 = local_38; if (param_9 != (ulong *)0x0) { sVar7 = (short)*(int4 *)(param_1 + 0xc); uVar3 = 0xfffd; if ((local_50 <= *param_9) && (lVar1 = *(long *)(param_9[1] + (local_50 >> 8) * 8), uVar3 = local_50, lVar1 != 0)) { uVar3 = (ulong)*(uint *)(lVar1 + (local_50 & 0xff) * 0xc + 4 + (ulong)(-1 < sVar7) * 4); } local_50 = uVar3; uVar3 = 0xfffd; if ((local_38 <= *param_9) && (lVar1 = *(long *)(param_9[1] + (local_38 >> 8) * 8), uVar3 = local_38, lVar1 != 0)) { uVar3 = (ulong)*(uint *)(lVar1 + (local_38 & 0xff) * 0xc + 4 + (ulong)(-1 < sVar7) * 4); } } local_38 = uVar3; lVar8 = lVar8 + (ulong)uVar5; if ((local_50 == local_38) && (local_40 = lVar8, uVar5 = my_wildcmp_unicode_impl (param_1,lVar8,param_3,param_4,param_5,param_6,param_7, param_8,param_9,param_10 + 1), lVar8 = local_40, (int)uVar5 < 1)) { return uVar5; } } return 1; } return 1; } uVar6 = (*local_48)(param_1,&local_50,local_40,param_3); if ((int)uVar6 < 1) { return 1; } local_40 = local_40 + (ulong)uVar6; } param_4 = param_4 + uVar5; pcVar2 = local_48; } while( true ); } param_4 = param_4 + uVar5; if ((local_38 == (long)param_6) && (param_4 < param_5)) { uVar5 = (*pcVar2)(param_1,&local_38,param_4,param_5); lVar8 = local_40; if ((int)uVar5 < 1) { return 1; } uVar6 = (*pcVar2)(param_1,&local_50,local_40,param_3); if ((int)uVar6 < 1) { return 1; } param_4 = param_4 + uVar5; local_40 = lVar8 + (ulong)uVar6; LAB_001efede: uVar3 = local_38; if (param_9 != (ulong *)0x0) { sVar7 = (short)*(int4 *)(param_1 + 0xc); uVar3 = 0xfffd; if ((local_50 <= *param_9) && (lVar8 = *(long *)(param_9[1] + (local_50 >> 8) * 8), uVar3 = local_50, lVar8 != 0)) { uVar3 = (ulong)*(uint *)(lVar8 + (local_50 & 0xff) * 0xc + 4 + (ulong)(-1 < sVar7) * 4); } local_50 = uVar3; uVar3 = 0xfffd; if ((local_38 <= *param_9) && (lVar8 = *(long *)(param_9[1] + (local_38 >> 8) * 8), uVar3 = local_38, lVar8 != 0)) { uVar3 = (ulong)*(uint *)(lVar8 + (local_38 & 0xff) * 0xc + 4 + (ulong)(-1 < sVar7) * 4); } } local_38 = uVar3; if (local_50 != local_38) { return 1; } } else { uVar5 = (*pcVar2)(param_1,&local_50,local_40,param_3); if ((int)uVar5 < 1) { return 1; } local_40 = lVar8 + (ulong)uVar5; if (local_38 != (long)param_7) goto LAB_001efede; } } while (param_4 != param_5); } return (uint)(local_40 != param_3); }
47,428
my_copy_fix_mb2_or_mb4
eloqsql/strings/ctype-ucs2.c
static size_t my_copy_fix_mb2_or_mb4(CHARSET_INFO *cs, char *dst, size_t dst_length, const char *src, size_t src_length, size_t nchars, MY_STRCOPY_STATUS *status) { size_t length2, src_offset= src_length % cs->mbminlen; my_char_copy_status_t padstatus; if (!src_offset) return my_copy_fix_mb(cs, dst, dst_length, src, src_length, nchars, status); if ((padstatus= my_copy_incomplete_char(cs, dst, dst_length, src, src_length, nchars, TRUE)) == MY_CHAR_COPY_ERROR) { status->m_source_end_pos= status->m_well_formed_error_pos= src; return 0; } length2= my_copy_fix_mb(cs, dst + cs->mbminlen, dst_length - cs->mbminlen, src + src_offset, src_length - src_offset, nchars - 1, status); if (padstatus == MY_CHAR_COPY_FIXED) status->m_well_formed_error_pos= src; return cs->mbminlen /* The left-padded character */ + length2; }
O3
c
my_copy_fix_mb2_or_mb4: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x38, %rsp movq %rcx, %r12 movq %rdx, %r10 movq %rsi, %rbx movq %rdi, %r14 movl 0x98(%rdi), %r13d movq %r8, %rax xorl %edx, %edx divq %r13 testq %rdx, %rdx je 0xc435d cmpq %r10, %r13 seta %al movq 0x10(%rbp), %rsi testq %r9, %r9 sete %cl orb %al, %cl jne 0xc43ec movq %rdx, %r15 movq %rsi, -0x38(%rbp) movq %r10, -0x40(%rbp) movq %r8, -0x48(%rbp) movq %r9, -0x50(%rbp) subq %rdx, %r13 movq %rbx, %rdi xorl %esi, %esi movq %r13, %rdx callq 0x292c0 addq %rbx, %r13 movq %r13, %rdi movq %r12, -0x58(%rbp) movq %r12, %rsi movq %r15, %rdx callq 0x29120 movl 0x98(%r14), %edx addq %rbx, %rdx movq 0xb8(%r14), %rax movq %r14, %rdi movq %rbx, %rsi callq *0xc0(%rax) movl 0x98(%r14), %r13d cmpl %r13d, %eax movl %eax, -0x2c(%rbp) jne 0xc437c movq -0x58(%rbp), %r12 movq -0x50(%rbp), %r9 movq -0x48(%rbp), %r8 movq -0x40(%rbp), %rdx movq -0x38(%rbp), %rsi jmp 0xc43b2 movq %r14, %rdi movq %rbx, %rsi movq %r10, %rdx movq %r12, %rcx addq $0x38, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp jmp 0xb3336 movq 0xb8(%r14), %rax leaq (%rbx,%r13), %rcx movl $0x3f, %esi movq %r14, %rdi movq %rbx, %rdx callq *0x30(%rax) cmpl 0x98(%r14), %eax movq -0x58(%rbp), %r12 movq -0x50(%rbp), %r9 movq -0x48(%rbp), %r8 movq -0x40(%rbp), %rdx movq -0x38(%rbp), %rsi jne 0xc43ec movl %eax, %eax addq %rax, %rbx subq %rax, %rdx leaq (%r12,%r15), %rcx subq %r15, %r8 decq %r9 movq %rsi, (%rsp) movq %r14, %rdi movq %rsi, %r15 movq %rbx, %rsi callq 0xb3336 cmpl %r13d, -0x2c(%rbp) je 0xc43e0 movq %r12, 0x8(%r15) movl 0x98(%r14), %ecx addq %rcx, %rax jmp 0xc43f5 movq %r12, 0x8(%rsi) movq %r12, (%rsi) xorl %eax, %eax addq $0x38, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
my_copy_fix_mb2_or_mb4: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx sub rsp, 38h mov r12, rcx mov r10, rdx mov rbx, rsi mov r14, rdi mov r13d, [rdi+98h] mov rax, r8 xor edx, edx div r13 test rdx, rdx jz loc_C435D cmp r13, r10 setnbe al mov rsi, [rbp+arg_0] test r9, r9 setz cl or cl, al jnz loc_C43EC mov r15, rdx mov [rbp+var_38], rsi mov [rbp+var_40], r10 mov [rbp+var_48], r8 mov [rbp+var_50], r9 sub r13, rdx mov rdi, rbx xor esi, esi mov rdx, r13 call _memset add r13, rbx mov rdi, r13 mov [rbp+var_58], r12 mov rsi, r12 mov rdx, r15 call _memmove mov edx, [r14+98h] add rdx, rbx mov rax, [r14+0B8h] mov rdi, r14 mov rsi, rbx call qword ptr [rax+0C0h] mov r13d, [r14+98h] cmp eax, r13d mov [rbp+var_2C], eax jnz short loc_C437C mov r12, [rbp+var_58] mov r9, [rbp+var_50] mov r8, [rbp+var_48] mov rdx, [rbp+var_40] mov rsi, [rbp+var_38] jmp short loc_C43B2 loc_C435D: mov rdi, r14 mov rsi, rbx mov rdx, r10 mov rcx, r12 add rsp, 38h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp jmp my_copy_fix_mb loc_C437C: mov rax, [r14+0B8h] lea rcx, [rbx+r13] mov esi, 3Fh ; '?' mov rdi, r14 mov rdx, rbx call qword ptr [rax+30h] cmp eax, [r14+98h] mov r12, [rbp+var_58] mov r9, [rbp+var_50] mov r8, [rbp+var_48] mov rdx, [rbp+var_40] mov rsi, [rbp+var_38] jnz short loc_C43EC loc_C43B2: mov eax, eax add rbx, rax sub rdx, rax lea rcx, [r12+r15] sub r8, r15 dec r9 mov [rsp+60h+var_60], rsi mov rdi, r14 mov r15, rsi mov rsi, rbx call my_copy_fix_mb cmp [rbp+var_2C], r13d jz short loc_C43E0 mov [r15+8], r12 loc_C43E0: mov ecx, [r14+98h] add rax, rcx jmp short loc_C43F5 loc_C43EC: mov [rsi+8], r12 mov [rsi], r12 xor eax, eax loc_C43F5: add rsp, 38h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
unsigned long long my_copy_fix_mb2_or_mb4( long long a1, long long a2, unsigned long long a3, long long a4, unsigned long long a5, long long a6, unsigned long long *a7) { unsigned long long v9; // r13 unsigned long long *v10; // rsi unsigned long long v11; // r15 unsigned long long v12; // r13 unsigned int v13; // eax long long v14; // r13 long long v15; // r9 unsigned long long v16; // r8 unsigned long long v17; // rdx unsigned long long fixed; // rax unsigned int v23; // [rsp+34h] [rbp-2Ch] v9 = *(unsigned int *)(a1 + 152); if ( !(a5 % v9) ) return my_copy_fix_mb(a1, a2, a3, a4, a5, a6, a7); v10 = a7; if ( v9 > a3 || a6 == 0 ) goto LABEL_10; v11 = a5 % *(unsigned int *)(a1 + 152); v12 = v9 - a5 % v9; memset(a2, 0LL, v12); memmove(a2 + v12, a4, v11); v13 = (*(long long ( **)(long long, long long, long long))(*(_QWORD *)(a1 + 184) + 192LL))( a1, a2, a2 + *(unsigned int *)(a1 + 152)); v14 = *(unsigned int *)(a1 + 152); v23 = v13; if ( v13 != (_DWORD)v14 ) { v13 = (*(long long ( **)(long long, long long, long long, long long))(*(_QWORD *)(a1 + 184) + 48LL))( a1, 63LL, a2, a2 + v14); v15 = a6; v16 = a5; v17 = a3; v10 = a7; if ( v13 == *(_DWORD *)(a1 + 152) ) goto LABEL_7; LABEL_10: v10[1] = a4; *v10 = a4; return 0LL; } v15 = a6; v16 = a5; v17 = a3; v10 = a7; LABEL_7: fixed = my_copy_fix_mb(a1, v13 + a2, v17 - v13, a4 + v11, v16 - v11, v15 - 1, v10); if ( v23 != (_DWORD)v14 ) v10[1] = a4; return *(unsigned int *)(a1 + 152) + fixed; }
my_copy_fix_mb2_or_mb4: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x38 MOV R12,RCX MOV R10,RDX MOV RBX,RSI MOV R14,RDI MOV R13D,dword ptr [RDI + 0x98] MOV RAX,R8 XOR EDX,EDX DIV R13 TEST RDX,RDX JZ 0x001c435d CMP R13,R10 SETA AL MOV RSI,qword ptr [RBP + 0x10] TEST R9,R9 SETZ CL OR CL,AL JNZ 0x001c43ec MOV R15,RDX MOV qword ptr [RBP + -0x38],RSI MOV qword ptr [RBP + -0x40],R10 MOV qword ptr [RBP + -0x48],R8 MOV qword ptr [RBP + -0x50],R9 SUB R13,RDX MOV RDI,RBX XOR ESI,ESI MOV RDX,R13 CALL 0x001292c0 ADD R13,RBX MOV RDI,R13 MOV qword ptr [RBP + -0x58],R12 MOV RSI,R12 MOV RDX,R15 CALL 0x00129120 MOV EDX,dword ptr [R14 + 0x98] ADD RDX,RBX MOV RAX,qword ptr [R14 + 0xb8] MOV RDI,R14 MOV RSI,RBX CALL qword ptr [RAX + 0xc0] MOV R13D,dword ptr [R14 + 0x98] CMP EAX,R13D MOV dword ptr [RBP + -0x2c],EAX JNZ 0x001c437c MOV R12,qword ptr [RBP + -0x58] MOV R9,qword ptr [RBP + -0x50] MOV R8,qword ptr [RBP + -0x48] MOV RDX,qword ptr [RBP + -0x40] MOV RSI,qword ptr [RBP + -0x38] JMP 0x001c43b2 LAB_001c435d: MOV RDI,R14 MOV RSI,RBX MOV RDX,R10 MOV RCX,R12 ADD RSP,0x38 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP JMP 0x001b3336 LAB_001c437c: MOV RAX,qword ptr [R14 + 0xb8] LEA RCX,[RBX + R13*0x1] MOV ESI,0x3f MOV RDI,R14 MOV RDX,RBX CALL qword ptr [RAX + 0x30] CMP EAX,dword ptr [R14 + 0x98] MOV R12,qword ptr [RBP + -0x58] MOV R9,qword ptr [RBP + -0x50] MOV R8,qword ptr [RBP + -0x48] MOV RDX,qword ptr [RBP + -0x40] MOV RSI,qword ptr [RBP + -0x38] JNZ 0x001c43ec LAB_001c43b2: MOV EAX,EAX ADD RBX,RAX SUB RDX,RAX LEA RCX,[R12 + R15*0x1] SUB R8,R15 DEC R9 MOV qword ptr [RSP],RSI MOV RDI,R14 MOV R15,RSI MOV RSI,RBX CALL 0x001b3336 CMP dword ptr [RBP + -0x2c],R13D JZ 0x001c43e0 MOV qword ptr [R15 + 0x8],R12 LAB_001c43e0: MOV ECX,dword ptr [R14 + 0x98] ADD RAX,RCX JMP 0x001c43f5 LAB_001c43ec: MOV qword ptr [RSI + 0x8],R12 MOV qword ptr [RSI],R12 XOR EAX,EAX LAB_001c43f5: ADD RSP,0x38 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
long my_copy_fix_mb2_or_mb4 (long param_1,void *param_2,ulong param_3,void *param_4,ulong param_5,long param_6, int8 *param_7) { uint uVar1; uint uVar2; uint uVar3; long lVar4; ulong __n; ulong uVar5; uVar5 = (ulong)*(uint *)(param_1 + 0x98); __n = param_5 % uVar5; if (__n == 0) { lVar4 = my_copy_fix_mb(param_1,param_2,param_3,param_4); return lVar4; } if (param_6 != 0 && uVar5 <= param_3) { memset(param_2,0,uVar5 - __n); memmove((void *)((uVar5 - __n) + (long)param_2),param_4,__n); uVar2 = (**(code **)(*(long *)(param_1 + 0xb8) + 0xc0)) (param_1,param_2,(ulong)*(uint *)(param_1 + 0x98) + (long)param_2); uVar1 = *(uint *)(param_1 + 0x98); uVar3 = uVar2; if ((uVar2 == uVar1) || (uVar3 = (**(code **)(*(long *)(param_1 + 0xb8) + 0x30)) (param_1,0x3f,param_2,(long)param_2 + (ulong)uVar1), uVar3 == *(uint *)(param_1 + 0x98))) { lVar4 = my_copy_fix_mb(param_1,(long)param_2 + (ulong)uVar3,param_3 - uVar3, (long)param_4 + __n,param_5 - __n,param_6 + -1,param_7); if (uVar2 != uVar1) { param_7[1] = param_4; } return lVar4 + (ulong)*(uint *)(param_1 + 0x98); } } param_7[1] = param_4; *param_7 = param_4; return 0; }
47,429
stbi__paeth(int, int, int)
mnn-tts/MNN/3rd_party/imageHelper/stb_image.h
static int stbi__paeth(int a, int b, int c) { int p = a + b - c; int pa = abs(p-a); int pb = abs(p-b); int pc = abs(p-c); if (pa <= pb && pa <= pc) return a; if (pb <= pc) return b; return c; }
O0
c
stbi__paeth(int, int, int): movl %edi, -0x8(%rsp) movl %esi, -0xc(%rsp) movl %edx, -0x10(%rsp) movl -0x8(%rsp), %eax addl -0xc(%rsp), %eax subl -0x10(%rsp), %eax movl %eax, -0x14(%rsp) movl -0x14(%rsp), %eax subl -0x8(%rsp), %eax movl %eax, %ecx negl %ecx cmovnsl %ecx, %eax movl %eax, -0x18(%rsp) movl -0x14(%rsp), %eax subl -0xc(%rsp), %eax movl %eax, %ecx negl %ecx cmovnsl %ecx, %eax movl %eax, -0x1c(%rsp) movl -0x14(%rsp), %eax subl -0x10(%rsp), %eax movl %eax, %ecx negl %ecx cmovnsl %ecx, %eax movl %eax, -0x20(%rsp) movl -0x18(%rsp), %eax cmpl -0x1c(%rsp), %eax jg 0x199a3 movl -0x18(%rsp), %eax cmpl -0x20(%rsp), %eax jg 0x199a3 movl -0x8(%rsp), %eax movl %eax, -0x4(%rsp) jmp 0x199bf movl -0x1c(%rsp), %eax cmpl -0x20(%rsp), %eax jg 0x199b7 movl -0xc(%rsp), %eax movl %eax, -0x4(%rsp) jmp 0x199bf movl -0x10(%rsp), %eax movl %eax, -0x4(%rsp) movl -0x4(%rsp), %eax retq nopw %cs:(%rax,%rax) nop
_ZL11stbi__paethiii: mov [rsp+var_8], edi mov [rsp+var_C], esi mov [rsp+var_10], edx mov eax, [rsp+var_8] add eax, [rsp+var_C] sub eax, [rsp+var_10] mov [rsp+var_14], eax mov eax, [rsp+var_14] sub eax, [rsp+var_8] mov ecx, eax neg ecx cmovns eax, ecx mov [rsp+var_18], eax mov eax, [rsp+var_14] sub eax, [rsp+var_C] mov ecx, eax neg ecx cmovns eax, ecx mov [rsp+var_1C], eax mov eax, [rsp+var_14] sub eax, [rsp+var_10] mov ecx, eax neg ecx cmovns eax, ecx mov [rsp+var_20], eax mov eax, [rsp+var_18] cmp eax, [rsp+var_1C] jg short loc_199A3 mov eax, [rsp+var_18] cmp eax, [rsp+var_20] jg short loc_199A3 mov eax, [rsp+var_8] mov [rsp+var_4], eax jmp short loc_199BF loc_199A3: mov eax, [rsp+var_1C] cmp eax, [rsp+var_20] jg short loc_199B7 mov eax, [rsp+var_C] mov [rsp+var_4], eax jmp short loc_199BF loc_199B7: mov eax, [rsp+var_10] mov [rsp+var_4], eax loc_199BF: mov eax, [rsp+var_4] retn
long long stbi__paeth(unsigned int a1, unsigned int a2, unsigned int a3) { unsigned int v3; // eax unsigned int v4; // eax int v5; // eax int v7; // [rsp+4h] [rbp-1Ch] int v8; // [rsp+8h] [rbp-18h] unsigned int v9; // [rsp+Ch] [rbp-14h] v9 = a2 + a1 - a3; v3 = a2 - a3; if ( (int)(a2 - a3) <= 0 ) v3 = a3 - a2; v8 = v3; v4 = a1 - a3; if ( (int)(a1 - a3) <= 0 ) v4 = a3 - a1; v7 = v4; v5 = v9 - a3; if ( (int)(v9 - a3) <= 0 ) v5 = a3 - v9; if ( v8 > v7 || v8 > v5 ) { if ( v7 > v5 ) return a3; else return a2; } else { return a1; } }
stbi__paeth: MOV dword ptr [RSP + -0x8],EDI MOV dword ptr [RSP + -0xc],ESI MOV dword ptr [RSP + -0x10],EDX MOV EAX,dword ptr [RSP + -0x8] ADD EAX,dword ptr [RSP + -0xc] SUB EAX,dword ptr [RSP + -0x10] MOV dword ptr [RSP + -0x14],EAX MOV EAX,dword ptr [RSP + -0x14] SUB EAX,dword ptr [RSP + -0x8] MOV ECX,EAX NEG ECX CMOVNS EAX,ECX MOV dword ptr [RSP + -0x18],EAX MOV EAX,dword ptr [RSP + -0x14] SUB EAX,dword ptr [RSP + -0xc] MOV ECX,EAX NEG ECX CMOVNS EAX,ECX MOV dword ptr [RSP + -0x1c],EAX MOV EAX,dword ptr [RSP + -0x14] SUB EAX,dword ptr [RSP + -0x10] MOV ECX,EAX NEG ECX CMOVNS EAX,ECX MOV dword ptr [RSP + -0x20],EAX MOV EAX,dword ptr [RSP + -0x18] CMP EAX,dword ptr [RSP + -0x1c] JG 0x001199a3 MOV EAX,dword ptr [RSP + -0x18] CMP EAX,dword ptr [RSP + -0x20] JG 0x001199a3 MOV EAX,dword ptr [RSP + -0x8] MOV dword ptr [RSP + -0x4],EAX JMP 0x001199bf LAB_001199a3: MOV EAX,dword ptr [RSP + -0x1c] CMP EAX,dword ptr [RSP + -0x20] JG 0x001199b7 MOV EAX,dword ptr [RSP + -0xc] MOV dword ptr [RSP + -0x4],EAX JMP 0x001199bf LAB_001199b7: MOV EAX,dword ptr [RSP + -0x10] MOV dword ptr [RSP + -0x4],EAX LAB_001199bf: MOV EAX,dword ptr [RSP + -0x4] RET
/* stbi__paeth(int, int, int) */ int stbi__paeth(int param_1,int param_2,int param_3) { int iVar1; int iVar2; int iVar3; int local_4; iVar1 = (param_1 + param_2) - param_3; iVar2 = iVar1 - param_1; if (iVar2 < 1) { iVar2 = -iVar2; } iVar3 = iVar1 - param_2; if (iVar3 < 1) { iVar3 = -iVar3; } iVar1 = iVar1 - param_3; if (iVar1 < 1) { iVar1 = -iVar1; } if (((iVar3 < iVar2) || (local_4 = param_1, iVar1 < iVar2)) && (local_4 = param_3, iVar3 <= iVar1) ) { local_4 = param_2; } return local_4; }
47,430
remove_pin
eloqsql/storage/maria/ma_pagecache.c
static void remove_pin(PAGECACHE_BLOCK_LINK *block, my_bool any #ifdef DBUG_OFF __attribute__((unused)) #endif ) { DBUG_ENTER("remove_pin"); DBUG_PRINT("enter", ("block: %p pins: %u any: %d", block, block->pins, (int)any)); PCBLOCK_INFO(block); DBUG_ASSERT(block->pins > 0); block->pins--; #ifndef DBUG_OFF { PAGECACHE_PIN_INFO *info= info_find(block->pin_list, my_thread_var, any); DBUG_ASSERT(info != 0); info_unlink(info); my_free(info); } #endif DBUG_VOID_RETURN; }
O0
c
remove_pin: pushq %rbp movq %rsp, %rbp movb %sil, %al movq %rdi, -0x8(%rbp) movb %al, -0x9(%rbp) jmp 0x3ed50 jmp 0x3ed52 jmp 0x3ed54 jmp 0x3ed56 jmp 0x3ed58 movq -0x8(%rbp), %rax movl 0x64(%rax), %ecx addl $-0x1, %ecx movl %ecx, 0x64(%rax) jmp 0x3ed67 popq %rbp retq nopl (%rax)
remove_pin: push rbp mov rbp, rsp mov al, sil mov [rbp+var_8], rdi mov [rbp+var_9], al jmp short $+2 loc_3ED50: jmp short $+2 loc_3ED52: jmp short $+2 loc_3ED54: jmp short $+2 loc_3ED56: jmp short $+2 loc_3ED58: mov rax, [rbp+var_8] mov ecx, [rax+64h] add ecx, 0FFFFFFFFh mov [rax+64h], ecx jmp short $+2 loc_3ED67: pop rbp retn
long long remove_pin(long long a1) { long long result; // rax result = a1; --*(_DWORD *)(a1 + 100); return result; }
remove_pin: PUSH RBP MOV RBP,RSP MOV AL,SIL MOV qword ptr [RBP + -0x8],RDI MOV byte ptr [RBP + -0x9],AL JMP 0x0013ed50 LAB_0013ed50: JMP 0x0013ed52 LAB_0013ed52: JMP 0x0013ed54 LAB_0013ed54: JMP 0x0013ed56 LAB_0013ed56: JMP 0x0013ed58 LAB_0013ed58: MOV RAX,qword ptr [RBP + -0x8] MOV ECX,dword ptr [RAX + 0x64] ADD ECX,-0x1 MOV dword ptr [RAX + 0x64],ECX JMP 0x0013ed67 LAB_0013ed67: POP RBP RET
void remove_pin(long param_1) { *(int *)(param_1 + 100) = *(int *)(param_1 + 100) + -1; return; }
47,431
translog_finish_page
eloqsql/storage/maria/ma_loghandler.c
static void translog_finish_page(TRANSLOG_ADDRESS *horizon, struct st_buffer_cursor *cursor) { uint16 left= TRANSLOG_PAGE_SIZE - cursor->current_page_fill; uchar *page= cursor->ptr - cursor->current_page_fill; DBUG_ENTER("translog_finish_page"); DBUG_PRINT("enter", ("Buffer: #%u %p " "Buffer addr: " LSN_FMT " " "Page addr: " LSN_FMT " " "size:%u (%u) Pg:%u left:%u", (uint) cursor->buffer_no, cursor->buffer, LSN_IN_PARTS(cursor->buffer->offset), (uint)LSN_FILE_NO(*horizon), (uint)(LSN_OFFSET(*horizon) - cursor->current_page_fill), (uint) cursor->buffer->size, (uint) (cursor->ptr -cursor->buffer->buffer), (uint) cursor->current_page_fill, (uint) left)); DBUG_ASSERT(LSN_FILE_NO(*horizon) == LSN_FILE_NO(cursor->buffer->offset) || translog_status == TRANSLOG_UNINITED); if ((LSN_FILE_NO(*horizon) != LSN_FILE_NO(cursor->buffer->offset))) DBUG_VOID_RETURN; // everything wrong do not write to awoid more problems translog_check_cursor(cursor); if (cursor->protected) { DBUG_PRINT("info", ("Already protected and finished")); DBUG_VOID_RETURN; } cursor->protected= 1; DBUG_ASSERT(left < TRANSLOG_PAGE_SIZE); if (left != 0) { DBUG_PRINT("info", ("left: %u", (uint) left)); memset(cursor->ptr, TRANSLOG_FILLER, left); cursor->ptr+= left; (*horizon)+= left; /* offset increasing */ if (!cursor->chaser) cursor->buffer->size+= left; /* We are finishing the page so reset the counter */ cursor->current_page_fill= 0; DBUG_PRINT("info", ("Finish Page buffer #%u: %p " "chaser: %d Size: %lu (%lu)", (uint) cursor->buffer->buffer_no, cursor->buffer, cursor->chaser, (ulong) cursor->buffer->size, (ulong) (cursor->ptr - cursor->buffer->buffer))); translog_check_cursor(cursor); } /* When we are finishing the page other thread might not finish the page header yet (in case if we started from the middle of the page) so we have to read log_descriptor.flags but not the flags from the page. */ if (log_descriptor.flags & TRANSLOG_SECTOR_PROTECTION) { translog_put_sector_protection(page, cursor); DBUG_PRINT("info", ("drop write_counter")); cursor->write_counter= 0; cursor->previous_offset= 0; } if (log_descriptor.flags & TRANSLOG_PAGE_CRC) { uint32 crc= translog_crc(page + log_descriptor.page_overhead, TRANSLOG_PAGE_SIZE - log_descriptor.page_overhead); DBUG_PRINT("info", ("CRC: %lx", (ulong) crc)); /* We have page number, file number and flag before crc */ int4store(page + 3 + 3 + 1, crc); } DBUG_VOID_RETURN; }
O0
c
translog_finish_page: pushq %rbp movq %rsp, %rbp subq $0x30, %rsp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq -0x10(%rbp), %rax movzwl 0x30(%rax), %ecx movl $0x2000, %eax # imm = 0x2000 subl %ecx, %eax movw %ax, -0x12(%rbp) movq -0x10(%rbp), %rax movq 0x20(%rax), %rax movq -0x10(%rbp), %rcx movzwl 0x30(%rcx), %ecx movslq %ecx, %rdx xorl %ecx, %ecx subq %rdx, %rcx addq %rcx, %rax movq %rax, -0x20(%rbp) jmp 0x54fa4 jmp 0x54fa6 jmp 0x54fa8 movq -0x8(%rbp), %rax movq (%rax), %rax sarq $0x20, %rax movq -0x10(%rbp), %rcx movq 0x28(%rcx), %rcx movq 0x100010(%rcx), %rcx sarq $0x20, %rcx cmpl %ecx, %eax je 0x54fd1 jmp 0x54fcc jmp 0x55107 movq -0x10(%rbp), %rdi callq 0x53d60 movq -0x10(%rbp), %rax cmpb $0x0, 0x38(%rax) je 0x54fef jmp 0x54fe6 jmp 0x54fe8 jmp 0x54fea jmp 0x55107 movq -0x10(%rbp), %rax movb $0x1, 0x38(%rax) jmp 0x54ff9 movzwl -0x12(%rbp), %eax cmpl $0x0, %eax je 0x5507b jmp 0x55004 jmp 0x55006 movq -0x10(%rbp), %rax movq 0x20(%rax), %rdi movzwl -0x12(%rbp), %eax movl %eax, %edx movl $0xff, %esi callq 0x2a2c0 movzwl -0x12(%rbp), %edx movq -0x10(%rbp), %rax movq 0x20(%rax), %rcx movslq %edx, %rdx addq %rdx, %rcx movq %rcx, 0x20(%rax) movzwl -0x12(%rbp), %eax movl %eax, %ecx movq -0x8(%rbp), %rax addq (%rax), %rcx movq %rcx, (%rax) movq -0x10(%rbp), %rax cmpb $0x0, 0x37(%rax) jne 0x55066 movzwl -0x12(%rbp), %ecx movq -0x10(%rbp), %rax movq 0x28(%rax), %rax addl 0x100030(%rax), %ecx movl %ecx, 0x100030(%rax) movq -0x10(%rbp), %rax movw $0x0, 0x30(%rax) jmp 0x55072 movq -0x10(%rbp), %rdi callq 0x53d60 movl 0x4255e7(%rip), %eax # 0x47a668 andl $0x2, %eax cmpl $0x0, %eax je 0x550ac movq -0x20(%rbp), %rdi movq -0x10(%rbp), %rsi callq 0x5ac80 jmp 0x55098 movq -0x10(%rbp), %rax movw $0x0, 0x32(%rax) movq -0x10(%rbp), %rax movw $0x0, 0x34(%rax) movl 0x4255b6(%rip), %eax # 0x47a668 andl $0x1, %eax cmpl $0x0, %eax je 0x55103 movq -0x20(%rbp), %rdi movzwl 0x4255bf(%rip), %eax # 0x47a684 cltq addq %rax, %rdi movzwl 0x4255b3(%rip), %eax # 0x47a684 movl $0x2000, %esi # imm = 0x2000 subl %eax, %esi callq 0x59fd0 movl %eax, -0x24(%rbp) jmp 0x550e2 jmp 0x550e4 movq -0x20(%rbp), %rax addq $0x3, %rax addq $0x3, %rax addq $0x1, %rax movq %rax, -0x30(%rbp) movl -0x24(%rbp), %ecx movq -0x30(%rbp), %rax movl %ecx, (%rax) jmp 0x55103 jmp 0x55105 jmp 0x55107 addq $0x30, %rsp popq %rbp retq nopl (%rax)
translog_finish_page: push rbp mov rbp, rsp sub rsp, 30h mov [rbp+var_8], rdi mov [rbp+var_10], rsi mov rax, [rbp+var_10] movzx ecx, word ptr [rax+30h] mov eax, 2000h sub eax, ecx mov [rbp+var_12], ax mov rax, [rbp+var_10] mov rax, [rax+20h] mov rcx, [rbp+var_10] movzx ecx, word ptr [rcx+30h] movsxd rdx, ecx xor ecx, ecx sub rcx, rdx add rax, rcx mov [rbp+var_20], rax jmp short $+2 loc_54FA4: jmp short $+2 loc_54FA6: jmp short $+2 loc_54FA8: mov rax, [rbp+var_8] mov rax, [rax] sar rax, 20h mov rcx, [rbp+var_10] mov rcx, [rcx+28h] mov rcx, [rcx+100010h] sar rcx, 20h cmp eax, ecx jz short loc_54FD1 jmp short $+2 loc_54FCC: jmp loc_55107 loc_54FD1: mov rdi, [rbp+var_10] call translog_check_cursor mov rax, [rbp+var_10] cmp byte ptr [rax+38h], 0 jz short loc_54FEF jmp short $+2 loc_54FE6: jmp short $+2 loc_54FE8: jmp short $+2 loc_54FEA: jmp loc_55107 loc_54FEF: mov rax, [rbp+var_10] mov byte ptr [rax+38h], 1 jmp short $+2 loc_54FF9: movzx eax, [rbp+var_12] cmp eax, 0 jz short loc_5507B jmp short $+2 loc_55004: jmp short $+2 loc_55006: mov rax, [rbp+var_10] mov rdi, [rax+20h] movzx eax, [rbp+var_12] mov edx, eax mov esi, 0FFh call _memset movzx edx, [rbp+var_12] mov rax, [rbp+var_10] mov rcx, [rax+20h] movsxd rdx, edx add rcx, rdx mov [rax+20h], rcx movzx eax, [rbp+var_12] mov ecx, eax mov rax, [rbp+var_8] add rcx, [rax] mov [rax], rcx mov rax, [rbp+var_10] cmp byte ptr [rax+37h], 0 jnz short loc_55066 movzx ecx, [rbp+var_12] mov rax, [rbp+var_10] mov rax, [rax+28h] add ecx, dword ptr ds:safe_hash_change[rax] mov dword ptr ds:safe_hash_change[rax], ecx loc_55066: mov rax, [rbp+var_10] mov word ptr [rax+30h], 0 jmp short $+2 loc_55072: mov rdi, [rbp+var_10] call translog_check_cursor loc_5507B: mov eax, cs:dword_47A668 and eax, 2 cmp eax, 0 jz short loc_550AC mov rdi, [rbp+var_20] mov rsi, [rbp+var_10] call translog_put_sector_protection jmp short $+2 loc_55098: mov rax, [rbp+var_10] mov word ptr [rax+32h], 0 mov rax, [rbp+var_10] mov word ptr [rax+34h], 0 loc_550AC: mov eax, cs:dword_47A668 and eax, 1 cmp eax, 0 jz short loc_55103 mov rdi, [rbp+var_20] movzx eax, cs:word_47A684 cdqe add rdi, rax movzx eax, cs:word_47A684 mov esi, 2000h sub esi, eax call translog_crc mov [rbp+var_24], eax jmp short $+2 loc_550E2: jmp short $+2 loc_550E4: mov rax, [rbp+var_20] add rax, 3 add rax, 3 add rax, 1 mov [rbp+var_30], rax mov ecx, [rbp+var_24] mov rax, [rbp+var_30] mov [rax], ecx jmp short $+2 loc_55103: jmp short $+2 loc_55105: jmp short $+2 loc_55107: add rsp, 30h pop rbp retn
long long translog_finish_page(long long *a1, long long a2) { long long result; // rax int v3; // [rsp+Ch] [rbp-24h] long long v4; // [rsp+10h] [rbp-20h] unsigned __int16 v5; // [rsp+1Eh] [rbp-12h] v5 = 0x2000 - *(_WORD *)(a2 + 48); v4 = *(_QWORD *)(a2 + 32) - *(unsigned __int16 *)(a2 + 48); result = *a1 >> 32; if ( (_DWORD)result == HIDWORD(*(_QWORD *)(*(_QWORD *)(a2 + 40) + 1048592LL)) ) { translog_check_cursor(); result = a2; if ( !*(_BYTE *)(a2 + 56) ) { *(_BYTE *)(a2 + 56) = 1; if ( v5 ) { memset(*(_QWORD *)(a2 + 32), 255LL, v5); *(_QWORD *)(a2 + 32) += v5; *a1 += v5; if ( !*(_BYTE *)(a2 + 55) ) *(_DWORD *)((char *)safe_hash_change + *(_QWORD *)(a2 + 40)) += v5; *(_WORD *)(a2 + 48) = 0; translog_check_cursor(); } if ( (dword_47A668 & 2) != 0 ) { translog_put_sector_protection(v4, a2); *(_WORD *)(a2 + 50) = 0; *(_WORD *)(a2 + 52) = 0; } result = dword_47A668 & 1; if ( (dword_47A668 & 1) != 0 ) { v3 = translog_crc((unsigned __int16)word_47A684 + v4, 0x2000 - (unsigned int)(unsigned __int16)word_47A684); result = v4 + 7; *(_DWORD *)(v4 + 7) = v3; } } } return result; }
translog_finish_page: PUSH RBP MOV RBP,RSP SUB RSP,0x30 MOV qword ptr [RBP + -0x8],RDI MOV qword ptr [RBP + -0x10],RSI MOV RAX,qword ptr [RBP + -0x10] MOVZX ECX,word ptr [RAX + 0x30] MOV EAX,0x2000 SUB EAX,ECX MOV word ptr [RBP + -0x12],AX MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x20] MOV RCX,qword ptr [RBP + -0x10] MOVZX ECX,word ptr [RCX + 0x30] MOVSXD RDX,ECX XOR ECX,ECX SUB RCX,RDX ADD RAX,RCX MOV qword ptr [RBP + -0x20],RAX JMP 0x00154fa4 LAB_00154fa4: JMP 0x00154fa6 LAB_00154fa6: JMP 0x00154fa8 LAB_00154fa8: MOV RAX,qword ptr [RBP + -0x8] MOV RAX,qword ptr [RAX] SAR RAX,0x20 MOV RCX,qword ptr [RBP + -0x10] MOV RCX,qword ptr [RCX + 0x28] MOV RCX,qword ptr [RCX + 0x100010] SAR RCX,0x20 CMP EAX,ECX JZ 0x00154fd1 JMP 0x00154fcc LAB_00154fcc: JMP 0x00155107 LAB_00154fd1: MOV RDI,qword ptr [RBP + -0x10] CALL 0x00153d60 MOV RAX,qword ptr [RBP + -0x10] CMP byte ptr [RAX + 0x38],0x0 JZ 0x00154fef JMP 0x00154fe6 LAB_00154fe6: JMP 0x00154fe8 LAB_00154fe8: JMP 0x00154fea LAB_00154fea: JMP 0x00155107 LAB_00154fef: MOV RAX,qword ptr [RBP + -0x10] MOV byte ptr [RAX + 0x38],0x1 JMP 0x00154ff9 LAB_00154ff9: MOVZX EAX,word ptr [RBP + -0x12] CMP EAX,0x0 JZ 0x0015507b JMP 0x00155004 LAB_00155004: JMP 0x00155006 LAB_00155006: MOV RAX,qword ptr [RBP + -0x10] MOV RDI,qword ptr [RAX + 0x20] MOVZX EAX,word ptr [RBP + -0x12] MOV EDX,EAX MOV ESI,0xff CALL 0x0012a2c0 MOVZX EDX,word ptr [RBP + -0x12] MOV RAX,qword ptr [RBP + -0x10] MOV RCX,qword ptr [RAX + 0x20] MOVSXD RDX,EDX ADD RCX,RDX MOV qword ptr [RAX + 0x20],RCX MOVZX EAX,word ptr [RBP + -0x12] MOV ECX,EAX MOV RAX,qword ptr [RBP + -0x8] ADD RCX,qword ptr [RAX] MOV qword ptr [RAX],RCX MOV RAX,qword ptr [RBP + -0x10] CMP byte ptr [RAX + 0x37],0x0 JNZ 0x00155066 MOVZX ECX,word ptr [RBP + -0x12] MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x28] ADD ECX,dword ptr [RAX + 0x100030] MOV dword ptr [RAX + 0x100030],ECX LAB_00155066: MOV RAX,qword ptr [RBP + -0x10] MOV word ptr [RAX + 0x30],0x0 JMP 0x00155072 LAB_00155072: MOV RDI,qword ptr [RBP + -0x10] CALL 0x00153d60 LAB_0015507b: MOV EAX,dword ptr [0x0057a668] AND EAX,0x2 CMP EAX,0x0 JZ 0x001550ac MOV RDI,qword ptr [RBP + -0x20] MOV RSI,qword ptr [RBP + -0x10] CALL 0x0015ac80 JMP 0x00155098 LAB_00155098: MOV RAX,qword ptr [RBP + -0x10] MOV word ptr [RAX + 0x32],0x0 MOV RAX,qword ptr [RBP + -0x10] MOV word ptr [RAX + 0x34],0x0 LAB_001550ac: MOV EAX,dword ptr [0x0057a668] AND EAX,0x1 CMP EAX,0x0 JZ 0x00155103 MOV RDI,qword ptr [RBP + -0x20] MOVZX EAX,word ptr [0x0057a684] CDQE ADD RDI,RAX MOVZX EAX,word ptr [0x0057a684] MOV ESI,0x2000 SUB ESI,EAX CALL 0x00159fd0 MOV dword ptr [RBP + -0x24],EAX JMP 0x001550e2 LAB_001550e2: JMP 0x001550e4 LAB_001550e4: MOV RAX,qword ptr [RBP + -0x20] ADD RAX,0x3 ADD RAX,0x3 ADD RAX,0x1 MOV qword ptr [RBP + -0x30],RAX MOV ECX,dword ptr [RBP + -0x24] MOV RAX,qword ptr [RBP + -0x30] MOV dword ptr [RAX],ECX JMP 0x00155103 LAB_00155103: JMP 0x00155105 LAB_00155105: JMP 0x00155107 LAB_00155107: ADD RSP,0x30 POP RBP RET
void translog_finish_page(long *param_1,long param_2) { ushort uVar1; int4 uVar2; long lVar3; uVar1 = 0x2000 - *(short *)(param_2 + 0x30); lVar3 = *(long *)(param_2 + 0x20) - (long)(int)(uint)*(ushort *)(param_2 + 0x30); if (((int)((ulong)*param_1 >> 0x20) == (int)((ulong)*(int8 *)(Elf64_Ehdr_00100000.e_ident_pad + *(long *)(param_2 + 0x28) + 7) >> 0x20)) && (translog_check_cursor(param_2), *(char *)(param_2 + 0x38) == '\0')) { *(int1 *)(param_2 + 0x38) = 1; if (uVar1 != 0) { memset(*(void **)(param_2 + 0x20),0xff,(ulong)uVar1); *(long *)(param_2 + 0x20) = *(long *)(param_2 + 0x20) + (long)(int)(uint)uVar1; *param_1 = (ulong)uVar1 + *param_1; if (*(char *)(param_2 + 0x37) == '\0') { *(uint *)(Elf64_Ehdr_00100000.e_ident_pad + *(long *)(param_2 + 0x28) + 0x27) = (uint)uVar1 + *(int *)(Elf64_Ehdr_00100000.e_ident_pad + *(long *)(param_2 + 0x28) + 0x27); } *(int2 *)(param_2 + 0x30) = 0; translog_check_cursor(param_2); } if ((DAT_0057a668 & 2) != 0) { translog_put_sector_protection(lVar3,param_2); *(int2 *)(param_2 + 0x32) = 0; *(int2 *)(param_2 + 0x34) = 0; } if ((DAT_0057a668 & 1) != 0) { uVar2 = translog_crc(lVar3 + (int)(uint)DAT_0057a684,0x2000 - (uint)DAT_0057a684); *(int4 *)(lVar3 + 7) = uVar2; } } return; }
47,432
js_call_bound_function
bluesky950520[P]quickjs/quickjs.c
static JSValue js_call_bound_function(JSContext *ctx, JSValue func_obj, JSValue this_obj, int argc, JSValue *argv, int flags) { JSObject *p; JSBoundFunction *bf; JSValue *arg_buf, new_target; int arg_count, i; p = JS_VALUE_GET_OBJ(func_obj); bf = p->u.bound_function; arg_count = bf->argc + argc; if (js_check_stack_overflow(ctx->rt, sizeof(JSValue) * arg_count)) return JS_ThrowStackOverflow(ctx); arg_buf = alloca(sizeof(JSValue) * arg_count); for(i = 0; i < bf->argc; i++) { arg_buf[i] = bf->argv[i]; } for(i = 0; i < argc; i++) { arg_buf[bf->argc + i] = argv[i]; } if (flags & JS_CALL_FLAG_CONSTRUCTOR) { new_target = this_obj; if (js_same_value(ctx, func_obj, new_target)) new_target = bf->func_obj; return JS_CallConstructor2(ctx, bf->func_obj, new_target, arg_count, arg_buf); } else { return JS_Call(ctx, bf->func_obj, bf->this_val, arg_count, arg_buf); } }
O0
c
js_call_bound_function: pushq %rbp movq %rsp, %rbp subq $0x70, %rsp movl 0x18(%rbp), %eax movq 0x10(%rbp), %rax movq %rsi, -0x20(%rbp) movq %rdx, -0x18(%rbp) movq %rcx, -0x30(%rbp) movq %r8, -0x28(%rbp) movq %rdi, -0x38(%rbp) movl %r9d, -0x3c(%rbp) movq -0x20(%rbp), %rax movq %rax, -0x48(%rbp) movq -0x48(%rbp), %rax movq 0x30(%rax), %rax movq %rax, -0x50(%rbp) movq -0x50(%rbp), %rax movl 0x20(%rax), %eax addl -0x3c(%rbp), %eax movl %eax, -0x6c(%rbp) movq -0x38(%rbp), %rax movq 0x18(%rax), %rdi movslq -0x6c(%rbp), %rsi shlq $0x4, %rsi callq 0x4dce0 cmpl $0x0, %eax je 0x22fd8 movq -0x38(%rbp), %rdi callq 0x601e0 movq %rax, -0x10(%rbp) movq %rdx, -0x8(%rbp) jmp 0x2314c movslq -0x6c(%rbp), %rcx shlq $0x4, %rcx movq %rsp, %rax subq %rcx, %rax movq %rax, %rsp movq %rax, -0x58(%rbp) movl $0x0, -0x70(%rbp) movl -0x70(%rbp), %eax movq -0x50(%rbp), %rcx cmpl 0x20(%rcx), %eax jge 0x2303b movq -0x58(%rbp), %rax movslq -0x70(%rbp), %rcx shlq $0x4, %rcx addq %rcx, %rax movq -0x50(%rbp), %rcx addq $0x28, %rcx movslq -0x70(%rbp), %rdx shlq $0x4, %rdx addq %rdx, %rcx movq (%rcx), %rdx movq %rdx, (%rax) movq 0x8(%rcx), %rcx movq %rcx, 0x8(%rax) movl -0x70(%rbp), %eax addl $0x1, %eax movl %eax, -0x70(%rbp) jmp 0x22ff4 movl $0x0, -0x70(%rbp) movl -0x70(%rbp), %eax cmpl -0x3c(%rbp), %eax jge 0x2308a movq -0x58(%rbp), %rax movq -0x50(%rbp), %rcx movl 0x20(%rcx), %ecx addl -0x70(%rbp), %ecx movslq %ecx, %rcx shlq $0x4, %rcx addq %rcx, %rax movq 0x10(%rbp), %rcx movslq -0x70(%rbp), %rdx shlq $0x4, %rdx addq %rdx, %rcx movq (%rcx), %rdx movq %rdx, (%rax) movq 0x8(%rcx), %rcx movq %rcx, 0x8(%rax) movl -0x70(%rbp), %eax addl $0x1, %eax movl %eax, -0x70(%rbp) jmp 0x23042 movl 0x18(%rbp), %eax andl $0x1, %eax cmpl $0x0, %eax je 0x23110 movq -0x30(%rbp), %rax movq %rax, -0x68(%rbp) movq -0x28(%rbp), %rax movq %rax, -0x60(%rbp) movq -0x38(%rbp), %rdi movq -0x20(%rbp), %rsi movq -0x18(%rbp), %rdx movq -0x68(%rbp), %rcx movq -0x60(%rbp), %r8 callq 0x35b10 cmpl $0x0, %eax je 0x230d6 movq -0x50(%rbp), %rax movq (%rax), %rcx movq %rcx, -0x68(%rbp) movq 0x8(%rax), %rax movq %rax, -0x60(%rbp) movq -0x38(%rbp), %rdi movq -0x50(%rbp), %rcx movl -0x6c(%rbp), %r9d movq -0x58(%rbp), %rax movq (%rcx), %rsi movq 0x8(%rcx), %rdx movq -0x68(%rbp), %rcx movq -0x60(%rbp), %r8 subq $0x10, %rsp movq %rax, (%rsp) callq 0x48090 addq $0x10, %rsp movq %rax, -0x10(%rbp) movq %rdx, -0x8(%rbp) jmp 0x2314c movq -0x38(%rbp), %rdi movq -0x50(%rbp), %rcx movq -0x50(%rbp), %r8 movl -0x6c(%rbp), %r9d movq -0x58(%rbp), %rax movq (%rcx), %rsi movq 0x8(%rcx), %rdx movq 0x10(%r8), %rcx movq 0x18(%r8), %r8 subq $0x10, %rsp movq %rax, (%rsp) callq 0x3a050 addq $0x10, %rsp movq %rax, -0x10(%rbp) movq %rdx, -0x8(%rbp) movq -0x10(%rbp), %rax movq -0x8(%rbp), %rdx movq %rbp, %rsp popq %rbp retq nopl (%rax)
js_call_bound_function: push rbp mov rbp, rsp sub rsp, 70h mov eax, [rbp+arg_8] mov rax, [rbp+arg_0] mov [rbp+var_20], rsi mov [rbp+var_18], rdx mov [rbp+var_30], rcx mov [rbp+var_28], r8 mov [rbp+var_38], rdi mov [rbp+var_3C], r9d mov rax, [rbp+var_20] mov [rbp+var_48], rax mov rax, [rbp+var_48] mov rax, [rax+30h] mov [rbp+var_50], rax mov rax, [rbp+var_50] mov eax, [rax+20h] add eax, [rbp+var_3C] mov [rbp+var_6C], eax mov rax, [rbp+var_38] mov rdi, [rax+18h] movsxd rsi, [rbp+var_6C] shl rsi, 4 call js_check_stack_overflow cmp eax, 0 jz short loc_22FD8 mov rdi, [rbp+var_38] call JS_ThrowStackOverflow mov [rbp+var_10], rax mov [rbp+var_8], rdx jmp loc_2314C loc_22FD8: movsxd rcx, [rbp+var_6C] shl rcx, 4 mov rax, rsp sub rax, rcx mov rsp, rax mov [rbp+var_58], rax mov [rbp+var_70], 0 loc_22FF4: mov eax, [rbp+var_70] mov rcx, [rbp+var_50] cmp eax, [rcx+20h] jge short loc_2303B mov rax, [rbp+var_58] movsxd rcx, [rbp+var_70] shl rcx, 4 add rax, rcx mov rcx, [rbp+var_50] add rcx, 28h ; '(' movsxd rdx, [rbp+var_70] shl rdx, 4 add rcx, rdx mov rdx, [rcx] mov [rax], rdx mov rcx, [rcx+8] mov [rax+8], rcx mov eax, [rbp+var_70] add eax, 1 mov [rbp+var_70], eax jmp short loc_22FF4 loc_2303B: mov [rbp+var_70], 0 loc_23042: mov eax, [rbp+var_70] cmp eax, [rbp+var_3C] jge short loc_2308A mov rax, [rbp+var_58] mov rcx, [rbp+var_50] mov ecx, [rcx+20h] add ecx, [rbp+var_70] movsxd rcx, ecx shl rcx, 4 add rax, rcx mov rcx, [rbp+arg_0] movsxd rdx, [rbp+var_70] shl rdx, 4 add rcx, rdx mov rdx, [rcx] mov [rax], rdx mov rcx, [rcx+8] mov [rax+8], rcx mov eax, [rbp+var_70] add eax, 1 mov [rbp+var_70], eax jmp short loc_23042 loc_2308A: mov eax, [rbp+arg_8] and eax, 1 cmp eax, 0 jz short loc_23110 mov rax, [rbp+var_30] mov [rbp+var_68], rax mov rax, [rbp+var_28] mov [rbp+var_60], rax mov rdi, [rbp+var_38] mov rsi, [rbp+var_20] mov rdx, [rbp+var_18] mov rcx, [rbp+var_68] mov r8, [rbp+var_60] call js_same_value cmp eax, 0 jz short loc_230D6 mov rax, [rbp+var_50] mov rcx, [rax] mov [rbp+var_68], rcx mov rax, [rax+8] mov [rbp+var_60], rax loc_230D6: mov rdi, [rbp+var_38] mov rcx, [rbp+var_50] mov r9d, [rbp+var_6C] mov rax, [rbp+var_58] mov rsi, [rcx] mov rdx, [rcx+8] mov rcx, [rbp+var_68] mov r8, [rbp+var_60] sub rsp, 10h mov [rsp+80h+var_80], rax call JS_CallConstructor2 add rsp, 10h mov [rbp+var_10], rax mov [rbp+var_8], rdx jmp short loc_2314C loc_23110: mov rdi, [rbp+var_38] mov rcx, [rbp+var_50] mov r8, [rbp+var_50] mov r9d, [rbp+var_6C] mov rax, [rbp+var_58] mov rsi, [rcx] mov rdx, [rcx+8] mov rcx, [r8+10h] mov r8, [r8+18h] sub rsp, 10h mov [rsp+80h+var_80], rax call JS_Call add rsp, 10h mov [rbp+var_10], rax mov [rbp+var_8], rdx loc_2314C: mov rax, [rbp+var_10] mov rdx, [rbp+var_8] mov rsp, rbp pop rbp retn
long long js_call_bound_function( long long a1, long long a2, long long a3, long long a4, long long a5, int a6, long long a7, char a8) { long long v8; // rdx int *v9; // rax long long *v10; // rcx int *v11; // rax _QWORD *v12; // rcx long long v13; // rdx long long v14; // rdx int i; // [rsp+10h] [rbp-70h] BYREF int v17; // [rsp+14h] [rbp-6Ch] long long v18; // [rsp+18h] [rbp-68h] long long v19; // [rsp+20h] [rbp-60h] int *v20; // [rsp+28h] [rbp-58h] long long *v21; // [rsp+30h] [rbp-50h] long long v22; // [rsp+38h] [rbp-48h] int v23; // [rsp+44h] [rbp-3Ch] long long v24; // [rsp+48h] [rbp-38h] long long v25; // [rsp+50h] [rbp-30h] long long v26; // [rsp+58h] [rbp-28h] long long v27; // [rsp+60h] [rbp-20h] long long v28; // [rsp+68h] [rbp-18h] long long v29; // [rsp+70h] [rbp-10h] long long v30; // [rsp+78h] [rbp-8h] v27 = a2; v28 = a3; v25 = a4; v26 = a5; v24 = a1; v23 = a6; v22 = a2; v21 = *(long long **)(a2 + 48); v17 = a6 + *((_DWORD *)v21 + 8); if ( (unsigned int)js_check_stack_overflow(*(_QWORD *)(a1 + 24), 16LL * v17) ) { v29 = JS_ThrowStackOverflow(v24); v30 = v8; } else { v20 = &i - 4 * v17; for ( i = 0; i < *((_DWORD *)v21 + 8); ++i ) { v9 = &v20[4 * i]; v10 = &v21[2 * i + 5]; *(_QWORD *)v9 = *v10; *((_QWORD *)v9 + 1) = v10[1]; } for ( i = 0; i < v23; ++i ) { v11 = &v20[4 * i + 4 * *((_DWORD *)v21 + 8)]; v12 = (_QWORD *)(16LL * i + a7); *(_QWORD *)v11 = *v12; *((_QWORD *)v11 + 1) = v12[1]; } if ( (a8 & 1) != 0 ) { v18 = v25; v19 = v26; if ( (unsigned int)js_same_value(v24, v27, v28, v25, v26) ) { v18 = *v21; v19 = v21[1]; } v29 = JS_CallConstructor2(v24, *v21, v21[1], v18, v19, v17, (long long)v20); v30 = v13; } else { v29 = JS_Call(v24, *v21, v21[1], v21[2], v21[3], v17, (long long)v20); v30 = v14; } } return v29; }
js_call_bound_function: PUSH RBP MOV RBP,RSP SUB RSP,0x70 MOV EAX,dword ptr [RBP + 0x18] MOV RAX,qword ptr [RBP + 0x10] MOV qword ptr [RBP + -0x20],RSI MOV qword ptr [RBP + -0x18],RDX MOV qword ptr [RBP + -0x30],RCX MOV qword ptr [RBP + -0x28],R8 MOV qword ptr [RBP + -0x38],RDI MOV dword ptr [RBP + -0x3c],R9D MOV RAX,qword ptr [RBP + -0x20] MOV qword ptr [RBP + -0x48],RAX MOV RAX,qword ptr [RBP + -0x48] MOV RAX,qword ptr [RAX + 0x30] MOV qword ptr [RBP + -0x50],RAX MOV RAX,qword ptr [RBP + -0x50] MOV EAX,dword ptr [RAX + 0x20] ADD EAX,dword ptr [RBP + -0x3c] MOV dword ptr [RBP + -0x6c],EAX MOV RAX,qword ptr [RBP + -0x38] MOV RDI,qword ptr [RAX + 0x18] MOVSXD RSI,dword ptr [RBP + -0x6c] SHL RSI,0x4 CALL 0x0014dce0 CMP EAX,0x0 JZ 0x00122fd8 MOV RDI,qword ptr [RBP + -0x38] CALL 0x001601e0 MOV qword ptr [RBP + -0x10],RAX MOV qword ptr [RBP + -0x8],RDX JMP 0x0012314c LAB_00122fd8: MOVSXD RCX,dword ptr [RBP + -0x6c] SHL RCX,0x4 MOV RAX,RSP SUB RAX,RCX MOV RSP,RAX MOV qword ptr [RBP + -0x58],RAX MOV dword ptr [RBP + -0x70],0x0 LAB_00122ff4: MOV EAX,dword ptr [RBP + -0x70] MOV RCX,qword ptr [RBP + -0x50] CMP EAX,dword ptr [RCX + 0x20] JGE 0x0012303b MOV RAX,qword ptr [RBP + -0x58] MOVSXD RCX,dword ptr [RBP + -0x70] SHL RCX,0x4 ADD RAX,RCX MOV RCX,qword ptr [RBP + -0x50] ADD RCX,0x28 MOVSXD RDX,dword ptr [RBP + -0x70] SHL RDX,0x4 ADD RCX,RDX MOV RDX,qword ptr [RCX] MOV qword ptr [RAX],RDX MOV RCX,qword ptr [RCX + 0x8] MOV qword ptr [RAX + 0x8],RCX MOV EAX,dword ptr [RBP + -0x70] ADD EAX,0x1 MOV dword ptr [RBP + -0x70],EAX JMP 0x00122ff4 LAB_0012303b: MOV dword ptr [RBP + -0x70],0x0 LAB_00123042: MOV EAX,dword ptr [RBP + -0x70] CMP EAX,dword ptr [RBP + -0x3c] JGE 0x0012308a MOV RAX,qword ptr [RBP + -0x58] MOV RCX,qword ptr [RBP + -0x50] MOV ECX,dword ptr [RCX + 0x20] ADD ECX,dword ptr [RBP + -0x70] MOVSXD RCX,ECX SHL RCX,0x4 ADD RAX,RCX MOV RCX,qword ptr [RBP + 0x10] MOVSXD RDX,dword ptr [RBP + -0x70] SHL RDX,0x4 ADD RCX,RDX MOV RDX,qword ptr [RCX] MOV qword ptr [RAX],RDX MOV RCX,qword ptr [RCX + 0x8] MOV qword ptr [RAX + 0x8],RCX MOV EAX,dword ptr [RBP + -0x70] ADD EAX,0x1 MOV dword ptr [RBP + -0x70],EAX JMP 0x00123042 LAB_0012308a: MOV EAX,dword ptr [RBP + 0x18] AND EAX,0x1 CMP EAX,0x0 JZ 0x00123110 MOV RAX,qword ptr [RBP + -0x30] MOV qword ptr [RBP + -0x68],RAX MOV RAX,qword ptr [RBP + -0x28] MOV qword ptr [RBP + -0x60],RAX MOV RDI,qword ptr [RBP + -0x38] MOV RSI,qword ptr [RBP + -0x20] MOV RDX,qword ptr [RBP + -0x18] MOV RCX,qword ptr [RBP + -0x68] MOV R8,qword ptr [RBP + -0x60] CALL 0x00135b10 CMP EAX,0x0 JZ 0x001230d6 MOV RAX,qword ptr [RBP + -0x50] MOV RCX,qword ptr [RAX] MOV qword ptr [RBP + -0x68],RCX MOV RAX,qword ptr [RAX + 0x8] MOV qword ptr [RBP + -0x60],RAX LAB_001230d6: MOV RDI,qword ptr [RBP + -0x38] MOV RCX,qword ptr [RBP + -0x50] MOV R9D,dword ptr [RBP + -0x6c] MOV RAX,qword ptr [RBP + -0x58] MOV RSI,qword ptr [RCX] MOV RDX,qword ptr [RCX + 0x8] MOV RCX,qword ptr [RBP + -0x68] MOV R8,qword ptr [RBP + -0x60] SUB RSP,0x10 MOV qword ptr [RSP],RAX CALL 0x00148090 ADD RSP,0x10 MOV qword ptr [RBP + -0x10],RAX MOV qword ptr [RBP + -0x8],RDX JMP 0x0012314c LAB_00123110: MOV RDI,qword ptr [RBP + -0x38] MOV RCX,qword ptr [RBP + -0x50] MOV R8,qword ptr [RBP + -0x50] MOV R9D,dword ptr [RBP + -0x6c] MOV RAX,qword ptr [RBP + -0x58] MOV RSI,qword ptr [RCX] MOV RDX,qword ptr [RCX + 0x8] MOV RCX,qword ptr [R8 + 0x10] MOV R8,qword ptr [R8 + 0x18] SUB RSP,0x10 MOV qword ptr [RSP],RAX CALL 0x0013a050 ADD RSP,0x10 MOV qword ptr [RBP + -0x10],RAX MOV qword ptr [RBP + -0x8],RDX LAB_0012314c: MOV RAX,qword ptr [RBP + -0x10] MOV RDX,qword ptr [RBP + -0x8] MOV RSP,RBP POP RBP RET
int1 [16] js_call_bound_function (long param_1,long param_2,int8 param_3,int8 param_4,int8 param_5, int param_6,long param_7,uint param_8) { int8 uVar1; int8 uVar2; int8 uVar3; int8 uVar4; int iVar5; long lVar6; long lVar7; int iVar8; long lVar9; int8 *puVar10; int1 auVar11 [16]; long alStack_90 [3]; int local_78 [2]; int8 local_70; int8 local_68; int *local_60; int8 *local_58; long local_50; int local_44; long local_40; int8 local_38; int8 local_30; long local_28; int8 local_20; local_58 = *(int8 **)(param_2 + 0x30); local_78[1] = *(int *)(local_58 + 4) + param_6; alStack_90[2] = 0x122fbd; local_50 = param_2; local_44 = param_6; local_40 = param_1; local_38 = param_4; local_30 = param_5; local_28 = param_2; local_20 = param_3; iVar8 = js_check_stack_overflow(*(int8 *)(param_1 + 0x18),(long)local_78[1] << 4); uVar3 = local_20; lVar7 = local_28; uVar2 = local_30; uVar1 = local_38; lVar6 = local_40; iVar5 = local_78[1]; if (iVar8 == 0) { lVar9 = (long)local_78[1]; local_60 = local_78 + lVar9 * -4; for (local_78[0] = 0; local_78[0] < *(int *)(local_58 + 4); local_78[0] = local_78[0] + 1) { *(int8 *)(local_60 + (long)local_78[0] * 4) = local_58[(long)local_78[0] * 2 + 5]; *(int8 *)(local_60 + (long)local_78[0] * 4 + 2) = (local_58 + (long)local_78[0] * 2 + 5)[1]; } for (local_78[0] = 0; local_78[0] < local_44; local_78[0] = local_78[0] + 1) { iVar8 = *(int *)(local_58 + 4); puVar10 = (int8 *)(param_7 + (long)local_78[0] * 0x10); *(int8 *)(local_60 + (long)(iVar8 + local_78[0]) * 4) = *puVar10; *(int8 *)(local_60 + (long)(iVar8 + local_78[0]) * 4 + 2) = puVar10[1]; } if ((param_8 & 1) == 0) { uVar1 = *local_58; uVar2 = local_58[1]; uVar3 = local_58[2]; uVar4 = local_58[3]; alStack_90[lVar9 * -2 + 1] = (long)local_60; alStack_90[lVar9 * -2] = 0x123140; auVar11 = JS_Call(lVar6,uVar1,uVar2,uVar3,uVar4,iVar5); } else { local_70 = local_38; local_68 = local_30; alStack_90[lVar9 * -2 + 2] = 0x1230be; iVar8 = js_same_value(lVar6,lVar7,uVar3,uVar1,uVar2); lVar6 = local_40; iVar5 = local_78[1]; if (iVar8 != 0) { local_70 = *local_58; local_68 = local_58[1]; } uVar4 = local_68; uVar3 = local_70; uVar1 = *local_58; uVar2 = local_58[1]; alStack_90[lVar9 * -2 + 1] = (long)local_60; alStack_90[lVar9 * -2] = 0x123102; auVar11 = JS_CallConstructor2(lVar6,uVar1,uVar2,uVar3,uVar4,iVar5); } } else { alStack_90[2] = 0x122fcb; auVar11 = JS_ThrowStackOverflow(local_40); } return auVar11; }
47,433
js_call_bound_function
bluesky950520[P]quickjs/quickjs.c
static JSValue js_call_bound_function(JSContext *ctx, JSValue func_obj, JSValue this_obj, int argc, JSValue *argv, int flags) { JSObject *p; JSBoundFunction *bf; JSValue *arg_buf, new_target; int arg_count, i; p = JS_VALUE_GET_OBJ(func_obj); bf = p->u.bound_function; arg_count = bf->argc + argc; if (js_check_stack_overflow(ctx->rt, sizeof(JSValue) * arg_count)) return JS_ThrowStackOverflow(ctx); arg_buf = alloca(sizeof(JSValue) * arg_count); for(i = 0; i < bf->argc; i++) { arg_buf[i] = bf->argv[i]; } for(i = 0; i < argc; i++) { arg_buf[bf->argc + i] = argv[i]; } if (flags & JS_CALL_FLAG_CONSTRUCTOR) { new_target = this_obj; if (js_same_value(ctx, func_obj, new_target)) new_target = bf->func_obj; return JS_CallConstructor2(ctx, bf->func_obj, new_target, arg_count, arg_buf); } else { return JS_Call(ctx, bf->func_obj, bf->this_val, arg_count, arg_buf); } }
O1
c
js_call_bound_function: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x18, %rsp movq %rdi, %rbx movq %rbp, %r10 movq 0x30(%rsi), %r13 movslq 0x20(%r13), %rax movslq %r9d, %r14 addq %rax, %r14 movq 0x18(%rdi), %rdi movq %r14, %rax shlq $0x4, %rax subq %rax, %r10 cmpq 0xe8(%rdi), %r10 jae 0x1d3d6 leaq 0x81c17(%rip), %rsi # 0x9efd6 xorl %r14d, %r14d movq %rbx, %rdi xorl %eax, %eax callq 0x20add movl $0x6, %edx jmp 0x1d4d0 movq %rsp, %r15 addq $0xf, %rax andq $-0x10, %rax subq %rax, %r15 movq %r15, %rsp cmpl $0x0, 0x20(%r13) jle 0x1d411 leaq 0x28(%r13), %rax xorl %r11d, %r11d xorl %edi, %edi movups (%rax,%r11), %xmm0 movups %xmm0, (%r15,%r11) incq %rdi movslq 0x20(%r13), %r10 addq $0x10, %r11 cmpq %r10, %rdi jl 0x1d3f7 movl 0x18(%rbp), %eax testl %r9d, %r9d jle 0x1d443 movq 0x10(%rbp), %r11 movl %r9d, %edi xorl %r10d, %r10d movslq 0x20(%r13), %r9 addq %r10, %r9 shlq $0x4, %r9 movups (%r11), %xmm0 movups %xmm0, (%r15,%r9) incq %r10 addq $0x10, %r11 cmpq %r10, %rdi jne 0x1d423 testb $0x1, %al jne 0x1d490 movq (%r13), %rsi movq 0x8(%r13), %rdx movq 0x10(%r13), %rcx movq 0x18(%r13), %r8 movl $0x0, -0x40(%rbp) movq $0x3, -0x38(%rbp) subq $0x20, %rsp movups -0x40(%rbp), %xmm0 movups %xmm0, (%rsp) movq %r15, 0x10(%rsp) movl $0x2, 0x18(%rsp) movq %rbx, %rdi movl %r14d, %r9d callq 0x284ca addq $0x20, %rsp jmp 0x1d4cd movq %rbx, %rdi movq %r8, -0x30(%rbp) movq %rcx, %r12 callq 0x26461 movq -0x30(%rbp), %r8 testl %eax, %eax je 0x1d4af movq (%r13), %r12 movq 0x8(%r13), %r8 movq (%r13), %rsi movq 0x8(%r13), %rdx movq %rbx, %rdi movq %r12, %rcx movl %r14d, %r9d pushq $0x2 pushq %r15 callq 0x2fa61 addq $0x10, %rsp movq %rax, %r14 movq %r14, %rax leaq -0x28(%rbp), %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
js_call_bound_function: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx sub rsp, 18h mov rbx, rdi mov r10, rbp mov r13, [rsi+30h] movsxd rax, dword ptr [r13+20h] movsxd r14, r9d add r14, rax mov rdi, [rdi+18h] mov rax, r14 shl rax, 4 sub r10, rax cmp r10, [rdi+0E8h] jnb short loc_1D3D6 lea rsi, aMaximumCallSta; "Maximum call stack size exceeded" xor r14d, r14d mov rdi, rbx xor eax, eax call JS_ThrowRangeError mov edx, 6 jmp loc_1D4D0 loc_1D3D6: mov r15, rsp add rax, 0Fh and rax, 0FFFFFFFFFFFFFFF0h sub r15, rax mov rsp, r15 cmp dword ptr [r13+20h], 0 jle short loc_1D411 lea rax, [r13+28h] xor r11d, r11d xor edi, edi loc_1D3F7: movups xmm0, xmmword ptr [rax+r11] movups xmmword ptr [r15+r11], xmm0 inc rdi movsxd r10, dword ptr [r13+20h] add r11, 10h cmp rdi, r10 jl short loc_1D3F7 loc_1D411: mov eax, [rbp+arg_8] test r9d, r9d jle short loc_1D443 mov r11, [rbp+arg_0] mov edi, r9d xor r10d, r10d loc_1D423: movsxd r9, dword ptr [r13+20h] add r9, r10 shl r9, 4 movups xmm0, xmmword ptr [r11] movups xmmword ptr [r15+r9], xmm0 inc r10 add r11, 10h cmp rdi, r10 jnz short loc_1D423 loc_1D443: test al, 1 jnz short loc_1D490 mov rsi, [r13+0] mov rdx, [r13+8] mov rcx, [r13+10h] mov r8, [r13+18h] mov dword ptr [rbp+var_40], 0 mov qword ptr [rbp+var_40+8], 3 sub rsp, 20h movups xmm0, [rbp+var_40] movups [rsp+60h+var_60], xmm0 mov [rsp+60h+var_50], r15 mov [rsp+60h+var_48], 2 mov rdi, rbx mov r9d, r14d call JS_CallInternal add rsp, 20h jmp short loc_1D4CD loc_1D490: mov rdi, rbx mov [rbp+var_30], r8 mov r12, rcx call js_same_value mov r8, [rbp+var_30] test eax, eax jz short loc_1D4AF mov r12, [r13+0] mov r8, [r13+8] loc_1D4AF: mov rsi, [r13+0] mov rdx, [r13+8] mov rdi, rbx mov rcx, r12 mov r9d, r14d push 2 push r15 call JS_CallConstructorInternal add rsp, 10h loc_1D4CD: mov r14, rax loc_1D4D0: mov rax, r14 lea rsp, [rbp-28h] pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
long long js_call_bound_function( long long a1, long long a2, int a3, int a4, long long a5, int a6, _OWORD *a7, char a8) { long long *v9; // r13 int v10; // r14d long long v11; // rax long long v12; // r14 char *v13; // r15 long long v14; // r11 long long v15; // rdi long long i; // r10 long long v18; // rsi long long v19; // rdx long long v20; // rcx long long v21; // r8 long long v23; // r12 int v24; // eax long long v25; // r8 int v27; // [rsp+20h] [rbp-40h] BYREF long long v28; // [rsp+28h] [rbp-38h] long long v29; // [rsp+30h] [rbp-30h] long long savedregs; // [rsp+60h] [rbp+0h] BYREF v9 = *(long long **)(a2 + 48); v10 = *((_DWORD *)v9 + 8) + a6; v11 = 16 * (*((int *)v9 + 8) + (long long)a6); if ( (unsigned long long)&savedregs - v11 >= *(_QWORD *)(*(_QWORD *)(a1 + 24) + 232LL) ) { v13 = (char *)&v27 - ((v11 + 15) & 0xFFFFFFFFFFFFFFF0LL); if ( *((int *)v9 + 8) > 0 ) { v14 = 0LL; v15 = 0LL; do { *(_OWORD *)&v13[v14 * 8] = *(_OWORD *)&v9[v14 + 5]; ++v15; v14 += 2LL; } while ( v15 < *((int *)v9 + 8) ); } if ( a6 > 0 ) { for ( i = 0LL; i != a6; ++i ) *(_OWORD *)&v13[16 * i + 16 * *((int *)v9 + 8)] = *a7++; } if ( (a8 & 1) != 0 ) { v29 = a5; LODWORD(v23) = a4; v24 = js_same_value(a1); LODWORD(v25) = v29; if ( v24 ) { v23 = *v9; v25 = v9[1]; } return JS_CallConstructorInternal(a1, *v9, v9[1], v23, v25, v10, (long long)v13, 2); } else { v18 = *v9; v19 = v9[1]; v20 = v9[2]; v21 = v9[3]; v27 = 0; v28 = 3LL; return JS_CallInternal(a1, v18, v19, v20, v21, v10, 0, 3, (long long)v13, 2); } } else { v12 = 0LL; JS_ThrowRangeError(a1, (unsigned int)"Maximum call stack size exceeded", a3, a4, a5, a6); } return v12; }
js_call_bound_function: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x18 MOV RBX,RDI MOV R10,RBP MOV R13,qword ptr [RSI + 0x30] MOVSXD RAX,dword ptr [R13 + 0x20] MOVSXD R14,R9D ADD R14,RAX MOV RDI,qword ptr [RDI + 0x18] MOV RAX,R14 SHL RAX,0x4 SUB R10,RAX CMP R10,qword ptr [RDI + 0xe8] JNC 0x0011d3d6 LEA RSI,[0x19efd6] XOR R14D,R14D MOV RDI,RBX XOR EAX,EAX CALL 0x00120add MOV EDX,0x6 JMP 0x0011d4d0 LAB_0011d3d6: MOV R15,RSP ADD RAX,0xf AND RAX,-0x10 SUB R15,RAX MOV RSP,R15 CMP dword ptr [R13 + 0x20],0x0 JLE 0x0011d411 LEA RAX,[R13 + 0x28] XOR R11D,R11D XOR EDI,EDI LAB_0011d3f7: MOVUPS XMM0,xmmword ptr [RAX + R11*0x1] MOVUPS xmmword ptr [R15 + R11*0x1],XMM0 INC RDI MOVSXD R10,dword ptr [R13 + 0x20] ADD R11,0x10 CMP RDI,R10 JL 0x0011d3f7 LAB_0011d411: MOV EAX,dword ptr [RBP + 0x18] TEST R9D,R9D JLE 0x0011d443 MOV R11,qword ptr [RBP + 0x10] MOV EDI,R9D XOR R10D,R10D LAB_0011d423: MOVSXD R9,dword ptr [R13 + 0x20] ADD R9,R10 SHL R9,0x4 MOVUPS XMM0,xmmword ptr [R11] MOVUPS xmmword ptr [R15 + R9*0x1],XMM0 INC R10 ADD R11,0x10 CMP RDI,R10 JNZ 0x0011d423 LAB_0011d443: TEST AL,0x1 JNZ 0x0011d490 MOV RSI,qword ptr [R13] MOV RDX,qword ptr [R13 + 0x8] MOV RCX,qword ptr [R13 + 0x10] MOV R8,qword ptr [R13 + 0x18] MOV dword ptr [RBP + -0x40],0x0 MOV qword ptr [RBP + -0x38],0x3 SUB RSP,0x20 MOVUPS XMM0,xmmword ptr [RBP + -0x40] MOVUPS xmmword ptr [RSP],XMM0 MOV qword ptr [RSP + 0x10],R15 MOV dword ptr [RSP + 0x18],0x2 MOV RDI,RBX MOV R9D,R14D CALL 0x001284ca ADD RSP,0x20 JMP 0x0011d4cd LAB_0011d490: MOV RDI,RBX MOV qword ptr [RBP + -0x30],R8 MOV R12,RCX CALL 0x00126461 MOV R8,qword ptr [RBP + -0x30] TEST EAX,EAX JZ 0x0011d4af MOV R12,qword ptr [R13] MOV R8,qword ptr [R13 + 0x8] LAB_0011d4af: MOV RSI,qword ptr [R13] MOV RDX,qword ptr [R13 + 0x8] MOV RDI,RBX MOV RCX,R12 MOV R9D,R14D PUSH 0x2 PUSH R15 CALL 0x0012fa61 ADD RSP,0x10 LAB_0011d4cd: MOV R14,RAX LAB_0011d4d0: MOV RAX,R14 LEA RSP,[RBP + -0x28] POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
/* WARNING: Type propagation algorithm not settling */ int8 js_call_bound_function (long param_1,long param_2,int8 param_3,int8 param_4,int8 param_5, uint param_6,int4 *param_7,uint param_8) { int4 *puVar1; int4 *puVar2; int8 *puVar3; int8 *puVar4; int8 uVar5; int8 uVar6; int8 uVar7; int4 uVar8; int4 uVar9; int4 uVar10; int iVar11; int8 uVar12; long lVar13; ulong uVar14; long lVar15; ulong uVar16; int8 *puVar17; int8 uStack_70; int4 auStack_68 [2]; int8 uStack_60; long alStack_58 [2]; int8 local_48; int8 uStack_40; int8 local_38; puVar4 = *(int8 **)(param_2 + 0x30); uVar16 = (long)(int)param_6 + (long)*(int *)(puVar4 + 4); if (&stack0xfffffffffffffff8 + uVar16 * -0x10 < *(int1 **)(*(long *)(param_1 + 0x18) + 0xe8) ) { uVar12 = 0; alStack_58[1] = 0x11d3cc; JS_ThrowRangeError(param_1,"Maximum call stack size exceeded"); } else { puVar17 = &local_48 + uVar16 * -2; if (0 < *(int *)(puVar4 + 4)) { lVar15 = 0; lVar13 = 0; do { puVar1 = (int4 *)((long)puVar4 + lVar15 + 0x28); uVar8 = puVar1[1]; uVar9 = puVar1[2]; uVar10 = puVar1[3]; puVar2 = (int4 *)((long)puVar17 + lVar15); *puVar2 = *puVar1; puVar2[1] = uVar8; puVar2[2] = uVar9; puVar2[3] = uVar10; lVar13 = lVar13 + 1; lVar15 = lVar15 + 0x10; } while (lVar13 < *(int *)(puVar4 + 4)); } if (0 < (int)param_6) { uVar14 = 0; do { uVar8 = param_7[1]; uVar9 = param_7[2]; uVar10 = param_7[3]; puVar3 = puVar17 + ((long)*(int *)(puVar4 + 4) + uVar14) * 2; *(int4 *)puVar3 = *param_7; *(int4 *)((long)puVar3 + 4) = uVar8; *(int4 *)(puVar3 + 1) = uVar9; *(int4 *)((long)puVar3 + 0xc) = uVar10; uVar14 = uVar14 + 1; param_7 = param_7 + 4; } while (param_6 != uVar14); } if ((param_8 & 1) == 0) { uVar12 = *puVar4; uVar5 = puVar4[1]; uVar6 = puVar4[2]; uVar7 = puVar4[3]; local_48._0_4_ = 0; uStack_40 = 3; auStack_68[uVar16 * -4] = 0; auStack_68[uVar16 * -4 + 1] = local_48._4_4_; *(int4 *)(&uStack_60 + uVar16 * -2) = 3; *(int4 *)((long)&uStack_60 + uVar16 * -0x10 + 4) = 0; alStack_58[uVar16 * -2] = (long)puVar17; *(int4 *)(&local_48 + uVar16 * -2 + -1) = 2; (&uStack_70)[uVar16 * -2] = 0x11d48a; uVar12 = JS_CallInternal(param_1,uVar12,uVar5,uVar6,uVar7,uVar16 & 0xffffffff); } else { local_38 = param_5; (&local_48)[uVar16 * -2 + -1] = 0x11d49f; iVar11 = js_same_value(param_1); uVar12 = local_38; if (iVar11 != 0) { param_4 = *puVar4; uVar12 = puVar4[1]; } uVar5 = *puVar4; uVar6 = puVar4[1]; (&local_48)[uVar16 * -2 + -1] = 2; alStack_58[uVar16 * -2] = (long)puVar17; (&uStack_60)[uVar16 * -2] = 0x11d4c9; uVar12 = JS_CallConstructorInternal(param_1,uVar5,uVar6,param_4,uVar12,uVar16 & 0xffffffff); } } return uVar12; }
47,434
js_call_bound_function
bluesky950520[P]quickjs/quickjs.c
static JSValue js_call_bound_function(JSContext *ctx, JSValue func_obj, JSValue this_obj, int argc, JSValue *argv, int flags) { JSObject *p; JSBoundFunction *bf; JSValue *arg_buf, new_target; int arg_count, i; p = JS_VALUE_GET_OBJ(func_obj); bf = p->u.bound_function; arg_count = bf->argc + argc; if (js_check_stack_overflow(ctx->rt, sizeof(JSValue) * arg_count)) return JS_ThrowStackOverflow(ctx); arg_buf = alloca(sizeof(JSValue) * arg_count); for(i = 0; i < bf->argc; i++) { arg_buf[i] = bf->argv[i]; } for(i = 0; i < argc; i++) { arg_buf[bf->argc + i] = argv[i]; } if (flags & JS_CALL_FLAG_CONSTRUCTOR) { new_target = this_obj; if (js_same_value(ctx, func_obj, new_target)) new_target = bf->func_obj; return JS_CallConstructor2(ctx, bf->func_obj, new_target, arg_count, arg_buf); } else { return JS_Call(ctx, bf->func_obj, bf->this_val, arg_count, arg_buf); } }
O2
c
js_call_bound_function: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx pushq %rax movq %rdi, %rbx movq %rbp, %r11 movq 0x30(%rsi), %r13 movl 0x20(%r13), %eax leal (%rax,%r9), %r14d movq 0x18(%rdi), %rdi movslq %r14d, %r10 shlq $0x4, %r10 subq %r10, %r11 cmpq 0xe8(%rdi), %r11 jae 0x17a9c movq %rbx, %rdi callq 0x35d91 pushq $0x6 popq %rdx xorl %eax, %eax jmp 0x17b71 movl %r14d, -0x2c(%rbp) movq %rcx, %r12 movq %r8, %r15 movl 0x18(%rbp), %ecx movq 0x10(%rbp), %rdi movslq %eax, %r8 movq %rsp, %r14 addq $0xf, %r10 andq $-0x10, %r10 subq %r10, %r14 movq %r14, %rsp xorl %r10d, %r10d xorl %r11d, %r11d cmpq %r8, %r11 jge 0x17ae0 movups 0x28(%r13,%r10), %xmm0 movups %xmm0, (%r14,%r10) incq %r11 addq $0x10, %r10 jmp 0x17ac7 xorl %r8d, %r8d testl %r9d, %r9d cmovlel %r8d, %r9d shlq $0x4, %r9 cmpq %r8, %r9 je 0x17b0e cltq movq %rax, %r10 shlq $0x4, %r10 movups (%rdi,%r8), %xmm0 movups %xmm0, (%r14,%r10) addq $0x10, %r8 incl %eax jmp 0x17aee testb $0x1, %cl jne 0x17b37 movq (%r13), %rsi movq 0x8(%r13), %rdx movq 0x10(%r13), %rcx movq 0x18(%r13), %r8 subq $0x8, %rsp movq %rbx, %rdi movl -0x2c(%rbp), %r9d pushq %r14 callq 0x21eb6 jmp 0x17b6f movq %rbx, %rdi movq %r12, %rcx movq %r15, %r8 callq 0x1ff32 testl %eax, %eax movq (%r13), %rsi movq 0x8(%r13), %rdx cmovneq %rdx, %r15 cmovneq %rsi, %r12 subq $0x8, %rsp movq %rbx, %rdi movq %r12, %rcx movq %r15, %r8 movl -0x2c(%rbp), %r9d pushq %r14 callq 0x28200 popq %rcx popq %rsi leaq -0x28(%rbp), %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
js_call_bound_function: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx push rax mov rbx, rdi mov r11, rbp mov r13, [rsi+30h] mov eax, [r13+20h] lea r14d, [rax+r9] mov rdi, [rdi+18h] movsxd r10, r14d shl r10, 4 sub r11, r10 cmp r11, [rdi+0E8h] jnb short loc_17A9C mov rdi, rbx call JS_ThrowStackOverflow push 6 pop rdx xor eax, eax jmp loc_17B71 loc_17A9C: mov [rbp+var_2C], r14d mov r12, rcx mov r15, r8 mov ecx, [rbp+arg_8] mov rdi, [rbp+arg_0] movsxd r8, eax mov r14, rsp add r10, 0Fh and r10, 0FFFFFFFFFFFFFFF0h sub r14, r10 mov rsp, r14 xor r10d, r10d xor r11d, r11d loc_17AC7: cmp r11, r8 jge short loc_17AE0 movups xmm0, xmmword ptr [r13+r10+28h] movups xmmword ptr [r14+r10], xmm0 inc r11 add r10, 10h jmp short loc_17AC7 loc_17AE0: xor r8d, r8d test r9d, r9d cmovle r9d, r8d shl r9, 4 loc_17AEE: cmp r9, r8 jz short loc_17B0E cdqe mov r10, rax shl r10, 4 movups xmm0, xmmword ptr [rdi+r8] movups xmmword ptr [r14+r10], xmm0 add r8, 10h inc eax jmp short loc_17AEE loc_17B0E: test cl, 1 jnz short loc_17B37 mov rsi, [r13+0] mov rdx, [r13+8] mov rcx, [r13+10h] mov r8, [r13+18h] sub rsp, 8 mov rdi, rbx mov r9d, [rbp+var_2C] push r14 call JS_Call jmp short loc_17B6F loc_17B37: mov rdi, rbx mov rcx, r12 mov r8, r15 call js_same_value test eax, eax mov rsi, [r13+0] mov rdx, [r13+8] cmovnz r15, rdx cmovnz r12, rsi sub rsp, 8 mov rdi, rbx mov rcx, r12 mov r8, r15 mov r9d, [rbp+var_2C] push r14 call JS_CallConstructor2 loc_17B6F: pop rcx pop rsi loc_17B71: lea rsp, [rbp-28h] pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
long long js_call_bound_function( long long a1, long long a2, long long a3, long long a4, long long a5, long long a6, long long a7, char a8) { long long v8; // rax long long *v9; // r13 int v10; // eax long long v11; // r10 long long v13; // r12 char *v15; // r14 long long v16; // r10 long long i; // r11 long long v18; // r8 long long v19; // r9 long long v20; // [rsp-4h] [rbp-30h] BYREF long long savedregs; // [rsp+2Ch] [rbp+0h] BYREF v20 = v8; v9 = *(long long **)(a2 + 48); v10 = *((_DWORD *)v9 + 8); v11 = 16LL * (v10 + (int)a6); if ( (unsigned long long)&savedregs - v11 >= *(_QWORD *)(*(_QWORD *)(a1 + 24) + 232LL) ) { HIDWORD(v20) = v10 + a6; LODWORD(v13) = a4; v15 = (char *)&v20 - ((v11 + 15) & 0xFFFFFFFFFFFFFFF0LL); v16 = 0LL; for ( i = 0LL; i < v10; ++i ) { *(_OWORD *)&v15[v16 * 8] = *(_OWORD *)&v9[v16 + 5]; v16 += 2LL; } v18 = 0LL; if ( (int)a6 <= 0 ) a6 = 0LL; v19 = 16 * a6; while ( v19 != v18 ) { *(_OWORD *)&v15[16 * v10] = *(_OWORD *)(a7 + v18); v18 += 16LL; ++v10; } if ( (a8 & 1) != 0 ) { if ( (unsigned int)js_same_value(a1, a2, a3, a4, a5) ) { a5 = v9[1]; v13 = *v9; } return JS_CallConstructor2(a1, *v9, v9[1], v13, a5, HIDWORD(v20), (long long)v15); } else { return JS_Call(a1, *v9, v9[1], v9[2], v9[3], HIDWORD(v20), (long long)v15); } } else { JS_ThrowStackOverflow(a1); return 0LL; } }
js_call_bound_function: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX PUSH RAX MOV RBX,RDI MOV R11,RBP MOV R13,qword ptr [RSI + 0x30] MOV EAX,dword ptr [R13 + 0x20] LEA R14D,[RAX + R9*0x1] MOV RDI,qword ptr [RDI + 0x18] MOVSXD R10,R14D SHL R10,0x4 SUB R11,R10 CMP R11,qword ptr [RDI + 0xe8] JNC 0x00117a9c MOV RDI,RBX CALL 0x00135d91 PUSH 0x6 POP RDX XOR EAX,EAX JMP 0x00117b71 LAB_00117a9c: MOV dword ptr [RBP + -0x2c],R14D MOV R12,RCX MOV R15,R8 MOV ECX,dword ptr [RBP + 0x18] MOV RDI,qword ptr [RBP + 0x10] MOVSXD R8,EAX MOV R14,RSP ADD R10,0xf AND R10,-0x10 SUB R14,R10 MOV RSP,R14 XOR R10D,R10D XOR R11D,R11D LAB_00117ac7: CMP R11,R8 JGE 0x00117ae0 MOVUPS XMM0,xmmword ptr [R13 + R10*0x1 + 0x28] MOVUPS xmmword ptr [R14 + R10*0x1],XMM0 INC R11 ADD R10,0x10 JMP 0x00117ac7 LAB_00117ae0: XOR R8D,R8D TEST R9D,R9D CMOVLE R9D,R8D SHL R9,0x4 LAB_00117aee: CMP R9,R8 JZ 0x00117b0e CDQE MOV R10,RAX SHL R10,0x4 MOVUPS XMM0,xmmword ptr [RDI + R8*0x1] MOVUPS xmmword ptr [R14 + R10*0x1],XMM0 ADD R8,0x10 INC EAX JMP 0x00117aee LAB_00117b0e: TEST CL,0x1 JNZ 0x00117b37 MOV RSI,qword ptr [R13] MOV RDX,qword ptr [R13 + 0x8] MOV RCX,qword ptr [R13 + 0x10] MOV R8,qword ptr [R13 + 0x18] SUB RSP,0x8 MOV RDI,RBX MOV R9D,dword ptr [RBP + -0x2c] PUSH R14 CALL 0x00121eb6 JMP 0x00117b6f LAB_00117b37: MOV RDI,RBX MOV RCX,R12 MOV R8,R15 CALL 0x0011ff32 TEST EAX,EAX MOV RSI,qword ptr [R13] MOV RDX,qword ptr [R13 + 0x8] CMOVNZ R15,RDX CMOVNZ R12,RSI SUB RSP,0x8 MOV RDI,RBX MOV RCX,R12 MOV R8,R15 MOV R9D,dword ptr [RBP + -0x2c] PUSH R14 CALL 0x00128200 LAB_00117b6f: POP RCX POP RSI LAB_00117b71: LEA RSP,[RBP + -0x28] POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
int8 js_call_bound_function (long param_1,long param_2,int8 param_3,int8 param_4,int8 param_5, uint param_6,long param_7,uint param_8) { int4 *puVar1; int *piVar2; int *piVar3; int4 *puVar4; int8 *puVar5; int8 uVar6; int8 uVar7; int8 uVar8; int4 uVar9; int4 uVar10; int4 uVar11; int iVar12; int iVar13; int iVar14; int4 in_EAX; int iVar15; int8 uVar16; ulong uVar17; ulong uVar18; long lVar19; long lVar20; long lVar21; int *piVar22; long alStack_50 [3]; int aiStack_38 [2]; puVar5 = *(int8 **)(param_2 + 0x30); iVar15 = *(int *)(puVar5 + 4); lVar19 = (long)(int)(iVar15 + param_6); if (&stack0xfffffffffffffff8 + lVar19 * -0x10 < *(int1 **)(*(long *)(param_1 + 0x18) + 0xe8) ) { alStack_50[2] = 0x117a92; JS_ThrowStackOverflow(param_1); uVar16 = 0; } else { aiStack_38[1] = iVar15 + param_6; aiStack_38[0] = in_EAX; piVar22 = aiStack_38 + lVar19 * -4; lVar20 = 0; for (lVar21 = 0; lVar21 < iVar15; lVar21 = lVar21 + 1) { puVar4 = (int4 *)((long)puVar5 + lVar20 + 0x28); uVar9 = puVar4[1]; uVar10 = puVar4[2]; uVar11 = puVar4[3]; puVar1 = (int4 *)((long)piVar22 + lVar20); *puVar1 = *puVar4; puVar1[1] = uVar9; puVar1[2] = uVar10; puVar1[3] = uVar11; lVar20 = lVar20 + 0x10; } uVar17 = 0; uVar18 = (ulong)param_6; if ((int)param_6 < 1) { uVar18 = uVar17; } for (; uVar18 * 0x10 != uVar17; uVar17 = uVar17 + 0x10) { piVar2 = (int *)(param_7 + uVar17); iVar12 = piVar2[1]; iVar13 = piVar2[2]; iVar14 = piVar2[3]; piVar3 = piVar22 + (long)iVar15 * 4; *piVar3 = *piVar2; piVar3[1] = iVar12; piVar3[2] = iVar13; piVar3[3] = iVar14; iVar15 = iVar15 + 1; } if ((param_8 & 1) == 0) { uVar16 = *puVar5; uVar6 = puVar5[1]; uVar7 = puVar5[2]; uVar8 = puVar5[3]; iVar15 = aiStack_38[1]; alStack_50[lVar19 * -2 + 1] = (long)piVar22; alStack_50[lVar19 * -2] = 0x117b35; uVar16 = JS_Call(param_1,uVar16,uVar6,uVar7,uVar8,iVar15); } else { (aiStack_38 + lVar19 * -4 + -2)[0] = 0x117b45; (aiStack_38 + lVar19 * -4 + -2)[1] = 0; iVar15 = js_same_value(param_1,param_2,param_3,param_4,param_5); uVar16 = *puVar5; uVar6 = puVar5[1]; if (iVar15 != 0) { param_4 = uVar16; param_5 = uVar6; } iVar15 = aiStack_38[1]; alStack_50[lVar19 * -2 + 1] = (long)piVar22; alStack_50[lVar19 * -2] = 0x117b6f; uVar16 = JS_CallConstructor2(param_1,uVar16,uVar6,param_4,param_5,iVar15); } } return uVar16; }
47,435
mbedtls_gf128mul_x_ble
msxemulator/build_O3/_deps/pico_sdk-src/lib/mbedtls/library/aes.c
static void mbedtls_gf128mul_x_ble(unsigned char r[16], const unsigned char x[16]) { uint64_t a, b, ra, rb; a = MBEDTLS_GET_UINT64_LE(x, 0); b = MBEDTLS_GET_UINT64_LE(x, 8); ra = (a << 1) ^ 0x0087 >> (8 - ((b >> 63) << 3)); rb = (a >> 63) | (b << 1); MBEDTLS_PUT_UINT64_LE(ra, r, 0); MBEDTLS_PUT_UINT64_LE(rb, r, 8); }
O3
c
mbedtls_gf128mul_x_ble: pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx movzbl 0x7(%rsi), %r8d movq %r8, %r9 shlq $0x38, %r9 movzbl 0x6(%rsi), %r11d shlq $0x30, %r11 orq %r11, %r9 movzwl 0x4(%rsi), %ebx movq %rbx, %r14 shlq $0x20, %r14 orq %r14, %r11 movzwl 0x2(%rsi), %ebp movzwl (%rsi), %r15d movzbl 0xf(%rsi), %ecx movq %rcx, %rax movzbl 0xe(%rsi), %edx movzwl 0xc(%rsi), %r10d leal (%r15,%r15), %r12d notb %cl shrb $0x4, %cl andb $0x8, %cl movl $0x87, %r13d shrq %cl, %r13 xorl %r12d, %r13d movzwl 0xa(%rsi), %ecx movzwl 0x8(%rsi), %esi movb %r13b, (%rdi) movl %ebp, %r12d shll $0x10, %r12d addq %r12, %r14 orl %r15d, %r12d shrl $0x7, %r15d movb %r15b, 0x1(%rdi) shrl $0xf, %r12d movb %r12b, 0x2(%rdi) shrl $0x7, %ebp movb %bpl, 0x3(%rdi) shrq $0x1f, %r14 movb %r14b, 0x4(%rdi) shrl $0x7, %ebx movb %bl, 0x5(%rdi) shrq $0x2f, %r11 movb %r11b, 0x6(%rdi) shlq $0x38, %rax shlq $0x30, %rdx orq %rdx, %rax shrq $0x37, %r9 movb %r9b, 0x7(%rdi) movq %r10, %r9 shlq $0x20, %r9 orq %r9, %rdx shrl $0x7, %r8d leal (%r8,%rsi,2), %r8d movb %r8b, 0x8(%rdi) movl %ecx, %r8d shll $0x10, %r8d addq %r8, %r9 orl %esi, %r8d shrl $0x7, %esi movb %sil, 0x9(%rdi) shrl $0xf, %r8d movb %r8b, 0xa(%rdi) shrl $0x7, %ecx movb %cl, 0xb(%rdi) shrq $0x1f, %r9 movb %r9b, 0xc(%rdi) shrl $0x7, %r10d movb %r10b, 0xd(%rdi) shrq $0x2f, %rdx movb %dl, 0xe(%rdi) shrq $0x37, %rax movb %al, 0xf(%rdi) popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
mbedtls_gf128mul_x_ble: push rbp push r15 push r14 push r13 push r12 push rbx movzx r8d, byte ptr [rsi+7] mov r9, r8 shl r9, 38h movzx r11d, byte ptr [rsi+6] shl r11, 30h or r9, r11 movzx ebx, word ptr [rsi+4] mov r14, rbx shl r14, 20h or r11, r14 movzx ebp, word ptr [rsi+2] movzx r15d, word ptr [rsi] movzx ecx, byte ptr [rsi+0Fh] mov rax, rcx movzx edx, byte ptr [rsi+0Eh] movzx r10d, word ptr [rsi+0Ch] lea r12d, [r15+r15] not cl shr cl, 4 and cl, 8 mov r13d, 87h shr r13, cl xor r13d, r12d movzx ecx, word ptr [rsi+0Ah] movzx esi, word ptr [rsi+8] mov [rdi], r13b mov r12d, ebp shl r12d, 10h add r14, r12 or r12d, r15d shr r15d, 7 mov [rdi+1], r15b shr r12d, 0Fh mov [rdi+2], r12b shr ebp, 7 mov [rdi+3], bpl shr r14, 1Fh mov [rdi+4], r14b shr ebx, 7 mov [rdi+5], bl shr r11, 2Fh mov [rdi+6], r11b shl rax, 38h shl rdx, 30h or rax, rdx shr r9, 37h mov [rdi+7], r9b mov r9, r10 shl r9, 20h or rdx, r9 shr r8d, 7 lea r8d, [r8+rsi*2] mov [rdi+8], r8b mov r8d, ecx shl r8d, 10h add r9, r8 or r8d, esi shr esi, 7 mov [rdi+9], sil shr r8d, 0Fh mov [rdi+0Ah], r8b shr ecx, 7 mov [rdi+0Bh], cl shr r9, 1Fh mov [rdi+0Ch], r9b shr r10d, 7 mov [rdi+0Dh], r10b shr rdx, 2Fh mov [rdi+0Eh], dl shr rax, 37h mov [rdi+0Fh], al pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
unsigned long long mbedtls_gf128mul_x_ble(_BYTE *a1, unsigned __int16 *a2) { unsigned int v2; // r8d unsigned long long v3; // r11 unsigned long long v4; // r9 unsigned int v5; // ebx unsigned long long v6; // r14 unsigned int v7; // ebp unsigned int v8; // r15d long long v9; // rax unsigned long long v10; // rdx long long v11; // r10 unsigned int v12; // ecx unsigned int v13; // esi long long v14; // r12 long long v15; // r8 unsigned long long result; // rax v2 = *((unsigned __int8 *)a2 + 7); v3 = (unsigned long long)*((unsigned __int8 *)a2 + 6) << 48; v4 = v3 | ((unsigned long long)*((unsigned __int8 *)a2 + 7) << 56); v5 = a2[2]; v6 = (unsigned long long)a2[2] << 32; v7 = a2[1]; v8 = *a2; v9 = *((unsigned __int8 *)a2 + 15); v10 = *((unsigned __int8 *)a2 + 14); v11 = a2[6]; v12 = a2[5]; v13 = a2[4]; *a1 = (2 * v8) ^ (0x87uLL >> (((unsigned __int8)~(_BYTE)v9 >> 4) & 8)); v14 = v7 << 16; a1[1] = v8 >> 7; a1[2] = (v8 | (unsigned int)v14) >> 15; a1[3] = v7 >> 7; a1[4] = (v14 + v6) >> 31; a1[5] = v5 >> 7; a1[6] = (v6 | v3) >> 47; v10 <<= 48; a1[7] = v4 >> 55; a1[8] = (v2 >> 7) + 2 * v13; v15 = v12 << 16; a1[9] = v13 >> 7; a1[10] = (v13 | (unsigned int)v15) >> 15; a1[11] = v12 >> 7; a1[12] = (unsigned long long)(v15 + (v11 << 32)) >> 31; a1[13] = (unsigned int)v11 >> 7; a1[14] = ((v11 << 32) | v10) >> 47; result = (v10 | (v9 << 56)) >> 55; a1[15] = result; return result; }
mbedtls_gf128mul_x_ble: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX MOVZX R8D,byte ptr [RSI + 0x7] MOV R9,R8 SHL R9,0x38 MOVZX R11D,byte ptr [RSI + 0x6] SHL R11,0x30 OR R9,R11 MOVZX EBX,word ptr [RSI + 0x4] MOV R14,RBX SHL R14,0x20 OR R11,R14 MOVZX EBP,word ptr [RSI + 0x2] MOVZX R15D,word ptr [RSI] MOVZX ECX,byte ptr [RSI + 0xf] MOV RAX,RCX MOVZX EDX,byte ptr [RSI + 0xe] MOVZX R10D,word ptr [RSI + 0xc] LEA R12D,[R15 + R15*0x1] NOT CL SHR CL,0x4 AND CL,0x8 MOV R13D,0x87 SHR R13,CL XOR R13D,R12D MOVZX ECX,word ptr [RSI + 0xa] MOVZX ESI,word ptr [RSI + 0x8] MOV byte ptr [RDI],R13B MOV R12D,EBP SHL R12D,0x10 ADD R14,R12 OR R12D,R15D SHR R15D,0x7 MOV byte ptr [RDI + 0x1],R15B SHR R12D,0xf MOV byte ptr [RDI + 0x2],R12B SHR EBP,0x7 MOV byte ptr [RDI + 0x3],BPL SHR R14,0x1f MOV byte ptr [RDI + 0x4],R14B SHR EBX,0x7 MOV byte ptr [RDI + 0x5],BL SHR R11,0x2f MOV byte ptr [RDI + 0x6],R11B SHL RAX,0x38 SHL RDX,0x30 OR RAX,RDX SHR R9,0x37 MOV byte ptr [RDI + 0x7],R9B MOV R9,R10 SHL R9,0x20 OR RDX,R9 SHR R8D,0x7 LEA R8D,[R8 + RSI*0x2] MOV byte ptr [RDI + 0x8],R8B MOV R8D,ECX SHL R8D,0x10 ADD R9,R8 OR R8D,ESI SHR ESI,0x7 MOV byte ptr [RDI + 0x9],SIL SHR R8D,0xf MOV byte ptr [RDI + 0xa],R8B SHR ECX,0x7 MOV byte ptr [RDI + 0xb],CL SHR R9,0x1f MOV byte ptr [RDI + 0xc],R9B SHR R10D,0x7 MOV byte ptr [RDI + 0xd],R10B SHR RDX,0x2f MOV byte ptr [RDI + 0xe],DL SHR RAX,0x37 MOV byte ptr [RDI + 0xf],AL POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
void mbedtls_gf128mul_x_ble(byte *param_1,uint *param_2) { byte bVar1; byte bVar2; byte bVar3; ushort uVar4; ushort uVar5; ushort uVar6; uint uVar7; uint uVar8; uint uVar9; uint uVar10; uint uVar11; uint uVar12; uint uVar13; ulong uVar14; ulong uVar15; bVar1 = *(byte *)((long)param_2 + 7); uVar15 = (ulong)*(byte *)((long)param_2 + 6) << 0x30; uVar11 = param_2[1]; uVar4 = *(ushort *)((long)param_2 + 2); uVar7 = *(uint *)((long)param_2 + 2); uVar12 = *param_2; uVar8 = *param_2; bVar2 = *(byte *)((long)param_2 + 0xf); bVar3 = *(byte *)((long)param_2 + 0xe); uVar13 = param_2[3]; uVar5 = *(ushort *)((long)param_2 + 10); uVar9 = *(uint *)((long)param_2 + 10); uVar6 = (ushort)param_2[2]; uVar10 = param_2[2]; *param_1 = (byte)(0x87L >> ((byte)~bVar2 >> 4 & 8)) ^ (char)(ushort)uVar12 * '\x02'; param_1[1] = (byte)((ushort)uVar12 >> 7); param_1[2] = (byte)(uVar8 >> 0xf); param_1[3] = (byte)(uVar4 >> 7); param_1[4] = (byte)(uVar7 >> 0xf); param_1[5] = (byte)((ushort)uVar11 >> 7); param_1[6] = (byte)((uVar15 | (ulong)(ushort)uVar11 << 0x20) >> 0x2f); uVar14 = (ulong)bVar3 << 0x30; param_1[7] = (byte)(((ulong)bVar1 << 0x38 | uVar15) >> 0x37); param_1[8] = (char)uVar6 * '\x02' - ((char)bVar1 >> 7); param_1[9] = (byte)(uVar6 >> 7); param_1[10] = (byte)(uVar10 >> 0xf); param_1[0xb] = (byte)(uVar5 >> 7); param_1[0xc] = (byte)(uVar9 >> 0xf); param_1[0xd] = (byte)((ushort)uVar13 >> 7); param_1[0xe] = (byte)((uVar14 | (ulong)(ushort)uVar13 << 0x20) >> 0x2f); param_1[0xf] = (byte)(((ulong)bVar2 << 0x38 | uVar14) >> 0x37); return; }
47,436
nlohmann::json_abi_v3_11_3::detail::invalid_iterator nlohmann::json_abi_v3_11_3::detail::invalid_iterator::create<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> const*, 0>(int, 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> const*)
hkr04[P]cpp-mcp/common/json.hpp
static invalid_iterator create(int id_, const std::string& what_arg, BasicJsonContext context) { const std::string w = concat(exception::name("invalid_iterator", id_), exception::diagnostics(context), what_arg); return {id_, w.c_str()}; }
O3
cpp
nlohmann::json_abi_v3_11_3::detail::invalid_iterator nlohmann::json_abi_v3_11_3::detail::invalid_iterator::create<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> const*, 0>(int, 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> const*): pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x98, %rsp movq %rdx, %r15 movl %esi, %ebp movq %rdi, %rbx leaq 0x38(%rsp), %r13 movq %r13, -0x10(%r13) leaq 0x23a1(%rip), %rsi # 0x1fd7a leaq 0x23aa(%rip), %rdx # 0x1fd8a leaq 0x28(%rsp), %rdi callq 0x78c6 leaq 0x48(%rsp), %rdi leaq 0x28(%rsp), %rsi movl %ebp, %edx callq 0x8cf8 leaq 0x78(%rsp), %r14 movq %r14, -0x10(%r14) xorl %eax, %eax movq %rax, -0x8(%r14) movb %al, (%r14) leaq 0x18(%rsp), %r12 movq %r12, -0x10(%r12) movq %rax, -0x8(%r12) movb %al, (%r12) movq 0x8(%r15), %rsi addq 0x50(%rsp), %rsi leaq 0x8(%rsp), %rdi callq 0x5660 movq 0x48(%rsp), %rsi movq 0x50(%rsp), %rdx leaq 0x8(%rsp), %rdi callq 0x5120 movq 0x68(%rsp), %rsi movq 0x70(%rsp), %rdx leaq 0x8(%rsp), %rdi callq 0x5120 movq (%r15), %rsi movq 0x8(%r15), %rdx leaq 0x8(%rsp), %rdi callq 0x5120 movq 0x68(%rsp), %rdi cmpq %r14, %rdi je 0x1da83 movq 0x78(%rsp), %rsi incq %rsi callq 0x5460 leaq 0x58(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0x1da9e movq 0x58(%rsp), %rsi incq %rsi callq 0x5460 movq 0x28(%rsp), %rdi cmpq %r13, %rdi je 0x1dab5 movq 0x38(%rsp), %rsi incq %rsi callq 0x5460 movq 0x8(%rsp), %rdx movq %rbx, %rdi movl %ebp, %esi callq 0x8f60 leaq 0xd025(%rip), %rax # 0x2aaf0 movq %rax, (%rbx) movq 0x8(%rsp), %rdi cmpq %r12, %rdi je 0x1dae5 movq 0x18(%rsp), %rsi incq %rsi callq 0x5460 movq %rbx, %rax addq $0x98, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq movq %rax, %rbx movq 0x8(%rsp), %rdi cmpq %r12, %rdi je 0x1db73 movq 0x18(%rsp), %rsi jmp 0x1db6b movq %rax, %rbx jmp 0x1db5c movq %rax, %rbx jmp 0x1db73 movq %rdx, %rbx movq %rax, %r15 movq 0x8(%rsp), %rdi cmpq %r12, %rdi je 0x1db35 movq 0x18(%rsp), %rsi incq %rsi callq 0x5460 leaq 0x68(%rsp), %rdi leaq 0x48(%rsp), %rdx leaq 0x88(%rsp), %r12 movq %r14, %rsi movq %r15, %rcx movl %ebx, %r8d movq %r12, %r9 callq 0x622c movq (%r12), %rbx movq 0x28(%rsp), %rdi cmpq %r13, %rdi je 0x1db73 movq 0x38(%rsp), %rsi incq %rsi callq 0x5460 movq %rbx, %rdi callq 0x5740 nop
_ZN8nlohmann16json_abi_v3_11_36detail16invalid_iterator6createIPKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SK_: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 98h mov r15, rdx mov ebp, esi mov rbx, rdi lea r13, [rsp+0C8h+var_90] mov [r13-10h], r13 lea rsi, aInvalidIterato; "invalid_iterator" lea rdx, aInvalidIterato+10h; "" lea rdi, [rsp+0C8h+var_A0] 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) lea rdi, [rsp+0C8h+var_80]; int lea rsi, [rsp+0C8h+var_A0]; int mov edx, ebp; int call _ZN8nlohmann16json_abi_v3_11_36detail9exception4nameERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEi; nlohmann::json_abi_v3_11_3::detail::exception::name(std::string const&,int) lea r14, [rsp+0C8h+var_50] mov [r14-10h], r14 xor eax, eax mov [r14-8], rax mov [r14], al lea r12, [rsp+0C8h+var_B0] mov [r12-10h], r12 mov [r12-8], rax mov [r12], al mov rsi, [r15+8] add rsi, [rsp+0C8h+var_78] lea rdi, [rsp+0C8h+var_C0] call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE7reserveEm; std::string::reserve(ulong) mov rsi, qword ptr [rsp+0C8h+var_80] mov rdx, [rsp+0C8h+var_78] lea rdi, [rsp+0C8h+var_C0] call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9_M_appendEPKcm; std::string::_M_append(char const*,ulong) mov rsi, [rsp+0C8h+var_60] mov rdx, [rsp+0C8h+var_58] lea rdi, [rsp+0C8h+var_C0] call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9_M_appendEPKcm; std::string::_M_append(char const*,ulong) mov rsi, [r15] mov rdx, [r15+8] lea rdi, [rsp+0C8h+var_C0] call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9_M_appendEPKcm; std::string::_M_append(char const*,ulong) mov rdi, [rsp+0C8h+var_60]; void * cmp rdi, r14 jz short loc_1DA83 mov rsi, [rsp+0C8h+var_50] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_1DA83: lea rax, [rsp+0C8h+var_70] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_1DA9E mov rsi, [rsp+0C8h+var_70] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_1DA9E: mov rdi, [rsp+0C8h+var_A0]; void * cmp rdi, r13 jz short loc_1DAB5 mov rsi, [rsp+0C8h+var_90] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_1DAB5: mov rdx, [rsp+0C8h+var_C0]; char * mov rdi, rbx; this mov esi, ebp; int call _ZN8nlohmann16json_abi_v3_11_36detail9exceptionC2EiPKc; nlohmann::json_abi_v3_11_3::detail::exception::exception(int,char const*) lea rax, off_2AAF0 mov [rbx], rax mov rdi, [rsp+0C8h+var_C0]; void * cmp rdi, r12 jz short loc_1DAE5 mov rsi, [rsp+0C8h+var_B0] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_1DAE5: mov rax, rbx add rsp, 98h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn mov rbx, rax mov rdi, [rsp+arg_0] cmp rdi, r12 jz short loc_1DB73 mov rsi, [rsp+arg_10] jmp short loc_1DB6B mov rbx, rax jmp short loc_1DB5C mov rbx, rax jmp short loc_1DB73 mov rbx, rdx mov r15, rax mov rdi, [rsp+arg_0]; void * cmp rdi, r12 jz short loc_1DB35 mov rsi, [rsp+arg_10] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_1DB35: lea rdi, [rsp+arg_60] lea rdx, [rsp+arg_40] lea r12, [rsp+arg_80] mov rsi, r14 mov rcx, r15 mov r8d, ebx mov r9, r12 call _ZN8nlohmann16json_abi_v3_11_36detail16invalid_iterator6createIPKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SK__cold_1 mov rbx, [r12] loc_1DB5C: mov rdi, [rsp+arg_20]; void * cmp rdi, r13 jz short loc_1DB73 mov rsi, [rsp+arg_30] loc_1DB6B: inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_1DB73: mov rdi, rbx call __Unwind_Resume
nlohmann::json_abi_v3_11_3::detail::exception * ZN8nlohmann16json_abi_v3_11_36detail16invalid_iterator6createIPKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SK_( nlohmann::json_abi_v3_11_3::detail::exception *this, int a2, _QWORD *a3) { char *v5[2]; // [rsp+8h] [rbp-C0h] BYREF _QWORD v6[2]; // [rsp+18h] [rbp-B0h] BYREF void *v7[2]; // [rsp+28h] [rbp-A0h] BYREF _QWORD v8[2]; // [rsp+38h] [rbp-90h] BYREF int v9[2]; // [rsp+48h] [rbp-80h] BYREF long long v10; // [rsp+50h] [rbp-78h] long long v11; // [rsp+58h] [rbp-70h] BYREF void *v12; // [rsp+68h] [rbp-60h] long long v13; // [rsp+70h] [rbp-58h] _QWORD v14[10]; // [rsp+78h] [rbp-50h] BYREF v7[0] = v8; std::string::_M_construct<char const*>((long long)v7, "invalid_iterator", (long long)""); nlohmann::json_abi_v3_11_3::detail::exception::name((long long)v9, (long long)v7, a2); v12 = v14; v13 = 0LL; LOBYTE(v14[0]) = 0; v5[0] = (char *)v6; v5[1] = 0LL; LOBYTE(v6[0]) = 0; std::string::reserve(v5, v10 + a3[1]); std::string::_M_append(v5, *(_QWORD *)v9, v10); std::string::_M_append(v5, v12, v13); std::string::_M_append(v5, *a3, a3[1]); if ( v12 != v14 ) operator delete(v12, v14[0] + 1LL); if ( *(long long **)v9 != &v11 ) operator delete(*(void **)v9, v11 + 1); if ( v7[0] != v8 ) operator delete(v7[0], v8[0] + 1LL); nlohmann::json_abi_v3_11_3::detail::exception::exception(this, a2, v5[0]); *(_QWORD *)this = off_2AAF0; if ( (_QWORD *)v5[0] != v6 ) operator delete(v5[0], v6[0] + 1LL); return this; }
_ZN8nlohmann16json_abi_v3_11_36detail16invalid_iterator6createIPKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SK_: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x98 MOV R15,RDX MOV EBP,ESI MOV RBX,RDI LEA R13,[RSP + 0x38] MOV qword ptr [R13 + -0x10],R13 LAB_0011d9d2: LEA RSI,[0x11fd7a] LEA RDX,[0x11fd8a] LEA RDI,[RSP + 0x28] CALL 0x001078c6 LAB_0011d9ea: LEA RDI,[RSP + 0x48] LEA RSI,[RSP + 0x28] MOV EDX,EBP CALL 0x00108cf8 LEA R14,[RSP + 0x78] MOV qword ptr [R14 + -0x10],R14 XOR EAX,EAX MOV qword ptr [R14 + -0x8],RAX MOV byte ptr [R14],AL LEA R12,[RSP + 0x18] MOV qword ptr [R12 + -0x10],R12 MOV qword ptr [R12 + -0x8],RAX MOV byte ptr [R12],AL MOV RSI,qword ptr [R15 + 0x8] ADD RSI,qword ptr [RSP + 0x50] LAB_0011da29: LEA RDI,[RSP + 0x8] CALL 0x00105660 MOV RSI,qword ptr [RSP + 0x48] MOV RDX,qword ptr [RSP + 0x50] LEA RDI,[RSP + 0x8] CALL 0x00105120 MOV RSI,qword ptr [RSP + 0x68] MOV RDX,qword ptr [RSP + 0x70] LEA RDI,[RSP + 0x8] CALL 0x00105120 MOV RSI,qword ptr [R15] MOV RDX,qword ptr [R15 + 0x8] LEA RDI,[RSP + 0x8] CALL 0x00105120 MOV RDI,qword ptr [RSP + 0x68] CMP RDI,R14 JZ 0x0011da83 MOV RSI,qword ptr [RSP + 0x78] INC RSI CALL 0x00105460 LAB_0011da83: LEA RAX,[RSP + 0x58] MOV RDI,qword ptr [RAX + -0x10] CMP RDI,RAX JZ 0x0011da9e MOV RSI,qword ptr [RSP + 0x58] INC RSI CALL 0x00105460 LAB_0011da9e: MOV RDI,qword ptr [RSP + 0x28] CMP RDI,R13 JZ 0x0011dab5 MOV RSI,qword ptr [RSP + 0x38] INC RSI CALL 0x00105460 LAB_0011dab5: MOV RDX,qword ptr [RSP + 0x8] LAB_0011daba: MOV RDI,RBX MOV ESI,EBP CALL 0x00108f60 LAB_0011dac4: LEA RAX,[0x12aaf0] MOV qword ptr [RBX],RAX MOV RDI,qword ptr [RSP + 0x8] CMP RDI,R12 JZ 0x0011dae5 MOV RSI,qword ptr [RSP + 0x18] INC RSI CALL 0x00105460 LAB_0011dae5: MOV RAX,RBX ADD RSP,0x98 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
exception * _ZN8nlohmann16json_abi_v3_11_36detail16invalid_iterator6createIPKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SK_ (exception *param_1,int param_2,ulong *param_3) { char *local_c0; int8 local_b8; char local_b0; int7 uStack_af; long *local_a0 [2]; long local_90 [2]; long *local_80 [2]; long local_70 [2]; int1 *local_60; int8 local_58; int1 local_50; int7 uStack_4f; /* try { // try from 0011d9d2 to 0011d9e9 has its CatchHandler @ 0011db13 */ local_a0[0] = local_90; std::__cxx11::string::_M_construct<char_const*>(local_a0,"invalid_iterator",""); /* try { // try from 0011d9ea to 0011d9fa has its CatchHandler @ 0011db0e */ nlohmann::json_abi_v3_11_3::detail::exception::name ((exception *)local_80,(string *)local_a0,param_2); local_58 = 0; local_50 = 0; local_b8 = 0; local_b0 = '\0'; /* try { // try from 0011da29 to 0011da6b has its CatchHandler @ 0011db18 */ local_c0 = &local_b0; local_60 = &local_50; std::__cxx11::string::reserve((ulong)&local_c0); std::__cxx11::string::_M_append((char *)&local_c0,(ulong)local_80[0]); std::__cxx11::string::_M_append((char *)&local_c0,(ulong)local_60); std::__cxx11::string::_M_append((char *)&local_c0,*param_3); if (local_60 != &local_50) { operator_delete(local_60,CONCAT71(uStack_4f,local_50) + 1); } if (local_80[0] != local_70) { operator_delete(local_80[0],local_70[0] + 1); } if (local_a0[0] != local_90) { operator_delete(local_a0[0],local_90[0] + 1); } /* try { // try from 0011daba to 0011dac3 has its CatchHandler @ 0011dafa */ nlohmann::json_abi_v3_11_3::detail::exception::exception(param_1,param_2,local_c0); *(int ***)param_1 = &PTR__exception_0012aaf0; if (local_c0 != &local_b0) { operator_delete(local_c0,CONCAT71(uStack_af,local_b0) + 1); } return param_1; }
47,437
ma_tls_write
eloqsql/libmariadb/libmariadb/secure/openssl.c
ssize_t ma_tls_write(MARIADB_TLS *ctls, const uchar* buffer, size_t length) { int rc; MARIADB_PVIO *pvio= ctls->pvio; while ((rc= SSL_write((SSL *)ctls->ssl, (void *)buffer, (int)length)) <= 0) { int error= SSL_get_error((SSL *)ctls->ssl, rc); if (error != SSL_ERROR_WANT_WRITE) break; if (pvio->methods->wait_io_or_timeout(pvio, TRUE, pvio->mysql->options.write_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_write: 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 0x13830 movl %eax, %r14d testl %eax, %eax jg 0x290a3 movq 0x10(%r15), %rdi movl %r14d, %esi callq 0x13050 cmpl $0x3, %eax jne 0x29090 movq 0x40(%r13), %rax movq 0x48(%r13), %rcx movl 0x398(%rax), %edx movq %r13, %rdi movl $0x1, %esi callq *0x30(%rcx) testl %eax, %eax jg 0x2904d movq 0x10(%r15), %rdi xorl %esi, %esi callq 0x13160 movq %rax, %rdi callq 0x28da0 movslq %r14d, %rax addq $0x8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
ma_tls_write: 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_2904D: mov rdi, [r15+10h] mov rsi, r12 mov edx, ebx call _SSL_write mov r14d, eax test eax, eax jg short loc_290A3 mov rdi, [r15+10h] mov esi, r14d call _SSL_get_error cmp eax, 3 jnz short loc_29090 mov rax, [r13+40h] mov rcx, [r13+48h] mov edx, [rax+398h] mov rdi, r13 mov esi, 1 call qword ptr [rcx+30h] test eax, eax jg short loc_2904D loc_29090: mov rdi, [r15+10h] xor esi, esi call _SSL_get_ex_data mov rdi, rax call ma_tls_set_error loc_290A3: movsxd rax, r14d add rsp, 8 pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
long long ma_tls_write(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_write(*(_QWORD *)(a1 + 16), a2, a3); v6 = v5; if ( v5 > 0 ) break; if ( (unsigned int)SSL_get_error(*(_QWORD *)(a1 + 16), (unsigned int)v5) != 3 || (*(int ( **)(long long, long long, _QWORD))(*(_QWORD *)(v4 + 72) + 48LL))( v4, 1LL, *(unsigned int *)(*(_QWORD *)(v4 + 64) + 920LL)) <= 0 ) { v7 = (long long *)SSL_get_ex_data(*(_QWORD *)(a1 + 16), 0LL); ma_tls_set_error(v7); return v6; } } return v6; }
ma_tls_write: 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_0012904d: MOV RDI,qword ptr [R15 + 0x10] MOV RSI,R12 MOV EDX,EBX CALL 0x00113830 MOV R14D,EAX TEST EAX,EAX JG 0x001290a3 MOV RDI,qword ptr [R15 + 0x10] MOV ESI,R14D CALL 0x00113050 CMP EAX,0x3 JNZ 0x00129090 MOV RAX,qword ptr [R13 + 0x40] MOV RCX,qword ptr [R13 + 0x48] MOV EDX,dword ptr [RAX + 0x398] MOV RDI,R13 MOV ESI,0x1 CALL qword ptr [RCX + 0x30] TEST EAX,EAX JG 0x0012904d LAB_00129090: MOV RDI,qword ptr [R15 + 0x10] XOR ESI,ESI CALL 0x00113160 MOV RDI,RAX CALL 0x00128da0 LAB_001290a3: MOVSXD RAX,R14D ADD RSP,0x8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
long ma_tls_write(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_write(*(SSL **)(param_1 + 0x10),param_2,param_3); if (0 < ret_code) goto LAB_001290a3; iVar2 = SSL_get_error(*(SSL **)(param_1 + 0x10),ret_code); if (iVar2 != 3) break; iVar2 = (**(code **)(*(long *)(lVar1 + 0x48) + 0x30)) (lVar1,1,*(int4 *)(*(long *)(lVar1 + 0x40) + 0x398)); } while (0 < iVar2); pvVar3 = SSL_get_ex_data(*(SSL **)(param_1 + 0x10),0); ma_tls_set_error(pvVar3); LAB_001290a3: return (long)ret_code; }
47,438
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::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>, minja::Value, std::less<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::allocator<std::pair<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> const, minja::Value>>>::erase(__gnu_cxx::__normal_iterator<std::pair<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> const, minja::Value>*, std::vector<std::pair<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> 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::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> const, minja::Value>>>>, __gnu_cxx::__normal_iterator<std::pair<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> const, minja::Value>*, std::vector<std::pair<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> 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::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> const, minja::Value>>>>)
monkey531[P]llama/common/json.hpp
iterator erase(iterator first, iterator last) { if (first == last) { return first; } const auto elements_affected = std::distance(first, last); const auto offset = std::distance(Container::begin(), first); // This is the start situation. We need to delete elements_affected // elements (3 in this example: e, f, g), and need to return an // iterator past the last deleted element (h in this example). // Note that offset is the distance from the start of the vector // to first. We will need this later. // [ a, b, c, d, e, f, g, h, i, j ] // ^ ^ // first last // Since we cannot move const Keys, we re-construct them in place. // We start at first and re-construct (viz. copy) the elements from // the back of the vector. Example for first iteration: // ,--------. // v | destroy e and re-construct with h // [ a, b, c, d, e, f, g, h, i, j ] // ^ ^ // it it + elements_affected for (auto it = first; std::next(it, elements_affected) != Container::end(); ++it) { it->~value_type(); // destroy but keep allocation new (&*it) value_type{std::move(*std::next(it, elements_affected))}; // "move" next element to it } // [ a, b, c, d, h, i, j, h, i, j ] // ^ ^ // first last // remove the unneeded elements at the end of the vector Container::resize(this->size() - static_cast<size_type>(elements_affected)); // [ a, b, c, d, h, i, j ] // ^ ^ // first last // first is now pointing past the last deleted element, but we cannot // use this iterator, because it may have been invalidated by the // resize call. Instead, we can return begin() + offset. return Container::begin() + offset; }
O2
cpp
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::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>, minja::Value, std::less<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::allocator<std::pair<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> const, minja::Value>>>::erase(__gnu_cxx::__normal_iterator<std::pair<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> const, minja::Value>*, std::vector<std::pair<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> 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::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> const, minja::Value>>>>, __gnu_cxx::__normal_iterator<std::pair<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> const, minja::Value>*, std::vector<std::pair<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> 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::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> const, minja::Value>>>>): pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx pushq %rax movq %rsi, %rbx cmpq %rdx, %rsi je 0x4fd5d movq %rdi, %r14 subq %rbx, %rdx pushq $0x60 popq %rcx movq %rdx, %rax cqto idivq %rcx movq %rax, %r15 movq (%rdi), %rax movq %rax, (%rsp) imulq $0x60, %r15, %r13 addq %rbx, %r13 movq %r13, %r12 negq %r12 movq %rbx, %rbp cmpq 0x8(%r14), %r13 je 0x4fd37 movq %rbp, %rdi callq 0x49bd6 movq %rbp, %rdi movq %r13, %rsi callq 0x4fd70 addq $0x60, %rbp addq $0x60, %r13 addq $-0x60, %r12 jmp 0x4fd10 subq (%rsp), %rbx addq (%r14), %r12 negq %r12 movq %r12, %rax cqto pushq $0x60 popq %rcx idivq %rcx subq %r15, %rax movq %r14, %rdi movq %rax, %rsi callq 0x4fd9a addq (%r14), %rbx movq %rbx, %rax addq $0x8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq nop
_ZN8nlohmann16json_abi_v3_11_311ordered_mapINS0_10basic_jsonIS1_St6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEEN5minja5ValueESt4lessISD_ESaISt4pairIKSD_SF_EEE5eraseEN9__gnu_cxx17__normal_iteratorIPSK_S3_ISK_SL_EEESR_: push rbp push r15 push r14 push r13 push r12 push rbx push rax mov rbx, rsi cmp rsi, rdx jz short loc_4FD5D mov r14, rdi sub rdx, rbx push 60h ; '`' pop rcx mov rax, rdx cqo idiv rcx mov r15, rax mov rax, [rdi] mov [rsp+38h+var_38], rax imul r13, r15, 60h ; '`' add r13, rbx mov r12, r13 neg r12 mov rbp, rbx loc_4FD10: cmp r13, [r14+8] jz short loc_4FD37 mov rdi, rbp call _ZNSt4pairIKN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES4_IhSaIhEEvEEN5minja5ValueEED2Ev; 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>::~pair() mov rdi, rbp mov rsi, r13 call _ZNSt4pairIKN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES4_IhSaIhEEvEEN5minja5ValueEEC2EOSI_; 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>::pair(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>&&) add rbp, 60h ; '`' add r13, 60h ; '`' add r12, 0FFFFFFFFFFFFFFA0h jmp short loc_4FD10 loc_4FD37: sub rbx, [rsp+38h+var_38] add r12, [r14] neg r12 mov rax, r12 cqo push 60h ; '`' pop rcx idiv rcx sub rax, r15 mov rdi, r14 mov rsi, rax call _ZNSt6vectorISt4pairIKN8nlohmann16json_abi_v3_11_310basic_jsonINS2_11ordered_mapES_NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS2_14adl_serializerES_IhSaIhEEvEEN5minja5ValueEESaISI_EE6resizeEm; 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>>::resize(ulong) add rbx, [r14] loc_4FD5D: mov rax, rbx add rsp, 8 pop rbx pop r12 pop r13 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>>>::erase( long long *a1, long long a2, long long a3) { long long v3; // rbx long long v4; // r15 long long v5; // r13 long long v6; // r12 long long v7; // rbp long long v9; // [rsp+0h] [rbp-38h] v3 = a2; if ( a2 != a3 ) { v4 = (a3 - a2) / 96; v9 = *a1; v5 = a2 + 96 * v4; v6 = -v5; v7 = a2; while ( v5 != a1[1] ) { 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>::~pair(v7); 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>::pair( v7, v5); v7 += 96LL; v5 += 96LL; v6 -= 96LL; } 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>>::resize( a1, -(*a1 + v6) / 96 - v4, -(*a1 + v6) % 96); return *a1 + a2 - v9; } return v3; }
erase: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX PUSH RAX MOV RBX,RSI CMP RSI,RDX JZ 0x0014fd5d MOV R14,RDI SUB RDX,RBX PUSH 0x60 POP RCX MOV RAX,RDX CQO IDIV RCX MOV R15,RAX MOV RAX,qword ptr [RDI] MOV qword ptr [RSP],RAX IMUL R13,R15,0x60 ADD R13,RBX MOV R12,R13 NEG R12 MOV RBP,RBX LAB_0014fd10: CMP R13,qword ptr [R14 + 0x8] JZ 0x0014fd37 MOV RDI,RBP CALL 0x00149bd6 MOV RDI,RBP MOV RSI,R13 CALL 0x0014fd70 ADD RBP,0x60 ADD R13,0x60 ADD R12,-0x60 JMP 0x0014fd10 LAB_0014fd37: SUB RBX,qword ptr [RSP] ADD R12,qword ptr [R14] NEG R12 MOV RAX,R12 CQO PUSH 0x60 POP RCX IDIV RCX SUB RAX,R15 MOV RDI,R14 MOV RSI,RAX CALL 0x0014fd9a ADD RBX,qword ptr [R14] LAB_0014fd5d: MOV RAX,RBX ADD RSP,0x8 POP RBX POP R12 POP R13 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> > >::erase(__gnu_cxx::__normal_iterator<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::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> > > >, __gnu_cxx::__normal_iterator<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::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> > > >) */ 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> * __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>>> ::erase(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,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> *param_2, 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> *param_3) { long lVar1; long lVar2; 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_00; long lVar3; pair *ppVar4; if (param_2 != param_3) { lVar2 = ((long)param_3 - (long)param_2) / 0x60; lVar1 = *(long *)this; ppVar4 = (pair *)(param_2 + lVar2 * 0x60); lVar3 = -(long)ppVar4; this_00 = param_2; for (; ppVar4 != *(pair **)(this + 8); ppVar4 = ppVar4 + 0x60) { 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> ::~pair(this_00); 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> ::pair(this_00,ppVar4); this_00 = this_00 + 0x60; lVar3 = lVar3 + -0x60; } 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>>> ::resize((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,-(lVar3 + *(long *)this) / 0x60 - lVar2); param_2 = param_2 + (*(long *)this - lVar1); } return param_2; }
47,439
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::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>, minja::Value, std::less<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::allocator<std::pair<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> const, minja::Value>>>::erase(__gnu_cxx::__normal_iterator<std::pair<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> const, minja::Value>*, std::vector<std::pair<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> 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::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> const, minja::Value>>>>, __gnu_cxx::__normal_iterator<std::pair<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> const, minja::Value>*, std::vector<std::pair<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> 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::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> const, minja::Value>>>>)
monkey531[P]llama/common/json.hpp
iterator erase(iterator first, iterator last) { if (first == last) { return first; } const auto elements_affected = std::distance(first, last); const auto offset = std::distance(Container::begin(), first); // This is the start situation. We need to delete elements_affected // elements (3 in this example: e, f, g), and need to return an // iterator past the last deleted element (h in this example). // Note that offset is the distance from the start of the vector // to first. We will need this later. // [ a, b, c, d, e, f, g, h, i, j ] // ^ ^ // first last // Since we cannot move const Keys, we re-construct them in place. // We start at first and re-construct (viz. copy) the elements from // the back of the vector. Example for first iteration: // ,--------. // v | destroy e and re-construct with h // [ a, b, c, d, e, f, g, h, i, j ] // ^ ^ // it it + elements_affected for (auto it = first; std::next(it, elements_affected) != Container::end(); ++it) { it->~value_type(); // destroy but keep allocation new (&*it) value_type{std::move(*std::next(it, elements_affected))}; // "move" next element to it } // [ a, b, c, d, h, i, j, h, i, j ] // ^ ^ // first last // remove the unneeded elements at the end of the vector Container::resize(this->size() - static_cast<size_type>(elements_affected)); // [ a, b, c, d, h, i, j ] // ^ ^ // first last // first is now pointing past the last deleted element, but we cannot // use this iterator, because it may have been invalidated by the // resize call. Instead, we can return begin() + offset. return Container::begin() + offset; }
O3
cpp
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::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>, minja::Value, std::less<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::allocator<std::pair<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> const, minja::Value>>>::erase(__gnu_cxx::__normal_iterator<std::pair<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> const, minja::Value>*, std::vector<std::pair<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> 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::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> const, minja::Value>>>>, __gnu_cxx::__normal_iterator<std::pair<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> const, minja::Value>*, std::vector<std::pair<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> 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::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> const, minja::Value>>>>): pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx pushq %rax movq %rsi, %rbx cmpq %rdx, %rsi je 0x54dc9 movq %rdx, %r12 movq %rdi, %r14 movq %rdx, %rbp subq %rbx, %rbp sarq $0x5, %rbp movabsq $-0x5555555555555555, %rax # imm = 0xAAAAAAAAAAAAAAAB imulq %rax, %rbp movq (%rdi), %rax movq %rax, (%rsp) movq %rdx, %r15 negq %r15 movq %rbx, %r13 cmpq 0x8(%r14), %r12 je 0x54d9c movq %r13, %rdi callq 0x4d61e movq %r13, %rdi movq %r12, %rsi callq 0x54ddc addq $0x60, %r13 addq $0x60, %r12 addq $-0x60, %r15 jmp 0x54d75 subq (%rsp), %rbx addq (%r14), %r15 negq %r15 sarq $0x5, %r15 movabsq $-0x5555555555555555, %rax # imm = 0xAAAAAAAAAAAAAAAB imulq %rax, %r15 subq %rbp, %r15 movq %r14, %rdi movq %r15, %rsi callq 0x54e68 addq (%r14), %rbx movq %rbx, %rax addq $0x8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq nop
_ZN8nlohmann16json_abi_v3_11_311ordered_mapINS0_10basic_jsonIS1_St6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEEN5minja5ValueESt4lessISD_ESaISt4pairIKSD_SF_EEE5eraseEN9__gnu_cxx17__normal_iteratorIPSK_S3_ISK_SL_EEESR_: push rbp push r15 push r14 push r13 push r12 push rbx push rax mov rbx, rsi cmp rsi, rdx jz loc_54DC9 mov r12, rdx mov r14, rdi mov rbp, rdx sub rbp, rbx sar rbp, 5 mov rax, 0AAAAAAAAAAAAAAABh imul rbp, rax mov rax, [rdi] mov [rsp+38h+var_38], rax mov r15, rdx neg r15 mov r13, rbx loc_54D75: cmp r12, [r14+8] jz short loc_54D9C mov rdi, r13 call _ZNSt4pairIKN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES4_IhSaIhEEvEEN5minja5ValueEED2Ev; 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>::~pair() mov rdi, r13 mov rsi, r12 call _ZNSt4pairIKN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES4_IhSaIhEEvEEN5minja5ValueEEC2EOSI_; 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>::pair(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>&&) add r13, 60h ; '`' add r12, 60h ; '`' add r15, 0FFFFFFFFFFFFFFA0h jmp short loc_54D75 loc_54D9C: sub rbx, [rsp+38h+var_38] add r15, [r14] neg r15 sar r15, 5 mov rax, 0AAAAAAAAAAAAAAABh imul r15, rax sub r15, rbp mov rdi, r14 mov rsi, r15 call _ZNSt6vectorISt4pairIKN8nlohmann16json_abi_v3_11_310basic_jsonINS2_11ordered_mapES_NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS2_14adl_serializerES_IhSaIhEEvEEN5minja5ValueEESaISI_EE6resizeEm; 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>>::resize(ulong) add rbx, [r14] loc_54DC9: mov rax, rbx add rsp, 8 pop rbx pop r12 pop r13 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>>>::erase( long long *a1, long long a2, long long a3) { long long v3; // rbx long long v4; // r12 unsigned long long v5; // rbp long long v6; // r15 long long v7; // r13 long long v9; // [rsp+0h] [rbp-38h] v3 = a2; if ( a2 != a3 ) { v4 = a3; v5 = 0xAAAAAAAAAAAAAAABLL * ((a3 - a2) >> 5); v9 = *a1; v6 = -a3; v7 = a2; while ( v4 != a1[1] ) { 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>::~pair(v7); 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>::pair( v7, v4); v7 += 96LL; v4 += 96LL; v6 -= 96LL; } 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>>::resize( a1, 0xAAAAAAAAAAAAAAABLL * (-(*a1 + v6) >> 5) - v5); return *a1 + a2 - v9; } return v3; }
erase: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX PUSH RAX MOV RBX,RSI CMP RSI,RDX JZ 0x00154dc9 MOV R12,RDX MOV R14,RDI MOV RBP,RDX SUB RBP,RBX SAR RBP,0x5 MOV RAX,-0x5555555555555555 IMUL RBP,RAX MOV RAX,qword ptr [RDI] MOV qword ptr [RSP],RAX MOV R15,RDX NEG R15 MOV R13,RBX LAB_00154d75: CMP R12,qword ptr [R14 + 0x8] JZ 0x00154d9c MOV RDI,R13 CALL 0x0014d61e MOV RDI,R13 MOV RSI,R12 CALL 0x00154ddc ADD R13,0x60 ADD R12,0x60 ADD R15,-0x60 JMP 0x00154d75 LAB_00154d9c: SUB RBX,qword ptr [RSP] ADD R15,qword ptr [R14] NEG R15 SAR R15,0x5 MOV RAX,-0x5555555555555555 IMUL R15,RAX SUB R15,RBP MOV RDI,R14 MOV RSI,R15 CALL 0x00154e68 ADD RBX,qword ptr [R14] LAB_00154dc9: MOV RAX,RBX ADD RSP,0x8 POP RBX POP R12 POP R13 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> > >::erase(__gnu_cxx::__normal_iterator<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::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> > > >, __gnu_cxx::__normal_iterator<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::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> > > >) */ pair * __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>>> ::erase(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,pair *param_2,pair *param_3) { long lVar1; long lVar2; pair *this_00; long lVar3; if (param_2 != param_3) { lVar2 = (long)param_3 - (long)param_2; lVar1 = *(long *)this; lVar3 = -(long)param_3; this_00 = param_2; for (; param_3 != *(pair **)(this + 8); param_3 = param_3 + 0x60) { 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> ::~pair((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_00); 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> ::pair((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_00,param_3); this_00 = (pair *)((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_00 + 0x60); lVar3 = lVar3 + -0x60; } 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>>> ::resize((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,(-(lVar3 + *(long *)this) >> 5) * -0x5555555555555555 + (lVar2 >> 5) * 0x5555555555555555); param_2 = param_2 + (*(long *)this - lVar1); } return param_2; }
47,440
get_lm_hash_data(elf_file*, block*, bool)
msxemulator/build_O3/_deps/picotool-src/bintool/bintool.cpp
std::vector<uint8_t> get_lm_hash_data(elf_file *elf, block *new_block, bool clear_sram = false) { std::vector<uint8_t> to_hash; std::shared_ptr<load_map_item> load_map = new_block->get_item<load_map_item>(); if (load_map == nullptr) { std::vector<load_map_item::entry> entries; if (clear_sram) { // todo tidy up this way of hashing the uint32_t std::vector<uint32_t> sram_size_vec = {SRAM_END_RP2350 - SRAM_START}; entries.push_back({ 0x0, SRAM_START, sram_size_vec[0] }); auto sram_size_data = words_to_lsb_bytes(sram_size_vec.begin(), sram_size_vec.end()); std::copy(sram_size_data.begin(), sram_size_data.end(), std::back_inserter(to_hash)); DEBUG_LOG("CLEAR %08x + %08x\n", (int)SRAM_START, (int)sram_size_vec[0]); } for(const auto &seg : sorted_segs(elf)) { if (!seg->is_load()) continue; const auto data = elf->content(*seg); // std::cout << "virt = " << std::hex << seg->virtual_address() << " + " << std::hex << seg->virtual_size() << ", phys = " << std::hex << seg->physical_address() << " + " << std::hex << seg->physical_size() << std::endl; if (data.size() != seg->physical_size()) { fail(ERROR_INCOMPATIBLE, "Elf segment physical size (%" PRIx32 ") does not match data size in file (%zx)", seg->physical_size(), data.size()); } if (seg->physical_size() && seg->physical_address() < new_block->physical_addr) { std::copy(data.begin(), data.end(), std::back_inserter(to_hash)); DEBUG_LOG("HASH %08x + %08x\n", (int)seg->physical_address(), (int)seg->physical_size()); entries.push_back( { (uint32_t)seg->physical_address(), (uint32_t)seg->virtual_address(), (uint32_t)seg->physical_size() }); } } load_map = std::make_shared<load_map_item>(false, entries); new_block->items.push_back(load_map); } else { DEBUG_LOG("Already has load map, so hashing that\n"); // todo hash existing load map for(const auto &entry : load_map->entries) { std::vector<uint8_t> data; uint32_t current_storage_address = entry.storage_address; if (current_storage_address == 0) { std::copy( (uint8_t*)&entry.size, (uint8_t*)&entry.size + sizeof(entry.size), std::back_inserter(to_hash)); DEBUG_LOG("CLEAR %08x + %08x\n", (int)entry.runtime_address, (int)entry.size); } else { while (data.size() < entry.size) { auto seg = elf->segment_from_physical_address(current_storage_address); if (seg == nullptr) { fail(ERROR_NOT_POSSIBLE, "The ELF file does not contain the storage address %x", current_storage_address); } const auto new_data = elf->content(*seg); uint32_t offset = current_storage_address - seg->physical_address(); std::copy(new_data.begin()+offset, new_data.end(), std::back_inserter(data)); current_storage_address += new_data.size(); } data.resize(entry.size); std::copy(data.begin(), data.end(), std::back_inserter(to_hash)); DEBUG_LOG("HASH %08x + %08x\n", (int)entry.storage_address, (int)data.size()); } } } return to_hash; }
O3
cpp
get_lm_hash_data(elf_file*, block*, bool): pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x88, %rsp movl %ecx, %ebx movq %rdx, %r15 movq %rsi, %r14 pxor %xmm0, %xmm0 movdqu %xmm0, (%rdi) movq %rdi, 0x58(%rsp) movq $0x0, 0x10(%rdi) leaq 0x70(%rsp), %rdi movq %rdx, %rsi callq 0x39b1e movq 0x70(%rsp), %rax testq %rax, %rax je 0x73eff movq 0x10(%rax), %r13 movq 0x18(%rax), %rax movq %rax, 0x80(%rsp) cmpq %rax, %r13 je 0x741a6 pxor %xmm0, %xmm0 movdqa %xmm0, 0x20(%rsp) movq $0x0, 0x30(%rsp) movl (%r13), %ebx leaq 0x8(%r13), %rbp testl %ebx, %ebx je 0x73e9e cmpl $0x0, (%rbp) je 0x73eb1 movq %r14, %rdi movl %ebx, %esi callq 0xa1f56 movq %rax, %r12 testq %rax, %rax jne 0x73e3a movl $0xfffffff8, %edi # imm = 0xFFFFFFF8 leaq 0x36fa6(%rip), %rsi # 0xaadd7 movl %ebx, %edx xorl %eax, %eax callq 0x7b492 movq %rsp, %rdi movq %r14, %rsi movq %r12, %rdx callq 0xa1e2a movl %ebx, %edi subl 0xc(%r12), %edi addq (%rsp), %rdi movq 0x8(%rsp), %rsi leaq 0x20(%rsp), %rdx callq 0x78a1c movl 0x8(%rsp), %r15d movq (%rsp), %r12 testq %r12, %r12 je 0x73e80 movq 0x10(%rsp), %rsi subq %r12, %rsi movq %r12, %rdi callq 0xf470 subl %r12d, %r15d addl %r15d, %ebx movq 0x28(%rsp), %rax subq 0x20(%rsp), %rax movl (%rbp), %esi cmpq %rsi, %rax jb 0x73e13 jmp 0x73eb3 leaq 0xc(%r13), %rsi movq %rbp, %rdi movq 0x58(%rsp), %rdx callq 0x6ef0c jmp 0x73ed1 xorl %esi, %esi leaq 0x20(%rsp), %rdi callq 0x76b5e movq 0x20(%rsp), %rdi movq 0x28(%rsp), %rsi movq 0x58(%rsp), %rdx callq 0x6ef0c movq 0x20(%rsp), %rdi testq %rdi, %rdi je 0x73ee8 movq 0x30(%rsp), %rsi subq %rdi, %rsi callq 0xf470 addq $0xc, %r13 cmpq 0x80(%rsp), %r13 jne 0x73de6 jmp 0x741a6 pxor %xmm0, %xmm0 movdqa %xmm0, 0x20(%rsp) movq $0x0, 0x30(%rsp) testb %bl, %bl je 0x73fd6 leaq 0x40(%rsp), %rsi movl $0x82000, (%rsi) # imm = 0x82000 movq %rsp, %rdi leaq 0x60(%rsp), %rcx movl $0x1, %edx callq 0x54ca2 movabsq $0x2000000000000000, %rax # imm = 0x2000000000000000 movq %rax, 0x40(%rsp) movq (%rsp), %rax movl (%rax), %eax movl %eax, 0x48(%rsp) movq 0x28(%rsp), %rsi cmpq 0x30(%rsp), %rsi je 0x73f73 movl 0x48(%rsp), %eax movl %eax, 0x8(%rsi) movq 0x40(%rsp), %rax movq %rax, (%rsi) addq $0xc, 0x28(%rsp) jmp 0x73f82 leaq 0x20(%rsp), %rdi leaq 0x40(%rsp), %rdx callq 0x788cc movq (%rsp), %rsi movq 0x8(%rsp), %rdx leaq 0x40(%rsp), %rdi callq 0x3acd7 movq 0x40(%rsp), %rdi movq 0x48(%rsp), %rsi movq 0x58(%rsp), %rdx callq 0x6ef0c movq 0x40(%rsp), %rdi testq %rdi, %rdi je 0x73fc0 movq 0x50(%rsp), %rsi subq %rdi, %rsi callq 0xf470 movq (%rsp), %rdi testq %rdi, %rdi je 0x73fd6 movq 0x10(%rsp), %rsi subq %rdi, %rsi callq 0xf470 movq %rsp, %rdi movq %r14, %rsi callq 0x72400 movq (%rsp), %r12 movq 0x8(%rsp), %rbx cmpq %rbx, %r12 je 0x740d8 leaq 0x40(%rsp), %r13 leaq 0x36d92(%rip), %rbp # 0xaad91 movq (%r12), %rdx cmpl $0x1, (%rdx) jne 0x740c7 movq %r13, %rdi movq %r14, %rsi callq 0xa1e2a movq 0x48(%rsp), %rcx subq 0x40(%rsp), %rcx movq (%r12), %rax movl 0x10(%rax), %edx cmpq %rdx, %rcx je 0x74043 movl $0xfffffffd, %edi # imm = 0xFFFFFFFD movq %rbp, %rsi xorl %eax, %eax callq 0x7b492 movq (%r12), %rax movl 0x10(%rax), %edx testl %edx, %edx je 0x740b0 movl 0xc(%rax), %eax cmpl (%r15), %eax jae 0x740b0 movq 0x40(%rsp), %rdi movq 0x48(%rsp), %rsi movq 0x58(%rsp), %rdx callq 0x78a1c movq (%r12), %rax movq 0x8(%rax), %xmm0 pshufd $0xe1, %xmm0, %xmm0 # xmm0 = xmm0[1,0,2,3] movq %xmm0, 0x60(%rsp) movl 0x10(%rax), %eax movl %eax, 0x68(%rsp) movq 0x28(%rsp), %rsi cmpq 0x30(%rsp), %rsi je 0x740a1 movl 0x68(%rsp), %eax movl %eax, 0x8(%rsi) movq 0x60(%rsp), %rax movq %rax, (%rsi) addq $0xc, 0x28(%rsp) jmp 0x740b0 leaq 0x20(%rsp), %rdi leaq 0x60(%rsp), %rdx callq 0x788cc movq 0x40(%rsp), %rdi testq %rdi, %rdi je 0x740c7 movq 0x50(%rsp), %rsi subq %rdi, %rsi callq 0xf470 addq $0x8, %r12 cmpq %rbx, %r12 jne 0x73fff movq (%rsp), %r12 testq %r12, %r12 je 0x740ed movq 0x10(%rsp), %rsi subq %r12, %rsi movq %r12, %rdi callq 0xf470 leaq 0x60(%rsp), %rcx movb $0x0, (%rcx) leaq 0x8(%rsp), %rdi movq $0x0, -0x8(%rdi) movq %rsp, %rsi leaq 0x40(%rsp), %rdx leaq 0x20(%rsp), %r8 callq 0x78a6a movdqa (%rsp), %xmm0 xorps %xmm1, %xmm1 movaps %xmm1, (%rsp) movq 0x78(%rsp), %rdi movdqa %xmm0, 0x70(%rsp) testq %rdi, %rdi je 0x74144 callq 0x4bd0a movq 0x8(%rsp), %rdi testq %rdi, %rdi je 0x74144 callq 0x4bd0a addq $0x10, %r15 movq 0x70(%rsp), %rcx movq 0x78(%rsp), %rax movq %rcx, (%rsp) movq %rax, 0x8(%rsp) testq %rax, %rax je 0x74175 movq 0x70e51(%rip), %rcx # 0xe4fb8 cmpb $0x0, (%rcx) je 0x74171 incl 0x8(%rax) jmp 0x74175 lock incl 0x8(%rax) movq %rsp, %rsi movq %r15, %rdi callq 0x645b0 movq 0x8(%rsp), %rdi testq %rdi, %rdi je 0x7418f callq 0x4bd0a movq 0x20(%rsp), %rdi testq %rdi, %rdi je 0x741a6 movq 0x30(%rsp), %rsi subq %rdi, %rsi callq 0xf470 movq 0x78(%rsp), %rdi testq %rdi, %rdi je 0x741b5 callq 0x4bd0a movq 0x58(%rsp), %rax addq $0x88, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq jmp 0x74213 jmp 0x741f3 jmp 0x74213 jmp 0x74230 movq %rax, %r14 movq 0x8(%rsp), %rdi testq %rdi, %rdi je 0x74233 callq 0x4bd0a jmp 0x74233 jmp 0x74230 jmp 0x74230 jmp 0x741f3 movq %rax, %r14 jmp 0x74259 movq %rax, %r14 movq 0x40(%rsp), %rdi testq %rdi, %rdi je 0x74216 movq 0x50(%rsp), %rsi subq %rdi, %rsi callq 0xf470 jmp 0x74216 jmp 0x74213 jmp 0x74230 movq %rax, %r14 movq (%rsp), %rdi testq %rdi, %rdi je 0x74233 movq 0x10(%rsp), %rsi subq %rdi, %rsi callq 0xf470 jmp 0x74233 jmp 0x74230 movq %rax, %r14 movq 0x20(%rsp), %rdi testq %rdi, %rdi je 0x7424a movq 0x30(%rsp), %rsi subq %rdi, %rsi callq 0xf470 movq 0x78(%rsp), %rdi testq %rdi, %rdi je 0x74259 callq 0x4bd0a movq 0x58(%rsp), %rax movq (%rax), %rdi testq %rdi, %rdi je 0x74272 movq 0x10(%rax), %rsi subq %rdi, %rsi callq 0xf470 movq %r14, %rdi callq 0xf7d0
_Z16get_lm_hash_dataP8elf_fileP5blockb: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 88h mov ebx, ecx mov r15, rdx mov r14, rsi pxor xmm0, xmm0 movdqu xmmword ptr [rdi], xmm0 mov [rsp+0B8h+var_60], rdi mov qword ptr [rdi+10h], 0 lea rdi, [rsp+0B8h+var_48] mov rsi, rdx call _ZN5block8get_itemI13load_map_itemEESt10shared_ptrIT_Ev; block::get_item<load_map_item>(void) mov rax, qword ptr [rsp+0B8h+var_48] test rax, rax jz loc_73EFF mov r13, [rax+10h] mov rax, [rax+18h] mov [rsp+0B8h+var_38], rax cmp r13, rax jz loc_741A6 loc_73DE6: pxor xmm0, xmm0 movdqa xmmword ptr [rsp+0B8h+var_98], xmm0 mov [rsp+0B8h+var_88], 0 mov ebx, [r13+0] lea rbp, [r13+8] test ebx, ebx jz loc_73E9E cmp dword ptr [rbp+0], 0 jz loc_73EB1 loc_73E13: mov rdi, r14; this mov esi, ebx; unsigned int call _ZN8elf_file29segment_from_physical_addressEj; elf_file::segment_from_physical_address(uint) mov r12, rax test rax, rax jnz short loc_73E3A mov edi, 0FFFFFFF8h; int lea rsi, aTheElfFileDoes_0; "The ELF file does not contain the stora"... mov edx, ebx xor eax, eax call _Z4failiPKcz; fail(int,char const*,...) loc_73E3A: mov rdi, rsp mov rsi, r14 mov rdx, r12 call _ZNK8elf_file7contentERK14elf32_ph_entry; elf_file::content(elf32_ph_entry const&) mov edi, ebx sub edi, [r12+0Ch] add rdi, [rsp+0B8h+var_B8] mov rsi, [rsp+0B8h+var_B8+8] lea rdx, [rsp+0B8h+var_98] call _ZNSt11__copy_moveILb0ELb0ESt26random_access_iterator_tagE8__copy_mIPKhSt20back_insert_iteratorISt6vectorIhSaIhEEEEET0_T_SB_SA_; std::__copy_move<false,false,std::random_access_iterator_tag>::__copy_m<uchar const*,std::back_insert_iterator<std::vector<uchar>>>(uchar const*,uchar const*,std::back_insert_iterator<std::vector<uchar>>) mov r15d, dword ptr [rsp+0B8h+var_B8+8] mov r12, [rsp+0B8h+var_B8] test r12, r12 jz short loc_73E80 mov rsi, [rsp+0B8h+var_A8] sub rsi, r12; unsigned __int64 mov rdi, r12; void * call __ZdlPvm; operator delete(void *,ulong) loc_73E80: sub r15d, r12d add ebx, r15d mov rax, [rsp+0B8h+var_98+8] sub rax, [rsp+0B8h+var_98] mov esi, [rbp+0] cmp rax, rsi jb loc_73E13 jmp short loc_73EB3 loc_73E9E: lea rsi, [r13+0Ch] mov rdi, rbp mov rdx, [rsp+0B8h+var_60] call _ZNSt11__copy_moveILb0ELb0ESt26random_access_iterator_tagE8__copy_mIPhSt20back_insert_iteratorISt6vectorIhSaIhEEEEET0_T_SA_S9_; std::__copy_move<false,false,std::random_access_iterator_tag>::__copy_m<uchar *,std::back_insert_iterator<std::vector<uchar>>>(uchar *,uchar *,std::back_insert_iterator<std::vector<uchar>>) jmp short loc_73ED1 loc_73EB1: xor esi, esi loc_73EB3: lea rdi, [rsp+0B8h+var_98] call _ZNSt6vectorIhSaIhEE6resizeEm; std::vector<uchar>::resize(ulong) mov rdi, [rsp+0B8h+var_98] mov rsi, [rsp+0B8h+var_98+8] mov rdx, [rsp+0B8h+var_60] call _ZNSt11__copy_moveILb0ELb0ESt26random_access_iterator_tagE8__copy_mIPhSt20back_insert_iteratorISt6vectorIhSaIhEEEEET0_T_SA_S9_; std::__copy_move<false,false,std::random_access_iterator_tag>::__copy_m<uchar *,std::back_insert_iterator<std::vector<uchar>>>(uchar *,uchar *,std::back_insert_iterator<std::vector<uchar>>) loc_73ED1: mov rdi, [rsp+0B8h+var_98]; void * test rdi, rdi jz short loc_73EE8 mov rsi, [rsp+0B8h+var_88] sub rsi, rdi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_73EE8: add r13, 0Ch cmp r13, [rsp+0B8h+var_38] jnz loc_73DE6 jmp loc_741A6 loc_73EFF: pxor xmm0, xmm0 movdqa xmmword ptr [rsp+0B8h+var_98], xmm0 mov [rsp+0B8h+var_88], 0 test bl, bl jz loc_73FD6 lea rsi, [rsp+0B8h+var_78] mov dword ptr [rsi], 82000h mov rdi, rsp lea rcx, [rsp+0B8h+var_58] mov edx, 1 call _ZNSt6vectorIjSaIjEEC2ESt16initializer_listIjERKS0_; std::vector<uint>::vector(std::initializer_list<uint>,std::allocator<uint> const&) mov rax, 2000000000000000h mov [rsp+0B8h+var_78], rax mov rax, [rsp+0B8h+var_B8] mov eax, [rax] mov dword ptr [rsp+0B8h+var_70], eax mov rsi, [rsp+0B8h+var_98+8] cmp rsi, [rsp+0B8h+var_88] jz short loc_73F73 mov eax, dword ptr [rsp+0B8h+var_70] mov [rsi+8], eax mov rax, [rsp+0B8h+var_78] mov [rsi], rax add [rsp+0B8h+var_98+8], 0Ch jmp short loc_73F82 loc_73F73: lea rdi, [rsp+0B8h+var_98] lea rdx, [rsp+0B8h+var_78] call _ZNSt6vectorIN13load_map_item5entryESaIS1_EE17_M_realloc_insertIJS1_EEEvN9__gnu_cxx17__normal_iteratorIPS1_S3_EEDpOT_; std::vector<load_map_item::entry>::_M_realloc_insert<load_map_item::entry>(__gnu_cxx::__normal_iterator<load_map_item::entry*,std::vector<load_map_item::entry>>,load_map_item::entry &&) loc_73F82: mov rsi, [rsp+0B8h+var_B8] mov rdx, [rsp+0B8h+var_B8+8] lea rdi, [rsp+0B8h+var_78] call _Z18words_to_lsb_bytesIN9__gnu_cxx17__normal_iteratorIPjSt6vectorIjSaIjEEEEhES3_IT0_SaIS7_EET_SA_; words_to_lsb_bytes<__gnu_cxx::__normal_iterator<uint *,std::vector<uint>>,uchar>(__gnu_cxx::__normal_iterator<uint *,std::vector<uint>>,__gnu_cxx::__normal_iterator<uint *,std::vector<uint>>) mov rdi, [rsp+0B8h+var_78] mov rsi, [rsp+0B8h+var_70] mov rdx, [rsp+0B8h+var_60] call _ZNSt11__copy_moveILb0ELb0ESt26random_access_iterator_tagE8__copy_mIPhSt20back_insert_iteratorISt6vectorIhSaIhEEEEET0_T_SA_S9_; std::__copy_move<false,false,std::random_access_iterator_tag>::__copy_m<uchar *,std::back_insert_iterator<std::vector<uchar>>>(uchar *,uchar *,std::back_insert_iterator<std::vector<uchar>>) mov rdi, [rsp+0B8h+var_78]; void * test rdi, rdi jz short loc_73FC0 mov rsi, [rsp+0B8h+var_68] sub rsi, rdi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_73FC0: mov rdi, [rsp+0B8h+var_B8]; void * test rdi, rdi jz short loc_73FD6 mov rsi, [rsp+0B8h+var_A8] sub rsi, rdi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_73FD6: mov rdi, rsp; elf_file * mov rsi, r14 call _Z11sorted_segsP8elf_file; sorted_segs(elf_file *) mov r12, [rsp+0B8h+var_B8] mov rbx, [rsp+0B8h+var_B8+8] cmp r12, rbx jz loc_740D8 lea r13, [rsp+0B8h+var_78] lea rbp, aElfSegmentPhys; "Elf segment physical size (%x) does not"... loc_73FFF: mov rdx, [r12] cmp dword ptr [rdx], 1 jnz loc_740C7 mov rdi, r13 mov rsi, r14 call _ZNK8elf_file7contentERK14elf32_ph_entry; elf_file::content(elf32_ph_entry const&) mov rcx, [rsp+0B8h+var_70] sub rcx, [rsp+0B8h+var_78] mov rax, [r12] mov edx, [rax+10h] cmp rcx, rdx jz short loc_74043 mov edi, 0FFFFFFFDh; int mov rsi, rbp; char * xor eax, eax call _Z4failiPKcz; fail(int,char const*,...) mov rax, [r12] mov edx, [rax+10h] loc_74043: test edx, edx jz short loc_740B0 mov eax, [rax+0Ch] cmp eax, [r15] jnb short loc_740B0 mov rdi, [rsp+0B8h+var_78] mov rsi, [rsp+0B8h+var_70] mov rdx, [rsp+0B8h+var_60] call _ZNSt11__copy_moveILb0ELb0ESt26random_access_iterator_tagE8__copy_mIPKhSt20back_insert_iteratorISt6vectorIhSaIhEEEEET0_T_SB_SA_; std::__copy_move<false,false,std::random_access_iterator_tag>::__copy_m<uchar const*,std::back_insert_iterator<std::vector<uchar>>>(uchar const*,uchar const*,std::back_insert_iterator<std::vector<uchar>>) mov rax, [r12] movq xmm0, qword ptr [rax+8] pshufd xmm0, xmm0, 0E1h movq [rsp+0B8h+var_58], xmm0 mov eax, [rax+10h] mov [rsp+0B8h+var_50], eax mov rsi, [rsp+0B8h+var_98+8] cmp rsi, [rsp+0B8h+var_88] jz short loc_740A1 mov eax, [rsp+0B8h+var_50] mov [rsi+8], eax mov rax, [rsp+0B8h+var_58] mov [rsi], rax add [rsp+0B8h+var_98+8], 0Ch jmp short loc_740B0 loc_740A1: lea rdi, [rsp+0B8h+var_98] lea rdx, [rsp+0B8h+var_58] call _ZNSt6vectorIN13load_map_item5entryESaIS1_EE17_M_realloc_insertIJS1_EEEvN9__gnu_cxx17__normal_iteratorIPS1_S3_EEDpOT_; std::vector<load_map_item::entry>::_M_realloc_insert<load_map_item::entry>(__gnu_cxx::__normal_iterator<load_map_item::entry*,std::vector<load_map_item::entry>>,load_map_item::entry &&) loc_740B0: mov rdi, [rsp+0B8h+var_78]; void * test rdi, rdi jz short loc_740C7 mov rsi, [rsp+0B8h+var_68] sub rsi, rdi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_740C7: add r12, 8 cmp r12, rbx jnz loc_73FFF mov r12, [rsp+0B8h+var_B8] loc_740D8: test r12, r12 jz short loc_740ED mov rsi, [rsp+0B8h+var_A8] sub rsi, r12; unsigned __int64 mov rdi, r12; void * call __ZdlPvm; operator delete(void *,ulong) loc_740ED: lea rcx, [rsp+0B8h+var_58] mov byte ptr [rcx], 0 lea rdi, [rsp+0B8h+var_B8+8] mov qword ptr [rdi-8], 0 mov rsi, rsp lea rdx, [rsp+0B8h+var_78] lea r8, [rsp+0B8h+var_98] call _ZNSt14__shared_countILN9__gnu_cxx12_Lock_policyE2EEC2I13load_map_itemSaIS4_EJbRSt6vectorINS4_5entryESaIS7_EEEEERPT_St20_Sp_alloc_shared_tagIT0_EDpOT1_; std::__shared_count<(__gnu_cxx::_Lock_policy)2>::__shared_count<load_map_item,std::allocator<load_map_item>,bool,std::vector<load_map_item::entry> &>(load_map_item *&,std::_Sp_alloc_shared_tag<std::allocator<load_map_item>>,bool,std::vector<load_map_item::entry> &) movdqa xmm0, xmmword ptr [rsp+0B8h+var_B8] xorps xmm1, xmm1 movaps xmmword ptr [rsp+0B8h+var_B8], xmm1 mov rdi, qword ptr [rsp+0B8h+var_48+8] movdqa [rsp+0B8h+var_48], xmm0 test rdi, rdi jz short loc_74144 call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void) mov rdi, [rsp+0B8h+var_B8+8] test rdi, rdi jz short loc_74144 call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void) loc_74144: add r15, 10h mov rcx, qword ptr [rsp+0B8h+var_48] mov rax, qword ptr [rsp+0B8h+var_48+8] mov [rsp+0B8h+var_B8], rcx mov [rsp+0B8h+var_B8+8], rax test rax, rax jz short loc_74175 mov rcx, cs:__libc_single_threaded_ptr cmp byte ptr [rcx], 0 jz short loc_74171 inc dword ptr [rax+8] jmp short loc_74175 loc_74171: lock inc dword ptr [rax+8] loc_74175: mov rsi, rsp mov rdi, r15 call _ZNSt6vectorISt10shared_ptrI4itemESaIS2_EE12emplace_backIJS2_EEEvDpOT_; std::vector<std::shared_ptr<item>>::emplace_back<std::shared_ptr<item>>(std::shared_ptr<item> &&) mov rdi, [rsp+0B8h+var_B8+8] test rdi, rdi jz short loc_7418F call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void) loc_7418F: mov rdi, [rsp+0B8h+var_98]; void * test rdi, rdi jz short loc_741A6 mov rsi, [rsp+0B8h+var_88] sub rsi, rdi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_741A6: mov rdi, qword ptr [rsp+0B8h+var_48+8] test rdi, rdi jz short loc_741B5 call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void) loc_741B5: mov rax, [rsp+0B8h+var_60] add rsp, 88h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn jmp short loc_74213 jmp short loc_741F3 jmp short loc_74213 jmp short loc_74230 mov r14, rax mov rdi, [rsp+arg_0] test rdi, rdi jz short loc_74233 call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void) jmp short loc_74233 jmp short loc_74230 jmp short loc_74230 jmp short loc_741F3 mov r14, rax jmp short loc_74259 loc_741F3: mov r14, rax mov rdi, [rsp+arg_38]; void * test rdi, rdi jz short loc_74216 mov rsi, [rsp+arg_48] sub rsi, rdi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) jmp short loc_74216 jmp short loc_74213 jmp short loc_74230 loc_74213: mov r14, rax loc_74216: mov rdi, [rsp+0]; void * test rdi, rdi jz short loc_74233 mov rsi, [rsp+arg_8] sub rsi, rdi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) jmp short loc_74233 jmp short $+2 loc_74230: mov r14, rax loc_74233: mov rdi, [rsp+arg_18]; void * test rdi, rdi jz short loc_7424A mov rsi, [rsp+arg_28] sub rsi, rdi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_7424A: mov rdi, [rsp+arg_70] test rdi, rdi jz short loc_74259 call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void) loc_74259: mov rax, [rsp+arg_50] mov rdi, [rax]; void * test rdi, rdi jz short loc_74272 mov rsi, [rax+10h] sub rsi, rdi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_74272: mov rdi, r14 call __Unwind_Resume
elf_file * get_lm_hash_data(elf_file *a1, block *a2, _DWORD *a3, char a4) { unsigned int *v7; // r13 unsigned int v8; // ebx _DWORD *v9; // rbp long long v10; // rax long long v11; // r12 int v12; // r15d int v13; // r12d unsigned long long v14; // rsi void **v15; // rsi _QWORD *v16; // r12 _QWORD *v17; // rbx long long v18; // rdx long long v19; // rax unsigned long long *v20; // rsi __m128i si128; // xmm0 volatile signed __int32 *v22; // rdi long long v23; // r15 void *v25[2]; // [rsp+0h] [rbp-B8h] BYREF long long v26; // [rsp+10h] [rbp-A8h] void *v27[2]; // [rsp+20h] [rbp-98h] BYREF void *v28; // [rsp+30h] [rbp-88h] void *v29; // [rsp+40h] [rbp-78h] BYREF long long v30; // [rsp+48h] [rbp-70h] long long v31; // [rsp+50h] [rbp-68h] elf_file *v32; // [rsp+58h] [rbp-60h] unsigned long long v33; // [rsp+60h] [rbp-58h] BYREF int v34; // [rsp+68h] [rbp-50h] __m128i v35; // [rsp+70h] [rbp-48h] BYREF unsigned int *i; // [rsp+80h] [rbp-38h] *(_OWORD *)a1 = 0LL; v32 = a1; *((_QWORD *)a1 + 2) = 0LL; block::get_item<load_map_item>(&v35, (long long)a3); if ( v35.m128i_i64[0] ) { v7 = *(unsigned int **)(v35.m128i_i64[0] + 16); for ( i = *(unsigned int **)(v35.m128i_i64[0] + 24); v7 != i; v7 += 3 ) { *(_OWORD *)v27 = 0LL; v28 = 0LL; v8 = *v7; v9 = v7 + 2; if ( *v7 ) { if ( *v9 ) { do { v10 = elf_file::segment_from_physical_address(a2, v8); v11 = v10; if ( !v10 ) fail(-8, "The ELF file does not contain the storage address %x", v8); elf_file::content(v25, a2, v10); std::__copy_move<false,false,std::random_access_iterator_tag>::__copy_m<unsigned char const*,std::back_insert_iterator<std::vector<unsigned char>>>( (char *)v25[0] + v8 - *(_DWORD *)(v11 + 12), v25[1], v27); v12 = (int)v25[1]; v13 = (int)v25[0]; if ( v25[0] ) operator delete(v25[0], v26 - (unsigned long long)v25[0]); v8 += v12 - v13; v14 = (unsigned int)*v9; } while ( (char *)v27[1] - (char *)v27[0] < v14 ); } else { v14 = 0LL; } std::vector<unsigned char>::resize(v27, v14); std::__copy_move<false,false,std::random_access_iterator_tag>::__copy_m<unsigned char *,std::back_insert_iterator<std::vector<unsigned char>>>( (_BYTE *)v27[0], (long long)v27[1], (long long)v32); } else { std::__copy_move<false,false,std::random_access_iterator_tag>::__copy_m<unsigned char *,std::back_insert_iterator<std::vector<unsigned char>>>( (_BYTE *)v7 + 8, (long long)(v7 + 3), (long long)v32); } if ( v27[0] ) operator delete(v27[0], (unsigned long long)v28 - (unsigned long long)v27[0]); } } else { *(_OWORD *)v27 = 0LL; v28 = 0LL; if ( a4 ) { LODWORD(v29) = 532480; std::vector<unsigned int>::vector((long long)v25, (long long)&v29, 1LL); v29 = (void *)0x2000000000000000LL; LODWORD(v30) = *(_DWORD *)v25[0]; v15 = (void **)v27[1]; if ( v27[1] == v28 ) { std::vector<load_map_item::entry>::_M_realloc_insert<load_map_item::entry>(v27, v27[1], &v29); } else { *((_DWORD *)v27[1] + 2) = v30; *v15 = v29; v27[1] = (char *)v27[1] + 12; } words_to_lsb_bytes<__gnu_cxx::__normal_iterator<unsigned int *,std::vector<unsigned int>>,unsigned char>( (long long)&v29, (unsigned int *)v25[0], (unsigned long long)v25[1]); std::__copy_move<false,false,std::random_access_iterator_tag>::__copy_m<unsigned char *,std::back_insert_iterator<std::vector<unsigned char>>>( v29, v30, (long long)v32); if ( v29 ) operator delete(v29, v31 - (_QWORD)v29); if ( v25[0] ) operator delete(v25[0], v26 - (unsigned long long)v25[0]); } sorted_segs((elf_file *)v25, (long long)a2); v16 = v25[0]; v17 = v25[1]; if ( v25[0] != v25[1] ) { do { if ( *(_DWORD *)*v16 == 1 ) { elf_file::content(&v29, a2, *v16); v18 = *(unsigned int *)(*v16 + 16LL); if ( v30 - (_QWORD)v29 != v18 ) fail(-3, "Elf segment physical size (%x) does not match data size in file (%zx)", v18, v30 - (_QWORD)v29); if ( (_DWORD)v18 && *(_DWORD *)(*v16 + 12LL) < *a3 ) { std::__copy_move<false,false,std::random_access_iterator_tag>::__copy_m<unsigned char const*,std::back_insert_iterator<std::vector<unsigned char>>>( v29, v30, v32); v19 = *v16; v33 = _mm_shuffle_epi32(_mm_loadl_epi64((const __m128i *)(*v16 + 8LL)), 225).m128i_u64[0]; v34 = *(_DWORD *)(v19 + 16); v20 = (unsigned long long *)v27[1]; if ( v27[1] == v28 ) { std::vector<load_map_item::entry>::_M_realloc_insert<load_map_item::entry>(v27, v27[1], &v33); } else { *((_DWORD *)v27[1] + 2) = v34; *v20 = v33; v27[1] = (char *)v27[1] + 12; } } if ( v29 ) operator delete(v29, v31 - (_QWORD)v29); } ++v16; } while ( v16 != v17 ); v16 = v25[0]; } if ( v16 ) operator delete(v16, v26 - (_QWORD)v16); LOBYTE(v33) = 0; v25[0] = 0LL; std::__shared_count<(__gnu_cxx::_Lock_policy)2>::__shared_count<load_map_item,std::allocator<load_map_item>,bool,std::vector<load_map_item::entry> &>( &v25[1], v25, &v29, &v33, v27); si128 = _mm_load_si128((const __m128i *)v25); *(_OWORD *)v25 = 0LL; v22 = (volatile signed __int32 *)v35.m128i_i64[1]; v35 = si128; if ( v22 ) { std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v22); if ( v25[1] ) std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release((volatile signed __int32 *)v25[1]); } v23 = (long long)(a3 + 4); *(__m128i *)v25 = v35; if ( v35.m128i_i64[1] ) { if ( _libc_single_threaded ) ++*(_DWORD *)(v35.m128i_i64[1] + 8); else _InterlockedIncrement((volatile signed __int32 *)(v35.m128i_i64[1] + 8)); } std::vector<std::shared_ptr<item>>::emplace_back<std::shared_ptr<item>>(v23, (__int128 *)v25); if ( v25[1] ) std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release((volatile signed __int32 *)v25[1]); if ( v27[0] ) operator delete(v27[0], (unsigned long long)v28 - (unsigned long long)v27[0]); } if ( v35.m128i_i64[1] ) std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release((volatile signed __int32 *)v35.m128i_i64[1]); return v32; }
get_lm_hash_data: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x88 MOV EBX,ECX MOV R15,RDX MOV R14,RSI PXOR XMM0,XMM0 MOVDQU xmmword ptr [RDI],XMM0 MOV qword ptr [RSP + 0x58],RDI MOV qword ptr [RDI + 0x10],0x0 LAB_00173db2: LEA RDI,[RSP + 0x70] MOV RSI,RDX CALL 0x00139b1e MOV RAX,qword ptr [RSP + 0x70] TEST RAX,RAX JZ 0x00173eff MOV R13,qword ptr [RAX + 0x10] MOV RAX,qword ptr [RAX + 0x18] MOV qword ptr [RSP + 0x80],RAX CMP R13,RAX JZ 0x001741a6 LAB_00173de6: PXOR XMM0,XMM0 MOVDQA xmmword ptr [RSP + 0x20],XMM0 MOV qword ptr [RSP + 0x30],0x0 MOV EBX,dword ptr [R13] LEA RBP,[R13 + 0x8] TEST EBX,EBX JZ 0x00173e9e CMP dword ptr [RBP],0x0 JZ 0x00173eb1 LAB_00173e13: MOV RDI,R14 MOV ESI,EBX CALL 0x001a1f56 MOV R12,RAX TEST RAX,RAX JNZ 0x00173e3a MOV EDI,0xfffffff8 LEA RSI,[0x1aadd7] MOV EDX,EBX XOR EAX,EAX CALL 0x0017b492 LAB_00173e3a: MOV RDI,RSP MOV RSI,R14 MOV RDX,R12 CALL 0x001a1e2a MOV EDI,EBX SUB EDI,dword ptr [R12 + 0xc] ADD RDI,qword ptr [RSP] MOV RSI,qword ptr [RSP + 0x8] LAB_00173e58: LEA RDX,[RSP + 0x20] CALL 0x00178a1c MOV R15D,dword ptr [RSP + 0x8] MOV R12,qword ptr [RSP] TEST R12,R12 JZ 0x00173e80 MOV RSI,qword ptr [RSP + 0x10] SUB RSI,R12 MOV RDI,R12 CALL 0x0010f470 LAB_00173e80: SUB R15D,R12D ADD EBX,R15D MOV RAX,qword ptr [RSP + 0x28] SUB RAX,qword ptr [RSP + 0x20] MOV ESI,dword ptr [RBP] CMP RAX,RSI JC 0x00173e13 JMP 0x00173eb3 LAB_00173e9e: LEA RSI,[R13 + 0xc] LAB_00173ea2: MOV RDI,RBP MOV RDX,qword ptr [RSP + 0x58] CALL 0x0016ef0c JMP 0x00173ed1 LAB_00173eb1: XOR ESI,ESI LAB_00173eb3: LEA RDI,[RSP + 0x20] CALL 0x00176b5e MOV RDI,qword ptr [RSP + 0x20] MOV RSI,qword ptr [RSP + 0x28] MOV RDX,qword ptr [RSP + 0x58] CALL 0x0016ef0c LAB_00173ed1: MOV RDI,qword ptr [RSP + 0x20] TEST RDI,RDI JZ 0x00173ee8 MOV RSI,qword ptr [RSP + 0x30] SUB RSI,RDI CALL 0x0010f470 LAB_00173ee8: ADD R13,0xc CMP R13,qword ptr [RSP + 0x80] JNZ 0x00173de6 JMP 0x001741a6 LAB_00173eff: PXOR XMM0,XMM0 MOVDQA xmmword ptr [RSP + 0x20],XMM0 MOV qword ptr [RSP + 0x30],0x0 TEST BL,BL JZ 0x00173fd6 LEA RSI,[RSP + 0x40] MOV dword ptr [RSI],0x82000 LAB_00173f25: MOV RDI,RSP LEA RCX,[RSP + 0x60] MOV EDX,0x1 CALL 0x00154ca2 MOV RAX,0x2000000000000000 MOV qword ptr [RSP + 0x40],RAX MOV RAX,qword ptr [RSP] MOV EAX,dword ptr [RAX] MOV dword ptr [RSP + 0x48],EAX MOV RSI,qword ptr [RSP + 0x28] CMP RSI,qword ptr [RSP + 0x30] JZ 0x00173f73 MOV EAX,dword ptr [RSP + 0x48] MOV dword ptr [RSI + 0x8],EAX MOV RAX,qword ptr [RSP + 0x40] MOV qword ptr [RSI],RAX ADD qword ptr [RSP + 0x28],0xc JMP 0x00173f82 LAB_00173f73: LEA RDI,[RSP + 0x20] LEA RDX,[RSP + 0x40] CALL 0x001788cc LAB_00173f82: MOV RSI,qword ptr [RSP] MOV RDX,qword ptr [RSP + 0x8] LAB_00173f8b: LEA RDI,[RSP + 0x40] CALL 0x0013acd7 MOV RDI,qword ptr [RSP + 0x40] MOV RSI,qword ptr [RSP + 0x48] LAB_00173f9f: MOV RDX,qword ptr [RSP + 0x58] CALL 0x0016ef0c MOV RDI,qword ptr [RSP + 0x40] TEST RDI,RDI JZ 0x00173fc0 MOV RSI,qword ptr [RSP + 0x50] SUB RSI,RDI CALL 0x0010f470 LAB_00173fc0: MOV RDI,qword ptr [RSP] TEST RDI,RDI JZ 0x00173fd6 MOV RSI,qword ptr [RSP + 0x10] SUB RSI,RDI CALL 0x0010f470 LAB_00173fd6: MOV RDI,RSP MOV RSI,R14 CALL 0x00172400 MOV R12,qword ptr [RSP] MOV RBX,qword ptr [RSP + 0x8] CMP R12,RBX JZ 0x001740d8 LEA R13,[RSP + 0x40] LEA RBP,[0x1aad91] LAB_00173fff: MOV RDX,qword ptr [R12] CMP dword ptr [RDX],0x1 JNZ 0x001740c7 LAB_0017400c: MOV RDI,R13 MOV RSI,R14 CALL 0x001a1e2a MOV RCX,qword ptr [RSP + 0x48] SUB RCX,qword ptr [RSP + 0x40] MOV RAX,qword ptr [R12] MOV EDX,dword ptr [RAX + 0x10] CMP RCX,RDX JZ 0x00174043 LAB_0017402d: MOV EDI,0xfffffffd MOV RSI,RBP XOR EAX,EAX CALL 0x0017b492 MOV RAX,qword ptr [R12] MOV EDX,dword ptr [RAX + 0x10] LAB_00174043: TEST EDX,EDX JZ 0x001740b0 MOV EAX,dword ptr [RAX + 0xc] CMP EAX,dword ptr [R15] JNC 0x001740b0 MOV RDI,qword ptr [RSP + 0x40] MOV RSI,qword ptr [RSP + 0x48] MOV RDX,qword ptr [RSP + 0x58] CALL 0x00178a1c MOV RAX,qword ptr [R12] MOVQ XMM0,qword ptr [RAX + 0x8] PSHUFD XMM0,XMM0,0xe1 MOVQ qword ptr [RSP + 0x60],XMM0 MOV EAX,dword ptr [RAX + 0x10] MOV dword ptr [RSP + 0x68],EAX MOV RSI,qword ptr [RSP + 0x28] CMP RSI,qword ptr [RSP + 0x30] JZ 0x001740a1 MOV EAX,dword ptr [RSP + 0x68] MOV dword ptr [RSI + 0x8],EAX MOV RAX,qword ptr [RSP + 0x60] MOV qword ptr [RSI],RAX ADD qword ptr [RSP + 0x28],0xc JMP 0x001740b0 LAB_001740a1: LEA RDI,[RSP + 0x20] LEA RDX,[RSP + 0x60] CALL 0x001788cc LAB_001740b0: MOV RDI,qword ptr [RSP + 0x40] TEST RDI,RDI JZ 0x001740c7 MOV RSI,qword ptr [RSP + 0x50] SUB RSI,RDI CALL 0x0010f470 LAB_001740c7: ADD R12,0x8 CMP R12,RBX JNZ 0x00173fff MOV R12,qword ptr [RSP] LAB_001740d8: TEST R12,R12 JZ 0x001740ed MOV RSI,qword ptr [RSP + 0x10] SUB RSI,R12 MOV RDI,R12 CALL 0x0010f470 LAB_001740ed: LEA RCX,[RSP + 0x60] MOV byte ptr [RCX],0x0 LEA RDI,[RSP + 0x8] MOV qword ptr [RDI + -0x8],0x0 LAB_00174102: MOV RSI,RSP LEA RDX,[RSP + 0x40] LEA R8,[RSP + 0x20] CALL 0x00178a6a MOVDQA XMM0,xmmword ptr [RSP] XORPS XMM1,XMM1 MOVAPS xmmword ptr [RSP],XMM1 MOV RDI,qword ptr [RSP + 0x78] MOVDQA xmmword ptr [RSP + 0x70],XMM0 TEST RDI,RDI JZ 0x00174144 CALL 0x0014bd0a MOV RDI,qword ptr [RSP + 0x8] TEST RDI,RDI JZ 0x00174144 CALL 0x0014bd0a LAB_00174144: ADD R15,0x10 MOV RCX,qword ptr [RSP + 0x70] MOV RAX,qword ptr [RSP + 0x78] MOV qword ptr [RSP],RCX MOV qword ptr [RSP + 0x8],RAX TEST RAX,RAX JZ 0x00174175 MOV RCX,qword ptr [0x001e4fb8] CMP byte ptr [RCX],0x0 JZ 0x00174171 INC dword ptr [RAX + 0x8] JMP 0x00174175 LAB_00174171: INC.LOCK dword ptr [RAX + 0x8] LAB_00174175: MOV RSI,RSP MOV RDI,R15 CALL 0x001645b0 LAB_00174180: MOV RDI,qword ptr [RSP + 0x8] TEST RDI,RDI JZ 0x0017418f CALL 0x0014bd0a LAB_0017418f: MOV RDI,qword ptr [RSP + 0x20] TEST RDI,RDI JZ 0x001741a6 MOV RSI,qword ptr [RSP + 0x30] SUB RSI,RDI CALL 0x0010f470 LAB_001741a6: MOV RDI,qword ptr [RSP + 0x78] TEST RDI,RDI JZ 0x001741b5 CALL 0x0014bd0a LAB_001741b5: MOV RAX,qword ptr [RSP + 0x58] ADD RSP,0x88 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
/* get_lm_hash_data(elf_file*, block*, bool) */ elf_file * get_lm_hash_data(elf_file *param_1,block *param_2,bool param_3) { uint *puVar1; int8 uVar2; _Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *p_Var3; int iVar4; long lVar5; char in_CL; int7 in_register_00000011; uint uVar6; ulong uVar7; _Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *p_Var8; uint *puVar9; _Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *local_b8; _Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *p_Stack_b0; long local_a8; int1 local_98 [16]; ulong *local_88; void *local_78; int4 local_70; int4 uStack_6c; long local_68; elf_file *local_60; ulong local_58; int4 local_50; _Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *local_48; _Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *p_Stack_40; uint *local_38; *(int1 (*) [16])param_1 = (int1 [16])0x0; *(int8 *)(param_1 + 0x10) = 0; local_60 = param_1; /* try { // try from 00173db2 to 00173dbe has its CatchHandler @ 001741ee */ block::get_item<load_map_item>(); if (local_48 == (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) { local_98 = (int1 [16])0x0; local_88 = (ulong *)0x0; if (in_CL != '\0') { local_78 = (void *)CONCAT44(local_78._4_4_,0x82000); /* try { // try from 00173f25 to 00173f36 has its CatchHandler @ 001741d2 */ std::vector<unsigned_int,std::allocator<unsigned_int>>::vector ((vector<unsigned_int,std::allocator<unsigned_int>> *)&local_b8,&local_78,1, &local_58); local_78 = (void *)0x2000000000000000; local_70 = *(int4 *)local_b8; if ((ulong *)local_98._8_8_ == local_88) { /* try { // try from 00173f73 to 00173f81 has its CatchHandler @ 001741cc */ std::vector<load_map_item::entry,std::allocator<load_map_item::entry>>:: _M_realloc_insert<load_map_item::entry> ((vector<load_map_item::entry,std::allocator<load_map_item::entry>> *)local_98, local_98._8_8_,&local_78); } else { *(int4 *)(local_98._8_8_ + 8) = local_70; *(ulong *)local_98._8_8_ = 0x2000000000000000; local_98._8_8_ = local_98._8_8_ + 0xc; } /* try { // try from 00173f8b to 00173f94 has its CatchHandler @ 001741d0 */ words_to_lsb_bytes<__gnu_cxx::__normal_iterator<unsigned_int*,std::vector<unsigned_int,std::allocator<unsigned_int>>>,unsigned_char> (&local_78,local_b8,p_Stack_b0); /* try { // try from 00173f9f to 00173fa8 has its CatchHandler @ 001741ce */ std::__copy_move<false,false,std::random_access_iterator_tag>:: __copy_m<unsigned_char*,std::back_insert_iterator<std::vector<unsigned_char,std::allocator<unsigned_char>>>> (local_78,CONCAT44(uStack_6c,local_70),local_60); if (local_78 != (void *)0x0) { operator_delete(local_78,local_68 - (long)local_78); } if (local_b8 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) { operator_delete(local_b8,local_a8 - (long)local_b8); } } /* try { // try from 00173fd6 to 00173fe0 has its CatchHandler @ 001741ea */ sorted_segs((elf_file *)&local_b8); p_Var3 = p_Stack_b0; if (local_b8 != p_Stack_b0) { p_Var8 = local_b8; do { if (**(int **)p_Var8 == 1) { /* try { // try from 0017400c to 00174016 has its CatchHandler @ 0017420f */ elf_file::content((elf32_ph_entry *)&local_78); lVar5 = *(long *)p_Var8; uVar6 = *(uint *)(lVar5 + 0x10); if (CONCAT44(uStack_6c,local_70) - (long)local_78 != (ulong)uVar6) { /* try { // try from 0017402d to 00174062 has its CatchHandler @ 001741f3 */ fail(-3,"Elf segment physical size (%x) does not match data size in file (%zx)"); lVar5 = *(long *)p_Var8; uVar6 = *(uint *)(lVar5 + 0x10); } if ((uVar6 != 0) && (*(uint *)(lVar5 + 0xc) < *(uint *)CONCAT71(in_register_00000011,param_3))) { std::__copy_move<false,false,std::random_access_iterator_tag>:: __copy_m<unsigned_char_const*,std::back_insert_iterator<std::vector<unsigned_char,std::allocator<unsigned_char>>>> (local_78,CONCAT44(uStack_6c,local_70),local_60); uVar2 = *(int8 *)(*(long *)p_Var8 + 8); local_58 = CONCAT44((int)uVar2,(int)((ulong)uVar2 >> 0x20)); local_50 = *(int4 *)(*(long *)p_Var8 + 0x10); if ((ulong *)local_98._8_8_ == local_88) { /* try { // try from 001740a1 to 001740af has its CatchHandler @ 001741ec */ std::vector<load_map_item::entry,std::allocator<load_map_item::entry>>:: _M_realloc_insert<load_map_item::entry> ((vector<load_map_item::entry,std::allocator<load_map_item::entry>> *) local_98,local_98._8_8_,&local_58); } else { *(int4 *)(local_98._8_8_ + 8) = local_50; *(ulong *)local_98._8_8_ = local_58; local_98._8_8_ = local_98._8_8_ + 0xc; } } if (local_78 != (void *)0x0) { operator_delete(local_78,local_68 - (long)local_78); } } p_Var8 = p_Var8 + 8; } while (p_Var8 != p_Var3); } if (local_b8 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) { operator_delete(local_b8,local_a8 - (long)local_b8); } local_58 = local_58 & 0xffffffffffffff00; local_b8 = (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0; /* try { // try from 00174102 to 00174113 has its CatchHandler @ 001741e8 */ std::__shared_count<(__gnu_cxx::_Lock_policy)2>:: __shared_count<load_map_item,std::allocator<load_map_item>,bool,std::vector<load_map_item::entry,std::allocator<load_map_item::entry>>&> ((__shared_count<(__gnu_cxx::_Lock_policy)2> *)&p_Stack_b0,&local_b8,&local_78, &local_58,local_98); p_Var3 = p_Stack_40; p_Stack_40 = p_Stack_b0; local_48 = local_b8; local_b8 = (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0; p_Stack_b0 = (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0; if ((p_Var3 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) && (std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(p_Var3), p_Stack_b0 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0)) { std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(p_Stack_b0); } local_b8 = local_48; p_Stack_b0 = p_Stack_40; if (p_Stack_40 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) { if (*PTR___libc_single_threaded_001e4fb8 == '\0') { LOCK(); *(int *)(p_Stack_40 + 8) = *(int *)(p_Stack_40 + 8) + 1; UNLOCK(); } else { *(int *)(p_Stack_40 + 8) = *(int *)(p_Stack_40 + 8) + 1; } } /* try { // try from 00174175 to 0017417f has its CatchHandler @ 001741d4 */ std::vector<std::shared_ptr<item>,std::allocator<std::shared_ptr<item>>>:: emplace_back<std::shared_ptr<item>> ((vector<std::shared_ptr<item>,std::allocator<std::shared_ptr<item>>> *) ((uint *)CONCAT71(in_register_00000011,param_3) + 4),(shared_ptr *)&local_b8); if (p_Stack_b0 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) { std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(p_Stack_b0); } if ((void *)local_98._0_8_ != (void *)0x0) { operator_delete((void *)local_98._0_8_,(long)local_88 - local_98._0_8_); } } else { puVar9 = *(uint **)(local_48 + 0x10); local_38 = *(uint **)(local_48 + 0x18); if (puVar9 != local_38) { do { local_98 = (int1 [16])0x0; local_88 = (ulong *)0x0; uVar6 = *puVar9; puVar1 = puVar9 + 2; if (uVar6 == 0) { /* try { // try from 00173ea2 to 00173ed0 has its CatchHandler @ 00174211 */ std::__copy_move<false,false,std::random_access_iterator_tag>:: __copy_m<unsigned_char*,std::back_insert_iterator<std::vector<unsigned_char,std::allocator<unsigned_char>>>> (puVar1,puVar9 + 3,local_60); } else { if (*puVar1 == 0) { uVar7 = 0; } else { do { /* try { // try from 00173e13 to 00173e39 has its CatchHandler @ 00174230 */ lVar5 = elf_file::segment_from_physical_address((elf_file *)param_2,uVar6); if (lVar5 == 0) { fail(-8,"The ELF file does not contain the storage address %x",(ulong)uVar6); } /* try { // try from 00173e3a to 00173e47 has its CatchHandler @ 0017422e */ elf_file::content((elf32_ph_entry *)&local_b8); /* try { // try from 00173e58 to 00173e61 has its CatchHandler @ 00174213 */ std::__copy_move<false,false,std::random_access_iterator_tag>:: __copy_m<unsigned_char_const*,std::back_insert_iterator<std::vector<unsigned_char,std::allocator<unsigned_char>>>> (local_b8 + (uVar6 - *(int *)(lVar5 + 0xc)),p_Stack_b0,local_98); p_Var3 = local_b8; iVar4 = (int)p_Stack_b0; if (local_b8 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) { operator_delete(local_b8,local_a8 - (long)local_b8); } uVar6 = uVar6 + (iVar4 - (int)p_Var3); uVar7 = (ulong)*puVar1; } while ((ulong)(local_98._8_8_ - local_98._0_8_) < uVar7); } std::vector<unsigned_char,std::allocator<unsigned_char>>::resize ((vector<unsigned_char,std::allocator<unsigned_char>> *)local_98,uVar7); std::__copy_move<false,false,std::random_access_iterator_tag>:: __copy_m<unsigned_char*,std::back_insert_iterator<std::vector<unsigned_char,std::allocator<unsigned_char>>>> (local_98._0_8_,local_98._8_8_,local_60); } if ((void *)local_98._0_8_ != (void *)0x0) { operator_delete((void *)local_98._0_8_,(long)local_88 - local_98._0_8_); } puVar9 = puVar9 + 3; } while (puVar9 != local_38); } } if (p_Stack_40 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) { std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(p_Stack_40); } return local_60; }
47,441
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>>>>>::skip_bom()
llama.cpp/common/json.hpp
bool skip_bom() { if (get() == 0xEF) { // check if we completely parse the BOM return get() == 0xBB && get() == 0xBF; } // the first character is not the beginning of the BOM; unget it to // process is later unget(); return true; }
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>>>>>::skip_bom(): pushq %rbx movq %rdi, %rbx callq 0x2164e cmpl $0xef, %eax je 0x84b3e movq %rbx, %rdi callq 0x85434 movb $0x1, %al popq %rbx retq movq %rbx, %rdi callq 0x2164e cmpl $0xbb, %eax je 0x84b51 xorl %eax, %eax jmp 0x84b3c movq %rbx, %rdi callq 0x2164e cmpl $0xbf, %eax sete %al jmp 0x84b3c nop
_ZN8nlohmann16json_abi_v3_11_36detail5lexerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEENS1_22iterator_input_adapterIN9__gnu_cxx17__normal_iteratorIPKcSB_EEEEE8skip_bomEv: push rbx mov rbx, rdi call _ZN8nlohmann16json_abi_v3_11_36detail5lexerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEENS1_22iterator_input_adapterIN9__gnu_cxx17__normal_iteratorIPKcSB_EEEEE3getEv; 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,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::get(void) cmp eax, 0EFh jz short loc_84B3E mov rdi, rbx call _ZN8nlohmann16json_abi_v3_11_36detail5lexerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEENS1_22iterator_input_adapterIN9__gnu_cxx17__normal_iteratorIPKcSB_EEEEE5ungetEv; 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,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::unget(void) mov al, 1 loc_84B3C: pop rbx retn loc_84B3E: mov rdi, rbx call _ZN8nlohmann16json_abi_v3_11_36detail5lexerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEENS1_22iterator_input_adapterIN9__gnu_cxx17__normal_iteratorIPKcSB_EEEEE3getEv; 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,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::get(void) cmp eax, 0BBh jz short loc_84B51 xor eax, eax jmp short loc_84B3C loc_84B51: mov rdi, rbx call _ZN8nlohmann16json_abi_v3_11_36detail5lexerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEENS1_22iterator_input_adapterIN9__gnu_cxx17__normal_iteratorIPKcSB_EEEEE3getEv; 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,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::get(void) cmp eax, 0BFh setz al jmp short loc_84B3C
bool 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>>>::skip_bom( __m128i *a1) { if ( (unsigned int)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>>>::get(a1) == 239 ) return (unsigned int)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>>>::get(a1) == 187 && (unsigned int)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>>>::get(a1) == 191; 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>>>::unget(a1); return 1; }
skip_bom: PUSH RBX MOV RBX,RDI CALL 0x0012164e CMP EAX,0xef JZ 0x00184b3e MOV RDI,RBX CALL 0x00185434 MOV AL,0x1 LAB_00184b3c: POP RBX RET LAB_00184b3e: MOV RDI,RBX CALL 0x0012164e CMP EAX,0xbb JZ 0x00184b51 XOR EAX,EAX JMP 0x00184b3c LAB_00184b51: MOV RDI,RBX CALL 0x0012164e CMP EAX,0xbf SETZ AL JMP 0x00184b3c
/* 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 > > >::skip_bom() */ bool __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>>> ::skip_bom(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) { int iVar1; bool bVar2; iVar1 = get(this); if (iVar1 == 0xef) { iVar1 = get(this); if (iVar1 == 0xbb) { iVar1 = get(this); bVar2 = iVar1 == 0xbf; } else { bVar2 = false; } } else { unget(this); bVar2 = true; } return bVar2; }
47,442
LefDefParser::lefiVia::setViaRule(char const*, double, double, char const*, char const*, char const*, double, double, double, double, double, double)
Efficient-TDP/thirdparty/Limbo/limbo/thirdparty/lefdef/5.8/lef/lef/lefiVia.cpp
void lefiVia::setViaRule(const char *viaRuleName, double xSize, double ySize, const char *botLayer, const char *cutLayer, const char *topLayer, double xCut, double yCut, double xBotEnc, double yBotEnc, double xTopEnc, double yTopEnc) { viaRuleName_ = strdup(viaRuleName); xSize_ = xSize; ySize_ = ySize; botLayer_ = strdup(botLayer); cutLayer_ = strdup(cutLayer); topLayer_ = strdup(topLayer); xSpacing_ = xCut; ySpacing_ = yCut; xBotEnc_ = xBotEnc; yBotEnc_ = yBotEnc; xTopEnc_ = xTopEnc; yTopEnc_ = yTopEnc; }
O0
cpp
LefDefParser::lefiVia::setViaRule(char const*, double, double, char const*, char const*, char const*, double, double, double, double, double, double): subq $0x78, %rsp movq %rdi, 0x70(%rsp) movq %rsi, 0x68(%rsp) movsd %xmm0, 0x60(%rsp) movsd %xmm1, 0x58(%rsp) movq %rdx, 0x50(%rsp) movq %rcx, 0x48(%rsp) movq %r8, 0x40(%rsp) movsd %xmm2, 0x38(%rsp) movsd %xmm3, 0x30(%rsp) movsd %xmm4, 0x28(%rsp) movsd %xmm5, 0x20(%rsp) movsd %xmm6, 0x18(%rsp) movsd %xmm7, 0x10(%rsp) movq 0x70(%rsp), %rax movq %rax, 0x8(%rsp) movq 0x68(%rsp), %rdi callq 0x2450 movq %rax, %rcx movq 0x8(%rsp), %rax movq %rcx, 0x80(%rax) movsd 0x60(%rsp), %xmm0 movsd %xmm0, 0x88(%rax) movsd 0x58(%rsp), %xmm0 movsd %xmm0, 0x90(%rax) movq 0x50(%rsp), %rdi callq 0x2450 movq %rax, %rcx movq 0x8(%rsp), %rax movq %rcx, 0x98(%rax) movq 0x48(%rsp), %rdi callq 0x2450 movq %rax, %rcx movq 0x8(%rsp), %rax movq %rcx, 0xa0(%rax) movq 0x40(%rsp), %rdi callq 0x2450 movq %rax, %rcx movq 0x8(%rsp), %rax movq %rcx, 0xa8(%rax) movsd 0x38(%rsp), %xmm0 movsd %xmm0, 0xb0(%rax) movsd 0x30(%rsp), %xmm0 movsd %xmm0, 0xb8(%rax) movsd 0x28(%rsp), %xmm0 movsd %xmm0, 0xc0(%rax) movsd 0x20(%rsp), %xmm0 movsd %xmm0, 0xc8(%rax) movsd 0x18(%rsp), %xmm0 movsd %xmm0, 0xd0(%rax) movsd 0x10(%rsp), %xmm0 movsd %xmm0, 0xd8(%rax) addq $0x78, %rsp retq
_ZN12LefDefParser7lefiVia10setViaRuleEPKcddS2_S2_S2_dddddd: sub rsp, 78h mov [rsp+78h+var_8], rdi mov [rsp+78h+var_10], rsi movsd [rsp+78h+var_18], xmm0 movsd [rsp+78h+var_20], xmm1 mov [rsp+78h+var_28], rdx mov [rsp+78h+var_30], rcx mov [rsp+78h+var_38], r8 movsd [rsp+78h+var_40], xmm2 movsd [rsp+78h+var_48], xmm3 movsd [rsp+78h+var_50], xmm4 movsd [rsp+78h+var_58], xmm5 movsd [rsp+78h+var_60], xmm6 movsd [rsp+78h+var_68], xmm7 mov rax, [rsp+78h+var_8] mov [rsp+78h+var_70], rax mov rdi, [rsp+78h+var_10] call _strdup mov rcx, rax mov rax, [rsp+78h+var_70] mov [rax+80h], rcx movsd xmm0, [rsp+78h+var_18] movsd qword ptr [rax+88h], xmm0 movsd xmm0, [rsp+78h+var_20] movsd qword ptr [rax+90h], xmm0 mov rdi, [rsp+78h+var_28] call _strdup mov rcx, rax mov rax, [rsp+78h+var_70] mov [rax+98h], rcx mov rdi, [rsp+78h+var_30] call _strdup mov rcx, rax mov rax, [rsp+78h+var_70] mov [rax+0A0h], rcx mov rdi, [rsp+78h+var_38] call _strdup mov rcx, rax mov rax, [rsp+78h+var_70] mov [rax+0A8h], rcx movsd xmm0, [rsp+78h+var_40] movsd qword ptr [rax+0B0h], xmm0 movsd xmm0, [rsp+78h+var_48] movsd qword ptr [rax+0B8h], xmm0 movsd xmm0, [rsp+78h+var_50] movsd qword ptr [rax+0C0h], xmm0 movsd xmm0, [rsp+78h+var_58] movsd qword ptr [rax+0C8h], xmm0 movsd xmm0, [rsp+78h+var_60] movsd qword ptr [rax+0D0h], xmm0 movsd xmm0, [rsp+78h+var_68] movsd qword ptr [rax+0D8h], xmm0 add rsp, 78h retn
LefDefParser::lefiVia * LefDefParser::lefiVia::setViaRule( LefDefParser::lefiVia *this, const char *a2, double a3, double a4, const char *a5, const char *a6, const char *a7, double a8, double a9, double a10, double a11, double a12, double a13) { long long v13; // rcx LefDefParser::lefiVia *result; // rax *((_QWORD *)this + 16) = strdup(a2); *((double *)this + 17) = a3; *((double *)this + 18) = a4; *((_QWORD *)this + 19) = strdup(a5); *((_QWORD *)this + 20) = strdup(a6); v13 = strdup(a7); result = this; *((_QWORD *)this + 21) = v13; *((double *)this + 22) = a8; *((double *)this + 23) = a9; *((double *)this + 24) = a10; *((double *)this + 25) = a11; *((double *)this + 26) = a12; *((double *)this + 27) = a13; return result; }
setViaRule: SUB RSP,0x78 MOV qword ptr [RSP + 0x70],RDI MOV qword ptr [RSP + 0x68],RSI MOVSD qword ptr [RSP + 0x60],XMM0 MOVSD qword ptr [RSP + 0x58],XMM1 MOV qword ptr [RSP + 0x50],RDX MOV qword ptr [RSP + 0x48],RCX MOV qword ptr [RSP + 0x40],R8 MOVSD qword ptr [RSP + 0x38],XMM2 MOVSD qword ptr [RSP + 0x30],XMM3 MOVSD qword ptr [RSP + 0x28],XMM4 MOVSD qword ptr [RSP + 0x20],XMM5 MOVSD qword ptr [RSP + 0x18],XMM6 MOVSD qword ptr [RSP + 0x10],XMM7 MOV RAX,qword ptr [RSP + 0x70] MOV qword ptr [RSP + 0x8],RAX MOV RDI,qword ptr [RSP + 0x68] CALL 0x00102450 MOV RCX,RAX MOV RAX,qword ptr [RSP + 0x8] MOV qword ptr [RAX + 0x80],RCX MOVSD XMM0,qword ptr [RSP + 0x60] MOVSD qword ptr [RAX + 0x88],XMM0 MOVSD XMM0,qword ptr [RSP + 0x58] MOVSD qword ptr [RAX + 0x90],XMM0 MOV RDI,qword ptr [RSP + 0x50] CALL 0x00102450 MOV RCX,RAX MOV RAX,qword ptr [RSP + 0x8] MOV qword ptr [RAX + 0x98],RCX MOV RDI,qword ptr [RSP + 0x48] CALL 0x00102450 MOV RCX,RAX MOV RAX,qword ptr [RSP + 0x8] MOV qword ptr [RAX + 0xa0],RCX MOV RDI,qword ptr [RSP + 0x40] CALL 0x00102450 MOV RCX,RAX MOV RAX,qword ptr [RSP + 0x8] MOV qword ptr [RAX + 0xa8],RCX MOVSD XMM0,qword ptr [RSP + 0x38] MOVSD qword ptr [RAX + 0xb0],XMM0 MOVSD XMM0,qword ptr [RSP + 0x30] MOVSD qword ptr [RAX + 0xb8],XMM0 MOVSD XMM0,qword ptr [RSP + 0x28] MOVSD qword ptr [RAX + 0xc0],XMM0 MOVSD XMM0,qword ptr [RSP + 0x20] MOVSD qword ptr [RAX + 0xc8],XMM0 MOVSD XMM0,qword ptr [RSP + 0x18] MOVSD qword ptr [RAX + 0xd0],XMM0 MOVSD XMM0,qword ptr [RSP + 0x10] MOVSD qword ptr [RAX + 0xd8],XMM0 ADD RSP,0x78 RET
/* LefDefParser::lefiVia::setViaRule(char const*, double, double, char const*, char const*, char const*, double, double, double, double, double, double) */ void __thiscall LefDefParser::lefiVia::setViaRule (lefiVia *this,char *param_1,double param_2,double param_3,char *param_4,char *param_5, char *param_6,double param_7,double param_8,double param_9,double param_10,double param_11 ,double param_12) { char *pcVar1; pcVar1 = strdup(param_1); *(char **)(this + 0x80) = pcVar1; *(double *)(this + 0x88) = param_2; *(double *)(this + 0x90) = param_3; pcVar1 = strdup(param_4); *(char **)(this + 0x98) = pcVar1; pcVar1 = strdup(param_5); *(char **)(this + 0xa0) = pcVar1; pcVar1 = strdup(param_6); *(char **)(this + 0xa8) = pcVar1; *(double *)(this + 0xb0) = param_7; *(double *)(this + 0xb8) = param_8; *(double *)(this + 0xc0) = param_9; *(double *)(this + 200) = param_10; *(double *)(this + 0xd0) = param_11; *(double *)(this + 0xd8) = param_12; return; }
47,443
patricia_to_nibbles
corpus-core[P]colibri-stateless/src/chains/eth/verifier/patricia.c
static uint8_t* patricia_to_nibbles(bytes_t p, bool prefix) { size_t count = 0; uint8_t* nibbles = safe_calloc(1 + (p.len << 1), 1); for (size_t i = 0; i < p.len; i++) { nibbles[count++] = p.data[i] >> 4; nibbles[count++] = p.data[i] & 0x0F; if (prefix && i == 0) nibbles[0] = nibbles[(count = nibbles[0] & 1 ? 1 : 0)]; } nibbles[count] = 0xFF; return nibbles; }
O0
c
patricia_to_nibbles: pushq %rbp movq %rsp, %rbp subq $0x30, %rsp movb %dl, %al movl %edi, -0x10(%rbp) movq %rsi, -0x8(%rbp) andb $0x1, %al movb %al, -0x11(%rbp) movq $0x0, -0x20(%rbp) movl -0x10(%rbp), %eax shll %eax addl $0x1, %eax movl %eax, %eax movl %eax, %edi movl $0x1, %esi callq 0x18620 movq %rax, -0x28(%rbp) movq $0x0, -0x30(%rbp) movq -0x30(%rbp), %rax movl -0x10(%rbp), %ecx cmpq %rcx, %rax jae 0x15949 movq -0x8(%rbp), %rax movq -0x30(%rbp), %rcx movzbl (%rax,%rcx), %eax sarl $0x4, %eax movb %al, %dl movq -0x28(%rbp), %rax movq -0x20(%rbp), %rcx movq %rcx, %rsi addq $0x1, %rsi movq %rsi, -0x20(%rbp) movb %dl, (%rax,%rcx) movq -0x8(%rbp), %rax movq -0x30(%rbp), %rcx movzbl (%rax,%rcx), %eax andl $0xf, %eax movb %al, %dl movq -0x28(%rbp), %rax movq -0x20(%rbp), %rcx movq %rcx, %rsi addq $0x1, %rsi movq %rsi, -0x20(%rbp) movb %dl, (%rax,%rcx) testb $0x1, -0x11(%rbp) je 0x15936 cmpq $0x0, -0x30(%rbp) jne 0x15936 movq -0x28(%rbp), %rax movq -0x28(%rbp), %rcx movzbl (%rcx), %esi andl $0x1, %esi xorl %ecx, %ecx movl $0x1, %edx cmpl $0x0, %esi cmovnel %edx, %ecx movslq %ecx, %rcx movq %rcx, -0x20(%rbp) movb (%rax,%rcx), %cl movq -0x28(%rbp), %rax movb %cl, (%rax) jmp 0x15938 movq -0x30(%rbp), %rax addq $0x1, %rax movq %rax, -0x30(%rbp) jmp 0x158a0 movq -0x28(%rbp), %rax movq -0x20(%rbp), %rcx movb $-0x1, (%rax,%rcx) movq -0x28(%rbp), %rax addq $0x30, %rsp popq %rbp retq nop
patricia_to_nibbles: push rbp mov rbp, rsp sub rsp, 30h mov al, dl mov [rbp+var_10], edi mov [rbp+var_8], rsi and al, 1 mov [rbp+var_11], al mov [rbp+var_20], 0 mov eax, [rbp+var_10] shl eax, 1 add eax, 1 mov eax, eax mov edi, eax mov esi, 1 call safe_calloc mov [rbp+var_28], rax mov [rbp+var_30], 0 loc_158A0: mov rax, [rbp+var_30] mov ecx, [rbp+var_10] cmp rax, rcx jnb loc_15949 mov rax, [rbp+var_8] mov rcx, [rbp+var_30] movzx eax, byte ptr [rax+rcx] sar eax, 4 mov dl, al mov rax, [rbp+var_28] mov rcx, [rbp+var_20] mov rsi, rcx add rsi, 1 mov [rbp+var_20], rsi mov [rax+rcx], dl mov rax, [rbp+var_8] mov rcx, [rbp+var_30] movzx eax, byte ptr [rax+rcx] and eax, 0Fh mov dl, al mov rax, [rbp+var_28] mov rcx, [rbp+var_20] mov rsi, rcx add rsi, 1 mov [rbp+var_20], rsi mov [rax+rcx], dl test [rbp+var_11], 1 jz short loc_15936 cmp [rbp+var_30], 0 jnz short loc_15936 mov rax, [rbp+var_28] mov rcx, [rbp+var_28] movzx esi, byte ptr [rcx] and esi, 1 xor ecx, ecx mov edx, 1 cmp esi, 0 cmovnz ecx, edx movsxd rcx, ecx mov [rbp+var_20], rcx mov cl, [rax+rcx] mov rax, [rbp+var_28] mov [rax], cl loc_15936: jmp short $+2 loc_15938: mov rax, [rbp+var_30] add rax, 1 mov [rbp+var_30], rax jmp loc_158A0 loc_15949: mov rax, [rbp+var_28] mov rcx, [rbp+var_20] mov byte ptr [rax+rcx], 0FFh mov rax, [rbp+var_28] add rsp, 30h pop rbp retn
_BYTE * patricia_to_nibbles(unsigned int a1, long long a2, char a3) { long long v3; // rcx unsigned long long i; // [rsp+0h] [rbp-30h] _BYTE *v6; // [rsp+8h] [rbp-28h] long long v7; // [rsp+10h] [rbp-20h] char v8; // [rsp+1Fh] [rbp-11h] v8 = a3 & 1; v7 = 0LL; v6 = (_BYTE *)safe_calloc(2 * a1 + 1, 1LL); for ( i = 0LL; i < a1; ++i ) { v6[v7] = (int)*(unsigned __int8 *)(a2 + i) >> 4; v3 = v7 + 1; v7 += 2LL; v6[v3] = *(_BYTE *)(a2 + i) & 0xF; if ( (v8 & 1) != 0 && !i ) { v7 = (*v6 & 1) != 0; *v6 = v6[v7]; } } v6[v7] = -1; return v6; }
patricia_to_nibbles: PUSH RBP MOV RBP,RSP SUB RSP,0x30 MOV AL,DL MOV dword ptr [RBP + -0x10],EDI MOV qword ptr [RBP + -0x8],RSI AND AL,0x1 MOV byte ptr [RBP + -0x11],AL MOV qword ptr [RBP + -0x20],0x0 MOV EAX,dword ptr [RBP + -0x10] SHL EAX,0x1 ADD EAX,0x1 MOV EAX,EAX MOV EDI,EAX MOV ESI,0x1 CALL 0x00118620 MOV qword ptr [RBP + -0x28],RAX MOV qword ptr [RBP + -0x30],0x0 LAB_001158a0: MOV RAX,qword ptr [RBP + -0x30] MOV ECX,dword ptr [RBP + -0x10] CMP RAX,RCX JNC 0x00115949 MOV RAX,qword ptr [RBP + -0x8] MOV RCX,qword ptr [RBP + -0x30] MOVZX EAX,byte ptr [RAX + RCX*0x1] SAR EAX,0x4 MOV DL,AL MOV RAX,qword ptr [RBP + -0x28] MOV RCX,qword ptr [RBP + -0x20] MOV RSI,RCX ADD RSI,0x1 MOV qword ptr [RBP + -0x20],RSI MOV byte ptr [RAX + RCX*0x1],DL MOV RAX,qword ptr [RBP + -0x8] MOV RCX,qword ptr [RBP + -0x30] MOVZX EAX,byte ptr [RAX + RCX*0x1] AND EAX,0xf MOV DL,AL MOV RAX,qword ptr [RBP + -0x28] MOV RCX,qword ptr [RBP + -0x20] MOV RSI,RCX ADD RSI,0x1 MOV qword ptr [RBP + -0x20],RSI MOV byte ptr [RAX + RCX*0x1],DL TEST byte ptr [RBP + -0x11],0x1 JZ 0x00115936 CMP qword ptr [RBP + -0x30],0x0 JNZ 0x00115936 MOV RAX,qword ptr [RBP + -0x28] MOV RCX,qword ptr [RBP + -0x28] MOVZX ESI,byte ptr [RCX] AND ESI,0x1 XOR ECX,ECX MOV EDX,0x1 CMP ESI,0x0 CMOVNZ ECX,EDX MOVSXD RCX,ECX MOV qword ptr [RBP + -0x20],RCX MOV CL,byte ptr [RAX + RCX*0x1] MOV RAX,qword ptr [RBP + -0x28] MOV byte ptr [RAX],CL LAB_00115936: JMP 0x00115938 LAB_00115938: MOV RAX,qword ptr [RBP + -0x30] ADD RAX,0x1 MOV qword ptr [RBP + -0x30],RAX JMP 0x001158a0 LAB_00115949: MOV RAX,qword ptr [RBP + -0x28] MOV RCX,qword ptr [RBP + -0x20] MOV byte ptr [RAX + RCX*0x1],0xff MOV RAX,qword ptr [RBP + -0x28] ADD RSP,0x30 POP RBP RET
byte * patricia_to_nibbles(uint param_1,long param_2,byte param_3) { byte *pbVar1; long lVar2; ulong local_38; long local_28; local_28 = 0; pbVar1 = (byte *)safe_calloc(param_1 * 2 + 1,1); for (local_38 = 0; local_38 < param_1; local_38 = local_38 + 1) { lVar2 = local_28 + 1; pbVar1[local_28] = (byte)((int)(uint)*(byte *)(param_2 + local_38) >> 4); local_28 = local_28 + 2; pbVar1[lVar2] = *(byte *)(param_2 + local_38) & 0xf; if (((param_3 & 1) != 0) && (local_38 == 0)) { local_28 = (long)(int)(uint)((*pbVar1 & 1) != 0); *pbVar1 = pbVar1[local_28]; } } pbVar1[local_28] = 0xff; return pbVar1; }
47,444
patricia_to_nibbles
corpus-core[P]colibri-stateless/src/chains/eth/verifier/patricia.c
static uint8_t* patricia_to_nibbles(bytes_t p, bool prefix) { size_t count = 0; uint8_t* nibbles = safe_calloc(1 + (p.len << 1), 1); for (size_t i = 0; i < p.len; i++) { nibbles[count++] = p.data[i] >> 4; nibbles[count++] = p.data[i] & 0x0F; if (prefix && i == 0) nibbles[0] = nibbles[(count = nibbles[0] & 1 ? 1 : 0)]; } nibbles[count] = 0xFF; return nibbles; }
O1
c
patricia_to_nibbles: pushq %r15 pushq %r14 pushq %rbx movl %edx, %ebx movq %rsi, %r14 movl %edi, %r15d leal 0x1(,%r15,2), %edi movl $0x1, %esi callq 0x1285b testl %r15d, %r15d je 0x10bca movl %r15d, %ecx xorl %edx, %edx xorb $0x1, %bl xorl %esi, %esi movb (%r14,%rdx), %dil shrb $0x4, %dil movb %dil, (%rax,%rsi) movb (%r14,%rdx), %dil andb $0xf, %dil movb %dil, 0x1(%rax,%rsi) testq %rdx, %rdx setne %dil orb %bl, %dil jne 0x10bbc movzbl (%rax), %esi andl $0x1, %esi movb (%rax,%rsi), %dil movb %dil, (%rax) jmp 0x10bc0 addq $0x2, %rsi incq %rdx cmpq %rdx, %rcx jne 0x10b88 jmp 0x10bcc xorl %esi, %esi movb $-0x1, (%rax,%rsi) popq %rbx popq %r14 popq %r15 retq
patricia_to_nibbles: push r15 push r14 push rbx mov ebx, edx mov r14, rsi mov r15d, edi lea edi, ds:1[r15*2] mov esi, 1 call safe_calloc test r15d, r15d jz short loc_10BCA mov ecx, r15d xor edx, edx xor bl, 1 xor esi, esi loc_10B88: mov dil, [r14+rdx] shr dil, 4 mov [rax+rsi], dil mov dil, [r14+rdx] and dil, 0Fh mov [rax+rsi+1], dil test rdx, rdx setnz dil or dil, bl jnz short loc_10BBC movzx esi, byte ptr [rax] and esi, 1 mov dil, [rax+rsi] mov [rax], dil jmp short loc_10BC0 loc_10BBC: add rsi, 2 loc_10BC0: inc rdx cmp rcx, rdx jnz short loc_10B88 jmp short loc_10BCC loc_10BCA: xor esi, esi loc_10BCC: mov byte ptr [rax+rsi], 0FFh pop rbx pop r14 pop r15 retn
_BYTE * patricia_to_nibbles(int a1, long long a2, char a3) { _BYTE *result; // rax long long v6; // rdx unsigned __int8 v7; // bl long long v8; // rsi result = (_BYTE *)safe_calloc((unsigned int)(2 * a1 + 1), 1LL); if ( a1 ) { v6 = 0LL; v7 = a3 ^ 1; v8 = 0LL; do { result[v8] = *(_BYTE *)(a2 + v6) >> 4; result[v8 + 1] = *(_BYTE *)(a2 + v6) & 0xF; if ( v7 | (v6 != 0) ) { v8 += 2LL; } else { v8 = *result & 1; *result = result[v8]; } ++v6; } while ( a1 != v6 ); } else { v8 = 0LL; } result[v8] = -1; return result; }
patricia_to_nibbles: PUSH R15 PUSH R14 PUSH RBX MOV EBX,EDX MOV R14,RSI MOV R15D,EDI LEA EDI,[0x1 + R15*0x2] MOV ESI,0x1 CALL 0x0011285b TEST R15D,R15D JZ 0x00110bca MOV ECX,R15D XOR EDX,EDX XOR BL,0x1 XOR ESI,ESI LAB_00110b88: MOV DIL,byte ptr [R14 + RDX*0x1] SHR DIL,0x4 MOV byte ptr [RAX + RSI*0x1],DIL MOV DIL,byte ptr [R14 + RDX*0x1] AND DIL,0xf MOV byte ptr [RAX + RSI*0x1 + 0x1],DIL TEST RDX,RDX SETNZ DIL OR DIL,BL JNZ 0x00110bbc MOVZX ESI,byte ptr [RAX] AND ESI,0x1 MOV DIL,byte ptr [RAX + RSI*0x1] MOV byte ptr [RAX],DIL JMP 0x00110bc0 LAB_00110bbc: ADD RSI,0x2 LAB_00110bc0: INC RDX CMP RCX,RDX JNZ 0x00110b88 JMP 0x00110bcc LAB_00110bca: XOR ESI,ESI LAB_00110bcc: MOV byte ptr [RAX + RSI*0x1],0xff POP RBX POP R14 POP R15 RET
void patricia_to_nibbles(uint param_1,long param_2,char param_3) { byte *pbVar1; ulong uVar2; ulong uVar3; pbVar1 = (byte *)safe_calloc(param_1 * 2 + 1); if (param_1 == 0) { uVar3 = 0; } else { uVar2 = 0; uVar3 = 0; do { pbVar1[uVar3] = *(byte *)(param_2 + uVar2) >> 4; pbVar1[uVar3 + 1] = *(byte *)(param_2 + uVar2) & 0xf; if (uVar2 == 0 && param_3 == '\x01') { uVar3 = (ulong)(*pbVar1 & 1); *pbVar1 = pbVar1[uVar3]; } else { uVar3 = uVar3 + 2; } uVar2 = uVar2 + 1; } while (param_1 != uVar2); } pbVar1[uVar3] = 0xff; return; }
47,445
patricia_to_nibbles
corpus-core[P]colibri-stateless/src/chains/eth/verifier/patricia.c
static uint8_t* patricia_to_nibbles(bytes_t p, bool prefix) { size_t count = 0; uint8_t* nibbles = safe_calloc(1 + (p.len << 1), 1); for (size_t i = 0; i < p.len; i++) { nibbles[count++] = p.data[i] >> 4; nibbles[count++] = p.data[i] & 0x0F; if (prefix && i == 0) nibbles[0] = nibbles[(count = nibbles[0] & 1 ? 1 : 0)]; } nibbles[count] = 0xFF; return nibbles; }
O2
c
patricia_to_nibbles: pushq %r15 pushq %r14 pushq %rbx movl %edx, %ebx movq %rsi, %r14 movl %edi, %r15d leal 0x1(%r15,%r15), %edi pushq $0x1 popq %rsi callq 0x1189d movl %r15d, %ecx xorl %edx, %edx xorb $0x1, %bl xorl %esi, %esi cmpq %rsi, %rcx je 0xfed6 movb (%r14,%rsi), %dil shrb $0x4, %dil movb %dil, (%rax,%rdx) movb (%r14,%rsi), %dil andb $0xf, %dil movb %dil, 0x1(%rax,%rdx) testq %rsi, %rsi setne %dil orb %bl, %dil jne 0xfecd movzbl (%rax), %edx andl $0x1, %edx movb (%rax,%rdx), %dil movb %dil, (%rax) jmp 0xfed1 addq $0x2, %rdx incq %rsi jmp 0xfe94 movb $-0x1, (%rax,%rdx) popq %rbx popq %r14 popq %r15 retq
patricia_to_nibbles: push r15 push r14 push rbx mov ebx, edx mov r14, rsi mov r15d, edi lea edi, [r15+r15+1] push 1 pop rsi call safe_calloc mov ecx, r15d xor edx, edx xor bl, 1 xor esi, esi loc_FE94: cmp rcx, rsi jz short loc_FED6 mov dil, [r14+rsi] shr dil, 4 mov [rax+rdx], dil mov dil, [r14+rsi] and dil, 0Fh mov [rax+rdx+1], dil test rsi, rsi setnz dil or dil, bl jnz short loc_FECD movzx edx, byte ptr [rax] and edx, 1 mov dil, [rax+rdx] mov [rax], dil jmp short loc_FED1 loc_FECD: add rdx, 2 loc_FED1: inc rsi jmp short loc_FE94 loc_FED6: mov byte ptr [rax+rdx], 0FFh pop rbx pop r14 pop r15 retn
_BYTE * patricia_to_nibbles(int a1, long long a2, char a3) { _BYTE *result; // rax long long v6; // rdx unsigned __int8 v7; // bl long long i; // rsi result = (_BYTE *)safe_calloc((unsigned int)(2 * a1 + 1), 1LL); v6 = 0LL; v7 = a3 ^ 1; for ( i = 0LL; a1 != i; ++i ) { result[v6] = *(_BYTE *)(a2 + i) >> 4; result[v6 + 1] = *(_BYTE *)(a2 + i) & 0xF; if ( v7 | (i != 0) ) { v6 += 2LL; } else { v6 = *result & 1; *result = result[v6]; } } result[v6] = -1; return result; }
patricia_to_nibbles: PUSH R15 PUSH R14 PUSH RBX MOV EBX,EDX MOV R14,RSI MOV R15D,EDI LEA EDI,[R15 + R15*0x1 + 0x1] PUSH 0x1 POP RSI CALL 0x0011189d MOV ECX,R15D XOR EDX,EDX XOR BL,0x1 XOR ESI,ESI LAB_0010fe94: CMP RCX,RSI JZ 0x0010fed6 MOV DIL,byte ptr [R14 + RSI*0x1] SHR DIL,0x4 MOV byte ptr [RAX + RDX*0x1],DIL MOV DIL,byte ptr [R14 + RSI*0x1] AND DIL,0xf MOV byte ptr [RAX + RDX*0x1 + 0x1],DIL TEST RSI,RSI SETNZ DIL OR DIL,BL JNZ 0x0010fecd MOVZX EDX,byte ptr [RAX] AND EDX,0x1 MOV DIL,byte ptr [RAX + RDX*0x1] MOV byte ptr [RAX],DIL JMP 0x0010fed1 LAB_0010fecd: ADD RDX,0x2 LAB_0010fed1: INC RSI JMP 0x0010fe94 LAB_0010fed6: MOV byte ptr [RAX + RDX*0x1],0xff POP RBX POP R14 POP R15 RET
void patricia_to_nibbles(uint param_1,long param_2,char param_3) { byte *pbVar1; ulong uVar2; ulong uVar3; pbVar1 = (byte *)safe_calloc(param_1 * 2 + 1); uVar2 = 0; for (uVar3 = 0; param_1 != uVar3; uVar3 = uVar3 + 1) { pbVar1[uVar2] = *(byte *)(param_2 + uVar3) >> 4; pbVar1[uVar2 + 1] = *(byte *)(param_2 + uVar3) & 0xf; if (uVar3 == 0 && param_3 == '\x01') { uVar2 = (ulong)(*pbVar1 & 1); *pbVar1 = pbVar1[uVar2]; } else { uVar2 = uVar2 + 2; } } pbVar1[uVar2] = 0xff; return; }
47,446
patricia_to_nibbles
corpus-core[P]colibri-stateless/src/chains/eth/verifier/patricia.c
static uint8_t* patricia_to_nibbles(bytes_t p, bool prefix) { size_t count = 0; uint8_t* nibbles = safe_calloc(1 + (p.len << 1), 1); for (size_t i = 0; i < p.len; i++) { nibbles[count++] = p.data[i] >> 4; nibbles[count++] = p.data[i] & 0x0F; if (prefix && i == 0) nibbles[0] = nibbles[(count = nibbles[0] & 1 ? 1 : 0)]; } nibbles[count] = 0xFF; return nibbles; }
O3
c
patricia_to_nibbles: pushq %r15 pushq %r14 pushq %rbx movl %edx, %ebx movq %rsi, %r14 movl %edi, %r15d leal 0x1(,%r15,2), %edi movl $0x1, %esi callq 0x12563 testl %r15d, %r15d je 0x10919 movl %r15d, %ecx xorl %edx, %edx xorb $0x1, %bl xorl %esi, %esi movb (%r14,%rdx), %dil shrb $0x4, %dil movb %dil, (%rax,%rsi) movb (%r14,%rdx), %dil andb $0xf, %dil movb %dil, 0x1(%rax,%rsi) testq %rdx, %rdx setne %dil orb %bl, %dil jne 0x1090b movzbl (%rax), %esi andl $0x1, %esi movb (%rax,%rsi), %dil movb %dil, (%rax) jmp 0x1090f addq $0x2, %rsi incq %rdx cmpq %rdx, %rcx jne 0x108d7 jmp 0x1091b xorl %esi, %esi movb $-0x1, (%rax,%rsi) popq %rbx popq %r14 popq %r15 retq
patricia_to_nibbles: push r15 push r14 push rbx mov ebx, edx mov r14, rsi mov r15d, edi lea edi, ds:1[r15*2] mov esi, 1 call safe_calloc test r15d, r15d jz short loc_10919 mov ecx, r15d xor edx, edx xor bl, 1 xor esi, esi loc_108D7: mov dil, [r14+rdx] shr dil, 4 mov [rax+rsi], dil mov dil, [r14+rdx] and dil, 0Fh mov [rax+rsi+1], dil test rdx, rdx setnz dil or dil, bl jnz short loc_1090B movzx esi, byte ptr [rax] and esi, 1 mov dil, [rax+rsi] mov [rax], dil jmp short loc_1090F loc_1090B: add rsi, 2 loc_1090F: inc rdx cmp rcx, rdx jnz short loc_108D7 jmp short loc_1091B loc_10919: xor esi, esi loc_1091B: mov byte ptr [rax+rsi], 0FFh pop rbx pop r14 pop r15 retn
_BYTE * patricia_to_nibbles(int a1, long long a2, char a3) { _BYTE *result; // rax long long v6; // rdx unsigned __int8 v7; // bl long long v8; // rsi result = (_BYTE *)safe_calloc((unsigned int)(2 * a1 + 1), 1LL); if ( a1 ) { v6 = 0LL; v7 = a3 ^ 1; v8 = 0LL; do { result[v8] = *(_BYTE *)(a2 + v6) >> 4; result[v8 + 1] = *(_BYTE *)(a2 + v6) & 0xF; if ( v7 | (v6 != 0) ) { v8 += 2LL; } else { v8 = *result & 1; *result = result[v8]; } ++v6; } while ( a1 != v6 ); } else { v8 = 0LL; } result[v8] = -1; return result; }
patricia_to_nibbles: PUSH R15 PUSH R14 PUSH RBX MOV EBX,EDX MOV R14,RSI MOV R15D,EDI LEA EDI,[0x1 + R15*0x2] MOV ESI,0x1 CALL 0x00112563 TEST R15D,R15D JZ 0x00110919 MOV ECX,R15D XOR EDX,EDX XOR BL,0x1 XOR ESI,ESI LAB_001108d7: MOV DIL,byte ptr [R14 + RDX*0x1] SHR DIL,0x4 MOV byte ptr [RAX + RSI*0x1],DIL MOV DIL,byte ptr [R14 + RDX*0x1] AND DIL,0xf MOV byte ptr [RAX + RSI*0x1 + 0x1],DIL TEST RDX,RDX SETNZ DIL OR DIL,BL JNZ 0x0011090b MOVZX ESI,byte ptr [RAX] AND ESI,0x1 MOV DIL,byte ptr [RAX + RSI*0x1] MOV byte ptr [RAX],DIL JMP 0x0011090f LAB_0011090b: ADD RSI,0x2 LAB_0011090f: INC RDX CMP RCX,RDX JNZ 0x001108d7 JMP 0x0011091b LAB_00110919: XOR ESI,ESI LAB_0011091b: MOV byte ptr [RAX + RSI*0x1],0xff POP RBX POP R14 POP R15 RET
void patricia_to_nibbles(uint param_1,long param_2,char param_3) { byte *pbVar1; ulong uVar2; ulong uVar3; pbVar1 = (byte *)safe_calloc(param_1 * 2 + 1); if (param_1 == 0) { uVar3 = 0; } else { uVar2 = 0; uVar3 = 0; do { pbVar1[uVar3] = *(byte *)(param_2 + uVar2) >> 4; pbVar1[uVar3 + 1] = *(byte *)(param_2 + uVar2) & 0xf; if (uVar2 == 0 && param_3 == '\x01') { uVar3 = (ulong)(*pbVar1 & 1); *pbVar1 = pbVar1[uVar3]; } else { uVar3 = uVar3 + 2; } uVar2 = uVar2 + 1; } while (param_1 != uVar2); } pbVar1[uVar3] = 0xff; return; }
47,447
stbi__pnm_info(stbi__context*, int*, int*, int*)
7CodeWizard[P]stablediffusion/thirdparty/stb_image.h
static int stbi__pnm_info(stbi__context *s, int *x, int *y, int *comp) { int maxv, dummy; char c, p, t; if (!x) x = &dummy; if (!y) y = &dummy; if (!comp) comp = &dummy; stbi__rewind(s); // Get identifier p = (char) stbi__get8(s); t = (char) stbi__get8(s); if (p != 'P' || (t != '5' && t != '6')) { stbi__rewind(s); return 0; } *comp = (t == '6') ? 3 : 1; // '5' is 1-component .pgm; '6' is 3-component .ppm c = (char) stbi__get8(s); stbi__pnm_skip_whitespace(s, &c); *x = stbi__pnm_getinteger(s, &c); // read width if(*x == 0) return stbi__err("invalid width", "PPM image header had zero or overflowing width"); stbi__pnm_skip_whitespace(s, &c); *y = stbi__pnm_getinteger(s, &c); // read height if (*y == 0) return stbi__err("invalid width", "PPM image header had zero or overflowing width"); stbi__pnm_skip_whitespace(s, &c); maxv = stbi__pnm_getinteger(s, &c); // read max value if (maxv > 65535) return stbi__err("max value > 65535", "PPM image supports only 8-bit and 16-bit images"); else if (maxv > 255) return 16; else return 8; }
O0
c
stbi__pnm_info(stbi__context*, int*, int*, int*): subq $0x38, %rsp movq %rdi, 0x28(%rsp) movq %rsi, 0x20(%rsp) movq %rdx, 0x18(%rsp) movq %rcx, 0x10(%rsp) cmpq $0x0, 0x20(%rsp) jne 0x2adca leaq 0x8(%rsp), %rax movq %rax, 0x20(%rsp) cmpq $0x0, 0x18(%rsp) jne 0x2addc leaq 0x8(%rsp), %rax movq %rax, 0x18(%rsp) cmpq $0x0, 0x10(%rsp) jne 0x2adee leaq 0x8(%rsp), %rax movq %rax, 0x10(%rsp) movq 0x28(%rsp), %rdi callq 0x17f10 movq 0x28(%rsp), %rdi callq 0x17f50 movb %al, 0x6(%rsp) movq 0x28(%rsp), %rdi callq 0x17f50 movb %al, 0x5(%rsp) movsbl 0x6(%rsp), %eax cmpl $0x50, %eax jne 0x2ae32 movsbl 0x5(%rsp), %eax cmpl $0x35, %eax je 0x2ae49 movsbl 0x5(%rsp), %eax cmpl $0x36, %eax je 0x2ae49 movq 0x28(%rsp), %rdi callq 0x17f10 movl $0x0, 0x34(%rsp) jmp 0x2af56 movsbl 0x5(%rsp), %edx movl $0x1, %ecx movl $0x3, %eax cmpl $0x36, %edx cmovel %eax, %ecx movq 0x10(%rsp), %rax movl %ecx, (%rax) movq 0x28(%rsp), %rdi callq 0x17f50 movb %al, 0x7(%rsp) movq 0x28(%rsp), %rdi leaq 0x7(%rsp), %rsi callq 0x2b090 movq 0x28(%rsp), %rdi leaq 0x7(%rsp), %rsi callq 0x2b180 movl %eax, %ecx movq 0x20(%rsp), %rax movl %ecx, (%rax) movq 0x20(%rsp), %rax cmpl $0x0, (%rax) jne 0x2aeb9 leaq 0x153ced(%rip), %rdi # 0x17eb98 callq 0xddd0 movl %eax, 0x34(%rsp) jmp 0x2af56 movq 0x28(%rsp), %rdi leaq 0x7(%rsp), %rsi callq 0x2b090 movq 0x28(%rsp), %rdi leaq 0x7(%rsp), %rsi callq 0x2b180 movl %eax, %ecx movq 0x18(%rsp), %rax movl %ecx, (%rax) movq 0x18(%rsp), %rax cmpl $0x0, (%rax) jne 0x2aefc leaq 0x153ca7(%rip), %rdi # 0x17eb98 callq 0xddd0 movl %eax, 0x34(%rsp) jmp 0x2af56 movq 0x28(%rsp), %rdi leaq 0x7(%rsp), %rsi callq 0x2b090 movq 0x28(%rsp), %rdi leaq 0x7(%rsp), %rsi callq 0x2b180 movl %eax, 0xc(%rsp) cmpl $0xffff, 0xc(%rsp) # imm = 0xFFFF jle 0x2af3a leaq 0x153f60(%rip), %rdi # 0x17ee8f callq 0xddd0 movl %eax, 0x34(%rsp) jmp 0x2af56 cmpl $0xff, 0xc(%rsp) jle 0x2af4e movl $0x10, 0x34(%rsp) jmp 0x2af56 movl $0x8, 0x34(%rsp) movl 0x34(%rsp), %eax addq $0x38, %rsp retq nop
_ZL14stbi__pnm_infoP13stbi__contextPiS1_S1_: sub rsp, 38h mov [rsp+38h+var_10], rdi mov [rsp+38h+var_18], rsi mov [rsp+38h+var_20], rdx mov [rsp+38h+var_28], rcx cmp [rsp+38h+var_18], 0 jnz short loc_2ADCA lea rax, [rsp+38h+var_30] mov [rsp+38h+var_18], rax loc_2ADCA: cmp [rsp+38h+var_20], 0 jnz short loc_2ADDC lea rax, [rsp+38h+var_30] mov [rsp+38h+var_20], rax loc_2ADDC: cmp [rsp+38h+var_28], 0 jnz short loc_2ADEE lea rax, [rsp+38h+var_30] mov [rsp+38h+var_28], rax loc_2ADEE: mov rdi, [rsp+38h+var_10] call _ZL12stbi__rewindP13stbi__context; stbi__rewind(stbi__context *) mov rdi, [rsp+38h+var_10] call _ZL10stbi__get8P13stbi__context; stbi__get8(stbi__context *) mov [rsp+38h+var_32], al mov rdi, [rsp+38h+var_10] call _ZL10stbi__get8P13stbi__context; stbi__get8(stbi__context *) mov [rsp+38h+var_33], al movsx eax, [rsp+38h+var_32] cmp eax, 50h ; 'P' jnz short loc_2AE32 movsx eax, [rsp+38h+var_33] cmp eax, 35h ; '5' jz short loc_2AE49 movsx eax, [rsp+38h+var_33] cmp eax, 36h ; '6' jz short loc_2AE49 loc_2AE32: mov rdi, [rsp+38h+var_10] call _ZL12stbi__rewindP13stbi__context; stbi__rewind(stbi__context *) mov [rsp+38h+var_4], 0 jmp loc_2AF56 loc_2AE49: movsx edx, [rsp+38h+var_33] mov ecx, 1 mov eax, 3 cmp edx, 36h ; '6' cmovz ecx, eax mov rax, [rsp+38h+var_28] mov [rax], ecx mov rdi, [rsp+38h+var_10] call _ZL10stbi__get8P13stbi__context; stbi__get8(stbi__context *) mov [rsp+38h+var_31], al mov rdi, [rsp+38h+var_10] lea rsi, [rsp+38h+var_31] call _ZL25stbi__pnm_skip_whitespaceP13stbi__contextPc; stbi__pnm_skip_whitespace(stbi__context *,char *) mov rdi, [rsp+38h+var_10] lea rsi, [rsp+38h+var_31] call _ZL20stbi__pnm_getintegerP13stbi__contextPc; stbi__pnm_getinteger(stbi__context *,char *) mov ecx, eax mov rax, [rsp+38h+var_18] mov [rax], ecx mov rax, [rsp+38h+var_18] cmp dword ptr [rax], 0 jnz short loc_2AEB9 lea rdi, aInvalidWidth; "invalid width" call _ZL9stbi__errPKc; stbi__err(char const*) mov [rsp+38h+var_4], eax jmp loc_2AF56 loc_2AEB9: mov rdi, [rsp+38h+var_10] lea rsi, [rsp+38h+var_31] call _ZL25stbi__pnm_skip_whitespaceP13stbi__contextPc; stbi__pnm_skip_whitespace(stbi__context *,char *) mov rdi, [rsp+38h+var_10] lea rsi, [rsp+38h+var_31] call _ZL20stbi__pnm_getintegerP13stbi__contextPc; stbi__pnm_getinteger(stbi__context *,char *) mov ecx, eax mov rax, [rsp+38h+var_20] mov [rax], ecx mov rax, [rsp+38h+var_20] cmp dword ptr [rax], 0 jnz short loc_2AEFC lea rdi, aInvalidWidth; "invalid width" call _ZL9stbi__errPKc; stbi__err(char const*) mov [rsp+38h+var_4], eax jmp short loc_2AF56 loc_2AEFC: mov rdi, [rsp+38h+var_10] lea rsi, [rsp+38h+var_31] call _ZL25stbi__pnm_skip_whitespaceP13stbi__contextPc; stbi__pnm_skip_whitespace(stbi__context *,char *) mov rdi, [rsp+38h+var_10] lea rsi, [rsp+38h+var_31] call _ZL20stbi__pnm_getintegerP13stbi__contextPc; stbi__pnm_getinteger(stbi__context *,char *) mov [rsp+38h+var_2C], eax cmp [rsp+38h+var_2C], 0FFFFh jle short loc_2AF3A lea rdi, aMaxValue65535; "max value > 65535" call _ZL9stbi__errPKc; stbi__err(char const*) mov [rsp+38h+var_4], eax jmp short loc_2AF56 loc_2AF3A: cmp [rsp+38h+var_2C], 0FFh jle short loc_2AF4E mov [rsp+38h+var_4], 10h jmp short loc_2AF56 loc_2AF4E: mov [rsp+38h+var_4], 8 loc_2AF56: mov eax, [rsp+38h+var_4] add rsp, 38h retn
long long stbi__pnm_info(_QWORD *a1, _DWORD *a2, _DWORD *a3, int *a4) { int v4; // ecx int v5; // eax int v6; // eax char v8; // [rsp+5h] [rbp-33h] char v9; // [rsp+6h] [rbp-32h] char v10; // [rsp+7h] [rbp-31h] BYREF _BYTE v11[4]; // [rsp+8h] [rbp-30h] BYREF int v12; // [rsp+Ch] [rbp-2Ch] int *v13; // [rsp+10h] [rbp-28h] _DWORD *v14; // [rsp+18h] [rbp-20h] _DWORD *v15; // [rsp+20h] [rbp-18h] _QWORD *v16; // [rsp+28h] [rbp-10h] v16 = a1; v15 = a2; v14 = a3; v13 = a4; if ( !a2 ) v15 = v11; if ( !v14 ) v14 = v11; if ( !v13 ) v13 = (int *)v11; stbi__rewind(v16); v9 = stbi__get8((long long)v16); v8 = stbi__get8((long long)v16); if ( v9 == 80 && (v8 == 53 || v8 == 54) ) { v4 = 1; if ( v8 == 54 ) v4 = 3; *v13 = v4; v10 = stbi__get8((long long)v16); stbi__pnm_skip_whitespace(v16, &v10); v5 = stbi__pnm_getinteger(v16, &v10); *v15 = v5; if ( *v15 && (stbi__pnm_skip_whitespace(v16, &v10), v6 = stbi__pnm_getinteger(v16, &v10), (*v14 = v6) != 0) ) { stbi__pnm_skip_whitespace(v16, &v10); v12 = stbi__pnm_getinteger(v16, &v10); if ( v12 <= 0xFFFF ) { if ( v12 <= 255 ) return 8; else return 16; } else { return (unsigned int)stbi__err("max value > 65535"); } } else { return (unsigned int)stbi__err("invalid width"); } } else { stbi__rewind(v16); return 0; } }
stbi__pnm_info: SUB RSP,0x38 MOV qword ptr [RSP + 0x28],RDI MOV qword ptr [RSP + 0x20],RSI MOV qword ptr [RSP + 0x18],RDX MOV qword ptr [RSP + 0x10],RCX CMP qword ptr [RSP + 0x20],0x0 JNZ 0x0012adca LEA RAX,[RSP + 0x8] MOV qword ptr [RSP + 0x20],RAX LAB_0012adca: CMP qword ptr [RSP + 0x18],0x0 JNZ 0x0012addc LEA RAX,[RSP + 0x8] MOV qword ptr [RSP + 0x18],RAX LAB_0012addc: CMP qword ptr [RSP + 0x10],0x0 JNZ 0x0012adee LEA RAX,[RSP + 0x8] MOV qword ptr [RSP + 0x10],RAX LAB_0012adee: MOV RDI,qword ptr [RSP + 0x28] CALL 0x00117f10 MOV RDI,qword ptr [RSP + 0x28] CALL 0x00117f50 MOV byte ptr [RSP + 0x6],AL MOV RDI,qword ptr [RSP + 0x28] CALL 0x00117f50 MOV byte ptr [RSP + 0x5],AL MOVSX EAX,byte ptr [RSP + 0x6] CMP EAX,0x50 JNZ 0x0012ae32 MOVSX EAX,byte ptr [RSP + 0x5] CMP EAX,0x35 JZ 0x0012ae49 MOVSX EAX,byte ptr [RSP + 0x5] CMP EAX,0x36 JZ 0x0012ae49 LAB_0012ae32: MOV RDI,qword ptr [RSP + 0x28] CALL 0x00117f10 MOV dword ptr [RSP + 0x34],0x0 JMP 0x0012af56 LAB_0012ae49: MOVSX EDX,byte ptr [RSP + 0x5] MOV ECX,0x1 MOV EAX,0x3 CMP EDX,0x36 CMOVZ ECX,EAX MOV RAX,qword ptr [RSP + 0x10] MOV dword ptr [RAX],ECX MOV RDI,qword ptr [RSP + 0x28] CALL 0x00117f50 MOV byte ptr [RSP + 0x7],AL MOV RDI,qword ptr [RSP + 0x28] LEA RSI,[RSP + 0x7] CALL 0x0012b090 MOV RDI,qword ptr [RSP + 0x28] LEA RSI,[RSP + 0x7] CALL 0x0012b180 MOV ECX,EAX MOV RAX,qword ptr [RSP + 0x20] MOV dword ptr [RAX],ECX MOV RAX,qword ptr [RSP + 0x20] CMP dword ptr [RAX],0x0 JNZ 0x0012aeb9 LEA RDI,[0x27eb98] CALL 0x0010ddd0 MOV dword ptr [RSP + 0x34],EAX JMP 0x0012af56 LAB_0012aeb9: MOV RDI,qword ptr [RSP + 0x28] LEA RSI,[RSP + 0x7] CALL 0x0012b090 MOV RDI,qword ptr [RSP + 0x28] LEA RSI,[RSP + 0x7] CALL 0x0012b180 MOV ECX,EAX MOV RAX,qword ptr [RSP + 0x18] MOV dword ptr [RAX],ECX MOV RAX,qword ptr [RSP + 0x18] CMP dword ptr [RAX],0x0 JNZ 0x0012aefc LEA RDI,[0x27eb98] CALL 0x0010ddd0 MOV dword ptr [RSP + 0x34],EAX JMP 0x0012af56 LAB_0012aefc: MOV RDI,qword ptr [RSP + 0x28] LEA RSI,[RSP + 0x7] CALL 0x0012b090 MOV RDI,qword ptr [RSP + 0x28] LEA RSI,[RSP + 0x7] CALL 0x0012b180 MOV dword ptr [RSP + 0xc],EAX CMP dword ptr [RSP + 0xc],0xffff JLE 0x0012af3a LEA RDI,[0x27ee8f] CALL 0x0010ddd0 MOV dword ptr [RSP + 0x34],EAX JMP 0x0012af56 LAB_0012af3a: CMP dword ptr [RSP + 0xc],0xff JLE 0x0012af4e MOV dword ptr [RSP + 0x34],0x10 JMP 0x0012af56 LAB_0012af4e: MOV dword ptr [RSP + 0x34],0x8 LAB_0012af56: MOV EAX,dword ptr [RSP + 0x34] ADD RSP,0x38 RET
/* stbi__pnm_info(stbi__context*, int*, int*, int*) */ int4 stbi__pnm_info(stbi__context *param_1,int *param_2,int *param_3,int *param_4) { char cVar1; char cVar2; int iVar3; char local_31; int local_30; int local_2c; int *local_28; int *local_20; int *local_18; stbi__context *local_10; int4 local_4; local_18 = param_2; if (param_2 == (int *)0x0) { local_18 = &local_30; } local_20 = param_3; if (param_3 == (int *)0x0) { local_20 = &local_30; } local_28 = param_4; if (param_4 == (int *)0x0) { local_28 = &local_30; } local_10 = param_1; stbi__rewind(param_1); cVar1 = stbi__get8(local_10); cVar2 = stbi__get8(local_10); if ((cVar1 == 'P') && ((cVar2 == '5' || (cVar2 == '6')))) { iVar3 = 1; if (cVar2 == '6') { iVar3 = 3; } *local_28 = iVar3; local_31 = stbi__get8(local_10); stbi__pnm_skip_whitespace(local_10,&local_31); iVar3 = stbi__pnm_getinteger(local_10,&local_31); *local_18 = iVar3; if (*local_18 == 0) { local_4 = stbi__err("invalid width"); } else { stbi__pnm_skip_whitespace(local_10,&local_31); iVar3 = stbi__pnm_getinteger(local_10,&local_31); *local_20 = iVar3; if (*local_20 == 0) { local_4 = stbi__err("invalid width"); } else { stbi__pnm_skip_whitespace(local_10,&local_31); local_2c = stbi__pnm_getinteger(local_10,&local_31); if (local_2c < 0x10000) { if (local_2c < 0x100) { local_4 = 8; } else { local_4 = 0x10; } } else { local_4 = stbi__err("max value > 65535"); } } } } else { stbi__rewind(local_10); local_4 = 0; } return local_4; }
47,448
stbi__pnm_info(stbi__context*, int*, int*, int*)
7CodeWizard[P]stablediffusion/thirdparty/stb_image.h
static int stbi__pnm_info(stbi__context *s, int *x, int *y, int *comp) { int maxv, dummy; char c, p, t; if (!x) x = &dummy; if (!y) y = &dummy; if (!comp) comp = &dummy; stbi__rewind(s); // Get identifier p = (char) stbi__get8(s); t = (char) stbi__get8(s); if (p != 'P' || (t != '5' && t != '6')) { stbi__rewind(s); return 0; } *comp = (t == '6') ? 3 : 1; // '5' is 1-component .pgm; '6' is 3-component .ppm c = (char) stbi__get8(s); stbi__pnm_skip_whitespace(s, &c); *x = stbi__pnm_getinteger(s, &c); // read width if(*x == 0) return stbi__err("invalid width", "PPM image header had zero or overflowing width"); stbi__pnm_skip_whitespace(s, &c); *y = stbi__pnm_getinteger(s, &c); // read height if (*y == 0) return stbi__err("invalid width", "PPM image header had zero or overflowing width"); stbi__pnm_skip_whitespace(s, &c); maxv = stbi__pnm_getinteger(s, &c); // read max value if (maxv > 65535) return stbi__err("max value > 65535", "PPM image supports only 8-bit and 16-bit images"); else if (maxv > 255) return 16; else return 8; }
O1
c
stbi__pnm_info(stbi__context*, int*, int*, int*): pushq %rbp pushq %r15 pushq %r14 pushq %r12 pushq %rbx subq $0x10, %rsp movq %rcx, %r12 movq %rdx, %r14 movq %rsi, %r15 movq %rdi, %rbx movq 0xd0(%rdi), %rax movq 0xd8(%rdi), %rcx movq %rax, 0xc0(%rdi) movq %rcx, 0xc8(%rdi) cmpq %rcx, %rax jb 0x2d57a cmpl $0x0, 0x30(%rbx) je 0x2d6cf movq %rbx, %rdi callq 0x2696c movq 0xc0(%rbx), %rax leaq 0x1(%rax), %rcx movq %rcx, 0xc0(%rbx) cmpb $0x50, (%rax) setne %bpl movq 0xc0(%rbx), %rax cmpq 0xc8(%rbx), %rax jb 0x2d5b5 cmpl $0x0, 0x30(%rbx) je 0x2d6d7 movq %rbx, %rdi callq 0x2696c movq 0xc0(%rbx), %rax leaq 0x1(%rax), %rcx movq %rcx, 0xc0(%rbx) movb (%rax), %al leal -0x37(%rax), %ecx cmpb $-0x2, %cl setae %cl notb %bpl testb %cl, %bpl jne 0x2d5e6 movups 0xd0(%rbx), %xmm0 movups %xmm0, 0xc0(%rbx) jmp 0x2d6c0 testq %r12, %r12 je 0x2d5fd xorl %ecx, %ecx cmpb $0x36, %al sete %cl leal 0x1(,%rcx,2), %eax movl %eax, (%r12) movq 0xc0(%rbx), %rax cmpq 0xc8(%rbx), %rax jb 0x2d626 cmpl $0x0, 0x30(%rbx) je 0x2d6f1 movq %rbx, %rdi callq 0x2696c movq 0xc0(%rbx), %rax leaq 0x1(%rax), %rcx movq %rcx, 0xc0(%rbx) movb (%rax), %al leaq 0xf(%rsp), %r12 movb %al, (%r12) movq %rbx, %rdi movq %r12, %rsi callq 0x2d7b0 movq %rbx, %rdi movq %r12, %rsi callq 0x2d8fb testq %r15, %r15 je 0x2d65a movl %eax, (%r15) testl %eax, %eax je 0x2d6b0 leaq 0xf(%rsp), %r15 movq %rbx, %rdi movq %r15, %rsi callq 0x2d7b0 movq %rbx, %rdi movq %r15, %rsi callq 0x2d8fb testq %r14, %r14 je 0x2d681 movl %eax, (%r14) testl %eax, %eax je 0x2d6b0 leaq 0xf(%rsp), %r14 movq %rbx, %rdi movq %r14, %rsi callq 0x2d7b0 movq %rbx, %rdi movq %r14, %rsi callq 0x2d8fb cmpl $0x10000, %eax # imm = 0x10000 jl 0x2d6de leaq 0x8f477(%rip), %rax # 0xbcb25 jmp 0x2d6b7 leaq 0x8f16c(%rip), %rax # 0xbc823 movq %rax, %fs:-0x20 xorl %eax, %eax addq $0x10, %rsp popq %rbx popq %r12 popq %r14 popq %r15 popq %rbp retq movb $0x1, %bpl jmp 0x2d58c xorl %eax, %eax jmp 0x2d5c2 xorl %ecx, %ecx cmpl $0x100, %eax # imm = 0x100 setge %cl leal 0x8(,%rcx,8), %eax jmp 0x2d6c2 xorl %eax, %eax jmp 0x2d633
_ZL14stbi__pnm_infoP13stbi__contextPiS1_S1_: push rbp push r15 push r14 push r12 push rbx sub rsp, 10h mov r12, rcx mov r14, rdx mov r15, rsi mov rbx, rdi mov rax, [rdi+0D0h] mov rcx, [rdi+0D8h] mov [rdi+0C0h], rax mov [rdi+0C8h], rcx cmp rax, rcx jb short loc_2D57A cmp dword ptr [rbx+30h], 0 jz loc_2D6CF mov rdi, rbx call _ZL19stbi__refill_bufferP13stbi__context; stbi__refill_buffer(stbi__context *) mov rax, [rbx+0C0h] loc_2D57A: lea rcx, [rax+1] mov [rbx+0C0h], rcx cmp byte ptr [rax], 50h ; 'P' setnz bpl loc_2D58C: mov rax, [rbx+0C0h] cmp rax, [rbx+0C8h] jb short loc_2D5B5 cmp dword ptr [rbx+30h], 0 jz loc_2D6D7 mov rdi, rbx call _ZL19stbi__refill_bufferP13stbi__context; stbi__refill_buffer(stbi__context *) mov rax, [rbx+0C0h] loc_2D5B5: lea rcx, [rax+1] mov [rbx+0C0h], rcx mov al, [rax] loc_2D5C2: lea ecx, [rax-37h] cmp cl, 0FEh setnb cl not bpl test bpl, cl jnz short loc_2D5E6 movups xmm0, xmmword ptr [rbx+0D0h] movups xmmword ptr [rbx+0C0h], xmm0 jmp loc_2D6C0 loc_2D5E6: test r12, r12 jz short loc_2D5FD xor ecx, ecx cmp al, 36h ; '6' setz cl lea eax, ds:1[rcx*2] mov [r12], eax loc_2D5FD: mov rax, [rbx+0C0h] cmp rax, [rbx+0C8h] jb short loc_2D626 cmp dword ptr [rbx+30h], 0 jz loc_2D6F1 mov rdi, rbx call _ZL19stbi__refill_bufferP13stbi__context; stbi__refill_buffer(stbi__context *) mov rax, [rbx+0C0h] loc_2D626: lea rcx, [rax+1] mov [rbx+0C0h], rcx mov al, [rax] loc_2D633: lea r12, [rsp+38h+var_29] mov [r12], al mov rdi, rbx mov rsi, r12 call _ZL25stbi__pnm_skip_whitespaceP13stbi__contextPc; stbi__pnm_skip_whitespace(stbi__context *,char *) mov rdi, rbx mov rsi, r12 call _ZL20stbi__pnm_getintegerP13stbi__contextPc; stbi__pnm_getinteger(stbi__context *,char *) test r15, r15 jz short loc_2D65A mov [r15], eax loc_2D65A: test eax, eax jz short loc_2D6B0 lea r15, [rsp+38h+var_29] mov rdi, rbx mov rsi, r15 call _ZL25stbi__pnm_skip_whitespaceP13stbi__contextPc; stbi__pnm_skip_whitespace(stbi__context *,char *) mov rdi, rbx mov rsi, r15 call _ZL20stbi__pnm_getintegerP13stbi__contextPc; stbi__pnm_getinteger(stbi__context *,char *) test r14, r14 jz short loc_2D681 mov [r14], eax loc_2D681: test eax, eax jz short loc_2D6B0 lea r14, [rsp+38h+var_29] mov rdi, rbx mov rsi, r14 call _ZL25stbi__pnm_skip_whitespaceP13stbi__contextPc; stbi__pnm_skip_whitespace(stbi__context *,char *) mov rdi, rbx mov rsi, r14 call _ZL20stbi__pnm_getintegerP13stbi__contextPc; stbi__pnm_getinteger(stbi__context *,char *) cmp eax, 10000h jl short loc_2D6DE lea rax, aMaxValue65535; "max value > 65535" jmp short loc_2D6B7 loc_2D6B0: lea rax, aInvalidWidth; "invalid width" loc_2D6B7: mov fs:0FFFFFFFFFFFFFFE0h, rax loc_2D6C0: xor eax, eax loc_2D6C2: add rsp, 10h pop rbx pop r12 pop r14 pop r15 pop rbp retn loc_2D6CF: mov bpl, 1 jmp loc_2D58C loc_2D6D7: xor eax, eax jmp loc_2D5C2 loc_2D6DE: xor ecx, ecx cmp eax, 100h setnl cl lea eax, ds:8[rcx*8] jmp short loc_2D6C2 loc_2D6F1: xor eax, eax jmp loc_2D633
long long stbi__pnm_info(long long a1, _DWORD *a2, _DWORD *a3, _DWORD *a4) { _BYTE *v6; // rax unsigned long long v7; // rcx char v8; // bp char *v9; // rax char v10; // al char *v11; // rax char v12; // al int v13; // eax int v14; // eax int v15; // eax const char *v16; // rax _BYTE v18[41]; // [rsp+Fh] [rbp-29h] BYREF v6 = *(_BYTE **)(a1 + 208); v7 = *(_QWORD *)(a1 + 216); *(_QWORD *)(a1 + 192) = v6; *(_QWORD *)(a1 + 200) = v7; if ( (unsigned long long)v6 < v7 ) goto LABEL_4; if ( *(_DWORD *)(a1 + 48) ) { stbi__refill_buffer(a1); v6 = *(_BYTE **)(a1 + 192); LABEL_4: *(_QWORD *)(a1 + 192) = v6 + 1; v8 = *v6 != 80; goto LABEL_5; } v8 = 1; LABEL_5: v9 = *(char **)(a1 + 192); if ( (unsigned long long)v9 < *(_QWORD *)(a1 + 200) ) { LABEL_8: *(_QWORD *)(a1 + 192) = v9 + 1; v10 = *v9; goto LABEL_9; } if ( *(_DWORD *)(a1 + 48) ) { stbi__refill_buffer(a1); v9 = *(char **)(a1 + 192); goto LABEL_8; } v10 = 0; LABEL_9: if ( (((unsigned __int8)(v10 - 55) >= 0xFEu) & (unsigned __int8)~v8) == 0 ) { *(_OWORD *)(a1 + 192) = *(_OWORD *)(a1 + 208); return 0LL; } if ( a4 ) *a4 = 2 * (v10 == 54) + 1; v11 = *(char **)(a1 + 192); if ( (unsigned long long)v11 < *(_QWORD *)(a1 + 200) ) goto LABEL_16; if ( *(_DWORD *)(a1 + 48) ) { stbi__refill_buffer(a1); v11 = *(char **)(a1 + 192); LABEL_16: *(_QWORD *)(a1 + 192) = v11 + 1; v12 = *v11; goto LABEL_17; } v12 = 0; LABEL_17: v18[0] = v12; stbi__pnm_skip_whitespace(a1, v18); v13 = stbi__pnm_getinteger(a1, v18); if ( a2 ) *a2 = v13; if ( !v13 ) goto LABEL_25; stbi__pnm_skip_whitespace(a1, v18); v14 = stbi__pnm_getinteger(a1, v18); if ( a3 ) *a3 = v14; if ( !v14 ) { LABEL_25: v16 = "invalid width"; goto LABEL_26; } stbi__pnm_skip_whitespace(a1, v18); v15 = stbi__pnm_getinteger(a1, v18); if ( v15 >= 0x10000 ) { v16 = "max value > 65535"; LABEL_26: __writefsqword(0xFFFFFFE0, (unsigned long long)v16); return 0LL; } return 8 * (unsigned int)(v15 >= 256) + 8; }
47,449
stbi__pnm_info(stbi__context*, int*, int*, int*)
7CodeWizard[P]stablediffusion/thirdparty/stb_image.h
static int stbi__pnm_info(stbi__context *s, int *x, int *y, int *comp) { int maxv, dummy; char c, p, t; if (!x) x = &dummy; if (!y) y = &dummy; if (!comp) comp = &dummy; stbi__rewind(s); // Get identifier p = (char) stbi__get8(s); t = (char) stbi__get8(s); if (p != 'P' || (t != '5' && t != '6')) { stbi__rewind(s); return 0; } *comp = (t == '6') ? 3 : 1; // '5' is 1-component .pgm; '6' is 3-component .ppm c = (char) stbi__get8(s); stbi__pnm_skip_whitespace(s, &c); *x = stbi__pnm_getinteger(s, &c); // read width if(*x == 0) return stbi__err("invalid width", "PPM image header had zero or overflowing width"); stbi__pnm_skip_whitespace(s, &c); *y = stbi__pnm_getinteger(s, &c); // read height if (*y == 0) return stbi__err("invalid width", "PPM image header had zero or overflowing width"); stbi__pnm_skip_whitespace(s, &c); maxv = stbi__pnm_getinteger(s, &c); // read max value if (maxv > 65535) return stbi__err("max value > 65535", "PPM image supports only 8-bit and 16-bit images"); else if (maxv > 255) return 16; else return 8; }
O2
c
stbi__pnm_info(stbi__context*, int*, int*, int*): pushq %rbp pushq %r15 pushq %r14 pushq %r12 pushq %rbx subq $0x10, %rsp movq %rcx, %r12 movq %rdx, %r14 movq %rsi, %r15 movq %rdi, %rbx movups 0xd0(%rdi), %xmm0 movups %xmm0, 0xc0(%rdi) callq 0x14342 movl %eax, %ebp movq %rbx, %rdi callq 0x14342 cmpb $0x50, %bpl sete %cl leal -0x37(%rax), %edx cmpb $-0x2, %dl setae %dl testb %dl, %cl jne 0x19131 movups 0xd0(%rbx), %xmm0 movups %xmm0, 0xc0(%rbx) jmp 0x191dd testq %r12, %r12 je 0x19148 xorl %ecx, %ecx cmpb $0x36, %al sete %cl leal 0x1(,%rcx,2), %eax movl %eax, (%r12) movq %rbx, %rdi callq 0x14342 leaq 0xf(%rsp), %r12 movb %al, (%r12) movq %rbx, %rdi movq %r12, %rsi callq 0x192b1 movq %rbx, %rdi movq %r12, %rsi callq 0x19329 testq %r15, %r15 je 0x19177 movl %eax, (%r15) testl %eax, %eax je 0x191cd leaq 0xf(%rsp), %r15 movq %rbx, %rdi movq %r15, %rsi callq 0x192b1 movq %rbx, %rdi movq %r15, %rsi callq 0x19329 testq %r14, %r14 je 0x1919e movl %eax, (%r14) testl %eax, %eax je 0x191cd leaq 0xf(%rsp), %r14 movq %rbx, %rdi movq %r14, %rsi callq 0x192b1 movq %rbx, %rdi movq %r14, %rsi callq 0x19329 cmpl $0x10000, %eax # imm = 0x10000 jl 0x191ec leaq 0x7f89a(%rip), %rax # 0x98a65 jmp 0x191d4 leaq 0x7f58f(%rip), %rax # 0x98763 movq %rax, %fs:-0x20 xorl %eax, %eax addq $0x10, %rsp popq %rbx popq %r12 popq %r14 popq %r15 popq %rbp retq xorl %ecx, %ecx cmpl $0x100, %eax # imm = 0x100 setge %cl leal 0x8(,%rcx,8), %eax jmp 0x191df
_ZL14stbi__pnm_infoP13stbi__contextPiS1_S1_: push rbp push r15 push r14 push r12 push rbx sub rsp, 10h mov r12, rcx mov r14, rdx mov r15, rsi mov rbx, rdi movups xmm0, xmmword ptr [rdi+0D0h] movups xmmword ptr [rdi+0C0h], xmm0 call _ZL10stbi__get8P13stbi__context; stbi__get8(stbi__context *) mov ebp, eax mov rdi, rbx call _ZL10stbi__get8P13stbi__context; stbi__get8(stbi__context *) cmp bpl, 50h ; 'P' setz cl lea edx, [rax-37h] cmp dl, 0FEh setnb dl test cl, dl jnz short loc_19131 movups xmm0, xmmword ptr [rbx+0D0h] movups xmmword ptr [rbx+0C0h], xmm0 jmp loc_191DD loc_19131: test r12, r12 jz short loc_19148 xor ecx, ecx cmp al, 36h ; '6' setz cl lea eax, ds:1[rcx*2] mov [r12], eax loc_19148: mov rdi, rbx call _ZL10stbi__get8P13stbi__context; stbi__get8(stbi__context *) lea r12, [rsp+38h+var_29] mov [r12], al mov rdi, rbx mov rsi, r12 call _ZL25stbi__pnm_skip_whitespaceP13stbi__contextPc; stbi__pnm_skip_whitespace(stbi__context *,char *) mov rdi, rbx mov rsi, r12 call _ZL20stbi__pnm_getintegerP13stbi__contextPc; stbi__pnm_getinteger(stbi__context *,char *) test r15, r15 jz short loc_19177 mov [r15], eax loc_19177: test eax, eax jz short loc_191CD lea r15, [rsp+38h+var_29] mov rdi, rbx mov rsi, r15 call _ZL25stbi__pnm_skip_whitespaceP13stbi__contextPc; stbi__pnm_skip_whitespace(stbi__context *,char *) mov rdi, rbx mov rsi, r15 call _ZL20stbi__pnm_getintegerP13stbi__contextPc; stbi__pnm_getinteger(stbi__context *,char *) test r14, r14 jz short loc_1919E mov [r14], eax loc_1919E: test eax, eax jz short loc_191CD lea r14, [rsp+38h+var_29] mov rdi, rbx mov rsi, r14 call _ZL25stbi__pnm_skip_whitespaceP13stbi__contextPc; stbi__pnm_skip_whitespace(stbi__context *,char *) mov rdi, rbx mov rsi, r14 call _ZL20stbi__pnm_getintegerP13stbi__contextPc; stbi__pnm_getinteger(stbi__context *,char *) cmp eax, 10000h jl short loc_191EC lea rax, aMaxValue65535; "max value > 65535" jmp short loc_191D4 loc_191CD: lea rax, aInvalidWidth; "invalid width" loc_191D4: mov fs:0FFFFFFFFFFFFFFE0h, rax loc_191DD: xor eax, eax loc_191DF: add rsp, 10h pop rbx pop r12 pop r14 pop r15 pop rbp retn loc_191EC: xor ecx, ecx cmp eax, 100h setnl cl lea eax, ds:8[rcx*8] jmp short loc_191DF
long long stbi__pnm_info(long long a1, _DWORD *a2, _DWORD *a3, _DWORD *a4) { char v6; // bp char v7; // al int v8; // eax int v9; // eax int v10; // eax const char *v11; // rax _BYTE v13[41]; // [rsp+Fh] [rbp-29h] BYREF *(_OWORD *)(a1 + 192) = *(_OWORD *)(a1 + 208); v6 = stbi__get8(a1); v7 = stbi__get8(a1); if ( (unsigned __int8)(v7 - 55) < 0xFEu || v6 != 80 ) { *(_OWORD *)(a1 + 192) = *(_OWORD *)(a1 + 208); return 0LL; } if ( a4 ) *a4 = 2 * (v7 == 54) + 1; v13[0] = stbi__get8(a1); stbi__pnm_skip_whitespace(a1, v13); v8 = stbi__pnm_getinteger(a1, v13); if ( a2 ) *a2 = v8; if ( !v8 ) goto LABEL_13; stbi__pnm_skip_whitespace(a1, v13); v9 = stbi__pnm_getinteger(a1, v13); if ( a3 ) *a3 = v9; if ( !v9 ) { LABEL_13: v11 = "invalid width"; goto LABEL_14; } stbi__pnm_skip_whitespace(a1, v13); v10 = stbi__pnm_getinteger(a1, v13); if ( v10 >= 0x10000 ) { v11 = "max value > 65535"; LABEL_14: __writefsqword(0xFFFFFFE0, (unsigned long long)v11); return 0LL; } return 8 * (unsigned int)(v10 >= 256) + 8; }
stbi__pnm_info: PUSH RBP PUSH R15 PUSH R14 PUSH R12 PUSH RBX SUB RSP,0x10 MOV R12,RCX MOV R14,RDX MOV R15,RSI MOV RBX,RDI MOVUPS XMM0,xmmword ptr [RDI + 0xd0] MOVUPS xmmword ptr [RDI + 0xc0],XMM0 CALL 0x00114342 MOV EBP,EAX MOV RDI,RBX CALL 0x00114342 CMP BPL,0x50 SETZ CL LEA EDX,[RAX + -0x37] CMP DL,0xfe SETNC DL TEST CL,DL JNZ 0x00119131 MOVUPS XMM0,xmmword ptr [RBX + 0xd0] MOVUPS xmmword ptr [RBX + 0xc0],XMM0 JMP 0x001191dd LAB_00119131: TEST R12,R12 JZ 0x00119148 XOR ECX,ECX CMP AL,0x36 SETZ CL LEA EAX,[0x1 + RCX*0x2] MOV dword ptr [R12],EAX LAB_00119148: MOV RDI,RBX CALL 0x00114342 LEA R12,[RSP + 0xf] MOV byte ptr [R12],AL MOV RDI,RBX MOV RSI,R12 CALL 0x001192b1 MOV RDI,RBX MOV RSI,R12 CALL 0x00119329 TEST R15,R15 JZ 0x00119177 MOV dword ptr [R15],EAX LAB_00119177: TEST EAX,EAX JZ 0x001191cd LEA R15,[RSP + 0xf] MOV RDI,RBX MOV RSI,R15 CALL 0x001192b1 MOV RDI,RBX MOV RSI,R15 CALL 0x00119329 TEST R14,R14 JZ 0x0011919e MOV dword ptr [R14],EAX LAB_0011919e: TEST EAX,EAX JZ 0x001191cd LEA R14,[RSP + 0xf] MOV RDI,RBX MOV RSI,R14 CALL 0x001192b1 MOV RDI,RBX MOV RSI,R14 CALL 0x00119329 CMP EAX,0x10000 JL 0x001191ec LEA RAX,[0x198a65] JMP 0x001191d4 LAB_001191cd: LEA RAX,[0x198763] LAB_001191d4: MOV qword ptr FS:[-0x20],RAX LAB_001191dd: XOR EAX,EAX LAB_001191df: ADD RSP,0x10 POP RBX POP R12 POP R14 POP R15 POP RBP RET LAB_001191ec: XOR ECX,ECX CMP EAX,0x100 SETGE CL LEA EAX,[0x8 + RCX*0x8] JMP 0x001191df
/* stbi__pnm_info(stbi__context*, int*, int*, int*) */ char stbi__pnm_info(stbi__context *param_1,int *param_2,int *param_3,int *param_4) { char cVar1; char cVar2; int iVar3; char *pcVar4; long in_FS_OFFSET; char local_29; *(int8 *)(param_1 + 0xc0) = *(int8 *)(param_1 + 0xd0); *(int8 *)(param_1 + 200) = *(int8 *)(param_1 + 0xd8); cVar1 = stbi__get8(param_1); cVar2 = stbi__get8(param_1); if (cVar1 != 'P' || (byte)(cVar2 - 0x37U) < 0xfe) { *(int8 *)(param_1 + 0xc0) = *(int8 *)(param_1 + 0xd0); *(int8 *)(param_1 + 200) = *(int8 *)(param_1 + 0xd8); return '\0'; } if (param_4 != (int *)0x0) { *param_4 = (uint)(cVar2 == '6') * 2 + 1; } local_29 = stbi__get8(param_1); stbi__pnm_skip_whitespace(param_1,&local_29); iVar3 = stbi__pnm_getinteger(param_1,&local_29); if (param_2 != (int *)0x0) { *param_2 = iVar3; } if (iVar3 != 0) { stbi__pnm_skip_whitespace(param_1,&local_29); iVar3 = stbi__pnm_getinteger(param_1,&local_29); if (param_3 != (int *)0x0) { *param_3 = iVar3; } if (iVar3 != 0) { stbi__pnm_skip_whitespace(param_1,&local_29); iVar3 = stbi__pnm_getinteger(param_1,&local_29); if (iVar3 < 0x10000) { return (0xff < iVar3) * '\b' + '\b'; } pcVar4 = "max value > 65535"; goto LAB_001191d4; } } pcVar4 = "invalid width"; LAB_001191d4: *(char **)(in_FS_OFFSET + -0x20) = pcVar4; return '\0'; }
47,450
translog_check_sector_protection
eloqsql/storage/maria/ma_loghandler.c
static my_bool translog_check_sector_protection(uchar *page, TRANSLOG_FILE *file) { uint i, offset; uchar *table= page + page_overhead[page[TRANSLOG_PAGE_FLAGS]] - TRANSLOG_PAGE_SIZE / DISK_DRIVE_SECTOR_SIZE; uint8 current= table[0]; DBUG_ENTER("translog_check_sector_protection"); for (i= 1, offset= DISK_DRIVE_SECTOR_SIZE; i < TRANSLOG_PAGE_SIZE / DISK_DRIVE_SECTOR_SIZE; i++, offset+= DISK_DRIVE_SECTOR_SIZE) { /* TODO: add chunk counting for "suspecting" sectors (difference is more than 1-2), if difference more then present chunks then it is the problem. */ uint8 test= page[offset]; DBUG_PRINT("info", ("sector: #%u offset: %u current: %lx " "read: 0x%x stored: 0x%x%x", i, offset, (ulong) current, (uint) uint2korr(page + offset), (uint) table[i], (uint) table[i + 1])); /* 3 is minimal possible record length. So we can have "distance" between 2 sectors value more then DISK_DRIVE_SECTOR_SIZE / 3 only if it is old value, i.e. the sector was not written. */ if (((test < current) && ((uint)(0xFFL - current + test) > DISK_DRIVE_SECTOR_SIZE / 3)) || ((test >= current) && ((uint)(test - current) > DISK_DRIVE_SECTOR_SIZE / 3))) { if (translog_recover_page_up_to_sector(page, offset)) DBUG_RETURN(1); file->was_recovered= 1; DBUG_RETURN(0); } /* Restore value on the page */ page[offset]= table[i]; current= test; DBUG_PRINT("info", ("sector: #%u offset: %u current: %lx " "read: 0x%x stored: 0x%x", i, offset, (ulong) current, (uint) page[offset], (uint) table[i])); } DBUG_RETURN(0); }
O3
c
translog_check_sector_protection: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx pushq %rax movq %rdi, %r14 movzbl 0x6(%rdi), %ecx leaq 0xbb1b43(%rip), %rax # 0xc01960 movl (%rax,%rcx,4), %ecx addq %rdi, %rcx addq $-0xf, %rcx movb -0x1(%rcx), %r9b movl $0x400, %r12d # imm = 0x400 movb -0x200(%r14,%r12), %dl movzbl %dl, %edi cmpb %r9b, %dil jae 0x4fe57 movl %r9d, %r8d notb %r8b movzbl %r8b, %r8d addl %edi, %r8d cmpl $0xaa, %r8d ja 0x4fe91 cmpb %r9b, %dl jb 0x4fe6b movzbl %r9b, %r8d subl %r8d, %edi cmpl $0xab, %edi jae 0x4fe91 movb (%rcx), %dil movb %dil, -0x200(%r14,%r12) incq %rcx addq $0x200, %r12 # imm = 0x200 movl %edx, %r9d cmpq $0x2200, %r12 # imm = 0x2200 jne 0x4fe31 jmp 0x4ff53 movq %rsi, -0x30(%rbp) leaq -0x200(%r12), %rbx movzbl 0x6(%r14), %ecx movsbl (%rax,%rcx,4), %r13d movzwl %r13w, %r15d movb (%r14,%r15), %al cmpw %bx, %r13w jae 0x4fef3 cmpb $-0x1, %al je 0x4ff2a movq %r14, %rdi movl %r15d, %esi callq 0x4b880 movl %eax, %ecx movb $0x1, %al testw %cx, %cx je 0x4ff55 movzwl %cx, %edx addq %r15, %rdx cmpq $0x2001, %rdx # imm = 0x2001 movl $0x0, %esi cmovael %esi, %ecx addl %ecx, %r13d cmpl $0x2001, %edx # imm = 0x2001 jb 0x4fea7 jmp 0x4ff55 cmpb $-0x1, %al movq -0x30(%rbp), %rbx je 0x4ff37 movzwl %r13w, %esi movq %r14, %rdi callq 0x4b880 testw %ax, %ax je 0x4ff30 movzwl %ax, %ecx addq %rcx, %r15 cmpq %r12, %r15 ja 0x4ff30 addl %r13d, %eax movzwl %ax, %r15d cmpb $-0x1, (%r14,%r15) movl %eax, %r13d jne 0x4fefb jmp 0x4ff33 movq -0x30(%rbp), %rbx jmp 0x4ff37 movl %r13d, %eax movzwl %ax, %r15d addq %r15, %r14 movl $0x2000, %edx # imm = 0x2000 subl %r15d, %edx movq %r14, %rdi movl $0xff, %esi callq 0x292c0 movb $0x1, 0x50(%rbx) xorl %eax, %eax addq $0x8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
translog_check_sector_protection: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx push rax mov r14, rdi movzx ecx, byte ptr [rdi+6] lea rax, page_overhead mov ecx, [rax+rcx*4] add rcx, rdi add rcx, 0FFFFFFFFFFFFFFF1h mov r9b, [rcx-1] mov r12d, 400h loc_4FE31: mov dl, [r14+r12-200h] movzx edi, dl cmp dil, r9b jnb short loc_4FE57 mov r8d, r9d not r8b movzx r8d, r8b add r8d, edi cmp r8d, 0AAh ja short loc_4FE91 loc_4FE57: cmp dl, r9b jb short loc_4FE6B movzx r8d, r9b sub edi, r8d cmp edi, 0ABh jnb short loc_4FE91 loc_4FE6B: mov dil, [rcx] mov [r14+r12-200h], dil inc rcx add r12, 200h mov r9d, edx cmp r12, 2200h jnz short loc_4FE31 jmp loc_4FF53 loc_4FE91: mov [rbp+var_30], rsi lea rbx, [r12-200h] movzx ecx, byte ptr [r14+6] movsx r13d, byte ptr [rax+rcx*4] loc_4FEA7: movzx r15d, r13w mov al, [r14+r15] cmp r13w, bx jnb short loc_4FEF3 cmp al, 0FFh jz short loc_4FF2A mov rdi, r14 mov esi, r15d call translog_get_total_chunk_length mov ecx, eax mov al, 1 test cx, cx jz loc_4FF55 movzx edx, cx add rdx, r15 cmp rdx, 2001h mov esi, 0 cmovnb ecx, esi add r13d, ecx cmp edx, 2001h jb short loc_4FEA7 jmp short loc_4FF55 loc_4FEF3: cmp al, 0FFh mov rbx, [rbp+var_30] jz short loc_4FF37 loc_4FEFB: movzx esi, r13w mov rdi, r14 call translog_get_total_chunk_length test ax, ax jz short loc_4FF30 movzx ecx, ax add r15, rcx cmp r15, r12 ja short loc_4FF30 add eax, r13d movzx r15d, ax cmp byte ptr [r14+r15], 0FFh mov r13d, eax jnz short loc_4FEFB jmp short loc_4FF33 loc_4FF2A: mov rbx, [rbp+var_30] jmp short loc_4FF37 loc_4FF30: mov eax, r13d loc_4FF33: movzx r15d, ax loc_4FF37: add r14, r15 mov edx, 2000h sub edx, r15d mov rdi, r14 mov esi, 0FFh call _memset mov byte ptr [rbx+50h], 1 loc_4FF53: xor eax, eax loc_4FF55: add rsp, 8 pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
char translog_check_sector_protection(long long a1, long long a2) { _BYTE *v2; // rcx unsigned __int8 v3; // r9 unsigned long long v4; // r12 unsigned __int8 v5; // dl int v6; // r13d long long v7; // r15 char v8; // al int total_chunk_length; // ecx char result; // al unsigned long long v11; // rdx long long v12; // rbx int v13; // eax int v14; // eax v2 = (_BYTE *)(a1 + *((unsigned int *)&page_overhead + *(unsigned __int8 *)(a1 + 6)) - 15); v3 = *(_BYTE *)(a1 + *((unsigned int *)&page_overhead + *(unsigned __int8 *)(a1 + 6)) - 16); v4 = 1024LL; while ( 1 ) { v5 = *(_BYTE *)(a1 + v4 - 512); if ( v5 < v3 && v5 + (unsigned int)(unsigned __int8)~v3 > 0xAA ) break; if ( v5 >= v3 && v5 - (unsigned int)v3 >= 0xAB ) break; *(_BYTE *)(a1 + v4 - 512) = *v2++; v4 += 512LL; v3 = v5; if ( v4 == 8704 ) return 0; } v6 = *((char *)&page_overhead + 4 * *(unsigned __int8 *)(a1 + 6)); while ( 1 ) { v7 = (unsigned __int16)v6; v8 = *(_BYTE *)(a1 + (unsigned __int16)v6); if ( (unsigned __int16)v6 >= (unsigned __int16)(v4 - 512) ) break; if ( v8 == -1 ) { v12 = a2; goto LABEL_24; } total_chunk_length = translog_get_total_chunk_length(a1, (unsigned __int16)v6); result = 1; if ( (_WORD)total_chunk_length ) { v11 = (unsigned __int16)v6 + (unsigned long long)(unsigned __int16)total_chunk_length; if ( v11 >= 0x2001 ) total_chunk_length = 0; v6 += total_chunk_length; if ( (unsigned int)v11 < 0x2001 ) continue; } return result; } v12 = a2; if ( v8 != -1 ) { while ( 1 ) { v13 = translog_get_total_chunk_length(a1, (unsigned __int16)v6); if ( !(_WORD)v13 || (unsigned long long)(unsigned __int16)v13 + v7 > v4 ) break; v14 = v6 + v13; v7 = (unsigned __int16)v14; v6 = v14; if ( *(_BYTE *)(a1 + (unsigned __int16)v14) == 0xFF ) goto LABEL_23; } LOWORD(v14) = v6; LABEL_23: v7 = (unsigned __int16)v14; } LABEL_24: memset(v7 + a1, 255LL, (unsigned int)(0x2000 - v7)); *(_BYTE *)(v12 + 80) = 1; return 0; }
translog_check_sector_protection: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX PUSH RAX MOV R14,RDI MOVZX ECX,byte ptr [RDI + 0x6] LEA RAX,[0xd01960] MOV ECX,dword ptr [RAX + RCX*0x4] ADD RCX,RDI ADD RCX,-0xf MOV R9B,byte ptr [RCX + -0x1] MOV R12D,0x400 LAB_0014fe31: MOV DL,byte ptr [R14 + R12*0x1 + -0x200] MOVZX EDI,DL CMP DIL,R9B JNC 0x0014fe57 MOV R8D,R9D NOT R8B MOVZX R8D,R8B ADD R8D,EDI CMP R8D,0xaa JA 0x0014fe91 LAB_0014fe57: CMP DL,R9B JC 0x0014fe6b MOVZX R8D,R9B SUB EDI,R8D CMP EDI,0xab JNC 0x0014fe91 LAB_0014fe6b: MOV DIL,byte ptr [RCX] MOV byte ptr [R14 + R12*0x1 + -0x200],DIL INC RCX ADD R12,0x200 MOV R9D,EDX CMP R12,0x2200 JNZ 0x0014fe31 JMP 0x0014ff53 LAB_0014fe91: MOV qword ptr [RBP + -0x30],RSI LEA RBX,[R12 + -0x200] MOVZX ECX,byte ptr [R14 + 0x6] MOVSX R13D,byte ptr [RAX + RCX*0x4] LAB_0014fea7: MOVZX R15D,R13W MOV AL,byte ptr [R14 + R15*0x1] CMP R13W,BX JNC 0x0014fef3 CMP AL,0xff JZ 0x0014ff2a MOV RDI,R14 MOV ESI,R15D CALL 0x0014b880 MOV ECX,EAX MOV AL,0x1 TEST CX,CX JZ 0x0014ff55 MOVZX EDX,CX ADD RDX,R15 CMP RDX,0x2001 MOV ESI,0x0 CMOVNC ECX,ESI ADD R13D,ECX CMP EDX,0x2001 JC 0x0014fea7 JMP 0x0014ff55 LAB_0014fef3: CMP AL,0xff MOV RBX,qword ptr [RBP + -0x30] JZ 0x0014ff37 LAB_0014fefb: MOVZX ESI,R13W MOV RDI,R14 CALL 0x0014b880 TEST AX,AX JZ 0x0014ff30 MOVZX ECX,AX ADD R15,RCX CMP R15,R12 JA 0x0014ff30 ADD EAX,R13D MOVZX R15D,AX CMP byte ptr [R14 + R15*0x1],0xff MOV R13D,EAX JNZ 0x0014fefb JMP 0x0014ff33 LAB_0014ff2a: MOV RBX,qword ptr [RBP + -0x30] JMP 0x0014ff37 LAB_0014ff30: MOV EAX,R13D LAB_0014ff33: MOVZX R15D,AX LAB_0014ff37: ADD R14,R15 MOV EDX,0x2000 SUB EDX,R15D MOV RDI,R14 MOV ESI,0xff CALL 0x001292c0 MOV byte ptr [RBX + 0x50],0x1 LAB_0014ff53: XOR EAX,EAX LAB_0014ff55: ADD RSP,0x8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
int8 translog_check_sector_protection(long param_1,long param_2) { byte bVar1; ushort uVar2; int1 *puVar3; ulong uVar4; byte bVar5; ulong uVar6; ushort uVar7; ulong uVar8; puVar3 = (int1 *) ((ulong)*(uint *)(page_overhead + (ulong)*(byte *)(param_1 + 6) * 4) + param_1 + -0xf); uVar6 = 0x400; bVar5 = *(byte *)((ulong)*(uint *)(page_overhead + (ulong)*(byte *)(param_1 + 6) * 4) + param_1 + -0x10); while( true ) { bVar1 = *(byte *)(param_1 + -0x200 + uVar6); if (((bVar1 < bVar5) && (0xaa < (uint)(byte)~bVar5 + (uint)bVar1)) || ((bVar5 <= bVar1 && (0xaa < (uint)bVar1 - (uint)bVar5)))) break; *(int1 *)(param_1 + -0x200 + uVar6) = *puVar3; puVar3 = puVar3 + 1; uVar6 = uVar6 + 0x200; bVar5 = bVar1; if (uVar6 == 0x2200) { return 0; } } uVar7 = (ushort)(char)page_overhead[(ulong)*(byte *)(param_1 + 6) * 4]; while( true ) { uVar8 = (ulong)uVar7; if ((ushort)((short)uVar6 - 0x200U) <= uVar7) break; if (*(char *)(param_1 + uVar8) == -1) goto LAB_0014ff37; uVar2 = translog_get_total_chunk_length(param_1,uVar8); if (uVar2 == 0) { return 1; } uVar4 = (ulong)uVar2; if (0x2000 < uVar4 + uVar8) { uVar2 = 0; } uVar7 = uVar7 + uVar2; if (0x2000 < (uint)(uVar4 + uVar8)) { return 1; } } if (*(char *)(param_1 + uVar8) != -1) { do { uVar2 = translog_get_total_chunk_length(param_1,uVar7); if ((uVar2 == 0) || (uVar6 < uVar8 + uVar2)) break; uVar7 = uVar2 + uVar7; uVar8 = (ulong)uVar7; } while (*(char *)(param_1 + uVar8) != -1); uVar8 = (ulong)uVar7; } LAB_0014ff37: memset((void *)(param_1 + uVar8),0xff,(ulong)(0x2000 - (int)uVar8)); *(int1 *)(param_2 + 0x50) = 1; return 0; }
47,451
translog_read_next_record_header
eloqsql/storage/maria/ma_loghandler.c
int translog_read_next_record_header(TRANSLOG_SCANNER_DATA *scanner, TRANSLOG_HEADER_BUFFER *buff) { translog_size_t res; DBUG_ENTER("translog_read_next_record_header"); buff->groups_no= 0; /* to be sure that we will free it right */ DBUG_PRINT("enter", ("scanner: %p", scanner)); DBUG_PRINT("info", ("Scanner: Cur: " LSN_FMT " Hrz: " LSN_FMT " " "Lst: " LSN_FMT " Offset: %u(%x) fixed: %d", LSN_IN_PARTS(scanner->page_addr), LSN_IN_PARTS(scanner->horizon), LSN_IN_PARTS(scanner->last_file_page), (uint) scanner->page_offset, (uint) scanner->page_offset, scanner->fixed_horizon)); DBUG_ASSERT(translog_status == TRANSLOG_OK || translog_status == TRANSLOG_READONLY); do { if (translog_get_next_chunk(scanner)) DBUG_RETURN(RECHEADER_READ_ERROR); if (scanner->page == END_OF_LOG) { DBUG_PRINT("info", ("End of file from the scanner")); /* Last record was read */ buff->lsn= LSN_IMPOSSIBLE; DBUG_RETURN(RECHEADER_READ_EOF); } DBUG_PRINT("info", ("Page: " LSN_FMT " offset: %lu byte: %x", LSN_IN_PARTS(scanner->page_addr), (ulong) scanner->page_offset, (uint) scanner->page[scanner->page_offset])); } while (!translog_is_LSN_chunk(scanner->page[scanner->page_offset]) && scanner->page[scanner->page_offset] != TRANSLOG_FILLER); if (scanner->page[scanner->page_offset] == TRANSLOG_FILLER) { DBUG_PRINT("info", ("End of file")); /* Last record was read */ buff->lsn= LSN_IMPOSSIBLE; /* Return 'end of log' marker */ res= RECHEADER_READ_EOF; } else res= translog_read_record_header_scan(scanner, buff, 0); DBUG_RETURN(res); }
O0
c
translog_read_next_record_header: pushq %rbp movq %rsp, %rbp subq $0x20, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq -0x18(%rbp), %rax movl $0x0, 0x418(%rax) jmp 0x8d5e0 jmp 0x8d5e2 jmp 0x8d5e4 jmp 0x8d5e6 jmp 0x8d5e8 jmp 0x8d5ea movq -0x10(%rbp), %rdi callq 0x8aab0 cmpb $0x0, %al je 0x8d605 jmp 0x8d5f9 movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF jmp 0x8d6e5 movq -0x10(%rbp), %rax leaq 0xbf7da0(%rip), %rcx # 0xc853b0 cmpq %rcx, 0x2018(%rax) jne 0x8d634 jmp 0x8d61b jmp 0x8d61d movq -0x18(%rbp), %rax movq $0x0, (%rax) movl $0xfffffffe, -0x4(%rbp) # imm = 0xFFFFFFFE jmp 0x8d6e5 jmp 0x8d636 jmp 0x8d638 jmp 0x8d63a movq -0x10(%rbp), %rax movq 0x2018(%rax), %rax movq -0x10(%rbp), %rcx movl 0x2028(%rcx), %ecx movzbl (%rax,%rcx), %edi callq 0x8aa50 movb %al, %cl xorl %eax, %eax cmpb $0x0, %cl movb %al, -0x1d(%rbp) jne 0x8d688 movq -0x10(%rbp), %rax movq 0x2018(%rax), %rax movq -0x10(%rbp), %rcx movl 0x2028(%rcx), %ecx movzbl (%rax,%rcx), %eax cmpl $0xff, %eax setne %al movb %al, -0x1d(%rbp) movb -0x1d(%rbp), %al testb $0x1, %al jne 0x8d5ea movq -0x10(%rbp), %rax movq 0x2018(%rax), %rax movq -0x10(%rbp), %rcx movl 0x2028(%rcx), %ecx movzbl (%rax,%rcx), %eax cmpl $0xff, %eax jne 0x8d6cb jmp 0x8d6b5 jmp 0x8d6b7 movq -0x18(%rbp), %rax movq $0x0, (%rax) movl $0xfffffffe, -0x1c(%rbp) # imm = 0xFFFFFFFE jmp 0x8d6dd movq -0x10(%rbp), %rdi movq -0x18(%rbp), %rsi xorl %edx, %edx callq 0x8d500 movl %eax, -0x1c(%rbp) jmp 0x8d6df movl -0x1c(%rbp), %eax movl %eax, -0x4(%rbp) movl -0x4(%rbp), %eax addq $0x20, %rsp popq %rbp retq nop
translog_read_next_record_header: push rbp mov rbp, rsp sub rsp, 20h mov [rbp+var_10], rdi mov [rbp+var_18], rsi mov rax, [rbp+var_18] mov dword ptr [rax+418h], 0 jmp short $+2 loc_8D5E0: jmp short $+2 loc_8D5E2: jmp short $+2 loc_8D5E4: jmp short $+2 loc_8D5E6: jmp short $+2 loc_8D5E8: jmp short $+2 loc_8D5EA: mov rdi, [rbp+var_10] call translog_get_next_chunk cmp al, 0 jz short loc_8D605 jmp short $+2 loc_8D5F9: mov [rbp+var_4], 0FFFFFFFFh jmp loc_8D6E5 loc_8D605: mov rax, [rbp+var_10] lea rcx, end_of_log cmp [rax+2018h], rcx jnz short loc_8D634 jmp short $+2 loc_8D61B: jmp short $+2 loc_8D61D: mov rax, [rbp+var_18] mov qword ptr [rax], 0 mov [rbp+var_4], 0FFFFFFFEh jmp loc_8D6E5 loc_8D634: jmp short $+2 loc_8D636: jmp short $+2 loc_8D638: jmp short $+2 loc_8D63A: mov rax, [rbp+var_10] mov rax, [rax+2018h] mov rcx, [rbp+var_10] mov ecx, [rcx+2028h] movzx edi, byte ptr [rax+rcx] call translog_is_LSN_chunk mov cl, al xor eax, eax cmp cl, 0 mov [rbp+var_1D], al jnz short loc_8D688 mov rax, [rbp+var_10] mov rax, [rax+2018h] mov rcx, [rbp+var_10] mov ecx, [rcx+2028h] movzx eax, byte ptr [rax+rcx] cmp eax, 0FFh setnz al mov [rbp+var_1D], al loc_8D688: mov al, [rbp+var_1D] test al, 1 jnz loc_8D5EA mov rax, [rbp+var_10] mov rax, [rax+2018h] mov rcx, [rbp+var_10] mov ecx, [rcx+2028h] movzx eax, byte ptr [rax+rcx] cmp eax, 0FFh jnz short loc_8D6CB jmp short $+2 loc_8D6B5: jmp short $+2 loc_8D6B7: mov rax, [rbp+var_18] mov qword ptr [rax], 0 mov [rbp+var_1C], 0FFFFFFFEh jmp short loc_8D6DD loc_8D6CB: mov rdi, [rbp+var_10] mov rsi, [rbp+var_18] xor edx, edx call translog_read_record_header_scan mov [rbp+var_1C], eax loc_8D6DD: jmp short $+2 loc_8D6DF: mov eax, [rbp+var_1C] mov [rbp+var_4], eax loc_8D6E5: mov eax, [rbp+var_4] add rsp, 20h pop rbp retn
long long translog_read_next_record_header(long long a1, long long a2) { bool v3; // [rsp+3h] [rbp-1Dh] *(_DWORD *)(a2 + 1048) = 0; do { if ( translog_get_next_chunk(a1) ) return (unsigned int)-1; if ( *(_UNKNOWN **)(a1 + 8216) == &end_of_log ) { *(_QWORD *)a2 = 0LL; return (unsigned int)-2; } v3 = 0; if ( !(unsigned __int8)translog_is_LSN_chunk(*(_BYTE *)(*(_QWORD *)(a1 + 8216) + *(unsigned int *)(a1 + 8232))) ) v3 = *(unsigned __int8 *)(*(_QWORD *)(a1 + 8216) + *(unsigned int *)(a1 + 8232)) != 255; } while ( v3 ); if ( *(unsigned __int8 *)(*(_QWORD *)(a1 + 8216) + *(unsigned int *)(a1 + 8232)) == 255 ) { *(_QWORD *)a2 = 0LL; return (unsigned int)-2; } else { return (unsigned int)translog_read_record_header_scan(a1, a2, 0); } }
translog_read_next_record_header: 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] MOV dword ptr [RAX + 0x418],0x0 JMP 0x0018d5e0 LAB_0018d5e0: JMP 0x0018d5e2 LAB_0018d5e2: JMP 0x0018d5e4 LAB_0018d5e4: JMP 0x0018d5e6 LAB_0018d5e6: JMP 0x0018d5e8 LAB_0018d5e8: JMP 0x0018d5ea LAB_0018d5ea: MOV RDI,qword ptr [RBP + -0x10] CALL 0x0018aab0 CMP AL,0x0 JZ 0x0018d605 JMP 0x0018d5f9 LAB_0018d5f9: MOV dword ptr [RBP + -0x4],0xffffffff JMP 0x0018d6e5 LAB_0018d605: MOV RAX,qword ptr [RBP + -0x10] LEA RCX,[0xd853b0] CMP qword ptr [RAX + 0x2018],RCX JNZ 0x0018d634 JMP 0x0018d61b LAB_0018d61b: JMP 0x0018d61d LAB_0018d61d: MOV RAX,qword ptr [RBP + -0x18] MOV qword ptr [RAX],0x0 MOV dword ptr [RBP + -0x4],0xfffffffe JMP 0x0018d6e5 LAB_0018d634: JMP 0x0018d636 LAB_0018d636: JMP 0x0018d638 LAB_0018d638: JMP 0x0018d63a LAB_0018d63a: MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x2018] MOV RCX,qword ptr [RBP + -0x10] MOV ECX,dword ptr [RCX + 0x2028] MOVZX EDI,byte ptr [RAX + RCX*0x1] CALL 0x0018aa50 MOV CL,AL XOR EAX,EAX CMP CL,0x0 MOV byte ptr [RBP + -0x1d],AL JNZ 0x0018d688 MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x2018] MOV RCX,qword ptr [RBP + -0x10] MOV ECX,dword ptr [RCX + 0x2028] MOVZX EAX,byte ptr [RAX + RCX*0x1] CMP EAX,0xff SETNZ AL MOV byte ptr [RBP + -0x1d],AL LAB_0018d688: MOV AL,byte ptr [RBP + -0x1d] TEST AL,0x1 JNZ 0x0018d5ea MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x2018] MOV RCX,qword ptr [RBP + -0x10] MOV ECX,dword ptr [RCX + 0x2028] MOVZX EAX,byte ptr [RAX + RCX*0x1] CMP EAX,0xff JNZ 0x0018d6cb JMP 0x0018d6b5 LAB_0018d6b5: JMP 0x0018d6b7 LAB_0018d6b7: MOV RAX,qword ptr [RBP + -0x18] MOV qword ptr [RAX],0x0 MOV dword ptr [RBP + -0x1c],0xfffffffe JMP 0x0018d6dd LAB_0018d6cb: MOV RDI,qword ptr [RBP + -0x10] MOV RSI,qword ptr [RBP + -0x18] XOR EDX,EDX CALL 0x0018d500 MOV dword ptr [RBP + -0x1c],EAX LAB_0018d6dd: JMP 0x0018d6df LAB_0018d6df: MOV EAX,dword ptr [RBP + -0x1c] MOV dword ptr [RBP + -0x4],EAX LAB_0018d6e5: MOV EAX,dword ptr [RBP + -0x4] ADD RSP,0x20 POP RBP RET
int4 translog_read_next_record_header(long param_1,int8 *param_2) { char cVar1; bool bVar2; int4 local_24; *(int4 *)(param_2 + 0x83) = 0; while( true ) { cVar1 = translog_get_next_chunk(param_1); if (cVar1 != '\0') { return 0xffffffff; } if (*(int1 **)(param_1 + 0x2018) == &end_of_log) break; cVar1 = translog_is_LSN_chunk (*(int1 *) (*(long *)(param_1 + 0x2018) + (ulong)*(uint *)(param_1 + 0x2028))); bVar2 = false; if (cVar1 == '\0') { bVar2 = *(char *)(*(long *)(param_1 + 0x2018) + (ulong)*(uint *)(param_1 + 0x2028)) != -1; } if (!bVar2) { if (*(char *)(*(long *)(param_1 + 0x2018) + (ulong)*(uint *)(param_1 + 0x2028)) == -1) { *param_2 = 0; local_24 = 0xfffffffe; } else { local_24 = translog_read_record_header_scan(param_1,param_2,0); } return local_24; } } *param_2 = 0; return 0xfffffffe; }
47,452
insert_dynamic
eloqsql/mysys/array.c
my_bool insert_dynamic(DYNAMIC_ARRAY *array, const void * element) { void *buffer; if (array->elements == array->max_element) { /* Call only when necessary */ if (!(buffer=alloc_dynamic(array))) return TRUE; } else { buffer=array->buffer+(array->elements * array->size_of_element); array->elements++; } memcpy(buffer,element,(size_t) array->size_of_element); return FALSE; }
O0
c
insert_dynamic: pushq %rbp movq %rsp, %rbp subq $0x20, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq -0x10(%rbp), %rax movl 0x8(%rax), %eax movq -0x10(%rbp), %rcx cmpl 0xc(%rcx), %eax jne 0xe231b movq -0x10(%rbp), %rdi callq 0xe2370 movq %rax, -0x20(%rbp) cmpq $0x0, %rax jne 0xe2319 movb $0x1, -0x1(%rbp) jmp 0xe2361 jmp 0xe2347 movq -0x10(%rbp), %rax movq (%rax), %rax movq -0x10(%rbp), %rcx movl 0x8(%rcx), %ecx movq -0x10(%rbp), %rdx imull 0x14(%rdx), %ecx movl %ecx, %ecx addq %rcx, %rax movq %rax, -0x20(%rbp) movq -0x10(%rbp), %rax movl 0x8(%rax), %ecx addl $0x1, %ecx movl %ecx, 0x8(%rax) movq -0x20(%rbp), %rdi movq -0x18(%rbp), %rsi movq -0x10(%rbp), %rax movl 0x14(%rax), %eax movl %eax, %edx callq 0x29090 movb $0x0, -0x1(%rbp) movb -0x1(%rbp), %al addq $0x20, %rsp popq %rbp retq nopw (%rax,%rax)
insert_dynamic: push rbp mov rbp, rsp sub rsp, 20h mov [rbp+var_10], rdi mov [rbp+var_18], rsi mov rax, [rbp+var_10] mov eax, [rax+8] mov rcx, [rbp+var_10] cmp eax, [rcx+0Ch] jnz short loc_E231B mov rdi, [rbp+var_10] call alloc_dynamic mov [rbp+var_20], rax cmp rax, 0 jnz short loc_E2319 mov [rbp+var_1], 1 jmp short loc_E2361 loc_E2319: jmp short loc_E2347 loc_E231B: mov rax, [rbp+var_10] mov rax, [rax] mov rcx, [rbp+var_10] mov ecx, [rcx+8] mov rdx, [rbp+var_10] imul ecx, [rdx+14h] mov ecx, ecx add rax, rcx mov [rbp+var_20], rax mov rax, [rbp+var_10] mov ecx, [rax+8] add ecx, 1 mov [rax+8], ecx loc_E2347: mov rdi, [rbp+var_20] mov rsi, [rbp+var_18] mov rax, [rbp+var_10] mov eax, [rax+14h] mov edx, eax call _memcpy mov [rbp+var_1], 0 loc_E2361: mov al, [rbp+var_1] add rsp, 20h pop rbp retn
char insert_dynamic(long long a1, long long a2) { long long v3; // [rsp+0h] [rbp-20h] if ( *(_DWORD *)(a1 + 8) != *(_DWORD *)(a1 + 12) ) { v3 = (unsigned int)(*(_DWORD *)(a1 + 20) * (*(_DWORD *)(a1 + 8))++) + *(_QWORD *)a1; LABEL_6: memcpy(v3, a2, *(unsigned int *)(a1 + 20)); return 0; } v3 = alloc_dynamic(a1); if ( v3 ) goto LABEL_6; return 1; }
insert_dynamic: 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 + -0x10] MOV EAX,dword ptr [RAX + 0x8] MOV RCX,qword ptr [RBP + -0x10] CMP EAX,dword ptr [RCX + 0xc] JNZ 0x001e231b MOV RDI,qword ptr [RBP + -0x10] CALL 0x001e2370 MOV qword ptr [RBP + -0x20],RAX CMP RAX,0x0 JNZ 0x001e2319 MOV byte ptr [RBP + -0x1],0x1 JMP 0x001e2361 LAB_001e2319: JMP 0x001e2347 LAB_001e231b: MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX] MOV RCX,qword ptr [RBP + -0x10] MOV ECX,dword ptr [RCX + 0x8] MOV RDX,qword ptr [RBP + -0x10] IMUL ECX,dword ptr [RDX + 0x14] MOV ECX,ECX ADD RAX,RCX MOV qword ptr [RBP + -0x20],RAX MOV RAX,qword ptr [RBP + -0x10] MOV ECX,dword ptr [RAX + 0x8] ADD ECX,0x1 MOV dword ptr [RAX + 0x8],ECX LAB_001e2347: MOV RDI,qword ptr [RBP + -0x20] MOV RSI,qword ptr [RBP + -0x18] MOV RAX,qword ptr [RBP + -0x10] MOV EAX,dword ptr [RAX + 0x14] MOV EDX,EAX CALL 0x00129090 MOV byte ptr [RBP + -0x1],0x0 LAB_001e2361: MOV AL,byte ptr [RBP + -0x1] ADD RSP,0x20 POP RBP RET
int1 insert_dynamic(long *param_1,void *param_2) { void *local_28; if ((int)param_1[1] == *(int *)((long)param_1 + 0xc)) { local_28 = (void *)alloc_dynamic(param_1); if (local_28 == (void *)0x0) { return 1; } } else { local_28 = (void *)(*param_1 + (ulong)(uint)((int)param_1[1] * *(int *)((long)param_1 + 0x14))); *(int *)(param_1 + 1) = (int)param_1[1] + 1; } memcpy(local_28,param_2,(ulong)*(uint *)((long)param_1 + 0x14)); return 0; }
47,453
ma_bitmap_create_first
eloqsql/storage/maria/ma_bitmap.c
int _ma_bitmap_create_first(MARIA_SHARE *share) { uint block_size= share->bitmap.block_size; File file= share->bitmap.file.file; uchar marker[CRC_SIZE]; /* Next write operation of the page will write correct CRC if it is needed */ int4store(marker, MARIA_NO_CRC_BITMAP_PAGE); if (mysql_file_chsize(file, block_size - sizeof(marker), 0, MYF(MY_WME)) || my_pwrite(file, marker, sizeof(marker), block_size - sizeof(marker), MYF(MY_NABP | MY_WME))) return 1; share->state.state.data_file_length= block_size; _ma_bitmap_delete_all(share); return 0; }
O0
c
ma_bitmap_create_first: pushq %rbp movq %rsp, %rbp subq $0x30, %rsp movq %fs:0x28, %rax movq %rax, -0x8(%rbp) movq %rdi, -0x18(%rbp) movq -0x18(%rbp), %rax movl 0xb44(%rax), %eax movl %eax, -0x1c(%rbp) movq -0x18(%rbp), %rax movl 0xa60(%rax), %eax movl %eax, -0x20(%rbp) leaq -0xc(%rbp), %rax movq %rax, -0x28(%rbp) movq -0x28(%rbp), %rax movl $0xfffffffe, (%rax) # imm = 0xFFFFFFFE movl -0x20(%rbp), %edx movl -0x1c(%rbp), %eax movl %eax, %ecx subq $0x4, %rcx leaq 0x10d3eb(%rip), %rdi # 0x151683 movl $0xc0f, %esi # imm = 0xC0F xorl %r8d, %r8d movl $0x10, %r9d callq 0x44330 cmpl $0x0, %eax jne 0x442d6 movl -0x20(%rbp), %edi leaq -0xc(%rbp), %rsi movl -0x1c(%rbp), %eax movl %eax, %ecx subq $0x4, %rcx movl $0x4, %edx movl $0x14, %r8d callq 0xf4860 cmpq $0x0, %rax je 0x442df movl $0x1, -0x10(%rbp) jmp 0x442fc movl -0x1c(%rbp), %eax movl %eax, %ecx movq -0x18(%rbp), %rax movq %rcx, 0x40(%rax) movq -0x18(%rbp), %rdi callq 0x42430 movl $0x0, -0x10(%rbp) movl -0x10(%rbp), %eax movl %eax, -0x2c(%rbp) movq %fs:0x28, %rax movq -0x8(%rbp), %rcx cmpq %rcx, %rax jne 0x4431d movl -0x2c(%rbp), %eax addq $0x30, %rsp popq %rbp retq callq 0x2a270 nopw %cs:(%rax,%rax)
_ma_bitmap_create_first: push rbp mov rbp, rsp sub rsp, 30h mov rax, fs:28h mov [rbp+var_8], rax mov [rbp+var_18], rdi mov rax, [rbp+var_18] mov eax, [rax+0B44h] mov [rbp+var_1C], eax mov rax, [rbp+var_18] mov eax, [rax+0A60h] mov [rbp+var_20], eax lea rax, [rbp+var_C] mov [rbp+var_28], rax mov rax, [rbp+var_28] mov dword ptr [rax], 0FFFFFFFEh mov edx, [rbp+var_20] mov eax, [rbp+var_1C] mov ecx, eax sub rcx, 4 lea rdi, aWorkspaceLlm4b_6; "/workspace/llm4binary/github2025/eloqsq"... mov esi, 0C0Fh xor r8d, r8d mov r9d, 10h call inline_mysql_file_chsize cmp eax, 0 jnz short loc_442D6 mov edi, [rbp+var_20] lea rsi, [rbp+var_C] mov eax, [rbp+var_1C] mov ecx, eax sub rcx, 4 mov edx, 4 mov r8d, 14h call my_pwrite cmp rax, 0 jz short loc_442DF loc_442D6: mov [rbp+var_10], 1 jmp short loc_442FC loc_442DF: mov eax, [rbp+var_1C] mov ecx, eax mov rax, [rbp+var_18] mov [rax+40h], rcx mov rdi, [rbp+var_18] call _ma_bitmap_delete_all mov [rbp+var_10], 0 loc_442FC: mov eax, [rbp+var_10] mov [rbp+var_2C], eax mov rax, fs:28h mov rcx, [rbp+var_8] cmp rax, rcx jnz short loc_4431D mov eax, [rbp+var_2C] add rsp, 30h pop rbp retn loc_4431D: call ___stack_chk_fail
long long ma_bitmap_create_first(long long a1) { unsigned int v2; // [rsp+10h] [rbp-20h] unsigned int v3; // [rsp+14h] [rbp-1Ch] int v5; // [rsp+24h] [rbp-Ch] BYREF unsigned long long v6; // [rsp+28h] [rbp-8h] v6 = __readfsqword(0x28u); v3 = *(_DWORD *)(a1 + 2884); v2 = *(_DWORD *)(a1 + 2656); v5 = -2; if ( (unsigned int)inline_mysql_file_chsize( "/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_bitmap.c", 3087LL, v2, v3 - 4LL, 0LL, 16LL) || my_pwrite(v2, &v5, 4LL, v3 - 4LL) ) { return 1; } else { *(_QWORD *)(a1 + 64) = v3; ma_bitmap_delete_all(a1); return 0; } }
_ma_bitmap_create_first: PUSH RBP MOV RBP,RSP SUB RSP,0x30 MOV RAX,qword ptr FS:[0x28] MOV qword ptr [RBP + -0x8],RAX MOV qword ptr [RBP + -0x18],RDI MOV RAX,qword ptr [RBP + -0x18] MOV EAX,dword ptr [RAX + 0xb44] MOV dword ptr [RBP + -0x1c],EAX MOV RAX,qword ptr [RBP + -0x18] MOV EAX,dword ptr [RAX + 0xa60] MOV dword ptr [RBP + -0x20],EAX LEA RAX,[RBP + -0xc] MOV qword ptr [RBP + -0x28],RAX MOV RAX,qword ptr [RBP + -0x28] MOV dword ptr [RAX],0xfffffffe MOV EDX,dword ptr [RBP + -0x20] MOV EAX,dword ptr [RBP + -0x1c] MOV ECX,EAX SUB RCX,0x4 LEA RDI,[0x251683] MOV ESI,0xc0f XOR R8D,R8D MOV R9D,0x10 CALL 0x00144330 CMP EAX,0x0 JNZ 0x001442d6 MOV EDI,dword ptr [RBP + -0x20] LEA RSI,[RBP + -0xc] MOV EAX,dword ptr [RBP + -0x1c] MOV ECX,EAX SUB RCX,0x4 MOV EDX,0x4 MOV R8D,0x14 CALL 0x001f4860 CMP RAX,0x0 JZ 0x001442df LAB_001442d6: MOV dword ptr [RBP + -0x10],0x1 JMP 0x001442fc LAB_001442df: MOV EAX,dword ptr [RBP + -0x1c] MOV ECX,EAX MOV RAX,qword ptr [RBP + -0x18] MOV qword ptr [RAX + 0x40],RCX MOV RDI,qword ptr [RBP + -0x18] CALL 0x00142430 MOV dword ptr [RBP + -0x10],0x0 LAB_001442fc: MOV EAX,dword ptr [RBP + -0x10] MOV dword ptr [RBP + -0x2c],EAX MOV RAX,qword ptr FS:[0x28] MOV RCX,qword ptr [RBP + -0x8] CMP RAX,RCX JNZ 0x0014431d MOV EAX,dword ptr [RBP + -0x2c] ADD RSP,0x30 POP RBP RET LAB_0014431d: CALL 0x0012a270
int4 _ma_bitmap_create_first(long param_1) { uint uVar1; int4 uVar2; int iVar3; long lVar4; long in_FS_OFFSET; int4 local_18; int4 local_14; long local_10; local_10 = *(long *)(in_FS_OFFSET + 0x28); uVar1 = *(uint *)(param_1 + 0xb44); uVar2 = *(int4 *)(param_1 + 0xa60); local_14 = 0xfffffffe; iVar3 = inline_mysql_file_chsize ("/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_bitmap.c",0xc0f, uVar2,(ulong)uVar1 - 4,0,0x10); if (iVar3 == 0) { lVar4 = my_pwrite(uVar2,&local_14,4,(ulong)uVar1 - 4,0x14); if (lVar4 == 0) { *(ulong *)(param_1 + 0x40) = (ulong)uVar1; _ma_bitmap_delete_all(param_1); local_18 = 0; goto LAB_001442fc; } } local_18 = 1; LAB_001442fc: if (*(long *)(in_FS_OFFSET + 0x28) == local_10) { return local_18; } /* WARNING: Subroutine does not return */ __stack_chk_fail(); }
47,454
sapphire_plugins::shared::ProcessorShim<sapphire_plugins::elastika::ElastikaClap>::pushFullUIRefresh()
sapphire-plugins/src/shared/processor_shim.h
void pushFullUIRefresh() { SPLLOG("Full UI Refresh Requested"); for (const auto *p : asProcessor()->patch.params) { shared::AudioToUIMsg au{shared::AudioToUIMsg::UPDATE_PARAM, p->meta.id, p->value}; audioToUi.push(au); } }
O3
c
sapphire_plugins::shared::ProcessorShim<sapphire_plugins::elastika::ElastikaClap>::pushFullUIRefresh(): pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x40, %rsp movq %rdi, %rbx leaq 0x10(%rsp), %r12 movq %r12, -0x10(%r12) leaq 0x2a8792(%rip), %rsi # 0x3a5bfd leaq 0x2a87d8(%rip), %rdx # 0x3a5c4a movq %rsp, %r14 movq %r14, %rdi callq 0x86440 leaq 0x4f9794(%rip), %r13 # 0x5f6c18 movq (%r13), %r15 movq %r15, %rdi callq 0x86b00 movq %r14, %rdi movq %r15, %rsi xorl %edx, %edx movq %rax, %rcx callq 0x869f0 cmpq $-0x1, %rax je 0xfd4cd movq %rax, %r14 movq (%r13), %rdi callq 0x86b00 leaq 0x1(%r14,%rax), %rdx leaq 0x20(%rsp), %rdi movq %rsp, %rsi movq $-0x1, %rcx callq 0x87e20 jmp 0xfd4ec leaq 0x30(%rsp), %rax movq %rax, -0x10(%rax) movq (%rsp), %rsi movq 0x8(%rsp), %rdx addq %rsi, %rdx leaq 0x20(%rsp), %rdi callq 0x860f0 movq 0x20(%rsp), %rsi movq 0x28(%rsp), %rdx movq 0x4f79f3(%rip), %rdi # 0x5f4ef0 callq 0x87d90 movq %rax, %r14 leaq 0x2daa0a(%rip), %rsi # 0x3d7f16 movl $0x1, %edx movq %rax, %rdi callq 0x87d90 movq %r14, %rdi movl $0x3d, %esi callq 0x86860 movq %rax, %r14 leaq 0x2b1b78(%rip), %rsi # 0x3af0a8 movl $0x1, %edx movq %rax, %rdi callq 0x87d90 leaq 0x2a8707(%rip), %rsi # 0x3a5c4b movl $0x19, %edx movq %r14, %rdi callq 0x87d90 movq (%r14), %rax movq -0x18(%rax), %rdi addq %r14, %rdi movl $0xa, %esi callq 0x87f80 movsbl %al, %esi movq %r14, %rdi callq 0x86f30 movq %rax, %rdi callq 0x86de0 leaq 0x30(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0xfd593 movq 0x30(%rsp), %rsi incq %rsi callq 0x86290 movq (%rsp), %rdi cmpq %r12, %rdi je 0xfd5a9 movq 0x10(%rsp), %rsi incq %rsi callq 0x86290 movq 0x100260(%rbx), %rax movq 0x100268(%rbx), %rcx cmpq %rcx, %rax je 0xfd601 leaq 0x1e8(%rbx), %rdx movq (%rax), %rsi movl 0x50(%rsi), %edi shlq $0x20, %rdi movss (%rsi), %xmm0 movq 0x1d8(%rbx), %rsi movq %rsi, %r8 shlq $0x4, %r8 movq %rdi, (%rdx,%r8) movlps %xmm0, 0x8(%rdx,%r8) incl %esi andl $0x3fff, %esi # imm = 0x3FFF movq %rsi, 0x1d8(%rbx) addq $0x8, %rax cmpq %rcx, %rax jne 0xfd5c3 addq $0x40, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 retq movq %rax, %rbx jmp 0xfd632 movq %rax, %rbx leaq 0x30(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0xfd632 movq 0x30(%rsp), %rsi incq %rsi callq 0x86290 movq (%rsp), %rdi cmpq %r12, %rdi je 0xfd648 movq 0x10(%rsp), %rsi incq %rsi callq 0x86290 movq %rbx, %rdi callq 0x871f0
_ZN16sapphire_plugins6shared13ProcessorShimINS_6galaxy10GalaxyClapEE17pushFullUIRefreshEv: push r15 push r14 push r13 push r12 push rbx sub rsp, 40h mov rbx, rdi lea r12, [rsp+68h+var_58] mov [r12-10h], r12 lea rsi, aWorkspaceLlm4b_1; "/workspace/llm4binary/github2025/sapphi"... lea rdx, aWorkspaceLlm4b_1+4Dh; "" mov r14, rsp mov rdi, r14 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) lea r13, _ZN3sst11plugininfra18VersionInformation16cmake_source_dirE; sst::plugininfra::VersionInformation::cmake_source_dir mov r15, [r13+0] mov rdi, r15 call _strlen mov rdi, r14 mov rsi, r15 xor edx, edx mov rcx, rax call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4findEPKcmm; std::string::find(char const*,ulong,ulong) cmp rax, 0FFFFFFFFFFFFFFFFh jz short loc_FD4CD mov r14, rax mov rdi, [r13+0] call _strlen lea rdx, [r14+rax+1] lea rdi, [rsp+68h+var_48] mov rsi, rsp mov rcx, 0FFFFFFFFFFFFFFFFh call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6substrEmm; std::string::substr(ulong,ulong) jmp short loc_FD4EC loc_FD4CD: lea rax, [rsp+68h+var_38] mov [rax-10h], rax mov rsi, [rsp+68h+var_68] mov rdx, [rsp+68h+var_60] add rdx, rsi lea rdi, [rsp+68h+var_48] call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIPcEEvT_S7_St20forward_iterator_tag; std::string::_M_construct<char *>(char *,char *,std::forward_iterator_tag) loc_FD4EC: mov rsi, [rsp+68h+var_48] mov rdx, [rsp+68h+var_40] mov rdi, cs:_ZSt4cout_ptr call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long) mov r14, rax lea rsi, aG_5+3; ":" mov edx, 1 mov rdi, rax call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long) mov rdi, r14 mov esi, 3Dh ; '=' call __ZNSolsEi; std::ostream::operator<<(int) mov r14, rax lea rsi, asc_3AF0A5+3; " " mov edx, 1 mov rdi, rax call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long) lea rsi, aFullUiRefreshR; "Full UI Refresh Requested" mov edx, 19h mov rdi, r14 call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long) mov rax, [r14] mov rdi, [rax-18h] add rdi, r14 mov esi, 0Ah call __ZNKSt9basic_iosIcSt11char_traitsIcEE5widenEc; std::ios::widen(char) movsx esi, al; char mov rdi, r14; this call __ZNSo3putEc; std::ostream::put(char) mov rdi, rax; this call __ZNSo5flushEv; std::ostream::flush(void) lea rax, [rsp+68h+var_38] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_FD593 mov rsi, [rsp+68h+var_38] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_FD593: mov rdi, [rsp+68h+var_68]; void * cmp rdi, r12 jz short loc_FD5A9 mov rsi, [rsp+68h+var_58] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_FD5A9: mov rax, [rbx+100260h] mov rcx, [rbx+100268h] cmp rax, rcx jz short loc_FD601 lea rdx, [rbx+1E8h] loc_FD5C3: mov rsi, [rax] mov edi, [rsi+50h] shl rdi, 20h movss xmm0, dword ptr [rsi] mov rsi, [rbx+1D8h] mov r8, rsi shl r8, 4 mov [rdx+r8], rdi movlps qword ptr [rdx+r8+8], xmm0 inc esi and esi, 3FFFh mov [rbx+1D8h], rsi add rax, 8 cmp rax, rcx jnz short loc_FD5C3 loc_FD601: add rsp, 40h pop rbx pop r12 pop r13 pop r14 pop r15 retn mov rbx, rax jmp short loc_FD632 mov rbx, rax lea rax, [rsp+arg_28] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_FD632 mov rsi, [rsp+arg_28] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_FD632: mov rdi, [rsp+0]; void * cmp rdi, r12 jz short loc_FD648 mov rsi, [rsp+arg_8] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_FD648: mov rdi, rbx call __Unwind_Resume
unsigned int ** sapphire_plugins::shared::ProcessorShim<sapphire_plugins::galaxy::GalaxyClap>::pushFullUIRefresh( _QWORD *a1) { char *v1; // r15 long long v2; // rax long long v3; // rax long long v4; // r14 long long v5; // rax long long v6; // r14 std::ostream *v7; // r14 char v8; // al std::ostream *v9; // rax unsigned int **result; // rax unsigned int **v11; // rcx _QWORD *v12; // rdx __m128 v13; // xmm0 long long v14; // rsi void *v15[2]; // [rsp+0h] [rbp-68h] BYREF _QWORD v16[2]; // [rsp+10h] [rbp-58h] BYREF void *v17[2]; // [rsp+20h] [rbp-48h] BYREF _QWORD v18[7]; // [rsp+30h] [rbp-38h] BYREF v15[0] = v16; std::string::_M_construct<char const*>( v15, "/workspace/llm4binary/github2025/sapphire-plugins/src/shared/processor_shim.h", ""); v1 = sst::plugininfra::VersionInformation::cmake_source_dir[0]; v2 = strlen(sst::plugininfra::VersionInformation::cmake_source_dir[0]); v3 = std::string::find(v15, v1, 0LL, v2); if ( v3 == -1 ) { v17[0] = v18; std::string::_M_construct<char *>(v17, v15[0], (char *)v15[0] + (unsigned long long)v15[1]); } else { v4 = v3; v5 = strlen(sst::plugininfra::VersionInformation::cmake_source_dir[0]); std::string::substr(v17, v15, v4 + v5 + 1, -1LL); } v6 = std::__ostream_insert<char,std::char_traits<char>>(&std::cout, v17[0], v17[1]); std::__ostream_insert<char,std::char_traits<char>>(v6, ":", 1LL); v7 = (std::ostream *)std::ostream::operator<<(v6, 61LL); std::__ostream_insert<char,std::char_traits<char>>(v7, " ", 1LL); std::__ostream_insert<char,std::char_traits<char>>(v7, "Full UI Refresh Requested", 25LL); v8 = std::ios::widen((char *)v7 + *(_QWORD *)(*(_QWORD *)v7 - 24LL), 10LL); v9 = (std::ostream *)std::ostream::put(v7, v8); std::ostream::flush(v9); if ( v17[0] != v18 ) operator delete(v17[0], v18[0] + 1LL); if ( v15[0] != v16 ) operator delete(v15[0], v16[0] + 1LL); result = (unsigned int **)a1[131148]; v11 = (unsigned int **)a1[131149]; if ( result != v11 ) { v12 = a1 + 61; do { v13 = (__m128)**result; v14 = a1[59]; v12[2 * v14] = (unsigned long long)(*result)[20] << 32; _mm_storel_ps((double *)&v12[2 * v14 + 1], v13); a1[59] = ((_WORD)v14 + 1) & 0x3FFF; ++result; } while ( result != v11 ); } return result; }
pushFullUIRefresh: PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x40 MOV RBX,RDI LEA R12,[RSP + 0x10] MOV qword ptr [R12 + -0x10],R12 LEA RSI,[0x4a5bfd] LEA RDX,[0x4a5c4a] MOV R14,RSP MOV RDI,R14 CALL 0x00186440 LEA R13,[0x6f6c18] MOV R15,qword ptr [R13] MOV RDI,R15 CALL 0x00186b00 MOV RDI,R14 MOV RSI,R15 XOR EDX,EDX MOV RCX,RAX CALL 0x001869f0 CMP RAX,-0x1 JZ 0x001fd4cd MOV R14,RAX MOV RDI,qword ptr [R13] CALL 0x00186b00 LEA RDX,[R14 + RAX*0x1 + 0x1] LAB_001fd4b7: LEA RDI,[RSP + 0x20] MOV RSI,RSP MOV RCX,-0x1 CALL 0x00187e20 JMP 0x001fd4ec LAB_001fd4cd: LEA RAX,[RSP + 0x30] MOV qword ptr [RAX + -0x10],RAX MOV RSI,qword ptr [RSP] MOV RDX,qword ptr [RSP + 0x8] ADD RDX,RSI LEA RDI,[RSP + 0x20] CALL 0x001860f0 LAB_001fd4ec: MOV RSI,qword ptr [RSP + 0x20] MOV RDX,qword ptr [RSP + 0x28] LAB_001fd4f6: MOV RDI,qword ptr [0x006f4ef0] CALL 0x00187d90 MOV R14,RAX LEA RSI,[0x4d7f16] MOV EDX,0x1 MOV RDI,RAX CALL 0x00187d90 MOV RDI,R14 MOV ESI,0x3d CALL 0x00186860 MOV R14,RAX LEA RSI,[0x4af0a8] MOV EDX,0x1 MOV RDI,RAX CALL 0x00187d90 LEA RSI,[0x4a5c4b] MOV EDX,0x19 MOV RDI,R14 CALL 0x00187d90 MOV RAX,qword ptr [R14] MOV RDI,qword ptr [RAX + -0x18] ADD RDI,R14 MOV ESI,0xa CALL 0x00187f80 MOVSX ESI,AL MOV RDI,R14 CALL 0x00186f30 MOV RDI,RAX CALL 0x00186de0 LAB_001fd578: LEA RAX,[RSP + 0x30] MOV RDI,qword ptr [RAX + -0x10] CMP RDI,RAX JZ 0x001fd593 MOV RSI,qword ptr [RSP + 0x30] INC RSI CALL 0x00186290 LAB_001fd593: MOV RDI,qword ptr [RSP] CMP RDI,R12 JZ 0x001fd5a9 MOV RSI,qword ptr [RSP + 0x10] INC RSI CALL 0x00186290 LAB_001fd5a9: MOV RAX,qword ptr [RBX + 0x100260] MOV RCX,qword ptr [RBX + 0x100268] CMP RAX,RCX JZ 0x001fd601 LEA RDX,[RBX + 0x1e8] LAB_001fd5c3: MOV RSI,qword ptr [RAX] MOV EDI,dword ptr [RSI + 0x50] SHL RDI,0x20 MOVSS XMM0,dword ptr [RSI] MOV RSI,qword ptr [RBX + 0x1d8] MOV R8,RSI SHL R8,0x4 MOV qword ptr [RDX + R8*0x1],RDI MOVLPS qword ptr [RDX + R8*0x1 + 0x8],XMM0 INC ESI AND ESI,0x3fff MOV qword ptr [RBX + 0x1d8],RSI ADD RAX,0x8 CMP RAX,RCX JNZ 0x001fd5c3 LAB_001fd601: ADD RSP,0x40 POP RBX POP R12 POP R13 POP R14 POP R15 RET
/* sapphire_plugins::shared::ProcessorShim<sapphire_plugins::galaxy::GalaxyClap>::pushFullUIRefresh() */ void __thiscall sapphire_plugins::shared::ProcessorShim<sapphire_plugins::galaxy::GalaxyClap>::pushFullUIRefresh (ProcessorShim<sapphire_plugins::galaxy::GalaxyClap> *this) { uint uVar1; int8 *puVar2; int *puVar3; long lVar4; ostream *poVar5; int8 *puVar6; long lVar7; long *local_68; long local_60; long local_58 [2]; long *local_48; long local_40; long local_38 [2]; local_68 = local_58; std::__cxx11::string::_M_construct<char_const*> (&local_68, "/workspace/llm4binary/github2025/sapphire-plugins/src/shared/processor_shim.h",""); puVar3 = sst::plugininfra::VersionInformation::cmake_source_dir; strlen(sst::plugininfra::VersionInformation::cmake_source_dir); lVar4 = std::__cxx11::string::find((char *)&local_68,(ulong)puVar3,0); if (lVar4 == -1) { local_48 = local_38; std::__cxx11::string::_M_construct<char*>(&local_48,local_68,local_60 + (long)local_68); } else { strlen(sst::plugininfra::VersionInformation::cmake_source_dir); /* try { // try from 001fd4b7 to 001fd4eb has its CatchHandler @ 001fd60f */ std::__cxx11::string::substr((ulong)&local_48,(ulong)&local_68); } /* try { // try from 001fd4f6 to 001fd577 has its CatchHandler @ 001fd614 */ poVar5 = std::__ostream_insert<char,std::char_traits<char>> ((ostream *)PTR_cout_006f4ef0,(char *)local_48,local_40); std::__ostream_insert<char,std::char_traits<char>>(poVar5,":",1); poVar5 = (ostream *)std::ostream::operator<<(poVar5,0x3d); std::__ostream_insert<char,std::char_traits<char>>(poVar5," ",1); std::__ostream_insert<char,std::char_traits<char>>(poVar5,"Full UI Refresh Requested",0x19); std::ios::widen((char)*(int8 *)(*(long *)poVar5 + -0x18) + (char)poVar5); std::ostream::put((char)poVar5); std::ostream::flush(); if (local_48 != local_38) { operator_delete(local_48,local_38[0] + 1); } if (local_68 != local_58) { operator_delete(local_68,local_58[0] + 1); } puVar2 = *(int8 **)(this + 0x100268); for (puVar6 = *(int8 **)(this + 0x100260); puVar6 != puVar2; puVar6 = puVar6 + 1) { uVar1 = *(uint *)*puVar6; lVar4 = *(long *)(this + 0x1d8); lVar7 = lVar4 * 0x10; *(ulong *)(this + lVar7 + 0x1e8) = (ulong)((uint *)*puVar6)[0x14] << 0x20; *(ulong *)(this + lVar7 + 0x1f0) = (ulong)uVar1; *(ulong *)(this + 0x1d8) = (ulong)((int)lVar4 + 1U & 0x3fff); } return; }
47,455
thr_lock_data_init
eloqsql/mysys/thr_lock.c
void thr_lock_data_init(THR_LOCK *lock,THR_LOCK_DATA *data, void *param) { data->lock=lock; data->type=TL_UNLOCK; data->owner= 0; /* no owner yet */ data->status_param=param; data->cond=0; data->priority= 0; data->debug_print_param= 0; }
O3
c
thr_lock_data_init: pushq %rbp movq %rsp, %rbp movq %rdi, 0x18(%rsi) xorl %eax, %eax movl %eax, 0x40(%rsi) movq %rax, (%rsi) movq %rdx, 0x28(%rsi) movq %rax, 0x20(%rsi) movl %eax, 0x48(%rsi) movq %rax, 0x30(%rsi) popq %rbp retq
thr_lock_data_init: push rbp mov rbp, rsp mov [rsi+18h], rdi xor eax, eax mov [rsi+40h], eax mov [rsi], rax mov [rsi+28h], rdx mov [rsi+20h], rax mov [rsi+48h], eax mov [rsi+30h], rax pop rbp retn
long long thr_lock_data_init(long long a1, long long a2, long long a3) { long long result; // rax *(_QWORD *)(a2 + 24) = a1; result = 0LL; *(_DWORD *)(a2 + 64) = 0; *(_QWORD *)a2 = 0LL; *(_QWORD *)(a2 + 40) = a3; *(_QWORD *)(a2 + 32) = 0LL; *(_DWORD *)(a2 + 72) = 0; *(_QWORD *)(a2 + 48) = 0LL; return result; }
thr_lock_data_init: PUSH RBP MOV RBP,RSP MOV qword ptr [RSI + 0x18],RDI XOR EAX,EAX MOV dword ptr [RSI + 0x40],EAX MOV qword ptr [RSI],RAX MOV qword ptr [RSI + 0x28],RDX MOV qword ptr [RSI + 0x20],RAX MOV dword ptr [RSI + 0x48],EAX MOV qword ptr [RSI + 0x30],RAX POP RBP RET
void thr_lock_data_init(int8 param_1,int8 *param_2,int8 param_3) { param_2[3] = param_1; *(int4 *)(param_2 + 8) = 0; *param_2 = 0; param_2[5] = param_3; param_2[4] = 0; *(int4 *)(param_2 + 9) = 0; param_2[6] = 0; return; }
47,456
js_build_arguments
bluesky950520[P]quickjs/quickjs.c
static JSValue js_build_arguments(JSContext *ctx, int argc, JSValue *argv) { JSValue val, *tab; JSProperty *pr; JSObject *p; int i; val = JS_NewObjectProtoClass(ctx, ctx->class_proto[JS_CLASS_OBJECT], JS_CLASS_ARGUMENTS); if (JS_IsException(val)) return val; p = JS_VALUE_GET_OBJ(val); /* add the length field (cannot fail) */ pr = add_property(ctx, p, JS_ATOM_length, JS_PROP_WRITABLE | JS_PROP_CONFIGURABLE); if (!pr) { JS_FreeValue(ctx, val); return JS_EXCEPTION; } pr->u.value = js_int32(argc); /* initialize the fast array part */ tab = NULL; if (argc > 0) { tab = js_malloc(ctx, sizeof(tab[0]) * argc); if (!tab) { JS_FreeValue(ctx, val); return JS_EXCEPTION; } for(i = 0; i < argc; i++) { tab[i] = js_dup(argv[i]); } } p->u.array.u.values = tab; p->u.array.count = argc; JS_DefinePropertyValue(ctx, val, JS_ATOM_Symbol_iterator, js_dup(ctx->array_proto_values), JS_PROP_CONFIGURABLE | JS_PROP_WRITABLE); /* add callee property to throw a TypeError in strict mode */ JS_DefineProperty(ctx, val, JS_ATOM_callee, JS_UNDEFINED, ctx->throw_type_error, ctx->throw_type_error, JS_PROP_HAS_GET | JS_PROP_HAS_SET); return val; }
O0
c
js_build_arguments: subq $0xe8, %rsp movq %rdi, 0xd0(%rsp) movl %esi, 0xcc(%rsp) movq %rdx, 0xc0(%rsp) movq 0xd0(%rsp), %rdi movq 0xd0(%rsp), %rax movq 0x40(%rax), %rax movq 0x10(%rax), %rsi movq 0x18(%rax), %rdx movl $0x8, %ecx callq 0x30190 movq %rax, 0x80(%rsp) movq %rdx, 0x88(%rsp) movq 0x80(%rsp), %rax movq %rax, 0xb0(%rsp) movq 0x88(%rsp), %rax movq %rax, 0xb8(%rsp) movq 0xb0(%rsp), %rdi movq 0xb8(%rsp), %rsi callq 0x29fb0 cmpl $0x0, %eax je 0x6a6c3 movq 0xb0(%rsp), %rax movq %rax, 0xd8(%rsp) movq 0xb8(%rsp), %rax movq %rax, 0xe0(%rsp) jmp 0x6a9b9 movq 0xb0(%rsp), %rax movq %rax, 0x98(%rsp) movq 0xd0(%rsp), %rdi movq 0x98(%rsp), %rsi movl $0x32, %edx movl $0x3, %ecx callq 0x64030 movq %rax, 0xa0(%rsp) cmpq $0x0, 0xa0(%rsp) jne 0x6a73e movq 0xd0(%rsp), %rdi movq 0xb0(%rsp), %rsi movq 0xb8(%rsp), %rdx callq 0x29f80 movl $0x0, 0xd8(%rsp) movq $0x6, 0xe0(%rsp) jmp 0x6a9b9 movq 0xa0(%rsp), %rax movq %rax, 0x38(%rsp) movl 0xcc(%rsp), %edi callq 0x39fb0 movq %rax, %rcx movq 0x38(%rsp), %rax movq %rcx, 0x70(%rsp) movq %rdx, 0x78(%rsp) movq 0x70(%rsp), %rcx movq %rcx, (%rax) movq 0x78(%rsp), %rcx movq %rcx, 0x8(%rax) movq $0x0, 0xa8(%rsp) cmpl $0x0, 0xcc(%rsp) jle 0x6a88e movq 0xd0(%rsp), %rdi movslq 0xcc(%rsp), %rsi shlq $0x4, %rsi callq 0x27fa0 movq %rax, 0xa8(%rsp) cmpq $0x0, 0xa8(%rsp) jne 0x6a7f9 movq 0xd0(%rsp), %rdi movq 0xb0(%rsp), %rsi movq 0xb8(%rsp), %rdx callq 0x29f80 movl $0x0, 0xd8(%rsp) movq $0x6, 0xe0(%rsp) jmp 0x6a9b9 movl $0x0, 0x94(%rsp) movl 0x94(%rsp), %eax cmpl 0xcc(%rsp), %eax jge 0x6a88c movq 0xa8(%rsp), %rax movslq 0x94(%rsp), %rcx shlq $0x4, %rcx addq %rcx, %rax movq %rax, 0x30(%rsp) movq 0xc0(%rsp), %rax movslq 0x94(%rsp), %rcx shlq $0x4, %rcx addq %rcx, %rax movq (%rax), %rdi movq 0x8(%rax), %rsi callq 0x279c0 movq %rax, %rcx movq 0x30(%rsp), %rax movq %rcx, 0x60(%rsp) movq %rdx, 0x68(%rsp) movq 0x60(%rsp), %rcx movq %rcx, (%rax) movq 0x68(%rsp), %rcx movq %rcx, 0x8(%rax) movl 0x94(%rsp), %eax addl $0x1, %eax movl %eax, 0x94(%rsp) jmp 0x6a804 jmp 0x6a88e movq 0xa8(%rsp), %rcx movq 0x98(%rsp), %rax movq %rcx, 0x38(%rax) movl 0xcc(%rsp), %ecx movq 0x98(%rsp), %rax movl %ecx, 0x40(%rax) movq 0xd0(%rsp), %rax movq %rax, 0x28(%rsp) movq 0xd0(%rsp), %rax movq 0x170(%rax), %rdi movq 0x178(%rax), %rsi callq 0x279c0 movq 0x28(%rsp), %rdi movq %rax, 0x50(%rsp) movq %rdx, 0x58(%rsp) movq 0xb0(%rsp), %rsi movq 0xb8(%rsp), %rdx movq 0x50(%rsp), %r8 movq 0x58(%rsp), %r9 movl $0xd4, %ecx movl $0x3, (%rsp) callq 0x3d4a0 movq 0xd0(%rsp), %rdi movl $0x0, 0x40(%rsp) movq $0x3, 0x48(%rsp) movq 0xd0(%rsp), %r10 addq $0x180, %r10 # imm = 0x180 movq 0xd0(%rsp), %rax addq $0x180, %rax # imm = 0x180 movq 0xb0(%rsp), %rsi movq 0xb8(%rsp), %rdx movq 0x40(%rsp), %r8 movq 0x48(%rsp), %r9 movl $0x4f, %ecx movq (%r10), %r11 movq %r11, (%rsp) movq 0x8(%r10), %r10 movq %r10, 0x8(%rsp) movq (%rax), %r10 movq %r10, 0x10(%rsp) movq 0x8(%rax), %rax movq %rax, 0x18(%rsp) movl $0x1800, 0x20(%rsp) # imm = 0x1800 callq 0x3a0d0 movq 0xb0(%rsp), %rax movq %rax, 0xd8(%rsp) movq 0xb8(%rsp), %rax movq %rax, 0xe0(%rsp) movq 0xd8(%rsp), %rax movq 0xe0(%rsp), %rdx addq $0xe8, %rsp retq nopw %cs:(%rax,%rax)
js_build_arguments: sub rsp, 0E8h mov [rsp+0E8h+var_18], rdi mov [rsp+0E8h+var_1C], esi mov [rsp+0E8h+var_28], rdx mov rdi, [rsp+0E8h+var_18] mov rax, [rsp+0E8h+var_18] mov rax, [rax+40h] mov rsi, [rax+10h] mov rdx, [rax+18h] mov ecx, 8 call JS_NewObjectProtoClass mov [rsp+0E8h+var_68], rax mov [rsp+0E8h+var_60], rdx mov rax, [rsp+0E8h+var_68] mov [rsp+0E8h+var_38], rax mov rax, [rsp+0E8h+var_60] mov [rsp+0E8h+var_30], rax mov rdi, [rsp+0E8h+var_38] mov rsi, [rsp+0E8h+var_30] call JS_IsException_1 cmp eax, 0 jz short loc_6A6C3 mov rax, [rsp+0E8h+var_38] mov [rsp+0E8h+var_10], rax mov rax, [rsp+0E8h+var_30] mov [rsp+0E8h+var_8], rax jmp loc_6A9B9 loc_6A6C3: mov rax, [rsp+0E8h+var_38] mov [rsp+0E8h+var_50], rax mov rdi, [rsp+0E8h+var_18] mov rsi, [rsp+0E8h+var_50] mov edx, 32h ; '2' mov ecx, 3 call add_property mov [rsp+0E8h+var_48], rax cmp [rsp+0E8h+var_48], 0 jnz short loc_6A73E mov rdi, [rsp+0E8h+var_18] mov rsi, [rsp+0E8h+var_38] mov rdx, [rsp+0E8h+var_30] call JS_FreeValue mov dword ptr [rsp+0E8h+var_10], 0 mov [rsp+0E8h+var_8], 6 jmp loc_6A9B9 loc_6A73E: mov rax, [rsp+0E8h+var_48] mov [rsp+0E8h+var_B0], rax mov edi, [rsp+0E8h+var_1C] call js_int32 mov rcx, rax mov rax, [rsp+0E8h+var_B0] mov [rsp+0E8h+var_78], rcx mov [rsp+0E8h+var_70], rdx mov rcx, [rsp+0E8h+var_78] mov [rax], rcx mov rcx, [rsp+0E8h+var_70] mov [rax+8], rcx mov [rsp+0E8h+var_40], 0 cmp [rsp+0E8h+var_1C], 0 jle loc_6A88E mov rdi, [rsp+0E8h+var_18] movsxd rsi, [rsp+0E8h+var_1C] shl rsi, 4 call js_malloc mov [rsp+0E8h+var_40], rax cmp [rsp+0E8h+var_40], 0 jnz short loc_6A7F9 mov rdi, [rsp+0E8h+var_18] mov rsi, [rsp+0E8h+var_38] mov rdx, [rsp+0E8h+var_30] call JS_FreeValue mov dword ptr [rsp+0E8h+var_10], 0 mov [rsp+0E8h+var_8], 6 jmp loc_6A9B9 loc_6A7F9: mov [rsp+0E8h+var_54], 0 loc_6A804: mov eax, [rsp+0E8h+var_54] cmp eax, [rsp+0E8h+var_1C] jge short loc_6A88C mov rax, [rsp+0E8h+var_40] movsxd rcx, [rsp+0E8h+var_54] shl rcx, 4 add rax, rcx mov [rsp+0E8h+var_B8], rax mov rax, [rsp+0E8h+var_28] movsxd rcx, [rsp+0E8h+var_54] shl rcx, 4 add rax, rcx mov rdi, [rax] mov rsi, [rax+8] call js_dup mov rcx, rax mov rax, [rsp+0E8h+var_B8] mov [rsp+0E8h+var_88], rcx mov [rsp+0E8h+var_80], rdx mov rcx, [rsp+0E8h+var_88] mov [rax], rcx mov rcx, [rsp+0E8h+var_80] mov [rax+8], rcx mov eax, [rsp+0E8h+var_54] add eax, 1 mov [rsp+0E8h+var_54], eax jmp loc_6A804 loc_6A88C: jmp short $+2 loc_6A88E: mov rcx, [rsp+0E8h+var_40] mov rax, [rsp+0E8h+var_50] mov [rax+38h], rcx mov ecx, [rsp+0E8h+var_1C] mov rax, [rsp+0E8h+var_50] mov [rax+40h], ecx mov rax, [rsp+0E8h+var_18] mov [rsp+0E8h+var_C0], rax mov rax, [rsp+0E8h+var_18] mov rdi, [rax+170h] mov rsi, [rax+178h] call js_dup mov rdi, [rsp+0E8h+var_C0] mov [rsp+0E8h+var_98], rax mov [rsp+0E8h+var_90], rdx mov rsi, [rsp+0E8h+var_38] mov rdx, [rsp+0E8h+var_30] mov r8, [rsp+0E8h+var_98] mov r9, [rsp+0E8h+var_90] mov ecx, 0D4h mov dword ptr [rsp+0E8h+var_E8], 3 call JS_DefinePropertyValue mov rdi, [rsp+0E8h+var_18] mov dword ptr [rsp+0E8h+var_A8], 0 mov [rsp+0E8h+var_A0], 3 mov r10, [rsp+0E8h+var_18] add r10, 180h mov rax, [rsp+0E8h+var_18] add rax, 180h mov rsi, [rsp+0E8h+var_38] mov rdx, [rsp+0E8h+var_30] mov r8, [rsp+0E8h+var_A8] mov r9, [rsp+0E8h+var_A0] mov ecx, 4Fh ; 'O' mov r11, [r10] mov [rsp+0E8h+var_E8], r11 mov r10, [r10+8] mov [rsp+0E8h+var_E0], r10 mov r10, [rax] mov [rsp+0E8h+var_D8], r10 mov rax, [rax+8] mov [rsp+0E8h+var_D0], rax mov [rsp+0E8h+var_C8], 1800h call JS_DefineProperty mov rax, [rsp+0E8h+var_38] mov [rsp+0E8h+var_10], rax mov rax, [rsp+0E8h+var_30] mov [rsp+0E8h+var_8], rax loc_6A9B9: mov rax, [rsp+0E8h+var_10] mov rdx, [rsp+0E8h+var_8] add rsp, 0E8h retn
long long js_build_arguments( long long a1, int a2, long long a3, __m128 a4, __m128 a5, __m128 a6, __m128 a7, double a8, double a9, __m128 a10, __m128 a11) { long long v11; // rdx long long v12; // rdx long long v13; // rdx long long v14; // rdx __m128 v15; // xmm4 __m128 v16; // xmm5 __m128 v17; // xmm4 __m128 v18; // xmm5 _QWORD *v20; // [rsp+30h] [rbp-B8h] _DWORD *v21; // [rsp+40h] [rbp-A8h] _DWORD *v22; // [rsp+50h] [rbp-98h] long long v23; // [rsp+80h] [rbp-68h] int i; // [rsp+94h] [rbp-54h] _QWORD *v25; // [rsp+A0h] [rbp-48h] long long v26; // [rsp+A8h] [rbp-40h] long long v27; // [rsp+B8h] [rbp-30h] long long v29; // [rsp+D8h] [rbp-10h] v23 = JS_NewObjectProtoClass( a1, *(_QWORD *)(*(_QWORD *)(a1 + 64) + 16LL), *(_QWORD *)(*(_QWORD *)(a1 + 64) + 24LL), 8u); v27 = v11; if ( !JS_IsException_1(v23, v11) ) { v25 = (_QWORD *)add_property(a1, v23, 0x32u, 3u); if ( !v25 ) { LABEL_4: JS_FreeValue(a1, v23, v27); LODWORD(v29) = 0; return v29; } *v25 = js_int32(a2); v25[1] = v12; v26 = 0LL; if ( a2 > 0 ) { v26 = js_malloc(a1, 16LL * a2); if ( !v26 ) goto LABEL_4; for ( i = 0; i < a2; ++i ) { v20 = (_QWORD *)(16LL * i + v26); *v20 = js_dup(*(_DWORD **)(16LL * i + a3), *(_QWORD *)(16LL * i + a3 + 8)); v20[1] = v13; } } *(_QWORD *)(v23 + 56) = v26; *(_DWORD *)(v23 + 64) = a2; v22 = js_dup(*(_DWORD **)(a1 + 368), *(_QWORD *)(a1 + 376)); JS_DefinePropertyValue(a1, v23, v27, 0xD4u, v22, v14, a4, a5, a6, a7, v15, v16, a10, a11, 3); LODWORD(v21) = 0; JS_DefineProperty( a1, v23, v27, 79LL, v21, 3LL, a4, a5, a6, a7, v17, v18, a10, a11, *(_DWORD **)(a1 + 384), *(_QWORD *)(a1 + 392), *(_DWORD **)(a1 + 384), *(_QWORD *)(a1 + 392), 0x1800u); return v23; } return v23; }
js_build_arguments: SUB RSP,0xe8 MOV qword ptr [RSP + 0xd0],RDI MOV dword ptr [RSP + 0xcc],ESI MOV qword ptr [RSP + 0xc0],RDX MOV RDI,qword ptr [RSP + 0xd0] MOV RAX,qword ptr [RSP + 0xd0] MOV RAX,qword ptr [RAX + 0x40] MOV RSI,qword ptr [RAX + 0x10] MOV RDX,qword ptr [RAX + 0x18] MOV ECX,0x8 CALL 0x00130190 MOV qword ptr [RSP + 0x80],RAX MOV qword ptr [RSP + 0x88],RDX MOV RAX,qword ptr [RSP + 0x80] MOV qword ptr [RSP + 0xb0],RAX MOV RAX,qword ptr [RSP + 0x88] MOV qword ptr [RSP + 0xb8],RAX MOV RDI,qword ptr [RSP + 0xb0] MOV RSI,qword ptr [RSP + 0xb8] CALL 0x00129fb0 CMP EAX,0x0 JZ 0x0016a6c3 MOV RAX,qword ptr [RSP + 0xb0] MOV qword ptr [RSP + 0xd8],RAX MOV RAX,qword ptr [RSP + 0xb8] MOV qword ptr [RSP + 0xe0],RAX JMP 0x0016a9b9 LAB_0016a6c3: MOV RAX,qword ptr [RSP + 0xb0] MOV qword ptr [RSP + 0x98],RAX MOV RDI,qword ptr [RSP + 0xd0] MOV RSI,qword ptr [RSP + 0x98] MOV EDX,0x32 MOV ECX,0x3 CALL 0x00164030 MOV qword ptr [RSP + 0xa0],RAX CMP qword ptr [RSP + 0xa0],0x0 JNZ 0x0016a73e MOV RDI,qword ptr [RSP + 0xd0] MOV RSI,qword ptr [RSP + 0xb0] MOV RDX,qword ptr [RSP + 0xb8] CALL 0x00129f80 MOV dword ptr [RSP + 0xd8],0x0 MOV qword ptr [RSP + 0xe0],0x6 JMP 0x0016a9b9 LAB_0016a73e: MOV RAX,qword ptr [RSP + 0xa0] MOV qword ptr [RSP + 0x38],RAX MOV EDI,dword ptr [RSP + 0xcc] CALL 0x00139fb0 MOV RCX,RAX MOV RAX,qword ptr [RSP + 0x38] MOV qword ptr [RSP + 0x70],RCX MOV qword ptr [RSP + 0x78],RDX MOV RCX,qword ptr [RSP + 0x70] MOV qword ptr [RAX],RCX MOV RCX,qword ptr [RSP + 0x78] MOV qword ptr [RAX + 0x8],RCX MOV qword ptr [RSP + 0xa8],0x0 CMP dword ptr [RSP + 0xcc],0x0 JLE 0x0016a88e MOV RDI,qword ptr [RSP + 0xd0] MOVSXD RSI,dword ptr [RSP + 0xcc] SHL RSI,0x4 CALL 0x00127fa0 MOV qword ptr [RSP + 0xa8],RAX CMP qword ptr [RSP + 0xa8],0x0 JNZ 0x0016a7f9 MOV RDI,qword ptr [RSP + 0xd0] MOV RSI,qword ptr [RSP + 0xb0] MOV RDX,qword ptr [RSP + 0xb8] CALL 0x00129f80 MOV dword ptr [RSP + 0xd8],0x0 MOV qword ptr [RSP + 0xe0],0x6 JMP 0x0016a9b9 LAB_0016a7f9: MOV dword ptr [RSP + 0x94],0x0 LAB_0016a804: MOV EAX,dword ptr [RSP + 0x94] CMP EAX,dword ptr [RSP + 0xcc] JGE 0x0016a88c MOV RAX,qword ptr [RSP + 0xa8] MOVSXD RCX,dword ptr [RSP + 0x94] SHL RCX,0x4 ADD RAX,RCX MOV qword ptr [RSP + 0x30],RAX MOV RAX,qword ptr [RSP + 0xc0] MOVSXD RCX,dword ptr [RSP + 0x94] SHL RCX,0x4 ADD RAX,RCX MOV RDI,qword ptr [RAX] MOV RSI,qword ptr [RAX + 0x8] CALL 0x001279c0 MOV RCX,RAX MOV RAX,qword ptr [RSP + 0x30] MOV qword ptr [RSP + 0x60],RCX MOV qword ptr [RSP + 0x68],RDX MOV RCX,qword ptr [RSP + 0x60] MOV qword ptr [RAX],RCX MOV RCX,qword ptr [RSP + 0x68] MOV qword ptr [RAX + 0x8],RCX MOV EAX,dword ptr [RSP + 0x94] ADD EAX,0x1 MOV dword ptr [RSP + 0x94],EAX JMP 0x0016a804 LAB_0016a88c: JMP 0x0016a88e LAB_0016a88e: MOV RCX,qword ptr [RSP + 0xa8] MOV RAX,qword ptr [RSP + 0x98] MOV qword ptr [RAX + 0x38],RCX MOV ECX,dword ptr [RSP + 0xcc] MOV RAX,qword ptr [RSP + 0x98] MOV dword ptr [RAX + 0x40],ECX MOV RAX,qword ptr [RSP + 0xd0] MOV qword ptr [RSP + 0x28],RAX MOV RAX,qword ptr [RSP + 0xd0] MOV RDI,qword ptr [RAX + 0x170] MOV RSI,qword ptr [RAX + 0x178] CALL 0x001279c0 MOV RDI,qword ptr [RSP + 0x28] MOV qword ptr [RSP + 0x50],RAX MOV qword ptr [RSP + 0x58],RDX MOV RSI,qword ptr [RSP + 0xb0] MOV RDX,qword ptr [RSP + 0xb8] MOV R8,qword ptr [RSP + 0x50] MOV R9,qword ptr [RSP + 0x58] MOV ECX,0xd4 MOV dword ptr [RSP],0x3 CALL 0x0013d4a0 MOV RDI,qword ptr [RSP + 0xd0] MOV dword ptr [RSP + 0x40],0x0 MOV qword ptr [RSP + 0x48],0x3 MOV R10,qword ptr [RSP + 0xd0] ADD R10,0x180 MOV RAX,qword ptr [RSP + 0xd0] ADD RAX,0x180 MOV RSI,qword ptr [RSP + 0xb0] MOV RDX,qword ptr [RSP + 0xb8] MOV R8,qword ptr [RSP + 0x40] MOV R9,qword ptr [RSP + 0x48] MOV ECX,0x4f MOV R11,qword ptr [R10] MOV qword ptr [RSP],R11 MOV R10,qword ptr [R10 + 0x8] MOV qword ptr [RSP + 0x8],R10 MOV R10,qword ptr [RAX] MOV qword ptr [RSP + 0x10],R10 MOV RAX,qword ptr [RAX + 0x8] MOV qword ptr [RSP + 0x18],RAX MOV dword ptr [RSP + 0x20],0x1800 CALL 0x0013a0d0 MOV RAX,qword ptr [RSP + 0xb0] MOV qword ptr [RSP + 0xd8],RAX MOV RAX,qword ptr [RSP + 0xb8] MOV qword ptr [RSP + 0xe0],RAX LAB_0016a9b9: MOV RAX,qword ptr [RSP + 0xd8] MOV RDX,qword ptr [RSP + 0xe0] ADD RSP,0xe8 RET
int1 [16] js_build_arguments(long param_1,int param_2,long param_3) { int4 uVar1; int iVar2; int1 (*pauVar4) [16]; int8 *puVar5; int1 auVar6 [16]; int8 in_stack_ffffffffffffff18; int4 uVar7; uint uStack_a4; int local_54; long local_40; int4 local_10; int4 uStack_c; int8 local_8; long lVar3; uVar1 = uStack_c; auVar6 = JS_NewObjectProtoClass (param_1,*(int8 *)(*(long *)(param_1 + 0x40) + 0x10), *(int8 *)(*(long *)(param_1 + 0x40) + 0x18),8); local_8 = auVar6._8_8_; lVar3 = auVar6._0_8_; iVar2 = JS_IsException(lVar3,local_8); local_10 = auVar6._0_4_; uStack_c = auVar6._4_4_; if (iVar2 == 0) { pauVar4 = (int1 (*) [16])add_property(param_1,lVar3,0x32,3); if (pauVar4 == (int1 (*) [16])0x0) { JS_FreeValue(param_1,lVar3,local_8); local_10 = 0; local_8 = 6; uStack_c = uVar1; } else { auVar6 = js_int32(param_2); uVar7 = (int4)((ulong)in_stack_ffffffffffffff18 >> 0x20); *pauVar4 = auVar6; local_40 = 0; if (0 < param_2) { local_40 = js_malloc(param_1,(long)param_2 << 4); if (local_40 == 0) { JS_FreeValue(param_1,lVar3,local_8); local_10 = 0; local_8 = 6; uStack_c = uVar1; goto LAB_0016a9b9; } for (local_54 = 0; uVar7 = (int4)((ulong)in_stack_ffffffffffffff18 >> 0x20), local_54 < param_2; local_54 = local_54 + 1) { puVar5 = (int8 *)(param_3 + (long)local_54 * 0x10); auVar6 = js_dup(*puVar5,puVar5[1]); *(int1 (*) [16])(local_40 + (long)local_54 * 0x10) = auVar6; } } *(long *)(lVar3 + 0x38) = local_40; *(int *)(lVar3 + 0x40) = param_2; auVar6 = js_dup(*(int8 *)(param_1 + 0x170),*(int8 *)(param_1 + 0x178)); JS_DefinePropertyValue(param_1,lVar3,local_8,0xd4,auVar6._0_8_,auVar6._8_8_,CONCAT44(uVar7,3)) ; JS_DefineProperty(param_1,lVar3,local_8,0x4f,(ulong)uStack_a4 << 0x20,3, *(int8 *)(param_1 + 0x180),*(int8 *)(param_1 + 0x188), *(int8 *)(param_1 + 0x180),*(int8 *)(param_1 + 0x188),0x1800); } } LAB_0016a9b9: auVar6._4_4_ = uStack_c; auVar6._0_4_ = local_10; auVar6._8_8_ = local_8; return auVar6; }
47,457
get_tensor(ggml_context*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&)
monkey531[P]llama/examples/llava/clip.cpp
static struct ggml_tensor * get_tensor(struct ggml_context * ctx, const std::string & name) { struct ggml_tensor * cur = ggml_get_tensor(ctx, name.c_str()); if (!cur) { throw std::runtime_error(format("%s: unable to find tensor %s\n", __func__, name.c_str())); } return cur; }
O3
cpp
get_tensor(ggml_context*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&): pushq %rbp pushq %r14 pushq %rbx subq $0x20, %rsp movq %rsi, %r14 movq (%rsi), %rsi callq 0x1b980 testq %rax, %rax je 0x25ecf addq $0x20, %rsp popq %rbx popq %r14 popq %rbp retq movl $0x10, %edi callq 0x1a7d0 movq %rax, %rbx movq (%r14), %rcx leaq 0x26579(%rip), %rsi # 0x4c45f leaq 0x26590(%rip), %rdx # 0x4c47d movq %rsp, %rdi xorl %eax, %eax callq 0x25ab1 movb $0x1, %bpl movq %rsp, %rsi movq %rbx, %rdi callq 0x1bf90 xorl %ebp, %ebp movq 0x340ea(%rip), %rsi # 0x59ff8 movq 0x33fbb(%rip), %rdx # 0x59ed0 movq %rbx, %rdi callq 0x1c200 movq %rax, %r14 leaq 0x10(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0x25f3b movq 0x10(%rsp), %rsi incq %rsi callq 0x1b320 testb %bpl, %bpl jne 0x25f45 jmp 0x25f4d movq %rax, %r14 movq %rbx, %rdi callq 0x1acb0 movq %r14, %rdi callq 0x1c320
_ZL10get_tensorP12ggml_contextRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE: push rbp push r14 push rbx sub rsp, 20h mov r14, rsi mov rsi, [rsi] call _ggml_get_tensor test rax, rax jz short loc_25ECF add rsp, 20h pop rbx pop r14 pop rbp retn loc_25ECF: mov edi, 10h; thrown_size call ___cxa_allocate_exception mov rbx, rax mov rcx, [r14] lea rsi, aSUnableToFindT; "%s: unable to find tensor %s\n" lea rdx, aGetTensor; "get_tensor" mov rdi, rsp xor eax, eax call _ZL6formatB5cxx11PKcz; format(char const*,...) mov bpl, 1 mov rsi, rsp mov rdi, rbx call __ZNSt13runtime_errorC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; std::runtime_error::runtime_error(std::string const&) xor ebp, ebp mov rsi, cs:lptinfo; lptinfo mov rdx, cs:_ZNSt13runtime_errorD1Ev_ptr; void (*)(void *) mov rdi, rbx; void * call ___cxa_throw mov r14, rax lea rax, [rsp+38h+var_28] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_25F3B mov rsi, [rsp+38h+var_28] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_25F3B: test bpl, bpl jnz short loc_25F45 jmp short loc_25F4D mov r14, rax loc_25F45: mov rdi, rbx; void * call ___cxa_free_exception loc_25F4D: mov rdi, r14 call __Unwind_Resume
long long get_tensor( long long a1, long long *a2, __m128 a3, __m128 a4, __m128 a5, __m128 a6, double a7, double a8, __m128 a9, __m128 a10) { long long result; // rax void *exception; // rbx long long v12; // r8 long long v13; // r9 __m128 v14; // xmm4 __m128 v15; // xmm5 _QWORD v16[2]; // [rsp+0h] [rbp-38h] BYREF result = ggml_get_tensor(a1, *a2); if ( !result ) { exception = __cxa_allocate_exception(0x10uLL); format[abi:cxx11]( v16, (long long)"%s: unable to find tensor %s\n", (long long)"get_tensor", *a2, v12, v13, a3, a4, a5, a6, v14, v15, a9, a10, v16[0]); std::runtime_error::runtime_error(exception, v16); __cxa_throw( exception, (struct type_info *)&`typeinfo for'std::runtime_error, (void (*)(void *))&std::runtime_error::~runtime_error); } return result; }
get_tensor: PUSH RBP PUSH R14 PUSH RBX SUB RSP,0x20 MOV R14,RSI MOV RSI,qword ptr [RSI] CALL 0x0011b980 TEST RAX,RAX JZ 0x00125ecf ADD RSP,0x20 POP RBX POP R14 POP RBP RET LAB_00125ecf: MOV EDI,0x10 CALL 0x0011a7d0 MOV RBX,RAX MOV RCX,qword ptr [R14] LAB_00125edf: LEA RSI,[0x14c45f] LEA RDX,[0x14c47d] MOV RDI,RSP XOR EAX,EAX CALL 0x00125ab1 MOV BPL,0x1 LAB_00125efa: MOV RSI,RSP MOV RDI,RBX CALL 0x0011bf90 XOR EBP,EBP MOV RSI,qword ptr [0x00159ff8] MOV RDX,qword ptr [0x00159ed0] MOV RDI,RBX CALL 0x0011c200
/* get_tensor(ggml_context*, std::__cxx11::string const&) */ void get_tensor(ggml_context *param_1,string *param_2) { long lVar1; runtime_error *this; string asStack_38 [32]; lVar1 = ggml_get_tensor(param_1,*(int8 *)param_2); if (lVar1 != 0) { return; } this = (runtime_error *)__cxa_allocate_exception(0x10); /* try { // try from 00125edf to 00125ef6 has its CatchHandler @ 00125f42 */ format_abi_cxx11_((char *)asStack_38,"%s: unable to find tensor %s\n","get_tensor", *(int8 *)param_2); /* try { // try from 00125efa to 00125f1c has its CatchHandler @ 00125f1d */ std::runtime_error::runtime_error(this,asStack_38); /* WARNING: Subroutine does not return */ __cxa_throw(this,PTR_typeinfo_00159ff8,PTR__runtime_error_00159ed0); }
47,458
ma_bitmap_lock
eloqsql/storage/maria/ma_bitmap.c
void _ma_bitmap_lock(MARIA_SHARE *share) { MARIA_FILE_BITMAP *bitmap= &share->bitmap; DBUG_ENTER("_ma_bitmap_lock"); if (!share->now_transactional) DBUG_VOID_RETURN; mysql_mutex_lock(&bitmap->bitmap_lock); bitmap->flush_all_requested++; bitmap->waiting_for_non_flushable++; while (bitmap->non_flushable) { DBUG_PRINT("info", ("waiting for bitmap to be flushable")); mysql_cond_wait(&bitmap->bitmap_cond, &bitmap->bitmap_lock); } bitmap->waiting_for_non_flushable--; /* Ensure that _ma_bitmap_flush_all() and _ma_bitmap_lock() are blocked. ma_bitmap_flushable() is blocked thanks to 'flush_all_requested'. */ bitmap->non_flushable= 1; mysql_mutex_unlock(&bitmap->bitmap_lock); DBUG_VOID_RETURN; }
O3
c
ma_bitmap_lock: cmpb $0x0, 0x7e7(%rdi) je 0x4008c pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r12 pushq %rbx movq %rdi, %r14 leaq 0xa98(%rdi), %rbx cmpq $0x0, 0xad8(%rdi) jne 0x4008d movq %rbx, %rdi callq 0x29220 incl 0xa40(%r14) movl 0xa4c(%r14), %eax leal 0x1(%rax), %ecx movl %ecx, 0xa4c(%r14) cmpl $0x0, 0xa48(%r14) je 0x4005e leaq 0xae0(%r14), %r15 leaq 0x997ec(%rip), %r12 # 0xd980b cmpq $0x0, 0xb10(%r14) jne 0x40040 movq %r15, %rdi movq %rbx, %rsi callq 0x29430 cmpl $0x0, 0xa48(%r14) jne 0x4001f jmp 0x40055 movq %r15, %rdi movq %rbx, %rsi movq %r12, %rdx movl $0x25c, %ecx # imm = 0x25C callq 0x2eea0 jmp 0x40034 movl 0xa4c(%r14), %eax decl %eax movl %eax, 0xa4c(%r14) movl $0x1, 0xa48(%r14) movq 0xad8(%r14), %rdi testq %rdi, %rdi jne 0x400a6 movq %rbx, %rdi popq %rbx popq %r12 popq %r14 popq %r15 popq %rbp jmp 0x291e0 retq leaq 0x99777(%rip), %rsi # 0xd980b movq %rbx, %rdi movl $0x256, %edx # imm = 0x256 callq 0x2eb8f jmp 0x3ffef leaq 0x345f63(%rip), %rax # 0x386010 movq (%rax), %rax callq *0x160(%rax) jmp 0x4007c
_ma_bitmap_lock: cmp byte ptr [rdi+7E7h], 0 jz locret_4008C push rbp mov rbp, rsp push r15 push r14 push r12 push rbx mov r14, rdi lea rbx, [rdi+0A98h] cmp qword ptr [rdi+0AD8h], 0 jnz loc_4008D mov rdi, rbx call _pthread_mutex_lock loc_3FFEF: inc dword ptr [r14+0A40h] mov eax, [r14+0A4Ch] lea ecx, [rax+1] loc_40000: mov [r14+0A4Ch], ecx cmp dword ptr [r14+0A48h], 0 jz short loc_4005E lea r15, [r14+0AE0h] lea r12, aWorkspaceLlm4b_2; "/workspace/llm4binary/github2025/eloqsq"... loc_4001F: cmp qword ptr [r14+0B10h], 0 jnz short loc_40040 mov rdi, r15 mov rsi, rbx call _pthread_cond_wait loc_40034: cmp dword ptr [r14+0A48h], 0 jnz short loc_4001F jmp short loc_40055 loc_40040: mov rdi, r15 mov rsi, rbx mov rdx, r12 mov ecx, 25Ch call psi_cond_wait jmp short loc_40034 loc_40055: mov eax, [r14+0A4Ch] dec eax loc_4005E: mov [r14+0A4Ch], eax mov dword ptr [r14+0A48h], 1 mov rdi, [r14+0AD8h] test rdi, rdi jnz short loc_400A6 loc_4007C: mov rdi, rbx pop rbx pop r12 pop r14 pop r15 pop rbp jmp _pthread_mutex_unlock locret_4008C: retn loc_4008D: lea rsi, aWorkspaceLlm4b_2; "/workspace/llm4binary/github2025/eloqsq"... mov rdi, rbx mov edx, 256h call psi_mutex_lock jmp loc_3FFEF loc_400A6: lea rax, PSI_server mov rax, [rax] call qword ptr [rax+160h] jmp short loc_4007C
void ma_bitmap_lock(long long a1) { long long v1; // rbx int v2; // eax if ( *(_BYTE *)(a1 + 2023) ) { v1 = a1 + 2712; if ( *(_QWORD *)(a1 + 2776) ) psi_mutex_lock(a1 + 2712, (long long)"/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_bitmap.c", 0x256u); else pthread_mutex_lock(a1 + 2712); ++*(_DWORD *)(a1 + 2624); v2 = *(_DWORD *)(a1 + 2636); *(_DWORD *)(a1 + 2636) = v2 + 1; if ( *(_DWORD *)(a1 + 2632) ) { do { if ( *(_QWORD *)(a1 + 2832) ) psi_cond_wait( a1 + 2784, v1, (long long)"/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_bitmap.c", 0x25Cu); else pthread_cond_wait(a1 + 2784, v1); } while ( *(_DWORD *)(a1 + 2632) ); v2 = *(_DWORD *)(a1 + 2636) - 1; } *(_DWORD *)(a1 + 2636) = v2; *(_DWORD *)(a1 + 2632) = 1; if ( *(_QWORD *)(a1 + 2776) ) PSI_server[44](); pthread_mutex_unlock(v1); } }
_ma_bitmap_lock: CMP byte ptr [RDI + 0x7e7],0x0 JZ 0x0014008c PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R12 PUSH RBX MOV R14,RDI LEA RBX,[RDI + 0xa98] CMP qword ptr [RDI + 0xad8],0x0 JNZ 0x0014008d MOV RDI,RBX CALL 0x00129220 LAB_0013ffef: INC dword ptr [R14 + 0xa40] MOV EAX,dword ptr [R14 + 0xa4c] LEA ECX,[RAX + 0x1] MOV dword ptr [R14 + 0xa4c],ECX CMP dword ptr [R14 + 0xa48],0x0 JZ 0x0014005e LEA R15,[R14 + 0xae0] LEA R12,[0x1d980b] LAB_0014001f: CMP qword ptr [R14 + 0xb10],0x0 JNZ 0x00140040 MOV RDI,R15 MOV RSI,RBX CALL 0x00129430 LAB_00140034: CMP dword ptr [R14 + 0xa48],0x0 JNZ 0x0014001f JMP 0x00140055 LAB_00140040: MOV RDI,R15 MOV RSI,RBX MOV RDX,R12 MOV ECX,0x25c CALL 0x0012eea0 JMP 0x00140034 LAB_00140055: MOV EAX,dword ptr [R14 + 0xa4c] DEC EAX LAB_0014005e: MOV dword ptr [R14 + 0xa4c],EAX MOV dword ptr [R14 + 0xa48],0x1 MOV RDI,qword ptr [R14 + 0xad8] TEST RDI,RDI JNZ 0x001400a6 LAB_0014007c: MOV RDI,RBX POP RBX POP R12 POP R14 POP R15 POP RBP JMP 0x001291e0 LAB_0014008c: RET LAB_0014008d: LEA RSI,[0x1d980b] MOV RDI,RBX MOV EDX,0x256 CALL 0x0012eb8f JMP 0x0013ffef LAB_001400a6: LEA RAX,[0x486010] MOV RAX,qword ptr [RAX] CALL qword ptr [RAX + 0x160] JMP 0x0014007c
void _ma_bitmap_lock(long param_1) { pthread_mutex_t *__mutex; int iVar1; if (*(char *)(param_1 + 0x7e7) != '\0') { __mutex = (pthread_mutex_t *)(param_1 + 0xa98); if (*(long *)(param_1 + 0xad8) == 0) { pthread_mutex_lock(__mutex); } else { psi_mutex_lock(__mutex,"/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_bitmap.c", 0x256); } *(int *)(param_1 + 0xa40) = *(int *)(param_1 + 0xa40) + 1; iVar1 = *(int *)(param_1 + 0xa4c); *(int *)(param_1 + 0xa4c) = iVar1 + 1; if (*(int *)(param_1 + 0xa48) != 0) { do { if (*(long *)(param_1 + 0xb10) == 0) { pthread_cond_wait((pthread_cond_t *)(param_1 + 0xae0),__mutex); } else { psi_cond_wait((pthread_cond_t *)(param_1 + 0xae0),__mutex, "/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_bitmap.c",0x25c); } } while (*(int *)(param_1 + 0xa48) != 0); iVar1 = *(int *)(param_1 + 0xa4c) + -1; } *(int *)(param_1 + 0xa4c) = iVar1; *(int4 *)(param_1 + 0xa48) = 1; if (*(long *)(param_1 + 0xad8) != 0) { (**(code **)(PSI_server + 0x160))(); } pthread_mutex_unlock(__mutex); return; } return; }
47,459
mysql_next_result_start_internal
eloqsql/libmariadb/libmariadb/mariadb_async.c
static void mysql_next_result_start_internal(void *d) { MK_ASYNC_INTERNAL_BODY( mysql_next_result, (parms->mysql), parms->mysql, int, r_int) }
O0
c
mysql_next_result_start_internal: pushq %rbp movq %rsp, %rbp subq $0x20, %rsp movq %rdi, -0x8(%rbp) movq -0x8(%rbp), %rax movq %rax, -0x10(%rbp) movq -0x10(%rbp), %rax movq (%rax), %rax movq 0x480(%rax), %rax movq 0x28(%rax), %rax movq %rax, -0x20(%rbp) movq -0x10(%rbp), %rax movq (%rax), %rdi callq 0x41190 movl %eax, -0x14(%rbp) movl -0x14(%rbp), %ecx movq -0x20(%rbp), %rax movl %ecx, 0x8(%rax) movq -0x20(%rbp), %rax movl $0x0, (%rax) addq $0x20, %rsp popq %rbp retq nopw %cs:(%rax,%rax)
mysql_next_result_start_internal: push rbp mov rbp, rsp sub rsp, 20h mov [rbp+var_8], rdi mov rax, [rbp+var_8] mov [rbp+var_10], rax mov rax, [rbp+var_10] mov rax, [rax] mov rax, [rax+480h] mov rax, [rax+28h] mov [rbp+var_20], rax mov rax, [rbp+var_10] mov rdi, [rax] call mysql_next_result mov [rbp+var_14], eax mov ecx, [rbp+var_14] mov rax, [rbp+var_20] mov [rax+8], ecx mov rax, [rbp+var_20] mov dword ptr [rax], 0 add rsp, 20h pop rbp retn
_DWORD * mysql_next_result_start_internal(long long *a1) { _DWORD *result; // rax _DWORD *v2; // [rsp+0h] [rbp-20h] v2 = *(_DWORD **)(*(_QWORD *)(*a1 + 1152) + 40LL); v2[2] = mysql_next_result(*a1); result = v2; *v2 = 0; return result; }
mysql_next_result_start_internal: PUSH RBP MOV RBP,RSP SUB RSP,0x20 MOV qword ptr [RBP + -0x8],RDI MOV RAX,qword ptr [RBP + -0x8] MOV qword ptr [RBP + -0x10],RAX MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX] MOV RAX,qword ptr [RAX + 0x480] MOV RAX,qword ptr [RAX + 0x28] MOV qword ptr [RBP + -0x20],RAX MOV RAX,qword ptr [RBP + -0x10] MOV RDI,qword ptr [RAX] CALL 0x00141190 MOV dword ptr [RBP + -0x14],EAX MOV ECX,dword ptr [RBP + -0x14] MOV RAX,qword ptr [RBP + -0x20] MOV dword ptr [RAX + 0x8],ECX MOV RAX,qword ptr [RBP + -0x20] MOV dword ptr [RAX],0x0 ADD RSP,0x20 POP RBP RET
void mysql_next_result_start_internal(long *param_1) { int4 *puVar1; int4 uVar2; puVar1 = *(int4 **)(*(long *)(*param_1 + 0x480) + 0x28); uVar2 = mysql_next_result(*param_1); puVar1[2] = uVar2; *puVar1 = 0; return; }
47,460
tree_walk_left_root_right
eloqsql/mysys/tree.c
static int tree_walk_left_root_right(TREE *tree, TREE_ELEMENT *element, tree_walk_action action, void *argument) { int error; if (element->left) /* Not null_element */ { if ((error=tree_walk_left_root_right(tree,element->left,action, argument)) == 0 && (error=(*action)(ELEMENT_KEY(tree,element), (element_count) element->count, argument)) == 0) error=tree_walk_left_root_right(tree,element->right,action,argument); return error; } return 0; }
O0
c
tree_walk_left_root_right: pushq %rbp movq %rsp, %rbp subq $0x40, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq %rdx, -0x20(%rbp) movq %rcx, -0x28(%rbp) movq -0x18(%rbp), %rax cmpq $0x0, (%rax) je 0xfb3a5 movq -0x10(%rbp), %rdi movq -0x18(%rbp), %rax movq (%rax), %rsi movq -0x20(%rbp), %rdx movq -0x28(%rbp), %rcx callq 0xfb2e0 movl %eax, -0x2c(%rbp) cmpl $0x0, %eax jne 0xfb39d movq -0x20(%rbp), %rax movq %rax, -0x38(%rbp) movq -0x10(%rbp), %rax cmpl $0x0, 0x208(%rax) je 0xfb352 movq -0x18(%rbp), %rax movq -0x10(%rbp), %rcx movl 0x208(%rcx), %ecx addq %rcx, %rax movq %rax, -0x40(%rbp) jmp 0xfb35e movq -0x18(%rbp), %rax movq 0x18(%rax), %rax movq %rax, -0x40(%rbp) movq -0x38(%rbp), %rax movq -0x40(%rbp), %rdi movq -0x18(%rbp), %rcx movl 0x10(%rcx), %esi andl $0x7fffffff, %esi # imm = 0x7FFFFFFF movq -0x28(%rbp), %rdx callq *%rax movl %eax, -0x2c(%rbp) cmpl $0x0, %eax jne 0xfb39d movq -0x10(%rbp), %rdi movq -0x18(%rbp), %rax movq 0x8(%rax), %rsi movq -0x20(%rbp), %rdx movq -0x28(%rbp), %rcx callq 0xfb2e0 movl %eax, -0x2c(%rbp) movl -0x2c(%rbp), %eax movl %eax, -0x4(%rbp) jmp 0xfb3ac movl $0x0, -0x4(%rbp) movl -0x4(%rbp), %eax addq $0x40, %rsp popq %rbp retq nopw %cs:(%rax,%rax)
tree_walk_left_root_right: push rbp mov rbp, rsp sub rsp, 40h mov [rbp+var_10], rdi mov [rbp+var_18], rsi mov [rbp+var_20], rdx mov [rbp+var_28], rcx mov rax, [rbp+var_18] cmp qword ptr [rax], 0 jz loc_FB3A5 mov rdi, [rbp+var_10] mov rax, [rbp+var_18] mov rsi, [rax] mov rdx, [rbp+var_20] mov rcx, [rbp+var_28] call tree_walk_left_root_right mov [rbp+var_2C], eax cmp eax, 0 jnz short loc_FB39D mov rax, [rbp+var_20] mov [rbp+var_38], rax mov rax, [rbp+var_10] cmp dword ptr [rax+208h], 0 jz short loc_FB352 mov rax, [rbp+var_18] mov rcx, [rbp+var_10] mov ecx, [rcx+208h] add rax, rcx mov [rbp+var_40], rax jmp short loc_FB35E loc_FB352: mov rax, [rbp+var_18] mov rax, [rax+18h] mov [rbp+var_40], rax loc_FB35E: mov rax, [rbp+var_38] mov rdi, [rbp+var_40] mov rcx, [rbp+var_18] mov esi, [rcx+10h] and esi, 7FFFFFFFh mov rdx, [rbp+var_28] call rax mov [rbp+var_2C], eax cmp eax, 0 jnz short loc_FB39D mov rdi, [rbp+var_10] mov rax, [rbp+var_18] mov rsi, [rax+8] mov rdx, [rbp+var_20] mov rcx, [rbp+var_28] call tree_walk_left_root_right mov [rbp+var_2C], eax loc_FB39D: mov eax, [rbp+var_2C] mov [rbp+var_4], eax jmp short loc_FB3AC loc_FB3A5: mov [rbp+var_4], 0 loc_FB3AC: mov eax, [rbp+var_4] add rsp, 40h pop rbp retn
long long tree_walk_left_root_right( long long a1, long long a2, long long ( *a3)(long long, _QWORD, long long), long long a4) { unsigned int v4; // eax unsigned int v6; // [rsp+14h] [rbp-2Ch] if ( *(_QWORD *)a2 ) { v6 = tree_walk_left_root_right(a1, *(_QWORD *)a2, a3, a4); if ( !v6 ) { if ( *(_DWORD *)(a1 + 520) ) v4 = a3(*(unsigned int *)(a1 + 520) + a2, *(_DWORD *)(a2 + 16) & 0x7FFFFFFF, a4); else v4 = a3(*(_QWORD *)(a2 + 24), *(_DWORD *)(a2 + 16) & 0x7FFFFFFF, a4); v6 = v4; if ( !v4 ) return (unsigned int)tree_walk_left_root_right(a1, *(_QWORD *)(a2 + 8), a3, a4); } return v6; } else { return 0; } }
tree_walk_left_root_right: 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 MOV qword ptr [RBP + -0x28],RCX MOV RAX,qword ptr [RBP + -0x18] CMP qword ptr [RAX],0x0 JZ 0x001fb3a5 MOV RDI,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RBP + -0x18] MOV RSI,qword ptr [RAX] MOV RDX,qword ptr [RBP + -0x20] MOV RCX,qword ptr [RBP + -0x28] CALL 0x001fb2e0 MOV dword ptr [RBP + -0x2c],EAX CMP EAX,0x0 JNZ 0x001fb39d MOV RAX,qword ptr [RBP + -0x20] MOV qword ptr [RBP + -0x38],RAX MOV RAX,qword ptr [RBP + -0x10] CMP dword ptr [RAX + 0x208],0x0 JZ 0x001fb352 MOV RAX,qword ptr [RBP + -0x18] MOV RCX,qword ptr [RBP + -0x10] MOV ECX,dword ptr [RCX + 0x208] ADD RAX,RCX MOV qword ptr [RBP + -0x40],RAX JMP 0x001fb35e LAB_001fb352: MOV RAX,qword ptr [RBP + -0x18] MOV RAX,qword ptr [RAX + 0x18] MOV qword ptr [RBP + -0x40],RAX LAB_001fb35e: MOV RAX,qword ptr [RBP + -0x38] MOV RDI,qword ptr [RBP + -0x40] MOV RCX,qword ptr [RBP + -0x18] MOV ESI,dword ptr [RCX + 0x10] AND ESI,0x7fffffff MOV RDX,qword ptr [RBP + -0x28] CALL RAX MOV dword ptr [RBP + -0x2c],EAX CMP EAX,0x0 JNZ 0x001fb39d MOV RDI,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RBP + -0x18] MOV RSI,qword ptr [RAX + 0x8] MOV RDX,qword ptr [RBP + -0x20] MOV RCX,qword ptr [RBP + -0x28] CALL 0x001fb2e0 MOV dword ptr [RBP + -0x2c],EAX LAB_001fb39d: MOV EAX,dword ptr [RBP + -0x2c] MOV dword ptr [RBP + -0x4],EAX JMP 0x001fb3ac LAB_001fb3a5: MOV dword ptr [RBP + -0x4],0x0 LAB_001fb3ac: MOV EAX,dword ptr [RBP + -0x4] ADD RSP,0x40 POP RBP RET
int tree_walk_left_root_right(long param_1,long *param_2,code *param_3,int8 param_4) { long local_48; int local_34; int local_c; if (*param_2 == 0) { local_c = 0; } else { local_34 = tree_walk_left_root_right(param_1,*param_2,param_3,param_4); if (local_34 == 0) { if (*(int *)(param_1 + 0x208) == 0) { local_48 = param_2[3]; } else { local_48 = (long)param_2 + (ulong)*(uint *)(param_1 + 0x208); } local_34 = (*param_3)(local_48,*(uint *)(param_2 + 2) & 0x7fffffff,param_4); if (local_34 == 0) { local_34 = tree_walk_left_root_right(param_1,param_2[1],param_3,param_4); } } local_c = local_34; } return local_c; }
47,461
tree_walk_left_root_right
eloqsql/mysys/tree.c
static int tree_walk_left_root_right(TREE *tree, TREE_ELEMENT *element, tree_walk_action action, void *argument) { int error; if (element->left) /* Not null_element */ { if ((error=tree_walk_left_root_right(tree,element->left,action, argument)) == 0 && (error=(*action)(ELEMENT_KEY(tree,element), (element_count) element->count, argument)) == 0) error=tree_walk_left_root_right(tree,element->right,action,argument); return error; } return 0; }
O3
c
tree_walk_left_root_right: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx pushq %rax movq %rsi, %r12 movq (%rsi), %rsi xorl %eax, %eax testq %rsi, %rsi je 0xa4c31 movq %rcx, %r14 movq %rdx, %r15 movq %rdi, %r13 movl $0x7fffffff, %ebx # imm = 0x7FFFFFFF movq %r13, %rdi movq %r15, %rdx movq %r14, %rcx callq 0xa4bbf testl %eax, %eax jne 0xa4c31 movl 0x208(%r13), %edi testq %rdi, %rdi je 0xa4c0b addq %r12, %rdi jmp 0xa4c10 movq 0x18(%r12), %rdi movl 0x10(%r12), %esi andl %ebx, %esi movq %r14, %rdx callq *%r15 testl %eax, %eax jne 0xa4c31 movq 0x8(%r12), %r12 movq (%r12), %rsi testq %rsi, %rsi jne 0xa4be8 xorl %eax, %eax addq $0x8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
tree_walk_left_root_right: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx push rax mov r12, rsi mov rsi, [rsi] xor eax, eax test rsi, rsi jz short loc_A4C31 mov r14, rcx mov r15, rdx mov r13, rdi mov ebx, 7FFFFFFFh loc_A4BE8: mov rdi, r13 mov rdx, r15 mov rcx, r14 call tree_walk_left_root_right test eax, eax jnz short loc_A4C31 mov edi, [r13+208h] test rdi, rdi jz short loc_A4C0B add rdi, r12 jmp short loc_A4C10 loc_A4C0B: mov rdi, [r12+18h] loc_A4C10: mov esi, [r12+10h] and esi, ebx mov rdx, r14 call r15 test eax, eax jnz short loc_A4C31 mov r12, [r12+8] mov rsi, [r12] test rsi, rsi jnz short loc_A4BE8 xor eax, eax loc_A4C31: add rsp, 8 pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
long long tree_walk_left_root_right( long long a1, long long *a2, long long ( *a3)(long long *, long long, long long), long long a4) { long long *v4; // r12 long long v5; // rsi long long result; // rax long long *v10; // rdi v4 = a2; v5 = *a2; result = 0LL; if ( v5 ) { while ( 1 ) { result = tree_walk_left_root_right(a1, v5, a3, a4); if ( (_DWORD)result ) break; v10 = *(_DWORD *)(a1 + 520) ? (long long *)((char *)v4 + *(unsigned int *)(a1 + 520)) : (long long *)v4[3]; result = a3(v10, v4[2] & 0x7FFFFFFF, a4); if ( (_DWORD)result ) break; v4 = (long long *)v4[1]; v5 = *v4; if ( !*v4 ) return 0LL; } } return result; }
tree_walk_left_root_right: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX PUSH RAX MOV R12,RSI MOV RSI,qword ptr [RSI] XOR EAX,EAX TEST RSI,RSI JZ 0x001a4c31 MOV R14,RCX MOV R15,RDX MOV R13,RDI MOV EBX,0x7fffffff LAB_001a4be8: MOV RDI,R13 MOV RDX,R15 MOV RCX,R14 CALL 0x001a4bbf TEST EAX,EAX JNZ 0x001a4c31 MOV EDI,dword ptr [R13 + 0x208] TEST RDI,RDI JZ 0x001a4c0b ADD RDI,R12 JMP 0x001a4c10 LAB_001a4c0b: MOV RDI,qword ptr [R12 + 0x18] LAB_001a4c10: MOV ESI,dword ptr [R12 + 0x10] AND ESI,EBX MOV RDX,R14 CALL R15 TEST EAX,EAX JNZ 0x001a4c31 MOV R12,qword ptr [R12 + 0x8] MOV RSI,qword ptr [R12] TEST RSI,RSI JNZ 0x001a4be8 XOR EAX,EAX LAB_001a4c31: ADD RSP,0x8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
int8 tree_walk_left_root_right(long param_1,long *param_2,code *param_3,int8 param_4) { int8 uVar1; long lVar2; lVar2 = *param_2; while( true ) { if (lVar2 == 0) { return 0; } uVar1 = tree_walk_left_root_right(param_1,lVar2,param_3,param_4); if ((int)uVar1 != 0) break; if ((ulong)*(uint *)(param_1 + 0x208) == 0) { lVar2 = param_2[3]; } else { lVar2 = (ulong)*(uint *)(param_1 + 0x208) + (long)param_2; } uVar1 = (*param_3)(lVar2,*(uint *)(param_2 + 2) & 0x7fffffff,param_4); if ((int)uVar1 != 0) { return uVar1; } param_2 = (long *)param_2[1]; lVar2 = *param_2; } return uVar1; }
47,462
common_log::pause()
monkey531[P]llama/common/log.cpp
void pause() { { std::lock_guard<std::mutex> lock(mtx); if (!running) { return; } running = false; // push an entry to signal the worker thread to stop { auto & entry = entries[tail]; entry.is_end = true; tail = (tail + 1) % entries.size(); } cv.notify_one(); } thrd.join(); }
O2
cpp
common_log::pause(): pushq %rbx movq %rdi, %rbx callq 0x96902 cmpb $0x1, 0x6a(%rbx) jne 0x96112 movb $0x0, 0x6a(%rbx) movq 0x78(%rbx), %rdx movq 0x98(%rbx), %rcx imulq $0x30, %rcx, %rax movb $0x1, 0x28(%rdx,%rax) incq %rcx movq 0x80(%rbx), %rax subq %rdx, %rax pushq $0x30 popq %rsi cqto idivq %rsi movq %rax, %rsi movq %rcx, %rax xorl %edx, %edx divq %rsi movq %rdx, 0x98(%rbx) leaq 0x30(%rbx), %rdi callq 0x23470 movq %rbx, %rdi callq 0x236f0 addq $0x28, %rbx movq %rbx, %rdi popq %rbx jmp 0x23f10 movq %rbx, %rdi popq %rbx jmp 0x236f0 nop
_ZN10common_log5pauseEv: push rbx mov rbx, rdi call _ZNSt5mutex4lockEv; std::mutex::lock(void) cmp byte ptr [rbx+6Ah], 1 jnz short loc_96112 mov byte ptr [rbx+6Ah], 0 mov rdx, [rbx+78h] mov rcx, [rbx+98h] imul rax, rcx, 30h ; '0' mov byte ptr [rdx+rax+28h], 1 inc rcx mov rax, [rbx+80h] sub rax, rdx push 30h ; '0' pop rsi cqo idiv rsi mov rsi, rax mov rax, rcx xor edx, edx div rsi mov [rbx+98h], rdx lea rdi, [rbx+30h]; this call __ZNSt18condition_variable10notify_oneEv; std::condition_variable::notify_one(void) mov rdi, rbx call _pthread_mutex_unlock add rbx, 28h ; '(' mov rdi, rbx; this pop rbx jmp __ZNSt6thread4joinEv; std::thread::join(void) loc_96112: mov rdi, rbx pop rbx jmp _pthread_mutex_unlock
long long common_log::pause(common_log *this) { long long v1; // rdx long long v2; // rcx std::mutex::lock(this); if ( *((_BYTE *)this + 106) != 1 ) return pthread_mutex_unlock(this); *((_BYTE *)this + 106) = 0; v1 = *((_QWORD *)this + 15); v2 = *((_QWORD *)this + 19); *(_BYTE *)(v1 + 48 * v2 + 40) = 1; *((_QWORD *)this + 19) = (v2 + 1) % (unsigned long long)((*((_QWORD *)this + 16) - v1) / 48); std::condition_variable::notify_one((common_log *)((char *)this + 48)); pthread_mutex_unlock(this); return std::thread::join((common_log *)((char *)this + 40)); }
pause: PUSH RBX MOV RBX,RDI CALL 0x00196902 CMP byte ptr [RBX + 0x6a],0x1 JNZ 0x00196112 MOV byte ptr [RBX + 0x6a],0x0 MOV RDX,qword ptr [RBX + 0x78] MOV RCX,qword ptr [RBX + 0x98] IMUL RAX,RCX,0x30 MOV byte ptr [RDX + RAX*0x1 + 0x28],0x1 INC RCX MOV RAX,qword ptr [RBX + 0x80] SUB RAX,RDX PUSH 0x30 POP RSI CQO IDIV RSI MOV RSI,RAX MOV RAX,RCX XOR EDX,EDX DIV RSI MOV qword ptr [RBX + 0x98],RDX LEA RDI,[RBX + 0x30] CALL 0x00123470 MOV RDI,RBX CALL 0x001236f0 ADD RBX,0x28 MOV RDI,RBX POP RBX JMP 0x00123f10 LAB_00196112: MOV RDI,RBX POP RBX JMP 0x001236f0
/* common_log::pause() */ void __thiscall common_log::pause(common_log *this) { long lVar1; long lVar2; std::mutex::lock((mutex *)this); if (this[0x6a] == (common_log)0x1) { this[0x6a] = (common_log)0x0; lVar1 = *(long *)(this + 0x78); lVar2 = *(long *)(this + 0x98); *(int1 *)(lVar1 + 0x28 + lVar2 * 0x30) = 1; *(ulong *)(this + 0x98) = (lVar2 + 1U) % (ulong)((*(long *)(this + 0x80) - lVar1) / 0x30); std::condition_variable::notify_one(); pthread_mutex_unlock((pthread_mutex_t *)this); std::thread::join(); return; } pthread_mutex_unlock((pthread_mutex_t *)this); return; }
47,463
nglog::GetTempDirectories(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>>>>&)
ng-log[P]ng-log/src/logging.cc
static void GetTempDirectories(vector<string>& list) { list.clear(); #ifdef NGLOG_OS_WINDOWS // On windows we'll try to find a directory in this order: // C:/Documents & Settings/whomever/TEMP (or whatever GetTempPath() is) // C:/TMP/ // C:/TEMP/ char tmp[MAX_PATH]; if (GetTempPathA(MAX_PATH, tmp)) list.push_back(tmp); list.push_back("C:\\TMP\\"); list.push_back("C:\\TEMP\\"); #else // Directories, in order of preference. If we find a dir that // exists, we stop adding other less-preferred dirs const char* candidates[] = { // Non-null only during unittest/regtest getenv("TEST_TMPDIR"), // Explicitly-supplied temp dirs getenv("TMPDIR"), getenv("TMP"), // If all else fails "/tmp", }; for (auto d : candidates) { if (!d) continue; // Empty env var // Make sure we don't surprise anyone who's expecting a '/' string dstr = d; if (dstr[dstr.size() - 1] != '/') { dstr += "/"; } list.push_back(dstr); struct stat statbuf; if (!stat(d, &statbuf) && S_ISDIR(statbuf.st_mode)) { // We found a dir that exists - we're done. return; } } #endif }
O3
cpp
nglog::GetTempDirectories(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>>>>&): pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0xd8, %rsp movq %rdi, %rbx movq (%rdi), %rsi callq 0x1fc9c leaq 0x15a92(%rip), %rdi # 0x236a2 callq 0x76a0 movq %rax, %r13 movq %rax, 0x20(%rsp) leaq 0x15a83(%rip), %rdi # 0x236a7 callq 0x76a0 movq %rax, 0x28(%rsp) leaq 0x16c34(%rip), %rdi # 0x24869 callq 0x76a0 movq %rax, 0x30(%rsp) leaq 0x16c27(%rip), %rax # 0x2486d movq %rax, 0x38(%rsp) leaq 0x10(%rsp), %rbp xorl %r12d, %r12d movq %rsp, %r14 leaq 0x48(%rsp), %r15 testq %r13, %r13 je 0xdcf8 movq %rbp, (%rsp) movq %r13, %rdi callq 0x71f0 leaq (%rax,%r13), %rdx movq %r14, %rdi movq %r13, %rsi callq 0xa448 movq (%rsp), %rax movq 0x8(%rsp), %rcx cmpb $0x2f, -0x1(%rax,%rcx) je 0xdc9e movq %r14, %rdi leaq 0x15d48(%rip), %rsi # 0x239e1 callq 0x7a40 movq %rbx, %rdi movq %r14, %rsi callq 0x1209e movq %r13, %rdi movq %r15, %rsi callq 0x7470 testl %eax, %eax jne 0xdccd movl 0x60(%rsp), %eax movl $0xf000, %ecx # imm = 0xF000 andl %ecx, %eax movb $0x1, %r13b cmpl $0x4000, %eax # imm = 0x4000 je 0xdcd0 xorl %r13d, %r13d movq (%rsp), %rdi cmpq %rbp, %rdi je 0xdce6 movq 0x10(%rsp), %rsi incq %rsi callq 0x8efc addq $0x8, %r12 cmpq $0x20, %r12 sete %al orb %al, %r13b je 0xdd02 jmp 0xdd0c addq $0x8, %r12 cmpq $0x20, %r12 je 0xdd0c movq 0x20(%rsp,%r12), %r13 jmp 0xdc5b addq $0xd8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq movq %rax, %rbx movq (%rsp), %rdi cmpq %rbp, %rdi je 0xdd37 movq 0x10(%rsp), %rsi incq %rsi callq 0x8efc movq %rbx, %rdi callq 0x79b0
_ZN5nglogL18GetTempDirectoriesERSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS6_EE: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 0D8h mov rbx, rdi mov rsi, [rdi] call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE15_M_erase_at_endEPS5_; std::vector<std::string>::_M_erase_at_end(std::string*) lea rdi, aTestTmpdir; "TEST_TMPDIR" call _getenv mov r13, rax mov [rsp+108h+var_E8], rax lea rdi, aTestTmpdir+5; "TMPDIR" call _getenv mov [rsp+108h+var_E0], rax lea rdi, aTmp_0; "TMP" call _getenv mov [rsp+108h+var_D8], rax lea rax, aTmp; "/tmp" mov [rsp+108h+var_D0], rax lea rbp, [rsp+108h+var_F8] xor r12d, r12d mov r14, rsp lea r15, [rsp+108h+var_C0] loc_DC5B: test r13, r13 jz loc_DCF8 mov [rsp+108h+var_108], rbp mov rdi, r13 call _strlen lea rdx, [rax+r13] mov rdi, r14 mov rsi, r13 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) mov rax, [rsp+108h+var_108] mov rcx, [rsp+108h+var_100] cmp byte ptr [rax+rcx-1], 2Fh ; '/' jz short loc_DC9E mov rdi, r14 lea rsi, asc_239E0+1; "/" call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendEPKc; std::string::append(char const*) loc_DC9E: mov rdi, rbx mov rsi, r14 call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE9push_backERKS5_; std::vector<std::string>::push_back(std::string const&) mov rdi, r13 mov rsi, r15 call _stat test eax, eax jnz short loc_DCCD mov eax, [rsp+108h+var_A8] mov ecx, 0F000h and eax, ecx mov r13b, 1 cmp eax, 4000h jz short loc_DCD0 loc_DCCD: xor r13d, r13d loc_DCD0: mov rdi, [rsp+108h+var_108]; void * cmp rdi, rbp jz short loc_DCE6 mov rsi, [rsp+108h+var_F8] inc rsi; unsigned __int64 call _ZdlPvm; operator delete(void *,ulong) loc_DCE6: add r12, 8 cmp r12, 20h ; ' ' setz al or r13b, al jz short loc_DD02 jmp short loc_DD0C loc_DCF8: add r12, 8 cmp r12, 20h ; ' ' jz short loc_DD0C loc_DD02: mov r13, [rsp+r12+108h+var_E8] jmp loc_DC5B loc_DD0C: add rsp, 0D8h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn mov rbx, rax mov rdi, [rsp+0]; void * cmp rdi, rbp jz short loc_DD37 mov rsi, [rsp+arg_8] inc rsi; unsigned __int64 call _ZdlPvm; operator delete(void *,ulong) loc_DD37: mov rdi, rbx call __Unwind_Resume
char nglog::GetTempDirectories(_QWORD *a1) { _BYTE *v1; // r13 const char *v2; // rax long long v3; // r12 long long v4; // rax char v5; // r13 void *v7[2]; // [rsp+0h] [rbp-108h] BYREF _QWORD v8[2]; // [rsp+10h] [rbp-F8h] BYREF _QWORD v9[5]; // [rsp+20h] [rbp-E8h] _BYTE v10[24]; // [rsp+48h] [rbp-C0h] BYREF int v11; // [rsp+60h] [rbp-A8h] std::vector<std::string>::_M_erase_at_end(a1, *a1); v1 = (_BYTE *)getenv("TEST_TMPDIR"); v9[0] = v1; v9[1] = getenv("TMPDIR"); v9[2] = getenv("TMP"); v2 = "/tmp"; v9[3] = "/tmp"; v3 = 0LL; while ( !v1 ) { if ( ++v3 == 4 ) return (char)v2; LABEL_13: v1 = (_BYTE *)v9[v3]; } v7[0] = v8; v4 = strlen(v1); std::string::_M_construct<char const*>((long long)v7, v1, (long long)&v1[v4]); if ( *((_BYTE *)v7[0] + (unsigned long long)v7[1] - 1) != 47 ) std::string::append(v7, "/"); std::vector<std::string>::push_back(a1); if ( (unsigned int)stat(v1, v10) || (v5 = 1, (v11 & 0xF000) != 0x4000) ) v5 = 0; if ( v7[0] != v8 ) operator delete(v7[0]); LOBYTE(v2) = ++v3 == 4; if ( !((v3 == 4) | (unsigned __int8)v5) ) goto LABEL_13; return (char)v2; }
GetTempDirectories: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0xd8 MOV RBX,RDI MOV RSI,qword ptr [RDI] CALL 0x0011fc9c LEA RDI,[0x1236a2] CALL 0x001076a0 MOV R13,RAX MOV qword ptr [RSP + 0x20],RAX LEA RDI,[0x1236a7] CALL 0x001076a0 MOV qword ptr [RSP + 0x28],RAX LEA RDI,[0x124869] CALL 0x001076a0 MOV qword ptr [RSP + 0x30],RAX LEA RAX,[0x12486d] MOV qword ptr [RSP + 0x38],RAX LEA RBP,[RSP + 0x10] XOR R12D,R12D MOV R14,RSP LEA R15,[RSP + 0x48] LAB_0010dc5b: TEST R13,R13 JZ 0x0010dcf8 MOV qword ptr [RSP],RBP MOV RDI,R13 CALL 0x001071f0 LEA RDX,[RAX + R13*0x1] MOV RDI,R14 MOV RSI,R13 CALL 0x0010a448 MOV RAX,qword ptr [RSP] MOV RCX,qword ptr [RSP + 0x8] CMP byte ptr [RAX + RCX*0x1 + -0x1],0x2f JZ 0x0010dc9e LAB_0010dc8f: MOV RDI,R14 LEA RSI,[0x1239e1] CALL 0x00107a40 LAB_0010dc9e: MOV RDI,RBX MOV RSI,R14 CALL 0x0011209e LAB_0010dca9: MOV RDI,R13 MOV RSI,R15 CALL 0x00107470 TEST EAX,EAX JNZ 0x0010dccd MOV EAX,dword ptr [RSP + 0x60] MOV ECX,0xf000 AND EAX,ECX MOV R13B,0x1 CMP EAX,0x4000 JZ 0x0010dcd0 LAB_0010dccd: XOR R13D,R13D LAB_0010dcd0: MOV RDI,qword ptr [RSP] CMP RDI,RBP JZ 0x0010dce6 MOV RSI,qword ptr [RSP + 0x10] INC RSI CALL 0x00108efc LAB_0010dce6: ADD R12,0x8 CMP R12,0x20 SETZ AL OR R13B,AL JZ 0x0010dd02 JMP 0x0010dd0c LAB_0010dcf8: ADD R12,0x8 CMP R12,0x20 JZ 0x0010dd0c LAB_0010dd02: MOV R13,qword ptr [RSP + R12*0x1 + 0x20] JMP 0x0010dc5b LAB_0010dd0c: ADD RSP,0xd8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
/* nglog::GetTempDirectories(std::vector<std::__cxx11::string, std::allocator<std::__cxx11::string > >&) */ void nglog::GetTempDirectories(vector *param_1) { bool bVar1; int iVar2; char *__s; size_t sVar3; long lVar4; long *local_108; long local_100; long local_f8 [2]; char *local_e8; char *local_e0 [4]; stat local_c0; std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::_M_erase_at_end ((vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *)param_1, *(string **)param_1); __s = getenv("TEST_TMPDIR"); local_e8 = __s; local_e0[0] = getenv("TMPDIR"); local_e0[1] = getenv("TMP"); local_e0[2] = "/tmp"; lVar4 = 0; do { if (__s == (char *)0x0) { if (lVar4 == 0x18) { return; } } else { local_108 = local_f8; sVar3 = strlen(__s); std::__cxx11::string::_M_construct<char_const*>(&local_108,__s,__s + sVar3); if (*(char *)((long)local_108 + local_100 + -1) != '/') { /* try { // try from 0010dc8f to 0010dca8 has its CatchHandler @ 0010dd1e */ std::__cxx11::string::append((char *)&local_108); } std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::push_back ((vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *)param_1, (string *)&local_108); iVar2 = stat(__s,&local_c0); if ((iVar2 != 0) || (bVar1 = true, (local_c0.st_mode & 0xf000) != 0x4000)) { bVar1 = false; } if (local_108 != local_f8) { operator_delete(local_108,local_f8[0] + 1); } if (bVar1 || lVar4 == 0x18) { return; } } __s = *(char **)((long)local_e0 + lVar4); lVar4 = lVar4 + 8; } while( true ); }
47,464
my_fstat
eloqsql/mysys/my_lib.c
int my_fstat(File Filedes, MY_STAT *stat_area, myf MyFlags __attribute__((unused))) { DBUG_ENTER("my_fstat"); DBUG_PRINT("my",("fd: %d MyFlags: %lu", Filedes, MyFlags)); #ifdef _WIN32 DBUG_RETURN(my_win_fstat(Filedes, stat_area)); #elif defined HAVE_valgrind { int s= fstat(Filedes, stat_area); if (!s) MSAN_STAT_WORKAROUND(stat_area); DBUG_RETURN(s); } #else DBUG_RETURN(fstat(Filedes, (struct stat *) stat_area)); #endif }
O3
c
my_fstat: pushq %rbp movq %rsp, %rbp popq %rbp jmp 0x33620 nopl (%rax)
my_fstat: push rbp mov rbp, rsp pop rbp jmp _fstat64
long long my_fstat() { return fstat64(); }
my_fstat: PUSH RBP MOV RBP,RSP POP RBP JMP 0x00133620
void my_fstat(int param_1,stat64 *param_2) { fstat64(param_1,param_2); return; }
47,465
free_rw_handler
bluesky950520[P]quickjs/quickjs-libc.c
static void free_rw_handler(JSRuntime *rt, JSOSRWHandler *rh) { int i; list_del(&rh->link); for(i = 0; i < 2; i++) { JS_FreeValueRT(rt, rh->rw_func[i]); } js_free_rt(rt, rh); }
O2
c
free_rw_handler: pushq %r15 pushq %r14 pushq %rbx movq %rsi, %rbx movq %rdi, %r14 movq (%rsi), %rax movq 0x8(%rsi), %rcx movq %rcx, 0x8(%rax) movq %rax, (%rcx) xorps %xmm0, %xmm0 movups %xmm0, (%rsi) pushq $0x20 popq %r15 cmpq $0x40, %r15 je 0x13e86 movq -0x8(%rbx,%r15), %rsi movq (%rbx,%r15), %rdx movq %r14, %rdi callq 0x1bbe1 addq $0x10, %r15 jmp 0x13e69 movq %r14, %rdi movq %rbx, %rsi popq %rbx popq %r14 popq %r15 jmp 0x1ac7b
free_rw_handler: push r15 push r14 push rbx mov rbx, rsi mov r14, rdi mov rax, [rsi] mov rcx, [rsi+8] mov [rax+8], rcx mov [rcx], rax xorps xmm0, xmm0 movups xmmword ptr [rsi], xmm0 push 20h ; ' ' pop r15 loc_13E69: cmp r15, 40h ; '@' jz short loc_13E86 mov rsi, [rbx+r15-8] mov rdx, [rbx+r15] mov rdi, r14 call JS_FreeValueRT add r15, 10h jmp short loc_13E69 loc_13E86: mov rdi, r14 mov rsi, rbx pop rbx pop r14 pop r15 jmp js_free_rt
long long free_rw_handler(long long a1, long long *a2) { long long v2; // rax _QWORD *v3; // rcx long long i; // r15 v2 = *a2; v3 = (_QWORD *)a2[1]; *(_QWORD *)(v2 + 8) = v3; *v3 = v2; *(_OWORD *)a2 = 0LL; for ( i = 4LL; i != 8; i += 2LL ) JS_FreeValueRT(a1, a2[i - 1], a2[i]); return js_free_rt(a1, a2); }
free_rw_handler: PUSH R15 PUSH R14 PUSH RBX MOV RBX,RSI MOV R14,RDI MOV RAX,qword ptr [RSI] MOV RCX,qword ptr [RSI + 0x8] MOV qword ptr [RAX + 0x8],RCX MOV qword ptr [RCX],RAX XORPS XMM0,XMM0 MOVUPS xmmword ptr [RSI],XMM0 PUSH 0x20 POP R15 LAB_00113e69: CMP R15,0x40 JZ 0x00113e86 MOV RSI,qword ptr [RBX + R15*0x1 + -0x8] MOV RDX,qword ptr [RBX + R15*0x1] MOV RDI,R14 CALL 0x0011bbe1 ADD R15,0x10 JMP 0x00113e69 LAB_00113e86: MOV RDI,R14 MOV RSI,RBX POP RBX POP R14 POP R15 JMP 0x0011ac7b
void free_rw_handler(int8 param_1,long *param_2) { long *plVar1; long lVar2; lVar2 = *param_2; plVar1 = (long *)param_2[1]; *(long **)(lVar2 + 8) = plVar1; *plVar1 = lVar2; *param_2 = 0; param_2[1] = 0; for (lVar2 = 0x20; lVar2 != 0x40; lVar2 = lVar2 + 0x10) { JS_FreeValueRT(param_1,*(int8 *)((long)param_2 + lVar2 + -8), *(int8 *)((long)param_2 + lVar2)); } js_free_rt(param_1,param_2); return; }
47,466
mi_find_writepos
eloqsql/storage/myisam/mi_dynrec.c
static int _mi_find_writepos(MI_INFO *info, ulong reclength, /* record length */ my_off_t *filepos, /* Return file pos */ ulong *length) /* length of block at filepos */ { MI_BLOCK_INFO block_info; ulong tmp; DBUG_ENTER("_mi_find_writepos"); if (info->s->state.dellink != HA_OFFSET_ERROR && !info->append_insert_at_end) { /* Deleted blocks exists; Get last used block */ *filepos=info->s->state.dellink; block_info.second_read=0; info->rec_cache.seek_not_done=1; if (!(_mi_get_block_info(&block_info,info->dfile,info->s->state.dellink) & BLOCK_DELETED)) { DBUG_PRINT("error",("Delete link crashed")); my_errno=HA_ERR_WRONG_IN_RECORD; DBUG_RETURN(-1); } info->s->state.dellink=block_info.next_filepos; info->state->del--; info->state->empty-= block_info.block_len; *length= block_info.block_len; } else { /* No deleted blocks; Allocate a new block */ *filepos=info->state->data_file_length; if ((tmp= reclength + 3 + MY_TEST(reclength >= (65520 - 3))) < info->s->base.min_block_length) tmp= info->s->base.min_block_length; else tmp= ((tmp+MI_DYN_ALIGN_SIZE-1) & (~ (ulong) (MI_DYN_ALIGN_SIZE-1))); if (info->state->data_file_length > (info->s->base.max_data_file_length - tmp)) { my_errno=HA_ERR_RECORD_FILE_FULL; DBUG_RETURN(-1); } if (tmp > MI_MAX_BLOCK_LENGTH) tmp=MI_MAX_BLOCK_LENGTH; *length= tmp; info->state->data_file_length+= tmp; info->s->state.split++; info->update|=HA_STATE_WRITE_AT_END; } DBUG_RETURN(0); }
O3
c
mi_find_writepos: pushq %rbp movq %rsp, %rbp pushq %r14 pushq %rbx subq $0x60, %rsp movq %rcx, %rbx movq %rdi, %r14 movq %fs:0x28, %rax movq %rax, -0x18(%rbp) movq (%rdi), %rax movq 0x58(%rax), %rax cmpq $-0x1, %rax je 0x797ca cmpb $0x0, 0x33a(%r14) je 0x79846 movq 0x8(%r14), %rax movq 0x28(%rax), %rax movq %rax, (%rdx) cmpq $0xffed, %rsi # imm = 0xFFED sbbq $-0x1, %rsi leaq 0x3(%rsi), %rax movq (%r14), %rcx movq 0x8(%r14), %rdx movq 0x160(%rcx), %rdi addq $0x6, %rsi andq $-0x4, %rsi cmpq %rdi, %rax cmovbq %rdi, %rsi movq 0x110(%rcx), %rax subq %rsi, %rax cmpq %rax, 0x28(%rdx) jbe 0x7981e callq 0xa13e6 movl $0x87, (%rax) jmp 0x79881 movl $0xfffffc, %eax # imm = 0xFFFFFC cmpq %rax, %rsi cmovbq %rsi, %rax movq %rax, (%rbx) movq 0x8(%r14), %rcx addq %rax, 0x28(%rcx) movq (%r14), %rax incq 0x50(%rax) orb $0x1, 0x1d1(%r14) jmp 0x798ae movq %rax, (%rdx) leaq -0x70(%rbp), %rdi movl $0x0, 0x50(%rdi) movl $0x1, 0x300(%r14) movl 0x1c0(%r14), %esi movq (%r14), %rax movq 0x58(%rax), %rdx callq 0x77d43 testb $0x4, %al jne 0x79888 callq 0xa13e6 movl $0x7f, (%rax) movl $0xffffffff, %eax # imm = 0xFFFFFFFF jmp 0x798b0 movq -0x30(%rbp), %rax movq (%r14), %rcx movq %rax, 0x58(%rcx) movq 0x8(%r14), %rax decq 0x8(%rax) movq -0x48(%rbp), %rax movq 0x8(%r14), %rcx subq %rax, 0x10(%rcx) movq -0x48(%rbp), %rax movq %rax, (%rbx) xorl %eax, %eax movq %fs:0x28, %rcx cmpq -0x18(%rbp), %rcx jne 0x798c8 addq $0x60, %rsp popq %rbx popq %r14 popq %rbp retq callq 0x29260 nopl (%rax)
_mi_find_writepos: push rbp mov rbp, rsp push r14 push rbx sub rsp, 60h mov rbx, rcx mov r14, rdi mov rax, fs:28h mov [rbp+var_18], rax mov rax, [rdi] mov rax, [rax+58h] cmp rax, 0FFFFFFFFFFFFFFFFh jz short loc_797CA cmp byte ptr [r14+33Ah], 0 jz short loc_79846 loc_797CA: mov rax, [r14+8] mov rax, [rax+28h] mov [rdx], rax cmp rsi, 0FFEDh sbb rsi, 0FFFFFFFFFFFFFFFFh lea rax, [rsi+3] mov rcx, [r14] mov rdx, [r14+8] mov rdi, [rcx+160h] add rsi, 6 and rsi, 0FFFFFFFFFFFFFFFCh cmp rax, rdi cmovb rsi, rdi mov rax, [rcx+110h] sub rax, rsi cmp [rdx+28h], rax jbe short loc_7981E call _my_thread_var mov dword ptr [rax], 87h jmp short loc_79881 loc_7981E: mov eax, 0FFFFFCh cmp rsi, rax cmovb rax, rsi mov [rbx], rax mov rcx, [r14+8] add [rcx+28h], rax mov rax, [r14] inc qword ptr [rax+50h] or byte ptr [r14+1D1h], 1 jmp short loc_798AE loc_79846: mov [rdx], rax lea rdi, [rbp+var_70] mov dword ptr [rdi+50h], 0 mov dword ptr [r14+300h], 1 mov esi, [r14+1C0h] mov rax, [r14] mov rdx, [rax+58h] call _mi_get_block_info test al, 4 jnz short loc_79888 call _my_thread_var mov dword ptr [rax], 7Fh loc_79881: mov eax, 0FFFFFFFFh jmp short loc_798B0 loc_79888: mov rax, [rbp+var_30] mov rcx, [r14] mov [rcx+58h], rax mov rax, [r14+8] dec qword ptr [rax+8] mov rax, [rbp+var_48] mov rcx, [r14+8] sub [rcx+10h], rax mov rax, [rbp+var_48] mov [rbx], rax loc_798AE: xor eax, eax loc_798B0: mov rcx, fs:28h cmp rcx, [rbp+var_18] jnz short loc_798C8 add rsp, 60h pop rbx pop r14 pop rbp retn loc_798C8: call ___stack_chk_fail
long long mi_find_writepos(_QWORD *a1, unsigned long long a2, _QWORD *a3, long long *a4) { long long v6; // rax unsigned long long v7; // rsi unsigned long long v8; // rax long long v9; // rcx long long v10; // rdx unsigned long long v11; // rdi unsigned long long v12; // rsi long long v13; // rax _BYTE v15[40]; // [rsp+0h] [rbp-70h] BYREF long long v16; // [rsp+28h] [rbp-48h] long long v17; // [rsp+40h] [rbp-30h] int v18; // [rsp+50h] [rbp-20h] unsigned long long v19; // [rsp+58h] [rbp-18h] v19 = __readfsqword(0x28u); v6 = *(_QWORD *)(*a1 + 88LL); if ( v6 == -1 || *((_BYTE *)a1 + 826) ) { *a3 = *(_QWORD *)(a1[1] + 40LL); v7 = a2 - ((a2 < 0xFFED) - 1LL); v8 = v7 + 3; v9 = *a1; v10 = a1[1]; v11 = *(_QWORD *)(*a1 + 352LL); v12 = (v7 + 6) & 0xFFFFFFFFFFFFFFFCLL; if ( v8 < v11 ) v12 = *(_QWORD *)(*a1 + 352LL); if ( *(_QWORD *)(v10 + 40) > *(_QWORD *)(v9 + 272) - v12 ) { *(_DWORD *)my_thread_var(v11) = 135; return 0xFFFFFFFFLL; } v13 = 16777212LL; if ( v12 < 0xFFFFFC ) v13 = v12; *a4 = v13; *(_QWORD *)(a1[1] + 40LL) += v13; ++*(_QWORD *)(*a1 + 80LL); *((_BYTE *)a1 + 465) |= 1u; } else { *a3 = v6; v18 = 0; *((_DWORD *)a1 + 192) = 1; if ( (mi_get_block_info((long long)v15, *((unsigned int *)a1 + 112), *(_QWORD *)(*a1 + 88LL)) & 4) == 0 ) { *(_DWORD *)my_thread_var(v15) = 127; return 0xFFFFFFFFLL; } *(_QWORD *)(*a1 + 88LL) = v17; --*(_QWORD *)(a1[1] + 8LL); *(_QWORD *)(a1[1] + 16LL) -= v16; *a4 = v16; } return 0LL; }
_mi_find_writepos: PUSH RBP MOV RBP,RSP PUSH R14 PUSH RBX SUB RSP,0x60 MOV RBX,RCX MOV R14,RDI MOV RAX,qword ptr FS:[0x28] MOV qword ptr [RBP + -0x18],RAX MOV RAX,qword ptr [RDI] MOV RAX,qword ptr [RAX + 0x58] CMP RAX,-0x1 JZ 0x001797ca CMP byte ptr [R14 + 0x33a],0x0 JZ 0x00179846 LAB_001797ca: MOV RAX,qword ptr [R14 + 0x8] MOV RAX,qword ptr [RAX + 0x28] MOV qword ptr [RDX],RAX CMP RSI,0xffed SBB RSI,-0x1 LEA RAX,[RSI + 0x3] MOV RCX,qword ptr [R14] MOV RDX,qword ptr [R14 + 0x8] MOV RDI,qword ptr [RCX + 0x160] ADD RSI,0x6 AND RSI,-0x4 CMP RAX,RDI CMOVC RSI,RDI MOV RAX,qword ptr [RCX + 0x110] SUB RAX,RSI CMP qword ptr [RDX + 0x28],RAX JBE 0x0017981e CALL 0x001a13e6 MOV dword ptr [RAX],0x87 JMP 0x00179881 LAB_0017981e: MOV EAX,0xfffffc CMP RSI,RAX CMOVC RAX,RSI MOV qword ptr [RBX],RAX MOV RCX,qword ptr [R14 + 0x8] ADD qword ptr [RCX + 0x28],RAX MOV RAX,qword ptr [R14] INC qword ptr [RAX + 0x50] OR byte ptr [R14 + 0x1d1],0x1 JMP 0x001798ae LAB_00179846: MOV qword ptr [RDX],RAX LEA RDI,[RBP + -0x70] MOV dword ptr [RDI + 0x50],0x0 MOV dword ptr [R14 + 0x300],0x1 MOV ESI,dword ptr [R14 + 0x1c0] MOV RAX,qword ptr [R14] MOV RDX,qword ptr [RAX + 0x58] CALL 0x00177d43 TEST AL,0x4 JNZ 0x00179888 CALL 0x001a13e6 MOV dword ptr [RAX],0x7f LAB_00179881: MOV EAX,0xffffffff JMP 0x001798b0 LAB_00179888: MOV RAX,qword ptr [RBP + -0x30] MOV RCX,qword ptr [R14] MOV qword ptr [RCX + 0x58],RAX MOV RAX,qword ptr [R14 + 0x8] DEC qword ptr [RAX + 0x8] MOV RAX,qword ptr [RBP + -0x48] MOV RCX,qword ptr [R14 + 0x8] SUB qword ptr [RCX + 0x10],RAX MOV RAX,qword ptr [RBP + -0x48] MOV qword ptr [RBX],RAX LAB_001798ae: XOR EAX,EAX LAB_001798b0: MOV RCX,qword ptr FS:[0x28] CMP RCX,qword ptr [RBP + -0x18] JNZ 0x001798c8 ADD RSP,0x60 POP RBX POP R14 POP RBP RET LAB_001798c8: CALL 0x00129260
int8 _mi_find_writepos(long *param_1,ulong param_2,long *param_3,ulong *param_4) { int4 *puVar1; ulong uVar2; int8 uVar3; long lVar4; ulong uVar5; long in_FS_OFFSET; int1 local_78 [40]; ulong local_50; int8 local_38; int4 local_28; long local_20; local_20 = *(long *)(in_FS_OFFSET + 0x28); if ((*(long *)(*param_1 + 0x58) == -1) || (*(char *)((long)param_1 + 0x33a) != '\0')) { *param_3 = *(long *)(param_1[1] + 0x28); lVar4 = (param_2 + 1) - (ulong)(param_2 < 0xffed); uVar2 = *(ulong *)(*param_1 + 0x160); uVar5 = lVar4 + 6U & 0xfffffffffffffffc; if (lVar4 + 3U < uVar2) { uVar5 = uVar2; } if (*(ulong *)(param_1[1] + 0x28) <= *(long *)(*param_1 + 0x110) - uVar5) { uVar2 = 0xfffffc; if (uVar5 < 0xfffffc) { uVar2 = uVar5; } *param_4 = uVar2; *(long *)(param_1[1] + 0x28) = *(long *)(param_1[1] + 0x28) + uVar2; *(long *)(*param_1 + 0x50) = *(long *)(*param_1 + 0x50) + 1; *(byte *)((long)param_1 + 0x1d1) = *(byte *)((long)param_1 + 0x1d1) | 1; LAB_001798ae: uVar3 = 0; goto LAB_001798b0; } puVar1 = (int4 *)_my_thread_var(); *puVar1 = 0x87; } else { *param_3 = *(long *)(*param_1 + 0x58); local_28 = 0; *(int4 *)(param_1 + 0x60) = 1; uVar2 = _mi_get_block_info(local_78,(int)param_1[0x38],*(int8 *)(*param_1 + 0x58)); if ((uVar2 & 4) != 0) { *(int8 *)(*param_1 + 0x58) = local_38; *(long *)(param_1[1] + 8) = *(long *)(param_1[1] + 8) + -1; *(long *)(param_1[1] + 0x10) = *(long *)(param_1[1] + 0x10) - local_50; *param_4 = local_50; goto LAB_001798ae; } puVar1 = (int4 *)_my_thread_var(); *puVar1 = 0x7f; } uVar3 = 0xffffffff; LAB_001798b0: if (*(long *)(in_FS_OFFSET + 0x28) == local_20) { return uVar3; } /* WARNING: Subroutine does not return */ __stack_chk_fail(); }
47,467
set_prealloc_root
eloqsql/mysys/my_alloc.c
void set_prealloc_root(MEM_ROOT *root, char *ptr) { USED_MEM *next; for (next=root->used; next ; next=next->next) { if ((char*) next <= ptr && (char*) next + next->size > ptr) { root->pre_alloc=next; return; } } for (next=root->free ; next ; next=next->next) { if ((char*) next <= ptr && (char*) next + next->size > ptr) { root->pre_alloc=next; return; } } }
O3
c
set_prealloc_root: pushq %rbp movq %rsp, %rbp movq 0x8(%rdi), %rax testq %rax, %rax je 0x9fcf6 cmpq %rsi, %rax ja 0x9fcf1 movq 0x10(%rax), %rcx addq %rax, %rcx cmpq %rsi, %rcx ja 0x9fd14 movq (%rax), %rax jmp 0x9fcdb movq (%rdi), %rax testq %rax, %rax je 0x9fd18 cmpq %rsi, %rax ja 0x9fd0f movq 0x10(%rax), %rcx addq %rax, %rcx cmpq %rsi, %rcx ja 0x9fd14 movq (%rax), %rax jmp 0x9fcf9 movq %rax, 0x10(%rdi) popq %rbp retq
set_prealloc_root: push rbp mov rbp, rsp mov rax, [rdi+8] loc_9FCDB: test rax, rax jz short loc_9FCF6 cmp rax, rsi ja short loc_9FCF1 mov rcx, [rax+10h] add rcx, rax cmp rcx, rsi ja short loc_9FD14 loc_9FCF1: mov rax, [rax] jmp short loc_9FCDB loc_9FCF6: mov rax, [rdi] loc_9FCF9: test rax, rax jz short loc_9FD18 cmp rax, rsi ja short loc_9FD0F mov rcx, [rax+10h] add rcx, rax cmp rcx, rsi ja short loc_9FD14 loc_9FD0F: mov rax, [rax] jmp short loc_9FCF9 loc_9FD14: mov [rdi+10h], rax loc_9FD18: pop rbp retn
_QWORD * set_prealloc_root(_QWORD *a1, unsigned long long a2) { _QWORD *result; // rax for ( result = (_QWORD *)a1[1]; result; result = (_QWORD *)*result ) { if ( (unsigned long long)result <= a2 && (unsigned long long)result + result[2] > a2 ) { LABEL_11: a1[2] = result; return result; } } for ( result = (_QWORD *)*a1; result; result = (_QWORD *)*result ) { if ( (unsigned long long)result <= a2 && (unsigned long long)result + result[2] > a2 ) goto LABEL_11; } return result; }
set_prealloc_root: PUSH RBP MOV RBP,RSP MOV RAX,qword ptr [RDI + 0x8] LAB_0019fcdb: TEST RAX,RAX JZ 0x0019fcf6 CMP RAX,RSI JA 0x0019fcf1 MOV RCX,qword ptr [RAX + 0x10] ADD RCX,RAX CMP RCX,RSI JA 0x0019fd14 LAB_0019fcf1: MOV RAX,qword ptr [RAX] JMP 0x0019fcdb LAB_0019fcf6: MOV RAX,qword ptr [RDI] LAB_0019fcf9: TEST RAX,RAX JZ 0x0019fd18 CMP RAX,RSI JA 0x0019fd0f MOV RCX,qword ptr [RAX + 0x10] ADD RCX,RAX CMP RCX,RSI JA 0x0019fd14 LAB_0019fd0f: MOV RAX,qword ptr [RAX] JMP 0x0019fcf9 LAB_0019fd14: MOV qword ptr [RDI + 0x10],RAX LAB_0019fd18: POP RBP RET
void set_prealloc_root(int8 *param_1,int8 *param_2) { int8 *puVar1; for (puVar1 = (int8 *)param_1[1]; puVar1 != (int8 *)0x0; puVar1 = (int8 *)*puVar1) { if ((puVar1 <= param_2) && (param_2 < (int8 *)(puVar1[2] + (long)puVar1))) goto LAB_0019fd14; } puVar1 = (int8 *)*param_1; while( true ) { if (puVar1 == (int8 *)0x0) { return; } if ((puVar1 <= param_2) && (param_2 < (int8 *)(puVar1[2] + (long)puVar1))) break; puVar1 = (int8 *)*puVar1; } LAB_0019fd14: param_1[2] = puVar1; return; }
47,468
string_join(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&)
llama.cpp/common/common.cpp
std::string string_join(const std::vector<std::string> & values, const std::string & separator) { std::ostringstream result; for (size_t i = 0; i < values.size(); ++i) { if (i > 0) { result << separator; } result << values[i]; } return result.str(); }
O3
cpp
string_join(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&): pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x178, %rsp # imm = 0x178 movq %rdx, %r14 movq %rsi, %r15 movq %rdi, %rbx movq %rsp, %rdi callq 0x21010 movq (%r15), %rax cmpq %rax, 0x8(%r15) je 0xf65bf movl $0x8, %r13d xorl %ebp, %ebp movq %rsp, %r12 testq %rbp, %rbp je 0xf6594 movq (%r14), %rsi movq 0x8(%r14), %rdx movq %r12, %rdi callq 0x21070 movq (%r15), %rax movq -0x8(%rax,%r13), %rsi movq (%rax,%r13), %rdx movq %r12, %rdi callq 0x21070 incq %rbp movq (%r15), %rax movq 0x8(%r15), %rcx subq %rax, %rcx sarq $0x5, %rcx addq $0x20, %r13 cmpq %rcx, %rbp jb 0xf657d leaq 0x8(%rsp), %rsi movq %rbx, %rdi callq 0x20650 movq 0x6b985(%rip), %rsi # 0x161f58 movq %rsp, %rdi callq 0x20c60 leaq 0x70(%rsp), %rdi callq 0x20c30 movq %rbx, %rax addq $0x178, %rsp # imm = 0x178 popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq jmp 0xf65fc movq %rax, %rbx movq 0x6b952(%rip), %rsi # 0x161f58 movq %rsp, %rdi callq 0x20c60 leaq 0x70(%rsp), %rdi callq 0x20c30 movq %rbx, %rdi callq 0x20ae0
_Z11string_joinRKSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EERKS5_: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 178h mov r14, rdx mov r15, rsi mov rbx, rdi mov rdi, rsp call __ZNSt7__cxx1119basic_ostringstreamIcSt11char_traitsIcESaIcEEC1Ev; std::ostringstream::basic_ostringstream(void) mov rax, [r15] cmp [r15+8], rax jz short loc_F65BF mov r13d, 8 xor ebp, ebp mov r12, rsp loc_F657D: test rbp, rbp jz short loc_F6594 mov rsi, [r14] mov rdx, [r14+8] mov rdi, r12 call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long) mov rax, [r15] loc_F6594: mov rsi, [rax+r13-8] mov rdx, [rax+r13] mov rdi, r12 call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long) inc rbp mov rax, [r15] mov rcx, [r15+8] sub rcx, rax sar rcx, 5 add r13, 20h ; ' ' cmp rbp, rcx jb short loc_F657D loc_F65BF: lea rsi, [rsp+1A8h+var_1A0] mov rdi, rbx call __ZNKSt7__cxx1115basic_stringbufIcSt11char_traitsIcESaIcEE3strEv; std::stringbuf::str(void) mov rsi, cs:_ZTTNSt7__cxx1119basic_ostringstreamIcSt11char_traitsIcESaIcEEE_ptr mov rdi, rsp call __ZNSt7__cxx1119basic_ostringstreamIcSt11char_traitsIcESaIcEED2Ev; std::ostringstream::~ostringstream() lea rdi, [rsp+1A8h+var_138]; this call __ZNSt8ios_baseD2Ev; std::ios_base::~ios_base() mov rax, rbx add rsp, 178h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn jmp short $+2 loc_F65FC: mov rbx, rax mov rsi, cs:_ZTTNSt7__cxx1119basic_ostringstreamIcSt11char_traitsIcESaIcEEE_ptr mov rdi, rsp call __ZNSt7__cxx1119basic_ostringstreamIcSt11char_traitsIcESaIcEED2Ev; std::ostringstream::~ostringstream() lea rdi, [rsp+arg_68]; this call __ZNSt8ios_baseD2Ev; std::ios_base::~ios_base() mov rdi, rbx call __Unwind_Resume
long long string_join(long long a1, long long *a2, _QWORD *a3) { long long v4; // rax long long v5; // r13 unsigned long long v6; // rbp long long v8; // [rsp+0h] [rbp-1A8h] BYREF _BYTE v9[104]; // [rsp+8h] [rbp-1A0h] BYREF _BYTE v10[312]; // [rsp+70h] [rbp-138h] BYREF std::ostringstream::basic_ostringstream(&v8); v4 = *a2; if ( a2[1] != *a2 ) { v5 = 8LL; v6 = 0LL; do { if ( v6 ) { std::__ostream_insert<char,std::char_traits<char>>(&v8, *a3, a3[1]); v4 = *a2; } std::__ostream_insert<char,std::char_traits<char>>(&v8, *(_QWORD *)(v4 + v5 - 8), *(_QWORD *)(v4 + v5)); ++v6; v4 = *a2; v5 += 32LL; } while ( v6 < (a2[1] - *a2) >> 5 ); } std::stringbuf::str(a1, v9); std::ostringstream::~ostringstream(&v8, &`VTT for'std::ostringstream); std::ios_base::~ios_base((std::ios_base *)v10); return a1; }
string_join: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x178 MOV R14,RDX MOV R15,RSI MOV RBX,RDI MOV RDI,RSP CALL 0x00121010 MOV RAX,qword ptr [R15] CMP qword ptr [R15 + 0x8],RAX JZ 0x001f65bf MOV R13D,0x8 XOR EBP,EBP MOV R12,RSP LAB_001f657d: TEST RBP,RBP JZ 0x001f6594 MOV RSI,qword ptr [R14] MOV RDX,qword ptr [R14 + 0x8] LAB_001f6589: MOV RDI,R12 CALL 0x00121070 MOV RAX,qword ptr [R15] LAB_001f6594: MOV RSI,qword ptr [RAX + R13*0x1 + -0x8] MOV RDX,qword ptr [RAX + R13*0x1] MOV RDI,R12 CALL 0x00121070 INC RBP MOV RAX,qword ptr [R15] MOV RCX,qword ptr [R15 + 0x8] SUB RCX,RAX SAR RCX,0x5 ADD R13,0x20 CMP RBP,RCX JC 0x001f657d LAB_001f65bf: LEA RSI,[RSP + 0x8] LAB_001f65c4: MOV RDI,RBX CALL 0x00120650 LAB_001f65cc: MOV RSI,qword ptr [0x00261f58] MOV RDI,RSP CALL 0x00120c60 LEA RDI,[RSP + 0x70] CALL 0x00120c30 MOV RAX,RBX ADD RSP,0x178 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
/* string_join(std::vector<std::__cxx11::string, std::allocator<std::__cxx11::string > > const&, std::__cxx11::string const&) */ vector * string_join(vector *param_1,string *param_2) { long lVar1; int8 *in_RDX; ulong uVar2; long lVar3; ostringstream aoStack_1a8 [112]; ios_base local_138 [264]; std::__cxx11::ostringstream::ostringstream(aoStack_1a8); lVar1 = *(long *)param_2; if (*(long *)(param_2 + 8) != lVar1) { lVar3 = 8; uVar2 = 0; do { if (uVar2 != 0) { /* try { // try from 001f6589 to 001f65a4 has its CatchHandler @ 001f65fc */ std::__ostream_insert<char,std::char_traits<char>> ((ostream *)aoStack_1a8,(char *)*in_RDX,in_RDX[1]); lVar1 = *(long *)param_2; } std::__ostream_insert<char,std::char_traits<char>> ((ostream *)aoStack_1a8,*(char **)(lVar1 + -8 + lVar3),*(long *)(lVar1 + lVar3)); uVar2 = uVar2 + 1; lVar1 = *(long *)param_2; lVar3 = lVar3 + 0x20; } while (uVar2 < (ulong)(*(long *)(param_2 + 8) - lVar1 >> 5)); } /* try { // try from 001f65c4 to 001f65cb has its CatchHandler @ 001f65fa */ std::__cxx11::stringbuf::str(); std::__cxx11::ostringstream::~ostringstream(aoStack_1a8); std::ios_base::~ios_base(local_138); return param_1; }
47,469
my_thread_destroy_common_mutex
eloqsql/mysys/my_thr_init.c
void my_thread_destroy_common_mutex(void) { mysql_mutex_destroy(&THR_LOCK_open); mysql_mutex_destroy(&THR_LOCK_lock); mysql_mutex_destroy(&THR_LOCK_myisam); mysql_mutex_destroy(&THR_LOCK_myisam_mmap); mysql_mutex_destroy(&THR_LOCK_heap); mysql_mutex_destroy(&THR_LOCK_net); mysql_mutex_destroy(&THR_LOCK_charset); #if !defined(HAVE_LOCALTIME_R) || !defined(HAVE_GMTIME_R) mysql_mutex_destroy(&LOCK_localtime_r); #endif }
O0
c
my_thread_destroy_common_mutex: pushq %rbp movq %rsp, %rbp leaq 0x364b6d(%rip), %rdi # 0x3932b8 callq 0x2e7a0 leaq 0x364ba9(%rip), %rdi # 0x393300 callq 0x2e7a0 leaq 0x364be5(%rip), %rdi # 0x393348 callq 0x2e7a0 leaq 0x364c21(%rip), %rdi # 0x393390 callq 0x2e7a0 leaq 0x364c5d(%rip), %rdi # 0x3933d8 callq 0x2e7a0 leaq 0x364c99(%rip), %rdi # 0x393420 callq 0x2e7a0 leaq 0x364cd5(%rip), %rdi # 0x393468 callq 0x2e7a0 popq %rbp retq nopw (%rax,%rax)
my_thread_destroy_common_mutex: push rbp mov rbp, rsp lea rdi, THR_LOCK_open call inline_mysql_mutex_destroy lea rdi, THR_LOCK_lock call inline_mysql_mutex_destroy lea rdi, THR_LOCK_myisam call inline_mysql_mutex_destroy lea rdi, THR_LOCK_myisam_mmap call inline_mysql_mutex_destroy lea rdi, THR_LOCK_heap call inline_mysql_mutex_destroy lea rdi, THR_LOCK_net call inline_mysql_mutex_destroy lea rdi, THR_LOCK_charset call inline_mysql_mutex_destroy pop rbp retn
long long my_thread_destroy_common_mutex() { inline_mysql_mutex_destroy(&THR_LOCK_open); inline_mysql_mutex_destroy(&THR_LOCK_lock); inline_mysql_mutex_destroy(&THR_LOCK_myisam); inline_mysql_mutex_destroy(&THR_LOCK_myisam_mmap); inline_mysql_mutex_destroy(&THR_LOCK_heap); inline_mysql_mutex_destroy(&THR_LOCK_net); return inline_mysql_mutex_destroy(&THR_LOCK_charset); }
my_thread_destroy_common_mutex: PUSH RBP MOV RBP,RSP LEA RDI,[0x4932b8] CALL 0x0012e7a0 LEA RDI,[0x493300] CALL 0x0012e7a0 LEA RDI,[0x493348] CALL 0x0012e7a0 LEA RDI,[0x493390] CALL 0x0012e7a0 LEA RDI,[0x4933d8] CALL 0x0012e7a0 LEA RDI,[0x493420] CALL 0x0012e7a0 LEA RDI,[0x493468] CALL 0x0012e7a0 POP RBP RET
void my_thread_destroy_common_mutex(void) { inline_mysql_mutex_destroy(THR_LOCK_open); inline_mysql_mutex_destroy(THR_LOCK_lock); inline_mysql_mutex_destroy(THR_LOCK_myisam); inline_mysql_mutex_destroy(THR_LOCK_myisam_mmap); inline_mysql_mutex_destroy(THR_LOCK_heap); inline_mysql_mutex_destroy(THR_LOCK_net); inline_mysql_mutex_destroy(THR_LOCK_charset); return; }
47,470
svc_tasks_init_waitable_task
navaro[P]qoraal-tictactoe/build_O3/_deps/qoraal-src/src/svc/svc_tasks.c
int32_t svc_tasks_init_waitable_task (SVC_WAITABLE_TASKS_T* task) { svc_tasks_init_task(&task->task) ; task->event = 0 ; p_event_t event ; int32_t res = os_event_create (&event) ; if (res == EOK) { task->event = event ; task->task.flags = SVC_TASKS_FLAGS_WAITABLE ; } return res ; }
O3
c
svc_tasks_init_waitable_task: pushq %rbp movq %rsp, %rbp pushq %rbx pushq %rax movq %rdi, %rbx movb $0x0, 0x10(%rdi) movw $0x0, 0x12(%rdi) movq $0x0, 0x28(%rdi) leaq -0x10(%rbp), %rdi callq 0x15383 testl %eax, %eax jne 0x18fab movq -0x10(%rbp), %rcx movq %rcx, 0x28(%rbx) movb $0x1, 0x12(%rbx) addq $0x8, %rsp popq %rbx popq %rbp retq
svc_tasks_init_waitable_task: push rbp mov rbp, rsp push rbx push rax mov rbx, rdi mov byte ptr [rdi+10h], 0 mov word ptr [rdi+12h], 0 mov qword ptr [rdi+28h], 0 lea rdi, [rbp+var_10] call os_event_create test eax, eax jnz short loc_18FAB mov rcx, [rbp+var_10] mov [rbx+28h], rcx mov byte ptr [rbx+12h], 1 loc_18FAB: add rsp, 8 pop rbx pop rbp retn
long long svc_tasks_init_waitable_task(long long a1) { long long v1; // rax long long result; // rax long long v3; // [rsp+0h] [rbp-10h] BYREF v3 = v1; *(_BYTE *)(a1 + 16) = 0; *(_WORD *)(a1 + 18) = 0; *(_QWORD *)(a1 + 40) = 0LL; result = os_event_create(&v3); if ( !(_DWORD)result ) { *(_QWORD *)(a1 + 40) = v3; *(_BYTE *)(a1 + 18) = 1; } return result; }
svc_tasks_init_waitable_task: PUSH RBP MOV RBP,RSP PUSH RBX PUSH RAX MOV RBX,RDI MOV byte ptr [RDI + 0x10],0x0 MOV word ptr [RDI + 0x12],0x0 MOV qword ptr [RDI + 0x28],0x0 LEA RDI,[RBP + -0x10] CALL 0x00115383 TEST EAX,EAX JNZ 0x00118fab MOV RCX,qword ptr [RBP + -0x10] MOV qword ptr [RBX + 0x28],RCX MOV byte ptr [RBX + 0x12],0x1 LAB_00118fab: ADD RSP,0x8 POP RBX POP RBP RET
void svc_tasks_init_waitable_task(long param_1) { int4 in_EAX; int iVar1; int4 in_register_00000004; int8 local_18; local_18 = CONCAT44(in_register_00000004,in_EAX); *(int1 *)(param_1 + 0x10) = 0; *(int2 *)(param_1 + 0x12) = 0; *(int8 *)(param_1 + 0x28) = 0; iVar1 = os_event_create(&local_18); if (iVar1 == 0) { *(int8 *)(param_1 + 0x28) = local_18; *(int1 *)(param_1 + 0x12) = 1; } return; }
47,471
Field_row::sp_prepare_and_store_item(THD*, Item**)
eloqsql/sql/field.cc
bool Field_row::sp_prepare_and_store_item(THD *thd, Item **value) { DBUG_ENTER("Field_row::sp_prepare_and_store_item"); if (value[0]->type() == Item::NULL_ITEM) { /* We're in a auto-generated sp_inst_set, to assign the explicit default NULL value to a ROW variable. */ m_table->set_all_fields_to_null(); DBUG_RETURN(false); } /** - In case if we're assigning a ROW variable from another ROW variable, value[0] points to Item_splocal. sp_fix_func_item() will return the fixed underlying Item_field pointing to Field_row. - In case if we're assigning from a ROW() value, src and value[0] will point to the same Item_row. */ Item *src; if (!(src= thd->sp_fix_func_item(value)) || src->cmp_type() != ROW_RESULT || src->cols() != m_table->s->fields) { my_error(ER_OPERAND_COLUMNS, MYF(0), m_table->s->fields); m_table->set_all_fields_to_null(); DBUG_RETURN(true); } DBUG_RETURN(m_table->sp_set_all_fields_from_item(thd, src)); }
O0
cpp
Field_row::sp_prepare_and_store_item(THD*, Item**): pushq %rbp movq %rsp, %rbp subq $0x30, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq %rdx, -0x20(%rbp) movq -0x10(%rbp), %rax movq %rax, -0x30(%rbp) movq -0x20(%rbp), %rax movq (%rax), %rdi movq (%rdi), %rax callq *0xc8(%rax) cmpl $0x5, %eax jne 0x8abcda movq -0x30(%rbp), %rax movq 0xd8(%rax), %rdi callq 0x8c72d0 movb $0x0, -0x1(%rbp) jmp 0x8abd7b movq -0x18(%rbp), %rdi movq -0x20(%rbp), %rsi callq 0x4d4f50 movq %rax, -0x28(%rbp) cmpq $0x0, %rax je 0x8abd22 movq -0x28(%rbp), %rdi callq 0x641500 cmpl $0x3, %eax jne 0x8abd22 movq -0x28(%rbp), %rdi movq (%rdi), %rax callq *0x4e8(%rax) movq -0x30(%rbp), %rcx movq 0xd8(%rcx), %rcx movq (%rcx), %rcx cmpl 0x36c(%rcx), %eax je 0x8abd5c movq -0x30(%rbp), %rax movq 0xd8(%rax), %rax movq (%rax), %rax movl 0x36c(%rax), %edx movl $0x4d9, %edi # imm = 0x4D9 xorl %eax, %eax movl %eax, %esi movb $0x0, %al callq 0xc12a30 movq -0x30(%rbp), %rax movq 0xd8(%rax), %rdi callq 0x8c72d0 movb $0x1, -0x1(%rbp) jmp 0x8abd7b jmp 0x8abd5e movq -0x30(%rbp), %rax movq 0xd8(%rax), %rdi movq -0x18(%rbp), %rsi movq -0x28(%rbp), %rdx callq 0x628f60 andb $0x1, %al movb %al, -0x1(%rbp) movb -0x1(%rbp), %al andb $0x1, %al addq $0x30, %rsp popq %rbp retq nopw %cs:(%rax,%rax)
_ZN9Field_row25sp_prepare_and_store_itemEP3THDPP4Item: push rbp mov rbp, rsp sub rsp, 30h mov [rbp+var_10], rdi mov [rbp+var_18], rsi mov [rbp+var_20], rdx mov rax, [rbp+var_10] mov [rbp+var_30], rax mov rax, [rbp+var_20] mov rdi, [rax] mov rax, [rdi] call qword ptr [rax+0C8h] cmp eax, 5 jnz short loc_8ABCDA mov rax, [rbp+var_30] mov rdi, [rax+0D8h]; this call _ZN17Virtual_tmp_table22set_all_fields_to_nullEv; Virtual_tmp_table::set_all_fields_to_null(void) mov [rbp+var_1], 0 jmp loc_8ABD7B loc_8ABCDA: mov rdi, [rbp+var_18]; this mov rsi, [rbp+var_20]; Item ** call _ZN3THD16sp_fix_func_itemEPP4Item; THD::sp_fix_func_item(Item **) mov [rbp+var_28], rax cmp rax, 0 jz short loc_8ABD22 mov rdi, [rbp+var_28]; this call _ZNK4Item8cmp_typeEv; Item::cmp_type(void) cmp eax, 3 jnz short loc_8ABD22 mov rdi, [rbp+var_28] mov rax, [rdi] call qword ptr [rax+4E8h] mov rcx, [rbp+var_30] mov rcx, [rcx+0D8h] mov rcx, [rcx] cmp eax, [rcx+36Ch] jz short loc_8ABD5C loc_8ABD22: mov rax, [rbp+var_30] mov rax, [rax+0D8h] mov rax, [rax] mov edx, [rax+36Ch] mov edi, 4D9h xor eax, eax mov esi, eax mov al, 0 call my_error mov rax, [rbp+var_30] mov rdi, [rax+0D8h]; this call _ZN17Virtual_tmp_table22set_all_fields_to_nullEv; Virtual_tmp_table::set_all_fields_to_null(void) mov [rbp+var_1], 1 jmp short loc_8ABD7B loc_8ABD5C: jmp short $+2 loc_8ABD5E: mov rax, [rbp+var_30] mov rdi, [rax+0D8h]; this mov rsi, [rbp+var_18]; THD * mov rdx, [rbp+var_28]; Item * call _ZN17Virtual_tmp_table27sp_set_all_fields_from_itemEP3THDP4Item; Virtual_tmp_table::sp_set_all_fields_from_item(THD *,Item *) and al, 1 mov [rbp+var_1], al loc_8ABD7B: mov al, [rbp+var_1] and al, 1 add rsp, 30h pop rbp retn
char Field_row::sp_prepare_and_store_item(Virtual_tmp_table **this, THD *a2, Item **a3) { long long v3; // rcx int v4; // r8d int v5; // r9d int v6; // eax Item *fixed; // [rsp+8h] [rbp-28h] if ( (*(unsigned int ( **)(_QWORD))(*(_QWORD *)*a3 + 200LL))(*a3) == 5 ) { Virtual_tmp_table::set_all_fields_to_null(this[27]); return 0; } else { fixed = THD::sp_fix_func_item(a2, a3); if ( fixed && (unsigned int)Item::cmp_type(fixed) == 3 && (v6 = (*(long long ( **)(Item *))(*(_QWORD *)fixed + 1256LL))(fixed), v3 = *(_QWORD *)this[27], v6 == *(_DWORD *)(v3 + 876)) ) { return Virtual_tmp_table::sp_set_all_fields_from_item(this[27], a2, fixed) & 1; } else { my_error(1241, 0, *(_DWORD *)(*(_QWORD *)this[27] + 876LL), v3, v4, v5); Virtual_tmp_table::set_all_fields_to_null(this[27]); return 1; } } }
type_handler_signed: PUSH RBP MOV RBP,RSP MOV qword ptr [RBP + -0x8],RDI LEA RAX,[0x16f0920] POP RBP RET
/* Type_handler_int24::type_handler_signed() const */ int1 * Type_handler_int24::type_handler_signed(void) { return type_handler_sint24; }
47,472
list_walk
eloqsql/mysys/list.c
int list_walk(LIST *list, list_walk_action action, uchar* argument) { int error=0; while (list) { if ((error = (*action)(list->data,argument))) return error; list=list_rest(list); } return 0; }
O3
c
list_walk: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r12 pushq %rbx xorl %ebx, %ebx testq %rdi, %rdi je 0x94444 movq %rdx, %r14 movq %rsi, %r15 movq %rdi, %r12 movq 0x10(%r12), %rdi movq %r14, %rsi callq *%r15 testl %eax, %eax jne 0x94442 movq 0x8(%r12), %r12 testq %r12, %r12 jne 0x94427 jmp 0x94444 movl %eax, %ebx movl %ebx, %eax popq %rbx popq %r12 popq %r14 popq %r15 popq %rbp retq nop
list_walk: push rbp mov rbp, rsp push r15 push r14 push r12 push rbx xor ebx, ebx test rdi, rdi jz short loc_94444 mov r14, rdx mov r15, rsi mov r12, rdi loc_94427: mov rdi, [r12+10h] mov rsi, r14 call r15 test eax, eax jnz short loc_94442 mov r12, [r12+8] test r12, r12 jnz short loc_94427 jmp short loc_94444 loc_94442: mov ebx, eax loc_94444: mov eax, ebx pop rbx pop r12 pop r14 pop r15 pop rbp retn
long long list_walk(long long a1, long long ( *a2)(_QWORD, long long), long long a3) { unsigned int v3; // ebx long long v5; // r12 unsigned int v6; // eax v3 = 0; if ( a1 ) { v5 = a1; while ( 1 ) { v6 = a2(*(_QWORD *)(v5 + 16), a3); if ( v6 ) break; v5 = *(_QWORD *)(v5 + 8); if ( !v5 ) return v3; } return v6; } return v3; }
list_walk: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R12 PUSH RBX XOR EBX,EBX TEST RDI,RDI JZ 0x00194444 MOV R14,RDX MOV R15,RSI MOV R12,RDI LAB_00194427: MOV RDI,qword ptr [R12 + 0x10] MOV RSI,R14 CALL R15 TEST EAX,EAX JNZ 0x00194442 MOV R12,qword ptr [R12 + 0x8] TEST R12,R12 JNZ 0x00194427 JMP 0x00194444 LAB_00194442: MOV EBX,EAX LAB_00194444: MOV EAX,EBX POP RBX POP R12 POP R14 POP R15 POP RBP RET
int list_walk(long param_1,code *param_2,int8 param_3) { int iVar1; if (param_1 != 0) { do { iVar1 = (*param_2)(*(int8 *)(param_1 + 0x10),param_3); if (iVar1 != 0) { return iVar1; } param_1 = *(long *)(param_1 + 8); } while (param_1 != 0); } return 0; }
47,473
my_wc_mb_big5
eloqsql/strings/ctype-big5.c
static int my_wc_mb_big5(CHARSET_INFO *cs __attribute__((unused)), my_wc_t wc, uchar *s, uchar *e) { int code; if (s >= e) return MY_CS_TOOSMALL; if ((int) wc < 0x80) { s[0]= (uchar) wc; return 1; } if (!(code=func_uni_big5_onechar(wc))) return MY_CS_ILUNI; if (s+2>e) return MY_CS_TOOSMALL; s[0]=code>>8; s[1]=code&0xFF; return 2; }
O0
c
my_wc_mb_big5: pushq %rbp movq %rsp, %rbp subq $0x30, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq %rdx, -0x20(%rbp) movq %rcx, -0x28(%rbp) movq -0x20(%rbp), %rax cmpq -0x28(%rbp), %rax jb 0x6b2ab movl $0xffffff9b, -0x4(%rbp) # imm = 0xFFFFFF9B jmp 0x6b324 movq -0x18(%rbp), %rax cmpl $0x80, %eax jge 0x6b2cb movq -0x18(%rbp), %rax movb %al, %cl movq -0x20(%rbp), %rax movb %cl, (%rax) movl $0x1, -0x4(%rbp) jmp 0x6b324 movq -0x18(%rbp), %rax movl %eax, %edi callq 0x6b620 movl %eax, -0x2c(%rbp) cmpl $0x0, %eax jne 0x6b2e7 movl $0x0, -0x4(%rbp) jmp 0x6b324 movq -0x20(%rbp), %rax addq $0x2, %rax cmpq -0x28(%rbp), %rax jbe 0x6b2fe movl $0xffffff9b, -0x4(%rbp) # imm = 0xFFFFFF9B jmp 0x6b324 movl -0x2c(%rbp), %eax sarl $0x8, %eax movb %al, %cl movq -0x20(%rbp), %rax movb %cl, (%rax) movl -0x2c(%rbp), %eax andl $0xff, %eax movb %al, %cl movq -0x20(%rbp), %rax movb %cl, 0x1(%rax) movl $0x2, -0x4(%rbp) movl -0x4(%rbp), %eax addq $0x30, %rsp popq %rbp retq nopl (%rax)
my_wc_mb_big5: push rbp mov rbp, rsp sub rsp, 30h mov [rbp+var_10], rdi mov [rbp+var_18], rsi mov [rbp+var_20], rdx mov [rbp+var_28], rcx mov rax, [rbp+var_20] cmp rax, [rbp+var_28] jb short loc_6B2AB mov [rbp+var_4], 0FFFFFF9Bh jmp short loc_6B324 loc_6B2AB: mov rax, [rbp+var_18] cmp eax, 80h jge short loc_6B2CB mov rax, [rbp+var_18] mov cl, al mov rax, [rbp+var_20] mov [rax], cl mov [rbp+var_4], 1 jmp short loc_6B324 loc_6B2CB: mov rax, [rbp+var_18] mov edi, eax call func_uni_big5_onechar mov [rbp+var_2C], eax cmp eax, 0 jnz short loc_6B2E7 mov [rbp+var_4], 0 jmp short loc_6B324 loc_6B2E7: mov rax, [rbp+var_20] add rax, 2 cmp rax, [rbp+var_28] jbe short loc_6B2FE mov [rbp+var_4], 0FFFFFF9Bh jmp short loc_6B324 loc_6B2FE: mov eax, [rbp+var_2C] sar eax, 8 mov cl, al mov rax, [rbp+var_20] mov [rax], cl mov eax, [rbp+var_2C] and eax, 0FFh mov cl, al mov rax, [rbp+var_20] mov [rax+1], cl mov [rbp+var_4], 2 loc_6B324: mov eax, [rbp+var_4] add rsp, 30h pop rbp retn
long long my_wc_mb_big5(long long a1, int a2, _BYTE *a3, unsigned long long a4) { int v5; // [rsp+4h] [rbp-2Ch] if ( (unsigned long long)a3 < a4 ) { if ( a2 >= 128 ) { v5 = func_uni_big5_onechar((unsigned int)a2); if ( v5 ) { if ( (unsigned long long)(a3 + 2) <= a4 ) { *a3 = BYTE1(v5); a3[1] = v5; return 2; } else { return (unsigned int)-101; } } else { return 0; } } else { *a3 = a2; return 1; } } else { return (unsigned int)-101; } }
my_wc_mb_big5: PUSH RBP MOV RBP,RSP SUB RSP,0x30 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 RAX,qword ptr [RBP + -0x20] CMP RAX,qword ptr [RBP + -0x28] JC 0x0016b2ab MOV dword ptr [RBP + -0x4],0xffffff9b JMP 0x0016b324 LAB_0016b2ab: MOV RAX,qword ptr [RBP + -0x18] CMP EAX,0x80 JGE 0x0016b2cb MOV RAX,qword ptr [RBP + -0x18] MOV CL,AL MOV RAX,qword ptr [RBP + -0x20] MOV byte ptr [RAX],CL MOV dword ptr [RBP + -0x4],0x1 JMP 0x0016b324 LAB_0016b2cb: MOV RAX,qword ptr [RBP + -0x18] MOV EDI,EAX CALL 0x0016b620 MOV dword ptr [RBP + -0x2c],EAX CMP EAX,0x0 JNZ 0x0016b2e7 MOV dword ptr [RBP + -0x4],0x0 JMP 0x0016b324 LAB_0016b2e7: MOV RAX,qword ptr [RBP + -0x20] ADD RAX,0x2 CMP RAX,qword ptr [RBP + -0x28] JBE 0x0016b2fe MOV dword ptr [RBP + -0x4],0xffffff9b JMP 0x0016b324 LAB_0016b2fe: MOV EAX,dword ptr [RBP + -0x2c] SAR EAX,0x8 MOV CL,AL MOV RAX,qword ptr [RBP + -0x20] MOV byte ptr [RAX],CL MOV EAX,dword ptr [RBP + -0x2c] AND EAX,0xff MOV CL,AL MOV RAX,qword ptr [RBP + -0x20] MOV byte ptr [RAX + 0x1],CL MOV dword ptr [RBP + -0x4],0x2 LAB_0016b324: MOV EAX,dword ptr [RBP + -0x4] ADD RSP,0x30 POP RBP RET
int4 my_wc_mb_big5(int8 param_1,int param_2,int1 *param_3,int1 *param_4) { int iVar1; int4 local_c; if (param_3 < param_4) { if (param_2 < 0x80) { *param_3 = (char)param_2; local_c = 1; } else { iVar1 = func_uni_big5_onechar(param_2); if (iVar1 == 0) { local_c = 0; } else if (param_4 < param_3 + 2) { local_c = 0xffffff9b; } else { *param_3 = (char)((uint)iVar1 >> 8); param_3[1] = (char)iVar1; local_c = 2; } } } else { local_c = 0xffffff9b; } return local_c; }
47,474
ma_read_static_record
eloqsql/storage/maria/ma_statrec.c
int _ma_read_static_record(register MARIA_HA *info, register uchar *record, MARIA_RECORD_POS pos) { int error; DBUG_ENTER("_ma_read_static_record"); if (pos != HA_OFFSET_ERROR) { if (info->opt_flag & WRITE_CACHE_USED && info->rec_cache.pos_in_file <= pos && flush_io_cache(&info->rec_cache)) DBUG_RETURN(my_errno); info->rec_cache.seek_not_done=1; /* We have done a seek */ error= (int) info->s->file_read(info, record,info->s->base.reclength, pos, MYF(MY_NABP)); if (! error) { fast_ma_writeinfo(info); if (!*record) { /* Record is deleted */ DBUG_PRINT("warning", ("Record is deleted")); DBUG_RETURN((my_errno=HA_ERR_RECORD_DELETED)); } info->update|= HA_STATE_AKTIV; /* Record is read */ DBUG_RETURN(0); } } fast_ma_writeinfo(info); /* No such record */ DBUG_RETURN(my_errno); }
O0
c
ma_read_static_record: pushq %rbp movq %rsp, %rbp subq $0x30, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq %rdx, -0x20(%rbp) cmpq $-0x1, -0x20(%rbp) je 0x7e340 movq -0x10(%rbp), %rax movl 0x61c(%rax), %eax andl $0x10, %eax cmpl $0x0, %eax je 0x7e29d movq -0x10(%rbp), %rax movq 0x4b8(%rax), %rax cmpq -0x20(%rbp), %rax ja 0x7e29d movq -0x10(%rbp), %rdi addq $0x4b8, %rdi # imm = 0x4B8 movl $0x1, %esi callq 0xafda0 cmpl $0x0, %eax je 0x7e29d jmp 0x7e28e callq 0xc0d80 movl (%rax), %eax movl %eax, -0x4(%rbp) jmp 0x7e367 movq -0x10(%rbp), %rax movl $0x1, 0x598(%rax) movq -0x10(%rbp), %rax movq (%rax), %rax movq 0x6e0(%rax), %rax movq -0x10(%rbp), %rdi movq -0x18(%rbp), %rsi movq -0x10(%rbp), %rcx movq (%rcx), %rcx movq 0x398(%rcx), %rdx movq -0x20(%rbp), %rcx movl $0x4, %r8d callq *%rax movl %eax, -0x24(%rbp) cmpl $0x0, -0x24(%rbp) jne 0x7e33e movq -0x10(%rbp), %rax movq (%rax), %rax cmpl $0x0, 0x7b8(%rax) jne 0x7e2ff movq -0x10(%rbp), %rdi xorl %esi, %esi callq 0x3ae00 movq -0x18(%rbp), %rax cmpb $0x0, (%rax) jne 0x7e322 jmp 0x7e30a jmp 0x7e30c jmp 0x7e30e callq 0xc0d80 movl $0x86, (%rax) movl $0x86, -0x4(%rbp) jmp 0x7e367 movq -0x10(%rbp), %rax movl 0x624(%rax), %ecx orl $0x2, %ecx movl %ecx, 0x624(%rax) movl $0x0, -0x4(%rbp) jmp 0x7e367 jmp 0x7e340 movq -0x10(%rbp), %rax movq (%rax), %rax cmpl $0x0, 0x7b8(%rax) jne 0x7e35b movq -0x10(%rbp), %rdi xorl %esi, %esi callq 0x3ae00 jmp 0x7e35d callq 0xc0d80 movl (%rax), %eax movl %eax, -0x4(%rbp) movl -0x4(%rbp), %eax addq $0x30, %rsp popq %rbp retq
_ma_read_static_record: push rbp mov rbp, rsp sub rsp, 30h mov [rbp+var_10], rdi mov [rbp+var_18], rsi mov [rbp+var_20], rdx cmp [rbp+var_20], 0FFFFFFFFFFFFFFFFh jz loc_7E340 mov rax, [rbp+var_10] mov eax, [rax+61Ch] and eax, 10h cmp eax, 0 jz short loc_7E29D mov rax, [rbp+var_10] mov rax, [rax+4B8h] cmp rax, [rbp+var_20] ja short loc_7E29D mov rdi, [rbp+var_10] add rdi, 4B8h mov esi, 1 call my_b_flush_io_cache cmp eax, 0 jz short loc_7E29D jmp short $+2 loc_7E28E: call _my_thread_var mov eax, [rax] mov [rbp+var_4], eax jmp loc_7E367 loc_7E29D: mov rax, [rbp+var_10] mov dword ptr [rax+598h], 1 mov rax, [rbp+var_10] mov rax, [rax] mov rax, [rax+6E0h] mov rdi, [rbp+var_10] mov rsi, [rbp+var_18] mov rcx, [rbp+var_10] mov rcx, [rcx] mov rdx, [rcx+398h] mov rcx, [rbp+var_20] mov r8d, 4 call rax mov [rbp+var_24], eax cmp [rbp+var_24], 0 jnz short loc_7E33E mov rax, [rbp+var_10] mov rax, [rax] cmp dword ptr [rax+7B8h], 0 jnz short loc_7E2FF mov rdi, [rbp+var_10] xor esi, esi call _ma_writeinfo loc_7E2FF: mov rax, [rbp+var_18] cmp byte ptr [rax], 0 jnz short loc_7E322 jmp short $+2 loc_7E30A: jmp short $+2 loc_7E30C: jmp short $+2 loc_7E30E: call _my_thread_var mov dword ptr [rax], 86h mov [rbp+var_4], 86h jmp short loc_7E367 loc_7E322: mov rax, [rbp+var_10] mov ecx, [rax+624h] or ecx, 2 mov [rax+624h], ecx mov [rbp+var_4], 0 jmp short loc_7E367 loc_7E33E: jmp short $+2 loc_7E340: mov rax, [rbp+var_10] mov rax, [rax] cmp dword ptr [rax+7B8h], 0 jnz short loc_7E35B mov rdi, [rbp+var_10] xor esi, esi call _ma_writeinfo loc_7E35B: jmp short $+2 loc_7E35D: call _my_thread_var mov eax, [rax] mov [rbp+var_4], eax loc_7E367: mov eax, [rbp+var_4] add rsp, 30h pop rbp retn
long long ma_read_static_record(long long a1, const char *a2, unsigned long long a3) { char *v5; // [rsp+18h] [rbp-18h] long long v6; // [rsp+20h] [rbp-10h] v6 = a1; v5 = (char *)a2; if ( a3 == -1LL ) goto LABEL_17; if ( (*(_DWORD *)(a1 + 1564) & 0x10) != 0 && *(_QWORD *)(a1 + 1208) <= a3 ) { a1 += 1208LL; a2 = (_BYTE *)(&dword_0 + 1); if ( (unsigned int)my_b_flush_io_cache(v6 + 1208, 1LL) ) return *(unsigned int *)my_thread_var(a1, a2); } *(_DWORD *)(v6 + 1432) = 1; a1 = v6; a2 = v5; if ( (*(unsigned int ( **)(long long, char *, _QWORD, unsigned long long, long long))(*(_QWORD *)v6 + 1760LL))( v6, v5, *(_QWORD *)(*(_QWORD *)v6 + 920LL), a3, 4LL) ) { LABEL_17: if ( !*(_DWORD *)(*(_QWORD *)v6 + 1976LL) ) { a1 = v6; a2 = 0LL; ma_writeinfo((long long *)v6, 0); } return *(unsigned int *)my_thread_var(a1, a2); } if ( !*(_DWORD *)(*(_QWORD *)v6 + 1976LL) ) { a1 = v6; a2 = 0LL; ma_writeinfo((long long *)v6, 0); } if ( *v5 ) { *(_DWORD *)(v6 + 1572) |= 2u; return 0; } else { *(_DWORD *)my_thread_var(a1, a2) = 134; return 134; } }
_ma_read_static_record: PUSH RBP MOV RBP,RSP SUB RSP,0x30 MOV qword ptr [RBP + -0x10],RDI MOV qword ptr [RBP + -0x18],RSI MOV qword ptr [RBP + -0x20],RDX CMP qword ptr [RBP + -0x20],-0x1 JZ 0x0017e340 MOV RAX,qword ptr [RBP + -0x10] MOV EAX,dword ptr [RAX + 0x61c] AND EAX,0x10 CMP EAX,0x0 JZ 0x0017e29d MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x4b8] CMP RAX,qword ptr [RBP + -0x20] JA 0x0017e29d MOV RDI,qword ptr [RBP + -0x10] ADD RDI,0x4b8 MOV ESI,0x1 CALL 0x001afda0 CMP EAX,0x0 JZ 0x0017e29d JMP 0x0017e28e LAB_0017e28e: CALL 0x001c0d80 MOV EAX,dword ptr [RAX] MOV dword ptr [RBP + -0x4],EAX JMP 0x0017e367 LAB_0017e29d: MOV RAX,qword ptr [RBP + -0x10] MOV dword ptr [RAX + 0x598],0x1 MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX] MOV RAX,qword ptr [RAX + 0x6e0] MOV RDI,qword ptr [RBP + -0x10] MOV RSI,qword ptr [RBP + -0x18] MOV RCX,qword ptr [RBP + -0x10] MOV RCX,qword ptr [RCX] MOV RDX,qword ptr [RCX + 0x398] MOV RCX,qword ptr [RBP + -0x20] MOV R8D,0x4 CALL RAX MOV dword ptr [RBP + -0x24],EAX CMP dword ptr [RBP + -0x24],0x0 JNZ 0x0017e33e MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX] CMP dword ptr [RAX + 0x7b8],0x0 JNZ 0x0017e2ff MOV RDI,qword ptr [RBP + -0x10] XOR ESI,ESI CALL 0x0013ae00 LAB_0017e2ff: MOV RAX,qword ptr [RBP + -0x18] CMP byte ptr [RAX],0x0 JNZ 0x0017e322 JMP 0x0017e30a LAB_0017e30a: JMP 0x0017e30c LAB_0017e30c: JMP 0x0017e30e LAB_0017e30e: CALL 0x001c0d80 MOV dword ptr [RAX],0x86 MOV dword ptr [RBP + -0x4],0x86 JMP 0x0017e367 LAB_0017e322: MOV RAX,qword ptr [RBP + -0x10] MOV ECX,dword ptr [RAX + 0x624] OR ECX,0x2 MOV dword ptr [RAX + 0x624],ECX MOV dword ptr [RBP + -0x4],0x0 JMP 0x0017e367 LAB_0017e33e: JMP 0x0017e340 LAB_0017e340: MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX] CMP dword ptr [RAX + 0x7b8],0x0 JNZ 0x0017e35b MOV RDI,qword ptr [RBP + -0x10] XOR ESI,ESI CALL 0x0013ae00 LAB_0017e35b: JMP 0x0017e35d LAB_0017e35d: CALL 0x001c0d80 MOV EAX,dword ptr [RAX] MOV dword ptr [RBP + -0x4],EAX LAB_0017e367: MOV EAX,dword ptr [RBP + -0x4] ADD RSP,0x30 POP RBP RET
int4 _ma_read_static_record(long *param_1,char *param_2,ulong param_3) { int iVar1; int4 *puVar2; if (param_3 != 0xffffffffffffffff) { if ((((*(uint *)((long)param_1 + 0x61c) & 0x10) != 0) && ((ulong)param_1[0x97] <= param_3)) && (iVar1 = my_b_flush_io_cache(param_1 + 0x97,1), iVar1 != 0)) { puVar2 = (int4 *)_my_thread_var(); return *puVar2; } *(int4 *)(param_1 + 0xb3) = 1; iVar1 = (**(code **)(*param_1 + 0x6e0)) (param_1,param_2,*(int8 *)(*param_1 + 0x398),param_3,4); if (iVar1 == 0) { if (*(int *)(*param_1 + 0x7b8) == 0) { _ma_writeinfo(param_1,0); } if (*param_2 == '\0') { puVar2 = (int4 *)_my_thread_var(); *puVar2 = 0x86; return 0x86; } *(uint *)((long)param_1 + 0x624) = *(uint *)((long)param_1 + 0x624) | 2; return 0; } } if (*(int *)(*param_1 + 0x7b8) == 0) { _ma_writeinfo(param_1,0); } puVar2 = (int4 *)_my_thread_var(); return *puVar2; }
47,475
fmt::v10::basic_format_arg<fmt::v10::basic_format_context<fmt::v10::appender, char>> fmt::v10::detail::make_arg<fmt::v10::basic_format_context<fmt::v10::appender, char>, float>(float&)
AlayaLite/build_O0/_deps/spdlog-src/include/spdlog/fmt/bundled/core.h
FMT_CONSTEXPR auto make_arg(T& val) -> basic_format_arg<Context> { auto arg = basic_format_arg<Context>(); arg.type_ = mapped_type_constant<T, Context>::value; arg.value_ = make_arg<true, Context>(val); return arg; }
O0
c
fmt::v10::basic_format_arg<fmt::v10::basic_format_context<fmt::v10::appender, char>> fmt::v10::detail::make_arg<fmt::v10::basic_format_context<fmt::v10::appender, char>, float>(float&): subq $0x78, %rsp movq %rdi, (%rsp) movq %rdi, %rax movq %rax, 0x8(%rsp) movq %rsi, 0x28(%rsp) callq 0x8d0d0 movq (%rsp), %rdi movq 0x8(%rsp), %rax movl $0x9, 0x10(%rdi) movq 0x28(%rsp), %rcx movq %rcx, 0x38(%rsp) movb $0x1, 0x37(%rsp) movb $0x1, 0x36(%rsp) movb $0x1, 0x35(%rsp) movq 0x38(%rsp), %rcx movss (%rcx), %xmm0 leaq 0x34(%rsp), %rcx movq %rcx, 0x60(%rsp) movss %xmm0, 0x5c(%rsp) movss 0x5c(%rsp), %xmm0 leaq 0x40(%rsp), %rcx movq %rcx, 0x70(%rsp) movss %xmm0, 0x6c(%rsp) movq 0x70(%rsp), %rcx movss 0x6c(%rsp), %xmm0 movss %xmm0, (%rcx) movq 0x40(%rsp), %rdx movq 0x48(%rsp), %rcx movq %rdx, 0x10(%rsp) movq %rcx, 0x18(%rsp) movq 0x10(%rsp), %rcx movq %rcx, (%rdi) movq 0x18(%rsp), %rcx movq %rcx, 0x8(%rdi) addq $0x78, %rsp retq nopl (%rax,%rax)
_ZN3fmt3v106detail8make_argINS0_20basic_format_contextINS0_8appenderEcEEfEENS0_16basic_format_argIT_EERT0_: sub rsp, 78h mov [rsp+78h+var_78], rdi mov rax, rdi mov [rsp+78h+var_70], rax mov [rsp+78h+var_50], rsi call _ZN3fmt3v1016basic_format_argINS0_20basic_format_contextINS0_8appenderEcEEEC2Ev; fmt::v10::basic_format_arg<fmt::v10::basic_format_context<fmt::v10::appender,char>>::basic_format_arg(void) mov rdi, [rsp+78h+var_78] mov rax, [rsp+78h+var_70] mov dword ptr [rdi+10h], 9 mov rcx, [rsp+78h+var_50] mov [rsp+78h+var_40], rcx mov [rsp+78h+var_41], 1 mov [rsp+78h+var_42], 1 mov [rsp+78h+var_43], 1 mov rcx, [rsp+78h+var_40] movss xmm0, dword ptr [rcx] lea rcx, [rsp+78h+var_44] mov [rsp+78h+var_18], rcx movss [rsp+78h+var_1C], xmm0 movss xmm0, [rsp+78h+var_1C] lea rcx, [rsp+78h+var_38] mov [rsp+78h+var_8], rcx movss [rsp+78h+var_C], xmm0 mov rcx, [rsp+78h+var_8] movss xmm0, [rsp+78h+var_C] movss dword ptr [rcx], xmm0 mov rdx, [rsp+78h+var_38] mov rcx, [rsp+78h+var_30] mov [rsp+78h+var_68], rdx mov [rsp+78h+var_60], rcx mov rcx, [rsp+78h+var_68] mov [rdi], rcx mov rcx, [rsp+78h+var_60] mov [rdi+8], rcx add rsp, 78h retn
long long fmt::v10::detail::make_arg<fmt::v10::basic_format_context<fmt::v10::appender,char>,float>( long long a1, _DWORD *a2) { long long result; // rax long long v3; // [rsp+40h] [rbp-38h] long long v4; // [rsp+48h] [rbp-30h] fmt::v10::basic_format_arg<fmt::v10::basic_format_context<fmt::v10::appender,char>>::basic_format_arg((fmt::v10::monostate *)a1); result = a1; *(_DWORD *)(a1 + 16) = 9; LODWORD(v3) = *a2; *(_QWORD *)a1 = v3; *(_QWORD *)(a1 + 8) = v4; return result; }
make_arg<fmt::v10::basic_format_context<fmt::v10::appender,char>,float>: SUB RSP,0x78 MOV qword ptr [RSP],RDI MOV RAX,RDI MOV qword ptr [RSP + 0x8],RAX MOV qword ptr [RSP + 0x28],RSI CALL 0x0018d0d0 MOV RDI,qword ptr [RSP] MOV RAX,qword ptr [RSP + 0x8] MOV dword ptr [RDI + 0x10],0x9 MOV RCX,qword ptr [RSP + 0x28] MOV qword ptr [RSP + 0x38],RCX MOV byte ptr [RSP + 0x37],0x1 MOV byte ptr [RSP + 0x36],0x1 MOV byte ptr [RSP + 0x35],0x1 MOV RCX,qword ptr [RSP + 0x38] MOVSS XMM0,dword ptr [RCX] LEA RCX,[RSP + 0x34] MOV qword ptr [RSP + 0x60],RCX MOVSS dword ptr [RSP + 0x5c],XMM0 MOVSS XMM0,dword ptr [RSP + 0x5c] LEA RCX,[RSP + 0x40] MOV qword ptr [RSP + 0x70],RCX MOVSS dword ptr [RSP + 0x6c],XMM0 MOV RCX,qword ptr [RSP + 0x70] MOVSS XMM0,dword ptr [RSP + 0x6c] MOVSS dword ptr [RCX],XMM0 MOV RDX,qword ptr [RSP + 0x40] MOV RCX,qword ptr [RSP + 0x48] MOV qword ptr [RSP + 0x10],RDX MOV qword ptr [RSP + 0x18],RCX MOV RCX,qword ptr [RSP + 0x10] MOV qword ptr [RDI],RCX MOV RCX,qword ptr [RSP + 0x18] MOV qword ptr [RDI + 0x8],RCX ADD RSP,0x78 RET
/* fmt::v10::basic_format_arg<fmt::v10::basic_format_context<fmt::v10::appender, char> > fmt::v10::detail::make_arg<fmt::v10::basic_format_context<fmt::v10::appender, char>, float>(float&) */ detail * __thiscall fmt::v10::detail::make_arg<fmt::v10::basic_format_context<fmt::v10::appender,char>,float> (detail *this,float *param_1) { int8 local_38; int8 local_30; basic_format_arg<fmt::v10::basic_format_context<fmt::v10::appender,char>>::basic_format_arg ((basic_format_arg<fmt::v10::basic_format_context<fmt::v10::appender,char>> *)this); *(int4 *)(this + 0x10) = 9; /* WARNING: Ignoring partial resolution of indirect */ local_38._0_4_ = *param_1; *(int8 *)this = local_38; *(int8 *)(this + 8) = local_30; return this; }
47,476
bitmap_get_first
eloqsql/mysys/my_bitmap.c
uint bitmap_get_first(const MY_BITMAP *map) { uchar *byte_ptr; uint i,j,k; my_bitmap_map *data_ptr, *end= map->last_word_ptr; DBUG_ASSERT(map->bitmap); data_ptr= map->bitmap; *map->last_word_ptr|= map->last_word_mask; for (i=0; data_ptr < end; data_ptr++, i++) if (*data_ptr != 0xFFFFFFFF) goto found; if ((*data_ptr | map->last_word_mask) == 0xFFFFFFFF) return MY_BIT_NONE; found: byte_ptr= (uchar*)data_ptr; for (j=0; ; j++, byte_ptr++) { if (*byte_ptr != 0xFF) { for (k=0; ; k++) { if (!(*byte_ptr & (1 << k))) return (i*32) + (j*8) + k; } } } DBUG_ASSERT(0); return MY_BIT_NONE; /* Impossible */ }
O0
c
bitmap_get_first: pushq %rbp movq %rsp, %rbp movq %rdi, -0x10(%rbp) movq -0x10(%rbp), %rax movq 0x8(%rax), %rax movq %rax, -0x38(%rbp) jmp 0xed936 movq -0x10(%rbp), %rax movq (%rax), %rax movq %rax, -0x30(%rbp) movq -0x10(%rbp), %rax movl 0x18(%rax), %ecx movq -0x10(%rbp), %rax movq 0x8(%rax), %rax orl (%rax), %ecx movl %ecx, (%rax) movl $0x0, -0x1c(%rbp) movq -0x30(%rbp), %rax cmpq -0x38(%rbp), %rax jae 0xed989 movq -0x30(%rbp), %rax cmpl $-0x1, (%rax) je 0xed970 jmp 0xed9a6 jmp 0xed972 movq -0x30(%rbp), %rax addq $0x4, %rax movq %rax, -0x30(%rbp) movl -0x1c(%rbp), %eax addl $0x1, %eax movl %eax, -0x1c(%rbp) jmp 0xed95b movq -0x30(%rbp), %rax movl (%rax), %eax movq -0x10(%rbp), %rcx orl 0x18(%rcx), %eax cmpl $-0x1, %eax jne 0xed9a4 movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF jmp 0xeda20 jmp 0xed9a6 movq -0x30(%rbp), %rax movq %rax, -0x18(%rbp) movl $0x0, -0x20(%rbp) movq -0x18(%rbp), %rax movzbl (%rax), %eax cmpl $0xff, %eax je 0xeda07 movl $0x0, -0x24(%rbp) movq -0x18(%rbp), %rax movzbl (%rax), %eax movl -0x24(%rbp), %ecx movl $0x1, %edx shll %cl, %edx movl %edx, %ecx andl %ecx, %eax cmpl $0x0, %eax jne 0xed9fa movl -0x1c(%rbp), %eax shll $0x5, %eax movl -0x20(%rbp), %ecx shll $0x3, %ecx addl %ecx, %eax addl -0x24(%rbp), %eax movl %eax, -0x4(%rbp) jmp 0xeda20 jmp 0xed9fc movl -0x24(%rbp), %eax addl $0x1, %eax movl %eax, -0x24(%rbp) jmp 0xed9ca jmp 0xeda09 movl -0x20(%rbp), %eax addl $0x1, %eax movl %eax, -0x20(%rbp) movq -0x18(%rbp), %rax addq $0x1, %rax movq %rax, -0x18(%rbp) jmp 0xed9b5 movl -0x4(%rbp), %eax popq %rbp retq nopw %cs:(%rax,%rax)
bitmap_get_first: push rbp mov rbp, rsp mov [rbp+var_10], rdi mov rax, [rbp+var_10] mov rax, [rax+8] mov [rbp+var_38], rax jmp short $+2 loc_ED936: mov rax, [rbp+var_10] mov rax, [rax] mov [rbp+var_30], rax mov rax, [rbp+var_10] mov ecx, [rax+18h] mov rax, [rbp+var_10] mov rax, [rax+8] or ecx, [rax] mov [rax], ecx mov [rbp+var_1C], 0 loc_ED95B: mov rax, [rbp+var_30] cmp rax, [rbp+var_38] jnb short loc_ED989 mov rax, [rbp+var_30] cmp dword ptr [rax], 0FFFFFFFFh jz short loc_ED970 jmp short loc_ED9A6 loc_ED970: jmp short $+2 loc_ED972: mov rax, [rbp+var_30] add rax, 4 mov [rbp+var_30], rax mov eax, [rbp+var_1C] add eax, 1 mov [rbp+var_1C], eax jmp short loc_ED95B loc_ED989: mov rax, [rbp+var_30] mov eax, [rax] mov rcx, [rbp+var_10] or eax, [rcx+18h] cmp eax, 0FFFFFFFFh jnz short loc_ED9A4 mov [rbp+var_4], 0FFFFFFFFh jmp short loc_EDA20 loc_ED9A4: jmp short $+2 loc_ED9A6: mov rax, [rbp+var_30] mov [rbp+var_18], rax mov [rbp+var_20], 0 loc_ED9B5: mov rax, [rbp+var_18] movzx eax, byte ptr [rax] cmp eax, 0FFh jz short loc_EDA07 mov [rbp+var_24], 0 loc_ED9CA: mov rax, [rbp+var_18] movzx eax, byte ptr [rax] mov ecx, [rbp+var_24] mov edx, 1 shl edx, cl mov ecx, edx and eax, ecx cmp eax, 0 jnz short loc_ED9FA mov eax, [rbp+var_1C] shl eax, 5 mov ecx, [rbp+var_20] shl ecx, 3 add eax, ecx add eax, [rbp+var_24] mov [rbp+var_4], eax jmp short loc_EDA20 loc_ED9FA: jmp short $+2 loc_ED9FC: mov eax, [rbp+var_24] add eax, 1 mov [rbp+var_24], eax jmp short loc_ED9CA loc_EDA07: jmp short $+2 loc_EDA09: mov eax, [rbp+var_20] add eax, 1 mov [rbp+var_20], eax mov rax, [rbp+var_18] add rax, 1 mov [rbp+var_18], rax jmp short loc_ED9B5 loc_EDA20: mov eax, [rbp+var_4] pop rbp retn
long long bitmap_get_first(long long a1) { unsigned __int8 *v2; // [rsp+0h] [rbp-38h] unsigned __int8 *v3; // [rsp+8h] [rbp-30h] int i; // [rsp+14h] [rbp-24h] int v5; // [rsp+18h] [rbp-20h] int v6; // [rsp+1Ch] [rbp-1Ch] unsigned __int8 *v7; // [rsp+20h] [rbp-18h] v2 = *(unsigned __int8 **)(a1 + 8); v3 = *(unsigned __int8 **)a1; *(_DWORD *)v2 |= *(_DWORD *)(a1 + 24); v6 = 0; while ( v3 < v2 ) { if ( *(_DWORD *)v3 != -1 ) goto LABEL_7; v3 += 4; ++v6; } if ( (*(_DWORD *)(a1 + 24) | *(_DWORD *)v3) == -1 ) return (unsigned int)-1; LABEL_7: v7 = v3; v5 = 0; while ( *v7 == 255 ) { ++v5; ++v7; } for ( i = 0; ((1 << i) & *v7) != 0; ++i ) ; return (unsigned int)(i + 8 * v5 + 32 * v6); }
bitmap_get_first: PUSH RBP MOV RBP,RSP MOV qword ptr [RBP + -0x10],RDI MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x8] MOV qword ptr [RBP + -0x38],RAX JMP 0x001ed936 LAB_001ed936: MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX] MOV qword ptr [RBP + -0x30],RAX MOV RAX,qword ptr [RBP + -0x10] MOV ECX,dword ptr [RAX + 0x18] MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x8] OR ECX,dword ptr [RAX] MOV dword ptr [RAX],ECX MOV dword ptr [RBP + -0x1c],0x0 LAB_001ed95b: MOV RAX,qword ptr [RBP + -0x30] CMP RAX,qword ptr [RBP + -0x38] JNC 0x001ed989 MOV RAX,qword ptr [RBP + -0x30] CMP dword ptr [RAX],-0x1 JZ 0x001ed970 JMP 0x001ed9a6 LAB_001ed970: JMP 0x001ed972 LAB_001ed972: MOV RAX,qword ptr [RBP + -0x30] ADD RAX,0x4 MOV qword ptr [RBP + -0x30],RAX MOV EAX,dword ptr [RBP + -0x1c] ADD EAX,0x1 MOV dword ptr [RBP + -0x1c],EAX JMP 0x001ed95b LAB_001ed989: MOV RAX,qword ptr [RBP + -0x30] MOV EAX,dword ptr [RAX] MOV RCX,qword ptr [RBP + -0x10] OR EAX,dword ptr [RCX + 0x18] CMP EAX,-0x1 JNZ 0x001ed9a4 MOV dword ptr [RBP + -0x4],0xffffffff JMP 0x001eda20 LAB_001ed9a4: JMP 0x001ed9a6 LAB_001ed9a6: MOV RAX,qword ptr [RBP + -0x30] MOV qword ptr [RBP + -0x18],RAX MOV dword ptr [RBP + -0x20],0x0 LAB_001ed9b5: MOV RAX,qword ptr [RBP + -0x18] MOVZX EAX,byte ptr [RAX] CMP EAX,0xff JZ 0x001eda07 MOV dword ptr [RBP + -0x24],0x0 LAB_001ed9ca: MOV RAX,qword ptr [RBP + -0x18] MOVZX EAX,byte ptr [RAX] MOV ECX,dword ptr [RBP + -0x24] MOV EDX,0x1 SHL EDX,CL MOV ECX,EDX AND EAX,ECX CMP EAX,0x0 JNZ 0x001ed9fa MOV EAX,dword ptr [RBP + -0x1c] SHL EAX,0x5 MOV ECX,dword ptr [RBP + -0x20] SHL ECX,0x3 ADD EAX,ECX ADD EAX,dword ptr [RBP + -0x24] MOV dword ptr [RBP + -0x4],EAX JMP 0x001eda20 LAB_001ed9fa: JMP 0x001ed9fc LAB_001ed9fc: MOV EAX,dword ptr [RBP + -0x24] ADD EAX,0x1 MOV dword ptr [RBP + -0x24],EAX JMP 0x001ed9ca LAB_001eda07: JMP 0x001eda09 LAB_001eda09: MOV EAX,dword ptr [RBP + -0x20] ADD EAX,0x1 MOV dword ptr [RBP + -0x20],EAX MOV RAX,qword ptr [RBP + -0x18] ADD RAX,0x1 MOV qword ptr [RBP + -0x18],RAX JMP 0x001ed9b5 LAB_001eda20: MOV EAX,dword ptr [RBP + -0x4] POP RBP RET
int bitmap_get_first(int8 *param_1) { uint *puVar1; uint *local_38; int local_2c; int local_28; int local_24; uint *local_20; int local_c; puVar1 = (uint *)param_1[1]; local_38 = (uint *)*param_1; *(uint *)param_1[1] = *(uint *)(param_1 + 3) | *(uint *)param_1[1]; local_24 = 0; for (; local_38 < puVar1; local_38 = local_38 + 1) { if (*local_38 != 0xffffffff) goto LAB_001ed9a6; local_24 = local_24 + 1; } if ((*local_38 | *(uint *)(param_1 + 3)) == 0xffffffff) { local_c = -1; } else { LAB_001ed9a6: local_28 = 0; for (local_20 = local_38; (byte)*local_20 == 0xff; local_20 = (uint *)((long)local_20 + 1)) { local_28 = local_28 + 1; } local_2c = 0; while (((uint)(byte)*local_20 & 1 << ((byte)local_2c & 0x1f)) != 0) { local_2c = local_2c + 1; } local_c = local_24 * 0x20 + local_28 * 8 + local_2c; } return local_c; }
47,477
psi_rwlock_tryrdlock
eloqsql/mysys/my_thr_init.c
ATTRIBUTE_COLD int psi_rwlock_tryrdlock(mysql_rwlock_t *that, const char *file, uint line) { PSI_rwlock_locker_state state; PSI_rwlock_locker *locker= PSI_RWLOCK_CALL(start_rwlock_rdwait) (&state, that->m_psi, PSI_RWLOCK_TRYREADLOCK, file, line); int result= rw_tryrdlock(&that->m_rwlock); if (locker) PSI_RWLOCK_CALL(end_rwlock_rdwait)(locker, result); return result; }
O0
c
psi_rwlock_tryrdlock: pushq %rbp movq %rsp, %rbp subq $0x60, %rsp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movl %edx, -0x14(%rbp) leaq 0x1ad72e(%rip), %rax # 0x1da0f8 movq (%rax), %rax movq 0x1a0(%rax), %rax movq -0x8(%rbp), %rcx movq 0x90(%rcx), %rsi movq -0x10(%rbp), %rcx movl -0x14(%rbp), %r8d leaq -0x48(%rbp), %rdi movl $0x2, %edx callq *%rax movq %rax, -0x50(%rbp) movq -0x8(%rbp), %rdi callq 0x2cfc0 movl %eax, -0x54(%rbp) cmpq $0x0, -0x50(%rbp) je 0x2ca23 leaq 0x1ad6e8(%rip), %rax # 0x1da0f8 movq (%rax), %rax movq 0x1a8(%rax), %rax movq -0x50(%rbp), %rdi movl -0x54(%rbp), %esi callq *%rax movl -0x54(%rbp), %eax addq $0x60, %rsp popq %rbp retq nopl (%rax)
psi_rwlock_tryrdlock: push rbp mov rbp, rsp sub rsp, 60h mov [rbp+var_8], rdi mov [rbp+var_10], rsi mov [rbp+var_14], edx lea rax, PSI_server mov rax, [rax] mov rax, [rax+1A0h] mov rcx, [rbp+var_8] mov rsi, [rcx+90h] mov rcx, [rbp+var_10] mov r8d, [rbp+var_14] lea rdi, [rbp+var_48] mov edx, 2 call rax mov [rbp+var_50], rax mov rdi, [rbp+var_8] call my_rw_tryrdlock mov [rbp+var_54], eax cmp [rbp+var_50], 0 jz short loc_2CA23 lea rax, PSI_server mov rax, [rax] mov rax, [rax+1A8h] mov rdi, [rbp+var_50] mov esi, [rbp+var_54] call rax loc_2CA23: mov eax, [rbp+var_54] add rsp, 60h pop rbp retn
long long psi_rwlock_tryrdlock(long long a1, long long a2, unsigned int a3) { unsigned int v4; // [rsp+Ch] [rbp-54h] long long v5; // [rsp+10h] [rbp-50h] _BYTE v6[52]; // [rsp+18h] [rbp-48h] BYREF unsigned int v7; // [rsp+4Ch] [rbp-14h] long long v8; // [rsp+50h] [rbp-10h] long long v9; // [rsp+58h] [rbp-8h] v9 = a1; v8 = a2; v7 = a3; v5 = (*((long long ( **)(_BYTE *, _QWORD, long long, long long, _QWORD))PSI_server[0] + 52))( v6, *(_QWORD *)(a1 + 144), 2LL, a2, a3); v4 = my_rw_tryrdlock(v9); if ( v5 ) (*((void ( **)(long long, _QWORD))PSI_server[0] + 53))(v5, v4); return v4; }
psi_rwlock_tryrdlock: PUSH RBP MOV RBP,RSP SUB RSP,0x60 MOV qword ptr [RBP + -0x8],RDI MOV qword ptr [RBP + -0x10],RSI MOV dword ptr [RBP + -0x14],EDX LEA RAX,[0x2da0f8] MOV RAX,qword ptr [RAX] MOV RAX,qword ptr [RAX + 0x1a0] MOV RCX,qword ptr [RBP + -0x8] MOV RSI,qword ptr [RCX + 0x90] MOV RCX,qword ptr [RBP + -0x10] MOV R8D,dword ptr [RBP + -0x14] LEA RDI,[RBP + -0x48] MOV EDX,0x2 CALL RAX MOV qword ptr [RBP + -0x50],RAX MOV RDI,qword ptr [RBP + -0x8] CALL 0x0012cfc0 MOV dword ptr [RBP + -0x54],EAX CMP qword ptr [RBP + -0x50],0x0 JZ 0x0012ca23 LEA RAX,[0x2da0f8] MOV RAX,qword ptr [RAX] MOV RAX,qword ptr [RAX + 0x1a8] MOV RDI,qword ptr [RBP + -0x50] MOV ESI,dword ptr [RBP + -0x54] CALL RAX LAB_0012ca23: MOV EAX,dword ptr [RBP + -0x54] ADD RSP,0x60 POP RBP RET
int4 psi_rwlock_tryrdlock(long param_1,int8 param_2,int4 param_3) { int4 uVar1; long lVar2; int1 local_50 [52]; int4 local_1c; int8 local_18; long local_10; local_1c = param_3; local_18 = param_2; local_10 = param_1; lVar2 = (**(code **)(PSI_server + 0x1a0)) (local_50,*(int8 *)(param_1 + 0x90),2,param_2,param_3); uVar1 = my_rw_tryrdlock(local_10); if (lVar2 != 0) { (**(code **)(PSI_server + 0x1a8))(lVar2,uVar1); } return uVar1; }
47,478
write_keys_varlen
eloqsql/storage/maria/ma_sort.c
static int write_keys_varlen(MARIA_SORT_PARAM *info, register uchar **sort_keys, ha_keys count, BUFFPEK *buffpek, IO_CACHE *tempfile) { uchar **end; int err; DBUG_ENTER("write_keys_varlen"); if (!buffpek) DBUG_RETURN(1); /* Out of memory */ my_qsort2((uchar*) sort_keys, (size_t) count, sizeof(uchar*), (qsort2_cmp) info->key_cmp, info); if (!my_b_inited(tempfile) && open_cached_file(tempfile, my_tmpdir(info->tmpdir), "ST", DISK_BUFFER_SIZE, info->sort_info->param->myf_rw)) DBUG_RETURN(1); /* purecov: inspected */ buffpek->file_pos=my_b_tell(tempfile); buffpek->count=count; for (end=sort_keys+count ; sort_keys != end ; sort_keys++) { if ((err= my_var_write(info,tempfile, *sort_keys))) DBUG_RETURN(err); } DBUG_RETURN(0); }
O3
c
write_keys_varlen: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x28, %rsp movl $0x1, %r13d testq %rcx, %rcx je 0x84539 movq %r8, %rbx movq %rcx, %r15 movq %rdx, %r14 movq %rdi, %r12 movq 0x668(%rdi), %rcx movl $0x8, %edx movq %rsi, -0x38(%rbp) movq %rsi, %rdi movq %r14, %rsi movq %r12, %r8 callq 0xb857c cmpq $0x0, 0x20(%rbx) je 0x844f3 movq %r12, -0x48(%rbp) leaq 0x10(%rbx), %rax cmpl $0x2, 0xb0(%rbx) leaq 0x40(%rbx), %rcx movq (%rbx), %rdx cmoveq %rcx, %rax subq 0x28(%rbx), %rdx addq (%rax), %rdx movq %rdx, (%r15) movq %r14, 0x18(%r15) testq %r14, %r14 je 0x844ee movq %r14, %rax movq -0x38(%rbp), %r14 shlq $0x3, %rax movq %rax, -0x40(%rbp) xorl %r12d, %r12d movq (%r14,%r12), %r15 movq -0x48(%rbp), %rax movq 0x378(%rax), %rdi movq %r15, %rsi callq 0x5ea54 movw %ax, -0x2a(%rbp) movq 0x40(%rbx), %rcx leaq 0x2(%rcx), %rdx cmpq 0x48(%rbx), %rdx jbe 0x84497 movl $0x2, %edx movq %rbx, %rdi leaq -0x2a(%rbp), %rsi callq 0xb10ff testl %eax, %eax jne 0x84536 movzwl -0x2a(%rbp), %eax movq 0x40(%rbx), %rdi jmp 0x844aa movzwl -0x2a(%rbp), %edx movw %dx, (%rcx) movq 0x40(%rbx), %rdi addq $0x2, %rdi movq %rdi, 0x40(%rbx) movzwl %ax, %r13d leaq (%rdi,%r13), %rax cmpq 0x48(%rbx), %rax jbe 0x844cc movq %rbx, %rdi movq %r15, %rsi movq %r13, %rdx callq 0xb10ff testl %eax, %eax je 0x844e0 jmp 0x84536 testq %r13, %r13 je 0x844e0 movq %r15, %rsi movq %r13, %rdx callq 0x2a0b0 addq %r13, 0x40(%rbx) addq $0x8, %r12 cmpq %r12, -0x40(%rbp) jne 0x8444b xorl %r13d, %r13d jmp 0x84539 movq 0x3f8(%r12), %rdi callq 0xb90fe movq 0x380(%r12), %rcx movq 0x90(%rcx), %rcx movq 0x20998(%rcx), %r8 leaq 0x79ae0(%rip), %rdx # 0xfdffd movl $0x80000, %ecx # imm = 0x80000 movq %rbx, %rdi movq %rax, %rsi callq 0xb0044 testb %al, %al jne 0x84539 jmp 0x84408 movl %eax, %r13d movl %r13d, %eax addq $0x28, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
write_keys_varlen: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx sub rsp, 28h mov r13d, 1 test rcx, rcx jz loc_84539 mov rbx, r8 mov r15, rcx mov r14, rdx mov r12, rdi mov rcx, [rdi+668h] mov edx, 8 mov [rbp+var_38], rsi mov rdi, rsi mov rsi, r14 mov r8, r12 call my_qsort2 cmp qword ptr [rbx+20h], 0 jz loc_844F3 loc_84408: mov [rbp+var_48], r12 lea rax, [rbx+10h] cmp dword ptr [rbx+0B0h], 2 lea rcx, [rbx+40h] mov rdx, [rbx] cmovz rax, rcx sub rdx, [rbx+28h] add rdx, [rax] mov [r15], rdx mov [r15+18h], r14 test r14, r14 jz loc_844EE mov rax, r14 mov r14, [rbp+var_38] shl rax, 3 mov [rbp+var_40], rax xor r12d, r12d loc_8444B: mov r15, [r14+r12] mov rax, [rbp+var_48] mov rdi, [rax+378h] mov rsi, r15 call _ma_keylength mov [rbp+var_2A], ax mov rcx, [rbx+40h] lea rdx, [rcx+2] cmp rdx, [rbx+48h] jbe short loc_84497 mov edx, 2 mov rdi, rbx lea rsi, [rbp+var_2A] call _my_b_write test eax, eax jnz loc_84536 movzx eax, [rbp+var_2A] mov rdi, [rbx+40h] jmp short loc_844AA loc_84497: movzx edx, [rbp+var_2A] mov [rcx], dx mov rdi, [rbx+40h] add rdi, 2 mov [rbx+40h], rdi loc_844AA: movzx r13d, ax lea rax, [rdi+r13] cmp rax, [rbx+48h] jbe short loc_844CC mov rdi, rbx mov rsi, r15 mov rdx, r13 call _my_b_write test eax, eax jz short loc_844E0 jmp short loc_84536 loc_844CC: test r13, r13 jz short loc_844E0 mov rsi, r15 mov rdx, r13 call _memcpy add [rbx+40h], r13 loc_844E0: add r12, 8 cmp [rbp+var_40], r12 jnz loc_8444B loc_844EE: xor r13d, r13d jmp short loc_84539 loc_844F3: mov rdi, [r12+3F8h] call my_tmpdir mov rcx, [r12+380h] mov rcx, [rcx+90h] mov r8, [rcx+20998h] lea rdx, aSt; "ST" mov ecx, 80000h mov rdi, rbx mov rsi, rax call open_cached_file test al, al jnz short loc_84539 jmp loc_84408 loc_84536: mov r13d, eax loc_84539: mov eax, r13d add rsp, 28h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
long long write_keys_varlen(long long *a1, long long a2, long long a3, _QWORD *a4, long long a5) { unsigned int v5; // r13d _QWORD *v9; // rax long long i; // r12 unsigned __int8 *v11; // r15 unsigned __int16 v12; // ax _WORD *v13; // rcx unsigned int v14; // eax long long v15; // rdi long long v16; // r13 long long v17; // rax _WORD v20[21]; // [rsp+26h] [rbp-2Ah] BYREF v5 = 1; if ( a4 ) { my_qsort2(a2, a3, 8LL, a1[205], a1); if ( *(_QWORD *)(a5 + 32) || (v17 = my_tmpdir(a1[127]), !(unsigned __int8)open_cached_file( a5, v17, "ST", 0x80000LL, *(_QWORD *)(*(_QWORD *)(a1[112] + 144) + 133528LL))) ) { v9 = (_QWORD *)(a5 + 16); if ( *(_DWORD *)(a5 + 176) == 2 ) v9 = (_QWORD *)(a5 + 64); *a4 = *v9 + *(_QWORD *)a5 - *(_QWORD *)(a5 + 40); a4[3] = a3; if ( a3 ) { for ( i = 0LL; 8 * a3 != i; i += 8LL ) { v11 = *(unsigned __int8 **)(a2 + i); v12 = ma_keylength(a1[111], v11); v20[0] = v12; v13 = *(_WORD **)(a5 + 64); if ( (unsigned long long)(v13 + 1) <= *(_QWORD *)(a5 + 72) ) { *v13 = v20[0]; v15 = *(_QWORD *)(a5 + 64) + 2LL; *(_QWORD *)(a5 + 64) = v15; } else { v14 = my_b_write(a5, v20, 2LL); if ( v14 ) return v14; v12 = v20[0]; v15 = *(_QWORD *)(a5 + 64); } v16 = v12; if ( v15 + (unsigned long long)v12 <= *(_QWORD *)(a5 + 72) ) { if ( v12 ) { memcpy(v15, v11, v12); *(_QWORD *)(a5 + 64) += v16; } } else { v14 = my_b_write(a5, v11, v12); if ( v14 ) return v14; } } } return 0; } } return v5; }
write_keys_varlen: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x28 MOV R13D,0x1 TEST RCX,RCX JZ 0x00184539 MOV RBX,R8 MOV R15,RCX MOV R14,RDX MOV R12,RDI MOV RCX,qword ptr [RDI + 0x668] MOV EDX,0x8 MOV qword ptr [RBP + -0x38],RSI MOV RDI,RSI MOV RSI,R14 MOV R8,R12 CALL 0x001b857c CMP qword ptr [RBX + 0x20],0x0 JZ 0x001844f3 LAB_00184408: MOV qword ptr [RBP + -0x48],R12 LEA RAX,[RBX + 0x10] CMP dword ptr [RBX + 0xb0],0x2 LEA RCX,[RBX + 0x40] MOV RDX,qword ptr [RBX] CMOVZ RAX,RCX SUB RDX,qword ptr [RBX + 0x28] ADD RDX,qword ptr [RAX] MOV qword ptr [R15],RDX MOV qword ptr [R15 + 0x18],R14 TEST R14,R14 JZ 0x001844ee MOV RAX,R14 MOV R14,qword ptr [RBP + -0x38] SHL RAX,0x3 MOV qword ptr [RBP + -0x40],RAX XOR R12D,R12D LAB_0018444b: MOV R15,qword ptr [R14 + R12*0x1] MOV RAX,qword ptr [RBP + -0x48] MOV RDI,qword ptr [RAX + 0x378] MOV RSI,R15 CALL 0x0015ea54 MOV word ptr [RBP + -0x2a],AX MOV RCX,qword ptr [RBX + 0x40] LEA RDX,[RCX + 0x2] CMP RDX,qword ptr [RBX + 0x48] JBE 0x00184497 MOV EDX,0x2 MOV RDI,RBX LEA RSI,[RBP + -0x2a] CALL 0x001b10ff TEST EAX,EAX JNZ 0x00184536 MOVZX EAX,word ptr [RBP + -0x2a] MOV RDI,qword ptr [RBX + 0x40] JMP 0x001844aa LAB_00184497: MOVZX EDX,word ptr [RBP + -0x2a] MOV word ptr [RCX],DX MOV RDI,qword ptr [RBX + 0x40] ADD RDI,0x2 MOV qword ptr [RBX + 0x40],RDI LAB_001844aa: MOVZX R13D,AX LEA RAX,[RDI + R13*0x1] CMP RAX,qword ptr [RBX + 0x48] JBE 0x001844cc MOV RDI,RBX MOV RSI,R15 MOV RDX,R13 CALL 0x001b10ff TEST EAX,EAX JZ 0x001844e0 JMP 0x00184536 LAB_001844cc: TEST R13,R13 JZ 0x001844e0 MOV RSI,R15 MOV RDX,R13 CALL 0x0012a0b0 ADD qword ptr [RBX + 0x40],R13 LAB_001844e0: ADD R12,0x8 CMP qword ptr [RBP + -0x40],R12 JNZ 0x0018444b LAB_001844ee: XOR R13D,R13D JMP 0x00184539 LAB_001844f3: MOV RDI,qword ptr [R12 + 0x3f8] CALL 0x001b90fe MOV RCX,qword ptr [R12 + 0x380] MOV RCX,qword ptr [RCX + 0x90] MOV R8,qword ptr [RCX + 0x20998] LEA RDX,[0x1fdffd] MOV ECX,0x80000 MOV RDI,RBX MOV RSI,RAX CALL 0x001b0044 TEST AL,AL JNZ 0x00184539 JMP 0x00184408 LAB_00184536: MOV R13D,EAX LAB_00184539: MOV EAX,R13D ADD RSP,0x28 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
int write_keys_varlen(long param_1,long param_2,long param_3,long *param_4,long *param_5) { void *__src; char cVar1; int iVar2; long *plVar3; int8 uVar4; void *__dest; long lVar5; ulong __n; ushort local_32; iVar2 = 1; if (param_4 != (long *)0x0) { my_qsort2(param_2,param_3,8,*(int8 *)(param_1 + 0x668),param_1); if (param_5[4] == 0) { uVar4 = my_tmpdir(*(int8 *)(param_1 + 0x3f8)); cVar1 = open_cached_file(param_5,uVar4,&DAT_001fdffd,0x80000, *(int8 *) (*(long *)(*(long *)(param_1 + 0x380) + 0x90) + 0x20998)); if (cVar1 != '\0') { return 1; } } plVar3 = param_5 + 2; if ((int)param_5[0x16] == 2) { plVar3 = param_5 + 8; } *param_4 = (*param_5 - param_5[5]) + *plVar3; param_4[3] = param_3; if (param_3 != 0) { lVar5 = 0; do { __src = *(void **)(param_2 + lVar5); local_32 = _ma_keylength(*(int8 *)(param_1 + 0x378),__src); if ((ushort *)param_5[9] < (ushort *)param_5[8] + 1) { iVar2 = _my_b_write(param_5,&local_32,2); if (iVar2 != 0) { return iVar2; } __dest = (void *)param_5[8]; } else { *(ushort *)param_5[8] = local_32; __dest = (void *)(param_5[8] + 2); param_5[8] = (long)__dest; } __n = (ulong)local_32; if ((ulong)param_5[9] < (long)__dest + __n) { iVar2 = _my_b_write(param_5,__src,__n); if (iVar2 != 0) { return iVar2; } } else if (__n != 0) { memcpy(__dest,__src,__n); param_5[8] = param_5[8] + __n; } lVar5 = lVar5 + 8; } while (param_3 << 3 != lVar5); } iVar2 = 0; } return iVar2; }
47,479
mi_cmp_dynamic_record
eloqsql/storage/myisam/mi_dynrec.c
int _mi_cmp_dynamic_record(register MI_INFO *info, register const uchar *record) { uint flag,reclength,b_type; my_off_t filepos; uchar *buffer; MI_BLOCK_INFO block_info; DBUG_ENTER("_mi_cmp_dynamic_record"); if (info->opt_flag & WRITE_CACHE_USED) { info->update&= ~(HA_STATE_WRITE_AT_END | HA_STATE_EXTEND_BLOCK); if (flush_io_cache(&info->rec_cache)) DBUG_RETURN(-1); } info->rec_cache.seek_not_done=1; /* If nobody have touched the database we don't have to test rec */ buffer=info->rec_buff; if ((info->opt_flag & READ_CHECK_USED)) { /* If check isn't disabled */ if (info->s->base.blobs) { if (!(buffer=(uchar*) my_alloca(info->s->base.pack_reclength+ _mi_calc_total_blob_length(info,record)))) DBUG_RETURN(-1); } reclength=_mi_rec_pack(info,buffer,record); record= buffer; filepos=info->lastpos; flag=block_info.second_read=0; block_info.next_filepos=filepos; while (reclength > 0) { if ((b_type=_mi_get_block_info(&block_info,info->dfile, block_info.next_filepos)) & (BLOCK_DELETED | BLOCK_ERROR | BLOCK_SYNC_ERROR | BLOCK_FATAL_ERROR)) { if (b_type & (BLOCK_SYNC_ERROR | BLOCK_DELETED)) my_errno=HA_ERR_RECORD_CHANGED; goto err; } if (flag == 0) /* First block */ { flag=1; if (reclength != block_info.rec_len) { my_errno=HA_ERR_RECORD_CHANGED; goto err; } } else if (reclength < block_info.data_len) { my_errno=HA_ERR_WRONG_IN_RECORD; goto err; } reclength-=block_info.data_len; if (_mi_cmp_buffer(info->dfile,record,block_info.filepos, block_info.data_len)) { my_errno=HA_ERR_RECORD_CHANGED; goto err; } flag=1; record+=block_info.data_len; } } my_errno=0; err: if (buffer != info->rec_buff) my_afree((uchar*) buffer); DBUG_RETURN(my_errno); }
O0
c
mi_cmp_dynamic_record: pushq %rbp movq %rsp, %rbp subq $0xb0, %rsp movq %fs:0x28, %rax movq %rax, -0x8(%rbp) movq %rdi, -0x70(%rbp) movq %rsi, -0x78(%rbp) movq -0x70(%rbp), %rax movl 0x1c8(%rax), %eax andl $0x10, %eax cmpl $0x0, %eax je 0xabdc2 movq -0x70(%rbp), %rax movl 0x1d0(%rax), %ecx andl $0xfffff6ff, %ecx # imm = 0xFFFFF6FF movl %ecx, 0x1d0(%rax) movq -0x70(%rbp), %rdi addq $0x220, %rdi # imm = 0x220 movl $0x1, %esi callq 0xe0be0 cmpl $0x0, %eax je 0xabdc0 jmp 0xabdb4 movl $0xffffffff, -0x64(%rbp) # imm = 0xFFFFFFFF jmp 0xabfc0 jmp 0xabdc2 movq -0x70(%rbp), %rax movl $0x1, 0x300(%rax) movq -0x70(%rbp), %rax movq 0x120(%rax), %rax movq %rax, -0x98(%rbp) movq -0x70(%rbp), %rax movl 0x1c8(%rax), %eax andl $0x4, %eax cmpl $0x0, %eax je 0xabf89 movq -0x70(%rbp), %rax movq (%rax), %rax cmpl $0x0, 0x188(%rax) je 0xabe5c movq -0x70(%rbp), %rax movq (%rax), %rax movq 0x148(%rax), %rax movq %rax, -0xa0(%rbp) movq -0x70(%rbp), %rdi movq -0x78(%rbp), %rsi callq 0xa88d0 movq -0xa0(%rbp), %rsi addq %rax, %rsi xorl %edi, %edi xorl %eax, %eax movl %eax, %edx callq 0xf3860 movq %rax, -0x98(%rbp) cmpq $0x0, %rax jne 0xabe5a jmp 0xabe4e movl $0xffffffff, -0x64(%rbp) # imm = 0xFFFFFFFF jmp 0xabfc0 jmp 0xabe5c movq -0x70(%rbp), %rdi movq -0x98(%rbp), %rsi movq -0x78(%rbp), %rdx callq 0xa7940 movl %eax, -0x80(%rbp) movq -0x98(%rbp), %rax movq %rax, -0x78(%rbp) movq -0x70(%rbp), %rax movq 0x170(%rax), %rax movq %rax, -0x90(%rbp) movl $0x0, -0x10(%rbp) movl $0x0, -0x7c(%rbp) movq -0x90(%rbp), %rax movq %rax, -0x20(%rbp) cmpl $0x0, -0x80(%rbp) jbe 0xabf87 movq -0x70(%rbp), %rax movl 0x1c0(%rax), %esi movq -0x20(%rbp), %rdx leaq -0x60(%rbp), %rdi callq 0xa9d10 movl %eax, -0x84(%rbp) andl $0x3c, %eax cmpl $0x0, %eax je 0xabef6 movl -0x84(%rbp), %eax andl $0x14, %eax cmpl $0x0, %eax je 0xabef1 callq 0xf60c0 movl $0x7b, (%rax) jmp 0xabf94 cmpl $0x0, -0x7c(%rbp) jne 0xabf1b movl $0x1, -0x7c(%rbp) movl -0x80(%rbp), %eax cmpq -0x48(%rbp), %rax je 0xabf19 callq 0xf60c0 movl $0x7b, (%rax) jmp 0xabf94 jmp 0xabf33 movl -0x80(%rbp), %eax cmpq -0x40(%rbp), %rax jae 0xabf31 callq 0xf60c0 movl $0x7f, (%rax) jmp 0xabf94 jmp 0xabf33 movq -0x40(%rbp), %rcx movl -0x80(%rbp), %eax subq %rcx, %rax movl %eax, -0x80(%rbp) movq -0x70(%rbp), %rax movl 0x1c0(%rax), %edi movq -0x78(%rbp), %rsi movq -0x28(%rbp), %rdx movq -0x40(%rbp), %rax movl %eax, %ecx callq 0xabff0 cmpl $0x0, %eax je 0xabf6f callq 0xf60c0 movl $0x7b, (%rax) jmp 0xabf94 movl $0x1, -0x7c(%rbp) movq -0x40(%rbp), %rax addq -0x78(%rbp), %rax movq %rax, -0x78(%rbp) jmp 0xabea9 jmp 0xabf89 callq 0xf60c0 movl $0x0, (%rax) movq -0x98(%rbp), %rax movq -0x70(%rbp), %rcx cmpq 0x120(%rcx), %rax je 0xabfb4 movq -0x98(%rbp), %rdi callq 0xf3be0 jmp 0xabfb6 callq 0xf60c0 movl (%rax), %eax movl %eax, -0x64(%rbp) movl -0x64(%rbp), %eax movl %eax, -0xa4(%rbp) movq %fs:0x28, %rax movq -0x8(%rbp), %rcx cmpq %rcx, %rax jne 0xabfea movl -0xa4(%rbp), %eax addq $0xb0, %rsp popq %rbp retq callq 0x2a270 nop
_mi_cmp_dynamic_record: push rbp mov rbp, rsp sub rsp, 0B0h mov rax, fs:28h mov [rbp+var_8], rax mov [rbp+var_70], rdi mov [rbp+var_78], rsi mov rax, [rbp+var_70] mov eax, [rax+1C8h] and eax, 10h cmp eax, 0 jz short loc_ABDC2 mov rax, [rbp+var_70] mov ecx, [rax+1D0h] and ecx, 0FFFFF6FFh mov [rax+1D0h], ecx mov rdi, [rbp+var_70] add rdi, 220h mov esi, 1 call my_b_flush_io_cache cmp eax, 0 jz short loc_ABDC0 jmp short $+2 loc_ABDB4: mov [rbp+var_64], 0FFFFFFFFh jmp loc_ABFC0 loc_ABDC0: jmp short $+2 loc_ABDC2: mov rax, [rbp+var_70] mov dword ptr [rax+300h], 1 mov rax, [rbp+var_70] mov rax, [rax+120h] mov [rbp+var_98], rax mov rax, [rbp+var_70] mov eax, [rax+1C8h] and eax, 4 cmp eax, 0 jz loc_ABF89 mov rax, [rbp+var_70] mov rax, [rax] cmp dword ptr [rax+188h], 0 jz short loc_ABE5C mov rax, [rbp+var_70] mov rax, [rax] mov rax, [rax+148h] mov [rbp+var_A0], rax mov rdi, [rbp+var_70] mov rsi, [rbp+var_78] call _mi_calc_total_blob_length mov rsi, [rbp+var_A0] add rsi, rax xor edi, edi xor eax, eax mov edx, eax call my_malloc mov [rbp+var_98], rax cmp rax, 0 jnz short loc_ABE5A jmp short $+2 loc_ABE4E: mov [rbp+var_64], 0FFFFFFFFh jmp loc_ABFC0 loc_ABE5A: jmp short $+2 loc_ABE5C: mov rdi, [rbp+var_70] mov rsi, [rbp+var_98] mov rdx, [rbp+var_78] call _mi_rec_pack mov [rbp+var_80], eax mov rax, [rbp+var_98] mov [rbp+var_78], rax mov rax, [rbp+var_70] mov rax, [rax+170h] mov [rbp+var_90], rax mov [rbp+var_10], 0 mov [rbp+var_7C], 0 mov rax, [rbp+var_90] mov [rbp+var_20], rax loc_ABEA9: cmp [rbp+var_80], 0 jbe loc_ABF87 mov rax, [rbp+var_70] mov esi, [rax+1C0h] mov rdx, [rbp+var_20] lea rdi, [rbp+var_60] call _mi_get_block_info mov [rbp+var_84], eax and eax, 3Ch cmp eax, 0 jz short loc_ABEF6 mov eax, [rbp+var_84] and eax, 14h cmp eax, 0 jz short loc_ABEF1 call _my_thread_var mov dword ptr [rax], 7Bh ; '{' loc_ABEF1: jmp loc_ABF94 loc_ABEF6: cmp [rbp+var_7C], 0 jnz short loc_ABF1B mov [rbp+var_7C], 1 mov eax, [rbp+var_80] cmp rax, [rbp+var_48] jz short loc_ABF19 call _my_thread_var mov dword ptr [rax], 7Bh ; '{' jmp short loc_ABF94 loc_ABF19: jmp short loc_ABF33 loc_ABF1B: mov eax, [rbp+var_80] cmp rax, [rbp+var_40] jnb short loc_ABF31 call _my_thread_var mov dword ptr [rax], 7Fh jmp short loc_ABF94 loc_ABF31: jmp short $+2 loc_ABF33: mov rcx, [rbp+var_40] mov eax, [rbp+var_80] sub rax, rcx mov [rbp+var_80], eax mov rax, [rbp+var_70] mov edi, [rax+1C0h] mov rsi, [rbp+var_78] mov rdx, [rbp+var_28] mov rax, [rbp+var_40] mov ecx, eax call _mi_cmp_buffer cmp eax, 0 jz short loc_ABF6F call _my_thread_var mov dword ptr [rax], 7Bh ; '{' jmp short loc_ABF94 loc_ABF6F: mov [rbp+var_7C], 1 mov rax, [rbp+var_40] add rax, [rbp+var_78] mov [rbp+var_78], rax jmp loc_ABEA9 loc_ABF87: jmp short $+2 loc_ABF89: call _my_thread_var mov dword ptr [rax], 0 loc_ABF94: mov rax, [rbp+var_98] mov rcx, [rbp+var_70] cmp rax, [rcx+120h] jz short loc_ABFB4 mov rdi, [rbp+var_98] call my_free loc_ABFB4: jmp short $+2 loc_ABFB6: call _my_thread_var mov eax, [rax] mov [rbp+var_64], eax loc_ABFC0: mov eax, [rbp+var_64] mov [rbp+var_A4], eax mov rax, fs:28h mov rcx, [rbp+var_8] cmp rax, rcx jnz short loc_ABFEA mov eax, [rbp+var_A4] add rsp, 0B0h pop rbp retn loc_ABFEA: call ___stack_chk_fail
long long mi_cmp_dynamic_record(char *a1, const char *a2) { long long v2; // rax long long v4; // [rsp+10h] [rbp-A0h] char *v5; // [rsp+18h] [rbp-98h] long long v6; // [rsp+20h] [rbp-90h] char block_info; // [rsp+2Ch] [rbp-84h] unsigned int v8; // [rsp+30h] [rbp-80h] int v9; // [rsp+34h] [rbp-7Ch] _BYTE *v10; // [rsp+38h] [rbp-78h] const char *v11; // [rsp+38h] [rbp-78h] char *v12; // [rsp+40h] [rbp-70h] char v14[24]; // [rsp+50h] [rbp-60h] BYREF long long v15; // [rsp+68h] [rbp-48h] unsigned long long v16; // [rsp+70h] [rbp-40h] long long v17; // [rsp+88h] [rbp-28h] long long v18; // [rsp+90h] [rbp-20h] int v19; // [rsp+A0h] [rbp-10h] unsigned long long v20; // [rsp+A8h] [rbp-8h] v20 = __readfsqword(0x28u); v12 = a1; v10 = a2; if ( (*((_DWORD *)a1 + 114) & 0x10) != 0 && (*((_DWORD *)a1 + 116) &= 0xFFFFF6FF, a1 += 544, a2 = (_BYTE *)(&dword_0 + 1), (unsigned int)my_b_flush_io_cache(v12 + 544, 1LL)) ) { return (unsigned int)-1; } else { *((_DWORD *)v12 + 192) = 1; v5 = (char *)*((_QWORD *)v12 + 36); if ( (*((_DWORD *)v12 + 114) & 4) != 0 ) { if ( *(_DWORD *)(*(_QWORD *)v12 + 392LL) ) { v4 = *(_QWORD *)(*(_QWORD *)v12 + 328LL); v2 = mi_calc_total_blob_length(v12, (long long)v10); v5 = (char *)my_malloc(0LL, v2 + v4, 0LL); if ( !v5 ) return (unsigned int)-1; } a1 = v12; a2 = v5; v8 = mi_rec_pack(v12, v5, v10); v11 = v5; v6 = *((_QWORD *)v12 + 46); v19 = 0; v9 = 0; v18 = v6; while ( v8 ) { a2 = (const char *)*((unsigned int *)v12 + 112); a1 = v14; block_info = mi_get_block_info(v14, a2, v18); if ( (block_info & 0x3C) != 0 ) { if ( (block_info & 0x14) != 0 ) *(_DWORD *)my_thread_var(v14, a2) = 123; goto LABEL_23; } if ( v9 ) { if ( v8 < v16 ) { *(_DWORD *)my_thread_var(v14, a2) = 127; goto LABEL_23; } } else if ( v8 != v15 ) { goto LABEL_16; } v8 -= v16; a1 = (char *)*((unsigned int *)v12 + 112); a2 = v11; if ( (unsigned int)mi_cmp_buffer(a1, v11, v17, (unsigned int)v16) ) { LABEL_16: *(_DWORD *)my_thread_var(a1, a2) = 123; goto LABEL_23; } v9 = 1; v11 += v16; } } *(_DWORD *)my_thread_var(a1, a2) = 0; LABEL_23: if ( v5 != *((char **)v12 + 36) ) { a1 = v5; my_free(v5); } return *(unsigned int *)my_thread_var(a1, a2); } }
_mi_cmp_dynamic_record: PUSH RBP MOV RBP,RSP SUB RSP,0xb0 MOV RAX,qword ptr FS:[0x28] MOV qword ptr [RBP + -0x8],RAX MOV qword ptr [RBP + -0x70],RDI MOV qword ptr [RBP + -0x78],RSI MOV RAX,qword ptr [RBP + -0x70] MOV EAX,dword ptr [RAX + 0x1c8] AND EAX,0x10 CMP EAX,0x0 JZ 0x001abdc2 MOV RAX,qword ptr [RBP + -0x70] MOV ECX,dword ptr [RAX + 0x1d0] AND ECX,0xfffff6ff MOV dword ptr [RAX + 0x1d0],ECX MOV RDI,qword ptr [RBP + -0x70] ADD RDI,0x220 MOV ESI,0x1 CALL 0x001e0be0 CMP EAX,0x0 JZ 0x001abdc0 JMP 0x001abdb4 LAB_001abdb4: MOV dword ptr [RBP + -0x64],0xffffffff JMP 0x001abfc0 LAB_001abdc0: JMP 0x001abdc2 LAB_001abdc2: MOV RAX,qword ptr [RBP + -0x70] MOV dword ptr [RAX + 0x300],0x1 MOV RAX,qword ptr [RBP + -0x70] MOV RAX,qword ptr [RAX + 0x120] MOV qword ptr [RBP + -0x98],RAX MOV RAX,qword ptr [RBP + -0x70] MOV EAX,dword ptr [RAX + 0x1c8] AND EAX,0x4 CMP EAX,0x0 JZ 0x001abf89 MOV RAX,qword ptr [RBP + -0x70] MOV RAX,qword ptr [RAX] CMP dword ptr [RAX + 0x188],0x0 JZ 0x001abe5c MOV RAX,qword ptr [RBP + -0x70] MOV RAX,qword ptr [RAX] MOV RAX,qword ptr [RAX + 0x148] MOV qword ptr [RBP + -0xa0],RAX MOV RDI,qword ptr [RBP + -0x70] MOV RSI,qword ptr [RBP + -0x78] CALL 0x001a88d0 MOV RSI,qword ptr [RBP + -0xa0] ADD RSI,RAX XOR EDI,EDI XOR EAX,EAX MOV EDX,EAX CALL 0x001f3860 MOV qword ptr [RBP + -0x98],RAX CMP RAX,0x0 JNZ 0x001abe5a JMP 0x001abe4e LAB_001abe4e: MOV dword ptr [RBP + -0x64],0xffffffff JMP 0x001abfc0 LAB_001abe5a: JMP 0x001abe5c LAB_001abe5c: MOV RDI,qword ptr [RBP + -0x70] MOV RSI,qword ptr [RBP + -0x98] MOV RDX,qword ptr [RBP + -0x78] CALL 0x001a7940 MOV dword ptr [RBP + -0x80],EAX MOV RAX,qword ptr [RBP + -0x98] MOV qword ptr [RBP + -0x78],RAX MOV RAX,qword ptr [RBP + -0x70] MOV RAX,qword ptr [RAX + 0x170] MOV qword ptr [RBP + -0x90],RAX MOV dword ptr [RBP + -0x10],0x0 MOV dword ptr [RBP + -0x7c],0x0 MOV RAX,qword ptr [RBP + -0x90] MOV qword ptr [RBP + -0x20],RAX LAB_001abea9: CMP dword ptr [RBP + -0x80],0x0 JBE 0x001abf87 MOV RAX,qword ptr [RBP + -0x70] MOV ESI,dword ptr [RAX + 0x1c0] MOV RDX,qword ptr [RBP + -0x20] LEA RDI,[RBP + -0x60] CALL 0x001a9d10 MOV dword ptr [RBP + -0x84],EAX AND EAX,0x3c CMP EAX,0x0 JZ 0x001abef6 MOV EAX,dword ptr [RBP + -0x84] AND EAX,0x14 CMP EAX,0x0 JZ 0x001abef1 CALL 0x001f60c0 MOV dword ptr [RAX],0x7b LAB_001abef1: JMP 0x001abf94 LAB_001abef6: CMP dword ptr [RBP + -0x7c],0x0 JNZ 0x001abf1b MOV dword ptr [RBP + -0x7c],0x1 MOV EAX,dword ptr [RBP + -0x80] CMP RAX,qword ptr [RBP + -0x48] JZ 0x001abf19 CALL 0x001f60c0 MOV dword ptr [RAX],0x7b JMP 0x001abf94 LAB_001abf19: JMP 0x001abf33 LAB_001abf1b: MOV EAX,dword ptr [RBP + -0x80] CMP RAX,qword ptr [RBP + -0x40] JNC 0x001abf31 CALL 0x001f60c0 MOV dword ptr [RAX],0x7f JMP 0x001abf94 LAB_001abf31: JMP 0x001abf33 LAB_001abf33: MOV RCX,qword ptr [RBP + -0x40] MOV EAX,dword ptr [RBP + -0x80] SUB RAX,RCX MOV dword ptr [RBP + -0x80],EAX MOV RAX,qword ptr [RBP + -0x70] MOV EDI,dword ptr [RAX + 0x1c0] MOV RSI,qword ptr [RBP + -0x78] MOV RDX,qword ptr [RBP + -0x28] MOV RAX,qword ptr [RBP + -0x40] MOV ECX,EAX CALL 0x001abff0 CMP EAX,0x0 JZ 0x001abf6f CALL 0x001f60c0 MOV dword ptr [RAX],0x7b JMP 0x001abf94 LAB_001abf6f: MOV dword ptr [RBP + -0x7c],0x1 MOV RAX,qword ptr [RBP + -0x40] ADD RAX,qword ptr [RBP + -0x78] MOV qword ptr [RBP + -0x78],RAX JMP 0x001abea9 LAB_001abf87: JMP 0x001abf89 LAB_001abf89: CALL 0x001f60c0 MOV dword ptr [RAX],0x0 LAB_001abf94: MOV RAX,qword ptr [RBP + -0x98] MOV RCX,qword ptr [RBP + -0x70] CMP RAX,qword ptr [RCX + 0x120] JZ 0x001abfb4 MOV RDI,qword ptr [RBP + -0x98] CALL 0x001f3be0 LAB_001abfb4: JMP 0x001abfb6 LAB_001abfb6: CALL 0x001f60c0 MOV EAX,dword ptr [RAX] MOV dword ptr [RBP + -0x64],EAX LAB_001abfc0: MOV EAX,dword ptr [RBP + -0x64] MOV dword ptr [RBP + -0xa4],EAX MOV RAX,qword ptr FS:[0x28] MOV RCX,qword ptr [RBP + -0x8] CMP RAX,RCX JNZ 0x001abfea MOV EAX,dword ptr [RBP + -0xa4] ADD RSP,0xb0 POP RBP RET LAB_001abfea: CALL 0x0012a270
int4 _mi_cmp_dynamic_record(long *param_1,int8 param_2) { long lVar1; bool bVar2; int iVar3; uint uVar4; long lVar5; int4 *puVar6; long in_FS_OFFSET; long local_a0; uint local_88; long local_80; int4 local_6c; int1 local_68 [24]; ulong local_50; ulong local_48; int8 local_30; long local_28; int4 local_18; long local_10; local_10 = *(long *)(in_FS_OFFSET + 0x28); if ((*(uint *)(param_1 + 0x39) & 0x10) != 0) { *(uint *)(param_1 + 0x3a) = *(uint *)(param_1 + 0x3a) & 0xfffff6ff; iVar3 = my_b_flush_io_cache(param_1 + 0x44,1); if (iVar3 != 0) { local_6c = 0xffffffff; goto LAB_001abfc0; } } *(int4 *)(param_1 + 0x60) = 1; local_a0 = param_1[0x24]; if ((*(uint *)(param_1 + 0x39) & 4) != 0) { if (*(int *)(*param_1 + 0x188) != 0) { lVar1 = *(long *)(*param_1 + 0x148); lVar5 = _mi_calc_total_blob_length(param_1,param_2); local_a0 = my_malloc(0,lVar1 + lVar5,0); if (local_a0 == 0) { local_6c = 0xffffffff; goto LAB_001abfc0; } } local_88 = _mi_rec_pack(param_1,local_a0,param_2); local_80 = local_a0; local_28 = param_1[0x2e]; local_18 = 0; bVar2 = false; while (local_88 != 0) { uVar4 = _mi_get_block_info(local_68,(int)param_1[0x38],local_28); if ((uVar4 & 0x3c) != 0) { if ((uVar4 & 0x14) != 0) { puVar6 = (int4 *)_my_thread_var(); *puVar6 = 0x7b; } goto LAB_001abf94; } if (bVar2) { if (local_88 < local_48) { puVar6 = (int4 *)_my_thread_var(); *puVar6 = 0x7f; goto LAB_001abf94; } } else if (local_88 != local_50) { puVar6 = (int4 *)_my_thread_var(); *puVar6 = 0x7b; goto LAB_001abf94; } local_88 = local_88 - (int)local_48; iVar3 = _mi_cmp_buffer((int)param_1[0x38],local_80,local_30,local_48 & 0xffffffff); if (iVar3 != 0) { puVar6 = (int4 *)_my_thread_var(); *puVar6 = 0x7b; goto LAB_001abf94; } bVar2 = true; local_80 = local_48 + local_80; } } puVar6 = (int4 *)_my_thread_var(); *puVar6 = 0; LAB_001abf94: if (local_a0 != param_1[0x24]) { my_free(local_a0); } puVar6 = (int4 *)_my_thread_var(); local_6c = *puVar6; LAB_001abfc0: if (*(long *)(in_FS_OFFSET + 0x28) != local_10) { /* WARNING: Subroutine does not return */ __stack_chk_fail(); } return local_6c; }
47,480
nlohmann::json_abi_v3_11_3::detail::serializer<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>>::dump_float(double)
monkey531[P]llama/common/./json.hpp
void dump_float(number_float_t x) { // NaN / inf if (!std::isfinite(x)) { o->write_characters("null", 4); return; } // If number_float_t is an IEEE-754 single or double precision number, // use the Grisu2 algorithm to produce short numbers which are // guaranteed to round-trip, using strtof and strtod, resp. // // NB: The test below works if <long double> == <double>. static constexpr bool is_ieee_single_or_double = (std::numeric_limits<number_float_t>::is_iec559 && std::numeric_limits<number_float_t>::digits == 24 && std::numeric_limits<number_float_t>::max_exponent == 128) || (std::numeric_limits<number_float_t>::is_iec559 && std::numeric_limits<number_float_t>::digits == 53 && std::numeric_limits<number_float_t>::max_exponent == 1024); dump_float(x, std::integral_constant<bool, is_ieee_single_or_double>()); }
O0
cpp
nlohmann::json_abi_v3_11_3::detail::serializer<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>>::dump_float(double): subq $0x28, %rsp movq %rdi, 0x20(%rsp) movsd %xmm0, 0x18(%rsp) movq 0x20(%rsp), %rax movq %rax, 0x8(%rsp) movsd 0x18(%rsp), %xmm0 callq 0xb8c30 testb $0x1, %al jne 0x1183d9 movq 0x8(%rsp), %rdi callq 0x116c30 movq %rax, %rdi movq (%rdi), %rax leaq 0xb9530(%rip), %rsi # 0x1d18ff movl $0x4, %edx callq *0x8(%rax) jmp 0x1183e9 movq 0x8(%rsp), %rdi movsd 0x18(%rsp), %xmm0 callq 0x118eb0 addq $0x28, %rsp retq nop
_ZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE10dump_floatEd: sub rsp, 28h mov [rsp+28h+var_8], rdi movsd [rsp+28h+var_10], xmm0 mov rax, [rsp+28h+var_8] mov [rsp+28h+var_20], rax movsd xmm0, [rsp+28h+var_10]; double call _ZSt8isfinited; std::isfinite(double) test al, 1 jnz short loc_1183D9 mov rdi, [rsp+28h+var_20] call _ZNKSt19__shared_ptr_accessIN8nlohmann16json_abi_v3_11_36detail23output_adapter_protocolIcEELN9__gnu_cxx12_Lock_policyE2ELb0ELb0EEptEv; std::__shared_ptr_access<nlohmann::json_abi_v3_11_3::detail::output_adapter_protocol<char>,(__gnu_cxx::_Lock_policy)2,false,false>::operator->(void) mov rdi, rax mov rax, [rdi] lea rsi, aOnNull_0+5; "null" mov edx, 4 call qword ptr [rax+8] jmp short loc_1183E9 loc_1183D9: mov rdi, [rsp+28h+var_20] movsd xmm0, [rsp+28h+var_10] call _ZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE10dump_floatEdSt17integral_constantIbLb1EE; nlohmann::json_abi_v3_11_3::detail::serializer<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>>::dump_float(double,std::integral_constant<bool,true>) loc_1183E9: add rsp, 28h retn
long long nlohmann::json_abi_v3_11_3::detail::serializer<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>>::dump_float( long long a1, double a2) { long long v2; // rax if ( std::isfinite(a2) ) return nlohmann::json_abi_v3_11_3::detail::serializer<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>>::dump_float( a1, a2); v2 = std::__shared_ptr_access<nlohmann::json_abi_v3_11_3::detail::output_adapter_protocol<char>,(__gnu_cxx::_Lock_policy)2,false,false>::operator->(a1); return (*(long long ( **)(long long, char *, long long))(*(_QWORD *)v2 + 8LL))(v2, "null", 4LL); }
47,481
nlohmann::json_abi_v3_11_3::detail::serializer<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>>::dump_float(double)
monkey531[P]llama/common/./json.hpp
void dump_float(number_float_t x) { // NaN / inf if (!std::isfinite(x)) { o->write_characters("null", 4); return; } // If number_float_t is an IEEE-754 single or double precision number, // use the Grisu2 algorithm to produce short numbers which are // guaranteed to round-trip, using strtof and strtod, resp. // // NB: The test below works if <long double> == <double>. static constexpr bool is_ieee_single_or_double = (std::numeric_limits<number_float_t>::is_iec559 && std::numeric_limits<number_float_t>::digits == 24 && std::numeric_limits<number_float_t>::max_exponent == 128) || (std::numeric_limits<number_float_t>::is_iec559 && std::numeric_limits<number_float_t>::digits == 53 && std::numeric_limits<number_float_t>::max_exponent == 1024); dump_float(x, std::integral_constant<bool, is_ieee_single_or_double>()); }
O3
cpp
nlohmann::json_abi_v3_11_3::detail::serializer<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>>::dump_float(double): pushq %r14 pushq %rbx pushq %rax movq %rdi, %rbx movq %xmm0, %rax btrq $0x3f, %rax movabsq $0x7ff0000000000000, %rcx # imm = 0x7FF0000000000000 cmpq %rcx, %rax jl 0x66f7d movq (%rbx), %rdi movq (%rdi), %rax movq 0x8(%rax), %rax leaq 0x541da(%rip), %rsi # 0xbb149 movl $0x4, %edx addq $0x8, %rsp popq %rbx popq %r14 jmpq *%rax leaq 0x10(%rbx), %r14 leaq 0x50(%rbx), %rsi movq %r14, %rdi callq 0x671b7 movq (%rbx), %rdi subq %r14, %rax movq (%rdi), %rcx movq 0x8(%rcx), %rcx movq %r14, %rsi movq %rax, %rdx addq $0x8, %rsp popq %rbx popq %r14 jmpq *%rcx nop
_ZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE10dump_floatEd: push r14 push rbx push rax mov rbx, rdi movq rax, xmm0 btr rax, 3Fh ; '?' mov rcx, 7FF0000000000000h cmp rax, rcx jl short loc_66F7D mov rdi, [rbx] mov rax, [rdi] mov rax, [rax+8] lea rsi, aOnNull_0+5; "null" mov edx, 4 add rsp, 8 pop rbx pop r14 jmp rax loc_66F7D: lea r14, [rbx+10h] lea rsi, [rbx+50h] mov rdi, r14; this call _ZN8nlohmann16json_abi_v3_11_36detail8to_charsIdEEPcS3_PKcT_; nlohmann::json_abi_v3_11_3::detail::to_chars<double>(char *,char const*,double) mov rdi, [rbx] sub rax, r14 mov rcx, [rdi] mov rcx, [rcx+8] mov rsi, r14 mov rdx, rax add rsp, 8 pop rbx pop r14 jmp rcx
long long nlohmann::json_abi_v3_11_3::detail::serializer<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>>::dump_float( _QWORD *a1, double a2) { long long v3; // rax if ( (*(_QWORD *)&a2 & 0x7FFFFFFFFFFFFFFFuLL) >= 0x7FF0000000000000LL ) return (*(long long ( **)(_QWORD, char *, long long))(*(_QWORD *)*a1 + 8LL))(*a1, "null", 4LL); v3 = nlohmann::json_abi_v3_11_3::detail::to_chars<double>((nlohmann::json_abi_v3_11_3::detail::dtoa_impl *)(a1 + 2)); return (*(long long ( **)(_QWORD, _QWORD *, long long))(*(_QWORD *)*a1 + 8LL))( *a1, a1 + 2, v3 - (_QWORD)(a1 + 2)); }
dump_float: PUSH R14 PUSH RBX PUSH RAX MOV RBX,RDI MOVQ RAX,XMM0 BTR RAX,0x3f MOV RCX,0x7ff0000000000000 CMP RAX,RCX JL 0x00166f7d MOV RDI,qword ptr [RBX] MOV RAX,qword ptr [RDI] MOV RAX,qword ptr [RAX + 0x8] LEA RSI,[0x1bb149] MOV EDX,0x4 ADD RSP,0x8 POP RBX POP R14 JMP RAX LAB_00166f7d: LEA R14,[RBX + 0x10] LEA RSI,[RBX + 0x50] MOV RDI,R14 CALL 0x001671b7 MOV RDI,qword ptr [RBX] SUB RAX,R14 MOV RCX,qword ptr [RDI] MOV RCX,qword ptr [RCX + 0x8] MOV RSI,R14 MOV RDX,RAX ADD RSP,0x8 POP RBX POP R14 JMP RCX
/* nlohmann::json_abi_v3_11_3::detail::serializer<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> >::dump_float(double) */ void __thiscall nlohmann::json_abi_v3_11_3::detail:: serializer<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>> ::dump_float(serializer<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,double param_1) { serializer<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>> *psVar1; code *UNRECOVERED_JUMPTABLE; char *pcVar2; if (0x7fefffffffffffff < (ulong)ABS(param_1)) { /* WARNING: Could not recover jumptable at 0x00166f7b. Too many branches */ /* WARNING: Treating indirect jump as call */ (**(code **)(**(long **)this + 8))(*(long **)this,"null",4); return; } psVar1 = this + 0x10; pcVar2 = to_chars<double>((char *)psVar1,(char *)(this + 0x50),param_1); UNRECOVERED_JUMPTABLE = *(code **)(**(long **)this + 8); /* WARNING: Could not recover jumptable at 0x00166fa7. Too many branches */ /* WARNING: Treating indirect jump as call */ (*UNRECOVERED_JUMPTABLE)(*(long **)this,psVar1,(long)pcVar2 - (long)psVar1,UNRECOVERED_JUMPTABLE); return; }
47,482
encodeURI_hex
bluesky950520[P]quickjs/quickjs.c
static int encodeURI_hex(StringBuffer *b, int c) { uint8_t buf[6]; int n = 0; const char *hex = "0123456789ABCDEF"; buf[n++] = '%'; if (c >= 256) { buf[n++] = 'u'; buf[n++] = hex[(c >> 12) & 15]; buf[n++] = hex[(c >> 8) & 15]; } buf[n++] = hex[(c >> 4) & 15]; buf[n++] = hex[(c >> 0) & 15]; return string_buffer_write8(b, buf, n); }
O1
c
encodeURI_hex: pushq %rax movb $0x25, 0x2(%rsp) movl $0x1, %edx cmpl $0x100, %esi # imm = 0x100 jl 0x79ec3 movb $0x75, 0x3(%rsp) movl %esi, %eax shrl $0xc, %eax andl $0xf, %eax leaq 0x2802d(%rip), %rcx # 0xa1ed5 movb (%rax,%rcx), %al movb %al, 0x4(%rsp) movl %esi, %eax shrl $0x8, %eax andl $0xf, %eax movb (%rax,%rcx), %al movb %al, 0x5(%rsp) movl $0x4, %edx movl %esi, %eax shrl $0x4, %eax andl $0xf, %eax leaq 0x28003(%rip), %rcx # 0xa1ed5 movb (%rax,%rcx), %al movl %edx, %r8d movb %al, 0x2(%rsp,%r8) andl $0xf, %esi movb (%rsi,%rcx), %al orl $0x2, %edx movb %al, 0x3(%rsp,%r8) leaq 0x2(%rsp), %rsi callq 0x42038 popq %rax retq
encodeURI_hex: push rax mov [rsp+8+var_6], 25h ; '%' mov edx, 1 cmp esi, 100h jl short loc_79EC3 mov [rsp+8+var_5], 75h ; 'u' mov eax, esi shr eax, 0Ch and eax, 0Fh lea rcx, a0123456789abcd; "0123456789ABCDEF" mov al, [rax+rcx] mov [rsp+8+var_4], al mov eax, esi shr eax, 8 and eax, 0Fh mov al, [rax+rcx] mov [rsp+8+var_3], al mov edx, 4 loc_79EC3: mov eax, esi shr eax, 4 and eax, 0Fh lea rcx, a0123456789abcd; "0123456789ABCDEF" mov al, [rax+rcx] mov r8d, edx mov [rsp+r8+8+var_6], al and esi, 0Fh mov al, [rsi+rcx] or edx, 2 mov [rsp+r8+8+var_5], al lea rsi, [rsp+8+var_6] call string_buffer_write8 pop rax retn
long long encodeURI_hex(long long a1, int a2) { long long v2; // rax unsigned int v3; // edx long long v5; // [rsp-2h] [rbp-8h] BYREF v5 = v2; BYTE2(v5) = 37; v3 = 1; if ( a2 >= 256 ) { BYTE3(v5) = 117; BYTE4(v5) = a0123456789abcd[(unsigned __int16)a2 >> 12]; BYTE5(v5) = a0123456789abcd[((unsigned int)a2 >> 8) & 0xF]; v3 = 4; } *((_BYTE *)&v5 + v3 + 2) = a0123456789abcd[(unsigned __int8)a2 >> 4]; *((_BYTE *)&v5 + v3 + 3) = a0123456789abcd[a2 & 0xF]; string_buffer_write8(a1, (long long)&v5 + 2, v3 | 2); return v5; }
encodeURI_hex: PUSH RAX MOV byte ptr [RSP + 0x2],0x25 MOV EDX,0x1 CMP ESI,0x100 JL 0x00179ec3 MOV byte ptr [RSP + 0x3],0x75 MOV EAX,ESI SHR EAX,0xc AND EAX,0xf LEA RCX,[0x1a1ed5] MOV AL,byte ptr [RAX + RCX*0x1] MOV byte ptr [RSP + 0x4],AL MOV EAX,ESI SHR EAX,0x8 AND EAX,0xf MOV AL,byte ptr [RAX + RCX*0x1] MOV byte ptr [RSP + 0x5],AL MOV EDX,0x4 LAB_00179ec3: MOV EAX,ESI SHR EAX,0x4 AND EAX,0xf LEA RCX,[0x1a1ed5] MOV AL,byte ptr [RAX + RCX*0x1] MOV R8D,EDX MOV byte ptr [RSP + R8*0x1 + 0x2],AL AND ESI,0xf MOV AL,byte ptr [RSI + RCX*0x1] OR EDX,0x2 MOV byte ptr [RSP + R8*0x1 + 0x3],AL LEA RSI,[RSP + 0x2] CALL 0x00142038 POP RAX RET
int8 encodeURI_hex(int8 param_1,uint param_2) { int8 in_RAX; uint uVar1; int8 uStack_8; uStack_8._3_5_ = (int5)((ulong)in_RAX >> 0x18); uStack_8._0_3_ = CONCAT12(0x25,(short)in_RAX); uVar1 = 1; if (0xff < (int)param_2) { uStack_8._6_2_ = (int2)((ulong)in_RAX >> 0x30); uStack_8._0_6_ = CONCAT15("0123456789ABCDEF"[param_2 >> 8 & 0xf], CONCAT14("0123456789ABCDEF"[param_2 >> 0xc & 0xf], CONCAT13(0x75,(int3)uStack_8))); uVar1 = 4; } *(char *)((long)&uStack_8 + (ulong)uVar1 + 2) = "0123456789ABCDEF"[param_2 >> 4 & 0xf]; *(char *)((long)&uStack_8 + (ulong)uVar1 + 3) = "0123456789ABCDEF"[param_2 & 0xf]; string_buffer_write8(param_1,(long)&uStack_8 + 2,uVar1 | 2); return uStack_8; }
47,483
encodeURI_hex
bluesky950520[P]quickjs/quickjs.c
static int encodeURI_hex(StringBuffer *b, int c) { uint8_t buf[6]; int n = 0; const char *hex = "0123456789ABCDEF"; buf[n++] = '%'; if (c >= 256) { buf[n++] = 'u'; buf[n++] = hex[(c >> 12) & 15]; buf[n++] = hex[(c >> 8) & 15]; } buf[n++] = hex[(c >> 4) & 15]; buf[n++] = hex[(c >> 0) & 15]; return string_buffer_write8(b, buf, n); }
O2
c
encodeURI_hex: pushq %rax movb $0x25, 0x2(%rsp) cmpl $0x100, %esi # imm = 0x100 jl 0x66751 movb $0x75, 0x3(%rsp) movl %esi, %eax shrl $0xc, %eax andl $0xf, %eax leaq 0x226d8(%rip), %rcx # 0x88e0f movb (%rax,%rcx), %al movb %al, 0x4(%rsp) movl %esi, %eax shrl $0x8, %eax andl $0xf, %eax movb (%rax,%rcx), %al movb %al, 0x5(%rsp) pushq $0x4 jmp 0x66753 pushq $0x1 popq %rdx movl %esi, %eax shrl $0x4, %eax andl $0xf, %eax leaq 0x226ac(%rip), %rcx # 0x88e0f movb (%rax,%rcx), %al movl %edx, %r8d movb %al, 0x2(%rsp,%r8) andl $0xf, %esi movb (%rsi,%rcx), %al orl $0x2, %edx movb %al, 0x3(%rsp,%r8) leaq 0x2(%rsp), %rsi callq 0x39d2a popq %rax retq
encodeURI_hex: push rax mov [rsp+8+var_6], 25h ; '%' cmp esi, 100h jl short loc_66751 mov [rsp+8+var_5], 75h ; 'u' mov eax, esi shr eax, 0Ch and eax, 0Fh lea rcx, a0123456789abcd; "0123456789ABCDEF" mov al, [rax+rcx] mov [rsp+8+var_4], al mov eax, esi shr eax, 8 and eax, 0Fh mov al, [rax+rcx] mov [rsp+8+var_3], al push 4 jmp short loc_66753 loc_66751: push 1 loc_66753: pop rdx mov eax, esi shr eax, 4 and eax, 0Fh lea rcx, a0123456789abcd; "0123456789ABCDEF" mov al, [rax+rcx] mov r8d, edx mov [rsp+r8+8+var_6], al and esi, 0Fh mov al, [rsi+rcx] or edx, 2 mov [rsp+r8+8+var_5], al lea rsi, [rsp+8+var_6] call string_buffer_write8 pop rax retn
long long encodeURI_hex(long long a1, int a2) { long long v2; // rax unsigned int v4; // [rsp-Ah] [rbp-10h] long long v5; // [rsp-2h] [rbp-8h] BYREF v5 = v2; BYTE2(v5) = 37; if ( a2 < 256 ) { v4 = 1; } else { BYTE3(v5) = 117; BYTE4(v5) = a0123456789abcd[(unsigned __int16)a2 >> 12]; BYTE5(v5) = a0123456789abcd[((unsigned int)a2 >> 8) & 0xF]; v4 = 4; } *((_BYTE *)&v5 + v4 + 2) = a0123456789abcd[(unsigned __int8)a2 >> 4]; *((_BYTE *)&v5 + v4 + 3) = a0123456789abcd[a2 & 0xF]; string_buffer_write8(a1, (long long)&v5 + 2, v4 | 2); return v5; }
encodeURI_hex: PUSH RAX MOV byte ptr [RSP + 0x2],0x25 CMP ESI,0x100 JL 0x00166751 MOV byte ptr [RSP + 0x3],0x75 MOV EAX,ESI SHR EAX,0xc AND EAX,0xf LEA RCX,[0x188e0f] MOV AL,byte ptr [RAX + RCX*0x1] MOV byte ptr [RSP + 0x4],AL MOV EAX,ESI SHR EAX,0x8 AND EAX,0xf MOV AL,byte ptr [RAX + RCX*0x1] MOV byte ptr [RSP + 0x5],AL PUSH 0x4 JMP 0x00166753 LAB_00166751: PUSH 0x1 LAB_00166753: POP RDX MOV EAX,ESI SHR EAX,0x4 AND EAX,0xf LEA RCX,[0x188e0f] MOV AL,byte ptr [RAX + RCX*0x1] MOV R8D,EDX MOV byte ptr [RSP + R8*0x1 + 0x2],AL AND ESI,0xf MOV AL,byte ptr [RSI + RCX*0x1] OR EDX,0x2 MOV byte ptr [RSP + R8*0x1 + 0x3],AL LEA RSI,[RSP + 0x2] CALL 0x00139d2a POP RAX RET
int8 encodeURI_hex(int8 param_1,uint param_2) { uint uVar1; int8 in_RAX; int8 uStack_8; uStack_8._3_5_ = (int5)((ulong)in_RAX >> 0x18); uStack_8._0_3_ = CONCAT12(0x25,(short)in_RAX); if ((int)param_2 < 0x100) { uVar1 = 1; } else { uStack_8._6_2_ = (int2)((ulong)in_RAX >> 0x30); uStack_8._0_6_ = CONCAT15("0123456789ABCDEF"[param_2 >> 8 & 0xf], CONCAT14("0123456789ABCDEF"[param_2 >> 0xc & 0xf], CONCAT13(0x75,(int3)uStack_8))); uVar1 = 4; } *(char *)((long)&uStack_8 + (ulong)uVar1 + 2) = "0123456789ABCDEF"[param_2 >> 4 & 0xf]; *(char *)((long)&uStack_8 + (ulong)uVar1 + 3) = "0123456789ABCDEF"[param_2 & 0xf]; string_buffer_write8(param_1,(long)&uStack_8 + 2,uVar1 | 2); return uStack_8; }
47,484
nlohmann::json_abi_v3_11_3::detail::out_of_range nlohmann::json_abi_v3_11_3::detail::out_of_range::create<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>*, 0>(int, 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
static out_of_range create(int id_, const std::string& what_arg, BasicJsonContext context) { const std::string w = concat(exception::name("out_of_range", id_), exception::diagnostics(context), what_arg); return {id_, w.c_str()}; }
O2
cpp
nlohmann::json_abi_v3_11_3::detail::out_of_range nlohmann::json_abi_v3_11_3::detail::out_of_range::create<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>*, 0>(int, 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 %rbx subq $0x88, %rsp movq %rcx, %r15 movq %rdx, %r14 movl %esi, %ebp movq %rdi, %rbx leaq 0x2e1fb(%rip), %rsi # 0x912dc leaq 0x28(%rsp), %rdi leaq 0x7(%rsp), %rdx callq 0x2303e leaq 0x48(%rsp), %rdi leaq 0x28(%rsp), %rsi movl %ebp, %edx callq 0x3d27c leaq 0x8(%rsp), %rdi movq %r15, %rsi callq 0x3d2f2 leaq 0x68(%rsp), %rdi leaq 0x48(%rsp), %rsi leaq 0x8(%rsp), %rdx movq %r14, %rcx callq 0x3d212 leaq 0x8(%rsp), %rdi callq 0x20d88 leaq 0x48(%rsp), %rdi callq 0x20d88 leaq 0x28(%rsp), %rdi callq 0x20d88 movq 0x68(%rsp), %rdx movq %rbx, %rdi movl %ebp, %esi callq 0x45fd4 leaq 0x68(%rsp), %rdi callq 0x20d88 movq %rbx, %rax addq $0x88, %rsp popq %rbx popq %r14 popq %r15 popq %rbp retq movq %rax, %rbx leaq 0x68(%rsp), %rdi jmp 0x6319d movq %rax, %rbx leaq 0x8(%rsp), %rdi callq 0x20d88 jmp 0x63189 movq %rax, %rbx leaq 0x48(%rsp), %rdi callq 0x20d88 jmp 0x63198 movq %rax, %rbx leaq 0x28(%rsp), %rdi callq 0x20d88 jmp 0x631a7 movq %rax, %rbx movq %rbx, %rdi callq 0x20b90 nop
_ZN8nlohmann16json_abi_v3_11_36detail12out_of_range6createIPKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SK_: push rbp push r15 push r14 push rbx sub rsp, 88h mov r15, rcx mov r14, rdx mov ebp, esi mov rbx, rdi lea rsi, aOutOfRange; "out_of_range" lea rdi, [rsp+0A8h+var_80] lea rdx, [rsp+0A8h+var_A1] call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&) lea rdi, [rsp+0A8h+var_60] lea rsi, [rsp+0A8h+var_80] mov edx, ebp call _ZN8nlohmann16json_abi_v3_11_36detail9exception4nameERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEi; nlohmann::json_abi_v3_11_3::detail::exception::name(std::string const&,int) lea rdi, [rsp+0A8h+var_A0] mov rsi, r15 call _ZN8nlohmann16json_abi_v3_11_36detail9exception11diagnosticsINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEEEESC_PKT_; nlohmann::json_abi_v3_11_3::detail::exception::diagnostics<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>>(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*) lea rdi, [rsp+0A8h+var_40] lea rsi, [rsp+0A8h+var_60] lea rdx, [rsp+0A8h+var_A0] mov rcx, r14 call _ZN8nlohmann16json_abi_v3_11_36detail6concatINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEJS8_S8_RKS8_EEET_DpOT0_; nlohmann::json_abi_v3_11_3::detail::concat<std::string,std::string,std::string,std::string const&>(std::string,std::string,std::string const&) lea rdi, [rsp+0A8h+var_A0]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() lea rdi, [rsp+0A8h+var_60]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() lea rdi, [rsp+0A8h+var_80]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() mov rdx, [rsp+0A8h+var_40]; char * mov rdi, rbx; this mov esi, ebp; int call _ZN8nlohmann16json_abi_v3_11_36detail12out_of_rangeC2EiPKc; nlohmann::json_abi_v3_11_3::detail::out_of_range::out_of_range(int,char const*) lea rdi, [rsp+0A8h+var_40]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() mov rax, rbx add rsp, 88h pop rbx pop r14 pop r15 pop rbp retn mov rbx, rax lea rdi, [rsp+arg_60] jmp short loc_6319D mov rbx, rax lea rdi, [rsp+arg_0]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() jmp short loc_63189 mov rbx, rax loc_63189: lea rdi, [rsp+arg_40]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() jmp short loc_63198 mov rbx, rax loc_63198: lea rdi, [rsp+arg_20]; void * loc_6319D: call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() jmp short loc_631A7 mov rbx, rax loc_631A7: mov rdi, rbx call __Unwind_Resume
nlohmann::json_abi_v3_11_3::detail::out_of_range * ZN8nlohmann16json_abi_v3_11_36detail12out_of_range6createIPKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SK_( nlohmann::json_abi_v3_11_3::detail::out_of_range *this, int a2, long long a3) { _QWORD v5[4]; // [rsp+8h] [rbp-A0h] BYREF _QWORD v6[4]; // [rsp+28h] [rbp-80h] BYREF _BYTE v7[32]; // [rsp+48h] [rbp-60h] BYREF char *v8[8]; // [rsp+68h] [rbp-40h] BYREF std::string::basic_string<std::allocator<char>>(v6, (long long)"out_of_range"); nlohmann::json_abi_v3_11_3::detail::exception::name((long long)v7, (long long)v6, a2); nlohmann::json_abi_v3_11_3::detail::exception::diagnostics<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>>(v5); nlohmann::json_abi_v3_11_3::detail::concat<std::string,std::string,std::string,std::string const&>( (long long)v8, (long long)v7, (long long)v5, a3); std::string::~string(v5); std::string::~string(v7); std::string::~string(v6); nlohmann::json_abi_v3_11_3::detail::out_of_range::out_of_range(this, a2, v8[0]); std::string::~string(v8); return this; }
_ZN8nlohmann16json_abi_v3_11_36detail12out_of_range6createIPKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SK_: PUSH RBP PUSH R15 PUSH R14 PUSH RBX SUB RSP,0x88 MOV R15,RCX MOV R14,RDX MOV EBP,ESI MOV RBX,RDI LAB_001630da: LEA RSI,[0x1912dc] LEA RDI,[RSP + 0x28] LEA RDX,[RSP + 0x7] CALL 0x0012303e LAB_001630f0: LEA RDI,[RSP + 0x48] LEA RSI,[RSP + 0x28] MOV EDX,EBP CALL 0x0013d27c LAB_00163101: LEA RDI,[RSP + 0x8] MOV RSI,R15 CALL 0x0013d2f2 LAB_0016310e: LEA RDI,[RSP + 0x68] LEA RSI,[RSP + 0x48] LEA RDX,[RSP + 0x8] MOV RCX,R14 CALL 0x0013d212 LEA RDI,[RSP + 0x8] CALL 0x00120d88 LEA RDI,[RSP + 0x48] CALL 0x00120d88 LEA RDI,[RSP + 0x28] CALL 0x00120d88 MOV RDX,qword ptr [RSP + 0x68] LAB_00163148: MOV RDI,RBX MOV ESI,EBP CALL 0x00145fd4 LAB_00163152: LEA RDI,[RSP + 0x68] CALL 0x00120d88 MOV RAX,RBX ADD RSP,0x88 POP RBX POP R14 POP R15 POP RBP RET
out_of_range * _ZN8nlohmann16json_abi_v3_11_36detail12out_of_range6createIPKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SK_ (out_of_range *param_1,int param_2,string *param_3) { allocator local_a1; string local_a0 [32]; string local_80 [32]; exception local_60 [32]; char *local_40 [4]; /* try { // try from 001630da to 001630ef has its CatchHandler @ 001631a4 */ std::__cxx11::string::string<std::allocator<char>>(local_80,"out_of_range",&local_a1); /* try { // try from 001630f0 to 00163100 has its CatchHandler @ 00163195 */ nlohmann::json_abi_v3_11_3::detail::exception::name(local_60,local_80,param_2); /* try { // try from 00163101 to 0016310d has its CatchHandler @ 00163186 */ nlohmann::json_abi_v3_11_3::detail::exception:: diagnostics<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_a0); /* try { // try from 0016310e to 00163124 has its CatchHandler @ 00163177 */ nlohmann::json_abi_v3_11_3::detail:: concat<std::__cxx11::string,std::__cxx11::string,std::__cxx11::string,std::__cxx11::string_const&> ((detail *)local_40,(string *)local_60,local_a0,param_3); std::__cxx11::string::~string(local_a0); std::__cxx11::string::~string((string *)local_60); std::__cxx11::string::~string(local_80); /* try { // try from 00163148 to 00163151 has its CatchHandler @ 0016316d */ nlohmann::json_abi_v3_11_3::detail::out_of_range::out_of_range(param_1,param_2,local_40[0]); std::__cxx11::string::~string((string *)local_40); return param_1; }
47,485
glfwGetInstanceProcAddress
untodesu[P]riteg/build_O1/_deps/glfw-src/src/vulkan.c
GLFWAPI GLFWvkproc glfwGetInstanceProcAddress(VkInstance instance, const char* procname) { GLFWvkproc proc; assert(procname != NULL); _GLFW_REQUIRE_INIT_OR_RETURN(NULL); if (!_glfwInitVulkan(_GLFW_REQUIRE_LOADER)) return NULL; proc = (GLFWvkproc) vkGetInstanceProcAddr(instance, procname); #if defined(_GLFW_VULKAN_STATIC) if (!proc) { if (strcmp(procname, "vkGetInstanceProcAddr") == 0) return (GLFWvkproc) vkGetInstanceProcAddr; } #else if (!proc) proc = (GLFWvkproc) _glfw_dlsym(_glfw.vk.handle, procname); #endif return proc; }
O1
c
glfwGetInstanceProcAddress: pushq %r15 pushq %r14 pushq %rbx testq %rsi, %rsi je 0x1c9c3 leaq 0x87cd7(%rip), %r15 # 0xa4638 cmpl $0x0, (%r15) je 0x1c9a4 movq %rsi, %rbx movq %rdi, %r14 movl $0x2, %edi callq 0x1c54c testl %eax, %eax je 0x1c9b7 movq %r14, %rdi movq %rbx, %rsi callq *0x1fe98(%r15) movq %rax, %r14 testq %rax, %rax jne 0x1c9ba movq 0x1fe78(%r15), %rdi movq %rbx, %rsi popq %rbx popq %r14 popq %r15 jmp 0xc820 xorl %r14d, %r14d movl $0x10001, %edi # imm = 0x10001 xorl %esi, %esi xorl %eax, %eax callq 0x19081 jmp 0x1c9ba xorl %r14d, %r14d movq %r14, %rax popq %rbx popq %r14 popq %r15 retq leaq 0x46e22(%rip), %rdi # 0x637ec leaq 0x63499(%rip), %rsi # 0x7fe6a leaq 0x6352b(%rip), %rcx # 0x7ff03 movl $0xf7, %edx callq 0xc540
glfwGetInstanceProcAddress: push r15 push r14 push rbx test rsi, rsi jz short loc_1C9C3 lea r15, _glfw cmp dword ptr [r15], 0 jz short loc_1C9A4 mov rbx, rsi mov r14, rdi mov edi, 2 call _glfwInitVulkan test eax, eax jz short loc_1C9B7 mov rdi, r14 mov rsi, rbx call qword ptr [r15+1FE98h] mov r14, rax test rax, rax jnz short loc_1C9BA mov rdi, qword ptr ds:loc_1FE78[r15] mov rsi, rbx pop rbx pop r14 pop r15 jmp _dlsym loc_1C9A4: xor r14d, r14d mov edi, 10001h xor esi, esi xor eax, eax call _glfwInputError jmp short loc_1C9BA loc_1C9B7: xor r14d, r14d loc_1C9BA: mov rax, r14 pop rbx pop r14 pop r15 retn loc_1C9C3: lea rdi, aProcnameNull; "procname != NULL" lea rsi, aWorkspaceLlm4b_14; "/workspace/llm4binary/github/2025_star3"... lea rcx, aGlfwvkprocGlfw; "GLFWvkproc glfwGetInstanceProcAddress(V"... mov edx, 0F7h call ___assert_fail
long long glfwGetInstanceProcAddress(long long a1, long long a2) { long long v2; // r14 if ( !a2 ) __assert_fail( "procname != NULL", "/workspace/llm4binary/github/2025_star3/untodesu[P]riteg/build_O1/_deps/glfw-src/src/vulkan.c", 247LL, "GLFWvkproc glfwGetInstanceProcAddress(VkInstance, const char *)"); if ( glfw[0] ) { if ( (unsigned int)glfwInitVulkan(2) ) { v2 = (*(long long ( **)(long long, long long))&glfw[32678])(a1, a2); if ( !v2 ) return dlsym(*(_QWORD *)((char *)&loc_1FE78 + (_QWORD)glfw), a2); } else { return 0LL; } } else { v2 = 0LL; glfwInputError(0x10001u, 0LL); } return v2; }
glfwGetInstanceProcAddress: PUSH R15 PUSH R14 PUSH RBX TEST RSI,RSI JZ 0x0011c9c3 LEA R15,[0x1a4638] CMP dword ptr [R15],0x0 JZ 0x0011c9a4 MOV RBX,RSI MOV R14,RDI MOV EDI,0x2 CALL 0x0011c54c TEST EAX,EAX JZ 0x0011c9b7 MOV RDI,R14 MOV RSI,RBX CALL qword ptr [R15 + 0x1fe98] MOV R14,RAX TEST RAX,RAX JNZ 0x0011c9ba MOV RDI,qword ptr [R15 + 0x1fe78] MOV RSI,RBX POP RBX POP R14 POP R15 JMP 0x0010c820 LAB_0011c9a4: XOR R14D,R14D MOV EDI,0x10001 XOR ESI,ESI XOR EAX,EAX CALL 0x00119081 JMP 0x0011c9ba LAB_0011c9b7: XOR R14D,R14D LAB_0011c9ba: MOV RAX,R14 POP RBX POP R14 POP R15 RET LAB_0011c9c3: LEA RDI,[0x1637ec] LEA RSI,[0x17fe6a] LEA RCX,[0x17ff03] MOV EDX,0xf7 CALL 0x0010c540
long glfwGetInstanceProcAddress(int8 param_1,long param_2) { int iVar1; long lVar2; if (param_2 == 0) { /* WARNING: Subroutine does not return */ __assert_fail("procname != NULL", "/workspace/llm4binary/github/2025_star3/untodesu[P]riteg/build_O1/_deps/glfw-src/src/vulkan.c" ,0xf7,"GLFWvkproc glfwGetInstanceProcAddress(VkInstance, const char *)"); } if (_glfw == 0) { lVar2 = 0; _glfwInputError(0x10001,0); } else { iVar1 = _glfwInitVulkan(2); if (iVar1 == 0) { lVar2 = 0; } else { lVar2 = (*DAT_001c44d0)(param_1,param_2); if (lVar2 == 0) { lVar2 = dlsym(DAT_001c44b0,param_2); return lVar2; } } } return lVar2; }
47,486
mz_zip_reader_is_file_supported
7CodeWizard[P]stablediffusion/thirdparty/miniz.h
mz_bool mz_zip_reader_is_file_supported(mz_zip_archive *pZip, mz_uint file_index) { mz_uint bit_flag; mz_uint method; const mz_uint8 *p = mz_zip_get_cdh(pZip, file_index); if (!p) { mz_zip_set_error(pZip, MZ_ZIP_INVALID_PARAMETER); return MZ_FALSE; } method = MZ_READ_LE16(p + MZ_ZIP_CDH_METHOD_OFS); bit_flag = MZ_READ_LE16(p + MZ_ZIP_CDH_BIT_FLAG_OFS); if ((method != 0) && (method != MZ_DEFLATED)) { mz_zip_set_error(pZip, MZ_ZIP_UNSUPPORTED_METHOD); return MZ_FALSE; } if (bit_flag & (MZ_ZIP_GENERAL_PURPOSE_BIT_FLAG_IS_ENCRYPTED | MZ_ZIP_GENERAL_PURPOSE_BIT_FLAG_USES_STRONG_ENCRYPTION)) { mz_zip_set_error(pZip, MZ_ZIP_UNSUPPORTED_ENCRYPTION); return MZ_FALSE; } if (bit_flag & MZ_ZIP_GENERAL_PURPOSE_BIT_FLAG_COMPRESSED_PATCH_FLAG) { mz_zip_set_error(pZip, MZ_ZIP_UNSUPPORTED_FEATURE); return MZ_FALSE; } return MZ_TRUE; }
O0
c
mz_zip_reader_is_file_supported: movq %rdi, -0x60(%rsp) movl %esi, -0x64(%rsp) movq -0x60(%rsp), %rcx movl -0x64(%rsp), %eax movq %rcx, -0x10(%rsp) movl %eax, -0x14(%rsp) cmpq $0x0, -0x10(%rsp) je 0x10001d movq -0x10(%rsp), %rax cmpq $0x0, 0x68(%rax) je 0x10001d movl -0x14(%rsp), %eax movq -0x10(%rsp), %rcx cmpl 0x10(%rcx), %eax jb 0x100028 movq $0x0, -0x8(%rsp) jmp 0x100050 movq -0x10(%rsp), %rax movq 0x68(%rax), %rax movq (%rax), %rax movq -0x10(%rsp), %rcx movq 0x68(%rcx), %rcx movq 0x20(%rcx), %rcx movl -0x14(%rsp), %edx movl (%rcx,%rdx,4), %ecx addq %rcx, %rax movq %rax, -0x8(%rsp) movq -0x8(%rsp), %rax movq %rax, -0x78(%rsp) cmpq $0x0, -0x78(%rsp) jne 0x100095 movq -0x60(%rsp), %rax movq %rax, -0x20(%rsp) movl $0x18, -0x24(%rsp) cmpq $0x0, -0x20(%rsp) je 0x100088 movl -0x24(%rsp), %ecx movq -0x20(%rsp), %rax movl %ecx, 0x1c(%rax) movl $0x0, -0x58(%rsp) jmp 0x100170 movq -0x78(%rsp), %rax movzwl 0xa(%rax), %eax movl %eax, -0x6c(%rsp) movq -0x78(%rsp), %rax movzwl 0x8(%rax), %eax movl %eax, -0x68(%rsp) cmpl $0x0, -0x6c(%rsp) je 0x1000f0 cmpl $0x8, -0x6c(%rsp) je 0x1000f0 movq -0x60(%rsp), %rax movq %rax, -0x30(%rsp) movl $0x4, -0x34(%rsp) cmpq $0x0, -0x30(%rsp) je 0x1000e3 movl -0x34(%rsp), %ecx movq -0x30(%rsp), %rax movl %ecx, 0x1c(%rax) movl $0x0, -0x58(%rsp) jmp 0x100170 movl -0x68(%rsp), %eax andl $0x41, %eax cmpl $0x0, %eax je 0x10012c movq -0x60(%rsp), %rax movq %rax, -0x40(%rsp) movl $0x5, -0x44(%rsp) cmpq $0x0, -0x40(%rsp) je 0x100122 movl -0x44(%rsp), %ecx movq -0x40(%rsp), %rax movl %ecx, 0x1c(%rax) movl $0x0, -0x58(%rsp) jmp 0x100170 movl -0x68(%rsp), %eax andl $0x20, %eax cmpl $0x0, %eax je 0x100168 movq -0x60(%rsp), %rax movq %rax, -0x50(%rsp) movl $0x6, -0x54(%rsp) cmpq $0x0, -0x50(%rsp) je 0x10015e movl -0x54(%rsp), %ecx movq -0x50(%rsp), %rax movl %ecx, 0x1c(%rax) movl $0x0, -0x58(%rsp) jmp 0x100170 movl $0x1, -0x58(%rsp) movl -0x58(%rsp), %eax retq nopw %cs:(%rax,%rax)
mz_zip_reader_is_file_supported: mov [rsp+var_60], rdi mov [rsp+var_64], esi mov rcx, [rsp+var_60] mov eax, [rsp+var_64] mov [rsp+var_10], rcx mov [rsp+var_14], eax cmp [rsp+var_10], 0 jz short loc_10001D mov rax, [rsp+var_10] cmp qword ptr [rax+68h], 0 jz short loc_10001D mov eax, [rsp+var_14] mov rcx, [rsp+var_10] cmp eax, [rcx+10h] jb short loc_100028 loc_10001D: mov [rsp+var_8], 0 jmp short loc_100050 loc_100028: mov rax, [rsp+var_10] mov rax, [rax+68h] mov rax, [rax] mov rcx, [rsp+var_10] mov rcx, [rcx+68h] mov rcx, [rcx+20h] mov edx, [rsp+var_14] mov ecx, [rcx+rdx*4] add rax, rcx mov [rsp+var_8], rax loc_100050: mov rax, [rsp+var_8] mov [rsp+var_78], rax cmp [rsp+var_78], 0 jnz short loc_100095 mov rax, [rsp+var_60] mov [rsp+var_20], rax mov [rsp+var_24], 18h cmp [rsp+var_20], 0 jz short loc_100088 mov ecx, [rsp+var_24] mov rax, [rsp+var_20] mov [rax+1Ch], ecx loc_100088: mov [rsp+var_58], 0 jmp loc_100170 loc_100095: mov rax, [rsp+var_78] movzx eax, word ptr [rax+0Ah] mov [rsp+var_6C], eax mov rax, [rsp+var_78] movzx eax, word ptr [rax+8] mov [rsp+var_68], eax cmp [rsp+var_6C], 0 jz short loc_1000F0 cmp [rsp+var_6C], 8 jz short loc_1000F0 mov rax, [rsp+var_60] mov [rsp+var_30], rax mov [rsp+var_34], 4 cmp [rsp+var_30], 0 jz short loc_1000E3 mov ecx, [rsp+var_34] mov rax, [rsp+var_30] mov [rax+1Ch], ecx loc_1000E3: mov [rsp+var_58], 0 jmp loc_100170 loc_1000F0: mov eax, [rsp+var_68] and eax, 41h cmp eax, 0 jz short loc_10012C mov rax, [rsp+var_60] mov [rsp+var_40], rax mov [rsp+var_44], 5 cmp [rsp+var_40], 0 jz short loc_100122 mov ecx, [rsp+var_44] mov rax, [rsp+var_40] mov [rax+1Ch], ecx loc_100122: mov [rsp+var_58], 0 jmp short loc_100170 loc_10012C: mov eax, [rsp+var_68] and eax, 20h cmp eax, 0 jz short loc_100168 mov rax, [rsp+var_60] mov [rsp+var_50], rax mov [rsp+var_54], 6 cmp [rsp+var_50], 0 jz short loc_10015E mov ecx, [rsp+var_54] mov rax, [rsp+var_50] mov [rax+1Ch], ecx loc_10015E: mov [rsp+var_58], 0 jmp short loc_100170 loc_100168: mov [rsp+var_58], 1 loc_100170: mov eax, [rsp+var_58] retn
long long mz_zip_reader_is_file_supported(long long a1, unsigned int a2) { __int16 v3; // [rsp+10h] [rbp-68h] long long v5; // [rsp+70h] [rbp-8h] if ( a1 && *(_QWORD *)(a1 + 104) && a2 < *(_DWORD *)(a1 + 16) ) v5 = *(unsigned int *)(*(_QWORD *)(*(_QWORD *)(a1 + 104) + 32LL) + 4LL * a2) + **(_QWORD **)(a1 + 104); else v5 = 0LL; if ( v5 ) { v3 = *(_WORD *)(v5 + 8); if ( !*(_WORD *)(v5 + 10) || *(_WORD *)(v5 + 10) == 8 ) { if ( (v3 & 0x41) != 0 ) { if ( a1 ) *(_DWORD *)(a1 + 28) = 5; return 0; } else if ( (v3 & 0x20) != 0 ) { if ( a1 ) *(_DWORD *)(a1 + 28) = 6; return 0; } else { return 1; } } else { if ( a1 ) *(_DWORD *)(a1 + 28) = 4; return 0; } } else { if ( a1 ) *(_DWORD *)(a1 + 28) = 24; return 0; } }
mz_zip_reader_is_file_supported: MOV qword ptr [RSP + -0x60],RDI MOV dword ptr [RSP + -0x64],ESI MOV RCX,qword ptr [RSP + -0x60] MOV EAX,dword ptr [RSP + -0x64] MOV qword ptr [RSP + -0x10],RCX MOV dword ptr [RSP + -0x14],EAX CMP qword ptr [RSP + -0x10],0x0 JZ 0x0020001d MOV RAX,qword ptr [RSP + -0x10] CMP qword ptr [RAX + 0x68],0x0 JZ 0x0020001d MOV EAX,dword ptr [RSP + -0x14] MOV RCX,qword ptr [RSP + -0x10] CMP EAX,dword ptr [RCX + 0x10] JC 0x00200028 LAB_0020001d: MOV qword ptr [RSP + -0x8],0x0 JMP 0x00200050 LAB_00200028: MOV RAX,qword ptr [RSP + -0x10] MOV RAX,qword ptr [RAX + 0x68] MOV RAX,qword ptr [RAX] MOV RCX,qword ptr [RSP + -0x10] MOV RCX,qword ptr [RCX + 0x68] MOV RCX,qword ptr [RCX + 0x20] MOV EDX,dword ptr [RSP + -0x14] MOV ECX,dword ptr [RCX + RDX*0x4] ADD RAX,RCX MOV qword ptr [RSP + -0x8],RAX LAB_00200050: MOV RAX,qword ptr [RSP + -0x8] MOV qword ptr [RSP + -0x78],RAX CMP qword ptr [RSP + -0x78],0x0 JNZ 0x00200095 MOV RAX,qword ptr [RSP + -0x60] MOV qword ptr [RSP + -0x20],RAX MOV dword ptr [RSP + -0x24],0x18 CMP qword ptr [RSP + -0x20],0x0 JZ 0x00200088 MOV ECX,dword ptr [RSP + -0x24] MOV RAX,qword ptr [RSP + -0x20] MOV dword ptr [RAX + 0x1c],ECX LAB_00200088: MOV dword ptr [RSP + -0x58],0x0 JMP 0x00200170 LAB_00200095: MOV RAX,qword ptr [RSP + -0x78] MOVZX EAX,word ptr [RAX + 0xa] MOV dword ptr [RSP + -0x6c],EAX MOV RAX,qword ptr [RSP + -0x78] MOVZX EAX,word ptr [RAX + 0x8] MOV dword ptr [RSP + -0x68],EAX CMP dword ptr [RSP + -0x6c],0x0 JZ 0x002000f0 CMP dword ptr [RSP + -0x6c],0x8 JZ 0x002000f0 MOV RAX,qword ptr [RSP + -0x60] MOV qword ptr [RSP + -0x30],RAX MOV dword ptr [RSP + -0x34],0x4 CMP qword ptr [RSP + -0x30],0x0 JZ 0x002000e3 MOV ECX,dword ptr [RSP + -0x34] MOV RAX,qword ptr [RSP + -0x30] MOV dword ptr [RAX + 0x1c],ECX LAB_002000e3: MOV dword ptr [RSP + -0x58],0x0 JMP 0x00200170 LAB_002000f0: MOV EAX,dword ptr [RSP + -0x68] AND EAX,0x41 CMP EAX,0x0 JZ 0x0020012c MOV RAX,qword ptr [RSP + -0x60] MOV qword ptr [RSP + -0x40],RAX MOV dword ptr [RSP + -0x44],0x5 CMP qword ptr [RSP + -0x40],0x0 JZ 0x00200122 MOV ECX,dword ptr [RSP + -0x44] MOV RAX,qword ptr [RSP + -0x40] MOV dword ptr [RAX + 0x1c],ECX LAB_00200122: MOV dword ptr [RSP + -0x58],0x0 JMP 0x00200170 LAB_0020012c: MOV EAX,dword ptr [RSP + -0x68] AND EAX,0x20 CMP EAX,0x0 JZ 0x00200168 MOV RAX,qword ptr [RSP + -0x60] MOV qword ptr [RSP + -0x50],RAX MOV dword ptr [RSP + -0x54],0x6 CMP qword ptr [RSP + -0x50],0x0 JZ 0x0020015e MOV ECX,dword ptr [RSP + -0x54] MOV RAX,qword ptr [RSP + -0x50] MOV dword ptr [RAX + 0x1c],ECX LAB_0020015e: MOV dword ptr [RSP + -0x58],0x0 JMP 0x00200170 LAB_00200168: MOV dword ptr [RSP + -0x58],0x1 LAB_00200170: MOV EAX,dword ptr [RSP + -0x58] RET
int4 mz_zip_reader_is_file_supported(long param_1,uint param_2) { int4 local_58; int8 local_8; if (((param_1 == 0) || (*(long *)(param_1 + 0x68) == 0)) || (*(uint *)(param_1 + 0x10) <= param_2) ) { local_8 = 0; } else { local_8 = **(long **)(param_1 + 0x68) + (ulong)*(uint *)(*(long *)(*(long *)(param_1 + 0x68) + 0x20) + (ulong)param_2 * 4); } if (local_8 == 0) { if (param_1 != 0) { *(int4 *)(param_1 + 0x1c) = 0x18; } local_58 = 0; } else if ((*(short *)(local_8 + 10) == 0) || (*(short *)(local_8 + 10) == 8)) { if ((*(ushort *)(local_8 + 8) & 0x41) == 0) { if ((*(ushort *)(local_8 + 8) & 0x20) == 0) { local_58 = 1; } else { if (param_1 != 0) { *(int4 *)(param_1 + 0x1c) = 6; } local_58 = 0; } } else { if (param_1 != 0) { *(int4 *)(param_1 + 0x1c) = 5; } local_58 = 0; } } else { if (param_1 != 0) { *(int4 *)(param_1 + 0x1c) = 4; } local_58 = 0; } return local_58; }
47,487
mz_zip_reader_is_file_supported
7CodeWizard[P]stablediffusion/thirdparty/miniz.h
mz_bool mz_zip_reader_is_file_supported(mz_zip_archive *pZip, mz_uint file_index) { mz_uint bit_flag; mz_uint method; const mz_uint8 *p = mz_zip_get_cdh(pZip, file_index); if (!p) { mz_zip_set_error(pZip, MZ_ZIP_INVALID_PARAMETER); return MZ_FALSE; } method = MZ_READ_LE16(p + MZ_ZIP_CDH_METHOD_OFS); bit_flag = MZ_READ_LE16(p + MZ_ZIP_CDH_BIT_FLAG_OFS); if ((method != 0) && (method != MZ_DEFLATED)) { mz_zip_set_error(pZip, MZ_ZIP_UNSUPPORTED_METHOD); return MZ_FALSE; } if (bit_flag & (MZ_ZIP_GENERAL_PURPOSE_BIT_FLAG_IS_ENCRYPTED | MZ_ZIP_GENERAL_PURPOSE_BIT_FLAG_USES_STRONG_ENCRYPTION)) { mz_zip_set_error(pZip, MZ_ZIP_UNSUPPORTED_ENCRYPTION); return MZ_FALSE; } if (bit_flag & MZ_ZIP_GENERAL_PURPOSE_BIT_FLAG_COMPRESSED_PATCH_FLAG) { mz_zip_set_error(pZip, MZ_ZIP_UNSUPPORTED_FEATURE); return MZ_FALSE; } return MZ_TRUE; }
O3
c
mz_zip_reader_is_file_supported: xorl %eax, %eax testq %rdi, %rdi je 0x8333c movq 0x68(%rdi), %rdx movl $0x18, %ecx testq %rdx, %rdx je 0x83337 cmpl %esi, 0x10(%rdi) jbe 0x83337 movq (%rdx), %rax testq %rax, %rax je 0x83337 movq 0x20(%rdx), %rcx movl %esi, %edx movl (%rcx,%rdx,4), %edx movzwl 0xa(%rax,%rdx), %esi movl $0x4, %ecx testl $0xfff7, %esi # imm = 0xFFF7 jne 0x83337 movzwl 0x8(%rax,%rdx), %edx movl $0x5, %ecx testb $0x41, %dl jne 0x83337 movl $0x6, %ecx movl $0x1, %eax testb $0x20, %dl je 0x8333c movl %ecx, 0x1c(%rdi) xorl %eax, %eax retq
mz_zip_reader_is_file_supported: xor eax, eax test rdi, rdi jz short locret_8333C mov rdx, [rdi+68h] mov ecx, 18h test rdx, rdx jz short loc_83337 cmp [rdi+10h], esi jbe short loc_83337 mov rax, [rdx] test rax, rax jz short loc_83337 mov rcx, [rdx+20h] mov edx, esi mov edx, [rcx+rdx*4] movzx esi, word ptr [rax+rdx+0Ah] mov ecx, 4 test esi, 0FFF7h jnz short loc_83337 movzx edx, word ptr [rax+rdx+8] mov ecx, 5 test dl, 41h jnz short loc_83337 mov ecx, 6 mov eax, 1 test dl, 20h jz short locret_8333C loc_83337: mov [rdi+1Ch], ecx xor eax, eax locret_8333C: retn
long long mz_zip_reader_is_file_supported(long long a1, unsigned int a2) { long long result; // rax long long *v3; // rdx int v4; // ecx long long v5; // rax long long v6; // rdx __int16 v7; // dx result = 0LL; if ( a1 ) { v3 = *(long long **)(a1 + 104); v4 = 24; if ( !v3 || *(_DWORD *)(a1 + 16) <= a2 || (v5 = *v3) == 0 || (v6 = *(unsigned int *)(v3[4] + 4LL * a2), v4 = 4, (*(_WORD *)(v5 + v6 + 10) & 0xFFF7) != 0) || (v7 = *(_WORD *)(v5 + v6 + 8), v4 = 5, (v7 & 0x41) != 0) || (v4 = 6, result = 1LL, (v7 & 0x20) != 0) ) { *(_DWORD *)(a1 + 28) = v4; return 0LL; } } return result; }
47,488
void nlohmann::json_abi_v3_11_3::detail::from_json<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::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> 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>::string_t&)
monkey531[P]llama/common/json.hpp
inline void from_json(const BasicJsonType& j, typename BasicJsonType::string_t& s) { if (JSON_HEDLEY_UNLIKELY(!j.is_string())) { JSON_THROW(type_error::create(302, concat("type must be string, but is ", j.type_name()), &j)); } s = *j.template get_ptr<const typename BasicJsonType::string_t*>(); }
O3
cpp
void nlohmann::json_abi_v3_11_3::detail::from_json<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::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> 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>::string_t&): pushq %rbp pushq %r14 pushq %rbx subq $0x30, %rsp movq %rdi, %r14 cmpb $0x3, (%rdi) jne 0x468c2 movq 0x8(%r14), %rax movq %rsi, %rdi movq %rax, %rsi addq $0x30, %rsp popq %rbx popq %r14 popq %rbp jmp 0x193d0 movl $0x20, %edi callq 0x19370 movq %rax, %rbx movq %r14, %rdi callq 0x374f2 leaq 0x8(%rsp), %rdx movq %rax, (%rdx) leaq 0x71078(%rip), %rsi # 0xb795e leaq 0x10(%rsp), %rdi callq 0x46958 movb $0x1, %bpl leaq 0x10(%rsp), %rdx movq %rbx, %rdi movl $0x12e, %esi # imm = 0x12E movq %r14, %rcx callq 0x465f6 xorl %ebp, %ebp leaq 0xa2877(%rip), %rsi # 0xe9188 leaq -0x13196(%rip), %rdx # 0x33782 movq %rbx, %rdi callq 0x19ba0 movq %rax, %r14 leaq 0x20(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0x4693e movq 0x20(%rsp), %rsi incq %rsi callq 0x196d0 testb %bpl, %bpl jne 0x46948 jmp 0x46950 movq %rax, %r14 movq %rbx, %rdi callq 0x19510 movq %r14, %rdi callq 0x19c00
_ZN8nlohmann16json_abi_v3_11_36detail9from_jsonINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEEvRKT_RNSG_8string_tE: push rbp; char push r14; int push rbx; __int64 sub rsp, 30h mov r14, rdi cmp byte ptr [rdi], 3 jnz short loc_468C2 mov rax, [r14+8] mov rdi, rsi mov rsi, rax add rsp, 30h pop rbx pop r14 pop rbp jmp __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9_M_assignERKS4_; std::string::_M_assign(std::string const&) loc_468C2: mov edi, 20h ; ' '; thrown_size call ___cxa_allocate_exception mov rbx, rax mov rdi, r14 call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE9type_nameEv; 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>::type_name(void) lea rdx, [rsp+48h+var_40] mov [rdx], rax lea rsi, aTypeMustBeStri; "type must be string, but is " lea rdi, [rsp+48h+var_38] call _ZN8nlohmann16json_abi_v3_11_36detail6concatINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEJRA29_KcPS9_EEET_DpOT0_; nlohmann::json_abi_v3_11_3::detail::concat<std::string,char const(&)[29],char const*>(char const(&)[29],char const* &&) mov bpl, 1 lea rdx, [rsp+48h+var_38] mov rdi, rbx; this mov esi, 12Eh; int mov rcx, r14 call _ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIPKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SK_ xor ebp, ebp lea rsi, _ZTIN8nlohmann16json_abi_v3_11_36detail10type_errorE; lptinfo lea rdx, _ZN8nlohmann16json_abi_v3_11_36detail9exceptionD2Ev; void (*)(void *) mov rdi, rbx; void * call ___cxa_throw mov r14, rax lea rax, [rsp+48h+var_28] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_4693E mov rsi, [rsp+48h+var_28] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_4693E: test bpl, bpl jnz short loc_46948 jmp short loc_46950 mov r14, rax loc_46948: mov rdi, rbx; void * call ___cxa_free_exception loc_46950: mov rdi, r14 call __Unwind_Resume
long long nlohmann::json_abi_v3_11_3::detail::from_json<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 a1, long long a2) { nlohmann::json_abi_v3_11_3::detail::exception *exception; // rbx _QWORD v4[2]; // [rsp+10h] [rbp-38h] BYREF if ( *(_BYTE *)a1 != 3 ) { exception = (nlohmann::json_abi_v3_11_3::detail::exception *)__cxa_allocate_exception(0x20uLL); 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>::type_name((unsigned __int8 *)a1); nlohmann::json_abi_v3_11_3::detail::concat<std::string,char const(&)[29],char const*>( v4, "type must be string, but is "); ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIPKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SK_( exception, 302, v4); __cxa_throw( exception, (struct type_info *)&`typeinfo for'nlohmann::json_abi_v3_11_3::detail::type_error, (void (*)(void *))nlohmann::json_abi_v3_11_3::detail::exception::~exception); } return std::string::_M_assign(a2, *(_QWORD *)(a1 + 8)); }
from_json<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>>: PUSH RBP PUSH R14 PUSH RBX SUB RSP,0x30 MOV R14,RDI CMP byte ptr [RDI],0x3 JNZ 0x001468c2 MOV RAX,qword ptr [R14 + 0x8] MOV RDI,RSI MOV RSI,RAX ADD RSP,0x30 POP RBX POP R14 POP RBP JMP 0x001193d0 LAB_001468c2: MOV EDI,0x20 CALL 0x00119370 MOV RBX,RAX MOV RDI,R14 CALL 0x001374f2 LEA RDX,[RSP + 0x8] MOV qword ptr [RDX],RAX LAB_001468df: LEA RSI,[0x1b795e] LEA RDI,[RSP + 0x10] CALL 0x00146958 MOV BPL,0x1 LAB_001468f3: LEA RDX,[RSP + 0x10] MOV RDI,RBX MOV ESI,0x12e MOV RCX,R14 CALL 0x001465f6 XOR EBP,EBP LEA RSI,[0x1e9188] LEA RDX,[0x133782] MOV RDI,RBX CALL 0x00119ba0
/* void nlohmann::json_abi_v3_11_3::detail::from_json<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::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&, 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>::string_t&) */ void nlohmann::json_abi_v3_11_3::detail:: from_json<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>> (basic_json *param_1,string_t *param_2) { int8 uVar1; char *local_40; detail local_38 [32]; if (*param_1 == (basic_json)0x3) { std::__cxx11::string::_M_assign((string *)param_2); return; } uVar1 = __cxa_allocate_exception(0x20); local_40 = (char *)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> ::type_name((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> *)param_1); /* try { // try from 001468df to 001468ef has its CatchHandler @ 00146945 */ concat<std::__cxx11::string,char_const(&)[29],char_const*> (local_38,"type must be string, but is ",&local_40); /* try { // try from 001468f3 to 0014691f has its CatchHandler @ 00146920 */ _ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIPKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SK_ (uVar1,0x12e,local_38,param_1); /* WARNING: Subroutine does not return */ __cxa_throw(uVar1,&type_error::typeinfo,exception::~exception); }
47,489
my_long10_to_str_8bit
eloqsql/strings/ctype-simple.c
size_t my_long10_to_str_8bit(CHARSET_INFO *cs __attribute__((unused)), char *dst, size_t len, int radix, long int val) { char buffer[66]; register char *p, *e; long int new_val; uint sign=0; unsigned long int uval = (unsigned long int) val; e = p = &buffer[sizeof(buffer)-1]; *p= 0; if (radix < 0) { if (val < 0) { /* Avoid integer overflow in (-val) for LONGLONG_MIN (BUG#31799). */ uval= (unsigned long int)0 - uval; *dst++= '-'; len--; sign= 1; } } new_val = (long) (uval / 10); *--p = '0'+ (char) (uval - (unsigned long) new_val * 10); val = new_val; while (val != 0) { new_val=val/10; *--p = '0' + (char) (val-new_val*10); val= new_val; } len= MY_MIN(len, (size_t) (e-p)); memcpy(dst, p, len); return len+sign; }
O0
c
my_long10_to_str_8bit: pushq %rbp movq %rsp, %rbp subq $0xb0, %rsp movq %fs:0x28, %rax movq %rax, -0x8(%rbp) movq %rdi, -0x58(%rbp) movq %rsi, -0x60(%rbp) movq %rdx, -0x68(%rbp) movl %ecx, -0x6c(%rbp) movq %r8, -0x78(%rbp) movl $0x0, -0x94(%rbp) movq -0x78(%rbp), %rax movq %rax, -0xa0(%rbp) leaq -0x50(%rbp), %rax addq $0x41, %rax movq %rax, -0x80(%rbp) movq %rax, -0x88(%rbp) movq -0x80(%rbp), %rax movb $0x0, (%rax) cmpl $0x0, -0x6c(%rbp) jge 0x4a571 cmpq $0x0, -0x78(%rbp) jge 0x4a56f xorl %eax, %eax subq -0xa0(%rbp), %rax movq %rax, -0xa0(%rbp) movq -0x60(%rbp), %rax movq %rax, %rcx addq $0x1, %rcx movq %rcx, -0x60(%rbp) movb $0x2d, (%rax) movq -0x68(%rbp), %rax addq $-0x1, %rax movq %rax, -0x68(%rbp) movl $0x1, -0x94(%rbp) jmp 0x4a571 movq -0xa0(%rbp), %rax movl $0xa, %ecx xorl %edx, %edx divq %rcx movq %rax, -0x90(%rbp) movq -0xa0(%rbp), %rax imulq $0xa, -0x90(%rbp), %rcx subq %rcx, %rax movsbl %al, %eax addl $0x30, %eax movb %al, %cl movq -0x80(%rbp), %rax movq %rax, %rdx addq $-0x1, %rdx movq %rdx, -0x80(%rbp) movb %cl, -0x1(%rax) movq -0x90(%rbp), %rax movq %rax, -0x78(%rbp) cmpq $0x0, -0x78(%rbp) je 0x4a612 movq -0x78(%rbp), %rax movl $0xa, %ecx cqto idivq %rcx movq %rax, -0x90(%rbp) movq -0x78(%rbp), %rax imulq $0xa, -0x90(%rbp), %rcx subq %rcx, %rax movsbl %al, %eax addl $0x30, %eax movb %al, %cl movq -0x80(%rbp), %rax movq %rax, %rdx addq $-0x1, %rdx movq %rdx, -0x80(%rbp) movb %cl, -0x1(%rax) movq -0x90(%rbp), %rax movq %rax, -0x78(%rbp) jmp 0x4a5c0 movq -0x68(%rbp), %rax movq -0x88(%rbp), %rcx movq -0x80(%rbp), %rdx subq %rdx, %rcx cmpq %rcx, %rax jae 0x4a636 movq -0x68(%rbp), %rax movq %rax, -0xa8(%rbp) jmp 0x4a64b movq -0x88(%rbp), %rax movq -0x80(%rbp), %rcx subq %rcx, %rax movq %rax, -0xa8(%rbp) movq -0xa8(%rbp), %rax movq %rax, -0x68(%rbp) movq -0x60(%rbp), %rdi movq -0x80(%rbp), %rsi movq -0x68(%rbp), %rdx callq 0x24230 movq -0x68(%rbp), %rax movl -0x94(%rbp), %ecx addq %rcx, %rax movq %rax, -0xb0(%rbp) movq %fs:0x28, %rax movq -0x8(%rbp), %rcx cmpq %rcx, %rax jne 0x4a69d movq -0xb0(%rbp), %rax addq $0xb0, %rsp popq %rbp retq callq 0x24330 nopw %cs:(%rax,%rax)
my_long10_to_str_8bit: push rbp mov rbp, rsp sub rsp, 0B0h mov rax, fs:28h mov [rbp+var_8], rax mov [rbp+var_58], rdi mov [rbp+var_60], rsi mov [rbp+var_68], rdx mov [rbp+var_6C], ecx mov [rbp+var_78], r8 mov [rbp+var_94], 0 mov rax, [rbp+var_78] mov [rbp+var_A0], rax lea rax, [rbp+var_50] add rax, 41h ; 'A' mov [rbp+var_80], rax mov [rbp+var_88], rax mov rax, [rbp+var_80] mov byte ptr [rax], 0 cmp [rbp+var_6C], 0 jge short loc_4A571 cmp [rbp+var_78], 0 jge short loc_4A56F xor eax, eax sub rax, [rbp+var_A0] mov [rbp+var_A0], rax mov rax, [rbp+var_60] mov rcx, rax add rcx, 1 mov [rbp+var_60], rcx mov byte ptr [rax], 2Dh ; '-' mov rax, [rbp+var_68] add rax, 0FFFFFFFFFFFFFFFFh mov [rbp+var_68], rax mov [rbp+var_94], 1 loc_4A56F: jmp short $+2 loc_4A571: mov rax, [rbp+var_A0] mov ecx, 0Ah xor edx, edx div rcx mov [rbp+var_90], rax mov rax, [rbp+var_A0] imul rcx, [rbp+var_90], 0Ah sub rax, rcx movsx eax, al add eax, 30h ; '0' mov cl, al mov rax, [rbp+var_80] mov rdx, rax add rdx, 0FFFFFFFFFFFFFFFFh mov [rbp+var_80], rdx mov [rax-1], cl mov rax, [rbp+var_90] mov [rbp+var_78], rax loc_4A5C0: cmp [rbp+var_78], 0 jz short loc_4A612 mov rax, [rbp+var_78] mov ecx, 0Ah cqo idiv rcx mov [rbp+var_90], rax mov rax, [rbp+var_78] imul rcx, [rbp+var_90], 0Ah sub rax, rcx movsx eax, al add eax, 30h ; '0' mov cl, al mov rax, [rbp+var_80] mov rdx, rax add rdx, 0FFFFFFFFFFFFFFFFh mov [rbp+var_80], rdx mov [rax-1], cl mov rax, [rbp+var_90] mov [rbp+var_78], rax jmp short loc_4A5C0 loc_4A612: mov rax, [rbp+var_68] mov rcx, [rbp+var_88] mov rdx, [rbp+var_80] sub rcx, rdx cmp rax, rcx jnb short loc_4A636 mov rax, [rbp+var_68] mov [rbp+var_A8], rax jmp short loc_4A64B loc_4A636: mov rax, [rbp+var_88] mov rcx, [rbp+var_80] sub rax, rcx mov [rbp+var_A8], rax loc_4A64B: mov rax, [rbp+var_A8] mov [rbp+var_68], rax mov rdi, [rbp+var_60] mov rsi, [rbp+var_80] mov rdx, [rbp+var_68] call _memcpy mov rax, [rbp+var_68] mov ecx, [rbp+var_94] add rax, rcx mov [rbp+var_B0], rax mov rax, fs:28h mov rcx, [rbp+var_8] cmp rax, rcx jnz short loc_4A69D mov rax, [rbp+var_B0] add rsp, 0B0h pop rbp retn loc_4A69D: call ___stack_chk_fail
_BYTE * my_long10_to_str_8bit(long long a1, _BYTE *a2, _BYTE *a3, int a4, long long a5) { char *v5; // rax _BYTE *v7; // [rsp+8h] [rbp-A8h] unsigned long long v8; // [rsp+10h] [rbp-A0h] unsigned int v9; // [rsp+1Ch] [rbp-94h] char *v10; // [rsp+30h] [rbp-80h] signed long long i; // [rsp+38h] [rbp-78h] _BYTE *v12; // [rsp+48h] [rbp-68h] _BYTE *v13; // [rsp+50h] [rbp-60h] char v14; // [rsp+A0h] [rbp-10h] BYREF _BYTE v15[7]; // [rsp+A1h] [rbp-Fh] BYREF unsigned long long v16; // [rsp+A8h] [rbp-8h] v16 = __readfsqword(0x28u); v13 = a2; v12 = a3; v9 = 0; v8 = a5; v15[0] = 0; if ( a4 < 0 && a5 < 0 ) { v8 = -a5; v13 = a2 + 1; *a2 = 45; v12 = a3 - 1; v9 = 1; } v10 = &v14; v14 = v8 % 0xA + 48; for ( i = v8 / 0xA; i; i /= 10LL ) { v5 = v10--; *(v5 - 1) = i % 10 + 48; } if ( (unsigned long long)v12 >= v15 - v10 ) v7 = (_BYTE *)(v15 - v10); else v7 = v12; memcpy(v13, v10, v7); return &v7[v9]; }
my_long10_to_str_8bit: PUSH RBP MOV RBP,RSP SUB RSP,0xb0 MOV RAX,qword ptr FS:[0x28] MOV qword ptr [RBP + -0x8],RAX MOV qword ptr [RBP + -0x58],RDI MOV qword ptr [RBP + -0x60],RSI MOV qword ptr [RBP + -0x68],RDX MOV dword ptr [RBP + -0x6c],ECX MOV qword ptr [RBP + -0x78],R8 MOV dword ptr [RBP + -0x94],0x0 MOV RAX,qword ptr [RBP + -0x78] MOV qword ptr [RBP + -0xa0],RAX LEA RAX,[RBP + -0x50] ADD RAX,0x41 MOV qword ptr [RBP + -0x80],RAX MOV qword ptr [RBP + -0x88],RAX MOV RAX,qword ptr [RBP + -0x80] MOV byte ptr [RAX],0x0 CMP dword ptr [RBP + -0x6c],0x0 JGE 0x0014a571 CMP qword ptr [RBP + -0x78],0x0 JGE 0x0014a56f XOR EAX,EAX SUB RAX,qword ptr [RBP + -0xa0] MOV qword ptr [RBP + -0xa0],RAX MOV RAX,qword ptr [RBP + -0x60] MOV RCX,RAX ADD RCX,0x1 MOV qword ptr [RBP + -0x60],RCX MOV byte ptr [RAX],0x2d MOV RAX,qword ptr [RBP + -0x68] ADD RAX,-0x1 MOV qword ptr [RBP + -0x68],RAX MOV dword ptr [RBP + -0x94],0x1 LAB_0014a56f: JMP 0x0014a571 LAB_0014a571: MOV RAX,qword ptr [RBP + -0xa0] MOV ECX,0xa XOR EDX,EDX DIV RCX MOV qword ptr [RBP + -0x90],RAX MOV RAX,qword ptr [RBP + -0xa0] IMUL RCX,qword ptr [RBP + -0x90],0xa SUB RAX,RCX MOVSX EAX,AL ADD EAX,0x30 MOV CL,AL MOV RAX,qword ptr [RBP + -0x80] MOV RDX,RAX ADD RDX,-0x1 MOV qword ptr [RBP + -0x80],RDX MOV byte ptr [RAX + -0x1],CL MOV RAX,qword ptr [RBP + -0x90] MOV qword ptr [RBP + -0x78],RAX LAB_0014a5c0: CMP qword ptr [RBP + -0x78],0x0 JZ 0x0014a612 MOV RAX,qword ptr [RBP + -0x78] MOV ECX,0xa CQO IDIV RCX MOV qword ptr [RBP + -0x90],RAX MOV RAX,qword ptr [RBP + -0x78] IMUL RCX,qword ptr [RBP + -0x90],0xa SUB RAX,RCX MOVSX EAX,AL ADD EAX,0x30 MOV CL,AL MOV RAX,qword ptr [RBP + -0x80] MOV RDX,RAX ADD RDX,-0x1 MOV qword ptr [RBP + -0x80],RDX MOV byte ptr [RAX + -0x1],CL MOV RAX,qword ptr [RBP + -0x90] MOV qword ptr [RBP + -0x78],RAX JMP 0x0014a5c0 LAB_0014a612: MOV RAX,qword ptr [RBP + -0x68] MOV RCX,qword ptr [RBP + -0x88] MOV RDX,qword ptr [RBP + -0x80] SUB RCX,RDX CMP RAX,RCX JNC 0x0014a636 MOV RAX,qword ptr [RBP + -0x68] MOV qword ptr [RBP + -0xa8],RAX JMP 0x0014a64b LAB_0014a636: MOV RAX,qword ptr [RBP + -0x88] MOV RCX,qword ptr [RBP + -0x80] SUB RAX,RCX MOV qword ptr [RBP + -0xa8],RAX LAB_0014a64b: MOV RAX,qword ptr [RBP + -0xa8] MOV qword ptr [RBP + -0x68],RAX MOV RDI,qword ptr [RBP + -0x60] MOV RSI,qword ptr [RBP + -0x80] MOV RDX,qword ptr [RBP + -0x68] CALL 0x00124230 MOV RAX,qword ptr [RBP + -0x68] MOV ECX,dword ptr [RBP + -0x94] ADD RAX,RCX MOV qword ptr [RBP + -0xb0],RAX MOV RAX,qword ptr FS:[0x28] MOV RCX,qword ptr [RBP + -0x8] CMP RAX,RCX JNZ 0x0014a69d MOV RAX,qword ptr [RBP + -0xb0] ADD RSP,0xb0 POP RBP RET LAB_0014a69d: CALL 0x00124330
char * my_long10_to_str_8bit (int8 param_1,int1 *param_2,char *param_3,int param_4,ulong param_5) { long in_FS_OFFSET; char *local_b0; ulong local_a8; uint local_9c; char *local_88; ulong local_80; char *local_70; int1 *local_68; char local_19 [9]; long local_10; local_10 = *(long *)(in_FS_OFFSET + 0x28); local_9c = 0; local_19[2] = 0; local_a8 = param_5; local_70 = param_3; local_68 = param_2; if (param_4 < 0) { if ((long)param_5 < 0) { local_a8 = -param_5; local_68 = param_2 + 1; *param_2 = 0x2d; local_70 = param_3 + -1; } local_9c = (uint)((long)param_5 < 0); } local_19[1] = (char)local_a8 + (char)(local_a8 / 10) * -10 + '0'; local_88 = local_19 + 1; local_80 = local_a8 / 10; while (local_80 != 0) { local_88[-1] = (char)local_80 + (char)((long)local_80 / 10) * -10 + '0'; local_88 = local_88 + -1; local_80 = (long)local_80 / 10; } if (local_70 < local_19 + (2 - (long)local_88)) { local_b0 = local_70; } else { local_b0 = local_19 + (2 - (long)local_88); } memcpy(local_68,local_88,(size_t)local_b0); if (*(long *)(in_FS_OFFSET + 0x28) == local_10) { return local_b0 + local_9c; } /* WARNING: Subroutine does not return */ __stack_chk_fail(); }
47,490
my_long10_to_str_8bit
eloqsql/strings/ctype-simple.c
size_t my_long10_to_str_8bit(CHARSET_INFO *cs __attribute__((unused)), char *dst, size_t len, int radix, long int val) { char buffer[66]; register char *p, *e; long int new_val; uint sign=0; unsigned long int uval = (unsigned long int) val; e = p = &buffer[sizeof(buffer)-1]; *p= 0; if (radix < 0) { if (val < 0) { /* Avoid integer overflow in (-val) for LONGLONG_MIN (BUG#31799). */ uval= (unsigned long int)0 - uval; *dst++= '-'; len--; sign= 1; } } new_val = (long) (uval / 10); *--p = '0'+ (char) (uval - (unsigned long) new_val * 10); val = new_val; while (val != 0) { new_val=val/10; *--p = '0' + (char) (val-new_val*10); val= new_val; } len= MY_MIN(len, (size_t) (e-p)); memcpy(dst, p, len); return len+sign; }
O3
c
my_long10_to_str_8bit: pushq %rbp movq %rsp, %rbp pushq %r14 pushq %rbx subq $0x50, %rsp movq %rdx, %r10 movq %rsi, %rdi movq %fs:0x28, %rax movq %rax, -0x18(%rbp) movb $0x0, -0x1f(%rbp) testl %ecx, %ecx setns %al testq %r8, %r8 setns %cl orb %al, %cl jne 0x3c5af negq %r8 movb $0x2d, (%rdi) incq %rdi decq %r10 movl $0x1, %r14d jmp 0x3c5b2 xorl %r14d, %r14d leaq -0x1f(%rbp), %rbx movabsq $-0x3333333333333333, %rcx # imm = 0xCCCCCCCCCCCCCCCD movq %r8, %rax mulq %rcx movq %rdx, %r9 shrq $0x3, %r9 imull $0xf6, %r9d, %eax addl %r8d, %eax addb $0x30, %al leaq -0x20(%rbp), %rsi movb %al, (%rsi) cmpq $0xa, %r8 jb 0x3c609 movq %r9, %rax mulq %rcx shrq $0x3, %rdx imull $0xf6, %edx, %eax addl %r9d, %eax addb $0x30, %al movb %al, -0x1(%rsi) decq %rsi cmpq $0x9, %r9 movq %rdx, %r9 ja 0x3c5e5 subq %rsi, %rbx cmpq %rbx, %r10 cmovbq %r10, %rbx movq %rbx, %rdx callq 0x24240 movq %fs:0x28, %rax cmpq -0x18(%rbp), %rax jne 0x3c639 addq %r14, %rbx movq %rbx, %rax addq $0x50, %rsp popq %rbx popq %r14 popq %rbp retq callq 0x24370
my_long10_to_str_8bit: push rbp mov rbp, rsp push r14 push rbx sub rsp, 50h mov r10, rdx mov rdi, rsi mov rax, fs:28h mov [rbp+var_18], rax mov [rbp+var_1F], 0 test ecx, ecx setns al test r8, r8 setns cl or cl, al jnz short loc_3C5AF neg r8 mov byte ptr [rdi], 2Dh ; '-' inc rdi dec r10 mov r14d, 1 jmp short loc_3C5B2 loc_3C5AF: xor r14d, r14d loc_3C5B2: lea rbx, [rbp+var_1F] mov rcx, 0CCCCCCCCCCCCCCCDh mov rax, r8 mul rcx mov r9, rdx shr r9, 3 imul eax, r9d, 0F6h add eax, r8d add al, 30h ; '0' lea rsi, [rbp+var_20] mov [rsi], al cmp r8, 0Ah jb short loc_3C609 loc_3C5E5: mov rax, r9 mul rcx shr rdx, 3 imul eax, edx, 0F6h add eax, r9d add al, 30h ; '0' mov [rsi-1], al dec rsi cmp r9, 9 mov r9, rdx ja short loc_3C5E5 loc_3C609: sub rbx, rsi cmp r10, rbx cmovb rbx, r10 mov rdx, rbx call _memcpy mov rax, fs:28h cmp rax, [rbp+var_18] jnz short loc_3C639 add rbx, r14 mov rax, rbx add rsp, 50h pop rbx pop r14 pop rbp retn loc_3C639: call ___stack_chk_fail
_BYTE * my_long10_to_str_8bit(long long a1, _BYTE *a2, _BYTE *a3, int a4, unsigned long long a5) { _BYTE *v5; // r10 _BYTE *v6; // rdi long long v7; // r14 unsigned long long v8; // r9 char *v9; // rsi bool v10; // cf bool v11; // zf _BYTE *v12; // rbx char v14; // [rsp+40h] [rbp-20h] BYREF _BYTE v15[7]; // [rsp+41h] [rbp-1Fh] BYREF unsigned long long v16; // [rsp+48h] [rbp-18h] v5 = a3; v6 = a2; v16 = __readfsqword(0x28u); v15[0] = 0; if ( a4 >= 0 || (a5 & 0x8000000000000000LL) == 0LL ) { v7 = 0LL; } else { a5 = -(long long)a5; *a2 = 45; v6 = a2 + 1; v5 = a3 - 1; v7 = 1LL; } v8 = a5 / 0xA; v9 = &v14; v14 = a5 % 0xA + 48; if ( a5 >= 0xA ) { do { *--v9 = v8 % 0xA + 48; v10 = v8 < 9; v11 = v8 == 9; v8 /= 0xAuLL; } while ( !v10 && !v11 ); } v12 = (_BYTE *)(v15 - v9); if ( (unsigned long long)v5 < v15 - v9 ) v12 = v5; memcpy(v6, v9, v12); return &v12[v7]; }
my_long10_to_str_8bit: PUSH RBP MOV RBP,RSP PUSH R14 PUSH RBX SUB RSP,0x50 MOV R10,RDX MOV RDI,RSI MOV RAX,qword ptr FS:[0x28] MOV qword ptr [RBP + -0x18],RAX MOV byte ptr [RBP + -0x1f],0x0 TEST ECX,ECX SETNS AL TEST R8,R8 SETNS CL OR CL,AL JNZ 0x0013c5af NEG R8 MOV byte ptr [RDI],0x2d INC RDI DEC R10 MOV R14D,0x1 JMP 0x0013c5b2 LAB_0013c5af: XOR R14D,R14D LAB_0013c5b2: LEA RBX,[RBP + -0x1f] MOV RCX,-0x3333333333333333 MOV RAX,R8 MUL RCX MOV R9,RDX SHR R9,0x3 IMUL EAX,R9D,0xf6 ADD EAX,R8D ADD AL,0x30 LEA RSI,[RBP + -0x20] MOV byte ptr [RSI],AL CMP R8,0xa JC 0x0013c609 LAB_0013c5e5: MOV RAX,R9 MUL RCX SHR RDX,0x3 IMUL EAX,EDX,0xf6 ADD EAX,R9D ADD AL,0x30 MOV byte ptr [RSI + -0x1],AL DEC RSI CMP R9,0x9 MOV R9,RDX JA 0x0013c5e5 LAB_0013c609: SUB RBX,RSI CMP R10,RBX CMOVC RBX,R10 MOV RDX,RBX CALL 0x00124240 MOV RAX,qword ptr FS:[0x28] CMP RAX,qword ptr [RBP + -0x18] JNZ 0x0013c639 ADD RBX,R14 MOV RAX,RBX ADD RSP,0x50 POP RBX POP R14 POP RBP RET LAB_0013c639: CALL 0x00124370
char * my_long10_to_str_8bit (int8 param_1,int1 *param_2,char *param_3,int param_4,ulong param_5) { ulong uVar1; ulong uVar2; char *__n; char *__src; long in_FS_OFFSET; bool bVar3; char local_29 [9]; long local_20; local_20 = *(long *)(in_FS_OFFSET + 0x28); local_29[2] = 0; bVar3 = (long)param_5 < 0; if (bVar3 && param_4 < 0) { param_5 = -param_5; *param_2 = 0x2d; param_2 = param_2 + 1; param_3 = param_3 + -1; } local_29[1] = (char)(param_5 / 10) * -10 + (char)param_5 + '0'; __src = local_29 + 1; uVar2 = param_5 / 10; while (uVar1 = uVar2, 9 < param_5) { __src[-1] = (char)(uVar1 / 10) * -10 + (char)uVar1 + '0'; __src = __src + -1; uVar2 = uVar1 / 10; param_5 = uVar1; } __n = local_29 + (2 - (long)__src); if (param_3 < local_29 + (2 - (long)__src)) { __n = param_3; } memcpy(param_2,__src,(size_t)__n); if (*(long *)(in_FS_OFFSET + 0x28) == local_20) { return __n + (bVar3 && param_4 < 0); } /* WARNING: Subroutine does not return */ __stack_chk_fail(); }
47,491
JS_ToCStringLen2
bluesky950520[P]quickjs/quickjs.c
const char *JS_ToCStringLen2(JSContext *ctx, size_t *plen, JSValue val1, BOOL cesu8) { JSValue val; JSString *str, *str_new; int pos, len, c, c1; JSObject *p; uint8_t *q; if (JS_VALUE_GET_TAG(val1) == JS_TAG_STRING) { val = js_dup(val1); goto go; } val = JS_ToString(ctx, val1); if (!JS_IsException(val)) goto go; // Stringification can fail when there is an exception pending, // e.g. a stack overflow InternalError. Special-case exception // objects to make debugging easier, look up the .message property // and stringify that. if (JS_VALUE_GET_TAG(val1) != JS_TAG_OBJECT) goto fail; p = JS_VALUE_GET_OBJ(val1); if (p->class_id != JS_CLASS_ERROR) goto fail; val = JS_GetProperty(ctx, val1, JS_ATOM_message); if (JS_VALUE_GET_TAG(val) != JS_TAG_STRING) { JS_FreeValue(ctx, val); goto fail; } go: str = JS_VALUE_GET_STRING(val); len = str->len; if (!str->is_wide_char) { const uint8_t *src = str->u.str8; int count; /* count the number of non-ASCII characters */ /* Scanning the whole string is required for ASCII strings, and computing the number of non-ASCII bytes is less expensive than testing each byte, hence this method is faster for ASCII strings, which is the most common case. */ count = 0; for (pos = 0; pos < len; pos++) { count += src[pos] >> 7; } if (count == 0) { if (plen) *plen = len; return (const char *)src; } str_new = js_alloc_string(ctx, len + count, 0); if (!str_new) goto fail; q = str_new->u.str8; for (pos = 0; pos < len; pos++) { c = src[pos]; if (c < 0x80) { *q++ = c; } else { *q++ = (c >> 6) | 0xc0; *q++ = (c & 0x3f) | 0x80; } } } else { const uint16_t *src = str->u.str16; /* Allocate 3 bytes per 16 bit code point. Surrogate pairs may produce 4 bytes but use 2 code points. */ str_new = js_alloc_string(ctx, len * 3, 0); if (!str_new) goto fail; q = str_new->u.str8; pos = 0; while (pos < len) { c = src[pos++]; if (c < 0x80) { *q++ = c; } else { if (is_hi_surrogate(c)) { if (pos < len && !cesu8) { c1 = src[pos]; if (is_lo_surrogate(c1)) { pos++; c = from_surrogate(c, c1); } else { /* Keep unmatched surrogate code points */ /* c = 0xfffd; */ /* error */ } } else { /* Keep unmatched surrogate code points */ /* c = 0xfffd; */ /* error */ } } q += utf8_encode(q, c); } } } *q = '\0'; str_new->len = q - str_new->u.str8; JS_FreeValue(ctx, val); if (plen) *plen = str_new->len; return (const char *)str_new->u.str8; fail: if (plen) *plen = 0; return NULL; }
O0
c
JS_ToCStringLen2: subq $0xb8, %rsp movq %rdx, 0xa0(%rsp) movq %rcx, 0xa8(%rsp) movq %rdi, 0x98(%rsp) movq %rsi, 0x90(%rsp) movl %r8d, 0x8c(%rsp) movq 0xa8(%rsp), %rax cmpl $-0x7, %eax jne 0x298c7 movq 0xa0(%rsp), %rdi movq 0xa8(%rsp), %rsi callq 0x216d0 movq %rax, 0x38(%rsp) movq %rdx, 0x40(%rsp) movq 0x38(%rsp), %rax movq %rax, 0x78(%rsp) movq 0x40(%rsp), %rax movq %rax, 0x80(%rsp) jmp 0x299c4 movq 0x98(%rsp), %rdi movq 0xa0(%rsp), %rsi movq 0xa8(%rsp), %rdx callq 0x29d40 movq %rax, 0x28(%rsp) movq %rdx, 0x30(%rsp) movq 0x28(%rsp), %rax movq %rax, 0x78(%rsp) movq 0x30(%rsp), %rax movq %rax, 0x80(%rsp) movq 0x78(%rsp), %rdi movq 0x80(%rsp), %rsi callq 0x23cc0 cmpl $0x0, %eax jne 0x29921 jmp 0x299c4 movq 0xa8(%rsp), %rax cmpl $-0x1, %eax je 0x29933 jmp 0x29d0a movq 0xa0(%rsp), %rax movq %rax, 0x50(%rsp) movq 0x50(%rsp), %rax movzwl 0x6(%rax), %eax cmpl $0x3, %eax je 0x29953 jmp 0x29d0a movq 0x98(%rsp), %rdi movq 0xa0(%rsp), %rsi movq 0xa8(%rsp), %rdx movl $0x33, %ecx callq 0x29d80 movq %rax, 0x18(%rsp) movq %rdx, 0x20(%rsp) movq 0x18(%rsp), %rax movq %rax, 0x78(%rsp) movq 0x20(%rsp), %rax movq %rax, 0x80(%rsp) movq 0x80(%rsp), %rax cmpl $-0x7, %eax je 0x299c2 movq 0x98(%rsp), %rdi movq 0x78(%rsp), %rsi movq 0x80(%rsp), %rdx callq 0x23c90 jmp 0x29d0a jmp 0x299c4 movq 0x78(%rsp), %rax movq %rax, 0x70(%rsp) movq 0x70(%rsp), %rax movq 0x4(%rax), %rax andq $0x7fffffff, %rax # imm = 0x7FFFFFFF movl %eax, 0x60(%rsp) movq 0x70(%rsp), %rax movq 0x4(%rax), %rax shrq $0x1f, %rax andq $0x1, %rax cmpb $0x0, %al jne 0x29b59 movq 0x70(%rsp), %rax addq $0x18, %rax movq %rax, 0x10(%rsp) movl $0x0, 0xc(%rsp) movl $0x0, 0x64(%rsp) movl 0x64(%rsp), %eax cmpl 0x60(%rsp), %eax jge 0x29a48 movq 0x10(%rsp), %rax movslq 0x64(%rsp), %rcx movzbl (%rax,%rcx), %eax sarl $0x7, %eax addl 0xc(%rsp), %eax movl %eax, 0xc(%rsp) movl 0x64(%rsp), %eax addl $0x1, %eax movl %eax, 0x64(%rsp) jmp 0x29a18 cmpl $0x0, 0xc(%rsp) jne 0x29a7c cmpq $0x0, 0x90(%rsp) je 0x29a6a movslq 0x60(%rsp), %rcx movq 0x90(%rsp), %rax movq %rcx, (%rax) movq 0x10(%rsp), %rax movq %rax, 0xb0(%rsp) jmp 0x29d30 movq 0x98(%rsp), %rdi movl 0x60(%rsp), %esi addl 0xc(%rsp), %esi xorl %edx, %edx callq 0x29760 movq %rax, 0x68(%rsp) cmpq $0x0, 0x68(%rsp) jne 0x29aa5 jmp 0x29d0a movq 0x68(%rsp), %rax addq $0x18, %rax movq %rax, 0x48(%rsp) movl $0x0, 0x64(%rsp) movl 0x64(%rsp), %eax cmpl 0x60(%rsp), %eax jge 0x29b54 movq 0x10(%rsp), %rax movslq 0x64(%rsp), %rcx movzbl (%rax,%rcx), %eax movl %eax, 0x5c(%rsp) cmpl $0x80, 0x5c(%rsp) jge 0x29b00 movl 0x5c(%rsp), %eax movb %al, %cl movq 0x48(%rsp), %rax movq %rax, %rdx addq $0x1, %rdx movq %rdx, 0x48(%rsp) movb %cl, (%rax) jmp 0x29b42 movl 0x5c(%rsp), %eax sarl $0x6, %eax orl $0xc0, %eax movb %al, %cl movq 0x48(%rsp), %rax movq %rax, %rdx addq $0x1, %rdx movq %rdx, 0x48(%rsp) movb %cl, (%rax) movl 0x5c(%rsp), %eax andl $0x3f, %eax orl $0x80, %eax movb %al, %cl movq 0x48(%rsp), %rax movq %rax, %rdx addq $0x1, %rdx movq %rdx, 0x48(%rsp) movb %cl, (%rax) jmp 0x29b44 movl 0x64(%rsp), %eax addl $0x1, %eax movl %eax, 0x64(%rsp) jmp 0x29abb jmp 0x29c77 movq 0x70(%rsp), %rax addq $0x18, %rax movq %rax, (%rsp) movq 0x98(%rsp), %rdi imull $0x3, 0x60(%rsp), %esi xorl %edx, %edx callq 0x29760 movq %rax, 0x68(%rsp) cmpq $0x0, 0x68(%rsp) jne 0x29b8c jmp 0x29d0a movq 0x68(%rsp), %rax addq $0x18, %rax movq %rax, 0x48(%rsp) movl $0x0, 0x64(%rsp) movl 0x64(%rsp), %eax cmpl 0x60(%rsp), %eax jge 0x29c75 movq (%rsp), %rax movl 0x64(%rsp), %ecx movl %ecx, %edx addl $0x1, %edx movl %edx, 0x64(%rsp) movslq %ecx, %rcx movzwl (%rax,%rcx,2), %eax movl %eax, 0x5c(%rsp) cmpl $0x80, 0x5c(%rsp) jge 0x29bf1 movl 0x5c(%rsp), %eax movb %al, %cl movq 0x48(%rsp), %rax movq %rax, %rdx addq $0x1, %rdx movq %rdx, 0x48(%rsp) movb %cl, (%rax) jmp 0x29c70 movl 0x5c(%rsp), %edi callq 0x29de0 cmpl $0x0, %eax je 0x29c58 movl 0x64(%rsp), %eax cmpl 0x60(%rsp), %eax jge 0x29c54 cmpl $0x0, 0x8c(%rsp) jne 0x29c54 movq (%rsp), %rax movslq 0x64(%rsp), %rcx movzwl (%rax,%rcx,2), %eax movl %eax, 0x58(%rsp) movl 0x58(%rsp), %edi callq 0x29e00 cmpl $0x0, %eax je 0x29c50 movl 0x64(%rsp), %eax addl $0x1, %eax movl %eax, 0x64(%rsp) movl 0x5c(%rsp), %edi movl 0x58(%rsp), %esi callq 0x29e20 movl %eax, 0x5c(%rsp) jmp 0x29c52 jmp 0x29c52 jmp 0x29c56 jmp 0x29c56 jmp 0x29c58 movq 0x48(%rsp), %rdi movl 0x5c(%rsp), %esi callq 0x1e9e0 addq 0x48(%rsp), %rax movq %rax, 0x48(%rsp) jmp 0x29ba2 jmp 0x29c77 movq 0x48(%rsp), %rax movb $0x0, (%rax) movq 0x48(%rsp), %rax movq 0x68(%rsp), %rcx addq $0x18, %rcx subq %rcx, %rax movl %eax, %ecx movq 0x68(%rsp), %rax movl %ecx, %ecx movl %ecx, %edx movq 0x4(%rax), %rcx andq $0x7fffffff, %rdx # imm = 0x7FFFFFFF andq $-0x80000000, %rcx # imm = 0x80000000 orq %rdx, %rcx movq %rcx, 0x4(%rax) movq 0x98(%rsp), %rdi movq 0x78(%rsp), %rsi movq 0x80(%rsp), %rdx callq 0x23c90 cmpq $0x0, 0x90(%rsp) je 0x29cf7 movq 0x68(%rsp), %rax movq 0x4(%rax), %rax andq $0x7fffffff, %rax # imm = 0x7FFFFFFF movl %eax, %eax movl %eax, %ecx movq 0x90(%rsp), %rax movq %rcx, (%rax) movq 0x68(%rsp), %rax addq $0x18, %rax movq %rax, 0xb0(%rsp) jmp 0x29d30 cmpq $0x0, 0x90(%rsp) je 0x29d24 movq 0x90(%rsp), %rax movq $0x0, (%rax) movq $0x0, 0xb0(%rsp) movq 0xb0(%rsp), %rax addq $0xb8, %rsp retq
JS_ToCStringLen2: sub rsp, 0B8h mov [rsp+0B8h+var_18], rdx mov [rsp+0B8h+var_10], rcx mov [rsp+0B8h+var_20], rdi mov [rsp+0B8h+var_28], rsi mov [rsp+0B8h+var_2C], r8d mov rax, [rsp+0B8h+var_10] cmp eax, 0FFFFFFF9h jnz short loc_298C7 mov rdi, [rsp+0B8h+var_18] mov rsi, [rsp+0B8h+var_10] call js_dup mov [rsp+0B8h+var_80], rax mov [rsp+0B8h+var_78], rdx mov rax, [rsp+0B8h+var_80] mov [rsp+0B8h+var_40], rax mov rax, [rsp+0B8h+var_78] mov [rsp+0B8h+var_38], rax jmp loc_299C4 loc_298C7: mov rdi, [rsp+0B8h+var_20] mov rsi, [rsp+0B8h+var_18] mov rdx, [rsp+0B8h+var_10] call JS_ToString mov [rsp+0B8h+var_90], rax mov [rsp+0B8h+var_88], rdx mov rax, [rsp+0B8h+var_90] mov [rsp+0B8h+var_40], rax mov rax, [rsp+0B8h+var_88] mov [rsp+0B8h+var_38], rax mov rdi, [rsp+0B8h+var_40] mov rsi, [rsp+0B8h+var_38] call JS_IsException_1 cmp eax, 0 jnz short loc_29921 jmp loc_299C4 loc_29921: mov rax, [rsp+0B8h+var_10] cmp eax, 0FFFFFFFFh jz short loc_29933 jmp loc_29D0A loc_29933: mov rax, [rsp+0B8h+var_18] mov [rsp+0B8h+var_68], rax mov rax, [rsp+0B8h+var_68] movzx eax, word ptr [rax+6] cmp eax, 3 jz short loc_29953 jmp loc_29D0A loc_29953: mov rdi, [rsp+0B8h+var_20] mov rsi, [rsp+0B8h+var_18] mov rdx, [rsp+0B8h+var_10] mov ecx, 33h ; '3' call JS_GetProperty mov [rsp+0B8h+var_A0], rax mov [rsp+0B8h+var_98], rdx mov rax, [rsp+0B8h+var_A0] mov [rsp+0B8h+var_40], rax mov rax, [rsp+0B8h+var_98] mov [rsp+0B8h+var_38], rax mov rax, [rsp+0B8h+var_38] cmp eax, 0FFFFFFF9h jz short loc_299C2 mov rdi, [rsp+0B8h+var_20] mov rsi, [rsp+0B8h+var_40] mov rdx, [rsp+0B8h+var_38] call JS_FreeValue jmp loc_29D0A loc_299C2: jmp short $+2 loc_299C4: mov rax, [rsp+0B8h+var_40] mov [rsp+0B8h+var_48], rax mov rax, [rsp+0B8h+var_48] mov rax, [rax+4] and rax, 7FFFFFFFh mov [rsp+0B8h+var_58], eax mov rax, [rsp+0B8h+var_48] mov rax, [rax+4] shr rax, 1Fh and rax, 1 cmp al, 0 jnz loc_29B59 mov rax, [rsp+0B8h+var_48] add rax, 18h mov [rsp+0B8h+var_A8], rax mov [rsp+0B8h+var_AC], 0 mov [rsp+0B8h+var_54], 0 loc_29A18: mov eax, [rsp+0B8h+var_54] cmp eax, [rsp+0B8h+var_58] jge short loc_29A48 mov rax, [rsp+0B8h+var_A8] movsxd rcx, [rsp+0B8h+var_54] movzx eax, byte ptr [rax+rcx] sar eax, 7 add eax, [rsp+0B8h+var_AC] mov [rsp+0B8h+var_AC], eax mov eax, [rsp+0B8h+var_54] add eax, 1 mov [rsp+0B8h+var_54], eax jmp short loc_29A18 loc_29A48: cmp [rsp+0B8h+var_AC], 0 jnz short loc_29A7C cmp [rsp+0B8h+var_28], 0 jz short loc_29A6A movsxd rcx, [rsp+0B8h+var_58] mov rax, [rsp+0B8h+var_28] mov [rax], rcx loc_29A6A: mov rax, [rsp+0B8h+var_A8] mov [rsp+0B8h+var_8], rax jmp loc_29D30 loc_29A7C: mov rdi, [rsp+0B8h+var_20] mov esi, [rsp+0B8h+var_58] add esi, [rsp+0B8h+var_AC] xor edx, edx call js_alloc_string mov [rsp+0B8h+var_50], rax cmp [rsp+0B8h+var_50], 0 jnz short loc_29AA5 jmp loc_29D0A loc_29AA5: mov rax, [rsp+0B8h+var_50] add rax, 18h mov [rsp+0B8h+var_70], rax mov [rsp+0B8h+var_54], 0 loc_29ABB: mov eax, [rsp+0B8h+var_54] cmp eax, [rsp+0B8h+var_58] jge loc_29B54 mov rax, [rsp+0B8h+var_A8] movsxd rcx, [rsp+0B8h+var_54] movzx eax, byte ptr [rax+rcx] mov [rsp+0B8h+var_5C], eax cmp [rsp+0B8h+var_5C], 80h jge short loc_29B00 mov eax, [rsp+0B8h+var_5C] mov cl, al mov rax, [rsp+0B8h+var_70] mov rdx, rax add rdx, 1 mov [rsp+0B8h+var_70], rdx mov [rax], cl jmp short loc_29B42 loc_29B00: mov eax, [rsp+0B8h+var_5C] sar eax, 6 or eax, 0C0h mov cl, al mov rax, [rsp+0B8h+var_70] mov rdx, rax add rdx, 1 mov [rsp+0B8h+var_70], rdx mov [rax], cl mov eax, [rsp+0B8h+var_5C] and eax, 3Fh or eax, 80h mov cl, al mov rax, [rsp+0B8h+var_70] mov rdx, rax add rdx, 1 mov [rsp+0B8h+var_70], rdx mov [rax], cl loc_29B42: jmp short $+2 loc_29B44: mov eax, [rsp+0B8h+var_54] add eax, 1 mov [rsp+0B8h+var_54], eax jmp loc_29ABB loc_29B54: jmp loc_29C77 loc_29B59: mov rax, [rsp+0B8h+var_48] add rax, 18h mov [rsp+0B8h+var_B8], rax mov rdi, [rsp+0B8h+var_20] imul esi, [rsp+0B8h+var_58], 3 xor edx, edx call js_alloc_string mov [rsp+0B8h+var_50], rax cmp [rsp+0B8h+var_50], 0 jnz short loc_29B8C jmp loc_29D0A loc_29B8C: mov rax, [rsp+0B8h+var_50] add rax, 18h mov [rsp+0B8h+var_70], rax mov [rsp+0B8h+var_54], 0 loc_29BA2: mov eax, [rsp+0B8h+var_54] cmp eax, [rsp+0B8h+var_58] jge loc_29C75 mov rax, [rsp+0B8h+var_B8] mov ecx, [rsp+0B8h+var_54] mov edx, ecx add edx, 1 mov [rsp+0B8h+var_54], edx movsxd rcx, ecx movzx eax, word ptr [rax+rcx*2] mov [rsp+0B8h+var_5C], eax cmp [rsp+0B8h+var_5C], 80h jge short loc_29BF1 mov eax, [rsp+0B8h+var_5C] mov cl, al mov rax, [rsp+0B8h+var_70] mov rdx, rax add rdx, 1 mov [rsp+0B8h+var_70], rdx mov [rax], cl jmp short loc_29C70 loc_29BF1: mov edi, [rsp+0B8h+var_5C] call is_hi_surrogate_0 cmp eax, 0 jz short loc_29C58 mov eax, [rsp+0B8h+var_54] cmp eax, [rsp+0B8h+var_58] jge short loc_29C54 cmp [rsp+0B8h+var_2C], 0 jnz short loc_29C54 mov rax, [rsp+0B8h+var_B8] movsxd rcx, [rsp+0B8h+var_54] movzx eax, word ptr [rax+rcx*2] mov [rsp+0B8h+var_60], eax mov edi, [rsp+0B8h+var_60] call is_lo_surrogate_0 cmp eax, 0 jz short loc_29C50 mov eax, [rsp+0B8h+var_54] add eax, 1 mov [rsp+0B8h+var_54], eax mov edi, [rsp+0B8h+var_5C] mov esi, [rsp+0B8h+var_60] call from_surrogate_0 mov [rsp+0B8h+var_5C], eax jmp short loc_29C52 loc_29C50: jmp short $+2 loc_29C52: jmp short loc_29C56 loc_29C54: jmp short $+2 loc_29C56: jmp short $+2 loc_29C58: mov rdi, [rsp+0B8h+var_70] mov esi, [rsp+0B8h+var_5C] call utf8_encode add rax, [rsp+0B8h+var_70] mov [rsp+0B8h+var_70], rax loc_29C70: jmp loc_29BA2 loc_29C75: jmp short $+2 loc_29C77: mov rax, [rsp+0B8h+var_70] mov byte ptr [rax], 0 mov rax, [rsp+0B8h+var_70] mov rcx, [rsp+0B8h+var_50] add rcx, 18h sub rax, rcx mov ecx, eax mov rax, [rsp+0B8h+var_50] mov ecx, ecx mov edx, ecx mov rcx, [rax+4] and rdx, 7FFFFFFFh and rcx, 0FFFFFFFF80000000h or rcx, rdx mov [rax+4], rcx mov rdi, [rsp+0B8h+var_20] mov rsi, [rsp+0B8h+var_40] mov rdx, [rsp+0B8h+var_38] call JS_FreeValue cmp [rsp+0B8h+var_28], 0 jz short loc_29CF7 mov rax, [rsp+0B8h+var_50] mov rax, [rax+4] and rax, 7FFFFFFFh mov eax, eax mov ecx, eax mov rax, [rsp+0B8h+var_28] mov [rax], rcx loc_29CF7: mov rax, [rsp+0B8h+var_50] add rax, 18h mov [rsp+0B8h+var_8], rax jmp short loc_29D30 loc_29D0A: cmp [rsp+0B8h+var_28], 0 jz short loc_29D24 mov rax, [rsp+0B8h+var_28] mov qword ptr [rax], 0 loc_29D24: mov [rsp+0B8h+var_8], 0 loc_29D30: mov rax, [rsp+0B8h+var_8] add rsp, 0B8h retn
_DWORD * JS_ToCStringLen2(long long a1, _QWORD *a2, long long a3, long long a4, int a5) { long long v5; // rdx long long v6; // rdx long long v7; // rdx _BYTE *v8; // rax _BYTE *v9; // rax int v10; // ecx _BYTE *v11; // rax _DWORD *v13; // [rsp+0h] [rbp-B8h] int v14; // [rsp+Ch] [rbp-ACh] _DWORD *v15; // [rsp+10h] [rbp-A8h] long long Property; // [rsp+18h] [rbp-A0h] _BYTE *v17; // [rsp+48h] [rbp-70h] unsigned int v18; // [rsp+58h] [rbp-60h] int v19; // [rsp+5Ch] [rbp-5Ch] unsigned int v20; // [rsp+5Ch] [rbp-5Ch] int v21; // [rsp+60h] [rbp-58h] int i; // [rsp+64h] [rbp-54h] int j; // [rsp+64h] [rbp-54h] int v24; // [rsp+64h] [rbp-54h] long long v25; // [rsp+68h] [rbp-50h] _DWORD *v26; // [rsp+78h] [rbp-40h] long long v27; // [rsp+80h] [rbp-38h] if ( (_DWORD)a4 == -7 ) { v26 = js_dup((_DWORD *)a3, 0xFFFFFFF9); v27 = v5; } else { v26 = (_DWORD *)JS_ToString(a1, a3, a4); v27 = v6; if ( JS_IsException_1((long long)v26, v6) ) { if ( (_DWORD)a4 != -1 || *(_WORD *)(a3 + 6) != 3 ) goto LABEL_38; Property = JS_GetProperty(a1, a3, a4, 51LL); v26 = (_DWORD *)Property; v27 = v7; if ( (_DWORD)v7 != -7 ) { JS_FreeValue(a1, Property, v7); goto LABEL_38; } } } v21 = *(_QWORD *)(v26 + 1) & 0x7FFFFFFF; if ( (*(_QWORD *)(v26 + 1) & 0x80000000LL) != 0 ) { v13 = v26 + 6; v25 = js_alloc_string(a1, 3 * v21, 0); if ( v25 ) { v17 = (_BYTE *)(v25 + 24); v24 = 0; while ( v24 < v21 ) { v10 = v24++; v20 = *((unsigned __int16 *)v13 + v10); if ( v20 >= 0x80 ) { if ( (unsigned int)is_hi_surrogate_0(*((unsigned __int16 *)v13 + v10)) ) { if ( v24 < v21 && !a5 ) { v18 = *((unsigned __int16 *)v13 + v24); if ( (unsigned int)is_lo_surrogate_0(*((unsigned __int16 *)v13 + v24)) ) { ++v24; v20 = from_surrogate_0(v20, v18); } } } v17 += utf8_encode(v17, v20); } else { v11 = v17++; *v11 = v20; } } goto LABEL_35; } } else { v15 = v26 + 6; v14 = 0; for ( i = 0; i < v21; ++i ) v14 += (int)*((unsigned __int8 *)v15 + i) >> 7; if ( !v14 ) { if ( a2 ) *a2 = v21; return v26 + 6; } v25 = js_alloc_string(a1, v14 + v21, 0); if ( v25 ) { v17 = (_BYTE *)(v25 + 24); for ( j = 0; j < v21; ++j ) { v19 = *((unsigned __int8 *)v15 + j); if ( (unsigned int)v19 >= 0x80 ) { *v17 = (v19 >> 6) | 0xC0; v9 = v17 + 1; v17 += 2; *v9 = v19 & 0x3F | 0x80; } else { v8 = v17++; *v8 = v19; } } LABEL_35: *v17 = 0; *(_QWORD *)(v25 + 4) = ((_DWORD)v17 - ((_DWORD)v25 + 24)) & 0x7FFFFFFF | *(_QWORD *)(v25 + 4) & 0xFFFFFFFF80000000LL; JS_FreeValue(a1, (long long)v26, v27); if ( a2 ) *a2 = *(_DWORD *)(v25 + 4) & 0x7FFFFFFF; return (_DWORD *)(v25 + 24); } } LABEL_38: if ( a2 ) *a2 = 0LL; return 0LL; }
JS_ToCStringLen2: SUB RSP,0xb8 MOV qword ptr [RSP + 0xa0],RDX MOV qword ptr [RSP + 0xa8],RCX MOV qword ptr [RSP + 0x98],RDI MOV qword ptr [RSP + 0x90],RSI MOV dword ptr [RSP + 0x8c],R8D MOV RAX,qword ptr [RSP + 0xa8] CMP EAX,-0x7 JNZ 0x001298c7 MOV RDI,qword ptr [RSP + 0xa0] MOV RSI,qword ptr [RSP + 0xa8] CALL 0x001216d0 MOV qword ptr [RSP + 0x38],RAX MOV qword ptr [RSP + 0x40],RDX MOV RAX,qword ptr [RSP + 0x38] MOV qword ptr [RSP + 0x78],RAX MOV RAX,qword ptr [RSP + 0x40] MOV qword ptr [RSP + 0x80],RAX JMP 0x001299c4 LAB_001298c7: MOV RDI,qword ptr [RSP + 0x98] MOV RSI,qword ptr [RSP + 0xa0] MOV RDX,qword ptr [RSP + 0xa8] CALL 0x00129d40 MOV qword ptr [RSP + 0x28],RAX MOV qword ptr [RSP + 0x30],RDX MOV RAX,qword ptr [RSP + 0x28] MOV qword ptr [RSP + 0x78],RAX MOV RAX,qword ptr [RSP + 0x30] MOV qword ptr [RSP + 0x80],RAX MOV RDI,qword ptr [RSP + 0x78] MOV RSI,qword ptr [RSP + 0x80] CALL 0x00123cc0 CMP EAX,0x0 JNZ 0x00129921 JMP 0x001299c4 LAB_00129921: MOV RAX,qword ptr [RSP + 0xa8] CMP EAX,-0x1 JZ 0x00129933 JMP 0x00129d0a LAB_00129933: MOV RAX,qword ptr [RSP + 0xa0] MOV qword ptr [RSP + 0x50],RAX MOV RAX,qword ptr [RSP + 0x50] MOVZX EAX,word ptr [RAX + 0x6] CMP EAX,0x3 JZ 0x00129953 JMP 0x00129d0a LAB_00129953: MOV RDI,qword ptr [RSP + 0x98] MOV RSI,qword ptr [RSP + 0xa0] MOV RDX,qword ptr [RSP + 0xa8] MOV ECX,0x33 CALL 0x00129d80 MOV qword ptr [RSP + 0x18],RAX MOV qword ptr [RSP + 0x20],RDX MOV RAX,qword ptr [RSP + 0x18] MOV qword ptr [RSP + 0x78],RAX MOV RAX,qword ptr [RSP + 0x20] MOV qword ptr [RSP + 0x80],RAX MOV RAX,qword ptr [RSP + 0x80] CMP EAX,-0x7 JZ 0x001299c2 MOV RDI,qword ptr [RSP + 0x98] MOV RSI,qword ptr [RSP + 0x78] MOV RDX,qword ptr [RSP + 0x80] CALL 0x00123c90 JMP 0x00129d0a LAB_001299c2: JMP 0x001299c4 LAB_001299c4: MOV RAX,qword ptr [RSP + 0x78] MOV qword ptr [RSP + 0x70],RAX MOV RAX,qword ptr [RSP + 0x70] MOV RAX,qword ptr [RAX + 0x4] AND RAX,0x7fffffff MOV dword ptr [RSP + 0x60],EAX MOV RAX,qword ptr [RSP + 0x70] MOV RAX,qword ptr [RAX + 0x4] SHR RAX,0x1f AND RAX,0x1 CMP AL,0x0 JNZ 0x00129b59 MOV RAX,qword ptr [RSP + 0x70] ADD RAX,0x18 MOV qword ptr [RSP + 0x10],RAX MOV dword ptr [RSP + 0xc],0x0 MOV dword ptr [RSP + 0x64],0x0 LAB_00129a18: MOV EAX,dword ptr [RSP + 0x64] CMP EAX,dword ptr [RSP + 0x60] JGE 0x00129a48 MOV RAX,qword ptr [RSP + 0x10] MOVSXD RCX,dword ptr [RSP + 0x64] MOVZX EAX,byte ptr [RAX + RCX*0x1] SAR EAX,0x7 ADD EAX,dword ptr [RSP + 0xc] MOV dword ptr [RSP + 0xc],EAX MOV EAX,dword ptr [RSP + 0x64] ADD EAX,0x1 MOV dword ptr [RSP + 0x64],EAX JMP 0x00129a18 LAB_00129a48: CMP dword ptr [RSP + 0xc],0x0 JNZ 0x00129a7c CMP qword ptr [RSP + 0x90],0x0 JZ 0x00129a6a MOVSXD RCX,dword ptr [RSP + 0x60] MOV RAX,qword ptr [RSP + 0x90] MOV qword ptr [RAX],RCX LAB_00129a6a: MOV RAX,qword ptr [RSP + 0x10] MOV qword ptr [RSP + 0xb0],RAX JMP 0x00129d30 LAB_00129a7c: MOV RDI,qword ptr [RSP + 0x98] MOV ESI,dword ptr [RSP + 0x60] ADD ESI,dword ptr [RSP + 0xc] XOR EDX,EDX CALL 0x00129760 MOV qword ptr [RSP + 0x68],RAX CMP qword ptr [RSP + 0x68],0x0 JNZ 0x00129aa5 JMP 0x00129d0a LAB_00129aa5: MOV RAX,qword ptr [RSP + 0x68] ADD RAX,0x18 MOV qword ptr [RSP + 0x48],RAX MOV dword ptr [RSP + 0x64],0x0 LAB_00129abb: MOV EAX,dword ptr [RSP + 0x64] CMP EAX,dword ptr [RSP + 0x60] JGE 0x00129b54 MOV RAX,qword ptr [RSP + 0x10] MOVSXD RCX,dword ptr [RSP + 0x64] MOVZX EAX,byte ptr [RAX + RCX*0x1] MOV dword ptr [RSP + 0x5c],EAX CMP dword ptr [RSP + 0x5c],0x80 JGE 0x00129b00 MOV EAX,dword ptr [RSP + 0x5c] MOV CL,AL MOV RAX,qword ptr [RSP + 0x48] MOV RDX,RAX ADD RDX,0x1 MOV qword ptr [RSP + 0x48],RDX MOV byte ptr [RAX],CL JMP 0x00129b42 LAB_00129b00: MOV EAX,dword ptr [RSP + 0x5c] SAR EAX,0x6 OR EAX,0xc0 MOV CL,AL MOV RAX,qword ptr [RSP + 0x48] MOV RDX,RAX ADD RDX,0x1 MOV qword ptr [RSP + 0x48],RDX MOV byte ptr [RAX],CL MOV EAX,dword ptr [RSP + 0x5c] AND EAX,0x3f OR EAX,0x80 MOV CL,AL MOV RAX,qword ptr [RSP + 0x48] MOV RDX,RAX ADD RDX,0x1 MOV qword ptr [RSP + 0x48],RDX MOV byte ptr [RAX],CL LAB_00129b42: JMP 0x00129b44 LAB_00129b44: MOV EAX,dword ptr [RSP + 0x64] ADD EAX,0x1 MOV dword ptr [RSP + 0x64],EAX JMP 0x00129abb LAB_00129b54: JMP 0x00129c77 LAB_00129b59: MOV RAX,qword ptr [RSP + 0x70] ADD RAX,0x18 MOV qword ptr [RSP],RAX MOV RDI,qword ptr [RSP + 0x98] IMUL ESI,dword ptr [RSP + 0x60],0x3 XOR EDX,EDX CALL 0x00129760 MOV qword ptr [RSP + 0x68],RAX CMP qword ptr [RSP + 0x68],0x0 JNZ 0x00129b8c JMP 0x00129d0a LAB_00129b8c: MOV RAX,qword ptr [RSP + 0x68] ADD RAX,0x18 MOV qword ptr [RSP + 0x48],RAX MOV dword ptr [RSP + 0x64],0x0 LAB_00129ba2: MOV EAX,dword ptr [RSP + 0x64] CMP EAX,dword ptr [RSP + 0x60] JGE 0x00129c75 MOV RAX,qword ptr [RSP] MOV ECX,dword ptr [RSP + 0x64] MOV EDX,ECX ADD EDX,0x1 MOV dword ptr [RSP + 0x64],EDX MOVSXD RCX,ECX MOVZX EAX,word ptr [RAX + RCX*0x2] MOV dword ptr [RSP + 0x5c],EAX CMP dword ptr [RSP + 0x5c],0x80 JGE 0x00129bf1 MOV EAX,dword ptr [RSP + 0x5c] MOV CL,AL MOV RAX,qword ptr [RSP + 0x48] MOV RDX,RAX ADD RDX,0x1 MOV qword ptr [RSP + 0x48],RDX MOV byte ptr [RAX],CL JMP 0x00129c70 LAB_00129bf1: MOV EDI,dword ptr [RSP + 0x5c] CALL 0x00129de0 CMP EAX,0x0 JZ 0x00129c58 MOV EAX,dword ptr [RSP + 0x64] CMP EAX,dword ptr [RSP + 0x60] JGE 0x00129c54 CMP dword ptr [RSP + 0x8c],0x0 JNZ 0x00129c54 MOV RAX,qword ptr [RSP] MOVSXD RCX,dword ptr [RSP + 0x64] MOVZX EAX,word ptr [RAX + RCX*0x2] MOV dword ptr [RSP + 0x58],EAX MOV EDI,dword ptr [RSP + 0x58] CALL 0x00129e00 CMP EAX,0x0 JZ 0x00129c50 MOV EAX,dword ptr [RSP + 0x64] ADD EAX,0x1 MOV dword ptr [RSP + 0x64],EAX MOV EDI,dword ptr [RSP + 0x5c] MOV ESI,dword ptr [RSP + 0x58] CALL 0x00129e20 MOV dword ptr [RSP + 0x5c],EAX JMP 0x00129c52 LAB_00129c50: JMP 0x00129c52 LAB_00129c52: JMP 0x00129c56 LAB_00129c54: JMP 0x00129c56 LAB_00129c56: JMP 0x00129c58 LAB_00129c58: MOV RDI,qword ptr [RSP + 0x48] MOV ESI,dword ptr [RSP + 0x5c] CALL 0x0011e9e0 ADD RAX,qword ptr [RSP + 0x48] MOV qword ptr [RSP + 0x48],RAX LAB_00129c70: JMP 0x00129ba2 LAB_00129c75: JMP 0x00129c77 LAB_00129c77: MOV RAX,qword ptr [RSP + 0x48] MOV byte ptr [RAX],0x0 MOV RAX,qword ptr [RSP + 0x48] MOV RCX,qword ptr [RSP + 0x68] ADD RCX,0x18 SUB RAX,RCX MOV ECX,EAX MOV RAX,qword ptr [RSP + 0x68] MOV ECX,ECX MOV EDX,ECX MOV RCX,qword ptr [RAX + 0x4] AND RDX,0x7fffffff AND RCX,-0x80000000 OR RCX,RDX MOV qword ptr [RAX + 0x4],RCX MOV RDI,qword ptr [RSP + 0x98] MOV RSI,qword ptr [RSP + 0x78] MOV RDX,qword ptr [RSP + 0x80] CALL 0x00123c90 CMP qword ptr [RSP + 0x90],0x0 JZ 0x00129cf7 MOV RAX,qword ptr [RSP + 0x68] MOV RAX,qword ptr [RAX + 0x4] AND RAX,0x7fffffff MOV EAX,EAX MOV ECX,EAX MOV RAX,qword ptr [RSP + 0x90] MOV qword ptr [RAX],RCX LAB_00129cf7: MOV RAX,qword ptr [RSP + 0x68] ADD RAX,0x18 MOV qword ptr [RSP + 0xb0],RAX JMP 0x00129d30 LAB_00129d0a: CMP qword ptr [RSP + 0x90],0x0 JZ 0x00129d24 MOV RAX,qword ptr [RSP + 0x90] MOV qword ptr [RAX],0x0 LAB_00129d24: MOV qword ptr [RSP + 0xb0],0x0 LAB_00129d30: MOV RAX,qword ptr [RSP + 0xb0] ADD RSP,0xb8 RET
long JS_ToCStringLen2(int8 param_1,ulong *param_2,long param_3,int8 param_4,int param_5) { byte bVar1; ushort uVar2; int2 uVar3; uint uVar4; int iVar5; long lVar6; int iVar7; byte *pbVar8; int1 auVar9 [16]; int local_ac; byte *local_70; uint local_5c; int local_54; long local_50; long local_40; int8 local_38; if ((int)param_4 == -7) { auVar9 = js_dup(param_3,param_4); } else { auVar9 = JS_ToString(param_1,param_3,param_4); iVar7 = JS_IsException(auVar9._0_8_,auVar9._8_8_); if (iVar7 != 0) { if (((int)param_4 != -1) || (*(short *)(param_3 + 6) != 3)) goto LAB_00129d0a; auVar9 = JS_GetProperty(param_1,param_3,param_4,0x33); if (auVar9._8_4_ != -7) { JS_FreeValue(param_1,auVar9._0_8_,auVar9._8_8_); goto LAB_00129d0a; } } } local_38 = auVar9._8_8_; local_40 = auVar9._0_8_; uVar4 = (uint)*(int8 *)(local_40 + 4) & 0x7fffffff; if ((*(ulong *)(local_40 + 4) >> 0x1f & 1) == 0) { lVar6 = local_40 + 0x18; local_ac = 0; for (local_54 = 0; local_54 < (int)uVar4; local_54 = local_54 + 1) { local_ac = ((int)(uint)*(byte *)(lVar6 + local_54) >> 7) + local_ac; } if (local_ac == 0) { if (param_2 == (ulong *)0x0) { return lVar6; } *param_2 = (long)(int)uVar4; return lVar6; } local_50 = js_alloc_string(param_1,uVar4 + local_ac,0); if (local_50 != 0) { local_70 = (byte *)(local_50 + 0x18); for (local_54 = 0; local_54 < (int)uVar4; local_54 = local_54 + 1) { bVar1 = *(byte *)(lVar6 + local_54); if (bVar1 < 0x80) { *local_70 = bVar1; local_70 = local_70 + 1; } else { pbVar8 = local_70 + 1; *local_70 = (byte)((int)(uint)bVar1 >> 6) | 0xc0; local_70 = local_70 + 2; *pbVar8 = bVar1 & 0x3f | 0x80; } } LAB_00129c77: *local_70 = 0; *(ulong *)(local_50 + 4) = *(ulong *)(local_50 + 4) & 0xffffffff80000000 | (ulong)(uint)((int)local_70 - ((int)local_50 + 0x18)) & 0x7fffffff; JS_FreeValue(param_1,local_40,local_38); if (param_2 != (ulong *)0x0) { *param_2 = (ulong)((uint)*(int8 *)(local_50 + 4) & 0x7fffffff); } return local_50 + 0x18; } } else { local_50 = js_alloc_string(param_1,uVar4 * 3,0); if (local_50 != 0) { local_54 = 0; local_70 = (byte *)(local_50 + 0x18); while (local_54 < (int)uVar4) { iVar7 = local_54 + 1; uVar2 = *(ushort *)(local_40 + 0x18 + (long)local_54 * 2); local_5c = (uint)uVar2; if (local_5c < 0x80) { *local_70 = (byte)uVar2; local_70 = local_70 + 1; local_54 = iVar7; } else { iVar5 = is_hi_surrogate(local_5c); if (((iVar5 != 0) && (iVar7 < (int)uVar4)) && (param_5 == 0)) { uVar3 = *(int2 *)(local_40 + 0x18 + (long)iVar7 * 2); iVar5 = is_lo_surrogate(uVar3); if (iVar5 != 0) { local_5c = from_surrogate(local_5c,uVar3); iVar7 = local_54 + 2; } } local_54 = iVar7; lVar6 = utf8_encode(local_70,local_5c); local_70 = local_70 + lVar6; } } goto LAB_00129c77; } } LAB_00129d0a: if (param_2 != (ulong *)0x0) { *param_2 = 0; } return 0; }
47,492
JS_ToCStringLen2
bluesky950520[P]quickjs/quickjs.c
const char *JS_ToCStringLen2(JSContext *ctx, size_t *plen, JSValue val1, BOOL cesu8) { JSValue val; JSString *str, *str_new; int pos, len, c, c1; JSObject *p; uint8_t *q; if (JS_VALUE_GET_TAG(val1) == JS_TAG_STRING) { val = js_dup(val1); goto go; } val = JS_ToString(ctx, val1); if (!JS_IsException(val)) goto go; // Stringification can fail when there is an exception pending, // e.g. a stack overflow InternalError. Special-case exception // objects to make debugging easier, look up the .message property // and stringify that. if (JS_VALUE_GET_TAG(val1) != JS_TAG_OBJECT) goto fail; p = JS_VALUE_GET_OBJ(val1); if (p->class_id != JS_CLASS_ERROR) goto fail; val = JS_GetProperty(ctx, val1, JS_ATOM_message); if (JS_VALUE_GET_TAG(val) != JS_TAG_STRING) { JS_FreeValue(ctx, val); goto fail; } go: str = JS_VALUE_GET_STRING(val); len = str->len; if (!str->is_wide_char) { const uint8_t *src = str->u.str8; int count; /* count the number of non-ASCII characters */ /* Scanning the whole string is required for ASCII strings, and computing the number of non-ASCII bytes is less expensive than testing each byte, hence this method is faster for ASCII strings, which is the most common case. */ count = 0; for (pos = 0; pos < len; pos++) { count += src[pos] >> 7; } if (count == 0) { if (plen) *plen = len; return (const char *)src; } str_new = js_alloc_string(ctx, len + count, 0); if (!str_new) goto fail; q = str_new->u.str8; for (pos = 0; pos < len; pos++) { c = src[pos]; if (c < 0x80) { *q++ = c; } else { *q++ = (c >> 6) | 0xc0; *q++ = (c & 0x3f) | 0x80; } } } else { const uint16_t *src = str->u.str16; /* Allocate 3 bytes per 16 bit code point. Surrogate pairs may produce 4 bytes but use 2 code points. */ str_new = js_alloc_string(ctx, len * 3, 0); if (!str_new) goto fail; q = str_new->u.str8; pos = 0; while (pos < len) { c = src[pos++]; if (c < 0x80) { *q++ = c; } else { if (is_hi_surrogate(c)) { if (pos < len && !cesu8) { c1 = src[pos]; if (is_lo_surrogate(c1)) { pos++; c = from_surrogate(c, c1); } else { /* Keep unmatched surrogate code points */ /* c = 0xfffd; */ /* error */ } } else { /* Keep unmatched surrogate code points */ /* c = 0xfffd; */ /* error */ } } q += utf8_encode(q, c); } } } *q = '\0'; str_new->len = q - str_new->u.str8; JS_FreeValue(ctx, val); if (plen) *plen = str_new->len; return (const char *)str_new->u.str8; fail: if (plen) *plen = 0; return NULL; }
O2
c
JS_ToCStringLen2: pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x28, %rsp movl %r8d, %ebp movq %rcx, %r15 movq %rdx, %r12 movq %rsi, %rbx movq %rdi, %r14 cmpl $-0x7, %r15d jne 0x1adeb incl (%r12) movq %r12, (%rsp) movq %r12, %r13 jmp 0x1ae46 movq %r14, %rdi movq %r12, %rsi movq %r15, %rdx callq 0x1b03c cmpl $0x6, %edx jne 0x1ae3c cmpl $-0x1, %r15d jne 0x1b01a cmpw $0x3, 0x6(%r12) jne 0x1b01a movq %r15, %rdx pushq $0x33 popq %rcx movq %r14, %rdi movq %r12, %rsi callq 0x1b043 movq %rdx, %r15 cmpl $-0x7, %r15d jne 0x1b00c movq %rax, (%rsp) movq %rax, %r13 jmp 0x1ae46 movq %rax, %r13 movq %rax, (%rsp) movq %rdx, %r15 movq 0x4(%r13), %rax movl %eax, %r12d andl $0x7fffffff, %r12d # imm = 0x7FFFFFFF addq $0x18, %r13 testl %eax, %eax js 0x1ae81 movl %eax, %ebp andl $0x7fffffff, %ebp # imm = 0x7FFFFFFF xorl %ecx, %ecx xorl %esi, %esi cmpq %rcx, %rbp je 0x1af3c movzbl (%r13,%rcx), %edx shrl $0x7, %edx addl %edx, %esi incq %rcx jmp 0x1ae68 movq %r15, 0x8(%rsp) leal (%r12,%r12,2), %esi xorl %r15d, %r15d movq %r14, 0x20(%rsp) movq %r14, %rdi xorl %edx, %edx callq 0x1ad45 testq %rax, %rax je 0x1b01a movq %rbx, 0x10(%rsp) movq %rax, 0x18(%rsp) movq %rax, %rbx addq $0x18, %rbx cmpl %r12d, %r15d jge 0x1afab leal 0x1(%r15), %r14d movslq %r15d, %rax movzwl (%r13,%rax,2), %esi cmpl $0x7f, %esi ja 0x1aedc movb %sil, (%rbx) incq %rbx movl %r14d, %r15d jmp 0x1aeb6 movl %esi, %eax andl $0xfc00, %eax # imm = 0xFC00 cmpl $0xd800, %eax # imm = 0xD800 jne 0x1af29 testl %ebp, %ebp jne 0x1af29 cmpl %r12d, %r14d jge 0x1af29 movslq %r14d, %rax movzwl (%r13,%rax,2), %eax movl %eax, %ecx andl $0xfc00, %ecx # imm = 0xFC00 cmpl $0xdc00, %ecx # imm = 0xDC00 jne 0x1af29 addl $0x2, %r15d shll $0xa, %esi andl $0xffc00, %esi # imm = 0xFFC00 andl $0x3ff, %eax # imm = 0x3FF addl %eax, %esi addl $0x10000, %esi # imm = 0x10000 movl %r15d, %r14d movq %rbx, %rdi callq 0x15edf addq %rax, %rbx movl %r14d, %r15d jmp 0x1aeb6 testl %esi, %esi je 0x1b000 movq %r15, 0x8(%rsp) addl %r12d, %esi movq %r14, %r15 movq %r14, %rdi xorl %edx, %edx callq 0x1ad45 testq %rax, %rax je 0x1b01a movq %rbx, 0x10(%rsp) movq %rax, %rbx addq $0x18, %rbx xorl %r8d, %r8d movq %r15, %rdi movq %rax, %r14 cmpq %r8, %rbp je 0x1afc0 movb (%r13,%r8), %cl testb %cl, %cl js 0x1af8b leaq 0x1(%rbx), %rdx jmp 0x1afa1 movl %ecx, %esi shrb $0x6, %sil orb $-0x40, %sil andb $-0x41, %cl leaq 0x2(%rbx), %rdx movb %cl, 0x1(%rbx) movl %esi, %ecx movb %cl, (%rbx) incq %r8 movq %rdx, %rbx jmp 0x1af77 movq 0x20(%rsp), %rdi movq 0x8(%rsp), %rdx movq (%rsp), %rsi movq 0x18(%rsp), %r14 jmp 0x1afc9 movq 0x8(%rsp), %rdx movq (%rsp), %rsi movb $0x0, (%rbx) leaq 0x18(%r14), %r13 subl %r13d, %ebx andl $0x7fffffff, %ebx # imm = 0x7FFFFFFF movq $-0x80000000, %rax # imm = 0x80000000 andq 0x4(%r14), %rax orq %rbx, %rax movq %rax, 0x4(%r14) callq 0x1801e movq 0x10(%rsp), %rbx testq %rbx, %rbx je 0x1b02a movq 0x4(%r14), %rax jmp 0x1b005 testq %rbx, %rbx je 0x1b02a andl $0x7fffffff, %eax # imm = 0x7FFFFFFF jmp 0x1b027 movq %r14, %rdi movq %rax, %rsi movq %r15, %rdx callq 0x1801e xorl %eax, %eax movl $0x0, %r13d testq %rbx, %rbx je 0x1b02a movq %rax, (%rbx) movq %r13, %rax addq $0x28, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
JS_ToCStringLen2: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 28h mov ebp, r8d mov r15, rcx mov r12, rdx mov rbx, rsi mov r14, rdi cmp r15d, 0FFFFFFF9h jnz short loc_1ADEB inc dword ptr [r12] mov [rsp+58h+var_58], r12 mov r13, r12 jmp short loc_1AE46 loc_1ADEB: mov rdi, r14 mov rsi, r12 mov rdx, r15 call JS_ToString cmp edx, 6 jnz short loc_1AE3C cmp r15d, 0FFFFFFFFh jnz loc_1B01A cmp word ptr [r12+6], 3 jnz loc_1B01A mov rdx, r15 push 33h ; '3' pop rcx mov rdi, r14 mov rsi, r12 call JS_GetProperty mov r15, rdx cmp r15d, 0FFFFFFF9h jnz loc_1B00C mov [rsp+58h+var_58], rax mov r13, rax jmp short loc_1AE46 loc_1AE3C: mov r13, rax mov [rsp+58h+var_58], rax mov r15, rdx loc_1AE46: mov rax, [r13+4] mov r12d, eax and r12d, 7FFFFFFFh add r13, 18h test eax, eax js short loc_1AE81 mov ebp, eax and ebp, 7FFFFFFFh xor ecx, ecx xor esi, esi loc_1AE68: cmp rbp, rcx jz loc_1AF3C movzx edx, byte ptr [r13+rcx+0] shr edx, 7 add esi, edx inc rcx jmp short loc_1AE68 loc_1AE81: mov [rsp+58h+var_50], r15 lea esi, [r12+r12*2] xor r15d, r15d mov [rsp+58h+var_38], r14 mov rdi, r14 xor edx, edx call js_alloc_string test rax, rax jz loc_1B01A mov [rsp+58h+var_48], rbx mov [rsp+58h+var_40], rax mov rbx, rax add rbx, 18h loc_1AEB6: cmp r15d, r12d jge loc_1AFAB lea r14d, [r15+1] movsxd rax, r15d movzx esi, word ptr [r13+rax*2+0] cmp esi, 7Fh ja short loc_1AEDC mov [rbx], sil inc rbx mov r15d, r14d jmp short loc_1AEB6 loc_1AEDC: mov eax, esi and eax, 0FC00h cmp eax, 0D800h jnz short loc_1AF29 test ebp, ebp jnz short loc_1AF29 cmp r14d, r12d jge short loc_1AF29 movsxd rax, r14d movzx eax, word ptr [r13+rax*2+0] mov ecx, eax and ecx, 0FC00h cmp ecx, 0DC00h jnz short loc_1AF29 add r15d, 2 shl esi, 0Ah and esi, 0FFC00h and eax, 3FFh add esi, eax add esi, 10000h mov r14d, r15d loc_1AF29: mov rdi, rbx call utf8_encode add rbx, rax mov r15d, r14d jmp loc_1AEB6 loc_1AF3C: test esi, esi jz loc_1B000 mov [rsp+58h+var_50], r15 add esi, r12d mov r15, r14 mov rdi, r14 xor edx, edx call js_alloc_string test rax, rax jz loc_1B01A mov [rsp+58h+var_48], rbx mov rbx, rax add rbx, 18h xor r8d, r8d mov rdi, r15 mov r14, rax loc_1AF77: cmp rbp, r8 jz short loc_1AFC0 mov cl, [r13+r8+0] test cl, cl js short loc_1AF8B lea rdx, [rbx+1] jmp short loc_1AFA1 loc_1AF8B: mov esi, ecx shr sil, 6 or sil, 0C0h and cl, 0BFh lea rdx, [rbx+2] mov [rbx+1], cl mov ecx, esi loc_1AFA1: mov [rbx], cl inc r8 mov rbx, rdx jmp short loc_1AF77 loc_1AFAB: mov rdi, [rsp+58h+var_38] mov rdx, [rsp+58h+var_50] mov rsi, [rsp+58h+var_58] mov r14, [rsp+58h+var_40] jmp short loc_1AFC9 loc_1AFC0: mov rdx, [rsp+58h+var_50] mov rsi, [rsp+58h+var_58] loc_1AFC9: mov byte ptr [rbx], 0 lea r13, [r14+18h] sub ebx, r13d and ebx, 7FFFFFFFh mov rax, 0FFFFFFFF80000000h and rax, [r14+4] or rax, rbx mov [r14+4], rax call JS_FreeValue mov rbx, [rsp+58h+var_48] test rbx, rbx jz short loc_1B02A mov rax, [r14+4] jmp short loc_1B005 loc_1B000: test rbx, rbx jz short loc_1B02A loc_1B005: and eax, 7FFFFFFFh jmp short loc_1B027 loc_1B00C: mov rdi, r14 mov rsi, rax mov rdx, r15 call JS_FreeValue loc_1B01A: xor eax, eax mov r13d, 0 test rbx, rbx jz short loc_1B02A loc_1B027: mov [rbx], rax loc_1B02A: mov rax, r13 add rsp, 28h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
long long JS_ToCStringLen2(long long a1, long long *a2, long long a3, long long a4, int a5) { long long v6; // r15 long long *v8; // rbx long long v9; // r13 long long v10; // rax long long v11; // rdx long long Property; // rax long long v13; // rdx long long v14; // rax int v15; // r12d long long v16; // r13 long long v17; // rbp long long v18; // rcx int v19; // esi int v20; // r15d long long v21; // rax _BYTE *v22; // rbx int v23; // r14d unsigned int v24; // esi long long v25; // rax int v26; // ecx long long v27; // r8 long long v28; // r14 _BYTE *v29; // rdx int v30; // esi long long v31; // rdx long long v32; // rsi long long v33; // rax long long v35; // [rsp+0h] [rbp-58h] long long v36; // [rsp+8h] [rbp-50h] long long *v37; // [rsp+10h] [rbp-48h] long long v38; // [rsp+18h] [rbp-40h] v6 = a4; v8 = a2; if ( (_DWORD)a4 == -7 ) { ++*(_DWORD *)a3; v35 = a3; v9 = a3; } else { v10 = JS_ToString(a1, a3, a4); if ( (_DWORD)v11 == 6 ) { if ( (_DWORD)v6 != -1 || *(_WORD *)(a3 + 6) != 3 ) goto LABEL_39; Property = JS_GetProperty(a1, a3, v6, 51LL); v6 = v13; if ( (_DWORD)v13 != -7 ) { JS_FreeValue(a1, Property, v13); goto LABEL_39; } v35 = Property; v9 = Property; } else { v9 = v10; v35 = v10; v6 = v11; } } v14 = *(_QWORD *)(v9 + 4); v15 = v14 & 0x7FFFFFFF; v16 = v9 + 24; if ( (int)v14 >= 0 ) { v17 = v14 & 0x7FFFFFFF; v18 = 0LL; v19 = 0; while ( v17 != v18 ) v19 += *(unsigned __int8 *)(v16 + v18++) >> 7; if ( !v19 ) { if ( v8 ) goto LABEL_37; return v16; } v25 = js_alloc_string(a1, (unsigned int)(v15 + v19), 0LL); if ( v25 ) { v37 = v8; v22 = (_BYTE *)(v25 + 24); v27 = 0LL; v28 = v25; while ( v17 != v27 ) { LOBYTE(v26) = *(_BYTE *)(v16 + v27); if ( (v26 & 0x80u) != 0 ) { v30 = v26; LOBYTE(v30) = ((unsigned __int8)v26 >> 6) | 0xC0; v29 = v22 + 2; v22[1] = v26 & 0xBF; v26 = v30; } else { v29 = v22 + 1; } *v22 = v26; ++v27; v22 = v29; } v31 = v6; v32 = v35; goto LABEL_34; } LABEL_39: v33 = 0LL; v16 = 0LL; if ( v8 ) goto LABEL_40; return v16; } v36 = v6; v20 = 0; v21 = js_alloc_string(a1, (unsigned int)(3 * v15), 0LL); if ( !v21 ) goto LABEL_39; v37 = a2; v38 = v21; v22 = (_BYTE *)(v21 + 24); while ( v20 < v15 ) { v23 = v20 + 1; v24 = *(unsigned __int16 *)(v16 + 2LL * v20); if ( v24 > 0x7F ) { if ( (v24 & 0xFC00) == 0xD800 && !a5 && v23 < v15 && (*(_WORD *)(v16 + 2LL * v23) & 0xFC00) == 0xDC00 ) { v24 = (*(_WORD *)(v16 + 2LL * v23) & 0x3FF) + ((v24 << 10) & 0xFFC00) + 0x10000; v23 = v20 + 2; } v22 += utf8_encode(v22, v24); v20 = v23; } else { *v22++ = v24; ++v20; } } v31 = v36; v32 = v35; v28 = v38; LABEL_34: *v22 = 0; v16 = v28 + 24; *(_QWORD *)(v28 + 4) = ((_DWORD)v22 - ((_DWORD)v28 + 24)) & 0x7FFFFFFF | *(_QWORD *)(v28 + 4) & 0xFFFFFFFF80000000LL; JS_FreeValue(a1, v32, v31); v8 = v37; if ( v37 ) { v14 = *(_QWORD *)(v28 + 4); LABEL_37: v33 = v14 & 0x7FFFFFFF; LABEL_40: *v8 = v33; } return v16; }
JS_ToCStringLen2: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x28 MOV EBP,R8D MOV R15,RCX MOV R12,RDX MOV RBX,RSI MOV R14,RDI CMP R15D,-0x7 JNZ 0x0011adeb INC dword ptr [R12] MOV qword ptr [RSP],R12 MOV R13,R12 JMP 0x0011ae46 LAB_0011adeb: MOV RDI,R14 MOV RSI,R12 MOV RDX,R15 CALL 0x0011b03c CMP EDX,0x6 JNZ 0x0011ae3c CMP R15D,-0x1 JNZ 0x0011b01a CMP word ptr [R12 + 0x6],0x3 JNZ 0x0011b01a MOV RDX,R15 PUSH 0x33 POP RCX MOV RDI,R14 MOV RSI,R12 CALL 0x0011b043 MOV R15,RDX CMP R15D,-0x7 JNZ 0x0011b00c MOV qword ptr [RSP],RAX MOV R13,RAX JMP 0x0011ae46 LAB_0011ae3c: MOV R13,RAX MOV qword ptr [RSP],RAX MOV R15,RDX LAB_0011ae46: MOV RAX,qword ptr [R13 + 0x4] MOV R12D,EAX AND R12D,0x7fffffff ADD R13,0x18 TEST EAX,EAX JS 0x0011ae81 MOV EBP,EAX AND EBP,0x7fffffff XOR ECX,ECX XOR ESI,ESI LAB_0011ae68: CMP RBP,RCX JZ 0x0011af3c MOVZX EDX,byte ptr [R13 + RCX*0x1] SHR EDX,0x7 ADD ESI,EDX INC RCX JMP 0x0011ae68 LAB_0011ae81: MOV qword ptr [RSP + 0x8],R15 LEA ESI,[R12 + R12*0x2] XOR R15D,R15D MOV qword ptr [RSP + 0x20],R14 MOV RDI,R14 XOR EDX,EDX CALL 0x0011ad45 TEST RAX,RAX JZ 0x0011b01a MOV qword ptr [RSP + 0x10],RBX MOV qword ptr [RSP + 0x18],RAX MOV RBX,RAX ADD RBX,0x18 LAB_0011aeb6: CMP R15D,R12D JGE 0x0011afab LEA R14D,[R15 + 0x1] MOVSXD RAX,R15D MOVZX ESI,word ptr [R13 + RAX*0x2] CMP ESI,0x7f JA 0x0011aedc MOV byte ptr [RBX],SIL INC RBX MOV R15D,R14D JMP 0x0011aeb6 LAB_0011aedc: MOV EAX,ESI AND EAX,0xfc00 CMP EAX,0xd800 JNZ 0x0011af29 TEST EBP,EBP JNZ 0x0011af29 CMP R14D,R12D JGE 0x0011af29 MOVSXD RAX,R14D MOVZX EAX,word ptr [R13 + RAX*0x2] MOV ECX,EAX AND ECX,0xfc00 CMP ECX,0xdc00 JNZ 0x0011af29 ADD R15D,0x2 SHL ESI,0xa AND ESI,0xffc00 AND EAX,0x3ff ADD ESI,EAX ADD ESI,0x10000 MOV R14D,R15D LAB_0011af29: MOV RDI,RBX CALL 0x00115edf ADD RBX,RAX MOV R15D,R14D JMP 0x0011aeb6 LAB_0011af3c: TEST ESI,ESI JZ 0x0011b000 MOV qword ptr [RSP + 0x8],R15 ADD ESI,R12D MOV R15,R14 MOV RDI,R14 XOR EDX,EDX CALL 0x0011ad45 TEST RAX,RAX JZ 0x0011b01a MOV qword ptr [RSP + 0x10],RBX MOV RBX,RAX ADD RBX,0x18 XOR R8D,R8D MOV RDI,R15 MOV R14,RAX LAB_0011af77: CMP RBP,R8 JZ 0x0011afc0 MOV CL,byte ptr [R13 + R8*0x1] TEST CL,CL JS 0x0011af8b LEA RDX,[RBX + 0x1] JMP 0x0011afa1 LAB_0011af8b: MOV ESI,ECX SHR SIL,0x6 OR SIL,0xc0 AND CL,0xbf LEA RDX,[RBX + 0x2] MOV byte ptr [RBX + 0x1],CL MOV ECX,ESI LAB_0011afa1: MOV byte ptr [RBX],CL INC R8 MOV RBX,RDX JMP 0x0011af77 LAB_0011afab: MOV RDI,qword ptr [RSP + 0x20] MOV RDX,qword ptr [RSP + 0x8] MOV RSI,qword ptr [RSP] MOV R14,qword ptr [RSP + 0x18] JMP 0x0011afc9 LAB_0011afc0: MOV RDX,qword ptr [RSP + 0x8] MOV RSI,qword ptr [RSP] LAB_0011afc9: MOV byte ptr [RBX],0x0 LEA R13,[R14 + 0x18] SUB EBX,R13D AND EBX,0x7fffffff MOV RAX,-0x80000000 AND RAX,qword ptr [R14 + 0x4] OR RAX,RBX MOV qword ptr [R14 + 0x4],RAX CALL 0x0011801e MOV RBX,qword ptr [RSP + 0x10] TEST RBX,RBX JZ 0x0011b02a MOV RAX,qword ptr [R14 + 0x4] JMP 0x0011b005 LAB_0011b000: TEST RBX,RBX JZ 0x0011b02a LAB_0011b005: AND EAX,0x7fffffff JMP 0x0011b027 LAB_0011b00c: MOV RDI,R14 MOV RSI,RAX MOV RDX,R15 CALL 0x0011801e LAB_0011b01a: XOR EAX,EAX MOV R13D,0x0 TEST RBX,RBX JZ 0x0011b02a LAB_0011b027: MOV qword ptr [RBX],RAX LAB_0011b02a: MOV RAX,R13 ADD RSP,0x28 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
long JS_ToCStringLen2(int8 param_1,ulong *param_2,int *param_3,int8 param_4,int param_5) { int iVar1; byte bVar2; ushort uVar3; uint uVar4; long lVar5; long lVar6; ulong uVar7; byte *pbVar8; byte *pbVar9; byte bVar10; int iVar11; uint uVar12; uint uVar13; long lVar14; int1 auVar15 [16]; long local_58; auVar15._8_8_ = param_4; auVar15._0_8_ = param_3; if ((int)param_4 != -7) { auVar15 = JS_ToString(param_1,param_3,param_4); if (auVar15._8_4_ != 6) goto LAB_0011ae46; if (((int)param_4 == -1) && (*(short *)((long)param_3 + 6) == 3)) { auVar15 = JS_GetProperty(param_1,param_3,param_4); if (auVar15._8_4_ == -7) goto LAB_0011ae46; JS_FreeValue(param_1,auVar15._0_8_,auVar15._8_8_); } LAB_0011b01a: uVar7 = 0; lVar14 = 0; if (param_2 == (ulong *)0x0) { return 0; } goto LAB_0011b027; } *param_3 = *param_3 + 1; LAB_0011ae46: local_58 = auVar15._0_8_; uVar12 = (uint)*(int8 *)(local_58 + 4); uVar13 = uVar12 & 0x7fffffff; lVar14 = local_58 + 0x18; if ((int)uVar12 < 0) { lVar6 = js_alloc_string(param_1,uVar13 * 3,0); if (lVar6 == 0) goto LAB_0011b01a; pbVar9 = (byte *)(lVar6 + 0x18); iVar11 = 0; while (iVar11 < (int)uVar13) { iVar1 = iVar11 + 1; uVar3 = *(ushort *)(lVar14 + (long)iVar11 * 2); uVar12 = (uint)uVar3; if (uVar3 < 0x80) { *pbVar9 = (byte)uVar3; pbVar9 = pbVar9 + 1; iVar11 = iVar1; } else { if (((((uVar3 & 0xfc00) == 0xd800) && (param_5 == 0)) && (iVar1 < (int)uVar13)) && (uVar4 = (uint)*(ushort *)(lVar14 + (long)iVar1 * 2), (uVar4 & 0xfc00) == 0xdc00)) { uVar12 = (uVar3 & 0x3ff) * 0x400 + (uVar4 & 0x3ff) + 0x10000; iVar1 = iVar11 + 2; } iVar11 = iVar1; lVar5 = utf8_encode(pbVar9,uVar12); pbVar9 = pbVar9 + lVar5; } } LAB_0011afc9: *pbVar9 = 0; lVar14 = lVar6 + 0x18; *(ulong *)(lVar6 + 4) = *(ulong *)(lVar6 + 4) & 0xffffffff80000000 | (ulong)((int)pbVar9 - (int)lVar14 & 0x7fffffff); JS_FreeValue(param_1,local_58,auVar15._8_8_); if (param_2 == (ulong *)0x0) { return lVar14; } uVar12 = (uint)*(int8 *)(lVar6 + 4); } else { iVar11 = 0; for (uVar7 = 0; (uVar12 & 0x7fffffff) != uVar7; uVar7 = uVar7 + 1) { iVar11 = iVar11 + (uint)(*(byte *)(lVar14 + uVar7) >> 7); } if (iVar11 != 0) { lVar6 = js_alloc_string(param_1,iVar11 + uVar13,0); if (lVar6 == 0) goto LAB_0011b01a; pbVar9 = (byte *)(lVar6 + 0x18); for (uVar7 = 0; (uVar12 & 0x7fffffff) != uVar7; uVar7 = uVar7 + 1) { bVar2 = *(byte *)(lVar14 + uVar7); if ((char)bVar2 < '\0') { bVar10 = bVar2 >> 6 | 0xc0; pbVar8 = pbVar9 + 2; pbVar9[1] = bVar2 & 0xbf; } else { pbVar8 = pbVar9 + 1; bVar10 = bVar2; } *pbVar9 = bVar10; pbVar9 = pbVar8; } goto LAB_0011afc9; } if (param_2 == (ulong *)0x0) { return lVar14; } } uVar7 = (ulong)(uVar12 & 0x7fffffff); LAB_0011b027: *param_2 = uVar7; return lVar14; }
47,493
my_delete
eloqsql/mysys/my_delete.c
int my_delete(const char *name, myf MyFlags) { int err; DBUG_ENTER("my_delete"); DBUG_PRINT("my",("name %s MyFlags %lu", name, MyFlags)); #ifdef _WIN32 err = my_win_unlink(name); #else if (MyFlags & MY_NOSYMLINKS) err= unlink_nosymlinks(name); else err= unlink(name); #endif if ((MyFlags & MY_IGNORE_ENOENT) && errno == ENOENT) DBUG_RETURN(0); if (err) { my_errno= errno; if (MyFlags & (MY_FAE+MY_WME)) my_error(EE_DELETE, MYF(ME_BELL), name, errno); } else if ((MyFlags & MY_SYNC_DIR) && my_sync_dir_by_file(name, MyFlags)) err= -1; DBUG_RETURN(err); }
O0
c
my_delete: pushq %rbp movq %rsp, %rbp subq $0x30, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) jmp 0xef792 movq -0x18(%rbp), %rax andq $0x200, %rax # imm = 0x200 cmpq $0x0, %rax je 0xef7b0 movq -0x10(%rbp), %rdi callq 0xef870 movl %eax, -0x1c(%rbp) jmp 0xef7bc movq -0x10(%rbp), %rdi callq 0x2a1d0 movl %eax, -0x1c(%rbp) movq -0x18(%rbp), %rax andq $0x20, %rax cmpq $0x0, %rax je 0xef7e2 callq 0x2a760 cmpl $0x2, (%rax) jne 0xef7e2 jmp 0xef7d6 movl $0x0, -0x4(%rbp) jmp 0xef863 cmpl $0x0, -0x1c(%rbp) je 0xef830 callq 0x2a760 movl (%rax), %eax movl %eax, -0x20(%rbp) callq 0xf60c0 movl -0x20(%rbp), %ecx movl %ecx, (%rax) movq -0x18(%rbp), %rax andq $0x18, %rax cmpq $0x0, %rax je 0xef82e movq -0x10(%rbp), %rax movq %rax, -0x28(%rbp) callq 0x2a760 movq -0x28(%rbp), %rdx movl (%rax), %ecx movl $0x6, %edi movl $0x4, %esi movb $0x0, %al callq 0xefb70 jmp 0xef85b movq -0x18(%rbp), %rax andq $0x8000, %rax # imm = 0x8000 cmpq $0x0, %rax je 0xef859 movq -0x10(%rbp), %rdi movq -0x18(%rbp), %rsi callq 0xf5d60 cmpl $0x0, %eax je 0xef859 movl $0xffffffff, -0x1c(%rbp) # imm = 0xFFFFFFFF jmp 0xef85b jmp 0xef85d movl -0x1c(%rbp), %eax movl %eax, -0x4(%rbp) movl -0x4(%rbp), %eax addq $0x30, %rsp popq %rbp retq nopl (%rax)
my_delete: push rbp mov rbp, rsp sub rsp, 30h mov [rbp+var_10], rdi mov [rbp+var_18], rsi jmp short $+2 loc_EF792: mov rax, [rbp+var_18] and rax, 200h cmp rax, 0 jz short loc_EF7B0 mov rdi, [rbp+var_10] call unlink_nosymlinks mov [rbp+var_1C], eax jmp short loc_EF7BC loc_EF7B0: mov rdi, [rbp+var_10] call _unlink mov [rbp+var_1C], eax loc_EF7BC: mov rax, [rbp+var_18] and rax, 20h cmp rax, 0 jz short loc_EF7E2 call ___errno_location cmp dword ptr [rax], 2 jnz short loc_EF7E2 jmp short $+2 loc_EF7D6: mov [rbp+var_4], 0 jmp loc_EF863 loc_EF7E2: cmp [rbp+var_1C], 0 jz short loc_EF830 call ___errno_location mov eax, [rax] mov [rbp+var_20], eax call _my_thread_var mov ecx, [rbp+var_20] mov [rax], ecx mov rax, [rbp+var_18] and rax, 18h cmp rax, 0 jz short loc_EF82E mov rax, [rbp+var_10] mov [rbp+var_28], rax call ___errno_location mov rdx, [rbp+var_28] mov ecx, [rax] mov edi, 6 mov esi, 4 mov al, 0 call my_error loc_EF82E: jmp short loc_EF85B loc_EF830: mov rax, [rbp+var_18] and rax, 8000h cmp rax, 0 jz short loc_EF859 mov rdi, [rbp+var_10] mov rsi, [rbp+var_18] call my_sync_dir_by_file cmp eax, 0 jz short loc_EF859 mov [rbp+var_1C], 0FFFFFFFFh loc_EF859: jmp short $+2 loc_EF85B: jmp short $+2 loc_EF85D: mov eax, [rbp+var_1C] mov [rbp+var_4], eax loc_EF863: mov eax, [rbp+var_4] add rsp, 30h pop rbp retn
long long my_delete(long long a1, const char *a2) { _DWORD *v2; // rax int v3; // r8d int v4; // r9d int v6; // [rsp+10h] [rbp-20h] unsigned int v7; // [rsp+14h] [rbp-1Ch] if ( ((unsigned __int16)a2 & 0x200) != 0 ) v7 = unlink_nosymlinks(a1); else v7 = unlink(a1); if ( ((unsigned __int8)a2 & 0x20) != 0 && *(_DWORD *)__errno_location() == 2 ) { return 0; } else { if ( v7 ) { v6 = *(_DWORD *)__errno_location(); *(_DWORD *)my_thread_var(a1, a2) = v6; if ( ((unsigned __int8)a2 & 0x18) != 0 ) { v2 = (_DWORD *)__errno_location(); my_error(6, 4, a1, *v2, v3, v4); } } else if ( ((unsigned __int16)a2 & 0x8000) != 0 && (unsigned int)my_sync_dir_by_file(a1, a2) ) { return (unsigned int)-1; } return v7; } }
my_delete: PUSH RBP MOV RBP,RSP SUB RSP,0x30 MOV qword ptr [RBP + -0x10],RDI MOV qword ptr [RBP + -0x18],RSI JMP 0x001ef792 LAB_001ef792: MOV RAX,qword ptr [RBP + -0x18] AND RAX,0x200 CMP RAX,0x0 JZ 0x001ef7b0 MOV RDI,qword ptr [RBP + -0x10] CALL 0x001ef870 MOV dword ptr [RBP + -0x1c],EAX JMP 0x001ef7bc LAB_001ef7b0: MOV RDI,qword ptr [RBP + -0x10] CALL 0x0012a1d0 MOV dword ptr [RBP + -0x1c],EAX LAB_001ef7bc: MOV RAX,qword ptr [RBP + -0x18] AND RAX,0x20 CMP RAX,0x0 JZ 0x001ef7e2 CALL 0x0012a760 CMP dword ptr [RAX],0x2 JNZ 0x001ef7e2 JMP 0x001ef7d6 LAB_001ef7d6: MOV dword ptr [RBP + -0x4],0x0 JMP 0x001ef863 LAB_001ef7e2: CMP dword ptr [RBP + -0x1c],0x0 JZ 0x001ef830 CALL 0x0012a760 MOV EAX,dword ptr [RAX] MOV dword ptr [RBP + -0x20],EAX CALL 0x001f60c0 MOV ECX,dword ptr [RBP + -0x20] MOV dword ptr [RAX],ECX MOV RAX,qword ptr [RBP + -0x18] AND RAX,0x18 CMP RAX,0x0 JZ 0x001ef82e MOV RAX,qword ptr [RBP + -0x10] MOV qword ptr [RBP + -0x28],RAX CALL 0x0012a760 MOV RDX,qword ptr [RBP + -0x28] MOV ECX,dword ptr [RAX] MOV EDI,0x6 MOV ESI,0x4 MOV AL,0x0 CALL 0x001efb70 LAB_001ef82e: JMP 0x001ef85b LAB_001ef830: MOV RAX,qword ptr [RBP + -0x18] AND RAX,0x8000 CMP RAX,0x0 JZ 0x001ef859 MOV RDI,qword ptr [RBP + -0x10] MOV RSI,qword ptr [RBP + -0x18] CALL 0x001f5d60 CMP EAX,0x0 JZ 0x001ef859 MOV dword ptr [RBP + -0x1c],0xffffffff LAB_001ef859: JMP 0x001ef85b LAB_001ef85b: JMP 0x001ef85d LAB_001ef85d: MOV EAX,dword ptr [RBP + -0x1c] MOV dword ptr [RBP + -0x4],EAX LAB_001ef863: MOV EAX,dword ptr [RBP + -0x4] ADD RSP,0x30 POP RBP RET
int my_delete(char *param_1,ulong param_2) { int iVar1; int *piVar2; int local_24; int local_c; if ((param_2 & 0x200) == 0) { local_24 = unlink(param_1); } else { local_24 = unlink_nosymlinks(param_1); } if (((param_2 & 0x20) == 0) || (piVar2 = __errno_location(), *piVar2 != 2)) { if (local_24 == 0) { if (((param_2 & 0x8000) != 0) && (iVar1 = my_sync_dir_by_file(param_1,param_2), iVar1 != 0)) { local_24 = -1; } } else { piVar2 = __errno_location(); iVar1 = *piVar2; piVar2 = (int *)_my_thread_var(); *piVar2 = iVar1; if ((param_2 & 0x18) != 0) { piVar2 = __errno_location(); my_error(6,4,param_1,*piVar2); } } local_c = local_24; } else { local_c = 0; } return local_c; }
47,494
minja::Parser::parseConstant()
monkey531[P]llama/common/minja.hpp
std::shared_ptr<Value> parseConstant() { auto start = it; consumeSpaces(); if (it == end) return nullptr; if (*it == '"' || *it == '\'') { auto str = parseString(); if (str) return std::make_shared<Value>(*str); } static std::regex prim_tok(R"(true\b|True\b|false\b|False\b|None\b)"); auto token = consumeToken(prim_tok); if (!token.empty()) { if (token == "true" || token == "True") return std::make_shared<Value>(true); if (token == "false" || token == "False") return std::make_shared<Value>(false); if (token == "None") return std::make_shared<Value>(nullptr); throw std::runtime_error("Unknown constant token: " + token); } auto number = parseNumber(it, end); if (!number.is_null()) return std::make_shared<Value>(number); it = start; return nullptr; }
O0
cpp
minja::Parser::parseConstant(): subq $0xc8, %rsp movq %rdi, 0x18(%rsp) movq %rdi, %rax movq %rax, 0x20(%rsp) movq %rdi, 0xc0(%rsp) movq %rsi, 0xb8(%rsp) movq 0xb8(%rsp), %rdi movq %rdi, 0x28(%rsp) movq 0x20(%rdi), %rax movq %rax, 0xb0(%rsp) movl $0x1, %esi callq 0xd8ae0 movq 0x28(%rsp), %rsi movq %rsi, %rdi addq $0x20, %rdi addq $0x18, %rsi callq 0x98bd0 testb $0x1, %al jne 0xe6fc2 jmp 0xe6fd5 movq 0x18(%rsp), %rdi xorl %eax, %eax movl %eax, %esi callq 0xe8b50 jmp 0xe73ef movq 0x28(%rsp), %rdi addq $0x20, %rdi callq 0x9ac80 movsbl (%rax), %eax cmpl $0x22, %eax je 0xe7005 movq 0x28(%rsp), %rdi addq $0x20, %rdi callq 0x9ac80 movsbl (%rax), %eax cmpl $0x27, %eax jne 0xe70ae movq 0x28(%rsp), %rsi leaq 0xa8(%rsp), %rdi callq 0xe8b70 leaq 0xa8(%rsp), %rdi callq 0xe8c40 testb $0x1, %al jne 0xe702a jmp 0xe7082 leaq 0xa8(%rsp), %rdi callq 0xe8ce0 movq %rax, 0x10(%rsp) jmp 0xe703e movq 0x10(%rsp), %rsi movq 0x18(%rsp), %rdi callq 0xe8c60 jmp 0xe704f movl $0x1, 0x98(%rsp) jmp 0xe708d movq %rax, %rcx movl %edx, %eax movq %rcx, 0xa0(%rsp) movl %eax, 0x9c(%rsp) leaq 0xa8(%rsp), %rdi callq 0xe8d10 jmp 0xe73fc movl $0x0, 0x98(%rsp) leaq 0xa8(%rsp), %rdi callq 0xe8d10 movl 0x98(%rsp), %eax testl %eax, %eax je 0xe70ac jmp 0xe70a7 jmp 0xe73ef jmp 0xe70ae leaq 0x18946b(%rip), %rax # 0x270520 cmpb $0x0, (%rax) jne 0xe710b leaq 0x18945f(%rip), %rdi # 0x270520 callq 0x56530 cmpl $0x0, %eax je 0xe710b leaq 0x18942e(%rip), %rdi # 0x270500 leaq 0x100d0c(%rip), %rsi # 0x1e7de5 movl $0x10, %edx callq 0x692d0 jmp 0xe70e5 leaq -0x7d7ec(%rip), %rdi # 0x69900 leaq 0x18940d(%rip), %rsi # 0x270500 leaq 0x18886e(%rip), %rdx # 0x26f968 callq 0x56db0 leaq 0x18941a(%rip), %rdi # 0x270520 callq 0x568d0 movq 0x28(%rsp), %rsi leaq 0x78(%rsp), %rdi leaq 0x1893e4(%rip), %rdx # 0x270500 movl $0x1, %ecx callq 0xd5e70 leaq 0x78(%rsp), %rdi callq 0x56430 testb $0x1, %al jne 0xe7338 leaq 0xfd83b(%rip), %rsi # 0x1e497a leaq 0x78(%rsp), %rdi callq 0x688e0 movb %al, 0xf(%rsp) jmp 0xe714f movb 0xf(%rsp), %al testb $0x1, %al jne 0xe717a jmp 0xe7159 leaq 0x10087a(%rip), %rsi # 0x1e79da leaq 0x78(%rsp), %rdi callq 0x688e0 movb %al, 0xe(%rsp) jmp 0xe7170 movb 0xe(%rsp), %al testb $0x1, %al jne 0xe717a jmp 0xe71de movq 0x18(%rsp), %rdi movb $0x1, 0x77(%rsp) leaq 0x77(%rsp), %rsi callq 0xe8d70 jmp 0xe7190 movl $0x1, 0x98(%rsp) jmp 0xe73d7 movq %rax, %rcx movl %edx, %eax movq %rcx, 0xa0(%rsp) movl %eax, 0x9c(%rsp) leaq 0x189365(%rip), %rdi # 0x270520 callq 0x56660 jmp 0xe73fc movq %rax, %rcx movl %edx, %eax movq %rcx, 0xa0(%rsp) movl %eax, 0x9c(%rsp) jmp 0xe73e3 leaq 0xfd78f(%rip), %rsi # 0x1e4974 leaq 0x78(%rsp), %rdi callq 0x688e0 movb %al, 0xd(%rsp) jmp 0xe71f5 movb 0xd(%rsp), %al testb $0x1, %al jne 0xe7220 jmp 0xe71ff leaq 0x1007d9(%rip), %rsi # 0x1e79df leaq 0x78(%rsp), %rdi callq 0x688e0 movb %al, 0xc(%rsp) jmp 0xe7216 movb 0xc(%rsp), %al testb $0x1, %al jne 0xe7220 jmp 0xe7246 movq 0x18(%rsp), %rdi movb $0x0, 0x76(%rsp) leaq 0x76(%rsp), %rsi callq 0xe8d70 jmp 0xe7236 movl $0x1, 0x98(%rsp) jmp 0xe73d7 leaq 0x100bbd(%rip), %rsi # 0x1e7e0a leaq 0x78(%rsp), %rdi callq 0x688e0 movb %al, 0xb(%rsp) jmp 0xe725d movb 0xb(%rsp), %al testb $0x1, %al jne 0xe7267 jmp 0xe7291 movq 0x18(%rsp), %rdi movq $0x0, 0x68(%rsp) leaq 0x68(%rsp), %rsi callq 0xe8df0 jmp 0xe7281 movl $0x1, 0x98(%rsp) jmp 0xe73d7 movb $0x1, 0x47(%rsp) movl $0x10, %edi callq 0x565c0 movq %rax, (%rsp) leaq 0x100b64(%rip), %rsi # 0x1e7e0f leaq 0x48(%rsp), %rdi leaq 0x78(%rsp), %rdx callq 0xc1890 jmp 0xe72bc movq (%rsp), %rdi leaq 0x48(%rsp), %rsi callq 0x56410 jmp 0xe72cc movq (%rsp), %rdi movb $0x0, 0x47(%rsp) movq 0x187ccc(%rip), %rsi # 0x26efa8 movq 0x187c8d(%rip), %rdx # 0x26ef70 callq 0x569b0 jmp 0xe7409 movq %rax, %rcx movl %edx, %eax movq %rcx, 0xa0(%rsp) movl %eax, 0x9c(%rsp) jmp 0xe7321 movq %rax, %rcx movl %edx, %eax movq %rcx, 0xa0(%rsp) movl %eax, 0x9c(%rsp) leaq 0x48(%rsp), %rdi callq 0x572d0 testb $0x1, 0x47(%rsp) jne 0xe732a jmp 0xe7333 movq (%rsp), %rdi callq 0x56dd0 jmp 0xe73e3 movq 0x28(%rsp), %rsi movq %rsi, %rdx addq $0x20, %rdx movq %rsi, %rcx addq $0x18, %rcx leaq 0x30(%rsp), %rdi callq 0xe8e70 jmp 0xe7357 leaq 0x30(%rsp), %rdi callq 0xdeab0 testb $0x1, %al jne 0xe73a3 movq 0x18(%rsp), %rdi leaq 0x30(%rsp), %rsi callq 0xe9490 jmp 0xe7376 movl $0x1, 0x98(%rsp) jmp 0xe73cd movq %rax, %rcx movl %edx, %eax movq %rcx, 0xa0(%rsp) movl %eax, 0x9c(%rsp) leaq 0x30(%rsp), %rdi callq 0xcb040 jmp 0xe73e3 movq 0x18(%rsp), %rdi movq 0x28(%rsp), %rax movq 0xb0(%rsp), %rcx movq %rcx, 0x20(%rax) xorl %eax, %eax movl %eax, %esi callq 0xe8b50 movl $0x1, 0x98(%rsp) leaq 0x30(%rsp), %rdi callq 0xcb040 leaq 0x78(%rsp), %rdi callq 0x572d0 jmp 0xe73ef leaq 0x78(%rsp), %rdi callq 0x572d0 jmp 0xe73fc movq 0x20(%rsp), %rax addq $0xc8, %rsp retq movq 0xa0(%rsp), %rdi callq 0x56a10 nopl (%rax)
_ZN5minja6Parser13parseConstantEv: sub rsp, 0C8h mov qword ptr [rsp+0C8h+var_B0], rdi; int mov rax, rdi mov qword ptr [rsp+0C8h+var_A8], rax; int mov [rsp+0C8h+var_8], rdi mov qword ptr [rsp+0C8h+var_10], rsi mov rdi, qword ptr [rsp+0C8h+var_10] mov qword ptr [rsp+0C8h+var_A0], rdi; int mov rax, [rdi+20h] mov [rsp+0C8h+var_18], rax mov esi, 1 call _ZN5minja6Parser13consumeSpacesENS_13SpaceHandlingE; minja::Parser::consumeSpaces(minja::SpaceHandling) mov rsi, qword ptr [rsp+0C8h+var_A0] mov rdi, rsi add rdi, 20h ; ' ' add rsi, 18h call _ZN9__gnu_cxxeqIPKcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEEbRKNS_17__normal_iteratorIT_T0_EESE_; __gnu_cxx::operator==<char const*,std::string>(__gnu_cxx::__normal_iterator<char const*,std::string> const&,__gnu_cxx::__normal_iterator<char const*,std::string> const&) test al, 1 jnz short loc_E6FC2 jmp short loc_E6FD5 loc_E6FC2: mov rdi, qword ptr [rsp+0C8h+var_B0] xor eax, eax mov esi, eax call _ZNSt10shared_ptrIN5minja5ValueEEC2EDn; std::shared_ptr<minja::Value>::shared_ptr(decltype(nullptr)) jmp loc_E73EF loc_E6FD5: mov rdi, qword ptr [rsp+0C8h+var_A0] add rdi, 20h ; ' ' call _ZNK9__gnu_cxx17__normal_iteratorIPKcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEdeEv; __gnu_cxx::__normal_iterator<char const*,std::string>::operator*(void) movsx eax, byte ptr [rax] cmp eax, 22h ; '"' jz short loc_E7005 mov rdi, qword ptr [rsp+0C8h+var_A0] add rdi, 20h ; ' ' call _ZNK9__gnu_cxx17__normal_iteratorIPKcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEdeEv; __gnu_cxx::__normal_iterator<char const*,std::string>::operator*(void) movsx eax, byte ptr [rax] cmp eax, 27h ; ''' jnz loc_E70AE loc_E7005: mov rsi, qword ptr [rsp+0C8h+var_A0] lea rdi, [rsp+0C8h+var_20] call _ZN5minja6Parser11parseStringB5cxx11Ev; minja::Parser::parseString(void) lea rdi, [rsp+0C8h+var_20] call _ZNKSt10unique_ptrINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt14default_deleteIS5_EEcvbEv; std::unique_ptr<std::string>::operator bool(void) test al, 1 jnz short loc_E702A jmp short loc_E7082 loc_E702A: lea rdi, [rsp+0C8h+var_20] call _ZNKSt10unique_ptrINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt14default_deleteIS5_EEdeEv; std::unique_ptr<std::string>::operator*(void) mov [rsp+0C8h+var_B8], rax jmp short $+2 loc_E703E: mov rsi, [rsp+0C8h+var_B8] mov rdi, qword ptr [rsp+0C8h+var_B0] call _ZSt11make_sharedIN5minja5ValueEJRNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEESt10shared_ptrIT_EDpOT0_; std::make_shared<minja::Value,std::string &>(std::string &) jmp short $+2 loc_E704F: mov [rsp+0C8h+var_30], 1 jmp short loc_E708D mov rcx, rax mov eax, edx mov [rsp+arg_98], rcx mov [rsp+arg_94], eax lea rdi, [rsp+arg_A0] call _ZNSt10unique_ptrINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt14default_deleteIS5_EED2Ev; std::unique_ptr<std::string>::~unique_ptr() jmp loc_E73FC loc_E7082: mov [rsp+0C8h+var_30], 0 loc_E708D: lea rdi, [rsp+0C8h+var_20] call _ZNSt10unique_ptrINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt14default_deleteIS5_EED2Ev; std::unique_ptr<std::string>::~unique_ptr() mov eax, [rsp+0C8h+var_30] test eax, eax jz short loc_E70AC jmp short $+2 loc_E70A7: jmp loc_E73EF loc_E70AC: jmp short $+2 loc_E70AE: lea rax, _ZGVZN5minja6Parser13parseConstantEvE8prim_tokB5cxx11; `guard variable for'minja::Parser::parseConstant(void)::prim_tok cmp byte ptr [rax], 0 jnz short loc_E710B lea rdi, _ZGVZN5minja6Parser13parseConstantEvE8prim_tokB5cxx11; __guard * call ___cxa_guard_acquire cmp eax, 0 jz short loc_E710B lea rdi, _ZZN5minja6Parser13parseConstantEvE8prim_tokB5cxx11; minja::Parser::parseConstant(void)::prim_tok lea rsi, aTrueBTrueBFals; "true\\b|True\\b|false\\b|False\\b|None"... mov edx, 10h call _ZNSt7__cxx1111basic_regexIcNS_12regex_traitsIcEEEC2EPKcNSt15regex_constants18syntax_option_typeE; std::basic_regex<char,std::regex_traits<char>>::basic_regex(char const*,std::regex_constants::syntax_option_type) jmp short $+2 loc_E70E5: lea rdi, _ZNSt7__cxx1111basic_regexIcNS_12regex_traitsIcEEED2Ev; lpfunc lea rsi, _ZZN5minja6Parser13parseConstantEvE8prim_tokB5cxx11; obj lea rdx, __dso_handle; lpdso_handle call ___cxa_atexit lea rdi, _ZGVZN5minja6Parser13parseConstantEvE8prim_tokB5cxx11; __guard * call ___cxa_guard_release loc_E710B: mov rsi, qword ptr [rsp+0C8h+var_A0] lea rdi, [rsp+0C8h+var_50] lea rdx, _ZZN5minja6Parser13parseConstantEvE8prim_tokB5cxx11; minja::Parser::parseConstant(void)::prim_tok mov ecx, 1 call _ZN5minja6Parser12consumeTokenERKNSt7__cxx1111basic_regexIcNS1_12regex_traitsIcEEEENS_13SpaceHandlingE; minja::Parser::consumeToken(std::basic_regex<char,std::regex_traits<char>> const&,minja::SpaceHandling) lea rdi, [rsp+0C8h+var_50] call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5emptyEv; std::string::empty(void) test al, 1 jnz loc_E7338 lea rsi, aTrue; "true" lea rdi, [rsp+0C8h+var_50] call _ZSteqIcSt11char_traitsIcESaIcEEbRKNSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_; std::operator==<char>(std::string const&,char const*) mov [rsp+0C8h+var_B9], al jmp short $+2 loc_E714F: mov al, [rsp+0C8h+var_B9] test al, 1 jnz short loc_E717A jmp short $+2 loc_E7159: lea rsi, aTrue_0; "True" lea rdi, [rsp+0C8h+var_50] call _ZSteqIcSt11char_traitsIcESaIcEEbRKNSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_; std::operator==<char>(std::string const&,char const*) mov [rsp+0C8h+var_BA], al jmp short $+2 loc_E7170: mov al, [rsp+0C8h+var_BA] test al, 1 jnz short loc_E717A jmp short loc_E71DE loc_E717A: mov rdi, qword ptr [rsp+0C8h+var_B0] mov [rsp+0C8h+var_51], 1 lea rsi, [rsp+0C8h+var_51] call _ZSt11make_sharedIN5minja5ValueEJbEESt10shared_ptrIT_EDpOT0_; std::make_shared<minja::Value,bool>(bool &&) jmp short $+2 loc_E7190: mov [rsp+0C8h+var_30], 1 jmp loc_E73D7 mov rcx, rax mov eax, edx mov [rsp+arg_98], rcx mov [rsp+arg_94], eax lea rdi, _ZGVZN5minja6Parser13parseConstantEvE8prim_tokB5cxx11; __guard * call ___cxa_guard_abort jmp loc_E73FC mov rcx, rax mov eax, edx mov [rsp+arg_98], rcx mov [rsp+arg_94], eax jmp loc_E73E3 loc_E71DE: lea rsi, aFalse; "false" lea rdi, [rsp+0C8h+var_50] call _ZSteqIcSt11char_traitsIcESaIcEEbRKNSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_; std::operator==<char>(std::string const&,char const*) mov [rsp+0C8h+var_BB], al jmp short $+2 loc_E71F5: mov al, [rsp+0C8h+var_BB] test al, 1 jnz short loc_E7220 jmp short $+2 loc_E71FF: lea rsi, aFalse_0; "False" lea rdi, [rsp+0C8h+var_50] call _ZSteqIcSt11char_traitsIcESaIcEEbRKNSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_; std::operator==<char>(std::string const&,char const*) mov [rsp+0C8h+var_BC], al jmp short $+2 loc_E7216: mov al, [rsp+0C8h+var_BC] test al, 1 jnz short loc_E7220 jmp short loc_E7246 loc_E7220: mov rdi, qword ptr [rsp+0C8h+var_B0] mov [rsp+0C8h+var_52], 0 lea rsi, [rsp+0C8h+var_52] call _ZSt11make_sharedIN5minja5ValueEJbEESt10shared_ptrIT_EDpOT0_; std::make_shared<minja::Value,bool>(bool &&) jmp short $+2 loc_E7236: mov [rsp+0C8h+var_30], 1 jmp loc_E73D7 loc_E7246: lea rsi, aNone_0; "None" lea rdi, [rsp+0C8h+var_50] call _ZSteqIcSt11char_traitsIcESaIcEEbRKNSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_; std::operator==<char>(std::string const&,char const*) mov [rsp+0C8h+var_BD], al jmp short $+2 loc_E725D: mov al, [rsp+0C8h+var_BD] test al, 1 jnz short loc_E7267 jmp short loc_E7291 loc_E7267: mov rdi, qword ptr [rsp+0C8h+var_B0] mov [rsp+0C8h+var_60], 0 lea rsi, [rsp+0C8h+var_60] call _ZSt11make_sharedIN5minja5ValueEJDnEESt10shared_ptrIT_EDpOT0_; std::make_shared<minja::Value,decltype(nullptr)>(decltype(nullptr) &&) jmp short $+2 loc_E7281: mov [rsp+0C8h+var_30], 1 jmp loc_E73D7 loc_E7291: mov [rsp+0C8h+var_81], 1 mov edi, 10h; thrown_size call ___cxa_allocate_exception mov [rsp+0C8h+var_C8], rax; int lea rsi, aUnknownConstan; "Unknown constant token: " lea rdi, [rsp+0C8h+var_80]; int lea rdx, [rsp+0C8h+var_50]; int call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_RKS8_; std::operator+<char>(char const*,std::string const&) jmp short $+2 loc_E72BC: mov rdi, [rsp+0C8h+var_C8] lea rsi, [rsp+0C8h+var_80] call __ZNSt13runtime_errorC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; std::runtime_error::runtime_error(std::string const&) jmp short $+2 loc_E72CC: mov rdi, [rsp+0C8h+var_C8]; void * mov [rsp+0C8h+var_81], 0 mov rsi, cs:_ZTISt13runtime_error_ptr; lptinfo mov rdx, cs:_ZNSt13runtime_errorD1Ev_ptr; void (*)(void *) call ___cxa_throw jmp loc_E7409 mov rcx, rax mov eax, edx mov [rsp+arg_98], rcx mov [rsp+arg_94], eax jmp short loc_E7321 mov rcx, rax mov eax, edx mov [rsp+arg_98], rcx mov [rsp+arg_94], eax lea rdi, [rsp+arg_40]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string() loc_E7321: test [rsp+arg_3F], 1 jnz short loc_E732A jmp short loc_E7333 loc_E732A: mov rdi, [rsp+0]; void * call ___cxa_free_exception loc_E7333: jmp loc_E73E3 loc_E7338: mov rsi, qword ptr [rsp+0C8h+var_A0] mov rdx, rsi add rdx, 20h ; ' ' mov rcx, rsi add rcx, 18h lea rdi, [rsp+0C8h+var_98] call _ZN5minja6Parser11parseNumberERN9__gnu_cxx17__normal_iteratorIPKcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEERKSB_; minja::Parser::parseNumber(__gnu_cxx::__normal_iterator<char const*,std::string> &,__gnu_cxx::__normal_iterator<char const*,std::string> const&) jmp short $+2 loc_E7357: lea rdi, [rsp+0C8h+var_98] call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE7is_nullEv; 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>::is_null(void) test al, 1 jnz short loc_E73A3 mov rdi, qword ptr [rsp+0C8h+var_B0] lea rsi, [rsp+0C8h+var_98] call _ZSt11make_sharedIN5minja5ValueEJRN8nlohmann16json_abi_v3_11_310basic_jsonINS3_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS3_14adl_serializerES6_IhSaIhEEvEEEESt10shared_ptrIT_EDpOT0_; std::make_shared<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> &>(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> &) jmp short $+2 loc_E7376: mov [rsp+0C8h+var_30], 1 jmp short loc_E73CD mov rcx, rax mov eax, edx mov [rsp+arg_98], rcx mov [rsp+arg_94], eax lea rdi, [rsp+arg_28] call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvED2Ev; 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>::~basic_json() jmp short loc_E73E3 loc_E73A3: mov rdi, qword ptr [rsp+0C8h+var_B0] mov rax, qword ptr [rsp+0C8h+var_A0] mov rcx, [rsp+0C8h+var_18] mov [rax+20h], rcx xor eax, eax mov esi, eax call _ZNSt10shared_ptrIN5minja5ValueEEC2EDn; std::shared_ptr<minja::Value>::shared_ptr(decltype(nullptr)) mov [rsp+0C8h+var_30], 1 loc_E73CD: lea rdi, [rsp+0C8h+var_98] call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvED2Ev; 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>::~basic_json() loc_E73D7: lea rdi, [rsp+0C8h+var_50]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string() jmp short loc_E73EF loc_E73E3: lea rdi, [rsp+arg_70]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string() jmp short loc_E73FC loc_E73EF: mov rax, qword ptr [rsp+0C8h+var_A8] add rsp, 0C8h retn loc_E73FC: mov rdi, [rsp+arg_98] call __Unwind_Resume loc_E7409: nop dword ptr [rax+00000000h]
minja::Parser * minja::Parser::parseConstant(minja::Parser *this, long long a2) { int v2; // edx int v3; // ecx int v4; // r8d int v5; // r9d int v6; // edx int v7; // ecx int v8; // r8d int v9; // r9d int v10; // edx int v11; // ecx int v12; // r8d int v13; // r9d int v14; // edx int v15; // ecx int v16; // r8d int v17; // r9d int v18; // edx int v19; // ecx int v20; // r8d int v21; // r9d void *exception; // [rsp+0h] [rbp-C8h] int v24; // [rsp+10h] [rbp-B8h] _BYTE v25[24]; // [rsp+30h] [rbp-98h] BYREF int v26[8]; // [rsp+48h] [rbp-80h] BYREF long long v27; // [rsp+68h] [rbp-60h] BYREF char v28; // [rsp+76h] [rbp-52h] BYREF char v29; // [rsp+77h] [rbp-51h] BYREF int v30[8]; // [rsp+78h] [rbp-50h] BYREF int v31; // [rsp+98h] [rbp-30h] _BYTE v32[8]; // [rsp+A8h] [rbp-20h] BYREF long long v33; // [rsp+B0h] [rbp-18h] int v34[2]; // [rsp+B8h] [rbp-10h] minja::Parser *v35; // [rsp+C0h] [rbp-8h] v35 = this; *(_QWORD *)v34 = a2; v33 = *(_QWORD *)(a2 + 32); minja::Parser::consumeSpaces(a2, 1); if ( __gnu_cxx::operator==<char const*,std::string>(a2 + 32, a2 + 24) ) { std::shared_ptr<minja::Value>::shared_ptr(this, 0LL); } else if ( *(_BYTE *)__gnu_cxx::__normal_iterator<char const*,std::string>::operator*(a2 + 32) != 34 && *(_BYTE *)__gnu_cxx::__normal_iterator<char const*,std::string>::operator*(a2 + 32) != 39 || ((minja::Parser::parseString[abi:cxx11](v32, a2), (std::unique_ptr<std::string>::operator bool(v32) & 1) == 0) ? (v31 = 0) : (v24 = std::unique_ptr<std::string>::operator*(v32), std::make_shared<minja::Value,std::string &>((_DWORD)this, v24, v2, v3, v4, v5), v31 = 1), std::unique_ptr<std::string>::~unique_ptr(v32), !v31) ) { if ( !(_BYTE)`guard variable for'minja::Parser::parseConstant(void)::prim_tok[abi:cxx11] && __cxa_guard_acquire(&`guard variable for'minja::Parser::parseConstant(void)::prim_tok[abi:cxx11]) ) { std::basic_regex<char,std::regex_traits<char>>::basic_regex( (long long)&minja::Parser::parseConstant(void)::prim_tok[abi:cxx11], (long long)"true\\b|True\\b|false\\b|False\\b|None\\b", 0x10u); __cxa_atexit( (void (*)(void *))std::basic_regex<char,std::regex_traits<char>>::~basic_regex, &minja::Parser::parseConstant(void)::prim_tok[abi:cxx11], &_dso_handle); __cxa_guard_release(&`guard variable for'minja::Parser::parseConstant(void)::prim_tok[abi:cxx11]); } minja::Parser::consumeToken((long long)v30, a2, (long long)&minja::Parser::parseConstant(void)::prim_tok[abi:cxx11], 1u); if ( (std::string::empty(v30) & 1) != 0 ) { minja::Parser::parseNumber(v25, a2, a2 + 32, a2 + 24); if ( 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>::is_null(v25) ) { *(_QWORD *)(a2 + 32) = v33; std::shared_ptr<minja::Value>::shared_ptr(this, 0LL); } else { std::make_shared<minja::Value,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> &>( (_DWORD)this, (unsigned int)v25, v18, v19, v20, v21); } v31 = 1; 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>::~basic_json((long long)v25); } else if ( std::operator==<char>((long long)v30, (long long)"true") || std::operator==<char>((long long)v30, (long long)"True") ) { v29 = 1; std::make_shared<minja::Value,bool>((_DWORD)this, (unsigned int)&v29, v6, v7, v8, v9); v31 = 1; } else if ( std::operator==<char>((long long)v30, (long long)"false") || std::operator==<char>((long long)v30, (long long)"False") ) { v28 = 0; std::make_shared<minja::Value,bool>((_DWORD)this, (unsigned int)&v28, v10, v11, v12, v13); v31 = 1; } else { if ( !std::operator==<char>((long long)v30, (long long)"None") ) { exception = __cxa_allocate_exception(0x10uLL); std::operator+<char>((long long)v26, (long long)"Unknown constant token: ", (long long)v30); std::runtime_error::runtime_error(exception, v26); v25[23] = 0; __cxa_throw( exception, (struct type_info *)&`typeinfo for'std::runtime_error, (void (*)(void *))&std::runtime_error::~runtime_error); } v27 = 0LL; std::make_shared<minja::Value,decltype(nullptr)>((_DWORD)this, (unsigned int)&v27, v14, v15, v16, v17); v31 = 1; } std::string::~string(v30); } return this; }
parseConstant: SUB RSP,0xc8 MOV qword ptr [RSP + 0x18],RDI MOV RAX,RDI MOV qword ptr [RSP + 0x20],RAX MOV qword ptr [RSP + 0xc0],RDI MOV qword ptr [RSP + 0xb8],RSI MOV RDI,qword ptr [RSP + 0xb8] MOV qword ptr [RSP + 0x28],RDI MOV RAX,qword ptr [RDI + 0x20] MOV qword ptr [RSP + 0xb0],RAX MOV ESI,0x1 CALL 0x001d8ae0 MOV RSI,qword ptr [RSP + 0x28] MOV RDI,RSI ADD RDI,0x20 ADD RSI,0x18 CALL 0x00198bd0 TEST AL,0x1 JNZ 0x001e6fc2 JMP 0x001e6fd5 LAB_001e6fc2: MOV RDI,qword ptr [RSP + 0x18] XOR EAX,EAX MOV ESI,EAX CALL 0x001e8b50 JMP 0x001e73ef LAB_001e6fd5: MOV RDI,qword ptr [RSP + 0x28] ADD RDI,0x20 CALL 0x0019ac80 MOVSX EAX,byte ptr [RAX] CMP EAX,0x22 JZ 0x001e7005 MOV RDI,qword ptr [RSP + 0x28] ADD RDI,0x20 CALL 0x0019ac80 MOVSX EAX,byte ptr [RAX] CMP EAX,0x27 JNZ 0x001e70ae LAB_001e7005: MOV RSI,qword ptr [RSP + 0x28] LEA RDI,[RSP + 0xa8] CALL 0x001e8b70 LEA RDI,[RSP + 0xa8] CALL 0x001e8c40 TEST AL,0x1 JNZ 0x001e702a JMP 0x001e7082 LAB_001e702a: LEA RDI,[RSP + 0xa8] CALL 0x001e8ce0 MOV qword ptr [RSP + 0x10],RAX JMP 0x001e703e LAB_001e703e: MOV RSI,qword ptr [RSP + 0x10] MOV RDI,qword ptr [RSP + 0x18] CALL 0x001e8c60 JMP 0x001e704f LAB_001e704f: MOV dword ptr [RSP + 0x98],0x1 JMP 0x001e708d LAB_001e7082: MOV dword ptr [RSP + 0x98],0x0 LAB_001e708d: LEA RDI,[RSP + 0xa8] CALL 0x001e8d10 MOV EAX,dword ptr [RSP + 0x98] TEST EAX,EAX JZ 0x001e70ac JMP 0x001e70a7 LAB_001e70a7: JMP 0x001e73ef LAB_001e70ac: JMP 0x001e70ae LAB_001e70ae: LEA RAX,[0x370520] CMP byte ptr [RAX],0x0 JNZ 0x001e710b LEA RDI,[0x370520] CALL 0x00156530 CMP EAX,0x0 JZ 0x001e710b LAB_001e70cb: LEA RDI,[0x370500] LEA RSI,[0x2e7de5] MOV EDX,0x10 CALL 0x001692d0 LAB_001e70e3: JMP 0x001e70e5 LAB_001e70e5: LEA RDI,[0x169900] LEA RSI,[0x370500] LEA RDX,[0x36f968] CALL 0x00156db0 LEA RDI,[0x370520] CALL 0x001568d0 LAB_001e710b: MOV RSI,qword ptr [RSP + 0x28] LEA RDI,[RSP + 0x78] LEA RDX,[0x370500] MOV ECX,0x1 CALL 0x001d5e70 LEA RDI,[RSP + 0x78] CALL 0x00156430 TEST AL,0x1 JNZ 0x001e7338 LAB_001e7138: LEA RSI,[0x2e497a] LEA RDI,[RSP + 0x78] CALL 0x001688e0 MOV byte ptr [RSP + 0xf],AL JMP 0x001e714f LAB_001e714f: MOV AL,byte ptr [RSP + 0xf] TEST AL,0x1 JNZ 0x001e717a JMP 0x001e7159 LAB_001e7159: LEA RSI,[0x2e79da] LEA RDI,[RSP + 0x78] CALL 0x001688e0 MOV byte ptr [RSP + 0xe],AL JMP 0x001e7170 LAB_001e7170: MOV AL,byte ptr [RSP + 0xe] TEST AL,0x1 JNZ 0x001e717a JMP 0x001e71de LAB_001e717a: MOV RDI,qword ptr [RSP + 0x18] MOV byte ptr [RSP + 0x77],0x1 LEA RSI,[RSP + 0x77] CALL 0x001e8d70 JMP 0x001e7190 LAB_001e7190: MOV dword ptr [RSP + 0x98],0x1 JMP 0x001e73d7 LAB_001e71de: LEA RSI,[0x2e4974] LEA RDI,[RSP + 0x78] CALL 0x001688e0 MOV byte ptr [RSP + 0xd],AL JMP 0x001e71f5 LAB_001e71f5: MOV AL,byte ptr [RSP + 0xd] TEST AL,0x1 JNZ 0x001e7220 JMP 0x001e71ff LAB_001e71ff: LEA RSI,[0x2e79df] LEA RDI,[RSP + 0x78] CALL 0x001688e0 MOV byte ptr [RSP + 0xc],AL JMP 0x001e7216 LAB_001e7216: MOV AL,byte ptr [RSP + 0xc] TEST AL,0x1 JNZ 0x001e7220 JMP 0x001e7246 LAB_001e7220: MOV RDI,qword ptr [RSP + 0x18] MOV byte ptr [RSP + 0x76],0x0 LEA RSI,[RSP + 0x76] CALL 0x001e8d70 JMP 0x001e7236 LAB_001e7236: MOV dword ptr [RSP + 0x98],0x1 JMP 0x001e73d7 LAB_001e7246: LEA RSI,[0x2e7e0a] LEA RDI,[RSP + 0x78] CALL 0x001688e0 MOV byte ptr [RSP + 0xb],AL JMP 0x001e725d LAB_001e725d: MOV AL,byte ptr [RSP + 0xb] TEST AL,0x1 JNZ 0x001e7267 JMP 0x001e7291 LAB_001e7267: MOV RDI,qword ptr [RSP + 0x18] MOV qword ptr [RSP + 0x68],0x0 LEA RSI,[RSP + 0x68] CALL 0x001e8df0 LAB_001e727f: JMP 0x001e7281 LAB_001e7281: MOV dword ptr [RSP + 0x98],0x1 JMP 0x001e73d7 LAB_001e7291: MOV byte ptr [RSP + 0x47],0x1 MOV EDI,0x10 CALL 0x001565c0 MOV qword ptr [RSP],RAX LAB_001e72a4: LEA RSI,[0x2e7e0f] LEA RDI,[RSP + 0x48] LEA RDX,[RSP + 0x78] CALL 0x001c1890 JMP 0x001e72bc LAB_001e72bc: MOV RDI,qword ptr [RSP] LEA RSI,[RSP + 0x48] CALL 0x00156410 JMP 0x001e72cc LAB_001e72cc: MOV RDI,qword ptr [RSP] MOV byte ptr [RSP + 0x47],0x0 MOV RSI,qword ptr [0x0036efa8] MOV RDX,qword ptr [0x0036ef70] CALL 0x001569b0 LAB_001e7338: MOV RSI,qword ptr [RSP + 0x28] MOV RDX,RSI ADD RDX,0x20 MOV RCX,RSI ADD RCX,0x18 LAB_001e734b: LEA RDI,[RSP + 0x30] CALL 0x001e8e70 JMP 0x001e7357 LAB_001e7357: LEA RDI,[RSP + 0x30] CALL 0x001deab0 TEST AL,0x1 JNZ 0x001e73a3 LAB_001e7365: MOV RDI,qword ptr [RSP + 0x18] LEA RSI,[RSP + 0x30] CALL 0x001e9490 LAB_001e7374: JMP 0x001e7376 LAB_001e7376: MOV dword ptr [RSP + 0x98],0x1 JMP 0x001e73cd LAB_001e73a3: MOV RDI,qword ptr [RSP + 0x18] MOV RAX,qword ptr [RSP + 0x28] MOV RCX,qword ptr [RSP + 0xb0] MOV qword ptr [RAX + 0x20],RCX XOR EAX,EAX MOV ESI,EAX CALL 0x001e8b50 MOV dword ptr [RSP + 0x98],0x1 LAB_001e73cd: LEA RDI,[RSP + 0x30] CALL 0x001cb040 LAB_001e73d7: LEA RDI,[RSP + 0x78] CALL 0x001572d0 JMP 0x001e73ef LAB_001e73ef: MOV RAX,qword ptr [RSP + 0x20] ADD RSP,0xc8 RET
/* minja::Parser::parseConstant() */ string * minja::Parser::parseConstant(void) { bool bVar1; int iVar2; char *pcVar3; ulong uVar4; runtime_error *this; Parser *in_RSI; string *in_RDI; __normal_iterator local_98 [23]; int1 local_81; string local_80 [32]; int8 local_60; int1 local_52; int1 local_51; string local_50 [32]; uint local_30; unique_ptr local_20 [8]; int8 local_18; local_18 = *(int8 *)(in_RSI + 0x20); consumeSpaces(in_RSI,1); bVar1 = __gnu_cxx::operator== ((__normal_iterator *)(in_RSI + 0x20),(__normal_iterator *)(in_RSI + 0x18)); if (bVar1) { std::shared_ptr<minja::Value>::shared_ptr((_func_decltype_nullptr *)in_RDI); } else { pcVar3 = (char *)__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>::operator* ((__normal_iterator<char_const*,std::__cxx11::string> *) (in_RSI + 0x20)); if ((*pcVar3 == '\"') || (pcVar3 = (char *)__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>::operator* ((__normal_iterator<char_const*,std::__cxx11::string> *) (in_RSI + 0x20)), *pcVar3 == '\'')) { parseString_abi_cxx11_(); bVar1 = std::unique_ptr::operator_cast_to_bool(local_20); if (bVar1) { /* try { // try from 001e702a to 001e704c has its CatchHandler @ 001e705c */ std::unique_ptr<std::__cxx11::string,std::default_delete<std::__cxx11::string>>::operator* ((unique_ptr<std::__cxx11::string,std::default_delete<std::__cxx11::string>> *) local_20); std::make_shared<minja::Value,std::__cxx11::string&>(in_RDI); } local_30 = (uint)bVar1; std::unique_ptr<std::__cxx11::string,std::default_delete<std::__cxx11::string>>::~unique_ptr ((unique_ptr<std::__cxx11::string,std::default_delete<std::__cxx11::string>> *) local_20); if (local_30 != 0) { return in_RDI; } } if ((parseConstant()::prim_tok_abi_cxx11_ == '\0') && (iVar2 = __cxa_guard_acquire(&parseConstant()::prim_tok_abi_cxx11_), iVar2 != 0)) { /* try { // try from 001e70cb to 001e70e2 has its CatchHandler @ 001e71a0 */ std::__cxx11::basic_regex<char,std::__cxx11::regex_traits<char>>::basic_regex (parseConstant()::prim_tok_abi_cxx11_,"true\\b|True\\b|false\\b|False\\b|None\\b", 0x10); __cxa_atexit(std::__cxx11::basic_regex<char,std::__cxx11::regex_traits<char>>::~basic_regex, parseConstant()::prim_tok_abi_cxx11_,&__dso_handle); __cxa_guard_release(&parseConstant()::prim_tok_abi_cxx11_); } consumeToken(local_50,in_RSI,parseConstant()::prim_tok_abi_cxx11_,1); uVar4 = std::__cxx11::string::empty(); if ((uVar4 & 1) == 0) { /* try { // try from 001e7138 to 001e727e has its CatchHandler @ 001e71c5 */ bVar1 = std::operator==(local_50,"true"); if ((bVar1) || (bVar1 = std::operator==(local_50,"True"), bVar1)) { local_51 = 1; std::make_shared<minja::Value,bool>((bool *)in_RDI); local_30 = 1; } else { bVar1 = std::operator==(local_50,"false"); if ((bVar1) || (bVar1 = std::operator==(local_50,"False"), bVar1)) { local_52 = 0; std::make_shared<minja::Value,bool>((bool *)in_RDI); local_30 = 1; } else { bVar1 = std::operator==(local_50,"None"); if (!bVar1) { local_81 = 1; this = (runtime_error *)__cxa_allocate_exception(0x10); /* try { // try from 001e72a4 to 001e72b9 has its CatchHandler @ 001e72ed */ std::operator+((char *)local_80,(string *)"Unknown constant token: "); /* try { // try from 001e72bc to 001e72e7 has its CatchHandler @ 001e7303 */ std::runtime_error::runtime_error(this,local_80); local_81 = 0; /* WARNING: Subroutine does not return */ __cxa_throw(this,PTR_typeinfo_0036efa8,PTR__runtime_error_0036ef70); } local_60 = 0; std::make_shared<minja::Value,decltype(nullptr)>((_func_decltype_nullptr **)in_RDI); local_30 = 1; } } } else { /* try { // try from 001e734b to 001e7354 has its CatchHandler @ 001e71c5 */ parseNumber(local_98,(__normal_iterator *)in_RSI); uVar4 = 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> ::is_null((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_98); if ((uVar4 & 1) == 0) { /* try { // try from 001e7365 to 001e7373 has its CatchHandler @ 001e7383 */ std:: make_shared<minja::Value,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>&> (in_RDI); } else { *(int8 *)(in_RSI + 0x20) = local_18; std::shared_ptr<minja::Value>::shared_ptr((_func_decltype_nullptr *)in_RDI); } local_30 = 1; 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> ::~basic_json((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_98); } std::__cxx11::string::~string(local_50); } return in_RDI; }
47,495
PickleTensorReader::read_int_value(unsigned int)
7CodeWizard[P]stablediffusion/model.cpp
bool read_int_value(uint32_t value) { if (phase == CHECK_SIZE) { if (entry_size == value * ggml_type_size(tensor_storage.type)) { nelements = value; phase = READ_DIMENS; return true; } else { phase = READ_NAME; } } else if (phase == READ_DIMENS) { if (tensor_storage.n_dims + 1 > 4) { // too many dimens phase = READ_NAME; tensor_storage.n_dims = 0; } if (nelements % value == 0) { tensor_storage.ne[tensor_storage.n_dims] = value; tensor_storage.n_dims++; } } return false; }
O0
cpp
PickleTensorReader::read_int_value(unsigned int): subq $0x38, %rsp movq %rdi, 0x28(%rsp) movl %esi, 0x24(%rsp) movq 0x28(%rsp), %rax movq %rax, 0x18(%rsp) cmpl $0x2, (%rax) jne 0xc3fa7 movq 0x18(%rsp), %rax movq 0x8(%rax), %rcx movq %rcx, 0x10(%rsp) movl 0x24(%rsp), %ecx movq %rcx, 0x8(%rsp) movl 0x38(%rax), %edi callq 0x11afb0 movq 0x8(%rsp), %rcx movq %rax, %rdx movq 0x10(%rsp), %rax imulq %rdx, %rcx cmpq %rcx, %rax jne 0xc3f9a movq 0x18(%rsp), %rax movl 0x24(%rsp), %ecx movl %ecx, 0x10(%rax) movl $0x3, (%rax) movb $0x1, 0x37(%rsp) jmp 0xc400c movq 0x18(%rsp), %rax movl $0x0, (%rax) jmp 0xc4007 movq 0x18(%rsp), %rax cmpl $0x3, (%rax) jne 0xc4005 movq 0x18(%rsp), %rax movl 0x60(%rax), %eax addl $0x1, %eax cmpl $0x4, %eax jle 0xc3fd3 movq 0x18(%rsp), %rax movl $0x0, (%rax) movl $0x0, 0x60(%rax) movq 0x18(%rsp), %rax movl 0x10(%rax), %eax xorl %edx, %edx divl 0x24(%rsp) cmpl $0x0, %edx jne 0xc4003 movq 0x18(%rsp), %rax movl 0x24(%rsp), %ecx movl %ecx, %edx movslq 0x60(%rax), %rcx movq %rdx, 0x40(%rax,%rcx,8) movl 0x60(%rax), %ecx addl $0x1, %ecx movl %ecx, 0x60(%rax) jmp 0xc4005 jmp 0xc4007 movb $0x0, 0x37(%rsp) movb 0x37(%rsp), %al andb $0x1, %al addq $0x38, %rsp retq nopw (%rax,%rax)
_ZN18PickleTensorReader14read_int_valueEj: sub rsp, 38h mov [rsp+38h+var_10], rdi mov [rsp+38h+var_14], esi mov rax, [rsp+38h+var_10] mov [rsp+38h+var_20], rax cmp dword ptr [rax], 2 jnz short loc_C3FA7 mov rax, [rsp+38h+var_20] mov rcx, [rax+8] mov [rsp+38h+var_28], rcx mov ecx, [rsp+38h+var_14] mov [rsp+38h+var_30], rcx mov edi, [rax+38h] call ggml_type_size mov rcx, [rsp+38h+var_30] mov rdx, rax mov rax, [rsp+38h+var_28] imul rcx, rdx cmp rax, rcx jnz short loc_C3F9A mov rax, [rsp+38h+var_20] mov ecx, [rsp+38h+var_14] mov [rax+10h], ecx mov dword ptr [rax], 3 mov [rsp+38h+var_1], 1 jmp short loc_C400C loc_C3F9A: mov rax, [rsp+38h+var_20] mov dword ptr [rax], 0 jmp short loc_C4007 loc_C3FA7: mov rax, [rsp+38h+var_20] cmp dword ptr [rax], 3 jnz short loc_C4005 mov rax, [rsp+38h+var_20] mov eax, [rax+60h] add eax, 1 cmp eax, 4 jle short loc_C3FD3 mov rax, [rsp+38h+var_20] mov dword ptr [rax], 0 mov dword ptr [rax+60h], 0 loc_C3FD3: mov rax, [rsp+38h+var_20] mov eax, [rax+10h] xor edx, edx div [rsp+38h+var_14] cmp edx, 0 jnz short loc_C4003 mov rax, [rsp+38h+var_20] mov ecx, [rsp+38h+var_14] mov edx, ecx movsxd rcx, dword ptr [rax+60h] mov [rax+rcx*8+40h], rdx mov ecx, [rax+60h] add ecx, 1 mov [rax+60h], ecx loc_C4003: jmp short $+2 loc_C4005: jmp short $+2 loc_C4007: mov [rsp+38h+var_1], 0 loc_C400C: mov al, [rsp+38h+var_1] and al, 1 add rsp, 38h retn
char PickleTensorReader::read_int_value(PickleTensorReader *this, unsigned int a2) { long long v3; // [rsp+10h] [rbp-28h] if ( *(_DWORD *)this != 2 ) { if ( *(_DWORD *)this == 3 ) { if ( *((_DWORD *)this + 24) + 1 > 4 ) { *(_DWORD *)this = 0; *((_DWORD *)this + 24) = 0; } if ( !(*((_DWORD *)this + 4) % a2) ) *((_QWORD *)this + (*((_DWORD *)this + 24))++ + 8) = a2; } return 0; } v3 = *((_QWORD *)this + 1); if ( v3 != ggml_type_size(*((unsigned int *)this + 14)) * a2 ) { *(_DWORD *)this = 0; return 0; } *((_DWORD *)this + 4) = a2; *(_DWORD *)this = 3; return 1; }
read_int_value: SUB RSP,0x38 MOV qword ptr [RSP + 0x28],RDI MOV dword ptr [RSP + 0x24],ESI MOV RAX,qword ptr [RSP + 0x28] MOV qword ptr [RSP + 0x18],RAX CMP dword ptr [RAX],0x2 JNZ 0x001c3fa7 MOV RAX,qword ptr [RSP + 0x18] MOV RCX,qword ptr [RAX + 0x8] MOV qword ptr [RSP + 0x10],RCX MOV ECX,dword ptr [RSP + 0x24] MOV qword ptr [RSP + 0x8],RCX MOV EDI,dword ptr [RAX + 0x38] CALL 0x0021afb0 MOV RCX,qword ptr [RSP + 0x8] MOV RDX,RAX MOV RAX,qword ptr [RSP + 0x10] IMUL RCX,RDX CMP RAX,RCX JNZ 0x001c3f9a MOV RAX,qword ptr [RSP + 0x18] MOV ECX,dword ptr [RSP + 0x24] MOV dword ptr [RAX + 0x10],ECX MOV dword ptr [RAX],0x3 MOV byte ptr [RSP + 0x37],0x1 JMP 0x001c400c LAB_001c3f9a: MOV RAX,qword ptr [RSP + 0x18] MOV dword ptr [RAX],0x0 JMP 0x001c4007 LAB_001c3fa7: MOV RAX,qword ptr [RSP + 0x18] CMP dword ptr [RAX],0x3 JNZ 0x001c4005 MOV RAX,qword ptr [RSP + 0x18] MOV EAX,dword ptr [RAX + 0x60] ADD EAX,0x1 CMP EAX,0x4 JLE 0x001c3fd3 MOV RAX,qword ptr [RSP + 0x18] MOV dword ptr [RAX],0x0 MOV dword ptr [RAX + 0x60],0x0 LAB_001c3fd3: MOV RAX,qword ptr [RSP + 0x18] MOV EAX,dword ptr [RAX + 0x10] XOR EDX,EDX DIV dword ptr [RSP + 0x24] CMP EDX,0x0 JNZ 0x001c4003 MOV RAX,qword ptr [RSP + 0x18] MOV ECX,dword ptr [RSP + 0x24] MOV EDX,ECX MOVSXD RCX,dword ptr [RAX + 0x60] MOV qword ptr [RAX + RCX*0x8 + 0x40],RDX MOV ECX,dword ptr [RAX + 0x60] ADD ECX,0x1 MOV dword ptr [RAX + 0x60],ECX LAB_001c4003: JMP 0x001c4005 LAB_001c4005: JMP 0x001c4007 LAB_001c4007: MOV byte ptr [RSP + 0x37],0x0 LAB_001c400c: MOV AL,byte ptr [RSP + 0x37] AND AL,0x1 ADD RSP,0x38 RET
/* PickleTensorReader::read_int_value(unsigned int) */ int1 __thiscall PickleTensorReader::read_int_value(PickleTensorReader *this,uint param_1) { long lVar1; long lVar2; if (*(int *)this == 2) { lVar1 = *(long *)(this + 8); lVar2 = ggml_type_size(*(int4 *)(this + 0x38)); if (lVar1 == (ulong)param_1 * lVar2) { *(uint *)(this + 0x10) = param_1; *(int4 *)this = 3; return 1; } *(int4 *)this = 0; } else if (*(int *)this == 3) { if (4 < *(int *)(this + 0x60) + 1) { *(int4 *)this = 0; *(int4 *)(this + 0x60) = 0; } if (*(uint *)(this + 0x10) % param_1 == 0) { *(ulong *)(this + (long)*(int *)(this + 0x60) * 8 + 0x40) = (ulong)param_1; *(int *)(this + 0x60) = *(int *)(this + 0x60) + 1; } } return 0; }
47,496
PickleTensorReader::read_int_value(unsigned int)
7CodeWizard[P]stablediffusion/model.cpp
bool read_int_value(uint32_t value) { if (phase == CHECK_SIZE) { if (entry_size == value * ggml_type_size(tensor_storage.type)) { nelements = value; phase = READ_DIMENS; return true; } else { phase = READ_NAME; } } else if (phase == READ_DIMENS) { if (tensor_storage.n_dims + 1 > 4) { // too many dimens phase = READ_NAME; tensor_storage.n_dims = 0; } if (nelements % value == 0) { tensor_storage.ne[tensor_storage.n_dims] = value; tensor_storage.n_dims++; } } return false; }
O1
cpp
PickleTensorReader::read_int_value(unsigned int): pushq %rbp pushq %r15 pushq %r14 pushq %rbx pushq %rax movl %esi, %ebp movq %rdi, %rbx movl (%rdi), %eax cmpl $0x3, %eax je 0x6d953 cmpl $0x2, %eax jne 0x6d986 movq 0x8(%rbx), %r14 movl %ebp, %r15d movl 0x38(%rbx), %edi callq 0x8e159 imulq %r15, %rax cmpq %rax, %r14 jne 0x6d980 movl %ebp, 0x10(%rbx) movl $0x3, (%rbx) movb $0x1, %cl jmp 0x6d988 cmpl $0x4, 0x60(%rbx) jl 0x6d960 xorl %eax, %eax movl %eax, (%rbx) movl %eax, 0x60(%rbx) movl 0x10(%rbx), %eax xorl %ecx, %ecx xorl %edx, %edx divl %ebp testl %edx, %edx jne 0x6d988 movl %ebp, %eax movslq 0x60(%rbx), %rcx movq %rax, 0x40(%rbx,%rcx,8) leal 0x1(%rcx), %eax movl %eax, 0x60(%rbx) jmp 0x6d986 movl $0x0, (%rbx) xorl %ecx, %ecx movl %ecx, %eax addq $0x8, %rsp popq %rbx popq %r14 popq %r15 popq %rbp retq nop
_ZN18PickleTensorReader14read_int_valueEj: push rbp push r15 push r14 push rbx push rax mov ebp, esi mov rbx, rdi mov eax, [rdi] cmp eax, 3 jz short loc_6D953 cmp eax, 2 jnz short loc_6D986 mov r14, [rbx+8] mov r15d, ebp mov edi, [rbx+38h] call ggml_type_size imul rax, r15 cmp r14, rax jnz short loc_6D980 mov [rbx+10h], ebp mov dword ptr [rbx], 3 mov cl, 1 jmp short loc_6D988 loc_6D953: cmp dword ptr [rbx+60h], 4 jl short loc_6D960 xor eax, eax mov [rbx], eax mov [rbx+60h], eax loc_6D960: mov eax, [rbx+10h] xor ecx, ecx xor edx, edx div ebp test edx, edx jnz short loc_6D988 mov eax, ebp movsxd rcx, dword ptr [rbx+60h] mov [rbx+rcx*8+40h], rax lea eax, [rcx+1] mov [rbx+60h], eax jmp short loc_6D986 loc_6D980: mov dword ptr [rbx], 0 loc_6D986: xor ecx, ecx loc_6D988: mov eax, ecx add rsp, 8 pop rbx pop r14 pop r15 pop rbp retn
long long PickleTensorReader::read_int_value(PickleTensorReader *this, unsigned int a2) { long long v2; // r14 unsigned int v3; // ecx long long v4; // rcx if ( *(_DWORD *)this != 3 ) { if ( *(_DWORD *)this == 2 ) { v2 = *((_QWORD *)this + 1); if ( v2 == a2 * ggml_type_size(*((unsigned int *)this + 14)) ) { *((_DWORD *)this + 4) = a2; *(_DWORD *)this = 3; LOBYTE(v3) = 1; return v3; } *(_DWORD *)this = 0; } return 0; } if ( *((int *)this + 24) >= 4 ) { *(_DWORD *)this = 0; *((_DWORD *)this + 24) = 0; } v3 = 0; if ( !(*((_DWORD *)this + 4) % a2) ) { v4 = *((int *)this + 24); *((_QWORD *)this + v4 + 8) = a2; *((_DWORD *)this + 24) = v4 + 1; return 0; } return v3; }
47,497
PickleTensorReader::read_int_value(unsigned int)
7CodeWizard[P]stablediffusion/model.cpp
bool read_int_value(uint32_t value) { if (phase == CHECK_SIZE) { if (entry_size == value * ggml_type_size(tensor_storage.type)) { nelements = value; phase = READ_DIMENS; return true; } else { phase = READ_NAME; } } else if (phase == READ_DIMENS) { if (tensor_storage.n_dims + 1 > 4) { // too many dimens phase = READ_NAME; tensor_storage.n_dims = 0; } if (nelements % value == 0) { tensor_storage.ne[tensor_storage.n_dims] = value; tensor_storage.n_dims++; } } return false; }
O2
cpp
PickleTensorReader::read_int_value(unsigned int): pushq %rbp pushq %r15 pushq %r14 pushq %rbx pushq %rax movl %esi, %ebp movq %rdi, %rbx movl (%rdi), %eax cmpl $0x3, %eax je 0x4aae1 cmpl $0x2, %eax jne 0x4ab13 movq 0x8(%rbx), %r14 movl %ebp, %r15d movl 0x38(%rbx), %edi callq 0x67b83 imulq %r15, %rax cmpq %rax, %r14 jne 0x4ab10 movl %ebp, 0x10(%rbx) movl $0x3, (%rbx) movb $0x1, %cl jmp 0x4ab15 movl 0x60(%rbx), %esi cmpl $0x4, %esi jl 0x4aaf2 andl $0x0, (%rbx) andl $0x0, 0x60(%rbx) xorl %esi, %esi movl 0x10(%rbx), %eax xorl %ecx, %ecx xorl %edx, %edx divl %ebp testl %edx, %edx jne 0x4ab15 movl %ebp, %eax movslq %esi, %rcx movq %rax, 0x40(%rbx,%rcx,8) incl %ecx movl %ecx, 0x60(%rbx) jmp 0x4ab13 andl $0x0, (%rbx) xorl %ecx, %ecx movl %ecx, %eax addq $0x8, %rsp popq %rbx popq %r14 popq %r15 popq %rbp retq
_ZN18PickleTensorReader14read_int_valueEj: push rbp push r15 push r14 push rbx push rax mov ebp, esi mov rbx, rdi mov eax, [rdi] cmp eax, 3 jz short loc_4AAE1 cmp eax, 2 jnz short loc_4AB13 mov r14, [rbx+8] mov r15d, ebp mov edi, [rbx+38h] call ggml_type_size imul rax, r15 cmp r14, rax jnz short loc_4AB10 mov [rbx+10h], ebp mov dword ptr [rbx], 3 mov cl, 1 jmp short loc_4AB15 loc_4AAE1: mov esi, [rbx+60h] cmp esi, 4 jl short loc_4AAF2 and dword ptr [rbx], 0 and dword ptr [rbx+60h], 0 xor esi, esi loc_4AAF2: mov eax, [rbx+10h] xor ecx, ecx xor edx, edx div ebp test edx, edx jnz short loc_4AB15 mov eax, ebp movsxd rcx, esi mov [rbx+rcx*8+40h], rax inc ecx mov [rbx+60h], ecx jmp short loc_4AB13 loc_4AB10: and dword ptr [rbx], 0 loc_4AB13: xor ecx, ecx loc_4AB15: mov eax, ecx add rsp, 8 pop rbx pop r14 pop r15 pop rbp retn
long long PickleTensorReader::read_int_value(PickleTensorReader *this, unsigned int a2) { long long v3; // r14 unsigned int v4; // ecx int v5; // esi if ( *(_DWORD *)this != 3 ) { if ( *(_DWORD *)this == 2 ) { v3 = *((_QWORD *)this + 1); if ( v3 == a2 * ggml_type_size(*((unsigned int *)this + 14)) ) { *((_DWORD *)this + 4) = a2; *(_DWORD *)this = 3; LOBYTE(v4) = 1; return v4; } *(_DWORD *)this = 0; } return 0; } v5 = *((_DWORD *)this + 24); if ( v5 >= 4 ) { *(_DWORD *)this = 0; *((_DWORD *)this + 24) = 0; v5 = 0; } v4 = 0; if ( !(*((_DWORD *)this + 4) % a2) ) { *((_QWORD *)this + v5 + 8) = a2; *((_DWORD *)this + 24) = v5 + 1; return 0; } return v4; }
read_int_value: PUSH RBP PUSH R15 PUSH R14 PUSH RBX PUSH RAX MOV EBP,ESI MOV RBX,RDI MOV EAX,dword ptr [RDI] CMP EAX,0x3 JZ 0x0014aae1 CMP EAX,0x2 JNZ 0x0014ab13 MOV R14,qword ptr [RBX + 0x8] MOV R15D,EBP MOV EDI,dword ptr [RBX + 0x38] CALL 0x00167b83 IMUL RAX,R15 CMP R14,RAX JNZ 0x0014ab10 MOV dword ptr [RBX + 0x10],EBP MOV dword ptr [RBX],0x3 MOV CL,0x1 JMP 0x0014ab15 LAB_0014aae1: MOV ESI,dword ptr [RBX + 0x60] CMP ESI,0x4 JL 0x0014aaf2 AND dword ptr [RBX],0x0 AND dword ptr [RBX + 0x60],0x0 XOR ESI,ESI LAB_0014aaf2: MOV EAX,dword ptr [RBX + 0x10] XOR ECX,ECX XOR EDX,EDX DIV EBP TEST EDX,EDX JNZ 0x0014ab15 MOV EAX,EBP MOVSXD RCX,ESI MOV qword ptr [RBX + RCX*0x8 + 0x40],RAX INC ECX MOV dword ptr [RBX + 0x60],ECX JMP 0x0014ab13 LAB_0014ab10: AND dword ptr [RBX],0x0 LAB_0014ab13: XOR ECX,ECX LAB_0014ab15: MOV EAX,ECX ADD RSP,0x8 POP RBX POP R14 POP R15 POP RBP RET
/* PickleTensorReader::read_int_value(unsigned int) */ ulong PickleTensorReader::read_int_value(uint param_1) { long lVar1; long lVar2; int8 in_RCX; ulong uVar3; uint in_ESI; int iVar4; int4 in_register_0000003c; int *piVar5; piVar5 = (int *)CONCAT44(in_register_0000003c,param_1); if (*piVar5 == 3) { iVar4 = piVar5[0x18]; if (3 < iVar4) { *piVar5 = 0; piVar5[0x18] = 0; iVar4 = 0; } uVar3 = 0; if ((uint)piVar5[4] % in_ESI != 0) goto LAB_0014ab15; *(ulong *)(piVar5 + (long)iVar4 * 2 + 0x10) = (ulong)in_ESI; piVar5[0x18] = iVar4 + 1; } else if (*piVar5 == 2) { lVar1 = *(long *)(piVar5 + 2); lVar2 = ggml_type_size(piVar5[0xe]); if (lVar1 == lVar2 * (ulong)in_ESI) { piVar5[4] = in_ESI; *piVar5 = 3; uVar3 = CONCAT71((int7)((ulong)in_RCX >> 8),1); goto LAB_0014ab15; } *piVar5 = 0; } uVar3 = 0; LAB_0014ab15: return uVar3 & 0xffffffff; }
47,498
PickleTensorReader::read_int_value(unsigned int)
7CodeWizard[P]stablediffusion/model.cpp
bool read_int_value(uint32_t value) { if (phase == CHECK_SIZE) { if (entry_size == value * ggml_type_size(tensor_storage.type)) { nelements = value; phase = READ_DIMENS; return true; } else { phase = READ_NAME; } } else if (phase == READ_DIMENS) { if (tensor_storage.n_dims + 1 > 4) { // too many dimens phase = READ_NAME; tensor_storage.n_dims = 0; } if (nelements % value == 0) { tensor_storage.ne[tensor_storage.n_dims] = value; tensor_storage.n_dims++; } } return false; }
O3
cpp
PickleTensorReader::read_int_value(unsigned int): pushq %rbp pushq %r15 pushq %r14 pushq %rbx pushq %rax movl %esi, %ebp movq %rdi, %rbx movl (%rdi), %eax cmpl $0x3, %eax je 0x6cd1b cmpl $0x2, %eax jne 0x6cd4e movq 0x8(%rbx), %r14 movl %ebp, %r15d movl 0x38(%rbx), %edi callq 0x8ceea imulq %r15, %rax cmpq %rax, %r14 jne 0x6cd48 movl %ebp, 0x10(%rbx) movl $0x3, (%rbx) movb $0x1, %cl jmp 0x6cd50 movl 0x60(%rbx), %esi cmpl $0x4, %esi jl 0x6cd2a xorl %esi, %esi movl %esi, (%rbx) movl %esi, 0x60(%rbx) movl 0x10(%rbx), %eax xorl %ecx, %ecx xorl %edx, %edx divl %ebp testl %edx, %edx jne 0x6cd50 movl %ebp, %eax movslq %esi, %rcx movq %rax, 0x40(%rbx,%rcx,8) incl %ecx movl %ecx, 0x60(%rbx) jmp 0x6cd4e movl $0x0, (%rbx) xorl %ecx, %ecx movl %ecx, %eax addq $0x8, %rsp popq %rbx popq %r14 popq %r15 popq %rbp retq nop
_ZN18PickleTensorReader14read_int_valueEj: push rbp push r15 push r14 push rbx push rax mov ebp, esi mov rbx, rdi mov eax, [rdi] cmp eax, 3 jz short loc_6CD1B cmp eax, 2 jnz short loc_6CD4E mov r14, [rbx+8] mov r15d, ebp mov edi, [rbx+38h] call ggml_type_size imul rax, r15 cmp r14, rax jnz short loc_6CD48 mov [rbx+10h], ebp mov dword ptr [rbx], 3 mov cl, 1 jmp short loc_6CD50 loc_6CD1B: mov esi, [rbx+60h] cmp esi, 4 jl short loc_6CD2A xor esi, esi mov [rbx], esi mov [rbx+60h], esi loc_6CD2A: mov eax, [rbx+10h] xor ecx, ecx xor edx, edx div ebp test edx, edx jnz short loc_6CD50 mov eax, ebp movsxd rcx, esi mov [rbx+rcx*8+40h], rax inc ecx mov [rbx+60h], ecx jmp short loc_6CD4E loc_6CD48: mov dword ptr [rbx], 0 loc_6CD4E: xor ecx, ecx loc_6CD50: mov eax, ecx add rsp, 8 pop rbx pop r14 pop r15 pop rbp retn
long long PickleTensorReader::read_int_value(PickleTensorReader *this, unsigned int a2) { long long v3; // r14 unsigned int v4; // ecx int v5; // esi if ( *(_DWORD *)this != 3 ) { if ( *(_DWORD *)this == 2 ) { v3 = *((_QWORD *)this + 1); if ( v3 == a2 * ggml_type_size(*((unsigned int *)this + 14)) ) { *((_DWORD *)this + 4) = a2; *(_DWORD *)this = 3; LOBYTE(v4) = 1; return v4; } *(_DWORD *)this = 0; } return 0; } v5 = *((_DWORD *)this + 24); if ( v5 >= 4 ) { v5 = 0; *(_DWORD *)this = 0; *((_DWORD *)this + 24) = 0; } v4 = 0; if ( !(*((_DWORD *)this + 4) % a2) ) { *((_QWORD *)this + v5 + 8) = a2; *((_DWORD *)this + 24) = v5 + 1; return 0; } return v4; }
47,499
minja::Context::at(minja::Value const&)
monkey531[P]llama/common/minja.hpp
virtual Value & at(const Value & key) { if (values_.contains(key)) return values_.at(key); if (parent_) return parent_->at(key); throw std::runtime_error("Undefined variable: " + key.dump()); }
O3
cpp
minja::Context::at(minja::Value const&): pushq %rbp pushq %r15 pushq %r14 pushq %rbx subq $0x48, %rsp movq %rsi, %r14 movq %rdi, %rbx leaq 0x18(%rdi), %r15 movq %r15, %rdi callq 0x926e2 testb %al, %al je 0x9bea9 movq %r15, %rdi movq %r14, %rsi addq $0x48, %rsp popq %rbx popq %r14 popq %r15 popq %rbp jmp 0x924d0 movq 0x68(%rbx), %rdi testq %rdi, %rdi je 0x9bec8 movq (%rdi), %rax movq 0x18(%rax), %rax movq %r14, %rsi addq $0x48, %rsp popq %rbx popq %r14 popq %r15 popq %rbp jmpq *%rax movl $0x10, %edi callq 0x1a430 movq %rax, %rbx leaq 0x8(%rsp), %rdi movq %r14, %rsi movl $0xffffffff, %edx # imm = 0xFFFFFFFF xorl %ecx, %ecx callq 0x85792 leaq 0x53b23(%rip), %rsi # 0xefa13 leaq 0x28(%rsp), %rdi leaq 0x8(%rsp), %rdx callq 0x77e59 movb $0x1, %bpl leaq 0x28(%rsp), %rsi movq %rbx, %rdi callq 0x1adb0 xorl %ebp, %ebp movq 0x8e0d0(%rip), %rsi # 0x129fe8 movq 0x8e039(%rip), %rdx # 0x129f58 movq %rbx, %rdi callq 0x1aea0 movq %rax, %r14 leaq 0x38(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0x9bf45 movq 0x38(%rsp), %rsi incq %rsi callq 0x1a890 leaq 0x18(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0x9bf60 movq 0x18(%rsp), %rsi incq %rsi callq 0x1a890 testb %bpl, %bpl jne 0x9bf8a jmp 0x9bf92 movq %rax, %r14 leaq 0x18(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0x9bf8a movq 0x18(%rsp), %rsi incq %rsi callq 0x1a890 jmp 0x9bf8a movq %rax, %r14 movq %rbx, %rdi callq 0x1a640 movq %r14, %rdi callq 0x1af20
_ZN5minja7Context2atERKNS_5ValueE: push rbp push r15 push r14 push rbx sub rsp, 48h mov r14, rsi mov rbx, rdi lea r15, [rdi+18h] mov rdi, r15; this call _ZNK5minja5Value8containsERKS0_; minja::Value::contains(minja::Value const&) test al, al jz short loc_9BEA9 mov rdi, r15; this mov rsi, r14; minja::Value * add rsp, 48h pop rbx pop r14 pop r15 pop rbp jmp _ZN5minja5Value2atERKS0_; minja::Value::at(minja::Value const&) loc_9BEA9: mov rdi, [rbx+68h] test rdi, rdi jz short loc_9BEC8 mov rax, [rdi] mov rax, [rax+18h] mov rsi, r14 add rsp, 48h pop rbx pop r14 pop r15 pop rbp jmp rax loc_9BEC8: mov edi, 10h; thrown_size call ___cxa_allocate_exception mov rbx, rax lea rdi, [rsp+68h+var_60] mov rsi, r14 mov edx, 0FFFFFFFFh xor ecx, ecx call _ZNK5minja5Value4dumpB5cxx11Eib; minja::Value::dump(int,bool) lea rsi, aUndefinedVaria; "Undefined variable: " lea rdi, [rsp+68h+var_40] lea rdx, [rsp+68h+var_60] call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_OS8_; std::operator+<char>(char const*,std::string&&) mov bpl, 1 lea rsi, [rsp+68h+var_40] 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:_ZTISt19_Sp_make_shared_tag; void (*)(void *) mov rdi, rbx; void * call ___cxa_throw mov r14, rax lea rax, [rsp+68h+var_30] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_9BF45 mov rsi, [rsp+68h+var_30] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_9BF45: lea rax, [rsp+68h+var_50] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_9BF60 mov rsi, [rsp+68h+var_50] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_9BF60: test bpl, bpl jnz short loc_9BF8A jmp short loc_9BF92 mov r14, rax lea rax, [rsp+68h+var_50] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_9BF8A mov rsi, [rsp+68h+var_50] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) jmp short loc_9BF8A mov r14, rax loc_9BF8A: mov rdi, rbx; void * call ___cxa_free_exception loc_9BF92: mov rdi, r14 call __Unwind_Resume
unsigned long long minja::Context::at(minja::Context *this, const minja::Value *a2, __m128d a3) { long long v4; // rdi void *exception; // rbx _BYTE v6[16]; // [rsp+8h] [rbp-60h] BYREF _BYTE v7[16]; // [rsp+28h] [rbp-40h] BYREF if ( minja::Value::contains((minja::Context *)((char *)this + 24), a2, a3) ) return minja::Value::at((minja::Context *)((char *)this + 24), a2); v4 = *((_QWORD *)this + 13); if ( !v4 ) { exception = __cxa_allocate_exception(0x10uLL); minja::Value::dump[abi:cxx11]((long long)v6, (long long)a2, 0xFFFFFFFF, 0); std::operator+<char>((long long)v7, (long long)"Undefined variable: ", (long long)v6); std::runtime_error::runtime_error(exception, v7); __cxa_throw( exception, (struct type_info *)&`typeinfo for'std::runtime_error, (void (*)(void *))&std::runtime_error::~runtime_error); } return (*(long long ( **)(long long, const minja::Value *))(*(_QWORD *)v4 + 24LL))(v4, a2); }
at: PUSH RBP PUSH R15 PUSH R14 PUSH RBX SUB RSP,0x48 MOV R14,RSI MOV RBX,RDI LEA R15,[RDI + 0x18] MOV RDI,R15 CALL 0x001926e2 TEST AL,AL JZ 0x0019bea9 MOV RDI,R15 MOV RSI,R14 ADD RSP,0x48 POP RBX POP R14 POP R15 POP RBP JMP 0x001924d0 LAB_0019bea9: MOV RDI,qword ptr [RBX + 0x68] TEST RDI,RDI JZ 0x0019bec8 MOV RAX,qword ptr [RDI] MOV RAX,qword ptr [RAX + 0x18] MOV RSI,R14 ADD RSP,0x48 POP RBX POP R14 POP R15 POP RBP JMP RAX LAB_0019bec8: MOV EDI,0x10 CALL 0x0011a430 MOV RBX,RAX LAB_0019bed5: LEA RDI,[RSP + 0x8] MOV RSI,R14 MOV EDX,0xffffffff XOR ECX,ECX CALL 0x00185792 LAB_0019bee9: LEA RSI,[0x1efa13] LEA RDI,[RSP + 0x28] LEA RDX,[RSP + 0x8] CALL 0x00177e59 MOV BPL,0x1 LAB_0019bf02: LEA RSI,[RSP + 0x28] MOV RDI,RBX CALL 0x0011adb0 XOR EBP,EBP MOV RSI,qword ptr [0x00229fe8] MOV RDX,qword ptr [0x00229f58] MOV RDI,RBX CALL 0x0011aea0
/* minja::Context::at(minja::Value const&) */ void __thiscall minja::Context::at(Context *this,Value *param_1) { long *plVar1; char cVar2; runtime_error *this_00; int1 local_60 [32]; string local_40 [32]; cVar2 = Value::contains((Value *)(this + 0x18),param_1); if (cVar2 != '\0') { Value::at((Value *)(this + 0x18),param_1); return; } plVar1 = *(long **)(this + 0x68); if (plVar1 != (long *)0x0) { /* WARNING: Could not recover jumptable at 0x0019bec6. Too many branches */ /* WARNING: Treating indirect jump as call */ (**(code **)(*plVar1 + 0x18))(plVar1,param_1); return; } this_00 = (runtime_error *)__cxa_allocate_exception(0x10); /* try { // try from 0019bed5 to 0019bee8 has its CatchHandler @ 0019bf87 */ Value::dump_abi_cxx11_((int)local_60,SUB81(param_1,0)); /* try { // try from 0019bee9 to 0019befe has its CatchHandler @ 0019bf67 */ std::operator+((char *)local_40,(string *)"Undefined variable: "); /* try { // try from 0019bf02 to 0019bf26 has its CatchHandler @ 0019bf27 */ std::runtime_error::runtime_error(this_00,local_40); /* WARNING: Subroutine does not return */ __cxa_throw(this_00,PTR_typeinfo_00229fe8,PTR__runtime_error_00229f58); }