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
31,800
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>::insert(nlohmann::json_abi_v3_11_3::detail::iter_impl<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> const&)
llama.cpp/common/json.hpp
iterator insert(const_iterator pos, const basic_json& val) { // insert only works for arrays if (JSON_HEDLEY_LIKELY(is_array())) { // check if iterator pos fits to this JSON value if (JSON_HEDLEY_UNLIKELY(pos.m_object != this)) { JSON_THROW(invalid_iterator::create(202, "iterator does not fit current value", this)); } // insert to array and return iterator return insert_iterator(pos, val); } JSON_THROW(type_error::create(309, detail::concat("cannot use insert() with ", type_name()), this)); }
O3
cpp
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>::insert(nlohmann::json_abi_v3_11_3::detail::iter_impl<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> const&): pushq %rbp pushq %r15 pushq %r14 pushq %rbx subq $0x48, %rsp movq %rsi, %r14 cmpb $0x2, (%rsi) jne 0x6220e movq (%rdx), %rsi cmpq %r14, %rsi jne 0x6226a movq %rdi, %rbx leaq 0x28(%rsp), %rax movq %rsi, (%rax) movups 0x8(%rdx), %xmm0 movups %xmm0, 0x8(%rax) movq 0x18(%rdx), %rdx movq %rdx, 0x18(%rax) movq %r14, %rsi movq %rax, %rdx callq 0x624e4 movq %rbx, %rax addq $0x48, %rsp popq %rbx popq %r14 popq %r15 popq %rbp retq movl $0x20, %edi callq 0x1d520 movq %rax, %rbx movq %r14, %rdi callq 0x607fe leaq 0x20(%rsp), %rdx movq %rax, (%rdx) leaq 0x7060a(%rip), %rsi # 0xd283c movq %rsp, %rdi callq 0x62558 movb $0x1, %bpl movq %rsp, %rdx movq %rbx, %rdi movl $0x135, %esi # imm = 0x135 movq %r14, %rcx callq 0x61958 xorl %ebp, %ebp leaq 0xa6c67(%rip), %rsi # 0x108ec0 leaq -0x38f42(%rip), %rdx # 0x2931e movq %rbx, %rdi callq 0x1d890 jmp 0x622c4 movl $0x20, %edi callq 0x1d520 movq %rax, %rbx leaq 0x10(%rsp), %r15 movq %r15, -0x10(%r15) leaq 0x68a2e(%rip), %rsi # 0xcacb5 leaq 0x68a4a(%rip), %rdx # 0xcacd8 movq %rsp, %rdi callq 0x237c2 movb $0x1, %bpl movq %rsp, %rdx movq %rbx, %rdi movl $0xca, %esi movq %r14, %rcx callq 0x6230c xorl %ebp, %ebp leaq 0xa6bcb(%rip), %rsi # 0x108e80 leaq -0x38f9e(%rip), %rdx # 0x2931e movq %rbx, %rdi callq 0x1d890 movq %rax, %r14 movq (%rsp), %rdi cmpq %r15, %rdi jne 0x622e5 jmp 0x622f2 jmp 0x622f9 movq %rax, %r14 leaq 0x10(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0x622f2 movq 0x10(%rsp), %rsi incq %rsi callq 0x1d160 testb %bpl, %bpl jne 0x622fc jmp 0x62304 movq %rax, %r14 movq %rbx, %rdi callq 0x1dc90 movq %r14, %rdi callq 0x1d8e0
_ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE6insertENS0_6detail9iter_implIKSD_EERSG_: push rbp; void * push r15; int push r14; __int64 push rbx; int sub rsp, 48h mov r14, rsi cmp byte ptr [rsi], 2 jnz short loc_6220E mov rsi, [rdx] cmp rsi, r14 jnz loc_6226A mov rbx, rdi lea rax, [rsp+68h+var_40] mov [rax], rsi movups xmm0, xmmword ptr [rdx+8] movups xmmword ptr [rax+8], xmm0 mov rdx, [rdx+18h] mov [rax+18h], rdx mov rsi, r14 mov rdx, rax call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE15insert_iteratorIJRKSD_EEENS0_6detail9iter_implISD_EENSI_ISF_EEDpOT_; 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>::insert_iterator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const&>(nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const>,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const&) mov rax, rbx add rsp, 48h pop rbx pop r14 pop r15 pop rbp retn loc_6220E: 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+68h+var_48] mov [rdx], rax lea rsi, aCannotUseInser; "cannot use insert() with " mov rdi, rsp call _ZN8nlohmann16json_abi_v3_11_36detail6concatINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEJRA26_KcPS9_EEET_DpOT0_; nlohmann::json_abi_v3_11_3::detail::concat<std::string,char const(&)[26],char const*>(char const(&)[26],char const* &&) mov bpl, 1 mov rdx, rsp mov rdi, rbx; this mov esi, 135h; int mov rcx, r14 call _ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIPNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SJ_ 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 jmp short loc_622C4 loc_6226A: mov edi, 20h ; ' '; thrown_size call ___cxa_allocate_exception mov rbx, rax lea r15, [rsp+68h+var_58] mov [r15-10h], r15 lea rsi, aIteratorDoesNo; "iterator does not fit current value" lea rdx, aIteratorDoesNo+23h; "" mov rdi, rsp 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 bpl, 1 mov rdx, rsp mov rdi, rbx; this mov esi, 0CAh; int mov rcx, r14 call _ZN8nlohmann16json_abi_v3_11_36detail16invalid_iterator6createIPNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SJ_ xor ebp, ebp lea rsi, _ZTIN8nlohmann16json_abi_v3_11_36detail16invalid_iteratorE; lptinfo lea rdx, _ZN8nlohmann16json_abi_v3_11_36detail9exceptionD2Ev; void (*)(void *) mov rdi, rbx; void * call ___cxa_throw loc_622C4: mov r14, rax mov rdi, [rsp+68h+var_68] cmp rdi, r15 jnz short loc_622E5 jmp short loc_622F2 jmp short loc_622F9 mov r14, rax lea rax, [rsp+68h+var_58] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_622F2 loc_622E5: mov rsi, [rsp+68h+var_58] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_622F2: test bpl, bpl jnz short loc_622FC jmp short loc_62304 loc_622F9: mov r14, rax loc_622FC: mov rdi, rbx; void * call ___cxa_free_exception loc_62304: mov rdi, r14 call __Unwind_Resume
insert: PUSH RBP PUSH R15 PUSH R14 PUSH RBX SUB RSP,0x48 MOV R14,RSI CMP byte ptr [RSI],0x2 JNZ 0x0016220e MOV RSI,qword ptr [RDX] CMP RSI,R14 JNZ 0x0016226a MOV RBX,RDI LEA RAX,[RSP + 0x28] MOV qword ptr [RAX],RSI MOVUPS XMM0,xmmword ptr [RDX + 0x8] MOVUPS xmmword ptr [RAX + 0x8],XMM0 MOV RDX,qword ptr [RDX + 0x18] MOV qword ptr [RAX + 0x18],RDX MOV RSI,R14 MOV RDX,RAX CALL 0x001624e4 MOV RAX,RBX ADD RSP,0x48 POP RBX POP R14 POP R15 POP RBP RET LAB_0016220e: MOV EDI,0x20 CALL 0x0011d520 MOV RBX,RAX MOV RDI,R14 CALL 0x001607fe LEA RDX,[RSP + 0x20] MOV qword ptr [RDX],RAX LAB_0016222b: LEA RSI,[0x1d283c] MOV RDI,RSP CALL 0x00162558 MOV BPL,0x1 LAB_0016223d: MOV RDX,RSP MOV RDI,RBX MOV ESI,0x135 MOV RCX,R14 CALL 0x00161958 XOR EBP,EBP LEA RSI,[0x208ec0] LEA RDX,[0x12931e] MOV RDI,RBX CALL 0x0011d890 LAB_0016226a: MOV EDI,0x20 CALL 0x0011d520 MOV RBX,RAX LEA R15,[RSP + 0x10] MOV qword ptr [R15 + -0x10],R15 LAB_00162280: LEA RSI,[0x1cacb5] LEA RDX,[0x1cacd8] MOV RDI,RSP CALL 0x001237c2 MOV BPL,0x1 LAB_00162299: MOV RDX,RSP MOV RDI,RBX MOV ESI,0xca MOV RCX,R14 CALL 0x0016230c XOR EBP,EBP LEA RSI,[0x208e80] LEA RDX,[0x12931e] MOV RDI,RBX CALL 0x0011d890
/* 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>::insert(nlohmann::json_abi_v3_11_3::detail::iter_impl<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> const&) */ 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> * __thiscall 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> ::insert(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,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_2,long *param_3) { int8 uVar1; int1 *local_68 [2]; int1 local_58 [16]; char *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> *local_40; int4 local_38; int4 uStack_34; int4 uStack_30; int4 uStack_2c; long local_28; if (*param_2 != (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> )0x2) { uVar1 = __cxa_allocate_exception(0x20); local_48 = (char *)type_name(param_2); /* try { // try from 0016222b to 00162239 has its CatchHandler @ 001622f9 */ detail::concat<std::__cxx11::string,char_const(&)[26],char_const*> ((detail *)local_68,"cannot use insert() with ",&local_48); /* try { // try from 0016223d to 00162267 has its CatchHandler @ 001622d4 */ _ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIPNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SJ_ (uVar1,0x135,local_68,param_2); /* WARNING: Subroutine does not return */ __cxa_throw(uVar1,&detail::type_error::typeinfo,detail::exception::~exception); } local_40 = (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_3; if (local_40 == param_2) { local_38 = (int4)param_3[1]; uStack_34 = *(int4 *)((long)param_3 + 0xc); uStack_30 = (int4)param_3[2]; uStack_2c = *(int4 *)((long)param_3 + 0x14); local_28 = param_3[3]; insert_iterator<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&> (this,param_2,&local_40); return this; } uVar1 = __cxa_allocate_exception(0x20); local_68[0] = local_58; /* try { // try from 00162280 to 00162295 has its CatchHandler @ 001622d2 */ std::__cxx11::string::_M_construct<char_const*>(local_68,"iterator does not fit current value","") ; /* try { // try from 00162299 to 001622c3 has its CatchHandler @ 001622c4 */ _ZN8nlohmann16json_abi_v3_11_36detail16invalid_iterator6createIPNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SJ_ (uVar1,0xca,local_68,param_2); /* WARNING: Subroutine does not return */ __cxa_throw(uVar1,&detail::invalid_iterator::typeinfo,detail::exception::~exception); }
31,801
Effect::addEffectChild(Object*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, glm::vec<2, float, (glm::qualifier)0>, float, ObjectWorld*)
GhostEscape/src/world/effect.cpp
Effect *Effect::addEffectChild(Object* parent, const std::string &file_path, glm::vec2 pos, float scale, ObjectWorld *next_object) { auto effect = new Effect(); effect->init(); effect->sprite_ = SpriteAnim::addSpriteAnimChild(effect, file_path, scale); effect->sprite_->setLoop(false); effect->setPosition(pos); effect->setNextObject(next_object); if (parent) parent->addChild(effect); return effect; }
O3
cpp
Effect::addEffectChild(Object*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, glm::vec<2, float, (glm::qualifier)0>, float, ObjectWorld*): pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r12 pushq %rbx subq $0x10, %rsp movq %rdx, %r15 movss %xmm1, -0x24(%rbp) movq %rsi, %r12 movq %rdi, %r14 movlps %xmm0, -0x30(%rbp) movl $0x78, %edi callq 0x53b0 movq %rax, %rbx xorps %xmm0, %xmm0 movaps %xmm0, (%rax) movaps %xmm0, 0x10(%rax) movaps %xmm0, 0x20(%rax) movaps %xmm0, 0x30(%rax) movaps %xmm0, 0x40(%rax) movaps %xmm0, 0x50(%rax) movaps %xmm0, 0x60(%rax) movq $0x0, 0x70(%rax) leaq 0x9509(%rip), %rax # 0x150b0 addq $0x10, %rax movq %rax, (%rbx) callq 0x66dc movq %rax, 0x10(%rbx) xorps %xmm0, %xmm0 movups %xmm0, 0x18(%rbx) movups %xmm0, 0x28(%rbx) movups %xmm0, 0x38(%rbx) movw $0x1, 0x48(%rbx) movq $0x0, 0x60(%rbx) movups %xmm0, 0x4c(%rbx) leaq 0x9b31(%rip), %rax # 0x15710 movq %rax, (%rbx) movups %xmm0, 0x68(%rbx) movl $0x2, 0x8(%rbx) movq %rbx, %rdi movq %r12, %rsi movss -0x24(%rbp), %xmm0 movl $0x5, %edx callq 0xc1c4 movq %rax, 0x68(%rbx) movb $0x0, 0xac(%rax) leaq -0x30(%rbp), %rsi movq %rbx, %rdi callq 0x8e18 movq %r15, 0x70(%rbx) testq %r14, %r14 je 0xbc2e movq (%r14), %rax movq %r14, %rdi movq %rbx, %rsi callq *0x38(%rax) movq %rbx, %rax addq $0x10, %rsp popq %rbx popq %r12 popq %r14 popq %r15 popq %rbp retq movq %rax, %r14 movl $0x78, %esi movq %rbx, %rdi callq 0x53d0 movq %r14, %rdi callq 0x5600
_ZN6Effect14addEffectChildEP6ObjectRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN3glm3vecILi2EfLNSA_9qualifierE0EEEfP11ObjectWorld: push rbp mov rbp, rsp push r15 push r14 push r12 push rbx sub rsp, 10h mov r15, rdx movss [rbp+var_24], xmm1 mov r12, rsi mov r14, rdi movlps [rbp+var_30], xmm0 mov edi, offset dword_78; this call __Znwm; operator new(ulong) mov rbx, rax xorps xmm0, xmm0 movaps xmmword ptr [rax], xmm0 movaps xmmword ptr [rax+10h], xmm0 movaps xmmword ptr [rax+20h], xmm0 movaps xmmword ptr [rax+30h], xmm0 movaps xmmword ptr [rax+40h], xmm0 movaps xmmword ptr [rax+50h], xmm0 movaps xmmword ptr [rax+60h], xmm0 mov qword ptr [rax+70h], 0 lea rax, _ZTV6Object; `vtable for'Object add rax, 10h mov [rbx], rax call _ZN4Game11GetInstanceEv; Game::GetInstance(void) mov [rbx+10h], rax xorps xmm0, xmm0 movups xmmword ptr [rbx+18h], xmm0 movups xmmword ptr [rbx+28h], xmm0 movups xmmword ptr [rbx+38h], xmm0 mov word ptr [rbx+48h], 1 mov qword ptr [rbx+60h], 0 movups xmmword ptr [rbx+4Ch], xmm0 lea rax, off_15710 mov [rbx], rax movups xmmword ptr [rbx+68h], xmm0 mov dword ptr [rbx+8], 2 mov rdi, rbx mov rsi, r12 movss xmm0, [rbp+var_24] mov edx, 5 call _ZN10SpriteAnim18addSpriteAnimChildEP12ObjectScreenRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEf6Anchor; SpriteAnim::addSpriteAnimChild(ObjectScreen *,std::string const&,float,Anchor) mov [rbx+68h], rax mov byte ptr [rax+0ACh], 0 lea rsi, [rbp+var_30] mov rdi, rbx call _ZN11ObjectWorld11setPositionERKN3glm3vecILi2EfLNS0_9qualifierE0EEE; ObjectWorld::setPosition(glm::vec<2,float,(glm::qualifier)0> const&) mov [rbx+70h], r15 test r14, r14 jz short loc_BC2E mov rax, [r14] mov rdi, r14 mov rsi, rbx call qword ptr [rax+38h] loc_BC2E: mov rax, rbx add rsp, 10h pop rbx pop r12 pop r14 pop r15 pop rbp retn mov r14, rax mov esi, 78h ; 'x'; unsigned __int64 mov rdi, rbx; void * call __ZdlPvm; operator delete(void *,ulong) mov rdi, r14 call __Unwind_Resume
long long Effect::addEffectChild(long long a1, long long a2, long long a3, __m128 a4, float a5) { long long v6; // rbx long long v7; // rax unsigned long long v9; // [rsp+0h] [rbp-30h] BYREF float v10; // [rsp+Ch] [rbp-24h] v10 = a5; _mm_storel_ps((double *)&v9, a4); v6 = operator new((unsigned long long)&dword_78); *(_OWORD *)v6 = 0LL; *(_OWORD *)(v6 + 16) = 0LL; *(_OWORD *)(v6 + 32) = 0LL; *(_OWORD *)(v6 + 48) = 0LL; *(_OWORD *)(v6 + 64) = 0LL; *(_OWORD *)(v6 + 80) = 0LL; *(_OWORD *)(v6 + 96) = 0LL; *(_QWORD *)(v6 + 112) = 0LL; *(_QWORD *)v6 = &`vtable for'Object + 2; *(_QWORD *)(v6 + 16) = Game::GetInstance((Game *)&dword_78); *(_OWORD *)(v6 + 24) = 0LL; *(_OWORD *)(v6 + 40) = 0LL; *(_OWORD *)(v6 + 56) = 0LL; *(_WORD *)(v6 + 72) = 1; *(_QWORD *)(v6 + 96) = 0LL; *(_OWORD *)(v6 + 76) = 0LL; *(_QWORD *)v6 = off_15710; *(_OWORD *)(v6 + 104) = 0LL; *(_DWORD *)(v6 + 8) = 2; v7 = SpriteAnim::addSpriteAnimChild(v6, a2, 5LL, v10); *(_QWORD *)(v6 + 104) = v7; *(_BYTE *)(v7 + 172) = 0; ObjectWorld::setPosition(v6, &v9); *(_QWORD *)(v6 + 112) = a3; if ( a1 ) (*(void ( **)(long long, long long))(*(_QWORD *)a1 + 56LL))(a1, v6); return v6; }
addEffectChild: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R12 PUSH RBX SUB RSP,0x10 MOV R15,RDX MOVSS dword ptr [RBP + -0x24],XMM1 MOV R12,RSI MOV R14,RDI MOVLPS qword ptr [RBP + -0x30],XMM0 MOV EDI,0x78 CALL 0x001053b0 MOV RBX,RAX XORPS XMM0,XMM0 MOVAPS xmmword ptr [RAX],XMM0 MOVAPS xmmword ptr [RAX + 0x10],XMM0 MOVAPS xmmword ptr [RAX + 0x20],XMM0 MOVAPS xmmword ptr [RAX + 0x30],XMM0 MOVAPS xmmword ptr [RAX + 0x40],XMM0 MOVAPS xmmword ptr [RAX + 0x50],XMM0 MOVAPS xmmword ptr [RAX + 0x60],XMM0 MOV qword ptr [RAX + 0x70],0x0 LEA RAX,[0x1150b0] ADD RAX,0x10 MOV qword ptr [RBX],RAX LAB_0010bbae: CALL 0x001066dc LAB_0010bbb3: MOV qword ptr [RBX + 0x10],RAX XORPS XMM0,XMM0 MOVUPS xmmword ptr [RBX + 0x18],XMM0 MOVUPS xmmword ptr [RBX + 0x28],XMM0 MOVUPS xmmword ptr [RBX + 0x38],XMM0 MOV word ptr [RBX + 0x48],0x1 MOV qword ptr [RBX + 0x60],0x0 MOVUPS xmmword ptr [RBX + 0x4c],XMM0 LEA RAX,[0x115710] MOV qword ptr [RBX],RAX MOVUPS xmmword ptr [RBX + 0x68],XMM0 MOV dword ptr [RBX + 0x8],0x2 MOV RDI,RBX MOV RSI,R12 MOVSS XMM0,dword ptr [RBP + -0x24] MOV EDX,0x5 CALL 0x0010c1c4 MOV qword ptr [RBX + 0x68],RAX MOV byte ptr [RAX + 0xac],0x0 LEA RSI,[RBP + -0x30] MOV RDI,RBX CALL 0x00108e18 MOV qword ptr [RBX + 0x70],R15 TEST R14,R14 JZ 0x0010bc2e MOV RAX,qword ptr [R14] MOV RDI,R14 MOV RSI,RBX CALL qword ptr [RAX + 0x38] LAB_0010bc2e: MOV RAX,RBX ADD RSP,0x10 POP RBX POP R12 POP R14 POP R15 POP RBP RET
/* Effect::addEffectChild(Object*, std::__cxx11::string const&, glm::vec<2, float, (glm::qualifier)0>, float, ObjectWorld*) */ ObjectWorld * Effect::addEffectChild (int8 param_1_00,int4 param_2_00,long *param_1,int8 param_2, int8 param_5) { ObjectWorld *this; int8 uVar1; long lVar2; int8 local_38; int4 local_2c; local_38 = param_1_00; local_2c = param_2_00; this = (ObjectWorld *)operator_new(0x78); *(int8 *)this = 0; *(int8 *)(this + 8) = 0; *(int8 *)(this + 0x10) = 0; *(int8 *)(this + 0x18) = 0; *(int8 *)(this + 0x20) = 0; *(int8 *)(this + 0x28) = 0; *(int8 *)(this + 0x30) = 0; *(int8 *)(this + 0x38) = 0; *(int8 *)(this + 0x40) = 0; *(int8 *)(this + 0x48) = 0; *(int8 *)(this + 0x50) = 0; *(int8 *)(this + 0x58) = 0; *(int8 *)(this + 0x60) = 0; *(int8 *)(this + 0x68) = 0; *(int8 *)(this + 0x70) = 0; *(int ***)this = &PTR__Object_001150c0; /* try { // try from 0010bbae to 0010bbb2 has its CatchHandler @ 0010bc3e */ uVar1 = Game::GetInstance(); *(int8 *)(this + 0x10) = uVar1; *(int8 *)(this + 0x18) = 0; *(int8 *)(this + 0x20) = 0; *(int8 *)(this + 0x28) = 0; *(int8 *)(this + 0x30) = 0; *(int8 *)(this + 0x38) = 0; *(int8 *)(this + 0x40) = 0; *(int2 *)(this + 0x48) = 1; *(int8 *)(this + 0x60) = 0; *(int8 *)(this + 0x4c) = 0; *(int8 *)(this + 0x54) = 0; *(int ***)this = &PTR__Object_00115710; *(int8 *)(this + 0x68) = 0; *(int8 *)(this + 0x70) = 0; *(int4 *)(this + 8) = 2; lVar2 = SpriteAnim::addSpriteAnimChild(local_2c,this,param_2,5); *(long *)(this + 0x68) = lVar2; *(int1 *)(lVar2 + 0xac) = 0; ObjectWorld::setPosition(this,(vec *)&local_38); *(int8 *)(this + 0x70) = param_5; if (param_1 != (long *)0x0) { (**(code **)(*param_1 + 0x38))(param_1,this); } return this; }
31,802
maria_rnext
eloqsql/storage/maria/ma_rnext.c
int maria_rnext(MARIA_HA *info, uchar *buf, int inx) { int error,changed; uint flag; MARIA_SHARE *share= info->s; MARIA_KEYDEF *keyinfo; check_result_t check= CHECK_POS; uint update_mask= HA_STATE_NEXT_FOUND; DBUG_ENTER("maria_rnext"); if ((inx = _ma_check_index(info,inx)) < 0) DBUG_RETURN(my_errno); flag=SEARCH_BIGGER; /* Read next */ if (info->cur_row.lastpos == HA_OFFSET_ERROR && info->update & HA_STATE_PREV_FOUND) flag=0; /* Read first */ if (fast_ma_readinfo(info)) DBUG_RETURN(my_errno); keyinfo= share->keyinfo + inx; if (share->lock_key_trees) mysql_rwlock_rdlock(&keyinfo->root_lock); changed= _ma_test_if_changed(info); if (!flag) { switch (keyinfo->key_alg){ #ifdef HAVE_RTREE_KEYS case HA_KEY_ALG_RTREE: error=maria_rtree_get_first(info, inx, info->last_key.data_length + info->last_key.ref_length); break; #endif case HA_KEY_ALG_BTREE: default: error= _ma_search_first(info, keyinfo, share->state.key_root[inx]); break; } /* "search first" failed. This means we have no pivot for "search next", or in other words MI_INFO::lastkey is likely uninitialized. Normally SQL layer would never request "search next" if "search first" failed. But HANDLER may do anything. As mi_rnext() without preceding mi_rkey()/mi_rfirst() equals to mi_rfirst(), we must restore original state as if failing mi_rfirst() was not called. */ if (error) update_mask|= HA_STATE_PREV_FOUND; } else { switch (keyinfo->key_alg) { #ifdef HAVE_RTREE_KEYS case HA_KEY_ALG_RTREE: /* Note that rtree doesn't support that the table may be changed since last call, so we do need to skip rows inserted by other threads like in btree */ error= maria_rtree_get_next(info, inx, info->last_key.data_length + info->last_key.ref_length); break; #endif case HA_KEY_ALG_BTREE: default: if (!changed) error= _ma_search_next(info, &info->last_key, flag | info->last_key.flag, share->state.key_root[inx]); else error= _ma_search(info, &info->last_key, flag | info->last_key.flag, share->state.key_root[inx]); } } if (!error) { while (!(*share->row_is_visible)(info) || ((check= ma_check_index_cond(info, inx, buf)) == CHECK_NEG)) { /* If we are at the last key on the key page, allow writers to access the index. */ if (info->int_keypos >= info->int_maxpos && ma_yield_and_check_if_killed(info, inx)) { /* my_errno is set by ma_yield_and_check_if_killed() */ error= 1; break; } /* Skip rows inserted by other threads since we got a lock */ if ((error= _ma_search_next(info, &info->last_key, SEARCH_BIGGER, share->state.key_root[inx]))) break; } } if (share->lock_key_trees) mysql_rwlock_unlock(&keyinfo->root_lock); /* Don't clear if database-changed */ info->update&= (HA_STATE_CHANGED | HA_STATE_ROW_CHANGED); info->update|= update_mask; if (error || check != CHECK_POS) { fast_ma_writeinfo(info); if (my_errno == HA_ERR_KEY_NOT_FOUND) my_errno= HA_ERR_END_OF_FILE; } else if (!buf) { fast_ma_writeinfo(info); DBUG_RETURN(info->cur_row.lastpos == HA_OFFSET_ERROR ? my_errno : 0); } else if (!(*info->read_record)(info, buf, info->cur_row.lastpos)) { info->update|= HA_STATE_AKTIV; /* Record is read */ DBUG_RETURN(0); } DBUG_PRINT("error",("Got error: %d, errno: %d",error, my_errno)); DBUG_RETURN(my_errno); }
O0
c
maria_rnext: pushq %rbp movq %rsp, %rbp subq $0x50, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movl %edx, -0x1c(%rbp) movq -0x10(%rbp), %rax movq (%rax), %rax movq %rax, -0x30(%rbp) movl $0x1, -0x3c(%rbp) movl $0x10, -0x40(%rbp) movq -0x10(%rbp), %rdi movl -0x1c(%rbp), %esi callq 0x384b0 movl %eax, -0x1c(%rbp) cmpl $0x0, %eax jge 0x37b41 jmp 0x37b32 callq 0xfa320 movl (%rax), %eax movl %eax, -0x4(%rbp) jmp 0x37f1a movl $0x8, -0x28(%rbp) movq -0x10(%rbp), %rax cmpq $-0x1, 0x98(%rax) jne 0x37b6f movq -0x10(%rbp), %rax movl 0x624(%rax), %eax andl $0x20, %eax cmpl $0x0, %eax je 0x37b6f movl $0x0, -0x28(%rbp) movq -0x10(%rbp), %rax cmpl $0x2, 0x664(%rax) jne 0x37ba2 movq -0x10(%rbp), %rdi xorl %esi, %esi movl $0x1, %edx callq 0x441c0 cmpl $0x0, %eax je 0x37ba2 jmp 0x37b93 callq 0xfa320 movl (%rax), %eax movl %eax, -0x4(%rbp) jmp 0x37f1a movq -0x30(%rbp), %rax movq 0x570(%rax), %rax movslq -0x1c(%rbp), %rcx imulq $0x118, %rcx, %rcx # imm = 0x118 addq %rcx, %rax movq %rax, -0x38(%rbp) movq -0x30(%rbp), %rax cmpb $0x0, 0x7e3(%rax) je 0x37be5 movq -0x38(%rbp), %rdi addq $0x8, %rdi leaq 0x11c9fa(%rip), %rsi # 0x1545d5 movl $0x30, %edx callq 0x37f30 movq -0x10(%rbp), %rdi callq 0x44110 movl %eax, -0x24(%rbp) cmpl $0x0, -0x28(%rbp) jne 0x37c74 movq -0x38(%rbp), %rax movzbl 0xa4(%rax), %eax movl %eax, -0x44(%rbp) subl $0x1, %eax je 0x37c3b jmp 0x37c0c movl -0x44(%rbp), %eax subl $0x2, %eax jne 0x37c3d jmp 0x37c16 movq -0x10(%rbp), %rdi movl -0x1c(%rbp), %esi movq -0x10(%rbp), %rax movl 0x210(%rax), %edx movq -0x10(%rbp), %rax addl 0x214(%rax), %edx callq 0x78450 movl %eax, -0x20(%rbp) jmp 0x37c60 jmp 0x37c3d movq -0x10(%rbp), %rdi movq -0x38(%rbp), %rsi movq -0x30(%rbp), %rax movq 0x118(%rax), %rax movslq -0x1c(%rbp), %rcx movq (%rax,%rcx,8), %rdx callq 0x3c6e0 movl %eax, -0x20(%rbp) cmpl $0x0, -0x20(%rbp) je 0x37c6f movl -0x40(%rbp), %eax orl $0x20, %eax movl %eax, -0x40(%rbp) jmp 0x37d34 movq -0x38(%rbp), %rax movzbl 0xa4(%rax), %eax movl %eax, -0x48(%rbp) subl $0x1, %eax je 0x37cb8 jmp 0x37c89 movl -0x48(%rbp), %eax subl $0x2, %eax jne 0x37cba jmp 0x37c93 movq -0x10(%rbp), %rdi movl -0x1c(%rbp), %esi movq -0x10(%rbp), %rax movl 0x210(%rax), %edx movq -0x10(%rbp), %rax addl 0x214(%rax), %edx callq 0x78a20 movl %eax, -0x20(%rbp) jmp 0x37d32 jmp 0x37cba cmpl $0x0, -0x24(%rbp) jne 0x37cf9 movq -0x10(%rbp), %rdi movq -0x10(%rbp), %rsi addq $0x200, %rsi # imm = 0x200 movl -0x28(%rbp), %edx movq -0x10(%rbp), %rax orl 0x218(%rax), %edx movq -0x30(%rbp), %rax movq 0x118(%rax), %rax movslq -0x1c(%rbp), %rcx movq (%rax,%rcx,8), %rcx callq 0x3c1e0 movl %eax, -0x20(%rbp) jmp 0x37d30 movq -0x10(%rbp), %rdi movq -0x10(%rbp), %rsi addq $0x200, %rsi # imm = 0x200 movl -0x28(%rbp), %edx movq -0x10(%rbp), %rax orl 0x218(%rax), %edx movq -0x30(%rbp), %rax movq 0x118(%rax), %rax movslq -0x1c(%rbp), %rcx movq (%rax,%rcx,8), %rcx callq 0x38640 movl %eax, -0x20(%rbp) jmp 0x37d32 jmp 0x37d34 cmpl $0x0, -0x20(%rbp) jne 0x37df4 jmp 0x37d40 movq -0x30(%rbp), %rax movq 0x6d8(%rax), %rax movq -0x10(%rbp), %rdi callq *%rax movb %al, %cl movb $0x1, %al cmpb $0x0, %cl movb %al, -0x49(%rbp) je 0x37d79 movq -0x10(%rbp), %rdi movl -0x1c(%rbp), %esi movq -0x18(%rbp), %rdx callq 0x43710 movl %eax, -0x3c(%rbp) cmpl $0x0, %eax sete %al movb %al, -0x49(%rbp) movb -0x49(%rbp), %al testb $0x1, %al jne 0x37d82 jmp 0x37df2 movq -0x10(%rbp), %rax movq 0x3b0(%rax), %rax movq -0x10(%rbp), %rcx cmpq 0x3b8(%rcx), %rax jb 0x37db7 movq -0x10(%rbp), %rdi movl -0x1c(%rbp), %esi callq 0x379c0 movsbl %al, %eax cmpl $0x0, %eax je 0x37db7 movl $0x1, -0x20(%rbp) jmp 0x37df2 movq -0x10(%rbp), %rdi movq -0x10(%rbp), %rsi addq $0x200, %rsi # imm = 0x200 movq -0x30(%rbp), %rax movq 0x118(%rax), %rax movslq -0x1c(%rbp), %rcx movq (%rax,%rcx,8), %rcx movl $0x8, %edx callq 0x3c1e0 movl %eax, -0x20(%rbp) cmpl $0x0, %eax je 0x37ded jmp 0x37df2 jmp 0x37d40 jmp 0x37df4 movq -0x30(%rbp), %rax cmpb $0x0, 0x7e3(%rax) je 0x37e0e movq -0x38(%rbp), %rdi addq $0x8, %rdi callq 0x37fa0 movq -0x10(%rbp), %rax movl 0x624(%rax), %ecx andl $0x401, %ecx # imm = 0x401 movl %ecx, 0x624(%rax) movl -0x40(%rbp), %ecx movq -0x10(%rbp), %rax orl 0x624(%rax), %ecx movl %ecx, 0x624(%rax) cmpl $0x0, -0x20(%rbp) jne 0x37e43 cmpl $0x1, -0x3c(%rbp) je 0x37e78 movq -0x10(%rbp), %rax movq (%rax), %rax cmpl $0x0, 0x7b8(%rax) jne 0x37e5e movq -0x10(%rbp), %rdi xorl %esi, %esi callq 0x441e0 callq 0xfa320 cmpl $0x78, (%rax) jne 0x37e73 callq 0xfa320 movl $0x89, (%rax) jmp 0x37f0a cmpq $0x0, -0x18(%rbp) jne 0x37ec5 movq -0x10(%rbp), %rax movq (%rax), %rax cmpl $0x0, 0x7b8(%rax) jne 0x37e9a movq -0x10(%rbp), %rdi xorl %esi, %esi callq 0x441e0 jmp 0x37e9c movq -0x10(%rbp), %rax cmpq $-0x1, 0x98(%rax) jne 0x37eb6 callq 0xfa320 movl (%rax), %eax movl %eax, -0x50(%rbp) jmp 0x37ebd xorl %eax, %eax movl %eax, -0x50(%rbp) jmp 0x37ebd movl -0x50(%rbp), %eax movl %eax, -0x4(%rbp) jmp 0x37f1a movq -0x10(%rbp), %rax movq 0x3d8(%rax), %rax movq -0x10(%rbp), %rdi movq -0x18(%rbp), %rsi movq -0x10(%rbp), %rcx movq 0x98(%rcx), %rdx callq *%rax cmpl $0x0, %eax jne 0x37f06 movq -0x10(%rbp), %rax movl 0x624(%rax), %ecx orl $0x2, %ecx movl %ecx, 0x624(%rax) movl $0x0, -0x4(%rbp) jmp 0x37f1a jmp 0x37f08 jmp 0x37f0a jmp 0x37f0c jmp 0x37f0e jmp 0x37f10 callq 0xfa320 movl (%rax), %eax movl %eax, -0x4(%rbp) movl -0x4(%rbp), %eax addq $0x50, %rsp popq %rbp retq nopw %cs:(%rax,%rax)
maria_rnext: push rbp mov rbp, rsp sub rsp, 50h mov [rbp+var_10], rdi mov [rbp+var_18], rsi mov [rbp+var_1C], edx mov rax, [rbp+var_10] mov rax, [rax] mov [rbp+var_30], rax mov [rbp+var_3C], 1 mov [rbp+var_40], 10h mov rdi, [rbp+var_10] mov esi, [rbp+var_1C] call _ma_check_index mov [rbp+var_1C], eax cmp eax, 0 jge short loc_37B41 jmp short $+2 loc_37B32: call _my_thread_var mov eax, [rax] mov [rbp+var_4], eax jmp loc_37F1A loc_37B41: mov [rbp+var_28], 8 mov rax, [rbp+var_10] cmp qword ptr [rax+98h], 0FFFFFFFFFFFFFFFFh jnz short loc_37B6F mov rax, [rbp+var_10] mov eax, [rax+624h] and eax, 20h cmp eax, 0 jz short loc_37B6F mov [rbp+var_28], 0 loc_37B6F: mov rax, [rbp+var_10] cmp dword ptr [rax+664h], 2 jnz short loc_37BA2 mov rdi, [rbp+var_10] xor esi, esi mov edx, 1 call _ma_readinfo cmp eax, 0 jz short loc_37BA2 jmp short $+2 loc_37B93: call _my_thread_var mov eax, [rax] mov [rbp+var_4], eax jmp loc_37F1A loc_37BA2: mov rax, [rbp+var_30] mov rax, [rax+570h] movsxd rcx, [rbp+var_1C] imul rcx, 118h add rax, rcx mov [rbp+var_38], rax mov rax, [rbp+var_30] cmp byte ptr [rax+7E3h], 0 jz short loc_37BE5 mov rdi, [rbp+var_38] add rdi, 8 lea rsi, aWorkspaceLlm4b_4; "/workspace/llm4binary/github2025/eloqsq"... mov edx, 30h ; '0' call inline_mysql_rwlock_rdlock_0 loc_37BE5: mov rdi, [rbp+var_10] call _ma_test_if_changed mov [rbp+var_24], eax cmp [rbp+var_28], 0 jnz short loc_37C74 mov rax, [rbp+var_38] movzx eax, byte ptr [rax+0A4h] mov [rbp+var_44], eax sub eax, 1 jz short loc_37C3B jmp short $+2 loc_37C0C: mov eax, [rbp+var_44] sub eax, 2 jnz short loc_37C3D jmp short $+2 loc_37C16: mov rdi, [rbp+var_10] mov esi, [rbp+var_1C] mov rax, [rbp+var_10] mov edx, [rax+210h] mov rax, [rbp+var_10] add edx, [rax+214h] call maria_rtree_get_first mov [rbp+var_20], eax jmp short loc_37C60 loc_37C3B: jmp short $+2 loc_37C3D: mov rdi, [rbp+var_10] mov rsi, [rbp+var_38] mov rax, [rbp+var_30] mov rax, [rax+118h] movsxd rcx, [rbp+var_1C] mov rdx, [rax+rcx*8] call _ma_search_first mov [rbp+var_20], eax loc_37C60: cmp [rbp+var_20], 0 jz short loc_37C6F mov eax, [rbp+var_40] or eax, 20h mov [rbp+var_40], eax loc_37C6F: jmp loc_37D34 loc_37C74: mov rax, [rbp+var_38] movzx eax, byte ptr [rax+0A4h] mov [rbp+var_48], eax sub eax, 1 jz short loc_37CB8 jmp short $+2 loc_37C89: mov eax, [rbp+var_48] sub eax, 2 jnz short loc_37CBA jmp short $+2 loc_37C93: mov rdi, [rbp+var_10] mov esi, [rbp+var_1C] mov rax, [rbp+var_10] mov edx, [rax+210h] mov rax, [rbp+var_10] add edx, [rax+214h] call maria_rtree_get_next mov [rbp+var_20], eax jmp short loc_37D32 loc_37CB8: jmp short $+2 loc_37CBA: cmp [rbp+var_24], 0 jnz short loc_37CF9 mov rdi, [rbp+var_10] mov rsi, [rbp+var_10] add rsi, 200h mov edx, [rbp+var_28] mov rax, [rbp+var_10] or edx, [rax+218h] mov rax, [rbp+var_30] mov rax, [rax+118h] movsxd rcx, [rbp+var_1C] mov rcx, [rax+rcx*8] call _ma_search_next mov [rbp+var_20], eax jmp short loc_37D30 loc_37CF9: mov rdi, [rbp+var_10] mov rsi, [rbp+var_10] add rsi, 200h mov edx, [rbp+var_28] mov rax, [rbp+var_10] or edx, [rax+218h] mov rax, [rbp+var_30] mov rax, [rax+118h] movsxd rcx, [rbp+var_1C] mov rcx, [rax+rcx*8] call _ma_search mov [rbp+var_20], eax loc_37D30: jmp short $+2 loc_37D32: jmp short $+2 loc_37D34: cmp [rbp+var_20], 0 jnz loc_37DF4 jmp short $+2 loc_37D40: mov rax, [rbp+var_30] mov rax, [rax+6D8h] mov rdi, [rbp+var_10] call rax mov cl, al mov al, 1 cmp cl, 0 mov [rbp+var_49], al jz short loc_37D79 mov rdi, [rbp+var_10] mov esi, [rbp+var_1C] mov rdx, [rbp+var_18] call ma_check_index_cond mov [rbp+var_3C], eax cmp eax, 0 setz al mov [rbp+var_49], al loc_37D79: mov al, [rbp+var_49] test al, 1 jnz short loc_37D82 jmp short loc_37DF2 loc_37D82: mov rax, [rbp+var_10] mov rax, [rax+3B0h] mov rcx, [rbp+var_10] cmp rax, [rcx+3B8h] jb short loc_37DB7 mov rdi, [rbp+var_10] mov esi, [rbp+var_1C] call ma_yield_and_check_if_killed movsx eax, al cmp eax, 0 jz short loc_37DB7 mov [rbp+var_20], 1 jmp short loc_37DF2 loc_37DB7: mov rdi, [rbp+var_10] mov rsi, [rbp+var_10] add rsi, 200h mov rax, [rbp+var_30] mov rax, [rax+118h] movsxd rcx, [rbp+var_1C] mov rcx, [rax+rcx*8] mov edx, 8 call _ma_search_next mov [rbp+var_20], eax cmp eax, 0 jz short loc_37DED jmp short loc_37DF2 loc_37DED: jmp loc_37D40 loc_37DF2: jmp short $+2 loc_37DF4: mov rax, [rbp+var_30] cmp byte ptr [rax+7E3h], 0 jz short loc_37E0E mov rdi, [rbp+var_38] add rdi, 8 call inline_mysql_rwlock_unlock_0 loc_37E0E: mov rax, [rbp+var_10] mov ecx, [rax+624h] and ecx, 401h mov [rax+624h], ecx mov ecx, [rbp+var_40] mov rax, [rbp+var_10] or ecx, [rax+624h] mov [rax+624h], ecx cmp [rbp+var_20], 0 jnz short loc_37E43 cmp [rbp+var_3C], 1 jz short loc_37E78 loc_37E43: mov rax, [rbp+var_10] mov rax, [rax] cmp dword ptr [rax+7B8h], 0 jnz short loc_37E5E mov rdi, [rbp+var_10] xor esi, esi call _ma_writeinfo loc_37E5E: call _my_thread_var cmp dword ptr [rax], 78h ; 'x' jnz short loc_37E73 call _my_thread_var mov dword ptr [rax], 89h loc_37E73: jmp loc_37F0A loc_37E78: cmp [rbp+var_18], 0 jnz short loc_37EC5 mov rax, [rbp+var_10] mov rax, [rax] cmp dword ptr [rax+7B8h], 0 jnz short loc_37E9A mov rdi, [rbp+var_10] xor esi, esi call _ma_writeinfo loc_37E9A: jmp short $+2 loc_37E9C: mov rax, [rbp+var_10] cmp qword ptr [rax+98h], 0FFFFFFFFFFFFFFFFh jnz short loc_37EB6 call _my_thread_var mov eax, [rax] mov [rbp+var_50], eax jmp short loc_37EBD loc_37EB6: xor eax, eax mov [rbp+var_50], eax jmp short $+2 loc_37EBD: mov eax, [rbp+var_50] mov [rbp+var_4], eax jmp short loc_37F1A loc_37EC5: mov rax, [rbp+var_10] mov rax, [rax+3D8h] mov rdi, [rbp+var_10] mov rsi, [rbp+var_18] mov rcx, [rbp+var_10] mov rdx, [rcx+98h] call rax cmp eax, 0 jnz short loc_37F06 mov rax, [rbp+var_10] mov ecx, [rax+624h] or ecx, 2 mov [rax+624h], ecx mov [rbp+var_4], 0 jmp short loc_37F1A loc_37F06: jmp short $+2 loc_37F08: jmp short $+2 loc_37F0A: jmp short $+2 loc_37F0C: jmp short $+2 loc_37F0E: jmp short $+2 loc_37F10: call _my_thread_var mov eax, [rax] mov [rbp+var_4], eax loc_37F1A: mov eax, [rbp+var_4] add rsp, 50h pop rbp retn
long long maria_rnext(long long a1, const char *a2, unsigned int a3) { long long v3; // rsi bool v6; // [rsp+7h] [rbp-49h] int v7; // [rsp+10h] [rbp-40h] int v8; // [rsp+14h] [rbp-3Ch] long long v9; // [rsp+18h] [rbp-38h] long long v10; // [rsp+20h] [rbp-30h] int v11; // [rsp+28h] [rbp-28h] int v12; // [rsp+2Ch] [rbp-24h] int next; // [rsp+30h] [rbp-20h] unsigned int v14; // [rsp+34h] [rbp-1Ch] long long v16; // [rsp+40h] [rbp-10h] v16 = a1; v10 = *(_QWORD *)a1; v8 = 1; v7 = 16; v3 = a3; v14 = ma_check_index(a1, a3); if ( (v14 & 0x80000000) != 0 ) return *(unsigned int *)my_thread_var(a1, (const char *)v3); v11 = 8; if ( *(_QWORD *)(a1 + 152) == -1LL && (*(_DWORD *)(a1 + 1572) & 0x20) != 0 ) v11 = 0; if ( *(_DWORD *)(a1 + 1636) == 2 ) { v3 = 0LL; if ( (unsigned int)ma_readinfo(a1, 0LL) ) return *(unsigned int *)my_thread_var(a1, (const char *)v3); } v9 = 280LL * (int)v14 + *(_QWORD *)(v10 + 1392); if ( *(_BYTE *)(v10 + 2019) ) inline_mysql_rwlock_rdlock_0(v9 + 8, "/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_rnext.c", 48LL); v12 = ma_test_if_changed(a1); if ( v11 ) { if ( *(_BYTE *)(v9 + 164) == 2 ) { v3 = v14; next = maria_rtree_get_next(a1, v14, (unsigned int)(*(_DWORD *)(a1 + 532) + *(_DWORD *)(a1 + 528))); } else { v3 = a1 + 512; if ( v12 ) next = ma_search( a1, a1 + 512, *(_DWORD *)(a1 + 536) | (unsigned int)v11, *(_QWORD *)(*(_QWORD *)(v10 + 280) + 8LL * (int)v14)); else next = ma_search_next( a1, a1 + 512, *(_DWORD *)(a1 + 536) | (unsigned int)v11, *(_QWORD *)(*(_QWORD *)(v10 + 280) + 8LL * (int)v14)); } } else { if ( *(_BYTE *)(v9 + 164) == 2 ) { v3 = v14; next = maria_rtree_get_first(a1, v14, (unsigned int)(*(_DWORD *)(a1 + 532) + *(_DWORD *)(a1 + 528))); } else { v3 = v9; next = ma_search_first(a1, v9, *(_QWORD *)(*(_QWORD *)(v10 + 280) + 8LL * (int)v14)); } if ( next ) v7 = 48; } for ( ; !next; next = ma_search_next(v16, v16 + 512, 8LL, *(_QWORD *)(*(_QWORD *)(v10 + 280) + 8LL * (int)v14)) ) { a1 = v16; v6 = 1; if ( (*(unsigned __int8 ( **)(long long))(v10 + 1752))(v16) ) { a1 = v16; v3 = v14; v8 = ma_check_index_cond(v16, v14, a2); v6 = v8 == 0; } if ( !v6 ) break; if ( *(_QWORD *)(v16 + 944) >= *(_QWORD *)(v16 + 952) ) { a1 = v16; v3 = v14; if ( ma_yield_and_check_if_killed((_QWORD *)v16, (const char *)v14) ) { next = 1; break; } } a1 = v16; v3 = v16 + 512; } if ( *(_BYTE *)(v10 + 2019) ) { a1 = v9 + 8; inline_mysql_rwlock_unlock_0(v9 + 8); } *(_DWORD *)(v16 + 1572) &= 0x401u; *(_DWORD *)(v16 + 1572) |= v7; if ( next || v8 != 1 ) { if ( !*(_DWORD *)(*(_QWORD *)v16 + 1976LL) ) { a1 = v16; v3 = 0LL; ma_writeinfo(v16, 0LL); } if ( *(_DWORD *)my_thread_var(a1, (const char *)v3) == 120 ) *(_DWORD *)my_thread_var(a1, (const char *)v3) = 137; return *(unsigned int *)my_thread_var(a1, (const char *)v3); } if ( a2 ) { a1 = v16; v3 = (long long)a2; if ( (*(unsigned int ( **)(long long, const char *, _QWORD))(v16 + 984))(v16, a2, *(_QWORD *)(v16 + 152)) ) return *(unsigned int *)my_thread_var(a1, (const char *)v3); *(_DWORD *)(v16 + 1572) |= 2u; return 0; } else { if ( !*(_DWORD *)(*(_QWORD *)v16 + 1976LL) ) { a1 = v16; v3 = 0LL; ma_writeinfo(v16, 0LL); } if ( *(_QWORD *)(v16 + 152) == -1LL ) return *(unsigned int *)my_thread_var(a1, (const char *)v3); else return 0; } }
maria_rnext: PUSH RBP MOV RBP,RSP SUB RSP,0x50 MOV qword ptr [RBP + -0x10],RDI MOV qword ptr [RBP + -0x18],RSI MOV dword ptr [RBP + -0x1c],EDX MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX] MOV qword ptr [RBP + -0x30],RAX MOV dword ptr [RBP + -0x3c],0x1 MOV dword ptr [RBP + -0x40],0x10 MOV RDI,qword ptr [RBP + -0x10] MOV ESI,dword ptr [RBP + -0x1c] CALL 0x001384b0 MOV dword ptr [RBP + -0x1c],EAX CMP EAX,0x0 JGE 0x00137b41 JMP 0x00137b32 LAB_00137b32: CALL 0x001fa320 MOV EAX,dword ptr [RAX] MOV dword ptr [RBP + -0x4],EAX JMP 0x00137f1a LAB_00137b41: MOV dword ptr [RBP + -0x28],0x8 MOV RAX,qword ptr [RBP + -0x10] CMP qword ptr [RAX + 0x98],-0x1 JNZ 0x00137b6f MOV RAX,qword ptr [RBP + -0x10] MOV EAX,dword ptr [RAX + 0x624] AND EAX,0x20 CMP EAX,0x0 JZ 0x00137b6f MOV dword ptr [RBP + -0x28],0x0 LAB_00137b6f: MOV RAX,qword ptr [RBP + -0x10] CMP dword ptr [RAX + 0x664],0x2 JNZ 0x00137ba2 MOV RDI,qword ptr [RBP + -0x10] XOR ESI,ESI MOV EDX,0x1 CALL 0x001441c0 CMP EAX,0x0 JZ 0x00137ba2 JMP 0x00137b93 LAB_00137b93: CALL 0x001fa320 MOV EAX,dword ptr [RAX] MOV dword ptr [RBP + -0x4],EAX JMP 0x00137f1a LAB_00137ba2: MOV RAX,qword ptr [RBP + -0x30] MOV RAX,qword ptr [RAX + 0x570] MOVSXD RCX,dword ptr [RBP + -0x1c] IMUL RCX,RCX,0x118 ADD RAX,RCX MOV qword ptr [RBP + -0x38],RAX MOV RAX,qword ptr [RBP + -0x30] CMP byte ptr [RAX + 0x7e3],0x0 JZ 0x00137be5 MOV RDI,qword ptr [RBP + -0x38] ADD RDI,0x8 LEA RSI,[0x2545d5] MOV EDX,0x30 CALL 0x00137f30 LAB_00137be5: MOV RDI,qword ptr [RBP + -0x10] CALL 0x00144110 MOV dword ptr [RBP + -0x24],EAX CMP dword ptr [RBP + -0x28],0x0 JNZ 0x00137c74 MOV RAX,qword ptr [RBP + -0x38] MOVZX EAX,byte ptr [RAX + 0xa4] MOV dword ptr [RBP + -0x44],EAX SUB EAX,0x1 JZ 0x00137c3b JMP 0x00137c0c LAB_00137c0c: MOV EAX,dword ptr [RBP + -0x44] SUB EAX,0x2 JNZ 0x00137c3d JMP 0x00137c16 LAB_00137c16: MOV RDI,qword ptr [RBP + -0x10] MOV ESI,dword ptr [RBP + -0x1c] MOV RAX,qword ptr [RBP + -0x10] MOV EDX,dword ptr [RAX + 0x210] MOV RAX,qword ptr [RBP + -0x10] ADD EDX,dword ptr [RAX + 0x214] CALL 0x00178450 MOV dword ptr [RBP + -0x20],EAX JMP 0x00137c60 LAB_00137c3b: JMP 0x00137c3d LAB_00137c3d: MOV RDI,qword ptr [RBP + -0x10] MOV RSI,qword ptr [RBP + -0x38] MOV RAX,qword ptr [RBP + -0x30] MOV RAX,qword ptr [RAX + 0x118] MOVSXD RCX,dword ptr [RBP + -0x1c] MOV RDX,qword ptr [RAX + RCX*0x8] CALL 0x0013c6e0 MOV dword ptr [RBP + -0x20],EAX LAB_00137c60: CMP dword ptr [RBP + -0x20],0x0 JZ 0x00137c6f MOV EAX,dword ptr [RBP + -0x40] OR EAX,0x20 MOV dword ptr [RBP + -0x40],EAX LAB_00137c6f: JMP 0x00137d34 LAB_00137c74: MOV RAX,qword ptr [RBP + -0x38] MOVZX EAX,byte ptr [RAX + 0xa4] MOV dword ptr [RBP + -0x48],EAX SUB EAX,0x1 JZ 0x00137cb8 JMP 0x00137c89 LAB_00137c89: MOV EAX,dword ptr [RBP + -0x48] SUB EAX,0x2 JNZ 0x00137cba JMP 0x00137c93 LAB_00137c93: MOV RDI,qword ptr [RBP + -0x10] MOV ESI,dword ptr [RBP + -0x1c] MOV RAX,qword ptr [RBP + -0x10] MOV EDX,dword ptr [RAX + 0x210] MOV RAX,qword ptr [RBP + -0x10] ADD EDX,dword ptr [RAX + 0x214] CALL 0x00178a20 MOV dword ptr [RBP + -0x20],EAX JMP 0x00137d32 LAB_00137cb8: JMP 0x00137cba LAB_00137cba: CMP dword ptr [RBP + -0x24],0x0 JNZ 0x00137cf9 MOV RDI,qword ptr [RBP + -0x10] MOV RSI,qword ptr [RBP + -0x10] ADD RSI,0x200 MOV EDX,dword ptr [RBP + -0x28] MOV RAX,qword ptr [RBP + -0x10] OR EDX,dword ptr [RAX + 0x218] MOV RAX,qword ptr [RBP + -0x30] MOV RAX,qword ptr [RAX + 0x118] MOVSXD RCX,dword ptr [RBP + -0x1c] MOV RCX,qword ptr [RAX + RCX*0x8] CALL 0x0013c1e0 MOV dword ptr [RBP + -0x20],EAX JMP 0x00137d30 LAB_00137cf9: MOV RDI,qword ptr [RBP + -0x10] MOV RSI,qword ptr [RBP + -0x10] ADD RSI,0x200 MOV EDX,dword ptr [RBP + -0x28] MOV RAX,qword ptr [RBP + -0x10] OR EDX,dword ptr [RAX + 0x218] MOV RAX,qword ptr [RBP + -0x30] MOV RAX,qword ptr [RAX + 0x118] MOVSXD RCX,dword ptr [RBP + -0x1c] MOV RCX,qword ptr [RAX + RCX*0x8] CALL 0x00138640 MOV dword ptr [RBP + -0x20],EAX LAB_00137d30: JMP 0x00137d32 LAB_00137d32: JMP 0x00137d34 LAB_00137d34: CMP dword ptr [RBP + -0x20],0x0 JNZ 0x00137df4 JMP 0x00137d40 LAB_00137d40: MOV RAX,qword ptr [RBP + -0x30] MOV RAX,qword ptr [RAX + 0x6d8] MOV RDI,qword ptr [RBP + -0x10] CALL RAX MOV CL,AL MOV AL,0x1 CMP CL,0x0 MOV byte ptr [RBP + -0x49],AL JZ 0x00137d79 MOV RDI,qword ptr [RBP + -0x10] MOV ESI,dword ptr [RBP + -0x1c] MOV RDX,qword ptr [RBP + -0x18] CALL 0x00143710 MOV dword ptr [RBP + -0x3c],EAX CMP EAX,0x0 SETZ AL MOV byte ptr [RBP + -0x49],AL LAB_00137d79: MOV AL,byte ptr [RBP + -0x49] TEST AL,0x1 JNZ 0x00137d82 JMP 0x00137df2 LAB_00137d82: MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x3b0] MOV RCX,qword ptr [RBP + -0x10] CMP RAX,qword ptr [RCX + 0x3b8] JC 0x00137db7 MOV RDI,qword ptr [RBP + -0x10] MOV ESI,dword ptr [RBP + -0x1c] CALL 0x001379c0 MOVSX EAX,AL CMP EAX,0x0 JZ 0x00137db7 MOV dword ptr [RBP + -0x20],0x1 JMP 0x00137df2 LAB_00137db7: MOV RDI,qword ptr [RBP + -0x10] MOV RSI,qword ptr [RBP + -0x10] ADD RSI,0x200 MOV RAX,qword ptr [RBP + -0x30] MOV RAX,qword ptr [RAX + 0x118] MOVSXD RCX,dword ptr [RBP + -0x1c] MOV RCX,qword ptr [RAX + RCX*0x8] MOV EDX,0x8 CALL 0x0013c1e0 MOV dword ptr [RBP + -0x20],EAX CMP EAX,0x0 JZ 0x00137ded JMP 0x00137df2 LAB_00137ded: JMP 0x00137d40 LAB_00137df2: JMP 0x00137df4 LAB_00137df4: MOV RAX,qword ptr [RBP + -0x30] CMP byte ptr [RAX + 0x7e3],0x0 JZ 0x00137e0e MOV RDI,qword ptr [RBP + -0x38] ADD RDI,0x8 CALL 0x00137fa0 LAB_00137e0e: MOV RAX,qword ptr [RBP + -0x10] MOV ECX,dword ptr [RAX + 0x624] AND ECX,0x401 MOV dword ptr [RAX + 0x624],ECX MOV ECX,dword ptr [RBP + -0x40] MOV RAX,qword ptr [RBP + -0x10] OR ECX,dword ptr [RAX + 0x624] MOV dword ptr [RAX + 0x624],ECX CMP dword ptr [RBP + -0x20],0x0 JNZ 0x00137e43 CMP dword ptr [RBP + -0x3c],0x1 JZ 0x00137e78 LAB_00137e43: MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX] CMP dword ptr [RAX + 0x7b8],0x0 JNZ 0x00137e5e MOV RDI,qword ptr [RBP + -0x10] XOR ESI,ESI CALL 0x001441e0 LAB_00137e5e: CALL 0x001fa320 CMP dword ptr [RAX],0x78 JNZ 0x00137e73 CALL 0x001fa320 MOV dword ptr [RAX],0x89 LAB_00137e73: JMP 0x00137f0a LAB_00137e78: CMP qword ptr [RBP + -0x18],0x0 JNZ 0x00137ec5 MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX] CMP dword ptr [RAX + 0x7b8],0x0 JNZ 0x00137e9a MOV RDI,qword ptr [RBP + -0x10] XOR ESI,ESI CALL 0x001441e0 LAB_00137e9a: JMP 0x00137e9c LAB_00137e9c: MOV RAX,qword ptr [RBP + -0x10] CMP qword ptr [RAX + 0x98],-0x1 JNZ 0x00137eb6 CALL 0x001fa320 MOV EAX,dword ptr [RAX] MOV dword ptr [RBP + -0x50],EAX JMP 0x00137ebd LAB_00137eb6: XOR EAX,EAX MOV dword ptr [RBP + -0x50],EAX JMP 0x00137ebd LAB_00137ebd: MOV EAX,dword ptr [RBP + -0x50] MOV dword ptr [RBP + -0x4],EAX JMP 0x00137f1a LAB_00137ec5: MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x3d8] MOV RDI,qword ptr [RBP + -0x10] MOV RSI,qword ptr [RBP + -0x18] MOV RCX,qword ptr [RBP + -0x10] MOV RDX,qword ptr [RCX + 0x98] CALL RAX CMP EAX,0x0 JNZ 0x00137f06 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 0x00137f1a LAB_00137f06: JMP 0x00137f08 LAB_00137f08: JMP 0x00137f0a LAB_00137f0a: JMP 0x00137f0c LAB_00137f0c: JMP 0x00137f0e LAB_00137f0e: JMP 0x00137f10 LAB_00137f10: CALL 0x001fa320 MOV EAX,dword ptr [RAX] MOV dword ptr [RBP + -0x4],EAX LAB_00137f1a: MOV EAX,dword ptr [RBP + -0x4] ADD RSP,0x50 POP RBP RET
int4 maria_rnext(long *param_1,long param_2,int4 param_3) { long lVar1; char cVar2; int iVar3; int iVar4; int4 *puVar5; long lVar6; int *piVar7; bool bVar8; int4 local_58; uint local_48; int local_44; uint local_30; int local_28; int4 local_c; lVar1 = *param_1; local_44 = 1; local_48 = 0x10; iVar3 = _ma_check_index(param_1,param_3); if (iVar3 < 0) { puVar5 = (int4 *)_my_thread_var(); local_c = *puVar5; } else { local_30 = 8; if ((param_1[0x13] == -1) && ((*(uint *)((long)param_1 + 0x624) & 0x20) != 0)) { local_30 = 0; } if ((*(int *)((long)param_1 + 0x664) == 2) && (iVar4 = _ma_readinfo(param_1,0,1), iVar4 != 0)) { puVar5 = (int4 *)_my_thread_var(); local_c = *puVar5; } else { lVar6 = *(long *)(lVar1 + 0x570) + (long)iVar3 * 0x118; if (*(char *)(lVar1 + 0x7e3) != '\0') { inline_mysql_rwlock_rdlock (lVar6 + 8,"/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_rnext.c", 0x30); } iVar4 = _ma_test_if_changed(param_1); if (local_30 == 0) { if ((*(char *)(lVar6 + 0xa4) == '\x01') || (*(char *)(lVar6 + 0xa4) != '\x02')) { local_28 = _ma_search_first(param_1,lVar6, *(int8 *)(*(long *)(lVar1 + 0x118) + (long)iVar3 * 8)); } else { local_28 = maria_rtree_get_first (param_1,iVar3,(int)param_1[0x42] + *(int *)((long)param_1 + 0x214)); } if (local_28 != 0) { local_48 = 0x30; } } else if ((*(char *)(lVar6 + 0xa4) == '\x01') || (*(char *)(lVar6 + 0xa4) != '\x02')) { if (iVar4 == 0) { local_28 = _ma_search_next(param_1,param_1 + 0x40,local_30 | *(uint *)(param_1 + 0x43), *(int8 *)(*(long *)(lVar1 + 0x118) + (long)iVar3 * 8)); } else { local_28 = _ma_search(param_1,param_1 + 0x40,local_30 | *(uint *)(param_1 + 0x43), *(int8 *)(*(long *)(lVar1 + 0x118) + (long)iVar3 * 8)); } } else { local_28 = maria_rtree_get_next (param_1,iVar3,(int)param_1[0x42] + *(int *)((long)param_1 + 0x214)); } while (local_28 == 0) { cVar2 = (**(code **)(lVar1 + 0x6d8))(param_1); bVar8 = true; if (cVar2 != '\0') { local_44 = ma_check_index_cond(param_1,iVar3,param_2); bVar8 = local_44 == 0; } if (!bVar8) break; if (((ulong)param_1[0x77] <= (ulong)param_1[0x76]) && (cVar2 = ma_yield_and_check_if_killed(param_1,iVar3), cVar2 != '\0')) { local_28 = 1; break; } local_28 = _ma_search_next(param_1,param_1 + 0x40,8, *(int8 *)(*(long *)(lVar1 + 0x118) + (long)iVar3 * 8)); } if (*(char *)(lVar1 + 0x7e3) != '\0') { inline_mysql_rwlock_unlock(lVar6 + 8); } *(uint *)((long)param_1 + 0x624) = *(uint *)((long)param_1 + 0x624) & 0x401; *(uint *)((long)param_1 + 0x624) = local_48 | *(uint *)((long)param_1 + 0x624); if ((local_28 == 0) && (local_44 == 1)) { if (param_2 == 0) { if (*(int *)(*param_1 + 0x7b8) == 0) { _ma_writeinfo(param_1,0); } if (param_1[0x13] == -1) { puVar5 = (int4 *)_my_thread_var(); local_58 = *puVar5; } else { local_58 = 0; } return local_58; } iVar3 = (*(code *)param_1[0x7b])(param_1,param_2,param_1[0x13]); if (iVar3 == 0) { *(uint *)((long)param_1 + 0x624) = *(uint *)((long)param_1 + 0x624) | 2; return 0; } } else { if (*(int *)(*param_1 + 0x7b8) == 0) { _ma_writeinfo(param_1,0); } piVar7 = (int *)_my_thread_var(); if (*piVar7 == 0x78) { puVar5 = (int4 *)_my_thread_var(); *puVar5 = 0x89; } } puVar5 = (int4 *)_my_thread_var(); local_c = *puVar5; } } return local_c; }
31,803
maria_rnext
eloqsql/storage/maria/ma_rnext.c
int maria_rnext(MARIA_HA *info, uchar *buf, int inx) { int error,changed; uint flag; MARIA_SHARE *share= info->s; MARIA_KEYDEF *keyinfo; check_result_t check= CHECK_POS; uint update_mask= HA_STATE_NEXT_FOUND; DBUG_ENTER("maria_rnext"); if ((inx = _ma_check_index(info,inx)) < 0) DBUG_RETURN(my_errno); flag=SEARCH_BIGGER; /* Read next */ if (info->cur_row.lastpos == HA_OFFSET_ERROR && info->update & HA_STATE_PREV_FOUND) flag=0; /* Read first */ if (fast_ma_readinfo(info)) DBUG_RETURN(my_errno); keyinfo= share->keyinfo + inx; if (share->lock_key_trees) mysql_rwlock_rdlock(&keyinfo->root_lock); changed= _ma_test_if_changed(info); if (!flag) { switch (keyinfo->key_alg){ #ifdef HAVE_RTREE_KEYS case HA_KEY_ALG_RTREE: error=maria_rtree_get_first(info, inx, info->last_key.data_length + info->last_key.ref_length); break; #endif case HA_KEY_ALG_BTREE: default: error= _ma_search_first(info, keyinfo, share->state.key_root[inx]); break; } /* "search first" failed. This means we have no pivot for "search next", or in other words MI_INFO::lastkey is likely uninitialized. Normally SQL layer would never request "search next" if "search first" failed. But HANDLER may do anything. As mi_rnext() without preceding mi_rkey()/mi_rfirst() equals to mi_rfirst(), we must restore original state as if failing mi_rfirst() was not called. */ if (error) update_mask|= HA_STATE_PREV_FOUND; } else { switch (keyinfo->key_alg) { #ifdef HAVE_RTREE_KEYS case HA_KEY_ALG_RTREE: /* Note that rtree doesn't support that the table may be changed since last call, so we do need to skip rows inserted by other threads like in btree */ error= maria_rtree_get_next(info, inx, info->last_key.data_length + info->last_key.ref_length); break; #endif case HA_KEY_ALG_BTREE: default: if (!changed) error= _ma_search_next(info, &info->last_key, flag | info->last_key.flag, share->state.key_root[inx]); else error= _ma_search(info, &info->last_key, flag | info->last_key.flag, share->state.key_root[inx]); } } if (!error) { while (!(*share->row_is_visible)(info) || ((check= ma_check_index_cond(info, inx, buf)) == CHECK_NEG)) { /* If we are at the last key on the key page, allow writers to access the index. */ if (info->int_keypos >= info->int_maxpos && ma_yield_and_check_if_killed(info, inx)) { /* my_errno is set by ma_yield_and_check_if_killed() */ error= 1; break; } /* Skip rows inserted by other threads since we got a lock */ if ((error= _ma_search_next(info, &info->last_key, SEARCH_BIGGER, share->state.key_root[inx]))) break; } } if (share->lock_key_trees) mysql_rwlock_unlock(&keyinfo->root_lock); /* Don't clear if database-changed */ info->update&= (HA_STATE_CHANGED | HA_STATE_ROW_CHANGED); info->update|= update_mask; if (error || check != CHECK_POS) { fast_ma_writeinfo(info); if (my_errno == HA_ERR_KEY_NOT_FOUND) my_errno= HA_ERR_END_OF_FILE; } else if (!buf) { fast_ma_writeinfo(info); DBUG_RETURN(info->cur_row.lastpos == HA_OFFSET_ERROR ? my_errno : 0); } else if (!(*info->read_record)(info, buf, info->cur_row.lastpos)) { info->update|= HA_STATE_AKTIV; /* Record is read */ DBUG_RETURN(0); } DBUG_PRINT("error",("Got error: %d, errno: %d",error, my_errno)); DBUG_RETURN(my_errno); }
O3
c
maria_rnext: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x28, %rsp movq %rsi, %r15 movq %rdi, %rbx movq (%rdi), %r14 movl %edx, %esi callq 0x37fd0 testl %eax, %eax js 0x37c6c movl %eax, %r12d movq %r15, -0x48(%rbp) cmpq $-0x1, 0x98(%rbx) je 0x379ed movl $0x8, %r13d xorl %r15d, %r15d jmp 0x37a07 movl 0x624(%rbx), %r13d andl $0x20, %r13d movl %r13d, %r15d shrl $0x5, %r15d shrl $0x2, %r13d xorl $0x8, %r13d cmpl $0x2, 0x664(%rbx) jne 0x37a27 movq %rbx, %rdi xorl %esi, %esi movl $0x1, %edx callq 0x3e412 testl %eax, %eax jne 0x37c6c movl %r15d, -0x3c(%rbp) movl %r12d, %ecx movq %rcx, -0x38(%rbp) imulq $0x118, %rcx, %r15 # imm = 0x118 addq 0x570(%r14), %r15 cmpb $0x0, 0x7e3(%r14) movq %r15, -0x30(%rbp) je 0x37a69 leaq 0x8(%r15), %rdi cmpq $0x0, 0x98(%r15) jne 0x37c82 callq 0xa7348 movq -0x30(%rbp), %r15 movq %rbx, %rdi callq 0x3e3f9 movb 0xa4(%r15), %cl cmpb $0x0, -0x3c(%rbp) je 0x37a9c cmpb $0x2, %cl jne 0x37aba movl 0x214(%rbx), %edx addl 0x210(%rbx), %edx movq %rbx, %rdi movl %r12d, %esi callq 0x5ebc6 jmp 0x37ad4 cmpb $0x2, %cl jne 0x37ae6 movl 0x214(%rbx), %edx addl 0x210(%rbx), %edx movq %rbx, %rdi movl %r12d, %esi callq 0x5ef49 jmp 0x37b19 movq 0x118(%r14), %rax movq -0x38(%rbp), %rcx movq (%rax,%rcx,8), %rdx movq %rbx, %rdi movq %r15, %rsi callq 0x3a2af testl %eax, %eax je 0x37b25 movb $0x1, %r15b movl $0x30, %r12d jmp 0x37bb2 orl 0x218(%rbx), %r13d leaq 0x200(%rbx), %rsi movq 0x118(%r14), %rcx movq -0x38(%rbp), %rdx movq (%rcx,%rdx,8), %rcx movq %rbx, %rdi movl %r13d, %edx testl %eax, %eax je 0x37b14 callq 0x380b3 jmp 0x37b19 callq 0x39fdf testl %eax, %eax je 0x37b25 movb $0x1, %r15b jmp 0x37bac leaq 0x200(%rbx), %r13 movl $0x1, %r15d movq %rbx, %rdi callq *0x6d8(%r14) testb %al, %al je 0x37b56 movq %rbx, %rdi movl %r12d, %esi movq -0x48(%rbp), %rdx callq 0x3de83 xorl %r15d, %r15d testl %eax, %eax jne 0x37b9c movq 0x3b0(%rbx), %rax cmpq 0x3b8(%rbx), %rax jb 0x37b75 movq %rbx, %rdi movl %r12d, %esi callq 0x378e7 testb %al, %al jne 0x37b98 movq 0x118(%r14), %rax movq -0x38(%rbp), %rcx movq (%rax,%rcx,8), %rcx movq %rbx, %rdi movq %r13, %rsi movl $0x8, %edx callq 0x39fdf testl %eax, %eax je 0x37b32 movb $0x1, %cl jmp 0x37ba1 xorl %ecx, %ecx movl %eax, %r15d cmpl $0x1, %r15d setne %r15b orb %cl, %r15b movl $0x10, %r12d movq -0x30(%rbp), %rcx cmpb $0x0, 0x7e3(%r14) je 0x37bdc movq 0x98(%rcx), %rdi addq $0x8, %rcx testq %rdi, %rdi jne 0x37c98 movq %rcx, %rdi callq 0xa7476 movl $0x401, %eax # imm = 0x401 andl 0x624(%rbx), %eax orl %r12d, %eax movl %eax, 0x624(%rbx) testb %r15b, %r15b je 0x37c22 movq (%rbx), %rax cmpl $0x0, 0x7b8(%rax) jne 0x37c0b movq %rbx, %rdi xorl %esi, %esi callq 0x3e41a callq 0xa4ab2 cmpl $0x78, (%rax) jne 0x37c6c callq 0xa4ab2 movl $0x89, (%rax) jmp 0x37c6c movq -0x48(%rbp), %rsi testq %rsi, %rsi je 0x37c4a movq 0x98(%rbx), %rdx movq %rbx, %rdi callq *0x3d8(%rbx) testl %eax, %eax jne 0x37c6c orb $0x2, 0x624(%rbx) xorl %eax, %eax jmp 0x37c73 movq (%rbx), %rax cmpl $0x0, 0x7b8(%rax) jne 0x37c60 movq %rbx, %rdi xorl %esi, %esi callq 0x3e41a xorl %eax, %eax cmpq $-0x1, 0x98(%rbx) jne 0x37c73 callq 0xa4ab2 movl (%rax), %eax addq $0x28, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq leaq 0xa394c(%rip), %rsi # 0xdb5d5 movl $0x30, %edx callq 0x2eecc jmp 0x37a65 leaq 0x3513b1(%rip), %rax # 0x389050 movq (%rax), %rax movq %rcx, %r14 callq *0x168(%rax) movq %r14, %rcx jmp 0x37bd4 nop
maria_rnext: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx sub rsp, 28h mov r15, rsi mov rbx, rdi mov r14, [rdi] mov esi, edx call _ma_check_index test eax, eax js loc_37C6C mov r12d, eax mov [rbp+var_48], r15 cmp qword ptr [rbx+98h], 0FFFFFFFFFFFFFFFFh jz short loc_379ED mov r13d, 8 xor r15d, r15d jmp short loc_37A07 loc_379ED: mov r13d, [rbx+624h] and r13d, 20h mov r15d, r13d shr r15d, 5 shr r13d, 2 xor r13d, 8 loc_37A07: cmp dword ptr [rbx+664h], 2 jnz short loc_37A27 mov rdi, rbx xor esi, esi mov edx, 1 call _ma_readinfo test eax, eax jnz loc_37C6C loc_37A27: mov [rbp+var_3C], r15d mov ecx, r12d mov [rbp+var_38], rcx imul r15, rcx, 118h add r15, [r14+570h] cmp byte ptr [r14+7E3h], 0 mov [rbp+var_30], r15 jz short loc_37A69 lea rdi, [r15+8] cmp qword ptr [r15+98h], 0 jnz loc_37C82 call my_rw_rdlock loc_37A65: mov r15, [rbp+var_30] loc_37A69: mov rdi, rbx call _ma_test_if_changed mov cl, [r15+0A4h] cmp byte ptr [rbp+var_3C], 0 jz short loc_37A9C cmp cl, 2 jnz short loc_37ABA mov edx, [rbx+214h] add edx, [rbx+210h] mov rdi, rbx mov esi, r12d call maria_rtree_get_first jmp short loc_37AD4 loc_37A9C: cmp cl, 2 jnz short loc_37AE6 mov edx, [rbx+214h] add edx, [rbx+210h] mov rdi, rbx mov esi, r12d call maria_rtree_get_next jmp short loc_37B19 loc_37ABA: mov rax, [r14+118h] mov rcx, [rbp+var_38] mov rdx, [rax+rcx*8] mov rdi, rbx mov rsi, r15 call _ma_search_first loc_37AD4: test eax, eax jz short loc_37B25 mov r15b, 1 mov r12d, 30h ; '0' jmp loc_37BB2 loc_37AE6: or r13d, [rbx+218h] lea rsi, [rbx+200h] mov rcx, [r14+118h] mov rdx, [rbp+var_38] mov rcx, [rcx+rdx*8] mov rdi, rbx mov edx, r13d test eax, eax jz short loc_37B14 call _ma_search jmp short loc_37B19 loc_37B14: call _ma_search_next loc_37B19: test eax, eax jz short loc_37B25 mov r15b, 1 jmp loc_37BAC loc_37B25: lea r13, [rbx+200h] mov r15d, 1 loc_37B32: mov rdi, rbx call qword ptr [r14+6D8h] test al, al jz short loc_37B56 mov rdi, rbx mov esi, r12d mov rdx, [rbp+var_48] call ma_check_index_cond xor r15d, r15d test eax, eax jnz short loc_37B9C loc_37B56: mov rax, [rbx+3B0h] cmp rax, [rbx+3B8h] jb short loc_37B75 mov rdi, rbx mov esi, r12d call ma_yield_and_check_if_killed test al, al jnz short loc_37B98 loc_37B75: mov rax, [r14+118h] mov rcx, [rbp+var_38] mov rcx, [rax+rcx*8] mov rdi, rbx mov rsi, r13 mov edx, 8 call _ma_search_next test eax, eax jz short loc_37B32 loc_37B98: mov cl, 1 jmp short loc_37BA1 loc_37B9C: xor ecx, ecx mov r15d, eax loc_37BA1: cmp r15d, 1 setnz r15b or r15b, cl loc_37BAC: mov r12d, 10h loc_37BB2: mov rcx, [rbp+var_30] cmp byte ptr [r14+7E3h], 0 jz short loc_37BDC mov rdi, [rcx+98h] add rcx, 8 test rdi, rdi jnz loc_37C98 loc_37BD4: mov rdi, rcx call my_rw_unlock loc_37BDC: mov eax, 401h and eax, [rbx+624h] or eax, r12d mov [rbx+624h], eax test r15b, r15b jz short loc_37C22 mov rax, [rbx] cmp dword ptr [rax+7B8h], 0 jnz short loc_37C0B mov rdi, rbx xor esi, esi call _ma_writeinfo loc_37C0B: call _my_thread_var cmp dword ptr [rax], 78h ; 'x' jnz short loc_37C6C call _my_thread_var mov dword ptr [rax], 89h jmp short loc_37C6C loc_37C22: mov rsi, [rbp+var_48] test rsi, rsi jz short loc_37C4A mov rdx, [rbx+98h] mov rdi, rbx call qword ptr [rbx+3D8h] test eax, eax jnz short loc_37C6C or byte ptr [rbx+624h], 2 xor eax, eax jmp short loc_37C73 loc_37C4A: mov rax, [rbx] cmp dword ptr [rax+7B8h], 0 jnz short loc_37C60 mov rdi, rbx xor esi, esi call _ma_writeinfo loc_37C60: xor eax, eax cmp qword ptr [rbx+98h], 0FFFFFFFFFFFFFFFFh jnz short loc_37C73 loc_37C6C: call _my_thread_var mov eax, [rax] loc_37C73: add rsp, 28h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn loc_37C82: lea rsi, aWorkspaceLlm4b_29; "/workspace/llm4binary/github2025/eloqsq"... mov edx, 30h ; '0' call psi_rwlock_rdlock jmp loc_37A65 loc_37C98: lea rax, PSI_server mov rax, [rax] mov r14, rcx call qword ptr [rax+168h] mov rcx, r14 jmp loc_37BD4
long long maria_rnext(long long *a1, long long a2, unsigned int a3) { long long *v3; // rbx long long v4; // r14 int v5; // eax unsigned int v6; // r12d unsigned int v7; // r13d unsigned int v8; // r15d long long v9; // r15 long long v10; // rdi int v11; // eax char v12; // cl int first; // eax int next; // eax char v15; // r15 int v16; // r12d long long *v17; // rsi long long v18; // rcx long long v19; // rdx int v20; // r15d int v21; // eax char v22; // cl long long v23; // rcx long long v24; // rcx long long result; // rax char v27; // [rsp+14h] [rbp-3Ch] long long v28; // [rsp+20h] [rbp-30h] v3 = a1; v4 = *a1; v5 = ma_check_index(a1, a3); if ( v5 < 0 ) return *(unsigned int *)my_thread_var(a1); v6 = v5; if ( a1[19] == -1 ) { v8 = (*((_DWORD *)a1 + 393) & 0x20u) >> 5; v7 = ((*((_DWORD *)a1 + 393) & 0x20u) >> 2) ^ 8; } else { v7 = 8; LOBYTE(v8) = 0; } if ( *((_DWORD *)a1 + 409) == 2 && (unsigned int)ma_readinfo(a1, 0LL, 1LL) ) return *(unsigned int *)my_thread_var(a1); v27 = v8; v9 = *(_QWORD *)(v4 + 1392) + 280LL * v6; v28 = v9; if ( *(_BYTE *)(v4 + 2019) ) { v10 = v9 + 8; if ( *(_QWORD *)(v9 + 152) ) psi_rwlock_rdlock(v10, (long long)"/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_rnext.c", 0x30u); else my_rw_rdlock(v10); } v11 = ma_test_if_changed(v3); v12 = *(_BYTE *)(v9 + 164); if ( v27 ) { a1 = v3; if ( v12 == 2 ) first = maria_rtree_get_first(v3, v6, (unsigned int)(*((_DWORD *)v3 + 132) + *((_DWORD *)v3 + 133))); else first = ma_search_first(v3, v9, *(_QWORD *)(*(_QWORD *)(v4 + 280) + 8LL * v6)); if ( first ) { v15 = 1; v16 = 48; goto LABEL_33; } goto LABEL_23; } if ( v12 == 2 ) { a1 = v3; next = maria_rtree_get_next(v3, v6, (unsigned int)(*((_DWORD *)v3 + 132) + *((_DWORD *)v3 + 133))); } else { v17 = v3 + 64; v18 = *(_QWORD *)(*(_QWORD *)(v4 + 280) + 8LL * v6); a1 = v3; v19 = *((_DWORD *)v3 + 134) | v7; if ( v11 ) next = ma_search(v3, v17, v19, v18); else next = ma_search_next(v3, v17, v19, v18); } if ( !next ) { LABEL_23: v20 = 1; while ( 1 ) { if ( (*(unsigned __int8 ( **)(long long *))(v4 + 1752))(v3) ) { a1 = v3; v21 = ma_check_index_cond(v3, v6, a2); v20 = 0; if ( v21 ) break; } if ( v3[118] < (unsigned long long)v3[119] || (a1 = v3, !ma_yield_and_check_if_killed(v3, v6)) ) { a1 = v3; if ( !(unsigned int)ma_search_next(v3, v3 + 64, 8LL, *(_QWORD *)(*(_QWORD *)(v4 + 280) + 8LL * v6)) ) continue; } v22 = 1; goto LABEL_31; } v22 = 0; v20 = v21; LABEL_31: v15 = v22 | (v20 != 1); goto LABEL_32; } v15 = 1; LABEL_32: v16 = 16; LABEL_33: v23 = v28; if ( *(_BYTE *)(v4 + 2019) ) { v24 = v28 + 8; if ( *(_QWORD *)(v28 + 152) ) { PSI_server[45](); v24 = v28 + 8; } a1 = (long long *)v24; my_rw_unlock(v24); } *((_DWORD *)v3 + 393) = v16 | *((_DWORD *)v3 + 393) & 0x401; if ( v15 ) { if ( !*(_DWORD *)(*v3 + 1976) ) { a1 = v3; ma_writeinfo(v3, 0LL); } if ( *(_DWORD *)my_thread_var(a1) == 120 ) *(_DWORD *)my_thread_var(a1) = 137; return *(unsigned int *)my_thread_var(a1); } if ( a2 ) { a1 = v3; if ( !((unsigned int ( *)(long long *, long long, long long, long long))v3[123])(v3, a2, v3[19], v23) ) { *((_BYTE *)v3 + 1572) |= 2u; return 0LL; } return *(unsigned int *)my_thread_var(a1); } if ( !*(_DWORD *)(*v3 + 1976) ) { a1 = v3; ma_writeinfo(v3, 0LL); } result = 0LL; if ( v3[19] == -1 ) return *(unsigned int *)my_thread_var(a1); return result; }
maria_rnext: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x28 MOV R15,RSI MOV RBX,RDI MOV R14,qword ptr [RDI] MOV ESI,EDX CALL 0x00137fd0 TEST EAX,EAX JS 0x00137c6c MOV R12D,EAX MOV qword ptr [RBP + -0x48],R15 CMP qword ptr [RBX + 0x98],-0x1 JZ 0x001379ed MOV R13D,0x8 XOR R15D,R15D JMP 0x00137a07 LAB_001379ed: MOV R13D,dword ptr [RBX + 0x624] AND R13D,0x20 MOV R15D,R13D SHR R15D,0x5 SHR R13D,0x2 XOR R13D,0x8 LAB_00137a07: CMP dword ptr [RBX + 0x664],0x2 JNZ 0x00137a27 MOV RDI,RBX XOR ESI,ESI MOV EDX,0x1 CALL 0x0013e412 TEST EAX,EAX JNZ 0x00137c6c LAB_00137a27: MOV dword ptr [RBP + -0x3c],R15D MOV ECX,R12D MOV qword ptr [RBP + -0x38],RCX IMUL R15,RCX,0x118 ADD R15,qword ptr [R14 + 0x570] CMP byte ptr [R14 + 0x7e3],0x0 MOV qword ptr [RBP + -0x30],R15 JZ 0x00137a69 LEA RDI,[R15 + 0x8] CMP qword ptr [R15 + 0x98],0x0 JNZ 0x00137c82 CALL 0x001a7348 LAB_00137a65: MOV R15,qword ptr [RBP + -0x30] LAB_00137a69: MOV RDI,RBX CALL 0x0013e3f9 MOV CL,byte ptr [R15 + 0xa4] CMP byte ptr [RBP + -0x3c],0x0 JZ 0x00137a9c CMP CL,0x2 JNZ 0x00137aba MOV EDX,dword ptr [RBX + 0x214] ADD EDX,dword ptr [RBX + 0x210] MOV RDI,RBX MOV ESI,R12D CALL 0x0015ebc6 JMP 0x00137ad4 LAB_00137a9c: CMP CL,0x2 JNZ 0x00137ae6 MOV EDX,dword ptr [RBX + 0x214] ADD EDX,dword ptr [RBX + 0x210] MOV RDI,RBX MOV ESI,R12D CALL 0x0015ef49 JMP 0x00137b19 LAB_00137aba: MOV RAX,qword ptr [R14 + 0x118] MOV RCX,qword ptr [RBP + -0x38] MOV RDX,qword ptr [RAX + RCX*0x8] MOV RDI,RBX MOV RSI,R15 CALL 0x0013a2af LAB_00137ad4: TEST EAX,EAX JZ 0x00137b25 MOV R15B,0x1 MOV R12D,0x30 JMP 0x00137bb2 LAB_00137ae6: OR R13D,dword ptr [RBX + 0x218] LEA RSI,[RBX + 0x200] MOV RCX,qword ptr [R14 + 0x118] MOV RDX,qword ptr [RBP + -0x38] MOV RCX,qword ptr [RCX + RDX*0x8] MOV RDI,RBX MOV EDX,R13D TEST EAX,EAX JZ 0x00137b14 CALL 0x001380b3 JMP 0x00137b19 LAB_00137b14: CALL 0x00139fdf LAB_00137b19: TEST EAX,EAX JZ 0x00137b25 MOV R15B,0x1 JMP 0x00137bac LAB_00137b25: LEA R13,[RBX + 0x200] MOV R15D,0x1 LAB_00137b32: MOV RDI,RBX CALL qword ptr [R14 + 0x6d8] TEST AL,AL JZ 0x00137b56 MOV RDI,RBX MOV ESI,R12D MOV RDX,qword ptr [RBP + -0x48] CALL 0x0013de83 XOR R15D,R15D TEST EAX,EAX JNZ 0x00137b9c LAB_00137b56: MOV RAX,qword ptr [RBX + 0x3b0] CMP RAX,qword ptr [RBX + 0x3b8] JC 0x00137b75 MOV RDI,RBX MOV ESI,R12D CALL 0x001378e7 TEST AL,AL JNZ 0x00137b98 LAB_00137b75: MOV RAX,qword ptr [R14 + 0x118] MOV RCX,qword ptr [RBP + -0x38] MOV RCX,qword ptr [RAX + RCX*0x8] MOV RDI,RBX MOV RSI,R13 MOV EDX,0x8 CALL 0x00139fdf TEST EAX,EAX JZ 0x00137b32 LAB_00137b98: MOV CL,0x1 JMP 0x00137ba1 LAB_00137b9c: XOR ECX,ECX MOV R15D,EAX LAB_00137ba1: CMP R15D,0x1 SETNZ R15B OR R15B,CL LAB_00137bac: MOV R12D,0x10 LAB_00137bb2: MOV RCX,qword ptr [RBP + -0x30] CMP byte ptr [R14 + 0x7e3],0x0 JZ 0x00137bdc MOV RDI,qword ptr [RCX + 0x98] ADD RCX,0x8 TEST RDI,RDI JNZ 0x00137c98 LAB_00137bd4: MOV RDI,RCX CALL 0x001a7476 LAB_00137bdc: MOV EAX,0x401 AND EAX,dword ptr [RBX + 0x624] OR EAX,R12D MOV dword ptr [RBX + 0x624],EAX TEST R15B,R15B JZ 0x00137c22 MOV RAX,qword ptr [RBX] CMP dword ptr [RAX + 0x7b8],0x0 JNZ 0x00137c0b MOV RDI,RBX XOR ESI,ESI CALL 0x0013e41a LAB_00137c0b: CALL 0x001a4ab2 CMP dword ptr [RAX],0x78 JNZ 0x00137c6c CALL 0x001a4ab2 MOV dword ptr [RAX],0x89 JMP 0x00137c6c LAB_00137c22: MOV RSI,qword ptr [RBP + -0x48] TEST RSI,RSI JZ 0x00137c4a MOV RDX,qword ptr [RBX + 0x98] MOV RDI,RBX CALL qword ptr [RBX + 0x3d8] TEST EAX,EAX JNZ 0x00137c6c OR byte ptr [RBX + 0x624],0x2 XOR EAX,EAX JMP 0x00137c73 LAB_00137c4a: MOV RAX,qword ptr [RBX] CMP dword ptr [RAX + 0x7b8],0x0 JNZ 0x00137c60 MOV RDI,RBX XOR ESI,ESI CALL 0x0013e41a LAB_00137c60: XOR EAX,EAX CMP qword ptr [RBX + 0x98],-0x1 JNZ 0x00137c73 LAB_00137c6c: CALL 0x001a4ab2 MOV EAX,dword ptr [RAX] LAB_00137c73: ADD RSP,0x28 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET LAB_00137c82: LEA RSI,[0x1db5d5] MOV EDX,0x30 CALL 0x0012eecc JMP 0x00137a65 LAB_00137c98: LEA RAX,[0x489050] MOV RAX,qword ptr [RAX] MOV R14,RCX CALL qword ptr [RAX + 0x168] MOV RCX,R14 JMP 0x00137bd4
int4 maria_rnext(long *param_1,long param_2,int4 param_3) { long lVar1; bool bVar2; byte bVar3; char cVar4; uint uVar5; int iVar6; int iVar7; int *piVar8; int4 *puVar9; uint uVar10; long lVar11; lVar1 = *param_1; uVar5 = _ma_check_index(param_1,param_3); if ((int)uVar5 < 0) goto LAB_00137c6c; if (param_1[0x13] == -1) { uVar10 = *(uint *)((long)param_1 + 0x624) & 0x20; cVar4 = (char)(uVar10 >> 5); uVar10 = uVar10 >> 2 ^ 8; } else { uVar10 = 8; cVar4 = '\0'; } if ((*(int *)((long)param_1 + 0x664) == 2) && (iVar6 = _ma_readinfo(param_1,0,1), iVar6 != 0)) goto LAB_00137c6c; lVar11 = (ulong)uVar5 * 0x118 + *(long *)(lVar1 + 0x570); if (*(char *)(lVar1 + 0x7e3) != '\0') { if (*(long *)(lVar11 + 0x98) == 0) { my_rw_rdlock(); } else { psi_rwlock_rdlock(lVar11 + 8, "/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_rnext.c",0x30); } } iVar6 = _ma_test_if_changed(param_1); if (cVar4 == '\0') { if (*(char *)(lVar11 + 0xa4) == '\x02') { iVar6 = maria_rtree_get_next (param_1,uVar5,*(int *)((long)param_1 + 0x214) + (int)param_1[0x42]); } else if (iVar6 == 0) { iVar6 = _ma_search_next(param_1,param_1 + 0x40,uVar10 | *(uint *)(param_1 + 0x43)); } else { iVar6 = _ma_search(); } if (iVar6 == 0) goto LAB_00137b25; bVar2 = true; LAB_00137bac: uVar5 = 0x10; } else { if (*(char *)(lVar11 + 0xa4) == '\x02') { iVar6 = maria_rtree_get_first (param_1,uVar5,*(int *)((long)param_1 + 0x214) + (int)param_1[0x42]); } else { iVar6 = _ma_search_first(param_1,lVar11, *(int8 *)(*(long *)(lVar1 + 0x118) + (ulong)uVar5 * 8)); } if (iVar6 == 0) { LAB_00137b25: iVar6 = 1; do { cVar4 = (**(code **)(lVar1 + 0x6d8))(param_1); iVar7 = iVar6; if (cVar4 != '\0') { iVar6 = ma_check_index_cond(param_1,uVar5,param_2); iVar7 = 0; if (iVar6 != 0) { bVar3 = 0; goto LAB_00137ba1; } } iVar6 = iVar7; } while ((((ulong)param_1[0x76] < (ulong)param_1[0x77]) || (cVar4 = ma_yield_and_check_if_killed(param_1,uVar5), cVar4 == '\0')) && (iVar7 = _ma_search_next(param_1,param_1 + 0x40,8), iVar7 == 0)); bVar3 = 1; LAB_00137ba1: bVar2 = (bool)(iVar6 != 1 | bVar3); goto LAB_00137bac; } bVar2 = true; uVar5 = 0x30; } if (*(char *)(lVar1 + 0x7e3) != '\0') { if (*(long *)(lVar11 + 0x98) != 0) { (**(code **)(PSI_server + 0x168))(); } my_rw_unlock(lVar11 + 8); } *(uint *)((long)param_1 + 0x624) = *(uint *)((long)param_1 + 0x624) & 0x401 | uVar5; if (bVar2) { if (*(int *)(*param_1 + 0x7b8) == 0) { _ma_writeinfo(param_1,0); } piVar8 = (int *)_my_thread_var(); if (*piVar8 == 0x78) { puVar9 = (int4 *)_my_thread_var(); *puVar9 = 0x89; } } else if (param_2 == 0) { if (*(int *)(*param_1 + 0x7b8) == 0) { _ma_writeinfo(param_1,0); } if (param_1[0x13] != -1) { return 0; } } else { iVar6 = (*(code *)param_1[0x7b])(param_1,param_2,param_1[0x13]); if (iVar6 == 0) { *(byte *)((long)param_1 + 0x624) = *(byte *)((long)param_1 + 0x624) | 2; return 0; } } LAB_00137c6c: puVar9 = (int4 *)_my_thread_var(); return *puVar9; }
31,804
CLI::OptionAlreadyAdded::OptionAlreadyAdded(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, CLI::ExitCodes)
MikePodsytnik[P]TCRtrie/build_O3/_deps/cli11-src/include/CLI/Error.hpp
static OptionAlreadyAdded Requires(std::string name, std::string other) { return {name + " requires " + other, ExitCodes::OptionAlreadyAdded}; }
O3
cpp
CLI::OptionAlreadyAdded::OptionAlreadyAdded(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, CLI::ExitCodes): pushq %rbp pushq %r15 pushq %r14 pushq %r12 pushq %rbx subq $0x40, %rsp movl %edx, %ebp movq %rsi, %r15 movq %rdi, %r14 leaq 0x30(%rsp), %rbx movq %rbx, -0x10(%rbx) leaq 0x19fc5(%rip), %rsi # 0x377cf leaq 0x19fd0(%rip), %rdx # 0x377e1 leaq 0x20(%rsp), %rdi callq 0x11f90 leaq 0x10(%rsp), %r12 movq %r12, -0x10(%r12) movq (%r15), %rcx leaq 0x10(%r15), %rax cmpq %rax, %rcx je 0x1d83f movq %rcx, (%rsp) movq (%rax), %rcx movq %rcx, 0x10(%rsp) jmp 0x1d847 movups (%rax), %xmm0 movups %xmm0, (%r12) movq 0x8(%r15), %rcx movq %rsp, %rdx movq %rcx, 0x8(%rdx) movq %rax, (%r15) movq $0x0, 0x8(%r15) movb $0x0, 0x10(%r15) leaq 0x20(%rsp), %rsi movq %r14, %rdi movl %ebp, %ecx callq 0x1ca64 movq (%rsp), %rdi cmpq %r12, %rdi je 0x1d887 movq 0x10(%rsp), %rsi incq %rsi callq 0x7430 movq 0x20(%rsp), %rdi cmpq %rbx, %rdi je 0x1d89e movq 0x30(%rsp), %rsi incq %rsi callq 0x7430 leaq 0x2bdd3(%rip), %rax # 0x49678 movq %rax, (%r14) addq $0x40, %rsp popq %rbx popq %r12 popq %r14 popq %r15 popq %rbp retq movq %rax, %r14 movq (%rsp), %rdi cmpq %r12, %rdi je 0x1d8ce movq 0x10(%rsp), %rsi incq %rsi callq 0x7430 leaq 0x20(%rsp), %rdi movq %rbx, %rsi callq 0x7a7b movq %r14, %rdi callq 0x7780 nop
_ZN3CLI18OptionAlreadyAddedC2ENSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEENS_9ExitCodesE: push rbp push r15 push r14 push r12 push rbx sub rsp, 40h mov ebp, edx mov r15, rsi mov r14, rdi lea rbx, [rsp+68h+var_38] mov [rbx-10h], rbx lea rsi, aOptionalreadya; "OptionAlreadyAdded" lea rdx, aOptionalreadya+12h; "" lea rdi, [rsp+68h+var_48] 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 r12, [rsp+68h+var_58] mov [r12-10h], r12 mov rcx, [r15] lea rax, [r15+10h] cmp rcx, rax jz short loc_1D83F mov [rsp+68h+var_68], rcx mov rcx, [rax] mov [rsp+68h+var_58], rcx jmp short loc_1D847 loc_1D83F: movups xmm0, xmmword ptr [rax] movups xmmword ptr [r12], xmm0 loc_1D847: mov rcx, [r15+8] mov rdx, rsp mov [rdx+8], rcx mov [r15], rax mov qword ptr [r15+8], 0 mov byte ptr [r15+10h], 0 lea rsi, [rsp+68h+var_48] mov rdi, r14; int mov ecx, ebp call _ZN3CLI17ConstructionErrorC2ENSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES6_NS_9ExitCodesE; CLI::ConstructionError::ConstructionError(std::string,std::string,CLI::ExitCodes) mov rdi, [rsp+68h+var_68]; void * cmp rdi, r12 jz short loc_1D887 mov rsi, [rsp+68h+var_58] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_1D887: mov rdi, [rsp+68h+var_48]; void * cmp rdi, rbx jz short loc_1D89E mov rsi, [rsp+68h+var_38] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_1D89E: lea rax, off_49678 mov [r14], rax add rsp, 40h pop rbx pop r12 pop r14 pop r15 pop rbp retn mov r14, rax mov rdi, [rsp+0]; void * cmp rdi, r12 jz short loc_1D8CE mov rsi, [rsp+arg_8] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_1D8CE: lea rdi, [rsp+arg_18] mov rsi, rbx call _ZN3CLI18OptionAlreadyAddedC2ENSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEENS_9ExitCodesE_cold_1; CLI::OptionAlreadyAdded::OptionAlreadyAdded(std::string,CLI::ExitCodes) [clone] mov rdi, r14 call __Unwind_Resume
void ( ** CLI::OptionAlreadyAdded::OptionAlreadyAdded( _QWORD *a1, long long a2, int a3))(CLI::Error *__hidden this) { __int128 *v4; // rax void ( **result)(CLI::Error *__hidden); // rax void *v6[2]; // [rsp+0h] [rbp-68h] BYREF __int128 v7; // [rsp+10h] [rbp-58h] BYREF void *v8[2]; // [rsp+20h] [rbp-48h] BYREF _QWORD v9[7]; // [rsp+30h] [rbp-38h] BYREF v8[0] = v9; std::string::_M_construct<char const*>((long long)v8, "OptionAlreadyAdded", (long long)""); v6[0] = &v7; v4 = (__int128 *)(a2 + 16); if ( *(_QWORD *)a2 == a2 + 16 ) { v7 = *v4; } else { v6[0] = *(void **)a2; *(_QWORD *)&v7 = *(_QWORD *)v4; } v6[1] = *(void **)(a2 + 8); *(_QWORD *)a2 = v4; *(_QWORD *)(a2 + 8) = 0LL; *(_BYTE *)(a2 + 16) = 0; CLI::ConstructionError::ConstructionError(a1, (long long)v8, (long long)v6, a3); if ( v6[0] != &v7 ) operator delete(v6[0], v7 + 1); if ( v8[0] != v9 ) operator delete(v8[0], v9[0] + 1LL); result = off_49678; *a1 = off_49678; return result; }
OptionAlreadyAdded: PUSH RBP PUSH R15 PUSH R14 PUSH R12 PUSH RBX SUB RSP,0x40 MOV EBP,EDX MOV R15,RSI MOV R14,RDI LEA RBX,[RSP + 0x30] MOV qword ptr [RBX + -0x10],RBX LEA RSI,[0x1377cf] LEA RDX,[0x1377e1] LEA RDI,[RSP + 0x20] CALL 0x00111f90 LEA R12,[RSP + 0x10] MOV qword ptr [R12 + -0x10],R12 MOV RCX,qword ptr [R15] LEA RAX,[R15 + 0x10] CMP RCX,RAX JZ 0x0011d83f MOV qword ptr [RSP],RCX MOV RCX,qword ptr [RAX] MOV qword ptr [RSP + 0x10],RCX JMP 0x0011d847 LAB_0011d83f: MOVUPS XMM0,xmmword ptr [RAX] MOVUPS xmmword ptr [R12],XMM0 LAB_0011d847: MOV RCX,qword ptr [R15 + 0x8] MOV RDX,RSP MOV qword ptr [RDX + 0x8],RCX MOV qword ptr [R15],RAX MOV qword ptr [R15 + 0x8],0x0 MOV byte ptr [R15 + 0x10],0x0 LAB_0011d862: LEA RSI,[RSP + 0x20] MOV RDI,R14 MOV ECX,EBP CALL 0x0011ca64 LAB_0011d871: MOV RDI,qword ptr [RSP] CMP RDI,R12 JZ 0x0011d887 MOV RSI,qword ptr [RSP + 0x10] INC RSI CALL 0x00107430 LAB_0011d887: MOV RDI,qword ptr [RSP + 0x20] CMP RDI,RBX JZ 0x0011d89e MOV RSI,qword ptr [RSP + 0x30] INC RSI CALL 0x00107430 LAB_0011d89e: LEA RAX,[0x149678] MOV qword ptr [R14],RAX ADD RSP,0x40 POP RBX POP R12 POP R14 POP R15 POP RBP RET
/* CLI::OptionAlreadyAdded::OptionAlreadyAdded(std::__cxx11::string, CLI::ExitCodes) */ void __thiscall CLI::OptionAlreadyAdded::OptionAlreadyAdded (OptionAlreadyAdded *this,long *param_2,int4 param_3) { long *plVar1; long *local_68; long local_60; long local_58; int4 uStack_50; int4 uStack_4c; long *local_48 [2]; long local_38 [2]; local_48[0] = local_38; std::__cxx11::string::_M_construct<char_const*>(local_48,"OptionAlreadyAdded",""); plVar1 = param_2 + 2; if ((long *)*param_2 == plVar1) { local_58 = *plVar1; uStack_50 = (int4)param_2[3]; uStack_4c = *(int4 *)((long)param_2 + 0x1c); local_68 = &local_58; } else { local_58 = *plVar1; local_68 = (long *)*param_2; } local_60 = param_2[1]; *param_2 = (long)plVar1; param_2[1] = 0; *(int1 *)(param_2 + 2) = 0; /* try { // try from 0011d862 to 0011d870 has its CatchHandler @ 0011d8b5 */ ConstructionError::ConstructionError((ConstructionError *)this,local_48,&local_68,param_3); if (local_68 != &local_58) { operator_delete(local_68,local_58 + 1); } if (local_48[0] != local_38) { operator_delete(local_48[0],local_38[0] + 1); } *(int ***)this = &PTR__Error_00149678; return; }
31,805
ma_log_rt_split
eloqsql/storage/maria/ma_rt_split.c
static my_bool _ma_log_rt_split(MARIA_PAGE *page, const uchar *key_with_nod_flag, uint full_length, const uchar *log_internal_copy, uint log_internal_copy_length, const uchar *log_key_copy, uint length_diff) { MARIA_HA *info= page->info; MARIA_SHARE *share= info->s; LSN lsn; uchar log_data[FILEID_STORE_SIZE + PAGE_STORE_SIZE + 1 + 2 + 1 + 2 + 2 + 7], *log_pos; LEX_CUSTRING log_array[TRANSLOG_INTERNAL_PARTS + 6]; uint translog_parts, extra_length= 0; my_off_t page_pos; DBUG_ENTER("_ma_log_rt_split"); DBUG_PRINT("enter", ("page: %p", page)); DBUG_ASSERT(share->now_transactional); page_pos= page->pos / share->block_size; page_store(log_data + FILEID_STORE_SIZE, page_pos); log_pos= log_data+ FILEID_STORE_SIZE + PAGE_STORE_SIZE; log_pos[0]= KEY_OP_DEL_SUFFIX; log_pos++; DBUG_ASSERT((int)length_diff > 0); int2store(log_pos, length_diff); log_pos+= 2; log_pos[0]= KEY_OP_MULTI_COPY; log_pos++; int2store(log_pos, full_length); log_pos+= 2; int2store(log_pos, log_internal_copy_length); log_pos+= 2; log_array[TRANSLOG_INTERNAL_PARTS + 0].str= log_data; log_array[TRANSLOG_INTERNAL_PARTS + 0].length= sizeof(log_data) - 7; log_array[TRANSLOG_INTERNAL_PARTS + 1].str= log_internal_copy; log_array[TRANSLOG_INTERNAL_PARTS + 1].length= log_internal_copy_length; translog_parts= 2; if (log_key_copy != NULL) /* need to store key into record */ { log_array[TRANSLOG_INTERNAL_PARTS + 2].str= log_key_copy; log_array[TRANSLOG_INTERNAL_PARTS + 2].length= 1 + 2 + 1 + 2; log_array[TRANSLOG_INTERNAL_PARTS + 3].str= key_with_nod_flag; log_array[TRANSLOG_INTERNAL_PARTS + 3].length= full_length; extra_length= 1 + 2 + 1 + 2 + full_length; translog_parts+= 2; } _ma_log_key_changes(page, log_array + TRANSLOG_INTERNAL_PARTS + translog_parts, log_pos, &extra_length, &translog_parts); /* Remember new page length for future log entires for same page */ page->org_size= page->size; if (translog_write_record(&lsn, LOGREC_REDO_INDEX, info->trn, info, (translog_size_t) ((log_pos - log_data) + log_internal_copy_length + extra_length), TRANSLOG_INTERNAL_PARTS + translog_parts, log_array, log_data, NULL)) DBUG_RETURN(1); DBUG_RETURN(0); }
O0
c
ma_log_rt_split: pushq %rbp movq %rsp, %rbp subq $0x150, %rsp # imm = 0x150 movl 0x10(%rbp), %eax movq %fs:0x28, %rax movq %rax, -0x8(%rbp) movq %rdi, -0x30(%rbp) movq %rsi, -0x38(%rbp) movl %edx, -0x3c(%rbp) movq %rcx, -0x48(%rbp) movl %r8d, -0x4c(%rbp) movq %r9, -0x58(%rbp) movq -0x30(%rbp), %rax movq (%rax), %rax movq %rax, -0x60(%rbp) movq -0x60(%rbp), %rax movq (%rax), %rax movq %rax, -0x68(%rbp) movl $0x0, -0x108(%rbp) jmp 0x9b2b4 jmp 0x9b2b6 jmp 0x9b2b8 movq -0x30(%rbp), %rax movq 0x18(%rax), %rax movq -0x68(%rbp), %rcx movl 0x7bc(%rcx), %ecx xorl %edx, %edx divq %rcx movq %rax, -0x110(%rbp) leaq -0x20(%rbp), %rax addq $0x2, %rax movq %rax, -0x118(%rbp) movq -0x110(%rbp), %rax movl %eax, %ecx movq -0x118(%rbp), %rax movl %ecx, (%rax) movq -0x110(%rbp), %rax shrq $0x20, %rax movb %al, %cl movq -0x118(%rbp), %rax movb %cl, 0x4(%rax) leaq -0x20(%rbp), %rax addq $0x2, %rax addq $0x5, %rax movq %rax, -0x78(%rbp) movq -0x78(%rbp), %rax movb $0x7, (%rax) movq -0x78(%rbp), %rax addq $0x1, %rax movq %rax, -0x78(%rbp) jmp 0x9b333 jmp 0x9b335 movq -0x78(%rbp), %rax movq %rax, -0x120(%rbp) movl 0x10(%rbp), %eax movw %ax, %cx movq -0x120(%rbp), %rax movw %cx, (%rax) movq -0x78(%rbp), %rax addq $0x2, %rax movq %rax, -0x78(%rbp) movq -0x78(%rbp), %rax movb $0x9, (%rax) movq -0x78(%rbp), %rax addq $0x1, %rax movq %rax, -0x78(%rbp) movq -0x78(%rbp), %rax movq %rax, -0x128(%rbp) movl -0x3c(%rbp), %eax movw %ax, %cx movq -0x128(%rbp), %rax movw %cx, (%rax) movq -0x78(%rbp), %rax addq $0x2, %rax movq %rax, -0x78(%rbp) movq -0x78(%rbp), %rax movq %rax, -0x130(%rbp) movl -0x4c(%rbp), %eax movw %ax, %cx movq -0x130(%rbp), %rax movw %cx, (%rax) movq -0x78(%rbp), %rax addq $0x2, %rax movq %rax, -0x78(%rbp) leaq -0x20(%rbp), %rax movq %rax, -0xe0(%rbp) movq $0xf, -0xd8(%rbp) movq -0x48(%rbp), %rax movq %rax, -0xd0(%rbp) movl -0x4c(%rbp), %eax movq %rax, -0xc8(%rbp) movl $0x2, -0x104(%rbp) cmpq $0x0, -0x58(%rbp) je 0x9b43f movq -0x58(%rbp), %rax movq %rax, -0xc0(%rbp) movq $0x6, -0xb8(%rbp) movq -0x38(%rbp), %rax movq %rax, -0xb0(%rbp) movl -0x3c(%rbp), %eax movq %rax, -0xa8(%rbp) movl -0x3c(%rbp), %eax addl $0x6, %eax movl %eax, -0x108(%rbp) movl -0x104(%rbp), %eax addl $0x2, %eax movl %eax, -0x104(%rbp) movq -0x30(%rbp), %rax movl 0x20(%rax), %ecx movq -0x30(%rbp), %rax movl %ecx, 0x24(%rax) movq -0x60(%rbp), %rax movq 0x8(%rax), %rdx movq -0x60(%rbp), %rcx movq -0x78(%rbp), %rax leaq -0x20(%rbp), %rsi subq %rsi, %rax movl -0x4c(%rbp), %esi addq %rsi, %rax movl -0x108(%rbp), %esi addq %rsi, %rax movl %eax, %r8d movl -0x104(%rbp), %r9d addl $0x2, %r9d leaq -0x100(%rbp), %r10 leaq -0x20(%rbp), %rax leaq -0x70(%rbp), %rdi movl $0xc, %esi xorl %r11d, %r11d movq %r10, (%rsp) movq %rax, 0x8(%rsp) movq $0x0, 0x10(%rsp) callq 0x539a0 cmpb $0x0, %al je 0x9b4bb jmp 0x9b4b5 movb $0x1, -0x21(%rbp) jmp 0x9b4c1 jmp 0x9b4bd movb $0x0, -0x21(%rbp) movb -0x21(%rbp), %al movb %al, -0x131(%rbp) movq %fs:0x28, %rax movq -0x8(%rbp), %rcx cmpq %rcx, %rax jne 0x9b4eb movb -0x131(%rbp), %al addq $0x150, %rsp # imm = 0x150 popq %rbp retq callq 0x2a270
_ma_log_rt_split: push rbp mov rbp, rsp sub rsp, 150h mov eax, [rbp+arg_0] mov rax, fs:28h mov [rbp+var_8], rax mov [rbp+var_30], rdi mov [rbp+var_38], rsi mov [rbp+var_3C], edx mov [rbp+var_48], rcx mov [rbp+var_4C], r8d mov [rbp+var_58], r9 mov rax, [rbp+var_30] mov rax, [rax] mov [rbp+var_60], rax mov rax, [rbp+var_60] mov rax, [rax] mov [rbp+var_68], rax mov [rbp+var_108], 0 jmp short $+2 loc_9B2B4: jmp short $+2 loc_9B2B6: jmp short $+2 loc_9B2B8: mov rax, [rbp+var_30] mov rax, [rax+18h] mov rcx, [rbp+var_68] mov ecx, [rcx+7BCh] xor edx, edx div rcx mov [rbp+var_110], rax lea rax, [rbp+var_20] add rax, 2 mov [rbp+var_118], rax mov rax, [rbp+var_110] mov ecx, eax mov rax, [rbp+var_118] mov [rax], ecx mov rax, [rbp+var_110] shr rax, 20h mov cl, al mov rax, [rbp+var_118] mov [rax+4], cl lea rax, [rbp+var_20] add rax, 2 add rax, 5 mov [rbp+var_78], rax mov rax, [rbp+var_78] mov byte ptr [rax], 7 mov rax, [rbp+var_78] add rax, 1 mov [rbp+var_78], rax jmp short $+2 loc_9B333: jmp short $+2 loc_9B335: mov rax, [rbp+var_78] mov [rbp+var_120], rax mov eax, [rbp+arg_0] mov cx, ax mov rax, [rbp+var_120] mov [rax], cx mov rax, [rbp+var_78] add rax, 2 mov [rbp+var_78], rax mov rax, [rbp+var_78] mov byte ptr [rax], 9 mov rax, [rbp+var_78] add rax, 1 mov [rbp+var_78], rax mov rax, [rbp+var_78] mov [rbp+var_128], rax mov eax, [rbp+var_3C] mov cx, ax mov rax, [rbp+var_128] mov [rax], cx mov rax, [rbp+var_78] add rax, 2 mov [rbp+var_78], rax mov rax, [rbp+var_78] mov [rbp+var_130], rax mov eax, [rbp+var_4C] mov cx, ax mov rax, [rbp+var_130] mov [rax], cx mov rax, [rbp+var_78] add rax, 2 mov [rbp+var_78], rax lea rax, [rbp+var_20] mov [rbp+var_E0], rax mov [rbp+var_D8], 0Fh mov rax, [rbp+var_48] mov [rbp+var_D0], rax mov eax, [rbp+var_4C] mov [rbp+var_C8], rax mov [rbp+var_104], 2 cmp [rbp+var_58], 0 jz short loc_9B43F mov rax, [rbp+var_58] mov [rbp+var_C0], rax mov [rbp+var_B8], 6 mov rax, [rbp+var_38] mov [rbp+var_B0], rax mov eax, [rbp+var_3C] mov [rbp+var_A8], rax mov eax, [rbp+var_3C] add eax, 6 mov [rbp+var_108], eax mov eax, [rbp+var_104] add eax, 2 mov [rbp+var_104], eax loc_9B43F: mov rax, [rbp+var_30] mov ecx, [rax+20h] mov rax, [rbp+var_30] mov [rax+24h], ecx mov rax, [rbp+var_60] mov rdx, [rax+8] mov rcx, [rbp+var_60] mov rax, [rbp+var_78] lea rsi, [rbp+var_20] sub rax, rsi mov esi, [rbp+var_4C] add rax, rsi mov esi, [rbp+var_108] add rax, rsi mov r8d, eax mov r9d, [rbp+var_104] add r9d, 2 lea r10, [rbp+var_100] lea rax, [rbp+var_20] lea rdi, [rbp+var_70] mov esi, 0Ch xor r11d, r11d mov [rsp+150h+var_150], r10 mov [rsp+150h+var_148], rax mov [rsp+150h+var_140], 0 call translog_write_record cmp al, 0 jz short loc_9B4BB jmp short $+2 loc_9B4B5: mov [rbp+var_21], 1 jmp short loc_9B4C1 loc_9B4BB: jmp short $+2 loc_9B4BD: mov [rbp+var_21], 0 loc_9B4C1: mov al, [rbp+var_21] mov [rbp+var_131], al mov rax, fs:28h mov rcx, [rbp+var_8] cmp rax, rcx jnz short loc_9B4EB mov al, [rbp+var_131] add rsp, 150h pop rbp retn loc_9B4EB: call ___stack_chk_fail
bool ma_log_rt_split( long long a1, long long a2, unsigned int a3, long long a4, unsigned int a5, long long a6, __int16 a7) { unsigned long long v8; // [rsp+40h] [rbp-110h] unsigned int v9; // [rsp+48h] [rbp-108h] int v10; // [rsp+4Ch] [rbp-104h] _QWORD v11[17]; // [rsp+50h] [rbp-100h] BYREF _BYTE *v12; // [rsp+D8h] [rbp-78h] _BYTE v13[8]; // [rsp+E0h] [rbp-70h] BYREF long long v14; // [rsp+E8h] [rbp-68h] long long *v15; // [rsp+F0h] [rbp-60h] long long v16; // [rsp+F8h] [rbp-58h] unsigned int v17; // [rsp+104h] [rbp-4Ch] long long v18; // [rsp+108h] [rbp-48h] unsigned int v19; // [rsp+114h] [rbp-3Ch] long long v20; // [rsp+118h] [rbp-38h] long long v21; // [rsp+120h] [rbp-30h] __int16 v22; // [rsp+130h] [rbp-20h] BYREF int v23; // [rsp+132h] [rbp-1Eh] char v24; // [rsp+136h] [rbp-1Ah] char v25; // [rsp+137h] [rbp-19h] __int16 v26; // [rsp+138h] [rbp-18h] char v27; // [rsp+13Ah] [rbp-16h] __int16 v28; // [rsp+13Bh] [rbp-15h] __int16 v29; // [rsp+13Dh] [rbp-13h] _BYTE v30[17]; // [rsp+13Fh] [rbp-11h] BYREF long long savedregs; // [rsp+150h] [rbp+0h] BYREF *(_QWORD *)&v30[9] = __readfsqword(0x28u); v21 = a1; v20 = a2; v19 = a3; v18 = a4; v17 = a5; v16 = a6; v15 = *(long long **)a1; v14 = *v15; v9 = 0; v8 = *(_QWORD *)(a1 + 24) / (unsigned long long)*(unsigned int *)(v14 + 1980); v23 = v8; v24 = BYTE4(v8); v25 = 7; v26 = a7; v27 = 9; v28 = a3; v29 = a5; v12 = v30; v11[4] = &v22; v11[5] = 15LL; v11[6] = a4; v11[7] = a5; v10 = 2; if ( a6 ) { v11[8] = v16; v11[9] = 6LL; v11[10] = v20; v11[11] = v19; v9 = v19 + 6; v10 = 4; } *(_DWORD *)(v21 + 36) = *(_DWORD *)(v21 + 32); return translog_write_record( (long long)v13, 0xCu, v15[1], v15, v9 + v17 + (_DWORD)v12 - ((unsigned int)&savedregs - 32), v10 + 2, v11, &v22, 0LL) != 0; }
_ma_log_rt_split: PUSH RBP MOV RBP,RSP SUB RSP,0x150 MOV EAX,dword ptr [RBP + 0x10] MOV RAX,qword ptr FS:[0x28] MOV qword ptr [RBP + -0x8],RAX MOV qword ptr [RBP + -0x30],RDI MOV qword ptr [RBP + -0x38],RSI MOV dword ptr [RBP + -0x3c],EDX MOV qword ptr [RBP + -0x48],RCX MOV dword ptr [RBP + -0x4c],R8D MOV qword ptr [RBP + -0x58],R9 MOV RAX,qword ptr [RBP + -0x30] MOV RAX,qword ptr [RAX] MOV qword ptr [RBP + -0x60],RAX MOV RAX,qword ptr [RBP + -0x60] MOV RAX,qword ptr [RAX] MOV qword ptr [RBP + -0x68],RAX MOV dword ptr [RBP + -0x108],0x0 JMP 0x0019b2b4 LAB_0019b2b4: JMP 0x0019b2b6 LAB_0019b2b6: JMP 0x0019b2b8 LAB_0019b2b8: MOV RAX,qword ptr [RBP + -0x30] MOV RAX,qword ptr [RAX + 0x18] MOV RCX,qword ptr [RBP + -0x68] MOV ECX,dword ptr [RCX + 0x7bc] XOR EDX,EDX DIV RCX MOV qword ptr [RBP + -0x110],RAX LEA RAX,[RBP + -0x20] ADD RAX,0x2 MOV qword ptr [RBP + -0x118],RAX MOV RAX,qword ptr [RBP + -0x110] MOV ECX,EAX MOV RAX,qword ptr [RBP + -0x118] MOV dword ptr [RAX],ECX MOV RAX,qword ptr [RBP + -0x110] SHR RAX,0x20 MOV CL,AL MOV RAX,qword ptr [RBP + -0x118] MOV byte ptr [RAX + 0x4],CL LEA RAX,[RBP + -0x20] ADD RAX,0x2 ADD RAX,0x5 MOV qword ptr [RBP + -0x78],RAX MOV RAX,qword ptr [RBP + -0x78] MOV byte ptr [RAX],0x7 MOV RAX,qword ptr [RBP + -0x78] ADD RAX,0x1 MOV qword ptr [RBP + -0x78],RAX JMP 0x0019b333 LAB_0019b333: JMP 0x0019b335 LAB_0019b335: MOV RAX,qword ptr [RBP + -0x78] MOV qword ptr [RBP + -0x120],RAX MOV EAX,dword ptr [RBP + 0x10] MOV CX,AX MOV RAX,qword ptr [RBP + -0x120] MOV word ptr [RAX],CX MOV RAX,qword ptr [RBP + -0x78] ADD RAX,0x2 MOV qword ptr [RBP + -0x78],RAX MOV RAX,qword ptr [RBP + -0x78] MOV byte ptr [RAX],0x9 MOV RAX,qword ptr [RBP + -0x78] ADD RAX,0x1 MOV qword ptr [RBP + -0x78],RAX MOV RAX,qword ptr [RBP + -0x78] MOV qword ptr [RBP + -0x128],RAX MOV EAX,dword ptr [RBP + -0x3c] MOV CX,AX MOV RAX,qword ptr [RBP + -0x128] MOV word ptr [RAX],CX MOV RAX,qword ptr [RBP + -0x78] ADD RAX,0x2 MOV qword ptr [RBP + -0x78],RAX MOV RAX,qword ptr [RBP + -0x78] MOV qword ptr [RBP + -0x130],RAX MOV EAX,dword ptr [RBP + -0x4c] MOV CX,AX MOV RAX,qword ptr [RBP + -0x130] MOV word ptr [RAX],CX MOV RAX,qword ptr [RBP + -0x78] ADD RAX,0x2 MOV qword ptr [RBP + -0x78],RAX LEA RAX,[RBP + -0x20] MOV qword ptr [RBP + -0xe0],RAX MOV qword ptr [RBP + -0xd8],0xf MOV RAX,qword ptr [RBP + -0x48] MOV qword ptr [RBP + -0xd0],RAX MOV EAX,dword ptr [RBP + -0x4c] MOV qword ptr [RBP + -0xc8],RAX MOV dword ptr [RBP + -0x104],0x2 CMP qword ptr [RBP + -0x58],0x0 JZ 0x0019b43f MOV RAX,qword ptr [RBP + -0x58] MOV qword ptr [RBP + -0xc0],RAX MOV qword ptr [RBP + -0xb8],0x6 MOV RAX,qword ptr [RBP + -0x38] MOV qword ptr [RBP + -0xb0],RAX MOV EAX,dword ptr [RBP + -0x3c] MOV qword ptr [RBP + -0xa8],RAX MOV EAX,dword ptr [RBP + -0x3c] ADD EAX,0x6 MOV dword ptr [RBP + -0x108],EAX MOV EAX,dword ptr [RBP + -0x104] ADD EAX,0x2 MOV dword ptr [RBP + -0x104],EAX LAB_0019b43f: MOV RAX,qword ptr [RBP + -0x30] MOV ECX,dword ptr [RAX + 0x20] MOV RAX,qword ptr [RBP + -0x30] MOV dword ptr [RAX + 0x24],ECX MOV RAX,qword ptr [RBP + -0x60] MOV RDX,qword ptr [RAX + 0x8] MOV RCX,qword ptr [RBP + -0x60] MOV RAX,qword ptr [RBP + -0x78] LEA RSI,[RBP + -0x20] SUB RAX,RSI MOV ESI,dword ptr [RBP + -0x4c] ADD RAX,RSI MOV ESI,dword ptr [RBP + -0x108] ADD RAX,RSI MOV R8D,EAX MOV R9D,dword ptr [RBP + -0x104] ADD R9D,0x2 LEA R10,[RBP + -0x100] LEA RAX,[RBP + -0x20] LEA RDI,[RBP + -0x70] MOV ESI,0xc XOR R11D,R11D MOV qword ptr [RSP],R10 MOV qword ptr [RSP + 0x8],RAX MOV qword ptr [RSP + 0x10],0x0 CALL 0x001539a0 CMP AL,0x0 JZ 0x0019b4bb JMP 0x0019b4b5 LAB_0019b4b5: MOV byte ptr [RBP + -0x21],0x1 JMP 0x0019b4c1 LAB_0019b4bb: JMP 0x0019b4bd LAB_0019b4bd: MOV byte ptr [RBP + -0x21],0x0 LAB_0019b4c1: MOV AL,byte ptr [RBP + -0x21] MOV byte ptr [RBP + -0x131],AL MOV RAX,qword ptr FS:[0x28] MOV RCX,qword ptr [RBP + -0x8] CMP RAX,RCX JNZ 0x0019b4eb MOV AL,byte ptr [RBP + -0x131] ADD RSP,0x150 POP RBP RET LAB_0019b4eb: CALL 0x0012a270
int8 _ma_log_rt_split(long *param_1,int8 param_2,uint param_3,int8 param_4,uint param_5, long param_6,int2 param_7) { char cVar1; ulong uVar2; long in_FS_OFFSET; int local_110; int local_10c; int1 local_108 [32]; int1 *local_e8; int8 local_e0; int8 local_d8; ulong local_d0; long local_c8; int8 local_c0; int8 local_b8; ulong local_b0; int1 *local_80; int1 local_78 [8]; long local_70; long *local_68; long local_60; uint local_54; int8 local_50; uint local_44; int8 local_40; long *local_38; int1 local_29; int1 local_28 [2]; int4 local_26; int1 local_22; int1 local_21; int2 local_20; int1 local_1e; int2 local_1d; int2 local_1b; int1 auStack_19 [9]; long local_10; local_10 = *(long *)(in_FS_OFFSET + 0x28); local_68 = (long *)*param_1; local_70 = *local_68; local_110 = 0; uVar2 = (ulong)param_1[3] / (ulong)*(uint *)(local_70 + 0x7bc); local_26 = (int4)uVar2; local_22 = (int1)(uVar2 >> 0x20); local_21 = 7; local_20 = param_7; local_1e = 9; local_1d = (int2)param_3; local_1b = (int2)param_5; local_80 = auStack_19; local_e8 = local_28; local_e0 = 0xf; local_d0 = (ulong)param_5; local_10c = 2; if (param_6 != 0) { local_c0 = 6; local_b0 = (ulong)param_3; local_110 = param_3 + 6; local_10c = 4; local_c8 = param_6; local_b8 = param_2; } *(int *)((long)param_1 + 0x24) = (int)param_1[4]; local_d8 = param_4; local_60 = param_6; local_54 = param_5; local_50 = param_4; local_44 = param_3; local_40 = param_2; local_38 = param_1; cVar1 = translog_write_record (local_78,0xc,local_68[1],local_68, ((int)local_80 - (int)local_28) + param_5 + local_110,local_10c + 2,local_108, local_28,0); local_29 = cVar1 != '\0'; if (*(long *)(in_FS_OFFSET + 0x28) == local_10) { return CONCAT71((int7)((ulong)*(long *)(in_FS_OFFSET + 0x28) >> 8),local_29); } /* WARNING: Subroutine does not return */ __stack_chk_fail(); }
31,806
OpenSubdiv::v3_6_0::Tmr::SubdivisionPlanBuilder::initializeStencilMatrix(OpenSubdiv::v3_6_0::Tmr::SubdivisionPlan&)
NVIDIA-RTX[P]OSD-Lite/opensubdiv/tmr/subdivisionPlanBuilder.cpp
void SubdivisionPlanBuilder::initializeStencilMatrix(SubdivisionPlan& plan) { int numPointStencils = _numRefinedPoints + (_numIrregularPatchesTotal * _irregularPatchSize); std::vector<float>& stencilMatrix = plan._stencilMatrix; stencilMatrix.resize(numPointStencils * _numControlPoints, 0.f); // For refined points, initialize successive rows of the stencil matrix // a level at a time using the PrimvarRefiner to accumulate contributing // rows: int numLevels = _faceRefiner->GetNumLevels(); if (numLevels > 1) { Far::PrimvarRefinerReal<float> primvarRefiner(*_faceRefiner); StencilRow<float> dstRow(&stencilMatrix[0], _numControlPoints); primvarRefiner.Interpolate(1, ControlRow(-1), dstRow); for (int level = 2; level < numLevels; ++level) { StencilRow<float> srcRow = dstRow; dstRow = srcRow[_faceRefiner->getLevel(level-1).getNumVertices()]; primvarRefiner.Interpolate(level, srcRow, dstRow); } } // For irregular patch points, append rows for each irregular patch: if (_numIrregularPatchesTotal > 0) { Index stencilIndexBase = _numRefinedPoints; for (int level = 0; level < numLevels; ++level) { if (_levelOffsets[level].numIrregularPatches == 0) continue; for (ProtoNode const& pn : _protoNodeStore[level]) { if (!pn.active || !pn.hasIrregularPatch) continue; getIrregularPatchConversion(pn); appendConversionStencilsToMatrix(stencilMatrix, stencilIndexBase); stencilIndexBase += _irregularPatchSize; } } } }
O1
cpp
OpenSubdiv::v3_6_0::Tmr::SubdivisionPlanBuilder::initializeStencilMatrix(OpenSubdiv::v3_6_0::Tmr::SubdivisionPlan&): pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x48, %rsp movq %rsi, %rbx movq %rdi, %r14 movslq 0x284(%rdi), %rax movslq 0x28c(%rdi), %rcx movslq 0x274(%rdi), %rdx imulq %rcx, %rdx addq %rax, %rdx addq $0x70, %rbx movslq 0x280(%rdi), %rsi imulq %rdx, %rsi leaq 0x10(%rsp), %rdx movl $0x0, (%rdx) movq %rbx, %rdi callq 0x3a220 movq 0x108(%r14), %rax movq 0x68(%rax), %rcx subq 0x60(%rax), %rcx sarq $0x3, %rcx movabsq $-0x5555555555555555, %rdx # imm = 0xAAAAAAAAAAAAAAAB imulq %rcx, %rdx movq %rdx, 0x8(%rsp) cmpl $0x2, %edx jl 0xa938a leaq 0x40(%rsp), %rdi movq %rax, (%rdi) movq (%rbx), %rax movl 0x280(%r14), %edx leaq 0x10(%rsp), %rcx movq %rax, (%rcx) movl %edx, 0x8(%rcx) leaq 0x20(%rsp), %rdx movl $0xffffffff, (%rdx) # imm = 0xFFFFFFFF movl $0x1, %esi callq 0x38990 cmpl $0x2, 0x8(%rsp) je 0xa938a movq 0x8(%rsp), %r12 andl $0x7fffffff, %r12d # imm = 0x7FFFFFFF movl $0x2, %r15d leaq 0x20(%rsp), %r13 leaq 0x10(%rsp), %rbp movups 0x10(%rsp), %xmm0 movaps %xmm0, 0x20(%rsp) movq 0x108(%r14), %rax movq 0x30(%rax), %rax movq -0x8(%rax,%r15,8), %rax movslq 0x8(%rax), %rax movslq 0x28(%rsp), %rcx imulq %rcx, %rax shlq $0x2, %rax addq 0x20(%rsp), %rax movq %rax, 0x10(%rsp) movl %ecx, 0x18(%rsp) leaq 0x40(%rsp), %rdi movl %r15d, %esi movq %r13, %rdx movq %rbp, %rcx callq 0x3a8e0 incq %r15 cmpq %r15, %r12 jne 0xa9336 cmpl $0x0, 0x28c(%r14) jle 0xa9423 cmpl $0x0, 0x8(%rsp) jle 0xa9423 movl 0x284(%r14), %ebp leaq 0x118(%r14), %rax movq %rax, 0x38(%rsp) movq 0x8(%rsp), %rax andl $0x7fffffff, %eax # imm = 0x7FFFFFFF movq %rax, 0x8(%rsp) xorl %r12d, %r12d leaq (%r12,%r12,4), %rax movq 0x38(%rsp), %rcx cmpl $0x0, 0x10(%rcx,%rax,4) je 0xa9419 leaq (%r12,%r12,2), %rax movq (%r14,%rax,8), %r15 movq 0x8(%r14,%rax,8), %r13 cmpq %r13, %r15 je 0xa9419 movl 0xc(%r15), %eax notl %eax testb $0x41, %al jne 0xa9413 movq %r14, %rdi movq %r15, %rsi callq 0x39610 movq %r14, %rdi movq %rbx, %rsi movl %ebp, %edx callq 0x3b0e0 addl 0x274(%r14), %ebp addq $0x28, %r15 jmp 0xa93e5 incq %r12 cmpq 0x8(%rsp), %r12 jne 0xa93c8 addq $0x48, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
_ZN10OpenSubdiv6v3_6_03Tmr22SubdivisionPlanBuilder23initializeStencilMatrixERNS1_15SubdivisionPlanE: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 48h mov rbx, rsi mov r14, rdi movsxd rax, dword ptr [rdi+284h] movsxd rcx, dword ptr [rdi+28Ch] movsxd rdx, dword ptr [rdi+274h] imul rdx, rcx add rdx, rax add rbx, 70h ; 'p' movsxd rsi, dword ptr [rdi+280h] imul rsi, rdx lea rdx, [rsp+78h+var_68] mov dword ptr [rdx], 0 mov rdi, rbx call __ZNSt6vectorIfSaIfEE6resizeEmRKf; std::vector<float>::resize(ulong,float const&) mov rax, [r14+108h] mov rcx, [rax+68h] sub rcx, [rax+60h] sar rcx, 3 mov rdx, 0AAAAAAAAAAAAAAABh imul rdx, rcx mov [rsp+78h+var_70], rdx cmp edx, 2 jl loc_A938A lea rdi, [rsp+78h+var_38] mov [rdi], rax mov rax, [rbx] mov edx, [r14+280h] lea rcx, [rsp+78h+var_68] mov [rcx], rax mov [rcx+8], edx lea rdx, [rsp+78h+var_58] mov dword ptr [rdx], 0FFFFFFFFh mov esi, 1 call __ZNK10OpenSubdiv6v3_6_03Far18PrimvarRefinerRealIfE11InterpolateINS0_3Tmr10ControlRowENS5_10StencilRowIfEEEEviRKT_RT0_; OpenSubdiv::v3_6_0::Far::PrimvarRefinerReal<float>::Interpolate<OpenSubdiv::v3_6_0::Tmr::ControlRow,OpenSubdiv::v3_6_0::Tmr::StencilRow<float>>(int,OpenSubdiv::v3_6_0::Tmr::ControlRow const&,OpenSubdiv::v3_6_0::Tmr::StencilRow<float> &) cmp dword ptr [rsp+78h+var_70], 2 jz short loc_A938A mov r12, [rsp+78h+var_70] and r12d, 7FFFFFFFh mov r15d, 2 lea r13, [rsp+78h+var_58] lea rbp, [rsp+78h+var_68] loc_A9336: movups xmm0, [rsp+78h+var_68] movaps [rsp+78h+var_58], xmm0 mov rax, [r14+108h] mov rax, [rax+30h] mov rax, [rax+r15*8-8] movsxd rax, dword ptr [rax+8] movsxd rcx, dword ptr [rsp+78h+var_58+8] imul rax, rcx shl rax, 2 add rax, qword ptr [rsp+78h+var_58] mov qword ptr [rsp+78h+var_68], rax mov dword ptr [rsp+78h+var_68+8], ecx lea rdi, [rsp+78h+var_38] mov esi, r15d mov rdx, r13 mov rcx, rbp call __ZNK10OpenSubdiv6v3_6_03Far18PrimvarRefinerRealIfE11InterpolateINS0_3Tmr10StencilRowIfEES7_EEviRKT_RT0_; OpenSubdiv::v3_6_0::Far::PrimvarRefinerReal<float>::Interpolate<OpenSubdiv::v3_6_0::Tmr::StencilRow<float>,OpenSubdiv::v3_6_0::Tmr::StencilRow<float>>(int,OpenSubdiv::v3_6_0::Tmr::StencilRow<float> const&,OpenSubdiv::v3_6_0::Tmr::StencilRow<float> &) inc r15 cmp r12, r15 jnz short loc_A9336 loc_A938A: cmp dword ptr [r14+28Ch], 0 jle loc_A9423 cmp dword ptr [rsp+78h+var_70], 0 jle loc_A9423 mov ebp, [r14+284h] lea rax, [r14+118h] mov [rsp+78h+var_40], rax mov rax, [rsp+78h+var_70] and eax, 7FFFFFFFh mov [rsp+78h+var_70], rax xor r12d, r12d loc_A93C8: lea rax, [r12+r12*4] mov rcx, [rsp+78h+var_40] cmp dword ptr [rcx+rax*4+10h], 0 jz short loc_A9419 lea rax, [r12+r12*2] mov r15, [r14+rax*8] mov r13, [r14+rax*8+8] loc_A93E5: cmp r15, r13 jz short loc_A9419 mov eax, [r15+0Ch] not eax test al, 41h jnz short loc_A9413 mov rdi, r14 mov rsi, r15 call __ZN10OpenSubdiv6v3_6_03Tmr22SubdivisionPlanBuilder27getIrregularPatchConversionERKNS2_9ProtoNodeE; OpenSubdiv::v3_6_0::Tmr::SubdivisionPlanBuilder::getIrregularPatchConversion(OpenSubdiv::v3_6_0::Tmr::SubdivisionPlanBuilder::ProtoNode const&) mov rdi, r14 mov rsi, rbx mov edx, ebp call __ZN10OpenSubdiv6v3_6_03Tmr22SubdivisionPlanBuilder32appendConversionStencilsToMatrixERSt6vectorIfSaIfEEi; OpenSubdiv::v3_6_0::Tmr::SubdivisionPlanBuilder::appendConversionStencilsToMatrix(std::vector<float> &,int) add ebp, [r14+274h] loc_A9413: add r15, 28h ; '(' jmp short loc_A93E5 loc_A9419: inc r12 cmp r12, [rsp+78h+var_70] jnz short loc_A93C8 loc_A9423: add rsp, 48h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
long long OpenSubdiv::v3_6_0::Tmr::SubdivisionPlanBuilder::initializeStencilMatrix( OpenSubdiv::v3_6_0::Tmr::SubdivisionPlanBuilder *this, OpenSubdiv::v3_6_0::Tmr::SubdivisionPlan *a2) { long long *v2; // rbx long long v3; // rsi long long result; // rax int v5; // edx long long v6; // r15 int v7; // ebp long long v8; // r12 long long v9; // r15 long long v10; // r13 int v11; // [rsp+8h] [rbp-70h] long long v12; // [rsp+8h] [rbp-70h] __int128 v13; // [rsp+10h] [rbp-68h] BYREF __int128 v14; // [rsp+20h] [rbp-58h] BYREF char *v15; // [rsp+38h] [rbp-40h] _QWORD v16[7]; // [rsp+40h] [rbp-38h] BYREF v2 = (long long *)((char *)a2 + 112); v3 = (*((int *)this + 161) + *((int *)this + 163) * (long long)*((int *)this + 157)) * *((int *)this + 160); LODWORD(v13) = 0; std::vector<float>::resize(v2, v3, &v13); result = *((_QWORD *)this + 33); v11 = -1431655765 * ((long long)(*(_QWORD *)(result + 104) - *(_QWORD *)(result + 96)) >> 3); if ( v11 >= 2 ) { v16[0] = *((_QWORD *)this + 33); v5 = *((_DWORD *)this + 160); *(_QWORD *)&v13 = *v2; DWORD2(v13) = v5; LODWORD(v14) = -1; result = OpenSubdiv::v3_6_0::Far::PrimvarRefinerReal<float>::Interpolate<OpenSubdiv::v3_6_0::Tmr::ControlRow,OpenSubdiv::v3_6_0::Tmr::StencilRow<float>>( v16, 1LL, &v14); if ( v11 != 2 ) { v6 = 2LL; do { v14 = v13; *(_QWORD *)&v13 = v13 + 4 * SDWORD2(v13) * (long long)*(int *)(*(_QWORD *)(*(_QWORD *)(*((_QWORD *)this + 33) + 48LL) + 8 * v6 - 8) + 8LL); result = OpenSubdiv::v3_6_0::Far::PrimvarRefinerReal<float>::Interpolate<OpenSubdiv::v3_6_0::Tmr::StencilRow<float>,OpenSubdiv::v3_6_0::Tmr::StencilRow<float>>( v16, (unsigned int)v6++, &v14, &v13); } while ( (v11 & 0x7FFFFFFF) != v6 ); } } if ( *((int *)this + 163) > 0 && v11 > 0 ) { v7 = *((_DWORD *)this + 161); v15 = (char *)this + 280; v12 = v11 & 0x7FFFFFFF; v8 = 0LL; do { result = 5 * v8; if ( *(_DWORD *)&v15[20 * v8 + 16] ) { result = 3 * v8; v9 = *((_QWORD *)this + 3 * v8); v10 = *((_QWORD *)this + 3 * v8 + 1); while ( v9 != v10 ) { result = (unsigned int)~*(_DWORD *)(v9 + 12); if ( (~*(_BYTE *)(v9 + 12) & 0x41) == 0 ) { OpenSubdiv::v3_6_0::Tmr::SubdivisionPlanBuilder::getIrregularPatchConversion( (long long)this, (unsigned __int16 *)v9); result = OpenSubdiv::v3_6_0::Tmr::SubdivisionPlanBuilder::appendConversionStencilsToMatrix( (long long)this, v2, v7); v7 += *((_DWORD *)this + 157); } v9 += 40LL; } } ++v8; } while ( v8 != v12 ); } return result; }
initializeStencilMatrix: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x48 MOV RBX,RSI MOV R14,RDI MOVSXD RAX,dword ptr [RDI + 0x284] MOVSXD RCX,dword ptr [RDI + 0x28c] MOVSXD RDX,dword ptr [RDI + 0x274] IMUL RDX,RCX ADD RDX,RAX ADD RBX,0x70 MOVSXD RSI,dword ptr [RDI + 0x280] IMUL RSI,RDX LEA RDX,[RSP + 0x10] MOV dword ptr [RDX],0x0 MOV RDI,RBX CALL 0x0013a220 MOV RAX,qword ptr [R14 + 0x108] MOV RCX,qword ptr [RAX + 0x68] SUB RCX,qword ptr [RAX + 0x60] SAR RCX,0x3 MOV RDX,-0x5555555555555555 IMUL RDX,RCX MOV qword ptr [RSP + 0x8],RDX CMP EDX,0x2 JL 0x001a938a LEA RDI,[RSP + 0x40] MOV qword ptr [RDI],RAX MOV RAX,qword ptr [RBX] MOV EDX,dword ptr [R14 + 0x280] LEA RCX,[RSP + 0x10] MOV qword ptr [RCX],RAX MOV dword ptr [RCX + 0x8],EDX LEA RDX,[RSP + 0x20] MOV dword ptr [RDX],0xffffffff MOV ESI,0x1 CALL 0x00138990 CMP dword ptr [RSP + 0x8],0x2 JZ 0x001a938a MOV R12,qword ptr [RSP + 0x8] AND R12D,0x7fffffff MOV R15D,0x2 LEA R13,[RSP + 0x20] LEA RBP,[RSP + 0x10] LAB_001a9336: MOVUPS XMM0,xmmword ptr [RSP + 0x10] MOVAPS xmmword ptr [RSP + 0x20],XMM0 MOV RAX,qword ptr [R14 + 0x108] MOV RAX,qword ptr [RAX + 0x30] MOV RAX,qword ptr [RAX + R15*0x8 + -0x8] MOVSXD RAX,dword ptr [RAX + 0x8] MOVSXD RCX,dword ptr [RSP + 0x28] IMUL RAX,RCX SHL RAX,0x2 ADD RAX,qword ptr [RSP + 0x20] MOV qword ptr [RSP + 0x10],RAX MOV dword ptr [RSP + 0x18],ECX LEA RDI,[RSP + 0x40] MOV ESI,R15D MOV RDX,R13 MOV RCX,RBP CALL 0x0013a8e0 INC R15 CMP R12,R15 JNZ 0x001a9336 LAB_001a938a: CMP dword ptr [R14 + 0x28c],0x0 JLE 0x001a9423 CMP dword ptr [RSP + 0x8],0x0 JLE 0x001a9423 MOV EBP,dword ptr [R14 + 0x284] LEA RAX,[R14 + 0x118] MOV qword ptr [RSP + 0x38],RAX MOV RAX,qword ptr [RSP + 0x8] AND EAX,0x7fffffff MOV qword ptr [RSP + 0x8],RAX XOR R12D,R12D LAB_001a93c8: LEA RAX,[R12 + R12*0x4] MOV RCX,qword ptr [RSP + 0x38] CMP dword ptr [RCX + RAX*0x4 + 0x10],0x0 JZ 0x001a9419 LEA RAX,[R12 + R12*0x2] MOV R15,qword ptr [R14 + RAX*0x8] MOV R13,qword ptr [R14 + RAX*0x8 + 0x8] LAB_001a93e5: CMP R15,R13 JZ 0x001a9419 MOV EAX,dword ptr [R15 + 0xc] NOT EAX TEST AL,0x41 JNZ 0x001a9413 MOV RDI,R14 MOV RSI,R15 CALL 0x00139610 MOV RDI,R14 MOV RSI,RBX MOV EDX,EBP CALL 0x0013b0e0 ADD EBP,dword ptr [R14 + 0x274] LAB_001a9413: ADD R15,0x28 JMP 0x001a93e5 LAB_001a9419: INC R12 CMP R12,qword ptr [RSP + 0x8] JNZ 0x001a93c8 LAB_001a9423: ADD RSP,0x48 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
/* OpenSubdiv::v3_6_0::Tmr::SubdivisionPlanBuilder::initializeStencilMatrix(OpenSubdiv::v3_6_0::Tmr::SubdivisionPlan&) */ void __thiscall OpenSubdiv::v3_6_0::Tmr::SubdivisionPlanBuilder::initializeStencilMatrix (SubdivisionPlanBuilder *this,SubdivisionPlan *param_1) { long lVar1; ProtoNode *pPVar2; uint uVar3; vector<float,std::allocator<float>> *this_00; int iVar4; ulong uVar5; ProtoNode *pPVar6; ulong local_68; int iStack_60; int4 uStack_5c; ulong local_58; int8 uStack_50; SubdivisionPlanBuilder *local_40; long local_38; this_00 = (vector<float,std::allocator<float>> *)(param_1 + 0x70); local_68 = local_68 & 0xffffffff00000000; std::vector<float,std::allocator<float>>::resize (this_00,(long)*(int *)(this + 0x280) * ((long)*(int *)(this + 0x274) * (long)*(int *)(this + 0x28c) + (long)*(int *)(this + 0x284)),(float *)&local_68); lVar1 = *(long *)(this + 0x108); uVar3 = (int)(*(long *)(lVar1 + 0x68) - *(long *)(lVar1 + 0x60) >> 3) * -0x55555555; if (1 < (int)uVar3) { local_68 = *(ulong *)this_00; iStack_60 = *(int *)(this + 0x280); local_58 = CONCAT44(local_58._4_4_,0xffffffff); local_38 = lVar1; Far::PrimvarRefinerReal<float>:: Interpolate<OpenSubdiv::v3_6_0::Tmr::ControlRow,OpenSubdiv::v3_6_0::Tmr::StencilRow<float>> ((PrimvarRefinerReal<float> *)&local_38,1,(ControlRow *)&local_58, (StencilRow *)&local_68); if (uVar3 != 2) { uVar5 = 2; do { uStack_50 = CONCAT44(uStack_5c,iStack_60); local_58 = local_68; local_68 = (long)*(int *)(*(long *)(*(long *)(*(long *)(this + 0x108) + 0x30) + -8 + uVar5 * 8) + 8) * (long)iStack_60 * 4 + local_68; Far::PrimvarRefinerReal<float>:: Interpolate<OpenSubdiv::v3_6_0::Tmr::StencilRow<float>,OpenSubdiv::v3_6_0::Tmr::StencilRow<float>> ((PrimvarRefinerReal<float> *)&local_38,(int)uVar5,(StencilRow *)&local_58, (StencilRow *)&local_68); uVar5 = uVar5 + 1; } while ((uVar3 & 0x7fffffff) != uVar5); } } if ((0 < *(int *)(this + 0x28c)) && (0 < (int)uVar3)) { iVar4 = *(int *)(this + 0x284); local_40 = this + 0x118; uVar5 = 0; do { if (*(int *)(local_40 + uVar5 * 0x14 + 0x10) != 0) { pPVar2 = *(ProtoNode **)(this + uVar5 * 0x18 + 8); for (pPVar6 = *(ProtoNode **)(this + uVar5 * 0x18); pPVar6 != pPVar2; pPVar6 = pPVar6 + 0x28 ) { if ((~*(uint *)(pPVar6 + 0xc) & 0x41) == 0) { getIrregularPatchConversion(this,pPVar6); appendConversionStencilsToMatrix(this,(vector *)this_00,iVar4); iVar4 = iVar4 + *(int *)(this + 0x274); } } } uVar5 = uVar5 + 1; } while (uVar5 != (uVar3 & 0x7fffffff)); } return; }
31,807
OpenSubdiv::v3_6_0::Tmr::SubdivisionPlanBuilder::initializeStencilMatrix(OpenSubdiv::v3_6_0::Tmr::SubdivisionPlan&)
NVIDIA-RTX[P]OSD-Lite/opensubdiv/tmr/subdivisionPlanBuilder.cpp
void SubdivisionPlanBuilder::initializeStencilMatrix(SubdivisionPlan& plan) { int numPointStencils = _numRefinedPoints + (_numIrregularPatchesTotal * _irregularPatchSize); std::vector<float>& stencilMatrix = plan._stencilMatrix; stencilMatrix.resize(numPointStencils * _numControlPoints, 0.f); // For refined points, initialize successive rows of the stencil matrix // a level at a time using the PrimvarRefiner to accumulate contributing // rows: int numLevels = _faceRefiner->GetNumLevels(); if (numLevels > 1) { Far::PrimvarRefinerReal<float> primvarRefiner(*_faceRefiner); StencilRow<float> dstRow(&stencilMatrix[0], _numControlPoints); primvarRefiner.Interpolate(1, ControlRow(-1), dstRow); for (int level = 2; level < numLevels; ++level) { StencilRow<float> srcRow = dstRow; dstRow = srcRow[_faceRefiner->getLevel(level-1).getNumVertices()]; primvarRefiner.Interpolate(level, srcRow, dstRow); } } // For irregular patch points, append rows for each irregular patch: if (_numIrregularPatchesTotal > 0) { Index stencilIndexBase = _numRefinedPoints; for (int level = 0; level < numLevels; ++level) { if (_levelOffsets[level].numIrregularPatches == 0) continue; for (ProtoNode const& pn : _protoNodeStore[level]) { if (!pn.active || !pn.hasIrregularPatch) continue; getIrregularPatchConversion(pn); appendConversionStencilsToMatrix(stencilMatrix, stencilIndexBase); stencilIndexBase += _irregularPatchSize; } } } }
O2
cpp
OpenSubdiv::v3_6_0::Tmr::SubdivisionPlanBuilder::initializeStencilMatrix(OpenSubdiv::v3_6_0::Tmr::SubdivisionPlan&): pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x48, %rsp movq %rsi, %rbx movq %rdi, %r14 movslq 0x284(%rdi), %rax movslq 0x28c(%rdi), %rcx movslq 0x274(%rdi), %rdx imulq %rcx, %rdx addq %rax, %rdx addq $0x70, %rbx movslq 0x280(%rdi), %rsi imulq %rdx, %rsi leaq 0x10(%rsp), %rdx andl $0x0, (%rdx) movq %rbx, %rdi callq 0x52780 movq 0x108(%r14), %rcx movq 0x68(%rcx), %rax subq 0x60(%rcx), %rax pushq $0x18 popq %rsi cqto idivq %rsi movq %rax, %r15 cmpl $0x2, %r15d jl 0xb3fa7 leaq 0x40(%rsp), %rdi movq %rcx, (%rdi) movq (%rbx), %rax movl 0x280(%r14), %ecx leaq 0x10(%rsp), %r13 movq %rax, (%r13) movl %ecx, 0x8(%r13) leaq 0x20(%rsp), %rbp orl $-0x1, (%rbp) pushq $0x1 popq %rsi movq %rbp, %rdx movq %r13, %rcx callq 0x4ff50 movq %r15, 0x8(%rsp) movl %r15d, %r12d andl $0x7fffffff, %r12d # imm = 0x7FFFFFFF pushq $0x2 popq %r15 cmpq %r15, %r12 je 0xb3fa2 movups 0x10(%rsp), %xmm0 movaps %xmm0, 0x20(%rsp) movq 0x108(%r14), %rax movq 0x30(%rax), %rax movq -0x8(%rax,%r15,8), %rax movslq 0x8(%rax), %rax movslq 0x28(%rsp), %rcx imulq %rcx, %rax shlq $0x2, %rax addq 0x20(%rsp), %rax movq %rax, 0x10(%rsp) movl %ecx, 0x18(%rsp) leaq 0x40(%rsp), %rdi movl %r15d, %esi movq %rbp, %rdx movq %r13, %rcx callq 0x532e0 incq %r15 jmp 0xb3f4c movq 0x8(%rsp), %r15 cmpl $0x0, 0x28c(%r14) jle 0xb4039 movl 0x284(%r14), %ebp leaq 0x118(%r14), %rax movq %rax, 0x38(%rsp) xorl %r13d, %r13d testl %r15d, %r15d movl $0x0, %eax cmovgl %r15d, %eax movq %rax, 0x8(%rsp) cmpq 0x8(%rsp), %r13 je 0xb4039 imulq $0x14, %r13, %rax movq 0x38(%rsp), %rcx cmpl $0x0, 0x10(%rcx,%rax) je 0xb4034 imulq $0x18, %r13, %rax movq (%r14,%rax), %r15 movq 0x8(%r14,%rax), %r12 cmpq %r12, %r15 je 0xb4034 movl 0xc(%r15), %eax notl %eax testb $0x41, %al jne 0xb402e movq %r14, %rdi movq %r15, %rsi callq 0x51400 movq %r14, %rdi movq %rbx, %rsi movl %ebp, %edx callq 0x53f80 addl 0x274(%r14), %ebp addq $0x28, %r15 jmp 0xb4000 incq %r13 jmp 0xb3fdc addq $0x48, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
_ZN10OpenSubdiv6v3_6_03Tmr22SubdivisionPlanBuilder23initializeStencilMatrixERNS1_15SubdivisionPlanE: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 48h mov rbx, rsi mov r14, rdi movsxd rax, dword ptr [rdi+284h] movsxd rcx, dword ptr [rdi+28Ch] movsxd rdx, dword ptr [rdi+274h] imul rdx, rcx add rdx, rax add rbx, 70h ; 'p' movsxd rsi, dword ptr [rdi+280h] imul rsi, rdx lea rdx, [rsp+78h+var_68] and dword ptr [rdx], 0 mov rdi, rbx call __ZNSt6vectorIfSaIfEE6resizeEmRKf; std::vector<float>::resize(ulong,float const&) mov rcx, [r14+108h] mov rax, [rcx+68h] sub rax, [rcx+60h] push 18h pop rsi cqo idiv rsi mov r15, rax cmp r15d, 2 jl loc_B3FA7 lea rdi, [rsp+78h+var_38]; int mov [rdi], rcx mov rax, [rbx] mov ecx, [r14+280h] lea r13, [rsp+78h+var_68] mov [r13+0], rax mov [r13+8], ecx lea rbp, [rsp+78h+var_58] or dword ptr [rbp+0], 0FFFFFFFFh push 1 pop rsi; int mov rdx, rbp; int mov rcx, r13; int call __ZNK10OpenSubdiv6v3_6_03Far18PrimvarRefinerRealIfE11InterpolateINS0_3Tmr10ControlRowENS5_10StencilRowIfEEEEviRKT_RT0_; OpenSubdiv::v3_6_0::Far::PrimvarRefinerReal<float>::Interpolate<OpenSubdiv::v3_6_0::Tmr::ControlRow,OpenSubdiv::v3_6_0::Tmr::StencilRow<float>>(int,OpenSubdiv::v3_6_0::Tmr::ControlRow const&,OpenSubdiv::v3_6_0::Tmr::StencilRow<float> &) mov [rsp+78h+var_70], r15 mov r12d, r15d and r12d, 7FFFFFFFh push 2 pop r15 loc_B3F4C: cmp r12, r15 jz short loc_B3FA2 movups xmm0, xmmword ptr [rsp+78h+var_68] movaps xmmword ptr [rsp+78h+var_58], xmm0 mov rax, [r14+108h] mov rax, [rax+30h] mov rax, [rax+r15*8-8] movsxd rax, dword ptr [rax+8] movsxd rcx, [rsp+78h+var_58+8] imul rax, rcx shl rax, 2 add rax, qword ptr [rsp+78h+var_58] mov qword ptr [rsp+78h+var_68], rax mov [rsp+78h+var_68+8], ecx lea rdi, [rsp+78h+var_38]; int mov esi, r15d; int mov rdx, rbp; int mov rcx, r13; int call __ZNK10OpenSubdiv6v3_6_03Far18PrimvarRefinerRealIfE11InterpolateINS0_3Tmr10StencilRowIfEES7_EEviRKT_RT0_; OpenSubdiv::v3_6_0::Far::PrimvarRefinerReal<float>::Interpolate<OpenSubdiv::v3_6_0::Tmr::StencilRow<float>,OpenSubdiv::v3_6_0::Tmr::StencilRow<float>>(int,OpenSubdiv::v3_6_0::Tmr::StencilRow<float> const&,OpenSubdiv::v3_6_0::Tmr::StencilRow<float> &) inc r15 jmp short loc_B3F4C loc_B3FA2: mov r15, [rsp+78h+var_70] loc_B3FA7: cmp dword ptr [r14+28Ch], 0 jle loc_B4039 mov ebp, [r14+284h] lea rax, [r14+118h] mov [rsp+78h+var_40], rax xor r13d, r13d test r15d, r15d mov eax, 0 cmovg eax, r15d mov [rsp+78h+var_70], rax loc_B3FDC: cmp r13, [rsp+78h+var_70] jz short loc_B4039 imul rax, r13, 14h mov rcx, [rsp+78h+var_40] cmp dword ptr [rcx+rax+10h], 0 jz short loc_B4034 imul rax, r13, 18h mov r15, [r14+rax] mov r12, [r14+rax+8] loc_B4000: cmp r15, r12 jz short loc_B4034 mov eax, [r15+0Ch] not eax test al, 41h jnz short loc_B402E mov rdi, r14 mov rsi, r15 call __ZN10OpenSubdiv6v3_6_03Tmr22SubdivisionPlanBuilder27getIrregularPatchConversionERKNS2_9ProtoNodeE; OpenSubdiv::v3_6_0::Tmr::SubdivisionPlanBuilder::getIrregularPatchConversion(OpenSubdiv::v3_6_0::Tmr::SubdivisionPlanBuilder::ProtoNode const&) mov rdi, r14 mov rsi, rbx mov edx, ebp call __ZN10OpenSubdiv6v3_6_03Tmr22SubdivisionPlanBuilder32appendConversionStencilsToMatrixERSt6vectorIfSaIfEEi; OpenSubdiv::v3_6_0::Tmr::SubdivisionPlanBuilder::appendConversionStencilsToMatrix(std::vector<float> &,int) add ebp, [r14+274h] loc_B402E: add r15, 28h ; '(' jmp short loc_B4000 loc_B4034: inc r13 jmp short loc_B3FDC loc_B4039: add rsp, 48h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
long long OpenSubdiv::v3_6_0::Tmr::SubdivisionPlanBuilder::initializeStencilMatrix( OpenSubdiv::v3_6_0::Tmr::SubdivisionPlanBuilder *this, OpenSubdiv::v3_6_0::Tmr::SubdivisionPlan *a2) { long long *v2; // rbx long long v3; // rsi long long result; // rax int v5; // r15d int v6; // ecx long long v7; // r12 long long i; // r15 int v9; // ebp long long v10; // r13 long long v11; // r15 long long v12; // r12 int v13; // [rsp+8h] [rbp-70h] long long v14; // [rsp+8h] [rbp-70h] int v15[4]; // [rsp+10h] [rbp-68h] BYREF int v16[6]; // [rsp+20h] [rbp-58h] BYREF char *v17; // [rsp+38h] [rbp-40h] _QWORD v18[7]; // [rsp+40h] [rbp-38h] BYREF v2 = (long long *)((char *)a2 + 112); v3 = (*((int *)this + 161) + *((int *)this + 163) * (long long)*((int *)this + 157)) * *((int *)this + 160); v15[0] = 0; std::vector<float>::resize(v2, v3, v15); result = (*(_QWORD *)(*((_QWORD *)this + 33) + 104LL) - *(_QWORD *)(*((_QWORD *)this + 33) + 96LL)) / 24LL; v5 = result; if ( (int)result >= 2 ) { v18[0] = *((_QWORD *)this + 33); v6 = *((_DWORD *)this + 160); *(_QWORD *)v15 = *v2; v15[2] = v6; v16[0] = -1; result = OpenSubdiv::v3_6_0::Far::PrimvarRefinerReal<float>::Interpolate<OpenSubdiv::v3_6_0::Tmr::ControlRow,OpenSubdiv::v3_6_0::Tmr::StencilRow<float>>( (int)v18, 1, (int)v16, (int)v15); v13 = v5; v7 = v5 & 0x7FFFFFFF; for ( i = 2LL; v7 != i; ++i ) { *(_OWORD *)v16 = *(_OWORD *)v15; *(_QWORD *)v15 += 4 * v15[2] * (long long)*(int *)(*(_QWORD *)(*(_QWORD *)(*((_QWORD *)this + 33) + 48LL) + 8 * i - 8) + 8LL); result = OpenSubdiv::v3_6_0::Far::PrimvarRefinerReal<float>::Interpolate<OpenSubdiv::v3_6_0::Tmr::StencilRow<float>,OpenSubdiv::v3_6_0::Tmr::StencilRow<float>>( (int)v18, i, (int)v16, (int)v15); } v5 = v13; } if ( *((int *)this + 163) > 0 ) { v9 = *((_DWORD *)this + 161); v17 = (char *)this + 280; v10 = 0LL; result = 0LL; if ( v5 > 0 ) result = (unsigned int)v5; v14 = result; while ( v10 != v14 ) { result = 20 * v10; if ( *(_DWORD *)&v17[20 * v10 + 16] ) { result = 24 * v10; v11 = *((_QWORD *)this + 3 * v10); v12 = *((_QWORD *)this + 3 * v10 + 1); while ( v11 != v12 ) { result = (unsigned int)~*(_DWORD *)(v11 + 12); if ( (~*(_BYTE *)(v11 + 12) & 0x41) == 0 ) { OpenSubdiv::v3_6_0::Tmr::SubdivisionPlanBuilder::getIrregularPatchConversion( (long long)this, (unsigned __int16 *)v11); result = OpenSubdiv::v3_6_0::Tmr::SubdivisionPlanBuilder::appendConversionStencilsToMatrix( (long long)this, v2, v9); v9 += *((_DWORD *)this + 157); } v11 += 40LL; } } ++v10; } } return result; }
initializeStencilMatrix: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x48 MOV RBX,RSI MOV R14,RDI MOVSXD RAX,dword ptr [RDI + 0x284] MOVSXD RCX,dword ptr [RDI + 0x28c] MOVSXD RDX,dword ptr [RDI + 0x274] IMUL RDX,RCX ADD RDX,RAX ADD RBX,0x70 MOVSXD RSI,dword ptr [RDI + 0x280] IMUL RSI,RDX LEA RDX,[RSP + 0x10] AND dword ptr [RDX],0x0 MOV RDI,RBX CALL 0x00152780 MOV RCX,qword ptr [R14 + 0x108] MOV RAX,qword ptr [RCX + 0x68] SUB RAX,qword ptr [RCX + 0x60] PUSH 0x18 POP RSI CQO IDIV RSI MOV R15,RAX CMP R15D,0x2 JL 0x001b3fa7 LEA RDI,[RSP + 0x40] MOV qword ptr [RDI],RCX MOV RAX,qword ptr [RBX] MOV ECX,dword ptr [R14 + 0x280] LEA R13,[RSP + 0x10] MOV qword ptr [R13],RAX MOV dword ptr [R13 + 0x8],ECX LEA RBP,[RSP + 0x20] OR dword ptr [RBP],0xffffffff PUSH 0x1 POP RSI MOV RDX,RBP MOV RCX,R13 CALL 0x0014ff50 MOV qword ptr [RSP + 0x8],R15 MOV R12D,R15D AND R12D,0x7fffffff PUSH 0x2 POP R15 LAB_001b3f4c: CMP R12,R15 JZ 0x001b3fa2 MOVUPS XMM0,xmmword ptr [RSP + 0x10] MOVAPS xmmword ptr [RSP + 0x20],XMM0 MOV RAX,qword ptr [R14 + 0x108] MOV RAX,qword ptr [RAX + 0x30] MOV RAX,qword ptr [RAX + R15*0x8 + -0x8] MOVSXD RAX,dword ptr [RAX + 0x8] MOVSXD RCX,dword ptr [RSP + 0x28] IMUL RAX,RCX SHL RAX,0x2 ADD RAX,qword ptr [RSP + 0x20] MOV qword ptr [RSP + 0x10],RAX MOV dword ptr [RSP + 0x18],ECX LEA RDI,[RSP + 0x40] MOV ESI,R15D MOV RDX,RBP MOV RCX,R13 CALL 0x001532e0 INC R15 JMP 0x001b3f4c LAB_001b3fa2: MOV R15,qword ptr [RSP + 0x8] LAB_001b3fa7: CMP dword ptr [R14 + 0x28c],0x0 JLE 0x001b4039 MOV EBP,dword ptr [R14 + 0x284] LEA RAX,[R14 + 0x118] MOV qword ptr [RSP + 0x38],RAX XOR R13D,R13D TEST R15D,R15D MOV EAX,0x0 CMOVG EAX,R15D MOV qword ptr [RSP + 0x8],RAX LAB_001b3fdc: CMP R13,qword ptr [RSP + 0x8] JZ 0x001b4039 IMUL RAX,R13,0x14 MOV RCX,qword ptr [RSP + 0x38] CMP dword ptr [RCX + RAX*0x1 + 0x10],0x0 JZ 0x001b4034 IMUL RAX,R13,0x18 MOV R15,qword ptr [R14 + RAX*0x1] MOV R12,qword ptr [R14 + RAX*0x1 + 0x8] LAB_001b4000: CMP R15,R12 JZ 0x001b4034 MOV EAX,dword ptr [R15 + 0xc] NOT EAX TEST AL,0x41 JNZ 0x001b402e MOV RDI,R14 MOV RSI,R15 CALL 0x00151400 MOV RDI,R14 MOV RSI,RBX MOV EDX,EBP CALL 0x00153f80 ADD EBP,dword ptr [R14 + 0x274] LAB_001b402e: ADD R15,0x28 JMP 0x001b4000 LAB_001b4034: INC R13 JMP 0x001b3fdc LAB_001b4039: ADD RSP,0x48 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
/* OpenSubdiv::v3_6_0::Tmr::SubdivisionPlanBuilder::initializeStencilMatrix(OpenSubdiv::v3_6_0::Tmr::SubdivisionPlan&) */ void __thiscall OpenSubdiv::v3_6_0::Tmr::SubdivisionPlanBuilder::initializeStencilMatrix (SubdivisionPlanBuilder *this,SubdivisionPlan *param_1) { long lVar1; ProtoNode *pPVar2; ulong uVar3; vector<float,std::allocator<float>> *this_00; int iVar4; ulong uVar5; uint uVar6; ulong uVar7; ProtoNode *pPVar8; ulong local_68; int iStack_60; int4 uStack_5c; ulong local_58; int8 uStack_50; SubdivisionPlanBuilder *local_40; long local_38; this_00 = (vector<float,std::allocator<float>> *)(param_1 + 0x70); local_68 = local_68 & 0xffffffff00000000; std::vector<float,std::allocator<float>>::resize (this_00,(long)*(int *)(this + 0x280) * ((long)*(int *)(this + 0x274) * (long)*(int *)(this + 0x28c) + (long)*(int *)(this + 0x284)),(float *)&local_68); lVar1 = *(long *)(this + 0x108); uVar3 = (*(long *)(lVar1 + 0x68) - *(long *)(lVar1 + 0x60)) / 0x18; uVar6 = (uint)uVar3; if (1 < (int)uVar6) { local_68 = *(ulong *)this_00; iStack_60 = *(int *)(this + 0x280); local_58 = CONCAT44(local_58._4_4_,0xffffffff); local_38 = lVar1; Far::PrimvarRefinerReal<float>:: Interpolate<OpenSubdiv::v3_6_0::Tmr::ControlRow,OpenSubdiv::v3_6_0::Tmr::StencilRow<float>> ((PrimvarRefinerReal<float> *)&local_38,1,(ControlRow *)&local_58, (StencilRow *)&local_68); for (uVar7 = 2; (uVar6 & 0x7fffffff) != uVar7; uVar7 = uVar7 + 1) { uStack_50 = CONCAT44(uStack_5c,iStack_60); local_58 = local_68; local_68 = (long)*(int *)(*(long *)(*(long *)(*(long *)(this + 0x108) + 0x30) + -8 + uVar7 * 8 ) + 8) * (long)iStack_60 * 4 + local_68; Far::PrimvarRefinerReal<float>:: Interpolate<OpenSubdiv::v3_6_0::Tmr::StencilRow<float>,OpenSubdiv::v3_6_0::Tmr::StencilRow<float>> ((PrimvarRefinerReal<float> *)&local_38,(int)uVar7,(StencilRow *)&local_58, (StencilRow *)&local_68); } } if (0 < *(int *)(this + 0x28c)) { iVar4 = *(int *)(this + 0x284); local_40 = this + 0x118; uVar5 = 0; uVar7 = 0; if (0 < (int)uVar6) { uVar7 = uVar3 & 0xffffffff; } for (; uVar5 != uVar7; uVar5 = uVar5 + 1) { if (*(int *)(local_40 + uVar5 * 0x14 + 0x10) != 0) { pPVar2 = *(ProtoNode **)(this + uVar5 * 0x18 + 8); for (pPVar8 = *(ProtoNode **)(this + uVar5 * 0x18); pPVar8 != pPVar2; pPVar8 = pPVar8 + 0x28 ) { if ((~*(uint *)(pPVar8 + 0xc) & 0x41) == 0) { getIrregularPatchConversion(this,pPVar8); appendConversionStencilsToMatrix(this,(vector *)this_00,iVar4); iVar4 = iVar4 + *(int *)(this + 0x274); } } } } } return; }
31,808
ma_search_last
eloqsql/storage/maria/ma_search.c
int _ma_search_last(MARIA_HA *info, MARIA_KEYDEF *keyinfo, my_off_t pos) { uchar *end_of_page; MARIA_PAGE page; DBUG_ENTER("_ma_search_last"); if (pos == HA_OFFSET_ERROR) { my_errno=HA_ERR_KEY_NOT_FOUND; /* Didn't find key */ info->cur_row.lastpos= HA_OFFSET_ERROR; DBUG_RETURN(-1); } do { if (_ma_fetch_keypage(&page, info, keyinfo, pos, PAGECACHE_LOCK_LEFT_UNLOCKED, DFLT_INIT_HITS, info->keyread_buff, 0)) { info->cur_row.lastpos= HA_OFFSET_ERROR; DBUG_RETURN(-1); } end_of_page= page.buff + page.size; } while ((pos= _ma_kpos(page.node, end_of_page)) != HA_OFFSET_ERROR); if (!_ma_get_last_key(&info->last_key, &page, end_of_page)) DBUG_RETURN(-1); info->cur_row.lastpos= _ma_row_pos_from_key(&info->last_key); info->cur_row.trid= _ma_trid_from_key(&info->last_key); info->int_keypos= info->int_maxpos= end_of_page; info->int_nod_flag= page.node; info->int_keytree_version= keyinfo->version; info->last_search_keypage= info->last_keypage; info->page_changed=info->keyread_buff_used=0; DBUG_PRINT("exit",("found key at %lu",(ulong) info->cur_row.lastpos)); DBUG_RETURN(0); }
O0
c
ma_search_last: pushq %rbp movq %rsp, %rbp subq $0x70, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq %rdx, -0x20(%rbp) cmpq $-0x1, -0x20(%rbp) jne 0x6d481 callq 0xf60c0 movl $0x78, (%rax) movq -0x10(%rbp), %rax movq $-0x1, 0x98(%rax) movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF jmp 0x6d5d5 jmp 0x6d483 movq -0x10(%rbp), %rsi movq -0x18(%rbp), %rdx movq -0x20(%rbp), %rcx movq -0x10(%rbp), %rax movq 0x380(%rax), %rax leaq -0x60(%rbp), %rdi xorl %r8d, %r8d movl $0x3, %r9d movq %rax, (%rsp) movl $0x0, 0x8(%rsp) callq 0x6ee50 cmpb $0x0, %al je 0x6d4d7 movq -0x10(%rbp), %rax movq $-0x1, 0x98(%rax) movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF jmp 0x6d5d5 movq -0x50(%rbp), %rax movl -0x40(%rbp), %ecx addq %rcx, %rax movq %rax, -0x28(%rbp) movl -0x38(%rbp), %edi movq -0x28(%rbp), %rsi callq 0x6ab60 movq %rax, -0x20(%rbp) cmpq $-0x1, %rax jne 0x6d483 movq -0x10(%rbp), %rdi addq $0x200, %rdi # imm = 0x200 movq -0x28(%rbp), %rdx leaq -0x60(%rbp), %rsi callq 0x6c980 cmpq $0x0, %rax jne 0x6d527 jmp 0x6d51b movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF jmp 0x6d5d5 movq -0x10(%rbp), %rdi addq $0x200, %rdi # imm = 0x200 callq 0x6b050 movq %rax, %rcx movq -0x10(%rbp), %rax movq %rcx, 0x98(%rax) movq -0x10(%rbp), %rdi addq $0x200, %rdi # imm = 0x200 callq 0x6b200 movq %rax, %rcx movq -0x10(%rbp), %rax movq %rcx, 0xc0(%rax) movq -0x28(%rbp), %rcx movq -0x10(%rbp), %rax movq %rcx, 0x3b8(%rax) movq -0x10(%rbp), %rax movq %rcx, 0x3b0(%rax) movl -0x38(%rbp), %ecx movq -0x10(%rbp), %rax movl %ecx, 0x3d0(%rax) movq -0x18(%rbp), %rax movl 0xb8(%rax), %ecx movq -0x10(%rbp), %rax movl %ecx, 0x3d4(%rax) movq -0x10(%rbp), %rax movq 0x440(%rax), %rcx movq -0x10(%rbp), %rax movq %rcx, 0x448(%rax) movq -0x10(%rbp), %rax movb $0x0, 0x685(%rax) movq -0x10(%rbp), %rax movb $0x0, 0x684(%rax) jmp 0x6d5cc jmp 0x6d5ce movl $0x0, -0x4(%rbp) movl -0x4(%rbp), %eax addq $0x70, %rsp popq %rbp retq nop
_ma_search_last: push rbp mov rbp, rsp sub rsp, 70h mov [rbp+var_10], rdi mov [rbp+var_18], rsi mov [rbp+var_20], rdx cmp [rbp+var_20], 0FFFFFFFFFFFFFFFFh jnz short loc_6D481 call _my_thread_var mov dword ptr [rax], 78h ; 'x' mov rax, [rbp+var_10] mov qword ptr [rax+98h], 0FFFFFFFFFFFFFFFFh mov [rbp+var_4], 0FFFFFFFFh jmp loc_6D5D5 loc_6D481: jmp short $+2 loc_6D483: mov rsi, [rbp+var_10] mov rdx, [rbp+var_18] mov rcx, [rbp+var_20] mov rax, [rbp+var_10] mov rax, [rax+380h] lea rdi, [rbp+var_60] xor r8d, r8d mov r9d, 3 mov [rsp+70h+var_70], rax mov [rsp+70h+var_68], 0 call _ma_fetch_keypage cmp al, 0 jz short loc_6D4D7 mov rax, [rbp+var_10] mov qword ptr [rax+98h], 0FFFFFFFFFFFFFFFFh mov [rbp+var_4], 0FFFFFFFFh jmp loc_6D5D5 loc_6D4D7: mov rax, [rbp+var_50] mov ecx, [rbp+var_40] add rax, rcx mov [rbp+var_28], rax mov edi, [rbp+var_38] mov rsi, [rbp+var_28] call _ma_kpos mov [rbp+var_20], rax cmp rax, 0FFFFFFFFFFFFFFFFh jnz short loc_6D483 mov rdi, [rbp+var_10] add rdi, 200h mov rdx, [rbp+var_28] lea rsi, [rbp+var_60] call _ma_get_last_key cmp rax, 0 jnz short loc_6D527 jmp short $+2 loc_6D51B: mov [rbp+var_4], 0FFFFFFFFh jmp loc_6D5D5 loc_6D527: mov rdi, [rbp+var_10] add rdi, 200h call _ma_row_pos_from_key mov rcx, rax mov rax, [rbp+var_10] mov [rax+98h], rcx mov rdi, [rbp+var_10] add rdi, 200h call _ma_trid_from_key mov rcx, rax mov rax, [rbp+var_10] mov [rax+0C0h], rcx mov rcx, [rbp+var_28] mov rax, [rbp+var_10] mov [rax+3B8h], rcx mov rax, [rbp+var_10] mov [rax+3B0h], rcx mov ecx, [rbp+var_38] mov rax, [rbp+var_10] mov [rax+3D0h], ecx mov rax, [rbp+var_18] mov ecx, [rax+0B8h] mov rax, [rbp+var_10] mov [rax+3D4h], ecx mov rax, [rbp+var_10] mov rcx, [rax+440h] mov rax, [rbp+var_10] mov [rax+448h], rcx mov rax, [rbp+var_10] mov byte ptr [rax+685h], 0 mov rax, [rbp+var_10] mov byte ptr [rax+684h], 0 jmp short $+2 loc_6D5CC: jmp short $+2 loc_6D5CE: mov [rbp+var_4], 0 loc_6D5D5: mov eax, [rbp+var_4] add rsp, 70h pop rbp retn
long long ma_search_last(long long a1, const char *a2, long long a3) { long long v3; // rax unsigned long long v4; // rax unsigned long long v5; // rcx _BYTE v7[16]; // [rsp+10h] [rbp-60h] BYREF long long v8; // [rsp+20h] [rbp-50h] unsigned int v9; // [rsp+30h] [rbp-40h] unsigned int v10; // [rsp+38h] [rbp-38h] unsigned long long v11; // [rsp+48h] [rbp-28h] long long v12; // [rsp+50h] [rbp-20h] const char *v13; // [rsp+58h] [rbp-18h] long long v14; // [rsp+60h] [rbp-10h] v14 = a1; v13 = a2; v12 = a3; if ( a3 == -1 ) { *(_DWORD *)my_thread_var(a1, a2) = 120; *(_QWORD *)(v14 + 152) = -1LL; return (unsigned int)-1; } else { do { if ( (unsigned __int8)ma_fetch_keypage((unsigned int)v7, v14, (_DWORD)v13, v12, 0, 3, *(_QWORD *)(v14 + 896), 0) ) { *(_QWORD *)(v14 + 152) = -1LL; return (unsigned int)-1; } v11 = v9 + v8; v12 = ma_kpos(v10, v11); } while ( v12 != -1 ); if ( ma_get_last_key(v14 + 512, (long long)v7, v11) ) { v3 = ma_row_pos_from_key(v14 + 512); *(_QWORD *)(v14 + 152) = v3; v4 = ma_trid_from_key(v14 + 512); *(_QWORD *)(v14 + 192) = v4; v5 = v11; *(_QWORD *)(v14 + 952) = v11; *(_QWORD *)(v14 + 944) = v5; *(_DWORD *)(v14 + 976) = v10; *(_DWORD *)(v14 + 980) = *((_DWORD *)v13 + 46); *(_QWORD *)(v14 + 1096) = *(_QWORD *)(v14 + 1088); *(_BYTE *)(v14 + 1669) = 0; *(_BYTE *)(v14 + 1668) = 0; return 0; } else { return (unsigned int)-1; } } }
_ma_search_last: PUSH RBP MOV RBP,RSP SUB RSP,0x70 MOV qword ptr [RBP + -0x10],RDI MOV qword ptr [RBP + -0x18],RSI MOV qword ptr [RBP + -0x20],RDX CMP qword ptr [RBP + -0x20],-0x1 JNZ 0x0016d481 CALL 0x001f60c0 MOV dword ptr [RAX],0x78 MOV RAX,qword ptr [RBP + -0x10] MOV qword ptr [RAX + 0x98],-0x1 MOV dword ptr [RBP + -0x4],0xffffffff JMP 0x0016d5d5 LAB_0016d481: JMP 0x0016d483 LAB_0016d483: MOV RSI,qword ptr [RBP + -0x10] MOV RDX,qword ptr [RBP + -0x18] MOV RCX,qword ptr [RBP + -0x20] MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x380] LEA RDI,[RBP + -0x60] XOR R8D,R8D MOV R9D,0x3 MOV qword ptr [RSP],RAX MOV dword ptr [RSP + 0x8],0x0 CALL 0x0016ee50 CMP AL,0x0 JZ 0x0016d4d7 MOV RAX,qword ptr [RBP + -0x10] MOV qword ptr [RAX + 0x98],-0x1 MOV dword ptr [RBP + -0x4],0xffffffff JMP 0x0016d5d5 LAB_0016d4d7: MOV RAX,qword ptr [RBP + -0x50] MOV ECX,dword ptr [RBP + -0x40] ADD RAX,RCX MOV qword ptr [RBP + -0x28],RAX MOV EDI,dword ptr [RBP + -0x38] MOV RSI,qword ptr [RBP + -0x28] CALL 0x0016ab60 MOV qword ptr [RBP + -0x20],RAX CMP RAX,-0x1 JNZ 0x0016d483 MOV RDI,qword ptr [RBP + -0x10] ADD RDI,0x200 MOV RDX,qword ptr [RBP + -0x28] LEA RSI,[RBP + -0x60] CALL 0x0016c980 CMP RAX,0x0 JNZ 0x0016d527 JMP 0x0016d51b LAB_0016d51b: MOV dword ptr [RBP + -0x4],0xffffffff JMP 0x0016d5d5 LAB_0016d527: MOV RDI,qword ptr [RBP + -0x10] ADD RDI,0x200 CALL 0x0016b050 MOV RCX,RAX MOV RAX,qword ptr [RBP + -0x10] MOV qword ptr [RAX + 0x98],RCX MOV RDI,qword ptr [RBP + -0x10] ADD RDI,0x200 CALL 0x0016b200 MOV RCX,RAX MOV RAX,qword ptr [RBP + -0x10] MOV qword ptr [RAX + 0xc0],RCX MOV RCX,qword ptr [RBP + -0x28] MOV RAX,qword ptr [RBP + -0x10] MOV qword ptr [RAX + 0x3b8],RCX MOV RAX,qword ptr [RBP + -0x10] MOV qword ptr [RAX + 0x3b0],RCX MOV ECX,dword ptr [RBP + -0x38] MOV RAX,qword ptr [RBP + -0x10] MOV dword ptr [RAX + 0x3d0],ECX MOV RAX,qword ptr [RBP + -0x18] MOV ECX,dword ptr [RAX + 0xb8] MOV RAX,qword ptr [RBP + -0x10] MOV dword ptr [RAX + 0x3d4],ECX MOV RAX,qword ptr [RBP + -0x10] MOV RCX,qword ptr [RAX + 0x440] MOV RAX,qword ptr [RBP + -0x10] MOV qword ptr [RAX + 0x448],RCX MOV RAX,qword ptr [RBP + -0x10] MOV byte ptr [RAX + 0x685],0x0 MOV RAX,qword ptr [RBP + -0x10] MOV byte ptr [RAX + 0x684],0x0 JMP 0x0016d5cc LAB_0016d5cc: JMP 0x0016d5ce LAB_0016d5ce: MOV dword ptr [RBP + -0x4],0x0 LAB_0016d5d5: MOV EAX,dword ptr [RBP + -0x4] ADD RSP,0x70 POP RBP RET
int4 _ma_search_last(long param_1,long param_2,long param_3) { char cVar1; int4 *puVar2; long lVar3; int8 uVar4; int1 local_68 [16]; long local_58; uint local_48; int4 local_40; long local_30; long local_28; long local_20; long local_18; int4 local_c; local_28 = param_3; local_20 = param_2; local_18 = param_1; if (param_3 == -1) { puVar2 = (int4 *)_my_thread_var(); *puVar2 = 0x78; *(int8 *)(local_18 + 0x98) = 0xffffffffffffffff; local_c = 0xffffffff; } else { do { cVar1 = _ma_fetch_keypage(local_68,local_18,local_20,local_28,0,3, *(int8 *)(local_18 + 0x380),0); if (cVar1 != '\0') { *(int8 *)(local_18 + 0x98) = 0xffffffffffffffff; return 0xffffffff; } local_30 = local_58 + (ulong)local_48; local_28 = _ma_kpos(local_40,local_30); } while (local_28 != -1); lVar3 = _ma_get_last_key(local_18 + 0x200,local_68,local_30); if (lVar3 == 0) { local_c = 0xffffffff; } else { uVar4 = _ma_row_pos_from_key(local_18 + 0x200); *(int8 *)(local_18 + 0x98) = uVar4; uVar4 = _ma_trid_from_key(local_18 + 0x200); *(int8 *)(local_18 + 0xc0) = uVar4; *(long *)(local_18 + 0x3b8) = local_30; *(long *)(local_18 + 0x3b0) = local_30; *(int4 *)(local_18 + 0x3d0) = local_40; *(int4 *)(local_18 + 0x3d4) = *(int4 *)(local_20 + 0xb8); *(int8 *)(local_18 + 0x448) = *(int8 *)(local_18 + 0x440); *(int1 *)(local_18 + 0x685) = 0; *(int1 *)(local_18 + 0x684) = 0; local_c = 0; } } return local_c; }
31,809
ma_search_last
eloqsql/storage/maria/ma_search.c
int _ma_search_last(MARIA_HA *info, MARIA_KEYDEF *keyinfo, my_off_t pos) { uchar *end_of_page; MARIA_PAGE page; DBUG_ENTER("_ma_search_last"); if (pos == HA_OFFSET_ERROR) { my_errno=HA_ERR_KEY_NOT_FOUND; /* Didn't find key */ info->cur_row.lastpos= HA_OFFSET_ERROR; DBUG_RETURN(-1); } do { if (_ma_fetch_keypage(&page, info, keyinfo, pos, PAGECACHE_LOCK_LEFT_UNLOCKED, DFLT_INIT_HITS, info->keyread_buff, 0)) { info->cur_row.lastpos= HA_OFFSET_ERROR; DBUG_RETURN(-1); } end_of_page= page.buff + page.size; } while ((pos= _ma_kpos(page.node, end_of_page)) != HA_OFFSET_ERROR); if (!_ma_get_last_key(&info->last_key, &page, end_of_page)) DBUG_RETURN(-1); info->cur_row.lastpos= _ma_row_pos_from_key(&info->last_key); info->cur_row.trid= _ma_trid_from_key(&info->last_key); info->int_keypos= info->int_maxpos= end_of_page; info->int_nod_flag= page.node; info->int_keytree_version= keyinfo->version; info->last_search_keypage= info->last_keypage; info->page_changed=info->keyread_buff_used=0; DBUG_PRINT("exit",("found key at %lu",(ulong) info->cur_row.lastpos)); DBUG_RETURN(0); }
O3
c
ma_search_last: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r12 pushq %rbx subq $0x40, %rsp movq %rdi, %rbx cmpq $-0x1, %rdx je 0x58345 movq %rdx, %rax movq %rsi, %r14 leaq -0x58(%rbp), %r12 movq %r12, %rdi movq %rbx, %rsi movq %r14, %rdx movq %rax, %rcx xorl %r8d, %r8d movl $0x3, %r9d pushq $0x0 pushq 0x380(%rbx) callq 0x58efe addq $0x10, %rsp testb %al, %al jne 0x58350 movl -0x38(%rbp), %r15d movl -0x30(%rbp), %edi addq -0x48(%rbp), %r15 movq %r15, %rsi callq 0x56f0f cmpq $-0x1, %rax jne 0x58286 leaq 0x200(%rbx), %r12 leaq -0x58(%rbp), %rsi movq %r12, %rdi movq %r15, %rdx callq 0x57c58 testq %rax, %rax je 0x5835b movq %r12, %rdi callq 0x57074 movq %rax, 0x98(%rbx) movq %r12, %rdi callq 0x5712c movq %rax, 0xc0(%rbx) movq %r15, 0x3b8(%rbx) movq %r15, 0x3b0(%rbx) movl -0x30(%rbp), %eax movl %eax, 0x3d0(%rbx) movl 0xb8(%r14), %eax movl %eax, 0x3d4(%rbx) movq 0x440(%rbx), %rax movq %rax, 0x448(%rbx) movw $0x0, 0x684(%rbx) xorl %eax, %eax jmp 0x58360 callq 0xa1b22 movl $0x78, (%rax) movq $-0x1, 0x98(%rbx) movl $0xffffffff, %eax # imm = 0xFFFFFFFF addq $0x40, %rsp popq %rbx popq %r12 popq %r14 popq %r15 popq %rbp retq
_ma_search_last: push rbp mov rbp, rsp push r15 push r14 push r12 push rbx sub rsp, 40h mov rbx, rdi cmp rdx, 0FFFFFFFFFFFFFFFFh jz loc_58345 mov rax, rdx mov r14, rsi lea r12, [rbp+var_58] loc_58286: mov rdi, r12 mov rsi, rbx mov rdx, r14 mov rcx, rax xor r8d, r8d mov r9d, 3 push 0 push qword ptr [rbx+380h] call _ma_fetch_keypage add rsp, 10h test al, al jnz loc_58350 mov r15d, [rbp+var_38] mov edi, [rbp+var_30] add r15, [rbp+var_48] mov rsi, r15 call _ma_kpos cmp rax, 0FFFFFFFFFFFFFFFFh jnz short loc_58286 lea r12, [rbx+200h] lea rsi, [rbp+var_58] mov rdi, r12 mov rdx, r15 call _ma_get_last_key test rax, rax jz short loc_5835B mov rdi, r12 call _ma_row_pos_from_key mov [rbx+98h], rax mov rdi, r12 call _ma_trid_from_key mov [rbx+0C0h], rax mov [rbx+3B8h], r15 mov [rbx+3B0h], r15 mov eax, [rbp+var_30] mov [rbx+3D0h], eax mov eax, [r14+0B8h] mov [rbx+3D4h], eax mov rax, [rbx+440h] mov [rbx+448h], rax mov word ptr [rbx+684h], 0 xor eax, eax jmp short loc_58360 loc_58345: call _my_thread_var mov dword ptr [rax], 78h ; 'x' loc_58350: mov qword ptr [rbx+98h], 0FFFFFFFFFFFFFFFFh loc_5835B: mov eax, 0FFFFFFFFh loc_58360: add rsp, 40h pop rbx pop r12 pop r14 pop r15 pop rbp retn
long long ma_search_last(long long a1, long long a2, long long a3) { long long v3; // rax unsigned long long v4; // r15 _BYTE v6[16]; // [rsp+8h] [rbp-58h] BYREF long long v7; // [rsp+18h] [rbp-48h] unsigned int v8; // [rsp+28h] [rbp-38h] unsigned int v9; // [rsp+30h] [rbp-30h] if ( a3 == -1 ) { *(_DWORD *)my_thread_var(a1, (const char *)a2) = 120; } else { LODWORD(v3) = a3; while ( !(unsigned __int8)ma_fetch_keypage((unsigned int)v6, a1, a2, v3, 0, 3, *(_QWORD *)(a1 + 896)) ) { v4 = v7 + v8; v3 = ma_kpos(v9, v4); if ( v3 == -1 ) { if ( !ma_get_last_key(a1 + 512, (long long)v6, v4) ) return 0xFFFFFFFFLL; *(_QWORD *)(a1 + 152) = ma_row_pos_from_key((long long *)(a1 + 512)); *(_QWORD *)(a1 + 192) = ma_trid_from_key(a1 + 512); *(_QWORD *)(a1 + 952) = v4; *(_QWORD *)(a1 + 944) = v4; *(_DWORD *)(a1 + 976) = v9; *(_DWORD *)(a1 + 980) = *(_DWORD *)(a2 + 184); *(_QWORD *)(a1 + 1096) = *(_QWORD *)(a1 + 1088); *(_WORD *)(a1 + 1668) = 0; return 0LL; } } } *(_QWORD *)(a1 + 152) = -1LL; return 0xFFFFFFFFLL; }
_ma_search_last: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R12 PUSH RBX SUB RSP,0x40 MOV RBX,RDI CMP RDX,-0x1 JZ 0x00158345 MOV RAX,RDX MOV R14,RSI LEA R12,[RBP + -0x58] LAB_00158286: MOV RDI,R12 MOV RSI,RBX MOV RDX,R14 MOV RCX,RAX XOR R8D,R8D MOV R9D,0x3 PUSH 0x0 PUSH qword ptr [RBX + 0x380] CALL 0x00158efe ADD RSP,0x10 TEST AL,AL JNZ 0x00158350 MOV R15D,dword ptr [RBP + -0x38] MOV EDI,dword ptr [RBP + -0x30] ADD R15,qword ptr [RBP + -0x48] MOV RSI,R15 CALL 0x00156f0f CMP RAX,-0x1 JNZ 0x00158286 LEA R12,[RBX + 0x200] LEA RSI,[RBP + -0x58] MOV RDI,R12 MOV RDX,R15 CALL 0x00157c58 TEST RAX,RAX JZ 0x0015835b MOV RDI,R12 CALL 0x00157074 MOV qword ptr [RBX + 0x98],RAX MOV RDI,R12 CALL 0x0015712c MOV qword ptr [RBX + 0xc0],RAX MOV qword ptr [RBX + 0x3b8],R15 MOV qword ptr [RBX + 0x3b0],R15 MOV EAX,dword ptr [RBP + -0x30] MOV dword ptr [RBX + 0x3d0],EAX MOV EAX,dword ptr [R14 + 0xb8] MOV dword ptr [RBX + 0x3d4],EAX MOV RAX,qword ptr [RBX + 0x440] MOV qword ptr [RBX + 0x448],RAX MOV word ptr [RBX + 0x684],0x0 XOR EAX,EAX JMP 0x00158360 LAB_00158345: CALL 0x001a1b22 MOV dword ptr [RAX],0x78 LAB_00158350: MOV qword ptr [RBX + 0x98],-0x1 LAB_0015835b: MOV EAX,0xffffffff LAB_00158360: ADD RSP,0x40 POP RBX POP R12 POP R14 POP R15 POP RBP RET
int8 _ma_search_last(long param_1,long param_2,long param_3) { long lVar1; char cVar2; long lVar3; int8 uVar4; int4 *puVar5; long lVar6; int1 local_60 [16]; long local_50; uint local_40; int4 local_38; if (param_3 == -1) { puVar5 = (int4 *)_my_thread_var(); *puVar5 = 0x78; LAB_00158350: *(int8 *)(param_1 + 0x98) = 0xffffffffffffffff; } else { do { cVar2 = _ma_fetch_keypage(local_60,param_1,param_2,param_3,0,3, *(int8 *)(param_1 + 0x380),0); if (cVar2 != '\0') goto LAB_00158350; lVar6 = (ulong)local_40 + local_50; param_3 = _ma_kpos(local_38,lVar6); } while (param_3 != -1); lVar1 = param_1 + 0x200; lVar3 = _ma_get_last_key(lVar1,local_60,lVar6); if (lVar3 != 0) { uVar4 = _ma_row_pos_from_key(lVar1); *(int8 *)(param_1 + 0x98) = uVar4; uVar4 = _ma_trid_from_key(lVar1); *(int8 *)(param_1 + 0xc0) = uVar4; *(long *)(param_1 + 0x3b8) = lVar6; *(long *)(param_1 + 0x3b0) = lVar6; *(int4 *)(param_1 + 0x3d0) = local_38; *(int4 *)(param_1 + 0x3d4) = *(int4 *)(param_2 + 0xb8); *(int8 *)(param_1 + 0x448) = *(int8 *)(param_1 + 0x440); *(int2 *)(param_1 + 0x684) = 0; return 0; } } return 0xffffffff; }
31,810
my_coll_lexem_print_error
eloqsql/strings/ctype-uca.c
static void my_coll_lexem_print_error(MY_COLL_LEXEM *lexem, char *errstr, size_t errsize, const char *txt) { char tail[30]; size_t len= lexem->end - lexem->prev; strmake (tail, lexem->prev, (size_t) MY_MIN(len, sizeof(tail)-1)); errstr[errsize-1]= '\0'; my_snprintf(errstr, errsize - 1, "%s at '%s'", txt[0] ? txt : "Syntax error", tail); }
O0
c
my_coll_lexem_print_error: pushq %rbp movq %rsp, %rbp subq $0x90, %rsp movq %fs:0x28, %rax movq %rax, -0x8(%rbp) movq %rdi, -0x38(%rbp) movq %rsi, -0x40(%rbp) movq %rdx, -0x48(%rbp) movq %rcx, -0x50(%rbp) movq -0x38(%rbp), %rax movq 0x10(%rax), %rax movq -0x38(%rbp), %rcx movq 0x18(%rcx), %rcx subq %rcx, %rax movq %rax, -0x58(%rbp) leaq -0x30(%rbp), %rax movq %rax, -0x68(%rbp) movq -0x38(%rbp), %rax movq 0x18(%rax), %rax movq %rax, -0x60(%rbp) cmpq $0x1d, -0x58(%rbp) jae 0x5f054 movq -0x58(%rbp), %rax movq %rax, -0x70(%rbp) jmp 0x5f05f movl $0x1d, %eax movq %rax, -0x70(%rbp) jmp 0x5f05f movq -0x60(%rbp), %rsi movq -0x68(%rbp), %rdi movq -0x70(%rbp), %rdx callq 0x87940 movq -0x40(%rbp), %rax movq -0x48(%rbp), %rcx subq $0x1, %rcx movb $0x0, (%rax,%rcx) movq -0x40(%rbp), %rax movq %rax, -0x80(%rbp) movq -0x48(%rbp), %rax subq $0x1, %rax movq %rax, -0x78(%rbp) movq -0x50(%rbp), %rax movsbl (%rax), %eax cmpl $0x0, %eax je 0x5f0ad movq -0x50(%rbp), %rax movq %rax, -0x88(%rbp) jmp 0x5f0bd leaq 0x2eeda(%rip), %rax # 0x8df8e movq %rax, -0x88(%rbp) jmp 0x5f0bd movq -0x78(%rbp), %rsi movq -0x80(%rbp), %rdi movq -0x88(%rbp), %rcx leaq 0x2eeb0(%rip), %rdx # 0x8df83 xorl %eax, %eax leaq -0x30(%rbp), %r8 callq 0x86db0 movq %fs:0x28, %rax movq -0x8(%rbp), %rcx cmpq %rcx, %rax jne 0x5f0f9 addq $0x90, %rsp popq %rbp retq callq 0x25340 nop
my_coll_lexem_print_error: push rbp mov rbp, rsp sub rsp, 90h mov rax, fs:28h mov [rbp+var_8], rax mov [rbp+var_38], rdi mov [rbp+var_40], rsi mov [rbp+var_48], rdx mov [rbp+var_50], rcx mov rax, [rbp+var_38] mov rax, [rax+10h] mov rcx, [rbp+var_38] mov rcx, [rcx+18h] sub rax, rcx mov [rbp+var_58], rax lea rax, [rbp+var_30] mov [rbp+var_68], rax mov rax, [rbp+var_38] mov rax, [rax+18h] mov [rbp+var_60], rax cmp [rbp+var_58], 1Dh jnb short loc_5F054 mov rax, [rbp+var_58] mov [rbp+var_70], rax jmp short loc_5F05F loc_5F054: mov eax, 1Dh mov [rbp+var_70], rax jmp short $+2 loc_5F05F: mov rsi, [rbp+var_60] mov rdi, [rbp+var_68] mov rdx, [rbp+var_70] call strmake mov rax, [rbp+var_40] mov rcx, [rbp+var_48] sub rcx, 1 mov byte ptr [rax+rcx], 0 mov rax, [rbp+var_40] mov [rbp+var_80], rax mov rax, [rbp+var_48] sub rax, 1 mov [rbp+var_78], rax mov rax, [rbp+var_50] movsx eax, byte ptr [rax] cmp eax, 0 jz short loc_5F0AD mov rax, [rbp+var_50] mov [rbp+var_88], rax jmp short loc_5F0BD loc_5F0AD: lea rax, aSyntaxError; "Syntax error" mov [rbp+var_88], rax jmp short $+2 loc_5F0BD: mov rsi, [rbp+var_78] mov rdi, [rbp+var_80] mov rcx, [rbp+var_88] lea rdx, aSAtS; "%s at '%s'" xor eax, eax lea r8, [rbp+var_30] call my_snprintf mov rax, fs:28h mov rcx, [rbp+var_8] cmp rax, rcx jnz short loc_5F0F9 add rsp, 90h pop rbp retn loc_5F0F9: call ___stack_chk_fail
unsigned long long my_coll_lexem_print_error(long long a1, long long a2, long long a3, _BYTE *a4) { int v4; // r9d int v6; // [rsp+18h] [rbp-78h] long long v7; // [rsp+30h] [rbp-60h] unsigned long long v8; // [rsp+38h] [rbp-58h] _BYTE v11[40]; // [rsp+60h] [rbp-30h] BYREF unsigned long long v12; // [rsp+88h] [rbp-8h] v12 = __readfsqword(0x28u); v8 = *(_QWORD *)(a1 + 16) - *(_QWORD *)(a1 + 24); v7 = *(_QWORD *)(a1 + 24); if ( v8 >= 0x1D ) strmake(v11, v7, 29LL); else strmake(v11, v7, v8); *(_BYTE *)(a2 + a3 - 1) = 0; v6 = a3 - 1; if ( *a4 ) my_snprintf(a2, v6, (unsigned int)"%s at '%s'", (_DWORD)a4, (unsigned int)v11, v4); else my_snprintf(a2, v6, (unsigned int)"%s at '%s'", (unsigned int)"Syntax error", (unsigned int)v11, v4); return __readfsqword(0x28u); }
my_coll_lexem_print_error: PUSH RBP MOV RBP,RSP SUB RSP,0x90 MOV RAX,qword ptr FS:[0x28] MOV qword ptr [RBP + -0x8],RAX MOV qword ptr [RBP + -0x38],RDI MOV qword ptr [RBP + -0x40],RSI MOV qword ptr [RBP + -0x48],RDX MOV qword ptr [RBP + -0x50],RCX MOV RAX,qword ptr [RBP + -0x38] MOV RAX,qword ptr [RAX + 0x10] MOV RCX,qword ptr [RBP + -0x38] MOV RCX,qword ptr [RCX + 0x18] SUB RAX,RCX MOV qword ptr [RBP + -0x58],RAX LEA RAX,[RBP + -0x30] MOV qword ptr [RBP + -0x68],RAX MOV RAX,qword ptr [RBP + -0x38] MOV RAX,qword ptr [RAX + 0x18] MOV qword ptr [RBP + -0x60],RAX CMP qword ptr [RBP + -0x58],0x1d JNC 0x0015f054 MOV RAX,qword ptr [RBP + -0x58] MOV qword ptr [RBP + -0x70],RAX JMP 0x0015f05f LAB_0015f054: MOV EAX,0x1d MOV qword ptr [RBP + -0x70],RAX JMP 0x0015f05f LAB_0015f05f: MOV RSI,qword ptr [RBP + -0x60] MOV RDI,qword ptr [RBP + -0x68] MOV RDX,qword ptr [RBP + -0x70] CALL 0x00187940 MOV RAX,qword ptr [RBP + -0x40] MOV RCX,qword ptr [RBP + -0x48] SUB RCX,0x1 MOV byte ptr [RAX + RCX*0x1],0x0 MOV RAX,qword ptr [RBP + -0x40] MOV qword ptr [RBP + -0x80],RAX MOV RAX,qword ptr [RBP + -0x48] SUB RAX,0x1 MOV qword ptr [RBP + -0x78],RAX MOV RAX,qword ptr [RBP + -0x50] MOVSX EAX,byte ptr [RAX] CMP EAX,0x0 JZ 0x0015f0ad MOV RAX,qword ptr [RBP + -0x50] MOV qword ptr [RBP + -0x88],RAX JMP 0x0015f0bd LAB_0015f0ad: LEA RAX,[0x18df8e] MOV qword ptr [RBP + -0x88],RAX JMP 0x0015f0bd LAB_0015f0bd: MOV RSI,qword ptr [RBP + -0x78] MOV RDI,qword ptr [RBP + -0x80] MOV RCX,qword ptr [RBP + -0x88] LEA RDX,[0x18df83] XOR EAX,EAX LEA R8,[RBP + -0x30] CALL 0x00186db0 MOV RAX,qword ptr FS:[0x28] MOV RCX,qword ptr [RBP + -0x8] CMP RAX,RCX JNZ 0x0015f0f9 ADD RSP,0x90 POP RBP RET LAB_0015f0f9: CALL 0x00125340
void my_coll_lexem_print_error(long param_1,long param_2,long param_3,char *param_4) { long in_FS_OFFSET; char *local_90; ulong local_78; int1 local_38 [40]; long local_10; local_10 = *(long *)(in_FS_OFFSET + 0x28); local_78 = *(long *)(param_1 + 0x10) - *(long *)(param_1 + 0x18); if (0x1c < local_78) { local_78 = 0x1d; } strmake(local_38,*(int8 *)(param_1 + 0x18),local_78); *(int1 *)(param_2 + param_3 + -1) = 0; local_90 = param_4; if (*param_4 == '\0') { local_90 = "Syntax error"; } my_snprintf(param_2,param_3 + -1,"%s at \'%s\'",local_90,local_38); if (*(long *)(in_FS_OFFSET + 0x28) != local_10) { /* WARNING: Subroutine does not return */ __stack_chk_fail(); } return; }
31,811
my_b_write
eloqsql/include/my_sys.h
static inline int my_b_write(IO_CACHE *info, const uchar *Buffer, size_t Count) { MEM_CHECK_DEFINED(Buffer, Count); if (info->write_pos + Count <= info->write_end) { if (Count) { memcpy(info->write_pos, Buffer, Count); info->write_pos+= Count; } return 0; } return _my_b_write(info, Buffer, Count); }
O0
c
my_b_write: pushq %rbp movq %rsp, %rbp subq $0x20, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq %rdx, -0x20(%rbp) movq -0x10(%rbp), %rax movq 0x40(%rax), %rax addq -0x20(%rbp), %rax movq -0x10(%rbp), %rcx cmpq 0x48(%rcx), %rax ja 0x6f96f cmpq $0x0, -0x20(%rbp) je 0x6f966 movq -0x10(%rbp), %rax movq 0x40(%rax), %rdi movq -0x18(%rbp), %rsi movq -0x20(%rbp), %rdx callq 0x282b0 movq -0x20(%rbp), %rcx movq -0x10(%rbp), %rax addq 0x40(%rax), %rcx movq %rcx, 0x40(%rax) movl $0x0, -0x4(%rbp) jmp 0x6f983 movq -0x10(%rbp), %rdi movq -0x18(%rbp), %rsi movq -0x20(%rbp), %rdx callq 0x6ea30 movl %eax, -0x4(%rbp) movl -0x4(%rbp), %eax addq $0x20, %rsp popq %rbp retq nopl (%rax)
my_b_write_1: push rbp mov rbp, rsp sub rsp, 20h mov [rbp+var_10], rdi mov [rbp+var_18], rsi mov [rbp+var_20], rdx mov rax, [rbp+var_10] mov rax, [rax+40h] add rax, [rbp+var_20] mov rcx, [rbp+var_10] cmp rax, [rcx+48h] ja short loc_6F96F cmp [rbp+var_20], 0 jz short loc_6F966 mov rax, [rbp+var_10] mov rdi, [rax+40h] mov rsi, [rbp+var_18] mov rdx, [rbp+var_20] call _memcpy mov rcx, [rbp+var_20] mov rax, [rbp+var_10] add rcx, [rax+40h] mov [rax+40h], rcx loc_6F966: mov [rbp+var_4], 0 jmp short loc_6F983 loc_6F96F: mov rdi, [rbp+var_10] mov rsi, [rbp+var_18] mov rdx, [rbp+var_20] call _my_b_write mov [rbp+var_4], eax loc_6F983: mov eax, [rbp+var_4] add rsp, 20h pop rbp retn
long long my_b_write_1(long long a1, const char *a2, long long a3) { if ( (unsigned long long)(a3 + *(_QWORD *)(a1 + 64)) > *(_QWORD *)(a1 + 72) ) { return (unsigned int)my_b_write(a1, a2, a3); } else { if ( a3 ) { memcpy(*(_QWORD *)(a1 + 64), a2, a3); *(_QWORD *)(a1 + 64) += a3; } return 0; } }
my_b_write: PUSH RBP MOV RBP,RSP SUB RSP,0x20 MOV qword ptr [RBP + -0x10],RDI MOV qword ptr [RBP + -0x18],RSI MOV qword ptr [RBP + -0x20],RDX MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x40] ADD RAX,qword ptr [RBP + -0x20] MOV RCX,qword ptr [RBP + -0x10] CMP RAX,qword ptr [RCX + 0x48] JA 0x0016f96f CMP qword ptr [RBP + -0x20],0x0 JZ 0x0016f966 MOV RAX,qword ptr [RBP + -0x10] MOV RDI,qword ptr [RAX + 0x40] MOV RSI,qword ptr [RBP + -0x18] MOV RDX,qword ptr [RBP + -0x20] CALL 0x001282b0 MOV RCX,qword ptr [RBP + -0x20] MOV RAX,qword ptr [RBP + -0x10] ADD RCX,qword ptr [RAX + 0x40] MOV qword ptr [RAX + 0x40],RCX LAB_0016f966: MOV dword ptr [RBP + -0x4],0x0 JMP 0x0016f983 LAB_0016f96f: MOV RDI,qword ptr [RBP + -0x10] MOV RSI,qword ptr [RBP + -0x18] MOV RDX,qword ptr [RBP + -0x20] CALL 0x0016ea30 MOV dword ptr [RBP + -0x4],EAX LAB_0016f983: MOV EAX,dword ptr [RBP + -0x4] ADD RSP,0x20 POP RBP RET
int4 my_b_write(long param_1,void *param_2,size_t param_3) { int4 local_c; if (*(ulong *)(param_1 + 0x48) < *(long *)(param_1 + 0x40) + param_3) { local_c = _my_b_write(param_1,param_2,param_3); } else { if (param_3 != 0) { memcpy(*(void **)(param_1 + 0x40),param_2,param_3); *(size_t *)(param_1 + 0x40) = param_3 + *(long *)(param_1 + 0x40); } local_c = 0; } return local_c; }
31,812
ftxui::Color::HSV(unsigned char, unsigned char, unsigned char)
Andrewchistyakov[P]flashcards_lyc/build_O0/_deps/ftxui-src/src/ftxui/screen/color.cpp
Color Color::HSV(uint8_t h, uint8_t s, uint8_t v) { if (s == 0) { return {0, 0, 0}; } uint8_t region = h / 43; // NOLINT uint8_t remainder = (h - (region * 43)) * 6; // NOLINT uint8_t p = (v * (255 - s)) >> 8; // NOLINT uint8_t q = (v * (255 - ((s * remainder) >> 8))) >> 8; // NOLINT uint8_t t = (v * (255 - ((s * (255 - remainder)) >> 8))) >> 8; // NOLINT // clang-format off switch (region) { // NOLINT case 0: return Color(v,t,p); // NOLINT case 1: return Color(q,v,p); // NOLINT case 2: return Color(p,v,t); // NOLINT case 3: return Color(p,q,v); // NOLINT case 4: return Color(t,p,v); // NOLINT case 5: return Color(v,p,q); // NOLINT } // NOLINT // clang-format on return {0, 0, 0}; }
O0
cpp
ftxui::Color::HSV(unsigned char, unsigned char, unsigned char): pushq %rbp movq %rsp, %rbp subq $0x20, %rsp movb %dl, %al movb %sil, %cl movb %dil, %dl movb %dl, -0x5(%rbp) movb %cl, -0x6(%rbp) movb %al, -0x7(%rbp) movzbl -0x6(%rbp), %eax cmpl $0x0, %eax jne 0x38c56 leaq -0x4(%rbp), %rdi xorl %ecx, %ecx movl %ecx, %esi movl %ecx, %edx callq 0x38aa0 jmp 0x38db5 movzbl -0x5(%rbp), %eax imulq $0x5f417d1, %rax, %rax # imm = 0x5F417D1 shrq $0x20, %rax movb %al, -0x8(%rbp) movzbl -0x5(%rbp), %ecx movzbl -0x8(%rbp), %eax imull $0x2b, %eax, %eax subl %eax, %ecx addl %ecx, %ecx movl %ecx, %eax leal (%rax,%rax,2), %eax movb %al, -0x9(%rbp) movzbl -0x7(%rbp), %eax movzbl -0x6(%rbp), %ecx xorl $0xff, %ecx imull %ecx, %eax movb %ah, %al movb %al, -0xa(%rbp) movzbl -0x7(%rbp), %eax movzbl -0x6(%rbp), %ecx movzbl -0x9(%rbp), %edx imull %edx, %ecx shrl $0x8, %ecx xorl $0xff, %ecx imull %ecx, %eax movb %ah, %al movb %al, -0xb(%rbp) movzbl -0x7(%rbp), %eax movzbl -0x6(%rbp), %ecx movzbl -0x9(%rbp), %edx xorl $0xff, %edx imull %edx, %ecx shrl $0x8, %ecx xorl $0xff, %ecx imull %ecx, %eax movb %ah, %al movb %al, -0xc(%rbp) movzbl -0x8(%rbp), %eax movq %rax, -0x18(%rbp) subq $0x5, %rax ja 0x38da6 movq -0x18(%rbp), %rax leaq 0x58294(%rip), %rcx # 0x90f8c movslq (%rcx,%rax,4), %rax addq %rcx, %rax jmpq *%rax movb -0x7(%rbp), %cl movb -0xc(%rbp), %al leaq -0x4(%rbp), %rdi movzbl %cl, %esi movzbl %al, %edx movzbl -0xa(%rbp), %ecx callq 0x38aa0 jmp 0x38db5 movb -0xb(%rbp), %cl movb -0x7(%rbp), %al leaq -0x4(%rbp), %rdi movzbl %cl, %esi movzbl %al, %edx movzbl -0xa(%rbp), %ecx callq 0x38aa0 jmp 0x38db5 movb -0xa(%rbp), %cl movb -0x7(%rbp), %al leaq -0x4(%rbp), %rdi movzbl %cl, %esi movzbl %al, %edx movzbl -0xc(%rbp), %ecx callq 0x38aa0 jmp 0x38db5 movb -0xa(%rbp), %cl movb -0xb(%rbp), %al leaq -0x4(%rbp), %rdi movzbl %cl, %esi movzbl %al, %edx movzbl -0x7(%rbp), %ecx callq 0x38aa0 jmp 0x38db5 movb -0xc(%rbp), %cl movb -0xa(%rbp), %al leaq -0x4(%rbp), %rdi movzbl %cl, %esi movzbl %al, %edx movzbl -0x7(%rbp), %ecx callq 0x38aa0 jmp 0x38db5 movb -0x7(%rbp), %cl movb -0xa(%rbp), %al leaq -0x4(%rbp), %rdi movzbl %cl, %esi movzbl %al, %edx movzbl -0xb(%rbp), %ecx callq 0x38aa0 jmp 0x38db5 leaq -0x4(%rbp), %rdi xorl %ecx, %ecx movl %ecx, %esi movl %ecx, %edx callq 0x38aa0 movl -0x4(%rbp), %eax addq $0x20, %rsp popq %rbp retq nop
_ZN5ftxui5Color3HSVEhhh: push rbp mov rbp, rsp sub rsp, 20h mov al, dl mov cl, sil mov dl, dil mov [rbp+var_5], dl mov [rbp+var_6], cl mov [rbp+var_7], al movzx eax, [rbp+var_6] cmp eax, 0 jnz short loc_38C56 lea rdi, [rbp+var_4]; this xor ecx, ecx; unsigned __int8 mov esi, ecx; unsigned __int8 mov edx, ecx; unsigned __int8 call _ZN5ftxui5ColorC2Ehhh; ftxui::Color::Color(uchar,uchar,uchar) jmp loc_38DB5 loc_38C56: movzx eax, [rbp+var_5] imul rax, 5F417D1h shr rax, 20h mov [rbp+var_8], al movzx ecx, [rbp+var_5] movzx eax, [rbp+var_8] imul eax, 2Bh ; '+' sub ecx, eax add ecx, ecx mov eax, ecx lea eax, [rax+rax*2] mov [rbp+var_9], al movzx eax, [rbp+var_7] movzx ecx, [rbp+var_6] xor ecx, 0FFh imul eax, ecx mov al, ah mov [rbp+var_A], al movzx eax, [rbp+var_7] movzx ecx, [rbp+var_6] movzx edx, [rbp+var_9] imul ecx, edx shr ecx, 8 xor ecx, 0FFh imul eax, ecx mov al, ah mov [rbp+var_B], al movzx eax, [rbp+var_7] movzx ecx, [rbp+var_6] movzx edx, [rbp+var_9] xor edx, 0FFh imul ecx, edx shr ecx, 8 xor ecx, 0FFh imul eax, ecx mov al, ah mov [rbp+var_C], al movzx eax, [rbp+var_8] mov [rbp+var_18], rax sub rax, 5; switch 6 cases ja def_38CFF; jumptable 0000000000038CFF default case mov rax, [rbp+var_18] lea rcx, jpt_38CFF movsxd rax, ds:(jpt_38CFF - 90F8Ch)[rcx+rax*4] add rax, rcx jmp rax; switch jump loc_38D01: mov cl, [rbp+var_7]; jumptable 0000000000038CFF case 0 mov al, [rbp+var_C] lea rdi, [rbp+var_4]; this movzx esi, cl; unsigned __int8 movzx edx, al; unsigned __int8 movzx ecx, [rbp+var_A]; unsigned __int8 call _ZN5ftxui5ColorC2Ehhh; ftxui::Color::Color(uchar,uchar,uchar) jmp loc_38DB5 loc_38D1F: mov cl, [rbp+var_B]; jumptable 0000000000038CFF case 1 mov al, [rbp+var_7] lea rdi, [rbp+var_4]; this movzx esi, cl; unsigned __int8 movzx edx, al; unsigned __int8 movzx ecx, [rbp+var_A]; unsigned __int8 call _ZN5ftxui5ColorC2Ehhh; ftxui::Color::Color(uchar,uchar,uchar) jmp short loc_38DB5 loc_38D3A: mov cl, [rbp+var_A]; jumptable 0000000000038CFF case 2 mov al, [rbp+var_7] lea rdi, [rbp+var_4]; this movzx esi, cl; unsigned __int8 movzx edx, al; unsigned __int8 movzx ecx, [rbp+var_C]; unsigned __int8 call _ZN5ftxui5ColorC2Ehhh; ftxui::Color::Color(uchar,uchar,uchar) jmp short loc_38DB5 loc_38D55: mov cl, [rbp+var_A]; jumptable 0000000000038CFF case 3 mov al, [rbp+var_B] lea rdi, [rbp+var_4]; this movzx esi, cl; unsigned __int8 movzx edx, al; unsigned __int8 movzx ecx, [rbp+var_7]; unsigned __int8 call _ZN5ftxui5ColorC2Ehhh; ftxui::Color::Color(uchar,uchar,uchar) jmp short loc_38DB5 loc_38D70: mov cl, [rbp+var_C]; jumptable 0000000000038CFF case 4 mov al, [rbp+var_A] lea rdi, [rbp+var_4]; this movzx esi, cl; unsigned __int8 movzx edx, al; unsigned __int8 movzx ecx, [rbp+var_7]; unsigned __int8 call _ZN5ftxui5ColorC2Ehhh; ftxui::Color::Color(uchar,uchar,uchar) jmp short loc_38DB5 loc_38D8B: mov cl, [rbp+var_7]; jumptable 0000000000038CFF case 5 mov al, [rbp+var_A] lea rdi, [rbp+var_4]; this movzx esi, cl; unsigned __int8 movzx edx, al; unsigned __int8 movzx ecx, [rbp+var_B]; unsigned __int8 call _ZN5ftxui5ColorC2Ehhh; ftxui::Color::Color(uchar,uchar,uchar) jmp short loc_38DB5 def_38CFF: lea rdi, [rbp+var_4]; jumptable 0000000000038CFF default case xor ecx, ecx; unsigned __int8 mov esi, ecx; unsigned __int8 mov edx, ecx; unsigned __int8 call _ZN5ftxui5ColorC2Ehhh; ftxui::Color::Color(uchar,uchar,uchar) loc_38DB5: mov eax, [rbp+var_4] add rsp, 20h pop rbp retn
long long ftxui::Color::HSV(ftxui::Color *this, unsigned __int8 a2, unsigned __int8 a3) { unsigned __int8 v4; // [rsp+14h] [rbp-Ch] unsigned __int8 v5; // [rsp+15h] [rbp-Bh] unsigned __int8 v6; // [rsp+16h] [rbp-Ah] unsigned __int8 v7; // [rsp+17h] [rbp-9h] unsigned int v8; // [rsp+1Ch] [rbp-4h] BYREF if ( a2 ) { v7 = 6 * ((unsigned __int8)this % 0x2Bu); v6 = (unsigned __int16)((a2 ^ 0xFF) * a3) >> 8; v5 = (unsigned __int16)((((v7 * (unsigned int)a2) >> 8) ^ 0xFF) * a3) >> 8; v4 = (unsigned __int16)(((((v7 ^ 0xFF) * (unsigned int)a2) >> 8) ^ 0xFF) * a3) >> 8; switch ( (unsigned __int8)this / 0x2Bu ) { case 0u: ftxui::Color::Color((unsigned long long)&v8, a3, v4, v6); break; case 1u: ftxui::Color::Color((unsigned long long)&v8, v5, a3, v6); break; case 2u: ftxui::Color::Color((unsigned long long)&v8, v6, a3, v4); break; case 3u: ftxui::Color::Color((unsigned long long)&v8, v6, v5, a3); break; case 4u: ftxui::Color::Color((unsigned long long)&v8, v4, v6, a3); break; case 5u: ftxui::Color::Color((unsigned long long)&v8, a3, v6, v5); break; default: goto LABEL_9; } } else { LABEL_9: ftxui::Color::Color((unsigned long long)&v8, 0, 0, 0); } return v8; }
HSV: PUSH RBP MOV RBP,RSP SUB RSP,0x20 MOV AL,DL MOV CL,SIL MOV DL,DIL MOV byte ptr [RBP + -0x5],DL MOV byte ptr [RBP + -0x6],CL MOV byte ptr [RBP + -0x7],AL MOVZX EAX,byte ptr [RBP + -0x6] CMP EAX,0x0 JNZ 0x00138c56 LEA RDI,[RBP + -0x4] XOR ECX,ECX MOV ESI,ECX MOV EDX,ECX CALL 0x00138aa0 JMP 0x00138db5 LAB_00138c56: MOVZX EAX,byte ptr [RBP + -0x5] IMUL RAX,RAX,0x5f417d1 SHR RAX,0x20 MOV byte ptr [RBP + -0x8],AL MOVZX ECX,byte ptr [RBP + -0x5] MOVZX EAX,byte ptr [RBP + -0x8] IMUL EAX,EAX,0x2b SUB ECX,EAX ADD ECX,ECX MOV EAX,ECX LEA EAX,[RAX + RAX*0x2] MOV byte ptr [RBP + -0x9],AL MOVZX EAX,byte ptr [RBP + -0x7] MOVZX ECX,byte ptr [RBP + -0x6] XOR ECX,0xff IMUL EAX,ECX MOV AL,AH MOV byte ptr [RBP + -0xa],AL MOVZX EAX,byte ptr [RBP + -0x7] MOVZX ECX,byte ptr [RBP + -0x6] MOVZX EDX,byte ptr [RBP + -0x9] IMUL ECX,EDX SHR ECX,0x8 XOR ECX,0xff IMUL EAX,ECX MOV AL,AH MOV byte ptr [RBP + -0xb],AL MOVZX EAX,byte ptr [RBP + -0x7] MOVZX ECX,byte ptr [RBP + -0x6] MOVZX EDX,byte ptr [RBP + -0x9] XOR EDX,0xff IMUL ECX,EDX SHR ECX,0x8 XOR ECX,0xff IMUL EAX,ECX MOV AL,AH MOV byte ptr [RBP + -0xc],AL MOVZX EAX,byte ptr [RBP + -0x8] MOV qword ptr [RBP + -0x18],RAX SUB RAX,0x5 JA 0x00138da6 MOV RAX,qword ptr [RBP + -0x18] LEA RCX,[0x190f8c] MOVSXD RAX,dword ptr [RCX + RAX*0x4] ADD RAX,RCX switchD: JMP RAX caseD_0: MOV CL,byte ptr [RBP + -0x7] MOV AL,byte ptr [RBP + -0xc] LEA RDI,[RBP + -0x4] MOVZX ESI,CL MOVZX EDX,AL MOVZX ECX,byte ptr [RBP + -0xa] CALL 0x00138aa0 JMP 0x00138db5 caseD_1: MOV CL,byte ptr [RBP + -0xb] MOV AL,byte ptr [RBP + -0x7] LEA RDI,[RBP + -0x4] MOVZX ESI,CL MOVZX EDX,AL MOVZX ECX,byte ptr [RBP + -0xa] CALL 0x00138aa0 JMP 0x00138db5 caseD_2: MOV CL,byte ptr [RBP + -0xa] MOV AL,byte ptr [RBP + -0x7] LEA RDI,[RBP + -0x4] MOVZX ESI,CL MOVZX EDX,AL MOVZX ECX,byte ptr [RBP + -0xc] CALL 0x00138aa0 JMP 0x00138db5 caseD_3: MOV CL,byte ptr [RBP + -0xa] MOV AL,byte ptr [RBP + -0xb] LEA RDI,[RBP + -0x4] MOVZX ESI,CL MOVZX EDX,AL MOVZX ECX,byte ptr [RBP + -0x7] CALL 0x00138aa0 JMP 0x00138db5 caseD_4: MOV CL,byte ptr [RBP + -0xc] MOV AL,byte ptr [RBP + -0xa] LEA RDI,[RBP + -0x4] MOVZX ESI,CL MOVZX EDX,AL MOVZX ECX,byte ptr [RBP + -0x7] CALL 0x00138aa0 JMP 0x00138db5 caseD_5: MOV CL,byte ptr [RBP + -0x7] MOV AL,byte ptr [RBP + -0xa] LEA RDI,[RBP + -0x4] MOVZX ESI,CL MOVZX EDX,AL MOVZX ECX,byte ptr [RBP + -0xb] CALL 0x00138aa0 JMP 0x00138db5 default: LEA RDI,[RBP + -0x4] XOR ECX,ECX MOV ESI,ECX MOV EDX,ECX CALL 0x00138aa0 LAB_00138db5: MOV EAX,dword ptr [RBP + -0x4] ADD RSP,0x20 POP RBP RET
/* ftxui::Color::HSV(unsigned char, unsigned char, unsigned char) */ int4 ftxui::Color::HSV(uchar param_1,uchar param_2,uchar param_3) { byte bVar1; char cVar2; uchar uVar3; uchar uVar4; uchar uVar5; int4 local_c; if (param_2 == '\0') { Color((Color *)&local_c,'\0','\0','\0'); } else { cVar2 = (char)((ulong)param_1 * 0x5f417d1 >> 0x20); bVar1 = (param_1 + cVar2 * -0x2b) * '\x06'; uVar3 = (uchar)((uint)param_3 * (param_2 ^ 0xff) >> 8); uVar4 = (uchar)((uint)param_3 * ((uint)param_2 * (uint)bVar1 >> 8 ^ 0xff) >> 8); uVar5 = (uchar)((uint)param_3 * ((uint)param_2 * (bVar1 ^ 0xff) >> 8 ^ 0xff) >> 8); switch(cVar2) { case '\0': Color((Color *)&local_c,param_3,uVar5,uVar3); break; case '\x01': Color((Color *)&local_c,uVar4,param_3,uVar3); break; case '\x02': Color((Color *)&local_c,uVar3,param_3,uVar5); break; case '\x03': Color((Color *)&local_c,uVar3,uVar4,param_3); break; case '\x04': Color((Color *)&local_c,uVar5,uVar3,param_3); break; case '\x05': Color((Color *)&local_c,param_3,uVar3,uVar4); break; default: Color((Color *)&local_c,'\0','\0','\0'); } } return local_c; }
31,813
spdlog::details::c_formatter<spdlog::details::null_scoped_padder>::format(spdlog::details::log_msg const&, tm const&, fmt::v10::basic_memory_buffer<char, 250ul, std::allocator<char>>&)
AlayaLite/build_O3/_deps/spdlog-src/include/spdlog/pattern_formatter-inl.h
void format(const details::log_msg &, const std::tm &tm_time, memory_buf_t &dest) override { const size_t field_size = 24; ScopedPadder p(field_size, padinfo_, dest); fmt_helper::append_string_view(days[static_cast<size_t>(tm_time.tm_wday)], dest); dest.push_back(' '); fmt_helper::append_string_view(months[static_cast<size_t>(tm_time.tm_mon)], dest); dest.push_back(' '); fmt_helper::append_int(tm_time.tm_mday, dest); dest.push_back(' '); // time fmt_helper::pad2(tm_time.tm_hour, dest); dest.push_back(':'); fmt_helper::pad2(tm_time.tm_min, dest); dest.push_back(':'); fmt_helper::pad2(tm_time.tm_sec, dest); dest.push_back(' '); fmt_helper::append_int(tm_time.tm_year + 1900, dest); }
O3
c
spdlog::details::c_formatter<spdlog::details::null_scoped_padder>::format(spdlog::details::log_msg const&, tm const&, fmt::v10::basic_memory_buffer<char, 250ul, std::allocator<char>>&): pushq %r15 pushq %r14 pushq %r12 pushq %rbx subq $0x28, %rsp movq %rcx, %rbx movq %rdx, %r14 movslq 0x18(%rdx), %rax leaq 0x78a68(%rip), %rcx # 0xb0e58 movq (%rcx,%rax,8), %r15 movq %r15, %rdi callq 0x114d0 leaq (%rax,%r15), %rdx movq %rbx, %rdi movq %r15, %rsi callq 0x2fac6 movq 0x10(%rbx), %rax leaq 0x1(%rax), %rsi cmpq %rsi, 0x18(%rbx) jae 0x38429 movq (%rbx), %rax movq %rbx, %rdi callq *(%rax) movq 0x10(%rbx), %rax leaq 0x1(%rax), %rsi movq 0x8(%rbx), %rcx movq %rsi, 0x10(%rbx) movb $0x20, (%rcx,%rax) movslq 0x10(%r14), %rax leaq 0x78a88(%rip), %rcx # 0xb0ec8 movq (%rcx,%rax,8), %r15 movq %r15, %rdi callq 0x114d0 leaq (%rax,%r15), %rdx movq %rbx, %rdi movq %r15, %rsi callq 0x2fac6 movq 0x10(%rbx), %rax leaq 0x1(%rax), %rsi cmpq %rsi, 0x18(%rbx) jae 0x38479 movq (%rbx), %rax movq %rbx, %rdi callq *(%rax) movq 0x10(%rbx), %rax leaq 0x1(%rax), %rsi movq 0x8(%rbx), %rcx movq %rsi, 0x10(%rbx) movb $0x20, (%rcx,%rax) movl 0xc(%r14), %esi movq %rsp, %r15 movq %r15, %rdi callq 0x34bfc movq %rax, 0x18(%r15) leaq 0x15(%rsp), %rdx movq %rbx, %rdi movq %rax, %rsi callq 0x2fac6 movq 0x10(%rbx), %rax leaq 0x1(%rax), %rsi cmpq %rsi, 0x18(%rbx) jae 0x384c6 movq (%rbx), %rax movq %rbx, %rdi callq *(%rax) movq 0x10(%rbx), %rax leaq 0x1(%rax), %rsi movq 0x8(%rbx), %rcx movq %rsi, 0x10(%rbx) movb $0x20, (%rcx,%rax) movl 0x8(%r14), %r15d cmpq $0x63, %r15 ja 0x38553 movzbl %r15b, %eax imull $0xcd, %eax, %r12d shrl $0xb, %r12d leal (%r12,%r12), %eax leal (%rax,%rax,4), %eax subb %al, %r15b orb $0x30, %r12b movq 0x10(%rbx), %rax leaq 0x1(%rax), %rsi cmpq %rsi, 0x18(%rbx) jae 0x38517 movq (%rbx), %rax movq %rbx, %rdi callq *(%rax) movq 0x10(%rbx), %rax leaq 0x1(%rax), %rsi movq 0x8(%rbx), %rcx movq %rsi, 0x10(%rbx) movb %r12b, (%rcx,%rax) orb $0x30, %r15b movq 0x10(%rbx), %rax leaq 0x1(%rax), %rsi cmpq %rsi, 0x18(%rbx) jae 0x38545 movq (%rbx), %rax movq %rbx, %rdi callq *(%rax) movq 0x10(%rbx), %rax leaq 0x1(%rax), %rsi movq 0x8(%rbx), %rcx movq %rsi, 0x10(%rbx) movb %r15b, (%rcx,%rax) jmp 0x38575 movq %rsp, %r8 movq %r15, (%r8) leaq 0x4960b(%rip), %rsi # 0x81b6b movl $0x5, %edx movl $0x1, %ecx movq %rbx, %rdi xorl %r9d, %r9d callq 0x4163d movq 0x10(%rbx), %rax leaq 0x1(%rax), %rsi cmpq %rsi, 0x18(%rbx) jae 0x38593 movq (%rbx), %rax movq %rbx, %rdi callq *(%rax) movq 0x10(%rbx), %rax leaq 0x1(%rax), %rsi movq 0x8(%rbx), %rcx movq %rsi, 0x10(%rbx) movb $0x3a, (%rcx,%rax) movl 0x4(%r14), %r15d cmpq $0x63, %r15 ja 0x38620 movzbl %r15b, %eax imull $0xcd, %eax, %r12d shrl $0xb, %r12d leal (%r12,%r12), %eax leal (%rax,%rax,4), %eax subb %al, %r15b orb $0x30, %r12b movq 0x10(%rbx), %rax leaq 0x1(%rax), %rsi cmpq %rsi, 0x18(%rbx) jae 0x385e4 movq (%rbx), %rax movq %rbx, %rdi callq *(%rax) movq 0x10(%rbx), %rax leaq 0x1(%rax), %rsi movq 0x8(%rbx), %rcx movq %rsi, 0x10(%rbx) movb %r12b, (%rcx,%rax) orb $0x30, %r15b movq 0x10(%rbx), %rax leaq 0x1(%rax), %rsi cmpq %rsi, 0x18(%rbx) jae 0x38612 movq (%rbx), %rax movq %rbx, %rdi callq *(%rax) movq 0x10(%rbx), %rax leaq 0x1(%rax), %rsi movq 0x8(%rbx), %rcx movq %rsi, 0x10(%rbx) movb %r15b, (%rcx,%rax) jmp 0x38642 movq %rsp, %r8 movq %r15, (%r8) leaq 0x4953e(%rip), %rsi # 0x81b6b movl $0x5, %edx movl $0x1, %ecx movq %rbx, %rdi xorl %r9d, %r9d callq 0x4163d movq 0x10(%rbx), %rax leaq 0x1(%rax), %rsi cmpq %rsi, 0x18(%rbx) jae 0x38660 movq (%rbx), %rax movq %rbx, %rdi callq *(%rax) movq 0x10(%rbx), %rax leaq 0x1(%rax), %rsi movq 0x8(%rbx), %rcx movq %rsi, 0x10(%rbx) movb $0x3a, (%rcx,%rax) movl (%r14), %r15d cmpq $0x63, %r15 ja 0x386ec movzbl %r15b, %eax imull $0xcd, %eax, %r12d shrl $0xb, %r12d leal (%r12,%r12), %eax leal (%rax,%rax,4), %eax subb %al, %r15b orb $0x30, %r12b movq 0x10(%rbx), %rax leaq 0x1(%rax), %rsi cmpq %rsi, 0x18(%rbx) jae 0x386b0 movq (%rbx), %rax movq %rbx, %rdi callq *(%rax) movq 0x10(%rbx), %rax leaq 0x1(%rax), %rsi movq 0x8(%rbx), %rcx movq %rsi, 0x10(%rbx) movb %r12b, (%rcx,%rax) orb $0x30, %r15b movq 0x10(%rbx), %rax leaq 0x1(%rax), %rsi cmpq %rsi, 0x18(%rbx) jae 0x386de movq (%rbx), %rax movq %rbx, %rdi callq *(%rax) movq 0x10(%rbx), %rax leaq 0x1(%rax), %rsi movq 0x8(%rbx), %rcx movq %rsi, 0x10(%rbx) movb %r15b, (%rcx,%rax) jmp 0x3870e movq %rsp, %r8 movq %r15, (%r8) leaq 0x49472(%rip), %rsi # 0x81b6b movl $0x5, %edx movl $0x1, %ecx movq %rbx, %rdi xorl %r9d, %r9d callq 0x4163d movq 0x10(%rbx), %rax leaq 0x1(%rax), %rsi cmpq %rsi, 0x18(%rbx) jae 0x3872c movq (%rbx), %rax movq %rbx, %rdi callq *(%rax) movq 0x10(%rbx), %rax leaq 0x1(%rax), %rsi movq 0x8(%rbx), %rcx movq %rsi, 0x10(%rbx) movb $0x20, (%rcx,%rax) movl $0x76c, %esi # imm = 0x76C addl 0x14(%r14), %esi movq %rsp, %r14 movq %r14, %rdi callq 0x34bfc movq %rax, 0x18(%r14) leaq 0x15(%rsp), %rdx movq %rbx, %rdi movq %rax, %rsi callq 0x2fac6 addq $0x28, %rsp popq %rbx popq %r12 popq %r14 popq %r15 retq
_ZN6spdlog7details11c_formatterINS0_18null_scoped_padderEE6formatERKNS0_7log_msgERK2tmRN3fmt3v1019basic_memory_bufferIcLm250ESaIcEEE: push r15 push r14 push r12 push rbx sub rsp, 28h mov rbx, rcx mov r14, rdx movsxd rax, dword ptr [rdx+18h] lea rcx, _ZN6spdlog7detailsL4daysE; spdlog::details::days mov r15, [rcx+rax*8] mov rdi, r15 call _strlen lea rdx, [rax+r15] mov rdi, rbx mov rsi, r15 call _ZN3fmt3v106detail6bufferIcE6appendIcEEvPKT_S7_; fmt::v10::detail::buffer<char>::append<char>(char const*,char const*) mov rax, [rbx+10h] lea rsi, [rax+1] cmp [rbx+18h], rsi jnb short loc_38429 mov rax, [rbx] mov rdi, rbx call qword ptr [rax] mov rax, [rbx+10h] lea rsi, [rax+1] loc_38429: mov rcx, [rbx+8] mov [rbx+10h], rsi mov byte ptr [rcx+rax], 20h ; ' ' movsxd rax, dword ptr [r14+10h] lea rcx, _ZN6spdlog7detailsL6monthsE; spdlog::details::months mov r15, [rcx+rax*8] mov rdi, r15 call _strlen lea rdx, [rax+r15] mov rdi, rbx mov rsi, r15 call _ZN3fmt3v106detail6bufferIcE6appendIcEEvPKT_S7_; fmt::v10::detail::buffer<char>::append<char>(char const*,char const*) mov rax, [rbx+10h] lea rsi, [rax+1] cmp [rbx+18h], rsi jnb short loc_38479 mov rax, [rbx] mov rdi, rbx call qword ptr [rax] mov rax, [rbx+10h] lea rsi, [rax+1] loc_38479: mov rcx, [rbx+8] mov [rbx+10h], rsi mov byte ptr [rcx+rax], 20h ; ' ' mov esi, [r14+0Ch] mov r15, rsp mov rdi, r15 call _ZN3fmt3v1010format_int13format_signedIiEEPcT_; fmt::v10::format_int::format_signed<int>(int) mov [r15+18h], rax lea rdx, [rsp+48h+var_33] mov rdi, rbx mov rsi, rax call _ZN3fmt3v106detail6bufferIcE6appendIcEEvPKT_S7_; fmt::v10::detail::buffer<char>::append<char>(char const*,char const*) mov rax, [rbx+10h] lea rsi, [rax+1] cmp [rbx+18h], rsi jnb short loc_384C6 mov rax, [rbx] mov rdi, rbx call qword ptr [rax] mov rax, [rbx+10h] lea rsi, [rax+1] loc_384C6: mov rcx, [rbx+8] mov [rbx+10h], rsi mov byte ptr [rcx+rax], 20h ; ' ' mov r15d, [r14+8] cmp r15, 63h ; 'c' ja short loc_38553 movzx eax, r15b imul r12d, eax, 0CDh shr r12d, 0Bh lea eax, [r12+r12] lea eax, [rax+rax*4] sub r15b, al or r12b, 30h mov rax, [rbx+10h] lea rsi, [rax+1] cmp [rbx+18h], rsi jnb short loc_38517 mov rax, [rbx] mov rdi, rbx call qword ptr [rax] mov rax, [rbx+10h] lea rsi, [rax+1] loc_38517: mov rcx, [rbx+8] mov [rbx+10h], rsi mov [rcx+rax], r12b or r15b, 30h mov rax, [rbx+10h] lea rsi, [rax+1] cmp [rbx+18h], rsi jnb short loc_38545 mov rax, [rbx] mov rdi, rbx call qword ptr [rax] mov rax, [rbx+10h] lea rsi, [rax+1] loc_38545: mov rcx, [rbx+8] mov [rbx+10h], rsi mov [rcx+rax], r15b jmp short loc_38575 loc_38553: mov r8, rsp mov [r8], r15 lea rsi, a02; "{:02}" mov edx, 5 mov ecx, 1 mov rdi, rbx; int xor r9d, r9d call _ZN3fmt3v106detail10vformat_toIcEEvRNS1_6bufferIT_EENS0_17basic_string_viewIS4_EENS1_12vformat_argsIS4_E4typeENS1_10locale_refE; fmt::v10::detail::vformat_to<char>(fmt::v10::detail::buffer<char> &,fmt::v10::basic_string_view<char>,fmt::v10::detail::vformat_args<char>::type,fmt::v10::detail::locale_ref) loc_38575: mov rax, [rbx+10h] lea rsi, [rax+1] cmp [rbx+18h], rsi jnb short loc_38593 mov rax, [rbx] mov rdi, rbx call qword ptr [rax] mov rax, [rbx+10h] lea rsi, [rax+1] loc_38593: mov rcx, [rbx+8] mov [rbx+10h], rsi mov byte ptr [rcx+rax], 3Ah ; ':' mov r15d, [r14+4] cmp r15, 63h ; 'c' ja short loc_38620 movzx eax, r15b imul r12d, eax, 0CDh shr r12d, 0Bh lea eax, [r12+r12] lea eax, [rax+rax*4] sub r15b, al or r12b, 30h mov rax, [rbx+10h] lea rsi, [rax+1] cmp [rbx+18h], rsi jnb short loc_385E4 mov rax, [rbx] mov rdi, rbx call qword ptr [rax] mov rax, [rbx+10h] lea rsi, [rax+1] loc_385E4: mov rcx, [rbx+8] mov [rbx+10h], rsi mov [rcx+rax], r12b or r15b, 30h mov rax, [rbx+10h] lea rsi, [rax+1] cmp [rbx+18h], rsi jnb short loc_38612 mov rax, [rbx] mov rdi, rbx call qword ptr [rax] mov rax, [rbx+10h] lea rsi, [rax+1] loc_38612: mov rcx, [rbx+8] mov [rbx+10h], rsi mov [rcx+rax], r15b jmp short loc_38642 loc_38620: mov r8, rsp mov [r8], r15 lea rsi, a02; "{:02}" mov edx, 5 mov ecx, 1 mov rdi, rbx; int xor r9d, r9d call _ZN3fmt3v106detail10vformat_toIcEEvRNS1_6bufferIT_EENS0_17basic_string_viewIS4_EENS1_12vformat_argsIS4_E4typeENS1_10locale_refE; fmt::v10::detail::vformat_to<char>(fmt::v10::detail::buffer<char> &,fmt::v10::basic_string_view<char>,fmt::v10::detail::vformat_args<char>::type,fmt::v10::detail::locale_ref) loc_38642: mov rax, [rbx+10h] lea rsi, [rax+1] cmp [rbx+18h], rsi jnb short loc_38660 mov rax, [rbx] mov rdi, rbx call qword ptr [rax] mov rax, [rbx+10h] lea rsi, [rax+1] loc_38660: mov rcx, [rbx+8] mov [rbx+10h], rsi mov byte ptr [rcx+rax], 3Ah ; ':' mov r15d, [r14] cmp r15, 63h ; 'c' ja short loc_386EC movzx eax, r15b imul r12d, eax, 0CDh shr r12d, 0Bh lea eax, [r12+r12] lea eax, [rax+rax*4] sub r15b, al or r12b, 30h mov rax, [rbx+10h] lea rsi, [rax+1] cmp [rbx+18h], rsi jnb short loc_386B0 mov rax, [rbx] mov rdi, rbx call qword ptr [rax] mov rax, [rbx+10h] lea rsi, [rax+1] loc_386B0: mov rcx, [rbx+8] mov [rbx+10h], rsi mov [rcx+rax], r12b or r15b, 30h mov rax, [rbx+10h] lea rsi, [rax+1] cmp [rbx+18h], rsi jnb short loc_386DE mov rax, [rbx] mov rdi, rbx call qword ptr [rax] mov rax, [rbx+10h] lea rsi, [rax+1] loc_386DE: mov rcx, [rbx+8] mov [rbx+10h], rsi mov [rcx+rax], r15b jmp short loc_3870E loc_386EC: mov r8, rsp mov [r8], r15 lea rsi, a02; "{:02}" mov edx, 5 mov ecx, 1 mov rdi, rbx; int xor r9d, r9d call _ZN3fmt3v106detail10vformat_toIcEEvRNS1_6bufferIT_EENS0_17basic_string_viewIS4_EENS1_12vformat_argsIS4_E4typeENS1_10locale_refE; fmt::v10::detail::vformat_to<char>(fmt::v10::detail::buffer<char> &,fmt::v10::basic_string_view<char>,fmt::v10::detail::vformat_args<char>::type,fmt::v10::detail::locale_ref) loc_3870E: mov rax, [rbx+10h] lea rsi, [rax+1] cmp [rbx+18h], rsi jnb short loc_3872C mov rax, [rbx] mov rdi, rbx call qword ptr [rax] mov rax, [rbx+10h] lea rsi, [rax+1] loc_3872C: mov rcx, [rbx+8] mov [rbx+10h], rsi mov byte ptr [rcx+rax], 20h ; ' ' mov esi, 76Ch add esi, [r14+14h] mov r14, rsp mov rdi, r14 call _ZN3fmt3v1010format_int13format_signedIiEEPcT_; fmt::v10::format_int::format_signed<int>(int) mov [r14+18h], rax lea rdx, [rsp+48h+var_33] mov rdi, rbx mov rsi, rax call _ZN3fmt3v106detail6bufferIcE6appendIcEEvPKT_S7_; fmt::v10::detail::buffer<char>::append<char>(char const*,char const*) add rsp, 28h pop rbx pop r12 pop r14 pop r15 retn
long long spdlog::details::c_formatter<spdlog::details::null_scoped_padder>::format( long long a1, long long a2, unsigned int *a3, long long a4) { char *v6; // r15 long long v7; // rax long long v8; // rax long long v9; // rsi long long v10; // rcx char *v11; // r15 long long v12; // rax long long v13; // rax long long v14; // rsi long long v15; // rcx long long v16; // rax long long v17; // rsi long long v18; // rcx unsigned long long v19; // r15 char v20; // r12 char v21; // r15 char v22; // r12 long long v23; // rax long long v24; // rsi long long v25; // rcx char v26; // r15 long long v27; // rax long long v28; // rsi long long v29; // rcx long long v30; // rax long long v31; // rsi long long v32; // rcx unsigned long long v33; // r15 char v34; // r12 char v35; // r15 char v36; // r12 long long v37; // rax long long v38; // rsi long long v39; // rcx char v40; // r15 long long v41; // rax long long v42; // rsi long long v43; // rcx long long v44; // rax long long v45; // rsi long long v46; // rcx unsigned long long v47; // r15 char v48; // r12 char v49; // r15 char v50; // r12 long long v51; // rax long long v52; // rsi long long v53; // rcx char v54; // r15 long long v55; // rax long long v56; // rsi long long v57; // rcx long long v58; // rax long long v59; // rsi long long v60; // rcx _QWORD v62[2]; // [rsp+0h] [rbp-48h] BYREF _BYTE v63[3]; // [rsp+15h] [rbp-33h] BYREF long long v64; // [rsp+18h] [rbp-30h] v6 = spdlog::details::days[a3[6]]; v7 = strlen(v6); fmt::v10::detail::buffer<char>::append<char>(a4, (long long)v6, (long long)&v6[v7]); v8 = *(_QWORD *)(a4 + 16); v9 = v8 + 1; if ( *(_QWORD *)(a4 + 24) < (unsigned long long)(v8 + 1) ) { (**(void ( ***)(long long))a4)(a4); v8 = *(_QWORD *)(a4 + 16); v9 = v8 + 1; } v10 = *(_QWORD *)(a4 + 8); *(_QWORD *)(a4 + 16) = v9; *(_BYTE *)(v10 + v8) = 32; v11 = spdlog::details::months[a3[4]]; v12 = strlen(v11); fmt::v10::detail::buffer<char>::append<char>(a4, (long long)v11, (long long)&v11[v12]); v13 = *(_QWORD *)(a4 + 16); v14 = v13 + 1; if ( *(_QWORD *)(a4 + 24) < (unsigned long long)(v13 + 1) ) { (**(void ( ***)(long long))a4)(a4); v13 = *(_QWORD *)(a4 + 16); v14 = v13 + 1; } v15 = *(_QWORD *)(a4 + 8); *(_QWORD *)(a4 + 16) = v14; *(_BYTE *)(v15 + v13) = 32; v64 = fmt::v10::format_int::format_signed<int>((long long)v62, a3[3]); fmt::v10::detail::buffer<char>::append<char>(a4, v64, (long long)v63); v16 = *(_QWORD *)(a4 + 16); v17 = v16 + 1; if ( *(_QWORD *)(a4 + 24) < (unsigned long long)(v16 + 1) ) { (**(void ( ***)(long long))a4)(a4); v16 = *(_QWORD *)(a4 + 16); v17 = v16 + 1; } v18 = *(_QWORD *)(a4 + 8); *(_QWORD *)(a4 + 16) = v17; *(_BYTE *)(v18 + v16) = 32; v19 = a3[2]; if ( v19 > 0x63 ) { v62[0] = a3[2]; fmt::v10::detail::vformat_to<char>(a4); } else { v20 = (unsigned __int8)v19 / 0xAu; v21 = (unsigned __int8)v19 % 0xAu; v22 = v20 | 0x30; v23 = *(_QWORD *)(a4 + 16); v24 = v23 + 1; if ( *(_QWORD *)(a4 + 24) < (unsigned long long)(v23 + 1) ) { (**(void ( ***)(long long))a4)(a4); v23 = *(_QWORD *)(a4 + 16); v24 = v23 + 1; } v25 = *(_QWORD *)(a4 + 8); *(_QWORD *)(a4 + 16) = v24; *(_BYTE *)(v25 + v23) = v22; v26 = v21 | 0x30; v27 = *(_QWORD *)(a4 + 16); v28 = v27 + 1; if ( *(_QWORD *)(a4 + 24) < (unsigned long long)(v27 + 1) ) { (**(void ( ***)(long long))a4)(a4); v27 = *(_QWORD *)(a4 + 16); v28 = v27 + 1; } v29 = *(_QWORD *)(a4 + 8); *(_QWORD *)(a4 + 16) = v28; *(_BYTE *)(v29 + v27) = v26; } v30 = *(_QWORD *)(a4 + 16); v31 = v30 + 1; if ( *(_QWORD *)(a4 + 24) < (unsigned long long)(v30 + 1) ) { (**(void ( ***)(long long))a4)(a4); v30 = *(_QWORD *)(a4 + 16); v31 = v30 + 1; } v32 = *(_QWORD *)(a4 + 8); *(_QWORD *)(a4 + 16) = v31; *(_BYTE *)(v32 + v30) = 58; v33 = a3[1]; if ( v33 > 0x63 ) { v62[0] = a3[1]; fmt::v10::detail::vformat_to<char>(a4); } else { v34 = (unsigned __int8)v33 / 0xAu; v35 = (unsigned __int8)v33 % 0xAu; v36 = v34 | 0x30; v37 = *(_QWORD *)(a4 + 16); v38 = v37 + 1; if ( *(_QWORD *)(a4 + 24) < (unsigned long long)(v37 + 1) ) { (**(void ( ***)(long long))a4)(a4); v37 = *(_QWORD *)(a4 + 16); v38 = v37 + 1; } v39 = *(_QWORD *)(a4 + 8); *(_QWORD *)(a4 + 16) = v38; *(_BYTE *)(v39 + v37) = v36; v40 = v35 | 0x30; v41 = *(_QWORD *)(a4 + 16); v42 = v41 + 1; if ( *(_QWORD *)(a4 + 24) < (unsigned long long)(v41 + 1) ) { (**(void ( ***)(long long))a4)(a4); v41 = *(_QWORD *)(a4 + 16); v42 = v41 + 1; } v43 = *(_QWORD *)(a4 + 8); *(_QWORD *)(a4 + 16) = v42; *(_BYTE *)(v43 + v41) = v40; } v44 = *(_QWORD *)(a4 + 16); v45 = v44 + 1; if ( *(_QWORD *)(a4 + 24) < (unsigned long long)(v44 + 1) ) { (**(void ( ***)(long long))a4)(a4); v44 = *(_QWORD *)(a4 + 16); v45 = v44 + 1; } v46 = *(_QWORD *)(a4 + 8); *(_QWORD *)(a4 + 16) = v45; *(_BYTE *)(v46 + v44) = 58; v47 = *a3; if ( v47 > 0x63 ) { v62[0] = *a3; fmt::v10::detail::vformat_to<char>(a4); } else { v48 = (unsigned __int8)v47 / 0xAu; v49 = (unsigned __int8)v47 % 0xAu; v50 = v48 | 0x30; v51 = *(_QWORD *)(a4 + 16); v52 = v51 + 1; if ( *(_QWORD *)(a4 + 24) < (unsigned long long)(v51 + 1) ) { (**(void ( ***)(long long))a4)(a4); v51 = *(_QWORD *)(a4 + 16); v52 = v51 + 1; } v53 = *(_QWORD *)(a4 + 8); *(_QWORD *)(a4 + 16) = v52; *(_BYTE *)(v53 + v51) = v50; v54 = v49 | 0x30; v55 = *(_QWORD *)(a4 + 16); v56 = v55 + 1; if ( *(_QWORD *)(a4 + 24) < (unsigned long long)(v55 + 1) ) { (**(void ( ***)(long long))a4)(a4); v55 = *(_QWORD *)(a4 + 16); v56 = v55 + 1; } v57 = *(_QWORD *)(a4 + 8); *(_QWORD *)(a4 + 16) = v56; *(_BYTE *)(v57 + v55) = v54; } v58 = *(_QWORD *)(a4 + 16); v59 = v58 + 1; if ( *(_QWORD *)(a4 + 24) < (unsigned long long)(v58 + 1) ) { (**(void ( ***)(long long))a4)(a4); v58 = *(_QWORD *)(a4 + 16); v59 = v58 + 1; } v60 = *(_QWORD *)(a4 + 8); *(_QWORD *)(a4 + 16) = v59; *(_BYTE *)(v60 + v58) = 32; v64 = fmt::v10::format_int::format_signed<int>((long long)v62, a3[5] + 1900); return fmt::v10::detail::buffer<char>::append<char>(a4, v64, (long long)v63); }
format: PUSH R15 PUSH R14 PUSH R12 PUSH RBX SUB RSP,0x28 MOV RBX,RCX MOV R14,RDX MOVSXD RAX,dword ptr [RDX + 0x18] LEA RCX,[0x1b0e58] MOV R15,qword ptr [RCX + RAX*0x8] MOV RDI,R15 CALL 0x001114d0 LEA RDX,[RAX + R15*0x1] MOV RDI,RBX MOV RSI,R15 CALL 0x0012fac6 MOV RAX,qword ptr [RBX + 0x10] LEA RSI,[RAX + 0x1] CMP qword ptr [RBX + 0x18],RSI JNC 0x00138429 MOV RAX,qword ptr [RBX] MOV RDI,RBX CALL qword ptr [RAX] MOV RAX,qword ptr [RBX + 0x10] LEA RSI,[RAX + 0x1] LAB_00138429: MOV RCX,qword ptr [RBX + 0x8] MOV qword ptr [RBX + 0x10],RSI MOV byte ptr [RCX + RAX*0x1],0x20 MOVSXD RAX,dword ptr [R14 + 0x10] LEA RCX,[0x1b0ec8] MOV R15,qword ptr [RCX + RAX*0x8] MOV RDI,R15 CALL 0x001114d0 LEA RDX,[RAX + R15*0x1] MOV RDI,RBX MOV RSI,R15 CALL 0x0012fac6 MOV RAX,qword ptr [RBX + 0x10] LEA RSI,[RAX + 0x1] CMP qword ptr [RBX + 0x18],RSI JNC 0x00138479 MOV RAX,qword ptr [RBX] MOV RDI,RBX CALL qword ptr [RAX] MOV RAX,qword ptr [RBX + 0x10] LEA RSI,[RAX + 0x1] LAB_00138479: MOV RCX,qword ptr [RBX + 0x8] MOV qword ptr [RBX + 0x10],RSI MOV byte ptr [RCX + RAX*0x1],0x20 MOV ESI,dword ptr [R14 + 0xc] MOV R15,RSP MOV RDI,R15 CALL 0x00134bfc MOV qword ptr [R15 + 0x18],RAX LEA RDX,[RSP + 0x15] MOV RDI,RBX MOV RSI,RAX CALL 0x0012fac6 MOV RAX,qword ptr [RBX + 0x10] LEA RSI,[RAX + 0x1] CMP qword ptr [RBX + 0x18],RSI JNC 0x001384c6 MOV RAX,qword ptr [RBX] MOV RDI,RBX CALL qword ptr [RAX] MOV RAX,qword ptr [RBX + 0x10] LEA RSI,[RAX + 0x1] LAB_001384c6: MOV RCX,qword ptr [RBX + 0x8] MOV qword ptr [RBX + 0x10],RSI MOV byte ptr [RCX + RAX*0x1],0x20 MOV R15D,dword ptr [R14 + 0x8] CMP R15,0x63 JA 0x00138553 MOVZX EAX,R15B IMUL R12D,EAX,0xcd SHR R12D,0xb LEA EAX,[R12 + R12*0x1] LEA EAX,[RAX + RAX*0x4] SUB R15B,AL OR R12B,0x30 MOV RAX,qword ptr [RBX + 0x10] LEA RSI,[RAX + 0x1] CMP qword ptr [RBX + 0x18],RSI JNC 0x00138517 MOV RAX,qword ptr [RBX] MOV RDI,RBX CALL qword ptr [RAX] MOV RAX,qword ptr [RBX + 0x10] LEA RSI,[RAX + 0x1] LAB_00138517: MOV RCX,qword ptr [RBX + 0x8] MOV qword ptr [RBX + 0x10],RSI MOV byte ptr [RCX + RAX*0x1],R12B OR R15B,0x30 MOV RAX,qword ptr [RBX + 0x10] LEA RSI,[RAX + 0x1] CMP qword ptr [RBX + 0x18],RSI JNC 0x00138545 MOV RAX,qword ptr [RBX] MOV RDI,RBX CALL qword ptr [RAX] MOV RAX,qword ptr [RBX + 0x10] LEA RSI,[RAX + 0x1] LAB_00138545: MOV RCX,qword ptr [RBX + 0x8] MOV qword ptr [RBX + 0x10],RSI MOV byte ptr [RCX + RAX*0x1],R15B JMP 0x00138575 LAB_00138553: MOV R8,RSP MOV qword ptr [R8],R15 LEA RSI,[0x181b6b] MOV EDX,0x5 MOV ECX,0x1 MOV RDI,RBX XOR R9D,R9D CALL 0x0014163d LAB_00138575: MOV RAX,qword ptr [RBX + 0x10] LEA RSI,[RAX + 0x1] CMP qword ptr [RBX + 0x18],RSI JNC 0x00138593 MOV RAX,qword ptr [RBX] MOV RDI,RBX CALL qword ptr [RAX] MOV RAX,qword ptr [RBX + 0x10] LEA RSI,[RAX + 0x1] LAB_00138593: MOV RCX,qword ptr [RBX + 0x8] MOV qword ptr [RBX + 0x10],RSI MOV byte ptr [RCX + RAX*0x1],0x3a MOV R15D,dword ptr [R14 + 0x4] CMP R15,0x63 JA 0x00138620 MOVZX EAX,R15B IMUL R12D,EAX,0xcd SHR R12D,0xb LEA EAX,[R12 + R12*0x1] LEA EAX,[RAX + RAX*0x4] SUB R15B,AL OR R12B,0x30 MOV RAX,qword ptr [RBX + 0x10] LEA RSI,[RAX + 0x1] CMP qword ptr [RBX + 0x18],RSI JNC 0x001385e4 MOV RAX,qword ptr [RBX] MOV RDI,RBX CALL qword ptr [RAX] MOV RAX,qword ptr [RBX + 0x10] LEA RSI,[RAX + 0x1] LAB_001385e4: MOV RCX,qword ptr [RBX + 0x8] MOV qword ptr [RBX + 0x10],RSI MOV byte ptr [RCX + RAX*0x1],R12B OR R15B,0x30 MOV RAX,qword ptr [RBX + 0x10] LEA RSI,[RAX + 0x1] CMP qword ptr [RBX + 0x18],RSI JNC 0x00138612 MOV RAX,qword ptr [RBX] MOV RDI,RBX CALL qword ptr [RAX] MOV RAX,qword ptr [RBX + 0x10] LEA RSI,[RAX + 0x1] LAB_00138612: MOV RCX,qword ptr [RBX + 0x8] MOV qword ptr [RBX + 0x10],RSI MOV byte ptr [RCX + RAX*0x1],R15B JMP 0x00138642 LAB_00138620: MOV R8,RSP MOV qword ptr [R8],R15 LEA RSI,[0x181b6b] MOV EDX,0x5 MOV ECX,0x1 MOV RDI,RBX XOR R9D,R9D CALL 0x0014163d LAB_00138642: MOV RAX,qword ptr [RBX + 0x10] LEA RSI,[RAX + 0x1] CMP qword ptr [RBX + 0x18],RSI JNC 0x00138660 MOV RAX,qword ptr [RBX] MOV RDI,RBX CALL qword ptr [RAX] MOV RAX,qword ptr [RBX + 0x10] LEA RSI,[RAX + 0x1] LAB_00138660: MOV RCX,qword ptr [RBX + 0x8] MOV qword ptr [RBX + 0x10],RSI MOV byte ptr [RCX + RAX*0x1],0x3a MOV R15D,dword ptr [R14] CMP R15,0x63 JA 0x001386ec MOVZX EAX,R15B IMUL R12D,EAX,0xcd SHR R12D,0xb LEA EAX,[R12 + R12*0x1] LEA EAX,[RAX + RAX*0x4] SUB R15B,AL OR R12B,0x30 MOV RAX,qword ptr [RBX + 0x10] LEA RSI,[RAX + 0x1] CMP qword ptr [RBX + 0x18],RSI JNC 0x001386b0 MOV RAX,qword ptr [RBX] MOV RDI,RBX CALL qword ptr [RAX] MOV RAX,qword ptr [RBX + 0x10] LEA RSI,[RAX + 0x1] LAB_001386b0: MOV RCX,qword ptr [RBX + 0x8] MOV qword ptr [RBX + 0x10],RSI MOV byte ptr [RCX + RAX*0x1],R12B OR R15B,0x30 MOV RAX,qword ptr [RBX + 0x10] LEA RSI,[RAX + 0x1] CMP qword ptr [RBX + 0x18],RSI JNC 0x001386de MOV RAX,qword ptr [RBX] MOV RDI,RBX CALL qword ptr [RAX] MOV RAX,qword ptr [RBX + 0x10] LEA RSI,[RAX + 0x1] LAB_001386de: MOV RCX,qword ptr [RBX + 0x8] MOV qword ptr [RBX + 0x10],RSI MOV byte ptr [RCX + RAX*0x1],R15B JMP 0x0013870e LAB_001386ec: MOV R8,RSP MOV qword ptr [R8],R15 LEA RSI,[0x181b6b] MOV EDX,0x5 MOV ECX,0x1 MOV RDI,RBX XOR R9D,R9D CALL 0x0014163d LAB_0013870e: MOV RAX,qword ptr [RBX + 0x10] LEA RSI,[RAX + 0x1] CMP qword ptr [RBX + 0x18],RSI JNC 0x0013872c MOV RAX,qword ptr [RBX] MOV RDI,RBX CALL qword ptr [RAX] MOV RAX,qword ptr [RBX + 0x10] LEA RSI,[RAX + 0x1] LAB_0013872c: MOV RCX,qword ptr [RBX + 0x8] MOV qword ptr [RBX + 0x10],RSI MOV byte ptr [RCX + RAX*0x1],0x20 MOV ESI,0x76c ADD ESI,dword ptr [R14 + 0x14] MOV R14,RSP MOV RDI,R14 CALL 0x00134bfc MOV qword ptr [R14 + 0x18],RAX LEA RDX,[RSP + 0x15] MOV RDI,RBX MOV RSI,RAX CALL 0x0012fac6 ADD RSP,0x28 POP RBX POP R12 POP R14 POP R15 RET
/* spdlog::details::c_formatter<spdlog::details::null_scoped_padder>::format(spdlog::details::log_msg const&, tm const&, fmt::v10::basic_memory_buffer<char, 250ul, std::allocator<char> >&) */ void __thiscall spdlog::details::c_formatter<spdlog::details::null_scoped_padder>::format (c_formatter<spdlog::details::null_scoped_padder> *this,log_msg *param_1,tm *param_2, basic_memory_buffer *param_3) { uint uVar1; char *pcVar2; byte bVar3; size_t sVar4; long lVar5; ulong uVar6; ulong local_48 [2]; char local_33 [3]; char *local_30; pcVar2 = *(char **)(days + (long)param_2->tm_wday * 8); sVar4 = strlen(pcVar2); fmt::v10::detail::buffer<char>::append<char>((buffer<char> *)param_3,pcVar2,pcVar2 + sVar4); lVar5 = *(long *)(param_3 + 0x10); uVar6 = lVar5 + 1; if (*(ulong *)(param_3 + 0x18) < uVar6) { (*(code *)**(int8 **)param_3)(param_3); lVar5 = *(long *)(param_3 + 0x10); uVar6 = lVar5 + 1; } *(ulong *)(param_3 + 0x10) = uVar6; *(int1 *)(*(long *)(param_3 + 8) + lVar5) = 0x20; pcVar2 = *(char **)(months + (long)param_2->tm_mon * 8); sVar4 = strlen(pcVar2); fmt::v10::detail::buffer<char>::append<char>((buffer<char> *)param_3,pcVar2,pcVar2 + sVar4); lVar5 = *(long *)(param_3 + 0x10); uVar6 = lVar5 + 1; if (*(ulong *)(param_3 + 0x18) < uVar6) { (*(code *)**(int8 **)param_3)(param_3); lVar5 = *(long *)(param_3 + 0x10); uVar6 = lVar5 + 1; } *(ulong *)(param_3 + 0x10) = uVar6; *(int1 *)(*(long *)(param_3 + 8) + lVar5) = 0x20; local_30 = fmt::v10::format_int::format_signed<int>((format_int *)local_48,param_2->tm_mday); fmt::v10::detail::buffer<char>::append<char>((buffer<char> *)param_3,local_30,local_33); lVar5 = *(long *)(param_3 + 0x10); uVar6 = lVar5 + 1; if (*(ulong *)(param_3 + 0x18) < uVar6) { (*(code *)**(int8 **)param_3)(param_3); lVar5 = *(long *)(param_3 + 0x10); uVar6 = lVar5 + 1; } *(ulong *)(param_3 + 0x10) = uVar6; *(int1 *)(*(long *)(param_3 + 8) + lVar5) = 0x20; uVar1 = param_2->tm_hour; if ((ulong)uVar1 < 100) { bVar3 = (byte)((uVar1 & 0xff) / 10); lVar5 = *(long *)(param_3 + 0x10); uVar6 = lVar5 + 1; if (*(ulong *)(param_3 + 0x18) < uVar6) { (*(code *)**(int8 **)param_3)(param_3); lVar5 = *(long *)(param_3 + 0x10); uVar6 = lVar5 + 1; } *(ulong *)(param_3 + 0x10) = uVar6; *(byte *)(*(long *)(param_3 + 8) + lVar5) = bVar3 | 0x30; lVar5 = *(long *)(param_3 + 0x10); uVar6 = lVar5 + 1; if (*(ulong *)(param_3 + 0x18) < uVar6) { (*(code *)**(int8 **)param_3)(param_3); lVar5 = *(long *)(param_3 + 0x10); uVar6 = lVar5 + 1; } *(ulong *)(param_3 + 0x10) = uVar6; *(byte *)(*(long *)(param_3 + 8) + lVar5) = (char)uVar1 + bVar3 * -10 | 0x30; } else { local_48[0] = (ulong)uVar1; fmt::v10::detail::vformat_to<char>(param_3,"{:02}",5,1,local_48,0); } lVar5 = *(long *)(param_3 + 0x10); uVar6 = lVar5 + 1; if (*(ulong *)(param_3 + 0x18) < uVar6) { (*(code *)**(int8 **)param_3)(param_3); lVar5 = *(long *)(param_3 + 0x10); uVar6 = lVar5 + 1; } *(ulong *)(param_3 + 0x10) = uVar6; *(int1 *)(*(long *)(param_3 + 8) + lVar5) = 0x3a; uVar1 = param_2->tm_min; if ((ulong)uVar1 < 100) { bVar3 = (byte)((uVar1 & 0xff) / 10); lVar5 = *(long *)(param_3 + 0x10); uVar6 = lVar5 + 1; if (*(ulong *)(param_3 + 0x18) < uVar6) { (*(code *)**(int8 **)param_3)(param_3); lVar5 = *(long *)(param_3 + 0x10); uVar6 = lVar5 + 1; } *(ulong *)(param_3 + 0x10) = uVar6; *(byte *)(*(long *)(param_3 + 8) + lVar5) = bVar3 | 0x30; lVar5 = *(long *)(param_3 + 0x10); uVar6 = lVar5 + 1; if (*(ulong *)(param_3 + 0x18) < uVar6) { (*(code *)**(int8 **)param_3)(param_3); lVar5 = *(long *)(param_3 + 0x10); uVar6 = lVar5 + 1; } *(ulong *)(param_3 + 0x10) = uVar6; *(byte *)(*(long *)(param_3 + 8) + lVar5) = (char)uVar1 + bVar3 * -10 | 0x30; } else { local_48[0] = (ulong)uVar1; fmt::v10::detail::vformat_to<char>(param_3,"{:02}",5,1,local_48,0); } lVar5 = *(long *)(param_3 + 0x10); uVar6 = lVar5 + 1; if (*(ulong *)(param_3 + 0x18) < uVar6) { (*(code *)**(int8 **)param_3)(param_3); lVar5 = *(long *)(param_3 + 0x10); uVar6 = lVar5 + 1; } *(ulong *)(param_3 + 0x10) = uVar6; *(int1 *)(*(long *)(param_3 + 8) + lVar5) = 0x3a; uVar1 = param_2->tm_sec; if ((ulong)uVar1 < 100) { bVar3 = (byte)((uVar1 & 0xff) / 10); lVar5 = *(long *)(param_3 + 0x10); uVar6 = lVar5 + 1; if (*(ulong *)(param_3 + 0x18) < uVar6) { (*(code *)**(int8 **)param_3)(param_3); lVar5 = *(long *)(param_3 + 0x10); uVar6 = lVar5 + 1; } *(ulong *)(param_3 + 0x10) = uVar6; *(byte *)(*(long *)(param_3 + 8) + lVar5) = bVar3 | 0x30; lVar5 = *(long *)(param_3 + 0x10); uVar6 = lVar5 + 1; if (*(ulong *)(param_3 + 0x18) < uVar6) { (*(code *)**(int8 **)param_3)(param_3); lVar5 = *(long *)(param_3 + 0x10); uVar6 = lVar5 + 1; } *(ulong *)(param_3 + 0x10) = uVar6; *(byte *)(*(long *)(param_3 + 8) + lVar5) = (char)uVar1 + bVar3 * -10 | 0x30; } else { local_48[0] = (ulong)uVar1; fmt::v10::detail::vformat_to<char>(param_3,"{:02}",5,1,local_48,0); } lVar5 = *(long *)(param_3 + 0x10); uVar6 = lVar5 + 1; if (*(ulong *)(param_3 + 0x18) < uVar6) { (*(code *)**(int8 **)param_3)(param_3); lVar5 = *(long *)(param_3 + 0x10); uVar6 = lVar5 + 1; } *(ulong *)(param_3 + 0x10) = uVar6; *(int1 *)(*(long *)(param_3 + 8) + lVar5) = 0x20; local_30 = fmt::v10::format_int::format_signed<int> ((format_int *)local_48,param_2->tm_year + 0x76c); fmt::v10::detail::buffer<char>::append<char>((buffer<char> *)param_3,local_30,local_33); return; }
31,814
js_array_cmp_generic
bluesky950520[P]quickjs/quickjs.c
static int js_array_cmp_generic(const void *a, const void *b, void *opaque) { struct array_sort_context *psc = opaque; JSContext *ctx = psc->ctx; JSValue argv[2]; JSValue res; ValueSlot *ap = (ValueSlot *)(void *)a; ValueSlot *bp = (ValueSlot *)(void *)b; int cmp; if (psc->exception) return 0; if (psc->has_method) { /* custom sort function is specified as returning 0 for identical * objects: avoid method call overhead. */ if (!memcmp(&ap->val, &bp->val, sizeof(ap->val))) goto cmp_same; argv[0] = ap->val; argv[1] = bp->val; res = JS_Call(ctx, psc->method, JS_UNDEFINED, 2, argv); if (JS_IsException(res)) goto exception; if (JS_VALUE_GET_TAG(res) == JS_TAG_INT) { int val = JS_VALUE_GET_INT(res); cmp = (val > 0) - (val < 0); } else { double val; if (JS_ToFloat64Free(ctx, &val, res) < 0) goto exception; cmp = (val > 0) - (val < 0); } } else { /* Not supposed to bypass ToString even for identical objects as * tested in test262/test/built-ins/Array/prototype/sort/bug_596_1.js */ if (!ap->str) { JSValue str = JS_ToString(ctx, ap->val); if (JS_IsException(str)) goto exception; ap->str = JS_VALUE_GET_STRING(str); } if (!bp->str) { JSValue str = JS_ToString(ctx, bp->val); if (JS_IsException(str)) goto exception; bp->str = JS_VALUE_GET_STRING(str); } cmp = js_string_compare(ap->str, bp->str); } if (cmp != 0) return cmp; cmp_same: /* make sort stable: compare array offsets */ return (ap->pos > bp->pos) - (ap->pos < bp->pos); exception: psc->exception = 1; return 0; }
O0
c
js_array_cmp_generic: subq $0xd8, %rsp movq %rdi, 0xc8(%rsp) movq %rsi, 0xc0(%rsp) movq %rdx, 0xb8(%rsp) movq 0xb8(%rsp), %rax movq %rax, 0xb0(%rsp) movq 0xb0(%rsp), %rax movq (%rax), %rax movq %rax, 0xa8(%rsp) movq 0xc8(%rsp), %rax movq %rax, 0x68(%rsp) movq 0xc0(%rsp), %rax movq %rax, 0x60(%rsp) movq 0xb0(%rsp), %rax cmpl $0x0, 0x8(%rax) je 0xd4b9a movl $0x0, 0xd4(%rsp) jmp 0xd4e53 movq 0xb0(%rsp), %rax cmpl $0x0, 0xc(%rax) je 0xd4d1f movq 0x68(%rsp), %rax movq 0x60(%rsp), %rcx movups (%rcx), %xmm1 movups (%rax), %xmm0 pcmpeqb %xmm1, %xmm0 pmovmskb %xmm0, %eax subl $0xffff, %eax # imm = 0xFFFF setne %al movzbl %al, %eax cmpl $0x0, %eax jne 0xd4bd9 jmp 0xd4df9 movq 0x68(%rsp), %rax movq (%rax), %rcx movq %rcx, 0x80(%rsp) movq 0x8(%rax), %rax movq %rax, 0x88(%rsp) movq 0x60(%rsp), %rax movq (%rax), %rcx movq %rcx, 0x90(%rsp) movq 0x8(%rax), %rax movq %rax, 0x98(%rsp) movq 0xa8(%rsp), %rdi movq 0xb0(%rsp), %rcx movl $0x0, 0x38(%rsp) movq $0x3, 0x40(%rsp) leaq 0x80(%rsp), %rax movq 0x10(%rcx), %rsi movq 0x18(%rcx), %rdx movq 0x38(%rsp), %rcx movq 0x40(%rsp), %r8 movl $0x2, %r9d movq %rax, (%rsp) callq 0x40340 movq %rax, 0x48(%rsp) movq %rdx, 0x50(%rsp) movq 0x48(%rsp), %rax movq %rax, 0x70(%rsp) movq 0x50(%rsp), %rax movq %rax, 0x78(%rsp) movq 0x70(%rsp), %rdi movq 0x78(%rsp), %rsi callq 0x29fb0 cmpl $0x0, %eax je 0xd4c92 jmp 0xd4e39 movq 0x78(%rsp), %rax cmpl $0x0, %eax jne 0xd4cc7 movl 0x70(%rsp), %eax movl %eax, 0x34(%rsp) cmpl $0x0, 0x34(%rsp) setg %al andb $0x1, %al movzbl %al, %eax cmpl $0x0, 0x34(%rsp) setl %cl andb $0x1, %cl movzbl %cl, %ecx subl %ecx, %eax movl %eax, 0x5c(%rsp) jmp 0xd4d1a movq 0xa8(%rsp), %rdi movq 0x70(%rsp), %rdx movq 0x78(%rsp), %rcx leaq 0x28(%rsp), %rsi callq 0x3e8e0 cmpl $0x0, %eax jge 0xd4ced jmp 0xd4e39 movsd 0x28(%rsp), %xmm0 xorps %xmm1, %xmm1 ucomisd %xmm1, %xmm0 seta %al andb $0x1, %al movzbl %al, %eax xorps %xmm0, %xmm0 ucomisd 0x28(%rsp), %xmm0 seta %cl andb $0x1, %cl movzbl %cl, %ecx subl %ecx, %eax movl %eax, 0x5c(%rsp) jmp 0xd4de3 movq 0x68(%rsp), %rax cmpq $0x0, 0x10(%rax) jne 0xd4d75 movq 0xa8(%rsp), %rdi movq 0x68(%rsp), %rax movq (%rax), %rsi movq 0x8(%rax), %rdx callq 0x30030 movq %rax, 0x18(%rsp) movq %rdx, 0x20(%rsp) movq 0x18(%rsp), %rdi movq 0x20(%rsp), %rsi callq 0x29fb0 cmpl $0x0, %eax je 0xd4d67 jmp 0xd4e39 movq 0x18(%rsp), %rcx movq 0x68(%rsp), %rax movq %rcx, 0x10(%rax) movq 0x60(%rsp), %rax cmpq $0x0, 0x10(%rax) jne 0xd4dc8 movq 0xa8(%rsp), %rdi movq 0x60(%rsp), %rax movq (%rax), %rsi movq 0x8(%rax), %rdx callq 0x30030 movq %rax, 0x8(%rsp) movq %rdx, 0x10(%rsp) movq 0x8(%rsp), %rdi movq 0x10(%rsp), %rsi callq 0x29fb0 cmpl $0x0, %eax je 0xd4dba jmp 0xd4e39 movq 0x8(%rsp), %rcx movq 0x60(%rsp), %rax movq %rcx, 0x10(%rax) movq 0x68(%rsp), %rax movq 0x10(%rax), %rdi movq 0x60(%rsp), %rax movq 0x10(%rax), %rsi callq 0x77df0 movl %eax, 0x5c(%rsp) cmpl $0x0, 0x5c(%rsp) je 0xd4df7 movl 0x5c(%rsp), %eax movl %eax, 0xd4(%rsp) jmp 0xd4e53 jmp 0xd4df9 movq 0x68(%rsp), %rax movq 0x18(%rax), %rax movq 0x60(%rsp), %rcx cmpq 0x18(%rcx), %rax setg %al andb $0x1, %al movzbl %al, %eax movq 0x68(%rsp), %rcx movq 0x18(%rcx), %rcx movq 0x60(%rsp), %rdx cmpq 0x18(%rdx), %rcx setl %cl andb $0x1, %cl movzbl %cl, %ecx subl %ecx, %eax movl %eax, 0xd4(%rsp) jmp 0xd4e53 movq 0xb0(%rsp), %rax movl $0x1, 0x8(%rax) movl $0x0, 0xd4(%rsp) movl 0xd4(%rsp), %eax addq $0xd8, %rsp retq nopw %cs:(%rax,%rax)
js_array_cmp_generic: sub rsp, 0D8h mov [rsp+0D8h+var_10], rdi mov [rsp+0D8h+var_18], rsi mov [rsp+0D8h+var_20], rdx mov rax, [rsp+0D8h+var_20] mov [rsp+0D8h+var_28], rax mov rax, [rsp+0D8h+var_28] mov rax, [rax] mov [rsp+0D8h+var_30], rax mov rax, [rsp+0D8h+var_10] mov [rsp+0D8h+var_70], rax mov rax, [rsp+0D8h+var_18] mov [rsp+0D8h+var_78], rax mov rax, [rsp+0D8h+var_28] cmp dword ptr [rax+8], 0 jz short loc_D4B9A mov [rsp+0D8h+var_4], 0 jmp loc_D4E53 loc_D4B9A: mov rax, [rsp+0D8h+var_28] cmp dword ptr [rax+0Ch], 0 jz loc_D4D1F mov rax, [rsp+0D8h+var_70] mov rcx, [rsp+0D8h+var_78] movups xmm1, xmmword ptr [rcx] movups xmm0, xmmword ptr [rax] pcmpeqb xmm0, xmm1 pmovmskb eax, xmm0 sub eax, 0FFFFh setnz al movzx eax, al cmp eax, 0 jnz short loc_D4BD9 jmp loc_D4DF9 loc_D4BD9: mov rax, [rsp+0D8h+var_70] mov rcx, [rax] mov [rsp+0D8h+var_58], rcx mov rax, [rax+8] mov [rsp+0D8h+var_50], rax mov rax, [rsp+0D8h+var_78] mov rcx, [rax] mov [rsp+0D8h+var_48], rcx mov rax, [rax+8] mov [rsp+0D8h+var_40], rax mov rdi, [rsp+0D8h+var_30] mov rcx, [rsp+0D8h+var_28] mov dword ptr [rsp+0D8h+var_A0], 0 mov [rsp+0D8h+var_98], 3 lea rax, [rsp+0D8h+var_58] mov rsi, [rcx+10h] mov rdx, [rcx+18h] mov rcx, [rsp+0D8h+var_A0] mov r8, [rsp+0D8h+var_98] mov r9d, 2 mov [rsp+0D8h+var_D8], rax call JS_Call mov [rsp+0D8h+var_90], rax mov [rsp+0D8h+var_88], rdx mov rax, [rsp+0D8h+var_90] mov [rsp+0D8h+var_68], rax mov rax, [rsp+0D8h+var_88] mov [rsp+0D8h+var_60], rax mov rdi, [rsp+0D8h+var_68] mov rsi, [rsp+0D8h+var_60] call JS_IsException_1 cmp eax, 0 jz short loc_D4C92 jmp loc_D4E39 loc_D4C92: mov rax, [rsp+0D8h+var_60] cmp eax, 0 jnz short loc_D4CC7 mov eax, dword ptr [rsp+0D8h+var_68] mov [rsp+0D8h+var_A4], eax cmp [rsp+0D8h+var_A4], 0 setnle al and al, 1 movzx eax, al cmp [rsp+0D8h+var_A4], 0 setl cl and cl, 1 movzx ecx, cl sub eax, ecx mov [rsp+0D8h+var_7C], eax jmp short loc_D4D1A loc_D4CC7: mov rdi, [rsp+0D8h+var_30] mov rdx, [rsp+0D8h+var_68] mov rcx, [rsp+0D8h+var_60] lea rsi, [rsp+0D8h+var_B0] call JS_ToFloat64Free cmp eax, 0 jge short loc_D4CED jmp loc_D4E39 loc_D4CED: movsd xmm0, [rsp+0D8h+var_B0] xorps xmm1, xmm1 ucomisd xmm0, xmm1 setnbe al and al, 1 movzx eax, al xorps xmm0, xmm0 ucomisd xmm0, [rsp+0D8h+var_B0] setnbe cl and cl, 1 movzx ecx, cl sub eax, ecx mov [rsp+0D8h+var_7C], eax loc_D4D1A: jmp loc_D4DE3 loc_D4D1F: mov rax, [rsp+0D8h+var_70] cmp qword ptr [rax+10h], 0 jnz short loc_D4D75 mov rdi, [rsp+0D8h+var_30] mov rax, [rsp+0D8h+var_70] mov rsi, [rax] mov rdx, [rax+8] call JS_ToString mov [rsp+0D8h+var_C0], rax mov [rsp+0D8h+var_B8], rdx mov rdi, [rsp+0D8h+var_C0] mov rsi, [rsp+0D8h+var_B8] call JS_IsException_1 cmp eax, 0 jz short loc_D4D67 jmp loc_D4E39 loc_D4D67: mov rcx, [rsp+0D8h+var_C0] mov rax, [rsp+0D8h+var_70] mov [rax+10h], rcx loc_D4D75: mov rax, [rsp+0D8h+var_78] cmp qword ptr [rax+10h], 0 jnz short loc_D4DC8 mov rdi, [rsp+0D8h+var_30] mov rax, [rsp+0D8h+var_78] mov rsi, [rax] mov rdx, [rax+8] call JS_ToString mov [rsp+0D8h+var_D0], rax mov [rsp+0D8h+var_C8], rdx mov rdi, [rsp+0D8h+var_D0] mov rsi, [rsp+0D8h+var_C8] call JS_IsException_1 cmp eax, 0 jz short loc_D4DBA jmp short loc_D4E39 loc_D4DBA: mov rcx, [rsp+0D8h+var_D0] mov rax, [rsp+0D8h+var_78] mov [rax+10h], rcx loc_D4DC8: mov rax, [rsp+0D8h+var_70] mov rdi, [rax+10h] mov rax, [rsp+0D8h+var_78] mov rsi, [rax+10h] call js_string_compare mov [rsp+0D8h+var_7C], eax loc_D4DE3: cmp [rsp+0D8h+var_7C], 0 jz short loc_D4DF7 mov eax, [rsp+0D8h+var_7C] mov [rsp+0D8h+var_4], eax jmp short loc_D4E53 loc_D4DF7: jmp short $+2 loc_D4DF9: mov rax, [rsp+0D8h+var_70] mov rax, [rax+18h] mov rcx, [rsp+0D8h+var_78] cmp rax, [rcx+18h] setnle al and al, 1 movzx eax, al mov rcx, [rsp+0D8h+var_70] mov rcx, [rcx+18h] mov rdx, [rsp+0D8h+var_78] cmp rcx, [rdx+18h] setl cl and cl, 1 movzx ecx, cl sub eax, ecx mov [rsp+0D8h+var_4], eax jmp short loc_D4E53 loc_D4E39: mov rax, [rsp+0D8h+var_28] mov dword ptr [rax+8], 1 mov [rsp+0D8h+var_4], 0 loc_D4E53: mov eax, [rsp+0D8h+var_4] add rsp, 0D8h retn
long long js_array_cmp_generic(__m128i *a1, __m128i *a2, long long a3, long long a4, long long a5, long long a6) { long long v6; // rdx int v7; // edx int v8; // edx long long v10; // [rsp+8h] [rbp-D0h] long long v11; // [rsp+18h] [rbp-C0h] double v12; // [rsp+28h] [rbp-B0h] BYREF int v13; // [rsp+34h] [rbp-A4h] long long v14; // [rsp+38h] [rbp-A0h] long long v15; // [rsp+40h] [rbp-98h] long long v16; // [rsp+48h] [rbp-90h] long long v17; // [rsp+50h] [rbp-88h] unsigned int v18; // [rsp+5Ch] [rbp-7Ch] __m128i *v19; // [rsp+60h] [rbp-78h] __m128i *v20; // [rsp+68h] [rbp-70h] long long v21; // [rsp+70h] [rbp-68h] long long v22; // [rsp+78h] [rbp-60h] _QWORD v23[5]; // [rsp+80h] [rbp-58h] BYREF long long v24; // [rsp+A8h] [rbp-30h] long long v25; // [rsp+B0h] [rbp-28h] long long v26; // [rsp+B8h] [rbp-20h] __m128i *v27; // [rsp+C0h] [rbp-18h] __m128i *v28; // [rsp+C8h] [rbp-10h] v28 = a1; v27 = a2; v26 = a3; v25 = a3; v24 = *(_QWORD *)a3; v20 = a1; v19 = a2; if ( !*(_DWORD *)(a3 + 8) ) { if ( *(_DWORD *)(v25 + 12) ) { if ( _mm_movemask_epi8(_mm_cmpeq_epi8(*v20, *v19)) == 0xFFFF ) return (unsigned int)((v20[1].m128i_i64[1] > v19[1].m128i_i64[1]) - (v20[1].m128i_i64[1] < v19[1].m128i_i64[1])); v23[0] = v20->m128i_i64[0]; v23[1] = v20->m128i_i64[1]; v23[2] = v19->m128i_i64[0]; v23[3] = v19->m128i_i64[1]; LODWORD(v14) = 0; v15 = 3LL; v16 = JS_Call(v24, *(_QWORD *)(v25 + 16), *(_QWORD *)(v25 + 24), 0, 3, 2, (long long)v23); v17 = v6; v21 = v16; v22 = v6; if ( !JS_IsException_1(v16, v6) ) { if ( !(_DWORD)v22 ) { v13 = v21; v18 = ((int)v21 > 0) - ((int)v21 < 0); goto LABEL_17; } if ( (int)JS_ToFloat64Free(v24, &v12, v21, v22) >= 0 ) { v18 = (v12 > 0.0) - (v12 < 0.0); goto LABEL_17; } } LABEL_20: *(_DWORD *)(v25 + 8) = 1; return 0; } if ( !v20[1].m128i_i64[0] ) { v11 = JS_ToString(v24, v20->m128i_i64[0], v20->m128i_i64[1], a4, a5, a6); if ( JS_IsException_1(v11, v7) ) goto LABEL_20; a4 = v11; v20[1].m128i_i64[0] = v11; } if ( !v19[1].m128i_i64[0] ) { v10 = JS_ToString(v24, v19->m128i_i64[0], v19->m128i_i64[1], a4, a5, a6); if ( JS_IsException_1(v10, v8) ) goto LABEL_20; v19[1].m128i_i64[0] = v10; } v18 = js_string_compare(v20[1].m128i_i64[0], v19[1].m128i_i64[0]); LABEL_17: if ( v18 ) return v18; return (unsigned int)((v20[1].m128i_i64[1] > v19[1].m128i_i64[1]) - (v20[1].m128i_i64[1] < v19[1].m128i_i64[1])); } return 0; }
js_array_cmp_generic: SUB RSP,0xd8 MOV qword ptr [RSP + 0xc8],RDI MOV qword ptr [RSP + 0xc0],RSI MOV qword ptr [RSP + 0xb8],RDX MOV RAX,qword ptr [RSP + 0xb8] MOV qword ptr [RSP + 0xb0],RAX MOV RAX,qword ptr [RSP + 0xb0] MOV RAX,qword ptr [RAX] MOV qword ptr [RSP + 0xa8],RAX MOV RAX,qword ptr [RSP + 0xc8] MOV qword ptr [RSP + 0x68],RAX MOV RAX,qword ptr [RSP + 0xc0] MOV qword ptr [RSP + 0x60],RAX MOV RAX,qword ptr [RSP + 0xb0] CMP dword ptr [RAX + 0x8],0x0 JZ 0x001d4b9a MOV dword ptr [RSP + 0xd4],0x0 JMP 0x001d4e53 LAB_001d4b9a: MOV RAX,qword ptr [RSP + 0xb0] CMP dword ptr [RAX + 0xc],0x0 JZ 0x001d4d1f MOV RAX,qword ptr [RSP + 0x68] MOV RCX,qword ptr [RSP + 0x60] MOVUPS XMM1,xmmword ptr [RCX] MOVUPS XMM0,xmmword ptr [RAX] PCMPEQB XMM0,XMM1 PMOVMSKB EAX,XMM0 SUB EAX,0xffff SETNZ AL MOVZX EAX,AL CMP EAX,0x0 JNZ 0x001d4bd9 JMP 0x001d4df9 LAB_001d4bd9: MOV RAX,qword ptr [RSP + 0x68] MOV RCX,qword ptr [RAX] MOV qword ptr [RSP + 0x80],RCX MOV RAX,qword ptr [RAX + 0x8] MOV qword ptr [RSP + 0x88],RAX MOV RAX,qword ptr [RSP + 0x60] MOV RCX,qword ptr [RAX] MOV qword ptr [RSP + 0x90],RCX MOV RAX,qword ptr [RAX + 0x8] MOV qword ptr [RSP + 0x98],RAX MOV RDI,qword ptr [RSP + 0xa8] MOV RCX,qword ptr [RSP + 0xb0] MOV dword ptr [RSP + 0x38],0x0 MOV qword ptr [RSP + 0x40],0x3 LEA RAX,[RSP + 0x80] MOV RSI,qword ptr [RCX + 0x10] MOV RDX,qword ptr [RCX + 0x18] MOV RCX,qword ptr [RSP + 0x38] MOV R8,qword ptr [RSP + 0x40] MOV R9D,0x2 MOV qword ptr [RSP],RAX CALL 0x00140340 MOV qword ptr [RSP + 0x48],RAX MOV qword ptr [RSP + 0x50],RDX MOV RAX,qword ptr [RSP + 0x48] MOV qword ptr [RSP + 0x70],RAX MOV RAX,qword ptr [RSP + 0x50] MOV qword ptr [RSP + 0x78],RAX MOV RDI,qword ptr [RSP + 0x70] MOV RSI,qword ptr [RSP + 0x78] CALL 0x00129fb0 CMP EAX,0x0 JZ 0x001d4c92 JMP 0x001d4e39 LAB_001d4c92: MOV RAX,qword ptr [RSP + 0x78] CMP EAX,0x0 JNZ 0x001d4cc7 MOV EAX,dword ptr [RSP + 0x70] MOV dword ptr [RSP + 0x34],EAX CMP dword ptr [RSP + 0x34],0x0 SETG AL AND AL,0x1 MOVZX EAX,AL CMP dword ptr [RSP + 0x34],0x0 SETL CL AND CL,0x1 MOVZX ECX,CL SUB EAX,ECX MOV dword ptr [RSP + 0x5c],EAX JMP 0x001d4d1a LAB_001d4cc7: MOV RDI,qword ptr [RSP + 0xa8] MOV RDX,qword ptr [RSP + 0x70] MOV RCX,qword ptr [RSP + 0x78] LEA RSI,[RSP + 0x28] CALL 0x0013e8e0 CMP EAX,0x0 JGE 0x001d4ced JMP 0x001d4e39 LAB_001d4ced: MOVSD XMM0,qword ptr [RSP + 0x28] XORPS XMM1,XMM1 UCOMISD XMM0,XMM1 SETA AL AND AL,0x1 MOVZX EAX,AL XORPS XMM0,XMM0 UCOMISD XMM0,qword ptr [RSP + 0x28] SETA CL AND CL,0x1 MOVZX ECX,CL SUB EAX,ECX MOV dword ptr [RSP + 0x5c],EAX LAB_001d4d1a: JMP 0x001d4de3 LAB_001d4d1f: MOV RAX,qword ptr [RSP + 0x68] CMP qword ptr [RAX + 0x10],0x0 JNZ 0x001d4d75 MOV RDI,qword ptr [RSP + 0xa8] MOV RAX,qword ptr [RSP + 0x68] MOV RSI,qword ptr [RAX] MOV RDX,qword ptr [RAX + 0x8] CALL 0x00130030 MOV qword ptr [RSP + 0x18],RAX MOV qword ptr [RSP + 0x20],RDX MOV RDI,qword ptr [RSP + 0x18] MOV RSI,qword ptr [RSP + 0x20] CALL 0x00129fb0 CMP EAX,0x0 JZ 0x001d4d67 JMP 0x001d4e39 LAB_001d4d67: MOV RCX,qword ptr [RSP + 0x18] MOV RAX,qword ptr [RSP + 0x68] MOV qword ptr [RAX + 0x10],RCX LAB_001d4d75: MOV RAX,qword ptr [RSP + 0x60] CMP qword ptr [RAX + 0x10],0x0 JNZ 0x001d4dc8 MOV RDI,qword ptr [RSP + 0xa8] MOV RAX,qword ptr [RSP + 0x60] MOV RSI,qword ptr [RAX] MOV RDX,qword ptr [RAX + 0x8] CALL 0x00130030 MOV qword ptr [RSP + 0x8],RAX MOV qword ptr [RSP + 0x10],RDX MOV RDI,qword ptr [RSP + 0x8] MOV RSI,qword ptr [RSP + 0x10] CALL 0x00129fb0 CMP EAX,0x0 JZ 0x001d4dba JMP 0x001d4e39 LAB_001d4dba: MOV RCX,qword ptr [RSP + 0x8] MOV RAX,qword ptr [RSP + 0x60] MOV qword ptr [RAX + 0x10],RCX LAB_001d4dc8: MOV RAX,qword ptr [RSP + 0x68] MOV RDI,qword ptr [RAX + 0x10] MOV RAX,qword ptr [RSP + 0x60] MOV RSI,qword ptr [RAX + 0x10] CALL 0x00177df0 MOV dword ptr [RSP + 0x5c],EAX LAB_001d4de3: CMP dword ptr [RSP + 0x5c],0x0 JZ 0x001d4df7 MOV EAX,dword ptr [RSP + 0x5c] MOV dword ptr [RSP + 0xd4],EAX JMP 0x001d4e53 LAB_001d4df7: JMP 0x001d4df9 LAB_001d4df9: MOV RAX,qword ptr [RSP + 0x68] MOV RAX,qword ptr [RAX + 0x18] MOV RCX,qword ptr [RSP + 0x60] CMP RAX,qword ptr [RCX + 0x18] SETG AL AND AL,0x1 MOVZX EAX,AL MOV RCX,qword ptr [RSP + 0x68] MOV RCX,qword ptr [RCX + 0x18] MOV RDX,qword ptr [RSP + 0x60] CMP RCX,qword ptr [RDX + 0x18] SETL CL AND CL,0x1 MOVZX ECX,CL SUB EAX,ECX MOV dword ptr [RSP + 0xd4],EAX JMP 0x001d4e53 LAB_001d4e39: MOV RAX,qword ptr [RSP + 0xb0] MOV dword ptr [RAX + 0x8],0x1 MOV dword ptr [RSP + 0xd4],0x0 LAB_001d4e53: MOV EAX,dword ptr [RSP + 0xd4] ADD RSP,0xd8 RET
int js_array_cmp_generic(char *param_1,char *param_2,int8 *param_3) { int1 auVar1 [16]; uint uVar2; uint uVar3; int1 auVar4 [11]; int1 auVar5 [12]; int1 auVar6 [13]; int1 auVar7 [14]; int iVar8; char cVar9; char cVar10; char cVar11; char cVar12; char cVar13; char cVar14; char cVar15; char cVar16; char cVar17; char cVar18; char cVar19; char cVar20; char cVar21; byte bVar22; char cVar23; char cVar24; char cVar25; char cVar26; char cVar27; char cVar28; int1 uVar29; char cVar30; int1 uVar31; char cVar32; int1 uVar33; int1 auVar34 [16]; double local_b0 [2]; int4 local_a0; uint uStack_9c; int8 local_98; int1 local_90 [16]; int local_7c; char *local_78; char *local_70; int1 local_68 [16]; int8 local_58; int8 local_50; int8 local_48; int8 local_40; int8 local_30; int8 *local_28; int8 *local_20; char *local_18; char *local_10; local_30 = *param_3; if (*(int *)(param_3 + 1) != 0) { return 0; } local_78 = param_2; local_70 = param_1; local_28 = param_3; local_20 = param_3; local_18 = param_2; local_10 = param_1; if (*(int *)((long)param_3 + 0xc) == 0) { if (*(long *)(param_1 + 0x10) == 0) { auVar34 = JS_ToString(local_30,*(int8 *)param_1,*(int8 *)(param_1 + 8)); iVar8 = JS_IsException(auVar34._0_8_,auVar34._8_8_); if (iVar8 != 0) goto LAB_001d4e39; *(long *)(local_70 + 0x10) = auVar34._0_8_; } if (*(long *)(local_78 + 0x10) == 0) { auVar34 = JS_ToString(local_30,*(int8 *)local_78,*(int8 *)(local_78 + 8)); iVar8 = JS_IsException(auVar34._0_8_,auVar34._8_8_); if (iVar8 != 0) goto LAB_001d4e39; *(long *)(local_78 + 0x10) = auVar34._0_8_; } local_7c = js_string_compare(*(int8 *)(local_70 + 0x10),*(int8 *)(local_78 + 0x10)); } else { cVar23 = *param_2; cVar24 = param_2[1]; cVar25 = param_2[2]; cVar26 = param_2[3]; cVar27 = param_2[4]; cVar28 = param_2[5]; cVar30 = param_2[6]; cVar32 = param_2[7]; cVar9 = -(param_1[2] == cVar25); cVar10 = -(param_1[3] == cVar26); cVar11 = -(param_1[4] == cVar27); cVar12 = -(param_1[5] == cVar28); cVar13 = -(param_1[6] == cVar30); cVar14 = -(param_1[7] == cVar32); cVar15 = -(param_1[8] == param_2[8]); cVar16 = -(param_1[9] == param_2[9]); cVar17 = -(param_1[10] == param_2[10]); cVar18 = -(param_1[0xb] == param_2[0xb]); cVar19 = -(param_1[0xc] == param_2[0xc]); cVar20 = -(param_1[0xd] == param_2[0xd]); cVar21 = -(param_1[0xe] == param_2[0xe]); bVar22 = -(param_1[0xf] == param_2[0xf]); auVar34[1] = -(param_1[1] == cVar24); auVar34[0] = -(*param_1 == cVar23); auVar34[2] = cVar9; auVar34[3] = cVar10; auVar34[4] = cVar11; auVar34[5] = cVar12; auVar34[6] = cVar13; auVar34[7] = cVar14; auVar34[8] = cVar15; auVar34[9] = cVar16; auVar34[10] = cVar17; auVar34[0xb] = cVar18; auVar34[0xc] = cVar19; auVar34[0xd] = cVar20; auVar34[0xe] = cVar21; auVar34[0xf] = bVar22; auVar1[1] = -(param_1[1] == cVar24); auVar1[0] = -(*param_1 == cVar23); auVar1[2] = cVar9; auVar1[3] = cVar10; auVar1[4] = cVar11; auVar1[5] = cVar12; auVar1[6] = cVar13; auVar1[7] = cVar14; auVar1[8] = cVar15; auVar1[9] = cVar16; auVar1[10] = cVar17; auVar1[0xb] = cVar18; auVar1[0xc] = cVar19; auVar1[0xd] = cVar20; auVar1[0xe] = cVar21; auVar1[0xf] = bVar22; auVar7[1] = cVar10; auVar7[0] = cVar9; auVar7[2] = cVar11; auVar7[3] = cVar12; auVar7[4] = cVar13; auVar7[5] = cVar14; auVar7[6] = cVar15; auVar7[7] = cVar16; auVar7[8] = cVar17; auVar7[9] = cVar18; auVar7[10] = cVar19; auVar7[0xb] = cVar20; auVar7[0xc] = cVar21; auVar7[0xd] = bVar22; auVar6[1] = cVar11; auVar6[0] = cVar10; auVar6[2] = cVar12; auVar6[3] = cVar13; auVar6[4] = cVar14; auVar6[5] = cVar15; auVar6[6] = cVar16; auVar6[7] = cVar17; auVar6[8] = cVar18; auVar6[9] = cVar19; auVar6[10] = cVar20; auVar6[0xb] = cVar21; auVar6[0xc] = bVar22; auVar5[1] = cVar12; auVar5[0] = cVar11; auVar5[2] = cVar13; auVar5[3] = cVar14; auVar5[4] = cVar15; auVar5[5] = cVar16; auVar5[6] = cVar17; auVar5[7] = cVar18; auVar5[8] = cVar19; auVar5[9] = cVar20; auVar5[10] = cVar21; auVar5[0xb] = bVar22; auVar4[1] = cVar13; auVar4[0] = cVar12; auVar4[2] = cVar14; auVar4[3] = cVar15; auVar4[4] = cVar16; auVar4[5] = cVar17; auVar4[6] = cVar18; auVar4[7] = cVar19; auVar4[8] = cVar20; auVar4[9] = cVar21; auVar4[10] = bVar22; if ((ushort)((ushort)(SUB161(auVar34 >> 7,0) & 1) | (ushort)(SUB161(auVar1 >> 0xf,0) & 1) << 1 | (ushort)(SUB141(auVar7 >> 7,0) & 1) << 2 | (ushort)(SUB131(auVar6 >> 7,0) & 1) << 3 | (ushort)(SUB121(auVar5 >> 7,0) & 1) << 4 | (ushort)(SUB111(auVar4 >> 7,0) & 1) << 5 | (ushort)((byte)(CONCAT19(bVar22,CONCAT18(cVar21,CONCAT17(cVar20,CONCAT16(cVar19, CONCAT15(cVar18,CONCAT14(cVar17,CONCAT13(cVar16, CONCAT12(cVar15,CONCAT11(cVar14,cVar13))))))))) >> 7) & 1) << 6 | (ushort)((byte)(CONCAT18(bVar22,CONCAT17(cVar21,CONCAT16(cVar20,CONCAT15(cVar19, CONCAT14(cVar18,CONCAT13(cVar17,CONCAT12(cVar16, CONCAT11(cVar15,cVar14)))))))) >> 7) & 1) << 7 | (ushort)(bVar22 >> 7) << 0xf) == 0xffff) goto LAB_001d4df9; local_58 = *(int8 *)param_1; local_50 = *(int8 *)(param_1 + 8); local_48 = *(int8 *)param_2; local_40 = *(int8 *)(param_2 + 8); local_a0 = 0; local_98 = 3; local_90 = JS_Call(local_30,param_3[2],param_3[3],(ulong)uStack_9c << 0x20,3,2,&local_58); local_68 = local_90; iVar8 = JS_IsException(local_90._0_8_,local_90._8_8_); if (iVar8 != 0) { LAB_001d4e39: *(int4 *)(local_28 + 1) = 1; return 0; } if (local_68._8_4_ == 0) { local_7c = (uint)(0 < (int)local_68._0_4_) - (uint)((int)local_68._0_4_ < 0); } else { iVar8 = JS_ToFloat64Free(local_30,local_b0,local_68._0_8_,local_68._8_8_); if (iVar8 < 0) goto LAB_001d4e39; uVar2 = CONCAT13(cVar26,CONCAT12(cVar25,CONCAT11(cVar24,cVar23))) ^ CONCAT13(cVar26,CONCAT12(cVar25,CONCAT11(cVar24,cVar23))); uVar3 = CONCAT13(cVar32,CONCAT12(cVar30,CONCAT11(cVar28,cVar27))) ^ CONCAT13(cVar32,CONCAT12(cVar30,CONCAT11(cVar28,cVar27))); uVar29 = (int1)(uVar3 >> 8); uVar31 = (int1)(uVar3 >> 0x10); uVar33 = (int1)(uVar3 >> 0x18); local_7c = (uint)((double)CONCAT17(uVar33,CONCAT16(uVar31,CONCAT15(uVar29,CONCAT14((char)uVar3 ,uVar2)))) <= local_b0[0] && local_b0[0] != (double)CONCAT17(uVar33,CONCAT16(uVar31,CONCAT15(uVar29,CONCAT14((char)uVar3, uVar2))))) - (uint)(local_b0[0] < 0.0); } } if (local_7c != 0) { return local_7c; } LAB_001d4df9: return (uint)(*(long *)(local_78 + 0x18) < *(long *)(local_70 + 0x18)) - (uint)(*(long *)(local_70 + 0x18) < *(long *)(local_78 + 0x18)); }
31,815
js_array_cmp_generic
bluesky950520[P]quickjs/quickjs.c
static int js_array_cmp_generic(const void *a, const void *b, void *opaque) { struct array_sort_context *psc = opaque; JSContext *ctx = psc->ctx; JSValue argv[2]; JSValue res; ValueSlot *ap = (ValueSlot *)(void *)a; ValueSlot *bp = (ValueSlot *)(void *)b; int cmp; if (psc->exception) return 0; if (psc->has_method) { /* custom sort function is specified as returning 0 for identical * objects: avoid method call overhead. */ if (!memcmp(&ap->val, &bp->val, sizeof(ap->val))) goto cmp_same; argv[0] = ap->val; argv[1] = bp->val; res = JS_Call(ctx, psc->method, JS_UNDEFINED, 2, argv); if (JS_IsException(res)) goto exception; if (JS_VALUE_GET_TAG(res) == JS_TAG_INT) { int val = JS_VALUE_GET_INT(res); cmp = (val > 0) - (val < 0); } else { double val; if (JS_ToFloat64Free(ctx, &val, res) < 0) goto exception; cmp = (val > 0) - (val < 0); } } else { /* Not supposed to bypass ToString even for identical objects as * tested in test262/test/built-ins/Array/prototype/sort/bug_596_1.js */ if (!ap->str) { JSValue str = JS_ToString(ctx, ap->val); if (JS_IsException(str)) goto exception; ap->str = JS_VALUE_GET_STRING(str); } if (!bp->str) { JSValue str = JS_ToString(ctx, bp->val); if (JS_IsException(str)) goto exception; bp->str = JS_VALUE_GET_STRING(str); } cmp = js_string_compare(ap->str, bp->str); } if (cmp != 0) return cmp; cmp_same: /* make sort stable: compare array offsets */ return (ap->pos > bp->pos) - (ap->pos < bp->pos); exception: psc->exception = 1; return 0; }
O2
c
js_array_cmp_generic: pushq %rbp pushq %r15 pushq %r14 pushq %r12 pushq %rbx subq $0x30, %rsp xorl %ebp, %ebp cmpl $0x0, 0x8(%rdx) je 0x68c22 movl %ebp, %eax addq $0x30, %rsp popq %rbx popq %r12 popq %r14 popq %r15 popq %rbp retq movq %rdx, %r15 movq %rsi, %rbx movq %rdi, %r14 movq (%rdx), %r12 cmpl $0x0, 0xc(%rdx) je 0x68ca7 movdqu (%rbx), %xmm0 movdqu (%r14), %xmm1 pcmpeqb %xmm0, %xmm1 pmovmskb %xmm1, %eax cmpl $0xffff, %eax # imm = 0xFFFF je 0x68d3b movups (%r14), %xmm0 leaq 0x10(%rsp), %rax movaps %xmm0, (%rax) movupd (%rbx), %xmm0 movapd %xmm0, 0x10(%rax) movq 0x10(%r15), %rsi movq 0x18(%r15), %rdx movq %rax, (%rsp) pushq $0x3 popq %r8 pushq $0x2 popq %r9 movq %r12, %rdi xorl %ecx, %ecx callq 0x25a66 movq %rdx, %rcx cmpl $0x6, %ecx je 0x68d55 testl %ecx, %ecx jne 0x68d00 movl %eax, %ecx sarl $0x1f, %ecx xorl %ebp, %ebp testl %eax, %eax setne %bpl orl %ecx, %ebp jmp 0x68d33 movq 0x10(%r14), %rdi testq %rdi, %rdi jne 0x68ccf movq (%r14), %rsi movq 0x8(%r14), %rdx movq %r12, %rdi callq 0x1ebec cmpl $0x6, %edx je 0x68d55 movq %rax, %rdi movq %rax, 0x10(%r14) movq 0x10(%rbx), %rsi testq %rsi, %rsi jne 0x68cf7 movq (%rbx), %rsi movq 0x8(%rbx), %rdx movq %r12, %rdi callq 0x1ebec cmpl $0x6, %edx je 0x68d55 movq %rax, %rsi movq %rax, 0x10(%rbx) movq 0x10(%r14), %rdi callq 0x3e5f1 movl %eax, %ebp jmp 0x68d33 leaq 0x8(%rsp), %rsi movq %r12, %rdi movq %rax, %rdx callq 0x24e38 testl %eax, %eax js 0x68d55 movsd 0x8(%rsp), %xmm0 pxor %xmm1, %xmm1 xorl %ebp, %ebp ucomisd %xmm1, %xmm0 seta %bpl xorl %eax, %eax ucomisd %xmm0, %xmm1 seta %al subl %eax, %ebp testl %ebp, %ebp jne 0x68c13 movq 0x18(%r14), %rax xorl %ebp, %ebp xorl %ecx, %ecx cmpq 0x18(%rbx), %rax setg %bpl setl %cl subl %ecx, %ebp jmp 0x68c13 movl $0x1, 0x8(%r15) jmp 0x68c13
js_array_cmp_generic: push rbp push r15 push r14 push r12 push rbx sub rsp, 30h xor ebp, ebp cmp dword ptr [rdx+8], 0 jz short loc_68C22 loc_68C13: mov eax, ebp add rsp, 30h pop rbx pop r12 pop r14 pop r15 pop rbp retn loc_68C22: mov r15, rdx mov rbx, rsi mov r14, rdi mov r12, [rdx] cmp dword ptr [rdx+0Ch], 0 jz short loc_68CA7 movdqu xmm0, xmmword ptr [rbx] movdqu xmm1, xmmword ptr [r14] pcmpeqb xmm1, xmm0 pmovmskb eax, xmm1 cmp eax, 0FFFFh jz loc_68D3B movups xmm0, xmmword ptr [r14] lea rax, [rsp+58h+var_48] movaps xmmword ptr [rax], xmm0 movupd xmm0, xmmword ptr [rbx] movapd xmmword ptr [rax+10h], xmm0 mov rsi, [r15+10h] mov rdx, [r15+18h] mov [rsp+58h+var_58], rax push 3 pop r8 push 2 pop r9 mov rdi, r12 xor ecx, ecx call JS_Call mov rcx, rdx cmp ecx, 6 jz loc_68D55 test ecx, ecx jnz short loc_68D00 mov ecx, eax sar ecx, 1Fh xor ebp, ebp test eax, eax setnz bpl or ebp, ecx jmp loc_68D33 loc_68CA7: mov rdi, [r14+10h] test rdi, rdi jnz short loc_68CCF mov rsi, [r14] mov rdx, [r14+8] mov rdi, r12 call JS_ToString cmp edx, 6 jz loc_68D55 mov rdi, rax mov [r14+10h], rax loc_68CCF: mov rsi, [rbx+10h] test rsi, rsi jnz short loc_68CF7 mov rsi, [rbx] mov rdx, [rbx+8] mov rdi, r12 call JS_ToString cmp edx, 6 jz short loc_68D55 mov rsi, rax mov [rbx+10h], rax mov rdi, [r14+10h] loc_68CF7: call js_string_compare mov ebp, eax jmp short loc_68D33 loc_68D00: lea rsi, [rsp+58h+var_50] mov rdi, r12 mov rdx, rax call JS_ToFloat64Free test eax, eax js short loc_68D55 movsd xmm0, [rsp+58h+var_50] pxor xmm1, xmm1 xor ebp, ebp ucomisd xmm0, xmm1 setnbe bpl xor eax, eax ucomisd xmm1, xmm0 setnbe al sub ebp, eax loc_68D33: test ebp, ebp jnz loc_68C13 loc_68D3B: mov rax, [r14+18h] xor ebp, ebp xor ecx, ecx cmp rax, [rbx+18h] setnle bpl setl cl sub ebp, ecx jmp loc_68C13 loc_68D55: mov dword ptr [r15+8], 1 jmp loc_68C13
long long js_array_cmp_generic(const __m128i *a1, const __m128i *a2, long long a3) { unsigned int v3; // ebp const char *v8; // r12 long long v9; // rax long long v10; // rdx long long v11; // rdi long long v12; // rax int v13; // edx long long v14; // rsi long long v15; // rax int v16; // edx double v17; // [rsp+8h] [rbp-50h] BYREF __m128i v18[4]; // [rsp+10h] [rbp-48h] BYREF v3 = 0; if ( !*(_DWORD *)(a3 + 8) ) { v8 = *(const char **)a3; if ( *(_DWORD *)(a3 + 12) ) { if ( _mm_movemask_epi8(_mm_cmpeq_epi8(_mm_loadu_si128(a1), _mm_loadu_si128(a2))) == 0xFFFF ) return (a1[1].m128i_i64[1] > a2[1].m128i_i64[1]) - (unsigned int)(a1[1].m128i_i64[1] < a2[1].m128i_i64[1]); v18[0] = *a1; v18[1] = *a2; v9 = JS_Call((int)v8, *(_QWORD *)(a3 + 16), *(_QWORD *)(a3 + 24), 0, 3, 2, (long long)v18); if ( (_DWORD)v10 != 6 ) { if ( !(_DWORD)v10 ) { v3 = ((int)v9 >> 31) | ((_DWORD)v9 != 0); goto LABEL_17; } if ( (int)JS_ToFloat64Free(v8, &v17, v9, v10) >= 0 ) { v3 = (v17 > 0.0) - (v17 < 0.0); LABEL_17: if ( v3 ) return v3; return (a1[1].m128i_i64[1] > a2[1].m128i_i64[1]) - (unsigned int)(a1[1].m128i_i64[1] < a2[1].m128i_i64[1]); } } LABEL_19: *(_DWORD *)(a3 + 8) = 1; return v3; } v11 = a1[1].m128i_i64[0]; if ( !v11 ) { v12 = JS_ToString((long long)v8, a1->m128i_i64[0], a1->m128i_i64[1]); if ( v13 == 6 ) goto LABEL_19; v11 = v12; a1[1].m128i_i64[0] = v12; } v14 = a2[1].m128i_i64[0]; if ( !v14 ) { v15 = JS_ToString((long long)v8, a2->m128i_i64[0], a2->m128i_i64[1]); if ( v16 == 6 ) goto LABEL_19; v14 = v15; a2[1].m128i_i64[0] = v15; v11 = a1[1].m128i_i64[0]; } v3 = js_string_compare(v11, v14); goto LABEL_17; } return v3; }
js_array_cmp_generic: PUSH RBP PUSH R15 PUSH R14 PUSH R12 PUSH RBX SUB RSP,0x30 XOR EBP,EBP CMP dword ptr [RDX + 0x8],0x0 JZ 0x00168c22 LAB_00168c13: MOV EAX,EBP ADD RSP,0x30 POP RBX POP R12 POP R14 POP R15 POP RBP RET LAB_00168c22: MOV R15,RDX MOV RBX,RSI MOV R14,RDI MOV R12,qword ptr [RDX] CMP dword ptr [RDX + 0xc],0x0 JZ 0x00168ca7 MOVDQU XMM0,xmmword ptr [RBX] MOVDQU XMM1,xmmword ptr [R14] PCMPEQB XMM1,XMM0 PMOVMSKB EAX,XMM1 CMP EAX,0xffff JZ 0x00168d3b MOVUPS XMM0,xmmword ptr [R14] LEA RAX,[RSP + 0x10] MOVAPS xmmword ptr [RAX],XMM0 MOVUPD XMM0,xmmword ptr [RBX] MOVAPD xmmword ptr [RAX + 0x10],XMM0 MOV RSI,qword ptr [R15 + 0x10] MOV RDX,qword ptr [R15 + 0x18] MOV qword ptr [RSP],RAX PUSH 0x3 POP R8 PUSH 0x2 POP R9 MOV RDI,R12 XOR ECX,ECX CALL 0x00125a66 MOV RCX,RDX CMP ECX,0x6 JZ 0x00168d55 TEST ECX,ECX JNZ 0x00168d00 MOV ECX,EAX SAR ECX,0x1f XOR EBP,EBP TEST EAX,EAX SETNZ BPL OR EBP,ECX JMP 0x00168d33 LAB_00168ca7: MOV RDI,qword ptr [R14 + 0x10] TEST RDI,RDI JNZ 0x00168ccf MOV RSI,qword ptr [R14] MOV RDX,qword ptr [R14 + 0x8] MOV RDI,R12 CALL 0x0011ebec CMP EDX,0x6 JZ 0x00168d55 MOV RDI,RAX MOV qword ptr [R14 + 0x10],RAX LAB_00168ccf: MOV RSI,qword ptr [RBX + 0x10] TEST RSI,RSI JNZ 0x00168cf7 MOV RSI,qword ptr [RBX] MOV RDX,qword ptr [RBX + 0x8] MOV RDI,R12 CALL 0x0011ebec CMP EDX,0x6 JZ 0x00168d55 MOV RSI,RAX MOV qword ptr [RBX + 0x10],RAX MOV RDI,qword ptr [R14 + 0x10] LAB_00168cf7: CALL 0x0013e5f1 MOV EBP,EAX JMP 0x00168d33 LAB_00168d00: LEA RSI,[RSP + 0x8] MOV RDI,R12 MOV RDX,RAX CALL 0x00124e38 TEST EAX,EAX JS 0x00168d55 MOVSD XMM0,qword ptr [RSP + 0x8] PXOR XMM1,XMM1 XOR EBP,EBP UCOMISD XMM0,XMM1 SETA BPL XOR EAX,EAX UCOMISD XMM1,XMM0 SETA AL SUB EBP,EAX LAB_00168d33: TEST EBP,EBP JNZ 0x00168c13 LAB_00168d3b: MOV RAX,qword ptr [R14 + 0x18] XOR EBP,EBP XOR ECX,ECX CMP RAX,qword ptr [RBX + 0x18] SETG BPL SETL CL SUB EBP,ECX JMP 0x00168c13 LAB_00168d55: MOV dword ptr [R15 + 0x8],0x1 JMP 0x00168c13
uint js_array_cmp_generic(char *param_1,char *param_2,int8 *param_3) { int8 uVar1; int iVar2; uint uVar3; long lVar4; long lVar5; int1 auVar6 [16]; int1 auVar7 [12]; double local_50; int8 local_48; int8 uStack_40; int8 local_38; int8 uStack_30; if (*(int *)(param_3 + 1) != 0) { return 0; } uVar1 = *param_3; if (*(int *)((long)param_3 + 0xc) == 0) { lVar5 = *(long *)(param_1 + 0x10); if (lVar5 == 0) { auVar7 = JS_ToString(uVar1,*(int8 *)param_1,*(int8 *)(param_1 + 8)); lVar5 = auVar7._0_8_; if (auVar7._8_4_ == 6) goto LAB_00168d55; *(long *)(param_1 + 0x10) = lVar5; } lVar4 = *(long *)(param_2 + 0x10); if (lVar4 == 0) { auVar7 = JS_ToString(uVar1,*(int8 *)param_2,*(int8 *)(param_2 + 8)); lVar4 = auVar7._0_8_; if (auVar7._8_4_ == 6) goto LAB_00168d55; *(long *)(param_2 + 0x10) = lVar4; lVar5 = *(long *)(param_1 + 0x10); } uVar3 = js_string_compare(lVar5,lVar4); } else { auVar6[0] = -(*param_1 == *param_2); auVar6[1] = -(param_1[1] == param_2[1]); auVar6[2] = -(param_1[2] == param_2[2]); auVar6[3] = -(param_1[3] == param_2[3]); auVar6[4] = -(param_1[4] == param_2[4]); auVar6[5] = -(param_1[5] == param_2[5]); auVar6[6] = -(param_1[6] == param_2[6]); auVar6[7] = -(param_1[7] == param_2[7]); auVar6[8] = -(param_1[8] == param_2[8]); auVar6[9] = -(param_1[9] == param_2[9]); auVar6[10] = -(param_1[10] == param_2[10]); auVar6[0xb] = -(param_1[0xb] == param_2[0xb]); auVar6[0xc] = -(param_1[0xc] == param_2[0xc]); auVar6[0xd] = -(param_1[0xd] == param_2[0xd]); auVar6[0xe] = -(param_1[0xe] == param_2[0xe]); auVar6[0xf] = -(param_1[0xf] == param_2[0xf]); if ((ushort)((ushort)(SUB161(auVar6 >> 7,0) & 1) | (ushort)(SUB161(auVar6 >> 0xf,0) & 1) << 1 | (ushort)(SUB161(auVar6 >> 0x17,0) & 1) << 2 | (ushort)(SUB161(auVar6 >> 0x1f,0) & 1) << 3 | (ushort)(SUB161(auVar6 >> 0x27,0) & 1) << 4 | (ushort)(SUB161(auVar6 >> 0x2f,0) & 1) << 5 | (ushort)(SUB161(auVar6 >> 0x37,0) & 1) << 6 | (ushort)(SUB161(auVar6 >> 0x3f,0) & 1) << 7 | (ushort)(SUB161(auVar6 >> 0x47,0) & 1) << 8 | (ushort)(SUB161(auVar6 >> 0x4f,0) & 1) << 9 | (ushort)(SUB161(auVar6 >> 0x57,0) & 1) << 10 | (ushort)(SUB161(auVar6 >> 0x5f,0) & 1) << 0xb | (ushort)(SUB161(auVar6 >> 0x67,0) & 1) << 0xc | (ushort)(SUB161(auVar6 >> 0x6f,0) & 1) << 0xd | (ushort)(SUB161(auVar6 >> 0x77,0) & 1) << 0xe | (ushort)(auVar6[0xf] >> 7) << 0xf) == 0xffff) goto LAB_00168d3b; local_48 = *(int8 *)param_1; uStack_40 = *(int8 *)(param_1 + 8); local_38 = *(int8 *)param_2; uStack_30 = *(int8 *)(param_2 + 8); auVar7 = JS_Call(uVar1,param_3[2],param_3[3],0,3,2,&local_48); if (auVar7._8_4_ == 6) { LAB_00168d55: *(int4 *)(param_3 + 1) = 1; return 0; } if (auVar7._8_4_ == 0) { uVar3 = (uint)(auVar7._0_4_ != 0) | auVar7._0_4_ >> 0x1f; } else { iVar2 = JS_ToFloat64Free(uVar1,&local_50,auVar7._0_8_); if (iVar2 < 0) goto LAB_00168d55; uVar3 = (uint)(0.0 < local_50) - (uint)(local_50 < 0.0); } } if (uVar3 != 0) { return uVar3; } LAB_00168d3b: return (uint)(*(long *)(param_2 + 0x18) < *(long *)(param_1 + 0x18)) - (uint)(*(long *)(param_1 + 0x18) < *(long *)(param_2 + 0x18)); }
31,816
google::protobuf::FileDescriptorTables::GetSourceLocation(std::vector<int, std::allocator<int>> const&, google::protobuf::SourceCodeInfo const*) const
aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/descriptor.cc
const SourceCodeInfo_Location* FileDescriptorTables::GetSourceLocation( const std::vector<int>& path, const SourceCodeInfo* info) const { std::pair<const FileDescriptorTables*, const SourceCodeInfo*> p( std::make_pair(this, info)); internal::call_once(locations_by_path_once_, FileDescriptorTables::BuildLocationsByPath, &p); return FindPtrOrNull(locations_by_path_, Join(path, ",")); }
O0
cpp
google::protobuf::FileDescriptorTables::GetSourceLocation(std::vector<int, std::allocator<int>> const&, google::protobuf::SourceCodeInfo const*) const: subq $0x88, %rsp movq %rdi, 0x80(%rsp) movq %rsi, 0x78(%rsp) movq %rdx, 0x70(%rsp) movq 0x80(%rsp), %rax movq %rax, (%rsp) movq %rax, 0x58(%rsp) leaq 0x58(%rsp), %rdi leaq 0x70(%rsp), %rsi callq 0x28af80 movq (%rsp), %rdi movq %rax, 0x60(%rsp) movq %rdx, 0x68(%rsp) addq $0xf8, %rdi leaq 0x60(%rsp), %rax movq %rax, 0x50(%rsp) leaq -0x14f(%rip), %rsi # 0x24b590 leaq 0x50(%rsp), %rdx callq 0x28afc0 movq (%rsp), %rax addq $0x100, %rax # imm = 0x100 movq %rax, 0x8(%rsp) movq 0x78(%rsp), %rsi leaq 0x178e07(%rip), %rdx # 0x3c450b leaq 0x30(%rsp), %rdi movq %rdi, 0x10(%rsp) callq 0x28b060 movq 0x8(%rsp), %rdi movq 0x10(%rsp), %rsi callq 0x28aff0 movq %rax, 0x18(%rsp) jmp 0x24b729 leaq 0x30(%rsp), %rdi callq 0x21cc8 movq 0x18(%rsp), %rax addq $0x88, %rsp retq movq %rax, %rcx movl %edx, %eax movq %rcx, 0x28(%rsp) movl %eax, 0x24(%rsp) leaq 0x30(%rsp), %rdi callq 0x21cc8 movq 0x28(%rsp), %rdi callq 0x21700 nopw %cs:(%rax,%rax)
_ZNK6google8protobuf20FileDescriptorTables17GetSourceLocationERKSt6vectorIiSaIiEEPKNS0_14SourceCodeInfoE: sub rsp, 88h mov qword ptr [rsp+88h+var_8], rdi mov qword ptr [rsp+88h+var_10], rsi mov [rsp+88h+var_18], rdx mov rax, qword ptr [rsp+88h+var_8] mov qword ptr [rsp+88h+var_88], rax; int mov [rsp+88h+var_30], rax lea rdi, [rsp+88h+var_30] lea rsi, [rsp+88h+var_18] call _ZSt9make_pairIPKN6google8protobuf20FileDescriptorTablesERPKNS1_14SourceCodeInfoEESt4pairINSt25__strip_reference_wrapperINSt5decayIT_E4typeEE6__typeENSA_INSB_IT0_E4typeEE6__typeEEOSC_OSH_; std::make_pair<google::protobuf::FileDescriptorTables const*,google::protobuf::SourceCodeInfo const*&>(google::protobuf::FileDescriptorTables const*&&,google::protobuf::SourceCodeInfo const*&&&) mov rdi, qword ptr [rsp+88h+var_88] mov [rsp+88h+var_28], rax mov [rsp+88h+var_20], rdx add rdi, 0F8h lea rax, [rsp+88h+var_28] mov [rsp+88h+var_38], rax lea rsi, _ZN6google8protobuf20FileDescriptorTables20BuildLocationsByPathEPSt4pairIPKS1_PKNS0_14SourceCodeInfoEE; google::protobuf::FileDescriptorTables::BuildLocationsByPath(std::pair<google::protobuf::FileDescriptorTables const*,google::protobuf::SourceCodeInfo const*> *) lea rdx, [rsp+88h+var_38] call _ZN6google8protobuf8internal9call_onceIJRSt9once_flagRFvPSt4pairIPKNS0_20FileDescriptorTablesEPKNS0_14SourceCodeInfoEEESD_EEEvDpOT_; google::protobuf::internal::call_once<std::once_flag &,void (&)(std::pair<google::protobuf::FileDescriptorTables const*,google::protobuf::SourceCodeInfo const*> *),std::pair<google::protobuf::FileDescriptorTables const*,google::protobuf::SourceCodeInfo const*> *>(std::once_flag &,void (&)(std::pair<google::protobuf::FileDescriptorTables const*,google::protobuf::SourceCodeInfo const*> *),std::pair<google::protobuf::FileDescriptorTables const*,google::protobuf::SourceCodeInfo const*> * &&) mov rax, qword ptr [rsp+88h+var_88] add rax, 100h mov [rsp+88h+var_80], rax; void * mov rsi, qword ptr [rsp+88h+var_10]; int lea rdx, a12_0+9; int lea rdi, [rsp+88h+var_58]; int mov qword ptr [rsp+88h+var_78], rdi; int call _ZN6google8protobuf4JoinISt6vectorIiSaIiEEEENSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKT_PKc; google::protobuf::Join<std::vector<int>>(std::vector<int> const&,char const*) mov rdi, [rsp+88h+var_80] mov rsi, qword ptr [rsp+88h+var_78] call _ZN6google8protobuf13FindPtrOrNullISt13unordered_mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEPKNS0_23SourceCodeInfo_LocationESt4hashIS8_ESt8equal_toIS8_ESaISt4pairIKS8_SB_EEEEENT_10value_type11second_typeERSL_RKNSM_10first_typeE; google::protobuf::FindPtrOrNull<std::unordered_map<std::string,google::protobuf::SourceCodeInfo_Location const*>>(std::unordered_map<std::string,google::protobuf::SourceCodeInfo_Location const*>::value_type&,std::unordered_map<std::string,google::protobuf::SourceCodeInfo_Location const*>::value_type::second_type::first_type const&) mov [rsp+88h+var_70], rax jmp short $+2 loc_24B729: lea rdi, [rsp+88h+var_58]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string() mov rax, [rsp+88h+var_70] add rsp, 88h retn mov rcx, rax mov eax, edx mov [rsp+arg_20], rcx mov [rsp+arg_1C], eax lea rdi, [rsp+arg_28]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string() mov rdi, [rsp+arg_20] call __Unwind_Resume
long long google::protobuf::FileDescriptorTables::GetSourceLocation(long long a1, long long a2, long long a3) { long long v3; // rdx int v4; // ecx int v5; // r8d int v6; // r9d void *v8; // [rsp+8h] [rbp-80h] int v9[2]; // [rsp+10h] [rbp-78h] long long v10; // [rsp+18h] [rbp-70h] long long v11; // [rsp+18h] [rbp-70h] int v12[8]; // [rsp+30h] [rbp-58h] BYREF _QWORD *v13; // [rsp+50h] [rbp-38h] BYREF long long v14; // [rsp+58h] [rbp-30h] BYREF _QWORD v15[2]; // [rsp+60h] [rbp-28h] BYREF long long v16; // [rsp+70h] [rbp-18h] BYREF int v17[2]; // [rsp+78h] [rbp-10h] int v18[2]; // [rsp+80h] [rbp-8h] *(_QWORD *)v18 = a1; *(_QWORD *)v17 = a2; v16 = a3; v14 = a1; v15[0] = std::make_pair<google::protobuf::FileDescriptorTables const*,google::protobuf::SourceCodeInfo const*&>( &v14, &v16); v15[1] = v3; v13 = v15; google::protobuf::internal::call_once<std::once_flag &,void (&)(std::pair<google::protobuf::FileDescriptorTables const*,google::protobuf::SourceCodeInfo const*> *),std::pair<google::protobuf::FileDescriptorTables const*,google::protobuf::SourceCodeInfo const*> *>( a1 + 248, google::protobuf::FileDescriptorTables::BuildLocationsByPath, &v13); google::protobuf::Join<std::vector<int>>( (int)v12, v17[0], (int)",", v4, v5, v6, a1, (void *)(a1 + 256), (int)v12, v10); v11 = google::protobuf::FindPtrOrNull<std::unordered_map<std::string,google::protobuf::SourceCodeInfo_Location const*>>( v8, *(_QWORD *)v9); std::string::~string(v12); return v11; }
_Tuple_impl: SUB RSP,0x18 MOV qword ptr [RSP + 0x10],RDI MOV RDI,qword ptr [RSP + 0x10] MOV qword ptr [RSP + 0x8],RDI CALL 0x0024b6b0 MOV RDI,qword ptr [RSP + 0x8] CALL 0x0024b6c0 ADD RSP,0x18 RET
/* std::_Tuple_impl<0ul, google::protobuf::compiler::java::Context*, std::default_delete<google::protobuf::compiler::java::Context> >::_Tuple_impl() */ void __thiscall std:: _Tuple_impl<0ul,google::protobuf::compiler::java::Context*,std::default_delete<google::protobuf::compiler::java::Context>> ::_Tuple_impl(_Tuple_impl<0ul,google::protobuf::compiler::java::Context*,std::default_delete<google::protobuf::compiler::java::Context>> *this) { _Tuple_impl<1ul,std::default_delete<google::protobuf::compiler::java::Context>>::_Tuple_impl ((_Tuple_impl<1ul,std::default_delete<google::protobuf::compiler::java::Context>> *)this ); _Head_base<0ul,google::protobuf::compiler::java::Context*,false>::_Head_base ((_Head_base<0ul,google::protobuf::compiler::java::Context*,false> *)this); return; }
31,817
google::protobuf::FileDescriptorTables::GetSourceLocation(std::vector<int, std::allocator<int>> const&, google::protobuf::SourceCodeInfo const*) const
aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/descriptor.cc
const SourceCodeInfo_Location* FileDescriptorTables::GetSourceLocation( const std::vector<int>& path, const SourceCodeInfo* info) const { std::pair<const FileDescriptorTables*, const SourceCodeInfo*> p( std::make_pair(this, info)); internal::call_once(locations_by_path_once_, FileDescriptorTables::BuildLocationsByPath, &p); return FindPtrOrNull(locations_by_path_, Join(path, ",")); }
O3
cpp
google::protobuf::FileDescriptorTables::GetSourceLocation(std::vector<int, std::allocator<int>> const&, google::protobuf::SourceCodeInfo const*) const: pushq %r15 pushq %r14 pushq %rbx subq $0x30, %rsp movq %rsi, %rbx movq %rdi, %r14 leaq 0x20(%rsp), %rax movq %rdi, (%rax) movq %rdx, 0x8(%rax) addq $0xf8, %rdi movq %rsp, %rdx movq %rax, (%rdx) leaq -0xd9(%rip), %rsi # 0x11c978 callq 0x140bcd addq $0x100, %r14 # imm = 0x100 leaq 0x99062(%rip), %rdx # 0x1b5ac6 movq %rsp, %r15 movq %r15, %rdi movq %rbx, %rsi callq 0x13cf86 movq %r14, %rdi movq %r15, %rsi callq 0x140cee testq %rax, %rax je 0x11ca88 movq 0x28(%rax), %rbx jmp 0x11ca8a xorl %ebx, %ebx leaq 0x10(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0x11ca9d callq 0x1f4a0 movq %rbx, %rax addq $0x30, %rsp popq %rbx popq %r14 popq %r15 retq movq %rax, %rbx leaq 0x10(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0x11cac0 callq 0x1f4a0 movq %rbx, %rdi callq 0x1f860
_ZNK6google8protobuf20FileDescriptorTables17GetSourceLocationERKSt6vectorIiSaIiEEPKNS0_14SourceCodeInfoE: push r15 push r14 push rbx sub rsp, 30h mov rbx, rsi mov r14, rdi lea rax, [rsp+48h+var_28] mov [rax], rdi mov [rax+8], rdx add rdi, 0F8h mov rdx, rsp mov [rdx], rax lea rsi, _ZN6google8protobuf20FileDescriptorTables20BuildLocationsByPathEPSt4pairIPKS1_PKNS0_14SourceCodeInfoEE; google::protobuf::FileDescriptorTables::BuildLocationsByPath(std::pair<google::protobuf::FileDescriptorTables const*,google::protobuf::SourceCodeInfo const*> *) call _ZSt9call_onceIRFvPSt4pairIPKN6google8protobuf20FileDescriptorTablesEPKNS2_14SourceCodeInfoEEEJSA_EEvRSt9once_flagOT_DpOT0_; std::call_once<void (&)(std::pair<google::protobuf::FileDescriptorTables const*,google::protobuf::SourceCodeInfo const*> *),std::pair<google::protobuf::FileDescriptorTables const*,google::protobuf::SourceCodeInfo const*> *>(std::once_flag &,void (&)(std::pair<google::protobuf::FileDescriptorTables const*,google::protobuf::SourceCodeInfo const*> *) &&,std::pair<google::protobuf::FileDescriptorTables const*,google::protobuf::SourceCodeInfo const*> * &&) add r14, 100h lea rdx, a12_0+9; "," mov r15, rsp mov rdi, r15 mov rsi, rbx call _ZN6google8protobuf4JoinISt6vectorIiSaIiEEEENSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKT_PKc; google::protobuf::Join<std::vector<int>>(std::vector<int> const&,char const*) mov rdi, r14 mov rsi, r15 call _ZNSt10_HashtableINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt4pairIKS5_PKN6google8protobuf23SourceCodeInfo_LocationEESaISD_ENSt8__detail10_Select1stESt8equal_toIS5_ESt4hashIS5_ENSF_18_Mod_range_hashingENSF_20_Default_ranged_hashENSF_20_Prime_rehash_policyENSF_17_Hashtable_traitsILb1ELb0ELb1EEEE4findERS7_; std::_Hashtable<std::string,std::pair<std::string const,google::protobuf::SourceCodeInfo_Location const*>,std::allocator<std::pair<std::string const,google::protobuf::SourceCodeInfo_Location const*>>,std::__detail::_Select1st,std::equal_to<std::string>,std::hash<std::string>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<true,false,true>>::find(std::string const&) test rax, rax jz short loc_11CA88 mov rbx, [rax+28h] jmp short loc_11CA8A loc_11CA88: xor ebx, ebx loc_11CA8A: lea rax, [rsp+48h+var_38] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_11CA9D call __ZdlPv; operator delete(void *) loc_11CA9D: mov rax, rbx add rsp, 30h pop rbx pop r14 pop r15 retn mov rbx, rax lea rax, [rsp+arg_8] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_11CAC0 call __ZdlPv; operator delete(void *) loc_11CAC0: mov rdi, rbx call __Unwind_Resume
long long google::protobuf::FileDescriptorTables::GetSourceLocation(long long a1, long long a2, long long a3) { long long v3; // rax long long v4; // rbx void *v6[2]; // [rsp+0h] [rbp-48h] BYREF char v7; // [rsp+10h] [rbp-38h] BYREF _QWORD v8[5]; // [rsp+20h] [rbp-28h] BYREF v8[0] = a1; v8[1] = a3; v6[0] = v8; std::call_once<void (&)(std::pair<google::protobuf::FileDescriptorTables const*,google::protobuf::SourceCodeInfo const*> *),std::pair<google::protobuf::FileDescriptorTables const*,google::protobuf::SourceCodeInfo const*> *>( a1 + 248, google::protobuf::FileDescriptorTables::BuildLocationsByPath); google::protobuf::Join<std::vector<int>>(v6, a2, ","); v3 = std::_Hashtable<std::string,std::pair<std::string const,google::protobuf::SourceCodeInfo_Location const*>,std::allocator<std::pair<std::string const,google::protobuf::SourceCodeInfo_Location const*>>,std::__detail::_Select1st,std::equal_to<std::string>,std::hash<std::string>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<true,false,true>>::find( a1 + 256, v6); if ( v3 ) v4 = *(_QWORD *)(v3 + 40); else v4 = 0LL; if ( v6[0] != &v7 ) operator delete(v6[0]); return v4; }
31,818
String::set_or_copy_aligned(char const*, unsigned long, charset_info_st const*)
eloqsql/sql/sql_string.cc
bool String::set_or_copy_aligned(const char *str, size_t arg_length, CHARSET_INFO *cs) { /* How many bytes are in incomplete character */ size_t offset= (arg_length % cs->mbminlen); if (!offset) { /* All characters are complete, just use given string */ set(str, arg_length, cs); return FALSE; } return copy_aligned(str, arg_length, offset, cs); }
O3
cpp
String::set_or_copy_aligned(char const*, unsigned long, charset_info_st const*): pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r12 pushq %rbx movq %rcx, %rbx movq %rdx, %r14 movq %rsi, %r12 movq %rdi, %r15 movl 0x98(%rcx), %ecx movq %rdx, %rax xorl %edx, %edx divq %rcx testq %rdx, %rdx je 0x71b9e movq %rdx, %rcx movq %r15, %rdi movq %r12, %rsi movq %r14, %rdx movq %rbx, %r8 popq %rbx popq %r12 popq %r14 popq %r15 popq %rbp jmp 0x71aba cmpb $0x1, 0x1c(%r15) jne 0x71bb3 movb $0x0, 0x1c(%r15) movq 0x8(%r15), %rdi callq 0x9c92a movq %r12, 0x8(%r15) movl %r14d, 0x10(%r15) movl $0x0, 0x14(%r15) movq %rbx, (%r15) xorl %eax, %eax popq %rbx popq %r12 popq %r14 popq %r15 popq %rbp retq nop
_ZN6String19set_or_copy_alignedEPKcmPK15charset_info_st: push rbp mov rbp, rsp push r15 push r14 push r12 push rbx mov rbx, rcx mov r14, rdx mov r12, rsi mov r15, rdi mov ecx, [rcx+98h] mov rax, rdx xor edx, edx div rcx test rdx, rdx jz short loc_71B9E mov rcx, rdx mov rdi, r15 mov rsi, r12 mov rdx, r14 mov r8, rbx pop rbx pop r12 pop r14 pop r15 pop rbp jmp _ZN6String12copy_alignedEPKcmmPK15charset_info_st; String::copy_aligned(char const*,ulong,ulong,charset_info_st const*) loc_71B9E: cmp byte ptr [r15+1Ch], 1 jnz short loc_71BB3 mov byte ptr [r15+1Ch], 0 mov rdi, [r15+8] call my_free loc_71BB3: mov [r15+8], r12 mov [r15+10h], r14d mov dword ptr [r15+14h], 0 mov [r15], rbx xor eax, eax pop rbx pop r12 pop r14 pop r15 pop rbp retn
long long String::set_or_copy_aligned(long long a1, long long a2, unsigned long long a3, long long a4) { unsigned long long v6; // rdx v6 = a3 % *(unsigned int *)(a4 + 152); if ( v6 ) return String::copy_aligned(a1, a2, a3, v6, a4); if ( *(_BYTE *)(a1 + 28) == 1 ) { *(_BYTE *)(a1 + 28) = 0; my_free(*(_QWORD *)(a1 + 8)); } *(_QWORD *)(a1 + 8) = a2; *(_DWORD *)(a1 + 16) = a3; *(_DWORD *)(a1 + 20) = 0; *(_QWORD *)a1 = a4; return 0LL; }
set_or_copy_aligned: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R12 PUSH RBX MOV RBX,RCX MOV R14,RDX MOV R12,RSI MOV R15,RDI MOV ECX,dword ptr [RCX + 0x98] MOV RAX,RDX XOR EDX,EDX DIV RCX TEST RDX,RDX JZ 0x00171b9e MOV RCX,RDX MOV RDI,R15 MOV RSI,R12 MOV RDX,R14 MOV R8,RBX POP RBX POP R12 POP R14 POP R15 POP RBP JMP 0x00171aba LAB_00171b9e: CMP byte ptr [R15 + 0x1c],0x1 JNZ 0x00171bb3 MOV byte ptr [R15 + 0x1c],0x0 MOV RDI,qword ptr [R15 + 0x8] CALL 0x0019c92a LAB_00171bb3: MOV qword ptr [R15 + 0x8],R12 MOV dword ptr [R15 + 0x10],R14D MOV dword ptr [R15 + 0x14],0x0 MOV qword ptr [R15],RBX XOR EAX,EAX POP RBX POP R12 POP R14 POP R15 POP RBP RET
/* String::set_or_copy_aligned(char const*, unsigned long, charset_info_st const*) */ int8 __thiscall String::set_or_copy_aligned(String *this,char *param_1,ulong param_2,charset_info_st *param_3) { int8 uVar1; if (param_2 % (ulong)*(uint *)(param_3 + 0x98) != 0) { uVar1 = copy_aligned(this,param_1,param_2,param_2 % (ulong)*(uint *)(param_3 + 0x98),param_3); return uVar1; } if (this[0x1c] == (String)0x1) { this[0x1c] = (String)0x0; my_free(*(int8 *)(this + 8)); } *(char **)(this + 8) = param_1; *(int *)(this + 0x10) = (int)param_2; *(int4 *)(this + 0x14) = 0; *(charset_info_st **)this = param_3; return 0; }
31,819
nlohmann::json_abi_v3_11_2::basic_json<std::map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_2::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>>::size() const
7CodeWizard[P]stablediffusion/thirdparty/json.hpp
size_type size() const noexcept { switch (m_type) { case value_t::null: { // null values are empty return 0; } case value_t::array: { // delegate call to array_t::size() return m_value.array->size(); } case value_t::object: { // delegate call to object_t::size() return m_value.object->size(); } case value_t::string: case value_t::boolean: case value_t::number_integer: case value_t::number_unsigned: case value_t::number_float: case value_t::binary: case value_t::discarded: default: { // all other types have size 1 return 1; } } }
O0
cpp
nlohmann::json_abi_v3_11_2::basic_json<std::map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_2::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>>::size() const: subq $0x28, %rsp movq %rdi, 0x18(%rsp) movq 0x18(%rsp), %rax movq %rax, 0x8(%rsp) movzbl (%rax), %eax movq %rax, 0x10(%rsp) subq $0x9, %rax ja 0xc3dad movq 0x10(%rsp), %rax leaq 0xbe32b(%rip), %rcx # 0x182098 movslq (%rcx,%rax,4), %rax addq %rcx, %rax jmpq *%rax movq $0x0, 0x20(%rsp) jmp 0xc3db6 movq 0x8(%rsp), %rax movq 0x8(%rax), %rdi callq 0xc9740 movq %rax, 0x20(%rsp) jmp 0xc3db6 movq 0x8(%rsp), %rax movq 0x8(%rax), %rdi callq 0xc9860 movq %rax, 0x20(%rsp) jmp 0xc3db6 jmp 0xc3dad movq $0x1, 0x20(%rsp) movq 0x20(%rsp), %rax addq $0x28, %rsp retq
_ZNK8nlohmann16json_abi_v3_11_210basic_jsonISt3mapSt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEE4sizeEv: sub rsp, 28h mov [rsp+28h+var_10], rdi mov rax, [rsp+28h+var_10] mov [rsp+28h+var_20], rax movzx eax, byte ptr [rax] mov [rsp+28h+var_18], rax sub rax, 9; switch 10 cases ja short def_C3D74; jumptable 00000000000C3D74 default case mov rax, [rsp+28h+var_18] lea rcx, jpt_C3D74 movsxd rax, ds:(jpt_C3D74 - 182098h)[rcx+rax*4] add rax, rcx jmp rax; switch jump loc_C3D76: mov [rsp+28h+var_8], 0; jumptable 00000000000C3D74 case 0 jmp short loc_C3DB6 loc_C3D81: mov rax, [rsp+28h+var_20]; jumptable 00000000000C3D74 case 2 mov rdi, [rax+8] call _ZNKSt6vectorIN8nlohmann16json_abi_v3_11_210basic_jsonISt3mapS_NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES_IhSaIhEEEESaISD_EE4sizeEv; std::vector<nlohmann::json_abi_v3_11_2::basic_json<std::map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<uchar>>>::size(void) mov [rsp+28h+var_8], rax jmp short loc_C3DB6 loc_C3D96: mov rax, [rsp+28h+var_20]; jumptable 00000000000C3D74 case 1 mov rdi, [rax+8] call _ZNKSt3mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_210basic_jsonIS_St6vectorS5_blmdSaNS7_14adl_serializerES9_IhSaIhEEEESt4lessIvESaISt4pairIKS5_SD_EEE4sizeEv; std::map<std::string,nlohmann::json_abi_v3_11_2::basic_json<std::map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<uchar>>>::size(void) mov [rsp+28h+var_8], rax jmp short loc_C3DB6 loc_C3DAB: jmp short $+2; jumptable 00000000000C3D74 cases 3-9 def_C3D74: mov [rsp+28h+var_8], 1; jumptable 00000000000C3D74 default case loc_C3DB6: mov rax, [rsp+28h+var_8] add rsp, 28h retn
long long nlohmann::json_abi_v3_11_2::basic_json<std::map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned char>>::size( long long a1) { long long v2; // [rsp+20h] [rbp-8h] switch ( *(_BYTE *)a1 ) { case 0: v2 = 0LL; break; case 1: v2 = std::map<std::string,nlohmann::json_abi_v3_11_2::basic_json<std::map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned char>>>::size(*(_QWORD *)(a1 + 8)); break; case 2: v2 = std::vector<nlohmann::json_abi_v3_11_2::basic_json<std::map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned char>>>::size(*(_QWORD *)(a1 + 8)); break; default: v2 = 1LL; break; } return v2; }
size: SUB RSP,0x28 MOV qword ptr [RSP + 0x18],RDI MOV RAX,qword ptr [RSP + 0x18] MOV qword ptr [RSP + 0x8],RAX MOVZX EAX,byte ptr [RAX] MOV qword ptr [RSP + 0x10],RAX SUB RAX,0x9 JA 0x001c3dad MOV RAX,qword ptr [RSP + 0x10] LEA RCX,[0x282098] MOVSXD RAX,dword ptr [RCX + RAX*0x4] ADD RAX,RCX switchD: JMP RAX caseD_0: MOV qword ptr [RSP + 0x20],0x0 JMP 0x001c3db6 caseD_2: MOV RAX,qword ptr [RSP + 0x8] MOV RDI,qword ptr [RAX + 0x8] CALL 0x001c9740 MOV qword ptr [RSP + 0x20],RAX JMP 0x001c3db6 caseD_1: MOV RAX,qword ptr [RSP + 0x8] MOV RDI,qword ptr [RAX + 0x8] CALL 0x001c9860 MOV qword ptr [RSP + 0x20],RAX JMP 0x001c3db6 caseD_3: JMP 0x001c3dad default: MOV qword ptr [RSP + 0x20],0x1 LAB_001c3db6: MOV RAX,qword ptr [RSP + 0x20] ADD RSP,0x28 RET
/* nlohmann::json_abi_v3_11_2::basic_json<std::map, std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_2::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char> > >::size() const */ int8 __thiscall nlohmann::json_abi_v3_11_2:: basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>> ::size(basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>> *this) { int8 local_8; switch(*this) { case (basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>> )0x0: local_8 = 0; break; case (basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>> )0x1: local_8 = std:: map<std::__cxx11::string,nlohmann::json_abi_v3_11_2::basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>>,std::less<void>,std::allocator<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_2::basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>>>>> ::size(*(map<std::__cxx11::string,nlohmann::json_abi_v3_11_2::basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>>,std::less<void>,std::allocator<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_2::basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>>>>> **)(this + 8)); break; case (basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>> )0x2: local_8 = std:: vector<nlohmann::json_abi_v3_11_2::basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>>,std::allocator<nlohmann::json_abi_v3_11_2::basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>>>> ::size(*(vector<nlohmann::json_abi_v3_11_2::basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>>,std::allocator<nlohmann::json_abi_v3_11_2::basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>>>> **)(this + 8)); break; case (basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>> )0x3: case (basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>> )0x4: case (basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>> )0x5: case (basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>> )0x6: case (basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>> )0x7: case (basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>> )0x8: case (basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>> )0x9: default: local_8 = 1; } return local_8; }
31,820
js_std_file_close
bluesky950520[P]quickjs/quickjs-libc.c
static JSValue js_std_file_close(JSContext *ctx, JSValue this_val, int argc, JSValue *argv) { JSRuntime *rt = JS_GetRuntime(ctx); JSThreadState *ts = js_get_thread_state(rt); JSSTDFile *s = JS_GetOpaque2(ctx, this_val, ts->std_file_class_id); int err; if (!s) return JS_EXCEPTION; if (!s->f) return JS_ThrowTypeError(ctx, "invalid file handle"); if (is_stdio(s->f)) return JS_ThrowTypeError(ctx, "cannot close stdio"); #if !defined(__wasi__) if (s->is_popen) err = js_get_errno(pclose(s->f)); else #endif err = js_get_errno(fclose(s->f)); s->f = NULL; return JS_NewInt32(ctx, err); }
O0
c
js_std_file_close: subq $0x78, %rsp movq %rsi, 0x38(%rsp) movq %rdx, 0x40(%rsp) movq %rdi, 0x30(%rsp) movl %ecx, 0x2c(%rsp) movq %r8, 0x20(%rsp) movq 0x30(%rsp), %rdi callq 0x27f00 movq %rax, 0x18(%rsp) movq 0x18(%rsp), %rdi callq 0x115d0 movq %rax, 0x10(%rsp) movq 0x30(%rsp), %rdi movq 0x10(%rsp), %rax movl 0x78(%rax), %ecx movq 0x38(%rsp), %rsi movq 0x40(%rsp), %rdx callq 0x383b0 movq %rax, 0x8(%rsp) cmpq $0x0, 0x8(%rsp) jne 0x12959 movl $0x0, 0x48(%rsp) movq $0x6, 0x50(%rsp) jmp 0x12a3c movq 0x8(%rsp), %rax cmpq $0x0, (%rax) jne 0x12986 movq 0x30(%rsp), %rdi leaq 0xf72b0(%rip), %rsi # 0x109c20 movb $0x0, %al callq 0x2d300 movq %rax, 0x48(%rsp) movq %rdx, 0x50(%rsp) jmp 0x12a3c movq 0x8(%rsp), %rax movq (%rax), %rdi callq 0x12880 cmpl $0x0, %eax je 0x129ba movq 0x30(%rsp), %rdi leaq 0xf7290(%rip), %rsi # 0x109c34 movb $0x0, %al callq 0x2d300 movq %rax, 0x48(%rsp) movq %rdx, 0x50(%rsp) jmp 0x12a3c movq 0x8(%rsp), %rax cmpl $0x0, 0x8(%rax) je 0x129e0 movq 0x8(%rsp), %rax movq (%rax), %rdi callq 0xe2c0 movslq %eax, %rdi callq 0x13a50 movl %eax, 0x4(%rsp) jmp 0x129f9 movq 0x8(%rsp), %rax movq (%rax), %rdi callq 0xe220 movslq %eax, %rdi callq 0x13a50 movl %eax, 0x4(%rsp) movq 0x8(%rsp), %rax movq $0x0, (%rax) movq 0x30(%rsp), %rcx movl 0x4(%rsp), %eax movq %rcx, 0x60(%rsp) movl %eax, 0x5c(%rsp) movl 0x5c(%rsp), %eax movl %eax, 0x68(%rsp) movq $0x0, 0x70(%rsp) movq 0x68(%rsp), %rcx movq 0x70(%rsp), %rax movq %rcx, 0x48(%rsp) movq %rax, 0x50(%rsp) movq 0x48(%rsp), %rax movq 0x50(%rsp), %rdx addq $0x78, %rsp retq nopl (%rax,%rax)
js_std_file_close: sub rsp, 78h mov [rsp+78h+var_40], rsi mov [rsp+78h+var_38], rdx mov [rsp+78h+var_48], rdi mov [rsp+78h+var_4C], ecx mov [rsp+78h+var_58], r8 mov rdi, [rsp+78h+var_48] call JS_GetRuntime mov [rsp+78h+var_60], rax mov rdi, [rsp+78h+var_60] call js_get_thread_state mov [rsp+78h+var_68], rax mov rdi, [rsp+78h+var_48] mov rax, [rsp+78h+var_68] mov ecx, [rax+78h] mov rsi, [rsp+78h+var_40] mov rdx, [rsp+78h+var_38] call JS_GetOpaque2 mov [rsp+78h+var_70], rax cmp [rsp+78h+var_70], 0 jnz short loc_12959 mov dword ptr [rsp+78h+var_30], 0 mov [rsp+78h+var_28], 6 jmp loc_12A3C loc_12959: mov rax, [rsp+78h+var_70] cmp qword ptr [rax], 0 jnz short loc_12986 mov rdi, [rsp+78h+var_48] lea rsi, aInvalidFileHan; "invalid file handle" mov al, 0 call JS_ThrowTypeError mov [rsp+78h+var_30], rax mov [rsp+78h+var_28], rdx jmp loc_12A3C loc_12986: mov rax, [rsp+78h+var_70] mov rdi, [rax] call is_stdio cmp eax, 0 jz short loc_129BA mov rdi, [rsp+78h+var_48] lea rsi, aCannotCloseStd; "cannot close stdio" mov al, 0 call JS_ThrowTypeError mov [rsp+78h+var_30], rax mov [rsp+78h+var_28], rdx jmp loc_12A3C loc_129BA: mov rax, [rsp+78h+var_70] cmp dword ptr [rax+8], 0 jz short loc_129E0 mov rax, [rsp+78h+var_70] mov rdi, [rax] call _pclose movsxd rdi, eax call js_get_errno mov [rsp+78h+var_74], eax jmp short loc_129F9 loc_129E0: mov rax, [rsp+78h+var_70] mov rdi, [rax] call _fclose movsxd rdi, eax call js_get_errno mov [rsp+78h+var_74], eax loc_129F9: mov rax, [rsp+78h+var_70] mov qword ptr [rax], 0 mov rcx, [rsp+78h+var_48] mov eax, [rsp+78h+var_74] mov [rsp+78h+var_18], rcx mov [rsp+78h+var_1C], eax mov eax, [rsp+78h+var_1C] mov dword ptr [rsp+78h+var_10], eax mov [rsp+78h+var_8], 0 mov rcx, [rsp+78h+var_10] mov rax, [rsp+78h+var_8] mov [rsp+78h+var_30], rcx mov [rsp+78h+var_28], rax loc_12A3C: mov rax, [rsp+78h+var_30] mov rdx, [rsp+78h+var_28] add rsp, 78h retn
long long js_std_file_close(long long a1, long long a2, long long a3) { int v3; // edx int v4; // ecx int v5; // r8d int v6; // r9d int v7; // edx int v8; // ecx int v9; // r8d int v10; // r9d int v11; // edx int v12; // ecx int v13; // r8d int v14; // r9d int v15; // eax int errno; // [rsp+4h] [rbp-74h] long long *Opaque2; // [rsp+8h] [rbp-70h] long long thread_state; // [rsp+10h] [rbp-68h] int Runtime; // [rsp+18h] [rbp-60h] long long v22; // [rsp+48h] [rbp-30h] long long v23; // [rsp+68h] [rbp-10h] Runtime = JS_GetRuntime(a1); thread_state = js_get_thread_state(Runtime, a2, v3, v4, v5, v6); Opaque2 = (long long *)JS_GetOpaque2(a1, a2, a3, *(unsigned int *)(thread_state + 120)); if ( Opaque2 ) { if ( *Opaque2 ) { if ( is_stdio(*Opaque2) ) { return JS_ThrowTypeError(a1, (unsigned int)"cannot close stdio", v11, v12, v13, v14); } else { if ( *((_DWORD *)Opaque2 + 2) ) v15 = pclose(*Opaque2); else v15 = fclose(*Opaque2); errno = js_get_errno(v15); *Opaque2 = 0LL; LODWORD(v23) = errno; return v23; } } else { return JS_ThrowTypeError(a1, (unsigned int)"invalid file handle", v7, v8, v9, v10); } } else { LODWORD(v22) = 0; } return v22; }
js_std_file_close: SUB RSP,0x78 MOV qword ptr [RSP + 0x38],RSI MOV qword ptr [RSP + 0x40],RDX MOV qword ptr [RSP + 0x30],RDI MOV dword ptr [RSP + 0x2c],ECX MOV qword ptr [RSP + 0x20],R8 MOV RDI,qword ptr [RSP + 0x30] CALL 0x00127f00 MOV qword ptr [RSP + 0x18],RAX MOV RDI,qword ptr [RSP + 0x18] CALL 0x001115d0 MOV qword ptr [RSP + 0x10],RAX MOV RDI,qword ptr [RSP + 0x30] MOV RAX,qword ptr [RSP + 0x10] MOV ECX,dword ptr [RAX + 0x78] MOV RSI,qword ptr [RSP + 0x38] MOV RDX,qword ptr [RSP + 0x40] CALL 0x001383b0 MOV qword ptr [RSP + 0x8],RAX CMP qword ptr [RSP + 0x8],0x0 JNZ 0x00112959 MOV dword ptr [RSP + 0x48],0x0 MOV qword ptr [RSP + 0x50],0x6 JMP 0x00112a3c LAB_00112959: MOV RAX,qword ptr [RSP + 0x8] CMP qword ptr [RAX],0x0 JNZ 0x00112986 MOV RDI,qword ptr [RSP + 0x30] LEA RSI,[0x209c20] MOV AL,0x0 CALL 0x0012d300 MOV qword ptr [RSP + 0x48],RAX MOV qword ptr [RSP + 0x50],RDX JMP 0x00112a3c LAB_00112986: MOV RAX,qword ptr [RSP + 0x8] MOV RDI,qword ptr [RAX] CALL 0x00112880 CMP EAX,0x0 JZ 0x001129ba MOV RDI,qword ptr [RSP + 0x30] LEA RSI,[0x209c34] MOV AL,0x0 CALL 0x0012d300 MOV qword ptr [RSP + 0x48],RAX MOV qword ptr [RSP + 0x50],RDX JMP 0x00112a3c LAB_001129ba: MOV RAX,qword ptr [RSP + 0x8] CMP dword ptr [RAX + 0x8],0x0 JZ 0x001129e0 MOV RAX,qword ptr [RSP + 0x8] MOV RDI,qword ptr [RAX] CALL 0x0010e2c0 MOVSXD RDI,EAX CALL 0x00113a50 MOV dword ptr [RSP + 0x4],EAX JMP 0x001129f9 LAB_001129e0: MOV RAX,qword ptr [RSP + 0x8] MOV RDI,qword ptr [RAX] CALL 0x0010e220 MOVSXD RDI,EAX CALL 0x00113a50 MOV dword ptr [RSP + 0x4],EAX LAB_001129f9: MOV RAX,qword ptr [RSP + 0x8] MOV qword ptr [RAX],0x0 MOV RCX,qword ptr [RSP + 0x30] MOV EAX,dword ptr [RSP + 0x4] MOV qword ptr [RSP + 0x60],RCX MOV dword ptr [RSP + 0x5c],EAX MOV EAX,dword ptr [RSP + 0x5c] MOV dword ptr [RSP + 0x68],EAX MOV qword ptr [RSP + 0x70],0x0 MOV RCX,qword ptr [RSP + 0x68] MOV RAX,qword ptr [RSP + 0x70] MOV qword ptr [RSP + 0x48],RCX MOV qword ptr [RSP + 0x50],RAX LAB_00112a3c: MOV RAX,qword ptr [RSP + 0x48] MOV RDX,qword ptr [RSP + 0x50] ADD RSP,0x78 RET
int1 [16] js_std_file_close(int8 param_1,int8 param_2,int8 param_3) { int iVar1; int8 uVar2; long lVar3; long *plVar4; int1 auVar5 [16]; int4 local_74; int4 local_30; int4 uStack_2c; int8 local_28; int4 uStack_c; uVar2 = JS_GetRuntime(param_1); lVar3 = js_get_thread_state(uVar2); plVar4 = (long *)JS_GetOpaque2(param_1,param_2,param_3,*(int4 *)(lVar3 + 0x78)); if (plVar4 == (long *)0x0) { local_30 = 0; local_28 = 6; } else if (*plVar4 == 0) { auVar5 = JS_ThrowTypeError(param_1,"invalid file handle"); local_28 = auVar5._8_8_; local_30 = auVar5._0_4_; uStack_2c = auVar5._4_4_; } else { iVar1 = is_stdio(*plVar4); if (iVar1 == 0) { if ((int)plVar4[1] == 0) { iVar1 = fclose((FILE *)*plVar4); local_74 = js_get_errno((long)iVar1); } else { iVar1 = pclose((FILE *)*plVar4); local_74 = js_get_errno((long)iVar1); } *plVar4 = 0; local_30 = local_74; uStack_2c = uStack_c; local_28 = 0; } else { auVar5 = JS_ThrowTypeError(param_1,"cannot close stdio"); local_28 = auVar5._8_8_; local_30 = auVar5._0_4_; uStack_2c = auVar5._4_4_; } } auVar5._4_4_ = uStack_2c; auVar5._0_4_ = local_30; auVar5._8_8_ = local_28; return auVar5; }
31,821
js_std_file_close
bluesky950520[P]quickjs/quickjs-libc.c
static JSValue js_std_file_close(JSContext *ctx, JSValue this_val, int argc, JSValue *argv) { JSRuntime *rt = JS_GetRuntime(ctx); JSThreadState *ts = js_get_thread_state(rt); JSSTDFile *s = JS_GetOpaque2(ctx, this_val, ts->std_file_class_id); int err; if (!s) return JS_EXCEPTION; if (!s->f) return JS_ThrowTypeError(ctx, "invalid file handle"); if (is_stdio(s->f)) return JS_ThrowTypeError(ctx, "cannot close stdio"); #if !defined(__wasi__) if (s->is_popen) err = js_get_errno(pclose(s->f)); else #endif err = js_get_errno(fclose(s->f)); s->f = NULL; return JS_NewInt32(ctx, err); }
O1
c
js_std_file_close: pushq %r15 pushq %r14 pushq %r12 pushq %rbx pushq %rax movq %rdx, %rbx movq %rsi, %r12 movq %rdi, %r15 callq 0x1fd7e xorl %r14d, %r14d xorl %edi, %edi movq %rax, %rsi xorl %eax, %eax callq 0x3a5f3 movl 0x78(%rax), %ecx movq %r15, %rdi movq %r12, %rsi movq %rbx, %rdx callq 0x275b5 testq %rax, %rax je 0x15f0c movq %rax, %rbx movq (%rax), %rdi testq %rdi, %rdi je 0x15f15 movq 0xb70d6(%rip), %rax # 0xccfb8 cmpq %rdi, (%rax) je 0x15f1e movq 0xb70c2(%rip), %rax # 0xccfb0 cmpq %rdi, (%rax) je 0x15f1e movq 0xb70f6(%rip), %rax # 0xccff0 cmpq %rdi, (%rax) je 0x15f1e cmpl $0x0, 0x8(%rbx) je 0x15f41 callq 0xe2c0 jmp 0x15f46 movl $0x6, %edx xorl %ecx, %ecx jmp 0x15f65 leaq 0x85bec(%rip), %rsi # 0x9bb08 jmp 0x15f25 leaq 0x85bf7(%rip), %rsi # 0x9bb1c movq %r15, %rdi xorl %eax, %eax callq 0x22567 movq %rax, %r14 movabsq $-0x100000000, %rcx # imm = 0xFFFFFFFF00000000 andq %rax, %rcx jmp 0x15f65 callq 0xe220 cmpl $-0x1, %eax jne 0x15f57 callq 0xe0b0 movq %rax, %rcx xorl %eax, %eax subl (%rcx), %eax movq $0x0, (%rbx) movl %eax, %r14d xorl %ecx, %ecx xorl %edx, %edx movl %r14d, %eax orq %rcx, %rax addq $0x8, %rsp popq %rbx popq %r12 popq %r14 popq %r15 retq
js_std_file_close: push r15 push r14 push r12 push rbx push rax mov rbx, rdx mov r12, rsi mov r15, rdi call JS_GetRuntime xor r14d, r14d xor edi, edi mov rsi, rax xor eax, eax call js_std_cmd mov ecx, [rax+78h] mov rdi, r15 mov rsi, r12 mov rdx, rbx call JS_GetOpaque2 test rax, rax jz short loc_15F0C mov rbx, rax mov rdi, [rax] test rdi, rdi jz short loc_15F15 mov rax, cs:stdin_ptr cmp [rax], rdi jz short loc_15F1E mov rax, cs:stdout_ptr cmp [rax], rdi jz short loc_15F1E mov rax, cs:stderr_ptr cmp [rax], rdi jz short loc_15F1E cmp dword ptr [rbx+8], 0 jz short loc_15F41 call _pclose jmp short loc_15F46 loc_15F0C: mov edx, 6 xor ecx, ecx jmp short loc_15F65 loc_15F15: lea rsi, aInvalidFileHan; "invalid file handle" jmp short loc_15F25 loc_15F1E: lea rsi, aCannotCloseStd; "cannot close stdio" loc_15F25: mov rdi, r15 xor eax, eax call JS_ThrowTypeError mov r14, rax mov rcx, 0FFFFFFFF00000000h and rcx, rax jmp short loc_15F65 loc_15F41: call _fclose loc_15F46: cmp eax, 0FFFFFFFFh jnz short loc_15F57 call ___errno_location mov rcx, rax xor eax, eax sub eax, [rcx] loc_15F57: mov qword ptr [rbx], 0 mov r14d, eax xor ecx, ecx xor edx, edx loc_15F65: mov eax, r14d or rax, rcx add rsp, 8 pop rbx pop r12 pop r14 pop r15 retn
unsigned long long js_std_file_close(long long a1, long long a2, long long a3) { int v4; // r15d int Runtime; // eax unsigned int v6; // r14d int v7; // edx int v8; // ecx int v9; // r8d int v10; // r9d long long v11; // rax long long Opaque2; // rax int v13; // edx int v14; // ecx int v15; // r8d int v16; // r9d _QWORD *v17; // rbx long long v18; // rdi int v19; // eax unsigned long long v20; // rcx const char *v21; // rsi long long v22; // rax v4 = a1; Runtime = JS_GetRuntime(a1); v6 = 0; v11 = js_std_cmd(0, Runtime, v7, v8, v9, v10); Opaque2 = JS_GetOpaque2(a1, a2, a3, *(unsigned int *)(v11 + 120)); if ( !Opaque2 ) { v20 = 0LL; return v20 | v6; } v17 = (_QWORD *)Opaque2; v18 = *(_QWORD *)Opaque2; if ( !*(_QWORD *)Opaque2 ) { v21 = "invalid file handle"; LABEL_11: v22 = JS_ThrowTypeError(v4, (_DWORD)v21, v13, v14, v15, v16); v6 = v22; v20 = v22 & 0xFFFFFFFF00000000LL; return v20 | v6; } if ( stdin == v18 || stdout == v18 || stderr == v18 ) { v21 = "cannot close stdio"; goto LABEL_11; } if ( *(_DWORD *)(Opaque2 + 8) ) v19 = pclose(v18); else v19 = fclose(v18); if ( v19 == -1 ) v19 = -*(_DWORD *)__errno_location(v18); *v17 = 0LL; v6 = v19; v20 = 0LL; return v20 | v6; }
31,822
js_std_file_close
bluesky950520[P]quickjs/quickjs-libc.c
static JSValue js_std_file_close(JSContext *ctx, JSValue this_val, int argc, JSValue *argv) { JSRuntime *rt = JS_GetRuntime(ctx); JSThreadState *ts = js_get_thread_state(rt); JSSTDFile *s = JS_GetOpaque2(ctx, this_val, ts->std_file_class_id); int err; if (!s) return JS_EXCEPTION; if (!s->f) return JS_ThrowTypeError(ctx, "invalid file handle"); if (is_stdio(s->f)) return JS_ThrowTypeError(ctx, "cannot close stdio"); #if !defined(__wasi__) if (s->is_popen) err = js_get_errno(pclose(s->f)); else #endif err = js_get_errno(fclose(s->f)); s->f = NULL; return JS_NewInt32(ctx, err); }
O2
c
js_std_file_close: pushq %r15 pushq %r14 pushq %rbx movq %rdx, %rbx movq %rsi, %r15 movq %rdi, %r14 callq 0x1a185 movq %rax, %rdi callq 0x1028a movl 0x78(%rax), %ecx movq %r14, %rdi movq %r15, %rsi movq %rbx, %rdx callq 0x21207 testq %rax, %rax je 0x10da7 movq %rax, %rbx movq (%rax), %r15 testq %r15, %r15 je 0x10db0 movq %r15, %rdi callq 0x10d27 testl %eax, %eax je 0x10dd0 leaq 0x71d23(%rip), %rsi # 0x82ac8 jmp 0x10db7 pushq $0x6 popq %rdx xorl %eax, %eax xorl %ecx, %ecx jmp 0x10df8 leaq 0x71cfd(%rip), %rsi # 0x82ab4 movq %r14, %rdi xorl %eax, %eax callq 0x1c64d movabsq $-0x100000000, %rcx # imm = 0xFFFFFFFF00000000 andq %rax, %rcx jmp 0x10df8 cmpl $0x0, 0x8(%rbx) je 0x10de0 movq %r15, %rdi callq 0xe2d0 jmp 0x10de8 movq %r15, %rdi callq 0xe230 movslq %eax, %rdi callq 0x113ab andq $0x0, (%rbx) xorl %ecx, %ecx xorl %edx, %edx movl %eax, %eax orq %rcx, %rax popq %rbx popq %r14 popq %r15 retq
js_std_file_close: push r15 push r14 push rbx mov rbx, rdx mov r15, rsi mov r14, rdi call JS_GetRuntime mov rdi, rax call js_get_thread_state mov ecx, [rax+78h] mov rdi, r14 mov rsi, r15 mov rdx, rbx call JS_GetOpaque2 test rax, rax jz short loc_10DA7 mov rbx, rax mov r15, [rax] test r15, r15 jz short loc_10DB0 mov rdi, r15 call is_stdio test eax, eax jz short loc_10DD0 lea rsi, aCannotCloseStd; "cannot close stdio" jmp short loc_10DB7 loc_10DA7: push 6 pop rdx xor eax, eax xor ecx, ecx jmp short loc_10DF8 loc_10DB0: lea rsi, aInvalidFileHan; "invalid file handle" loc_10DB7: mov rdi, r14 xor eax, eax call JS_ThrowTypeError mov rcx, 0FFFFFFFF00000000h and rcx, rax jmp short loc_10DF8 loc_10DD0: cmp dword ptr [rbx+8], 0 jz short loc_10DE0 mov rdi, r15 call _pclose jmp short loc_10DE8 loc_10DE0: mov rdi, r15 call _fclose loc_10DE8: movsxd rdi, eax call js_get_errno and qword ptr [rbx], 0 xor ecx, ecx xor edx, edx loc_10DF8: mov eax, eax or rax, rcx pop rbx pop r14 pop r15 retn
unsigned long long js_std_file_close(long long a1, long long a2, long long a3) { int Runtime; // eax int v5; // edx int v6; // ecx int v7; // r8d int v8; // r9d long long thread_state; // rax long long *Opaque2; // rax int v11; // edx int v12; // ecx int v13; // r8d int v14; // r9d long long *v15; // rbx long long v16; // r15 const char *v17; // rsi long long v18; // rax unsigned long long v19; // rcx int v20; // eax char v22; // [rsp+0h] [rbp-18h] Runtime = JS_GetRuntime(a1); thread_state = js_get_thread_state(Runtime, a2, v5, v6, v7, v8, v22); Opaque2 = (long long *)JS_GetOpaque2(a1, a2, a3, *(unsigned int *)(thread_state + 120)); if ( Opaque2 ) { v15 = Opaque2; v16 = *Opaque2; if ( !*Opaque2 ) { v17 = "invalid file handle"; goto LABEL_7; } if ( (unsigned int)is_stdio(*Opaque2) ) { v17 = "cannot close stdio"; LABEL_7: v18 = JS_ThrowTypeError(a1, (_DWORD)v17, v11, v12, v13, v14); v19 = v18 & 0xFFFFFFFF00000000LL; return v19 | (unsigned int)v18; } if ( *((_DWORD *)v15 + 2) ) v20 = pclose(v16); else v20 = fclose(v16); LODWORD(v18) = js_get_errno(v20); *v15 = 0LL; v19 = 0LL; } else { LODWORD(v18) = 0; v19 = 0LL; } return v19 | (unsigned int)v18; }
js_std_file_close: PUSH R15 PUSH R14 PUSH RBX MOV RBX,RDX MOV R15,RSI MOV R14,RDI CALL 0x0011a185 MOV RDI,RAX CALL 0x0011028a MOV ECX,dword ptr [RAX + 0x78] MOV RDI,R14 MOV RSI,R15 MOV RDX,RBX CALL 0x00121207 TEST RAX,RAX JZ 0x00110da7 MOV RBX,RAX MOV R15,qword ptr [RAX] TEST R15,R15 JZ 0x00110db0 MOV RDI,R15 CALL 0x00110d27 TEST EAX,EAX JZ 0x00110dd0 LEA RSI,[0x182ac8] JMP 0x00110db7 LAB_00110da7: PUSH 0x6 POP RDX XOR EAX,EAX XOR ECX,ECX JMP 0x00110df8 LAB_00110db0: LEA RSI,[0x182ab4] LAB_00110db7: MOV RDI,R14 XOR EAX,EAX CALL 0x0011c64d MOV RCX,-0x100000000 AND RCX,RAX JMP 0x00110df8 LAB_00110dd0: CMP dword ptr [RBX + 0x8],0x0 JZ 0x00110de0 MOV RDI,R15 CALL 0x0010e2d0 JMP 0x00110de8 LAB_00110de0: MOV RDI,R15 CALL 0x0010e230 LAB_00110de8: MOVSXD RDI,EAX CALL 0x001113ab AND qword ptr [RBX],0x0 XOR ECX,ECX XOR EDX,EDX LAB_00110df8: MOV EAX,EAX OR RAX,RCX POP RBX POP R14 POP R15 RET
ulong js_std_file_close(int8 param_1,int8 param_2,int8 param_3) { FILE *__stream; int iVar1; int8 uVar2; long lVar3; int8 *puVar4; ulong uVar5; ulong uVar6; char *pcVar7; uVar2 = JS_GetRuntime(); lVar3 = js_get_thread_state(uVar2); puVar4 = (int8 *)JS_GetOpaque2(param_1,param_2,param_3,*(int4 *)(lVar3 + 0x78)); if (puVar4 == (int8 *)0x0) { uVar5 = 0; uVar6 = 0; } else { __stream = (FILE *)*puVar4; if (__stream == (FILE *)0x0) { pcVar7 = "invalid file handle"; } else { iVar1 = is_stdio(__stream); if (iVar1 == 0) { if (*(int *)(puVar4 + 1) == 0) { iVar1 = fclose(__stream); } else { iVar1 = pclose(__stream); } uVar5 = js_get_errno((long)iVar1); *puVar4 = 0; uVar6 = 0; goto LAB_00110df8; } pcVar7 = "cannot close stdio"; } uVar5 = JS_ThrowTypeError(param_1,pcVar7); uVar6 = uVar5 & 0xffffffff00000000; } LAB_00110df8: return uVar5 & 0xffffffff | uVar6; }
31,823
minja::Parser::parseStringConcat()
monkey531[P]llama/common/minja.hpp
std::shared_ptr<Expression> parseStringConcat() { auto left = parseMathPow(); if (!left) throw std::runtime_error("Expected left side of 'string concat' expression"); static std::regex concat_tok(R"(~(?!\}))"); if (!consumeToken(concat_tok).empty()) { auto right = parseLogicalAnd(); if (!right) throw std::runtime_error("Expected right side of 'string concat' expression"); left = std::make_shared<BinaryOpExpr>(get_location(), std::move(left), std::move(right), BinaryOpExpr::Op::StrConcat); } return left; }
O3
cpp
minja::Parser::parseStringConcat(): pushq %r15 pushq %r14 pushq %rbx subq $0x30, %rsp movq %rsi, %r14 movq %rdi, %rbx callq 0x41052 cmpq $0x0, (%rbx) je 0x40f22 leaq 0x9e03d(%rip), %rax # 0xdee40 movb (%rax), %al testb %al, %al je 0x40f59 leaq 0x9e00c(%rip), %rdx # 0xdee20 leaq 0x10(%rsp), %rdi movq %r14, %rsi movl $0x1, %ecx callq 0x313dc leaq 0x20(%rsp), %rax movq -0x10(%rax), %rdi movq -0x8(%rax), %r15 cmpq %rax, %rdi je 0x40e45 movq 0x20(%rsp), %rsi incq %rsi callq 0x186a0 testq %r15, %r15 je 0x40f15 movq %rsp, %rdi movq %r14, %rsi callq 0x3d9bc cmpq $0x0, (%rsp) je 0x40fb0 movq (%r14), %rax movq %rax, 0x10(%rsp) movq 0x8(%r14), %rax movq %rax, 0x18(%rsp) testq %rax, %rax je 0x40e8f movq 0x9d117(%rip), %rcx # 0xddf98 cmpb $0x0, (%rcx) je 0x40e8b incl 0x8(%rax) jmp 0x40e8f lock incl 0x8(%rax) movq 0x20(%r14), %rax subq 0x10(%r14), %rax movq %rax, 0x20(%rsp) movl $0x58, %edi callq 0x18690 movq %rax, %r14 movabsq $0x100000001, %rax # imm = 0x100000001 movq %rax, 0x8(%r14) leaq 0x9bada(%rip), %rax # 0xdc998 addq $0x10, %rax movq %rax, (%r14) movq %r14, %r15 addq $0x10, %r15 leaq 0x10(%rsp), %rsi movq %rsp, %rcx movq %r15, %rdi movq %rbx, %rdx xorl %r8d, %r8d callq 0x581d6 movq %r15, (%rbx) movq 0x8(%rbx), %rdi movq %r14, 0x8(%rbx) testq %rdi, %rdi je 0x40ef7 callq 0x30ed6 movq 0x18(%rsp), %rdi testq %rdi, %rdi je 0x40f06 callq 0x30ed6 movq 0x8(%rsp), %rdi testq %rdi, %rdi je 0x40f15 callq 0x30ed6 movq %rbx, %rax addq $0x30, %rsp popq %rbx popq %r14 popq %r15 retq movl $0x10, %edi callq 0x18350 movq %rax, %r15 leaq 0x69bd6(%rip), %rsi # 0xaab0c movq %rax, %rdi callq 0x18260 movq 0x9d0ab(%rip), %rsi # 0xddff0 movq 0x9d024(%rip), %rdx # 0xddf70 movq %r15, %rdi callq 0x18b50 jmp 0x40fe2 leaq 0x9dee0(%rip), %rdi # 0xdee40 callq 0x18c10 testl %eax, %eax je 0x40e0d leaq 0x9deac(%rip), %rdi # 0xdee20 leaq 0x69bc2(%rip), %rsi # 0xaab3d movl $0x10, %edx callq 0x30f46 leaq -0xffde(%rip), %rdi # 0x30fae leaq 0x9de8d(%rip), %rsi # 0xdee20 leaq 0x9d71e(%rip), %rdx # 0xde6b8 callq 0x185d0 leaq 0x9de9a(%rip), %rdi # 0xdee40 callq 0x18440 jmp 0x40e0d movl $0x10, %edi callq 0x18350 movq %rax, %r15 leaq 0x69b81(%rip), %rsi # 0xaab45 movq %rax, %rdi callq 0x18260 movq 0x9d01d(%rip), %rsi # 0xddff0 movq 0x9cf96(%rip), %rdx # 0xddf70 movq %r15, %rdi callq 0x18b50 movq %rax, %r14 leaq 0x9de54(%rip), %rdi # 0xdee40 callq 0x18430 jmp 0x4103c movq %rax, %r14 jmp 0x41026 movq %rax, %r14 movq %r15, %rdi callq 0x184f0 jmp 0x41026 jmp 0x41039 movq %rax, %r14 movq %r15, %rdi callq 0x184f0 jmp 0x4103c movq %rax, %r14 movq 0x18(%rsp), %rdi testq %rdi, %rdi je 0x41026 callq 0x30ed6 movq 0x8(%rsp), %rdi testq %rdi, %rdi je 0x4103c callq 0x30ed6 jmp 0x4103c jmp 0x41039 movq %rax, %r14 movq 0x8(%rbx), %rdi testq %rdi, %rdi je 0x4104a callq 0x30ed6 movq %r14, %rdi callq 0x18bc0
_ZN5minja6Parser17parseStringConcatEv: push r15 push r14 push rbx sub rsp, 30h mov r14, rsi mov rbx, rdi call _ZN5minja6Parser12parseMathPowEv; minja::Parser::parseMathPow(void) cmp qword ptr [rbx], 0 jz loc_40F22 lea rax, _ZGVZN5minja6Parser17parseStringConcatEvE10concat_tokB5cxx11; `guard variable for'minja::Parser::parseStringConcat(void)::concat_tok mov al, [rax] test al, al jz loc_40F59 loc_40E0D: lea rdx, _ZZN5minja6Parser17parseStringConcatEvE10concat_tokB5cxx11; minja::Parser::parseStringConcat(void)::concat_tok lea rdi, [rsp+48h+var_38] mov rsi, r14 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 rax, [rsp+48h+var_28] mov rdi, [rax-10h]; void * mov r15, [rax-8] cmp rdi, rax jz short loc_40E45 mov rsi, [rsp+48h+var_28] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_40E45: test r15, r15 jz loc_40F15 mov rdi, rsp; this mov rsi, r14 call _ZN5minja6Parser15parseLogicalAndEv; minja::Parser::parseLogicalAnd(void) cmp [rsp+48h+var_48], 0 jz loc_40FB0 mov rax, [r14] mov [rsp+48h+var_38], rax mov rax, [r14+8] mov [rsp+48h+var_30], rax test rax, rax jz short loc_40E8F mov rcx, cs:__libc_single_threaded_ptr cmp byte ptr [rcx], 0 jz short loc_40E8B inc dword ptr [rax+8] jmp short loc_40E8F loc_40E8B: lock inc dword ptr [rax+8] loc_40E8F: mov rax, [r14+20h] sub rax, [r14+10h] mov [rsp+48h+var_28], rax mov edi, 58h ; 'X'; unsigned __int64 call __Znwm; operator new(ulong) mov r14, rax mov rax, 100000001h mov [r14+8], rax lea rax, _ZTVSt23_Sp_counted_ptr_inplaceIN5minja12BinaryOpExprESaIS1_ELN9__gnu_cxx12_Lock_policyE2EE; `vtable for'std::_Sp_counted_ptr_inplace<minja::BinaryOpExpr,std::allocator<minja::BinaryOpExpr>,(__gnu_cxx::_Lock_policy)2> add rax, 10h mov [r14], rax mov r15, r14 add r15, 10h lea rsi, [rsp+48h+var_38] mov rcx, rsp mov rdi, r15 mov rdx, rbx xor r8d, r8d call _ZN5minja12BinaryOpExprC2ERKNS_8LocationEOSt10shared_ptrINS_10ExpressionEES7_NS0_2OpE; minja::BinaryOpExpr::BinaryOpExpr(minja::Location const&,std::shared_ptr<minja::Expression> &&,std::shared_ptr<minja::Expression> &,minja::BinaryOpExpr::Op) mov [rbx], r15 mov rdi, [rbx+8] mov [rbx+8], r14 test rdi, rdi jz short loc_40EF7 call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void) loc_40EF7: mov rdi, [rsp+48h+var_30] test rdi, rdi jz short loc_40F06 call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void) loc_40F06: mov rdi, [rsp+48h+var_40] test rdi, rdi jz short loc_40F15 call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void) loc_40F15: mov rax, rbx add rsp, 30h pop rbx pop r14 pop r15 retn loc_40F22: mov edi, 10h; thrown_size call ___cxa_allocate_exception mov r15, rax lea rsi, aExpectedLeftSi_2; "Expected left side of 'string concat' e"... mov rdi, rax; this call __ZNSt13runtime_errorC1EPKc; std::runtime_error::runtime_error(char const*) mov rsi, cs:lptinfo; lptinfo mov rdx, cs:_ZTISt19_Sp_make_shared_tag; void (*)(void *) mov rdi, r15; void * call ___cxa_throw jmp loc_40FE2 loc_40F59: lea rdi, _ZGVZN5minja6Parser17parseStringConcatEvE10concat_tokB5cxx11; __guard * call ___cxa_guard_acquire test eax, eax jz loc_40E0D lea rdi, _ZZN5minja6Parser17parseStringConcatEvE10concat_tokB5cxx11; minja::Parser::parseStringConcat(void)::concat_tok lea rsi, asc_AAB3D; "~(?!\\})" 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) lea rdi, _ZNSt7__cxx1111basic_regexIcNS_12regex_traitsIcEEED2Ev; lpfunc lea rsi, _ZZN5minja6Parser17parseStringConcatEvE10concat_tokB5cxx11; obj lea rdx, __dso_handle; lpdso_handle call ___cxa_atexit lea rdi, _ZGVZN5minja6Parser17parseStringConcatEvE10concat_tokB5cxx11; __guard * call ___cxa_guard_release jmp loc_40E0D loc_40FB0: mov edi, 10h; thrown_size call ___cxa_allocate_exception mov r15, rax lea rsi, aExpectedRightS_2; "Expected right side of 'string concat' "... mov rdi, rax; this call __ZNSt13runtime_errorC1EPKc; std::runtime_error::runtime_error(char const*) mov rsi, cs:lptinfo; lptinfo mov rdx, cs:_ZTISt19_Sp_make_shared_tag; void (*)(void *) mov rdi, r15; void * call ___cxa_throw loc_40FE2: mov r14, rax lea rdi, _ZGVZN5minja6Parser17parseStringConcatEvE10concat_tokB5cxx11; __guard * call ___cxa_guard_abort jmp short loc_4103C mov r14, rax jmp short loc_41026 mov r14, rax mov rdi, r15; void * call ___cxa_free_exception jmp short loc_41026 jmp short loc_41039 mov r14, rax mov rdi, r15; void * call ___cxa_free_exception jmp short loc_4103C mov r14, rax mov rdi, [rsp+48h+var_30] test rdi, rdi jz short loc_41026 call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void) loc_41026: mov rdi, [rsp+48h+var_40] test rdi, rdi jz short loc_4103C 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_4103C jmp short $+2 loc_41039: mov r14, rax loc_4103C: mov rdi, [rbx+8] test rdi, rdi jz short loc_4104A call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void) loc_4104A: mov rdi, r14 call __Unwind_Resume
minja::Parser * minja::Parser::parseStringConcat(volatile signed __int32 **this, long long *a2) { volatile signed __int32 *v3; // r15 volatile signed __int32 *v4; // rax volatile signed __int32 *v5; // r14 volatile signed __int32 *v6; // rdi std::runtime_error *exception; // r15 std::runtime_error *v9; // r15 volatile signed __int32 *v10; // [rsp+0h] [rbp-48h] BYREF volatile signed __int32 *v11; // [rsp+8h] [rbp-40h] long long *v12; // [rsp+10h] [rbp-38h] BYREF volatile signed __int32 *v13; // [rsp+18h] [rbp-30h] long long v14; // [rsp+20h] [rbp-28h] BYREF minja::Parser::parseMathPow((minja::Parser *)this); if ( !*this ) { exception = (std::runtime_error *)__cxa_allocate_exception(0x10uLL); std::runtime_error::runtime_error(exception, "Expected left side of 'string concat' expression"); __cxa_throw( exception, (struct type_info *)&`typeinfo for'std::runtime_error, (void (*)(void *))&std::runtime_error::~runtime_error); } if ( !(_BYTE)`guard variable for'minja::Parser::parseStringConcat(void)::concat_tok[abi:cxx11] && __cxa_guard_acquire(&`guard variable for'minja::Parser::parseStringConcat(void)::concat_tok[abi:cxx11]) ) { std::basic_regex<char,std::regex_traits<char>>::basic_regex( (long long)&minja::Parser::parseStringConcat(void)::concat_tok[abi:cxx11], "~(?!\\})", 0x10u); __cxa_atexit( (void (*)(void *))std::basic_regex<char,std::regex_traits<char>>::~basic_regex, &minja::Parser::parseStringConcat(void)::concat_tok[abi:cxx11], &_dso_handle); __cxa_guard_release(&`guard variable for'minja::Parser::parseStringConcat(void)::concat_tok[abi:cxx11]); } minja::Parser::consumeToken( (long long)&v12, (long long)a2, (long long)&minja::Parser::parseStringConcat(void)::concat_tok[abi:cxx11], 1u); v3 = v13; if ( v12 != &v14 ) operator delete(v12, v14 + 1); if ( v3 ) { minja::Parser::parseLogicalAnd(&v10, a2); if ( !v10 ) { v9 = (std::runtime_error *)__cxa_allocate_exception(0x10uLL); std::runtime_error::runtime_error(v9, "Expected right side of 'string concat' expression"); __cxa_throw( v9, (struct type_info *)&`typeinfo for'std::runtime_error, (void (*)(void *))&std::runtime_error::~runtime_error); } v12 = (long long *)*a2; v4 = (volatile signed __int32 *)a2[1]; v13 = v4; if ( v4 ) { if ( _libc_single_threaded ) ++*((_DWORD *)v4 + 2); else _InterlockedIncrement(v4 + 2); } v14 = a2[4] - a2[2]; v5 = (volatile signed __int32 *)operator new(0x58uLL); *((_QWORD *)v5 + 1) = 0x100000001LL; *(_QWORD *)v5 = &`vtable for'std::_Sp_counted_ptr_inplace<minja::BinaryOpExpr,std::allocator<minja::BinaryOpExpr>,(__gnu_cxx::_Lock_policy)2> + 2; minja::BinaryOpExpr::BinaryOpExpr(v5 + 4, &v12, this, &v10, 0LL); *this = v5 + 4; v6 = this[1]; this[1] = v5; if ( v6 ) std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v6); if ( v13 ) std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v13); if ( v11 ) std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v11); } return (minja::Parser *)this; }
parseStringConcat: PUSH R15 PUSH R14 PUSH RBX SUB RSP,0x30 MOV R14,RSI MOV RBX,RDI CALL 0x00141052 CMP qword ptr [RBX],0x0 JZ 0x00140f22 LEA RAX,[0x1dee40] MOV AL,byte ptr [RAX] TEST AL,AL JZ 0x00140f59 LAB_00140e0d: LEA RDX,[0x1dee20] LEA RDI,[RSP + 0x10] MOV RSI,R14 MOV ECX,0x1 CALL 0x001313dc LEA RAX,[RSP + 0x20] MOV RDI,qword ptr [RAX + -0x10] MOV R15,qword ptr [RAX + -0x8] CMP RDI,RAX JZ 0x00140e45 MOV RSI,qword ptr [RSP + 0x20] INC RSI CALL 0x001186a0 LAB_00140e45: TEST R15,R15 JZ 0x00140f15 LAB_00140e4e: MOV RDI,RSP MOV RSI,R14 CALL 0x0013d9bc CMP qword ptr [RSP],0x0 JZ 0x00140fb0 MOV RAX,qword ptr [R14] MOV qword ptr [RSP + 0x10],RAX MOV RAX,qword ptr [R14 + 0x8] MOV qword ptr [RSP + 0x18],RAX TEST RAX,RAX JZ 0x00140e8f MOV RCX,qword ptr [0x001ddf98] CMP byte ptr [RCX],0x0 JZ 0x00140e8b INC dword ptr [RAX + 0x8] JMP 0x00140e8f LAB_00140e8b: INC.LOCK dword ptr [RAX + 0x8] LAB_00140e8f: MOV RAX,qword ptr [R14 + 0x20] SUB RAX,qword ptr [R14 + 0x10] MOV qword ptr [RSP + 0x20],RAX LAB_00140e9c: MOV EDI,0x58 CALL 0x00118690 LAB_00140ea6: MOV R14,RAX MOV RAX,0x100000001 MOV qword ptr [R14 + 0x8],RAX LEA RAX,[0x1dc998] ADD RAX,0x10 MOV qword ptr [R14],RAX MOV R15,R14 ADD R15,0x10 LEA RSI,[RSP + 0x10] MOV RCX,RSP MOV RDI,R15 MOV RDX,RBX XOR R8D,R8D CALL 0x001581d6 MOV qword ptr [RBX],R15 MOV RDI,qword ptr [RBX + 0x8] MOV qword ptr [RBX + 0x8],R14 TEST RDI,RDI JZ 0x00140ef7 CALL 0x00130ed6 LAB_00140ef7: MOV RDI,qword ptr [RSP + 0x18] TEST RDI,RDI JZ 0x00140f06 CALL 0x00130ed6 LAB_00140f06: MOV RDI,qword ptr [RSP + 0x8] TEST RDI,RDI JZ 0x00140f15 CALL 0x00130ed6 LAB_00140f15: MOV RAX,RBX ADD RSP,0x30 POP RBX POP R14 POP R15 RET LAB_00140f22: MOV EDI,0x10 CALL 0x00118350 MOV R15,RAX LAB_00140f2f: LEA RSI,[0x1aab0c] MOV RDI,RAX CALL 0x00118260 LAB_00140f3e: MOV RSI,qword ptr [0x001ddff0] MOV RDX,qword ptr [0x001ddf70] MOV RDI,R15 CALL 0x00118b50 LAB_00140f59: LEA RDI,[0x1dee40] CALL 0x00118c10 TEST EAX,EAX JZ 0x00140e0d LAB_00140f6d: LEA RDI,[0x1dee20] LEA RSI,[0x1aab3d] MOV EDX,0x10 CALL 0x00130f46 LAB_00140f85: LEA RDI,[0x130fae] LEA RSI,[0x1dee20] LEA RDX,[0x1de6b8] CALL 0x001185d0 LEA RDI,[0x1dee40] CALL 0x00118440 JMP 0x00140e0d LAB_00140fb0: MOV EDI,0x10 CALL 0x00118350 MOV R15,RAX LAB_00140fbd: LEA RSI,[0x1aab45] MOV RDI,RAX CALL 0x00118260 LAB_00140fcc: MOV RSI,qword ptr [0x001ddff0] MOV RDX,qword ptr [0x001ddf70] MOV RDI,R15 CALL 0x00118b50
/* minja::Parser::parseStringConcat() */ void minja::Parser::parseStringConcat(void) { _Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *this; int iVar1; int8 *puVar2; runtime_error *prVar3; int8 *in_RSI; long *in_RDI; long local_48; _Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *local_40; long *local_38; _Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *local_30; long local_28 [2]; parseMathPow(); if (*in_RDI == 0) { prVar3 = (runtime_error *)__cxa_allocate_exception(0x10); /* try { // try from 00140f2f to 00140f3d has its CatchHandler @ 00141007 */ std::runtime_error::runtime_error(prVar3,"Expected left side of \'string concat\' expression"); /* try { // try from 00140f3e to 00140f53 has its CatchHandler @ 00141005 */ /* WARNING: Subroutine does not return */ __cxa_throw(prVar3,PTR_typeinfo_001ddff0,PTR__runtime_error_001ddf70); } if (parseStringConcat()::concat_tok_abi_cxx11_ == '\0') { iVar1 = __cxa_guard_acquire(&parseStringConcat()::concat_tok_abi_cxx11_); if (iVar1 != 0) { /* try { // try from 00140f6d to 00140f84 has its CatchHandler @ 00140fe2 */ std::__cxx11::basic_regex<char,std::__cxx11::regex_traits<char>>::basic_regex ((basic_regex<char,std::__cxx11::regex_traits<char>> *) parseStringConcat()::concat_tok_abi_cxx11_,"~(?!\\})",0x10); __cxa_atexit(std::__cxx11::basic_regex<char,std::__cxx11::regex_traits<char>>::~basic_regex, parseStringConcat()::concat_tok_abi_cxx11_,&__dso_handle); __cxa_guard_release(&parseStringConcat()::concat_tok_abi_cxx11_); } } /* try { // try from 00140e0d to 00140e25 has its CatchHandler @ 00141039 */ consumeToken(&local_38); if (local_38 != local_28) { operator_delete(local_38,local_28[0] + 1); } if (local_30 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) { /* try { // try from 00140e4e to 00140e58 has its CatchHandler @ 00141037 */ parseLogicalAnd(); if (local_48 == 0) { prVar3 = (runtime_error *)__cxa_allocate_exception(0x10); /* try { // try from 00140fbd to 00140fcb has its CatchHandler @ 00140ff8 */ std::runtime_error::runtime_error (prVar3,"Expected right side of \'string concat\' expression"); /* try { // try from 00140fcc to 00140fe1 has its CatchHandler @ 00140ff3 */ /* WARNING: Subroutine does not return */ __cxa_throw(prVar3,PTR_typeinfo_001ddff0,PTR__runtime_error_001ddf70); } local_38 = (long *)*in_RSI; local_30 = (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)in_RSI[1]; if (local_30 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) { if (*PTR___libc_single_threaded_001ddf98 == '\0') { LOCK(); *(int *)(local_30 + 8) = *(int *)(local_30 + 8) + 1; UNLOCK(); } else { *(int *)(local_30 + 8) = *(int *)(local_30 + 8) + 1; } } local_28[0] = in_RSI[4] - in_RSI[2]; /* try { // try from 00140e9c to 00140ea5 has its CatchHandler @ 00141014 */ puVar2 = (int8 *)operator_new(0x58); puVar2[1] = 0x100000001; *puVar2 = &PTR___Sp_counted_ptr_inplace_001dc9a8; BinaryOpExpr::BinaryOpExpr((BinaryOpExpr *)(puVar2 + 2),&local_38); *in_RDI = (long)(puVar2 + 2); this = (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)in_RDI[1]; in_RDI[1] = (long)puVar2; if (this != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) { std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(this); } if (local_30 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) { std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(local_30); } if (local_40 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) { std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(local_40); } } return; }
31,824
sp_pcontext::find_label_current_loop_start()
eloqsql/sql/sp_pcontext.cc
sp_label *sp_pcontext::find_label_current_loop_start() { List_iterator_fast<sp_label> li(m_labels); sp_label *lab; while ((lab= li++)) { if (lab->type == sp_label::ITERATION) return lab; } // See a comment in sp_pcontext::find_label() return (m_parent && (m_scope == REGULAR_SCOPE)) ? m_parent->find_label_current_loop_start() : NULL; }
O0
cpp
sp_pcontext::find_label_current_loop_start(): pushq %rbp movq %rsp, %rbp subq $0x50, %rsp movq %rdi, -0x10(%rbp) movq -0x10(%rbp), %rsi movq %rsi, -0x40(%rbp) addq $0xe8, %rsi leaq -0x30(%rbp), %rdi callq 0x915350 leaq -0x30(%rbp), %rdi xorl %esi, %esi callq 0x915380 movq %rax, -0x38(%rbp) cmpq $0x0, %rax je 0x91428f movq -0x38(%rbp), %rax cmpl $0x2, 0x14(%rax) jne 0x91428d movq -0x38(%rbp), %rax movq %rax, -0x8(%rbp) jmp 0x9142ca jmp 0x914264 movq -0x40(%rbp), %rax cmpq $0x0, 0x8(%rax) je 0x9142ba movq -0x40(%rbp), %rax cmpl $0x0, 0x140(%rax) jne 0x9142ba movq -0x40(%rbp), %rax movq 0x8(%rax), %rdi callq 0x914240 movq %rax, -0x48(%rbp) jmp 0x9142c2 xorl %eax, %eax movq %rax, -0x48(%rbp) jmp 0x9142c2 movq -0x48(%rbp), %rax movq %rax, -0x8(%rbp) movq -0x8(%rbp), %rax addq $0x50, %rsp popq %rbp retq nopw %cs:(%rax,%rax)
_ZN11sp_pcontext29find_label_current_loop_startEv: push rbp mov rbp, rsp sub rsp, 50h mov [rbp+var_10], rdi mov rsi, [rbp+var_10] mov [rbp+var_40], rsi add rsi, 0E8h lea rdi, [rbp+var_30] call _ZN18List_iterator_fastI8sp_labelEC2ER4ListIS0_E; List_iterator_fast<sp_label>::List_iterator_fast(List<sp_label> &) loc_914264: lea rdi, [rbp+var_30] xor esi, esi call _ZN18List_iterator_fastI8sp_labelEppEi; List_iterator_fast<sp_label>::operator++(int) mov [rbp+var_38], rax cmp rax, 0 jz short loc_91428F mov rax, [rbp+var_38] cmp dword ptr [rax+14h], 2 jnz short loc_91428D mov rax, [rbp+var_38] mov [rbp+var_8], rax jmp short loc_9142CA loc_91428D: jmp short loc_914264 loc_91428F: mov rax, [rbp+var_40] cmp qword ptr [rax+8], 0 jz short loc_9142BA mov rax, [rbp+var_40] cmp dword ptr [rax+140h], 0 jnz short loc_9142BA mov rax, [rbp+var_40] mov rdi, [rax+8]; this call _ZN11sp_pcontext29find_label_current_loop_startEv; sp_pcontext::find_label_current_loop_start(void) mov [rbp+var_48], rax jmp short loc_9142C2 loc_9142BA: xor eax, eax mov [rbp+var_48], rax jmp short $+2 loc_9142C2: mov rax, [rbp+var_48] mov [rbp+var_8], rax loc_9142CA: mov rax, [rbp+var_8] add rsp, 50h pop rbp retn
long long sp_pcontext::find_label_current_loop_start(sp_pcontext **this) { long long v3; // [rsp+18h] [rbp-38h] _BYTE v4[32]; // [rsp+20h] [rbp-30h] BYREF sp_pcontext **v5; // [rsp+40h] [rbp-10h] v5 = this; List_iterator_fast<sp_label>::List_iterator_fast(v4, this + 29); while ( 1 ) { v3 = List_iterator_fast<sp_label>::operator++(v4, 0LL); if ( !v3 ) break; if ( *(_DWORD *)(v3 + 20) == 2 ) return v3; } if ( !this[1] || *((_DWORD *)this + 80) ) return 0LL; else return sp_pcontext::find_label_current_loop_start(this[1]); }
physical_size: PUSH RBP MOV RBP,RSP SUB RSP,0x10 MOV qword ptr [RBP + -0x8],RDI MOV RAX,qword ptr [RBP + -0x8] MOV RDI,qword ptr [RAX + 0x128] CALL 0x009142d0 ADD RSP,0x10 POP RBP RET
/* fil_space_t::physical_size() const */ void __thiscall fil_space_t::physical_size(fil_space_t *this) { physical_size(*(ulong *)(this + 0x128)); return; }
31,825
ggml_get_rel_pos
Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c
struct ggml_tensor * ggml_get_rel_pos( struct ggml_context * ctx, struct ggml_tensor * a, int qh, int kh) { GGML_ASSERT(qh == kh); GGML_ASSERT(2*MAX(qh, kh) - 1 == a->ne[1]); const int64_t ne[4] = { a->ne[0], kh, qh, 1, }; struct ggml_tensor * result = ggml_new_tensor(ctx, GGML_TYPE_F16, 3, ne); result->op = GGML_OP_GET_REL_POS; result->src[0] = a; return result; }
O0
c
ggml_get_rel_pos: pushq %rbp movq %rsp, %rbp subq $0x50, %rsp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movl %edx, -0x14(%rbp) movl %ecx, -0x18(%rbp) movl -0x14(%rbp), %eax cmpl -0x18(%rbp), %eax je 0x53cbf leaq 0x5d912(%rip), %rdi # 0xb15b7 movl $0x11cf, %esi # imm = 0x11CF leaq 0x5d958(%rip), %rdx # 0xb1609 leaq 0x5e509(%rip), %rcx # 0xb21c1 movb $0x0, %al callq 0x48a00 movl -0x14(%rbp), %eax cmpl -0x18(%rbp), %eax jle 0x53ccf movl -0x14(%rbp), %eax movl %eax, -0x4c(%rbp) jmp 0x53cd5 movl -0x18(%rbp), %eax movl %eax, -0x4c(%rbp) movl -0x4c(%rbp), %eax shll %eax subl $0x1, %eax cltq movq -0x10(%rbp), %rcx cmpq 0x18(%rcx), %rax je 0x53d0a leaq 0x5d8c7(%rip), %rdi # 0xb15b7 movl $0x11d0, %esi # imm = 0x11D0 leaq 0x5d90d(%rip), %rdx # 0xb1609 leaq 0x5e4c7(%rip), %rcx # 0xb21ca movb $0x0, %al callq 0x48a00 movq -0x10(%rbp), %rax movq 0x10(%rax), %rax movq %rax, -0x40(%rbp) movslq -0x18(%rbp), %rax movq %rax, -0x38(%rbp) movslq -0x14(%rbp), %rax movq %rax, -0x30(%rbp) movq $0x1, -0x28(%rbp) movq -0x8(%rbp), %rdi leaq -0x40(%rbp), %rcx movl $0x1, %esi movl $0x3, %edx callq 0x42510 movq %rax, -0x48(%rbp) movq -0x48(%rbp), %rax movl $0x43, 0x50(%rax) movq -0x10(%rbp), %rcx movq -0x48(%rbp), %rax movq %rcx, 0x98(%rax) movq -0x48(%rbp), %rax addq $0x50, %rsp popq %rbp retq nopl (%rax)
ggml_get_rel_pos: push rbp mov rbp, rsp sub rsp, 50h mov [rbp+var_8], rdi mov [rbp+var_10], rsi mov [rbp+var_14], edx mov [rbp+var_18], ecx mov eax, [rbp+var_14] cmp eax, [rbp+var_18] jz short loc_53CBF lea rdi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"... mov esi, 11CFh lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aQhKh; "qh == kh" mov al, 0 call _ggml_abort loc_53CBF: mov eax, [rbp+var_14] cmp eax, [rbp+var_18] jle short loc_53CCF mov eax, [rbp+var_14] mov [rbp+var_4C], eax jmp short loc_53CD5 loc_53CCF: mov eax, [rbp+var_18] mov [rbp+var_4C], eax loc_53CD5: mov eax, [rbp+var_4C] shl eax, 1 sub eax, 1 cdqe mov rcx, [rbp+var_10] cmp rax, [rcx+18h] jz short loc_53D0A lea rdi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"... mov esi, 11D0h lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, a2MaxQhKh1ANe1; "2*MAX(qh, kh) - 1 == a->ne[1]" mov al, 0 call _ggml_abort loc_53D0A: mov rax, [rbp+var_10] mov rax, [rax+10h] mov [rbp+var_40], rax movsxd rax, [rbp+var_18] mov [rbp+var_38], rax movsxd rax, [rbp+var_14] mov [rbp+var_30], rax mov [rbp+var_28], 1 mov rdi, [rbp+var_8] lea rcx, [rbp+var_40] mov esi, 1 mov edx, 3 call _ggml_new_tensor mov [rbp+var_48], rax mov rax, [rbp+var_48] mov dword ptr [rax+50h], 43h ; 'C' mov rcx, [rbp+var_10] mov rax, [rbp+var_48] mov [rax+98h], rcx mov rax, [rbp+var_48] add rsp, 50h pop rbp retn
long long ggml_get_rel_pos(long long a1, long long a2, int a3, int a4) { long long result; // rax int v5; // [rsp+4h] [rbp-4Ch] _QWORD v6[5]; // [rsp+10h] [rbp-40h] BYREF int v7; // [rsp+38h] [rbp-18h] int v8; // [rsp+3Ch] [rbp-14h] long long v9; // [rsp+40h] [rbp-10h] long long v10; // [rsp+48h] [rbp-8h] v10 = a1; v9 = a2; v8 = a3; v7 = a4; if ( a3 != a4 ) ggml_abort( "/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c", 4559, (long long)"GGML_ASSERT(%s) failed", "qh == kh"); if ( v8 <= v7 ) v5 = v7; else v5 = v8; if ( 2 * v5 - 1 != *(_QWORD *)(v9 + 24) ) ggml_abort( "/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c", 4560, (long long)"GGML_ASSERT(%s) failed", "2*MAX(qh, kh) - 1 == a->ne[1]"); v6[0] = *(_QWORD *)(v9 + 16); v6[1] = v7; v6[2] = v8; v6[3] = 1LL; result = ggml_new_tensor(v10, 1u, 3u, (long long)v6); *(_DWORD *)(result + 80) = 67; *(_QWORD *)(result + 152) = v9; return result; }
ggml_get_rel_pos: PUSH RBP MOV RBP,RSP SUB RSP,0x50 MOV qword ptr [RBP + -0x8],RDI MOV qword ptr [RBP + -0x10],RSI MOV dword ptr [RBP + -0x14],EDX MOV dword ptr [RBP + -0x18],ECX MOV EAX,dword ptr [RBP + -0x14] CMP EAX,dword ptr [RBP + -0x18] JZ 0x00153cbf LEA RDI,[0x1b15b7] MOV ESI,0x11cf LEA RDX,[0x1b1609] LEA RCX,[0x1b21c1] MOV AL,0x0 CALL 0x00148a00 LAB_00153cbf: MOV EAX,dword ptr [RBP + -0x14] CMP EAX,dword ptr [RBP + -0x18] JLE 0x00153ccf MOV EAX,dword ptr [RBP + -0x14] MOV dword ptr [RBP + -0x4c],EAX JMP 0x00153cd5 LAB_00153ccf: MOV EAX,dword ptr [RBP + -0x18] MOV dword ptr [RBP + -0x4c],EAX LAB_00153cd5: MOV EAX,dword ptr [RBP + -0x4c] SHL EAX,0x1 SUB EAX,0x1 CDQE MOV RCX,qword ptr [RBP + -0x10] CMP RAX,qword ptr [RCX + 0x18] JZ 0x00153d0a LEA RDI,[0x1b15b7] MOV ESI,0x11d0 LEA RDX,[0x1b1609] LEA RCX,[0x1b21ca] MOV AL,0x0 CALL 0x00148a00 LAB_00153d0a: MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x10] MOV qword ptr [RBP + -0x40],RAX MOVSXD RAX,dword ptr [RBP + -0x18] MOV qword ptr [RBP + -0x38],RAX MOVSXD RAX,dword ptr [RBP + -0x14] MOV qword ptr [RBP + -0x30],RAX MOV qword ptr [RBP + -0x28],0x1 MOV RDI,qword ptr [RBP + -0x8] LEA RCX,[RBP + -0x40] MOV ESI,0x1 MOV EDX,0x3 CALL 0x00142510 MOV qword ptr [RBP + -0x48],RAX MOV RAX,qword ptr [RBP + -0x48] MOV dword ptr [RAX + 0x50],0x43 MOV RCX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RBP + -0x48] MOV qword ptr [RAX + 0x98],RCX MOV RAX,qword ptr [RBP + -0x48] ADD RSP,0x50 POP RBP RET
long ggml_get_rel_pos(int8 param_1,long param_2,int param_3,int param_4) { long lVar1; int local_54; int8 local_48; long local_40; long local_38; int8 local_30; int local_20; int local_1c; long local_18; int8 local_10; local_20 = param_4; local_1c = param_3; local_18 = param_2; local_10 = param_1; if (param_3 != param_4) { ggml_abort("/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c", 0x11cf,"GGML_ASSERT(%s) failed","qh == kh"); } if (local_20 < local_1c) { local_54 = local_1c; } else { local_54 = local_20; } if ((long)(local_54 * 2 + -1) != *(long *)(local_18 + 0x18)) { ggml_abort("/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c", 0x11d0,"GGML_ASSERT(%s) failed","2*MAX(qh, kh) - 1 == a->ne[1]"); } local_48 = *(int8 *)(local_18 + 0x10); local_40 = (long)local_20; local_38 = (long)local_1c; local_30 = 1; lVar1 = ggml_new_tensor(local_10,1,3,&local_48); *(int4 *)(lVar1 + 0x50) = 0x43; *(long *)(lVar1 + 0x98) = local_18; return lVar1; }
31,826
ggml_get_rel_pos
Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c
struct ggml_tensor * ggml_get_rel_pos( struct ggml_context * ctx, struct ggml_tensor * a, int qh, int kh) { GGML_ASSERT(qh == kh); GGML_ASSERT(2*MAX(qh, kh) - 1 == a->ne[1]); const int64_t ne[4] = { a->ne[0], kh, qh, 1, }; struct ggml_tensor * result = ggml_new_tensor(ctx, GGML_TYPE_F16, 3, ne); result->op = GGML_OP_GET_REL_POS; result->src[0] = a; return result; }
O1
c
ggml_get_rel_pos: pushq %rbx subq $0x20, %rsp cmpl %ecx, %edx jne 0x206f5 movq %rsi, %rbx leal -0x1(,%rcx,2), %eax cltq cmpq %rax, 0x18(%rsi) jne 0x20711 movq 0x10(%rbx), %rsi movq %rsp, %rax movq %rsi, (%rax) movslq %ecx, %rcx movq %rcx, 0x8(%rax) movslq %edx, %rcx movq %rcx, 0x10(%rax) movq $0x1, 0x18(%rax) movl $0x1, %esi movl $0x3, %edx movq %rax, %rcx xorl %r8d, %r8d xorl %r9d, %r9d callq 0x1b871 movl $0x43, 0x50(%rax) movq %rbx, 0x98(%rax) addq $0x20, %rsp popq %rbx retq leaq 0x2be73(%rip), %rdi # 0x4c56f leaq 0x2bebe(%rip), %rdx # 0x4c5c1 leaq 0x2c9a9(%rip), %rcx # 0x4d0b3 movl $0x11cf, %esi # imm = 0x11CF jmp 0x2072b leaq 0x2be57(%rip), %rdi # 0x4c56f leaq 0x2bea2(%rip), %rdx # 0x4c5c1 leaq 0x2c996(%rip), %rcx # 0x4d0bc movl $0x11d0, %esi # imm = 0x11D0 xorl %eax, %eax callq 0x18ce0
ggml_get_rel_pos: push rbx sub rsp, 20h cmp edx, ecx jnz short loc_206F5 mov rbx, rsi lea eax, ds:0FFFFFFFFFFFFFFFFh[rcx*2] cdqe cmp [rsi+18h], rax jnz short loc_20711 mov rsi, [rbx+10h] mov rax, rsp mov [rax], rsi movsxd rcx, ecx mov [rax+8], rcx movsxd rcx, edx mov [rax+10h], rcx mov qword ptr [rax+18h], 1 mov esi, 1 mov edx, 3 mov rcx, rax xor r8d, r8d xor r9d, r9d call ggml_new_tensor_impl mov dword ptr [rax+50h], 43h ; 'C' mov [rax+98h], rbx add rsp, 20h pop rbx retn loc_206F5: lea rdi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aQhKh; "qh == kh" mov esi, 11CFh jmp short loc_2072B loc_20711: lea rdi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, a2MaxQhKh1ANe1; "2*MAX(qh, kh) - 1 == a->ne[1]" mov esi, 11D0h loc_2072B: xor eax, eax call _ggml_abort
long long ggml_get_rel_pos(long long a1, long long a2, int a3, int a4, int a5, int a6, double a7) { long long result; // rax const char *v8; // rcx int v9; // esi long long v10[5]; // [rsp+0h] [rbp-28h] BYREF if ( a3 != a4 ) { v8 = "qh == kh"; v9 = 4559; goto LABEL_6; } if ( *(_QWORD *)(a2 + 24) != 2 * a4 - 1 ) { v8 = "2*MAX(qh, kh) - 1 == a->ne[1]"; v9 = 4560; LABEL_6: ggml_abort( (unsigned int)"/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c", v9, (unsigned int)"GGML_ASSERT(%s) failed", (_DWORD)v8, a5, a6); } v10[0] = *(_QWORD *)(a2 + 16); v10[1] = a4; v10[2] = a3; v10[3] = 1LL; result = ggml_new_tensor_impl(a1, 1u, 3, v10, 0LL, 0LL, a7); *(_DWORD *)(result + 80) = 67; *(_QWORD *)(result + 152) = a2; return result; }
ggml_get_rel_pos: PUSH RBX SUB RSP,0x20 CMP EDX,ECX JNZ 0x001206f5 MOV RBX,RSI LEA EAX,[-0x1 + RCX*0x2] CDQE CMP qword ptr [RSI + 0x18],RAX JNZ 0x00120711 MOV RSI,qword ptr [RBX + 0x10] MOV RAX,RSP MOV qword ptr [RAX],RSI MOVSXD RCX,ECX MOV qword ptr [RAX + 0x8],RCX MOVSXD RCX,EDX MOV qword ptr [RAX + 0x10],RCX MOV qword ptr [RAX + 0x18],0x1 MOV ESI,0x1 MOV EDX,0x3 MOV RCX,RAX XOR R8D,R8D XOR R9D,R9D CALL 0x0011b871 MOV dword ptr [RAX + 0x50],0x43 MOV qword ptr [RAX + 0x98],RBX ADD RSP,0x20 POP RBX RET LAB_001206f5: LEA RDI,[0x14c56f] LEA RDX,[0x14c5c1] LEA RCX,[0x14d0b3] MOV ESI,0x11cf JMP 0x0012072b LAB_00120711: LEA RDI,[0x14c56f] LEA RDX,[0x14c5c1] LEA RCX,[0x14d0bc] MOV ESI,0x11d0 LAB_0012072b: XOR EAX,EAX CALL 0x00118ce0
void ggml_get_rel_pos(int8 param_1,long param_2,int param_3,int param_4) { long lVar1; char *pcVar2; int8 uVar3; int8 local_28; long local_20; long local_18; int8 local_10; if (param_3 == param_4) { if (*(long *)(param_2 + 0x18) == (long)(param_4 * 2 + -1)) { local_28 = *(int8 *)(param_2 + 0x10); local_20 = (long)param_4; local_18 = (long)param_3; local_10 = 1; lVar1 = ggml_new_tensor_impl(param_1,1,3,&local_28,0,0); *(int4 *)(lVar1 + 0x50) = 0x43; *(long *)(lVar1 + 0x98) = param_2; return; } pcVar2 = "2*MAX(qh, kh) - 1 == a->ne[1]"; uVar3 = 0x11d0; } else { pcVar2 = "qh == kh"; uVar3 = 0x11cf; } /* WARNING: Subroutine does not return */ ggml_abort("/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c", uVar3,"GGML_ASSERT(%s) failed",pcVar2); }
31,827
ggml_get_rel_pos
Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c
struct ggml_tensor * ggml_get_rel_pos( struct ggml_context * ctx, struct ggml_tensor * a, int qh, int kh) { GGML_ASSERT(qh == kh); GGML_ASSERT(2*MAX(qh, kh) - 1 == a->ne[1]); const int64_t ne[4] = { a->ne[0], kh, qh, 1, }; struct ggml_tensor * result = ggml_new_tensor(ctx, GGML_TYPE_F16, 3, ne); result->op = GGML_OP_GET_REL_POS; result->src[0] = a; return result; }
O2
c
ggml_get_rel_pos: pushq %rbx subq $0x20, %rsp cmpl %ecx, %edx jne 0x2585d movq %rsi, %rbx leal -0x1(,%rdx,2), %eax cltq cmpq %rax, 0x18(%rsi) jne 0x25879 movq 0x10(%rbx), %rax movq %rsp, %rcx movq %rax, (%rcx) movslq %edx, %rax movq %rax, 0x8(%rcx) movq %rax, 0x10(%rcx) movq $0x1, 0x18(%rcx) pushq $0x1 popq %rsi pushq $0x3 popq %rdx callq 0x1d260 movl $0x43, 0x50(%rax) movq %rbx, 0x98(%rax) addq $0x20, %rsp popq %rbx retq leaq 0x28d1f(%rip), %rdi # 0x4e583 leaq 0x28d6a(%rip), %rdx # 0x4e5d5 leaq 0x29855(%rip), %rcx # 0x4f0c7 movl $0x11cf, %esi # imm = 0x11CF jmp 0x25893 leaq 0x28d03(%rip), %rdi # 0x4e583 leaq 0x28d4e(%rip), %rdx # 0x4e5d5 leaq 0x29842(%rip), %rcx # 0x4f0d0 movl $0x11d0, %esi # imm = 0x11D0 xorl %eax, %eax callq 0x1f9b0
ggml_get_rel_pos: push rbx sub rsp, 20h cmp edx, ecx jnz short loc_2585D mov rbx, rsi lea eax, ds:0FFFFFFFFFFFFFFFFh[rdx*2] cdqe cmp [rsi+18h], rax jnz short loc_25879 mov rax, [rbx+10h] mov rcx, rsp mov [rcx], rax movsxd rax, edx mov [rcx+8], rax mov [rcx+10h], rax mov qword ptr [rcx+18h], 1 push 1 pop rsi push 3 pop rdx call _ggml_new_tensor mov dword ptr [rax+50h], 43h ; 'C' mov [rax+98h], rbx add rsp, 20h pop rbx retn loc_2585D: lea rdi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aQhKh; "qh == kh" mov esi, 11CFh jmp short loc_25893 loc_25879: lea rdi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, a2MaxQhKh1ANe1; "2*MAX(qh, kh) - 1 == a->ne[1]" mov esi, 11D0h loc_25893: xor eax, eax call _ggml_abort
long long ggml_get_rel_pos( long long a1, long long a2, int a3, int a4, long long a5, long long a6, __m128 a7, __m128 a8, __m128 a9, __m128 a10, __m128 a11, __m128 a12, __m128 a13, __m128 a14) { long long result; // rax const char *v15; // rcx int v16; // esi _QWORD v17[5]; // [rsp+0h] [rbp-28h] BYREF if ( a3 != a4 ) { v15 = "qh == kh"; v16 = 4559; goto LABEL_6; } if ( *(_QWORD *)(a2 + 24) != 2 * a3 - 1 ) { v15 = "2*MAX(qh, kh) - 1 == a->ne[1]"; v16 = 4560; LABEL_6: ggml_abort( "/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c", v16, (long long)"GGML_ASSERT(%s) failed", (long long)v15, a5, a6, a7, a8, a9, a10, a11, a12, a13, a14, v17[0]); } v17[0] = *(_QWORD *)(a2 + 16); v17[1] = a3; v17[2] = a3; v17[3] = 1LL; result = ggml_new_tensor(a1, 1LL, 3LL, (long long)v17); *(_DWORD *)(result + 80) = 67; *(_QWORD *)(result + 152) = a2; return result; }
ggml_get_rel_pos: PUSH RBX SUB RSP,0x20 CMP EDX,ECX JNZ 0x0012585d MOV RBX,RSI LEA EAX,[-0x1 + RDX*0x2] CDQE CMP qword ptr [RSI + 0x18],RAX JNZ 0x00125879 MOV RAX,qword ptr [RBX + 0x10] MOV RCX,RSP MOV qword ptr [RCX],RAX MOVSXD RAX,EDX MOV qword ptr [RCX + 0x8],RAX MOV qword ptr [RCX + 0x10],RAX MOV qword ptr [RCX + 0x18],0x1 PUSH 0x1 POP RSI PUSH 0x3 POP RDX CALL 0x0011d260 MOV dword ptr [RAX + 0x50],0x43 MOV qword ptr [RAX + 0x98],RBX ADD RSP,0x20 POP RBX RET LAB_0012585d: LEA RDI,[0x14e583] LEA RDX,[0x14e5d5] LEA RCX,[0x14f0c7] MOV ESI,0x11cf JMP 0x00125893 LAB_00125879: LEA RDI,[0x14e583] LEA RDX,[0x14e5d5] LEA RCX,[0x14f0d0] MOV ESI,0x11d0 LAB_00125893: XOR EAX,EAX CALL 0x0011f9b0
void ggml_get_rel_pos(int8 param_1,long param_2,int param_3,int param_4) { long lVar1; char *pcVar2; int8 uVar3; if (param_3 == param_4) { if (*(long *)(param_2 + 0x18) == (long)(param_3 * 2 + -1)) { lVar1 = ggml_new_tensor(param_1,1,3); *(int4 *)(lVar1 + 0x50) = 0x43; *(long *)(lVar1 + 0x98) = param_2; return; } pcVar2 = "2*MAX(qh, kh) - 1 == a->ne[1]"; uVar3 = 0x11d0; } else { pcVar2 = "qh == kh"; uVar3 = 0x11cf; } /* WARNING: Subroutine does not return */ ggml_abort("/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c", uVar3,"GGML_ASSERT(%s) failed",pcVar2); }
31,828
get_key_cache_statistics
eloqsql/mysys/mf_keycache.c
void get_key_cache_statistics(KEY_CACHE *keycache, uint partition_no, KEY_CACHE_STATISTICS *key_cache_stats) { if (keycache->key_cache_inited) { pthread_mutex_lock(&keycache->op_lock); keycache->interface_funcs->get_stats(keycache->keycache_cb, partition_no, key_cache_stats); pthread_mutex_unlock(&keycache->op_lock); } }
O0
c
get_key_cache_statistics: pushq %rbp movq %rsp, %rbp subq $0x20, %rsp movq %rdi, -0x8(%rbp) movl %esi, -0xc(%rbp) movq %rdx, -0x18(%rbp) movq -0x8(%rbp), %rax cmpb $0x0, 0x48(%rax) je 0xe4e04 movq -0x8(%rbp), %rdi addq $0x58, %rdi callq 0x2a220 movq -0x8(%rbp), %rax movq 0x10(%rax), %rax movq 0x48(%rax), %rax movq -0x8(%rbp), %rcx movq 0x8(%rcx), %rdi movl -0xc(%rbp), %esi movq -0x18(%rbp), %rdx callq *%rax movq -0x8(%rbp), %rdi addq $0x58, %rdi callq 0x2a1f0 addq $0x20, %rsp popq %rbp retq nopw (%rax,%rax)
get_key_cache_statistics: push rbp mov rbp, rsp sub rsp, 20h mov [rbp+var_8], rdi mov [rbp+var_C], esi mov [rbp+var_18], rdx mov rax, [rbp+var_8] cmp byte ptr [rax+48h], 0 jz short loc_E4E04 mov rdi, [rbp+var_8] add rdi, 58h ; 'X' call _pthread_mutex_lock mov rax, [rbp+var_8] mov rax, [rax+10h] mov rax, [rax+48h] mov rcx, [rbp+var_8] mov rdi, [rcx+8] mov esi, [rbp+var_C] mov rdx, [rbp+var_18] call rax mov rdi, [rbp+var_8] add rdi, 58h ; 'X' call _pthread_mutex_unlock loc_E4E04: add rsp, 20h pop rbp retn
long long get_key_cache_statistics(long long a1, unsigned int a2, long long a3) { long long result; // rax result = a1; if ( *(_BYTE *)(a1 + 72) ) { pthread_mutex_lock(a1 + 88); (*(void ( **)(_QWORD, _QWORD, long long))(*(_QWORD *)(a1 + 16) + 72LL))(*(_QWORD *)(a1 + 8), a2, a3); return pthread_mutex_unlock(a1 + 88); } return result; }
get_key_cache_statistics: PUSH RBP MOV RBP,RSP SUB RSP,0x20 MOV qword ptr [RBP + -0x8],RDI MOV dword ptr [RBP + -0xc],ESI MOV qword ptr [RBP + -0x18],RDX MOV RAX,qword ptr [RBP + -0x8] CMP byte ptr [RAX + 0x48],0x0 JZ 0x001e4e04 MOV RDI,qword ptr [RBP + -0x8] ADD RDI,0x58 CALL 0x0012a220 MOV RAX,qword ptr [RBP + -0x8] MOV RAX,qword ptr [RAX + 0x10] MOV RAX,qword ptr [RAX + 0x48] MOV RCX,qword ptr [RBP + -0x8] MOV RDI,qword ptr [RCX + 0x8] MOV ESI,dword ptr [RBP + -0xc] MOV RDX,qword ptr [RBP + -0x18] CALL RAX MOV RDI,qword ptr [RBP + -0x8] ADD RDI,0x58 CALL 0x0012a1f0 LAB_001e4e04: ADD RSP,0x20 POP RBP RET
void get_key_cache_statistics(long param_1,int4 param_2,int8 param_3) { if (*(char *)(param_1 + 0x48) != '\0') { pthread_mutex_lock((pthread_mutex_t *)(param_1 + 0x58)); (**(code **)(*(long *)(param_1 + 0x10) + 0x48))(*(int8 *)(param_1 + 8),param_2,param_3); pthread_mutex_unlock((pthread_mutex_t *)(param_1 + 0x58)); } return; }
31,829
my_wildcmp_mb_impl
eloqsql/strings/ctype-mb.c
static int my_wildcmp_mb_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, int recurse_level) { int result= -1; /* Not found, using wildcards */ if (my_string_stack_guard && my_string_stack_guard(recurse_level)) return 1; while (wildstr != wildend) { while (*wildstr != w_many && *wildstr != w_one) { int l; if (*wildstr == escape && wildstr+1 != wildend) wildstr++; if ((l = my_ismbchar(cs, wildstr, wildend))) { if (str+l > str_end || memcmp(str, wildstr, l) != 0) return 1; str += l; wildstr += l; } else if (str == str_end || likeconv(cs,*wildstr++) != likeconv(cs,*str++)) return(1); /* No match */ if (wildstr == wildend) return (str != str_end); /* Match if both are at end */ result=1; /* Found an anchor char */ } if (*wildstr == w_one) { do { if (str == str_end) /* Skip one char if possible */ return (result); INC_PTR(cs,str,str_end); } while (++wildstr < wildend && *wildstr == w_one); if (wildstr == wildend) break; } if (*wildstr == w_many) { /* Found w_many */ uchar cmp; const char* mb = wildstr; int mb_len=0; wildstr++; /* Remove any '%' and '_' from the wild search string */ for (; wildstr != wildend ; wildstr++) { if (*wildstr == w_many) continue; if (*wildstr == w_one) { if (str == str_end) return (-1); INC_PTR(cs,str,str_end); continue; } break; /* Not a wild character */ } if (wildstr == wildend) return(0); /* Ok if w_many is last */ if (str == str_end) return -1; if ((cmp= *wildstr) == escape && wildstr+1 != wildend) cmp= *++wildstr; mb=wildstr; mb_len= my_ismbchar(cs, wildstr, wildend); INC_PTR(cs,wildstr,wildend); /* This is compared trough cmp */ cmp=likeconv(cs,cmp); do { for (;;) { if (str >= str_end) return -1; if (mb_len) { if (str+mb_len <= str_end && memcmp(str, mb, mb_len) == 0) { str += mb_len; break; } } else if (!my_ismbchar(cs, str, str_end) && likeconv(cs,*str) == cmp) { str++; break; } INC_PTR(cs,str, str_end); } { int tmp=my_wildcmp_mb_impl(cs,str,str_end,wildstr,wildend,escape,w_one, w_many, recurse_level + 1); if (tmp <= 0) return (tmp); } } while (str != str_end); return(-1); } } return (str != str_end ? 1 : 0); }
O3
c
my_wildcmp_mb_impl: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x48, %rsp movl %r9d, -0x44(%rbp) movq %r8, -0x40(%rbp) movq %rcx, %r15 movq %rdx, -0x58(%rbp) movq %rsi, %r12 movq %rdi, -0x38(%rbp) movl 0x20(%rbp), %eax movq %rax, -0x68(%rbp) leaq 0xb59f60(%rip), %rax # 0xc130e8 movq (%rax), %rax testq %rax, %rax je 0xb91a3 movl 0x20(%rbp), %edi callq *%rax movl $0x1, %r14d testl %eax, %eax jne 0xb933e movl 0x10(%rbp), %edi movl $0xffffffff, %r14d # imm = 0xFFFFFFFF cmpq -0x40(%rbp), %r15 je 0xb9330 movb (%r15), %al movsbl %al, %ecx movl 0x18(%rbp), %edx cmpl %edx, %ecx sete %sil cmpl %edi, %ecx sete %dl orb %dl, %sil movq -0x58(%rbp), %r13 je 0xb926c testb %dl, %dl je 0xb9259 incq %r15 movq %r15, %rax movq -0x38(%rbp), %rbx cmpq %r13, %r12 je 0xb933e movq %rax, %r15 movq 0xb8(%rbx), %rax movq %rbx, %rdi movq %r12, %rsi movq %r13, %rdx callq *0xc0(%rax) movl %eax, %ecx movl $0x1, %eax cmpl $0x2, %ecx jl 0xb9234 movq 0xb8(%rbx), %rax movq %rbx, %rdi movq %r12, %rsi movq %r13, %rdx callq *0xc0(%rax) cmpl $0x2, %eax movl $0x0, %ecx cmovll %ecx, %eax addq %rax, %r12 cmpq -0x40(%rbp), %r15 movl 0x10(%rbp), %edi jae 0xb924c movsbl (%r15), %ecx leaq 0x1(%r15), %rax cmpl %edi, %ecx je 0xb91e5 cmpq -0x40(%rbp), %r15 je 0xb9334 movb (%r15), %al movsbl %al, %eax movl 0x18(%rbp), %ecx cmpl %ecx, %eax jne 0xb91ac jmp 0xb9350 leaq 0x1(%r15), %rbx movq -0x40(%rbp), %rdx cmpq %rdx, %rbx cmoveq %r15, %rbx cmpl -0x44(%rbp), %ecx cmovneq %r15, %rbx movq -0x38(%rbp), %rdi movq 0xb8(%rdi), %rax movq %rbx, %rsi callq *0xc0(%rax) cmpl $0x2, %eax jge 0xb92d0 movl $0x1, %r14d cmpq %r13, %r12 je 0xb933e movq -0x38(%rbp), %rax movq 0x58(%rax), %rax movzbl (%rbx), %ecx movb (%rax,%rcx), %cl movzbl (%r12), %edx cmpb (%rax,%rdx), %cl movl 0x10(%rbp), %edi jne 0xb933e incq %rbx incq %r12 movq %rbx, %r15 jmp 0xb9303 movl %eax, %r15d movq %r13, %rax leaq (%r12,%r15), %r13 movl $0x1, %r14d cmpq %rax, %r13 ja 0xb933e movq %r12, %rdi movq %rbx, %rsi movq %r15, %rdx callq 0x29510 testl %eax, %eax movl 0x10(%rbp), %edi jne 0xb933e addq %r15, %rbx movq %rbx, %r15 movq %r13, %r12 cmpq -0x40(%rbp), %r15 movq -0x58(%rbp), %r13 je 0xb9334 movb (%r15), %al movsbl %al, %ecx cmpl %edi, %ecx sete %dl movl 0x18(%rbp), %esi cmpl %esi, %ecx je 0xb91d7 cmpl %edi, %ecx jne 0xb926c jmp 0xb91d7 movq -0x58(%rbp), %r13 xorl %r14d, %r14d cmpq %r13, %r12 setne %r14b movl %r14d, %eax addq $0x48, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq leaq 0x1(%r15), %rax cmpq -0x40(%rbp), %rax je 0xb93e0 addq $0x2, %r15 xorl %r13d, %r13d xorl %r14d, %r14d movb -0x1(%r15), %bl movsbl %bl, %eax movl 0x18(%rbp), %ecx cmpl %ecx, %eax je 0xb93ce cmpl %edi, %eax jne 0xb93e8 movq -0x58(%rbp), %rbx cmpq %rbx, %r12 je 0xb95b2 movq -0x38(%rbp), %rdi movq 0xb8(%rdi), %rax movq %r12, %rsi movq %rbx, %rdx callq *0xc0(%rax) movl %eax, %ecx movl $0x1, %eax cmpl $0x2, %ecx jl 0xb93c8 movq -0x38(%rbp), %rdi movq 0xb8(%rdi), %rax movq %r12, %rsi movq %rbx, %rdx callq *0xc0(%rax) cmpl $0x2, %eax cmovll %r13d, %eax addq %rax, %r12 movl 0x10(%rbp), %edi leaq 0x1(%r15), %rax cmpq -0x40(%rbp), %r15 movq %rax, %r15 jne 0xb9368 jmp 0xb933e xorl %r14d, %r14d jmp 0xb933e movl $0xffffffff, %r14d # imm = 0xFFFFFFFF movq -0x58(%rbp), %r13 cmpq %r13, %r12 je 0xb933e movzbl %bl, %eax leaq -0x1(%r15), %rcx movq %rcx, -0x50(%rbp) cmpl -0x44(%rbp), %eax jne 0xb9418 cmpq -0x40(%rbp), %r15 je 0xb9418 movb (%r15), %bl movq %r15, -0x50(%rbp) movq -0x38(%rbp), %rdi movq 0xb8(%rdi), %rax movq -0x50(%rbp), %rsi movq -0x40(%rbp), %rdx callq *0xc0(%rax) xorl %ecx, %ecx cmpl $0x2, %eax movl %eax, %r15d cmovll %ecx, %eax movl %eax, -0x60(%rbp) movq -0x38(%rbp), %rdi movq 0xb8(%rdi), %rax movq -0x50(%rbp), %rsi movq -0x40(%rbp), %rdx callq *0xc0(%rax) movl $0x1, %ecx cmpl $0x2, %eax jl 0xb9488 movq -0x38(%rbp), %rdi movq 0xb8(%rdi), %rax movq -0x50(%rbp), %rsi movq -0x40(%rbp), %rdx callq *0xc0(%rax) movl %eax, %ecx cmpl $0x2, %eax movl $0x0, %eax cmovll %eax, %ecx addq -0x50(%rbp), %rcx movq %rcx, -0x70(%rbp) movq -0x38(%rbp), %rax movq 0x58(%rax), %rax movzbl %bl, %ecx movb (%rax,%rcx), %al movb %al, -0x29(%rbp) movl -0x60(%rbp), %eax movq %rax, -0x60(%rbp) movq -0x68(%rbp), %rax incl %eax movq %rax, -0x68(%rbp) cmpq %r13, %r12 jae 0xb933e movq %r12, %rbx cmpl $0x2, %r15d jge 0xb94f5 movq -0x38(%rbp), %rdi movq 0xb8(%rdi), %rax movq %rbx, %rsi movq %r13, %rdx callq *0xc0(%rax) cmpl $0x1, %eax jg 0xb9516 movq -0x38(%rbp), %rax movq 0x58(%rax), %rax movzbl (%rbx), %ecx movb -0x29(%rbp), %dl cmpb %dl, (%rax,%rcx) jne 0xb9516 jmp 0xb956c movq -0x60(%rbp), %rax leaq (%rbx,%rax), %r12 cmpq %r13, %r12 ja 0xb9516 movq %rbx, %rdi movq -0x50(%rbp), %rsi movq -0x60(%rbp), %rdx callq 0x29510 testl %eax, %eax je 0xb9572 movq -0x38(%rbp), %rdi movq 0xb8(%rdi), %rax movq %rbx, %rsi movq %r13, %rdx callq *0xc0(%rax) movl %eax, %ecx movl $0x1, %eax cmpl $0x2, %ecx jl 0xb955b movq -0x38(%rbp), %rdi movq 0xb8(%rdi), %rax movq %rbx, %rsi movq %r13, %rdx callq *0xc0(%rax) cmpl $0x2, %eax movl $0x0, %ecx cmovll %ecx, %eax addq %rax, %rbx cmpq %r13, %rbx jb 0xb94be jmp 0xb933e incq %rbx movq %rbx, %r12 subq $0x8, %rsp movq -0x38(%rbp), %rdi movq %r12, %rsi movq %r13, %rdx movq -0x70(%rbp), %rcx movq -0x40(%rbp), %r8 movl -0x44(%rbp), %r9d pushq -0x68(%rbp) movl 0x18(%rbp), %eax pushq %rax movl 0x10(%rbp), %eax pushq %rax callq 0xb9153 addq $0x20, %rsp testl %eax, %eax jle 0xb95bd cmpq %r13, %r12 jne 0xb94b2 jmp 0xb933e movl $0xffffffff, %r14d # imm = 0xFFFFFFFF jmp 0xb933e movl %eax, %r14d jmp 0xb933e
my_wildcmp_mb_impl: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx sub rsp, 48h mov [rbp+var_44], r9d mov [rbp+var_40], r8 mov r15, rcx mov [rbp+var_58], rdx mov r12, rsi mov [rbp+var_38], rdi mov eax, [rbp+arg_10] mov [rbp+var_68], rax lea rax, my_string_stack_guard mov rax, [rax] test rax, rax jz short loc_B91A3 mov edi, [rbp+arg_10] call rax mov r14d, 1 test eax, eax jnz loc_B933E loc_B91A3: mov edi, [rbp+arg_0] mov r14d, 0FFFFFFFFh loc_B91AC: cmp r15, [rbp+var_40] jz loc_B9330 mov al, [r15] movsx ecx, al mov edx, [rbp+arg_8] cmp ecx, edx setz sil cmp ecx, edi setz dl or sil, dl mov r13, [rbp+var_58] jz loc_B926C loc_B91D7: test dl, dl jz short loc_B9259 inc r15 mov rax, r15 mov rbx, [rbp+var_38] loc_B91E5: cmp r12, r13 jz loc_B933E mov r15, rax mov rax, [rbx+0B8h] mov rdi, rbx mov rsi, r12 mov rdx, r13 call qword ptr [rax+0C0h] mov ecx, eax mov eax, 1 cmp ecx, 2 jl short loc_B9234 mov rax, [rbx+0B8h] mov rdi, rbx mov rsi, r12 mov rdx, r13 call qword ptr [rax+0C0h] cmp eax, 2 mov ecx, 0 cmovl eax, ecx loc_B9234: add r12, rax cmp r15, [rbp+var_40] mov edi, [rbp+arg_0] jnb short loc_B924C movsx ecx, byte ptr [r15] lea rax, [r15+1] cmp ecx, edi jz short loc_B91E5 loc_B924C: cmp r15, [rbp+var_40] jz loc_B9334 mov al, [r15] loc_B9259: movsx eax, al mov ecx, [rbp+arg_8] cmp eax, ecx jnz loc_B91AC jmp loc_B9350 loc_B926C: lea rbx, [r15+1] mov rdx, [rbp+var_40] cmp rbx, rdx cmovz rbx, r15 cmp ecx, [rbp+var_44] cmovnz rbx, r15 mov rdi, [rbp+var_38] mov rax, [rdi+0B8h] mov rsi, rbx call qword ptr [rax+0C0h] cmp eax, 2 jge short loc_B92D0 mov r14d, 1 cmp r12, r13 jz loc_B933E mov rax, [rbp+var_38] mov rax, [rax+58h] movzx ecx, byte ptr [rbx] mov cl, [rax+rcx] movzx edx, byte ptr [r12] cmp cl, [rax+rdx] mov edi, [rbp+arg_0] jnz short loc_B933E inc rbx inc r12 mov r15, rbx jmp short loc_B9303 loc_B92D0: mov r15d, eax mov rax, r13 lea r13, [r12+r15] mov r14d, 1 cmp r13, rax ja short loc_B933E mov rdi, r12 mov rsi, rbx mov rdx, r15 call _bcmp test eax, eax mov edi, [rbp+arg_0] jnz short loc_B933E add rbx, r15 mov r15, rbx mov r12, r13 loc_B9303: cmp r15, [rbp+var_40] mov r13, [rbp+var_58] jz short loc_B9334 mov al, [r15] movsx ecx, al cmp ecx, edi setz dl mov esi, [rbp+arg_8] cmp ecx, esi jz loc_B91D7 cmp ecx, edi jnz loc_B926C jmp loc_B91D7 loc_B9330: mov r13, [rbp+var_58] loc_B9334: xor r14d, r14d cmp r12, r13 setnz r14b loc_B933E: mov eax, r14d add rsp, 48h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn loc_B9350: lea rax, [r15+1] cmp rax, [rbp+var_40] jz loc_B93E0 add r15, 2 xor r13d, r13d xor r14d, r14d loc_B9368: mov bl, [r15-1] movsx eax, bl mov ecx, [rbp+arg_8] cmp eax, ecx jz short loc_B93CE cmp eax, edi jnz short loc_B93E8 mov rbx, [rbp+var_58] cmp r12, rbx jz loc_B95B2 mov rdi, [rbp+var_38] mov rax, [rdi+0B8h] mov rsi, r12 mov rdx, rbx call qword ptr [rax+0C0h] mov ecx, eax mov eax, 1 cmp ecx, 2 jl short loc_B93C8 mov rdi, [rbp+var_38] mov rax, [rdi+0B8h] mov rsi, r12 mov rdx, rbx call qword ptr [rax+0C0h] cmp eax, 2 cmovl eax, r13d loc_B93C8: add r12, rax mov edi, [rbp+arg_0] loc_B93CE: lea rax, [r15+1] cmp r15, [rbp+var_40] mov r15, rax jnz short loc_B9368 jmp loc_B933E loc_B93E0: xor r14d, r14d jmp loc_B933E loc_B93E8: mov r14d, 0FFFFFFFFh mov r13, [rbp+var_58] cmp r12, r13 jz loc_B933E movzx eax, bl lea rcx, [r15-1] mov [rbp+var_50], rcx cmp eax, [rbp+var_44] jnz short loc_B9418 cmp r15, [rbp+var_40] jz short loc_B9418 mov bl, [r15] mov [rbp+var_50], r15 loc_B9418: mov rdi, [rbp+var_38] mov rax, [rdi+0B8h] mov rsi, [rbp+var_50] mov rdx, [rbp+var_40] call qword ptr [rax+0C0h] xor ecx, ecx cmp eax, 2 mov r15d, eax cmovl eax, ecx mov dword ptr [rbp+var_60], eax mov rdi, [rbp+var_38] mov rax, [rdi+0B8h] mov rsi, [rbp+var_50] mov rdx, [rbp+var_40] call qword ptr [rax+0C0h] mov ecx, 1 cmp eax, 2 jl short loc_B9488 mov rdi, [rbp+var_38] mov rax, [rdi+0B8h] mov rsi, [rbp+var_50] mov rdx, [rbp+var_40] call qword ptr [rax+0C0h] mov ecx, eax cmp eax, 2 mov eax, 0 cmovl ecx, eax loc_B9488: add rcx, [rbp+var_50] mov [rbp+var_70], rcx mov rax, [rbp+var_38] mov rax, [rax+58h] movzx ecx, bl mov al, [rax+rcx] mov [rbp+var_29], al mov eax, dword ptr [rbp+var_60] mov [rbp+var_60], rax mov rax, [rbp+var_68] inc eax mov [rbp+var_68], rax loc_B94B2: cmp r12, r13 jnb loc_B933E mov rbx, r12 loc_B94BE: cmp r15d, 2 jge short loc_B94F5 mov rdi, [rbp+var_38] mov rax, [rdi+0B8h] mov rsi, rbx mov rdx, r13 call qword ptr [rax+0C0h] cmp eax, 1 jg short loc_B9516 mov rax, [rbp+var_38] mov rax, [rax+58h] movzx ecx, byte ptr [rbx] mov dl, [rbp+var_29] cmp [rax+rcx], dl jnz short loc_B9516 jmp short loc_B956C loc_B94F5: mov rax, [rbp+var_60] lea r12, [rbx+rax] cmp r12, r13 ja short loc_B9516 mov rdi, rbx mov rsi, [rbp+var_50] mov rdx, [rbp+var_60] call _bcmp test eax, eax jz short loc_B9572 loc_B9516: mov rdi, [rbp+var_38] mov rax, [rdi+0B8h] mov rsi, rbx mov rdx, r13 call qword ptr [rax+0C0h] mov ecx, eax mov eax, 1 cmp ecx, 2 jl short loc_B955B mov rdi, [rbp+var_38] mov rax, [rdi+0B8h] mov rsi, rbx mov rdx, r13 call qword ptr [rax+0C0h] cmp eax, 2 mov ecx, 0 cmovl eax, ecx loc_B955B: add rbx, rax cmp rbx, r13 jb loc_B94BE jmp loc_B933E loc_B956C: inc rbx mov r12, rbx loc_B9572: sub rsp, 8 mov rdi, [rbp+var_38] mov rsi, r12 mov rdx, r13 mov rcx, [rbp+var_70] mov r8, [rbp+var_40] mov r9d, [rbp+var_44] push [rbp+var_68] mov eax, [rbp+arg_8] push rax mov eax, [rbp+arg_0] push rax call my_wildcmp_mb_impl add rsp, 20h test eax, eax jle short loc_B95BD cmp r12, r13 jnz loc_B94B2 jmp loc_B933E loc_B95B2: mov r14d, 0FFFFFFFFh jmp loc_B933E loc_B95BD: mov r14d, eax jmp loc_B933E
long long my_wildcmp_mb_impl( long long a1, unsigned __int8 *a2, unsigned __int8 *a3, char *a4, char *a5, int a6, int a7, int a8, unsigned int a9) { unsigned int v11; // r14d int v12; // edi char v13; // al int v14; // ecx bool v15; // dl unsigned __int8 *v16; // r13 char *v17; // rax int v18; // ecx long long v19; // rax unsigned __int8 *v20; // rbx int v21; // eax long long v22; // r15 unsigned __int8 *v23; // rax unsigned __int8 *v24; // r13 char *v26; // r15 unsigned __int8 v27; // bl int v28; // ecx long long v29; // rax int v31; // eax int v32; // r15d int v33; // eax int v34; // ecx unsigned __int8 *v35; // rbx int v36; // ecx long long v37; // rax int v38; // eax int v39; // [rsp+0h] [rbp-70h] unsigned int v40; // [rsp+10h] [rbp-60h] char *v42; // [rsp+20h] [rbp-50h] char v46; // [rsp+47h] [rbp-29h] if ( !my_string_stack_guard || (v11 = 1, !(unsigned int)my_string_stack_guard(a9)) ) { v12 = a7; v11 = -1; do { if ( a4 == a5 ) { v16 = a3; return a2 != v16; } v13 = *a4; v14 = *a4; v15 = v14 == v12; v16 = a3; if ( v14 != v12 && v14 != a8 ) { do { v20 = (unsigned __int8 *)(a4 + 1); if ( a4 + 1 == a5 ) v20 = (unsigned __int8 *)a4; if ( v14 != a6 ) v20 = (unsigned __int8 *)a4; v21 = (*(long long ( **)(long long, unsigned __int8 *))(*(_QWORD *)(a1 + 184) + 192LL))(a1, v20); if ( v21 >= 2 ) { v22 = (unsigned int)v21; v23 = v16; v24 = &a2[v22]; v11 = 1; if ( &a2[v22] > v23 ) return v11; v12 = a7; if ( (unsigned int)bcmp(a2, v20, v22) ) return v11; a4 = (char *)&v20[v22]; a2 = v24; } else { v11 = 1; if ( a2 == v16 ) return v11; v12 = a7; if ( *(_BYTE *)(*(_QWORD *)(a1 + 88) + *v20) != *(_BYTE *)(*(_QWORD *)(a1 + 88) + *a2) ) return v11; ++a2; a4 = (char *)(v20 + 1); } v16 = a3; if ( a4 == a5 ) return a2 != v16; v13 = *a4; v14 = *a4; v15 = v14 == v12; } while ( v14 != a8 && v14 != v12 ); } if ( v15 ) { v17 = a4 + 1; do { if ( a2 == v16 ) return v11; a4 = v17; v18 = (*(long long ( **)(long long, unsigned __int8 *, unsigned __int8 *))(*(_QWORD *)(a1 + 184) + 192LL))( a1, a2, v16); v19 = 1LL; if ( v18 >= 2 ) { v19 = (*(long long ( **)(long long, unsigned __int8 *, unsigned __int8 *))(*(_QWORD *)(a1 + 184) + 192LL))( a1, a2, v16); if ( (int)v19 < 2 ) v19 = 0LL; } a2 += v19; v12 = a7; if ( a4 >= a5 ) break; v17 = a4 + 1; } while ( *a4 == a7 ); if ( a4 == a5 ) return a2 != v16; v13 = *a4; } } while ( v13 != a8 ); if ( a4 + 1 == a5 ) { return 0; } else { v26 = a4 + 2; v11 = 0; while ( 1 ) { v27 = *(v26 - 1); if ( (char)v27 == a8 ) goto LABEL_45; if ( (char)v27 != v12 ) break; if ( a2 == a3 ) return (unsigned int)-1; v28 = (*(long long ( **)(long long, unsigned __int8 *, unsigned __int8 *))(*(_QWORD *)(a1 + 184) + 192LL))( a1, a2, a3); v29 = 1LL; if ( v28 >= 2 ) { v29 = (*(long long ( **)(long long, unsigned __int8 *, unsigned __int8 *))(*(_QWORD *)(a1 + 184) + 192LL))( a1, a2, a3); if ( (int)v29 < 2 ) v29 = 0LL; } a2 += v29; v12 = a7; LABEL_45: if ( v26++ == a5 ) return v11; } v11 = -1; if ( a2 != a3 ) { v42 = v26 - 1; if ( v27 == a6 && v26 != a5 ) { v27 = *v26; v42 = v26; } v31 = (*(long long ( **)(long long, char *, char *))(*(_QWORD *)(a1 + 184) + 192LL))(a1, v42, a5); v32 = v31; if ( v31 < 2 ) v31 = 0; v40 = v31; v33 = (*(long long ( **)(long long, char *, char *))(*(_QWORD *)(a1 + 184) + 192LL))(a1, v42, a5); v34 = 1; if ( v33 >= 2 ) { v34 = (*(long long ( **)(long long, char *, char *, long long))(*(_QWORD *)(a1 + 184) + 192LL))( a1, v42, a5, 1LL); if ( v34 < 2 ) v34 = 0; } v39 = (_DWORD)v42 + v34; v46 = *(_BYTE *)(*(_QWORD *)(a1 + 88) + v27); do { if ( a2 >= a3 ) return v11; v35 = a2; while ( v32 >= 2 ) { a2 = &v35[v40]; if ( a2 <= a3 && !(unsigned int)bcmp(v35, v42, v40) ) goto LABEL_71; LABEL_66: v36 = (*(long long ( **)(long long, unsigned __int8 *, unsigned __int8 *))(*(_QWORD *)(a1 + 184) + 192LL))( a1, v35, a3); v37 = 1LL; if ( v36 >= 2 ) { v37 = (*(long long ( **)(long long, unsigned __int8 *, unsigned __int8 *))(*(_QWORD *)(a1 + 184) + 192LL))( a1, v35, a3); if ( (int)v37 < 2 ) v37 = 0LL; } v35 += v37; if ( v35 >= a3 ) return v11; } if ( (*(int ( **)(long long, unsigned __int8 *, unsigned __int8 *))(*(_QWORD *)(a1 + 184) + 192LL))( a1, v35, a3) > 1 || *(_BYTE *)(*(_QWORD *)(a1 + 88) + *v35) != v46 ) { goto LABEL_66; } a2 = v35 + 1; LABEL_71: v38 = my_wildcmp_mb_impl(a1, (_DWORD)a2, (_DWORD)a3, v39, (_DWORD)a5, a6, a7, a8, a9 + 1); if ( v38 <= 0 ) return (unsigned int)v38; } while ( a2 != a3 ); } } } return v11; }
my_wildcmp_mb_impl: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x48 MOV dword ptr [RBP + -0x44],R9D MOV qword ptr [RBP + -0x40],R8 MOV R15,RCX MOV qword ptr [RBP + -0x58],RDX MOV R12,RSI MOV qword ptr [RBP + -0x38],RDI MOV EAX,dword ptr [RBP + 0x20] MOV qword ptr [RBP + -0x68],RAX LEA RAX,[0xd130e8] MOV RAX,qword ptr [RAX] TEST RAX,RAX JZ 0x001b91a3 MOV EDI,dword ptr [RBP + 0x20] CALL RAX MOV R14D,0x1 TEST EAX,EAX JNZ 0x001b933e LAB_001b91a3: MOV EDI,dword ptr [RBP + 0x10] MOV R14D,0xffffffff LAB_001b91ac: CMP R15,qword ptr [RBP + -0x40] JZ 0x001b9330 MOV AL,byte ptr [R15] MOVSX ECX,AL MOV EDX,dword ptr [RBP + 0x18] CMP ECX,EDX SETZ SIL CMP ECX,EDI SETZ DL OR SIL,DL MOV R13,qword ptr [RBP + -0x58] JZ 0x001b926c LAB_001b91d7: TEST DL,DL JZ 0x001b9259 INC R15 MOV RAX,R15 MOV RBX,qword ptr [RBP + -0x38] LAB_001b91e5: CMP R12,R13 JZ 0x001b933e MOV R15,RAX MOV RAX,qword ptr [RBX + 0xb8] MOV RDI,RBX MOV RSI,R12 MOV RDX,R13 CALL qword ptr [RAX + 0xc0] MOV ECX,EAX MOV EAX,0x1 CMP ECX,0x2 JL 0x001b9234 MOV RAX,qword ptr [RBX + 0xb8] MOV RDI,RBX MOV RSI,R12 MOV RDX,R13 CALL qword ptr [RAX + 0xc0] CMP EAX,0x2 MOV ECX,0x0 CMOVL EAX,ECX LAB_001b9234: ADD R12,RAX CMP R15,qword ptr [RBP + -0x40] MOV EDI,dword ptr [RBP + 0x10] JNC 0x001b924c MOVSX ECX,byte ptr [R15] LEA RAX,[R15 + 0x1] CMP ECX,EDI JZ 0x001b91e5 LAB_001b924c: CMP R15,qword ptr [RBP + -0x40] JZ 0x001b9334 MOV AL,byte ptr [R15] LAB_001b9259: MOVSX EAX,AL MOV ECX,dword ptr [RBP + 0x18] CMP EAX,ECX JNZ 0x001b91ac JMP 0x001b9350 LAB_001b926c: LEA RBX,[R15 + 0x1] MOV RDX,qword ptr [RBP + -0x40] CMP RBX,RDX CMOVZ RBX,R15 CMP ECX,dword ptr [RBP + -0x44] CMOVNZ RBX,R15 MOV RDI,qword ptr [RBP + -0x38] MOV RAX,qword ptr [RDI + 0xb8] MOV RSI,RBX CALL qword ptr [RAX + 0xc0] CMP EAX,0x2 JGE 0x001b92d0 MOV R14D,0x1 CMP R12,R13 JZ 0x001b933e MOV RAX,qword ptr [RBP + -0x38] MOV RAX,qword ptr [RAX + 0x58] MOVZX ECX,byte ptr [RBX] MOV CL,byte ptr [RAX + RCX*0x1] MOVZX EDX,byte ptr [R12] CMP CL,byte ptr [RAX + RDX*0x1] MOV EDI,dword ptr [RBP + 0x10] JNZ 0x001b933e INC RBX INC R12 MOV R15,RBX JMP 0x001b9303 LAB_001b92d0: MOV R15D,EAX MOV RAX,R13 LEA R13,[R12 + R15*0x1] MOV R14D,0x1 CMP R13,RAX JA 0x001b933e MOV RDI,R12 MOV RSI,RBX MOV RDX,R15 CALL 0x00129510 TEST EAX,EAX MOV EDI,dword ptr [RBP + 0x10] JNZ 0x001b933e ADD RBX,R15 MOV R15,RBX MOV R12,R13 LAB_001b9303: CMP R15,qword ptr [RBP + -0x40] MOV R13,qword ptr [RBP + -0x58] JZ 0x001b9334 MOV AL,byte ptr [R15] MOVSX ECX,AL CMP ECX,EDI SETZ DL MOV ESI,dword ptr [RBP + 0x18] CMP ECX,ESI JZ 0x001b91d7 CMP ECX,EDI JNZ 0x001b926c JMP 0x001b91d7 LAB_001b9330: MOV R13,qword ptr [RBP + -0x58] LAB_001b9334: XOR R14D,R14D CMP R12,R13 SETNZ R14B LAB_001b933e: MOV EAX,R14D ADD RSP,0x48 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET LAB_001b9350: LEA RAX,[R15 + 0x1] CMP RAX,qword ptr [RBP + -0x40] JZ 0x001b93e0 ADD R15,0x2 XOR R13D,R13D XOR R14D,R14D LAB_001b9368: MOV BL,byte ptr [R15 + -0x1] MOVSX EAX,BL MOV ECX,dword ptr [RBP + 0x18] CMP EAX,ECX JZ 0x001b93ce CMP EAX,EDI JNZ 0x001b93e8 MOV RBX,qword ptr [RBP + -0x58] CMP R12,RBX JZ 0x001b95b2 MOV RDI,qword ptr [RBP + -0x38] MOV RAX,qword ptr [RDI + 0xb8] MOV RSI,R12 MOV RDX,RBX CALL qword ptr [RAX + 0xc0] MOV ECX,EAX MOV EAX,0x1 CMP ECX,0x2 JL 0x001b93c8 MOV RDI,qword ptr [RBP + -0x38] MOV RAX,qword ptr [RDI + 0xb8] MOV RSI,R12 MOV RDX,RBX CALL qword ptr [RAX + 0xc0] CMP EAX,0x2 CMOVL EAX,R13D LAB_001b93c8: ADD R12,RAX MOV EDI,dword ptr [RBP + 0x10] LAB_001b93ce: LEA RAX,[R15 + 0x1] CMP R15,qword ptr [RBP + -0x40] MOV R15,RAX JNZ 0x001b9368 JMP 0x001b933e LAB_001b93e0: XOR R14D,R14D JMP 0x001b933e LAB_001b93e8: MOV R14D,0xffffffff MOV R13,qword ptr [RBP + -0x58] CMP R12,R13 JZ 0x001b933e MOVZX EAX,BL LEA RCX,[R15 + -0x1] MOV qword ptr [RBP + -0x50],RCX CMP EAX,dword ptr [RBP + -0x44] JNZ 0x001b9418 CMP R15,qword ptr [RBP + -0x40] JZ 0x001b9418 MOV BL,byte ptr [R15] MOV qword ptr [RBP + -0x50],R15 LAB_001b9418: MOV RDI,qword ptr [RBP + -0x38] MOV RAX,qword ptr [RDI + 0xb8] MOV RSI,qword ptr [RBP + -0x50] MOV RDX,qword ptr [RBP + -0x40] CALL qword ptr [RAX + 0xc0] XOR ECX,ECX CMP EAX,0x2 MOV R15D,EAX CMOVL EAX,ECX MOV dword ptr [RBP + -0x60],EAX MOV RDI,qword ptr [RBP + -0x38] MOV RAX,qword ptr [RDI + 0xb8] MOV RSI,qword ptr [RBP + -0x50] MOV RDX,qword ptr [RBP + -0x40] CALL qword ptr [RAX + 0xc0] MOV ECX,0x1 CMP EAX,0x2 JL 0x001b9488 MOV RDI,qword ptr [RBP + -0x38] MOV RAX,qword ptr [RDI + 0xb8] MOV RSI,qword ptr [RBP + -0x50] MOV RDX,qword ptr [RBP + -0x40] CALL qword ptr [RAX + 0xc0] MOV ECX,EAX CMP EAX,0x2 MOV EAX,0x0 CMOVL ECX,EAX LAB_001b9488: ADD RCX,qword ptr [RBP + -0x50] MOV qword ptr [RBP + -0x70],RCX MOV RAX,qword ptr [RBP + -0x38] MOV RAX,qword ptr [RAX + 0x58] MOVZX ECX,BL MOV AL,byte ptr [RAX + RCX*0x1] MOV byte ptr [RBP + -0x29],AL MOV EAX,dword ptr [RBP + -0x60] MOV qword ptr [RBP + -0x60],RAX MOV RAX,qword ptr [RBP + -0x68] INC EAX MOV qword ptr [RBP + -0x68],RAX LAB_001b94b2: CMP R12,R13 JNC 0x001b933e MOV RBX,R12 LAB_001b94be: CMP R15D,0x2 JGE 0x001b94f5 MOV RDI,qword ptr [RBP + -0x38] MOV RAX,qword ptr [RDI + 0xb8] MOV RSI,RBX MOV RDX,R13 CALL qword ptr [RAX + 0xc0] CMP EAX,0x1 JG 0x001b9516 MOV RAX,qword ptr [RBP + -0x38] MOV RAX,qword ptr [RAX + 0x58] MOVZX ECX,byte ptr [RBX] MOV DL,byte ptr [RBP + -0x29] CMP byte ptr [RAX + RCX*0x1],DL JNZ 0x001b9516 JMP 0x001b956c LAB_001b94f5: MOV RAX,qword ptr [RBP + -0x60] LEA R12,[RBX + RAX*0x1] CMP R12,R13 JA 0x001b9516 MOV RDI,RBX MOV RSI,qword ptr [RBP + -0x50] MOV RDX,qword ptr [RBP + -0x60] CALL 0x00129510 TEST EAX,EAX JZ 0x001b9572 LAB_001b9516: MOV RDI,qword ptr [RBP + -0x38] MOV RAX,qword ptr [RDI + 0xb8] MOV RSI,RBX MOV RDX,R13 CALL qword ptr [RAX + 0xc0] MOV ECX,EAX MOV EAX,0x1 CMP ECX,0x2 JL 0x001b955b MOV RDI,qword ptr [RBP + -0x38] MOV RAX,qword ptr [RDI + 0xb8] MOV RSI,RBX MOV RDX,R13 CALL qword ptr [RAX + 0xc0] CMP EAX,0x2 MOV ECX,0x0 CMOVL EAX,ECX LAB_001b955b: ADD RBX,RAX CMP RBX,R13 JC 0x001b94be JMP 0x001b933e LAB_001b956c: INC RBX MOV R12,RBX LAB_001b9572: SUB RSP,0x8 MOV RDI,qword ptr [RBP + -0x38] MOV RSI,R12 MOV RDX,R13 MOV RCX,qword ptr [RBP + -0x70] MOV R8,qword ptr [RBP + -0x40] MOV R9D,dword ptr [RBP + -0x44] PUSH qword ptr [RBP + -0x68] MOV EAX,dword ptr [RBP + 0x18] PUSH RAX MOV EAX,dword ptr [RBP + 0x10] PUSH RAX CALL 0x001b9153 ADD RSP,0x20 TEST EAX,EAX JLE 0x001b95bd CMP R12,R13 JNZ 0x001b94b2 JMP 0x001b933e LAB_001b95b2: MOV R14D,0xffffffff JMP 0x001b933e LAB_001b95bd: MOV R14D,EAX JMP 0x001b933e
uint my_wildcmp_mb_impl(long param_1,byte *param_2,byte *param_3,byte *param_4,byte *param_5, uint param_6,uint param_7,uint param_8,int param_9) { char cVar1; byte bVar2; int iVar3; uint uVar4; uint uVar5; ulong uVar6; ulong uVar7; uint uVar8; byte *__s2; byte *pbVar9; bool bVar10; byte *local_58; if ((my_string_stack_guard != (code *)0x0) && (iVar3 = (*my_string_stack_guard)(param_9), iVar3 != 0)) { return 1; } uVar4 = 0xffffffff; do { if (param_4 == param_5) { LAB_001b9334: return (uint)(param_2 != param_3); } bVar2 = *param_4; uVar8 = (uint)(char)bVar2; bVar10 = uVar8 == param_7; pbVar9 = param_2; if (uVar8 != param_8 && !bVar10) { do { __s2 = param_4 + 1; if (param_4 + 1 == param_5) { __s2 = param_4; } if (uVar8 != param_6) { __s2 = param_4; } uVar4 = (**(code **)(*(long *)(param_1 + 0xb8) + 0xc0))(param_1,__s2); if ((int)uVar4 < 2) { if (pbVar9 == param_3) { return 1; } if (*(char *)(*(long *)(param_1 + 0x58) + (ulong)*__s2) != *(char *)(*(long *)(param_1 + 0x58) + (ulong)*pbVar9)) { return 1; } param_4 = __s2 + 1; param_2 = pbVar9 + 1; } else { uVar6 = (ulong)uVar4; param_2 = pbVar9 + uVar6; if (param_3 < param_2) { return 1; } iVar3 = bcmp(pbVar9,__s2,uVar6); if (iVar3 != 0) { return 1; } param_4 = __s2 + uVar6; } uVar4 = 1; if (param_4 == param_5) goto LAB_001b9334; bVar2 = *param_4; uVar8 = (uint)(char)bVar2; bVar10 = uVar8 == param_7; } while ((uVar8 != param_8) && (pbVar9 = param_2, uVar8 != param_7)); } if (bVar10) { do { param_4 = param_4 + 1; if (param_2 == param_3) { return uVar4; } iVar3 = (**(code **)(*(long *)(param_1 + 0xb8) + 0xc0))(param_1,param_2,param_3); uVar6 = 1; if (1 < iVar3) { uVar8 = (**(code **)(*(long *)(param_1 + 0xb8) + 0xc0))(param_1,param_2,param_3); uVar6 = (ulong)uVar8; if ((int)uVar8 < 2) { uVar6 = 0; } } param_2 = param_2 + uVar6; } while ((param_4 < param_5) && ((int)(char)*param_4 == param_7)); if (param_4 == param_5) goto LAB_001b9334; bVar2 = *param_4; } } while ((int)(char)bVar2 != param_8); if (param_4 + 1 != param_5) { pbVar9 = param_4 + 2; do { bVar2 = pbVar9[-1]; if ((int)(char)bVar2 != param_8) { if ((int)(char)bVar2 != param_7) { if (param_2 == param_3) { return 0xffffffff; } local_58 = pbVar9 + -1; if ((bVar2 == param_6) && (pbVar9 != param_5)) { bVar2 = *pbVar9; local_58 = pbVar9; } uVar8 = (**(code **)(*(long *)(param_1 + 0xb8) + 0xc0))(param_1,local_58,param_5); uVar4 = uVar8; if ((int)uVar8 < 2) { uVar4 = 0; } iVar3 = (**(code **)(*(long *)(param_1 + 0xb8) + 0xc0))(param_1,local_58,param_5); uVar6 = 1; if (1 < iVar3) { uVar5 = (**(code **)(*(long *)(param_1 + 0xb8) + 0xc0))(param_1,local_58,param_5); uVar6 = (ulong)uVar5; if ((int)uVar5 < 2) { uVar6 = 0; } } cVar1 = *(char *)(*(long *)(param_1 + 0x58) + (ulong)bVar2); goto LAB_001b94b2; } if (param_2 == param_3) { return 0xffffffff; } iVar3 = (**(code **)(*(long *)(param_1 + 0xb8) + 0xc0))(param_1,param_2,param_3); uVar6 = 1; if (1 < iVar3) { uVar4 = (**(code **)(*(long *)(param_1 + 0xb8) + 0xc0))(param_1,param_2,param_3); uVar6 = (ulong)uVar4; if ((int)uVar4 < 2) { uVar6 = 0; } } param_2 = param_2 + uVar6; } bVar10 = pbVar9 != param_5; pbVar9 = pbVar9 + 1; } while (bVar10); } return 0; LAB_001b94b2: if (param_3 <= param_2) { return 0xffffffff; } do { if ((int)uVar8 < 2) { iVar3 = (**(code **)(*(long *)(param_1 + 0xb8) + 0xc0))(param_1,param_2,param_3); if ((iVar3 < 2) && (*(char *)(*(long *)(param_1 + 0x58) + (ulong)*param_2) == cVar1)) break; } else { pbVar9 = param_2 + uVar4; if ((pbVar9 <= param_3) && (iVar3 = bcmp(param_2,local_58,(ulong)uVar4), iVar3 == 0)) goto LAB_001b9572; } iVar3 = (**(code **)(*(long *)(param_1 + 0xb8) + 0xc0))(param_1,param_2,param_3); uVar7 = 1; if (1 < iVar3) { uVar5 = (**(code **)(*(long *)(param_1 + 0xb8) + 0xc0))(param_1,param_2,param_3); uVar7 = (ulong)uVar5; if ((int)uVar5 < 2) { uVar7 = 0; } } param_2 = param_2 + uVar7; if (param_3 <= param_2) { return 0xffffffff; } } while( true ); pbVar9 = param_2 + 1; LAB_001b9572: uVar5 = my_wildcmp_mb_impl(param_1,pbVar9,param_3,local_58 + uVar6,param_5,param_6,param_7,param_8 ,param_9 + 1); if ((int)uVar5 < 1) { return uVar5; } param_2 = pbVar9; if (pbVar9 == param_3) { return 0xffffffff; } goto LAB_001b94b2; }
31,830
blst_miller_loop_lines
corpus-core[P]colibri-stateless/build_O3/_deps/blst-src/src/pairing.c
void blst_miller_loop_lines(vec384fp12 ret, const vec384fp6 Qlines[68], const POINTonE1_affine *P) { miller_loop_lines(ret, Qlines, P); }
O3
c
blst_miller_loop_lines: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x188, %rsp # imm = 0x188 movq %rdx, %r12 movq %rsi, %r14 movq %rdi, %rbx leaq 0x1f4bb(%rip), %r13 # 0x3fb10 leaq -0x90(%rbp), %r15 movq %r15, %rdi movq %rdx, %rsi movq %r13, %rcx callq 0x2ec40 movl $0x1, %edx movq %r15, %rdi movq %r15, %rsi movq %r13, %rcx callq 0x2f2c0 leaq -0x60(%rbp), %rdi addq $0x30, %r12 movq %r12, %rsi movq %r12, %rdx movq %r13, %rcx callq 0x2ec40 leaq -0x1b0(%rbp), %rdi movq %r14, %rsi movq %r15, %rdx callq 0x28624 xorl %eax, %eax movq $0x0, (%rbx,%rax,8) incq %rax cmpq $0x48, %rax jne 0x206a7 leaq -0x1b0(%rbp), %rsi movl $0xc0, %edx movq %rbx, %rdi callq 0x5060 leaq 0x180(%rbx), %rdi leaq -0xf0(%rbp), %rsi movl $0xc, %ecx rep movsq (%rsi), %es:(%rdi) movl $0x120, %r15d # imm = 0x120 leaq (%r14,%r15), %rsi leaq -0x90(%rbp), %r12 movl $0x2, %ecx movq %rbx, %rdi movq %r12, %rdx callq 0x286cc leaq 0x480(%r14), %rsi movl $0x3, %ecx movq %rbx, %rdi movq %r12, %rdx callq 0x286cc leaq 0x900(%r14), %rsi movl $0x9, %ecx movq %rbx, %rdi movq %r12, %rdx callq 0x286cc leaq 0x1440(%r14), %rsi movl $0x20, %ecx movq %rbx, %rdi movq %r12, %rdx callq 0x286cc addq $0x3960, %r14 # imm = 0x3960 movl $0x10, %ecx movq %rbx, %rdi movq %r14, %rsi movq %r12, %rdx callq 0x286cc addq %rbx, %r15 movq %r15, %rdi movq %r15, %rsi callq 0x279e1 addq $0x188, %rsp # imm = 0x188 popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
blst_miller_loop_lines: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx sub rsp, 188h mov r12, rdx mov r14, rsi mov rbx, rdi lea r13, BLS12_381_P lea r15, [rbp+var_90] mov rdi, r15 mov rsi, rdx mov rcx, r13 call add_mod_384 mov edx, 1 mov rdi, r15 mov rsi, r15 mov rcx, r13 call cneg_mod_384 lea rdi, [rbp+var_60] add r12, 30h ; '0' mov rsi, r12 mov rdx, r12 mov rcx, r13 call add_mod_384 lea rdi, [rbp+var_1B0] mov rsi, r14 mov rdx, r15 call post_line_by_Px2 xor eax, eax loc_206A7: mov qword ptr [rbx+rax*8], 0 inc rax cmp rax, 48h ; 'H' jnz short loc_206A7 lea rsi, [rbp+var_1B0] mov edx, 0C0h mov rdi, rbx call _memcpy lea rdi, [rbx+180h] lea rsi, [rbp+var_F0] mov ecx, 0Ch rep movsq mov r15d, 120h lea rsi, [r14+r15] lea r12, [rbp+var_90] mov ecx, 2 mov rdi, rbx mov rdx, r12 call post_add_n_dbl lea rsi, [r14+480h] mov ecx, 3 mov rdi, rbx mov rdx, r12 call post_add_n_dbl lea rsi, [r14+900h] mov ecx, 9 mov rdi, rbx mov rdx, r12 call post_add_n_dbl lea rsi, [r14+1440h] mov ecx, 20h ; ' ' mov rdi, rbx mov rdx, r12 call post_add_n_dbl add r14, 3960h mov ecx, 10h mov rdi, rbx mov rsi, r14 mov rdx, r12 call post_add_n_dbl add r15, rbx mov rdi, r15 mov rsi, r15 call neg_fp6 add rsp, 188h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
long long blst_miller_loop_lines(long long a1, long long a2, long long a3) { long long i; // rax _BYTE v6[192]; // [rsp+0h] [rbp-1B0h] BYREF _BYTE v7[96]; // [rsp+C0h] [rbp-F0h] BYREF _BYTE v8[48]; // [rsp+120h] [rbp-90h] BYREF _BYTE v9[96]; // [rsp+150h] [rbp-60h] BYREF add_mod_384(v8, a3, a3, &BLS12_381_P); cneg_mod_384(v8, v8, 1LL, &BLS12_381_P); add_mod_384(v9, a3 + 48, a3 + 48, &BLS12_381_P); post_line_by_Px2(v6, a2, v8); for ( i = 0LL; i != 72; ++i ) *(_QWORD *)(a1 + 8 * i) = 0LL; memcpy(a1, v6, 192LL); qmemcpy((void *)(a1 + 384), v7, 0x60uLL); post_add_n_dbl(a1, a2 + 288, v8, 2LL); post_add_n_dbl(a1, a2 + 1152, v8, 3LL); post_add_n_dbl(a1, a2 + 2304, v8, 9LL); post_add_n_dbl(a1, a2 + 5184, v8, 32LL); post_add_n_dbl(a1, a2 + 14688, v8, 16LL); return neg_fp6(a1 + 288, a1 + 288); }
blst_miller_loop_lines: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x188 MOV R12,RDX MOV R14,RSI MOV RBX,RDI LEA R13,[0x13fb10] LEA R15,[RBP + -0x90] MOV RDI,R15 MOV RSI,RDX MOV RCX,R13 CALL 0x0012ec40 MOV EDX,0x1 MOV RDI,R15 MOV RSI,R15 MOV RCX,R13 CALL 0x0012f2c0 LEA RDI,[RBP + -0x60] ADD R12,0x30 MOV RSI,R12 MOV RDX,R12 MOV RCX,R13 CALL 0x0012ec40 LEA RDI,[RBP + -0x1b0] MOV RSI,R14 MOV RDX,R15 CALL 0x00128624 XOR EAX,EAX LAB_001206a7: MOV qword ptr [RBX + RAX*0x8],0x0 INC RAX CMP RAX,0x48 JNZ 0x001206a7 LEA RSI,[RBP + -0x1b0] MOV EDX,0xc0 MOV RDI,RBX CALL 0x00105060 LEA RDI,[RBX + 0x180] LEA RSI,[RBP + -0xf0] MOV ECX,0xc MOVSQ.REP RDI,RSI MOV R15D,0x120 LEA RSI,[R14 + R15*0x1] LEA R12,[RBP + -0x90] MOV ECX,0x2 MOV RDI,RBX MOV RDX,R12 CALL 0x001286cc LEA RSI,[R14 + 0x480] MOV ECX,0x3 MOV RDI,RBX MOV RDX,R12 CALL 0x001286cc LEA RSI,[R14 + 0x900] MOV ECX,0x9 MOV RDI,RBX MOV RDX,R12 CALL 0x001286cc LEA RSI,[R14 + 0x1440] MOV ECX,0x20 MOV RDI,RBX MOV RDX,R12 CALL 0x001286cc ADD R14,0x3960 MOV ECX,0x10 MOV RDI,RBX MOV RSI,R14 MOV RDX,R12 CALL 0x001286cc ADD R15,RBX MOV RDI,R15 MOV RSI,R15 CALL 0x001279e1 ADD RSP,0x188 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
void blst_miller_loop_lines(void *param_1,long param_2,long param_3) { long lVar1; int8 *puVar2; int8 *puVar3; byte bVar4; int1 local_1b8 [192]; int8 local_f8 [12]; int1 local_98 [48]; int1 local_68 [56]; bVar4 = 0; add_mod_384(local_98,param_3,param_3,BLS12_381_P); cneg_mod_384(local_98,local_98,1,BLS12_381_P); add_mod_384(local_68,param_3 + 0x30,param_3 + 0x30,BLS12_381_P); post_line_by_Px2(local_1b8,param_2,local_98); lVar1 = 0; do { *(int8 *)((long)param_1 + lVar1 * 8) = 0; lVar1 = lVar1 + 1; } while (lVar1 != 0x48); memcpy(param_1,local_1b8,0xc0); puVar2 = local_f8; puVar3 = (int8 *)((long)param_1 + 0x180); for (lVar1 = 0xc; lVar1 != 0; lVar1 = lVar1 + -1) { *puVar3 = *puVar2; puVar2 = puVar2 + (ulong)bVar4 * -2 + 1; puVar3 = puVar3 + (ulong)bVar4 * -2 + 1; } post_add_n_dbl(param_1,param_2 + 0x120,local_98,2); post_add_n_dbl(param_1,param_2 + 0x480,local_98,3); post_add_n_dbl(param_1,param_2 + 0x900,local_98,9); post_add_n_dbl(param_1,param_2 + 0x1440,local_98,0x20); post_add_n_dbl(param_1,param_2 + 0x3960,local_98,0x10); neg_fp6((long)param_1 + 0x120,(long)param_1 + 0x120); return; }
31,831
my_hash_sort_utf8mb3_nopad
eloqsql/strings/ctype-utf8.c
static void my_hash_sort_utf8mb3_nopad(CHARSET_INFO *cs, const uchar *s, size_t slen, ulong *nr1, ulong *nr2) { my_wc_t wc; int res; const uchar *e= s+slen; MY_UNICASE_INFO *uni_plane= cs->caseinfo; register ulong m1= *nr1, m2= *nr2; while ((s < e) && (res=my_utf8mb3_uni(cs,&wc, (uchar *)s, (uchar*)e))>0 ) { my_tosort_unicode(uni_plane, &wc, cs->state); MY_HASH_ADD_16(m1, m2, wc); s+= res; } *nr1= m1; *nr2= m2; }
O3
c
my_hash_sort_utf8mb3_nopad: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x28, %rsp movq %rcx, -0x38(%rbp) movq (%rcx), %r13 movq %r8, -0x40(%rbp) movq (%r8), %r14 testq %rdx, %rdx jle 0xcff9a movq %rdx, %r15 movq %rsi, %r12 addq %rsi, %r15 movq %rdi, -0x48(%rbp) movq 0x78(%rdi), %rbx leaq -0x30(%rbp), %rsi movq %r12, %rdx movq %r15, %rcx callq 0xce6ef testl %eax, %eax jle 0xcff9a movq -0x30(%rbp), %rdx movl $0xfffd, %esi # imm = 0xFFFD cmpq (%rbx), %rdx ja 0xcff42 movq 0x8(%rbx), %rsi movq %rdx, %rcx shrq $0x8, %rcx movq (%rsi,%rcx,8), %rsi testq %rsi, %rsi je 0xcff4e movq -0x48(%rbp), %rcx movl 0xc(%rcx), %ecx xorl %edi, %edi testw %cx, %cx setns %dil movzbl %dl, %ecx leaq (%rcx,%rcx,2), %rcx leaq (%rsi,%rcx,4), %rcx movl 0x4(%rcx,%rdi,4), %esi movq %rsi, -0x30(%rbp) movl %esi, %ecx shrl $0x8, %ecx movq %rsi, %rdx movl %r13d, %esi andl $0x3f, %esi addq %r14, %rsi movzbl %dl, %edx imulq %rsi, %rdx movq %r13, %rsi shlq $0x8, %rsi addq %rdx, %rsi xorq %r13, %rsi movl %esi, %edx andl $0x3f, %edx addq %r14, %rdx addq $0x3, %rdx imulq %rcx, %rdx movq %rsi, %r13 shlq $0x8, %r13 addq %rdx, %r13 xorq %rsi, %r13 addq $0x6, %r14 movl %eax, %eax addq %rax, %r12 cmpq %r15, %r12 jb 0xcfeea movq -0x38(%rbp), %rax movq %r13, (%rax) movq -0x40(%rbp), %rax movq %r14, (%rax) addq $0x28, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
my_hash_sort_utf8mb3_nopad: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx sub rsp, 28h mov [rbp+var_38], rcx mov r13, [rcx] mov [rbp+var_40], r8 mov r14, [r8] test rdx, rdx jle loc_CFF9A mov r15, rdx mov r12, rsi add r15, rsi mov [rbp+var_48], rdi mov rbx, [rdi+78h] loc_CFEEA: lea rsi, [rbp+var_30] mov rdx, r12 mov rcx, r15 call my_utf8mb3_uni test eax, eax jle loc_CFF9A mov rdx, [rbp+var_30] mov esi, 0FFFDh cmp rdx, [rbx] ja short loc_CFF42 mov rsi, [rbx+8] mov rcx, rdx shr rcx, 8 mov rsi, [rsi+rcx*8] test rsi, rsi jz short loc_CFF4E mov rcx, [rbp+var_48] mov ecx, [rcx+0Ch] xor edi, edi test cx, cx setns dil movzx ecx, dl lea rcx, [rcx+rcx*2] lea rcx, [rsi+rcx*4] mov esi, [rcx+rdi*4+4] loc_CFF42: mov [rbp+var_30], rsi mov ecx, esi shr ecx, 8 mov rdx, rsi loc_CFF4E: mov esi, r13d and esi, 3Fh add rsi, r14 movzx edx, dl imul rdx, rsi mov rsi, r13 shl rsi, 8 add rsi, rdx xor rsi, r13 mov edx, esi and edx, 3Fh add rdx, r14 add rdx, 3 imul rdx, rcx mov r13, rsi shl r13, 8 add r13, rdx xor r13, rsi add r14, 6 mov eax, eax add r12, rax cmp r12, r15 jb loc_CFEEA loc_CFF9A: mov rax, [rbp+var_38] mov [rax], r13 mov rax, [rbp+var_40] mov [rax], r14 add rsp, 28h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
_QWORD * my_hash_sort_utf8mb3_nopad(long long a1, unsigned __int8 *a2, long long a3, long long *a4, _QWORD *a5) { long long v5; // r13 long long v6; // r14 unsigned __int8 *v7; // r12 unsigned long long v8; // r15 _QWORD *v9; // rbx int v10; // eax unsigned __int8 v11; // dl long long v12; // rsi unsigned long long v13; // rcx long long v14; // rsi long long v15; // rsi _QWORD *result; // rax long long v17; // [rsp+8h] [rbp-48h] unsigned long long v20[6]; // [rsp+20h] [rbp-30h] BYREF v5 = *a4; v6 = *a5; if ( a3 > 0 ) { v7 = a2; v8 = (unsigned long long)&a2[a3]; v17 = a1; v9 = *(_QWORD **)(a1 + 120); while ( 1 ) { v10 = my_utf8mb3_uni(a1, v20, v7, v8); if ( v10 <= 0 ) goto LABEL_9; v11 = v20[0]; v12 = 65533LL; if ( v20[0] > *v9 ) goto LABEL_7; v13 = v20[0] >> 8; v14 = *(_QWORD *)(v9[1] + 8 * (v20[0] >> 8)); if ( v14 ) break; LABEL_8: v15 = v5 ^ ((v6 + (v5 & 0x3F)) * v11 + (v5 << 8)); v5 = v15 ^ (v13 * (v6 + (((unsigned __int8)v5 ^ (unsigned __int8)((v6 + (v5 & 0x3F)) * v11)) & 0x3F) + 3) + (v15 << 8)); v6 += 6LL; v7 += (unsigned int)v10; if ( (unsigned long long)v7 >= v8 ) goto LABEL_9; } a1 = (*(_DWORD *)(v17 + 12) & 0x8000u) == 0; v12 = *(unsigned int *)(v14 + 12LL * LOBYTE(v20[0]) + 4 * a1 + 4); LABEL_7: v20[0] = v12; v13 = (unsigned int)v12 >> 8; v11 = v12; goto LABEL_8; } LABEL_9: *a4 = v5; result = a5; *a5 = v6; return result; }
my_hash_sort_utf8mb3_nopad: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x28 MOV qword ptr [RBP + -0x38],RCX MOV R13,qword ptr [RCX] MOV qword ptr [RBP + -0x40],R8 MOV R14,qword ptr [R8] TEST RDX,RDX JLE 0x001cff9a MOV R15,RDX MOV R12,RSI ADD R15,RSI MOV qword ptr [RBP + -0x48],RDI MOV RBX,qword ptr [RDI + 0x78] LAB_001cfeea: LEA RSI,[RBP + -0x30] MOV RDX,R12 MOV RCX,R15 CALL 0x001ce6ef TEST EAX,EAX JLE 0x001cff9a MOV RDX,qword ptr [RBP + -0x30] MOV ESI,0xfffd CMP RDX,qword ptr [RBX] JA 0x001cff42 MOV RSI,qword ptr [RBX + 0x8] MOV RCX,RDX SHR RCX,0x8 MOV RSI,qword ptr [RSI + RCX*0x8] TEST RSI,RSI JZ 0x001cff4e MOV RCX,qword ptr [RBP + -0x48] MOV ECX,dword ptr [RCX + 0xc] XOR EDI,EDI TEST CX,CX SETNS DIL MOVZX ECX,DL LEA RCX,[RCX + RCX*0x2] LEA RCX,[RSI + RCX*0x4] MOV ESI,dword ptr [RCX + RDI*0x4 + 0x4] LAB_001cff42: MOV qword ptr [RBP + -0x30],RSI MOV ECX,ESI SHR ECX,0x8 MOV RDX,RSI LAB_001cff4e: MOV ESI,R13D AND ESI,0x3f ADD RSI,R14 MOVZX EDX,DL IMUL RDX,RSI MOV RSI,R13 SHL RSI,0x8 ADD RSI,RDX XOR RSI,R13 MOV EDX,ESI AND EDX,0x3f ADD RDX,R14 ADD RDX,0x3 IMUL RDX,RCX MOV R13,RSI SHL R13,0x8 ADD R13,RDX XOR R13,RSI ADD R14,0x6 MOV EAX,EAX ADD R12,RAX CMP R12,R15 JC 0x001cfeea LAB_001cff9a: MOV RAX,qword ptr [RBP + -0x38] MOV qword ptr [RAX],R13 MOV RAX,qword ptr [RBP + -0x40] MOV qword ptr [RAX],R14 ADD RSP,0x28 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
void my_hash_sort_utf8mb3_nopad (long param_1,ulong param_2,long param_3,ulong *param_4,long *param_5) { ulong *puVar1; long lVar2; uint uVar3; ulong uVar4; ulong uVar5; ulong uVar6; long lVar7; ulong uVar8; ulong local_38; uVar6 = *param_4; lVar7 = *param_5; if (0 < param_3) { uVar8 = param_3 + param_2; puVar1 = *(ulong **)(param_1 + 0x78); do { uVar3 = my_utf8mb3_uni(); if ((int)uVar3 < 1) break; uVar5 = 0xfffd; if (*puVar1 < local_38) { LAB_001cff42: uVar4 = uVar5 >> 8; local_38 = uVar5; } else { uVar4 = local_38 >> 8; lVar2 = *(long *)(puVar1[1] + uVar4 * 8); if (lVar2 != 0) { uVar5 = (ulong)*(uint *)(lVar2 + (local_38 & 0xff) * 0xc + 4 + (ulong)(-1 < (short)*(int4 *)(param_1 + 0xc)) * 4); goto LAB_001cff42; } } uVar6 = uVar6 * 0x100 + (local_38 & 0xff) * ((ulong)((uint)uVar6 & 0x3f) + lVar7) ^ uVar6; uVar6 = uVar6 * 0x100 + ((ulong)((uint)uVar6 & 0x3f) + lVar7 + 3) * uVar4 ^ uVar6; lVar7 = lVar7 + 6; param_2 = param_2 + uVar3; } while (param_2 < uVar8); } *param_4 = uVar6; *param_5 = lVar7; return; }
31,832
hist(LefDefParser::defrCallbackType_e, char const*, void*)
Efficient-TDP/thirdparty/Limbo/limbo/thirdparty/lefdef/5.8/def/defdiff/diffDefRW.cpp
int hist(defrCallbackType_e c, const char* h, defiUserData ud) { checkType(c); if (ud != userData) dataError(); fprintf(fout, "HIST %s\n", h); return 0; }
O3
cpp
hist(LefDefParser::defrCallbackType_e, char const*, void*): pushq %r14 pushq %rbx pushq %rax movq %rdx, %r14 movq %rsi, %rbx cmpl $0x68, %edi jb 0xac29 movq 0x5863d(%rip), %rcx # 0x63250 leaq 0x33875(%rip), %rdi # 0x3e48f movl $0x27, %esi movl $0x1, %edx callq 0x6350 cmpq %r14, 0x58628(%rip) # 0x63258 je 0xac4f movq 0x58617(%rip), %rcx # 0x63250 leaq 0x33824(%rip), %rdi # 0x3e464 movl $0x2a, %esi movl $0x1, %edx callq 0x6350 movq 0x585fa(%rip), %rdi # 0x63250 leaq 0x34088(%rip), %rsi # 0x3ece5 movq %rbx, %rdx xorl %eax, %eax callq 0x6290 xorl %eax, %eax addq $0x8, %rsp popq %rbx popq %r14 retq
_Z4histN12LefDefParser18defrCallbackType_eEPKcPv: push r14 push rbx push rax mov r14, rdx mov rbx, rsi cmp edi, 68h ; 'h' jb short loc_AC29 mov rcx, cs:fout lea rdi, aErrorCallbackT; "ERROR: callback type is out of bounds!"... mov esi, 27h ; ''' mov edx, 1 call _fwrite loc_AC29: cmp cs:userData, r14 jz short loc_AC4F mov rcx, cs:fout lea rdi, aErrorReturnedU; "ERROR: returned user data is not correc"... mov esi, 2Ah ; '*' mov edx, 1 call _fwrite loc_AC4F: mov rdi, cs:fout lea rsi, aHistS; "HIST %s\n" mov rdx, rbx xor eax, eax call _fprintf xor eax, eax add rsp, 8 pop rbx pop r14 retn
long long hist(unsigned int a1, const char *a2, long long a3) { if ( a1 >= 0x68 ) fwrite("ERROR: callback type is out of bounds!\n", 39LL, 1LL, fout); if ( userData != a3 ) fwrite("ERROR: returned user data is not correct!\n", 42LL, 1LL, fout); fprintf(fout, "HIST %s\n", a2); return 0LL; }
hist: PUSH R14 PUSH RBX PUSH RAX MOV R14,RDX MOV RBX,RSI CMP EDI,0x68 JC 0x0010ac29 MOV RCX,qword ptr [0x00163250] LEA RDI,[0x13e48f] MOV ESI,0x27 MOV EDX,0x1 CALL 0x00106350 LAB_0010ac29: CMP qword ptr [0x00163258],R14 JZ 0x0010ac4f MOV RCX,qword ptr [0x00163250] LEA RDI,[0x13e464] MOV ESI,0x2a MOV EDX,0x1 CALL 0x00106350 LAB_0010ac4f: MOV RDI,qword ptr [0x00163250] LEA RSI,[0x13ece5] MOV RDX,RBX XOR EAX,EAX CALL 0x00106290 XOR EAX,EAX ADD RSP,0x8 POP RBX POP R14 RET
/* hist(LefDefParser::defrCallbackType_e, char const*, void*) */ int8 hist(uint param_1,int8 param_2,long param_3) { if (0x67 < param_1) { fwrite("ERROR: callback type is out of bounds!\n",0x27,1,fout); } if (userData != param_3) { fwrite("ERROR: returned user data is not correct!\n",0x2a,1,fout); } fprintf(fout,"HIST %s\n",param_2); return 0; }
31,833
re_parse_group_name
bluesky950520[P]quickjs/libregexp.c
static int re_parse_group_name(char *buf, int buf_size, const uint8_t **pp) { const uint8_t *p, *p_next; uint32_t c, d; char *q; p = *pp; q = buf; for(;;) { c = *p++; if (c == '\\') { if (*p != 'u') return -1; c = lre_parse_escape(&p, 2); // accept surrogate pairs if ((int)c < 0) return -1; } else if (c == '>') { break; } else if (c >= 0x80) { c = utf8_decode(p - 1, &p_next); if (p_next == p) return -1; p = p_next; if (is_hi_surrogate(c)) { d = utf8_decode(p, &p_next); if (is_lo_surrogate(d)) { c = from_surrogate(c, d); p = p_next; } } } if (q == buf) { if (!lre_js_is_ident_first(c)) return -1; } else { if (!lre_js_is_ident_next(c)) return -1; } if ((q - buf + UTF8_CHAR_LEN_MAX + 1) > buf_size) return -1; if (c < 0x80) { *q++ = c; } else { q += utf8_encode((uint8_t*)q, c); } } if (q == buf) return -1; *q = '\0'; *pp = p; return 0; }
O2
c
re_parse_group_name: pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x18, %rsp movq %rdi, %r14 movq %rsp, %r13 pushq $0x2 popq %rbp movq %rsi, 0x10(%rsp) movq %rsi, %rax movq %rdi, %r15 movq (%rax), %rdi leaq 0x1(%rdi), %r12 movq %r12, (%rsp) movzbl (%rdi), %ebx cmpl $0x5c, %ebx je 0x7e3c0 cmpl $0x3e, %ebx je 0x7e484 testb %bl, %bl jns 0x7e3df leaq 0x8(%rsp), %rsi callq 0x15f80 movq 0x8(%rsp), %rdi cmpq %r12, %rdi je 0x7e472 movl %eax, %ebx movq %rdi, (%rsp) andl $0xfffffc00, %eax # imm = 0xFFFFFC00 cmpl $0xd800, %eax # imm = 0xD800 jne 0x7e3df leaq 0x8(%rsp), %rsi callq 0x15f80 movl %eax, %ecx andl $0xfffffc00, %ecx # imm = 0xFFFFFC00 cmpl $0xdc00, %ecx # imm = 0xDC00 jne 0x7e3df shll $0xa, %ebx andl $0xffc00, %ebx # imm = 0xFFC00 andl $0x3ff, %eax # imm = 0x3FF addl %eax, %ebx addl $0x10000, %ebx # imm = 0x10000 movq 0x8(%rsp), %rax movq %rax, (%rsp) jmp 0x7e3df cmpb $0x75, (%r12) jne 0x7e472 movq %r13, %rdi movl %ebp, %esi callq 0x7b936 movl %eax, %ebx testl %eax, %eax js 0x7e472 movq %r15, %r12 subq %r14, %r12 je 0x7e3fa cmpl $0x7f, %ebx ja 0x7e418 movl %ebx, %eax shrl $0x5, %eax leaq 0xbee8(%rip), %rcx # 0x8a2e0 jmp 0x7e40b cmpl $0x7f, %ebx ja 0x7e439 movl %ebx, %eax shrl $0x5, %eax leaq 0xbec5(%rip), %rcx # 0x8a2d0 movl (%rcx,%rax,4), %ecx xorl %eax, %eax btl %ebx, %ecx setb %al jmp 0x7e440 movl %ebx, %edi callq 0x7f707 testl %eax, %eax setne %al movl %ebx, %ecx andl $-0x2, %ecx cmpl $0x200c, %ecx # imm = 0x200C sete %cl orb %al, %cl movzbl %cl, %eax jmp 0x7e440 movl %ebx, %edi callq 0x7f6f1 testl %eax, %eax je 0x7e472 cmpq $0x7b, %r12 jg 0x7e472 cmpl $0x7f, %ebx ja 0x7e45d movb %bl, (%r15) incq %r15 movq %r13, %rax jmp 0x7e337 movq %r15, %rdi movl %ebx, %esi callq 0x15edf addq %rax, %r15 movq %r13, %rax jmp 0x7e337 pushq $-0x1 popq %rax addq $0x18, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq cmpq %r14, %r15 pushq $-0x1 popq %rax je 0x7e475 movb $0x0, (%r15) movq (%rsp), %rax movq 0x10(%rsp), %rcx movq %rax, (%rcx) xorl %eax, %eax jmp 0x7e475
re_parse_group_name: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 18h mov r14, rdi mov r13, rsp push 2 pop rbp mov [rsp+48h+var_38], rsi mov rax, rsi mov r15, rdi loc_7E337: mov rdi, [rax] lea r12, [rdi+1] mov [rsp+48h+var_48], r12 movzx ebx, byte ptr [rdi] cmp ebx, 5Ch ; '\' jz short loc_7E3C0 cmp ebx, 3Eh ; '>' jz loc_7E484 test bl, bl jns loc_7E3DF lea rsi, [rsp+48h+var_40] call utf8_decode mov rdi, [rsp+48h+var_40] cmp rdi, r12 jz loc_7E472 mov ebx, eax mov [rsp+48h+var_48], rdi and eax, 0FFFFFC00h cmp eax, 0D800h jnz short loc_7E3DF lea rsi, [rsp+48h+var_40] call utf8_decode mov ecx, eax and ecx, 0FFFFFC00h cmp ecx, 0DC00h jnz short loc_7E3DF shl ebx, 0Ah and ebx, 0FFC00h and eax, 3FFh add ebx, eax add ebx, 10000h mov rax, [rsp+48h+var_40] mov [rsp+48h+var_48], rax jmp short loc_7E3DF loc_7E3C0: cmp byte ptr [r12], 75h ; 'u' jnz loc_7E472 mov rdi, r13 mov esi, ebp call lre_parse_escape mov ebx, eax test eax, eax js loc_7E472 loc_7E3DF: mov r12, r15 sub r12, r14 jz short loc_7E3FA cmp ebx, 7Fh ja short loc_7E418 mov eax, ebx shr eax, 5 lea rcx, lre_id_continue_table_ascii jmp short loc_7E40B loc_7E3FA: cmp ebx, 7Fh ja short loc_7E439 mov eax, ebx shr eax, 5 lea rcx, lre_id_start_table_ascii loc_7E40B: mov ecx, [rcx+rax*4] xor eax, eax bt ecx, ebx setb al jmp short loc_7E440 loc_7E418: mov edi, ebx call lre_is_id_continue test eax, eax setnz al mov ecx, ebx and ecx, 0FFFFFFFEh cmp ecx, 200Ch setz cl or cl, al movzx eax, cl jmp short loc_7E440 loc_7E439: mov edi, ebx call lre_is_id_start loc_7E440: test eax, eax jz short loc_7E472 cmp r12, 7Bh ; '{' jg short loc_7E472 cmp ebx, 7Fh ja short loc_7E45D mov [r15], bl inc r15 mov rax, r13 jmp loc_7E337 loc_7E45D: mov rdi, r15 mov esi, ebx call utf8_encode add r15, rax mov rax, r13 jmp loc_7E337 loc_7E472: push 0FFFFFFFFFFFFFFFFh pop rax loc_7E475: add rsp, 18h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn loc_7E484: cmp r15, r14 push 0FFFFFFFFFFFFFFFFh pop rax jz short loc_7E475 mov byte ptr [r15], 0 mov rax, [rsp+48h+var_48] mov rcx, [rsp+48h+var_38] mov [rcx], rax xor eax, eax jmp short loc_7E475
long long re_parse_group_name(_BYTE *a1, _QWORD *a2) { char **v3; // rax _BYTE *v4; // r15 char *v5; // rdi unsigned __int8 *v6; // r12 unsigned int v7; // ebx unsigned int v8; // eax int v9; // eax long long v10; // rax _DWORD *v11; // rcx int v12; // ecx int is_id_start; // eax long long result; // rax unsigned __int8 *v15; // [rsp+0h] [rbp-48h] BYREF char *v16; // [rsp+8h] [rbp-40h] BYREF _QWORD *v17; // [rsp+10h] [rbp-38h] v17 = a2; v3 = (char **)a2; v4 = a1; while ( 1 ) { v5 = *v3; v6 = (unsigned __int8 *)(*v3 + 1); v15 = v6; v7 = (unsigned __int8)*v5; if ( v7 != 92 ) break; if ( *v6 != 117 ) return -1LL; v7 = lre_parse_escape(&v15, 2); if ( (v7 & 0x80000000) != 0 ) return -1LL; LABEL_11: if ( v4 == a1 ) { if ( v7 > 0x7F ) { is_id_start = lre_is_id_start(v7); goto LABEL_19; } v10 = v7 >> 5; v11 = lre_id_start_table_ascii; } else { if ( v7 > 0x7F ) { is_id_start = (unsigned int)lre_is_id_continue(v7) != 0 || (v7 & 0xFFFFFFFE) == 8204; goto LABEL_19; } v10 = v7 >> 5; v11 = lre_id_continue_table_ascii; } v12 = v11[v10]; is_id_start = _bittest(&v12, v7); LABEL_19: if ( !is_id_start || v4 - a1 > 123 ) return -1LL; if ( v7 > 0x7F ) v4 += utf8_encode(v4, v7); else *v4++ = v7; v3 = (char **)&v15; } if ( v7 != 62 ) { if ( (v7 & 0x80u) != 0 ) { v8 = utf8_decode(v5, &v16); if ( v16 == (char *)v6 ) return -1LL; v7 = v8; v15 = (unsigned __int8 *)v16; if ( (v8 & 0xFFFFFC00) == 0xD800 ) { v9 = utf8_decode(v16, &v16); if ( (v9 & 0xFFFFFC00) == 0xDC00 ) { v7 = (v9 & 0x3FF) + ((v7 << 10) & 0xFFC00) + 0x10000; v15 = (unsigned __int8 *)v16; } } } goto LABEL_11; } result = -1LL; if ( v4 != a1 ) { *v4 = 0; *v17 = v15; return 0LL; } return result; }
re_parse_group_name: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x18 MOV R14,RDI MOV R13,RSP PUSH 0x2 POP RBP MOV qword ptr [RSP + 0x10],RSI MOV RAX,RSI MOV R15,RDI LAB_0017e337: MOV RDI,qword ptr [RAX] LEA R12,[RDI + 0x1] MOV qword ptr [RSP],R12 MOVZX EBX,byte ptr [RDI] CMP EBX,0x5c JZ 0x0017e3c0 CMP EBX,0x3e JZ 0x0017e484 TEST BL,BL JNS 0x0017e3df LEA RSI,[RSP + 0x8] CALL 0x00115f80 MOV RDI,qword ptr [RSP + 0x8] CMP RDI,R12 JZ 0x0017e472 MOV EBX,EAX MOV qword ptr [RSP],RDI AND EAX,0xfffffc00 CMP EAX,0xd800 JNZ 0x0017e3df LEA RSI,[RSP + 0x8] CALL 0x00115f80 MOV ECX,EAX AND ECX,0xfffffc00 CMP ECX,0xdc00 JNZ 0x0017e3df SHL EBX,0xa AND EBX,0xffc00 AND EAX,0x3ff ADD EBX,EAX ADD EBX,0x10000 MOV RAX,qword ptr [RSP + 0x8] MOV qword ptr [RSP],RAX JMP 0x0017e3df LAB_0017e3c0: CMP byte ptr [R12],0x75 JNZ 0x0017e472 MOV RDI,R13 MOV ESI,EBP CALL 0x0017b936 MOV EBX,EAX TEST EAX,EAX JS 0x0017e472 LAB_0017e3df: MOV R12,R15 SUB R12,R14 JZ 0x0017e3fa CMP EBX,0x7f JA 0x0017e418 MOV EAX,EBX SHR EAX,0x5 LEA RCX,[0x18a2e0] JMP 0x0017e40b LAB_0017e3fa: CMP EBX,0x7f JA 0x0017e439 MOV EAX,EBX SHR EAX,0x5 LEA RCX,[0x18a2d0] LAB_0017e40b: MOV ECX,dword ptr [RCX + RAX*0x4] XOR EAX,EAX BT ECX,EBX SETC AL JMP 0x0017e440 LAB_0017e418: MOV EDI,EBX CALL 0x0017f707 TEST EAX,EAX SETNZ AL MOV ECX,EBX AND ECX,0xfffffffe CMP ECX,0x200c SETZ CL OR CL,AL MOVZX EAX,CL JMP 0x0017e440 LAB_0017e439: MOV EDI,EBX CALL 0x0017f6f1 LAB_0017e440: TEST EAX,EAX JZ 0x0017e472 CMP R12,0x7b JG 0x0017e472 CMP EBX,0x7f JA 0x0017e45d MOV byte ptr [R15],BL INC R15 MOV RAX,R13 JMP 0x0017e337 LAB_0017e45d: MOV RDI,R15 MOV ESI,EBX CALL 0x00115edf ADD R15,RAX MOV RAX,R13 JMP 0x0017e337 LAB_0017e472: PUSH -0x1 POP RAX LAB_0017e475: ADD RSP,0x18 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET LAB_0017e484: CMP R15,R14 PUSH -0x1 POP RAX JZ 0x0017e475 MOV byte ptr [R15],0x0 MOV RAX,qword ptr [RSP] MOV RCX,qword ptr [RSP + 0x10] MOV qword ptr [RCX],RAX XOR EAX,EAX JMP 0x0017e475
int8 re_parse_group_name(int1 *param_1,byte **param_2) { byte *pbVar1; byte bVar2; byte *pbVar3; uint uVar4; uint uVar5; int iVar6; long lVar7; int1 *puVar8; ulong uVar9; int1 *puVar10; byte *local_48; byte *local_40; long *local_38; local_38 = (long *)param_2; puVar10 = param_1; do { pbVar3 = *param_2; pbVar1 = pbVar3 + 1; local_48 = pbVar1; bVar2 = *pbVar3; uVar9 = (ulong)bVar2; if (bVar2 == 0x5c) { if (*pbVar1 != 0x75) { return 0xffffffffffffffff; } uVar4 = lre_parse_escape(&local_48,2); uVar9 = (ulong)uVar4; if ((int)uVar4 < 0) { return 0xffffffffffffffff; } } else { if (bVar2 == 0x3e) { if (puVar10 != param_1) { *puVar10 = 0; *local_38 = (long)pbVar1; return 0; } return 0xffffffffffffffff; } if ((char)bVar2 < '\0') { uVar4 = utf8_decode(pbVar3,&local_40); if (local_40 == pbVar1) { return 0xffffffffffffffff; } uVar9 = (ulong)uVar4; local_48 = local_40; if (((uVar4 & 0xfffffc00) == 0xd800) && (uVar5 = utf8_decode(local_40,&local_40), (uVar5 & 0xfffffc00) == 0xdc00)) { uVar9 = (ulong)((uVar4 & 0x3ff) * 0x400 + (uVar5 & 0x3ff) + 0x10000); local_48 = local_40; } } } uVar4 = (uint)uVar9; if (puVar10 == param_1) { if (uVar4 < 0x80) { puVar8 = lre_id_start_table_ascii; goto LAB_0017e40b; } uVar5 = lre_is_id_start(uVar9); } else if (uVar4 < 0x80) { puVar8 = lre_id_continue_table_ascii; LAB_0017e40b: uVar5 = (uint)((*(uint *)(puVar8 + (uVar9 >> 5) * 4) >> (uVar4 & 0x1f) & 1) != 0); } else { iVar6 = lre_is_id_continue(uVar9); uVar5 = (uint)((uVar4 & 0xfffffffe) == 0x200c || iVar6 != 0); } if (uVar5 == 0) { return 0xffffffffffffffff; } if (0x7b < (long)puVar10 - (long)param_1) { return 0xffffffffffffffff; } if (uVar4 < 0x80) { *puVar10 = (char)uVar9; puVar10 = puVar10 + 1; param_2 = &local_48; } else { lVar7 = utf8_encode(puVar10,uVar9); puVar10 = puVar10 + lVar7; param_2 = &local_48; } } while( true ); }
31,834
common_log::common_log(unsigned long)
monkey531[P]llama/common/log.cpp
common_log(size_t capacity) { file = nullptr; prefix = false; timestamps = false; running = false; t_start = t_us(); // initial message size - will be expanded if longer messages arrive entries.resize(capacity); for (auto & entry : entries) { entry.msg.resize(256); } head = 0; tail = 0; resume(); }
O2
cpp
common_log::common_log(unsigned long): pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx movq %rsi, %r12 movq %rdi, %rbx leaq 0x30(%rdi), %r14 xorps %xmm0, %xmm0 movups %xmm0, 0x20(%rdi) movups %xmm0, 0x10(%rdi) movups %xmm0, (%rdi) movq %r14, %rdi callq 0x23c90 andq $0x0, 0x88(%rbx) xorps %xmm0, %xmm0 movups %xmm0, 0x78(%rbx) andq $0x0, 0xc0(%rbx) movups %xmm0, 0xb0(%rbx) andq $0x0, 0x60(%rbx) leaq 0x78(%rbx), %r15 andl $0x0, 0x67(%rbx) callq 0x967be movq %rax, 0x70(%rbx) movq %r15, %rdi movq %r12, %rsi callq 0x96d5c movq 0x78(%rbx), %r12 movq 0x80(%rbx), %r13 cmpq %r13, %r12 je 0x96d0b addq $0x10, %r12 movl $0x100, %esi # imm = 0x100 movq %r12, %rdi callq 0x5c54e addq $0x20, %r12 jmp 0x96cef xorps %xmm0, %xmm0 movups %xmm0, 0x90(%rbx) movq %rbx, %rdi callq 0x968a0 popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 retq jmp 0x96d29 movq %rax, %r12 leaq 0xb0(%rbx), %rdi addq $0x28, %rbx callq 0x3efe0 movq %r15, %rdi callq 0x96d92 movq %r14, %rdi callq 0x24040 movq %rbx, %rdi callq 0x96db4 movq %r12, %rdi callq 0x23fc0
_ZN10common_logC2Em: push r15 push r14 push r13 push r12 push rbx mov r12, rsi mov rbx, rdi lea r14, [rdi+30h] xorps xmm0, xmm0 movups xmmword ptr [rdi+20h], xmm0 movups xmmword ptr [rdi+10h], xmm0 movups xmmword ptr [rdi], xmm0 mov rdi, r14; this call __ZNSt18condition_variableC1Ev; std::condition_variable::condition_variable(void) and qword ptr [rbx+88h], 0 xorps xmm0, xmm0 movups xmmword ptr [rbx+78h], xmm0 and qword ptr [rbx+0C0h], 0 movups xmmword ptr [rbx+0B0h], xmm0 and qword ptr [rbx+60h], 0 lea r15, [rbx+78h] and dword ptr [rbx+67h], 0 call _ZL4t_usv; t_us(void) mov [rbx+70h], rax mov rdi, r15 mov rsi, r12 call _ZNSt6vectorI16common_log_entrySaIS0_EE6resizeEm; std::vector<common_log_entry>::resize(ulong) mov r12, [rbx+78h] mov r13, [rbx+80h] loc_96CEF: cmp r12, r13 jz short loc_96D0B add r12, 10h mov esi, 100h mov rdi, r12 call _ZNSt6vectorIcSaIcEE6resizeEm; std::vector<char>::resize(ulong) add r12, 20h ; ' ' jmp short loc_96CEF loc_96D0B: xorps xmm0, xmm0 movups xmmword ptr [rbx+90h], xmm0 mov rdi, rbx; this call _ZN10common_log6resumeEv; common_log::resume(void) pop rbx pop r12 pop r13 pop r14 pop r15 retn jmp short $+2 loc_96D29: mov r12, rax lea rdi, [rbx+0B0h] add rbx, 28h ; '(' call _ZNSt12_Vector_baseIcSaIcEED2Ev; std::_Vector_base<char>::~_Vector_base() mov rdi, r15 call _ZNSt6vectorI16common_log_entrySaIS0_EED2Ev; std::vector<common_log_entry>::~vector() mov rdi, r14; this call __ZNSt18condition_variableD1Ev; std::condition_variable::~condition_variable() mov rdi, rbx; this call _ZNSt6threadD2Ev; std::thread::~thread() mov rdi, r12 call __Unwind_Resume
void common_log::common_log(common_log *this, long long a2) { std::condition_variable *v3; // rdi _QWORD *v4; // r12 _QWORD *v5; // r13 _QWORD *v6; // r12 *((_OWORD *)this + 2) = 0LL; *((_OWORD *)this + 1) = 0LL; *(_OWORD *)this = 0LL; v3 = (common_log *)((char *)this + 48); std::condition_variable::condition_variable(v3); *((_QWORD *)this + 17) = 0LL; *(_OWORD *)((char *)this + 120) = 0LL; *((_QWORD *)this + 24) = 0LL; *((_OWORD *)this + 11) = 0LL; *((_QWORD *)this + 12) = 0LL; *(_DWORD *)((char *)this + 103) = 0; *((_QWORD *)this + 14) = t_us(v3); std::vector<common_log_entry>::resize((char *)this + 120, a2); v4 = (_QWORD *)*((_QWORD *)this + 15); v5 = (_QWORD *)*((_QWORD *)this + 16); while ( v4 != v5 ) { v6 = v4 + 2; std::vector<char>::resize(v6, 0x100uLL); v4 = v6 + 4; } *((_OWORD *)this + 9) = 0LL; common_log::resume(this); }
common_log: PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX MOV R12,RSI MOV RBX,RDI LEA R14,[RDI + 0x30] XORPS XMM0,XMM0 MOVUPS xmmword ptr [RDI + 0x20],XMM0 MOVUPS xmmword ptr [RDI + 0x10],XMM0 MOVUPS xmmword ptr [RDI],XMM0 MOV RDI,R14 CALL 0x00123c90 AND qword ptr [RBX + 0x88],0x0 XORPS XMM0,XMM0 MOVUPS xmmword ptr [RBX + 0x78],XMM0 AND qword ptr [RBX + 0xc0],0x0 MOVUPS xmmword ptr [RBX + 0xb0],XMM0 AND qword ptr [RBX + 0x60],0x0 LEA R15,[RBX + 0x78] AND dword ptr [RBX + 0x67],0x0 CALL 0x001967be MOV qword ptr [RBX + 0x70],RAX LAB_00196cd9: MOV RDI,R15 MOV RSI,R12 CALL 0x00196d5c MOV R12,qword ptr [RBX + 0x78] MOV R13,qword ptr [RBX + 0x80] LAB_00196cef: CMP R12,R13 JZ 0x00196d0b ADD R12,0x10 LAB_00196cf8: MOV ESI,0x100 MOV RDI,R12 CALL 0x0015c54e ADD R12,0x20 JMP 0x00196cef LAB_00196d0b: XORPS XMM0,XMM0 MOVUPS xmmword ptr [RBX + 0x90],XMM0 LAB_00196d15: MOV RDI,RBX CALL 0x001968a0 LAB_00196d1d: POP RBX POP R12 POP R13 POP R14 POP R15 RET
/* common_log::common_log(unsigned long) */ void __thiscall common_log::common_log(common_log *this,ulong param_1) { long lVar1; int8 uVar2; long lVar3; *(int8 *)(this + 0x20) = 0; *(int8 *)(this + 0x28) = 0; *(int8 *)(this + 0x10) = 0; *(int8 *)(this + 0x18) = 0; *(int8 *)this = 0; *(int8 *)(this + 8) = 0; std::condition_variable::condition_variable((condition_variable *)(this + 0x30)); *(int8 *)(this + 0x88) = 0; *(int8 *)(this + 0x78) = 0; *(int8 *)(this + 0x80) = 0; *(int8 *)(this + 0xc0) = 0; *(int8 *)(this + 0xb0) = 0; *(int8 *)(this + 0xb8) = 0; *(int8 *)(this + 0x60) = 0; *(int4 *)(this + 0x67) = 0; uVar2 = t_us(); *(int8 *)(this + 0x70) = uVar2; /* try { // try from 00196cd9 to 00196ce3 has its CatchHandler @ 00196d27 */ std::vector<common_log_entry,std::allocator<common_log_entry>>::resize ((vector<common_log_entry,std::allocator<common_log_entry>> *)(this + 0x78),param_1); lVar1 = *(long *)(this + 0x80); for (lVar3 = *(long *)(this + 0x78); lVar3 != lVar1; lVar3 = lVar3 + 0x30) { /* try { // try from 00196cf8 to 00196d04 has its CatchHandler @ 00196d29 */ std::vector<char,std::allocator<char>>::resize ((vector<char,std::allocator<char>> *)(lVar3 + 0x10),0x100); } *(int8 *)(this + 0x90) = 0; *(int8 *)(this + 0x98) = 0; /* try { // try from 00196d15 to 00196d1c has its CatchHandler @ 00196d27 */ resume(this); return; }
31,835
common_log::common_log(unsigned long)
monkey531[P]llama/common/log.cpp
common_log(size_t capacity) { file = nullptr; prefix = false; timestamps = false; running = false; t_start = t_us(); // initial message size - will be expanded if longer messages arrive entries.resize(capacity); for (auto & entry : entries) { entry.msg.resize(256); } head = 0; tail = 0; resume(); }
O3
cpp
common_log::common_log(unsigned long): pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx movq %rsi, %r12 movq %rdi, %rbx leaq 0x30(%rdi), %r14 xorps %xmm0, %xmm0 movups %xmm0, 0x20(%rdi) movups %xmm0, 0x10(%rdi) movups %xmm0, (%rdi) movq %r14, %rdi callq 0x1ac60 leaq 0x78(%rbx), %r15 xorl %eax, %eax movq %rax, 0x88(%rbx) xorps %xmm0, %xmm0 movups %xmm0, 0x78(%rbx) movups %xmm0, 0xb0(%rbx) movq %rax, 0xc0(%rbx) movq %rax, 0x60(%rbx) movl $0x0, 0x67(%rbx) callq 0x1a0a0 movabsq $0x20c49ba5e353f7cf, %rcx # imm = 0x20C49BA5E353F7CF imulq %rcx movq %rdx, %rax shrq $0x3f, %rax sarq $0x7, %rdx addq %rax, %rdx movq %rdx, 0x70(%rbx) movq %r15, %rdi movq %r12, %rsi callq 0xcc3d8 movq 0x78(%rbx), %r12 movq 0x80(%rbx), %r13 cmpq %r13, %r12 je 0xcc374 leaq 0x10(%r12), %rdi movl $0x100, %esi # imm = 0x100 callq 0x7e754 addq $0x30, %r12 jmp 0xcc35a xorps %xmm0, %xmm0 movups %xmm0, 0x90(%rbx) movq %rbx, %rdi callq 0xcbdf6 popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 retq jmp 0xcc392 movq %rax, %r12 leaq 0xb0(%rbx), %rax movq (%rax), %rdi testq %rdi, %rdi je 0xcc3b3 movq 0xc0(%rbx), %rsi subq %rdi, %rsi callq 0x1a8d0 movq %r15, %rdi callq 0xcc41a movq %r14, %rdi callq 0x1b030 cmpq $0x0, 0x28(%rbx) jne 0xcc3d2 movq %r12, %rdi callq 0x1afc0 callq 0x1a220 nop
_ZN10common_logC2Em: push r15 push r14 push r13 push r12 push rbx mov r12, rsi mov rbx, rdi lea r14, [rdi+30h] xorps xmm0, xmm0 movups xmmword ptr [rdi+20h], xmm0 movups xmmword ptr [rdi+10h], xmm0 movups xmmword ptr [rdi], xmm0 mov rdi, r14; this call __ZNSt18condition_variableC1Ev; std::condition_variable::condition_variable(void) lea r15, [rbx+78h] xor eax, eax mov [rbx+88h], rax xorps xmm0, xmm0 movups xmmword ptr [rbx+78h], xmm0 movups xmmword ptr [rbx+0B0h], xmm0 mov [rbx+0C0h], rax mov [rbx+60h], rax mov dword ptr [rbx+67h], 0 call __ZNSt6chrono3_V212system_clock3nowEv; std::chrono::_V2::system_clock::now(void) mov rcx, 20C49BA5E353F7CFh imul rcx mov rax, rdx shr rax, 3Fh sar rdx, 7 add rdx, rax mov [rbx+70h], rdx mov rdi, r15 mov rsi, r12 call _ZNSt6vectorI16common_log_entrySaIS0_EE6resizeEm; std::vector<common_log_entry>::resize(ulong) mov r12, [rbx+78h] mov r13, [rbx+80h] loc_CC35A: cmp r12, r13 jz short loc_CC374 lea rdi, [r12+10h] mov esi, 100h call _ZNSt6vectorIcSaIcEE6resizeEm; std::vector<char>::resize(ulong) add r12, 30h ; '0' jmp short loc_CC35A loc_CC374: xorps xmm0, xmm0 movups xmmword ptr [rbx+90h], xmm0 mov rdi, rbx; this call _ZN10common_log6resumeEv; common_log::resume(void) pop rbx pop r12 pop r13 pop r14 pop r15 retn jmp short $+2 loc_CC392: mov r12, rax lea rax, [rbx+0B0h] mov rdi, [rax]; void * test rdi, rdi jz short loc_CC3B3 mov rsi, [rbx+0C0h] sub rsi, rdi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_CC3B3: mov rdi, r15 call _ZNSt6vectorI16common_log_entrySaIS0_EED2Ev; std::vector<common_log_entry>::~vector() mov rdi, r14; this call __ZNSt18condition_variableD1Ev; std::condition_variable::~condition_variable() cmp qword ptr [rbx+28h], 0 jnz short loc_CC3D2 mov rdi, r12 call __Unwind_Resume loc_CC3D2: call __ZSt9terminatev; std::terminate(void)
void common_log::common_log(common_log *this, long long a2) { std::condition_variable *v3; // rdi long long v4; // r12 long long v5; // r13 *((_OWORD *)this + 2) = 0LL; *((_OWORD *)this + 1) = 0LL; *(_OWORD *)this = 0LL; v3 = (common_log *)((char *)this + 48); std::condition_variable::condition_variable(v3); *((_QWORD *)this + 17) = 0LL; *(_OWORD *)((char *)this + 120) = 0LL; *((_OWORD *)this + 11) = 0LL; *((_QWORD *)this + 24) = 0LL; *((_QWORD *)this + 12) = 0LL; *(_DWORD *)((char *)this + 103) = 0; *((_QWORD *)this + 14) = std::chrono::_V2::system_clock::now(v3) / 1000LL; std::vector<common_log_entry>::resize((char *)this + 120, a2); v4 = *((_QWORD *)this + 15); v5 = *((_QWORD *)this + 16); while ( v4 != v5 ) { std::vector<char>::resize((_QWORD *)(v4 + 16), 0x100uLL); v4 += 48LL; } *((_OWORD *)this + 9) = 0LL; common_log::resume(this); }
common_log: PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX MOV R12,RSI MOV RBX,RDI LEA R14,[RDI + 0x30] XORPS XMM0,XMM0 MOVUPS xmmword ptr [RDI + 0x20],XMM0 MOVUPS xmmword ptr [RDI + 0x10],XMM0 MOVUPS xmmword ptr [RDI],XMM0 MOV RDI,R14 CALL 0x0011ac60 LEA R15,[RBX + 0x78] XOR EAX,EAX MOV qword ptr [RBX + 0x88],RAX XORPS XMM0,XMM0 MOVUPS xmmword ptr [RBX + 0x78],XMM0 MOVUPS xmmword ptr [RBX + 0xb0],XMM0 MOV qword ptr [RBX + 0xc0],RAX MOV qword ptr [RBX + 0x60],RAX MOV dword ptr [RBX + 0x67],0x0 CALL 0x0011a0a0 MOV RCX,0x20c49ba5e353f7cf IMUL RCX MOV RAX,RDX SHR RAX,0x3f SAR RDX,0x7 ADD RDX,RAX MOV qword ptr [RBX + 0x70],RDX LAB_001cc344: MOV RDI,R15 MOV RSI,R12 CALL 0x001cc3d8 MOV R12,qword ptr [RBX + 0x78] MOV R13,qword ptr [RBX + 0x80] LAB_001cc35a: CMP R12,R13 JZ 0x001cc374 LEA RDI,[R12 + 0x10] LAB_001cc364: MOV ESI,0x100 CALL 0x0017e754 ADD R12,0x30 JMP 0x001cc35a LAB_001cc374: XORPS XMM0,XMM0 MOVUPS xmmword ptr [RBX + 0x90],XMM0 LAB_001cc37e: MOV RDI,RBX CALL 0x001cbdf6 LAB_001cc386: POP RBX POP R12 POP R13 POP R14 POP R15 RET
/* common_log::common_log(unsigned long) */ void __thiscall common_log::common_log(common_log *this,ulong param_1) { long lVar1; long lVar2; *(int8 *)(this + 0x20) = 0; *(int8 *)(this + 0x28) = 0; *(int8 *)(this + 0x10) = 0; *(int8 *)(this + 0x18) = 0; *(int8 *)this = 0; *(int8 *)(this + 8) = 0; std::condition_variable::condition_variable((condition_variable *)(this + 0x30)); *(int8 *)(this + 0x88) = 0; *(int8 *)(this + 0x78) = 0; *(int8 *)(this + 0x80) = 0; *(int8 *)(this + 0xb0) = 0; *(int8 *)(this + 0xb8) = 0; *(int8 *)(this + 0xc0) = 0; *(int8 *)(this + 0x60) = 0; *(int4 *)(this + 0x67) = 0; lVar2 = std::chrono::_V2::system_clock::now(); *(long *)(this + 0x70) = lVar2 / 1000; /* try { // try from 001cc344 to 001cc34e has its CatchHandler @ 001cc390 */ std::vector<common_log_entry,std::allocator<common_log_entry>>::resize ((vector<common_log_entry,std::allocator<common_log_entry>> *)(this + 0x78),param_1); lVar1 = *(long *)(this + 0x80); for (lVar2 = *(long *)(this + 0x78); lVar2 != lVar1; lVar2 = lVar2 + 0x30) { /* try { // try from 001cc364 to 001cc36d has its CatchHandler @ 001cc392 */ std::vector<char,std::allocator<char>>::resize ((vector<char,std::allocator<char>> *)(lVar2 + 0x10),0x100); } *(int8 *)(this + 0x90) = 0; *(int8 *)(this + 0x98) = 0; /* try { // try from 001cc37e to 001cc385 has its CatchHandler @ 001cc390 */ resume(this); return; }
31,836
js_iterator_proto_set_toStringTag
bluesky950520[P]quickjs/quickjs.c
static JSValue js_iterator_proto_set_toStringTag(JSContext *ctx, JSValue this_val, JSValue val) { int res; if (check_iterator(ctx, this_val) < 0) return JS_EXCEPTION; if (js_same_value(ctx, this_val, ctx->class_proto[JS_CLASS_ITERATOR])) return JS_ThrowTypeError(ctx, "Cannot assign to read only property"); res = JS_GetOwnProperty(ctx, NULL, this_val, JS_ATOM_Symbol_toStringTag); if (res < 0) return JS_EXCEPTION; if (res) { if (JS_SetProperty(ctx, this_val, JS_ATOM_Symbol_toStringTag, js_dup(val)) < 0) return JS_EXCEPTION; } else { if (JS_DefinePropertyValue(ctx, this_val, JS_ATOM_Symbol_toStringTag, js_dup(val), JS_PROP_C_W_E) < 0) return JS_EXCEPTION; } return JS_UNDEFINED; }
O0
c
js_iterator_proto_set_toStringTag: subq $0x78, %rsp movq %rsi, 0x58(%rsp) movq %rdx, 0x60(%rsp) movq %rcx, 0x48(%rsp) movq %r8, 0x50(%rsp) movq %rdi, 0x40(%rsp) movq 0x40(%rsp), %rdi movq 0x58(%rsp), %rsi movq 0x60(%rsp), %rdx callq 0xc54b0 cmpl $0x0, %eax jge 0xc532c movl $0x0, 0x68(%rsp) movq $0x6, 0x70(%rsp) jmp 0xc549c movq 0x40(%rsp), %rdi movq 0x40(%rsp), %rax movq 0x40(%rax), %rax movq 0x58(%rsp), %rsi movq 0x60(%rsp), %rdx movq 0x270(%rax), %rcx movq 0x278(%rax), %r8 callq 0x35b10 cmpl $0x0, %eax je 0xc537e movq 0x40(%rsp), %rdi leaq 0x4b92f(%rip), %rsi # 0x110c97 movb $0x0, %al callq 0x2d300 movq %rax, 0x68(%rsp) movq %rdx, 0x70(%rsp) jmp 0xc549c movq 0x40(%rsp), %rdi movq 0x58(%rsp), %rdx movq 0x60(%rsp), %rcx xorl %eax, %eax movl %eax, %esi movl $0xda, %r8d callq 0x30150 movl %eax, 0x3c(%rsp) cmpl $0x0, 0x3c(%rsp) jge 0xc53bd movl $0x0, 0x68(%rsp) movq $0x6, 0x70(%rsp) jmp 0xc549c cmpl $0x0, 0x3c(%rsp) je 0xc5424 movq 0x40(%rsp), %rax movq %rax, 0x10(%rsp) movq 0x48(%rsp), %rdi movq 0x50(%rsp), %rsi callq 0x216d0 movq 0x10(%rsp), %rdi movq %rax, 0x28(%rsp) movq %rdx, 0x30(%rsp) movq 0x58(%rsp), %rsi movq 0x60(%rsp), %rdx movq 0x28(%rsp), %r8 movq 0x30(%rsp), %r9 movl $0xda, %ecx callq 0x31f00 cmpl $0x0, %eax jge 0xc5422 movl $0x0, 0x68(%rsp) movq $0x6, 0x70(%rsp) jmp 0xc549c jmp 0xc548b movq 0x40(%rsp), %rax movq %rax, 0x8(%rsp) movq 0x48(%rsp), %rdi movq 0x50(%rsp), %rsi callq 0x216d0 movq 0x8(%rsp), %rdi movq %rax, 0x18(%rsp) movq %rdx, 0x20(%rsp) movq 0x58(%rsp), %rsi movq 0x60(%rsp), %rdx movq 0x18(%rsp), %r8 movq 0x20(%rsp), %r9 movl $0xda, %ecx movl $0x7, (%rsp) callq 0x371b0 cmpl $0x0, %eax jge 0xc5489 movl $0x0, 0x68(%rsp) movq $0x6, 0x70(%rsp) jmp 0xc549c jmp 0xc548b movl $0x0, 0x68(%rsp) movq $0x3, 0x70(%rsp) movq 0x68(%rsp), %rax movq 0x70(%rsp), %rdx addq $0x78, %rsp retq nopl (%rax,%rax)
js_iterator_proto_set_toStringTag: sub rsp, 78h mov [rsp+78h+var_20], rsi mov [rsp+78h+var_18], rdx mov [rsp+78h+var_30], rcx mov [rsp+78h+var_28], r8 mov [rsp+78h+var_38], rdi mov rdi, [rsp+78h+var_38] mov rsi, [rsp+78h+var_20] mov rdx, [rsp+78h+var_18] call check_iterator cmp eax, 0 jge short loc_C532C mov dword ptr [rsp+78h+var_10], 0 mov [rsp+78h+var_8], 6 jmp loc_C549C loc_C532C: mov rdi, [rsp+78h+var_38] mov rax, [rsp+78h+var_38] mov rax, [rax+40h] mov rsi, [rsp+78h+var_20] mov rdx, [rsp+78h+var_18] mov rcx, [rax+270h] mov r8, [rax+278h] call js_same_value cmp eax, 0 jz short loc_C537E mov rdi, [rsp+78h+var_38] lea rsi, aCannotAssignTo; "Cannot assign to read only property" mov al, 0 call JS_ThrowTypeError mov [rsp+78h+var_10], rax mov [rsp+78h+var_8], rdx jmp loc_C549C loc_C537E: mov rdi, [rsp+78h+var_38] mov rdx, [rsp+78h+var_20] mov rcx, [rsp+78h+var_18] xor eax, eax mov esi, eax mov r8d, 0DAh call JS_GetOwnProperty mov [rsp+78h+var_3C], eax cmp [rsp+78h+var_3C], 0 jge short loc_C53BD mov dword ptr [rsp+78h+var_10], 0 mov [rsp+78h+var_8], 6 jmp loc_C549C loc_C53BD: cmp [rsp+78h+var_3C], 0 jz short loc_C5424 mov rax, [rsp+78h+var_38] mov [rsp+78h+var_68], rax mov rdi, [rsp+78h+var_30] mov rsi, [rsp+78h+var_28] call js_dup mov rdi, [rsp+78h+var_68] mov [rsp+78h+var_50], rax mov [rsp+78h+var_48], rdx mov rsi, [rsp+78h+var_20] mov rdx, [rsp+78h+var_18] mov r8, [rsp+78h+var_50] mov r9, [rsp+78h+var_48] mov ecx, 0DAh call JS_SetProperty cmp eax, 0 jge short loc_C5422 mov dword ptr [rsp+78h+var_10], 0 mov [rsp+78h+var_8], 6 jmp short loc_C549C loc_C5422: jmp short loc_C548B loc_C5424: mov rax, [rsp+78h+var_38] mov [rsp+78h+var_70], rax mov rdi, [rsp+78h+var_30] mov rsi, [rsp+78h+var_28] call js_dup mov rdi, [rsp+78h+var_70] mov [rsp+78h+var_60], rax mov [rsp+78h+var_58], rdx mov rsi, [rsp+78h+var_20] mov rdx, [rsp+78h+var_18] mov r8, [rsp+78h+var_60] mov r9, [rsp+78h+var_58] mov ecx, 0DAh mov [rsp+78h+var_78], 7 call JS_DefinePropertyValue cmp eax, 0 jge short loc_C5489 mov dword ptr [rsp+78h+var_10], 0 mov [rsp+78h+var_8], 6 jmp short loc_C549C loc_C5489: jmp short $+2 loc_C548B: mov dword ptr [rsp+78h+var_10], 0 mov [rsp+78h+var_8], 3 loc_C549C: mov rax, [rsp+78h+var_10] mov rdx, [rsp+78h+var_8] add rsp, 78h retn
long long js_iterator_proto_set_toStringTag( long long a1, _DWORD *a2, long long a3, _DWORD *a4, unsigned int a5, __m128 a6, __m128 a7, __m128 a8, __m128 a9, double a10, double a11, __m128 a12, __m128 a13) { long long v13; // rdx long long v14; // rcx long long v15; // r8 long long v16; // r9 __m128 v17; // xmm4 __m128 v18; // xmm5 int v19; // edx long long v20; // rdx __m128 v21; // xmm4 __m128 v22; // xmm5 char v24; // [rsp+0h] [rbp-78h] _DWORD *v25; // [rsp+18h] [rbp-60h] int v26; // [rsp+28h] [rbp-50h] int OwnProperty; // [rsp+3Ch] [rbp-3Ch] long long v31; // [rsp+68h] [rbp-10h] if ( (int)check_iterator(a1, a2, a3) >= 0 ) { if ( (unsigned int)js_same_value( a1, a2, a3, *(_DWORD **)(*(_QWORD *)(a1 + 64) + 624LL), *(_QWORD *)(*(_QWORD *)(a1 + 64) + 632LL)) ) { return JS_ThrowTypeError( a1, (long long)"Cannot assign to read only property", v13, v14, v15, v16, a6, a7, a8, a9, v17, v18, a12, a13, v24); } else { OwnProperty = JS_GetOwnProperty(a1, 0LL, (long long)a2, a3, 218LL, v16, a6, a7, a8, a9, v17, v18, a12, a13); if ( OwnProperty >= 0 ) { if ( OwnProperty ) { v26 = (unsigned int)js_dup(a4, a5); if ( (int)JS_SetProperty(a1, (int)a2, a3, 218, v26, v19) < 0 ) { LODWORD(v31) = 0; return v31; } } else { v25 = js_dup(a4, a5); if ( (int)JS_DefinePropertyValue(a1, (long long)a2, a3, 0xDAu, v25, v20, a6, a7, a8, a9, v21, v22, a12, a13, 7) < 0 ) { LODWORD(v31) = 0; return v31; } } LODWORD(v31) = 0; return v31; } LODWORD(v31) = 0; } } else { LODWORD(v31) = 0; } return v31; }
js_iterator_proto_set_toStringTag: SUB RSP,0x78 MOV qword ptr [RSP + 0x58],RSI MOV qword ptr [RSP + 0x60],RDX MOV qword ptr [RSP + 0x48],RCX MOV qword ptr [RSP + 0x50],R8 MOV qword ptr [RSP + 0x40],RDI MOV RDI,qword ptr [RSP + 0x40] MOV RSI,qword ptr [RSP + 0x58] MOV RDX,qword ptr [RSP + 0x60] CALL 0x001c54b0 CMP EAX,0x0 JGE 0x001c532c MOV dword ptr [RSP + 0x68],0x0 MOV qword ptr [RSP + 0x70],0x6 JMP 0x001c549c LAB_001c532c: MOV RDI,qword ptr [RSP + 0x40] MOV RAX,qword ptr [RSP + 0x40] MOV RAX,qword ptr [RAX + 0x40] MOV RSI,qword ptr [RSP + 0x58] MOV RDX,qword ptr [RSP + 0x60] MOV RCX,qword ptr [RAX + 0x270] MOV R8,qword ptr [RAX + 0x278] CALL 0x00135b10 CMP EAX,0x0 JZ 0x001c537e MOV RDI,qword ptr [RSP + 0x40] LEA RSI,[0x210c97] MOV AL,0x0 CALL 0x0012d300 MOV qword ptr [RSP + 0x68],RAX MOV qword ptr [RSP + 0x70],RDX JMP 0x001c549c LAB_001c537e: MOV RDI,qword ptr [RSP + 0x40] MOV RDX,qword ptr [RSP + 0x58] MOV RCX,qword ptr [RSP + 0x60] XOR EAX,EAX MOV ESI,EAX MOV R8D,0xda CALL 0x00130150 MOV dword ptr [RSP + 0x3c],EAX CMP dword ptr [RSP + 0x3c],0x0 JGE 0x001c53bd MOV dword ptr [RSP + 0x68],0x0 MOV qword ptr [RSP + 0x70],0x6 JMP 0x001c549c LAB_001c53bd: CMP dword ptr [RSP + 0x3c],0x0 JZ 0x001c5424 MOV RAX,qword ptr [RSP + 0x40] MOV qword ptr [RSP + 0x10],RAX MOV RDI,qword ptr [RSP + 0x48] MOV RSI,qword ptr [RSP + 0x50] CALL 0x001216d0 MOV RDI,qword ptr [RSP + 0x10] MOV qword ptr [RSP + 0x28],RAX MOV qword ptr [RSP + 0x30],RDX MOV RSI,qword ptr [RSP + 0x58] MOV RDX,qword ptr [RSP + 0x60] MOV R8,qword ptr [RSP + 0x28] MOV R9,qword ptr [RSP + 0x30] MOV ECX,0xda CALL 0x00131f00 CMP EAX,0x0 JGE 0x001c5422 MOV dword ptr [RSP + 0x68],0x0 MOV qword ptr [RSP + 0x70],0x6 JMP 0x001c549c LAB_001c5422: JMP 0x001c548b LAB_001c5424: MOV RAX,qword ptr [RSP + 0x40] MOV qword ptr [RSP + 0x8],RAX MOV RDI,qword ptr [RSP + 0x48] MOV RSI,qword ptr [RSP + 0x50] CALL 0x001216d0 MOV RDI,qword ptr [RSP + 0x8] MOV qword ptr [RSP + 0x18],RAX MOV qword ptr [RSP + 0x20],RDX MOV RSI,qword ptr [RSP + 0x58] MOV RDX,qword ptr [RSP + 0x60] MOV R8,qword ptr [RSP + 0x18] MOV R9,qword ptr [RSP + 0x20] MOV ECX,0xda MOV dword ptr [RSP],0x7 CALL 0x001371b0 CMP EAX,0x0 JGE 0x001c5489 MOV dword ptr [RSP + 0x68],0x0 MOV qword ptr [RSP + 0x70],0x6 JMP 0x001c549c LAB_001c5489: JMP 0x001c548b LAB_001c548b: MOV dword ptr [RSP + 0x68],0x0 MOV qword ptr [RSP + 0x70],0x3 LAB_001c549c: MOV RAX,qword ptr [RSP + 0x68] MOV RDX,qword ptr [RSP + 0x70] ADD RSP,0x78 RET
int1 [16] js_iterator_proto_set_toStringTag (long param_1,int8 param_2,int8 param_3,int8 param_4,int8 param_5) { int iVar1; int1 auVar2 [16]; int4 local_10; int4 uStack_c; int8 local_8; iVar1 = check_iterator(param_1,param_2,param_3); if (iVar1 < 0) { local_10 = 0; local_8 = 6; } else { iVar1 = js_same_value(param_1,param_2,param_3,*(int8 *)(*(long *)(param_1 + 0x40) + 0x270) ,*(int8 *)(*(long *)(param_1 + 0x40) + 0x278)); if (iVar1 == 0) { iVar1 = JS_GetOwnProperty(param_1,0,param_2,param_3,0xda); if (iVar1 < 0) { local_10 = 0; local_8 = 6; } else { if (iVar1 == 0) { auVar2 = js_dup(param_4,param_5); iVar1 = JS_DefinePropertyValue(param_1,param_2,param_3,0xda,auVar2._0_8_,auVar2._8_8_,7); if (iVar1 < 0) { local_10 = 0; local_8 = 6; goto LAB_001c549c; } } else { auVar2 = js_dup(param_4,param_5); iVar1 = JS_SetProperty(param_1,param_2,param_3,0xda,auVar2._0_8_,auVar2._8_8_); if (iVar1 < 0) { local_10 = 0; local_8 = 6; goto LAB_001c549c; } } local_10 = 0; local_8 = 3; } } else { auVar2 = JS_ThrowTypeError(param_1,"Cannot assign to read only property"); local_8 = auVar2._8_8_; local_10 = auVar2._0_4_; uStack_c = auVar2._4_4_; } } LAB_001c549c: auVar2._4_4_ = uStack_c; auVar2._0_4_ = local_10; auVar2._8_8_ = local_8; return auVar2; }
31,837
js_iterator_proto_set_toStringTag
bluesky950520[P]quickjs/quickjs.c
static JSValue js_iterator_proto_set_toStringTag(JSContext *ctx, JSValue this_val, JSValue val) { int res; if (check_iterator(ctx, this_val) < 0) return JS_EXCEPTION; if (js_same_value(ctx, this_val, ctx->class_proto[JS_CLASS_ITERATOR])) return JS_ThrowTypeError(ctx, "Cannot assign to read only property"); res = JS_GetOwnProperty(ctx, NULL, this_val, JS_ATOM_Symbol_toStringTag); if (res < 0) return JS_EXCEPTION; if (res) { if (JS_SetProperty(ctx, this_val, JS_ATOM_Symbol_toStringTag, js_dup(val)) < 0) return JS_EXCEPTION; } else { if (JS_DefinePropertyValue(ctx, this_val, JS_ATOM_Symbol_toStringTag, js_dup(val), JS_PROP_C_W_E) < 0) return JS_EXCEPTION; } return JS_UNDEFINED; }
O1
c
js_iterator_proto_set_toStringTag: pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x38, %rsp movq %rdx, %r13 movq %rdi, %r15 cmpl $-0x1, %r13d jne 0x730fd movq %r8, %rbx movq %rcx, %r14 movq %rsi, %rbp movq 0x40(%r15), %rax movq 0x270(%rax), %rcx movq 0x278(%rax), %r8 movq %r15, %rdi movq %r13, %rdx callq 0x26461 testl %eax, %eax je 0x73128 leaq 0x2eb21(%rip), %rsi # 0xa1c1c jmp 0x73104 leaq 0x2bf21(%rip), %rsi # 0x9f025 movq %r15, %rdi xorl %eax, %eax callq 0x22567 movl $0x6, %r12d xorl %eax, %eax movq %r12, %rdx addq $0x38, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq movq %r15, %rdi xorl %esi, %esi movq %rbp, %rdx movq %r13, %rcx movl $0xda, %r8d callq 0x23bb0 movl $0x6, %r12d testl %eax, %eax js 0x73114 je 0x7319a movq %r14, 0x28(%rsp) cmpl $-0x9, %ebx jb 0x7315b movq 0x28(%rsp), %rax incl (%rax) movq %rbp, 0x28(%rsp) movq %r13, 0x30(%rsp) movups 0x28(%rsp), %xmm0 movups %xmm0, (%rsp) movq $0x0, 0x18(%rsp) movl $0x4000, 0x10(%rsp) # imm = 0x4000 movq %r15, %rdi movq %rbp, %rsi movq %r13, %rdx movl $0xda, %ecx movq %r14, %r8 movq %rbx, %r9 callq 0x24388 jmp 0x731cb movq %r14, 0x28(%rsp) cmpl $-0x9, %ebx jb 0x731ab movq 0x28(%rsp), %rax incl (%rax) movl $0x7, (%rsp) movq %r15, %rdi movq %rbp, %rsi movq %r13, %rdx movl $0xda, %ecx movq %r14, %r8 movq %rbx, %r9 callq 0x26abb testl %eax, %eax js 0x73114 movl $0x3, %r12d jmp 0x73114
js_iterator_proto_set_toStringTag: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 38h mov r13, rdx mov r15, rdi cmp r13d, 0FFFFFFFFh jnz short loc_730FD mov rbx, r8 mov r14, rcx mov rbp, rsi mov rax, [r15+40h] mov rcx, [rax+270h] mov r8, [rax+278h] mov rdi, r15 mov rdx, r13 call js_same_value test eax, eax jz short loc_73128 lea rsi, aCannotAssignTo; "Cannot assign to read only property" jmp short loc_73104 loc_730FD: lea rsi, aOperandPrototy+20h; "not an object" loc_73104: mov rdi, r15 xor eax, eax call JS_ThrowTypeError mov r12d, 6 loc_73114: xor eax, eax mov rdx, r12 add rsp, 38h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn loc_73128: mov rdi, r15 xor esi, esi mov rdx, rbp mov rcx, r13 mov r8d, 0DAh call JS_GetOwnProperty mov r12d, 6 test eax, eax js short loc_73114 jz short loc_7319A mov qword ptr [rsp+68h+var_40], r14 cmp ebx, 0FFFFFFF7h jb short loc_7315B mov rax, qword ptr [rsp+68h+var_40] inc dword ptr [rax] loc_7315B: mov qword ptr [rsp+68h+var_40], rbp mov qword ptr [rsp+68h+var_40+8], r13 movups xmm0, [rsp+68h+var_40] movups [rsp+68h+var_68], xmm0 mov [rsp+68h+var_50], 0 mov [rsp+68h+var_58], 4000h mov rdi, r15 mov rsi, rbp mov rdx, r13 mov ecx, 0DAh mov r8, r14 mov r9, rbx call JS_SetPropertyInternal2 jmp short loc_731CB loc_7319A: mov qword ptr [rsp+68h+var_40], r14 cmp ebx, 0FFFFFFF7h jb short loc_731AB mov rax, qword ptr [rsp+68h+var_40] inc dword ptr [rax] loc_731AB: mov dword ptr [rsp+68h+var_68], 7 mov rdi, r15 mov rsi, rbp mov rdx, r13 mov ecx, 0DAh mov r8, r14 mov r9, rbx call JS_DefinePropertyValue loc_731CB: test eax, eax js loc_73114 mov r12d, 3 jmp loc_73114
long long js_iterator_proto_set_toStringTag( long long a1, _DWORD *a2, unsigned long long a3, _DWORD *a4, long long a5, long long a6, __m128 a7, __m128 a8, __m128 a9, __m128 a10, __m128 a11, __m128 a12, __m128 a13, __m128 a14) { char *v17; // rsi int OwnProperty; // eax __m128 v20; // xmm4 __m128 v21; // xmm5 char v22; // [rsp+0h] [rbp-68h] __m128 v23; // [rsp+28h] [rbp-40h] if ( (_DWORD)a3 != -1 ) { v17 = "not an object"; goto LABEL_5; } if ( (unsigned int)js_same_value( a1, a2, a3, *(_DWORD **)(*(_QWORD *)(a1 + 64) + 624LL), *(_QWORD *)(*(_QWORD *)(a1 + 64) + 632LL)) ) { v17 = "Cannot assign to read only property"; LABEL_5: JS_ThrowTypeError(a1, (long long)v17, a3, (long long)a4, a5, a6, a7, a8, a9, a10, a11, a12, a13, a14, v22); return 0LL; } OwnProperty = JS_GetOwnProperty(a1, 0LL, (long long)a2, a3, 218LL, a6, a7, a8, a9, a10, a11, a12, a13, a14); if ( OwnProperty >= 0 ) { if ( OwnProperty ) { if ( (unsigned int)a5 >= 0xFFFFFFF7 ) ++*a4; v23.m128_u64[0] = (unsigned long long)a2; v23.m128_u64[1] = a3; JS_SetPropertyInternal2( a1, (long long)a2, a3, 0xDAu, a4, a5, v23, a8, a9, a10, *(double *)v20.m128_u64, *(double *)v21.m128_u64, a13, a14, (long long)a2, a3, 0x4000u, 0LL); } else { if ( (unsigned int)a5 >= 0xFFFFFFF7 ) ++*a4; JS_DefinePropertyValue( a1, (unsigned long long)a2, a3, 218LL, a4, a5, *(double *)a7.m128_u64, a8, a9, a10, v20, v21, a13, a14, 7); } } return 0LL; }
31,838
js_iterator_proto_set_toStringTag
bluesky950520[P]quickjs/quickjs.c
static JSValue js_iterator_proto_set_toStringTag(JSContext *ctx, JSValue this_val, JSValue val) { int res; if (check_iterator(ctx, this_val) < 0) return JS_EXCEPTION; if (js_same_value(ctx, this_val, ctx->class_proto[JS_CLASS_ITERATOR])) return JS_ThrowTypeError(ctx, "Cannot assign to read only property"); res = JS_GetOwnProperty(ctx, NULL, this_val, JS_ATOM_Symbol_toStringTag); if (res < 0) return JS_EXCEPTION; if (res) { if (JS_SetProperty(ctx, this_val, JS_ATOM_Symbol_toStringTag, js_dup(val)) < 0) return JS_EXCEPTION; } else { if (JS_DefinePropertyValue(ctx, this_val, JS_ATOM_Symbol_toStringTag, js_dup(val), JS_PROP_C_W_E) < 0) return JS_EXCEPTION; } return JS_UNDEFINED; }
O2
c
js_iterator_proto_set_toStringTag: pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx pushq %rax movq %r8, %r14 movq %rcx, %r15 movq %rdx, %r12 movq %rsi, %rbp movq %rdi, %r13 movq %rdx, %rsi callq 0x60e07 pushq $0x6 popq %rbx testl %eax, %eax js 0x60d7a movq 0x40(%r13), %rax movq 0x270(%rax), %rcx movq 0x278(%rax), %r8 movq %r13, %rdi movq %rbp, %rsi movq %r12, %rdx callq 0x1ff32 testl %eax, %eax je 0x60d8e leaq 0x27de6(%rip), %rsi # 0x88b56 movq %r13, %rdi xorl %eax, %eax callq 0x1c64d xorl %eax, %eax movq %rbx, %rdx addq $0x8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq movq %r13, %rdi xorl %esi, %esi movq %rbp, %rdx movq %r12, %rcx movl $0xda, %r8d callq 0x1db6b testl %eax, %eax js 0x60d7a je 0x60dce cmpl $-0x9, %r14d jb 0x60db3 incl (%r15) movq %r13, %rdi movq %rbp, %rsi movq %r12, %rdx movl $0xda, %ecx movq %r15, %r8 movq %r14, %r9 callq 0x1e446 jmp 0x60df7 cmpl $-0x9, %r14d jb 0x60dd7 incl (%r15) movl $0x7, (%rsp) movq %r13, %rdi movq %rbp, %rsi movq %r12, %rdx movl $0xda, %ecx movq %r15, %r8 movq %r14, %r9 callq 0x20872 testl %eax, %eax js 0x60d7a pushq $0x3 popq %rbx jmp 0x60d7a
js_iterator_proto_set_toStringTag: push rbp push r15 push r14 push r13 push r12 push rbx push rax mov r14, r8 mov r15, rcx mov r12, rdx mov rbp, rsi mov r13, rdi mov rsi, rdx call check_iterator push 6 pop rbx test eax, eax js short loc_60D7A mov rax, [r13+40h] mov rcx, [rax+270h] mov r8, [rax+278h] mov rdi, r13 mov rsi, rbp mov rdx, r12 call js_same_value test eax, eax jz short loc_60D8E lea rsi, aCannotAssignTo; "Cannot assign to read only property" mov rdi, r13 xor eax, eax call JS_ThrowTypeError loc_60D7A: xor eax, eax mov rdx, rbx add rsp, 8 pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn loc_60D8E: mov rdi, r13 xor esi, esi mov rdx, rbp mov rcx, r12 mov r8d, 0DAh call JS_GetOwnProperty test eax, eax js short loc_60D7A jz short loc_60DCE cmp r14d, 0FFFFFFF7h jb short loc_60DB3 inc dword ptr [r15] loc_60DB3: mov rdi, r13 mov rsi, rbp mov rdx, r12 mov ecx, 0DAh mov r8, r15 mov r9, r14 call JS_SetProperty jmp short loc_60DF7 loc_60DCE: cmp r14d, 0FFFFFFF7h jb short loc_60DD7 inc dword ptr [r15] loc_60DD7: mov [rsp+38h+var_38], 7 mov rdi, r13 mov rsi, rbp mov rdx, r12 mov ecx, 0DAh mov r8, r15 mov r9, r14 call JS_DefinePropertyValue loc_60DF7: test eax, eax js loc_60D7A push 3 pop rbx jmp loc_60D7A
long long js_iterator_proto_set_toStringTag( long long a1, _DWORD *a2, long long a3, _DWORD *a4, long long a5, __m128 a6, __m128 a7, __m128 a8, __m128 a9, double a10, double a11, __m128 a12, __m128 a13) { char v13; // al long long v17; // rdx long long v18; // rcx long long v19; // r8 long long v20; // r9 __m128 v21; // xmm4 __m128 v22; // xmm5 int OwnProperty; // eax __m128 v25; // xmm4 __m128 v26; // xmm5 char v27; // [rsp+0h] [rbp-38h] v27 = v13; if ( (int)check_iterator(a1, a3) >= 0 ) { if ( (unsigned int)js_same_value( a1, a2, a3, *(_DWORD **)(*(_QWORD *)(a1 + 64) + 624LL), *(_QWORD *)(*(_QWORD *)(a1 + 64) + 632LL)) ) { JS_ThrowTypeError( a1, (long long)"Cannot assign to read only property", v17, v18, v19, v20, a6, a7, a8, a9, v21, v22, a12, a13, v27); } else { OwnProperty = JS_GetOwnProperty(a1, 0LL, (long long)a2, a3, 218LL, v20, a6, a7, a8, a9, v21, v22, a12, a13); if ( OwnProperty >= 0 ) { if ( OwnProperty ) { if ( (unsigned int)a5 >= 0xFFFFFFF7 ) ++*a4; JS_SetProperty(a1, (int)a2, a3, 218, (int)a4, a5); } else { if ( (unsigned int)a5 >= 0xFFFFFFF7 ) ++*a4; JS_DefinePropertyValue( a1, (long long)a2, a3, 218LL, a4, a5, *(double *)a6.m128_u64, a7, a8, a9, v25, v26, a12, a13, 7); } } } } return 0LL; }
js_iterator_proto_set_toStringTag: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX PUSH RAX MOV R14,R8 MOV R15,RCX MOV R12,RDX MOV RBP,RSI MOV R13,RDI MOV RSI,RDX CALL 0x00160e07 PUSH 0x6 POP RBX TEST EAX,EAX JS 0x00160d7a MOV RAX,qword ptr [R13 + 0x40] MOV RCX,qword ptr [RAX + 0x270] MOV R8,qword ptr [RAX + 0x278] MOV RDI,R13 MOV RSI,RBP MOV RDX,R12 CALL 0x0011ff32 TEST EAX,EAX JZ 0x00160d8e LEA RSI,[0x188b56] MOV RDI,R13 XOR EAX,EAX CALL 0x0011c64d LAB_00160d7a: XOR EAX,EAX MOV RDX,RBX ADD RSP,0x8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET LAB_00160d8e: MOV RDI,R13 XOR ESI,ESI MOV RDX,RBP MOV RCX,R12 MOV R8D,0xda CALL 0x0011db6b TEST EAX,EAX JS 0x00160d7a JZ 0x00160dce CMP R14D,-0x9 JC 0x00160db3 INC dword ptr [R15] LAB_00160db3: MOV RDI,R13 MOV RSI,RBP MOV RDX,R12 MOV ECX,0xda MOV R8,R15 MOV R9,R14 CALL 0x0011e446 JMP 0x00160df7 LAB_00160dce: CMP R14D,-0x9 JC 0x00160dd7 INC dword ptr [R15] LAB_00160dd7: MOV dword ptr [RSP],0x7 MOV RDI,R13 MOV RSI,RBP MOV RDX,R12 MOV ECX,0xda MOV R8,R15 MOV R9,R14 CALL 0x00120872 LAB_00160df7: TEST EAX,EAX JS 0x00160d7a PUSH 0x3 POP RBX JMP 0x00160d7a
int1 [16] js_iterator_proto_set_toStringTag (long param_1,int8 param_2,int8 param_3,int *param_4,int8 param_5) { int1 auVar1 [16]; int iVar2; int8 in_RAX; ulong uStackY_40; int4 uVar3; uVar3 = (int4)((ulong)in_RAX >> 0x20); iVar2 = check_iterator(param_1,param_3); uStackY_40 = 6; if (-1 < iVar2) { iVar2 = js_same_value(param_1,param_2,param_3,*(int8 *)(*(long *)(param_1 + 0x40) + 0x270) ,*(int8 *)(*(long *)(param_1 + 0x40) + 0x278)); if (iVar2 == 0) { iVar2 = JS_GetOwnProperty(param_1,0,param_2,param_3,0xda); if (-1 < iVar2) { if (iVar2 == 0) { if (0xfffffff6 < (uint)param_5) { *param_4 = *param_4 + 1; } iVar2 = JS_DefinePropertyValue (param_1,param_2,param_3,0xda,param_4,param_5,CONCAT44(uVar3,7)); } else { if (0xfffffff6 < (uint)param_5) { *param_4 = *param_4 + 1; } iVar2 = JS_SetProperty(param_1,param_2,param_3,0xda,param_4,param_5); } if (-1 < iVar2) { uStackY_40 = 3; } } } else { JS_ThrowTypeError(param_1,"Cannot assign to read only property"); } } auVar1._8_8_ = 0; auVar1._0_8_ = uStackY_40; return auVar1 << 0x40; }
31,839
crypto_sign_ed25519_ref10_ge_msub
eloqsql/plugin/auth_ed25519/ref10/ge_msub.c
void ge_msub(ge_p1p1 *r,const ge_p3 *p,const ge_precomp *q) { fe t0; #include "ge_msub.h" }
O0
c
crypto_sign_ed25519_ref10_ge_msub: pushq %rbp movq %rsp, %rbp subq $0x40, %rsp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq %rdx, -0x18(%rbp) movq -0x8(%rbp), %rdi movq -0x10(%rbp), %rsi addq $0x28, %rsi movq -0x10(%rbp), %rdx callq 0x8530 movq -0x8(%rbp), %rdi addq $0x28, %rdi movq -0x10(%rbp), %rsi addq $0x28, %rsi movq -0x10(%rbp), %rdx callq 0xbea0 movq -0x8(%rbp), %rdi addq $0x50, %rdi movq -0x8(%rbp), %rsi movq -0x18(%rbp), %rdx addq $0x28, %rdx callq 0x9300 movq -0x8(%rbp), %rdi addq $0x28, %rdi movq -0x8(%rbp), %rsi addq $0x28, %rsi movq -0x18(%rbp), %rdx callq 0x9300 movq -0x8(%rbp), %rdi addq $0x78, %rdi movq -0x18(%rbp), %rsi addq $0x50, %rsi movq -0x10(%rbp), %rdx addq $0x78, %rdx callq 0x9300 leaq -0x40(%rbp), %rdi movq -0x10(%rbp), %rsi addq $0x50, %rsi movq -0x10(%rbp), %rdx addq $0x50, %rdx callq 0x8530 movq -0x8(%rbp), %rdi movq -0x8(%rbp), %rsi addq $0x50, %rsi movq -0x8(%rbp), %rdx addq $0x28, %rdx callq 0xbea0 movq -0x8(%rbp), %rdi addq $0x28, %rdi movq -0x8(%rbp), %rsi addq $0x50, %rsi movq -0x8(%rbp), %rdx addq $0x28, %rdx callq 0x8530 movq -0x8(%rbp), %rdi addq $0x50, %rdi leaq -0x40(%rbp), %rsi movq -0x8(%rbp), %rdx addq $0x78, %rdx callq 0xbea0 movq -0x8(%rbp), %rdi addq $0x78, %rdi leaq -0x40(%rbp), %rsi movq -0x8(%rbp), %rdx addq $0x78, %rdx callq 0x8530 addq $0x40, %rsp popq %rbp retq nopl (%rax,%rax)
crypto_sign_ed25519_ref10_ge_msub: push rbp mov rbp, rsp sub rsp, 40h mov [rbp+var_8], rdi mov [rbp+var_10], rsi mov [rbp+var_18], rdx mov rdi, [rbp+var_8] mov rsi, [rbp+var_10] add rsi, 28h ; '(' mov rdx, [rbp+var_10] call crypto_sign_ed25519_ref10_fe_add mov rdi, [rbp+var_8] add rdi, 28h ; '(' mov rsi, [rbp+var_10] add rsi, 28h ; '(' mov rdx, [rbp+var_10] call crypto_sign_ed25519_ref10_fe_sub mov rdi, [rbp+var_8] add rdi, 50h ; 'P' mov rsi, [rbp+var_8] mov rdx, [rbp+var_18] add rdx, 28h ; '(' call crypto_sign_ed25519_ref10_fe_mul mov rdi, [rbp+var_8] add rdi, 28h ; '(' mov rsi, [rbp+var_8] add rsi, 28h ; '(' mov rdx, [rbp+var_18] call crypto_sign_ed25519_ref10_fe_mul mov rdi, [rbp+var_8] add rdi, 78h ; 'x' mov rsi, [rbp+var_18] add rsi, 50h ; 'P' mov rdx, [rbp+var_10] add rdx, 78h ; 'x' call crypto_sign_ed25519_ref10_fe_mul lea rdi, [rbp+var_40] mov rsi, [rbp+var_10] add rsi, 50h ; 'P' mov rdx, [rbp+var_10] add rdx, 50h ; 'P' call crypto_sign_ed25519_ref10_fe_add mov rdi, [rbp+var_8] mov rsi, [rbp+var_8] add rsi, 50h ; 'P' mov rdx, [rbp+var_8] add rdx, 28h ; '(' call crypto_sign_ed25519_ref10_fe_sub mov rdi, [rbp+var_8] add rdi, 28h ; '(' mov rsi, [rbp+var_8] add rsi, 50h ; 'P' mov rdx, [rbp+var_8] add rdx, 28h ; '(' call crypto_sign_ed25519_ref10_fe_add mov rdi, [rbp+var_8] add rdi, 50h ; 'P' lea rsi, [rbp+var_40] mov rdx, [rbp+var_8] add rdx, 78h ; 'x' call crypto_sign_ed25519_ref10_fe_sub mov rdi, [rbp+var_8] add rdi, 78h ; 'x' lea rsi, [rbp+var_40] mov rdx, [rbp+var_8] add rdx, 78h ; 'x' call crypto_sign_ed25519_ref10_fe_add add rsp, 40h pop rbp retn
long long crypto_sign_ed25519_ref10_ge_msub(long long a1, long long a2, long long a3) { _BYTE v4[40]; // [rsp+0h] [rbp-40h] BYREF long long v5; // [rsp+28h] [rbp-18h] long long v6; // [rsp+30h] [rbp-10h] long long v7; // [rsp+38h] [rbp-8h] v7 = a1; v6 = a2; v5 = a3; crypto_sign_ed25519_ref10_fe_add(a1, a2 + 40, a2); crypto_sign_ed25519_ref10_fe_sub(a1 + 40, v6 + 40, v6); crypto_sign_ed25519_ref10_fe_mul(v7 + 80, v7, v5 + 40); crypto_sign_ed25519_ref10_fe_mul(v7 + 40, v7 + 40, v5); crypto_sign_ed25519_ref10_fe_mul(a1 + 120, v5 + 80, a2 + 120); crypto_sign_ed25519_ref10_fe_add(v4, v6 + 80, v6 + 80); crypto_sign_ed25519_ref10_fe_sub(v7, v7 + 80, v7 + 40); crypto_sign_ed25519_ref10_fe_add(v7 + 40, v7 + 80, v7 + 40); crypto_sign_ed25519_ref10_fe_sub(v7 + 80, v4, v7 + 120); return crypto_sign_ed25519_ref10_fe_add(v7 + 120, v4, v7 + 120); }
crypto_sign_ed25519_ref10_ge_msub: PUSH RBP MOV RBP,RSP SUB RSP,0x40 MOV qword ptr [RBP + -0x8],RDI MOV qword ptr [RBP + -0x10],RSI MOV qword ptr [RBP + -0x18],RDX MOV RDI,qword ptr [RBP + -0x8] MOV RSI,qword ptr [RBP + -0x10] ADD RSI,0x28 MOV RDX,qword ptr [RBP + -0x10] CALL 0x00108530 MOV RDI,qword ptr [RBP + -0x8] ADD RDI,0x28 MOV RSI,qword ptr [RBP + -0x10] ADD RSI,0x28 MOV RDX,qword ptr [RBP + -0x10] CALL 0x0010bea0 MOV RDI,qword ptr [RBP + -0x8] ADD RDI,0x50 MOV RSI,qword ptr [RBP + -0x8] MOV RDX,qword ptr [RBP + -0x18] ADD RDX,0x28 CALL 0x00109300 MOV RDI,qword ptr [RBP + -0x8] ADD RDI,0x28 MOV RSI,qword ptr [RBP + -0x8] ADD RSI,0x28 MOV RDX,qword ptr [RBP + -0x18] CALL 0x00109300 MOV RDI,qword ptr [RBP + -0x8] ADD RDI,0x78 MOV RSI,qword ptr [RBP + -0x18] ADD RSI,0x50 MOV RDX,qword ptr [RBP + -0x10] ADD RDX,0x78 CALL 0x00109300 LEA RDI,[RBP + -0x40] MOV RSI,qword ptr [RBP + -0x10] ADD RSI,0x50 MOV RDX,qword ptr [RBP + -0x10] ADD RDX,0x50 CALL 0x00108530 MOV RDI,qword ptr [RBP + -0x8] MOV RSI,qword ptr [RBP + -0x8] ADD RSI,0x50 MOV RDX,qword ptr [RBP + -0x8] ADD RDX,0x28 CALL 0x0010bea0 MOV RDI,qword ptr [RBP + -0x8] ADD RDI,0x28 MOV RSI,qword ptr [RBP + -0x8] ADD RSI,0x50 MOV RDX,qword ptr [RBP + -0x8] ADD RDX,0x28 CALL 0x00108530 MOV RDI,qword ptr [RBP + -0x8] ADD RDI,0x50 LEA RSI,[RBP + -0x40] MOV RDX,qword ptr [RBP + -0x8] ADD RDX,0x78 CALL 0x0010bea0 MOV RDI,qword ptr [RBP + -0x8] ADD RDI,0x78 LEA RSI,[RBP + -0x40] MOV RDX,qword ptr [RBP + -0x8] ADD RDX,0x78 CALL 0x00108530 ADD RSP,0x40 POP RBP RET
void crypto_sign_ed25519_ref10_ge_msub(long param_1,long param_2,long param_3) { int1 local_48 [40]; long local_20; long local_18; long local_10; local_20 = param_3; local_18 = param_2; local_10 = param_1; crypto_sign_ed25519_ref10_fe_add(param_1,param_2 + 0x28,param_2); crypto_sign_ed25519_ref10_fe_sub(local_10 + 0x28,local_18 + 0x28,local_18); crypto_sign_ed25519_ref10_fe_mul(local_10 + 0x50,local_10,local_20 + 0x28); crypto_sign_ed25519_ref10_fe_mul(local_10 + 0x28,local_10 + 0x28,local_20); crypto_sign_ed25519_ref10_fe_mul(local_10 + 0x78,local_20 + 0x50,local_18 + 0x78); crypto_sign_ed25519_ref10_fe_add(local_48,local_18 + 0x50,local_18 + 0x50); crypto_sign_ed25519_ref10_fe_sub(local_10,local_10 + 0x50,local_10 + 0x28); crypto_sign_ed25519_ref10_fe_add(local_10 + 0x28,local_10 + 0x50,local_10 + 0x28); crypto_sign_ed25519_ref10_fe_sub(local_10 + 0x50,local_48,local_10 + 0x78); crypto_sign_ed25519_ref10_fe_add(local_10 + 0x78,local_48,local_10 + 0x78); return; }
31,840
madb_get_os_character_set
eloqsql/libmariadb/libmariadb/ma_charset.c
const char *madb_get_os_character_set() { unsigned int i= 0; char *p= NULL; #ifdef _WIN32 char codepage[FN_REFLEN]; snprintf(codepage, FN_REFLEN, "%u", GetConsoleCP() ? GetConsoleCP() : GetACP()); p= codepage; #elif defined(HAVE_NL_LANGINFO) && defined(HAVE_SETLOCALE) if (setlocale(LC_CTYPE, "")) p= nl_langinfo(CODESET); #endif if (!p) return MADB_DEFAULT_CHARSET_NAME; while (MADB_OS_CHARSET[i].identifier) { if (MADB_OS_CHARSET[i].supported > MADB_CS_UNSUPPORTED && strcasecmp(MADB_OS_CHARSET[i].identifier, p) == 0) return MADB_OS_CHARSET[i].charset; i++; } return MADB_DEFAULT_CHARSET_NAME; }
O0
c
madb_get_os_character_set: pushq %rbp movq %rsp, %rbp subq $0x20, %rsp movl $0x0, -0xc(%rbp) movq $0x0, -0x18(%rbp) xorl %edi, %edi leaq 0x348bb(%rip), %rsi # 0x4e8eb callq 0x133a0 cmpq $0x0, %rax je 0x1a049 movl $0xe, %edi callq 0x13410 movq %rax, -0x18(%rbp) cmpq $0x0, -0x18(%rbp) jne 0x1a060 leaq 0x34bcd(%rip), %rax # 0x4ec24 movq %rax, -0x8(%rbp) jmp 0x1a0f1 jmp 0x1a062 movl -0xc(%rbp), %eax movl %eax, %ecx leaq 0x48312(%rip), %rax # 0x62380 imulq $0x28, %rcx, %rcx addq %rcx, %rax cmpq $0x0, (%rax) je 0x1a0e6 movl -0xc(%rbp), %eax movl %eax, %ecx leaq 0x482f9(%rip), %rax # 0x62380 imulq $0x28, %rcx, %rcx addq %rcx, %rax movzbl 0x20(%rax), %eax cmpl $0x0, %eax jle 0x1a0d8 movl -0xc(%rbp), %eax movl %eax, %ecx leaq 0x482dd(%rip), %rax # 0x62380 imulq $0x28, %rcx, %rcx addq %rcx, %rax movq (%rax), %rdi movq -0x18(%rbp), %rsi callq 0x13480 cmpl $0x0, %eax jne 0x1a0d8 movl -0xc(%rbp), %eax movl %eax, %ecx leaq 0x482b9(%rip), %rax # 0x62380 imulq $0x28, %rcx, %rcx addq %rcx, %rax movq 0x10(%rax), %rax movq %rax, -0x8(%rbp) jmp 0x1a0f1 movl -0xc(%rbp), %eax addl $0x1, %eax movl %eax, -0xc(%rbp) jmp 0x1a062 leaq 0x34b37(%rip), %rax # 0x4ec24 movq %rax, -0x8(%rbp) movq -0x8(%rbp), %rax addq $0x20, %rsp popq %rbp retq nopl (%rax,%rax)
madb_get_os_character_set: push rbp mov rbp, rsp sub rsp, 20h mov [rbp+var_C], 0 mov [rbp+var_18], 0 xor edi, edi lea rsi, aExecuteTestWit+29h; "" call _setlocale cmp rax, 0 jz short loc_1A049 mov edi, 0Eh call _nl_langinfo mov [rbp+var_18], rax loc_1A049: cmp [rbp+var_18], 0 jnz short loc_1A060 lea rax, aCreateTableT1A+29h; "latin1" mov [rbp+var_8], rax jmp loc_1A0F1 loc_1A060: jmp short $+2 loc_1A062: mov eax, [rbp+var_C] mov ecx, eax lea rax, MADB_OS_CHARSET imul rcx, 28h ; '(' add rax, rcx cmp qword ptr [rax], 0 jz short loc_1A0E6 mov eax, [rbp+var_C] mov ecx, eax lea rax, MADB_OS_CHARSET imul rcx, 28h ; '(' add rax, rcx movzx eax, byte ptr [rax+20h] cmp eax, 0 jle short loc_1A0D8 mov eax, [rbp+var_C] mov ecx, eax lea rax, MADB_OS_CHARSET imul rcx, 28h ; '(' add rax, rcx mov rdi, [rax] mov rsi, [rbp+var_18] call _strcasecmp cmp eax, 0 jnz short loc_1A0D8 mov eax, [rbp+var_C] mov ecx, eax lea rax, MADB_OS_CHARSET imul rcx, 28h ; '(' add rax, rcx mov rax, [rax+10h] mov [rbp+var_8], rax jmp short loc_1A0F1 loc_1A0D8: mov eax, [rbp+var_C] add eax, 1 mov [rbp+var_C], eax jmp loc_1A062 loc_1A0E6: lea rax, aCreateTableT1A+29h; "latin1" mov [rbp+var_8], rax loc_1A0F1: mov rax, [rbp+var_8] add rsp, 20h pop rbp retn
char *madb_get_os_character_set() { long long v1; // [rsp+8h] [rbp-18h] unsigned int v2; // [rsp+14h] [rbp-Ch] v2 = 0; v1 = 0LL; if ( setlocale(0LL, "") ) v1 = nl_langinfo(14LL); if ( !v1 ) return "latin1"; while ( *(&MADB_OS_CHARSET + 5 * v2) ) { if ( *((_BYTE *)&MADB_OS_CHARSET + 40 * v2 + 32) && !(unsigned int)strcasecmp(*(&MADB_OS_CHARSET + 5 * v2), v1) ) return (char *)*(&MADB_OS_CHARSET + 5 * v2 + 2); ++v2; } return "latin1"; }
madb_get_os_character_set: PUSH RBP MOV RBP,RSP SUB RSP,0x20 MOV dword ptr [RBP + -0xc],0x0 MOV qword ptr [RBP + -0x18],0x0 XOR EDI,EDI LEA RSI,[0x14e8eb] CALL 0x001133a0 CMP RAX,0x0 JZ 0x0011a049 MOV EDI,0xe CALL 0x00113410 MOV qword ptr [RBP + -0x18],RAX LAB_0011a049: CMP qword ptr [RBP + -0x18],0x0 JNZ 0x0011a060 LEA RAX,[0x14ec24] MOV qword ptr [RBP + -0x8],RAX JMP 0x0011a0f1 LAB_0011a060: JMP 0x0011a062 LAB_0011a062: MOV EAX,dword ptr [RBP + -0xc] MOV ECX,EAX LEA RAX,[0x162380] IMUL RCX,RCX,0x28 ADD RAX,RCX CMP qword ptr [RAX],0x0 JZ 0x0011a0e6 MOV EAX,dword ptr [RBP + -0xc] MOV ECX,EAX LEA RAX,[0x162380] IMUL RCX,RCX,0x28 ADD RAX,RCX MOVZX EAX,byte ptr [RAX + 0x20] CMP EAX,0x0 JLE 0x0011a0d8 MOV EAX,dword ptr [RBP + -0xc] MOV ECX,EAX LEA RAX,[0x162380] IMUL RCX,RCX,0x28 ADD RAX,RCX MOV RDI,qword ptr [RAX] MOV RSI,qword ptr [RBP + -0x18] CALL 0x00113480 CMP EAX,0x0 JNZ 0x0011a0d8 MOV EAX,dword ptr [RBP + -0xc] MOV ECX,EAX LEA RAX,[0x162380] IMUL RCX,RCX,0x28 ADD RAX,RCX MOV RAX,qword ptr [RAX + 0x10] MOV qword ptr [RBP + -0x8],RAX JMP 0x0011a0f1 LAB_0011a0d8: MOV EAX,dword ptr [RBP + -0xc] ADD EAX,0x1 MOV dword ptr [RBP + -0xc],EAX JMP 0x0011a062 LAB_0011a0e6: LEA RAX,[0x14ec24] MOV qword ptr [RBP + -0x8],RAX LAB_0011a0f1: MOV RAX,qword ptr [RBP + -0x8] ADD RSP,0x20 POP RBP RET
char * madb_get_os_character_set(void) { int iVar1; char *pcVar2; char *local_20; uint local_14; char *local_10; local_14 = 0; local_20 = (char *)0x0; pcVar2 = setlocale(0,""); if (pcVar2 != (char *)0x0) { local_20 = nl_langinfo(0xe); } if (local_20 != (char *)0x0) { while (*(long *)(MADB_OS_CHARSET + (ulong)local_14 * 0x28) != 0) { if ((MADB_OS_CHARSET[(ulong)local_14 * 0x28 + 0x20] != '\0') && (iVar1 = strcasecmp(*(char **)(MADB_OS_CHARSET + (ulong)local_14 * 0x28),local_20), iVar1 == 0)) { return *(char **)(MADB_OS_CHARSET + (ulong)local_14 * 0x28 + 0x10); } local_14 = local_14 + 1; } } local_10 = "latin1"; return local_10; }
31,841
translog_fill_overhead_table
eloqsql/storage/maria/ma_loghandler.c
void translog_fill_overhead_table() { uint i; for (i= 0; i < TRANSLOG_FLAGS_NUM; i++) { page_overhead[i]= 7; if (i & TRANSLOG_PAGE_CRC) page_overhead[i]+= CRC_SIZE; if (i & TRANSLOG_SECTOR_PROTECTION) page_overhead[i]+= TRANSLOG_PAGE_SIZE / DISK_DRIVE_SECTOR_SIZE; } }
O0
c
translog_fill_overhead_table: pushq %rbp movq %rsp, %rbp movl $0x0, -0x4(%rbp) cmpl $0x8, -0x4(%rbp) jae 0x2c71f movl -0x4(%rbp), %eax movl %eax, %ecx leaq 0xc545c3(%rip), %rax # 0xc80c80 movl $0x7, (%rax,%rcx,4) movl -0x4(%rbp), %eax andl $0x1, %eax cmpl $0x0, %eax je 0x2c6eb movl -0x4(%rbp), %eax movl %eax, %ecx leaq 0xc545a5(%rip), %rax # 0xc80c80 movl (%rax,%rcx,4), %edx addl $0x4, %edx leaq 0xc54598(%rip), %rax # 0xc80c80 movl %edx, (%rax,%rcx,4) movl -0x4(%rbp), %eax andl $0x2, %eax cmpl $0x0, %eax je 0x2c712 movl -0x4(%rbp), %eax movl %eax, %ecx leaq 0xc5457e(%rip), %rax # 0xc80c80 movl (%rax,%rcx,4), %edx addl $0x10, %edx leaq 0xc54571(%rip), %rax # 0xc80c80 movl %edx, (%rax,%rcx,4) jmp 0x2c714 movl -0x4(%rbp), %eax addl $0x1, %eax movl %eax, -0x4(%rbp) jmp 0x2c6ab popq %rbp retq nopw %cs:(%rax,%rax)
translog_fill_overhead_table: push rbp mov rbp, rsp mov [rbp+var_4], 0 loc_2C6AB: cmp [rbp+var_4], 8 jnb short loc_2C71F mov eax, [rbp+var_4] mov ecx, eax lea rax, page_overhead mov dword ptr [rax+rcx*4], 7 mov eax, [rbp+var_4] and eax, 1 cmp eax, 0 jz short loc_2C6EB mov eax, [rbp+var_4] mov ecx, eax lea rax, page_overhead mov edx, [rax+rcx*4] add edx, 4 lea rax, page_overhead mov [rax+rcx*4], edx loc_2C6EB: mov eax, [rbp+var_4] and eax, 2 cmp eax, 0 jz short loc_2C712 mov eax, [rbp+var_4] mov ecx, eax lea rax, page_overhead mov edx, [rax+rcx*4] add edx, 10h lea rax, page_overhead mov [rax+rcx*4], edx loc_2C712: jmp short $+2 loc_2C714: mov eax, [rbp+var_4] add eax, 1 mov [rbp+var_4], eax jmp short loc_2C6AB loc_2C71F: pop rbp retn
long long translog_fill_overhead_table() { long long result; // rax unsigned int i; // [rsp+0h] [rbp-4h] for ( i = 0; i < 8; ++i ) { page_overhead[i] = 7; if ( (i & 1) != 0 ) page_overhead[i] += 4; if ( (i & 2) != 0 ) page_overhead[i] += 16; result = i + 1; } return result; }
translog_fill_overhead_table: PUSH RBP MOV RBP,RSP MOV dword ptr [RBP + -0x4],0x0 LAB_0012c6ab: CMP dword ptr [RBP + -0x4],0x8 JNC 0x0012c71f MOV EAX,dword ptr [RBP + -0x4] MOV ECX,EAX LEA RAX,[0xd80c80] MOV dword ptr [RAX + RCX*0x4],0x7 MOV EAX,dword ptr [RBP + -0x4] AND EAX,0x1 CMP EAX,0x0 JZ 0x0012c6eb MOV EAX,dword ptr [RBP + -0x4] MOV ECX,EAX LEA RAX,[0xd80c80] MOV EDX,dword ptr [RAX + RCX*0x4] ADD EDX,0x4 LEA RAX,[0xd80c80] MOV dword ptr [RAX + RCX*0x4],EDX LAB_0012c6eb: MOV EAX,dword ptr [RBP + -0x4] AND EAX,0x2 CMP EAX,0x0 JZ 0x0012c712 MOV EAX,dword ptr [RBP + -0x4] MOV ECX,EAX LEA RAX,[0xd80c80] MOV EDX,dword ptr [RAX + RCX*0x4] ADD EDX,0x10 LEA RAX,[0xd80c80] MOV dword ptr [RAX + RCX*0x4],EDX LAB_0012c712: JMP 0x0012c714 LAB_0012c714: MOV EAX,dword ptr [RBP + -0x4] ADD EAX,0x1 MOV dword ptr [RBP + -0x4],EAX JMP 0x0012c6ab LAB_0012c71f: POP RBP RET
void translog_fill_overhead_table(void) { uint local_c; for (local_c = 0; local_c < 8; local_c = local_c + 1) { *(int4 *)(page_overhead + (ulong)local_c * 4) = 7; if ((local_c & 1) != 0) { *(int *)(page_overhead + (ulong)local_c * 4) = *(int *)(page_overhead + (ulong)local_c * 4) + 4; } if ((local_c & 2) != 0) { *(int *)(page_overhead + (ulong)local_c * 4) = *(int *)(page_overhead + (ulong)local_c * 4) + 0x10; } } return; }
31,842
Wsrep_schema::init()
eloqsql/sql/wsrep_schema.cc
int Wsrep_schema::init() { DBUG_ENTER("Wsrep_schema::init()"); int ret; THD* thd= new THD(next_thread_id()); if (!thd) { WSREP_ERROR("Unable to get thd"); DBUG_RETURN(1); } thd->thread_stack= (char*)&thd; wsrep_init_thd_for_schema(thd); if (Wsrep_schema_impl::execute_SQL(thd, create_cluster_table_str.c_str(), create_cluster_table_str.size()) || Wsrep_schema_impl::execute_SQL(thd, create_members_table_str.c_str(), create_members_table_str.size()) || #ifdef WSREP_SCHEMA_MEMBERS_HISTORY Wsrep_schema_impl::execute_SQL(thd, create_members_history_table_str.c_str(), create_members_history_table_str.size()) || Wsrep_schema_impl::execute_SQL(thd, alter_members_history_table.c_str(), alter_members_history_table.size()) || #endif /* WSREP_SCHEMA_MEMBERS_HISTORY */ Wsrep_schema_impl::execute_SQL(thd, create_frag_table_str.c_str(), create_frag_table_str.size()) || Wsrep_schema_impl::execute_SQL(thd, alter_cluster_table.c_str(), alter_cluster_table.size()) || Wsrep_schema_impl::execute_SQL(thd, alter_members_table.c_str(), alter_members_table.size()) || Wsrep_schema_impl::execute_SQL(thd, alter_frag_table.c_str(), alter_frag_table.size())) { ret= 1; } else { ret= 0; } delete thd; DBUG_RETURN(ret); }
O0
cpp
Wsrep_schema::init(): pushq %rbp movq %rsp, %rbp subq $0xc0, %rsp movq %rdi, -0x10(%rbp) movl $0x6948, %edi # imm = 0x6948 callq 0x7dd160 movq %rax, %rcx movq %rcx, -0x48(%rbp) movb $0x0, -0x21(%rbp) xorl %eax, %eax cmpq $0x0, %rcx movq %rax, -0x40(%rbp) je 0xf82dca movb $0x1, -0x21(%rbp) callq 0x7d3ce0 movq %rax, -0x50(%rbp) jmp 0xf82daf movq -0x50(%rbp), %rsi movq -0x48(%rbp), %rdi xorl %edx, %edx callq 0x87d510 jmp 0xf82dc0 movq -0x48(%rbp), %rax movq %rax, -0x40(%rbp) jmp 0xf82dca movq -0x40(%rbp), %rax movq %rax, -0x20(%rbp) cmpq $0x0, -0x20(%rbp) jne 0xf82e2d leaq -0x2596e0(%rip), %rdi # 0xd29700 leaq 0x48d675(%rip), %rsi # 0x141045c movl $0x2b6, %edx # imm = 0x2B6 leaq 0x48d6a6(%rip), %rcx # 0x1410499 movb $0x0, %al callq 0xf64bc0 movl $0x1, -0x4(%rbp) jmp 0xf82fff movq %rax, %rcx movl %edx, %eax movq %rcx, -0x30(%rbp) movl %eax, -0x34(%rbp) testb $0x1, -0x21(%rbp) jne 0xf82e1a jmp 0xf82e28 movq -0x48(%rbp), %rdi movl $0x6948, %esi # imm = 0x6948 callq 0x7dd230 jmp 0xf8300b movq -0x20(%rbp), %rax leaq -0x20(%rbp), %rcx movq %rcx, 0x1e98(%rax) movq -0x20(%rbp), %rdi callq 0xf83020 movq -0x20(%rbp), %rax movq %rax, -0x60(%rbp) leaq 0x15cf16c(%rip), %rdi # 0x2551fc0 callq 0x759420 movq %rax, -0x58(%rbp) leaq 0x15cf15c(%rip), %rdi # 0x2551fc0 callq 0x7596c0 movq -0x60(%rbp), %rdi movq -0x58(%rbp), %rsi movl %eax, %edx callq 0xf83110 cmpl $0x0, %eax jne 0xf82fc9 movq -0x20(%rbp), %rax movq %rax, -0x70(%rbp) leaq 0x15cf150(%rip), %rdi # 0x2551fe0 callq 0x759420 movq %rax, -0x68(%rbp) leaq 0x15cf140(%rip), %rdi # 0x2551fe0 callq 0x7596c0 movq -0x70(%rbp), %rdi movq -0x68(%rbp), %rsi movl %eax, %edx callq 0xf83110 cmpl $0x0, %eax jne 0xf82fc9 movq -0x20(%rbp), %rax movq %rax, -0x80(%rbp) leaq 0x15cf134(%rip), %rdi # 0x2552000 callq 0x759420 movq %rax, -0x78(%rbp) leaq 0x15cf124(%rip), %rdi # 0x2552000 callq 0x7596c0 movq -0x80(%rbp), %rdi movq -0x78(%rbp), %rsi movl %eax, %edx callq 0xf83110 cmpl $0x0, %eax jne 0xf82fc9 movq -0x20(%rbp), %rax movq %rax, -0x90(%rbp) leaq 0x15cf155(%rip), %rdi # 0x2552060 callq 0x759420 movq %rax, -0x88(%rbp) leaq 0x15cf142(%rip), %rdi # 0x2552060 callq 0x7596c0 movq -0x90(%rbp), %rdi movq -0x88(%rbp), %rsi movl %eax, %edx callq 0xf83110 cmpl $0x0, %eax jne 0xf82fc9 movq -0x20(%rbp), %rax movq %rax, -0xa0(%rbp) leaq 0x15cf12d(%rip), %rdi # 0x2552080 callq 0x759420 movq %rax, -0x98(%rbp) leaq 0x15cf11a(%rip), %rdi # 0x2552080 callq 0x7596c0 movq -0xa0(%rbp), %rdi movq -0x98(%rbp), %rsi movl %eax, %edx callq 0xf83110 cmpl $0x0, %eax jne 0xf82fc9 movq -0x20(%rbp), %rax movq %rax, -0xb0(%rbp) leaq 0x15cf109(%rip), %rdi # 0x25520a0 callq 0x759420 movq %rax, -0xa8(%rbp) leaq 0x15cf0f6(%rip), %rdi # 0x25520a0 callq 0x7596c0 movq -0xb0(%rbp), %rdi movq -0xa8(%rbp), %rsi movl %eax, %edx callq 0xf83110 cmpl $0x0, %eax je 0xf82fd2 movl $0x1, -0x14(%rbp) jmp 0xf82fd9 movl $0x0, -0x14(%rbp) movq -0x20(%rbp), %rax movq %rax, -0xb8(%rbp) cmpq $0x0, %rax je 0xf82ff7 movq -0xb8(%rbp), %rdi movq (%rdi), %rax callq *0x8(%rax) jmp 0xf82ff9 movl -0x14(%rbp), %eax movl %eax, -0x4(%rbp) movl -0x4(%rbp), %eax addq $0xc0, %rsp popq %rbp retq movq -0x30(%rbp), %rdi callq 0x7589b0 nopw %cs:(%rax,%rax)
_ZN12Wsrep_schema4initEv: push rbp mov rbp, rsp sub rsp, 0C0h mov [rbp+var_10], rdi mov edi, (offset elf_gnu_hash_indexes+6588h); this call _ZN5ilinknwEm; ilink::operator new(ulong) mov rcx, rax mov [rbp+var_48], rcx mov [rbp+var_21], 0 xor eax, eax cmp rcx, 0 mov [rbp+var_40], rax jz short loc_F82DCA mov [rbp+var_21], 1 call _Z14next_thread_idv; next_thread_id(void) mov [rbp+var_50], rax jmp short $+2 loc_F82DAF: mov rsi, [rbp+var_50]; unsigned __int64 mov rdi, [rbp+var_48]; this xor edx, edx; bool call _ZN3THDC2Eyb; THD::THD(ulong long,bool) jmp short $+2 loc_F82DC0: mov rax, [rbp+var_48] mov [rbp+var_40], rax jmp short $+2 loc_F82DCA: mov rax, [rbp+var_40] mov [rbp+var_20], rax cmp [rbp+var_20], 0 jnz short loc_F82E2D lea rdi, _Z16glog_print_errorPKciS0_z; void (*)(const char *, int, const char *, ...) lea rsi, aWorkspaceLlm4b_179; "/workspace/llm4binary/github2025/eloqsq"... mov edx, 2B6h; int lea rcx, aUnableToGetThd; "Unable to get thd" mov al, 0 call _Z9WSREP_LOGPFvPKciS0_zES0_iS0_z; WSREP_LOG(void (*)(char const*,int,char const*,...),char const*,int,char const*,...) mov [rbp+var_4], 1 jmp loc_F82FFF mov rcx, rax mov eax, edx mov [rbp+var_30], rcx mov [rbp+var_34], eax test [rbp+var_21], 1 jnz short loc_F82E1A jmp short loc_F82E28 loc_F82E1A: mov rdi, [rbp+var_48]; void * mov esi, 6948h; unsigned __int64 call _ZN5ilinkdlEPvm; ilink::operator delete(void *,ulong) loc_F82E28: jmp loc_F8300B loc_F82E2D: mov rax, [rbp+var_20] lea rcx, [rbp+var_20] mov [rax+1E98h], rcx mov rdi, [rbp+var_20]; THD * call _ZL25wsrep_init_thd_for_schemaP3THD; wsrep_init_thd_for_schema(THD *) mov rax, [rbp+var_20] mov [rbp+var_60], rax lea rdi, _ZL24create_cluster_table_strB5cxx11; create_cluster_table_str call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5c_strEv; std::string::c_str(void) mov [rbp+var_58], rax lea rdi, _ZL24create_cluster_table_strB5cxx11; create_cluster_table_str call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4sizeEv; std::string::size(void) mov rdi, [rbp+var_60]; this mov rsi, [rbp+var_58]; THD * mov edx, eax; char * call _ZN17Wsrep_schema_implL11execute_SQLEP3THDPKcj; Wsrep_schema_impl::execute_SQL(THD *,char const*,uint) cmp eax, 0 jnz loc_F82FC9 mov rax, [rbp+var_20] mov [rbp+var_70], rax lea rdi, _ZL24create_members_table_strB5cxx11; create_members_table_str call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5c_strEv; std::string::c_str(void) mov [rbp+var_68], rax lea rdi, _ZL24create_members_table_strB5cxx11; create_members_table_str call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4sizeEv; std::string::size(void) mov rdi, [rbp+var_70]; this mov rsi, [rbp+var_68]; THD * mov edx, eax; char * call _ZN17Wsrep_schema_implL11execute_SQLEP3THDPKcj; Wsrep_schema_impl::execute_SQL(THD *,char const*,uint) cmp eax, 0 jnz loc_F82FC9 mov rax, [rbp+var_20] mov [rbp+var_80], rax lea rdi, _ZL21create_frag_table_strB5cxx11; create_frag_table_str call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5c_strEv; std::string::c_str(void) mov [rbp+var_78], rax lea rdi, _ZL21create_frag_table_strB5cxx11; create_frag_table_str call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4sizeEv; std::string::size(void) mov rdi, [rbp+var_80]; this mov rsi, [rbp+var_78]; THD * mov edx, eax; char * call _ZN17Wsrep_schema_implL11execute_SQLEP3THDPKcj; Wsrep_schema_impl::execute_SQL(THD *,char const*,uint) cmp eax, 0 jnz loc_F82FC9 mov rax, [rbp+var_20] mov [rbp+var_90], rax lea rdi, _ZL19alter_cluster_tableB5cxx11; alter_cluster_table call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5c_strEv; std::string::c_str(void) mov [rbp+var_88], rax lea rdi, _ZL19alter_cluster_tableB5cxx11; alter_cluster_table call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4sizeEv; std::string::size(void) mov rdi, [rbp+var_90]; this mov rsi, [rbp+var_88]; THD * mov edx, eax; char * call _ZN17Wsrep_schema_implL11execute_SQLEP3THDPKcj; Wsrep_schema_impl::execute_SQL(THD *,char const*,uint) cmp eax, 0 jnz loc_F82FC9 mov rax, [rbp+var_20] mov [rbp+var_A0], rax lea rdi, _ZL19alter_members_tableB5cxx11; alter_members_table call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5c_strEv; std::string::c_str(void) mov [rbp+var_98], rax lea rdi, _ZL19alter_members_tableB5cxx11; alter_members_table call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4sizeEv; std::string::size(void) mov rdi, [rbp+var_A0]; this mov rsi, [rbp+var_98]; THD * mov edx, eax; char * call _ZN17Wsrep_schema_implL11execute_SQLEP3THDPKcj; Wsrep_schema_impl::execute_SQL(THD *,char const*,uint) cmp eax, 0 jnz short loc_F82FC9 mov rax, [rbp+var_20] mov [rbp+var_B0], rax lea rdi, _ZL16alter_frag_tableB5cxx11; alter_frag_table call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5c_strEv; std::string::c_str(void) mov [rbp+var_A8], rax lea rdi, _ZL16alter_frag_tableB5cxx11; alter_frag_table call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4sizeEv; std::string::size(void) mov rdi, [rbp+var_B0]; this mov rsi, [rbp+var_A8]; THD * mov edx, eax; char * call _ZN17Wsrep_schema_implL11execute_SQLEP3THDPKcj; Wsrep_schema_impl::execute_SQL(THD *,char const*,uint) cmp eax, 0 jz short loc_F82FD2 loc_F82FC9: mov [rbp+var_14], 1 jmp short loc_F82FD9 loc_F82FD2: mov [rbp+var_14], 0 loc_F82FD9: mov rax, [rbp+var_20] mov [rbp+var_B8], rax cmp rax, 0 jz short loc_F82FF7 mov rdi, [rbp+var_B8] mov rax, [rdi] call qword ptr [rax+8] loc_F82FF7: jmp short $+2 loc_F82FF9: mov eax, [rbp+var_14] mov [rbp+var_4], eax loc_F82FFF: mov eax, [rbp+var_4] add rsp, 0C0h pop rbp retn loc_F8300B: mov rdi, [rbp+var_30] call __Unwind_Resume
long long Wsrep_schema::init(Wsrep_schema *this) { unsigned int v1; // eax unsigned int v2; // ecx unsigned int v3; // eax unsigned int v4; // ecx unsigned int v5; // eax unsigned int v6; // ecx unsigned int v7; // eax unsigned int v8; // ecx unsigned int v9; // eax unsigned int v10; // ecx unsigned int v11; // eax unsigned int v12; // ecx THD *v14; // [rsp+10h] [rbp-B0h] THD *v15; // [rsp+18h] [rbp-A8h] THD *v16; // [rsp+20h] [rbp-A0h] THD *v17; // [rsp+28h] [rbp-98h] THD *v18; // [rsp+30h] [rbp-90h] THD *v19; // [rsp+38h] [rbp-88h] THD *v20; // [rsp+40h] [rbp-80h] THD *v21; // [rsp+48h] [rbp-78h] THD *v22; // [rsp+50h] [rbp-70h] THD *v23; // [rsp+58h] [rbp-68h] THD *v24; // [rsp+60h] [rbp-60h] THD *v25; // [rsp+68h] [rbp-58h] long long thread_id; // [rsp+70h] [rbp-50h] THD *v27; // [rsp+78h] [rbp-48h] THD *v28; // [rsp+80h] [rbp-40h] THD *v29; // [rsp+A0h] [rbp-20h] BYREF unsigned int v30; // [rsp+ACh] [rbp-14h] Wsrep_schema *v31; // [rsp+B0h] [rbp-10h] v31 = this; v27 = (THD *)ilink::operator new((ilink *)&elf_gnu_hash_indexes[3249]); v28 = 0LL; if ( v27 ) { thread_id = next_thread_id(); THD::THD(v27, thread_id, 0); v28 = v27; } v29 = v28; if ( v28 ) { *((_QWORD *)v29 + 979) = &v29; wsrep_init_thd_for_schema(v29); v24 = v29; v25 = (THD *)std::string::c_str(&create_cluster_table_str[abi:cxx11]); v1 = std::string::size(&create_cluster_table_str[abi:cxx11]); if ( (unsigned int)Wsrep_schema_impl::execute_SQL(v24, v25, (const char *)v1, v2) ) goto LABEL_11; v22 = v29; v23 = (THD *)std::string::c_str(&create_members_table_str[abi:cxx11]); v3 = std::string::size(&create_members_table_str[abi:cxx11]); if ( (unsigned int)Wsrep_schema_impl::execute_SQL(v22, v23, (const char *)v3, v4) ) goto LABEL_11; v20 = v29; v21 = (THD *)std::string::c_str(&create_frag_table_str[abi:cxx11]); v5 = std::string::size(&create_frag_table_str[abi:cxx11]); if ( (unsigned int)Wsrep_schema_impl::execute_SQL(v20, v21, (const char *)v5, v6) ) goto LABEL_11; v18 = v29; v19 = (THD *)std::string::c_str(&alter_cluster_table[abi:cxx11]); v7 = std::string::size(&alter_cluster_table[abi:cxx11]); if ( (unsigned int)Wsrep_schema_impl::execute_SQL(v18, v19, (const char *)v7, v8) || (v16 = v29, v17 = (THD *)std::string::c_str(&alter_members_table[abi:cxx11]), v9 = std::string::size(&alter_members_table[abi:cxx11]), (unsigned int)Wsrep_schema_impl::execute_SQL(v16, v17, (const char *)v9, v10)) || (v14 = v29, v15 = (THD *)std::string::c_str(&alter_frag_table[abi:cxx11]), v11 = std::string::size(&alter_frag_table[abi:cxx11]), (unsigned int)Wsrep_schema_impl::execute_SQL(v14, v15, (const char *)v11, v12)) ) { LABEL_11: v30 = 1; } else { v30 = 0; } if ( v29 ) (*(void ( **)(THD *))(*(_QWORD *)v29 + 8LL))(v29); return v30; } else { WSREP_LOG( (void (*)(const char *, int, const char *, ...))glog_print_error, "/workspace/llm4binary/github2025/eloqsql/sql/wsrep_schema.cc", 694, "Unable to get thd"); return 1; } }
write_hook_for_undo_key: PUSH RBP MOV RBP,RSP SUB RSP,0x30 MOV dword ptr [RBP + -0x4],EDI MOV qword ptr [RBP + -0x10],RSI MOV qword ptr [RBP + -0x18],RDX MOV qword ptr [RBP + -0x20],RCX MOV qword ptr [RBP + -0x28],R8 MOV RAX,qword ptr [RBP + -0x28] MOV qword ptr [RBP + -0x30],RAX MOV RAX,qword ptr [RBP + -0x30] MOV RCX,qword ptr [RAX + 0x8] MOV RAX,qword ptr [RBP + -0x30] MOV RAX,qword ptr [RAX] MOV qword ptr [RAX],RCX MOV RDI,qword ptr [RBP + -0x18] CALL 0x00f82dd0 MOV EDI,dword ptr [RBP + -0x4] MOV RSI,qword ptr [RBP + -0x10] MOV RDX,qword ptr [RBP + -0x18] MOV RCX,qword ptr [RBP + -0x20] XOR EAX,EAX MOV R8D,EAX CALL 0x00f919c0 ADD RSP,0x30 POP RBP RET
void write_hook_for_undo_key (int4 param_1,int8 param_2,int8 param_3,int8 param_4, int8 *param_5) { *(int8 *)*param_5 = param_5[1]; _ma_fast_unlock_key_del(param_3); write_hook_for_undo(param_1,param_2,param_3,param_4,0); return; }
31,843
LefDefParser::defiScanchain::setStart(char const*, char const*)
Efficient-TDP/thirdparty/Limbo/limbo/thirdparty/lefdef/5.8/def/def/defiScanchain.cpp
void defiScanchain::setStart(const char* inst, const char* pin) { int len; if (startInst_) defiError(0, 6150, "ERROR (DEFPARS-6150): The START statement in the SCANCHAINS has defined more than one time in the SCANCHAINS statement.\nUpdate the DEF file to only one START statement and then try again.", defData); len = strlen(inst) + 1; startInst_ = (char*)malloc(len); strcpy(startInst_, defData->DEFCASE(inst)); len = strlen(pin) + 1; startPin_ = (char*)malloc(len); strcpy(startPin_, defData->DEFCASE(pin)); hasStart_ = 1; }
O0
cpp
LefDefParser::defiScanchain::setStart(char const*, char const*): subq $0x38, %rsp movq %rdi, 0x30(%rsp) movq %rsi, 0x28(%rsp) movq %rdx, 0x20(%rsp) movq 0x30(%rsp), %rax movq %rax, 0x10(%rsp) cmpq $0x0, 0x58(%rax) je 0x426e3 movq 0x10(%rsp), %rax movq 0x90(%rax), %rcx xorl %edi, %edi movl $0x1806, %esi # imm = 0x1806 leaq 0x32e86(%rip), %rdx # 0x75564 callq 0x2a600 movq 0x28(%rsp), %rdi callq 0x70e0 addq $0x1, %rax movl %eax, 0x1c(%rsp) movslq 0x1c(%rsp), %rdi callq 0x72d0 movq %rax, %rcx movq 0x10(%rsp), %rax movq %rcx, 0x58(%rax) movq 0x58(%rax), %rcx movq %rcx, (%rsp) movq 0x90(%rax), %rdi movq 0x28(%rsp), %rsi callq 0x27ed0 movq (%rsp), %rdi movq %rax, %rsi callq 0x7220 movq 0x20(%rsp), %rdi callq 0x70e0 addq $0x1, %rax movl %eax, 0x1c(%rsp) movslq 0x1c(%rsp), %rdi callq 0x72d0 movq %rax, %rcx movq 0x10(%rsp), %rax movq %rcx, 0x60(%rax) movq 0x60(%rax), %rcx movq %rcx, 0x8(%rsp) movq 0x90(%rax), %rdi movq 0x20(%rsp), %rsi callq 0x27ed0 movq 0x8(%rsp), %rdi movq %rax, %rsi callq 0x7220 movq 0x10(%rsp), %rax movb $0x1, 0x8(%rax) addq $0x38, %rsp retq nopl (%rax)
_ZN12LefDefParser13defiScanchain8setStartEPKcS2_: sub rsp, 38h mov [rsp+38h+var_8], rdi mov [rsp+38h+var_10], rsi mov [rsp+38h+var_18], rdx mov rax, [rsp+38h+var_8] mov [rsp+38h+var_28], rax cmp qword ptr [rax+58h], 0 jz short loc_426E3 mov rax, [rsp+38h+var_28] mov rcx, [rax+90h]; char * xor edi, edi; this mov esi, 1806h; int lea rdx, aErrorDefpars61_4; "ERROR (DEFPARS-6150): The START stateme"... call _ZN12LefDefParser9defiErrorEiiPKcPNS_8defrDataE; LefDefParser::defiError(int,int,char const*,LefDefParser::defrData *) loc_426E3: mov rdi, [rsp+38h+var_10] call _strlen add rax, 1 mov [rsp+38h+var_1C], eax movsxd rdi, [rsp+38h+var_1C] call _malloc mov rcx, rax mov rax, [rsp+38h+var_28] mov [rax+58h], rcx mov rcx, [rax+58h] mov [rsp+38h+var_38], rcx mov rdi, [rax+90h]; this mov rsi, [rsp+38h+var_10]; char * call _ZN12LefDefParser8defrData7DEFCASEEPKc; LefDefParser::defrData::DEFCASE(char const*) mov rdi, [rsp+38h+var_38] mov rsi, rax call _strcpy mov rdi, [rsp+38h+var_18] call _strlen add rax, 1 mov [rsp+38h+var_1C], eax movsxd rdi, [rsp+38h+var_1C] call _malloc mov rcx, rax mov rax, [rsp+38h+var_28] mov [rax+60h], rcx mov rcx, [rax+60h] mov [rsp+38h+var_30], rcx mov rdi, [rax+90h]; this mov rsi, [rsp+38h+var_18]; char * call _ZN12LefDefParser8defrData7DEFCASEEPKc; LefDefParser::defrData::DEFCASE(char const*) mov rdi, [rsp+38h+var_30] mov rsi, rax call _strcpy mov rax, [rsp+38h+var_28] mov byte ptr [rax+8], 1 add rsp, 38h retn
LefDefParser::defrData ** LefDefParser::defiScanchain::setStart( LefDefParser::defrData **this, const char *a2, const char *a3, long long a4, LefDefParser::defrData *a5) { int v5; // eax const char *v6; // rax long long v7; // rdx const char *v8; // rax long long v9; // rdx LefDefParser::defrData **result; // rax LefDefParser::defrData *v11; // [rsp+0h] [rbp-38h] LefDefParser::defrData *v12; // [rsp+8h] [rbp-30h] int v13; // [rsp+1Ch] [rbp-1Ch] if ( this[11] ) LefDefParser::defiError( 0LL, 6150, "ERROR (DEFPARS-6150): The START statement in the SCANCHAINS has defined more than one time in the SCANCHAINS state" "ment.\n" "Update the DEF file to only one START statement and then try again.", this[18], a5); v5 = strlen(a2); this[11] = (LefDefParser::defrData *)malloc(v5 + 1); v11 = this[11]; v6 = LefDefParser::defrData::DEFCASE(this[18], a2); strcpy(v11, v6, v7); v13 = strlen(a3) + 1; this[12] = (LefDefParser::defrData *)malloc(v13); v12 = this[12]; v8 = LefDefParser::defrData::DEFCASE(this[18], a3); strcpy(v12, v8, v9); result = this; *((_BYTE *)this + 8) = 1; return result; }
setStart: SUB RSP,0x38 MOV qword ptr [RSP + 0x30],RDI MOV qword ptr [RSP + 0x28],RSI MOV qword ptr [RSP + 0x20],RDX MOV RAX,qword ptr [RSP + 0x30] MOV qword ptr [RSP + 0x10],RAX CMP qword ptr [RAX + 0x58],0x0 JZ 0x001426e3 MOV RAX,qword ptr [RSP + 0x10] MOV RCX,qword ptr [RAX + 0x90] XOR EDI,EDI MOV ESI,0x1806 LEA RDX,[0x175564] CALL 0x0012a600 LAB_001426e3: MOV RDI,qword ptr [RSP + 0x28] CALL 0x001070e0 ADD RAX,0x1 MOV dword ptr [RSP + 0x1c],EAX MOVSXD RDI,dword ptr [RSP + 0x1c] CALL 0x001072d0 MOV RCX,RAX MOV RAX,qword ptr [RSP + 0x10] MOV qword ptr [RAX + 0x58],RCX MOV RCX,qword ptr [RAX + 0x58] MOV qword ptr [RSP],RCX MOV RDI,qword ptr [RAX + 0x90] MOV RSI,qword ptr [RSP + 0x28] CALL 0x00127ed0 MOV RDI,qword ptr [RSP] MOV RSI,RAX CALL 0x00107220 MOV RDI,qword ptr [RSP + 0x20] CALL 0x001070e0 ADD RAX,0x1 MOV dword ptr [RSP + 0x1c],EAX MOVSXD RDI,dword ptr [RSP + 0x1c] CALL 0x001072d0 MOV RCX,RAX MOV RAX,qword ptr [RSP + 0x10] MOV qword ptr [RAX + 0x60],RCX MOV RCX,qword ptr [RAX + 0x60] MOV qword ptr [RSP + 0x8],RCX MOV RDI,qword ptr [RAX + 0x90] MOV RSI,qword ptr [RSP + 0x20] CALL 0x00127ed0 MOV RDI,qword ptr [RSP + 0x8] MOV RSI,RAX CALL 0x00107220 MOV RAX,qword ptr [RSP + 0x10] MOV byte ptr [RAX + 0x8],0x1 ADD RSP,0x38 RET
/* LefDefParser::defiScanchain::setStart(char const*, char const*) */ void __thiscall LefDefParser::defiScanchain::setStart(defiScanchain *this,char *param_1,char *param_2) { char *pcVar1; size_t sVar2; void *pvVar3; char *pcVar4; if (*(long *)(this + 0x58) != 0) { defiError(0,0x1806, "ERROR (DEFPARS-6150): The START statement in the SCANCHAINS has defined more than one time in the SCANCHAINS statement.\nUpdate the DEF file to only one START statement and then try again." ,*(defrData **)(this + 0x90)); } sVar2 = strlen(param_1); pvVar3 = malloc((long)((int)sVar2 + 1)); *(void **)(this + 0x58) = pvVar3; pcVar1 = *(char **)(this + 0x58); pcVar4 = (char *)defrData::DEFCASE(*(defrData **)(this + 0x90),param_1); strcpy(pcVar1,pcVar4); sVar2 = strlen(param_2); pvVar3 = malloc((long)((int)sVar2 + 1)); *(void **)(this + 0x60) = pvVar3; pcVar1 = *(char **)(this + 0x60); pcVar4 = (char *)defrData::DEFCASE(*(defrData **)(this + 0x90),param_2); strcpy(pcVar1,pcVar4); this[8] = (defiScanchain)0x1; return; }
31,844
LefDefParser::defiScanchain::setStart(char const*, char const*)
Efficient-TDP/thirdparty/Limbo/limbo/thirdparty/lefdef/5.8/def/def/defiScanchain.cpp
void defiScanchain::setStart(const char* inst, const char* pin) { int len; if (startInst_) defiError(0, 6150, "ERROR (DEFPARS-6150): The START statement in the SCANCHAINS has defined more than one time in the SCANCHAINS statement.\nUpdate the DEF file to only one START statement and then try again.", defData); len = strlen(inst) + 1; startInst_ = (char*)malloc(len); strcpy(startInst_, defData->DEFCASE(inst)); len = strlen(pin) + 1; startPin_ = (char*)malloc(len); strcpy(startPin_, defData->DEFCASE(pin)); hasStart_ = 1; }
O3
cpp
LefDefParser::defiScanchain::setStart(char const*, char const*): pushq %r15 pushq %r14 pushq %r12 pushq %rbx pushq %rax movq %rdx, %r14 movq %rsi, %r15 movq %rdi, %rbx cmpq $0x0, 0x58(%rdi) je 0x28b84 movq 0x90(%rbx), %rcx leaq 0x1c81e(%rip), %rdx # 0x45396 xorl %edi, %edi movl $0x1806, %esi # imm = 0x1806 callq 0x1bb18 movq %r15, %rdi callq 0x70d0 incl %eax movslq %eax, %rdi callq 0x7270 movq %rax, %r12 movq %rax, 0x58(%rbx) movq 0x90(%rbx), %rdi movq %r15, %rsi callq 0x1b638 movq %r12, %rdi movq %rax, %rsi callq 0x7190 movq %r14, %rdi callq 0x70d0 incl %eax movslq %eax, %rdi callq 0x7270 movq %rax, %r15 movq %rax, 0x60(%rbx) movq 0x90(%rbx), %rdi movq %r14, %rsi callq 0x1b638 movq %r15, %rdi movq %rax, %rsi callq 0x7190 movb $0x1, 0x8(%rbx) addq $0x8, %rsp popq %rbx popq %r12 popq %r14 popq %r15 retq
_ZN12LefDefParser13defiScanchain8setStartEPKcS2_: push r15 push r14 push r12 push rbx push rax mov r14, rdx mov r15, rsi mov rbx, rdi cmp qword ptr [rdi+58h], 0 jz short loc_28B84 mov rcx, [rbx+90h]; LefDefParser::defrData * lea rdx, aErrorDefpars61_4; "ERROR (DEFPARS-6150): The START stateme"... xor edi, edi; this mov esi, 1806h; int call _ZN12LefDefParser9defiErrorEiiPKcPNS_8defrDataE; LefDefParser::defiError(int,int,char const*,LefDefParser::defrData *) loc_28B84: mov rdi, r15 call _strlen inc eax movsxd rdi, eax call _malloc mov r12, rax mov [rbx+58h], rax mov rdi, [rbx+90h]; this mov rsi, r15; char * call _ZN12LefDefParser8defrData7DEFCASEEPKc; LefDefParser::defrData::DEFCASE(char const*) mov rdi, r12 mov rsi, rax call _strcpy mov rdi, r14 call _strlen inc eax movsxd rdi, eax call _malloc mov r15, rax mov [rbx+60h], rax mov rdi, [rbx+90h]; this mov rsi, r14; char * call _ZN12LefDefParser8defrData7DEFCASEEPKc; LefDefParser::defrData::DEFCASE(char const*) mov rdi, r15 mov rsi, rax call _strcpy mov byte ptr [rbx+8], 1 add rsp, 8 pop rbx pop r12 pop r14 pop r15 retn
long long LefDefParser::defiScanchain::setStart( LefDefParser::defrData **this, const char *a2, const char *a3, long long a4, LefDefParser::defrData *a5) { int v6; // eax long long v7; // r12 const char *v8; // rax int v9; // eax long long v10; // r15 const char *v11; // rax long long result; // rax if ( this[11] ) LefDefParser::defiError( 0LL, 6150, "ERROR (DEFPARS-6150): The START statement in the SCANCHAINS has defined more than one time in the SCANCHAINS state" "ment.\n" "Update the DEF file to only one START statement and then try again.", this[18], a5); v6 = strlen(a2); v7 = malloc(v6 + 1); this[11] = (LefDefParser::defrData *)v7; v8 = LefDefParser::defrData::DEFCASE(this[18], a2); strcpy(v7, v8); v9 = strlen(a3); v10 = malloc(v9 + 1); this[12] = (LefDefParser::defrData *)v10; v11 = LefDefParser::defrData::DEFCASE(this[18], a3); result = strcpy(v10, v11); *((_BYTE *)this + 8) = 1; return result; }
setStart: PUSH R15 PUSH R14 PUSH R12 PUSH RBX PUSH RAX MOV R14,RDX MOV R15,RSI MOV RBX,RDI CMP qword ptr [RDI + 0x58],0x0 JZ 0x00128b84 MOV RCX,qword ptr [RBX + 0x90] LEA RDX,[0x145396] XOR EDI,EDI MOV ESI,0x1806 CALL 0x0011bb18 LAB_00128b84: MOV RDI,R15 CALL 0x001070d0 INC EAX MOVSXD RDI,EAX CALL 0x00107270 MOV R12,RAX MOV qword ptr [RBX + 0x58],RAX MOV RDI,qword ptr [RBX + 0x90] MOV RSI,R15 CALL 0x0011b638 MOV RDI,R12 MOV RSI,RAX CALL 0x00107190 MOV RDI,R14 CALL 0x001070d0 INC EAX MOVSXD RDI,EAX CALL 0x00107270 MOV R15,RAX MOV qword ptr [RBX + 0x60],RAX MOV RDI,qword ptr [RBX + 0x90] MOV RSI,R14 CALL 0x0011b638 MOV RDI,R15 MOV RSI,RAX CALL 0x00107190 MOV byte ptr [RBX + 0x8],0x1 ADD RSP,0x8 POP RBX POP R12 POP R14 POP R15 RET
/* LefDefParser::defiScanchain::setStart(char const*, char const*) */ void __thiscall LefDefParser::defiScanchain::setStart(defiScanchain *this,char *param_1,char *param_2) { size_t sVar1; char *pcVar2; char *pcVar3; if (*(long *)(this + 0x58) != 0) { defiError(0,0x1806, "ERROR (DEFPARS-6150): The START statement in the SCANCHAINS has defined more than one time in the SCANCHAINS statement.\nUpdate the DEF file to only one START statement and then try again." ,*(defrData **)(this + 0x90)); } sVar1 = strlen(param_1); pcVar2 = (char *)malloc((long)((int)sVar1 + 1)); *(char **)(this + 0x58) = pcVar2; pcVar3 = (char *)defrData::DEFCASE(*(defrData **)(this + 0x90),param_1); strcpy(pcVar2,pcVar3); sVar1 = strlen(param_2); pcVar2 = (char *)malloc((long)((int)sVar1 + 1)); *(char **)(this + 0x60) = pcVar2; pcVar3 = (char *)defrData::DEFCASE(*(defrData **)(this + 0x90),param_2); strcpy(pcVar2,pcVar3); this[8] = (defiScanchain)0x1; return; }
31,845
psi_rwlock_rdlock
eloqsql/mysys/my_thr_init.c
ATTRIBUTE_COLD int psi_rwlock_rdlock(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_READLOCK, file, line); int result= rw_rdlock(&that->m_rwlock); if (locker) PSI_RWLOCK_CALL(end_rwlock_rdwait)(locker, result); return result; }
O3
c
psi_rwlock_rdlock: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %rbx subq $0x38, %rsp movl %edx, %r8d movq %rsi, %rcx movq %rdi, %r14 leaq 0x37d650(%rip), %r15 # 0x3aea18 movq (%r15), %rax movq 0x90(%rdi), %rsi leaq -0x48(%rbp), %rdi xorl %edx, %edx callq *0x1a0(%rax) movq %rax, %rbx movq %r14, %rdi callq 0xc3d84 movl %eax, %r14d testq %rbx, %rbx je 0x31400 movq (%r15), %rax movq %rbx, %rdi movl %r14d, %esi callq *0x1a8(%rax) movl %r14d, %eax addq $0x38, %rsp popq %rbx popq %r14 popq %r15 popq %rbp retq
psi_rwlock_rdlock: push rbp mov rbp, rsp push r15 push r14 push rbx sub rsp, 38h mov r8d, edx mov rcx, rsi mov r14, rdi lea r15, PSI_server mov rax, [r15] mov rsi, [rdi+90h] lea rdi, [rbp+var_48] xor edx, edx call qword ptr [rax+1A0h] mov rbx, rax mov rdi, r14 call my_rw_rdlock mov r14d, eax test rbx, rbx jz short loc_31400 mov rax, [r15] mov rdi, rbx mov esi, r14d call qword ptr [rax+1A8h] loc_31400: mov eax, r14d add rsp, 38h pop rbx pop r14 pop r15 pop rbp retn
long long psi_rwlock_rdlock(long long a1, long long a2, unsigned int a3) { long long v3; // rbx unsigned int v4; // r14d _BYTE v6[72]; // [rsp+8h] [rbp-48h] BYREF v3 = ((long long ( *)(_BYTE *, _QWORD, _QWORD, long long, _QWORD))PSI_server[52])( v6, *(_QWORD *)(a1 + 144), 0LL, a2, a3); v4 = my_rw_rdlock(a1); if ( v3 ) ((void ( *)(long long, _QWORD))PSI_server[53])(v3, v4); return v4; }
psi_rwlock_rdlock: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH RBX SUB RSP,0x38 MOV R8D,EDX MOV RCX,RSI MOV R14,RDI LEA R15,[0x4aea18] MOV RAX,qword ptr [R15] MOV RSI,qword ptr [RDI + 0x90] LEA RDI,[RBP + -0x48] XOR EDX,EDX CALL qword ptr [RAX + 0x1a0] MOV RBX,RAX MOV RDI,R14 CALL 0x001c3d84 MOV R14D,EAX TEST RBX,RBX JZ 0x00131400 MOV RAX,qword ptr [R15] MOV RDI,RBX MOV ESI,R14D CALL qword ptr [RAX + 0x1a8] LAB_00131400: MOV EAX,R14D ADD RSP,0x38 POP RBX POP R14 POP R15 POP RBP RET
int4 psi_rwlock_rdlock(long param_1,int8 param_2,int4 param_3) { int4 uVar1; long lVar2; int1 local_50 [48]; lVar2 = (**(code **)(PSI_server + 0x1a0)) (local_50,*(int8 *)(param_1 + 0x90),0,param_2,param_3); uVar1 = my_rw_rdlock(param_1); if (lVar2 != 0) { (**(code **)(PSI_server + 0x1a8))(lVar2,uVar1); } return uVar1; }
31,846
js_array_toReversed
bluesky950520[P]quickjs/quickjs.c
static JSValue js_array_toReversed(JSContext *ctx, JSValue this_val, int argc, JSValue *argv) { JSValue arr, obj, ret, *arrp, *pval; JSObject *p; int64_t i, len; uint32_t count32; ret = JS_EXCEPTION; arr = JS_UNDEFINED; obj = JS_ToObject(ctx, this_val); if (js_get_length64(ctx, &len, obj)) goto exception; if (len > UINT32_MAX) { JS_ThrowRangeError(ctx, "invalid array length"); goto exception; } arr = JS_NewArray(ctx); if (JS_IsException(arr)) goto exception; if (len > 0) { p = JS_VALUE_GET_OBJ(arr); if (expand_fast_array(ctx, p, len) < 0) goto exception; p->u.array.count = len; i = len - 1; pval = p->u.array.u.values; if (js_get_fast_array(ctx, obj, &arrp, &count32) && count32 == len) { for (; i >= 0; i--, pval++) *pval = js_dup(arrp[i]); } else { // Query order is observable; test262 expects descending order. for (; i >= 0; i--, pval++) { if (-1 == JS_TryGetPropertyInt64(ctx, obj, i, pval)) { // Exception; initialize remaining elements. for (; i >= 0; i--, pval++) *pval = JS_UNDEFINED; goto exception; } } } if (JS_SetProperty(ctx, arr, JS_ATOM_length, js_int64(len)) < 0) goto exception; } ret = arr; arr = JS_UNDEFINED; exception: JS_FreeValue(ctx, arr); JS_FreeValue(ctx, obj); return ret; }
O2
c
js_array_toReversed: pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x38, %rsp movq %rdi, %rbx callq 0x24742 movq %rax, %r14 movq %rdx, %r15 leaq 0x28(%rsp), %rsi movq %rbx, %rdi movq %rax, %rdx movq %r15, %rcx callq 0x207f3 pushq $0x6 popq %rbp pushq $0x3 popq %rdx testl %eax, %eax je 0x67401 xorl %r12d, %r12d xorl %eax, %eax xorl %r13d, %r13d jmp 0x6757a movq 0x28(%rsp), %rcx movabsq $0x100000000, %rax # imm = 0x100000000 cmpq %rax, %rcx jl 0x67433 leaq 0x21f4a(%rip), %rsi # 0x89366 xorl %r12d, %r12d movq %rbx, %rdi xorl %eax, %eax callq 0x1e863 xorl %eax, %eax xorl %r13d, %r13d jmp 0x67577 movq %rcx, 0x10(%rsp) movq %rbx, %rdi callq 0x1ee6b movq %rax, %r13 movq %rax, %r12 shrq $0x20, %r12 cmpl $0x6, %edx jne 0x67454 movq %r13, %rax jmp 0x673f9 movq %rdx, 0x8(%rsp) movq 0x10(%rsp), %rdx testq %rdx, %rdx jle 0x67570 movq %rbx, %rdi movq %r13, %rsi callq 0x39f55 testl %eax, %eax js 0x675ae movq 0x10(%rsp), %rax movl %eax, 0x40(%r13) leaq -0x1(%rax), %rbp movq %r13, 0x20(%rsp) movq 0x38(%r13), %r13 leaq 0x30(%rsp), %rdx leaq 0x1c(%rsp), %rcx movq %r14, %rdi movq %r15, %rsi callq 0x3de1c testl %eax, %eax je 0x674f6 movl 0x1c(%rsp), %eax movq 0x10(%rsp), %rcx cmpq %rax, %rcx jne 0x674f6 movq 0x30(%rsp), %rax shlq $0x4, %rcx addq %rcx, %rax addq $-0x8, %rax testq %rbp, %rbp js 0x67541 movq -0x8(%rax), %rcx movq (%rax), %rdx cmpl $-0x9, %edx jb 0x674da incl (%rcx) movq %rcx, (%r13) movq %rdx, 0x8(%r13) decq %rbp addq $0x10, %r13 addq $-0x10, %rax jmp 0x674c7 decq %rbp addq $0x10, %r13 testq %rbp, %rbp js 0x67541 movq %rbx, %rdi movq %r14, %rsi movq %r15, %rdx movq %rbp, %rcx movq %r13, %r8 callq 0x46238 cmpl $-0x1, %eax jne 0x674ef jmp 0x6752a andl $0x0, (%r13) movq $0x3, 0x8(%r13) decq %rbp addq $0x10, %r13 testq %rbp, %rbp jns 0x67516 movq 0x20(%rsp), %rax movq 0x8(%rsp), %rdx xorl %r13d, %r13d pushq $0x6 popq %rbp jmp 0x6757a movq 0x10(%rsp), %rdi callq 0x245bb movq %rdx, %r9 pushq $0x32 popq %rcx movq %rbx, %rdi movq 0x20(%rsp), %r13 movq %r13, %rsi movq 0x8(%rsp), %rdx movq %rax, %r8 callq 0x21ff6 testl %eax, %eax pushq $0x6 popq %rcx js 0x675bb xorl %eax, %eax movq 0x8(%rsp), %rbp pushq $0x3 popq %rdx shlq $0x20, %r12 movl %eax, %esi orq %r12, %rsi movq %rbx, %rdi callq 0x1bbce movq %rbx, %rdi movq %r14, %rsi movq %r15, %rdx callq 0x1bbce movq %r13, %rax movq %rbp, %rdx addq $0x38, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq movq %r13, %rax movq 0x8(%rsp), %rdx jmp 0x673f9 movq %r13, %rax movq 0x8(%rsp), %rdx xorl %r13d, %r13d movq %rcx, %rbp jmp 0x6757a
js_array_toReversed: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 38h mov rbx, rdi call JS_ToObject mov r14, rax mov r15, rdx lea rsi, [rsp+68h+var_40] mov rdi, rbx mov rdx, rax mov rcx, r15 call js_get_length64 push 6 pop rbp push 3 pop rdx test eax, eax jz short loc_67401 xor r12d, r12d xor eax, eax loc_673F9: xor r13d, r13d jmp loc_6757A loc_67401: mov rcx, [rsp+68h+var_40] mov rax, 100000000h cmp rcx, rax jl short loc_67433 lea rsi, aInvalidArrayLe; "invalid array length" xor r12d, r12d mov rdi, rbx xor eax, eax call JS_ThrowRangeError xor eax, eax xor r13d, r13d jmp loc_67577 loc_67433: mov [rsp+68h+var_58], rcx mov rdi, rbx call JS_NewArray mov r13, rax mov r12, rax shr r12, 20h cmp edx, 6 jnz short loc_67454 mov rax, r13 jmp short loc_673F9 loc_67454: mov [rsp+68h+var_60], rdx mov rdx, [rsp+68h+var_58] test rdx, rdx jle loc_67570 mov rdi, rbx mov rsi, r13 call expand_fast_array test eax, eax js loc_675AE mov rax, [rsp+68h+var_58] mov [r13+40h], eax lea rbp, [rax-1] mov [rsp+68h+var_48], r13 mov r13, [r13+38h] lea rdx, [rsp+68h+var_38] lea rcx, [rsp+68h+var_4C] mov rdi, r14 mov rsi, r15 call js_get_fast_array test eax, eax jz short loc_674F6 mov eax, [rsp+68h+var_4C] mov rcx, [rsp+68h+var_58] cmp rcx, rax jnz short loc_674F6 mov rax, [rsp+68h+var_38] shl rcx, 4 add rax, rcx add rax, 0FFFFFFFFFFFFFFF8h loc_674C7: test rbp, rbp js short loc_67541 mov rcx, [rax-8] mov rdx, [rax] cmp edx, 0FFFFFFF7h jb short loc_674DA inc dword ptr [rcx] loc_674DA: mov [r13+0], rcx mov [r13+8], rdx dec rbp add r13, 10h add rax, 0FFFFFFFFFFFFFFF0h jmp short loc_674C7 loc_674EF: dec rbp add r13, 10h loc_674F6: test rbp, rbp js short loc_67541 mov rdi, rbx mov rsi, r14 mov rdx, r15 mov rcx, rbp mov r8, r13 call JS_TryGetPropertyInt64 cmp eax, 0FFFFFFFFh jnz short loc_674EF jmp short loc_6752A loc_67516: and dword ptr [r13+0], 0 mov qword ptr [r13+8], 3 dec rbp add r13, 10h loc_6752A: test rbp, rbp jns short loc_67516 mov rax, [rsp+68h+var_48] mov rdx, [rsp+68h+var_60] xor r13d, r13d push 6 pop rbp jmp short loc_6757A loc_67541: mov rdi, [rsp+68h+var_58] call js_int64 mov r9, rdx push 32h ; '2' pop rcx mov rdi, rbx mov r13, [rsp+68h+var_48] mov rsi, r13 mov rdx, [rsp+68h+var_60] mov r8, rax call JS_SetProperty test eax, eax push 6 pop rcx js short loc_675BB loc_67570: xor eax, eax mov rbp, [rsp+68h+var_60] loc_67577: push 3 pop rdx loc_6757A: shl r12, 20h mov esi, eax or rsi, r12 mov rdi, rbx call JS_FreeValue mov rdi, rbx mov rsi, r14 mov rdx, r15 call JS_FreeValue mov rax, r13 mov rdx, rbp add rsp, 38h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn loc_675AE: mov rax, r13 mov rdx, [rsp+68h+var_60] jmp loc_673F9 loc_675BB: mov rax, r13 mov rdx, [rsp+68h+var_60] xor r13d, r13d mov rbp, rcx jmp short loc_6757A
unsigned long long js_array_toReversed( long long a1, long long a2, long long a3, long long a4, long long a5, long long a6, __m128 a7, __m128 a8, __m128 a9, __m128 a10, __m128 a11, __m128 a12, __m128 a13, __m128 a14) { long long v14; // r14 long long v15; // rdx long long v16; // r15 int length64; // eax long long v18; // r8 long long v19; // r9 __m128 v20; // xmm4 __m128 v21; // xmm5 long long v22; // rdx unsigned long long v23; // r12 unsigned long long v24; // rax unsigned long long v25; // r13 signed long long v26; // rbp _QWORD *v27; // r13 long long *v28; // rax _DWORD *v29; // rcx long long v30; // rdx int v31; // eax int v32; // edx char v34; // [rsp+0h] [rbp-68h] long long v35; // [rsp+8h] [rbp-60h] long long v36; // [rsp+10h] [rbp-58h] int v37; // [rsp+1Ch] [rbp-4Ch] BYREF unsigned long long v38; // [rsp+20h] [rbp-48h] long long v39; // [rsp+28h] [rbp-40h] BYREF long long v40[7]; // [rsp+30h] [rbp-38h] BYREF v14 = JS_ToObject(a1, a2, a3, a4, a5, a6, a7, a8, a9, a10, a11, a12, a13, a14); v16 = v15; length64 = js_get_length64(a1, &v39, v14, v15); v22 = 3LL; if ( !length64 ) { if ( v39 < 0x100000000LL ) { v36 = v39; v24 = JS_NewArray(a1); v25 = v24; v23 = HIDWORD(v24); if ( (_DWORD)v22 == 6 ) goto LABEL_3; v35 = v22; if ( v36 > 0 ) { if ( (int)expand_fast_array(a1, v24, v36) < 0 ) { LODWORD(v24) = v25; v22 = v35; goto LABEL_3; } *(_DWORD *)(v25 + 64) = v36; v26 = v36 - 1; v38 = v25; v27 = *(_QWORD **)(v25 + 56); if ( (unsigned int)js_get_fast_array(v14, v16, v40, &v37) && v36 == v37 ) { v28 = (long long *)(16 * v36 + v40[0] - 8); while ( v26 >= 0 ) { v29 = (_DWORD *)*(v28 - 1); v30 = *v28; if ( (unsigned int)*v28 >= 0xFFFFFFF7 ) ++*v29; *v27 = v29; v27[1] = v30; --v26; v27 += 2; v28 -= 2; } } else { while ( v26 >= 0 ) { if ( (unsigned int)JS_TryGetPropertyInt64(a1, v14, v16, v26, (long long)v27) == -1 ) { while ( v26 >= 0 ) { *(_DWORD *)v27 = 0; v27[1] = 3LL; --v26; v27 += 2; } LODWORD(v24) = v38; v22 = v35; v25 = 0LL; goto LABEL_26; } --v26; v27 += 2; } } v31 = js_int64(v36); v25 = v38; if ( (int)JS_SetProperty(a1, v38, v35, 50, v31, v32) < 0 ) { LODWORD(v24) = v25; v22 = v35; v25 = 0LL; goto LABEL_26; } } LODWORD(v24) = 0; } else { v23 = 0LL; JS_ThrowRangeError( a1, (long long)"invalid array length", 3LL, v39, v18, v19, a7, a8, a9, a10, v20, v21, a13, a14, v34); LODWORD(v24) = 0; v25 = 0LL; } v22 = 3LL; goto LABEL_26; } v23 = 0LL; LODWORD(v24) = 0; LABEL_3: v25 = 0LL; LABEL_26: JS_FreeValue(a1, (v23 << 32) | (unsigned int)v24, v22); JS_FreeValue(a1, v14, v16); return v25; }
js_array_toReversed: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x38 MOV RBX,RDI CALL 0x00124742 MOV R14,RAX MOV R15,RDX LEA RSI,[RSP + 0x28] MOV RDI,RBX MOV RDX,RAX MOV RCX,R15 CALL 0x001207f3 PUSH 0x6 POP RBP PUSH 0x3 POP RDX TEST EAX,EAX JZ 0x00167401 XOR R12D,R12D XOR EAX,EAX LAB_001673f9: XOR R13D,R13D JMP 0x0016757a LAB_00167401: MOV RCX,qword ptr [RSP + 0x28] MOV RAX,0x100000000 CMP RCX,RAX JL 0x00167433 LEA RSI,[0x189366] XOR R12D,R12D MOV RDI,RBX XOR EAX,EAX CALL 0x0011e863 XOR EAX,EAX XOR R13D,R13D JMP 0x00167577 LAB_00167433: MOV qword ptr [RSP + 0x10],RCX MOV RDI,RBX CALL 0x0011ee6b MOV R13,RAX MOV R12,RAX SHR R12,0x20 CMP EDX,0x6 JNZ 0x00167454 MOV RAX,R13 JMP 0x001673f9 LAB_00167454: MOV qword ptr [RSP + 0x8],RDX MOV RDX,qword ptr [RSP + 0x10] TEST RDX,RDX JLE 0x00167570 MOV RDI,RBX MOV RSI,R13 CALL 0x00139f55 TEST EAX,EAX JS 0x001675ae MOV RAX,qword ptr [RSP + 0x10] MOV dword ptr [R13 + 0x40],EAX LEA RBP,[RAX + -0x1] MOV qword ptr [RSP + 0x20],R13 MOV R13,qword ptr [R13 + 0x38] LEA RDX,[RSP + 0x30] LEA RCX,[RSP + 0x1c] MOV RDI,R14 MOV RSI,R15 CALL 0x0013de1c TEST EAX,EAX JZ 0x001674f6 MOV EAX,dword ptr [RSP + 0x1c] MOV RCX,qword ptr [RSP + 0x10] CMP RCX,RAX JNZ 0x001674f6 MOV RAX,qword ptr [RSP + 0x30] SHL RCX,0x4 ADD RAX,RCX ADD RAX,-0x8 LAB_001674c7: TEST RBP,RBP JS 0x00167541 MOV RCX,qword ptr [RAX + -0x8] MOV RDX,qword ptr [RAX] CMP EDX,-0x9 JC 0x001674da INC dword ptr [RCX] LAB_001674da: MOV qword ptr [R13],RCX MOV qword ptr [R13 + 0x8],RDX DEC RBP ADD R13,0x10 ADD RAX,-0x10 JMP 0x001674c7 LAB_001674ef: DEC RBP ADD R13,0x10 LAB_001674f6: TEST RBP,RBP JS 0x00167541 MOV RDI,RBX MOV RSI,R14 MOV RDX,R15 MOV RCX,RBP MOV R8,R13 CALL 0x00146238 CMP EAX,-0x1 JNZ 0x001674ef JMP 0x0016752a LAB_00167516: AND dword ptr [R13],0x0 MOV qword ptr [R13 + 0x8],0x3 DEC RBP ADD R13,0x10 LAB_0016752a: TEST RBP,RBP JNS 0x00167516 MOV RAX,qword ptr [RSP + 0x20] MOV RDX,qword ptr [RSP + 0x8] XOR R13D,R13D PUSH 0x6 POP RBP JMP 0x0016757a LAB_00167541: MOV RDI,qword ptr [RSP + 0x10] CALL 0x001245bb MOV R9,RDX PUSH 0x32 POP RCX MOV RDI,RBX MOV R13,qword ptr [RSP + 0x20] MOV RSI,R13 MOV RDX,qword ptr [RSP + 0x8] MOV R8,RAX CALL 0x00121ff6 TEST EAX,EAX PUSH 0x6 POP RCX JS 0x001675bb LAB_00167570: XOR EAX,EAX MOV RBP,qword ptr [RSP + 0x8] LAB_00167577: PUSH 0x3 POP RDX LAB_0016757a: SHL R12,0x20 MOV ESI,EAX OR RSI,R12 MOV RDI,RBX CALL 0x0011bbce MOV RDI,RBX MOV RSI,R14 MOV RDX,R15 CALL 0x0011bbce MOV RAX,R13 MOV RDX,RBP ADD RSP,0x38 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET LAB_001675ae: MOV RAX,R13 MOV RDX,qword ptr [RSP + 0x8] JMP 0x001673f9 LAB_001675bb: MOV RAX,R13 MOV RDX,qword ptr [RSP + 0x8] XOR R13D,R13D MOV RBP,RCX JMP 0x0016757a
int1 [16] js_array_toReversed(int8 param_1) { int *piVar1; int8 uVar2; int iVar3; ulong uVar5; int8 *puVar6; int8 uVar8; long lVar9; ulong uVar10; int8 *puVar11; int1 auVar12 [16]; int1 auVar13 [16]; uint local_4c; ulong local_48; ulong local_40; long local_38; int8 uVar4; int8 uVar7; auVar12 = JS_ToObject(); uVar7 = auVar12._8_8_; uVar4 = auVar12._0_8_; iVar3 = js_get_length64(param_1,&local_40,uVar4,uVar7); if (iVar3 == 0) { if ((long)local_40 < 0x100000000) { auVar12 = JS_NewArray(param_1); uVar8 = auVar12._8_8_; uVar5 = auVar12._0_8_; uVar10 = uVar5 >> 0x20; if (auVar12._8_4_ == 6) goto LAB_001673f9; auVar13 = auVar12; if (0 < (long)local_40) { iVar3 = expand_fast_array(param_1,uVar5); if (iVar3 < 0) goto LAB_001673f9; *(int *)(uVar5 + 0x40) = (int)local_40; lVar9 = local_40 - 1; puVar11 = *(int8 **)(uVar5 + 0x38); local_48 = uVar5; iVar3 = js_get_fast_array(uVar4,uVar7,&local_38,&local_4c); if ((iVar3 == 0) || (local_40 != local_4c)) { for (; -1 < lVar9; lVar9 = lVar9 + -1) { iVar3 = JS_TryGetPropertyInt64(param_1,uVar4,uVar7,lVar9,puVar11); auVar12._8_8_ = uVar8; auVar12._0_8_ = local_48; if (iVar3 == -1) goto LAB_0016752a; puVar11 = puVar11 + 2; } } else { puVar6 = (int8 *)(local_38 + local_40 * 0x10 + -8); for (; -1 < lVar9; lVar9 = lVar9 + -1) { piVar1 = (int *)puVar6[-1]; uVar2 = *puVar6; if (0xfffffff6 < (uint)uVar2) { *piVar1 = *piVar1 + 1; } *puVar11 = piVar1; puVar11[1] = uVar2; puVar11 = puVar11 + 2; puVar6 = puVar6 + -2; } } auVar13 = js_int64(local_40); auVar12._8_8_ = uVar8; auVar12._0_8_ = local_48; iVar3 = JS_SetProperty(param_1,local_48,uVar8,0x32,auVar13._0_8_,auVar13._8_8_); auVar13 = auVar12; if (iVar3 < 0) { auVar13 = ZEXT816(6) << 0x40; goto LAB_0016757a; } } } else { uVar10 = 0; JS_ThrowRangeError(param_1,"invalid array length"); auVar13 = ZEXT816(6) << 0x40; } auVar12 = ZEXT816(3) << 0x40; } else { uVar10 = 0; auVar12 = ZEXT816(3) << 0x40; LAB_001673f9: auVar13 = ZEXT816(6) << 0x40; } LAB_0016757a: JS_FreeValue(param_1,auVar12._0_8_ & 0xffffffff | uVar10 << 0x20,auVar12._8_8_); JS_FreeValue(param_1,uVar4,uVar7); return auVar13; LAB_0016752a: for (; -1 < lVar9; lVar9 = lVar9 + -1) { *(int4 *)puVar11 = 0; puVar11[1] = 3; puVar11 = puVar11 + 2; } auVar13 = ZEXT816(6) << 0x40; goto LAB_0016757a; }
31,847
AutoEncoderKL::init_params()
7CodeWizard[P]stablediffusion/vae.hpp
void init_params() { ggml_allocr* alloc = ggml_allocr_new_from_buffer(params_buffer); if (!decode_only) { quant_conv_w = ggml_new_tensor_4d(params_ctx, GGML_TYPE_F16, 1, 1, 2 * dd_config.z_channels, 2 * embed_dim); quant_conv_b = ggml_new_tensor_1d(params_ctx, GGML_TYPE_F32, 2 * embed_dim); encoder.init_params(params_ctx, alloc, wtype); } post_quant_conv_w = ggml_new_tensor_4d(params_ctx, GGML_TYPE_F16, 1, 1, embed_dim, dd_config.z_channels); post_quant_conv_b = ggml_new_tensor_1d(params_ctx, GGML_TYPE_F32, dd_config.z_channels); decoder.init_params(params_ctx, alloc, wtype); // alloc all tensors linked to this context for (struct ggml_tensor* t = ggml_get_first_tensor(params_ctx); t != NULL; t = ggml_get_next_tensor(params_ctx, t)) { if (t->data == NULL) { ggml_allocr_alloc(alloc, t); } } ggml_allocr_free(alloc); }
O0
cpp
AutoEncoderKL::init_params(): subq $0x28, %rsp movq %rdi, 0x20(%rsp) movq 0x20(%rsp), %rax movq %rax, 0x8(%rsp) movq 0x40(%rax), %rdi callq 0x165960 movq %rax, %rcx movq 0x8(%rsp), %rax movq %rcx, 0x18(%rsp) testb $0x1, 0x68(%rax) jne 0x54f96 movq 0x8(%rsp), %rax movq 0x28(%rax), %rdi movl 0x70(%rax), %ecx shll %ecx movslq %ecx, %r8 movl 0x6c(%rax), %eax shll %eax movslq %eax, %r9 movl $0x1, %esi movl $0x1, %ecx movq %rcx, %rdx callq 0x11c960 movq %rax, %rcx movq 0x8(%rsp), %rax movq %rcx, 0x98(%rax) movq 0x28(%rax), %rdi movl 0x6c(%rax), %eax shll %eax movslq %eax, %rdx xorl %esi, %esi callq 0x11c880 movq %rax, %rcx movq 0x8(%rsp), %rax movq %rcx, 0xa0(%rax) movq %rax, %rdi addq $0xb8, %rdi movq 0x28(%rax), %rsi movq 0x18(%rsp), %rdx movl 0x58(%rax), %ecx callq 0x610d0 movq 0x8(%rsp), %rax movq 0x28(%rax), %rdi movslq 0x6c(%rax), %r8 movslq 0x70(%rax), %r9 movl $0x1, %esi movl $0x1, %ecx movq %rcx, %rdx callq 0x11c960 movq %rax, %rcx movq 0x8(%rsp), %rax movq %rcx, 0xa8(%rax) movq 0x28(%rax), %rdi movslq 0x70(%rax), %rdx xorl %esi, %esi callq 0x11c880 movq %rax, %rcx movq 0x8(%rsp), %rax movq %rcx, 0xb0(%rax) movq %rax, %rdi addq $0x538, %rdi # imm = 0x538 movq 0x28(%rax), %rsi movq 0x18(%rsp), %rdx movl 0x58(%rax), %ecx callq 0x612f0 movq 0x8(%rsp), %rax movq 0x28(%rax), %rdi callq 0x11c1d0 movq %rax, 0x10(%rsp) cmpq $0x0, 0x10(%rsp) je 0x55056 movq 0x10(%rsp), %rax cmpq $0x0, 0x118(%rax) jne 0x5503a movq 0x18(%rsp), %rdi movq 0x10(%rsp), %rsi callq 0x165aa0 jmp 0x5503c movq 0x8(%rsp), %rax movq 0x28(%rax), %rdi movq 0x10(%rsp), %rsi callq 0x11c240 movq %rax, 0x10(%rsp) jmp 0x55014 movq 0x18(%rsp), %rdi callq 0x165a20 addq $0x28, %rsp retq nopw %cs:(%rax,%rax) nop
_ZN13AutoEncoderKL11init_paramsEv: sub rsp, 28h mov [rsp+28h+var_8], rdi mov rax, [rsp+28h+var_8] mov [rsp+28h+var_20], rax mov rdi, [rax+40h] call ggml_allocr_new_from_buffer mov rcx, rax mov rax, [rsp+28h+var_20] mov [rsp+28h+var_10], rcx test byte ptr [rax+68h], 1 jnz short loc_54F96 mov rax, [rsp+28h+var_20] mov rdi, [rax+28h] mov ecx, [rax+70h] shl ecx, 1 movsxd r8, ecx mov eax, [rax+6Ch] shl eax, 1 movsxd r9, eax mov esi, 1 mov ecx, 1 mov rdx, rcx call ggml_new_tensor_4d mov rcx, rax mov rax, [rsp+28h+var_20] mov [rax+98h], rcx mov rdi, [rax+28h] mov eax, [rax+6Ch] shl eax, 1 movsxd rdx, eax xor esi, esi call ggml_new_tensor_1d mov rcx, rax mov rax, [rsp+28h+var_20] mov [rax+0A0h], rcx mov rdi, rax add rdi, 0B8h mov rsi, [rax+28h] mov rdx, [rsp+28h+var_10] mov ecx, [rax+58h] call _ZN7Encoder11init_paramsEP12ggml_contextP11ggml_allocr9ggml_type; Encoder::init_params(ggml_context *,ggml_allocr *,ggml_type) loc_54F96: mov rax, [rsp+28h+var_20] mov rdi, [rax+28h] movsxd r8, dword ptr [rax+6Ch] movsxd r9, dword ptr [rax+70h] mov esi, 1 mov ecx, 1 mov rdx, rcx call ggml_new_tensor_4d mov rcx, rax mov rax, [rsp+28h+var_20] mov [rax+0A8h], rcx mov rdi, [rax+28h] movsxd rdx, dword ptr [rax+70h] xor esi, esi call ggml_new_tensor_1d mov rcx, rax mov rax, [rsp+28h+var_20] mov [rax+0B0h], rcx mov rdi, rax add rdi, 538h mov rsi, [rax+28h] mov rdx, [rsp+28h+var_10] mov ecx, [rax+58h] call _ZN7Decoder11init_paramsEP12ggml_contextP11ggml_allocr9ggml_type; Decoder::init_params(ggml_context *,ggml_allocr *,ggml_type) mov rax, [rsp+28h+var_20] mov rdi, [rax+28h] call ggml_get_first_tensor mov [rsp+28h+var_18], rax loc_55014: cmp [rsp+28h+var_18], 0 jz short loc_55056 mov rax, [rsp+28h+var_18] cmp qword ptr [rax+118h], 0 jnz short loc_5503A mov rdi, [rsp+28h+var_10] mov rsi, [rsp+28h+var_18] call ggml_allocr_alloc loc_5503A: jmp short $+2 loc_5503C: mov rax, [rsp+28h+var_20] mov rdi, [rax+28h] mov rsi, [rsp+28h+var_18] call ggml_get_next_tensor mov [rsp+28h+var_18], rax jmp short loc_55014 loc_55056: mov rdi, [rsp+28h+var_10] call ggml_allocr_free add rsp, 28h retn
long long AutoEncoderKL::init_params(AutoEncoderKL *this) { long long i; // [rsp+10h] [rbp-18h] long long v3; // [rsp+18h] [rbp-10h] v3 = ggml_allocr_new_from_buffer(*((_QWORD *)this + 8)); if ( (*((_BYTE *)this + 104) & 1) == 0 ) { *((_QWORD *)this + 19) = ggml_new_tensor_4d( *((_QWORD *)this + 5), 1LL, 1LL, 1LL, 2 * *((_DWORD *)this + 28), 2 * *((_DWORD *)this + 27)); *((_QWORD *)this + 20) = ggml_new_tensor_1d(*((_QWORD *)this + 5), 0LL, 2 * *((_DWORD *)this + 27)); Encoder::init_params((char *)this + 184, *((_QWORD *)this + 5), v3, *((unsigned int *)this + 22)); } *((_QWORD *)this + 21) = ggml_new_tensor_4d( *((_QWORD *)this + 5), 1LL, 1LL, 1LL, *((int *)this + 27), *((int *)this + 28)); *((_QWORD *)this + 22) = ggml_new_tensor_1d(*((_QWORD *)this + 5), 0LL, *((int *)this + 28)); Decoder::init_params((char *)this + 1336, *((_QWORD *)this + 5), v3, *((unsigned int *)this + 22)); for ( i = ggml_get_first_tensor(*((_QWORD *)this + 5)); i; i = ggml_get_next_tensor(*((_QWORD *)this + 5), i) ) { if ( !*(_QWORD *)(i + 280) ) ggml_allocr_alloc(v3, i); } return ggml_allocr_free(v3); }
init_params: SUB RSP,0x28 MOV qword ptr [RSP + 0x20],RDI MOV RAX,qword ptr [RSP + 0x20] MOV qword ptr [RSP + 0x8],RAX MOV RDI,qword ptr [RAX + 0x40] CALL 0x00265960 MOV RCX,RAX MOV RAX,qword ptr [RSP + 0x8] MOV qword ptr [RSP + 0x18],RCX TEST byte ptr [RAX + 0x68],0x1 JNZ 0x00154f96 MOV RAX,qword ptr [RSP + 0x8] MOV RDI,qword ptr [RAX + 0x28] MOV ECX,dword ptr [RAX + 0x70] SHL ECX,0x1 MOVSXD R8,ECX MOV EAX,dword ptr [RAX + 0x6c] SHL EAX,0x1 MOVSXD R9,EAX MOV ESI,0x1 MOV ECX,0x1 MOV RDX,RCX CALL 0x0021c960 MOV RCX,RAX MOV RAX,qword ptr [RSP + 0x8] MOV qword ptr [RAX + 0x98],RCX MOV RDI,qword ptr [RAX + 0x28] MOV EAX,dword ptr [RAX + 0x6c] SHL EAX,0x1 MOVSXD RDX,EAX XOR ESI,ESI CALL 0x0021c880 MOV RCX,RAX MOV RAX,qword ptr [RSP + 0x8] MOV qword ptr [RAX + 0xa0],RCX MOV RDI,RAX ADD RDI,0xb8 MOV RSI,qword ptr [RAX + 0x28] MOV RDX,qword ptr [RSP + 0x18] MOV ECX,dword ptr [RAX + 0x58] CALL 0x001610d0 LAB_00154f96: MOV RAX,qword ptr [RSP + 0x8] MOV RDI,qword ptr [RAX + 0x28] MOVSXD R8,dword ptr [RAX + 0x6c] MOVSXD R9,dword ptr [RAX + 0x70] MOV ESI,0x1 MOV ECX,0x1 MOV RDX,RCX CALL 0x0021c960 MOV RCX,RAX MOV RAX,qword ptr [RSP + 0x8] MOV qword ptr [RAX + 0xa8],RCX MOV RDI,qword ptr [RAX + 0x28] MOVSXD RDX,dword ptr [RAX + 0x70] XOR ESI,ESI CALL 0x0021c880 MOV RCX,RAX MOV RAX,qword ptr [RSP + 0x8] MOV qword ptr [RAX + 0xb0],RCX MOV RDI,RAX ADD RDI,0x538 MOV RSI,qword ptr [RAX + 0x28] MOV RDX,qword ptr [RSP + 0x18] MOV ECX,dword ptr [RAX + 0x58] CALL 0x001612f0 MOV RAX,qword ptr [RSP + 0x8] MOV RDI,qword ptr [RAX + 0x28] CALL 0x0021c1d0 MOV qword ptr [RSP + 0x10],RAX LAB_00155014: CMP qword ptr [RSP + 0x10],0x0 JZ 0x00155056 MOV RAX,qword ptr [RSP + 0x10] CMP qword ptr [RAX + 0x118],0x0 JNZ 0x0015503a MOV RDI,qword ptr [RSP + 0x18] MOV RSI,qword ptr [RSP + 0x10] CALL 0x00265aa0 LAB_0015503a: JMP 0x0015503c LAB_0015503c: MOV RAX,qword ptr [RSP + 0x8] MOV RDI,qword ptr [RAX + 0x28] MOV RSI,qword ptr [RSP + 0x10] CALL 0x0021c240 MOV qword ptr [RSP + 0x10],RAX JMP 0x00155014 LAB_00155056: MOV RDI,qword ptr [RSP + 0x18] CALL 0x00265a20 ADD RSP,0x28 RET
/* AutoEncoderKL::init_params() */ void __thiscall AutoEncoderKL::init_params(AutoEncoderKL *this) { int8 uVar1; int8 uVar2; long local_18; uVar1 = ggml_allocr_new_from_buffer(*(int8 *)(this + 0x40)); if (((byte)this[0x68] & 1) == 0) { uVar2 = ggml_new_tensor_4d(*(int8 *)(this + 0x28),1,1,1,(long)(*(int *)(this + 0x70) << 1) ,(long)(*(int *)(this + 0x6c) << 1)); *(int8 *)(this + 0x98) = uVar2; uVar2 = ggml_new_tensor_1d(*(int8 *)(this + 0x28),0,(long)(*(int *)(this + 0x6c) << 1)); *(int8 *)(this + 0xa0) = uVar2; Encoder::init_params ((Encoder *)(this + 0xb8),*(int8 *)(this + 0x28),uVar1, *(int4 *)(this + 0x58)); } uVar2 = ggml_new_tensor_4d(*(int8 *)(this + 0x28),1,1,1,(long)*(int *)(this + 0x6c), (long)*(int *)(this + 0x70)); *(int8 *)(this + 0xa8) = uVar2; uVar2 = ggml_new_tensor_1d(*(int8 *)(this + 0x28),0,(long)*(int *)(this + 0x70)); *(int8 *)(this + 0xb0) = uVar2; Decoder::init_params ((Decoder *)(this + 0x538),*(int8 *)(this + 0x28),uVar1, *(int4 *)(this + 0x58)); for (local_18 = ggml_get_first_tensor(*(int8 *)(this + 0x28)); local_18 != 0; local_18 = ggml_get_next_tensor(*(int8 *)(this + 0x28),local_18)) { if (*(long *)(local_18 + 0x118) == 0) { ggml_allocr_alloc(uVar1,local_18); } } ggml_allocr_free(uVar1); return; }
31,848
AutoEncoderKL::init_params()
7CodeWizard[P]stablediffusion/vae.hpp
void init_params() { ggml_allocr* alloc = ggml_allocr_new_from_buffer(params_buffer); if (!decode_only) { quant_conv_w = ggml_new_tensor_4d(params_ctx, GGML_TYPE_F16, 1, 1, 2 * dd_config.z_channels, 2 * embed_dim); quant_conv_b = ggml_new_tensor_1d(params_ctx, GGML_TYPE_F32, 2 * embed_dim); encoder.init_params(params_ctx, alloc, wtype); } post_quant_conv_w = ggml_new_tensor_4d(params_ctx, GGML_TYPE_F16, 1, 1, embed_dim, dd_config.z_channels); post_quant_conv_b = ggml_new_tensor_1d(params_ctx, GGML_TYPE_F32, dd_config.z_channels); decoder.init_params(params_ctx, alloc, wtype); // alloc all tensors linked to this context for (struct ggml_tensor* t = ggml_get_first_tensor(params_ctx); t != NULL; t = ggml_get_next_tensor(params_ctx, t)) { if (t->data == NULL) { ggml_allocr_alloc(alloc, t); } } ggml_allocr_free(alloc); }
O2
cpp
AutoEncoderKL::init_params(): pushq %r15 pushq %r14 pushq %rbx movq %rdi, %rbx movq 0x40(%rdi), %rdi callq 0x8f522 movq %rax, %r14 cmpb $0x0, 0x68(%rbx) jne 0x277da movq 0x28(%rbx), %rdi movslq 0x70(%rbx), %r8 addq %r8, %r8 movslq 0x6c(%rbx), %r9 addq %r9, %r9 pushq $0x1 popq %rsi pushq $0x1 popq %rcx movq %rcx, %rdx callq 0x68667 movq %rax, 0x98(%rbx) movq 0x28(%rbx), %rdi movslq 0x6c(%rbx), %rdx addq %rdx, %rdx xorl %esi, %esi callq 0x68616 movq %rax, 0xa0(%rbx) leaq 0xb8(%rbx), %rdi movq 0x28(%rbx), %rsi movl 0x58(%rbx), %ecx movq %r14, %rdx callq 0x2b5c0 movq 0x28(%rbx), %rdi movslq 0x6c(%rbx), %r8 movslq 0x70(%rbx), %r9 pushq $0x1 popq %rsi pushq $0x1 popq %rcx movq %rcx, %rdx callq 0x68667 movq %rax, 0xa8(%rbx) movq 0x28(%rbx), %rdi movslq 0x70(%rbx), %rdx xorl %esi, %esi callq 0x68616 movq %rax, 0xb0(%rbx) leaq 0x538(%rbx), %rdi movq 0x28(%rbx), %rsi movl 0x58(%rbx), %ecx movq %r14, %rdx callq 0x2b730 movq 0x28(%rbx), %rdi callq 0x68311 movq %rax, %r15 testq %rax, %rax je 0x2785b cmpq $0x0, 0x118(%r15) jne 0x2784d movq %r14, %rdi movq %r15, %rsi callq 0x8f58c movq 0x28(%rbx), %rdi movq %r15, %rsi callq 0x68336 jmp 0x27830 movq %r14, %rdi popq %rbx popq %r14 popq %r15 jmp 0x8f556
_ZN13AutoEncoderKL11init_paramsEv: push r15 push r14 push rbx mov rbx, rdi mov rdi, [rdi+40h] call ggml_allocr_new_from_buffer mov r14, rax cmp byte ptr [rbx+68h], 0 jnz short loc_277DA mov rdi, [rbx+28h] movsxd r8, dword ptr [rbx+70h] add r8, r8 movsxd r9, dword ptr [rbx+6Ch] add r9, r9 push 1 pop rsi push 1 pop rcx mov rdx, rcx call ggml_new_tensor_4d mov [rbx+98h], rax mov rdi, [rbx+28h] movsxd rdx, dword ptr [rbx+6Ch] add rdx, rdx xor esi, esi call ggml_new_tensor_1d mov [rbx+0A0h], rax lea rdi, [rbx+0B8h] mov rsi, [rbx+28h] mov ecx, [rbx+58h] mov rdx, r14 call _ZN7Encoder11init_paramsEP12ggml_contextP11ggml_allocr9ggml_type; Encoder::init_params(ggml_context *,ggml_allocr *,ggml_type) loc_277DA: mov rdi, [rbx+28h] movsxd r8, dword ptr [rbx+6Ch] movsxd r9, dword ptr [rbx+70h] push 1 pop rsi push 1 pop rcx mov rdx, rcx call ggml_new_tensor_4d mov [rbx+0A8h], rax mov rdi, [rbx+28h] movsxd rdx, dword ptr [rbx+70h] xor esi, esi call ggml_new_tensor_1d mov [rbx+0B0h], rax lea rdi, [rbx+538h] mov rsi, [rbx+28h] mov ecx, [rbx+58h] mov rdx, r14 call _ZN7Decoder11init_paramsEP12ggml_contextP11ggml_allocr9ggml_type; Decoder::init_params(ggml_context *,ggml_allocr *,ggml_type) mov rdi, [rbx+28h] call ggml_get_first_tensor loc_27830: mov r15, rax test rax, rax jz short loc_2785B cmp qword ptr [r15+118h], 0 jnz short loc_2784D mov rdi, r14 mov rsi, r15 call ggml_allocr_alloc loc_2784D: mov rdi, [rbx+28h] mov rsi, r15 call ggml_get_next_tensor jmp short loc_27830 loc_2785B: mov rdi, r14 pop rbx pop r14 pop r15 jmp ggml_allocr_free
long long AutoEncoderKL::init_params(AutoEncoderKL *this) { long long v1; // r14 long long i; // rax long long v3; // r15 v1 = ggml_allocr_new_from_buffer(*((_QWORD *)this + 8)); if ( !*((_BYTE *)this + 104) ) { *((_QWORD *)this + 19) = ggml_new_tensor_4d( *((_QWORD *)this + 5), 1LL, 1LL, 1LL, 2LL * *((int *)this + 28), 2LL * *((int *)this + 27)); *((_QWORD *)this + 20) = ggml_new_tensor_1d(*((_QWORD *)this + 5), 0LL, 2LL * *((int *)this + 27)); Encoder::init_params((char *)this + 184, *((_QWORD *)this + 5), v1, *((unsigned int *)this + 22)); } *((_QWORD *)this + 21) = ggml_new_tensor_4d( *((_QWORD *)this + 5), 1LL, 1LL, 1LL, *((int *)this + 27), *((int *)this + 28)); *((_QWORD *)this + 22) = ggml_new_tensor_1d(*((_QWORD *)this + 5), 0LL, *((int *)this + 28)); Decoder::init_params((char *)this + 1336, *((_QWORD *)this + 5), v1, *((unsigned int *)this + 22)); for ( i = ggml_get_first_tensor(*((_QWORD *)this + 5)); ; i = ggml_get_next_tensor(*((_QWORD *)this + 5), v3) ) { v3 = i; if ( !i ) break; if ( !*(_QWORD *)(i + 280) ) ggml_allocr_alloc(v1, i); } return ggml_allocr_free(v1); }
init_params: PUSH R15 PUSH R14 PUSH RBX MOV RBX,RDI MOV RDI,qword ptr [RDI + 0x40] CALL 0x0018f522 MOV R14,RAX CMP byte ptr [RBX + 0x68],0x0 JNZ 0x001277da MOV RDI,qword ptr [RBX + 0x28] MOVSXD R8,dword ptr [RBX + 0x70] ADD R8,R8 MOVSXD R9,dword ptr [RBX + 0x6c] ADD R9,R9 PUSH 0x1 POP RSI PUSH 0x1 POP RCX MOV RDX,RCX CALL 0x00168667 MOV qword ptr [RBX + 0x98],RAX MOV RDI,qword ptr [RBX + 0x28] MOVSXD RDX,dword ptr [RBX + 0x6c] ADD RDX,RDX XOR ESI,ESI CALL 0x00168616 MOV qword ptr [RBX + 0xa0],RAX LEA RDI,[RBX + 0xb8] MOV RSI,qword ptr [RBX + 0x28] MOV ECX,dword ptr [RBX + 0x58] MOV RDX,R14 CALL 0x0012b5c0 LAB_001277da: MOV RDI,qword ptr [RBX + 0x28] MOVSXD R8,dword ptr [RBX + 0x6c] MOVSXD R9,dword ptr [RBX + 0x70] PUSH 0x1 POP RSI PUSH 0x1 POP RCX MOV RDX,RCX CALL 0x00168667 MOV qword ptr [RBX + 0xa8],RAX MOV RDI,qword ptr [RBX + 0x28] MOVSXD RDX,dword ptr [RBX + 0x70] XOR ESI,ESI CALL 0x00168616 MOV qword ptr [RBX + 0xb0],RAX LEA RDI,[RBX + 0x538] MOV RSI,qword ptr [RBX + 0x28] MOV ECX,dword ptr [RBX + 0x58] MOV RDX,R14 CALL 0x0012b730 MOV RDI,qword ptr [RBX + 0x28] CALL 0x00168311 LAB_00127830: MOV R15,RAX TEST RAX,RAX JZ 0x0012785b CMP qword ptr [R15 + 0x118],0x0 JNZ 0x0012784d MOV RDI,R14 MOV RSI,R15 CALL 0x0018f58c LAB_0012784d: MOV RDI,qword ptr [RBX + 0x28] MOV RSI,R15 CALL 0x00168336 JMP 0x00127830 LAB_0012785b: MOV RDI,R14 POP RBX POP R14 POP R15 JMP 0x0018f556
/* AutoEncoderKL::init_params() */ void __thiscall AutoEncoderKL::init_params(AutoEncoderKL *this) { int8 uVar1; int8 uVar2; long lVar3; uVar1 = ggml_allocr_new_from_buffer(*(int8 *)(this + 0x40)); if (this[0x68] == (AutoEncoderKL)0x0) { uVar2 = ggml_new_tensor_4d(*(int8 *)(this + 0x28),1,1,1,(long)*(int *)(this + 0x70) * 2, (long)*(int *)(this + 0x6c) * 2); *(int8 *)(this + 0x98) = uVar2; uVar2 = ggml_new_tensor_1d(*(int8 *)(this + 0x28),0,(long)*(int *)(this + 0x6c) * 2); *(int8 *)(this + 0xa0) = uVar2; Encoder::init_params ((Encoder *)(this + 0xb8),*(int8 *)(this + 0x28),uVar1, *(int4 *)(this + 0x58)); } uVar2 = ggml_new_tensor_4d(*(int8 *)(this + 0x28),1,1,1,(long)*(int *)(this + 0x6c), (long)*(int *)(this + 0x70)); *(int8 *)(this + 0xa8) = uVar2; uVar2 = ggml_new_tensor_1d(*(int8 *)(this + 0x28),0,(long)*(int *)(this + 0x70)); *(int8 *)(this + 0xb0) = uVar2; Decoder::init_params ((Decoder *)(this + 0x538),*(int8 *)(this + 0x28),uVar1, *(int4 *)(this + 0x58)); for (lVar3 = ggml_get_first_tensor(*(int8 *)(this + 0x28)); lVar3 != 0; lVar3 = ggml_get_next_tensor(*(int8 *)(this + 0x28),lVar3)) { if (*(long *)(lVar3 + 0x118) == 0) { ggml_allocr_alloc(uVar1,lVar3); } } ggml_allocr_free(uVar1); return; }
31,849
AutoEncoderKL::init_params()
7CodeWizard[P]stablediffusion/vae.hpp
void init_params() { ggml_allocr* alloc = ggml_allocr_new_from_buffer(params_buffer); if (!decode_only) { quant_conv_w = ggml_new_tensor_4d(params_ctx, GGML_TYPE_F16, 1, 1, 2 * dd_config.z_channels, 2 * embed_dim); quant_conv_b = ggml_new_tensor_1d(params_ctx, GGML_TYPE_F32, 2 * embed_dim); encoder.init_params(params_ctx, alloc, wtype); } post_quant_conv_w = ggml_new_tensor_4d(params_ctx, GGML_TYPE_F16, 1, 1, embed_dim, dd_config.z_channels); post_quant_conv_b = ggml_new_tensor_1d(params_ctx, GGML_TYPE_F32, dd_config.z_channels); decoder.init_params(params_ctx, alloc, wtype); // alloc all tensors linked to this context for (struct ggml_tensor* t = ggml_get_first_tensor(params_ctx); t != NULL; t = ggml_get_next_tensor(params_ctx, t)) { if (t->data == NULL) { ggml_allocr_alloc(alloc, t); } } ggml_allocr_free(alloc); }
O3
cpp
AutoEncoderKL::init_params(): pushq %r15 pushq %r14 pushq %rbx movq %rdi, %rbx movq 0x40(%rdi), %rdi callq 0xb230d movq %rax, %r14 cmpb $0x0, 0x68(%rbx) jne 0x3f046 movq 0x28(%rbx), %rdi movslq 0x70(%rbx), %r8 addq %r8, %r8 movslq 0x6c(%rbx), %r9 addq %r9, %r9 movl $0x1, %edx movl $0x1, %ecx movl $0x1, %esi callq 0x8da20 movq %rax, 0x98(%rbx) movq 0x28(%rbx), %rdi movslq 0x6c(%rbx), %rdx addq %rdx, %rdx xorl %esi, %esi callq 0x8d9b7 movq %rax, 0xa0(%rbx) leaq 0xb8(%rbx), %rdi movq 0x28(%rbx), %rsi movl 0x58(%rbx), %ecx movq %r14, %rdx callq 0x43f44 movq 0x28(%rbx), %rdi movslq 0x6c(%rbx), %r8 movslq 0x70(%rbx), %r9 movl $0x1, %edx movl $0x1, %ecx movl $0x1, %esi callq 0x8da20 movq %rax, 0xa8(%rbx) movq 0x28(%rbx), %rdi movslq 0x70(%rbx), %rdx xorl %esi, %esi callq 0x8d9b7 movq %rax, 0xb0(%rbx) leaq 0x538(%rbx), %rdi movq 0x28(%rbx), %rsi movl 0x58(%rbx), %ecx movq %r14, %rdx callq 0x440bc movq 0x28(%rbx), %rdi callq 0x8d601 testq %rax, %rax je 0x3f0d3 movq %rax, %r15 cmpq $0x0, 0x118(%r15) jne 0x3f0bf movq %r14, %rdi movq %r15, %rsi callq 0xb240d movq 0x28(%rbx), %rdi movq %r15, %rsi callq 0x8d624 movq %rax, %r15 testq %rax, %rax jne 0x3f0aa movq %r14, %rdi popq %rbx popq %r14 popq %r15 jmp 0xb23d7
_ZN13AutoEncoderKL11init_paramsEv: push r15 push r14 push rbx mov rbx, rdi mov rdi, [rdi+40h] call ggml_allocr_new_from_buffer mov r14, rax cmp byte ptr [rbx+68h], 0 jnz short loc_3F046 mov rdi, [rbx+28h] movsxd r8, dword ptr [rbx+70h] add r8, r8 movsxd r9, dword ptr [rbx+6Ch] add r9, r9 mov edx, 1 mov ecx, 1 mov esi, 1 call ggml_new_tensor_4d mov [rbx+98h], rax mov rdi, [rbx+28h] movsxd rdx, dword ptr [rbx+6Ch] add rdx, rdx xor esi, esi call ggml_new_tensor_1d mov [rbx+0A0h], rax lea rdi, [rbx+0B8h] mov rsi, [rbx+28h] mov ecx, [rbx+58h] mov rdx, r14 call _ZN7Encoder11init_paramsEP12ggml_contextP11ggml_allocr9ggml_type; Encoder::init_params(ggml_context *,ggml_allocr *,ggml_type) loc_3F046: mov rdi, [rbx+28h] movsxd r8, dword ptr [rbx+6Ch] movsxd r9, dword ptr [rbx+70h] mov edx, 1 mov ecx, 1 mov esi, 1 call ggml_new_tensor_4d mov [rbx+0A8h], rax mov rdi, [rbx+28h] movsxd rdx, dword ptr [rbx+70h] xor esi, esi call ggml_new_tensor_1d mov [rbx+0B0h], rax lea rdi, [rbx+538h] mov rsi, [rbx+28h] mov ecx, [rbx+58h] mov rdx, r14 call _ZN7Decoder11init_paramsEP12ggml_contextP11ggml_allocr9ggml_type; Decoder::init_params(ggml_context *,ggml_allocr *,ggml_type) mov rdi, [rbx+28h] call ggml_get_first_tensor test rax, rax jz short loc_3F0D3 mov r15, rax loc_3F0AA: cmp qword ptr [r15+118h], 0 jnz short loc_3F0BF mov rdi, r14 mov rsi, r15 call ggml_allocr_alloc loc_3F0BF: mov rdi, [rbx+28h] mov rsi, r15 call ggml_get_next_tensor mov r15, rax test rax, rax jnz short loc_3F0AA loc_3F0D3: mov rdi, r14 pop rbx pop r14 pop r15 jmp ggml_allocr_free
long long AutoEncoderKL::init_params(AutoEncoderKL *this) { long long v1; // r14 long long first_tensor; // rax long long next_tensor; // r15 v1 = ggml_allocr_new_from_buffer(*((_QWORD *)this + 8)); if ( !*((_BYTE *)this + 104) ) { *((_QWORD *)this + 19) = ggml_new_tensor_4d( *((_QWORD *)this + 5), 1LL, 1LL, 1LL, 2LL * *((int *)this + 28), 2LL * *((int *)this + 27)); *((_QWORD *)this + 20) = ggml_new_tensor_1d(*((_QWORD *)this + 5), 0LL, 2LL * *((int *)this + 27)); Encoder::init_params((char *)this + 184, *((_QWORD *)this + 5), v1, *((unsigned int *)this + 22)); } *((_QWORD *)this + 21) = ggml_new_tensor_4d( *((_QWORD *)this + 5), 1LL, 1LL, 1LL, *((int *)this + 27), *((int *)this + 28)); *((_QWORD *)this + 22) = ggml_new_tensor_1d(*((_QWORD *)this + 5), 0LL, *((int *)this + 28)); Decoder::init_params((char *)this + 1336, *((_QWORD *)this + 5), v1, *((unsigned int *)this + 22)); first_tensor = ggml_get_first_tensor(*((_QWORD *)this + 5)); if ( first_tensor ) { next_tensor = first_tensor; do { if ( !*(_QWORD *)(next_tensor + 280) ) ggml_allocr_alloc(v1, next_tensor); next_tensor = ggml_get_next_tensor(*((_QWORD *)this + 5), next_tensor); } while ( next_tensor ); } return ggml_allocr_free(v1); }
31,850
write_hook_for_undo_key_insert
eloqsql/storage/maria/ma_key_recover.c
my_bool write_hook_for_undo_key_insert(enum translog_record_type type, TRN *trn, MARIA_HA *tbl_info, LSN *lsn, void *hook_arg) { struct st_msg_to_write_hook_for_undo_key *msg= (struct st_msg_to_write_hook_for_undo_key *) hook_arg; MARIA_SHARE *share= tbl_info->s; if (msg->auto_increment > 0) { /* Only reason to set it here is to have a mutex protect from checkpoint reading at the same time (would see a corrupted value). The purpose of the following code is to set auto_increment if the row has a with auto_increment value higher than the current one. We also want to be able to restore the old value, in case of rollback, if no one else has tried to set the value. The logic used is that we only restore the auto_increment value if tbl_info->last_auto_increment == share->last_auto_increment when it's time to do the rollback. */ DBUG_PRINT("info",("auto_inc: %lu new auto_inc: %lu", (ulong)share->state.auto_increment, (ulong)msg->auto_increment)); if (share->state.auto_increment < msg->auto_increment) { /* Remember the original value, in case of rollback */ tbl_info->last_auto_increment= share->last_auto_increment= share->state.auto_increment; share->state.auto_increment= msg->auto_increment; } else { /* If the current value would have affected the original auto_increment value, set it to an impossible value so that it's not restored on rollback */ if (msg->auto_increment > share->last_auto_increment) share->last_auto_increment= ~(ulonglong) 0; } } return write_hook_for_undo_key(type, trn, tbl_info, lsn, hook_arg); }
O0
c
write_hook_for_undo_key_insert: pushq %rbp movq %rsp, %rbp subq $0x40, %rsp movl %edi, -0x4(%rbp) movq %rsi, -0x10(%rbp) movq %rdx, -0x18(%rbp) movq %rcx, -0x20(%rbp) movq %r8, -0x28(%rbp) movq -0x28(%rbp), %rax movq %rax, -0x30(%rbp) movq -0x18(%rbp), %rax movq (%rax), %rax movq %rax, -0x38(%rbp) movq -0x30(%rbp), %rax cmpq $0x0, 0x18(%rax) jbe 0x7afe0 jmp 0x7af6b jmp 0x7af6d movq -0x38(%rbp), %rax movq 0xd8(%rax), %rax movq -0x30(%rbp), %rcx cmpq 0x18(%rcx), %rax jae 0x7afb8 movq -0x38(%rbp), %rax movq 0xd8(%rax), %rcx movq -0x38(%rbp), %rax movq %rcx, 0x610(%rax) movq -0x18(%rbp), %rax movq %rcx, 0x3e8(%rax) movq -0x30(%rbp), %rax movq 0x18(%rax), %rcx movq -0x38(%rbp), %rax movq %rcx, 0xd8(%rax) jmp 0x7afde movq -0x30(%rbp), %rax movq 0x18(%rax), %rax movq -0x38(%rbp), %rcx cmpq 0x610(%rcx), %rax jbe 0x7afdc movq -0x38(%rbp), %rax movq $-0x1, 0x610(%rax) jmp 0x7afde jmp 0x7afe0 movl -0x4(%rbp), %edi movq -0x10(%rbp), %rsi movq -0x18(%rbp), %rdx movq -0x20(%rbp), %rcx movq -0x28(%rbp), %r8 callq 0x7aea0 addq $0x40, %rsp popq %rbp retq nop
write_hook_for_undo_key_insert: push rbp mov rbp, rsp sub rsp, 40h mov [rbp+var_4], edi mov [rbp+var_10], rsi mov [rbp+var_18], rdx mov [rbp+var_20], rcx mov [rbp+var_28], r8 mov rax, [rbp+var_28] mov [rbp+var_30], rax mov rax, [rbp+var_18] mov rax, [rax] mov [rbp+var_38], rax mov rax, [rbp+var_30] cmp qword ptr [rax+18h], 0 jbe short loc_7AFE0 jmp short $+2 loc_7AF6B: jmp short $+2 loc_7AF6D: mov rax, [rbp+var_38] mov rax, [rax+0D8h] mov rcx, [rbp+var_30] cmp rax, [rcx+18h] jnb short loc_7AFB8 mov rax, [rbp+var_38] mov rcx, [rax+0D8h] mov rax, [rbp+var_38] mov [rax+610h], rcx mov rax, [rbp+var_18] mov [rax+3E8h], rcx mov rax, [rbp+var_30] mov rcx, [rax+18h] mov rax, [rbp+var_38] mov [rax+0D8h], rcx jmp short loc_7AFDE loc_7AFB8: mov rax, [rbp+var_30] mov rax, [rax+18h] mov rcx, [rbp+var_38] cmp rax, [rcx+610h] jbe short loc_7AFDC mov rax, [rbp+var_38] mov qword ptr [rax+610h], 0FFFFFFFFFFFFFFFFh loc_7AFDC: jmp short $+2 loc_7AFDE: jmp short $+2 loc_7AFE0: mov edi, [rbp+var_4] mov rsi, [rbp+var_10] mov rdx, [rbp+var_18] mov rcx, [rbp+var_20] mov r8, [rbp+var_28] call write_hook_for_undo_key add rsp, 40h pop rbp retn
long long write_hook_for_undo_key_insert(unsigned int a1, long long a2, long long *a3, long long a4, long long a5) { long long v5; // rcx long long v7; // [rsp+8h] [rbp-38h] v7 = *a3; if ( *(_QWORD *)(a5 + 24) ) { if ( *(_QWORD *)(v7 + 216) >= *(_QWORD *)(a5 + 24) ) { if ( *(_QWORD *)(a5 + 24) > *(_QWORD *)(v7 + 1552) ) *(_QWORD *)(v7 + 1552) = -1LL; } else { v5 = *(_QWORD *)(v7 + 216); *(_QWORD *)(v7 + 1552) = v5; a3[125] = v5; *(_QWORD *)(v7 + 216) = *(_QWORD *)(a5 + 24); } } return write_hook_for_undo_key(a1, a2, (long long)a3, a4, a5); }
write_hook_for_undo_key_insert: PUSH RBP MOV RBP,RSP SUB RSP,0x40 MOV dword ptr [RBP + -0x4],EDI MOV qword ptr [RBP + -0x10],RSI MOV qword ptr [RBP + -0x18],RDX MOV qword ptr [RBP + -0x20],RCX MOV qword ptr [RBP + -0x28],R8 MOV RAX,qword ptr [RBP + -0x28] MOV qword ptr [RBP + -0x30],RAX MOV RAX,qword ptr [RBP + -0x18] MOV RAX,qword ptr [RAX] MOV qword ptr [RBP + -0x38],RAX MOV RAX,qword ptr [RBP + -0x30] CMP qword ptr [RAX + 0x18],0x0 JBE 0x0017afe0 JMP 0x0017af6b LAB_0017af6b: JMP 0x0017af6d LAB_0017af6d: MOV RAX,qword ptr [RBP + -0x38] MOV RAX,qword ptr [RAX + 0xd8] MOV RCX,qword ptr [RBP + -0x30] CMP RAX,qword ptr [RCX + 0x18] JNC 0x0017afb8 MOV RAX,qword ptr [RBP + -0x38] MOV RCX,qword ptr [RAX + 0xd8] MOV RAX,qword ptr [RBP + -0x38] MOV qword ptr [RAX + 0x610],RCX MOV RAX,qword ptr [RBP + -0x18] MOV qword ptr [RAX + 0x3e8],RCX MOV RAX,qword ptr [RBP + -0x30] MOV RCX,qword ptr [RAX + 0x18] MOV RAX,qword ptr [RBP + -0x38] MOV qword ptr [RAX + 0xd8],RCX JMP 0x0017afde LAB_0017afb8: MOV RAX,qword ptr [RBP + -0x30] MOV RAX,qword ptr [RAX + 0x18] MOV RCX,qword ptr [RBP + -0x38] CMP RAX,qword ptr [RCX + 0x610] JBE 0x0017afdc MOV RAX,qword ptr [RBP + -0x38] MOV qword ptr [RAX + 0x610],-0x1 LAB_0017afdc: JMP 0x0017afde LAB_0017afde: JMP 0x0017afe0 LAB_0017afe0: MOV EDI,dword ptr [RBP + -0x4] MOV RSI,qword ptr [RBP + -0x10] MOV RDX,qword ptr [RBP + -0x18] MOV RCX,qword ptr [RBP + -0x20] MOV R8,qword ptr [RBP + -0x28] CALL 0x0017aea0 ADD RSP,0x40 POP RBP RET
void write_hook_for_undo_key_insert (int4 param_1,int8 param_2,long *param_3,int8 param_4,long param_5) { long lVar1; lVar1 = *param_3; if (*(long *)(param_5 + 0x18) != 0) { if (*(ulong *)(lVar1 + 0xd8) < *(ulong *)(param_5 + 0x18)) { *(long *)(lVar1 + 0x610) = *(long *)(lVar1 + 0xd8); param_3[0x7d] = *(long *)(lVar1 + 0xd8); *(int8 *)(lVar1 + 0xd8) = *(int8 *)(param_5 + 0x18); } else if (*(ulong *)(lVar1 + 0x610) < *(ulong *)(param_5 + 0x18)) { *(int8 *)(lVar1 + 0x610) = 0xffffffffffffffff; } } write_hook_for_undo_key(param_1,param_2,param_3,param_4,param_5); return; }
31,851
mi_rec_pack
eloqsql/storage/myisam/mi_dynrec.c
uint _mi_rec_pack(MI_INFO *info, register uchar *to, register const uchar *from) { uint length,new_length,flag,bit,i; uchar *pos,*end,*startpos,*packpos; enum en_fieldtype type; reg3 MI_COLUMNDEF *rec; MI_BLOB *blob; DBUG_ENTER("_mi_rec_pack"); flag=0 ; bit=1; startpos=packpos=to; to+= info->s->base.pack_bits; blob=info->blobs; rec=info->s->rec; for (i=info->s->base.fields ; i-- > 0; from+= length,rec++) { length=(uint) rec->length; if ((type = (enum en_fieldtype) rec->type) != FIELD_NORMAL) { if (type == FIELD_BLOB) { if (!blob->length) flag|=bit; else { char *temp_pos; size_t tmp_length=length-portable_sizeof_char_ptr; memcpy((uchar*) to,from,tmp_length); memcpy(&temp_pos,from+tmp_length,sizeof(char*)); memcpy(to+tmp_length,temp_pos,(size_t) blob->length); to+=tmp_length+blob->length; } blob++; } else if (type == FIELD_SKIP_ZERO) { if (memcmp((uchar*) from,zero_string,length) == 0) flag|=bit; else { memcpy((uchar*) to,from,(size_t) length); to+=length; } } else if (type == FIELD_SKIP_ENDSPACE || type == FIELD_SKIP_PRESPACE) { pos= (uchar*) from; end= (uchar*) from + length; if (type == FIELD_SKIP_ENDSPACE) { /* Pack trailing spaces */ while (end > from && *(end-1) == ' ') end--; } else { /* Pack pref-spaces */ while (pos < end && *pos == ' ') pos++; } new_length=(uint) (end-pos); if (new_length + 1 + MY_TEST(rec->length > 255 && new_length > 127) < length) { if (rec->length > 255 && new_length > 127) { to[0]= (uchar) ((new_length & 127) + 128); to[1]= (uchar) (new_length >> 7); to+=2; } else *to++= (uchar) new_length; memcpy((uchar*) to,pos,(size_t) new_length); to+=new_length; flag|=bit; } else { memcpy(to,from,(size_t) length); to+=length; } } else if (type == FIELD_VARCHAR) { uint pack_length= HA_VARCHAR_PACKLENGTH(rec->length -1); uint tmp_length; if (pack_length == 1) { tmp_length= (uint) *(uchar*) from; *to++= *from; } else { tmp_length= uint2korr(from); store_key_length_inc(to,tmp_length); } memcpy(to, from+pack_length,tmp_length); to+= tmp_length; continue; } else { memcpy(to,from,(size_t) length); to+=length; continue; /* Normal field */ } if ((bit= bit << 1) >= 256) { *packpos++= (uchar) flag; bit=1; flag=0; } } else { memcpy(to,from,(size_t) length); to+=length; } } if (bit != 1) *packpos= (uchar) flag; if (info->s->calc_checksum) *to++= (uchar) info->checksum; DBUG_PRINT("exit",("packed length: %d",(int) (to-startpos))); DBUG_RETURN((uint) (to-startpos)); }
O3
c
mi_rec_pack: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x48, %rsp movq (%rdi), %rax movl 0x168(%rax), %r13d movl 0x18c(%rax), %ebx addq %rsi, %rbx testl %r13d, %r13d je 0x786c9 movq %rdx, %r12 movq 0x230(%rax), %r15 movq 0x48(%rdi), %rdx movq %rsi, -0x58(%rbp) movq %rsi, -0x50(%rbp) movq %rdi, -0x48(%rbp) movl $0x1, -0x30(%rbp) movl $0x0, -0x2c(%rbp) decl %r13d movzwl 0x4(%r15), %r8d movl (%r15), %ecx testl %ecx, %ecx je 0x78485 cmpl $0x3, %ecx je 0x7844e cmpl $0x4, %ecx jne 0x784b5 cmpq $0x0, 0x10(%rdx) je 0x7852c movl %r13d, -0x3c(%rbp) movq %rbx, %r13 leal -0x8(%r8), %ebx movq %r13, %rdi movq %r12, %rsi movq %rdx, %r14 movq %rbx, %rdx movq %r8, -0x60(%rbp) callq 0x29080 movq (%r12,%rbx), %rsi leaq (%rbx,%r13), %rdi movq 0x10(%r14), %rdx callq 0x29080 movq -0x60(%rbp), %r8 movq %r14, %rdx addq 0x10(%r14), %rbx addq %rbx, %r13 movq %r13, %rbx movl -0x3c(%rbp), %r13d jmp 0x78535 movq %rdx, -0x38(%rbp) movq %r12, %rdi leaq 0xb890d4(%rip), %rsi # 0xc01530 movq %r8, %rdx movq %r8, %r14 callq 0x29560 testl %eax, %eax je 0x7851a movq %rbx, %rdi movq %r12, %rsi movq %r14, %rdx callq 0x29080 addq %r14, %rbx jmp 0x78523 movq %rbx, %rdi movq %r12, %rsi movq %rbx, -0x68(%rbp) movq %rdx, %rbx movq %r8, %rdx movl %r13d, %r14d movq %r8, %r13 callq 0x29080 movq %r13, %r8 movl %r14d, %r13d movq %rbx, %rdx movq -0x68(%rbp), %rbx addq %r8, %rbx jmp 0x7854c cmpl $0x2, %ecx ja 0x784e5 leaq (%r12,%r8), %rax cmpl $0x1, %ecx movq %rdx, -0x38(%rbp) jne 0x78561 movq %rax, %rcx cmpq %r12, %rax jbe 0x784dd leaq -0x1(%rcx), %rax cmpb $0x20, -0x1(%rcx) je 0x784cb movq %rcx, %rax jmp 0x78578 cmpl $0x8, %ecx jne 0x785ea cmpl $0x100, %r8d # imm = 0x100 movl %r13d, -0x3c(%rbp) movq %rdx, -0x38(%rbp) ja 0x78634 movq %r8, %r14 movzbl (%r12), %eax movb %al, (%rbx) incq %rbx movl $0x1, %esi jmp 0x7865c movl -0x2c(%rbp), %eax orl -0x30(%rbp), %eax movl %eax, -0x2c(%rbp) movq -0x38(%rbp), %rdx movq %r14, %r8 jmp 0x78539 movl -0x2c(%rbp), %eax orl -0x30(%rbp), %eax movl %eax, -0x2c(%rbp) addq $0x18, %rdx movl -0x30(%rbp), %eax addl %eax, %eax movl %eax, -0x30(%rbp) cmpl $0xff, %eax ja 0x78685 addq %r8, %r12 addq $0x30, %r15 testl %r13d, %r13d jne 0x783d7 jmp 0x786b2 movq %r12, %rsi testq %r8, %r8 je 0x78578 cmpb $0x20, (%rsi) jne 0x7857b incq %rsi cmpq %rax, %rsi jb 0x78569 jmp 0x7857b movq %r12, %rsi subq %rsi, %rax cmpl $0x100, %r8d # imm = 0x100 setae %dl cmpl $0x7f, %eax seta %cl andb %dl, %cl movzbl %cl, %edx addl %eax, %edx incl %edx cmpl %r8d, %edx jae 0x78614 movq %rbx, %rdi movl $0x1, %ebx testb %cl, %cl movq %r8, -0x60(%rbp) movl %eax, %ecx je 0x785be orb $-0x80, %cl movl %eax, %edx shrl $0x7, %edx movb %dl, 0x1(%rdi) movl $0x2, %ebx addq %rdi, %rbx movb %cl, (%rdi) movl %eax, %r14d movq %rbx, %rdi movq %r14, %rdx callq 0x29080 addq %r14, %rbx movl -0x2c(%rbp), %eax orl -0x30(%rbp), %eax movl %eax, -0x2c(%rbp) movq -0x38(%rbp), %rdx movq -0x60(%rbp), %r8 jmp 0x78539 movq %rbx, %rdi movq %r12, %rsi movq %rbx, -0x68(%rbp) movq %rdx, %rbx movq %r8, %rdx movq %r8, %r14 callq 0x29080 movq %r14, %r8 movq %rbx, %rdx movq -0x68(%rbp), %rbx addq %r14, %rbx jmp 0x7854c movq %rbx, %rdi movq %r12, %rsi movq %r8, %rdx movq %r8, %r14 callq 0x29080 movq %r14, %r8 addq %r14, %rbx movq -0x38(%rbp), %rdx jmp 0x78539 movzwl (%r12), %eax movq %r8, %r14 cmpl $0xfe, %eax ja 0x7864a movb %al, (%rbx) incq %rbx jmp 0x78657 movb $-0x1, (%rbx) movb %al, 0x2(%rbx) movb %ah, 0x1(%rbx) addq $0x3, %rbx movl $0x2, %esi movq %rbx, %r13 addq %r12, %rsi movl %eax, %ebx movq %r13, %rdi movq %rbx, %rdx callq 0x29080 addq %rbx, %r13 movq %r13, %rbx movl -0x3c(%rbp), %r13d movq -0x38(%rbp), %rdx movq %r14, %r8 jmp 0x7854c movq -0x58(%rbp), %rax movl -0x2c(%rbp), %ecx movb %cl, (%rax) incq %rax movq %rax, -0x58(%rbp) movl %r8d, %eax addq %rax, %r12 addq $0x30, %r15 testl %r13d, %r13d movq -0x50(%rbp), %rsi movq -0x48(%rbp), %rdi jne 0x783c9 jmp 0x786c9 cmpl $0x1, -0x30(%rbp) je 0x786c1 movq -0x58(%rbp), %rax movl -0x2c(%rbp), %ecx movb %cl, (%rax) movq -0x50(%rbp), %rsi movq -0x48(%rbp), %rdi movq (%rdi), %rax cmpq $0x0, 0x2c8(%rax) je 0x786e1 movb 0x1a8(%rdi), %al movb %al, (%rbx) incq %rbx subl %esi, %ebx movl %ebx, %eax addq $0x48, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
_mi_rec_pack: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx sub rsp, 48h mov rax, [rdi] mov r13d, [rax+168h] mov ebx, [rax+18Ch] add rbx, rsi test r13d, r13d jz loc_786C9 mov r12, rdx mov r15, [rax+230h] mov rdx, [rdi+48h] mov [rbp+var_58], rsi mov [rbp+var_50], rsi mov [rbp+var_48], rdi loc_783C9: mov [rbp+var_30], 1 mov [rbp+var_2C], 0 loc_783D7: dec r13d movzx r8d, word ptr [r15+4] mov ecx, [r15] test ecx, ecx jz loc_78485 cmp ecx, 3 jz short loc_7844E cmp ecx, 4 jnz loc_784B5 cmp qword ptr [rdx+10h], 0 jz loc_7852C mov [rbp+var_3C], r13d mov r13, rbx lea ebx, [r8-8] mov rdi, r13 mov rsi, r12 mov r14, rdx mov rdx, rbx mov [rbp+var_60], r8 call _memcpy mov rsi, [r12+rbx] lea rdi, [rbx+r13] mov rdx, [r14+10h] call _memcpy mov r8, [rbp+var_60] mov rdx, r14 add rbx, [r14+10h] add r13, rbx mov rbx, r13 mov r13d, [rbp+var_3C] jmp loc_78535 loc_7844E: mov [rbp+var_38], rdx mov rdi, r12 lea rsi, zero_string mov rdx, r8 mov r14, r8 call _bcmp test eax, eax jz loc_7851A mov rdi, rbx mov rsi, r12 mov rdx, r14 call _memcpy add rbx, r14 jmp loc_78523 loc_78485: mov rdi, rbx mov rsi, r12 mov [rbp+var_68], rbx mov rbx, rdx mov rdx, r8 mov r14d, r13d mov r13, r8 call _memcpy mov r8, r13 mov r13d, r14d mov rdx, rbx mov rbx, [rbp+var_68] add rbx, r8 jmp loc_7854C loc_784B5: cmp ecx, 2 ja short loc_784E5 lea rax, [r12+r8] cmp ecx, 1 mov [rbp+var_38], rdx jnz loc_78561 loc_784CB: mov rcx, rax cmp rax, r12 jbe short loc_784DD lea rax, [rcx-1] cmp byte ptr [rcx-1], 20h ; ' ' jz short loc_784CB loc_784DD: mov rax, rcx jmp loc_78578 loc_784E5: cmp ecx, 8 jnz loc_785EA cmp r8d, 100h mov [rbp+var_3C], r13d mov [rbp+var_38], rdx ja loc_78634 mov r14, r8 movzx eax, byte ptr [r12] mov [rbx], al inc rbx mov esi, 1 jmp loc_7865C loc_7851A: mov eax, [rbp+var_2C] or eax, [rbp+var_30] mov [rbp+var_2C], eax loc_78523: mov rdx, [rbp+var_38] mov r8, r14 jmp short loc_78539 loc_7852C: mov eax, [rbp+var_2C] or eax, [rbp+var_30] mov [rbp+var_2C], eax loc_78535: add rdx, 18h loc_78539: mov eax, [rbp+var_30] add eax, eax mov [rbp+var_30], eax cmp eax, 0FFh ja loc_78685 loc_7854C: add r12, r8 add r15, 30h ; '0' test r13d, r13d jnz loc_783D7 jmp loc_786B2 loc_78561: mov rsi, r12 test r8, r8 jz short loc_78578 loc_78569: cmp byte ptr [rsi], 20h ; ' ' jnz short loc_7857B inc rsi cmp rsi, rax jb short loc_78569 jmp short loc_7857B loc_78578: mov rsi, r12 loc_7857B: sub rax, rsi cmp r8d, 100h setnb dl cmp eax, 7Fh setnbe cl and cl, dl movzx edx, cl add edx, eax inc edx cmp edx, r8d jnb short loc_78614 mov rdi, rbx mov ebx, 1 test cl, cl mov [rbp+var_60], r8 mov ecx, eax jz short loc_785BE or cl, 80h mov edx, eax shr edx, 7 mov [rdi+1], dl mov ebx, 2 loc_785BE: add rbx, rdi mov [rdi], cl mov r14d, eax mov rdi, rbx mov rdx, r14 call _memcpy add rbx, r14 mov eax, [rbp+var_2C] or eax, [rbp+var_30] mov [rbp+var_2C], eax mov rdx, [rbp+var_38] mov r8, [rbp+var_60] jmp loc_78539 loc_785EA: mov rdi, rbx mov rsi, r12 mov [rbp+var_68], rbx mov rbx, rdx mov rdx, r8 mov r14, r8 call _memcpy mov r8, r14 mov rdx, rbx mov rbx, [rbp+var_68] add rbx, r14 jmp loc_7854C loc_78614: mov rdi, rbx mov rsi, r12 mov rdx, r8 mov r14, r8 call _memcpy mov r8, r14 add rbx, r14 mov rdx, [rbp+var_38] jmp loc_78539 loc_78634: movzx eax, word ptr [r12] mov r14, r8 cmp eax, 0FEh ja short loc_7864A mov [rbx], al inc rbx jmp short loc_78657 loc_7864A: mov byte ptr [rbx], 0FFh mov [rbx+2], al mov [rbx+1], ah add rbx, 3 loc_78657: mov esi, 2 loc_7865C: mov r13, rbx add rsi, r12 mov ebx, eax mov rdi, r13 mov rdx, rbx call _memcpy add r13, rbx mov rbx, r13 mov r13d, [rbp+var_3C] mov rdx, [rbp+var_38] mov r8, r14 jmp loc_7854C loc_78685: mov rax, [rbp+var_58] mov ecx, [rbp+var_2C] mov [rax], cl inc rax mov [rbp+var_58], rax mov eax, r8d add r12, rax add r15, 30h ; '0' test r13d, r13d mov rsi, [rbp+var_50] mov rdi, [rbp+var_48] jnz loc_783C9 jmp short loc_786C9 loc_786B2: cmp [rbp+var_30], 1 jz short loc_786C1 mov rax, [rbp+var_58] mov ecx, [rbp+var_2C] mov [rax], cl loc_786C1: mov rsi, [rbp+var_50] mov rdi, [rbp+var_48] loc_786C9: mov rax, [rdi] cmp qword ptr [rax+2C8h], 0 jz short loc_786E1 mov al, [rdi+1A8h] mov [rbx], al inc rbx loc_786E1: sub ebx, esi mov eax, ebx add rsp, 48h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
long long mi_rec_pack(long long a1, _BYTE *a2, char *a3) { int v3; // r13d _BYTE *v4; // rbx long long v6; // r15 long long v7; // rdx long long v8; // r8 unsigned int v9; // ecx _BYTE *v10; // r13 long long v11; // rbx long long v12; // r14 long long v13; // r14 _BYTE *v14; // rdi long long v15; // rbx int v16; // r14d long long v17; // r13 char *v18; // rax char *v19; // rcx long long v20; // r14 unsigned int v21; // eax _BYTE *v22; // rbx long long v23; // rsi char *v24; // rsi unsigned int v25; // eax bool v26; // cl _BYTE *v27; // rdi long long v28; // rbx bool v29; // zf char v30; // cl _BYTE *v31; // rbx long long v32; // r14 _BYTE *v33; // rdi long long v34; // rbx long long v35; // r14 long long v36; // r14 _BYTE *v37; // r13 long long v38; // rbx _BYTE *v40; // [rsp+8h] [rbp-68h] _BYTE *v41; // [rsp+8h] [rbp-68h] long long v42; // [rsp+10h] [rbp-60h] long long v43; // [rsp+10h] [rbp-60h] _BYTE *v44; // [rsp+18h] [rbp-58h] int v45; // [rsp+20h] [rbp-50h] long long v46; // [rsp+28h] [rbp-48h] int v47; // [rsp+34h] [rbp-3Ch] int v48; // [rsp+34h] [rbp-3Ch] long long v49; // [rsp+38h] [rbp-38h] long long v50; // [rsp+38h] [rbp-38h] long long v51; // [rsp+38h] [rbp-38h] unsigned int v52; // [rsp+40h] [rbp-30h] int v53; // [rsp+44h] [rbp-2Ch] v3 = *(_DWORD *)(*(_QWORD *)a1 + 360LL); v4 = &a2[*(unsigned int *)(*(_QWORD *)a1 + 396LL)]; if ( !v3 ) goto LABEL_48; v6 = *(_QWORD *)(*(_QWORD *)a1 + 560LL); v7 = *(_QWORD *)(a1 + 72); v44 = a2; v45 = (int)a2; v46 = a1; while ( 2 ) { v52 = 1; v53 = 0; while ( 1 ) { --v3; v8 = *(unsigned __int16 *)(v6 + 4); v9 = *(_DWORD *)v6; if ( *(_DWORD *)v6 ) break; v14 = v4; v40 = v4; v15 = v7; v16 = v3; v17 = *(unsigned __int16 *)(v6 + 4); memcpy(v14, a3, v8); v8 = v17; v3 = v16; v7 = v15; v4 = &v40[v8]; LABEL_25: a3 += v8; v6 += 48LL; if ( !v3 ) { if ( v52 != 1 ) *v44 = v53; LODWORD(a2) = v45; a1 = v46; goto LABEL_48; } } if ( v9 == 3 ) { v49 = v7; v13 = *(unsigned __int16 *)(v6 + 4); if ( (unsigned int)bcmp(a3, &zero_string, v8) ) { memcpy(v4, a3, v13); v4 += v13; } else { v53 |= v52; } v7 = v49; v8 = v13; goto LABEL_24; } if ( v9 == 4 ) { if ( *(_QWORD *)(v7 + 16) ) { v47 = v3; v10 = v4; v11 = (unsigned int)(v8 - 8); v12 = v7; v42 = *(unsigned __int16 *)(v6 + 4); memcpy(v10, a3, v11); memcpy(&v10[v11], *(_QWORD *)&a3[v11], *(_QWORD *)(v12 + 16)); v8 = v42; v7 = v12; v4 = &v10[*(_QWORD *)(v12 + 16) + v11]; v3 = v47; } else { v53 |= v52; } v7 += 24LL; goto LABEL_24; } if ( v9 > 2 ) { if ( v9 == 8 ) { v48 = v3; v51 = v7; if ( (unsigned int)v8 > 0x100 ) { v21 = *(unsigned __int16 *)a3; v20 = *(unsigned __int16 *)(v6 + 4); if ( v21 > 0xFE ) { *v4 = -1; v4[2] = v21; v4[1] = BYTE1(v21); v22 = v4 + 3; } else { *v4 = v21; v22 = v4 + 1; } v23 = 2LL; } else { v20 = *(unsigned __int16 *)(v6 + 4); v21 = (unsigned __int8)*a3; *v4 = v21; v22 = v4 + 1; v23 = 1LL; } v37 = v22; v38 = v21; memcpy(v37, &a3[v23], v21); v4 = &v37[v38]; v3 = v48; v7 = v51; v8 = v20; } else { v33 = v4; v41 = v4; v34 = v7; v35 = *(unsigned __int16 *)(v6 + 4); memcpy(v33, a3, v8); v8 = v35; v7 = v34; v4 = &v41[v35]; } goto LABEL_25; } v18 = &a3[v8]; v50 = v7; if ( v9 == 1 ) { do { v19 = v18; if ( v18 <= a3 ) break; --v18; } while ( *(v19 - 1) == 32 ); LODWORD(v18) = (_DWORD)v19; goto LABEL_31; } v24 = a3; if ( !*(_WORD *)(v6 + 4) ) { LABEL_31: v24 = a3; goto LABEL_32; } do { if ( *v24 != 32 ) break; ++v24; } while ( v24 < v18 ); LABEL_32: v25 = (_DWORD)v18 - (_DWORD)v24; v26 = (unsigned int)v8 >= 0x100 && v25 > 0x7F; if ( v25 + v26 + 1 >= (unsigned int)v8 ) { v36 = *(unsigned __int16 *)(v6 + 4); memcpy(v4, a3, v8); v8 = v36; v4 += v36; v7 = v50; } else { v27 = v4; v28 = 1LL; v29 = !v26; v43 = *(unsigned __int16 *)(v6 + 4); v30 = v25; if ( !v29 ) { v30 = v25 | 0x80; v27[1] = v25 >> 7; v28 = 2LL; } v31 = &v27[v28]; *v27 = v30; v32 = v25; memcpy(v31, v24, v25); v4 = &v31[v32]; v53 |= v52; v7 = v50; v8 = v43; } LABEL_24: v52 *= 2; if ( v52 <= 0xFF ) goto LABEL_25; *v44++ = v53; a3 += (unsigned int)v8; v6 += 48LL; LODWORD(a2) = v45; a1 = v46; if ( v3 ) continue; break; } LABEL_48: if ( *(_QWORD *)(*(_QWORD *)a1 + 712LL) ) { *v4 = *(_BYTE *)(a1 + 424); LODWORD(v4) = (_DWORD)v4 + 1; } return (unsigned int)((_DWORD)v4 - (_DWORD)a2); }
_mi_rec_pack: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x48 MOV RAX,qword ptr [RDI] MOV R13D,dword ptr [RAX + 0x168] MOV EBX,dword ptr [RAX + 0x18c] ADD RBX,RSI TEST R13D,R13D JZ 0x001786c9 MOV R12,RDX MOV R15,qword ptr [RAX + 0x230] MOV RDX,qword ptr [RDI + 0x48] MOV qword ptr [RBP + -0x58],RSI MOV qword ptr [RBP + -0x50],RSI MOV qword ptr [RBP + -0x48],RDI LAB_001783c9: MOV dword ptr [RBP + -0x30],0x1 MOV dword ptr [RBP + -0x2c],0x0 LAB_001783d7: DEC R13D MOVZX R8D,word ptr [R15 + 0x4] MOV ECX,dword ptr [R15] TEST ECX,ECX JZ 0x00178485 CMP ECX,0x3 JZ 0x0017844e CMP ECX,0x4 JNZ 0x001784b5 CMP qword ptr [RDX + 0x10],0x0 JZ 0x0017852c MOV dword ptr [RBP + -0x3c],R13D MOV R13,RBX LEA EBX,[R8 + -0x8] MOV RDI,R13 MOV RSI,R12 MOV R14,RDX MOV RDX,RBX MOV qword ptr [RBP + -0x60],R8 CALL 0x00129080 MOV RSI,qword ptr [R12 + RBX*0x1] LEA RDI,[RBX + R13*0x1] MOV RDX,qword ptr [R14 + 0x10] CALL 0x00129080 MOV R8,qword ptr [RBP + -0x60] MOV RDX,R14 ADD RBX,qword ptr [R14 + 0x10] ADD R13,RBX MOV RBX,R13 MOV R13D,dword ptr [RBP + -0x3c] JMP 0x00178535 LAB_0017844e: MOV qword ptr [RBP + -0x38],RDX MOV RDI,R12 LEA RSI,[0xd01530] MOV RDX,R8 MOV R14,R8 CALL 0x00129560 TEST EAX,EAX JZ 0x0017851a MOV RDI,RBX MOV RSI,R12 MOV RDX,R14 CALL 0x00129080 ADD RBX,R14 JMP 0x00178523 LAB_00178485: MOV RDI,RBX MOV RSI,R12 MOV qword ptr [RBP + -0x68],RBX MOV RBX,RDX MOV RDX,R8 MOV R14D,R13D MOV R13,R8 CALL 0x00129080 MOV R8,R13 MOV R13D,R14D MOV RDX,RBX MOV RBX,qword ptr [RBP + -0x68] ADD RBX,R8 JMP 0x0017854c LAB_001784b5: CMP ECX,0x2 JA 0x001784e5 LEA RAX,[R12 + R8*0x1] CMP ECX,0x1 MOV qword ptr [RBP + -0x38],RDX JNZ 0x00178561 LAB_001784cb: MOV RCX,RAX CMP RAX,R12 JBE 0x001784dd LEA RAX,[RCX + -0x1] CMP byte ptr [RCX + -0x1],0x20 JZ 0x001784cb LAB_001784dd: MOV RAX,RCX JMP 0x00178578 LAB_001784e5: CMP ECX,0x8 JNZ 0x001785ea CMP R8D,0x100 MOV dword ptr [RBP + -0x3c],R13D MOV qword ptr [RBP + -0x38],RDX JA 0x00178634 MOV R14,R8 MOVZX EAX,byte ptr [R12] MOV byte ptr [RBX],AL INC RBX MOV ESI,0x1 JMP 0x0017865c LAB_0017851a: MOV EAX,dword ptr [RBP + -0x2c] OR EAX,dword ptr [RBP + -0x30] MOV dword ptr [RBP + -0x2c],EAX LAB_00178523: MOV RDX,qword ptr [RBP + -0x38] MOV R8,R14 JMP 0x00178539 LAB_0017852c: MOV EAX,dword ptr [RBP + -0x2c] OR EAX,dword ptr [RBP + -0x30] MOV dword ptr [RBP + -0x2c],EAX LAB_00178535: ADD RDX,0x18 LAB_00178539: MOV EAX,dword ptr [RBP + -0x30] ADD EAX,EAX MOV dword ptr [RBP + -0x30],EAX CMP EAX,0xff JA 0x00178685 LAB_0017854c: ADD R12,R8 ADD R15,0x30 TEST R13D,R13D JNZ 0x001783d7 JMP 0x001786b2 LAB_00178561: MOV RSI,R12 TEST R8,R8 JZ 0x00178578 LAB_00178569: CMP byte ptr [RSI],0x20 JNZ 0x0017857b INC RSI CMP RSI,RAX JC 0x00178569 JMP 0x0017857b LAB_00178578: MOV RSI,R12 LAB_0017857b: SUB RAX,RSI CMP R8D,0x100 SETNC DL CMP EAX,0x7f SETA CL AND CL,DL MOVZX EDX,CL ADD EDX,EAX INC EDX CMP EDX,R8D JNC 0x00178614 MOV RDI,RBX MOV EBX,0x1 TEST CL,CL MOV qword ptr [RBP + -0x60],R8 MOV ECX,EAX JZ 0x001785be OR CL,0x80 MOV EDX,EAX SHR EDX,0x7 MOV byte ptr [RDI + 0x1],DL MOV EBX,0x2 LAB_001785be: ADD RBX,RDI MOV byte ptr [RDI],CL MOV R14D,EAX MOV RDI,RBX MOV RDX,R14 CALL 0x00129080 ADD RBX,R14 MOV EAX,dword ptr [RBP + -0x2c] OR EAX,dword ptr [RBP + -0x30] MOV dword ptr [RBP + -0x2c],EAX MOV RDX,qword ptr [RBP + -0x38] MOV R8,qword ptr [RBP + -0x60] JMP 0x00178539 LAB_001785ea: MOV RDI,RBX MOV RSI,R12 MOV qword ptr [RBP + -0x68],RBX MOV RBX,RDX MOV RDX,R8 MOV R14,R8 CALL 0x00129080 MOV R8,R14 MOV RDX,RBX MOV RBX,qword ptr [RBP + -0x68] ADD RBX,R14 JMP 0x0017854c LAB_00178614: MOV RDI,RBX MOV RSI,R12 MOV RDX,R8 MOV R14,R8 CALL 0x00129080 MOV R8,R14 ADD RBX,R14 MOV RDX,qword ptr [RBP + -0x38] JMP 0x00178539 LAB_00178634: MOVZX EAX,word ptr [R12] MOV R14,R8 CMP EAX,0xfe JA 0x0017864a MOV byte ptr [RBX],AL INC RBX JMP 0x00178657 LAB_0017864a: MOV byte ptr [RBX],0xff MOV byte ptr [RBX + 0x2],AL MOV byte ptr [RBX + 0x1],AH ADD RBX,0x3 LAB_00178657: MOV ESI,0x2 LAB_0017865c: MOV R13,RBX ADD RSI,R12 MOV EBX,EAX MOV RDI,R13 MOV RDX,RBX CALL 0x00129080 ADD R13,RBX MOV RBX,R13 MOV R13D,dword ptr [RBP + -0x3c] MOV RDX,qword ptr [RBP + -0x38] MOV R8,R14 JMP 0x0017854c LAB_00178685: MOV RAX,qword ptr [RBP + -0x58] MOV ECX,dword ptr [RBP + -0x2c] MOV byte ptr [RAX],CL INC RAX MOV qword ptr [RBP + -0x58],RAX MOV EAX,R8D ADD R12,RAX ADD R15,0x30 TEST R13D,R13D MOV RSI,qword ptr [RBP + -0x50] MOV RDI,qword ptr [RBP + -0x48] JNZ 0x001783c9 JMP 0x001786c9 LAB_001786b2: CMP dword ptr [RBP + -0x30],0x1 JZ 0x001786c1 MOV RAX,qword ptr [RBP + -0x58] MOV ECX,dword ptr [RBP + -0x2c] MOV byte ptr [RAX],CL LAB_001786c1: MOV RSI,qword ptr [RBP + -0x50] MOV RDI,qword ptr [RBP + -0x48] LAB_001786c9: MOV RAX,qword ptr [RDI] CMP qword ptr [RAX + 0x2c8],0x0 JZ 0x001786e1 MOV AL,byte ptr [RDI + 0x1a8] MOV byte ptr [RBX],AL INC RBX LAB_001786e1: SUB EBX,ESI MOV EAX,EBX ADD RSP,0x48 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
int _mi_rec_pack(long *param_1,int1 *param_2,ushort *param_3) { ushort uVar1; ushort *puVar2; int iVar3; uint uVar4; ulong uVar5; byte bVar7; long lVar8; byte *pbVar9; long lVar10; ushort *puVar11; uint uVar12; ulong __n; int iVar13; uint *puVar14; int1 *local_60; uint local_38; uint local_34; ushort *puVar6; lVar8 = *param_1; iVar13 = *(int *)(lVar8 + 0x168); pbVar9 = param_2 + *(uint *)(lVar8 + 0x18c); if (iVar13 == 0) { LAB_001786c9: if (*(long *)(*param_1 + 0x2c8) != 0) { *pbVar9 = *(byte *)(param_1 + 0x35); pbVar9 = pbVar9 + 1; } return (int)pbVar9 - (int)param_2; } puVar14 = *(uint **)(lVar8 + 0x230); lVar8 = param_1[9]; local_60 = param_2; LAB_001783c9: local_38 = 1; local_34 = 0; do { iVar13 = iVar13 + -1; uVar1 = (ushort)puVar14[1]; __n = (ulong)uVar1; uVar4 = *puVar14; if (uVar4 == 0) { memcpy(pbVar9,param_3,__n); pbVar9 = pbVar9 + __n; } else { if (uVar4 == 3) { iVar3 = bcmp(param_3,zero_string,__n); if (iVar3 == 0) { local_34 = local_34 | local_38; } else { memcpy(pbVar9,param_3,__n); pbVar9 = pbVar9 + __n; } } else if (uVar4 == 4) { if (*(long *)(lVar8 + 0x10) == 0) { local_34 = local_34 | local_38; } else { uVar5 = (ulong)(uVar1 - 8); memcpy(pbVar9,param_3,uVar5); memcpy(pbVar9 + uVar5,*(void **)((long)param_3 + uVar5),*(size_t *)(lVar8 + 0x10)); pbVar9 = pbVar9 + uVar5 + *(long *)(lVar8 + 0x10); } lVar8 = lVar8 + 0x18; } else { uVar12 = (uint)uVar1; if (2 < uVar4) { if (uVar4 == 8) { if (uVar12 < 0x101) { uVar4 = (uint)(byte)*param_3; *pbVar9 = (byte)*param_3; pbVar9 = pbVar9 + 1; lVar10 = 1; } else { uVar1 = *param_3; uVar4 = (uint)uVar1; if (uVar1 < 0xff) { *pbVar9 = (byte)uVar1; pbVar9 = pbVar9 + 1; } else { *pbVar9 = 0xff; pbVar9[2] = (byte)uVar1; pbVar9[1] = (byte)(uVar1 >> 8); pbVar9 = pbVar9 + 3; } lVar10 = 2; } memcpy(pbVar9,(byte *)(lVar10 + (long)param_3),(ulong)uVar4); pbVar9 = pbVar9 + uVar4; } else { memcpy(pbVar9,param_3,__n); pbVar9 = pbVar9 + __n; } goto LAB_0017854c; } puVar6 = (ushort *)((long)param_3 + __n); puVar2 = puVar6; puVar11 = param_3; if (uVar4 == 1) { do { puVar6 = puVar2; if (puVar6 <= param_3) break; puVar2 = (ushort *)((long)puVar6 + -1); } while (*(byte *)((long)puVar6 + -1) == 0x20); } else if (__n != 0) { do { if ((byte)*puVar11 != 0x20) break; puVar11 = (ushort *)((long)puVar11 + 1); } while (puVar11 < puVar6); } uVar5 = (long)puVar6 - (long)puVar11; uVar4 = (uint)uVar5; if ((0x7f < uVar4 && 0xff < uVar12) + uVar4 + 1 < uVar12) { lVar10 = 1; bVar7 = (byte)uVar5; if (0x7f < uVar4 && 0xff < uVar12) { bVar7 = bVar7 | 0x80; pbVar9[1] = (byte)(uVar5 >> 7); lVar10 = 2; } *pbVar9 = bVar7; memcpy(pbVar9 + lVar10,puVar11,uVar5 & 0xffffffff); pbVar9 = pbVar9 + lVar10 + (uVar5 & 0xffffffff); local_34 = local_34 | local_38; } else { memcpy(pbVar9,param_3,__n); pbVar9 = pbVar9 + __n; } } local_38 = local_38 * 2; if (0xff < local_38) break; } LAB_0017854c: param_3 = (ushort *)((long)param_3 + __n); puVar14 = puVar14 + 0xc; if (iVar13 == 0) { if (local_38 != 1) { *local_60 = (char)local_34; } goto LAB_001786c9; } } while( true ); *local_60 = (char)local_34; local_60 = local_60 + 1; param_3 = (ushort *)((long)param_3 + __n); puVar14 = puVar14 + 0xc; if (iVar13 == 0) goto LAB_001786c9; goto LAB_001783c9; }
31,852
find_jump_target
bluesky950520[P]quickjs/quickjs.c
static int find_jump_target(JSFunctionDef *s, int label, int *pop) { int i, pos, op; update_label(s, label, -1); for (i = 0; i < 10; i++) { assert(label >= 0 && label < s->label_count); pos = s->label_slots[label].pos2; for (;;) { switch(op = s->byte_code.buf[pos]) { case OP_source_loc: case OP_label: pos += opcode_info[op].size; continue; case OP_goto: label = get_u32(s->byte_code.buf + pos + 1); break; case OP_drop: /* ignore drop opcodes if followed by OP_return_undef */ while (s->byte_code.buf[++pos] == OP_drop) continue; if (s->byte_code.buf[pos] == OP_return_undef) op = OP_return_undef; /* fall thru */ default: goto done; } break; } } /* cycle detected, could issue a warning */ done: *pop = op; update_label(s, label, +1); return label; }
O1
c
find_jump_target: pushq %rbx movq 0x170(%rdi), %rcx movslq %esi, %rax leaq (%rax,%rax,2), %rax decl (%rcx,%rax,8) movq 0x138(%rdi), %rdi xorl %r8d, %r8d leaq 0x2eb46(%rip), %r9 # 0x9e140 movslq %esi, %rax leaq (%rax,%rax,2), %rax movl 0x8(%rcx,%rax,8), %r10d movslq %r10d, %r11 movb (%rdi,%r11), %al movzbl %al, %ebx cmpl $0xc3, %ebx jg 0x6f622 cmpl $0xb5, %ebx je 0x6f62a jmp 0x6f634 cmpl $0xc4, %ebx jne 0x6f66a movzbl (%r9,%rbx,4), %eax addl %eax, %r10d jmp 0x6f606 cmpl $0xe, %ebx je 0x6f650 cmpl $0x6b, %ebx jne 0x6f66a movl 0x1(%rdi,%r11), %esi incl %r8d cmpl $0xa, %r8d jne 0x6f5fa movb $0x6b, %al jmp 0x6f66a leaq (%rdi,%r11), %r8 incq %r8 movzbl (%r8), %edi incq %r8 cmpl $0xe, %edi je 0x6f657 cmpl $0x29, %edi jne 0x6f66a movl %edi, %eax movzbl %al, %eax movl %eax, (%rdx) movslq %esi, %rax leaq (%rax,%rax,2), %rdx incl (%rcx,%rdx,8) popq %rbx retq
find_jump_target: push rbx mov rcx, [rdi+170h] movsxd rax, esi lea rax, [rax+rax*2] dec dword ptr [rcx+rax*8] mov rdi, [rdi+138h] xor r8d, r8d lea r9, opcode_info loc_6F5FA: movsxd rax, esi lea rax, [rax+rax*2] mov r10d, [rcx+rax*8+8] loc_6F606: movsxd r11, r10d mov al, [rdi+r11] movzx ebx, al cmp ebx, 0C3h jg short loc_6F622 cmp ebx, 0B5h jz short loc_6F62A jmp short loc_6F634 loc_6F622: cmp ebx, 0C4h jnz short loc_6F66A loc_6F62A: movzx eax, byte ptr [r9+rbx*4] add r10d, eax jmp short loc_6F606 loc_6F634: cmp ebx, 0Eh jz short loc_6F650 cmp ebx, 6Bh ; 'k' jnz short loc_6F66A mov esi, [rdi+r11+1] inc r8d cmp r8d, 0Ah jnz short loc_6F5FA mov al, 6Bh ; 'k' jmp short loc_6F66A loc_6F650: lea r8, [rdi+r11] inc r8 loc_6F657: movzx edi, byte ptr [r8] inc r8 cmp edi, 0Eh jz short loc_6F657 cmp edi, 29h ; ')' jnz short loc_6F66A mov eax, edi loc_6F66A: movzx eax, al mov [rdx], eax movsxd rax, esi lea rdx, [rax+rax*2] inc dword ptr [rcx+rdx*8] pop rbx retn
long long find_jump_target(long long a1, int a2, _DWORD *a3) { long long v3; // rcx long long v4; // rdi int v5; // r8d int i; // r10d unsigned __int8 v7; // al unsigned __int8 *v8; // r8 int v9; // edi long long result; // rax v3 = *(_QWORD *)(a1 + 368); --*(_DWORD *)(v3 + 24LL * a2); v4 = *(_QWORD *)(a1 + 312); v5 = 0; while ( 2 ) { for ( i = *(_DWORD *)(v3 + 24LL * a2 + 8); ; i += opcode_info[4 * v7] ) { v7 = *(_BYTE *)(v4 + i); if ( v7 <= 0xC3u ) break; if ( v7 != 196 ) goto LABEL_16; LABEL_7: ; } switch ( v7 ) { case 0xB5u: goto LABEL_7; case 0xEu: v8 = (unsigned __int8 *)(v4 + i + 1); do v9 = *v8++; while ( v9 == 14 ); if ( v9 == 41 ) v7 = 41; break; case 0x6Bu: a2 = *(_DWORD *)(v4 + i + 1); if ( ++v5 == 10 ) { v7 = 107; break; } continue; } break; } LABEL_16: *a3 = v7; result = a2; ++*(_DWORD *)(v3 + 24LL * a2); return result; }
find_jump_target: PUSH RBX MOV RCX,qword ptr [RDI + 0x170] MOVSXD RAX,ESI LEA RAX,[RAX + RAX*0x2] DEC dword ptr [RCX + RAX*0x8] MOV RDI,qword ptr [RDI + 0x138] XOR R8D,R8D LEA R9,[0x19e140] LAB_0016f5fa: MOVSXD RAX,ESI LEA RAX,[RAX + RAX*0x2] MOV R10D,dword ptr [RCX + RAX*0x8 + 0x8] LAB_0016f606: MOVSXD R11,R10D MOV AL,byte ptr [RDI + R11*0x1] MOVZX EBX,AL CMP EBX,0xc3 JG 0x0016f622 CMP EBX,0xb5 JZ 0x0016f62a JMP 0x0016f634 LAB_0016f622: CMP EBX,0xc4 JNZ 0x0016f66a LAB_0016f62a: MOVZX EAX,byte ptr [R9 + RBX*0x4] ADD R10D,EAX JMP 0x0016f606 LAB_0016f634: CMP EBX,0xe JZ 0x0016f650 CMP EBX,0x6b JNZ 0x0016f66a MOV ESI,dword ptr [RDI + R11*0x1 + 0x1] INC R8D CMP R8D,0xa JNZ 0x0016f5fa MOV AL,0x6b JMP 0x0016f66a LAB_0016f650: LEA R8,[RDI + R11*0x1] INC R8 LAB_0016f657: MOVZX EDI,byte ptr [R8] INC R8 CMP EDI,0xe JZ 0x0016f657 CMP EDI,0x29 JNZ 0x0016f66a MOV EAX,EDI LAB_0016f66a: MOVZX EAX,AL MOV dword ptr [RDX],EAX MOVSXD RAX,ESI LEA RDX,[RAX + RAX*0x2] INC dword ptr [RCX + RDX*0x8] POP RBX RET
void find_jump_target(long param_1,int param_2,uint *param_3) { int *piVar1; long lVar2; long lVar3; byte bVar4; int iVar5; char *pcVar6; int iVar7; long lVar8; lVar2 = *(long *)(param_1 + 0x170); piVar1 = (int *)(lVar2 + (long)param_2 * 0x18); *piVar1 = *piVar1 + -1; lVar3 = *(long *)(param_1 + 0x138); iVar5 = 0; LAB_0016f5fa: iVar7 = *(int *)(lVar2 + 8 + (long)param_2 * 0x18); do { lVar8 = (long)iVar7; bVar4 = *(byte *)(lVar3 + lVar8); if (bVar4 < 0xc4) { if (bVar4 != 0xb5) goto LAB_0016f634; } else if (bVar4 != 0xc4) goto LAB_0016f66a; iVar7 = iVar7 + (uint)(byte)opcode_info[(ulong)bVar4 * 4]; } while( true ); code_r0x0016f64c: bVar4 = 0x6b; goto LAB_0016f66a; LAB_0016f634: if (bVar4 != 0xe) { if (bVar4 != 0x6b) goto LAB_0016f66a; param_2 = *(int *)(lVar3 + 1 + lVar8); iVar5 = iVar5 + 1; if (iVar5 == 10) goto code_r0x0016f64c; goto LAB_0016f5fa; } pcVar6 = (char *)(lVar3 + lVar8); do { pcVar6 = pcVar6 + 1; } while (*pcVar6 == '\x0e'); if (*pcVar6 == ')') { bVar4 = 0x29; } LAB_0016f66a: *param_3 = (uint)bVar4; piVar1 = (int *)(lVar2 + (long)param_2 * 0x18); *piVar1 = *piVar1 + 1; return; }
31,853
find_jump_target
bluesky950520[P]quickjs/quickjs.c
static int find_jump_target(JSFunctionDef *s, int label, int *pop) { int i, pos, op; update_label(s, label, -1); for (i = 0; i < 10; i++) { assert(label >= 0 && label < s->label_count); pos = s->label_slots[label].pos2; for (;;) { switch(op = s->byte_code.buf[pos]) { case OP_source_loc: case OP_label: pos += opcode_info[op].size; continue; case OP_goto: label = get_u32(s->byte_code.buf + pos + 1); break; case OP_drop: /* ignore drop opcodes if followed by OP_return_undef */ while (s->byte_code.buf[++pos] == OP_drop) continue; if (s->byte_code.buf[pos] == OP_return_undef) op = OP_return_undef; /* fall thru */ default: goto done; } break; } } /* cycle detected, could issue a warning */ done: *pop = op; update_label(s, label, +1); return label; }
O2
c
find_jump_target: pushq %rbx movq 0x170(%rdi), %rcx movslq %esi, %rax imulq $0x18, %rax, %rax decl (%rcx,%rax) movq 0x138(%rdi), %r8 xorl %r9d, %r9d movl $0x6b, %edi leaq 0x2766f(%rip), %r10 # 0x850e0 movslq %esi, %rax cmpl $0xa, %r9d je 0x5dae2 imulq $0x18, %rax, %rsi movl 0x8(%rcx,%rsi), %ebx movslq %ebx, %rsi movzbl (%r8,%rsi), %r11d cmpl $0xb5, %r11d je 0x5da9c cmpl $0xc4, %r11d jne 0x5daa5 movzbl (%r10,%r11,4), %esi addl %esi, %ebx jmp 0x5da82 cmpl $0x6b, %r11d jne 0x5dab5 movl 0x1(%r8,%rsi), %esi incl %r9d jmp 0x5da71 cmpl $0xe, %r11d jne 0x5dad8 addq %r8, %rsi incq %rsi movzbl (%rsi), %edi incq %rsi cmpl $0xe, %edi je 0x5dac1 cmpl $0x29, %edi jne 0x5dadd movl $0x29, %edi jmp 0x5dae2 movl %r11d, %edi jmp 0x5dae2 movl $0xe, %edi movl %edi, (%rdx) imulq $0x18, %rax, %rdx incl (%rcx,%rdx) popq %rbx retq
find_jump_target: push rbx mov rcx, [rdi+170h] movsxd rax, esi imul rax, 18h dec dword ptr [rcx+rax] mov r8, [rdi+138h] xor r9d, r9d mov edi, 6Bh ; 'k' lea r10, opcode_info loc_5DA71: movsxd rax, esi cmp r9d, 0Ah jz short loc_5DAE2 imul rsi, rax, 18h mov ebx, [rcx+rsi+8] loc_5DA82: movsxd rsi, ebx movzx r11d, byte ptr [r8+rsi] cmp r11d, 0B5h jz short loc_5DA9C cmp r11d, 0C4h jnz short loc_5DAA5 loc_5DA9C: movzx esi, byte ptr [r10+r11*4] add ebx, esi jmp short loc_5DA82 loc_5DAA5: cmp r11d, 6Bh ; 'k' jnz short loc_5DAB5 mov esi, [r8+rsi+1] inc r9d jmp short loc_5DA71 loc_5DAB5: cmp r11d, 0Eh jnz short loc_5DAD8 add rsi, r8 inc rsi loc_5DAC1: movzx edi, byte ptr [rsi] inc rsi cmp edi, 0Eh jz short loc_5DAC1 cmp edi, 29h ; ')' jnz short loc_5DADD mov edi, 29h ; ')' jmp short loc_5DAE2 loc_5DAD8: mov edi, r11d jmp short loc_5DAE2 loc_5DADD: mov edi, 0Eh loc_5DAE2: mov [rdx], edi imul rdx, rax, 18h inc dword ptr [rcx+rdx] pop rbx retn
long long find_jump_target(long long a1, int a2, int *a3) { long long v3; // rcx long long v4; // r8 int v5; // r9d int v6; // edi long long result; // rax int i; // ebx long long v9; // r11 unsigned __int8 *v10; // rsi int v11; // edi v3 = *(_QWORD *)(a1 + 368); --*(_DWORD *)(v3 + 24LL * a2); v4 = *(_QWORD *)(a1 + 312); v5 = 0; v6 = 107; while ( 1 ) { result = a2; if ( v5 == 10 ) break; for ( i = *(_DWORD *)(v3 + 24LL * a2 + 8); ; i += opcode_info[4 * v9] ) { v9 = *(unsigned __int8 *)(v4 + i); if ( (_DWORD)v9 != 181 && (_DWORD)v9 != 196 ) break; } if ( (_DWORD)v9 != 107 ) { if ( (_DWORD)v9 == 14 ) { v10 = (unsigned __int8 *)(v4 + i + 1); do v11 = *v10++; while ( v11 == 14 ); if ( v11 == 41 ) v6 = 41; else v6 = 14; } else { v6 = *(unsigned __int8 *)(v4 + i); } break; } a2 = *(_DWORD *)(v4 + i + 1); ++v5; } *a3 = v6; ++*(_DWORD *)(v3 + 24 * result); return result; }
find_jump_target: PUSH RBX MOV RCX,qword ptr [RDI + 0x170] MOVSXD RAX,ESI IMUL RAX,RAX,0x18 DEC dword ptr [RCX + RAX*0x1] MOV R8,qword ptr [RDI + 0x138] XOR R9D,R9D MOV EDI,0x6b LEA R10,[0x1850e0] LAB_0015da71: MOVSXD RAX,ESI CMP R9D,0xa JZ 0x0015dae2 IMUL RSI,RAX,0x18 MOV EBX,dword ptr [RCX + RSI*0x1 + 0x8] LAB_0015da82: MOVSXD RSI,EBX MOVZX R11D,byte ptr [R8 + RSI*0x1] CMP R11D,0xb5 JZ 0x0015da9c CMP R11D,0xc4 JNZ 0x0015daa5 LAB_0015da9c: MOVZX ESI,byte ptr [R10 + R11*0x4] ADD EBX,ESI JMP 0x0015da82 LAB_0015daa5: CMP R11D,0x6b JNZ 0x0015dab5 MOV ESI,dword ptr [R8 + RSI*0x1 + 0x1] INC R9D JMP 0x0015da71 LAB_0015dab5: CMP R11D,0xe JNZ 0x0015dad8 ADD RSI,R8 INC RSI LAB_0015dac1: MOVZX EDI,byte ptr [RSI] INC RSI CMP EDI,0xe JZ 0x0015dac1 CMP EDI,0x29 JNZ 0x0015dadd MOV EDI,0x29 JMP 0x0015dae2 LAB_0015dad8: MOV EDI,R11D JMP 0x0015dae2 LAB_0015dadd: MOV EDI,0xe LAB_0015dae2: MOV dword ptr [RDX],EDI IMUL RDX,RAX,0x18 INC dword ptr [RCX + RDX*0x1] POP RBX RET
void find_jump_target(long param_1,int param_2,uint *param_3) { int *piVar1; byte bVar2; long lVar3; long lVar4; int iVar5; long lVar6; char *pcVar7; int iVar8; uint uVar9; lVar3 = *(long *)(param_1 + 0x170); piVar1 = (int *)(lVar3 + (long)param_2 * 0x18); *piVar1 = *piVar1 + -1; lVar4 = *(long *)(param_1 + 0x138); iVar8 = 0; do { uVar9 = 0x6b; if (iVar8 == 10) { LAB_0015dae2: *param_3 = uVar9; piVar1 = (int *)(lVar3 + (long)param_2 * 0x18); *piVar1 = *piVar1 + 1; return; } iVar5 = *(int *)(lVar3 + 8 + (long)param_2 * 0x18); while( true ) { lVar6 = (long)iVar5; bVar2 = *(byte *)(lVar4 + lVar6); if ((bVar2 != 0xb5) && (bVar2 != 0xc4)) break; iVar5 = iVar5 + (uint)(byte)opcode_info[(ulong)bVar2 * 4]; } uVar9 = (uint)bVar2; if (uVar9 != 0x6b) { if (uVar9 == 0xe) { pcVar7 = (char *)(lVar6 + lVar4); do { pcVar7 = pcVar7 + 1; } while (*pcVar7 == '\x0e'); if (*pcVar7 == ')') { uVar9 = 0x29; } else { uVar9 = 0xe; } } goto LAB_0015dae2; } param_2 = *(int *)(lVar4 + 1 + lVar6); iVar8 = iVar8 + 1; } while( true ); }
31,854
OpenSubdiv::v3_6_0::Bfr::PatchTreeBuilder::~PatchTreeBuilder()
NVIDIA-RTX[P]OSD-Lite/opensubdiv/bfr/patchTreeBuilder.cpp
PatchTreeBuilder::~PatchTreeBuilder() { delete _patchBuilder; }
O3
cpp
OpenSubdiv::v3_6_0::Bfr::PatchTreeBuilder::~PatchTreeBuilder(): pushq %rbx movq %rdi, %rbx movq 0x48(%rdi), %rdi testq %rdi, %rdi je 0x90625 movq (%rdi), %rax callq *0x8(%rax) movq 0x30(%rbx), %rdi testq %rdi, %rdi je 0x9063a movq 0x40(%rbx), %rsi subq %rdi, %rsi callq 0x3a2b0 movq 0x18(%rbx), %rdi testq %rdi, %rdi je 0x90650 movq 0x28(%rbx), %rsi subq %rdi, %rsi popq %rbx jmp 0x3a2b0 popq %rbx retq
_ZN10OpenSubdiv6v3_6_03Bfr16PatchTreeBuilderD2Ev: push rbx; Alternative name is 'OpenSubdiv::v3_6_0::Bfr::PatchTreeBuilder::~PatchTreeBuilder()' mov rbx, rdi mov rdi, [rdi+48h] test rdi, rdi jz short loc_90625 mov rax, [rdi] call qword ptr [rax+8] loc_90625: mov rdi, [rbx+30h]; void * test rdi, rdi jz short loc_9063A mov rsi, [rbx+40h] sub rsi, rdi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_9063A: mov rdi, [rbx+18h]; void * test rdi, rdi jz short loc_90650 mov rsi, [rbx+28h] sub rsi, rdi; unsigned __int64 pop rbx jmp __ZdlPvm; operator delete(void *,ulong) loc_90650: pop rbx retn
void OpenSubdiv::v3_6_0::Bfr::PatchTreeBuilder::~PatchTreeBuilder( OpenSubdiv::v3_6_0::Bfr::PatchTreeBuilder *this) { long long v2; // rdi void *v3; // rdi void *v4; // rdi v2 = *((_QWORD *)this + 9); if ( v2 ) (*(void ( **)(long long))(*(_QWORD *)v2 + 8LL))(v2); v3 = (void *)*((_QWORD *)this + 6); if ( v3 ) operator delete(v3, *((_QWORD *)this + 8) - (_QWORD)v3); v4 = (void *)*((_QWORD *)this + 3); if ( v4 ) operator delete(v4, *((_QWORD *)this + 5) - (_QWORD)v4); }
~PatchTreeBuilder: PUSH RBX MOV RBX,RDI MOV RDI,qword ptr [RDI + 0x48] TEST RDI,RDI JZ 0x00190625 MOV RAX,qword ptr [RDI] CALL qword ptr [RAX + 0x8] LAB_00190625: MOV RDI,qword ptr [RBX + 0x30] TEST RDI,RDI JZ 0x0019063a MOV RSI,qword ptr [RBX + 0x40] SUB RSI,RDI CALL 0x0013a2b0 LAB_0019063a: MOV RDI,qword ptr [RBX + 0x18] TEST RDI,RDI JZ 0x00190650 MOV RSI,qword ptr [RBX + 0x28] SUB RSI,RDI POP RBX JMP 0x0013a2b0 LAB_00190650: POP RBX RET
/* OpenSubdiv::v3_6_0::Bfr::PatchTreeBuilder::~PatchTreeBuilder() */ void __thiscall OpenSubdiv::v3_6_0::Bfr::PatchTreeBuilder::~PatchTreeBuilder(PatchTreeBuilder *this) { void *pvVar1; if (*(long **)(this + 0x48) != (long *)0x0) { (**(code **)(**(long **)(this + 0x48) + 8))(); } pvVar1 = *(void **)(this + 0x30); if (pvVar1 != (void *)0x0) { operator_delete(pvVar1,*(long *)(this + 0x40) - (long)pvVar1); } pvVar1 = *(void **)(this + 0x18); if (pvVar1 != (void *)0x0) { operator_delete(pvVar1,*(long *)(this + 0x28) - (long)pvVar1); return; } return; }
31,855
alaya::WorkerTest::SetUp()
AlayaLite/tests/executor/worker_test.cpp
void SetUp() override { total_tasks_ = std::make_shared<std::atomic<size_t>>(0); finished_tasks_ = std::make_shared<std::atomic<size_t>>(0); task_queue_ = std::make_shared<TaskQueue>(); worker_ = std::make_shared<Worker>(1, 0, task_queue_.get(), total_tasks_.get(), finished_tasks_.get()); }
O0
cpp
alaya::WorkerTest::SetUp(): subq $0x88, %rsp movq %rdi, 0x80(%rsp) movq 0x80(%rsp), %rax movq %rax, 0x8(%rsp) movl $0x0, 0x6c(%rsp) leaq 0x70(%rsp), %rdi leaq 0x6c(%rsp), %rsi callq 0x71670 movq 0x8(%rsp), %rdi addq $0x20, %rdi leaq 0x70(%rsp), %rsi callq 0x716f0 leaq 0x70(%rsp), %rdi callq 0x71650 movl $0x0, 0x54(%rsp) leaq 0x58(%rsp), %rdi leaq 0x54(%rsp), %rsi callq 0x71670 movq 0x8(%rsp), %rdi addq $0x30, %rdi leaq 0x58(%rsp), %rsi callq 0x716f0 leaq 0x58(%rsp), %rdi callq 0x71650 leaq 0x40(%rsp), %rdi callq 0x71720 movq 0x8(%rsp), %rdi addq $0x10, %rdi leaq 0x40(%rsp), %rsi callq 0x71790 leaq 0x40(%rsp), %rdi callq 0x71660 movq 0x8(%rsp), %rdi movl $0x1, 0x2c(%rsp) movl $0x0, 0x28(%rsp) addq $0x10, %rdi callq 0x71870 movq 0x8(%rsp), %rdi movq %rax, 0x20(%rsp) addq $0x20, %rdi callq 0x71880 movq 0x8(%rsp), %rdi movq %rax, 0x18(%rsp) addq $0x30, %rdi callq 0x71880 movq %rax, 0x10(%rsp) leaq 0x30(%rsp), %rdi leaq 0x2c(%rsp), %rsi leaq 0x28(%rsp), %rdx leaq 0x20(%rsp), %rcx leaq 0x18(%rsp), %r8 leaq 0x10(%rsp), %r9 callq 0x717c0 movq 0x8(%rsp), %rdi addq $0x40, %rdi leaq 0x30(%rsp), %rsi callq 0x71890 leaq 0x30(%rsp), %rdi callq 0x71640 addq $0x88, %rsp retq nopl (%rax)
_ZN5alaya10WorkerTest5SetUpEv: sub rsp, 88h mov [rsp+88h+var_8], rdi mov rax, [rsp+88h+var_8] mov [rsp+88h+var_80], rax mov [rsp+88h+var_1C], 0 lea rdi, [rsp+88h+var_18] lea rsi, [rsp+88h+var_1C] call _ZSt11make_sharedISt6atomicImEJiEESt10shared_ptrIT_EDpOT0_; std::make_shared<std::atomic<ulong>,int>(int &&) mov rdi, [rsp+88h+var_80] add rdi, 20h ; ' ' lea rsi, [rsp+88h+var_18] call _ZNSt10shared_ptrISt6atomicImEEaSEOS2_; std::shared_ptr<std::atomic<ulong>>::operator=(std::shared_ptr<std::atomic<ulong>>&&) lea rdi, [rsp+88h+var_18] call _ZNSt10shared_ptrISt6atomicImEED2Ev; std::shared_ptr<std::atomic<ulong>>::~shared_ptr() mov [rsp+88h+var_34], 0 lea rdi, [rsp+88h+var_30] lea rsi, [rsp+88h+var_34] call _ZSt11make_sharedISt6atomicImEJiEESt10shared_ptrIT_EDpOT0_; std::make_shared<std::atomic<ulong>,int>(int &&) mov rdi, [rsp+88h+var_80] add rdi, 30h ; '0' lea rsi, [rsp+88h+var_30] call _ZNSt10shared_ptrISt6atomicImEEaSEOS2_; std::shared_ptr<std::atomic<ulong>>::operator=(std::shared_ptr<std::atomic<ulong>>&&) lea rdi, [rsp+88h+var_30] call _ZNSt10shared_ptrISt6atomicImEED2Ev; std::shared_ptr<std::atomic<ulong>>::~shared_ptr() lea rdi, [rsp+88h+var_48] call _ZSt11make_sharedIN5alaya9TaskQueueEJEESt10shared_ptrIT_EDpOT0_; std::make_shared<alaya::TaskQueue>() mov rdi, [rsp+88h+var_80] add rdi, 10h lea rsi, [rsp+88h+var_48] call _ZNSt10shared_ptrIN5alaya9TaskQueueEEaSEOS2_; std::shared_ptr<alaya::TaskQueue>::operator=(std::shared_ptr<alaya::TaskQueue>&&) lea rdi, [rsp+88h+var_48] call _ZNSt10shared_ptrIN5alaya9TaskQueueEED2Ev; std::shared_ptr<alaya::TaskQueue>::~shared_ptr() mov rdi, [rsp+88h+var_80] mov [rsp+88h+var_5C], 1 mov [rsp+88h+var_60], 0 add rdi, 10h call _ZNKSt12__shared_ptrIN5alaya9TaskQueueELN9__gnu_cxx12_Lock_policyE2EE3getEv; std::__shared_ptr<alaya::TaskQueue,(__gnu_cxx::_Lock_policy)2>::get(void) mov rdi, [rsp+88h+var_80] mov [rsp+88h+var_68], rax add rdi, 20h ; ' ' call _ZNKSt12__shared_ptrISt6atomicImELN9__gnu_cxx12_Lock_policyE2EE3getEv; std::__shared_ptr<std::atomic<ulong>,(__gnu_cxx::_Lock_policy)2>::get(void) mov rdi, [rsp+88h+var_80] mov [rsp+88h+var_70], rax add rdi, 30h ; '0' call _ZNKSt12__shared_ptrISt6atomicImELN9__gnu_cxx12_Lock_policyE2EE3getEv; std::__shared_ptr<std::atomic<ulong>,(__gnu_cxx::_Lock_policy)2>::get(void) mov [rsp+88h+var_78], rax lea rdi, [rsp+88h+var_58] lea rsi, [rsp+88h+var_5C] lea rdx, [rsp+88h+var_60] lea rcx, [rsp+88h+var_68] lea r8, [rsp+88h+var_70] lea r9, [rsp+88h+var_78] call _ZSt11make_sharedIN5alaya6WorkerEJiiPNS0_9TaskQueueEPSt6atomicImES6_EESt10shared_ptrIT_EDpOT0_; std::make_shared<alaya::Worker,int,int,alaya::TaskQueue *,std::atomic<ulong> *,std::atomic<ulong> *>(int,int,alaya::TaskQueue *,std::atomic<ulong> *,std::atomic<ulong> * &&) mov rdi, [rsp+88h+var_80] add rdi, 40h ; '@' lea rsi, [rsp+88h+var_58] call _ZNSt10shared_ptrIN5alaya6WorkerEEaSEOS2_; std::shared_ptr<alaya::Worker>::operator=(std::shared_ptr<alaya::Worker>&&) lea rdi, [rsp+88h+var_58] call _ZNSt10shared_ptrIN5alaya6WorkerEED2Ev; std::shared_ptr<alaya::Worker>::~shared_ptr() add rsp, 88h retn
long long alaya::WorkerTest::SetUp(alaya::WorkerTest *this, long long a2, int a3, int a4, int a5, int a6) { int v6; // edx int v7; // ecx int v8; // r8d int v9; // r9d int v10; // edx int v11; // ecx int v12; // r8d int v13; // r9d long long v15; // [rsp+10h] [rbp-78h] BYREF long long v16; // [rsp+18h] [rbp-70h] BYREF long long v17; // [rsp+20h] [rbp-68h] BYREF int v18; // [rsp+28h] [rbp-60h] BYREF int v19; // [rsp+2Ch] [rbp-5Ch] BYREF _BYTE v20[16]; // [rsp+30h] [rbp-58h] BYREF _BYTE v21[20]; // [rsp+40h] [rbp-48h] BYREF int v22; // [rsp+54h] [rbp-34h] BYREF _BYTE v23[20]; // [rsp+58h] [rbp-30h] BYREF int v24; // [rsp+6Ch] [rbp-1Ch] BYREF _BYTE v25[16]; // [rsp+70h] [rbp-18h] BYREF alaya::WorkerTest *v26; // [rsp+80h] [rbp-8h] v26 = this; v24 = 0; std::make_shared<std::atomic<unsigned long>,int>((unsigned int)v25, (unsigned int)&v24, a3, a4, a5, a6); std::shared_ptr<std::atomic<unsigned long>>::operator=((char *)this + 32, v25); std::shared_ptr<std::atomic<unsigned long>>::~shared_ptr(v25); v22 = 0; std::make_shared<std::atomic<unsigned long>,int>((unsigned int)v23, (unsigned int)&v22, v6, v7, v8, v9); std::shared_ptr<std::atomic<unsigned long>>::operator=((char *)this + 48, v23); std::shared_ptr<std::atomic<unsigned long>>::~shared_ptr(v23); std::make_shared<alaya::TaskQueue>((unsigned int)v21, (unsigned int)v23, v10, v11, v12, v13); std::shared_ptr<alaya::TaskQueue>::operator=((char *)this + 16, v21); std::shared_ptr<alaya::TaskQueue>::~shared_ptr(v21); v19 = 1; v18 = 0; v17 = std::__shared_ptr<alaya::TaskQueue,(__gnu_cxx::_Lock_policy)2>::get((char *)this + 16); v16 = std::__shared_ptr<std::atomic<unsigned long>,(__gnu_cxx::_Lock_policy)2>::get((char *)this + 32); v15 = std::__shared_ptr<std::atomic<unsigned long>,(__gnu_cxx::_Lock_policy)2>::get((char *)this + 48); std::make_shared<alaya::Worker,int,int,alaya::TaskQueue *,std::atomic<unsigned long> *,std::atomic<unsigned long> *>( (unsigned int)v20, (unsigned int)&v19, (unsigned int)&v18, (unsigned int)&v17, (unsigned int)&v16, (unsigned int)&v15); std::shared_ptr<alaya::Worker>::operator=((char *)this + 64, v20); return std::shared_ptr<alaya::Worker>::~shared_ptr(v20); }
SetUp: SUB RSP,0x88 MOV qword ptr [RSP + 0x80],RDI MOV RAX,qword ptr [RSP + 0x80] MOV qword ptr [RSP + 0x8],RAX MOV dword ptr [RSP + 0x6c],0x0 LEA RDI,[RSP + 0x70] LEA RSI,[RSP + 0x6c] CALL 0x00171670 MOV RDI,qword ptr [RSP + 0x8] ADD RDI,0x20 LEA RSI,[RSP + 0x70] CALL 0x001716f0 LEA RDI,[RSP + 0x70] CALL 0x00171650 MOV dword ptr [RSP + 0x54],0x0 LEA RDI,[RSP + 0x58] LEA RSI,[RSP + 0x54] CALL 0x00171670 MOV RDI,qword ptr [RSP + 0x8] ADD RDI,0x30 LEA RSI,[RSP + 0x58] CALL 0x001716f0 LEA RDI,[RSP + 0x58] CALL 0x00171650 LEA RDI,[RSP + 0x40] CALL 0x00171720 MOV RDI,qword ptr [RSP + 0x8] ADD RDI,0x10 LEA RSI,[RSP + 0x40] CALL 0x00171790 LEA RDI,[RSP + 0x40] CALL 0x00171660 MOV RDI,qword ptr [RSP + 0x8] MOV dword ptr [RSP + 0x2c],0x1 MOV dword ptr [RSP + 0x28],0x0 ADD RDI,0x10 CALL 0x00171870 MOV RDI,qword ptr [RSP + 0x8] MOV qword ptr [RSP + 0x20],RAX ADD RDI,0x20 CALL 0x00171880 MOV RDI,qword ptr [RSP + 0x8] MOV qword ptr [RSP + 0x18],RAX ADD RDI,0x30 CALL 0x00171880 MOV qword ptr [RSP + 0x10],RAX LEA RDI,[RSP + 0x30] LEA RSI,[RSP + 0x2c] LEA RDX,[RSP + 0x28] LEA RCX,[RSP + 0x20] LEA R8,[RSP + 0x18] LEA R9,[RSP + 0x10] CALL 0x001717c0 MOV RDI,qword ptr [RSP + 0x8] ADD RDI,0x40 LEA RSI,[RSP + 0x30] CALL 0x00171890 LEA RDI,[RSP + 0x30] CALL 0x00171640 ADD RSP,0x88 RET
/* alaya::WorkerTest::SetUp() */ void __thiscall alaya::WorkerTest::SetUp(WorkerTest *this) { atomic *local_70; atomic *local_68; int4 local_60; int local_5c; shared_ptr<alaya::Worker> local_58 [16]; shared_ptr<alaya::TaskQueue> local_48 [20]; int4 local_34; shared_ptr<std::atomic<unsigned_long>> local_30 [20]; int4 local_1c; shared_ptr<std::atomic<unsigned_long>> local_18 [16]; WorkerTest *local_8; local_1c = 0; local_8 = this; std::make_shared<std::atomic<unsigned_long>,int>((int *)local_18); std::shared_ptr<std::atomic<unsigned_long>>::operator= ((shared_ptr<std::atomic<unsigned_long>> *)(this + 0x20),local_18); std::shared_ptr<std::atomic<unsigned_long>>::~shared_ptr(local_18); local_34 = 0; std::make_shared<std::atomic<unsigned_long>,int>((int *)local_30); std::shared_ptr<std::atomic<unsigned_long>>::operator= ((shared_ptr<std::atomic<unsigned_long>> *)(this + 0x30),local_30); std::shared_ptr<std::atomic<unsigned_long>>::~shared_ptr(local_30); std::make_shared<alaya::TaskQueue>(); std::shared_ptr<alaya::TaskQueue>::operator= ((shared_ptr<alaya::TaskQueue> *)(this + 0x10),local_48); std::shared_ptr<alaya::TaskQueue>::~shared_ptr(local_48); local_5c = 1; local_60 = 0; local_68 = (atomic *) std::__shared_ptr<alaya::TaskQueue,(__gnu_cxx::_Lock_policy)2>::get ((__shared_ptr<alaya::TaskQueue,(__gnu_cxx::_Lock_policy)2> *)(this + 0x10)); local_70 = (atomic *) std::__shared_ptr<std::atomic<unsigned_long>,(__gnu_cxx::_Lock_policy)2>::get ((__shared_ptr<std::atomic<unsigned_long>,(__gnu_cxx::_Lock_policy)2> *) (this + 0x20)); std::__shared_ptr<std::atomic<unsigned_long>,(__gnu_cxx::_Lock_policy)2>::get ((__shared_ptr<std::atomic<unsigned_long>,(__gnu_cxx::_Lock_policy)2> *)(this + 0x30)); std:: make_shared<alaya::Worker,int,int,alaya::TaskQueue*,std::atomic<unsigned_long>*,std::atomic<unsigned_long>*> ((int *)local_58,&local_5c,(TaskQueue **)&local_60,&local_68,&local_70); std::shared_ptr<alaya::Worker>::operator=((shared_ptr<alaya::Worker> *)(this + 0x40),local_58); std::shared_ptr<alaya::Worker>::~shared_ptr(local_58); return; }
31,856
alaya::WorkerTest::SetUp()
AlayaLite/tests/executor/worker_test.cpp
void SetUp() override { total_tasks_ = std::make_shared<std::atomic<size_t>>(0); finished_tasks_ = std::make_shared<std::atomic<size_t>>(0); task_queue_ = std::make_shared<TaskQueue>(); worker_ = std::make_shared<Worker>(1, 0, task_queue_.get(), total_tasks_.get(), finished_tasks_.get()); }
O3
cpp
alaya::WorkerTest::SetUp(): pushq %rbx movq %rdi, %rbx leaq 0x851d5(%rip), %rax # 0xb0b20 addq $0x10, %rax movq %rax, (%rdi) movq 0x48(%rdi), %rdi testq %rdi, %rdi je 0x2b960 callq 0x1912a movq 0x38(%rbx), %rdi testq %rdi, %rdi je 0x2b96e callq 0x1912a movq 0x28(%rbx), %rdi testq %rdi, %rdi je 0x2b97c callq 0x1912a movq 0x18(%rbx), %rdi testq %rdi, %rdi je 0x2b98a callq 0x1912a movq %rbx, %rdi popq %rbx jmp 0x61a5a nop
_ZN5alaya10WorkerTestD2Ev: push rbx mov rbx, rdi lea rax, _ZTVN5alaya10WorkerTestE; `vtable for'alaya::WorkerTest add rax, 10h mov [rdi], rax mov rdi, [rdi+48h] test rdi, rdi jz short loc_2B960 call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void) loc_2B960: mov rdi, [rbx+38h] test rdi, rdi jz short loc_2B96E call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void) loc_2B96E: mov rdi, [rbx+28h] test rdi, rdi jz short loc_2B97C call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void) loc_2B97C: mov rdi, [rbx+18h] test rdi, rdi jz short loc_2B98A call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void) loc_2B98A: mov rdi, rbx; this pop rbx jmp _ZN7testing4TestD2Ev; testing::Test::~Test()
void alaya::WorkerTest::~WorkerTest(alaya::WorkerTest *this) { volatile signed __int32 *v2; // rdi volatile signed __int32 *v3; // rdi volatile signed __int32 *v4; // rdi volatile signed __int32 *v5; // rdi *(_QWORD *)this = &`vtable for'alaya::WorkerTest + 2; v2 = (volatile signed __int32 *)*((_QWORD *)this + 9); if ( v2 ) std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v2); v3 = (volatile signed __int32 *)*((_QWORD *)this + 7); if ( v3 ) std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v3); v4 = (volatile signed __int32 *)*((_QWORD *)this + 5); if ( v4 ) std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v4); v5 = (volatile signed __int32 *)*((_QWORD *)this + 3); if ( v5 ) std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v5); testing::Test::~Test(this); }
~WorkerTest: PUSH RBX MOV RBX,RDI LEA RAX,[0x1b0b20] ADD RAX,0x10 MOV qword ptr [RDI],RAX MOV RDI,qword ptr [RDI + 0x48] TEST RDI,RDI JZ 0x0012b960 CALL 0x0011912a LAB_0012b960: MOV RDI,qword ptr [RBX + 0x38] TEST RDI,RDI JZ 0x0012b96e CALL 0x0011912a LAB_0012b96e: MOV RDI,qword ptr [RBX + 0x28] TEST RDI,RDI JZ 0x0012b97c CALL 0x0011912a LAB_0012b97c: MOV RDI,qword ptr [RBX + 0x18] TEST RDI,RDI JZ 0x0012b98a CALL 0x0011912a LAB_0012b98a: MOV RDI,RBX POP RBX JMP 0x00161a5a
/* alaya::WorkerTest::~WorkerTest() */ void __thiscall alaya::WorkerTest::~WorkerTest(WorkerTest *this) { *(int ***)this = &PTR__WorkerTest_001b0b30; if (*(_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> **)(this + 0x48) != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) { std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release (*(_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> **)(this + 0x48)); } if (*(_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> **)(this + 0x38) != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) { std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release (*(_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> **)(this + 0x38)); } if (*(_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> **)(this + 0x28) != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) { std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release (*(_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> **)(this + 0x28)); } if (*(_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> **)(this + 0x18) != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) { std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release (*(_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> **)(this + 0x18)); } testing::Test::~Test((Test *)this); return; }
31,857
curl_perform_with_retry(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, void*, int, int)
llama.cpp/common/arg.cpp
static bool curl_perform_with_retry(const std::string & url, CURL * curl, int max_attempts, int retry_delay_seconds) { int remaining_attempts = max_attempts; while (remaining_attempts > 0) { LOG_INF("%s: Trying to download from %s (attempt %d of %d)...\n", __func__ , url.c_str(), max_attempts - remaining_attempts + 1, max_attempts); CURLcode res = curl_easy_perform(curl); if (res == CURLE_OK) { return true; } int exponential_backoff_delay = std::pow(retry_delay_seconds, max_attempts - remaining_attempts) * 1000; LOG_WRN("%s: curl_easy_perform() failed: %s, retrying after %d milliseconds...\n", __func__, curl_easy_strerror(res), exponential_backoff_delay); remaining_attempts--; std::this_thread::sleep_for(std::chrono::milliseconds(exponential_backoff_delay)); } LOG_ERR("%s: curl_easy_perform() failed after %d attempts\n", __func__, max_attempts); return false; }
O3
cpp
curl_perform_with_retry(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, void*, int, int): pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x28, %rsp movq %rsi, 0x10(%rsp) movq %rdi, 0x8(%rsp) movl $0x3, %r14d leaq 0x106774(%rip), %r12 # 0x163900 leaq 0xbdd1c(%rip), %rbx # 0x11aeaf leaq 0x18(%rsp), %rbp cmpl $0x0, (%r12) js 0x5d1d5 callq 0x10c85b movq 0x8(%rsp), %rcx movq (%rcx), %r8 movl $0x4, %r9d subl %r14d, %r9d movl $0x3, (%rsp) movq %rax, %rdi movl $0x2, %esi leaq 0xbdcae(%rip), %rdx # 0x11ae79 movq %rbx, %rcx xorl %eax, %eax callq 0x10c8f8 movq 0x10(%rsp), %rdi callq 0x20b90 movl %eax, %r15d testl %eax, %eax je 0x5d2d7 movl $0x3, %edi subl %r14d, %edi movsd 0xb53a6(%rip), %xmm0 # 0x1125a0 callq 0x21100 mulsd 0xb53a1(%rip), %xmm0 # 0x1125a8 cvttsd2si %xmm0, %r13d cmpl $0x0, (%r12) js 0x5d24f callq 0x10c85b movq %r12, %rbx movq %rax, %r12 movl %r15d, %edi callq 0x20710 movq %r12, %rdi movq %rbx, %r12 leaq 0xbdc7c(%rip), %rbx # 0x11aeaf movl $0x3, %esi leaq 0xbdc88(%rip), %rdx # 0x11aec7 movq %rbx, %rcx movq %rax, %r8 movl %r13d, %r9d xorl %eax, %eax callq 0x10c8f8 testl %r13d, %r13d jle 0x5d297 movl %r13d, %eax imulq $0x10624dd3, %rax, %rcx # imm = 0x10624DD3 shrq $0x26, %rcx imulq $-0x3e8, %rcx, %rdx # imm = 0xFC18 addq %rax, %rdx imulq $0xf4240, %rdx, %rax # imm = 0xF4240 movq %rcx, 0x18(%rsp) movq %rax, 0x20(%rsp) movq %rbp, %rdi movq %rbp, %rsi callq 0x211f0 cmpl $-0x1, %eax jne 0x5d297 callq 0x210f0 cmpl $0x4, (%rax) je 0x5d27d leal -0x1(%r14), %eax cmpl $0x1, %r14d movl %eax, %r14d ja 0x5d198 cmpl $0x0, (%r12) js 0x5d2d7 callq 0x10c85b leaq 0xbdc53(%rip), %rdx # 0x11af0e leaq 0xbdbed(%rip), %rcx # 0x11aeaf movq %rax, %rdi movl $0x4, %esi movl $0x3, %r8d xorl %eax, %eax callq 0x10c8f8 testl %r15d, %r15d sete %al addq $0x28, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
_ZL23curl_perform_with_retryRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEPvii: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 28h mov [rsp+58h+var_48], rsi mov [rsp+58h+var_50], rdi mov r14d, 3 lea r12, common_log_verbosity_thold lea rbx, aCurlPerformWit; "curl_perform_with_retry" lea rbp, [rsp+58h+var_40] loc_5D198: cmp dword ptr [r12], 0 js short loc_5D1D5 call _Z15common_log_mainv; common_log_main(void) mov rcx, [rsp+58h+var_50] mov r8, [rcx] mov r9d, 4 sub r9d, r14d mov [rsp+58h+var_58], 3 mov rdi, rax mov esi, 2 lea rdx, aSTryingToDownl_0; "%s: Trying to download from %s (attempt"... mov rcx, rbx xor eax, eax call _Z14common_log_addP10common_log14ggml_log_levelPKcz; common_log_add(common_log *,ggml_log_level,char const*,...) loc_5D1D5: mov rdi, [rsp+58h+var_48] call _curl_easy_perform mov r15d, eax test eax, eax jz loc_5D2D7 mov edi, 3 sub edi, r14d movsd xmm0, cs:qword_1125A0 call _ldexp mulsd xmm0, cs:qword_1125A8 cvttsd2si r13d, xmm0 cmp dword ptr [r12], 0 js short loc_5D24F call _Z15common_log_mainv; common_log_main(void) mov rbx, r12 mov r12, rax mov edi, r15d call _curl_easy_strerror mov rdi, r12 mov r12, rbx lea rbx, aCurlPerformWit; "curl_perform_with_retry" mov esi, 3 lea rdx, aSCurlEasyPerfo; "%s: curl_easy_perform() failed: %s, ret"... mov rcx, rbx mov r8, rax mov r9d, r13d xor eax, eax call _Z14common_log_addP10common_log14ggml_log_levelPKcz; common_log_add(common_log *,ggml_log_level,char const*,...) loc_5D24F: test r13d, r13d jle short loc_5D297 mov eax, r13d imul rcx, rax, 10624DD3h shr rcx, 26h imul rdx, rcx, 0FFFFFFFFFFFFFC18h add rdx, rax imul rax, rdx, 0F4240h mov [rsp+58h+var_40], rcx mov [rsp+58h+var_38], rax loc_5D27D: mov rdi, rbp mov rsi, rbp call _nanosleep cmp eax, 0FFFFFFFFh jnz short loc_5D297 call ___errno_location cmp dword ptr [rax], 4 jz short loc_5D27D loc_5D297: lea eax, [r14-1] cmp r14d, 1 mov r14d, eax ja loc_5D198 cmp dword ptr [r12], 0 js short loc_5D2D7 call _Z15common_log_mainv; common_log_main(void) lea rdx, aSCurlEasyPerfo_0; "%s: curl_easy_perform() failed after %d"... lea rcx, aCurlPerformWit; "curl_perform_with_retry" mov rdi, rax mov esi, 4 mov r8d, 3 xor eax, eax call _Z14common_log_addP10common_log14ggml_log_levelPKcz; common_log_add(common_log *,ggml_log_level,char const*,...) loc_5D2D7: test r15d, r15d setz al add rsp, 28h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
bool curl_perform_with_retry(_QWORD *a1, long long a2) { unsigned int v2; // r14d int *v3; // r12 int v4; // eax unsigned int v5; // r15d int v6; // r13d int *v7; // rbx int v8; // r12d int v9; // eax int v10; // edi int v12; // eax int v13; // r9d _QWORD v16[8]; // [rsp+18h] [rbp-40h] BYREF v2 = 3; v3 = (int *)&common_log_verbosity_thold; while ( 1 ) { if ( *v3 >= 0 ) { v4 = common_log_main(); common_log_add( v4, 2, (unsigned int)"%s: Trying to download from %s (attempt %d of %d)...\n", (unsigned int)"curl_perform_with_retry", *a1, 4 - v2); } v5 = curl_easy_perform(a2); if ( !v5 ) break; v6 = (int)(ldexp(1.0, 3 - v2) * 1000.0); if ( *v3 >= 0 ) { v7 = v3; v8 = common_log_main(); v9 = curl_easy_strerror(v5); v10 = v8; v3 = v7; common_log_add( v10, 3, (unsigned int)"%s: curl_easy_perform() failed: %s, retrying after %d milliseconds...\n", (unsigned int)"curl_perform_with_retry", v9, v6); } if ( v6 > 0 ) { v16[0] = (unsigned int)v6 / 0x3E8uLL; v16[1] = 1000000 * ((unsigned int)v6 % 0x3E8uLL); while ( (unsigned int)nanosleep(v16, v16) == -1 && *(_DWORD *)__errno_location(v16) == 4 ) ; } if ( v2-- <= 1 ) { if ( *v3 >= 0 ) { v12 = common_log_main(); common_log_add( v12, 4, (unsigned int)"%s: curl_easy_perform() failed after %d attempts\n", (unsigned int)"curl_perform_with_retry", 3, v13); } return v5 == 0; } } return v5 == 0; }
curl_perform_with_retry: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x28 MOV qword ptr [RSP + 0x10],RSI MOV qword ptr [RSP + 0x8],RDI MOV R14D,0x3 LEA R12,[0x263900] LEA RBX,[0x21aeaf] LEA RBP,[RSP + 0x18] LAB_0015d198: CMP dword ptr [R12],0x0 JS 0x0015d1d5 CALL 0x0020c85b MOV RCX,qword ptr [RSP + 0x8] MOV R8,qword ptr [RCX] MOV R9D,0x4 SUB R9D,R14D MOV dword ptr [RSP],0x3 MOV RDI,RAX MOV ESI,0x2 LEA RDX,[0x21ae79] MOV RCX,RBX XOR EAX,EAX CALL 0x0020c8f8 LAB_0015d1d5: MOV RDI,qword ptr [RSP + 0x10] CALL 0x00120b90 MOV R15D,EAX TEST EAX,EAX JZ 0x0015d2d7 MOV EDI,0x3 SUB EDI,R14D MOVSD XMM0,qword ptr [0x002125a0] CALL 0x00121100 MULSD XMM0,qword ptr [0x002125a8] CVTTSD2SI R13D,XMM0 CMP dword ptr [R12],0x0 JS 0x0015d24f CALL 0x0020c85b MOV RBX,R12 MOV R12,RAX MOV EDI,R15D CALL 0x00120710 MOV RDI,R12 MOV R12,RBX LEA RBX,[0x21aeaf] MOV ESI,0x3 LEA RDX,[0x21aec7] MOV RCX,RBX MOV R8,RAX MOV R9D,R13D XOR EAX,EAX CALL 0x0020c8f8 LAB_0015d24f: TEST R13D,R13D JLE 0x0015d297 MOV EAX,R13D IMUL RCX,RAX,0x10624dd3 SHR RCX,0x26 IMUL RDX,RCX,-0x3e8 ADD RDX,RAX IMUL RAX,RDX,0xf4240 MOV qword ptr [RSP + 0x18],RCX MOV qword ptr [RSP + 0x20],RAX LAB_0015d27d: MOV RDI,RBP MOV RSI,RBP CALL 0x001211f0 CMP EAX,-0x1 JNZ 0x0015d297 CALL 0x001210f0 CMP dword ptr [RAX],0x4 JZ 0x0015d27d LAB_0015d297: LEA EAX,[R14 + -0x1] CMP R14D,0x1 MOV R14D,EAX JA 0x0015d198 CMP dword ptr [R12],0x0 JS 0x0015d2d7 CALL 0x0020c85b LEA RDX,[0x21af0e] LEA RCX,[0x21aeaf] MOV RDI,RAX MOV ESI,0x4 MOV R8D,0x3 XOR EAX,EAX CALL 0x0020c8f8 LAB_0015d2d7: TEST R15D,R15D SETZ AL ADD RSP,0x28 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
/* WARNING: Globals starting with '_' overlap smaller symbols at the same address */ /* curl_perform_with_retry(std::__cxx11::string const&, void*, int, int) */ bool curl_perform_with_retry(string *param_1,void *param_2,int param_3,int param_4) { bool bVar1; int iVar2; int iVar3; int8 uVar4; int8 uVar5; int *piVar6; uint uVar7; uint uVar8; double dVar9; timespec local_40; uVar8 = 3; do { if (-1 < common_log_verbosity_thold) { uVar4 = common_log_main(); common_log_add(uVar4,2,"%s: Trying to download from %s (attempt %d of %d)...\n", "curl_perform_with_retry",*(int8 *)param_1,4 - uVar8,3); } iVar2 = curl_easy_perform(param_2); if (iVar2 == 0) goto LAB_0015d2d7; dVar9 = ldexp(DAT_002125a0,3 - uVar8); uVar7 = (uint)(dVar9 * _DAT_002125a8); if (-1 < common_log_verbosity_thold) { uVar4 = common_log_main(); uVar5 = curl_easy_strerror(iVar2); common_log_add(uVar4,3, "%s: curl_easy_perform() failed: %s, retrying after %d milliseconds...\n", "curl_perform_with_retry",uVar5,uVar7); } if (0 < (int)uVar7) { local_40.tv_sec = (ulong)uVar7 / 1000; local_40.tv_nsec = ((ulong)uVar7 % 1000) * 1000000; do { iVar3 = nanosleep(&local_40,&local_40); if (iVar3 != -1) break; piVar6 = __errno_location(); } while (*piVar6 == 4); } bVar1 = 1 < uVar8; uVar8 = uVar8 - 1; } while (bVar1); if (-1 < common_log_verbosity_thold) { uVar4 = common_log_main(); common_log_add(uVar4,4,"%s: curl_easy_perform() failed after %d attempts\n", "curl_perform_with_retry",3); } LAB_0015d2d7: return iVar2 == 0; }
31,858
ft_nlq_find_relevance
eloqsql/storage/myisam/ft_nlq_search.c
float ft_nlq_find_relevance(FT_INFO *handler, uchar *record __attribute__((unused)), uint length __attribute__((unused))) { int a,b,c; FT_DOC *docs=handler->doc; my_off_t docid=handler->info->lastpos; if (docid == HA_POS_ERROR) return -5.0; /* Assuming docs[] is sorted by dpos... */ for (a=0, b=handler->ndocs, c=(a+b)/2; b-a>1; c=(a+b)/2) { if (docs[c].dpos > docid) b=c; else a=c; } /* bounds check to avoid accessing unallocated handler->doc */ if (a < handler->ndocs && docs[a].dpos == docid) return (float) docs[a].weight; else return 0.0; }
O0
c
ft_nlq_find_relevance: pushq %rbp movq %rsp, %rbp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movl %edx, -0x1c(%rbp) movq -0x10(%rbp), %rax addq $0x18, %rax movq %rax, -0x30(%rbp) movq -0x10(%rbp), %rax movq 0x8(%rax), %rax movq 0x170(%rax), %rax movq %rax, -0x38(%rbp) cmpq $-0x1, -0x38(%rbp) jne 0xa18a7 movss 0xaf777(%rip), %xmm0 # 0x151014 movss %xmm0, -0x4(%rbp) jmp 0xa195a movl $0x0, -0x20(%rbp) movq -0x10(%rbp), %rax movl 0x10(%rax), %eax movl %eax, -0x24(%rbp) movl -0x20(%rbp), %eax addl -0x24(%rbp), %eax movl $0x2, %ecx cltd idivl %ecx movl %eax, -0x28(%rbp) movl -0x24(%rbp), %eax subl -0x20(%rbp), %eax cmpl $0x1, %eax jle 0xa190f movq -0x30(%rbp), %rax movslq -0x28(%rbp), %rcx shlq $0x4, %rcx addq %rcx, %rax movq (%rax), %rax cmpq -0x38(%rbp), %rax jbe 0xa18f4 movl -0x28(%rbp), %eax movl %eax, -0x24(%rbp) jmp 0xa18fa movl -0x28(%rbp), %eax movl %eax, -0x20(%rbp) jmp 0xa18fc movl -0x20(%rbp), %eax addl -0x24(%rbp), %eax movl $0x2, %ecx cltd idivl %ecx movl %eax, -0x28(%rbp) jmp 0xa18c9 movl -0x20(%rbp), %eax movq -0x10(%rbp), %rcx cmpl 0x10(%rcx), %eax jge 0xa1952 movq -0x30(%rbp), %rax movslq -0x20(%rbp), %rcx shlq $0x4, %rcx addq %rcx, %rax movq (%rax), %rax cmpq -0x38(%rbp), %rax jne 0xa1952 movq -0x30(%rbp), %rax movslq -0x20(%rbp), %rcx shlq $0x4, %rcx addq %rcx, %rax movsd 0x8(%rax), %xmm0 cvtsd2ss %xmm0, %xmm0 movss %xmm0, -0x4(%rbp) jmp 0xa195a xorps %xmm0, %xmm0 movss %xmm0, -0x4(%rbp) movss -0x4(%rbp), %xmm0 popq %rbp retq nopw %cs:(%rax,%rax)
ft_nlq_find_relevance: push rbp mov rbp, rsp mov [rbp+var_10], rdi mov [rbp+var_18], rsi mov [rbp+var_1C], edx mov rax, [rbp+var_10] add rax, 18h mov [rbp+var_30], rax mov rax, [rbp+var_10] mov rax, [rax+8] mov rax, [rax+170h] mov [rbp+var_38], rax cmp [rbp+var_38], 0FFFFFFFFFFFFFFFFh jnz short loc_A18A7 movss xmm0, cs:dword_151014 movss [rbp+var_4], xmm0 jmp loc_A195A loc_A18A7: mov [rbp+var_20], 0 mov rax, [rbp+var_10] mov eax, [rax+10h] mov [rbp+var_24], eax mov eax, [rbp+var_20] add eax, [rbp+var_24] mov ecx, 2 cdq idiv ecx mov [rbp+var_28], eax loc_A18C9: mov eax, [rbp+var_24] sub eax, [rbp+var_20] cmp eax, 1 jle short loc_A190F mov rax, [rbp+var_30] movsxd rcx, [rbp+var_28] shl rcx, 4 add rax, rcx mov rax, [rax] cmp rax, [rbp+var_38] jbe short loc_A18F4 mov eax, [rbp+var_28] mov [rbp+var_24], eax jmp short loc_A18FA loc_A18F4: mov eax, [rbp+var_28] mov [rbp+var_20], eax loc_A18FA: jmp short $+2 loc_A18FC: mov eax, [rbp+var_20] add eax, [rbp+var_24] mov ecx, 2 cdq idiv ecx mov [rbp+var_28], eax jmp short loc_A18C9 loc_A190F: mov eax, [rbp+var_20] mov rcx, [rbp+var_10] cmp eax, [rcx+10h] jge short loc_A1952 mov rax, [rbp+var_30] movsxd rcx, [rbp+var_20] shl rcx, 4 add rax, rcx mov rax, [rax] cmp rax, [rbp+var_38] jnz short loc_A1952 mov rax, [rbp+var_30] movsxd rcx, [rbp+var_20] shl rcx, 4 add rax, rcx movsd xmm0, qword ptr [rax+8] cvtsd2ss xmm0, xmm0 movss [rbp+var_4], xmm0 jmp short loc_A195A loc_A1952: xorps xmm0, xmm0 movss [rbp+var_4], xmm0 loc_A195A: movss xmm0, [rbp+var_4] pop rbp retn
float ft_nlq_find_relevance(long long a1) { unsigned long long v3; // [rsp+0h] [rbp-38h] long long v4; // [rsp+8h] [rbp-30h] int v5; // [rsp+10h] [rbp-28h] int v6; // [rsp+14h] [rbp-24h] int v7; // [rsp+18h] [rbp-20h] v4 = a1 + 24; v3 = *(_QWORD *)(*(_QWORD *)(a1 + 8) + 368LL); if ( v3 == -1LL ) return -5.0; v7 = 0; v6 = *(_DWORD *)(a1 + 16); v5 = v6 / 2; while ( v6 - v7 > 1 ) { if ( *(_QWORD *)(16LL * v5 + v4) <= v3 ) v7 = v5; else v6 = v5; v5 = (v6 + v7) / 2; } if ( v7 >= *(_DWORD *)(a1 + 16) || *(_QWORD *)(16LL * v7 + v4) != v3 ) return 0.0; return *(double *)(16LL * v7 + v4 + 8); }
ft_nlq_find_relevance: PUSH RBP MOV RBP,RSP MOV qword ptr [RBP + -0x10],RDI MOV qword ptr [RBP + -0x18],RSI MOV dword ptr [RBP + -0x1c],EDX MOV RAX,qword ptr [RBP + -0x10] ADD RAX,0x18 MOV qword ptr [RBP + -0x30],RAX MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x8] MOV RAX,qword ptr [RAX + 0x170] MOV qword ptr [RBP + -0x38],RAX CMP qword ptr [RBP + -0x38],-0x1 JNZ 0x001a18a7 MOVSS XMM0,dword ptr [0x00251014] MOVSS dword ptr [RBP + -0x4],XMM0 JMP 0x001a195a LAB_001a18a7: MOV dword ptr [RBP + -0x20],0x0 MOV RAX,qword ptr [RBP + -0x10] MOV EAX,dword ptr [RAX + 0x10] MOV dword ptr [RBP + -0x24],EAX MOV EAX,dword ptr [RBP + -0x20] ADD EAX,dword ptr [RBP + -0x24] MOV ECX,0x2 CDQ IDIV ECX MOV dword ptr [RBP + -0x28],EAX LAB_001a18c9: MOV EAX,dword ptr [RBP + -0x24] SUB EAX,dword ptr [RBP + -0x20] CMP EAX,0x1 JLE 0x001a190f MOV RAX,qword ptr [RBP + -0x30] MOVSXD RCX,dword ptr [RBP + -0x28] SHL RCX,0x4 ADD RAX,RCX MOV RAX,qword ptr [RAX] CMP RAX,qword ptr [RBP + -0x38] JBE 0x001a18f4 MOV EAX,dword ptr [RBP + -0x28] MOV dword ptr [RBP + -0x24],EAX JMP 0x001a18fa LAB_001a18f4: MOV EAX,dword ptr [RBP + -0x28] MOV dword ptr [RBP + -0x20],EAX LAB_001a18fa: JMP 0x001a18fc LAB_001a18fc: MOV EAX,dword ptr [RBP + -0x20] ADD EAX,dword ptr [RBP + -0x24] MOV ECX,0x2 CDQ IDIV ECX MOV dword ptr [RBP + -0x28],EAX JMP 0x001a18c9 LAB_001a190f: MOV EAX,dword ptr [RBP + -0x20] MOV RCX,qword ptr [RBP + -0x10] CMP EAX,dword ptr [RCX + 0x10] JGE 0x001a1952 MOV RAX,qword ptr [RBP + -0x30] MOVSXD RCX,dword ptr [RBP + -0x20] SHL RCX,0x4 ADD RAX,RCX MOV RAX,qword ptr [RAX] CMP RAX,qword ptr [RBP + -0x38] JNZ 0x001a1952 MOV RAX,qword ptr [RBP + -0x30] MOVSXD RCX,dword ptr [RBP + -0x20] SHL RCX,0x4 ADD RAX,RCX MOVSD XMM0,qword ptr [RAX + 0x8] CVTSD2SS XMM0,XMM0 MOVSS dword ptr [RBP + -0x4],XMM0 JMP 0x001a195a LAB_001a1952: XORPS XMM0,XMM0 MOVSS dword ptr [RBP + -0x4],XMM0 LAB_001a195a: MOVSS XMM0,dword ptr [RBP + -0x4] POP RBP RET
float ft_nlq_find_relevance(long param_1) { ulong uVar1; long lVar2; int4 local_30; int4 local_2c; int4 local_28; int4 local_c; lVar2 = param_1 + 0x18; uVar1 = *(ulong *)(*(long *)(param_1 + 8) + 0x170); if (uVar1 == 0xffffffffffffffff) { local_c = DAT_00251014; } else { local_28 = 0; local_2c = *(int *)(param_1 + 0x10); local_30 = local_2c; while (local_30 = local_30 / 2, 1 < local_2c - local_28) { if (uVar1 < *(ulong *)(lVar2 + (long)local_30 * 0x10)) { local_2c = local_30; } else { local_28 = local_30; } local_30 = local_28 + local_2c; } if ((local_28 < *(int *)(param_1 + 0x10)) && (*(ulong *)(lVar2 + (long)local_28 * 0x10) == uVar1)) { local_c = (float)*(double *)(lVar2 + (long)local_28 * 0x10 + 8); } else { local_c = 0.0; } } return local_c; }
31,859
wqueue_add_to_queue
eloqsql/mysys/wqueue.c
void wqueue_add_to_queue(WQUEUE *wqueue, struct st_my_thread_var *thread) { struct st_my_thread_var *last; if (!(last= wqueue->last_thread)) thread->next= thread; else { thread->next= last->next; last->next= thread; } #ifndef DBUG_OFF thread->prev= NULL; /* force segfault if used */ #endif wqueue->last_thread= thread; }
O0
c
wqueue_add_to_queue: pushq %rbp movq %rsp, %rbp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq -0x8(%rbp), %rax movq (%rax), %rax movq %rax, -0x18(%rbp) cmpq $0x0, %rax jne 0xff76e movq -0x10(%rbp), %rcx movq -0x10(%rbp), %rax movq %rcx, 0x88(%rax) jmp 0xff793 movq -0x18(%rbp), %rax movq 0x88(%rax), %rcx movq -0x10(%rbp), %rax movq %rcx, 0x88(%rax) movq -0x10(%rbp), %rcx movq -0x18(%rbp), %rax movq %rcx, 0x88(%rax) movq -0x10(%rbp), %rcx movq -0x8(%rbp), %rax movq %rcx, (%rax) popq %rbp retq
wqueue_add_to_queue: push rbp mov rbp, rsp mov [rbp+var_8], rdi mov [rbp+var_10], rsi mov rax, [rbp+var_8] mov rax, [rax] mov [rbp+var_18], rax cmp rax, 0 jnz short loc_FF76E mov rcx, [rbp+var_10] mov rax, [rbp+var_10] mov [rax+88h], rcx jmp short loc_FF793 loc_FF76E: mov rax, [rbp+var_18] mov rcx, [rax+88h] mov rax, [rbp+var_10] mov [rax+88h], rcx mov rcx, [rbp+var_10] mov rax, [rbp+var_18] mov [rax+88h], rcx loc_FF793: mov rcx, [rbp+var_10] mov rax, [rbp+var_8] mov [rax], rcx pop rbp retn
_QWORD * wqueue_add_to_queue(_QWORD *a1, long long a2) { _QWORD *result; // rax long long v3; // [rsp+0h] [rbp-18h] v3 = *a1; if ( *a1 ) { *(_QWORD *)(a2 + 136) = *(_QWORD *)(v3 + 136); *(_QWORD *)(v3 + 136) = a2; } else { *(_QWORD *)(a2 + 136) = a2; } result = a1; *a1 = a2; return result; }
wqueue_add_to_queue: PUSH RBP MOV RBP,RSP MOV qword ptr [RBP + -0x8],RDI MOV qword ptr [RBP + -0x10],RSI MOV RAX,qword ptr [RBP + -0x8] MOV RAX,qword ptr [RAX] MOV qword ptr [RBP + -0x18],RAX CMP RAX,0x0 JNZ 0x001ff76e MOV RCX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RBP + -0x10] MOV qword ptr [RAX + 0x88],RCX JMP 0x001ff793 LAB_001ff76e: MOV RAX,qword ptr [RBP + -0x18] MOV RCX,qword ptr [RAX + 0x88] MOV RAX,qword ptr [RBP + -0x10] MOV qword ptr [RAX + 0x88],RCX MOV RCX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RBP + -0x18] MOV qword ptr [RAX + 0x88],RCX LAB_001ff793: MOV RCX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RBP + -0x8] MOV qword ptr [RAX],RCX POP RBP RET
void wqueue_add_to_queue(long *param_1,long param_2) { long lVar1; lVar1 = *param_1; if (lVar1 == 0) { *(long *)(param_2 + 0x88) = param_2; } else { *(int8 *)(param_2 + 0x88) = *(int8 *)(lVar1 + 0x88); *(long *)(lVar1 + 0x88) = param_2; } *param_1 = param_2; return; }
31,860
Catch::BinaryExpr<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, char const (&) [9]>::streamReconstructedExpression(std::ostream&) const
11AgReS1SoR11[P]Graph/build_O2/_deps/catch2-src/src/catch2/../catch2/internal/catch_decomposer.hpp
void streamReconstructedExpression( std::ostream &os ) const override { formatReconstructedExpression ( os, Catch::Detail::stringify( m_lhs ), m_op, Catch::Detail::stringify( m_rhs ) ); }
O2
cpp
Catch::BinaryExpr<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, char const (&) [9]>::streamReconstructedExpression(std::ostream&) const: pushq %r15 pushq %r14 pushq %r12 pushq %rbx subq $0x48, %rsp movq %rsi, %rbx movq %rdi, %r12 movq 0x10(%rdi), %rsi leaq 0x28(%rsp), %rdi callq 0x3a612 movq 0x18(%r12), %r14 movq 0x20(%r12), %r15 movq 0x28(%r12), %rsi leaq 0x8(%rsp), %rdi callq 0x341e2 leaq 0x28(%rsp), %rsi leaq 0x8(%rsp), %r8 movq %rbx, %rdi movq %r14, %rdx movq %r15, %rcx callq 0x45070 leaq 0x8(%rsp), %rdi callq 0x11250 leaq 0x28(%rsp), %rdi callq 0x11250 addq $0x48, %rsp popq %rbx popq %r12 popq %r14 popq %r15 retq movq %rax, %rbx leaq 0x8(%rsp), %rdi callq 0x11250 jmp 0x341ba movq %rax, %rbx leaq 0x28(%rsp), %rdi callq 0x11250 movq %rbx, %rdi callq 0x119b0
_ZNK5Catch10BinaryExprIRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERA8_KcE29streamReconstructedExpressionERSo: push r15 push r14 push r12 push rbx sub rsp, 48h mov rbx, rsi mov r12, rdi mov rsi, [rdi+10h] lea rdi, [rsp+68h+var_40] call _ZN5Catch11StringMakerINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEvE7convertERKS6_; Catch::StringMaker<std::string,void>::convert(std::string const&) mov r14, [r12+18h] mov r15, [r12+20h] mov rsi, [r12+28h] lea rdi, [rsp+68h+var_60] call _ZN5Catch11StringMakerIA8_cvE7convertB5cxx11EPKc; Catch::StringMaker<char [8],void>::convert(char const*) lea rsi, [rsp+68h+var_40] lea r8, [rsp+68h+var_60] mov rdi, rbx mov rdx, r14 mov rcx, r15 call _ZN5Catch29formatReconstructedExpressionERSoRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEENS_9StringRefES8_; Catch::formatReconstructedExpression(std::ostream &,std::string const&,Catch::StringRef,std::string const&) lea rdi, [rsp+68h+var_60] call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() lea rdi, [rsp+68h+var_40] call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() add rsp, 48h pop rbx pop r12 pop r14 pop r15 retn mov rbx, rax lea rdi, [rsp+arg_0] call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() jmp short loc_341BA mov rbx, rax loc_341BA: lea rdi, [rsp+arg_20] call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() mov rdi, rbx call __Unwind_Resume
long long Catch::BinaryExpr<std::string const&,char const(&)[8]>::streamReconstructedExpression( _QWORD *a1, long long a2) { long long v2; // r14 long long v3; // r15 _BYTE v5[32]; // [rsp+8h] [rbp-60h] BYREF _BYTE v6[64]; // [rsp+28h] [rbp-40h] BYREF Catch::StringMaker<std::string,void>::convert(v6, a1[2]); v2 = a1[3]; v3 = a1[4]; Catch::StringMaker<char [8],void>::convert[abi:cxx11](v5, a1[5]); Catch::formatReconstructedExpression(a2, v6, v2, v3, v5); std::string::~string(v5); return std::string::~string(v6); }
streamReconstructedExpression: PUSH R15 PUSH R14 PUSH R12 PUSH RBX SUB RSP,0x48 MOV RBX,RSI MOV R12,RDI MOV RSI,qword ptr [RDI + 0x10] LEA RDI,[RSP + 0x28] CALL 0x0013a612 MOV R14,qword ptr [R12 + 0x18] MOV R15,qword ptr [R12 + 0x20] MOV RSI,qword ptr [R12 + 0x28] LAB_00134166: LEA RDI,[RSP + 0x8] CALL 0x001341e2 LAB_00134170: LEA RSI,[RSP + 0x28] LEA R8,[RSP + 0x8] MOV RDI,RBX MOV RDX,R14 MOV RCX,R15 CALL 0x00145070 LAB_00134188: LEA RDI,[RSP + 0x8] CALL 0x00111250 LEA RDI,[RSP + 0x28] CALL 0x00111250 ADD RSP,0x48 POP RBX POP R12 POP R14 POP R15 RET
/* Catch::BinaryExpr<std::__cxx11::string const&, char const (&) [8]>::streamReconstructedExpression(std::ostream&) const */ void __thiscall Catch::BinaryExpr<std::__cxx11::string_const&,char_const(&)[8]>::streamReconstructedExpression (BinaryExpr<std::__cxx11::string_const&,char_const(&)[8]> *this,ostream *param_1) { int8 uVar1; int8 uVar2; StringMaker<char[8],void> local_60 [32]; StringMaker<std::__cxx11::string,void> local_40 [32]; StringMaker<std::__cxx11::string,void>::convert(local_40,*(string **)(this + 0x10)); uVar1 = *(int8 *)(this + 0x18); uVar2 = *(int8 *)(this + 0x20); /* try { // try from 00134166 to 0013416f has its CatchHandler @ 001341b7 */ StringMaker<char[8],void>::convert_abi_cxx11_(local_60,*(char **)(this + 0x28)); /* try { // try from 00134170 to 00134187 has its CatchHandler @ 001341a8 */ formatReconstructedExpression((Catch *)param_1,local_40,uVar1,uVar2,local_60); std::__cxx11::string::~string((string *)local_60); std::__cxx11::string::~string((string *)local_40); return; }
31,861
FTB_WORD_cmp_list
eloqsql/storage/myisam/ft_boolean_search.c
static int FTB_WORD_cmp_list(CHARSET_INFO *cs, FTB_WORD **a, FTB_WORD **b) { /* ORDER BY word, ndepth */ int i= ha_compare_text(cs, (uchar*) (*a)->word + 1, (*a)->len - 1, (uchar*) (*b)->word + 1, (*b)->len - 1, 0); if (!i) i= CMP_NUM((*a)->ndepth, (*b)->ndepth); return i; }
O3
c
FTB_WORD_cmp_list: pushq %rbp movq %rsp, %rbp pushq %r14 pushq %rbx movq %rdx, %rbx movq %rsi, %r14 movq (%rsi), %rsi movl 0x48(%rsi), %edx addq $0x4e, %rsi decl %edx movq (%rbx), %rcx movl 0x48(%rcx), %r8d addq $0x4e, %rcx decl %r8d xorl %r9d, %r9d callq 0x9f6dc testl %eax, %eax jne 0x72b66 movq (%r14), %rax movl 0x44(%rax), %eax movq (%rbx), %rcx xorl %edx, %edx cmpl 0x44(%rcx), %eax setne %dl movl $0xffffffff, %eax # imm = 0xFFFFFFFF cmovael %edx, %eax popq %rbx popq %r14 popq %rbp retq
FTB_WORD_cmp_list: push rbp mov rbp, rsp push r14 push rbx mov rbx, rdx mov r14, rsi mov rsi, [rsi] mov edx, [rsi+48h] add rsi, 4Eh ; 'N' dec edx mov rcx, [rbx] mov r8d, [rcx+48h] add rcx, 4Eh ; 'N' dec r8d xor r9d, r9d call ha_compare_text test eax, eax jnz short loc_72B66 mov rax, [r14] mov eax, [rax+44h] mov rcx, [rbx] xor edx, edx cmp eax, [rcx+44h] setnz dl mov eax, 0FFFFFFFFh cmovnb eax, edx loc_72B66: pop rbx pop r14 pop rbp retn
long long FTB_WORD_cmp_list(long long a1, long long a2, long long a3) { long long result; // rax unsigned int v5; // eax bool v6; // cf BOOL v7; // edx result = ha_compare_text( a1, *(_QWORD *)a2 + 78LL, (unsigned int)(*(_DWORD *)(*(_QWORD *)a2 + 72LL) - 1), *(_QWORD *)a3 + 78LL, (unsigned int)(*(_DWORD *)(*(_QWORD *)a3 + 72LL) - 1), 0LL); if ( !(_DWORD)result ) { v5 = *(_DWORD *)(*(_QWORD *)a2 + 68LL); v6 = v5 < *(_DWORD *)(*(_QWORD *)a3 + 68LL); v7 = v5 != *(_DWORD *)(*(_QWORD *)a3 + 68LL); result = 0xFFFFFFFFLL; if ( !v6 ) return v7; } return result; }
FTB_WORD_cmp_list: PUSH RBP MOV RBP,RSP PUSH R14 PUSH RBX MOV RBX,RDX MOV R14,RSI MOV RSI,qword ptr [RSI] MOV EDX,dword ptr [RSI + 0x48] ADD RSI,0x4e DEC EDX MOV RCX,qword ptr [RBX] MOV R8D,dword ptr [RCX + 0x48] ADD RCX,0x4e DEC R8D XOR R9D,R9D CALL 0x0019f6dc TEST EAX,EAX JNZ 0x00172b66 MOV RAX,qword ptr [R14] MOV EAX,dword ptr [RAX + 0x44] MOV RCX,qword ptr [RBX] XOR EDX,EDX CMP EAX,dword ptr [RCX + 0x44] SETNZ DL MOV EAX,0xffffffff CMOVNC EAX,EDX LAB_00172b66: POP RBX POP R14 POP RBP RET
ulong FTB_WORD_cmp_list(int8 param_1,long *param_2,long *param_3) { ulong uVar1; uVar1 = ha_compare_text(param_1,*param_2 + 0x4e,*(int *)(*param_2 + 0x48) + -1,*param_3 + 0x4e, *(int *)(*param_3 + 0x48) + -1,0); if ((int)uVar1 == 0) { uVar1 = 0xffffffff; if (*(uint *)(*param_3 + 0x44) <= *(uint *)(*param_2 + 0x44)) { uVar1 = (ulong)(*(uint *)(*param_2 + 0x44) != *(uint *)(*param_3 + 0x44)); } } return uVar1; }
31,862
parse_device_list(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&)
monkey531[P]llama/common/arg.cpp
static std::vector<ggml_backend_dev_t> parse_device_list(const std::string & value) { std::vector<ggml_backend_dev_t> devices; auto dev_names = string_split<std::string>(value, ','); if (dev_names.empty()) { throw std::invalid_argument("no devices specified"); } if (dev_names.size() == 1 && dev_names[0] == "none") { devices.push_back(nullptr); } else { for (const auto & device : dev_names) { auto * dev = ggml_backend_dev_by_name(device.c_str()); if (!dev || ggml_backend_dev_type(dev) != GGML_BACKEND_DEVICE_TYPE_GPU) { throw std::invalid_argument(string_format("invalid device: %s", device.c_str())); } devices.push_back(dev); } devices.push_back(nullptr); } return devices; }
O0
cpp
parse_device_list(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&): subq $0xd8, %rsp movq %rdi, 0x28(%rsp) movq %rdi, %rax movq %rax, 0x30(%rsp) movq %rdi, 0xd0(%rsp) movq %rsi, 0xc8(%rsp) movb $0x0, 0xc7(%rsp) callq 0x63140 movq 0xc8(%rsp), %rsi leaq 0xa8(%rsp), %rdi movl $0x2c, %edx callq 0x846b0 jmp 0x88add leaq 0xa8(%rsp), %rdi callq 0x8ed60 testb $0x1, %al jne 0x88af3 jmp 0x88b88 movl $0x10, %edi callq 0x59660 movq %rax, %rdi movq %rdi, %rax movq %rax, 0x20(%rsp) leaq 0x186f5f(%rip), %rsi # 0x20fa6e callq 0x59300 jmp 0x88b16 movq 0x20(%rsp), %rdi movq 0x21b406(%rip), %rsi # 0x2a3f28 movq 0x21b3f7(%rip), %rdx # 0x2a3f20 callq 0x59ad0 jmp 0x88de9 movq %rax, %rcx movl %edx, %eax movq %rcx, 0xa0(%rsp) movl %eax, 0x9c(%rsp) jmp 0x88dd2 movq 0x20(%rsp), %rdi movq %rax, %rcx movl %edx, %eax movq %rcx, 0xa0(%rsp) movl %eax, 0x9c(%rsp) callq 0x59f20 jmp 0x88dac movq %rax, %rcx movl %edx, %eax movq %rcx, 0xa0(%rsp) movl %eax, 0x9c(%rsp) jmp 0x88dac leaq 0xa8(%rsp), %rdi callq 0x62d10 cmpq $0x1, %rax jne 0x88bf0 xorl %eax, %eax movl %eax, %esi leaq 0xa8(%rsp), %rdi callq 0x8eed0 movq %rax, %rdi leaq 0x181dfd(%rip), %rsi # 0x20a9b3 callq 0x62db0 movb %al, 0x1f(%rsp) jmp 0x88bc1 movb 0x1f(%rsp), %al testb $0x1, %al jne 0x88bcb jmp 0x88bf0 movq 0x28(%rsp), %rdi movq $0x0, 0x90(%rsp) leaq 0x90(%rsp), %rsi callq 0xbfb70 jmp 0x88beb jmp 0x88d8b leaq 0xa8(%rsp), %rax movq %rax, 0x88(%rsp) movq 0x88(%rsp), %rdi callq 0x67300 movq %rax, 0x80(%rsp) movq 0x88(%rsp), %rdi callq 0x67330 movq %rax, 0x78(%rsp) leaq 0x80(%rsp), %rdi leaq 0x78(%rsp), %rsi callq 0x67360 testb $0x1, %al jne 0x88c42 jmp 0x88d6f leaq 0x80(%rsp), %rdi callq 0x673a0 movq %rax, 0x70(%rsp) movq 0x70(%rsp), %rdi callq 0x591b0 movq %rax, %rdi callq 0x593b0 movq %rax, 0x10(%rsp) jmp 0x88c6d movq 0x10(%rsp), %rax movq %rax, 0x68(%rsp) cmpq $0x0, 0x68(%rsp) je 0x88c9c movq 0x68(%rsp), %rdi callq 0x599f0 movl %eax, 0xc(%rsp) jmp 0x88c8f movl 0xc(%rsp), %eax cmpl $0x1, %eax je 0x88d4a movb $0x1, 0x47(%rsp) movl $0x10, %edi callq 0x59660 movq %rax, (%rsp) movq 0x70(%rsp), %rdi callq 0x591b0 movq %rax, %rdx leaq 0x186dc0(%rip), %rsi # 0x20fa83 xorl %eax, %eax leaq 0x48(%rsp), %rdi callq 0xee920 jmp 0x88cd1 movq (%rsp), %rdi leaq 0x48(%rsp), %rsi callq 0x59a10 jmp 0x88ce1 movq (%rsp), %rdi movb $0x0, 0x47(%rsp) movq 0x21b237(%rip), %rsi # 0x2a3f28 movq 0x21b228(%rip), %rdx # 0x2a3f20 callq 0x59ad0 jmp 0x88de9 movq %rax, %rcx movl %edx, %eax movq %rcx, 0xa0(%rsp) movl %eax, 0x9c(%rsp) jmp 0x88d36 movq %rax, %rcx movl %edx, %eax movq %rcx, 0xa0(%rsp) movl %eax, 0x9c(%rsp) leaq 0x48(%rsp), %rdi callq 0x5a4d8 testb $0x1, 0x47(%rsp) jne 0x88d3f jmp 0x88d48 movq (%rsp), %rdi callq 0x59f20 jmp 0x88dac movq 0x28(%rsp), %rdi leaq 0x68(%rsp), %rsi callq 0xbfba0 jmp 0x88d5b jmp 0x88d5d leaq 0x80(%rsp), %rdi callq 0x673e0 jmp 0x88c27 movq 0x28(%rsp), %rdi movq $0x0, 0x38(%rsp) leaq 0x38(%rsp), %rsi callq 0xbfb70 jmp 0x88d89 jmp 0x88d8b movb $0x1, 0xc7(%rsp) leaq 0xa8(%rsp), %rdi callq 0x62de0 testb $0x1, 0xc7(%rsp) jne 0x88dc5 jmp 0x88dbb leaq 0xa8(%rsp), %rdi callq 0x62de0 jmp 0x88dd2 movq 0x28(%rsp), %rdi callq 0x63df0 movq 0x30(%rsp), %rax addq $0xd8, %rsp retq movq 0x28(%rsp), %rdi callq 0x63df0 movq 0xa0(%rsp), %rdi callq 0x59b90 nopl (%rax)
_ZL17parse_device_listRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE: sub rsp, 0D8h mov [rsp+0D8h+var_B0], rdi mov rax, rdi mov [rsp+0D8h+var_A8], rax mov [rsp+0D8h+var_8], rdi mov [rsp+0D8h+var_10], rsi mov [rsp+0D8h+var_11], 0 call _ZNSt6vectorIP19ggml_backend_deviceSaIS1_EEC2Ev; std::vector<ggml_backend_device *>::vector(void) mov rsi, [rsp+0D8h+var_10] lea rdi, [rsp+0D8h+var_30] mov edx, 2Ch ; ',' call _ZL12string_splitINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEESt6vectorIT_SaIS7_EERKS5_c; string_split<std::string>(std::string const&,char) jmp short $+2 loc_88ADD: lea rdi, [rsp+0D8h+var_30] call _ZNKSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE5emptyEv; std::vector<std::string>::empty(void) test al, 1 jnz short loc_88AF3 jmp loc_88B88 loc_88AF3: mov edi, 10h; thrown_size call ___cxa_allocate_exception mov rdi, rax; this mov rax, rdi mov [rsp+0D8h+var_B8], rax lea rsi, aNoDevicesSpeci; "no devices specified" call __ZNSt16invalid_argumentC1EPKc; std::invalid_argument::invalid_argument(char const*) jmp short $+2 loc_88B16: mov rdi, [rsp+0D8h+var_B8]; void * mov rsi, cs:lptinfo; lptinfo mov rdx, cs:_ZNSt16invalid_argumentD1Ev_ptr; void (*)(void *) call ___cxa_throw jmp loc_88DE9 mov rcx, rax mov eax, edx mov [rsp+arg_98], rcx mov [rsp+arg_94], eax jmp loc_88DD2 mov rdi, [rsp+arg_18]; void * mov rcx, rax mov eax, edx mov [rsp+arg_98], rcx mov [rsp+arg_94], eax call ___cxa_free_exception jmp loc_88DAC mov rcx, rax mov eax, edx mov [rsp+arg_98], rcx mov [rsp+arg_94], eax jmp loc_88DAC loc_88B88: lea rdi, [rsp+0D8h+var_30] call _ZNKSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE4sizeEv; std::vector<std::string>::size(void) cmp rax, 1 jnz short loc_88BF0 xor eax, eax mov esi, eax lea rdi, [rsp+0D8h+var_30] call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EEixEm; std::vector<std::string>::operator[](ulong) mov rdi, rax lea rsi, aNone; "none" call _ZSteqIcSt11char_traitsIcESaIcEEbRKNSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_; std::operator==<char>(std::string const&,char const*) mov [rsp+0D8h+var_B9], al jmp short $+2 loc_88BC1: mov al, [rsp+0D8h+var_B9] test al, 1 jnz short loc_88BCB jmp short loc_88BF0 loc_88BCB: mov rdi, [rsp+0D8h+var_B0] mov [rsp+0D8h+var_48], 0 lea rsi, [rsp+0D8h+var_48] call _ZNSt6vectorIP19ggml_backend_deviceSaIS1_EE9push_backEOS1_; std::vector<ggml_backend_device *>::push_back(ggml_backend_device *&&) jmp short $+2 loc_88BEB: jmp loc_88D8B loc_88BF0: lea rax, [rsp+0D8h+var_30] mov [rsp+0D8h+var_50], rax mov rdi, [rsp+0D8h+var_50] call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE5beginEv; std::vector<std::string>::begin(void) mov [rsp+0D8h+var_58], rax mov rdi, [rsp+0D8h+var_50] call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE3endEv; std::vector<std::string>::end(void) mov [rsp+0D8h+var_60], rax loc_88C27: lea rdi, [rsp+0D8h+var_58] lea rsi, [rsp+0D8h+var_60] call _ZN9__gnu_cxxneIPNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt6vectorIS6_SaIS6_EEEEbRKNS_17__normal_iteratorIT_T0_EESG_; __gnu_cxx::operator!=<std::string *,std::vector<std::string>>(__gnu_cxx::__normal_iterator<std::string *,std::vector<std::string>> const&,__gnu_cxx::__normal_iterator<std::string *,std::vector<std::string>> const&) test al, 1 jnz short loc_88C42 jmp loc_88D6F loc_88C42: lea rdi, [rsp+0D8h+var_58] call _ZNK9__gnu_cxx17__normal_iteratorIPNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt6vectorIS6_SaIS6_EEEdeEv; __gnu_cxx::__normal_iterator<std::string *,std::vector<std::string>>::operator*(void) mov [rsp+0D8h+var_68], rax mov rdi, [rsp+0D8h+var_68] call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5c_strEv; std::string::c_str(void) mov rdi, rax call _ggml_backend_dev_by_name mov [rsp+0D8h+var_C8], rax jmp short $+2 loc_88C6D: mov rax, [rsp+0D8h+var_C8] mov [rsp+0D8h+var_70], rax cmp [rsp+0D8h+var_70], 0 jz short loc_88C9C mov rdi, [rsp+0D8h+var_70] call _ggml_backend_dev_type mov [rsp+0D8h+var_CC], eax jmp short $+2 loc_88C8F: mov eax, [rsp+0D8h+var_CC] cmp eax, 1 jz loc_88D4A loc_88C9C: mov [rsp+0D8h+var_91], 1 mov edi, 10h; thrown_size call ___cxa_allocate_exception mov [rsp+0D8h+var_D8], rax mov rdi, [rsp+0D8h+var_68] call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5c_strEv; std::string::c_str(void) mov rdx, rax lea rsi, aInvalidDeviceS; "invalid device: %s" xor eax, eax lea rdi, [rsp+0D8h+var_90] call _Z13string_formatB5cxx11PKcz; string_format(char const*,...) jmp short $+2 loc_88CD1: mov rdi, [rsp+0D8h+var_D8] lea rsi, [rsp+0D8h+var_90] call __ZNSt16invalid_argumentC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; std::invalid_argument::invalid_argument(std::string const&) jmp short $+2 loc_88CE1: mov rdi, [rsp+0D8h+var_D8]; void * mov [rsp+0D8h+var_91], 0 mov rsi, cs:lptinfo; lptinfo mov rdx, cs:_ZNSt16invalid_argumentD1Ev_ptr; void (*)(void *) call ___cxa_throw jmp loc_88DE9 mov rcx, rax mov eax, edx mov [rsp+arg_98], rcx mov [rsp+arg_94], eax jmp short loc_88D36 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_88D36: test [rsp+arg_3F], 1 jnz short loc_88D3F jmp short loc_88D48 loc_88D3F: mov rdi, [rsp+0]; void * call ___cxa_free_exception loc_88D48: jmp short loc_88DAC loc_88D4A: mov rdi, [rsp+0D8h+var_B0] lea rsi, [rsp+0D8h+var_70] call _ZNSt6vectorIP19ggml_backend_deviceSaIS1_EE9push_backERKS1_; std::vector<ggml_backend_device *>::push_back(ggml_backend_device * const&) jmp short $+2 loc_88D5B: jmp short $+2 loc_88D5D: lea rdi, [rsp+0D8h+var_58] call _ZN9__gnu_cxx17__normal_iteratorIPNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt6vectorIS6_SaIS6_EEEppEv; __gnu_cxx::__normal_iterator<std::string *,std::vector<std::string>>::operator++(void) jmp loc_88C27 loc_88D6F: mov rdi, [rsp+0D8h+var_B0] mov [rsp+0D8h+var_A0], 0 lea rsi, [rsp+0D8h+var_A0] call _ZNSt6vectorIP19ggml_backend_deviceSaIS1_EE9push_backEOS1_; std::vector<ggml_backend_device *>::push_back(ggml_backend_device *&&) jmp short $+2 loc_88D89: jmp short $+2 loc_88D8B: mov [rsp+0D8h+var_11], 1 lea rdi, [rsp+0D8h+var_30] call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EED2Ev; std::vector<std::string>::~vector() test [rsp+0D8h+var_11], 1 jnz short loc_88DC5 jmp short loc_88DBB loc_88DAC: lea rdi, [rsp+arg_A0] call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EED2Ev; std::vector<std::string>::~vector() jmp short loc_88DD2 loc_88DBB: mov rdi, [rsp+0D8h+var_B0] call _ZNSt6vectorIP19ggml_backend_deviceSaIS1_EED2Ev; std::vector<ggml_backend_device *>::~vector() loc_88DC5: mov rax, [rsp+0D8h+var_A8] add rsp, 0D8h retn loc_88DD2: mov rdi, [rsp+arg_20] call _ZNSt6vectorIP19ggml_backend_deviceSaIS1_EED2Ev; std::vector<ggml_backend_device *>::~vector() mov rdi, [rsp+arg_98] call __Unwind_Resume loc_88DE9: nop dword ptr [rax+00000000h]
long long * parse_device_list(long long *a1, long long a2) { long long v2; // rax long long v3; // rax int v4; // eax int v5; // ecx int v6; // r8d int v7; // r9d void *v9; // [rsp+0h] [rbp-D8h] std::invalid_argument *exception; // [rsp+20h] [rbp-B8h] long long v11; // [rsp+38h] [rbp-A0h] BYREF char v12; // [rsp+47h] [rbp-91h] _BYTE v13[32]; // [rsp+48h] [rbp-90h] BYREF long long v14; // [rsp+68h] [rbp-70h] BYREF long long v15; // [rsp+70h] [rbp-68h] long long v16; // [rsp+78h] [rbp-60h] BYREF _QWORD v17[2]; // [rsp+80h] [rbp-58h] BYREF _QWORD v18[3]; // [rsp+90h] [rbp-48h] BYREF long long v19[3]; // [rsp+A8h] [rbp-30h] BYREF char v20; // [rsp+C7h] [rbp-11h] long long v21; // [rsp+C8h] [rbp-10h] long long *v22; // [rsp+D0h] [rbp-8h] v22 = a1; v21 = a2; v20 = 0; std::vector<ggml_backend_device *>::vector((long long)a1); string_split<std::string>((long long)v19, a2, 44); if ( (std::vector<std::string>::empty(v19) & 1) != 0 ) { exception = (std::invalid_argument *)__cxa_allocate_exception(0x10uLL); std::invalid_argument::invalid_argument(exception, "no devices specified"); __cxa_throw( exception, (struct type_info *)&`typeinfo for'std::invalid_argument, (void (*)(void *))&std::invalid_argument::~invalid_argument); } if ( std::vector<std::string>::size(v19) == 1 && (v2 = std::vector<std::string>::operator[](v19, 0LL), std::operator==<char>(v2, (long long)"none")) ) { v18[0] = 0LL; std::vector<ggml_backend_device *>::push_back(a1, v18); } else { v17[1] = v19; v17[0] = std::vector<std::string>::begin((long long)v19); v16 = std::vector<std::string>::end((long long)v19); while ( __gnu_cxx::operator!=<std::string *,std::vector<std::string>>((long long)v17, (long long)&v16) ) { v15 = __gnu_cxx::__normal_iterator<std::string *,std::vector<std::string>>::operator*((long long)v17); v3 = std::string::c_str(v15); v14 = ggml_backend_dev_by_name(v3); if ( !v14 || (unsigned int)ggml_backend_dev_type(v14) != 1 ) { v9 = __cxa_allocate_exception(0x10uLL); v4 = std::string::c_str(v15); string_format[abi:cxx11]((unsigned int)v13, (unsigned int)"invalid device: %s", v4, v5, v6, v7); std::invalid_argument::invalid_argument(v9, v13); v12 = 0; __cxa_throw( v9, (struct type_info *)&`typeinfo for'std::invalid_argument, (void (*)(void *))&std::invalid_argument::~invalid_argument); } std::vector<ggml_backend_device *>::push_back(a1, &v14); __gnu_cxx::__normal_iterator<std::string *,std::vector<std::string>>::operator++(v17); } v11 = 0LL; std::vector<ggml_backend_device *>::push_back(a1, &v11); } v20 = 1; std::vector<std::string>::~vector(v19); if ( (v20 & 1) == 0 ) std::vector<ggml_backend_device *>::~vector(a1); return a1; }
parse_device_list: SUB RSP,0xd8 MOV qword ptr [RSP + 0x28],RDI MOV RAX,RDI MOV qword ptr [RSP + 0x30],RAX MOV qword ptr [RSP + 0xd0],RDI MOV qword ptr [RSP + 0xc8],RSI MOV byte ptr [RSP + 0xc7],0x0 CALL 0x00163140 MOV RSI,qword ptr [RSP + 0xc8] LAB_00188ac9: LEA RDI,[RSP + 0xa8] MOV EDX,0x2c CALL 0x001846b0 LAB_00188adb: JMP 0x00188add LAB_00188add: LEA RDI,[RSP + 0xa8] CALL 0x0018ed60 TEST AL,0x1 JNZ 0x00188af3 JMP 0x00188b88 LAB_00188af3: MOV EDI,0x10 CALL 0x00159660 MOV RDI,RAX MOV RAX,RDI MOV qword ptr [RSP + 0x20],RAX LAB_00188b08: LEA RSI,[0x30fa6e] CALL 0x00159300 JMP 0x00188b16 LAB_00188b16: MOV RDI,qword ptr [RSP + 0x20] MOV RSI,qword ptr [0x003a3f28] MOV RDX,qword ptr [0x003a3f20] CALL 0x00159ad0 LAB_00188b88: LEA RDI,[RSP + 0xa8] CALL 0x00162d10 CMP RAX,0x1 JNZ 0x00188bf0 XOR EAX,EAX MOV ESI,EAX LEA RDI,[RSP + 0xa8] CALL 0x0018eed0 MOV RDI,RAX LAB_00188baf: LEA RSI,[0x30a9b3] CALL 0x00162db0 MOV byte ptr [RSP + 0x1f],AL JMP 0x00188bc1 LAB_00188bc1: MOV AL,byte ptr [RSP + 0x1f] TEST AL,0x1 JNZ 0x00188bcb JMP 0x00188bf0 LAB_00188bcb: MOV RDI,qword ptr [RSP + 0x28] MOV qword ptr [RSP + 0x90],0x0 LEA RSI,[RSP + 0x90] CALL 0x001bfb70 JMP 0x00188beb LAB_00188beb: JMP 0x00188d8b LAB_00188bf0: LEA RAX,[RSP + 0xa8] MOV qword ptr [RSP + 0x88],RAX MOV RDI,qword ptr [RSP + 0x88] CALL 0x00167300 MOV qword ptr [RSP + 0x80],RAX MOV RDI,qword ptr [RSP + 0x88] CALL 0x00167330 MOV qword ptr [RSP + 0x78],RAX LAB_00188c27: LEA RDI,[RSP + 0x80] LEA RSI,[RSP + 0x78] CALL 0x00167360 TEST AL,0x1 JNZ 0x00188c42 JMP 0x00188d6f LAB_00188c42: LEA RDI,[RSP + 0x80] CALL 0x001673a0 MOV qword ptr [RSP + 0x70],RAX MOV RDI,qword ptr [RSP + 0x70] CALL 0x001591b0 MOV RDI,RAX CALL 0x001593b0 MOV qword ptr [RSP + 0x10],RAX JMP 0x00188c6d LAB_00188c6d: MOV RAX,qword ptr [RSP + 0x10] MOV qword ptr [RSP + 0x68],RAX CMP qword ptr [RSP + 0x68],0x0 JZ 0x00188c9c MOV RDI,qword ptr [RSP + 0x68] CALL 0x001599f0 LAB_00188c89: MOV dword ptr [RSP + 0xc],EAX JMP 0x00188c8f LAB_00188c8f: MOV EAX,dword ptr [RSP + 0xc] CMP EAX,0x1 JZ 0x00188d4a LAB_00188c9c: MOV byte ptr [RSP + 0x47],0x1 MOV EDI,0x10 CALL 0x00159660 MOV qword ptr [RSP],RAX MOV RDI,qword ptr [RSP + 0x70] CALL 0x001591b0 MOV RDX,RAX LAB_00188cbc: LEA RSI,[0x30fa83] XOR EAX,EAX LEA RDI,[RSP + 0x48] CALL 0x001ee920 JMP 0x00188cd1 LAB_00188cd1: MOV RDI,qword ptr [RSP] LEA RSI,[RSP + 0x48] CALL 0x00159a10 JMP 0x00188ce1 LAB_00188ce1: MOV RDI,qword ptr [RSP] MOV byte ptr [RSP + 0x47],0x0 MOV RSI,qword ptr [0x003a3f28] MOV RDX,qword ptr [0x003a3f20] CALL 0x00159ad0 LAB_00188d4a: MOV RDI,qword ptr [RSP + 0x28] LEA RSI,[RSP + 0x68] CALL 0x001bfba0 JMP 0x00188d5b LAB_00188d5b: JMP 0x00188d5d LAB_00188d5d: LEA RDI,[RSP + 0x80] CALL 0x001673e0 JMP 0x00188c27 LAB_00188d6f: MOV RDI,qword ptr [RSP + 0x28] MOV qword ptr [RSP + 0x38],0x0 LEA RSI,[RSP + 0x38] CALL 0x001bfb70 LAB_00188d87: JMP 0x00188d89 LAB_00188d89: JMP 0x00188d8b LAB_00188d8b: MOV byte ptr [RSP + 0xc7],0x1 LEA RDI,[RSP + 0xa8] CALL 0x00162de0 TEST byte ptr [RSP + 0xc7],0x1 JNZ 0x00188dc5 JMP 0x00188dbb LAB_00188dbb: MOV RDI,qword ptr [RSP + 0x28] CALL 0x00163df0 LAB_00188dc5: MOV RAX,qword ptr [RSP + 0x30] ADD RSP,0xd8 RET
/* parse_device_list(std::__cxx11::string const&) */ string * parse_device_list(string *param_1) { bool bVar1; int iVar2; ulong uVar3; long lVar4; string *psVar5; int8 uVar6; invalid_argument *piVar7; char in_SIL; ggml_backend_device *local_a0; int1 local_91; string local_90 [32]; ggml_backend_device *local_70; int8 local_68; int8 local_60; int8 local_58; vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *local_50; ggml_backend_device *local_48 [3]; string local_30 [31]; byte local_11; char local_10; string *local_8; local_11 = 0; local_8 = param_1; local_10 = in_SIL; std::vector<ggml_backend_device*,std::allocator<ggml_backend_device*>>::vector ((vector<ggml_backend_device*,std::allocator<ggml_backend_device*>> *)param_1); /* try { // try from 00188ac9 to 00188ada has its CatchHandler @ 00188b33 */ string_split<std::__cxx11::string>(local_30,local_10); uVar3 = std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::empty ((vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *)local_30); if ((uVar3 & 1) != 0) { piVar7 = (invalid_argument *)__cxa_allocate_exception(0x10); /* try { // try from 00188b08 to 00188b13 has its CatchHandler @ 00188b4c */ std::invalid_argument::invalid_argument(piVar7,"no devices specified"); /* try { // try from 00188b16 to 00188b2d has its CatchHandler @ 00188b6f */ /* WARNING: Subroutine does not return */ __cxa_throw(piVar7,PTR_typeinfo_003a3f28,PTR__invalid_argument_003a3f20); } lVar4 = std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::size ((vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *)local_30); if (lVar4 == 1) { psVar5 = (string *) std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::operator[] ((vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *) local_30,0); /* try { // try from 00188baf to 00188c88 has its CatchHandler @ 00188b6f */ bVar1 = std::operator==(psVar5,"none"); if (bVar1) { local_48[0] = (ggml_backend_device *)0x0; std::vector<ggml_backend_device*,std::allocator<ggml_backend_device*>>::push_back ((vector<ggml_backend_device*,std::allocator<ggml_backend_device*>> *)param_1, local_48); goto LAB_00188d8b; } } local_50 = (vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *)local_30; local_58 = std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::begin(local_50) ; local_60 = std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::end(local_50); while (bVar1 = __gnu_cxx::operator!= ((__normal_iterator *)&local_58,(__normal_iterator *)&local_60), bVar1) { local_68 = __gnu_cxx:: __normal_iterator<std::__cxx11::string*,std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>> ::operator*((__normal_iterator<std::__cxx11::string*,std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>> *)&local_58); uVar6 = std::__cxx11::string::c_str(); local_70 = (ggml_backend_device *)ggml_backend_dev_by_name(uVar6); if ((local_70 == (ggml_backend_device *)0x0) || (iVar2 = ggml_backend_dev_type(local_70), iVar2 != 1)) { local_91 = 1; piVar7 = (invalid_argument *)__cxa_allocate_exception(0x10); uVar6 = std::__cxx11::string::c_str(); /* try { // try from 00188cbc to 00188cce has its CatchHandler @ 00188d02 */ string_format_abi_cxx11_((char *)local_90,"invalid device: %s",uVar6); /* try { // try from 00188cd1 to 00188cfc has its CatchHandler @ 00188d18 */ std::invalid_argument::invalid_argument(piVar7,local_90); local_91 = 0; /* WARNING: Subroutine does not return */ __cxa_throw(piVar7,PTR_typeinfo_003a3f28,PTR__invalid_argument_003a3f20); } /* try { // try from 00188d4a to 00188d86 has its CatchHandler @ 00188b6f */ std::vector<ggml_backend_device*,std::allocator<ggml_backend_device*>>::push_back ((vector<ggml_backend_device*,std::allocator<ggml_backend_device*>> *)param_1, &local_70); __gnu_cxx:: __normal_iterator<std::__cxx11::string*,std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>> ::operator++((__normal_iterator<std::__cxx11::string*,std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>> *)&local_58); } local_a0 = (ggml_backend_device *)0x0; std::vector<ggml_backend_device*,std::allocator<ggml_backend_device*>>::push_back ((vector<ggml_backend_device*,std::allocator<ggml_backend_device*>> *)param_1,&local_a0) ; LAB_00188d8b: local_11 = 1; std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::~vector ((vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *)local_30); if ((local_11 & 1) == 0) { std::vector<ggml_backend_device*,std::allocator<ggml_backend_device*>>::~vector ((vector<ggml_backend_device*,std::allocator<ggml_backend_device*>> *)param_1); } return param_1; }
31,863
glfwInputError
untodesu[P]riteg/build_O3/_deps/glfw-src/src/init.c
void _glfwInputError(int code, const char* format, ...) { _GLFWerror* error; char description[_GLFW_MESSAGE_SIZE]; if (format) { va_list vl; va_start(vl, format); vsnprintf(description, sizeof(description), format, vl); va_end(vl); description[sizeof(description) - 1] = '\0'; } else { if (code == GLFW_NOT_INITIALIZED) strcpy(description, "The GLFW library is not initialized"); else if (code == GLFW_NO_CURRENT_CONTEXT) strcpy(description, "There is no current context"); else if (code == GLFW_INVALID_ENUM) strcpy(description, "Invalid argument for enum parameter"); else if (code == GLFW_INVALID_VALUE) strcpy(description, "Invalid value for parameter"); else if (code == GLFW_OUT_OF_MEMORY) strcpy(description, "Out of memory"); else if (code == GLFW_API_UNAVAILABLE) strcpy(description, "The requested API is unavailable"); else if (code == GLFW_VERSION_UNAVAILABLE) strcpy(description, "The requested API version is unavailable"); else if (code == GLFW_PLATFORM_ERROR) strcpy(description, "A platform-specific error occurred"); else if (code == GLFW_FORMAT_UNAVAILABLE) strcpy(description, "The requested format is unavailable"); else if (code == GLFW_NO_WINDOW_CONTEXT) strcpy(description, "The specified window has no context"); else strcpy(description, "ERROR: UNKNOWN GLFW ERROR"); } if (_glfw.initialized) { error = _glfwPlatformGetTls(&_glfw.errorSlot); if (!error) { error = calloc(1, sizeof(_GLFWerror)); _glfwPlatformSetTls(&_glfw.errorSlot, error); _glfwPlatformLockMutex(&_glfw.errorLock); error->next = _glfw.errorListHead; _glfw.errorListHead = error; _glfwPlatformUnlockMutex(&_glfw.errorLock); } } else error = &_glfwMainThreadError; error->code = code; strcpy(error->description, description); if (_glfwErrorCallback) _glfwErrorCallback(code, description); }
O3
c
glfwInputError: pushq %r15 pushq %r14 pushq %r12 pushq %rbx subq $0x4d8, %rsp # imm = 0x4D8 movl %edi, %ebx movq %rdx, 0x30(%rsp) movq %rcx, 0x38(%rsp) movq %r8, 0x40(%rsp) movq %r9, 0x48(%rsp) testb %al, %al je 0x18ef0 movaps %xmm0, 0x50(%rsp) movaps %xmm1, 0x60(%rsp) movaps %xmm2, 0x70(%rsp) movaps %xmm3, 0x80(%rsp) movaps %xmm4, 0x90(%rsp) movaps %xmm5, 0xa0(%rsp) movaps %xmm6, 0xb0(%rsp) movaps %xmm7, 0xc0(%rsp) testq %rsi, %rsi je 0x18fbf movq %rsi, %r10 leaq 0x20(%rsp), %rax movq %rsp, %rcx movq %rax, 0x10(%rcx) leaq 0x500(%rsp), %rax movq %rax, 0x8(%rcx) movabsq $0x3000000010, %rax # imm = 0x3000000010 movq %rax, (%rcx) leaq 0xd0(%rsp), %r14 movl $0x400, %esi # imm = 0x400 movq %r14, %rdi movq %r10, %rdx callq 0xc500 movb $0x0, 0x3ff(%r14) leaq 0x8f6f0(%rip), %r12 # 0xa8638 cmpl $0x0, (%r12) je 0x1900c movl $0x1fe14, %edi # imm = 0x1FE14 addq 0x8e061(%rip), %rdi # 0xa6fc0 callq 0x25f2d movq %rax, %r14 testq %rax, %rax jne 0x19013 movl $0x1, %edi movl $0x410, %esi # imm = 0x410 callq 0xc550 movq %rax, %r14 leaq 0x1fe14(%r12), %rdi movq %rax, %rsi callq 0x25f5a leaq 0x1fe28(%r12), %r15 movq %r15, %rdi callq 0x26010 movq 0x3e0(%r12), %rax movq %rax, (%r14) movq %r14, 0x3e0(%r12) movq %r15, %rdi callq 0x2603e jmp 0x19013 leal -0x10001(%rbx), %eax cmpl $0x9, %eax ja 0x1918a leaq 0x4e89b(%rip), %rcx # 0x67870 movslq (%rcx,%rax,4), %rax addq %rcx, %rax jmpq *%rax movups 0x69a55(%rip), %xmm0 # 0x82a3a movaps %xmm0, 0xe0(%rsp) movups 0x69a36(%rip), %xmm0 # 0x82a2a movaps %xmm0, 0xd0(%rsp) movl $0x64657a, 0xf0(%rsp) # imm = 0x64657A jmp 0x18f41 leaq 0xaffb5(%rip), %r14 # 0xc8fc8 movl %ebx, 0x8(%r14) addq $0xc, %r14 leaq 0xd0(%rsp), %rsi movq %r14, %rdi callq 0xc7f0 movq 0xb03a6(%rip), %rax # 0xc93d8 testq %rax, %rax je 0x19043 leaq 0xd0(%rsp), %rsi movl %ebx, %edi callq *%rax addq $0x4d8, %rsp # imm = 0x4D8 popq %rbx popq %r12 popq %r14 popq %r15 retq movabsq $0x79726f6d656d20, %rax # imm = 0x79726F6D656D20 movq %rax, 0xd6(%rsp) movabsq $0x6d20666f2074754f, %rax # imm = 0x6D20666F2074754F movq %rax, 0xd0(%rsp) jmp 0x18f41 movups 0x69ad7(%rip), %xmm0 # 0x82b59 movaps %xmm0, 0xe0(%rsp) movups 0x69ab8(%rip), %xmm0 # 0x82b49 movaps %xmm0, 0xd0(%rsp) movl $0x747865, 0xf0(%rsp) # imm = 0x747865 jmp 0x18f41 movups 0x699ca(%rip), %xmm0 # 0x82a7a movaps %xmm0, 0xe0(%rsp) movups 0x699ab(%rip), %xmm0 # 0x82a6a movaps %xmm0, 0xd0(%rsp) movl $0x726574, 0xf0(%rsp) # imm = 0x726574 jmp 0x18f41 movups 0x699bc(%rip), %xmm0 # 0x82a9a movups %xmm0, 0xdc(%rsp) movups 0x699a1(%rip), %xmm0 # 0x82a8e jmp 0x191a0 movups 0x69a19(%rip), %xmm0 # 0x82b12 movaps %xmm0, 0xe0(%rsp) movups 0x699fa(%rip), %xmm0 # 0x82b02 movaps %xmm0, 0xd0(%rsp) movl $0x646572, 0xef(%rsp) # imm = 0x646572 jmp 0x18f41 movups 0x69933(%rip), %xmm0 # 0x82a5a movups %xmm0, 0xdc(%rsp) movups 0x69918(%rip), %xmm0 # 0x82a4e jmp 0x191a0 movups 0x69989(%rip), %xmm0 # 0x82ac8 movaps %xmm0, 0xe0(%rsp) movups 0x6996a(%rip), %xmm0 # 0x82ab8 movaps %xmm0, 0xd0(%rsp) movb $0x0, 0xf0(%rsp) jmp 0x18f41 movups 0x69988(%rip), %xmm0 # 0x82af2 movups %xmm0, 0xe9(%rsp) movups 0x69970(%rip), %xmm0 # 0x82ae9 movaps %xmm0, 0xe0(%rsp) movups 0x69951(%rip), %xmm0 # 0x82ad9 jmp 0x191a0 movups 0x699e6(%rip), %xmm0 # 0x82b77 movups %xmm0, 0xda(%rsp) movups 0x699cd(%rip), %xmm0 # 0x82b6d movaps %xmm0, 0xd0(%rsp) jmp 0x18f41 movups 0x69981(%rip), %xmm0 # 0x82b35 movaps %xmm0, 0xe0(%rsp) movups 0x69962(%rip), %xmm0 # 0x82b25 movaps %xmm0, 0xd0(%rsp) movl $0x656c62, 0xf0(%rsp) # imm = 0x656C62 jmp 0x18f41
_glfwInputError: push r15 push r14 push r12 push rbx sub rsp, 4D8h mov ebx, edi mov [rsp+4F8h+var_4C8], rdx mov [rsp+4F8h+var_4C0], rcx mov [rsp+4F8h+var_4B8], r8 mov [rsp+4F8h+var_4B0], r9 test al, al jz short loc_18EF0 movaps [rsp+4F8h+var_4A8], xmm0 movaps [rsp+4F8h+var_498], xmm1 movaps [rsp+4F8h+var_488], xmm2 movaps [rsp+4F8h+var_478], xmm3 movaps [rsp+4F8h+var_468], xmm4 movaps [rsp+4F8h+var_458], xmm5 movaps [rsp+4F8h+var_448], xmm6 movaps [rsp+4F8h+var_438], xmm7 loc_18EF0: test rsi, rsi jz loc_18FBF mov r10, rsi lea rax, [rsp+4F8h+var_4D8] mov rcx, rsp mov [rcx+10h], rax lea rax, [rsp+4F8h+arg_0] mov [rcx+8], rax mov rax, 3000000010h mov [rcx], rax lea r14, [rsp+4F8h+var_428] mov esi, 400h mov rdi, r14 mov rdx, r10 call _vsnprintf mov byte ptr [r14+3FFh], 0 loc_18F41: lea r12, _glfw cmp dword ptr [r12], 0 jz loc_1900C mov edi, 1FE14h add rdi, cs:_glfw_ptr call _glfwPlatformGetTls mov r14, rax test rax, rax jnz loc_19013 mov edi, 1 mov esi, 410h call _calloc mov r14, rax lea rdi, [r12+1FE14h] mov rsi, rax call _glfwPlatformSetTls lea r15, loc_1FE28[r12] mov rdi, r15 call _glfwPlatformLockMutex mov rax, [r12+3E0h] mov [r14], rax mov [r12+3E0h], r14 mov rdi, r15 call _glfwPlatformUnlockMutex jmp short loc_19013 loc_18FBF: lea eax, [rbx-10001h]; switch 10 cases cmp eax, 9 ja def_18FDC; jumptable 0000000000018FDC default case lea rcx, jpt_18FDC movsxd rax, ds:(jpt_18FDC - 67870h)[rcx+rax*4] add rax, rcx jmp rax; switch jump loc_18FDE: movups xmm0, cs:xmmword_82A3A; jumptable 0000000000018FDC case 65537 movaps [rsp+4F8h+var_418], xmm0 movups xmm0, cs:xmmword_82A2A movaps [rsp+4F8h+var_428], xmm0 mov [rsp+4F8h+var_408], 64657Ah jmp loc_18F41 loc_1900C: lea r14, _glfwMainThreadError loc_19013: mov [r14+8], ebx add r14, 0Ch lea rsi, [rsp+4F8h+var_428] mov rdi, r14 call _strcpy mov rax, cs:_glfwErrorCallback test rax, rax jz short loc_19043 lea rsi, [rsp+4F8h+var_428] mov edi, ebx call rax ; _glfwErrorCallback loc_19043: add rsp, 4D8h pop rbx pop r12 pop r14 pop r15 retn loc_19052: mov rax, 79726F6D656D20h; jumptable 0000000000018FDC case 65541 mov qword ptr [rsp+4F8h+var_428+6], rax mov rax, 6D20666F2074754Fh mov qword ptr [rsp+4F8h+var_428], rax jmp loc_18F41 loc_1907B: movups xmm0, cs:xmmword_82B59; jumptable 0000000000018FDC case 65546 movaps [rsp+4F8h+var_418], xmm0 movups xmm0, cs:xmmword_82B49 movaps [rsp+4F8h+var_428], xmm0 mov [rsp+4F8h+var_408], 747865h jmp loc_18F41 loc_190A9: movups xmm0, cs:xmmword_82A7A; jumptable 0000000000018FDC case 65539 movaps [rsp+4F8h+var_418], xmm0 movups xmm0, cs:xmmword_82A6A movaps [rsp+4F8h+var_428], xmm0 mov [rsp+4F8h+var_408], 726574h jmp loc_18F41 loc_190D7: movups xmm0, cs:xmmword_82A8E+0Ch; jumptable 0000000000018FDC case 65540 movups [rsp+4F8h+var_428+0Ch], xmm0 movups xmm0, cs:xmmword_82A8E jmp loc_191A0 loc_190F2: movups xmm0, cs:xmmword_82B12; jumptable 0000000000018FDC case 65544 movaps [rsp+4F8h+var_418], xmm0 movups xmm0, cs:xmmword_82B02 movaps [rsp+4F8h+var_428], xmm0 mov dword ptr [rsp+4F8h+var_418+0Fh], 646572h jmp loc_18F41 loc_19120: movups xmm0, cs:xmmword_82A4E+0Ch; jumptable 0000000000018FDC case 65538 movups [rsp+4F8h+var_428+0Ch], xmm0 movups xmm0, cs:xmmword_82A4E jmp short loc_191A0 loc_19138: movups xmm0, cs:xmmword_82AC8; jumptable 0000000000018FDC case 65542 movaps [rsp+4F8h+var_418], xmm0 movups xmm0, cs:xmmword_82AB8 movaps [rsp+4F8h+var_428], xmm0 mov byte ptr [rsp+4F8h+var_408], 0 jmp loc_18F41 loc_19163: movups xmm0, cs:xmmword_82AE9+9; jumptable 0000000000018FDC case 65543 movups [rsp+4F8h+var_418+9], xmm0 movups xmm0, cs:xmmword_82AE9 movaps [rsp+4F8h+var_418], xmm0 movups xmm0, cs:xmmword_82AD9 jmp short loc_191A0 def_18FDC: movups xmm0, cs:xmmword_82B6D+0Ah; jumptable 0000000000018FDC default case movups [rsp+4F8h+var_428+0Ah], xmm0 movups xmm0, cs:xmmword_82B6D loc_191A0: movaps [rsp+4F8h+var_428], xmm0 jmp loc_18F41 loc_191AD: movups xmm0, cs:xmmword_82B35; jumptable 0000000000018FDC case 65545 movaps [rsp+4F8h+var_418], xmm0 movups xmm0, cs:xmmword_82B25 movaps [rsp+4F8h+var_428], xmm0 mov [rsp+4F8h+var_408], 656C62h jmp loc_18F41
long long ( *glfwInputError(unsigned int a1, long long a2, ...))(_QWORD, _QWORD) { _DWORD *Tls; // r14 long long ( *result)(_QWORD, _QWORD); // rax __int128 v4; // xmm0 va_list va; // [rsp+0h] [rbp-4F8h] BYREF char v6[1023]; // [rsp+D0h] [rbp-428h] BYREF char v7; // [rsp+4CFh] [rbp-29h] if ( a2 ) { va_start(va, a2); ((void ( *)(char *, long long, long long, __va_list_tag *))vsnprintf)(v6, 1024LL, a2, va); v7 = 0; } else { switch ( a1 ) { case 0x10001u: strcpy(v6, "The GLFW library is not initialized"); break; case 0x10002u: strcpy(&v6[12], "current context"); v4 = xmmword_82A4E; goto LABEL_21; case 0x10003u: strcpy(v6, "Invalid argument for enum parameter"); break; case 0x10004u: strcpy(&v6[12], "e for parameter"); v4 = xmmword_82A8E; goto LABEL_21; case 0x10005u: strcpy(v6, "Out of memory"); break; case 0x10006u: strcpy(v6, "The requested API is unavailable"); break; case 0x10007u: strcpy(&v6[16], "I version is unavailable"); v4 = xmmword_82AD9; goto LABEL_21; case 0x10008u: strcpy(v6, "A platform-specific error occurred"); break; case 0x10009u: strcpy(v6, "The requested format is unavailable"); break; case 0x1000Au: strcpy(v6, "The specified window has no context"); break; default: strcpy(&v6[10], "NOWN GLFW ERROR"); v4 = xmmword_82B6D; LABEL_21: *(_OWORD *)v6 = v4; break; } } if ( glfw[0] ) { Tls = (_DWORD *)glfwPlatformGetTls(&glfw[32645]); if ( !Tls ) { Tls = (_DWORD *)calloc(1LL, 1040LL); glfwPlatformSetTls(&glfw[32645], Tls); glfwPlatformLockMutex((char *)&loc_1FE28 + (_QWORD)glfw); *(_QWORD *)Tls = *(_QWORD *)&glfw[248]; *(_QWORD *)&glfw[248] = Tls; glfwPlatformUnlockMutex((char *)&loc_1FE28 + (_QWORD)glfw); } } else { Tls = &glfwMainThreadError; } Tls[2] = a1; strcpy(Tls + 3, v6); result = glfwErrorCallback; if ( glfwErrorCallback ) return (long long ( *)(_QWORD, _QWORD))glfwErrorCallback(a1, v6); return result; }
_glfwInputError: PUSH R15 PUSH R14 PUSH R12 PUSH RBX SUB RSP,0x4d8 MOV EBX,EDI MOV qword ptr [RSP + 0x30],RDX MOV qword ptr [RSP + 0x38],RCX MOV qword ptr [RSP + 0x40],R8 MOV qword ptr [RSP + 0x48],R9 TEST AL,AL JZ 0x00118ef0 MOVAPS xmmword ptr [RSP + 0x50],XMM0 MOVAPS xmmword ptr [RSP + 0x60],XMM1 MOVAPS xmmword ptr [RSP + 0x70],XMM2 MOVAPS xmmword ptr [RSP + 0x80],XMM3 MOVAPS xmmword ptr [RSP + 0x90],XMM4 MOVAPS xmmword ptr [RSP + 0xa0],XMM5 MOVAPS xmmword ptr [RSP + 0xb0],XMM6 MOVAPS xmmword ptr [RSP + 0xc0],XMM7 LAB_00118ef0: TEST RSI,RSI JZ 0x00118fbf MOV R10,RSI LEA RAX,[RSP + 0x20] MOV RCX,RSP MOV qword ptr [RCX + 0x10],RAX LEA RAX,[RSP + 0x500] MOV qword ptr [RCX + 0x8],RAX MOV RAX,0x3000000010 MOV qword ptr [RCX],RAX LEA R14,[RSP + 0xd0] MOV ESI,0x400 MOV RDI,R14 MOV RDX,R10 CALL 0x0010c500 MOV byte ptr [R14 + 0x3ff],0x0 LAB_00118f41: LEA R12,[0x1a8638] CMP dword ptr [R12],0x0 JZ 0x0011900c MOV EDI,0x1fe14 ADD RDI,qword ptr [0x001a6fc0] CALL 0x00125f2d MOV R14,RAX TEST RAX,RAX JNZ 0x00119013 MOV EDI,0x1 MOV ESI,0x410 CALL 0x0010c550 MOV R14,RAX LEA RDI,[R12 + 0x1fe14] MOV RSI,RAX CALL 0x00125f5a LEA R15,[R12 + 0x1fe28] MOV RDI,R15 CALL 0x00126010 MOV RAX,qword ptr [R12 + 0x3e0] MOV qword ptr [R14],RAX MOV qword ptr [R12 + 0x3e0],R14 MOV RDI,R15 CALL 0x0012603e JMP 0x00119013 LAB_00118fbf: LEA EAX,[RBX + -0x10001] CMP EAX,0x9 JA 0x0011918a LEA RCX,[0x167870] MOVSXD RAX,dword ptr [RCX + RAX*0x4] ADD RAX,RCX switchD: JMP RAX caseD_10001: MOVUPS XMM0,xmmword ptr [0x00182a3a] MOVAPS xmmword ptr [RSP + 0xe0],XMM0 MOVUPS XMM0,xmmword ptr [0x00182a2a] MOVAPS xmmword ptr [RSP + 0xd0],XMM0 MOV dword ptr [RSP + 0xf0],0x64657a JMP 0x00118f41 LAB_0011900c: LEA R14,[0x1c8fc8] LAB_00119013: MOV dword ptr [R14 + 0x8],EBX ADD R14,0xc LEA RSI,[RSP + 0xd0] MOV RDI,R14 CALL 0x0010c7f0 MOV RAX,qword ptr [0x001c93d8] TEST RAX,RAX JZ 0x00119043 LEA RSI,[RSP + 0xd0] MOV EDI,EBX CALL RAX LAB_00119043: ADD RSP,0x4d8 POP RBX POP R12 POP R14 POP R15 RET caseD_10005: MOV RAX,0x79726f6d656d20 MOV qword ptr [RSP + 0xd6],RAX MOV RAX,0x6d20666f2074754f MOV qword ptr [RSP + 0xd0],RAX JMP 0x00118f41 caseD_1000a: MOVUPS XMM0,xmmword ptr [0x00182b59] MOVAPS xmmword ptr [RSP + 0xe0],XMM0 MOVUPS XMM0,xmmword ptr [0x00182b49] MOVAPS xmmword ptr [RSP + 0xd0],XMM0 MOV dword ptr [RSP + 0xf0],0x747865 JMP 0x00118f41 caseD_10003: MOVUPS XMM0,xmmword ptr [0x00182a7a] MOVAPS xmmword ptr [RSP + 0xe0],XMM0 MOVUPS XMM0,xmmword ptr [0x00182a6a] MOVAPS xmmword ptr [RSP + 0xd0],XMM0 MOV dword ptr [RSP + 0xf0],0x726574 JMP 0x00118f41 caseD_10004: MOVUPS XMM0,xmmword ptr [0x00182a9a] MOVUPS xmmword ptr [RSP + 0xdc],XMM0 MOVUPS XMM0,xmmword ptr [0x00182a8e] JMP 0x001191a0 caseD_10008: MOVUPS XMM0,xmmword ptr [0x00182b12] MOVAPS xmmword ptr [RSP + 0xe0],XMM0 MOVUPS XMM0,xmmword ptr [0x00182b02] MOVAPS xmmword ptr [RSP + 0xd0],XMM0 MOV dword ptr [RSP + 0xef],0x646572 JMP 0x00118f41 caseD_10002: MOVUPS XMM0,xmmword ptr [0x00182a5a] MOVUPS xmmword ptr [RSP + 0xdc],XMM0 MOVUPS XMM0,xmmword ptr [0x00182a4e] JMP 0x001191a0 caseD_10006: MOVUPS XMM0,xmmword ptr [0x00182ac8] MOVAPS xmmword ptr [RSP + 0xe0],XMM0 MOVUPS XMM0,xmmword ptr [0x00182ab8] MOVAPS xmmword ptr [RSP + 0xd0],XMM0 MOV byte ptr [RSP + 0xf0],0x0 JMP 0x00118f41 caseD_10007: MOVUPS XMM0,xmmword ptr [0x00182af2] MOVUPS xmmword ptr [RSP + 0xe9],XMM0 MOVUPS XMM0,xmmword ptr [0x00182ae9] MOVAPS xmmword ptr [RSP + 0xe0],XMM0 MOVUPS XMM0,xmmword ptr [0x00182ad9] JMP 0x001191a0 default: MOVUPS XMM0,xmmword ptr [0x00182b77] MOVUPS xmmword ptr [RSP + 0xda],XMM0 MOVUPS XMM0,xmmword ptr [0x00182b6d] LAB_001191a0: MOVAPS xmmword ptr [RSP + 0xd0],XMM0 JMP 0x00118f41 caseD_10009: MOVUPS XMM0,xmmword ptr [0x00182b35] MOVAPS xmmword ptr [RSP + 0xe0],XMM0 MOVUPS XMM0,xmmword ptr [0x00182b25] MOVAPS xmmword ptr [RSP + 0xd0],XMM0 MOV dword ptr [RSP + 0xf0],0x656c62 JMP 0x00118f41
void _glfwInputError(int4 param_1,int8 param_2,int8 param_3,int8 param_4, int8 param_5,int8 param_6,int8 param_7,int8 param_8, int4 param_9,char *param_10,int8 param_11,int8 param_12, int8 param_13,int8 param_14) { char in_AL; int1 *puVar1; int4 uVar2; int4 uVar3; int4 uVar4; int8 local_4f8; int1 *local_4f0; int1 *local_4e8; int1 local_4d8 [16]; int8 local_4c8; int8 local_4c0; int8 local_4b8; int8 local_4b0; int4 local_4a8; int8 local_498; int8 local_488; int8 local_478; int8 local_468; int8 local_458; int8 local_448; int8 local_438; char local_428 [4]; int2 uStack_424; int2 uStack_422; int2 uStack_420; int2 uStack_41e; int2 uStack_41c; int2 uStack_41a; char acStack_418 [2]; int2 uStack_416; int4 uStack_414; char cStack_410; char cStack_40f; int2 uStack_40e; int4 uStack_40c; char cStack_408; int2 uStack_407; char cStack_405; int5 uStack_404; int1 local_29; if (in_AL != '\0') { local_4a8 = param_1; local_498 = param_2; local_488 = param_3; local_478 = param_4; local_468 = param_5; local_458 = param_6; local_448 = param_7; local_438 = param_8; } local_4c8 = param_11; local_4c0 = param_12; local_4b8 = param_13; local_4b0 = param_14; if (param_10 != (char *)0x0) { local_4e8 = local_4d8; local_4f0 = &stack0x00000008; local_4f8 = 0x3000000010; vsnprintf(local_428,0x400,param_10,&local_4f8); local_29 = 0; goto LAB_00118f41; } switch(param_9) { case 0x10001: acStack_418 = SUB82(s_The_GLFW_library_is_not_initiali_00182a2a._16_8_,0); uStack_416 = SUB82(s_The_GLFW_library_is_not_initiali_00182a2a._16_8_,2); uStack_414 = SUB84(s_The_GLFW_library_is_not_initiali_00182a2a._16_8_,4); cStack_410 = (char)s_The_GLFW_library_is_not_initiali_00182a2a._24_8_; cStack_40f = SUB81(s_The_GLFW_library_is_not_initiali_00182a2a._24_8_,1); uStack_40e = SUB82(s_The_GLFW_library_is_not_initiali_00182a2a._24_8_,2); uStack_40c = SUB84(s_The_GLFW_library_is_not_initiali_00182a2a._24_8_,4); local_428 = SUB84(s_The_GLFW_library_is_not_initiali_00182a2a._0_8_,0); uStack_424 = SUB82(s_The_GLFW_library_is_not_initiali_00182a2a._0_8_,4); uStack_422 = SUB82(s_The_GLFW_library_is_not_initiali_00182a2a._0_8_,6); uStack_420 = (int2)s_The_GLFW_library_is_not_initiali_00182a2a._8_8_; uStack_41e = SUB82(s_The_GLFW_library_is_not_initiali_00182a2a._8_8_,2); uStack_41c = SUB82(s_The_GLFW_library_is_not_initiali_00182a2a._8_8_,4); uStack_41a = SUB82(s_The_GLFW_library_is_not_initiali_00182a2a._8_8_,6); cStack_408 = 'z'; uStack_407 = 0x6465; cStack_405 = '\0'; break; case 0x10002: acStack_418 = SUB42(s_There_is_no_current_context_00182a4e._16_4_,0); uStack_416 = SUB42(s_There_is_no_current_context_00182a4e._16_4_,2); uStack_414 = (int4)s_There_is_no_current_context_00182a4e._20_8_; cStack_410 = SUB81(s_There_is_no_current_context_00182a4e._20_8_,4); cStack_40f = SUB81(s_There_is_no_current_context_00182a4e._20_8_,5); uStack_40e = SUB82(s_There_is_no_current_context_00182a4e._20_8_,6); local_428 = (char [4])s_There_is_no_current_context_00182a4e._0_4_; uVar2 = s_There_is_no_current_context_00182a4e._4_4_; uVar3 = s_There_is_no_current_context_00182a4e._8_4_; uVar4 = s_There_is_no_current_context_00182a4e._12_4_; goto LAB_001191a0; case 0x10003: acStack_418 = SUB82(s_Invalid_argument_for_enum_parame_00182a6a._16_8_,0); uStack_416 = SUB82(s_Invalid_argument_for_enum_parame_00182a6a._16_8_,2); uStack_414 = SUB84(s_Invalid_argument_for_enum_parame_00182a6a._16_8_,4); cStack_410 = (char)s_Invalid_argument_for_enum_parame_00182a6a._24_8_; cStack_40f = SUB81(s_Invalid_argument_for_enum_parame_00182a6a._24_8_,1); uStack_40e = SUB82(s_Invalid_argument_for_enum_parame_00182a6a._24_8_,2); uStack_40c = SUB84(s_Invalid_argument_for_enum_parame_00182a6a._24_8_,4); local_428 = SUB84(s_Invalid_argument_for_enum_parame_00182a6a._0_8_,0); uStack_424 = SUB82(s_Invalid_argument_for_enum_parame_00182a6a._0_8_,4); uStack_422 = SUB82(s_Invalid_argument_for_enum_parame_00182a6a._0_8_,6); uStack_420 = (int2)s_Invalid_argument_for_enum_parame_00182a6a._8_8_; uStack_41e = SUB82(s_Invalid_argument_for_enum_parame_00182a6a._8_8_,2); uStack_41c = SUB82(s_Invalid_argument_for_enum_parame_00182a6a._8_8_,4); uStack_41a = SUB82(s_Invalid_argument_for_enum_parame_00182a6a._8_8_,6); cStack_408 = 't'; uStack_407 = 0x7265; cStack_405 = '\0'; break; case 0x10004: acStack_418 = SUB42(s_Invalid_value_for_parameter_00182a8e._16_4_,0); uStack_416 = SUB42(s_Invalid_value_for_parameter_00182a8e._16_4_,2); uStack_414 = (int4)s_Invalid_value_for_parameter_00182a8e._20_8_; cStack_410 = SUB81(s_Invalid_value_for_parameter_00182a8e._20_8_,4); cStack_40f = SUB81(s_Invalid_value_for_parameter_00182a8e._20_8_,5); uStack_40e = SUB82(s_Invalid_value_for_parameter_00182a8e._20_8_,6); local_428 = (char [4])s_Invalid_value_for_parameter_00182a8e._0_4_; uVar2 = s_Invalid_value_for_parameter_00182a8e._4_4_; uVar3 = s_Invalid_value_for_parameter_00182a8e._8_4_; uVar4 = s_Invalid_value_for_parameter_00182a8e._12_4_; goto LAB_001191a0; case 0x10005: uStack_420 = 0x6d65; uStack_41e = 0x726f; uStack_41c = 0x79; builtin_strncpy(local_428,"Out ",4); uStack_424 = 0x666f; uStack_422 = 0x6d20; break; case 0x10006: acStack_418 = SUB82(s_The_requested_API_is_unavailable_00182ab8._16_8_,0); uStack_416 = SUB82(s_The_requested_API_is_unavailable_00182ab8._16_8_,2); uStack_414 = SUB84(s_The_requested_API_is_unavailable_00182ab8._16_8_,4); cStack_410 = (char)s_The_requested_API_is_unavailable_00182ab8._24_8_; cStack_40f = SUB81(s_The_requested_API_is_unavailable_00182ab8._24_8_,1); uStack_40e = SUB82(s_The_requested_API_is_unavailable_00182ab8._24_8_,2); uStack_40c = SUB84(s_The_requested_API_is_unavailable_00182ab8._24_8_,4); local_428 = SUB84(s_The_requested_API_is_unavailable_00182ab8._0_8_,0); uStack_424 = SUB82(s_The_requested_API_is_unavailable_00182ab8._0_8_,4); uStack_422 = SUB82(s_The_requested_API_is_unavailable_00182ab8._0_8_,6); uStack_420 = (int2)s_The_requested_API_is_unavailable_00182ab8._8_8_; uStack_41e = SUB82(s_The_requested_API_is_unavailable_00182ab8._8_8_,2); uStack_41c = SUB82(s_The_requested_API_is_unavailable_00182ab8._8_8_,4); uStack_41a = SUB82(s_The_requested_API_is_unavailable_00182ab8._8_8_,6); cStack_408 = '\0'; break; case 0x10007: cStack_408 = s_The_requested_API_version_is_una_00182ad9[0x20]; uStack_407 = (int2)s_The_requested_API_version_is_una_00182ad9._33_8_; cStack_405 = SUB81(s_The_requested_API_version_is_una_00182ad9._33_8_,2); uStack_404 = SUB85(s_The_requested_API_version_is_una_00182ad9._33_8_,3); acStack_418 = SUB82(s_The_requested_API_version_is_una_00182ad9._16_8_,0); uStack_416 = SUB82(s_The_requested_API_version_is_una_00182ad9._16_8_,2); uStack_414 = SUB84(s_The_requested_API_version_is_una_00182ad9._16_8_,4); cStack_410 = s_The_requested_API_version_is_una_00182ad9[0x18]; cStack_40f = (char)s_The_requested_API_version_is_una_00182ad9._25_7_; uStack_40e = SUB72(s_The_requested_API_version_is_una_00182ad9._25_7_,1); uStack_40c = SUB74(s_The_requested_API_version_is_una_00182ad9._25_7_,3); local_428 = (char [4])s_The_requested_API_version_is_una_00182ad9._0_4_; uVar2 = s_The_requested_API_version_is_una_00182ad9._4_4_; uVar3 = s_The_requested_API_version_is_una_00182ad9._8_4_; uVar4 = s_The_requested_API_version_is_una_00182ad9._12_4_; goto LAB_001191a0; case 0x10008: acStack_418 = SUB82(s_A_platform_specific_error_occurr_00182b02._16_8_,0); uStack_416 = SUB82(s_A_platform_specific_error_occurr_00182b02._16_8_,2); uStack_414 = SUB84(s_A_platform_specific_error_occurr_00182b02._16_8_,4); cStack_410 = (char)s_A_platform_specific_error_occurr_00182b02._24_8_; cStack_40f = SUB81(s_A_platform_specific_error_occurr_00182b02._24_8_,1); uStack_40e = SUB82(s_A_platform_specific_error_occurr_00182b02._24_8_,2); local_428 = SUB84(s_A_platform_specific_error_occurr_00182b02._0_8_,0); uStack_424 = SUB82(s_A_platform_specific_error_occurr_00182b02._0_8_,4); uStack_422 = SUB82(s_A_platform_specific_error_occurr_00182b02._0_8_,6); uStack_420 = (int2)s_A_platform_specific_error_occurr_00182b02._8_8_; uStack_41e = SUB82(s_A_platform_specific_error_occurr_00182b02._8_8_,2); uStack_41c = SUB82(s_A_platform_specific_error_occurr_00182b02._8_8_,4); uStack_41a = SUB82(s_A_platform_specific_error_occurr_00182b02._8_8_,6); uStack_40c = CONCAT13(0x72,SUB83(s_A_platform_specific_error_occurr_00182b02._24_8_,4)); cStack_408 = 'e'; uStack_407 = 100; break; case 0x10009: acStack_418 = SUB82(s_The_requested_format_is_unavaila_00182b25._16_8_,0); uStack_416 = SUB82(s_The_requested_format_is_unavaila_00182b25._16_8_,2); uStack_414 = SUB84(s_The_requested_format_is_unavaila_00182b25._16_8_,4); cStack_410 = (char)s_The_requested_format_is_unavaila_00182b25._24_8_; cStack_40f = SUB81(s_The_requested_format_is_unavaila_00182b25._24_8_,1); uStack_40e = SUB82(s_The_requested_format_is_unavaila_00182b25._24_8_,2); uStack_40c = SUB84(s_The_requested_format_is_unavaila_00182b25._24_8_,4); local_428 = SUB84(s_The_requested_format_is_unavaila_00182b25._0_8_,0); uStack_424 = SUB82(s_The_requested_format_is_unavaila_00182b25._0_8_,4); uStack_422 = SUB82(s_The_requested_format_is_unavaila_00182b25._0_8_,6); uStack_420 = (int2)s_The_requested_format_is_unavaila_00182b25._8_8_; uStack_41e = SUB82(s_The_requested_format_is_unavaila_00182b25._8_8_,2); uStack_41c = SUB82(s_The_requested_format_is_unavaila_00182b25._8_8_,4); uStack_41a = SUB82(s_The_requested_format_is_unavaila_00182b25._8_8_,6); cStack_408 = 'b'; uStack_407 = 0x656c; cStack_405 = '\0'; break; case 0x1000a: acStack_418 = SUB82(s_The_specified_window_has_no_cont_00182b49._16_8_,0); uStack_416 = SUB82(s_The_specified_window_has_no_cont_00182b49._16_8_,2); uStack_414 = SUB84(s_The_specified_window_has_no_cont_00182b49._16_8_,4); cStack_410 = (char)s_The_specified_window_has_no_cont_00182b49._24_8_; cStack_40f = SUB81(s_The_specified_window_has_no_cont_00182b49._24_8_,1); uStack_40e = SUB82(s_The_specified_window_has_no_cont_00182b49._24_8_,2); uStack_40c = SUB84(s_The_specified_window_has_no_cont_00182b49._24_8_,4); local_428 = SUB84(s_The_specified_window_has_no_cont_00182b49._0_8_,0); uStack_424 = SUB82(s_The_specified_window_has_no_cont_00182b49._0_8_,4); uStack_422 = SUB82(s_The_specified_window_has_no_cont_00182b49._0_8_,6); uStack_420 = (int2)s_The_specified_window_has_no_cont_00182b49._8_8_; uStack_41e = SUB82(s_The_specified_window_has_no_cont_00182b49._8_8_,2); uStack_41c = SUB82(s_The_specified_window_has_no_cont_00182b49._8_8_,4); uStack_41a = SUB82(s_The_specified_window_has_no_cont_00182b49._8_8_,6); cStack_408 = 'e'; uStack_407 = 0x7478; cStack_405 = '\0'; break; default: acStack_418 = (char [2])s_ERROR__UNKNOWN_GLFW_ERROR_00182b6d._16_2_; uStack_416 = (int2)s_ERROR__UNKNOWN_GLFW_ERROR_00182b6d._18_8_; uStack_414 = SUB84(s_ERROR__UNKNOWN_GLFW_ERROR_00182b6d._18_8_,2); cStack_410 = SUB81(s_ERROR__UNKNOWN_GLFW_ERROR_00182b6d._18_8_,6); cStack_40f = SUB81(s_ERROR__UNKNOWN_GLFW_ERROR_00182b6d._18_8_,7); uVar3._2_2_ = s_ERROR__UNKNOWN_GLFW_ERROR_00182b6d._10_2_; uVar3._0_2_ = s_ERROR__UNKNOWN_GLFW_ERROR_00182b6d._8_2_; local_428 = (char [4])s_ERROR__UNKNOWN_GLFW_ERROR_00182b6d._0_4_; uVar2 = s_ERROR__UNKNOWN_GLFW_ERROR_00182b6d._4_4_; uVar4 = s_ERROR__UNKNOWN_GLFW_ERROR_00182b6d._12_4_; LAB_001191a0: uStack_424 = (int2)uVar2; uStack_422 = SUB42(uVar2,2); uStack_420 = (int2)uVar3; uStack_41e = SUB42(uVar3,2); uStack_41c = (int2)uVar4; uStack_41a = SUB42(uVar4,2); } LAB_00118f41: if (_glfw == 0) { puVar1 = _glfwMainThreadError; } else { puVar1 = (int1 *)_glfwPlatformGetTls(PTR__glfw_001a6fc0 + 0x1fe14); if ((int8 *)puVar1 == (int8 *)0x0) { puVar1 = (int1 *)calloc(1,0x410); _glfwPlatformSetTls(&DAT_001c844c,puVar1); _glfwPlatformLockMutex(&DAT_001c8460); *(int8 **)puVar1 = DAT_001a8a18; DAT_001a8a18 = (int8 *)puVar1; _glfwPlatformUnlockMutex(&DAT_001c8460); } } *(int4 *)((long)puVar1 + 8) = param_9; strcpy((char *)((long)puVar1 + 0xc),local_428); if (_glfwErrorCallback != (code *)0x0) { (*_glfwErrorCallback)(param_9,local_428); } return; }
31,864
minja::Value::insert(unsigned long, minja::Value const&)
monkey531[P]llama/common/minja.hpp
void insert(size_t index, const Value& v) { if (!array_) throw std::runtime_error("Value is not an array: " + dump()); array_->insert(array_->begin() + index, v); }
O0
cpp
minja::Value::insert(unsigned long, minja::Value const&): subq $0xa8, %rsp movq %rdi, 0xa0(%rsp) movq %rsi, 0x98(%rsp) movq %rdx, 0x90(%rsp) movq 0xa0(%rsp), %rdi movq %rdi, 0x18(%rsp) addq $0x10, %rdi callq 0xaeee0 testb $0x1, %al jne 0xe820b movb $0x1, 0x43(%rsp) movl $0x10, %edi callq 0x555d0 movq 0x18(%rsp), %rsi movq %rax, 0x10(%rsp) leaq 0x50(%rsp), %rdi movl $0xffffffff, %edx # imm = 0xFFFFFFFF xorl %ecx, %ecx callq 0xaee10 jmp 0xe8169 leaq 0xdf62b(%rip), %rsi # 0x1c779b leaq 0x70(%rsp), %rdi leaq 0x50(%rsp), %rdx callq 0x62fb0 jmp 0xe8181 movq 0x10(%rsp), %rdi leaq 0x70(%rsp), %rsi callq 0x553e0 jmp 0xe8192 movq 0x10(%rsp), %rdi movb $0x0, 0x43(%rsp) movq 0x15ee0d(%rip), %rsi # 0x246fb0 movq 0x15edce(%rip), %rdx # 0x246f78 callq 0x559b0 jmp 0xe828d movq %rax, %rcx movl %edx, %eax movq %rcx, 0x48(%rsp) movl %eax, 0x44(%rsp) jmp 0xe81f6 movq %rax, %rcx movl %edx, %eax movq %rcx, 0x48(%rsp) movl %eax, 0x44(%rsp) jmp 0xe81ec movq %rax, %rcx movl %edx, %eax movq %rcx, 0x48(%rsp) movl %eax, 0x44(%rsp) leaq 0x70(%rsp), %rdi callq 0x56290 leaq 0x50(%rsp), %rdi callq 0x56290 testb $0x1, 0x43(%rsp) jne 0xe81ff jmp 0xe8209 movq 0x10(%rsp), %rdi callq 0x55d50 jmp 0xe8283 movq 0x18(%rsp), %rdi addq $0x10, %rdi callq 0xb0670 movq 0x18(%rsp), %rdi movq %rax, 0x8(%rsp) addq $0x10, %rdi callq 0xb0670 movq %rax, %rdi callq 0xda330 movq %rax, 0x28(%rsp) movq 0x98(%rsp), %rsi leaq 0x28(%rsp), %rdi callq 0xeac10 movq %rax, 0x30(%rsp) leaq 0x38(%rsp), %rdi leaq 0x30(%rsp), %rsi callq 0xeacc0 movq 0x8(%rsp), %rdi movq 0x90(%rsp), %rdx movq 0x38(%rsp), %rsi callq 0xeba50 movq %rax, 0x20(%rsp) addq $0xa8, %rsp retq movq 0x48(%rsp), %rdi callq 0x55a10 nopl (%rax)
_ZN5minja5Value6insertEmRKS0_: sub rsp, 0A8h mov [rsp+0A8h+var_8], rdi mov [rsp+0A8h+var_10], rsi mov [rsp+0A8h+var_18], rdx mov rdi, [rsp+0A8h+var_8] mov [rsp+0A8h+var_90], rdi add rdi, 10h call _ZNKSt12__shared_ptrISt6vectorIN5minja5ValueESaIS2_EELN9__gnu_cxx12_Lock_policyE2EEcvbEv; std::__shared_ptr<std::vector<minja::Value>,(__gnu_cxx::_Lock_policy)2>::operator bool(void) test al, 1 jnz loc_E820B mov [rsp+0A8h+var_65], 1 mov edi, 10h; thrown_size call ___cxa_allocate_exception mov rsi, [rsp+0A8h+var_90] mov [rsp+0A8h+var_98], rax lea rdi, [rsp+0A8h+var_58] mov edx, 0FFFFFFFFh xor ecx, ecx call _ZNK5minja5Value4dumpB5cxx11Eib; minja::Value::dump(int,bool) jmp short $+2 loc_E8169: lea rsi, aValueIsNotAnAr; "Value is not an array: " lea rdi, [rsp+0A8h+var_38] lea rdx, [rsp+0A8h+var_58] call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_OS8_; std::operator+<char>(char const*,std::string&&) jmp short $+2 loc_E8181: mov rdi, [rsp+0A8h+var_98] lea rsi, [rsp+0A8h+var_38] call __ZNSt13runtime_errorC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; std::runtime_error::runtime_error(std::string const&) jmp short $+2 loc_E8192: mov rdi, [rsp+0A8h+var_98]; void * mov [rsp+0A8h+var_65], 0 mov rsi, cs:lptinfo; lptinfo mov rdx, cs:_ZNSt13runtime_errorD1Ev_ptr; void (*)(void *) call ___cxa_throw jmp loc_E828D mov rcx, rax mov eax, edx mov [rsp+arg_40], rcx mov [rsp+arg_3C], eax jmp short loc_E81F6 mov rcx, rax mov eax, edx mov [rsp+arg_40], rcx mov [rsp+arg_3C], eax jmp short loc_E81EC mov rcx, rax mov eax, edx mov [rsp+arg_40], rcx mov [rsp+arg_3C], eax lea rdi, [rsp+arg_68]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string() loc_E81EC: lea rdi, [rsp+arg_48]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string() loc_E81F6: test [rsp+arg_3B], 1 jnz short loc_E81FF jmp short loc_E8209 loc_E81FF: mov rdi, [rsp+arg_8]; void * call ___cxa_free_exception loc_E8209: jmp short loc_E8283 loc_E820B: mov rdi, [rsp+0A8h+var_90] add rdi, 10h call _ZNKSt19__shared_ptr_accessISt6vectorIN5minja5ValueESaIS2_EELN9__gnu_cxx12_Lock_policyE2ELb0ELb0EEptEv; std::__shared_ptr_access<std::vector<minja::Value>,(__gnu_cxx::_Lock_policy)2,false,false>::operator->(void) mov rdi, [rsp+0A8h+var_90] mov [rsp+0A8h+var_A0], rax add rdi, 10h call _ZNKSt19__shared_ptr_accessISt6vectorIN5minja5ValueESaIS2_EELN9__gnu_cxx12_Lock_policyE2ELb0ELb0EEptEv; std::__shared_ptr_access<std::vector<minja::Value>,(__gnu_cxx::_Lock_policy)2,false,false>::operator->(void) mov rdi, rax call _ZNSt6vectorIN5minja5ValueESaIS1_EE5beginEv; std::vector<minja::Value>::begin(void) mov [rsp+0A8h+var_80], rax mov rsi, [rsp+0A8h+var_10] lea rdi, [rsp+0A8h+var_80] call _ZNK9__gnu_cxx17__normal_iteratorIPN5minja5ValueESt6vectorIS2_SaIS2_EEEplEl; __gnu_cxx::__normal_iterator<minja::Value *,std::vector<minja::Value>>::operator+(long) mov [rsp+0A8h+var_78], rax lea rdi, [rsp+0A8h+var_70] lea rsi, [rsp+0A8h+var_78] call _ZN9__gnu_cxx17__normal_iteratorIPKN5minja5ValueESt6vectorIS2_SaIS2_EEEC2IPS2_EERKNS0_IT_NS_11__enable_ifIXsr3std10__are_sameISB_SA_EE7__valueES7_E6__typeEEE mov rdi, [rsp+0A8h+var_A0] mov rdx, [rsp+0A8h+var_18] mov rsi, [rsp+0A8h+var_70] call _ZNSt6vectorIN5minja5ValueESaIS1_EE6insertEN9__gnu_cxx17__normal_iteratorIPKS1_S3_EERS6_; std::vector<minja::Value>::insert(__gnu_cxx::__normal_iterator<minja::Value const*,std::vector<minja::Value>>,minja::Value const&) mov [rsp+0A8h+var_88], rax add rsp, 0A8h retn loc_E8283: mov rdi, [rsp+arg_40] call __Unwind_Resume loc_E828D: nop dword ptr [rax]
long long minja::Value::insert(minja::Value *this, long long a2, const minja::Value *a3) { long long v3; // rax int v4; // ecx int v5; // r8d int v6; // r9d int v8; // [rsp+8h] [rbp-A0h] void *exception; // [rsp+10h] [rbp-98h] long long v10; // [rsp+28h] [rbp-80h] BYREF long long v11; // [rsp+30h] [rbp-78h] BYREF long long v12; // [rsp+38h] [rbp-70h] BYREF char v13; // [rsp+43h] [rbp-65h] _BYTE v14[32]; // [rsp+50h] [rbp-58h] BYREF _BYTE v15[32]; // [rsp+70h] [rbp-38h] BYREF const minja::Value *v16; // [rsp+90h] [rbp-18h] long long v17; // [rsp+98h] [rbp-10h] minja::Value *v18; // [rsp+A0h] [rbp-8h] v18 = this; v17 = a2; v16 = a3; if ( !std::__shared_ptr<std::vector<minja::Value>,(__gnu_cxx::_Lock_policy)2>::operator bool((_QWORD *)this + 2) ) { exception = __cxa_allocate_exception(0x10uLL); minja::Value::dump[abi:cxx11]((long long)v14, (long long)this, 0xFFFFFFFF, 0); std::operator+<char>((long long)v15, (long long)"Value is not an array: ", (long long)v14); std::runtime_error::runtime_error(exception, v15); v13 = 0; __cxa_throw( exception, (struct type_info *)&`typeinfo for'std::runtime_error, (void (*)(void *))&std::runtime_error::~runtime_error); } v8 = std::__shared_ptr_access<std::vector<minja::Value>,(__gnu_cxx::_Lock_policy)2,false,false>::operator->((long long)this + 16); v3 = std::__shared_ptr_access<std::vector<minja::Value>,(__gnu_cxx::_Lock_policy)2,false,false>::operator->((long long)this + 16); v10 = std::vector<minja::Value>::begin(v3); v11 = __gnu_cxx::__normal_iterator<minja::Value *,std::vector<minja::Value>>::operator+(&v10, v17); __gnu_cxx::__normal_iterator<minja::Value const*,std::vector<minja::Value>>::__normal_iterator<minja::Value*>( &v12, &v11); return std::vector<minja::Value>::insert(v8, v12, (_DWORD)v16, v4, v5, v6); }
insert: SUB RSP,0xa8 MOV qword ptr [RSP + 0xa0],RDI MOV qword ptr [RSP + 0x98],RSI MOV qword ptr [RSP + 0x90],RDX MOV RDI,qword ptr [RSP + 0xa0] MOV qword ptr [RSP + 0x18],RDI ADD RDI,0x10 CALL 0x001aeee0 TEST AL,0x1 JNZ 0x001e820b MOV byte ptr [RSP + 0x43],0x1 MOV EDI,0x10 CALL 0x001555d0 MOV RSI,qword ptr [RSP + 0x18] MOV qword ptr [RSP + 0x10],RAX LAB_001e8156: LEA RDI,[RSP + 0x50] MOV EDX,0xffffffff XOR ECX,ECX CALL 0x001aee10 JMP 0x001e8169 LAB_001e8169: LEA RSI,[0x2c779b] LEA RDI,[RSP + 0x70] LEA RDX,[RSP + 0x50] CALL 0x00162fb0 JMP 0x001e8181 LAB_001e8181: MOV RDI,qword ptr [RSP + 0x10] LEA RSI,[RSP + 0x70] CALL 0x001553e0 JMP 0x001e8192 LAB_001e8192: MOV RDI,qword ptr [RSP + 0x10] MOV byte ptr [RSP + 0x43],0x0 MOV RSI,qword ptr [0x00346fb0] MOV RDX,qword ptr [0x00346f78] CALL 0x001559b0 LAB_001e820b: MOV RDI,qword ptr [RSP + 0x18] ADD RDI,0x10 CALL 0x001b0670 MOV RDI,qword ptr [RSP + 0x18] MOV qword ptr [RSP + 0x8],RAX ADD RDI,0x10 CALL 0x001b0670 MOV RDI,RAX CALL 0x001da330 MOV qword ptr [RSP + 0x28],RAX MOV RSI,qword ptr [RSP + 0x98] LEA RDI,[RSP + 0x28] CALL 0x001eac10 MOV qword ptr [RSP + 0x30],RAX LEA RDI,[RSP + 0x38] LEA RSI,[RSP + 0x30] CALL 0x001eacc0 MOV RDI,qword ptr [RSP + 0x8] MOV RDX,qword ptr [RSP + 0x90] MOV RSI,qword ptr [RSP + 0x38] CALL 0x001eba50 MOV qword ptr [RSP + 0x20],RAX ADD RSP,0xa8 RET
/* minja::Value::insert(unsigned long, minja::Value const&) */ void __thiscall minja::Value::insert(Value *this,ulong param_1,Value *param_2) { runtime_error *this_00; vector<minja::Value,std::allocator<minja::Value>> *pvVar1; vector<minja::Value,std::allocator<minja::Value>> *this_01; bool bVar2; int8 local_80; int8 local_78; int8 local_70; int1 local_65; int1 local_58 [32]; string local_38 [32]; Value *local_18; ulong local_10; Value *local_8; local_18 = param_2; local_10 = param_1; local_8 = this; bVar2 = std::__shared_ptr::operator_cast_to_bool((__shared_ptr *)(this + 0x10)); if (!bVar2) { local_65 = 1; this_00 = (runtime_error *)__cxa_allocate_exception(0x10); /* try { // try from 001e8156 to 001e8166 has its CatchHandler @ 001e81b4 */ dump_abi_cxx11_((int)local_58,SUB81(this,0)); /* try { // try from 001e8169 to 001e817e has its CatchHandler @ 001e81c4 */ std::operator+((char *)local_38,(string *)"Value is not an array: "); /* try { // try from 001e8181 to 001e81ae has its CatchHandler @ 001e81d4 */ std::runtime_error::runtime_error(this_00,local_38); local_65 = 0; /* WARNING: Subroutine does not return */ __cxa_throw(this_00,PTR_typeinfo_00346fb0,PTR__runtime_error_00346f78); } pvVar1 = (vector<minja::Value,std::allocator<minja::Value>> *) std:: __shared_ptr_access<std::vector<minja::Value,std::allocator<minja::Value>>,(__gnu_cxx::_Lock_policy)2,false,false> ::operator->((__shared_ptr_access<std::vector<minja::Value,std::allocator<minja::Value>>,(__gnu_cxx::_Lock_policy)2,false,false> *)(this + 0x10)); this_01 = (vector<minja::Value,std::allocator<minja::Value>> *) std:: __shared_ptr_access<std::vector<minja::Value,std::allocator<minja::Value>>,(__gnu_cxx::_Lock_policy)2,false,false> ::operator->((__shared_ptr_access<std::vector<minja::Value,std::allocator<minja::Value>>,(__gnu_cxx::_Lock_policy)2,false,false> *)(this + 0x10)); local_80 = std::vector<minja::Value,std::allocator<minja::Value>>::begin(this_01); local_78 = __gnu_cxx:: __normal_iterator<minja::Value*,std::vector<minja::Value,std::allocator<minja::Value>>> ::operator+((__normal_iterator<minja::Value*,std::vector<minja::Value,std::allocator<minja::Value>>> *)&local_80,local_10); __gnu_cxx:: __normal_iterator<minja::Value_const*,std::vector<minja::Value,std::allocator<minja::Value>>>:: __normal_iterator<minja::Value*> ((__normal_iterator<minja::Value_const*,std::vector<minja::Value,std::allocator<minja::Value>>> *)&local_70,(__normal_iterator *)&local_78); std::vector<minja::Value,std::allocator<minja::Value>>::insert(pvVar1,local_70,local_18); return; }
31,865
minja::Value::insert(unsigned long, minja::Value const&)
monkey531[P]llama/common/minja.hpp
void insert(size_t index, const Value& v) { if (!array_) throw std::runtime_error("Value is not an array: " + dump()); array_->insert(array_->begin() + index, v); }
O3
cpp
minja::Value::insert(unsigned long, minja::Value const&): pushq %rbp pushq %r14 pushq %rbx subq $0x40, %rsp movq %rdi, %r14 movq 0x10(%rdi), %rdi testq %rdi, %rdi je 0x592ae leaq (%rsi,%rsi,4), %rsi shlq $0x4, %rsi addq (%rdi), %rsi addq $0x40, %rsp popq %rbx popq %r14 popq %rbp jmp 0x5a9e6 movl $0x10, %edi callq 0x1a390 movq %rax, %rbx movq %rsp, %rdi movq %r14, %rsi movl $0xffffffff, %edx # imm = 0xFFFFFFFF xorl %ecx, %ecx callq 0x42a18 leaq 0x57a50(%rip), %rsi # 0xb0d24 leaq 0x20(%rsp), %rdi movq %rsp, %rdx callq 0x29d9d movb $0x1, %bpl leaq 0x20(%rsp), %rsi movq %rbx, %rdi callq 0x1ac00 xorl %ebp, %ebp movq 0x89cf6(%rip), %rsi # 0xe2ff0 movq 0x89c6f(%rip), %rdx # 0xe2f70 movq %rbx, %rdi callq 0x1acd0 movq %rax, %r14 leaq 0x30(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0x59327 movq 0x30(%rsp), %rsi incq %rsi callq 0x1a740 leaq 0x10(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0x59342 movq 0x10(%rsp), %rsi incq %rsi callq 0x1a740 testb %bpl, %bpl jne 0x5936c jmp 0x59374 movq %rax, %r14 leaq 0x10(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0x5936c movq 0x10(%rsp), %rsi incq %rsi callq 0x1a740 jmp 0x5936c movq %rax, %r14 movq %rbx, %rdi callq 0x1a530 movq %r14, %rdi callq 0x1ad30
_ZN5minja5Value6insertEmRKS0_: push rbp push r14 push rbx sub rsp, 40h mov r14, rdi mov rdi, [rdi+10h] test rdi, rdi jz short loc_592AE lea rsi, [rsi+rsi*4] shl rsi, 4 add rsi, [rdi] add rsp, 40h pop rbx pop r14 pop rbp jmp _ZNSt6vectorIN5minja5ValueESaIS1_EE6insertEN9__gnu_cxx17__normal_iteratorIPKS1_S3_EERS6_; std::vector<minja::Value>::insert(__gnu_cxx::__normal_iterator<minja::Value const*,std::vector<minja::Value>>,minja::Value const&) loc_592AE: mov edi, 10h; thrown_size call ___cxa_allocate_exception mov rbx, rax mov rdi, rsp mov rsi, r14 mov edx, 0FFFFFFFFh xor ecx, ecx call _ZNK5minja5Value4dumpB5cxx11Eib; minja::Value::dump(int,bool) lea rsi, aValueIsNotAnAr; "Value is not an array: " lea rdi, [rsp+58h+var_38] mov rdx, rsp call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_OS8_; std::operator+<char>(char const*,std::string&&) mov bpl, 1 lea rsi, [rsp+58h+var_38] mov rdi, rbx call __ZNSt13runtime_errorC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; std::runtime_error::runtime_error(std::string const&) xor ebp, ebp mov rsi, cs:lptinfo; lptinfo mov rdx, cs:_ZTISt19_Sp_make_shared_tag; void (*)(void *) mov rdi, rbx; void * call ___cxa_throw mov r14, rax lea rax, [rsp+58h+var_28] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_59327 mov rsi, [rsp+58h+var_28] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_59327: lea rax, [rsp+58h+var_48] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_59342 mov rsi, [rsp+58h+var_48] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_59342: test bpl, bpl jnz short loc_5936C jmp short loc_59374 mov r14, rax lea rax, [rsp+58h+var_48] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_5936C mov rsi, [rsp+58h+var_48] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) jmp short loc_5936C mov r14, rax loc_5936C: mov rdi, rbx; void * call ___cxa_free_exception loc_59374: mov rdi, r14 call __Unwind_Resume
long long minja::Value::insert(minja::Value *this, long long a2, const minja::Value *a3) { _QWORD *v4; // rdi void *exception; // rbx _BYTE v7[16]; // [rsp+0h] [rbp-58h] BYREF _BYTE v8[16]; // [rsp+20h] [rbp-38h] BYREF v4 = (_QWORD *)*((_QWORD *)this + 2); if ( !v4 ) { exception = __cxa_allocate_exception(0x10uLL); minja::Value::dump[abi:cxx11]((long long)v7, (long long)this, 0xFFFFFFFF, 0); std::operator+<char>((long long)v8, (long long)"Value is not an array: ", (long long)v7); std::runtime_error::runtime_error(exception, v8); __cxa_throw( exception, (struct type_info *)&`typeinfo for'std::runtime_error, (void (*)(void *))&std::runtime_error::~runtime_error); } return std::vector<minja::Value>::insert(v4, *v4 + 80 * a2, a3); }
insert: PUSH RBP PUSH R14 PUSH RBX SUB RSP,0x40 MOV R14,RDI MOV RDI,qword ptr [RDI + 0x10] TEST RDI,RDI JZ 0x001592ae LEA RSI,[RSI + RSI*0x4] SHL RSI,0x4 ADD RSI,qword ptr [RDI] ADD RSP,0x40 POP RBX POP R14 POP RBP JMP 0x0015a9e6 LAB_001592ae: MOV EDI,0x10 CALL 0x0011a390 MOV RBX,RAX LAB_001592bb: MOV RDI,RSP MOV RSI,R14 MOV EDX,0xffffffff XOR ECX,ECX CALL 0x00142a18 LAB_001592cd: LEA RSI,[0x1b0d24] LEA RDI,[RSP + 0x20] MOV RDX,RSP CALL 0x00129d9d MOV BPL,0x1 LAB_001592e4: LEA RSI,[RSP + 0x20] MOV RDI,RBX CALL 0x0011ac00 XOR EBP,EBP MOV RSI,qword ptr [0x001e2ff0] MOV RDX,qword ptr [0x001e2f70] MOV RDI,RBX CALL 0x0011acd0
/* minja::Value::insert(unsigned long, minja::Value const&) */ void minja::Value::insert(ulong param_1,Value *param_2) { vector<minja::Value,std::allocator<minja::Value>> *pvVar1; runtime_error *this; int1 auStack_58 [32]; string local_38 [32]; pvVar1 = *(vector<minja::Value,std::allocator<minja::Value>> **)(param_1 + 0x10); if (pvVar1 != (vector<minja::Value,std::allocator<minja::Value>> *)0x0) { std::vector<minja::Value,std::allocator<minja::Value>>::insert (pvVar1,(long)param_2 * 0x50 + *(long *)pvVar1); return; } this = (runtime_error *)__cxa_allocate_exception(0x10); /* try { // try from 001592bb to 001592cc has its CatchHandler @ 00159369 */ dump_abi_cxx11_((int)auStack_58,SUB81(param_1,0)); /* try { // try from 001592cd to 001592e0 has its CatchHandler @ 00159349 */ std::operator+((char *)local_38,(string *)"Value is not an array: "); /* try { // try from 001592e4 to 00159308 has its CatchHandler @ 00159309 */ std::runtime_error::runtime_error(this,local_38); /* WARNING: Subroutine does not return */ __cxa_throw(this,PTR_typeinfo_001e2ff0,PTR__runtime_error_001e2f70); }
31,866
mysql_multi_update_prepare(THD*)
eloqsql/sql/sql_update.cc
int mysql_multi_update_prepare(THD *thd) { LEX *lex= thd->lex; TABLE_LIST *table_list= lex->query_tables; TABLE_LIST *tl; Multiupdate_prelocking_strategy prelocking_strategy; uint table_count= lex->table_count_update; DBUG_ENTER("mysql_multi_update_prepare"); /* Open tables and create derived ones, but do not lock and fill them yet. During prepare phase acquire only S metadata locks instead of SW locks to keep prepare of multi-UPDATE compatible with concurrent LOCK TABLES WRITE and global read lock. Don't evaluate any subqueries even if constant, because tables aren't locked yet. */ lex->context_analysis_only|= CONTEXT_ANALYSIS_ONLY_DERIVED; if (thd->lex->sql_command == SQLCOM_UPDATE_MULTI) { if (open_tables(thd, &table_list, &table_count, thd->stmt_arena->is_stmt_prepare() ? MYSQL_OPEN_FORCE_SHARED_MDL : 0, &prelocking_strategy)) DBUG_RETURN(TRUE); } else { /* following need for prepared statements, to run next time multi-update */ thd->lex->sql_command= SQLCOM_UPDATE_MULTI; prelocking_strategy.reset(thd); if (prelocking_strategy.handle_end(thd)) DBUG_RETURN(TRUE); } /* now lock and fill tables */ if (!thd->stmt_arena->is_stmt_prepare() && lock_tables(thd, table_list, table_count, 0)) DBUG_RETURN(TRUE); lex->context_analysis_only&= ~CONTEXT_ANALYSIS_ONLY_DERIVED; (void) read_statistics_for_tables_if_needed(thd, table_list); /* @todo: downgrade the metadata locks here. */ /* Check that we are not using table that we are updating, but we should skip all tables of UPDATE SELECT itself */ lex->first_select_lex()->exclude_from_table_unique_test= TRUE; /* We only need SELECT privilege for columns in the values list */ List_iterator<TABLE_LIST> ti(lex->first_select_lex()->leaf_tables); while ((tl= ti++)) { if (tl->is_jtbm()) continue; TABLE *table= tl->table; TABLE_LIST *tlist; if (!(tlist= tl->top_table())->derived) { tlist->grant.want_privilege= (SELECT_ACL & ~tlist->grant.privilege); table->grant.want_privilege= (SELECT_ACL & ~table->grant.privilege); } DBUG_PRINT("info", ("table: %s want_privilege: %llx", tl->alias.str, (longlong) table->grant.want_privilege)); } /* Set exclude_from_table_unique_test value back to FALSE. It is needed for further check in multi_update::prepare whether to use record cache. */ lex->first_select_lex()->exclude_from_table_unique_test= FALSE; if (lex->save_prep_leaf_tables()) DBUG_RETURN(TRUE); DBUG_RETURN (FALSE); }
O0
cpp
mysql_multi_update_prepare(THD*): pushq %rbp movq %rsp, %rbp subq $0x100, %rsp # imm = 0x100 movq %fs:0x28, %rax movq %rax, -0x8(%rbp) movq %rdi, -0x28(%rbp) movq -0x28(%rbp), %rax movq 0x58(%rax), %rax movq %rax, -0x30(%rbp) movq -0x30(%rbp), %rax movq 0x10(%rax), %rax movq %rax, -0x38(%rbp) leaq -0x18(%rbp), %rdi callq 0xaf4780 movq -0x30(%rbp), %rax movl 0x1834(%rax), %eax movl %eax, -0x44(%rbp) movq -0x30(%rbp), %rax movzbl 0x183a(%rax), %ecx orl $0x4, %ecx movb %cl, 0x183a(%rax) movq -0x28(%rbp), %rax movq 0x58(%rax), %rax cmpl $0x48, 0x8(%rax) jne 0xaf090b movq -0x28(%rbp), %rax movq %rax, -0x98(%rbp) movq 0x3a40(%rax), %rdi callq 0x9598f0 movb %al, -0x89(%rbp) jmp 0xaf089f movq -0x98(%rbp), %rdi movb -0x89(%rbp), %al movzbl %al, %ecx andl $0x1, %ecx shll $0x9, %ecx leaq -0x38(%rbp), %rsi leaq -0x44(%rbp), %rdx leaq -0x18(%rbp), %r8 callq 0xaf0c20 movb %al, -0x99(%rbp) jmp 0xaf08ce movb -0x99(%rbp), %al testb $0x1, %al jne 0xaf08da jmp 0xaf0909 jmp 0xaf08dc movl $0x1, -0x1c(%rbp) movl $0x1, -0x58(%rbp) jmp 0xaf0bbe movq %rax, %rcx movl %edx, %eax movq %rcx, -0x50(%rbp) movl %eax, -0x54(%rbp) leaq -0x18(%rbp), %rdi callq 0xaf47c0 jmp 0xaf0bf1 jmp 0xaf0961 movq -0x28(%rbp), %rax movq 0x58(%rax), %rax movl $0x48, 0x8(%rax) movq -0x28(%rbp), %rsi leaq -0x18(%rbp), %rdi callq 0xaefc50 jmp 0xaf0929 movq -0x28(%rbp), %rsi leaq -0x18(%rbp), %rdi callq 0xaefc90 movb %al, -0x9a(%rbp) jmp 0xaf093e movb -0x9a(%rbp), %al testb $0x1, %al jne 0xaf094a jmp 0xaf095f jmp 0xaf094c movl $0x1, -0x1c(%rbp) movl $0x1, -0x58(%rbp) jmp 0xaf0bbe jmp 0xaf0961 movq -0x28(%rbp), %rax movq 0x3a40(%rax), %rdi callq 0x9598f0 movb %al, -0x9b(%rbp) jmp 0xaf0979 movb -0x9b(%rbp), %al testb $0x1, %al jne 0xaf09c0 jmp 0xaf0985 movq -0x28(%rbp), %rdi movq -0x38(%rbp), %rsi movl -0x44(%rbp), %edx xorl %ecx, %ecx callq 0x950340 movb %al, -0x9c(%rbp) jmp 0xaf099f movb -0x9c(%rbp), %al testb $0x1, %al jne 0xaf09ab jmp 0xaf09c0 jmp 0xaf09ad movl $0x1, -0x1c(%rbp) movl $0x1, -0x58(%rbp) jmp 0xaf0bbe movq -0x30(%rbp), %rax movb 0x183a(%rax), %cl andb $-0x5, %cl movb %cl, 0x183a(%rax) movq -0x28(%rbp), %rdi movq -0x38(%rbp), %rsi callq 0xaa57e0 jmp 0xaf09e2 movq -0x30(%rbp), %rdi callq 0x87e3a0 movq %rax, -0xa8(%rbp) jmp 0xaf09f4 movq -0xa8(%rbp), %rax movb 0x389(%rax), %cl orb $-0x80, %cl movb %cl, 0x389(%rax) movq -0x30(%rbp), %rdi callq 0x87e3a0 movq %rax, -0xb0(%rbp) jmp 0xaf0a1c movq -0xb0(%rbp), %rsi addq $0x218, %rsi # imm = 0x218 leaq -0x78(%rbp), %rdi callq 0x8d3680 jmp 0xaf0a35 jmp 0xaf0a37 leaq -0x78(%rbp), %rdi xorl %esi, %esi callq 0x8d36b0 movq %rax, -0xb8(%rbp) jmp 0xaf0a4b movq -0xb8(%rbp), %rax movq %rax, -0x40(%rbp) cmpq $0x0, %rax je 0xaf0b57 movq -0x40(%rbp), %rdi callq 0x9f99c0 movb %al, -0xb9(%rbp) jmp 0xaf0a71 movb -0xb9(%rbp), %al testb $0x1, %al jne 0xaf0a7d jmp 0xaf0a7f jmp 0xaf0a37 movq -0x40(%rbp), %rax movq 0x100(%rax), %rax movq %rax, -0x80(%rbp) movq -0x40(%rbp), %rdi callq 0x9599d0 movq %rax, -0xc8(%rbp) jmp 0xaf0aa0 movq -0xc8(%rbp), %rax movq %rax, -0x88(%rbp) cmpq $0x0, 0x128(%rax) jne 0xaf0b4c movq -0x88(%rbp), %rax movq 0x300(%rax), %rdi callq 0xaef820 movq %rax, -0xd0(%rbp) jmp 0xaf0ad8 movq -0xd0(%rbp), %rsi movl $0x1, %edi callq 0xaef800 movq %rax, -0xd8(%rbp) jmp 0xaf0af2 movq -0xd8(%rbp), %rcx movq -0x88(%rbp), %rax movq %rcx, 0x308(%rax) movq -0x80(%rbp), %rax movq 0x350(%rax), %rdi callq 0xaef820 movq %rax, -0xe0(%rbp) jmp 0xaf0b20 movq -0xe0(%rbp), %rsi movl $0x1, %edi callq 0xaef800 movq %rax, -0xe8(%rbp) jmp 0xaf0b3a movq -0xe8(%rbp), %rcx movq -0x80(%rbp), %rax movq %rcx, 0x358(%rax) jmp 0xaf0b4e jmp 0xaf0b50 jmp 0xaf0b52 jmp 0xaf0a37 movq -0x30(%rbp), %rdi callq 0x87e3a0 movq %rax, -0xf0(%rbp) jmp 0xaf0b69 movq -0xf0(%rbp), %rax movb 0x389(%rax), %cl andb $0x7f, %cl movb %cl, 0x389(%rax) movq -0x30(%rbp), %rdi callq 0x9b7e90 movb %al, -0xf1(%rbp) jmp 0xaf0b90 movb -0xf1(%rbp), %al testb $0x1, %al jne 0xaf0b9c jmp 0xaf0bae jmp 0xaf0b9e movl $0x1, -0x1c(%rbp) movl $0x1, -0x58(%rbp) jmp 0xaf0bbe jmp 0xaf0bb0 movl $0x0, -0x1c(%rbp) movl $0x1, -0x58(%rbp) leaq -0x18(%rbp), %rdi callq 0xaf47c0 movl -0x1c(%rbp), %eax movl %eax, -0xf8(%rbp) movq %fs:0x28, %rax movq -0x8(%rbp), %rcx cmpq %rcx, %rax jne 0xaf0c1a movl -0xf8(%rbp), %eax addq $0x100, %rsp # imm = 0x100 popq %rbp retq movq -0x50(%rbp), %rax movq %rax, -0x100(%rbp) movq %fs:0x28, %rax movq -0x8(%rbp), %rcx cmpq %rcx, %rax jne 0xaf0c1a movq -0x100(%rbp), %rdi callq 0x775a20 callq 0x7754c0 nop
_Z26mysql_multi_update_prepareP3THD: push rbp mov rbp, rsp sub rsp, 100h mov rax, fs:28h mov [rbp+var_8], rax mov [rbp+var_28], rdi mov rax, [rbp+var_28] mov rax, [rax+58h] mov [rbp+var_30], rax mov rax, [rbp+var_30] mov rax, [rax+10h] mov [rbp+var_38], rax lea rdi, [rbp+var_18]; this call _ZN31Multiupdate_prelocking_strategyC2Ev; Multiupdate_prelocking_strategy::Multiupdate_prelocking_strategy(void) mov rax, [rbp+var_30] mov eax, [rax+1834h] mov [rbp+var_44], eax mov rax, [rbp+var_30] movzx ecx, byte ptr [rax+183Ah] or ecx, 4 mov [rax+183Ah], cl mov rax, [rbp+var_28] mov rax, [rax+58h] cmp dword ptr [rax+8], 48h ; 'H' jnz loc_AF090B mov rax, [rbp+var_28] mov [rbp+var_98], rax mov rdi, [rax+3A40h]; this call _ZNK11Query_arena15is_stmt_prepareEv; Query_arena::is_stmt_prepare(void) mov [rbp+var_89], al jmp short $+2 loc_AF089F: mov rdi, [rbp+var_98]; THD * mov al, [rbp+var_89] movzx ecx, al and ecx, 1 shl ecx, 9; unsigned int lea rsi, [rbp+var_38]; TABLE_LIST ** lea rdx, [rbp+var_44]; unsigned int * lea r8, [rbp+var_18]; Prelocking_strategy * call _ZL11open_tablesP3THDPP10TABLE_LISTPjjP19Prelocking_strategy_2; open_tables(THD *,TABLE_LIST **,uint *,uint,Prelocking_strategy *) mov [rbp+var_99], al jmp short $+2 loc_AF08CE: mov al, [rbp+var_99] test al, 1 jnz short loc_AF08DA jmp short loc_AF0909 loc_AF08DA: jmp short $+2 loc_AF08DC: mov [rbp+var_1C], 1 mov [rbp+var_58], 1 jmp loc_AF0BBE mov rcx, rax mov eax, edx mov [rbp+var_50], rcx mov [rbp+var_54], eax lea rdi, [rbp+var_18]; this call _ZN31Multiupdate_prelocking_strategyD2Ev; Multiupdate_prelocking_strategy::~Multiupdate_prelocking_strategy() jmp loc_AF0BF1 loc_AF0909: jmp short loc_AF0961 loc_AF090B: mov rax, [rbp+var_28] mov rax, [rax+58h] mov dword ptr [rax+8], 48h ; 'H' mov rsi, [rbp+var_28]; THD * lea rdi, [rbp+var_18]; this call _ZN31Multiupdate_prelocking_strategy5resetEP3THD; Multiupdate_prelocking_strategy::reset(THD *) jmp short $+2 loc_AF0929: mov rsi, [rbp+var_28]; THD * lea rdi, [rbp+var_18]; this call _ZN31Multiupdate_prelocking_strategy10handle_endEP3THD; Multiupdate_prelocking_strategy::handle_end(THD *) mov [rbp+var_9A], al jmp short $+2 loc_AF093E: mov al, [rbp+var_9A] test al, 1 jnz short loc_AF094A jmp short loc_AF095F loc_AF094A: jmp short $+2 loc_AF094C: mov [rbp+var_1C], 1 mov [rbp+var_58], 1 jmp loc_AF0BBE loc_AF095F: jmp short $+2 loc_AF0961: mov rax, [rbp+var_28] mov rdi, [rax+3A40h]; this call _ZNK11Query_arena15is_stmt_prepareEv; Query_arena::is_stmt_prepare(void) mov [rbp+var_9B], al jmp short $+2 loc_AF0979: mov al, [rbp+var_9B] test al, 1 jnz short loc_AF09C0 jmp short $+2 loc_AF0985: mov rdi, [rbp+var_28]; THD * mov rsi, [rbp+var_38]; TABLE_LIST * mov edx, [rbp+var_44]; unsigned int xor ecx, ecx; unsigned int call _Z11lock_tablesP3THDP10TABLE_LISTjj; lock_tables(THD *,TABLE_LIST *,uint,uint) mov [rbp+var_9C], al jmp short $+2 loc_AF099F: mov al, [rbp+var_9C] test al, 1 jnz short loc_AF09AB jmp short loc_AF09C0 loc_AF09AB: jmp short $+2 loc_AF09AD: mov [rbp+var_1C], 1 mov [rbp+var_58], 1 jmp loc_AF0BBE loc_AF09C0: mov rax, [rbp+var_30] mov cl, [rax+183Ah] and cl, 0FBh mov [rax+183Ah], cl mov rdi, [rbp+var_28]; THD * mov rsi, [rbp+var_38]; TABLE_LIST * call _Z36read_statistics_for_tables_if_neededP3THDP10TABLE_LIST; read_statistics_for_tables_if_needed(THD *,TABLE_LIST *) jmp short $+2 loc_AF09E2: mov rdi, [rbp+var_30]; this call _ZN3LEX16first_select_lexEv; LEX::first_select_lex(void) mov [rbp+var_A8], rax jmp short $+2 loc_AF09F4: mov rax, [rbp+var_A8] mov cl, [rax+389h] or cl, 80h mov [rax+389h], cl mov rdi, [rbp+var_30]; this call _ZN3LEX16first_select_lexEv; LEX::first_select_lex(void) mov [rbp+var_B0], rax jmp short $+2 loc_AF0A1C: mov rsi, [rbp+var_B0] add rsi, 218h lea rdi, [rbp+var_78] call _ZN13List_iteratorI10TABLE_LISTEC2ER4ListIS0_E; List_iterator<TABLE_LIST>::List_iterator(List<TABLE_LIST> &) jmp short $+2 loc_AF0A35: jmp short $+2 loc_AF0A37: lea rdi, [rbp+var_78] xor esi, esi call _ZN13List_iteratorI10TABLE_LISTEppEi; List_iterator<TABLE_LIST>::operator++(int) mov [rbp+var_B8], rax jmp short $+2 loc_AF0A4B: mov rax, [rbp+var_B8] mov [rbp+var_40], rax cmp rax, 0 jz loc_AF0B57 mov rdi, [rbp+var_40]; this call _ZN10TABLE_LIST7is_jtbmEv; TABLE_LIST::is_jtbm(void) mov [rbp+var_B9], al jmp short $+2 loc_AF0A71: mov al, [rbp+var_B9] test al, 1 jnz short loc_AF0A7D jmp short loc_AF0A7F loc_AF0A7D: jmp short loc_AF0A37 loc_AF0A7F: mov rax, [rbp+var_40] mov rax, [rax+100h] mov [rbp+var_80], rax mov rdi, [rbp+var_40]; this call _ZN10TABLE_LIST9top_tableEv; TABLE_LIST::top_table(void) mov [rbp+var_C8], rax jmp short $+2 loc_AF0AA0: mov rax, [rbp+var_C8] mov [rbp+var_88], rax cmp qword ptr [rax+128h], 0 jnz loc_AF0B4C mov rax, [rbp+var_88] mov rdi, [rax+300h] call _Zco11privilege_t_4; operator~(privilege_t) mov [rbp+var_D0], rax jmp short $+2 loc_AF0AD8: mov rsi, [rbp+var_D0] mov edi, 1 call _Zan11privilege_ty_4; operator&(privilege_t,ulong long) mov [rbp+var_D8], rax jmp short $+2 loc_AF0AF2: mov rcx, [rbp+var_D8] mov rax, [rbp+var_88] mov [rax+308h], rcx mov rax, [rbp+var_80] mov rdi, [rax+350h] call _Zco11privilege_t_4; operator~(privilege_t) mov [rbp+var_E0], rax jmp short $+2 loc_AF0B20: mov rsi, [rbp+var_E0] mov edi, 1 call _Zan11privilege_ty_4; operator&(privilege_t,ulong long) mov [rbp+var_E8], rax jmp short $+2 loc_AF0B3A: mov rcx, [rbp+var_E8] mov rax, [rbp+var_80] mov [rax+358h], rcx loc_AF0B4C: jmp short $+2 loc_AF0B4E: jmp short $+2 loc_AF0B50: jmp short $+2 loc_AF0B52: jmp loc_AF0A37 loc_AF0B57: mov rdi, [rbp+var_30]; this call _ZN3LEX16first_select_lexEv; LEX::first_select_lex(void) mov [rbp+var_F0], rax jmp short $+2 loc_AF0B69: mov rax, [rbp+var_F0] mov cl, [rax+389h] and cl, 7Fh mov [rax+389h], cl mov rdi, [rbp+var_30]; this call _ZN3LEX21save_prep_leaf_tablesEv; LEX::save_prep_leaf_tables(void) mov [rbp+var_F1], al jmp short $+2 loc_AF0B90: mov al, [rbp+var_F1] test al, 1 jnz short loc_AF0B9C jmp short loc_AF0BAE loc_AF0B9C: jmp short $+2 loc_AF0B9E: mov [rbp+var_1C], 1 mov [rbp+var_58], 1 jmp short loc_AF0BBE loc_AF0BAE: jmp short $+2 loc_AF0BB0: mov [rbp+var_1C], 0 mov [rbp+var_58], 1 loc_AF0BBE: lea rdi, [rbp+var_18]; this call _ZN31Multiupdate_prelocking_strategyD2Ev; Multiupdate_prelocking_strategy::~Multiupdate_prelocking_strategy() mov eax, [rbp+var_1C] mov [rbp+var_F8], eax mov rax, fs:28h mov rcx, [rbp+var_8] cmp rax, rcx jnz short loc_AF0C1A mov eax, [rbp+var_F8] add rsp, 100h pop rbp retn loc_AF0BF1: mov rax, [rbp+var_50] mov [rbp+var_100], rax mov rax, fs:28h mov rcx, [rbp+var_8] cmp rax, rcx jnz short loc_AF0C1A mov rdi, [rbp+var_100] call __Unwind_Resume loc_AF0C1A: call ___stack_chk_fail
_BOOL8 mysql_multi_update_prepare(LEX **a1) { long long v2; // [rsp+10h] [rbp-F0h] long long v3; // [rsp+20h] [rbp-E0h] long long v4; // [rsp+30h] [rbp-D0h] long long v5; // [rsp+50h] [rbp-B0h] long long select_lex; // [rsp+58h] [rbp-A8h] bool is_stmt_prepare; // [rsp+77h] [rbp-89h] TABLE_LIST *v8; // [rsp+78h] [rbp-88h] long long v9; // [rsp+80h] [rbp-80h] _BYTE v10[32]; // [rsp+88h] [rbp-78h] BYREF int v11; // [rsp+A8h] [rbp-58h] unsigned int v12; // [rsp+BCh] [rbp-44h] BYREF TABLE_LIST *v13; // [rsp+C0h] [rbp-40h] TABLE_LIST *v14; // [rsp+C8h] [rbp-38h] BYREF LEX *v15; // [rsp+D0h] [rbp-30h] THD *v16; // [rsp+D8h] [rbp-28h] BOOL v17; // [rsp+E4h] [rbp-1Ch] _BYTE v18[16]; // [rsp+E8h] [rbp-18h] BYREF unsigned long long v19; // [rsp+F8h] [rbp-8h] v19 = __readfsqword(0x28u); v16 = (THD *)a1; v15 = a1[11]; v14 = (TABLE_LIST *)*((_QWORD *)v15 + 2); Multiupdate_prelocking_strategy::Multiupdate_prelocking_strategy((Multiupdate_prelocking_strategy *)v18); v12 = *((_DWORD *)v15 + 1549); *((_BYTE *)v15 + 6202) |= 4u; if ( *(_DWORD *)(*((_QWORD *)v16 + 11) + 8LL) == 72 ) { is_stmt_prepare = Query_arena::is_stmt_prepare(*((Query_arena **)v16 + 1864)); if ( (open_tables(v16, &v14, &v12, (unsigned __int8)is_stmt_prepare << 9, (Prelocking_strategy *)v18) & 1) != 0 ) { v17 = 1; v11 = 1; goto LABEL_17; } } else { *(_DWORD *)(*((_QWORD *)v16 + 11) + 8LL) = 72; Multiupdate_prelocking_strategy::reset((Multiupdate_prelocking_strategy *)v18, v16); if ( (Multiupdate_prelocking_strategy::handle_end((Multiupdate_prelocking_strategy *)v18, v16) & 1) != 0 ) { v17 = 1; v11 = 1; goto LABEL_17; } } if ( Query_arena::is_stmt_prepare(*((Query_arena **)v16 + 1864)) || (lock_tables(v16, v14, v12, 0) & 1) == 0 ) { *((_BYTE *)v15 + 6202) &= ~4u; read_statistics_for_tables_if_needed(v16, v14); select_lex = LEX::first_select_lex(v15); *(_BYTE *)(select_lex + 905) |= 0x80u; v5 = LEX::first_select_lex(v15); List_iterator<TABLE_LIST>::List_iterator((base_list_iterator *)v10, (base_list *)(v5 + 536)); while ( 1 ) { v13 = (TABLE_LIST *)List_iterator<TABLE_LIST>::operator++((base_list_iterator *)v10); if ( !v13 ) break; if ( !TABLE_LIST::is_jtbm(v13) ) { v9 = *((_QWORD *)v13 + 32); v8 = TABLE_LIST::top_table(v13); if ( !*((_QWORD *)v8 + 37) ) { v4 = operator~(*((_QWORD *)v8 + 96)); *((_QWORD *)v8 + 97) = operator&(1LL, v4); v3 = operator~(*(_QWORD *)(v9 + 848)); *(_QWORD *)(v9 + 856) = operator&(1LL, v3); } } } v2 = LEX::first_select_lex(v15); *(_BYTE *)(v2 + 905) &= ~0x80u; v17 = (LEX::save_prep_leaf_tables((Query_arena ***)v15) & 1) != 0; v11 = 1; } else { v17 = 1; v11 = 1; } LABEL_17: Multiupdate_prelocking_strategy::~Multiupdate_prelocking_strategy((Multiupdate_prelocking_strategy *)v18); return v17; }
check_rename_table: PUSH RBP MOV RBP,RSP SUB RSP,0xe30 MOV RAX,qword ptr FS:[0x28] MOV qword ptr [RBP + -0x8],RAX MOV qword ptr [RBP + -0xdd8],RDI MOV qword ptr [RBP + -0xde0],RSI MOV qword ptr [RBP + -0xde8],RDX JMP 0x00af083f LAB_00af083f: MOV RAX,qword ptr [RBP + -0xde0] MOV qword ptr [RBP + -0xdf0],RAX LAB_00af084d: CMP qword ptr [RBP + -0xdf0],0x0 JZ 0x00af0ada MOV RAX,qword ptr [RBP + -0xdd8] MOV qword ptr [RBP + -0xdf8],RAX MOV EDI,0x2000 MOV ESI,0x20 CALL 0x00aef6a0 MOV RDI,qword ptr [RBP + -0xdf8] MOV RSI,RAX MOV RAX,qword ptr [RBP + -0xdf0] MOV RDX,qword ptr [RAX + 0x18] MOV RCX,qword ptr [RBP + -0xdf0] ADD RCX,0x2e8 ADD RCX,0x18 MOV R8,qword ptr [RBP + -0xdf0] ADD R8,0x2e8 ADD R8,0x30 XOR R9D,R9D MOV dword ptr [RSP],0x0 CALL 0x00aef6c0 TEST AL,0x1 JNZ 0x00af0938 MOV RAX,qword ptr [RBP + -0xdd8] MOV qword ptr [RBP + -0xe00],RAX MOV EDI,0x2 MOV ESI,0x10 CALL 0x00aef6a0 MOV RDI,qword ptr [RBP + -0xe00] MOV RSI,RAX MOV RAX,qword ptr [RBP + -0xdf0] MOV RAX,qword ptr [RAX] MOV RDX,qword ptr [RAX + 0x18] MOV RAX,qword ptr [RBP + -0xdf0] MOV RCX,qword ptr [RAX] ADD RCX,0x2e8 ADD RCX,0x18 MOV RAX,qword ptr [RBP + -0xdf0] MOV R8,qword ptr [RAX] ADD R8,0x2e8 ADD R8,0x30 XOR R9D,R9D MOV dword ptr [RSP],0x0 CALL 0x00aef6c0 TEST AL,0x1 JNZ 0x00af0938 JMP 0x00af0944 LAB_00af0938: MOV byte ptr [RBP + -0xdc9],0x1 JMP 0x00af0ae1 LAB_00af0944: MOV RDI,qword ptr [RBP + -0xdd8] MOV RSI,qword ptr [RBP + -0xde0] MOV RDX,qword ptr [RBP + -0xdf0] CALL 0x00af8330 MOV RCX,RAX MOV RAX,qword ptr [RBP + -0xdf0] MOV qword ptr [RAX + 0x100],RCX MOV RAX,qword ptr [RBP + -0xdf0] MOV RCX,qword ptr [RAX + 0x100] MOV RAX,qword ptr [RBP + -0xdf0] MOV RAX,qword ptr [RAX] MOV qword ptr [RAX + 0x100],RCX LEA RDI,[RBP + -0x6e8] CALL 0x009535a0 LEA RDI,[RBP + -0xdc8] CALL 0x009535a0 MOV RSI,qword ptr [RBP + -0xdf0] LEA RDI,[RBP + -0x6e8] CALL 0x00aaa8c0 MOV RAX,qword ptr [RBP + -0xdf0] MOV RSI,qword ptr [RAX] LEA RDI,[RBP + -0xdc8] CALL 0x00aaa8c0 MOV RAX,qword ptr [RBP + -0xdd8] MOV qword ptr [RBP + -0xe08],RAX MOV EDI,0x2000 MOV ESI,0x20 CALL 0x00aef6a0 MOV RDI,qword ptr [RBP + -0xe08] MOV RSI,RAX LEA RDX,[RBP + -0x6e8] XOR R9D,R9D MOV R8D,0x1 MOV ECX,R9D CALL 0x00a29eb0 TEST AL,0x1 JNZ 0x00af0ab6 MOV RAX,qword ptr [RBP + -0xdf0] MOV RAX,qword ptr [RAX] MOV RAX,qword ptr [RAX + 0x300] MOV qword ptr [RBP + -0xe18],RAX MOV EDI,0x2 MOV ESI,0x10 CALL 0x00aef6a0 MOV RDI,qword ptr [RBP + -0xe18] MOV RSI,RAX CALL 0x00ae2eb0 MOV qword ptr [RBP + -0xe10],RAX MOV EDI,0x2 MOV ESI,0x10 CALL 0x00aef6a0 MOV RCX,RAX MOV RAX,qword ptr [RBP + -0xe10] CMP RAX,RCX JZ 0x00af0abf MOV RAX,qword ptr [RBP + -0xdd8] MOV qword ptr [RBP + -0xe20],RAX MOV EDI,0x2 MOV ESI,0x10 CALL 0x00aef6a0 MOV RDI,qword ptr [RBP + -0xe20] MOV RSI,RAX LEA RDX,[RBP + -0xdc8] XOR R9D,R9D MOV R8D,0x1 MOV ECX,R9D CALL 0x00a29eb0 TEST AL,0x1 JNZ 0x00af0ab6 JMP 0x00af0abf LAB_00af0ab6: MOV byte ptr [RBP + -0xdc9],0x1 JMP 0x00af0ae1 LAB_00af0abf: JMP 0x00af0ac1 LAB_00af0ac1: MOV RAX,qword ptr [RBP + -0xdf0] MOV RAX,qword ptr [RAX] MOV RAX,qword ptr [RAX] MOV qword ptr [RBP + -0xdf0],RAX JMP 0x00af084d LAB_00af0ada: MOV byte ptr [RBP + -0xdc9],0x0 LAB_00af0ae1: MOV AL,byte ptr [RBP + -0xdc9] MOV byte ptr [RBP + -0xe21],AL MOV RAX,qword ptr FS:[0x28] MOV RCX,qword ptr [RBP + -0x8] CMP RAX,RCX JNZ 0x00af0b10 MOV AL,byte ptr [RBP + -0xe21] AND AL,0x1 ADD RSP,0xe30 POP RBP RET LAB_00af0b10: CALL 0x008754c0
/* check_rename_table(THD*, TABLE_LIST*, TABLE_LIST*) */ int8 check_rename_table(THD *param_1,TABLE_LIST *param_2,TABLE_LIST *param_3) { int8 uVar1; ulong uVar2; int8 uVar3; long lVar4; long lVar5; long in_FS_OFFSET; TABLE_LIST *local_df8; int1 local_dd1; TABLE_LIST local_dd0 [1760]; TABLE_LIST local_6f0 [1760]; long local_10; local_10 = *(long *)(in_FS_OFFSET + 0x28); local_df8 = param_2; do { if (local_df8 == (TABLE_LIST *)0x0) { local_dd1 = 0; LAB_00af0ae1: if (*(long *)(in_FS_OFFSET + 0x28) != local_10) { /* WARNING: Subroutine does not return */ __stack_chk_fail(); } return CONCAT71((int7)((ulong)*(long *)(in_FS_OFFSET + 0x28) >> 8),local_dd1); } uVar1 = operator|(0x2000,0x20); uVar2 = check_access(param_1,uVar1,*(int8 *)(local_df8 + 0x18),local_df8 + 0x300, local_df8 + 0x318,0,0); if ((uVar2 & 1) != 0) { LAB_00af0938: local_dd1 = 1; goto LAB_00af0ae1; } uVar1 = operator|(2,0x10); uVar2 = check_access(param_1,uVar1,*(int8 *)(*(long *)local_df8 + 0x18), *(long *)local_df8 + 0x300,*(long *)local_df8 + 0x318,0,0); if ((uVar2 & 1) != 0) goto LAB_00af0938; uVar1 = find_temporary_table_for_rename(param_1,param_2,local_df8); *(int8 *)(local_df8 + 0x100) = uVar1; *(int8 *)(*(long *)local_df8 + 0x100) = *(int8 *)(local_df8 + 0x100); TABLE_LIST::TABLE_LIST(local_6f0); TABLE_LIST::TABLE_LIST(local_dd0); TABLE_LIST::operator=(local_6f0,local_df8); TABLE_LIST::operator=(local_dd0,*(TABLE_LIST **)local_df8); uVar1 = operator|(0x2000,0x20); uVar2 = check_grant(param_1,uVar1,local_6f0,0,1); if ((uVar2 & 1) != 0) { LAB_00af0ab6: local_dd1 = 1; goto LAB_00af0ae1; } uVar1 = *(int8 *)(*(long *)local_df8 + 0x300); uVar3 = operator|(2,0x10); lVar4 = operator&(uVar1,uVar3); lVar5 = operator|(2,0x10); if (lVar4 != lVar5) { uVar1 = operator|(2,0x10); uVar2 = check_grant(param_1,uVar1,local_dd0,0,1); if ((uVar2 & 1) != 0) goto LAB_00af0ab6; } local_df8 = (TABLE_LIST *)**(int8 **)local_df8; } while( true ); }
31,867
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::get<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
monkey531[P]llama/common/minja.hpp
inline json Value::get<json>() const { if (is_primitive()) return primitive_; if (is_null()) return json(); if (array_) { std::vector<json> res; for (const auto& item : *array_) { res.push_back(item.get<json>()); } return res; } if (object_) { json res = json::object(); for (const auto& [key, value] : *object_) { if (key.is_string()) { res[key.get<std::string>()] = value.get<json>(); } else if (key.is_primitive()) { res[key.dump()] = value.get<json>(); } else { throw std::runtime_error("Invalid key type for conversion to JSON: " + key.dump()); } } if (is_callable()) { res["__callable__"] = true; } return res; } throw std::runtime_error("get<json> not defined for this value type: " + dump()); }
O3
cpp
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::get<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 $0xb8, %rsp movq %rsi, %r14 movq %rdi, %rbx movq 0x10(%rsi), %rax movq 0x20(%rsi), %rcx movq %rax, %rsi orq %rcx, %rsi movq 0x30(%r14), %rdx orq %rdx, %rsi jne 0xb13bc addq $0x40, %r14 movq %rbx, %rdi movq %r14, %rsi callq 0x5d6e2 jmp 0xb1612 testq %rdx, %rdx sete %dl movq %rax, %rsi orq %rcx, %rsi sete %sil cmpb $0x0, 0x40(%r14) sete %dil andb %sil, %dil andb %dl, %dil cmpb $0x1, %dil jne 0xb140b movb $0x0, (%rbx) movq $0x0, 0x8(%rbx) movq %rbx, %rdi movl $0x1, %esi callq 0x586c0 movq %rbx, %rdi movl $0x1, %esi callq 0x586c0 jmp 0xb1612 testq %rax, %rax je 0xb147d xorps %xmm0, %xmm0 movaps %xmm0, (%rsp) movq $0x0, 0x10(%rsp) movq (%rax), %r14 movq 0x8(%rax), %r13 cmpq %r13, %r14 je 0xb1465 leaq 0x20(%rsp), %r15 movq %rsp, %r12 movq %r15, %rdi movq %r14, %rsi callq 0xb137a movq %r12, %rdi movq %r15, %rsi callq 0x5d282 movq %r15, %rdi xorl %esi, %esi callq 0x586c0 movq %r15, %rdi callq 0x5dbae addq $0x50, %r14 cmpq %r13, %r14 jne 0xb1434 movq %rsp, %rsi movq %rbx, %rdi callq 0xb1fd6 movq %rsp, %rdi callq 0x5e3c0 jmp 0xb1612 testq %rcx, %rcx je 0xb168d movq %rbx, %rdi xorl %esi, %esi xorl %edx, %edx xorl %ecx, %ecx movl $0x1, %r8d callq 0x7ebb2 movq 0x20(%r14), %rax movq (%rax), %r15 movq 0x8(%rax), %r13 cmpq %r13, %r15 je 0xb15b4 leaq 0xa8(%rsp), %rbp leaq 0x50(%rsp), %r12 leaq 0x10(%r15), %rsi movzbl (%r15), %eax testl %eax, %eax je 0xb1532 cmpl $0x4, %eax je 0xb1532 cmpl $0x3, %eax jne 0xb1528 leaq 0x40(%rsp), %rdi callq 0xb137a leaq 0x88(%rsp), %r12 movq %r12, %rdi movq %r15, %rsi callq 0x874a8 movq %rbx, %rdi movq %r12, %rsi callq 0xab2ba movq %rax, %rdi leaq 0x40(%rsp), %r12 movq %r12, %rsi callq 0x5ae62 movq 0x88(%rsp), %rdi leaq 0x98(%rsp), %rcx movq %rcx, %rax cmpq %rcx, %rdi jne 0xb1580 leaq 0x40(%rsp), %r12 jmp 0xb1590 addb $-0x5, %al cmpb $0x3, %al ja 0xb1627 movq %rbp, %rdi callq 0xb137a movq %r12, %rdi movq %r15, %rsi movl $0xffffffff, %edx # imm = 0xFFFFFFFF movl $0x20, %ecx xorl %r8d, %r8d xorl %r9d, %r9d callq 0x7f79e movq %rbx, %rdi movq %r12, %rsi callq 0xab2ba movq %rax, %rdi movq %rbp, %rsi callq 0x5ae62 movq 0x50(%rsp), %rdi leaq 0x60(%rsp), %rcx movq %rcx, %rax movq %rbp, %r12 cmpq %rcx, %rdi je 0xb158d movq (%rax), %rsi incq %rsi callq 0x1a8d0 jmp 0xb1590 movq %rbp, %r12 movq %r12, %rdi xorl %esi, %esi callq 0x586c0 movq %r12, %rdi callq 0x5dbae addq $0x60, %r15 cmpq %r13, %r15 leaq 0x50(%rsp), %r12 jne 0xb14bb cmpq $0x0, 0x30(%r14) je 0xb1612 xorps %xmm0, %xmm0 leaq 0x70(%rsp), %r14 movaps %xmm0, (%r14) movq %r14, %rdi movl $0x1, %esi callq 0x5fcf0 movq %r14, %rdi movl $0x1, %esi callq 0x586c0 leaq 0x3fc2b(%rip), %rsi # 0xf1213 movq %rbx, %rdi callq 0xa4818 leaq 0x70(%rsp), %r14 movq %rax, %rdi movq %r14, %rsi callq 0x5ae62 movq %r14, %rdi xorl %esi, %esi callq 0x586c0 movq %r14, %rdi callq 0x5dbae movq %rbx, %rax addq $0xb8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq movl $0x10, %edi callq 0x1a450 movq %rax, %r12 leaq 0x20(%rsp), %rdi movq %r15, %rsi movl $0xffffffff, %edx # imm = 0xFFFFFFFF movl $0x20, %ecx xorl %r8d, %r8d xorl %r9d, %r9d callq 0x7f79e leaq 0x3fb91(%rip), %rsi # 0xf11e9 movq %rsp, %rdi leaq 0x20(%rsp), %rdx callq 0x78b0d movb $0x1, %bpl movq %rsp, %rsi movq %r12, %rdi callq 0x1ae50 xorl %ebp, %ebp movq 0x7a974(%rip), %rsi # 0x12bff0 movq 0x7a8dd(%rip), %rdx # 0x12bf60 movq %r12, %rdi callq 0x1af40 jmp 0xb16e8 movl $0x10, %edi callq 0x1a450 movq %rax, %rbx leaq 0x20(%rsp), %rdi movq %r14, %rsi movl $0xffffffff, %edx # imm = 0xFFFFFFFF xorl %ecx, %ecx callq 0x86378 leaq 0x3fb6b(%rip), %rsi # 0xf1220 movq %rsp, %rdi leaq 0x20(%rsp), %rdx callq 0x78b0d movb $0x1, %bpl movq %rsp, %rsi movq %rbx, %rdi callq 0x1ae50 xorl %ebp, %ebp movq 0x7a917(%rip), %rsi # 0x12bff0 movq 0x7a880(%rip), %rdx # 0x12bf60 movq %rbx, %rdi callq 0x1af40 movq %rax, %r14 leaq 0x10(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0xb1706 movq 0x10(%rsp), %rsi incq %rsi callq 0x1a8d0 leaq 0x30(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0xb1721 movq 0x30(%rsp), %rsi incq %rsi callq 0x1a8d0 testb %bpl, %bpl jne 0xb174e jmp 0xb188f movq %rax, %r14 leaq 0x30(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0xb174e movq 0x30(%rsp), %rsi incq %rsi callq 0x1a8d0 jmp 0xb174e movq %rax, %r14 movq %rbx, %rdi callq 0x1a680 jmp 0xb188f movq %rax, %r14 leaq 0x70(%rsp), %r15 jmp 0xb183d movq %rax, %r14 leaq 0x10(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0xb1786 movq 0x10(%rsp), %rsi incq %rsi callq 0x1a8d0 leaq 0x30(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0xb17a1 movq 0x30(%rsp), %rsi incq %rsi callq 0x1a8d0 testb %bpl, %bpl jne 0xb17d3 jmp 0xb1854 movq %rax, %r14 leaq 0x30(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0xb17d3 movq 0x30(%rsp), %rsi incq %rsi callq 0x1a8d0 jmp 0xb17d3 jmp 0xb1868 movq %rax, %r14 movq %r12, %rdi callq 0x1a680 jmp 0xb1854 movq %rax, %r14 movq 0x88(%rsp), %rdi leaq 0x98(%rsp), %rax cmpq %rax, %rdi je 0xb180a movq 0x98(%rsp), %rsi incq %rsi callq 0x1a8d0 jmp 0xb180a movq %rax, %r14 leaq 0x40(%rsp), %r15 jmp 0xb183d movq %rax, %r14 movq 0x50(%rsp), %rdi leaq 0x60(%rsp), %rax cmpq %rax, %rdi je 0xb1835 movq 0x60(%rsp), %rsi incq %rsi callq 0x1a8d0 jmp 0xb1835 movq %rax, %r14 leaq 0xa8(%rsp), %r15 movq %r15, %rdi xorl %esi, %esi callq 0x586c0 movq %r15, %rdi callq 0x5dbae jmp 0xb1854 movq %rax, %r14 movq %rbx, %rdi xorl %esi, %esi callq 0x586c0 movq %rbx, %rdi callq 0x5dbae jmp 0xb188f movq %rax, %r14 jmp 0xb1887 movq %rax, %r14 leaq 0x20(%rsp), %rbx movq %rbx, %rdi xorl %esi, %esi callq 0x586c0 movq %rbx, %rdi callq 0x5dbae movq %rsp, %rdi callq 0x5e3c0 movq %r14, %rdi callq 0x1afc0
_ZNK5minja5Value3getIN8nlohmann16json_abi_v3_11_310basic_jsonINS3_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS3_14adl_serializerES6_IhSaIhEEvEEEET_v: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 0B8h mov r14, rsi mov rbx, rdi mov rax, [rsi+10h] mov rcx, [rsi+20h] mov rsi, rax or rsi, rcx mov rdx, [r14+30h] or rsi, rdx jnz short loc_B13BC add r14, 40h ; '@' mov rdi, rbx mov rsi, r14 call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEC2ERKSD_; 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> const&) jmp loc_B1612 loc_B13BC: test rdx, rdx setz dl mov rsi, rax or rsi, rcx setz sil cmp byte ptr [r14+40h], 0 setz dil and dil, sil and dil, dl cmp dil, 1 jnz short loc_B140B mov byte ptr [rbx], 0 mov qword ptr [rbx+8], 0 mov rdi, rbx 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 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) jmp loc_B1612 loc_B140B: test rax, rax jz short loc_B147D xorps xmm0, xmm0 movaps [rsp+0E8h+var_E8], xmm0 mov [rsp+0E8h+var_D8], 0 mov r14, [rax] mov r13, [rax+8] cmp r14, r13 jz short loc_B1465 lea r15, [rsp+0E8h+var_C8] mov r12, rsp loc_B1434: mov rdi, r15 mov rsi, r14 call _ZNK5minja5Value3getIN8nlohmann16json_abi_v3_11_310basic_jsonINS3_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS3_14adl_serializerES6_IhSaIhEEvEEEET_v; minja::Value::get<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>>(void) mov rdi, r12 mov rsi, r15 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 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() add r14, 50h ; 'P' cmp r14, r13 jnz short loc_B1434 loc_B1465: mov rsi, rsp mov rdi, rbx call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEC2IS3_ISD_SaISD_EESG_TnNSt9enable_ifIXaantsr6detail13is_basic_jsonIT0_EE5valuesr6detail18is_compatible_typeISD_SI_EE5valueEiE4typeELi0EEEOT_ mov rdi, rsp call _ZNSt6vectorIN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapES_NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES_IhSaIhEEvEESaISD_EED2Ev; 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>>::~vector() jmp loc_B1612 loc_B147D: test rcx, rcx jz loc_B168D mov rdi, rbx xor esi, esi xor edx, edx xor ecx, ecx mov r8d, 1 call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEC2ESt16initializer_listINS0_6detail8json_refISD_EEEbNSF_7value_tE; 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(std::initializer_list<nlohmann::json_abi_v3_11_3::detail::json_ref<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>>>,bool,nlohmann::json_abi_v3_11_3::detail::value_t) mov rax, [r14+20h] mov r15, [rax] mov r13, [rax+8] cmp r15, r13 jz loc_B15B4 lea rbp, [rsp+0E8h+var_40] lea r12, [rsp+0E8h+var_98] loc_B14BB: lea rsi, [r15+10h] movzx eax, byte ptr [r15] test eax, eax jz short loc_B1532 cmp eax, 4 jz short loc_B1532 cmp eax, 3 jnz short loc_B1528 lea rdi, [rsp+0E8h+var_A8] call _ZNK5minja5Value3getIN8nlohmann16json_abi_v3_11_310basic_jsonINS3_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS3_14adl_serializerES6_IhSaIhEEvEEEET_v; minja::Value::get<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>>(void) lea r12, [rsp+0E8h+var_60] mov rdi, r12 mov rsi, r15 call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE8get_implIS9_TnNSt9enable_ifIXaasr6detail24is_default_constructibleIT_EE5valuesr6detail13has_from_jsonISD_SG_EE5valueEiE4typeELi0EEESG_NS0_6detail12priority_tagILj0EEE mov rdi, rbx mov rsi, r12 call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEixES9_; 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[](std::string) mov rdi, rax lea r12, [rsp+0E8h+var_A8] mov rsi, r12 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+0E8h+var_60] lea rcx, [rsp+0E8h+var_50] mov rax, rcx cmp rdi, rcx jnz short loc_B1580 lea r12, [rsp+0E8h+var_A8] jmp short loc_B1590 loc_B1528: add al, 0FBh cmp al, 3 ja loc_B1627 loc_B1532: mov rdi, rbp call _ZNK5minja5Value3getIN8nlohmann16json_abi_v3_11_310basic_jsonINS3_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS3_14adl_serializerES6_IhSaIhEEvEEEET_v; minja::Value::get<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>>(void) mov rdi, r12 mov rsi, r15 mov edx, 0FFFFFFFFh mov ecx, 20h ; ' ' xor r8d, r8d xor r9d, r9d call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE4dumpEicbNS0_6detail15error_handler_tE; 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(int,char,bool,nlohmann::json_abi_v3_11_3::detail::error_handler_t) mov rdi, rbx mov rsi, r12 call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEixES9_; 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[](std::string) mov rdi, rax mov rsi, rbp 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+0E8h+var_98]; void * lea rcx, [rsp+0E8h+var_88] mov rax, rcx mov r12, rbp cmp rdi, rcx jz short loc_B158D loc_B1580: mov rsi, [rax] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) jmp short loc_B1590 loc_B158D: mov r12, rbp loc_B1590: mov rdi, r12 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, r12 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() add r15, 60h ; '`' cmp r15, r13 lea r12, [rsp+0E8h+var_98] jnz loc_B14BB loc_B15B4: cmp qword ptr [r14+30h], 0 jz short loc_B1612 xorps xmm0, xmm0 lea r14, [rsp+0E8h+var_78] movaps xmmword ptr [r14], xmm0 mov rdi, r14 mov esi, 1 call _ZN8nlohmann16json_abi_v3_11_36detail20external_constructorILNS1_7value_tE4EE9constructINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES8_IhSaIhEEvEEEEvRT_NSJ_9boolean_tE; nlohmann::json_abi_v3_11_3::detail::external_constructor<(nlohmann::json_abi_v3_11_3::detail::value_t)4>::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>::boolean_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) lea rsi, aCallable; "__callable__" mov rdi, rbx call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEixIKcEERSD_PT_; 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[]<char const>(char const *) lea r14, [rsp+0E8h+var_78] mov rdi, rax mov rsi, r14 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, 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() loc_B1612: mov rax, rbx add rsp, 0B8h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn loc_B1627: mov edi, 10h; thrown_size call ___cxa_allocate_exception mov r12, rax lea rdi, [rsp+0E8h+var_C8] mov rsi, r15 mov edx, 0FFFFFFFFh mov ecx, 20h ; ' ' xor r8d, r8d xor r9d, r9d call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE4dumpEicbNS0_6detail15error_handler_tE; 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(int,char,bool,nlohmann::json_abi_v3_11_3::detail::error_handler_t) lea rsi, aInvalidKeyType; "Invalid key type for conversion to JSON"... mov rdi, rsp lea rdx, [rsp+0E8h+var_C8] call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_OS8_; std::operator+<char>(char const*,std::string&&) mov bpl, 1 mov rsi, rsp mov rdi, r12 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, r12; void * call ___cxa_throw jmp short loc_B16E8 loc_B168D: mov edi, 10h; thrown_size call ___cxa_allocate_exception mov rbx, rax lea rdi, [rsp+0E8h+var_C8] mov rsi, r14 mov edx, 0FFFFFFFFh xor ecx, ecx call _ZNK5minja5Value4dumpB5cxx11Eib; minja::Value::dump(int,bool) lea rsi, aGetJsonNotDefi; "get<json> not defined for this value ty"... mov rdi, rsp lea rdx, [rsp+0E8h+var_C8] call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_OS8_; std::operator+<char>(char const*,std::string&&) 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:_ZTISt13runtime_error_ptr; lptinfo mov rdx, cs:_ZTISt19_Sp_make_shared_tag; void (*)(void *) mov rdi, rbx; void * call ___cxa_throw loc_B16E8: mov r14, rax lea rax, [rsp+0E8h+var_D8] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_B1706 mov rsi, [rsp+0E8h+var_D8] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_B1706: lea rax, [rsp+0E8h+var_B8] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_B1721 mov rsi, [rsp+0E8h+var_B8] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_B1721: test bpl, bpl jnz short loc_B174E jmp loc_B188F mov r14, rax lea rax, [rsp+0E8h+var_B8] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_B174E mov rsi, [rsp+0E8h+var_B8] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) jmp short loc_B174E mov r14, rax loc_B174E: mov rdi, rbx; void * call ___cxa_free_exception jmp loc_B188F mov r14, rax lea r15, [rsp+0E8h+var_78] jmp loc_B183D mov r14, rax lea rax, [rsp+0E8h+var_D8] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_B1786 mov rsi, [rsp+0E8h+var_D8] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_B1786: lea rax, [rsp+0E8h+var_B8] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_B17A1 mov rsi, [rsp+0E8h+var_B8] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_B17A1: test bpl, bpl jnz short loc_B17D3 jmp loc_B1854 mov r14, rax lea rax, [rsp+0E8h+var_B8] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_B17D3 mov rsi, [rsp+0E8h+var_B8] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) jmp short loc_B17D3 jmp loc_B1868 mov r14, rax loc_B17D3: mov rdi, r12; void * call ___cxa_free_exception jmp short loc_B1854 mov r14, rax mov rdi, [rsp+0E8h+var_60]; void * lea rax, [rsp+0E8h+var_50] cmp rdi, rax jz short loc_B180A mov rsi, [rsp+0E8h+var_50] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) jmp short loc_B180A mov r14, rax loc_B180A: lea r15, [rsp+0E8h+var_A8] jmp short loc_B183D mov r14, rax mov rdi, [rsp+0E8h+var_98]; void * lea rax, [rsp+0E8h+var_88] cmp rdi, rax jz short loc_B1835 mov rsi, [rsp+0E8h+var_88] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) jmp short loc_B1835 mov r14, rax loc_B1835: lea r15, [rsp+0E8h+var_40] loc_B183D: 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() jmp short loc_B1854 mov r14, rax loc_B1854: mov rdi, rbx 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, rbx 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() jmp short loc_B188F loc_B1868: mov r14, rax jmp short loc_B1887 mov r14, rax lea rbx, [rsp+0E8h+var_C8] mov rdi, rbx 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, rbx 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_B1887: mov rdi, rsp call _ZNSt6vectorIN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapES_NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES_IhSaIhEEvEESaISD_EED2Ev; 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>>::~vector() loc_B188F: mov rdi, r14 call __Unwind_Resume
long long minja::Value::get<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) { unsigned long long v4; // rax long long v5; // rcx long long v6; // rdx long long v7; // r14 long long v8; // r13 long long v9; // rax _BYTE *v10; // r15 _BYTE *v11; // r13 _BYTE *v12; // rsi int v13; // eax long long v14; // rax char *v15; // r12 void *v16; // rdi _QWORD *v17; // rax long long v18; // rax long long v19; // rax void *v21; // r12 void *exception; // rbx __int128 v23; // [rsp+0h] [rbp-E8h] BYREF long long v24; // [rsp+10h] [rbp-D8h] char v25[16]; // [rsp+20h] [rbp-C8h] BYREF _BYTE v26[16]; // [rsp+40h] [rbp-A8h] BYREF void *v27[2]; // [rsp+50h] [rbp-98h] BYREF _QWORD v28[2]; // [rsp+60h] [rbp-88h] BYREF char v29[24]; // [rsp+70h] [rbp-78h] BYREF void *v30[2]; // [rsp+88h] [rbp-60h] BYREF _QWORD v31[2]; // [rsp+98h] [rbp-50h] BYREF _BYTE v32[64]; // [rsp+A8h] [rbp-40h] BYREF v4 = *(_QWORD *)(a2 + 16); v5 = *(_QWORD *)(a2 + 32); v6 = *(_QWORD *)(a2 + 48); if ( !(v6 | v5 | v4) ) { 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( (unsigned __int8 *)a1, (unsigned __int8 *)(a2 + 64)); return a1; } if ( v6 == 0 && (v5 | v4) == 0 && *(_BYTE *)(a2 + 64) == 0 ) { *(_BYTE *)a1 = 0; *(_QWORD *)(a1 + 8) = 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 *)a1); 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 *)a1); return a1; } if ( v4 ) { v23 = 0LL; v24 = 0LL; v7 = *(_QWORD *)v4; v8 = *(_QWORD *)(v4 + 8); if ( *(_QWORD *)v4 != v8 ) { do { minja::Value::get<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, v7); 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>>( (long long)&v23, (long long)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(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); v7 += 80LL; } while ( v7 != v8 ); } ((void ( *)(long long, __int128 *))ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEC2IS3_ISD_SaISD_EESG_TnNSt9enable_ifIXaantsr6detail13is_basic_jsonIT0_EE5valuesr6detail18is_compatible_typeISD_SI_EE5valueEiE4typeELi0EEEOT_)( a1, &v23); 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>>::~vector((long long)&v23); return a1; } if ( !v5 ) { exception = __cxa_allocate_exception(0x10uLL); minja::Value::dump[abi:cxx11]((long long)v25, a2, 0xFFFFFFFF, 0); std::operator+<char>((long long)&v23, (long long)"get<json> not defined for this value type: ", (long long)v25); std::runtime_error::runtime_error(exception, &v23); __cxa_throw( exception, (struct type_info *)&`typeinfo for'std::runtime_error, (void (*)(void *))&std::runtime_error::~runtime_error); } 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( a1, 0LL, 0LL, 0LL, 1LL); v9 = *(_QWORD *)(a2 + 32); v10 = *(_BYTE **)v9; v11 = *(_BYTE **)(v9 + 8); if ( *(_BYTE **)v9 != v11 ) { while ( 1 ) { v12 = v10 + 16; v13 = (unsigned __int8)*v10; if ( !*v10 || v13 == 4 ) goto LABEL_17; if ( v13 != 3 ) break; minja::Value::get<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>>( v26, v12); ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE8get_implIS9_TnNSt9enable_ifIXaasr6detail24is_default_constructibleIT_EE5valuesr6detail13has_from_jsonISD_SG_EE5valueEiE4typeELi0EEESG_NS0_6detail12priority_tagILj0EEE( (long long)v30, (long long)v10); v14 = 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[]( a1, (long long *)v30); v15 = 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=( v14, (long long)v26); v16 = v30[0]; v17 = v31; if ( v30[0] != v31 ) goto LABEL_18; v15 = v26; LABEL_20: 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(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>::data::~data(v15); v10 += 96; if ( v10 == v11 ) goto LABEL_21; } if ( (unsigned __int8)(v13 - 5) > 3u ) { v21 = __cxa_allocate_exception(0x10uLL); 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( (long long)v25, (long long)v10, -1, 32, 0, 0); std::operator+<char>((long long)&v23, (long long)"Invalid key type for conversion to JSON: ", (long long)v25); std::runtime_error::runtime_error(v21, &v23); __cxa_throw( v21, (struct type_info *)&`typeinfo for'std::runtime_error, (void (*)(void *))&std::runtime_error::~runtime_error); } LABEL_17: minja::Value::get<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>>( v32, v12); 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( (long long)v27, (long long)v10, -1, 32, 0, 0); v18 = 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[]( 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>::operator=( v18, (long long)v32); v16 = v27[0]; v17 = v28; v15 = v32; if ( v27[0] == v28 ) { v15 = v32; goto LABEL_20; } LABEL_18: operator delete(v16, *v17 + 1LL); goto LABEL_20; } LABEL_21: if ( *(_QWORD *)(a2 + 48) ) { *(_OWORD *)v29 = 0LL; nlohmann::json_abi_v3_11_3::detail::external_constructor<(nlohmann::json_abi_v3_11_3::detail::value_t)4>::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>>( (unsigned __int8 *)v29, 1u); 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(v29); v19 = 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[]<char const>( a1, "__callable__"); 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=( v19, (long long)v29); 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(v29); 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(v29); } return a1; }
get<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 R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0xb8 MOV R14,RSI MOV RBX,RDI MOV RAX,qword ptr [RSI + 0x10] MOV RCX,qword ptr [RSI + 0x20] MOV RSI,RAX OR RSI,RCX MOV RDX,qword ptr [R14 + 0x30] OR RSI,RDX JNZ 0x001b13bc ADD R14,0x40 MOV RDI,RBX MOV RSI,R14 CALL 0x0015d6e2 JMP 0x001b1612 LAB_001b13bc: TEST RDX,RDX SETZ DL MOV RSI,RAX OR RSI,RCX SETZ SIL CMP byte ptr [R14 + 0x40],0x0 SETZ DIL AND DIL,SIL AND DIL,DL CMP DIL,0x1 JNZ 0x001b140b MOV byte ptr [RBX],0x0 MOV qword ptr [RBX + 0x8],0x0 MOV RDI,RBX MOV ESI,0x1 CALL 0x001586c0 MOV RDI,RBX MOV ESI,0x1 CALL 0x001586c0 JMP 0x001b1612 LAB_001b140b: TEST RAX,RAX JZ 0x001b147d XORPS XMM0,XMM0 MOVAPS xmmword ptr [RSP],XMM0 MOV qword ptr [RSP + 0x10],0x0 MOV R14,qword ptr [RAX] MOV R13,qword ptr [RAX + 0x8] CMP R14,R13 JZ 0x001b1465 LEA R15,[RSP + 0x20] MOV R12,RSP LAB_001b1434: MOV RDI,R15 MOV RSI,R14 CALL 0x001b137a LAB_001b143f: MOV RDI,R12 MOV RSI,R15 CALL 0x0015d282 MOV RDI,R15 XOR ESI,ESI CALL 0x001586c0 MOV RDI,R15 CALL 0x0015dbae ADD R14,0x50 CMP R14,R13 JNZ 0x001b1434 LAB_001b1465: MOV RSI,RSP MOV RDI,RBX CALL 0x001b1fd6 LAB_001b1470: MOV RDI,RSP CALL 0x0015e3c0 JMP 0x001b1612 LAB_001b147d: TEST RCX,RCX JZ 0x001b168d MOV RDI,RBX XOR ESI,ESI XOR EDX,EDX XOR ECX,ECX MOV R8D,0x1 CALL 0x0017ebb2 MOV RAX,qword ptr [R14 + 0x20] MOV R15,qword ptr [RAX] MOV R13,qword ptr [RAX + 0x8] CMP R15,R13 JZ 0x001b15b4 LEA RBP,[RSP + 0xa8] LEA R12,[RSP + 0x50] LAB_001b14bb: LEA RSI,[R15 + 0x10] MOVZX EAX,byte ptr [R15] TEST EAX,EAX JZ 0x001b1532 CMP EAX,0x4 JZ 0x001b1532 CMP EAX,0x3 JNZ 0x001b1528 LAB_001b14d1: LEA RDI,[RSP + 0x40] CALL 0x001b137a LAB_001b14db: LEA R12,[RSP + 0x88] MOV RDI,R12 MOV RSI,R15 CALL 0x001874a8 LAB_001b14ee: MOV RDI,RBX MOV RSI,R12 CALL 0x001ab2ba MOV RDI,RAX LEA R12,[RSP + 0x40] MOV RSI,R12 CALL 0x0015ae62 MOV RDI,qword ptr [RSP + 0x88] LEA RCX,[RSP + 0x98] MOV RAX,RCX CMP RDI,RCX JNZ 0x001b1580 LEA R12,[RSP + 0x40] JMP 0x001b1590 LAB_001b1528: ADD AL,0xfb CMP AL,0x3 JA 0x001b1627 LAB_001b1532: MOV RDI,RBP CALL 0x001b137a LAB_001b153a: MOV RDI,R12 MOV RSI,R15 MOV EDX,0xffffffff MOV ECX,0x20 XOR R8D,R8D XOR R9D,R9D CALL 0x0017f79e LAB_001b1555: MOV RDI,RBX MOV RSI,R12 CALL 0x001ab2ba MOV RDI,RAX MOV RSI,RBP CALL 0x0015ae62 MOV RDI,qword ptr [RSP + 0x50] LEA RCX,[RSP + 0x60] MOV RAX,RCX MOV R12,RBP CMP RDI,RCX JZ 0x001b158d LAB_001b1580: MOV RSI,qword ptr [RAX] INC RSI CALL 0x0011a8d0 JMP 0x001b1590 LAB_001b158d: MOV R12,RBP LAB_001b1590: MOV RDI,R12 XOR ESI,ESI CALL 0x001586c0 MOV RDI,R12 CALL 0x0015dbae ADD R15,0x60 CMP R15,R13 LEA R12,[RSP + 0x50] JNZ 0x001b14bb LAB_001b15b4: CMP qword ptr [R14 + 0x30],0x0 JZ 0x001b1612 XORPS XMM0,XMM0 LEA R14,[RSP + 0x70] MOVAPS xmmword ptr [R14],XMM0 MOV RDI,R14 MOV ESI,0x1 CALL 0x0015fcf0 MOV RDI,R14 MOV ESI,0x1 CALL 0x001586c0 LAB_001b15e1: LEA RSI,[0x1f1213] MOV RDI,RBX CALL 0x001a4818 LAB_001b15f0: LEA R14,[RSP + 0x70] MOV RDI,RAX MOV RSI,R14 CALL 0x0015ae62 MOV RDI,R14 XOR ESI,ESI CALL 0x001586c0 MOV RDI,R14 CALL 0x0015dbae LAB_001b1612: MOV RAX,RBX ADD RSP,0xb8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET LAB_001b1627: MOV EDI,0x10 CALL 0x0011a450 MOV R12,RAX LAB_001b1634: LEA RDI,[RSP + 0x20] MOV RSI,R15 MOV EDX,0xffffffff MOV ECX,0x20 XOR R8D,R8D XOR R9D,R9D CALL 0x0017f79e LAB_001b1651: LEA RSI,[0x1f11e9] MOV RDI,RSP LEA RDX,[RSP + 0x20] CALL 0x00178b0d MOV BPL,0x1 LAB_001b1668: MOV RSI,RSP MOV RDI,R12 CALL 0x0011ae50 XOR EBP,EBP MOV RSI,qword ptr [0x0022bff0] MOV RDX,qword ptr [0x0022bf60] MOV RDI,R12 CALL 0x0011af40 LAB_001b168d: MOV EDI,0x10 CALL 0x0011a450 MOV RBX,RAX LAB_001b169a: LEA RDI,[RSP + 0x20] MOV RSI,R14 MOV EDX,0xffffffff XOR ECX,ECX CALL 0x00186378 LAB_001b16ae: LEA RSI,[0x1f1220] MOV RDI,RSP LEA RDX,[RSP + 0x20] CALL 0x00178b0d MOV BPL,0x1 LAB_001b16c5: MOV RSI,RSP MOV RDI,RBX CALL 0x0011ae50 XOR EBP,EBP MOV RSI,qword ptr [0x0022bff0] MOV RDX,qword ptr [0x0022bf60] MOV RDI,RBX CALL 0x0011af40
/* 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::get<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 */ void minja::Value:: get<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>> (void) { char cVar1; long lVar2; char *pcVar3; 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> *pbVar4; long *plVar5; basic_json *pbVar6; runtime_error *prVar7; long in_RSI; 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; long *plVar8; data *this; long lVar9; char *pcVar10; int8 local_e8; int8 uStack_e0; int8 local_d8; data local_c8 [32]; data local_a8 [16]; long *local_98 [2]; long local_88 [2]; int8 local_78; int8 uStack_70; long *local_60 [2]; long local_50 [2]; data local_40 [16]; plVar5 = *(long **)(in_RSI + 0x10); lVar9 = *(long *)(in_RSI + 0x20); if ((plVar5 == (long *)0x0 && lVar9 == 0) && *(long *)(in_RSI + 0x30) == 0) { 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(in_RDI,(basic_json *)(in_RSI + 0x40)); } else if ((*(char *)(in_RSI + 0x40) == '\0' && (plVar5 == (long *)0x0 && lVar9 == 0)) && *(long *)(in_RSI + 0x30) == 0) { *in_RDI = (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> )0x0; *(int8 *)(in_RDI + 8) = 0; 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> ::assert_invariant(SUB81(in_RDI,0)); 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> ::assert_invariant(SUB81(in_RDI,0)); } else if (plVar5 == (long *)0x0) { if (lVar9 == 0) { prVar7 = (runtime_error *)__cxa_allocate_exception(0x10); /* try { // try from 001b169a to 001b16ad has its CatchHandler @ 001b174b */ dump_abi_cxx11_((int)local_c8,SUB81(in_RSI,0)); /* try { // try from 001b16ae to 001b16c1 has its CatchHandler @ 001b172b */ std::operator+((char *)&local_e8,(string *)"get<json> not defined for this value type: "); /* try { // try from 001b16c5 to 001b16e7 has its CatchHandler @ 001b16e8 */ std::runtime_error::runtime_error(prVar7,(string *)&local_e8); /* WARNING: Subroutine does not return */ __cxa_throw(prVar7,PTR_typeinfo_0022bff0,PTR__runtime_error_0022bf60); } 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(); pcVar10 = (char *)**(int8 **)(in_RSI + 0x20); pcVar3 = (char *)(*(int8 **)(in_RSI + 0x20))[1]; if (pcVar10 != pcVar3) { do { cVar1 = *pcVar10; if ((cVar1 == '\0') || (cVar1 == '\x04')) { LAB_001b1532: /* try { // try from 001b1532 to 001b1539 has its CatchHandler @ 001b1851 */ get<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>> (); /* try { // try from 001b153a to 001b1554 has its CatchHandler @ 001b1832 */ 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(local_98,pcVar10,0xffffffff,0x20,0,0); /* try { // try from 001b1555 to 001b155f has its CatchHandler @ 001b1811 */ pbVar4 = (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> ::operator[](); 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=(pbVar4,local_40); plVar5 = local_88; plVar8 = local_98[0]; this = local_40; if (local_98[0] != plVar5) { LAB_001b1580: operator_delete(plVar8,*plVar5 + 1); } } else { if (cVar1 != '\x03') { if (3 < (byte)(cVar1 - 5U)) { prVar7 = (runtime_error *)__cxa_allocate_exception(0x10,pcVar10 + 0x10); /* try { // try from 001b1634 to 001b1650 has its CatchHandler @ 001b17d0 */ 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(local_c8,pcVar10,0xffffffff,0x20,0,0); /* try { // try from 001b1651 to 001b1664 has its CatchHandler @ 001b17ab */ std::operator+((char *)&local_e8,(string *)"Invalid key type for conversion to JSON: " ); /* try { // try from 001b1668 to 001b168a has its CatchHandler @ 001b1768 */ std::runtime_error::runtime_error(prVar7,(string *)&local_e8); /* WARNING: Subroutine does not return */ __cxa_throw(prVar7,PTR_typeinfo_0022bff0,PTR__runtime_error_0022bf60); } goto LAB_001b1532; } /* try { // try from 001b14d1 to 001b14da has its CatchHandler @ 001b1851 */ get<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>> (); /* try { // try from 001b14db to 001b14ed has its CatchHandler @ 001b1807 */ _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE8get_implIS9_TnNSt9enable_ifIXaasr6detail24is_default_constructibleIT_EE5valuesr6detail13has_from_jsonISD_SG_EE5valueEiE4typeELi0EEESG_NS0_6detail12priority_tagILj0EEE (local_60,pcVar10); /* try { // try from 001b14ee to 001b14f8 has its CatchHandler @ 001b17dd */ pbVar4 = (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> ::operator[](); 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=(pbVar4,local_a8); plVar5 = local_50; plVar8 = local_60[0]; this = local_a8; if (local_60[0] != plVar5) goto LAB_001b1580; this = local_a8; } 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> ::assert_invariant(SUB81(this,0)); 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> ::data::~data(this); pcVar10 = pcVar10 + 0x60; } while (pcVar10 != pcVar3); } if (*(long *)(in_RSI + 0x30) != 0) { local_78 = 0; uStack_70 = 0; nlohmann::json_abi_v3_11_3::detail:: external_constructor<(nlohmann::json_abi_v3_11_3::detail::value_t)4>:: 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_78,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> ::assert_invariant(SUB81(&local_78,0)); /* try { // try from 001b15e1 to 001b15ef has its CatchHandler @ 001b175b */ pbVar6 = 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[]<char_const>(in_RDI,"__callable__"); 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=((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> *)pbVar6,(data *)&local_78); 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> ::assert_invariant(SUB81((data *)&local_78,0)); 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> ::data::~data((data *)&local_78); } } else { local_e8 = 0; uStack_e0 = 0; local_d8 = 0; lVar9 = *plVar5; lVar2 = plVar5[1]; if (lVar9 != lVar2) { do { /* try { // try from 001b1434 to 001b143e has its CatchHandler @ 001b1868 */ get<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>> (); /* try { // try from 001b143f to 001b1449 has its CatchHandler @ 001b186d */ 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>>> *)&local_e8,(basic_json *)local_c8); 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> ::assert_invariant(SUB81(local_c8,0)); 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> ::data::~data(local_c8); lVar9 = lVar9 + 0x50; } while (lVar9 != lVar2); } /* try { // try from 001b1465 to 001b146f has its CatchHandler @ 001b17cb */ _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEC2IS3_ISD_SaISD_EESG_TnNSt9enable_ifIXaantsr6detail13is_basic_jsonIT0_EE5valuesr6detail18is_compatible_typeISD_SI_EE5valueEiE4typeELi0EEEOT_ (); 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>>> ::~vector((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>>> *)&local_e8); } return; }
31,868
ma_read_rnd_static_record
eloqsql/storage/maria/ma_statrec.c
int _ma_read_rnd_static_record(MARIA_HA *info, uchar *buf, MARIA_RECORD_POS filepos, my_bool skip_deleted_blocks) { int locked,error,cache_read; uint cache_length; MARIA_SHARE *share= info->s; DBUG_ENTER("_ma_read_rnd_static_record"); cache_read=0; cache_length=0; if (info->opt_flag & READ_CACHE_USED) { /* Cache in use */ if (filepos == my_b_tell(&info->rec_cache) && (skip_deleted_blocks || !filepos)) { cache_read=1; /* Read record using cache */ cache_length= (uint) (info->rec_cache.read_end - info->rec_cache.read_pos); } else info->rec_cache.seek_not_done=1; /* Filepos is changed */ } locked=0; if (info->lock_type == F_UNLCK) { if (filepos >= info->state->data_file_length) { /* Test if new records */ if (_ma_readinfo(info,F_RDLCK,0)) DBUG_RETURN(my_errno); locked=1; } else { /* We don't nead new info */ #ifndef UNSAFE_LOCKING if ((! cache_read || share->base.reclength > cache_length) && share->tot_locks == 0) { /* record not in cache */ locked=1; } #else info->tmp_lock_type=F_RDLCK; #endif } } if (filepos >= info->state->data_file_length) { DBUG_PRINT("test",("filepos: %ld (%ld) records: %ld del: %ld", (long) filepos/share->base.reclength, (long) filepos, (long) info->state->records, (long) info->state->del)); fast_ma_writeinfo(info); DBUG_RETURN(my_errno=HA_ERR_END_OF_FILE); } info->cur_row.lastpos= filepos; info->cur_row.nextpos= filepos+share->base.pack_reclength; if (! cache_read) /* No cacheing */ { error= _ma_read_static_record(info, buf, filepos); DBUG_RETURN(error); } /* Read record with cacheing */ error=my_b_read(&info->rec_cache, buf, share->base.reclength); if (info->s->base.pack_reclength != info->s->base.reclength && !error) { uchar tmp[8]; /* Skill fill bytes */ error=my_b_read(&info->rec_cache, tmp, info->s->base.pack_reclength - info->s->base.reclength); } if (locked) _ma_writeinfo(info,0); /* Unlock keyfile */ if (!error) { if (!buf[0]) { /* Record is removed */ DBUG_RETURN(my_errno=HA_ERR_RECORD_DELETED); } /* Found and may be updated */ info->update|= HA_STATE_AKTIV | HA_STATE_KEY_CHANGED; DBUG_RETURN(0); } /* my_errno should be set if rec_cache.error == -1 */ if (info->rec_cache.error != -1 || my_errno == 0) _ma_set_fatal_error(info, HA_ERR_WRONG_IN_RECORD); DBUG_RETURN(my_errno); /* Something wrong (EOF?) */ }
O3
c
ma_read_rnd_static_record: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x18, %rsp movq %rdx, %r15 movq %rsi, %r8 movq %rdi, %rbx movq %fs:0x28, %rax movq %rax, -0x30(%rbp) movb $0x1, %r13b testb $0x2, 0x61c(%rdi) je 0x70593 leaq 0x4c8(%rbx), %rax leaq 0x4f8(%rbx), %rdx cmpl $0x2, 0x568(%rbx) movq 0x4b8(%rbx), %rsi cmoveq %rdx, %rax subq 0x4e0(%rbx), %rsi addq (%rax), %rsi cmpq %r15, %rsi jne 0x70589 testb %cl, %cl sete %al testq %r15, %r15 setne %cl testb %al, %cl je 0x706a0 movl $0x1, 0x598(%rbx) xorl %eax, %eax movb $0x1, %r12b movq (%rbx), %r14 cmpl $0x2, 0x664(%rbx) jne 0x705e7 movq 0x20(%rbx), %rcx cmpq %r15, 0x28(%rcx) jbe 0x705ca testb %r12b, %r12b jne 0x705bc cmpq %rax, 0x398(%r14) jbe 0x705e7 cmpl $0x0, 0x7b8(%r14) setne %r13b jmp 0x705e7 movq %r8, %r13 movq %rbx, %rdi xorl %esi, %esi xorl %edx, %edx callq 0x428b2 testl %eax, %eax jne 0x70770 movq %r13, %r8 xorl %r13d, %r13d movq 0x20(%rbx), %rax cmpq %r15, 0x28(%rax) jbe 0x7063d movq %r15, 0x98(%rbx) movq 0x3a0(%r14), %rax addq %r15, %rax movq %rax, 0xa0(%rbx) testb %r12b, %r12b je 0x70668 movq %fs:0x28, %rax cmpq -0x30(%rbp), %rax jne 0x707a7 movq %rbx, %rdi movq %r8, %rsi movq %r15, %rdx addq $0x18, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp jmp 0x70446 movq (%rbx), %rax cmpl $0x0, 0x7b8(%rax) jne 0x70653 movq %rbx, %rdi xorl %esi, %esi callq 0x428ba callq 0xa1c0e movl $0x89, (%rax) movl $0x89, %eax jmp 0x70777 leaq 0x4b8(%rbx), %r15 movq 0x398(%r14), %r12 movq 0x4c8(%rbx), %rsi leaq (%rsi,%r12), %rax cmpq 0x4d0(%rbx), %rax jbe 0x706b4 movq %r15, %rdi movq %r8, %r14 movq %r8, %rsi movq %r12, %rdx callq 0x9570a movl %eax, %r12d jmp 0x706cc movl 0x4d0(%rbx), %eax subl 0x4c8(%rbx), %eax xorl %r12d, %r12d jmp 0x70598 movq %r8, %r14 movq %r8, %rdi movq %r12, %rdx callq 0x29080 addq %r12, 0x4c8(%rbx) xorl %r12d, %r12d movq (%rbx), %rax movq 0x3a0(%rax), %rdx subq 0x398(%rax), %rdx je 0x70729 testl %r12d, %r12d jne 0x70729 movq %r14, -0x40(%rbp) movq 0x4c8(%rbx), %rsi leaq (%rsi,%rdx), %r14 cmpq 0x4d0(%rbx), %r14 jbe 0x7070d leaq -0x38(%rbp), %rsi movq %r15, %rdi callq 0x9570a movl %eax, %r12d jmp 0x70725 leaq -0x38(%rbp), %rdi movl $0x8, %ecx callq 0x29410 movq %r14, 0x4c8(%rbx) xorl %r12d, %r12d movq -0x40(%rbp), %r14 testb %r13b, %r13b jne 0x70738 movq %rbx, %rdi xorl %esi, %esi callq 0x428ba testl %r12d, %r12d je 0x70755 cmpl $-0x1, 0x59c(%rbx) je 0x70766 movq %rbx, %rdi movl $0x7f, %esi callq 0x3fda0 jmp 0x70770 cmpb $0x0, (%r14) je 0x70795 orb $-0x7e, 0x624(%rbx) xorl %eax, %eax jmp 0x70777 callq 0xa1c0e cmpl $0x0, (%rax) je 0x70746 callq 0xa1c0e movl (%rax), %eax movq %fs:0x28, %rcx cmpq -0x30(%rbp), %rcx jne 0x707a7 addq $0x18, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq callq 0xa1c0e movl $0x86, (%rax) movl $0x86, %eax jmp 0x70777 callq 0x29250
_ma_read_rnd_static_record: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx sub rsp, 18h mov r15, rdx mov r8, rsi mov rbx, rdi mov rax, fs:28h mov [rbp+var_30], rax mov r13b, 1 test byte ptr [rdi+61Ch], 2 jz short loc_70593 lea rax, [rbx+4C8h] lea rdx, [rbx+4F8h] cmp dword ptr [rbx+568h], 2 mov rsi, [rbx+4B8h] cmovz rax, rdx sub rsi, [rbx+4E0h] add rsi, [rax] cmp rsi, r15 jnz short loc_70589 test cl, cl setz al test r15, r15 setnz cl test cl, al jz loc_706A0 loc_70589: mov dword ptr [rbx+598h], 1 loc_70593: xor eax, eax mov r12b, 1 loc_70598: mov r14, [rbx] cmp dword ptr [rbx+664h], 2 jnz short loc_705E7 mov rcx, [rbx+20h] cmp [rcx+28h], r15 jbe short loc_705CA test r12b, r12b jnz short loc_705BC cmp [r14+398h], rax jbe short loc_705E7 loc_705BC: cmp dword ptr [r14+7B8h], 0 setnz r13b jmp short loc_705E7 loc_705CA: mov r13, r8 mov rdi, rbx xor esi, esi xor edx, edx call _ma_readinfo test eax, eax jnz loc_70770 mov r8, r13 xor r13d, r13d loc_705E7: mov rax, [rbx+20h] cmp [rax+28h], r15 jbe short loc_7063D mov [rbx+98h], r15 mov rax, [r14+3A0h] add rax, r15 mov [rbx+0A0h], rax test r12b, r12b jz short loc_70668 mov rax, fs:28h cmp rax, [rbp+var_30] jnz loc_707A7 mov rdi, rbx mov rsi, r8 mov rdx, r15 add rsp, 18h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp jmp _ma_read_static_record loc_7063D: mov rax, [rbx] cmp dword ptr [rax+7B8h], 0 jnz short loc_70653 mov rdi, rbx xor esi, esi call _ma_writeinfo loc_70653: call _my_thread_var mov dword ptr [rax], 89h mov eax, 89h jmp loc_70777 loc_70668: lea r15, [rbx+4B8h] mov r12, [r14+398h] mov rsi, [rbx+4C8h] lea rax, [rsi+r12] cmp rax, [rbx+4D0h] jbe short loc_706B4 mov rdi, r15 mov r14, r8 mov rsi, r8 mov rdx, r12 call _my_b_read mov r12d, eax jmp short loc_706CC loc_706A0: mov eax, [rbx+4D0h] sub eax, [rbx+4C8h] xor r12d, r12d jmp loc_70598 loc_706B4: mov r14, r8 mov rdi, r8 mov rdx, r12 call _memcpy add [rbx+4C8h], r12 xor r12d, r12d loc_706CC: mov rax, [rbx] mov rdx, [rax+3A0h] sub rdx, [rax+398h] jz short loc_70729 test r12d, r12d jnz short loc_70729 mov [rbp+var_40], r14 mov rsi, [rbx+4C8h] lea r14, [rsi+rdx] cmp r14, [rbx+4D0h] jbe short loc_7070D lea rsi, [rbp+var_38] mov rdi, r15 call _my_b_read mov r12d, eax jmp short loc_70725 loc_7070D: lea rdi, [rbp+var_38] mov ecx, 8 call ___memcpy_chk mov [rbx+4C8h], r14 xor r12d, r12d loc_70725: mov r14, [rbp+var_40] loc_70729: test r13b, r13b jnz short loc_70738 mov rdi, rbx xor esi, esi call _ma_writeinfo loc_70738: test r12d, r12d jz short loc_70755 cmp dword ptr [rbx+59Ch], 0FFFFFFFFh jz short loc_70766 loc_70746: mov rdi, rbx mov esi, 7Fh call _ma_set_fatal_error jmp short loc_70770 loc_70755: cmp byte ptr [r14], 0 jz short loc_70795 or byte ptr [rbx+624h], 82h xor eax, eax jmp short loc_70777 loc_70766: call _my_thread_var cmp dword ptr [rax], 0 jz short loc_70746 loc_70770: call _my_thread_var mov eax, [rax] loc_70777: mov rcx, fs:28h cmp rcx, [rbp+var_30] jnz short loc_707A7 add rsp, 18h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn loc_70795: call _my_thread_var mov dword ptr [rax], 86h mov eax, 86h jmp short loc_70777 loc_707A7: call ___stack_chk_fail
long long ma_read_rnd_static_record(_BYTE *a1, _BYTE *a2, unsigned long long a3, char a4) { _BYTE *v5; // r8 _QWORD *v6; // rbx bool v7; // r13 _QWORD *v8; // rax unsigned long long v9; // rax char v10; // r12 long long v11; // r14 long long v13; // r12 long long v14; // rsi _BYTE *v15; // r14 long long v16; // rcx long long v17; // r8 int v18; // r9d int v19; // r12d long long v20; // rdx long long v21; // rsi long long v22; // r14 _BYTE *v23; // [rsp+0h] [rbp-40h] _BYTE v24[8]; // [rsp+8h] [rbp-38h] BYREF unsigned long long v25; // [rsp+10h] [rbp-30h] v5 = a2; v6 = a1; v25 = __readfsqword(0x28u); v7 = 1; if ( (a1[1564] & 2) == 0 ) goto LABEL_7; v8 = a1 + 1224; if ( *((_DWORD *)a1 + 346) == 2 ) v8 = a1 + 1272; if ( *v8 + *((_QWORD *)a1 + 151) - *((_QWORD *)a1 + 156) != a3 || a4 == 0 && a3 != 0 ) { *((_DWORD *)a1 + 358) = 1; LABEL_7: v9 = 0LL; v10 = 1; goto LABEL_8; } v9 = (unsigned int)(*((_DWORD *)a1 + 308) - *((_DWORD *)a1 + 306)); v10 = 0; LABEL_8: v11 = *(_QWORD *)a1; if ( *((_DWORD *)a1 + 409) == 2 ) { if ( *(_QWORD *)(*((_QWORD *)a1 + 4) + 40LL) <= a3 ) { if ( (unsigned int)ma_readinfo() ) return *(unsigned int *)my_thread_var(a1); v5 = a2; v7 = 0; } else if ( v10 || *(_QWORD *)(v11 + 920) > v9 ) { v7 = *(_DWORD *)(v11 + 1976) != 0; } } if ( *(_QWORD *)(*((_QWORD *)a1 + 4) + 40LL) <= a3 ) { if ( !*(_DWORD *)(*(_QWORD *)a1 + 1976LL) ) ma_writeinfo((long long *)a1, 0); *(_DWORD *)my_thread_var(a1) = 137; return 137LL; } else { *((_QWORD *)a1 + 19) = a3; *((_QWORD *)a1 + 20) = a3 + *(_QWORD *)(v11 + 928); if ( v10 ) return ma_read_static_record((long long)a1, v5, a3); v13 = *(_QWORD *)(v11 + 920); v14 = *((_QWORD *)a1 + 153); if ( (unsigned long long)(v14 + v13) <= *((_QWORD *)a1 + 154) ) { v15 = v5; a1 = v5; memcpy(v5, v14, v13); v6[153] += v13; v19 = 0; } else { a1 += 1208; v15 = v5; v19 = my_b_read(a1, v5, v13); } v20 = *(_QWORD *)(*v6 + 928LL) - *(_QWORD *)(*v6 + 920LL); if ( v20 && !v19 ) { v23 = v15; v21 = v6[153]; v22 = v21 + v20; if ( (unsigned long long)(v21 + v20) <= v6[154] ) { a1 = v24; __memcpy_chk(v24, v21, v20, 8LL); v6[153] = v22; v19 = 0; } else { a1 = v6 + 151; v19 = my_b_read(v6 + 151, v24, v20); } v15 = v23; } if ( !v7 ) { a1 = v6; ma_writeinfo(v6, 0); } if ( v19 ) { if ( *((_DWORD *)v6 + 359) != -1 || !*(_DWORD *)my_thread_var(a1) ) { a1 = v6; ma_set_fatal_error(v6, 127, v20, v16, v17, v18); } return *(unsigned int *)my_thread_var(a1); } if ( *v15 ) { *((_BYTE *)v6 + 1572) |= 0x82u; return 0LL; } else { *(_DWORD *)my_thread_var(a1) = 134; return 134LL; } } }
_ma_read_rnd_static_record: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x18 MOV R15,RDX MOV R8,RSI MOV RBX,RDI MOV RAX,qword ptr FS:[0x28] MOV qword ptr [RBP + -0x30],RAX MOV R13B,0x1 TEST byte ptr [RDI + 0x61c],0x2 JZ 0x00170593 LEA RAX,[RBX + 0x4c8] LEA RDX,[RBX + 0x4f8] CMP dword ptr [RBX + 0x568],0x2 MOV RSI,qword ptr [RBX + 0x4b8] CMOVZ RAX,RDX SUB RSI,qword ptr [RBX + 0x4e0] ADD RSI,qword ptr [RAX] CMP RSI,R15 JNZ 0x00170589 TEST CL,CL SETZ AL TEST R15,R15 SETNZ CL TEST CL,AL JZ 0x001706a0 LAB_00170589: MOV dword ptr [RBX + 0x598],0x1 LAB_00170593: XOR EAX,EAX MOV R12B,0x1 LAB_00170598: MOV R14,qword ptr [RBX] CMP dword ptr [RBX + 0x664],0x2 JNZ 0x001705e7 MOV RCX,qword ptr [RBX + 0x20] CMP qword ptr [RCX + 0x28],R15 JBE 0x001705ca TEST R12B,R12B JNZ 0x001705bc CMP qword ptr [R14 + 0x398],RAX JBE 0x001705e7 LAB_001705bc: CMP dword ptr [R14 + 0x7b8],0x0 SETNZ R13B JMP 0x001705e7 LAB_001705ca: MOV R13,R8 MOV RDI,RBX XOR ESI,ESI XOR EDX,EDX CALL 0x001428b2 TEST EAX,EAX JNZ 0x00170770 MOV R8,R13 XOR R13D,R13D LAB_001705e7: MOV RAX,qword ptr [RBX + 0x20] CMP qword ptr [RAX + 0x28],R15 JBE 0x0017063d MOV qword ptr [RBX + 0x98],R15 MOV RAX,qword ptr [R14 + 0x3a0] ADD RAX,R15 MOV qword ptr [RBX + 0xa0],RAX TEST R12B,R12B JZ 0x00170668 MOV RAX,qword ptr FS:[0x28] CMP RAX,qword ptr [RBP + -0x30] JNZ 0x001707a7 MOV RDI,RBX MOV RSI,R8 MOV RDX,R15 ADD RSP,0x18 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP JMP 0x00170446 LAB_0017063d: MOV RAX,qword ptr [RBX] CMP dword ptr [RAX + 0x7b8],0x0 JNZ 0x00170653 MOV RDI,RBX XOR ESI,ESI CALL 0x001428ba LAB_00170653: CALL 0x001a1c0e MOV dword ptr [RAX],0x89 MOV EAX,0x89 JMP 0x00170777 LAB_00170668: LEA R15,[RBX + 0x4b8] MOV R12,qword ptr [R14 + 0x398] MOV RSI,qword ptr [RBX + 0x4c8] LEA RAX,[RSI + R12*0x1] CMP RAX,qword ptr [RBX + 0x4d0] JBE 0x001706b4 MOV RDI,R15 MOV R14,R8 MOV RSI,R8 MOV RDX,R12 CALL 0x0019570a MOV R12D,EAX JMP 0x001706cc LAB_001706a0: MOV EAX,dword ptr [RBX + 0x4d0] SUB EAX,dword ptr [RBX + 0x4c8] XOR R12D,R12D JMP 0x00170598 LAB_001706b4: MOV R14,R8 MOV RDI,R8 MOV RDX,R12 CALL 0x00129080 ADD qword ptr [RBX + 0x4c8],R12 XOR R12D,R12D LAB_001706cc: MOV RAX,qword ptr [RBX] MOV RDX,qword ptr [RAX + 0x3a0] SUB RDX,qword ptr [RAX + 0x398] JZ 0x00170729 TEST R12D,R12D JNZ 0x00170729 MOV qword ptr [RBP + -0x40],R14 MOV RSI,qword ptr [RBX + 0x4c8] LEA R14,[RSI + RDX*0x1] CMP R14,qword ptr [RBX + 0x4d0] JBE 0x0017070d LEA RSI,[RBP + -0x38] MOV RDI,R15 CALL 0x0019570a MOV R12D,EAX JMP 0x00170725 LAB_0017070d: LEA RDI,[RBP + -0x38] MOV ECX,0x8 CALL 0x00129410 MOV qword ptr [RBX + 0x4c8],R14 XOR R12D,R12D LAB_00170725: MOV R14,qword ptr [RBP + -0x40] LAB_00170729: TEST R13B,R13B JNZ 0x00170738 MOV RDI,RBX XOR ESI,ESI CALL 0x001428ba LAB_00170738: TEST R12D,R12D JZ 0x00170755 CMP dword ptr [RBX + 0x59c],-0x1 JZ 0x00170766 LAB_00170746: MOV RDI,RBX MOV ESI,0x7f CALL 0x0013fda0 JMP 0x00170770 LAB_00170755: CMP byte ptr [R14],0x0 JZ 0x00170795 OR byte ptr [RBX + 0x624],0x82 XOR EAX,EAX JMP 0x00170777 LAB_00170766: CALL 0x001a1c0e CMP dword ptr [RAX],0x0 JZ 0x00170746 LAB_00170770: CALL 0x001a1c0e MOV EAX,dword ptr [RAX] LAB_00170777: MOV RCX,qword ptr FS:[0x28] CMP RCX,qword ptr [RBP + -0x30] JNZ 0x001707a7 ADD RSP,0x18 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET LAB_00170795: CALL 0x001a1c0e MOV dword ptr [RAX],0x86 MOV EAX,0x86 JMP 0x00170777 LAB_001707a7: CALL 0x00129250
ulong _ma_read_rnd_static_record(long *param_1,char *param_2,ulong param_3,char param_4) { size_t __n; bool bVar1; int iVar2; long *plVar3; ulong uVar4; int *piVar5; uint *puVar6; int4 *puVar7; long lVar8; long in_FS_OFFSET; bool bVar9; int1 local_40 [8]; long local_38; local_38 = *(long *)(in_FS_OFFSET + 0x28); bVar9 = true; if ((*(byte *)((long)param_1 + 0x61c) & 2) == 0) { LAB_00170593: uVar4 = 0; bVar1 = true; } else { plVar3 = param_1 + 0x99; if ((int)param_1[0xad] == 2) { plVar3 = param_1 + 0x9f; } if (((param_1[0x97] - param_1[0x9c]) + *plVar3 != param_3) || (param_3 != 0 && param_4 == '\0')) { *(int4 *)(param_1 + 0xb3) = 1; goto LAB_00170593; } uVar4 = (ulong)(uint)((int)param_1[0x9a] - (int)param_1[0x99]); bVar1 = false; } lVar8 = *param_1; if (*(int *)((long)param_1 + 0x664) == 2) { if (param_3 < *(ulong *)(param_1[4] + 0x28)) { if ((bVar1) || (uVar4 < *(ulong *)(lVar8 + 0x398))) { bVar9 = *(int *)(lVar8 + 0x7b8) != 0; } goto LAB_001705e7; } iVar2 = _ma_readinfo(param_1,0,0); if (iVar2 == 0) { bVar9 = false; goto LAB_001705e7; } LAB_00170770: puVar6 = (uint *)_my_thread_var(); uVar4 = (ulong)*puVar6; } else { LAB_001705e7: if (param_3 < *(ulong *)(param_1[4] + 0x28)) { param_1[0x13] = param_3; param_1[0x14] = *(long *)(lVar8 + 0x3a0) + param_3; if (bVar1) { if (*(long *)(in_FS_OFFSET + 0x28) == local_38) { uVar4 = _ma_read_static_record(param_1,param_2,param_3); return uVar4; } goto LAB_001707a7; } __n = *(size_t *)(lVar8 + 0x398); if ((ulong)param_1[0x9a] < param_1[0x99] + __n) { iVar2 = _my_b_read(param_1 + 0x97,param_2,__n); } else { memcpy(param_2,(void *)param_1[0x99],__n); param_1[0x99] = param_1[0x99] + __n; iVar2 = 0; } lVar8 = *(long *)(*param_1 + 0x3a0) - *(long *)(*param_1 + 0x398); if ((lVar8 != 0) && (iVar2 == 0)) { uVar4 = param_1[0x99] + lVar8; if ((ulong)param_1[0x9a] < uVar4) { iVar2 = _my_b_read(param_1 + 0x97,local_40); } else { __memcpy_chk(local_40,param_1[0x99],lVar8,8); param_1[0x99] = uVar4; iVar2 = 0; } } if (!bVar9) { _ma_writeinfo(param_1,0); } if (iVar2 != 0) { if ((*(int *)((long)param_1 + 0x59c) != -1) || (piVar5 = (int *)_my_thread_var(), *piVar5 == 0)) { _ma_set_fatal_error(param_1,0x7f); } goto LAB_00170770; } if (*param_2 == '\0') { puVar7 = (int4 *)_my_thread_var(); *puVar7 = 0x86; uVar4 = 0x86; } else { *(byte *)((long)param_1 + 0x624) = *(byte *)((long)param_1 + 0x624) | 0x82; uVar4 = 0; } } else { if (*(int *)(*param_1 + 0x7b8) == 0) { _ma_writeinfo(param_1,0); } puVar7 = (int4 *)_my_thread_var(); *puVar7 = 0x89; uVar4 = 0x89; } } if (*(long *)(in_FS_OFFSET + 0x28) == local_38) { return uVar4; } LAB_001707a7: /* WARNING: Subroutine does not return */ __stack_chk_fail(); }
31,869
LefDefParser::lefwMaximumDensity(double)
Efficient-TDP/thirdparty/Limbo/limbo/thirdparty/lefdef/5.8/lef/lef/lefwWriter.cpp
int lefwMaximumDensity(double maxDensity) { lefw54Num = LEFW_MAXIMUMDENSITY; if (!lefwFile) return LEFW_UNINITIALIZED; if (versionNum < 5.4) return LEFW_WRONG_VERSION; if (lefwWriteEncrypt) encPrint(lefwFile, (char*) " MAXIMUMDENSITY %.11g ;\n", maxDensity); else fprintf(lefwFile, " MAXIMUMDENSITY %.11g ;\n", maxDensity); lefwLines++; return LEFW_OK; }
O0
cpp
LefDefParser::lefwMaximumDensity(double): subq $0x18, %rsp movsd %xmm0, 0x8(%rsp) movl $0x84, 0x1c9f8(%rip) # 0x32d4c leaq 0x1caa5(%rip), %rax # 0x32e00 cmpq $0x0, (%rax) jne 0x1636e movl $0x1, 0x14(%rsp) jmp 0x163ee movsd 0x12e8a(%rip), %xmm0 # 0x29200 ucomisd 0x1c9c2(%rip), %xmm0 # 0x32d40 jbe 0x1638a movl $0x5, 0x14(%rsp) jmp 0x163ee cmpl $0x0, 0x1cd5b(%rip) # 0x330ec je 0x163b3 leaq 0x1ca66(%rip), %rax # 0x32e00 movq (%rax), %rdi movsd 0x8(%rsp), %xmm0 leaq 0x1496b(%rip), %rsi # 0x2ad15 movb $0x1, %al callq 0x289b0 jmp 0x163d1 leaq 0x1ca46(%rip), %rax # 0x32e00 movq (%rax), %rdi movsd 0x8(%rsp), %xmm0 leaq 0x1494b(%rip), %rsi # 0x2ad15 movb $0x1, %al callq 0x1100 leaq 0x1cc74(%rip), %rax # 0x3304c movl (%rax), %ecx addl $0x1, %ecx leaq 0x1cc68(%rip), %rax # 0x3304c movl %ecx, (%rax) movl $0x0, 0x14(%rsp) movl 0x14(%rsp), %eax addq $0x18, %rsp retq nopw (%rax,%rax)
_ZN12LefDefParser18lefwMaximumDensityEd: sub rsp, 18h movsd [rsp+18h+var_10], xmm0 mov cs:_ZN12LefDefParserL9lefw54NumE, 84h; LefDefParser::lefw54Num lea rax, _ZN12LefDefParser8lefwFileE; LefDefParser::lefwFile cmp qword ptr [rax], 0 jnz short loc_1636E mov [rsp+18h+var_4], 1 jmp loc_163EE loc_1636E: movsd xmm0, cs:dbl_29200 ucomisd xmm0, cs:_ZN12LefDefParserL10versionNumE; LefDefParser::versionNum jbe short loc_1638A mov [rsp+18h+var_4], 5 jmp short loc_163EE loc_1638A: cmp cs:_ZN12LefDefParserL16lefwWriteEncryptE, 0; LefDefParser::lefwWriteEncrypt jz short loc_163B3 lea rax, _ZN12LefDefParser8lefwFileE; LefDefParser::lefwFile mov rdi, [rax] movsd xmm0, [rsp+18h+var_10] lea rsi, aMaximumdensity; " MAXIMUMDENSITY %.11g ;\n" mov al, 1 call _ZN12LefDefParser8encPrintEP8_IO_FILEPcz; LefDefParser::encPrint(_IO_FILE *,char *,...) jmp short loc_163D1 loc_163B3: lea rax, _ZN12LefDefParser8lefwFileE; LefDefParser::lefwFile mov rdi, [rax] movsd xmm0, [rsp+18h+var_10] lea rsi, aMaximumdensity; " MAXIMUMDENSITY %.11g ;\n" mov al, 1 call _fprintf loc_163D1: lea rax, _ZN12LefDefParser9lefwLinesE; LefDefParser::lefwLines mov ecx, [rax] add ecx, 1 lea rax, _ZN12LefDefParser9lefwLinesE; LefDefParser::lefwLines mov [rax], ecx mov [rsp+18h+var_4], 0 loc_163EE: mov eax, [rsp+18h+var_4] add rsp, 18h retn
long long LefDefParser::lefwMaximumDensity( LefDefParser *this, double a2, long long a3, int a4, int a5, int a6, int a7) { LefDefParser::lefw54Num = 132; if ( *(_QWORD *)&LefDefParser::lefwFile ) { if ( *(double *)&LefDefParser::versionNum >= 5.4 ) { if ( LefDefParser::lefwWriteEncrypt ) LefDefParser::encPrint(LefDefParser::lefwFile, (unsigned int)" MAXIMUMDENSITY %.11g ;\n", a4, a5, a6, a7); else fprintf(*(_QWORD *)&LefDefParser::lefwFile, " MAXIMUMDENSITY %.11g ;\n", a2); ++LefDefParser::lefwLines; return 0; } else { return 5; } } else { return 1; } }
lefwMaximumDensity: SUB RSP,0x18 MOVSD qword ptr [RSP + 0x8],XMM0 MOV dword ptr [0x00132d4c],0x84 LEA RAX,[0x132e00] CMP qword ptr [RAX],0x0 JNZ 0x0011636e MOV dword ptr [RSP + 0x14],0x1 JMP 0x001163ee LAB_0011636e: MOVSD XMM0,qword ptr [0x00129200] UCOMISD XMM0,qword ptr [0x00132d40] JBE 0x0011638a MOV dword ptr [RSP + 0x14],0x5 JMP 0x001163ee LAB_0011638a: CMP dword ptr [0x001330ec],0x0 JZ 0x001163b3 LEA RAX,[0x132e00] MOV RDI,qword ptr [RAX] MOVSD XMM0,qword ptr [RSP + 0x8] LEA RSI,[0x12ad15] MOV AL,0x1 CALL 0x001289b0 JMP 0x001163d1 LAB_001163b3: LEA RAX,[0x132e00] MOV RDI,qword ptr [RAX] MOVSD XMM0,qword ptr [RSP + 0x8] LEA RSI,[0x12ad15] MOV AL,0x1 CALL 0x00101100 LAB_001163d1: LEA RAX,[0x13304c] MOV ECX,dword ptr [RAX] ADD ECX,0x1 LEA RAX,[0x13304c] MOV dword ptr [RAX],ECX MOV dword ptr [RSP + 0x14],0x0 LAB_001163ee: MOV EAX,dword ptr [RSP + 0x14] ADD RSP,0x18 RET
/* LefDefParser::lefwMaximumDensity(double) */ int4 LefDefParser::lefwMaximumDensity(double param_1) { int4 local_4; lefw54Num = 0x84; if (lefwFile == (_IO_FILE *)0x0) { local_4 = 1; } else if (DAT_00129200 <= versionNum) { if (lefwWriteEncrypt == 0) { fprintf(lefwFile," MAXIMUMDENSITY %.11g ;\n",param_1); } else { encPrint(lefwFile," MAXIMUMDENSITY %.11g ;\n",param_1); } lefwLines = lefwLines + 1; local_4 = 0; } else { local_4 = 5; } return local_4; }
31,870
testing::internal::SuiteApiResolver<alaya::RawSpaceTest>::GetSetUpCaseOrSuite(char const*, int)
AlayaLite/build_O0/_deps/googletest-src/googletest/include/gtest/internal/gtest-internal.h
static SetUpTearDownSuiteFuncType GetSetUpCaseOrSuite(const char* filename, int line_num) { #ifndef GTEST_REMOVE_LEGACY_TEST_CASEAPI_ SetUpTearDownSuiteFuncType test_case_fp = GetNotDefaultOrNull(&T::SetUpTestCase, &Test::SetUpTestCase); SetUpTearDownSuiteFuncType test_suite_fp = GetNotDefaultOrNull(&T::SetUpTestSuite, &Test::SetUpTestSuite); GTEST_CHECK_(!test_case_fp || !test_suite_fp) << "Test can not provide both SetUpTestSuite and SetUpTestCase, please " "make sure there is only one present at " << filename << ":" << line_num; return test_case_fp != nullptr ? test_case_fp : test_suite_fp; #else (void)(filename); (void)(line_num); return &T::SetUpTestSuite; #endif }
O0
c
testing::internal::SuiteApiResolver<alaya::RawSpaceTest>::GetSetUpCaseOrSuite(char const*, int): subq $0x68, %rsp movq %rdi, 0x60(%rsp) movl %esi, 0x5c(%rsp) leaq -0xc6994(%rip), %rsi # 0x20a70 movq %rsi, %rdi callq 0x20a40 movq %rax, 0x50(%rsp) leaq -0xc6998(%rip), %rsi # 0x20a80 movq %rsi, %rdi callq 0x20a40 movq %rax, 0x48(%rsp) movb $0x1, %al cmpq $0x0, 0x50(%rsp) movb %al, 0x33(%rsp) je 0xe7442 cmpq $0x0, 0x48(%rsp) setne %al xorb $-0x1, %al movb %al, 0x33(%rsp) movb 0x33(%rsp), %al movzbl %al, %edi andl $0x1, %edi callq 0xbc040 testb $0x1, %al jne 0xe7457 jmp 0xe745c jmp 0xe7518 leaq 0x2dec2(%rip), %rdx # 0x115325 leaq 0x44(%rsp), %rdi movq %rdi, 0x20(%rsp) movl $0x3, %esi movl $0x201, %ecx # imm = 0x201 callq 0xc17d0 movq 0x20(%rsp), %rdi callq 0x20a90 movq %rax, %rdi leaq 0x2df11(%rip), %rsi # 0x1153a1 callq 0x166e0 movq %rax, 0x28(%rsp) jmp 0xe749c movq 0x28(%rsp), %rdi leaq 0x2df2c(%rip), %rsi # 0x1153d4 callq 0x166e0 movq %rax, 0x18(%rsp) jmp 0xe74b4 movq 0x18(%rsp), %rdi movq 0x60(%rsp), %rsi callq 0x166e0 movq %rax, 0x10(%rsp) jmp 0xe74ca movq 0x10(%rsp), %rdi leaq 0x2ec6f(%rip), %rsi # 0x116145 callq 0x166e0 movq %rax, 0x8(%rsp) jmp 0xe74e2 movq 0x8(%rsp), %rdi movl 0x5c(%rsp), %esi callq 0x16cc0 jmp 0xe74f2 leaq 0x44(%rsp), %rdi callq 0xc1940 jmp 0xe7518 movq %rax, %rcx movl %edx, %eax movq %rcx, 0x38(%rsp) movl %eax, 0x34(%rsp) leaq 0x44(%rsp), %rdi callq 0xc1940 jmp 0xe753d cmpq $0x0, 0x50(%rsp) je 0xe752b movq 0x50(%rsp), %rax movq %rax, (%rsp) jmp 0xe7534 movq 0x48(%rsp), %rax movq %rax, (%rsp) movq (%rsp), %rax addq $0x68, %rsp retq movq 0x38(%rsp), %rdi callq 0x16cf0 nopw (%rax,%rax)
_ZN7testing8internal16SuiteApiResolverINS0_12_GLOBAL__N_111FailureTestEE19GetSetUpCaseOrSuiteEPKci: sub rsp, 68h mov [rsp+68h+var_8], rdi mov [rsp+68h+var_C], esi lea rsi, _ZN7testing4Test13SetUpTestCaseEv; void (*)(void) mov rdi, rsi; this call _ZN7testing8internal19GetNotDefaultOrNullEPFvvES2_; testing::internal::GetNotDefaultOrNull(void (*)(void),void (*)(void)) mov [rsp+68h+var_18], rax lea rsi, _ZN7testing4Test14SetUpTestSuiteEv; bool mov rdi, rsi; this call _ZN7testing8internal19GetNotDefaultOrNullEPFvvES2_; testing::internal::GetNotDefaultOrNull(void (*)(void),void (*)(void)) mov qword ptr [rsp+68h+var_20], rax; char mov al, 1 cmp [rsp+68h+var_18], 0 mov [rsp+68h+var_35], al jz short loc_E7442 cmp qword ptr [rsp+68h+var_20], 0 setnz al xor al, 0FFh mov [rsp+68h+var_35], al loc_E7442: mov al, [rsp+68h+var_35] movzx edi, al and edi, 1; this call _ZN7testing8internal6IsTrueEb; testing::internal::IsTrue(bool) test al, 1 jnz short loc_E7457 jmp short loc_E745C loc_E7457: jmp loc_E7518 loc_E745C: lea rdx, aWorkspaceLlm4b_4; "/workspace/llm4binary/github2025/AlayaL"... lea rdi, [rsp+68h+var_24]; int mov [rsp+68h+var_48], rdi; int mov esi, 3 mov ecx, 201h call _ZN7testing8internal8GTestLogC2ENS0_16GTestLogSeverityEPKci; testing::internal::GTestLog::GTestLog(testing::internal::GTestLogSeverity,char const*,int) mov rdi, [rsp+68h+var_48]; this call _ZN7testing8internal8GTestLog9GetStreamEv; testing::internal::GTestLog::GetStream(void) mov rdi, rax lea rsi, aConditionTestC; "Condition !test_case_fp || !test_suite_"... call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*) mov [rsp+68h+var_40], rax jmp short $+2 loc_E749C: mov rdi, [rsp+68h+var_40] lea rsi, aTestCanNotProv; "Test can not provide both SetUpTestSuit"... call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*) mov [rsp+68h+var_50], rax jmp short $+2 loc_E74B4: mov rdi, [rsp+68h+var_50] mov rsi, [rsp+68h+var_8] call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*) mov [rsp+68h+var_58], rax jmp short $+2 loc_E74CA: mov rdi, [rsp+68h+var_58] lea rsi, asc_116144+1; ":" call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*) mov [rsp+68h+var_60], rax jmp short $+2 loc_E74E2: mov rdi, [rsp+68h+var_60] mov esi, [rsp+68h+var_C] call __ZNSolsEi; std::ostream::operator<<(int) jmp short $+2 loc_E74F2: lea rdi, [rsp+68h+var_24]; this call _ZN7testing8internal8GTestLogD2Ev; testing::internal::GTestLog::~GTestLog() jmp short loc_E7518 mov rcx, rax mov eax, edx mov [rsp+arg_30], rcx mov [rsp+arg_2C], eax lea rdi, [rsp+arg_3C]; this call _ZN7testing8internal8GTestLogD2Ev; testing::internal::GTestLog::~GTestLog() jmp short loc_E753D loc_E7518: cmp [rsp+68h+var_18], 0 jz short loc_E752B mov rax, [rsp+68h+var_18] mov [rsp+68h+var_68], rax jmp short loc_E7534 loc_E752B: mov rax, qword ptr [rsp+68h+var_20] mov [rsp+68h+var_68], rax loc_E7534: mov rax, [rsp+68h+var_68] add rsp, 68h retn loc_E753D: mov rdi, [rsp+arg_30] call __Unwind_Resume
testing::internal * testing::internal::SuiteApiResolver<testing::internal::`anonymous namespace'::FailureTest>::GetSetUpCaseOrSuite( long long a1, unsigned int a2, void (*a3)(void)) { void (*v3)(void); // rdx void *Stream; // rax long long v7; // [rsp+8h] [rbp-60h] long long v8; // [rsp+10h] [rbp-58h] long long v9; // [rsp+18h] [rbp-50h] long long v10; // [rsp+28h] [rbp-40h] char v11; // [rsp+33h] [rbp-35h] int v12; // [rsp+44h] [rbp-24h] BYREF char v13[8]; // [rsp+48h] [rbp-20h] testing::internal *NotDefaultOrNull; // [rsp+50h] [rbp-18h] unsigned int v15; // [rsp+5Ch] [rbp-Ch] long long v16; // [rsp+60h] [rbp-8h] v16 = a1; v15 = a2; NotDefaultOrNull = testing::internal::GetNotDefaultOrNull( (testing::internal *)testing::Test::SetUpTestCase, (testing::internal *)testing::Test::SetUpTestCase, a3); *(_QWORD *)v13 = testing::internal::GetNotDefaultOrNull( (testing::internal *)testing::Test::SetUpTestSuite, (testing::internal *)testing::Test::SetUpTestSuite, v3); v11 = 1; if ( NotDefaultOrNull ) v11 = ~(*(_QWORD *)v13 != 0LL); if ( (testing::internal::IsTrue((testing::internal *)(v11 & 1)) & 1) == 0 ) { testing::internal::GTestLog::GTestLog( (testing::internal::GTestLog *)&v12, 3, (long long)"/workspace/llm4binary/github2025/AlayaLite/build_O0/_deps/googletest-src/googletest/include/gtest/interna" "l/gtest-internal.h", 513); Stream = testing::internal::GTestLog::GetStream((testing::internal::GTestLog *)&v12); v10 = std::operator<<<std::char_traits<char>>(Stream, "Condition !test_case_fp || !test_suite_fp failed. "); v9 = std::operator<<<std::char_traits<char>>( v10, "Test can not provide both SetUpTestSuite and SetUpTestCase, please make sure there is only one present at "); v8 = std::operator<<<std::char_traits<char>>(v9, v16); v7 = std::operator<<<std::char_traits<char>>(v8, ":"); std::ostream::operator<<(v7, v15); testing::internal::GTestLog::~GTestLog((testing::internal::GTestLog *)&v12); } if ( NotDefaultOrNull ) return NotDefaultOrNull; else return *(testing::internal **)v13; }
GetSetUpCaseOrSuite: SUB RSP,0x68 MOV qword ptr [RSP + 0x60],RDI MOV dword ptr [RSP + 0x5c],ESI LEA RSI,[0x120a70] MOV RDI,RSI CALL 0x00120a40 MOV qword ptr [RSP + 0x50],RAX LEA RSI,[0x120a80] MOV RDI,RSI CALL 0x00120a40 MOV qword ptr [RSP + 0x48],RAX MOV AL,0x1 CMP qword ptr [RSP + 0x50],0x0 MOV byte ptr [RSP + 0x33],AL JZ 0x001e7442 CMP qword ptr [RSP + 0x48],0x0 SETNZ AL XOR AL,0xff MOV byte ptr [RSP + 0x33],AL LAB_001e7442: MOV AL,byte ptr [RSP + 0x33] MOVZX EDI,AL AND EDI,0x1 CALL 0x001bc040 TEST AL,0x1 JNZ 0x001e7457 JMP 0x001e745c LAB_001e7457: JMP 0x001e7518 LAB_001e745c: LEA RDX,[0x215325] LEA RDI,[RSP + 0x44] MOV qword ptr [RSP + 0x20],RDI MOV ESI,0x3 MOV ECX,0x201 CALL 0x001c17d0 MOV RDI,qword ptr [RSP + 0x20] CALL 0x00120a90 MOV RDI,RAX LAB_001e7489: LEA RSI,[0x2153a1] CALL 0x001166e0 MOV qword ptr [RSP + 0x28],RAX JMP 0x001e749c LAB_001e749c: MOV RDI,qword ptr [RSP + 0x28] LEA RSI,[0x2153d4] CALL 0x001166e0 MOV qword ptr [RSP + 0x18],RAX JMP 0x001e74b4 LAB_001e74b4: MOV RDI,qword ptr [RSP + 0x18] MOV RSI,qword ptr [RSP + 0x60] CALL 0x001166e0 MOV qword ptr [RSP + 0x10],RAX JMP 0x001e74ca LAB_001e74ca: MOV RDI,qword ptr [RSP + 0x10] LEA RSI,[0x216145] CALL 0x001166e0 MOV qword ptr [RSP + 0x8],RAX JMP 0x001e74e2 LAB_001e74e2: MOV RDI,qword ptr [RSP + 0x8] MOV ESI,dword ptr [RSP + 0x5c] CALL 0x00116cc0 LAB_001e74f0: JMP 0x001e74f2 LAB_001e74f2: LEA RDI,[RSP + 0x44] CALL 0x001c1940 JMP 0x001e7518 LAB_001e7518: CMP qword ptr [RSP + 0x50],0x0 JZ 0x001e752b MOV RAX,qword ptr [RSP + 0x50] MOV qword ptr [RSP],RAX JMP 0x001e7534 LAB_001e752b: MOV RAX,qword ptr [RSP + 0x48] MOV qword ptr [RSP],RAX LAB_001e7534: MOV RAX,qword ptr [RSP] ADD RSP,0x68 RET
/* testing::internal::SuiteApiResolver<testing::internal::(anonymous namespace)::FailureTest>::GetSetUpCaseOrSuite(char const*, int) */ long testing::internal::SuiteApiResolver<testing::internal::(anonymous_namespace)::FailureTest>:: GetSetUpCaseOrSuite(char *param_1,int param_2) { ulong uVar1; ostream *poVar2; long local_68; byte local_35; GTestLog local_24 [4]; long local_20; long local_18; int local_c; char *local_8; local_c = param_2; local_8 = param_1; local_18 = GetNotDefaultOrNull(Test::SetUpTestCase,Test::SetUpTestCase); local_20 = GetNotDefaultOrNull(Test::SetUpTestSuite,Test::SetUpTestSuite); local_35 = 1; if (local_18 != 0) { local_35 = local_20 != 0 ^ 0xff; } uVar1 = IsTrue((bool)(local_35 & 1)); if ((uVar1 & 1) == 0) { GTestLog::GTestLog(local_24,3, "/workspace/llm4binary/github2025/AlayaLite/build_O0/_deps/googletest-src/googletest/include/gtest/internal/gtest-internal.h" ,0x201); poVar2 = (ostream *)GTestLog::GetStream(); /* try { // try from 001e7489 to 001e74ef has its CatchHandler @ 001e74fe */ poVar2 = std::operator<<(poVar2,"Condition !test_case_fp || !test_suite_fp failed. "); poVar2 = std::operator<<(poVar2, "Test can not provide both SetUpTestSuite and SetUpTestCase, please make sure there is only one present at " ); poVar2 = std::operator<<(poVar2,local_8); poVar2 = std::operator<<(poVar2,":"); std::ostream::operator<<(poVar2,local_c); GTestLog::~GTestLog(local_24); } if (local_18 == 0) { local_68 = local_20; } else { local_68 = local_18; } return local_68; }
31,871
my_error_unregister_all
eloqsql/mysys/my_error.c
void my_error_unregister_all(void) { struct my_err_head *cursor, *saved_next; for (cursor= my_errmsgs_globerrs.meh_next; cursor != NULL; cursor= saved_next) { /* We need this ptr, but we're about to free its container, so save it. */ saved_next= cursor->meh_next; my_free(cursor); } my_errmsgs_globerrs.meh_next= NULL; /* Freed in first iteration above. */ my_errmsgs_list= &my_errmsgs_globerrs; }
O0
c
my_error_unregister_all: pushq %rbp movq %rsp, %rbp subq $0x10, %rsp movq 0x1b0471(%rip), %rax # 0x217470 movq %rax, -0x8(%rbp) cmpq $0x0, -0x8(%rbp) je 0x67028 movq -0x8(%rbp), %rax movq (%rax), %rax movq %rax, -0x10(%rbp) movq -0x8(%rbp), %rdi callq 0x5b4b0 movq -0x10(%rbp), %rax movq %rax, -0x8(%rbp) jmp 0x67003 movq $0x0, 0x1b043d(%rip) # 0x217470 leaq 0x1b0436(%rip), %rax # 0x217470 movq %rax, 0x1b0427(%rip) # 0x217468 addq $0x10, %rsp popq %rbp retq nopw (%rax,%rax)
my_error_unregister_all: push rbp mov rbp, rsp sub rsp, 10h mov rax, cs:my_errmsgs_globerrs mov [rbp+var_8], rax loc_67003: cmp [rbp+var_8], 0 jz short loc_67028 mov rax, [rbp+var_8] mov rax, [rax] mov [rbp+var_10], rax mov rdi, [rbp+var_8] call my_free mov rax, [rbp+var_10] mov [rbp+var_8], rax jmp short loc_67003 loc_67028: mov cs:my_errmsgs_globerrs, 0 lea rax, my_errmsgs_globerrs mov cs:my_errmsgs_list, rax add rsp, 10h pop rbp retn
long long *my_error_unregister_all() { long long *result; // rax _QWORD *v1; // [rsp+0h] [rbp-10h] _QWORD *i; // [rsp+8h] [rbp-8h] for ( i = (_QWORD *)my_errmsgs_globerrs; i; i = v1 ) { v1 = (_QWORD *)*i; my_free((long long)i); } my_errmsgs_globerrs = 0LL; result = &my_errmsgs_globerrs; my_errmsgs_list = &my_errmsgs_globerrs; return result; }
my_error_unregister_all: PUSH RBP MOV RBP,RSP SUB RSP,0x10 MOV RAX,qword ptr [0x00317470] MOV qword ptr [RBP + -0x8],RAX LAB_00167003: CMP qword ptr [RBP + -0x8],0x0 JZ 0x00167028 MOV RAX,qword ptr [RBP + -0x8] MOV RAX,qword ptr [RAX] MOV qword ptr [RBP + -0x10],RAX MOV RDI,qword ptr [RBP + -0x8] CALL 0x0015b4b0 MOV RAX,qword ptr [RBP + -0x10] MOV qword ptr [RBP + -0x8],RAX JMP 0x00167003 LAB_00167028: MOV qword ptr [0x00317470],0x0 LEA RAX,[0x317470] MOV qword ptr [0x00317468],RAX ADD RSP,0x10 POP RBP RET
void my_error_unregister_all(void) { int8 *puVar1; int8 *local_10; local_10 = my_errmsgs_globerrs; while (local_10 != (int8 *)0x0) { puVar1 = (int8 *)*local_10; my_free(local_10); local_10 = puVar1; } my_errmsgs_globerrs = (int8 *)0x0; my_errmsgs_list = (int *)&my_errmsgs_globerrs; return; }
31,872
mz_inflate
7CodeWizard[P]stablediffusion/thirdparty/miniz.h
int mz_inflate(mz_streamp pStream, int flush) { inflate_state *pState; mz_uint n, first_call, decomp_flags = TINFL_FLAG_COMPUTE_ADLER32; size_t in_bytes, out_bytes, orig_avail_in; tinfl_status status; if ((!pStream) || (!pStream->state)) return MZ_STREAM_ERROR; if (flush == MZ_PARTIAL_FLUSH) flush = MZ_SYNC_FLUSH; if ((flush) && (flush != MZ_SYNC_FLUSH) && (flush != MZ_FINISH)) return MZ_STREAM_ERROR; pState = (inflate_state *)pStream->state; if (pState->m_window_bits > 0) decomp_flags |= TINFL_FLAG_PARSE_ZLIB_HEADER; orig_avail_in = pStream->avail_in; first_call = pState->m_first_call; pState->m_first_call = 0; if (pState->m_last_status < 0) return MZ_DATA_ERROR; if (pState->m_has_flushed && (flush != MZ_FINISH)) return MZ_STREAM_ERROR; pState->m_has_flushed |= (flush == MZ_FINISH); if ((flush == MZ_FINISH) && (first_call)) { /* MZ_FINISH on the first call implies that the input and output buffers are * large enough to hold the entire compressed/decompressed file. */ decomp_flags |= TINFL_FLAG_USING_NON_WRAPPING_OUTPUT_BUF; in_bytes = pStream->avail_in; out_bytes = pStream->avail_out; status = tinfl_decompress(&pState->m_decomp, pStream->next_in, &in_bytes, pStream->next_out, pStream->next_out, &out_bytes, decomp_flags); pState->m_last_status = status; pStream->next_in += (mz_uint)in_bytes; pStream->avail_in -= (mz_uint)in_bytes; pStream->total_in += (mz_uint)in_bytes; pStream->adler = tinfl_get_adler32(&pState->m_decomp); pStream->next_out += (mz_uint)out_bytes; pStream->avail_out -= (mz_uint)out_bytes; pStream->total_out += (mz_uint)out_bytes; if (status < 0) return MZ_DATA_ERROR; else if (status != TINFL_STATUS_DONE) { pState->m_last_status = TINFL_STATUS_FAILED; return MZ_BUF_ERROR; } return MZ_STREAM_END; } /* flush != MZ_FINISH then we must assume there's more input. */ if (flush != MZ_FINISH) decomp_flags |= TINFL_FLAG_HAS_MORE_INPUT; if (pState->m_dict_avail) { n = MZ_MIN(pState->m_dict_avail, pStream->avail_out); memcpy(pStream->next_out, pState->m_dict + pState->m_dict_ofs, n); pStream->next_out += n; pStream->avail_out -= n; pStream->total_out += n; pState->m_dict_avail -= n; pState->m_dict_ofs = (pState->m_dict_ofs + n) & (TINFL_LZ_DICT_SIZE - 1); return ((pState->m_last_status == TINFL_STATUS_DONE) && (!pState->m_dict_avail)) ? MZ_STREAM_END : MZ_OK; } for (;;) { in_bytes = pStream->avail_in; out_bytes = TINFL_LZ_DICT_SIZE - pState->m_dict_ofs; status = tinfl_decompress( &pState->m_decomp, pStream->next_in, &in_bytes, pState->m_dict, pState->m_dict + pState->m_dict_ofs, &out_bytes, decomp_flags); pState->m_last_status = status; pStream->next_in += (mz_uint)in_bytes; pStream->avail_in -= (mz_uint)in_bytes; pStream->total_in += (mz_uint)in_bytes; pStream->adler = tinfl_get_adler32(&pState->m_decomp); pState->m_dict_avail = (mz_uint)out_bytes; n = MZ_MIN(pState->m_dict_avail, pStream->avail_out); memcpy(pStream->next_out, pState->m_dict + pState->m_dict_ofs, n); pStream->next_out += n; pStream->avail_out -= n; pStream->total_out += n; pState->m_dict_avail -= n; pState->m_dict_ofs = (pState->m_dict_ofs + n) & (TINFL_LZ_DICT_SIZE - 1); if (status < 0) return MZ_DATA_ERROR; /* Stream is corrupted (there could be some uncompressed data left in the output dictionary - oh well). */ else if ((status == TINFL_STATUS_NEEDS_MORE_INPUT) && (!orig_avail_in)) return MZ_BUF_ERROR; /* Signal caller that we can't make forward progress without supplying more input or by setting flush to MZ_FINISH. */ else if (flush == MZ_FINISH) { /* The output buffer MUST be large to hold the remaining uncompressed data * when flush==MZ_FINISH. */ if (status == TINFL_STATUS_DONE) return pState->m_dict_avail ? MZ_BUF_ERROR : MZ_STREAM_END; /* status here must be TINFL_STATUS_HAS_MORE_OUTPUT, which means there's * at least 1 more byte on the way. If there's no more room left in the * output buffer then something is wrong. */ else if (!pStream->avail_out) return MZ_BUF_ERROR; } else if ((status == TINFL_STATUS_DONE) || (!pStream->avail_in) || (!pStream->avail_out) || (pState->m_dict_avail)) break; } return ((status == TINFL_STATUS_DONE) && (!pState->m_dict_avail)) ? MZ_STREAM_END : MZ_OK; }
O1
c
mz_inflate: movl $0xfffffffe, %eax # imm = 0xFFFFFFFE testq %rdi, %rdi je 0x7f7cb pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x38, %rsp movq %rdi, %r14 movq 0x38(%rdi), %rbx testq %rbx, %rbx je 0x7f7bd cmpl $0x1, %esi movl $0x2, %r13d cmovnel %esi, %r13d cmpl $0x4, %r13d ja 0x7f7bd movl $0x15, %ecx btl %r13d, %ecx jae 0x7f7bd xorl %edx, %edx cmpl $0x0, 0x2b08(%rbx) setg %dil movl 0x8(%r14), %r10d movl 0x2b00(%rbx), %ecx movl $0x0, 0x2b00(%rbx) cmpl $0x0, 0xab0c(%rbx) js 0x7f7b8 cmpl $0x4, %r13d setne %r8b movl 0x2b04(%rbx), %esi testl %esi, %esi setne %r9b testb %r9b, %r8b jne 0x7f7bd movb %dil, %dl orl $0x8, %edx xorl %eax, %eax cmpl $0x4, %r13d sete %al orl %eax, %esi movl %esi, 0x2b04(%rbx) cmpl $0x4, %r13d jne 0x7f604 testl %ecx, %ecx je 0x7f604 orl $0x4, %edx leaq 0x20(%rsp), %r15 movq %r10, (%r15) movl 0x20(%r14), %eax leaq 0x18(%rsp), %r12 movq %rax, (%r12) movq (%r14), %rsi movq 0x18(%r14), %rcx movl %edx, (%rsp) movq %rbx, %rdi movq %r15, %rdx movq %rcx, %r8 movq %r12, %r9 callq 0x7f7e6 movl %eax, %ecx movl %eax, 0xab0c(%rbx) movq (%r15), %rax movl %eax, %edx addq %rdx, (%r14) subl %eax, 0x8(%r14) addq %rdx, 0x10(%r14) movl 0x1c(%rbx), %eax movq %rax, 0x60(%r14) movq (%r12), %rax movl %eax, %edx addq %rdx, 0x18(%r14) subl %eax, 0x20(%r14) addq %rdx, 0x28(%r14) movl $0xfffffffd, %eax # imm = 0xFFFFFFFD testl %ecx, %ecx js 0x7f7bd je 0x7f7cc movl $0xffffffff, 0xab0c(%rbx) # imm = 0xFFFFFFFF movl $0xfffffffb, %eax # imm = 0xFFFFFFFB jmp 0x7f7bd movl %edx, %ecx orl $0x2, %ecx cmpl $0x4, %r13d cmovel %edx, %ecx movl 0x2afc(%rbx), %eax testl %eax, %eax je 0x7f68f movl 0x20(%r14), %r15d cmpl %r15d, %eax cmovbl %eax, %r15d movq 0x18(%r14), %rdi movl 0x2af8(%rbx), %eax leaq (%rbx,%rax), %rsi addq $0x2b0c, %rsi # imm = 0x2B0C movq %r15, %rdx callq 0xa4c0 addq %r15, 0x18(%r14) subl %r15d, 0x20(%r14) addq %r15, 0x28(%r14) movl 0x2afc(%rbx), %ecx movl %ecx, %eax subl %r15d, %eax movl %eax, 0x2afc(%rbx) movl 0x2af8(%rbx), %eax addl %r15d, %eax andl $0x7fff, %eax # imm = 0x7FFF movl %eax, 0x2af8(%rbx) xorl %eax, %eax cmpl $0x0, 0xab0c(%rbx) jne 0x7f7bd xorl %eax, %eax cmpl %r15d, %ecx sete %al jmp 0x7f7bd leaq 0x2b0c(%rbx), %rax movq %rax, 0x30(%rsp) movl %ecx, 0x14(%rsp) movq %r10, 0x28(%rsp) movq 0x30(%rsp), %r15 movl 0x8(%r14), %eax movq %rax, 0x20(%rsp) movl 0x2af8(%rbx), %r8d movl $0x8000, %eax # imm = 0x8000 subl %r8d, %eax movq %rax, 0x18(%rsp) movq (%r14), %rsi addq %r15, %r8 movl %ecx, (%rsp) movq %rbx, %rdi leaq 0x20(%rsp), %rdx movq %r15, %rcx leaq 0x18(%rsp), %r9 callq 0x7f7e6 movl %eax, %r12d movl %eax, 0xab0c(%rbx) movq 0x20(%rsp), %rax movl %eax, %ecx addq %rcx, (%r14) subl %eax, 0x8(%r14) addq %rcx, 0x10(%r14) movl 0x1c(%rbx), %eax movq %rax, 0x60(%r14) movl 0x18(%rsp), %ebp movl %ebp, 0x2afc(%rbx) movl 0x20(%r14), %eax cmpl %ebp, %eax cmovbl %eax, %ebp movq 0x18(%r14), %rdi movl 0x2af8(%rbx), %esi addq %r15, %rsi movq %rbp, %rdx callq 0xa4c0 addq %rbp, 0x18(%r14) movl 0x20(%r14), %edx movl %edx, %eax subl %ebp, %eax movl %eax, 0x20(%r14) addq %rbp, 0x28(%r14) movl 0x2afc(%rbx), %ecx movl %ecx, %eax subl %ebp, %eax movl %eax, 0x2afc(%rbx) movl 0x2af8(%rbx), %eax addl %ebp, %eax andl $0x7fff, %eax # imm = 0x7FFF movl %eax, 0x2af8(%rbx) testl %r12d, %r12d js 0x7f7b8 movl %r12d, %esi xorl $0x1, %esi movl $0xfffffffb, %eax # imm = 0xFFFFFFFB movq 0x28(%rsp), %r10 orl %r10d, %esi je 0x7f7bd cmpl $0x4, %r13d jne 0x7f798 testl %r12d, %r12d je 0x7f7d3 cmpl %ebp, %edx movl 0x14(%rsp), %ecx jne 0x7f6a9 jmp 0x7f7bd xorl %eax, %eax testl %r12d, %r12d je 0x7f7df cmpl $0x0, 0x8(%r14) je 0x7f7bd cmpl %ebp, %edx je 0x7f7bd cmpl %ebp, %ecx movl 0x14(%rsp), %ecx je 0x7f6a9 jmp 0x7f7bd movl $0xfffffffd, %eax # imm = 0xFFFFFFFD addq $0x38, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq movl $0x1, %eax jmp 0x7f7bd cmpl %ebp, %ecx movl $0x1, %ecx cmovel %ecx, %eax jmp 0x7f7bd cmpl %ebp, %ecx jmp 0x7f687
mz_inflate: mov eax, 0FFFFFFFEh test rdi, rdi jz locret_7F7CB push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 38h mov r14, rdi mov rbx, [rdi+38h] test rbx, rbx jz loc_7F7BD cmp esi, 1 mov r13d, 2 cmovnz r13d, esi cmp r13d, 4 ja loc_7F7BD mov ecx, 15h bt ecx, r13d jnb loc_7F7BD xor edx, edx cmp dword ptr [rbx+2B08h], 0 setnle dil mov r10d, [r14+8] mov ecx, [rbx+2B00h] mov dword ptr [rbx+2B00h], 0 cmp dword ptr [rbx+0AB0Ch], 0 js loc_7F7B8 cmp r13d, 4 setnz r8b mov esi, [rbx+2B04h] test esi, esi setnz r9b test r8b, r9b jnz loc_7F7BD mov dl, dil or edx, 8 xor eax, eax cmp r13d, 4 setz al or esi, eax mov [rbx+2B04h], esi cmp r13d, 4 jnz loc_7F604 test ecx, ecx jz loc_7F604 or edx, 4 lea r15, [rsp+68h+var_48] mov [r15], r10 mov eax, [r14+20h] lea r12, [rsp+68h+var_50] mov [r12], rax mov rsi, [r14] mov rcx, [r14+18h] mov [rsp+68h+var_68], edx mov rdi, rbx mov rdx, r15 mov r8, rcx mov r9, r12 call tinfl_decompress mov ecx, eax mov [rbx+0AB0Ch], eax mov rax, [r15] mov edx, eax add [r14], rdx sub [r14+8], eax add [r14+10h], rdx mov eax, [rbx+1Ch] mov [r14+60h], rax mov rax, [r12] mov edx, eax add [r14+18h], rdx sub [r14+20h], eax add [r14+28h], rdx mov eax, 0FFFFFFFDh test ecx, ecx js loc_7F7BD jz loc_7F7CC mov dword ptr [rbx+0AB0Ch], 0FFFFFFFFh mov eax, 0FFFFFFFBh jmp loc_7F7BD loc_7F604: mov ecx, edx or ecx, 2 cmp r13d, 4 cmovz ecx, edx mov eax, [rbx+2AFCh] test eax, eax jz short loc_7F68F mov r15d, [r14+20h] cmp eax, r15d cmovb r15d, eax mov rdi, [r14+18h] mov eax, [rbx+2AF8h] lea rsi, [rbx+rax] add rsi, 2B0Ch mov rdx, r15 call _memcpy add [r14+18h], r15 sub [r14+20h], r15d add [r14+28h], r15 mov ecx, [rbx+2AFCh] mov eax, ecx sub eax, r15d mov [rbx+2AFCh], eax mov eax, [rbx+2AF8h] add eax, r15d and eax, 7FFFh mov [rbx+2AF8h], eax xor eax, eax cmp dword ptr [rbx+0AB0Ch], 0 jnz loc_7F7BD xor eax, eax cmp ecx, r15d loc_7F687: setz al jmp loc_7F7BD loc_7F68F: lea rax, [rbx+2B0Ch] mov [rsp+68h+var_38], rax mov [rsp+68h+var_54], ecx mov [rsp+68h+var_40], r10 mov r15, [rsp+68h+var_38] loc_7F6A9: mov eax, [r14+8] mov [rsp+68h+var_48], rax mov r8d, [rbx+2AF8h] mov eax, 8000h sub eax, r8d mov [rsp+68h+var_50], rax mov rsi, [r14] add r8, r15 mov [rsp+68h+var_68], ecx mov rdi, rbx lea rdx, [rsp+68h+var_48] mov rcx, r15 lea r9, [rsp+68h+var_50] call tinfl_decompress mov r12d, eax mov [rbx+0AB0Ch], eax mov rax, [rsp+68h+var_48] mov ecx, eax add [r14], rcx sub [r14+8], eax add [r14+10h], rcx mov eax, [rbx+1Ch] mov [r14+60h], rax mov ebp, dword ptr [rsp+68h+var_50] mov [rbx+2AFCh], ebp mov eax, [r14+20h] cmp eax, ebp cmovb ebp, eax mov rdi, [r14+18h] mov esi, [rbx+2AF8h] add rsi, r15 mov rdx, rbp call _memcpy add [r14+18h], rbp mov edx, [r14+20h] mov eax, edx sub eax, ebp mov [r14+20h], eax add [r14+28h], rbp mov ecx, [rbx+2AFCh] mov eax, ecx sub eax, ebp mov [rbx+2AFCh], eax mov eax, [rbx+2AF8h] add eax, ebp and eax, 7FFFh mov [rbx+2AF8h], eax test r12d, r12d js short loc_7F7B8 mov esi, r12d xor esi, 1 mov eax, 0FFFFFFFBh mov r10, [rsp+68h+var_40] or esi, r10d jz short loc_7F7BD cmp r13d, 4 jnz short loc_7F798 test r12d, r12d jz short loc_7F7D3 cmp edx, ebp mov ecx, [rsp+68h+var_54] jnz loc_7F6A9 jmp short loc_7F7BD loc_7F798: xor eax, eax test r12d, r12d jz short loc_7F7DF cmp dword ptr [r14+8], 0 jz short loc_7F7BD cmp edx, ebp jz short loc_7F7BD cmp ecx, ebp mov ecx, [rsp+68h+var_54] jz loc_7F6A9 jmp short loc_7F7BD loc_7F7B8: mov eax, 0FFFFFFFDh loc_7F7BD: add rsp, 38h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp locret_7F7CB: retn loc_7F7CC: mov eax, 1 jmp short loc_7F7BD loc_7F7D3: cmp ecx, ebp mov ecx, 1 cmovz eax, ecx jmp short loc_7F7BD loc_7F7DF: cmp ecx, ebp jmp loc_7F687
char mz_inflate(long long a1, unsigned int a2) { char result; // al _DWORD *v4; // rbx unsigned int v5; // r13d int v6; // ecx int v7; // edx bool v8; // di long long v9; // r10 int v10; // ecx int v11; // esi int v12; // edx int v13; // ecx long long v14; // rdx long long v15; // rdx int v16; // ecx unsigned int v17; // eax long long v18; // r15 int v19; // ecx bool v20; // zf _DWORD *v21; // r15 int v22; // r8d int v23; // r12d long long v24; // rcx long long v25; // rbp unsigned int v26; // eax int v27; // edx int v28; // ecx int v29; // [rsp+14h] [rbp-54h] long long v30; // [rsp+18h] [rbp-50h] BYREF long long v31; // [rsp+20h] [rbp-48h] BYREF long long v32; // [rsp+28h] [rbp-40h] _DWORD *v33; // [rsp+30h] [rbp-38h] result = -2; if ( !a1 ) return result; v4 = *(_DWORD **)(a1 + 56); if ( !v4 ) return result; v5 = 2; if ( a2 != 1 ) v5 = a2; if ( v5 > 4 ) return result; v6 = 21; if ( !_bittest(&v6, v5) ) return result; v7 = 0; v8 = v4[2754] > 0; v9 = *(unsigned int *)(a1 + 8); v10 = v4[2752]; v4[2752] = 0; if ( (int)v4[10947] < 0 ) return -3; v11 = v4[2753]; if ( v11 != 0 && v5 != 4 ) return result; LOBYTE(v7) = v8; v12 = v7 | 8; v4[2753] = (v5 == 4) | v11; if ( v5 == 4 && v10 ) { v31 = v9; v30 = *(unsigned int *)(a1 + 32); v13 = tinfl_decompress( (_DWORD)v4, *(_QWORD *)a1, (unsigned int)&v31, *(_QWORD *)(a1 + 24), *(_QWORD *)(a1 + 24), (unsigned int)&v30, v12 | 4u); v4[10947] = v13; v14 = (unsigned int)v31; *(_QWORD *)a1 += (unsigned int)v31; *(_DWORD *)(a1 + 8) -= v14; *(_QWORD *)(a1 + 16) += v14; *(_QWORD *)(a1 + 96) = (unsigned int)v4[7]; v15 = (unsigned int)v30; *(_QWORD *)(a1 + 24) += (unsigned int)v30; *(_DWORD *)(a1 + 32) -= v15; *(_QWORD *)(a1 + 40) += v15; result = -3; if ( v13 >= 0 ) { if ( v13 ) { v4[10947] = -1; return -5; } else { return 1; } } return result; } v16 = v12 | 2; if ( v5 == 4 ) v16 = v12; v17 = v4[2751]; if ( !v17 ) { v33 = v4 + 2755; v29 = v16; v32 = v9; v21 = v4 + 2755; while ( 1 ) { v31 = *(unsigned int *)(a1 + 8); v22 = v4[2750]; v30 = (unsigned int)(0x8000 - v22); v23 = tinfl_decompress( (_DWORD)v4, *(_QWORD *)a1, (unsigned int)&v31, (int)v4 + 11020, (int)v21 + v22, (unsigned int)&v30, v16); v4[10947] = v23; v24 = (unsigned int)v31; *(_QWORD *)a1 += (unsigned int)v31; *(_DWORD *)(a1 + 8) -= v24; *(_QWORD *)(a1 + 16) += v24; *(_QWORD *)(a1 + 96) = (unsigned int)v4[7]; v25 = (unsigned int)v30; v4[2751] = v30; v26 = *(_DWORD *)(a1 + 32); if ( v26 < (unsigned int)v25 ) v25 = v26; memcpy(*(_QWORD *)(a1 + 24), (char *)v21 + (unsigned int)v4[2750], v25); *(_QWORD *)(a1 + 24) += v25; v27 = *(_DWORD *)(a1 + 32); *(_DWORD *)(a1 + 32) = v27 - v25; *(_QWORD *)(a1 + 40) += v25; v28 = v4[2751]; v4[2751] = v28 - v25; v4[2750] = ((_WORD)v25 + (unsigned __int16)v4[2750]) & 0x7FFF; if ( v23 < 0 ) break; result = -5; if ( !((unsigned int)v32 | v23 ^ 1) ) return result; if ( v5 == 4 ) { if ( !v23 ) { if ( v28 == (_DWORD)v25 ) return 1; return result; } v16 = v29; if ( v27 == (_DWORD)v25 ) return result; } else { result = 0; if ( !v23 ) return v28 == (_DWORD)v25; if ( !*(_DWORD *)(a1 + 8) ) return result; if ( v27 == (_DWORD)v25 ) return result; v20 = v28 == (_DWORD)v25; v16 = v29; if ( !v20 ) return result; } } return -3; } v18 = *(unsigned int *)(a1 + 32); if ( v17 < (unsigned int)v18 ) v18 = v17; memcpy(*(_QWORD *)(a1 + 24), (char *)v4 + (unsigned int)v4[2750] + 11020, v18); *(_QWORD *)(a1 + 24) += v18; *(_DWORD *)(a1 + 32) -= v18; *(_QWORD *)(a1 + 40) += v18; v19 = v4[2751]; v4[2751] = v19 - v18; v4[2750] = ((_WORD)v18 + (unsigned __int16)v4[2750]) & 0x7FFF; result = 0; if ( !v4[10947] ) return v19 == (_DWORD)v18; return result; }
31,873
mz_inflate
7CodeWizard[P]stablediffusion/thirdparty/miniz.h
int mz_inflate(mz_streamp pStream, int flush) { inflate_state *pState; mz_uint n, first_call, decomp_flags = TINFL_FLAG_COMPUTE_ADLER32; size_t in_bytes, out_bytes, orig_avail_in; tinfl_status status; if ((!pStream) || (!pStream->state)) return MZ_STREAM_ERROR; if (flush == MZ_PARTIAL_FLUSH) flush = MZ_SYNC_FLUSH; if ((flush) && (flush != MZ_SYNC_FLUSH) && (flush != MZ_FINISH)) return MZ_STREAM_ERROR; pState = (inflate_state *)pStream->state; if (pState->m_window_bits > 0) decomp_flags |= TINFL_FLAG_PARSE_ZLIB_HEADER; orig_avail_in = pStream->avail_in; first_call = pState->m_first_call; pState->m_first_call = 0; if (pState->m_last_status < 0) return MZ_DATA_ERROR; if (pState->m_has_flushed && (flush != MZ_FINISH)) return MZ_STREAM_ERROR; pState->m_has_flushed |= (flush == MZ_FINISH); if ((flush == MZ_FINISH) && (first_call)) { /* MZ_FINISH on the first call implies that the input and output buffers are * large enough to hold the entire compressed/decompressed file. */ decomp_flags |= TINFL_FLAG_USING_NON_WRAPPING_OUTPUT_BUF; in_bytes = pStream->avail_in; out_bytes = pStream->avail_out; status = tinfl_decompress(&pState->m_decomp, pStream->next_in, &in_bytes, pStream->next_out, pStream->next_out, &out_bytes, decomp_flags); pState->m_last_status = status; pStream->next_in += (mz_uint)in_bytes; pStream->avail_in -= (mz_uint)in_bytes; pStream->total_in += (mz_uint)in_bytes; pStream->adler = tinfl_get_adler32(&pState->m_decomp); pStream->next_out += (mz_uint)out_bytes; pStream->avail_out -= (mz_uint)out_bytes; pStream->total_out += (mz_uint)out_bytes; if (status < 0) return MZ_DATA_ERROR; else if (status != TINFL_STATUS_DONE) { pState->m_last_status = TINFL_STATUS_FAILED; return MZ_BUF_ERROR; } return MZ_STREAM_END; } /* flush != MZ_FINISH then we must assume there's more input. */ if (flush != MZ_FINISH) decomp_flags |= TINFL_FLAG_HAS_MORE_INPUT; if (pState->m_dict_avail) { n = MZ_MIN(pState->m_dict_avail, pStream->avail_out); memcpy(pStream->next_out, pState->m_dict + pState->m_dict_ofs, n); pStream->next_out += n; pStream->avail_out -= n; pStream->total_out += n; pState->m_dict_avail -= n; pState->m_dict_ofs = (pState->m_dict_ofs + n) & (TINFL_LZ_DICT_SIZE - 1); return ((pState->m_last_status == TINFL_STATUS_DONE) && (!pState->m_dict_avail)) ? MZ_STREAM_END : MZ_OK; } for (;;) { in_bytes = pStream->avail_in; out_bytes = TINFL_LZ_DICT_SIZE - pState->m_dict_ofs; status = tinfl_decompress( &pState->m_decomp, pStream->next_in, &in_bytes, pState->m_dict, pState->m_dict + pState->m_dict_ofs, &out_bytes, decomp_flags); pState->m_last_status = status; pStream->next_in += (mz_uint)in_bytes; pStream->avail_in -= (mz_uint)in_bytes; pStream->total_in += (mz_uint)in_bytes; pStream->adler = tinfl_get_adler32(&pState->m_decomp); pState->m_dict_avail = (mz_uint)out_bytes; n = MZ_MIN(pState->m_dict_avail, pStream->avail_out); memcpy(pStream->next_out, pState->m_dict + pState->m_dict_ofs, n); pStream->next_out += n; pStream->avail_out -= n; pStream->total_out += n; pState->m_dict_avail -= n; pState->m_dict_ofs = (pState->m_dict_ofs + n) & (TINFL_LZ_DICT_SIZE - 1); if (status < 0) return MZ_DATA_ERROR; /* Stream is corrupted (there could be some uncompressed data left in the output dictionary - oh well). */ else if ((status == TINFL_STATUS_NEEDS_MORE_INPUT) && (!orig_avail_in)) return MZ_BUF_ERROR; /* Signal caller that we can't make forward progress without supplying more input or by setting flush to MZ_FINISH. */ else if (flush == MZ_FINISH) { /* The output buffer MUST be large to hold the remaining uncompressed data * when flush==MZ_FINISH. */ if (status == TINFL_STATUS_DONE) return pState->m_dict_avail ? MZ_BUF_ERROR : MZ_STREAM_END; /* status here must be TINFL_STATUS_HAS_MORE_OUTPUT, which means there's * at least 1 more byte on the way. If there's no more room left in the * output buffer then something is wrong. */ else if (!pStream->avail_out) return MZ_BUF_ERROR; } else if ((status == TINFL_STATUS_DONE) || (!pStream->avail_in) || (!pStream->avail_out) || (pState->m_dict_avail)) break; } return ((status == TINFL_STATUS_DONE) && (!pState->m_dict_avail)) ? MZ_STREAM_END : MZ_OK; }
O2
c
mz_inflate: pushq $-0x2 popq %rax testq %rdi, %rdi je 0x5b278 pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x38, %rsp movq %rdi, %r14 movq 0x38(%rdi), %rbx testq %rbx, %rbx je 0x5b26a cmpl $0x1, %esi pushq $0x2 popq %r13 cmovnel %esi, %r13d cmpl $0x4, %r13d ja 0x5b26a pushq $0x15 popq %rcx btl %r13d, %ecx jae 0x5b26a xorl %edx, %edx cmpl $0x0, 0x2b08(%rbx) setg %dil movl 0x8(%r14), %r10d movl 0x2b00(%rbx), %ecx andl $0x0, 0x2b00(%rbx) pushq $-0x3 popq %rsi cmpl $0x0, 0xab0c(%rbx) js 0x5b097 cmpl $0x4, %r13d setne %r8b movl 0x2b04(%rbx), %esi testl %esi, %esi setne %r9b testb %r9b, %r8b jne 0x5b26a movb %dil, %dl orl $0x8, %edx xorl %eax, %eax cmpl $0x4, %r13d sete %al orl %eax, %esi movl %esi, 0x2b04(%rbx) cmpl $0x4, %r13d jne 0x5b09e testl %ecx, %ecx je 0x5b09e orl $0x4, %edx leaq 0x20(%rsp), %r15 movq %r10, (%r15) movl 0x20(%r14), %eax leaq 0x18(%rsp), %r12 movq %rax, (%r12) movq (%r14), %rsi movq 0x18(%r14), %rcx movl %edx, (%rsp) movq %rbx, %rdi movq %r15, %rdx movq %rcx, %r8 movq %r12, %r9 callq 0x5b28f movl %eax, %ecx movl %eax, 0xab0c(%rbx) movq (%r15), %rax movl %eax, %edx addq %rdx, (%r14) subl %eax, 0x8(%r14) addq %rdx, 0x10(%r14) movl 0x1c(%rbx), %eax movq %rax, 0x60(%r14) movq (%r12), %rax movl %eax, %edx addq %rdx, 0x18(%r14) subl %eax, 0x20(%r14) addq %rdx, 0x28(%r14) pushq $-0x3 popq %rax testl %ecx, %ecx js 0x5b26a je 0x5b263 orl $-0x1, 0xab0c(%rbx) pushq $-0x5 jmp 0x5b269 movl %esi, %eax jmp 0x5b26a movl %edx, %r9d orl $0x2, %r9d cmpl $0x4, %r13d cmovel %edx, %r9d movl 0x2afc(%rbx), %eax testl %eax, %eax je 0x5b12c movl 0x20(%r14), %r15d cmpl %r15d, %eax cmovbl %eax, %r15d movq 0x18(%r14), %rdi movl 0x2af8(%rbx), %eax leaq (%rbx,%rax), %rsi addq $0x2b0c, %rsi # imm = 0x2B0C movq %r15, %rdx callq 0xa4c0 addq %r15, 0x18(%r14) subl %r15d, 0x20(%r14) addq %r15, 0x28(%r14) movl 0x2afc(%rbx), %ecx movl %ecx, %eax subl %r15d, %eax movl %eax, 0x2afc(%rbx) movl 0x2af8(%rbx), %eax addl %r15d, %eax andl $0x7fff, %eax # imm = 0x7FFF movl %eax, 0x2af8(%rbx) xorl %eax, %eax cmpl $0x0, 0xab0c(%rbx) jne 0x5b26a xorl %eax, %eax cmpl %r15d, %ecx sete %al jmp 0x5b26a leaq 0x2b0c(%rbx), %rax movq %rax, 0x30(%rsp) movl 0x2af8(%rbx), %ecx movl %r10d, %edi movl %r9d, 0x14(%rsp) movq %r10, 0x28(%rsp) movq 0x30(%rsp), %r15 movl %edi, %eax movq %rax, 0x20(%rsp) movl $0x8000, %eax # imm = 0x8000 subl %ecx, %eax movq %rax, 0x18(%rsp) movq (%r14), %rsi movl %ecx, %r8d addq %r15, %r8 movl %r9d, (%rsp) movq %rbx, %rdi leaq 0x20(%rsp), %rdx movq %r15, %rcx leaq 0x18(%rsp), %r9 callq 0x5b28f movl %eax, %r12d movl %eax, 0xab0c(%rbx) movq 0x20(%rsp), %rax movl %eax, %ecx addq %rcx, (%r14) subl %eax, 0x8(%r14) addq %rcx, 0x10(%r14) movl 0x1c(%rbx), %eax movq %rax, 0x60(%r14) movl 0x18(%rsp), %ebp movl %ebp, 0x2afc(%rbx) movl 0x20(%r14), %eax cmpl %ebp, %eax cmovbl %eax, %ebp movq 0x18(%r14), %rdi movl 0x2af8(%rbx), %esi addq %r15, %rsi movq %rbp, %rdx callq 0xa4c0 addq %rbp, 0x18(%r14) movl 0x20(%r14), %esi movl %esi, %eax subl %ebp, %eax movl %eax, 0x20(%r14) addq %rbp, 0x28(%r14) movl 0x2afc(%rbx), %edx movl %edx, %eax subl %ebp, %eax movl %eax, 0x2afc(%rbx) movl 0x2af8(%rbx), %ecx addl %ebp, %ecx andl $0x7fff, %ecx # imm = 0x7FFF movl %ecx, 0x2af8(%rbx) testl %r12d, %r12d js 0x5b267 movl %r12d, %eax xorl $0x1, %eax movq 0x28(%rsp), %r10 orl %r10d, %eax je 0x5b090 cmpl $0x4, %r13d jne 0x5b241 testl %r12d, %r12d je 0x5b279 cmpl %ebp, %esi je 0x5b090 movl 0x8(%r14), %edi movl 0x14(%rsp), %r9d jmp 0x5b150 testl %r12d, %r12d je 0x5b286 movl 0x8(%r14), %edi xorl %eax, %eax testl %edi, %edi je 0x5b26a cmpl %ebp, %esi je 0x5b26a cmpl %ebp, %edx movl 0x14(%rsp), %r9d je 0x5b150 jmp 0x5b26a pushq $0x1 jmp 0x5b269 pushq $-0x3 popq %rax addq $0x38, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq cmpl %ebp, %edx pushq $0x1 popq %rcx pushq $-0x5 popq %rax cmovel %ecx, %eax jmp 0x5b26a xorl %eax, %eax cmpl %ebp, %edx jmp 0x5b124
mz_inflate: push 0FFFFFFFFFFFFFFFEh pop rax test rdi, rdi jz locret_5B278 push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 38h mov r14, rdi mov rbx, [rdi+38h] test rbx, rbx jz loc_5B26A cmp esi, 1 push 2 pop r13 cmovnz r13d, esi cmp r13d, 4 ja loc_5B26A push 15h pop rcx bt ecx, r13d jnb loc_5B26A xor edx, edx cmp dword ptr [rbx+2B08h], 0 setnle dil mov r10d, [r14+8] mov ecx, [rbx+2B00h] and dword ptr [rbx+2B00h], 0 push 0FFFFFFFFFFFFFFFDh pop rsi cmp dword ptr [rbx+0AB0Ch], 0 js loc_5B097 cmp r13d, 4 setnz r8b mov esi, [rbx+2B04h] test esi, esi setnz r9b test r8b, r9b jnz loc_5B26A mov dl, dil or edx, 8 xor eax, eax cmp r13d, 4 setz al or esi, eax mov [rbx+2B04h], esi cmp r13d, 4 jnz loc_5B09E test ecx, ecx jz loc_5B09E or edx, 4 lea r15, [rsp+68h+var_48] mov [r15], r10 mov eax, [r14+20h] lea r12, [rsp+68h+var_50] mov [r12], rax mov rsi, [r14] mov rcx, [r14+18h] mov [rsp+68h+var_68], edx mov rdi, rbx mov rdx, r15 mov r8, rcx mov r9, r12 call tinfl_decompress mov ecx, eax mov [rbx+0AB0Ch], eax mov rax, [r15] mov edx, eax add [r14], rdx sub [r14+8], eax add [r14+10h], rdx mov eax, [rbx+1Ch] mov [r14+60h], rax mov rax, [r12] mov edx, eax add [r14+18h], rdx sub [r14+20h], eax add [r14+28h], rdx push 0FFFFFFFFFFFFFFFDh pop rax test ecx, ecx js loc_5B26A jz loc_5B263 or dword ptr [rbx+0AB0Ch], 0FFFFFFFFh loc_5B090: push 0FFFFFFFFFFFFFFFBh jmp loc_5B269 loc_5B097: mov eax, esi jmp loc_5B26A loc_5B09E: mov r9d, edx or r9d, 2 cmp r13d, 4 cmovz r9d, edx mov eax, [rbx+2AFCh] test eax, eax jz short loc_5B12C mov r15d, [r14+20h] cmp eax, r15d cmovb r15d, eax mov rdi, [r14+18h] mov eax, [rbx+2AF8h] lea rsi, [rbx+rax] add rsi, 2B0Ch mov rdx, r15 call _memcpy add [r14+18h], r15 sub [r14+20h], r15d add [r14+28h], r15 mov ecx, [rbx+2AFCh] mov eax, ecx sub eax, r15d mov [rbx+2AFCh], eax mov eax, [rbx+2AF8h] add eax, r15d and eax, 7FFFh mov [rbx+2AF8h], eax xor eax, eax cmp dword ptr [rbx+0AB0Ch], 0 jnz loc_5B26A xor eax, eax cmp ecx, r15d loc_5B124: setz al jmp loc_5B26A loc_5B12C: lea rax, [rbx+2B0Ch] mov [rsp+68h+var_38], rax mov ecx, [rbx+2AF8h] mov edi, r10d mov [rsp+68h+var_54], r9d mov [rsp+68h+var_40], r10 mov r15, [rsp+68h+var_38] loc_5B150: mov eax, edi mov [rsp+68h+var_48], rax mov eax, 8000h sub eax, ecx mov [rsp+68h+var_50], rax mov rsi, [r14] mov r8d, ecx add r8, r15 mov [rsp+68h+var_68], r9d mov rdi, rbx lea rdx, [rsp+68h+var_48] mov rcx, r15 lea r9, [rsp+68h+var_50] call tinfl_decompress mov r12d, eax mov [rbx+0AB0Ch], eax mov rax, [rsp+68h+var_48] mov ecx, eax add [r14], rcx sub [r14+8], eax add [r14+10h], rcx mov eax, [rbx+1Ch] mov [r14+60h], rax mov ebp, dword ptr [rsp+68h+var_50] mov [rbx+2AFCh], ebp mov eax, [r14+20h] cmp eax, ebp cmovb ebp, eax mov rdi, [r14+18h] mov esi, [rbx+2AF8h] add rsi, r15 mov rdx, rbp call _memcpy add [r14+18h], rbp mov esi, [r14+20h] mov eax, esi sub eax, ebp mov [r14+20h], eax add [r14+28h], rbp mov edx, [rbx+2AFCh] mov eax, edx sub eax, ebp mov [rbx+2AFCh], eax mov ecx, [rbx+2AF8h] add ecx, ebp and ecx, 7FFFh mov [rbx+2AF8h], ecx test r12d, r12d js short loc_5B267 mov eax, r12d xor eax, 1 mov r10, [rsp+68h+var_40] or eax, r10d jz loc_5B090 cmp r13d, 4 jnz short loc_5B241 test r12d, r12d jz short loc_5B279 cmp esi, ebp jz loc_5B090 mov edi, [r14+8] mov r9d, [rsp+68h+var_54] jmp loc_5B150 loc_5B241: test r12d, r12d jz short loc_5B286 mov edi, [r14+8] xor eax, eax test edi, edi jz short loc_5B26A cmp esi, ebp jz short loc_5B26A cmp edx, ebp mov r9d, [rsp+68h+var_54] jz loc_5B150 jmp short loc_5B26A loc_5B263: push 1 jmp short loc_5B269 loc_5B267: push 0FFFFFFFFFFFFFFFDh loc_5B269: pop rax loc_5B26A: add rsp, 38h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp locret_5B278: retn loc_5B279: cmp edx, ebp push 1 pop rcx push 0FFFFFFFFFFFFFFFBh pop rax cmovz eax, ecx jmp short loc_5B26A loc_5B286: xor eax, eax cmp edx, ebp jmp loc_5B124
char mz_inflate(long long a1, unsigned int a2) { char result; // al unsigned int *v4; // rbx unsigned int v5; // r13d int v6; // ecx int v7; // edx bool v8; // di long long v9; // r10 unsigned int v10; // ecx unsigned int v11; // esi int v12; // edx int v13; // ecx long long v14; // rdx long long v15; // rdx int v16; // r9d unsigned int v17; // eax long long v18; // r15 unsigned int v19; // ecx int v21; // ecx unsigned int v22; // edi unsigned int *v23; // r15 int v24; // r12d long long v25; // rcx long long v26; // rbp unsigned int v27; // eax int v28; // esi unsigned int v29; // edx int v31; // [rsp+14h] [rbp-54h] long long v32; // [rsp+18h] [rbp-50h] BYREF long long v33; // [rsp+20h] [rbp-48h] BYREF long long v34; // [rsp+28h] [rbp-40h] unsigned int *v35; // [rsp+30h] [rbp-38h] result = -2; if ( a1 ) { v4 = *(unsigned int **)(a1 + 56); if ( v4 ) { v5 = 2; if ( a2 != 1 ) v5 = a2; if ( v5 <= 4 ) { v6 = 21; if ( _bittest(&v6, v5) ) { v7 = 0; v8 = (int)v4[2754] > 0; v9 = *(unsigned int *)(a1 + 8); v10 = v4[2752]; v4[2752] = 0; if ( (v4[10947] & 0x80000000) != 0 ) { return -3; } else { v11 = v4[2753]; if ( v11 == 0 || v5 == 4 ) { LOBYTE(v7) = v8; v12 = v7 | 8; v4[2753] = (v5 == 4) | v11; if ( v5 == 4 && v10 ) { v33 = v9; v32 = *(unsigned int *)(a1 + 32); v13 = tinfl_decompress( (_DWORD)v4, *(_QWORD *)a1, (unsigned int)&v33, *(_QWORD *)(a1 + 24), *(_QWORD *)(a1 + 24), (unsigned int)&v32, v12 | 4u); v4[10947] = v13; v14 = (unsigned int)v33; *(_QWORD *)a1 += (unsigned int)v33; *(_DWORD *)(a1 + 8) -= v14; *(_QWORD *)(a1 + 16) += v14; *(_QWORD *)(a1 + 96) = v4[7]; v15 = (unsigned int)v32; *(_QWORD *)(a1 + 24) += (unsigned int)v32; *(_DWORD *)(a1 + 32) -= v15; *(_QWORD *)(a1 + 40) += v15; result = -3; if ( v13 >= 0 ) { if ( !v13 ) return 1; v4[10947] = -1; return -5; } } else { v16 = v12 | 2; if ( v5 == 4 ) v16 = v12; v17 = v4[2751]; if ( v17 ) { v18 = *(unsigned int *)(a1 + 32); if ( v17 < (unsigned int)v18 ) v18 = v17; memcpy(*(_QWORD *)(a1 + 24), (char *)v4 + v4[2750] + 11020, v18); *(_QWORD *)(a1 + 24) += v18; *(_DWORD *)(a1 + 32) -= v18; *(_QWORD *)(a1 + 40) += v18; v19 = v4[2751]; v4[2751] = v19 - v18; v4[2750] = ((_WORD)v18 + (unsigned __int16)v4[2750]) & 0x7FFF; result = 0; if ( !v4[10947] ) return v19 == (_DWORD)v18; } else { v35 = v4 + 2755; v21 = v4[2750]; v22 = v9; v31 = v16; v34 = v9; v23 = v4 + 2755; while ( 1 ) { while ( 1 ) { v33 = v22; v32 = (unsigned int)(0x8000 - v21); v24 = tinfl_decompress( (_DWORD)v4, *(_QWORD *)a1, (unsigned int)&v33, (int)v4 + 11020, (int)v23 + v21, (unsigned int)&v32, v16); v4[10947] = v24; v25 = (unsigned int)v33; *(_QWORD *)a1 += (unsigned int)v33; *(_DWORD *)(a1 + 8) -= v25; *(_QWORD *)(a1 + 16) += v25; *(_QWORD *)(a1 + 96) = v4[7]; v26 = (unsigned int)v32; v4[2751] = v32; v27 = *(_DWORD *)(a1 + 32); if ( v27 < (unsigned int)v26 ) v26 = v27; memcpy(*(_QWORD *)(a1 + 24), (char *)v23 + v4[2750], v26); *(_QWORD *)(a1 + 24) += v26; v28 = *(_DWORD *)(a1 + 32); *(_DWORD *)(a1 + 32) = v28 - v26; *(_QWORD *)(a1 + 40) += v26; v29 = v4[2751]; v4[2751] = v29 - v26; v21 = ((_WORD)v26 + (unsigned __int16)v4[2750]) & 0x7FFF; v4[2750] = v21; if ( v24 < 0 ) return -3; if ( !((unsigned int)v34 | v24 ^ 1) ) return -5; if ( v5 == 4 ) break; if ( !v24 ) return v29 == (_DWORD)v26; v22 = *(_DWORD *)(a1 + 8); result = 0; if ( v22 ) { if ( v28 != (_DWORD)v26 ) { v16 = v31; if ( v29 == (_DWORD)v26 ) continue; } } return result; } if ( !v24 ) break; if ( v28 == (_DWORD)v26 ) return -5; v22 = *(_DWORD *)(a1 + 8); v16 = v31; } result = -5; if ( v29 == (_DWORD)v26 ) return 1; } } } } } } } } return result; }
mz_inflate: PUSH -0x2 POP RAX TEST RDI,RDI JZ 0x0015b278 PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x38 MOV R14,RDI MOV RBX,qword ptr [RDI + 0x38] TEST RBX,RBX JZ 0x0015b26a CMP ESI,0x1 PUSH 0x2 POP R13 CMOVNZ R13D,ESI CMP R13D,0x4 JA 0x0015b26a PUSH 0x15 POP RCX BT ECX,R13D JNC 0x0015b26a XOR EDX,EDX CMP dword ptr [RBX + 0x2b08],0x0 SETG DIL MOV R10D,dword ptr [R14 + 0x8] MOV ECX,dword ptr [RBX + 0x2b00] AND dword ptr [RBX + 0x2b00],0x0 PUSH -0x3 POP RSI CMP dword ptr [RBX + 0xab0c],0x0 JS 0x0015b097 CMP R13D,0x4 SETNZ R8B MOV ESI,dword ptr [RBX + 0x2b04] TEST ESI,ESI SETNZ R9B TEST R8B,R9B JNZ 0x0015b26a MOV DL,DIL OR EDX,0x8 XOR EAX,EAX CMP R13D,0x4 SETZ AL OR ESI,EAX MOV dword ptr [RBX + 0x2b04],ESI CMP R13D,0x4 JNZ 0x0015b09e TEST ECX,ECX JZ 0x0015b09e OR EDX,0x4 LEA R15,[RSP + 0x20] MOV qword ptr [R15],R10 MOV EAX,dword ptr [R14 + 0x20] LEA R12,[RSP + 0x18] MOV qword ptr [R12],RAX MOV RSI,qword ptr [R14] MOV RCX,qword ptr [R14 + 0x18] MOV dword ptr [RSP],EDX MOV RDI,RBX MOV RDX,R15 MOV R8,RCX MOV R9,R12 CALL 0x0015b28f MOV ECX,EAX MOV dword ptr [RBX + 0xab0c],EAX MOV RAX,qword ptr [R15] MOV EDX,EAX ADD qword ptr [R14],RDX SUB dword ptr [R14 + 0x8],EAX ADD qword ptr [R14 + 0x10],RDX MOV EAX,dword ptr [RBX + 0x1c] MOV qword ptr [R14 + 0x60],RAX MOV RAX,qword ptr [R12] MOV EDX,EAX ADD qword ptr [R14 + 0x18],RDX SUB dword ptr [R14 + 0x20],EAX ADD qword ptr [R14 + 0x28],RDX PUSH -0x3 POP RAX TEST ECX,ECX JS 0x0015b26a JZ 0x0015b263 OR dword ptr [RBX + 0xab0c],0xffffffff LAB_0015b090: PUSH -0x5 JMP 0x0015b269 LAB_0015b097: MOV EAX,ESI JMP 0x0015b26a LAB_0015b09e: MOV R9D,EDX OR R9D,0x2 CMP R13D,0x4 CMOVZ R9D,EDX MOV EAX,dword ptr [RBX + 0x2afc] TEST EAX,EAX JZ 0x0015b12c MOV R15D,dword ptr [R14 + 0x20] CMP EAX,R15D CMOVC R15D,EAX MOV RDI,qword ptr [R14 + 0x18] MOV EAX,dword ptr [RBX + 0x2af8] LEA RSI,[RBX + RAX*0x1] ADD RSI,0x2b0c MOV RDX,R15 CALL 0x0010a4c0 ADD qword ptr [R14 + 0x18],R15 SUB dword ptr [R14 + 0x20],R15D ADD qword ptr [R14 + 0x28],R15 MOV ECX,dword ptr [RBX + 0x2afc] MOV EAX,ECX SUB EAX,R15D MOV dword ptr [RBX + 0x2afc],EAX MOV EAX,dword ptr [RBX + 0x2af8] ADD EAX,R15D AND EAX,0x7fff MOV dword ptr [RBX + 0x2af8],EAX XOR EAX,EAX CMP dword ptr [RBX + 0xab0c],0x0 JNZ 0x0015b26a XOR EAX,EAX CMP ECX,R15D LAB_0015b124: SETZ AL JMP 0x0015b26a LAB_0015b12c: LEA RAX,[RBX + 0x2b0c] MOV qword ptr [RSP + 0x30],RAX MOV ECX,dword ptr [RBX + 0x2af8] MOV EDI,R10D MOV dword ptr [RSP + 0x14],R9D MOV qword ptr [RSP + 0x28],R10 MOV R15,qword ptr [RSP + 0x30] LAB_0015b150: MOV EAX,EDI MOV qword ptr [RSP + 0x20],RAX MOV EAX,0x8000 SUB EAX,ECX MOV qword ptr [RSP + 0x18],RAX MOV RSI,qword ptr [R14] MOV R8D,ECX ADD R8,R15 MOV dword ptr [RSP],R9D MOV RDI,RBX LEA RDX,[RSP + 0x20] MOV RCX,R15 LEA R9,[RSP + 0x18] CALL 0x0015b28f MOV R12D,EAX MOV dword ptr [RBX + 0xab0c],EAX MOV RAX,qword ptr [RSP + 0x20] MOV ECX,EAX ADD qword ptr [R14],RCX SUB dword ptr [R14 + 0x8],EAX ADD qword ptr [R14 + 0x10],RCX MOV EAX,dword ptr [RBX + 0x1c] MOV qword ptr [R14 + 0x60],RAX MOV EBP,dword ptr [RSP + 0x18] MOV dword ptr [RBX + 0x2afc],EBP MOV EAX,dword ptr [R14 + 0x20] CMP EAX,EBP CMOVC EBP,EAX MOV RDI,qword ptr [R14 + 0x18] MOV ESI,dword ptr [RBX + 0x2af8] ADD RSI,R15 MOV RDX,RBP CALL 0x0010a4c0 ADD qword ptr [R14 + 0x18],RBP MOV ESI,dword ptr [R14 + 0x20] MOV EAX,ESI SUB EAX,EBP MOV dword ptr [R14 + 0x20],EAX ADD qword ptr [R14 + 0x28],RBP MOV EDX,dword ptr [RBX + 0x2afc] MOV EAX,EDX SUB EAX,EBP MOV dword ptr [RBX + 0x2afc],EAX MOV ECX,dword ptr [RBX + 0x2af8] ADD ECX,EBP AND ECX,0x7fff MOV dword ptr [RBX + 0x2af8],ECX TEST R12D,R12D JS 0x0015b267 MOV EAX,R12D XOR EAX,0x1 MOV R10,qword ptr [RSP + 0x28] OR EAX,R10D JZ 0x0015b090 CMP R13D,0x4 JNZ 0x0015b241 TEST R12D,R12D JZ 0x0015b279 CMP ESI,EBP JZ 0x0015b090 MOV EDI,dword ptr [R14 + 0x8] MOV R9D,dword ptr [RSP + 0x14] JMP 0x0015b150 LAB_0015b241: TEST R12D,R12D JZ 0x0015b286 MOV EDI,dword ptr [R14 + 0x8] XOR EAX,EAX TEST EDI,EDI JZ 0x0015b26a CMP ESI,EBP JZ 0x0015b26a CMP EDX,EBP MOV R9D,dword ptr [RSP + 0x14] JZ 0x0015b150 JMP 0x0015b26a LAB_0015b263: PUSH 0x1 JMP 0x0015b269 LAB_0015b267: PUSH -0x3 LAB_0015b269: POP RAX LAB_0015b26a: ADD RSP,0x38 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP LAB_0015b278: RET LAB_0015b279: CMP EDX,EBP PUSH 0x1 POP RCX PUSH -0x5 POP RAX CMOVZ EAX,ECX JMP 0x0015b26a LAB_0015b286: XOR EAX,EAX CMP EDX,EBP JMP 0x0015b124
ulong mz_inflate(long *param_1,uint param_2) { long lVar1; uint uVar2; uint uVar3; long lVar4; byte bVar5; uint uVar6; int iVar7; uint uVar8; uint uVar9; ulong uVar10; bool bVar11; ulong uStackY_70; ulong local_50; ulong local_48; ulong local_40; long local_38; uStackY_70 = 0xfffffffffffffffe; if ((param_1 != (long *)0x0) && (lVar4 = param_1[7], lVar4 != 0)) { uVar9 = 2; if (param_2 != 1) { uVar9 = param_2; } if ((uVar9 < 5) && ((0x15U >> (uVar9 & 0x1f) & 1) != 0)) { bVar11 = 0 < *(int *)(lVar4 + 0x2b08); local_48 = (ulong)*(uint *)(param_1 + 1); iVar7 = *(int *)(lVar4 + 0x2b00); *(int4 *)(lVar4 + 0x2b00) = 0; if (*(int *)(lVar4 + 0xab0c) < 0) { uStackY_70 = 0xfffffffd; } else if (uVar9 == 4 || *(uint *)(lVar4 + 0x2b04) == 0) { *(uint *)(lVar4 + 0x2b04) = *(uint *)(lVar4 + 0x2b04) | (uint)(uVar9 == 4); if ((uVar9 == 4) && (iVar7 != 0)) { local_50 = (ulong)*(uint *)(param_1 + 4); iVar7 = tinfl_decompress(lVar4,*param_1,&local_48,param_1[3],param_1[3],&local_50, bVar11 | 0xc); *(int *)(lVar4 + 0xab0c) = iVar7; *param_1 = *param_1 + (local_48 & 0xffffffff); *(int *)(param_1 + 1) = (int)param_1[1] - (int)local_48; param_1[2] = param_1[2] + (local_48 & 0xffffffff); param_1[0xc] = (ulong)*(uint *)(lVar4 + 0x1c); param_1[3] = param_1[3] + (local_50 & 0xffffffff); *(int *)(param_1 + 4) = (int)param_1[4] - (int)local_50; param_1[5] = param_1[5] + (local_50 & 0xffffffff); uStackY_70 = 0xfffffffffffffffd; if (-1 < iVar7) { if (iVar7 == 0) { uStackY_70 = 1; } else { *(int4 *)(lVar4 + 0xab0c) = 0xffffffff; LAB_0015b090: uStackY_70 = 0xfffffffffffffffb; } } } else { bVar5 = bVar11 | 10; if (uVar9 == 4) { bVar5 = bVar11 | 8; } uVar8 = *(uint *)(lVar4 + 0x2afc); if (uVar8 == 0) { lVar1 = lVar4 + 0x2b0c; uVar8 = *(uint *)(lVar4 + 11000); local_40 = local_48; local_38 = lVar1; while( true ) { while( true ) { local_50 = (ulong)(0x8000 - uVar8); iVar7 = tinfl_decompress(lVar4,*param_1,&local_48,lVar1,(ulong)uVar8 + lVar1, &local_50,bVar5); *(int *)(lVar4 + 0xab0c) = iVar7; *param_1 = *param_1 + (local_48 & 0xffffffff); *(int *)(param_1 + 1) = (int)param_1[1] - (int)local_48; param_1[2] = param_1[2] + (local_48 & 0xffffffff); param_1[0xc] = (ulong)*(uint *)(lVar4 + 0x1c); *(uint *)(lVar4 + 0x2afc) = (uint)local_50; uVar6 = (uint)local_50; if (*(uint *)(param_1 + 4) < (uint)local_50) { uVar6 = *(uint *)(param_1 + 4); } uVar10 = (ulong)uVar6; memcpy((void *)param_1[3],(void *)((ulong)*(uint *)(lVar4 + 11000) + lVar1),uVar10); param_1[3] = param_1[3] + uVar10; uVar2 = *(uint *)(param_1 + 4); *(uint *)(param_1 + 4) = uVar2 - uVar6; param_1[5] = param_1[5] + uVar10; uVar3 = *(uint *)(lVar4 + 0x2afc); *(uint *)(lVar4 + 0x2afc) = uVar3 - uVar6; uVar8 = *(int *)(lVar4 + 11000) + uVar6 & 0x7fff; *(uint *)(lVar4 + 11000) = uVar8; if (iVar7 < 0) { return 0xfffffffffffffffd; } if (iVar7 == 1 && (int)local_40 == 0) goto LAB_0015b090; if (uVar9 == 4) break; if (iVar7 == 0) { bVar11 = uVar3 == uVar6; goto LAB_0015b124; } local_48 = (ulong)*(uint *)(param_1 + 1); if (*(uint *)(param_1 + 1) == 0) { return 0; } if (uVar2 == uVar6) { return 0; } if (uVar3 != uVar6) { return 0; } } if (iVar7 == 0) break; if (uVar2 == uVar6) goto LAB_0015b090; local_48 = (ulong)*(uint *)(param_1 + 1); } uStackY_70 = 0xfffffffffffffffb; if (uVar3 == uVar6) { uStackY_70 = 1; } uStackY_70 = uStackY_70 & 0xffffffff; } else { uVar9 = *(uint *)(param_1 + 4); if (uVar8 < *(uint *)(param_1 + 4)) { uVar9 = uVar8; } uVar10 = (ulong)uVar9; memcpy((void *)param_1[3],(void *)(lVar4 + (ulong)*(uint *)(lVar4 + 11000) + 0x2b0c), uVar10); param_1[3] = param_1[3] + uVar10; *(uint *)(param_1 + 4) = (int)param_1[4] - uVar9; param_1[5] = param_1[5] + uVar10; uVar8 = *(uint *)(lVar4 + 0x2afc); *(uint *)(lVar4 + 0x2afc) = uVar8 - uVar9; *(uint *)(lVar4 + 11000) = *(int *)(lVar4 + 11000) + uVar9 & 0x7fff; uStackY_70 = 0; if (*(int *)(lVar4 + 0xab0c) == 0) { bVar11 = uVar8 == uVar9; LAB_0015b124: uStackY_70 = (ulong)bVar11; } } } } } } return uStackY_70; }
31,874
js_trigger_gc
bluesky950520[P]quickjs/quickjs.c
static void js_trigger_gc(JSRuntime *rt, size_t size) { BOOL force_gc; #ifdef FORCE_GC_AT_MALLOC force_gc = TRUE; #else force_gc = ((rt->malloc_state.malloc_size + size) > rt->malloc_gc_threshold); #endif if (force_gc) { #ifdef DUMP_GC if (check_dump_flag(rt, DUMP_GC)) { printf("GC: size=%" PRIu64 "\n", (uint64_t)rt->malloc_state.malloc_size); } #endif JS_RunGC(rt); rt->malloc_gc_threshold = rt->malloc_state.malloc_size + (rt->malloc_state.malloc_size >> 1); } }
O0
c
js_trigger_gc: subq $0x18, %rsp movq %rdi, 0x10(%rsp) movq %rsi, 0x8(%rsp) movq 0x10(%rsp), %rax movq 0x30(%rax), %rax addq 0x8(%rsp), %rax movq 0x10(%rsp), %rcx cmpq 0xd0(%rcx), %rax seta %al andb $0x1, %al movzbl %al, %eax movl %eax, 0x4(%rsp) cmpl $0x0, 0x4(%rsp) je 0x5ca79 movq 0x10(%rsp), %rdi callq 0x22ab0 movq 0x10(%rsp), %rax movq 0x30(%rax), %rcx movq 0x10(%rsp), %rax movq 0x30(%rax), %rax shrq %rax addq %rax, %rcx movq 0x10(%rsp), %rax movq %rcx, 0xd0(%rax) addq $0x18, %rsp retq nop
js_trigger_gc: sub rsp, 18h mov [rsp+18h+var_8], rdi mov [rsp+18h+var_10], rsi mov rax, [rsp+18h+var_8] mov rax, [rax+30h] add rax, [rsp+18h+var_10] mov rcx, [rsp+18h+var_8] cmp rax, [rcx+0D0h] setnbe al and al, 1 movzx eax, al mov [rsp+18h+var_14], eax cmp [rsp+18h+var_14], 0 jz short loc_5CA79 mov rdi, [rsp+18h+var_8] call JS_RunGC mov rax, [rsp+18h+var_8] mov rcx, [rax+30h] mov rax, [rsp+18h+var_8] mov rax, [rax+30h] shr rax, 1 add rcx, rax mov rax, [rsp+18h+var_8] mov [rax+0D0h], rcx loc_5CA79: add rsp, 18h retn
_BOOL8 js_trigger_gc(long long a1, long long a2) { _BOOL8 result; // rax result = (unsigned long long)(a2 + *(_QWORD *)(a1 + 48)) > *(_QWORD *)(a1 + 208); if ( (unsigned long long)(a2 + *(_QWORD *)(a1 + 48)) > *(_QWORD *)(a1 + 208) ) { JS_RunGC(a1); result = a1; *(_QWORD *)(a1 + 208) = (*(_QWORD *)(a1 + 48) >> 1) + *(_QWORD *)(a1 + 48); } return result; }
js_trigger_gc: SUB RSP,0x18 MOV qword ptr [RSP + 0x10],RDI MOV qword ptr [RSP + 0x8],RSI MOV RAX,qword ptr [RSP + 0x10] MOV RAX,qword ptr [RAX + 0x30] ADD RAX,qword ptr [RSP + 0x8] MOV RCX,qword ptr [RSP + 0x10] CMP RAX,qword ptr [RCX + 0xd0] SETA AL AND AL,0x1 MOVZX EAX,AL MOV dword ptr [RSP + 0x4],EAX CMP dword ptr [RSP + 0x4],0x0 JZ 0x0015ca79 MOV RDI,qword ptr [RSP + 0x10] CALL 0x00122ab0 MOV RAX,qword ptr [RSP + 0x10] MOV RCX,qword ptr [RAX + 0x30] MOV RAX,qword ptr [RSP + 0x10] MOV RAX,qword ptr [RAX + 0x30] SHR RAX,0x1 ADD RCX,RAX MOV RAX,qword ptr [RSP + 0x10] MOV qword ptr [RAX + 0xd0],RCX LAB_0015ca79: ADD RSP,0x18 RET
void js_trigger_gc(long param_1,long param_2) { if (*(ulong *)(param_1 + 0xd0) < (ulong)(*(long *)(param_1 + 0x30) + param_2)) { JS_RunGC(param_1); *(ulong *)(param_1 + 0xd0) = *(long *)(param_1 + 0x30) + (*(ulong *)(param_1 + 0x30) >> 1); } return; }
31,875
my_once_alloc
eloqsql/mysys/my_once.c
void* my_once_alloc(size_t Size, myf MyFlags) { size_t get_size, max_left; uchar* point; reg1 USED_MEM *next; reg2 USED_MEM **prev; Size= ALIGN_SIZE(Size); prev= &my_once_root_block; max_left=0; for (next=my_once_root_block ; next && next->left < Size ; next= next->next) { if (next->left > max_left) max_left=next->left; prev= &next->next; } if (! next) { /* Time to alloc new block */ get_size= Size+ALIGN_SIZE(sizeof(USED_MEM)); if (max_left*4 < my_once_extra && get_size < my_once_extra) get_size=my_once_extra; /* Normal alloc */ if ((next = (USED_MEM*) malloc(get_size)) == 0) { my_errno=errno; if (MyFlags & (MY_FAE+MY_WME)) my_error(EE_OUTOFMEMORY, MYF(ME_BELL+ME_FATAL), get_size); return((uchar*) 0); } DBUG_PRINT("test",("my_once_malloc %lu byte malloced", (ulong) get_size)); next->next= 0; next->size= get_size; next->left= get_size-ALIGN_SIZE(sizeof(USED_MEM)); *prev=next; } point= (uchar*) ((char*) next+ (next->size-next->left)); next->left-= Size; if (MyFlags & MY_ZEROFILL) bzero(point, Size); return((void*) point); }
O3
c
my_once_alloc: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx pushq %rax movq %rsi, %rbx movq %rdi, %r14 addq $0x7, %r14 andq $-0x8, %r14 leaq 0x38dc85(%rip), %r13 # 0x3d6720 movq (%r13), %rcx xorl %eax, %eax testq %rcx, %rcx je 0x48ac6 movq %rcx, %r13 movq 0x8(%rcx), %rcx cmpq %r14, %rcx jae 0x48b0f cmpq %rax, %rcx cmovaq %rcx, %rax movq (%r13), %rcx testq %rcx, %rcx jne 0x48aa6 shlq $0x2, %rax leaq 0x18(%r14), %rcx leaq 0x2d3f4f(%rip), %rdx # 0x31ca20 movl (%rdx), %edx cmpq %rdx, %rcx movq %rdx, %r15 cmovaq %rcx, %r15 cmpq %rdx, %rax cmovaeq %rcx, %r15 movq %r15, %rdi callq 0x26480 testq %rax, %rax je 0x48b40 movq $0x0, (%rax) movq %r15, 0x10(%rax) addq $-0x18, %r15 movq %r15, 0x8(%rax) movq %rax, (%r13) movq 0x8(%rax), %rcx movq %rax, %r13 movq 0x10(%r13), %r12 subq %rcx, %r12 addq %r13, %r12 subq %r14, %rcx movq %rcx, 0x8(%r13) testb $0x20, %bl je 0x48b6c movq %r12, %rdi xorl %esi, %esi movq %r14, %rdx addq $0x8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp jmp 0x261c0 callq 0x26060 movl (%rax), %r14d callq 0x49666 movl %r14d, (%rax) xorl %r12d, %r12d testb $0x18, %bl je 0x48b6c movl $0x1004, %esi # imm = 0x1004 movl $0x5, %edi movq %r15, %rdx xorl %eax, %eax callq 0x4e80f movq %r12, %rax addq $0x8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
my_once_alloc: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx push rax mov rbx, rsi mov r14, rdi add r14, 7 and r14, 0FFFFFFFFFFFFFFF8h lea r13, my_once_root_block mov rcx, [r13+0] xor eax, eax test rcx, rcx jz short loc_48AC6 loc_48AA6: mov r13, rcx mov rcx, [rcx+8] cmp rcx, r14 jnb short loc_48B0F cmp rcx, rax cmova rax, rcx mov rcx, [r13+0] test rcx, rcx jnz short loc_48AA6 shl rax, 2 loc_48AC6: lea rcx, [r14+18h] lea rdx, my_once_extra mov edx, [rdx] cmp rcx, rdx mov r15, rdx cmova r15, rcx cmp rax, rdx cmovnb r15, rcx mov rdi, r15 call _malloc test rax, rax jz short loc_48B40 mov qword ptr [rax], 0 mov [rax+10h], r15 add r15, 0FFFFFFFFFFFFFFE8h mov [rax+8], r15 mov [r13+0], rax mov rcx, [rax+8] mov r13, rax loc_48B0F: mov r12, [r13+10h] sub r12, rcx add r12, r13 sub rcx, r14 mov [r13+8], rcx test bl, 20h jz short loc_48B6C mov rdi, r12 xor esi, esi mov rdx, r14 add rsp, 8 pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp jmp _memset loc_48B40: call ___errno_location mov r14d, [rax] call _my_thread_var mov [rax], r14d xor r12d, r12d test bl, 18h jz short loc_48B6C mov esi, 1004h mov edi, 5 mov rdx, r15 xor eax, eax call my_error loc_48B6C: mov rax, r12 add rsp, 8 pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
long long my_once_alloc(long long a1, char a2) { unsigned long long v2; // r14 _QWORD *v3; // r13 _QWORD *v4; // rcx unsigned long long v5; // rax unsigned long long v6; // rcx unsigned long long v7; // r15 _QWORD *v8; // rax char *v9; // r12 int v11; // r14d int v12; // ecx int v13; // r8d int v14; // r9d v2 = (a1 + 7) & 0xFFFFFFFFFFFFFFF8LL; v3 = &my_once_root_block; v4 = (_QWORD *)my_once_root_block; v5 = 0LL; if ( my_once_root_block ) { while ( 1 ) { v3 = v4; v6 = v4[1]; if ( v6 >= v2 ) break; if ( v6 > v5 ) v5 = v6; v4 = (_QWORD *)*v3; if ( !*v3 ) { v5 *= 4LL; goto LABEL_7; } } } else { LABEL_7: v7 = my_once_extra; if ( v2 + 24 > my_once_extra ) v7 = v2 + 24; if ( v5 >= my_once_extra ) v7 = v2 + 24; v8 = (_QWORD *)malloc(v7); if ( !v8 ) { v11 = *(_DWORD *)__errno_location(v7); *(_DWORD *)my_thread_var(v7) = v11; v9 = 0LL; if ( (a2 & 0x18) != 0 ) my_error(5, 4100, v7, v12, v13, v14); return (long long)v9; } *v8 = 0LL; v8[2] = v7; v8[1] = v7 - 24; *v3 = v8; v6 = v8[1]; v3 = v8; } v9 = (char *)v3 + v3[2] - v6; v3[1] = v6 - v2; if ( (a2 & 0x20) != 0 ) return memset(v9, 0LL, v2); return (long long)v9; }
my_once_alloc: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX PUSH RAX MOV RBX,RSI MOV R14,RDI ADD R14,0x7 AND R14,-0x8 LEA R13,[0x4d6720] MOV RCX,qword ptr [R13] XOR EAX,EAX TEST RCX,RCX JZ 0x00148ac6 LAB_00148aa6: MOV R13,RCX MOV RCX,qword ptr [RCX + 0x8] CMP RCX,R14 JNC 0x00148b0f CMP RCX,RAX CMOVA RAX,RCX MOV RCX,qword ptr [R13] TEST RCX,RCX JNZ 0x00148aa6 SHL RAX,0x2 LAB_00148ac6: LEA RCX,[R14 + 0x18] LEA RDX,[0x41ca20] MOV EDX,dword ptr [RDX] CMP RCX,RDX MOV R15,RDX CMOVA R15,RCX CMP RAX,RDX CMOVNC R15,RCX MOV RDI,R15 CALL 0x00126480 TEST RAX,RAX JZ 0x00148b40 MOV qword ptr [RAX],0x0 MOV qword ptr [RAX + 0x10],R15 ADD R15,-0x18 MOV qword ptr [RAX + 0x8],R15 MOV qword ptr [R13],RAX MOV RCX,qword ptr [RAX + 0x8] MOV R13,RAX LAB_00148b0f: MOV R12,qword ptr [R13 + 0x10] SUB R12,RCX ADD R12,R13 SUB RCX,R14 MOV qword ptr [R13 + 0x8],RCX TEST BL,0x20 JZ 0x00148b6c MOV RDI,R12 XOR ESI,ESI MOV RDX,R14 ADD RSP,0x8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP JMP 0x001261c0 LAB_00148b40: CALL 0x00126060 MOV R14D,dword ptr [RAX] CALL 0x00149666 MOV dword ptr [RAX],R14D XOR R12D,R12D TEST BL,0x18 JZ 0x00148b6c MOV ESI,0x1004 MOV EDI,0x5 MOV RDX,R15 XOR EAX,EAX CALL 0x0014e80f LAB_00148b6c: MOV RAX,R12 ADD RSP,0x8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
void * my_once_alloc(long param_1,ulong param_2) { int iVar1; int8 *puVar2; ulong uVar3; int8 *puVar4; int *piVar5; ulong uVar6; ulong uVar7; void *pvVar8; int8 *puVar9; ulong __n; ulong __size; __n = param_1 + 7U & 0xfffffffffffffff8; uVar3 = 0; puVar2 = my_once_root_block; puVar9 = &my_once_root_block; if (my_once_root_block != (int8 *)0x0) { do { puVar4 = puVar2; uVar6 = puVar4[1]; if (__n <= uVar6) goto LAB_00148b0f; if (uVar3 < uVar6) { uVar3 = uVar6; } puVar2 = (int8 *)*puVar4; } while ((int8 *)*puVar4 != (int8 *)0x0); uVar3 = uVar3 << 2; puVar9 = puVar4; } uVar6 = __n + 0x18; uVar7 = (ulong)my_once_extra; __size = uVar7; if (uVar7 < uVar6) { __size = uVar6; } if (uVar7 <= uVar3) { __size = uVar6; } puVar4 = (int8 *)malloc(__size); if (puVar4 == (int8 *)0x0) { piVar5 = __errno_location(); iVar1 = *piVar5; piVar5 = (int *)_my_thread_var(); *piVar5 = iVar1; pvVar8 = (void *)0x0; if ((param_2 & 0x18) != 0) { my_error(5,0x1004,__size); } } else { *puVar4 = 0; puVar4[2] = __size; puVar4[1] = __size - 0x18; *puVar9 = puVar4; uVar6 = puVar4[1]; LAB_00148b0f: pvVar8 = (void *)((puVar4[2] - uVar6) + (long)puVar4); puVar4[1] = uVar6 - __n; if ((param_2 & 0x20) != 0) { pvVar8 = memset(pvVar8,0,__n); return pvVar8; } } return pvVar8; }
31,876
unsigned long google::protobuf::internal::RepeatedPtrFieldBase::SpaceUsedExcludingSelfLong<google::protobuf::RepeatedPtrField<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>::TypeHandler>() const
aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/repeated_ptr_field.h
size_t SpaceUsedExcludingSelfLong() const { size_t allocated_bytes = static_cast<size_t>(total_size_) * sizeof(void*); if (rep_ != nullptr) { for (int i = 0; i < rep_->allocated_size; ++i) { allocated_bytes += TypeHandler::SpaceUsedLong(*cast<TypeHandler>(rep_->elements[i])); } allocated_bytes += kRepHeaderSize; } return allocated_bytes; }
O0
c
unsigned long google::protobuf::internal::RepeatedPtrFieldBase::SpaceUsedExcludingSelfLong<google::protobuf::RepeatedPtrField<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>::TypeHandler>() const: subq $0x28, %rsp movq %rdi, 0x20(%rsp) movq 0x20(%rsp), %rax movq %rax, 0x8(%rsp) movslq 0xc(%rax), %rcx shlq $0x3, %rcx movq %rcx, 0x18(%rsp) cmpq $0x0, 0x10(%rax) je 0x1d43a5 movl $0x0, 0x14(%rsp) movq 0x8(%rsp), %rcx movl 0x14(%rsp), %eax movq 0x10(%rcx), %rcx cmpl (%rcx), %eax jge 0x1d4397 movq 0x8(%rsp), %rax movq 0x10(%rax), %rax movslq 0x14(%rsp), %rcx movq 0x8(%rax,%rcx,8), %rdi callq 0x1d3fc0 movq %rax, %rdi callq 0x1c43f0 addq 0x18(%rsp), %rax movq %rax, 0x18(%rsp) movl 0x14(%rsp), %eax addl $0x1, %eax movl %eax, 0x14(%rsp) jmp 0x1d434f movq 0x18(%rsp), %rax addq $0x8, %rax movq %rax, 0x18(%rsp) movq 0x18(%rsp), %rax addq $0x28, %rsp retq nop
_ZNK6google8protobuf8internal20RepeatedPtrFieldBase26SpaceUsedExcludingSelfLongINS0_16RepeatedPtrFieldINS0_7MessageEE11TypeHandlerEEEmv: sub rsp, 28h mov [rsp+28h+var_8], rdi mov rax, [rsp+28h+var_8] mov [rsp+28h+var_20], rax movsxd rcx, dword ptr [rax+0Ch] shl rcx, 3 mov [rsp+28h+var_10], rcx cmp qword ptr [rax+10h], 0 jz short loc_1D43A5 mov [rsp+28h+var_14], 0 loc_1D434F: mov rcx, [rsp+28h+var_20] mov eax, [rsp+28h+var_14] mov rcx, [rcx+10h] cmp eax, [rcx] jge short loc_1D4397 mov rax, [rsp+28h+var_20] mov rax, [rax+10h] movsxd rcx, [rsp+28h+var_14] mov rdi, [rax+rcx*8+8] call _ZN6google8protobuf8internal20RepeatedPtrFieldBase4castINS0_16RepeatedPtrFieldINS0_7MessageEE11TypeHandlerEEEPNT_4TypeEPv; google::protobuf::internal::RepeatedPtrFieldBase::cast<google::protobuf::RepeatedPtrField<google::protobuf::Message>::TypeHandler>(void *) mov rdi, rax call _ZN6google8protobuf8internal18GenericTypeHandlerINS0_7MessageEE13SpaceUsedLongERKS3_; google::protobuf::internal::GenericTypeHandler<google::protobuf::Message>::SpaceUsedLong(google::protobuf::Message const&) add rax, [rsp+28h+var_10] mov [rsp+28h+var_10], rax mov eax, [rsp+28h+var_14] add eax, 1 mov [rsp+28h+var_14], eax jmp short loc_1D434F loc_1D4397: mov rax, [rsp+28h+var_10] add rax, 8 mov [rsp+28h+var_10], rax loc_1D43A5: mov rax, [rsp+28h+var_10] add rsp, 28h retn
long long google::protobuf::internal::RepeatedPtrFieldBase::SpaceUsedExcludingSelfLong<google::protobuf::RepeatedPtrField<google::protobuf::Message>::TypeHandler>( long long a1) { long long v1; // rax int i; // [rsp+14h] [rbp-14h] long long v4; // [rsp+18h] [rbp-10h] v4 = 8LL * *(int *)(a1 + 12); if ( *(_QWORD *)(a1 + 16) ) { for ( i = 0; i < **(_DWORD **)(a1 + 16); ++i ) { v1 = google::protobuf::internal::RepeatedPtrFieldBase::cast<google::protobuf::RepeatedPtrField<google::protobuf::Message>::TypeHandler>(*(_QWORD *)(*(_QWORD *)(a1 + 16) + 8LL * i + 8)); v4 += google::protobuf::internal::GenericTypeHandler<google::protobuf::Message>::SpaceUsedLong(v1); } v4 += 8LL; } return v4; }
31,877
unsigned long google::protobuf::internal::RepeatedPtrFieldBase::SpaceUsedExcludingSelfLong<google::protobuf::RepeatedPtrField<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>::TypeHandler>() const
aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/repeated_ptr_field.h
size_t SpaceUsedExcludingSelfLong() const { size_t allocated_bytes = static_cast<size_t>(total_size_) * sizeof(void*); if (rep_ != nullptr) { for (int i = 0; i < rep_->allocated_size; ++i) { allocated_bytes += TypeHandler::SpaceUsedLong(*cast<TypeHandler>(rep_->elements[i])); } allocated_bytes += kRepHeaderSize; } return allocated_bytes; }
O3
c
unsigned long google::protobuf::internal::RepeatedPtrFieldBase::SpaceUsedExcludingSelfLong<google::protobuf::RepeatedPtrField<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>::TypeHandler>() const: pushq %r15 pushq %r14 pushq %rbx movslq 0xc(%rdi), %rbx shlq $0x3, %rbx movq 0x10(%rdi), %rax testq %rax, %rax je 0x84019 cmpl $0x0, (%rax) jle 0x84015 movq %rdi, %r14 xorl %r15d, %r15d movq 0x8(%rax,%r15,8), %rdi callq 0x78d70 addq %rax, %rbx addq $0x20, %rbx incq %r15 movq 0x10(%r14), %rax movslq (%rax), %rcx cmpq %rcx, %r15 jl 0x83ff5 addq $0x8, %rbx movq %rbx, %rax popq %rbx popq %r14 popq %r15 retq
_ZNK6google8protobuf8internal20RepeatedPtrFieldBase26SpaceUsedExcludingSelfLongINS0_16RepeatedPtrFieldINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEE11TypeHandlerEEEmv: push r15 push r14 push rbx movsxd rbx, dword ptr [rdi+0Ch] shl rbx, 3 mov rax, [rdi+10h] test rax, rax jz short loc_84019 cmp dword ptr [rax], 0 jle short loc_84015 mov r14, rdi xor r15d, r15d loc_83FF5: mov rdi, [rax+r15*8+8] call _ZN6google8protobuf8internal32StringSpaceUsedExcludingSelfLongERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; google::protobuf::internal::StringSpaceUsedExcludingSelfLong(std::string const&) add rbx, rax add rbx, 20h ; ' ' inc r15 mov rax, [r14+10h] movsxd rcx, dword ptr [rax] cmp r15, rcx jl short loc_83FF5 loc_84015: add rbx, 8 loc_84019: mov rax, rbx pop rbx pop r14 pop r15 retn
long long google::protobuf::internal::RepeatedPtrFieldBase::SpaceUsedExcludingSelfLong<google::protobuf::RepeatedPtrField<std::string>::TypeHandler>( long long a1) { long long v1; // rbx int *v2; // rax long long v3; // r15 v1 = 8LL * *(int *)(a1 + 12); v2 = *(int **)(a1 + 16); if ( v2 ) { if ( *v2 > 0 ) { v3 = 0LL; do { v1 += google::protobuf::internal::StringSpaceUsedExcludingSelfLong(*(unsigned long long **)&v2[2 * v3++ + 2]) + 32; v2 = *(int **)(a1 + 16); } while ( v3 < *v2 ); } v1 += 8LL; } return v1; }
SpaceUsedExcludingSelfLong<google::protobuf::RepeatedPtrField<std::__cxx11::string>::TypeHandler>: PUSH R15 PUSH R14 PUSH RBX MOVSXD RBX,dword ptr [RDI + 0xc] SHL RBX,0x3 MOV RAX,qword ptr [RDI + 0x10] TEST RAX,RAX JZ 0x00184019 CMP dword ptr [RAX],0x0 JLE 0x00184015 MOV R14,RDI XOR R15D,R15D LAB_00183ff5: MOV RDI,qword ptr [RAX + R15*0x8 + 0x8] CALL 0x00178d70 ADD RBX,RAX ADD RBX,0x20 INC R15 MOV RAX,qword ptr [R14 + 0x10] MOVSXD RCX,dword ptr [RAX] CMP R15,RCX JL 0x00183ff5 LAB_00184015: ADD RBX,0x8 LAB_00184019: MOV RAX,RBX POP RBX POP R14 POP R15 RET
/* unsigned long google::protobuf::internal::RepeatedPtrFieldBase::SpaceUsedExcludingSelfLong<google::protobuf::RepeatedPtrField<std::__cxx11::string >::TypeHandler>() const */ ulong __thiscall google::protobuf::internal::RepeatedPtrFieldBase:: SpaceUsedExcludingSelfLong<google::protobuf::RepeatedPtrField<std::__cxx11::string>::TypeHandler> (RepeatedPtrFieldBase *this) { int *piVar1; long lVar2; ulong uVar3; long lVar4; uVar3 = (long)*(int *)(this + 0xc) << 3; piVar1 = *(int **)(this + 0x10); if (piVar1 != (int *)0x0) { if (0 < *piVar1) { lVar4 = 0; do { lVar2 = StringSpaceUsedExcludingSelfLong(*(string **)(piVar1 + lVar4 * 2 + 2)); uVar3 = uVar3 + lVar2 + 0x20; lVar4 = lVar4 + 1; piVar1 = *(int **)(this + 0x10); } while (lVar4 < *piVar1); } uVar3 = uVar3 + 8; } return uVar3; }
31,878
minja::Context::~Context()
monkey531[P]llama/common/minja.hpp
virtual ~Context() {}
O3
cpp
minja::Context::~Context(): pushq %r14 pushq %rbx pushq %rax movq %rdi, %rbx leaq 0x945f6(%rip), %rax # 0x155120 addq $0x10, %rax movq %rax, (%rdi) movq 0x70(%rdi), %rdi testq %rdi, %rdi je 0xc0b3f callq 0x516f8 leaq 0x58(%rbx), %r14 movq %r14, %rdi xorl %esi, %esi callq 0x89876 movq %r14, %rdi callq 0x8eb30 movq 0x50(%rbx), %rdi testq %rdi, %rdi je 0xc0b63 callq 0x516f8 movq 0x40(%rbx), %rdi testq %rdi, %rdi je 0xc0b71 callq 0x516f8 movq 0x30(%rbx), %rdi testq %rdi, %rdi je 0xc0b7f callq 0x516f8 movq 0x20(%rbx), %rdi testq %rdi, %rdi je 0xc0bb4 movq 0x953f1(%rip), %rax # 0x155f80 cmpb $0x0, (%rax) je 0xc0b9f movl 0xc(%rdi), %eax leal -0x1(%rax), %ecx movl %ecx, 0xc(%rdi) jmp 0xc0ba9 movl $0xffffffff, %eax # imm = 0xFFFFFFFF lock xaddl %eax, 0xc(%rdi) cmpl $0x1, %eax jne 0xc0bb4 movq (%rdi), %rax callq *0x18(%rax) movq 0x10(%rbx), %rdi testq %rdi, %rdi je 0xc0bf0 movq 0x953bc(%rip), %rax # 0x155f80 cmpb $0x0, (%rax) je 0xc0bd4 movl 0xc(%rdi), %eax leal -0x1(%rax), %ecx movl %ecx, 0xc(%rdi) jmp 0xc0bde movl $0xffffffff, %eax # imm = 0xFFFFFFFF lock xaddl %eax, 0xc(%rdi) cmpl $0x1, %eax jne 0xc0bf0 movq (%rdi), %rax addq $0x8, %rsp popq %rbx popq %r14 jmpq *0x18(%rax) addq $0x8, %rsp popq %rbx popq %r14 retq
_ZN5minja7ContextD2Ev: push r14 push rbx push rax mov rbx, rdi lea rax, _ZTVN5minja7ContextE; `vtable for'minja::Context add rax, 10h mov [rdi], rax mov rdi, [rdi+70h] test rdi, rdi jz short loc_C0B3F call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void) loc_C0B3F: lea r14, [rbx+58h] 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+50h] test rdi, rdi jz short loc_C0B63 call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void) loc_C0B63: mov rdi, [rbx+40h] test rdi, rdi jz short loc_C0B71 call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void) loc_C0B71: mov rdi, [rbx+30h] test rdi, rdi jz short loc_C0B7F call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void) loc_C0B7F: mov rdi, [rbx+20h] test rdi, rdi jz short loc_C0BB4 mov rax, cs:__libc_single_threaded_ptr cmp byte ptr [rax], 0 jz short loc_C0B9F mov eax, [rdi+0Ch] lea ecx, [rax-1] mov [rdi+0Ch], ecx jmp short loc_C0BA9 loc_C0B9F: mov eax, 0FFFFFFFFh lock xadd [rdi+0Ch], eax loc_C0BA9: cmp eax, 1 jnz short loc_C0BB4 mov rax, [rdi] call qword ptr [rax+18h] loc_C0BB4: mov rdi, [rbx+10h] test rdi, rdi jz short loc_C0BF0 mov rax, cs:__libc_single_threaded_ptr cmp byte ptr [rax], 0 jz short loc_C0BD4 mov eax, [rdi+0Ch] lea ecx, [rax-1] mov [rdi+0Ch], ecx jmp short loc_C0BDE loc_C0BD4: mov eax, 0FFFFFFFFh lock xadd [rdi+0Ch], eax loc_C0BDE: cmp eax, 1 jnz short loc_C0BF0 mov rax, [rdi] add rsp, 8 pop rbx pop r14 jmp qword ptr [rax+18h] loc_C0BF0: add rsp, 8 pop rbx pop r14 retn
void minja::Context::~Context(minja::Context *this) { volatile signed __int32 *v2; // rdi volatile signed __int32 *v3; // rdi volatile signed __int32 *v4; // rdi volatile signed __int32 *v5; // rdi volatile signed __int32 *v6; // rdi signed __int32 v7; // eax volatile signed __int32 *v8; // rdi signed __int32 v9; // eax *(_QWORD *)this = &`vtable for'minja::Context + 2; v2 = (volatile signed __int32 *)*((_QWORD *)this + 14); if ( v2 ) std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v2); 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 *)this + 88); 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((char *)this + 88); v3 = (volatile signed __int32 *)*((_QWORD *)this + 10); if ( v3 ) std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v3); v4 = (volatile signed __int32 *)*((_QWORD *)this + 8); if ( v4 ) std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v4); v5 = (volatile signed __int32 *)*((_QWORD *)this + 6); if ( v5 ) std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v5); v6 = (volatile signed __int32 *)*((_QWORD *)this + 4); if ( v6 ) { if ( _libc_single_threaded ) { v7 = *((_DWORD *)v6 + 3); *((_DWORD *)v6 + 3) = v7 - 1; } else { v7 = _InterlockedExchangeAdd(v6 + 3, 0xFFFFFFFF); } if ( v7 == 1 ) (*(void ( **)(volatile signed __int32 *, _QWORD))(*(_QWORD *)v6 + 24LL))(v6, 0LL); } v8 = (volatile signed __int32 *)*((_QWORD *)this + 2); if ( v8 ) { if ( _libc_single_threaded ) { v9 = *((_DWORD *)v8 + 3); *((_DWORD *)v8 + 3) = v9 - 1; } else { v9 = _InterlockedExchangeAdd(v8 + 3, 0xFFFFFFFF); } if ( v9 == 1 ) (*(void ( **)(volatile signed __int32 *, _QWORD))(*(_QWORD *)v8 + 24LL))(v8, 0LL); } }
~Context: PUSH R14 PUSH RBX PUSH RAX MOV RBX,RDI LEA RAX,[0x255120] ADD RAX,0x10 MOV qword ptr [RDI],RAX MOV RDI,qword ptr [RDI + 0x70] TEST RDI,RDI JZ 0x001c0b3f CALL 0x001516f8 LAB_001c0b3f: LEA R14,[RBX + 0x58] MOV RDI,R14 XOR ESI,ESI CALL 0x00189876 MOV RDI,R14 CALL 0x0018eb30 MOV RDI,qword ptr [RBX + 0x50] TEST RDI,RDI JZ 0x001c0b63 CALL 0x001516f8 LAB_001c0b63: MOV RDI,qword ptr [RBX + 0x40] TEST RDI,RDI JZ 0x001c0b71 CALL 0x001516f8 LAB_001c0b71: MOV RDI,qword ptr [RBX + 0x30] TEST RDI,RDI JZ 0x001c0b7f CALL 0x001516f8 LAB_001c0b7f: MOV RDI,qword ptr [RBX + 0x20] TEST RDI,RDI JZ 0x001c0bb4 MOV RAX,qword ptr [0x00255f80] CMP byte ptr [RAX],0x0 JZ 0x001c0b9f MOV EAX,dword ptr [RDI + 0xc] LEA ECX,[RAX + -0x1] MOV dword ptr [RDI + 0xc],ECX JMP 0x001c0ba9 LAB_001c0b9f: MOV EAX,0xffffffff XADD.LOCK dword ptr [RDI + 0xc],EAX LAB_001c0ba9: CMP EAX,0x1 JNZ 0x001c0bb4 MOV RAX,qword ptr [RDI] CALL qword ptr [RAX + 0x18] LAB_001c0bb4: MOV RDI,qword ptr [RBX + 0x10] TEST RDI,RDI JZ 0x001c0bf0 MOV RAX,qword ptr [0x00255f80] CMP byte ptr [RAX],0x0 JZ 0x001c0bd4 MOV EAX,dword ptr [RDI + 0xc] LEA ECX,[RAX + -0x1] MOV dword ptr [RDI + 0xc],ECX JMP 0x001c0bde LAB_001c0bd4: MOV EAX,0xffffffff XADD.LOCK dword ptr [RDI + 0xc],EAX LAB_001c0bde: CMP EAX,0x1 JNZ 0x001c0bf0 MOV RAX,qword ptr [RDI] ADD RSP,0x8 POP RBX POP R14 JMP qword ptr [RAX + 0x18] LAB_001c0bf0: ADD RSP,0x8 POP RBX POP R14 RET
/* minja::Context::~Context() */ void __thiscall minja::Context::~Context(Context *this) { int *piVar1; long *plVar2; int iVar3; *(int ***)this = &PTR__Context_00255130; if (*(_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> **)(this + 0x70) != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) { std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release (*(_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> **)(this + 0x70)); } 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> ::assert_invariant(SUB81((data *)(this + 0x58),0)); 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> ::data::~data((data *)(this + 0x58)); if (*(_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> **)(this + 0x50) != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) { std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release (*(_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> **)(this + 0x50)); } if (*(_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> **)(this + 0x40) != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) { std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release (*(_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> **)(this + 0x40)); } if (*(_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> **)(this + 0x30) != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) { std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release (*(_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> **)(this + 0x30)); } plVar2 = *(long **)(this + 0x20); if (plVar2 != (long *)0x0) { if (*PTR___libc_single_threaded_00255f80 == '\0') { LOCK(); piVar1 = (int *)((long)plVar2 + 0xc); iVar3 = *piVar1; *piVar1 = *piVar1 + -1; UNLOCK(); } else { iVar3 = *(int *)((long)plVar2 + 0xc); *(int *)((long)plVar2 + 0xc) = iVar3 + -1; } if (iVar3 == 1) { (**(code **)(*plVar2 + 0x18))(); } } plVar2 = *(long **)(this + 0x10); if (plVar2 != (long *)0x0) { if (*PTR___libc_single_threaded_00255f80 == '\0') { LOCK(); piVar1 = (int *)((long)plVar2 + 0xc); iVar3 = *piVar1; *piVar1 = *piVar1 + -1; UNLOCK(); } else { iVar3 = *(int *)((long)plVar2 + 0xc); *(int *)((long)plVar2 + 0xc) = iVar3 + -1; } if (iVar3 == 1) { /* WARNING: Could not recover jumptable at 0x001c0bed. Too many branches */ /* WARNING: Treating indirect jump as call */ (**(code **)(*plVar2 + 0x18))(); return; } } return; }
31,879
ggml_opt_result_reset
Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml-opt.cpp
void ggml_opt_result_reset(ggml_opt_result_t result) { result->ndata = 0; result->loss.clear(); result->pred.clear(); result->ncorrect = 0; }
O1
cpp
ggml_opt_result_reset: movq $0x0, (%rdi) movq 0x8(%rdi), %rax cmpq %rax, 0x10(%rdi) je 0x2b99f movq %rax, 0x10(%rdi) movq 0x20(%rdi), %rax cmpq %rax, 0x28(%rdi) je 0x2b9ad movq %rax, 0x28(%rdi) movq $0x0, 0x38(%rdi) retq
ggml_opt_result_reset: mov qword ptr [rdi], 0 mov rax, [rdi+8] cmp [rdi+10h], rax jz short loc_2B99F mov [rdi+10h], rax loc_2B99F: mov rax, [rdi+20h] cmp [rdi+28h], rax jz short loc_2B9AD mov [rdi+28h], rax loc_2B9AD: mov qword ptr [rdi+38h], 0 retn
long long ggml_opt_result_reset(_QWORD *a1) { long long v1; // rax long long result; // rax *a1 = 0LL; v1 = a1[1]; if ( a1[2] != v1 ) a1[2] = v1; result = a1[4]; if ( a1[5] != result ) a1[5] = result; a1[7] = 0LL; return result; }
ggml_opt_result_reset: MOV qword ptr [RDI],0x0 MOV RAX,qword ptr [RDI + 0x8] CMP qword ptr [RDI + 0x10],RAX JZ 0x0012b99f MOV qword ptr [RDI + 0x10],RAX LAB_0012b99f: MOV RAX,qword ptr [RDI + 0x20] CMP qword ptr [RDI + 0x28],RAX JZ 0x0012b9ad MOV qword ptr [RDI + 0x28],RAX LAB_0012b9ad: MOV qword ptr [RDI + 0x38],0x0 RET
void ggml_opt_result_reset(int8 *param_1) { *param_1 = 0; if (param_1[2] != param_1[1]) { param_1[2] = param_1[1]; } if (param_1[5] != param_1[4]) { param_1[5] = param_1[4]; } param_1[7] = 0; return; }
31,880
ggml_opt_result_reset
Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml-opt.cpp
void ggml_opt_result_reset(ggml_opt_result_t result) { result->ndata = 0; result->loss.clear(); result->pred.clear(); result->ncorrect = 0; }
O2
cpp
ggml_opt_result_reset: andq $0x0, (%rdi) movq 0x8(%rdi), %rax cmpq %rax, 0x10(%rdi) je 0x2f9d1 movq %rax, 0x10(%rdi) movq 0x20(%rdi), %rax cmpq %rax, 0x28(%rdi) je 0x2f9df movq %rax, 0x28(%rdi) andq $0x0, 0x38(%rdi) retq
ggml_opt_result_reset: and qword ptr [rdi], 0 mov rax, [rdi+8] cmp [rdi+10h], rax jz short loc_2F9D1 mov [rdi+10h], rax loc_2F9D1: mov rax, [rdi+20h] cmp [rdi+28h], rax jz short loc_2F9DF mov [rdi+28h], rax loc_2F9DF: and qword ptr [rdi+38h], 0 retn
long long ggml_opt_result_reset(_QWORD *a1) { long long v1; // rax long long result; // rax *a1 = 0LL; v1 = a1[1]; if ( a1[2] != v1 ) a1[2] = v1; result = a1[4]; if ( a1[5] != result ) a1[5] = result; a1[7] = 0LL; return result; }
ggml_opt_result_reset: AND qword ptr [RDI],0x0 MOV RAX,qword ptr [RDI + 0x8] CMP qword ptr [RDI + 0x10],RAX JZ 0x0012f9d1 MOV qword ptr [RDI + 0x10],RAX LAB_0012f9d1: MOV RAX,qword ptr [RDI + 0x20] CMP qword ptr [RDI + 0x28],RAX JZ 0x0012f9df MOV qword ptr [RDI + 0x28],RAX LAB_0012f9df: AND qword ptr [RDI + 0x38],0x0 RET
void ggml_opt_result_reset(int8 *param_1) { *param_1 = 0; if (param_1[2] != param_1[1]) { param_1[2] = param_1[1]; } if (param_1[5] != param_1[4]) { param_1[5] = param_1[4]; } param_1[7] = 0; return; }
31,881
ggml_opt_result_reset
Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml-opt.cpp
void ggml_opt_result_reset(ggml_opt_result_t result) { result->ndata = 0; result->loss.clear(); result->pred.clear(); result->ncorrect = 0; }
O3
cpp
ggml_opt_result_reset: movq $0x0, (%rdi) movq 0x8(%rdi), %rax cmpq %rax, 0x10(%rdi) je 0x2a413 movq %rax, 0x10(%rdi) movq 0x20(%rdi), %rax cmpq %rax, 0x28(%rdi) je 0x2a421 movq %rax, 0x28(%rdi) movq $0x0, 0x38(%rdi) retq
ggml_opt_result_reset: mov qword ptr [rdi], 0 mov rax, [rdi+8] cmp [rdi+10h], rax jz short loc_2A413 mov [rdi+10h], rax loc_2A413: mov rax, [rdi+20h] cmp [rdi+28h], rax jz short loc_2A421 mov [rdi+28h], rax loc_2A421: mov qword ptr [rdi+38h], 0 retn
long long ggml_opt_result_reset(_QWORD *a1) { long long v1; // rax long long result; // rax *a1 = 0LL; v1 = a1[1]; if ( a1[2] != v1 ) a1[2] = v1; result = a1[4]; if ( a1[5] != result ) a1[5] = result; a1[7] = 0LL; return result; }
ggml_opt_result_reset: MOV qword ptr [RDI],0x0 MOV RAX,qword ptr [RDI + 0x8] CMP qword ptr [RDI + 0x10],RAX JZ 0x0012a413 MOV qword ptr [RDI + 0x10],RAX LAB_0012a413: MOV RAX,qword ptr [RDI + 0x20] CMP qword ptr [RDI + 0x28],RAX JZ 0x0012a421 MOV qword ptr [RDI + 0x28],RAX LAB_0012a421: MOV qword ptr [RDI + 0x38],0x0 RET
void ggml_opt_result_reset(int8 *param_1) { *param_1 = 0; if (param_1[2] != param_1[1]) { param_1[2] = param_1[1]; } if (param_1[5] != param_1[4]) { param_1[5] = param_1[4]; } param_1[7] = 0; return; }
31,882
int10_to_str
eloqsql/strings/int2str.c
char *int10_to_str(long int val,char *dst,int radix) { char buffer[65]; register char *p; long int new_val; unsigned long int uval = (unsigned long int) val; if (radix < 0) /* -10 */ { if (val < 0) { *dst++ = '-'; /* Avoid integer overflow in (-val) for LONGLONG_MIN (BUG#31799). */ uval = (unsigned long int)0 - uval; } } p = &buffer[sizeof(buffer)-1]; *p = '\0'; 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; } while ((*dst++ = *p++) != 0) ; return dst-1; }
O3
c
int10_to_str: pushq %rbp movq %rsp, %rbp subq $0x50, %rsp movq %fs:0x28, %rax movq %rax, -0x8(%rbp) testl %edx, %edx setns %al testq %rdi, %rdi setns %cl orb %al, %cl jne 0xd58d3 movb $0x2d, (%rsi) incq %rsi negq %rdi leaq -0x11(%rbp), %r8 movabsq $-0x3333333333333333, %r9 # imm = 0xCCCCCCCCCCCCCCCD movq %rdi, %rax mulq %r9 movq %rdx, %rcx movb $0x0, 0x1(%r8) shrq $0x3, %rcx imull $0xf6, %ecx, %eax addl %edi, %eax addb $0x30, %al movb %al, (%r8) cmpq $0xa, %rdi jb 0xd592a movq %rcx, %rax mulq %r9 shrq $0x3, %rdx imull $0xf6, %edx, %eax addl %ecx, %eax addb $0x30, %al movb %al, -0x1(%r8) decq %r8 cmpq $0x9, %rcx movq %rdx, %rcx ja 0xd5906 decq %rsi movb (%r8), %al incq %r8 movb %al, 0x1(%rsi) incq %rsi testb %al, %al jne 0xd592d movq %fs:0x28, %rax cmpq -0x8(%rbp), %rax jne 0xd5955 movq %rsi, %rax addq $0x50, %rsp popq %rbp retq callq 0x29250 nop
int10_to_str: push rbp mov rbp, rsp sub rsp, 50h mov rax, fs:28h mov [rbp+var_8], rax test edx, edx setns al test rdi, rdi setns cl or cl, al jnz short loc_D58D3 mov byte ptr [rsi], 2Dh ; '-' inc rsi neg rdi loc_D58D3: lea r8, [rbp+var_11] mov r9, 0CCCCCCCCCCCCCCCDh mov rax, rdi mul r9 mov rcx, rdx mov byte ptr [r8+1], 0 shr rcx, 3 imul eax, ecx, 0F6h add eax, edi add al, 30h ; '0' mov [r8], al cmp rdi, 0Ah jb short loc_D592A loc_D5906: mov rax, rcx mul r9 shr rdx, 3 imul eax, edx, 0F6h add eax, ecx add al, 30h ; '0' mov [r8-1], al dec r8 cmp rcx, 9 mov rcx, rdx ja short loc_D5906 loc_D592A: dec rsi loc_D592D: mov al, [r8] inc r8 mov [rsi+1], al inc rsi test al, al jnz short loc_D592D mov rax, fs:28h cmp rax, [rbp+var_8] jnz short loc_D5955 mov rax, rsi add rsp, 50h pop rbp retn loc_D5955: call ___stack_chk_fail
_BYTE * int10_to_str(unsigned long long a1, _BYTE *a2, int a3) { char *v3; // r8 unsigned long long v4; // rcx bool v5; // cc _BYTE *v6; // rsi char v7; // al _BYTE v9[9]; // [rsp+3Fh] [rbp-11h] BYREF unsigned long long v10; // [rsp+48h] [rbp-8h] v10 = __readfsqword(0x28u); if ( a3 < 0 && (a1 & 0x8000000000000000LL) != 0LL ) { *a2++ = 45; a1 = -(long long)a1; } v3 = v9; v9[1] = 0; v4 = a1 / 0xA; v9[0] = a1 % 0xA + 48; if ( a1 >= 0xA ) { do { *--v3 = v4 % 0xA + 48; v5 = v4 <= 9; v4 /= 0xAuLL; } while ( !v5 ); } v6 = a2 - 1; do { v7 = *v3++; *++v6 = v7; } while ( v7 ); return v6; }
int10_to_str: PUSH RBP MOV RBP,RSP SUB RSP,0x50 MOV RAX,qword ptr FS:[0x28] MOV qword ptr [RBP + -0x8],RAX TEST EDX,EDX SETNS AL TEST RDI,RDI SETNS CL OR CL,AL JNZ 0x001d58d3 MOV byte ptr [RSI],0x2d INC RSI NEG RDI LAB_001d58d3: LEA R8,[RBP + -0x11] MOV R9,-0x3333333333333333 MOV RAX,RDI MUL R9 MOV RCX,RDX MOV byte ptr [R8 + 0x1],0x0 SHR RCX,0x3 IMUL EAX,ECX,0xf6 ADD EAX,EDI ADD AL,0x30 MOV byte ptr [R8],AL CMP RDI,0xa JC 0x001d592a LAB_001d5906: MOV RAX,RCX MUL R9 SHR RDX,0x3 IMUL EAX,EDX,0xf6 ADD EAX,ECX ADD AL,0x30 MOV byte ptr [R8 + -0x1],AL DEC R8 CMP RCX,0x9 MOV RCX,RDX JA 0x001d5906 LAB_001d592a: DEC RSI LAB_001d592d: MOV AL,byte ptr [R8] INC R8 MOV byte ptr [RSI + 0x1],AL INC RSI TEST AL,AL JNZ 0x001d592d MOV RAX,qword ptr FS:[0x28] CMP RAX,qword ptr [RBP + -0x8] JNZ 0x001d5955 MOV RAX,RSI ADD RSP,0x50 POP RBP RET LAB_001d5955: CALL 0x00129250
int1 * int10_to_str(ulong param_1,int1 *param_2,int param_3) { char cVar1; ulong uVar2; ulong uVar3; char *pcVar4; long in_FS_OFFSET; char local_1a [10]; long local_10; local_10 = *(long *)(in_FS_OFFSET + 0x28); if ((long)param_1 < 0 && param_3 < 0) { *param_2 = 0x2d; param_2 = param_2 + 1; param_1 = -param_1; } pcVar4 = local_1a + 1; local_1a[2] = 0; local_1a[1] = (char)(param_1 / 10) * -10 + (char)param_1 + '0'; uVar3 = param_1 / 10; while (uVar2 = uVar3, 9 < param_1) { pcVar4[-1] = (char)(uVar2 / 10) * -10 + (char)uVar2 + '0'; pcVar4 = pcVar4 + -1; uVar3 = uVar2 / 10; param_1 = uVar2; } param_2 = param_2 + -1; do { cVar1 = *pcVar4; pcVar4 = pcVar4 + 1; param_2[1] = cVar1; param_2 = param_2 + 1; } while (cVar1 != '\0'); if (*(long *)(in_FS_OFFSET + 0x28) != local_10) { /* WARNING: Subroutine does not return */ __stack_chk_fail(); } return param_2; }
31,883
minja::DictExpr::do_evaluate(std::shared_ptr<minja::Context> const&) const
monkey531[P]llama/common/minja.hpp
Value do_evaluate(const std::shared_ptr<Context> & context) const override { auto result = Value::object(); for (const auto& [key, value] : elements) { if (!key) throw std::runtime_error("Dict key is null"); if (!value) throw std::runtime_error("Dict value is null"); result.set(key->evaluate(context), value->evaluate(context)); } return result; }
O3
cpp
minja::DictExpr::do_evaluate(std::shared_ptr<minja::Context> const&) const: pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0xb8, %rsp movq %rdx, %r14 movq %rsi, %r15 movq %rdi, %rbx movl $0x30, %edi callq 0x1a720 movabsq $0x100000001, %rcx # imm = 0x100000001 movq %rcx, 0x8(%rax) leaq 0x8c9f9(%rip), %rcx # 0xe1458 addq $0x10, %rcx movq %rcx, (%rax) leaq 0x10(%rax), %rcx xorps %xmm0, %xmm0 movups %xmm0, 0x10(%rax) movq $0x0, 0x20(%rax) leaq 0xa8(%rsp), %r12 movq %rax, 0x8(%r12) movq %rcx, (%r12) movq %rbx, (%rsp) movq %rbx, %rdi movq %r12, %rsi callq 0x54f36 movq 0x8(%r12), %rdi testq %rdi, %rdi je 0x54aa8 callq 0x348da movq 0x20(%r15), %rbx movq 0x28(%r15), %r15 cmpq %r15, %rbx je 0x54c0d leaq 0x58(%rsp), %r13 leaq 0x8(%rsp), %rbp movq (%rbx), %rsi testq %rsi, %rsi je 0x54c23 cmpq $0x0, 0x10(%rbx) je 0x54c41 movq %r13, %rdi movq %r14, %rdx callq 0x42364 movq 0x10(%rbx), %rsi movq %rbp, %rdi movq %r14, %rdx callq 0x42364 movq (%rsp), %rdi movq %r13, %rsi movq %rbp, %rdx callq 0x54d36 leaq 0x48(%rsp), %r12 movq %r12, %rdi xorl %esi, %esi callq 0x426e2 movq %r12, %rdi callq 0x4f2d0 movq 0x40(%rsp), %rdi testq %rdi, %rdi je 0x54b29 callq 0x348da movq 0x30(%rsp), %rdi testq %rdi, %rdi je 0x54b38 callq 0x348da movq 0x20(%rsp), %rdi testq %rdi, %rdi je 0x54b47 callq 0x348da movq 0x10(%rsp), %rdi testq %rdi, %rdi je 0x54b7d movq 0x8e440(%rip), %rax # 0xe2f98 cmpb $0x0, (%rax) je 0x54b68 movl 0xc(%rdi), %eax leal -0x1(%rax), %ecx movl %ecx, 0xc(%rdi) jmp 0x54b72 movl $0xffffffff, %eax # imm = 0xFFFFFFFF lock xaddl %eax, 0xc(%rdi) cmpl $0x1, %eax jne 0x54b7d movq (%rdi), %rax callq *0x18(%rax) leaq 0x98(%rsp), %r12 movq %r12, %rdi xorl %esi, %esi callq 0x426e2 movq %r12, %rdi callq 0x4f2d0 movq 0x90(%rsp), %rdi testq %rdi, %rdi je 0x54ba9 callq 0x348da movq 0x80(%rsp), %rdi testq %rdi, %rdi je 0x54bbb callq 0x348da movq 0x70(%rsp), %rdi testq %rdi, %rdi je 0x54bca callq 0x348da movq 0x60(%rsp), %rdi testq %rdi, %rdi je 0x54c00 movq 0x8e3bd(%rip), %rax # 0xe2f98 cmpb $0x0, (%rax) je 0x54beb movl 0xc(%rdi), %eax leal -0x1(%rax), %ecx movl %ecx, 0xc(%rdi) jmp 0x54bf5 movl $0xffffffff, %eax # imm = 0xFFFFFFFF lock xaddl %eax, 0xc(%rdi) cmpl $0x1, %eax jne 0x54c00 movq (%rdi), %rax callq *0x18(%rax) addq $0x20, %rbx cmpq %r15, %rbx jne 0x54ac3 movq (%rsp), %rax addq $0xb8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq movl $0x10, %edi callq 0x1a390 movq %rax, %r15 leaq 0x5c1ce(%rip), %rsi # 0xb0e05 movq %rax, %rdi callq 0x1a290 jmp 0x54c5d movl $0x10, %edi callq 0x1a390 movq %rax, %r15 leaq 0x5c1c1(%rip), %rsi # 0xb0e16 movq %rax, %rdi callq 0x1a290 movq 0x8e38c(%rip), %rsi # 0xe2ff0 movq 0x8e305(%rip), %rdx # 0xe2f70 movq %r15, %rdi callq 0x1acd0 jmp 0x54c75 movq %rax, %r14 movq %r15, %rdi callq 0x1a530 jmp 0x54ca5 jmp 0x54ca2 movq %rax, %r14 jmp 0x54c96 movq %rax, %r14 leaq 0x8(%rsp), %rdi callq 0x42656 leaq 0x58(%rsp), %rdi callq 0x42656 jmp 0x54ca5 movq %rax, %r14 movq (%rsp), %rdi callq 0x42656 movq %r14, %rdi callq 0x1ad30
_ZNK5minja8DictExpr11do_evaluateERKSt10shared_ptrINS_7ContextEE: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 0B8h mov r14, rdx mov r15, rsi mov rbx, rdi mov edi, 30h ; '0'; unsigned __int64 call __Znwm; operator new(ulong) mov rcx, 100000001h mov [rax+8], rcx lea rcx, _ZTVSt23_Sp_counted_ptr_inplaceIN8nlohmann16json_abi_v3_11_311ordered_mapINS1_10basic_jsonIS2_St6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES4_IhSaIhEEvEEN5minja5ValueESt4lessISE_ESaISt4pairIKSE_SG_EEEESaISN_ELN9__gnu_cxx12_Lock_policyE2EE; `vtable for'std::_Sp_counted_ptr_inplace<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,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,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,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,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,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const,minja::Value>>>,std::allocator<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,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,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,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,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,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const,minja::Value>>>>,(__gnu_cxx::_Lock_policy)2> add rcx, 10h mov [rax], rcx lea rcx, [rax+10h] xorps xmm0, xmm0 movups xmmword ptr [rax+10h], xmm0 mov qword ptr [rax+20h], 0 lea r12, [rsp+0E8h+var_40] mov [r12+8], rax mov [r12], rcx mov [rsp+0E8h+var_E8], rbx mov rdi, rbx mov rsi, r12 call _ZN5minja5ValueC2ERKSt10shared_ptrIN8nlohmann16json_abi_v3_11_311ordered_mapINS3_10basic_jsonIS4_St6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS3_14adl_serializerES6_IhSaIhEEvEES0_St4lessISG_ESaISt4pairIKSG_S0_EEEEE; minja::Value::Value(std::shared_ptr<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,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,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,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,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,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const,minja::Value>>>> const&) mov rdi, [r12+8] test rdi, rdi jz short loc_54AA8 call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void) loc_54AA8: mov rbx, [r15+20h] mov r15, [r15+28h] cmp rbx, r15 jz loc_54C0D lea r13, [rsp+0E8h+var_90] lea rbp, [rsp+0E8h+var_E0] loc_54AC3: mov rsi, [rbx] test rsi, rsi jz loc_54C23 cmp qword ptr [rbx+10h], 0 jz loc_54C41 mov rdi, r13 mov rdx, r14 call _ZNK5minja10Expression8evaluateERKSt10shared_ptrINS_7ContextEE; minja::Expression::evaluate(std::shared_ptr<minja::Context> const&) mov rsi, [rbx+10h] mov rdi, rbp mov rdx, r14 call _ZNK5minja10Expression8evaluateERKSt10shared_ptrINS_7ContextEE; minja::Expression::evaluate(std::shared_ptr<minja::Context> const&) mov rdi, [rsp+0E8h+var_E8]; this mov rsi, r13; minja::Value * mov rdx, rbp; minja::Value * call _ZN5minja5Value3setERKS0_S2_; minja::Value::set(minja::Value const&,minja::Value const&) lea r12, [rsp+0E8h+var_A0] mov rdi, r12 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, r12 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, [rsp+0E8h+var_A8] test rdi, rdi jz short loc_54B29 call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void) loc_54B29: mov rdi, [rsp+0E8h+var_B8] test rdi, rdi jz short loc_54B38 call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void) loc_54B38: mov rdi, [rsp+0E8h+var_C8] test rdi, rdi jz short loc_54B47 call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void) loc_54B47: mov rdi, [rsp+0E8h+var_D8] test rdi, rdi jz short loc_54B7D mov rax, cs:__libc_single_threaded_ptr cmp byte ptr [rax], 0 jz short loc_54B68 mov eax, [rdi+0Ch] lea ecx, [rax-1] mov [rdi+0Ch], ecx jmp short loc_54B72 loc_54B68: mov eax, 0FFFFFFFFh lock xadd [rdi+0Ch], eax loc_54B72: cmp eax, 1 jnz short loc_54B7D mov rax, [rdi] call qword ptr [rax+18h] loc_54B7D: lea r12, [rsp+0E8h+var_50] mov rdi, r12 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, r12 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, [rsp+0E8h+var_58] test rdi, rdi jz short loc_54BA9 call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void) loc_54BA9: mov rdi, [rsp+0E8h+var_68] test rdi, rdi jz short loc_54BBB call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void) loc_54BBB: mov rdi, [rsp+0E8h+var_78] test rdi, rdi jz short loc_54BCA call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void) loc_54BCA: mov rdi, [rsp+0E8h+var_88] test rdi, rdi jz short loc_54C00 mov rax, cs:__libc_single_threaded_ptr cmp byte ptr [rax], 0 jz short loc_54BEB mov eax, [rdi+0Ch] lea ecx, [rax-1] mov [rdi+0Ch], ecx jmp short loc_54BF5 loc_54BEB: mov eax, 0FFFFFFFFh lock xadd [rdi+0Ch], eax loc_54BF5: cmp eax, 1 jnz short loc_54C00 mov rax, [rdi] call qword ptr [rax+18h] loc_54C00: add rbx, 20h ; ' ' cmp rbx, r15 jnz loc_54AC3 loc_54C0D: mov rax, [rsp+0E8h+var_E8] add rsp, 0B8h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn loc_54C23: mov edi, 10h; thrown_size call ___cxa_allocate_exception mov r15, rax lea rsi, aDictKeyIsNull; "Dict key is null" mov rdi, rax; this call __ZNSt13runtime_errorC1EPKc; std::runtime_error::runtime_error(char const*) jmp short loc_54C5D loc_54C41: mov edi, 10h; thrown_size call ___cxa_allocate_exception mov r15, rax lea rsi, aDictValueIsNul; "Dict value is null" mov rdi, rax; this call __ZNSt13runtime_errorC1EPKc; std::runtime_error::runtime_error(char const*) loc_54C5D: mov rsi, cs:lptinfo; lptinfo mov rdx, cs:_ZTISt19_Sp_make_shared_tag; void (*)(void *) mov rdi, r15; void * call ___cxa_throw jmp short $+2 loc_54C75: mov r14, rax mov rdi, r15; void * call ___cxa_free_exception jmp short loc_54CA5 jmp short loc_54CA2 mov r14, rax jmp short loc_54C96 mov r14, rax lea rdi, [rsp+0E8h+var_E0]; this call _ZN5minja5ValueD2Ev; minja::Value::~Value() loc_54C96: lea rdi, [rsp+0E8h+var_90]; this call _ZN5minja5ValueD2Ev; minja::Value::~Value() jmp short loc_54CA5 loc_54CA2: mov r14, rax loc_54CA5: mov rdi, [rsp+0E8h+var_E8]; this call _ZN5minja5ValueD2Ev; minja::Value::~Value() mov rdi, r14 call __Unwind_Resume
minja::Value * minja::DictExpr::do_evaluate(minja::Value *a1, long long a2) { long long v2; // rax void (****v3)(void); // rbx void (****v4)(void); // r15 long long v5; // rdi signed __int32 v6; // eax long long v7; // rdi signed __int32 v8; // eax std::runtime_error *exception; // r15 _BYTE v12[8]; // [rsp+8h] [rbp-E0h] BYREF long long v13; // [rsp+10h] [rbp-D8h] volatile signed __int32 *v14; // [rsp+20h] [rbp-C8h] volatile signed __int32 *v15; // [rsp+30h] [rbp-B8h] volatile signed __int32 *v16; // [rsp+40h] [rbp-A8h] void **v17[2]; // [rsp+48h] [rbp-A0h] BYREF _BYTE v18[8]; // [rsp+58h] [rbp-90h] BYREF long long v19; // [rsp+60h] [rbp-88h] volatile signed __int32 *v20; // [rsp+70h] [rbp-78h] volatile signed __int32 *v21; // [rsp+80h] [rbp-68h] volatile signed __int32 *v22; // [rsp+90h] [rbp-58h] void **v23[2]; // [rsp+98h] [rbp-50h] BYREF long long v24; // [rsp+A8h] [rbp-40h] BYREF volatile signed __int32 *v25; // [rsp+B0h] [rbp-38h] v2 = operator new(0x30uLL); *(_QWORD *)(v2 + 8) = 0x100000001LL; *(_QWORD *)v2 = &`vtable for'std::_Sp_counted_ptr_inplace<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>>>,std::allocator<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>>>>,(__gnu_cxx::_Lock_policy)2> + 2; *(_OWORD *)(v2 + 16) = 0LL; *(_QWORD *)(v2 + 32) = 0LL; v25 = (volatile signed __int32 *)v2; v24 = v2 + 16; minja::Value::Value(a1, &v24); if ( v25 ) std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v25); v3 = *(void (*****)(void))(a2 + 32); v4 = *(void (*****)(void))(a2 + 40); if ( v3 != v4 ) { while ( *v3 ) { if ( !v3[2] ) { exception = (std::runtime_error *)__cxa_allocate_exception(0x10uLL); std::runtime_error::runtime_error(exception, "Dict value is null"); LABEL_34: __cxa_throw( exception, (struct type_info *)&`typeinfo for'std::runtime_error, (void (*)(void *))&std::runtime_error::~runtime_error); } minja::Expression::evaluate((long long)v18, *v3); minja::Expression::evaluate((long long)v12, v3[2]); minja::Value::set(a1, (const minja::Value *)v18, (const minja::Value *)v12); 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 *)v17); 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(v17); if ( v16 ) std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v16); if ( v15 ) std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v15); if ( v14 ) std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v14); v5 = v13; if ( v13 ) { if ( _libc_single_threaded ) { v6 = *(_DWORD *)(v13 + 12); *(_DWORD *)(v13 + 12) = v6 - 1; } else { v6 = _InterlockedExchangeAdd((volatile signed __int32 *)(v13 + 12), 0xFFFFFFFF); } if ( v6 == 1 ) (*(void ( **)(long long, _QWORD))(*(_QWORD *)v5 + 24LL))(v5, 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 *)v23); 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(v23); if ( v22 ) std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v22); if ( v21 ) std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v21); if ( v20 ) std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v20); v7 = v19; if ( v19 ) { if ( _libc_single_threaded ) { v8 = *(_DWORD *)(v19 + 12); *(_DWORD *)(v19 + 12) = v8 - 1; } else { v8 = _InterlockedExchangeAdd((volatile signed __int32 *)(v19 + 12), 0xFFFFFFFF); } if ( v8 == 1 ) (*(void ( **)(long long, _QWORD))(*(_QWORD *)v7 + 24LL))(v7, 0LL); } v3 += 4; if ( v3 == v4 ) return a1; } exception = (std::runtime_error *)__cxa_allocate_exception(0x10uLL); std::runtime_error::runtime_error(exception, "Dict key is null"); goto LABEL_34; } return a1; }
do_evaluate: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0xb8 MOV R14,RDX MOV R15,RSI MOV RBX,RDI MOV EDI,0x30 CALL 0x0011a720 MOV RCX,0x100000001 MOV qword ptr [RAX + 0x8],RCX LEA RCX,[0x1e1458] ADD RCX,0x10 MOV qword ptr [RAX],RCX LEA RCX,[RAX + 0x10] XORPS XMM0,XMM0 MOVUPS xmmword ptr [RAX + 0x10],XMM0 MOV qword ptr [RAX + 0x20],0x0 LEA R12,[RSP + 0xa8] MOV qword ptr [R12 + 0x8],RAX MOV qword ptr [R12],RCX MOV qword ptr [RSP],RBX MOV RDI,RBX MOV RSI,R12 CALL 0x00154f36 MOV RDI,qword ptr [R12 + 0x8] TEST RDI,RDI JZ 0x00154aa8 CALL 0x001348da LAB_00154aa8: MOV RBX,qword ptr [R15 + 0x20] MOV R15,qword ptr [R15 + 0x28] CMP RBX,R15 JZ 0x00154c0d LEA R13,[RSP + 0x58] LEA RBP,[RSP + 0x8] LAB_00154ac3: MOV RSI,qword ptr [RBX] TEST RSI,RSI JZ 0x00154c23 CMP qword ptr [RBX + 0x10],0x0 JZ 0x00154c41 LAB_00154ada: MOV RDI,R13 MOV RDX,R14 CALL 0x00142364 MOV RSI,qword ptr [RBX + 0x10] LAB_00154ae9: MOV RDI,RBP MOV RDX,R14 CALL 0x00142364 LAB_00154af4: MOV RDI,qword ptr [RSP] MOV RSI,R13 MOV RDX,RBP CALL 0x00154d36 LAB_00154b03: LEA R12,[RSP + 0x48] MOV RDI,R12 XOR ESI,ESI CALL 0x001426e2 MOV RDI,R12 CALL 0x0014f2d0 MOV RDI,qword ptr [RSP + 0x40] TEST RDI,RDI JZ 0x00154b29 CALL 0x001348da LAB_00154b29: MOV RDI,qword ptr [RSP + 0x30] TEST RDI,RDI JZ 0x00154b38 CALL 0x001348da LAB_00154b38: MOV RDI,qword ptr [RSP + 0x20] TEST RDI,RDI JZ 0x00154b47 CALL 0x001348da LAB_00154b47: MOV RDI,qword ptr [RSP + 0x10] TEST RDI,RDI JZ 0x00154b7d MOV RAX,qword ptr [0x001e2f98] CMP byte ptr [RAX],0x0 JZ 0x00154b68 MOV EAX,dword ptr [RDI + 0xc] LEA ECX,[RAX + -0x1] MOV dword ptr [RDI + 0xc],ECX JMP 0x00154b72 LAB_00154b68: MOV EAX,0xffffffff XADD.LOCK dword ptr [RDI + 0xc],EAX LAB_00154b72: CMP EAX,0x1 JNZ 0x00154b7d MOV RAX,qword ptr [RDI] CALL qword ptr [RAX + 0x18] LAB_00154b7d: LEA R12,[RSP + 0x98] MOV RDI,R12 XOR ESI,ESI CALL 0x001426e2 MOV RDI,R12 CALL 0x0014f2d0 MOV RDI,qword ptr [RSP + 0x90] TEST RDI,RDI JZ 0x00154ba9 CALL 0x001348da LAB_00154ba9: MOV RDI,qword ptr [RSP + 0x80] TEST RDI,RDI JZ 0x00154bbb CALL 0x001348da LAB_00154bbb: MOV RDI,qword ptr [RSP + 0x70] TEST RDI,RDI JZ 0x00154bca CALL 0x001348da LAB_00154bca: MOV RDI,qword ptr [RSP + 0x60] TEST RDI,RDI JZ 0x00154c00 MOV RAX,qword ptr [0x001e2f98] CMP byte ptr [RAX],0x0 JZ 0x00154beb MOV EAX,dword ptr [RDI + 0xc] LEA ECX,[RAX + -0x1] MOV dword ptr [RDI + 0xc],ECX JMP 0x00154bf5 LAB_00154beb: MOV EAX,0xffffffff XADD.LOCK dword ptr [RDI + 0xc],EAX LAB_00154bf5: CMP EAX,0x1 JNZ 0x00154c00 MOV RAX,qword ptr [RDI] CALL qword ptr [RAX + 0x18] LAB_00154c00: ADD RBX,0x20 CMP RBX,R15 JNZ 0x00154ac3 LAB_00154c0d: MOV RAX,qword ptr [RSP] ADD RSP,0xb8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET LAB_00154c23: MOV EDI,0x10 CALL 0x0011a390 MOV R15,RAX LAB_00154c30: LEA RSI,[0x1b0e05] MOV RDI,RAX CALL 0x0011a290 LAB_00154c3f: JMP 0x00154c5d LAB_00154c41: MOV EDI,0x10 CALL 0x0011a390 MOV R15,RAX LAB_00154c4e: LEA RSI,[0x1b0e16] MOV RDI,RAX CALL 0x0011a290 LAB_00154c5d: MOV RSI,qword ptr [0x001e2ff0] MOV RDX,qword ptr [0x001e2f70] MOV RDI,R15 CALL 0x0011acd0
/* minja::DictExpr::do_evaluate(std::shared_ptr<minja::Context> const&) const */ DictExpr * __thiscall minja::DictExpr::do_evaluate(DictExpr *this,shared_ptr *param_1) { int *piVar1; int8 *puVar2; int iVar3; runtime_error *this_00; int8 *puVar4; Expression local_e0 [8]; long *local_d8; _Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *local_c8; _Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *local_b8; _Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *local_a8; data local_a0 [16]; Expression local_90 [8]; long *local_88; _Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *local_78; _Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *local_68; _Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *local_58; data local_50 [16]; _Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *local_40; _Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *local_38; local_38 = (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)operator_new(0x30); *(int8 *)(local_38 + 8) = 0x100000001; *(int ***)local_38 = &PTR___Sp_counted_ptr_inplace_001e1468; local_40 = local_38 + 0x10; *(int8 *)(local_38 + 0x10) = 0; *(int8 *)(local_38 + 0x18) = 0; *(int8 *)(local_38 + 0x20) = 0; Value::Value((Value *)this,(shared_ptr *)&local_40); if (local_38 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) { std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(local_38); } puVar4 = *(int8 **)(param_1 + 0x20); puVar2 = *(int8 **)(param_1 + 0x28); if (puVar4 != puVar2) { do { if ((shared_ptr *)*puVar4 == (shared_ptr *)0x0) { this_00 = (runtime_error *)__cxa_allocate_exception(0x10); /* try { // try from 00154c30 to 00154c3e has its CatchHandler @ 00154c75 */ std::runtime_error::runtime_error(this_00,"Dict key is null"); LAB_00154c5d: /* try { // try from 00154c5d to 00154c72 has its CatchHandler @ 00154ca2 */ /* WARNING: Subroutine does not return */ __cxa_throw(this_00,PTR_typeinfo_001e2ff0,PTR__runtime_error_001e2f70); } if (puVar4[2] == 0) { this_00 = (runtime_error *)__cxa_allocate_exception(0x10); /* try { // try from 00154c4e to 00154c5c has its CatchHandler @ 00154c73 */ std::runtime_error::runtime_error(this_00,"Dict value is null"); goto LAB_00154c5d; } /* try { // try from 00154ada to 00154ae4 has its CatchHandler @ 00154c82 */ Expression::evaluate(local_90,(shared_ptr *)*puVar4); /* try { // try from 00154ae9 to 00154af3 has its CatchHandler @ 00154c84 */ Expression::evaluate(local_e0,(shared_ptr *)puVar4[2]); /* try { // try from 00154af4 to 00154b02 has its CatchHandler @ 00154c89 */ Value::set((Value *)this,(Value *)local_90,(Value *)local_e0); 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> ::assert_invariant(SUB81(local_a0,0)); 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> ::data::~data(local_a0); if (local_a8 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) { std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(local_a8); } if (local_b8 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) { std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(local_b8); } if (local_c8 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) { std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(local_c8); } if (local_d8 != (long *)0x0) { if (*PTR___libc_single_threaded_001e2f98 == '\0') { LOCK(); piVar1 = (int *)((long)local_d8 + 0xc); iVar3 = *piVar1; *piVar1 = *piVar1 + -1; UNLOCK(); } else { iVar3 = *(int *)((long)local_d8 + 0xc); *(int *)((long)local_d8 + 0xc) = iVar3 + -1; } if (iVar3 == 1) { (**(code **)(*local_d8 + 0x18))(); } } 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> ::assert_invariant(SUB81(local_50,0)); 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> ::data::~data(local_50); if (local_58 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) { std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(local_58); } if (local_68 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) { std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(local_68); } if (local_78 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) { std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(local_78); } if (local_88 != (long *)0x0) { if (*PTR___libc_single_threaded_001e2f98 == '\0') { LOCK(); piVar1 = (int *)((long)local_88 + 0xc); iVar3 = *piVar1; *piVar1 = *piVar1 + -1; UNLOCK(); } else { iVar3 = *(int *)((long)local_88 + 0xc); *(int *)((long)local_88 + 0xc) = iVar3 + -1; } if (iVar3 == 1) { (**(code **)(*local_88 + 0x18))(); } } puVar4 = puVar4 + 4; } while (puVar4 != puVar2); } return this; }
31,884
metrics::HttpExporter::start()
nickolajgrishuk[P]metricz-cpp/examples/../include/metrics_exporter.hpp
void start() override { if (running_) return; server_.Get("/metrics", [this](const httplib::Request&, httplib::Response& res) { res.set_content(registry_.serialize(), "text/plain"); }); running_ = true; server_thread_ = std::thread([this]() { server_.listen(host_.c_str(), port_); }); }
O1
cpp
metrics::HttpExporter::start(): pushq %r15 pushq %r14 pushq %rbx subq $0xa0, %rsp cmpb $0x0, 0x34(%rdi) jne 0x9b4e movq %rdi, %rbx leaq 0x50(%rsp), %r15 movq %r15, -0x10(%r15) leaq 0x23b3f(%rip), %rsi # 0x2d596 leaq 0x23b40(%rip), %rdx # 0x2d59e leaq 0x40(%rsp), %r14 movq %r14, %rdi callq 0x107fc xorps %xmm0, %xmm0 movaps %xmm0, (%rsp) movaps %xmm0, 0x10(%rsp) movq %rbx, (%rsp) leaq 0xd040(%rip), %rax # 0x16ac2 movq %rax, 0x18(%rsp) leaq 0xd03a(%rip), %rax # 0x16ac8 movq %rax, 0x10(%rsp) leaq 0x20(%rsp), %rdi movq %r14, %rsi movl $0x10, %edx callq 0xb5f4 leaq 0x60(%rsp), %r14 leaq 0x20(%rsp), %rsi movq %rsp, %rdx movq %r14, %rdi callq 0xb8e6 leaq 0x120(%rbx), %rdi movq %r14, %rsi callq 0xb6a4 movq 0x90(%rsp), %rax testq %rax, %rax je 0x9ae8 leaq 0x80(%rsp), %rdi movq %rdi, %rsi movl $0x3, %edx callq *%rax leaq 0x60(%rsp), %rdi callq 0xb684 leaq 0x20(%rsp), %rdi callq 0xb684 movq 0x10(%rsp), %rax testq %rax, %rax je 0x9b13 movq %rsp, %rdi movq %rdi, %rsi movl $0x3, %edx callq *%rax movq 0x40(%rsp), %rdi cmpq %r15, %rdi je 0x9b22 callq 0x8520 movb $0x1, 0x34(%rbx) leaq 0x20(%rsp), %rsi movq %rbx, (%rsi) leaq 0x60(%rsp), %rdi callq 0xb576 cmpq $0x0, 0x328(%rbx) jne 0x9b5b movq 0x60(%rsp), %rax movq %rax, 0x328(%rbx) addq $0xa0, %rsp popq %rbx popq %r14 popq %r15 retq callq 0x8110 jmp 0x9bae jmp 0x9bae movq %rax, %rbx leaq 0x60(%rsp), %rdi callq 0xb658 leaq 0x20(%rsp), %rdi callq 0xb684 jmp 0x9b80 movq %rax, %rbx movq 0x10(%rsp), %rax testq %rax, %rax je 0x9b97 movq %rsp, %rdi movq %rdi, %rsi movl $0x3, %edx callq *%rax movq 0x40(%rsp), %rdi cmpq %r15, %rdi je 0x9ba6 callq 0x8520 movq %rbx, %rdi callq 0x8990 movq %rax, %rdi callq 0x9349
_ZN7metrics12HttpExporter5startEv: push r15 push r14 push rbx sub rsp, 0A0h cmp byte ptr [rdi+34h], 0 jnz loc_9B4E mov rbx, rdi lea r15, [rsp+0B8h+var_68] mov [r15-10h], r15 lea rsi, aMetrics_0; "/metrics" lea rdx, aMetrics_0+8; "" lea r14, [rsp+0B8h+var_78] 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) xorps xmm0, xmm0 movaps [rsp+0B8h+var_B8], xmm0 movaps [rsp+0B8h+var_A8], xmm0 mov qword ptr [rsp+0B8h+var_B8], rbx lea rax, _ZNSt17_Function_handlerIFvRKN7httplib7RequestERNS0_8ResponseEEZN7metrics12HttpExporter5startEvEUlS3_S5_E_E9_M_invokeERKSt9_Any_dataS3_S5_; std::_Function_handler<void ()(httplib::Request const&,httplib::Response &),metrics::HttpExporter::start(void)::{lambda(httplib::Request const&,httplib::Response &)#1}>::_M_invoke(std::_Any_data const&,httplib::Request const&,httplib::Response &) mov qword ptr [rsp+0B8h+var_A8+8], rax lea rax, _ZNSt17_Function_handlerIFvRKN7httplib7RequestERNS0_8ResponseEEZN7metrics12HttpExporter5startEvEUlS3_S5_E_E10_M_managerERSt9_Any_dataRKSB_St18_Manager_operation; std::_Function_handler<void ()(httplib::Request const&,httplib::Response &),metrics::HttpExporter::start(void)::{lambda(httplib::Request const&,httplib::Response &)#1}>::_M_manager(std::_Any_data &,std::_Any_data const&,std::_Manager_operation) mov qword ptr [rsp+0B8h+var_A8], rax lea rdi, [rsp+0B8h+var_98] mov rsi, r14 mov edx, 10h call _ZNSt7__cxx1111basic_regexIcNS_12regex_traitsIcEEEC2ISt11char_traitsIcESaIcEEERKNS_12basic_stringIcT_T0_EENSt15regex_constants18syntax_option_typeE; std::basic_regex<char,std::regex_traits<char>>::basic_regex<std::char_traits<char>,std::allocator<char>>(std::string const&,std::regex_constants::syntax_option_type) lea r14, [rsp+0B8h+var_58] lea rsi, [rsp+0B8h+var_98] mov rdx, rsp mov rdi, r14 call _ZNSt4pairINSt7__cxx1111basic_regexIcNS0_12regex_traitsIcEEEESt8functionIFvRKN7httplib7RequestERNS6_8ResponseEEEEC2IS4_SD_TnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairISH_SI_EEEbE4typeELb1EEEOSH_OSI_ lea rdi, [rbx+120h] mov rsi, r14 call _ZNSt6vectorISt4pairINSt7__cxx1111basic_regexIcNS1_12regex_traitsIcEEEESt8functionIFvRKN7httplib7RequestERNS7_8ResponseEEEESaISF_EE12emplace_backIJSF_EEEvDpOT_; std::vector<std::pair<std::basic_regex<char,std::regex_traits<char>>,std::function<void ()(httplib::Request const&,httplib::Response &)>>>::emplace_back<std::pair<std::basic_regex<char,std::regex_traits<char>>,std::function<void ()(httplib::Request const&,httplib::Response &)>>>(std::pair<std::basic_regex<char,std::regex_traits<char>>,std::function<void ()(httplib::Request const&,httplib::Response &)>> &&) mov rax, [rsp+0B8h+var_28] test rax, rax jz short loc_9AE8 lea rdi, [rsp+0B8h+var_38] mov rsi, rdi mov edx, 3 call rax loc_9AE8: lea rdi, [rsp+0B8h+var_58]; void * call _ZNSt7__cxx1111basic_regexIcNS_12regex_traitsIcEEED2Ev; std::basic_regex<char,std::regex_traits<char>>::~basic_regex() lea rdi, [rsp+0B8h+var_98]; void * call _ZNSt7__cxx1111basic_regexIcNS_12regex_traitsIcEEED2Ev; std::basic_regex<char,std::regex_traits<char>>::~basic_regex() mov rax, qword ptr [rsp+0B8h+var_A8] test rax, rax jz short loc_9B13 mov rdi, rsp mov rsi, rdi mov edx, 3 call rax loc_9B13: mov rdi, [rsp+0B8h+var_78]; void * cmp rdi, r15 jz short loc_9B22 call __ZdlPv; operator delete(void *) loc_9B22: mov byte ptr [rbx+34h], 1 lea rsi, [rsp+0B8h+var_98] mov [rsi], rbx lea rdi, [rsp+0B8h+var_58] call _ZNSt6threadC2IZN7metrics12HttpExporter5startEvEUlvE_JEvEEOT_DpOT0_ cmp qword ptr [rbx+328h], 0 jnz short loc_9B5B mov rax, [rsp+0B8h+var_58] mov [rbx+328h], rax loc_9B4E: add rsp, 0A0h pop rbx pop r14 pop r15 retn loc_9B5B: call __ZSt9terminatev; std::terminate(void) jmp short loc_9BAE jmp short loc_9BAE mov rbx, rax lea rdi, [rsp+0B8h+var_58]; void * call _ZNSt4pairINSt7__cxx1111basic_regexIcNS0_12regex_traitsIcEEEESt8functionIFvRKN7httplib7RequestERNS6_8ResponseEEEED2Ev; std::pair<std::basic_regex<char,std::regex_traits<char>>,std::function<void ()(httplib::Request const&,httplib::Response &)>>::~pair() lea rdi, [rsp+0B8h+var_98]; void * call _ZNSt7__cxx1111basic_regexIcNS_12regex_traitsIcEEED2Ev; std::basic_regex<char,std::regex_traits<char>>::~basic_regex() jmp short loc_9B80 mov rbx, rax loc_9B80: mov rax, qword ptr [rsp+0B8h+var_A8] test rax, rax jz short loc_9B97 mov rdi, rsp mov rsi, rdi mov edx, 3 call rax loc_9B97: mov rdi, [rsp+0B8h+var_78]; void * cmp rdi, r15 jz short loc_9BA6 call __ZdlPv; operator delete(void *) loc_9BA6: mov rdi, rbx call __Unwind_Resume loc_9BAE: mov rdi, rax call __clang_call_terminate
void metrics::HttpExporter::start(metrics::HttpExporter *this) { __int128 v1; // [rsp+0h] [rbp-B8h] BYREF long long ( *v2)(); // [rsp+10h] [rbp-A8h] long long ( *v3)(); // [rsp+18h] [rbp-A0h] _QWORD v4[4]; // [rsp+20h] [rbp-98h] BYREF void *v5[2]; // [rsp+40h] [rbp-78h] BYREF _BYTE v6[16]; // [rsp+50h] [rbp-68h] BYREF _QWORD v7[4]; // [rsp+60h] [rbp-58h] BYREF _BYTE v8[16]; // [rsp+80h] [rbp-38h] BYREF void ( *v9)(_BYTE *, _BYTE *, long long); // [rsp+90h] [rbp-28h] if ( !*((_BYTE *)this + 52) ) { v5[0] = v6; std::string::_M_construct<char const*>(v5, "/metrics", ""); v1 = (unsigned long long)this; v3 = std::_Function_handler<void ()(httplib::Request const&,httplib::Response &),metrics::HttpExporter::start(void)::{lambda(httplib::Request const&,httplib::Response &)#1}>::_M_invoke; v2 = std::_Function_handler<void ()(httplib::Request const&,httplib::Response &),metrics::HttpExporter::start(void)::{lambda(httplib::Request const&,httplib::Response &)#1}>::_M_manager; std::basic_regex<char,std::regex_traits<char>>::basic_regex<std::char_traits<char>,std::allocator<char>>( v4, v5, 16LL); ZNSt4pairINSt7__cxx1111basic_regexIcNS0_12regex_traitsIcEEEESt8functionIFvRKN7httplib7RequestERNS6_8ResponseEEEEC2IS4_SD_TnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairISH_SI_EEEbE4typeELb1EEEOSH_OSI_( v7, v4, &v1); std::vector<std::pair<std::basic_regex<char,std::regex_traits<char>>,std::function<void ()(httplib::Request const&,httplib::Response &)>>>::emplace_back<std::pair<std::basic_regex<char,std::regex_traits<char>>,std::function<void ()(httplib::Request const&,httplib::Response &)>>>( (char *)this + 288, v7); if ( v9 ) v9(v8, v8, 3LL); std::basic_regex<char,std::regex_traits<char>>::~basic_regex(v7); std::basic_regex<char,std::regex_traits<char>>::~basic_regex(v4); if ( v2 ) ((void ( *)(__int128 *, __int128 *, long long))v2)(&v1, &v1, 3LL); if ( v5[0] != v6 ) operator delete(v5[0]); *((_BYTE *)this + 52) = 1; v4[0] = this; ZNSt6threadC2IZN7metrics12HttpExporter5startEvEUlvE_JEvEEOT_DpOT0_(v7); if ( *((_QWORD *)this + 101) ) std::terminate(); *((_QWORD *)this + 101) = v7[0]; } }
start: PUSH R15 PUSH R14 PUSH RBX SUB RSP,0xa0 CMP byte ptr [RDI + 0x34],0x0 JNZ 0x00109b4e MOV RBX,RDI LEA R15,[RSP + 0x50] MOV qword ptr [R15 + -0x10],R15 LEA RSI,[0x12d596] LEA RDX,[0x12d59e] LEA R14,[RSP + 0x40] MOV RDI,R14 CALL 0x001107fc XORPS XMM0,XMM0 MOVAPS xmmword ptr [RSP],XMM0 MOVAPS xmmword ptr [RSP + 0x10],XMM0 MOV qword ptr [RSP],RBX LEA RAX,[0x116ac2] MOV qword ptr [RSP + 0x18],RAX LEA RAX,[0x116ac8] MOV qword ptr [RSP + 0x10],RAX LAB_00109a93: LEA RDI,[RSP + 0x20] MOV RSI,R14 MOV EDX,0x10 CALL 0x0010b5f4 LEA R14,[RSP + 0x60] LEA RSI,[RSP + 0x20] MOV RDX,RSP MOV RDI,R14 CALL 0x0010b8e6 LEA RDI,[RBX + 0x120] LAB_00109ac1: MOV RSI,R14 CALL 0x0010b6a4 MOV RAX,qword ptr [RSP + 0x90] TEST RAX,RAX JZ 0x00109ae8 LEA RDI,[RSP + 0x80] LAB_00109ade: MOV RSI,RDI MOV EDX,0x3 CALL RAX LAB_00109ae8: LEA RDI,[RSP + 0x60] CALL 0x0010b684 LEA RDI,[RSP + 0x20] CALL 0x0010b684 MOV RAX,qword ptr [RSP + 0x10] TEST RAX,RAX JZ 0x00109b13 LAB_00109b06: MOV RDI,RSP MOV RSI,RDI MOV EDX,0x3 CALL RAX LAB_00109b13: MOV RDI,qword ptr [RSP + 0x40] CMP RDI,R15 JZ 0x00109b22 CALL 0x00108520 LAB_00109b22: MOV byte ptr [RBX + 0x34],0x1 LEA RSI,[RSP + 0x20] MOV qword ptr [RSI],RBX LEA RDI,[RSP + 0x60] CALL 0x0010b576 CMP qword ptr [RBX + 0x328],0x0 JNZ 0x00109b5b MOV RAX,qword ptr [RSP + 0x60] MOV qword ptr [RBX + 0x328],RAX LAB_00109b4e: ADD RSP,0xa0 POP RBX POP R14 POP R15 RET LAB_00109b5b: CALL 0x00108110
/* metrics::HttpExporter::start() */ void __thiscall metrics::HttpExporter::start(HttpExporter *this) { HttpExporter *local_b8; int8 uStack_b0; code *local_a8; code *pcStack_a0; HttpExporter *local_98 [4]; int1 *local_78 [2]; int1 local_68 [16]; int8 local_58 [4]; int1 local_38 [16]; code *local_28; if (this[0x34] == (HttpExporter)0x0) { local_78[0] = local_68; std::__cxx11::string::_M_construct<char_const*>(local_78,"/metrics",""); uStack_b0 = 0; pcStack_a0 = std:: _Function_handler<void(httplib::Request_const&,httplib::Response&),metrics::HttpExporter::start()::{lambda(httplib::Request_const&,httplib::Response&)#1}> ::_M_invoke; local_a8 = std:: _Function_handler<void(httplib::Request_const&,httplib::Response&),metrics::HttpExporter::start()::{lambda(httplib::Request_const&,httplib::Response&)#1}> ::_M_manager; /* try { // try from 00109a93 to 00109aa4 has its CatchHandler @ 00109b7d */ local_b8 = this; std::__cxx11::basic_regex<char,std::__cxx11::regex_traits<char>>:: basic_regex<std::char_traits<char>,std::allocator<char>> ((basic_regex<char,std::__cxx11::regex_traits<char>> *)local_98,local_78,0x10); _ZNSt4pairINSt7__cxx1111basic_regexIcNS0_12regex_traitsIcEEEESt8functionIFvRKN7httplib7RequestERNS6_8ResponseEEEEC2IS4_SD_TnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairISH_SI_EEEbE4typeELb1EEEOSH_OSI_ ((pair *)local_58,local_98,&local_b8); /* try { // try from 00109ac1 to 00109ac8 has its CatchHandler @ 00109b64 */ std:: vector<std::pair<std::__cxx11::basic_regex<char,std::__cxx11::regex_traits<char>>,std::function<void(httplib::Request_const&,httplib::Response&)>>,std::allocator<std::pair<std::__cxx11::basic_regex<char,std::__cxx11::regex_traits<char>>,std::function<void(httplib::Request_const&,httplib::Response&)>>>> :: emplace_back<std::pair<std::__cxx11::basic_regex<char,std::__cxx11::regex_traits<char>>,std::function<void(httplib::Request_const&,httplib::Response&)>>> ((vector<std::pair<std::__cxx11::basic_regex<char,std::__cxx11::regex_traits<char>>,std::function<void(httplib::Request_const&,httplib::Response&)>>,std::allocator<std::pair<std::__cxx11::basic_regex<char,std::__cxx11::regex_traits<char>>,std::function<void(httplib::Request_const&,httplib::Response&)>>>> *)(this + 0x120),(pair *)local_58); if (local_28 != (code *)0x0) { /* try { // try from 00109ade to 00109ae7 has its CatchHandler @ 00109b62 */ (*local_28)(local_38,local_38,3); } std::__cxx11::basic_regex<char,std::__cxx11::regex_traits<char>>::~basic_regex ((basic_regex<char,std::__cxx11::regex_traits<char>> *)local_58); std::__cxx11::basic_regex<char,std::__cxx11::regex_traits<char>>::~basic_regex ((basic_regex<char,std::__cxx11::regex_traits<char>> *)local_98); if (local_a8 != (code *)0x0) { /* try { // try from 00109b06 to 00109b12 has its CatchHandler @ 00109b60 */ (*local_a8)(&local_b8,&local_b8,3); } if (local_78[0] != local_68) { operator_delete(local_78[0]); } this[0x34] = (HttpExporter)0x1; local_98[0] = this; std::thread::thread<metrics::HttpExporter::start()::_lambda()_1_,,void> ((thread *)local_58,(_lambda___1_ *)local_98); if (*(long *)(this + 0x328) != 0) { /* WARNING: Subroutine does not return */ std::terminate(); } *(int8 *)(this + 0x328) = local_58[0]; } return; }
31,885
metrics::HttpExporter::start()
nickolajgrishuk[P]metricz-cpp/examples/../include/metrics_exporter.hpp
void start() override { if (running_) return; server_.Get("/metrics", [this](const httplib::Request&, httplib::Response& res) { res.set_content(registry_.serialize(), "text/plain"); }); running_ = true; server_thread_ = std::thread([this]() { server_.listen(host_.c_str(), port_); }); }
O2
cpp
metrics::HttpExporter::start(): pushq %r14 pushq %rbx subq $0x48, %rsp cmpb $0x0, 0x34(%rdi) jne 0x94b1 movq %rdi, %rbx leaq 0x1f159(%rip), %rsi # 0x28586 leaq 0x8(%rsp), %r14 movq %rsp, %rdx movq %r14, %rdi callq 0x8220 leaq 0x38(%rbx), %rdi leaq 0x28(%rsp), %rdx andq $0x0, 0x8(%rdx) movq %rbx, (%rdx) leaq 0xaf2d(%rip), %rax # 0x14382 movq %rax, 0x18(%rdx) leaq 0xaf28(%rip), %rax # 0x14388 movq %rax, 0x10(%rdx) movq %r14, %rsi callq 0xab14 leaq 0x28(%rsp), %rdi callq 0x249a4 leaq 0x8(%rsp), %rdi callq 0x8ac8 movb $0x1, 0x34(%rbx) movq %rsp, %rsi movq %rbx, (%rsi) leaq 0x8(%rsp), %r14 movq %r14, %rdi callq 0xab9a addq $0x328, %rbx # imm = 0x328 movq %rbx, %rdi movq %r14, %rsi callq 0xac02 movq %r14, %rdi callq 0xa95a addq $0x48, %rsp popq %rbx popq %r14 retq movq %rax, %rbx leaq 0x28(%rsp), %rdi callq 0x249a4 leaq 0x8(%rsp), %rdi callq 0x8ac8 movq %rbx, %rdi callq 0x89d0
_ZN7metrics12HttpExporter5startEv: push r14 push rbx sub rsp, 48h cmp byte ptr [rdi+34h], 0 jnz loc_94B1 mov rbx, rdi lea rsi, aMetrics_0; "/metrics" lea r14, [rsp+58h+var_50] mov rdx, rsp mov rdi, r14 call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2EPKcRKS3_; std::string::basic_string(char const*,std::allocator<char> const&) lea rdi, [rbx+38h] lea rdx, [rsp+58h+var_30] and qword ptr [rdx+8], 0 mov [rdx], rbx lea rax, _ZNSt17_Function_handlerIFvRKN7httplib7RequestERNS0_8ResponseEEZN7metrics12HttpExporter5startEvEUlS3_S5_E_E9_M_invokeERKSt9_Any_dataS3_S5_; std::_Function_handler<void ()(httplib::Request const&,httplib::Response &),metrics::HttpExporter::start(void)::{lambda(httplib::Request const&,httplib::Response &)#1}>::_M_invoke(std::_Any_data const&,httplib::Request const&,httplib::Response &) mov [rdx+18h], rax lea rax, _ZNSt17_Function_handlerIFvRKN7httplib7RequestERNS0_8ResponseEEZN7metrics12HttpExporter5startEvEUlS3_S5_E_E10_M_managerERSt9_Any_dataRKSB_St18_Manager_operation; std::_Function_handler<void ()(httplib::Request const&,httplib::Response &),metrics::HttpExporter::start(void)::{lambda(httplib::Request const&,httplib::Response &)#1}>::_M_manager(std::_Any_data &,std::_Any_data const&,std::_Manager_operation) mov [rdx+10h], rax mov rsi, r14 call _ZN7httplib6Server3GetERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt8functionIFvRKNS_7RequestERNS_8ResponseEEE; httplib::Server::Get(std::string const&,std::function<void ()(httplib::Request const&,httplib::Response &)>) lea rdi, [rsp+58h+var_30]; this call _ZNSt14_Function_baseD2Ev; std::_Function_base::~_Function_base() lea rdi, [rsp+58h+var_50]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() mov byte ptr [rbx+34h], 1 mov rsi, rsp mov [rsi], rbx lea r14, [rsp+58h+var_50] mov rdi, r14 call _ZNSt6threadC2IZN7metrics12HttpExporter5startEvEUlvE_JEvEEOT_DpOT0_ add rbx, 328h mov rdi, rbx mov rsi, r14 call _ZNSt6threadaSEOS_; std::thread::operator=(std::thread&&) mov rdi, r14; this call _ZNSt6threadD2Ev; std::thread::~thread() loc_94B1: add rsp, 48h pop rbx pop r14 retn mov rbx, rax lea rdi, [rsp+arg_20]; this call _ZNSt14_Function_baseD2Ev; std::_Function_base::~_Function_base() lea rdi, [rsp+arg_0]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() mov rdi, rbx call __Unwind_Resume
void metrics::HttpExporter::start(metrics::HttpExporter *this) { int v1; // ecx int v2; // r8d int v3; // r9d metrics::HttpExporter *v4; // [rsp+0h] [rbp-58h] BYREF _DWORD v5[6]; // [rsp+8h] [rbp-50h] BYREF char v6; // [rsp+20h] [rbp-38h] _QWORD v7[6]; // [rsp+28h] [rbp-30h] BYREF if ( !*((_BYTE *)this + 52) ) { std::string::basic_string(v5, "/metrics", &v4); v7[1] = 0LL; v7[0] = this; v7[3] = std::_Function_handler<void ()(httplib::Request const&,httplib::Response &),metrics::HttpExporter::start(void)::{lambda(httplib::Request const&,httplib::Response &)#1}>::_M_invoke; v7[2] = std::_Function_handler<void ()(httplib::Request const&,httplib::Response &),metrics::HttpExporter::start(void)::{lambda(httplib::Request const&,httplib::Response &)#1}>::_M_manager; httplib::Server::Get( (_DWORD)this + 56, (unsigned int)v5, (unsigned int)v7, v1, v2, v3, (char)v4, v5[0], v5[2], v5[4], v6); std::_Function_base::~_Function_base((std::_Function_base *)v7); std::string::~string(v5); *((_BYTE *)this + 52) = 1; v4 = this; ZNSt6threadC2IZN7metrics12HttpExporter5startEvEUlvE_JEvEEOT_DpOT0_(v5); std::thread::operator=((char *)this + 808, v5); std::thread::~thread((std::thread *)v5); } }
start: PUSH R14 PUSH RBX SUB RSP,0x48 CMP byte ptr [RDI + 0x34],0x0 JNZ 0x001094b1 MOV RBX,RDI LEA RSI,[0x128586] LEA R14,[RSP + 0x8] MOV RDX,RSP MOV RDI,R14 CALL 0x00108220 LEA RDI,[RBX + 0x38] LEA RDX,[RSP + 0x28] AND qword ptr [RDX + 0x8],0x0 MOV qword ptr [RDX],RBX LEA RAX,[0x114382] MOV qword ptr [RDX + 0x18],RAX LEA RAX,[0x114388] MOV qword ptr [RDX + 0x10],RAX LAB_00109464: MOV RSI,R14 CALL 0x0010ab14 LAB_0010946c: LEA RDI,[RSP + 0x28] CALL 0x001249a4 LEA RDI,[RSP + 0x8] CALL 0x00108ac8 MOV byte ptr [RBX + 0x34],0x1 MOV RSI,RSP MOV qword ptr [RSI],RBX LEA R14,[RSP + 0x8] MOV RDI,R14 CALL 0x0010ab9a ADD RBX,0x328 MOV RDI,RBX MOV RSI,R14 CALL 0x0010ac02 MOV RDI,R14 CALL 0x0010a95a LAB_001094b1: ADD RSP,0x48 POP RBX POP R14 RET
/* metrics::HttpExporter::start() */ void __thiscall metrics::HttpExporter::start(HttpExporter *this) { HttpExporter *local_58; string local_50 [32]; HttpExporter *local_30; int8 local_28; code *local_20; code *local_18; if (this[0x34] == (HttpExporter)0x0) { std::__cxx11::string::string(local_50,"/metrics",(allocator *)&local_58); local_28 = 0; local_18 = std:: _Function_handler<void(httplib::Request_const&,httplib::Response&),metrics::HttpExporter::start()::{lambda(httplib::Request_const&,httplib::Response&)#1}> ::_M_invoke; local_20 = std:: _Function_handler<void(httplib::Request_const&,httplib::Response&),metrics::HttpExporter::start()::{lambda(httplib::Request_const&,httplib::Response&)#1}> ::_M_manager; local_30 = this; /* try { // try from 00109464 to 0010946b has its CatchHandler @ 001094b9 */ httplib::Server::Get((Server *)(this + 0x38),local_50); std::_Function_base::~_Function_base((_Function_base *)&local_30); std::__cxx11::string::~string(local_50); this[0x34] = (HttpExporter)0x1; local_58 = this; std::thread::thread<metrics::HttpExporter::start()::_lambda()_1_,,void> ((thread *)local_50,(_lambda___1_ *)&local_58); std::thread::operator=((thread *)(this + 0x328),(thread *)local_50); std::thread::~thread((thread *)local_50); } return; }
31,886
translog_get_first_needed_file
eloqsql/storage/maria/ma_loghandler.c
uint32 translog_get_first_needed_file() { uint32 file_no; mysql_mutex_lock(&log_descriptor.purger_lock); file_no= log_descriptor.min_need_file; mysql_mutex_unlock(&log_descriptor.purger_lock); return file_no; }
O3
c
translog_get_first_needed_file: pushq %rbp movq %rsp, %rbp pushq %rbx pushq %rax cmpq $0x0, 0xbc84a3(%rip) # 0xc00db0 jne 0x38942 leaq 0xbc845a(%rip), %rdi # 0xc00d70 callq 0x29200 movl 0xbc8447(%rip), %ebx # 0xc00d68 movq 0xbc8488(%rip), %rdi # 0xc00db0 testq %rdi, %rdi jne 0x38949 leaq 0xbc843c(%rip), %rdi # 0xc00d70 callq 0x291c0 movl %ebx, %eax addq $0x8, %rsp popq %rbx popq %rbp retq callq 0x2c0a4 jmp 0x3891b leaq 0x34f6c0(%rip), %rax # 0x388010 movq (%rax), %rax callq *0x160(%rax) jmp 0x3892d
translog_get_first_needed_file: push rbp mov rbp, rsp push rbx push rax cmp cs:qword_C00DB0, 0 jnz short loc_38942 lea rdi, unk_C00D70 call _pthread_mutex_lock loc_3891B: mov ebx, dword ptr cs:qword_C00D68 mov rdi, cs:qword_C00DB0 test rdi, rdi jnz short loc_38949 loc_3892D: lea rdi, unk_C00D70 call _pthread_mutex_unlock mov eax, ebx add rsp, 8 pop rbx pop rbp retn loc_38942: call translog_get_first_needed_file_cold_1 jmp short loc_3891B loc_38949: lea rax, PSI_server mov rax, [rax] call qword ptr [rax+160h] jmp short loc_3892D
long long translog_get_first_needed_file(long long a1) { unsigned int v1; // ebx if ( qword_C00DB0 ) translog_get_first_needed_file_cold_1(a1); else pthread_mutex_lock(&unk_C00D70); v1 = qword_C00D68; if ( qword_C00DB0 ) ((void ( *)(long long))PSI_server[44])(qword_C00DB0); pthread_mutex_unlock(&unk_C00D70); return v1; }
translog_get_first_needed_file: PUSH RBP MOV RBP,RSP PUSH RBX PUSH RAX CMP qword ptr [0x00d00db0],0x0 JNZ 0x00138942 LEA RDI,[0xd00d70] CALL 0x00129200 LAB_0013891b: MOV EBX,dword ptr [0x00d00d68] MOV RDI,qword ptr [0x00d00db0] TEST RDI,RDI JNZ 0x00138949 LAB_0013892d: LEA RDI,[0xd00d70] CALL 0x001291c0 MOV EAX,EBX ADD RSP,0x8 POP RBX POP RBP RET LAB_00138942: CALL 0x0012c0a4 JMP 0x0013891b LAB_00138949: LEA RAX,[0x488010] MOV RAX,qword ptr [RAX] CALL qword ptr [RAX + 0x160] JMP 0x0013892d
int4 translog_get_first_needed_file(void) { int4 uVar1; if (DAT_00d00db0 == 0) { pthread_mutex_lock((pthread_mutex_t *)&DAT_00d00d70); } else { translog_get_first_needed_file_cold_1(); } uVar1 = DAT_00d00d68; if (DAT_00d00db0 != 0) { (**(code **)(PSI_server + 0x160))(); } pthread_mutex_unlock((pthread_mutex_t *)&DAT_00d00d70); return uVar1; }
31,887
MyStartNode::exec[abi:cxx11](std::nullptr_t)
The-Pocket[P]PocketFlow-CPP/main.cpp
std::string exec(std::nullptr_t /*prepResult*/) override { std::cout << "Starting workflow..." << std::endl; return "started"; }
O1
cpp
MyStartNode::exec[abi:cxx11](std::nullptr_t): pushq %r14 pushq %rbx pushq %rax movq %rdi, %rbx movq 0xdda8(%rip), %r14 # 0x17fb0 leaq 0x7237(%rip), %rsi # 0x11446 movl $0x14, %edx movq %r14, %rdi callq 0x51c0 movq (%r14), %rax movq -0x18(%rax), %rdi addq %r14, %rdi movl $0xa, %esi callq 0x5160 movsbl %al, %esi movq %r14, %rdi callq 0x5030 movq %rax, %rdi callq 0x5100 leaq 0x10(%rbx), %rax movq %rax, (%rbx) leaq 0x6e17(%rip), %rsi # 0x11068 leaq 0x6e17(%rip), %rdx # 0x1106f movq %rbx, %rdi callq 0x90e4 movq %rbx, %rax addq $0x8, %rsp popq %rbx popq %r14 retq nop
_ZN11MyStartNode4execB5cxx11EDn: push r14 push rbx push rax mov rbx, rdi mov r14, cs:_ZSt4cout_ptr lea rsi, aStartingWorkfl; "Starting workflow..." mov edx, 14h 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, [rbx+10h] mov [rbx], rax lea rsi, aStarted; "started" lea rdx, aStarted+7; "" mov rdi, rbx 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, rbx add rsp, 8 pop rbx pop r14 retn
_QWORD * MyStartNode::exec[abi:cxx11](_QWORD *a1) { char v1; // al std::ostream *v2; // rax std::__ostream_insert<char,std::char_traits<char>>(&std::cout, "Starting workflow...", 20LL); v1 = std::ios::widen((char *)&std::cout + *(_QWORD *)(std::cout - 24LL), 10LL); v2 = (std::ostream *)std::ostream::put((std::ostream *)&std::cout, v1); std::ostream::flush(v2); *a1 = a1 + 2; std::string::_M_construct<char const*>(a1, "started", (long long)""); return a1; }
exec[abi:cxx11]: PUSH R14 PUSH RBX PUSH RAX MOV RBX,RDI MOV R14,qword ptr [0x00117fb0] LEA RSI,[0x111446] MOV EDX,0x14 MOV RDI,R14 CALL 0x001051c0 MOV RAX,qword ptr [R14] MOV RDI,qword ptr [RAX + -0x18] ADD RDI,R14 MOV ESI,0xa CALL 0x00105160 MOVSX ESI,AL MOV RDI,R14 CALL 0x00105030 MOV RDI,RAX CALL 0x00105100 LEA RAX,[RBX + 0x10] MOV qword ptr [RBX],RAX LEA RSI,[0x111068] LEA RDX,[0x11106f] MOV RDI,RBX CALL 0x001090e4 MOV RAX,RBX ADD RSP,0x8 POP RBX POP R14 RET
/* MyStartNode::exec[abi:cxx11](decltype(nullptr)) */ _func_decltype_nullptr * MyStartNode::exec_abi_cxx11_(_func_decltype_nullptr *param_1) { char cVar1; int *puVar2; puVar2 = PTR_cout_00117fb0; std::__ostream_insert<char,std::char_traits<char>> ((ostream *)PTR_cout_00117fb0,"Starting workflow...",0x14); cVar1 = (char)puVar2; std::ios::widen((char)*(int8 *)(*(long *)puVar2 + -0x18) + cVar1); std::ostream::put(cVar1); std::ostream::flush(); *(_func_decltype_nullptr **)param_1 = param_1 + 0x10; std::__cxx11::string::_M_construct<char_const*>((string *)param_1,"started",""); return param_1; }
31,888
delete_head_or_tail
eloqsql/storage/maria/ma_blockrec.c
static my_bool delete_head_or_tail(MARIA_HA *info, pgcache_page_no_t page, uint record_number, my_bool head, my_bool from_update) { MARIA_SHARE *share= info->s; uint empty_space; int res; my_bool page_is_empty; uchar *buff; LSN lsn; MARIA_PINNED_PAGE page_link; enum pagecache_page_lock lock_at_write, lock_at_unpin; DBUG_ENTER("delete_head_or_tail"); DBUG_PRINT("enter", ("id: %lu (%lu:%u)", (ulong) ma_recordpos(page, record_number), (ulong) page, record_number)); buff= pagecache_read(share->pagecache, &info->dfile, page, 0, 0, share->page_type, PAGECACHE_LOCK_WRITE, &page_link.link); page_link.unlock= PAGECACHE_LOCK_WRITE_UNLOCK; page_link.changed= buff != 0; push_dynamic(&info->pinned_pages, (void*) &page_link); if (!buff) { _ma_set_fatal_error(info, my_errno); DBUG_RETURN(1); } DBUG_ASSERT((buff[PAGE_TYPE_OFFSET] & PAGE_TYPE_MASK) == (head ? HEAD_PAGE : TAIL_PAGE)); if (from_update) { lock_at_write= PAGECACHE_LOCK_LEFT_WRITELOCKED; lock_at_unpin= PAGECACHE_LOCK_WRITE_UNLOCK; } else { lock_at_write= PAGECACHE_LOCK_WRITE_TO_READ; lock_at_unpin= PAGECACHE_LOCK_READ_UNLOCK; } res= delete_dir_entry(share, buff, record_number, &empty_space); if (res < 0) DBUG_RETURN(1); if (res == 0) /* after our deletion, page is still not empty */ { uchar log_data[FILEID_STORE_SIZE + PAGE_STORE_SIZE + DIRPOS_STORE_SIZE]; LEX_CUSTRING log_array[TRANSLOG_INTERNAL_PARTS + 1]; page_is_empty= 0; if (share->now_transactional) { /* Log REDO data */ page_store(log_data + FILEID_STORE_SIZE, page); dirpos_store(log_data + FILEID_STORE_SIZE + PAGE_STORE_SIZE, record_number); log_array[TRANSLOG_INTERNAL_PARTS + 0].str= log_data; log_array[TRANSLOG_INTERNAL_PARTS + 0].length= sizeof(log_data); if (translog_write_record(&lsn, (head ? LOGREC_REDO_PURGE_ROW_HEAD : LOGREC_REDO_PURGE_ROW_TAIL), info->trn, info, (translog_size_t) sizeof(log_data), TRANSLOG_INTERNAL_PARTS + 1, log_array, log_data, NULL)) DBUG_RETURN(1); } } else /* page is now empty */ { page_is_empty= 1; if (share->now_transactional) { uchar log_data[FILEID_STORE_SIZE + PAGE_STORE_SIZE]; LEX_CUSTRING log_array[TRANSLOG_INTERNAL_PARTS + 1]; page_store(log_data + FILEID_STORE_SIZE, page); log_array[TRANSLOG_INTERNAL_PARTS + 0].str= log_data; log_array[TRANSLOG_INTERNAL_PARTS + 0].length= sizeof(log_data); if (translog_write_record(&lsn, LOGREC_REDO_FREE_HEAD_OR_TAIL, info->trn, info, (translog_size_t) sizeof(log_data), TRANSLOG_INTERNAL_PARTS + 1, log_array, log_data, NULL)) DBUG_RETURN(1); } /* Mark that this page must be written to disk by page cache, even if we could call pagecache_delete() on it. This is needed to ensure that repair finds the empty page on disk and not old data. */ pagecache_set_write_on_delete_by_link(page_link.link); DBUG_ASSERT(empty_space >= share->bitmap.sizes[0]); } pagecache_unlock_by_link(share->pagecache, page_link.link, lock_at_write, PAGECACHE_PIN_LEFT_PINNED, LSN_IMPOSSIBLE, LSN_IMPOSSIBLE, 1, FALSE); page_link.unlock= lock_at_unpin; set_dynamic(&info->pinned_pages, (void*) &page_link, info->pinned_pages.elements-1); DBUG_PRINT("info", ("empty_space: %u", empty_space)); /* If there is not enough space for all possible tails, mark the page full */ if (!head && !page_is_empty && !enough_free_entries(buff, share->block_size, 1 + share->base.blobs)) empty_space= 0; DBUG_RETURN(_ma_bitmap_set(info, page, head, empty_space)); }
O3
c
delete_head_or_tail: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x98, %rsp movl %r8d, -0x3c(%rbp) movl %ecx, -0x40(%rbp) movl %edx, %r12d movq %rsi, %rdx movq %rdi, %r15 movq %fs:0x28, %rax movq %rax, -0x30(%rbp) movq (%rdi), %rbx movq 0x600(%rbx), %rdi leaq 0x470(%r15), %rsi movl 0x7d4(%rbx), %r9d leaq -0x88(%rbp), %r13 movq %rdx, -0x58(%rbp) xorl %ecx, %ecx xorl %r8d, %r8d pushq %r13 pushq $0x4 callq 0x32612 addq $0x10, %rsp movq %rax, %r14 movl $0x6, 0x8(%r13) testq %rax, %rax setne 0x10(%r13) leaq 0x2e8(%r15), %rdi movq %rdi, -0x68(%rbp) movq %r13, %rsi callq 0x91b9e testq %r14, %r14 je 0x5cdad movq %r14, %rsi movq %r15, -0x50(%rbp) xorl %r13d, %r13d cmpb $0x0, -0x3c(%rbp) sete %r13b movl $0x6, %eax subl %r13d, %eax movl %eax, -0x3c(%rbp) movq %rbx, %r14 movl 0x7bc(%rbx), %edi leaq -0x44(%rbp), %rcx movq %rsi, %rbx movl %r12d, -0x60(%rbp) movl %r12d, %edx callq 0x5fa03 movb $0x1, %r15b testl %eax, %eax js 0x5cef9 movl %eax, -0x5c(%rbp) movq %r14, %r12 je 0x5cdc4 cmpb $0x0, 0x7e7(%r14) je 0x5cd9c leaq -0x38(%rbp), %rax movq -0x58(%rbp), %rcx movl %ecx, 0x2(%rax) shrq $0x20, %rcx movb %cl, 0x6(%rax) leaq -0xc0(%rbp), %r10 movq %rax, 0x20(%r10) movq $0x7, 0x28(%r10) movq -0x50(%rbp), %rcx movq 0x8(%rcx), %rdx subq $0x8, %rsp leaq -0x70(%rbp), %rdi movl $0x9, %esi movl $0x7, %r8d movl $0x3, %r9d pushq $0x0 pushq %rax pushq %r10 callq 0x2a8ac addq $0x20, %rsp testb %al, %al jne 0x5cef9 movq -0x88(%rbp), %rdi callq 0x33425 jmp 0x5ce34 callq 0xa1afa movl (%rax), %esi movq %r15, %rdi callq 0x36a24 movb $0x1, %r15b jmp 0x5cef9 cmpb $0x0, 0x7e7(%r14) je 0x5ce34 leaq -0x38(%rbp), %rax movq -0x58(%rbp), %rcx movl %ecx, 0x2(%rax) shrq $0x20, %rcx movb %cl, 0x6(%rax) movl -0x60(%rbp), %ecx movb %cl, 0x7(%rax) leaq -0xc0(%rbp), %r10 movq %rax, 0x20(%r10) movq $0x8, 0x28(%r10) xorl %esi, %esi cmpb $0x1, -0x40(%rbp) adcl $0x6, %esi movq -0x50(%rbp), %rcx movq 0x8(%rcx), %rdx subq $0x8, %rsp leaq -0x70(%rbp), %rdi movl $0x8, %r8d movl $0x3, %r9d pushq $0x0 pushq %rax pushq %r10 callq 0x2a8ac addq $0x20, %rsp testb %al, %al jne 0x5cef9 leal 0x2(%r13,%r13,4), %edx movq 0x600(%r12), %rdi leaq -0x88(%rbp), %r15 movq (%r15), %rsi xorl %ecx, %ecx xorl %r8d, %r8d xorl %r9d, %r9d pushq $0x0 pushq $0x1 callq 0x3232d addq $0x10, %rsp movl -0x3c(%rbp), %eax movl %eax, 0x8(%r15) movq -0x50(%rbp), %r13 movl 0x2f0(%r13), %edx decl %edx movq -0x68(%rbp), %rdi movq %r15, %rsi callq 0x91cb0 movl -0x40(%rbp), %edi testb %dil, %dil jne 0x5cee3 cmpl $0x0, -0x5c(%rbp) jne 0x5cee3 movq %rbx, %r14 movl 0x3f0(%r12), %eax movzbl 0x8(%rbx), %ecx addl %ecx, %eax incl %eax cmpl $0x100, %eax # imm = 0x100 jb 0x5cee3 movb 0x9(%r14), %cl cmpb $-0x1, %cl je 0x5cedc movl 0x7bc(%r12), %edx addl $0xffffff01, %eax # imm = 0xFFFFFF01 addq %r14, %rdx addq $-0x5, %rdx decl %eax je 0x5cee3 movzbl %cl, %ecx shll $0x2, %ecx movq %rdx, %rsi subq %rcx, %rsi movb (%rsi), %cl cmpb $-0x1, %cl jne 0x5cec5 movl $0x0, -0x44(%rbp) movl -0x44(%rbp), %ecx movsbl %dil, %edx movq %r13, %rdi movq -0x58(%rbp), %rsi callq 0x41c7f movl %eax, %r15d movq %fs:0x28, %rax cmpq -0x30(%rbp), %rax jne 0x5cf1d movl %r15d, %eax addq $0x98, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq callq 0x29270
delete_head_or_tail: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx sub rsp, 98h mov [rbp+var_3C], r8d mov [rbp+var_40], ecx mov r12d, edx mov rdx, rsi mov r15, rdi mov rax, fs:28h mov [rbp+var_30], rax mov rbx, [rdi] mov rdi, [rbx+600h] lea rsi, [r15+470h] mov r9d, [rbx+7D4h] lea r13, [rbp+var_88] mov [rbp+var_58], rdx xor ecx, ecx xor r8d, r8d push r13 push 4 call pagecache_read add rsp, 10h mov r14, rax mov dword ptr [r13+8], 6 test rax, rax setnz byte ptr [r13+10h] lea rdi, [r15+2E8h] mov [rbp+var_68], rdi mov rsi, r13 call insert_dynamic test r14, r14 jz loc_5CDAD mov rsi, r14 mov [rbp+var_50], r15 xor r13d, r13d cmp byte ptr [rbp+var_3C], 0 setz r13b mov eax, 6 sub eax, r13d mov [rbp+var_3C], eax mov r14, rbx mov edi, [rbx+7BCh] lea rcx, [rbp+var_44] mov rbx, rsi mov [rbp+var_60], r12d mov edx, r12d call delete_dir_entry mov r15b, 1 test eax, eax js loc_5CEF9 mov [rbp+var_5C], eax mov r12, r14 jz loc_5CDC4 cmp byte ptr [r14+7E7h], 0 jz short loc_5CD9C lea rax, [rbp+var_38] mov rcx, [rbp+var_58] mov [rax+2], ecx shr rcx, 20h mov [rax+6], cl lea r10, [rbp+var_C0] mov [r10+20h], rax mov qword ptr [r10+28h], 7 mov rcx, [rbp+var_50] mov rdx, [rcx+8] sub rsp, 8 lea rdi, [rbp+var_70] mov esi, 9 mov r8d, 7 mov r9d, 3 push 0 push rax push r10 call translog_write_record add rsp, 20h test al, al jnz loc_5CEF9 loc_5CD9C: mov rdi, [rbp+var_88] call pagecache_set_write_on_delete_by_link jmp loc_5CE34 loc_5CDAD: call _my_thread_var mov esi, [rax] mov rdi, r15 call _ma_set_fatal_error mov r15b, 1 jmp loc_5CEF9 loc_5CDC4: cmp byte ptr [r14+7E7h], 0 jz short loc_5CE34 lea rax, [rbp+var_38] mov rcx, [rbp+var_58] mov [rax+2], ecx shr rcx, 20h mov [rax+6], cl mov ecx, [rbp+var_60] mov [rax+7], cl lea r10, [rbp+var_C0] mov [r10+20h], rax mov qword ptr [r10+28h], 8 xor esi, esi cmp byte ptr [rbp+var_40], 1 adc esi, 6 mov rcx, [rbp+var_50] mov rdx, [rcx+8] sub rsp, 8 lea rdi, [rbp+var_70] mov r8d, 8 mov r9d, 3 push 0 push rax push r10 call translog_write_record add rsp, 20h test al, al jnz loc_5CEF9 loc_5CE34: lea edx, [r13+r13*4+2] mov rdi, [r12+600h] lea r15, [rbp+var_88] mov rsi, [r15] xor ecx, ecx xor r8d, r8d xor r9d, r9d push 0 push 1 call pagecache_unlock_by_link add rsp, 10h mov eax, [rbp+var_3C] mov [r15+8], eax mov r13, [rbp+var_50] mov edx, [r13+2F0h] dec edx mov rdi, [rbp+var_68] mov rsi, r15 call set_dynamic mov edi, [rbp+var_40] test dil, dil jnz short loc_5CEE3 cmp [rbp+var_5C], 0 jnz short loc_5CEE3 mov r14, rbx mov eax, [r12+3F0h] movzx ecx, byte ptr [rbx+8] add eax, ecx inc eax cmp eax, 100h jb short loc_5CEE3 mov cl, [r14+9] cmp cl, 0FFh jz short loc_5CEDC mov edx, [r12+7BCh] add eax, 0FFFFFF01h add rdx, r14 add rdx, 0FFFFFFFFFFFFFFFBh loc_5CEC5: dec eax jz short loc_5CEE3 movzx ecx, cl shl ecx, 2 mov rsi, rdx sub rsi, rcx mov cl, [rsi] cmp cl, 0FFh jnz short loc_5CEC5 loc_5CEDC: mov [rbp+var_44], 0 loc_5CEE3: mov ecx, [rbp+var_44] movsx edx, dil mov rdi, r13 mov rsi, [rbp+var_58] call _ma_bitmap_set mov r15d, eax loc_5CEF9: mov rax, fs:28h cmp rax, [rbp+var_30] jnz short loc_5CF1D mov eax, r15d add rsp, 98h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn loc_5CF1D: call ___stack_chk_fail
long long delete_head_or_tail(_DWORD *a1, long long a2, unsigned int a3, int a4, int a5) { _DWORD *v6; // r15 long long v7; // rbx long long v8; // rdi int v9; // r9d long long v10; // r14 BOOL v11; // r13d long long v12; // rdi int v13; // eax unsigned int *v14; // rax long long v15; // rdx long long v16; // rcx long long v17; // r8 int v18; // r9d long long *v19; // r13 unsigned __int8 v20; // cl int v21; // eax _OWORD v23[2]; // [rsp+0h] [rbp-C0h] BYREF __int16 *v24; // [rsp+20h] [rbp-A0h] long long v25; // [rsp+28h] [rbp-98h] long long v26; // [rsp+38h] [rbp-88h] BYREF int v27; // [rsp+40h] [rbp-80h] bool v28; // [rsp+48h] [rbp-78h] char v29[8]; // [rsp+50h] [rbp-70h] BYREF _DWORD *v30; // [rsp+58h] [rbp-68h] unsigned int v31; // [rsp+60h] [rbp-60h] int v32; // [rsp+64h] [rbp-5Ch] unsigned long long v33; // [rsp+68h] [rbp-58h] long long *v34; // [rsp+70h] [rbp-50h] unsigned int v35; // [rsp+7Ch] [rbp-44h] BYREF int v36; // [rsp+80h] [rbp-40h] int v37; // [rsp+84h] [rbp-3Ch] __int16 v38; // [rsp+88h] [rbp-38h] BYREF int v39; // [rsp+8Ah] [rbp-36h] char v40; // [rsp+8Eh] [rbp-32h] char v41; // [rsp+8Fh] [rbp-31h] unsigned long long v42; // [rsp+90h] [rbp-30h] v37 = a5; v36 = a4; v6 = a1; v42 = __readfsqword(0x28u); v7 = *(_QWORD *)a1; v8 = *(_QWORD *)(*(_QWORD *)a1 + 1536LL); v9 = *(_DWORD *)(v7 + 2004); v33 = a2; v10 = pagecache_read(v8, (long long)(v6 + 284), a2, 0, 0LL, v9, 4u, &v26); v27 = 6; v28 = v10 != 0; v30 = v6 + 186; insert_dynamic(v6 + 186, &v26); if ( !v10 ) { v14 = (unsigned int *)my_thread_var(v6 + 186, (const char *)&v26); ma_set_fatal_error(v6, *v14, v15, v16, v17, v18); LOBYTE(v6) = 1; return (unsigned int)v6; } v34 = (long long *)v6; v11 = (_BYTE)v37 == 0; v37 = 6 - v11; v12 = *(unsigned int *)(v7 + 1980); v31 = a3; v13 = delete_dir_entry(v12, v10, a3, &v35); LOBYTE(v6) = 1; if ( v13 >= 0 ) { v32 = v13; if ( v13 ) { if ( *(_BYTE *)(v7 + 2023) ) { v39 = v33; v40 = BYTE4(v33); v24 = &v38; v25 = 7LL; if ( (unsigned __int8)translog_write_record((unsigned long long)v29, byte_9, v34[1], v34, 7u, 3, v23, &v38, 0LL) ) return (unsigned int)v6; } pagecache_set_write_on_delete_by_link(v26); } else if ( *(_BYTE *)(v7 + 2023) ) { v39 = v33; v40 = BYTE4(v33); v41 = v31; v24 = &v38; v25 = 8LL; if ( (unsigned __int8)translog_write_record( (unsigned long long)v29, (_WORD *)((unsigned int)((_BYTE)v36 == 0) + 6), v34[1], v34, 8u, 3, v23, &v38, 0LL) ) return (unsigned int)v6; } pagecache_unlock_by_link(*(_QWORD *)(v7 + 1536), v26, 5 * v11 + 2, 0, 0LL, 0LL, 1); v27 = v37; v19 = v34; set_dynamic(v30, &v26, (unsigned int)(*((_DWORD *)v34 + 188) - 1)); if ( !(_BYTE)v36 && !v32 && (unsigned int)*(unsigned __int8 *)(v10 + 8) + *(_DWORD *)(v7 + 1008) + 1 >= 0x100 ) { v20 = *(_BYTE *)(v10 + 9); if ( v20 == 0xFF ) { LABEL_17: v35 = 0; } else { v21 = *(unsigned __int8 *)(v10 + 8) + *(_DWORD *)(v7 + 1008) - 254; while ( --v21 ) { v20 = *(_BYTE *)(v10 + *(unsigned int *)(v7 + 1980) - 5 - 4 * (unsigned int)v20); if ( v20 == 0xFF ) goto LABEL_17; } } } LODWORD(v6) = ma_bitmap_set(v19, v33, v36, v35); } return (unsigned int)v6; }
delete_head_or_tail: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x98 MOV dword ptr [RBP + -0x3c],R8D MOV dword ptr [RBP + -0x40],ECX MOV R12D,EDX MOV RDX,RSI MOV R15,RDI MOV RAX,qword ptr FS:[0x28] MOV qword ptr [RBP + -0x30],RAX MOV RBX,qword ptr [RDI] MOV RDI,qword ptr [RBX + 0x600] LEA RSI,[R15 + 0x470] MOV R9D,dword ptr [RBX + 0x7d4] LEA R13,[RBP + -0x88] MOV qword ptr [RBP + -0x58],RDX XOR ECX,ECX XOR R8D,R8D PUSH R13 PUSH 0x4 CALL 0x00132612 ADD RSP,0x10 MOV R14,RAX MOV dword ptr [R13 + 0x8],0x6 TEST RAX,RAX SETNZ byte ptr [R13 + 0x10] LEA RDI,[R15 + 0x2e8] MOV qword ptr [RBP + -0x68],RDI MOV RSI,R13 CALL 0x00191b9e TEST R14,R14 JZ 0x0015cdad MOV RSI,R14 MOV qword ptr [RBP + -0x50],R15 XOR R13D,R13D CMP byte ptr [RBP + -0x3c],0x0 SETZ R13B MOV EAX,0x6 SUB EAX,R13D MOV dword ptr [RBP + -0x3c],EAX MOV R14,RBX MOV EDI,dword ptr [RBX + 0x7bc] LEA RCX,[RBP + -0x44] MOV RBX,RSI MOV dword ptr [RBP + -0x60],R12D MOV EDX,R12D CALL 0x0015fa03 MOV R15B,0x1 TEST EAX,EAX JS 0x0015cef9 MOV dword ptr [RBP + -0x5c],EAX MOV R12,R14 JZ 0x0015cdc4 CMP byte ptr [R14 + 0x7e7],0x0 JZ 0x0015cd9c LEA RAX,[RBP + -0x38] MOV RCX,qword ptr [RBP + -0x58] MOV dword ptr [RAX + 0x2],ECX SHR RCX,0x20 MOV byte ptr [RAX + 0x6],CL LEA R10,[RBP + -0xc0] MOV qword ptr [R10 + 0x20],RAX MOV qword ptr [R10 + 0x28],0x7 MOV RCX,qword ptr [RBP + -0x50] MOV RDX,qword ptr [RCX + 0x8] SUB RSP,0x8 LEA RDI,[RBP + -0x70] MOV ESI,0x9 MOV R8D,0x7 MOV R9D,0x3 PUSH 0x0 PUSH RAX PUSH R10 CALL 0x0012a8ac ADD RSP,0x20 TEST AL,AL JNZ 0x0015cef9 LAB_0015cd9c: MOV RDI,qword ptr [RBP + -0x88] CALL 0x00133425 JMP 0x0015ce34 LAB_0015cdad: CALL 0x001a1afa MOV ESI,dword ptr [RAX] MOV RDI,R15 CALL 0x00136a24 MOV R15B,0x1 JMP 0x0015cef9 LAB_0015cdc4: CMP byte ptr [R14 + 0x7e7],0x0 JZ 0x0015ce34 LEA RAX,[RBP + -0x38] MOV RCX,qword ptr [RBP + -0x58] MOV dword ptr [RAX + 0x2],ECX SHR RCX,0x20 MOV byte ptr [RAX + 0x6],CL MOV ECX,dword ptr [RBP + -0x60] MOV byte ptr [RAX + 0x7],CL LEA R10,[RBP + -0xc0] MOV qword ptr [R10 + 0x20],RAX MOV qword ptr [R10 + 0x28],0x8 XOR ESI,ESI CMP byte ptr [RBP + -0x40],0x1 ADC ESI,0x6 MOV RCX,qword ptr [RBP + -0x50] MOV RDX,qword ptr [RCX + 0x8] SUB RSP,0x8 LEA RDI,[RBP + -0x70] MOV R8D,0x8 MOV R9D,0x3 PUSH 0x0 PUSH RAX PUSH R10 CALL 0x0012a8ac ADD RSP,0x20 TEST AL,AL JNZ 0x0015cef9 LAB_0015ce34: LEA EDX,[R13 + R13*0x4 + 0x2] MOV RDI,qword ptr [R12 + 0x600] LEA R15,[RBP + -0x88] MOV RSI,qword ptr [R15] XOR ECX,ECX XOR R8D,R8D XOR R9D,R9D PUSH 0x0 PUSH 0x1 CALL 0x0013232d ADD RSP,0x10 MOV EAX,dword ptr [RBP + -0x3c] MOV dword ptr [R15 + 0x8],EAX MOV R13,qword ptr [RBP + -0x50] MOV EDX,dword ptr [R13 + 0x2f0] DEC EDX MOV RDI,qword ptr [RBP + -0x68] MOV RSI,R15 CALL 0x00191cb0 MOV EDI,dword ptr [RBP + -0x40] TEST DIL,DIL JNZ 0x0015cee3 CMP dword ptr [RBP + -0x5c],0x0 JNZ 0x0015cee3 MOV R14,RBX MOV EAX,dword ptr [R12 + 0x3f0] MOVZX ECX,byte ptr [RBX + 0x8] ADD EAX,ECX INC EAX CMP EAX,0x100 JC 0x0015cee3 MOV CL,byte ptr [R14 + 0x9] CMP CL,0xff JZ 0x0015cedc MOV EDX,dword ptr [R12 + 0x7bc] ADD EAX,0xffffff01 ADD RDX,R14 ADD RDX,-0x5 LAB_0015cec5: DEC EAX JZ 0x0015cee3 MOVZX ECX,CL SHL ECX,0x2 MOV RSI,RDX SUB RSI,RCX MOV CL,byte ptr [RSI] CMP CL,0xff JNZ 0x0015cec5 LAB_0015cedc: MOV dword ptr [RBP + -0x44],0x0 LAB_0015cee3: MOV ECX,dword ptr [RBP + -0x44] MOVSX EDX,DIL MOV RDI,R13 MOV RSI,qword ptr [RBP + -0x58] CALL 0x00141c7f MOV R15D,EAX LAB_0015cef9: MOV RAX,qword ptr FS:[0x28] CMP RAX,qword ptr [RBP + -0x30] JNZ 0x0015cf1d MOV EAX,R15D ADD RSP,0x98 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET LAB_0015cf1d: CALL 0x00129270
ulong delete_head_or_tail(long *param_1,int8 param_2,int4 param_3,int4 param_4, int param_5) { long lVar1; long *plVar2; char cVar3; int iVar4; uint uVar5; long lVar6; int4 *puVar7; int1 uVar8; byte bVar9; int7 uVar11; ulong uVar10; long in_FS_OFFSET; bool bVar12; int1 local_c8 [32]; int1 *local_a8; int8 local_a0; int8 local_90; int local_88; int1 local_80; int1 local_78 [8]; long *local_70; int4 local_68; int local_64; int8 local_60; long *local_58; int4 local_4c; int4 local_48; int local_44; int1 local_40 [2]; int4 local_3e; int1 local_3a; int1 local_39; long local_38; local_38 = *(long *)(in_FS_OFFSET + 0x28); lVar1 = *param_1; local_60 = param_2; local_48 = param_4; local_44 = param_5; lVar6 = pagecache_read(*(int8 *)(lVar1 + 0x600),param_1 + 0x8e,param_2,0,0, *(int4 *)(lVar1 + 0x7d4),4,&local_90); local_88 = 6; local_80 = lVar6 != 0; local_70 = param_1 + 0x5d; insert_dynamic(local_70,&local_90); uVar11 = (int7)((ulong)param_1 >> 8); if (lVar6 == 0) { puVar7 = (int4 *)_my_thread_var(); _ma_set_fatal_error(param_1,*puVar7); uVar10 = CONCAT71(uVar11,1); } else { bVar12 = (char)local_44 == '\0'; local_44 = 6 - (uint)bVar12; local_68 = param_3; local_58 = param_1; iVar4 = delete_dir_entry(*(int4 *)(lVar1 + 0x7bc),lVar6,param_3,&local_4c); uVar10 = CONCAT71(uVar11,1); if (-1 < iVar4) { uVar8 = (int1)((ulong)local_60 >> 0x20); local_64 = iVar4; if (iVar4 == 0) { if (*(char *)(lVar1 + 0x7e7) != '\0') { local_a8 = local_40; local_39 = (int1)local_68; local_a0 = 8; local_3e = (int)local_60; local_3a = uVar8; cVar3 = translog_write_record (local_78,((char)local_48 == '\0') + '\x06',local_58[1],local_58,8,3, local_c8,local_a8,0); if (cVar3 != '\0') goto LAB_0015cef9; } } else { if (*(char *)(lVar1 + 0x7e7) != '\0') { local_a8 = local_40; local_a0 = 7; local_3e = (int)local_60; local_3a = uVar8; cVar3 = translog_write_record(local_78,9,local_58[1],local_58,7,3,local_c8,local_a8,0); if (cVar3 != '\0') goto LAB_0015cef9; } pagecache_set_write_on_delete_by_link(local_90); } pagecache_unlock_by_link (*(int8 *)(lVar1 + 0x600),local_90,bVar12 * '\x05' + '\x02',0,0,0,1,0); plVar2 = local_58; local_88 = local_44; set_dynamic(local_70,&local_90,(int)local_58[0x5e] + -1); if ((((char)local_48 == '\0') && (local_64 == 0)) && (iVar4 = *(int *)(lVar1 + 0x3f0) + (uint)*(byte *)(lVar6 + 8), 0xff < iVar4 + 1U)) { bVar9 = *(byte *)(lVar6 + 9); if (bVar9 != 0xff) { iVar4 = iVar4 + -0xfe; do { iVar4 = iVar4 + -1; if (iVar4 == 0) goto LAB_0015cee3; bVar9 = *(byte *)((ulong)*(uint *)(lVar1 + 0x7bc) + lVar6 + -5 + (ulong)bVar9 * -4); } while (bVar9 != 0xff); } local_4c = 0; } LAB_0015cee3: uVar5 = _ma_bitmap_set(plVar2,local_60,(int)(char)local_48,local_4c); uVar10 = (ulong)uVar5; } } LAB_0015cef9: if (*(long *)(in_FS_OFFSET + 0x28) == local_38) { return uVar10 & 0xffffffff; } /* WARNING: Subroutine does not return */ __stack_chk_fail(); }
31,889
nlohmann::json_abi_v3_11_3::detail::type_error nlohmann::json_abi_v3_11_3::detail::type_error::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*)
monkey531[P]llama/common/json.hpp
static type_error create(int id_, const std::string& what_arg, BasicJsonContext context) { const std::string w = concat(exception::name("type_error", id_), exception::diagnostics(context), what_arg); return {id_, w.c_str()}; }
O1
cpp
nlohmann::json_abi_v3_11_3::detail::type_error nlohmann::json_abi_v3_11_3::detail::type_error::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 0x6e34d(%rip), %rsi # 0xb1630 leaq 0x6e350(%rip), %rdx # 0xb163a leaq 0x28(%rsp), %rdi callq 0x2175a leaq 0x48(%rsp), %rdi leaq 0x28(%rsp), %rsi movl %ebp, %edx callq 0x43532 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 0x19ab0 movq 0x48(%rsp), %rsi movq 0x50(%rsp), %rdx leaq 0x8(%rsp), %rdi callq 0x191e0 movq 0x68(%rsp), %rsi movq 0x70(%rsp), %rdx leaq 0x8(%rsp), %rdi callq 0x191e0 movq (%r15), %rsi movq 0x8(%r15), %rdx leaq 0x8(%rsp), %rdi callq 0x191e0 movq 0x68(%rsp), %rdi cmpq %r14, %rdi je 0x4338d movq 0x78(%rsp), %rsi incq %rsi callq 0x196e0 leaq 0x58(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0x433a8 movq 0x58(%rsp), %rsi incq %rsi callq 0x196e0 movq 0x28(%rsp), %rdi cmpq %r13, %rdi je 0x433bf movq 0x38(%rsp), %rsi incq %rsi callq 0x196e0 movq 0x8(%rsp), %rdx movq %rbx, %rdi movl %ebp, %esi callq 0x4372e leaq 0x9ff0b(%rip), %rax # 0xe32e0 addq $0x10, %rax movq %rax, (%rbx) movq 0x8(%rsp), %rdi cmpq %r12, %rdi je 0x433f3 movq 0x18(%rsp), %rsi incq %rsi callq 0x196e0 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 0x43481 movq 0x18(%rsp), %rsi jmp 0x43479 movq %rax, %rbx jmp 0x4346a movq %rax, %rbx jmp 0x43481 movq %rdx, %rbx movq %rax, %r15 movq 0x8(%rsp), %rdi cmpq %r12, %rdi je 0x43443 movq 0x18(%rsp), %rsi incq %rsi callq 0x196e0 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 0x1a2f1 movq (%r12), %rbx movq 0x28(%rsp), %rdi cmpq %r13, %rdi je 0x43481 movq 0x38(%rsp), %rsi incq %rsi callq 0x196e0 movq %rbx, %rdi callq 0x19c10
_ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIPKNS0_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, aTypeError; "type_error" lea rdx, aTypeError+0Ah; "" 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_4338D mov rsi, [rsp+0C8h+var_50] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_4338D: lea rax, [rsp+0C8h+var_70] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_433A8 mov rsi, [rsp+0C8h+var_70] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_433A8: mov rdi, [rsp+0C8h+var_A0]; void * cmp rdi, r13 jz short loc_433BF mov rsi, [rsp+0C8h+var_90] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_433BF: 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, _ZTVN8nlohmann16json_abi_v3_11_36detail10type_errorE; `vtable for'nlohmann::json_abi_v3_11_3::detail::type_error add rax, 10h mov [rbx], rax mov rdi, [rsp+0C8h+var_C0]; void * cmp rdi, r12 jz short loc_433F3 mov rsi, [rsp+0C8h+var_B0] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_433F3: 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_43481 mov rsi, [rsp+arg_10] jmp short loc_43479 mov rbx, rax jmp short loc_4346A mov rbx, rax jmp short loc_43481 mov rbx, rdx mov r15, rax mov rdi, [rsp+arg_0]; void * cmp rdi, r12 jz short loc_43443 mov rsi, [rsp+arg_10] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_43443: 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_36detail10type_error6createIPKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SK__cold_1 mov rbx, [r12] loc_4346A: mov rdi, [rsp+arg_20]; void * cmp rdi, r13 jz short loc_43481 mov rsi, [rsp+arg_30] loc_43479: inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_43481: mov rdi, rbx call __Unwind_Resume
nlohmann::json_abi_v3_11_3::detail::exception * ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIPKNS0_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) { int v4; // ecx int v5; // r8d int v6; // r9d int v8; // [rsp+0h] [rbp-C8h] char *v9; // [rsp+8h] [rbp-C0h] BYREF void *v10; // [rsp+10h] [rbp-B8h] _QWORD v11[2]; // [rsp+18h] [rbp-B0h] BYREF void *v12[2]; // [rsp+28h] [rbp-A0h] BYREF _QWORD v13[2]; // [rsp+38h] [rbp-90h] BYREF int v14[2]; // [rsp+48h] [rbp-80h] BYREF long long v15; // [rsp+50h] [rbp-78h] long long v16; // [rsp+58h] [rbp-70h] BYREF void *v17; // [rsp+68h] [rbp-60h] long long v18; // [rsp+70h] [rbp-58h] _QWORD v19[10]; // [rsp+78h] [rbp-50h] BYREF v12[0] = v13; std::string::_M_construct<char const*>(v12, "type_error", (long long)""); nlohmann::json_abi_v3_11_3::detail::exception::name( (int)v14, (int)v12, a2, v4, v5, v6, v8, (int)v9, v10, v11[0], v11[1]); v17 = v19; v18 = 0LL; LOBYTE(v19[0]) = 0; v9 = (char *)v11; v10 = 0LL; LOBYTE(v11[0]) = 0; std::string::reserve(&v9, v15 + a3[1]); std::string::_M_append(&v9, *(_QWORD *)v14, v15); std::string::_M_append(&v9, v17, v18); std::string::_M_append(&v9, *a3, a3[1]); if ( v17 != v19 ) operator delete(v17, v19[0] + 1LL); if ( *(long long **)v14 != &v16 ) operator delete(*(void **)v14, v16 + 1); if ( v12[0] != v13 ) operator delete(v12[0], v13[0] + 1LL); nlohmann::json_abi_v3_11_3::detail::exception::exception(this, a2, v9); *(_QWORD *)this = &`vtable for'nlohmann::json_abi_v3_11_3::detail::type_error + 2; if ( v9 != (char *)v11 ) operator delete(v9, v11[0] + 1LL); return this; }
_ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIPKNS0_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_001432dc: LEA RSI,[0x1b1630] LEA RDX,[0x1b163a] LEA RDI,[RSP + 0x28] CALL 0x0012175a LAB_001432f4: LEA RDI,[RSP + 0x48] LEA RSI,[RSP + 0x28] MOV EDX,EBP CALL 0x00143532 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_00143333: LEA RDI,[RSP + 0x8] CALL 0x00119ab0 MOV RSI,qword ptr [RSP + 0x48] MOV RDX,qword ptr [RSP + 0x50] LEA RDI,[RSP + 0x8] CALL 0x001191e0 MOV RSI,qword ptr [RSP + 0x68] MOV RDX,qword ptr [RSP + 0x70] LEA RDI,[RSP + 0x8] CALL 0x001191e0 MOV RSI,qword ptr [R15] MOV RDX,qword ptr [R15 + 0x8] LEA RDI,[RSP + 0x8] CALL 0x001191e0 MOV RDI,qword ptr [RSP + 0x68] CMP RDI,R14 JZ 0x0014338d MOV RSI,qword ptr [RSP + 0x78] INC RSI CALL 0x001196e0 LAB_0014338d: LEA RAX,[RSP + 0x58] MOV RDI,qword ptr [RAX + -0x10] CMP RDI,RAX JZ 0x001433a8 MOV RSI,qword ptr [RSP + 0x58] INC RSI CALL 0x001196e0 LAB_001433a8: MOV RDI,qword ptr [RSP + 0x28] CMP RDI,R13 JZ 0x001433bf MOV RSI,qword ptr [RSP + 0x38] INC RSI CALL 0x001196e0 LAB_001433bf: MOV RDX,qword ptr [RSP + 0x8] LAB_001433c4: MOV RDI,RBX MOV ESI,EBP CALL 0x0014372e LAB_001433ce: LEA RAX,[0x1e32e0] ADD RAX,0x10 MOV qword ptr [RBX],RAX MOV RDI,qword ptr [RSP + 0x8] CMP RDI,R12 JZ 0x001433f3 MOV RSI,qword ptr [RSP + 0x18] INC RSI CALL 0x001196e0 LAB_001433f3: MOV RAX,RBX ADD RSP,0x98 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
exception * _ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIPKNS0_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 001432dc to 001432f3 has its CatchHandler @ 00143421 */ local_a0[0] = local_90; std::__cxx11::string::_M_construct<char_const*>(local_a0,"type_error",""); /* try { // try from 001432f4 to 00143304 has its CatchHandler @ 0014341c */ 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 00143333 to 00143375 has its CatchHandler @ 00143426 */ 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 001433c4 to 001433cd has its CatchHandler @ 00143408 */ nlohmann::json_abi_v3_11_3::detail::exception::exception(param_1,param_2,local_c0); *(int ***)param_1 = &PTR__exception_001e32f0; if (local_c0 != &local_b0) { operator_delete(local_c0,CONCAT71(uStack_af,local_b0) + 1); } return param_1; }
31,890
nlohmann::json_abi_v3_11_3::detail::type_error nlohmann::json_abi_v3_11_3::detail::type_error::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*)
monkey531[P]llama/common/json.hpp
static type_error create(int id_, const std::string& what_arg, BasicJsonContext context) { const std::string w = concat(exception::name("type_error", id_), exception::diagnostics(context), what_arg); return {id_, w.c_str()}; }
O3
cpp
nlohmann::json_abi_v3_11_3::detail::type_error nlohmann::json_abi_v3_11_3::detail::type_error::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 0x457bf(%rip), %rsi # 0xad620 leaq 0x457c2(%rip), %rdx # 0xad62a leaq 0x28(%rsp), %rdi callq 0x200f4 leaq 0x48(%rsp), %rdi leaq 0x28(%rsp), %rsi movl %ebp, %edx callq 0x41306 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 0x18ab0 movq 0x48(%rsp), %rsi movq 0x50(%rsp), %rdx leaq 0x8(%rsp), %rdi callq 0x181e0 movq 0x68(%rsp), %rsi movq 0x70(%rsp), %rdx leaq 0x8(%rsp), %rdi callq 0x181e0 movq (%r15), %rsi movq 0x8(%r15), %rdx leaq 0x8(%rsp), %rdi callq 0x181e0 movq 0x68(%rsp), %rdi cmpq %r14, %rdi je 0x67f0b movq 0x78(%rsp), %rsi incq %rsi callq 0x186e0 leaq 0x58(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0x67f26 movq 0x58(%rsp), %rsi incq %rsi callq 0x186e0 movq 0x28(%rsp), %rdi cmpq %r13, %rdi je 0x67f3d movq 0x38(%rsp), %rsi incq %rsi callq 0x186e0 movq 0x8(%rsp), %rdx movq %rbx, %rdi movl %ebp, %esi callq 0x41502 leaq 0x7738d(%rip), %rax # 0xdf2e0 addq $0x10, %rax movq %rax, (%rbx) movq 0x8(%rsp), %rdi cmpq %r12, %rdi je 0x67f71 movq 0x18(%rsp), %rsi incq %rsi callq 0x186e0 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 0x67fff movq 0x18(%rsp), %rsi jmp 0x67ff7 movq %rax, %rbx jmp 0x67fe8 movq %rax, %rbx jmp 0x67fff movq %rdx, %rbx movq %rax, %r15 movq 0x8(%rsp), %rdi cmpq %r12, %rdi je 0x67fc1 movq 0x18(%rsp), %rsi incq %rsi callq 0x186e0 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 0x197e2 movq (%r12), %rbx movq 0x28(%rsp), %rdi cmpq %r13, %rdi je 0x67fff movq 0x38(%rsp), %rsi incq %rsi callq 0x186e0 movq %rbx, %rdi callq 0x18c10 nop
_ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIDnTnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES5_: 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, aTypeError; "type_error" lea rdx, aTypeError+0Ah; "" 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_67F0B mov rsi, [rsp+0C8h+var_50] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_67F0B: lea rax, [rsp+0C8h+var_70] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_67F26 mov rsi, [rsp+0C8h+var_70] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_67F26: mov rdi, [rsp+0C8h+var_A0]; void * cmp rdi, r13 jz short loc_67F3D mov rsi, [rsp+0C8h+var_90] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_67F3D: 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, _ZTVN8nlohmann16json_abi_v3_11_36detail10type_errorE; `vtable for'nlohmann::json_abi_v3_11_3::detail::type_error add rax, 10h mov [rbx], rax mov rdi, [rsp+0C8h+var_C0]; void * cmp rdi, r12 jz short loc_67F71 mov rsi, [rsp+0C8h+var_B0] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_67F71: 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_67FFF mov rsi, [rsp+arg_10] jmp short loc_67FF7 mov rbx, rax jmp short loc_67FE8 mov rbx, rax jmp short loc_67FFF mov rbx, rdx mov r15, rax mov rdi, [rsp+arg_0]; void * cmp rdi, r12 jz short loc_67FC1 mov rsi, [rsp+arg_10] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_67FC1: 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_36detail10type_error6createIDnTnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES5__cold_1 mov rbx, [r12] loc_67FE8: mov rdi, [rsp+arg_20]; void * cmp rdi, r13 jz short loc_67FFF mov rsi, [rsp+arg_30] loc_67FF7: inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_67FFF: mov rdi, rbx call __Unwind_Resume
nlohmann::json_abi_v3_11_3::detail::exception * ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIDnTnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES5_( 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, "type_error", (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 = &`vtable for'nlohmann::json_abi_v3_11_3::detail::type_error + 2; if ( (_QWORD *)v5[0] != v6 ) operator delete(v5[0], v6[0] + 1LL); return this; }
_ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIDnTnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES5_: 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_00167e5a: LEA RSI,[0x1ad620] LEA RDX,[0x1ad62a] LEA RDI,[RSP + 0x28] CALL 0x001200f4 LAB_00167e72: LEA RDI,[RSP + 0x48] LEA RSI,[RSP + 0x28] MOV EDX,EBP CALL 0x00141306 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_00167eb1: LEA RDI,[RSP + 0x8] CALL 0x00118ab0 MOV RSI,qword ptr [RSP + 0x48] MOV RDX,qword ptr [RSP + 0x50] LEA RDI,[RSP + 0x8] CALL 0x001181e0 MOV RSI,qword ptr [RSP + 0x68] MOV RDX,qword ptr [RSP + 0x70] LEA RDI,[RSP + 0x8] CALL 0x001181e0 MOV RSI,qword ptr [R15] MOV RDX,qword ptr [R15 + 0x8] LEA RDI,[RSP + 0x8] CALL 0x001181e0 MOV RDI,qword ptr [RSP + 0x68] CMP RDI,R14 JZ 0x00167f0b MOV RSI,qword ptr [RSP + 0x78] INC RSI CALL 0x001186e0 LAB_00167f0b: LEA RAX,[RSP + 0x58] MOV RDI,qword ptr [RAX + -0x10] CMP RDI,RAX JZ 0x00167f26 MOV RSI,qword ptr [RSP + 0x58] INC RSI CALL 0x001186e0 LAB_00167f26: MOV RDI,qword ptr [RSP + 0x28] CMP RDI,R13 JZ 0x00167f3d MOV RSI,qword ptr [RSP + 0x38] INC RSI CALL 0x001186e0 LAB_00167f3d: MOV RDX,qword ptr [RSP + 0x8] LAB_00167f42: MOV RDI,RBX MOV ESI,EBP CALL 0x00141502 LAB_00167f4c: LEA RAX,[0x1df2e0] ADD RAX,0x10 MOV qword ptr [RBX],RAX MOV RDI,qword ptr [RSP + 0x8] CMP RDI,R12 JZ 0x00167f71 MOV RSI,qword ptr [RSP + 0x18] INC RSI CALL 0x001186e0 LAB_00167f71: MOV RAX,RBX ADD RSP,0x98 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
exception * _ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIDnTnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES5_ (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 00167e5a to 00167e71 has its CatchHandler @ 00167f9f */ local_a0[0] = local_90; std::__cxx11::string::_M_construct<char_const*>(local_a0,"type_error",""); /* try { // try from 00167e72 to 00167e82 has its CatchHandler @ 00167f9a */ 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 00167eb1 to 00167ef3 has its CatchHandler @ 00167fa4 */ 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 00167f42 to 00167f4b has its CatchHandler @ 00167f86 */ nlohmann::json_abi_v3_11_3::detail::exception::exception(param_1,param_2,local_c0); *(int ***)param_1 = &PTR__exception_001df2f0; if (local_c0 != &local_b0) { operator_delete(local_c0,CONCAT71(uStack_af,local_b0) + 1); } return param_1; }
31,891
ma_tls_connect
eloqsql/libmariadb/libmariadb/secure/openssl.c
my_bool ma_tls_connect(MARIADB_TLS *ctls) { SSL *ssl = (SSL *)ctls->ssl; my_bool blocking, try_connect= 1; MYSQL *mysql; MARIADB_PVIO *pvio; int rc; #ifdef OPENSSL_USE_BIOMETHOD BIO_METHOD *bio_method= NULL; BIO *bio; #endif mysql= (MYSQL *)SSL_get_app_data(ssl); pvio= mysql->net.pvio; /* Set socket to non blocking if not already set */ if (!(blocking= pvio->methods->is_blocking(pvio))) pvio->methods->blocking(pvio, FALSE, 0); SSL_clear(ssl); #ifdef OPENSSL_USE_BIOMETHOD bio= BIO_new(&ma_BIO_method); bio->ptr= pvio; SSL_set_bio(ssl, bio, bio); BIO_set_fd(bio, mysql_get_socket(mysql), BIO_NOCLOSE); #else SSL_set_fd(ssl, (int)mysql_get_socket(mysql)); #endif while (try_connect && (rc= SSL_connect(ssl)) == -1) { switch((SSL_get_error(ssl, rc))) { case SSL_ERROR_WANT_READ: if (pvio->methods->wait_io_or_timeout(pvio, TRUE, mysql->options.connect_timeout) < 1) try_connect= 0; break; case SSL_ERROR_WANT_WRITE: if (pvio->methods->wait_io_or_timeout(pvio, TRUE, mysql->options.connect_timeout) < 1) try_connect= 0; break; default: try_connect= 0; } } /* In case handshake failed or if a root certificate (ca) was specified, we need to check the result code of X509 verification. A detailed check of the peer certificate (hostname checking will follow later) */ if (rc != 1 || (mysql->client_flag & CLIENT_SSL_VERIFY_SERVER_CERT) || (mysql->options.ssl_ca || mysql->options.ssl_capath)) { long x509_err= SSL_get_verify_result(ssl); if (x509_err != X509_V_OK) { my_set_error(mysql, CR_SSL_CONNECTION_ERROR, SQLSTATE_UNKNOWN, ER(CR_SSL_CONNECTION_ERROR), X509_verify_cert_error_string(x509_err)); /* restore blocking mode */ if (!blocking) pvio->methods->blocking(pvio, FALSE, 0); return 1; } else if (rc != 1) { ma_tls_set_error(mysql); return 1; } } pvio->ctls->ssl= ctls->ssl= (void *)ssl; return 0; }
O3
c
ma_tls_connect: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx pushq %rax movq %rdi, -0x30(%rbp) movq 0x10(%rdi), %r12 movq %r12, %rdi xorl %esi, %esi callq 0x13160 movq %rax, %r14 movq (%rax), %rbx movq 0x48(%rbx), %rax movq %rbx, %rdi callq *0x68(%rax) movl %eax, %r15d testb %al, %al jne 0x2afea movq 0x48(%rbx), %rax movq %rbx, %rdi xorl %esi, %esi xorl %edx, %edx callq *0x38(%rax) movq %r12, %rdi callq 0x130b0 movq %r14, %rdi callq 0x1f50f movq %r12, %rdi movl %eax, %esi callq 0x132b0 movq %r12, %rdi callq 0x13670 cmpl $-0x1, %eax jne 0x2b044 movq %r12, %rdi movl $0xffffffff, %esi # imm = 0xFFFFFFFF callq 0x13050 cmpl $0x3, %eax je 0x2b028 cmpl $0x2, %eax jne 0x2b092 movq 0x48(%rbx), %rax movl 0x390(%r14), %edx movq %rbx, %rdi movl $0x1, %esi callq *0x30(%rax) testl %eax, %eax jg 0x2b004 jmp 0x2b092 movl %eax, %r13d cmpl $0x1, %eax jne 0x2b092 testb $0x40, 0x36b(%r14) jne 0x2b06a cmpq $0x0, 0x410(%r14) jne 0x2b06a cmpq $0x0, 0x418(%r14) je 0x2b07d movq %r12, %rdi callq 0x13190 testq %rax, %rax jne 0x2b09f cmpl $0x1, %r13d jne 0x2b0ef movq -0x30(%rbp), %rax movq %r12, 0x10(%rax) movq 0x38(%rbx), %rax movq %r12, 0x10(%rax) xorl %r14d, %r14d jmp 0x2b0fa movq %r12, %rdi callq 0x13190 testq %rax, %rax je 0x2b0ef leaq 0x22cda(%rip), %rcx # 0x4dd80 movq (%rcx), %r12 leaq 0x22ce0(%rip), %rcx # 0x4dd90 movq 0xd0(%rcx), %r13 movq %rax, %rdi callq 0x132f0 movq %r14, %rdi movl $0x7ea, %esi # imm = 0x7EA movq %r12, %rdx movq %r13, %rcx movq %rax, %r8 xorl %eax, %eax callq 0x184d1 movb $0x1, %r14b testb %r15b, %r15b jne 0x2b0fa movq 0x48(%rbx), %rax movq %rbx, %rdi xorl %esi, %esi xorl %edx, %edx callq *0x38(%rax) jmp 0x2b0fa movq %r14, %rdi callq 0x2b10c movb $0x1, %r14b movl %r14d, %eax addq $0x8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
ma_tls_connect: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx push rax mov [rbp+var_30], rdi mov r12, [rdi+10h] mov rdi, r12 xor esi, esi call _SSL_get_ex_data mov r14, rax mov rbx, [rax] mov rax, [rbx+48h] mov rdi, rbx call qword ptr [rax+68h] mov r15d, eax test al, al jnz short loc_2AFEA mov rax, [rbx+48h] mov rdi, rbx xor esi, esi xor edx, edx call qword ptr [rax+38h] loc_2AFEA: mov rdi, r12 call _SSL_clear mov rdi, r14 call mysql_get_socket mov rdi, r12 mov esi, eax call _SSL_set_fd loc_2B004: mov rdi, r12 call _SSL_connect cmp eax, 0FFFFFFFFh jnz short loc_2B044 mov rdi, r12 mov esi, 0FFFFFFFFh call _SSL_get_error cmp eax, 3 jz short loc_2B028 cmp eax, 2 jnz short loc_2B092 loc_2B028: mov rax, [rbx+48h] mov edx, [r14+390h] mov rdi, rbx mov esi, 1 call qword ptr [rax+30h] test eax, eax jg short loc_2B004 jmp short loc_2B092 loc_2B044: mov r13d, eax cmp eax, 1 jnz short loc_2B092 test byte ptr [r14+36Bh], 40h jnz short loc_2B06A cmp qword ptr [r14+410h], 0 jnz short loc_2B06A cmp qword ptr [r14+418h], 0 jz short loc_2B07D loc_2B06A: mov rdi, r12 call _SSL_get_verify_result test rax, rax jnz short loc_2B09F cmp r13d, 1 jnz short loc_2B0EF loc_2B07D: mov rax, [rbp+var_30] mov [rax+10h], r12 mov rax, [rbx+38h] mov [rax+10h], r12 xor r14d, r14d jmp short loc_2B0FA loc_2B092: mov rdi, r12 call _SSL_get_verify_result test rax, rax jz short loc_2B0EF loc_2B09F: lea rcx, SQLSTATE_UNKNOWN mov r12, [rcx] lea rcx, client_errors mov r13, [rcx+0D0h] mov rdi, rax call _X509_verify_cert_error_string mov rdi, r14 mov esi, 7EAh mov rdx, r12 mov rcx, r13 mov r8, rax xor eax, eax call my_set_error mov r14b, 1 test r15b, r15b jnz short loc_2B0FA mov rax, [rbx+48h] mov rdi, rbx xor esi, esi xor edx, edx call qword ptr [rax+38h] jmp short loc_2B0FA loc_2B0EF: mov rdi, r14 call ma_tls_set_error mov r14b, 1 loc_2B0FA: mov eax, r14d add rsp, 8 pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
long long ma_tls_connect(long long a1) { long long v1; // r12 _QWORD *v2; // r14 long long v3; // rbx char v4; // r15 unsigned int socket; // eax int v6; // eax int error; // eax long long verify_result; // rax char *v9; // r12 char *v10; // r13 long long v11; // rax v1 = *(_QWORD *)(a1 + 16); v2 = (_QWORD *)SSL_get_ex_data(v1, 0LL); v3 = *v2; v4 = (*(long long ( **)(_QWORD))(*(_QWORD *)(*v2 + 72LL) + 104LL))(*v2); if ( !v4 ) (*(void ( **)(long long, _QWORD, _QWORD))(*(_QWORD *)(v3 + 72) + 56LL))(v3, 0LL, 0LL); SSL_clear(v1); socket = mysql_get_socket(v2); SSL_set_fd(v1, socket); while ( 1 ) { v6 = SSL_connect(v1); if ( v6 != -1 ) break; error = SSL_get_error(v1, 0xFFFFFFFFLL); if ( error != 3 && error != 2 || (*(int ( **)(long long, long long, _QWORD))(*(_QWORD *)(v3 + 72) + 48LL))( v3, 1LL, *((unsigned int *)v2 + 228)) <= 0 ) { goto LABEL_15; } } if ( v6 == 1 ) { if ( (*((_BYTE *)v2 + 875) & 0x40) == 0 && !v2[130] && !v2[131] || (verify_result = SSL_get_verify_result(v1)) == 0 ) { *(_QWORD *)(a1 + 16) = v1; *(_QWORD *)(*(_QWORD *)(v3 + 56) + 16LL) = v1; LODWORD(v2) = 0; return (unsigned int)v2; } goto LABEL_16; } LABEL_15: verify_result = SSL_get_verify_result(v1); if ( !verify_result ) { ma_tls_set_error(v2); LOBYTE(v2) = 1; return (unsigned int)v2; } LABEL_16: v9 = SQLSTATE_UNKNOWN; v10 = client_errors[26]; v11 = X509_verify_cert_error_string(verify_result); my_set_error((long long)v2, 2026, (long long)v9, v10, v11); LOBYTE(v2) = 1; if ( !v4 ) (*(void ( **)(long long, _QWORD, _QWORD))(*(_QWORD *)(v3 + 72) + 56LL))(v3, 0LL, 0LL); return (unsigned int)v2; }
ma_tls_connect: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX PUSH RAX MOV qword ptr [RBP + -0x30],RDI MOV R12,qword ptr [RDI + 0x10] MOV RDI,R12 XOR ESI,ESI CALL 0x00113160 MOV R14,RAX MOV RBX,qword ptr [RAX] MOV RAX,qword ptr [RBX + 0x48] MOV RDI,RBX CALL qword ptr [RAX + 0x68] MOV R15D,EAX TEST AL,AL JNZ 0x0012afea MOV RAX,qword ptr [RBX + 0x48] MOV RDI,RBX XOR ESI,ESI XOR EDX,EDX CALL qword ptr [RAX + 0x38] LAB_0012afea: MOV RDI,R12 CALL 0x001130b0 MOV RDI,R14 CALL 0x0011f50f MOV RDI,R12 MOV ESI,EAX CALL 0x001132b0 LAB_0012b004: MOV RDI,R12 CALL 0x00113670 CMP EAX,-0x1 JNZ 0x0012b044 MOV RDI,R12 MOV ESI,0xffffffff CALL 0x00113050 CMP EAX,0x3 JZ 0x0012b028 CMP EAX,0x2 JNZ 0x0012b092 LAB_0012b028: MOV RAX,qword ptr [RBX + 0x48] MOV EDX,dword ptr [R14 + 0x390] MOV RDI,RBX MOV ESI,0x1 CALL qword ptr [RAX + 0x30] TEST EAX,EAX JG 0x0012b004 JMP 0x0012b092 LAB_0012b044: MOV R13D,EAX CMP EAX,0x1 JNZ 0x0012b092 TEST byte ptr [R14 + 0x36b],0x40 JNZ 0x0012b06a CMP qword ptr [R14 + 0x410],0x0 JNZ 0x0012b06a CMP qword ptr [R14 + 0x418],0x0 JZ 0x0012b07d LAB_0012b06a: MOV RDI,R12 CALL 0x00113190 TEST RAX,RAX JNZ 0x0012b09f CMP R13D,0x1 JNZ 0x0012b0ef LAB_0012b07d: MOV RAX,qword ptr [RBP + -0x30] MOV qword ptr [RAX + 0x10],R12 MOV RAX,qword ptr [RBX + 0x38] MOV qword ptr [RAX + 0x10],R12 XOR R14D,R14D JMP 0x0012b0fa LAB_0012b092: MOV RDI,R12 CALL 0x00113190 TEST RAX,RAX JZ 0x0012b0ef LAB_0012b09f: LEA RCX,[0x14dd80] MOV R12,qword ptr [RCX] LEA RCX,[0x14dd90] MOV R13,qword ptr [RCX + 0xd0] MOV RDI,RAX CALL 0x001132f0 MOV RDI,R14 MOV ESI,0x7ea MOV RDX,R12 MOV RCX,R13 MOV R8,RAX XOR EAX,EAX CALL 0x001184d1 MOV R14B,0x1 TEST R15B,R15B JNZ 0x0012b0fa MOV RAX,qword ptr [RBX + 0x48] MOV RDI,RBX XOR ESI,ESI XOR EDX,EDX CALL qword ptr [RAX + 0x38] JMP 0x0012b0fa LAB_0012b0ef: MOV RDI,R14 CALL 0x0012b10c MOV R14B,0x1 LAB_0012b0fa: MOV EAX,R14D ADD RSP,0x8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
ulong ma_tls_connect(long param_1) { SSL *ssl; long lVar1; int *puVar2; int *puVar3; char cVar4; int iVar5; long *plVar6; long n; char *pcVar7; int7 uVar9; ulong uVar8; ssl = *(SSL **)(param_1 + 0x10); plVar6 = (long *)SSL_get_ex_data(ssl,0); lVar1 = *plVar6; cVar4 = (**(code **)(*(long *)(lVar1 + 0x48) + 0x68))(lVar1); if (cVar4 == '\0') { (**(code **)(*(long *)(lVar1 + 0x48) + 0x38))(lVar1,0,0); } SSL_clear(ssl); iVar5 = mysql_get_socket(plVar6); SSL_set_fd(ssl,iVar5); while( true ) { iVar5 = SSL_connect(ssl); uVar9 = (int7)((ulong)plVar6 >> 8); if (iVar5 != -1) break; iVar5 = SSL_get_error(ssl,-1); if (((iVar5 != 3) && (iVar5 != 2)) || (iVar5 = (**(code **)(*(long *)(lVar1 + 0x48) + 0x30))(lVar1,1,(int)plVar6[0x72]), iVar5 < 1) ) goto LAB_0012b092; } if (iVar5 == 1) { if (((((*(byte *)((long)plVar6 + 0x36b) & 0x40) != 0) || (plVar6[0x82] != 0)) || (plVar6[0x83] != 0)) && (n = SSL_get_verify_result(ssl), n != 0)) goto LAB_0012b09f; *(SSL **)(param_1 + 0x10) = ssl; *(SSL **)(*(long *)(lVar1 + 0x38) + 0x10) = ssl; uVar8 = 0; goto LAB_0012b0fa; } LAB_0012b092: n = SSL_get_verify_result(ssl); if (n == 0) { ma_tls_set_error(plVar6); uVar8 = CONCAT71(uVar9,1); } else { LAB_0012b09f: puVar3 = PTR_s_TLS_SSL_error_____100s_0014de60; puVar2 = SQLSTATE_UNKNOWN; pcVar7 = X509_verify_cert_error_string(n); my_set_error(plVar6,0x7ea,puVar2,puVar3,pcVar7); uVar8 = CONCAT71(uVar9,1); if (cVar4 == '\0') { (**(code **)(*(long *)(lVar1 + 0x48) + 0x38))(lVar1,0,0); } } LAB_0012b0fa: return uVar8 & 0xffffffff; }
31,892
nglog::tools::SymbolizeAndDemangle(void*, char*, unsigned long, nglog::tools::SymbolizeOptions)
ng-log[P]ng-log/src/symbolize.cc
static ATTRIBUTE_NOINLINE bool SymbolizeAndDemangle( void* pc, char* out, size_t out_size, SymbolizeOptions /*options*/) { auto pc0 = reinterpret_cast<uintptr_t>(pc); uint64_t start_address = 0; uint64_t base_address = 0; FileDescriptor object_fd; if (out_size < 1) { return false; } out[0] = '\0'; SafeAppendString("(", out, out_size); if (g_symbolize_open_object_file_callback) { object_fd.reset(g_symbolize_open_object_file_callback( pc0, start_address, base_address, out + 1, out_size - 1)); } else { object_fd = OpenObjectFileContainingPcAndGetStartAddress( pc0, start_address, base_address, out + 1, out_size - 1); } # if defined(PRINT_UNSYMBOLIZED_STACK_TRACES) { # else // Check whether a file name was returned. if (!object_fd) { # endif if (out[1]) { // The object file containing PC was determined successfully however the // object file was not opened successfully. This is still considered // success because the object file name and offset are known and tools // like asan_symbolize.py can be used for the symbolization. out[out_size - 1] = '\0'; // Making sure |out| is always null-terminated. SafeAppendString("+0x", out, out_size); SafeAppendHexNumber(pc0 - base_address, out, out_size); SafeAppendString(")", out, out_size); return true; } // Failed to determine the object file containing PC. Bail out. return false; } int elf_type = FileGetElfType(object_fd.get()); if (elf_type == -1) { return false; } if (g_symbolize_callback) { // Run the call back if it's installed. // Note: relocation (and much of the rest of this code) will be // wrong for prelinked shared libraries and PIE executables. uint64_t relocation = (elf_type == ET_DYN) ? start_address : 0; int num_bytes_written = g_symbolize_callback(object_fd.get(), pc, out, out_size, relocation); if (num_bytes_written > 0) { out += static_cast<size_t>(num_bytes_written); out_size -= static_cast<size_t>(num_bytes_written); } } if (!GetSymbolFromObjectFile(object_fd.get(), pc0, out, out_size, base_address)) { if (out[1] && !g_symbolize_callback) { // The object file containing PC was opened successfully however the // symbol was not found. The object may have been stripped. This is still // considered success because the object file name and offset are known // and tools like asan_symbolize.py can be used for the symbolization. out[out_size - 1] = '\0'; // Making sure |out| is always null-terminated. SafeAppendString("+0x", out, out_size); SafeAppendHexNumber(pc0 - base_address, out, out_size); SafeAppendString(")", out, out_size); return true; } return false; } // Symbolization succeeded. Now we try to demangle the symbol. DemangleInplace(out, out_size); return true; } }
O1
cpp
nglog::tools::SymbolizeAndDemangle(void*, char*, unsigned long, nglog::tools::SymbolizeOptions): pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0xe8, %rsp xorl %r13d, %r13d movq %r13, 0x18(%rsp) movq %r13, 0x10(%rsp) testq %rdx, %rdx je 0x2171e movq %rdx, %r14 movq %rsi, %r15 movq %rdi, %r12 movb $0x0, (%rsi) leaq 0x241b(%rip), %rdi # 0x23b0d callq 0x2199e movq 0x2040a(%rip), %rax # 0x41b08 testq %rax, %rax je 0x21728 leaq 0x1(%r15), %rcx leaq -0x1(%r14), %r8 leaq 0x18(%rsp), %rsi leaq 0x10(%rsp), %rdx movq %r12, %rdi callq *%rax movl %eax, %ebx jmp 0x2174b movl $0xffffffff, %ebx # imm = 0xFFFFFFFF jmp 0x2194e leaq 0x1(%r15), %r8 leaq -0x1(%r14), %r9 leaq 0x28(%rsp), %rdi leaq 0x18(%rsp), %rdx leaq 0x10(%rsp), %rcx movq %r12, %rsi callq 0x219db movl 0x28(%rsp), %ebx cmpl $-0x1, %ebx je 0x218e6 leaq 0x28(%rsp), %rsi movl $0x40, %edx movl %ebx, %edi xorl %ecx, %ecx callq 0x21604 cmpq $0x40, %rax sete %al cmpl $0x464c457f, 0x28(%rsp) # imm = 0x464C457F sete %cl andb %al, %cl je 0x218f5 movq 0x20378(%rip), %rax # 0x41b00 testq %rax, %rax je 0x217c5 xorl %r8d, %r8d cmpw $0x3, 0x38(%rsp) movl $0x0, %edx jne 0x217a2 movq 0x18(%rsp), %rdx testb %cl, %cl cmovneq %rdx, %r8 movl %ebx, %edi movq %r12, %rsi movq %r15, %rdx movq %r14, %rcx callq *%rax xorl %ecx, %ecx testl %eax, %eax movl %eax, %eax cmovgq %rax, %rcx subq %rcx, %r14 addq %rcx, %r15 movq 0x10(%rsp), %rax movq %rax, 0x20(%rsp) leaq 0x28(%rsp), %rsi movl $0x40, %edx movl %ebx, %edi xorl %ecx, %ecx callq 0x21604 cmpq $0x40, %rax jne 0x218fa movq 0x50(%rsp), %rbp movzwl 0x64(%rsp), %r13d leaq 0x68(%rsp), %r8 movl %ebx, %edi movl %r13d, %esi movq %rbp, %rdx movl $0x2, %ecx callq 0x21fe0 testb %al, %al je 0x21868 movl 0x90(%rsp), %ecx shlq $0x6, %rcx addq %rbp, %rcx leaq 0xa8(%rsp), %rsi movl $0x40, %edx movl %ebx, %edi callq 0x21604 cmpq $0x40, %rax jne 0x218fa leaq 0x68(%rsp), %rax movq %rax, (%rsp) leaq 0xa8(%rsp), %r9 movq %r12, %rdi movl %ebx, %esi movq %r15, %rdx movq %r14, %rcx movq 0x20(%rsp), %r8 callq 0x220ff testb %al, %al jne 0x218d6 leaq 0x68(%rsp), %rax movl %ebx, %edi movl %r13d, %esi movq %rax, %r13 movq %rbp, %rdx movl $0xb, %ecx movq %rax, %r8 callq 0x21fe0 testb %al, %al je 0x218fa movl 0x90(%rsp), %ecx shlq $0x6, %rcx addq %rbp, %rcx leaq 0xa8(%rsp), %rsi movl $0x40, %edx movl %ebx, %edi callq 0x21604 cmpq $0x40, %rax jne 0x218fa movq %r13, (%rsp) leaq 0xa8(%rsp), %r9 movq %r12, %rdi movl %ebx, %esi movq %r15, %rdx movq %r14, %rcx movq 0x20(%rsp), %r8 callq 0x220ff testb %al, %al je 0x218fa movb $0x1, %r13b movq %r15, %rdi movq %r14, %rsi callq 0x21eea jmp 0x2194e cmpb $0x0, 0x1(%r15) je 0x218f5 movb $0x0, -0x1(%r15,%r14) jmp 0x21914 xorl %r13d, %r13d jmp 0x2194e xorl %r13d, %r13d cmpb $0x0, 0x1(%r15) je 0x2194e cmpq $0x0, 0x201f4(%rip) # 0x41b00 jne 0x2194e movb $0x0, -0x1(%r14,%r15) leaq 0x37f7(%rip), %rdi # 0x25112 movq %r15, %rsi movq %r14, %rdx callq 0x2199e subq 0x10(%rsp), %r12 movq %r12, %rdi movq %r15, %rsi movq %r14, %rdx callq 0x21e63 leaq 0x2495(%rip), %rdi # 0x23dd5 movq %r15, %rsi movq %r14, %rdx callq 0x2199e movb $0x1, %r13b cmpl $-0x1, %ebx je 0x2195a movl %ebx, %edi callq 0x7a60 movl %r13d, %eax addq $0xe8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq jmp 0x2197f jmp 0x21973 movq %rax, %r14 movl $0xffffffff, %ebx # imm = 0xFFFFFFFF jmp 0x21982 jmp 0x21996 movq %rax, %r14 cmpl $-0x1, %ebx je 0x2198e movl %ebx, %edi callq 0x7a60 movq %r14, %rdi callq 0x79b0 movq %rax, %rdi callq 0x98c3
_ZN5nglog5toolsL20SymbolizeAndDemangleEPvPcmNS0_16SymbolizeOptionsE: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 0E8h xor r13d, r13d mov [rsp+118h+var_100], r13 mov [rsp+118h+var_108], r13 test rdx, rdx jz short loc_2171E mov r14, rdx mov r15, rsi mov r12, rdi mov byte ptr [rsi], 0 lea rdi, asc_23B0C+1; this call _ZN5nglog5toolsL16SafeAppendStringEPKcPcm; nglog::tools::SafeAppendString(char const*,char *,ulong) mov rax, cs:_ZN5nglog5tools12_GLOBAL__N_137g_symbolize_open_object_file_callbackE; nglog::tools::`anonymous namespace'::g_symbolize_open_object_file_callback test rax, rax jz short loc_21728 lea rcx, [r15+1] lea r8, [r14-1] lea rsi, [rsp+118h+var_100] lea rdx, [rsp+118h+var_108] mov rdi, r12 call rax ; nglog::tools::`anonymous namespace'::g_symbolize_open_object_file_callback mov ebx, eax jmp short loc_2174B loc_2171E: mov ebx, 0FFFFFFFFh jmp loc_2194E loc_21728: lea r8, [r15+1]; char * lea r9, [r14-1]; unsigned __int64 lea rdi, [rsp+118h+var_F0]; this lea rdx, [rsp+118h+var_100]; unsigned __int64 * lea rcx, [rsp+118h+var_108]; unsigned __int64 * mov rsi, r12; unsigned __int64 call _ZN5nglog5toolsL44OpenObjectFileContainingPcAndGetStartAddressEmRmS1_Pcm; nglog::tools::OpenObjectFileContainingPcAndGetStartAddress(ulong,ulong &,ulong &,char *,ulong) mov ebx, [rsp+118h+var_F0] loc_2174B: cmp ebx, 0FFFFFFFFh jz loc_218E6 lea rsi, [rsp+118h+var_F0]; int mov edx, offset dword_40; void * mov edi, ebx; this xor ecx, ecx; unsigned __int64 call _ZN5nglog5toolsL14ReadFromOffsetEiPvmm; nglog::tools::ReadFromOffset(int,void *,ulong,ulong) cmp rax, 40h ; '@' setz al cmp [rsp+118h+var_F0], 464C457Fh setz cl and cl, al jz loc_218F5 mov rax, cs:_ZN5nglog5tools12_GLOBAL__N_120g_symbolize_callbackE; nglog::tools::`anonymous namespace'::g_symbolize_callback test rax, rax jz short loc_217C5 xor r8d, r8d cmp [rsp+118h+var_E0], 3 mov edx, 0 jnz short loc_217A2 mov rdx, [rsp+118h+var_100] loc_217A2: test cl, cl cmovnz r8, rdx mov edi, ebx mov rsi, r12 mov rdx, r15 mov rcx, r14 call rax ; nglog::tools::`anonymous namespace'::g_symbolize_callback xor ecx, ecx test eax, eax mov eax, eax cmovg rcx, rax sub r14, rcx add r15, rcx loc_217C5: mov rax, [rsp+118h+var_108] mov [rsp+118h+var_F8], rax lea rsi, [rsp+118h+var_F0]; int mov edx, offset dword_40; void * mov edi, ebx; this xor ecx, ecx; unsigned __int64 call _ZN5nglog5toolsL14ReadFromOffsetEiPvmm; nglog::tools::ReadFromOffset(int,void *,ulong,ulong) cmp rax, 40h ; '@' jnz loc_218FA mov rbp, [rsp+118h+var_C8] movzx r13d, [rsp+118h+var_B4] lea r8, [rsp+118h+var_B0] mov edi, ebx; this mov esi, r13d mov rdx, rbp mov ecx, 2 call _ZN5nglog5toolsL22GetSectionHeaderByTypeEitmjP10Elf64_Shdr; nglog::tools::GetSectionHeaderByType(int,ushort,ulong,uint,Elf64_Shdr *) test al, al jz short loc_21868 mov ecx, [rsp+118h+var_88] shl rcx, 6 add rcx, rbp; unsigned __int64 lea rsi, [rsp+118h+var_70]; int mov edx, offset dword_40; void * mov edi, ebx; this call _ZN5nglog5toolsL14ReadFromOffsetEiPvmm; nglog::tools::ReadFromOffset(int,void *,ulong,ulong) cmp rax, 40h ; '@' jnz loc_218FA lea rax, [rsp+118h+var_B0] mov [rsp+118h+var_118], rax lea r9, [rsp+118h+var_70] mov rdi, r12 mov esi, ebx mov rdx, r15 mov rcx, r14 mov r8, [rsp+118h+var_F8] call _ZN5nglog5toolsL10FindSymbolEmiPcmmPK10Elf64_ShdrS4_; nglog::tools::FindSymbol(ulong,int,char *,ulong,ulong,Elf64_Shdr const*,Elf64_Shdr const*) test al, al jnz short loc_218D6 loc_21868: lea rax, [rsp+118h+var_B0] mov edi, ebx; this mov esi, r13d mov r13, rax mov rdx, rbp mov ecx, 0Bh mov r8, rax call _ZN5nglog5toolsL22GetSectionHeaderByTypeEitmjP10Elf64_Shdr; nglog::tools::GetSectionHeaderByType(int,ushort,ulong,uint,Elf64_Shdr *) test al, al jz short loc_218FA mov ecx, [rsp+118h+var_88] shl rcx, 6 add rcx, rbp; unsigned __int64 lea rsi, [rsp+118h+var_70]; int mov edx, offset dword_40; void * mov edi, ebx; this call _ZN5nglog5toolsL14ReadFromOffsetEiPvmm; nglog::tools::ReadFromOffset(int,void *,ulong,ulong) cmp rax, 40h ; '@' jnz short loc_218FA mov [rsp+118h+var_118], r13 lea r9, [rsp+118h+var_70] mov rdi, r12 mov esi, ebx mov rdx, r15 mov rcx, r14 mov r8, [rsp+118h+var_F8] call _ZN5nglog5toolsL10FindSymbolEmiPcmmPK10Elf64_ShdrS4_; nglog::tools::FindSymbol(ulong,int,char *,ulong,ulong,Elf64_Shdr const*,Elf64_Shdr const*) test al, al jz short loc_218FA loc_218D6: mov r13b, 1 mov rdi, r15; this mov rsi, r14; char * call _ZN5nglog5tools12_GLOBAL__N_115DemangleInplaceEPcm; nglog::tools::`anonymous namespace'::DemangleInplace(char *,ulong) jmp short loc_2194E loc_218E6: cmp byte ptr [r15+1], 0 jz short loc_218F5 mov byte ptr [r15+r14-1], 0 jmp short loc_21914 loc_218F5: xor r13d, r13d jmp short loc_2194E loc_218FA: xor r13d, r13d cmp byte ptr [r15+1], 0 jz short loc_2194E cmp cs:_ZN5nglog5tools12_GLOBAL__N_120g_symbolize_callbackE, 0; nglog::tools::`anonymous namespace'::g_symbolize_callback jnz short loc_2194E mov byte ptr [r14+r15-1], 0 loc_21914: lea rdi, a0x_0; "+0x" mov rsi, r15; char * mov rdx, r14; char * call _ZN5nglog5toolsL16SafeAppendStringEPKcPcm; nglog::tools::SafeAppendString(char const*,char *,ulong) sub r12, [rsp+118h+var_108] mov rdi, r12; this mov rsi, r15; unsigned __int64 mov rdx, r14; char * call _ZN5nglog5toolsL19SafeAppendHexNumberEmPcm; nglog::tools::SafeAppendHexNumber(ulong,char *,ulong) lea rdi, aVoidNglogAnony+86h; this mov rsi, r15; char * mov rdx, r14; char * call _ZN5nglog5toolsL16SafeAppendStringEPKcPcm; nglog::tools::SafeAppendString(char const*,char *,ulong) mov r13b, 1 loc_2194E: cmp ebx, 0FFFFFFFFh jz short loc_2195A mov edi, ebx call _close loc_2195A: mov eax, r13d add rsp, 0E8h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn jmp short loc_2197F jmp short $+2 loc_21973: mov r14, rax mov ebx, 0FFFFFFFFh jmp short loc_21982 jmp short loc_21996 loc_2197F: mov r14, rax loc_21982: cmp ebx, 0FFFFFFFFh jz short loc_2198E mov edi, ebx call _close loc_2198E: mov rdi, r14 call __Unwind_Resume loc_21996: mov rdi, rax call __clang_call_terminate
long long nglog::tools::SymbolizeAndDemangle( unsigned long long a1, nglog::tools::_anonymous_namespace_ *this, char *a3, unsigned long long a4) { _BYTE *v4; // r13 char *v5; // r14 nglog::tools::_anonymous_namespace_ *v6; // r15 unsigned long long v7; // rcx unsigned int v8; // ebx unsigned long long v9; // rax unsigned long long v10; // rdx int v11; // eax long long v12; // rcx long long v13; // rbp unsigned long long v14; // rdx unsigned long long v15; // rcx unsigned long long v16; // rcx unsigned long long v18; // [rsp+10h] [rbp-108h] BYREF unsigned long long v19; // [rsp+18h] [rbp-100h] BYREF unsigned long long v20; // [rsp+20h] [rbp-F8h] int v21[4]; // [rsp+28h] [rbp-F0h] BYREF __int16 v22; // [rsp+38h] [rbp-E0h] long long v23; // [rsp+50h] [rbp-C8h] unsigned __int16 v24; // [rsp+64h] [rbp-B4h] _BYTE v25[40]; // [rsp+68h] [rbp-B0h] BYREF unsigned int v26; // [rsp+90h] [rbp-88h] int v27[28]; // [rsp+A8h] [rbp-70h] BYREF LODWORD(v4) = 0; v19 = 0LL; v18 = 0LL; if ( !a3 ) { v8 = -1; goto LABEL_29; } v5 = a3; v6 = this; *(_BYTE *)this = 0; nglog::tools::SafeAppendString((nglog::tools *)"(", (const char *)this, a3, a4); if ( nglog::tools::`anonymous namespace'::g_symbolize_open_object_file_callback ) { v8 = nglog::tools::`anonymous namespace'::g_symbolize_open_object_file_callback( a1, &v19, &v18, (char *)this + 1, v5 - 1); } else { nglog::tools::OpenObjectFileContainingPcAndGetStartAddress( (nglog::tools *)v21, a1, &v19, &v18, (char *)this + 1, (unsigned long long)(v5 - 1)); v8 = v21[0]; } if ( v8 == -1 ) { if ( *((_BYTE *)this + 1) ) { v5[(_QWORD)this - 1] = 0; LABEL_28: nglog::tools::SafeAppendString((nglog::tools *)"+0x", (const char *)v6, v5, v7); nglog::tools::SafeAppendHexNumber((nglog::tools *)(a1 - v18), (unsigned long long)v6, v5, v15); nglog::tools::SafeAppendString((nglog::tools *)")", (const char *)v6, v5, v16); LOBYTE(v4) = 1; goto LABEL_29; } LABEL_24: LODWORD(v4) = 0; goto LABEL_29; } v9 = nglog::tools::ReadFromOffset(v8, (long long)v21, (char *)&dword_40, 0LL); if ( v9 != 64 || v21[0] != 1179403647 ) goto LABEL_24; if ( nglog::tools::`anonymous namespace'::g_symbolize_callback ) { v10 = 0LL; if ( v22 == 3 ) v10 = v19; v11 = nglog::tools::`anonymous namespace'::g_symbolize_callback(v8, a1, this, v5, v10); v12 = 0LL; if ( v11 > 0 ) v12 = (unsigned int)v11; v5 -= v12; v6 = (nglog::tools::_anonymous_namespace_ *)((char *)this + v12); } v20 = v18; if ( nglog::tools::ReadFromOffset(v8, (long long)v21, (char *)&dword_40, 0LL) == 64 ) { v13 = v23; LODWORD(v4) = v24; if ( (unsigned __int8)nglog::tools::GetSectionHeaderByType((nglog::tools *)v8) ) { if ( nglog::tools::ReadFromOffset(v8, (long long)v27, (char *)&dword_40, v13 + ((unsigned long long)v26 << 6)) != 64 ) goto LABEL_25; if ( (unsigned __int8)nglog::tools::FindSymbol(a1, v8, v6, v5, v20, v27, v25) ) { LABEL_21: LOBYTE(v4) = 1; nglog::tools::`anonymous namespace'::DemangleInplace(v6, v5, v14); goto LABEL_29; } } v4 = v25; if ( (unsigned __int8)nglog::tools::GetSectionHeaderByType((nglog::tools *)v8) && nglog::tools::ReadFromOffset(v8, (long long)v27, (char *)&dword_40, v13 + ((unsigned long long)v26 << 6)) == 64 && (unsigned __int8)nglog::tools::FindSymbol(a1, v8, v6, v5, v20, v27, v25) ) { goto LABEL_21; } } LABEL_25: LODWORD(v4) = 0; if ( *((_BYTE *)v6 + 1) && !nglog::tools::`anonymous namespace'::g_symbolize_callback ) { *((_BYTE *)v6 + (_QWORD)v5 - 1) = 0; goto LABEL_28; } LABEL_29: if ( v8 != -1 ) close(v8); return (unsigned int)v4; }
SymbolizeAndDemangle: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0xe8 XOR R13D,R13D MOV qword ptr [RSP + 0x18],R13 MOV qword ptr [RSP + 0x10],R13 TEST RDX,RDX JZ 0x0012171e MOV R14,RDX MOV R15,RSI MOV R12,RDI MOV byte ptr [RSI],0x0 LEA RDI,[0x123b0d] CALL 0x0012199e MOV RAX,qword ptr [0x00141b08] TEST RAX,RAX JZ 0x00121728 LEA RCX,[R15 + 0x1] LEA R8,[R14 + -0x1] LAB_0012170b: LEA RSI,[RSP + 0x18] LEA RDX,[RSP + 0x10] MOV RDI,R12 CALL RAX MOV EBX,EAX JMP 0x0012174b LAB_0012171e: MOV EBX,0xffffffff JMP 0x0012194e LAB_00121728: LEA R8,[R15 + 0x1] LEA R9,[R14 + -0x1] LAB_00121730: LEA RDI,[RSP + 0x28] LEA RDX,[RSP + 0x18] LEA RCX,[RSP + 0x10] MOV RSI,R12 CALL 0x001219db MOV EBX,dword ptr [RSP + 0x28] LAB_0012174b: CMP EBX,-0x1 JZ 0x001218e6 LAB_00121754: LEA RSI,[RSP + 0x28] MOV EDX,0x40 MOV EDI,EBX XOR ECX,ECX CALL 0x00121604 CMP RAX,0x40 SETZ AL CMP dword ptr [RSP + 0x28],0x464c457f SETZ CL AND CL,AL JZ 0x001218f5 MOV RAX,qword ptr [0x00141b00] TEST RAX,RAX JZ 0x001217c5 XOR R8D,R8D CMP word ptr [RSP + 0x38],0x3 MOV EDX,0x0 JNZ 0x001217a2 MOV RDX,qword ptr [RSP + 0x18] LAB_001217a2: TEST CL,CL CMOVNZ R8,RDX LAB_001217a8: MOV EDI,EBX MOV RSI,R12 MOV RDX,R15 MOV RCX,R14 CALL RAX XOR ECX,ECX TEST EAX,EAX MOV EAX,EAX CMOVG RCX,RAX SUB R14,RCX ADD R15,RCX LAB_001217c5: MOV RAX,qword ptr [RSP + 0x10] MOV qword ptr [RSP + 0x20],RAX LAB_001217cf: LEA RSI,[RSP + 0x28] MOV EDX,0x40 MOV EDI,EBX XOR ECX,ECX CALL 0x00121604 CMP RAX,0x40 JNZ 0x001218fa MOV RBP,qword ptr [RSP + 0x50] MOVZX R13D,word ptr [RSP + 0x64] LEA R8,[RSP + 0x68] MOV EDI,EBX MOV ESI,R13D MOV RDX,RBP MOV ECX,0x2 CALL 0x00121fe0 TEST AL,AL JZ 0x00121868 MOV ECX,dword ptr [RSP + 0x90] SHL RCX,0x6 ADD RCX,RBP LEA RSI,[RSP + 0xa8] MOV EDX,0x40 MOV EDI,EBX CALL 0x00121604 CMP RAX,0x40 JNZ 0x001218fa LEA RAX,[RSP + 0x68] MOV qword ptr [RSP],RAX LEA R9,[RSP + 0xa8] MOV RDI,R12 MOV ESI,EBX MOV RDX,R15 MOV RCX,R14 MOV R8,qword ptr [RSP + 0x20] CALL 0x001220ff TEST AL,AL JNZ 0x001218d6 LAB_00121868: LEA RAX,[RSP + 0x68] MOV EDI,EBX MOV ESI,R13D MOV R13,RAX MOV RDX,RBP MOV ECX,0xb MOV R8,RAX CALL 0x00121fe0 TEST AL,AL JZ 0x001218fa MOV ECX,dword ptr [RSP + 0x90] SHL RCX,0x6 ADD RCX,RBP LEA RSI,[RSP + 0xa8] MOV EDX,0x40 MOV EDI,EBX CALL 0x00121604 CMP RAX,0x40 JNZ 0x001218fa MOV qword ptr [RSP],R13 LEA R9,[RSP + 0xa8] MOV RDI,R12 MOV ESI,EBX MOV RDX,R15 MOV RCX,R14 MOV R8,qword ptr [RSP + 0x20] CALL 0x001220ff TEST AL,AL JZ 0x001218fa LAB_001218d6: MOV R13B,0x1 MOV RDI,R15 MOV RSI,R14 CALL 0x00121eea JMP 0x0012194e LAB_001218e6: CMP byte ptr [R15 + 0x1],0x0 JZ 0x001218f5 MOV byte ptr [R15 + R14*0x1 + -0x1],0x0 JMP 0x00121914 LAB_001218f5: XOR R13D,R13D JMP 0x0012194e LAB_001218fa: XOR R13D,R13D CMP byte ptr [R15 + 0x1],0x0 JZ 0x0012194e CMP qword ptr [0x00141b00],0x0 JNZ 0x0012194e MOV byte ptr [R14 + R15*0x1 + -0x1],0x0 LAB_00121914: LEA RDI,[0x125112] MOV RSI,R15 MOV RDX,R14 CALL 0x0012199e SUB R12,qword ptr [RSP + 0x10] MOV RDI,R12 MOV RSI,R15 MOV RDX,R14 CALL 0x00121e63 LEA RDI,[0x123dd5] MOV RSI,R15 MOV RDX,R14 CALL 0x0012199e MOV R13B,0x1 LAB_0012194e: CMP EBX,-0x1 JZ 0x0012195a LAB_00121953: MOV EDI,EBX CALL 0x00107a60 LAB_0012195a: MOV EAX,R13D ADD RSP,0xe8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
/* nglog::tools::SymbolizeAndDemangle(void*, char*, unsigned long, nglog::tools::SymbolizeOptions) */ ulong nglog::tools::SymbolizeAndDemangle(ulong param_1,char *param_2,ulong param_3) { char cVar1; int __fd; uint uVar2; long lVar3; ulong uVar4; ulong uVar5; Elf64_Shdr *pEVar6; ulong local_108; ulong local_100; ulong local_f8; int local_f0 [4]; short local_e0; ulong local_c8; ushort local_b4; Elf64_Shdr local_b0; Elf64_Shdr local_70; uVar5 = 0; local_100 = 0; local_108 = 0; if (param_3 == 0) { __fd = -1; goto LAB_0012194e; } *param_2 = '\0'; SafeAppendString("(",param_2,param_3); if ((anonymous_namespace)::g_symbolize_open_object_file_callback == (code *)0x0) { /* try { // try from 00121730 to 00121746 has its CatchHandler @ 00121971 */ OpenObjectFileContainingPcAndGetStartAddress ((tools *)local_f0,param_1,&local_100,&local_108,param_2 + 1,param_3 - 1); __fd = local_f0[0]; } else { /* try { // try from 0012170b to 00121719 has its CatchHandler @ 00121973 */ __fd = (*(anonymous_namespace)::g_symbolize_open_object_file_callback) (param_1,&local_100,&local_108,param_2 + 1,param_3 - 1); } if (__fd == -1) { if (param_2[1] == '\0') goto LAB_001218f5; param_2[param_3 - 1] = '\0'; } else { /* try { // try from 00121754 to 00121766 has its CatchHandler @ 0012197f */ lVar3 = ReadFromOffset(__fd,local_f0,0x40,0); if (local_f0[0] != 0x464c457f || lVar3 != 0x40) { LAB_001218f5: uVar5 = 0; goto LAB_0012194e; } if ((anonymous_namespace)::g_symbolize_callback != (code *)0x0) { uVar5 = 0; if (local_e0 == 3) { uVar5 = local_100; } uVar4 = 0; if (local_f0[0] == 0x464c457f && lVar3 == 0x40) { uVar4 = uVar5; } /* try { // try from 001217a8 to 001217b4 has its CatchHandler @ 0012196f */ uVar2 = (*(anonymous_namespace)::g_symbolize_callback)(__fd,param_1,param_2,param_3,uVar4); uVar5 = 0; if (0 < (int)uVar2) { uVar5 = (ulong)uVar2; } param_3 = param_3 - uVar5; param_2 = param_2 + uVar5; } local_f8 = local_108; /* try { // try from 001217cf to 001218e3 has its CatchHandler @ 0012197f */ lVar3 = ReadFromOffset(__fd,local_f0,0x40,0); if (lVar3 == 0x40) { pEVar6 = (Elf64_Shdr *)(ulong)local_b4; cVar1 = GetSectionHeaderByType(__fd,local_b4,local_c8,2,&local_b0); if (cVar1 == '\0') { LAB_00121868: pEVar6 = &local_b0; cVar1 = GetSectionHeaderByType(__fd,local_b4,local_c8,0xb,pEVar6); if (cVar1 != '\0') { lVar3 = ReadFromOffset(__fd,&local_70,0x40,(ulong)local_b0.sh_link * 0x40 + local_c8); if (lVar3 == 0x40) { cVar1 = FindSymbol(param_1,__fd,param_2,param_3,local_f8,&local_70,pEVar6); if (cVar1 != '\0') goto LAB_001218d6; } } } else { lVar3 = ReadFromOffset(__fd,&local_70,0x40,(ulong)local_b0.sh_link * 0x40 + local_c8); if (lVar3 == 0x40) { cVar1 = FindSymbol(param_1,__fd,param_2,param_3,local_f8,&local_70,&local_b0); if (cVar1 == '\0') goto LAB_00121868; LAB_001218d6: uVar5 = CONCAT71((int7)((ulong)pEVar6 >> 8),1); (anonymous_namespace)::DemangleInplace(param_2,param_3); goto LAB_0012194e; } } } uVar5 = 0; if ((param_2[1] == '\0') || ((anonymous_namespace)::g_symbolize_callback != (code *)0x0)) goto LAB_0012194e; param_2[param_3 - 1] = '\0'; } SafeAppendString("+0x",param_2,param_3); SafeAppendHexNumber(param_1 - local_108,param_2,param_3); SafeAppendString(")",param_2,param_3); uVar5 = 1; LAB_0012194e: if (__fd != -1) { /* try { // try from 00121953 to 00121959 has its CatchHandler @ 0012197d */ close(__fd); } return uVar5 & 0xffffffff; }
31,893
my_numcells_eucjp
eloqsql/strings/ctype-ujis.c
static size_t my_numcells_eucjp(CHARSET_INFO *cs __attribute__((unused)), const char *str, const char *str_end) { size_t clen; const uchar *b= (const uchar *) str; const uchar *e= (const uchar *) str_end; for (clen= 0; b < e; ) { if (*b == 0x8E) { clen++; b+= 2; } else if (*b == 0x8F) { clen+= 2; b+= 3; } else if (*b & 0x80) { clen+= 2; b+= 2; } else { clen++; b++; } } return clen; }
O3
c
my_numcells_eucjp: cmpq %rdx, %rsi jae 0xc9a1e pushq %rbp movq %rsp, %rbp xorl %eax, %eax movzbl (%rsi), %edi cmpl $0x8e, %edi je 0xc99f7 cmpl $0x8f, %edi jne 0xc9a03 movl $0x3, %edi movl $0x2, %ecx jmp 0xc9a11 movl $0x2, %edi movl $0x1, %ecx jmp 0xc9a11 xorl %ecx, %ecx testb %dil, %dil sets %cl incq %rcx movq %rcx, %rdi addq %rcx, %rax addq %rdi, %rsi cmpq %rdx, %rsi jb 0xc99d8 popq %rbp retq xorl %eax, %eax retq
my_numcells_eucjp: cmp rsi, rdx jnb short loc_C9A1E push rbp mov rbp, rsp xor eax, eax loc_C99D8: movzx edi, byte ptr [rsi] cmp edi, 8Eh jz short loc_C99F7 cmp edi, 8Fh jnz short loc_C9A03 mov edi, 3 mov ecx, 2 jmp short loc_C9A11 loc_C99F7: mov edi, 2 mov ecx, 1 jmp short loc_C9A11 loc_C9A03: xor ecx, ecx test dil, dil sets cl inc rcx mov rdi, rcx loc_C9A11: add rax, rcx add rsi, rdi cmp rsi, rdx jb short loc_C99D8 pop rbp retn loc_C9A1E: xor eax, eax retn
long long my_numcells_eucjp(long long a1, unsigned __int8 *a2, unsigned long long a3) { long long result; // rax int v4; // edi long long v5; // rdi long long v6; // rcx if ( (unsigned long long)a2 >= a3 ) return 0LL; result = 0LL; do { v4 = *a2; if ( v4 == 142 ) { v5 = 2LL; v6 = 1LL; } else if ( v4 == 143 ) { v5 = 3LL; v6 = 2LL; } else { v6 = ((v4 & 0x80u) != 0) + 1LL; v5 = v6; } result += v6; a2 += v5; } while ( (unsigned long long)a2 < a3 ); return result; }
my_numcells_eucjp: CMP RSI,RDX JNC 0x001c9a1e PUSH RBP MOV RBP,RSP XOR EAX,EAX LAB_001c99d8: MOVZX EDI,byte ptr [RSI] CMP EDI,0x8e JZ 0x001c99f7 CMP EDI,0x8f JNZ 0x001c9a03 MOV EDI,0x3 MOV ECX,0x2 JMP 0x001c9a11 LAB_001c99f7: MOV EDI,0x2 MOV ECX,0x1 JMP 0x001c9a11 LAB_001c9a03: XOR ECX,ECX TEST DIL,DIL SETS CL INC RCX MOV RDI,RCX LAB_001c9a11: ADD RAX,RCX ADD RSI,RDI CMP RSI,RDX JC 0x001c99d8 POP RBP RET LAB_001c9a1e: XOR EAX,EAX RET
long my_numcells_eucjp(int8 param_1,char *param_2,char *param_3) { char cVar1; long lVar2; long lVar3; long lVar4; if (param_2 < param_3) { lVar2 = 0; do { cVar1 = *param_2; if (cVar1 == -0x72) { lVar4 = 2; lVar3 = 1; } else if (cVar1 == -0x71) { lVar3 = 2; lVar4 = 3; } else { lVar3 = (ulong)(cVar1 < '\0') + 1; lVar4 = lVar3; } lVar2 = lVar2 + lVar3; param_2 = param_2 + lVar4; } while (param_2 < param_3); return lVar2; } return 0; }
31,894
google::protobuf::EnumDescriptor::CopyTo(google::protobuf::EnumDescriptorProto*) const
aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/descriptor.cc
void EnumDescriptor::CopyTo(EnumDescriptorProto* proto) const { proto->set_name(name()); for (int i = 0; i < value_count(); i++) { value(i)->CopyTo(proto->add_value()); } for (int i = 0; i < reserved_range_count(); i++) { EnumDescriptorProto::EnumReservedRange* range = proto->add_reserved_range(); range->set_start(reserved_range(i)->start); range->set_end(reserved_range(i)->end); } for (int i = 0; i < reserved_name_count(); i++) { proto->add_reserved_name(reserved_name(i)); } if (&options() != &EnumOptions::default_instance()) { proto->mutable_options()->CopyFrom(options()); } }
O3
cpp
google::protobuf::EnumDescriptor::CopyTo(google::protobuf::EnumDescriptorProto*) const: pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx pushq %rax movq %rsi, %r14 movq %rdi, %rbx movq 0x8(%rdi), %rsi orl $0x1, 0x10(%r14) leaq 0x60(%r14), %rdi movq 0x8(%r14), %rax movq %rax, %rdx andq $-0x4, %rdx testb $0x1, %al jne 0xc284a callq 0x786ce cmpl $0x0, 0x4(%rbx) jle 0xc276d leaq 0x18(%r14), %r15 xorl %r13d, %r13d xorl %ebp, %ebp movq 0x28(%rbx), %r12 addq %r13, %r12 movq %r15, %rdi xorl %esi, %esi callq 0xe246a movq %r12, %rdi movq %rax, %rsi callq 0xc3186 incq %rbp movslq 0x4(%rbx), %rax addq $0x20, %r13 cmpq %rax, %rbp jl 0xc2741 cmpl $0x0, 0x30(%rbx) jle 0xc27b8 leaq 0x30(%r14), %r15 xorl %r12d, %r12d movq %r15, %rdi xorl %esi, %esi callq 0xe24a0 movq 0x38(%rbx), %rcx movl (%rcx,%r12,8), %ecx movl 0x10(%rax), %edx movl %edx, %esi orl $0x1, %esi movl %esi, 0x10(%rax) movl %ecx, 0x18(%rax) movq 0x38(%rbx), %rcx movl 0x4(%rcx,%r12,8), %ecx orl $0x3, %edx movl %edx, 0x10(%rax) movl %ecx, 0x1c(%rax) incq %r12 movslq 0x30(%rbx), %rax cmpq %rax, %r12 jl 0xc277a cmpl $0x0, 0x34(%rbx) jle 0xc27ee leaq 0x48(%r14), %r15 xorl %r13d, %r13d movq 0x40(%rbx), %rax movq (%rax,%r13,8), %r12 movq %r15, %rdi xorl %esi, %esi callq 0x5cf48 movq %rax, %rdi movq %r12, %rsi callq 0x2d240 incq %r13 movslq 0x34(%rbx), %rax cmpq %rax, %r13 jl 0xc27c5 movq 0x20(%rbx), %rsi cmpq 0x14d747(%rip), %rsi # 0x20ff40 je 0xc283b orb $0x2, 0x10(%r14) movq 0x68(%r14), %rdi testq %rdi, %rdi jne 0xc2828 movq 0x8(%r14), %rax movq %rax, %rdi andq $-0x4, %rdi testb $0x1, %al jne 0xc2852 callq 0xfa8e6 movq %rax, %rdi movq %rax, 0x68(%r14) movq 0x20(%rbx), %rsi addq $0x8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp jmp 0xf5de2 addq $0x8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq movq (%rdx), %rdx jmp 0xc272d movq (%rdi), %rdi jmp 0xc2818 nop
_ZNK6google8protobuf14EnumDescriptor6CopyToEPNS0_19EnumDescriptorProtoE: push rbp push r15 push r14 push r13 push r12 push rbx push rax mov r14, rsi mov rbx, rdi mov rsi, [rdi+8] or dword ptr [r14+10h], 1 lea rdi, [r14+60h] mov rax, [r14+8] mov rdx, rax and rdx, 0FFFFFFFFFFFFFFFCh test al, 1 jnz loc_C284A loc_C272D: call _ZN6google8protobuf8internal14ArenaStringPtr3SetERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEPNS0_5ArenaE; google::protobuf::internal::ArenaStringPtr::Set(std::string const&,google::protobuf::Arena *) cmp dword ptr [rbx+4], 0 jle short loc_C276D lea r15, [r14+18h] xor r13d, r13d xor ebp, ebp loc_C2741: mov r12, [rbx+28h] add r12, r13 mov rdi, r15; this xor esi, esi call _ZN6google8protobuf8internal20RepeatedPtrFieldBase3AddINS0_16RepeatedPtrFieldINS0_24EnumValueDescriptorProtoEE11TypeHandlerEEEPNT_4TypeEPKS9_; google::protobuf::internal::RepeatedPtrFieldBase::Add<google::protobuf::RepeatedPtrField<google::protobuf::EnumValueDescriptorProto>::TypeHandler>(google::protobuf::RepeatedPtrField<google::protobuf::EnumValueDescriptorProto>::TypeHandler::Type * const*) mov rdi, r12; this mov rsi, rax; google::protobuf::EnumValueDescriptorProto * call _ZNK6google8protobuf19EnumValueDescriptor6CopyToEPNS0_24EnumValueDescriptorProtoE; google::protobuf::EnumValueDescriptor::CopyTo(google::protobuf::EnumValueDescriptorProto *) inc rbp movsxd rax, dword ptr [rbx+4] add r13, 20h ; ' ' cmp rbp, rax jl short loc_C2741 loc_C276D: cmp dword ptr [rbx+30h], 0 jle short loc_C27B8 lea r15, [r14+30h] xor r12d, r12d loc_C277A: mov rdi, r15; this xor esi, esi call _ZN6google8protobuf8internal20RepeatedPtrFieldBase3AddINS0_16RepeatedPtrFieldINS0_37EnumDescriptorProto_EnumReservedRangeEE11TypeHandlerEEEPNT_4TypeEPKS9_; google::protobuf::internal::RepeatedPtrFieldBase::Add<google::protobuf::RepeatedPtrField<google::protobuf::EnumDescriptorProto_EnumReservedRange>::TypeHandler>(google::protobuf::RepeatedPtrField<google::protobuf::EnumDescriptorProto_EnumReservedRange>::TypeHandler::Type * const*) mov rcx, [rbx+38h] mov ecx, [rcx+r12*8] mov edx, [rax+10h] mov esi, edx or esi, 1 mov [rax+10h], esi mov [rax+18h], ecx mov rcx, [rbx+38h] mov ecx, [rcx+r12*8+4] or edx, 3 mov [rax+10h], edx mov [rax+1Ch], ecx inc r12 movsxd rax, dword ptr [rbx+30h] cmp r12, rax jl short loc_C277A loc_C27B8: cmp dword ptr [rbx+34h], 0 jle short loc_C27EE lea r15, [r14+48h] xor r13d, r13d loc_C27C5: mov rax, [rbx+40h] mov r12, [rax+r13*8] mov rdi, r15; this xor esi, esi call _ZN6google8protobuf8internal20RepeatedPtrFieldBase3AddINS0_16RepeatedPtrFieldINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEE11TypeHandlerEEEPNT_4TypeEPKSE_; google::protobuf::internal::RepeatedPtrFieldBase::Add<google::protobuf::RepeatedPtrField<std::string>::TypeHandler>(google::protobuf::RepeatedPtrField<std::string>::TypeHandler::Type * const*) mov rdi, rax mov rsi, r12 call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9_M_assignERKS4_; std::string::_M_assign(std::string const&) inc r13 movsxd rax, dword ptr [rbx+34h] cmp r13, rax jl short loc_C27C5 loc_C27EE: mov rsi, [rbx+20h] cmp rsi, cs:_ZN6google8protobuf30_EnumOptions_default_instance_E_ptr jz short loc_C283B or byte ptr [r14+10h], 2 mov rdi, [r14+68h] test rdi, rdi jnz short loc_C2828 mov rax, [r14+8] mov rdi, rax and rdi, 0FFFFFFFFFFFFFFFCh test al, 1 jnz short loc_C2852 loc_C2818: call _ZN6google8protobuf5Arena18CreateMaybeMessageINS0_11EnumOptionsEJEEEPT_PS1_DpOT0_; google::protobuf::Arena::CreateMaybeMessage<google::protobuf::EnumOptions>(google::protobuf::Arena*) mov rdi, rax; this mov [r14+68h], rax mov rsi, [rbx+20h]; google::protobuf::EnumOptions * loc_C2828: add rsp, 8 pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp jmp _ZN6google8protobuf11EnumOptions8CopyFromERKS1_; google::protobuf::EnumOptions::CopyFrom(google::protobuf::EnumOptions const&) loc_C283B: add rsp, 8 pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn loc_C284A: mov rdx, [rdx] jmp loc_C272D loc_C2852: mov rdi, [rdi] jmp short loc_C2818
long long google::protobuf::EnumDescriptor::CopyTo( google::protobuf::EnumDescriptor *this, google::protobuf::EnumDescriptorProto *a2) { long long v4; // rsi google::protobuf::Arena *v5; // rdx long long result; // rax long long v7; // r13 long long v8; // rbp google::protobuf::EnumValueDescriptor *v9; // r12 google::protobuf::EnumValueDescriptorProto *v10; // rax long long v11; // r12 _DWORD *v12; // rax int v13; // ecx int v14; // edx int v15; // ecx long long v16; // r13 long long v17; // r12 long long v18; // rax const google::protobuf::EnumOptions *v19; // rsi google::protobuf::EnumOptions *v20; // rdi _QWORD *v21; // rdi v4 = *((_QWORD *)this + 1); *((_DWORD *)a2 + 4) |= 1u; v5 = (google::protobuf::Arena *)(*((_QWORD *)a2 + 1) & 0xFFFFFFFFFFFFFFFCLL); if ( (*((_QWORD *)a2 + 1) & 1) != 0 ) v5 = *(google::protobuf::Arena **)v5; result = google::protobuf::internal::ArenaStringPtr::Set((long long *)a2 + 12, v4, v5); if ( *((int *)this + 1) > 0 ) { v7 = 0LL; v8 = 0LL; do { v9 = (google::protobuf::EnumValueDescriptor *)(v7 + *((_QWORD *)this + 5)); v10 = (google::protobuf::EnumValueDescriptorProto *)google::protobuf::internal::RepeatedPtrFieldBase::Add<google::protobuf::RepeatedPtrField<google::protobuf::EnumValueDescriptorProto>::TypeHandler>((google::protobuf::EnumDescriptorProto *)((char *)a2 + 24)); google::protobuf::EnumValueDescriptor::CopyTo(v9, v10); ++v8; result = *((int *)this + 1); v7 += 32LL; } while ( v8 < result ); } if ( *((int *)this + 12) > 0 ) { v11 = 0LL; do { v12 = (_DWORD *)google::protobuf::internal::RepeatedPtrFieldBase::Add<google::protobuf::RepeatedPtrField<google::protobuf::EnumDescriptorProto_EnumReservedRange>::TypeHandler>((google::protobuf::EnumDescriptorProto *)((char *)a2 + 48)); v13 = *(_DWORD *)(*((_QWORD *)this + 7) + 8 * v11); v14 = v12[4]; v12[4] = v14 | 1; v12[6] = v13; v15 = *(_DWORD *)(*((_QWORD *)this + 7) + 8 * v11 + 4); v12[4] = v14 | 3; v12[7] = v15; ++v11; result = *((int *)this + 12); } while ( v11 < result ); } if ( *((int *)this + 13) > 0 ) { v16 = 0LL; do { v17 = *(_QWORD *)(*((_QWORD *)this + 8) + 8 * v16); v18 = google::protobuf::internal::RepeatedPtrFieldBase::Add<google::protobuf::RepeatedPtrField<std::string>::TypeHandler>((google::protobuf::EnumDescriptorProto *)((char *)a2 + 72)); std::string::_M_assign(v18, v17); ++v16; result = *((int *)this + 13); } while ( v16 < result ); } v19 = (const google::protobuf::EnumOptions *)*((_QWORD *)this + 4); if ( v19 != (const google::protobuf::EnumOptions *)&google::protobuf::_EnumOptions_default_instance_ ) { *((_BYTE *)a2 + 16) |= 2u; v20 = (google::protobuf::EnumOptions *)*((_QWORD *)a2 + 13); if ( !v20 ) { v21 = (_QWORD *)(*((_QWORD *)a2 + 1) & 0xFFFFFFFFFFFFFFFCLL); if ( (*((_QWORD *)a2 + 1) & 1) != 0 ) v21 = (_QWORD *)*v21; v20 = (google::protobuf::EnumOptions *)google::protobuf::Arena::CreateMaybeMessage<google::protobuf::EnumOptions>(v21); *((_QWORD *)a2 + 13) = v20; v19 = (const google::protobuf::EnumOptions *)*((_QWORD *)this + 4); } return google::protobuf::EnumOptions::CopyFrom(v20, v19); } return result; }
CopyTo: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX PUSH RAX MOV R14,RSI MOV RBX,RDI MOV RSI,qword ptr [RDI + 0x8] OR dword ptr [R14 + 0x10],0x1 LEA RDI,[R14 + 0x60] MOV RAX,qword ptr [R14 + 0x8] MOV RDX,RAX AND RDX,-0x4 TEST AL,0x1 JNZ 0x001c284a LAB_001c272d: CALL 0x001786ce CMP dword ptr [RBX + 0x4],0x0 JLE 0x001c276d LEA R15,[R14 + 0x18] XOR R13D,R13D XOR EBP,EBP LAB_001c2741: MOV R12,qword ptr [RBX + 0x28] ADD R12,R13 MOV RDI,R15 XOR ESI,ESI CALL 0x001e246a MOV RDI,R12 MOV RSI,RAX CALL 0x001c3186 INC RBP MOVSXD RAX,dword ptr [RBX + 0x4] ADD R13,0x20 CMP RBP,RAX JL 0x001c2741 LAB_001c276d: CMP dword ptr [RBX + 0x30],0x0 JLE 0x001c27b8 LEA R15,[R14 + 0x30] XOR R12D,R12D LAB_001c277a: MOV RDI,R15 XOR ESI,ESI CALL 0x001e24a0 MOV RCX,qword ptr [RBX + 0x38] MOV ECX,dword ptr [RCX + R12*0x8] MOV EDX,dword ptr [RAX + 0x10] MOV ESI,EDX OR ESI,0x1 MOV dword ptr [RAX + 0x10],ESI MOV dword ptr [RAX + 0x18],ECX MOV RCX,qword ptr [RBX + 0x38] MOV ECX,dword ptr [RCX + R12*0x8 + 0x4] OR EDX,0x3 MOV dword ptr [RAX + 0x10],EDX MOV dword ptr [RAX + 0x1c],ECX INC R12 MOVSXD RAX,dword ptr [RBX + 0x30] CMP R12,RAX JL 0x001c277a LAB_001c27b8: CMP dword ptr [RBX + 0x34],0x0 JLE 0x001c27ee LEA R15,[R14 + 0x48] XOR R13D,R13D LAB_001c27c5: MOV RAX,qword ptr [RBX + 0x40] MOV R12,qword ptr [RAX + R13*0x8] MOV RDI,R15 XOR ESI,ESI CALL 0x0015cf48 MOV RDI,RAX MOV RSI,R12 CALL 0x0012d240 INC R13 MOVSXD RAX,dword ptr [RBX + 0x34] CMP R13,RAX JL 0x001c27c5 LAB_001c27ee: MOV RSI,qword ptr [RBX + 0x20] CMP RSI,qword ptr [0x0030ff40] JZ 0x001c283b OR byte ptr [R14 + 0x10],0x2 MOV RDI,qword ptr [R14 + 0x68] TEST RDI,RDI JNZ 0x001c2828 MOV RAX,qword ptr [R14 + 0x8] MOV RDI,RAX AND RDI,-0x4 TEST AL,0x1 JNZ 0x001c2852 LAB_001c2818: CALL 0x001fa8e6 MOV RDI,RAX MOV qword ptr [R14 + 0x68],RAX MOV RSI,qword ptr [RBX + 0x20] LAB_001c2828: ADD RSP,0x8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP JMP 0x001f5de2 LAB_001c283b: ADD RSP,0x8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET LAB_001c284a: MOV RDX,qword ptr [RDX] JMP 0x001c272d LAB_001c2852: MOV RDI,qword ptr [RDI] JMP 0x001c2818
/* google::protobuf::EnumDescriptor::CopyTo(google::protobuf::EnumDescriptorProto*) const */ void __thiscall google::protobuf::EnumDescriptor::CopyTo(EnumDescriptor *this,EnumDescriptorProto *param_1) { int4 uVar1; uint uVar2; string *psVar3; long lVar4; Type *pTVar5; Type *pTVar6; Type *this_00; EnumOptions *this_01; Arena *pAVar7; long lVar8; EnumOptions *pEVar9; long lVar10; psVar3 = *(string **)(this + 8); *(uint *)(param_1 + 0x10) = *(uint *)(param_1 + 0x10) | 1; pAVar7 = (Arena *)(*(ulong *)(param_1 + 8) & 0xfffffffffffffffc); if ((*(ulong *)(param_1 + 8) & 1) != 0) { pAVar7 = *(Arena **)pAVar7; } internal::ArenaStringPtr::Set((ArenaStringPtr *)(param_1 + 0x60),psVar3,pAVar7); if (0 < *(int *)(this + 4)) { lVar10 = 0; lVar8 = 0; do { lVar4 = *(long *)(this + 0x28); pTVar5 = internal::RepeatedPtrFieldBase:: Add<google::protobuf::RepeatedPtrField<google::protobuf::EnumValueDescriptorProto>::TypeHandler> ((Type *)(param_1 + 0x18)); EnumValueDescriptor::CopyTo ((EnumValueDescriptor *)(lVar4 + lVar10),(EnumValueDescriptorProto *)pTVar5); lVar8 = lVar8 + 1; lVar10 = lVar10 + 0x20; } while (lVar8 < *(int *)(this + 4)); } if (0 < *(int *)(this + 0x30)) { lVar8 = 0; do { pTVar6 = internal::RepeatedPtrFieldBase:: Add<google::protobuf::RepeatedPtrField<google::protobuf::EnumDescriptorProto_EnumReservedRange>::TypeHandler> ((Type *)(param_1 + 0x30)); uVar1 = *(int4 *)(*(long *)(this + 0x38) + lVar8 * 8); uVar2 = *(uint *)(pTVar6 + 0x10); *(uint *)(pTVar6 + 0x10) = uVar2 | 1; *(int4 *)(pTVar6 + 0x18) = uVar1; uVar1 = *(int4 *)(*(long *)(this + 0x38) + 4 + lVar8 * 8); *(uint *)(pTVar6 + 0x10) = uVar2 | 3; *(int4 *)(pTVar6 + 0x1c) = uVar1; lVar8 = lVar8 + 1; } while (lVar8 < *(int *)(this + 0x30)); } if (0 < *(int *)(this + 0x34)) { lVar8 = 0; do { psVar3 = *(string **)(*(long *)(this + 0x40) + lVar8 * 8); this_00 = internal::RepeatedPtrFieldBase:: Add<google::protobuf::RepeatedPtrField<std::__cxx11::string>::TypeHandler> ((Type *)(param_1 + 0x48)); std::__cxx11::string::_M_assign((string *)this_00,psVar3); lVar8 = lVar8 + 1; } while (lVar8 < *(int *)(this + 0x34)); } pEVar9 = *(EnumOptions **)(this + 0x20); if (pEVar9 != (EnumOptions *)PTR__EnumOptions_default_instance__0030ff40) { param_1[0x10] = (EnumDescriptorProto)((byte)param_1[0x10] | 2); this_01 = *(EnumOptions **)(param_1 + 0x68); if (this_01 == (EnumOptions *)0x0) { pAVar7 = (Arena *)(*(ulong *)(param_1 + 8) & 0xfffffffffffffffc); if ((*(ulong *)(param_1 + 8) & 1) != 0) { pAVar7 = *(Arena **)pAVar7; } this_01 = Arena::CreateMaybeMessage<google::protobuf::EnumOptions>(pAVar7); *(EnumOptions **)(param_1 + 0x68) = this_01; pEVar9 = *(EnumOptions **)(this + 0x20); } EnumOptions::CopyFrom(this_01,pEVar9); return; } return; }
31,895
print_params(SDParams)
7CodeWizard[P]stablediffusion/examples/cli/main.cpp
void print_params(SDParams params) { printf("Option: \n"); printf(" n_threads: %d\n", params.n_threads); printf(" mode: %s\n", modes_str[params.mode]); printf(" model_path: %s\n", params.model_path.c_str()); printf(" wtype: %s\n", params.wtype < SD_TYPE_COUNT ? sd_type_name(params.wtype) : "unspecified"); printf(" vae_path: %s\n", params.vae_path.c_str()); printf(" taesd_path: %s\n", params.taesd_path.c_str()); printf(" esrgan_path: %s\n", params.esrgan_path.c_str()); printf(" output_path: %s\n", params.output_path.c_str()); printf(" init_img: %s\n", params.input_path.c_str()); printf(" prompt: %s\n", params.prompt.c_str()); printf(" negative_prompt: %s\n", params.negative_prompt.c_str()); printf(" cfg_scale: %.2f\n", params.cfg_scale); printf(" clip_skip: %d\n", params.clip_skip); printf(" width: %d\n", params.width); printf(" height: %d\n", params.height); printf(" sample_method: %s\n", sample_method_str[params.sample_method]); printf(" schedule: %s\n", schedule_str[params.schedule]); printf(" sample_steps: %d\n", params.sample_steps); printf(" strength(img2img): %.2f\n", params.strength); printf(" rng: %s\n", rng_type_to_str[params.rng_type]); printf(" seed: %ld\n", params.seed); printf(" batch_count: %d\n", params.batch_count); printf(" vae_tiling: %s\n", params.vae_tiling ? "true" : "false"); }
O2
cpp
print_params(SDParams): pushq %rbx movq %rdi, %rbx leaq 0x8b11d(%rip), %rdi # 0x98bed callq 0xa940 movl (%rbx), %esi leaq 0x8a2e3(%rip), %rdi # 0x97dc1 xorl %eax, %eax callq 0xa070 movl 0x4(%rbx), %eax leaq 0xc8bd1(%rip), %rcx # 0xd66c0 movq (%rcx,%rax,8), %rsi leaq 0x8a2e2(%rip), %rdi # 0x97ddc xorl %eax, %eax callq 0xa070 movq 0x8(%rbx), %rsi leaq 0x8a2eb(%rip), %rdi # 0x97df7 xorl %eax, %eax callq 0xa070 movl 0x88(%rbx), %edi cmpl $0x12, %edi jg 0xdb28 callq 0x563c4 movq %rax, %rsi jmp 0xdb2f leaq 0x8a2fe(%rip), %rsi # 0x97e2d leaq 0x8a2dc(%rip), %rdi # 0x97e12 xorl %eax, %eax callq 0xa070 movq 0x28(%rbx), %rsi leaq 0x8a2f1(%rip), %rdi # 0x97e39 xorl %eax, %eax callq 0xa070 movq 0x48(%rbx), %rsi leaq 0x8a2fa(%rip), %rdi # 0x97e54 xorl %eax, %eax callq 0xa070 movq 0x68(%rbx), %rsi leaq 0x8a303(%rip), %rdi # 0x97e6f xorl %eax, %eax callq 0xa070 movq 0xb0(%rbx), %rsi leaq 0x8a309(%rip), %rdi # 0x97e8a xorl %eax, %eax callq 0xa070 movq 0xd0(%rbx), %rsi leaq 0x8a30f(%rip), %rdi # 0x97ea5 xorl %eax, %eax callq 0xa070 movq 0xf0(%rbx), %rsi leaq 0x8a315(%rip), %rdi # 0x97ec0 xorl %eax, %eax callq 0xa070 movq 0x110(%rbx), %rsi leaq 0x8a31b(%rip), %rdi # 0x97edb xorl %eax, %eax callq 0xa070 cvtss2sd 0x130(%rbx), %xmm0 leaq 0x8a320(%rip), %rdi # 0x97ef6 movb $0x1, %al callq 0xa070 movl 0x134(%rbx), %esi leaq 0x8a329(%rip), %rdi # 0x97f13 xorl %eax, %eax callq 0xa070 movl 0x138(%rbx), %esi leaq 0x8a330(%rip), %rdi # 0x97f2e xorl %eax, %eax callq 0xa070 movl 0x13c(%rbx), %esi leaq 0x8a337(%rip), %rdi # 0x97f49 xorl %eax, %eax callq 0xa070 movl 0x144(%rbx), %eax leaq 0xc8a3a(%rip), %rcx # 0xd6660 movq (%rcx,%rax,8), %rsi leaq 0x8a333(%rip), %rdi # 0x97f64 xorl %eax, %eax callq 0xa070 movl 0x148(%rbx), %eax leaq 0xc8a5b(%rip), %rcx # 0xd66a0 movq (%rcx,%rax,8), %rsi leaq 0x8a32f(%rip), %rdi # 0x97f7f xorl %eax, %eax callq 0xa070 movl 0x14c(%rbx), %esi leaq 0x8a336(%rip), %rdi # 0x97f9a xorl %eax, %eax callq 0xa070 cvtss2sd 0x150(%rbx), %xmm0 leaq 0x8a33b(%rip), %rdi # 0x97fb5 movb $0x1, %al callq 0xa070 movl 0x154(%rbx), %eax leaq 0xc89c2(%rip), %rcx # 0xd6650 movq (%rcx,%rax,8), %rsi leaq 0x8a339(%rip), %rdi # 0x97fd2 xorl %eax, %eax callq 0xa070 movq 0x158(%rbx), %rsi leaq 0x8a33f(%rip), %rdi # 0x97fed xorl %eax, %eax callq 0xa070 movl 0x140(%rbx), %esi leaq 0x8a347(%rip), %rdi # 0x98009 xorl %eax, %eax callq 0xa070 leaq 0x969e5(%rip), %rax # 0xa46b5 leaq 0x8a368(%rip), %rsi # 0x9803f cmpb $0x0, 0x161(%rbx) cmovneq %rax, %rsi leaq 0x8a33b(%rip), %rdi # 0x98024 xorl %eax, %eax popq %rbx jmp 0xa070
_Z12print_params8SDParams: push rbx mov rbx, rdi lea rdi, aOption; "Option: " call _puts mov esi, [rbx] lea rdi, aNThreadsD; " n_threads: %d\n" xor eax, eax call _printf mov eax, [rbx+4] lea rcx, modes_str mov rsi, [rcx+rax*8] lea rdi, aModeS; " mode: %s\n" xor eax, eax call _printf mov rsi, [rbx+8] lea rdi, aModelPathS; " model_path: %s\n" xor eax, eax call _printf mov edi, [rbx+88h] cmp edi, 12h jg short loc_DB28 call sd_type_name mov rsi, rax jmp short loc_DB2F loc_DB28: lea rsi, aUnspecified; "unspecified" loc_DB2F: lea rdi, aWtypeS; " wtype: %s\n" xor eax, eax call _printf mov rsi, [rbx+28h] lea rdi, aVaePathS; " vae_path: %s\n" xor eax, eax call _printf mov rsi, [rbx+48h] lea rdi, aTaesdPathS; " taesd_path: %s\n" xor eax, eax call _printf mov rsi, [rbx+68h] lea rdi, aEsrganPathS; " esrgan_path: %s\n" xor eax, eax call _printf mov rsi, [rbx+0B0h] lea rdi, aOutputPathS; " output_path: %s\n" xor eax, eax call _printf mov rsi, [rbx+0D0h] lea rdi, aInitImgS; " init_img: %s\n" xor eax, eax call _printf mov rsi, [rbx+0F0h] lea rdi, aPromptS; " prompt: %s\n" xor eax, eax call _printf mov rsi, [rbx+110h] lea rdi, aNegativePrompt; " negative_prompt: %s\n" xor eax, eax call _printf cvtss2sd xmm0, dword ptr [rbx+130h] lea rdi, aCfgScale2f; " cfg_scale: %.2f\n" mov al, 1 call _printf mov esi, [rbx+134h] lea rdi, aClipSkipD; " clip_skip: %d\n" xor eax, eax call _printf mov esi, [rbx+138h] lea rdi, aWidthD; " width: %d\n" xor eax, eax call _printf mov esi, [rbx+13Ch] lea rdi, aHeightD; " height: %d\n" xor eax, eax call _printf mov eax, [rbx+144h] lea rcx, sample_method_str mov rsi, [rcx+rax*8] lea rdi, aSampleMethodS; " sample_method: %s\n" xor eax, eax call _printf mov eax, [rbx+148h] lea rcx, schedule_str mov rsi, [rcx+rax*8] lea rdi, aScheduleS; " schedule: %s\n" xor eax, eax call _printf mov esi, [rbx+14Ch] lea rdi, aSampleStepsD; " sample_steps: %d\n" xor eax, eax call _printf cvtss2sd xmm0, dword ptr [rbx+150h] lea rdi, aStrengthImg2im; " strength(img2img): %.2f\n" mov al, 1 call _printf mov eax, [rbx+154h] lea rcx, rng_type_to_str mov rsi, [rcx+rax*8] lea rdi, aRngS; " rng: %s\n" xor eax, eax call _printf mov rsi, [rbx+158h] lea rdi, aSeedLd; " seed: %ld\n" xor eax, eax call _printf mov esi, [rbx+140h] lea rdi, aBatchCountD; " batch_count: %d\n" xor eax, eax call _printf lea rax, aGgmlGetNoAlloc+1Ah; "true" lea rsi, aFalse; "false" cmp byte ptr [rbx+161h], 0 cmovnz rsi, rax lea rdi, aVaeTilingS; " vae_tiling: %s\n" xor eax, eax pop rbx jmp _printf
long long print_params(long long a1) { const char *v1; // rsi const char *v2; // rsi puts("Option: "); printf(" n_threads: %d\n", *(_DWORD *)a1); printf(" mode: %s\n", (&modes_str)[*(unsigned int *)(a1 + 4)]); printf(" model_path: %s\n", *(const char **)(a1 + 8)); if ( *(int *)(a1 + 136) > 18 ) v1 = "unspecified"; else v1 = (const char *)sd_type_name(); printf(" wtype: %s\n", v1); printf(" vae_path: %s\n", *(const char **)(a1 + 40)); printf(" taesd_path: %s\n", *(const char **)(a1 + 72)); printf(" esrgan_path: %s\n", *(const char **)(a1 + 104)); printf(" output_path: %s\n", *(const char **)(a1 + 176)); printf(" init_img: %s\n", *(const char **)(a1 + 208)); printf(" prompt: %s\n", *(const char **)(a1 + 240)); printf(" negative_prompt: %s\n", *(const char **)(a1 + 272)); printf(" cfg_scale: %.2f\n", *(float *)(a1 + 304)); printf(" clip_skip: %d\n", *(_DWORD *)(a1 + 308)); printf(" width: %d\n", *(_DWORD *)(a1 + 312)); printf(" height: %d\n", *(_DWORD *)(a1 + 316)); printf(" sample_method: %s\n", sample_method_str[*(unsigned int *)(a1 + 324)]); printf(" schedule: %s\n", (const char *)*(&schedule_str + *(unsigned int *)(a1 + 328))); printf(" sample_steps: %d\n", *(_DWORD *)(a1 + 332)); printf(" strength(img2img): %.2f\n", *(float *)(a1 + 336)); printf(" rng: %s\n", rng_type_to_str[*(unsigned int *)(a1 + 340)]); printf(" seed: %ld\n", *(_QWORD *)(a1 + 344)); printf(" batch_count: %d\n", *(_DWORD *)(a1 + 320)); v2 = "false"; if ( *(_BYTE *)(a1 + 353) ) v2 = "true"; return printf(" vae_tiling: %s\n", v2); }
print_params: PUSH RBX MOV RBX,RDI LEA RDI,[0x198bed] CALL 0x0010a940 MOV ESI,dword ptr [RBX] LEA RDI,[0x197dc1] XOR EAX,EAX CALL 0x0010a070 MOV EAX,dword ptr [RBX + 0x4] LEA RCX,[0x1d66c0] MOV RSI,qword ptr [RCX + RAX*0x8] LEA RDI,[0x197ddc] XOR EAX,EAX CALL 0x0010a070 MOV RSI,qword ptr [RBX + 0x8] LEA RDI,[0x197df7] XOR EAX,EAX CALL 0x0010a070 MOV EDI,dword ptr [RBX + 0x88] CMP EDI,0x12 JG 0x0010db28 CALL 0x001563c4 MOV RSI,RAX JMP 0x0010db2f LAB_0010db28: LEA RSI,[0x197e2d] LAB_0010db2f: LEA RDI,[0x197e12] XOR EAX,EAX CALL 0x0010a070 MOV RSI,qword ptr [RBX + 0x28] LEA RDI,[0x197e39] XOR EAX,EAX CALL 0x0010a070 MOV RSI,qword ptr [RBX + 0x48] LEA RDI,[0x197e54] XOR EAX,EAX CALL 0x0010a070 MOV RSI,qword ptr [RBX + 0x68] LEA RDI,[0x197e6f] XOR EAX,EAX CALL 0x0010a070 MOV RSI,qword ptr [RBX + 0xb0] LEA RDI,[0x197e8a] XOR EAX,EAX CALL 0x0010a070 MOV RSI,qword ptr [RBX + 0xd0] LEA RDI,[0x197ea5] XOR EAX,EAX CALL 0x0010a070 MOV RSI,qword ptr [RBX + 0xf0] LEA RDI,[0x197ec0] XOR EAX,EAX CALL 0x0010a070 MOV RSI,qword ptr [RBX + 0x110] LEA RDI,[0x197edb] XOR EAX,EAX CALL 0x0010a070 CVTSS2SD XMM0,dword ptr [RBX + 0x130] LEA RDI,[0x197ef6] MOV AL,0x1 CALL 0x0010a070 MOV ESI,dword ptr [RBX + 0x134] LEA RDI,[0x197f13] XOR EAX,EAX CALL 0x0010a070 MOV ESI,dword ptr [RBX + 0x138] LEA RDI,[0x197f2e] XOR EAX,EAX CALL 0x0010a070 MOV ESI,dword ptr [RBX + 0x13c] LEA RDI,[0x197f49] XOR EAX,EAX CALL 0x0010a070 MOV EAX,dword ptr [RBX + 0x144] LEA RCX,[0x1d6660] MOV RSI,qword ptr [RCX + RAX*0x8] LEA RDI,[0x197f64] XOR EAX,EAX CALL 0x0010a070 MOV EAX,dword ptr [RBX + 0x148] LEA RCX,[0x1d66a0] MOV RSI,qword ptr [RCX + RAX*0x8] LEA RDI,[0x197f7f] XOR EAX,EAX CALL 0x0010a070 MOV ESI,dword ptr [RBX + 0x14c] LEA RDI,[0x197f9a] XOR EAX,EAX CALL 0x0010a070 CVTSS2SD XMM0,dword ptr [RBX + 0x150] LEA RDI,[0x197fb5] MOV AL,0x1 CALL 0x0010a070 MOV EAX,dword ptr [RBX + 0x154] LEA RCX,[0x1d6650] MOV RSI,qword ptr [RCX + RAX*0x8] LEA RDI,[0x197fd2] XOR EAX,EAX CALL 0x0010a070 MOV RSI,qword ptr [RBX + 0x158] LEA RDI,[0x197fed] XOR EAX,EAX CALL 0x0010a070 MOV ESI,dword ptr [RBX + 0x140] LEA RDI,[0x198009] XOR EAX,EAX CALL 0x0010a070 LEA RAX,[0x1a46b5] LEA RSI,[0x19803f] CMP byte ptr [RBX + 0x161],0x0 CMOVNZ RSI,RAX LEA RDI,[0x198024] XOR EAX,EAX POP RBX JMP 0x0010a070
/* print_params(SDParams) */ void print_params(uint *param_1) { char *pcVar1; puts("Option: "); printf(" n_threads: %d\n",(ulong)*param_1); printf(" mode: %s\n",(&modes_str)[param_1[1]]); printf(" model_path: %s\n",*(int8 *)(param_1 + 2)); if ((int)param_1[0x22] < 0x13) { pcVar1 = (char *)sd_type_name(); } else { pcVar1 = "unspecified"; } printf(" wtype: %s\n",pcVar1); printf(" vae_path: %s\n",*(int8 *)(param_1 + 10)); printf(" taesd_path: %s\n",*(int8 *)(param_1 + 0x12)); printf(" esrgan_path: %s\n",*(int8 *)(param_1 + 0x1a)); printf(" output_path: %s\n",*(int8 *)(param_1 + 0x2c)); printf(" init_img: %s\n",*(int8 *)(param_1 + 0x34)); printf(" prompt: %s\n",*(int8 *)(param_1 + 0x3c)); printf(" negative_prompt: %s\n",*(int8 *)(param_1 + 0x44)); printf(" cfg_scale: %.2f\n",(double)(float)param_1[0x4c]); printf(" clip_skip: %d\n",(ulong)param_1[0x4d]); printf(" width: %d\n",(ulong)param_1[0x4e]); printf(" height: %d\n",(ulong)param_1[0x4f]); printf(" sample_method: %s\n",(&sample_method_str)[param_1[0x51]]); printf(" schedule: %s\n",(&schedule_str)[param_1[0x52]]); printf(" sample_steps: %d\n",(ulong)param_1[0x53]); printf(" strength(img2img): %.2f\n",(double)(float)param_1[0x54]); printf(" rng: %s\n",*(int8 *)(rng_type_to_str + (ulong)param_1[0x55] * 8)); printf(" seed: %ld\n",*(int8 *)(param_1 + 0x56)); printf(" batch_count: %d\n",(ulong)param_1[0x50]); pcVar1 = "false"; if (*(char *)((long)param_1 + 0x161) != '\0') { pcVar1 = "true"; } printf(" vae_tiling: %s\n",pcVar1); return; }
31,896
my_scan_utf32
eloqsql/strings/ctype-ucs2.c
static size_t my_scan_utf32(CHARSET_INFO *cs, const char *str, const char *end, int sequence_type) { const char *str0= str; switch (sequence_type) { case MY_SEQ_SPACES: for ( ; str < end; ) { my_wc_t wc; int res= my_utf32_uni(cs, &wc, (uchar*) str, (uchar*) end); if (res < 0 || wc != ' ') break; str+= res; } return (size_t) (str - str0); case MY_SEQ_NONSPACES: DBUG_ASSERT(0); /* Not implemented */ /* pass through */ default: return 0; } }
O0
c
my_scan_utf32: pushq %rbp movq %rsp, %rbp subq $0x40, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq %rdx, -0x20(%rbp) movl %ecx, -0x24(%rbp) movq -0x18(%rbp), %rax movq %rax, -0x30(%rbp) movl -0x24(%rbp), %eax movl %eax, -0x40(%rbp) subl $0x2, %eax je 0xab8e6 jmp 0xab8dc movl -0x40(%rbp), %eax subl $0x3, %eax je 0xab93d jmp 0xab943 jmp 0xab8e8 movq -0x18(%rbp), %rax cmpq -0x20(%rbp), %rax jae 0xab92c movq -0x10(%rbp), %rdi movq -0x18(%rbp), %rdx movq -0x20(%rbp), %rcx leaq -0x38(%rbp), %rsi callq 0xaad50 movl %eax, -0x3c(%rbp) cmpl $0x0, -0x3c(%rbp) jl 0xab917 cmpq $0x20, -0x38(%rbp) je 0xab919 jmp 0xab92c movl -0x3c(%rbp), %ecx movq -0x18(%rbp), %rax movslq %ecx, %rcx addq %rcx, %rax movq %rax, -0x18(%rbp) jmp 0xab8e8 movq -0x18(%rbp), %rax movq -0x30(%rbp), %rcx subq %rcx, %rax movq %rax, -0x8(%rbp) jmp 0xab94b jmp 0xab93f jmp 0xab941 jmp 0xab943 movq $0x0, -0x8(%rbp) movq -0x8(%rbp), %rax addq $0x40, %rsp popq %rbp retq nopw %cs:(%rax,%rax)
my_scan_utf32: 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_24], ecx mov rax, [rbp+var_18] mov [rbp+var_30], rax mov eax, [rbp+var_24] mov [rbp+var_40], eax sub eax, 2 jz short loc_AB8E6 jmp short $+2 loc_AB8DC: mov eax, [rbp+var_40] sub eax, 3 jz short loc_AB93D jmp short loc_AB943 loc_AB8E6: jmp short $+2 loc_AB8E8: mov rax, [rbp+var_18] cmp rax, [rbp+var_20] jnb short loc_AB92C mov rdi, [rbp+var_10] mov rdx, [rbp+var_18] mov rcx, [rbp+var_20] lea rsi, [rbp+var_38] call my_utf32_uni mov [rbp+var_3C], eax cmp [rbp+var_3C], 0 jl short loc_AB917 cmp [rbp+var_38], 20h ; ' ' jz short loc_AB919 loc_AB917: jmp short loc_AB92C loc_AB919: mov ecx, [rbp+var_3C] mov rax, [rbp+var_18] movsxd rcx, ecx add rax, rcx mov [rbp+var_18], rax jmp short loc_AB8E8 loc_AB92C: mov rax, [rbp+var_18] mov rcx, [rbp+var_30] sub rax, rcx mov [rbp+var_8], rax jmp short loc_AB94B loc_AB93D: jmp short $+2 loc_AB93F: jmp short $+2 loc_AB941: jmp short $+2 loc_AB943: mov [rbp+var_8], 0 loc_AB94B: mov rax, [rbp+var_8] add rsp, 40h pop rbp retn
unsigned long long my_scan_utf32( long long a1, unsigned long long a2, unsigned long long a3, int a4, long long a5, long long a6) { int v7; // [rsp+4h] [rbp-3Ch] long long v8; // [rsp+8h] [rbp-38h] BYREF unsigned long long v9; // [rsp+10h] [rbp-30h] int v10; // [rsp+1Ch] [rbp-24h] unsigned long long v11; // [rsp+20h] [rbp-20h] unsigned long long v12; // [rsp+28h] [rbp-18h] long long v13; // [rsp+30h] [rbp-10h] v13 = a1; v12 = a2; v11 = a3; v10 = a4; v9 = a2; if ( a4 != 2 ) return 0LL; while ( v12 < v11 ) { v7 = my_utf32_uni(v13, (long long)&v8, v12, v11, a5, a6); if ( v7 < 0 || v8 != 32 ) break; v12 += v7; } return v12 - v9; }
my_scan_utf32: 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 dword ptr [RBP + -0x24],ECX MOV RAX,qword ptr [RBP + -0x18] MOV qword ptr [RBP + -0x30],RAX MOV EAX,dword ptr [RBP + -0x24] MOV dword ptr [RBP + -0x40],EAX SUB EAX,0x2 JZ 0x001ab8e6 JMP 0x001ab8dc LAB_001ab8dc: MOV EAX,dword ptr [RBP + -0x40] SUB EAX,0x3 JZ 0x001ab93d JMP 0x001ab943 LAB_001ab8e6: JMP 0x001ab8e8 LAB_001ab8e8: MOV RAX,qword ptr [RBP + -0x18] CMP RAX,qword ptr [RBP + -0x20] JNC 0x001ab92c MOV RDI,qword ptr [RBP + -0x10] MOV RDX,qword ptr [RBP + -0x18] MOV RCX,qword ptr [RBP + -0x20] LEA RSI,[RBP + -0x38] CALL 0x001aad50 MOV dword ptr [RBP + -0x3c],EAX CMP dword ptr [RBP + -0x3c],0x0 JL 0x001ab917 CMP qword ptr [RBP + -0x38],0x20 JZ 0x001ab919 LAB_001ab917: JMP 0x001ab92c LAB_001ab919: MOV ECX,dword ptr [RBP + -0x3c] MOV RAX,qword ptr [RBP + -0x18] MOVSXD RCX,ECX ADD RAX,RCX MOV qword ptr [RBP + -0x18],RAX JMP 0x001ab8e8 LAB_001ab92c: MOV RAX,qword ptr [RBP + -0x18] MOV RCX,qword ptr [RBP + -0x30] SUB RAX,RCX MOV qword ptr [RBP + -0x8],RAX JMP 0x001ab94b LAB_001ab93d: JMP 0x001ab93f LAB_001ab93f: JMP 0x001ab941 LAB_001ab941: JMP 0x001ab943 LAB_001ab943: MOV qword ptr [RBP + -0x8],0x0 LAB_001ab94b: MOV RAX,qword ptr [RBP + -0x8] ADD RSP,0x40 POP RBP RET
long my_scan_utf32(int8 param_1,ulong param_2,ulong param_3,int param_4) { int iVar1; long local_40; ulong local_38; int4 local_2c; ulong local_28; ulong local_20; int8 local_18; long local_10; if (param_4 == 2) { local_2c = 2; local_38 = param_2; local_28 = param_3; local_20 = param_2; local_18 = param_1; while (((local_20 < local_28 && (iVar1 = my_utf32_uni(local_18,&local_40,local_20,local_28), -1 < iVar1)) && (local_40 == 0x20))) { local_20 = local_20 + (long)iVar1; } local_10 = local_20 - local_38; } else { local_10 = 0; } return local_10; }
31,897
dump_header_page
eloqsql/storage/maria/ma_loghandler.c
static void dump_header_page(uchar *buff) { LOGHANDLER_FILE_INFO desc; char strbuff[21]; struct tm tmp_tm; time_t header_time; translog_interpret_file_header(&desc, buff); header_time= desc.timestamp/1000000ULL; localtime_r(&header_time, &tmp_tm); printf(" This can be header page:\n" " Timestamp: %04d.%02d.%02d %02d.%02d.%02d (%s)\n" " Aria log version: %lu\n" " Server version: %lu\n" " Server id %lu\n" " Page size %lu\n", tmp_tm.tm_year+1900, tmp_tm.tm_mon+1, tmp_tm.tm_mday, tmp_tm.tm_hour, tmp_tm.tm_min, tmp_tm.tm_sec, llstr(desc.timestamp, strbuff), desc.maria_version, desc.mysql_version, desc.server_id, desc.page_size); if (desc.page_size != TRANSLOG_PAGE_SIZE) printf(" WARNING: page size is not equal compiled in one %lu!!!\n", (ulong) TRANSLOG_PAGE_SIZE); printf(" File number %lu\n" " Max lsn: " LSN_FMT "\n", desc.file_number, LSN_IN_PARTS(desc.max_lsn)); }
O0
c
dump_header_page: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %rbx subq $0xf8, %rsp movq %fs:0x28, %rax movq %rax, -0x20(%rbp) movq %rdi, -0x48(%rbp) movq -0x48(%rbp), %rsi leaq -0x80(%rbp), %rdi callq 0x87520 movq -0x78(%rbp), %rax movl $0xf4240, %ecx # imm = 0xF4240 xorl %edx, %edx divq %rcx movq %rax, -0xc0(%rbp) leaq -0xc0(%rbp), %rdi leaq -0xb8(%rbp), %rsi callq 0x2a140 movl -0xa4(%rbp), %eax addl $0x76c, %eax # imm = 0x76C movl %eax, -0xd4(%rbp) movl -0xa8(%rbp), %eax addl $0x1, %eax movl %eax, -0xd0(%rbp) movl -0xac(%rbp), %eax movl %eax, -0xcc(%rbp) movl -0xb0(%rbp), %eax movl %eax, -0xc8(%rbp) movl -0xb4(%rbp), %eax movl %eax, -0xc4(%rbp) movl -0xb8(%rbp), %r15d movq -0x78(%rbp), %rdi leaq -0x40(%rbp), %rsi callq 0x154690 movl -0xd4(%rbp), %esi movl -0xd0(%rbp), %edx movl -0xcc(%rbp), %ecx movl -0xc8(%rbp), %r8d movl -0xc4(%rbp), %r9d movq %rax, %r14 movq -0x70(%rbp), %rbx movq -0x68(%rbp), %r11 movq -0x60(%rbp), %r10 movq -0x58(%rbp), %rax leaq 0xcb347(%rip), %rdi # 0x15b36f movl %r15d, (%rsp) movq %r14, 0x8(%rsp) movq %rbx, 0x10(%rsp) movq %r11, 0x18(%rsp) movq %r10, 0x20(%rsp) movq %rax, 0x28(%rsp) movb $0x0, %al callq 0x2a070 cmpq $0x2000, -0x58(%rbp) # imm = 0x2000 je 0x90069 leaq 0xcb3b7(%rip), %rdi # 0x15b414 movl $0x2000, %esi # imm = 0x2000 movb $0x0, %al callq 0x2a070 movq -0x80(%rbp), %rax movq -0x50(%rbp), %rsi movq %rax, %rcx shrq $0x20, %rcx movl %ecx, %edx movl %eax, %ecx leaq 0xcb3cf(%rip), %rdi # 0x15b452 xorl %eax, %eax callq 0x2a070 movq %fs:0x28, %rax movq -0x20(%rbp), %rcx cmpq %rcx, %rax jne 0x900aa addq $0xf8, %rsp popq %rbx popq %r14 popq %r15 popq %rbp retq callq 0x2a260 nop
dump_header_page: push rbp mov rbp, rsp push r15 push r14 push rbx sub rsp, 0F8h mov rax, fs:28h mov [rbp+var_20], rax mov [rbp+var_48], rdi mov rsi, [rbp+var_48] lea rdi, [rbp+var_80] call translog_interpret_file_header mov rax, [rbp+var_78] mov ecx, 0F4240h xor edx, edx div rcx mov [rbp+var_C0], rax lea rdi, [rbp+var_C0] lea rsi, [rbp+var_B8] call _localtime_r mov eax, [rbp+var_A4] add eax, 76Ch mov [rbp+var_D4], eax mov eax, [rbp+var_A8] add eax, 1 mov [rbp+var_D0], eax mov eax, [rbp+var_AC] mov [rbp+var_CC], eax mov eax, [rbp+var_B0] mov [rbp+var_C8], eax mov eax, [rbp+var_B4] mov [rbp+var_C4], eax mov r15d, [rbp+var_B8] mov rdi, [rbp+var_78] lea rsi, [rbp+var_40] call llstr mov esi, [rbp+var_D4] mov edx, [rbp+var_D0] mov ecx, [rbp+var_CC] mov r8d, [rbp+var_C8] mov r9d, [rbp+var_C4] mov r14, rax mov rbx, [rbp+var_70] mov r11, [rbp+var_68] mov r10, [rbp+var_60] mov rax, [rbp+var_58] lea rdi, aThisCanBeHeade; " This can be header page:\n Timesta"... mov [rsp+110h+var_110], r15d mov [rsp+110h+var_108], r14 mov [rsp+110h+var_100], rbx mov [rsp+110h+var_F8], r11 mov [rsp+110h+var_F0], r10 mov [rsp+110h+var_E8], rax mov al, 0 call _printf cmp [rbp+var_58], 2000h jz short loc_90069 lea rdi, aWarningPageSiz; " WARNING: page size is not equal c"... mov esi, 2000h mov al, 0 call _printf loc_90069: mov rax, [rbp+var_80] mov rsi, [rbp+var_50] mov rcx, rax shr rcx, 20h mov edx, ecx mov ecx, eax lea rdi, aFileNumberLuMa; " File number %lu\n Max lsn: (%u,0"... xor eax, eax call _printf mov rax, fs:28h mov rcx, [rbp+var_20] cmp rax, rcx jnz short loc_900AA add rsp, 0F8h pop rbx pop r14 pop r15 pop rbp retn loc_900AA: call ___stack_chk_fail
unsigned long long dump_header_page(long long a1) { int v1; // r15d const char *v2; // rax int v4; // [rsp+3Ch] [rbp-D4h] int v5; // [rsp+40h] [rbp-D0h] int v6; // [rsp+44h] [rbp-CCh] int v7; // [rsp+48h] [rbp-C8h] int v8; // [rsp+4Ch] [rbp-C4h] unsigned long long v9; // [rsp+50h] [rbp-C0h] BYREF _DWORD v10[14]; // [rsp+58h] [rbp-B8h] BYREF unsigned long long v11; // [rsp+90h] [rbp-80h] BYREF unsigned long long v12; // [rsp+98h] [rbp-78h] long long v13; // [rsp+A0h] [rbp-70h] long long v14; // [rsp+A8h] [rbp-68h] long long v15; // [rsp+B0h] [rbp-60h] long long v16; // [rsp+B8h] [rbp-58h] long long v17; // [rsp+C0h] [rbp-50h] long long v18; // [rsp+C8h] [rbp-48h] _BYTE v19[32]; // [rsp+D0h] [rbp-40h] BYREF unsigned long long v20; // [rsp+F0h] [rbp-20h] v20 = __readfsqword(0x28u); v18 = a1; translog_interpret_file_header(&v11, a1); v9 = v12 / 0xF4240; localtime_r(&v9, v10, v12 % 0xF4240); v4 = v10[5] + 1900; v5 = v10[4] + 1; v6 = v10[3]; v7 = v10[2]; v8 = v10[1]; v1 = v10[0]; v2 = (const char *)llstr(v12, v19); printf( " This can be header page:\n" " Timestamp: %04d.%02d.%02d %02d.%02d.%02d (%s)\n" " Aria log version: %lu\n" " Server version: %lu\n" " Server id %lu\n" " Page size %lu\n", v4, v5, v6, v7, v8, v1, v2, v13, v14, v15, v16); if ( v16 != 0x2000 ) printf(" WARNING: page size is not equal compiled in one %lu!!!\n", 0x2000LL); printf(" File number %lu\n Max lsn: (%u,0x%x)\n", v17, HIDWORD(v11), v11); return __readfsqword(0x28u); }
dump_header_page: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH RBX SUB RSP,0xf8 MOV RAX,qword ptr FS:[0x28] MOV qword ptr [RBP + -0x20],RAX MOV qword ptr [RBP + -0x48],RDI MOV RSI,qword ptr [RBP + -0x48] LEA RDI,[RBP + -0x80] CALL 0x00187520 MOV RAX,qword ptr [RBP + -0x78] MOV ECX,0xf4240 XOR EDX,EDX DIV RCX MOV qword ptr [RBP + -0xc0],RAX LEA RDI,[RBP + -0xc0] LEA RSI,[RBP + -0xb8] CALL 0x0012a140 MOV EAX,dword ptr [RBP + -0xa4] ADD EAX,0x76c MOV dword ptr [RBP + -0xd4],EAX MOV EAX,dword ptr [RBP + -0xa8] ADD EAX,0x1 MOV dword ptr [RBP + -0xd0],EAX MOV EAX,dword ptr [RBP + -0xac] MOV dword ptr [RBP + -0xcc],EAX MOV EAX,dword ptr [RBP + -0xb0] MOV dword ptr [RBP + -0xc8],EAX MOV EAX,dword ptr [RBP + -0xb4] MOV dword ptr [RBP + -0xc4],EAX MOV R15D,dword ptr [RBP + -0xb8] MOV RDI,qword ptr [RBP + -0x78] LEA RSI,[RBP + -0x40] CALL 0x00254690 MOV ESI,dword ptr [RBP + -0xd4] MOV EDX,dword ptr [RBP + -0xd0] MOV ECX,dword ptr [RBP + -0xcc] MOV R8D,dword ptr [RBP + -0xc8] MOV R9D,dword ptr [RBP + -0xc4] MOV R14,RAX MOV RBX,qword ptr [RBP + -0x70] MOV R11,qword ptr [RBP + -0x68] MOV R10,qword ptr [RBP + -0x60] MOV RAX,qword ptr [RBP + -0x58] LEA RDI,[0x25b36f] MOV dword ptr [RSP],R15D MOV qword ptr [RSP + 0x8],R14 MOV qword ptr [RSP + 0x10],RBX MOV qword ptr [RSP + 0x18],R11 MOV qword ptr [RSP + 0x20],R10 MOV qword ptr [RSP + 0x28],RAX MOV AL,0x0 CALL 0x0012a070 CMP qword ptr [RBP + -0x58],0x2000 JZ 0x00190069 LEA RDI,[0x25b414] MOV ESI,0x2000 MOV AL,0x0 CALL 0x0012a070 LAB_00190069: MOV RAX,qword ptr [RBP + -0x80] MOV RSI,qword ptr [RBP + -0x50] MOV RCX,RAX SHR RCX,0x20 MOV EDX,ECX MOV ECX,EAX LEA RDI,[0x25b452] XOR EAX,EAX CALL 0x0012a070 MOV RAX,qword ptr FS:[0x28] MOV RCX,qword ptr [RBP + -0x20] CMP RAX,RCX JNZ 0x001900aa ADD RSP,0xf8 POP RBX POP R14 POP R15 POP RBP RET LAB_001900aa: CALL 0x0012a260
void dump_header_page(int8 param_1) { int8 uVar1; long in_FS_OFFSET; ulong local_c8; tm local_c0; ulong local_88; ulong local_80; int8 local_78; int8 local_70; int8 local_68; long local_60; int8 local_58; int8 local_50; int1 local_48 [32]; long local_28; local_28 = *(long *)(in_FS_OFFSET + 0x28); local_50 = param_1; translog_interpret_file_header(&local_88,param_1); local_c8 = local_80 / 1000000; localtime_r((time_t *)&local_c8,&local_c0); uVar1 = llstr(local_80,local_48); printf(" This can be header page:\n Timestamp: %04d.%02d.%02d %02d.%02d.%02d (%s)\n Aria log version: %lu\n Server version: %lu\n Server id %lu\n Page size %lu\n" ,(ulong)(local_c0.tm_year + 0x76c),(ulong)(local_c0.tm_mon + 1), (ulong)(uint)local_c0.tm_mday,(ulong)(uint)local_c0.tm_hour,(ulong)(uint)local_c0.tm_min, local_c0.tm_sec,uVar1,local_78,local_70,local_68,local_60); if (local_60 != 0x2000) { printf(" WARNING: page size is not equal compiled in one %lu!!!\n",0x2000); } printf(" File number %lu\n Max lsn: (%u,0x%x)\n",local_58,local_88 >> 0x20, local_88 & 0xffffffff); if (*(long *)(in_FS_OFFSET + 0x28) == local_28) { return; } /* WARNING: Subroutine does not return */ __stack_chk_fail(); }
31,898
LoadDirectoryFilesEx
csit-sgu[P]mit-game-2025_1/Libraries/raylib/src/rcore.c
FilePathList LoadDirectoryFilesEx(const char *basePath, const char *filter, bool scanSubdirs) { FilePathList files = { 0 }; files.capacity = MAX_FILEPATH_CAPACITY; files.paths = (char **)RL_CALLOC(files.capacity, sizeof(char *)); for (unsigned int i = 0; i < files.capacity; i++) files.paths[i] = (char *)RL_CALLOC(MAX_FILEPATH_LENGTH, sizeof(char)); // WARNING: basePath is always prepended to scanned paths if (scanSubdirs) ScanDirectoryFilesRecursively(basePath, &files, filter); else ScanDirectoryFiles(basePath, &files, filter); return files; }
O2
c
LoadDirectoryFilesEx: pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x18, %rsp movl %edx, %ebp movq %rsi, %rbx movq %rdi, %r14 andq $0x0, 0x8(%rsp) movl $0x2000, 0x8(%rsp) # imm = 0x2000 pushq $0x8 popq %rsi movl $0x2000, %edi # imm = 0x2000 callq 0x9320 movq %rax, %r15 movq %rax, 0x10(%rsp) xorl %r13d, %r13d pushq $0x1 popq %r12 cmpq $0x2000, %r13 # imm = 0x2000 je 0x63c2c movl $0x1000, %edi # imm = 0x1000 movq %r12, %rsi callq 0x9320 movq %rax, (%r15,%r13,8) incq %r13 jmp 0x63c0d leaq 0x8(%rsp), %rsi movq %r14, %rdi movq %rbx, %rdx testb %bpl, %bpl je 0x63c43 callq 0x63c61 jmp 0x63c48 callq 0x63aba movq 0x8(%rsp), %rax movq 0x10(%rsp), %rdx addq $0x18, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
LoadDirectoryFilesEx: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 18h mov ebp, edx mov rbx, rsi mov r14, rdi and [rsp+48h+var_40], 0 mov dword ptr [rsp+48h+var_40], 2000h push 8 pop rsi mov edi, 2000h call _calloc mov r15, rax mov [rsp+48h+var_38], rax xor r13d, r13d push 1 pop r12 loc_63C0D: cmp r13, 2000h jz short loc_63C2C mov edi, 1000h mov rsi, r12 call _calloc mov [r15+r13*8], rax inc r13 jmp short loc_63C0D loc_63C2C: lea rsi, [rsp+48h+var_40] mov rdi, r14 mov rdx, rbx test bpl, bpl jz short loc_63C43 call ScanDirectoryFilesRecursively jmp short loc_63C48 loc_63C43: call ScanDirectoryFiles loc_63C48: mov rax, [rsp+48h+var_40] mov rdx, [rsp+48h+var_38] add rsp, 18h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
long long LoadDirectoryFilesEx(const char *a1, long long a2, char a3) { long long v4; // r15 long long i; // r13 _QWORD v7[8]; // [rsp+8h] [rbp-40h] BYREF v7[0] = 0x2000LL; v4 = calloc(0x2000LL, 8LL); v7[1] = v4; for ( i = 0LL; i != 0x2000; ++i ) *(_QWORD *)(v4 + 8 * i) = calloc(4096LL, 1LL); if ( a3 ) ScanDirectoryFilesRecursively(a1, v7, a2); else ScanDirectoryFiles(a1, (long long)v7, a2); return v7[0]; }
LoadDirectoryFilesEx: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x18 MOV EBP,EDX MOV RBX,RSI MOV R14,RDI AND qword ptr [RSP + 0x8],0x0 MOV dword ptr [RSP + 0x8],0x2000 PUSH 0x8 POP RSI MOV EDI,0x2000 CALL 0x00109320 MOV R15,RAX MOV qword ptr [RSP + 0x10],RAX XOR R13D,R13D PUSH 0x1 POP R12 LAB_00163c0d: CMP R13,0x2000 JZ 0x00163c2c MOV EDI,0x1000 MOV RSI,R12 CALL 0x00109320 MOV qword ptr [R15 + R13*0x8],RAX INC R13 JMP 0x00163c0d LAB_00163c2c: LEA RSI,[RSP + 0x8] MOV RDI,R14 MOV RDX,RBX TEST BPL,BPL JZ 0x00163c43 CALL 0x00163c61 JMP 0x00163c48 LAB_00163c43: CALL 0x00163aba LAB_00163c48: MOV RAX,qword ptr [RSP + 0x8] MOV RDX,qword ptr [RSP + 0x10] ADD RSP,0x18 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
int1 [16] LoadDirectoryFilesEx(int8 param_1,int8 param_2,char param_3) { int1 auVar1 [16]; void *pvVar2; void *pvVar3; long lVar4; int4 local_40; int4 uStack_3c; void *local_38; uStack_3c = 0; local_40 = 0x2000; pvVar2 = calloc(0x2000,8); local_38 = pvVar2; for (lVar4 = 0; lVar4 != 0x2000; lVar4 = lVar4 + 1) { pvVar3 = calloc(0x1000,1); *(void **)((long)pvVar2 + lVar4 * 8) = pvVar3; } if (param_3 == '\0') { ScanDirectoryFiles(param_1,&local_40,param_2); } else { ScanDirectoryFilesRecursively(); } auVar1._4_4_ = uStack_3c; auVar1._0_4_ = local_40; auVar1._8_8_ = local_38; return auVar1; }
31,899
LoadDirectoryFilesEx
csit-sgu[P]mit-game-2025_1/Libraries/raylib/src/rcore.c
FilePathList LoadDirectoryFilesEx(const char *basePath, const char *filter, bool scanSubdirs) { FilePathList files = { 0 }; files.capacity = MAX_FILEPATH_CAPACITY; files.paths = (char **)RL_CALLOC(files.capacity, sizeof(char *)); for (unsigned int i = 0; i < files.capacity; i++) files.paths[i] = (char *)RL_CALLOC(MAX_FILEPATH_LENGTH, sizeof(char)); // WARNING: basePath is always prepended to scanned paths if (scanSubdirs) ScanDirectoryFilesRecursively(basePath, &files, filter); else ScanDirectoryFiles(basePath, &files, filter); return files; }
O3
c
LoadDirectoryFilesEx: pushq %rbp pushq %r15 pushq %r14 pushq %r12 pushq %rbx subq $0x10, %rsp movl %edx, %ebp movq %rsi, %rbx movq %rdi, %r14 movq $0x0, (%rsp) movl $0x2000, (%rsp) # imm = 0x2000 movl $0x2000, %edi # imm = 0x2000 movl $0x8, %esi callq 0xa330 movq %rax, %r15 movq %rax, 0x8(%rsp) xorl %r12d, %r12d movl $0x1000, %edi # imm = 0x1000 movl $0x1, %esi callq 0xa330 movq %rax, (%r15,%r12,8) incq %r12 cmpq $0x2000, %r12 # imm = 0x2000 jne 0x761cd movq %rsp, %rsi movq %r14, %rdi movq %rbx, %rdx testb %bpl, %bpl je 0x76201 callq 0x7621c jmp 0x76206 callq 0x76039 movq (%rsp), %rax movq 0x8(%rsp), %rdx addq $0x10, %rsp popq %rbx popq %r12 popq %r14 popq %r15 popq %rbp retq
LoadDirectoryFilesEx: push rbp push r15 push r14 push r12 push rbx sub rsp, 10h mov ebp, edx mov rbx, rsi mov r14, rdi mov [rsp+38h+var_38], 0 mov dword ptr [rsp+38h+var_38], 2000h mov edi, 2000h mov esi, 8 call _calloc mov r15, rax mov [rsp+38h+var_30], rax xor r12d, r12d loc_761CD: mov edi, 1000h mov esi, 1 call _calloc mov [r15+r12*8], rax inc r12 cmp r12, 2000h jnz short loc_761CD mov rsi, rsp mov rdi, r14 mov rdx, rbx test bpl, bpl jz short loc_76201 call ScanDirectoryFilesRecursively jmp short loc_76206 loc_76201: call ScanDirectoryFiles loc_76206: mov rax, [rsp+38h+var_38] mov rdx, [rsp+38h+var_30] add rsp, 10h pop rbx pop r12 pop r14 pop r15 pop rbp retn
long long LoadDirectoryFilesEx(const char *a1, long long a2, char a3) { long long v4; // r15 long long i; // r12 _QWORD v7[7]; // [rsp+0h] [rbp-38h] BYREF v7[0] = 0x2000LL; v4 = calloc(0x2000LL, 8LL); v7[1] = v4; for ( i = 0LL; i != 0x2000; ++i ) *(_QWORD *)(v4 + 8 * i) = calloc(4096LL, 1LL); if ( a3 ) ScanDirectoryFilesRecursively(a1, v7, a2); else ScanDirectoryFiles(a1, (long long)v7, a2); return v7[0]; }
LoadDirectoryFilesEx: PUSH RBP PUSH R15 PUSH R14 PUSH R12 PUSH RBX SUB RSP,0x10 MOV EBP,EDX MOV RBX,RSI MOV R14,RDI MOV qword ptr [RSP],0x0 MOV dword ptr [RSP],0x2000 MOV EDI,0x2000 MOV ESI,0x8 CALL 0x0010a330 MOV R15,RAX MOV qword ptr [RSP + 0x8],RAX XOR R12D,R12D LAB_001761cd: MOV EDI,0x1000 MOV ESI,0x1 CALL 0x0010a330 MOV qword ptr [R15 + R12*0x8],RAX INC R12 CMP R12,0x2000 JNZ 0x001761cd MOV RSI,RSP MOV RDI,R14 MOV RDX,RBX TEST BPL,BPL JZ 0x00176201 CALL 0x0017621c JMP 0x00176206 LAB_00176201: CALL 0x00176039 LAB_00176206: MOV RAX,qword ptr [RSP] MOV RDX,qword ptr [RSP + 0x8] ADD RSP,0x10 POP RBX POP R12 POP R14 POP R15 POP RBP RET
int1 [16] LoadDirectoryFilesEx(int8 param_1,int8 param_2,char param_3) { int1 auVar1 [16]; void *pvVar2; void *pvVar3; long lVar4; int4 local_38; int4 uStack_34; void *local_30; uStack_34 = 0; local_38 = 0x2000; pvVar2 = calloc(0x2000,8); lVar4 = 0; local_30 = pvVar2; do { pvVar3 = calloc(0x1000,1); *(void **)((long)pvVar2 + lVar4 * 8) = pvVar3; lVar4 = lVar4 + 1; } while (lVar4 != 0x2000); if (param_3 == '\0') { ScanDirectoryFiles(param_1,&local_38,param_2); } else { ScanDirectoryFilesRecursively(); } auVar1._4_4_ = uStack_34; auVar1._0_4_ = local_38; auVar1._8_8_ = local_30; return auVar1; }