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
27,500
nlohmann::json_abi_v3_11_3::ordered_map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>, std::less<void>, std::allocator<std::pair<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>>>::operator[](std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&)
monkey531[P]llama/common/json.hpp
T& operator[](const key_type& key) { return emplace(key, T{}).first->second; }
O3
cpp
nlohmann::json_abi_v3_11_3::ordered_map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>, std::less<void>, std::allocator<std::pair<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>>>::operator[](std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&): pushq %r15 pushq %r14 pushq %rbx subq $0x10, %rsp movq %rsi, %rbx movq %rdi, %r14 movq %rsp, %r15 movb $0x0, (%r15) movq $0x0, 0x8(%r15) movq %r15, %rdi movl $0x1, %esi callq 0x586c0 movq %r15, %rdi movl $0x1, %esi callq 0x586c0 movq %r14, %rdi movq %rbx, %rsi movq %r15, %rdx callq 0x5f25a movq %rax, %rbx addq $0x20, %rbx movq %rsp, %r14 movq %r14, %rdi xorl %esi, %esi callq 0x586c0 movq %r14, %rdi callq 0x5dbae movq %rbx, %rax addq $0x10, %rsp popq %rbx popq %r14 popq %r15 retq movq %rax, %rbx movq %rsp, %r14 movq %r14, %rdi xorl %esi, %esi callq 0x586c0 movq %r14, %rdi callq 0x5dbae movq %rbx, %rdi callq 0x1afc0 nop
_ZN8nlohmann16json_abi_v3_11_311ordered_mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEENS0_10basic_jsonIS1_St6vectorS7_blmdSaNS0_14adl_serializerES9_IhSaIhEEvEESt4lessIvESaISt4pairIKS7_SD_EEEixERSH_: push r15 push r14 push rbx sub rsp, 10h mov rbx, rsi mov r14, rdi mov r15, rsp mov byte ptr [r15], 0 mov qword ptr [r15+8], 0 mov rdi, r15 mov esi, 1 call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::assert_invariant(bool) mov rdi, r15 mov esi, 1 call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::assert_invariant(bool) mov rdi, r14 mov rsi, rbx mov rdx, r15 call _ZN8nlohmann16json_abi_v3_11_311ordered_mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEENS0_10basic_jsonIS1_St6vectorS7_blmdSaNS0_14adl_serializerES9_IhSaIhEEvEESt4lessIvESaISt4pairIKS7_SD_EEE7emplaceERSH_OSD_; nlohmann::json_abi_v3_11_3::ordered_map<std::string,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>,std::less<void>,std::allocator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>>::emplace(std::string const&,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>&&) mov rbx, rax add rbx, 20h ; ' ' mov r14, rsp 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 rax, rbx add rsp, 10h pop rbx pop r14 pop r15 retn mov rbx, rax mov r14, rsp mov rdi, r14 xor esi, esi call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::assert_invariant(bool) mov rdi, r14 call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE4dataD2Ev; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::data::~data() mov rdi, rbx call __Unwind_Resume
long long nlohmann::json_abi_v3_11_3::ordered_map<std::string,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,std::less<void>,std::allocator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>>>::operator[]( long long a1, long long a2) { long long v2; // rbx char v4[8]; // [rsp+0h] [rbp-28h] BYREF long long v5; // [rsp+8h] [rbp-20h] v4[0] = 0; 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(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>::assert_invariant(v4); v2 = nlohmann::json_abi_v3_11_3::ordered_map<std::string,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,std::less<void>,std::allocator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>>>::emplace( a1, a2, v4) + 32; 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(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>::data::~data(v4); return v2; }
operator[]: PUSH R15 PUSH R14 PUSH RBX SUB RSP,0x10 MOV RBX,RSI MOV R14,RDI MOV R15,RSP MOV byte ptr [R15],0x0 MOV qword ptr [R15 + 0x8],0x0 MOV RDI,R15 MOV ESI,0x1 CALL 0x001586c0 MOV RDI,R15 MOV ESI,0x1 CALL 0x001586c0 LAB_0015f1c6: MOV RDI,R14 MOV RSI,RBX MOV RDX,R15 CALL 0x0015f25a LAB_0015f1d4: MOV RBX,RAX ADD RBX,0x20 MOV R14,RSP MOV RDI,R14 XOR ESI,ESI CALL 0x001586c0 MOV RDI,R14 CALL 0x0015dbae MOV RAX,RBX ADD RSP,0x10 POP RBX POP R14 POP R15 RET
/* nlohmann::json_abi_v3_11_3::ordered_map<std::__cxx11::string, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char> >, void>, std::less<void>, std::allocator<std::pair<std::__cxx11::string const, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char> >, void> > > >::operator[](std::__cxx11::string const&) */ long __thiscall nlohmann::json_abi_v3_11_3:: ordered_map<std::__cxx11::string,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,std::less<void>,std::allocator<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>> ::operator[](ordered_map<std::__cxx11::string,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,std::less<void>,std::allocator<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>> *this,string *param_1) { long lVar1; bool bVar2; basic_json local_28 [8]; int8 local_20; local_28[0] = (basic_json)0x0; local_20 = 0; bVar2 = SUB81(local_28,0); basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> ::assert_invariant(bVar2); basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,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(bVar2); /* try { // try from 0015f1c6 to 0015f1d3 has its CatchHandler @ 0015f1fd */ lVar1 = emplace(this,param_1,local_28); basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,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(bVar2); basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,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_28); return lVar1 + 0x20; }
27,501
u64toa_length_loop
bluesky950520[P]quickjs/tests/test_conv.c
size_t u64toa_length_loop(char buf[minimum_length(21)], uint64_t n) { if (likely(n < 0x100000000)) return u32toa_length_loop(buf, n); uint32_t last = n % 10; n /= 10; uint64_t n10 = 1000000000; size_t len = 10; while (n >= n10) { n10 *= 10; len++; } char *end = buf + len; *end-- = '\0'; *end-- = (char)('0' + last); while (n >= 10) { uint32_t quo = n % 10; n /= 10; *end-- = (char)('0' + quo); } *end = (char)('0' + n); return len; }
O0
c
u64toa_length_loop: subq $0x48, %rsp movq %rdi, 0x38(%rsp) movq %rsi, 0x30(%rsp) movabsq $0x100000000, %rax # imm = 0x100000000 cmpq %rax, 0x30(%rsp) setb %al xorb $-0x1, %al xorb $-0x1, %al andb $0x1, %al movzbl %al, %eax cltq cmpq $0x0, %rax je 0x39bc movq 0x38(%rsp), %rdi movq 0x30(%rsp), %rax movl %eax, %esi callq 0x3830 movq %rax, 0x40(%rsp) jmp 0x3ac8 movq 0x30(%rsp), %rax movl $0xa, %ecx xorl %edx, %edx divq %rcx movl %edx, %eax movl %eax, 0x2c(%rsp) movq 0x30(%rsp), %rax movl $0xa, %ecx xorl %edx, %edx divq %rcx movq %rax, 0x30(%rsp) movq $0x3b9aca00, 0x20(%rsp) # imm = 0x3B9ACA00 movq $0xa, 0x18(%rsp) movq 0x30(%rsp), %rax cmpq 0x20(%rsp), %rax jb 0x3a1e imulq $0xa, 0x20(%rsp), %rax movq %rax, 0x20(%rsp) movq 0x18(%rsp), %rax addq $0x1, %rax movq %rax, 0x18(%rsp) jmp 0x39f7 movq 0x38(%rsp), %rax addq 0x18(%rsp), %rax movq %rax, 0x10(%rsp) movq 0x10(%rsp), %rax movq %rax, %rcx addq $-0x1, %rcx movq %rcx, 0x10(%rsp) movb $0x0, (%rax) movl 0x2c(%rsp), %eax addl $0x30, %eax movb %al, %cl movq 0x10(%rsp), %rax movq %rax, %rdx addq $-0x1, %rdx movq %rdx, 0x10(%rsp) movb %cl, (%rax) cmpq $0xa, 0x30(%rsp) jb 0x3aac movq 0x30(%rsp), %rax movl $0xa, %ecx xorl %edx, %edx divq %rcx movl %edx, %eax movl %eax, 0xc(%rsp) movq 0x30(%rsp), %rax movl $0xa, %ecx xorl %edx, %edx divq %rcx movq %rax, 0x30(%rsp) movl 0xc(%rsp), %eax addl $0x30, %eax movb %al, %cl movq 0x10(%rsp), %rax movq %rax, %rdx addq $-0x1, %rdx movq %rdx, 0x10(%rsp) movb %cl, (%rax) jmp 0x3a5d movq 0x30(%rsp), %rax addq $0x30, %rax movb %al, %cl movq 0x10(%rsp), %rax movb %cl, (%rax) movq 0x18(%rsp), %rax movq %rax, 0x40(%rsp) movq 0x40(%rsp), %rax addq $0x48, %rsp retq nopw %cs:(%rax,%rax)
u64toa_length_loop: sub rsp, 48h mov [rsp+48h+var_10], rdi mov [rsp+48h+var_18], rsi mov rax, 100000000h cmp [rsp+48h+var_18], rax setb al xor al, 0FFh xor al, 0FFh and al, 1 movzx eax, al cdqe cmp rax, 0 jz short loc_39BC mov rdi, [rsp+48h+var_10] mov rax, [rsp+48h+var_18] mov esi, eax call u32toa_length_loop mov [rsp+48h+var_8], rax jmp loc_3AC8 loc_39BC: mov rax, [rsp+48h+var_18] mov ecx, 0Ah xor edx, edx div rcx mov eax, edx mov [rsp+48h+var_1C], eax mov rax, [rsp+48h+var_18] mov ecx, 0Ah xor edx, edx div rcx mov [rsp+48h+var_18], rax mov [rsp+48h+var_28], 3B9ACA00h mov [rsp+48h+var_30], 0Ah loc_39F7: mov rax, [rsp+48h+var_18] cmp rax, [rsp+48h+var_28] jb short loc_3A1E imul rax, [rsp+48h+var_28], 0Ah mov [rsp+48h+var_28], rax mov rax, [rsp+48h+var_30] add rax, 1 mov [rsp+48h+var_30], rax jmp short loc_39F7 loc_3A1E: mov rax, [rsp+48h+var_10] add rax, [rsp+48h+var_30] mov [rsp+48h+var_38], rax mov rax, [rsp+48h+var_38] mov rcx, rax add rcx, 0FFFFFFFFFFFFFFFFh mov [rsp+48h+var_38], rcx mov byte ptr [rax], 0 mov eax, [rsp+48h+var_1C] add eax, 30h ; '0' mov cl, al mov rax, [rsp+48h+var_38] mov rdx, rax add rdx, 0FFFFFFFFFFFFFFFFh mov [rsp+48h+var_38], rdx mov [rax], cl loc_3A5D: cmp [rsp+48h+var_18], 0Ah jb short loc_3AAC mov rax, [rsp+48h+var_18] mov ecx, 0Ah xor edx, edx div rcx mov eax, edx mov [rsp+48h+var_3C], eax mov rax, [rsp+48h+var_18] mov ecx, 0Ah xor edx, edx div rcx mov [rsp+48h+var_18], rax mov eax, [rsp+48h+var_3C] add eax, 30h ; '0' mov cl, al mov rax, [rsp+48h+var_38] mov rdx, rax add rdx, 0FFFFFFFFFFFFFFFFh mov [rsp+48h+var_38], rdx mov [rax], cl jmp short loc_3A5D loc_3AAC: mov rax, [rsp+48h+var_18] add rax, 30h ; '0' mov cl, al mov rax, [rsp+48h+var_38] mov [rax], cl mov rax, [rsp+48h+var_30] mov [rsp+48h+var_8], rax loc_3AC8: mov rax, [rsp+48h+var_8] add rsp, 48h retn
long long u64toa_length_loop(_BYTE *a1, unsigned long long a2) { _BYTE *v2; // rax int v4; // [rsp+Ch] [rbp-3Ch] _BYTE *v5; // [rsp+10h] [rbp-38h] long long v6; // [rsp+18h] [rbp-30h] unsigned long long v7; // [rsp+20h] [rbp-28h] unsigned long long v8; // [rsp+30h] [rbp-18h] if ( a2 < 0x100000000LL ) return u32toa_length_loop(a1, a2); v8 = a2 / 0xA; v7 = 1000000000LL; v6 = 10LL; while ( v8 >= v7 ) { v7 *= 10LL; ++v6; } a1[v6] = 0; v5 = &a1[v6 - 2]; a1[v6 - 1] = a2 % 0xA + 48; while ( v8 >= 0xA ) { v4 = v8 % 0xA; v8 /= 0xAuLL; v2 = v5--; *v2 = v4 + 48; } *v5 = v8 + 48; return v6; }
u64toa_length_loop: SUB RSP,0x48 MOV qword ptr [RSP + 0x38],RDI MOV qword ptr [RSP + 0x30],RSI MOV RAX,0x100000000 CMP qword ptr [RSP + 0x30],RAX SETC AL XOR AL,0xff XOR AL,0xff AND AL,0x1 MOVZX EAX,AL CDQE CMP RAX,0x0 JZ 0x001039bc MOV RDI,qword ptr [RSP + 0x38] MOV RAX,qword ptr [RSP + 0x30] MOV ESI,EAX CALL 0x00103830 MOV qword ptr [RSP + 0x40],RAX JMP 0x00103ac8 LAB_001039bc: MOV RAX,qword ptr [RSP + 0x30] MOV ECX,0xa XOR EDX,EDX DIV RCX MOV EAX,EDX MOV dword ptr [RSP + 0x2c],EAX MOV RAX,qword ptr [RSP + 0x30] MOV ECX,0xa XOR EDX,EDX DIV RCX MOV qword ptr [RSP + 0x30],RAX MOV qword ptr [RSP + 0x20],0x3b9aca00 MOV qword ptr [RSP + 0x18],0xa LAB_001039f7: MOV RAX,qword ptr [RSP + 0x30] CMP RAX,qword ptr [RSP + 0x20] JC 0x00103a1e IMUL RAX,qword ptr [RSP + 0x20],0xa MOV qword ptr [RSP + 0x20],RAX MOV RAX,qword ptr [RSP + 0x18] ADD RAX,0x1 MOV qword ptr [RSP + 0x18],RAX JMP 0x001039f7 LAB_00103a1e: MOV RAX,qword ptr [RSP + 0x38] ADD RAX,qword ptr [RSP + 0x18] MOV qword ptr [RSP + 0x10],RAX MOV RAX,qword ptr [RSP + 0x10] MOV RCX,RAX ADD RCX,-0x1 MOV qword ptr [RSP + 0x10],RCX MOV byte ptr [RAX],0x0 MOV EAX,dword ptr [RSP + 0x2c] ADD EAX,0x30 MOV CL,AL MOV RAX,qword ptr [RSP + 0x10] MOV RDX,RAX ADD RDX,-0x1 MOV qword ptr [RSP + 0x10],RDX MOV byte ptr [RAX],CL LAB_00103a5d: CMP qword ptr [RSP + 0x30],0xa JC 0x00103aac MOV RAX,qword ptr [RSP + 0x30] MOV ECX,0xa XOR EDX,EDX DIV RCX MOV EAX,EDX MOV dword ptr [RSP + 0xc],EAX MOV RAX,qword ptr [RSP + 0x30] MOV ECX,0xa XOR EDX,EDX DIV RCX MOV qword ptr [RSP + 0x30],RAX MOV EAX,dword ptr [RSP + 0xc] ADD EAX,0x30 MOV CL,AL MOV RAX,qword ptr [RSP + 0x10] MOV RDX,RAX ADD RDX,-0x1 MOV qword ptr [RSP + 0x10],RDX MOV byte ptr [RAX],CL JMP 0x00103a5d LAB_00103aac: MOV RAX,qword ptr [RSP + 0x30] ADD RAX,0x30 MOV CL,AL MOV RAX,qword ptr [RSP + 0x10] MOV byte ptr [RAX],CL MOV RAX,qword ptr [RSP + 0x18] MOV qword ptr [RSP + 0x40],RAX LAB_00103ac8: MOV RAX,qword ptr [RSP + 0x40] ADD RSP,0x48 RET
long u64toa_length_loop(long param_1,ulong param_2) { int1 auVar1 [16]; int1 auVar2 [16]; int1 *puVar3; char *local_38; long local_30; ulong local_28; ulong local_18; long local_8; if (param_2 < 0x100000000) { local_8 = u32toa_length_loop(param_1,param_2 & 0xffffffff); } else { auVar1._8_8_ = 0; auVar1._0_8_ = param_2; local_18 = param_2 / 10; local_30 = 10; for (local_28 = 1000000000; local_28 <= local_18; local_28 = local_28 * 10) { local_30 = local_30 + 1; } puVar3 = (int1 *)(param_1 + local_30); *puVar3 = 0; puVar3[-1] = SUB161(auVar1 % ZEXT816(10),0) + '0'; local_38 = puVar3 + -2; while (9 < local_18) { auVar2._8_8_ = 0; auVar2._0_8_ = local_18; local_18 = local_18 / 10; *local_38 = SUB161(auVar2 % ZEXT816(10),0) + '0'; local_38 = local_38 + -1; } *local_38 = (char)local_18 + '0'; local_8 = local_30; } return local_8; }
27,502
u64toa_length_loop
bluesky950520[P]quickjs/tests/test_conv.c
size_t u64toa_length_loop(char buf[minimum_length(21)], uint64_t n) { if (likely(n < 0x100000000)) return u32toa_length_loop(buf, n); uint32_t last = n % 10; n /= 10; uint64_t n10 = 1000000000; size_t len = 10; while (n >= n10) { n10 *= 10; len++; } char *end = buf + len; *end-- = '\0'; *end-- = (char)('0' + last); while (n >= 10) { uint32_t quo = n % 10; n /= 10; *end-- = (char)('0' + quo); } *end = (char)('0' + n); return len; }
O1
c
u64toa_length_loop: movq %rdi, %rax movq %rsi, %rcx shrq $0x20, %rcx jne 0x2f38 movq %rax, %rdi jmp 0x2e85 pushq %rbx subq $0x10, %rsp leaq 0x8(%rsp), %rbx movq %rsi, %rdi movq %rax, %rsi movq %rbx, %rdx callq 0x245b movq (%rbx), %rax addq $0x10, %rsp popq %rbx retq
u64toa_length_loop: mov rax, rdi mov rcx, rsi shr rcx, 20h jnz short loc_2F38 mov rdi, rax jmp u32toa_length_loop loc_2F38: push rbx sub rsp, 10h lea rbx, [rsp+18h+var_10] mov rdi, rsi mov rsi, rax mov rdx, rbx call u64toa_length_loop_cold_1 mov rax, [rbx] add rsp, 10h pop rbx retn
long long u64toa_length_loop(_BYTE *a1, unsigned long long a2) { long long v3; // [rsp+0h] [rbp-10h] BYREF if ( !HIDWORD(a2) ) return u32toa_length_loop(a1, a2); u64toa_length_loop_cold_1(a2, (long long)a1, &v3); return v3; }
u64toa_length_loop: MOV RAX,RDI MOV RCX,RSI SHR RCX,0x20 JNZ 0x00102f38 MOV RDI,RAX JMP 0x00102e85 LAB_00102f38: PUSH RBX SUB RSP,0x10 LEA RBX,[RSP + 0x8] MOV RDI,RSI MOV RSI,RAX MOV RDX,RBX CALL 0x0010245b MOV RAX,qword ptr [RBX] ADD RSP,0x10 POP RBX RET
int8 u64toa_length_loop(int8 param_1,ulong param_2) { int8 uVar1; int8 local_10; if (param_2 >> 0x20 == 0) { uVar1 = u32toa_length_loop(param_1); return uVar1; } u64toa_length_loop_cold_1(param_2,param_1,&local_10); return local_10; }
27,503
Config::GetActiveLayerForConfig(Config::Location const&)
Dolphin-anty/Source/Core/Common/Config/Config.cpp
LayerType GetActiveLayerForConfig(const Location& config) { ReadLock lock(s_layers_rw_lock); for (auto layer : SEARCH_ORDER) { const auto it = s_layers.find(layer); if (it != s_layers.end()) { if (it->second->Exists(config)) return layer; } } // If config is not present in any layer, base layer is considered active. return LayerType::Base; }
O3
cpp
Config::GetActiveLayerForConfig(Config::Location const&): pushq %rbp pushq %r15 pushq %r14 pushq %r12 pushq %rbx movq %rdi, %rbx leaq 0x3b6d7(%rip), %rdi # 0x539f0 callq 0xdacc xorl %r14d, %r14d movq 0x3b690(%rip), %rax # 0x539b8 leaq 0x25829(%rip), %r15 # 0x3db58 leaq 0x3b67a(%rip), %r12 # 0x539b0 testq %rax, %rax je 0x1837f movl (%r14,%r15), %ebp movq %rax, %rdx movq %r12, %rcx xorl %esi, %esi cmpl %ebp, 0x20(%rdx) setl %sil cmovgeq %rdx, %rcx movq 0x10(%rdx,%rsi,8), %rdx testq %rdx, %rdx jne 0x18345 cmpq %r12, %rcx je 0x18381 cmpl 0x20(%rcx), %ebp jl 0x18381 movq 0x28(%rcx), %rdi movq %rbx, %rsi callq 0x197f8 testb %al, %al jne 0x1838d movq 0x3b63b(%rip), %rax # 0x539b8 jmp 0x18381 xorl %eax, %eax addq $0x4, %r14 cmpq $0x1c, %r14 jne 0x18336 xorl %ebp, %ebp leaq 0x3b65c(%rip), %rdi # 0x539f0 callq 0x7430 movl %ebp, %eax popq %rbx popq %r12 popq %r14 popq %r15 popq %rbp retq
_ZN6Config23GetActiveLayerForConfigERKNS_8LocationE: push rbp push r15 push r14 push r12 push rbx mov rbx, rdi lea rdi, _ZN6ConfigL16s_layers_rw_lockE; this call _ZNSt22__shared_mutex_pthread11lock_sharedEv; std::__shared_mutex_pthread::lock_shared(void) xor r14d, r14d mov rax, cs:qword_539B8 lea r15, _ZN6ConfigL12SEARCH_ORDERE; Config::SEARCH_ORDER lea r12, dword_539B0 loc_18336: test rax, rax jz short loc_1837F mov ebp, [r14+r15] mov rdx, rax mov rcx, r12 loc_18345: xor esi, esi cmp [rdx+20h], ebp setl sil cmovge rcx, rdx mov rdx, [rdx+rsi*8+10h] test rdx, rdx jnz short loc_18345 cmp rcx, r12 jz short loc_18381 cmp ebp, [rcx+20h] jl short loc_18381 mov rdi, [rcx+28h] mov rsi, rbx call _ZNK6Config5Layer6ExistsERKNS_8LocationE; Config::Layer::Exists(Config::Location const&) test al, al jnz short loc_1838D mov rax, cs:qword_539B8 jmp short loc_18381 loc_1837F: xor eax, eax loc_18381: add r14, 4 cmp r14, 1Ch jnz short loc_18336 xor ebp, ebp loc_1838D: lea rdi, _ZN6ConfigL16s_layers_rw_lockE; Config::s_layers_rw_lock call _pthread_rwlock_unlock mov eax, ebp pop rbx pop r12 pop r14 pop r15 pop rbp retn
long long Config::GetActiveLayerForConfig(long long a1) { long long v1; // r14 long long v2; // rax int v3; // ebp int *v4; // rdx int *v5; // rcx std::__shared_mutex_pthread::lock_shared((std::__shared_mutex_pthread *)&Config::s_layers_rw_lock); v1 = 0LL; v2 = qword_539B8; do { if ( v2 ) { v3 = *(_DWORD *)((char *)&Config::SEARCH_ORDER + v1); v4 = (int *)v2; v5 = &dword_539B0; do { if ( v4[8] >= v3 ) v5 = v4; v4 = *(int **)&v4[2 * (v4[8] < v3) + 4]; } while ( v4 ); if ( v5 != &dword_539B0 && v3 >= v5[8] ) { if ( (unsigned __int8)Config::Layer::Exists(*((_QWORD *)v5 + 5), a1) ) goto LABEL_14; v2 = qword_539B8; } } else { v2 = 0LL; } v1 += 4LL; } while ( v1 != 28 ); v3 = 0; LABEL_14: pthread_rwlock_unlock(&Config::s_layers_rw_lock); return (unsigned int)v3; }
GetActiveLayerForConfig: PUSH RBP PUSH R15 PUSH R14 PUSH R12 PUSH RBX MOV RBX,RDI LEA RDI,[0x1539f0] CALL 0x0010dacc XOR R14D,R14D MOV RAX,qword ptr [0x001539b8] LEA R15,[0x13db58] LEA R12,[0x1539b0] LAB_00118336: TEST RAX,RAX JZ 0x0011837f MOV EBP,dword ptr [R14 + R15*0x1] MOV RDX,RAX MOV RCX,R12 LAB_00118345: XOR ESI,ESI CMP dword ptr [RDX + 0x20],EBP SETL SIL CMOVGE RCX,RDX MOV RDX,qword ptr [RDX + RSI*0x8 + 0x10] TEST RDX,RDX JNZ 0x00118345 CMP RCX,R12 JZ 0x00118381 CMP EBP,dword ptr [RCX + 0x20] JL 0x00118381 MOV RDI,qword ptr [RCX + 0x28] MOV RSI,RBX CALL 0x001197f8 TEST AL,AL JNZ 0x0011838d MOV RAX,qword ptr [0x001539b8] JMP 0x00118381 LAB_0011837f: XOR EAX,EAX LAB_00118381: ADD R14,0x4 CMP R14,0x1c JNZ 0x00118336 XOR EBP,EBP LAB_0011838d: LEA RDI,[0x1539f0] CALL 0x00107430 MOV EAX,EBP POP RBX POP R12 POP R14 POP R15 POP RBP RET
/* Config::GetActiveLayerForConfig(Config::Location const&) */ int Config::GetActiveLayerForConfig(Location *param_1) { char cVar1; long lVar2; long lVar3; long lVar4; int iVar5; long lVar6; std::__shared_mutex_pthread::lock_shared((__shared_mutex_pthread *)s_layers_rw_lock); lVar6 = 0; lVar2 = s_layers._16_8_; do { if (lVar2 == 0) { lVar2 = 0; } else { iVar5 = *(int *)((long)&SEARCH_ORDER + lVar6); lVar3 = 0x1539b0; lVar4 = lVar2; do { if (iVar5 <= *(int *)(lVar4 + 0x20)) { lVar3 = lVar4; } lVar4 = *(long *)(lVar4 + 0x10 + (ulong)(*(int *)(lVar4 + 0x20) < iVar5) * 8); } while (lVar4 != 0); if (((lVar3 != 0x1539b0) && (*(int *)(lVar3 + 0x20) <= iVar5)) && (cVar1 = Layer::Exists(*(Layer **)(lVar3 + 0x28),param_1), lVar2 = s_layers._16_8_, cVar1 != '\0')) goto LAB_0011838d; } lVar6 = lVar6 + 4; } while (lVar6 != 0x1c); iVar5 = 0; LAB_0011838d: pthread_rwlock_unlock((pthread_rwlock_t *)s_layers_rw_lock); return iVar5; }
27,504
R3D_GetFogColor
r3d/src/r3d_environment.c
Color R3D_GetFogColor(void) { Color color = { 0 }; color.r = (unsigned char)(R3D.env.fogColor.x * 255); color.g = (unsigned char)(R3D.env.fogColor.y * 255); color.b = (unsigned char)(R3D.env.fogColor.z * 255); color.a = 255; return color; }
O3
c
R3D_GetFogColor: pushq %rbp movq %rsp, %rbp leaq 0xf3a6c(%rip), %rcx # 0x1b1bc0 movss 0x24ee0(%rip), %xmm0 # 0xe303c movss 0x1500(%rcx), %xmm1 mulss %xmm0, %xmm1 cvttss2si %xmm1, %eax movss 0x1504(%rcx), %xmm1 mulss %xmm0, %xmm1 cvttss2si %xmm1, %edx mulss 0x1508(%rcx), %xmm0 cvttss2si %xmm0, %ecx shll $0x10, %ecx movl $0xff, %esi andl %esi, %edx shll $0x8, %edx orl %ecx, %edx andl %esi, %eax orl %edx, %eax orl $0xff000000, %eax # imm = 0xFF000000 popq %rbp retq
R3D_GetFogColor: push rbp mov rbp, rsp lea rcx, R3D movss xmm0, cs:dword_E303C movss xmm1, dword ptr [rcx+1500h] mulss xmm1, xmm0 cvttss2si eax, xmm1 movss xmm1, dword ptr [rcx+1504h] mulss xmm1, xmm0 cvttss2si edx, xmm1 mulss xmm0, dword ptr [rcx+1508h] cvttss2si ecx, xmm0 shl ecx, 10h mov esi, 0FFh and edx, esi shl edx, 8 or edx, ecx and eax, esi or eax, edx or eax, 0FF000000h pop rbp retn
long long R3D_GetFogColor() { return ((int)(float)(255.0 * *((float *)&R3D + 1346)) << 16) | ((unsigned __int8)(int)(float)(*((float *)&R3D + 1345) * 255.0) << 8) | (unsigned __int8)(int)(float)(*((float *)&R3D + 1344) * 255.0) | 0xFF000000; }
R3D_GetFogColor: PUSH RBP MOV RBP,RSP LEA RCX,[0x2b1bc0] MOVSS XMM0,dword ptr [0x001e303c] MOVSS XMM1,dword ptr [RCX + 0x1500] MULSS XMM1,XMM0 CVTTSS2SI EAX,XMM1 MOVSS XMM1,dword ptr [RCX + 0x1504] MULSS XMM1,XMM0 CVTTSS2SI EDX,XMM1 MULSS XMM0,dword ptr [RCX + 0x1508] CVTTSS2SI ECX,XMM0 SHL ECX,0x10 MOV ESI,0xff AND EDX,ESI SHL EDX,0x8 OR EDX,ECX AND EAX,ESI OR EAX,EDX OR EAX,0xff000000 POP RBP RET
uint R3D_GetFogColor(void) { return (int)(DAT_002b30c0 * DAT_001e303c) & 0xffU | ((int)(DAT_002b30c4 * DAT_001e303c) & 0xffU) << 8 | (int)(DAT_001e303c * DAT_002b30c8) << 0x10 | 0xff000000; }
27,505
common_chat_format_name[abi:cxx11](common_chat_format)
llama.cpp/common/chat.cpp
std::string common_chat_format_name(common_chat_format format) { switch (format) { case COMMON_CHAT_FORMAT_CONTENT_ONLY: return "Content-only"; case COMMON_CHAT_FORMAT_GENERIC: return "Generic"; case COMMON_CHAT_FORMAT_MISTRAL_NEMO: return "Mistral Nemo"; case COMMON_CHAT_FORMAT_LLAMA_3_X: return "Llama 3.x"; case COMMON_CHAT_FORMAT_LLAMA_3_X_WITH_BUILTIN_TOOLS: return "Llama 3.x with builtin tools"; case COMMON_CHAT_FORMAT_DEEPSEEK_R1: return "DeepSeek R1"; case COMMON_CHAT_FORMAT_DEEPSEEK_R1_EXTRACT_REASONING: return "DeepSeek R1 (extract reasoning)"; case COMMON_CHAT_FORMAT_FIREFUNCTION_V2: return "FireFunction v2"; case COMMON_CHAT_FORMAT_FUNCTIONARY_V3_2: return "Functionary v3.2"; case COMMON_CHAT_FORMAT_FUNCTIONARY_V3_1_LLAMA_3_1: return "Functionary v3.1 Llama 3.1"; case COMMON_CHAT_FORMAT_HERMES_2_PRO: return "Hermes 2 Pro"; case COMMON_CHAT_FORMAT_HERMES_2_PRO_EXTRACT_REASONING: return "Hermes 2 Pro (extract reasoning)"; case COMMON_CHAT_FORMAT_COMMAND_R7B: return "Command R7B"; case COMMON_CHAT_FORMAT_COMMAND_R7B_EXTRACT_REASONING: return "Command R7B (extract reasoning)"; default: throw std::runtime_error("Unknown chat format"); } }
O3
cpp
common_chat_format_name[abi:cxx11](common_chat_format): pushq %r14 pushq %rbx pushq %rax cmpl $0xd, %esi ja 0x955c3 movq %rdi, %rbx movl %esi, %eax leaq 0x870b1(%rip), %rcx # 0x11c500 movslq (%rcx,%rax,4), %rax addq %rcx, %rax jmpq *%rax leaq 0x10(%rbx), %rax movq %rax, (%rbx) leaq 0x88983(%rip), %rsi # 0x11dde9 leaq 0x88988(%rip), %rdx # 0x11ddf5 jmp 0x955b0 leaq 0x10(%rbx), %rax movq %rax, (%rbx) leaq 0x88a27(%rip), %rsi # 0x11dea7 leaq 0x88a40(%rip), %rdx # 0x11dec7 jmp 0x955b0 leaq 0x10(%rbx), %rax movq %rax, (%rbx) leaq 0x8897b(%rip), %rsi # 0x11de15 leaq 0x88990(%rip), %rdx # 0x11de31 jmp 0x955b0 leaq 0x10(%rbx), %rax movq %rax, (%rbx) leaq 0x88a14(%rip), %rsi # 0x11dec8 leaq 0x88a18(%rip), %rdx # 0x11ded3 jmp 0x955b0 leaq 0x10(%rbx), %rax movq %rax, (%rbx) leaq 0x889b1(%rip), %rsi # 0x11de7f leaq 0x889c4(%rip), %rdx # 0x11de99 jmp 0x955b0 leaq 0x10(%rbx), %rax movq %rax, (%rbx) leaq 0x88916(%rip), %rsi # 0x11ddfe leaq 0x8891b(%rip), %rdx # 0x11de0a jmp 0x955b0 leaq 0x10(%rbx), %rax movq %rax, (%rbx) leaq 0x88909(%rip), %rsi # 0x11de0b leaq 0x8890b(%rip), %rdx # 0x11de14 jmp 0x955b0 leaq 0x10(%rbx), %rax movq %rax, (%rbx) leaq 0x88942(%rip), %rsi # 0x11de5e leaq 0x8894a(%rip), %rdx # 0x11de6d jmp 0x955b0 leaq 0x10(%rbx), %rax movq %rax, (%rbx) leaq 0x888c0(%rip), %rsi # 0x11ddf6 leaq 0x888c0(%rip), %rdx # 0x11ddfd jmp 0x955b0 leaq 0x10(%rbx), %rax movq %rax, (%rbx) leaq 0x888e5(%rip), %rsi # 0x11de32 leaq 0x888e9(%rip), %rdx # 0x11de3d jmp 0x955b0 leaq 0x10(%rbx), %rax movq %rax, (%rbx) leaq 0x88970(%rip), %rsi # 0x11ded4 leaq 0x88988(%rip), %rdx # 0x11def3 jmp 0x955b0 leaq 0x10(%rbx), %rax movq %rax, (%rbx) leaq 0x888c3(%rip), %rsi # 0x11de3e leaq 0x888db(%rip), %rdx # 0x11de5d jmp 0x955b0 leaq 0x10(%rbx), %rax movq %rax, (%rbx) leaq 0x88908(%rip), %rsi # 0x11de9a leaq 0x8890d(%rip), %rdx # 0x11dea6 jmp 0x955b0 leaq 0x10(%rbx), %rax movq %rax, (%rbx) leaq 0x888c5(%rip), %rsi # 0x11de6e leaq 0x888ce(%rip), %rdx # 0x11de7e movq %rbx, %rdi callq 0x27994 movq %rbx, %rax addq $0x8, %rsp popq %rbx popq %r14 retq movl $0x10, %edi callq 0x20610 movq %rax, %rbx leaq 0x8891d(%rip), %rsi # 0x11def4 movq %rax, %rdi callq 0x203f0 movq 0xcb9da(%rip), %rsi # 0x160fc0 movq 0xcb993(%rip), %rdx # 0x160f80 movq %rbx, %rdi callq 0x20a10 movq %rax, %r14 movq %rbx, %rdi callq 0x20e90 movq %r14, %rdi callq 0x20ab0
_Z23common_chat_format_nameB5cxx1118common_chat_format: push r14 push rbx push rax cmp esi, 0Dh; switch 14 cases ja def_95456; jumptable 0000000000095456 default case mov rbx, rdi mov eax, esi lea rcx, jpt_95456 movsxd rax, ds:(jpt_95456 - 11C500h)[rcx+rax*4] add rax, rcx jmp rax; switch jump loc_95458: lea rax, [rbx+10h]; jumptable 0000000000095456 case 0 mov [rbx], rax lea rsi, aContentOnly; "Content-only" lea rdx, aContentOnly+0Ch; "" jmp loc_955B0 loc_95472: lea rax, [rbx+10h]; jumptable 0000000000095456 case 11 mov [rbx], rax lea rsi, aHermes2ProExtr; "Hermes 2 Pro (extract reasoning)" lea rdx, aHermes2ProExtr+20h; "" jmp loc_955B0 loc_9548C: lea rax, [rbx+10h]; jumptable 0000000000095456 case 4 mov [rbx], rax lea rsi, aLlama3XWithBui; "Llama 3.x with builtin tools" lea rdx, aLlama3XWithBui+1Ch; "" jmp loc_955B0 loc_954A6: lea rax, [rbx+10h]; jumptable 0000000000095456 case 12 mov [rbx], rax lea rsi, aCommandR7b; "Command R7B" lea rdx, aCommandR7b+0Bh; "" jmp loc_955B0 loc_954C0: lea rax, [rbx+10h]; jumptable 0000000000095456 case 9 mov [rbx], rax lea rsi, aFunctionaryV31; "Functionary v3.1 Llama 3.1" lea rdx, aFunctionaryV31+1Ah; "" jmp loc_955B0 loc_954DA: lea rax, [rbx+10h]; jumptable 0000000000095456 case 2 mov [rbx], rax lea rsi, aMistralNemo; "Mistral Nemo" lea rdx, aMistralNemo+0Ch; "" jmp loc_955B0 loc_954F4: lea rax, [rbx+10h]; jumptable 0000000000095456 case 3 mov [rbx], rax lea rsi, aLlama3X; "Llama 3.x" lea rdx, aLlama3X+9; "" jmp loc_955B0 loc_9550E: lea rax, [rbx+10h]; jumptable 0000000000095456 case 7 mov [rbx], rax lea rsi, aFirefunctionV2; "FireFunction v2" lea rdx, aFirefunctionV2+0Fh; "" jmp loc_955B0 loc_95528: lea rax, [rbx+10h]; jumptable 0000000000095456 case 1 mov [rbx], rax lea rsi, aGeneric; "Generic" lea rdx, aGeneric+7; "" jmp short loc_955B0 loc_9553F: lea rax, [rbx+10h]; jumptable 0000000000095456 case 5 mov [rbx], rax lea rsi, aDeepseekR1; "DeepSeek R1" lea rdx, aDeepseekR1+0Bh; "" jmp short loc_955B0 loc_95556: lea rax, [rbx+10h]; jumptable 0000000000095456 case 13 mov [rbx], rax lea rsi, aCommandR7bExtr; "Command R7B (extract reasoning)" lea rdx, aCommandR7bExtr+1Fh; "" jmp short loc_955B0 loc_9556D: lea rax, [rbx+10h]; jumptable 0000000000095456 case 6 mov [rbx], rax lea rsi, aDeepseekR1Extr; "DeepSeek R1 (extract reasoning)" lea rdx, aDeepseekR1Extr+1Fh; "" jmp short loc_955B0 loc_95584: lea rax, [rbx+10h]; jumptable 0000000000095456 case 10 mov [rbx], rax lea rsi, aHermes2Pro; "Hermes 2 Pro" lea rdx, aHermes2Pro+0Ch; "" jmp short loc_955B0 loc_9559B: lea rax, [rbx+10h]; jumptable 0000000000095456 case 8 mov [rbx], rax lea rsi, aFunctionaryV32; "Functionary v3.2" lea rdx, aFunctionaryV32+10h; "" loc_955B0: 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 def_95456: mov edi, 10h; jumptable 0000000000095456 default case call ___cxa_allocate_exception mov rbx, rax lea rsi, aUnknownChatFor; "Unknown chat format" mov rdi, rax; this call __ZNSt13runtime_errorC1EPKc; std::runtime_error::runtime_error(char const*) mov rsi, cs:_ZTISt13runtime_error_ptr; lptinfo mov rdx, cs:_ZNSt13runtime_errorD1Ev_ptr; void (*)(void *) mov rdi, rbx; void * call ___cxa_throw mov r14, rax mov rdi, rbx; void * call ___cxa_free_exception mov rdi, r14 call __Unwind_Resume
_QWORD * common_chat_format_name[abi:cxx11](_QWORD *a1, int a2) { char *v2; // rsi char *v3; // rdx std::runtime_error *exception; // rbx switch ( a2 ) { case 0: *a1 = a1 + 2; v2 = "Content-only"; v3 = ""; break; case 1: *a1 = a1 + 2; v2 = "Generic"; v3 = ""; break; case 2: *a1 = a1 + 2; v2 = "Mistral Nemo"; v3 = ""; break; case 3: *a1 = a1 + 2; v2 = "Llama 3.x"; v3 = ""; break; case 4: *a1 = a1 + 2; v2 = "Llama 3.x with builtin tools"; v3 = ""; break; case 5: *a1 = a1 + 2; v2 = "DeepSeek R1"; v3 = ""; break; case 6: *a1 = a1 + 2; v2 = "DeepSeek R1 (extract reasoning)"; v3 = ""; break; case 7: *a1 = a1 + 2; v2 = "FireFunction v2"; v3 = ""; break; case 8: *a1 = a1 + 2; v2 = "Functionary v3.2"; v3 = ""; break; case 9: *a1 = a1 + 2; v2 = "Functionary v3.1 Llama 3.1"; v3 = ""; break; case 10: *a1 = a1 + 2; v2 = "Hermes 2 Pro"; v3 = ""; break; case 11: *a1 = a1 + 2; v2 = "Hermes 2 Pro (extract reasoning)"; v3 = ""; break; case 12: *a1 = a1 + 2; v2 = "Command R7B"; v3 = ""; break; case 13: *a1 = a1 + 2; v2 = "Command R7B (extract reasoning)"; v3 = ""; break; default: exception = (std::runtime_error *)__cxa_allocate_exception(0x10uLL); std::runtime_error::runtime_error(exception, "Unknown chat format"); __cxa_throw( exception, (struct type_info *)&`typeinfo for'std::runtime_error, (void (*)(void *))&std::runtime_error::~runtime_error); } std::string::_M_construct<char const*>((long long)a1, v2, (long long)v3); return a1; }
common_chat_format_name[abi:cxx11]: PUSH R14 PUSH RBX PUSH RAX CMP ESI,0xd JA 0x001955c3 MOV RBX,RDI MOV EAX,ESI LEA RCX,[0x21c500] MOVSXD RAX,dword ptr [RCX + RAX*0x4] ADD RAX,RCX switchD: JMP RAX caseD_0: LEA RAX,[RBX + 0x10] MOV qword ptr [RBX],RAX LEA RSI,[0x21dde9] LEA RDX,[0x21ddf5] JMP 0x001955b0 caseD_b: LEA RAX,[RBX + 0x10] MOV qword ptr [RBX],RAX LEA RSI,[0x21dea7] LEA RDX,[0x21dec7] JMP 0x001955b0 caseD_4: LEA RAX,[RBX + 0x10] MOV qword ptr [RBX],RAX LEA RSI,[0x21de15] LEA RDX,[0x21de31] JMP 0x001955b0 caseD_c: LEA RAX,[RBX + 0x10] MOV qword ptr [RBX],RAX LEA RSI,[0x21dec8] LEA RDX,[0x21ded3] JMP 0x001955b0 caseD_9: LEA RAX,[RBX + 0x10] MOV qword ptr [RBX],RAX LEA RSI,[0x21de7f] LEA RDX,[0x21de99] JMP 0x001955b0 caseD_2: LEA RAX,[RBX + 0x10] MOV qword ptr [RBX],RAX LEA RSI,[0x21ddfe] LEA RDX,[0x21de0a] JMP 0x001955b0 caseD_3: LEA RAX,[RBX + 0x10] MOV qword ptr [RBX],RAX LEA RSI,[0x21de0b] LEA RDX,[0x21de14] JMP 0x001955b0 caseD_7: LEA RAX,[RBX + 0x10] MOV qword ptr [RBX],RAX LEA RSI,[0x21de5e] LEA RDX,[0x21de6d] JMP 0x001955b0 caseD_1: LEA RAX,[RBX + 0x10] MOV qword ptr [RBX],RAX LEA RSI,[0x21ddf6] LEA RDX,[0x21ddfd] JMP 0x001955b0 caseD_5: LEA RAX,[RBX + 0x10] MOV qword ptr [RBX],RAX LEA RSI,[0x21de32] LEA RDX,[0x21de3d] JMP 0x001955b0 caseD_d: LEA RAX,[RBX + 0x10] MOV qword ptr [RBX],RAX LEA RSI,[0x21ded4] LEA RDX,[0x21def3] JMP 0x001955b0 caseD_6: LEA RAX,[RBX + 0x10] MOV qword ptr [RBX],RAX LEA RSI,[0x21de3e] LEA RDX,[0x21de5d] JMP 0x001955b0 caseD_a: LEA RAX,[RBX + 0x10] MOV qword ptr [RBX],RAX LEA RSI,[0x21de9a] LEA RDX,[0x21dea6] JMP 0x001955b0 caseD_8: LEA RAX,[RBX + 0x10] MOV qword ptr [RBX],RAX LEA RSI,[0x21de6e] LEA RDX,[0x21de7e] LAB_001955b0: MOV RDI,RBX CALL 0x00127994 MOV RAX,RBX ADD RSP,0x8 POP RBX POP R14 RET default: MOV EDI,0x10 CALL 0x00120610 MOV RBX,RAX LAB_001955d0: LEA RSI,[0x21def4] MOV RDI,RAX CALL 0x001203f0 LAB_001955df: MOV RSI,qword ptr [0x00260fc0] MOV RDX,qword ptr [0x00260f80] MOV RDI,RBX CALL 0x00120a10
/* common_chat_format_name[abi:cxx11](common_chat_format) */ long * common_chat_format_name_abi_cxx11_(long *param_1,int4 param_2) { runtime_error *this; char *pcVar1; char *pcVar2; switch(param_2) { case 0: *param_1 = (long)(param_1 + 2); pcVar2 = "Content-only"; pcVar1 = ""; break; case 1: *param_1 = (long)(param_1 + 2); pcVar2 = "Generic"; pcVar1 = ""; break; case 2: *param_1 = (long)(param_1 + 2); pcVar2 = "Mistral Nemo"; pcVar1 = ""; break; case 3: *param_1 = (long)(param_1 + 2); pcVar2 = "Llama 3.x"; pcVar1 = ""; break; case 4: *param_1 = (long)(param_1 + 2); pcVar2 = "Llama 3.x with builtin tools"; pcVar1 = ""; break; case 5: *param_1 = (long)(param_1 + 2); pcVar2 = "DeepSeek R1"; pcVar1 = ""; break; case 6: *param_1 = (long)(param_1 + 2); pcVar2 = "DeepSeek R1 (extract reasoning)"; pcVar1 = ""; break; case 7: *param_1 = (long)(param_1 + 2); pcVar2 = "FireFunction v2"; pcVar1 = ""; break; case 8: *param_1 = (long)(param_1 + 2); pcVar2 = "Functionary v3.2"; pcVar1 = ""; break; case 9: *param_1 = (long)(param_1 + 2); pcVar2 = "Functionary v3.1 Llama 3.1"; pcVar1 = ""; break; case 10: *param_1 = (long)(param_1 + 2); pcVar2 = "Hermes 2 Pro"; pcVar1 = ""; break; case 0xb: *param_1 = (long)(param_1 + 2); pcVar2 = "Hermes 2 Pro (extract reasoning)"; pcVar1 = ""; break; case 0xc: *param_1 = (long)(param_1 + 2); pcVar2 = "Command R7B"; pcVar1 = ""; break; case 0xd: *param_1 = (long)(param_1 + 2); pcVar2 = "Command R7B (extract reasoning)"; pcVar1 = ""; break; default: this = (runtime_error *)__cxa_allocate_exception(0x10); /* try { // try from 001955d0 to 001955de has its CatchHandler @ 001955f5 */ std::runtime_error::runtime_error(this,"Unknown chat format"); /* WARNING: Subroutine does not return */ __cxa_throw(this,PTR_typeinfo_00260fc0,PTR__runtime_error_00260f80); } std::__cxx11::string::_M_construct<char_const*>(param_1,pcVar2,pcVar1); return param_1; }
27,506
google::protobuf::FileOptions::Clear()
aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/descriptor.pb.cc
void FileOptions::Clear() { // @@protoc_insertion_point(message_clear_start:google.protobuf.FileOptions) uint32_t cached_has_bits = 0; // Prevent compiler warnings about cached_has_bits being unused (void) cached_has_bits; _impl_._extensions_.Clear(); _impl_.uninterpreted_option_.Clear(); cached_has_bits = _impl_._has_bits_[0]; if (cached_has_bits & 0x000000ffu) { if (cached_has_bits & 0x00000001u) { _impl_.java_package_.ClearNonDefaultToEmpty(); } if (cached_has_bits & 0x00000002u) { _impl_.java_outer_classname_.ClearNonDefaultToEmpty(); } if (cached_has_bits & 0x00000004u) { _impl_.go_package_.ClearNonDefaultToEmpty(); } if (cached_has_bits & 0x00000008u) { _impl_.objc_class_prefix_.ClearNonDefaultToEmpty(); } if (cached_has_bits & 0x00000010u) { _impl_.csharp_namespace_.ClearNonDefaultToEmpty(); } if (cached_has_bits & 0x00000020u) { _impl_.swift_prefix_.ClearNonDefaultToEmpty(); } if (cached_has_bits & 0x00000040u) { _impl_.php_class_prefix_.ClearNonDefaultToEmpty(); } if (cached_has_bits & 0x00000080u) { _impl_.php_namespace_.ClearNonDefaultToEmpty(); } } if (cached_has_bits & 0x00000300u) { if (cached_has_bits & 0x00000100u) { _impl_.php_metadata_namespace_.ClearNonDefaultToEmpty(); } if (cached_has_bits & 0x00000200u) { _impl_.ruby_package_.ClearNonDefaultToEmpty(); } } if (cached_has_bits & 0x0000fc00u) { ::memset(&_impl_.java_multiple_files_, 0, static_cast<size_t>( reinterpret_cast<char*>(&_impl_.py_generic_services_) - reinterpret_cast<char*>(&_impl_.java_multiple_files_)) + sizeof(_impl_.py_generic_services_)); } if (cached_has_bits & 0x000f0000u) { ::memset(&_impl_.php_generic_services_, 0, static_cast<size_t>( reinterpret_cast<char*>(&_impl_.deprecated_) - reinterpret_cast<char*>(&_impl_.php_generic_services_)) + sizeof(_impl_.deprecated_)); _impl_.optimize_for_ = 1; _impl_.cc_enable_arenas_ = true; } _impl_._has_bits_.Clear(); _internal_metadata_.Clear<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(); }
O0
cpp
google::protobuf::FileOptions::Clear(): subq $0x58, %rsp movq %rdi, 0x20(%rsp) movq 0x20(%rsp), %rdi movq %rdi, 0x10(%rsp) movl $0x0, 0x1c(%rsp) addq $0x10, %rdi callq 0x1984c0 movq 0x10(%rsp), %rdi addq $0x10, %rdi addq $0x20, %rdi callq 0xd6c10 movq 0x10(%rsp), %rax addq $0x10, %rax addq $0x18, %rax movq %rax, 0x40(%rsp) movl $0x0, 0x3c(%rsp) movq 0x40(%rsp), %rax movslq 0x3c(%rsp), %rcx movl (%rax,%rcx,4), %eax movl %eax, 0x1c(%rsp) movl 0x1c(%rsp), %eax andl $0xff, %eax cmpl $0x0, %eax je 0xa9d87 movl 0x1c(%rsp), %eax andl $0x1, %eax cmpl $0x0, %eax je 0xa9cb1 movq 0x10(%rsp), %rdi addq $0x10, %rdi addq $0x38, %rdi callq 0xd4de0 movl 0x1c(%rsp), %eax andl $0x2, %eax cmpl $0x0, %eax je 0xa9ccf movq 0x10(%rsp), %rdi addq $0x10, %rdi addq $0x40, %rdi callq 0xd4de0 movl 0x1c(%rsp), %eax andl $0x4, %eax cmpl $0x0, %eax je 0xa9ced movq 0x10(%rsp), %rdi addq $0x10, %rdi addq $0x48, %rdi callq 0xd4de0 movl 0x1c(%rsp), %eax andl $0x8, %eax cmpl $0x0, %eax je 0xa9d0b movq 0x10(%rsp), %rdi addq $0x10, %rdi addq $0x50, %rdi callq 0xd4de0 movl 0x1c(%rsp), %eax andl $0x10, %eax cmpl $0x0, %eax je 0xa9d29 movq 0x10(%rsp), %rdi addq $0x10, %rdi addq $0x58, %rdi callq 0xd4de0 movl 0x1c(%rsp), %eax andl $0x20, %eax cmpl $0x0, %eax je 0xa9d47 movq 0x10(%rsp), %rdi addq $0x10, %rdi addq $0x60, %rdi callq 0xd4de0 movl 0x1c(%rsp), %eax andl $0x40, %eax cmpl $0x0, %eax je 0xa9d65 movq 0x10(%rsp), %rdi addq $0x10, %rdi addq $0x68, %rdi callq 0xd4de0 movl 0x1c(%rsp), %eax andl $0x80, %eax cmpl $0x0, %eax je 0xa9d85 movq 0x10(%rsp), %rdi addq $0x10, %rdi addq $0x70, %rdi callq 0xd4de0 jmp 0xa9d87 movl 0x1c(%rsp), %eax andl $0x300, %eax # imm = 0x300 cmpl $0x0, %eax je 0xa9dda movl 0x1c(%rsp), %eax andl $0x100, %eax # imm = 0x100 cmpl $0x0, %eax je 0xa9db5 movq 0x10(%rsp), %rdi addq $0x10, %rdi addq $0x78, %rdi callq 0xd4de0 movl 0x1c(%rsp), %eax andl $0x200, %eax # imm = 0x200 cmpl $0x0, %eax je 0xa9dd8 movq 0x10(%rsp), %rdi addq $0x10, %rdi addq $0x80, %rdi callq 0xd4de0 jmp 0xa9dda movl 0x1c(%rsp), %eax andl $0xfc00, %eax # imm = 0xFC00 cmpl $0x0, %eax je 0xa9e21 movq 0x10(%rsp), %rax movq %rax, %rdi addq $0x10, %rdi addq $0x88, %rdi movq %rax, %rdx addq $0x10, %rdx addq $0x8d, %rdx addq $0x10, %rax addq $0x88, %rax subq %rax, %rdx addq $0x1, %rdx xorl %esi, %esi callq 0x13200 movl 0x1c(%rsp), %eax andl $0xf0000, %eax # imm = 0xF0000 cmpl $0x0, %eax je 0xa9e7e movq 0x10(%rsp), %rax movq %rax, %rdi addq $0x10, %rdi addq $0x8e, %rdi movq %rax, %rdx addq $0x10, %rdx addq $0x8f, %rdx addq $0x10, %rax addq $0x8e, %rax subq %rax, %rdx addq $0x1, %rdx xorl %esi, %esi callq 0x13200 movq 0x10(%rsp), %rax movl $0x1, 0xa0(%rax) movb $0x1, 0xa4(%rax) movq 0x10(%rsp), %rax addq $0x10, %rax addq $0x18, %rax movq %rax, 0x48(%rsp) movq 0x48(%rsp), %rdi xorl %esi, %esi movl $0x4, %edx callq 0x13200 movq 0x10(%rsp), %rax addq $0x8, %rax movq %rax, 0x28(%rsp) movq 0x28(%rsp), %rax movq %rax, 0x8(%rsp) movq %rax, 0x30(%rsp) movq 0x30(%rsp), %rax movq %rax, 0x50(%rsp) movq 0x50(%rsp), %rax movq (%rax), %rax andq $0x1, %rax cmpq $0x0, %rax je 0xa9ee4 movq 0x8(%rsp), %rdi callq 0xe0a90 addq $0x58, %rsp retq nopl (%rax)
_ZN6google8protobuf11FileOptions5ClearEv: sub rsp, 58h mov [rsp+58h+var_38], rdi mov rdi, [rsp+58h+var_38] mov [rsp+58h+var_48], rdi mov [rsp+58h+var_3C], 0 add rdi, 10h; this call _ZN6google8protobuf8internal12ExtensionSet5ClearEv; google::protobuf::internal::ExtensionSet::Clear(void) mov rdi, [rsp+58h+var_48] add rdi, 10h add rdi, 20h ; ' ' call _ZN6google8protobuf16RepeatedPtrFieldINS0_19UninterpretedOptionEE5ClearEv; google::protobuf::RepeatedPtrField<google::protobuf::UninterpretedOption>::Clear(void) mov rax, [rsp+58h+var_48] add rax, 10h add rax, 18h mov [rsp+58h+var_18], rax mov [rsp+58h+var_1C], 0 mov rax, [rsp+58h+var_18] movsxd rcx, [rsp+58h+var_1C] mov eax, [rax+rcx*4] mov [rsp+58h+var_3C], eax mov eax, [rsp+58h+var_3C] and eax, 0FFh cmp eax, 0 jz loc_A9D87 mov eax, [rsp+58h+var_3C] and eax, 1 cmp eax, 0 jz short loc_A9CB1 mov rdi, [rsp+58h+var_48] add rdi, 10h add rdi, 38h ; '8'; this call _ZN6google8protobuf8internal14ArenaStringPtr22ClearNonDefaultToEmptyEv; google::protobuf::internal::ArenaStringPtr::ClearNonDefaultToEmpty(void) loc_A9CB1: mov eax, [rsp+58h+var_3C] and eax, 2 cmp eax, 0 jz short loc_A9CCF mov rdi, [rsp+58h+var_48] add rdi, 10h add rdi, 40h ; '@'; this call _ZN6google8protobuf8internal14ArenaStringPtr22ClearNonDefaultToEmptyEv; google::protobuf::internal::ArenaStringPtr::ClearNonDefaultToEmpty(void) loc_A9CCF: mov eax, [rsp+58h+var_3C] and eax, 4 cmp eax, 0 jz short loc_A9CED mov rdi, [rsp+58h+var_48] add rdi, 10h add rdi, 48h ; 'H'; this call _ZN6google8protobuf8internal14ArenaStringPtr22ClearNonDefaultToEmptyEv; google::protobuf::internal::ArenaStringPtr::ClearNonDefaultToEmpty(void) loc_A9CED: mov eax, [rsp+58h+var_3C] and eax, 8 cmp eax, 0 jz short loc_A9D0B mov rdi, [rsp+58h+var_48] add rdi, 10h add rdi, 50h ; 'P'; this call _ZN6google8protobuf8internal14ArenaStringPtr22ClearNonDefaultToEmptyEv; google::protobuf::internal::ArenaStringPtr::ClearNonDefaultToEmpty(void) loc_A9D0B: mov eax, [rsp+58h+var_3C] and eax, 10h cmp eax, 0 jz short loc_A9D29 mov rdi, [rsp+58h+var_48] add rdi, 10h add rdi, 58h ; 'X'; this call _ZN6google8protobuf8internal14ArenaStringPtr22ClearNonDefaultToEmptyEv; google::protobuf::internal::ArenaStringPtr::ClearNonDefaultToEmpty(void) loc_A9D29: mov eax, [rsp+58h+var_3C] and eax, 20h cmp eax, 0 jz short loc_A9D47 mov rdi, [rsp+58h+var_48] add rdi, 10h add rdi, 60h ; '`'; this call _ZN6google8protobuf8internal14ArenaStringPtr22ClearNonDefaultToEmptyEv; google::protobuf::internal::ArenaStringPtr::ClearNonDefaultToEmpty(void) loc_A9D47: mov eax, [rsp+58h+var_3C] and eax, 40h cmp eax, 0 jz short loc_A9D65 mov rdi, [rsp+58h+var_48] add rdi, 10h add rdi, 68h ; 'h'; this call _ZN6google8protobuf8internal14ArenaStringPtr22ClearNonDefaultToEmptyEv; google::protobuf::internal::ArenaStringPtr::ClearNonDefaultToEmpty(void) loc_A9D65: mov eax, [rsp+58h+var_3C] and eax, 80h cmp eax, 0 jz short loc_A9D85 mov rdi, [rsp+58h+var_48] add rdi, 10h add rdi, 70h ; 'p'; this call _ZN6google8protobuf8internal14ArenaStringPtr22ClearNonDefaultToEmptyEv; google::protobuf::internal::ArenaStringPtr::ClearNonDefaultToEmpty(void) loc_A9D85: jmp short $+2 loc_A9D87: mov eax, [rsp+58h+var_3C] and eax, 300h cmp eax, 0 jz short loc_A9DDA mov eax, [rsp+58h+var_3C] and eax, 100h cmp eax, 0 jz short loc_A9DB5 mov rdi, [rsp+58h+var_48] add rdi, 10h add rdi, 78h ; 'x'; this call _ZN6google8protobuf8internal14ArenaStringPtr22ClearNonDefaultToEmptyEv; google::protobuf::internal::ArenaStringPtr::ClearNonDefaultToEmpty(void) loc_A9DB5: mov eax, [rsp+58h+var_3C] and eax, 200h cmp eax, 0 jz short loc_A9DD8 mov rdi, [rsp+58h+var_48] add rdi, 10h add rdi, 80h; this call _ZN6google8protobuf8internal14ArenaStringPtr22ClearNonDefaultToEmptyEv; google::protobuf::internal::ArenaStringPtr::ClearNonDefaultToEmpty(void) loc_A9DD8: jmp short $+2 loc_A9DDA: mov eax, [rsp+58h+var_3C] and eax, 0FC00h cmp eax, 0 jz short loc_A9E21 mov rax, [rsp+58h+var_48] mov rdi, rax add rdi, 10h add rdi, 88h mov rdx, rax add rdx, 10h add rdx, 8Dh add rax, 10h add rax, 88h sub rdx, rax add rdx, 1 xor esi, esi call _memset loc_A9E21: mov eax, [rsp+58h+var_3C] and eax, 0F0000h cmp eax, 0 jz short loc_A9E7E mov rax, [rsp+58h+var_48] mov rdi, rax add rdi, 10h add rdi, 8Eh mov rdx, rax add rdx, 10h add rdx, 8Fh add rax, 10h add rax, 8Eh sub rdx, rax add rdx, 1 xor esi, esi call _memset mov rax, [rsp+58h+var_48] mov dword ptr [rax+0A0h], 1 mov byte ptr [rax+0A4h], 1 loc_A9E7E: mov rax, [rsp+58h+var_48] add rax, 10h add rax, 18h mov [rsp+58h+var_10], rax mov rdi, [rsp+58h+var_10] xor esi, esi mov edx, 4 call _memset mov rax, [rsp+58h+var_48] add rax, 8 mov [rsp+58h+var_30], rax mov rax, [rsp+58h+var_30] mov [rsp+58h+var_50], rax mov [rsp+58h+var_28], rax mov rax, [rsp+58h+var_28] mov [rsp+58h+var_8], rax mov rax, [rsp+58h+var_8] mov rax, [rax] and rax, 1 cmp rax, 0 jz short loc_A9EE4 mov rdi, [rsp+58h+var_50]; void * call _ZN6google8protobuf8internal16InternalMetadata7DoClearINS0_15UnknownFieldSetEEEvv; google::protobuf::internal::InternalMetadata::DoClear<google::protobuf::UnknownFieldSet>(void) loc_A9EE4: add rsp, 58h retn
long long google::protobuf::FileOptions::Clear(google::protobuf::FileOptions *this) { long long result; // rax int v2; // [rsp+1Ch] [rbp-3Ch] google::protobuf::internal::ExtensionSet::Clear((google::protobuf::FileOptions *)((char *)this + 16)); google::protobuf::RepeatedPtrField<google::protobuf::UninterpretedOption>::Clear((char *)this + 48); v2 = *((_DWORD *)this + 10); if ( (_BYTE)v2 ) { if ( (v2 & 1) != 0 ) google::protobuf::internal::ArenaStringPtr::ClearNonDefaultToEmpty((google::protobuf::FileOptions *)((char *)this + 72)); if ( (v2 & 2) != 0 ) google::protobuf::internal::ArenaStringPtr::ClearNonDefaultToEmpty((google::protobuf::FileOptions *)((char *)this + 80)); if ( (v2 & 4) != 0 ) google::protobuf::internal::ArenaStringPtr::ClearNonDefaultToEmpty((google::protobuf::FileOptions *)((char *)this + 88)); if ( (v2 & 8) != 0 ) google::protobuf::internal::ArenaStringPtr::ClearNonDefaultToEmpty((google::protobuf::FileOptions *)((char *)this + 96)); if ( (v2 & 0x10) != 0 ) google::protobuf::internal::ArenaStringPtr::ClearNonDefaultToEmpty((google::protobuf::FileOptions *)((char *)this + 104)); if ( (v2 & 0x20) != 0 ) google::protobuf::internal::ArenaStringPtr::ClearNonDefaultToEmpty((google::protobuf::FileOptions *)((char *)this + 112)); if ( (v2 & 0x40) != 0 ) google::protobuf::internal::ArenaStringPtr::ClearNonDefaultToEmpty((google::protobuf::FileOptions *)((char *)this + 120)); if ( (v2 & 0x80) != 0 ) google::protobuf::internal::ArenaStringPtr::ClearNonDefaultToEmpty((google::protobuf::FileOptions *)((char *)this + 128)); } if ( (v2 & 0x300) != 0 ) { if ( (v2 & 0x100) != 0 ) google::protobuf::internal::ArenaStringPtr::ClearNonDefaultToEmpty((google::protobuf::FileOptions *)((char *)this + 136)); if ( (v2 & 0x200) != 0 ) google::protobuf::internal::ArenaStringPtr::ClearNonDefaultToEmpty((google::protobuf::FileOptions *)((char *)this + 144)); } if ( (v2 & 0xFC00) != 0 ) memset((char *)this + 152, 0LL, 6LL); if ( (v2 & 0xF0000) != 0 ) { memset((char *)this + 158, 0LL, 2LL); *((_DWORD *)this + 40) = 1; *((_BYTE *)this + 164) = 1; } memset((char *)this + 40, 0LL, 4LL); result = *((_QWORD *)this + 1) & 1LL; if ( result ) return google::protobuf::internal::InternalMetadata::DoClear<google::protobuf::UnknownFieldSet>((char *)this + 8); return result; }
Clear: SUB RSP,0x58 MOV qword ptr [RSP + 0x20],RDI MOV RDI,qword ptr [RSP + 0x20] MOV qword ptr [RSP + 0x10],RDI MOV dword ptr [RSP + 0x1c],0x0 ADD RDI,0x10 CALL 0x002984c0 MOV RDI,qword ptr [RSP + 0x10] ADD RDI,0x10 ADD RDI,0x20 CALL 0x001d6c10 MOV RAX,qword ptr [RSP + 0x10] ADD RAX,0x10 ADD RAX,0x18 MOV qword ptr [RSP + 0x40],RAX MOV dword ptr [RSP + 0x3c],0x0 MOV RAX,qword ptr [RSP + 0x40] MOVSXD RCX,dword ptr [RSP + 0x3c] MOV EAX,dword ptr [RAX + RCX*0x4] MOV dword ptr [RSP + 0x1c],EAX MOV EAX,dword ptr [RSP + 0x1c] AND EAX,0xff CMP EAX,0x0 JZ 0x001a9d87 MOV EAX,dword ptr [RSP + 0x1c] AND EAX,0x1 CMP EAX,0x0 JZ 0x001a9cb1 MOV RDI,qword ptr [RSP + 0x10] ADD RDI,0x10 ADD RDI,0x38 CALL 0x001d4de0 LAB_001a9cb1: MOV EAX,dword ptr [RSP + 0x1c] AND EAX,0x2 CMP EAX,0x0 JZ 0x001a9ccf MOV RDI,qword ptr [RSP + 0x10] ADD RDI,0x10 ADD RDI,0x40 CALL 0x001d4de0 LAB_001a9ccf: MOV EAX,dword ptr [RSP + 0x1c] AND EAX,0x4 CMP EAX,0x0 JZ 0x001a9ced MOV RDI,qword ptr [RSP + 0x10] ADD RDI,0x10 ADD RDI,0x48 CALL 0x001d4de0 LAB_001a9ced: MOV EAX,dword ptr [RSP + 0x1c] AND EAX,0x8 CMP EAX,0x0 JZ 0x001a9d0b MOV RDI,qword ptr [RSP + 0x10] ADD RDI,0x10 ADD RDI,0x50 CALL 0x001d4de0 LAB_001a9d0b: MOV EAX,dword ptr [RSP + 0x1c] AND EAX,0x10 CMP EAX,0x0 JZ 0x001a9d29 MOV RDI,qword ptr [RSP + 0x10] ADD RDI,0x10 ADD RDI,0x58 CALL 0x001d4de0 LAB_001a9d29: MOV EAX,dword ptr [RSP + 0x1c] AND EAX,0x20 CMP EAX,0x0 JZ 0x001a9d47 MOV RDI,qword ptr [RSP + 0x10] ADD RDI,0x10 ADD RDI,0x60 CALL 0x001d4de0 LAB_001a9d47: MOV EAX,dword ptr [RSP + 0x1c] AND EAX,0x40 CMP EAX,0x0 JZ 0x001a9d65 MOV RDI,qword ptr [RSP + 0x10] ADD RDI,0x10 ADD RDI,0x68 CALL 0x001d4de0 LAB_001a9d65: MOV EAX,dword ptr [RSP + 0x1c] AND EAX,0x80 CMP EAX,0x0 JZ 0x001a9d85 MOV RDI,qword ptr [RSP + 0x10] ADD RDI,0x10 ADD RDI,0x70 CALL 0x001d4de0 LAB_001a9d85: JMP 0x001a9d87 LAB_001a9d87: MOV EAX,dword ptr [RSP + 0x1c] AND EAX,0x300 CMP EAX,0x0 JZ 0x001a9dda MOV EAX,dword ptr [RSP + 0x1c] AND EAX,0x100 CMP EAX,0x0 JZ 0x001a9db5 MOV RDI,qword ptr [RSP + 0x10] ADD RDI,0x10 ADD RDI,0x78 CALL 0x001d4de0 LAB_001a9db5: MOV EAX,dword ptr [RSP + 0x1c] AND EAX,0x200 CMP EAX,0x0 JZ 0x001a9dd8 MOV RDI,qword ptr [RSP + 0x10] ADD RDI,0x10 ADD RDI,0x80 CALL 0x001d4de0 LAB_001a9dd8: JMP 0x001a9dda LAB_001a9dda: MOV EAX,dword ptr [RSP + 0x1c] AND EAX,0xfc00 CMP EAX,0x0 JZ 0x001a9e21 MOV RAX,qword ptr [RSP + 0x10] MOV RDI,RAX ADD RDI,0x10 ADD RDI,0x88 MOV RDX,RAX ADD RDX,0x10 ADD RDX,0x8d ADD RAX,0x10 ADD RAX,0x88 SUB RDX,RAX ADD RDX,0x1 XOR ESI,ESI CALL 0x00113200 LAB_001a9e21: MOV EAX,dword ptr [RSP + 0x1c] AND EAX,0xf0000 CMP EAX,0x0 JZ 0x001a9e7e MOV RAX,qword ptr [RSP + 0x10] MOV RDI,RAX ADD RDI,0x10 ADD RDI,0x8e MOV RDX,RAX ADD RDX,0x10 ADD RDX,0x8f ADD RAX,0x10 ADD RAX,0x8e SUB RDX,RAX ADD RDX,0x1 XOR ESI,ESI CALL 0x00113200 MOV RAX,qword ptr [RSP + 0x10] MOV dword ptr [RAX + 0xa0],0x1 MOV byte ptr [RAX + 0xa4],0x1 LAB_001a9e7e: MOV RAX,qword ptr [RSP + 0x10] ADD RAX,0x10 ADD RAX,0x18 MOV qword ptr [RSP + 0x48],RAX MOV RDI,qword ptr [RSP + 0x48] XOR ESI,ESI MOV EDX,0x4 CALL 0x00113200 MOV RAX,qword ptr [RSP + 0x10] ADD RAX,0x8 MOV qword ptr [RSP + 0x28],RAX MOV RAX,qword ptr [RSP + 0x28] MOV qword ptr [RSP + 0x8],RAX MOV qword ptr [RSP + 0x30],RAX MOV RAX,qword ptr [RSP + 0x30] MOV qword ptr [RSP + 0x50],RAX MOV RAX,qword ptr [RSP + 0x50] MOV RAX,qword ptr [RAX] AND RAX,0x1 CMP RAX,0x0 JZ 0x001a9ee4 MOV RDI,qword ptr [RSP + 0x8] CALL 0x001e0a90 LAB_001a9ee4: ADD RSP,0x58 RET
/* google::protobuf::FileOptions::Clear() */ void __thiscall google::protobuf::FileOptions::Clear(FileOptions *this) { uint uVar1; internal::ExtensionSet::Clear((ExtensionSet *)(this + 0x10)); RepeatedPtrField<google::protobuf::UninterpretedOption>::Clear ((RepeatedPtrField<google::protobuf::UninterpretedOption> *)(this + 0x30)); uVar1 = *(uint *)(this + 0x28); if ((uVar1 & 0xff) != 0) { if ((uVar1 & 1) != 0) { internal::ArenaStringPtr::ClearNonDefaultToEmpty((ArenaStringPtr *)(this + 0x48)); } if ((uVar1 & 2) != 0) { internal::ArenaStringPtr::ClearNonDefaultToEmpty((ArenaStringPtr *)(this + 0x50)); } if ((uVar1 & 4) != 0) { internal::ArenaStringPtr::ClearNonDefaultToEmpty((ArenaStringPtr *)(this + 0x58)); } if ((uVar1 & 8) != 0) { internal::ArenaStringPtr::ClearNonDefaultToEmpty((ArenaStringPtr *)(this + 0x60)); } if ((uVar1 & 0x10) != 0) { internal::ArenaStringPtr::ClearNonDefaultToEmpty((ArenaStringPtr *)(this + 0x68)); } if ((uVar1 & 0x20) != 0) { internal::ArenaStringPtr::ClearNonDefaultToEmpty((ArenaStringPtr *)(this + 0x70)); } if ((uVar1 & 0x40) != 0) { internal::ArenaStringPtr::ClearNonDefaultToEmpty((ArenaStringPtr *)(this + 0x78)); } if ((uVar1 & 0x80) != 0) { internal::ArenaStringPtr::ClearNonDefaultToEmpty((ArenaStringPtr *)(this + 0x80)); } } if ((uVar1 & 0x300) != 0) { if ((uVar1 & 0x100) != 0) { internal::ArenaStringPtr::ClearNonDefaultToEmpty((ArenaStringPtr *)(this + 0x88)); } if ((uVar1 & 0x200) != 0) { internal::ArenaStringPtr::ClearNonDefaultToEmpty((ArenaStringPtr *)(this + 0x90)); } } if ((uVar1 & 0xfc00) != 0) { memset(this + 0x98,0,6); } if ((uVar1 & 0xf0000) != 0) { memset(this + 0x9e,0,2); *(int4 *)(this + 0xa0) = 1; this[0xa4] = (FileOptions)0x1; } memset(this + 0x28,0,4); if ((*(ulong *)(this + 8) & 1) != 0) { internal::InternalMetadata::DoClear<google::protobuf::UnknownFieldSet> ((InternalMetadata *)(this + 8)); } return; }
27,507
my_context_continue
eloqsql/libmariadb/libmariadb/ma_context.c
int my_context_continue(struct my_context *c) { int ret; __asm__ __volatile__ ( "movq (%[save]), %%rax\n\t" "movq %%rsp, (%[save])\n\t" "movq %%rax, %%rsp\n\t" "movq 8(%[save]), %%rax\n\t" "movq %%rbp, 8(%[save])\n\t" "movq %%rax, %%rbp\n\t" "movq 24(%[save]), %%rax\n\t" "movq %%r12, 24(%[save])\n\t" "movq %%rax, %%r12\n\t" "movq 32(%[save]), %%rax\n\t" "movq %%r13, 32(%[save])\n\t" "movq %%rax, %%r13\n\t" "movq 40(%[save]), %%rax\n\t" "movq %%r14, 40(%[save])\n\t" "movq %%rax, %%r14\n\t" "movq 48(%[save]), %%rax\n\t" "movq %%r15, 48(%[save])\n\t" "movq %%rax, %%r15\n\t" "leaq 1f(%%rip), %%rax\n\t" "leaq 2f(%%rip), %%rcx\n\t" "movq %%rax, 56(%[save])\n\t" "movq 64(%[save]), %%rax\n\t" "movq %%rcx, 64(%[save])\n\t" "movq 16(%[save]), %%rcx\n\t" "movq %%rbx, 16(%[save])\n\t" "movq %%rcx, %%rbx\n\t" "jmpq *%%rax\n" /* Come here when operation is done. Be sure to use the same callee-save register for %[save] here and in my_context_spawn(), so we preserve the value correctly at this point. */ "1:\n\t" "movq (%[save]), %%rsp\n\t" "movq 8(%[save]), %%rbp\n\t" /* %rbx is preserved from my_context_spawn() in this case. */ "movq 24(%[save]), %%r12\n\t" "movq 32(%[save]), %%r13\n\t" "movq 40(%[save]), %%r14\n\t" "movq 48(%[save]), %%r15\n\t" "xorl %[ret], %[ret]\n\t" "jmp 3f\n" /* Come here when operation is suspended. */ "2:\n\t" "movl $1, %[ret]\n" "3:\n" : [ret] "=a" (ret) : /* Need this in callee-save register to preserve in function call. */ [save] "b" (&c->save[0]) : "rcx", "rdx", "rsi", "rdi", "r8", "r9", "r10", "r11", "memory", "cc" ); return ret; }
O0
c
my_context_continue: pushq %rbp movq %rsp, %rbp pushq %rbx movq %rdi, -0x10(%rbp) movq -0x10(%rbp), %rbx movq (%rbx), %rax movq %rsp, (%rbx) movq %rax, %rsp movq 0x8(%rbx), %rax movq %rbp, 0x8(%rbx) movq %rax, %rbp movq 0x18(%rbx), %rax movq %r12, 0x18(%rbx) movq %rax, %r12 movq 0x20(%rbx), %rax movq %r13, 0x20(%rbx) movq %rax, %r13 movq 0x28(%rbx), %rax movq %r14, 0x28(%rbx) movq %rax, %r14 movq 0x30(%rbx), %rax movq %r15, 0x30(%rbx) movq %rax, %r15 leaq 0x20(%rip), %rax # 0x43fc4 leaq 0x34(%rip), %rcx # 0x43fdf movq %rax, 0x38(%rbx) movq 0x40(%rbx), %rax movq %rcx, 0x40(%rbx) movq 0x10(%rbx), %rcx movq %rbx, 0x10(%rbx) movq %rcx, %rbx jmpq *%rax movq (%rbx), %rsp movq 0x8(%rbx), %rbp movq 0x18(%rbx), %r12 movq 0x20(%rbx), %r13 movq 0x28(%rbx), %r14 movq 0x30(%rbx), %r15 xorl %eax, %eax jmp 0x43fe4 movl $0x1, %eax movl %eax, -0x14(%rbp) movl -0x14(%rbp), %eax popq %rbx popq %rbp retq nopl (%rax)
my_context_continue: push rbp mov rbp, rsp push rbx mov [rbp+var_10], rdi mov rbx, [rbp+var_10] mov rax, [rbx] mov [rbx], rsp mov rsp, rax mov rax, [rbx+8] mov [rbx+8], rbp mov rbp, rax mov rax, [rbx+18h] mov [rbx+18h], r12 mov r12, rax mov rax, [rbx+20h] mov [rbx+20h], r13 mov r13, rax mov rax, [rbx+28h] mov [rbx+28h], r14 mov r14, rax mov rax, [rbx+30h] mov [rbx+30h], r15 mov r15, rax lea rax, sub_43FC4 lea rcx, loc_43FDF mov [rbx+38h], rax mov rax, [rbx+40h] mov [rbx+40h], rcx mov rcx, [rbx+10h] mov [rbx+10h], rbx mov rbx, rcx jmp rax
long long my_context_continue(_QWORD *a1) { long long v1; // r12 long long v2; // r13 long long v3; // r14 long long v4; // r15 long long (*v5)(void); // rax long long v7; // [rsp+8h] [rbp-8h] BYREF long long savedregs; // [rsp+10h] [rbp+0h] BYREF *a1 = &v7; a1[1] = &savedregs; a1[3] = v1; a1[4] = v2; a1[5] = v3; a1[6] = v4; a1[7] = sub_43FC4; v5 = (long long (*)(void))a1[8]; a1[8] = &loc_43FDF; a1[2] = a1; return v5(); }
my_context_continue: PUSH RBP MOV RBP,RSP PUSH RBX MOV qword ptr [RBP + -0x10],RDI MOV RBX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RBX] MOV qword ptr [RBX],RSP MOV RSP,RAX MOV RAX,qword ptr [RBX + 0x8] MOV qword ptr [RBX + 0x8],RBP MOV RBP,RAX MOV RAX,qword ptr [RBX + 0x18] MOV qword ptr [RBX + 0x18],R12 MOV R12,RAX MOV RAX,qword ptr [RBX + 0x20] MOV qword ptr [RBX + 0x20],R13 MOV R13,RAX MOV RAX,qword ptr [RBX + 0x28] MOV qword ptr [RBX + 0x28],R14 MOV R14,RAX MOV RAX,qword ptr [RBX + 0x30] MOV qword ptr [RBX + 0x30],R15 MOV R15,RAX LEA RAX,[0x143fc4] LEA RCX,[0x143fdf] MOV qword ptr [RBX + 0x38],RAX MOV RAX,qword ptr [RBX + 0x40] MOV qword ptr [RBX + 0x40],RCX MOV RCX,qword ptr [RBX + 0x10] MOV qword ptr [RBX + 0x10],RBX MOV RBX,RCX JMP RAX
void my_context_continue(long param_1) { code *UNRECOVERED_JUMPTABLE; int8 unaff_R12; int8 unaff_R13; int8 unaff_R14; int8 unaff_R15; *(int1 **)param_1 = &stack0xfffffffffffffff0; *(int1 **)(param_1 + 8) = &stack0xfffffffffffffff8; *(int8 *)(param_1 + 0x18) = unaff_R12; *(int8 *)(param_1 + 0x20) = unaff_R13; *(int8 *)(param_1 + 0x28) = unaff_R14; *(int8 *)(param_1 + 0x30) = unaff_R15; *(int1 **)(param_1 + 0x38) = &LAB_00143fc4; UNRECOVERED_JUMPTABLE = *(code **)(param_1 + 0x40); *(int1 **)(param_1 + 0x40) = &LAB_00143fdf; *(long *)(param_1 + 0x10) = param_1; /* WARNING: Could not recover jumptable at 0x00143fc2. Too many branches */ /* WARNING: Treating indirect jump as call */ (*UNRECOVERED_JUMPTABLE)(); return; }
27,508
glfwPlatformRequestWindowAttention
untodesu[P]riteg/build_O1/_deps/glfw-src/src/x11_window.c
void _glfwPlatformRequestWindowAttention(_GLFWwindow* window) { sendEventToWM(window, _glfw.x11.NET_WM_STATE, _NET_WM_STATE_ADD, _glfw.x11.NET_WM_STATE_DEMANDS_ATTENTION, 0, 1, 0); }
O1
c
glfwPlatformRequestWindowAttention: pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0xc8, %rsp movq %rdi, %r14 leaq 0x81067(%rip), %r15 # 0xa4638 movq 0x20440(%r15), %r12 movq 0x20468(%r15), %r13 leaq 0x8(%rsp), %rbx xorl %ebp, %ebp movl $0xc0, %edx movq %rbx, %rdi xorl %esi, %esi callq 0xc470 movl $0x21, (%rbx) movq 0x348(%r14), %rax movq %rax, 0x20(%rbx) movl $0x20, 0x30(%rbx) movq %r12, 0x28(%rbx) movl $0x1, %eax movq %rax, 0x38(%rbx) movq %r13, 0x40(%rbx) movq %rbp, 0x48(%rbx) movq %rax, 0x50(%rbx) movq %rbp, 0x58(%rbx) movq 0x1fec0(%r15), %rdi movq 0x1fed0(%r15), %rsi movl $0x180000, %ecx # imm = 0x180000 xorl %edx, %edx movq %rbx, %r8 callq 0xc1c0 addq $0xc8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
_glfwPlatformRequestWindowAttention: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 0C8h mov r14, rdi lea r15, _glfw mov r12, [r15+20440h] mov r13, [r15+20468h] lea rbx, [rsp+0F8h+var_F0] xor ebp, ebp mov edx, 0C0h mov rdi, rbx xor esi, esi call _memset mov dword ptr [rbx], 21h ; '!' mov rax, [r14+348h] mov [rbx+20h], rax mov dword ptr [rbx+30h], 20h ; ' ' mov [rbx+28h], r12 mov eax, 1 mov [rbx+38h], rax mov [rbx+40h], r13 mov [rbx+48h], rbp mov [rbx+50h], rax mov [rbx+58h], rbp mov rdi, [r15+1FEC0h] mov rsi, [r15+1FED0h] mov ecx, 180000h xor edx, edx mov r8, rbx call _XSendEvent add rsp, 0C8h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
long long glfwPlatformRequestWindowAttention(long long a1) { long long v1; // r12 long long v2; // r13 _DWORD v4[8]; // [rsp+8h] [rbp-F0h] BYREF long long v5; // [rsp+28h] [rbp-D0h] long long v6; // [rsp+30h] [rbp-C8h] int v7; // [rsp+38h] [rbp-C0h] long long v8; // [rsp+40h] [rbp-B8h] long long v9; // [rsp+48h] [rbp-B0h] long long v10; // [rsp+50h] [rbp-A8h] long long v11; // [rsp+58h] [rbp-A0h] long long v12; // [rsp+60h] [rbp-98h] v1 = *(_QWORD *)&glfw[33040]; v2 = *(_QWORD *)&glfw[33050]; memset(v4, 0LL, 192LL); v4[0] = 33; v5 = *(_QWORD *)(a1 + 840); v7 = 32; v6 = v1; v8 = 1LL; v9 = v2; v10 = 0LL; v11 = 1LL; v12 = 0LL; return XSendEvent(*(_QWORD *)&glfw[32688], *(_QWORD *)&glfw[32692], 0LL, 1572864LL, v4); }
_glfwPlatformRequestWindowAttention: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0xc8 MOV R14,RDI LEA R15,[0x1a4638] MOV R12,qword ptr [R15 + 0x20440] MOV R13,qword ptr [R15 + 0x20468] LEA RBX,[RSP + 0x8] XOR EBP,EBP MOV EDX,0xc0 MOV RDI,RBX XOR ESI,ESI CALL 0x0010c470 MOV dword ptr [RBX],0x21 MOV RAX,qword ptr [R14 + 0x348] MOV qword ptr [RBX + 0x20],RAX MOV dword ptr [RBX + 0x30],0x20 MOV qword ptr [RBX + 0x28],R12 MOV EAX,0x1 MOV qword ptr [RBX + 0x38],RAX MOV qword ptr [RBX + 0x40],R13 MOV qword ptr [RBX + 0x48],RBP MOV qword ptr [RBX + 0x50],RAX MOV qword ptr [RBX + 0x58],RBP MOV RDI,qword ptr [R15 + 0x1fec0] MOV RSI,qword ptr [R15 + 0x1fed0] MOV ECX,0x180000 XOR EDX,EDX MOV R8,RBX CALL 0x0010c1c0 ADD RSP,0xc8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
void _glfwPlatformRequestWindowAttention(long param_1) { int8 uVar1; int8 uVar2; int4 local_f0 [8]; int8 local_d0; int8 local_c8; int4 local_c0; int8 local_b8; int8 local_b0; int8 local_a8; int8 local_a0; int8 local_98; uVar2 = DAT_001c4aa0; uVar1 = DAT_001c4a78; memset(local_f0,0,0xc0); local_f0[0] = 0x21; local_d0 = *(int8 *)(param_1 + 0x348); local_c0 = 0x20; local_c8 = uVar1; local_b8 = 1; local_b0 = uVar2; local_a8 = 0; local_a0 = 1; local_98 = 0; XSendEvent(DAT_001c44f8,DAT_001c4508,0,0x180000,local_f0); return; }
27,509
nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>, nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>>>::scan_comment()
llama.cpp/common/json.hpp
bool scan_comment() { switch (get()) { // single-line comments skip input until a newline or EOF is read case '/': { while (true) { switch (get()) { case '\n': case '\r': case char_traits<char_type>::eof(): case '\0': return true; default: break; } } } // multi-line comments skip input until */ is read case '*': { while (true) { switch (get()) { case char_traits<char_type>::eof(): case '\0': { error_message = "invalid comment; missing closing '*/'"; return false; } case '*': { switch (get()) { case '/': return true; default: { unget(); continue; } } } default: continue; } } } // unexpected character after reading '/' default: { error_message = "invalid comment; expecting '/' or '*' after '/'"; return false; } } }
O3
cpp
nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>, nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>>>::scan_comment(): pushq %rbp pushq %rbx pushq %rax movq %rdi, %rbx callq 0x21658 cmpl $0x2f, %eax je 0x85885 cmpl $0x2a, %eax jne 0x858a2 movq %rbx, %rdi callq 0x21658 leal 0x1(%rax), %ecx cmpl $0x2, %ecx jb 0x858ab cmpl $0x2a, %eax jne 0x85859 movq %rbx, %rdi callq 0x21658 cmpl $0x2f, %eax je 0x8589e movq %rbx, %rdi callq 0x86114 jmp 0x85859 movl $0x4803, %ebp # imm = 0x4803 movq %rbx, %rdi callq 0x21658 incl %eax cmpl $0xf, %eax jae 0x8588a btl %eax, %ebp jae 0x8588a movb $0x1, %al jmp 0x858b8 leaq 0x947ec(%rip), %rax # 0x11a095 jmp 0x858b2 leaq 0x947bd(%rip), %rax # 0x11a06f movq %rax, 0x70(%rbx) xorl %eax, %eax addq $0x8, %rsp popq %rbx popq %rbp retq nop
_ZN8nlohmann16json_abi_v3_11_36detail5lexerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEENS1_22iterator_input_adapterIN9__gnu_cxx17__normal_iteratorIPKcSB_EEEEE12scan_commentEv: push rbp push rbx push rax mov rbx, rdi call _ZN8nlohmann16json_abi_v3_11_36detail5lexerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEENS1_22iterator_input_adapterIN9__gnu_cxx17__normal_iteratorIPKcSB_EEEEE3getEv; nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::get(void) cmp eax, 2Fh ; '/' jz short loc_85885 cmp eax, 2Ah ; '*' jnz short loc_858A2 loc_85859: mov rdi, rbx call _ZN8nlohmann16json_abi_v3_11_36detail5lexerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEENS1_22iterator_input_adapterIN9__gnu_cxx17__normal_iteratorIPKcSB_EEEEE3getEv; nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::get(void) lea ecx, [rax+1] cmp ecx, 2 jb short loc_858AB cmp eax, 2Ah ; '*' jnz short loc_85859 mov rdi, rbx call _ZN8nlohmann16json_abi_v3_11_36detail5lexerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEENS1_22iterator_input_adapterIN9__gnu_cxx17__normal_iteratorIPKcSB_EEEEE3getEv; nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::get(void) cmp eax, 2Fh ; '/' jz short loc_8589E mov rdi, rbx call _ZN8nlohmann16json_abi_v3_11_36detail5lexerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEENS1_22iterator_input_adapterIN9__gnu_cxx17__normal_iteratorIPKcSB_EEEEE5ungetEv; nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::unget(void) jmp short loc_85859 loc_85885: mov ebp, 4803h loc_8588A: mov rdi, rbx call _ZN8nlohmann16json_abi_v3_11_36detail5lexerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEENS1_22iterator_input_adapterIN9__gnu_cxx17__normal_iteratorIPKcSB_EEEEE3getEv; nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::get(void) inc eax cmp eax, 0Fh jnb short loc_8588A bt ebp, eax jnb short loc_8588A loc_8589E: mov al, 1 jmp short loc_858B8 loc_858A2: lea rax, aInvalidComment; "invalid comment; expecting '/' or '*' a"... jmp short loc_858B2 loc_858AB: lea rax, aInvalidComment_0; "invalid comment; missing closing '*/'" loc_858B2: mov [rbx+70h], rax xor eax, eax loc_858B8: add rsp, 8 pop rbx pop rbp retn
char nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::scan_comment( __m128i *a1) { int v1; // eax int v2; // eax int v3; // ebp unsigned int v4; // eax const char *v6; // rax v1 = nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::get(a1); if ( v1 == 47 ) { v3 = 18435; do { do v4 = nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::get(a1) + 1; while ( v4 >= 0xF ); } while ( !_bittest(&v3, v4) ); return 1; } else { if ( v1 == 42 ) { while ( 1 ) { v2 = nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::get(a1); if ( (unsigned int)(v2 + 1) < 2 ) break; if ( v2 == 42 ) { if ( (unsigned int)nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::get(a1) == 47 ) return 1; nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::unget(a1); } } v6 = "invalid comment; missing closing '*/'"; } else { v6 = "invalid comment; expecting '/' or '*' after '/'"; } a1[7].m128i_i64[0] = (long long)v6; return 0; } }
scan_comment: PUSH RBP PUSH RBX PUSH RAX MOV RBX,RDI CALL 0x00121658 CMP EAX,0x2f JZ 0x00185885 CMP EAX,0x2a JNZ 0x001858a2 LAB_00185859: MOV RDI,RBX CALL 0x00121658 LEA ECX,[RAX + 0x1] CMP ECX,0x2 JC 0x001858ab CMP EAX,0x2a JNZ 0x00185859 MOV RDI,RBX CALL 0x00121658 CMP EAX,0x2f JZ 0x0018589e MOV RDI,RBX CALL 0x00186114 JMP 0x00185859 LAB_00185885: MOV EBP,0x4803 LAB_0018588a: MOV RDI,RBX CALL 0x00121658 INC EAX CMP EAX,0xf JNC 0x0018588a BT EBP,EAX JNC 0x0018588a LAB_0018589e: MOV AL,0x1 JMP 0x001858b8 LAB_001858a2: LEA RAX,[0x21a095] JMP 0x001858b2 LAB_001858ab: LEA RAX,[0x21a06f] LAB_001858b2: MOV qword ptr [RBX + 0x70],RAX XOR EAX,EAX LAB_001858b8: ADD RSP,0x8 POP RBX POP RBP RET
/* nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char> >, void>, nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*, std::__cxx11::string > > >::scan_comment() */ int8 __thiscall nlohmann::json_abi_v3_11_3::detail:: lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>>> ::scan_comment(lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>>> *this) { int iVar1; int8 uVar2; char *pcVar3; iVar1 = get(this); if (iVar1 == 0x2f) { do { do { iVar1 = get(this); } while (0xe < iVar1 + 1U); } while ((0x4803U >> (iVar1 + 1U & 0x1f) & 1) == 0); LAB_0018589e: uVar2 = 1; } else { if (iVar1 == 0x2a) { while (iVar1 = get(this), 1 < iVar1 + 1U) { if (iVar1 == 0x2a) { iVar1 = get(this); if (iVar1 == 0x2f) goto LAB_0018589e; unget(this); } } pcVar3 = "invalid comment; missing closing \'*/\'"; } else { pcVar3 = "invalid comment; expecting \'/\' or \'*\' after \'/\'"; } *(char **)(this + 0x70) = pcVar3; uVar2 = 0; } return uVar2; }
27,510
repartition_key_cache_internal
eloqsql/mysys/mf_keycache.c
static int repartition_key_cache_internal(KEY_CACHE *keycache, uint key_cache_block_size, size_t use_mem, uint division_limit, uint age_threshold, uint changed_blocks_hash_size, uint partitions, my_bool use_op_lock) { uint blocks= -1; if (keycache->key_cache_inited) { if (use_op_lock) pthread_mutex_lock(&keycache->op_lock); keycache->interface_funcs->resize(keycache->keycache_cb, key_cache_block_size, 0, division_limit, age_threshold, changed_blocks_hash_size); end_key_cache_internal(keycache, 1, 0); blocks= init_key_cache_internal(keycache, key_cache_block_size, use_mem, division_limit, age_threshold, changed_blocks_hash_size, partitions, 0); if (use_op_lock) pthread_mutex_unlock(&keycache->op_lock); } return blocks; }
O0
c
repartition_key_cache_internal: pushq %rbp movq %rsp, %rbp subq $0x40, %rsp movb 0x18(%rbp), %al movl 0x10(%rbp), %eax movq %rdi, -0x8(%rbp) movl %esi, -0xc(%rbp) movq %rdx, -0x18(%rbp) movl %ecx, -0x1c(%rbp) movl %r8d, -0x20(%rbp) movl %r9d, -0x24(%rbp) movl $0xffffffff, -0x28(%rbp) # imm = 0xFFFFFFFF movq -0x8(%rbp), %rax cmpb $0x0, 0x48(%rax) je 0xec506 cmpb $0x0, 0x18(%rbp) je 0xec48c movq -0x8(%rbp), %rdi addq $0x58, %rdi callq 0x291e0 movq -0x8(%rbp), %rax movq 0x10(%rax), %rax movq 0x8(%rax), %rax movq -0x8(%rbp), %rcx movq 0x8(%rcx), %rdi movl -0xc(%rbp), %esi movl -0x1c(%rbp), %ecx movl -0x20(%rbp), %r8d movl -0x24(%rbp), %r9d xorl %edx, %edx callq *%rax movq -0x8(%rbp), %rdi movl $0x1, %esi xorl %edx, %edx callq 0xec5a0 movq -0x8(%rbp), %rdi movl -0xc(%rbp), %esi movq -0x18(%rbp), %rdx movl -0x1c(%rbp), %ecx movl -0x20(%rbp), %r8d movl -0x24(%rbp), %r9d movl 0x10(%rbp), %eax xorl %r10d, %r10d movl %eax, (%rsp) movl $0x0, 0x8(%rsp) callq 0xec100 movl %eax, -0x28(%rbp) cmpb $0x0, 0x18(%rbp) je 0xec504 movq -0x8(%rbp), %rdi addq $0x58, %rdi callq 0x291c0 jmp 0xec506 movl -0x28(%rbp), %eax addq $0x40, %rsp popq %rbp retq nop
repartition_key_cache_internal: push rbp mov rbp, rsp sub rsp, 40h mov al, [rbp+arg_8] mov eax, [rbp+arg_0] mov [rbp+var_8], rdi mov [rbp+var_C], esi mov [rbp+var_18], rdx mov [rbp+var_1C], ecx mov [rbp+var_20], r8d mov [rbp+var_24], r9d mov [rbp+var_28], 0FFFFFFFFh mov rax, [rbp+var_8] cmp byte ptr [rax+48h], 0 jz loc_EC506 cmp [rbp+arg_8], 0 jz short loc_EC48C mov rdi, [rbp+var_8] add rdi, 58h ; 'X' call _pthread_mutex_lock loc_EC48C: mov rax, [rbp+var_8] mov rax, [rax+10h] mov rax, [rax+8] mov rcx, [rbp+var_8] mov rdi, [rcx+8] mov esi, [rbp+var_C] mov ecx, [rbp+var_1C] mov r8d, [rbp+var_20] mov r9d, [rbp+var_24] xor edx, edx call rax mov rdi, [rbp+var_8] mov esi, 1 xor edx, edx call end_key_cache_internal mov rdi, [rbp+var_8] mov esi, [rbp+var_C] mov rdx, [rbp+var_18] mov ecx, [rbp+var_1C] mov r8d, [rbp+var_20] mov r9d, [rbp+var_24] mov eax, [rbp+arg_0] xor r10d, r10d mov [rsp+40h+var_40], eax mov [rsp+40h+var_38], 0 call init_key_cache_internal mov [rbp+var_28], eax cmp [rbp+arg_8], 0 jz short loc_EC504 mov rdi, [rbp+var_8] add rdi, 58h ; 'X' call _pthread_mutex_unlock loc_EC504: jmp short $+2 loc_EC506: mov eax, [rbp+var_28] add rsp, 40h pop rbp retn
long long repartition_key_cache_internal( long long a1, unsigned int a2, long long a3, unsigned int a4, unsigned int a5, unsigned int a6, int a7, char a8) { unsigned int inited; // [rsp+18h] [rbp-28h] inited = -1; if ( *(_BYTE *)(a1 + 72) ) { if ( a8 ) pthread_mutex_lock(a1 + 88); (*(void ( **)(_QWORD, _QWORD, _QWORD, _QWORD, _QWORD, _QWORD))(*(_QWORD *)(a1 + 16) + 8LL))( *(_QWORD *)(a1 + 8), a2, 0LL, a4, a5, a6); end_key_cache_internal(a1, 1LL, 0LL); inited = init_key_cache_internal(a1, a2, a3, a4, a5, a6, a7, 0); if ( a8 ) pthread_mutex_unlock(a1 + 88); } return inited; }
repartition_key_cache_internal: PUSH RBP MOV RBP,RSP SUB RSP,0x40 MOV AL,byte ptr [RBP + 0x18] MOV EAX,dword ptr [RBP + 0x10] MOV qword ptr [RBP + -0x8],RDI MOV dword ptr [RBP + -0xc],ESI MOV qword ptr [RBP + -0x18],RDX MOV dword ptr [RBP + -0x1c],ECX MOV dword ptr [RBP + -0x20],R8D MOV dword ptr [RBP + -0x24],R9D MOV dword ptr [RBP + -0x28],0xffffffff MOV RAX,qword ptr [RBP + -0x8] CMP byte ptr [RAX + 0x48],0x0 JZ 0x001ec506 CMP byte ptr [RBP + 0x18],0x0 JZ 0x001ec48c MOV RDI,qword ptr [RBP + -0x8] ADD RDI,0x58 CALL 0x001291e0 LAB_001ec48c: MOV RAX,qword ptr [RBP + -0x8] MOV RAX,qword ptr [RAX + 0x10] MOV RAX,qword ptr [RAX + 0x8] MOV RCX,qword ptr [RBP + -0x8] MOV RDI,qword ptr [RCX + 0x8] MOV ESI,dword ptr [RBP + -0xc] MOV ECX,dword ptr [RBP + -0x1c] MOV R8D,dword ptr [RBP + -0x20] MOV R9D,dword ptr [RBP + -0x24] XOR EDX,EDX CALL RAX MOV RDI,qword ptr [RBP + -0x8] MOV ESI,0x1 XOR EDX,EDX CALL 0x001ec5a0 MOV RDI,qword ptr [RBP + -0x8] MOV ESI,dword ptr [RBP + -0xc] MOV RDX,qword ptr [RBP + -0x18] MOV ECX,dword ptr [RBP + -0x1c] MOV R8D,dword ptr [RBP + -0x20] MOV R9D,dword ptr [RBP + -0x24] MOV EAX,dword ptr [RBP + 0x10] XOR R10D,R10D MOV dword ptr [RSP],EAX MOV dword ptr [RSP + 0x8],0x0 CALL 0x001ec100 MOV dword ptr [RBP + -0x28],EAX CMP byte ptr [RBP + 0x18],0x0 JZ 0x001ec504 MOV RDI,qword ptr [RBP + -0x8] ADD RDI,0x58 CALL 0x001291c0 LAB_001ec504: JMP 0x001ec506 LAB_001ec506: MOV EAX,dword ptr [RBP + -0x28] ADD RSP,0x40 POP RBP RET
int4 repartition_key_cache_internal (long param_1,int4 param_2,int8 param_3,int4 param_4,int4 param_5, int4 param_6,int4 param_7,char param_8) { int4 local_30; local_30 = 0xffffffff; if (*(char *)(param_1 + 0x48) != '\0') { if (param_8 != '\0') { pthread_mutex_lock((pthread_mutex_t *)(param_1 + 0x58)); } (**(code **)(*(long *)(param_1 + 0x10) + 8)) (*(int8 *)(param_1 + 8),param_2,0,param_4,param_5,param_6); end_key_cache_internal(param_1,1,0); local_30 = init_key_cache_internal(param_1,param_2,param_3,param_4,param_5,param_6,param_7,0); if (param_8 != '\0') { pthread_mutex_unlock((pthread_mutex_t *)(param_1 + 0x58)); } } return local_30; }
27,511
spdlog::initialize_logger(std::shared_ptr<spdlog::logger>)
AlayaLite/build_O3/_deps/spdlog-src/include/spdlog/spdlog-inl.h
SPDLOG_INLINE void initialize_logger(std::shared_ptr<logger> logger) { details::registry::instance().initialize_logger(std::move(logger)); }
O3
c
spdlog::initialize_logger(std::shared_ptr<spdlog::logger>): pushq %rbx subq $0x10, %rsp movq %rdi, %rbx callq 0x2e0ae movups (%rbx), %xmm0 xorl %eax, %eax movq %rax, 0x8(%rbx) movq %rsp, %rsi movaps %xmm0, (%rsi) movq %rax, (%rbx) leaq 0x853c6(%rip), %rdi # 0xb4850 callq 0x2d5a6 movq 0x8(%rsp), %rdi addq $0x10, %rsp testq %rdi, %rdi je 0x2f4a3 popq %rbx jmp 0x1912a popq %rbx retq movq %rax, %rbx movq 0x8(%rsp), %rdi testq %rdi, %rdi je 0x2f4b7 callq 0x1912a movq %rbx, %rdi callq 0x11760
_ZN6spdlog17initialize_loggerESt10shared_ptrINS_6loggerEE: push rbx sub rsp, 10h mov rbx, rdi call _ZN6spdlog7details8registry8instanceEv; spdlog::details::registry::instance(void) movups xmm0, xmmword ptr [rbx] xor eax, eax mov [rbx+8], rax mov rsi, rsp movaps xmmword ptr [rsi], xmm0 mov [rbx], rax lea rdi, _ZZN6spdlog7details8registry8instanceEvE10s_instance; int call _ZN6spdlog7details8registry17initialize_loggerESt10shared_ptrINS_6loggerEE; spdlog::details::registry::initialize_logger(std::shared_ptr<spdlog::logger>) mov rdi, [rsp+18h+var_10] add rsp, 10h test rdi, rdi jz short loc_2F4A3 pop rbx jmp _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void) loc_2F4A3: pop rbx retn mov rbx, rax mov rdi, [rsp+arg_0] test rdi, rdi jz short loc_2F4B7 call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void) loc_2F4B7: mov rdi, rbx call __Unwind_Resume
long long spdlog::initialize_logger(spdlog::details::registry *a1) { __int128 v1; // xmm0 long long result; // rax __int128 v3; // [rsp+0h] [rbp-18h] BYREF spdlog::details::registry::instance(a1); v1 = *(_OWORD *)a1; *((_QWORD *)a1 + 1) = 0LL; v3 = v1; *(_QWORD *)a1 = 0LL; result = spdlog::details::registry::initialize_logger( (long long)&spdlog::details::registry::instance(void)::s_instance, &v3); if ( *((_QWORD *)&v3 + 1) ) return std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(*((volatile signed __int32 **)&v3 + 1)); return result; }
initialize_logger: PUSH RBX SUB RSP,0x10 MOV RBX,RDI CALL 0x0012e0ae MOVUPS XMM0,xmmword ptr [RBX] XOR EAX,EAX MOV qword ptr [RBX + 0x8],RAX MOV RSI,RSP MOVAPS xmmword ptr [RSI],XMM0 MOV qword ptr [RBX],RAX LAB_0012f483: LEA RDI,[0x1b4850] CALL 0x0012d5a6 LAB_0012f48f: MOV RDI,qword ptr [RSP + 0x8] ADD RSP,0x10 TEST RDI,RDI JZ 0x0012f4a3 POP RBX JMP 0x0011912a LAB_0012f4a3: POP RBX RET
/* spdlog::initialize_logger(std::shared_ptr<spdlog::logger>) */ void spdlog::initialize_logger(int8 *param_1) { _Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *this; details::registry::instance(); this = (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)param_1[1]; param_1[1] = 0; *param_1 = 0; /* try { // try from 0012f483 to 0012f48e has its CatchHandler @ 0012f4a5 */ details::registry::initialize_logger((registry *)details::registry::instance()::s_instance); if (this != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) { std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(this); return; } return; }
27,512
JS_GetScriptOrModuleName
bluesky950520[P]quickjs/quickjs.c
JSAtom JS_GetScriptOrModuleName(JSContext *ctx, int n_stack_levels) { JSStackFrame *sf; JSFunctionBytecode *b; JSObject *p; /* XXX: currently we just use the filename of the englobing function. It does not work for eval(). Need to add a ScriptOrModule info in JSFunctionBytecode */ sf = ctx->rt->current_stack_frame; if (!sf) return JS_ATOM_NULL; while (n_stack_levels-- > 0) { sf = sf->prev_frame; if (!sf) return JS_ATOM_NULL; } if (JS_VALUE_GET_TAG(sf->cur_func) != JS_TAG_OBJECT) return JS_ATOM_NULL; p = JS_VALUE_GET_OBJ(sf->cur_func); if (!js_class_has_bytecode(p->class_id)) return JS_ATOM_NULL; b = p->u.func.function_bytecode; return JS_DupAtom(ctx, b->filename); }
O1
c
JS_GetScriptOrModuleName: movq 0x18(%rdi), %rcx movq 0x108(%rcx), %rdx xorl %eax, %eax testq %rdx, %rdx je 0x30e7c incl %esi decl %esi testl %esi, %esi jle 0x30e7d movq (%rdx), %rdx testq %rdx, %rdx jne 0x30e6e retq cmpl $-0x1, 0x10(%rdx) jne 0x30e7c movq 0x8(%rdx), %rdx movzwl 0x6(%rdx), %esi cmpq $0x38, %rsi ja 0x30e7c movabsq $0x110000000012000, %rdi # imm = 0x110000000012000 btq %rsi, %rdi jae 0x30e7c movq 0x30(%rdx), %rax movslq 0x68(%rax), %rax cmpq $0xe0, %rax jl 0x30e7c movq 0x68(%rcx), %rcx movq (%rcx,%rax,8), %rcx incl (%rcx) retq
JS_GetScriptOrModuleName: mov rcx, [rdi+18h] mov rdx, [rcx+108h] xor eax, eax test rdx, rdx jz short locret_30E7C inc esi loc_30E6E: dec esi test esi, esi jle short loc_30E7D mov rdx, [rdx] test rdx, rdx jnz short loc_30E6E locret_30E7C: retn loc_30E7D: cmp dword ptr [rdx+10h], 0FFFFFFFFh jnz short locret_30E7C mov rdx, [rdx+8] movzx esi, word ptr [rdx+6] cmp rsi, 38h ; '8' ja short locret_30E7C mov rdi, 110000000012000h bt rdi, rsi jnb short locret_30E7C mov rax, [rdx+30h] movsxd rax, dword ptr [rax+68h] cmp rax, 0E0h jl short locret_30E7C mov rcx, [rcx+68h] mov rcx, [rcx+rax*8] inc dword ptr [rcx] retn
long long JS_GetScriptOrModuleName(long long a1, int a2) { long long v2; // rcx long long *v3; // rdx long long result; // rax int v5; // esi long long v6; // rdx unsigned long long v7; // rsi long long v8; // rdi _DWORD *v9; // rcx v2 = *(_QWORD *)(a1 + 24); v3 = *(long long **)(v2 + 264); result = 0LL; if ( v3 ) { v5 = a2 + 1; while ( --v5 > 0 ) { v3 = (long long *)*v3; if ( !v3 ) return result; } if ( *((_DWORD *)v3 + 4) == -1 ) { v6 = v3[1]; v7 = *(unsigned __int16 *)(v6 + 6); if ( v7 <= 0x38 ) { v8 = 0x110000000012000LL; if ( _bittest64(&v8, v7) ) { result = *(int *)(*(_QWORD *)(v6 + 48) + 104LL); if ( result >= 224 ) { v9 = *(_DWORD **)(*(_QWORD *)(v2 + 104) + 8 * result); ++*v9; } } } } } return result; }
27,513
JS_GetScriptOrModuleName
bluesky950520[P]quickjs/quickjs.c
JSAtom JS_GetScriptOrModuleName(JSContext *ctx, int n_stack_levels) { JSStackFrame *sf; JSFunctionBytecode *b; JSObject *p; /* XXX: currently we just use the filename of the englobing function. It does not work for eval(). Need to add a ScriptOrModule info in JSFunctionBytecode */ sf = ctx->rt->current_stack_frame; if (!sf) return JS_ATOM_NULL; while (n_stack_levels-- > 0) { sf = sf->prev_frame; if (!sf) return JS_ATOM_NULL; } if (JS_VALUE_GET_TAG(sf->cur_func) != JS_TAG_OBJECT) return JS_ATOM_NULL; p = JS_VALUE_GET_OBJ(sf->cur_func); if (!js_class_has_bytecode(p->class_id)) return JS_ATOM_NULL; b = p->u.func.function_bytecode; return JS_DupAtom(ctx, b->filename); }
O2
c
JS_GetScriptOrModuleName: movq 0x18(%rdi), %rcx movq 0x108(%rcx), %rdx xorl %eax, %eax testq %rdx, %rdx je 0x29442 incl %esi decl %esi testl %esi, %esi jle 0x29443 movq (%rdx), %rdx testq %rdx, %rdx jne 0x29434 retq cmpl $-0x1, 0x10(%rdx) jne 0x29442 movq 0x8(%rdx), %rdx movzwl 0x6(%rdx), %esi cmpq $0x38, %rsi ja 0x29442 movabsq $0x110000000012000, %rdi # imm = 0x110000000012000 btq %rsi, %rdi jae 0x29442 movq 0x30(%rdx), %rax movslq 0x68(%rax), %rax cmpq $0xe0, %rax jl 0x29442 movq 0x68(%rcx), %rcx movq (%rcx,%rax,8), %rcx incl (%rcx) retq
JS_GetScriptOrModuleName: mov rcx, [rdi+18h] mov rdx, [rcx+108h] xor eax, eax test rdx, rdx jz short locret_29442 inc esi loc_29434: dec esi test esi, esi jle short loc_29443 mov rdx, [rdx] test rdx, rdx jnz short loc_29434 locret_29442: retn loc_29443: cmp dword ptr [rdx+10h], 0FFFFFFFFh jnz short locret_29442 mov rdx, [rdx+8] movzx esi, word ptr [rdx+6] cmp rsi, 38h ; '8' ja short locret_29442 mov rdi, 110000000012000h bt rdi, rsi jnb short locret_29442 mov rax, [rdx+30h] movsxd rax, dword ptr [rax+68h] cmp rax, 0E0h jl short locret_29442 mov rcx, [rcx+68h] mov rcx, [rcx+rax*8] inc dword ptr [rcx] retn
long long JS_GetScriptOrModuleName(long long a1, int a2) { long long v2; // rcx long long *v3; // rdx long long result; // rax int v5; // esi long long v6; // rdx unsigned long long v7; // rsi long long v8; // rdi _DWORD *v9; // rcx v2 = *(_QWORD *)(a1 + 24); v3 = *(long long **)(v2 + 264); result = 0LL; if ( v3 ) { v5 = a2 + 1; while ( --v5 > 0 ) { v3 = (long long *)*v3; if ( !v3 ) return result; } if ( *((_DWORD *)v3 + 4) == -1 ) { v6 = v3[1]; v7 = *(unsigned __int16 *)(v6 + 6); if ( v7 <= 0x38 ) { v8 = 0x110000000012000LL; if ( _bittest64(&v8, v7) ) { result = *(int *)(*(_QWORD *)(v6 + 48) + 104LL); if ( result >= 224 ) { v9 = *(_DWORD **)(*(_QWORD *)(v2 + 104) + 8 * result); ++*v9; } } } } } return result; }
JS_GetScriptOrModuleName: MOV RCX,qword ptr [RDI + 0x18] MOV RDX,qword ptr [RCX + 0x108] XOR EAX,EAX TEST RDX,RDX JZ 0x00129442 INC ESI LAB_00129434: DEC ESI TEST ESI,ESI JLE 0x00129443 MOV RDX,qword ptr [RDX] TEST RDX,RDX JNZ 0x00129434 LAB_00129442: RET LAB_00129443: CMP dword ptr [RDX + 0x10],-0x1 JNZ 0x00129442 MOV RDX,qword ptr [RDX + 0x8] MOVZX ESI,word ptr [RDX + 0x6] CMP RSI,0x38 JA 0x00129442 MOV RDI,0x110000000012000 BT RDI,RSI JNC 0x00129442 MOV RAX,qword ptr [RDX + 0x30] MOVSXD RAX,dword ptr [RAX + 0x68] CMP RAX,0xe0 JL 0x00129442 MOV RCX,qword ptr [RCX + 0x68] MOV RCX,qword ptr [RCX + RAX*0x8] INC dword ptr [RCX] RET
long JS_GetScriptOrModuleName(long param_1,int param_2) { int *piVar1; long lVar2; long *plVar3; ulong uVar4; plVar3 = *(long **)(*(long *)(param_1 + 0x18) + 0x108); if (plVar3 != (long *)0x0) { param_2 = param_2 + 1; do { param_2 = param_2 + -1; if (param_2 < 1) { if ((int)plVar3[2] != -1) { return 0; } uVar4 = (ulong)*(ushort *)(plVar3[1] + 6); if (0x38 < uVar4) { return 0; } if ((0x110000000012000U >> (uVar4 & 0x3f) & 1) == 0) { return 0; } lVar2 = (long)*(int *)(*(long *)(plVar3[1] + 0x30) + 0x68); if (lVar2 < 0xe0) { return lVar2; } piVar1 = *(int **)(*(long *)(*(long *)(param_1 + 0x18) + 0x68) + lVar2 * 8); *piVar1 = *piVar1 + 1; return lVar2; } plVar3 = (long *)*plVar3; } while (plVar3 != (long *)0x0); } return 0; }
27,514
OpenSubdiv::v3_6_0::Far::GregoryConverter<float>::resizeMatrixIsolatedIrregular(OpenSubdiv::v3_6_0::Far::SparseMatrix<float>&, int, int) const
NVIDIA-RTX[P]OSD-Lite/opensubdiv/far/catmarkPatchBuilder.cpp
void GregoryConverter<REAL>::resizeMatrixIsolatedIrregular( Matrix & matrix, int cornerIndex, int cornerValence) const { int irregRingSize = 1 + 2 * cornerValence; int irregCorner = cornerIndex; int irregPlus = (cornerIndex + 1) & 0x3; int irregOpposite = (cornerIndex + 2) & 0x3; int irregMinus = (cornerIndex + 3) & 0x3; int rowSizes[20]; int * rowSizePtr = 0; rowSizePtr = rowSizes + irregCorner * 5; *rowSizePtr++ = irregRingSize; *rowSizePtr++ = irregRingSize; *rowSizePtr++ = irregRingSize; *rowSizePtr++ = irregRingSize; *rowSizePtr++ = irregRingSize; rowSizePtr = rowSizes + irregPlus * 5; *rowSizePtr++ = 9; *rowSizePtr++ = 6; *rowSizePtr++ = 6; *rowSizePtr++ = 4; *rowSizePtr++ = 3 + irregRingSize; rowSizePtr = rowSizes + irregOpposite * 5; *rowSizePtr++ = 9; *rowSizePtr++ = 6; *rowSizePtr++ = 6; *rowSizePtr++ = 4; *rowSizePtr++ = 4; rowSizePtr = rowSizes + irregMinus * 5; *rowSizePtr++ = 9; *rowSizePtr++ = 6; *rowSizePtr++ = 6; *rowSizePtr++ = 3 + irregRingSize; *rowSizePtr++ = 4; int numElements = 7*irregRingSize + 85; _resizeMatrix(matrix, 20, _numSourcePoints, numElements, rowSizes); }
O0
cpp
OpenSubdiv::v3_6_0::Far::GregoryConverter<float>::resizeMatrixIsolatedIrregular(OpenSubdiv::v3_6_0::Far::SparseMatrix<float>&, int, int) const: pushq %rbp movq %rsp, %rbp subq $0x90, %rsp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movl %edx, -0x14(%rbp) movl %ecx, -0x18(%rbp) movq -0x8(%rbp), %rax movl -0x18(%rbp), %ecx shll %ecx addl $0x1, %ecx movl %ecx, -0x1c(%rbp) movl -0x14(%rbp), %ecx movl %ecx, -0x20(%rbp) movl -0x14(%rbp), %ecx addl $0x1, %ecx andl $0x3, %ecx movl %ecx, -0x24(%rbp) movl -0x14(%rbp), %ecx addl $0x2, %ecx andl $0x3, %ecx movl %ecx, -0x28(%rbp) movl -0x14(%rbp), %ecx addl $0x3, %ecx andl $0x3, %ecx movl %ecx, -0x2c(%rbp) movq $0x0, -0x88(%rbp) leaq -0x80(%rbp), %rcx imull $0x5, -0x20(%rbp), %edx movslq %edx, %rdx shlq $0x2, %rdx addq %rdx, %rcx movq %rcx, -0x88(%rbp) movl -0x1c(%rbp), %edx movq -0x88(%rbp), %rcx movq %rcx, %rsi addq $0x4, %rsi movq %rsi, -0x88(%rbp) movl %edx, (%rcx) movl -0x1c(%rbp), %edx movq -0x88(%rbp), %rcx movq %rcx, %rsi addq $0x4, %rsi movq %rsi, -0x88(%rbp) movl %edx, (%rcx) movl -0x1c(%rbp), %edx movq -0x88(%rbp), %rcx movq %rcx, %rsi addq $0x4, %rsi movq %rsi, -0x88(%rbp) movl %edx, (%rcx) movl -0x1c(%rbp), %edx movq -0x88(%rbp), %rcx movq %rcx, %rsi addq $0x4, %rsi movq %rsi, -0x88(%rbp) movl %edx, (%rcx) movl -0x1c(%rbp), %edx movq -0x88(%rbp), %rcx movq %rcx, %rsi addq $0x4, %rsi movq %rsi, -0x88(%rbp) movl %edx, (%rcx) leaq -0x80(%rbp), %rcx imull $0x5, -0x24(%rbp), %edx movslq %edx, %rdx shlq $0x2, %rdx addq %rdx, %rcx movq %rcx, -0x88(%rbp) movq -0x88(%rbp), %rcx movq %rcx, %rdx addq $0x4, %rdx movq %rdx, -0x88(%rbp) movl $0x9, (%rcx) movq -0x88(%rbp), %rcx movq %rcx, %rdx addq $0x4, %rdx movq %rdx, -0x88(%rbp) movl $0x6, (%rcx) movq -0x88(%rbp), %rcx movq %rcx, %rdx addq $0x4, %rdx movq %rdx, -0x88(%rbp) movl $0x6, (%rcx) movq -0x88(%rbp), %rcx movq %rcx, %rdx addq $0x4, %rdx movq %rdx, -0x88(%rbp) movl $0x4, (%rcx) movl -0x1c(%rbp), %edx addl $0x3, %edx movq -0x88(%rbp), %rcx movq %rcx, %rsi addq $0x4, %rsi movq %rsi, -0x88(%rbp) movl %edx, (%rcx) leaq -0x80(%rbp), %rcx imull $0x5, -0x28(%rbp), %edx movslq %edx, %rdx shlq $0x2, %rdx addq %rdx, %rcx movq %rcx, -0x88(%rbp) movq -0x88(%rbp), %rcx movq %rcx, %rdx addq $0x4, %rdx movq %rdx, -0x88(%rbp) movl $0x9, (%rcx) movq -0x88(%rbp), %rcx movq %rcx, %rdx addq $0x4, %rdx movq %rdx, -0x88(%rbp) movl $0x6, (%rcx) movq -0x88(%rbp), %rcx movq %rcx, %rdx addq $0x4, %rdx movq %rdx, -0x88(%rbp) movl $0x6, (%rcx) movq -0x88(%rbp), %rcx movq %rcx, %rdx addq $0x4, %rdx movq %rdx, -0x88(%rbp) movl $0x4, (%rcx) movq -0x88(%rbp), %rcx movq %rcx, %rdx addq $0x4, %rdx movq %rdx, -0x88(%rbp) movl $0x4, (%rcx) leaq -0x80(%rbp), %rcx imull $0x5, -0x2c(%rbp), %edx movslq %edx, %rdx shlq $0x2, %rdx addq %rdx, %rcx movq %rcx, -0x88(%rbp) movq -0x88(%rbp), %rcx movq %rcx, %rdx addq $0x4, %rdx movq %rdx, -0x88(%rbp) movl $0x9, (%rcx) movq -0x88(%rbp), %rcx movq %rcx, %rdx addq $0x4, %rdx movq %rdx, -0x88(%rbp) movl $0x6, (%rcx) movq -0x88(%rbp), %rcx movq %rcx, %rdx addq $0x4, %rdx movq %rdx, -0x88(%rbp) movl $0x6, (%rcx) movl -0x1c(%rbp), %edx addl $0x3, %edx movq -0x88(%rbp), %rcx movq %rcx, %rsi addq $0x4, %rsi movq %rsi, -0x88(%rbp) movl %edx, (%rcx) movq -0x88(%rbp), %rcx movq %rcx, %rdx addq $0x4, %rdx movq %rdx, -0x88(%rbp) movl $0x4, (%rcx) imull $0x7, -0x1c(%rbp), %ecx addl $0x55, %ecx movl %ecx, -0x8c(%rbp) movq -0x10(%rbp), %rdi movl (%rax), %edx movl -0x8c(%rbp), %ecx leaq -0x80(%rbp), %r8 movl $0x14, %esi callq 0x10c930 addq $0x90, %rsp popq %rbp retq nopl (%rax)
_ZNK10OpenSubdiv6v3_6_03Far16GregoryConverterIdE29resizeMatrixIsolatedIrregularERNS1_12SparseMatrixIdEEii: push rbp mov rbp, rsp sub rsp, 90h mov [rbp+var_8], rdi mov [rbp+var_10], rsi mov [rbp+var_14], edx mov [rbp+var_18], ecx mov rax, [rbp+var_8] mov ecx, [rbp+var_18] shl ecx, 1 add ecx, 1 mov [rbp+var_1C], ecx mov ecx, [rbp+var_14] mov [rbp+var_20], ecx mov ecx, [rbp+var_14] add ecx, 1 and ecx, 3 mov [rbp+var_24], ecx mov ecx, [rbp+var_14] add ecx, 2 and ecx, 3 mov [rbp+var_28], ecx mov ecx, [rbp+var_14] add ecx, 3 and ecx, 3 mov [rbp+var_2C], ecx mov [rbp+var_88], 0 lea rcx, [rbp+var_80] imul edx, [rbp+var_20], 5 movsxd rdx, edx shl rdx, 2 add rcx, rdx mov [rbp+var_88], rcx mov edx, [rbp+var_1C] mov rcx, [rbp+var_88] mov rsi, rcx add rsi, 4 mov [rbp+var_88], rsi mov [rcx], edx mov edx, [rbp+var_1C] mov rcx, [rbp+var_88] mov rsi, rcx add rsi, 4 mov [rbp+var_88], rsi mov [rcx], edx mov edx, [rbp+var_1C] mov rcx, [rbp+var_88] mov rsi, rcx add rsi, 4 mov [rbp+var_88], rsi mov [rcx], edx mov edx, [rbp+var_1C] mov rcx, [rbp+var_88] mov rsi, rcx add rsi, 4 mov [rbp+var_88], rsi mov [rcx], edx mov edx, [rbp+var_1C] mov rcx, [rbp+var_88] mov rsi, rcx add rsi, 4 mov [rbp+var_88], rsi mov [rcx], edx lea rcx, [rbp+var_80] imul edx, [rbp+var_24], 5 movsxd rdx, edx shl rdx, 2 add rcx, rdx mov [rbp+var_88], rcx mov rcx, [rbp+var_88] mov rdx, rcx add rdx, 4 mov [rbp+var_88], rdx mov dword ptr [rcx], 9 mov rcx, [rbp+var_88] mov rdx, rcx add rdx, 4 mov [rbp+var_88], rdx mov dword ptr [rcx], 6 mov rcx, [rbp+var_88] mov rdx, rcx add rdx, 4 mov [rbp+var_88], rdx mov dword ptr [rcx], 6 mov rcx, [rbp+var_88] mov rdx, rcx add rdx, 4 mov [rbp+var_88], rdx mov dword ptr [rcx], 4 mov edx, [rbp+var_1C] add edx, 3 mov rcx, [rbp+var_88] mov rsi, rcx add rsi, 4 mov [rbp+var_88], rsi mov [rcx], edx lea rcx, [rbp+var_80] imul edx, [rbp+var_28], 5 movsxd rdx, edx shl rdx, 2 add rcx, rdx mov [rbp+var_88], rcx mov rcx, [rbp+var_88] mov rdx, rcx add rdx, 4 mov [rbp+var_88], rdx mov dword ptr [rcx], 9 mov rcx, [rbp+var_88] mov rdx, rcx add rdx, 4 mov [rbp+var_88], rdx mov dword ptr [rcx], 6 mov rcx, [rbp+var_88] mov rdx, rcx add rdx, 4 mov [rbp+var_88], rdx mov dword ptr [rcx], 6 mov rcx, [rbp+var_88] mov rdx, rcx add rdx, 4 mov [rbp+var_88], rdx mov dword ptr [rcx], 4 mov rcx, [rbp+var_88] mov rdx, rcx add rdx, 4 mov [rbp+var_88], rdx mov dword ptr [rcx], 4 lea rcx, [rbp+var_80] imul edx, [rbp+var_2C], 5 movsxd rdx, edx shl rdx, 2 add rcx, rdx mov [rbp+var_88], rcx mov rcx, [rbp+var_88] mov rdx, rcx add rdx, 4 mov [rbp+var_88], rdx mov dword ptr [rcx], 9 mov rcx, [rbp+var_88] mov rdx, rcx add rdx, 4 mov [rbp+var_88], rdx mov dword ptr [rcx], 6 mov rcx, [rbp+var_88] mov rdx, rcx add rdx, 4 mov [rbp+var_88], rdx mov dword ptr [rcx], 6 mov edx, [rbp+var_1C] add edx, 3 mov rcx, [rbp+var_88] mov rsi, rcx add rsi, 4 mov [rbp+var_88], rsi mov [rcx], edx mov rcx, [rbp+var_88] mov rdx, rcx add rdx, 4 mov [rbp+var_88], rdx mov dword ptr [rcx], 4 imul ecx, [rbp+var_1C], 7 add ecx, 55h ; 'U' mov [rbp+var_8C], ecx mov rdi, [rbp+var_10] mov edx, [rax] mov ecx, [rbp+var_8C] lea r8, [rbp+var_80] mov esi, 14h call _ZN10OpenSubdiv6v3_6_03Far12_GLOBAL__N_113_resizeMatrixIdEEvRNS1_12SparseMatrixIT_EEiiiPKi; OpenSubdiv::v3_6_0::Far::`anonymous namespace'::_resizeMatrix<double>(OpenSubdiv::v3_6_0::Far::SparseMatrix<double> &,int,int,int,int const*) add rsp, 90h pop rbp retn
long long OpenSubdiv::v3_6_0::Far::GregoryConverter<double>::resizeMatrixIsolatedIrregular( unsigned int *a1, long long a2, int a3, int a4) { int *v5; // [rsp+8h] [rbp-88h] _DWORD *v6; // [rsp+8h] [rbp-88h] _DWORD *v7; // [rsp+8h] [rbp-88h] _DWORD *v8; // [rsp+8h] [rbp-88h] _DWORD v9[21]; // [rsp+10h] [rbp-80h] BYREF int v10; // [rsp+64h] [rbp-2Ch] int v11; // [rsp+68h] [rbp-28h] int v12; // [rsp+6Ch] [rbp-24h] int v13; // [rsp+70h] [rbp-20h] int v14; // [rsp+74h] [rbp-1Ch] int v15; // [rsp+78h] [rbp-18h] int v16; // [rsp+7Ch] [rbp-14h] long long v17; // [rsp+80h] [rbp-10h] unsigned int *v18; // [rsp+88h] [rbp-8h] v18 = a1; v17 = a2; v16 = a3; v15 = a4; v14 = 2 * a4 + 1; v13 = a3; v12 = ((_BYTE)a3 + 1) & 3; v11 = ((_BYTE)a3 + 2) & 3; v10 = ((_BYTE)a3 + 3) & 3; v5 = &v9[5 * a3]; *v5 = v14; v5[1] = v14; v5[2] = v14; v5[3] = v14; v5[4] = v14; v6 = &v9[5 * v12 + 1]; v9[5 * v12] = 9; *v6 = 6; v6[1] = 6; v6[2] = 4; v6[3] = v14 + 3; v7 = &v9[5 * v11 + 1]; v9[5 * v11] = 9; *v7 = 6; v7[1] = 6; v7[2] = 4; v7[3] = 4; v8 = &v9[5 * v10 + 1]; v9[5 * v10] = 9; *v8 = 6; v8[1] = 6; v8[2] = v14 + 3; v8[3] = 4; return OpenSubdiv::v3_6_0::Far::`anonymous namespace'::_resizeMatrix<double>( v17, 0x14u, *a1, 7 * v14 + 85, (long long)v9); }
27,515
OpenSubdiv::v3_6_0::Far::GregoryConverter<float>::resizeMatrixIsolatedIrregular(OpenSubdiv::v3_6_0::Far::SparseMatrix<float>&, int, int) const
NVIDIA-RTX[P]OSD-Lite/opensubdiv/far/catmarkPatchBuilder.cpp
void GregoryConverter<REAL>::resizeMatrixIsolatedIrregular( Matrix & matrix, int cornerIndex, int cornerValence) const { int irregRingSize = 1 + 2 * cornerValence; int irregCorner = cornerIndex; int irregPlus = (cornerIndex + 1) & 0x3; int irregOpposite = (cornerIndex + 2) & 0x3; int irregMinus = (cornerIndex + 3) & 0x3; int rowSizes[20]; int * rowSizePtr = 0; rowSizePtr = rowSizes + irregCorner * 5; *rowSizePtr++ = irregRingSize; *rowSizePtr++ = irregRingSize; *rowSizePtr++ = irregRingSize; *rowSizePtr++ = irregRingSize; *rowSizePtr++ = irregRingSize; rowSizePtr = rowSizes + irregPlus * 5; *rowSizePtr++ = 9; *rowSizePtr++ = 6; *rowSizePtr++ = 6; *rowSizePtr++ = 4; *rowSizePtr++ = 3 + irregRingSize; rowSizePtr = rowSizes + irregOpposite * 5; *rowSizePtr++ = 9; *rowSizePtr++ = 6; *rowSizePtr++ = 6; *rowSizePtr++ = 4; *rowSizePtr++ = 4; rowSizePtr = rowSizes + irregMinus * 5; *rowSizePtr++ = 9; *rowSizePtr++ = 6; *rowSizePtr++ = 6; *rowSizePtr++ = 3 + irregRingSize; *rowSizePtr++ = 4; int numElements = 7*irregRingSize + 85; _resizeMatrix(matrix, 20, _numSourcePoints, numElements, rowSizes); }
O1
cpp
OpenSubdiv::v3_6_0::Far::GregoryConverter<float>::resizeMatrixIsolatedIrregular(OpenSubdiv::v3_6_0::Far::SparseMatrix<float>&, int, int) const: subq $0x58, %rsp movq %rsi, %rax leal 0x1(,%rcx,2), %esi addl %ecx, %ecx leal 0x1(%rdx), %r9d andl $0x3, %r9d leal -0x1(%rdx), %r8d leal (%rdx,%rdx,4), %r10d andl $0x3, %edx xorl $0x2, %edx andl $0x3, %r8d movslq %r10d, %r10 movl %esi, (%rsp,%r10,4) movl %esi, 0x4(%rsp,%r10,4) movl %esi, 0x8(%rsp,%r10,4) movl %esi, 0xc(%rsp,%r10,4) movl %esi, 0x10(%rsp,%r10,4) shll $0x2, %r9d leal (%r9,%r9,4), %r9d movaps 0x6635c(%rip), %xmm0 # 0xb4570 movups %xmm0, (%rsp,%r9) movl $0x4, %r10d leal (%rcx,%r10), %r11d movl %r11d, 0x10(%rsp,%r9) shll $0x2, %edx leal (%rdx,%rdx,4), %edx movups %xmm0, (%rsp,%rdx) movl %r10d, 0x10(%rsp,%rdx) shll $0x2, %r8d leal (%r8,%r8,4), %edx movabsq $0x600000009, %r8 # imm = 0x600000009 movq %r8, (%rsp,%rdx) movl $0x6, 0x8(%rsp,%rdx) movl %r11d, 0xc(%rsp,%rdx) movl %r10d, 0x10(%rsp,%rdx) leal 0x8(,%rcx,8), %edx subl %esi, %edx addl $0x55, %edx movl (%rdi), %esi movq %rsp, %rcx movq %rax, %rdi callq 0x4cc4d addq $0x58, %rsp retq nop
_ZNK10OpenSubdiv6v3_6_03Far16GregoryConverterIfE29resizeMatrixIsolatedIrregularERNS1_12SparseMatrixIfEEii: sub rsp, 58h mov rax, rsi lea esi, ds:1[rcx*2] add ecx, ecx lea r9d, [rdx+1] and r9d, 3 lea r8d, [rdx-1] lea r10d, [rdx+rdx*4] and edx, 3 xor edx, 2 and r8d, 3 movsxd r10, r10d mov dword ptr [rsp+r10*4+58h+var_58], esi mov dword ptr [rsp+r10*4+58h+var_58+4], esi mov dword ptr [rsp+r10*4+58h+var_58+8], esi mov dword ptr [rsp+r10*4+58h+var_58+0Ch], esi mov [rsp+r10*4+58h+var_48], esi shl r9d, 2 lea r9d, [r9+r9*4] movaps xmm0, cs:xmmword_B4570 movups [rsp+r9+58h+var_58], xmm0 mov r10d, 4 lea r11d, [rcx+r10] mov [rsp+r9+58h+var_48], r11d shl edx, 2 lea edx, [rdx+rdx*4] movups [rsp+rdx+58h+var_58], xmm0 mov [rsp+rdx+58h+var_48], r10d shl r8d, 2 lea edx, [r8+r8*4] mov r8, 600000009h mov qword ptr [rsp+rdx+58h+var_58], r8 mov dword ptr [rsp+rdx+58h+var_58+8], 6 mov dword ptr [rsp+rdx+58h+var_58+0Ch], r11d mov [rsp+rdx+58h+var_48], r10d lea edx, ds:8[rcx*8] sub edx, esi add edx, 55h ; 'U' mov esi, [rdi] mov rcx, rsp mov rdi, rax call _ZN10OpenSubdiv6v3_6_03Far12_GLOBAL__N_113_resizeMatrixIfEEvRNS1_12SparseMatrixIT_EEiiiPKi; OpenSubdiv::v3_6_0::Far::`anonymous namespace'::_resizeMatrix<float>(OpenSubdiv::v3_6_0::Far::SparseMatrix<float> &,int,int,int,int const*) add rsp, 58h retn
long long OpenSubdiv::v3_6_0::Far::GregoryConverter<float>::resizeMatrixIsolatedIrregular( int *a1, int *a2, int a3, int a4) { int v5; // esi int v6; // ecx char v7; // r8 int v8; // r10d long long v9; // rdx long long v10; // rdx _BYTE v12[88]; // [rsp+0h] [rbp-58h] BYREF v5 = 2 * a4 + 1; v6 = 2 * a4; v7 = a3 - 1; v8 = 5 * a3; *(_DWORD *)&v12[4 * v8] = v5; *(_DWORD *)&v12[4 * v8 + 4] = v5; *(_DWORD *)&v12[4 * v8 + 8] = v5; *(_DWORD *)&v12[4 * v8 + 12] = v5; *(_DWORD *)&v12[4 * v8 + 16] = v5; *(_OWORD *)&v12[20 * (((_BYTE)a3 + 1) & 3)] = xmmword_B4570; *(_DWORD *)&v12[20 * (((_BYTE)a3 + 1) & 3) + 16] = v6 + 4; v9 = 20 * (a3 & 3 ^ 2u); *(_OWORD *)&v12[v9] = xmmword_B4570; *(_DWORD *)&v12[v9 + 16] = 4; v10 = 20 * (v7 & 3u); *(_QWORD *)&v12[v10] = 0x600000009LL; *(_DWORD *)&v12[v10 + 8] = 6; *(_DWORD *)&v12[v10 + 12] = v6 + 4; *(_DWORD *)&v12[v10 + 16] = 4; return OpenSubdiv::v3_6_0::Far::`anonymous namespace'::_resizeMatrix<float>( a2, *a1, 8 * v6 + 8 - v5 + 85, (long long)v12); }
resizeMatrixIsolatedIrregular: SUB RSP,0x58 MOV RAX,RSI LEA ESI,[0x1 + RCX*0x2] ADD ECX,ECX LEA R9D,[RDX + 0x1] AND R9D,0x3 LEA R8D,[RDX + -0x1] LEA R10D,[RDX + RDX*0x4] AND EDX,0x3 XOR EDX,0x2 AND R8D,0x3 MOVSXD R10,R10D MOV dword ptr [RSP + R10*0x4],ESI MOV dword ptr [RSP + R10*0x4 + 0x4],ESI MOV dword ptr [RSP + R10*0x4 + 0x8],ESI MOV dword ptr [RSP + R10*0x4 + 0xc],ESI MOV dword ptr [RSP + R10*0x4 + 0x10],ESI SHL R9D,0x2 LEA R9D,[R9 + R9*0x4] MOVAPS XMM0,xmmword ptr [0x001b4570] MOVUPS xmmword ptr [RSP + R9*0x1],XMM0 MOV R10D,0x4 LEA R11D,[RCX + R10*0x1] MOV dword ptr [RSP + R9*0x1 + 0x10],R11D SHL EDX,0x2 LEA EDX,[RDX + RDX*0x4] MOVUPS xmmword ptr [RSP + RDX*0x1],XMM0 MOV dword ptr [RSP + RDX*0x1 + 0x10],R10D SHL R8D,0x2 LEA EDX,[R8 + R8*0x4] MOV R8,0x600000009 MOV qword ptr [RSP + RDX*0x1],R8 MOV dword ptr [RSP + RDX*0x1 + 0x8],0x6 MOV dword ptr [RSP + RDX*0x1 + 0xc],R11D MOV dword ptr [RSP + RDX*0x1 + 0x10],R10D LEA EDX,[0x8 + RCX*0x8] SUB EDX,ESI ADD EDX,0x55 MOV ESI,dword ptr [RDI] MOV RCX,RSP MOV RDI,RAX CALL 0x0014cc4d ADD RSP,0x58 RET
/* WARNING: Globals starting with '_' overlap smaller symbols at the same address */ /* OpenSubdiv::v3_6_0::Far::GregoryConverter<float>::resizeMatrixIsolatedIrregular(OpenSubdiv::v3_6_0::Far::SparseMatrix<float>&, int, int) const */ void __thiscall OpenSubdiv::v3_6_0::Far::GregoryConverter<float>::resizeMatrixIsolatedIrregular (GregoryConverter<float> *this,SparseMatrix *param_1,int param_2,int param_3) { int iVar1; ulong uVar2; int iVar3; long lVar4; int aiStack_58 [2]; int8 uStack_50; int aiStack_48 [18]; iVar3 = param_3 * 2 + 1; lVar4 = (long)(param_2 * 5); aiStack_58[lVar4] = iVar3; aiStack_58[lVar4 + 1] = iVar3; *(int *)((long)&uStack_50 + lVar4 * 4) = iVar3; aiStack_48[lVar4 + -1] = iVar3; aiStack_48[lVar4] = iVar3; uVar2 = (ulong)((param_2 + 1U & 3) * 0x14); *(int8 *)((long)aiStack_58 + uVar2) = _DAT_001b4570; *(int8 *)((long)&uStack_50 + uVar2) = _UNK_001b4578; iVar1 = param_3 * 2 + 4; *(int *)((long)aiStack_48 + uVar2) = iVar1; uVar2 = (ulong)((param_2 & 3U ^ 2) * 0x14); *(int8 *)((long)aiStack_58 + uVar2) = _DAT_001b4570; *(int8 *)((long)&uStack_50 + uVar2) = _UNK_001b4578; *(int4 *)((long)aiStack_48 + uVar2) = 4; uVar2 = (ulong)((param_2 - 1U & 3) * 0x14); *(int8 *)((long)aiStack_58 + uVar2) = 0x600000009; *(int4 *)((long)&uStack_50 + uVar2) = 6; *(int *)((long)aiStack_48 + (uVar2 - 4)) = iVar1; *(int4 *)((long)aiStack_48 + uVar2) = 4; (anonymous_namespace)::_resizeMatrix<float> (param_1,*(int *)this,(param_3 * 0x10 - iVar3) + 0x5d,(int)aiStack_58,(int *)0x600000009 ); return; }
27,516
OpenSubdiv::v3_6_0::Far::GregoryConverter<float>::resizeMatrixIsolatedIrregular(OpenSubdiv::v3_6_0::Far::SparseMatrix<float>&, int, int) const
NVIDIA-RTX[P]OSD-Lite/opensubdiv/far/catmarkPatchBuilder.cpp
void GregoryConverter<REAL>::resizeMatrixIsolatedIrregular( Matrix & matrix, int cornerIndex, int cornerValence) const { int irregRingSize = 1 + 2 * cornerValence; int irregCorner = cornerIndex; int irregPlus = (cornerIndex + 1) & 0x3; int irregOpposite = (cornerIndex + 2) & 0x3; int irregMinus = (cornerIndex + 3) & 0x3; int rowSizes[20]; int * rowSizePtr = 0; rowSizePtr = rowSizes + irregCorner * 5; *rowSizePtr++ = irregRingSize; *rowSizePtr++ = irregRingSize; *rowSizePtr++ = irregRingSize; *rowSizePtr++ = irregRingSize; *rowSizePtr++ = irregRingSize; rowSizePtr = rowSizes + irregPlus * 5; *rowSizePtr++ = 9; *rowSizePtr++ = 6; *rowSizePtr++ = 6; *rowSizePtr++ = 4; *rowSizePtr++ = 3 + irregRingSize; rowSizePtr = rowSizes + irregOpposite * 5; *rowSizePtr++ = 9; *rowSizePtr++ = 6; *rowSizePtr++ = 6; *rowSizePtr++ = 4; *rowSizePtr++ = 4; rowSizePtr = rowSizes + irregMinus * 5; *rowSizePtr++ = 9; *rowSizePtr++ = 6; *rowSizePtr++ = 6; *rowSizePtr++ = 3 + irregRingSize; *rowSizePtr++ = 4; int numElements = 7*irregRingSize + 85; _resizeMatrix(matrix, 20, _numSourcePoints, numElements, rowSizes); }
O2
cpp
OpenSubdiv::v3_6_0::Far::GregoryConverter<float>::resizeMatrixIsolatedIrregular(OpenSubdiv::v3_6_0::Far::SparseMatrix<float>&, int, int) const: subq $0x58, %rsp movq %rsi, %rax leal 0x1(,%rcx,2), %esi addl %ecx, %ecx leal 0x1(%rdx), %r8d andl $0x3, %r8d leal -0x1(%rdx), %r9d leal (%rdx,%rdx,4), %r10d andl $0x3, %edx xorl $0x2, %edx andl $0x3, %r9d movslq %r10d, %r10 movd %esi, %xmm0 pshufd $0x0, %xmm0, %xmm0 # xmm0 = xmm0[0,0,0,0] movdqu %xmm0, (%rsp,%r10,4) movl %esi, 0x10(%rsp,%r10,4) imull $0x14, %r8d, %r8d movaps 0x58e60(%rip), %xmm0 # 0xbe580 movups %xmm0, (%rsp,%r8) pushq $0x4 popq %r10 addl %r10d, %ecx movl %ecx, 0x10(%rsp,%r8) imull $0x14, %edx, %edx movups %xmm0, (%rsp,%rdx) movl %r10d, 0x10(%rsp,%rdx) imull $0x14, %r9d, %edx movabsq $0x600000009, %r8 # imm = 0x600000009 movq %r8, (%rsp,%rdx) movl $0x6, 0x8(%rsp,%rdx) movl %ecx, 0xc(%rsp,%rdx) movl %r10d, 0x10(%rsp,%rdx) imull $0x7, %esi, %edx addl $0x55, %edx movl (%rdi), %esi movq %rsp, %rcx movq %rax, %rdi callq 0x6458d addq $0x58, %rsp retq
_ZNK10OpenSubdiv6v3_6_03Far16GregoryConverterIfE29resizeMatrixIsolatedIrregularERNS1_12SparseMatrixIfEEii: sub rsp, 58h mov rax, rsi lea esi, ds:1[rcx*2] add ecx, ecx lea r8d, [rdx+1] and r8d, 3 lea r9d, [rdx-1] lea r10d, [rdx+rdx*4] and edx, 3 xor edx, 2 and r9d, 3 movsxd r10, r10d movd xmm0, esi pshufd xmm0, xmm0, 0 movdqu [rsp+r10*4+58h+var_58], xmm0 mov [rsp+r10*4+58h+var_48], esi imul r8d, 14h movaps xmm0, cs:xmmword_BE580 movups [rsp+r8+58h+var_58], xmm0 push 4 pop r10 add ecx, r10d mov [rsp+r8+58h+var_48], ecx imul edx, 14h movups [rsp+rdx+58h+var_58], xmm0 mov [rsp+rdx+58h+var_48], r10d imul edx, r9d, 14h mov r8, 600000009h mov qword ptr [rsp+rdx+58h+var_58], r8 mov dword ptr [rsp+rdx+58h+var_58+8], 6 mov dword ptr [rsp+rdx+58h+var_58+0Ch], ecx mov [rsp+rdx+58h+var_48], r10d imul edx, esi, 7 add edx, 55h ; 'U' mov esi, [rdi] mov rcx, rsp mov rdi, rax call _ZN10OpenSubdiv6v3_6_03Far12_GLOBAL__N_113_resizeMatrixIfEEvRNS1_12SparseMatrixIT_EEiiiPKi; OpenSubdiv::v3_6_0::Far::`anonymous namespace'::_resizeMatrix<float>(OpenSubdiv::v3_6_0::Far::SparseMatrix<float> &,int,int,int,int const*) add rsp, 58h retn
long long OpenSubdiv::v3_6_0::Far::GregoryConverter<float>::resizeMatrixIsolatedIrregular( unsigned int *a1, long long a2, int a3, int a4) { unsigned int v5; // esi int v6; // r10d int v7; // r9d int v8; // ecx long long v9; // rdx _BYTE v11[88]; // [rsp+0h] [rbp-58h] BYREF v5 = 2 * a4 + 1; v6 = 5 * a3; v7 = ((_BYTE)a3 - 1) & 3; *(__m128i *)&v11[4 * v6] = _mm_shuffle_epi32(_mm_cvtsi32_si128(v5), 0); *(_DWORD *)&v11[4 * v6 + 16] = v5; *(_OWORD *)&v11[20 * (((_BYTE)a3 + 1) & 3)] = xmmword_BE580; v8 = 2 * a4 + 4; *(_DWORD *)&v11[20 * (((_BYTE)a3 + 1) & 3) + 16] = v8; v9 = 20 * (a3 & 3 ^ 2u); *(_OWORD *)&v11[v9] = xmmword_BE580; *(_DWORD *)&v11[v9 + 16] = 4; *(_QWORD *)&v11[20 * v7] = 0x600000009LL; *(_DWORD *)&v11[20 * v7 + 8] = 6; *(_DWORD *)&v11[20 * v7 + 12] = v8; *(_DWORD *)&v11[20 * v7 + 16] = 4; return OpenSubdiv::v3_6_0::Far::`anonymous namespace'::_resizeMatrix<float>(a2, *a1, 7 * v5 + 85, (long long)v11); }
resizeMatrixIsolatedIrregular: SUB RSP,0x58 MOV RAX,RSI LEA ESI,[0x1 + RCX*0x2] ADD ECX,ECX LEA R8D,[RDX + 0x1] AND R8D,0x3 LEA R9D,[RDX + -0x1] LEA R10D,[RDX + RDX*0x4] AND EDX,0x3 XOR EDX,0x2 AND R9D,0x3 MOVSXD R10,R10D MOVD XMM0,ESI PSHUFD XMM0,XMM0,0x0 MOVDQU xmmword ptr [RSP + R10*0x4],XMM0 MOV dword ptr [RSP + R10*0x4 + 0x10],ESI IMUL R8D,R8D,0x14 MOVAPS XMM0,xmmword ptr [0x001be580] MOVUPS xmmword ptr [RSP + R8*0x1],XMM0 PUSH 0x4 POP R10 ADD ECX,R10D MOV dword ptr [RSP + R8*0x1 + 0x10],ECX IMUL EDX,EDX,0x14 MOVUPS xmmword ptr [RSP + RDX*0x1],XMM0 MOV dword ptr [RSP + RDX*0x1 + 0x10],R10D IMUL EDX,R9D,0x14 MOV R8,0x600000009 MOV qword ptr [RSP + RDX*0x1],R8 MOV dword ptr [RSP + RDX*0x1 + 0x8],0x6 MOV dword ptr [RSP + RDX*0x1 + 0xc],ECX MOV dword ptr [RSP + RDX*0x1 + 0x10],R10D IMUL EDX,ESI,0x7 ADD EDX,0x55 MOV ESI,dword ptr [RDI] MOV RCX,RSP MOV RDI,RAX CALL 0x0016458d ADD RSP,0x58 RET
/* WARNING: Globals starting with '_' overlap smaller symbols at the same address */ /* OpenSubdiv::v3_6_0::Far::GregoryConverter<float>::resizeMatrixIsolatedIrregular(OpenSubdiv::v3_6_0::Far::SparseMatrix<float>&, int, int) const */ void __thiscall OpenSubdiv::v3_6_0::Far::GregoryConverter<float>::resizeMatrixIsolatedIrregular (GregoryConverter<float> *this,SparseMatrix *param_1,int param_2,int param_3) { int iVar1; ulong uVar2; int iVar3; long lVar4; int aiStack_58 [2]; int8 uStack_50; int aiStack_48 [18]; iVar3 = param_3 * 2 + 1; lVar4 = (long)(param_2 * 5); aiStack_58[lVar4] = iVar3; aiStack_58[lVar4 + 1] = iVar3; *(int *)((long)&uStack_50 + lVar4 * 4) = iVar3; aiStack_48[lVar4 + -1] = iVar3; aiStack_48[lVar4] = iVar3; uVar2 = (ulong)((param_2 + 1U & 3) * 0x14); *(int8 *)((long)aiStack_58 + uVar2) = _DAT_001be580; *(int8 *)((long)&uStack_50 + uVar2) = _UNK_001be588; iVar1 = param_3 * 2 + 4; *(int *)((long)aiStack_48 + uVar2) = iVar1; uVar2 = (ulong)((param_2 & 3U ^ 2) * 0x14); *(int8 *)((long)aiStack_58 + uVar2) = _DAT_001be580; *(int8 *)((long)&uStack_50 + uVar2) = _UNK_001be588; *(int4 *)((long)aiStack_48 + uVar2) = 4; uVar2 = (ulong)((param_2 - 1U & 3) * 0x14); *(int8 *)((long)aiStack_58 + uVar2) = 0x600000009; *(int4 *)((long)&uStack_50 + uVar2) = 6; *(int *)((long)aiStack_48 + (uVar2 - 4)) = iVar1; *(int4 *)((long)aiStack_48 + uVar2) = 4; (anonymous_namespace)::_resizeMatrix<float> (param_1,*(int *)this,iVar3 * 7 + 0x55,(int)aiStack_58,(int *)0x600000009); return; }
27,517
OpenSubdiv::v3_6_0::Far::GregoryConverter<float>::resizeMatrixIsolatedIrregular(OpenSubdiv::v3_6_0::Far::SparseMatrix<float>&, int, int) const
NVIDIA-RTX[P]OSD-Lite/opensubdiv/far/catmarkPatchBuilder.cpp
void GregoryConverter<REAL>::resizeMatrixIsolatedIrregular( Matrix & matrix, int cornerIndex, int cornerValence) const { int irregRingSize = 1 + 2 * cornerValence; int irregCorner = cornerIndex; int irregPlus = (cornerIndex + 1) & 0x3; int irregOpposite = (cornerIndex + 2) & 0x3; int irregMinus = (cornerIndex + 3) & 0x3; int rowSizes[20]; int * rowSizePtr = 0; rowSizePtr = rowSizes + irregCorner * 5; *rowSizePtr++ = irregRingSize; *rowSizePtr++ = irregRingSize; *rowSizePtr++ = irregRingSize; *rowSizePtr++ = irregRingSize; *rowSizePtr++ = irregRingSize; rowSizePtr = rowSizes + irregPlus * 5; *rowSizePtr++ = 9; *rowSizePtr++ = 6; *rowSizePtr++ = 6; *rowSizePtr++ = 4; *rowSizePtr++ = 3 + irregRingSize; rowSizePtr = rowSizes + irregOpposite * 5; *rowSizePtr++ = 9; *rowSizePtr++ = 6; *rowSizePtr++ = 6; *rowSizePtr++ = 4; *rowSizePtr++ = 4; rowSizePtr = rowSizes + irregMinus * 5; *rowSizePtr++ = 9; *rowSizePtr++ = 6; *rowSizePtr++ = 6; *rowSizePtr++ = 3 + irregRingSize; *rowSizePtr++ = 4; int numElements = 7*irregRingSize + 85; _resizeMatrix(matrix, 20, _numSourcePoints, numElements, rowSizes); }
O3
cpp
OpenSubdiv::v3_6_0::Far::GregoryConverter<float>::resizeMatrixIsolatedIrregular(OpenSubdiv::v3_6_0::Far::SparseMatrix<float>&, int, int) const: subq $0x58, %rsp movq %rsi, %rax leal 0x1(,%rcx,2), %esi addl %ecx, %ecx leal 0x1(%rdx), %r9d andl $0x3, %r9d leal -0x1(%rdx), %r8d leal (%rdx,%rdx,4), %r10d andl $0x3, %edx xorl $0x2, %edx andl $0x3, %r8d movslq %r10d, %r10 movd %esi, %xmm0 pshufd $0x0, %xmm0, %xmm0 # xmm0 = xmm0[0,0,0,0] movdqu %xmm0, (%rsp,%r10,4) movl %esi, 0x10(%rsp,%r10,4) shll $0x2, %r9d leal (%r9,%r9,4), %r9d movaps 0x63b3c(%rip), %xmm0 # 0xb7630 movups %xmm0, (%rsp,%r9) movl $0x4, %r10d leal (%rcx,%r10), %r11d movl %r11d, 0x10(%rsp,%r9) shll $0x2, %edx leal (%rdx,%rdx,4), %edx movups %xmm0, (%rsp,%rdx) movl %r10d, 0x10(%rsp,%rdx) shll $0x2, %r8d leal (%r8,%r8,4), %edx movabsq $0x600000009, %r8 # imm = 0x600000009 movq %r8, (%rsp,%rdx) movl $0x6, 0x8(%rsp,%rdx) movl %r11d, 0xc(%rsp,%rdx) movl %r10d, 0x10(%rsp,%rdx) leal 0x8(,%rcx,8), %edx subl %esi, %edx addl $0x55, %edx movl (%rdi), %esi movq %rsp, %rcx movq %rax, %rdi callq 0x4fa27 addq $0x58, %rsp retq nop
_ZNK10OpenSubdiv6v3_6_03Far16GregoryConverterIdE29resizeMatrixIsolatedIrregularERNS1_12SparseMatrixIdEEii: sub rsp, 58h mov rax, rsi lea esi, ds:1[rcx*2] add ecx, ecx lea r9d, [rdx+1] and r9d, 3 lea r8d, [rdx-1] lea r10d, [rdx+rdx*4] and edx, 3 xor edx, 2 and r8d, 3 movsxd r10, r10d movd xmm0, esi pshufd xmm0, xmm0, 0 movdqu [rsp+r10*4+58h+var_58], xmm0 mov [rsp+r10*4+58h+var_48], esi shl r9d, 2 lea r9d, [r9+r9*4] movaps xmm0, cs:xmmword_B7630 movups [rsp+r9+58h+var_58], xmm0 mov r10d, 4 lea r11d, [rcx+r10] mov [rsp+r9+58h+var_48], r11d shl edx, 2 lea edx, [rdx+rdx*4] movups [rsp+rdx+58h+var_58], xmm0 mov [rsp+rdx+58h+var_48], r10d shl r8d, 2 lea edx, [r8+r8*4] mov r8, 600000009h mov qword ptr [rsp+rdx+58h+var_58], r8 mov dword ptr [rsp+rdx+58h+var_58+8], 6 mov dword ptr [rsp+rdx+58h+var_58+0Ch], r11d mov [rsp+rdx+58h+var_48], r10d lea edx, ds:8[rcx*8] sub edx, esi add edx, 55h ; 'U' mov esi, [rdi] mov rcx, rsp mov rdi, rax call _ZN10OpenSubdiv6v3_6_03Far12_GLOBAL__N_113_resizeMatrixIdEEvRNS1_12SparseMatrixIT_EEiiiPKi; OpenSubdiv::v3_6_0::Far::`anonymous namespace'::_resizeMatrix<double>(OpenSubdiv::v3_6_0::Far::SparseMatrix<double> &,int,int,int,int const*) add rsp, 58h retn
long long OpenSubdiv::v3_6_0::Far::GregoryConverter<double>::resizeMatrixIsolatedIrregular( int *a1, int *a2, int a3, int a4) { unsigned int v5; // esi int v6; // ecx char v7; // r8 int v8; // r10d long long v9; // rdx long long v10; // rdx _BYTE v12[88]; // [rsp+0h] [rbp-58h] BYREF v5 = 2 * a4 + 1; v6 = 2 * a4; v7 = a3 - 1; v8 = 5 * a3; *(__m128i *)&v12[4 * v8] = _mm_shuffle_epi32(_mm_cvtsi32_si128(v5), 0); *(_DWORD *)&v12[4 * v8 + 16] = v5; *(_OWORD *)&v12[20 * (((_BYTE)a3 + 1) & 3)] = xmmword_B7630; *(_DWORD *)&v12[20 * (((_BYTE)a3 + 1) & 3) + 16] = v6 + 4; v9 = 20 * (a3 & 3 ^ 2u); *(_OWORD *)&v12[v9] = xmmword_B7630; *(_DWORD *)&v12[v9 + 16] = 4; v10 = 20 * (v7 & 3u); *(_QWORD *)&v12[v10] = 0x600000009LL; *(_DWORD *)&v12[v10 + 8] = 6; *(_DWORD *)&v12[v10 + 12] = v6 + 4; *(_DWORD *)&v12[v10 + 16] = 4; return OpenSubdiv::v3_6_0::Far::`anonymous namespace'::_resizeMatrix<double>( a2, *a1, 8 * v6 + 8 - v5 + 85, (long long)v12); }
resizeMatrixIsolatedIrregular: SUB RSP,0x58 MOV RAX,RSI LEA ESI,[0x1 + RCX*0x2] ADD ECX,ECX LEA R9D,[RDX + 0x1] AND R9D,0x3 LEA R8D,[RDX + -0x1] LEA R10D,[RDX + RDX*0x4] AND EDX,0x3 XOR EDX,0x2 AND R8D,0x3 MOVSXD R10,R10D MOVD XMM0,ESI PSHUFD XMM0,XMM0,0x0 MOVDQU xmmword ptr [RSP + R10*0x4],XMM0 MOV dword ptr [RSP + R10*0x4 + 0x10],ESI SHL R9D,0x2 LEA R9D,[R9 + R9*0x4] MOVAPS XMM0,xmmword ptr [0x001b7630] MOVUPS xmmword ptr [RSP + R9*0x1],XMM0 MOV R10D,0x4 LEA R11D,[RCX + R10*0x1] MOV dword ptr [RSP + R9*0x1 + 0x10],R11D SHL EDX,0x2 LEA EDX,[RDX + RDX*0x4] MOVUPS xmmword ptr [RSP + RDX*0x1],XMM0 MOV dword ptr [RSP + RDX*0x1 + 0x10],R10D SHL R8D,0x2 LEA EDX,[R8 + R8*0x4] MOV R8,0x600000009 MOV qword ptr [RSP + RDX*0x1],R8 MOV dword ptr [RSP + RDX*0x1 + 0x8],0x6 MOV dword ptr [RSP + RDX*0x1 + 0xc],R11D MOV dword ptr [RSP + RDX*0x1 + 0x10],R10D LEA EDX,[0x8 + RCX*0x8] SUB EDX,ESI ADD EDX,0x55 MOV ESI,dword ptr [RDI] MOV RCX,RSP MOV RDI,RAX CALL 0x0014fa27 ADD RSP,0x58 RET
/* WARNING: Globals starting with '_' overlap smaller symbols at the same address */ /* OpenSubdiv::v3_6_0::Far::GregoryConverter<double>::resizeMatrixIsolatedIrregular(OpenSubdiv::v3_6_0::Far::SparseMatrix<double>&, int, int) const */ void __thiscall OpenSubdiv::v3_6_0::Far::GregoryConverter<double>::resizeMatrixIsolatedIrregular (GregoryConverter<double> *this,SparseMatrix *param_1,int param_2,int param_3) { int iVar1; ulong uVar2; int iVar3; long lVar4; int aiStack_58 [2]; int8 uStack_50; int aiStack_48 [18]; iVar3 = param_3 * 2 + 1; lVar4 = (long)(param_2 * 5); aiStack_58[lVar4] = iVar3; aiStack_58[lVar4 + 1] = iVar3; *(int *)((long)&uStack_50 + lVar4 * 4) = iVar3; aiStack_48[lVar4 + -1] = iVar3; aiStack_48[lVar4] = iVar3; uVar2 = (ulong)((param_2 + 1U & 3) * 0x14); *(int8 *)((long)aiStack_58 + uVar2) = _DAT_001b7630; *(int8 *)((long)&uStack_50 + uVar2) = _UNK_001b7638; iVar1 = param_3 * 2 + 4; *(int *)((long)aiStack_48 + uVar2) = iVar1; uVar2 = (ulong)((param_2 & 3U ^ 2) * 0x14); *(int8 *)((long)aiStack_58 + uVar2) = _DAT_001b7630; *(int8 *)((long)&uStack_50 + uVar2) = _UNK_001b7638; *(int4 *)((long)aiStack_48 + uVar2) = 4; uVar2 = (ulong)((param_2 - 1U & 3) * 0x14); *(int8 *)((long)aiStack_58 + uVar2) = 0x600000009; *(int4 *)((long)&uStack_50 + uVar2) = 6; *(int *)((long)aiStack_48 + (uVar2 - 4)) = iVar1; *(int4 *)((long)aiStack_48 + uVar2) = 4; (anonymous_namespace)::_resizeMatrix<double> (param_1,*(int *)this,(param_3 * 0x10 - iVar3) + 0x5d,(int)aiStack_58,(int *)0x600000009 ); return; }
27,518
mi_keyseg_read
eloqsql/storage/myisam/mi_open.c
uchar *mi_keyseg_read(uchar *ptr, HA_KEYSEG *keyseg) { keyseg->type = *ptr++; keyseg->language = *ptr++; keyseg->null_bit = *ptr++; keyseg->bit_start = *ptr++; keyseg->language += ((uint16) (*ptr++)) << 8; keyseg->bit_length = *ptr++; keyseg->flag = mi_uint2korr(ptr); ptr +=2; keyseg->length = mi_uint2korr(ptr); ptr +=2; keyseg->start = mi_uint4korr(ptr); ptr +=4; keyseg->null_pos = mi_uint4korr(ptr); ptr +=4; keyseg->charset=0; /* Will be filled in later */ if (keyseg->null_bit) /* We adjust bit_pos if null_bit is last in the byte */ keyseg->bit_pos= (uint16)(keyseg->null_pos + (keyseg->null_bit == (1 << 7))); else { keyseg->bit_pos= (uint16)keyseg->null_pos; keyseg->null_pos= 0; } return ptr; }
O0
c
mi_keyseg_read: pushq %rbp movq %rsp, %rbp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq -0x8(%rbp), %rax movq %rax, %rcx addq $0x1, %rcx movq %rcx, -0x8(%rbp) movb (%rax), %cl movq -0x10(%rbp), %rax movb %cl, 0x18(%rax) movq -0x8(%rbp), %rax movq %rax, %rcx addq $0x1, %rcx movq %rcx, -0x8(%rbp) movzbl (%rax), %eax movw %ax, %cx movq -0x10(%rbp), %rax movw %cx, 0x16(%rax) movq -0x8(%rbp), %rax movq %rax, %rcx addq $0x1, %rcx movq %rcx, -0x8(%rbp) movb (%rax), %cl movq -0x10(%rbp), %rax movb %cl, 0x19(%rax) movq -0x8(%rbp), %rax movq %rax, %rcx addq $0x1, %rcx movq %rcx, -0x8(%rbp) movb (%rax), %cl movq -0x10(%rbp), %rax movb %cl, 0x1a(%rax) movq -0x8(%rbp), %rax movq %rax, %rcx addq $0x1, %rcx movq %rcx, -0x8(%rbp) movzbl (%rax), %eax movzwl %ax, %edx shll $0x8, %edx movq -0x10(%rbp), %rax movzwl 0x16(%rax), %ecx addl %edx, %ecx movw %cx, 0x16(%rax) movq -0x8(%rbp), %rax movq %rax, %rcx addq $0x1, %rcx movq %rcx, -0x8(%rbp) movb (%rax), %cl movq -0x10(%rbp), %rax movb %cl, 0x1b(%rax) movq -0x8(%rbp), %rax movzbl 0x1(%rax), %eax movzwl %ax, %eax movq -0x8(%rbp), %rcx movzbl (%rcx), %ecx movzwl %cx, %ecx shll $0x8, %ecx orl %ecx, %eax movw %ax, %cx movq -0x10(%rbp), %rax movw %cx, 0x12(%rax) movq -0x8(%rbp), %rax addq $0x2, %rax movq %rax, -0x8(%rbp) movq -0x8(%rbp), %rax movzbl 0x1(%rax), %eax movzwl %ax, %eax movq -0x8(%rbp), %rcx movzbl (%rcx), %ecx movzwl %cx, %ecx shll $0x8, %ecx orl %ecx, %eax movw %ax, %cx movq -0x10(%rbp), %rax movw %cx, 0x14(%rax) movq -0x8(%rbp), %rax addq $0x2, %rax movq %rax, -0x8(%rbp) movq -0x8(%rbp), %rax movzbl 0x3(%rax), %ecx movq -0x8(%rbp), %rax movzbl 0x2(%rax), %eax shll $0x8, %eax orl %eax, %ecx movq -0x8(%rbp), %rax movzbl 0x1(%rax), %eax shll $0x10, %eax orl %eax, %ecx movq -0x8(%rbp), %rax movzbl (%rax), %eax shll $0x18, %eax orl %eax, %ecx movq -0x10(%rbp), %rax movl %ecx, 0x8(%rax) movq -0x8(%rbp), %rax addq $0x4, %rax movq %rax, -0x8(%rbp) movq -0x8(%rbp), %rax movzbl 0x3(%rax), %ecx movq -0x8(%rbp), %rax movzbl 0x2(%rax), %eax shll $0x8, %eax orl %eax, %ecx movq -0x8(%rbp), %rax movzbl 0x1(%rax), %eax shll $0x10, %eax orl %eax, %ecx movq -0x8(%rbp), %rax movzbl (%rax), %eax shll $0x18, %eax orl %eax, %ecx movq -0x10(%rbp), %rax movl %ecx, 0xc(%rax) movq -0x8(%rbp), %rax addq $0x4, %rax movq %rax, -0x8(%rbp) movq -0x10(%rbp), %rax movq $0x0, (%rax) movq -0x10(%rbp), %rax cmpb $0x0, 0x19(%rax) je 0xb65d5 movq -0x10(%rbp), %rax movl 0xc(%rax), %eax movq -0x10(%rbp), %rcx movzbl 0x19(%rcx), %ecx cmpl $0x80, %ecx sete %cl andb $0x1, %cl movzbl %cl, %ecx addl %ecx, %eax movw %ax, %cx movq -0x10(%rbp), %rax movw %cx, 0x10(%rax) jmp 0xb65f2 movq -0x10(%rbp), %rax movl 0xc(%rax), %eax movw %ax, %cx movq -0x10(%rbp), %rax movw %cx, 0x10(%rax) movq -0x10(%rbp), %rax movl $0x0, 0xc(%rax) movq -0x8(%rbp), %rax popq %rbp retq nopl (%rax,%rax)
mi_keyseg_read: push rbp mov rbp, rsp mov [rbp+var_8], rdi mov [rbp+var_10], rsi mov rax, [rbp+var_8] mov rcx, rax add rcx, 1 mov [rbp+var_8], rcx mov cl, [rax] mov rax, [rbp+var_10] mov [rax+18h], cl mov rax, [rbp+var_8] mov rcx, rax add rcx, 1 mov [rbp+var_8], rcx movzx eax, byte ptr [rax] mov cx, ax mov rax, [rbp+var_10] mov [rax+16h], cx mov rax, [rbp+var_8] mov rcx, rax add rcx, 1 mov [rbp+var_8], rcx mov cl, [rax] mov rax, [rbp+var_10] mov [rax+19h], cl mov rax, [rbp+var_8] mov rcx, rax add rcx, 1 mov [rbp+var_8], rcx mov cl, [rax] mov rax, [rbp+var_10] mov [rax+1Ah], cl mov rax, [rbp+var_8] mov rcx, rax add rcx, 1 mov [rbp+var_8], rcx movzx eax, byte ptr [rax] movzx edx, ax shl edx, 8 mov rax, [rbp+var_10] movzx ecx, word ptr [rax+16h] add ecx, edx mov [rax+16h], cx mov rax, [rbp+var_8] mov rcx, rax add rcx, 1 mov [rbp+var_8], rcx mov cl, [rax] mov rax, [rbp+var_10] mov [rax+1Bh], cl mov rax, [rbp+var_8] movzx eax, byte ptr [rax+1] movzx eax, ax mov rcx, [rbp+var_8] movzx ecx, byte ptr [rcx] movzx ecx, cx shl ecx, 8 or eax, ecx mov cx, ax mov rax, [rbp+var_10] mov [rax+12h], cx mov rax, [rbp+var_8] add rax, 2 mov [rbp+var_8], rax mov rax, [rbp+var_8] movzx eax, byte ptr [rax+1] movzx eax, ax mov rcx, [rbp+var_8] movzx ecx, byte ptr [rcx] movzx ecx, cx shl ecx, 8 or eax, ecx mov cx, ax mov rax, [rbp+var_10] mov [rax+14h], cx mov rax, [rbp+var_8] add rax, 2 mov [rbp+var_8], rax mov rax, [rbp+var_8] movzx ecx, byte ptr [rax+3] mov rax, [rbp+var_8] movzx eax, byte ptr [rax+2] shl eax, 8 or ecx, eax mov rax, [rbp+var_8] movzx eax, byte ptr [rax+1] shl eax, 10h or ecx, eax mov rax, [rbp+var_8] movzx eax, byte ptr [rax] shl eax, 18h or ecx, eax mov rax, [rbp+var_10] mov [rax+8], ecx mov rax, [rbp+var_8] add rax, 4 mov [rbp+var_8], rax mov rax, [rbp+var_8] movzx ecx, byte ptr [rax+3] mov rax, [rbp+var_8] movzx eax, byte ptr [rax+2] shl eax, 8 or ecx, eax mov rax, [rbp+var_8] movzx eax, byte ptr [rax+1] shl eax, 10h or ecx, eax mov rax, [rbp+var_8] movzx eax, byte ptr [rax] shl eax, 18h or ecx, eax mov rax, [rbp+var_10] mov [rax+0Ch], ecx mov rax, [rbp+var_8] add rax, 4 mov [rbp+var_8], rax mov rax, [rbp+var_10] mov qword ptr [rax], 0 mov rax, [rbp+var_10] cmp byte ptr [rax+19h], 0 jz short loc_B65D5 mov rax, [rbp+var_10] mov eax, [rax+0Ch] mov rcx, [rbp+var_10] movzx ecx, byte ptr [rcx+19h] cmp ecx, 80h setz cl and cl, 1 movzx ecx, cl add eax, ecx mov cx, ax mov rax, [rbp+var_10] mov [rax+10h], cx jmp short loc_B65F2 loc_B65D5: mov rax, [rbp+var_10] mov eax, [rax+0Ch] mov cx, ax mov rax, [rbp+var_10] mov [rax+10h], cx mov rax, [rbp+var_10] mov dword ptr [rax+0Ch], 0 loc_B65F2: mov rax, [rbp+var_8] pop rbp retn
long long mi_keyseg_read(long long a1, long long a2) { *(_BYTE *)(a2 + 24) = *(_BYTE *)a1; *(_WORD *)(a2 + 22) = *(unsigned __int8 *)(a1 + 1); *(_BYTE *)(a2 + 25) = *(_BYTE *)(a1 + 2); *(_BYTE *)(a2 + 26) = *(_BYTE *)(a1 + 3); *(_WORD *)(a2 + 22) += *(unsigned __int8 *)(a1 + 4) << 8; *(_BYTE *)(a2 + 27) = *(_BYTE *)(a1 + 5); *(_WORD *)(a2 + 18) = _byteswap_ushort(*(_WORD *)(a1 + 6)); *(_WORD *)(a2 + 20) = _byteswap_ushort(*(_WORD *)(a1 + 8)); *(_DWORD *)(a2 + 8) = _byteswap_ulong(*(_DWORD *)(a1 + 10)); *(_DWORD *)(a2 + 12) = _byteswap_ulong(*(_DWORD *)(a1 + 14)); *(_QWORD *)a2 = 0LL; if ( *(_BYTE *)(a2 + 25) ) { *(_WORD *)(a2 + 16) = (*(unsigned __int8 *)(a2 + 25) == 128) + (unsigned __int16)*(_DWORD *)(a2 + 12); } else { *(_WORD *)(a2 + 16) = *(_DWORD *)(a2 + 12); *(_DWORD *)(a2 + 12) = 0; } return a1 + 18; }
mi_keyseg_read: PUSH RBP MOV RBP,RSP MOV qword ptr [RBP + -0x8],RDI MOV qword ptr [RBP + -0x10],RSI MOV RAX,qword ptr [RBP + -0x8] MOV RCX,RAX ADD RCX,0x1 MOV qword ptr [RBP + -0x8],RCX MOV CL,byte ptr [RAX] MOV RAX,qword ptr [RBP + -0x10] MOV byte ptr [RAX + 0x18],CL MOV RAX,qword ptr [RBP + -0x8] MOV RCX,RAX ADD RCX,0x1 MOV qword ptr [RBP + -0x8],RCX MOVZX EAX,byte ptr [RAX] MOV CX,AX MOV RAX,qword ptr [RBP + -0x10] MOV word ptr [RAX + 0x16],CX MOV RAX,qword ptr [RBP + -0x8] MOV RCX,RAX ADD RCX,0x1 MOV qword ptr [RBP + -0x8],RCX MOV CL,byte ptr [RAX] MOV RAX,qword ptr [RBP + -0x10] MOV byte ptr [RAX + 0x19],CL MOV RAX,qword ptr [RBP + -0x8] MOV RCX,RAX ADD RCX,0x1 MOV qword ptr [RBP + -0x8],RCX MOV CL,byte ptr [RAX] MOV RAX,qword ptr [RBP + -0x10] MOV byte ptr [RAX + 0x1a],CL MOV RAX,qword ptr [RBP + -0x8] MOV RCX,RAX ADD RCX,0x1 MOV qword ptr [RBP + -0x8],RCX MOVZX EAX,byte ptr [RAX] MOVZX EDX,AX SHL EDX,0x8 MOV RAX,qword ptr [RBP + -0x10] MOVZX ECX,word ptr [RAX + 0x16] ADD ECX,EDX MOV word ptr [RAX + 0x16],CX MOV RAX,qword ptr [RBP + -0x8] MOV RCX,RAX ADD RCX,0x1 MOV qword ptr [RBP + -0x8],RCX MOV CL,byte ptr [RAX] MOV RAX,qword ptr [RBP + -0x10] MOV byte ptr [RAX + 0x1b],CL MOV RAX,qword ptr [RBP + -0x8] MOVZX EAX,byte ptr [RAX + 0x1] MOVZX EAX,AX MOV RCX,qword ptr [RBP + -0x8] MOVZX ECX,byte ptr [RCX] MOVZX ECX,CX SHL ECX,0x8 OR EAX,ECX MOV CX,AX MOV RAX,qword ptr [RBP + -0x10] MOV word ptr [RAX + 0x12],CX MOV RAX,qword ptr [RBP + -0x8] ADD RAX,0x2 MOV qword ptr [RBP + -0x8],RAX MOV RAX,qword ptr [RBP + -0x8] MOVZX EAX,byte ptr [RAX + 0x1] MOVZX EAX,AX MOV RCX,qword ptr [RBP + -0x8] MOVZX ECX,byte ptr [RCX] MOVZX ECX,CX SHL ECX,0x8 OR EAX,ECX MOV CX,AX MOV RAX,qword ptr [RBP + -0x10] MOV word ptr [RAX + 0x14],CX MOV RAX,qword ptr [RBP + -0x8] ADD RAX,0x2 MOV qword ptr [RBP + -0x8],RAX MOV RAX,qword ptr [RBP + -0x8] MOVZX ECX,byte ptr [RAX + 0x3] MOV RAX,qword ptr [RBP + -0x8] MOVZX EAX,byte ptr [RAX + 0x2] SHL EAX,0x8 OR ECX,EAX MOV RAX,qword ptr [RBP + -0x8] MOVZX EAX,byte ptr [RAX + 0x1] SHL EAX,0x10 OR ECX,EAX MOV RAX,qword ptr [RBP + -0x8] MOVZX EAX,byte ptr [RAX] SHL EAX,0x18 OR ECX,EAX MOV RAX,qword ptr [RBP + -0x10] MOV dword ptr [RAX + 0x8],ECX MOV RAX,qword ptr [RBP + -0x8] ADD RAX,0x4 MOV qword ptr [RBP + -0x8],RAX MOV RAX,qword ptr [RBP + -0x8] MOVZX ECX,byte ptr [RAX + 0x3] MOV RAX,qword ptr [RBP + -0x8] MOVZX EAX,byte ptr [RAX + 0x2] SHL EAX,0x8 OR ECX,EAX MOV RAX,qword ptr [RBP + -0x8] MOVZX EAX,byte ptr [RAX + 0x1] SHL EAX,0x10 OR ECX,EAX MOV RAX,qword ptr [RBP + -0x8] MOVZX EAX,byte ptr [RAX] SHL EAX,0x18 OR ECX,EAX MOV RAX,qword ptr [RBP + -0x10] MOV dword ptr [RAX + 0xc],ECX MOV RAX,qword ptr [RBP + -0x8] ADD RAX,0x4 MOV qword ptr [RBP + -0x8],RAX MOV RAX,qword ptr [RBP + -0x10] MOV qword ptr [RAX],0x0 MOV RAX,qword ptr [RBP + -0x10] CMP byte ptr [RAX + 0x19],0x0 JZ 0x001b65d5 MOV RAX,qword ptr [RBP + -0x10] MOV EAX,dword ptr [RAX + 0xc] MOV RCX,qword ptr [RBP + -0x10] MOVZX ECX,byte ptr [RCX + 0x19] CMP ECX,0x80 SETZ CL AND CL,0x1 MOVZX ECX,CL ADD EAX,ECX MOV CX,AX MOV RAX,qword ptr [RBP + -0x10] MOV word ptr [RAX + 0x10],CX JMP 0x001b65f2 LAB_001b65d5: MOV RAX,qword ptr [RBP + -0x10] MOV EAX,dword ptr [RAX + 0xc] MOV CX,AX MOV RAX,qword ptr [RBP + -0x10] MOV word ptr [RAX + 0x10],CX MOV RAX,qword ptr [RBP + -0x10] MOV dword ptr [RAX + 0xc],0x0 LAB_001b65f2: MOV RAX,qword ptr [RBP + -0x8] POP RBP RET
int1 * mi_keyseg_read(int1 *param_1,int8 *param_2) { *(int1 *)(param_2 + 3) = *param_1; *(ushort *)((long)param_2 + 0x16) = (ushort)(byte)param_1[1]; *(int1 *)((long)param_2 + 0x19) = param_1[2]; *(int1 *)((long)param_2 + 0x1a) = param_1[3]; *(ushort *)((long)param_2 + 0x16) = *(short *)((long)param_2 + 0x16) + (ushort)(byte)param_1[4] * 0x100; *(int1 *)((long)param_2 + 0x1b) = param_1[5]; *(ushort *)((long)param_2 + 0x12) = CONCAT11(param_1[6],param_1[7]); *(ushort *)((long)param_2 + 0x14) = CONCAT11(param_1[8],param_1[9]); *(uint *)(param_2 + 1) = CONCAT13(param_1[10],CONCAT12(param_1[0xb],CONCAT11(param_1[0xc],param_1[0xd]))); *(uint *)((long)param_2 + 0xc) = CONCAT13(param_1[0xe],CONCAT12(param_1[0xf],CONCAT11(param_1[0x10],param_1[0x11]))); *param_2 = 0; if (*(char *)((long)param_2 + 0x19) == '\0') { *(short *)(param_2 + 2) = (short)*(int4 *)((long)param_2 + 0xc); *(int4 *)((long)param_2 + 0xc) = 0; } else { *(ushort *)(param_2 + 2) = (short)*(int4 *)((long)param_2 + 0xc) + (ushort)(*(char *)((long)param_2 + 0x19) == -0x80); } return param_1 + 0x12; }
27,519
get_segment_integrity
seiftnesse[P]memoryallocator/src/custom_alloc_util.c
segment_integrity_t *get_segment_integrity(segment_t *s) { if (!s) return 0; // In our layout, the integrity data comes after the segment_t structure // but before the user data begins. // Calculate the proper aligned offset for the integrity structure uintptr_t segment_addr = (uintptr_t) (s); uintptr_t user_data_addr = (uintptr_t) (SegmentToPtr(s)); // The integrity structure is placed between the segment header and the user data uintptr_t integrity_addr = segment_addr + sizeof(segment_t); // Make sure there's enough space for the integrity structure if (integrity_addr + sizeof(segment_integrity_t) > user_data_addr) { HEAP_LOG("Warning: Not enough space for integrity data in segment %p\n", s); return 0; } return (segment_integrity_t *) (integrity_addr); }
O3
c
get_segment_integrity: testq %rdi, %rdi je 0x28e4 leaq 0x3f(%rdi), %rcx andq $-0x10, %rcx leaq 0x3c(%rdi), %rdx addq $0x30, %rdi xorl %eax, %eax cmpq %rcx, %rdx cmovbeq %rdi, %rax retq xorl %eax, %eax retq
get_segment_integrity: test rdi, rdi jz short loc_28E4 lea rcx, [rdi+3Fh] and rcx, 0FFFFFFFFFFFFFFF0h lea rdx, [rdi+3Ch] add rdi, 30h ; '0' xor eax, eax cmp rdx, rcx cmovbe rax, rdi retn loc_28E4: xor eax, eax retn
long long get_segment_integrity(long long a1) { unsigned long long v1; // rcx unsigned long long v2; // rdx long long v3; // rdi long long result; // rax if ( !a1 ) return 0LL; v1 = (a1 + 63) & 0xFFFFFFFFFFFFFFF0LL; v2 = a1 + 60; v3 = a1 + 48; result = 0LL; if ( v2 <= v1 ) return v3; return result; }
get_segment_integrity: TEST RDI,RDI JZ 0x001028e4 LEA RCX,[RDI + 0x3f] AND RCX,-0x10 LEA RDX,[RDI + 0x3c] ADD RDI,0x30 XOR EAX,EAX CMP RDX,RCX CMOVBE RAX,RDI RET LAB_001028e4: XOR EAX,EAX RET
long get_segment_integrity(long param_1) { long lVar1; if (param_1 != 0) { lVar1 = 0; if (param_1 + 0x3cU <= (param_1 + 0x3fU & 0xfffffffffffffff0)) { lVar1 = param_1 + 0x30; } return lVar1; } return 0; }
27,520
my_fill_mb2
eloqsql/strings/ctype-ucs2.c
static void my_fill_mb2(CHARSET_INFO *cs, char *s, size_t slen, int fill) { char buf[10], *last; size_t buflen, remainder; DBUG_ASSERT((slen % 2) == 0); buflen= my_ci_wc_mb(cs, (my_wc_t) fill, (uchar*) buf, (uchar*) buf + sizeof(buf)); DBUG_ASSERT(buflen > 0); /* "last" in the last position where a sequence of "buflen" bytes can start. */ for (last= s + slen - buflen; s <= last; s+= buflen) { /* Enough space for the character */ memcpy(s, buf, buflen); } /* If there are some more space which is not enough for the whole multibyte character, then add trailing zeros. */ if ((remainder= last + buflen - s) > 0) bzero(s, (size_t) remainder); }
O0
c
my_fill_mb2: pushq %rbp movq %rsp, %rbp subq $0x50, %rsp movq %fs:0x28, %rax movq %rax, -0x8(%rbp) movq %rdi, -0x20(%rbp) movq %rsi, -0x28(%rbp) movq %rdx, -0x30(%rbp) movl %ecx, -0x34(%rbp) jmp 0xeee36 movq -0x20(%rbp), %rax movq 0xb8(%rax), %rax movq 0x30(%rax), %rax movq -0x20(%rbp), %rdi movslq -0x34(%rbp), %rsi leaq -0x12(%rbp), %rdx leaq -0x12(%rbp), %rcx addq $0xa, %rcx callq *%rax cltq movq %rax, -0x48(%rbp) jmp 0xeee63 movq -0x28(%rbp), %rax addq -0x30(%rbp), %rax xorl %ecx, %ecx subq -0x48(%rbp), %rcx addq %rcx, %rax movq %rax, -0x40(%rbp) movq -0x28(%rbp), %rax cmpq -0x40(%rbp), %rax ja 0xeeea1 movq -0x28(%rbp), %rdi leaq -0x12(%rbp), %rsi movq -0x48(%rbp), %rdx callq 0x3b0c0 movq -0x48(%rbp), %rax addq -0x28(%rbp), %rax movq %rax, -0x28(%rbp) jmp 0xeee78 movq -0x40(%rbp), %rax addq -0x48(%rbp), %rax movq -0x28(%rbp), %rcx subq %rcx, %rax movq %rax, -0x50(%rbp) cmpq $0x0, %rax jbe 0xeeec9 movq -0x28(%rbp), %rdi movq -0x50(%rbp), %rdx xorl %esi, %esi callq 0x3b390 movq %fs:0x28, %rax movq -0x8(%rbp), %rcx cmpq %rcx, %rax jne 0xeeee1 addq $0x50, %rsp popq %rbp retq callq 0x3b340 nopw %cs:(%rax,%rax)
my_fill_mb2: push rbp mov rbp, rsp sub rsp, 50h mov rax, fs:28h mov [rbp+var_8], rax mov [rbp+var_20], rdi mov [rbp+var_28], rsi mov [rbp+var_30], rdx mov [rbp+var_34], ecx jmp short $+2 loc_EEE36: mov rax, [rbp+var_20] mov rax, [rax+0B8h] mov rax, [rax+30h] mov rdi, [rbp+var_20] movsxd rsi, [rbp+var_34] lea rdx, [rbp+var_12] lea rcx, [rbp+var_12] add rcx, 0Ah call rax cdqe mov [rbp+var_48], rax jmp short $+2 loc_EEE63: mov rax, [rbp+var_28] add rax, [rbp+var_30] xor ecx, ecx sub rcx, [rbp+var_48] add rax, rcx mov [rbp+var_40], rax loc_EEE78: mov rax, [rbp+var_28] cmp rax, [rbp+var_40] ja short loc_EEEA1 mov rdi, [rbp+var_28] lea rsi, [rbp+var_12] mov rdx, [rbp+var_48] call _memcpy mov rax, [rbp+var_48] add rax, [rbp+var_28] mov [rbp+var_28], rax jmp short loc_EEE78 loc_EEEA1: mov rax, [rbp+var_40] add rax, [rbp+var_48] mov rcx, [rbp+var_28] sub rax, rcx mov [rbp+var_50], rax cmp rax, 0 jbe short loc_EEEC9 mov rdi, [rbp+var_28] mov rdx, [rbp+var_50] xor esi, esi call _memset loc_EEEC9: mov rax, fs:28h mov rcx, [rbp+var_8] cmp rax, rcx jnz short loc_EEEE1 add rsp, 50h pop rbp retn loc_EEEE1: call ___stack_chk_fail
unsigned long long my_fill_mb2(long long a1, unsigned long long a2, long long a3, int a4) { long long i; // [rsp+8h] [rbp-48h] unsigned long long v7; // [rsp+28h] [rbp-28h] _BYTE v8[10]; // [rsp+3Eh] [rbp-12h] BYREF unsigned long long v9; // [rsp+48h] [rbp-8h] BYREF v9 = __readfsqword(0x28u); v7 = a2; for ( i = (*(int ( **)(long long, _QWORD, _BYTE *, unsigned long long *))(*(_QWORD *)(a1 + 184) + 48LL))( a1, a4, v8, &v9); v7 <= a3 + a2 - i; v7 += i ) memcpy(v7, v8, i); if ( a3 + a2 != v7 ) memset(v7, 0LL, a3 + a2 - v7); return __readfsqword(0x28u); }
my_fill_mb2: PUSH RBP MOV RBP,RSP SUB RSP,0x50 MOV RAX,qword ptr FS:[0x28] MOV qword ptr [RBP + -0x8],RAX MOV qword ptr [RBP + -0x20],RDI MOV qword ptr [RBP + -0x28],RSI MOV qword ptr [RBP + -0x30],RDX MOV dword ptr [RBP + -0x34],ECX JMP 0x001eee36 LAB_001eee36: MOV RAX,qword ptr [RBP + -0x20] MOV RAX,qword ptr [RAX + 0xb8] MOV RAX,qword ptr [RAX + 0x30] MOV RDI,qword ptr [RBP + -0x20] MOVSXD RSI,dword ptr [RBP + -0x34] LEA RDX,[RBP + -0x12] LEA RCX,[RBP + -0x12] ADD RCX,0xa CALL RAX CDQE MOV qword ptr [RBP + -0x48],RAX JMP 0x001eee63 LAB_001eee63: MOV RAX,qword ptr [RBP + -0x28] ADD RAX,qword ptr [RBP + -0x30] XOR ECX,ECX SUB RCX,qword ptr [RBP + -0x48] ADD RAX,RCX MOV qword ptr [RBP + -0x40],RAX LAB_001eee78: MOV RAX,qword ptr [RBP + -0x28] CMP RAX,qword ptr [RBP + -0x40] JA 0x001eeea1 MOV RDI,qword ptr [RBP + -0x28] LEA RSI,[RBP + -0x12] MOV RDX,qword ptr [RBP + -0x48] CALL 0x0013b0c0 MOV RAX,qword ptr [RBP + -0x48] ADD RAX,qword ptr [RBP + -0x28] MOV qword ptr [RBP + -0x28],RAX JMP 0x001eee78 LAB_001eeea1: MOV RAX,qword ptr [RBP + -0x40] ADD RAX,qword ptr [RBP + -0x48] MOV RCX,qword ptr [RBP + -0x28] SUB RAX,RCX MOV qword ptr [RBP + -0x50],RAX CMP RAX,0x0 JBE 0x001eeec9 MOV RDI,qword ptr [RBP + -0x28] MOV RDX,qword ptr [RBP + -0x50] XOR ESI,ESI CALL 0x0013b390 LAB_001eeec9: MOV RAX,qword ptr FS:[0x28] MOV RCX,qword ptr [RBP + -0x8] CMP RAX,RCX JNZ 0x001eeee1 ADD RSP,0x50 POP RBP RET LAB_001eeee1: CALL 0x0013b340
void my_fill_mb2(long param_1,void *param_2,long param_3,int param_4) { int iVar1; size_t sVar2; void *pvVar3; long in_FS_OFFSET; void *local_30; int1 local_1a [10]; long local_10; local_10 = *(long *)(in_FS_OFFSET + 0x28); iVar1 = (**(code **)(*(long *)(param_1 + 0xb8) + 0x30))(param_1,(long)param_4,local_1a); sVar2 = (size_t)iVar1; pvVar3 = (void *)((long)param_2 + (param_3 - sVar2)); for (local_30 = param_2; local_30 <= pvVar3; local_30 = (void *)(sVar2 + (long)local_30)) { memcpy(local_30,local_1a,sVar2); } sVar2 = (long)pvVar3 + (sVar2 - (long)local_30); if (sVar2 != 0) { memset(local_30,0,sVar2); } if (*(long *)(in_FS_OFFSET + 0x28) == local_10) { return; } /* WARNING: Subroutine does not return */ __stack_chk_fail(); }
27,521
my_init
eloqsql/mysys/my_init.c
my_bool my_init(void) { char *str; if (my_init_done) return 0; my_init_done= 1; mysys_usage_id++; my_umask= 0660; /* Default umask for new files */ my_umask_dir= 0700; /* Default umask for new directories */ my_global_flags= 0; /* Default creation of new files */ if ((str= getenv("UMASK")) != 0) my_umask= (int) (atoi_octal(str) | 0600); /* Default creation of new dir's */ if ((str= getenv("UMASK_DIR")) != 0) my_umask_dir= (int) (atoi_octal(str) | 0700); init_glob_errs(); instrumented_stdin.m_file= stdin; instrumented_stdin.m_psi= NULL; /* not yet instrumented */ mysql_stdin= & instrumented_stdin; my_progname_short= "unknown"; if (my_progname) my_progname_short= my_progname + dirname_length(my_progname); /* Initialize our mutex handling */ my_mutex_init(); if (my_thread_global_init()) return 1; #if defined(SAFEMALLOC) && !defined(DBUG_OFF) dbug_sanity= sf_sanity; #endif /* $HOME is needed early to parse configuration files located in ~/ */ if ((home_dir= getenv("HOME")) != 0) home_dir= intern_filename(home_dir_buff, home_dir); { DBUG_ENTER("my_init"); DBUG_PROCESS((char*) (my_progname ? my_progname : "unknown")); my_time_init(); my_win_init(); DBUG_PRINT("exit", ("home: '%s'", home_dir)); #ifdef _WIN32 if (win32_init_tcp_ip()) DBUG_RETURN(1); #endif #ifdef CHECK_UNLIKELY init_my_likely(); #endif DBUG_RETURN(0); } }
O3
c
my_init: pushq %rbp movq %rsp, %rbp pushq %r14 pushq %rbx leaq 0x3652de(%rip), %rax # 0x3cfae0 cmpb $0x0, (%rax) je 0x6a80e xorl %eax, %eax jmp 0x6a8f6 leaq 0x3652cf(%rip), %rcx # 0x3cfae4 incl (%rcx) movb $0x1, (%rax) leaq 0x2e33d7(%rip), %r14 # 0x34dbf8 movl $0x1b0, (%r14) # imm = 0x1B0 leaq 0x2e33cd(%rip), %rbx # 0x34dbfc movl $0x1c0, (%rbx) # imm = 0x1C0 leaq 0x36577c(%rip), %rax # 0x3cffb8 movq $0x0, (%rax) leaq 0x3dd93(%rip), %rdi # 0xa85dd callq 0x377b0 testq %rax, %rax je 0x6a864 movq %rax, %rdi callq 0x6a932 orl $0x180, %eax # imm = 0x180 movl %eax, (%r14) leaq 0x3dd78(%rip), %rdi # 0xa85e3 callq 0x377b0 testq %rax, %rax je 0x6a884 movq %rax, %rdi callq 0x6a932 orl $0x1c0, %eax # imm = 0x1C0 movl %eax, (%rbx) callq 0x6ea94 movq 0x2de758(%rip), %rax # 0x348fe8 movq (%rax), %rax movq %rax, 0x365256(%rip) # 0x3cfaf0 leaq 0x36524f(%rip), %rax # 0x3cfaf0 movq $0x0, 0x36524c(%rip) # 0x3cfaf8 leaq 0x365235(%rip), %rcx # 0x3cfae8 movq %rax, (%rcx) leaq 0x3615f(%rip), %rax # 0xa0a1c leaq 0x3652d4(%rip), %r14 # 0x3cfb98 movq %rax, (%r14) leaq 0x3652c2(%rip), %rax # 0x3cfb90 movq (%rax), %rbx testq %rbx, %rbx je 0x6a8e4 movq %rbx, %rdi callq 0x66040 addq %rbx, %rax movq %rax, (%r14) callq 0x6cef0 callq 0x6c570 movl %eax, %ecx movb $0x1, %al testb %cl, %cl je 0x6a8fb popq %rbx popq %r14 popq %rbp retq leaq 0x3c5b5(%rip), %rdi # 0xa6eb7 callq 0x377b0 leaq 0x36527a(%rip), %rbx # 0x3cfb88 movq %rax, (%rbx) testq %rax, %rax je 0x6a928 leaq 0x365483(%rip), %rdi # 0x3cfda0 movq %rax, %rsi callq 0x66975 movq %rax, (%rbx) callq 0x6a5c0 jmp 0x6a807
my_init: push rbp mov rbp, rsp push r14 push rbx lea rax, my_init_done cmp byte ptr [rax], 0 jz short loc_6A80E loc_6A807: xor eax, eax jmp loc_6A8F6 loc_6A80E: lea rcx, mysys_usage_id inc dword ptr [rcx] mov byte ptr [rax], 1 lea r14, my_umask mov dword ptr [r14], 1B0h lea rbx, my_umask_dir mov dword ptr [rbx], 1C0h lea rax, my_global_flags mov qword ptr [rax], 0 lea rdi, aUmask; "UMASK" call _getenv test rax, rax jz short loc_6A864 mov rdi, rax call atoi_octal or eax, 180h mov [r14], eax loc_6A864: lea rdi, aUmaskDir; "UMASK_DIR" call _getenv test rax, rax jz short loc_6A884 mov rdi, rax call atoi_octal or eax, 1C0h mov [rbx], eax loc_6A884: call init_glob_errs mov rax, cs:stdin_ptr mov rax, [rax] mov cs:instrumented_stdin, rax lea rax, instrumented_stdin mov cs:qword_3CFAF8, 0 lea rcx, mysql_stdin mov [rcx], rax lea rax, aUnknown; "unknown" lea r14, my_progname_short mov [r14], rax lea rax, my_progname mov rbx, [rax] test rbx, rbx jz short loc_6A8E4 mov rdi, rbx call dirname_length add rax, rbx mov [r14], rax loc_6A8E4: call my_mutex_init call my_thread_global_init mov ecx, eax mov al, 1 test cl, cl jz short loc_6A8FB loc_6A8F6: pop rbx pop r14 pop rbp retn loc_6A8FB: lea rdi, aMariadbHome+8; "HOME" call _getenv lea rbx, home_dir mov [rbx], rax test rax, rax jz short loc_6A928 lea rdi, home_dir_buff mov rsi, rax call intern_filename mov [rbx], rax loc_6A928: call my_time_init jmp loc_6A807
char my_init() { char result; // al long long v1; // rax long long v2; // rax const char *v3; // rbx char v4; // cl _BYTE *v5; // rax if ( my_init_done ) return 0; ++mysys_usage_id; my_init_done = 1; my_umask = 432; my_umask_dir = 448; my_global_flags = 0LL; v1 = getenv("UMASK"); if ( v1 ) my_umask = atoi_octal(v1) | 0x180; v2 = getenv("UMASK_DIR"); if ( v2 ) my_umask_dir = atoi_octal(v2) | 0x1C0; init_glob_errs(); instrumented_stdin = stdin; qword_3CFAF8 = 0LL; mysql_stdin = &instrumented_stdin; my_progname_short = "unknown"; v3 = my_progname; if ( my_progname ) my_progname_short = &v3[dirname_length(my_progname)]; my_mutex_init(); v4 = my_thread_global_init(); result = 1; if ( !v4 ) { v5 = (_BYTE *)getenv("HOME"); home_dir = v5; if ( v5 ) home_dir = intern_filename((long long)&home_dir_buff, v5); my_time_init(); return 0; } return result; }
my_init: PUSH RBP MOV RBP,RSP PUSH R14 PUSH RBX LEA RAX,[0x4cfae0] CMP byte ptr [RAX],0x0 JZ 0x0016a80e LAB_0016a807: XOR EAX,EAX JMP 0x0016a8f6 LAB_0016a80e: LEA RCX,[0x4cfae4] INC dword ptr [RCX] MOV byte ptr [RAX],0x1 LEA R14,[0x44dbf8] MOV dword ptr [R14],0x1b0 LEA RBX,[0x44dbfc] MOV dword ptr [RBX],0x1c0 LEA RAX,[0x4cffb8] MOV qword ptr [RAX],0x0 LEA RDI,[0x1a85dd] CALL 0x001377b0 TEST RAX,RAX JZ 0x0016a864 MOV RDI,RAX CALL 0x0016a932 OR EAX,0x180 MOV dword ptr [R14],EAX LAB_0016a864: LEA RDI,[0x1a85e3] CALL 0x001377b0 TEST RAX,RAX JZ 0x0016a884 MOV RDI,RAX CALL 0x0016a932 OR EAX,0x1c0 MOV dword ptr [RBX],EAX LAB_0016a884: CALL 0x0016ea94 MOV RAX,qword ptr [0x00448fe8] MOV RAX,qword ptr [RAX] MOV qword ptr [0x004cfaf0],RAX LEA RAX,[0x4cfaf0] MOV qword ptr [0x004cfaf8],0x0 LEA RCX,[0x4cfae8] MOV qword ptr [RCX],RAX LEA RAX,[0x1a0a1c] LEA R14,[0x4cfb98] MOV qword ptr [R14],RAX LEA RAX,[0x4cfb90] MOV RBX,qword ptr [RAX] TEST RBX,RBX JZ 0x0016a8e4 MOV RDI,RBX CALL 0x00166040 ADD RAX,RBX MOV qword ptr [R14],RAX LAB_0016a8e4: CALL 0x0016cef0 CALL 0x0016c570 MOV ECX,EAX MOV AL,0x1 TEST CL,CL JZ 0x0016a8fb LAB_0016a8f6: POP RBX POP R14 POP RBP RET LAB_0016a8fb: LEA RDI,[0x1a6eb7] CALL 0x001377b0 LEA RBX,[0x4cfb88] MOV qword ptr [RBX],RAX TEST RAX,RAX JZ 0x0016a928 LEA RDI,[0x4cfda0] MOV RSI,RAX CALL 0x00166975 MOV qword ptr [RBX],RAX LAB_0016a928: CALL 0x0016a5c0 JMP 0x0016a807
int8 my_init(void) { long lVar1; char cVar2; uint uVar3; char *pcVar4; long lVar5; if (my_init_done == '\0') { mysys_usage_id = mysys_usage_id + 1; my_init_done = '\x01'; my_umask = 0x1b0; my_umask_dir = 0x1c0; my_global_flags = 0; pcVar4 = getenv("UMASK"); if (pcVar4 != (char *)0x0) { uVar3 = atoi_octal(pcVar4); my_umask = uVar3 | 0x180; } pcVar4 = getenv("UMASK_DIR"); if (pcVar4 != (char *)0x0) { uVar3 = atoi_octal(pcVar4); my_umask_dir = uVar3 | 0x1c0; } init_glob_errs(); lVar1 = my_progname; instrumented_stdin._0_8_ = *(int8 *)PTR_stdin_00448fe8; instrumented_stdin._8_8_ = 0; mysql_stdin = instrumented_stdin; my_progname_short = "unknown"; if (my_progname != 0) { lVar5 = dirname_length(my_progname); my_progname_short = (char *)(lVar5 + lVar1); } my_mutex_init(); cVar2 = my_thread_global_init(); if (cVar2 != '\0') { return 1; } home_dir = getenv("HOME"); if (home_dir != (char *)0x0) { home_dir = (char *)intern_filename(home_dir_buff,home_dir); } my_time_init(); } return 0; }
27,522
mysql_next_result
eloqsql/libmariadb/libmariadb/mariadb_lib.c
int STDCALL mysql_next_result(MYSQL *mysql) { /* make sure communication is not blocking */ if (mysql->status != MYSQL_STATUS_READY) { SET_CLIENT_ERROR(mysql, CR_COMMANDS_OUT_OF_SYNC, SQLSTATE_UNKNOWN, 0); return(1); } /* clear error, and mysql status variables */ CLEAR_CLIENT_ERROR(mysql); mysql->affected_rows = (ulonglong) ~0; if (mysql->server_status & SERVER_MORE_RESULTS_EXIST) { return(mysql->methods->db_read_query_result(mysql)); } return(-1); }
O3
c
mysql_next_result: pushq %rbp movq %rsp, %rbp pushq %r14 pushq %rbx movq %rdi, %rbx addq $0x297, %rdi # imm = 0x297 cmpl $0x0, 0x488(%rbx) je 0x19abd movl $0x7de, 0x90(%rbx) # imm = 0x7DE leaq 0x2efb4(%rip), %rax # 0x48a30 movq (%rax), %rsi movl $0x5, %edx callq 0x13220 xorl %r14d, %r14d movb %r14b, 0x29c(%rbx) leaq 0x97(%rbx), %rdi leaq 0x2ef9f(%rip), %rax # 0x48a40 movq 0x70(%rax), %rsi movl $0x1ff, %edx # imm = 0x1FF callq 0x13220 movb %r14b, 0x296(%rbx) movl $0x1, %eax jmp 0x19b06 movl $0x0, 0x90(%rbx) movw $0x30, 0x4(%rdi) movl $0x30303030, (%rdi) # imm = 0x30303030 movb $0x0, 0x97(%rbx) movq 0x2a0(%rbx), %rax testq %rax, %rax je 0x19aed movl $0x0, 0x4(%rax) movq $-0x1, 0x338(%rbx) movl $0xffffffff, %eax # imm = 0xFFFFFFFF testb $0x8, 0x380(%rbx) jne 0x19b0b popq %rbx popq %r14 popq %rbp retq movq 0x4d0(%rbx), %rax movq %rbx, %rdi popq %rbx popq %r14 popq %rbp jmpq *0x20(%rax)
mysql_next_result: push rbp mov rbp, rsp push r14 push rbx mov rbx, rdi add rdi, 297h cmp dword ptr [rbx+488h], 0 jz short loc_19ABD mov dword ptr [rbx+90h], 7DEh lea rax, SQLSTATE_UNKNOWN mov rsi, [rax] mov edx, 5 call _strncpy xor r14d, r14d mov [rbx+29Ch], r14b lea rdi, [rbx+97h] lea rax, client_errors mov rsi, [rax+70h] mov edx, 1FFh call _strncpy mov [rbx+296h], r14b mov eax, 1 jmp short loc_19B06 loc_19ABD: mov dword ptr [rbx+90h], 0 mov word ptr [rdi+4], 30h ; '0' mov dword ptr [rdi], 30303030h mov byte ptr [rbx+97h], 0 mov rax, [rbx+2A0h] test rax, rax jz short loc_19AED mov dword ptr [rax+4], 0 loc_19AED: mov qword ptr [rbx+338h], 0FFFFFFFFFFFFFFFFh mov eax, 0FFFFFFFFh test byte ptr [rbx+380h], 8 jnz short loc_19B0B loc_19B06: pop rbx pop r14 pop rbp retn loc_19B0B: mov rax, [rbx+4D0h] mov rdi, rbx pop rbx pop r14 pop rbp jmp qword ptr [rax+20h]
long long mysql_next_result(long long a1) { char *v2; // rdi long long result; // rax long long v4; // rax v2 = (char *)(a1 + 663); if ( *(_DWORD *)(a1 + 1160) ) { *(_DWORD *)(a1 + 144) = 2014; strncpy(v2, SQLSTATE_UNKNOWN, 5LL); *(_BYTE *)(a1 + 668) = 0; strncpy(a1 + 151, client_errors[14], 511LL); *(_BYTE *)(a1 + 662) = 0; return 1LL; } else { *(_DWORD *)(a1 + 144) = 0; strcpy(v2, "00000"); *(_BYTE *)(a1 + 151) = 0; v4 = *(_QWORD *)(a1 + 672); if ( v4 ) *(_DWORD *)(v4 + 4) = 0; *(_QWORD *)(a1 + 824) = -1LL; result = 0xFFFFFFFFLL; if ( (*(_BYTE *)(a1 + 896) & 8) != 0 ) return (*(long long ( **)(long long))(*(_QWORD *)(a1 + 1232) + 32LL))(a1); } return result; }
mysql_next_result: PUSH RBP MOV RBP,RSP PUSH R14 PUSH RBX MOV RBX,RDI ADD RDI,0x297 CMP dword ptr [RBX + 0x488],0x0 JZ 0x00119abd MOV dword ptr [RBX + 0x90],0x7de LEA RAX,[0x148a30] MOV RSI,qword ptr [RAX] MOV EDX,0x5 CALL 0x00113220 XOR R14D,R14D MOV byte ptr [RBX + 0x29c],R14B LEA RDI,[RBX + 0x97] LEA RAX,[0x148a40] MOV RSI,qword ptr [RAX + 0x70] MOV EDX,0x1ff CALL 0x00113220 MOV byte ptr [RBX + 0x296],R14B MOV EAX,0x1 JMP 0x00119b06 LAB_00119abd: MOV dword ptr [RBX + 0x90],0x0 MOV word ptr [RDI + 0x4],0x30 MOV dword ptr [RDI],0x30303030 MOV byte ptr [RBX + 0x97],0x0 MOV RAX,qword ptr [RBX + 0x2a0] TEST RAX,RAX JZ 0x00119aed MOV dword ptr [RAX + 0x4],0x0 LAB_00119aed: MOV qword ptr [RBX + 0x338],-0x1 MOV EAX,0xffffffff TEST byte ptr [RBX + 0x380],0x8 JNZ 0x00119b0b LAB_00119b06: POP RBX POP R14 POP RBP RET LAB_00119b0b: MOV RAX,qword ptr [RBX + 0x4d0] MOV RDI,RBX POP RBX POP R14 POP RBP JMP qword ptr [RAX + 0x20]
int8 mysql_next_result(long param_1) { int8 uVar1; if (*(int *)(param_1 + 0x488) == 0) { *(int4 *)(param_1 + 0x90) = 0; *(int2 *)(param_1 + 0x29b) = 0x30; builtin_strncpy((char *)(param_1 + 0x297),"0000",4); *(int1 *)(param_1 + 0x97) = 0; if (*(long *)(param_1 + 0x2a0) != 0) { *(int4 *)(*(long *)(param_1 + 0x2a0) + 4) = 0; } *(int8 *)(param_1 + 0x338) = 0xffffffffffffffff; uVar1 = 0xffffffff; if ((*(byte *)(param_1 + 0x380) & 8) != 0) { /* WARNING: Could not recover jumptable at 0x00119b19. Too many branches */ /* WARNING: Treating indirect jump as call */ uVar1 = (**(code **)(*(long *)(param_1 + 0x4d0) + 0x20))(param_1); return uVar1; } } else { *(int4 *)(param_1 + 0x90) = 0x7de; strncpy((char *)(param_1 + 0x297),SQLSTATE_UNKNOWN,5); *(int1 *)(param_1 + 0x29c) = 0; strncpy((char *)(param_1 + 0x97),PTR_s_Commands_out_of_sync__you_can_t_r_00148ab0,0x1ff); *(int1 *)(param_1 + 0x296) = 0; uVar1 = 1; } return uVar1; }
27,523
CLI::OptionBase<CLI::Option>::group(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&)
MikePodsytnik[P]TCRtrie/build_O0/_deps/cli11-src/include/CLI/Option.hpp
CRTP *group(const std::string &name) { if(!detail::valid_alias_name_string(name)) { throw IncorrectConstruction("Group names may not contain newlines or null characters"); } group_ = name; return static_cast<CRTP *>(this); }
O0
cpp
CLI::OptionBase<CLI::Option>::group(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&): pushq %rbp movq %rsp, %rbp subq $0x60, %rsp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq -0x8(%rbp), %rax movq %rax, -0x50(%rbp) movq -0x10(%rbp), %rdi callq 0x31260 testb $0x1, %al jne 0x30e99 movb $0x1, -0x45(%rbp) movl $0x38, %edi callq 0x92d0 movq %rax, -0x60(%rbp) leaq -0x31(%rbp), %rdi movq %rdi, -0x58(%rbp) callq 0x9a80 movq -0x58(%rbp), %rdx leaq 0x3eb26(%rip), %rsi # 0x6f949 leaq -0x30(%rbp), %rdi callq 0xbb20 jmp 0x30e2e movq -0x60(%rbp), %rdi leaq -0x30(%rbp), %rsi callq 0x31360 jmp 0x30e3d movq -0x60(%rbp), %rdi movb $0x0, -0x45(%rbp) leaq 0x7060c(%rip), %rsi # 0xa1458 leaq -0x5d23(%rip), %rdx # 0x2b130 callq 0x9a30 jmp 0x30eb9 movq %rax, %rcx movl %edx, %eax movq %rcx, -0x40(%rbp) movl %eax, -0x44(%rbp) jmp 0x30e7d movq %rax, %rcx movl %edx, %eax movq %rcx, -0x40(%rbp) movl %eax, -0x44(%rbp) leaq -0x30(%rbp), %rdi callq 0x9b90 leaq -0x31(%rbp), %rdi callq 0x9690 testb $0x1, -0x45(%rbp) jne 0x30e8e jmp 0x30e97 movq -0x60(%rbp), %rdi callq 0x9470 jmp 0x30eb0 movq -0x50(%rbp), %rdi movq -0x10(%rbp), %rsi callq 0x9060 movq -0x50(%rbp), %rax addq $0x60, %rsp popq %rbp retq movq -0x40(%rbp), %rdi callq 0x9a70 nopl (%rax)
_ZN3CLI10OptionBaseINS_6OptionEE5groupERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE: push rbp mov rbp, rsp sub rsp, 60h mov [rbp+var_8], rdi mov [rbp+var_10], rsi mov rax, [rbp+var_8] mov [rbp+var_50], rax mov rdi, [rbp+var_10] call _ZN3CLI6detail23valid_alias_name_stringERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; CLI::detail::valid_alias_name_string(std::string const&) test al, 1 jnz loc_30E99 mov [rbp+var_45], 1 mov edi, 38h ; '8'; thrown_size call ___cxa_allocate_exception mov [rbp+var_60], rax lea rdi, [rbp+var_31] mov [rbp+var_58], rdi call __ZNSaIcEC1Ev; std::allocator<char>::allocator(void) mov rdx, [rbp+var_58] lea rsi, aGroupNamesMayN; "Group names may not contain newlines or"... lea rdi, [rbp+var_30] call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&) jmp short $+2 loc_30E2E: mov rdi, [rbp+var_60] lea rsi, [rbp+var_30] call _ZN3CLI21IncorrectConstructionC2ENSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; CLI::IncorrectConstruction::IncorrectConstruction(std::string) jmp short $+2 loc_30E3D: mov rdi, [rbp+var_60]; void * mov [rbp+var_45], 0 lea rsi, _ZTIN3CLI21IncorrectConstructionE; lptinfo lea rdx, _ZN3CLI21IncorrectConstructionD2Ev; void (*)(void *) call ___cxa_throw jmp short loc_30EB9 mov rcx, rax mov eax, edx mov [rbp+var_40], rcx mov [rbp+var_44], eax jmp short loc_30E7D mov rcx, rax mov eax, edx mov [rbp+var_40], rcx mov [rbp+var_44], eax lea rdi, [rbp+var_30]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string() loc_30E7D: lea rdi, [rbp+var_31] call __ZNSaIcED1Ev; std::allocator<char>::~allocator() test [rbp+var_45], 1 jnz short loc_30E8E jmp short loc_30E97 loc_30E8E: mov rdi, [rbp+var_60]; void * call ___cxa_free_exception loc_30E97: jmp short loc_30EB0 loc_30E99: mov rdi, [rbp+var_50] mov rsi, [rbp+var_10] call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEaSERKS4_; std::string::operator=(std::string const&) mov rax, [rbp+var_50] add rsp, 60h pop rbp retn loc_30EB0: mov rdi, [rbp+var_40] call __Unwind_Resume loc_30EB9: nop dword ptr [rax+00000000h]
long long CLI::OptionBase<CLI::Option>::group(long long a1, long long a2) { long long v2; // rdx void *exception; // [rsp+0h] [rbp-60h] char v5; // [rsp+2Fh] [rbp-31h] BYREF _BYTE v6[32]; // [rsp+30h] [rbp-30h] BYREF long long v7; // [rsp+50h] [rbp-10h] long long v8; // [rsp+58h] [rbp-8h] v8 = a1; v7 = a2; if ( (CLI::detail::valid_alias_name_string(a2) & 1) == 0 ) { exception = __cxa_allocate_exception(0x38uLL); std::allocator<char>::allocator(&v5, a2, v2); std::string::basic_string<std::allocator<char>>( (long long)v6, (long long)"Group names may not contain newlines or null characters", (long long)&v5); CLI::IncorrectConstruction::IncorrectConstruction(exception, v6); __cxa_throw( exception, (struct type_info *)&`typeinfo for'CLI::IncorrectConstruction, (void (*)(void *))CLI::IncorrectConstruction::~IncorrectConstruction); } std::string::operator=(a1, v7); return a1; }
group: PUSH RBP MOV RBP,RSP SUB RSP,0x60 MOV qword ptr [RBP + -0x8],RDI MOV qword ptr [RBP + -0x10],RSI MOV RAX,qword ptr [RBP + -0x8] MOV qword ptr [RBP + -0x50],RAX MOV RDI,qword ptr [RBP + -0x10] CALL 0x00131260 TEST AL,0x1 JNZ 0x00130e99 MOV byte ptr [RBP + -0x45],0x1 MOV EDI,0x38 CALL 0x001092d0 MOV qword ptr [RBP + -0x60],RAX LEA RDI,[RBP + -0x31] MOV qword ptr [RBP + -0x58],RDI CALL 0x00109a80 MOV RDX,qword ptr [RBP + -0x58] LAB_00130e1c: LEA RSI,[0x16f949] LEA RDI,[RBP + -0x30] CALL 0x0010bb20 JMP 0x00130e2e LAB_00130e2e: MOV RDI,qword ptr [RBP + -0x60] LEA RSI,[RBP + -0x30] CALL 0x00131360 JMP 0x00130e3d LAB_00130e3d: MOV RDI,qword ptr [RBP + -0x60] MOV byte ptr [RBP + -0x45],0x0 LEA RSI,[0x1a1458] LEA RDX,[0x12b130] CALL 0x00109a30 LAB_00130e99: MOV RDI,qword ptr [RBP + -0x50] MOV RSI,qword ptr [RBP + -0x10] CALL 0x00109060 MOV RAX,qword ptr [RBP + -0x50] ADD RSP,0x60 POP RBP RET
/* CLI::OptionBase<CLI::Option>::group(std::__cxx11::string const&) */ OptionBase<CLI::Option> * __thiscall CLI::OptionBase<CLI::Option>::group(OptionBase<CLI::Option> *this,string *param_1) { ulong uVar1; IncorrectConstruction *pIVar2; allocator local_39; string local_38 [32]; string *local_18; OptionBase<CLI::Option> *local_10; local_18 = param_1; local_10 = this; uVar1 = detail::valid_alias_name_string(param_1); if ((uVar1 & 1) == 0) { pIVar2 = (IncorrectConstruction *)__cxa_allocate_exception(0x38); std::allocator<char>::allocator(); /* try { // try from 00130e1c to 00130e2b has its CatchHandler @ 00130e5a */ std::__cxx11::string::string<std::allocator<char>> (local_38,"Group names may not contain newlines or null characters",&local_39); /* try { // try from 00130e2e to 00130e57 has its CatchHandler @ 00130e68 */ IncorrectConstruction::IncorrectConstruction(pIVar2,local_38); /* WARNING: Subroutine does not return */ __cxa_throw(pIVar2,&IncorrectConstruction::typeinfo, IncorrectConstruction::~IncorrectConstruction); } std::__cxx11::string::operator=((string *)this,local_18); return this; }
27,524
stbi_loadf
7CodeWizard[P]stablediffusion/thirdparty/stb_image.h
STBIDEF float *stbi_loadf(char const *filename, int *x, int *y, int *comp, int req_comp) { float *result; FILE *f = stbi__fopen(filename, "rb"); if (!f) return stbi__errpf("can't fopen", "Unable to open file"); result = stbi_loadf_from_file(f,x,y,comp,req_comp); fclose(f); return result; }
O0
c
stbi_loadf: subq $0x48, %rsp movq %rdi, 0x38(%rsp) movq %rsi, 0x30(%rsp) movq %rdx, 0x28(%rsp) movq %rcx, 0x20(%rsp) movl %r8d, 0x1c(%rsp) movq 0x38(%rsp), %rdi leaq 0x16e79b(%rip), %rsi # 0x17d6e4 callq 0xdda0 movq %rax, 0x8(%rsp) cmpq $0x0, 0x8(%rsp) jne 0xef79 leaq 0x16e785(%rip), %rdi # 0x17d6e7 callq 0xddd0 movl %eax, %ecx xorl %eax, %eax cmpl $0x0, %ecx cmovneq %rax, %rax movq %rax, 0x40(%rsp) jmp 0xefb0 movq 0x8(%rsp), %rdi movq 0x30(%rsp), %rsi movq 0x28(%rsp), %rdx movq 0x20(%rsp), %rcx movl 0x1c(%rsp), %r8d callq 0xefc0 movq %rax, 0x10(%rsp) movq 0x8(%rsp), %rdi callq 0xb770 movq 0x10(%rsp), %rax movq %rax, 0x40(%rsp) movq 0x40(%rsp), %rax addq $0x48, %rsp retq nopw (%rax,%rax)
stbi_loadf: sub rsp, 48h mov [rsp+48h+var_10], rdi mov [rsp+48h+var_18], rsi mov [rsp+48h+var_20], rdx mov [rsp+48h+var_28], rcx mov [rsp+48h+var_2C], r8d mov rdi, [rsp+48h+var_10]; char * lea rsi, aRb; "rb" call _ZL11stbi__fopenPKcS0_; stbi__fopen(char const*,char const*) mov [rsp+48h+var_40], rax cmp [rsp+48h+var_40], 0 jnz short loc_EF79 lea rdi, aCanTFopen; "can't fopen" call _ZL9stbi__errPKc; stbi__err(char const*) mov ecx, eax xor eax, eax cmp ecx, 0 cmovnz rax, rax mov [rsp+48h+var_8], rax jmp short loc_EFB0 loc_EF79: mov rdi, [rsp+48h+var_40] mov rsi, [rsp+48h+var_18] mov rdx, [rsp+48h+var_20] mov rcx, [rsp+48h+var_28] mov r8d, [rsp+48h+var_2C] call stbi_loadf_from_file mov [rsp+48h+var_38], rax mov rdi, [rsp+48h+var_40] call _fclose mov rax, [rsp+48h+var_38] mov [rsp+48h+var_8], rax loc_EFB0: mov rax, [rsp+48h+var_8] add rsp, 48h retn
long long stbi_loadf(const char *a1, long long a2, long long a3, long long a4, unsigned int a5) { long long v6; // [rsp+8h] [rbp-40h] long long v7; // [rsp+10h] [rbp-38h] v6 = stbi__fopen(a1, "rb"); if ( v6 ) { v7 = stbi_loadf_from_file(v6, a2, a3, a4, a5); fclose(v6); return v7; } else { stbi__err("can't fopen"); return 0LL; } }
stbi_loadf: SUB RSP,0x48 MOV qword ptr [RSP + 0x38],RDI MOV qword ptr [RSP + 0x30],RSI MOV qword ptr [RSP + 0x28],RDX MOV qword ptr [RSP + 0x20],RCX MOV dword ptr [RSP + 0x1c],R8D MOV RDI,qword ptr [RSP + 0x38] LEA RSI,[0x27d6e4] CALL 0x0010dda0 MOV qword ptr [RSP + 0x8],RAX CMP qword ptr [RSP + 0x8],0x0 JNZ 0x0010ef79 LEA RDI,[0x27d6e7] CALL 0x0010ddd0 MOV ECX,EAX XOR EAX,EAX CMP ECX,0x0 CMOVNZ RAX,RAX MOV qword ptr [RSP + 0x40],RAX JMP 0x0010efb0 LAB_0010ef79: MOV RDI,qword ptr [RSP + 0x8] MOV RSI,qword ptr [RSP + 0x30] MOV RDX,qword ptr [RSP + 0x28] MOV RCX,qword ptr [RSP + 0x20] MOV R8D,dword ptr [RSP + 0x1c] CALL 0x0010efc0 MOV qword ptr [RSP + 0x10],RAX MOV RDI,qword ptr [RSP + 0x8] CALL 0x0010b770 MOV RAX,qword ptr [RSP + 0x10] MOV qword ptr [RSP + 0x40],RAX LAB_0010efb0: MOV RAX,qword ptr [RSP + 0x40] ADD RSP,0x48 RET
int8 stbi_loadf(char *param_1,int8 param_2,int8 param_3,int8 param_4,int4 param_5 ) { FILE *__stream; int8 local_8; __stream = (FILE *)stbi__fopen(param_1,"rb"); if (__stream == (FILE *)0x0) { stbi__err("can\'t fopen"); local_8 = 0; } else { local_8 = stbi_loadf_from_file(__stream,param_2,param_3,param_4,param_5); fclose(__stream); } return local_8; }
27,525
b2d
eloqsql/strings/dtoa.c
static double b2d(Bigint *a, int *e) { ULong *xa, *xa0, w, y, z; int k; U d; #define d0 word0(&d) #define d1 word1(&d) xa0= a->p.x; xa= xa0 + a->wds; y= *--xa; k= hi0bits(y); *e= 32 - k; if (k < Ebits) { d0= Exp_1 | y >> (Ebits - k); w= xa > xa0 ? *--xa : 0; d1= y << ((32-Ebits) + k) | w >> (Ebits - k); goto ret_d; } z= xa > xa0 ? *--xa : 0; if (k-= Ebits) { d0= Exp_1 | y << k | z >> (32 - k); y= xa > xa0 ? *--xa : 0; d1= z << k | y >> (32 - k); } else { d0= Exp_1 | y; d1= z; } ret_d: #undef d0 #undef d1 return dval(&d); }
O0
c
b2d: pushq %rbp movq %rsp, %rbp subq $0x50, %rsp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq -0x8(%rbp), %rax movq (%rax), %rax movq %rax, -0x20(%rbp) movq -0x20(%rbp), %rax movq -0x8(%rbp), %rcx movslq 0x14(%rcx), %rcx shlq $0x2, %rcx addq %rcx, %rax movq %rax, -0x18(%rbp) movq -0x18(%rbp), %rax movq %rax, %rcx addq $-0x4, %rcx movq %rcx, -0x18(%rbp) movl -0x4(%rax), %eax movl %eax, -0x28(%rbp) movl -0x28(%rbp), %edi callq 0xd1720 movl %eax, -0x30(%rbp) movl $0x20, %ecx subl -0x30(%rbp), %ecx movq -0x10(%rbp), %rax movl %ecx, (%rax) cmpl $0xb, -0x30(%rbp) jge 0xd18bd movl -0x28(%rbp), %eax movl $0xb, %ecx subl -0x30(%rbp), %ecx shrl %cl, %eax orl $0x3ff00000, %eax # imm = 0x3FF00000 movl %eax, -0x34(%rbp) movq -0x18(%rbp), %rax cmpq -0x20(%rbp), %rax jbe 0xd188c movq -0x18(%rbp), %rax movq %rax, %rcx addq $-0x4, %rcx movq %rcx, -0x18(%rbp) movl -0x4(%rax), %eax movl %eax, -0x3c(%rbp) jmp 0xd1893 xorl %eax, %eax movl %eax, -0x3c(%rbp) jmp 0xd1893 movl -0x3c(%rbp), %eax movl %eax, -0x24(%rbp) movl -0x28(%rbp), %eax movl -0x30(%rbp), %ecx addl $0x15, %ecx shll %cl, %eax movl -0x24(%rbp), %edx movl $0xb, %ecx subl -0x30(%rbp), %ecx shrl %cl, %edx movl %edx, %ecx orl %ecx, %eax movl %eax, -0x38(%rbp) jmp 0xd1979 movq -0x18(%rbp), %rax cmpq -0x20(%rbp), %rax jbe 0xd18de movq -0x18(%rbp), %rax movq %rax, %rcx addq $-0x4, %rcx movq %rcx, -0x18(%rbp) movl -0x4(%rax), %eax movl %eax, -0x40(%rbp) jmp 0xd18e5 xorl %eax, %eax movl %eax, -0x40(%rbp) jmp 0xd18e5 movl -0x40(%rbp), %eax movl %eax, -0x2c(%rbp) movl -0x30(%rbp), %eax subl $0xb, %eax movl %eax, -0x30(%rbp) cmpl $0x0, %eax je 0xd1966 movl -0x28(%rbp), %eax movl -0x30(%rbp), %ecx shll %cl, %eax orl $0x3ff00000, %eax # imm = 0x3FF00000 movl -0x2c(%rbp), %edx movl $0x20, %ecx subl -0x30(%rbp), %ecx shrl %cl, %edx movl %edx, %ecx orl %ecx, %eax movl %eax, -0x34(%rbp) movq -0x18(%rbp), %rax cmpq -0x20(%rbp), %rax jbe 0xd193b movq -0x18(%rbp), %rax movq %rax, %rcx addq $-0x4, %rcx movq %rcx, -0x18(%rbp) movl -0x4(%rax), %eax movl %eax, -0x44(%rbp) jmp 0xd1942 xorl %eax, %eax movl %eax, -0x44(%rbp) jmp 0xd1942 movl -0x44(%rbp), %eax movl %eax, -0x28(%rbp) movl -0x2c(%rbp), %eax movl -0x30(%rbp), %ecx shll %cl, %eax movl -0x28(%rbp), %edx movl $0x20, %ecx subl -0x30(%rbp), %ecx shrl %cl, %edx movl %edx, %ecx orl %ecx, %eax movl %eax, -0x38(%rbp) jmp 0xd1977 movl -0x28(%rbp), %eax orl $0x3ff00000, %eax # imm = 0x3FF00000 movl %eax, -0x34(%rbp) movl -0x2c(%rbp), %eax movl %eax, -0x38(%rbp) jmp 0xd1979 movsd -0x38(%rbp), %xmm0 addq $0x50, %rsp popq %rbp retq nopw %cs:(%rax,%rax)
b2d: push rbp mov rbp, rsp sub rsp, 50h mov [rbp+var_8], rdi mov [rbp+var_10], rsi mov rax, [rbp+var_8] mov rax, [rax] mov [rbp+var_20], rax mov rax, [rbp+var_20] mov rcx, [rbp+var_8] movsxd rcx, dword ptr [rcx+14h] shl rcx, 2 add rax, rcx mov [rbp+var_18], rax mov rax, [rbp+var_18] mov rcx, rax add rcx, 0FFFFFFFFFFFFFFFCh mov [rbp+var_18], rcx mov eax, [rax-4] mov [rbp+var_28], eax mov edi, [rbp+var_28] call hi0bits mov [rbp+var_30], eax mov ecx, 20h ; ' ' sub ecx, [rbp+var_30] mov rax, [rbp+var_10] mov [rax], ecx cmp [rbp+var_30], 0Bh jge short loc_D18BD mov eax, [rbp+var_28] mov ecx, 0Bh sub ecx, [rbp+var_30] shr eax, cl or eax, 3FF00000h mov dword ptr [rbp+var_38+4], eax mov rax, [rbp+var_18] cmp rax, [rbp+var_20] jbe short loc_D188C mov rax, [rbp+var_18] mov rcx, rax add rcx, 0FFFFFFFFFFFFFFFCh mov [rbp+var_18], rcx mov eax, [rax-4] mov [rbp+var_3C], eax jmp short loc_D1893 loc_D188C: xor eax, eax mov [rbp+var_3C], eax jmp short $+2 loc_D1893: mov eax, [rbp+var_3C] mov [rbp+var_24], eax mov eax, [rbp+var_28] mov ecx, [rbp+var_30] add ecx, 15h shl eax, cl mov edx, [rbp+var_24] mov ecx, 0Bh sub ecx, [rbp+var_30] shr edx, cl mov ecx, edx or eax, ecx mov dword ptr [rbp+var_38], eax jmp loc_D1979 loc_D18BD: mov rax, [rbp+var_18] cmp rax, [rbp+var_20] jbe short loc_D18DE mov rax, [rbp+var_18] mov rcx, rax add rcx, 0FFFFFFFFFFFFFFFCh mov [rbp+var_18], rcx mov eax, [rax-4] mov [rbp+var_40], eax jmp short loc_D18E5 loc_D18DE: xor eax, eax mov [rbp+var_40], eax jmp short $+2 loc_D18E5: mov eax, [rbp+var_40] mov [rbp+var_2C], eax mov eax, [rbp+var_30] sub eax, 0Bh mov [rbp+var_30], eax cmp eax, 0 jz short loc_D1966 mov eax, [rbp+var_28] mov ecx, [rbp+var_30] shl eax, cl or eax, 3FF00000h mov edx, [rbp+var_2C] mov ecx, 20h ; ' ' sub ecx, [rbp+var_30] shr edx, cl mov ecx, edx or eax, ecx mov dword ptr [rbp+var_38+4], eax mov rax, [rbp+var_18] cmp rax, [rbp+var_20] jbe short loc_D193B mov rax, [rbp+var_18] mov rcx, rax add rcx, 0FFFFFFFFFFFFFFFCh mov [rbp+var_18], rcx mov eax, [rax-4] mov [rbp+var_44], eax jmp short loc_D1942 loc_D193B: xor eax, eax mov [rbp+var_44], eax jmp short $+2 loc_D1942: mov eax, [rbp+var_44] mov [rbp+var_28], eax mov eax, [rbp+var_2C] mov ecx, [rbp+var_30] shl eax, cl mov edx, [rbp+var_28] mov ecx, 20h ; ' ' sub ecx, [rbp+var_30] shr edx, cl mov ecx, edx or eax, ecx mov dword ptr [rbp+var_38], eax jmp short loc_D1977 loc_D1966: mov eax, [rbp+var_28] or eax, 3FF00000h mov dword ptr [rbp+var_38+4], eax mov eax, [rbp+var_2C] mov dword ptr [rbp+var_38], eax loc_D1977: jmp short $+2 loc_D1979: movsd xmm0, [rbp+var_38] add rsp, 50h pop rbp retn
double b2d(long long a1, _DWORD *a2) { int *v2; // rax unsigned int v4; // [rsp+Ch] [rbp-44h] unsigned int v5; // [rsp+10h] [rbp-40h] unsigned int v6; // [rsp+14h] [rbp-3Ch] long long v7; // [rsp+18h] [rbp-38h] int v8; // [rsp+20h] [rbp-30h] int v9; // [rsp+20h] [rbp-30h] long long v10; // [rsp+24h] [rbp-2Ch] unsigned long long v11; // [rsp+30h] [rbp-20h] int *v12; // [rsp+38h] [rbp-18h] v11 = *(_QWORD *)a1; v12 = (int *)(4LL * *(int *)(a1 + 20) + *(_QWORD *)a1 - 4); HIDWORD(v10) = *v12; v8 = hi0bits(*v12); *a2 = 32 - v8; if ( v8 >= 11 ) { if ( (unsigned long long)v12 <= v11 ) { v5 = 0; } else { v2 = v12--; v5 = *(v2 - 1); } LODWORD(v10) = v5; v9 = v8 - 11; if ( v9 ) { HIDWORD(v7) = (v5 >> (32 - v9)) | (HIDWORD(v10) << v9) | 0x3FF00000; if ( (unsigned long long)v12 <= v11 ) v4 = 0; else v4 = *(v12 - 1); LODWORD(v7) = (v4 >> (32 - v9)) | (v5 << v9); } else { v7 = v10 | 0x3FF0000000000000LL; } } else { HIDWORD(v7) = (HIDWORD(v10) >> (11 - v8)) | 0x3FF00000; if ( (unsigned long long)v12 <= v11 ) v6 = 0; else v6 = *(v12 - 1); LODWORD(v7) = (v6 >> (11 - v8)) | (HIDWORD(v10) << (v8 + 21)); } return *(double *)&v7; }
b2d: PUSH RBP MOV RBP,RSP SUB RSP,0x50 MOV qword ptr [RBP + -0x8],RDI MOV qword ptr [RBP + -0x10],RSI MOV RAX,qword ptr [RBP + -0x8] MOV RAX,qword ptr [RAX] MOV qword ptr [RBP + -0x20],RAX MOV RAX,qword ptr [RBP + -0x20] MOV RCX,qword ptr [RBP + -0x8] MOVSXD RCX,dword ptr [RCX + 0x14] SHL RCX,0x2 ADD RAX,RCX MOV qword ptr [RBP + -0x18],RAX MOV RAX,qword ptr [RBP + -0x18] MOV RCX,RAX ADD RCX,-0x4 MOV qword ptr [RBP + -0x18],RCX MOV EAX,dword ptr [RAX + -0x4] MOV dword ptr [RBP + -0x28],EAX MOV EDI,dword ptr [RBP + -0x28] CALL 0x001d1720 MOV dword ptr [RBP + -0x30],EAX MOV ECX,0x20 SUB ECX,dword ptr [RBP + -0x30] MOV RAX,qword ptr [RBP + -0x10] MOV dword ptr [RAX],ECX CMP dword ptr [RBP + -0x30],0xb JGE 0x001d18bd MOV EAX,dword ptr [RBP + -0x28] MOV ECX,0xb SUB ECX,dword ptr [RBP + -0x30] SHR EAX,CL OR EAX,0x3ff00000 MOV dword ptr [RBP + -0x34],EAX MOV RAX,qword ptr [RBP + -0x18] CMP RAX,qword ptr [RBP + -0x20] JBE 0x001d188c MOV RAX,qword ptr [RBP + -0x18] MOV RCX,RAX ADD RCX,-0x4 MOV qword ptr [RBP + -0x18],RCX MOV EAX,dword ptr [RAX + -0x4] MOV dword ptr [RBP + -0x3c],EAX JMP 0x001d1893 LAB_001d188c: XOR EAX,EAX MOV dword ptr [RBP + -0x3c],EAX JMP 0x001d1893 LAB_001d1893: MOV EAX,dword ptr [RBP + -0x3c] MOV dword ptr [RBP + -0x24],EAX MOV EAX,dword ptr [RBP + -0x28] MOV ECX,dword ptr [RBP + -0x30] ADD ECX,0x15 SHL EAX,CL MOV EDX,dword ptr [RBP + -0x24] MOV ECX,0xb SUB ECX,dword ptr [RBP + -0x30] SHR EDX,CL MOV ECX,EDX OR EAX,ECX MOV dword ptr [RBP + -0x38],EAX JMP 0x001d1979 LAB_001d18bd: MOV RAX,qword ptr [RBP + -0x18] CMP RAX,qword ptr [RBP + -0x20] JBE 0x001d18de MOV RAX,qword ptr [RBP + -0x18] MOV RCX,RAX ADD RCX,-0x4 MOV qword ptr [RBP + -0x18],RCX MOV EAX,dword ptr [RAX + -0x4] MOV dword ptr [RBP + -0x40],EAX JMP 0x001d18e5 LAB_001d18de: XOR EAX,EAX MOV dword ptr [RBP + -0x40],EAX JMP 0x001d18e5 LAB_001d18e5: MOV EAX,dword ptr [RBP + -0x40] MOV dword ptr [RBP + -0x2c],EAX MOV EAX,dword ptr [RBP + -0x30] SUB EAX,0xb MOV dword ptr [RBP + -0x30],EAX CMP EAX,0x0 JZ 0x001d1966 MOV EAX,dword ptr [RBP + -0x28] MOV ECX,dword ptr [RBP + -0x30] SHL EAX,CL OR EAX,0x3ff00000 MOV EDX,dword ptr [RBP + -0x2c] MOV ECX,0x20 SUB ECX,dword ptr [RBP + -0x30] SHR EDX,CL MOV ECX,EDX OR EAX,ECX MOV dword ptr [RBP + -0x34],EAX MOV RAX,qword ptr [RBP + -0x18] CMP RAX,qword ptr [RBP + -0x20] JBE 0x001d193b MOV RAX,qword ptr [RBP + -0x18] MOV RCX,RAX ADD RCX,-0x4 MOV qword ptr [RBP + -0x18],RCX MOV EAX,dword ptr [RAX + -0x4] MOV dword ptr [RBP + -0x44],EAX JMP 0x001d1942 LAB_001d193b: XOR EAX,EAX MOV dword ptr [RBP + -0x44],EAX JMP 0x001d1942 LAB_001d1942: MOV EAX,dword ptr [RBP + -0x44] MOV dword ptr [RBP + -0x28],EAX MOV EAX,dword ptr [RBP + -0x2c] MOV ECX,dword ptr [RBP + -0x30] SHL EAX,CL MOV EDX,dword ptr [RBP + -0x28] MOV ECX,0x20 SUB ECX,dword ptr [RBP + -0x30] SHR EDX,CL MOV ECX,EDX OR EAX,ECX MOV dword ptr [RBP + -0x38],EAX JMP 0x001d1977 LAB_001d1966: MOV EAX,dword ptr [RBP + -0x28] OR EAX,0x3ff00000 MOV dword ptr [RBP + -0x34],EAX MOV EAX,dword ptr [RBP + -0x2c] MOV dword ptr [RBP + -0x38],EAX LAB_001d1977: JMP 0x001d1979 LAB_001d1979: MOVSD XMM0,qword ptr [RBP + -0x38] ADD RSP,0x50 POP RBP RET
int8 b2d(ulong *param_1,int *param_2) { uint uVar1; ulong uVar2; char cVar3; int iVar4; long lVar5; byte bVar6; int4 local_4c; int4 local_48; int4 local_44; int4 local_40; int4 uStack_3c; int8 local_20; uVar2 = *param_1; lVar5 = uVar2 + (long)*(int *)((long)param_1 + 0x14) * 4; local_20 = lVar5 - 4; uVar1 = *(uint *)(lVar5 + -4); iVar4 = hi0bits(uVar1); *param_2 = 0x20 - iVar4; if (iVar4 < 0xb) { cVar3 = (char)iVar4; uStack_3c = uVar1 >> (0xbU - cVar3 & 0x1f) | 0x3ff00000; if (uVar2 < local_20) { local_44 = *(uint *)(lVar5 + -8); } else { local_44 = 0; } local_40 = uVar1 << (cVar3 + 0x15U & 0x1f) | local_44 >> (0xbU - cVar3 & 0x1f); } else { if (uVar2 < local_20) { local_20 = lVar5 - 8; local_48 = *(uint *)(lVar5 + -8); } else { local_48 = 0; } if (iVar4 + -0xb == 0) { uStack_3c = uVar1 | 0x3ff00000; local_40 = local_48; } else { bVar6 = (byte)(iVar4 + -0xb); uStack_3c = uVar1 << (bVar6 & 0x1f) | 0x3ff00000 | local_48 >> (0x20 - bVar6 & 0x1f); if (uVar2 < local_20) { local_4c = *(uint *)(local_20 - 4); } else { local_4c = 0; } local_40 = local_48 << (bVar6 & 0x1f) | local_4c >> (0x20 - bVar6 & 0x1f); } } return CONCAT44(uStack_3c,local_40); }
27,526
str2int
eloqsql/strings/str2int.c
char *str2int(register const char *src, register int radix, long int lower, long int upper, long int *val) { int sign; /* is number negative (+1) or positive (-1) */ int n; /* number of digits yet to be converted */ long limit; /* "largest" possible valid input */ long scale; /* the amount to multiply next digit by */ long sofar; /* the running value */ register int d; /* (negative of) next digit */ char *start; int digits[32]; /* Room for numbers */ /* Make sure *val is sensible in case of error */ *val = 0; /* Check that the radix is in the range 2..36 */ #ifndef DBUG_OFF if (radix < 2 || radix > 36) { errno=EDOM; return NullS; } #endif /* The basic problem is: how do we handle the conversion of a number without resorting to machine-specific code to check for overflow? Obviously, we have to ensure that no calculation can overflow. We are guaranteed that the "lower" and "upper" arguments are valid machine integers. On sign-and-magnitude, twos-complement, and ones-complement machines all, if +|n| is representable, so is -|n|, but on twos complement machines the converse is not true. So the "maximum" representable number has a negative representative. Limit is set to MY_MIN(-|lower|,-|upper|); this is the "largest" number we are concerned with. */ /* Calculate Limit using Scale as a scratch variable */ if ((limit = lower) > 0) limit = -limit; if ((scale = upper) > 0) scale = -scale; if (scale < limit) limit = scale; /* Skip leading spaces and check for a sign. Note: because on a 2s complement machine MinLong is a valid integer but |MinLong| is not, we have to keep the current converted value (and the scale!) as *negative* numbers, so the sign is the opposite of what you might expect. */ while (my_isspace(&my_charset_latin1,*src)) src++; sign = -1; if (*src == '+') src++; else if (*src == '-') src++, sign = 1; /* Skip leading zeros so that we never compute a power of radix in scale that we won't have a need for. Otherwise sticking enough 0s in front of a number could cause the multiplication to overflow when it neededn't. */ start=(char*) src; while (*src == '0') src++; /* Move over the remaining digits. We have to convert from left to left in order to avoid overflow. Answer is after last digit. */ for (n = 0; (digits[n]=char_val(*src)) < radix && n < 20; n++,src++) ; /* Check that there is at least one digit */ if (start == src) { errno=EDOM; return NullS; } /* The invariant we want to maintain is that src is just to the right of n digits, we've converted k digits to sofar, scale = -radix**k, and scale < sofar < 0. Now if the final number is to be within the original Limit, we must have (to the left)*scale+sofar >= Limit, or (to the left)*scale >= Limit-sofar, i.e. the digits to the left of src must form an integer <= (Limit-sofar)/(scale). In particular, this is true of the next digit. In our incremental calculation of Limit, IT IS VITAL that (-|N|)/(-|D|) = |N|/|D| */ for (sofar = 0, scale = -1; --n >= 1;) { if ((long) -(d=digits[n]) < limit) { errno=ERANGE; return NullS; } limit = (limit+d)/radix, sofar += d*scale; scale *= radix; } if (n == 0) { if ((long) -(d=digits[n]) < limit) /* get last digit */ { errno=ERANGE; return NullS; } sofar+=d*scale; } /* Now it might still happen that sofar = -32768 or its equivalent, so we can't just multiply by the sign and check that the result is in the range lower..upper. All of this caution is a right pain in the neck. If only there were a standard routine which says generate thus and such a signal on integer overflow... But not enough machines can do it *SIGH*. */ if (sign < 0) { if (sofar < -LONG_MAX || (sofar= -sofar) > upper) { errno=ERANGE; return NullS; } } else if (sofar < lower) { errno=ERANGE; return NullS; } *val = sofar; errno=0; /* indicate that all went well */ return (char*) src; }
O3
c
str2int: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r12 pushq %rbx subq $0x80, %rsp movq %rdx, %r9 movq $0x0, (%r8) movq %rdx, %rax negq %rax cmovsq %rdx, %rax movq %rcx, %rdx negq %rdx cmovnsq %rcx, %rdx leaq 0x2bdd09(%rip), %r10 # 0x31cf40 movq 0x40(%r10), %r11 movzbl (%rdi), %r10d incq %rdi testb $0x8, 0x1(%r11,%r10) jne 0x5f23b negq %rax cmpq %rax, %rdx cmovlq %rdx, %rax cmpl $0x2b, %r10d je 0x5f268 cmpl $0x2d, %r10d jne 0x5f265 xorl %r10d, %r10d jmp 0x5f26b decq %rdi movb $0x1, %r10b leaq -0x1(%rdi), %rbx movb 0x1(%rbx), %r14b incq %rbx cmpb $0x30, %r14b je 0x5f26f xorl %r11d, %r11d xorl %edx, %edx leal -0x30(%r14), %r15d cmpb $0x9, %r15b ja 0x5f291 movzbl %r15b, %r15d jmp 0x5f2bd leal -0x41(%r14), %r15d cmpb $0x19, %r15b ja 0x5f2a5 movzbl %r14b, %r15d addl $-0x37, %r15d jmp 0x5f2bd leal -0x61(%r14), %r12d movl $0x7f, %r15d cmpb $0x19, %r12b ja 0x5f2bd movzbl %r14b, %r15d addl $-0x57, %r15d movl %r15d, -0xa0(%rbp,%rdx,4) cmpl %esi, %r15d jge 0x5f2df cmpq $0x13, %rdx ja 0x5f2df incq %rdx movb 0x1(%rbx), %r14b incq %rbx incl %r11d jmp 0x5f281 cmpq %rdi, %rbx je 0x5f327 cmpq $0x2, %rdx jb 0x5f32f movslq %esi, %r14 movq $-0x1, %rdi xorl %esi, %esi decl %r11d movslq -0xa0(%rbp,%r11,4), %r15 movq %r15, %rdx negq %rdx cmpq %rdx, %rax jg 0x5f36a addq %r15, %rax cqto idivq %r14 imulq %rdi, %r15 addq %r15, %rsi imulq %r14, %rdi cmpl $0x1, %r11d jg 0x5f2f6 jmp 0x5f33c movl $0x21, %r14d jmp 0x5f370 xorl %esi, %esi decl %edx jne 0x5f355 movq $-0x1, %rdi movslq -0xa0(%rbp), %rdx movq %rdx, %r11 negq %r11 cmpq %r11, %rax jg 0x5f36a imulq %rdx, %rdi addq %rdi, %rsi testb %r10b, %r10b je 0x5f38d negq %rsi seto %al cmpq %rcx, %rsi setg %cl orb %al, %cl je 0x5f392 movl $0x22, %r14d xorl %ebx, %ebx callq 0x24060 movl %r14d, (%rax) movq %rbx, %rax addq $0x80, %rsp popq %rbx popq %r12 popq %r14 popq %r15 popq %rbp retq cmpq %r9, %rsi jl 0x5f36a movq %rsi, (%r8) xorl %r14d, %r14d jmp 0x5f372 nop
str2int: push rbp mov rbp, rsp push r15 push r14 push r12 push rbx sub rsp, 80h mov r9, rdx mov qword ptr [r8], 0 mov rax, rdx neg rax cmovs rax, rdx mov rdx, rcx neg rdx cmovns rdx, rcx lea r10, my_charset_latin1 mov r11, [r10+40h] loc_5F23B: movzx r10d, byte ptr [rdi] inc rdi test byte ptr [r11+r10+1], 8 jnz short loc_5F23B neg rax cmp rdx, rax cmovl rax, rdx cmp r10d, 2Bh ; '+' jz short loc_5F268 cmp r10d, 2Dh ; '-' jnz short loc_5F265 xor r10d, r10d jmp short loc_5F26B loc_5F265: dec rdi loc_5F268: mov r10b, 1 loc_5F26B: lea rbx, [rdi-1] loc_5F26F: mov r14b, [rbx+1] inc rbx cmp r14b, 30h ; '0' jz short loc_5F26F xor r11d, r11d xor edx, edx loc_5F281: lea r15d, [r14-30h] cmp r15b, 9 ja short loc_5F291 movzx r15d, r15b jmp short loc_5F2BD loc_5F291: lea r15d, [r14-41h] cmp r15b, 19h ja short loc_5F2A5 movzx r15d, r14b add r15d, 0FFFFFFC9h jmp short loc_5F2BD loc_5F2A5: lea r12d, [r14-61h] mov r15d, 7Fh cmp r12b, 19h ja short loc_5F2BD movzx r15d, r14b add r15d, 0FFFFFFA9h loc_5F2BD: mov [rbp+rdx*4+var_A0], r15d cmp r15d, esi jge short loc_5F2DF cmp rdx, 13h ja short loc_5F2DF inc rdx mov r14b, [rbx+1] inc rbx inc r11d jmp short loc_5F281 loc_5F2DF: cmp rbx, rdi jz short loc_5F327 cmp rdx, 2 jb short loc_5F32F movsxd r14, esi mov rdi, 0FFFFFFFFFFFFFFFFh xor esi, esi loc_5F2F6: dec r11d movsxd r15, [rbp+r11*4+var_A0] mov rdx, r15 neg rdx cmp rax, rdx jg short loc_5F36A add rax, r15 cqo idiv r14 imul r15, rdi add rsi, r15 imul rdi, r14 cmp r11d, 1 jg short loc_5F2F6 jmp short loc_5F33C loc_5F327: mov r14d, 21h ; '!' jmp short loc_5F370 loc_5F32F: xor esi, esi dec edx jnz short loc_5F355 mov rdi, 0FFFFFFFFFFFFFFFFh loc_5F33C: movsxd rdx, [rbp+var_A0] mov r11, rdx neg r11 cmp rax, r11 jg short loc_5F36A imul rdi, rdx add rsi, rdi loc_5F355: test r10b, r10b jz short loc_5F38D neg rsi seto al cmp rsi, rcx setnle cl or cl, al jz short loc_5F392 loc_5F36A: mov r14d, 22h ; '"' loc_5F370: xor ebx, ebx loc_5F372: call ___errno_location mov [rax], r14d mov rax, rbx add rsp, 80h pop rbx pop r12 pop r14 pop r15 pop rbp retn loc_5F38D: cmp rsi, r9 jl short loc_5F36A loc_5F392: mov [r8], rsi xor r14d, r14d jmp short loc_5F372
long long str2int(long long a1, int a2, long long a3, long long a4, long long *a5) { long long v6; // rax long long v7; // rdx long long v8; // r10 long long v9; // rax char v10; // r10 long long v11; // rbx unsigned __int8 v12; // r14 long long v13; // r11 unsigned long long i; // rdx int v15; // r15d long long v16; // r14 long long v17; // rsi long long v18; // r15 int v19; // r14d _DWORD v21[40]; // [rsp+0h] [rbp-A0h] *a5 = 0LL; v6 = -a3; if ( a3 > 0 ) v6 = a3; v7 = -a4; if ( a4 <= 0 ) v7 = a4; do v8 = *(unsigned __int8 *)a1++; while ( (*(_BYTE *)(*(_QWORD *)&my_charset_latin1[16] + v8 + 1) & 8) != 0 ); v9 = -v6; if ( v7 < v9 ) v9 = v7; if ( (_DWORD)v8 != 43 ) { if ( (_DWORD)v8 == 45 ) { v10 = 0; goto LABEL_13; } --a1; } v10 = 1; LABEL_13: v11 = a1 - 1; do v12 = *(_BYTE *)++v11; while ( v12 == 48 ); LODWORD(v13) = 0; for ( i = 0LL; ; ++i ) { LOBYTE(v15) = v12 - 48; if ( (unsigned __int8)(v12 - 48) > 9u ) { if ( (unsigned __int8)(v12 - 65) > 0x19u ) { v15 = 127; if ( (unsigned __int8)(v12 - 97) <= 0x19u ) v15 = v12 - 87; } else { v15 = v12 - 55; } } else { v15 = (unsigned __int8)v15; } v21[i] = v15; if ( v15 >= a2 || i > 0x13 ) break; v12 = *(_BYTE *)++v11; LODWORD(v13) = v13 + 1; } if ( v11 != a1 ) { if ( i >= 2 ) { v16 = a2; a1 = -1LL; v17 = 0LL; while ( 1 ) { v13 = (unsigned int)(v13 - 1); v18 = (int)v21[v13]; if ( v9 > -v18 ) goto LABEL_38; v9 = (v18 + v9) / v16; v17 += a1 * v18; a1 *= v16; if ( (int)v13 <= 1 ) goto LABEL_34; } } v17 = 0LL; if ( (_DWORD)i == 1 ) { a1 = -1LL; LABEL_34: if ( v9 > -(long long)v21[0] ) goto LABEL_38; a1 *= v21[0]; v17 += a1; } if ( v10 ) { v17 = -v17; if ( __OFSUB__(v17, 1LL) || v17 > a4 ) { LABEL_38: v19 = 34; goto LABEL_39; } } else if ( v17 < a3 ) { goto LABEL_38; } *a5 = v17; v19 = 0; goto LABEL_40; } v19 = 33; LABEL_39: v11 = 0LL; LABEL_40: *(_DWORD *)__errno_location(a1) = v19; return v11; }
str2int: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R12 PUSH RBX SUB RSP,0x80 MOV R9,RDX MOV qword ptr [R8],0x0 MOV RAX,RDX NEG RAX CMOVS RAX,RDX MOV RDX,RCX NEG RDX CMOVNS RDX,RCX LEA R10,[0x41cf40] MOV R11,qword ptr [R10 + 0x40] LAB_0015f23b: MOVZX R10D,byte ptr [RDI] INC RDI TEST byte ptr [R11 + R10*0x1 + 0x1],0x8 JNZ 0x0015f23b NEG RAX CMP RDX,RAX CMOVL RAX,RDX CMP R10D,0x2b JZ 0x0015f268 CMP R10D,0x2d JNZ 0x0015f265 XOR R10D,R10D JMP 0x0015f26b LAB_0015f265: DEC RDI LAB_0015f268: MOV R10B,0x1 LAB_0015f26b: LEA RBX,[RDI + -0x1] LAB_0015f26f: MOV R14B,byte ptr [RBX + 0x1] INC RBX CMP R14B,0x30 JZ 0x0015f26f XOR R11D,R11D XOR EDX,EDX LAB_0015f281: LEA R15D,[R14 + -0x30] CMP R15B,0x9 JA 0x0015f291 MOVZX R15D,R15B JMP 0x0015f2bd LAB_0015f291: LEA R15D,[R14 + -0x41] CMP R15B,0x19 JA 0x0015f2a5 MOVZX R15D,R14B ADD R15D,-0x37 JMP 0x0015f2bd LAB_0015f2a5: LEA R12D,[R14 + -0x61] MOV R15D,0x7f CMP R12B,0x19 JA 0x0015f2bd MOVZX R15D,R14B ADD R15D,-0x57 LAB_0015f2bd: MOV dword ptr [RBP + RDX*0x4 + -0xa0],R15D CMP R15D,ESI JGE 0x0015f2df CMP RDX,0x13 JA 0x0015f2df INC RDX MOV R14B,byte ptr [RBX + 0x1] INC RBX INC R11D JMP 0x0015f281 LAB_0015f2df: CMP RBX,RDI JZ 0x0015f327 CMP RDX,0x2 JC 0x0015f32f MOVSXD R14,ESI MOV RDI,-0x1 XOR ESI,ESI LAB_0015f2f6: DEC R11D MOVSXD R15,dword ptr [RBP + R11*0x4 + -0xa0] MOV RDX,R15 NEG RDX CMP RAX,RDX JG 0x0015f36a ADD RAX,R15 CQO IDIV R14 IMUL R15,RDI ADD RSI,R15 IMUL RDI,R14 CMP R11D,0x1 JG 0x0015f2f6 JMP 0x0015f33c LAB_0015f327: MOV R14D,0x21 JMP 0x0015f370 LAB_0015f32f: XOR ESI,ESI DEC EDX JNZ 0x0015f355 MOV RDI,-0x1 LAB_0015f33c: MOVSXD RDX,dword ptr [RBP + -0xa0] MOV R11,RDX NEG R11 CMP RAX,R11 JG 0x0015f36a IMUL RDI,RDX ADD RSI,RDI LAB_0015f355: TEST R10B,R10B JZ 0x0015f38d NEG RSI SETO AL CMP RSI,RCX SETG CL OR CL,AL JZ 0x0015f392 LAB_0015f36a: MOV R14D,0x22 LAB_0015f370: XOR EBX,EBX LAB_0015f372: CALL 0x00124060 MOV dword ptr [RAX],R14D MOV RAX,RBX ADD RSP,0x80 POP RBX POP R12 POP R14 POP R15 POP RBP RET LAB_0015f38d: CMP RSI,R9 JL 0x0015f36a LAB_0015f392: MOV qword ptr [R8],RSI XOR R14D,R14D JMP 0x0015f372
byte * str2int(byte *param_1,int param_2,long param_3,long param_4,long *param_5) { long lVar1; int *piVar2; ulong uVar3; byte *pbVar4; long lVar5; byte *pbVar6; long lVar7; ulong uVar8; byte bVar9; int iVar10; uint uVar11; long lVar12; bool bVar13; uint local_a8 [32]; *param_5 = 0; lVar5 = -param_3; if (0 < param_3) { lVar5 = param_3; } lVar7 = -param_4; if (param_4 < 1) { lVar7 = param_4; } do { pbVar4 = param_1; bVar9 = *pbVar4; param_1 = pbVar4 + 1; } while ((PTR_ctype_latin1_0041cf80[(ulong)bVar9 + 1] & 8) != 0); lVar1 = -lVar5; if (SBORROW8(lVar7,-lVar5) != lVar7 + lVar5 < 0) { lVar1 = lVar7; } pbVar6 = param_1; if ((bVar9 == 0x2b) || (pbVar6 = pbVar4, bVar9 != 0x2d)) { bVar13 = true; } else { bVar13 = false; pbVar6 = param_1; } pbVar4 = pbVar6 + -1; do { bVar9 = pbVar4[1]; pbVar4 = pbVar4 + 1; } while (bVar9 == 0x30); uVar8 = 0; uVar3 = 0; while( true ) { if ((byte)(bVar9 - 0x30) < 10) { uVar11 = (uint)(byte)(bVar9 - 0x30); } else if ((byte)(bVar9 + 0xbf) < 0x1a) { uVar11 = bVar9 - 0x37; } else { uVar11 = 0x7f; if ((byte)(bVar9 + 0x9f) < 0x1a) { uVar11 = bVar9 - 0x57; } } local_a8[uVar3] = uVar11; if ((param_2 <= (int)uVar11) || (0x13 < uVar3)) break; uVar3 = uVar3 + 1; bVar9 = pbVar4[1]; pbVar4 = pbVar4 + 1; uVar8 = (ulong)((int)uVar8 + 1); } if (pbVar4 == pbVar6) { iVar10 = 0x21; } else { if (uVar3 < 2) { lVar5 = 0; if ((int)uVar3 == 1) { lVar7 = -1; goto LAB_0015f33c; } LAB_0015f355: if (bVar13) { lVar7 = -lVar5; bVar13 = -param_4 == lVar5; lVar5 = lVar7; if (bVar13 || lVar7 < param_4) { LAB_0015f392: *param_5 = lVar5; iVar10 = 0; goto LAB_0015f372; } } else if (param_3 <= lVar5) goto LAB_0015f392; } else { lVar7 = -1; lVar5 = 0; do { uVar11 = (int)uVar8 - 1; uVar8 = (ulong)uVar11; lVar12 = (long)(int)local_a8[uVar8]; if (lVar1 != -lVar12 && SBORROW8(lVar1,-lVar12) == lVar1 + lVar12 < 0) goto LAB_0015f36a; lVar1 = (lVar1 + lVar12) / (long)param_2; lVar5 = lVar5 + lVar12 * lVar7; lVar7 = lVar7 * param_2; } while (1 < (int)uVar11); LAB_0015f33c: lVar12 = (long)(int)local_a8[0]; if (lVar1 == -lVar12 || SBORROW8(lVar1,-lVar12) != lVar1 + lVar12 < 0) { lVar5 = lVar5 + lVar7 * lVar12; goto LAB_0015f355; } } LAB_0015f36a: iVar10 = 0x22; } pbVar4 = (byte *)0x0; LAB_0015f372: piVar2 = __errno_location(); *piVar2 = iVar10; return pbVar4; }
27,527
ma_stmt_execute_generate_request
eloqsql/libmariadb/libmariadb/mariadb_stmt.c
unsigned char* ma_stmt_execute_generate_request(MYSQL_STMT *stmt, size_t *request_len, my_bool internal) { unsigned char *buf; if (stmt->request_buffer) { *request_len= stmt->request_length; buf= stmt->request_buffer; /* store actual stmt id */ int4store(buf, stmt->stmt_id); /* clear buffer, memory will be freed in execute */ stmt->request_buffer= NULL; stmt->request_length= 0; return buf; } if (stmt->array_size > 0) buf= ma_stmt_execute_generate_bulk_request(stmt, request_len); else buf= ma_stmt_execute_generate_simple_request(stmt, request_len); if (internal) { if (stmt->request_buffer) free(stmt->request_buffer); stmt->request_buffer= buf; stmt->request_length= *request_len; } return buf; }
O3
c
ma_stmt_execute_generate_request: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r12 pushq %rbx movq %rsi, %r14 movq %rdi, %rbx cmpq $0x0, 0x360(%rdi) je 0x22add movq 0x398(%rbx), %rax movq %rax, (%r14) movq 0x360(%rbx), %r15 movb 0x40(%rbx), %al movb %al, (%r15) movb 0x41(%rbx), %al movb %al, 0x1(%r15) movb 0x42(%rbx), %al movb %al, 0x2(%r15) movb 0x43(%rbx), %al movb %al, 0x3(%r15) xorl %eax, %eax movq %rax, 0x360(%rbx) jmp 0x22b24 movl %edx, %r12d cmpl $0x0, 0x368(%rbx) je 0x22af6 movq %rbx, %rdi movq %r14, %rsi callq 0x22632 jmp 0x22b01 movq %rbx, %rdi movq %r14, %rsi callq 0x222bb movq %rax, %r15 testb %r12b, %r12b je 0x22b2b movq 0x360(%rbx), %rdi testq %rdi, %rdi je 0x22b1a callq 0x13570 movq %r15, 0x360(%rbx) movq (%r14), %rax movq %rax, 0x398(%rbx) movq %r15, %rax popq %rbx popq %r12 popq %r14 popq %r15 popq %rbp retq
ma_stmt_execute_generate_request: push rbp mov rbp, rsp push r15 push r14 push r12 push rbx mov r14, rsi mov rbx, rdi cmp qword ptr [rdi+360h], 0 jz short loc_22ADD mov rax, [rbx+398h] mov [r14], rax mov r15, [rbx+360h] mov al, [rbx+40h] mov [r15], al mov al, [rbx+41h] mov [r15+1], al mov al, [rbx+42h] mov [r15+2], al mov al, [rbx+43h] mov [r15+3], al xor eax, eax mov [rbx+360h], rax jmp short loc_22B24 loc_22ADD: mov r12d, edx cmp dword ptr [rbx+368h], 0 jz short loc_22AF6 mov rdi, rbx mov rsi, r14 call ma_stmt_execute_generate_bulk_request jmp short loc_22B01 loc_22AF6: mov rdi, rbx mov rsi, r14 call ma_stmt_execute_generate_simple_request loc_22B01: mov r15, rax test r12b, r12b jz short loc_22B2B mov rdi, [rbx+360h] test rdi, rdi jz short loc_22B1A call _free loc_22B1A: mov [rbx+360h], r15 mov rax, [r14] loc_22B24: mov [rbx+398h], rax loc_22B2B: mov rax, r15 pop rbx pop r12 pop r14 pop r15 pop rbp retn
_BYTE * ma_stmt_execute_generate_request(long long a1, long long *a2, char a3) { _BYTE *v4; // r15 long long v5; // rax long long bulk_request; // rax long long v8; // rdi if ( *(_QWORD *)(a1 + 864) ) { *a2 = *(_QWORD *)(a1 + 920); v4 = *(_BYTE **)(a1 + 864); *v4 = *(_BYTE *)(a1 + 64); v4[1] = *(_BYTE *)(a1 + 65); v4[2] = *(_BYTE *)(a1 + 66); v4[3] = *(_BYTE *)(a1 + 67); v5 = 0LL; *(_QWORD *)(a1 + 864) = 0LL; LABEL_10: *(_QWORD *)(a1 + 920) = v5; return v4; } if ( *(_DWORD *)(a1 + 872) ) bulk_request = ma_stmt_execute_generate_bulk_request(a1, a2); else bulk_request = ma_stmt_execute_generate_simple_request(a1, a2); v4 = (_BYTE *)bulk_request; if ( a3 ) { v8 = *(_QWORD *)(a1 + 864); if ( v8 ) free(v8); *(_QWORD *)(a1 + 864) = v4; v5 = *a2; goto LABEL_10; } return v4; }
ma_stmt_execute_generate_request: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R12 PUSH RBX MOV R14,RSI MOV RBX,RDI CMP qword ptr [RDI + 0x360],0x0 JZ 0x00122add MOV RAX,qword ptr [RBX + 0x398] MOV qword ptr [R14],RAX MOV R15,qword ptr [RBX + 0x360] MOV AL,byte ptr [RBX + 0x40] MOV byte ptr [R15],AL MOV AL,byte ptr [RBX + 0x41] MOV byte ptr [R15 + 0x1],AL MOV AL,byte ptr [RBX + 0x42] MOV byte ptr [R15 + 0x2],AL MOV AL,byte ptr [RBX + 0x43] MOV byte ptr [R15 + 0x3],AL XOR EAX,EAX MOV qword ptr [RBX + 0x360],RAX JMP 0x00122b24 LAB_00122add: MOV R12D,EDX CMP dword ptr [RBX + 0x368],0x0 JZ 0x00122af6 MOV RDI,RBX MOV RSI,R14 CALL 0x00122632 JMP 0x00122b01 LAB_00122af6: MOV RDI,RBX MOV RSI,R14 CALL 0x001222bb LAB_00122b01: MOV R15,RAX TEST R12B,R12B JZ 0x00122b2b MOV RDI,qword ptr [RBX + 0x360] TEST RDI,RDI JZ 0x00122b1a CALL 0x00113570 LAB_00122b1a: MOV qword ptr [RBX + 0x360],R15 MOV RAX,qword ptr [R14] LAB_00122b24: MOV qword ptr [RBX + 0x398],RAX LAB_00122b2b: MOV RAX,R15 POP RBX POP R12 POP R14 POP R15 POP RBP RET
int1 * ma_stmt_execute_generate_request(long param_1,int8 *param_2,char param_3) { int8 uVar1; int1 *puVar2; if (*(long *)(param_1 + 0x360) == 0) { if (*(int *)(param_1 + 0x368) == 0) { puVar2 = (int1 *)ma_stmt_execute_generate_simple_request(param_1,param_2); } else { puVar2 = (int1 *)ma_stmt_execute_generate_bulk_request(param_1,param_2); } if (param_3 == '\0') { return puVar2; } if (*(void **)(param_1 + 0x360) != (void *)0x0) { free(*(void **)(param_1 + 0x360)); } *(int1 **)(param_1 + 0x360) = puVar2; uVar1 = *param_2; } else { *param_2 = *(int8 *)(param_1 + 0x398); puVar2 = *(int1 **)(param_1 + 0x360); *puVar2 = *(int1 *)(param_1 + 0x40); puVar2[1] = *(int1 *)(param_1 + 0x41); puVar2[2] = *(int1 *)(param_1 + 0x42); puVar2[3] = *(int1 *)(param_1 + 0x43); uVar1 = 0; *(int8 *)(param_1 + 0x360) = 0; } *(int8 *)(param_1 + 0x398) = uVar1; return puVar2; }
27,528
testing::internal::UnitTestOptions::MatchesFilter(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, char const*)
AlayaLite/build_O3/_deps/googletest-src/googletest/src/gtest.cc
bool UnitTestOptions::MatchesFilter(const std::string& name_str, const char* filter) { return UnitTestFilter(filter).MatchesName(name_str); }
O3
cpp
testing::internal::UnitTestOptions::MatchesFilter(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, char const*): pushq %r14 pushq %rbx subq $0x78, %rsp movq %rdi, %rbx leaq 0x8(%rsp), %r14 leaq 0x7(%rsp), %rdx movq %r14, %rdi callq 0x16c9c leaq 0x28(%rsp), %rdi movq %r14, %rsi callq 0x5cea0 leaq 0x28(%rsp), %rdi movq %rbx, %rsi callq 0x5cfae movl %eax, %ebx leaq 0x40(%rsp), %rdi callq 0x787f6 leaq 0x28(%rsp), %rdi callq 0x73be2 leaq 0x18(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0x5ce57 movq 0x18(%rsp), %rsi incq %rsi callq 0x11120 movl %ebx, %eax addq $0x78, %rsp popq %rbx popq %r14 retq movq %rax, %rbx leaq 0x40(%rsp), %rdi callq 0x787f6 leaq 0x28(%rsp), %rdi callq 0x73be2 jmp 0x5ce7d movq %rax, %rbx leaq 0x18(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0x5ce98 movq 0x18(%rsp), %rsi incq %rsi callq 0x11120 movq %rbx, %rdi callq 0x11760
_ZN7testing8internal15UnitTestOptions13MatchesFilterERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEPKc: push r14 push rbx sub rsp, 78h mov rbx, rdi lea r14, [rsp+88h+var_80] lea rdx, [rsp+88h+var_81] mov rdi, r14 call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&) lea rdi, [rsp+88h+var_60] mov rsi, r14 call _ZN7testing8internal12_GLOBAL__N_114UnitTestFilterC2ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; testing::internal::`anonymous namespace'::UnitTestFilter::UnitTestFilter(std::string const&) lea rdi, [rsp+88h+var_60] mov rsi, rbx call _ZNK7testing8internal12_GLOBAL__N_114UnitTestFilter11MatchesNameERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; testing::internal::`anonymous namespace'::UnitTestFilter::MatchesName(std::string const&) mov ebx, eax lea rdi, [rsp+88h+var_48] call _ZNSt10_HashtableINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES5_SaIS5_ENSt8__detail9_IdentityESt8equal_toIS5_ESt4hashIS5_ENS7_18_Mod_range_hashingENS7_20_Default_ranged_hashENS7_20_Prime_rehash_policyENS7_17_Hashtable_traitsILb1ELb1ELb1EEEED2Ev; std::_Hashtable<std::string,std::string,std::allocator<std::string>,std::__detail::_Identity,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,true,true>>::~_Hashtable() lea rdi, [rsp+88h+var_60]; void * call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EED2Ev; std::vector<std::string>::~vector() lea rax, [rsp+88h+var_70] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_5CE57 mov rsi, [rsp+88h+var_70] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_5CE57: mov eax, ebx add rsp, 78h pop rbx pop r14 retn mov rbx, rax lea rdi, [rsp+arg_38] call _ZNSt10_HashtableINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES5_SaIS5_ENSt8__detail9_IdentityESt8equal_toIS5_ESt4hashIS5_ENS7_18_Mod_range_hashingENS7_20_Default_ranged_hashENS7_20_Prime_rehash_policyENS7_17_Hashtable_traitsILb1ELb1ELb1EEEED2Ev; std::_Hashtable<std::string,std::string,std::allocator<std::string>,std::__detail::_Identity,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,true,true>>::~_Hashtable() lea rdi, [rsp+arg_20]; void * call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EED2Ev; std::vector<std::string>::~vector() jmp short loc_5CE7D mov rbx, rax loc_5CE7D: lea rax, [rsp+arg_10] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_5CE98 mov rsi, [rsp+arg_10] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_5CE98: mov rdi, rbx call __Unwind_Resume
long long testing::internal::UnitTestOptions::MatchesFilter(long long a1, long long a2) { unsigned int v2; // ebx void *v4[2]; // [rsp+8h] [rbp-80h] BYREF long long v5; // [rsp+18h] [rbp-70h] BYREF _BYTE v6[24]; // [rsp+28h] [rbp-60h] BYREF _BYTE v7[72]; // [rsp+40h] [rbp-48h] BYREF std::string::basic_string<std::allocator<char>>(v4, a2); testing::internal::`anonymous namespace'::UnitTestFilter::UnitTestFilter(v6, v4); v2 = testing::internal::`anonymous namespace'::UnitTestFilter::MatchesName(v6, a1); std::_Hashtable<std::string,std::string,std::allocator<std::string>,std::__detail::_Identity,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,true,true>>::~_Hashtable(v7); std::vector<std::string>::~vector(v6); if ( v4[0] != &v5 ) operator delete(v4[0], v5 + 1); return v2; }
MatchesFilter: PUSH R14 PUSH RBX SUB RSP,0x78 MOV RBX,RDI LEA R14,[RSP + 0x8] LEA RDX,[RSP + 0x7] MOV RDI,R14 CALL 0x00116c9c LAB_0015ce0c: LEA RDI,[RSP + 0x28] MOV RSI,R14 CALL 0x0015cea0 LAB_0015ce19: LEA RDI,[RSP + 0x28] MOV RSI,RBX CALL 0x0015cfae LAB_0015ce26: MOV EBX,EAX LEA RDI,[RSP + 0x40] CALL 0x001787f6 LEA RDI,[RSP + 0x28] CALL 0x00173be2 LEA RAX,[RSP + 0x18] MOV RDI,qword ptr [RAX + -0x10] CMP RDI,RAX JZ 0x0015ce57 MOV RSI,qword ptr [RSP + 0x18] INC RSI CALL 0x00111120 LAB_0015ce57: MOV EAX,EBX ADD RSP,0x78 POP RBX POP R14 RET
/* testing::internal::UnitTestOptions::MatchesFilter(std::__cxx11::string const&, char const*) */ int4 testing::internal::UnitTestOptions::MatchesFilter(string *param_1,char *param_2) { int4 uVar1; allocator local_81; long *local_80 [2]; long local_70 [2]; UnitTestFilter local_60 [24]; _Hashtable<std::__cxx11::string,std::__cxx11::string,std::allocator<std::__cxx11::string>,std::__detail::_Identity,std::equal_to<std::__cxx11::string>,std::hash<std::__cxx11::string>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<true,true,true>> local_48 [56]; std::__cxx11::string::string<std::allocator<char>>((string *)local_80,param_2,&local_81); /* try { // try from 0015ce0c to 0015ce18 has its CatchHandler @ 0015ce7a */ (anonymous_namespace)::UnitTestFilter::UnitTestFilter(local_60,(string *)local_80); /* try { // try from 0015ce19 to 0015ce25 has its CatchHandler @ 0015ce61 */ uVar1 = (anonymous_namespace)::UnitTestFilter::MatchesName(local_60,param_1); std:: _Hashtable<std::__cxx11::string,std::__cxx11::string,std::allocator<std::__cxx11::string>,std::__detail::_Identity,std::equal_to<std::__cxx11::string>,std::hash<std::__cxx11::string>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<true,true,true>> ::~_Hashtable(local_48); std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::~vector ((vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *)local_60); if (local_80[0] != local_70) { operator_delete(local_80[0],local_70[0] + 1); } return uVar1; }
27,529
my_instr_simple
eloqsql/strings/ctype-simple.c
uint my_instr_simple(CHARSET_INFO *cs, const char *b, size_t b_length, const char *s, size_t s_length, my_match_t *match, uint nmatch) { register const uchar *str, *search, *end, *search_end; if (s_length <= b_length) { if (!s_length) { if (nmatch) { match->beg= 0; match->end= 0; match->mb_len= 0; } return 1; /* Empty string is always found */ } str= (const uchar*) b; search= (const uchar*) s; end= (const uchar*) b+b_length-s_length+1; search_end= (const uchar*) s + s_length; skip: while (str != end) { if (cs->sort_order[*str++] == cs->sort_order[*search]) { register const uchar *i,*j; i= str; j= search+1; while (j != search_end) if (cs->sort_order[*i++] != cs->sort_order[*j++]) goto skip; if (nmatch > 0) { match[0].beg= 0; match[0].end= (uint) (str- (const uchar*)b-1); match[0].mb_len= match[0].end; if (nmatch > 1) { match[1].beg= match[0].end; match[1].end= (uint)(match[0].end+s_length); match[1].mb_len= match[1].end-match[1].beg; } } return 2; } } } return 0; }
O3
c
my_instr_simple: xorl %eax, %eax cmpq %rdx, %r8 ja 0x58e84 pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx movl 0x10(%rbp), %r11d testq %r8, %r8 je 0x58e4a addq %rsi, %rdx subq %r8, %rdx incq %rdx movq %rsi, %r10 cmpq %rdx, %r10 je 0x58e7a movq %r10, %rbx movq 0x58(%rdi), %r14 incq %r10 movzbl (%rbx), %r15d movb (%r14,%r15), %r15b movzbl (%rcx), %r12d cmpb (%r14,%r12), %r15b jne 0x58dca movl $0x1, %r15d cmpq %r15, %r8 je 0x58e13 movzbl (%rbx,%r15), %r12d movb (%r14,%r12), %r12b movzbl (%rcx,%r15), %r13d incq %r15 cmpb (%r14,%r13), %r12b je 0x58df5 jmp 0x58dca movl $0x2, %eax testl %r11d, %r11d je 0x58e7a movl $0x0, (%r9) notl %esi addl %esi, %r10d movl %r10d, 0x4(%r9) movl %r10d, 0x8(%r9) cmpl $0x1, %r11d je 0x58e7a movl %r10d, 0xc(%r9) addl %r8d, %r10d movl $0x14, %ecx movl $0x10, %edx jmp 0x58e6b testl %r11d, %r11d je 0x58e75 movl $0x0, (%r9) movl $0x1, %eax movl $0x8, %ecx xorl %r10d, %r10d movl $0x4, %edx xorl %r8d, %r8d movl %r10d, (%r9,%rdx) movl %r8d, (%r9,%rcx) jmp 0x58e7a movl $0x1, %eax popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
my_instr_simple: xor eax, eax cmp r8, rdx ja locret_58E84 push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx mov r11d, [rbp+10h] test r8, r8 jz loc_58E4A add rdx, rsi sub rdx, r8 inc rdx mov r10, rsi loc_58DCA: cmp r10, rdx jz loc_58E7A mov rbx, r10 mov r14, [rdi+58h] inc r10 movzx r15d, byte ptr [rbx] mov r15b, [r14+r15] movzx r12d, byte ptr [rcx] cmp r15b, [r14+r12] jnz short loc_58DCA mov r15d, 1 loc_58DF5: cmp r8, r15 jz short loc_58E13 movzx r12d, byte ptr [rbx+r15] mov r12b, [r14+r12] movzx r13d, byte ptr [rcx+r15] inc r15 cmp r12b, [r14+r13] jz short loc_58DF5 jmp short loc_58DCA loc_58E13: mov eax, 2 test r11d, r11d jz short loc_58E7A mov dword ptr [r9], 0 not esi add r10d, esi mov [r9+4], r10d mov [r9+8], r10d cmp r11d, 1 jz short loc_58E7A mov [r9+0Ch], r10d add r10d, r8d mov ecx, 14h mov edx, 10h jmp short loc_58E6B loc_58E4A: test r11d, r11d jz short loc_58E75 mov dword ptr [r9], 0 mov eax, 1 mov ecx, 8 xor r10d, r10d mov edx, 4 xor r8d, r8d loc_58E6B: mov [r9+rdx], r10d mov [r9+rcx], r8d jmp short loc_58E7A loc_58E75: mov eax, 1 loc_58E7A: pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp locret_58E84: retn
long long my_instr_simple( long long a1, unsigned __int8 *a2, unsigned long long a3, unsigned __int8 *a4, unsigned long long a5, _DWORD *a6, int a7) { long long result; // rax long long v8; // rdx unsigned __int8 *v9; // r10 unsigned __int8 *v10; // rbx long long v11; // r14 long long v12; // r15 char v13; // r12 long long v14; // r13 int v15; // r10d int v16; // r10d long long v17; // rcx long long v18; // rdx result = 0LL; if ( a5 <= a3 ) { if ( a5 ) { v8 = (long long)&a2[a3 - a5 + 1]; v9 = a2; LABEL_4: while ( v9 != (unsigned __int8 *)v8 ) { v10 = v9; v11 = *(_QWORD *)(a1 + 88); ++v9; if ( *(_BYTE *)(v11 + *v10) == *(_BYTE *)(v11 + *a4) ) { v12 = 1LL; while ( a5 != v12 ) { v13 = *(_BYTE *)(v11 + v10[v12]); v14 = a4[v12++]; if ( v13 != *(_BYTE *)(v11 + v14) ) goto LABEL_4; } result = 2LL; if ( a7 ) { *a6 = 0; v15 = ~(_DWORD)a2 + (_DWORD)v9; a6[1] = v15; a6[2] = v15; if ( a7 != 1 ) { a6[3] = v15; v16 = a5 + v15; v17 = 5LL; v18 = 4LL; goto LABEL_15; } } return result; } } } else if ( a7 ) { *a6 = 0; result = 1LL; v17 = 2LL; v16 = 0; v18 = 1LL; LODWORD(a5) = 0; LABEL_15: a6[v18] = v16; a6[v17] = a5; } else { return 1LL; } } return result; }
my_instr_simple: XOR EAX,EAX CMP R8,RDX JA 0x00158e84 PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX MOV R11D,dword ptr [RBP + 0x10] TEST R8,R8 JZ 0x00158e4a ADD RDX,RSI SUB RDX,R8 INC RDX MOV R10,RSI LAB_00158dca: CMP R10,RDX JZ 0x00158e7a MOV RBX,R10 MOV R14,qword ptr [RDI + 0x58] INC R10 MOVZX R15D,byte ptr [RBX] MOV R15B,byte ptr [R14 + R15*0x1] MOVZX R12D,byte ptr [RCX] CMP R15B,byte ptr [R14 + R12*0x1] JNZ 0x00158dca MOV R15D,0x1 LAB_00158df5: CMP R8,R15 JZ 0x00158e13 MOVZX R12D,byte ptr [RBX + R15*0x1] MOV R12B,byte ptr [R14 + R12*0x1] MOVZX R13D,byte ptr [RCX + R15*0x1] INC R15 CMP R12B,byte ptr [R14 + R13*0x1] JZ 0x00158df5 JMP 0x00158dca LAB_00158e13: MOV EAX,0x2 TEST R11D,R11D JZ 0x00158e7a MOV dword ptr [R9],0x0 NOT ESI ADD R10D,ESI MOV dword ptr [R9 + 0x4],R10D MOV dword ptr [R9 + 0x8],R10D CMP R11D,0x1 JZ 0x00158e7a MOV dword ptr [R9 + 0xc],R10D ADD R10D,R8D MOV ECX,0x14 MOV EDX,0x10 JMP 0x00158e6b LAB_00158e4a: TEST R11D,R11D JZ 0x00158e75 MOV dword ptr [R9],0x0 MOV EAX,0x1 MOV ECX,0x8 XOR R10D,R10D MOV EDX,0x4 XOR R8D,R8D LAB_00158e6b: MOV dword ptr [R9 + RDX*0x1],R10D MOV dword ptr [R9 + RCX*0x1],R8D JMP 0x00158e7a LAB_00158e75: MOV EAX,0x1 LAB_00158e7a: POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP LAB_00158e84: RET
int8 my_instr_simple(long param_1,byte *param_2,ulong param_3,byte *param_4,ulong param_5, int4 *param_6,int param_7) { byte *pbVar1; byte *pbVar2; int8 uVar3; long lVar4; long lVar5; int iVar6; byte *pbVar7; byte *pbVar8; ulong uVar9; uVar3 = 0; if (param_5 <= param_3) { if (param_5 == 0) { if (param_7 == 0) { uVar3 = 1; } else { *param_6 = 0; uVar3 = 1; lVar4 = 8; iVar6 = 0; lVar5 = 4; param_5 = 0; LAB_00158e6b: *(int *)((long)param_6 + lVar5) = iVar6; *(int *)((long)param_6 + lVar4) = (int)param_5; } } else { pbVar8 = param_2; while (pbVar7 = pbVar8, pbVar7 != param_2 + (param_3 - param_5) + 1) { lVar4 = *(long *)(param_1 + 0x58); pbVar8 = pbVar7 + 1; if (*(char *)(lVar4 + (ulong)*pbVar7) == *(char *)(lVar4 + (ulong)*param_4)) { uVar9 = 1; do { if (param_5 == uVar9) { uVar3 = 2; if (param_7 == 0) { return 2; } *param_6 = 0; iVar6 = (int)pbVar8 + ~(uint)param_2; param_6[1] = iVar6; param_6[2] = iVar6; if (param_7 == 1) { return 2; } param_6[3] = iVar6; iVar6 = iVar6 + (int)param_5; lVar4 = 0x14; lVar5 = 0x10; goto LAB_00158e6b; } pbVar1 = pbVar7 + uVar9; pbVar2 = param_4 + uVar9; uVar9 = uVar9 + 1; } while (*(char *)(lVar4 + (ulong)*pbVar1) == *(char *)(lVar4 + (ulong)*pbVar2)); } } } } return uVar3; }
27,530
pfs_get_sp_share_v1
eloqsql/storage/perfschema/pfs.cc
PSI_sp_share *pfs_get_sp_share_v1(uint sp_type, const char* schema_name, uint schema_name_length, const char* object_name, uint object_name_length) { PFS_thread *pfs_thread= my_thread_get_THR_PFS(); if (unlikely(pfs_thread == NULL)) return NULL; if (object_name_length > COL_OBJECT_NAME_SIZE) object_name_length= COL_OBJECT_NAME_SIZE; if (schema_name_length > COL_OBJECT_SCHEMA_SIZE) schema_name_length= COL_OBJECT_SCHEMA_SIZE; PFS_program *pfs_program; pfs_program= find_or_create_program(pfs_thread, sp_type_to_object_type(sp_type), object_name, object_name_length, schema_name, schema_name_length); return reinterpret_cast<PSI_sp_share *>(pfs_program); }
O0
cpp
pfs_get_sp_share_v1: pushq %rbp movq %rsp, %rbp subq $0x50, %rsp movl %edi, -0xc(%rbp) movq %rsi, -0x18(%rbp) movl %edx, -0x1c(%rbp) movq %rcx, -0x28(%rbp) movl %r8d, -0x2c(%rbp) callq 0x2d4b0 movq %rax, -0x38(%rbp) cmpq $0x0, -0x38(%rbp) sete %al andb $0x1, %al movzbl %al, %eax cmpl $0x0, %eax je 0x3409f movq $0x0, -0x8(%rbp) jmp 0x340ef cmpl $0x40, -0x2c(%rbp) jbe 0x340ac movl $0x40, -0x2c(%rbp) cmpl $0x40, -0x1c(%rbp) jbe 0x340b9 movl $0x40, -0x1c(%rbp) movq -0x38(%rbp), %rax movq %rax, -0x48(%rbp) movl -0xc(%rbp), %edi callq 0x34100 movq -0x48(%rbp), %rdi movl %eax, %esi movq -0x28(%rbp), %rdx movl -0x2c(%rbp), %ecx movq -0x18(%rbp), %r8 movl -0x1c(%rbp), %r9d callq 0x3d700 movq %rax, -0x40(%rbp) movq -0x40(%rbp), %rax movq %rax, -0x8(%rbp) movq -0x8(%rbp), %rax addq $0x50, %rsp popq %rbp retq nopl (%rax)
pfs_get_sp_share_v1: push rbp mov rbp, rsp sub rsp, 50h mov [rbp+var_C], edi mov [rbp+var_18], rsi mov [rbp+var_1C], edx mov [rbp+var_28], rcx mov [rbp+var_2C], r8d call _ZL21my_thread_get_THR_PFSv; my_thread_get_THR_PFS(void) mov [rbp+var_38], rax cmp [rbp+var_38], 0 setz al and al, 1 movzx eax, al cmp eax, 0 jz short loc_3409F mov [rbp+var_8], 0 jmp short loc_340EF loc_3409F: cmp [rbp+var_2C], 40h ; '@' jbe short loc_340AC mov [rbp+var_2C], 40h ; '@' loc_340AC: cmp [rbp+var_1C], 40h ; '@' jbe short loc_340B9 mov [rbp+var_1C], 40h ; '@' loc_340B9: mov rax, [rbp+var_38] mov [rbp+var_48], rax mov edi, [rbp+var_C]; unsigned int call _ZL22sp_type_to_object_typej; sp_type_to_object_type(uint) mov rdi, [rbp+var_48] mov esi, eax mov rdx, [rbp+var_28] mov ecx, [rbp+var_2C] mov r8, [rbp+var_18] mov r9d, [rbp+var_1C] call _Z22find_or_create_programP10PFS_thread16enum_object_typePKcjS3_j; find_or_create_program(PFS_thread *,enum_object_type,char const*,uint,char const*,uint) mov [rbp+var_40], rax mov rax, [rbp+var_40] mov [rbp+var_8], rax loc_340EF: mov rax, [rbp+var_8] add rsp, 50h pop rbp retn
long long pfs_get_sp_share_v1(unsigned int a1, long long a2, unsigned int a3, long long a4, unsigned int a5) { unsigned int v5; // eax long long THR_PFS; // [rsp+18h] [rbp-38h] THR_PFS = my_thread_get_THR_PFS(); if ( !THR_PFS ) return 0LL; if ( a5 > 0x40 ) a5 = 64; if ( a3 > 0x40 ) a3 = 64; v5 = sp_type_to_object_type(a1); return find_or_create_program(THR_PFS, v5, a4, a5, a2, a3); }
pfs_get_sp_share_v1: PUSH RBP MOV RBP,RSP SUB RSP,0x50 MOV dword ptr [RBP + -0xc],EDI MOV qword ptr [RBP + -0x18],RSI MOV dword ptr [RBP + -0x1c],EDX MOV qword ptr [RBP + -0x28],RCX MOV dword ptr [RBP + -0x2c],R8D CALL 0x0012d4b0 MOV qword ptr [RBP + -0x38],RAX CMP qword ptr [RBP + -0x38],0x0 SETZ AL AND AL,0x1 MOVZX EAX,AL CMP EAX,0x0 JZ 0x0013409f MOV qword ptr [RBP + -0x8],0x0 JMP 0x001340ef LAB_0013409f: CMP dword ptr [RBP + -0x2c],0x40 JBE 0x001340ac MOV dword ptr [RBP + -0x2c],0x40 LAB_001340ac: CMP dword ptr [RBP + -0x1c],0x40 JBE 0x001340b9 MOV dword ptr [RBP + -0x1c],0x40 LAB_001340b9: MOV RAX,qword ptr [RBP + -0x38] MOV qword ptr [RBP + -0x48],RAX MOV EDI,dword ptr [RBP + -0xc] CALL 0x00134100 MOV RDI,qword ptr [RBP + -0x48] MOV ESI,EAX MOV RDX,qword ptr [RBP + -0x28] MOV ECX,dword ptr [RBP + -0x2c] MOV R8,qword ptr [RBP + -0x18] MOV R9D,dword ptr [RBP + -0x1c] CALL 0x0013d700 MOV qword ptr [RBP + -0x40],RAX MOV RAX,qword ptr [RBP + -0x40] MOV qword ptr [RBP + -0x8],RAX LAB_001340ef: MOV RAX,qword ptr [RBP + -0x8] ADD RSP,0x50 POP RBP RET
int8 pfs_get_sp_share_v1(uint param_1,int8 param_2,uint param_3,int8 param_4,uint param_5) { int4 uVar1; long lVar2; int4 local_34; int4 local_24; int8 local_10; lVar2 = my_thread_get_THR_PFS(); if (lVar2 == 0) { local_10 = 0; } else { local_34 = param_5; if (0x40 < param_5) { local_34 = 0x40; } local_24 = param_3; if (0x40 < param_3) { local_24 = 0x40; } uVar1 = sp_type_to_object_type(param_1); local_10 = find_or_create_program(lVar2,uVar1,param_4,local_34,param_2,local_24); } return local_10; }
27,531
testing::TestSuite::TestSuite(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, char const*, void (*)(), void (*)())
AlayaLite/build_O0/_deps/googletest-src/googletest/src/gtest.cc
TestSuite::TestSuite(const std::string& a_name, const char* a_type_param, internal::SetUpTestSuiteFunc set_up_tc, internal::TearDownTestSuiteFunc tear_down_tc) : name_(a_name), type_param_(a_type_param ? new std::string(a_type_param) : nullptr), set_up_tc_(set_up_tc), tear_down_tc_(tear_down_tc), should_run_(false), start_timestamp_(0), elapsed_time_(0) {}
O0
cpp
testing::TestSuite::TestSuite(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, char const*, void (*)(), void (*)()): subq $0x98, %rsp movq %rdi, 0x90(%rsp) movq %rsi, 0x88(%rsp) movq %rdx, 0x80(%rsp) movq %rcx, 0x78(%rsp) movq %r8, 0x70(%rsp) movq 0x90(%rsp), %rdi movq %rdi, 0x40(%rsp) leaq 0xb411b(%rip), %rax # 0x183b88 addq $0x10, %rax movq %rax, (%rdi) addq $0x8, %rdi movq %rdi, 0x38(%rsp) movq 0x88(%rsp), %rsi callq 0x2f810 movq 0x40(%rsp), %rax addq $0x28, %rax movq %rax, 0x48(%rsp) movq 0x80(%rsp), %rax movb $0x0, 0x57(%rsp) movb $0x0, 0x55(%rsp) cmpq $0x0, %rax je 0xcfb18 movl $0x20, %edi callq 0x16700 movq %rax, 0x30(%rsp) jmp 0xcfac1 movq 0x30(%rsp), %rax movq %rax, 0x58(%rsp) movb $0x1, 0x57(%rsp) movq 0x80(%rsp), %rax movq %rax, 0x20(%rsp) leaq 0x56(%rsp), %rdi movq %rdi, 0x28(%rsp) callq 0x16d00 movq 0x30(%rsp), %rdi movq 0x20(%rsp), %rsi movq 0x28(%rsp), %rdx movb $0x1, 0x55(%rsp) callq 0x1dbb0 jmp 0xcfb07 movq 0x30(%rsp), %rax movb $0x0, 0x57(%rsp) movq %rax, 0x18(%rsp) jmp 0xcfb21 xorl %eax, %eax movq %rax, 0x18(%rsp) jmp 0xcfb21 movq 0x48(%rsp), %rdi movq 0x18(%rsp), %rsi callq 0xf05e0 testb $0x1, 0x55(%rsp) jne 0xcfb39 jmp 0xcfb43 leaq 0x56(%rsp), %rdi callq 0x16790 movq 0x40(%rsp), %rdi addq $0x30, %rdi movq %rdi, 0x8(%rsp) callq 0xf10f0 movq 0x40(%rsp), %rdi addq $0x48, %rdi movq %rdi, 0x10(%rsp) callq 0xf1100 movq 0x40(%rsp), %rdi movq 0x78(%rsp), %rax movq %rax, 0x60(%rdi) movq 0x70(%rsp), %rax movq %rax, 0x68(%rdi) movb $0x0, 0x70(%rdi) movq $0x0, 0x78(%rdi) movq $0x0, 0x80(%rdi) addq $0x88, %rdi callq 0xcd570 jmp 0xcfba5 addq $0x98, %rsp retq movq %rax, %rcx movl %edx, %eax movq %rcx, 0x68(%rsp) movl %eax, 0x64(%rsp) jmp 0xcfc24 movq %rax, %rcx movl %edx, %eax movq %rcx, 0x68(%rsp) movl %eax, 0x64(%rsp) testb $0x1, 0x55(%rsp) jne 0xcfbd4 jmp 0xcfbde leaq 0x56(%rsp), %rdi callq 0x16790 testb $0x1, 0x57(%rsp) jne 0xcfbe7 jmp 0xcfbf6 movq 0x58(%rsp), %rdi movl $0x20, %esi callq 0x16720 jmp 0xcfc24 movq 0x10(%rsp), %rdi movq %rax, %rcx movl %edx, %eax movq %rcx, 0x68(%rsp) movl %eax, 0x64(%rsp) callq 0xf1110 movq 0x8(%rsp), %rdi callq 0xf1170 movq 0x48(%rsp), %rdi callq 0xf0610 movq 0x38(%rsp), %rdi callq 0x1dfd0 movq 0x68(%rsp), %rdi callq 0x16cf0 nopl (%rax,%rax)
_ZN7testing9TestSuiteC2ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEPKcPFvvESC_: sub rsp, 98h; Alternative name is 'testing::TestSuite::TestSuite(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, char const*, void (*)(void), void (*)(void))' mov [rsp+98h+var_8], rdi mov [rsp+98h+var_10], rsi mov [rsp+98h+var_18], rdx mov [rsp+98h+var_20], rcx mov [rsp+98h+var_28], r8 mov rdi, [rsp+98h+var_8] mov [rsp+98h+var_58], rdi lea rax, _ZTVN7testing9TestSuiteE; `vtable for'testing::TestSuite add rax, 10h mov [rdi], rax add rdi, 8 mov [rsp+98h+var_60], rdi mov rsi, [rsp+98h+var_10] call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2ERKS4_; std::string::basic_string(std::string const&) mov rax, [rsp+98h+var_58] add rax, 28h ; '(' mov [rsp+98h+var_50], rax mov rax, [rsp+98h+var_18] mov [rsp+98h+var_41], 0 mov [rsp+98h+var_43], 0 cmp rax, 0 jz short loc_CFB18 mov edi, 20h ; ' '; unsigned __int64 call __Znwm; operator new(ulong) mov [rsp+98h+var_68], rax jmp short $+2 loc_CFAC1: mov rax, [rsp+98h+var_68] mov [rsp+98h+var_40], rax mov [rsp+98h+var_41], 1 mov rax, [rsp+98h+var_18] mov [rsp+98h+var_78], rax lea rdi, [rsp+98h+var_42] mov [rsp+98h+var_70], rdi call __ZNSaIcEC1Ev; std::allocator<char>::allocator(void) mov rdi, [rsp+98h+var_68] mov rsi, [rsp+98h+var_78] mov rdx, [rsp+98h+var_70] mov [rsp+98h+var_43], 1 call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&) jmp short $+2 loc_CFB07: mov rax, [rsp+98h+var_68] mov [rsp+98h+var_41], 0 mov [rsp+98h+var_80], rax jmp short loc_CFB21 loc_CFB18: xor eax, eax mov [rsp+98h+var_80], rax jmp short $+2 loc_CFB21: mov rdi, [rsp+98h+var_50] mov rsi, [rsp+98h+var_80] call _ZNSt10unique_ptrIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt14default_deleteIS6_EEC2IS8_vEEPS6_; std::unique_ptr<std::string const>::unique_ptr<std::default_delete<std::string const>,void>(std::string const*) test [rsp+98h+var_43], 1 jnz short loc_CFB39 jmp short loc_CFB43 loc_CFB39: lea rdi, [rsp+98h+var_42] call __ZNSaIcED1Ev; std::allocator<char>::~allocator() loc_CFB43: mov rdi, [rsp+98h+var_58] add rdi, 30h ; '0' mov [rsp+98h+var_90], rdi call _ZNSt6vectorIPN7testing8TestInfoESaIS2_EEC2Ev; std::vector<testing::TestInfo *>::vector(void) mov rdi, [rsp+98h+var_58] add rdi, 48h ; 'H' mov [rsp+98h+var_88], rdi call _ZNSt6vectorIiSaIiEEC2Ev; std::vector<int>::vector(void) mov rdi, [rsp+98h+var_58] mov rax, [rsp+98h+var_20] mov [rdi+60h], rax mov rax, [rsp+98h+var_28] mov [rdi+68h], rax mov byte ptr [rdi+70h], 0 mov qword ptr [rdi+78h], 0 mov qword ptr [rdi+80h], 0 add rdi, 88h; this call _ZN7testing10TestResultC2Ev; testing::TestResult::TestResult(void) jmp short $+2 loc_CFBA5: add rsp, 98h retn mov rcx, rax mov eax, edx mov [rsp+arg_60], rcx mov [rsp+arg_5C], eax jmp short loc_CFC24 mov rcx, rax mov eax, edx mov [rsp+arg_60], rcx mov [rsp+arg_5C], eax test [rsp+arg_4D], 1 jnz short loc_CFBD4 jmp short loc_CFBDE loc_CFBD4: lea rdi, [rsp+arg_4E] call __ZNSaIcED1Ev; std::allocator<char>::~allocator() loc_CFBDE: test [rsp+arg_4F], 1 jnz short loc_CFBE7 jmp short loc_CFBF6 loc_CFBE7: mov rdi, [rsp+arg_50]; void * mov esi, 20h ; ' '; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_CFBF6: jmp short loc_CFC24 mov rdi, [rsp+arg_8] mov rcx, rax mov eax, edx mov [rsp+arg_60], rcx mov [rsp+arg_5C], eax call _ZNSt6vectorIiSaIiEED2Ev; std::vector<int>::~vector() mov rdi, [rsp+arg_0] call _ZNSt6vectorIPN7testing8TestInfoESaIS2_EED2Ev; std::vector<testing::TestInfo *>::~vector() mov rdi, [rsp+arg_40] call _ZNSt10unique_ptrIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt14default_deleteIS6_EED2Ev; std::unique_ptr<std::string const>::~unique_ptr() loc_CFC24: mov rdi, [rsp+arg_30]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() mov rdi, [rsp+arg_60] call __Unwind_Resume
testing::TestResult * testing::TestSuite::TestSuite( long long a1, long long a2, long long a3, long long a4, long long a5) { const char *v6; // [rsp+18h] [rbp-80h] long long v7; // [rsp+20h] [rbp-78h] long long v8; // [rsp+30h] [rbp-68h] char v9; // [rsp+55h] [rbp-43h] char v10; // [rsp+56h] [rbp-42h] BYREF char v11; // [rsp+57h] [rbp-41h] long long v12; // [rsp+58h] [rbp-40h] long long v13; // [rsp+70h] [rbp-28h] long long v14; // [rsp+78h] [rbp-20h] long long v15; // [rsp+80h] [rbp-18h] long long v16; // [rsp+88h] [rbp-10h] long long v17; // [rsp+90h] [rbp-8h] v17 = a1; v16 = a2; v15 = a3; v14 = a4; v13 = a5; *(_QWORD *)a1 = &`vtable for'testing::TestSuite + 2; std::string::basic_string((_QWORD *)(a1 + 8), v16); v11 = 0; v9 = 0; if ( v15 ) { v8 = operator new(0x20uLL); v12 = v8; v11 = 1; v7 = v15; std::allocator<char>::allocator(); v9 = 1; std::string::basic_string<std::allocator<char>>(v8, v7, (long long)&v10); v11 = 0; v6 = (const char *)v8; } else { v6 = 0LL; } std::unique_ptr<std::string const>::unique_ptr<std::default_delete<std::string const>,void>(a1 + 40, v6); if ( (v9 & 1) != 0 ) std::allocator<char>::~allocator(&v10, v6); std::vector<testing::TestInfo *>::vector(); std::vector<int>::vector(); *(_QWORD *)(a1 + 96) = v14; *(_QWORD *)(a1 + 104) = v13; *(_BYTE *)(a1 + 112) = 0; *(_QWORD *)(a1 + 120) = 0LL; *(_QWORD *)(a1 + 128) = 0LL; return testing::TestResult::TestResult((testing::TestResult *)(a1 + 136)); }
TestSuite: SUB RSP,0x98 MOV qword ptr [RSP + 0x90],RDI MOV qword ptr [RSP + 0x88],RSI MOV qword ptr [RSP + 0x80],RDX MOV qword ptr [RSP + 0x78],RCX MOV qword ptr [RSP + 0x70],R8 MOV RDI,qword ptr [RSP + 0x90] MOV qword ptr [RSP + 0x40],RDI LEA RAX,[0x283b88] ADD RAX,0x10 MOV qword ptr [RDI],RAX ADD RDI,0x8 MOV qword ptr [RSP + 0x38],RDI MOV RSI,qword ptr [RSP + 0x88] CALL 0x0012f810 MOV RAX,qword ptr [RSP + 0x40] ADD RAX,0x28 MOV qword ptr [RSP + 0x48],RAX MOV RAX,qword ptr [RSP + 0x80] MOV byte ptr [RSP + 0x57],0x0 MOV byte ptr [RSP + 0x55],0x0 CMP RAX,0x0 JZ 0x001cfb18 LAB_001cfab0: MOV EDI,0x20 CALL 0x00116700 MOV qword ptr [RSP + 0x30],RAX JMP 0x001cfac1 LAB_001cfac1: MOV RAX,qword ptr [RSP + 0x30] MOV qword ptr [RSP + 0x58],RAX MOV byte ptr [RSP + 0x57],0x1 MOV RAX,qword ptr [RSP + 0x80] MOV qword ptr [RSP + 0x20],RAX LEA RDI,[RSP + 0x56] MOV qword ptr [RSP + 0x28],RDI CALL 0x00116d00 MOV RDI,qword ptr [RSP + 0x30] MOV RSI,qword ptr [RSP + 0x20] MOV RDX,qword ptr [RSP + 0x28] MOV byte ptr [RSP + 0x55],0x1 LAB_001cfb00: CALL 0x0011dbb0 JMP 0x001cfb07 LAB_001cfb07: MOV RAX,qword ptr [RSP + 0x30] MOV byte ptr [RSP + 0x57],0x0 MOV qword ptr [RSP + 0x18],RAX JMP 0x001cfb21 LAB_001cfb18: XOR EAX,EAX MOV qword ptr [RSP + 0x18],RAX JMP 0x001cfb21 LAB_001cfb21: MOV RDI,qword ptr [RSP + 0x48] MOV RSI,qword ptr [RSP + 0x18] CALL 0x001f05e0 TEST byte ptr [RSP + 0x55],0x1 JNZ 0x001cfb39 JMP 0x001cfb43 LAB_001cfb39: LEA RDI,[RSP + 0x56] CALL 0x00116790 LAB_001cfb43: MOV RDI,qword ptr [RSP + 0x40] ADD RDI,0x30 MOV qword ptr [RSP + 0x8],RDI CALL 0x001f10f0 MOV RDI,qword ptr [RSP + 0x40] ADD RDI,0x48 MOV qword ptr [RSP + 0x10],RDI CALL 0x001f1100 MOV RDI,qword ptr [RSP + 0x40] MOV RAX,qword ptr [RSP + 0x78] MOV qword ptr [RDI + 0x60],RAX MOV RAX,qword ptr [RSP + 0x70] MOV qword ptr [RDI + 0x68],RAX MOV byte ptr [RDI + 0x70],0x0 MOV qword ptr [RDI + 0x78],0x0 MOV qword ptr [RDI + 0x80],0x0 ADD RDI,0x88 LAB_001cfb9e: CALL 0x001cd570 LAB_001cfba3: JMP 0x001cfba5 LAB_001cfba5: ADD RSP,0x98 RET
/* testing::TestSuite::TestSuite(std::__cxx11::string const&, char const*, void (*)(), void (*)()) */ void __thiscall testing::TestSuite::TestSuite (TestSuite *this,string *param_1,char *param_2,_func_void *param_3,_func_void *param_4) { char *pcVar1; string *local_80; bool local_43; allocator local_42; int1 local_41; string *local_40; _func_void *local_28; _func_void *local_20; char *local_18; string *local_10; TestSuite *local_8; *(int ***)this = &PTR__TestSuite_00283b98; local_28 = param_4; local_20 = param_3; local_18 = param_2; local_10 = param_1; local_8 = this; std::__cxx11::string::string((string *)(this + 8),param_1); local_41 = 0; local_43 = local_18 == (char *)0x0; if (local_43) { local_80 = (string *)0x0; } else { /* try { // try from 001cfab0 to 001cfab9 has its CatchHandler @ 001cfbad */ local_80 = (string *)operator_new(0x20); pcVar1 = local_18; local_41 = 1; local_40 = local_80; std::allocator<char>::allocator(); /* try { // try from 001cfb00 to 001cfb04 has its CatchHandler @ 001cfbbd */ std::__cxx11::string::string<std::allocator<char>>(local_80,pcVar1,&local_42); } local_41 = 0; local_43 = !local_43; std::unique_ptr<std::__cxx11::string_const,std::default_delete<std::__cxx11::string_const>>:: unique_ptr<std::default_delete<std::__cxx11::string_const>,void> ((unique_ptr<std::__cxx11::string_const,std::default_delete<std::__cxx11::string_const>> *)(this + 0x28),local_80); if (local_43) { std::allocator<char>::~allocator((allocator<char> *)&local_42); } std::vector<testing::TestInfo*,std::allocator<testing::TestInfo*>>::vector ((vector<testing::TestInfo*,std::allocator<testing::TestInfo*>> *)(this + 0x30)); std::vector<int,std::allocator<int>>::vector((vector<int,std::allocator<int>> *)(this + 0x48)); *(_func_void **)(this + 0x60) = local_20; *(_func_void **)(this + 0x68) = local_28; this[0x70] = (TestSuite)0x0; *(int8 *)(this + 0x78) = 0; *(int8 *)(this + 0x80) = 0; /* try { // try from 001cfb9e to 001cfba2 has its CatchHandler @ 001cfbf8 */ TestResult::TestResult((TestResult *)(this + 0x88)); return; }
27,532
translog_get_chunk_header_length
eloqsql/storage/maria/ma_loghandler.c
static uint16 translog_get_chunk_header_length(uchar *chunk) { DBUG_ENTER("translog_get_chunk_header_length"); switch (*chunk & TRANSLOG_CHUNK_TYPE) { case TRANSLOG_CHUNK_LSN: { /* 0 chunk referred as LSN (head or tail) */ translog_size_t rec_len __attribute__((unused)); uchar *start= chunk; uchar *ptr= start + 1 + 2; uint16 chunk_len, header_len; DBUG_PRINT("info", ("TRANSLOG_CHUNK_LSN")); rec_len= translog_variable_record_1group_decode_len(&ptr); chunk_len= uint2korr(ptr); header_len= (uint16) (ptr - start) +2; DBUG_PRINT("info", ("rec len: %lu chunk len: %u header len: %u", (ulong) rec_len, (uint) chunk_len, (uint) header_len)); if (chunk_len) { /* TODO: fine header end */ /* The last chunk of multi-group record can be base for it header calculation (we skip to the first group to read the header) so if we stuck here something is wrong. */ DBUG_ASSERT(0); DBUG_RETURN(0); /* Keep compiler happy */ } DBUG_RETURN(header_len); } case TRANSLOG_CHUNK_FIXED: { /* 1 (pseudo)fixed record (also LSN) */ DBUG_PRINT("info", ("TRANSLOG_CHUNK_FIXED = 3")); DBUG_RETURN(3); } case TRANSLOG_CHUNK_NOHDR: /* 2 no header chunk (till page end) */ DBUG_PRINT("info", ("TRANSLOG_CHUNK_NOHDR = 1")); DBUG_RETURN(1); break; case TRANSLOG_CHUNK_LNGTH: /* 3 chunk with chunk length */ DBUG_PRINT("info", ("TRANSLOG_CHUNK_LNGTH = 3")); DBUG_RETURN(3); break; } DBUG_ASSERT(0); DBUG_RETURN(0); /* Keep compiler happy */ }
O0
c
translog_get_chunk_header_length: pushq %rbp movq %rsp, %rbp subq $0x30, %rsp movq %rdi, -0x10(%rbp) movq -0x10(%rbp), %rax movzbl (%rax), %eax andl $0xc0, %eax movl %eax, -0x30(%rbp) je 0x38a70 jmp 0x38a3f movl -0x30(%rbp), %eax subl $0x40, %eax je 0x38ad9 jmp 0x38a4d movl -0x30(%rbp), %eax subl $0x80, %eax je 0x38ae7 jmp 0x38a5d movl -0x30(%rbp), %eax subl $0xc0, %eax je 0x38af5 jmp 0x38b03 movq -0x10(%rbp), %rax movq %rax, -0x20(%rbp) movq -0x20(%rbp), %rax addq $0x1, %rax addq $0x2, %rax movq %rax, -0x28(%rbp) jmp 0x38a8a leaq -0x28(%rbp), %rdi callq 0x35290 movl %eax, -0x14(%rbp) movq -0x28(%rbp), %rax movw (%rax), %ax movw %ax, -0x2a(%rbp) movq -0x28(%rbp), %rax movq -0x20(%rbp), %rcx subq %rcx, %rax movzwl %ax, %eax addl $0x2, %eax movw %ax, -0x2c(%rbp) jmp 0x38ab8 cmpw $0x0, -0x2a(%rbp) je 0x38acd jmp 0x38ac1 jmp 0x38ac3 jmp 0x38ac5 movw $0x0, -0x2(%rbp) jmp 0x38b0f jmp 0x38acf movw -0x2c(%rbp), %ax movw %ax, -0x2(%rbp) jmp 0x38b0f jmp 0x38adb jmp 0x38add jmp 0x38adf movw $0x3, -0x2(%rbp) jmp 0x38b0f jmp 0x38ae9 jmp 0x38aeb jmp 0x38aed movw $0x1, -0x2(%rbp) jmp 0x38b0f jmp 0x38af7 jmp 0x38af9 jmp 0x38afb movw $0x3, -0x2(%rbp) jmp 0x38b0f jmp 0x38b05 jmp 0x38b07 jmp 0x38b09 movw $0x0, -0x2(%rbp) movw -0x2(%rbp), %ax addq $0x30, %rsp popq %rbp retq nopl (%rax)
translog_get_chunk_header_length: push rbp mov rbp, rsp sub rsp, 30h mov [rbp+var_10], rdi mov rax, [rbp+var_10] movzx eax, byte ptr [rax] and eax, 0C0h mov [rbp+var_30], eax jz short loc_38A70 jmp short $+2 loc_38A3F: mov eax, [rbp+var_30] sub eax, 40h ; '@' jz loc_38AD9 jmp short $+2 loc_38A4D: mov eax, [rbp+var_30] sub eax, 80h jz loc_38AE7 jmp short $+2 loc_38A5D: mov eax, [rbp+var_30] sub eax, 0C0h jz loc_38AF5 jmp loc_38B03 loc_38A70: mov rax, [rbp+var_10] mov [rbp+var_20], rax mov rax, [rbp+var_20] add rax, 1 add rax, 2 mov [rbp+var_28], rax jmp short $+2 loc_38A8A: lea rdi, [rbp+var_28] call translog_variable_record_1group_decode_len mov [rbp+var_14], eax mov rax, [rbp+var_28] mov ax, [rax] mov [rbp+var_2A], ax mov rax, [rbp+var_28] mov rcx, [rbp+var_20] sub rax, rcx movzx eax, ax add eax, 2 mov [rbp+var_2C], ax jmp short $+2 loc_38AB8: cmp [rbp+var_2A], 0 jz short loc_38ACD jmp short $+2 loc_38AC1: jmp short $+2 loc_38AC3: jmp short $+2 loc_38AC5: mov [rbp+var_2], 0 jmp short loc_38B0F loc_38ACD: jmp short $+2 loc_38ACF: mov ax, [rbp+var_2C] mov [rbp+var_2], ax jmp short loc_38B0F loc_38AD9: jmp short $+2 loc_38ADB: jmp short $+2 loc_38ADD: jmp short $+2 loc_38ADF: mov [rbp+var_2], 3 jmp short loc_38B0F loc_38AE7: jmp short $+2 loc_38AE9: jmp short $+2 loc_38AEB: jmp short $+2 loc_38AED: mov [rbp+var_2], 1 jmp short loc_38B0F loc_38AF5: jmp short $+2 loc_38AF7: jmp short $+2 loc_38AF9: jmp short $+2 loc_38AFB: mov [rbp+var_2], 3 jmp short loc_38B0F loc_38B03: jmp short $+2 loc_38B05: jmp short $+2 loc_38B07: jmp short $+2 loc_38B09: mov [rbp+var_2], 0 loc_38B0F: mov ax, [rbp+var_2] add rsp, 30h pop rbp retn
__int16 translog_get_chunk_header_length(_BYTE *a1) { int v2; // [rsp+0h] [rbp-30h] unsigned __int8 *v3; // [rsp+8h] [rbp-28h] BYREF _BYTE *v4; // [rsp+10h] [rbp-20h] int v5; // [rsp+1Ch] [rbp-14h] _BYTE *v6; // [rsp+20h] [rbp-10h] v6 = a1; v2 = *a1 & 0xC0; if ( (*a1 & 0xC0) != 0 ) { switch ( v2 ) { case 64: return 3; case 128: return 1; case 192: return 3; default: return 0; } } else { v4 = v6; v3 = v6 + 3; v5 = translog_variable_record_1group_decode_len(&v3); if ( *(_WORD *)v3 ) return 0; else return (_WORD)v3 - (_WORD)v4 + 2; } }
translog_get_chunk_header_length: PUSH RBP MOV RBP,RSP SUB RSP,0x30 MOV qword ptr [RBP + -0x10],RDI MOV RAX,qword ptr [RBP + -0x10] MOVZX EAX,byte ptr [RAX] AND EAX,0xc0 MOV dword ptr [RBP + -0x30],EAX JZ 0x00138a70 JMP 0x00138a3f LAB_00138a3f: MOV EAX,dword ptr [RBP + -0x30] SUB EAX,0x40 JZ 0x00138ad9 JMP 0x00138a4d LAB_00138a4d: MOV EAX,dword ptr [RBP + -0x30] SUB EAX,0x80 JZ 0x00138ae7 JMP 0x00138a5d LAB_00138a5d: MOV EAX,dword ptr [RBP + -0x30] SUB EAX,0xc0 JZ 0x00138af5 JMP 0x00138b03 LAB_00138a70: MOV RAX,qword ptr [RBP + -0x10] MOV qword ptr [RBP + -0x20],RAX MOV RAX,qword ptr [RBP + -0x20] ADD RAX,0x1 ADD RAX,0x2 MOV qword ptr [RBP + -0x28],RAX JMP 0x00138a8a LAB_00138a8a: LEA RDI,[RBP + -0x28] CALL 0x00135290 MOV dword ptr [RBP + -0x14],EAX MOV RAX,qword ptr [RBP + -0x28] MOV AX,word ptr [RAX] MOV word ptr [RBP + -0x2a],AX MOV RAX,qword ptr [RBP + -0x28] MOV RCX,qword ptr [RBP + -0x20] SUB RAX,RCX MOVZX EAX,AX ADD EAX,0x2 MOV word ptr [RBP + -0x2c],AX JMP 0x00138ab8 LAB_00138ab8: CMP word ptr [RBP + -0x2a],0x0 JZ 0x00138acd JMP 0x00138ac1 LAB_00138ac1: JMP 0x00138ac3 LAB_00138ac3: JMP 0x00138ac5 LAB_00138ac5: MOV word ptr [RBP + -0x2],0x0 JMP 0x00138b0f LAB_00138acd: JMP 0x00138acf LAB_00138acf: MOV AX,word ptr [RBP + -0x2c] MOV word ptr [RBP + -0x2],AX JMP 0x00138b0f LAB_00138ad9: JMP 0x00138adb LAB_00138adb: JMP 0x00138add LAB_00138add: JMP 0x00138adf LAB_00138adf: MOV word ptr [RBP + -0x2],0x3 JMP 0x00138b0f LAB_00138ae7: JMP 0x00138ae9 LAB_00138ae9: JMP 0x00138aeb LAB_00138aeb: JMP 0x00138aed LAB_00138aed: MOV word ptr [RBP + -0x2],0x1 JMP 0x00138b0f LAB_00138af5: JMP 0x00138af7 LAB_00138af7: JMP 0x00138af9 LAB_00138af9: JMP 0x00138afb LAB_00138afb: MOV word ptr [RBP + -0x2],0x3 JMP 0x00138b0f LAB_00138b03: JMP 0x00138b05 LAB_00138b05: JMP 0x00138b07 LAB_00138b07: JMP 0x00138b09 LAB_00138b09: MOV word ptr [RBP + -0x2],0x0 LAB_00138b0f: MOV AX,word ptr [RBP + -0x2] ADD RSP,0x30 POP RBP RET
int8 translog_get_chunk_header_length(byte *param_1) { uint uVar1; ulong uVar2; byte *local_30; byte *local_28; byte *local_18; int2 local_a; uVar1 = *param_1 & 0xc0; if ((*param_1 & 0xc0) == 0) { local_30 = param_1 + 3; local_28 = param_1; local_18 = param_1; translog_variable_record_1group_decode_len(&local_30); uVar1 = (ushort)((short)local_30 - (short)local_28) + 2; uVar2 = (ulong)uVar1; local_a = (int2)uVar1; if (*(short *)local_30 == 0) { uVar2 = (ulong)uVar1; } else { local_a = 0; } } else { uVar2 = (ulong)(uVar1 - 0x40); if (uVar1 - 0x40 == 0) { local_a = 3; } else { uVar2 = (ulong)(uVar1 - 0x80); if (uVar1 - 0x80 == 0) { local_a = 1; } else { uVar2 = (ulong)(uVar1 - 0xc0); if (uVar1 - 0xc0 == 0) { local_a = 3; } else { local_a = 0; } } } } return CONCAT62((int6)(uVar2 >> 0x10),local_a); }
27,533
testing::Test::Run()
giladroyz[P]FindPeaks/build_O1/_deps/googletest-src/googletest/src/gtest.cc
void Test::Run() { if (!HasSameFixtureClass()) return; internal::UnitTestImpl* const impl = internal::GetUnitTestImpl(); impl->os_stack_trace_getter()->UponLeavingGTest(); internal::HandleExceptionsInMethodIfSupported(this, &Test::SetUp, "SetUp()"); // We will run the test only if SetUp() was successful and didn't call // GTEST_SKIP(). if (!HasFatalFailure() && !IsSkipped()) { impl->os_stack_trace_getter()->UponLeavingGTest(); internal::HandleExceptionsInMethodIfSupported(this, &Test::TestBody, "the test body"); } // However, we want to clean up as much as possible. Hence we will // always call TearDown(), even if SetUp() or the test body has // failed. impl->os_stack_trace_getter()->UponLeavingGTest(); internal::HandleExceptionsInMethodIfSupported(this, &Test::TearDown, "TearDown()"); }
O1
cpp
testing::Test::Run(): pushq %r14 pushq %rbx pushq %rax movq %rdi, %rbx callq 0x20574 testb %al, %al je 0x20c51 callq 0x19012 movq 0x38c50(%rip), %r14 # 0x597b0 cmpq $0x0, 0x280(%r14) jne 0x20b85 movl $0x8, %edi callq 0x84b0 leaq 0x37ac5(%rip), %rcx # 0x58640 movq %rcx, (%rax) movq %rax, 0x280(%r14) movq 0x280(%r14), %rdi movq (%rdi), %rax callq *0x18(%rax) leaq 0x223d1(%rip), %rcx # 0x42f6a movl $0x11, %esi movq %rbx, %rdi xorl %edx, %edx callq 0x34423 callq 0x20c5a testb %al, %al jne 0x20c02 callq 0x20cc4 testb %al, %al jne 0x20c02 cmpq $0x0, 0x280(%r14) jne 0x20bdf movl $0x8, %edi callq 0x84b0 leaq 0x37a6b(%rip), %rcx # 0x58640 movq %rcx, (%rax) movq %rax, 0x280(%r14) movq 0x280(%r14), %rdi movq (%rdi), %rax callq *0x18(%rax) leaq 0x2237f(%rip), %rcx # 0x42f72 movl $0x21, %esi movq %rbx, %rdi xorl %edx, %edx callq 0x34423 cmpq $0x0, 0x280(%r14) jne 0x20c27 movl $0x8, %edi callq 0x84b0 leaq 0x37a23(%rip), %rcx # 0x58640 movq %rcx, (%rax) movq %rax, 0x280(%r14) movq 0x280(%r14), %rdi movq (%rdi), %rax callq *0x18(%rax) leaq 0x22345(%rip), %rcx # 0x42f80 movl $0x19, %esi movq %rbx, %rdi xorl %edx, %edx addq $0x8, %rsp popq %rbx popq %r14 jmp 0x34423 addq $0x8, %rsp popq %rbx popq %r14 retq nop
_ZN7testing4Test3RunEv: push r14 push rbx push rax mov rbx, rdi call _ZN7testing4Test19HasSameFixtureClassEv; testing::Test::HasSameFixtureClass(void) test al, al jz loc_20C51 call _ZN7testing8UnitTest11GetInstanceEv; testing::UnitTest::GetInstance(void) mov r14, cs:qword_597B0 cmp qword ptr [r14+280h], 0 jnz short loc_20B85 mov edi, 8; unsigned __int64 call __Znwm; operator new(ulong) lea rcx, off_58640 mov [rax], rcx mov [r14+280h], rax loc_20B85: mov rdi, [r14+280h] mov rax, [rdi] call qword ptr [rax+18h] lea rcx, aSetup; "SetUp()" mov esi, 11h mov rdi, rbx; this xor edx, edx call _ZN7testing8internal35HandleExceptionsInMethodIfSupportedINS_4TestEvEET0_PT_MS4_FS3_vEPKc; testing::internal::HandleExceptionsInMethodIfSupported<testing::Test,void>(testing::Test *,void (testing::Test::*)(void),char const*) call _ZN7testing4Test15HasFatalFailureEv; testing::Test::HasFatalFailure(void) test al, al jnz short loc_20C02 call _ZN7testing4Test9IsSkippedEv; testing::Test::IsSkipped(void) test al, al jnz short loc_20C02 cmp qword ptr [r14+280h], 0 jnz short loc_20BDF mov edi, 8; unsigned __int64 call __Znwm; operator new(ulong) lea rcx, off_58640 mov [rax], rcx mov [r14+280h], rax loc_20BDF: mov rdi, [r14+280h] mov rax, [rdi] call qword ptr [rax+18h] lea rcx, aTheTestBody; "the test body" mov esi, 21h ; '!' mov rdi, rbx xor edx, edx call _ZN7testing8internal35HandleExceptionsInMethodIfSupportedINS_4TestEvEET0_PT_MS4_FS3_vEPKc; testing::internal::HandleExceptionsInMethodIfSupported<testing::Test,void>(testing::Test *,void (testing::Test::*)(void),char const*) loc_20C02: cmp qword ptr [r14+280h], 0 jnz short loc_20C27 mov edi, 8; unsigned __int64 call __Znwm; operator new(ulong) lea rcx, off_58640 mov [rax], rcx mov [r14+280h], rax loc_20C27: mov rdi, [r14+280h] mov rax, [rdi] call qword ptr [rax+18h] lea rcx, aTeardown; "TearDown()" mov esi, 19h mov rdi, rbx xor edx, edx add rsp, 8 pop rbx pop r14 jmp _ZN7testing8internal35HandleExceptionsInMethodIfSupportedINS_4TestEvEET0_PT_MS4_FS3_vEPKc; testing::internal::HandleExceptionsInMethodIfSupported<testing::Test,void>(testing::Test *,void (testing::Test::*)(void),char const*) loc_20C51: add rsp, 8 pop rbx pop r14 retn
char testing::Test::Run(testing::Test *this) { char result; // al testing::internal::UnitTestImpl *v2; // r14 _QWORD *v3; // rax _QWORD *v4; // rax _QWORD *v5; // rax result = testing::Test::HasSameFixtureClass(this); if ( result ) { testing::UnitTest::GetInstance(this); v2 = qword_597B0; if ( !*((_QWORD *)qword_597B0 + 80) ) { v3 = (_QWORD *)operator new(8uLL); *v3 = off_58640; *((_QWORD *)v2 + 80) = v3; } (*(void ( **)(_QWORD))(**((_QWORD **)v2 + 80) + 24LL))(*((_QWORD *)v2 + 80)); testing::internal::HandleExceptionsInMethodIfSupported<testing::Test,void>(this, 17LL, 0LL, "SetUp()"); if ( !(unsigned __int8)testing::Test::HasFatalFailure(this) && !(unsigned __int8)testing::Test::IsSkipped(this) ) { if ( !*((_QWORD *)v2 + 80) ) { v4 = (_QWORD *)operator new(8uLL); *v4 = off_58640; *((_QWORD *)v2 + 80) = v4; } (*(void ( **)(_QWORD))(**((_QWORD **)v2 + 80) + 24LL))(*((_QWORD *)v2 + 80)); testing::internal::HandleExceptionsInMethodIfSupported<testing::Test,void>(this, 33LL, 0LL, "the test body"); } if ( !*((_QWORD *)v2 + 80) ) { v5 = (_QWORD *)operator new(8uLL); *v5 = off_58640; *((_QWORD *)v2 + 80) = v5; } (*(void ( **)(_QWORD))(**((_QWORD **)v2 + 80) + 24LL))(*((_QWORD *)v2 + 80)); return testing::internal::HandleExceptionsInMethodIfSupported<testing::Test,void>(this, 25LL, 0LL, "TearDown()"); } return result; }
Run: PUSH R14 PUSH RBX PUSH RAX MOV RBX,RDI CALL 0x00120574 TEST AL,AL JZ 0x00120c51 CALL 0x00119012 MOV R14,qword ptr [0x001597b0] CMP qword ptr [R14 + 0x280],0x0 JNZ 0x00120b85 MOV EDI,0x8 CALL 0x001084b0 LEA RCX,[0x158640] MOV qword ptr [RAX],RCX MOV qword ptr [R14 + 0x280],RAX LAB_00120b85: MOV RDI,qword ptr [R14 + 0x280] MOV RAX,qword ptr [RDI] CALL qword ptr [RAX + 0x18] LEA RCX,[0x142f6a] MOV ESI,0x11 MOV RDI,RBX XOR EDX,EDX CALL 0x00134423 CALL 0x00120c5a TEST AL,AL JNZ 0x00120c02 CALL 0x00120cc4 TEST AL,AL JNZ 0x00120c02 CMP qword ptr [R14 + 0x280],0x0 JNZ 0x00120bdf MOV EDI,0x8 CALL 0x001084b0 LEA RCX,[0x158640] MOV qword ptr [RAX],RCX MOV qword ptr [R14 + 0x280],RAX LAB_00120bdf: MOV RDI,qword ptr [R14 + 0x280] MOV RAX,qword ptr [RDI] CALL qword ptr [RAX + 0x18] LEA RCX,[0x142f72] MOV ESI,0x21 MOV RDI,RBX XOR EDX,EDX CALL 0x00134423 LAB_00120c02: CMP qword ptr [R14 + 0x280],0x0 JNZ 0x00120c27 MOV EDI,0x8 CALL 0x001084b0 LEA RCX,[0x158640] MOV qword ptr [RAX],RCX MOV qword ptr [R14 + 0x280],RAX LAB_00120c27: MOV RDI,qword ptr [R14 + 0x280] MOV RAX,qword ptr [RDI] CALL qword ptr [RAX + 0x18] LEA RCX,[0x142f80] MOV ESI,0x19 MOV RDI,RBX XOR EDX,EDX ADD RSP,0x8 POP RBX POP R14 JMP 0x00134423 LAB_00120c51: ADD RSP,0x8 POP RBX POP R14 RET
/* testing::Test::Run() */ void __thiscall testing::Test::Run(Test *this) { int8 uVar1; char cVar2; int8 *puVar3; cVar2 = HasSameFixtureClass(); if (cVar2 != '\0') { UnitTest::GetInstance(); uVar1 = UnitTest::GetInstance()::instance._64_8_; if (*(long *)(UnitTest::GetInstance()::instance._64_8_ + 0x280) == 0) { puVar3 = (int8 *)operator_new(8); *puVar3 = &PTR__OsStackTraceGetterInterface_00158640; *(int8 **)(uVar1 + 0x280) = puVar3; } (**(code **)(**(long **)(uVar1 + 0x280) + 0x18))(); internal::HandleExceptionsInMethodIfSupported<testing::Test,void> (this,(_func_void *)0x11,(char *)0x0); cVar2 = HasFatalFailure(); if (cVar2 == '\0') { cVar2 = IsSkipped(); if (cVar2 == '\0') { if (*(long *)(uVar1 + 0x280) == 0) { puVar3 = (int8 *)operator_new(8); *puVar3 = &PTR__OsStackTraceGetterInterface_00158640; *(int8 **)(uVar1 + 0x280) = puVar3; } (**(code **)(**(long **)(uVar1 + 0x280) + 0x18))(); internal::HandleExceptionsInMethodIfSupported<testing::Test,void> (this,(_func_void *)0x21,(char *)0x0); } } if (*(long *)(uVar1 + 0x280) == 0) { puVar3 = (int8 *)operator_new(8); *puVar3 = &PTR__OsStackTraceGetterInterface_00158640; *(int8 **)(uVar1 + 0x280) = puVar3; } (**(code **)(**(long **)(uVar1 + 0x280) + 0x18))(); internal::HandleExceptionsInMethodIfSupported<testing::Test,void> (this,(_func_void *)0x19,(char *)0x0); return; } return; }
27,534
mi_uint7korr
eloqsql/include/byte_order_generic_x86_64.h
static inline ulonglong mi_uint7korr(const void *p) { ulonglong a= *(uint32 *) p; ulonglong b= *(uint16 *) (4 + (char *) p); ulonglong c= *(6 + (uchar *) p); ulonglong v= (a | (b << 32) | (c << 48)) << 8; asm ("bswapq %0" : "=r" (v) : "0" (v)); return v; }
O0
c
mi_uint7korr: pushq %rbp movq %rsp, %rbp movq %rdi, -0x8(%rbp) movq -0x8(%rbp), %rax movl (%rax), %eax movq %rax, -0x10(%rbp) movq -0x8(%rbp), %rax movzwl 0x4(%rax), %eax movq %rax, -0x18(%rbp) movq -0x8(%rbp), %rax movzbl 0x6(%rax), %eax movq %rax, -0x20(%rbp) movq -0x10(%rbp), %rax movq -0x18(%rbp), %rcx shlq $0x20, %rcx orq %rcx, %rax movq -0x20(%rbp), %rcx shlq $0x30, %rcx orq %rcx, %rax shlq $0x8, %rax movq %rax, -0x28(%rbp) movq -0x28(%rbp), %rax bswapq %rax movq %rax, -0x28(%rbp) movq -0x28(%rbp), %rax popq %rbp retq nopl (%rax)
mi_uint7korr_0: push rbp mov rbp, rsp mov [rbp+var_8], rdi mov rax, [rbp+var_8] mov eax, [rax] mov [rbp+var_10], rax mov rax, [rbp+var_8] movzx eax, word ptr [rax+4] mov [rbp+var_18], rax mov rax, [rbp+var_8] movzx eax, byte ptr [rax+6] mov [rbp+var_20], rax mov rax, [rbp+var_10] mov rcx, [rbp+var_18] shl rcx, 20h or rax, rcx mov rcx, [rbp+var_20] shl rcx, 30h or rax, rcx shl rax, 8 mov [rbp+var_28], rax mov rax, [rbp+var_28] bswap rax mov [rbp+var_28], rax mov rax, [rbp+var_28] pop rbp retn
unsigned long long mi_uint7korr_0(unsigned int *a1) { return _byteswap_uint64((((unsigned long long)*((unsigned __int8 *)a1 + 6) << 48) | ((unsigned long long)*((unsigned __int16 *)a1 + 2) << 32) | *a1) << 8); }
mi_uint7korr: PUSH RBP MOV RBP,RSP MOV qword ptr [RBP + -0x8],RDI MOV RAX,qword ptr [RBP + -0x8] MOV EAX,dword ptr [RAX] MOV qword ptr [RBP + -0x10],RAX MOV RAX,qword ptr [RBP + -0x8] MOVZX EAX,word ptr [RAX + 0x4] MOV qword ptr [RBP + -0x18],RAX MOV RAX,qword ptr [RBP + -0x8] MOVZX EAX,byte ptr [RAX + 0x6] MOV qword ptr [RBP + -0x20],RAX MOV RAX,qword ptr [RBP + -0x10] MOV RCX,qword ptr [RBP + -0x18] SHL RCX,0x20 OR RAX,RCX MOV RCX,qword ptr [RBP + -0x20] SHL RCX,0x30 OR RAX,RCX SHL RAX,0x8 MOV qword ptr [RBP + -0x28],RAX MOV RAX,qword ptr [RBP + -0x28] BSWAP RAX MOV qword ptr [RBP + -0x28],RAX MOV RAX,qword ptr [RBP + -0x28] POP RBP RET
ulong mi_uint7korr(uint7 *param_1) { ulong uVar1; uVar1 = (ulong)*param_1 << 8; return uVar1 >> 0x38 | (uVar1 & 0xff000000000000) >> 0x28 | (uVar1 & 0xff0000000000) >> 0x18 | (uVar1 & 0xff00000000) >> 8 | (uVar1 & 0xff000000) << 8 | (uVar1 & 0xff0000) << 0x18 | (uVar1 & 0xff00) << 0x28; }
27,535
copy_ggml_tensor(ggml_tensor*, ggml_tensor*)
7CodeWizard[P]stablediffusion/ggml_extend.hpp
__STATIC_INLINE__ void copy_ggml_tensor(struct ggml_tensor* dst, struct ggml_tensor* src) { if (dst->type == src->type) { dst->nb[0] = src->nb[0]; dst->nb[1] = src->nb[1]; dst->nb[2] = src->nb[2]; dst->nb[3] = src->nb[3]; memcpy(((char*)dst->data), ((char*)src->data), ggml_nbytes(dst)); return; } struct ggml_init_params params; params.mem_size = 10 * 1024 * 1024; // for padding params.mem_buffer = NULL; params.no_alloc = false; struct ggml_context* ctx = ggml_init(params); if (!ctx) { LOG_ERROR("ggml_init() failed"); return; } ggml_tensor* final = ggml_cpy_inplace(ctx, src, dst); struct ggml_cgraph* graph = ggml_new_graph(ctx); ggml_build_forward_expand(graph, final); ggml_graph_compute_with_ctx(ctx, graph, 1); ggml_free(ctx); }
O0
cpp
copy_ggml_tensor(ggml_tensor*, ggml_tensor*): subq $0x88, %rsp movq %rdi, 0x80(%rsp) movq %rsi, 0x78(%rsp) movq 0x80(%rsp), %rax movl (%rax), %eax movq 0x78(%rsp), %rcx cmpl (%rcx), %eax jne 0x36798 movq 0x78(%rsp), %rax movq 0x30(%rax), %rcx movq 0x80(%rsp), %rax movq %rcx, 0x30(%rax) movq 0x78(%rsp), %rax movq 0x38(%rax), %rcx movq 0x80(%rsp), %rax movq %rcx, 0x38(%rax) movq 0x78(%rsp), %rax movq 0x40(%rax), %rcx movq 0x80(%rsp), %rax movq %rcx, 0x40(%rax) movq 0x78(%rsp), %rax movq 0x48(%rax), %rcx movq 0x80(%rsp), %rax movq %rcx, 0x48(%rax) movq 0x80(%rsp), %rax movq 0x118(%rax), %rax movq %rax, 0x20(%rsp) movq 0x78(%rsp), %rax movq 0x118(%rax), %rax movq %rax, 0x28(%rsp) movq 0x80(%rsp), %rdi callq 0x11ae90 movq 0x20(%rsp), %rdi movq 0x28(%rsp), %rsi movq %rax, %rdx callq 0xb600 jmp 0x36876 movq $0xa00000, 0x60(%rsp) # imm = 0xA00000 movq $0x0, 0x68(%rsp) movb $0x0, 0x70(%rsp) movq 0x60(%rsp), %rax movq %rax, 0x40(%rsp) movq 0x68(%rsp), %rax movq %rax, 0x48(%rsp) movq 0x70(%rsp), %rax movq %rax, 0x50(%rsp) leaq 0x40(%rsp), %rax movq (%rax), %rcx movq %rcx, (%rsp) movq 0x8(%rax), %rcx movq %rcx, 0x8(%rsp) movq 0x10(%rax), %rax movq %rax, 0x10(%rsp) callq 0x11b680 movq %rax, 0x58(%rsp) cmpq $0x0, 0x58(%rsp) jne 0x3681e movl $0x3, %edi leaq 0x149553(%rip), %rsi # 0x17fd5c movl $0xb7, %edx leaq 0x148ec1(%rip), %rcx # 0x17f6d6 movb $0x0, %al callq 0xeb5e0 jmp 0x36876 movq 0x58(%rsp), %rdi movq 0x78(%rsp), %rsi movq 0x80(%rsp), %rdx callq 0x1222f0 movq %rax, 0x38(%rsp) movq 0x58(%rsp), %rdi callq 0x12dcf0 movq %rax, 0x30(%rsp) movq 0x30(%rsp), %rdi movq 0x38(%rsp), %rsi callq 0x12a100 movq 0x58(%rsp), %rdi movq 0x30(%rsp), %rsi movl $0x1, %edx callq 0x12f980 movq 0x58(%rsp), %rdi callq 0x11bfa0 addq $0x88, %rsp retq nop
_ZL16copy_ggml_tensorP11ggml_tensorS0_: sub rsp, 88h mov [rsp+88h+var_8], rdi mov [rsp+88h+var_10], rsi mov rax, [rsp+88h+var_8] mov eax, [rax] mov rcx, [rsp+88h+var_10] cmp eax, [rcx] jnz loc_36798 mov rax, [rsp+88h+var_10] mov rcx, [rax+30h] mov rax, [rsp+88h+var_8] mov [rax+30h], rcx mov rax, [rsp+88h+var_10] mov rcx, [rax+38h] mov rax, [rsp+88h+var_8] mov [rax+38h], rcx mov rax, [rsp+88h+var_10] mov rcx, [rax+40h] mov rax, [rsp+88h+var_8] mov [rax+40h], rcx mov rax, [rsp+88h+var_10] mov rcx, [rax+48h] mov rax, [rsp+88h+var_8] mov [rax+48h], rcx mov rax, [rsp+88h+var_8] mov rax, [rax+118h] mov [rsp+88h+var_68], rax mov rax, [rsp+88h+var_10] mov rax, [rax+118h] mov [rsp+88h+var_60], rax mov rdi, [rsp+88h+var_8] call ggml_nbytes mov rdi, [rsp+88h+var_68] mov rsi, [rsp+88h+var_60] mov rdx, rax call _memcpy jmp loc_36876 loc_36798: mov [rsp+88h+var_28], 0A00000h mov [rsp+88h+var_20], 0 mov byte ptr [rsp+88h+var_18], 0 mov rax, [rsp+88h+var_28] mov [rsp+88h+var_48], rax mov rax, [rsp+88h+var_20] mov [rsp+88h+var_40], rax mov rax, [rsp+88h+var_18] mov [rsp+88h+var_38], rax lea rax, [rsp+88h+var_48] mov rcx, [rax] mov [rsp+88h+var_88], rcx mov rcx, [rax+8] mov [rsp+88h+var_80], rcx mov rax, [rax+10h] mov [rsp+88h+var_78], rax call ggml_init mov [rsp+88h+var_30], rax cmp [rsp+88h+var_30], 0 jnz short loc_3681E mov edi, 3 lea rsi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github/2025_star3"... mov edx, 0B7h lea rcx, aGgmlInitFailed; "ggml_init() failed" mov al, 0 call _Z10log_printf14sd_log_level_tPKciS1_z; log_printf(sd_log_level_t,char const*,int,char const*,...) jmp short loc_36876 loc_3681E: mov rdi, [rsp+88h+var_30] mov rsi, [rsp+88h+var_10] mov rdx, [rsp+88h+var_8] call ggml_cpy_inplace mov [rsp+88h+var_50], rax mov rdi, [rsp+88h+var_30] call ggml_new_graph mov [rsp+88h+var_58], rax mov rdi, [rsp+88h+var_58] mov rsi, [rsp+88h+var_50] call ggml_build_forward_expand mov rdi, [rsp+88h+var_30] mov rsi, [rsp+88h+var_58] mov edx, 1 call ggml_graph_compute_with_ctx mov rdi, [rsp+88h+var_30] call ggml_free loc_36876: add rsp, 88h retn
long long copy_ggml_tensor(long long a1, long long a2, int a3, long long a4, int a5, int a6) { long long v6; // rax int v8; // r8d int v9; // r9d long long v10; // [rsp+20h] [rbp-68h] long long v11; // [rsp+28h] [rbp-60h] long long v12; // [rsp+30h] [rbp-58h] long long v13; // [rsp+38h] [rbp-50h] long long v14; // [rsp+58h] [rbp-30h] if ( *(_DWORD *)a1 == *(_DWORD *)a2 ) { *(_QWORD *)(a1 + 48) = *(_QWORD *)(a2 + 48); *(_QWORD *)(a1 + 56) = *(_QWORD *)(a2 + 56); *(_QWORD *)(a1 + 64) = *(_QWORD *)(a2 + 64); *(_QWORD *)(a1 + 72) = *(_QWORD *)(a2 + 72); v10 = *(_QWORD *)(a1 + 280); v11 = *(_QWORD *)(a2 + 280); v6 = ggml_nbytes(a1); return memcpy(v10, v11, v6); } else { v14 = ggml_init(a1, a2, a3, 0, a5, a6, 10485760LL, 0LL, 0); if ( v14 ) { v13 = ggml_cpy_inplace(v14, a2, a1); v12 = ggml_new_graph(v14); ggml_build_forward_expand(v12, v13); ggml_graph_compute_with_ctx(v14, v12, 1LL); return ggml_free(v14); } else { return log_printf( 3, (unsigned int)"/workspace/llm4binary/github/2025_star3/7CodeWizard[P]stablediffusion/ggml_extend.hpp", 183, (unsigned int)"ggml_init() failed", v8, v9); } } }
copy_ggml_tensor: SUB RSP,0x88 MOV qword ptr [RSP + 0x80],RDI MOV qword ptr [RSP + 0x78],RSI MOV RAX,qword ptr [RSP + 0x80] MOV EAX,dword ptr [RAX] MOV RCX,qword ptr [RSP + 0x78] CMP EAX,dword ptr [RCX] JNZ 0x00136798 MOV RAX,qword ptr [RSP + 0x78] MOV RCX,qword ptr [RAX + 0x30] MOV RAX,qword ptr [RSP + 0x80] MOV qword ptr [RAX + 0x30],RCX MOV RAX,qword ptr [RSP + 0x78] MOV RCX,qword ptr [RAX + 0x38] MOV RAX,qword ptr [RSP + 0x80] MOV qword ptr [RAX + 0x38],RCX MOV RAX,qword ptr [RSP + 0x78] MOV RCX,qword ptr [RAX + 0x40] MOV RAX,qword ptr [RSP + 0x80] MOV qword ptr [RAX + 0x40],RCX MOV RAX,qword ptr [RSP + 0x78] MOV RCX,qword ptr [RAX + 0x48] MOV RAX,qword ptr [RSP + 0x80] MOV qword ptr [RAX + 0x48],RCX MOV RAX,qword ptr [RSP + 0x80] MOV RAX,qword ptr [RAX + 0x118] MOV qword ptr [RSP + 0x20],RAX MOV RAX,qword ptr [RSP + 0x78] MOV RAX,qword ptr [RAX + 0x118] MOV qword ptr [RSP + 0x28],RAX MOV RDI,qword ptr [RSP + 0x80] CALL 0x0021ae90 MOV RDI,qword ptr [RSP + 0x20] MOV RSI,qword ptr [RSP + 0x28] MOV RDX,RAX CALL 0x0010b600 JMP 0x00136876 LAB_00136798: MOV qword ptr [RSP + 0x60],0xa00000 MOV qword ptr [RSP + 0x68],0x0 MOV byte ptr [RSP + 0x70],0x0 MOV RAX,qword ptr [RSP + 0x60] MOV qword ptr [RSP + 0x40],RAX MOV RAX,qword ptr [RSP + 0x68] MOV qword ptr [RSP + 0x48],RAX MOV RAX,qword ptr [RSP + 0x70] MOV qword ptr [RSP + 0x50],RAX LEA RAX,[RSP + 0x40] MOV RCX,qword ptr [RAX] MOV qword ptr [RSP],RCX MOV RCX,qword ptr [RAX + 0x8] MOV qword ptr [RSP + 0x8],RCX MOV RAX,qword ptr [RAX + 0x10] MOV qword ptr [RSP + 0x10],RAX CALL 0x0021b680 MOV qword ptr [RSP + 0x58],RAX CMP qword ptr [RSP + 0x58],0x0 JNZ 0x0013681e MOV EDI,0x3 LEA RSI,[0x27fd5c] MOV EDX,0xb7 LEA RCX,[0x27f6d6] MOV AL,0x0 CALL 0x001eb5e0 JMP 0x00136876 LAB_0013681e: MOV RDI,qword ptr [RSP + 0x58] MOV RSI,qword ptr [RSP + 0x78] MOV RDX,qword ptr [RSP + 0x80] CALL 0x002222f0 MOV qword ptr [RSP + 0x38],RAX MOV RDI,qword ptr [RSP + 0x58] CALL 0x0022dcf0 MOV qword ptr [RSP + 0x30],RAX MOV RDI,qword ptr [RSP + 0x30] MOV RSI,qword ptr [RSP + 0x38] CALL 0x0022a100 MOV RDI,qword ptr [RSP + 0x58] MOV RSI,qword ptr [RSP + 0x30] MOV EDX,0x1 CALL 0x0022f980 MOV RDI,qword ptr [RSP + 0x58] CALL 0x0021bfa0 LAB_00136876: ADD RSP,0x88 RET
/* copy_ggml_tensor(ggml_tensor*, ggml_tensor*) */ void copy_ggml_tensor(ggml_tensor *param_1,ggml_tensor *param_2) { void *__dest; void *__src; size_t __n; long lVar1; int8 in_R8; int8 in_R9; int8 uVar2; int8 uVar3; long lVar4; uint7 uStack_17; if (*(int *)param_1 == *(int *)param_2) { *(int8 *)(param_1 + 0x30) = *(int8 *)(param_2 + 0x30); *(int8 *)(param_1 + 0x38) = *(int8 *)(param_2 + 0x38); *(int8 *)(param_1 + 0x40) = *(int8 *)(param_2 + 0x40); *(int8 *)(param_1 + 0x48) = *(int8 *)(param_2 + 0x48); __dest = *(void **)(param_1 + 0x118); __src = *(void **)(param_2 + 0x118); __n = ggml_nbytes(param_1); memcpy(__dest,__src,__n); } else { lVar4 = (ulong)uStack_17 << 8; uVar2 = 0xa00000; uVar3 = 0; lVar1 = ggml_init(); if (lVar1 == 0) { log_printf(3, "/workspace/llm4binary/github/2025_star3/7CodeWizard[P]stablediffusion/ggml_extend.hpp" ,0xb7,"ggml_init() failed",in_R8,in_R9,uVar2,uVar3,lVar4); } else { uVar2 = ggml_cpy_inplace(lVar1,param_2,param_1); uVar3 = ggml_new_graph(lVar1); ggml_build_forward_expand(uVar3,uVar2); ggml_graph_compute_with_ctx(lVar1,uVar3,1); ggml_free(lVar1); } } return; }
27,536
my_strnxfrm_uca_padn
eloqsql/strings/ctype-uca.c
static uchar * my_strnxfrm_uca_padn(uchar *dst, uchar *de, uint nweights, int weight) { uint count= MY_MIN((uint) (de - dst) / 2, nweights); for (; count ; count--) { *dst++= weight >> 8; *dst++= weight & 0xFF; } return dst; }
O0
c
my_strnxfrm_uca_padn: pushq %rbp movq %rsp, %rbp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movl %edx, -0x14(%rbp) movl %ecx, -0x18(%rbp) movq -0x10(%rbp), %rax movq -0x8(%rbp), %rcx subq %rcx, %rax shrl %eax cmpl -0x14(%rbp), %eax jae 0x86de6 movq -0x10(%rbp), %rax movq -0x8(%rbp), %rcx subq %rcx, %rax shrl %eax movl %eax, -0x20(%rbp) jmp 0x86dec movl -0x14(%rbp), %eax movl %eax, -0x20(%rbp) movl -0x20(%rbp), %eax movl %eax, -0x1c(%rbp) cmpl $0x0, -0x1c(%rbp) je 0x86e37 movl -0x18(%rbp), %eax sarl $0x8, %eax movb %al, %cl movq -0x8(%rbp), %rax movq %rax, %rdx addq $0x1, %rdx movq %rdx, -0x8(%rbp) movb %cl, (%rax) movl -0x18(%rbp), %eax andl $0xff, %eax movb %al, %cl movq -0x8(%rbp), %rax movq %rax, %rdx addq $0x1, %rdx movq %rdx, -0x8(%rbp) movb %cl, (%rax) movl -0x1c(%rbp), %eax addl $-0x1, %eax movl %eax, -0x1c(%rbp) jmp 0x86df2 movq -0x8(%rbp), %rax popq %rbp retq nopl (%rax)
my_strnxfrm_uca_padn: push rbp mov rbp, rsp mov [rbp+var_8], rdi mov [rbp+var_10], rsi mov [rbp+var_14], edx mov [rbp+var_18], ecx mov rax, [rbp+var_10] mov rcx, [rbp+var_8] sub rax, rcx shr eax, 1 cmp eax, [rbp+var_14] jnb short loc_86DE6 mov rax, [rbp+var_10] mov rcx, [rbp+var_8] sub rax, rcx shr eax, 1 mov [rbp+var_20], eax jmp short loc_86DEC loc_86DE6: mov eax, [rbp+var_14] mov [rbp+var_20], eax loc_86DEC: mov eax, [rbp+var_20] mov [rbp+var_1C], eax loc_86DF2: cmp [rbp+var_1C], 0 jz short loc_86E37 mov eax, [rbp+var_18] sar eax, 8 mov cl, al mov rax, [rbp+var_8] mov rdx, rax add rdx, 1 mov [rbp+var_8], rdx mov [rax], cl mov eax, [rbp+var_18] and eax, 0FFh mov cl, al mov rax, [rbp+var_8] mov rdx, rax add rdx, 1 mov [rbp+var_8], rdx mov [rax], cl mov eax, [rbp+var_1C] add eax, 0FFFFFFFFh mov [rbp+var_1C], eax jmp short loc_86DF2 loc_86E37: mov rax, [rbp+var_8] pop rbp retn
_BYTE * my_strnxfrm_uca_padn(_BYTE *a1, int a2, unsigned int a3, __int16 a4) { _BYTE *v4; // rax unsigned int v6; // [rsp+0h] [rbp-20h] unsigned int i; // [rsp+4h] [rbp-1Ch] _BYTE *v8; // [rsp+18h] [rbp-8h] v8 = a1; if ( (unsigned int)(a2 - (_DWORD)a1) >> 1 >= a3 ) v6 = a3; else v6 = (unsigned int)(a2 - (_DWORD)a1) >> 1; for ( i = v6; i; --i ) { *v8 = HIBYTE(a4); v4 = v8 + 1; v8 += 2; *v4 = a4; } return v8; }
my_strnxfrm_uca_padn: PUSH RBP MOV RBP,RSP 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 RAX,qword ptr [RBP + -0x10] MOV RCX,qword ptr [RBP + -0x8] SUB RAX,RCX SHR EAX,0x1 CMP EAX,dword ptr [RBP + -0x14] JNC 0x00186de6 MOV RAX,qword ptr [RBP + -0x10] MOV RCX,qword ptr [RBP + -0x8] SUB RAX,RCX SHR EAX,0x1 MOV dword ptr [RBP + -0x20],EAX JMP 0x00186dec LAB_00186de6: MOV EAX,dword ptr [RBP + -0x14] MOV dword ptr [RBP + -0x20],EAX LAB_00186dec: MOV EAX,dword ptr [RBP + -0x20] MOV dword ptr [RBP + -0x1c],EAX LAB_00186df2: CMP dword ptr [RBP + -0x1c],0x0 JZ 0x00186e37 MOV EAX,dword ptr [RBP + -0x18] SAR EAX,0x8 MOV CL,AL MOV RAX,qword ptr [RBP + -0x8] MOV RDX,RAX ADD RDX,0x1 MOV qword ptr [RBP + -0x8],RDX MOV byte ptr [RAX],CL MOV EAX,dword ptr [RBP + -0x18] AND EAX,0xff MOV CL,AL MOV RAX,qword ptr [RBP + -0x8] MOV RDX,RAX ADD RDX,0x1 MOV qword ptr [RBP + -0x8],RDX MOV byte ptr [RAX],CL MOV EAX,dword ptr [RBP + -0x1c] ADD EAX,-0x1 MOV dword ptr [RBP + -0x1c],EAX JMP 0x00186df2 LAB_00186e37: MOV RAX,qword ptr [RBP + -0x8] POP RBP RET
int1 * my_strnxfrm_uca_padn(int1 *param_1,int param_2,uint param_3,int4 param_4) { int1 *puVar1; uint local_28; uint local_24; int1 *local_10; local_28 = param_3; if ((uint)(param_2 - (int)param_1) >> 1 < param_3) { local_28 = (uint)(param_2 - (int)param_1) >> 1; } local_10 = param_1; for (local_24 = local_28; local_24 != 0; local_24 = local_24 - 1) { puVar1 = local_10 + 1; *local_10 = (char)((uint)param_4 >> 8); local_10 = local_10 + 2; *puVar1 = (char)param_4; } return local_10; }
27,537
normalize_dirname
eloqsql/mysys/mf_pack.c
size_t normalize_dirname(char *to, const char *from) { size_t length; char buff[FN_REFLEN + 1]; DBUG_ENTER("normalize_dirname"); /* Despite the name, this actually converts the name to the system's format (TODO: name this properly). */ (void) intern_filename(buff, from); length= strlen(buff); /* Fix that '/' is last */ if (length && #ifdef FN_DEVCHAR buff[length - 1] != FN_DEVCHAR && #endif buff[length - 1] != FN_LIBCHAR && buff[length - 1] != '/') { /* we need reserve 2 bytes for the trailing slash and the zero */ if (length >= sizeof (buff) - 1) length= sizeof (buff) - 2; buff[length]= FN_LIBCHAR; buff[length + 1]= '\0'; } length=cleanup_dirname(to, buff); DBUG_RETURN(length); }
O3
c
normalize_dirname: pushq %rbp movq %rsp, %rbp pushq %r14 pushq %rbx subq $0x210, %rsp # imm = 0x210 movq %rdi, %rbx movq %fs:0x28, %rax movq %rax, -0x18(%rbp) leaq -0x220(%rbp), %r14 movq %r14, %rdi callq 0x564a5 movq %r14, %rdi callq 0x28130 testq %rax, %rax je 0x567fb cmpb $0x2f, -0x1(%rax,%r14) je 0x567fb movl $0x1ff, %ecx # imm = 0x1FF cmpq %rcx, %rax cmovbq %rax, %rcx movw $0x2f, -0x220(%rbp,%rcx) leaq -0x220(%rbp), %rsi movq %rbx, %rdi callq 0x5653b movq %fs:0x28, %rcx cmpq -0x18(%rbp), %rcx jne 0x56825 addq $0x210, %rsp # imm = 0x210 popq %rbx popq %r14 popq %rbp retq callq 0x283d0
normalize_dirname: push rbp mov rbp, rsp push r14 push rbx sub rsp, 210h mov rbx, rdi mov rax, fs:28h mov [rbp+var_18], rax lea r14, [rbp+var_220] mov rdi, r14 call intern_filename mov rdi, r14 call _strlen test rax, rax jz short loc_567FB cmp byte ptr [rax+r14-1], 2Fh ; '/' jz short loc_567FB mov ecx, 1FFh cmp rax, rcx cmovb rcx, rax mov [rbp+rcx+var_220], 2Fh ; '/' loc_567FB: lea rsi, [rbp+var_220] mov rdi, rbx call cleanup_dirname mov rcx, fs:28h cmp rcx, [rbp+var_18] jnz short loc_56825 add rsp, 210h pop rbx pop r14 pop rbp retn loc_56825: call ___stack_chk_fail
long long normalize_dirname(long long a1, _BYTE *a2) { unsigned long long v2; // rax long long v3; // rcx unsigned __int8 v5[520]; // [rsp+0h] [rbp-220h] BYREF unsigned long long v6; // [rsp+208h] [rbp-18h] v6 = __readfsqword(0x28u); intern_filename((long long)v5, a2); v2 = strlen(v5); if ( v2 && v5[v2 - 1] != 47 ) { v3 = 511LL; if ( v2 < 0x1FF ) v3 = v2; *(_WORD *)&v5[v3] = 47; } return cleanup_dirname(a1, v5); }
normalize_dirname: PUSH RBP MOV RBP,RSP PUSH R14 PUSH RBX SUB RSP,0x210 MOV RBX,RDI MOV RAX,qword ptr FS:[0x28] MOV qword ptr [RBP + -0x18],RAX LEA R14,[RBP + -0x220] MOV RDI,R14 CALL 0x001564a5 MOV RDI,R14 CALL 0x00128130 TEST RAX,RAX JZ 0x001567fb CMP byte ptr [RAX + R14*0x1 + -0x1],0x2f JZ 0x001567fb MOV ECX,0x1ff CMP RAX,RCX CMOVC RCX,RAX MOV word ptr [RBP + RCX*0x1 + -0x220],0x2f LAB_001567fb: LEA RSI,[RBP + -0x220] MOV RDI,RBX CALL 0x0015653b MOV RCX,qword ptr FS:[0x28] CMP RCX,qword ptr [RBP + -0x18] JNZ 0x00156825 ADD RSP,0x210 POP RBX POP R14 POP RBP RET LAB_00156825: CALL 0x001283d0
void normalize_dirname(int8 param_1) { size_t sVar1; size_t sVar2; long in_FS_OFFSET; int8 uStack_230; char local_228 [520]; long local_20; local_20 = *(long *)(in_FS_OFFSET + 0x28); uStack_230 = (code *)0x1567d0; intern_filename(local_228); uStack_230 = (code *)0x1567d8; sVar1 = strlen(local_228); if ((sVar1 != 0) && (local_228[sVar1 - 1] != '/')) { sVar2 = 0x1ff; if (sVar1 < 0x1ff) { sVar2 = sVar1; } (local_228 + sVar2)[0] = '/'; (local_228 + sVar2)[1] = '\0'; } uStack_230 = (code *)0x15680a; cleanup_dirname(param_1,local_228); if (*(long *)(in_FS_OFFSET + 0x28) == local_20) { return; } /* WARNING: Subroutine does not return */ uStack_230 = unpack_dirname; __stack_chk_fail(); }
27,538
my_strntol_mb2_or_mb4
eloqsql/strings/ctype-ucs2.c
static long my_strntol_mb2_or_mb4(CHARSET_INFO *cs, const char *nptr, size_t l, int base, char **endptr, int *err) { int negative= 0; int overflow; int cnv; my_wc_t wc; my_charset_conv_mb_wc mb_wc= cs->cset->mb_wc; register unsigned int cutlim; register uint32 cutoff; register uint32 res; register const uchar *s= (const uchar*) nptr; register const uchar *e= (const uchar*) nptr+l; const uchar *save; *err= 0; do { if ((cnv= mb_wc(cs, &wc, s, e)) > 0) { switch (wc) { case ' ' : break; case '\t': break; case '-' : negative= !negative; break; case '+' : break; default : goto bs; } } else /* No more characters or bad multibyte sequence */ { if (endptr != NULL ) *endptr= (char*) s; err[0]= (cnv==MY_CS_ILSEQ) ? EILSEQ : EDOM; return 0; } s+= cnv; } while (1); bs: overflow= 0; res= 0; save= s; cutoff= ((uint32)~0L) / (uint32) base; cutlim= (uint) (((uint32)~0L) % (uint32) base); do { if ((cnv= mb_wc(cs, &wc, s, e)) > 0) { s+= cnv; if (wc >= '0' && wc <= '9') wc-= '0'; else if (wc >= 'A' && wc <= 'Z') wc= wc - 'A' + 10; else if (wc >= 'a' && wc <= 'z') wc= wc - 'a' + 10; else break; if ((int)wc >= base) break; if (res > cutoff || (res == cutoff && wc > cutlim)) overflow= 1; else { res*= (uint32) base; res+= wc; } } else if (cnv == MY_CS_ILSEQ) { if (endptr !=NULL ) *endptr = (char*) s; err[0]= EILSEQ; return 0; } else { /* No more characters */ break; } } while(1); if (endptr != NULL) *endptr = (char *) s; if (s == save) { err[0]= EDOM; return 0L; } if (negative) { if (res > (uint32) INT_MIN32) overflow= 1; } else if (res > INT_MAX32) overflow= 1; if (overflow) { err[0]= ERANGE; return negative ? INT_MIN32 : INT_MAX32; } return (negative ? -((long) res) : (long) res); }
O3
c
my_strntol_mb2_or_mb4: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x38, %rsp movq %r8, -0x40(%rbp) movl %ecx, -0x34(%rbp) movq %rdx, %r13 movq %rsi, %r15 movq %rdi, %r14 movq 0xb8(%rdi), %rax movq 0x28(%rax), %r12 addq %rsi, %r13 movq %r9, -0x50(%rbp) movl $0x0, (%r9) leaq -0x30(%rbp), %rsi movq %r15, %rdx movq %r13, %rcx callq *%r12 testl %eax, %eax jle 0x47c16 movl $0x0, -0x38(%rbp) leaq -0x30(%rbp), %rbx movq -0x30(%rbp), %rcx cmpq $0x2a, %rcx jg 0x47be6 cmpq $0x9, %rcx je 0x47bfe cmpq $0x20, %rcx je 0x47bfe jmp 0x47c48 cmpq $0x2b, %rcx je 0x47bfe cmpq $0x2d, %rcx jne 0x47c48 xorl %ecx, %ecx cmpl $0x0, -0x38(%rbp) sete %cl movl %ecx, -0x38(%rbp) movl %eax, %eax addq %rax, %r15 movq %r14, %rdi movq %rbx, %rsi movq %r15, %rdx movq %r13, %rcx callq *%r12 testl %eax, %eax jg 0x47bce movq -0x40(%rbp), %rcx testq %rcx, %rcx je 0x47c22 movq %r15, (%rcx) testl %eax, %eax movl $0x54, %eax movl $0x21, %ecx cmovel %eax, %ecx movq -0x50(%rbp), %rax movl %ecx, (%rax) xorl %eax, %eax addq $0x38, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq movl $0xffffffff, %eax # imm = 0xFFFFFFFF xorl %edx, %edx divl -0x34(%rbp) movl %edx, %ebx movl %eax, -0x44(%rbp) leaq -0x30(%rbp), %rsi movq %r14, %rdi movq %r15, %rdx movq %r13, %rcx callq *%r12 testl %eax, %eax jle 0x47d0e movl %ebx, %ecx movq %rcx, -0x60(%rbp) xorl %ecx, %ecx movq %r15, %rbx xorl %r8d, %r8d movq %rbx, %rsi movl %eax, %ebx addq %rsi, %rbx movq -0x30(%rbp), %rsi leaq -0x30(%rsi), %rax cmpq $0x9, %rax ja 0x47c99 movq %rax, -0x30(%rbp) jmp 0x47cbe leaq -0x41(%rsi), %rax cmpq $0x19, %rax ja 0x47ca9 addq $-0x37, %rsi jmp 0x47cb7 leaq -0x61(%rsi), %rax cmpq $0x19, %rax ja 0x47d1e addq $-0x57, %rsi movq %rsi, -0x30(%rbp) movq %rsi, %rax cmpl -0x34(%rbp), %eax jge 0x47d1e movl $0x1, %esi cmpl -0x44(%rbp), %ecx ja 0x47ce1 jne 0x47cd8 movl -0x44(%rbp), %edi cmpq -0x60(%rbp), %rax ja 0x47ce3 imull -0x34(%rbp), %ecx addl %eax, %ecx movl %r8d, %esi movl %ecx, %edi movl %edi, -0x54(%rbp) movl %esi, -0x58(%rbp) movq %r14, %rdi leaq -0x30(%rbp), %rsi movq %rbx, %rdx movq %r13, %rcx callq *%r12 movl -0x54(%rbp), %edi movl -0x58(%rbp), %esi movl %edi, %ecx movl %esi, %r8d testl %eax, %eax jg 0x47c7d jmp 0x47d15 xorl %edi, %edi movq %r15, %rbx xorl %esi, %esi testl %eax, %eax je 0x47d7d movl %esi, %r8d movl %edi, %ecx movq -0x40(%rbp), %rax testq %rax, %rax je 0x47d2a movq %rbx, (%rax) cmpq %r15, %rbx je 0x47d6e cmpl $0x80000001, %ecx # imm = 0x80000001 movl $0x1, %eax movl %r8d, %esi cmovael %eax, %esi testl %ecx, %ecx cmovsl %eax, %r8d movl -0x38(%rbp), %edi testl %edi, %edi cmovnel %esi, %r8d testl %r8d, %r8d je 0x47d98 testl %edi, %edi movq -0x50(%rbp), %rax movl $0x22, (%rax) movl $0x7fffffff, %ecx # imm = 0x7FFFFFFF movq $-0x80000000, %rax # imm = 0x80000000 jmp 0x47da2 movq -0x50(%rbp), %rax movl $0x21, (%rax) jmp 0x47c37 movq -0x40(%rbp), %rax testq %rax, %rax je 0x47d89 movq %rbx, (%rax) movq -0x50(%rbp), %rax movl $0x54, (%rax) jmp 0x47c37 movl %ecx, %ecx movq %rcx, %rax negq %rax testl %edi, %edi cmoveq %rcx, %rax jmp 0x47c39
my_strntol_mb2_or_mb4: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx sub rsp, 38h mov [rbp+var_40], r8 mov [rbp+var_34], ecx mov r13, rdx mov r15, rsi mov r14, rdi mov rax, [rdi+0B8h] mov r12, [rax+28h] add r13, rsi mov [rbp+var_50], r9 mov dword ptr [r9], 0 lea rsi, [rbp+var_30] mov rdx, r15 mov rcx, r13 call r12 test eax, eax jle short loc_47C16 mov [rbp+var_38], 0 lea rbx, [rbp+var_30] loc_47BCE: mov rcx, [rbp+var_30] cmp rcx, 2Ah ; '*' jg short loc_47BE6 cmp rcx, 9 jz short loc_47BFE cmp rcx, 20h ; ' ' jz short loc_47BFE jmp short loc_47C48 loc_47BE6: cmp rcx, 2Bh ; '+' jz short loc_47BFE cmp rcx, 2Dh ; '-' jnz short loc_47C48 xor ecx, ecx cmp [rbp+var_38], 0 setz cl mov [rbp+var_38], ecx loc_47BFE: mov eax, eax add r15, rax mov rdi, r14 mov rsi, rbx mov rdx, r15 mov rcx, r13 call r12 test eax, eax jg short loc_47BCE loc_47C16: mov rcx, [rbp+var_40] test rcx, rcx jz short loc_47C22 mov [rcx], r15 loc_47C22: test eax, eax mov eax, 54h ; 'T' mov ecx, 21h ; '!' cmovz ecx, eax mov rax, [rbp+var_50] mov [rax], ecx loc_47C37: xor eax, eax loc_47C39: add rsp, 38h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn loc_47C48: mov eax, 0FFFFFFFFh xor edx, edx div [rbp+var_34] mov ebx, edx mov [rbp+var_44], eax lea rsi, [rbp+var_30] mov rdi, r14 mov rdx, r15 mov rcx, r13 call r12 test eax, eax jle loc_47D0E mov ecx, ebx mov [rbp+var_60], rcx xor ecx, ecx mov rbx, r15 xor r8d, r8d loc_47C7D: mov rsi, rbx mov ebx, eax add rbx, rsi mov rsi, [rbp+var_30] lea rax, [rsi-30h] cmp rax, 9 ja short loc_47C99 mov [rbp+var_30], rax jmp short loc_47CBE loc_47C99: lea rax, [rsi-41h] cmp rax, 19h ja short loc_47CA9 add rsi, 0FFFFFFFFFFFFFFC9h jmp short loc_47CB7 loc_47CA9: lea rax, [rsi-61h] cmp rax, 19h ja short loc_47D1E add rsi, 0FFFFFFFFFFFFFFA9h loc_47CB7: mov [rbp+var_30], rsi mov rax, rsi loc_47CBE: cmp eax, [rbp+var_34] jge short loc_47D1E mov esi, 1 cmp ecx, [rbp+var_44] ja short loc_47CE1 jnz short loc_47CD8 mov edi, [rbp+var_44] cmp rax, [rbp+var_60] ja short loc_47CE3 loc_47CD8: imul ecx, [rbp+var_34] add ecx, eax mov esi, r8d loc_47CE1: mov edi, ecx loc_47CE3: mov [rbp+var_54], edi mov [rbp+var_58], esi mov rdi, r14 lea rsi, [rbp+var_30] mov rdx, rbx mov rcx, r13 call r12 mov edi, [rbp+var_54] mov esi, [rbp+var_58] mov ecx, edi mov r8d, esi test eax, eax jg loc_47C7D jmp short loc_47D15 loc_47D0E: xor edi, edi mov rbx, r15 xor esi, esi loc_47D15: test eax, eax jz short loc_47D7D mov r8d, esi mov ecx, edi loc_47D1E: mov rax, [rbp+var_40] test rax, rax jz short loc_47D2A mov [rax], rbx loc_47D2A: cmp rbx, r15 jz short loc_47D6E cmp ecx, 80000001h mov eax, 1 mov esi, r8d cmovnb esi, eax test ecx, ecx cmovs r8d, eax mov edi, [rbp+var_38] test edi, edi cmovnz r8d, esi test r8d, r8d jz short loc_47D98 test edi, edi mov rax, [rbp+var_50] mov dword ptr [rax], 22h ; '"' mov ecx, 7FFFFFFFh mov rax, 0FFFFFFFF80000000h jmp short loc_47DA2 loc_47D6E: mov rax, [rbp+var_50] mov dword ptr [rax], 21h ; '!' jmp loc_47C37 loc_47D7D: mov rax, [rbp+var_40] test rax, rax jz short loc_47D89 mov [rax], rbx loc_47D89: mov rax, [rbp+var_50] mov dword ptr [rax], 54h ; 'T' jmp loc_47C37 loc_47D98: mov ecx, ecx mov rax, rcx neg rax test edi, edi loc_47DA2: cmovz rax, rcx jmp loc_47C39
long long my_strntol_mb2_or_mb4(long long a1, long long a2, long long a3, unsigned int a4, _QWORD *a5, int *a6) { long long v6; // r15 long long ( *v8)(long long, _QWORD *, long long, long long); // r12 long long v9; // r13 int v10; // eax int v11; // ecx long long result; // rax int v13; // eax long long v14; // rcx long long v15; // rbx long long v16; // r8 unsigned long long v17; // rax long long v18; // rsi unsigned int v19; // esi unsigned int v20; // edi int v21; // esi bool v22; // zf unsigned int v24; // [rsp+1Ch] [rbp-44h] BOOL v26; // [rsp+28h] [rbp-38h] _QWORD v28[6]; // [rsp+30h] [rbp-30h] BYREF v6 = a2; v8 = *(long long ( **)(long long, _QWORD *, long long, long long))(*(_QWORD *)(a1 + 184) + 40LL); v9 = a2 + a3; *a6 = 0; v10 = v8(a1, v28, a2, a2 + a3); if ( v10 <= 0 ) { LABEL_11: if ( a5 ) *a5 = v6; v11 = 33; if ( !v10 ) v11 = 84; *a6 = v11; return 0LL; } v26 = 0; while ( 1 ) { if ( v28[0] > 42LL ) { if ( v28[0] != 43LL ) { if ( v28[0] != 45LL ) break; v26 = !v26; } goto LABEL_10; } if ( v28[0] != 9LL && v28[0] != 32LL ) break; LABEL_10: v6 += (unsigned int)v10; v10 = v8(a1, v28, v6, v9); if ( v10 <= 0 ) goto LABEL_11; } v24 = 0xFFFFFFFF / a4; v13 = v8(a1, v28, v6, v9); if ( v13 > 0 ) { LODWORD(v14) = 0; v15 = v6; v16 = 0LL; while ( 1 ) { v15 += (unsigned int)v13; v17 = v28[0] - 48LL; if ( (unsigned long long)(v28[0] - 48LL) > 9 ) { if ( (unsigned long long)(v28[0] - 65LL) > 0x19 ) { if ( (unsigned long long)(v28[0] - 97LL) > 0x19 ) goto LABEL_37; v18 = v28[0] - 87LL; } else { v18 = v28[0] - 55LL; } v28[0] = v18; v17 = v18; } else { v28[0] -= 48LL; } if ( (int)v17 >= (int)a4 ) goto LABEL_37; v19 = 1; if ( (unsigned int)v14 <= v24 ) { if ( (_DWORD)v14 == v24 ) { v20 = 0xFFFFFFFF / a4; if ( v17 > 0xFFFFFFFF % a4 ) goto LABEL_32; } LODWORD(v14) = v17 + a4 * v14; v19 = v16; } v20 = v14; LABEL_32: v13 = ((long long ( *)(long long, _QWORD *, long long, long long, long long))v8)(a1, v28, v15, v9, v16); LODWORD(v14) = v20; v16 = v19; if ( v13 <= 0 ) goto LABEL_35; } } v20 = 0; v15 = v6; v19 = 0; LABEL_35: if ( !v13 ) { if ( a5 ) *a5 = v15; *a6 = 84; return 0LL; } LODWORD(v16) = v19; LODWORD(v14) = v20; LABEL_37: if ( a5 ) *a5 = v15; if ( v15 == v6 ) { *a6 = 33; return 0LL; } v21 = v16; if ( (unsigned int)v14 >= 0x80000001 ) v21 = 1; if ( (int)v14 < 0 ) LODWORD(v16) = 1; if ( v26 ) LODWORD(v16) = v21; if ( (_DWORD)v16 ) { v22 = !v26; *a6 = 34; v14 = 0x7FFFFFFFLL; result = 0xFFFFFFFF80000000LL; } else { v14 = (unsigned int)v14; result = -(long long)(unsigned int)v14; v22 = !v26; } if ( v22 ) return v14; return result; }
my_strntol_mb2_or_mb4: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x38 MOV qword ptr [RBP + -0x40],R8 MOV dword ptr [RBP + -0x34],ECX MOV R13,RDX MOV R15,RSI MOV R14,RDI MOV RAX,qword ptr [RDI + 0xb8] MOV R12,qword ptr [RAX + 0x28] ADD R13,RSI MOV qword ptr [RBP + -0x50],R9 MOV dword ptr [R9],0x0 LEA RSI,[RBP + -0x30] MOV RDX,R15 MOV RCX,R13 CALL R12 TEST EAX,EAX JLE 0x00147c16 MOV dword ptr [RBP + -0x38],0x0 LEA RBX,[RBP + -0x30] LAB_00147bce: MOV RCX,qword ptr [RBP + -0x30] CMP RCX,0x2a JG 0x00147be6 CMP RCX,0x9 JZ 0x00147bfe CMP RCX,0x20 JZ 0x00147bfe JMP 0x00147c48 LAB_00147be6: CMP RCX,0x2b JZ 0x00147bfe CMP RCX,0x2d JNZ 0x00147c48 XOR ECX,ECX CMP dword ptr [RBP + -0x38],0x0 SETZ CL MOV dword ptr [RBP + -0x38],ECX LAB_00147bfe: MOV EAX,EAX ADD R15,RAX MOV RDI,R14 MOV RSI,RBX MOV RDX,R15 MOV RCX,R13 CALL R12 TEST EAX,EAX JG 0x00147bce LAB_00147c16: MOV RCX,qword ptr [RBP + -0x40] TEST RCX,RCX JZ 0x00147c22 MOV qword ptr [RCX],R15 LAB_00147c22: TEST EAX,EAX MOV EAX,0x54 MOV ECX,0x21 CMOVZ ECX,EAX MOV RAX,qword ptr [RBP + -0x50] MOV dword ptr [RAX],ECX LAB_00147c37: XOR EAX,EAX LAB_00147c39: ADD RSP,0x38 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET LAB_00147c48: MOV EAX,0xffffffff XOR EDX,EDX DIV dword ptr [RBP + -0x34] MOV EBX,EDX MOV dword ptr [RBP + -0x44],EAX LEA RSI,[RBP + -0x30] MOV RDI,R14 MOV RDX,R15 MOV RCX,R13 CALL R12 TEST EAX,EAX JLE 0x00147d0e MOV ECX,EBX MOV qword ptr [RBP + -0x60],RCX XOR ECX,ECX MOV RBX,R15 XOR R8D,R8D LAB_00147c7d: MOV RSI,RBX MOV EBX,EAX ADD RBX,RSI MOV RSI,qword ptr [RBP + -0x30] LEA RAX,[RSI + -0x30] CMP RAX,0x9 JA 0x00147c99 MOV qword ptr [RBP + -0x30],RAX JMP 0x00147cbe LAB_00147c99: LEA RAX,[RSI + -0x41] CMP RAX,0x19 JA 0x00147ca9 ADD RSI,-0x37 JMP 0x00147cb7 LAB_00147ca9: LEA RAX,[RSI + -0x61] CMP RAX,0x19 JA 0x00147d1e ADD RSI,-0x57 LAB_00147cb7: MOV qword ptr [RBP + -0x30],RSI MOV RAX,RSI LAB_00147cbe: CMP EAX,dword ptr [RBP + -0x34] JGE 0x00147d1e MOV ESI,0x1 CMP ECX,dword ptr [RBP + -0x44] JA 0x00147ce1 JNZ 0x00147cd8 MOV EDI,dword ptr [RBP + -0x44] CMP RAX,qword ptr [RBP + -0x60] JA 0x00147ce3 LAB_00147cd8: IMUL ECX,dword ptr [RBP + -0x34] ADD ECX,EAX MOV ESI,R8D LAB_00147ce1: MOV EDI,ECX LAB_00147ce3: MOV dword ptr [RBP + -0x54],EDI MOV dword ptr [RBP + -0x58],ESI MOV RDI,R14 LEA RSI,[RBP + -0x30] MOV RDX,RBX MOV RCX,R13 CALL R12 MOV EDI,dword ptr [RBP + -0x54] MOV ESI,dword ptr [RBP + -0x58] MOV ECX,EDI MOV R8D,ESI TEST EAX,EAX JG 0x00147c7d JMP 0x00147d15 LAB_00147d0e: XOR EDI,EDI MOV RBX,R15 XOR ESI,ESI LAB_00147d15: TEST EAX,EAX JZ 0x00147d7d MOV R8D,ESI MOV ECX,EDI LAB_00147d1e: MOV RAX,qword ptr [RBP + -0x40] TEST RAX,RAX JZ 0x00147d2a MOV qword ptr [RAX],RBX LAB_00147d2a: CMP RBX,R15 JZ 0x00147d6e CMP ECX,0x80000001 MOV EAX,0x1 MOV ESI,R8D CMOVNC ESI,EAX TEST ECX,ECX CMOVS R8D,EAX MOV EDI,dword ptr [RBP + -0x38] TEST EDI,EDI CMOVNZ R8D,ESI TEST R8D,R8D JZ 0x00147d98 TEST EDI,EDI MOV RAX,qword ptr [RBP + -0x50] MOV dword ptr [RAX],0x22 MOV ECX,0x7fffffff MOV RAX,-0x80000000 JMP 0x00147da2 LAB_00147d6e: MOV RAX,qword ptr [RBP + -0x50] MOV dword ptr [RAX],0x21 JMP 0x00147c37 LAB_00147d7d: MOV RAX,qword ptr [RBP + -0x40] TEST RAX,RAX JZ 0x00147d89 MOV qword ptr [RAX],RBX LAB_00147d89: MOV RAX,qword ptr [RBP + -0x50] MOV dword ptr [RAX],0x54 JMP 0x00147c37 LAB_00147d98: MOV ECX,ECX MOV RAX,RCX NEG RAX TEST EDI,EDI LAB_00147da2: CMOVZ RAX,RCX JMP 0x00147c39
ulong my_strntol_mb2_or_mb4 (long param_1,long param_2,long param_3,uint param_4,long *param_5, int4 *param_6) { code *pcVar1; bool bVar2; bool bVar3; bool bVar4; uint uVar5; uint uVar6; ulong uVar7; int4 uVar8; uint uVar9; ulong uVar10; long lVar11; ulong local_38; pcVar1 = *(code **)(*(long *)(param_1 + 0xb8) + 0x28); param_3 = param_3 + param_2; *param_6 = 0; uVar5 = (*pcVar1)(param_1,&local_38,param_2,param_3); if (0 < (int)uVar5) { bVar2 = false; do { if ((long)local_38 < 0x2b) { if ((local_38 != 9) && (local_38 != 0x20)) { LAB_00147c48: uVar5 = (uint)(0xffffffff / (ulong)param_4); uVar6 = (*pcVar1)(param_1,&local_38,param_2,param_3); lVar11 = param_2; if ((int)uVar6 < 1) { uVar9 = 0; bVar3 = false; goto LAB_00147d15; } uVar9 = 0; bVar3 = false; goto LAB_00147c7d; } } else if (local_38 != 0x2b) { if (local_38 != 0x2d) goto LAB_00147c48; bVar2 = !bVar2; } param_2 = param_2 + (ulong)uVar5; uVar5 = (*pcVar1)(param_1,&local_38,param_2,param_3); } while (0 < (int)uVar5); } if (param_5 != (long *)0x0) { *param_5 = param_2; } uVar8 = 0x21; if (uVar5 == 0) { uVar8 = 0x54; } *param_6 = uVar8; return 0; while( true ) { if ((int)param_4 <= (int)uVar7) goto LAB_00147d1e; uVar6 = uVar9; bVar4 = true; if ((uVar9 <= uVar5) && ((uVar9 != uVar5 || (uVar6 = uVar5, bVar4 = true, uVar7 <= 0xffffffffU % (ulong)param_4)))) { uVar6 = uVar9 * param_4 + (int)uVar7; bVar4 = bVar3; } bVar3 = bVar4; uVar9 = uVar6; local_38 = uVar7; uVar6 = (*pcVar1)(param_1,&local_38,lVar11,param_3); if ((int)uVar6 < 1) break; LAB_00147c7d: lVar11 = (ulong)uVar6 + lVar11; uVar7 = local_38 - 0x30; if (9 < uVar7) { if (local_38 - 0x41 < 0x1a) { uVar7 = local_38 - 0x37; } else { if (0x19 < local_38 - 0x61) goto LAB_00147d1e; uVar7 = local_38 - 0x57; } } } LAB_00147d15: if (uVar6 == 0) { if (param_5 != (long *)0x0) { *param_5 = lVar11; } *param_6 = 0x54; } else { LAB_00147d1e: if (param_5 != (long *)0x0) { *param_5 = lVar11; } if (lVar11 != param_2) { bVar4 = bVar3; if (0x80000000 < uVar9) { bVar4 = true; } if ((int)uVar9 < 0) { bVar3 = true; } if (bVar2) { bVar3 = bVar4; } if (bVar3) { *param_6 = 0x22; uVar10 = 0x7fffffff; uVar7 = 0xffffffff80000000; } else { uVar10 = (ulong)uVar9; uVar7 = -uVar10; } if (!bVar2) { return uVar10; } return uVar7; } *param_6 = 0x21; } return 0; }
27,539
nglog::LogMessage::~LogMessage()
ng-log[P]ng-log/src/logging.cc
LogMessage::~LogMessage() noexcept(false) { Flush(); bool fail = data_->severity_ == NGLOG_FATAL && exit_on_dfatal; #ifdef NGLOG_THREAD_LOCAL_STORAGE if (data_ == static_cast<void*>(&thread_msg_data)) { data_->~LogMessageData(); thread_data_available = true; } else { delete allocated_; } #else // !defined(NGLOG_THREAD_LOCAL_STORAGE) delete allocated_; #endif // defined(NGLOG_THREAD_LOCAL_STORAGE) // if (fail) { const char* message = "*** Check failure stack trace: ***\n"; if (write(fileno(stderr), message, strlen(message)) < 0) { // Ignore errors. } AlsoErrorWrite(NGLOG_FATAL, tools::ProgramInvocationShortName(), message); #if defined(__cpp_lib_uncaught_exceptions) && \ (__cpp_lib_uncaught_exceptions >= 201411L) if (std::uncaught_exceptions() == 0) #else if (!std::uncaught_exception()) #endif { Fail(); } } }
O1
cpp
nglog::LogMessage::~LogMessage(): pushq %rbp pushq %r14 pushq %rbx movq %rdi, %r14 callq 0x12320 movq (%r14), %rbx movq 0x8(%r14), %rax cmpl $0x3, 0x7698(%rax) sete %bpl andb 0x25aab(%rip), %bpl # 0x3a9f4 testq %rbx, %rbx je 0x14fa5 movq 0x24eab(%rip), %rax # 0x39e00 leaq 0x18(%rax), %rcx movq %rcx, 0x7538(%rbx) leaq 0x7590(%rbx), %r14 addq $0x40, %rax movq %rax, 0x7590(%rbx) movq 0x24e3f(%rip), %rax # 0x39db8 addq $0x10, %rax movq %rax, 0x7540(%rbx) leaq 0x7578(%rbx), %rdi callq 0x11db0 movq %r14, %rdi callq 0x11260 movl $0x76f0, %esi # imm = 0x76F0 movq %rbx, %rdi callq 0x11960 testb %bpl, %bpl je 0x14fed movq 0x24f47(%rip), %rax # 0x39ef8 movq (%rax), %rdi callq 0x119e0 leaq 0x1855e(%rip), %rbx # 0x2d51e movl $0x23, %edx movl %eax, %edi movq %rbx, %rsi callq 0x11290 callq 0x2b7bf movl $0x3, %edi movq %rax, %rsi movq %rbx, %rdx callq 0x2b7a0 callq 0x11b20 testl %eax, %eax je 0x14ff2 popq %rbx popq %r14 popq %rbp retq callq *0x25a00(%rip) # 0x3a9f8
_ZN5nglog10LogMessageD2Ev: push rbp; Alternative name is 'nglog::LogMessage::~LogMessage()' push r14 push rbx mov r14, rdi call __ZN5nglog10LogMessage5FlushEv; nglog::LogMessage::Flush(void) mov rbx, [r14] mov rax, [r14+8] cmp dword ptr [rax+7698h], 3 setz bpl and bpl, cs:_ZN5nglogL14exit_on_dfatalE; nglog::exit_on_dfatal test rbx, rbx jz short loc_14FA5 mov rax, cs:_ZTVN5nglog10LogMessage9LogStreamE_ptr lea rcx, [rax+18h] mov [rbx+7538h], rcx lea r14, [rbx+7590h] add rax, 40h ; '@' mov [rbx+7590h], rax mov rax, cs:_ZTVSt15basic_streambufIcSt11char_traitsIcEE_ptr add rax, 10h mov [rbx+7540h], rax lea rdi, [rbx+7578h]; this call __ZNSt6localeD1Ev; std::locale::~locale() mov rdi, r14; this call __ZNSt8ios_baseD2Ev; std::ios_base::~ios_base() mov esi, 76F0h; unsigned __int64 mov rdi, rbx; void * call __ZdlPvm; operator delete(void *,ulong) loc_14FA5: test bpl, bpl jz short loc_14FED mov rax, cs:stderr_ptr mov rdi, [rax] call _fileno lea rbx, aCheckFailureSt; "*** Check failure stack trace: ***\n" mov edx, 23h ; '#' mov edi, eax; this mov rsi, rbx call _write call _ZN5nglog5tools26ProgramInvocationShortNameEv; nglog::tools::ProgramInvocationShortName(void) mov edi, 3 mov rsi, rax mov rdx, rbx call _ZN5nglog5tools14AlsoErrorWriteENS_11LogSeverityEPKcS3_; nglog::tools::AlsoErrorWrite(nglog::LogSeverity,char const*,char const*) call __ZSt19uncaught_exceptionsv; std::uncaught_exceptions(void) test eax, eax jz short loc_14FF2 loc_14FED: pop rbx pop r14 pop rbp retn loc_14FF2: call cs:_ZN5nglog19g_logging_fail_funcE; nglog::g_logging_fail_func ...
void nglog::LogMessage::~LogMessage(nglog::LogMessage *this) { _QWORD *v1; // rbx char v2; // bp nglog::tools *v3; // rdi long long v4; // rax nglog::LogMessage::Flush(this); v1 = *(_QWORD **)this; v2 = nglog::exit_on_dfatal & (*(_DWORD *)(*((_QWORD *)this + 1) + 30360LL) == 3); if ( *(_QWORD *)this ) { v1[3751] = (char *)&`vtable for'nglog::LogMessage::LogStream + 24; v1[3762] = (char *)&`vtable for'nglog::LogMessage::LogStream + 64; v1[3752] = (char *)&`vtable for'std::streambuf + 16; std::locale::~locale((std::locale *)(v1 + 3759)); std::ios_base::~ios_base((std::ios_base *)(v1 + 3762)); operator delete(v1, 0x76F0uLL); } if ( v2 ) { v3 = (nglog::tools *)(unsigned int)fileno(stderr); write(v3, "*** Check failure stack trace: ***\n", 35LL); v4 = nglog::tools::ProgramInvocationShortName(v3); nglog::tools::AlsoErrorWrite(3LL, v4, "*** Check failure stack trace: ***\n"); if ( !(unsigned int)std::uncaught_exceptions() ) nglog::g_logging_fail_func(); } }
~LogMessage: PUSH RBP PUSH R14 PUSH RBX MOV R14,RDI CALL 0x00112320 MOV RBX,qword ptr [R14] MOV RAX,qword ptr [R14 + 0x8] CMP dword ptr [RAX + 0x7698],0x3 SETZ BPL AND BPL,byte ptr [0x0013a9f4] TEST RBX,RBX JZ 0x00114fa5 MOV RAX,qword ptr [0x00139e00] LEA RCX,[RAX + 0x18] MOV qword ptr [RBX + 0x7538],RCX LEA R14,[RBX + 0x7590] ADD RAX,0x40 MOV qword ptr [RBX + 0x7590],RAX MOV RAX,qword ptr [0x00139db8] ADD RAX,0x10 MOV qword ptr [RBX + 0x7540],RAX LEA RDI,[RBX + 0x7578] CALL 0x00111db0 MOV RDI,R14 CALL 0x00111260 MOV ESI,0x76f0 MOV RDI,RBX CALL 0x00111960 LAB_00114fa5: TEST BPL,BPL JZ 0x00114fed MOV RAX,qword ptr [0x00139ef8] MOV RDI,qword ptr [RAX] CALL 0x001119e0 LEA RBX,[0x12d51e] MOV EDX,0x23 MOV EDI,EAX MOV RSI,RBX CALL 0x00111290 CALL 0x0012b7bf MOV EDI,0x3 MOV RSI,RAX MOV RDX,RBX CALL 0x0012b7a0 CALL 0x00111b20 TEST EAX,EAX JZ 0x00114ff2 LAB_00114fed: POP RBX POP R14 POP RBP RET LAB_00114ff2: CALL qword ptr [0x0013a9f8]
/* nglog::LogMessage::~LogMessage() */ void __thiscall nglog::LogMessage::~LogMessage(LogMessage *this) { void *pvVar1; int *puVar2; int iVar3; int8 uVar4; byte bVar5; Flush(this); puVar2 = PTR_vtable_00139e00; pvVar1 = *(void **)this; bVar5 = *(int *)(*(long *)(this + 8) + 0x7698) == 3 & exit_on_dfatal; if (pvVar1 != (void *)0x0) { *(int **)((long)pvVar1 + 0x7538) = PTR_vtable_00139e00 + 0x18; *(int **)((long)pvVar1 + 0x7590) = puVar2 + 0x40; *(int **)((long)pvVar1 + 0x7540) = PTR_vtable_00139db8 + 0x10; std::locale::~locale((locale *)((long)pvVar1 + 0x7578)); std::ios_base::~ios_base((ios_base *)((long)pvVar1 + 0x7590)); operator_delete(pvVar1,0x76f0); } if (bVar5 != 0) { iVar3 = fileno(*(FILE **)PTR_stderr_00139ef8); write(iVar3,"*** Check failure stack trace: ***\n",0x23); uVar4 = tools::ProgramInvocationShortName(); tools::AlsoErrorWrite(3,uVar4,"*** Check failure stack trace: ***\n"); iVar3 = std::uncaught_exceptions(); if (iVar3 == 0) { (*(code *)g_logging_fail_func)(); return; } } return; }
27,540
psi_mutex_lock
eloqsql/mysys/my_thr_init.c
ATTRIBUTE_COLD int psi_mutex_lock(mysql_mutex_t *that, const char *file, uint line) { PSI_mutex_locker_state state; PSI_mutex_locker *locker= PSI_MUTEX_CALL(start_mutex_wait) (&state, that->m_psi, PSI_MUTEX_LOCK, file, line); # ifdef SAFE_MUTEX int result= safe_mutex_lock(&that->m_mutex, FALSE, file, line); # else int result= pthread_mutex_lock(&that->m_mutex); # endif if (locker) PSI_MUTEX_CALL(end_mutex_wait)(locker, result); return result; }
O3
c
psi_mutex_lock: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %rbx subq $0x38, %rsp movl %edx, %r8d movq %rsi, %rcx movq %rdi, %r14 leaq 0x357464(%rip), %r15 # 0x386010 movq (%r15), %rax movq 0x40(%rdi), %rsi leaq -0x48(%rbp), %rdi xorl %edx, %edx callq *0x190(%rax) movq %rax, %rbx movq %r14, %rdi callq 0x29220 movl %eax, %r14d testq %rbx, %rbx je 0x2ebe1 movq (%r15), %rax movq %rbx, %rdi movl %r14d, %esi callq *0x198(%rax) movl %r14d, %eax addq $0x38, %rsp popq %rbx popq %r14 popq %r15 popq %rbp retq
psi_mutex_lock: 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+40h] lea rdi, [rbp+var_48] xor edx, edx call qword ptr [rax+190h] mov rbx, rax mov rdi, r14 call _pthread_mutex_lock mov r14d, eax test rbx, rbx jz short loc_2EBE1 mov rax, [r15] mov rdi, rbx mov esi, r14d call qword ptr [rax+198h] loc_2EBE1: mov eax, r14d add rsp, 38h pop rbx pop r14 pop r15 pop rbp retn
long long psi_mutex_lock(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[50])( v6, *(_QWORD *)(a1 + 64), 0LL, a2, a3); v4 = pthread_mutex_lock(a1); if ( v3 ) ((void ( *)(long long, _QWORD))PSI_server[51])(v3, v4); return v4; }
psi_mutex_lock: 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,[0x486010] MOV RAX,qword ptr [R15] MOV RSI,qword ptr [RDI + 0x40] LEA RDI,[RBP + -0x48] XOR EDX,EDX CALL qword ptr [RAX + 0x190] MOV RBX,RAX MOV RDI,R14 CALL 0x00129220 MOV R14D,EAX TEST RBX,RBX JZ 0x0012ebe1 MOV RAX,qword ptr [R15] MOV RDI,RBX MOV ESI,R14D CALL qword ptr [RAX + 0x198] LAB_0012ebe1: MOV EAX,R14D ADD RSP,0x38 POP RBX POP R14 POP R15 POP RBP RET
int psi_mutex_lock(pthread_mutex_t *param_1,int8 param_2,int4 param_3) { int iVar1; long lVar2; int1 local_50 [48]; lVar2 = (**(code **)(PSI_server + 400)) (local_50,*(int8 *)((long)param_1 + 0x40),0,param_2,param_3); iVar1 = pthread_mutex_lock(param_1); if (lVar2 != 0) { (**(code **)(PSI_server + 0x198))(lVar2,iVar1); } return iVar1; }
27,541
parse_prefixed_json_tool_call_array(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, unsigned long)
monkey531[P]llama/common/chat.cpp
static common_chat_msg parse_prefixed_json_tool_call_array(const std::string& input, const std::string & prefix, size_t rstrip_prefix = 0) { auto content_end = input.find(prefix); size_t tc_start = std::string::npos; common_chat_msg result; result.role = "assistant"; const auto process_tool_calls = [&](const json & tool_calls) { for (const auto & tool_call : tool_calls) { const auto & arguments = tool_call["arguments"]; result.tool_calls.push_back({ tool_call["name"], arguments.is_string() ? arguments.get<std::string>() : arguments.dump(), tool_call.contains("id") ? tool_call["id"] : "", }); } }; if (content_end == std::string::npos) { result.content = input; } else { tc_start = content_end + prefix.size() - rstrip_prefix; result.content = input.substr(0, content_end); auto tool_calls = json::parse(input.substr(tc_start)); process_tool_calls(tool_calls); } return result; }
O2
cpp
parse_prefixed_json_tool_call_array(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, unsigned long): pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0xf8, %rsp movq %rcx, %r15 movq %rdx, %r12 movq %rsi, %rbx movq %rdi, %r13 movq %rsi, %rdi movq %rdx, %rsi xorl %edx, %edx callq 0x20d50 movq %rax, %r14 movq %r13, %rdi callq 0x80888 leaq 0x108fe(%rip), %rsi # 0x8ecb5 movq %r13, 0x8(%rsp) movq %r13, %rdi callq 0x20ce0 cmpq $-0x1, %r14 je 0x7e5b9 movq 0x8(%r12), %r12 leaq 0x50(%rsp), %rdi movq %rbx, %rsi xorl %edx, %edx movq %r14, %rcx callq 0x20710 subq %r15, %r14 addq %r12, %r14 movq 0x8(%rsp), %rax leaq 0x20(%rax), %rdi leaq 0x50(%rsp), %r15 movq %r15, %rsi callq 0x20820 movq %r15, %rdi callq 0x20d88 leaq 0x50(%rsp), %rdi pushq $-0x1 popq %rcx movq %rbx, %rsi movq %r14, %rdx callq 0x20710 xorps %xmm0, %xmm0 leaq 0xb0(%rsp), %rdx movaps %xmm0, 0x10(%rdx) movaps %xmm0, (%rdx) leaq 0x10(%rsp), %rdi leaq 0x50(%rsp), %rsi pushq $0x1 popq %rcx xorl %r8d, %r8d callq 0x5f49a leaq 0xb0(%rsp), %rdi callq 0x63a40 leaq 0x50(%rsp), %r15 movq %r15, %rdi callq 0x20d88 leaq 0x20(%rsp), %r12 leaq 0x10(%rsp), %rbx movq %r12, %rdi movq %rbx, %rsi callq 0x4a318 leaq 0xd8(%rsp), %rdi movq %rbx, %rsi callq 0x4a584 movq 0x8(%rsp), %rax leaq 0x40(%rax), %rbx leaq 0x40(%rsp), %rbp movq %r12, %rdi leaq 0xd8(%rsp), %rsi callq 0x49dbc testb %al, %al je 0x7e5a8 movq %r12, %rdi callq 0x49fb6 movq %rax, %r13 movq %rax, %rdi leaq 0x1370b(%rip), %rsi # 0x91bc8 callq 0x5fad4 movq %rax, %r14 movq %r13, %rdi leaq 0x13cac(%rip), %rsi # 0x9217b callq 0x5fad4 movq %r15, %rdi movq %rax, %rsi callq 0x3e6c6 cmpb $0x3, (%r14) jne 0x7e4f4 leaq 0x70(%rsp), %rdi movq %r14, %rsi callq 0x3e6c6 jmp 0x7e50d leaq 0x70(%rsp), %rdi movq %r14, %rsi pushq $-0x1 popq %rdx pushq $0x20 popq %rcx xorl %r8d, %r8d xorl %r9d, %r9d callq 0x2d946 movq %r13, %rdi leaq 0x10c0b(%rip), %rsi # 0x8f122 callq 0x5fab2 testb %al, %al je 0x7e53c movq %r13, %rdi leaq 0x10bf8(%rip), %rsi # 0x8f122 callq 0x5fad4 movq %rbp, %rdi movq %rax, %rsi callq 0x2c946 jmp 0x7e54b movq %rbp, %rdi leaq 0xeed2(%rip), %rsi # 0x8d418 callq 0x6d224 leaq 0x90(%rsp), %rdi movq %rbp, %rsi callq 0x3e6c6 movq %rbx, %rdi movq %r15, %rsi callq 0x8092e movq %r15, %rdi callq 0x6fb76 movq %rbp, %rdi callq 0x46dce movq 0x20(%rsp), %rax movzbl (%rax), %eax cmpl $0x2, %eax je 0x7e593 cmpl $0x1, %eax jne 0x7e59e addq $0x30, 0x28(%rsp) jmp 0x7e490 addq $0x10, 0x30(%rsp) jmp 0x7e490 incq 0x38(%rsp) jmp 0x7e490 leaq 0x10(%rsp), %rdi callq 0x46dce movq 0x8(%rsp), %r14 jmp 0x7e5ca movq 0x8(%rsp), %r14 leaq 0x20(%r14), %rdi movq %rbx, %rsi callq 0x203e0 movq %r14, %rax addq $0xf8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq jmp 0x7e601 movq %rax, %rbx leaq 0xb0(%rsp), %rdi callq 0x63a40 leaq 0x50(%rsp), %rdi callq 0x20d88 jmp 0x7e659 jmp 0x7e601 jmp 0x7e601 movq %rax, %rbx jmp 0x7e659 movq %rax, %rbx leaq 0x50(%rsp), %rdi callq 0x6fb76 xorl %ebp, %ebp jmp 0x7e61d movq %rax, %rbx movb $0x1, %bpl leaq 0x40(%rsp), %rdi callq 0x46dce testb %bpl, %bpl jne 0x7e636 jmp 0x7e64f movq %rax, %rbx jmp 0x7e640 movq %rax, %rbx leaq 0x70(%rsp), %rdi callq 0x20d88 leaq 0x50(%rsp), %rdi callq 0x20d88 jmp 0x7e64f movq %rax, %rbx leaq 0x10(%rsp), %rdi callq 0x46dce movq 0x8(%rsp), %rdi callq 0x2cb16 movq %rbx, %rdi callq 0x20b90
_ZL35parse_prefixed_json_tool_call_arrayRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES6_m: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 0F8h mov r15, rcx mov r12, rdx mov rbx, rsi mov r13, rdi mov rdi, rsi mov rsi, rdx xor edx, edx call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4findERKS4_m; std::string::find(std::string const&,ulong) mov r14, rax mov rdi, r13; this call _ZN15common_chat_msgC2Ev; common_chat_msg::common_chat_msg(void) lea rsi, aYouAreAHelpful+12h; "assistant" mov [rsp+128h+var_120], r13 mov rdi, r13 call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6assignEPKc; std::string::assign(char const*) cmp r14, 0FFFFFFFFFFFFFFFFh jz loc_7E5B9 mov r12, [r12+8] lea rdi, [rsp+128h+var_D8] mov rsi, rbx xor edx, edx mov rcx, r14 call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6substrEmm; std::string::substr(ulong,ulong) sub r14, r15 add r14, r12 mov rax, [rsp+128h+var_120] lea rdi, [rax+20h] lea r15, [rsp+128h+var_D8] mov rsi, r15 call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEaSEOS4_; std::string::operator=(std::string&&) mov rdi, r15; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() lea rdi, [rsp+128h+var_D8] push 0FFFFFFFFFFFFFFFFh pop rcx mov rsi, rbx mov rdx, r14 call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6substrEmm; std::string::substr(ulong,ulong) xorps xmm0, xmm0 lea rdx, [rsp+128h+var_78] movaps xmmword ptr [rdx+10h], xmm0 movaps xmmword ptr [rdx], xmm0 lea rdi, [rsp+128h+var_118] lea rsi, [rsp+128h+var_D8] push 1 pop rcx xor r8d, r8d call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE5parseIS9_EESD_OT_St8functionIFbiNS0_6detail13parse_event_tERSD_EEbb; 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>::parse<std::string>(std::string &&,std::function<bool ()(int,nlohmann::json_abi_v3_11_3::detail::parse_event_t,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>&)>,bool,bool) lea rdi, [rsp+128h+var_78]; this call _ZNSt14_Function_baseD2Ev; std::_Function_base::~_Function_base() lea r15, [rsp+128h+var_D8] mov rdi, r15; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() lea r12, [rsp+128h+var_108] lea rbx, [rsp+128h+var_118] mov rdi, r12 mov rsi, rbx call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE6cbeginEv; 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>::cbegin(void) lea rdi, [rsp+128h+var_50] mov rsi, rbx call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE4cendEv; 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>::cend(void) mov rax, [rsp+128h+var_120] lea rbx, [rax+40h] lea rbp, [rsp+128h+var_E8] loc_7E490: mov rdi, r12 lea rsi, [rsp+128h+var_50] call _ZNK8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEneISH_TnNSt9enable_ifIXoosr3std7is_sameIT_SH_EE5valuesr3std7is_sameISK_NS2_ISF_EEEE5valueEDnE4typeELDn0EEEbRKSK_ test al, al jz loc_7E5A8 mov rdi, r12 call _ZNK8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEdeEv; 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>::operator*(void) mov r13, rax mov rdi, rax lea rsi, aKeywordArgumen+9; "arguments" call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEixIKcEERKSD_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 *) mov r14, rax mov rdi, r13 lea rsi, aNamespacedSetO+2Fh; "name" call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEixIKcEERKSD_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 *) mov rdi, r15 mov rsi, rax 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 cmp byte ptr [r14], 3 jnz short loc_7E4F4 lea rdi, [rsp+128h+var_B8] mov rsi, r14 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 jmp short loc_7E50D loc_7E4F4: lea rdi, [rsp+128h+var_B8] mov rsi, r14 push 0FFFFFFFFFFFFFFFFh pop rdx push 20h ; ' ' pop rcx 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) loc_7E50D: mov rdi, r13 lea rsi, aToolCallId+0Ah; "id" call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE8containsIRA3_KcTnNSt9enable_ifIXsr6detail32is_usable_as_basic_json_key_typeISD_T_EE5valueEiE4typeELi0EEEbOSJ_ test al, al jz short loc_7E53C mov rdi, r13 lea rsi, aToolCallId+0Ah; "id" call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEixIKcEERKSD_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 *) mov rdi, rbp mov rsi, rax 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 short loc_7E54B loc_7E53C: mov rdi, rbp lea rsi, aUsageSOptions+15h; "" call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEC2IRA1_KcA1_cTnNSt9enable_ifIXaantsr6detail13is_basic_jsonIT0_EE5valuesr6detail18is_compatible_typeISD_SK_EE5valueEiE4typeELi0EEEOT_ loc_7E54B: lea rdi, [rsp+128h+var_98] mov rsi, rbp 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, r15 call _ZNSt6vectorI16common_tool_callSaIS0_EE12emplace_backIJS0_EEERS0_DpOT_; std::vector<common_tool_call>::emplace_back<common_tool_call>(common_tool_call &&) mov rdi, r15; this call _ZN16common_tool_callD2Ev; common_tool_call::~common_tool_call() mov rdi, rbp 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 rax, [rsp+128h+var_108] movzx eax, byte ptr [rax] cmp eax, 2 jz short loc_7E593 cmp eax, 1 jnz short loc_7E59E add [rsp+128h+var_100], 30h ; '0' jmp loc_7E490 loc_7E593: add [rsp+128h+var_F8], 10h jmp loc_7E490 loc_7E59E: inc [rsp+128h+var_F0] jmp loc_7E490 loc_7E5A8: lea rdi, [rsp+128h+var_118] call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE4dataD2Ev; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::data::~data() mov r14, [rsp+128h+var_120] jmp short loc_7E5CA loc_7E5B9: mov r14, [rsp+128h+var_120] lea rdi, [r14+20h] mov rsi, rbx call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9_M_assignERKS4_; std::string::_M_assign(std::string const&) loc_7E5CA: mov rax, r14 add rsp, 0F8h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn jmp short loc_7E601 mov rbx, rax lea rdi, [rsp+arg_A8]; this call _ZNSt14_Function_baseD2Ev; std::_Function_base::~_Function_base() lea rdi, [rsp+arg_48]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() jmp short loc_7E659 jmp short loc_7E601 jmp short $+2 loc_7E601: mov rbx, rax jmp short loc_7E659 mov rbx, rax lea rdi, [rsp+arg_48]; this call _ZN16common_tool_callD2Ev; common_tool_call::~common_tool_call() xor ebp, ebp jmp short loc_7E61D mov rbx, rax mov bpl, 1 loc_7E61D: lea rdi, [rsp+arg_38] 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() test bpl, bpl jnz short loc_7E636 jmp short loc_7E64F mov rbx, rax jmp short loc_7E640 mov rbx, rax loc_7E636: lea rdi, [rsp+arg_68]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() loc_7E640: lea rdi, [rsp+arg_48]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() jmp short loc_7E64F mov rbx, rax loc_7E64F: lea rdi, [rsp+arg_8] 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_7E659: mov rdi, [rsp+arg_0]; this call _ZN15common_chat_msgD2Ev; common_chat_msg::~common_chat_msg() mov rdi, rbx call __Unwind_Resume
common_chat_msg * parse_prefixed_json_tool_call_array( common_chat_msg *this, long long a2, long long a3, long long a4) { long long v6; // r14 long long v7; // r12 long long v8; // r13 _BYTE *v9; // r14 long long v10; // rax long long v11; // rax int v12; // eax common_chat_msg *v13; // r14 void *v15[2]; // [rsp+10h] [rbp-118h] BYREF unsigned __int8 *v16; // [rsp+20h] [rbp-108h] BYREF long long v17; // [rsp+28h] [rbp-100h] long long v18; // [rsp+30h] [rbp-F8h] long long v19; // [rsp+38h] [rbp-F0h] void *v20[2]; // [rsp+40h] [rbp-E8h] BYREF long long v21[4]; // [rsp+50h] [rbp-D8h] BYREF _BYTE v22[32]; // [rsp+70h] [rbp-B8h] BYREF _BYTE v23[32]; // [rsp+90h] [rbp-98h] BYREF _BYTE v24[40]; // [rsp+B0h] [rbp-78h] BYREF _BYTE v25[80]; // [rsp+D8h] [rbp-50h] BYREF v6 = std::string::find(a2, a3, 0LL); common_chat_msg::common_chat_msg(this); std::string::assign(this, "assistant"); if ( v6 == -1 ) { v13 = this; std::string::_M_assign((char *)this + 32, a2); } else { v7 = *(_QWORD *)(a3 + 8); std::string::substr(v21, a2, 0LL, v6); std::string::operator=((char *)this + 32, v21); std::string::~string(v21); std::string::substr(v21, a2, v7 + v6 - a4, -1LL); memset(v24, 0, 32); 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>::parse<std::string>( (char *)v15, v21, (long long)v24, 1u, 0); std::_Function_base::~_Function_base((std::_Function_base *)v24); std::string::~string(v21); 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>::cbegin( (long long)&v16, (long long)v15); nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::cend( (long long)v25, (long long)v15); while ( ZNK8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEneISH_TnNSt9enable_ifIXoosr3std7is_sameIT_SH_EE5valuesr3std7is_sameISK_NS2_ISF_EEEE5valueEDnE4typeELDn0EEEbRKSK_((long long)&v16) ) { v8 = 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,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void> const>::operator*(&v16); v9 = (_BYTE *)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>( v8, (long long)"arguments"); v10 = 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>( v8, (long long)"name"); 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)v21, v10); if ( *v9 == 3 ) 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)v22, (long long)v9); else 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)v22, (long long)v9, -1, 32, 0, 0); if ( ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE8containsIRA3_KcTnNSt9enable_ifIXsr6detail32is_usable_as_basic_json_key_typeISD_T_EE5valueEiE4typeELi0EEEbOSJ_(v8) ) { v11 = 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>( v8, (long long)"id"); nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::basic_json( (long long)v20, v11); } else { ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEC2IRA1_KcA1_cTnNSt9enable_ifIXaantsr6detail13is_basic_jsonIT0_EE5valuesr6detail18is_compatible_typeISD_SK_EE5valueEiE4typeELi0EEEOT_((char *)v20); } 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)v23, (long long)v20); std::vector<common_tool_call>::emplace_back<common_tool_call>((char *)this + 64, v21); common_tool_call::~common_tool_call((common_tool_call *)v21); 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(v20); v12 = *v16; if ( v12 == 2 ) { v18 += 16LL; } else if ( v12 == 1 ) { v17 += 48LL; } else { ++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>::data::~data(v15); return this; } return v13; }
parse_prefixed_json_tool_call_array: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0xf8 MOV R15,RCX MOV R12,RDX MOV RBX,RSI MOV R13,RDI MOV RDI,RSI MOV RSI,RDX XOR EDX,EDX CALL 0x00120d50 MOV R14,RAX MOV RDI,R13 CALL 0x00180888 LAB_0017e3b0: LEA RSI,[0x18ecb5] MOV qword ptr [RSP + 0x8],R13 MOV RDI,R13 CALL 0x00120ce0 CMP R14,-0x1 JZ 0x0017e5b9 MOV R12,qword ptr [R12 + 0x8] LAB_0017e3d3: LEA RDI,[RSP + 0x50] MOV RSI,RBX XOR EDX,EDX MOV RCX,R14 CALL 0x00120710 SUB R14,R15 ADD R14,R12 MOV RAX,qword ptr [RSP + 0x8] LEA RDI,[RAX + 0x20] LEA R15,[RSP + 0x50] MOV RSI,R15 CALL 0x00120820 MOV RDI,R15 CALL 0x00120d88 LAB_0017e409: LEA RDI,[RSP + 0x50] PUSH -0x1 POP RCX MOV RSI,RBX MOV RDX,R14 CALL 0x00120710 XORPS XMM0,XMM0 LEA RDX,[RSP + 0xb0] MOVAPS xmmword ptr [RDX + 0x10],XMM0 MOVAPS xmmword ptr [RDX],XMM0 LAB_0017e42e: LEA RDI,[RSP + 0x10] LEA RSI,[RSP + 0x50] PUSH 0x1 POP RCX XOR R8D,R8D CALL 0x0015f49a LEA RDI,[RSP + 0xb0] CALL 0x00163a40 LEA R15,[RSP + 0x50] MOV RDI,R15 CALL 0x00120d88 LEA R12,[RSP + 0x20] LEA RBX,[RSP + 0x10] MOV RDI,R12 MOV RSI,RBX CALL 0x0014a318 LEA RDI,[RSP + 0xd8] MOV RSI,RBX CALL 0x0014a584 MOV RAX,qword ptr [RSP + 0x8] LEA RBX,[RAX + 0x40] LEA RBP,[RSP + 0x40] LAB_0017e490: MOV RDI,R12 LEA RSI,[RSP + 0xd8] CALL 0x00149dbc TEST AL,AL JZ 0x0017e5a8 MOV RDI,R12 CALL 0x00149fb6 MOV R13,RAX MOV RDI,RAX LEA RSI,[0x191bc8] CALL 0x0015fad4 MOV R14,RAX MOV RDI,R13 LEA RSI,[0x19217b] CALL 0x0015fad4 MOV RDI,R15 MOV RSI,RAX CALL 0x0013e6c6 CMP byte ptr [R14],0x3 JNZ 0x0017e4f4 LAB_0017e4e5: LEA RDI,[RSP + 0x70] MOV RSI,R14 CALL 0x0013e6c6 JMP 0x0017e50d LAB_0017e4f4: LEA RDI,[RSP + 0x70] MOV RSI,R14 PUSH -0x1 POP RDX PUSH 0x20 POP RCX XOR R8D,R8D XOR R9D,R9D CALL 0x0012d946 LAB_0017e50d: MOV RDI,R13 LEA RSI,[0x18f122] CALL 0x0015fab2 TEST AL,AL JZ 0x0017e53c MOV RDI,R13 LEA RSI,[0x18f122] CALL 0x0015fad4 MOV RDI,RBP MOV RSI,RAX CALL 0x0012c946 JMP 0x0017e54b LAB_0017e53c: MOV RDI,RBP LEA RSI,[0x18d418] CALL 0x0016d224 LAB_0017e54b: LEA RDI,[RSP + 0x90] MOV RSI,RBP CALL 0x0013e6c6 LAB_0017e55b: MOV RDI,RBX MOV RSI,R15 CALL 0x0018092e MOV RDI,R15 CALL 0x0016fb76 MOV RDI,RBP CALL 0x00146dce MOV RAX,qword ptr [RSP + 0x20] MOVZX EAX,byte ptr [RAX] CMP EAX,0x2 JZ 0x0017e593 CMP EAX,0x1 JNZ 0x0017e59e ADD qword ptr [RSP + 0x28],0x30 JMP 0x0017e490 LAB_0017e593: ADD qword ptr [RSP + 0x30],0x10 JMP 0x0017e490 LAB_0017e59e: INC qword ptr [RSP + 0x38] JMP 0x0017e490 LAB_0017e5a8: LEA RDI,[RSP + 0x10] CALL 0x00146dce MOV R14,qword ptr [RSP + 0x8] JMP 0x0017e5ca LAB_0017e5b9: MOV R14,qword ptr [RSP + 0x8] LEA RDI,[R14 + 0x20] LAB_0017e5c2: MOV RSI,RBX CALL 0x001203e0 LAB_0017e5ca: MOV RAX,R14 ADD RSP,0xf8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
/* parse_prefixed_json_tool_call_array(std::__cxx11::string const&, std::__cxx11::string const&, unsigned long) */ string * parse_prefixed_json_tool_call_array(string *param_1,string *param_2,ulong param_3) { char cVar1; long lVar2; basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> *this; char *pcVar3; basic_json *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> local_118 [16]; char *local_108; long local_100; long local_f8; long local_f0; basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,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 [16]; string local_d8 [32]; int1 local_b8 [32]; int1 local_98 [32]; int8 local_78; int8 uStack_70; int8 local_68; int8 uStack_60; int1 local_50 [32]; lVar2 = std::__cxx11::string::find(param_2,param_3); common_chat_msg::common_chat_msg((common_chat_msg *)param_1); /* try { // try from 0017e3b0 to 0017e3c3 has its CatchHandler @ 0017e601 */ std::__cxx11::string::assign((char *)param_1); if (lVar2 == -1) { /* try { // try from 0017e5c2 to 0017e5c9 has its CatchHandler @ 0017e5df */ std::__cxx11::string::_M_assign(param_1 + 0x20); } else { /* try { // try from 0017e3d3 to 0017e3e4 has its CatchHandler @ 0017e5ff */ std::__cxx11::string::substr((ulong)local_d8,(ulong)param_2); std::__cxx11::string::operator=(param_1 + 0x20,local_d8); std::__cxx11::string::~string(local_d8); /* try { // try from 0017e409 to 0017e41b has its CatchHandler @ 0017e5fd */ std::__cxx11::string::substr((ulong)local_d8,(ulong)param_2); local_68 = 0; uStack_60 = 0; local_78 = 0; uStack_70 = 0; /* try { // try from 0017e42e to 0017e442 has its CatchHandler @ 0017e5e1 */ 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> ::parse<std::__cxx11::string>(local_118,local_d8,&local_78,1,0); std::_Function_base::~_Function_base((_Function_base *)&local_78); std::__cxx11::string::~string(local_d8); 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> ::cbegin(); 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> ::cend(); while( true ) { /* try { // try from 0017e490 to 0017e4de has its CatchHandler @ 0017e64c */ cVar1 = _ZNK8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEneISH_TnNSt9enable_ifIXoosr3std7is_sameIT_SH_EE5valuesr3std7is_sameISK_NS2_ISF_EEEE5valueEDnE4typeELDn0EEEbRKSK_ ((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> *)&local_108,local_50); if (cVar1 == '\0') break; 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> *)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> ::operator*((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> *)&local_108); pcVar3 = 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>(this,"arguments"); pbVar4 = 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>(this,"name"); _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_d8,pbVar4); if (*pcVar3 == '\x03') { /* try { // try from 0017e4e5 to 0017e50c has its CatchHandler @ 0017e62e */ _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_b8,pcVar3); } else { 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_b8,pcVar3,0xffffffffffffffff,0x20,0,0); } /* try { // try from 0017e50d to 0017e54a has its CatchHandler @ 0017e633 */ cVar1 = _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE8containsIRA3_KcTnNSt9enable_ifIXsr6detail32is_usable_as_basic_json_key_typeISD_T_EE5valueEiE4typeELi0EEEbOSJ_ (this,"id"); if (cVar1 == '\0') { _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEC2IRA1_KcA1_cTnNSt9enable_ifIXaantsr6detail13is_basic_jsonIT0_EE5valuesr6detail18is_compatible_typeISD_SK_EE5valueEiE4typeELi0EEEOT_ (local_e8,""); } else { pbVar4 = 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>(this,"id"); 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(local_e8,pbVar4); } /* try { // try from 0017e54b to 0017e55a has its CatchHandler @ 0017e617 */ _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_98,local_e8); /* try { // try from 0017e55b to 0017e565 has its CatchHandler @ 0017e606 */ std::vector<common_tool_call,std::allocator<common_tool_call>>::emplace_back<common_tool_call> ((vector<common_tool_call,std::allocator<common_tool_call>> *)(param_1 + 0x40), (common_tool_call *)local_d8); common_tool_call::~common_tool_call((common_tool_call *)local_d8); 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_e8); if (*local_108 == '\x02') { local_f8 = local_f8 + 0x10; } else if (*local_108 == '\x01') { local_100 = local_100 + 0x30; } else { local_f0 = local_f0 + 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> ::data::~data((data *)local_118); } return param_1; }
27,542
parse_default_charset(Table_map_log_event::Optional_metadata_fields::Default_charset&, unsigned char*, unsigned int)
eloqsql/sql/log_event.cc
static void parse_default_charset(Table_map_log_event::Optional_metadata_fields:: Default_charset &default_charset, unsigned char *field, unsigned int length) { unsigned char* p= field; default_charset.default_charset= net_field_length(&p); while (p < field + length) { unsigned int col_index= net_field_length(&p); unsigned int col_charset= net_field_length(&p); default_charset.charset_pairs.push_back(std::make_pair(col_index, col_charset)); } }
O0
cpp
parse_default_charset(Table_map_log_event::Optional_metadata_fields::Default_charset&, unsigned char*, unsigned int): pushq %rbp movq %rsp, %rbp subq $0x40, %rsp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movl %edx, -0x14(%rbp) movq -0x10(%rbp), %rax movq %rax, -0x20(%rbp) leaq -0x20(%rbp), %rdi callq 0xda17a0 movl %eax, %ecx movq -0x8(%rbp), %rax movl %ecx, (%rax) movq -0x20(%rbp), %rax movq -0x10(%rbp), %rcx movl -0x14(%rbp), %edx addq %rdx, %rcx cmpq %rcx, %rax jae 0xd4e8d3 leaq -0x20(%rbp), %rdi callq 0xda17a0 movl %eax, -0x24(%rbp) leaq -0x20(%rbp), %rdi callq 0xda17a0 movl %eax, -0x28(%rbp) movq -0x8(%rbp), %rax addq $0x8, %rax movq %rax, -0x38(%rbp) leaq -0x24(%rbp), %rdi leaq -0x28(%rbp), %rsi callq 0xd52570 movq -0x38(%rbp), %rdi movq %rax, -0x30(%rbp) leaq -0x30(%rbp), %rsi callq 0xd52540 jmp 0xd4e87c addq $0x40, %rsp popq %rbp retq nopl (%rax)
_ZL21parse_default_charsetRN19Table_map_log_event24Optional_metadata_fields15Default_charsetEPhj: push rbp mov rbp, rsp sub rsp, 40h mov [rbp+var_8], rdi mov [rbp+var_10], rsi mov [rbp+var_14], edx mov rax, [rbp+var_10] mov [rbp+var_20], rax lea rdi, [rbp+var_20] call net_field_length mov ecx, eax mov rax, [rbp+var_8] mov [rax], ecx loc_D4E87C: mov rax, [rbp+var_20] mov rcx, [rbp+var_10] mov edx, [rbp+var_14] add rcx, rdx cmp rax, rcx jnb short loc_D4E8D3 lea rdi, [rbp+var_20] call net_field_length mov [rbp+var_24], eax lea rdi, [rbp+var_20] call net_field_length mov [rbp+var_28], eax mov rax, [rbp+var_8] add rax, 8 mov [rbp+var_38], rax lea rdi, [rbp+var_24] lea rsi, [rbp+var_28] call _ZSt9make_pairIRjS0_ESt4pairINSt25__strip_reference_wrapperINSt5decayIT_E4typeEE6__typeENS2_INS3_IT0_E4typeEE6__typeEEOS4_OS9_; std::make_pair<uint &,uint &>(uint &&&,uint &&&) mov rdi, [rbp+var_38] mov [rbp+var_30], rax lea rsi, [rbp+var_30] call _ZNSt6vectorISt4pairIjjESaIS1_EE9push_backEOS1_; std::vector<std::pair<uint,uint>>::push_back(std::pair<uint,uint>&&) jmp short loc_D4E87C loc_D4E8D3: add rsp, 40h pop rbp retn
unsigned __int8 * parse_default_charset( Table_map_log_event::Optional_metadata_fields::Default_charset *a1, unsigned __int8 *a2, int a3) { int v3; // eax unsigned __int8 *result; // rax char *v5; // [rsp+8h] [rbp-38h] long long v6; // [rsp+10h] [rbp-30h] BYREF int v7; // [rsp+18h] [rbp-28h] BYREF int v8; // [rsp+1Ch] [rbp-24h] BYREF unsigned __int8 *v9; // [rsp+20h] [rbp-20h] BYREF int v10; // [rsp+2Ch] [rbp-14h] unsigned __int8 *v11; // [rsp+30h] [rbp-10h] Table_map_log_event::Optional_metadata_fields::Default_charset *v12; // [rsp+38h] [rbp-8h] v12 = a1; v11 = a2; v10 = a3; v9 = a2; v3 = net_field_length(&v9); *(_DWORD *)v12 = v3; while ( 1 ) { result = v9; if ( v9 >= &v11[v10] ) break; v8 = net_field_length(&v9); v7 = net_field_length(&v9); v5 = (char *)v12 + 8; v6 = std::make_pair<unsigned int &,unsigned int &>(&v8, &v7); std::vector<std::pair<unsigned int,unsigned int>>::push_back(v5, &v6); } return result; }
type_handler: PUSH RBP MOV RBP,RSP MOV qword ptr [RBP + -0x8],RDI LEA RAX,[0x1dfb548] POP RBP RET
/* Item_float::type_handler() const */ int1 * Item_float::type_handler(void) { return type_handler_double; }
27,543
parse_default_charset(Table_map_log_event::Optional_metadata_fields::Default_charset&, unsigned char*, unsigned int)
eloqsql/sql/log_event.cc
static void parse_default_charset(Table_map_log_event::Optional_metadata_fields:: Default_charset &default_charset, unsigned char *field, unsigned int length) { unsigned char* p= field; default_charset.default_charset= net_field_length(&p); while (p < field + length) { unsigned int col_index= net_field_length(&p); unsigned int col_charset= net_field_length(&p); default_charset.charset_pairs.push_back(std::make_pair(col_index, col_charset)); } }
O3
cpp
parse_default_charset(Table_map_log_event::Optional_metadata_fields::Default_charset&, unsigned char*, unsigned int): pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x18, %rsp movl %edx, %r14d movq %rsi, %r15 movq %rdi, %rbx leaq -0x30(%rbp), %r12 movq %rsi, (%r12) movq %r12, %rdi callq 0x9f64dc movl %eax, (%rbx) movl %r14d, %r13d addq %r15, %r13 cmpq %r13, (%r12) jae 0x9c79d0 addq $0x8, %rbx leaq -0x30(%rbp), %r14 leaq -0x38(%rbp), %r15 movq %r14, %rdi callq 0x9f64dc movq %rax, %r12 movq %r14, %rdi callq 0x9f64dc shlq $0x20, %rax movl %r12d, %ecx orq %rax, %rcx movq %rcx, -0x38(%rbp) movq %rbx, %rdi movq %r15, %rsi callq 0x9c864c cmpq %r13, -0x30(%rbp) jb 0x9c799e addq $0x18, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
_ZL21parse_default_charsetRN19Table_map_log_event24Optional_metadata_fields15Default_charsetEPhj: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx sub rsp, 18h mov r14d, edx mov r15, rsi mov rbx, rdi lea r12, [rbp+var_30] mov [r12], rsi mov rdi, r12 call net_field_length mov [rbx], eax mov r13d, r14d add r13, r15 cmp [r12], r13 jnb short loc_9C79D0 add rbx, 8 lea r14, [rbp+var_30] lea r15, [rbp+var_38] loc_9C799E: mov rdi, r14 call net_field_length mov r12, rax mov rdi, r14 call net_field_length shl rax, 20h mov ecx, r12d or rcx, rax mov [rbp+var_38], rcx mov rdi, rbx mov rsi, r15 call _ZNSt6vectorISt4pairIjjESaIS1_EE12emplace_backIJS1_EEERS1_DpOT_; std::vector<std::pair<uint,uint>>::emplace_back<std::pair<uint,uint>>(std::pair<uint,uint> &&) cmp [rbp+var_30], r13 jb short loc_9C799E loc_9C79D0: add rsp, 18h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
long long parse_default_charset(_DWORD *a1, long long a2, unsigned int a3) { long long result; // rax unsigned long long i; // r13 unsigned int v6; // r12d long long v7; // [rsp+8h] [rbp-38h] BYREF _QWORD v8[6]; // [rsp+10h] [rbp-30h] BYREF v8[0] = a2; result = net_field_length(v8); *a1 = result; for ( i = a2 + a3; v8[0] < i; result = std::vector<std::pair<unsigned int,unsigned int>>::emplace_back<std::pair<unsigned int,unsigned int>>( a1 + 2, &v7) ) { v6 = net_field_length(v8); v7 = (net_field_length(v8) << 32) | v6; } return result; }
27,544
init_myisam_psi_keys
eloqsql/storage/myisam/mi_static.c
void init_myisam_psi_keys() { const char* category= "myisam"; int count; count= array_elements(all_myisam_mutexes); mysql_mutex_register(category, all_myisam_mutexes, count); count= array_elements(all_myisam_rwlocks); mysql_rwlock_register(category, all_myisam_rwlocks, count); count= array_elements(all_myisam_conds); mysql_cond_register(category, all_myisam_conds, count); count= array_elements(all_myisam_files); mysql_file_register(category, all_myisam_files, count); count= array_elements(all_myisam_threads); mysql_thread_register(category, all_myisam_threads, count); count= array_elements(all_myisam_memory); mysql_memory_register(category, all_myisam_memory, count); }
O0
c
init_myisam_psi_keys: pushq %rbp movq %rsp, %rbp subq $0x10, %rsp leaq 0xc40f0(%rip), %rax # 0x18570f movq %rax, -0x8(%rbp) movl $0x3, -0xc(%rbp) movq -0x8(%rbp), %rdi movl -0xc(%rbp), %edx leaq 0x233578(%rip), %rsi # 0x2f4bb0 callq 0xc16d0 movl $0x2, -0xc(%rbp) movq -0x8(%rbp), %rdi movl -0xc(%rbp), %edx leaq 0x2335ae(%rip), %rsi # 0x2f4c00 callq 0xc1710 movl $0x1, -0xc(%rbp) movq -0x8(%rbp), %rdi movl -0xc(%rbp), %edx leaq 0x2335c4(%rip), %rsi # 0x2f4c30 callq 0xc1750 movl $0x4, -0xc(%rbp) movq -0x8(%rbp), %rdi movl -0xc(%rbp), %edx leaq 0x2335ca(%rip), %rsi # 0x2f4c50 callq 0xc1790 movl $0x1, -0xc(%rbp) movq -0x8(%rbp), %rdi movl -0xc(%rbp), %edx leaq 0x233610(%rip), %rsi # 0x2f4cb0 callq 0xc17d0 movl $0x15, -0xc(%rbp) movq -0x8(%rbp), %rdi movl -0xc(%rbp), %edx leaq 0x233616(%rip), %rsi # 0x2f4cd0 callq 0xc1810 addq $0x10, %rsp popq %rbp retq nopw %cs:(%rax,%rax)
init_myisam_psi_keys: push rbp mov rbp, rsp sub rsp, 10h lea rax, aThrLockMyisam+9; "myisam" mov [rbp+var_8], rax mov [rbp+var_C], 3 mov rdi, [rbp+var_8] mov edx, [rbp+var_C] lea rsi, all_myisam_mutexes call inline_mysql_mutex_register mov [rbp+var_C], 2 mov rdi, [rbp+var_8] mov edx, [rbp+var_C] lea rsi, all_myisam_rwlocks call inline_mysql_rwlock_register mov [rbp+var_C], 1 mov rdi, [rbp+var_8] mov edx, [rbp+var_C] lea rsi, all_myisam_conds call inline_mysql_cond_register mov [rbp+var_C], 4 mov rdi, [rbp+var_8] mov edx, [rbp+var_C] lea rsi, all_myisam_files call inline_mysql_file_register mov [rbp+var_C], 1 mov rdi, [rbp+var_8] mov edx, [rbp+var_C] lea rsi, all_myisam_threads call inline_mysql_thread_register mov [rbp+var_C], 15h mov rdi, [rbp+var_8] mov edx, [rbp+var_C] lea rsi, all_myisam_memory call inline_mysql_memory_register add rsp, 10h pop rbp retn
long long init_myisam_psi_keys() { inline_mysql_mutex_register("myisam", &all_myisam_mutexes, 3LL); inline_mysql_rwlock_register("myisam", &all_myisam_rwlocks, 2LL); inline_mysql_cond_register("myisam", &all_myisam_conds, 1LL); inline_mysql_file_register("myisam", &all_myisam_files, 4LL); inline_mysql_thread_register("myisam", &all_myisam_threads, 1LL); return inline_mysql_memory_register("myisam", &all_myisam_memory, 21LL); }
init_myisam_psi_keys: PUSH RBP MOV RBP,RSP SUB RSP,0x10 LEA RAX,[0x28570f] MOV qword ptr [RBP + -0x8],RAX MOV dword ptr [RBP + -0xc],0x3 MOV RDI,qword ptr [RBP + -0x8] MOV EDX,dword ptr [RBP + -0xc] LEA RSI,[0x3f4bb0] CALL 0x001c16d0 MOV dword ptr [RBP + -0xc],0x2 MOV RDI,qword ptr [RBP + -0x8] MOV EDX,dword ptr [RBP + -0xc] LEA RSI,[0x3f4c00] CALL 0x001c1710 MOV dword ptr [RBP + -0xc],0x1 MOV RDI,qword ptr [RBP + -0x8] MOV EDX,dword ptr [RBP + -0xc] LEA RSI,[0x3f4c30] CALL 0x001c1750 MOV dword ptr [RBP + -0xc],0x4 MOV RDI,qword ptr [RBP + -0x8] MOV EDX,dword ptr [RBP + -0xc] LEA RSI,[0x3f4c50] CALL 0x001c1790 MOV dword ptr [RBP + -0xc],0x1 MOV RDI,qword ptr [RBP + -0x8] MOV EDX,dword ptr [RBP + -0xc] LEA RSI,[0x3f4cb0] CALL 0x001c17d0 MOV dword ptr [RBP + -0xc],0x15 MOV RDI,qword ptr [RBP + -0x8] MOV EDX,dword ptr [RBP + -0xc] LEA RSI,[0x3f4cd0] CALL 0x001c1810 ADD RSP,0x10 POP RBP RET
void init_myisam_psi_keys(void) { inline_mysql_mutex_register("myisam",all_myisam_mutexes,3); inline_mysql_rwlock_register("myisam",all_myisam_rwlocks,2); inline_mysql_cond_register("myisam",all_myisam_conds,1); inline_mysql_file_register("myisam",all_myisam_files,4); inline_mysql_thread_register("myisam",all_myisam_threads,1); inline_mysql_memory_register("myisam",all_myisam_memory,0x15); return; }
27,545
my_mb_wc_cp932
eloqsql/strings/ctype-cp932.c
static int my_mb_wc_cp932(CHARSET_INFO *cs __attribute__((unused)), my_wc_t *pwc, const uchar *s, const uchar *e){ int hi; if (s >= e) return MY_CS_TOOSMALL; if ((hi= s[0]) < 0x80) /* ASCII: [00-7F] -> [U+0000..U+007F] */ { *pwc= hi; return 1; } /* JIS-X-0201 Half width Katakana: [A1..DF] -> [U+FF61..U+FF9F] */ if (hi >= 0xA1 && hi <= 0xDF) { *pwc= cp932_to_unicode[hi]; return 1; } if (s + 2 > e) return MY_CS_TOOSMALL2; /* JIS-X-0208-MS [81..9F,E0..FC][40..7E,80..FC] */ if (!(pwc[0]= cp932_to_unicode[(hi << 8) + s[1]])) return (iscp932head(hi) && iscp932tail(s[1])) ? -2 : MY_CS_ILSEQ; return 2; }
O0
c
my_mb_wc_cp932: pushq %rbp movq %rsp, %rbp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq %rdx, -0x20(%rbp) movq %rcx, -0x28(%rbp) movq -0x20(%rbp), %rax cmpq -0x28(%rbp), %rax jb 0xdb43a movl $0xffffff9b, -0x4(%rbp) # imm = 0xFFFFFF9B jmp 0xdb598 movq -0x20(%rbp), %rax movzbl (%rax), %eax movl %eax, -0x2c(%rbp) cmpl $0x80, %eax jge 0xdb462 movslq -0x2c(%rbp), %rcx movq -0x18(%rbp), %rax movq %rcx, (%rax) movl $0x1, -0x4(%rbp) jmp 0xdb598 cmpl $0xa1, -0x2c(%rbp) jl 0xdb498 cmpl $0xdf, -0x2c(%rbp) jg 0xdb498 movslq -0x2c(%rbp), %rcx leaq 0x63da1(%rip), %rax # 0x13f220 movzwl (%rax,%rcx,2), %eax movl %eax, %ecx movq -0x18(%rbp), %rax movq %rcx, (%rax) movl $0x1, -0x4(%rbp) jmp 0xdb598 movq -0x20(%rbp), %rax addq $0x2, %rax cmpq -0x28(%rbp), %rax jbe 0xdb4b2 movl $0xffffff9a, -0x4(%rbp) # imm = 0xFFFFFF9A jmp 0xdb598 movl -0x2c(%rbp), %eax shll $0x8, %eax movq -0x20(%rbp), %rcx movzbl 0x1(%rcx), %ecx addl %ecx, %eax movslq %eax, %rcx leaq 0x63d54(%rip), %rax # 0x13f220 movzwl (%rax,%rcx,2), %eax movq -0x18(%rbp), %rcx movq %rax, (%rcx) cmpq $0x0, %rax jne 0xdb591 movl -0x2c(%rbp), %eax movzbl %al, %ecx movl $0x81, %eax cmpl %ecx, %eax jg 0xdb4fd movl -0x2c(%rbp), %eax movzbl %al, %eax cmpl $0x9f, %eax jle 0xdb524 movl -0x2c(%rbp), %eax movzbl %al, %edx xorl %eax, %eax movl $0xe0, %ecx cmpl %edx, %ecx movb %al, -0x2d(%rbp) jg 0xdb57c movl -0x2c(%rbp), %eax movzbl %al, %ecx xorl %eax, %eax cmpl $0xfc, %ecx movb %al, -0x2d(%rbp) jg 0xdb57c movq -0x20(%rbp), %rax movzbl 0x1(%rax), %ecx movl $0x40, %eax cmpl %ecx, %eax jg 0xdb547 movq -0x20(%rbp), %rax movzbl 0x1(%rax), %ecx movb $0x1, %al cmpl $0x7e, %ecx movb %al, -0x2e(%rbp) jle 0xdb576 movq -0x20(%rbp), %rax movzbl 0x1(%rax), %edx xorl %eax, %eax movl $0x80, %ecx cmpl %edx, %ecx movb %al, -0x2f(%rbp) jg 0xdb570 movq -0x20(%rbp), %rax movzbl 0x1(%rax), %eax cmpl $0xfc, %eax setle %al movb %al, -0x2f(%rbp) movb -0x2f(%rbp), %al movb %al, -0x2e(%rbp) movb -0x2e(%rbp), %al movb %al, -0x2d(%rbp) movb -0x2d(%rbp), %dl xorl %eax, %eax movl $0xfffffffe, %ecx # imm = 0xFFFFFFFE testb $0x1, %dl cmovnel %ecx, %eax movl %eax, -0x4(%rbp) jmp 0xdb598 movl $0x2, -0x4(%rbp) movl -0x4(%rbp), %eax popq %rbp retq nopl (%rax)
my_mb_wc_cp932: push rbp mov rbp, rsp mov [rbp+var_10], rdi mov [rbp+var_18], rsi mov [rbp+var_20], rdx mov [rbp+var_28], rcx mov rax, [rbp+var_20] cmp rax, [rbp+var_28] jb short loc_DB43A mov [rbp+var_4], 0FFFFFF9Bh jmp loc_DB598 loc_DB43A: mov rax, [rbp+var_20] movzx eax, byte ptr [rax] mov [rbp+var_2C], eax cmp eax, 80h jge short loc_DB462 movsxd rcx, [rbp+var_2C] mov rax, [rbp+var_18] mov [rax], rcx mov [rbp+var_4], 1 jmp loc_DB598 loc_DB462: cmp [rbp+var_2C], 0A1h jl short loc_DB498 cmp [rbp+var_2C], 0DFh jg short loc_DB498 movsxd rcx, [rbp+var_2C] lea rax, cp932_to_unicode movzx eax, word ptr [rax+rcx*2] mov ecx, eax mov rax, [rbp+var_18] mov [rax], rcx mov [rbp+var_4], 1 jmp loc_DB598 loc_DB498: mov rax, [rbp+var_20] add rax, 2 cmp rax, [rbp+var_28] jbe short loc_DB4B2 mov [rbp+var_4], 0FFFFFF9Ah jmp loc_DB598 loc_DB4B2: mov eax, [rbp+var_2C] shl eax, 8 mov rcx, [rbp+var_20] movzx ecx, byte ptr [rcx+1] add eax, ecx movsxd rcx, eax lea rax, cp932_to_unicode movzx eax, word ptr [rax+rcx*2] mov rcx, [rbp+var_18] mov [rcx], rax cmp rax, 0 jnz loc_DB591 mov eax, [rbp+var_2C] movzx ecx, al mov eax, 81h cmp eax, ecx jg short loc_DB4FD mov eax, [rbp+var_2C] movzx eax, al cmp eax, 9Fh jle short loc_DB524 loc_DB4FD: mov eax, [rbp+var_2C] movzx edx, al xor eax, eax mov ecx, 0E0h cmp ecx, edx mov [rbp+var_2D], al jg short loc_DB57C mov eax, [rbp+var_2C] movzx ecx, al xor eax, eax cmp ecx, 0FCh mov [rbp+var_2D], al jg short loc_DB57C loc_DB524: mov rax, [rbp+var_20] movzx ecx, byte ptr [rax+1] mov eax, 40h ; '@' cmp eax, ecx jg short loc_DB547 mov rax, [rbp+var_20] movzx ecx, byte ptr [rax+1] mov al, 1 cmp ecx, 7Eh ; '~' mov [rbp+var_2E], al jle short loc_DB576 loc_DB547: mov rax, [rbp+var_20] movzx edx, byte ptr [rax+1] xor eax, eax mov ecx, 80h cmp ecx, edx mov [rbp+var_2F], al jg short loc_DB570 mov rax, [rbp+var_20] movzx eax, byte ptr [rax+1] cmp eax, 0FCh setle al mov [rbp+var_2F], al loc_DB570: mov al, [rbp+var_2F] mov [rbp+var_2E], al loc_DB576: mov al, [rbp+var_2E] mov [rbp+var_2D], al loc_DB57C: mov dl, [rbp+var_2D] xor eax, eax mov ecx, 0FFFFFFFEh test dl, 1 cmovnz eax, ecx mov [rbp+var_4], eax jmp short loc_DB598 loc_DB591: mov [rbp+var_4], 2 loc_DB598: mov eax, [rbp+var_4] pop rbp retn
long long my_mb_wc_cp932(long long a1, _QWORD *a2, unsigned __int8 *a3, unsigned long long a4) { long long v4; // rax unsigned int v5; // eax bool v7; // [rsp+1h] [rbp-2Fh] char v8; // [rsp+2h] [rbp-2Eh] char v9; // [rsp+3h] [rbp-2Dh] unsigned int v10; // [rsp+4h] [rbp-2Ch] if ( (unsigned long long)a3 < a4 ) { v10 = *a3; if ( v10 >= 0x80 ) { if ( *a3 < 0xA1u || *a3 > 0xDFu ) { if ( (unsigned long long)(a3 + 2) <= a4 ) { v4 = cp932_to_unicode[a3[1] + (v10 << 8)]; *a2 = v4; if ( v4 ) { return 2; } else { if ( (unsigned __int8)v10 >= 0x81u && (unsigned __int8)v10 <= 0x9Fu || (v9 = 0, (unsigned __int8)v10 >= 0xE0u) && (v9 = 0, (unsigned __int8)v10 <= 0xFCu) ) { if ( a3[1] < 0x40u || (v8 = 1, a3[1] > 0x7Eu) ) { v7 = 0; if ( a3[1] >= 0x80u ) v7 = a3[1] <= 0xFCu; v8 = v7; } v9 = v8; } v5 = 0; if ( (v9 & 1) != 0 ) return (unsigned int)-2; return v5; } } else { return (unsigned int)-102; } } else { *a2 = cp932_to_unicode[*a3]; return 1; } } else { *a2 = *a3; return 1; } } else { return (unsigned int)-101; } }
my_mb_wc_cp932: PUSH RBP MOV RBP,RSP MOV qword ptr [RBP + -0x10],RDI MOV qword ptr [RBP + -0x18],RSI MOV qword ptr [RBP + -0x20],RDX MOV qword ptr [RBP + -0x28],RCX MOV RAX,qword ptr [RBP + -0x20] CMP RAX,qword ptr [RBP + -0x28] JC 0x001db43a MOV dword ptr [RBP + -0x4],0xffffff9b JMP 0x001db598 LAB_001db43a: MOV RAX,qword ptr [RBP + -0x20] MOVZX EAX,byte ptr [RAX] MOV dword ptr [RBP + -0x2c],EAX CMP EAX,0x80 JGE 0x001db462 MOVSXD RCX,dword ptr [RBP + -0x2c] MOV RAX,qword ptr [RBP + -0x18] MOV qword ptr [RAX],RCX MOV dword ptr [RBP + -0x4],0x1 JMP 0x001db598 LAB_001db462: CMP dword ptr [RBP + -0x2c],0xa1 JL 0x001db498 CMP dword ptr [RBP + -0x2c],0xdf JG 0x001db498 MOVSXD RCX,dword ptr [RBP + -0x2c] LEA RAX,[0x23f220] MOVZX EAX,word ptr [RAX + RCX*0x2] MOV ECX,EAX MOV RAX,qword ptr [RBP + -0x18] MOV qword ptr [RAX],RCX MOV dword ptr [RBP + -0x4],0x1 JMP 0x001db598 LAB_001db498: MOV RAX,qword ptr [RBP + -0x20] ADD RAX,0x2 CMP RAX,qword ptr [RBP + -0x28] JBE 0x001db4b2 MOV dword ptr [RBP + -0x4],0xffffff9a JMP 0x001db598 LAB_001db4b2: MOV EAX,dword ptr [RBP + -0x2c] SHL EAX,0x8 MOV RCX,qword ptr [RBP + -0x20] MOVZX ECX,byte ptr [RCX + 0x1] ADD EAX,ECX MOVSXD RCX,EAX LEA RAX,[0x23f220] MOVZX EAX,word ptr [RAX + RCX*0x2] MOV RCX,qword ptr [RBP + -0x18] MOV qword ptr [RCX],RAX CMP RAX,0x0 JNZ 0x001db591 MOV EAX,dword ptr [RBP + -0x2c] MOVZX ECX,AL MOV EAX,0x81 CMP EAX,ECX JG 0x001db4fd MOV EAX,dword ptr [RBP + -0x2c] MOVZX EAX,AL CMP EAX,0x9f JLE 0x001db524 LAB_001db4fd: MOV EAX,dword ptr [RBP + -0x2c] MOVZX EDX,AL XOR EAX,EAX MOV ECX,0xe0 CMP ECX,EDX MOV byte ptr [RBP + -0x2d],AL JG 0x001db57c MOV EAX,dword ptr [RBP + -0x2c] MOVZX ECX,AL XOR EAX,EAX CMP ECX,0xfc MOV byte ptr [RBP + -0x2d],AL JG 0x001db57c LAB_001db524: MOV RAX,qword ptr [RBP + -0x20] MOVZX ECX,byte ptr [RAX + 0x1] MOV EAX,0x40 CMP EAX,ECX JG 0x001db547 MOV RAX,qword ptr [RBP + -0x20] MOVZX ECX,byte ptr [RAX + 0x1] MOV AL,0x1 CMP ECX,0x7e MOV byte ptr [RBP + -0x2e],AL JLE 0x001db576 LAB_001db547: MOV RAX,qword ptr [RBP + -0x20] MOVZX EDX,byte ptr [RAX + 0x1] XOR EAX,EAX MOV ECX,0x80 CMP ECX,EDX MOV byte ptr [RBP + -0x2f],AL JG 0x001db570 MOV RAX,qword ptr [RBP + -0x20] MOVZX EAX,byte ptr [RAX + 0x1] CMP EAX,0xfc SETLE AL MOV byte ptr [RBP + -0x2f],AL LAB_001db570: MOV AL,byte ptr [RBP + -0x2f] MOV byte ptr [RBP + -0x2e],AL LAB_001db576: MOV AL,byte ptr [RBP + -0x2e] MOV byte ptr [RBP + -0x2d],AL LAB_001db57c: MOV DL,byte ptr [RBP + -0x2d] XOR EAX,EAX MOV ECX,0xfffffffe TEST DL,0x1 CMOVNZ EAX,ECX MOV dword ptr [RBP + -0x4],EAX JMP 0x001db598 LAB_001db591: MOV dword ptr [RBP + -0x4],0x2 LAB_001db598: MOV EAX,dword ptr [RBP + -0x4] POP RBP RET
int4 my_mb_wc_cp932(int8 param_1,ulong *param_2,byte *param_3,byte *param_4) { ushort uVar1; bool bVar2; uint uVar3; int4 local_c; if (param_3 < param_4) { uVar3 = (uint)*param_3; if (uVar3 < 0x80) { *param_2 = (long)(int)uVar3; local_c = 1; } else if ((uVar3 < 0xa1) || (0xdf < uVar3)) { if (param_4 < param_3 + 2) { local_c = 0xffffff9a; } else { uVar1 = *(ushort *)(cp932_to_unicode + (long)(int)(uVar3 * 0x100 + (uint)param_3[1]) * 2); *param_2 = (ulong)uVar1; if ((ulong)uVar1 == 0) { if ((((0x80 < uVar3) && (uVar3 < 0xa0)) || ((bVar2 = false, 0xdf < uVar3 && (bVar2 = false, uVar3 < 0xfd)))) && (((param_3[1] < 0x40 || (bVar2 = true, 0x7e < param_3[1])) && (bVar2 = false, 0x7f < param_3[1])))) { bVar2 = param_3[1] < 0xfd; } local_c = 0; if (bVar2) { local_c = 0xfffffffe; } } else { local_c = 2; } } } else { *param_2 = (ulong)*(ushort *)(cp932_to_unicode + (long)(int)uVar3 * 2); local_c = 1; } } else { local_c = 0xffffff9b; } return local_c; }
27,546
BeginMode3D
csit-sgu[P]mit-game-2025_1/Libraries/raylib/src/rcore.c
void BeginMode3D(Camera camera) { rlDrawRenderBatchActive(); // Update and draw internal render batch rlMatrixMode(RL_PROJECTION); // Switch to projection matrix rlPushMatrix(); // Save previous matrix, which contains the settings for the 2d ortho projection rlLoadIdentity(); // Reset current matrix (projection) float aspect = (float)CORE.Window.currentFbo.width/(float)CORE.Window.currentFbo.height; // NOTE: zNear and zFar values are important when computing depth buffer values if (camera.projection == CAMERA_PERSPECTIVE) { // Setup perspective projection double top = rlGetCullDistanceNear()*tan(camera.fovy*0.5*DEG2RAD); double right = top*aspect; rlFrustum(-right, right, -top, top, rlGetCullDistanceNear(), rlGetCullDistanceFar()); } else if (camera.projection == CAMERA_ORTHOGRAPHIC) { // Setup orthographic projection double top = camera.fovy/2.0; double right = top*aspect; rlOrtho(-right, right, -top,top, rlGetCullDistanceNear(), rlGetCullDistanceFar()); } rlMatrixMode(RL_MODELVIEW); // Switch back to modelview matrix rlLoadIdentity(); // Reset current matrix (modelview) // Setup Camera view Matrix matView = MatrixLookAt(camera.position, camera.target, camera.up); rlMultMatrixf(MatrixToFloat(matView)); // Multiply modelview matrix by view matrix (camera) rlEnableDepthTest(); // Enable DEPTH_TEST for 3D }
O1
c
BeginMode3D: pushq %rbx subq $0xd0, %rsp leaq 0xe0(%rsp), %rbx movq 0xc9e61(%rip), %rdi # 0x141108 callq 0x6246c leaq 0xc9ee5(%rip), %rax # 0x141198 movq %rax, 0xc9e96(%rip) # 0x141150 movl $0x1701, 0xc9e88(%rip) # imm = 0x1701 callq 0x61151 movq 0xc9e80(%rip), %rax # 0x141150 movl $0x3f800000, %ecx # imm = 0x3F800000 movl %ecx, (%rax) xorps %xmm0, %xmm0 movups %xmm0, 0x4(%rax) movl %ecx, 0x14(%rax) movups %xmm0, 0x18(%rax) movl %ecx, 0x28(%rax) movups %xmm0, 0x2c(%rax) movl %ecx, 0x3c(%rax) movl 0xca8f7(%rip), %eax # 0x141bec cvtsi2ss %rax, %xmm1 movl 0xca8f0(%rip), %eax # 0x141bf0 xorps %xmm0, %xmm0 cvtsi2ss %rax, %xmm0 divss %xmm0, %xmm1 movl 0x28(%rbx), %eax cmpl $0x1, %eax je 0x7738e testl %eax, %eax jne 0x773cc movsd 0xc549c(%rip), %xmm0 # 0x13c7c0 movaps %xmm0, 0x50(%rsp) xorps %xmm0, %xmm0 cvtss2sd 0x24(%rbx), %xmm0 mulsd 0x627af(%rip), %xmm0 # 0xd9ae8 mulsd 0x6d4f7(%rip), %xmm0 # 0xe4838 movss %xmm1, 0x40(%rsp) callq 0x92f0 movapd 0x50(%rsp), %xmm3 mulsd %xmm0, %xmm3 xorps %xmm1, %xmm1 cvtss2sd 0x40(%rsp), %xmm1 mulsd %xmm3, %xmm1 movapd 0x62865(%rip), %xmm2 # 0xd9bd0 movapd %xmm1, %xmm0 xorpd %xmm2, %xmm0 xorpd %xmm3, %xmm2 movsd 0xc5441(%rip), %xmm4 # 0x13c7c0 movsd 0xc5441(%rip), %xmm5 # 0x13c7c8 callq 0x61ead jmp 0x773cc cvtss2sd 0x24(%rbx), %xmm3 mulsd 0x6274d(%rip), %xmm3 # 0xd9ae8 cvtss2sd %xmm1, %xmm1 mulsd %xmm3, %xmm1 movapd 0x62825(%rip), %xmm2 # 0xd9bd0 movapd %xmm1, %xmm0 xorpd %xmm2, %xmm0 xorpd %xmm3, %xmm2 movsd 0xc5401(%rip), %xmm4 # 0x13c7c0 movsd 0xc5401(%rip), %xmm5 # 0x13c7c8 callq 0x620ae leaq 0xc9d85(%rip), %rax # 0x141158 movq %rax, 0xc9d76(%rip) # 0x141150 movl $0x1700, 0xc9d68(%rip) # imm = 0x1700 movl $0x3f800000, %eax # imm = 0x3F800000 movl %eax, 0xc9d69(%rip) # 0x141158 xorps %xmm0, %xmm0 movups %xmm0, 0xc9d63(%rip) # 0x14115c movl %eax, 0xc9d6d(%rip) # 0x14116c movups %xmm0, 0xc9d6a(%rip) # 0x141170 movl %eax, 0xc9d74(%rip) # 0x141180 movups %xmm0, 0xc9d71(%rip) # 0x141184 movl %eax, 0xc9d7b(%rip) # 0x141194 movsd (%rbx), %xmm2 movss 0x8(%rbx), %xmm1 movsd 0xc(%rbx), %xmm0 movsd 0x18(%rbx), %xmm3 movss 0x20(%rbx), %xmm6 movaps %xmm2, %xmm8 subps %xmm0, %xmm8 movaps %xmm2, 0x40(%rsp) shufps $0x55, %xmm2, %xmm2 # xmm2 = xmm2[1,1,1,1] movaps %xmm2, 0x80(%rsp) movaps %xmm8, %xmm11 movaps %xmm1, 0x50(%rsp) movaps %xmm1, %xmm10 subss 0x14(%rbx), %xmm10 shufps $0x55, %xmm8, %xmm11 # xmm11 = xmm11[1,1],xmm8[1,1] movaps %xmm11, %xmm0 mulss %xmm11, %xmm0 movaps %xmm8, %xmm1 mulss %xmm8, %xmm1 addss %xmm0, %xmm1 movaps %xmm10, %xmm0 mulss %xmm10, %xmm0 addss %xmm1, %xmm0 xorps %xmm7, %xmm7 ucomiss %xmm7, %xmm0 jb 0x77493 sqrtss %xmm0, %xmm0 jmp 0x774d7 movaps %xmm8, 0x30(%rsp) movss %xmm10, 0xc(%rsp) movaps %xmm11, 0x20(%rsp) movss %xmm6, 0x8(%rsp) movaps %xmm3, 0x10(%rsp) callq 0x99f0 xorps %xmm7, %xmm7 movaps 0x10(%rsp), %xmm3 movss 0x8(%rsp), %xmm6 movaps 0x20(%rsp), %xmm11 movss 0xc(%rsp), %xmm10 movaps 0x30(%rsp), %xmm8 movss 0x62465(%rip), %xmm5 # 0xd9944 movaps %xmm5, %xmm1 divss %xmm0, %xmm1 cmpeqss %xmm7, %xmm0 movaps %xmm0, %xmm2 andnps %xmm1, %xmm2 andps %xmm5, %xmm0 orps %xmm2, %xmm0 mulss %xmm0, %xmm8 mulss %xmm0, %xmm11 mulss %xmm0, %xmm10 movaps %xmm3, %xmm12 shufps $0x55, %xmm3, %xmm12 # xmm12 = xmm12[1,1],xmm3[1,1] movaps 0x626aa(%rip), %xmm4 # 0xd9bc0 xorps %xmm11, %xmm4 movaps %xmm6, %xmm0 mulss %xmm11, %xmm0 movaps %xmm8, %xmm1 mulss %xmm12, %xmm1 mulss %xmm10, %xmm12 subss %xmm0, %xmm12 movaps %xmm10, %xmm0 mulss %xmm3, %xmm0 mulss %xmm8, %xmm6 subss %xmm0, %xmm6 mulss %xmm11, %xmm3 subss %xmm1, %xmm3 movaps %xmm6, %xmm0 mulss %xmm6, %xmm0 movaps %xmm12, %xmm1 mulss %xmm12, %xmm1 addss %xmm0, %xmm1 movaps %xmm3, %xmm0 mulss %xmm3, %xmm0 addss %xmm1, %xmm0 ucomiss %xmm7, %xmm0 jb 0x77579 sqrtss %xmm0, %xmm0 jmp 0x775d8 movaps %xmm8, 0x30(%rsp) movss %xmm10, 0xc(%rsp) movaps %xmm11, 0x20(%rsp) movss %xmm6, 0x8(%rsp) movaps %xmm12, 0x70(%rsp) movaps %xmm3, 0x10(%rsp) movaps %xmm4, 0x60(%rsp) callq 0x99f0 movss 0x62395(%rip), %xmm5 # 0xd9944 movaps 0x60(%rsp), %xmm4 movaps 0x10(%rsp), %xmm3 movaps 0x70(%rsp), %xmm12 movss 0x8(%rsp), %xmm6 movaps 0x20(%rsp), %xmm11 movss 0xc(%rsp), %xmm10 movaps 0x30(%rsp), %xmm8 movaps %xmm5, %xmm2 divss %xmm0, %xmm2 xorps %xmm1, %xmm1 cmpeqss %xmm0, %xmm1 movaps %xmm1, %xmm0 andnps %xmm2, %xmm0 andps %xmm5, %xmm1 orps %xmm0, %xmm1 mulss %xmm1, %xmm12 mulss %xmm1, %xmm6 mulss %xmm3, %xmm1 movaps %xmm6, %xmm2 mulss %xmm10, %xmm2 movaps %xmm11, %xmm0 mulss %xmm1, %xmm0 subss %xmm2, %xmm0 movaps %xmm1, %xmm3 mulss %xmm8, %xmm3 movaps %xmm10, %xmm2 mulss %xmm12, %xmm2 subss %xmm3, %xmm2 mulss %xmm12, %xmm4 movaps %xmm8, %xmm3 mulss %xmm6, %xmm3 addss %xmm4, %xmm3 movaps 0x80(%rsp), %xmm9 movaps %xmm9, %xmm5 mulss %xmm6, %xmm5 movaps %xmm12, %xmm4 movaps 0x40(%rsp), %xmm7 mulss %xmm7, %xmm4 addss %xmm5, %xmm4 xorps %xmm5, %xmm5 leaq 0x90(%rsp), %rdi movaps %xmm5, (%rdi) movaps %xmm5, 0x10(%rdi) movaps %xmm5, 0x20(%rdi) movaps %xmm5, 0x30(%rdi) movss %xmm12, (%rdi) movss %xmm0, 0x4(%rdi) movss %xmm8, 0x8(%rdi) xorl %eax, %eax movl %eax, 0xc(%rdi) movss %xmm6, 0x10(%rdi) movss %xmm2, 0x14(%rdi) movss %xmm11, 0x18(%rdi) movl %eax, 0x1c(%rdi) movss %xmm1, 0x20(%rdi) movaps 0x50(%rsp), %xmm6 mulss %xmm6, %xmm1 addss %xmm4, %xmm1 movaps 0x62509(%rip), %xmm4 # 0xd9bc0 xorps %xmm4, %xmm1 movaps %xmm9, %xmm5 mulss %xmm2, %xmm5 mulss %xmm7, %xmm0 addss %xmm5, %xmm0 movss %xmm3, 0x24(%rdi) mulss %xmm6, %xmm3 addss %xmm0, %xmm3 xorps %xmm4, %xmm3 mulss %xmm11, %xmm9 mulss %xmm8, %xmm7 addss %xmm9, %xmm7 mulss %xmm10, %xmm6 addss %xmm7, %xmm6 xorps %xmm4, %xmm6 movss %xmm10, 0x28(%rdi) movl %eax, 0x2c(%rdi) movss %xmm1, 0x30(%rdi) movss %xmm3, 0x34(%rdi) movss %xmm6, 0x38(%rdi) movl $0x3f800000, 0x3c(%rdi) # imm = 0x3F800000 callq 0x61ce6 movl $0xb71, %edi # imm = 0xB71 addq $0xd0, %rsp popq %rbx jmpq *0xc80f4(%rip) # 0x13f820
BeginMode3D: push rbx sub rsp, 0D0h lea rbx, [rsp+0D8h+arg_0] mov rdi, cs:RLGL call rlDrawRenderBatch lea rax, xmmword_141198 mov cs:qword_141150, rax mov cs:dword_14114C, 1701h call rlPushMatrix mov rax, cs:qword_141150 mov ecx, 3F800000h mov [rax], ecx xorps xmm0, xmm0 movups xmmword ptr [rax+4], xmm0 mov [rax+14h], ecx movups xmmword ptr [rax+18h], xmm0 mov [rax+28h], ecx movups xmmword ptr [rax+2Ch], xmm0 mov [rax+3Ch], ecx mov eax, cs:dword_141BEC cvtsi2ss xmm1, rax mov eax, cs:dword_141BF0 xorps xmm0, xmm0 cvtsi2ss xmm0, rax divss xmm1, xmm0 mov eax, [rbx+28h] cmp eax, 1 jz short loc_7738E test eax, eax jnz loc_773CC movsd xmm0, cs:rlCullDistanceNear movaps [rsp+0D8h+var_88], xmm0 xorps xmm0, xmm0 cvtss2sd xmm0, dword ptr [rbx+24h] mulsd xmm0, cs:qword_D9AE8 mulsd xmm0, cs:qword_E4838 movss dword ptr [rsp+0D8h+var_98], xmm1 call _tan movapd xmm3, [rsp+0D8h+var_88] mulsd xmm3, xmm0 xorps xmm1, xmm1 cvtss2sd xmm1, dword ptr [rsp+0D8h+var_98] mulsd xmm1, xmm3 movapd xmm2, cs:xmmword_D9BD0 movapd xmm0, xmm1 xorpd xmm0, xmm2 xorpd xmm2, xmm3 movsd xmm4, cs:rlCullDistanceNear movsd xmm5, cs:rlCullDistanceFar call rlFrustum jmp short loc_773CC loc_7738E: cvtss2sd xmm3, dword ptr [rbx+24h] mulsd xmm3, cs:qword_D9AE8 cvtss2sd xmm1, xmm1 mulsd xmm1, xmm3 movapd xmm2, cs:xmmword_D9BD0 movapd xmm0, xmm1 xorpd xmm0, xmm2 xorpd xmm2, xmm3 movsd xmm4, cs:rlCullDistanceNear movsd xmm5, cs:rlCullDistanceFar call rlOrtho loc_773CC: lea rax, xmmword_141158 mov cs:qword_141150, rax mov cs:dword_14114C, 1700h mov eax, 3F800000h mov dword ptr cs:xmmword_141158, eax xorps xmm0, xmm0 movups cs:xmmword_141158+4, xmm0 mov dword ptr cs:xmmword_141168+4, eax movups cs:xmmword_141168+8, xmm0 mov dword ptr cs:xmmword_141178+8, eax movups cs:xmmword_141178+0Ch, xmm0 mov dword ptr cs:xmmword_141188+0Ch, eax movsd xmm2, qword ptr [rbx] movss xmm1, dword ptr [rbx+8] movsd xmm0, qword ptr [rbx+0Ch] movsd xmm3, qword ptr [rbx+18h] movss xmm6, dword ptr [rbx+20h] movaps xmm8, xmm2 subps xmm8, xmm0 movaps [rsp+0D8h+var_98], xmm2 shufps xmm2, xmm2, 55h ; 'U' movaps [rsp+0D8h+var_58], xmm2 movaps xmm11, xmm8 movaps [rsp+0D8h+var_88], xmm1 movaps xmm10, xmm1 subss xmm10, dword ptr [rbx+14h] shufps xmm11, xmm8, 55h ; 'U' movaps xmm0, xmm11 mulss xmm0, xmm11 movaps xmm1, xmm8 mulss xmm1, xmm8 addss xmm1, xmm0 movaps xmm0, xmm10 mulss xmm0, xmm10 addss xmm0, xmm1 xorps xmm7, xmm7 ucomiss xmm0, xmm7 jb short loc_77493 sqrtss xmm0, xmm0 jmp short loc_774D7 loc_77493: movaps [rsp+0D8h+var_A8], xmm8 movss [rsp+0D8h+var_CC], xmm10 movaps [rsp+0D8h+var_B8], xmm11 movss [rsp+0D8h+var_D0], xmm6 movaps [rsp+0D8h+var_C8], xmm3 call _sqrtf xorps xmm7, xmm7 movaps xmm3, [rsp+0D8h+var_C8] movss xmm6, [rsp+0D8h+var_D0] movaps xmm11, [rsp+0D8h+var_B8] movss xmm10, [rsp+0D8h+var_CC] movaps xmm8, [rsp+0D8h+var_A8] loc_774D7: movss xmm5, cs:dword_D9944 movaps xmm1, xmm5 divss xmm1, xmm0 cmpeqss xmm0, xmm7 movaps xmm2, xmm0 andnps xmm2, xmm1 andps xmm0, xmm5 orps xmm0, xmm2 mulss xmm8, xmm0 mulss xmm11, xmm0 mulss xmm10, xmm0 movaps xmm12, xmm3 shufps xmm12, xmm3, 55h ; 'U' movaps xmm4, cs:xmmword_D9BC0 xorps xmm4, xmm11 movaps xmm0, xmm6 mulss xmm0, xmm11 movaps xmm1, xmm8 mulss xmm1, xmm12 mulss xmm12, xmm10 subss xmm12, xmm0 movaps xmm0, xmm10 mulss xmm0, xmm3 mulss xmm6, xmm8 subss xmm6, xmm0 mulss xmm3, xmm11 subss xmm3, xmm1 movaps xmm0, xmm6 mulss xmm0, xmm6 movaps xmm1, xmm12 mulss xmm1, xmm12 addss xmm1, xmm0 movaps xmm0, xmm3 mulss xmm0, xmm3 addss xmm0, xmm1 ucomiss xmm0, xmm7 jb short loc_77579 sqrtss xmm0, xmm0 jmp short loc_775D8 loc_77579: movaps [rsp+0D8h+var_A8], xmm8 movss [rsp+0D8h+var_CC], xmm10 movaps [rsp+0D8h+var_B8], xmm11 movss [rsp+0D8h+var_D0], xmm6 movaps [rsp+0D8h+var_68], xmm12 movaps [rsp+0D8h+var_C8], xmm3 movaps [rsp+0D8h+var_78], xmm4 call _sqrtf movss xmm5, cs:dword_D9944 movaps xmm4, [rsp+0D8h+var_78] movaps xmm3, [rsp+0D8h+var_C8] movaps xmm12, [rsp+0D8h+var_68] movss xmm6, [rsp+0D8h+var_D0] movaps xmm11, [rsp+0D8h+var_B8] movss xmm10, [rsp+0D8h+var_CC] movaps xmm8, [rsp+0D8h+var_A8] loc_775D8: movaps xmm2, xmm5 divss xmm2, xmm0 xorps xmm1, xmm1 cmpeqss xmm1, xmm0 movaps xmm0, xmm1 andnps xmm0, xmm2 andps xmm1, xmm5 orps xmm1, xmm0 mulss xmm12, xmm1 mulss xmm6, xmm1 mulss xmm1, xmm3 movaps xmm2, xmm6 mulss xmm2, xmm10 movaps xmm0, xmm11 mulss xmm0, xmm1 subss xmm0, xmm2 movaps xmm3, xmm1 mulss xmm3, xmm8 movaps xmm2, xmm10 mulss xmm2, xmm12 subss xmm2, xmm3 mulss xmm4, xmm12 movaps xmm3, xmm8 mulss xmm3, xmm6 addss xmm3, xmm4 movaps xmm9, [rsp+0D8h+var_58] movaps xmm5, xmm9 mulss xmm5, xmm6 movaps xmm4, xmm12 movaps xmm7, [rsp+0D8h+var_98] mulss xmm4, xmm7 addss xmm4, xmm5 xorps xmm5, xmm5 lea rdi, [rsp+0D8h+var_48] movaps xmmword ptr [rdi], xmm5 movaps xmmword ptr [rdi+10h], xmm5 movaps xmmword ptr [rdi+20h], xmm5 movaps xmmword ptr [rdi+30h], xmm5 movss dword ptr [rdi], xmm12 movss dword ptr [rdi+4], xmm0 movss dword ptr [rdi+8], xmm8 xor eax, eax mov [rdi+0Ch], eax movss dword ptr [rdi+10h], xmm6 movss dword ptr [rdi+14h], xmm2 movss dword ptr [rdi+18h], xmm11 mov [rdi+1Ch], eax movss dword ptr [rdi+20h], xmm1 movaps xmm6, [rsp+0D8h+var_88] mulss xmm1, xmm6 addss xmm1, xmm4 movaps xmm4, cs:xmmword_D9BC0 xorps xmm1, xmm4 movaps xmm5, xmm9 mulss xmm5, xmm2 mulss xmm0, xmm7 addss xmm0, xmm5 movss dword ptr [rdi+24h], xmm3 mulss xmm3, xmm6 addss xmm3, xmm0 xorps xmm3, xmm4 mulss xmm9, xmm11 mulss xmm7, xmm8 addss xmm7, xmm9 mulss xmm6, xmm10 addss xmm6, xmm7 xorps xmm6, xmm4 movss dword ptr [rdi+28h], xmm10 mov [rdi+2Ch], eax movss dword ptr [rdi+30h], xmm1 movss dword ptr [rdi+34h], xmm3 movss dword ptr [rdi+38h], xmm6 mov dword ptr [rdi+3Ch], 3F800000h call rlMultMatrixf mov edi, 0B71h add rsp, 0D0h pop rbx jmp cs:glad_glEnable
long long BeginMode3D( long long a1, long long a2, long long a3, long long a4, long long a5, long long a6, unsigned long long a7, __int128 a8, unsigned long long a9, long long a10, int a11) { long long v11; // rdi int v12; // edx int v13; // ecx int v14; // r8d int v15; // r9d long long v16; // rdx long long v17; // r8 long long v18; // r9 long long v19; // rax long long v20; // rcx double v21; // xmm0_8 long long v22; // rdx long long v23; // rcx long long v24; // r8 long long v25; // r9 __m128 v26; // xmm8 __m128 v27; // xmm10 float v28; // xmm11_4 __m128 v29; // xmm0 __m128 v30; // xmm7 __m128 v31; // xmm5 __m128 v32; // xmm1 float v33; // xmm8_4 float v34; // xmm11_4 float v35; // xmm10_4 float v36; // xmm12_4 float v37; // xmm4_4 float v38; // xmm12_4 float v39; // xmm6_4 float v40; // xmm3_4 __m128 v41; // xmm0 __m128 v42; // xmm2 __m128 v43; // xmm1 float v44; // xmm12_4 float v45; // xmm6_4 float v47; // [rsp+40h] [rbp-98h] double v48; // [rsp+50h] [rbp-88h] float v49; // [rsp+80h] [rbp-58h] float v50; // [rsp+90h] [rbp-48h] BYREF float v51; // [rsp+94h] [rbp-44h] float v52; // [rsp+98h] [rbp-40h] int v53; // [rsp+9Ch] [rbp-3Ch] float v54; // [rsp+A0h] [rbp-38h] float v55; // [rsp+A4h] [rbp-34h] float v56; // [rsp+A8h] [rbp-30h] int v57; // [rsp+ACh] [rbp-2Ch] __int32 v58; // [rsp+B0h] [rbp-28h] float v59; // [rsp+B4h] [rbp-24h] float v60; // [rsp+B8h] [rbp-20h] int v61; // [rsp+BCh] [rbp-1Ch] float v62; // [rsp+C0h] [rbp-18h] float v63; // [rsp+C4h] [rbp-14h] float v64; // [rsp+C8h] [rbp-10h] int v65; // [rsp+CCh] [rbp-Ch] v11 = RLGL[0]; rlDrawRenderBatch(RLGL[0], a2); qword_141150 = (long long)&xmmword_141198; dword_14114C = 5889; rlPushMatrix(v11, a2, v12, v13, v14, v15); v19 = qword_141150; v20 = 1065353216LL; *(_DWORD *)qword_141150 = 1065353216; *(_OWORD *)(v19 + 4) = 0LL; *(_DWORD *)(v19 + 20) = 1065353216; *(_OWORD *)(v19 + 24) = 0LL; *(_DWORD *)(v19 + 40) = 1065353216; *(_OWORD *)(v19 + 44) = 0LL; *(_DWORD *)(v19 + 60) = 1065353216; if ( a11 == 1 ) { rlOrtho( -((float)((float)(int)dword_141BEC / (float)(int)dword_141BF0) * (*((float *)&a10 + 1) * 0.5)), (float)((float)(int)dword_141BEC / (float)(int)dword_141BF0) * (*((float *)&a10 + 1) * 0.5), -(*((float *)&a10 + 1) * 0.5), *((float *)&a10 + 1) * 0.5, *(double *)&rlCullDistanceNear, *(double *)&rlCullDistanceFar, v11, a2, v16, 1065353216LL, v17, v18); } else if ( !a11 ) { v48 = *(double *)&rlCullDistanceNear; v47 = (float)(int)dword_141BEC / (float)(int)dword_141BF0; v21 = tan(*((float *)&a10 + 1) * 0.5 * 0.01745329238474369); rlFrustum( -(v47 * (v48 * v21)), v47 * (v48 * v21), -(v48 * v21), v48 * v21, *(double *)&rlCullDistanceNear, *(double *)&rlCullDistanceFar, v11, a2, v22, v23, v24, v25); } qword_141150 = (long long)&xmmword_141158; dword_14114C = 5888; LODWORD(xmmword_141158) = 1065353216; *(__int128 *)((char *)&xmmword_141158 + 4) = 0LL; DWORD1(xmmword_141168) = 1065353216; *(__int128 *)((char *)&xmmword_141168 + 8) = 0LL; DWORD2(xmmword_141178) = 1065353216; *(__int128 *)((char *)&xmmword_141178 + 12) = 0LL; HIDWORD(xmmword_141188) = 1065353216; v26 = _mm_sub_ps((__m128)a7, (__m128)*(unsigned long long *)((char *)&a8 + 4)); LODWORD(v49) = _mm_shuffle_ps((__m128)a7, (__m128)a7, 85).m128_u32[0]; v27 = (__m128)(unsigned int)a8; v27.m128_f32[0] = *(float *)&a8 - *((float *)&a8 + 3); v28 = _mm_shuffle_ps(v26, v26, 85).m128_f32[0]; v29 = v27; v29.m128_f32[0] = (float)(v27.m128_f32[0] * v27.m128_f32[0]) + (float)((float)(v26.m128_f32[0] * v26.m128_f32[0]) + (float)(v28 * v28)); v30.m128_i32[0] = 0; if ( v29.m128_f32[0] < 0.0 ) { *(double *)v29.m128_u64 = sqrtf(*(double *)v29.m128_u64); v30.m128_i32[0] = 0; } else { v29.m128_f32[0] = fsqrt(v29.m128_f32[0]); } v31 = (__m128)0x3F800000u; v32 = (__m128)0x3F800000u; v32.m128_f32[0] = 1.0 / v29.m128_f32[0]; v41 = _mm_cmpeq_ss(v29, v30); v41.m128_i32[0] = v41.m128_i32[0] & 0x3F800000 | _mm_andnot_ps(v41, v32).m128_u32[0]; v33 = v26.m128_f32[0] * v41.m128_f32[0]; v34 = v28 * v41.m128_f32[0]; v35 = v27.m128_f32[0] * v41.m128_f32[0]; v36 = _mm_shuffle_ps((__m128)a9, (__m128)a9, 85).m128_f32[0]; v37 = -v34; v32.m128_f32[0] = v33 * v36; v38 = (float)(v36 * v35) - (float)(*(float *)&a10 * v34); v39 = (float)(*(float *)&a10 * v33) - (float)(v35 * *(float *)&a9); v40 = (float)(*(float *)&a9 * v34) - v32.m128_f32[0]; v41.m128_i32[1] = HIDWORD(a9); v41.m128_f32[0] = (float)(v40 * v40) + (float)((float)(v38 * v38) + (float)(v39 * v39)); if ( v41.m128_f32[0] < 0.0 ) { *(double *)v41.m128_u64 = sqrtf(*(double *)v41.m128_u64); v31 = (__m128)0x3F800000u; v37 = -v34; } else { v41.m128_f32[0] = fsqrt(v41.m128_f32[0]); } v42 = v31; v42.m128_f32[0] = v31.m128_f32[0] / v41.m128_f32[0]; v43 = _mm_cmpeq_ss((__m128)0LL, v41); v43.m128_i32[0] = v43.m128_i32[0] & v31.m128_i32[0] | _mm_andnot_ps(v43, v42).m128_u32[0]; v44 = v38 * v43.m128_f32[0]; v45 = v39 * v43.m128_f32[0]; v43.m128_f32[0] = v43.m128_f32[0] * v40; v50 = v44; v51 = (float)(v34 * v43.m128_f32[0]) - (float)(v45 * v35); v52 = v33; v53 = 0; v54 = v45; v55 = (float)(v35 * v44) - (float)(v43.m128_f32[0] * v33); v56 = v34; v57 = 0; v58 = v43.m128_i32[0]; v59 = (float)(v33 * v45) + (float)(v37 * v44); v60 = v35; v61 = 0; v62 = -(float)((float)(v43.m128_f32[0] * *(float *)&a8) + (float)((float)(v44 * *(float *)&a7) + (float)(v49 * v45))); v63 = -(float)((float)(v59 * *(float *)&a8) + (float)((float)(v51 * *(float *)&a7) + (float)(v49 * v55))); v64 = -(float)((float)(*(float *)&a8 * v35) + (float)((float)(*(float *)&a7 * v33) + (float)(v49 * v34))); v65 = 1065353216; rlMultMatrixf(&v50, a2, v16, v20, v17, v18); return glad_glEnable(2929LL); }
BeginMode3D: PUSH RBX SUB RSP,0xd0 LEA RBX,[RSP + 0xe0] MOV RDI,qword ptr [0x00241108] CALL 0x0016246c LEA RAX,[0x241198] MOV qword ptr [0x00241150],RAX MOV dword ptr [0x0024114c],0x1701 CALL 0x00161151 MOV RAX,qword ptr [0x00241150] MOV ECX,0x3f800000 MOV dword ptr [RAX],ECX XORPS XMM0,XMM0 MOVUPS xmmword ptr [RAX + 0x4],XMM0 MOV dword ptr [RAX + 0x14],ECX MOVUPS xmmword ptr [RAX + 0x18],XMM0 MOV dword ptr [RAX + 0x28],ECX MOVUPS xmmword ptr [RAX + 0x2c],XMM0 MOV dword ptr [RAX + 0x3c],ECX MOV EAX,dword ptr [0x00241bec] CVTSI2SS XMM1,RAX MOV EAX,dword ptr [0x00241bf0] XORPS XMM0,XMM0 CVTSI2SS XMM0,RAX DIVSS XMM1,XMM0 MOV EAX,dword ptr [RBX + 0x28] CMP EAX,0x1 JZ 0x0017738e TEST EAX,EAX JNZ 0x001773cc MOVSD XMM0,qword ptr [0x0023c7c0] MOVAPS xmmword ptr [RSP + 0x50],XMM0 XORPS XMM0,XMM0 CVTSS2SD XMM0,dword ptr [RBX + 0x24] MULSD XMM0,qword ptr [0x001d9ae8] MULSD XMM0,qword ptr [0x001e4838] MOVSS dword ptr [RSP + 0x40],XMM1 CALL 0x001092f0 MOVAPD XMM3,xmmword ptr [RSP + 0x50] MULSD XMM3,XMM0 XORPS XMM1,XMM1 CVTSS2SD XMM1,dword ptr [RSP + 0x40] MULSD XMM1,XMM3 MOVAPD XMM2,xmmword ptr [0x001d9bd0] MOVAPD XMM0,XMM1 XORPD XMM0,XMM2 XORPD XMM2,XMM3 MOVSD XMM4,qword ptr [0x0023c7c0] MOVSD XMM5,qword ptr [0x0023c7c8] CALL 0x00161ead JMP 0x001773cc LAB_0017738e: CVTSS2SD XMM3,dword ptr [RBX + 0x24] MULSD XMM3,qword ptr [0x001d9ae8] CVTSS2SD XMM1,XMM1 MULSD XMM1,XMM3 MOVAPD XMM2,xmmword ptr [0x001d9bd0] MOVAPD XMM0,XMM1 XORPD XMM0,XMM2 XORPD XMM2,XMM3 MOVSD XMM4,qword ptr [0x0023c7c0] MOVSD XMM5,qword ptr [0x0023c7c8] CALL 0x001620ae LAB_001773cc: LEA RAX,[0x241158] MOV qword ptr [0x00241150],RAX MOV dword ptr [0x0024114c],0x1700 MOV EAX,0x3f800000 MOV dword ptr [0x00241158],EAX XORPS XMM0,XMM0 MOVUPS xmmword ptr [0x0024115c],XMM0 MOV dword ptr [0x0024116c],EAX MOVUPS xmmword ptr [0x00241170],XMM0 MOV dword ptr [0x00241180],EAX MOVUPS xmmword ptr [0x00241184],XMM0 MOV dword ptr [0x00241194],EAX MOVSD XMM2,qword ptr [RBX] MOVSS XMM1,dword ptr [RBX + 0x8] MOVSD XMM0,qword ptr [RBX + 0xc] MOVSD XMM3,qword ptr [RBX + 0x18] MOVSS XMM6,dword ptr [RBX + 0x20] MOVAPS XMM8,XMM2 SUBPS XMM8,XMM0 MOVAPS xmmword ptr [RSP + 0x40],XMM2 SHUFPS XMM2,XMM2,0x55 MOVAPS xmmword ptr [RSP + 0x80],XMM2 MOVAPS XMM11,XMM8 MOVAPS xmmword ptr [RSP + 0x50],XMM1 MOVAPS XMM10,XMM1 SUBSS XMM10,dword ptr [RBX + 0x14] SHUFPS XMM11,XMM8,0x55 MOVAPS XMM0,XMM11 MULSS XMM0,XMM11 MOVAPS XMM1,XMM8 MULSS XMM1,XMM8 ADDSS XMM1,XMM0 MOVAPS XMM0,XMM10 MULSS XMM0,XMM10 ADDSS XMM0,XMM1 XORPS XMM7,XMM7 UCOMISS XMM0,XMM7 JC 0x00177493 SQRTSS XMM0,XMM0 JMP 0x001774d7 LAB_00177493: MOVAPS xmmword ptr [RSP + 0x30],XMM8 MOVSS dword ptr [RSP + 0xc],XMM10 MOVAPS xmmword ptr [RSP + 0x20],XMM11 MOVSS dword ptr [RSP + 0x8],XMM6 MOVAPS xmmword ptr [RSP + 0x10],XMM3 CALL 0x001099f0 XORPS XMM7,XMM7 MOVAPS XMM3,xmmword ptr [RSP + 0x10] MOVSS XMM6,dword ptr [RSP + 0x8] MOVAPS XMM11,xmmword ptr [RSP + 0x20] MOVSS XMM10,dword ptr [RSP + 0xc] MOVAPS XMM8,xmmword ptr [RSP + 0x30] LAB_001774d7: MOVSS XMM5,dword ptr [0x001d9944] MOVAPS XMM1,XMM5 DIVSS XMM1,XMM0 CMPEQSS XMM0,XMM7 MOVAPS XMM2,XMM0 ANDNPS XMM2,XMM1 ANDPS XMM0,XMM5 ORPS XMM0,XMM2 MULSS XMM8,XMM0 MULSS XMM11,XMM0 MULSS XMM10,XMM0 MOVAPS XMM12,XMM3 SHUFPS XMM12,XMM3,0x55 MOVAPS XMM4,xmmword ptr [0x001d9bc0] XORPS XMM4,XMM11 MOVAPS XMM0,XMM6 MULSS XMM0,XMM11 MOVAPS XMM1,XMM8 MULSS XMM1,XMM12 MULSS XMM12,XMM10 SUBSS XMM12,XMM0 MOVAPS XMM0,XMM10 MULSS XMM0,XMM3 MULSS XMM6,XMM8 SUBSS XMM6,XMM0 MULSS XMM3,XMM11 SUBSS XMM3,XMM1 MOVAPS XMM0,XMM6 MULSS XMM0,XMM6 MOVAPS XMM1,XMM12 MULSS XMM1,XMM12 ADDSS XMM1,XMM0 MOVAPS XMM0,XMM3 MULSS XMM0,XMM3 ADDSS XMM0,XMM1 UCOMISS XMM0,XMM7 JC 0x00177579 SQRTSS XMM0,XMM0 JMP 0x001775d8 LAB_00177579: MOVAPS xmmword ptr [RSP + 0x30],XMM8 MOVSS dword ptr [RSP + 0xc],XMM10 MOVAPS xmmword ptr [RSP + 0x20],XMM11 MOVSS dword ptr [RSP + 0x8],XMM6 MOVAPS xmmword ptr [RSP + 0x70],XMM12 MOVAPS xmmword ptr [RSP + 0x10],XMM3 MOVAPS xmmword ptr [RSP + 0x60],XMM4 CALL 0x001099f0 MOVSS XMM5,dword ptr [0x001d9944] MOVAPS XMM4,xmmword ptr [RSP + 0x60] MOVAPS XMM3,xmmword ptr [RSP + 0x10] MOVAPS XMM12,xmmword ptr [RSP + 0x70] MOVSS XMM6,dword ptr [RSP + 0x8] MOVAPS XMM11,xmmword ptr [RSP + 0x20] MOVSS XMM10,dword ptr [RSP + 0xc] MOVAPS XMM8,xmmword ptr [RSP + 0x30] LAB_001775d8: MOVAPS XMM2,XMM5 DIVSS XMM2,XMM0 XORPS XMM1,XMM1 CMPEQSS XMM1,XMM0 MOVAPS XMM0,XMM1 ANDNPS XMM0,XMM2 ANDPS XMM1,XMM5 ORPS XMM1,XMM0 MULSS XMM12,XMM1 MULSS XMM6,XMM1 MULSS XMM1,XMM3 MOVAPS XMM2,XMM6 MULSS XMM2,XMM10 MOVAPS XMM0,XMM11 MULSS XMM0,XMM1 SUBSS XMM0,XMM2 MOVAPS XMM3,XMM1 MULSS XMM3,XMM8 MOVAPS XMM2,XMM10 MULSS XMM2,XMM12 SUBSS XMM2,XMM3 MULSS XMM4,XMM12 MOVAPS XMM3,XMM8 MULSS XMM3,XMM6 ADDSS XMM3,XMM4 MOVAPS XMM9,xmmword ptr [RSP + 0x80] MOVAPS XMM5,XMM9 MULSS XMM5,XMM6 MOVAPS XMM4,XMM12 MOVAPS XMM7,xmmword ptr [RSP + 0x40] MULSS XMM4,XMM7 ADDSS XMM4,XMM5 XORPS XMM5,XMM5 LEA RDI,[RSP + 0x90] MOVAPS xmmword ptr [RDI],XMM5 MOVAPS xmmword ptr [RDI + 0x10],XMM5 MOVAPS xmmword ptr [RDI + 0x20],XMM5 MOVAPS xmmword ptr [RDI + 0x30],XMM5 MOVSS dword ptr [RDI],XMM12 MOVSS dword ptr [RDI + 0x4],XMM0 MOVSS dword ptr [RDI + 0x8],XMM8 XOR EAX,EAX MOV dword ptr [RDI + 0xc],EAX MOVSS dword ptr [RDI + 0x10],XMM6 MOVSS dword ptr [RDI + 0x14],XMM2 MOVSS dword ptr [RDI + 0x18],XMM11 MOV dword ptr [RDI + 0x1c],EAX MOVSS dword ptr [RDI + 0x20],XMM1 MOVAPS XMM6,xmmword ptr [RSP + 0x50] MULSS XMM1,XMM6 ADDSS XMM1,XMM4 MOVAPS XMM4,xmmword ptr [0x001d9bc0] XORPS XMM1,XMM4 MOVAPS XMM5,XMM9 MULSS XMM5,XMM2 MULSS XMM0,XMM7 ADDSS XMM0,XMM5 MOVSS dword ptr [RDI + 0x24],XMM3 MULSS XMM3,XMM6 ADDSS XMM3,XMM0 XORPS XMM3,XMM4 MULSS XMM9,XMM11 MULSS XMM7,XMM8 ADDSS XMM7,XMM9 MULSS XMM6,XMM10 ADDSS XMM6,XMM7 XORPS XMM6,XMM4 MOVSS dword ptr [RDI + 0x28],XMM10 MOV dword ptr [RDI + 0x2c],EAX MOVSS dword ptr [RDI + 0x30],XMM1 MOVSS dword ptr [RDI + 0x34],XMM3 MOVSS dword ptr [RDI + 0x38],XMM6 MOV dword ptr [RDI + 0x3c],0x3f800000 CALL 0x00161ce6 MOV EDI,0xb71 ADD RSP,0xd0 POP RBX JMP qword ptr [0x0023f820]
/* WARNING: Globals starting with '_' overlap smaller symbols at the same address */ void BeginMode3D(void) { int4 *puVar1; ulong uVar2; ulong uVar3; float fVar4; double dVar5; double dVar6; uint uVar7; float fVar8; float fVar9; float fVar10; float fVar11; float fVar12; int8 in_stack_00000008; int4 uStack0000000000000010; int4 uStack000000000000001c; int8 in_stack_00000020; float fStack0000000000000028; float fStack000000000000002c; int in_stack_00000030; rlDrawRenderBatch(RLGL); DAT_00241150 = &DAT_00241198; DAT_0024114c = 0x1701; rlPushMatrix(); puVar1 = DAT_00241150; *DAT_00241150 = 0x3f800000; *(int8 *)(puVar1 + 1) = 0; *(int8 *)(puVar1 + 3) = 0; puVar1[5] = 0x3f800000; *(int8 *)(puVar1 + 6) = 0; *(int8 *)(puVar1 + 8) = 0; puVar1[10] = 0x3f800000; *(int8 *)(puVar1 + 0xb) = 0; *(int8 *)(puVar1 + 0xd) = 0; puVar1[0xf] = 0x3f800000; dVar6 = rlCullDistanceNear; uVar2 = (ulong)_DAT_00241bec; uVar3 = (ulong)_DAT_00241bf0; if (in_stack_00000030 == 1) { uVar7 = SUB84((double)fStack000000000000002c * DAT_001d9ae8,0); dVar6 = (double)((float)uVar2 / (float)uVar3) * (double)fStack000000000000002c * DAT_001d9ae8; rlOrtho((ulong)dVar6 ^ _DAT_001d9bd0,dVar6,(uint)_DAT_001d9bd0 ^ uVar7,uVar7, SUB84(rlCullDistanceNear,0),(int)rlCullDistanceFar); } else if (in_stack_00000030 == 0) { dVar5 = tan((double)fStack000000000000002c * DAT_001d9ae8 * _DAT_001e4838); uVar7 = SUB84(dVar6 * dVar5,0); dVar6 = (double)((float)uVar2 / (float)uVar3) * dVar6 * dVar5; rlFrustum((ulong)dVar6 ^ _DAT_001d9bd0,dVar6,(uint)_DAT_001d9bd0 ^ uVar7,uVar7, SUB84(rlCullDistanceNear,0),(int)rlCullDistanceFar); } DAT_00241150 = &DAT_00241158; DAT_0024114c = 0x1700; DAT_00241158 = 0x3f800000; _DAT_0024115c = 0; _DAT_00241164 = 0; DAT_0024116c = 0x3f800000; _DAT_00241170 = 0; _DAT_00241178 = 0; DAT_00241180 = 0x3f800000; _DAT_00241184 = 0; _DAT_0024118c = 0; DAT_00241194 = 0x3f800000; fVar8 = (float)((ulong)in_stack_00000020 >> 0x20); fVar9 = (float)in_stack_00000008 - SUB164(_uStack0000000000000010,4); fVar10 = (float)((ulong)in_stack_00000008 >> 0x20) - SUB164(_uStack0000000000000010,8); fVar11 = (float)uStack0000000000000010 - (float)uStack000000000000001c; fVar4 = fVar11 * fVar11 + fVar9 * fVar9 + fVar10 * fVar10; if (fVar4 < 0.0) { fVar4 = sqrtf(fVar4); } else { fVar4 = SQRT(fVar4); } fVar4 = (float)(-(uint)(fVar4 == 0.0) & (uint)DAT_001d9944 | ~-(uint)(fVar4 == 0.0) & (uint)(DAT_001d9944 / fVar4)); fVar12 = fVar8 * fVar11 * fVar4 - fStack0000000000000028 * fVar10 * fVar4; fVar11 = fStack0000000000000028 * fVar9 * fVar4 - fVar11 * fVar4 * (float)in_stack_00000020; fVar4 = (float)in_stack_00000020 * fVar10 * fVar4 - fVar9 * fVar4 * fVar8; fVar4 = fVar4 * fVar4 + fVar12 * fVar12 + fVar11 * fVar11; if (fVar4 < 0.0) { sqrtf(fVar4); } rlMultMatrixf(); /* WARNING: Could not recover jumptable at 0x00177726. Too many branches */ /* WARNING: Treating indirect jump as call */ (*glad_glEnable)(0xb71); return; }
27,547
BeginMode3D
csit-sgu[P]mit-game-2025_1/Libraries/raylib/src/rcore.c
void BeginMode3D(Camera camera) { rlDrawRenderBatchActive(); // Update and draw internal render batch rlMatrixMode(RL_PROJECTION); // Switch to projection matrix rlPushMatrix(); // Save previous matrix, which contains the settings for the 2d ortho projection rlLoadIdentity(); // Reset current matrix (projection) float aspect = (float)CORE.Window.currentFbo.width/(float)CORE.Window.currentFbo.height; // NOTE: zNear and zFar values are important when computing depth buffer values if (camera.projection == CAMERA_PERSPECTIVE) { // Setup perspective projection double top = rlGetCullDistanceNear()*tan(camera.fovy*0.5*DEG2RAD); double right = top*aspect; rlFrustum(-right, right, -top, top, rlGetCullDistanceNear(), rlGetCullDistanceFar()); } else if (camera.projection == CAMERA_ORTHOGRAPHIC) { // Setup orthographic projection double top = camera.fovy/2.0; double right = top*aspect; rlOrtho(-right, right, -top,top, rlGetCullDistanceNear(), rlGetCullDistanceFar()); } rlMatrixMode(RL_MODELVIEW); // Switch back to modelview matrix rlLoadIdentity(); // Reset current matrix (modelview) // Setup Camera view Matrix matView = MatrixLookAt(camera.position, camera.target, camera.up); rlMultMatrixf(MatrixToFloat(matView)); // Multiply modelview matrix by view matrix (camera) rlEnableDepthTest(); // Enable DEPTH_TEST for 3D }
O2
c
BeginMode3D: pushq %rbx subq $0xa0, %rsp leaq 0xb0(%rsp), %rbx callq 0x544b6 leaq 0xc555a(%rip), %rax # 0x1271c8 movq %rax, 0xc550b(%rip) # 0x127180 movl $0x1701, 0xc54fd(%rip) # imm = 0x1701 callq 0x50579 callq 0x50688 movl 0xc5f8d(%rip), %eax # 0x127c1c cvtsi2ss %rax, %xmm1 movl 0xc5f86(%rip), %eax # 0x127c20 cvtsi2ss %rax, %xmm0 divss %xmm0, %xmm1 movl 0x28(%rbx), %eax cmpl $0x1, %eax je 0x61d1f testl %eax, %eax jne 0x61d5d movsd 0xc0af5(%rip), %xmm0 # 0x1227b0 movaps %xmm0, 0x10(%rsp) cvtss2sd 0x24(%rbx), %xmm0 mulsd 0x57b63(%rip), %xmm0 # 0xb9830 mulsd 0x62d63(%rip), %xmm0 # 0xc4a38 movss %xmm1, 0xc(%rsp) callq 0x92e0 movapd 0x10(%rsp), %xmm3 mulsd %xmm0, %xmm3 cvtss2sd 0xc(%rsp), %xmm1 mulsd %xmm3, %xmm1 movapd 0x57ca4(%rip), %xmm2 # 0xb99a0 movapd %xmm1, %xmm0 xorpd %xmm2, %xmm0 xorpd %xmm3, %xmm2 movsd 0xc0aa0(%rip), %xmm4 # 0x1227b0 movsd 0xc0aa0(%rip), %xmm5 # 0x1227b8 callq 0x50ed3 jmp 0x61d5d cvtss2sd 0x24(%rbx), %xmm3 mulsd 0x57b04(%rip), %xmm3 # 0xb9830 cvtss2sd %xmm1, %xmm1 mulsd %xmm3, %xmm1 movapd 0x57c64(%rip), %xmm2 # 0xb99a0 movapd %xmm1, %xmm0 xorpd %xmm2, %xmm0 xorpd %xmm3, %xmm2 movsd 0xc0a60(%rip), %xmm4 # 0x1227b0 movsd 0xc0a60(%rip), %xmm5 # 0x1227b8 callq 0x5108c leaq 0xc5424(%rip), %rax # 0x127188 movq %rax, 0xc5415(%rip) # 0x127180 movl $0x1700, 0xc5407(%rip) # imm = 0x1700 callq 0x50688 movsd (%rbx), %xmm0 movss 0x8(%rbx), %xmm1 movsd 0xc(%rbx), %xmm2 movss 0x14(%rbx), %xmm3 movsd 0x18(%rbx), %xmm4 movss 0x20(%rbx), %xmm5 leaq 0x20(%rsp), %rbx movq %rbx, %rdi callq 0x59109 movss (%rbx), %xmm0 movss 0x4(%rbx), %xmm1 movss 0x8(%rbx), %xmm2 movss 0xc(%rbx), %xmm3 movss 0x10(%rbx), %xmm4 movss 0x14(%rbx), %xmm5 movss 0x18(%rbx), %xmm6 movss 0x1c(%rbx), %xmm7 movss 0x20(%rbx), %xmm8 movss 0x24(%rbx), %xmm9 movss 0x28(%rbx), %xmm10 movss 0x2c(%rbx), %xmm11 movss 0x30(%rbx), %xmm12 movss 0x34(%rbx), %xmm13 movss 0x38(%rbx), %xmm14 movss 0x3c(%rbx), %xmm15 leaq 0x60(%rsp), %rdi movss %xmm0, (%rdi) movss %xmm4, 0x4(%rdi) movss %xmm8, 0x8(%rdi) movss %xmm12, 0xc(%rdi) movss %xmm1, 0x10(%rdi) movss %xmm5, 0x14(%rdi) movss %xmm9, 0x18(%rdi) movss %xmm13, 0x1c(%rdi) movss %xmm2, 0x20(%rdi) movss %xmm6, 0x24(%rdi) movss %xmm10, 0x28(%rdi) movss %xmm14, 0x2c(%rdi) movss %xmm3, 0x30(%rdi) movss %xmm7, 0x34(%rdi) movss %xmm11, 0x38(%rdi) movss %xmm15, 0x3c(%rdi) callq 0x50d0c movl $0xb71, %edi # imm = 0xB71 addq $0xa0, %rsp popq %rbx jmpq *0xc39e1(%rip) # 0x125850
BeginMode3D: push rbx sub rsp, 0A0h lea rbx, [rsp+0A8h+arg_0] call rlDrawRenderBatchActive lea rax, xmmword_1271C8 mov cs:qword_127180, rax mov cs:dword_12717C, 1701h call rlPushMatrix call rlLoadIdentity mov eax, dword ptr cs:qword_127C1C cvtsi2ss xmm1, rax mov eax, dword ptr cs:qword_127C1C+4 cvtsi2ss xmm0, rax divss xmm1, xmm0 mov eax, [rbx+28h] cmp eax, 1 jz short loc_61D1F test eax, eax jnz loc_61D5D movsd xmm0, cs:rlCullDistanceNear movaps [rsp+0A8h+var_98], xmm0 cvtss2sd xmm0, dword ptr [rbx+24h] mulsd xmm0, cs:qword_B9830 mulsd xmm0, cs:qword_C4A38 movss [rsp+0A8h+var_9C], xmm1 call _tan movapd xmm3, [rsp+0A8h+var_98] mulsd xmm3, xmm0 cvtss2sd xmm1, [rsp+0A8h+var_9C] mulsd xmm1, xmm3 movapd xmm2, cs:xmmword_B99A0 movapd xmm0, xmm1 xorpd xmm0, xmm2 xorpd xmm2, xmm3 movsd xmm4, cs:rlCullDistanceNear movsd xmm5, cs:rlCullDistanceFar call rlFrustum jmp short loc_61D5D loc_61D1F: cvtss2sd xmm3, dword ptr [rbx+24h] mulsd xmm3, cs:qword_B9830 cvtss2sd xmm1, xmm1 mulsd xmm1, xmm3 movapd xmm2, cs:xmmword_B99A0 movapd xmm0, xmm1 xorpd xmm0, xmm2 xorpd xmm2, xmm3 movsd xmm4, cs:rlCullDistanceNear movsd xmm5, cs:rlCullDistanceFar call rlOrtho loc_61D5D: lea rax, xmmword_127188 mov cs:qword_127180, rax mov cs:dword_12717C, 1700h call rlLoadIdentity movsd xmm0, qword ptr [rbx] movss xmm1, dword ptr [rbx+8] movsd xmm2, qword ptr [rbx+0Ch] movss xmm3, dword ptr [rbx+14h] movsd xmm4, qword ptr [rbx+18h] movss xmm5, dword ptr [rbx+20h] lea rbx, [rsp+0A8h+var_88] mov rdi, rbx call MatrixLookAt movss xmm0, dword ptr [rbx] movss xmm1, dword ptr [rbx+4] movss xmm2, dword ptr [rbx+8] movss xmm3, dword ptr [rbx+0Ch] movss xmm4, dword ptr [rbx+10h] movss xmm5, dword ptr [rbx+14h] movss xmm6, dword ptr [rbx+18h] movss xmm7, dword ptr [rbx+1Ch] movss xmm8, dword ptr [rbx+20h] movss xmm9, dword ptr [rbx+24h] movss xmm10, dword ptr [rbx+28h] movss xmm11, dword ptr [rbx+2Ch] movss xmm12, dword ptr [rbx+30h] movss xmm13, dword ptr [rbx+34h] movss xmm14, dword ptr [rbx+38h] movss xmm15, dword ptr [rbx+3Ch] lea rdi, [rsp+0A8h+var_48] movss dword ptr [rdi], xmm0 movss dword ptr [rdi+4], xmm4 movss dword ptr [rdi+8], xmm8 movss dword ptr [rdi+0Ch], xmm12 movss dword ptr [rdi+10h], xmm1 movss dword ptr [rdi+14h], xmm5 movss dword ptr [rdi+18h], xmm9 movss dword ptr [rdi+1Ch], xmm13 movss dword ptr [rdi+20h], xmm2 movss dword ptr [rdi+24h], xmm6 movss dword ptr [rdi+28h], xmm10 movss dword ptr [rdi+2Ch], xmm14 movss dword ptr [rdi+30h], xmm3 movss dword ptr [rdi+34h], xmm7 movss dword ptr [rdi+38h], xmm11 movss dword ptr [rdi+3Ch], xmm15 call rlMultMatrixf mov edi, 0B71h add rsp, 0A0h pop rbx jmp cs:glad_glEnable
long long BeginMode3D( long long a1, long long a2, double a3, __m128 a4, __m128 a5, __m128 a6, double a7, double a8, __m128 a9, __m128 a10, long long a11, long long a12, long long a13, long long a14, unsigned long long a15, __int128 a16, unsigned long long a17, long long a18, int a19) { int v19; // edx int v20; // ecx int v21; // r8d int v22; // r9d long long v23; // rdx long long v24; // rcx long long v25; // r8 long long v26; // r9 double v27; // xmm0_8 double v28; // xmm3_8 long long v29; // rdx long long v30; // rcx long long v31; // r8 long long v32; // r9 double v33; // xmm3_8 long long v34; // rdx long long v35; // rcx long long v36; // r8 long long v37; // r9 float v39; // [rsp+Ch] [rbp-9Ch] double v40; // [rsp+10h] [rbp-98h] __int32 v41; // [rsp+20h] [rbp-88h] BYREF __int32 v42; // [rsp+24h] [rbp-84h] __int32 v43; // [rsp+28h] [rbp-80h] __int32 v44; // [rsp+2Ch] [rbp-7Ch] unsigned __int32 v45; // [rsp+30h] [rbp-78h] unsigned __int32 v46; // [rsp+34h] [rbp-74h] unsigned __int32 v47; // [rsp+38h] [rbp-70h] unsigned __int32 v48; // [rsp+3Ch] [rbp-6Ch] __int32 v49; // [rsp+40h] [rbp-68h] __int32 v50; // [rsp+44h] [rbp-64h] __int32 v51; // [rsp+48h] [rbp-60h] __int32 v52; // [rsp+4Ch] [rbp-5Ch] __int32 v53; // [rsp+50h] [rbp-58h] __int32 v54; // [rsp+54h] [rbp-54h] __int32 v55; // [rsp+58h] [rbp-50h] __int32 v56; // [rsp+5Ch] [rbp-4Ch] __int32 v57[18]; // [rsp+60h] [rbp-48h] BYREF rlDrawRenderBatchActive(a3, a4, a5, a6, a7, a8, a9, a10, a1, a2); qword_127180 = (long long)&xmmword_1271C8; dword_12717C = 5889; rlPushMatrix(a1, a2, v19, v20, v21, v22); ((void (*)(void))rlLoadIdentity)(); *(float *)&v27 = (float)SHIDWORD(qword_127C1C); a4.m128_f32[0] = (float)(int)qword_127C1C / (float)SHIDWORD(qword_127C1C); if ( a19 == 1 ) { v33 = *((float *)&a18 + 1) * 0.5; *(double *)a4.m128_u64 = a4.m128_f32[0] * v33; v27 = -*(double *)a4.m128_u64; rlOrtho( -*(double *)a4.m128_u64, *(double *)a4.m128_u64, -v33, v33, (__m128)(unsigned long long)rlCullDistanceNear, (__m128)(unsigned long long)rlCullDistanceFar, a9, a10, a1, a2, v23, v24, v25, v26); } else if ( !a19 ) { v40 = *(double *)&rlCullDistanceNear; v39 = (float)(int)qword_127C1C / (float)SHIDWORD(qword_127C1C); v28 = v40 * tan(*((float *)&a18 + 1) * 0.5 * 0.01745329238474369); *(double *)a4.m128_u64 = v39 * v28; v27 = -*(double *)a4.m128_u64; rlFrustum( -*(double *)a4.m128_u64, a4, -v28, v28, (__m128)(unsigned long long)rlCullDistanceNear, (__m128)(unsigned long long)rlCullDistanceFar, a9, a10, a1, a2, v29, v30, v31, v32); } qword_127180 = (long long)&xmmword_127188; dword_12717C = 5888; rlLoadIdentity(v27, *(double *)a4.m128_u64); MatrixLookAt( (long long)&v41, (__m128)a15, (__m128)(unsigned int)a16, (__m128)*(unsigned long long *)((char *)&a16 + 4), *((float *)&a16 + 3), (__m128)a17, *(float *)&a18); v57[0] = v41; v57[1] = v45; v57[2] = v49; v57[3] = v53; v57[4] = v42; v57[5] = v46; v57[6] = v50; v57[7] = v54; v57[8] = v43; v57[9] = v47; v57[10] = v51; v57[11] = v55; v57[12] = v44; v57[13] = v48; v57[14] = v52; v57[15] = v56; rlMultMatrixf( v57, a2, v34, v35, v36, v37, COERCE_DOUBLE((unsigned long long)v41), COERCE_DOUBLE((unsigned long long)v42), COERCE_DOUBLE((unsigned long long)v43), COERCE_DOUBLE((unsigned long long)v44), (__m128)v45, (__m128)v46, (__m128)v47, (__m128)v48); return glad_glEnable(2929LL); }
BeginMode3D: PUSH RBX SUB RSP,0xa0 LEA RBX,[RSP + 0xb0] CALL 0x001544b6 LEA RAX,[0x2271c8] MOV qword ptr [0x00227180],RAX MOV dword ptr [0x0022717c],0x1701 CALL 0x00150579 CALL 0x00150688 MOV EAX,dword ptr [0x00227c1c] CVTSI2SS XMM1,RAX MOV EAX,dword ptr [0x00227c20] CVTSI2SS XMM0,RAX DIVSS XMM1,XMM0 MOV EAX,dword ptr [RBX + 0x28] CMP EAX,0x1 JZ 0x00161d1f TEST EAX,EAX JNZ 0x00161d5d MOVSD XMM0,qword ptr [0x002227b0] MOVAPS xmmword ptr [RSP + 0x10],XMM0 CVTSS2SD XMM0,dword ptr [RBX + 0x24] MULSD XMM0,qword ptr [0x001b9830] MULSD XMM0,qword ptr [0x001c4a38] MOVSS dword ptr [RSP + 0xc],XMM1 CALL 0x001092e0 MOVAPD XMM3,xmmword ptr [RSP + 0x10] MULSD XMM3,XMM0 CVTSS2SD XMM1,dword ptr [RSP + 0xc] MULSD XMM1,XMM3 MOVAPD XMM2,xmmword ptr [0x001b99a0] MOVAPD XMM0,XMM1 XORPD XMM0,XMM2 XORPD XMM2,XMM3 MOVSD XMM4,qword ptr [0x002227b0] MOVSD XMM5,qword ptr [0x002227b8] CALL 0x00150ed3 JMP 0x00161d5d LAB_00161d1f: CVTSS2SD XMM3,dword ptr [RBX + 0x24] MULSD XMM3,qword ptr [0x001b9830] CVTSS2SD XMM1,XMM1 MULSD XMM1,XMM3 MOVAPD XMM2,xmmword ptr [0x001b99a0] MOVAPD XMM0,XMM1 XORPD XMM0,XMM2 XORPD XMM2,XMM3 MOVSD XMM4,qword ptr [0x002227b0] MOVSD XMM5,qword ptr [0x002227b8] CALL 0x0015108c LAB_00161d5d: LEA RAX,[0x227188] MOV qword ptr [0x00227180],RAX MOV dword ptr [0x0022717c],0x1700 CALL 0x00150688 MOVSD XMM0,qword ptr [RBX] MOVSS XMM1,dword ptr [RBX + 0x8] MOVSD XMM2,qword ptr [RBX + 0xc] MOVSS XMM3,dword ptr [RBX + 0x14] MOVSD XMM4,qword ptr [RBX + 0x18] MOVSS XMM5,dword ptr [RBX + 0x20] LEA RBX,[RSP + 0x20] MOV RDI,RBX CALL 0x00159109 MOVSS XMM0,dword ptr [RBX] MOVSS XMM1,dword ptr [RBX + 0x4] MOVSS XMM2,dword ptr [RBX + 0x8] MOVSS XMM3,dword ptr [RBX + 0xc] MOVSS XMM4,dword ptr [RBX + 0x10] MOVSS XMM5,dword ptr [RBX + 0x14] MOVSS XMM6,dword ptr [RBX + 0x18] MOVSS XMM7,dword ptr [RBX + 0x1c] MOVSS XMM8,dword ptr [RBX + 0x20] MOVSS XMM9,dword ptr [RBX + 0x24] MOVSS XMM10,dword ptr [RBX + 0x28] MOVSS XMM11,dword ptr [RBX + 0x2c] MOVSS XMM12,dword ptr [RBX + 0x30] MOVSS XMM13,dword ptr [RBX + 0x34] MOVSS XMM14,dword ptr [RBX + 0x38] MOVSS XMM15,dword ptr [RBX + 0x3c] LEA RDI,[RSP + 0x60] MOVSS dword ptr [RDI],XMM0 MOVSS dword ptr [RDI + 0x4],XMM4 MOVSS dword ptr [RDI + 0x8],XMM8 MOVSS dword ptr [RDI + 0xc],XMM12 MOVSS dword ptr [RDI + 0x10],XMM1 MOVSS dword ptr [RDI + 0x14],XMM5 MOVSS dword ptr [RDI + 0x18],XMM9 MOVSS dword ptr [RDI + 0x1c],XMM13 MOVSS dword ptr [RDI + 0x20],XMM2 MOVSS dword ptr [RDI + 0x24],XMM6 MOVSS dword ptr [RDI + 0x28],XMM10 MOVSS dword ptr [RDI + 0x2c],XMM14 MOVSS dword ptr [RDI + 0x30],XMM3 MOVSS dword ptr [RDI + 0x34],XMM7 MOVSS dword ptr [RDI + 0x38],XMM11 MOVSS dword ptr [RDI + 0x3c],XMM15 CALL 0x00150d0c MOV EDI,0xb71 ADD RSP,0xa0 POP RBX JMP qword ptr [0x00225850]
/* WARNING: Globals starting with '_' overlap smaller symbols at the same address */ void BeginMode3D(void) { ulong uVar1; ulong uVar2; double dVar3; double dVar4; int4 in_stack_00000008; int4 uStack0000000000000010; int8 uStack0000000000000014; int4 uStack000000000000001c; int8 in_stack_00000020; int4 uStack0000000000000028; float fStack000000000000002c; int in_stack_00000030; int4 local_88; int4 local_84; int4 local_80; int4 local_7c; int4 local_78; int4 local_74; int4 local_70; int4 local_6c; int4 local_68; int4 local_64; int4 local_60; int4 local_5c; int4 local_58; int4 local_54; int4 local_50; int4 local_4c; int4 local_48; int4 local_44; int4 local_40; int4 local_3c; int4 local_38; int4 local_34; int4 local_30; int4 local_2c; int4 local_28; int4 local_24; int4 local_20; int4 local_1c; int4 local_18; int4 local_14; int4 local_10; int4 local_c; rlDrawRenderBatchActive(); DAT_00227180 = &DAT_002271c8; DAT_0022717c = 0x1701; rlPushMatrix(); rlLoadIdentity(); dVar4 = rlCullDistanceNear; uVar1 = (ulong)DAT_00227c1c; uVar2 = (ulong)DAT_00227c20; if (in_stack_00000030 == 1) { dVar3 = (double)fStack000000000000002c * DAT_001b9830; dVar4 = (double)((float)uVar1 / (float)uVar2) * dVar3; rlOrtho(SUB84(dVar4,0) ^ (uint)_DAT_001b99a0,dVar4,_DAT_001b99a0 ^ (ulong)dVar3,dVar3, rlCullDistanceNear,rlCullDistanceFar); } else if (in_stack_00000030 == 0) { dVar3 = tan((double)fStack000000000000002c * DAT_001b9830 * _DAT_001c4a38); dVar4 = dVar4 * dVar3; dVar3 = (double)((float)uVar1 / (float)uVar2) * dVar4; rlFrustum(SUB84(dVar3,0) ^ (uint)_DAT_001b99a0,dVar3,_DAT_001b99a0 ^ (ulong)dVar4,dVar4, rlCullDistanceNear,rlCullDistanceFar); } DAT_00227180 = &DAT_00227188; DAT_0022717c = 0x1700; rlLoadIdentity(); MatrixLookAt(in_stack_00000008,uStack0000000000000010,uStack0000000000000014, uStack000000000000001c,in_stack_00000020,uStack0000000000000028,&local_88); local_48 = local_88; local_44 = local_78; local_40 = local_68; local_3c = local_58; local_38 = local_84; local_34 = local_74; local_30 = local_64; local_2c = local_54; local_28 = local_80; local_24 = local_70; local_20 = local_60; local_1c = local_50; local_18 = local_7c; local_14 = local_6c; local_10 = local_5c; local_c = local_4c; rlMultMatrixf(); /* WARNING: Could not recover jumptable at 0x00161e69. Too many branches */ /* WARNING: Treating indirect jump as call */ (*glad_glEnable)(0xb71); return; }
27,548
BeginMode3D
csit-sgu[P]mit-game-2025_1/Libraries/raylib/src/rcore.c
void BeginMode3D(Camera camera) { rlDrawRenderBatchActive(); // Update and draw internal render batch rlMatrixMode(RL_PROJECTION); // Switch to projection matrix rlPushMatrix(); // Save previous matrix, which contains the settings for the 2d ortho projection rlLoadIdentity(); // Reset current matrix (projection) float aspect = (float)CORE.Window.currentFbo.width/(float)CORE.Window.currentFbo.height; // NOTE: zNear and zFar values are important when computing depth buffer values if (camera.projection == CAMERA_PERSPECTIVE) { // Setup perspective projection double top = rlGetCullDistanceNear()*tan(camera.fovy*0.5*DEG2RAD); double right = top*aspect; rlFrustum(-right, right, -top, top, rlGetCullDistanceNear(), rlGetCullDistanceFar()); } else if (camera.projection == CAMERA_ORTHOGRAPHIC) { // Setup orthographic projection double top = camera.fovy/2.0; double right = top*aspect; rlOrtho(-right, right, -top,top, rlGetCullDistanceNear(), rlGetCullDistanceFar()); } rlMatrixMode(RL_MODELVIEW); // Switch back to modelview matrix rlLoadIdentity(); // Reset current matrix (modelview) // Setup Camera view Matrix matView = MatrixLookAt(camera.position, camera.target, camera.up); rlMultMatrixf(MatrixToFloat(matView)); // Multiply modelview matrix by view matrix (camera) rlEnableDepthTest(); // Enable DEPTH_TEST for 3D }
O3
c
BeginMode3D: pushq %rbx subq $0x60, %rsp leaq 0x70(%rsp), %rbx movq 0xc7ad6(%rip), %rdi # 0x13b118 callq 0x61150 leaq 0xc7b5a(%rip), %rax # 0x13b1a8 movq %rax, 0xc7b0b(%rip) # 0x13b160 movl $0x1701, 0xc7afd(%rip) # imm = 0x1701 callq 0x602a7 movq 0xc7af5(%rip), %rax # 0x13b160 movl $0x3f800000, %ecx # imm = 0x3F800000 movl %ecx, (%rax) xorps %xmm0, %xmm0 movups %xmm0, 0x4(%rax) movl %ecx, 0x14(%rax) movups %xmm0, 0x18(%rax) movl %ecx, 0x28(%rax) movups %xmm0, 0x2c(%rax) movl %ecx, 0x3c(%rax) movl 0xc856c(%rip), %eax # 0x13bbfc cvtsi2ss %rax, %xmm1 movl 0xc8565(%rip), %eax # 0x13bc00 xorps %xmm0, %xmm0 cvtsi2ss %rax, %xmm0 divss %xmm0, %xmm1 movl 0x28(%rbx), %eax cmpl $0x1, %eax je 0x73729 testl %eax, %eax jne 0x73767 movsd 0xc3101(%rip), %xmm0 # 0x1367c0 movaps %xmm0, 0x10(%rsp) xorps %xmm0, %xmm0 cvtss2sd 0x24(%rbx), %xmm0 mulsd 0x605dc(%rip), %xmm0 # 0xd3cb0 mulsd 0x6b1d4(%rip), %xmm0 # 0xde8b0 movss %xmm1, 0xc(%rsp) callq 0xa2f0 movapd 0x10(%rsp), %xmm3 mulsd %xmm0, %xmm3 xorps %xmm1, %xmm1 cvtss2sd 0xc(%rsp), %xmm1 mulsd %xmm3, %xmm1 movapd 0x5bc5a(%rip), %xmm2 # 0xcf360 movapd %xmm1, %xmm0 xorpd %xmm2, %xmm0 xorpd %xmm3, %xmm2 movsd 0xc30a6(%rip), %xmm4 # 0x1367c0 movsd 0xc30a6(%rip), %xmm5 # 0x1367c8 callq 0x60c06 jmp 0x73767 cvtss2sd 0x24(%rbx), %xmm3 mulsd 0x6057a(%rip), %xmm3 # 0xd3cb0 cvtss2sd %xmm1, %xmm1 mulsd %xmm3, %xmm1 movapd 0x5bc1a(%rip), %xmm2 # 0xcf360 movapd %xmm1, %xmm0 xorpd %xmm2, %xmm0 xorpd %xmm3, %xmm2 movsd 0xc3066(%rip), %xmm4 # 0x1367c0 movsd 0xc3066(%rip), %xmm5 # 0x1367c8 callq 0x60dc8 leaq 0xc79fa(%rip), %rax # 0x13b168 movq %rax, 0xc79eb(%rip) # 0x13b160 movl $0x1700, 0xc79dd(%rip) # imm = 0x1700 movl $0x3f800000, %eax # imm = 0x3F800000 movl %eax, 0xc79de(%rip) # 0x13b168 xorps %xmm0, %xmm0 movups %xmm0, 0xc79d8(%rip) # 0x13b16c movl %eax, 0xc79e2(%rip) # 0x13b17c movups %xmm0, 0xc79df(%rip) # 0x13b180 movl %eax, 0xc79e9(%rip) # 0x13b190 movups %xmm0, 0xc79e6(%rip) # 0x13b194 movl %eax, 0xc79f0(%rip) # 0x13b1a4 movsd (%rbx), %xmm1 movss 0x8(%rbx), %xmm0 movsd 0xc(%rbx), %xmm3 movsd 0x18(%rbx), %xmm9 movss 0x20(%rbx), %xmm2 movaps %xmm1, %xmm6 subps %xmm3, %xmm6 movaps %xmm1, %xmm4 shufps $0x55, %xmm1, %xmm4 # xmm4 = xmm4[1,1],xmm1[1,1] movaps %xmm6, %xmm3 movaps %xmm0, %xmm7 subss 0x14(%rbx), %xmm7 shufps $0x55, %xmm6, %xmm3 # xmm3 = xmm3[1,1],xmm6[1,1] movaps %xmm3, %xmm5 mulss %xmm3, %xmm5 movaps %xmm6, %xmm8 mulss %xmm6, %xmm8 addss %xmm5, %xmm8 movaps %xmm7, %xmm5 mulss %xmm7, %xmm5 addss %xmm8, %xmm5 sqrtss %xmm5, %xmm5 movss 0x60305(%rip), %xmm10 # 0xd3b1c movaps %xmm10, %xmm8 divss %xmm5, %xmm8 xorps %xmm11, %xmm11 cmpeqss %xmm11, %xmm5 movaps %xmm5, %xmm12 andnps %xmm8, %xmm12 andps %xmm10, %xmm5 orps %xmm12, %xmm5 mulss %xmm5, %xmm6 mulss %xmm5, %xmm3 mulss %xmm7, %xmm5 movaps %xmm9, %xmm7 shufps $0x55, %xmm9, %xmm7 # xmm7 = xmm7[1,1],xmm9[1,1] movaps %xmm2, %xmm8 mulss %xmm3, %xmm8 movaps %xmm6, %xmm12 mulss %xmm7, %xmm12 mulss %xmm5, %xmm7 subss %xmm8, %xmm7 movaps %xmm5, %xmm8 mulss %xmm9, %xmm8 mulss %xmm6, %xmm2 subss %xmm8, %xmm2 mulss %xmm3, %xmm9 subss %xmm12, %xmm9 movaps %xmm2, %xmm8 mulss %xmm2, %xmm8 movaps %xmm7, %xmm12 mulss %xmm7, %xmm12 addss %xmm8, %xmm12 movaps %xmm9, %xmm8 mulss %xmm9, %xmm8 addss %xmm12, %xmm8 sqrtss %xmm8, %xmm8 movaps %xmm10, %xmm12 divss %xmm8, %xmm12 cmpeqss %xmm11, %xmm8 movaps %xmm8, %xmm11 andnps %xmm12, %xmm11 andps %xmm10, %xmm8 orps %xmm11, %xmm8 mulss %xmm8, %xmm7 mulss %xmm8, %xmm2 mulss %xmm9, %xmm8 movaps %xmm2, %xmm10 mulss %xmm5, %xmm10 movaps %xmm3, %xmm9 mulss %xmm8, %xmm9 subss %xmm10, %xmm9 movaps %xmm8, %xmm11 mulss %xmm6, %xmm11 movaps %xmm5, %xmm10 mulss %xmm7, %xmm10 subss %xmm11, %xmm10 movaps %xmm7, %xmm12 mulss %xmm3, %xmm12 movaps %xmm6, %xmm11 leaq 0x20(%rsp), %rdi movss %xmm7, (%rdi) movss %xmm9, 0x4(%rdi) movss %xmm6, 0x8(%rdi) mulss %xmm2, %xmm6 subss %xmm12, %xmm6 xorl %ecx, %ecx movl %ecx, 0xc(%rdi) movss %xmm2, 0x10(%rdi) unpcklps %xmm10, %xmm2 # xmm2 = xmm2[0],xmm10[0],xmm2[1],xmm10[1] mulps %xmm4, %xmm2 mulss %xmm3, %xmm4 mulss %xmm1, %xmm11 addss %xmm4, %xmm11 movss %xmm10, 0x14(%rdi) movss %xmm3, 0x18(%rdi) movl %ecx, 0x1c(%rdi) movss %xmm8, 0x20(%rdi) movss %xmm6, 0x24(%rdi) movss %xmm5, 0x28(%rdi) mulss %xmm0, %xmm5 addss %xmm11, %xmm5 movaps 0x5b7cd(%rip), %xmm3 # 0xcf150 xorps %xmm3, %xmm5 movl %ecx, 0x2c(%rdi) unpcklps %xmm9, %xmm7 # xmm7 = xmm7[0],xmm9[0],xmm7[1],xmm9[1] shufps $0x0, %xmm1, %xmm1 # xmm1 = xmm1[0,0,0,0] mulps %xmm7, %xmm1 addps %xmm2, %xmm1 unpcklps %xmm6, %xmm8 # xmm8 = xmm8[0],xmm6[0],xmm8[1],xmm6[1] unpcklps %xmm0, %xmm0 # xmm0 = xmm0[0,0,1,1] mulps %xmm8, %xmm0 addps %xmm1, %xmm0 xorps %xmm3, %xmm0 movlps %xmm0, 0x30(%rdi) movss %xmm5, 0x38(%rdi) movl %eax, 0x3c(%rdi) callq 0x60a3f movl $0xb71, %edi # imm = 0xB71 addq $0x60, %rsp popq %rbx jmpq *0xc5e67(%rip) # 0x139830
BeginMode3D: push rbx sub rsp, 60h lea rbx, [rsp+68h+arg_0] mov rdi, cs:RLGL call rlDrawRenderBatch lea rax, xmmword_13B1A8 mov cs:qword_13B160, rax mov cs:dword_13B15C, 1701h call rlPushMatrix mov rax, cs:qword_13B160 mov ecx, 3F800000h mov [rax], ecx xorps xmm0, xmm0 movups xmmword ptr [rax+4], xmm0 mov [rax+14h], ecx movups xmmword ptr [rax+18h], xmm0 mov [rax+28h], ecx movups xmmword ptr [rax+2Ch], xmm0 mov [rax+3Ch], ecx mov eax, dword ptr cs:qword_13BBFC cvtsi2ss xmm1, rax mov eax, dword ptr cs:qword_13BBFC+4 xorps xmm0, xmm0 cvtsi2ss xmm0, rax divss xmm1, xmm0 mov eax, [rbx+28h] cmp eax, 1 jz short loc_73729 test eax, eax jnz loc_73767 movsd xmm0, cs:rlCullDistanceNear movaps [rsp+68h+var_58], xmm0 xorps xmm0, xmm0 cvtss2sd xmm0, dword ptr [rbx+24h] mulsd xmm0, cs:qword_D3CB0 mulsd xmm0, cs:qword_DE8B0 movss [rsp+68h+var_5C], xmm1 call _tan movapd xmm3, [rsp+68h+var_58] mulsd xmm3, xmm0 xorps xmm1, xmm1 cvtss2sd xmm1, [rsp+68h+var_5C] mulsd xmm1, xmm3 movapd xmm2, cs:xmmword_CF360 movapd xmm0, xmm1 xorpd xmm0, xmm2 xorpd xmm2, xmm3 movsd xmm4, cs:rlCullDistanceNear movsd xmm5, cs:rlCullDistanceFar call rlFrustum jmp short loc_73767 loc_73729: cvtss2sd xmm3, dword ptr [rbx+24h] mulsd xmm3, cs:qword_D3CB0 cvtss2sd xmm1, xmm1 mulsd xmm1, xmm3 movapd xmm2, cs:xmmword_CF360 movapd xmm0, xmm1 xorpd xmm0, xmm2 xorpd xmm2, xmm3 movsd xmm4, cs:rlCullDistanceNear movsd xmm5, cs:rlCullDistanceFar call rlOrtho loc_73767: lea rax, xmmword_13B168 mov cs:qword_13B160, rax mov cs:dword_13B15C, 1700h mov eax, 3F800000h mov dword ptr cs:xmmword_13B168, eax xorps xmm0, xmm0 movups cs:xmmword_13B168+4, xmm0 mov dword ptr cs:xmmword_13B178+4, eax movups cs:xmmword_13B178+8, xmm0 mov dword ptr cs:xmmword_13B188+8, eax movups cs:xmmword_13B188+0Ch, xmm0 mov dword ptr cs:xmmword_13B198+0Ch, eax movsd xmm1, qword ptr [rbx] movss xmm0, dword ptr [rbx+8] movsd xmm3, qword ptr [rbx+0Ch] movsd xmm9, qword ptr [rbx+18h] movss xmm2, dword ptr [rbx+20h] movaps xmm6, xmm1 subps xmm6, xmm3 movaps xmm4, xmm1 shufps xmm4, xmm1, 55h ; 'U' movaps xmm3, xmm6 movaps xmm7, xmm0 subss xmm7, dword ptr [rbx+14h] shufps xmm3, xmm6, 55h ; 'U' movaps xmm5, xmm3 mulss xmm5, xmm3 movaps xmm8, xmm6 mulss xmm8, xmm6 addss xmm8, xmm5 movaps xmm5, xmm7 mulss xmm5, xmm7 addss xmm5, xmm8 sqrtss xmm5, xmm5 movss xmm10, cs:dword_D3B1C movaps xmm8, xmm10 divss xmm8, xmm5 xorps xmm11, xmm11 cmpeqss xmm5, xmm11 movaps xmm12, xmm5 andnps xmm12, xmm8 andps xmm5, xmm10 orps xmm5, xmm12 mulss xmm6, xmm5 mulss xmm3, xmm5 mulss xmm5, xmm7 movaps xmm7, xmm9 shufps xmm7, xmm9, 55h ; 'U' movaps xmm8, xmm2 mulss xmm8, xmm3 movaps xmm12, xmm6 mulss xmm12, xmm7 mulss xmm7, xmm5 subss xmm7, xmm8 movaps xmm8, xmm5 mulss xmm8, xmm9 mulss xmm2, xmm6 subss xmm2, xmm8 mulss xmm9, xmm3 subss xmm9, xmm12 movaps xmm8, xmm2 mulss xmm8, xmm2 movaps xmm12, xmm7 mulss xmm12, xmm7 addss xmm12, xmm8 movaps xmm8, xmm9 mulss xmm8, xmm9 addss xmm8, xmm12 sqrtss xmm8, xmm8 movaps xmm12, xmm10 divss xmm12, xmm8 cmpeqss xmm8, xmm11 movaps xmm11, xmm8 andnps xmm11, xmm12 andps xmm8, xmm10 orps xmm8, xmm11 mulss xmm7, xmm8 mulss xmm2, xmm8 mulss xmm8, xmm9 movaps xmm10, xmm2 mulss xmm10, xmm5 movaps xmm9, xmm3 mulss xmm9, xmm8 subss xmm9, xmm10 movaps xmm11, xmm8 mulss xmm11, xmm6 movaps xmm10, xmm5 mulss xmm10, xmm7 subss xmm10, xmm11 movaps xmm12, xmm7 mulss xmm12, xmm3 movaps xmm11, xmm6 lea rdi, [rsp+68h+var_48] movss dword ptr [rdi], xmm7 movss dword ptr [rdi+4], xmm9 movss dword ptr [rdi+8], xmm6 mulss xmm6, xmm2 subss xmm6, xmm12 xor ecx, ecx mov [rdi+0Ch], ecx movss dword ptr [rdi+10h], xmm2 unpcklps xmm2, xmm10 mulps xmm2, xmm4 mulss xmm4, xmm3 mulss xmm11, xmm1 addss xmm11, xmm4 movss dword ptr [rdi+14h], xmm10 movss dword ptr [rdi+18h], xmm3 mov [rdi+1Ch], ecx movss dword ptr [rdi+20h], xmm8 movss dword ptr [rdi+24h], xmm6 movss dword ptr [rdi+28h], xmm5 mulss xmm5, xmm0 addss xmm5, xmm11 movaps xmm3, cs:xmmword_CF150 xorps xmm5, xmm3 mov [rdi+2Ch], ecx unpcklps xmm7, xmm9 shufps xmm1, xmm1, 0 mulps xmm1, xmm7 addps xmm1, xmm2 unpcklps xmm8, xmm6 unpcklps xmm0, xmm0 mulps xmm0, xmm8 addps xmm0, xmm1 xorps xmm0, xmm3 movlps qword ptr [rdi+30h], xmm0 movss dword ptr [rdi+38h], xmm5 mov [rdi+3Ch], eax call rlMultMatrixf mov edi, 0B71h add rsp, 60h pop rbx jmp cs:glad_glEnable
long long BeginMode3D( double a1, __m128 a2, __m128 a3, __m128 a4, double a5, double a6, __m128 a7, __m128 a8, long long a9, long long a10, long long a11, long long a12, long long a13, long long a14, unsigned long long a15, __int128 a16, unsigned long long a17, long long a18, int a19) { long long v19; // rdi int v20; // edx int v21; // ecx int v22; // r8d int v23; // r9d long long v24; // rdx long long v25; // r8 long long v26; // r9 long long v27; // rax double v28; // xmm0_8 long long v29; // rdx long long v30; // rcx long long v31; // r8 long long v32; // r9 __m128 v33; // xmm1 __m128 v34; // xmm9 __m128 v35; // xmm2 __m128 v36; // xmm6 __m128 v37; // xmm4 __m128 v38; // xmm7 __m128 v39; // xmm3 __m128 v40; // xmm5 __m128 v41; // xmm8 __m128 v42; // xmm11 __m128 v43; // xmm5 __m128 v44; // xmm5 __m128 v45; // xmm7 float v46; // xmm12_4 __m128 v47; // xmm8 __m128 v48; // xmm12 __m128 v49; // xmm8 __m128 v50; // xmm8 __m128 v51; // xmm9 __m128 v52; // xmm10 __m128 v53; // xmm2 __m128 v54; // xmm5 __m128 v55; // xmm7 __m128 v56; // xmm1 __m128 v57; // xmm0 float v59; // [rsp+Ch] [rbp-5Ch] double v60; // [rsp+10h] [rbp-58h] __int32 v61[12]; // [rsp+20h] [rbp-48h] BYREF double v62; // [rsp+50h] [rbp-18h] BYREF __int32 v63; // [rsp+58h] [rbp-10h] int v64; // [rsp+5Ch] [rbp-Ch] v19 = RLGL[0]; rlDrawRenderBatch(RLGL[0], a10, a1, a2, a3, a4, a5, a6, a7, a8); qword_13B160 = (long long)&xmmword_13B1A8; dword_13B15C = 5889; rlPushMatrix(v19, a10, v20, v21, v22, v23); v27 = qword_13B160; *(_DWORD *)qword_13B160 = 1065353216; *(_OWORD *)(v27 + 4) = 0LL; *(_DWORD *)(v27 + 20) = 1065353216; *(_OWORD *)(v27 + 24) = 0LL; *(_DWORD *)(v27 + 40) = 1065353216; *(_OWORD *)(v27 + 44) = 0LL; *(_DWORD *)(v27 + 60) = 1065353216; if ( a19 == 1 ) { rlOrtho( -((float)((float)(int)qword_13BBFC / (float)SHIDWORD(qword_13BBFC)) * (*((float *)&a18 + 1) * 0.5)), (float)((float)(int)qword_13BBFC / (float)SHIDWORD(qword_13BBFC)) * (*((float *)&a18 + 1) * 0.5), -(*((float *)&a18 + 1) * 0.5), *((float *)&a18 + 1) * 0.5, (__m128)(unsigned long long)rlCullDistanceNear, (__m128)(unsigned long long)rlCullDistanceFar, a7, a8, v19, a10, v24, 1065353216LL, v25, v26); } else if ( !a19 ) { v60 = *(double *)&rlCullDistanceNear; v59 = (float)(int)qword_13BBFC / (float)SHIDWORD(qword_13BBFC); v28 = tan(*((float *)&a18 + 1) * 0.5 * 0.01745329238474369); rlFrustum( -(v59 * (v60 * v28)), v59 * (v60 * v28), -(v60 * v28), v60 * v28, *(double *)&rlCullDistanceNear, *(double *)&rlCullDistanceFar, a7, a8, v19, a10, v29, v30, v31, v32); } qword_13B160 = (long long)&xmmword_13B168; dword_13B15C = 5888; LODWORD(xmmword_13B168) = 1065353216; *(__int128 *)((char *)&xmmword_13B168 + 4) = 0LL; DWORD1(xmmword_13B178) = 1065353216; *(__int128 *)((char *)&xmmword_13B178 + 8) = 0LL; DWORD2(xmmword_13B188) = 1065353216; *(__int128 *)((char *)&xmmword_13B188 + 12) = 0LL; HIDWORD(xmmword_13B198) = 1065353216; v33 = (__m128)a15; v34 = (__m128)a17; v35 = (__m128)(unsigned int)a18; v36 = _mm_sub_ps((__m128)a15, (__m128)*(unsigned long long *)((char *)&a16 + 4)); v37 = _mm_shuffle_ps(v33, v33, 85); v38 = (__m128)(unsigned int)a16; v38.m128_f32[0] = *(float *)&a16 - *((float *)&a16 + 3); v39 = _mm_shuffle_ps(v36, v36, 85); v40 = v38; v40.m128_f32[0] = fsqrt( (float)(v38.m128_f32[0] * v38.m128_f32[0]) + (float)((float)(v36.m128_f32[0] * v36.m128_f32[0]) + (float)(v39.m128_f32[0] * v39.m128_f32[0]))); v41 = (__m128)0x3F800000u; v41.m128_f32[0] = 1.0 / v40.m128_f32[0]; v42.m128_i32[0] = 0; v43 = _mm_cmpeq_ss(v40, v42); v44 = _mm_or_ps(_mm_and_ps(v43, (__m128)0x3F800000u), _mm_andnot_ps(v43, v41)); v36.m128_f32[0] = v36.m128_f32[0] * v44.m128_f32[0]; v39.m128_f32[0] = v39.m128_f32[0] * v44.m128_f32[0]; v44.m128_f32[0] = v44.m128_f32[0] * (float)(*(float *)&a16 - *((float *)&a16 + 3)); v45 = _mm_shuffle_ps(v34, v34, 85); v46 = v36.m128_f32[0] * v45.m128_f32[0]; v45.m128_f32[0] = (float)(v45.m128_f32[0] * v44.m128_f32[0]) - (float)(*(float *)&a18 * v39.m128_f32[0]); v35.m128_f32[0] = (float)(*(float *)&a18 * v36.m128_f32[0]) - (float)(v44.m128_f32[0] * *(float *)&a17); v34.m128_f32[0] = (float)(*(float *)&a17 * v39.m128_f32[0]) - v46; v47 = v34; v47.m128_f32[0] = fsqrt( (float)(v34.m128_f32[0] * v34.m128_f32[0]) + (float)((float)(v45.m128_f32[0] * v45.m128_f32[0]) + (float)(v35.m128_f32[0] * v35.m128_f32[0]))); v48 = (__m128)0x3F800000u; v48.m128_f32[0] = 1.0 / v47.m128_f32[0]; v49 = _mm_cmpeq_ss(v47, v42); v50 = _mm_or_ps(_mm_and_ps(v49, (__m128)0x3F800000u), _mm_andnot_ps(v49, v48)); v45.m128_f32[0] = v45.m128_f32[0] * v50.m128_f32[0]; v35.m128_f32[0] = v35.m128_f32[0] * v50.m128_f32[0]; v50.m128_f32[0] = v50.m128_f32[0] * v34.m128_f32[0]; v51 = v39; v51.m128_f32[0] = (float)(v39.m128_f32[0] * v50.m128_f32[0]) - (float)(v35.m128_f32[0] * v44.m128_f32[0]); v52 = v44; v52.m128_f32[0] = (float)(v44.m128_f32[0] * v45.m128_f32[0]) - (float)(v50.m128_f32[0] * v36.m128_f32[0]); v42.m128_i32[0] = v36.m128_i32[0]; v61[0] = v45.m128_i32[0]; v61[1] = v51.m128_i32[0]; v61[2] = v36.m128_i32[0]; v36.m128_f32[0] = (float)(v36.m128_f32[0] * v35.m128_f32[0]) - (float)(v45.m128_f32[0] * v39.m128_f32[0]); v61[3] = 0; v61[4] = v35.m128_i32[0]; v53 = _mm_mul_ps(_mm_unpacklo_ps(v35, v52), v37); v37.m128_f32[0] = v37.m128_f32[0] * v39.m128_f32[0]; v61[5] = v52.m128_i32[0]; v61[6] = v39.m128_i32[0]; v61[7] = 0; v61[8] = v50.m128_i32[0]; v61[9] = v36.m128_i32[0]; v61[10] = v44.m128_i32[0]; v44.m128_f32[0] = (float)(v44.m128_f32[0] * *(float *)&a16) + (float)((float)(v42.m128_f32[0] * *(float *)&a15) + v37.m128_f32[0]); v54 = _mm_xor_ps(v44, (__m128)xmmword_CF150); v61[11] = 0; v55 = _mm_unpacklo_ps(v45, v51); v56 = _mm_add_ps(_mm_mul_ps(_mm_shuffle_ps(v33, v33, 0), v55), v53); v57 = _mm_xor_ps( _mm_add_ps( _mm_mul_ps(_mm_unpacklo_ps((__m128)(unsigned int)a16, (__m128)(unsigned int)a16), _mm_unpacklo_ps(v50, v36)), v56), (__m128)xmmword_CF150); _mm_storel_ps(&v62, v57); v63 = v54.m128_i32[0]; v64 = 1065353216; rlMultMatrixf( v61, a10, v24, 0LL, v25, v26, *(double *)v57.m128_u64, *(double *)v56.m128_u64, *(double *)v53.m128_u64, COERCE_DOUBLE(0x8000000080000000LL), v37, v54, v36, v55); return glad_glEnable(2929LL); }
BeginMode3D: PUSH RBX SUB RSP,0x60 LEA RBX,[RSP + 0x70] MOV RDI,qword ptr [0x0023b118] CALL 0x00161150 LEA RAX,[0x23b1a8] MOV qword ptr [0x0023b160],RAX MOV dword ptr [0x0023b15c],0x1701 CALL 0x001602a7 MOV RAX,qword ptr [0x0023b160] MOV ECX,0x3f800000 MOV dword ptr [RAX],ECX XORPS XMM0,XMM0 MOVUPS xmmword ptr [RAX + 0x4],XMM0 MOV dword ptr [RAX + 0x14],ECX MOVUPS xmmword ptr [RAX + 0x18],XMM0 MOV dword ptr [RAX + 0x28],ECX MOVUPS xmmword ptr [RAX + 0x2c],XMM0 MOV dword ptr [RAX + 0x3c],ECX MOV EAX,dword ptr [0x0023bbfc] CVTSI2SS XMM1,RAX MOV EAX,dword ptr [0x0023bc00] XORPS XMM0,XMM0 CVTSI2SS XMM0,RAX DIVSS XMM1,XMM0 MOV EAX,dword ptr [RBX + 0x28] CMP EAX,0x1 JZ 0x00173729 TEST EAX,EAX JNZ 0x00173767 MOVSD XMM0,qword ptr [0x002367c0] MOVAPS xmmword ptr [RSP + 0x10],XMM0 XORPS XMM0,XMM0 CVTSS2SD XMM0,dword ptr [RBX + 0x24] MULSD XMM0,qword ptr [0x001d3cb0] MULSD XMM0,qword ptr [0x001de8b0] MOVSS dword ptr [RSP + 0xc],XMM1 CALL 0x0010a2f0 MOVAPD XMM3,xmmword ptr [RSP + 0x10] MULSD XMM3,XMM0 XORPS XMM1,XMM1 CVTSS2SD XMM1,dword ptr [RSP + 0xc] MULSD XMM1,XMM3 MOVAPD XMM2,xmmword ptr [0x001cf360] MOVAPD XMM0,XMM1 XORPD XMM0,XMM2 XORPD XMM2,XMM3 MOVSD XMM4,qword ptr [0x002367c0] MOVSD XMM5,qword ptr [0x002367c8] CALL 0x00160c06 JMP 0x00173767 LAB_00173729: CVTSS2SD XMM3,dword ptr [RBX + 0x24] MULSD XMM3,qword ptr [0x001d3cb0] CVTSS2SD XMM1,XMM1 MULSD XMM1,XMM3 MOVAPD XMM2,xmmword ptr [0x001cf360] MOVAPD XMM0,XMM1 XORPD XMM0,XMM2 XORPD XMM2,XMM3 MOVSD XMM4,qword ptr [0x002367c0] MOVSD XMM5,qword ptr [0x002367c8] CALL 0x00160dc8 LAB_00173767: LEA RAX,[0x23b168] MOV qword ptr [0x0023b160],RAX MOV dword ptr [0x0023b15c],0x1700 MOV EAX,0x3f800000 MOV dword ptr [0x0023b168],EAX XORPS XMM0,XMM0 MOVUPS xmmword ptr [0x0023b16c],XMM0 MOV dword ptr [0x0023b17c],EAX MOVUPS xmmword ptr [0x0023b180],XMM0 MOV dword ptr [0x0023b190],EAX MOVUPS xmmword ptr [0x0023b194],XMM0 MOV dword ptr [0x0023b1a4],EAX MOVSD XMM1,qword ptr [RBX] MOVSS XMM0,dword ptr [RBX + 0x8] MOVSD XMM3,qword ptr [RBX + 0xc] MOVSD XMM9,qword ptr [RBX + 0x18] MOVSS XMM2,dword ptr [RBX + 0x20] MOVAPS XMM6,XMM1 SUBPS XMM6,XMM3 MOVAPS XMM4,XMM1 SHUFPS XMM4,XMM1,0x55 MOVAPS XMM3,XMM6 MOVAPS XMM7,XMM0 SUBSS XMM7,dword ptr [RBX + 0x14] SHUFPS XMM3,XMM6,0x55 MOVAPS XMM5,XMM3 MULSS XMM5,XMM3 MOVAPS XMM8,XMM6 MULSS XMM8,XMM6 ADDSS XMM8,XMM5 MOVAPS XMM5,XMM7 MULSS XMM5,XMM7 ADDSS XMM5,XMM8 SQRTSS XMM5,XMM5 MOVSS XMM10,dword ptr [0x001d3b1c] MOVAPS XMM8,XMM10 DIVSS XMM8,XMM5 XORPS XMM11,XMM11 CMPEQSS XMM5,XMM11 MOVAPS XMM12,XMM5 ANDNPS XMM12,XMM8 ANDPS XMM5,XMM10 ORPS XMM5,XMM12 MULSS XMM6,XMM5 MULSS XMM3,XMM5 MULSS XMM5,XMM7 MOVAPS XMM7,XMM9 SHUFPS XMM7,XMM9,0x55 MOVAPS XMM8,XMM2 MULSS XMM8,XMM3 MOVAPS XMM12,XMM6 MULSS XMM12,XMM7 MULSS XMM7,XMM5 SUBSS XMM7,XMM8 MOVAPS XMM8,XMM5 MULSS XMM8,XMM9 MULSS XMM2,XMM6 SUBSS XMM2,XMM8 MULSS XMM9,XMM3 SUBSS XMM9,XMM12 MOVAPS XMM8,XMM2 MULSS XMM8,XMM2 MOVAPS XMM12,XMM7 MULSS XMM12,XMM7 ADDSS XMM12,XMM8 MOVAPS XMM8,XMM9 MULSS XMM8,XMM9 ADDSS XMM8,XMM12 SQRTSS XMM8,XMM8 MOVAPS XMM12,XMM10 DIVSS XMM12,XMM8 CMPEQSS XMM8,XMM11 MOVAPS XMM11,XMM8 ANDNPS XMM11,XMM12 ANDPS XMM8,XMM10 ORPS XMM8,XMM11 MULSS XMM7,XMM8 MULSS XMM2,XMM8 MULSS XMM8,XMM9 MOVAPS XMM10,XMM2 MULSS XMM10,XMM5 MOVAPS XMM9,XMM3 MULSS XMM9,XMM8 SUBSS XMM9,XMM10 MOVAPS XMM11,XMM8 MULSS XMM11,XMM6 MOVAPS XMM10,XMM5 MULSS XMM10,XMM7 SUBSS XMM10,XMM11 MOVAPS XMM12,XMM7 MULSS XMM12,XMM3 MOVAPS XMM11,XMM6 LEA RDI,[RSP + 0x20] MOVSS dword ptr [RDI],XMM7 MOVSS dword ptr [RDI + 0x4],XMM9 MOVSS dword ptr [RDI + 0x8],XMM6 MULSS XMM6,XMM2 SUBSS XMM6,XMM12 XOR ECX,ECX MOV dword ptr [RDI + 0xc],ECX MOVSS dword ptr [RDI + 0x10],XMM2 UNPCKLPS XMM2,XMM10 MULPS XMM2,XMM4 MULSS XMM4,XMM3 MULSS XMM11,XMM1 ADDSS XMM11,XMM4 MOVSS dword ptr [RDI + 0x14],XMM10 MOVSS dword ptr [RDI + 0x18],XMM3 MOV dword ptr [RDI + 0x1c],ECX MOVSS dword ptr [RDI + 0x20],XMM8 MOVSS dword ptr [RDI + 0x24],XMM6 MOVSS dword ptr [RDI + 0x28],XMM5 MULSS XMM5,XMM0 ADDSS XMM5,XMM11 MOVAPS XMM3,xmmword ptr [0x001cf150] XORPS XMM5,XMM3 MOV dword ptr [RDI + 0x2c],ECX UNPCKLPS XMM7,XMM9 SHUFPS XMM1,XMM1,0x0 MULPS XMM1,XMM7 ADDPS XMM1,XMM2 UNPCKLPS XMM8,XMM6 UNPCKLPS XMM0,XMM0 MULPS XMM0,XMM8 ADDPS XMM0,XMM1 XORPS XMM0,XMM3 MOVLPS qword ptr [RDI + 0x30],XMM0 MOVSS dword ptr [RDI + 0x38],XMM5 MOV dword ptr [RDI + 0x3c],EAX CALL 0x00160a3f MOV EDI,0xb71 ADD RSP,0x60 POP RBX JMP qword ptr [0x00239830]
/* WARNING: Globals starting with '_' overlap smaller symbols at the same address */ void BeginMode3D(void) { int4 *puVar1; ulong uVar2; ulong uVar3; double dVar4; double dVar5; int8 in_stack_00000028; int in_stack_00000030; rlDrawRenderBatch(RLGL); DAT_0023b160 = &DAT_0023b1a8; DAT_0023b15c = 0x1701; rlPushMatrix(); puVar1 = DAT_0023b160; *DAT_0023b160 = 0x3f800000; *(int8 *)(puVar1 + 1) = 0; *(int8 *)(puVar1 + 3) = 0; puVar1[5] = 0x3f800000; *(int8 *)(puVar1 + 6) = 0; *(int8 *)(puVar1 + 8) = 0; puVar1[10] = 0x3f800000; *(int8 *)(puVar1 + 0xb) = 0; *(int8 *)(puVar1 + 0xd) = 0; puVar1[0xf] = 0x3f800000; dVar5 = rlCullDistanceNear; uVar2 = (ulong)_DAT_0023bbfc; uVar3 = (ulong)_DAT_0023bc00; if (in_stack_00000030 == 1) { dVar4 = (double)in_stack_00000028._4_4_ * DAT_001d3cb0; dVar5 = (double)((float)uVar2 / (float)uVar3) * dVar4; rlOrtho(SUB84(dVar5,0) ^ (uint)_DAT_001cf360,dVar5,_DAT_001cf360 ^ (ulong)dVar4,dVar4, rlCullDistanceNear,rlCullDistanceFar); } else if (in_stack_00000030 == 0) { dVar4 = tan((double)in_stack_00000028._4_4_ * DAT_001d3cb0 * _DAT_001de8b0); dVar5 = dVar5 * dVar4; dVar4 = (double)((float)uVar2 / (float)uVar3) * dVar5; rlFrustum(SUB84(dVar4,0) ^ (uint)_DAT_001cf360,dVar4,_DAT_001cf360 ^ (ulong)dVar5,dVar5, rlCullDistanceNear,rlCullDistanceFar); } DAT_0023b160 = &DAT_0023b168; DAT_0023b15c = 0x1700; DAT_0023b168 = 0x3f800000; _DAT_0023b16c = 0; _DAT_0023b174 = 0; DAT_0023b17c = 0x3f800000; _DAT_0023b180 = 0; _DAT_0023b188 = 0; DAT_0023b190 = 0x3f800000; _DAT_0023b194 = 0; _DAT_0023b19c = 0; DAT_0023b1a4 = 0x3f800000; rlMultMatrixf(); /* WARNING: Could not recover jumptable at 0x001739c3. Too many branches */ /* WARNING: Treating indirect jump as call */ (*glad_glEnable)(0xb71); return; }
27,549
js_proxy_mark
bluesky950520[P]quickjs/quickjs.c
static void js_proxy_mark(JSRuntime *rt, JSValue val, JS_MarkFunc *mark_func) { JSProxyData *s = JS_GetOpaque(val, JS_CLASS_PROXY); if (s) { JS_MarkValue(rt, s->target, mark_func); JS_MarkValue(rt, s->handler, mark_func); } }
O1
c
js_proxy_mark: pushq %r15 pushq %r14 pushq %r12 pushq %rbx pushq %rax movq %rcx, %rbx movq %rdi, %r14 movq %rsi, (%rsp) cmpl $-0x1, %edx jne 0x4e12f movq (%rsp), %rax cmpw $0x30, 0x6(%rax) jne 0x4e12f movq 0x30(%rax), %r15 jmp 0x4e132 xorl %r15d, %r15d testq %r15, %r15 je 0x4e17c movl $0xfffffffe, %r12d # imm = 0xFFFFFFFE movsd (%r15), %xmm0 movl 0x8(%r15), %eax movsd %xmm0, (%rsp) andl $-0x2, %eax cmpl %r12d, %eax jne 0x4e15c movq (%rsp), %rsi movq %r14, %rdi callq *%rbx movsd 0x10(%r15), %xmm0 movl 0x18(%r15), %eax movsd %xmm0, (%rsp) andl $-0x2, %eax cmpl %r12d, %eax jne 0x4e17c movq (%rsp), %rsi movq %r14, %rdi callq *%rbx addq $0x8, %rsp popq %rbx popq %r12 popq %r14 popq %r15 retq
js_proxy_mark: push r15 push r14 push r12 push rbx push rax mov rbx, rcx mov r14, rdi mov [rsp+28h+var_28], rsi cmp edx, 0FFFFFFFFh jnz short loc_4E12F mov rax, [rsp+28h+var_28] cmp word ptr [rax+6], 30h ; '0' jnz short loc_4E12F mov r15, [rax+30h] jmp short loc_4E132 loc_4E12F: xor r15d, r15d loc_4E132: test r15, r15 jz short loc_4E17C mov r12d, 0FFFFFFFEh movsd xmm0, qword ptr [r15] mov eax, [r15+8] movsd [rsp+28h+var_28], xmm0 and eax, 0FFFFFFFEh cmp eax, r12d jnz short loc_4E15C mov rsi, [rsp+28h+var_28] mov rdi, r14 call rbx loc_4E15C: movsd xmm0, qword ptr [r15+10h] mov eax, [r15+18h] movsd [rsp+28h+var_28], xmm0 and eax, 0FFFFFFFEh cmp eax, r12d jnz short loc_4E17C mov rsi, [rsp+28h+var_28] mov rdi, r14 call rbx loc_4E17C: add rsp, 8 pop rbx pop r12 pop r14 pop r15 retn
long long js_proxy_mark(long long a1, long long a2, int a3, void ( *a4)(long long, _QWORD)) { long long result; // rax long long v6; // r15 if ( a3 == -1 && (result = a2, *(_WORD *)(a2 + 6) == 48) ) v6 = *(_QWORD *)(a2 + 48); else v6 = 0LL; if ( v6 ) { if ( (*(_DWORD *)(v6 + 8) & 0xFFFFFFFE) == 0xFFFFFFFE ) a4(a1, *(_QWORD *)v6); result = *(_DWORD *)(v6 + 24) & 0xFFFFFFFE; if ( (_DWORD)result == -2 ) return ((long long ( *)(long long, _QWORD))a4)(a1, *(_QWORD *)(v6 + 16)); } return result; }
27,550
js_proxy_mark
bluesky950520[P]quickjs/quickjs.c
static void js_proxy_mark(JSRuntime *rt, JSValue val, JS_MarkFunc *mark_func) { JSProxyData *s = JS_GetOpaque(val, JS_CLASS_PROXY); if (s) { JS_MarkValue(rt, s->target, mark_func); JS_MarkValue(rt, s->handler, mark_func); } }
O2
c
js_proxy_mark: pushq %r15 pushq %r14 pushq %r12 pushq %rbx pushq %rax cmpl $-0x1, %edx jne 0x42f2d cmpw $0x30, 0x6(%rsi) jne 0x42f2d movq 0x30(%rsi), %r14 testq %r14, %r14 je 0x42f2d movq %rdi, %rbx movl $0xfffffffe, %r15d # imm = 0xFFFFFFFE movl 0x8(%r14), %eax andl $-0x2, %eax cmpl %r15d, %eax jne 0x42f0d movq (%r14), %rsi movq %rbx, %rdi movq %rcx, %r12 callq *%rcx movq %r12, %rcx movl 0x18(%r14), %eax andl $-0x2, %eax cmpl %r15d, %eax jne 0x42f2d movq 0x10(%r14), %rsi movq %rbx, %rdi addq $0x8, %rsp popq %rbx popq %r12 popq %r14 popq %r15 jmpq *%rcx addq $0x8, %rsp popq %rbx popq %r12 popq %r14 popq %r15 retq
js_proxy_mark: push r15 push r14 push r12 push rbx push rax cmp edx, 0FFFFFFFFh jnz short loc_42F2D cmp word ptr [rsi+6], 30h ; '0' jnz short loc_42F2D mov r14, [rsi+30h] test r14, r14 jz short loc_42F2D mov rbx, rdi mov r15d, 0FFFFFFFEh mov eax, [r14+8] and eax, 0FFFFFFFEh cmp eax, r15d jnz short loc_42F0D mov rsi, [r14] mov rdi, rbx mov r12, rcx call rcx mov rcx, r12 loc_42F0D: mov eax, [r14+18h] and eax, 0FFFFFFFEh cmp eax, r15d jnz short loc_42F2D mov rsi, [r14+10h] mov rdi, rbx add rsp, 8 pop rbx pop r12 pop r14 pop r15 jmp rcx loc_42F2D: add rsp, 8 pop rbx pop r12 pop r14 pop r15 retn
long long js_proxy_mark(long long a1, long long a2, int a3, void ( *a4)(_QWORD, _QWORD)) { long long v4; // r14 void ( *v5)(_QWORD, _QWORD); // r12 long long result; // rax if ( a3 == -1 && *(_WORD *)(a2 + 6) == 48 ) { v4 = *(_QWORD *)(a2 + 48); if ( v4 ) { if ( (*(_DWORD *)(v4 + 8) & 0xFFFFFFFE) == 0xFFFFFFFE ) { v5 = a4; a4(a1, *(_QWORD *)v4); a4 = v5; } result = *(_DWORD *)(v4 + 24) & 0xFFFFFFFE; if ( (_DWORD)result == -2 ) return ((long long ( *)(long long, _QWORD))a4)(a1, *(_QWORD *)(v4 + 16)); } } return result; }
js_proxy_mark: PUSH R15 PUSH R14 PUSH R12 PUSH RBX PUSH RAX CMP EDX,-0x1 JNZ 0x00142f2d CMP word ptr [RSI + 0x6],0x30 JNZ 0x00142f2d MOV R14,qword ptr [RSI + 0x30] TEST R14,R14 JZ 0x00142f2d MOV RBX,RDI MOV R15D,0xfffffffe MOV EAX,dword ptr [R14 + 0x8] AND EAX,0xfffffffe CMP EAX,R15D JNZ 0x00142f0d MOV RSI,qword ptr [R14] MOV RDI,RBX MOV R12,RCX CALL RCX MOV RCX,R12 LAB_00142f0d: MOV EAX,dword ptr [R14 + 0x18] AND EAX,0xfffffffe CMP EAX,R15D JNZ 0x00142f2d MOV RSI,qword ptr [R14 + 0x10] MOV RDI,RBX ADD RSP,0x8 POP RBX POP R12 POP R14 POP R15 JMP RCX LAB_00142f2d: ADD RSP,0x8 POP RBX POP R12 POP R14 POP R15 RET
void js_proxy_mark(int8 param_1,long param_2,int param_3,code *UNRECOVERED_JUMPTABLE) { int8 *puVar1; int4 extraout_EDX; int4 uVar2; if (((param_3 == -1) && (*(short *)(param_2 + 6) == 0x30)) && (puVar1 = *(int8 **)(param_2 + 0x30), puVar1 != (int8 *)0x0)) { uVar2 = 0xffffffff; if ((*(uint *)(puVar1 + 1) & 0xfffffffe) == 0xfffffffe) { (*UNRECOVERED_JUMPTABLE)(param_1,*puVar1); uVar2 = extraout_EDX; } if ((*(uint *)(puVar1 + 3) & 0xfffffffe) == 0xfffffffe) { /* WARNING: Could not recover jumptable at 0x00142f2b. Too many branches */ /* WARNING: Treating indirect jump as call */ (*UNRECOVERED_JUMPTABLE)(param_1,puVar1[2],uVar2,UNRECOVERED_JUMPTABLE); return; } } return; }
27,551
get_length
eloqsql/strings/my_vsnprintf.c
static const char *get_length(const char *fmt, size_t *length, uint *pre_zero) { for (; my_isdigit(&my_charset_latin1, *fmt); fmt++) { *length= *length * 10 + (uint)(*fmt - '0'); if (!*length) *pre_zero|= PREZERO_ARG; /* first digit was 0 */ } return fmt; }
O0
c
get_length: pushq %rbp movq %rsp, %rbp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq %rdx, -0x18(%rbp) leaq 0x21a9a9(%rip), %rax # 0x366150 movq 0x40(%rax), %rax movq -0x8(%rbp), %rcx movzbl (%rcx), %ecx movzbl 0x1(%rax,%rcx), %eax andl $0x4, %eax cmpl $0x0, %eax je 0x14b802 movq -0x10(%rbp), %rax imulq $0xa, (%rax), %rcx movq -0x8(%rbp), %rax movsbl (%rax), %eax subl $0x30, %eax movl %eax, %eax addq %rax, %rcx movq -0x10(%rbp), %rax movq %rcx, (%rax) movq -0x10(%rbp), %rax cmpq $0x0, (%rax) jne 0x14b7f2 movq -0x18(%rbp), %rax movl (%rax), %ecx orl $0x4, %ecx movl %ecx, (%rax) jmp 0x14b7f4 movq -0x8(%rbp), %rax addq $0x1, %rax movq %rax, -0x8(%rbp) jmp 0x14b7a0 movq -0x8(%rbp), %rax popq %rbp retq nopl (%rax,%rax)
get_length: push rbp mov rbp, rsp mov [rbp+var_8], rdi mov [rbp+var_10], rsi mov [rbp+var_18], rdx loc_14B7A0: lea rax, my_charset_latin1 mov rax, [rax+40h] mov rcx, [rbp+var_8] movzx ecx, byte ptr [rcx] movzx eax, byte ptr [rax+rcx+1] and eax, 4 cmp eax, 0 jz short loc_14B802 mov rax, [rbp+var_10] imul rcx, [rax], 0Ah mov rax, [rbp+var_8] movsx eax, byte ptr [rax] sub eax, 30h ; '0' mov eax, eax add rcx, rax mov rax, [rbp+var_10] mov [rax], rcx mov rax, [rbp+var_10] cmp qword ptr [rax], 0 jnz short loc_14B7F2 mov rax, [rbp+var_18] mov ecx, [rax] or ecx, 4 mov [rax], ecx loc_14B7F2: jmp short $+2 loc_14B7F4: mov rax, [rbp+var_8] add rax, 1 mov [rbp+var_8], rax jmp short loc_14B7A0 loc_14B802: mov rax, [rbp+var_8] pop rbp retn
unsigned __int8 * get_length(unsigned __int8 *a1, _QWORD *a2, _DWORD *a3) { while ( (*(_BYTE *)(*(_QWORD *)&my_charset_latin1[16] + *a1 + 1LL) & 4) != 0 ) { *a2 = (unsigned int)((char)*a1 - 48) + 10LL * *a2; if ( !*a2 ) *a3 |= 4u; ++a1; } return a1; }
inline_mysql_file_seek: PUSH RBP MOV RBP,RSP SUB RSP,0x90 MOV qword ptr [RBP + -0x10],RDI MOV dword ptr [RBP + -0x14],ESI MOV dword ptr [RBP + -0x18],EDX MOV qword ptr [RBP + -0x20],RCX MOV dword ptr [RBP + -0x24],R8D MOV qword ptr [RBP + -0x30],R9 LEA RAX,[0x3c0238] MOV RAX,qword ptr [RAX] MOV RAX,qword ptr [RAX + 0x158] MOV ESI,dword ptr [RBP + -0x18] LEA RDI,[RBP + -0x88] MOV EDX,0x8 CALL RAX MOV qword ptr [RBP + -0x40],RAX CMP qword ptr [RBP + -0x40],0x0 SETNZ AL AND AL,0x1 MOVZX EAX,AL CMP EAX,0x0 SETNZ AL AND AL,0x1 MOVZX EAX,AL CDQE CMP RAX,0x0 JZ 0x0014b853 LEA RAX,[0x3c0238] MOV RAX,qword ptr [RAX] MOV RAX,qword ptr [RAX + 0x210] MOV RDI,qword ptr [RBP + -0x40] MOV RDX,qword ptr [RBP + -0x10] MOV ECX,dword ptr [RBP + -0x14] XOR ESI,ESI CALL RAX MOV EDI,dword ptr [RBP + -0x18] MOV RSI,qword ptr [RBP + -0x20] MOV EDX,dword ptr [RBP + -0x24] MOV RCX,qword ptr [RBP + -0x30] CALL 0x001f4c60 MOV qword ptr [RBP + -0x38],RAX LEA RAX,[0x3c0238] MOV RAX,qword ptr [RAX] MOV RAX,qword ptr [RAX + 0x218] MOV RDI,qword ptr [RBP + -0x40] XOR ECX,ECX MOV ESI,ECX CALL RAX MOV RAX,qword ptr [RBP + -0x38] MOV qword ptr [RBP + -0x8],RAX JMP 0x0014b872 LAB_0014b853: MOV EDI,dword ptr [RBP + -0x18] MOV RSI,qword ptr [RBP + -0x20] MOV EDX,dword ptr [RBP + -0x24] MOV RCX,qword ptr [RBP + -0x30] CALL 0x001f4c60 MOV qword ptr [RBP + -0x38],RAX MOV RAX,qword ptr [RBP + -0x38] MOV qword ptr [RBP + -0x8],RAX LAB_0014b872: MOV RAX,qword ptr [RBP + -0x8] ADD RSP,0x90 POP RBP RET
int8 inline_mysql_file_seek (int8 param_1,int4 param_2,int4 param_3,int8 param_4, int4 param_5,int8 param_6) { int1 local_90 [72]; long local_48; int8 local_40; int8 local_38; int4 local_2c; int8 local_28; int4 local_20; int4 local_1c; int8 local_18; int8 local_10; local_38 = param_6; local_2c = param_5; local_28 = param_4; local_20 = param_3; local_1c = param_2; local_18 = param_1; local_48 = (**(code **)(PSI_server + 0x158))(local_90,param_3,8); if (local_48 == 0) { local_10 = my_seek(local_20,local_28,local_2c,local_38); } else { (**(code **)(PSI_server + 0x210))(local_48,0,local_18,local_1c); local_40 = my_seek(local_20,local_28,local_2c,local_38); (**(code **)(PSI_server + 0x218))(local_48,0); local_10 = local_40; } return local_10; }
27,552
nlohmann::json_abi_v3_11_3::detail::json_sax_dom_callback_parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>::end_object()
monkey531[P]llama/common/json.hpp
bool end_object() { if (ref_stack.back()) { if (!callback(static_cast<int>(ref_stack.size()) - 1, parse_event_t::object_end, *ref_stack.back())) { // discard object *ref_stack.back() = discarded; } else { ref_stack.back()->set_parents(); } } JSON_ASSERT(!ref_stack.empty()); JSON_ASSERT(!keep_stack.empty()); ref_stack.pop_back(); keep_stack.pop_back(); if (!ref_stack.empty() && ref_stack.back() && ref_stack.back()->is_structured()) { // remove discarded value for (auto it = ref_stack.back()->begin(); it != ref_stack.back()->end(); ++it) { if (it->is_discarded()) { ref_stack.back()->erase(it); break; } } } return true; }
O0
cpp
nlohmann::json_abi_v3_11_3::detail::json_sax_dom_callback_parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>::end_object(): subq $0xb8, %rsp movq %rdi, 0xb0(%rsp) movq 0xb0(%rsp), %rdi movq %rdi, 0x18(%rsp) addq $0x8, %rdi callq 0xae1c0 cmpq $0x0, (%rax) je 0xace78 movq 0x18(%rsp), %rdi movq %rdi, %rax addq $0x80, %rax movq %rax, 0x8(%rsp) addq $0x8, %rdi callq 0xadbd0 movq 0x18(%rsp), %rdi subl $0x1, %eax movl %eax, 0x14(%rsp) addq $0x8, %rdi callq 0xae1c0 movq 0x8(%rsp), %rdi movl 0x14(%rsp), %esi movq (%rax), %rcx movl $0x1, %edx callq 0xadb70 testb $0x1, %al jne 0xace60 movq 0x18(%rsp), %rsi addq $0xa8, %rsi leaq 0xa0(%rsp), %rdi callq 0xafbb0 movq 0x18(%rsp), %rdi addq $0x8, %rdi callq 0xae1c0 movq (%rax), %rdi leaq 0xa0(%rsp), %rsi callq 0xa85f0 leaq 0xa0(%rsp), %rdi callq 0x9f450 jmp 0xace76 movq 0x18(%rsp), %rdi addq $0x8, %rdi callq 0xae1c0 movq (%rax), %rdi callq 0xae910 jmp 0xace78 movq 0x18(%rsp), %rdi addq $0x8, %rdi callq 0xae610 testb $0x1, %al jne 0xace8c jmp 0xacead leaq 0x15f51b(%rip), %rdi # 0x20c3ae movl $0x1bbd, %esi # imm = 0x1BBD leaq 0x159337(%rip), %rdx # 0x2061d6 leaq 0x16050e(%rip), %rcx # 0x20d3b4 movb $0x0, %al callq 0x5aee0 movq 0x18(%rsp), %rdi addq $0x20, %rdi callq 0xada50 testb $0x1, %al jne 0xacec1 jmp 0xacee2 leaq 0x15f4e6(%rip), %rdi # 0x20c3ae movl $0x1bbe, %esi # imm = 0x1BBE leaq 0x159302(%rip), %rdx # 0x2061d6 leaq 0x160453(%rip), %rcx # 0x20d32e movb $0x0, %al callq 0x5aee0 movq 0x18(%rsp), %rdi addq $0x8, %rdi callq 0xafda0 movq 0x18(%rsp), %rdi addq $0x20, %rdi callq 0xadb50 movq 0x18(%rsp), %rdi addq $0x8, %rdi callq 0xae610 testb $0x1, %al jne 0xad009 movq 0x18(%rsp), %rdi addq $0x8, %rdi callq 0xae1c0 cmpq $0x0, (%rax) je 0xad009 movq 0x18(%rsp), %rdi addq $0x8, %rdi callq 0xae1c0 movq (%rax), %rdi callq 0xafdc0 testb $0x1, %al jne 0xacf4b jmp 0xad009 movq 0x18(%rsp), %rdi addq $0x8, %rdi callq 0xae1c0 movq (%rax), %rsi leaq 0x80(%rsp), %rdi callq 0xafe00 movq 0x18(%rsp), %rdi addq $0x8, %rdi callq 0xae1c0 movq (%rax), %rsi leaq 0x60(%rsp), %rdi callq 0xafe70 leaq 0x80(%rsp), %rdi leaq 0x60(%rsp), %rsi callq 0xafe40 testb $0x1, %al jne 0xacf9c jmp 0xad007 leaq 0x80(%rsp), %rdi callq 0xafeb0 movq %rax, %rdi callq 0xa8670 testb $0x1, %al jne 0xacfb7 jmp 0xacff3 movq 0x18(%rsp), %rdi addq $0x8, %rdi callq 0xae1c0 movq (%rax), %rax movq %rax, (%rsp) leaq 0x40(%rsp), %rdi leaq 0x80(%rsp), %rsi callq 0xb0670 movq (%rsp), %rsi leaq 0x20(%rsp), %rdi leaq 0x40(%rsp), %rdx callq 0xb0120 jmp 0xad007 jmp 0xacff5 leaq 0x80(%rsp), %rdi callq 0xb06b0 jmp 0xacf69 jmp 0xad009 movb $0x1, %al andb $0x1, %al addq $0xb8, %rsp retq nopw %cs:(%rax,%rax) nop
_ZN8nlohmann16json_abi_v3_11_36detail28json_sax_dom_callback_parserINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE10end_objectEv: sub rsp, 0B8h mov qword ptr [rsp+0B8h+var_8], rdi; int mov rdi, qword ptr [rsp+0B8h+var_8] mov qword ptr [rsp+0B8h+var_A0], rdi; int add rdi, 8 call _ZNSt6vectorIPN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapES_NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES_IhSaIhEEvEESaISE_EE4backEv; std::vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> *,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> *>>::back(void) cmp qword ptr [rax], 0 jz loc_ACE78 mov rdi, qword ptr [rsp+0B8h+var_A0] mov rax, rdi add rax, 80h mov [rsp+0B8h+var_B0], rax add rdi, 8 call _ZNKSt6vectorIPN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapES_NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES_IhSaIhEEvEESaISE_EE4sizeEv; std::vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> *,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> *>>::size(void) mov rdi, qword ptr [rsp+0B8h+var_A0] sub eax, 1 mov [rsp+0B8h+var_A4], eax add rdi, 8 call _ZNSt6vectorIPN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapES_NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES_IhSaIhEEvEESaISE_EE4backEv; std::vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> *,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> *>>::back(void) mov rdi, [rsp+0B8h+var_B0] mov esi, [rsp+0B8h+var_A4] mov rcx, [rax] mov edx, 1 call _ZNKSt8functionIFbiN8nlohmann16json_abi_v3_11_36detail13parse_event_tERNS1_10basic_jsonINS1_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES6_IhSaIhEEvEEEEclEiS3_SH_; std::function<bool ()(int,nlohmann::json_abi_v3_11_3::detail::parse_event_t,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> &)>::operator()(int,nlohmann::json_abi_v3_11_3::detail::parse_event_t,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> &) test al, 1 jnz short loc_ACE60 mov rsi, qword ptr [rsp+0B8h+var_A0] add rsi, 0A8h lea rdi, [rsp+0B8h+var_18] 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&) mov rdi, qword ptr [rsp+0B8h+var_A0] add rdi, 8 call _ZNSt6vectorIPN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapES_NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES_IhSaIhEEvEESaISE_EE4backEv; std::vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> *,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> *>>::back(void) mov rdi, [rax] lea rsi, [rsp+0B8h+var_18] 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>) lea rdi, [rsp+0B8h+var_18] call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvED2Ev; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::~basic_json() jmp short loc_ACE76 loc_ACE60: mov rdi, qword ptr [rsp+0B8h+var_A0] add rdi, 8 call _ZNSt6vectorIPN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapES_NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES_IhSaIhEEvEESaISE_EE4backEv; std::vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> *,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> *>>::back(void) mov rdi, [rax] call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE11set_parentsEv; 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>::set_parents(void) loc_ACE76: jmp short $+2 loc_ACE78: mov rdi, qword ptr [rsp+0B8h+var_A0] add rdi, 8 call _ZNKSt6vectorIPN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapES_NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES_IhSaIhEEvEESaISE_EE5emptyEv; std::vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> *,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> *>>::empty(void) test al, 1 jnz short loc_ACE8C jmp short loc_ACEAD loc_ACE8C: lea rdi, aWorkspaceLlm4b_1; "/workspace/llm4binary/github/2025_star3"... mov esi, 1BBDh lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aRefStackEmpty; "!ref_stack.empty()" mov al, 0 call _ggml_abort loc_ACEAD: mov rdi, qword ptr [rsp+0B8h+var_A0] add rdi, 20h ; ' ' call _ZNKSt6vectorIbSaIbEE5emptyEv; std::vector<bool>::empty(void) test al, 1 jnz short loc_ACEC1 jmp short loc_ACEE2 loc_ACEC1: lea rdi, aWorkspaceLlm4b_1; "/workspace/llm4binary/github/2025_star3"... mov esi, 1BBEh lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aKeepStackEmpty; "!keep_stack.empty()" mov al, 0 call _ggml_abort loc_ACEE2: mov rdi, qword ptr [rsp+0B8h+var_A0] add rdi, 8 call _ZNSt6vectorIPN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapES_NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES_IhSaIhEEvEESaISE_EE8pop_backEv; std::vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> *,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> *>>::pop_back(void) mov rdi, qword ptr [rsp+0B8h+var_A0] add rdi, 20h ; ' ' call _ZNSt6vectorIbSaIbEE8pop_backEv; std::vector<bool>::pop_back(void) mov rdi, qword ptr [rsp+0B8h+var_A0] add rdi, 8 call _ZNKSt6vectorIPN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapES_NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES_IhSaIhEEvEESaISE_EE5emptyEv; std::vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> *,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> *>>::empty(void) test al, 1 jnz loc_AD009 mov rdi, qword ptr [rsp+0B8h+var_A0] add rdi, 8 call _ZNSt6vectorIPN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapES_NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES_IhSaIhEEvEESaISE_EE4backEv; std::vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> *,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> *>>::back(void) cmp qword ptr [rax], 0 jz loc_AD009 mov rdi, qword ptr [rsp+0B8h+var_A0] add rdi, 8 call _ZNSt6vectorIPN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapES_NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES_IhSaIhEEvEESaISE_EE4backEv; std::vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> *,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> *>>::back(void) mov rdi, [rax] call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE13is_structuredEv; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::is_structured(void) test al, 1 jnz short loc_ACF4B jmp loc_AD009 loc_ACF4B: mov rdi, qword ptr [rsp+0B8h+var_A0] add rdi, 8 call _ZNSt6vectorIPN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapES_NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES_IhSaIhEEvEESaISE_EE4backEv; std::vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> *,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> *>>::back(void) mov rsi, [rax] lea rdi, [rsp+0B8h+var_38] call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE5beginEv; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::begin(void) loc_ACF69: mov rdi, qword ptr [rsp+0B8h+var_A0] add rdi, 8 call _ZNSt6vectorIPN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapES_NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES_IhSaIhEEvEESaISE_EE4backEv; std::vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> *,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> *>>::back(void) mov rsi, [rax] lea rdi, [rsp+0B8h+var_58] call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE3endEv; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::end(void) lea rdi, [rsp+0B8h+var_38]; int lea rsi, [rsp+0B8h+var_58]; void * call _ZNK8nlohmann16json_abi_v3_11_36detail9iter_implINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEneISG_TnNSt9enable_ifIXoosr3std7is_sameIT_SG_EE5valuesr3std7is_sameISJ_NS2_IKSF_EEEE5valueEDnE4typeELDn0EEEbRKSJ_ test al, 1 jnz short loc_ACF9C jmp short loc_AD007 loc_ACF9C: lea rdi, [rsp+0B8h+var_38]; int call _ZNK8nlohmann16json_abi_v3_11_36detail9iter_implINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEptEv; 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>>::operator->(void) mov rdi, rax call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE12is_discardedEv; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::is_discarded(void) test al, 1 jnz short loc_ACFB7 jmp short loc_ACFF3 loc_ACFB7: mov rdi, qword ptr [rsp+0B8h+var_A0] add rdi, 8 call _ZNSt6vectorIPN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapES_NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES_IhSaIhEEvEESaISE_EE4backEv; std::vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> *,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> *>>::back(void) mov rax, [rax] mov [rsp+0B8h+var_B8], rax; void * lea rdi, [rsp+0B8h+var_78] lea rsi, [rsp+0B8h+var_38] call _ZN8nlohmann16json_abi_v3_11_36detail9iter_implINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEC2ERKSG_; 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>>::iter_impl(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&) mov rsi, [rsp+0B8h+var_B8] lea rdi, [rsp+0B8h+var_98]; int lea rdx, [rsp+0B8h+var_78] call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE5eraseINS0_6detail9iter_implISD_EETnNSt9enable_ifIXoosr3std7is_sameIT_SH_EE5valuesr3std7is_sameISJ_NSG_IKSD_EEEE5valueEiE4typeELi0EEESJ_SJ_ jmp short loc_AD007 loc_ACFF3: jmp short $+2 loc_ACFF5: lea rdi, [rsp+0B8h+var_38] call _ZN8nlohmann16json_abi_v3_11_36detail9iter_implINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEppEv; 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>>::operator++(void) jmp loc_ACF69 loc_AD007: jmp short $+2 loc_AD009: mov al, 1 and al, 1 add rsp, 0B8h retn
end_object: SUB RSP,0xb8 MOV qword ptr [RSP + 0xb0],RDI MOV RDI,qword ptr [RSP + 0xb0] MOV qword ptr [RSP + 0x18],RDI ADD RDI,0x8 CALL 0x001ae1c0 CMP qword ptr [RAX],0x0 JZ 0x001ace78 MOV RDI,qword ptr [RSP + 0x18] MOV RAX,RDI ADD RAX,0x80 MOV qword ptr [RSP + 0x8],RAX ADD RDI,0x8 CALL 0x001adbd0 MOV RDI,qword ptr [RSP + 0x18] SUB EAX,0x1 MOV dword ptr [RSP + 0x14],EAX ADD RDI,0x8 CALL 0x001ae1c0 MOV RDI,qword ptr [RSP + 0x8] MOV ESI,dword ptr [RSP + 0x14] MOV RCX,qword ptr [RAX] MOV EDX,0x1 CALL 0x001adb70 TEST AL,0x1 JNZ 0x001ace60 MOV RSI,qword ptr [RSP + 0x18] ADD RSI,0xa8 LEA RDI,[RSP + 0xa0] CALL 0x001afbb0 MOV RDI,qword ptr [RSP + 0x18] ADD RDI,0x8 CALL 0x001ae1c0 MOV RDI,qword ptr [RAX] LEA RSI,[RSP + 0xa0] CALL 0x001a85f0 LEA RDI,[RSP + 0xa0] CALL 0x0019f450 JMP 0x001ace76 LAB_001ace60: MOV RDI,qword ptr [RSP + 0x18] ADD RDI,0x8 CALL 0x001ae1c0 MOV RDI,qword ptr [RAX] CALL 0x001ae910 LAB_001ace76: JMP 0x001ace78 LAB_001ace78: MOV RDI,qword ptr [RSP + 0x18] ADD RDI,0x8 CALL 0x001ae610 TEST AL,0x1 JNZ 0x001ace8c JMP 0x001acead LAB_001ace8c: LEA RDI,[0x30c3ae] MOV ESI,0x1bbd LEA RDX,[0x3061d6] LEA RCX,[0x30d3b4] MOV AL,0x0 CALL 0x0015aee0 LAB_001acead: MOV RDI,qword ptr [RSP + 0x18] ADD RDI,0x20 CALL 0x001ada50 TEST AL,0x1 JNZ 0x001acec1 JMP 0x001acee2 LAB_001acec1: LEA RDI,[0x30c3ae] MOV ESI,0x1bbe LEA RDX,[0x3061d6] LEA RCX,[0x30d32e] MOV AL,0x0 CALL 0x0015aee0 LAB_001acee2: MOV RDI,qword ptr [RSP + 0x18] ADD RDI,0x8 CALL 0x001afda0 MOV RDI,qword ptr [RSP + 0x18] ADD RDI,0x20 CALL 0x001adb50 MOV RDI,qword ptr [RSP + 0x18] ADD RDI,0x8 CALL 0x001ae610 TEST AL,0x1 JNZ 0x001ad009 MOV RDI,qword ptr [RSP + 0x18] ADD RDI,0x8 CALL 0x001ae1c0 CMP qword ptr [RAX],0x0 JZ 0x001ad009 MOV RDI,qword ptr [RSP + 0x18] ADD RDI,0x8 CALL 0x001ae1c0 MOV RDI,qword ptr [RAX] CALL 0x001afdc0 TEST AL,0x1 JNZ 0x001acf4b JMP 0x001ad009 LAB_001acf4b: MOV RDI,qword ptr [RSP + 0x18] ADD RDI,0x8 CALL 0x001ae1c0 MOV RSI,qword ptr [RAX] LEA RDI,[RSP + 0x80] CALL 0x001afe00 LAB_001acf69: MOV RDI,qword ptr [RSP + 0x18] ADD RDI,0x8 CALL 0x001ae1c0 MOV RSI,qword ptr [RAX] LEA RDI,[RSP + 0x60] CALL 0x001afe70 LEA RDI,[RSP + 0x80] LEA RSI,[RSP + 0x60] CALL 0x001afe40 TEST AL,0x1 JNZ 0x001acf9c JMP 0x001ad007 LAB_001acf9c: LEA RDI,[RSP + 0x80] CALL 0x001afeb0 MOV RDI,RAX CALL 0x001a8670 TEST AL,0x1 JNZ 0x001acfb7 JMP 0x001acff3 LAB_001acfb7: MOV RDI,qword ptr [RSP + 0x18] ADD RDI,0x8 CALL 0x001ae1c0 MOV RAX,qword ptr [RAX] MOV qword ptr [RSP],RAX LEA RDI,[RSP + 0x40] LEA RSI,[RSP + 0x80] CALL 0x001b0670 MOV RSI,qword ptr [RSP] LEA RDI,[RSP + 0x20] LEA RDX,[RSP + 0x40] CALL 0x001b0120 JMP 0x001ad007 LAB_001acff3: JMP 0x001acff5 LAB_001acff5: LEA RDI,[RSP + 0x80] CALL 0x001b06b0 JMP 0x001acf69 LAB_001ad007: JMP 0x001ad009 LAB_001ad009: MOV AL,0x1 AND AL,0x1 ADD RSP,0xb8 RET
/* nlohmann::json_abi_v3_11_3::detail::json_sax_dom_callback_parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char> >, void> >::end_object() */ int8 __thiscall nlohmann::json_abi_v3_11_3::detail:: json_sax_dom_callback_parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>> ::end_object(json_sax_dom_callback_parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>> *this) { int8 uVar1; int iVar2; long *plVar3; int8 *puVar4; ulong uVar5; basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,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_00; int1 local_98 [32]; 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>> local_78 [32]; int1 local_58 [32]; 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>> local_38 [32]; basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> local_18 [16]; json_sax_dom_callback_parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>> *local_8; local_8 = this; plVar3 = (long *)std:: vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*>> ::back((vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*>> *)(this + 8)); if (*plVar3 != 0) { iVar2 = std:: vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*>> ::size((vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*>> *)(this + 8)); puVar4 = (int8 *) std:: vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*>> ::back((vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*>> *)(this + 8)); uVar5 = std:: function<bool(int,nlohmann::json_abi_v3_11_3::detail::parse_event_t,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>&)> ::operator()((function<bool(int,nlohmann::json_abi_v3_11_3::detail::parse_event_t,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>&)> *)(this + 0x80),iVar2 + -1,1,*puVar4); if ((uVar5 & 1) == 0) { basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> ::basic_json(local_18,this + 0xa8); puVar4 = (int8 *) std:: vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*>> ::back((vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*>> *)(this + 8)); basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,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> *)*puVar4,local_18); basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> ::~basic_json(local_18); } else { std:: vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*>> ::back((vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*>> *)(this + 8)); basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> ::set_parents(); } } uVar5 = std:: vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*>> ::empty((vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*>> *)(this + 8)); if ((uVar5 & 1) != 0) { ggml_abort("/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",0x1bbd, "GGML_ASSERT(%s) failed","!ref_stack.empty()"); } uVar5 = std::vector<bool,std::allocator<bool>>::empty ((vector<bool,std::allocator<bool>> *)(this + 0x20)); if ((uVar5 & 1) != 0) { ggml_abort("/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",0x1bbe, "GGML_ASSERT(%s) failed","!keep_stack.empty()"); } 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>*>> ::pop_back((vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*>> *)(this + 8)); std::vector<bool,std::allocator<bool>>::pop_back ((vector<bool,std::allocator<bool>> *)(this + 0x20)); uVar5 = std:: vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*>> ::empty((vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*>> *)(this + 8)); if (((uVar5 & 1) == 0) && (plVar3 = (long *)std:: vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*>> ::back((vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*>> *)(this + 8)), *plVar3 != 0)) { puVar4 = (int8 *) std:: vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*>> ::back((vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*>> *)(this + 8)); uVar5 = basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> ::is_structured((basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> *)*puVar4); if ((uVar5 & 1) != 0) { std:: vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*>> ::back((vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*>> *)(this + 8)); basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> ::begin(); while( true ) { std:: vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*>> ::back((vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*>> *)(this + 8)); basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> ::end(); uVar5 = _ZNK8nlohmann16json_abi_v3_11_36detail9iter_implINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEneISG_TnNSt9enable_ifIXoosr3std7is_sameIT_SG_EE5valuesr3std7is_sameISJ_NS2_IKSF_EEEE5valueEDnE4typeELDn0EEEbRKSJ_ (local_38,local_58); if ((uVar5 & 1) == 0) break; this_00 = (basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> *)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>> ::operator->(local_38); uVar5 = basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> ::is_discarded(this_00); if ((uVar5 & 1) != 0) { puVar4 = (int8 *) std:: vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*>> ::back((vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>*>> *)(this + 8)); uVar1 = *puVar4; 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>> ::iter_impl(local_78,(iter_impl *)local_38); _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE5eraseINS0_6detail9iter_implISD_EETnNSt9enable_ifIXoosr3std7is_sameIT_SH_EE5valuesr3std7is_sameISJ_NSG_IKSD_EEEE5valueEiE4typeELi0EEESJ_SJ_ (local_98,uVar1,local_78); return 1; } 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>> ::operator++(local_38); } } } return 1; }
27,553
nlohmann::json_abi_v3_11_3::detail::json_sax_dom_callback_parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>::end_object()
monkey531[P]llama/common/json.hpp
bool end_object() { if (ref_stack.back()) { if (!callback(static_cast<int>(ref_stack.size()) - 1, parse_event_t::object_end, *ref_stack.back())) { // discard object *ref_stack.back() = discarded; } else { ref_stack.back()->set_parents(); } } JSON_ASSERT(!ref_stack.empty()); JSON_ASSERT(!keep_stack.empty()); ref_stack.pop_back(); keep_stack.pop_back(); if (!ref_stack.empty() && ref_stack.back() && ref_stack.back()->is_structured()) { // remove discarded value for (auto it = ref_stack.back()->begin(); it != ref_stack.back()->end(); ++it) { if (it->is_discarded()) { ref_stack.back()->erase(it); break; } } } return true; }
O3
cpp
nlohmann::json_abi_v3_11_3::detail::json_sax_dom_callback_parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>::end_object(): pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x78, %rsp movq %rdi, %rbx movq 0x10(%rdi), %rax movq -0x8(%rax), %rcx testq %rcx, %rcx je 0x5bbdc subq 0x8(%rbx), %rax shrq $0x3, %rax decl %eax movl %eax, 0x28(%rsp) movb $0x1, 0x8(%rsp) cmpq $0x0, 0x90(%rbx) je 0x5bd87 leaq 0x80(%rbx), %rdi leaq 0x28(%rsp), %rsi leaq 0x8(%rsp), %rdx callq *0x98(%rbx) testb %al, %al jne 0x5bbdc leaq 0xa8(%rbx), %rsi leaq 0x48(%rsp), %r14 movq %r14, %rdi callq 0x5ce86 movq 0x10(%rbx), %rax movq -0x8(%rax), %rdi movq %r14, %rsi callq 0x5a686 movq %r14, %rdi xorl %esi, %esi callq 0x57ee4 movq %r14, %rdi callq 0x5d352 movq 0x8(%rbx), %rcx movq 0x10(%rbx), %rax cmpq %rax, %rcx je 0x5bd4a movq 0x30(%rbx), %rdx movl 0x38(%rbx), %esi cmpq %rdx, 0x20(%rbx) sete %dil testl %esi, %esi sete %r8b andb %dil, %r8b cmpb $0x1, %r8b je 0x5bd66 leaq -0x8(%rax), %rdi movq %rdi, 0x10(%rbx) subl $0x1, %esi movl %esi, 0x38(%rbx) jae 0x5bc2e movl $0x3f, 0x38(%rbx) addq $-0x8, %rdx movq %rdx, 0x30(%rbx) cmpq %rdi, %rcx je 0x5bd39 movq -0x10(%rax), %rax testq %rax, %rax je 0x5bd39 movb (%rax), %cl decb %cl cmpb $0x1, %cl ja 0x5bd39 movabsq $-0x8000000000000000, %r12 # imm = 0x8000000000000000 leaq 0x28(%rsp), %r14 movq %rax, (%r14) xorps %xmm0, %xmm0 movups %xmm0, 0x8(%r14) movq %r12, 0x18(%r14) movq %r14, %rdi callq 0x5dd72 movq 0x10(%rbx), %rax movq -0x8(%rax), %rax leaq 0x8(%rsp), %r15 movq %rax, (%r15) xorps %xmm0, %xmm0 movups %xmm0, 0x8(%r15) movq %r12, 0x18(%r15) movq %r15, %rdi callq 0x5e0ee movq %r14, %rdi movq %r15, %rsi callq 0x5dde4 testb %al, %al jne 0x5bd39 leaq 0x30(%rsp), %r13 leaq 0x10(%rsp), %rbp leaq 0x28(%rsp), %r14 leaq 0x8(%rsp), %r15 movq %r14, %rdi callq 0x5cf2a cmpb $0x9, (%rax) je 0x5bd09 movq %r14, %rdi callq 0x5d304 movq 0x10(%rbx), %rax movq -0x8(%rax), %rax movq %rax, 0x8(%rsp) xorps %xmm0, %xmm0 movups %xmm0, (%rbp) movq %r12, 0x20(%rsp) movq %r15, %rdi callq 0x5e0ee movq %r14, %rdi movq %r15, %rsi callq 0x5dde4 testb %al, %al je 0x5bcc2 jmp 0x5bd39 movq 0x10(%rbx), %rax movq -0x8(%rax), %rsi movq 0x28(%rsp), %rax leaq 0x58(%rsp), %rdx movq %rax, (%rdx) movups (%r13), %xmm0 movups %xmm0, 0x8(%rdx) movq 0x10(%r13), %rax movq %rax, 0x18(%rdx) leaq 0x8(%rsp), %rdi callq 0x5d076 movb $0x1, %al addq $0x78, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq leaq 0x8f0a2(%rip), %rdi # 0xeadf3 leaq 0x8f0e5(%rip), %rdx # 0xeae3d leaq 0x90096(%rip), %rcx # 0xebdf5 movl $0x1bbd, %esi # imm = 0x1BBD jmp 0x5bd80 leaq 0x8f086(%rip), %rdi # 0xeadf3 leaq 0x8f0c9(%rip), %rdx # 0xeae3d leaq 0x8fff4(%rip), %rcx # 0xebd6f movl $0x1bbe, %esi # imm = 0x1BBE xorl %eax, %eax callq 0x1aeb0 callq 0x1a310
_ZN8nlohmann16json_abi_v3_11_36detail28json_sax_dom_callback_parserINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE10end_objectEv: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 78h mov rbx, rdi mov rax, [rdi+10h] mov rcx, [rax-8] test rcx, rcx jz short loc_5BBDC sub rax, [rbx+8] shr rax, 3 dec eax mov dword ptr [rsp+0A8h+var_80], eax mov byte ptr [rsp+0A8h+var_A0], 1 cmp qword ptr [rbx+90h], 0 jz loc_5BD87 lea rdi, [rbx+80h] lea rsi, [rsp+0A8h+var_80] lea rdx, [rsp+0A8h+var_A0] call qword ptr [rbx+98h] test al, al jnz short loc_5BBDC lea rsi, [rbx+0A8h] lea r14, [rsp+0A8h+var_60] mov rdi, 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&) mov rax, [rbx+10h] mov rdi, [rax-8] 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_5BBDC: mov rcx, [rbx+8] mov rax, [rbx+10h] cmp rcx, rax jz loc_5BD4A mov rdx, [rbx+30h] mov esi, [rbx+38h] cmp [rbx+20h], rdx setz dil test esi, esi setz r8b and r8b, dil cmp r8b, 1 jz loc_5BD66 lea rdi, [rax-8] mov [rbx+10h], rdi sub esi, 1 mov [rbx+38h], esi jnb short loc_5BC2E mov dword ptr [rbx+38h], 3Fh ; '?' add rdx, 0FFFFFFFFFFFFFFF8h mov [rbx+30h], rdx loc_5BC2E: cmp rcx, rdi jz loc_5BD39 mov rax, [rax-10h] test rax, rax jz loc_5BD39 mov cl, [rax] dec cl cmp cl, 1 ja loc_5BD39 mov r12, 8000000000000000h lea r14, [rsp+0A8h+var_80] mov [r14], rax xorps xmm0, xmm0 movups xmmword ptr [r14+8], xmm0 mov [r14+18h], r12 mov rdi, r14 call _ZN8nlohmann16json_abi_v3_11_36detail9iter_implINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE9set_beginEv; 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>>::set_begin(void) mov rax, [rbx+10h] mov rax, [rax-8] lea r15, [rsp+0A8h+var_A0] mov [r15], rax xorps xmm0, xmm0 movups xmmword ptr [r15+8], xmm0 mov [r15+18h], r12 mov rdi, r15 call _ZN8nlohmann16json_abi_v3_11_36detail9iter_implINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE7set_endEv; 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>>::set_end(void) mov rdi, r14 mov rsi, r15 call _ZNK8nlohmann16json_abi_v3_11_36detail9iter_implINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEeqISG_TnNSt9enable_ifIXoosr3std7is_sameIT_SG_EE5valuesr3std7is_sameISJ_NS2_IKSF_EEEE5valueEDnE4typeELDn0EEEbRKSJ_ test al, al jnz loc_5BD39 lea r13, [rsp+0A8h+var_78] lea rbp, [rsp+0A8h+var_98] lea r14, [rsp+0A8h+var_80] lea r15, [rsp+0A8h+var_A0] loc_5BCC2: mov rdi, r14 call _ZNK8nlohmann16json_abi_v3_11_36detail9iter_implINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEptEv; 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>>::operator->(void) cmp byte ptr [rax], 9 jz short loc_5BD09 mov rdi, r14 call _ZN8nlohmann16json_abi_v3_11_36detail9iter_implINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEppEv; 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>>::operator++(void) mov rax, [rbx+10h] mov rax, [rax-8] mov [rsp+0A8h+var_A0], rax xorps xmm0, xmm0 movups xmmword ptr [rbp+0], xmm0 mov [rsp+0A8h+var_88], r12 mov rdi, r15 call _ZN8nlohmann16json_abi_v3_11_36detail9iter_implINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE7set_endEv; 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>>::set_end(void) mov rdi, r14 mov rsi, r15 call _ZNK8nlohmann16json_abi_v3_11_36detail9iter_implINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEeqISG_TnNSt9enable_ifIXoosr3std7is_sameIT_SG_EE5valuesr3std7is_sameISJ_NS2_IKSF_EEEE5valueEDnE4typeELDn0EEEbRKSJ_ test al, al jz short loc_5BCC2 jmp short loc_5BD39 loc_5BD09: mov rax, [rbx+10h] mov rsi, [rax-8] mov rax, [rsp+0A8h+var_80] lea rdx, [rsp+0A8h+var_50] mov [rdx], rax movups xmm0, xmmword ptr [r13+0] movups xmmword ptr [rdx+8], xmm0 mov rax, [r13+10h] mov [rdx+18h], rax lea rdi, [rsp+0A8h+var_A0] call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE5eraseINS0_6detail9iter_implISD_EETnNSt9enable_ifIXoosr3std7is_sameIT_SH_EE5valuesr3std7is_sameISJ_NSG_IKSD_EEEE5valueEiE4typeELi0EEESJ_SJ_ loc_5BD39: mov al, 1 add rsp, 78h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn loc_5BD4A: lea rdi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github/2025_star3"... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aRefStackEmpty; "!ref_stack.empty()" mov esi, 1BBDh jmp short loc_5BD80 loc_5BD66: lea rdi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github/2025_star3"... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aKeepStackEmpty; "!keep_stack.empty()" mov esi, 1BBEh loc_5BD80: xor eax, eax call _ggml_abort loc_5BD87: call __ZSt25__throw_bad_function_callv; std::__throw_bad_function_call(void)
char nlohmann::json_abi_v3_11_3::detail::json_sax_dom_callback_parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>::end_object( long long a1) { long long v1; // rax long long v2; // rcx long long v3; // rax long long v4; // rdx int v5; // esi _BYTE *v6; // rax long long v7; // rsi long long v9; // [rsp+8h] [rbp-A0h] BYREF __int128 v10; // [rsp+10h] [rbp-98h] unsigned long long v11; // [rsp+20h] [rbp-88h] _BYTE *v12; // [rsp+28h] [rbp-80h] BYREF __int128 v13; // [rsp+30h] [rbp-78h] unsigned long long v14; // [rsp+40h] [rbp-68h] char v15[16]; // [rsp+48h] [rbp-60h] BYREF _BYTE *v16; // [rsp+58h] [rbp-50h] __int128 v17; // [rsp+60h] [rbp-48h] unsigned long long v18; // [rsp+70h] [rbp-38h] v1 = *(_QWORD *)(a1 + 16); if ( *(_QWORD *)(v1 - 8) ) { LODWORD(v12) = ((unsigned long long)(v1 - *(_QWORD *)(a1 + 8)) >> 3) - 1; LOBYTE(v9) = 1; if ( !*(_QWORD *)(a1 + 144) ) goto LABEL_20; if ( !(*(unsigned __int8 ( **)(long long, _BYTE **, long long *))(a1 + 152))(a1 + 128, &v12, &v9) ) { nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::basic_json( v15, a1 + 168); nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::operator=( *(_QWORD *)(*(_QWORD *)(a1 + 16) - 8LL), (long long)v15); nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::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); } } v2 = *(_QWORD *)(a1 + 8); v3 = *(_QWORD *)(a1 + 16); if ( v2 == v3 ) { ggml_abort( "/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp", 7101LL, "GGML_ASSERT(%s) failed", "!ref_stack.empty()"); goto LABEL_20; } v4 = *(_QWORD *)(a1 + 48); v5 = *(_DWORD *)(a1 + 56); if ( *(_QWORD *)(a1 + 32) == v4 && v5 == 0 ) { ggml_abort( "/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp", 7102LL, "GGML_ASSERT(%s) failed", "!keep_stack.empty()"); LABEL_20: std::__throw_bad_function_call(); } *(_QWORD *)(a1 + 16) = v3 - 8; *(_DWORD *)(a1 + 56) = v5 - 1; if ( !v5 ) { *(_DWORD *)(a1 + 56) = 63; *(_QWORD *)(a1 + 48) = v4 - 8; } if ( v2 != v3 - 8 ) { v6 = *(_BYTE **)(v3 - 16); if ( v6 ) { if ( (unsigned __int8)(*v6 - 1) <= 1u ) { v12 = v6; v13 = 0LL; v14 = 0x8000000000000000LL; 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,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>::set_begin(&v12); v9 = *(_QWORD *)(*(_QWORD *)(a1 + 16) - 8LL); v10 = 0LL; v11 = 0x8000000000000000LL; 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,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>::set_end(&v9); if ( !(unsigned __int8)ZNK8nlohmann16json_abi_v3_11_36detail9iter_implINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEeqISG_TnNSt9enable_ifIXoosr3std7is_sameIT_SG_EE5valuesr3std7is_sameISJ_NS2_IKSF_EEEE5valueEDnE4typeELDn0EEEbRKSJ_( &v12, &v9) ) { while ( *(_BYTE *)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,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>::operator->(&v12) != 9 ) { 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,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>::operator++(&v12); v9 = *(_QWORD *)(*(_QWORD *)(a1 + 16) - 8LL); v10 = 0LL; v11 = 0x8000000000000000LL; 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,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>::set_end(&v9); if ( (unsigned __int8)ZNK8nlohmann16json_abi_v3_11_36detail9iter_implINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEeqISG_TnNSt9enable_ifIXoosr3std7is_sameIT_SG_EE5valuesr3std7is_sameISJ_NS2_IKSF_EEEE5valueEDnE4typeELDn0EEEbRKSJ_( &v12, &v9) ) return 1; } v7 = *(_QWORD *)(*(_QWORD *)(a1 + 16) - 8LL); v16 = v12; v17 = v13; v18 = v14; ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE5eraseINS0_6detail9iter_implISD_EETnNSt9enable_ifIXoosr3std7is_sameIT_SH_EE5valuesr3std7is_sameISJ_NSG_IKSD_EEEE5valueEiE4typeELi0EEESJ_SJ_( &v9, v7); } } } } return 1; }
end_object: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x78 MOV RBX,RDI MOV RAX,qword ptr [RDI + 0x10] MOV RCX,qword ptr [RAX + -0x8] TEST RCX,RCX JZ 0x0015bbdc SUB RAX,qword ptr [RBX + 0x8] SHR RAX,0x3 DEC EAX MOV dword ptr [RSP + 0x28],EAX MOV byte ptr [RSP + 0x8],0x1 CMP qword ptr [RBX + 0x90],0x0 JZ 0x0015bd87 LEA RDI,[RBX + 0x80] LEA RSI,[RSP + 0x28] LEA RDX,[RSP + 0x8] CALL qword ptr [RBX + 0x98] TEST AL,AL JNZ 0x0015bbdc LEA RSI,[RBX + 0xa8] LEA R14,[RSP + 0x48] MOV RDI,R14 CALL 0x0015ce86 MOV RAX,qword ptr [RBX + 0x10] MOV RDI,qword ptr [RAX + -0x8] MOV RSI,R14 CALL 0x0015a686 MOV RDI,R14 XOR ESI,ESI CALL 0x00157ee4 MOV RDI,R14 CALL 0x0015d352 LAB_0015bbdc: MOV RCX,qword ptr [RBX + 0x8] MOV RAX,qword ptr [RBX + 0x10] CMP RCX,RAX JZ 0x0015bd4a MOV RDX,qword ptr [RBX + 0x30] MOV ESI,dword ptr [RBX + 0x38] CMP qword ptr [RBX + 0x20],RDX SETZ DIL TEST ESI,ESI SETZ R8B AND R8B,DIL CMP R8B,0x1 JZ 0x0015bd66 LEA RDI,[RAX + -0x8] MOV qword ptr [RBX + 0x10],RDI SUB ESI,0x1 MOV dword ptr [RBX + 0x38],ESI JNC 0x0015bc2e MOV dword ptr [RBX + 0x38],0x3f ADD RDX,-0x8 MOV qword ptr [RBX + 0x30],RDX LAB_0015bc2e: CMP RCX,RDI JZ 0x0015bd39 MOV RAX,qword ptr [RAX + -0x10] TEST RAX,RAX JZ 0x0015bd39 MOV CL,byte ptr [RAX] DEC CL CMP CL,0x1 JA 0x0015bd39 MOV R12,-0x8000000000000000 LEA R14,[RSP + 0x28] MOV qword ptr [R14],RAX XORPS XMM0,XMM0 MOVUPS xmmword ptr [R14 + 0x8],XMM0 MOV qword ptr [R14 + 0x18],R12 MOV RDI,R14 CALL 0x0015dd72 MOV RAX,qword ptr [RBX + 0x10] MOV RAX,qword ptr [RAX + -0x8] LEA R15,[RSP + 0x8] MOV qword ptr [R15],RAX XORPS XMM0,XMM0 MOVUPS xmmword ptr [R15 + 0x8],XMM0 MOV qword ptr [R15 + 0x18],R12 MOV RDI,R15 CALL 0x0015e0ee MOV RDI,R14 MOV RSI,R15 CALL 0x0015dde4 TEST AL,AL JNZ 0x0015bd39 LEA R13,[RSP + 0x30] LEA RBP,[RSP + 0x10] LEA R14,[RSP + 0x28] LEA R15,[RSP + 0x8] LAB_0015bcc2: MOV RDI,R14 CALL 0x0015cf2a CMP byte ptr [RAX],0x9 JZ 0x0015bd09 MOV RDI,R14 CALL 0x0015d304 MOV RAX,qword ptr [RBX + 0x10] MOV RAX,qword ptr [RAX + -0x8] MOV qword ptr [RSP + 0x8],RAX XORPS XMM0,XMM0 MOVUPS xmmword ptr [RBP],XMM0 MOV qword ptr [RSP + 0x20],R12 MOV RDI,R15 CALL 0x0015e0ee MOV RDI,R14 MOV RSI,R15 CALL 0x0015dde4 TEST AL,AL JZ 0x0015bcc2 JMP 0x0015bd39 LAB_0015bd09: MOV RAX,qword ptr [RBX + 0x10] MOV RSI,qword ptr [RAX + -0x8] MOV RAX,qword ptr [RSP + 0x28] LEA RDX,[RSP + 0x58] MOV qword ptr [RDX],RAX MOVUPS XMM0,xmmword ptr [R13] MOVUPS xmmword ptr [RDX + 0x8],XMM0 MOV RAX,qword ptr [R13 + 0x10] MOV qword ptr [RDX + 0x18],RAX LEA RDI,[RSP + 0x8] CALL 0x0015d076 LAB_0015bd39: MOV AL,0x1 ADD RSP,0x78 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET LAB_0015bd4a: LEA RDI,[0x1eadf3] LEA RDX,[0x1eae3d] LEA RCX,[0x1ebdf5] MOV ESI,0x1bbd JMP 0x0015bd80 LAB_0015bd66: LEA RDI,[0x1eadf3] LEA RDX,[0x1eae3d] LEA RCX,[0x1ebd6f] MOV ESI,0x1bbe LAB_0015bd80: XOR EAX,EAX CALL 0x0011aeb0 LAB_0015bd87: CALL 0x0011a310
/* nlohmann::json_abi_v3_11_3::detail::json_sax_dom_callback_parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char> >, void> >::end_object() */ int8 __thiscall nlohmann::json_abi_v3_11_3::detail:: json_sax_dom_callback_parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>> ::end_object(json_sax_dom_callback_parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>> *this) { int iVar1; long lVar2; char cVar3; char *pcVar4; int8 uVar5; int8 local_a0; int8 local_98; int8 uStack_90; int8 local_88; char *local_80; int8 local_78; int8 uStack_70; int8 local_68; basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,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_60 [16]; char *local_50; int4 local_48; int4 uStack_44; int4 uStack_40; int4 uStack_3c; int8 local_38; if (*(long *)(*(long *)(this + 0x10) + -8) != 0) { local_80 = (char *)CONCAT44(local_80._4_4_, (int)((ulong)(*(long *)(this + 0x10) - *(long *)(this + 8)) >> 3) + -1); local_a0 = CONCAT71(local_a0._1_7_,1); if (*(long *)(this + 0x90) == 0) { /* WARNING: Subroutine does not return */ std::__throw_bad_function_call(); } cVar3 = (**(code **)(this + 0x98))(this + 0x80,&local_80,&local_a0); if (cVar3 == '\0') { basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> ::basic_json(local_60,(basic_json *)(this + 0xa8)); basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,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> **)(*(long *)(this + 0x10) + -8),local_60); basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,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_60,0)); basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> ::data::~data((data *)local_60); } } lVar2 = *(long *)(this + 0x10); if (*(long *)(this + 8) == lVar2) { pcVar4 = "!ref_stack.empty()"; uVar5 = 0x1bbd; } else { iVar1 = *(int *)(this + 0x38); if (iVar1 != 0 || *(long *)(this + 0x20) != *(long *)(this + 0x30)) { *(long *)(this + 0x10) = lVar2 + -8; *(int *)(this + 0x38) = iVar1 + -1; if (iVar1 == 0) { *(int4 *)(this + 0x38) = 0x3f; *(long *)(this + 0x30) = *(long *)(this + 0x30) + -8; } if (((*(long *)(this + 8) != lVar2 + -8) && (local_80 = *(char **)(lVar2 + -0x10), local_80 != (char *)0x0)) && ((byte)(*local_80 - 1U) < 2)) { local_78 = 0; uStack_70 = 0; local_68 = 0x8000000000000000; 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>> ::set_begin((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>> *)&local_80); local_a0 = *(int8 *)(*(long *)(this + 0x10) + -8); local_98 = 0; uStack_90 = 0; local_88 = 0x8000000000000000; 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>> ::set_end((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>> *)&local_a0); cVar3 = _ZNK8nlohmann16json_abi_v3_11_36detail9iter_implINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEeqISG_TnNSt9enable_ifIXoosr3std7is_sameIT_SG_EE5valuesr3std7is_sameISJ_NS2_IKSF_EEEE5valueEDnE4typeELDn0EEEbRKSJ_ ((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>> *)&local_80, (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>> *)&local_a0); if (cVar3 == '\0') { do { pcVar4 = (char *)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>> ::operator->((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>> *)&local_80); if (*pcVar4 == '\t') { local_50 = local_80; local_48 = (int4)local_78; uStack_44 = local_78._4_4_; uStack_40 = (int4)uStack_70; uStack_3c = uStack_70._4_4_; local_38 = local_68; _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE5eraseINS0_6detail9iter_implISD_EETnNSt9enable_ifIXoosr3std7is_sameIT_SH_EE5valuesr3std7is_sameISJ_NSG_IKSD_EEEE5valueEiE4typeELi0EEESJ_SJ_ (&local_a0,*(int8 *)(*(long *)(this + 0x10) + -8)); return 1; } 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>> ::operator++((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>> *)&local_80); local_a0 = *(int8 *)(*(long *)(this + 0x10) + -8); local_98 = 0; uStack_90 = 0; local_88 = 0x8000000000000000; 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>> ::set_end((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>> *)&local_a0); cVar3 = _ZNK8nlohmann16json_abi_v3_11_36detail9iter_implINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEeqISG_TnNSt9enable_ifIXoosr3std7is_sameIT_SG_EE5valuesr3std7is_sameISJ_NS2_IKSF_EEEE5valueEDnE4typeELDn0EEEbRKSJ_ ((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>> *)&local_80, (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>> *)&local_a0); } while (cVar3 == '\0'); } } return 1; } pcVar4 = "!keep_stack.empty()"; uVar5 = 0x1bbe; } /* WARNING: Subroutine does not return */ ggml_abort("/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",uVar5, "GGML_ASSERT(%s) failed",pcVar4); }
27,554
free_old_query
eloqsql/libmariadb/libmariadb/mariadb_lib.c
static void free_old_query(MYSQL *mysql) { if (mysql->fields) ma_free_root(&mysql->field_alloc,MYF(0)); ma_init_alloc_root(&mysql->field_alloc,8192,0); /* Assume rowlength < 8192 */ mysql->fields=0; mysql->field_count=0; /* For API */ mysql->info= 0; return; }
O0
c
free_old_query: pushq %rbp movq %rsp, %rbp subq $0x10, %rsp movq %rdi, -0x8(%rbp) movq -0x8(%rbp), %rax cmpq $0x0, 0x2f8(%rax) je 0x2608c movq -0x8(%rbp), %rdi addq $0x300, %rdi # imm = 0x300 xorl %esi, %esi callq 0x2cb10 movq -0x8(%rbp), %rdi addq $0x300, %rdi # imm = 0x300 movl $0x2000, %esi # imm = 0x2000 xorl %eax, %eax movl %eax, %edx callq 0x2c7d0 movq -0x8(%rbp), %rax movq $0x0, 0x2f8(%rax) movq -0x8(%rbp), %rax movl $0x0, 0x37c(%rax) movq -0x8(%rbp), %rax movq $0x0, 0x2e0(%rax) addq $0x10, %rsp popq %rbp retq nopw (%rax,%rax)
free_old_query: push rbp mov rbp, rsp sub rsp, 10h mov [rbp+var_8], rdi mov rax, [rbp+var_8] cmp qword ptr [rax+2F8h], 0 jz short loc_2608C mov rdi, [rbp+var_8] add rdi, 300h xor esi, esi call ma_free_root loc_2608C: mov rdi, [rbp+var_8] add rdi, 300h mov esi, 2000h xor eax, eax mov edx, eax call ma_init_alloc_root mov rax, [rbp+var_8] mov qword ptr [rax+2F8h], 0 mov rax, [rbp+var_8] mov dword ptr [rax+37Ch], 0 mov rax, [rbp+var_8] mov qword ptr [rax+2E0h], 0 add rsp, 10h pop rbp retn
long long free_old_query(long long a1) { long long result; // rax if ( *(_QWORD *)(a1 + 760) ) ma_free_root(a1 + 768, 0LL); ma_init_alloc_root(a1 + 768, 0x2000LL, 0LL); *(_QWORD *)(a1 + 760) = 0LL; *(_DWORD *)(a1 + 892) = 0; result = a1; *(_QWORD *)(a1 + 736) = 0LL; return result; }
free_old_query: PUSH RBP MOV RBP,RSP SUB RSP,0x10 MOV qword ptr [RBP + -0x8],RDI MOV RAX,qword ptr [RBP + -0x8] CMP qword ptr [RAX + 0x2f8],0x0 JZ 0x0012608c MOV RDI,qword ptr [RBP + -0x8] ADD RDI,0x300 XOR ESI,ESI CALL 0x0012cb10 LAB_0012608c: MOV RDI,qword ptr [RBP + -0x8] ADD RDI,0x300 MOV ESI,0x2000 XOR EAX,EAX MOV EDX,EAX CALL 0x0012c7d0 MOV RAX,qword ptr [RBP + -0x8] MOV qword ptr [RAX + 0x2f8],0x0 MOV RAX,qword ptr [RBP + -0x8] MOV dword ptr [RAX + 0x37c],0x0 MOV RAX,qword ptr [RBP + -0x8] MOV qword ptr [RAX + 0x2e0],0x0 ADD RSP,0x10 POP RBP RET
void free_old_query(long param_1) { if (*(long *)(param_1 + 0x2f8) != 0) { ma_free_root(param_1 + 0x300,0); } ma_init_alloc_root(param_1 + 0x300,0x2000,0); *(int8 *)(param_1 + 0x2f8) = 0; *(int4 *)(param_1 + 0x37c) = 0; *(int8 *)(param_1 + 0x2e0) = 0; return; }
27,555
mbedtls_chacha20_crypt
msxemulator/build_O3/_deps/pico_sdk-src/lib/mbedtls/library/chacha20.c
int mbedtls_chacha20_crypt(const unsigned char key[32], const unsigned char nonce[12], uint32_t counter, size_t data_len, const unsigned char *input, unsigned char *output) { mbedtls_chacha20_context ctx; int ret = MBEDTLS_ERR_ERROR_CORRUPTION_DETECTED; CHACHA20_VALIDATE_RET(key != NULL); CHACHA20_VALIDATE_RET(nonce != NULL); CHACHA20_VALIDATE_RET(data_len == 0 || input != NULL); CHACHA20_VALIDATE_RET(data_len == 0 || output != NULL); mbedtls_chacha20_init(&ctx); ret = mbedtls_chacha20_setkey(&ctx, key); if (ret != 0) { goto cleanup; } ret = mbedtls_chacha20_starts(&ctx, nonce, counter); if (ret != 0) { goto cleanup; } ret = mbedtls_chacha20_update(&ctx, data_len, input, output); cleanup: mbedtls_chacha20_free(&ctx); return ret; }
O3
c
mbedtls_chacha20_crypt: pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0xa8, %rsp movq %r9, 0x18(%rsp) movq %r8, 0x10(%rsp) movq %rcx, 0x8(%rsp) movl %edx, %ebp movq %rsi, %r13 movq %rdi, %rbx leaq 0x20(%rsp), %r14 movl $0x40, %r12d movl $0x40, %esi movq %r14, %rdi callq 0x8db8c leaq (%r14,%r12), %r15 movl $0x40, %esi movq %r15, %rdi callq 0x8db8c movq %r12, 0x80(%r14) movaps 0x161ae(%rip), %xmm0 # 0xb61b0 movaps %xmm0, (%r14) movups (%rbx), %xmm0 movaps %xmm0, 0x10(%r14) movups 0x10(%rbx), %xmm0 movaps %xmm0, 0x20(%r14) movl %ebp, 0x30(%r14) movq (%r13), %rax movq %rax, 0x34(%r14) movl 0x8(%r13), %eax movl %eax, 0x3c(%r14) movl $0x40, %esi movq %r15, %rdi callq 0x8db8c movq %r12, 0x80(%r14) movq %r14, %rdi movq 0x8(%rsp), %rsi movq 0x10(%rsp), %rdx movq 0x18(%rsp), %rcx callq 0x9fb4a movl $0x88, %esi movq %r14, %rdi callq 0x8db8c xorl %eax, %eax addq $0xa8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
mbedtls_chacha20_crypt: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 0A8h mov [rsp+0D8h+var_C0], r9 mov [rsp+0D8h+var_C8], r8 mov [rsp+0D8h+var_D0], rcx mov ebp, edx mov r13, rsi mov rbx, rdi lea r14, [rsp+0D8h+var_B8] mov r12d, 40h ; '@' mov esi, 40h ; '@' mov rdi, r14 call mbedtls_platform_zeroize lea r15, [r14+r12] mov esi, 40h ; '@' mov rdi, r15 call mbedtls_platform_zeroize mov [r14+80h], r12 movaps xmm0, cs:xmmword_B61B0 movaps xmmword ptr [r14], xmm0 movups xmm0, xmmword ptr [rbx] movaps xmmword ptr [r14+10h], xmm0 movups xmm0, xmmword ptr [rbx+10h] movaps xmmword ptr [r14+20h], xmm0 mov [r14+30h], ebp mov rax, [r13+0] mov [r14+34h], rax mov eax, [r13+8] mov [r14+3Ch], eax mov esi, 40h ; '@' mov rdi, r15 call mbedtls_platform_zeroize mov [r14+80h], r12 mov rdi, r14 mov rsi, [rsp+0D8h+var_D0] mov rdx, [rsp+0D8h+var_C8] mov rcx, [rsp+0D8h+var_C0] call mbedtls_chacha20_update mov esi, 88h mov rdi, r14 call mbedtls_platform_zeroize xor eax, eax add rsp, 0A8h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
long long mbedtls_chacha20_crypt(_OWORD *a1, long long *a2, int a3, long long a4, long long a5, long long a6) { _OWORD v11[3]; // [rsp+20h] [rbp-B8h] BYREF int v12; // [rsp+50h] [rbp-88h] long long v13; // [rsp+54h] [rbp-84h] int v14; // [rsp+5Ch] [rbp-7Ch] _BYTE v15[64]; // [rsp+60h] [rbp-78h] BYREF long long v16; // [rsp+A0h] [rbp-38h] mbedtls_platform_zeroize((long long)v11, 64LL); mbedtls_platform_zeroize((long long)v15, 64LL); v16 = 64LL; v11[0] = xmmword_B61B0; v11[1] = *a1; v11[2] = a1[1]; v12 = a3; v13 = *a2; v14 = *((_DWORD *)a2 + 2); mbedtls_platform_zeroize((long long)v15, 64LL); v16 = 64LL; mbedtls_chacha20_update((long long)v11, a4, a5, a6); mbedtls_platform_zeroize((long long)v11, 136LL); return 0LL; }
mbedtls_chacha20_crypt: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0xa8 MOV qword ptr [RSP + 0x18],R9 MOV qword ptr [RSP + 0x10],R8 MOV qword ptr [RSP + 0x8],RCX MOV EBP,EDX MOV R13,RSI MOV RBX,RDI LEA R14,[RSP + 0x20] MOV R12D,0x40 MOV ESI,0x40 MOV RDI,R14 CALL 0x0018db8c LEA R15,[R14 + R12*0x1] MOV ESI,0x40 MOV RDI,R15 CALL 0x0018db8c MOV qword ptr [R14 + 0x80],R12 MOVAPS XMM0,xmmword ptr [0x001b61b0] MOVAPS xmmword ptr [R14],XMM0 MOVUPS XMM0,xmmword ptr [RBX] MOVAPS xmmword ptr [R14 + 0x10],XMM0 MOVUPS XMM0,xmmword ptr [RBX + 0x10] MOVAPS xmmword ptr [R14 + 0x20],XMM0 MOV dword ptr [R14 + 0x30],EBP MOV RAX,qword ptr [R13] MOV qword ptr [R14 + 0x34],RAX MOV EAX,dword ptr [R13 + 0x8] MOV dword ptr [R14 + 0x3c],EAX MOV ESI,0x40 MOV RDI,R15 CALL 0x0018db8c MOV qword ptr [R14 + 0x80],R12 MOV RDI,R14 MOV RSI,qword ptr [RSP + 0x8] MOV RDX,qword ptr [RSP + 0x10] MOV RCX,qword ptr [RSP + 0x18] CALL 0x0019fb4a MOV ESI,0x88 MOV RDI,R14 CALL 0x0018db8c XOR EAX,EAX ADD RSP,0xa8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
int8 mbedtls_chacha20_crypt (int8 *param_1,int8 *param_2,int4 param_3,int8 param_4, int8 param_5,int8 param_6) { char local_b8 [8]; char acStack_b0 [8]; int8 local_a8; int8 uStack_a0; int4 local_98; int4 uStack_94; int4 uStack_90; int4 uStack_8c; int4 local_88; int8 local_84; int4 local_7c; int1 local_78 [64]; int8 local_38; mbedtls_platform_zeroize(local_b8,0x40); mbedtls_platform_zeroize(local_78,0x40); local_38 = 0x40; local_b8[0] = s_expand_32_byte_k__001b61b0[0]; local_b8[1] = s_expand_32_byte_k__001b61b0[1]; local_b8[2] = s_expand_32_byte_k__001b61b0[2]; local_b8[3] = s_expand_32_byte_k__001b61b0[3]; local_b8[4] = s_expand_32_byte_k__001b61b0[4]; local_b8[5] = s_expand_32_byte_k__001b61b0[5]; local_b8[6] = s_expand_32_byte_k__001b61b0[6]; local_b8[7] = s_expand_32_byte_k__001b61b0[7]; acStack_b0[0] = s_expand_32_byte_k__001b61b0[8]; acStack_b0[1] = s_expand_32_byte_k__001b61b0[9]; acStack_b0[2] = s_expand_32_byte_k__001b61b0[10]; acStack_b0[3] = s_expand_32_byte_k__001b61b0[0xb]; acStack_b0[4] = s_expand_32_byte_k__001b61b0[0xc]; acStack_b0[5] = s_expand_32_byte_k__001b61b0[0xd]; acStack_b0[6] = s_expand_32_byte_k__001b61b0[0xe]; acStack_b0[7] = s_expand_32_byte_k__001b61b0[0xf]; local_a8 = *param_1; uStack_a0 = param_1[1]; local_98 = *(int4 *)(param_1 + 2); uStack_94 = *(int4 *)((long)param_1 + 0x14); uStack_90 = *(int4 *)(param_1 + 3); uStack_8c = *(int4 *)((long)param_1 + 0x1c); local_84 = *param_2; local_7c = *(int4 *)(param_2 + 1); local_88 = param_3; mbedtls_platform_zeroize(local_78,0x40); local_38 = 0x40; mbedtls_chacha20_update(local_b8,param_4,param_5,param_6); mbedtls_platform_zeroize(local_b8,0x88); return 0; }
27,556
translog_read_next_record_header
eloqsql/storage/maria/ma_loghandler.c
int translog_read_next_record_header(TRANSLOG_SCANNER_DATA *scanner, TRANSLOG_HEADER_BUFFER *buff) { translog_size_t res; DBUG_ENTER("translog_read_next_record_header"); buff->groups_no= 0; /* to be sure that we will free it right */ DBUG_PRINT("enter", ("scanner: %p", scanner)); DBUG_PRINT("info", ("Scanner: Cur: " LSN_FMT " Hrz: " LSN_FMT " " "Lst: " LSN_FMT " Offset: %u(%x) fixed: %d", LSN_IN_PARTS(scanner->page_addr), LSN_IN_PARTS(scanner->horizon), LSN_IN_PARTS(scanner->last_file_page), (uint) scanner->page_offset, (uint) scanner->page_offset, scanner->fixed_horizon)); DBUG_ASSERT(translog_status == TRANSLOG_OK || translog_status == TRANSLOG_READONLY); do { if (translog_get_next_chunk(scanner)) DBUG_RETURN(RECHEADER_READ_ERROR); if (scanner->page == END_OF_LOG) { DBUG_PRINT("info", ("End of file from the scanner")); /* Last record was read */ buff->lsn= LSN_IMPOSSIBLE; DBUG_RETURN(RECHEADER_READ_EOF); } DBUG_PRINT("info", ("Page: " LSN_FMT " offset: %lu byte: %x", LSN_IN_PARTS(scanner->page_addr), (ulong) scanner->page_offset, (uint) scanner->page[scanner->page_offset])); } while (!translog_is_LSN_chunk(scanner->page[scanner->page_offset]) && scanner->page[scanner->page_offset] != TRANSLOG_FILLER); if (scanner->page[scanner->page_offset] == TRANSLOG_FILLER) { DBUG_PRINT("info", ("End of file")); /* Last record was read */ buff->lsn= LSN_IMPOSSIBLE; /* Return 'end of log' marker */ res= RECHEADER_READ_EOF; } else res= translog_read_record_header_scan(scanner, buff, 0); DBUG_RETURN(res); }
O3
c
translog_read_next_record_header: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %rbx pushq %rax movq %rsi, %rbx movq %rdi, %r14 movl $0x0, 0x418(%rsi) leaq 0xbc9343(%rip), %r15 # 0xbfee10 movq %r14, %rdi callq 0x341de testb %al, %al jne 0x35b73 movq 0x2018(%r14), %rax cmpq %r15, %rax je 0x35b65 movl 0x2028(%r14), %ecx movzbl (%rax,%rcx), %eax movl %eax, %ecx andl $-0x40, %ecx cmpl $0x40, %ecx je 0x35b1a testl %ecx, %ecx sete %cl movl %eax, %edx notl %edx testb $0x3f, %dl setne %dl testb %dl, %cl jne 0x35b1a cmpl $0xff, %eax jne 0x35acd jmp 0x35b65 cmpl $0xff, %eax je 0x35b65 movl $0x0, 0x418(%rbx) movq 0x2000(%r14), %rax movq %rax, (%rbx) movl 0x2028(%r14), %ecx addq %rax, %rcx movq %rcx, (%rbx) movq 0x2018(%r14), %rdi movzwl 0x2028(%r14), %esi movq %rbx, %rdx xorl %ecx, %ecx addq $0x8, %rsp popq %rbx popq %r14 popq %r15 popq %rbp jmp 0x3551c movq $0x0, (%rbx) movl $0xfffffffe, %eax # imm = 0xFFFFFFFE jmp 0x35b78 movl $0xffffffff, %eax # imm = 0xFFFFFFFF addq $0x8, %rsp popq %rbx popq %r14 popq %r15 popq %rbp retq
translog_read_next_record_header: push rbp mov rbp, rsp push r15 push r14 push rbx push rax mov rbx, rsi mov r14, rdi mov dword ptr [rsi+418h], 0 lea r15, end_of_log loc_35ACD: mov rdi, r14 call translog_get_next_chunk test al, al jnz loc_35B73 mov rax, [r14+2018h] cmp rax, r15 jz short loc_35B65 mov ecx, [r14+2028h] movzx eax, byte ptr [rax+rcx] mov ecx, eax and ecx, 0FFFFFFC0h cmp ecx, 40h ; '@' jz short loc_35B1A test ecx, ecx setz cl mov edx, eax not edx test dl, 3Fh setnz dl test cl, dl jnz short loc_35B1A cmp eax, 0FFh jnz short loc_35ACD jmp short loc_35B65 loc_35B1A: cmp eax, 0FFh jz short loc_35B65 mov dword ptr [rbx+418h], 0 mov rax, [r14+2000h] mov [rbx], rax mov ecx, [r14+2028h] add rcx, rax mov [rbx], rcx mov rdi, [r14+2018h] movzx esi, word ptr [r14+2028h] mov rdx, rbx xor ecx, ecx add rsp, 8 pop rbx pop r14 pop r15 pop rbp jmp translog_read_record_header_from_buffer loc_35B65: mov qword ptr [rbx], 0 mov eax, 0FFFFFFFEh jmp short loc_35B78 loc_35B73: mov eax, 0FFFFFFFFh loc_35B78: add rsp, 8 pop rbx pop r14 pop r15 pop rbp retn
long long translog_read_next_record_header(long long a1, long long a2) { unsigned __int8 *v2; // rax int v3; // eax long long v4; // rax *(_DWORD *)(a2 + 1048) = 0; while ( !translog_get_next_chunk(a1) ) { v2 = *(unsigned __int8 **)(a1 + 8216); if ( v2 == (unsigned __int8 *)&end_of_log ) goto LABEL_10; v3 = v2[*(unsigned int *)(a1 + 8232)]; if ( (v3 & 0xFFFFFFC0) == 0x40 || (~(_BYTE)v3 & 0x3F) != 0 && (v3 & 0xFFFFFFC0) == 0 ) { if ( v3 != 255 ) { *(_DWORD *)(a2 + 1048) = 0; v4 = *(_QWORD *)(a1 + 0x2000); *(_QWORD *)a2 = v4; *(_QWORD *)a2 = v4 + *(unsigned int *)(a1 + 8232); return translog_read_record_header_from_buffer( *(_QWORD *)(a1 + 8216), *(unsigned __int16 *)(a1 + 8232), a2, 0LL); } LABEL_10: *(_QWORD *)a2 = 0LL; return 4294967294LL; } if ( v3 == 255 ) goto LABEL_10; } return 0xFFFFFFFFLL; }
translog_read_next_record_header: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH RBX PUSH RAX MOV RBX,RSI MOV R14,RDI MOV dword ptr [RSI + 0x418],0x0 LEA R15,[0xcfee10] LAB_00135acd: MOV RDI,R14 CALL 0x001341de TEST AL,AL JNZ 0x00135b73 MOV RAX,qword ptr [R14 + 0x2018] CMP RAX,R15 JZ 0x00135b65 MOV ECX,dword ptr [R14 + 0x2028] MOVZX EAX,byte ptr [RAX + RCX*0x1] MOV ECX,EAX AND ECX,0xffffffc0 CMP ECX,0x40 JZ 0x00135b1a TEST ECX,ECX SETZ CL MOV EDX,EAX NOT EDX TEST DL,0x3f SETNZ DL TEST CL,DL JNZ 0x00135b1a CMP EAX,0xff JNZ 0x00135acd JMP 0x00135b65 LAB_00135b1a: CMP EAX,0xff JZ 0x00135b65 MOV dword ptr [RBX + 0x418],0x0 MOV RAX,qword ptr [R14 + 0x2000] MOV qword ptr [RBX],RAX MOV ECX,dword ptr [R14 + 0x2028] ADD RCX,RAX MOV qword ptr [RBX],RCX MOV RDI,qword ptr [R14 + 0x2018] MOVZX ESI,word ptr [R14 + 0x2028] MOV RDX,RBX XOR ECX,ECX ADD RSP,0x8 POP RBX POP R14 POP R15 POP RBP JMP 0x0013551c LAB_00135b65: MOV qword ptr [RBX],0x0 MOV EAX,0xfffffffe JMP 0x00135b78 LAB_00135b73: MOV EAX,0xffffffff LAB_00135b78: ADD RSP,0x8 POP RBX POP R14 POP R15 POP RBP RET
int8 translog_read_next_record_header(long param_1,long *param_2) { byte bVar1; long lVar2; char cVar3; int8 uVar4; *(int4 *)(param_2 + 0x83) = 0; while( true ) { cVar3 = translog_get_next_chunk(param_1); if (cVar3 != '\0') { return 0xffffffff; } if (*(int1 **)(param_1 + 0x2018) == &end_of_log) goto LAB_00135b65; bVar1 = (*(int1 **)(param_1 + 0x2018))[*(uint *)(param_1 + 0x2028)]; if (((bVar1 & 0xc0) == 0x40) || ((bVar1 & 0xc0) == 0 && (~bVar1 & 0x3f) != 0)) break; if (bVar1 == 0xff) { LAB_00135b65: *param_2 = 0; return 0xfffffffe; } } if (bVar1 != 0xff) { *(int4 *)(param_2 + 0x83) = 0; lVar2 = *(long *)(param_1 + 0x2000); *param_2 = lVar2; *param_2 = (ulong)*(uint *)(param_1 + 0x2028) + lVar2; uVar4 = translog_read_record_header_from_buffer (*(int8 *)(param_1 + 0x2018),*(int2 *)(param_1 + 0x2028),param_2,0 ); return uVar4; } goto LAB_00135b65; }
27,557
Diagnostics_area::reset_diagnostics_area()
eloqsql/sql/sql_error.cc
void Diagnostics_area::reset_diagnostics_area() { DBUG_ENTER("reset_diagnostics_area"); #ifdef DBUG_OFF m_can_overwrite_status= FALSE; /** Don't take chances in production */ m_message[0]= '\0'; Sql_state_errno::clear(); Sql_user_condition_identity::clear(); m_affected_rows= 0; m_last_insert_id= 0; m_statement_warn_count= 0; #endif get_warning_info()->clear_error_condition(); set_is_sent(false); /** Tiny reset in debug mode to see garbage right away */ m_status= DA_EMPTY; DBUG_VOID_RETURN; }
O0
cpp
Diagnostics_area::reset_diagnostics_area(): pushq %rbp movq %rsp, %rbp subq $0x10, %rsp movq %rdi, -0x8(%rbp) movq -0x8(%rbp), %rdi movq %rdi, -0x10(%rbp) movb $0x0, 0x19(%rdi) movb $0x0, 0x1a(%rdi) callq 0x8abfa0 movq -0x10(%rbp), %rdi addq $0x10, %rdi callq 0x8abfc0 movq -0x10(%rbp), %rdi movq $0x0, 0x220(%rdi) movq $0x0, 0x228(%rdi) movl $0x0, 0x230(%rdi) callq 0x7fb700 movq %rax, %rdi callq 0x8abfe0 movq -0x10(%rbp), %rdi xorl %esi, %esi callq 0x7ec1e0 movq -0x10(%rbp), %rax movl $0x0, 0x234(%rax) jmp 0x8aa6ba addq $0x10, %rsp popq %rbp retq
_ZN16Diagnostics_area22reset_diagnostics_areaEv: push rbp mov rbp, rsp sub rsp, 10h mov [rbp+var_8], rdi mov rdi, [rbp+var_8]; this mov [rbp+var_10], rdi mov byte ptr [rdi+19h], 0 mov byte ptr [rdi+1Ah], 0 call _ZN15Sql_state_errno5clearEv; Sql_state_errno::clear(void) mov rdi, [rbp+var_10] add rdi, 10h; this call _ZN27Sql_user_condition_identity5clearEv; Sql_user_condition_identity::clear(void) mov rdi, [rbp+var_10]; this mov qword ptr [rdi+220h], 0 mov qword ptr [rdi+228h], 0 mov dword ptr [rdi+230h], 0 call _ZN16Diagnostics_area16get_warning_infoEv; Diagnostics_area::get_warning_info(void) mov rdi, rax; this call _ZN12Warning_info21clear_error_conditionEv; Warning_info::clear_error_condition(void) mov rdi, [rbp+var_10]; this xor esi, esi; bool call _ZN16Diagnostics_area11set_is_sentEb; Diagnostics_area::set_is_sent(bool) mov rax, [rbp+var_10] mov dword ptr [rax+234h], 0 jmp short $+2 loc_8AA6BA: add rsp, 10h pop rbp retn
Diagnostics_area * Diagnostics_area::reset_diagnostics_area(Diagnostics_area *this) { Warning_info *warning_info; // rax Diagnostics_area *result; // rax *((_BYTE *)this + 25) = 0; *((_BYTE *)this + 26) = 0; Sql_state_errno::clear(this); Sql_user_condition_identity::clear((Diagnostics_area *)((char *)this + 16)); *((_QWORD *)this + 68) = 0LL; *((_QWORD *)this + 69) = 0LL; *((_DWORD *)this + 140) = 0; warning_info = (Warning_info *)Diagnostics_area::get_warning_info(this); Warning_info::clear_error_condition(warning_info); Diagnostics_area::set_is_sent(this, 0); result = this; *((_DWORD *)this + 141) = 0; return result; }
__cxx_global_var_init.9: PUSH RBP MOV RBP,RSP LEA RDI,[0x264b9cc] MOV ESI,0x3800000 CALL 0x008db900 POP RBP RET
void __cxx_global_var_init_9(void) { date_conv_mode_t::date_conv_mode_t((date_conv_mode_t *)&TIME_MODE_FOR_XXX_TO_DATE,0x3800000); return; }
27,558
Diagnostics_area::reset_diagnostics_area()
eloqsql/sql/sql_error.cc
void Diagnostics_area::reset_diagnostics_area() { DBUG_ENTER("reset_diagnostics_area"); #ifdef DBUG_OFF m_can_overwrite_status= FALSE; /** Don't take chances in production */ m_message[0]= '\0'; Sql_state_errno::clear(); Sql_user_condition_identity::clear(); m_affected_rows= 0; m_last_insert_id= 0; m_statement_warn_count= 0; #endif get_warning_info()->clear_error_condition(); set_is_sent(false); /** Tiny reset in debug mode to see garbage right away */ m_status= DA_EMPTY; DBUG_VOID_RETURN; }
O3
cpp
Diagnostics_area::reset_diagnostics_area(): pushq %rbp movq %rsp, %rbp movw $0x0, 0x19(%rdi) xorl %eax, %eax movl %eax, 0x8(%rdi) movq %rax, 0x10(%rdi) xorps %xmm0, %xmm0 movups %xmm0, 0x220(%rdi) movl %eax, 0x230(%rdi) movq 0x300(%rdi), %rcx movq %rax, 0x78(%rcx) movb $0x0, 0x18(%rdi) movl %eax, 0x234(%rdi) popq %rbp retq
_ZN16Diagnostics_area22reset_diagnostics_areaEv: push rbp mov rbp, rsp mov word ptr [rdi+19h], 0 xor eax, eax mov [rdi+8], eax mov [rdi+10h], rax xorps xmm0, xmm0 movups xmmword ptr [rdi+220h], xmm0 mov [rdi+230h], eax mov rcx, [rdi+300h] mov [rcx+78h], rax mov byte ptr [rdi+18h], 0 mov [rdi+234h], eax pop rbp retn
long long Diagnostics_area::reset_diagnostics_area(Diagnostics_area *this) { long long result; // rax *(_WORD *)((char *)this + 25) = 0; result = 0LL; *((_DWORD *)this + 2) = 0; *((_QWORD *)this + 2) = 0LL; *((_OWORD *)this + 34) = 0LL; *((_DWORD *)this + 140) = 0; *(_QWORD *)(*((_QWORD *)this + 96) + 120LL) = 0LL; *((_BYTE *)this + 24) = 0; *((_DWORD *)this + 141) = 0; return result; }
27,559
ssz_add_dynamic_list_bytes
corpus-core[P]colibri-stateless/src/util/ssz_builder.c
void ssz_add_dynamic_list_bytes(ssz_builder_t* buffer, int num_elements, bytes_t data) { const ssz_def_t* child_def = buffer->def->def.vector.type; if (ssz_is_dynamic(child_def)) { uint32_t offset = 4 * num_elements + buffer->dynamic.data.len; ssz_add_uint32(buffer, offset); buffer_append(&buffer->dynamic, data); } else buffer_append(&buffer->fixed, data); }
O0
c
ssz_add_dynamic_list_bytes: pushq %rbp movq %rsp, %rbp subq $0x30, %rsp movl %edx, -0x10(%rbp) movq %rcx, -0x8(%rbp) movq %rdi, -0x18(%rbp) movl %esi, -0x1c(%rbp) movq -0x18(%rbp), %rax movq (%rax), %rax movq 0x10(%rax), %rax movq %rax, -0x28(%rbp) movq -0x28(%rbp), %rdi callq 0x9dfd0 testb $0x1, %al jne 0xa2204 jmp 0xa2236 movl -0x1c(%rbp), %eax shll $0x2, %eax movq -0x18(%rbp), %rcx addl 0x20(%rcx), %eax movl %eax, -0x2c(%rbp) movq -0x18(%rbp), %rdi movl -0x2c(%rbp), %esi callq 0xa2250 movq -0x18(%rbp), %rdi addq $0x20, %rdi movl -0x10(%rbp), %esi movq -0x8(%rbp), %rdx callq 0x9ca30 jmp 0xa224a movq -0x18(%rbp), %rdi addq $0x8, %rdi movl -0x10(%rbp), %esi movq -0x8(%rbp), %rdx callq 0x9ca30 addq $0x30, %rsp popq %rbp retq
ssz_add_dynamic_list_bytes: push rbp mov rbp, rsp sub rsp, 30h mov [rbp+var_10], edx mov [rbp+var_8], rcx mov [rbp+var_18], rdi mov [rbp+var_1C], esi mov rax, [rbp+var_18] mov rax, [rax] mov rax, [rax+10h] mov [rbp+var_28], rax mov rdi, [rbp+var_28] call ssz_is_dynamic test al, 1 jnz short loc_A2204 jmp short loc_A2236 loc_A2204: mov eax, [rbp+var_1C] shl eax, 2 mov rcx, [rbp+var_18] add eax, [rcx+20h] mov [rbp+var_2C], eax mov rdi, [rbp+var_18] mov esi, [rbp+var_2C] call ssz_add_uint32 mov rdi, [rbp+var_18] add rdi, 20h ; ' ' mov esi, [rbp+var_10] mov rdx, [rbp+var_8] call buffer_append jmp short loc_A224A loc_A2236: mov rdi, [rbp+var_18] add rdi, 8 mov esi, [rbp+var_10] mov rdx, [rbp+var_8] call buffer_append loc_A224A: add rsp, 30h pop rbp retn
long long ssz_add_dynamic_list_bytes(unsigned int *a1, int a2, unsigned int a3, long long a4) { if ( (ssz_is_dynamic(*(_QWORD *)(*(_QWORD *)a1 + 16LL)) & 1) == 0 ) return buffer_append(a1 + 2, a3, a4); ssz_add_uint32(a1, a1[8] + 4 * a2); return buffer_append(a1 + 8, a3, a4); }
ssz_add_dynamic_list_bytes: PUSH RBP MOV RBP,RSP SUB RSP,0x30 MOV dword ptr [RBP + -0x10],EDX MOV qword ptr [RBP + -0x8],RCX MOV qword ptr [RBP + -0x18],RDI MOV dword ptr [RBP + -0x1c],ESI MOV RAX,qword ptr [RBP + -0x18] MOV RAX,qword ptr [RAX] MOV RAX,qword ptr [RAX + 0x10] MOV qword ptr [RBP + -0x28],RAX MOV RDI,qword ptr [RBP + -0x28] CALL 0x0019dfd0 TEST AL,0x1 JNZ 0x001a2204 JMP 0x001a2236 LAB_001a2204: MOV EAX,dword ptr [RBP + -0x1c] SHL EAX,0x2 MOV RCX,qword ptr [RBP + -0x18] ADD EAX,dword ptr [RCX + 0x20] MOV dword ptr [RBP + -0x2c],EAX MOV RDI,qword ptr [RBP + -0x18] MOV ESI,dword ptr [RBP + -0x2c] CALL 0x001a2250 MOV RDI,qword ptr [RBP + -0x18] ADD RDI,0x20 MOV ESI,dword ptr [RBP + -0x10] MOV RDX,qword ptr [RBP + -0x8] CALL 0x0019ca30 JMP 0x001a224a LAB_001a2236: MOV RDI,qword ptr [RBP + -0x18] ADD RDI,0x8 MOV ESI,dword ptr [RBP + -0x10] MOV RDX,qword ptr [RBP + -0x8] CALL 0x0019ca30 LAB_001a224a: ADD RSP,0x30 POP RBP RET
void ssz_add_dynamic_list_bytes(long *param_1,int param_2,int4 param_3,int8 param_4) { ulong uVar1; uVar1 = ssz_is_dynamic(*(int8 *)(*param_1 + 0x10)); if ((uVar1 & 1) == 0) { buffer_append(param_1 + 1,param_3,param_4); } else { ssz_add_uint32(param_1,param_2 * 4 + (int)param_1[4]); buffer_append(param_1 + 4,param_3,param_4); } return; }
27,560
ssz_add_dynamic_list_bytes
corpus-core[P]colibri-stateless/src/util/ssz_builder.c
void ssz_add_dynamic_list_bytes(ssz_builder_t* buffer, int num_elements, bytes_t data) { const ssz_def_t* child_def = buffer->def->def.vector.type; if (ssz_is_dynamic(child_def)) { uint32_t offset = 4 * num_elements + buffer->dynamic.data.len; ssz_add_uint32(buffer, offset); buffer_append(&buffer->dynamic, data); } else buffer_append(&buffer->fixed, data); }
O3
c
ssz_add_dynamic_list_bytes: pushq %rbp pushq %r15 pushq %r14 pushq %r12 pushq %rbx subq $0x10, %rsp movq %rcx, %rbx movl %edx, %ebp movl %esi, %r15d movq %rdi, %r14 movq (%rdi), %rax movq 0x10(%rax), %rdi callq 0x51c74 testb %al, %al je 0x5431a shll $0x2, %r15d addl 0x20(%r14), %r15d leaq 0x20(%r14), %r12 leaq 0xc(%rsp), %rdx movl %r15d, (%rdx) addq $0x8, %r14 movq %r14, %rdi movl $0x4, %esi callq 0x50fdd movq %r12, %rdi movl %ebp, %esi movq %rbx, %rdx callq 0x50fdd addq $0x10, %rsp popq %rbx popq %r12 popq %r14 popq %r15 popq %rbp retq addq $0x8, %r14 movq %r14, %rdi movl %ebp, %esi movq %rbx, %rdx addq $0x10, %rsp popq %rbx popq %r12 popq %r14 popq %r15 popq %rbp jmp 0x50fdd
ssz_add_dynamic_list_bytes: push rbp push r15 push r14 push r12 push rbx sub rsp, 10h mov rbx, rcx mov ebp, edx mov r15d, esi mov r14, rdi mov rax, [rdi] mov rdi, [rax+10h] call ssz_is_dynamic test al, al jz short loc_5431A shl r15d, 2 add r15d, [r14+20h] lea r12, [r14+20h] lea rdx, [rsp+38h+var_2C] mov [rdx], r15d add r14, 8 mov rdi, r14 mov esi, 4 call buffer_append mov rdi, r12 mov esi, ebp mov rdx, rbx call buffer_append add rsp, 10h pop rbx pop r12 pop r14 pop r15 pop rbp retn loc_5431A: add r14, 8 mov rdi, r14 mov esi, ebp mov rdx, rbx add rsp, 10h pop rbx pop r12 pop r14 pop r15 pop rbp jmp buffer_append
long long ssz_add_dynamic_list_bytes(unsigned int *a1, int a2, unsigned int a3, long long a4) { int v7[11]; // [rsp+Ch] [rbp-2Ch] BYREF if ( !(unsigned __int8)ssz_is_dynamic(*(_QWORD *)(*(_QWORD *)a1 + 16LL)) ) return buffer_append(a1 + 2, a3, a4); v7[0] = a1[8] + 4 * a2; buffer_append(a1 + 2, 4u, (long long)v7); return buffer_append(a1 + 8, a3, a4); }
ssz_add_dynamic_list_bytes: PUSH RBP PUSH R15 PUSH R14 PUSH R12 PUSH RBX SUB RSP,0x10 MOV RBX,RCX MOV EBP,EDX MOV R15D,ESI MOV R14,RDI MOV RAX,qword ptr [RDI] MOV RDI,qword ptr [RAX + 0x10] CALL 0x00151c74 TEST AL,AL JZ 0x0015431a SHL R15D,0x2 ADD R15D,dword ptr [R14 + 0x20] LEA R12,[R14 + 0x20] LEA RDX,[RSP + 0xc] MOV dword ptr [RDX],R15D ADD R14,0x8 MOV RDI,R14 MOV ESI,0x4 CALL 0x00150fdd MOV RDI,R12 MOV ESI,EBP MOV RDX,RBX CALL 0x00150fdd ADD RSP,0x10 POP RBX POP R12 POP R14 POP R15 POP RBP RET LAB_0015431a: ADD R14,0x8 MOV RDI,R14 MOV ESI,EBP MOV RDX,RBX ADD RSP,0x10 POP RBX POP R12 POP R14 POP R15 POP RBP JMP 0x00150fdd
void ssz_add_dynamic_list_bytes (long *param_1,int8 param_2,int4 param_3,int8 param_4) { char cVar1; cVar1 = ssz_is_dynamic(*(int8 *)(*param_1 + 0x10)); if (cVar1 != '\0') { buffer_append(param_1 + 1,4); buffer_append(param_1 + 4,param_3,param_4); return; } buffer_append(param_1 + 1,param_3,param_4); return; }
27,561
evmone::instr::core::callf(evmone::StackTop, evmone::ExecutionState&, unsigned char const*)
corpus-core[P]colibri-stateless/build_O0/_deps/evmone_external-src/lib/evmone/instructions.hpp
inline code_iterator callf(StackTop stack, ExecutionState& state, code_iterator pos) noexcept { const auto index = read_uint16_be(&pos[1]); const auto& header = state.analysis.baseline->eof_header(); const auto stack_size = &stack.top() - state.stack_space.bottom(); const auto callee_type = header.get_type(state.original_code, index); if (stack_size + callee_type.max_stack_increase > StackSpace::limit) { state.status = EVMC_STACK_OVERFLOW; return nullptr; } if (state.call_stack.size() >= StackSpace::limit) { // TODO: Add different error code. state.status = EVMC_STACK_OVERFLOW; return nullptr; } state.call_stack.push_back(pos + 3); const auto offset = header.code_offsets[index] - header.code_offsets[0]; return state.analysis.baseline->executable_code().data() + offset; }
O0
cpp
evmone::instr::core::callf(evmone::StackTop, evmone::ExecutionState&, unsigned char const*): pushq %rbp movq %rsp, %rbp subq $0x80, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq %rdx, -0x20(%rbp) movq -0x20(%rbp), %rdi addq $0x1, %rdi callq 0x6f960 movw %ax, -0x22(%rbp) movq -0x18(%rbp), %rax movq 0x1f8(%rax), %rdi callq 0x5ffc0 movq %rax, -0x30(%rbp) leaq -0x10(%rbp), %rdi callq 0x611d0 movq %rax, -0x78(%rbp) movq -0x18(%rbp), %rdi addq $0x218, %rdi # imm = 0x218 callq 0x3fb60 movq %rax, %rcx movq -0x78(%rbp), %rax subq %rcx, %rax sarq $0x5, %rax movq %rax, -0x38(%rbp) movq -0x30(%rbp), %rdi movq -0x18(%rbp), %rax movq 0x68(%rax), %rcx movq %rcx, -0x50(%rbp) movq 0x70(%rax), %rax movq %rax, -0x48(%rbp) movzwl -0x22(%rbp), %eax movl %eax, %ecx movq -0x50(%rbp), %rsi movq -0x48(%rbp), %rdx callq 0x70020 movl %eax, -0x3c(%rbp) movq -0x38(%rbp), %rax movzwl -0x3a(%rbp), %ecx addq %rcx, %rax cmpq $0x400, %rax # imm = 0x400 jle 0x6ff54 movq -0x18(%rbp), %rax movl $0x6, 0x78(%rax) movq $0x0, -0x8(%rbp) jmp 0x7000a movq -0x18(%rbp), %rdi addq $0x200, %rdi # imm = 0x200 callq 0x60b20 cmpq $0x400, %rax # imm = 0x400 jb 0x6ff84 movq -0x18(%rbp), %rax movl $0x6, 0x78(%rax) movq $0x0, -0x8(%rbp) jmp 0x7000a movq -0x18(%rbp), %rdi addq $0x200, %rdi # imm = 0x200 movq -0x20(%rbp), %rax addq $0x3, %rax movq %rax, -0x58(%rbp) leaq -0x58(%rbp), %rsi callq 0x700c0 jmp 0x6ffa6 movq -0x30(%rbp), %rdi addq $0x28, %rdi movzwl -0x22(%rbp), %eax movl %eax, %esi callq 0x3e560 movzwl (%rax), %eax movl %eax, -0x7c(%rbp) movq -0x30(%rbp), %rdi addq $0x28, %rdi xorl %eax, %eax movl %eax, %esi callq 0x3e560 movq %rax, %rcx movl -0x7c(%rbp), %eax movzwl (%rcx), %ecx subl %ecx, %eax movl %eax, -0x5c(%rbp) movq -0x18(%rbp), %rax movq 0x1f8(%rax), %rdi callq 0x5fd60 movq %rax, -0x70(%rbp) movq %rdx, -0x68(%rbp) leaq -0x70(%rbp), %rdi callq 0x5fd80 movslq -0x5c(%rbp), %rcx addq %rcx, %rax movq %rax, -0x8(%rbp) movq -0x8(%rbp), %rax addq $0x80, %rsp popq %rbp retq movq %rax, %rdi callq 0x37a70 nop
_ZN6evmone5instr4core5callfENS_8StackTopERNS_14ExecutionStateEPKh: push rbp mov rbp, rsp sub rsp, 80h mov [rbp+var_10], rdi mov [rbp+var_18], rsi mov [rbp+var_20], rdx mov rdi, [rbp+var_20] add rdi, 1 call _ZN6evmone14read_uint16_beIPKhEEtT_; evmone::read_uint16_be<uchar const*>(uchar const*) mov [rbp+var_22], ax mov rax, [rbp+var_18] mov rdi, [rax+1F8h]; this call _ZNK6evmone8baseline12CodeAnalysis10eof_headerEv; evmone::baseline::CodeAnalysis::eof_header(void) mov [rbp+var_30], rax lea rdi, [rbp+var_10]; this call _ZN6evmone8StackTop3topEv; evmone::StackTop::top(void) mov [rbp+var_78], rax mov rdi, [rbp+var_18] add rdi, 218h; this call _ZN6evmone10StackSpace6bottomEv; evmone::StackSpace::bottom(void) mov rcx, rax mov rax, [rbp+var_78] sub rax, rcx sar rax, 5 mov [rbp+var_38], rax mov rdi, [rbp+var_30] mov rax, [rbp+var_18] mov rcx, [rax+68h] mov [rbp+var_50], rcx mov rax, [rax+70h] mov [rbp+var_48], rax movzx eax, [rbp+var_22] mov ecx, eax mov rsi, [rbp+var_50] mov rdx, [rbp+var_48] call _ZNK6evmone10EOF1Header8get_typeESt17basic_string_viewIhN4evmc11byte_traitsIhEEEm; evmone::EOF1Header::get_type(std::basic_string_view<uchar,evmc::byte_traits<uchar>>,ulong) mov [rbp+var_3C], eax mov rax, [rbp+var_38] movzx ecx, word ptr [rbp+var_3C+2] add rax, rcx cmp rax, 400h jle short loc_6FF54 mov rax, [rbp+var_18] mov dword ptr [rax+78h], 6 mov [rbp+var_8], 0 jmp loc_7000A loc_6FF54: mov rdi, [rbp+var_18] add rdi, 200h call _ZNKSt6vectorIPKhSaIS1_EE4sizeEv; std::vector<uchar const*>::size(void) cmp rax, 400h jb short loc_6FF84 mov rax, [rbp+var_18] mov dword ptr [rax+78h], 6 mov [rbp+var_8], 0 jmp loc_7000A loc_6FF84: mov rdi, [rbp+var_18] add rdi, 200h mov rax, [rbp+var_20] add rax, 3 mov [rbp+var_58], rax lea rsi, [rbp+var_58] call _ZNSt6vectorIPKhSaIS1_EE9push_backEOS1_; std::vector<uchar const*>::push_back(uchar const*&&) jmp short $+2 loc_6FFA6: mov rdi, [rbp+var_30] add rdi, 28h ; '(' movzx eax, [rbp+var_22] mov esi, eax call _ZNKSt6vectorItSaItEEixEm; std::vector<ushort>::operator[](ulong) movzx eax, word ptr [rax] mov [rbp+var_7C], eax mov rdi, [rbp+var_30] add rdi, 28h ; '(' xor eax, eax mov esi, eax call _ZNKSt6vectorItSaItEEixEm; std::vector<ushort>::operator[](ulong) mov rcx, rax mov eax, [rbp+var_7C] movzx ecx, word ptr [rcx] sub eax, ecx mov [rbp+var_5C], eax mov rax, [rbp+var_18] mov rdi, [rax+1F8h]; this call _ZNK6evmone8baseline12CodeAnalysis15executable_codeEv; evmone::baseline::CodeAnalysis::executable_code(void) mov [rbp+var_70], rax mov [rbp+var_68], rdx lea rdi, [rbp+var_70] call _ZNKSt17basic_string_viewIhN4evmc11byte_traitsIhEEE4dataEv; std::basic_string_view<uchar,evmc::byte_traits<uchar>>::data(void) movsxd rcx, [rbp+var_5C] loc_70003: add rax, rcx mov [rbp+var_8], rax loc_7000A: mov rax, [rbp+var_8] add rsp, 80h pop rbp retn mov rdi, rax call __clang_call_terminate
long long evmone::instr::core::callf(long long a1, long long a2, long long a3) { long long v3; // rdx long long v4; // rax int v6; // [rsp+4h] [rbp-7Ch] long long v7; // [rsp+8h] [rbp-78h] _QWORD v8[2]; // [rsp+10h] [rbp-70h] BYREF int v9; // [rsp+24h] [rbp-5Ch] long long v10; // [rsp+28h] [rbp-58h] BYREF long long v11; // [rsp+30h] [rbp-50h] long long v12; // [rsp+38h] [rbp-48h] int type; // [rsp+44h] [rbp-3Ch] long long v14; // [rsp+48h] [rbp-38h] long long v15; // [rsp+50h] [rbp-30h] unsigned __int16 uint16; // [rsp+5Eh] [rbp-22h] long long v17; // [rsp+60h] [rbp-20h] long long v18; // [rsp+68h] [rbp-18h] long long v19; // [rsp+70h] [rbp-10h] BYREF v19 = a1; v18 = a2; v17 = a3; uint16 = evmone::read_uint16_be<unsigned char const*>((_BYTE *)(a3 + 1)); v15 = evmone::baseline::CodeAnalysis::eof_header(*(evmone::baseline::CodeAnalysis **)(a2 + 504)); v7 = evmone::StackTop::top((evmone::StackTop *)&v19); v14 = (v7 - evmone::StackSpace::bottom((evmone::StackSpace *)(a2 + 536))) >> 5; v11 = *(_QWORD *)(a2 + 104); v12 = *(_QWORD *)(a2 + 112); type = evmone::EOF1Header::get_type(v15, v11, v12, uint16); if ( HIWORD(type) + v14 <= 1024 ) { if ( (unsigned long long)std::vector<unsigned char const*>::size((_QWORD *)(v18 + 512)) < 0x400 ) { v10 = v17 + 3; std::vector<unsigned char const*>::push_back(v18 + 512, &v10); v6 = *(unsigned __int16 *)std::vector<unsigned short>::operator[]((_QWORD *)(v15 + 40), uint16); v9 = v6 - *(unsigned __int16 *)std::vector<unsigned short>::operator[]((_QWORD *)(v15 + 40), 0LL); v8[0] = evmone::baseline::CodeAnalysis::executable_code(*(evmone::baseline::CodeAnalysis **)(v18 + 504)); v8[1] = v3; v4 = std::basic_string_view<unsigned char,evmc::byte_traits<unsigned char>>::data((long long)v8); return v9 + v4; } else { *(_DWORD *)(v18 + 120) = 6; return 0LL; } } else { *(_DWORD *)(v18 + 120) = 6; return 0LL; } }
callf: PUSH RBP MOV RBP,RSP SUB RSP,0x80 MOV qword ptr [RBP + -0x10],RDI MOV qword ptr [RBP + -0x18],RSI MOV qword ptr [RBP + -0x20],RDX MOV RDI,qword ptr [RBP + -0x20] ADD RDI,0x1 CALL 0x0016f960 MOV word ptr [RBP + -0x22],AX MOV RAX,qword ptr [RBP + -0x18] MOV RDI,qword ptr [RAX + 0x1f8] CALL 0x0015ffc0 MOV qword ptr [RBP + -0x30],RAX LEA RDI,[RBP + -0x10] CALL 0x001611d0 MOV qword ptr [RBP + -0x78],RAX MOV RDI,qword ptr [RBP + -0x18] ADD RDI,0x218 CALL 0x0013fb60 MOV RCX,RAX MOV RAX,qword ptr [RBP + -0x78] SUB RAX,RCX SAR RAX,0x5 MOV qword ptr [RBP + -0x38],RAX MOV RDI,qword ptr [RBP + -0x30] MOV RAX,qword ptr [RBP + -0x18] MOV RCX,qword ptr [RAX + 0x68] MOV qword ptr [RBP + -0x50],RCX MOV RAX,qword ptr [RAX + 0x70] MOV qword ptr [RBP + -0x48],RAX MOVZX EAX,word ptr [RBP + -0x22] MOV ECX,EAX MOV RSI,qword ptr [RBP + -0x50] MOV RDX,qword ptr [RBP + -0x48] CALL 0x00170020 MOV dword ptr [RBP + -0x3c],EAX MOV RAX,qword ptr [RBP + -0x38] MOVZX ECX,word ptr [RBP + -0x3a] ADD RAX,RCX CMP RAX,0x400 JLE 0x0016ff54 MOV RAX,qword ptr [RBP + -0x18] MOV dword ptr [RAX + 0x78],0x6 MOV qword ptr [RBP + -0x8],0x0 JMP 0x0017000a LAB_0016ff54: MOV RDI,qword ptr [RBP + -0x18] ADD RDI,0x200 CALL 0x00160b20 CMP RAX,0x400 JC 0x0016ff84 MOV RAX,qword ptr [RBP + -0x18] MOV dword ptr [RAX + 0x78],0x6 MOV qword ptr [RBP + -0x8],0x0 JMP 0x0017000a LAB_0016ff84: MOV RDI,qword ptr [RBP + -0x18] ADD RDI,0x200 MOV RAX,qword ptr [RBP + -0x20] ADD RAX,0x3 MOV qword ptr [RBP + -0x58],RAX LAB_0016ff9b: LEA RSI,[RBP + -0x58] CALL 0x001700c0 JMP 0x0016ffa6 LAB_0016ffa6: MOV RDI,qword ptr [RBP + -0x30] ADD RDI,0x28 MOVZX EAX,word ptr [RBP + -0x22] MOV ESI,EAX CALL 0x0013e560 MOVZX EAX,word ptr [RAX] MOV dword ptr [RBP + -0x7c],EAX MOV RDI,qword ptr [RBP + -0x30] ADD RDI,0x28 XOR EAX,EAX MOV ESI,EAX CALL 0x0013e560 MOV RCX,RAX MOV EAX,dword ptr [RBP + -0x7c] MOVZX ECX,word ptr [RCX] SUB EAX,ECX MOV dword ptr [RBP + -0x5c],EAX MOV RAX,qword ptr [RBP + -0x18] MOV RDI,qword ptr [RAX + 0x1f8] CALL 0x0015fd60 MOV qword ptr [RBP + -0x70],RAX MOV qword ptr [RBP + -0x68],RDX LEA RDI,[RBP + -0x70] CALL 0x0015fd80 MOVSXD RCX,dword ptr [RBP + -0x5c] ADD RAX,RCX MOV qword ptr [RBP + -0x8],RAX LAB_0017000a: MOV RAX,qword ptr [RBP + -0x8] ADD RSP,0x80 POP RBP RET
/* evmone::instr::core::callf(evmone::StackTop, evmone::ExecutionState&, unsigned char const*) */ long evmone::instr::core::callf(int8 param_1,long param_2,long param_3) { ushort uVar1; int4 uVar2; long lVar3; long lVar4; ulong uVar5; ushort *puVar6; basic_string_view<unsigned_char,evmc::byte_traits<unsigned_char>> local_78 [20]; int local_64; uchar *local_60; int8 local_58; int8 local_50; int4 local_44; long local_40; long local_38; ushort local_2a; long local_28; long local_20; int8 local_18; long local_10; local_28 = param_3; local_20 = param_2; local_18 = param_1; local_2a = read_uint16_be<unsigned_char_const*>((uchar *)(param_3 + 1)); local_38 = baseline::CodeAnalysis::eof_header(*(CodeAnalysis **)(local_20 + 0x1f8)); lVar3 = StackTop::top((StackTop *)&local_18); lVar4 = StackSpace::bottom((StackSpace *)(local_20 + 0x218)); local_40 = lVar3 - lVar4 >> 5; local_58 = *(int8 *)(local_20 + 0x68); local_50 = *(int8 *)(local_20 + 0x70); uVar2 = EOF1Header::get_type(local_38,local_58,local_50,local_2a); local_44._2_2_ = (ushort)((uint)uVar2 >> 0x10); if ((long)(local_40 + (ulong)local_44._2_2_) < 0x401) { local_44 = uVar2; uVar5 = std::vector<unsigned_char_const*,std::allocator<unsigned_char_const*>>::size ((vector<unsigned_char_const*,std::allocator<unsigned_char_const*>> *) (local_20 + 0x200)); if (uVar5 < 0x400) { local_60 = (uchar *)(local_28 + 3); /* try { // try from 0016ff9b to 0016ffa3 has its CatchHandler @ 00170017 */ std::vector<unsigned_char_const*,std::allocator<unsigned_char_const*>>::push_back ((vector<unsigned_char_const*,std::allocator<unsigned_char_const*>> *) (local_20 + 0x200),&local_60); puVar6 = (ushort *) std::vector<unsigned_short,std::allocator<unsigned_short>>::operator[] ((vector<unsigned_short,std::allocator<unsigned_short>> *)(local_38 + 0x28) ,(ulong)local_2a); uVar1 = *puVar6; puVar6 = (ushort *) std::vector<unsigned_short,std::allocator<unsigned_short>>::operator[] ((vector<unsigned_short,std::allocator<unsigned_short>> *)(local_38 + 0x28) ,0); local_64 = (uint)uVar1 - (uint)*puVar6; local_78._0_16_ = baseline::CodeAnalysis::executable_code(*(CodeAnalysis **)(local_20 + 0x1f8)); local_10 = std::basic_string_view<unsigned_char,evmc::byte_traits<unsigned_char>>::data (local_78); local_10 = local_10 + local_64; } else { *(int4 *)(local_20 + 0x78) = 6; local_10 = 0; } } else { *(int4 *)(local_20 + 0x78) = 6; local_10 = 0; } return local_10; }
27,562
my_thread_destory_thr_mutex
eloqsql/mysys/my_thr_init.c
static void my_thread_destory_thr_mutex(struct st_my_thread_var *var) { mysql_mutex_destroy(&var->mutex); mysql_cond_destroy(&var->suspend); }
O3
c
my_thread_destory_thr_mutex: pushq %rbp movq %rsp, %rbp pushq %r14 pushq %rbx movq %rdi, %rbx leaq 0x40(%rdi), %r14 movq 0x80(%rdi), %rdi testq %rdi, %rdi je 0x633bf leaq 0x2daafa(%rip), %rax # 0x33dea8 movq (%rax), %rax callq *0x48(%rax) movq $0x0, 0x80(%rbx) movq %r14, %rdi callq 0x360f0 movq 0x38(%rbx), %rdi testq %rdi, %rdi jne 0x633e0 addq $0x8, %rbx movq %rbx, %rdi popq %rbx popq %r14 popq %rbp jmp 0x362c0 leaq 0x2daac1(%rip), %rax # 0x33dea8 movq (%rax), %rax callq *0x68(%rax) movq $0x0, 0x38(%rbx) jmp 0x633d0
my_thread_destory_thr_mutex: push rbp mov rbp, rsp push r14 push rbx mov rbx, rdi lea r14, [rdi+40h] mov rdi, [rdi+80h] test rdi, rdi jz short loc_633BF lea rax, PSI_server mov rax, [rax] call qword ptr [rax+48h] mov qword ptr [rbx+80h], 0 loc_633BF: mov rdi, r14 call _pthread_mutex_destroy mov rdi, [rbx+38h] test rdi, rdi jnz short loc_633E0 loc_633D0: add rbx, 8 mov rdi, rbx pop rbx pop r14 pop rbp jmp _pthread_cond_destroy loc_633E0: lea rax, PSI_server mov rax, [rax] call qword ptr [rax+68h] mov qword ptr [rbx+38h], 0 jmp short loc_633D0
long long my_thread_destory_thr_mutex(long long a1) { if ( *(_QWORD *)(a1 + 128) ) { (*((void (**)(void))PSI_server + 9))(); *(_QWORD *)(a1 + 128) = 0LL; } pthread_mutex_destroy(a1 + 64); if ( *(_QWORD *)(a1 + 56) ) { (*((void (**)(void))PSI_server + 13))(); *(_QWORD *)(a1 + 56) = 0LL; } return pthread_cond_destroy(a1 + 8); }
my_thread_destory_thr_mutex: PUSH RBP MOV RBP,RSP PUSH R14 PUSH RBX MOV RBX,RDI LEA R14,[RDI + 0x40] MOV RDI,qword ptr [RDI + 0x80] TEST RDI,RDI JZ 0x001633bf LEA RAX,[0x43dea8] MOV RAX,qword ptr [RAX] CALL qword ptr [RAX + 0x48] MOV qword ptr [RBX + 0x80],0x0 LAB_001633bf: MOV RDI,R14 CALL 0x001360f0 MOV RDI,qword ptr [RBX + 0x38] TEST RDI,RDI JNZ 0x001633e0 LAB_001633d0: ADD RBX,0x8 MOV RDI,RBX POP RBX POP R14 POP RBP JMP 0x001362c0 LAB_001633e0: LEA RAX,[0x43dea8] MOV RAX,qword ptr [RAX] CALL qword ptr [RAX + 0x68] MOV qword ptr [RBX + 0x38],0x0 JMP 0x001633d0
void my_thread_destory_thr_mutex(long param_1) { if (*(long *)(param_1 + 0x80) != 0) { (**(code **)(PSI_server + 0x48))(); *(int8 *)(param_1 + 0x80) = 0; } pthread_mutex_destroy((pthread_mutex_t *)(param_1 + 0x40)); if (*(long *)(param_1 + 0x38) != 0) { (**(code **)(PSI_server + 0x68))(); *(int8 *)(param_1 + 0x38) = 0; } pthread_cond_destroy((pthread_cond_t *)(param_1 + 8)); return; }
27,563
func_uni_big5_onechar
eloqsql/strings/ctype-big5.c
static int func_uni_big5_onechar(int code){ if ((code>=0x00A2)&&(code<=0x00F7)) return(tab_uni_big50[code-0x00A2]); if ((code>=0x02C7)&&(code<=0x0451)) return(tab_uni_big51[code-0x02C7]); if ((code>=0x2013)&&(code<=0x22BF)) return(tab_uni_big52[code-0x2013]); if ((code>=0x2460)&&(code<=0x2642)) return(tab_uni_big53[code-0x2460]); if ((code>=0x3000)&&(code<=0x3129)) return(tab_uni_big54[code-0x3000]); if ((code>=0x32A3)&&(code<=0x32A3)) return(tab_uni_big55[code-0x32A3]); if ((code>=0x338E)&&(code<=0x33D5)) return(tab_uni_big56[code-0x338E]); if ((code>=0x4E00)&&(code<=0x9483)) return(tab_uni_big57[code-0x4E00]); if ((code>=0x9577)&&(code<=0x9FA4)) return(tab_uni_big58[code-0x9577]); if ((code>=0xFA0C)&&(code<=0xFA0D)) return(tab_uni_big59[code-0xFA0C]); if ((code>=0xFE30)&&(code<=0xFFFD)) return(tab_uni_big510[code-0xFE30]); return(0); }
O0
c
func_uni_big5_onechar: pushq %rbp movq %rsp, %rbp movl %edi, -0x8(%rbp) cmpl $0xa2, -0x8(%rbp) jl 0x6b657 cmpl $0xf7, -0x8(%rbp) jg 0x6b657 movl -0x8(%rbp), %eax subl $0xa2, %eax movslq %eax, %rcx leaq 0x56765(%rip), %rax # 0xc1db0 movzwl (%rax,%rcx,2), %eax movl %eax, -0x4(%rbp) jmp 0x6b835 cmpl $0x2c7, -0x8(%rbp) # imm = 0x2C7 jl 0x6b687 cmpl $0x451, -0x8(%rbp) # imm = 0x451 jg 0x6b687 movl -0x8(%rbp), %eax subl $0x2c7, %eax # imm = 0x2C7 movslq %eax, %rcx leaq 0x567e5(%rip), %rax # 0xc1e60 movzwl (%rax,%rcx,2), %eax movl %eax, -0x4(%rbp) jmp 0x6b835 cmpl $0x2013, -0x8(%rbp) # imm = 0x2013 jl 0x6b6b7 cmpl $0x22bf, -0x8(%rbp) # imm = 0x22BF jg 0x6b6b7 movl -0x8(%rbp), %eax subl $0x2013, %eax # imm = 0x2013 movslq %eax, %rcx leaq 0x56ad5(%rip), %rax # 0xc2180 movzwl (%rax,%rcx,2), %eax movl %eax, -0x4(%rbp) jmp 0x6b835 cmpl $0x2460, -0x8(%rbp) # imm = 0x2460 jl 0x6b6e7 cmpl $0x2642, -0x8(%rbp) # imm = 0x2642 jg 0x6b6e7 movl -0x8(%rbp), %eax subl $0x2460, %eax # imm = 0x2460 movslq %eax, %rcx leaq 0x57005(%rip), %rax # 0xc26e0 movzwl (%rax,%rcx,2), %eax movl %eax, -0x4(%rbp) jmp 0x6b835 cmpl $0x3000, -0x8(%rbp) # imm = 0x3000 jl 0x6b717 cmpl $0x3129, -0x8(%rbp) # imm = 0x3129 jg 0x6b717 movl -0x8(%rbp), %eax subl $0x3000, %eax # imm = 0x3000 movslq %eax, %rcx leaq 0x573a5(%rip), %rax # 0xc2ab0 movzwl (%rax,%rcx,2), %eax movl %eax, -0x4(%rbp) jmp 0x6b835 cmpl $0x32a3, -0x8(%rbp) # imm = 0x32A3 jl 0x6b747 cmpl $0x32a3, -0x8(%rbp) # imm = 0x32A3 jg 0x6b747 movl -0x8(%rbp), %eax subl $0x32a3, %eax # imm = 0x32A3 movslq %eax, %rcx leaq 0x575c9(%rip), %rax # 0xc2d04 movzwl (%rax,%rcx,2), %eax movl %eax, -0x4(%rbp) jmp 0x6b835 cmpl $0x338e, -0x8(%rbp) # imm = 0x338E jl 0x6b777 cmpl $0x33d5, -0x8(%rbp) # imm = 0x33D5 jg 0x6b777 movl -0x8(%rbp), %eax subl $0x338e, %eax # imm = 0x338E movslq %eax, %rcx leaq 0x575a5(%rip), %rax # 0xc2d10 movzwl (%rax,%rcx,2), %eax movl %eax, -0x4(%rbp) jmp 0x6b835 cmpl $0x4e00, -0x8(%rbp) # imm = 0x4E00 jl 0x6b7a7 cmpl $0x9483, -0x8(%rbp) # imm = 0x9483 jg 0x6b7a7 movl -0x8(%rbp), %eax subl $0x4e00, %eax # imm = 0x4E00 movslq %eax, %rcx leaq 0x57605(%rip), %rax # 0xc2da0 movzwl (%rax,%rcx,2), %eax movl %eax, -0x4(%rbp) jmp 0x6b835 cmpl $0x9577, -0x8(%rbp) # imm = 0x9577 jl 0x6b7d4 cmpl $0x9fa4, -0x8(%rbp) # imm = 0x9FA4 jg 0x6b7d4 movl -0x8(%rbp), %eax subl $0x9577, %eax # imm = 0x9577 movslq %eax, %rcx leaq 0x602e5(%rip), %rax # 0xcbab0 movzwl (%rax,%rcx,2), %eax movl %eax, -0x4(%rbp) jmp 0x6b835 cmpl $0xfa0c, -0x8(%rbp) # imm = 0xFA0C jl 0x6b801 cmpl $0xfa0d, -0x8(%rbp) # imm = 0xFA0D jg 0x6b801 movl -0x8(%rbp), %eax subl $0xfa0c, %eax # imm = 0xFA0C movslq %eax, %rcx leaq 0x61714(%rip), %rax # 0xccf0c movzwl (%rax,%rcx,2), %eax movl %eax, -0x4(%rbp) jmp 0x6b835 cmpl $0xfe30, -0x8(%rbp) # imm = 0xFE30 jl 0x6b82e cmpl $0xfffd, -0x8(%rbp) # imm = 0xFFFD jg 0x6b82e movl -0x8(%rbp), %eax subl $0xfe30, %eax # imm = 0xFE30 movslq %eax, %rcx leaq 0x616eb(%rip), %rax # 0xccf10 movzwl (%rax,%rcx,2), %eax movl %eax, -0x4(%rbp) jmp 0x6b835 movl $0x0, -0x4(%rbp) movl -0x4(%rbp), %eax popq %rbp retq nopw (%rax,%rax)
func_uni_big5_onechar: push rbp mov rbp, rsp mov [rbp+var_8], edi cmp [rbp+var_8], 0A2h jl short loc_6B657 cmp [rbp+var_8], 0F7h jg short loc_6B657 mov eax, [rbp+var_8] sub eax, 0A2h movsxd rcx, eax lea rax, tab_uni_big50 movzx eax, word ptr [rax+rcx*2] mov [rbp+var_4], eax jmp loc_6B835 loc_6B657: cmp [rbp+var_8], 2C7h jl short loc_6B687 cmp [rbp+var_8], 451h jg short loc_6B687 mov eax, [rbp+var_8] sub eax, 2C7h movsxd rcx, eax lea rax, tab_uni_big51 movzx eax, word ptr [rax+rcx*2] mov [rbp+var_4], eax jmp loc_6B835 loc_6B687: cmp [rbp+var_8], 2013h jl short loc_6B6B7 cmp [rbp+var_8], 22BFh jg short loc_6B6B7 mov eax, [rbp+var_8] sub eax, 2013h movsxd rcx, eax lea rax, tab_uni_big52 movzx eax, word ptr [rax+rcx*2] mov [rbp+var_4], eax jmp loc_6B835 loc_6B6B7: cmp [rbp+var_8], 2460h jl short loc_6B6E7 cmp [rbp+var_8], 2642h jg short loc_6B6E7 mov eax, [rbp+var_8] sub eax, 2460h movsxd rcx, eax lea rax, tab_uni_big53 movzx eax, word ptr [rax+rcx*2] mov [rbp+var_4], eax jmp loc_6B835 loc_6B6E7: cmp [rbp+var_8], 3000h jl short loc_6B717 cmp [rbp+var_8], 3129h jg short loc_6B717 mov eax, [rbp+var_8] sub eax, 3000h movsxd rcx, eax lea rax, tab_uni_big54 movzx eax, word ptr [rax+rcx*2] mov [rbp+var_4], eax jmp loc_6B835 loc_6B717: cmp [rbp+var_8], 32A3h jl short loc_6B747 cmp [rbp+var_8], 32A3h jg short loc_6B747 mov eax, [rbp+var_8] sub eax, 32A3h movsxd rcx, eax lea rax, tab_uni_big55 movzx eax, word ptr [rax+rcx*2] mov [rbp+var_4], eax jmp loc_6B835 loc_6B747: cmp [rbp+var_8], 338Eh jl short loc_6B777 cmp [rbp+var_8], 33D5h jg short loc_6B777 mov eax, [rbp+var_8] sub eax, 338Eh movsxd rcx, eax lea rax, tab_uni_big56 movzx eax, word ptr [rax+rcx*2] mov [rbp+var_4], eax jmp loc_6B835 loc_6B777: cmp [rbp+var_8], 4E00h jl short loc_6B7A7 cmp [rbp+var_8], 9483h jg short loc_6B7A7 mov eax, [rbp+var_8] sub eax, 4E00h movsxd rcx, eax lea rax, tab_uni_big57 movzx eax, word ptr [rax+rcx*2] mov [rbp+var_4], eax jmp loc_6B835 loc_6B7A7: cmp [rbp+var_8], 9577h jl short loc_6B7D4 cmp [rbp+var_8], 9FA4h jg short loc_6B7D4 mov eax, [rbp+var_8] sub eax, 9577h movsxd rcx, eax lea rax, tab_uni_big58 movzx eax, word ptr [rax+rcx*2] mov [rbp+var_4], eax jmp short loc_6B835 loc_6B7D4: cmp [rbp+var_8], 0FA0Ch jl short loc_6B801 cmp [rbp+var_8], 0FA0Dh jg short loc_6B801 mov eax, [rbp+var_8] sub eax, 0FA0Ch movsxd rcx, eax lea rax, tab_uni_big59 movzx eax, word ptr [rax+rcx*2] mov [rbp+var_4], eax jmp short loc_6B835 loc_6B801: cmp [rbp+var_8], 0FE30h jl short loc_6B82E cmp [rbp+var_8], 0FFFDh jg short loc_6B82E mov eax, [rbp+var_8] sub eax, 0FE30h movsxd rcx, eax lea rax, tab_uni_big510 movzx eax, word ptr [rax+rcx*2] mov [rbp+var_4], eax jmp short loc_6B835 loc_6B82E: mov [rbp+var_4], 0 loc_6B835: mov eax, [rbp+var_4] pop rbp retn
long long func_uni_big5_onechar(int a1) { if ( a1 < 162 || a1 > 247 ) { if ( a1 < 711 || a1 > 1105 ) { if ( a1 < 8211 || a1 > 8895 ) { if ( a1 < 9312 || a1 > 9794 ) { if ( a1 < 12288 || a1 > 12585 ) { if ( a1 == 12963 ) { return tab_uni_big55; } else if ( a1 < 13198 || a1 > 13269 ) { if ( a1 < 19968 || a1 > 38019 ) { if ( a1 < 38263 || a1 > 40868 ) { if ( a1 < 64012 || a1 > 64013 ) { if ( a1 < 65072 || a1 > 65533 ) return 0; else return tab_uni_big510[a1 - 65072]; } else { return tab_uni_big59[a1 - 64012]; } } else { return tab_uni_big58[a1 - 38263]; } } else { return tab_uni_big57[a1 - 19968]; } } else { return tab_uni_big56[a1 - 13198]; } } else { return tab_uni_big54[a1 - 12288]; } } else { return tab_uni_big53[a1 - 9312]; } } else { return tab_uni_big52[a1 - 8211]; } } else { return tab_uni_big51[a1 - 711]; } } else { return tab_uni_big50[a1 - 162]; } }
func_uni_big5_onechar: PUSH RBP MOV RBP,RSP MOV dword ptr [RBP + -0x8],EDI CMP dword ptr [RBP + -0x8],0xa2 JL 0x0016b657 CMP dword ptr [RBP + -0x8],0xf7 JG 0x0016b657 MOV EAX,dword ptr [RBP + -0x8] SUB EAX,0xa2 MOVSXD RCX,EAX LEA RAX,[0x1c1db0] MOVZX EAX,word ptr [RAX + RCX*0x2] MOV dword ptr [RBP + -0x4],EAX JMP 0x0016b835 LAB_0016b657: CMP dword ptr [RBP + -0x8],0x2c7 JL 0x0016b687 CMP dword ptr [RBP + -0x8],0x451 JG 0x0016b687 MOV EAX,dword ptr [RBP + -0x8] SUB EAX,0x2c7 MOVSXD RCX,EAX LEA RAX,[0x1c1e60] MOVZX EAX,word ptr [RAX + RCX*0x2] MOV dword ptr [RBP + -0x4],EAX JMP 0x0016b835 LAB_0016b687: CMP dword ptr [RBP + -0x8],0x2013 JL 0x0016b6b7 CMP dword ptr [RBP + -0x8],0x22bf JG 0x0016b6b7 MOV EAX,dword ptr [RBP + -0x8] SUB EAX,0x2013 MOVSXD RCX,EAX LEA RAX,[0x1c2180] MOVZX EAX,word ptr [RAX + RCX*0x2] MOV dword ptr [RBP + -0x4],EAX JMP 0x0016b835 LAB_0016b6b7: CMP dword ptr [RBP + -0x8],0x2460 JL 0x0016b6e7 CMP dword ptr [RBP + -0x8],0x2642 JG 0x0016b6e7 MOV EAX,dword ptr [RBP + -0x8] SUB EAX,0x2460 MOVSXD RCX,EAX LEA RAX,[0x1c26e0] MOVZX EAX,word ptr [RAX + RCX*0x2] MOV dword ptr [RBP + -0x4],EAX JMP 0x0016b835 LAB_0016b6e7: CMP dword ptr [RBP + -0x8],0x3000 JL 0x0016b717 CMP dword ptr [RBP + -0x8],0x3129 JG 0x0016b717 MOV EAX,dword ptr [RBP + -0x8] SUB EAX,0x3000 MOVSXD RCX,EAX LEA RAX,[0x1c2ab0] MOVZX EAX,word ptr [RAX + RCX*0x2] MOV dword ptr [RBP + -0x4],EAX JMP 0x0016b835 LAB_0016b717: CMP dword ptr [RBP + -0x8],0x32a3 JL 0x0016b747 CMP dword ptr [RBP + -0x8],0x32a3 JG 0x0016b747 MOV EAX,dword ptr [RBP + -0x8] SUB EAX,0x32a3 MOVSXD RCX,EAX LEA RAX,[0x1c2d04] MOVZX EAX,word ptr [RAX + RCX*0x2] MOV dword ptr [RBP + -0x4],EAX JMP 0x0016b835 LAB_0016b747: CMP dword ptr [RBP + -0x8],0x338e JL 0x0016b777 CMP dword ptr [RBP + -0x8],0x33d5 JG 0x0016b777 MOV EAX,dword ptr [RBP + -0x8] SUB EAX,0x338e MOVSXD RCX,EAX LEA RAX,[0x1c2d10] MOVZX EAX,word ptr [RAX + RCX*0x2] MOV dword ptr [RBP + -0x4],EAX JMP 0x0016b835 LAB_0016b777: CMP dword ptr [RBP + -0x8],0x4e00 JL 0x0016b7a7 CMP dword ptr [RBP + -0x8],0x9483 JG 0x0016b7a7 MOV EAX,dword ptr [RBP + -0x8] SUB EAX,0x4e00 MOVSXD RCX,EAX LEA RAX,[0x1c2da0] MOVZX EAX,word ptr [RAX + RCX*0x2] MOV dword ptr [RBP + -0x4],EAX JMP 0x0016b835 LAB_0016b7a7: CMP dword ptr [RBP + -0x8],0x9577 JL 0x0016b7d4 CMP dword ptr [RBP + -0x8],0x9fa4 JG 0x0016b7d4 MOV EAX,dword ptr [RBP + -0x8] SUB EAX,0x9577 MOVSXD RCX,EAX LEA RAX,[0x1cbab0] MOVZX EAX,word ptr [RAX + RCX*0x2] MOV dword ptr [RBP + -0x4],EAX JMP 0x0016b835 LAB_0016b7d4: CMP dword ptr [RBP + -0x8],0xfa0c JL 0x0016b801 CMP dword ptr [RBP + -0x8],0xfa0d JG 0x0016b801 MOV EAX,dword ptr [RBP + -0x8] SUB EAX,0xfa0c MOVSXD RCX,EAX LEA RAX,[0x1ccf0c] MOVZX EAX,word ptr [RAX + RCX*0x2] MOV dword ptr [RBP + -0x4],EAX JMP 0x0016b835 LAB_0016b801: CMP dword ptr [RBP + -0x8],0xfe30 JL 0x0016b82e CMP dword ptr [RBP + -0x8],0xfffd JG 0x0016b82e MOV EAX,dword ptr [RBP + -0x8] SUB EAX,0xfe30 MOVSXD RCX,EAX LEA RAX,[0x1ccf10] MOVZX EAX,word ptr [RAX + RCX*0x2] MOV dword ptr [RBP + -0x4],EAX JMP 0x0016b835 LAB_0016b82e: MOV dword ptr [RBP + -0x4],0x0 LAB_0016b835: MOV EAX,dword ptr [RBP + -0x4] POP RBP RET
int2 func_uni_big5_onechar(int param_1) { int2 uVar1; if ((param_1 < 0xa2) || (0xf7 < param_1)) { if ((param_1 < 0x2c7) || (0x451 < param_1)) { if ((param_1 < 0x2013) || (0x22bf < param_1)) { if ((param_1 < 0x2460) || (0x2642 < param_1)) { if ((param_1 < 0x3000) || (0x3129 < param_1)) { if ((param_1 < 0x32a3) || (0x32a3 < param_1)) { if ((param_1 < 0x338e) || (0x33d5 < param_1)) { if ((param_1 < 0x4e00) || (0x9483 < param_1)) { if ((param_1 < 0x9577) || (0x9fa4 < param_1)) { if ((param_1 < 0xfa0c) || (0xfa0d < param_1)) { if ((param_1 < 0xfe30) || (0xfffd < param_1)) { uVar1 = 0; } else { uVar1 = *(int2 *)(tab_uni_big510 + (long)(param_1 + -0xfe30) * 2); } } else { uVar1 = *(int2 *)((long)&tab_uni_big59 + (long)(param_1 + -0xfa0c) * 2); } } else { uVar1 = *(int2 *)(tab_uni_big58 + (long)(param_1 + -0x9577) * 2); } } else { uVar1 = *(int2 *)(tab_uni_big57 + (long)(param_1 + -0x4e00) * 2); } } else { uVar1 = *(int2 *)(tab_uni_big56 + (long)(param_1 + -0x338e) * 2); } } else { uVar1 = (&tab_uni_big55)[param_1 + -0x32a3]; } } else { uVar1 = *(int2 *)(tab_uni_big54 + (long)(param_1 + -0x3000) * 2); } } else { uVar1 = *(int2 *)(tab_uni_big53 + (long)(param_1 + -0x2460) * 2); } } else { uVar1 = *(int2 *)(tab_uni_big52 + (long)(param_1 + -0x2013) * 2); } } else { uVar1 = *(int2 *)(tab_uni_big51 + (long)(param_1 + -0x2c7) * 2); } } else { uVar1 = *(int2 *)(tab_uni_big50 + (long)(param_1 + -0xa2) * 2); } return uVar1; }
27,564
nglog::LogMessage::~LogMessage()
ng-log[P]ng-log/src/logging.cc
LogMessage::~LogMessage() noexcept(false) { Flush(); bool fail = data_->severity_ == NGLOG_FATAL && exit_on_dfatal; #ifdef NGLOG_THREAD_LOCAL_STORAGE if (data_ == static_cast<void*>(&thread_msg_data)) { data_->~LogMessageData(); thread_data_available = true; } else { delete allocated_; } #else // !defined(NGLOG_THREAD_LOCAL_STORAGE) delete allocated_; #endif // defined(NGLOG_THREAD_LOCAL_STORAGE) // if (fail) { const char* message = "*** Check failure stack trace: ***\n"; if (write(fileno(stderr), message, strlen(message)) < 0) { // Ignore errors. } AlsoErrorWrite(NGLOG_FATAL, tools::ProgramInvocationShortName(), message); #if defined(__cpp_lib_uncaught_exceptions) && \ (__cpp_lib_uncaught_exceptions >= 201411L) if (std::uncaught_exceptions() == 0) #else if (!std::uncaught_exception()) #endif { Fail(); } } }
O0
cpp
nglog::LogMessage::~LogMessage(): pushq %rbp movq %rsp, %rbp subq $0x40, %rsp movq %rdi, -0x8(%rbp) movq -0x8(%rbp), %rdi movq %rdi, -0x28(%rbp) callq 0xf750 movq -0x28(%rbp), %rax movq 0x8(%rax), %rcx xorl %eax, %eax cmpl $0x3, 0x7698(%rcx) movb %al, -0x19(%rbp) jne 0xf698 movb 0x610d7(%rip), %al # 0x7076c movb %al, -0x19(%rbp) movq -0x28(%rbp), %rax movb -0x19(%rbp), %cl andb $0x1, %cl movb %cl, -0x9(%rbp) movq (%rax), %rax movq %rax, -0x30(%rbp) cmpq $0x0, %rax je 0xf6c9 movq -0x30(%rbp), %rdi callq 0x17bc0 movq -0x30(%rbp), %rdi movl $0x76f0, %esi # imm = 0x76F0 callq 0x9730 testb $0x1, -0x9(%rbp) je 0xf73b leaq 0x3e060(%rip), %rax # 0x4d736 movq %rax, -0x18(%rbp) movq 0x608cf(%rip), %rax # 0x6ffb0 movq (%rax), %rdi callq 0x9790 movl %eax, -0x3c(%rbp) movq -0x18(%rbp), %rax movq %rax, -0x38(%rbp) movq -0x18(%rbp), %rdi callq 0x92e0 movl -0x3c(%rbp), %edi movq -0x38(%rbp), %rsi movq %rax, %rdx callq 0x9220 cmpq $0x0, %rax jge 0xf714 jmp 0xf714 callq 0x4b280 movq %rax, %rsi movq -0x18(%rbp), %rdx movl $0x3, %edi callq 0x4b210 callq 0x98d0 cmpl $0x0, %eax jne 0xf739 callq 0xf980 jmp 0xf73b addq $0x40, %rsp popq %rbp retq nopw %cs:(%rax,%rax)
_ZN5nglog10LogMessageD2Ev: push rbp; Alternative name is 'nglog::LogMessage::~LogMessage()' mov rbp, rsp sub rsp, 40h mov [rbp+var_8], rdi mov rdi, [rbp+var_8]; this mov [rbp+var_28], rdi call _ZN5nglog10LogMessage5FlushEv; nglog::LogMessage::Flush(void) mov rax, [rbp+var_28] mov rcx, [rax+8] xor eax, eax cmp dword ptr [rcx+7698h], 3 mov [rbp+var_19], al jnz short loc_F698 mov al, cs:_ZN5nglogL14exit_on_dfatalE; nglog::exit_on_dfatal mov [rbp+var_19], al loc_F698: mov rax, [rbp+var_28] mov cl, [rbp+var_19] and cl, 1 mov [rbp+var_9], cl mov rax, [rax] mov [rbp+var_30], rax cmp rax, 0 jz short loc_F6C9 mov rdi, [rbp+var_30]; void * call _ZN5nglog8internal14LogMessageDataD2Ev; nglog::internal::LogMessageData::~LogMessageData() mov rdi, [rbp+var_30]; void * mov esi, 76F0h; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_F6C9: test [rbp+var_9], 1 jz short loc_F73B lea rax, aCheckFailureSt; "*** Check failure stack trace: ***\n" mov [rbp+var_18], rax mov rax, cs:stderr_ptr mov rdi, [rax] call _fileno mov dword ptr [rbp+var_3C], eax mov rax, [rbp+var_18] mov [rbp+var_3C+4], rax mov rdi, [rbp+var_18] call _strlen mov edi, dword ptr [rbp+var_3C]; this mov rsi, [rbp+var_3C+4] mov rdx, rax call _write cmp rax, 0 jge short loc_F714 jmp short $+2 loc_F714: call _ZN5nglog5tools26ProgramInvocationShortNameEv; nglog::tools::ProgramInvocationShortName(void) mov rsi, rax mov rdx, [rbp+var_18] mov edi, (offset dword_0+3); this call _ZN5nglog5tools14AlsoErrorWriteENS_11LogSeverityEPKcS3_; nglog::tools::AlsoErrorWrite(nglog::LogSeverity,char const*,char const*) call __ZSt19uncaught_exceptionsv; std::uncaught_exceptions(void) cmp eax, 0 jnz short loc_F739 call _ZN5nglog10LogMessage4FailEv; nglog::LogMessage::Fail(void) loc_F739: jmp short $+2 loc_F73B: add rsp, 40h pop rbp retn
void nglog::LogMessage::~LogMessage(nglog::LogMessage *this) { long long v1; // rax long long v2; // rax unsigned int v3; // [rsp+4h] [rbp-3Ch] void *v4; // [rsp+10h] [rbp-30h] char v5; // [rsp+27h] [rbp-19h] nglog::LogMessage::Flush(this); v5 = 0; if ( *(_DWORD *)(*((_QWORD *)this + 1) + 30360LL) == 3 ) v5 = nglog::exit_on_dfatal; v4 = *(void **)this; if ( *(_QWORD *)this ) { nglog::internal::LogMessageData::~LogMessageData(v4); operator delete(v4, 0x76F0uLL); } if ( (v5 & 1) != 0 ) { v3 = fileno(stderr); v1 = strlen("*** Check failure stack trace: ***\n"); write(v3, "*** Check failure stack trace: ***\n", v1); v2 = nglog::tools::ProgramInvocationShortName((nglog::tools *)v3); nglog::tools::AlsoErrorWrite((char *)&dword_0 + 3, v2, "*** Check failure stack trace: ***\n"); if ( !(unsigned int)std::uncaught_exceptions() ) nglog::LogMessage::Fail((nglog::LogMessage *)((char *)&dword_0 + 3)); } }
~LogMessage: PUSH RBP MOV RBP,RSP SUB RSP,0x40 MOV qword ptr [RBP + -0x8],RDI MOV RDI,qword ptr [RBP + -0x8] MOV qword ptr [RBP + -0x28],RDI CALL 0x0010f750 MOV RAX,qword ptr [RBP + -0x28] MOV RCX,qword ptr [RAX + 0x8] XOR EAX,EAX CMP dword ptr [RCX + 0x7698],0x3 MOV byte ptr [RBP + -0x19],AL JNZ 0x0010f698 MOV AL,byte ptr [0x0017076c] MOV byte ptr [RBP + -0x19],AL LAB_0010f698: MOV RAX,qword ptr [RBP + -0x28] MOV CL,byte ptr [RBP + -0x19] AND CL,0x1 MOV byte ptr [RBP + -0x9],CL MOV RAX,qword ptr [RAX] MOV qword ptr [RBP + -0x30],RAX CMP RAX,0x0 JZ 0x0010f6c9 MOV RDI,qword ptr [RBP + -0x30] CALL 0x00117bc0 MOV RDI,qword ptr [RBP + -0x30] MOV ESI,0x76f0 CALL 0x00109730 LAB_0010f6c9: TEST byte ptr [RBP + -0x9],0x1 JZ 0x0010f73b LEA RAX,[0x14d736] MOV qword ptr [RBP + -0x18],RAX MOV RAX,qword ptr [0x0016ffb0] MOV RDI,qword ptr [RAX] CALL 0x00109790 MOV dword ptr [RBP + -0x3c],EAX MOV RAX,qword ptr [RBP + -0x18] MOV qword ptr [RBP + -0x38],RAX MOV RDI,qword ptr [RBP + -0x18] CALL 0x001092e0 MOV EDI,dword ptr [RBP + -0x3c] MOV RSI,qword ptr [RBP + -0x38] MOV RDX,RAX CALL 0x00109220 CMP RAX,0x0 JGE 0x0010f714 JMP 0x0010f714 LAB_0010f714: CALL 0x0014b280 MOV RSI,RAX MOV RDX,qword ptr [RBP + -0x18] MOV EDI,0x3 CALL 0x0014b210 CALL 0x001098d0 CMP EAX,0x0 JNZ 0x0010f739 CALL 0x0010f980 LAB_0010f739: JMP 0x0010f73b LAB_0010f73b: ADD RSP,0x40 POP RBP RET
/* nglog::LogMessage::~LogMessage() */ void __thiscall nglog::LogMessage::~LogMessage(LogMessage *this) { LogMessageData *this_00; int iVar1; size_t __n; int8 uVar2; byte local_21; Flush(this); local_21 = 0; if (*(int *)(*(long *)(this + 8) + 0x7698) == 3) { local_21 = exit_on_dfatal; } this_00 = *(LogMessageData **)this; if (this_00 != (LogMessageData *)0x0) { internal::LogMessageData::~LogMessageData(this_00); operator_delete(this_00,0x76f0); } if ((local_21 & 1) != 0) { iVar1 = fileno(*(FILE **)PTR_stderr_0016ffb0); __n = strlen("*** Check failure stack trace: ***\n"); write(iVar1,"*** Check failure stack trace: ***\n",__n); uVar2 = tools::ProgramInvocationShortName(); tools::AlsoErrorWrite(3,uVar2,"*** Check failure stack trace: ***\n"); iVar1 = std::uncaught_exceptions(); if (iVar1 == 0) { Fail(); } } return; }
27,565
nglog::LogMessage::~LogMessage()
ng-log[P]ng-log/src/logging.cc
LogMessage::~LogMessage() noexcept(false) { Flush(); bool fail = data_->severity_ == NGLOG_FATAL && exit_on_dfatal; #ifdef NGLOG_THREAD_LOCAL_STORAGE if (data_ == static_cast<void*>(&thread_msg_data)) { data_->~LogMessageData(); thread_data_available = true; } else { delete allocated_; } #else // !defined(NGLOG_THREAD_LOCAL_STORAGE) delete allocated_; #endif // defined(NGLOG_THREAD_LOCAL_STORAGE) // if (fail) { const char* message = "*** Check failure stack trace: ***\n"; if (write(fileno(stderr), message, strlen(message)) < 0) { // Ignore errors. } AlsoErrorWrite(NGLOG_FATAL, tools::ProgramInvocationShortName(), message); #if defined(__cpp_lib_uncaught_exceptions) && \ (__cpp_lib_uncaught_exceptions >= 201411L) if (std::uncaught_exceptions() == 0) #else if (!std::uncaught_exception()) #endif { Fail(); } } }
O2
cpp
nglog::LogMessage::~LogMessage(): pushq %rbp pushq %r14 pushq %rbx movq %rdi, %r14 callq 0x9ffc movq (%r14), %rbx movq 0x8(%r14), %rax cmpl $0x3, 0x7698(%rax) sete %bpl andb 0x2462d(%rip), %bpl # 0x2e5bc testq %rbx, %rbx je 0x9fa0 leaq 0x7538(%rbx), %rdi callq 0x8e6c movl $0x76f0, %esi # imm = 0x76F0 movq %rbx, %rdi callq 0x75c0 testb %bpl, %bpl je 0x9ff1 movq 0x23fd7(%rip), %rax # 0x2df90 movq (%rax), %rdi callq 0x7610 leaq 0x146ae(%rip), %rbx # 0x1e676 pushq $0x23 popq %rdx movl %eax, %edi movq %rbx, %rsi callq 0x71a0 callq 0x1c915 pushq $0x3 popq %rdi movq %rax, %rsi movq %rbx, %rdx callq 0x1c8f8 callq 0x76e0 testl %eax, %eax je 0x9ff6 popq %rbx popq %r14 popq %rbp retq callq *0x245c4(%rip) # 0x2e5c0
_ZN5nglog10LogMessageD2Ev: push rbp; Alternative name is 'nglog::LogMessage::~LogMessage()' push r14 push rbx mov r14, rdi call _ZN5nglog10LogMessage5FlushEv; nglog::LogMessage::Flush(void) mov rbx, [r14] mov rax, [r14+8] cmp dword ptr [rax+7698h], 3 setz bpl and bpl, cs:_ZN5nglogL14exit_on_dfatalE; nglog::exit_on_dfatal test rbx, rbx jz short loc_9FA0 lea rdi, [rbx+7538h]; this call _ZN5nglog10LogMessage9LogStreamD1Ev; nglog::LogMessage::LogStream::~LogStream() loc_9FA0: mov esi, 76F0h; unsigned __int64 mov rdi, rbx; void * call __ZdlPvm; operator delete(void *,ulong) test bpl, bpl jz short loc_9FF1 mov rax, cs:stderr_ptr mov rdi, [rax] call _fileno lea rbx, aCheckFailureSt; "*** Check failure stack trace: ***\n" push 23h ; '#' pop rdx mov edi, eax; this mov rsi, rbx call _write call _ZN5nglog5tools26ProgramInvocationShortNameEv; nglog::tools::ProgramInvocationShortName(void) push 3 pop rdi mov rsi, rax mov rdx, rbx call _ZN5nglog5tools14AlsoErrorWriteENS_11LogSeverityEPKcS3_; nglog::tools::AlsoErrorWrite(nglog::LogSeverity,char const*,char const*) call __ZSt19uncaught_exceptionsv; std::uncaught_exceptions(void) test eax, eax jz short loc_9FF6 loc_9FF1: pop rbx pop r14 pop rbp retn loc_9FF6: call cs:_ZN5nglog19g_logging_fail_funcE; nglog::g_logging_fail_func ...
void nglog::LogMessage::~LogMessage(nglog::LogMessage *this) { long long v1; // rbx char v2; // bp nglog::tools *v3; // rdi long long v4; // rax nglog::LogMessage::Flush(this); v1 = *(_QWORD *)this; v2 = nglog::exit_on_dfatal & (*(_DWORD *)(*((_QWORD *)this + 1) + 30360LL) == 3); if ( *(_QWORD *)this ) nglog::LogMessage::LogStream::~LogStream((nglog::LogMessage::LogStream *)(v1 + 30008)); operator delete((void *)v1, 0x76F0uLL); if ( v2 ) { v3 = (nglog::tools *)(unsigned int)fileno(stderr); write(v3, "*** Check failure stack trace: ***\n", 35LL); v4 = nglog::tools::ProgramInvocationShortName(v3); nglog::tools::AlsoErrorWrite(3LL, v4, "*** Check failure stack trace: ***\n"); if ( !(unsigned int)std::uncaught_exceptions() ) nglog::g_logging_fail_func(); } }
~LogMessage: PUSH RBP PUSH R14 PUSH RBX MOV R14,RDI CALL 0x00109ffc MOV RBX,qword ptr [R14] MOV RAX,qword ptr [R14 + 0x8] CMP dword ptr [RAX + 0x7698],0x3 SETZ BPL AND BPL,byte ptr [0x0012e5bc] TEST RBX,RBX JZ 0x00109fa0 LEA RDI,[RBX + 0x7538] CALL 0x00108e6c LAB_00109fa0: MOV ESI,0x76f0 MOV RDI,RBX CALL 0x001075c0 TEST BPL,BPL JZ 0x00109ff1 MOV RAX,qword ptr [0x0012df90] MOV RDI,qword ptr [RAX] CALL 0x00107610 LEA RBX,[0x11e676] PUSH 0x23 POP RDX MOV EDI,EAX MOV RSI,RBX CALL 0x001071a0 CALL 0x0011c915 PUSH 0x3 POP RDI MOV RSI,RAX MOV RDX,RBX CALL 0x0011c8f8 CALL 0x001076e0 TEST EAX,EAX JZ 0x00109ff6 LAB_00109ff1: POP RBX POP R14 POP RBP RET LAB_00109ff6: CALL qword ptr [0x0012e5c0]
/* nglog::LogMessage::~LogMessage() */ void __thiscall nglog::LogMessage::~LogMessage(LogMessage *this) { void *pvVar1; int iVar2; int8 uVar3; byte bVar4; Flush(this); pvVar1 = *(void **)this; bVar4 = *(int *)(*(long *)(this + 8) + 0x7698) == 3 & exit_on_dfatal; if (pvVar1 != (void *)0x0) { LogStream::~LogStream((LogStream *)((long)pvVar1 + 0x7538)); } operator_delete(pvVar1,0x76f0); if (bVar4 != 0) { iVar2 = fileno(*(FILE **)PTR_stderr_0012df90); write(iVar2,"*** Check failure stack trace: ***\n",0x23); uVar3 = tools::ProgramInvocationShortName(); tools::AlsoErrorWrite(3,uVar3,"*** Check failure stack trace: ***\n"); iVar2 = std::uncaught_exceptions(); if (iVar2 == 0) { (*(code *)g_logging_fail_func)(); return; } } return; }
27,566
CustomAllocTest_PerformanceTest_Test::CustomAllocTest_PerformanceTest_Test()
seiftnesse[P]memoryallocator/tests/test_allocator.cpp
TEST_F(CustomAllocTest, PerformanceTest) { constexpr int PERF_ITERATIONS = 100000; std::vector<size_t> test_sizes = {16, 64, 256, 1024, 4096}; for (size_t size: test_sizes) { std::cout << "Testing allocation/free performance for size " << size << std::endl; // Test custom allocator auto start = std::chrono::high_resolution_clock::now(); for (int i = 0; i < PERF_ITERATIONS; i++) { void *ptr = _malloc(size); ASSERT_NE(ptr, nullptr); _free(ptr); } auto end = std::chrono::high_resolution_clock::now(); std::chrono::duration<double, std::milli> custom_time = end - start; // Test standard allocator start = std::chrono::high_resolution_clock::now(); for (int i = 0; i < PERF_ITERATIONS; i++) { void *ptr = std::malloc(size); ASSERT_NE(ptr, nullptr); std::free(ptr); } end = std::chrono::high_resolution_clock::now(); std::chrono::duration<double, std::milli> standard_time = end - start; std::cout << " Custom allocator: " << custom_time.count() << " ms" << std::endl; std::cout << " Standard allocator: " << standard_time.count() << " ms" << std::endl; std::cout << " Ratio (custom/standard): " << (custom_time.count() / standard_time.count()) << std::endl; } }
O0
cpp
CustomAllocTest_PerformanceTest_Test::CustomAllocTest_PerformanceTest_Test(): pushq %rbp movq %rsp, %rbp subq $0x10, %rsp movq %rdi, -0x8(%rbp) movq -0x8(%rbp), %rdi movq %rdi, -0x10(%rbp) callq 0x163d0 movq -0x10(%rbp), %rax leaq 0x8a984(%rip), %rcx # 0xa2468 addq $0x10, %rcx movq %rcx, (%rax) addq $0x10, %rsp popq %rbp retq nopw %cs:(%rax,%rax) nopl (%rax,%rax)
_ZN36CustomAllocTest_PerformanceTest_TestC2Ev: push rbp mov rbp, rsp sub rsp, 10h mov [rbp+var_8], rdi mov rdi, [rbp+var_8]; this mov [rbp+var_10], rdi call _ZN15CustomAllocTestC2Ev; CustomAllocTest::CustomAllocTest(void) mov rax, [rbp+var_10] lea rcx, _ZTV36CustomAllocTest_PerformanceTest_Test; `vtable for'CustomAllocTest_PerformanceTest_Test add rcx, 10h mov [rax], rcx add rsp, 10h pop rbp retn
void CustomAllocTest_PerformanceTest_Test::CustomAllocTest_PerformanceTest_Test( CustomAllocTest_PerformanceTest_Test *this) { CustomAllocTest::CustomAllocTest(this); *(_QWORD *)this = &`vtable for'CustomAllocTest_PerformanceTest_Test + 2; }
CustomAllocTest_PerformanceTest_Test: PUSH RBP MOV RBP,RSP SUB RSP,0x10 MOV qword ptr [RBP + -0x8],RDI MOV RDI,qword ptr [RBP + -0x8] MOV qword ptr [RBP + -0x10],RDI CALL 0x001163d0 MOV RAX,qword ptr [RBP + -0x10] LEA RCX,[0x1a2468] ADD RCX,0x10 MOV qword ptr [RAX],RCX ADD RSP,0x10 POP RBP RET
/* CustomAllocTest_PerformanceTest_Test::CustomAllocTest_PerformanceTest_Test() */ void __thiscall CustomAllocTest_PerformanceTest_Test::CustomAllocTest_PerformanceTest_Test (CustomAllocTest_PerformanceTest_Test *this) { CustomAllocTest::CustomAllocTest((CustomAllocTest *)this); *(int ***)this = &PTR__CustomAllocTest_PerformanceTest_Test_001a2478; return; }
27,567
CustomAllocTest_PerformanceTest_Test::CustomAllocTest_PerformanceTest_Test()
seiftnesse[P]memoryallocator/tests/test_allocator.cpp
TEST_F(CustomAllocTest, PerformanceTest) { constexpr int PERF_ITERATIONS = 100000; std::vector<size_t> test_sizes = {16, 64, 256, 1024, 4096}; for (size_t size: test_sizes) { std::cout << "Testing allocation/free performance for size " << size << std::endl; // Test custom allocator auto start = std::chrono::high_resolution_clock::now(); for (int i = 0; i < PERF_ITERATIONS; i++) { void *ptr = _malloc(size); ASSERT_NE(ptr, nullptr); _free(ptr); } auto end = std::chrono::high_resolution_clock::now(); std::chrono::duration<double, std::milli> custom_time = end - start; // Test standard allocator start = std::chrono::high_resolution_clock::now(); for (int i = 0; i < PERF_ITERATIONS; i++) { void *ptr = std::malloc(size); ASSERT_NE(ptr, nullptr); std::free(ptr); } end = std::chrono::high_resolution_clock::now(); std::chrono::duration<double, std::milli> standard_time = end - start; std::cout << " Custom allocator: " << custom_time.count() << " ms" << std::endl; std::cout << " Standard allocator: " << standard_time.count() << " ms" << std::endl; std::cout << " Ratio (custom/standard): " << (custom_time.count() / standard_time.count()) << std::endl; } }
O1
cpp
CustomAllocTest_PerformanceTest_Test::CustomAllocTest_PerformanceTest_Test(): pushq %rbx movq %rdi, %rbx callq 0x242c6 movl $0x10, %esi movq %rbx, %rdi popq %rbx jmp 0x94c0 nop
_ZN36CustomAllocTest_PerformanceTest_TestD0Ev: push rbx mov rbx, rdi call _ZN7testing4TestD2Ev; testing::Test::~Test() mov esi, 10h; unsigned __int64 mov rdi, rbx; void * pop rbx jmp __ZdlPvm; operator delete(void *,ulong)
void CustomAllocTest_PerformanceTest_Test::~CustomAllocTest_PerformanceTest_Test( CustomAllocTest_PerformanceTest_Test *this) { testing::Test::~Test(this); operator delete(this, 0x10uLL); }
~CustomAllocTest_PerformanceTest_Test: PUSH RBX MOV RBX,RDI CALL 0x001242c6 MOV ESI,0x10 MOV RDI,RBX POP RBX JMP 0x001094c0
/* CustomAllocTest_PerformanceTest_Test::~CustomAllocTest_PerformanceTest_Test() */ void __thiscall CustomAllocTest_PerformanceTest_Test::~CustomAllocTest_PerformanceTest_Test (CustomAllocTest_PerformanceTest_Test *this) { testing::Test::~Test((Test *)this); operator_delete(this,0x10); return; }
27,568
CustomAllocTest_PerformanceTest_Test::CustomAllocTest_PerformanceTest_Test()
seiftnesse[P]memoryallocator/tests/test_allocator.cpp
TEST_F(CustomAllocTest, PerformanceTest) { constexpr int PERF_ITERATIONS = 100000; std::vector<size_t> test_sizes = {16, 64, 256, 1024, 4096}; for (size_t size: test_sizes) { std::cout << "Testing allocation/free performance for size " << size << std::endl; // Test custom allocator auto start = std::chrono::high_resolution_clock::now(); for (int i = 0; i < PERF_ITERATIONS; i++) { void *ptr = _malloc(size); ASSERT_NE(ptr, nullptr); _free(ptr); } auto end = std::chrono::high_resolution_clock::now(); std::chrono::duration<double, std::milli> custom_time = end - start; // Test standard allocator start = std::chrono::high_resolution_clock::now(); for (int i = 0; i < PERF_ITERATIONS; i++) { void *ptr = std::malloc(size); ASSERT_NE(ptr, nullptr); std::free(ptr); } end = std::chrono::high_resolution_clock::now(); std::chrono::duration<double, std::milli> standard_time = end - start; std::cout << " Custom allocator: " << custom_time.count() << " ms" << std::endl; std::cout << " Standard allocator: " << standard_time.count() << " ms" << std::endl; std::cout << " Ratio (custom/standard): " << (custom_time.count() / standard_time.count()) << std::endl; } }
O2
cpp
CustomAllocTest_PerformanceTest_Test::CustomAllocTest_PerformanceTest_Test(): pushq %rbx movq %rdi, %rbx callq 0x1aef2 pushq $0x10 popq %rsi movq %rbx, %rdi popq %rbx jmp 0x9500 nop
_ZN36CustomAllocTest_PerformanceTest_TestD0Ev: push rbx mov rbx, rdi call _ZN7testing4TestD2Ev; testing::Test::~Test() push 10h pop rsi; unsigned __int64 mov rdi, rbx; void * pop rbx jmp __ZdlPvm; operator delete(void *,ulong)
void CustomAllocTest_PerformanceTest_Test::~CustomAllocTest_PerformanceTest_Test( CustomAllocTest_PerformanceTest_Test *this) { testing::Test::~Test(this); operator delete(this, 0x10uLL); }
~CustomAllocTest_PerformanceTest_Test: PUSH RBX MOV RBX,RDI CALL 0x0011aef2 PUSH 0x10 POP RSI MOV RDI,RBX POP RBX JMP 0x00109500
/* CustomAllocTest_PerformanceTest_Test::~CustomAllocTest_PerformanceTest_Test() */ void __thiscall CustomAllocTest_PerformanceTest_Test::~CustomAllocTest_PerformanceTest_Test (CustomAllocTest_PerformanceTest_Test *this) { testing::Test::~Test((Test *)this); operator_delete(this,0x10); return; }
27,569
cs_enter
eloqsql/strings/ctype.c
static int cs_enter(MY_XML_PARSER *st,const char *attr, size_t len) { struct my_cs_file_info *i= (struct my_cs_file_info *)st->user_data; const struct my_cs_file_section_st *s= cs_file_sec(attr,len); int state= s ? s->state : 0; switch (state) { case 0: i->loader->reporter(WARNING_LEVEL, "Unknown LDML tag: '%.*s'", len, attr); break; case _CS_CHARSET: my_charset_file_reset_charset(i); break; case _CS_COLLATION: my_charset_file_reset_collation(i); break; case _CS_RESET: return tailoring_append(st, " &", 0, NULL); default: break; } return MY_XML_OK; }
O3
c
cs_enter: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx pushq %rax movq %rdx, %r15 movq %rsi, %r14 movq 0x140(%rdi), %rbx leaq 0x2a2725(%rip), %r13 # 0x3164f0 leaq 0x8a65(%rip), %r12 # 0x7c837 movq %r14, %rdi movq %r12, %rsi movq %r15, %rdx callq 0x26170 testl %eax, %eax jne 0x73deb cmpb $0x0, (%r12,%r15) je 0x73e2b movq 0x18(%r13), %r12 addq $0x10, %r13 testq %r12, %r12 jne 0x73dd2 movq 0x7a8(%rbx), %r8 leaq 0xb29c(%rip), %rsi # 0x7f0a2 movl $0x1, %edi movq %r15, %rdx movq %r14, %rcx xorl %eax, %eax callq *0xa0(%r8) xorl %eax, %eax addq $0x8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq movl (%r13), %eax cmpl $0x8, %eax jg 0x73e55 testl %eax, %eax je 0x73df8 cmpl $0x8, %eax jne 0x73e1a addq $0x6e0, %rbx # imm = 0x6E0 movl $0xc8, %edx movq %rbx, %rdi xorl %esi, %esi callq 0x261c0 jmp 0x73e1a cmpl $0x9, %eax je 0x73e82 cmpl $0x12d, %eax # imm = 0x12D jne 0x73e1a leaq 0xb253(%rip), %rsi # 0x7f0bb movq %rbx, %rdi xorl %edx, %edx xorl %ecx, %ecx addq $0x8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp jmp 0x75024 movq $0x0, 0x690(%rbx) movb $0x0, 0x6a0(%rbx) jmp 0x73e1a
cs_enter: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx push rax mov r15, rdx mov r14, rsi mov rbx, [rdi+140h] lea r13, sec lea r12, aIndexXml+6; "xml" loc_73DD2: mov rdi, r14 mov rsi, r12 mov rdx, r15 call _strncmp test eax, eax jnz short loc_73DEB cmp byte ptr [r12+r15], 0 jz short loc_73E2B loc_73DEB: mov r12, [r13+18h] add r13, 10h test r12, r12 jnz short loc_73DD2 loc_73DF8: mov r8, [rbx+7A8h] lea rsi, aUnknownLdmlTag; "Unknown LDML tag: '%.*s'" mov edi, 1 mov rdx, r15 mov rcx, r14 xor eax, eax call qword ptr [r8+0A0h] loc_73E1A: xor eax, eax add rsp, 8 pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn loc_73E2B: mov eax, [r13+0] cmp eax, 8 jg short loc_73E55 test eax, eax jz short loc_73DF8 cmp eax, 8 jnz short loc_73E1A add rbx, 6E0h mov edx, 0C8h mov rdi, rbx xor esi, esi call _memset jmp short loc_73E1A loc_73E55: cmp eax, 9 jz short loc_73E82 cmp eax, 12Dh jnz short loc_73E1A lea rsi, asc_7F0BB; " &" mov rdi, rbx xor edx, edx xor ecx, ecx add rsp, 8 pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp jmp tailoring_append loc_73E82: mov qword ptr [rbx+690h], 0 mov byte ptr [rbx+6A0h], 0 jmp short loc_73E1A
long long cs_enter(long long a1, const char *a2, long long a3) { long long v4; // rbx char *v5; // r13 char *v6; // r12 int v8; // eax v4 = *(_QWORD *)(a1 + 320); v5 = (char *)&sec; v6 = "xml"; while ( (unsigned int)strncmp(a2, v6, a3) || v6[a3] ) { v6 = (char *)*((_QWORD *)v5 + 3); v5 += 16; if ( !v6 ) goto LABEL_5; } v8 = *(_DWORD *)v5; if ( *(int *)v5 <= 8 ) { if ( v8 ) { if ( v8 == 8 ) memset(v4 + 1760, 0LL, 200LL); } else { LABEL_5: (*(void (**)(long long, const char *, ...))(*(_QWORD *)(v4 + 1960) + 160LL))( 1LL, "Unknown LDML tag: '%.*s'", a3, a2); } return 0LL; } if ( v8 == 9 ) { *(_QWORD *)(v4 + 1680) = 0LL; *(_BYTE *)(v4 + 1696) = 0; return 0LL; } if ( v8 != 301 ) return 0LL; return tailoring_append(v4, " &", 0LL, 0LL); }
cs_enter: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX PUSH RAX MOV R15,RDX MOV R14,RSI MOV RBX,qword ptr [RDI + 0x140] LEA R13,[0x4164f0] LEA R12,[0x17c837] LAB_00173dd2: MOV RDI,R14 MOV RSI,R12 MOV RDX,R15 CALL 0x00126170 TEST EAX,EAX JNZ 0x00173deb CMP byte ptr [R12 + R15*0x1],0x0 JZ 0x00173e2b LAB_00173deb: MOV R12,qword ptr [R13 + 0x18] ADD R13,0x10 TEST R12,R12 JNZ 0x00173dd2 LAB_00173df8: MOV R8,qword ptr [RBX + 0x7a8] LEA RSI,[0x17f0a2] MOV EDI,0x1 MOV RDX,R15 MOV RCX,R14 XOR EAX,EAX CALL qword ptr [R8 + 0xa0] LAB_00173e1a: XOR EAX,EAX ADD RSP,0x8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET LAB_00173e2b: MOV EAX,dword ptr [R13] CMP EAX,0x8 JG 0x00173e55 TEST EAX,EAX JZ 0x00173df8 CMP EAX,0x8 JNZ 0x00173e1a ADD RBX,0x6e0 MOV EDX,0xc8 MOV RDI,RBX XOR ESI,ESI CALL 0x001261c0 JMP 0x00173e1a LAB_00173e55: CMP EAX,0x9 JZ 0x00173e82 CMP EAX,0x12d JNZ 0x00173e1a LEA RSI,[0x17f0bb] MOV RDI,RBX XOR EDX,EDX XOR ECX,ECX ADD RSP,0x8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP JMP 0x00175024 LAB_00173e82: MOV qword ptr [RBX + 0x690],0x0 MOV byte ptr [RBX + 0x6a0],0x0 JMP 0x00173e1a
int8 cs_enter(long param_1,char *param_2,size_t param_3) { long lVar1; int iVar2; int8 uVar3; char *__s2; int *piVar4; lVar1 = *(long *)(param_1 + 0x140); piVar4 = &sec; __s2 = "xml"; while ((iVar2 = strncmp(param_2,__s2,param_3), iVar2 != 0 || (__s2[param_3] != '\0'))) { __s2 = *(char **)(piVar4 + 6); piVar4 = piVar4 + 4; if (__s2 == (char *)0x0) { LAB_00173df8: (**(code **)(*(long *)(lVar1 + 0x7a8) + 0xa0))(1,"Unknown LDML tag: \'%.*s\'",param_3,param_2) ; return 0; } } iVar2 = *piVar4; if (8 < iVar2) { if (iVar2 == 9) { *(int8 *)(lVar1 + 0x690) = 0; *(int1 *)(lVar1 + 0x6a0) = 0; return 0; } if (iVar2 != 0x12d) { return 0; } uVar3 = tailoring_append(lVar1,&DAT_0017f0bb,0,0); return uVar3; } if (iVar2 != 0) { if (iVar2 != 8) { return 0; } memset((void *)(lVar1 + 0x6e0),0,200); return 0; } goto LAB_00173df8; }
27,570
rb_insert
eloqsql/mysys/tree.c
static void rb_insert(TREE *tree, TREE_ELEMENT ***parent, TREE_ELEMENT *leaf) { TREE_ELEMENT *y,*par,*par2; leaf->colour=RED; while (leaf != tree->root && (par=parent[-1][0])->colour == RED) { if (par == (par2=parent[-2][0])->left) { y= par2->right; if (y->colour == RED) { par->colour=BLACK; y->colour=BLACK; leaf=par2; parent-=2; leaf->colour=RED; /* And the loop continues */ } else { if (leaf == par->right) { left_rotate(parent[-1],par); par=leaf; /* leaf is now parent to old leaf */ } par->colour=BLACK; par2->colour=RED; right_rotate(parent[-2],par2); break; } } else { y= par2->left; if (y->colour == RED) { par->colour=BLACK; y->colour=BLACK; leaf=par2; parent-=2; leaf->colour=RED; /* And the loop continues */ } else { if (leaf == par->left) { right_rotate(parent[-1],par); par=leaf; } par->colour=BLACK; par2->colour=RED; left_rotate(parent[-2],par2); break; } } } tree->root->colour=BLACK; }
O0
c
rb_insert: pushq %rbp movq %rsp, %rbp subq $0x40, %rsp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq %rdx, -0x18(%rbp) movq -0x18(%rbp), %rax movl 0x10(%rax), %ecx andl $0x7fffffff, %ecx # imm = 0x7FFFFFFF orl $0x0, %ecx movl %ecx, 0x10(%rax) movq -0x18(%rbp), %rcx movq -0x8(%rbp), %rdx xorl %eax, %eax cmpq (%rdx), %rcx movb %al, -0x31(%rbp) je 0xfa527 movq -0x10(%rbp), %rax movq -0x8(%rax), %rax movq (%rax), %rax movq %rax, -0x28(%rbp) movl 0x10(%rax), %eax shrl $0x1f, %eax cmpl $0x0, %eax sete %al movb %al, -0x31(%rbp) movb -0x31(%rbp), %al testb $0x1, %al jne 0xfa533 jmp 0xfa702 movq -0x28(%rbp), %rax movq -0x10(%rbp), %rcx movq -0x10(%rcx), %rcx movq (%rcx), %rcx movq %rcx, -0x30(%rbp) cmpq (%rcx), %rax jne 0xfa62a movq -0x30(%rbp), %rax movq 0x8(%rax), %rax movq %rax, -0x20(%rbp) movq -0x20(%rbp), %rax movl 0x10(%rax), %eax shrl $0x1f, %eax cmpl $0x0, %eax jne 0xfa5bf movq -0x28(%rbp), %rax movl 0x10(%rax), %ecx andl $0x7fffffff, %ecx # imm = 0x7FFFFFFF orl $0x80000000, %ecx # imm = 0x80000000 movl %ecx, 0x10(%rax) movq -0x20(%rbp), %rax movl 0x10(%rax), %ecx andl $0x7fffffff, %ecx # imm = 0x7FFFFFFF orl $0x80000000, %ecx # imm = 0x80000000 movl %ecx, 0x10(%rax) movq -0x30(%rbp), %rax movq %rax, -0x18(%rbp) movq -0x10(%rbp), %rax addq $-0x10, %rax movq %rax, -0x10(%rbp) movq -0x18(%rbp), %rax movl 0x10(%rax), %ecx andl $0x7fffffff, %ecx # imm = 0x7FFFFFFF orl $0x0, %ecx movl %ecx, 0x10(%rax) jmp 0xfa625 movq -0x18(%rbp), %rax movq -0x28(%rbp), %rcx cmpq 0x8(%rcx), %rax jne 0xfa5e6 movq -0x10(%rbp), %rax movq -0x8(%rax), %rdi movq -0x28(%rbp), %rsi callq 0xfba70 movq -0x18(%rbp), %rax movq %rax, -0x28(%rbp) movq -0x28(%rbp), %rax movl 0x10(%rax), %ecx andl $0x7fffffff, %ecx # imm = 0x7FFFFFFF orl $0x80000000, %ecx # imm = 0x80000000 movl %ecx, 0x10(%rax) movq -0x30(%rbp), %rax movl 0x10(%rax), %ecx andl $0x7fffffff, %ecx # imm = 0x7FFFFFFF orl $0x0, %ecx movl %ecx, 0x10(%rax) movq -0x10(%rbp), %rax movq -0x10(%rax), %rdi movq -0x30(%rbp), %rsi callq 0xfbab0 jmp 0xfa702 jmp 0xfa6fd movq -0x30(%rbp), %rax movq (%rax), %rax movq %rax, -0x20(%rbp) movq -0x20(%rbp), %rax movl 0x10(%rax), %eax shrl $0x1f, %eax cmpl $0x0, %eax jne 0xfa699 movq -0x28(%rbp), %rax movl 0x10(%rax), %ecx andl $0x7fffffff, %ecx # imm = 0x7FFFFFFF orl $0x80000000, %ecx # imm = 0x80000000 movl %ecx, 0x10(%rax) movq -0x20(%rbp), %rax movl 0x10(%rax), %ecx andl $0x7fffffff, %ecx # imm = 0x7FFFFFFF orl $0x80000000, %ecx # imm = 0x80000000 movl %ecx, 0x10(%rax) movq -0x30(%rbp), %rax movq %rax, -0x18(%rbp) movq -0x10(%rbp), %rax addq $-0x10, %rax movq %rax, -0x10(%rbp) movq -0x18(%rbp), %rax movl 0x10(%rax), %ecx andl $0x7fffffff, %ecx # imm = 0x7FFFFFFF orl $0x0, %ecx movl %ecx, 0x10(%rax) jmp 0xfa6fb movq -0x18(%rbp), %rax movq -0x28(%rbp), %rcx cmpq (%rcx), %rax jne 0xfa6bf movq -0x10(%rbp), %rax movq -0x8(%rax), %rdi movq -0x28(%rbp), %rsi callq 0xfbab0 movq -0x18(%rbp), %rax movq %rax, -0x28(%rbp) movq -0x28(%rbp), %rax movl 0x10(%rax), %ecx andl $0x7fffffff, %ecx # imm = 0x7FFFFFFF orl $0x80000000, %ecx # imm = 0x80000000 movl %ecx, 0x10(%rax) movq -0x30(%rbp), %rax movl 0x10(%rax), %ecx andl $0x7fffffff, %ecx # imm = 0x7FFFFFFF orl $0x0, %ecx movl %ecx, 0x10(%rax) movq -0x10(%rbp), %rax movq -0x10(%rax), %rdi movq -0x30(%rbp), %rsi callq 0xfba70 jmp 0xfa702 jmp 0xfa6fd jmp 0xfa4f7 movq -0x8(%rbp), %rax movq (%rax), %rax movl 0x10(%rax), %ecx andl $0x7fffffff, %ecx # imm = 0x7FFFFFFF orl $0x80000000, %ecx # imm = 0x80000000 movl %ecx, 0x10(%rax) addq $0x40, %rsp popq %rbp retq nopw %cs:(%rax,%rax)
rb_insert: push rbp mov rbp, rsp sub rsp, 40h mov [rbp+var_8], rdi mov [rbp+var_10], rsi mov [rbp+var_18], rdx mov rax, [rbp+var_18] mov ecx, [rax+10h] and ecx, 7FFFFFFFh or ecx, 0 mov [rax+10h], ecx loc_FA4F7: mov rcx, [rbp+var_18] mov rdx, [rbp+var_8] xor eax, eax cmp rcx, [rdx] mov [rbp+var_31], al jz short loc_FA527 mov rax, [rbp+var_10] mov rax, [rax-8] mov rax, [rax] mov [rbp+var_28], rax mov eax, [rax+10h] shr eax, 1Fh cmp eax, 0 setz al mov [rbp+var_31], al loc_FA527: mov al, [rbp+var_31] test al, 1 jnz short loc_FA533 jmp loc_FA702 loc_FA533: mov rax, [rbp+var_28] mov rcx, [rbp+var_10] mov rcx, [rcx-10h] mov rcx, [rcx] mov [rbp+var_30], rcx cmp rax, [rcx] jnz loc_FA62A mov rax, [rbp+var_30] mov rax, [rax+8] mov [rbp+var_20], rax mov rax, [rbp+var_20] mov eax, [rax+10h] shr eax, 1Fh cmp eax, 0 jnz short loc_FA5BF mov rax, [rbp+var_28] mov ecx, [rax+10h] and ecx, 7FFFFFFFh or ecx, 80000000h mov [rax+10h], ecx mov rax, [rbp+var_20] mov ecx, [rax+10h] and ecx, 7FFFFFFFh or ecx, 80000000h mov [rax+10h], ecx mov rax, [rbp+var_30] mov [rbp+var_18], rax mov rax, [rbp+var_10] add rax, 0FFFFFFFFFFFFFFF0h mov [rbp+var_10], rax mov rax, [rbp+var_18] mov ecx, [rax+10h] and ecx, 7FFFFFFFh or ecx, 0 mov [rax+10h], ecx jmp short loc_FA625 loc_FA5BF: mov rax, [rbp+var_18] mov rcx, [rbp+var_28] cmp rax, [rcx+8] jnz short loc_FA5E6 mov rax, [rbp+var_10] mov rdi, [rax-8] mov rsi, [rbp+var_28] call left_rotate mov rax, [rbp+var_18] mov [rbp+var_28], rax loc_FA5E6: mov rax, [rbp+var_28] mov ecx, [rax+10h] and ecx, 7FFFFFFFh or ecx, 80000000h mov [rax+10h], ecx mov rax, [rbp+var_30] mov ecx, [rax+10h] and ecx, 7FFFFFFFh or ecx, 0 mov [rax+10h], ecx mov rax, [rbp+var_10] mov rdi, [rax-10h] mov rsi, [rbp+var_30] call right_rotate jmp loc_FA702 loc_FA625: jmp loc_FA6FD loc_FA62A: mov rax, [rbp+var_30] mov rax, [rax] mov [rbp+var_20], rax mov rax, [rbp+var_20] mov eax, [rax+10h] shr eax, 1Fh cmp eax, 0 jnz short loc_FA699 mov rax, [rbp+var_28] mov ecx, [rax+10h] and ecx, 7FFFFFFFh or ecx, 80000000h mov [rax+10h], ecx mov rax, [rbp+var_20] mov ecx, [rax+10h] and ecx, 7FFFFFFFh or ecx, 80000000h mov [rax+10h], ecx mov rax, [rbp+var_30] mov [rbp+var_18], rax mov rax, [rbp+var_10] add rax, 0FFFFFFFFFFFFFFF0h mov [rbp+var_10], rax mov rax, [rbp+var_18] mov ecx, [rax+10h] and ecx, 7FFFFFFFh or ecx, 0 mov [rax+10h], ecx jmp short loc_FA6FB loc_FA699: mov rax, [rbp+var_18] mov rcx, [rbp+var_28] cmp rax, [rcx] jnz short loc_FA6BF mov rax, [rbp+var_10] mov rdi, [rax-8] mov rsi, [rbp+var_28] call right_rotate mov rax, [rbp+var_18] mov [rbp+var_28], rax loc_FA6BF: mov rax, [rbp+var_28] mov ecx, [rax+10h] and ecx, 7FFFFFFFh or ecx, 80000000h mov [rax+10h], ecx mov rax, [rbp+var_30] mov ecx, [rax+10h] and ecx, 7FFFFFFFh or ecx, 0 mov [rax+10h], ecx mov rax, [rbp+var_10] mov rdi, [rax-10h] mov rsi, [rbp+var_30] call left_rotate jmp short loc_FA702 loc_FA6FB: jmp short $+2 loc_FA6FD: jmp loc_FA4F7 loc_FA702: mov rax, [rbp+var_8] mov rax, [rax] mov ecx, [rax+10h] and ecx, 7FFFFFFFh or ecx, 80000000h mov [rax+10h], ecx add rsp, 40h pop rbp retn
long long * rb_insert(long long **a1, long long a2, long long *a3) { long long *result; // rax bool v4; // [rsp+Fh] [rbp-31h] long long *v5; // [rsp+10h] [rbp-30h] long long *v6; // [rsp+18h] [rbp-28h] long long v7; // [rsp+20h] [rbp-20h] long long *v8; // [rsp+28h] [rbp-18h] v8 = a3; *((_DWORD *)a3 + 4) &= ~0x80000000; while ( 1 ) { v4 = 0; if ( v8 != *a1 ) { v6 = **(long long ***)(a2 - 8); v4 = *((_DWORD *)v6 + 4) >> 31 == 0; } if ( !v4 ) break; v5 = **(long long ***)(a2 - 16); if ( v6 == (long long *)*v5 ) { v7 = v5[1]; if ( *(int *)(v7 + 16) < 0 ) { if ( v8 == (long long *)v6[1] ) { left_rotate(*(_QWORD *)(a2 - 8), v6); v6 = v8; } *((_DWORD *)v6 + 4) = v6[2] & 0x7FFFFFFF | 0x80000000; *((_DWORD *)v5 + 4) &= ~0x80000000; right_rotate(*(_QWORD *)(a2 - 16), v5); break; } } else { v7 = *v5; if ( *(int *)(*v5 + 16) < 0 ) { if ( v8 == (long long *)*v6 ) { right_rotate(*(_QWORD *)(a2 - 8), v6); v6 = v8; } *((_DWORD *)v6 + 4) = v6[2] & 0x7FFFFFFF | 0x80000000; *((_DWORD *)v5 + 4) &= ~0x80000000; left_rotate(*(_QWORD *)(a2 - 16), v5); break; } } *((_DWORD *)v6 + 4) = v6[2] & 0x7FFFFFFF | 0x80000000; *(_DWORD *)(v7 + 16) = *(_DWORD *)(v7 + 16) & 0x7FFFFFFF | 0x80000000; v8 = v5; a2 -= 16LL; *((_DWORD *)v5 + 4) &= ~0x80000000; } result = *a1; *((_DWORD *)*a1 + 4) = (*a1)[2] & 0x7FFFFFFF | 0x80000000; return result; }
rb_insert: PUSH RBP MOV RBP,RSP SUB RSP,0x40 MOV qword ptr [RBP + -0x8],RDI MOV qword ptr [RBP + -0x10],RSI MOV qword ptr [RBP + -0x18],RDX MOV RAX,qword ptr [RBP + -0x18] MOV ECX,dword ptr [RAX + 0x10] AND ECX,0x7fffffff OR ECX,0x0 MOV dword ptr [RAX + 0x10],ECX LAB_001fa4f7: MOV RCX,qword ptr [RBP + -0x18] MOV RDX,qword ptr [RBP + -0x8] XOR EAX,EAX CMP RCX,qword ptr [RDX] MOV byte ptr [RBP + -0x31],AL JZ 0x001fa527 MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + -0x8] MOV RAX,qword ptr [RAX] MOV qword ptr [RBP + -0x28],RAX MOV EAX,dword ptr [RAX + 0x10] SHR EAX,0x1f CMP EAX,0x0 SETZ AL MOV byte ptr [RBP + -0x31],AL LAB_001fa527: MOV AL,byte ptr [RBP + -0x31] TEST AL,0x1 JNZ 0x001fa533 JMP 0x001fa702 LAB_001fa533: MOV RAX,qword ptr [RBP + -0x28] MOV RCX,qword ptr [RBP + -0x10] MOV RCX,qword ptr [RCX + -0x10] MOV RCX,qword ptr [RCX] MOV qword ptr [RBP + -0x30],RCX CMP RAX,qword ptr [RCX] JNZ 0x001fa62a MOV RAX,qword ptr [RBP + -0x30] MOV RAX,qword ptr [RAX + 0x8] MOV qword ptr [RBP + -0x20],RAX MOV RAX,qword ptr [RBP + -0x20] MOV EAX,dword ptr [RAX + 0x10] SHR EAX,0x1f CMP EAX,0x0 JNZ 0x001fa5bf MOV RAX,qword ptr [RBP + -0x28] MOV ECX,dword ptr [RAX + 0x10] AND ECX,0x7fffffff OR ECX,0x80000000 MOV dword ptr [RAX + 0x10],ECX MOV RAX,qword ptr [RBP + -0x20] MOV ECX,dword ptr [RAX + 0x10] AND ECX,0x7fffffff OR ECX,0x80000000 MOV dword ptr [RAX + 0x10],ECX MOV RAX,qword ptr [RBP + -0x30] MOV qword ptr [RBP + -0x18],RAX MOV RAX,qword ptr [RBP + -0x10] ADD RAX,-0x10 MOV qword ptr [RBP + -0x10],RAX MOV RAX,qword ptr [RBP + -0x18] MOV ECX,dword ptr [RAX + 0x10] AND ECX,0x7fffffff OR ECX,0x0 MOV dword ptr [RAX + 0x10],ECX JMP 0x001fa625 LAB_001fa5bf: MOV RAX,qword ptr [RBP + -0x18] MOV RCX,qword ptr [RBP + -0x28] CMP RAX,qword ptr [RCX + 0x8] JNZ 0x001fa5e6 MOV RAX,qword ptr [RBP + -0x10] MOV RDI,qword ptr [RAX + -0x8] MOV RSI,qword ptr [RBP + -0x28] CALL 0x001fba70 MOV RAX,qword ptr [RBP + -0x18] MOV qword ptr [RBP + -0x28],RAX LAB_001fa5e6: MOV RAX,qword ptr [RBP + -0x28] MOV ECX,dword ptr [RAX + 0x10] AND ECX,0x7fffffff OR ECX,0x80000000 MOV dword ptr [RAX + 0x10],ECX MOV RAX,qword ptr [RBP + -0x30] MOV ECX,dword ptr [RAX + 0x10] AND ECX,0x7fffffff OR ECX,0x0 MOV dword ptr [RAX + 0x10],ECX MOV RAX,qword ptr [RBP + -0x10] MOV RDI,qword ptr [RAX + -0x10] MOV RSI,qword ptr [RBP + -0x30] CALL 0x001fbab0 JMP 0x001fa702 LAB_001fa625: JMP 0x001fa6fd LAB_001fa62a: MOV RAX,qword ptr [RBP + -0x30] MOV RAX,qword ptr [RAX] MOV qword ptr [RBP + -0x20],RAX MOV RAX,qword ptr [RBP + -0x20] MOV EAX,dword ptr [RAX + 0x10] SHR EAX,0x1f CMP EAX,0x0 JNZ 0x001fa699 MOV RAX,qword ptr [RBP + -0x28] MOV ECX,dword ptr [RAX + 0x10] AND ECX,0x7fffffff OR ECX,0x80000000 MOV dword ptr [RAX + 0x10],ECX MOV RAX,qword ptr [RBP + -0x20] MOV ECX,dword ptr [RAX + 0x10] AND ECX,0x7fffffff OR ECX,0x80000000 MOV dword ptr [RAX + 0x10],ECX MOV RAX,qword ptr [RBP + -0x30] MOV qword ptr [RBP + -0x18],RAX MOV RAX,qword ptr [RBP + -0x10] ADD RAX,-0x10 MOV qword ptr [RBP + -0x10],RAX MOV RAX,qword ptr [RBP + -0x18] MOV ECX,dword ptr [RAX + 0x10] AND ECX,0x7fffffff OR ECX,0x0 MOV dword ptr [RAX + 0x10],ECX JMP 0x001fa6fb LAB_001fa699: MOV RAX,qword ptr [RBP + -0x18] MOV RCX,qword ptr [RBP + -0x28] CMP RAX,qword ptr [RCX] JNZ 0x001fa6bf MOV RAX,qword ptr [RBP + -0x10] MOV RDI,qword ptr [RAX + -0x8] MOV RSI,qword ptr [RBP + -0x28] CALL 0x001fbab0 MOV RAX,qword ptr [RBP + -0x18] MOV qword ptr [RBP + -0x28],RAX LAB_001fa6bf: MOV RAX,qword ptr [RBP + -0x28] MOV ECX,dword ptr [RAX + 0x10] AND ECX,0x7fffffff OR ECX,0x80000000 MOV dword ptr [RAX + 0x10],ECX MOV RAX,qword ptr [RBP + -0x30] MOV ECX,dword ptr [RAX + 0x10] AND ECX,0x7fffffff OR ECX,0x0 MOV dword ptr [RAX + 0x10],ECX MOV RAX,qword ptr [RBP + -0x10] MOV RDI,qword ptr [RAX + -0x10] MOV RSI,qword ptr [RBP + -0x30] CALL 0x001fba70 JMP 0x001fa702 LAB_001fa6fb: JMP 0x001fa6fd LAB_001fa6fd: JMP 0x001fa4f7 LAB_001fa702: MOV RAX,qword ptr [RBP + -0x8] MOV RAX,qword ptr [RAX] MOV ECX,dword ptr [RAX + 0x10] AND ECX,0x7fffffff OR ECX,0x80000000 MOV dword ptr [RAX + 0x10],ECX ADD RSP,0x40 POP RBP RET
void rb_insert(long *param_1,long param_2,long *param_3) { long *plVar1; long lVar2; bool bVar3; long *local_30; long *local_20; long local_18; *(uint *)(param_3 + 2) = *(uint *)(param_3 + 2) & 0x7fffffff; local_20 = param_3; local_18 = param_2; do { bVar3 = false; if (local_20 != (long *)*param_1) { local_30 = (long *)**(long **)(local_18 + -8); bVar3 = -1 < (int)local_30[2]; } if (!bVar3) goto LAB_001fa702; plVar1 = (long *)**(long **)(local_18 + -0x10); if (local_30 == (long *)*plVar1) { lVar2 = plVar1[1]; if (*(int *)(lVar2 + 0x10) < 0) { if (local_20 == (long *)local_30[1]) { left_rotate(*(int8 *)(local_18 + -8),local_30); local_30 = local_20; } *(uint *)(local_30 + 2) = *(uint *)(local_30 + 2) & 0x7fffffff | 0x80000000; *(uint *)(plVar1 + 2) = *(uint *)(plVar1 + 2) & 0x7fffffff; right_rotate(*(int8 *)(local_18 + -0x10),plVar1); LAB_001fa702: *(uint *)(*param_1 + 0x10) = *(uint *)(*param_1 + 0x10) & 0x7fffffff | 0x80000000; return; } *(uint *)(local_30 + 2) = *(uint *)(local_30 + 2) & 0x7fffffff | 0x80000000; *(uint *)(lVar2 + 0x10) = *(uint *)(lVar2 + 0x10) & 0x7fffffff | 0x80000000; *(uint *)(plVar1 + 2) = *(uint *)(plVar1 + 2) & 0x7fffffff; } else { lVar2 = *plVar1; if (*(int *)(lVar2 + 0x10) < 0) { if (local_20 == (long *)*local_30) { right_rotate(*(int8 *)(local_18 + -8),local_30); local_30 = local_20; } *(uint *)(local_30 + 2) = *(uint *)(local_30 + 2) & 0x7fffffff | 0x80000000; *(uint *)(plVar1 + 2) = *(uint *)(plVar1 + 2) & 0x7fffffff; left_rotate(*(int8 *)(local_18 + -0x10),plVar1); goto LAB_001fa702; } *(uint *)(local_30 + 2) = *(uint *)(local_30 + 2) & 0x7fffffff | 0x80000000; *(uint *)(lVar2 + 0x10) = *(uint *)(lVar2 + 0x10) & 0x7fffffff | 0x80000000; *(uint *)(plVar1 + 2) = *(uint *)(plVar1 + 2) & 0x7fffffff; } local_18 = local_18 + -0x10; local_20 = plVar1; } while( true ); }
27,571
ma_reset_state
eloqsql/storage/maria/ma_state.c
void _ma_reset_state(MARIA_HA *info) { MARIA_SHARE *share= info->s; MARIA_STATE_HISTORY *history= share->state_history; DBUG_ENTER("_ma_reset_state"); /* Always true if share->now_transactional is set */ if (history && share->have_versioning) { MARIA_STATE_HISTORY *next; DBUG_PRINT("info", ("resetting history")); /* Set the current history to current state */ share->state_history->state= share->state.state; /* Set current table handler to point to new history state */ info->state= info->state_start= &share->state_history->state; for (history= history->next ; history ; history= next) { next= history->next; my_free(history); } share->state_history->next= 0; share->state_history->trid= 0; /* Visible for all */ } DBUG_VOID_RETURN; }
O0
c
ma_reset_state: pushq %rbp movq %rsp, %rbp subq $0x20, %rsp movq %rdi, -0x8(%rbp) movq -0x8(%rbp), %rax movq (%rax), %rax movq %rax, -0x10(%rbp) movq -0x10(%rbp), %rax movq 0x450(%rax), %rax movq %rax, -0x18(%rbp) cmpq $0x0, -0x18(%rbp) je 0x3681e movq -0x10(%rbp), %rax movsbl 0x7e8(%rax), %eax cmpl $0x0, %eax je 0x3681e jmp 0x36787 jmp 0x36789 movq -0x10(%rbp), %rax movq 0x450(%rax), %rdi addq $0x10, %rdi movq -0x10(%rbp), %rsi addq $0x18, %rsi movl $0x38, %edx callq 0x2a090 movq -0x10(%rbp), %rax movq 0x450(%rax), %rcx addq $0x10, %rcx movq -0x8(%rbp), %rax movq %rcx, 0x60(%rax) movq -0x8(%rbp), %rax movq %rcx, 0x20(%rax) movq -0x18(%rbp), %rax movq (%rax), %rax movq %rax, -0x18(%rbp) cmpq $0x0, -0x18(%rbp) je 0x367f9 movq -0x18(%rbp), %rax movq (%rax), %rax movq %rax, -0x20(%rbp) movq -0x18(%rbp), %rdi callq 0xf3bb0 movq -0x20(%rbp), %rax movq %rax, -0x18(%rbp) jmp 0x367d4 movq -0x10(%rbp), %rax movq 0x450(%rax), %rax movq $0x0, (%rax) movq -0x10(%rbp), %rax movq 0x450(%rax), %rax movq $0x0, 0x8(%rax) jmp 0x36820 jmp 0x36822 addq $0x20, %rsp popq %rbp retq nopl (%rax,%rax)
_ma_reset_state: push rbp mov rbp, rsp sub rsp, 20h mov [rbp+var_8], rdi mov rax, [rbp+var_8] mov rax, [rax] mov [rbp+var_10], rax mov rax, [rbp+var_10] mov rax, [rax+450h] mov [rbp+var_18], rax cmp [rbp+var_18], 0 jz loc_3681E mov rax, [rbp+var_10] movsx eax, byte ptr [rax+7E8h] cmp eax, 0 jz loc_3681E jmp short $+2 loc_36787: jmp short $+2 loc_36789: mov rax, [rbp+var_10] mov rdi, [rax+450h] add rdi, 10h mov rsi, [rbp+var_10] add rsi, 18h mov edx, 38h ; '8' call _memcpy mov rax, [rbp+var_10] mov rcx, [rax+450h] add rcx, 10h mov rax, [rbp+var_8] mov [rax+60h], rcx mov rax, [rbp+var_8] mov [rax+20h], rcx mov rax, [rbp+var_18] mov rax, [rax] mov [rbp+var_18], rax loc_367D4: cmp [rbp+var_18], 0 jz short loc_367F9 mov rax, [rbp+var_18] mov rax, [rax] mov [rbp+var_20], rax mov rdi, [rbp+var_18] call my_free mov rax, [rbp+var_20] mov [rbp+var_18], rax jmp short loc_367D4 loc_367F9: mov rax, [rbp+var_10] mov rax, [rax+450h] mov qword ptr [rax], 0 mov rax, [rbp+var_10] mov rax, [rax+450h] mov qword ptr [rax+8], 0 loc_3681E: jmp short $+2 loc_36820: jmp short $+2 loc_36822: add rsp, 20h pop rbp retn
unsigned long long ma_reset_state(_QWORD *a1) { unsigned long long result; // rax long long v2; // rcx _QWORD *v3; // [rsp+0h] [rbp-20h] _QWORD *v4; // [rsp+8h] [rbp-18h] _QWORD *i; // [rsp+8h] [rbp-18h] long long v6; // [rsp+10h] [rbp-10h] v6 = *a1; result = *(_QWORD *)(*a1 + 1104LL); v4 = (_QWORD *)result; if ( result ) { result = (unsigned int)*(char *)(v6 + 2024); if ( *(_BYTE *)(v6 + 2024) ) { memcpy(*(_QWORD *)(v6 + 1104) + 16LL, v6 + 24, 56LL); v2 = *(_QWORD *)(v6 + 1104) + 16LL; a1[12] = v2; a1[4] = v2; for ( i = (_QWORD *)*v4; i; i = v3 ) { v3 = (_QWORD *)*i; my_free(i); } **(_QWORD **)(v6 + 1104) = 0LL; result = *(_QWORD *)(v6 + 1104); *(_QWORD *)(result + 8) = 0LL; } } return result; }
_ma_reset_state: PUSH RBP MOV RBP,RSP SUB RSP,0x20 MOV qword ptr [RBP + -0x8],RDI MOV RAX,qword ptr [RBP + -0x8] MOV RAX,qword ptr [RAX] MOV qword ptr [RBP + -0x10],RAX MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x450] MOV qword ptr [RBP + -0x18],RAX CMP qword ptr [RBP + -0x18],0x0 JZ 0x0013681e MOV RAX,qword ptr [RBP + -0x10] MOVSX EAX,byte ptr [RAX + 0x7e8] CMP EAX,0x0 JZ 0x0013681e JMP 0x00136787 LAB_00136787: JMP 0x00136789 LAB_00136789: MOV RAX,qword ptr [RBP + -0x10] MOV RDI,qword ptr [RAX + 0x450] ADD RDI,0x10 MOV RSI,qword ptr [RBP + -0x10] ADD RSI,0x18 MOV EDX,0x38 CALL 0x0012a090 MOV RAX,qword ptr [RBP + -0x10] MOV RCX,qword ptr [RAX + 0x450] ADD RCX,0x10 MOV RAX,qword ptr [RBP + -0x8] MOV qword ptr [RAX + 0x60],RCX MOV RAX,qword ptr [RBP + -0x8] MOV qword ptr [RAX + 0x20],RCX MOV RAX,qword ptr [RBP + -0x18] MOV RAX,qword ptr [RAX] MOV qword ptr [RBP + -0x18],RAX LAB_001367d4: CMP qword ptr [RBP + -0x18],0x0 JZ 0x001367f9 MOV RAX,qword ptr [RBP + -0x18] MOV RAX,qword ptr [RAX] MOV qword ptr [RBP + -0x20],RAX MOV RDI,qword ptr [RBP + -0x18] CALL 0x001f3bb0 MOV RAX,qword ptr [RBP + -0x20] MOV qword ptr [RBP + -0x18],RAX JMP 0x001367d4 LAB_001367f9: MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x450] MOV qword ptr [RAX],0x0 MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x450] MOV qword ptr [RAX + 0x8],0x0 LAB_0013681e: JMP 0x00136820 LAB_00136820: JMP 0x00136822 LAB_00136822: ADD RSP,0x20 POP RBP RET
void _ma_reset_state(long *param_1) { long lVar1; int8 *puVar2; long lVar3; int8 *local_20; lVar1 = *param_1; puVar2 = *(int8 **)(lVar1 + 0x450); if ((puVar2 != (int8 *)0x0) && (*(char *)(lVar1 + 0x7e8) != '\0')) { memcpy((void *)(*(long *)(lVar1 + 0x450) + 0x10),(void *)(lVar1 + 0x18),0x38); lVar3 = *(long *)(lVar1 + 0x450) + 0x10; param_1[0xc] = lVar3; param_1[4] = lVar3; local_20 = (int8 *)*puVar2; while (local_20 != (int8 *)0x0) { puVar2 = (int8 *)*local_20; my_free(local_20); local_20 = puVar2; } **(int8 **)(lVar1 + 0x450) = 0; *(int8 *)(*(long *)(lVar1 + 0x450) + 8) = 0; } return; }
27,572
parse_prefixed_json_tool_call_array(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, unsigned long)
monkey531[P]llama/common/chat.cpp
static common_chat_msg parse_prefixed_json_tool_call_array(const std::string& input, const std::string & prefix, size_t rstrip_prefix = 0) { auto content_end = input.find(prefix); size_t tc_start = std::string::npos; common_chat_msg result; result.role = "assistant"; const auto process_tool_calls = [&](const json & tool_calls) { for (const auto & tool_call : tool_calls) { const auto & arguments = tool_call["arguments"]; result.tool_calls.push_back({ tool_call["name"], arguments.is_string() ? arguments.get<std::string>() : arguments.dump(), tool_call.contains("id") ? tool_call["id"] : "", }); } }; if (content_end == std::string::npos) { result.content = input; } else { tc_start = content_end + prefix.size() - rstrip_prefix; result.content = input.substr(0, content_end); auto tool_calls = json::parse(input.substr(tc_start)); process_tool_calls(tool_calls); } return result; }
O1
cpp
parse_prefixed_json_tool_call_array(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, unsigned long): pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0xf8, %rsp movq %rcx, %rbx movq %rdx, %r12 movq %rsi, %r14 movq %rdi, %rbp movq (%rdx), %rsi movq 0x8(%rdx), %rcx xorl %r13d, %r13d movq %r14, %rdi xorl %edx, %edx callq 0x1bf30 movq %rax, %r15 leaq 0x10(%rbp), %rax movq %rax, (%rbp) movq %r13, 0x8(%rbp) movb %r13b, 0x10(%rbp) leaq 0x30(%rbp), %rax movq %rax, 0x20(%rbp) movq %r13, 0x28(%rbp) movb %r13b, 0x30(%rbp) xorps %xmm0, %xmm0 movups %xmm0, 0x40(%rbp) movq %r13, 0x50(%rbp) leaq 0x68(%rbp), %rax movq %rax, 0x58(%rbp) movq %r13, 0x60(%rbp) movb %r13b, 0x68(%rbp) leaq 0xca8c(%rip), %rcx # 0xf3223 movl $0x9, %r8d movq %rbp, %rdi xorl %esi, %esi xorl %edx, %edx movq %rbp, 0x8(%rsp) callq 0x1bd60 leaq 0x20(%rbp), %r13 cmpq $-0x1, %r15 je 0xe68c7 movq 0x8(%r12), %r12 leaq 0x40(%rsp), %rdi movq %r14, %rsi xorl %edx, %edx movq %r15, %rcx callq 0x1b910 subq %rbx, %r15 addq %r12, %r15 leaq 0x40(%rsp), %rbx movq %r13, %rdi movq %rbx, %rsi callq 0x1ba80 movq (%rbx), %rdi leaq 0x50(%rsp), %rax cmpq %rax, %rdi je 0xe6803 movq 0x50(%rsp), %rsi incq %rsi callq 0x1b8c0 leaq 0x40(%rsp), %rdi movq %r14, %rsi movq %r15, %rdx movq $-0x1, %rcx callq 0x1b910 xorps %xmm0, %xmm0 leaq 0xc0(%rsp), %rdx movaps %xmm0, 0x10(%rdx) movaps %xmm0, (%rdx) leaq 0x10(%rsp), %rbx leaq 0x40(%rsp), %rsi movq %rbx, %rdi movl $0x1, %ecx xorl %r8d, %r8d callq 0xa5cfc movq 0xd0(%rsp), %rax testq %rax, %rax je 0xe6865 leaq 0xc0(%rsp), %rdi movq %rdi, %rsi movl $0x3, %edx callq *%rax movq 0x40(%rsp), %rdi leaq 0x50(%rsp), %rax cmpq %rax, %rdi je 0xe6881 movq 0x50(%rsp), %rsi incq %rsi callq 0x1b8c0 movabsq $-0x8000000000000000, %r14 # imm = 0x8000000000000000 leaq 0xa0(%rsp), %rdi movq %rbx, %rsi callq 0x8da20 movq %rbx, 0x20(%rsp) xorps %xmm0, %xmm0 movups %xmm0, 0x28(%rsp) movq %r14, 0x38(%rsp) movzbl 0x10(%rsp), %eax cmpl $0x2, %eax je 0xe68d7 cmpl $0x1, %eax jne 0xe68e2 movq $0x0, 0x28(%rsp) jmp 0xe68e7 movq %r13, %rdi movq %r14, %rsi callq 0x1b4a0 jmp 0xe6acb movq $0x0, 0x30(%rsp) jmp 0xe68e7 movq %r14, 0x38(%rsp) cmpl $0x2, %eax je 0xe6901 cmpl $0x1, %eax jne 0xe6911 movq 0x18(%rsp), %rax movq 0x8(%rax), %rax movq %rax, 0x28(%rsp) jmp 0xe691a movq 0x18(%rsp), %rax movq 0x8(%rax), %rax movq %rax, 0x30(%rsp) jmp 0xe691a movq $0x1, 0x38(%rsp) leaq 0xa0(%rsp), %rdi leaq 0x20(%rsp), %rsi callq 0x8dae4 testb %al, %al jne 0xe6ac1 movq 0x8(%rsp), %rax leaq 0x40(%rax), %r14 leaq 0xa0(%rsp), %r13 leaq 0x40(%rsp), %r12 leaq 0xe8(%rsp), %r15 movq %r13, %rdi callq 0x8d724 movq %rax, %rbx movq %rax, %rdi leaq 0xdc71(%rip), %rsi # 0xf45d8 callq 0xa6572 movq %rax, %rbp movq %rbx, %rdi leaq 0xe1fb(%rip), %rsi # 0xf4b74 callq 0xa6572 movq %r12, %rdi movq %rax, %rsi callq 0x881f8 cmpb $0x3, (%rbp) jne 0xe699e leaq 0x60(%rsp), %rdi movq %rbp, %rsi callq 0x881f8 jmp 0xe69bb leaq 0x60(%rsp), %rdi movq %rbp, %rsi movl $0xffffffff, %edx # imm = 0xFFFFFFFF movl $0x20, %ecx xorl %r8d, %r8d xorl %r9d, %r9d callq 0x8024c movq %rbx, %rdi leaq 0xccbd(%rip), %rsi # 0xf3682 callq 0xa6510 testb %al, %al je 0xe69ea movq %rbx, %rdi leaq 0xccaa(%rip), %rsi # 0xf3682 callq 0xa6572 movq %r15, %rdi movq %rax, %rsi callq 0x5d92a jmp 0xe69f9 movq %r15, %rdi leaq 0x8f38(%rip), %rsi # 0xef92c callq 0xb9482 leaq 0x80(%rsp), %rdi movq %r15, %rsi callq 0x881f8 movq %r14, %rdi movq %r12, %rsi callq 0xe9684 movq 0x80(%rsp), %rdi leaq 0x90(%rsp), %rax cmpq %rax, %rdi je 0xe6a39 movq 0x90(%rsp), %rsi incq %rsi callq 0x1b8c0 movq 0x60(%rsp), %rdi leaq 0x70(%rsp), %rax cmpq %rax, %rdi je 0xe6a55 movq 0x70(%rsp), %rsi incq %rsi callq 0x1b8c0 movq 0x40(%rsp), %rdi leaq 0x50(%rsp), %rax cmpq %rax, %rdi je 0xe6a71 movq 0x50(%rsp), %rsi incq %rsi callq 0x1b8c0 movq %r15, %rdi callq 0x5de8a movq 0xa0(%rsp), %rax movzbl (%rax), %eax cmpl $0x2, %eax je 0xe6a99 cmpl $0x1, %eax jne 0xe6aa4 addq $0x30, 0xa8(%rsp) jmp 0xe6aac addq $0x10, 0xb0(%rsp) jmp 0xe6aac incq 0xb8(%rsp) movq %r13, %rdi leaq 0x20(%rsp), %rsi callq 0x8dae4 testb %al, %al je 0xe6952 leaq 0x10(%rsp), %rdi callq 0x5de8a movq 0x8(%rsp), %rax addq $0xf8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq jmp 0xe6b3e jmp 0xe6b32 jmp 0xe6bb9 movq %rax, %r14 movq 0xd0(%rsp), %rax testq %rax, %rax je 0xe6b0d leaq 0xc0(%rsp), %rdi movq %rdi, %rsi movl $0x3, %edx callq *%rax movq 0x40(%rsp), %rdi leaq 0x50(%rsp), %rax cmpq %rax, %rdi je 0xe6bc6 movq 0x50(%rsp), %rsi incq %rsi callq 0x1b8c0 jmp 0xe6bc6 movq %rax, %rdi callq 0x21597 jmp 0xe6b3e jmp 0xe6b3e movq %rax, %r14 jmp 0xe6bc6 movq %rax, %r14 movb $0x1, %bl jmp 0xe6b97 movq %rax, %r14 movb $0x1, %bl jmp 0xe6b63 movq %rax, %r14 leaq 0x40(%rsp), %rdi callq 0xe95a4 xorl %ebx, %ebx leaq 0xe8(%rsp), %rdi callq 0x5de8a jmp 0xe6b77 movq %rax, %r14 movb $0x1, %bl testb %bl, %bl je 0xe6b97 movq 0x60(%rsp), %rdi leaq 0x70(%rsp), %rax cmpq %rax, %rdi je 0xe6b97 movq 0x70(%rsp), %rsi incq %rsi callq 0x1b8c0 testb %bl, %bl je 0xe6bbc movq 0x40(%rsp), %rdi leaq 0x50(%rsp), %rax cmpq %rax, %rdi je 0xe6bbc movq 0x50(%rsp), %rsi incq %rsi callq 0x1b8c0 jmp 0xe6bbc movq %rax, %r14 leaq 0x10(%rsp), %rdi callq 0x5de8a movq 0x8(%rsp), %rdi callq 0x7f276 movq %r14, %rdi callq 0x1bf90
_ZL35parse_prefixed_json_tool_call_arrayRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES6_m: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 0F8h mov rbx, rcx mov r12, rdx mov r14, rsi mov rbp, rdi mov rsi, [rdx] mov rcx, [rdx+8] xor r13d, r13d mov rdi, r14 xor edx, edx call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4findEPKcmm; std::string::find(char const*,ulong,ulong) mov r15, rax lea rax, [rbp+10h] mov [rbp+0], rax mov [rbp+8], r13 mov [rbp+10h], r13b lea rax, [rbp+30h] mov [rbp+20h], rax mov [rbp+28h], r13 mov [rbp+30h], r13b xorps xmm0, xmm0 movups xmmword ptr [rbp+40h], xmm0 mov [rbp+50h], r13 lea rax, [rbp+68h] mov [rbp+58h], rax mov [rbp+60h], r13 mov [rbp+68h], r13b lea rcx, aYouAreAHelpful+12h; "assistant" mov r8d, 9 mov rdi, rbp xor esi, esi xor edx, edx mov [rsp+128h+var_120], rbp call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE10_M_replaceEmmPKcm; std::string::_M_replace(ulong,ulong,char const*,ulong) lea r13, [rbp+20h] cmp r15, 0FFFFFFFFFFFFFFFFh jz loc_E68C7 mov r12, [r12+8] lea rdi, [rsp+128h+var_E8] mov rsi, r14 xor edx, edx mov rcx, r15 call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6substrEmm; std::string::substr(ulong,ulong) sub r15, rbx add r15, r12 lea rbx, [rsp+128h+var_E8] mov rdi, r13 mov rsi, rbx call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEaSEOS4_; std::string::operator=(std::string&&) mov rdi, [rbx]; void * lea rax, [rsp+128h+var_D8] cmp rdi, rax jz short loc_E6803 mov rsi, [rsp+128h+var_D8] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_E6803: lea rdi, [rsp+128h+var_E8] mov rsi, r14 mov rdx, r15 mov rcx, 0FFFFFFFFFFFFFFFFh call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6substrEmm; std::string::substr(ulong,ulong) xorps xmm0, xmm0 lea rdx, [rsp+128h+var_68] movaps xmmword ptr [rdx+10h], xmm0 movaps xmmword ptr [rdx], xmm0 lea rbx, [rsp+128h+var_118] lea rsi, [rsp+128h+var_E8] mov rdi, rbx mov ecx, 1 xor r8d, r8d call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE5parseIS9_EESD_OT_St8functionIFbiNS0_6detail13parse_event_tERSD_EEbb; 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>::parse<std::string>(std::string &&,std::function<bool ()(int,nlohmann::json_abi_v3_11_3::detail::parse_event_t,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>&)>,bool,bool) mov rax, [rsp+128h+var_58] test rax, rax jz short loc_E6865 lea rdi, [rsp+128h+var_68] mov rsi, rdi mov edx, 3 call rax loc_E6865: mov rdi, [rsp+128h+var_E8]; void * lea rax, [rsp+128h+var_D8] cmp rdi, rax jz short loc_E6881 mov rsi, [rsp+128h+var_D8] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_E6881: mov r14, 8000000000000000h lea rdi, [rsp+128h+var_88] mov rsi, rbx call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE6cbeginEv; 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>::cbegin(void) mov [rsp+128h+var_108], rbx xorps xmm0, xmm0 movups [rsp+128h+var_100], xmm0 mov [rsp+128h+var_F0], r14 movzx eax, [rsp+128h+var_118] cmp eax, 2 jz short loc_E68D7 cmp eax, 1 jnz short loc_E68E2 mov qword ptr [rsp+128h+var_100], 0 jmp short loc_E68E7 loc_E68C7: mov rdi, r13 mov rsi, r14 call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9_M_assignERKS4_; std::string::_M_assign(std::string const&) jmp loc_E6ACB loc_E68D7: mov qword ptr [rsp+128h+var_100+8], 0 jmp short loc_E68E7 loc_E68E2: mov [rsp+128h+var_F0], r14 loc_E68E7: cmp eax, 2 jz short loc_E6901 cmp eax, 1 jnz short loc_E6911 mov rax, [rsp+128h+var_110] mov rax, [rax+8] mov qword ptr [rsp+128h+var_100], rax jmp short loc_E691A loc_E6901: mov rax, [rsp+128h+var_110] mov rax, [rax+8] mov qword ptr [rsp+128h+var_100+8], rax jmp short loc_E691A loc_E6911: mov [rsp+128h+var_F0], 1 loc_E691A: lea rdi, [rsp+128h+var_88] lea rsi, [rsp+128h+var_108] call _ZNK8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEeqISH_TnNSt9enable_ifIXoosr3std7is_sameIT_SH_EE5valuesr3std7is_sameISK_NS2_ISF_EEEE5valueEDnE4typeELDn0EEEbRKSK_ test al, al jnz loc_E6AC1 mov rax, [rsp+128h+var_120] lea r14, [rax+40h] lea r13, [rsp+128h+var_88] lea r12, [rsp+128h+var_E8] lea r15, [rsp+128h+var_40] loc_E6952: mov rdi, r13 call _ZNK8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEdeEv; 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>::operator*(void) mov rbx, rax mov rdi, rax lea rsi, aKeywordArgumen+9; "arguments" call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEixIKcEERKSD_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 *) mov rbp, rax mov rdi, rbx lea rsi, aNamespacedSetO+2Fh; "name" call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEixIKcEERKSD_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 *) mov rdi, r12 mov rsi, rax 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 cmp byte ptr [rbp+0], 3 jnz short loc_E699E lea rdi, [rsp+128h+var_C8] mov rsi, rbp 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 jmp short loc_E69BB loc_E699E: lea rdi, [rsp+128h+var_C8] mov rsi, rbp 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) loc_E69BB: mov rdi, rbx lea rsi, aToolCallId+0Ah; "id" call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE8containsIRA3_KcTnNSt9enable_ifIXsr6detail32is_usable_as_basic_json_key_typeISD_T_EE5valueEiE4typeELi0EEEbOSJ_ test al, al jz short loc_E69EA mov rdi, rbx lea rsi, aToolCallId+0Ah; "id" call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEixIKcEERKSD_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 *) mov rdi, r15 mov rsi, rax 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 short loc_E69F9 loc_E69EA: mov rdi, r15 lea rsi, aErrorWhileHand_0+34h; "" call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEC2IRA1_KcA1_cTnNSt9enable_ifIXaantsr6detail13is_basic_jsonIT0_EE5valuesr6detail18is_compatible_typeISD_SK_EE5valueEiE4typeELi0EEEOT_ loc_E69F9: lea rdi, [rsp+128h+var_A8] 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, r14 mov rsi, r12 call _ZNSt6vectorI16common_tool_callSaIS0_EE12emplace_backIJS0_EEERS0_DpOT_; std::vector<common_tool_call>::emplace_back<common_tool_call>(common_tool_call &&) mov rdi, [rsp+128h+var_A8]; void * lea rax, [rsp+128h+var_98] cmp rdi, rax jz short loc_E6A39 mov rsi, [rsp+128h+var_98] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_E6A39: mov rdi, [rsp+128h+var_C8]; void * lea rax, [rsp+128h+var_B8] cmp rdi, rax jz short loc_E6A55 mov rsi, [rsp+128h+var_B8] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_E6A55: mov rdi, [rsp+128h+var_E8]; void * lea rax, [rsp+128h+var_D8] cmp rdi, rax jz short loc_E6A71 mov rsi, [rsp+128h+var_D8] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_E6A71: mov rdi, r15 call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE4dataD2Ev; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::data::~data() mov rax, [rsp+128h+var_88] movzx eax, byte ptr [rax] cmp eax, 2 jz short loc_E6A99 cmp eax, 1 jnz short loc_E6AA4 add [rsp+128h+var_80], 30h ; '0' jmp short loc_E6AAC loc_E6A99: add [rsp+128h+var_78], 10h jmp short loc_E6AAC loc_E6AA4: inc [rsp+128h+var_70] loc_E6AAC: mov rdi, r13 lea rsi, [rsp+128h+var_108] call _ZNK8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEeqISH_TnNSt9enable_ifIXoosr3std7is_sameIT_SH_EE5valuesr3std7is_sameISK_NS2_ISF_EEEE5valueEDnE4typeELDn0EEEbRKSK_ test al, al jz loc_E6952 loc_E6AC1: lea rdi, [rsp+128h+var_118] 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_E6ACB: mov rax, [rsp+128h+var_120] add rsp, 0F8h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn jmp short loc_E6B3E jmp short loc_E6B32 jmp loc_E6BB9 mov r14, rax mov rax, [rsp+128h+var_58] test rax, rax jz short loc_E6B0D lea rdi, [rsp+128h+var_68] mov rsi, rdi mov edx, 3 call rax loc_E6B0D: mov rdi, [rsp+128h+var_E8]; void * lea rax, [rsp+128h+var_D8] cmp rdi, rax jz loc_E6BC6 mov rsi, [rsp+128h+var_D8] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) jmp loc_E6BC6 loc_E6B32: mov rdi, rax call __clang_call_terminate jmp short loc_E6B3E jmp short $+2 loc_E6B3E: mov r14, rax jmp loc_E6BC6 mov r14, rax mov bl, 1 jmp short loc_E6B97 mov r14, rax mov bl, 1 jmp short loc_E6B63 mov r14, rax lea rdi, [rsp+128h+var_E8]; this call _ZN16common_tool_callD2Ev; common_tool_call::~common_tool_call() xor ebx, ebx loc_E6B63: lea rdi, [rsp+128h+var_40] 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_E6B77 mov r14, rax mov bl, 1 loc_E6B77: test bl, bl jz short loc_E6B97 mov rdi, [rsp+128h+var_C8]; void * lea rax, [rsp+128h+var_B8] cmp rdi, rax jz short loc_E6B97 mov rsi, [rsp+128h+var_B8] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_E6B97: test bl, bl jz short loc_E6BBC mov rdi, [rsp+128h+var_E8]; void * lea rax, [rsp+128h+var_D8] cmp rdi, rax jz short loc_E6BBC mov rsi, [rsp+128h+var_D8] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) jmp short loc_E6BBC loc_E6BB9: mov r14, rax loc_E6BBC: lea rdi, [rsp+128h+var_118] 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_E6BC6: mov rdi, [rsp+128h+var_120]; this call _ZN15common_chat_msgD2Ev; common_chat_msg::~common_chat_msg() mov rdi, r14 call __Unwind_Resume
long long parse_prefixed_json_tool_call_array(long long a1, long long a2, _QWORD *a3, long long a4) { long long v6; // r15 long long v7; // r12 long long v8; // r15 long long v9; // rbx _BYTE *v10; // rbp long long v11; // rax unsigned __int8 *v12; // rax int v13; // eax unsigned __int8 v15[8]; // [rsp+10h] [rbp-118h] BYREF long long v16; // [rsp+18h] [rbp-110h] unsigned __int8 *v17; // [rsp+20h] [rbp-108h] BYREF __int128 v18; // [rsp+28h] [rbp-100h] long long v19; // [rsp+38h] [rbp-F0h] void *v20[2]; // [rsp+40h] [rbp-E8h] BYREF _QWORD v21[2]; // [rsp+50h] [rbp-D8h] BYREF void *v22[2]; // [rsp+60h] [rbp-C8h] BYREF long long v23; // [rsp+70h] [rbp-B8h] BYREF void *v24; // [rsp+80h] [rbp-A8h] BYREF long long v25; // [rsp+90h] [rbp-98h] BYREF unsigned __int8 *v26; // [rsp+A0h] [rbp-88h] BYREF long long v27; // [rsp+A8h] [rbp-80h] long long v28; // [rsp+B0h] [rbp-78h] long long v29; // [rsp+B8h] [rbp-70h] __int128 v30; // [rsp+C0h] [rbp-68h] BYREF __int128 v31; // [rsp+D0h] [rbp-58h] unsigned __int8 v32[64]; // [rsp+E8h] [rbp-40h] BYREF v6 = std::string::find(a2, *a3, 0LL, a3[1]); *(_QWORD *)a1 = a1 + 16; *(_QWORD *)(a1 + 8) = 0LL; *(_BYTE *)(a1 + 16) = 0; *(_QWORD *)(a1 + 32) = a1 + 48; *(_QWORD *)(a1 + 40) = 0LL; *(_BYTE *)(a1 + 48) = 0; *(_OWORD *)(a1 + 64) = 0LL; *(_QWORD *)(a1 + 80) = 0LL; *(_QWORD *)(a1 + 88) = a1 + 104; *(_QWORD *)(a1 + 96) = 0LL; *(_BYTE *)(a1 + 104) = 0; std::string::_M_replace(a1, 0LL, 0LL, "assistant", 9LL); if ( v6 == -1 ) { std::string::_M_assign(a1 + 32, a2); } else { v7 = a3[1]; std::string::substr(v20, a2, 0LL, v6); v8 = v7 + v6 - a4; std::string::operator=(a1 + 32, v20); if ( v20[0] != v21 ) operator delete(v20[0], v21[0] + 1LL); std::string::substr(v20, a2, v8, -1LL); v31 = 0LL; v30 = 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>::parse<std::string>( (long long)v15, (long long *)v20, (long long)&v30, 1u, 0); if ( (_QWORD)v31 ) ((void ( *)(__int128 *, __int128 *, long long))v31)(&v30, &v30, 3LL); if ( v20[0] != v21 ) operator delete(v20[0], v21[0] + 1LL); 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>::cbegin( (long long)&v26, v15); v17 = v15; v18 = 0LL; v19 = 0x8000000000000000LL; if ( v15[0] == 2 ) { *((_QWORD *)&v18 + 1) = 0LL; } else if ( v15[0] == 1 ) { *(_QWORD *)&v18 = 0LL; } else { v19 = 0x8000000000000000LL; } if ( v15[0] == 2 ) { *((_QWORD *)&v18 + 1) = *(_QWORD *)(v16 + 8); } else if ( v15[0] == 1 ) { *(_QWORD *)&v18 = *(_QWORD *)(v16 + 8); } else { v19 = 1LL; } while ( !(unsigned __int8)ZNK8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEeqISH_TnNSt9enable_ifIXoosr3std7is_sameIT_SH_EE5valuesr3std7is_sameISK_NS2_ISF_EEEE5valueEDnE4typeELDn0EEEbRKSK_( &v26, &v17) ) { v9 = 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,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void> const>::operator*(&v26); v10 = (_BYTE *)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>( v9, "arguments"); v11 = 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>( v9, "name"); 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)v20, v11); if ( *v10 == 3 ) 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)v22, (long long)v10); else 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)v22, (long long)v10, -1, 32, 0, 0); if ( ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE8containsIRA3_KcTnNSt9enable_ifIXsr6detail32is_usable_as_basic_json_key_typeISD_T_EE5valueEiE4typeELi0EEEbOSJ_( v9, (long long)"id") ) { v12 = (unsigned __int8 *)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>( v9, "id"); 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( v32, v12); } else { ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEC2IRA1_KcA1_cTnNSt9enable_ifIXaantsr6detail13is_basic_jsonIT0_EE5valuesr6detail18is_compatible_typeISD_SK_EE5valueEiE4typeELi0EEEOT_((char *)v32); } 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)&v24, (long long)v32); std::vector<common_tool_call>::emplace_back<common_tool_call>(a1 + 64, v20); if ( v24 != &v25 ) operator delete(v24, v25 + 1); if ( v22[0] != &v23 ) operator delete(v22[0], v23 + 1); if ( v20[0] != v21 ) operator delete(v20[0], v21[0] + 1LL); 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(v32); v13 = *v26; if ( v13 == 2 ) { v28 += 16LL; } else if ( v13 == 1 ) { v27 += 48LL; } else { ++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(v15); } return a1; }
parse_prefixed_json_tool_call_array: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0xf8 MOV RBX,RCX MOV R12,RDX MOV R14,RSI MOV RBP,RDI MOV RSI,qword ptr [RDX] MOV RCX,qword ptr [RDX + 0x8] XOR R13D,R13D MOV RDI,R14 XOR EDX,EDX CALL 0x0011bf30 MOV R15,RAX LEA RAX,[RBP + 0x10] MOV qword ptr [RBP],RAX MOV qword ptr [RBP + 0x8],R13 MOV byte ptr [RBP + 0x10],R13B LEA RAX,[RBP + 0x30] MOV qword ptr [RBP + 0x20],RAX MOV qword ptr [RBP + 0x28],R13 MOV byte ptr [RBP + 0x30],R13B XORPS XMM0,XMM0 MOVUPS xmmword ptr [RBP + 0x40],XMM0 MOV qword ptr [RBP + 0x50],R13 LEA RAX,[RBP + 0x68] MOV qword ptr [RBP + 0x58],RAX MOV qword ptr [RBP + 0x60],R13 MOV byte ptr [RBP + 0x68],R13B LAB_001e6790: LEA RCX,[0x1f3223] MOV R8D,0x9 MOV RDI,RBP XOR ESI,ESI XOR EDX,EDX MOV qword ptr [RSP + 0x8],RBP CALL 0x0011bd60 LEA R13,[RBP + 0x20] CMP R15,-0x1 JZ 0x001e68c7 MOV R12,qword ptr [R12 + 0x8] LAB_001e67c1: LEA RDI,[RSP + 0x40] MOV RSI,R14 XOR EDX,EDX MOV RCX,R15 CALL 0x0011b910 SUB R15,RBX ADD R15,R12 LEA RBX,[RSP + 0x40] MOV RDI,R13 MOV RSI,RBX CALL 0x0011ba80 MOV RDI,qword ptr [RBX] LEA RAX,[RSP + 0x50] CMP RDI,RAX JZ 0x001e6803 MOV RSI,qword ptr [RSP + 0x50] INC RSI CALL 0x0011b8c0 LAB_001e6803: LEA RDI,[RSP + 0x40] MOV RSI,R14 MOV RDX,R15 MOV RCX,-0x1 CALL 0x0011b910 XORPS XMM0,XMM0 LEA RDX,[RSP + 0xc0] MOVAPS xmmword ptr [RDX + 0x10],XMM0 MOVAPS xmmword ptr [RDX],XMM0 LAB_001e682c: LEA RBX,[RSP + 0x10] LEA RSI,[RSP + 0x40] MOV RDI,RBX MOV ECX,0x1 XOR R8D,R8D CALL 0x001a5cfc MOV RAX,qword ptr [RSP + 0xd0] TEST RAX,RAX JZ 0x001e6865 LAB_001e6853: LEA RDI,[RSP + 0xc0] MOV RSI,RDI MOV EDX,0x3 CALL RAX LAB_001e6865: MOV RDI,qword ptr [RSP + 0x40] LEA RAX,[RSP + 0x50] CMP RDI,RAX JZ 0x001e6881 MOV RSI,qword ptr [RSP + 0x50] INC RSI CALL 0x0011b8c0 LAB_001e6881: MOV R14,-0x8000000000000000 LEA RDI,[RSP + 0xa0] MOV RSI,RBX CALL 0x0018da20 MOV qword ptr [RSP + 0x20],RBX XORPS XMM0,XMM0 MOVUPS xmmword ptr [RSP + 0x28],XMM0 MOV qword ptr [RSP + 0x38],R14 MOVZX EAX,byte ptr [RSP + 0x10] CMP EAX,0x2 JZ 0x001e68d7 CMP EAX,0x1 JNZ 0x001e68e2 MOV qword ptr [RSP + 0x28],0x0 JMP 0x001e68e7 LAB_001e68c7: MOV RDI,R13 MOV RSI,R14 CALL 0x0011b4a0 JMP 0x001e6acb LAB_001e68d7: MOV qword ptr [RSP + 0x30],0x0 JMP 0x001e68e7 LAB_001e68e2: MOV qword ptr [RSP + 0x38],R14 LAB_001e68e7: CMP EAX,0x2 JZ 0x001e6901 CMP EAX,0x1 JNZ 0x001e6911 MOV RAX,qword ptr [RSP + 0x18] MOV RAX,qword ptr [RAX + 0x8] MOV qword ptr [RSP + 0x28],RAX JMP 0x001e691a LAB_001e6901: MOV RAX,qword ptr [RSP + 0x18] MOV RAX,qword ptr [RAX + 0x8] MOV qword ptr [RSP + 0x30],RAX JMP 0x001e691a LAB_001e6911: MOV qword ptr [RSP + 0x38],0x1 LAB_001e691a: LEA RDI,[RSP + 0xa0] LEA RSI,[RSP + 0x20] CALL 0x0018dae4 TEST AL,AL JNZ 0x001e6ac1 MOV RAX,qword ptr [RSP + 0x8] LEA R14,[RAX + 0x40] LEA R13,[RSP + 0xa0] LEA R12,[RSP + 0x40] LEA R15,[RSP + 0xe8] LAB_001e6952: MOV RDI,R13 CALL 0x0018d724 MOV RBX,RAX MOV RDI,RAX LEA RSI,[0x1f45d8] CALL 0x001a6572 MOV RBP,RAX MOV RDI,RBX LEA RSI,[0x1f4b74] CALL 0x001a6572 MOV RDI,R12 MOV RSI,RAX CALL 0x001881f8 CMP byte ptr [RBP],0x3 JNZ 0x001e699e LAB_001e698f: LEA RDI,[RSP + 0x60] MOV RSI,RBP CALL 0x001881f8 JMP 0x001e69bb LAB_001e699e: LEA RDI,[RSP + 0x60] MOV RSI,RBP MOV EDX,0xffffffff MOV ECX,0x20 XOR R8D,R8D XOR R9D,R9D CALL 0x0018024c LAB_001e69bb: MOV RDI,RBX LEA RSI,[0x1f3682] CALL 0x001a6510 TEST AL,AL JZ 0x001e69ea MOV RDI,RBX LEA RSI,[0x1f3682] CALL 0x001a6572 MOV RDI,R15 MOV RSI,RAX CALL 0x0015d92a JMP 0x001e69f9 LAB_001e69ea: MOV RDI,R15 LEA RSI,[0x1ef92c] CALL 0x001b9482 LAB_001e69f9: LEA RDI,[RSP + 0x80] MOV RSI,R15 CALL 0x001881f8 LAB_001e6a09: MOV RDI,R14 MOV RSI,R12 CALL 0x001e9684 MOV RDI,qword ptr [RSP + 0x80] LEA RAX,[RSP + 0x90] CMP RDI,RAX JZ 0x001e6a39 MOV RSI,qword ptr [RSP + 0x90] INC RSI CALL 0x0011b8c0 LAB_001e6a39: MOV RDI,qword ptr [RSP + 0x60] LEA RAX,[RSP + 0x70] CMP RDI,RAX JZ 0x001e6a55 MOV RSI,qword ptr [RSP + 0x70] INC RSI CALL 0x0011b8c0 LAB_001e6a55: MOV RDI,qword ptr [RSP + 0x40] LEA RAX,[RSP + 0x50] CMP RDI,RAX JZ 0x001e6a71 MOV RSI,qword ptr [RSP + 0x50] INC RSI CALL 0x0011b8c0 LAB_001e6a71: MOV RDI,R15 CALL 0x0015de8a MOV RAX,qword ptr [RSP + 0xa0] MOVZX EAX,byte ptr [RAX] CMP EAX,0x2 JZ 0x001e6a99 CMP EAX,0x1 JNZ 0x001e6aa4 ADD qword ptr [RSP + 0xa8],0x30 JMP 0x001e6aac LAB_001e6a99: ADD qword ptr [RSP + 0xb0],0x10 JMP 0x001e6aac LAB_001e6aa4: INC qword ptr [RSP + 0xb8] LAB_001e6aac: MOV RDI,R13 LEA RSI,[RSP + 0x20] CALL 0x0018dae4 TEST AL,AL JZ 0x001e6952 LAB_001e6ac1: LEA RDI,[RSP + 0x10] CALL 0x0015de8a LAB_001e6acb: MOV RAX,qword ptr [RSP + 0x8] ADD RSP,0xf8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
/* parse_prefixed_json_tool_call_array(std::__cxx11::string const&, std::__cxx11::string const&, unsigned long) */ string * parse_prefixed_json_tool_call_array(string *param_1,string *param_2,ulong param_3) { char cVar1; long lVar2; basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,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 *pbVar3; basic_json *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> local_118 [8]; long local_110; basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,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_108; int8 local_100; int8 uStack_f8; int8 local_f0; long *local_e8 [2]; long local_d8 [2]; long *local_c8 [2]; long local_b8 [2]; long *local_a8 [2]; long local_98 [2]; char *local_88; long local_80; long local_78; long local_70; int8 local_68; int8 uStack_60; code *local_58; int8 uStack_50; basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> local_40 [16]; lVar2 = std::__cxx11::string::find((char *)param_2,*(ulong *)param_3,0); *(string **)param_1 = param_1 + 0x10; *(int8 *)(param_1 + 8) = 0; param_1[0x10] = (string)0x0; *(string **)(param_1 + 0x20) = param_1 + 0x30; *(int8 *)(param_1 + 0x28) = 0; param_1[0x30] = (string)0x0; *(int8 *)(param_1 + 0x40) = 0; *(int8 *)(param_1 + 0x48) = 0; *(int8 *)(param_1 + 0x50) = 0; *(string **)(param_1 + 0x58) = param_1 + 0x68; *(int8 *)(param_1 + 0x60) = 0; param_1[0x68] = (string)0x0; /* try { // try from 001e6790 to 001e67ad has its CatchHandler @ 001e6b3e */ std::__cxx11::string::_M_replace((ulong)param_1,0,(char *)0x0,0x1f3223); if (lVar2 == -1) { /* try { // try from 001e68c7 to 001e68d1 has its CatchHandler @ 001e6ae2 */ std::__cxx11::string::_M_assign(param_1 + 0x20); } else { /* try { // try from 001e67c1 to 001e67d2 has its CatchHandler @ 001e6b3c */ std::__cxx11::string::substr((ulong)local_e8,(ulong)param_2); std::__cxx11::string::operator=(param_1 + 0x20,(string *)local_e8); if (local_e8[0] != local_d8) { operator_delete(local_e8[0],local_d8[0] + 1); } /* try { // try from 001e6803 to 001e6819 has its CatchHandler @ 001e6b3a */ std::__cxx11::string::substr((ulong)local_e8,(ulong)param_2); local_58 = (code *)0x0; uStack_50 = 0; local_68 = 0; uStack_60 = 0; /* try { // try from 001e682c to 001e6845 has its CatchHandler @ 001e6aeb */ 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> ::parse<std::__cxx11::string>(local_118,local_e8,&local_68,1,0); if (local_58 != (code *)0x0) { /* try { // try from 001e6853 to 001e6864 has its CatchHandler @ 001e6ae4 */ (*local_58)(&local_68,&local_68,3); } if (local_e8[0] != local_d8) { operator_delete(local_e8[0],local_d8[0] + 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> ::cbegin(); local_f0 = 0x8000000000000000; uStack_f8 = 0; local_100 = 0; if (local_118[0] == (basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> )0x2) { uStack_f8 = *(int8 *)(local_110 + 8); } else if (local_118[0] == (basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> )0x1) { local_100 = *(int8 *)(local_110 + 8); } else { local_f0 = 1; } /* try { // try from 001e691a to 001e692b has its CatchHandler @ 001e6ae6 */ local_108 = local_118; cVar1 = _ZNK8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEeqISH_TnNSt9enable_ifIXoosr3std7is_sameIT_SH_EE5valuesr3std7is_sameISK_NS2_ISF_EEEE5valueEDnE4typeELDn0EEEbRKSK_ (&local_88,&local_108); if (cVar1 == '\0') { do { /* try { // try from 001e6952 to 001e6988 has its CatchHandler @ 001e6bb9 */ 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> *)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> ::operator*((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> *)&local_88); pbVar3 = 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>(this,"arguments"); pbVar4 = 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>(this,"name"); _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 ((common_tool_call *)local_e8,pbVar4); if (*pbVar3 == (basic_json)0x3) { /* try { // try from 001e698f to 001e69ba has its CatchHandler @ 001e6b46 */ _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_c8,pbVar3); } else { 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,pbVar3,0xffffffff,0x20,0,0); } /* try { // try from 001e69bb to 001e69f8 has its CatchHandler @ 001e6b72 */ cVar1 = _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE8containsIRA3_KcTnNSt9enable_ifIXsr6detail32is_usable_as_basic_json_key_typeISD_T_EE5valueEiE4typeELi0EEEbOSJ_ (this,"id"); if (cVar1 == '\0') { _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEC2IRA1_KcA1_cTnNSt9enable_ifIXaantsr6detail13is_basic_jsonIT0_EE5valuesr6detail18is_compatible_typeISD_SK_EE5valueEiE4typeELi0EEEOT_ (local_40,""); } else { pbVar3 = 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>(this,"id"); 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(local_40,pbVar3); } /* try { // try from 001e69f9 to 001e6a08 has its CatchHandler @ 001e6b4d */ _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_a8,local_40); /* try { // try from 001e6a09 to 001e6a13 has its CatchHandler @ 001e6b54 */ std::vector<common_tool_call,std::allocator<common_tool_call>>:: emplace_back<common_tool_call> ((vector<common_tool_call,std::allocator<common_tool_call>> *)(param_1 + 0x40), (common_tool_call *)local_e8); if (local_a8[0] != local_98) { operator_delete(local_a8[0],local_98[0] + 1); } if (local_c8[0] != local_b8) { operator_delete(local_c8[0],local_b8[0] + 1); } if (local_e8[0] != local_d8) { operator_delete(local_e8[0],local_d8[0] + 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> ::data::~data((data *)local_40); if (*local_88 == '\x02') { local_78 = local_78 + 0x10; } else if (*local_88 == '\x01') { local_80 = local_80 + 0x30; } else { local_70 = local_70 + 1; } /* try { // try from 001e6aac to 001e6ab8 has its CatchHandler @ 001e6bb9 */ cVar1 = _ZNK8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEeqISH_TnNSt9enable_ifIXoosr3std7is_sameIT_SH_EE5valuesr3std7is_sameISK_NS2_ISF_EEEE5valueEDnE4typeELDn0EEEbRKSK_ ((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> *)&local_88,&local_108); } while (cVar1 == '\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_118); } return param_1; }
27,573
parse_prefixed_json_tool_call_array(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, unsigned long)
monkey531[P]llama/common/chat.cpp
static common_chat_msg parse_prefixed_json_tool_call_array(const std::string& input, const std::string & prefix, size_t rstrip_prefix = 0) { auto content_end = input.find(prefix); size_t tc_start = std::string::npos; common_chat_msg result; result.role = "assistant"; const auto process_tool_calls = [&](const json & tool_calls) { for (const auto & tool_call : tool_calls) { const auto & arguments = tool_call["arguments"]; result.tool_calls.push_back({ tool_call["name"], arguments.is_string() ? arguments.get<std::string>() : arguments.dump(), tool_call.contains("id") ? tool_call["id"] : "", }); } }; if (content_end == std::string::npos) { result.content = input; } else { tc_start = content_end + prefix.size() - rstrip_prefix; result.content = input.substr(0, content_end); auto tool_calls = json::parse(input.substr(tc_start)); process_tool_calls(tool_calls); } return result; }
O2
cpp
parse_prefixed_json_tool_call_array(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, unsigned long): pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0xf8, %rsp movq %rcx, %r15 movq %rdx, %r12 movq %rsi, %rbx movq %rdi, %r13 movq %rsi, %rdi movq %rdx, %rsi xorl %edx, %edx callq 0x25190 movq %rax, %r14 movq %r13, %rdi callq 0xab668 leaq 0xbe30(%rip), %rsi # 0xb5203 movq %r13, 0x8(%rsp) movq %r13, %rdi callq 0x25100 cmpq $-0x1, %r14 je 0xa95d5 movq 0x8(%r12), %r12 leaq 0x50(%rsp), %rdi movq %rbx, %rsi xorl %edx, %edx movq %r14, %rcx callq 0x24920 subq %r15, %r14 addq %r12, %r14 movq 0x8(%rsp), %rax leaq 0x20(%rax), %rdi leaq 0x50(%rsp), %r15 movq %r15, %rsi callq 0x24aa0 movq %r15, %rdi callq 0x251d8 leaq 0x50(%rsp), %rdi pushq $-0x1 popq %rcx movq %rbx, %rsi movq %r14, %rdx callq 0x24920 xorps %xmm0, %xmm0 leaq 0xb0(%rsp), %rdx movaps %xmm0, 0x10(%rdx) movaps %xmm0, (%rdx) leaq 0x10(%rsp), %rdi leaq 0x50(%rsp), %rsi pushq $0x1 popq %rcx xorl %r8d, %r8d callq 0x7b4d2 leaq 0xb0(%rsp), %rdi callq 0x48930 leaq 0x50(%rsp), %r15 movq %r15, %rdi callq 0x251d8 leaq 0x20(%rsp), %r12 leaq 0x10(%rsp), %rbx movq %r12, %rdi movq %rbx, %rsi callq 0x68960 leaq 0xd8(%rsp), %rdi movq %rbx, %rsi callq 0x68bcc movq 0x8(%rsp), %rax leaq 0x40(%rax), %rbx leaq 0x40(%rsp), %rbp movq %r12, %rdi leaq 0xd8(%rsp), %rsi callq 0x68404 testb %al, %al je 0xa95c4 movq %r12, %rdi callq 0x685fe movq %rax, %r13 movq %rax, %rdi leaq 0xd0df(%rip), %rsi # 0xb65b8 callq 0x7bb0c movq %rax, %r14 movq %r13, %rdi leaq 0xd669(%rip), %rsi # 0xb6b54 callq 0x7bb0c movq %r15, %rdi movq %rax, %rsi callq 0x64862 cmpb $0x3, (%r14) jne 0xa9510 leaq 0x70(%rsp), %rdi movq %r14, %rsi callq 0x64862 jmp 0xa9529 leaq 0x70(%rsp), %rdi movq %r14, %rsi pushq $-0x1 popq %rdx pushq $0x20 popq %rcx xorl %r8d, %r8d xorl %r9d, %r9d callq 0x5dd7c movq %r13, %rdi leaq 0xc12f(%rip), %rsi # 0xb5662 callq 0x7baea testb %al, %al je 0xa9558 movq %r13, %rdi leaq 0xc11c(%rip), %rsi # 0xb5662 callq 0x7bb0c movq %rbp, %rdi movq %rax, %rsi callq 0x42c42 jmp 0xa9567 movq %rbp, %rdi leaq 0x83cd(%rip), %rsi # 0xb192f callq 0x89196 leaq 0x90(%rsp), %rdi movq %rbp, %rsi callq 0x64862 movq %rbx, %rdi movq %r15, %rsi callq 0xab6ec movq %r15, %rdi callq 0x8b15a movq %rbp, %rdi callq 0x430a6 movq 0x20(%rsp), %rax movzbl (%rax), %eax cmpl $0x2, %eax je 0xa95af cmpl $0x1, %eax jne 0xa95ba addq $0x30, 0x28(%rsp) jmp 0xa94ac addq $0x10, 0x30(%rsp) jmp 0xa94ac incq 0x38(%rsp) jmp 0xa94ac leaq 0x10(%rsp), %rdi callq 0x430a6 movq 0x8(%rsp), %r14 jmp 0xa95e6 movq 0x8(%rsp), %r14 leaq 0x20(%r14), %rdi movq %rbx, %rsi callq 0x244c0 movq %r14, %rax addq $0xf8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq jmp 0xa961d movq %rax, %rbx leaq 0xb0(%rsp), %rdi callq 0x48930 leaq 0x50(%rsp), %rdi callq 0x251d8 jmp 0xa9675 jmp 0xa961d jmp 0xa961d movq %rax, %rbx jmp 0xa9675 movq %rax, %rbx leaq 0x50(%rsp), %rdi callq 0x8b15a xorl %ebp, %ebp jmp 0xa9639 movq %rax, %rbx movb $0x1, %bpl leaq 0x40(%rsp), %rdi callq 0x430a6 testb %bpl, %bpl jne 0xa9652 jmp 0xa966b movq %rax, %rbx jmp 0xa965c movq %rax, %rbx leaq 0x70(%rsp), %rdi callq 0x251d8 leaq 0x50(%rsp), %rdi callq 0x251d8 jmp 0xa966b movq %rax, %rbx leaq 0x10(%rsp), %rdi callq 0x430a6 movq 0x8(%rsp), %rdi callq 0x5d0c0 movq %rbx, %rdi callq 0x24f80
_ZL35parse_prefixed_json_tool_call_arrayRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES6_m: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 0F8h mov r15, rcx mov r12, rdx mov rbx, rsi mov r13, rdi mov rdi, rsi mov rsi, rdx xor edx, edx call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4findERKS4_m; std::string::find(std::string const&,ulong) mov r14, rax mov rdi, r13; this call _ZN15common_chat_msgC2Ev; common_chat_msg::common_chat_msg(void) lea rsi, aYouAreAHelpful+12h; "assistant" mov [rsp+128h+var_120], r13 mov rdi, r13 call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6assignEPKc; std::string::assign(char const*) cmp r14, 0FFFFFFFFFFFFFFFFh jz loc_A95D5 mov r12, [r12+8] lea rdi, [rsp+128h+var_D8] mov rsi, rbx xor edx, edx mov rcx, r14 call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6substrEmm; std::string::substr(ulong,ulong) sub r14, r15 add r14, r12 mov rax, [rsp+128h+var_120] lea rdi, [rax+20h] lea r15, [rsp+128h+var_D8] mov rsi, r15 call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEaSEOS4_; std::string::operator=(std::string&&) mov rdi, r15; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() lea rdi, [rsp+128h+var_D8] push 0FFFFFFFFFFFFFFFFh pop rcx mov rsi, rbx mov rdx, r14 call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6substrEmm; std::string::substr(ulong,ulong) xorps xmm0, xmm0 lea rdx, [rsp+128h+var_78] movaps xmmword ptr [rdx+10h], xmm0 movaps xmmword ptr [rdx], xmm0 lea rdi, [rsp+128h+var_118] lea rsi, [rsp+128h+var_D8] push 1 pop rcx xor r8d, r8d call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE5parseIS9_EESD_OT_St8functionIFbiNS0_6detail13parse_event_tERSD_EEbb; 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>::parse<std::string>(std::string &&,std::function<bool ()(int,nlohmann::json_abi_v3_11_3::detail::parse_event_t,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>&)>,bool,bool) lea rdi, [rsp+128h+var_78]; this call _ZNSt14_Function_baseD2Ev; std::_Function_base::~_Function_base() lea r15, [rsp+128h+var_D8] mov rdi, r15; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() lea r12, [rsp+128h+var_108] lea rbx, [rsp+128h+var_118] mov rdi, r12 mov rsi, rbx call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE6cbeginEv; 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>::cbegin(void) lea rdi, [rsp+128h+var_50] mov rsi, rbx call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE4cendEv; 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>::cend(void) mov rax, [rsp+128h+var_120] lea rbx, [rax+40h] lea rbp, [rsp+128h+var_E8] loc_A94AC: mov rdi, r12 lea rsi, [rsp+128h+var_50] call _ZNK8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEneISH_TnNSt9enable_ifIXoosr3std7is_sameIT_SH_EE5valuesr3std7is_sameISK_NS2_ISF_EEEE5valueEDnE4typeELDn0EEEbRKSK_ test al, al jz loc_A95C4 mov rdi, r12 call _ZNK8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEdeEv; 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>::operator*(void) mov r13, rax mov rdi, rax lea rsi, aKeywordArgumen+9; "arguments" call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEixIKcEERKSD_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 *) mov r14, rax mov rdi, r13 lea rsi, aNamespacedSetO+2Fh; "name" call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEixIKcEERKSD_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 *) mov rdi, r15 mov rsi, rax 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 cmp byte ptr [r14], 3 jnz short loc_A9510 lea rdi, [rsp+128h+var_B8] mov rsi, r14 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 jmp short loc_A9529 loc_A9510: lea rdi, [rsp+128h+var_B8] mov rsi, r14 push 0FFFFFFFFFFFFFFFFh pop rdx push 20h ; ' ' pop rcx 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) loc_A9529: mov rdi, r13 lea rsi, aToolCallId+0Ah; "id" call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE8containsIRA3_KcTnNSt9enable_ifIXsr6detail32is_usable_as_basic_json_key_typeISD_T_EE5valueEiE4typeELi0EEEbOSJ_ test al, al jz short loc_A9558 mov rdi, r13 lea rsi, aToolCallId+0Ah; "id" call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEixIKcEERKSD_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 *) mov rdi, rbp mov rsi, rax 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 short loc_A9567 loc_A9558: mov rdi, rbp lea rsi, aErrorWhileHand_0+34h; "" call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEC2IRA1_KcA1_cTnNSt9enable_ifIXaantsr6detail13is_basic_jsonIT0_EE5valuesr6detail18is_compatible_typeISD_SK_EE5valueEiE4typeELi0EEEOT_ loc_A9567: lea rdi, [rsp+128h+var_98] mov rsi, rbp 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, r15 call _ZNSt6vectorI16common_tool_callSaIS0_EE12emplace_backIJS0_EEERS0_DpOT_; std::vector<common_tool_call>::emplace_back<common_tool_call>(common_tool_call &&) mov rdi, r15; this call _ZN16common_tool_callD2Ev; common_tool_call::~common_tool_call() mov rdi, rbp 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 rax, [rsp+128h+var_108] movzx eax, byte ptr [rax] cmp eax, 2 jz short loc_A95AF cmp eax, 1 jnz short loc_A95BA add [rsp+128h+var_100], 30h ; '0' jmp loc_A94AC loc_A95AF: add [rsp+128h+var_F8], 10h jmp loc_A94AC loc_A95BA: inc [rsp+128h+var_F0] jmp loc_A94AC loc_A95C4: lea rdi, [rsp+128h+var_118] call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE4dataD2Ev; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::data::~data() mov r14, [rsp+128h+var_120] jmp short loc_A95E6 loc_A95D5: mov r14, [rsp+128h+var_120] lea rdi, [r14+20h] mov rsi, rbx call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9_M_assignERKS4_; std::string::_M_assign(std::string const&) loc_A95E6: mov rax, r14 add rsp, 0F8h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn jmp short loc_A961D mov rbx, rax lea rdi, [rsp+arg_A8]; this call _ZNSt14_Function_baseD2Ev; std::_Function_base::~_Function_base() lea rdi, [rsp+arg_48]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() jmp short loc_A9675 jmp short loc_A961D jmp short $+2 loc_A961D: mov rbx, rax jmp short loc_A9675 mov rbx, rax lea rdi, [rsp+arg_48]; this call _ZN16common_tool_callD2Ev; common_tool_call::~common_tool_call() xor ebp, ebp jmp short loc_A9639 mov rbx, rax mov bpl, 1 loc_A9639: lea rdi, [rsp+arg_38] 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() test bpl, bpl jnz short loc_A9652 jmp short loc_A966B mov rbx, rax jmp short loc_A965C mov rbx, rax loc_A9652: lea rdi, [rsp+arg_68]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() loc_A965C: lea rdi, [rsp+arg_48]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() jmp short loc_A966B mov rbx, rax loc_A966B: lea rdi, [rsp+arg_8] 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_A9675: mov rdi, [rsp+arg_0]; this call _ZN15common_chat_msgD2Ev; common_chat_msg::~common_chat_msg() mov rdi, rbx call __Unwind_Resume
common_chat_msg * parse_prefixed_json_tool_call_array( common_chat_msg *this, long long a2, long long a3, long long a4) { long long v6; // r14 long long v7; // r12 long long v8; // r13 _BYTE *v9; // r14 long long v10; // rax unsigned __int8 *v11; // rax int v12; // eax common_chat_msg *v13; // r14 _BYTE v15[16]; // [rsp+10h] [rbp-118h] BYREF unsigned __int8 *v16; // [rsp+20h] [rbp-108h] BYREF long long v17; // [rsp+28h] [rbp-100h] long long v18; // [rsp+30h] [rbp-F8h] long long v19; // [rsp+38h] [rbp-F0h] unsigned __int8 v20[16]; // [rsp+40h] [rbp-E8h] BYREF long long v21[4]; // [rsp+50h] [rbp-D8h] BYREF _BYTE v22[32]; // [rsp+70h] [rbp-B8h] BYREF _BYTE v23[32]; // [rsp+90h] [rbp-98h] BYREF _BYTE v24[40]; // [rsp+B0h] [rbp-78h] BYREF _BYTE v25[80]; // [rsp+D8h] [rbp-50h] BYREF v6 = std::string::find(a2, a3, 0LL); common_chat_msg::common_chat_msg(this); std::string::assign(this, "assistant"); if ( v6 == -1 ) { v13 = this; std::string::_M_assign((char *)this + 32, a2); } else { v7 = *(_QWORD *)(a3 + 8); std::string::substr(v21, a2, 0LL, v6); std::string::operator=((char *)this + 32, v21); std::string::~string(v21); std::string::substr(v21, a2, v7 + v6 - a4, -1LL); memset(v24, 0, 32); 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>::parse<std::string>( v15, v21, (long long)v24, 1u, 0); std::_Function_base::~_Function_base((std::_Function_base *)v24); std::string::~string(v21); 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>::cbegin( (long long)&v16, (long long)v15); nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::cend( (long long)v25, (long long)v15); while ( ZNK8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEneISH_TnNSt9enable_ifIXoosr3std7is_sameIT_SH_EE5valuesr3std7is_sameISK_NS2_ISF_EEEE5valueEDnE4typeELDn0EEEbRKSK_((long long)&v16) ) { v8 = 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,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void> const>::operator*(&v16); v9 = (_BYTE *)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>( v8, (long long)"arguments"); v10 = 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>( v8, (long long)"name"); 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)v21, v10); if ( *v9 == 3 ) 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)v22, (long long)v9); else 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)v22, (long long)v9, -1, 32, 0, 0); if ( ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE8containsIRA3_KcTnNSt9enable_ifIXsr6detail32is_usable_as_basic_json_key_typeISD_T_EE5valueEiE4typeELi0EEEbOSJ_(v8) ) { v11 = (unsigned __int8 *)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>( v8, (long long)"id"); 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( v20, v11); } else { ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEC2IRA1_KcA1_cTnNSt9enable_ifIXaantsr6detail13is_basic_jsonIT0_EE5valuesr6detail18is_compatible_typeISD_SK_EE5valueEiE4typeELi0EEEOT_((char *)v20); } 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)v23, (long long)v20); std::vector<common_tool_call>::emplace_back<common_tool_call>((char *)this + 64, v21); common_tool_call::~common_tool_call((common_tool_call *)v21); 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(v20); v12 = *v16; if ( v12 == 2 ) { v18 += 16LL; } else if ( v12 == 1 ) { v17 += 48LL; } else { ++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>::data::~data(v15); return this; } return v13; }
parse_prefixed_json_tool_call_array: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0xf8 MOV R15,RCX MOV R12,RDX MOV RBX,RSI MOV R13,RDI MOV RDI,RSI MOV RSI,RDX XOR EDX,EDX CALL 0x00125190 MOV R14,RAX MOV RDI,R13 CALL 0x001ab668 LAB_001a93cc: LEA RSI,[0x1b5203] MOV qword ptr [RSP + 0x8],R13 MOV RDI,R13 CALL 0x00125100 CMP R14,-0x1 JZ 0x001a95d5 MOV R12,qword ptr [R12 + 0x8] LAB_001a93ef: LEA RDI,[RSP + 0x50] MOV RSI,RBX XOR EDX,EDX MOV RCX,R14 CALL 0x00124920 SUB R14,R15 ADD R14,R12 MOV RAX,qword ptr [RSP + 0x8] LEA RDI,[RAX + 0x20] LEA R15,[RSP + 0x50] MOV RSI,R15 CALL 0x00124aa0 MOV RDI,R15 CALL 0x001251d8 LAB_001a9425: LEA RDI,[RSP + 0x50] PUSH -0x1 POP RCX MOV RSI,RBX MOV RDX,R14 CALL 0x00124920 XORPS XMM0,XMM0 LEA RDX,[RSP + 0xb0] MOVAPS xmmword ptr [RDX + 0x10],XMM0 MOVAPS xmmword ptr [RDX],XMM0 LAB_001a944a: LEA RDI,[RSP + 0x10] LEA RSI,[RSP + 0x50] PUSH 0x1 POP RCX XOR R8D,R8D CALL 0x0017b4d2 LEA RDI,[RSP + 0xb0] CALL 0x00148930 LEA R15,[RSP + 0x50] MOV RDI,R15 CALL 0x001251d8 LEA R12,[RSP + 0x20] LEA RBX,[RSP + 0x10] MOV RDI,R12 MOV RSI,RBX CALL 0x00168960 LEA RDI,[RSP + 0xd8] MOV RSI,RBX CALL 0x00168bcc MOV RAX,qword ptr [RSP + 0x8] LEA RBX,[RAX + 0x40] LEA RBP,[RSP + 0x40] LAB_001a94ac: MOV RDI,R12 LEA RSI,[RSP + 0xd8] CALL 0x00168404 TEST AL,AL JZ 0x001a95c4 MOV RDI,R12 CALL 0x001685fe MOV R13,RAX MOV RDI,RAX LEA RSI,[0x1b65b8] CALL 0x0017bb0c MOV R14,RAX MOV RDI,R13 LEA RSI,[0x1b6b54] CALL 0x0017bb0c MOV RDI,R15 MOV RSI,RAX CALL 0x00164862 CMP byte ptr [R14],0x3 JNZ 0x001a9510 LAB_001a9501: LEA RDI,[RSP + 0x70] MOV RSI,R14 CALL 0x00164862 JMP 0x001a9529 LAB_001a9510: LEA RDI,[RSP + 0x70] MOV RSI,R14 PUSH -0x1 POP RDX PUSH 0x20 POP RCX XOR R8D,R8D XOR R9D,R9D CALL 0x0015dd7c LAB_001a9529: MOV RDI,R13 LEA RSI,[0x1b5662] CALL 0x0017baea TEST AL,AL JZ 0x001a9558 MOV RDI,R13 LEA RSI,[0x1b5662] CALL 0x0017bb0c MOV RDI,RBP MOV RSI,RAX CALL 0x00142c42 JMP 0x001a9567 LAB_001a9558: MOV RDI,RBP LEA RSI,[0x1b192f] CALL 0x00189196 LAB_001a9567: LEA RDI,[RSP + 0x90] MOV RSI,RBP CALL 0x00164862 LAB_001a9577: MOV RDI,RBX MOV RSI,R15 CALL 0x001ab6ec MOV RDI,R15 CALL 0x0018b15a MOV RDI,RBP CALL 0x001430a6 MOV RAX,qword ptr [RSP + 0x20] MOVZX EAX,byte ptr [RAX] CMP EAX,0x2 JZ 0x001a95af CMP EAX,0x1 JNZ 0x001a95ba ADD qword ptr [RSP + 0x28],0x30 JMP 0x001a94ac LAB_001a95af: ADD qword ptr [RSP + 0x30],0x10 JMP 0x001a94ac LAB_001a95ba: INC qword ptr [RSP + 0x38] JMP 0x001a94ac LAB_001a95c4: LEA RDI,[RSP + 0x10] CALL 0x001430a6 MOV R14,qword ptr [RSP + 0x8] JMP 0x001a95e6 LAB_001a95d5: MOV R14,qword ptr [RSP + 0x8] LEA RDI,[R14 + 0x20] LAB_001a95de: MOV RSI,RBX CALL 0x001244c0 LAB_001a95e6: MOV RAX,R14 ADD RSP,0xf8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
/* parse_prefixed_json_tool_call_array(std::__cxx11::string const&, std::__cxx11::string const&, unsigned long) */ string * parse_prefixed_json_tool_call_array(string *param_1,string *param_2,ulong param_3) { char cVar1; long lVar2; basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> *this; char *pcVar3; basic_json *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> local_118 [16]; char *local_108; long local_100; long local_f8; long local_f0; basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,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 [16]; string local_d8 [32]; int1 local_b8 [32]; int1 local_98 [32]; int8 local_78; int8 uStack_70; int8 local_68; int8 uStack_60; int1 local_50 [32]; lVar2 = std::__cxx11::string::find(param_2,param_3); common_chat_msg::common_chat_msg((common_chat_msg *)param_1); /* try { // try from 001a93cc to 001a93df has its CatchHandler @ 001a961d */ std::__cxx11::string::assign((char *)param_1); if (lVar2 == -1) { /* try { // try from 001a95de to 001a95e5 has its CatchHandler @ 001a95fb */ std::__cxx11::string::_M_assign(param_1 + 0x20); } else { /* try { // try from 001a93ef to 001a9400 has its CatchHandler @ 001a961b */ std::__cxx11::string::substr((ulong)local_d8,(ulong)param_2); std::__cxx11::string::operator=(param_1 + 0x20,local_d8); std::__cxx11::string::~string(local_d8); /* try { // try from 001a9425 to 001a9437 has its CatchHandler @ 001a9619 */ std::__cxx11::string::substr((ulong)local_d8,(ulong)param_2); local_68 = 0; uStack_60 = 0; local_78 = 0; uStack_70 = 0; /* try { // try from 001a944a to 001a945e has its CatchHandler @ 001a95fd */ 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> ::parse<std::__cxx11::string>(local_118,local_d8,&local_78,1,0); std::_Function_base::~_Function_base((_Function_base *)&local_78); std::__cxx11::string::~string(local_d8); 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> ::cbegin(); 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> ::cend(); while( true ) { /* try { // try from 001a94ac to 001a94fa has its CatchHandler @ 001a9668 */ cVar1 = _ZNK8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEneISH_TnNSt9enable_ifIXoosr3std7is_sameIT_SH_EE5valuesr3std7is_sameISK_NS2_ISF_EEEE5valueEDnE4typeELDn0EEEbRKSK_ ((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> *)&local_108,local_50); if (cVar1 == '\0') break; 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> *)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> ::operator*((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> *)&local_108); pcVar3 = 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>(this,"arguments"); pbVar4 = 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>(this,"name"); _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_d8,pbVar4); if (*pcVar3 == '\x03') { /* try { // try from 001a9501 to 001a9528 has its CatchHandler @ 001a964a */ _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_b8,pcVar3); } else { 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_b8,pcVar3,0xffffffffffffffff,0x20,0,0); } /* try { // try from 001a9529 to 001a9566 has its CatchHandler @ 001a964f */ cVar1 = _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE8containsIRA3_KcTnNSt9enable_ifIXsr6detail32is_usable_as_basic_json_key_typeISD_T_EE5valueEiE4typeELi0EEEbOSJ_ (this,"id"); if (cVar1 == '\0') { _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEC2IRA1_KcA1_cTnNSt9enable_ifIXaantsr6detail13is_basic_jsonIT0_EE5valuesr6detail18is_compatible_typeISD_SK_EE5valueEiE4typeELi0EEEOT_ (local_e8,""); } else { pbVar4 = 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>(this,"id"); 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(local_e8,pbVar4); } /* try { // try from 001a9567 to 001a9576 has its CatchHandler @ 001a9633 */ _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_98,local_e8); /* try { // try from 001a9577 to 001a9581 has its CatchHandler @ 001a9622 */ std::vector<common_tool_call,std::allocator<common_tool_call>>::emplace_back<common_tool_call> ((vector<common_tool_call,std::allocator<common_tool_call>> *)(param_1 + 0x40), (common_tool_call *)local_d8); common_tool_call::~common_tool_call((common_tool_call *)local_d8); 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_e8); if (*local_108 == '\x02') { local_f8 = local_f8 + 0x10; } else if (*local_108 == '\x01') { local_100 = local_100 + 0x30; } else { local_f0 = local_f0 + 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> ::data::~data((data *)local_118); } return param_1; }
27,574
skip_spaces
bluesky950520[P]quickjs/quickjs.c
static int skip_spaces(const char *pc) { const uint8_t *p, *p_next, *p_start; uint32_t c; p = p_start = (const uint8_t *)pc; for (;;) { c = *p++; if (c < 0x80) { if (!((c >= 0x09 && c <= 0x0d) || (c == 0x20))) break; } else { c = utf8_decode(p - 1, &p_next); /* no need to test for invalid UTF-8, 0xFFFD is not a space */ if (!lre_is_space(c)) break; p = p_next; } } return p - 1 - p_start; }
O2
c
skip_spaces: pushq %r15 pushq %r14 pushq %r12 pushq %rbx pushq %rax movq %rdi, %rbx movabsq $0x100003e00, %r12 # imm = 0x100003E00 movq %rsp, %r14 movq %rdi, %rax movq %rax, %r15 movzbl (%rax), %ecx testb %cl, %cl js 0x37257 cmpl $0x20, %ecx ja 0x37273 leaq 0x1(%r15), %rax movl %ecx, %ecx btq %rcx, %r12 jb 0x3723a jmp 0x37273 movq %r15, %rdi movq %r14, %rsi callq 0x15f80 movl %eax, %edi callq 0x7b908 testl %eax, %eax je 0x37273 movq (%rsp), %rax jmp 0x3723a subl %ebx, %r15d movl %r15d, %eax addq $0x8, %rsp popq %rbx popq %r12 popq %r14 popq %r15 retq
skip_spaces: push r15 push r14 push r12 push rbx push rax mov rbx, rdi mov r12, 100003E00h mov r14, rsp mov rax, rdi loc_3723A: mov r15, rax movzx ecx, byte ptr [rax] test cl, cl js short loc_37257 cmp ecx, 20h ; ' ' ja short loc_37273 lea rax, [r15+1] mov ecx, ecx bt r12, rcx jb short loc_3723A jmp short loc_37273 loc_37257: mov rdi, r15 mov rsi, r14 call utf8_decode mov edi, eax call lre_is_space test eax, eax jz short loc_37273 mov rax, [rsp+28h+var_28] jmp short loc_3723A loc_37273: sub r15d, ebx mov eax, r15d add rsp, 8 pop rbx pop r12 pop r14 pop r15 retn
long long skip_spaces(char *a1) { char *v1; // rax long long v2; // r12 char *v3; // rax int v4; // r15d unsigned int v5; // ecx unsigned int v6; // eax char *v8; // [rsp+0h] [rbp-28h] BYREF v8 = v1; v2 = 0x100003E00LL; v3 = a1; do { while ( 1 ) { v4 = (int)v3; v5 = (unsigned __int8)*v3; if ( (v5 & 0x80u) == 0 ) break; v6 = utf8_decode(v3, &v8); if ( !(unsigned int)lre_is_space(v6) ) return (unsigned int)(v4 - (_DWORD)a1); v3 = v8; } if ( v5 > 0x20 ) break; ++v3; } while ( _bittest64(&v2, v5) ); return (unsigned int)(v4 - (_DWORD)a1); }
skip_spaces: PUSH R15 PUSH R14 PUSH R12 PUSH RBX PUSH RAX MOV RBX,RDI MOV R12,0x100003e00 MOV R14,RSP MOV RAX,RDI LAB_0013723a: MOV R15,RAX MOVZX ECX,byte ptr [RAX] TEST CL,CL JS 0x00137257 CMP ECX,0x20 JA 0x00137273 LEA RAX,[R15 + 0x1] MOV ECX,ECX BT R12,RCX JC 0x0013723a JMP 0x00137273 LAB_00137257: MOV RDI,R15 MOV RSI,R14 CALL 0x00115f80 MOV EDI,EAX CALL 0x0017b908 TEST EAX,EAX JZ 0x00137273 MOV RAX,qword ptr [RSP] JMP 0x0013723a LAB_00137273: SUB R15D,EBX MOV EAX,R15D ADD RSP,0x8 POP RBX POP R12 POP R14 POP R15 RET
int skip_spaces(byte *param_1) { byte bVar1; byte *pbVar2; int4 uVar3; int iVar4; byte *in_RAX; byte *pbVar5; byte *local_28; pbVar2 = param_1; local_28 = in_RAX; do { while (pbVar5 = pbVar2, bVar1 = *pbVar5, -1 < (char)bVar1) { if ((0x20 < bVar1) || (pbVar2 = pbVar5 + 1, (0x100003e00U >> ((ulong)(uint)bVar1 & 0x3f) & 1) == 0)) goto LAB_00137273; } uVar3 = utf8_decode(pbVar5,&local_28); iVar4 = lre_is_space(uVar3); pbVar2 = local_28; } while (iVar4 != 0); LAB_00137273: return (int)pbVar5 - (int)param_1; }
27,575
skip_spaces
bluesky950520[P]quickjs/quickjs.c
static int skip_spaces(const char *pc) { const uint8_t *p, *p_next, *p_start; uint32_t c; p = p_start = (const uint8_t *)pc; for (;;) { c = *p++; if (c < 0x80) { if (!((c >= 0x09 && c <= 0x0d) || (c == 0x20))) break; } else { c = utf8_decode(p - 1, &p_next); /* no need to test for invalid UTF-8, 0xFFFD is not a space */ if (!lre_is_space(c)) break; p = p_next; } } return p - 1 - p_start; }
O3
c
skip_spaces: pushq %r15 pushq %r14 pushq %rbx subq $0x10, %rsp movq %rdi, %rbx leaq 0x8(%rsp), %r14 movq %rdi, %rax movq %rax, %r15 movzbl (%rax), %ecx testb %cl, %cl js 0x405cc leaq 0x1(%r15), %rax leal -0x9(%rcx), %edx cmpl $0x5, %edx jb 0x405af cmpl $0x20, %ecx je 0x405af jmp 0x405e9 movq %r15, %rdi movq %r14, %rsi callq 0x1c05a movl %eax, %edi callq 0x9704c testl %eax, %eax je 0x405e9 movq 0x8(%rsp), %rax jmp 0x405af subl %ebx, %r15d movl %r15d, %eax addq $0x10, %rsp popq %rbx popq %r14 popq %r15 retq
skip_spaces: push r15 push r14 push rbx sub rsp, 10h mov rbx, rdi lea r14, [rsp+28h+var_20] mov rax, rdi loc_405AF: mov r15, rax movzx ecx, byte ptr [rax] test cl, cl js short loc_405CC lea rax, [r15+1] lea edx, [rcx-9] cmp edx, 5 jb short loc_405AF cmp ecx, 20h ; ' ' jz short loc_405AF jmp short loc_405E9 loc_405CC: mov rdi, r15 mov rsi, r14 call utf8_decode mov edi, eax call lre_is_space test eax, eax jz short loc_405E9 mov rax, [rsp+28h+var_20] jmp short loc_405AF loc_405E9: sub r15d, ebx mov eax, r15d add rsp, 10h pop rbx pop r14 pop r15 retn
long long skip_spaces(char *a1) { char *v1; // rax int v2; // r15d int v3; // ecx unsigned int v4; // eax char *v6; // [rsp+8h] [rbp-20h] BYREF v1 = a1; do { while ( 1 ) { v2 = (int)v1; v3 = (unsigned __int8)*v1; if ( (v3 & 0x80u) == 0 ) break; v4 = utf8_decode(v1, &v6); if ( !(unsigned int)lre_is_space(v4) ) return (unsigned int)(v2 - (_DWORD)a1); v1 = v6; } ++v1; } while ( (unsigned int)(v3 - 9) < 5 || v3 == 32 ); return (unsigned int)(v2 - (_DWORD)a1); }
skip_spaces: PUSH R15 PUSH R14 PUSH RBX SUB RSP,0x10 MOV RBX,RDI LEA R14,[RSP + 0x8] MOV RAX,RDI LAB_001405af: MOV R15,RAX MOVZX ECX,byte ptr [RAX] TEST CL,CL JS 0x001405cc LEA RAX,[R15 + 0x1] LEA EDX,[RCX + -0x9] CMP EDX,0x5 JC 0x001405af CMP ECX,0x20 JZ 0x001405af JMP 0x001405e9 LAB_001405cc: MOV RDI,R15 MOV RSI,R14 CALL 0x0011c05a MOV EDI,EAX CALL 0x0019704c TEST EAX,EAX JZ 0x001405e9 MOV RAX,qword ptr [RSP + 0x8] JMP 0x001405af LAB_001405e9: SUB R15D,EBX MOV EAX,R15D ADD RSP,0x10 POP RBX POP R14 POP R15 RET
int skip_spaces(byte *param_1) { byte bVar1; byte *pbVar2; int4 uVar3; int iVar4; byte *pbVar5; byte *local_20; pbVar2 = param_1; do { while (pbVar5 = pbVar2, bVar1 = *pbVar5, (char)bVar1 < '\0') { uVar3 = utf8_decode(pbVar5,&local_20); iVar4 = lre_is_space(uVar3); pbVar2 = local_20; if (iVar4 == 0) goto LAB_001405e9; } pbVar2 = pbVar5 + 1; } while ((bVar1 - 9 < 5) || (bVar1 == 0x20)); LAB_001405e9: return (int)pbVar5 - (int)param_1; }
27,576
ssz_add_builders
corpus-core[P]colibri-stateless/src/util/ssz_builder.c
void ssz_add_builders(ssz_builder_t* buffer, const char* name, ssz_builder_t data) { const ssz_def_t* def = find_def(buffer->def, name); if (def && def->type == SSZ_TYPE_UNION) { bool found = false; for (int i = 0; i < def->def.container.len; i++) { if (def->def.container.elements + i == data.def || (data.def->type == SSZ_TYPE_CONTAINER && def->def.container.elements[i].def.container.elements == data.def->def.container.elements)) { uint8_t selector = i; found = true; buffer_splice(&data.fixed, 0, 0, bytes(&selector, 1)); break; } } if (!found) { log_error("ssz_add_builders: Uniontype %s not found in %s.%s\n", data.def->name, buffer->def->name, name); return; } } ssz_ob_t element = ssz_builder_to_bytes(&data); ssz_add_bytes(buffer, name, element.bytes); safe_free(element.bytes.data); }
O0
c
ssz_add_builders: pushq %rbp movq %rsp, %rbp subq $0x70, %rsp leaq 0x10(%rbp), %rax movq %rax, -0x70(%rbp) movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq -0x8(%rbp), %rax movq (%rax), %rdi movq -0x10(%rbp), %rsi callq 0xa2480 movq %rax, -0x18(%rbp) cmpq $0x0, -0x18(%rbp) je 0xa2443 movq -0x18(%rbp), %rax cmpl $0x7, 0x8(%rax) jne 0xa2443 movb $0x0, -0x19(%rbp) movl $0x0, -0x20(%rbp) movl -0x20(%rbp), %eax movq -0x18(%rbp), %rcx cmpl 0x18(%rcx), %eax jae 0xa23b2 movq -0x70(%rbp), %rcx movq -0x18(%rbp), %rax movq 0x10(%rax), %rax movslq -0x20(%rbp), %rdx shlq $0x5, %rdx addq %rdx, %rax cmpq (%rcx), %rax je 0xa236d movq -0x70(%rbp), %rax movq (%rax), %rax cmpl $0x2, 0x8(%rax) jne 0xa23a2 movq -0x70(%rbp), %rcx movq -0x18(%rbp), %rax movq 0x10(%rax), %rax movslq -0x20(%rbp), %rdx shlq $0x5, %rdx addq %rdx, %rax movq 0x10(%rax), %rax movq (%rcx), %rcx cmpq 0x10(%rcx), %rax jne 0xa23a2 movq -0x70(%rbp), %rdi movl -0x20(%rbp), %eax movb %al, -0x21(%rbp) movb $0x1, -0x19(%rbp) addq $0x8, %rdi movl $0x1, -0x38(%rbp) leaq -0x21(%rbp), %rax movq %rax, -0x30(%rbp) movl -0x38(%rbp), %ecx movq -0x30(%rbp), %r8 xorl %eax, %eax movl %eax, %esi xorl %edx, %edx callq 0x9cb00 jmp 0xa23b2 jmp 0xa23a4 movl -0x20(%rbp), %eax addl $0x1, %eax movl %eax, -0x20(%rbp) jmp 0xa2310 testb $0x1, -0x19(%rbp) jne 0xa2441 jmp 0xa23be movb $0x0, %al callq 0xa5f40 cmpl $0x1, %eax jb 0xa243d leaq -0x50(%rbp), %rdi xorl %esi, %esi movl $0x18, %edx callq 0x23140 movq -0x70(%rbp), %rax movq (%rax), %rax movq (%rax), %rdx movq -0x8(%rbp), %rax movq (%rax), %rax movq (%rax), %rcx movq -0x10(%rbp), %r8 leaq -0x50(%rbp), %rdi leaq 0x433bf(%rip), %rsi # 0xe57bc movb $0x0, %al callq 0x9d5a0 movq 0x94ba5(%rip), %rax # 0x136fb0 movq (%rax), %rdi movq -0x48(%rbp), %r9 leaq 0x432d3(%rip), %rsi # 0xe56ec leaq 0x432e6(%rip), %rdx # 0xe5706 leaq 0x433c8(%rip), %rcx # 0xe57ef movl $0x2d, %r8d movb $0x0, %al callq 0x23350 leaq -0x50(%rbp), %rdi callq 0x9cbf0 jmp 0xa243f jmp 0xa246d jmp 0xa2443 movq -0x70(%rbp), %rsi leaq -0x68(%rbp), %rdi callq 0xa2520 movq -0x8(%rbp), %rdi movq -0x10(%rbp), %rsi movl -0x68(%rbp), %edx movq -0x60(%rbp), %rcx callq 0xa2590 movq -0x60(%rbp), %rdi callq 0x9c5a0 addq $0x70, %rsp popq %rbp retq nopw %cs:(%rax,%rax)
ssz_add_builders: push rbp mov rbp, rsp sub rsp, 70h lea rax, [rbp+arg_0] mov [rbp+var_70], rax mov [rbp+var_8], rdi mov [rbp+var_10], rsi mov rax, [rbp+var_8] mov rdi, [rax] mov rsi, [rbp+var_10] call find_def mov [rbp+var_18], rax cmp [rbp+var_18], 0 jz loc_A2443 mov rax, [rbp+var_18] cmp dword ptr [rax+8], 7 jnz loc_A2443 mov [rbp+var_19], 0 mov [rbp+var_20], 0 loc_A2310: mov eax, [rbp+var_20] mov rcx, [rbp+var_18] cmp eax, [rcx+18h] jnb loc_A23B2 mov rcx, [rbp+var_70] mov rax, [rbp+var_18] mov rax, [rax+10h] movsxd rdx, [rbp+var_20] shl rdx, 5 add rax, rdx cmp rax, [rcx] jz short loc_A236D mov rax, [rbp+var_70] mov rax, [rax] cmp dword ptr [rax+8], 2 jnz short loc_A23A2 mov rcx, [rbp+var_70] mov rax, [rbp+var_18] mov rax, [rax+10h] movsxd rdx, [rbp+var_20] shl rdx, 5 add rax, rdx mov rax, [rax+10h] mov rcx, [rcx] cmp rax, [rcx+10h] jnz short loc_A23A2 loc_A236D: mov rdi, [rbp+var_70] mov eax, [rbp+var_20] mov [rbp+var_21], al mov [rbp+var_19], 1 add rdi, 8 mov [rbp+var_38], 1 lea rax, [rbp+var_21] mov [rbp+var_30], rax mov ecx, [rbp+var_38] mov r8, [rbp+var_30] xor eax, eax mov esi, eax xor edx, edx call buffer_splice jmp short loc_A23B2 loc_A23A2: jmp short $+2 loc_A23A4: mov eax, [rbp+var_20] add eax, 1 mov [rbp+var_20], eax jmp loc_A2310 loc_A23B2: test [rbp+var_19], 1 jnz loc_A2441 jmp short $+2 loc_A23BE: mov al, 0 call c4_get_log_level cmp eax, 1 jb short loc_A243D lea rdi, [rbp+var_50] xor esi, esi mov edx, 18h call _memset mov rax, [rbp+var_70] mov rax, [rax] mov rdx, [rax] mov rax, [rbp+var_8] mov rax, [rax] mov rcx, [rax] mov r8, [rbp+var_10] lea rdi, [rbp+var_50] lea rsi, aSszAddBuilders; "ssz_add_builders: Uniontype %s not foun"... mov al, 0 call bprintf mov rax, cs:stderr_ptr mov rdi, [rax] mov r9, [rbp+var_48] lea rsi, aS0m32mSD0mS; "%s\x1B[0m\x1B[32m %s:%d\x1B[0m %s\n" lea rdx, a31merror; "\x1B[31mERROR" lea rcx, aSszAddBuilders_0; "ssz_add_builders" mov r8d, 2Dh ; '-' mov al, 0 call _fprintf lea rdi, [rbp+var_50] call buffer_free loc_A243D: jmp short $+2 loc_A243F: jmp short loc_A246D loc_A2441: jmp short $+2 loc_A2443: mov rsi, [rbp+var_70] lea rdi, [rbp+var_68] call ssz_builder_to_bytes mov rdi, [rbp+var_8] mov rsi, [rbp+var_10] mov edx, [rbp+var_68] mov rcx, [rbp+var_60] call ssz_add_bytes mov rdi, [rbp+var_60] call safe_free loc_A246D: add rsp, 70h pop rbp retn
long long ssz_add_builders( long long **a1, long long a2, _DWORD a3, _DWORD a4, _DWORD a5, _DWORD a6, __m128 a7, __m128 a8, __m128 a9, __m128 a10, double a11, double a12, __m128 a13, __m128 a14, long long a15, long long a16) { long long result; // rax long long v17; // r9 __m128 v18; // xmm4 __m128 v19; // xmm5 unsigned int v20; // [rsp+8h] [rbp-68h] BYREF long long v21; // [rsp+10h] [rbp-60h] unsigned int v22; // [rsp+20h] [rbp-50h] BYREF const char *v23; // [rsp+28h] [rbp-48h] int v24; // [rsp+38h] [rbp-38h] char *v25; // [rsp+40h] [rbp-30h] char v26; // [rsp+4Fh] [rbp-21h] BYREF unsigned int i; // [rsp+50h] [rbp-20h] char v28; // [rsp+57h] [rbp-19h] long long def; // [rsp+58h] [rbp-18h] long long v30; // [rsp+60h] [rbp-10h] long long **v31; // [rsp+68h] [rbp-8h] v31 = a1; v30 = a2; def = find_def(*a1, a2); if ( !def || *(_DWORD *)(def + 8) != 7 ) goto LABEL_14; v28 = 0; for ( i = 0; i < *(_DWORD *)(def + 24); ++i ) { if ( 32LL * (int)i + *(_QWORD *)(def + 16) == a15 || *(_DWORD *)(a15 + 8) == 2 && *(_QWORD *)(32LL * (int)i + *(_QWORD *)(def + 16) + 16) == *(_QWORD *)(a15 + 16) ) { v26 = i; v28 = 1; v24 = 1; v25 = &v26; buffer_splice((unsigned long long)&a16, 0LL, 0, 1u, (long long)&v26); break; } } if ( (v28 & 1) == 0 ) { result = c4_get_log_level(); if ( (_DWORD)result ) { memset(&v22, 0LL, 24LL); bprintf( &v22, (long long)"ssz_add_builders: Uniontype %s not found in %s.%s\n", *(_QWORD *)a15, **v31, v30, v17, a7, a8, a9, a10, v18, v19, a13, a14, (char)&a15); fprintf(stderr, "%s\x1B[0m\x1B[32m %s:%d\x1B[0m %s\n", "\x1B[31mERROR", "ssz_add_builders", 45, v23); return buffer_free((long long)&v22); } } else { LABEL_14: ssz_builder_to_bytes(&v20, &a15); ssz_add_bytes(v31, v30, v20, v21); return safe_free(v21); } return result; }
ssz_add_builders: PUSH RBP MOV RBP,RSP SUB RSP,0x70 LEA RAX,[RBP + 0x10] MOV qword ptr [RBP + -0x70],RAX MOV qword ptr [RBP + -0x8],RDI MOV qword ptr [RBP + -0x10],RSI MOV RAX,qword ptr [RBP + -0x8] MOV RDI,qword ptr [RAX] MOV RSI,qword ptr [RBP + -0x10] CALL 0x001a2480 MOV qword ptr [RBP + -0x18],RAX CMP qword ptr [RBP + -0x18],0x0 JZ 0x001a2443 MOV RAX,qword ptr [RBP + -0x18] CMP dword ptr [RAX + 0x8],0x7 JNZ 0x001a2443 MOV byte ptr [RBP + -0x19],0x0 MOV dword ptr [RBP + -0x20],0x0 LAB_001a2310: MOV EAX,dword ptr [RBP + -0x20] MOV RCX,qword ptr [RBP + -0x18] CMP EAX,dword ptr [RCX + 0x18] JNC 0x001a23b2 MOV RCX,qword ptr [RBP + -0x70] MOV RAX,qword ptr [RBP + -0x18] MOV RAX,qword ptr [RAX + 0x10] MOVSXD RDX,dword ptr [RBP + -0x20] SHL RDX,0x5 ADD RAX,RDX CMP RAX,qword ptr [RCX] JZ 0x001a236d MOV RAX,qword ptr [RBP + -0x70] MOV RAX,qword ptr [RAX] CMP dword ptr [RAX + 0x8],0x2 JNZ 0x001a23a2 MOV RCX,qword ptr [RBP + -0x70] MOV RAX,qword ptr [RBP + -0x18] MOV RAX,qword ptr [RAX + 0x10] MOVSXD RDX,dword ptr [RBP + -0x20] SHL RDX,0x5 ADD RAX,RDX MOV RAX,qword ptr [RAX + 0x10] MOV RCX,qword ptr [RCX] CMP RAX,qword ptr [RCX + 0x10] JNZ 0x001a23a2 LAB_001a236d: MOV RDI,qword ptr [RBP + -0x70] MOV EAX,dword ptr [RBP + -0x20] MOV byte ptr [RBP + -0x21],AL MOV byte ptr [RBP + -0x19],0x1 ADD RDI,0x8 MOV dword ptr [RBP + -0x38],0x1 LEA RAX,[RBP + -0x21] MOV qword ptr [RBP + -0x30],RAX MOV ECX,dword ptr [RBP + -0x38] MOV R8,qword ptr [RBP + -0x30] XOR EAX,EAX MOV ESI,EAX XOR EDX,EDX CALL 0x0019cb00 JMP 0x001a23b2 LAB_001a23a2: JMP 0x001a23a4 LAB_001a23a4: MOV EAX,dword ptr [RBP + -0x20] ADD EAX,0x1 MOV dword ptr [RBP + -0x20],EAX JMP 0x001a2310 LAB_001a23b2: TEST byte ptr [RBP + -0x19],0x1 JNZ 0x001a2441 JMP 0x001a23be LAB_001a23be: MOV AL,0x0 CALL 0x001a5f40 CMP EAX,0x1 JC 0x001a243d LEA RDI,[RBP + -0x50] XOR ESI,ESI MOV EDX,0x18 CALL 0x00123140 MOV RAX,qword ptr [RBP + -0x70] MOV RAX,qword ptr [RAX] MOV RDX,qword ptr [RAX] MOV RAX,qword ptr [RBP + -0x8] MOV RAX,qword ptr [RAX] MOV RCX,qword ptr [RAX] MOV R8,qword ptr [RBP + -0x10] LEA RDI,[RBP + -0x50] LEA RSI,[0x1e57bc] MOV AL,0x0 CALL 0x0019d5a0 MOV RAX,qword ptr [0x00236fb0] MOV RDI,qword ptr [RAX] MOV R9,qword ptr [RBP + -0x48] LEA RSI,[0x1e56ec] LEA RDX,[0x1e5706] LEA RCX,[0x1e57ef] MOV R8D,0x2d MOV AL,0x0 CALL 0x00123350 LEA RDI,[RBP + -0x50] CALL 0x0019cbf0 LAB_001a243d: JMP 0x001a243f LAB_001a243f: JMP 0x001a246d LAB_001a2441: JMP 0x001a2443 LAB_001a2443: MOV RSI,qword ptr [RBP + -0x70] LEA RDI,[RBP + -0x68] CALL 0x001a2520 MOV RDI,qword ptr [RBP + -0x8] MOV RSI,qword ptr [RBP + -0x10] MOV EDX,dword ptr [RBP + -0x68] MOV RCX,qword ptr [RBP + -0x60] CALL 0x001a2590 MOV RDI,qword ptr [RBP + -0x60] CALL 0x0019c5a0 LAB_001a246d: ADD RSP,0x70 POP RBP RET
void ssz_add_builders(int8 *param_1,int8 param_2) { int iVar1; int8 *in_stack_00000008; int4 local_70 [2]; int8 local_68; int1 local_58 [8]; int8 local_50; int4 local_40; int1 *local_38; int1 local_29; uint local_28; byte local_21; long local_20; int8 local_18; int8 *local_10; local_18 = param_2; local_10 = param_1; local_20 = find_def(*param_1); if ((local_20 != 0) && (*(int *)(local_20 + 8) == 7)) { local_21 = 0; for (local_28 = 0; local_28 < *(uint *)(local_20 + 0x18); local_28 = local_28 + 1) { if (((int8 *)(*(long *)(local_20 + 0x10) + (long)(int)local_28 * 0x20) == in_stack_00000008) || ((*(int *)(in_stack_00000008 + 1) == 2 && (*(long *)(*(long *)(local_20 + 0x10) + (long)(int)local_28 * 0x20 + 0x10) == in_stack_00000008[2])))) { local_29 = (int1)local_28; local_21 = 1; local_40 = 1; local_38 = &local_29; buffer_splice(&stack0x00000010,0,0,1,local_38); break; } } if ((local_21 & 1) == 0) { iVar1 = c4_get_log_level(); if (iVar1 == 0) { return; } memset(local_58,0,0x18); bprintf(local_58,"ssz_add_builders: Uniontype %s not found in %s.%s\n",*in_stack_00000008, *(int8 *)*local_10,local_18); fprintf(*(FILE **)PTR_stderr_00236fb0,"%s\x1b[0m\x1b[32m %s:%d\x1b[0m %s\n",&DAT_001e5706, "ssz_add_builders",0x2d,local_50); buffer_free(local_58); return; } } ssz_builder_to_bytes(local_70,&stack0x00000008); ssz_add_bytes(local_10,local_18,local_70[0],local_68); safe_free(local_68); return; }
27,577
ssz_add_builders
corpus-core[P]colibri-stateless/src/util/ssz_builder.c
void ssz_add_builders(ssz_builder_t* buffer, const char* name, ssz_builder_t data) { const ssz_def_t* def = find_def(buffer->def, name); if (def && def->type == SSZ_TYPE_UNION) { bool found = false; for (int i = 0; i < def->def.container.len; i++) { if (def->def.container.elements + i == data.def || (data.def->type == SSZ_TYPE_CONTAINER && def->def.container.elements[i].def.container.elements == data.def->def.container.elements)) { uint8_t selector = i; found = true; buffer_splice(&data.fixed, 0, 0, bytes(&selector, 1)); break; } } if (!found) { log_error("ssz_add_builders: Uniontype %s not found in %s.%s\n", data.def->name, buffer->def->name, name); return; } } ssz_ob_t element = ssz_builder_to_bytes(&data); ssz_add_bytes(buffer, name, element.bytes); safe_free(element.bytes.data); }
O3
c
ssz_add_builders: pushq %r15 pushq %r14 pushq %r12 pushq %rbx pushq %rax movq %rsi, %rbx movq %rdi, %r14 leaq 0x30(%rsp), %r15 movq (%rdi), %rdi callq 0x54423 testq %rax, %rax je 0x543dc cmpl $0x7, 0x8(%rax) jne 0x543dc movl 0x18(%rax), %ecx testq %rcx, %rcx je 0x543a7 movq 0x10(%rax), %rdx movq (%r15), %rsi xorl %eax, %eax cmpq %rsi, %rdx je 0x543c2 cmpl $0x2, 0x8(%rsi) jne 0x5439b movq 0x10(%rdx), %rdi cmpq 0x10(%rsi), %rdi je 0x543c2 incq %rax addq $0x20, %rdx cmpq %rax, %rcx jne 0x54386 xorl %eax, %eax callq 0x567a7 testl %eax, %eax je 0x54417 movq %r15, %rdi movq %r14, %rsi movq %rbx, %rdx callq 0x21f7d jmp 0x54417 leaq 0x7(%rsp), %r8 movb %al, (%r8) leaq 0x8(%r15), %rdi xorl %esi, %esi xorl %edx, %edx movl $0x1, %ecx callq 0x5103c leaq 0x8(%r15), %rdi leaq 0x20(%r15), %r12 movl 0x20(%r15), %esi movq 0x28(%r15), %rdx callq 0x50fdd movq %r12, %rdi callq 0x510bf movl 0x8(%r15), %edx movq 0x10(%r15), %r15 movq %r14, %rdi movq %rbx, %rsi movq %r15, %rcx callq 0x544a0 movq %r15, %rdi callq 0x50f4c addq $0x8, %rsp popq %rbx popq %r12 popq %r14 popq %r15 retq
ssz_add_builders: push r15 push r14 push r12 push rbx push rax mov rbx, rsi mov r14, rdi lea r15, [rsp+28h+arg_0] mov rdi, [rdi] call find_def test rax, rax jz short loc_543DC cmp dword ptr [rax+8], 7 jnz short loc_543DC mov ecx, [rax+18h] test rcx, rcx jz short loc_543A7 mov rdx, [rax+10h] mov rsi, [r15] xor eax, eax loc_54386: cmp rdx, rsi jz short loc_543C2 cmp dword ptr [rsi+8], 2 jnz short loc_5439B mov rdi, [rdx+10h] cmp rdi, [rsi+10h] jz short loc_543C2 loc_5439B: inc rax add rdx, 20h ; ' ' cmp rcx, rax jnz short loc_54386 loc_543A7: xor eax, eax call c4_get_log_level test eax, eax jz short loc_54417 mov rdi, r15 mov rsi, r14 mov rdx, rbx call ssz_add_builders_cold_1 jmp short loc_54417 loc_543C2: lea r8, [rsp+28h+var_21] mov [r8], al lea rdi, [r15+8] xor esi, esi xor edx, edx mov ecx, 1 call buffer_splice loc_543DC: lea rdi, [r15+8] lea r12, [r15+20h] mov esi, [r15+20h] mov rdx, [r15+28h] call buffer_append mov rdi, r12 call buffer_free mov edx, [r15+8] mov r15, [r15+10h] mov rdi, r14 mov rsi, rbx mov rcx, r15 call ssz_add_bytes mov rdi, r15 call safe_free loc_54417: add rsp, 8 pop rbx pop r12 pop r14 pop r15 retn
long long ssz_add_builders( _QWORD **a1, _QWORD *a2, _DWORD a3, _DWORD a4, _DWORD a5, _DWORD a6, _QWORD *a7, unsigned int a8, long long a9, long long a10, unsigned int a11, long long a12) { long long v12; // rax _QWORD *v13; // rbx _QWORD *v15; // rdi long long def; // rax _QWORD *v17; // rdx long long v18; // rcx long long v19; // rax long long result; // rax long long v21; // rcx long long v22; // r8 int v23; // r9d long long v24; // r15 _BYTE v25[33]; // [rsp+1h] [rbp-21h] BYREF v25[0] = HIBYTE(v12); v13 = a2; v15 = *a1; def = find_def(v15); if ( !def || *(_DWORD *)(def + 8) != 7 ) { LABEL_12: buffer_append(&a8, a11, a12); buffer_free((long long)&a11); v24 = a9; ssz_add_bytes(a1, v13, a8, a9); return safe_free(v24); } v18 = *(unsigned int *)(def + 24); if ( *(_DWORD *)(def + 24) ) { v17 = *(_QWORD **)(def + 16); a2 = a7; v19 = 0LL; while ( v17 != a7 ) { if ( *((_DWORD *)a7 + 2) == 2 ) { v15 = (_QWORD *)v17[2]; if ( v15 == (_QWORD *)a7[2] ) break; } ++v19; v17 += 4; if ( v18 == v19 ) goto LABEL_9; } v25[0] = v19; buffer_splice((long long)&a8, 0LL, 0, 1u, (long long)v25); goto LABEL_12; } LABEL_9: result = c4_get_log_level(v15, a2, v17); if ( (_DWORD)result ) return ssz_add_builders_cold_1(&a7, a1, (int)v13, v21, v22, v23); return result; }
ssz_add_builders: PUSH R15 PUSH R14 PUSH R12 PUSH RBX PUSH RAX MOV RBX,RSI MOV R14,RDI LEA R15,[RSP + 0x30] MOV RDI,qword ptr [RDI] CALL 0x00154423 TEST RAX,RAX JZ 0x001543dc CMP dword ptr [RAX + 0x8],0x7 JNZ 0x001543dc MOV ECX,dword ptr [RAX + 0x18] TEST RCX,RCX JZ 0x001543a7 MOV RDX,qword ptr [RAX + 0x10] MOV RSI,qword ptr [R15] XOR EAX,EAX LAB_00154386: CMP RDX,RSI JZ 0x001543c2 CMP dword ptr [RSI + 0x8],0x2 JNZ 0x0015439b MOV RDI,qword ptr [RDX + 0x10] CMP RDI,qword ptr [RSI + 0x10] JZ 0x001543c2 LAB_0015439b: INC RAX ADD RDX,0x20 CMP RCX,RAX JNZ 0x00154386 LAB_001543a7: XOR EAX,EAX CALL 0x001567a7 TEST EAX,EAX JZ 0x00154417 MOV RDI,R15 MOV RSI,R14 MOV RDX,RBX CALL 0x00121f7d JMP 0x00154417 LAB_001543c2: LEA R8,[RSP + 0x7] MOV byte ptr [R8],AL LEA RDI,[R15 + 0x8] XOR ESI,ESI XOR EDX,EDX MOV ECX,0x1 CALL 0x0015103c LAB_001543dc: LEA RDI,[R15 + 0x8] LEA R12,[R15 + 0x20] MOV ESI,dword ptr [R15 + 0x20] MOV RDX,qword ptr [R15 + 0x28] CALL 0x00150fdd MOV RDI,R12 CALL 0x001510bf MOV EDX,dword ptr [R15 + 0x8] MOV R15,qword ptr [R15 + 0x10] MOV RDI,R14 MOV RSI,RBX MOV RCX,R15 CALL 0x001544a0 MOV RDI,R15 CALL 0x00150f4c LAB_00154417: ADD RSP,0x8 POP RBX POP R12 POP R14 POP R15 RET
void ssz_add_builders(int8 *param_1,int8 param_2) { int8 uVar1; int iVar2; int8 in_RAX; long lVar3; ulong uVar4; long lVar5; int8 in_R9; long in_stack_00000008; int4 in_stack_00000010; int8 in_stack_00000018; int4 in_stack_00000028; int8 in_stack_00000030; lVar3 = find_def(*param_1); if ((lVar3 == 0) || (*(int *)(lVar3 + 8) != 7)) { LAB_001543dc: buffer_append(&stack0x00000010,in_stack_00000028,in_stack_00000030); buffer_free(&stack0x00000028); uVar1 = in_stack_00000018; ssz_add_bytes(param_1,param_2,in_stack_00000010,in_stack_00000018); safe_free(uVar1); } else { if ((ulong)*(uint *)(lVar3 + 0x18) != 0) { lVar5 = *(long *)(lVar3 + 0x10); uVar4 = 0; do { if ((lVar5 == in_stack_00000008) || ((*(int *)(in_stack_00000008 + 8) == 2 && (*(long *)(lVar5 + 0x10) == *(long *)(in_stack_00000008 + 0x10))))) { buffer_splice(&stack0x00000010,0,0,1,&stack0xffffffffffffffdf,in_R9, CONCAT17((char)uVar4,(int7)in_RAX)); goto LAB_001543dc; } uVar4 = uVar4 + 1; lVar5 = lVar5 + 0x20; } while (*(uint *)(lVar3 + 0x18) != uVar4); } iVar2 = c4_get_log_level(); if (iVar2 != 0) { ssz_add_builders_cold_1(&stack0x00000008,param_1,param_2); } } return; }
27,578
mysql_stmt_store_result_start_internal
eloqsql/libmariadb/libmariadb/mariadb_async.c
static void mysql_stmt_store_result_start_internal(void *d) { MK_ASYNC_INTERNAL_BODY( mysql_stmt_store_result, (parms->stmt), parms->stmt->mysql, int, r_int) }
O0
c
mysql_stmt_store_result_start_internal: pushq %rbp movq %rsp, %rbp subq $0x20, %rsp movq %rdi, -0x8(%rbp) movq -0x8(%rbp), %rax movq %rax, -0x10(%rbp) movq -0x10(%rbp), %rax movq (%rax), %rax movq 0x38(%rax), %rax movq 0x480(%rax), %rax movq 0x28(%rax), %rax movq %rax, -0x20(%rbp) movq -0x10(%rbp), %rax movq (%rax), %rdi callq 0x5c8d0 movl %eax, -0x14(%rbp) movl -0x14(%rbp), %ecx movq -0x20(%rbp), %rax movl %ecx, 0x8(%rax) movq -0x20(%rbp), %rax movl $0x0, (%rax) addq $0x20, %rsp popq %rbp retq nopw (%rax,%rax)
mysql_stmt_store_result_start_internal: push rbp mov rbp, rsp sub rsp, 20h mov [rbp+var_8], rdi mov rax, [rbp+var_8] mov [rbp+var_10], rax mov rax, [rbp+var_10] mov rax, [rax] mov rax, [rax+38h] mov rax, [rax+480h] mov rax, [rax+28h] mov [rbp+var_20], rax mov rax, [rbp+var_10] mov rdi, [rax] call mysql_stmt_store_result mov [rbp+var_14], eax mov ecx, [rbp+var_14] mov rax, [rbp+var_20] mov [rax+8], ecx mov rax, [rbp+var_20] mov dword ptr [rax], 0 add rsp, 20h pop rbp retn
_DWORD * mysql_stmt_store_result_start_internal(long long *a1) { _DWORD *result; // rax _DWORD *v2; // [rsp+0h] [rbp-20h] v2 = *(_DWORD **)(*(_QWORD *)(*(_QWORD *)(*a1 + 56) + 1152LL) + 40LL); v2[2] = mysql_stmt_store_result(*a1); result = v2; *v2 = 0; return result; }
mysql_stmt_store_result_start_internal: PUSH RBP MOV RBP,RSP SUB RSP,0x20 MOV qword ptr [RBP + -0x8],RDI MOV RAX,qword ptr [RBP + -0x8] MOV qword ptr [RBP + -0x10],RAX MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX] MOV RAX,qword ptr [RAX + 0x38] MOV RAX,qword ptr [RAX + 0x480] MOV RAX,qword ptr [RAX + 0x28] MOV qword ptr [RBP + -0x20],RAX MOV RAX,qword ptr [RBP + -0x10] MOV RDI,qword ptr [RAX] CALL 0x0015c8d0 MOV dword ptr [RBP + -0x14],EAX MOV ECX,dword ptr [RBP + -0x14] MOV RAX,qword ptr [RBP + -0x20] MOV dword ptr [RAX + 0x8],ECX MOV RAX,qword ptr [RBP + -0x20] MOV dword ptr [RAX],0x0 ADD RSP,0x20 POP RBP RET
void mysql_stmt_store_result_start_internal(long *param_1) { int4 *puVar1; int4 uVar2; puVar1 = *(int4 **)(*(long *)(*(long *)(*param_1 + 0x38) + 0x480) + 0x28); uVar2 = mysql_stmt_store_result(*param_1); puVar1[2] = uVar2; *puVar1 = 0; return; }
27,579
fill_buffer
eloqsql/storage/maria/ma_packrec.c
static void fill_buffer(MARIA_BIT_BUFF *bit_buff) { if (bit_buff->pos >= bit_buff->end) { bit_buff->error= 1; bit_buff->current_byte=0; return; } #if BITS_SAVED == 64 bit_buff->current_byte= ((((uint) ((uchar) bit_buff->pos[7]))) | (((uint) ((uchar) bit_buff->pos[6])) << 8) | (((uint) ((uchar) bit_buff->pos[5])) << 16) | (((uint) ((uchar) bit_buff->pos[4])) << 24) | ((ulonglong) ((((uint) ((uchar) bit_buff->pos[3]))) | (((uint) ((uchar) bit_buff->pos[2])) << 8) | (((uint) ((uchar) bit_buff->pos[1])) << 16) | (((uint) ((uchar) bit_buff->pos[0])) << 24)) << 32)); bit_buff->pos+=8; #else #if BITS_SAVED == 32 bit_buff->current_byte= (((uint) ((uchar) bit_buff->pos[3])) | (((uint) ((uchar) bit_buff->pos[2])) << 8) | (((uint) ((uchar) bit_buff->pos[1])) << 16) | (((uint) ((uchar) bit_buff->pos[0])) << 24)); bit_buff->pos+=4; #else bit_buff->current_byte= (uint) (((uint) ((uchar) bit_buff->pos[1])) | (((uint) ((uchar) bit_buff->pos[0])) << 8)); bit_buff->pos+=2; #endif #endif }
O0
c
fill_buffer: pushq %rbp movq %rsp, %rbp movq %rdi, -0x8(%rbp) movq -0x8(%rbp), %rax movq 0x8(%rax), %rax movq -0x8(%rbp), %rcx cmpq 0x10(%rcx), %rax jb 0x4dfb1 movq -0x8(%rbp), %rax movl $0x1, 0x28(%rax) movq -0x8(%rbp), %rax movl $0x0, (%rax) jmp 0x4e005 movq -0x8(%rbp), %rax movq 0x8(%rax), %rax movzbl 0x3(%rax), %ecx movq -0x8(%rbp), %rax movq 0x8(%rax), %rax movzbl 0x2(%rax), %eax shll $0x8, %eax orl %eax, %ecx movq -0x8(%rbp), %rax movq 0x8(%rax), %rax movzbl 0x1(%rax), %eax shll $0x10, %eax orl %eax, %ecx movq -0x8(%rbp), %rax movq 0x8(%rax), %rax movzbl (%rax), %eax shll $0x18, %eax orl %eax, %ecx movq -0x8(%rbp), %rax movl %ecx, (%rax) movq -0x8(%rbp), %rax movq 0x8(%rax), %rcx addq $0x4, %rcx movq %rcx, 0x8(%rax) popq %rbp retq nopw (%rax,%rax)
fill_buffer: push rbp mov rbp, rsp mov [rbp+var_8], rdi mov rax, [rbp+var_8] mov rax, [rax+8] mov rcx, [rbp+var_8] cmp rax, [rcx+10h] jb short loc_4DFB1 mov rax, [rbp+var_8] mov dword ptr [rax+28h], 1 mov rax, [rbp+var_8] mov dword ptr [rax], 0 jmp short loc_4E005 loc_4DFB1: mov rax, [rbp+var_8] mov rax, [rax+8] movzx ecx, byte ptr [rax+3] mov rax, [rbp+var_8] mov rax, [rax+8] movzx eax, byte ptr [rax+2] shl eax, 8 or ecx, eax mov rax, [rbp+var_8] mov rax, [rax+8] movzx eax, byte ptr [rax+1] shl eax, 10h or ecx, eax mov rax, [rbp+var_8] mov rax, [rax+8] movzx eax, byte ptr [rax] shl eax, 18h or ecx, eax mov rax, [rbp+var_8] mov [rax], ecx mov rax, [rbp+var_8] mov rcx, [rax+8] add rcx, 4 mov [rax+8], rcx loc_4E005: pop rbp retn
long long fill_buffer(long long a1) { long long result; // rax if ( *(_QWORD *)(a1 + 8) < *(_QWORD *)(a1 + 16) ) { *(_DWORD *)a1 = _byteswap_ulong(**(_DWORD **)(a1 + 8)); result = a1; *(_QWORD *)(a1 + 8) += 4LL; } else { *(_DWORD *)(a1 + 40) = 1; result = a1; *(_DWORD *)a1 = 0; } return result; }
fill_buffer: PUSH RBP MOV RBP,RSP MOV qword ptr [RBP + -0x8],RDI MOV RAX,qword ptr [RBP + -0x8] MOV RAX,qword ptr [RAX + 0x8] MOV RCX,qword ptr [RBP + -0x8] CMP RAX,qword ptr [RCX + 0x10] JC 0x0014dfb1 MOV RAX,qword ptr [RBP + -0x8] MOV dword ptr [RAX + 0x28],0x1 MOV RAX,qword ptr [RBP + -0x8] MOV dword ptr [RAX],0x0 JMP 0x0014e005 LAB_0014dfb1: MOV RAX,qword ptr [RBP + -0x8] MOV RAX,qword ptr [RAX + 0x8] MOVZX ECX,byte ptr [RAX + 0x3] MOV RAX,qword ptr [RBP + -0x8] MOV RAX,qword ptr [RAX + 0x8] MOVZX EAX,byte ptr [RAX + 0x2] SHL EAX,0x8 OR ECX,EAX MOV RAX,qword ptr [RBP + -0x8] MOV RAX,qword ptr [RAX + 0x8] MOVZX EAX,byte ptr [RAX + 0x1] SHL EAX,0x10 OR ECX,EAX MOV RAX,qword ptr [RBP + -0x8] MOV RAX,qword ptr [RAX + 0x8] MOVZX EAX,byte ptr [RAX] SHL EAX,0x18 OR ECX,EAX MOV RAX,qword ptr [RBP + -0x8] MOV dword ptr [RAX],ECX MOV RAX,qword ptr [RBP + -0x8] MOV RCX,qword ptr [RAX + 0x8] ADD RCX,0x4 MOV qword ptr [RAX + 0x8],RCX LAB_0014e005: POP RBP RET
void fill_buffer(int4 *param_1) { if (*(ulong *)(param_1 + 2) < *(ulong *)(param_1 + 4)) { *param_1 = CONCAT13(**(int1 **)(param_1 + 2), CONCAT12(*(int1 *)(*(long *)(param_1 + 2) + 1), CONCAT11(*(int1 *)(*(long *)(param_1 + 2) + 2), *(int1 *)(*(long *)(param_1 + 2) + 3)))); *(long *)(param_1 + 2) = *(long *)(param_1 + 2) + 4; } else { param_1[10] = 1; *param_1 = 0; } return; }
27,580
fill_buffer
eloqsql/storage/maria/ma_packrec.c
static void fill_buffer(MARIA_BIT_BUFF *bit_buff) { if (bit_buff->pos >= bit_buff->end) { bit_buff->error= 1; bit_buff->current_byte=0; return; } #if BITS_SAVED == 64 bit_buff->current_byte= ((((uint) ((uchar) bit_buff->pos[7]))) | (((uint) ((uchar) bit_buff->pos[6])) << 8) | (((uint) ((uchar) bit_buff->pos[5])) << 16) | (((uint) ((uchar) bit_buff->pos[4])) << 24) | ((ulonglong) ((((uint) ((uchar) bit_buff->pos[3]))) | (((uint) ((uchar) bit_buff->pos[2])) << 8) | (((uint) ((uchar) bit_buff->pos[1])) << 16) | (((uint) ((uchar) bit_buff->pos[0])) << 24)) << 32)); bit_buff->pos+=8; #else #if BITS_SAVED == 32 bit_buff->current_byte= (((uint) ((uchar) bit_buff->pos[3])) | (((uint) ((uchar) bit_buff->pos[2])) << 8) | (((uint) ((uchar) bit_buff->pos[1])) << 16) | (((uint) ((uchar) bit_buff->pos[0])) << 24)); bit_buff->pos+=4; #else bit_buff->current_byte= (uint) (((uint) ((uchar) bit_buff->pos[1])) | (((uint) ((uchar) bit_buff->pos[0])) << 8)); bit_buff->pos+=2; #endif #endif }
O3
c
fill_buffer: movq 0x8(%rdi), %rcx cmpq 0x10(%rdi), %rcx jae 0x45ffd pushq %rbp movq %rsp, %rbp movl (%rcx), %eax bswapl %eax addq $0x4, %rcx movq %rcx, 0x8(%rdi) popq %rbp jmp 0x46006 movl $0x1, 0x28(%rdi) xorl %eax, %eax movl %eax, (%rdi) retq
fill_buffer: mov rcx, [rdi+8] cmp rcx, [rdi+10h] jnb short loc_45FFD push rbp mov rbp, rsp mov eax, [rcx] bswap eax add rcx, 4 mov [rdi+8], rcx pop rbp jmp short loc_46006 loc_45FFD: mov dword ptr [rdi+28h], 1 xor eax, eax loc_46006: mov [rdi], eax retn
long long fill_buffer(long long a1) { unsigned int *v1; // rcx long long result; // rax v1 = *(unsigned int **)(a1 + 8); if ( (unsigned long long)v1 >= *(_QWORD *)(a1 + 16) ) { *(_DWORD *)(a1 + 40) = 1; result = 0LL; } else { result = _byteswap_ulong(*v1); *(_QWORD *)(a1 + 8) = v1 + 1; } *(_DWORD *)a1 = result; return result; }
fill_buffer: MOV RCX,qword ptr [RDI + 0x8] CMP RCX,qword ptr [RDI + 0x10] JNC 0x00145ffd PUSH RBP MOV RBP,RSP MOV EAX,dword ptr [RCX] BSWAP EAX ADD RCX,0x4 MOV qword ptr [RDI + 0x8],RCX POP RBP JMP 0x00146006 LAB_00145ffd: MOV dword ptr [RDI + 0x28],0x1 XOR EAX,EAX LAB_00146006: MOV dword ptr [RDI],EAX RET
void fill_buffer(uint *param_1) { uint *puVar1; uint uVar2; puVar1 = *(uint **)(param_1 + 2); if (puVar1 < *(uint **)(param_1 + 4)) { uVar2 = *puVar1; uVar2 = uVar2 >> 0x18 | (uVar2 & 0xff0000) >> 8 | (uVar2 & 0xff00) << 8 | uVar2 << 0x18; *(uint **)(param_1 + 2) = puVar1 + 1; } else { param_1[10] = 1; uVar2 = 0; } *param_1 = uVar2; return; }
27,581
get_digit
bluesky950520[P]quickjs/libbf.c
static limb_t get_digit(const limb_t *tab, limb_t len, slimb_t pos) { slimb_t i; int shift; i = floor_div(pos, LIMB_DIGITS); if (i < 0 || i >= len) return 0; shift = pos - i * LIMB_DIGITS; return fast_shr_dec(tab[i], shift) % 10; }
O0
c
get_digit: subq $0x38, %rsp movq %rdi, 0x28(%rsp) movq %rsi, 0x20(%rsp) movq %rdx, 0x18(%rsp) movq 0x18(%rsp), %rdi movl $0x13, %esi callq 0xf5380 movq %rax, 0x10(%rsp) cmpq $0x0, 0x10(%rsp) jl 0xf4e6b movq 0x10(%rsp), %rax cmpq 0x20(%rsp), %rax jb 0xf4e76 movq $0x0, 0x30(%rsp) jmp 0xf4eae movq 0x18(%rsp), %rax imulq $0x13, 0x10(%rsp), %rcx subq %rcx, %rax movl %eax, 0xc(%rsp) movq 0x28(%rsp), %rax movq 0x10(%rsp), %rcx movq (%rax,%rcx,8), %rdi movl 0xc(%rsp), %esi callq 0xf5680 movl $0xa, %ecx xorl %edx, %edx divq %rcx movq %rdx, 0x30(%rsp) movq 0x30(%rsp), %rax addq $0x38, %rsp retq nopl (%rax,%rax)
get_digit: sub rsp, 38h mov [rsp+38h+var_10], rdi mov [rsp+38h+var_18], rsi mov [rsp+38h+var_20], rdx mov rdi, [rsp+38h+var_20] mov esi, 13h call floor_div mov [rsp+38h+var_28], rax cmp [rsp+38h+var_28], 0 jl short loc_F4E6B mov rax, [rsp+38h+var_28] cmp rax, [rsp+38h+var_18] jb short loc_F4E76 loc_F4E6B: mov [rsp+38h+var_8], 0 jmp short loc_F4EAE loc_F4E76: mov rax, [rsp+38h+var_20] imul rcx, [rsp+38h+var_28], 13h sub rax, rcx mov [rsp+38h+var_2C], eax mov rax, [rsp+38h+var_10] mov rcx, [rsp+38h+var_28] mov rdi, [rax+rcx*8] mov esi, [rsp+38h+var_2C] call fast_shr_dec mov ecx, 0Ah xor edx, edx div rcx mov [rsp+38h+var_8], rdx loc_F4EAE: mov rax, [rsp+38h+var_8] add rsp, 38h retn
unsigned long long get_digit(long long a1, unsigned long long a2, long long a3) { long long v4; // [rsp+10h] [rbp-28h] int v5; // [rsp+18h] [rbp-20h] v5 = a3; v4 = floor_div(a3, 19LL); if ( v4 >= 0 && v4 < a2 ) return fast_shr_dec(*(_QWORD *)(a1 + 8 * v4), (unsigned int)(v5 - 19 * v4)) % 0xAuLL; else return 0LL; }
get_digit: SUB RSP,0x38 MOV qword ptr [RSP + 0x28],RDI MOV qword ptr [RSP + 0x20],RSI MOV qword ptr [RSP + 0x18],RDX MOV RDI,qword ptr [RSP + 0x18] MOV ESI,0x13 CALL 0x001f5380 MOV qword ptr [RSP + 0x10],RAX CMP qword ptr [RSP + 0x10],0x0 JL 0x001f4e6b MOV RAX,qword ptr [RSP + 0x10] CMP RAX,qword ptr [RSP + 0x20] JC 0x001f4e76 LAB_001f4e6b: MOV qword ptr [RSP + 0x30],0x0 JMP 0x001f4eae LAB_001f4e76: MOV RAX,qword ptr [RSP + 0x18] IMUL RCX,qword ptr [RSP + 0x10],0x13 SUB RAX,RCX MOV dword ptr [RSP + 0xc],EAX MOV RAX,qword ptr [RSP + 0x28] MOV RCX,qword ptr [RSP + 0x10] MOV RDI,qword ptr [RAX + RCX*0x8] MOV ESI,dword ptr [RSP + 0xc] CALL 0x001f5680 MOV ECX,0xa XOR EDX,EDX DIV RCX MOV qword ptr [RSP + 0x30],RDX LAB_001f4eae: MOV RAX,qword ptr [RSP + 0x30] ADD RSP,0x38 RET
ulong get_digit(long param_1,ulong param_2,int8 param_3) { ulong uVar1; int8 local_8; uVar1 = floor_div(param_3,0x13); if (((long)uVar1 < 0) || (param_2 <= uVar1)) { local_8 = 0; } else { local_8 = fast_shr_dec(*(int8 *)(param_1 + uVar1 * 8),(int)param_3 + (int)uVar1 * -0x13); local_8 = local_8 % 10; } return local_8; }
27,582
get_digit
bluesky950520[P]quickjs/libbf.c
static limb_t get_digit(const limb_t *tab, limb_t len, slimb_t pos) { slimb_t i; int shift; i = floor_div(pos, LIMB_DIGITS); if (i < 0 || i >= len) return 0; shift = pos - i * LIMB_DIGITS; return fast_shr_dec(tab[i], shift) % 10; }
O1
c
get_digit: movq %rdx, %rcx testq %rdx, %rdx js 0x8fafc movabsq $-0x286bca1af286bca1, %rdx # imm = 0xD79435E50D79435F movq %rcx, %rax mulq %rdx shrq $0x4, %rdx jmp 0x8fb17 leaq -0x12(%rcx), %rax movabsq $0xd79435e50d79436, %rdx # imm = 0xD79435E50D79436 imulq %rdx movq %rdx, %rax shrq $0x3f, %rdx addq %rax, %rdx testq %rdx, %rdx sets %al cmpq %rsi, %rdx setae %sil orb %al, %sil jne 0x8fb7e imull $-0x13, %edx, %eax addl %eax, %ecx movq (%rdi,%rdx,8), %rsi movslq %ecx, %rdi shlq $0x4, %rdi leaq 0x133e0(%rip), %r8 # 0xa2f20 movq %rsi, %rax mulq (%rdi,%r8) subq %rdx, %rsi movb 0x8(%rdi,%r8), %cl shrq %cl, %rsi movb 0x9(%rdi,%r8), %cl addq %rdx, %rsi shrq %cl, %rsi movabsq $-0x3333333333333333, %rcx # imm = 0xCCCCCCCCCCCCCCCD movq %rsi, %rax mulq %rcx shrq $0x2, %rdx andq $-0x2, %rdx leaq (%rdx,%rdx,4), %rax subq %rax, %rsi jmp 0x8fb80 xorl %esi, %esi movq %rsi, %rax retq
get_digit: mov rcx, rdx test rdx, rdx js short loc_8FAFC mov rdx, 0D79435E50D79435Fh mov rax, rcx mul rdx shr rdx, 4 jmp short loc_8FB17 loc_8FAFC: lea rax, [rcx-12h] mov rdx, 0D79435E50D79436h imul rdx mov rax, rdx shr rdx, 3Fh add rdx, rax loc_8FB17: test rdx, rdx sets al cmp rdx, rsi setnb sil or sil, al jnz short loc_8FB7E imul eax, edx, -13h add ecx, eax mov rsi, [rdi+rdx*8] movsxd rdi, ecx shl rdi, 4 lea r8, mp_pow_div mov rax, rsi mul qword ptr [rdi+r8] sub rsi, rdx mov cl, [rdi+r8+8] shr rsi, cl mov cl, [rdi+r8+9] add rsi, rdx shr rsi, cl mov rcx, 0CCCCCCCCCCCCCCCDh mov rax, rsi mul rcx shr rdx, 2 and rdx, 0FFFFFFFFFFFFFFFEh lea rax, [rdx+rdx*4] sub rsi, rax jmp short loc_8FB80 loc_8FB7E: xor esi, esi loc_8FB80: mov rax, rsi retn
unsigned long long get_digit(long long a1, unsigned long long a2, long long a3) { int v3; // ecx long long v4; // rdx unsigned long long v5; // rsi long long v6; // rdi long long v7; // rdx unsigned long long v8; // rsi v3 = a3; if ( a3 < 0 ) v4 = (a3 - 18) / 19; else v4 = a3 / 0x13uLL; if ( v4 < 0 || v4 >= a2 ) return 0LL; v5 = *(_QWORD *)(a1 + 8 * v4); v6 = 16LL * (-19 * (int)v4 + v3); v7 = (*(unsigned long long *)&mp_pow_div[v6] * (unsigned __int128)v5) >> 64; v8 = (v7 + ((v5 - v7) >> mp_pow_div[v6 + 8])) >> mp_pow_div[v6 + 9]; return v8 - 5 * ((v8 / 5) & 0xFFFFFFFFFFFFFFFELL); }
27,583
get_digit
bluesky950520[P]quickjs/libbf.c
static limb_t get_digit(const limb_t *tab, limb_t len, slimb_t pos) { slimb_t i; int shift; i = floor_div(pos, LIMB_DIGITS); if (i < 0 || i >= len) return 0; shift = pos - i * LIMB_DIGITS; return fast_shr_dec(tab[i], shift) % 10; }
O2
c
get_digit: movq %rdx, %rcx testq %rdx, %rdx js 0x77d0b pushq $0x13 popq %r8 movq %rcx, %rax xorl %edx, %edx divq %r8 jmp 0x77d18 leaq -0x12(%rcx), %rax pushq $0x13 popq %r8 cqto idivq %r8 testq %rax, %rax sets %dl cmpq %rsi, %rax setae %sil orb %dl, %sil jne 0x77d4b pushq %rax imull $-0x13, %eax, %edx addl %edx, %ecx movq (%rdi,%rax,8), %rdi movl %ecx, %esi callq 0x781dc pushq $0xa popq %rcx xorl %edx, %edx divq %rcx movq %rdx, %rax addq $0x8, %rsp retq xorl %eax, %eax retq
get_digit: mov rcx, rdx test rdx, rdx js short loc_77D0B push 13h pop r8 mov rax, rcx xor edx, edx div r8 jmp short loc_77D18 loc_77D0B: lea rax, [rcx-12h] push 13h pop r8 cqo idiv r8 loc_77D18: test rax, rax sets dl cmp rax, rsi setnb sil or sil, dl jnz short loc_77D4B push rax imul edx, eax, -13h add ecx, edx mov rdi, [rdi+rax*8] mov esi, ecx call fast_shr_dec push 0Ah pop rcx xor edx, edx div rcx mov rax, rdx add rsp, 8 retn loc_77D4B: xor eax, eax retn
unsigned long long get_digit(long long a1, unsigned long long a2, long long a3) { long long v3; // rax if ( a3 < 0 ) v3 = (a3 - 18) / 19; else v3 = a3 / 0x13uLL; if ( v3 < 0 || v3 >= a2 ) return 0LL; else return fast_shr_dec(*(_QWORD *)(a1 + 8 * v3), (unsigned int)(-19 * v3 + a3)) % 0xAuLL; }
get_digit: MOV RCX,RDX TEST RDX,RDX JS 0x00177d0b PUSH 0x13 POP R8 MOV RAX,RCX XOR EDX,EDX DIV R8 JMP 0x00177d18 LAB_00177d0b: LEA RAX,[RCX + -0x12] PUSH 0x13 POP R8 CQO IDIV R8 LAB_00177d18: TEST RAX,RAX SETS DL CMP RAX,RSI SETNC SIL OR SIL,DL JNZ 0x00177d4b PUSH RAX IMUL EDX,EAX,-0x13 ADD ECX,EDX MOV RDI,qword ptr [RDI + RAX*0x8] MOV ESI,ECX CALL 0x001781dc PUSH 0xa POP RCX XOR EDX,EDX DIV RCX MOV RAX,RDX ADD RSP,0x8 RET LAB_00177d4b: XOR EAX,EAX RET
ulong get_digit(long param_1,ulong param_2,ulong param_3) { ulong uVar1; if ((long)param_3 < 0) { uVar1 = (long)(param_3 - 0x12) / 0x13; } else { uVar1 = param_3 / 0x13; } if (uVar1 < param_2 && -1 < (long)uVar1) { uVar1 = fast_shr_dec(*(int8 *)(param_1 + uVar1 * 8),(int)param_3 + (int)uVar1 * -0x13); return uVar1 % 10; } return 0; }
27,584
ma_tls_read_async
eloqsql/libmariadb/libmariadb/secure/openssl.c
ssize_t ma_tls_read_async(MARIADB_PVIO *pvio, const unsigned char *buffer, size_t length) { int res; struct mysql_async_context *b= pvio->mysql->options.extension->async_context; MARIADB_TLS *ctls= pvio->ctls; for (;;) { res= SSL_read((SSL *)ctls->ssl, (void *)buffer, (int)length); if (ma_tls_async_check_result(res, b, (SSL *)ctls->ssl)) return res; } }
O0
c
ma_tls_read_async: pushq %rbp movq %rsp, %rbp subq $0x30, %rsp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq %rdx, -0x18(%rbp) movq -0x8(%rbp), %rax movq 0x40(%rax), %rax movq 0x480(%rax), %rax movq 0x28(%rax), %rax movq %rax, -0x28(%rbp) movq -0x8(%rbp), %rax movq 0x38(%rax), %rax movq %rax, -0x30(%rbp) movq -0x30(%rbp), %rax movq 0x10(%rax), %rdi movq -0x10(%rbp), %rsi movq -0x18(%rbp), %rax movl %eax, %edx callq 0x13070 movl %eax, -0x1c(%rbp) movl -0x1c(%rbp), %edi movq -0x28(%rbp), %rsi movq -0x30(%rbp), %rax movq 0x10(%rax), %rdx callq 0x3ce30 cmpb $0x0, %al je 0x3ce23 movslq -0x1c(%rbp), %rax addq $0x30, %rsp popq %rbp retq jmp 0x3cde7 nopw %cs:(%rax,%rax)
ma_tls_read_async: push rbp mov rbp, rsp sub rsp, 30h mov [rbp+var_8], rdi mov [rbp+var_10], rsi mov [rbp+var_18], rdx mov rax, [rbp+var_8] mov rax, [rax+40h] mov rax, [rax+480h] mov rax, [rax+28h] mov [rbp+var_28], rax mov rax, [rbp+var_8] mov rax, [rax+38h] mov [rbp+var_30], rax loc_3CDE7: mov rax, [rbp+var_30] mov rdi, [rax+10h] mov rsi, [rbp+var_10] mov rax, [rbp+var_18] mov edx, eax call _SSL_read mov [rbp+var_1C], eax mov edi, [rbp+var_1C] mov rsi, [rbp+var_28] mov rax, [rbp+var_30] mov rdx, [rax+10h] call ma_tls_async_check_result cmp al, 0 jz short loc_3CE23 movsxd rax, [rbp+var_1C] add rsp, 30h pop rbp retn loc_3CE23: jmp short loc_3CDE7
long long ma_tls_read_async(long long a1, long long a2, unsigned int a3) { long long v4; // [rsp+0h] [rbp-30h] long long v5; // [rsp+8h] [rbp-28h] unsigned int v6; // [rsp+14h] [rbp-1Ch] v5 = *(_QWORD *)(*(_QWORD *)(*(_QWORD *)(a1 + 64) + 1152LL) + 40LL); v4 = *(_QWORD *)(a1 + 56); do v6 = SSL_read(*(_QWORD *)(v4 + 16), a2, a3); while ( !(unsigned __int8)ma_tls_async_check_result(v6, v5, *(_QWORD *)(v4 + 16)) ); return (int)v6; }
ma_tls_read_async: PUSH RBP MOV RBP,RSP SUB RSP,0x30 MOV qword ptr [RBP + -0x8],RDI MOV qword ptr [RBP + -0x10],RSI MOV qword ptr [RBP + -0x18],RDX MOV RAX,qword ptr [RBP + -0x8] MOV RAX,qword ptr [RAX + 0x40] MOV RAX,qword ptr [RAX + 0x480] MOV RAX,qword ptr [RAX + 0x28] MOV qword ptr [RBP + -0x28],RAX MOV RAX,qword ptr [RBP + -0x8] MOV RAX,qword ptr [RAX + 0x38] MOV qword ptr [RBP + -0x30],RAX LAB_0013cde7: MOV RAX,qword ptr [RBP + -0x30] MOV RDI,qword ptr [RAX + 0x10] MOV RSI,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RBP + -0x18] MOV EDX,EAX CALL 0x00113070 MOV dword ptr [RBP + -0x1c],EAX MOV EDI,dword ptr [RBP + -0x1c] MOV RSI,qword ptr [RBP + -0x28] MOV RAX,qword ptr [RBP + -0x30] MOV RDX,qword ptr [RAX + 0x10] CALL 0x0013ce30 CMP AL,0x0 JZ 0x0013ce23 MOVSXD RAX,dword ptr [RBP + -0x1c] ADD RSP,0x30 POP RBP RET LAB_0013ce23: JMP 0x0013cde7
long ma_tls_read_async(long param_1,void *param_2,int param_3) { int8 uVar1; long lVar2; char cVar3; int iVar4; uVar1 = *(int8 *)(*(long *)(*(long *)(param_1 + 0x40) + 0x480) + 0x28); lVar2 = *(long *)(param_1 + 0x38); do { iVar4 = SSL_read(*(SSL **)(lVar2 + 0x10),param_2,param_3); cVar3 = ma_tls_async_check_result(iVar4,uVar1,*(int8 *)(lVar2 + 0x10)); } while (cVar3 == '\0'); return (long)iVar4; }
27,585
vec_select
corpus-core[P]colibri-stateless/build_O0/_deps/blst-src/src/vect.h
static inline void vec_select(void *ret, const void *a, const void *b, size_t num, bool_t sel_a) { launder(sel_a); #ifndef __BLST_NO_ASM__ if (num == 32) vec_select_32(ret, a, b, sel_a); else if (num == 48) vec_select_48(ret, a, b, sel_a); else if (num == 96) vec_select_96(ret, a, b, sel_a); else if (num == 144) vec_select_144(ret, a, b, sel_a); else if (num == 192) vec_select_192(ret, a, b, sel_a); else if (num == 288) vec_select_288(ret, a, b, sel_a); #else if (0) ; #endif else { limb_t bi; volatile limb_t *rp = (limb_t *)ret; const limb_t *ap = (const limb_t *)a; const limb_t *bp = (const limb_t *)b; limb_t xorm, mask = (limb_t)0 - sel_a; size_t i; num /= sizeof(limb_t); for (i = 0; i < num; i++) { xorm = (ap[i] ^ (bi = bp[i])) & mask; rp[i] = bi ^ xorm; } }
O0
c
vec_select: pushq %rbp movq %rsp, %rbp subq $0x60, %rsp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq %rdx, -0x18(%rbp) movq %rcx, -0x20(%rbp) movq %r8, -0x28(%rbp) movq -0x28(%rbp), %rax movq %rax, -0x28(%rbp) cmpq $0x20, -0x20(%rbp) jne 0xa8b85 movq -0x8(%rbp), %rdi movq -0x10(%rbp), %rsi movq -0x18(%rbp), %rdx movq -0x28(%rbp), %rcx callq 0xc68c0 jmp 0xa8cc8 cmpq $0x30, -0x20(%rbp) jne 0xa8ba6 movq -0x8(%rbp), %rdi movq -0x10(%rbp), %rsi movq -0x18(%rbp), %rdx movq -0x28(%rbp), %rcx callq 0xc6920 jmp 0xa8cc6 cmpq $0x60, -0x20(%rbp) jne 0xa8bc7 movq -0x8(%rbp), %rdi movq -0x10(%rbp), %rsi movq -0x18(%rbp), %rdx movq -0x28(%rbp), %rcx callq 0xc69a0 jmp 0xa8cc4 cmpq $0x90, -0x20(%rbp) jne 0xa8beb movq -0x8(%rbp), %rdi movq -0x10(%rbp), %rsi movq -0x18(%rbp), %rdx movq -0x28(%rbp), %rcx callq 0xc6c00 jmp 0xa8cc2 cmpq $0xc0, -0x20(%rbp) jne 0xa8c0f movq -0x8(%rbp), %rdi movq -0x10(%rbp), %rsi movq -0x18(%rbp), %rdx movq -0x28(%rbp), %rcx callq 0xc6a80 jmp 0xa8cc0 cmpq $0x120, -0x20(%rbp) # imm = 0x120 jne 0xa8c33 movq -0x8(%rbp), %rdi movq -0x10(%rbp), %rsi movq -0x18(%rbp), %rdx movq -0x28(%rbp), %rcx callq 0xc6d20 jmp 0xa8cbe movq -0x8(%rbp), %rax movq %rax, -0x38(%rbp) movq -0x10(%rbp), %rax movq %rax, -0x40(%rbp) movq -0x18(%rbp), %rax movq %rax, -0x48(%rbp) xorl %eax, %eax subq -0x28(%rbp), %rax movq %rax, -0x58(%rbp) movq -0x20(%rbp), %rax shrq $0x3, %rax movq %rax, -0x20(%rbp) movq $0x0, -0x60(%rbp) movq -0x60(%rbp), %rax cmpq -0x20(%rbp), %rax jae 0xa8cbc movq -0x40(%rbp), %rax movq -0x60(%rbp), %rcx movq (%rax,%rcx,8), %rax movq -0x48(%rbp), %rcx movq -0x60(%rbp), %rdx movq (%rcx,%rdx,8), %rcx movq %rcx, -0x30(%rbp) xorq %rcx, %rax andq -0x58(%rbp), %rax movq %rax, -0x50(%rbp) movq -0x30(%rbp), %rdx xorq -0x50(%rbp), %rdx movq -0x38(%rbp), %rax movq -0x60(%rbp), %rcx movq %rdx, (%rax,%rcx,8) movq -0x60(%rbp), %rax addq $0x1, %rax movq %rax, -0x60(%rbp) jmp 0xa8c69 jmp 0xa8cbe jmp 0xa8cc0 jmp 0xa8cc2 jmp 0xa8cc4 jmp 0xa8cc6 jmp 0xa8cc8 addq $0x60, %rsp popq %rbp retq nop
vec_select: push rbp mov rbp, rsp sub rsp, 60h mov [rbp+var_8], rdi mov [rbp+var_10], rsi mov [rbp+var_18], rdx mov [rbp+var_20], rcx mov [rbp+var_28], r8 mov rax, [rbp+var_28] mov [rbp+var_28], rax cmp [rbp+var_20], 20h ; ' ' jnz short loc_A8B85 mov rdi, [rbp+var_8] mov rsi, [rbp+var_10] mov rdx, [rbp+var_18] mov rcx, [rbp+var_28] call vec_select_32 jmp loc_A8CC8 loc_A8B85: cmp [rbp+var_20], 30h ; '0' jnz short loc_A8BA6 mov rdi, [rbp+var_8] mov rsi, [rbp+var_10] mov rdx, [rbp+var_18] mov rcx, [rbp+var_28] call vec_select_48 jmp loc_A8CC6 loc_A8BA6: cmp [rbp+var_20], 60h ; '`' jnz short loc_A8BC7 mov rdi, [rbp+var_8] mov rsi, [rbp+var_10] mov rdx, [rbp+var_18] mov rcx, [rbp+var_28] call vec_select_96 jmp loc_A8CC4 loc_A8BC7: cmp [rbp+var_20], 90h jnz short loc_A8BEB mov rdi, [rbp+var_8] mov rsi, [rbp+var_10] mov rdx, [rbp+var_18] mov rcx, [rbp+var_28] call vec_select_144 jmp loc_A8CC2 loc_A8BEB: cmp [rbp+var_20], 0C0h jnz short loc_A8C0F mov rdi, [rbp+var_8] mov rsi, [rbp+var_10] mov rdx, [rbp+var_18] mov rcx, [rbp+var_28] call vec_select_192 jmp loc_A8CC0 loc_A8C0F: cmp [rbp+var_20], 120h jnz short loc_A8C33 mov rdi, [rbp+var_8] mov rsi, [rbp+var_10] mov rdx, [rbp+var_18] mov rcx, [rbp+var_28] call vec_select_288 jmp loc_A8CBE loc_A8C33: mov rax, [rbp+var_8] mov [rbp+var_38], rax mov rax, [rbp+var_10] mov [rbp+var_40], rax mov rax, [rbp+var_18] mov [rbp+var_48], rax xor eax, eax sub rax, [rbp+var_28] mov [rbp+var_58], rax mov rax, [rbp+var_20] shr rax, 3 mov [rbp+var_20], rax mov [rbp+var_60], 0 loc_A8C69: mov rax, [rbp+var_60] cmp rax, [rbp+var_20] jnb short loc_A8CBC mov rax, [rbp+var_40] mov rcx, [rbp+var_60] mov rax, [rax+rcx*8] mov rcx, [rbp+var_48] mov rdx, [rbp+var_60] mov rcx, [rcx+rdx*8] mov [rbp+var_30], rcx xor rax, rcx and rax, [rbp+var_58] mov [rbp+var_50], rax mov rdx, [rbp+var_30] xor rdx, [rbp+var_50] mov rax, [rbp+var_38] mov rcx, [rbp+var_60] mov [rax+rcx*8], rdx mov rax, [rbp+var_60] add rax, 1 mov [rbp+var_60], rax jmp short loc_A8C69 loc_A8CBC: jmp short $+2 loc_A8CBE: jmp short $+2 loc_A8CC0: jmp short $+2 loc_A8CC2: jmp short $+2 loc_A8CC4: jmp short $+2 loc_A8CC6: jmp short $+2 loc_A8CC8: add rsp, 60h pop rbp retn
long long vec_select(long long a1, long long a2, long long a3, unsigned long long a4, long long a5) { long long result; // rax unsigned long long i; // [rsp+0h] [rbp-60h] switch ( a4 ) { case 0x20uLL: return vec_select_32(a1, a2, a3, a5); case 0x30uLL: return vec_select_48(a1, a2, a3, a5); case 0x60uLL: return vec_select_96(a1, a2, a3, a5); case 0x90uLL: return vec_select_144(a1, a2, a3, a5); case 0xC0uLL: return vec_select_192(a1, a2, a3, a5); case 0x120uLL: return vec_select_288(a1, a2, a3, a5); } for ( i = 0LL; ; ++i ) { result = i; if ( i >= a4 >> 3 ) break; *(_QWORD *)(a1 + 8 * i) = -a5 & (*(_QWORD *)(a3 + 8 * i) ^ *(_QWORD *)(a2 + 8 * i)) ^ *(_QWORD *)(a3 + 8 * i); } return result; }
vec_select: PUSH RBP MOV RBP,RSP SUB RSP,0x60 MOV qword ptr [RBP + -0x8],RDI MOV qword ptr [RBP + -0x10],RSI MOV qword ptr [RBP + -0x18],RDX MOV qword ptr [RBP + -0x20],RCX MOV qword ptr [RBP + -0x28],R8 MOV RAX,qword ptr [RBP + -0x28] MOV qword ptr [RBP + -0x28],RAX CMP qword ptr [RBP + -0x20],0x20 JNZ 0x001a8b85 MOV RDI,qword ptr [RBP + -0x8] MOV RSI,qword ptr [RBP + -0x10] MOV RDX,qword ptr [RBP + -0x18] MOV RCX,qword ptr [RBP + -0x28] CALL 0x001c68c0 JMP 0x001a8cc8 LAB_001a8b85: CMP qword ptr [RBP + -0x20],0x30 JNZ 0x001a8ba6 MOV RDI,qword ptr [RBP + -0x8] MOV RSI,qword ptr [RBP + -0x10] MOV RDX,qword ptr [RBP + -0x18] MOV RCX,qword ptr [RBP + -0x28] CALL 0x001c6920 JMP 0x001a8cc6 LAB_001a8ba6: CMP qword ptr [RBP + -0x20],0x60 JNZ 0x001a8bc7 MOV RDI,qword ptr [RBP + -0x8] MOV RSI,qword ptr [RBP + -0x10] MOV RDX,qword ptr [RBP + -0x18] MOV RCX,qword ptr [RBP + -0x28] CALL 0x001c69a0 JMP 0x001a8cc4 LAB_001a8bc7: CMP qword ptr [RBP + -0x20],0x90 JNZ 0x001a8beb MOV RDI,qword ptr [RBP + -0x8] MOV RSI,qword ptr [RBP + -0x10] MOV RDX,qword ptr [RBP + -0x18] MOV RCX,qword ptr [RBP + -0x28] CALL 0x001c6c00 JMP 0x001a8cc2 LAB_001a8beb: CMP qword ptr [RBP + -0x20],0xc0 JNZ 0x001a8c0f MOV RDI,qword ptr [RBP + -0x8] MOV RSI,qword ptr [RBP + -0x10] MOV RDX,qword ptr [RBP + -0x18] MOV RCX,qword ptr [RBP + -0x28] CALL 0x001c6a80 JMP 0x001a8cc0 LAB_001a8c0f: CMP qword ptr [RBP + -0x20],0x120 JNZ 0x001a8c33 MOV RDI,qword ptr [RBP + -0x8] MOV RSI,qword ptr [RBP + -0x10] MOV RDX,qword ptr [RBP + -0x18] MOV RCX,qword ptr [RBP + -0x28] CALL 0x001c6d20 JMP 0x001a8cbe LAB_001a8c33: MOV RAX,qword ptr [RBP + -0x8] MOV qword ptr [RBP + -0x38],RAX MOV RAX,qword ptr [RBP + -0x10] MOV qword ptr [RBP + -0x40],RAX MOV RAX,qword ptr [RBP + -0x18] MOV qword ptr [RBP + -0x48],RAX XOR EAX,EAX SUB RAX,qword ptr [RBP + -0x28] MOV qword ptr [RBP + -0x58],RAX MOV RAX,qword ptr [RBP + -0x20] SHR RAX,0x3 MOV qword ptr [RBP + -0x20],RAX MOV qword ptr [RBP + -0x60],0x0 LAB_001a8c69: MOV RAX,qword ptr [RBP + -0x60] CMP RAX,qword ptr [RBP + -0x20] JNC 0x001a8cbc MOV RAX,qword ptr [RBP + -0x40] MOV RCX,qword ptr [RBP + -0x60] MOV RAX,qword ptr [RAX + RCX*0x8] MOV RCX,qword ptr [RBP + -0x48] MOV RDX,qword ptr [RBP + -0x60] MOV RCX,qword ptr [RCX + RDX*0x8] MOV qword ptr [RBP + -0x30],RCX XOR RAX,RCX AND RAX,qword ptr [RBP + -0x58] MOV qword ptr [RBP + -0x50],RAX MOV RDX,qword ptr [RBP + -0x30] XOR RDX,qword ptr [RBP + -0x50] MOV RAX,qword ptr [RBP + -0x38] MOV RCX,qword ptr [RBP + -0x60] MOV qword ptr [RAX + RCX*0x8],RDX MOV RAX,qword ptr [RBP + -0x60] ADD RAX,0x1 MOV qword ptr [RBP + -0x60],RAX JMP 0x001a8c69 LAB_001a8cbc: JMP 0x001a8cbe LAB_001a8cbe: JMP 0x001a8cc0 LAB_001a8cc0: JMP 0x001a8cc2 LAB_001a8cc2: JMP 0x001a8cc4 LAB_001a8cc4: JMP 0x001a8cc6 LAB_001a8cc6: JMP 0x001a8cc8 LAB_001a8cc8: ADD RSP,0x60 POP RBP RET
void vec_select(long param_1,long param_2,long param_3,ulong param_4,long param_5) { ulong uVar1; int8 local_68; if (param_4 == 0x20) { vec_select_32(param_1,param_2,param_3,param_5); } else if (param_4 == 0x30) { vec_select_48(param_1,param_2,param_3,param_5); } else if (param_4 == 0x60) { vec_select_96(param_1,param_2,param_3,param_5); } else if (param_4 == 0x90) { vec_select_144(param_1,param_2,param_3,param_5); } else if (param_4 == 0xc0) { vec_select_192(param_1,param_2,param_3,param_5); } else if (param_4 == 0x120) { vec_select_288(param_1,param_2,param_3,param_5); } else { for (local_68 = 0; local_68 < param_4 >> 3; local_68 = local_68 + 1) { uVar1 = *(ulong *)(param_3 + local_68 * 8); *(ulong *)(param_1 + local_68 * 8) = uVar1 ^ (*(ulong *)(param_2 + local_68 * 8) ^ uVar1) & -param_5; } } return; }
27,586
ImPlot3D::GetLocationPos(ImRect const&, ImVec2 const&, int, ImVec2 const&)
zkingston[P]unknot/build_O1/_deps/implot3d-src/implot3d.cpp
ImVec2 GetLocationPos(const ImRect& outer_rect, const ImVec2& inner_size, ImPlot3DLocation loc, const ImVec2& pad) { ImVec2 pos; // Legend x coordinate if (ImPlot3D::ImHasFlag(loc, ImPlot3DLocation_West) && !ImPlot3D::ImHasFlag(loc, ImPlot3DLocation_East)) pos.x = outer_rect.Min.x + pad.x; else if (!ImPlot3D::ImHasFlag(loc, ImPlot3DLocation_West) && ImPlot3D::ImHasFlag(loc, ImPlot3DLocation_East)) pos.x = outer_rect.Max.x - pad.x - inner_size.x; else pos.x = outer_rect.GetCenter().x - inner_size.x * 0.5f; // Legend y coordinate if (ImPlot3D::ImHasFlag(loc, ImPlot3DLocation_North) && !ImPlot3D::ImHasFlag(loc, ImPlot3DLocation_South)) pos.y = outer_rect.Min.y + pad.y; else if (!ImPlot3D::ImHasFlag(loc, ImPlot3DLocation_North) && ImPlot3D::ImHasFlag(loc, ImPlot3DLocation_South)) pos.y = outer_rect.Max.y - pad.y - inner_size.y; else pos.y = outer_rect.GetCenter().y - inner_size.y * 0.5f; pos.x = IM_ROUND(pos.x); pos.y = IM_ROUND(pos.y); return pos; }
O1
cpp
ImPlot3D::GetLocationPos(ImRect const&, ImVec2 const&, int, ImVec2 const&): movl %edx, %eax andl $0xc, %eax cmpl $0x4, %eax jne 0x4b593 movss (%rdi), %xmm0 addss (%rcx), %xmm0 jmp 0x4b5c4 cmpl $0x8, %eax jne 0x4b5a7 movss 0x8(%rdi), %xmm0 subss (%rcx), %xmm0 subss (%rsi), %xmm0 jmp 0x4b5c4 movss (%rdi), %xmm0 addss 0x8(%rdi), %xmm0 movss 0x243a68(%rip), %xmm1 # 0x28f020 mulss %xmm1, %xmm0 mulss (%rsi), %xmm1 subss %xmm1, %xmm0 andl $0x3, %edx cmpl $0x1, %edx jne 0x4b5d8 movss 0x4(%rdi), %xmm1 addss 0x4(%rcx), %xmm1 jmp 0x4b60d cmpl $0x2, %edx jne 0x4b5ee movss 0xc(%rdi), %xmm1 subss 0x4(%rcx), %xmm1 subss 0x4(%rsi), %xmm1 jmp 0x4b60d movss 0x4(%rdi), %xmm1 addss 0xc(%rdi), %xmm1 movss 0x243a20(%rip), %xmm2 # 0x28f020 mulss %xmm2, %xmm1 mulss 0x4(%rsi), %xmm2 subss %xmm2, %xmm1 unpcklps %xmm1, %xmm0 # xmm0 = xmm0[0],xmm1[0],xmm0[1],xmm1[1] addps 0x248dd9(%rip), %xmm0 # 0x2943f0 cvttps2dq %xmm0, %xmm0 cvtdq2ps %xmm0, %xmm0 retq
_ZN8ImPlot3D14GetLocationPosERK6ImRectRK6ImVec2iS5_: mov eax, edx and eax, 0Ch cmp eax, 4 jnz short loc_4B593 movss xmm0, dword ptr [rdi] addss xmm0, dword ptr [rcx] jmp short loc_4B5C4 loc_4B593: cmp eax, 8 jnz short loc_4B5A7 movss xmm0, dword ptr [rdi+8] subss xmm0, dword ptr [rcx] subss xmm0, dword ptr [rsi] jmp short loc_4B5C4 loc_4B5A7: movss xmm0, dword ptr [rdi] addss xmm0, dword ptr [rdi+8] movss xmm1, dword ptr cs:xmmword_28F020 mulss xmm0, xmm1 mulss xmm1, dword ptr [rsi] subss xmm0, xmm1 loc_4B5C4: and edx, 3 cmp edx, 1 jnz short loc_4B5D8 movss xmm1, dword ptr [rdi+4] addss xmm1, dword ptr [rcx+4] jmp short loc_4B60D loc_4B5D8: cmp edx, 2 jnz short loc_4B5EE movss xmm1, dword ptr [rdi+0Ch] subss xmm1, dword ptr [rcx+4] subss xmm1, dword ptr [rsi+4] jmp short loc_4B60D loc_4B5EE: movss xmm1, dword ptr [rdi+4] addss xmm1, dword ptr [rdi+0Ch] movss xmm2, dword ptr cs:xmmword_28F020 mulss xmm1, xmm2 mulss xmm2, dword ptr [rsi+4] subss xmm1, xmm2 loc_4B60D: unpcklps xmm0, xmm1 addps xmm0, cs:xmmword_2943F0 cvttps2dq xmm0, xmm0 cvtdq2ps xmm0, xmm0 retn
__m128 ImPlot3D::GetLocationPos(unsigned int *a1, float *a2, char a3, float *a4) { int v4; // eax __m128 v5; // xmm0 int v6; // edx __m128 v7; // xmm1 v4 = a3 & 0xC; if ( v4 == 4 ) { v5 = (__m128)*a1; v5.m128_f32[0] = v5.m128_f32[0] + *a4; } else if ( v4 == 8 ) { v5 = (__m128)a1[2]; v5.m128_f32[0] = (float)(v5.m128_f32[0] - *a4) - *a2; } else { v5 = (__m128)*a1; v5.m128_f32[0] = (float)((float)(v5.m128_f32[0] + *((float *)a1 + 2)) * 0.5) - (float)(0.5 * *a2); } v6 = a3 & 3; if ( v6 == 1 ) { v7 = (__m128)a1[1]; v7.m128_f32[0] = v7.m128_f32[0] + a4[1]; } else if ( v6 == 2 ) { v7 = (__m128)a1[3]; v7.m128_f32[0] = (float)(v7.m128_f32[0] - a4[1]) - a2[1]; } else { v7 = (__m128)a1[1]; v7.m128_f32[0] = (float)((float)(v7.m128_f32[0] + *((float *)a1 + 3)) * 0.5) - (float)(0.5 * a2[1]); } return _mm_cvtepi32_ps(_mm_cvttps_epi32(_mm_add_ps(_mm_unpacklo_ps(v5, v7), (__m128)xmmword_2943F0))); }
GetLocationPos: MOV EAX,EDX AND EAX,0xc CMP EAX,0x4 JNZ 0x0014b593 MOVSS XMM0,dword ptr [RDI] ADDSS XMM0,dword ptr [RCX] JMP 0x0014b5c4 LAB_0014b593: CMP EAX,0x8 JNZ 0x0014b5a7 MOVSS XMM0,dword ptr [RDI + 0x8] SUBSS XMM0,dword ptr [RCX] SUBSS XMM0,dword ptr [RSI] JMP 0x0014b5c4 LAB_0014b5a7: MOVSS XMM0,dword ptr [RDI] ADDSS XMM0,dword ptr [RDI + 0x8] MOVSS XMM1,dword ptr [0x0038f020] MULSS XMM0,XMM1 MULSS XMM1,dword ptr [RSI] SUBSS XMM0,XMM1 LAB_0014b5c4: AND EDX,0x3 CMP EDX,0x1 JNZ 0x0014b5d8 MOVSS XMM1,dword ptr [RDI + 0x4] ADDSS XMM1,dword ptr [RCX + 0x4] JMP 0x0014b60d LAB_0014b5d8: CMP EDX,0x2 JNZ 0x0014b5ee MOVSS XMM1,dword ptr [RDI + 0xc] SUBSS XMM1,dword ptr [RCX + 0x4] SUBSS XMM1,dword ptr [RSI + 0x4] JMP 0x0014b60d LAB_0014b5ee: MOVSS XMM1,dword ptr [RDI + 0x4] ADDSS XMM1,dword ptr [RDI + 0xc] MOVSS XMM2,dword ptr [0x0038f020] MULSS XMM1,XMM2 MULSS XMM2,dword ptr [RSI + 0x4] SUBSS XMM1,XMM2 LAB_0014b60d: UNPCKLPS XMM0,XMM1 ADDPS XMM0,xmmword ptr [0x003943f0] CVTTPS2DQ XMM0,XMM0 CVTDQ2PS XMM0,XMM0 RET
/* ImPlot3D::GetLocationPos(ImRect const&, ImVec2 const&, int, ImVec2 const&) */ int8 ImPlot3D::GetLocationPos(ImRect *param_1,ImVec2 *param_2,int param_3,ImVec2 *param_4) { float fVar1; float fVar2; if ((param_3 & 0xcU) == 4) { fVar1 = *(float *)param_1 + *(float *)param_4; } else if ((param_3 & 0xcU) == 8) { fVar1 = (*(float *)(param_1 + 8) - *(float *)param_4) - *(float *)param_2; } else { fVar1 = (*(float *)param_1 + *(float *)(param_1 + 8)) * DAT_0038f020 - DAT_0038f020 * *(float *)param_2; } if ((param_3 & 3U) == 1) { fVar2 = *(float *)(param_1 + 4) + *(float *)(param_4 + 4); } else if ((param_3 & 3U) == 2) { fVar2 = (*(float *)(param_1 + 0xc) - *(float *)(param_4 + 4)) - *(float *)(param_2 + 4); } else { fVar2 = (*(float *)(param_1 + 4) + *(float *)(param_1 + 0xc)) * DAT_0038f020 - DAT_0038f020 * *(float *)(param_2 + 4); } return CONCAT44((float)(int)(fVar2 + DAT_003943f0._4_4_),(float)(int)(fVar1 + (float)DAT_003943f0) ); }
27,587
my_coll_parser_scan_rule
eloqsql/strings/ctype-uca.c
static int my_coll_parser_scan_rule(MY_COLL_RULE_PARSER *p) { if (!my_coll_parser_scan_term(p, MY_COLL_LEXEM_RESET) || !my_coll_parser_scan_reset_sequence(p)) return 0; /* Scan the first required shift command */ if (!my_coll_parser_scan_shift(p)) return my_coll_parser_expected_error(p, MY_COLL_LEXEM_SHIFT); /* Scan the first shift sequence */ if (!my_coll_parser_scan_shift_sequence(p)) return 0; /* Scan subsequent shift rules */ while (my_coll_parser_scan_shift(p)) { if (!my_coll_parser_scan_shift_sequence(p)) return 0; } return 1; }
O0
c
my_coll_parser_scan_rule: pushq %rbp movq %rsp, %rbp subq $0x10, %rsp movq %rdi, -0x10(%rbp) movq -0x10(%rbp), %rdi movl $0x4, %esi callq 0x5d300 cmpl $0x0, %eax je 0x5d27d movq -0x10(%rbp), %rdi callq 0x5d560 cmpl $0x0, %eax jne 0x5d286 movl $0x0, -0x4(%rbp) jmp 0x5d2ee movq -0x10(%rbp), %rdi callq 0x5d610 cmpl $0x0, %eax jne 0x5d2a7 movq -0x10(%rbp), %rdi movl $0x1, %esi callq 0x5d670 movl %eax, -0x4(%rbp) jmp 0x5d2ee movq -0x10(%rbp), %rdi callq 0x5d6c0 cmpl $0x0, %eax jne 0x5d2be movl $0x0, -0x4(%rbp) jmp 0x5d2ee jmp 0x5d2c0 movq -0x10(%rbp), %rdi callq 0x5d610 cmpl $0x0, %eax je 0x5d2e7 movq -0x10(%rbp), %rdi callq 0x5d6c0 cmpl $0x0, %eax jne 0x5d2e5 movl $0x0, -0x4(%rbp) jmp 0x5d2ee jmp 0x5d2c0 movl $0x1, -0x4(%rbp) movl -0x4(%rbp), %eax addq $0x10, %rsp popq %rbp retq nopw (%rax,%rax)
my_coll_parser_scan_rule: push rbp mov rbp, rsp sub rsp, 10h mov [rbp+var_10], rdi mov rdi, [rbp+var_10] mov esi, 4 call my_coll_parser_scan_term cmp eax, 0 jz short loc_5D27D mov rdi, [rbp+var_10] call my_coll_parser_scan_reset_sequence cmp eax, 0 jnz short loc_5D286 loc_5D27D: mov [rbp+var_4], 0 jmp short loc_5D2EE loc_5D286: mov rdi, [rbp+var_10] call my_coll_parser_scan_shift cmp eax, 0 jnz short loc_5D2A7 mov rdi, [rbp+var_10] mov esi, 1 call my_coll_parser_expected_error mov [rbp+var_4], eax jmp short loc_5D2EE loc_5D2A7: mov rdi, [rbp+var_10] call my_coll_parser_scan_shift_sequence cmp eax, 0 jnz short loc_5D2BE mov [rbp+var_4], 0 jmp short loc_5D2EE loc_5D2BE: jmp short $+2 loc_5D2C0: mov rdi, [rbp+var_10] call my_coll_parser_scan_shift cmp eax, 0 jz short loc_5D2E7 mov rdi, [rbp+var_10] call my_coll_parser_scan_shift_sequence cmp eax, 0 jnz short loc_5D2E5 mov [rbp+var_4], 0 jmp short loc_5D2EE loc_5D2E5: jmp short loc_5D2C0 loc_5D2E7: mov [rbp+var_4], 1 loc_5D2EE: mov eax, [rbp+var_4] add rsp, 10h pop rbp retn
long long my_coll_parser_scan_rule(long long a1) { if ( (unsigned int)my_coll_parser_scan_term(a1, 4LL) && (unsigned int)my_coll_parser_scan_reset_sequence(a1) ) { if ( (unsigned int)my_coll_parser_scan_shift(a1) ) { if ( (unsigned int)my_coll_parser_scan_shift_sequence(a1) ) { while ( (unsigned int)my_coll_parser_scan_shift(a1) ) { if ( !(unsigned int)my_coll_parser_scan_shift_sequence(a1) ) return 0; } return 1; } else { return 0; } } else { return (unsigned int)my_coll_parser_expected_error(a1, 1LL); } } else { return 0; } }
my_coll_parser_scan_rule: PUSH RBP MOV RBP,RSP SUB RSP,0x10 MOV qword ptr [RBP + -0x10],RDI MOV RDI,qword ptr [RBP + -0x10] MOV ESI,0x4 CALL 0x0015d300 CMP EAX,0x0 JZ 0x0015d27d MOV RDI,qword ptr [RBP + -0x10] CALL 0x0015d560 CMP EAX,0x0 JNZ 0x0015d286 LAB_0015d27d: MOV dword ptr [RBP + -0x4],0x0 JMP 0x0015d2ee LAB_0015d286: MOV RDI,qword ptr [RBP + -0x10] CALL 0x0015d610 CMP EAX,0x0 JNZ 0x0015d2a7 MOV RDI,qword ptr [RBP + -0x10] MOV ESI,0x1 CALL 0x0015d670 MOV dword ptr [RBP + -0x4],EAX JMP 0x0015d2ee LAB_0015d2a7: MOV RDI,qword ptr [RBP + -0x10] CALL 0x0015d6c0 CMP EAX,0x0 JNZ 0x0015d2be MOV dword ptr [RBP + -0x4],0x0 JMP 0x0015d2ee LAB_0015d2be: JMP 0x0015d2c0 LAB_0015d2c0: MOV RDI,qword ptr [RBP + -0x10] CALL 0x0015d610 CMP EAX,0x0 JZ 0x0015d2e7 MOV RDI,qword ptr [RBP + -0x10] CALL 0x0015d6c0 CMP EAX,0x0 JNZ 0x0015d2e5 MOV dword ptr [RBP + -0x4],0x0 JMP 0x0015d2ee LAB_0015d2e5: JMP 0x0015d2c0 LAB_0015d2e7: MOV dword ptr [RBP + -0x4],0x1 LAB_0015d2ee: MOV EAX,dword ptr [RBP + -0x4] ADD RSP,0x10 POP RBP RET
int4 my_coll_parser_scan_rule(int8 param_1) { int iVar1; int4 local_c; iVar1 = my_coll_parser_scan_term(param_1,4); if ((iVar1 == 0) || (iVar1 = my_coll_parser_scan_reset_sequence(param_1), iVar1 == 0)) { local_c = 0; } else { iVar1 = my_coll_parser_scan_shift(param_1); if (iVar1 == 0) { local_c = my_coll_parser_expected_error(param_1,1); } else { iVar1 = my_coll_parser_scan_shift_sequence(param_1); if (iVar1 == 0) { local_c = 0; } else { do { iVar1 = my_coll_parser_scan_shift(param_1); if (iVar1 == 0) { return 1; } iVar1 = my_coll_parser_scan_shift_sequence(param_1); } while (iVar1 != 0); local_c = 0; } } } return local_c; }
27,588
vemit_tap
eloqsql/unittest/mytap/tap.c
static void vemit_tap(int pass, char const *fmt, va_list ap) { fprintf(tapout, "%sok %d%s", pass ? "" : "not ", ++g_test.last, (fmt && *fmt) ? " - " : ""); if (fmt && *fmt) vfprintf(tapout, fmt, ap); fflush(tapout); }
O0
c
vemit_tap: pushq %rbp movq %rsp, %rbp subq $0x30, %rsp movl %edi, -0x4(%rbp) movq %rsi, -0x10(%rbp) movq %rdx, -0x18(%rbp) movq 0x1e2ff6(%rip), %rax # 0x2bcfd0 movq (%rax), %rax movq %rax, -0x30(%rbp) movl -0x4(%rbp), %edx leaq 0x79e54(%rip), %rax # 0x153e3f leaq 0x7dcbb(%rip), %rcx # 0x157cad cmpl $0x0, %edx cmovneq %rcx, %rax movq %rax, -0x28(%rbp) movl 0xba0611(%rip), %eax # 0xc7a614 addl $0x1, %eax movl %eax, -0x20(%rbp) movl %eax, 0xba0605(%rip) # 0xc7a614 xorl %eax, %eax cmpq $0x0, -0x10(%rbp) movb %al, -0x19(%rbp) je 0xda02b movq -0x10(%rbp), %rax movsbl (%rax), %eax cmpl $0x0, %eax setne %al movb %al, -0x19(%rbp) movl -0x20(%rbp), %ecx movq -0x28(%rbp), %rdx movq -0x30(%rbp), %rdi movb -0x19(%rbp), %sil leaq 0x7dc6c(%rip), %r8 # 0x157cad leaq 0x79dfc(%rip), %rax # 0x153e44 testb $0x1, %sil cmovneq %rax, %r8 leaq 0x79dde(%rip), %rsi # 0x153e35 movb $0x0, %al callq 0x2a180 cmpq $0x0, -0x10(%rbp) je 0xda088 movq -0x10(%rbp), %rax movsbl (%rax), %eax cmpl $0x0, %eax je 0xda088 movq 0x1e2f58(%rip), %rax # 0x2bcfd0 movq (%rax), %rdi movq -0x10(%rbp), %rsi movq -0x18(%rbp), %rdx callq 0x2a7e0 movq 0x1e2f41(%rip), %rax # 0x2bcfd0 movq (%rax), %rdi callq 0x2a3e0 addq $0x30, %rsp popq %rbp retq nopl (%rax)
vemit_tap: push rbp mov rbp, rsp sub rsp, 30h mov [rbp+var_4], edi mov [rbp+var_10], rsi mov [rbp+var_18], rdx mov rax, cs:stdout_ptr mov rax, [rax] mov [rbp+var_30], rax mov edx, [rbp+var_4] lea rax, aNot; "not " lea rcx, asc_157CA9+4; "" cmp edx, 0 cmovnz rax, rcx mov [rbp+var_28], rax mov eax, cs:dword_C7A614 add eax, 1 mov [rbp+var_20], eax mov cs:dword_C7A614, eax xor eax, eax cmp [rbp+var_10], 0 mov [rbp+var_19], al jz short loc_DA02B mov rax, [rbp+var_10] movsx eax, byte ptr [rax] cmp eax, 0 setnz al mov [rbp+var_19], al loc_DA02B: mov ecx, [rbp+var_20] mov rdx, [rbp+var_28] mov rdi, [rbp+var_30] mov sil, [rbp+var_19] lea r8, asc_157CA9+4; "" lea rax, asc_153E44; " - " test sil, 1 cmovnz r8, rax lea rsi, aSokDS; "%sok %d%s" mov al, 0 call _fprintf cmp [rbp+var_10], 0 jz short loc_DA088 mov rax, [rbp+var_10] movsx eax, byte ptr [rax] cmp eax, 0 jz short loc_DA088 mov rax, cs:stdout_ptr mov rdi, [rax] mov rsi, [rbp+var_10] mov rdx, [rbp+var_18] call _vfprintf loc_DA088: mov rax, cs:stdout_ptr mov rdi, [rax] call _fflush add rsp, 30h pop rbp retn
long long vemit_tap(int a1, _BYTE *a2, long long a3) { const char *v3; // rax const char *v4; // r8 int v6; // [rsp+10h] [rbp-20h] bool v7; // [rsp+17h] [rbp-19h] v3 = "not "; if ( a1 ) v3 = ""; v6 = ++dword_C7A614; v7 = 0; if ( a2 ) v7 = *a2 != 0; v4 = ""; if ( v7 ) v4 = " - "; fprintf(stdout, "%sok %d%s", v3, v6, v4); if ( a2 && *a2 ) vfprintf(stdout, a2, a3); return fflush(stdout); }
vemit_tap: 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 RAX,qword ptr [0x003bcfd0] MOV RAX,qword ptr [RAX] MOV qword ptr [RBP + -0x30],RAX MOV EDX,dword ptr [RBP + -0x4] LEA RAX,[0x253e3f] LEA RCX,[0x257cad] CMP EDX,0x0 CMOVNZ RAX,RCX MOV qword ptr [RBP + -0x28],RAX MOV EAX,dword ptr [0x00d7a614] ADD EAX,0x1 MOV dword ptr [RBP + -0x20],EAX MOV dword ptr [0x00d7a614],EAX XOR EAX,EAX CMP qword ptr [RBP + -0x10],0x0 MOV byte ptr [RBP + -0x19],AL JZ 0x001da02b MOV RAX,qword ptr [RBP + -0x10] MOVSX EAX,byte ptr [RAX] CMP EAX,0x0 SETNZ AL MOV byte ptr [RBP + -0x19],AL LAB_001da02b: MOV ECX,dword ptr [RBP + -0x20] MOV RDX,qword ptr [RBP + -0x28] MOV RDI,qword ptr [RBP + -0x30] MOV SIL,byte ptr [RBP + -0x19] LEA R8,[0x257cad] LEA RAX,[0x253e44] TEST SIL,0x1 CMOVNZ R8,RAX LEA RSI,[0x253e35] MOV AL,0x0 CALL 0x0012a180 CMP qword ptr [RBP + -0x10],0x0 JZ 0x001da088 MOV RAX,qword ptr [RBP + -0x10] MOVSX EAX,byte ptr [RAX] CMP EAX,0x0 JZ 0x001da088 MOV RAX,qword ptr [0x003bcfd0] MOV RDI,qword ptr [RAX] MOV RSI,qword ptr [RBP + -0x10] MOV RDX,qword ptr [RBP + -0x18] CALL 0x0012a7e0 LAB_001da088: MOV RAX,qword ptr [0x003bcfd0] MOV RDI,qword ptr [RAX] CALL 0x0012a3e0 ADD RSP,0x30 POP RBP RET
void vemit_tap(int param_1,char *param_2,__gnuc_va_list param_3) { int *puVar1; int *puVar2; bool bVar3; puVar1 = &DAT_00253e3f; if (param_1 != 0) { puVar1 = &DAT_00257cad; } DAT_00d7a614 = DAT_00d7a614 + 1; bVar3 = false; if (param_2 != (char *)0x0) { bVar3 = *param_2 != '\0'; } puVar2 = &DAT_00257cad; if (bVar3) { puVar2 = &DAT_00253e44; } fprintf(*(FILE **)PTR_stdout_003bcfd0,"%sok %d%s",puVar1,(ulong)DAT_00d7a614,puVar2); if ((param_2 != (char *)0x0) && (*param_2 != '\0')) { vfprintf(*(FILE **)PTR_stdout_003bcfd0,param_2,param_3); } fflush(*(FILE **)PTR_stdout_003bcfd0); return; }
27,589
nglog::InstallFailureSignalHandler()
ng-log[P]ng-log/src/signalhandler.cc
void InstallFailureSignalHandler() { #ifdef HAVE_SIGACTION // Build the sigaction struct. struct sigaction sig_action; memset(&sig_action, 0, sizeof(sig_action)); sigemptyset(&sig_action.sa_mask); sig_action.sa_flags |= SA_SIGINFO; sig_action.sa_sigaction = &FailureSignalHandler; for (auto kFailureSignal : kFailureSignals) { CHECK_ERR(sigaction(kFailureSignal.number, &sig_action, nullptr)); } kFailureSignalHandlerInstalled = true; #elif defined(NGLOG_OS_WINDOWS) for (size_t i = 0; i < ARRAYSIZE(kFailureSignals); ++i) { CHECK_NE(signal(kFailureSignals[i].number, &FailureSignalHandler), SIG_ERR); } kFailureSignalHandlerInstalled = true; #endif // HAVE_SIGACTION }
O2
cpp
nglog::InstallFailureSignalHandler(): pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x118, %rsp # imm = 0x118 leaq 0x80(%rsp), %rbx xorl %r13d, %r13d movl $0x98, %edx movq %rbx, %rdi xorl %esi, %esi callq 0x83b0 leaq 0x88(%rsp), %r14 movq %r14, %rdi callq 0x8860 orb $0x4, 0x80(%r14) leaq -0x88(%rip), %rax # 0x29173 movq %rax, -0x8(%r14) leaq 0x18a8a(%rip), %r14 # 0x41c90 leaq 0x20(%rsp), %r15 pushq $0x3 popq %rbp leaq 0x5eba(%rip), %r12 # 0x2f0cf cmpq $0x60, %r13 je 0x29286 movl (%r13,%r14), %edi movq %rbx, %rsi xorl %edx, %edx callq 0x8870 cmpl $-0x1, %eax je 0x29235 addq $0x10, %r13 jmp 0x29215 leaq -0x1159c(%rip), %rax # 0x17ca0 movq %rax, 0x10(%rsp) andq $0x0, 0x18(%rsp) movups 0x10(%rsp), %xmm0 movups %xmm0, (%rsp) movq %r15, %rdi leaq 0x5e28(%rip), %rsi # 0x2f082 movl $0x18b, %edx # imm = 0x18B movl %ebp, %ecx xorl %r8d, %r8d callq 0x1899a movq %r15, %rdi callq 0x17f4e movq %rax, %rdi movq %r12, %rsi callq 0x8680 movq %r15, %rdi callq 0x189bc jmp 0x2922f addq $0x118, %rsp # imm = 0x118 popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq movq %rax, %rbx leaq 0x20(%rsp), %rdi callq 0x189bc movq %rbx, %rdi callq 0x8c30 movq %rax, %rdi callq 0x142b9
_ZN5nglog27InstallFailureSignalHandlerEv: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 118h lea rbx, [rsp+148h+var_C8] xor r13d, r13d mov edx, 98h mov rdi, rbx xor esi, esi call _memset lea r14, [rsp+148h+var_C0] mov rdi, r14 call _sigemptyset or byte ptr [r14+80h], 4 lea rax, _ZN5nglog12_GLOBAL__N_120FailureSignalHandlerEiP9siginfo_tPv; nglog::`anonymous namespace'::FailureSignalHandler(int,siginfo_t *,void *) mov [r14-8], rax lea r14, _ZN5nglog12_GLOBAL__N_115kFailureSignalsE; nglog::`anonymous namespace'::kFailureSignals lea r15, [rsp+148h+var_128] push 3 pop rbp lea r12, aSigactionKfail; "sigaction(kFailureSignal.number, &sig_a"... loc_29215: cmp r13, 60h ; '`' jz short loc_29286 mov edi, [r13+r14+0] mov rsi, rbx xor edx, edx call _sigaction cmp eax, 0FFFFFFFFh jz short loc_29235 loc_2922F: add r13, 10h jmp short loc_29215 loc_29235: lea rax, _ZN5nglog10LogMessage9SendToLogEv; nglog::LogMessage::SendToLog(void) mov qword ptr [rsp+148h+var_138], rax and qword ptr [rsp+148h+var_138+8], 0 movups xmm0, [rsp+148h+var_138] movups [rsp+148h+var_148], xmm0 mov rdi, r15 lea rsi, aWorkspaceLlm4b_3; "/workspace/llm4binary/github/2025_star3"... mov edx, 18Bh mov ecx, ebp xor r8d, r8d call _ZN5nglog15ErrnoLogMessageC2EPKciNS_11LogSeverityElMNS_10LogMessageEFvvE; nglog::ErrnoLogMessage::ErrnoLogMessage(char const*,int,nglog::LogSeverity,long,void (nglog::LogMessage::*)(void)) mov rdi, r15; this call _ZN5nglog10LogMessage6streamEv; nglog::LogMessage::stream(void) mov rdi, rax mov rsi, r12 call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*) mov rdi, r15; this call _ZN5nglog15ErrnoLogMessageD2Ev; nglog::ErrnoLogMessage::~ErrnoLogMessage() jmp short loc_2922F loc_29286: add rsp, 118h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn mov rbx, rax lea rdi, [rsp+arg_18]; this call _ZN5nglog15ErrnoLogMessageD2Ev; nglog::ErrnoLogMessage::~ErrnoLogMessage() mov rdi, rbx call __Unwind_Resume mov rdi, rax call __clang_call_terminate
void nglog::InstallFailureSignalHandler(nglog *this) { long long v1; // r13 long long v2; // r9 long long v3; // rax _QWORD v4[12]; // [rsp+20h] [rbp-128h] BYREF long long ( *v5)(int, long long, long long); // [rsp+80h] [rbp-C8h] BYREF _BYTE v6[128]; // [rsp+88h] [rbp-C0h] BYREF char v7; // [rsp+108h] [rbp-40h] v1 = 0LL; memset(&v5, 0LL, 152LL); sigemptyset(v6); v7 |= 4u; v5 = nglog::`anonymous namespace'::FailureSignalHandler; while ( v1 != 96 ) { if ( (unsigned int)sigaction( *(unsigned int *)((char *)&nglog::`anonymous namespace'::kFailureSignals + v1), &v5, 0LL) == -1 ) { nglog::ErrnoLogMessage::ErrnoLogMessage( v4, (long long)"/workspace/llm4binary/github/2025_star3/ng-log[P]ng-log/src/signalhandler.cc", 0x18Bu, 3u, 0LL, v2, (unsigned long long)nglog::LogMessage::SendToLog); v3 = nglog::LogMessage::stream((nglog::LogMessage *)v4); std::operator<<<std::char_traits<char>>(v3, "sigaction(kFailureSignal.number, &sig_action, nullptr)"); nglog::ErrnoLogMessage::~ErrnoLogMessage((nglog::ErrnoLogMessage *)v4); } v1 += 16LL; } }
InstallFailureSignalHandler: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x118 LEA RBX,[RSP + 0x80] XOR R13D,R13D MOV EDX,0x98 MOV RDI,RBX XOR ESI,ESI CALL 0x001083b0 LEA R14,[RSP + 0x88] MOV RDI,R14 CALL 0x00108860 OR byte ptr [R14 + 0x80],0x4 LEA RAX,[0x129173] MOV qword ptr [R14 + -0x8],RAX LEA R14,[0x141c90] LEA R15,[RSP + 0x20] PUSH 0x3 POP RBP LEA R12,[0x12f0cf] LAB_00129215: CMP R13,0x60 JZ 0x00129286 MOV EDI,dword ptr [R13 + R14*0x1] MOV RSI,RBX XOR EDX,EDX CALL 0x00108870 CMP EAX,-0x1 JZ 0x00129235 LAB_0012922f: ADD R13,0x10 JMP 0x00129215 LAB_00129235: LEA RAX,[0x117ca0] MOV qword ptr [RSP + 0x10],RAX AND qword ptr [RSP + 0x18],0x0 MOVUPS XMM0,xmmword ptr [RSP + 0x10] MOVUPS xmmword ptr [RSP],XMM0 MOV RDI,R15 LEA RSI,[0x12f082] MOV EDX,0x18b MOV ECX,EBP XOR R8D,R8D CALL 0x0011899a LAB_00129269: MOV RDI,R15 CALL 0x00117f4e MOV RDI,RAX MOV RSI,R12 CALL 0x00108680 LAB_0012927c: MOV RDI,R15 CALL 0x001189bc JMP 0x0012922f LAB_00129286: ADD RSP,0x118 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
/* nglog::InstallFailureSignalHandler() */ void nglog::InstallFailureSignalHandler(void) { int iVar1; ostream *poVar2; int8 in_R9; long lVar3; LogMessage local_128 [96]; sigaction local_c8; memset(&local_c8,0,0x98); sigemptyset(&local_c8.sa_mask); local_c8.sa_flags._0_1_ = (byte)local_c8.sa_flags | 4; local_c8.__sigaction_handler.sa_handler = (anonymous_namespace)::FailureSignalHandler; for (lVar3 = 0; lVar3 != 0x60; lVar3 = lVar3 + 0x10) { iVar1 = sigaction(*(int *)((long)&(anonymous_namespace)::kFailureSignals + lVar3),&local_c8, (sigaction *)0x0); if (iVar1 == -1) { ErrnoLogMessage::ErrnoLogMessage ((ErrnoLogMessage *)local_128, "/workspace/llm4binary/github/2025_star3/ng-log[P]ng-log/src/signalhandler.cc", 0x18b,3,0,in_R9,0x117ca0,0); /* try { // try from 00129269 to 0012927b has its CatchHandler @ 00129298 */ poVar2 = (ostream *)LogMessage::stream(local_128); std::operator<<(poVar2,"sigaction(kFailureSignal.number, &sig_action, nullptr)"); ErrnoLogMessage::~ErrnoLogMessage((ErrnoLogMessage *)local_128); } } return; }
27,590
nglog::InstallFailureSignalHandler()
ng-log[P]ng-log/src/signalhandler.cc
void InstallFailureSignalHandler() { #ifdef HAVE_SIGACTION // Build the sigaction struct. struct sigaction sig_action; memset(&sig_action, 0, sizeof(sig_action)); sigemptyset(&sig_action.sa_mask); sig_action.sa_flags |= SA_SIGINFO; sig_action.sa_sigaction = &FailureSignalHandler; for (auto kFailureSignal : kFailureSignals) { CHECK_ERR(sigaction(kFailureSignal.number, &sig_action, nullptr)); } kFailureSignalHandlerInstalled = true; #elif defined(NGLOG_OS_WINDOWS) for (size_t i = 0; i < ARRAYSIZE(kFailureSignals); ++i) { CHECK_NE(signal(kFailureSignals[i].number, &FailureSignalHandler), SIG_ERR); } kFailureSignalHandlerInstalled = true; #endif // HAVE_SIGACTION }
O3
cpp
nglog::InstallFailureSignalHandler(): pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x118, %rsp # imm = 0x118 leaq 0x80(%rsp), %rbx xorl %r13d, %r13d movl $0x98, %edx movq %rbx, %rdi xorl %esi, %esi callq 0x8330 leaq 0x88(%rsp), %r14 movq %r14, %rdi callq 0x8800 orb $0x4, 0x80(%r14) leaq -0x88(%rip), %rax # 0x2ea8d movq %rax, -0x8(%r14) leaq 0x16140(%rip), %rbp # 0x44c60 leaq 0x64cb(%rip), %r14 # 0x34ff2 leaq 0x20(%rsp), %r15 leaq 0x650c(%rip), %r12 # 0x3503f movl (%r13,%rbp), %edi movq %rbx, %rsi xorl %edx, %edx callq 0x8810 cmpl $-0x1, %eax je 0x2eb53 addq $0x10, %r13 cmpq $0x60, %r13 jne 0x2eb33 jmp 0x2ebab leaq -0x151b8(%rip), %rax # 0x199a2 movq %rax, 0x10(%rsp) movq $0x0, 0x18(%rsp) movups 0x10(%rsp), %xmm0 movups %xmm0, (%rsp) movq %r15, %rdi movq %r14, %rsi movl $0x18b, %edx # imm = 0x18B movl $0x3, %ecx xorl %r8d, %r8d callq 0x1ab10 movq %r15, %rdi callq 0x19e6a movl $0x36, %edx movq %rax, %rdi movq %r12, %rsi callq 0x8720 movq %r15, %rdi callq 0x1ab7a jmp 0x2eb47 addq $0x118, %rsp # imm = 0x118 popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq movq %rax, %rbx leaq 0x20(%rsp), %rdi callq 0x1ab7a movq %rbx, %rdi callq 0x8bb0 movq %rax, %rdi callq 0x15c57
_ZN5nglog27InstallFailureSignalHandlerEv: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 118h lea rbx, [rsp+148h+var_C8] xor r13d, r13d mov edx, 98h mov rdi, rbx xor esi, esi call _memset lea r14, [rsp+148h+var_C0] mov rdi, r14 call _sigemptyset or byte ptr [r14+80h], 4 lea rax, _ZN5nglog12_GLOBAL__N_120FailureSignalHandlerEiP9siginfo_tPv; nglog::`anonymous namespace'::FailureSignalHandler(int,siginfo_t *,void *) mov [r14-8], rax lea rbp, _ZN5nglog12_GLOBAL__N_115kFailureSignalsE; nglog::`anonymous namespace'::kFailureSignals lea r14, aWorkspaceLlm4b_2; "/workspace/llm4binary/github/2025_star3"... lea r15, [rsp+148h+var_128] lea r12, aSigactionKfail; "sigaction(kFailureSignal.number, &sig_a"... loc_2EB33: mov edi, [r13+rbp+0] mov rsi, rbx xor edx, edx call _sigaction cmp eax, 0FFFFFFFFh jz short loc_2EB53 loc_2EB47: add r13, 10h cmp r13, 60h ; '`' jnz short loc_2EB33 jmp short loc_2EBAB loc_2EB53: lea rax, _ZN5nglog10LogMessage9SendToLogEv; nglog::LogMessage::SendToLog(void) mov qword ptr [rsp+148h+var_138], rax mov qword ptr [rsp+148h+var_138+8], 0 movups xmm0, [rsp+148h+var_138] movups [rsp+148h+var_148], xmm0 mov rdi, r15 mov rsi, r14 mov edx, 18Bh mov ecx, 3 xor r8d, r8d call _ZN5nglog15ErrnoLogMessageC2EPKciNS_11LogSeverityElMNS_10LogMessageEFvvE; nglog::ErrnoLogMessage::ErrnoLogMessage(char const*,int,nglog::LogSeverity,long,void (nglog::LogMessage::*)(void)) mov rdi, r15; this call _ZN5nglog10LogMessage6streamEv; nglog::LogMessage::stream(void) mov edx, 36h ; '6' mov rdi, rax mov rsi, r12 call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long) mov rdi, r15; this call _ZN5nglog15ErrnoLogMessageD2Ev; nglog::ErrnoLogMessage::~ErrnoLogMessage() jmp short loc_2EB47 loc_2EBAB: add rsp, 118h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn mov rbx, rax lea rdi, [rsp+arg_18]; this call _ZN5nglog15ErrnoLogMessageD2Ev; nglog::ErrnoLogMessage::~ErrnoLogMessage() mov rdi, rbx call __Unwind_Resume mov rdi, rax call __clang_call_terminate
void nglog::InstallFailureSignalHandler(nglog *this) { long long v1; // r13 long long v2; // r9 long long v3; // rax _QWORD v4[12]; // [rsp+20h] [rbp-128h] BYREF long long ( *v5)(int, long long, long long); // [rsp+80h] [rbp-C8h] BYREF _BYTE v6[128]; // [rsp+88h] [rbp-C0h] BYREF char v7; // [rsp+108h] [rbp-40h] v1 = 0LL; memset(&v5, 0LL, 152LL); sigemptyset(v6); v7 |= 4u; v5 = nglog::`anonymous namespace'::FailureSignalHandler; do { if ( (unsigned int)sigaction( *(unsigned int *)((char *)&nglog::`anonymous namespace'::kFailureSignals + v1), &v5, 0LL) == -1 ) { nglog::ErrnoLogMessage::ErrnoLogMessage( v4, (nglog::tools *)"/workspace/llm4binary/github/2025_star3/ng-log[P]ng-log/src/signalhandler.cc", 395, 3, 0LL, v2, (long long)nglog::LogMessage::SendToLog, 0LL); v3 = nglog::LogMessage::stream((nglog::LogMessage *)v4); std::__ostream_insert<char,std::char_traits<char>>( v3, "sigaction(kFailureSignal.number, &sig_action, nullptr)", 54LL); nglog::ErrnoLogMessage::~ErrnoLogMessage((nglog::ErrnoLogMessage *)v4); } v1 += 16LL; } while ( v1 != 96 ); }
InstallFailureSignalHandler: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x118 LEA RBX,[RSP + 0x80] XOR R13D,R13D MOV EDX,0x98 MOV RDI,RBX XOR ESI,ESI CALL 0x00108330 LEA R14,[RSP + 0x88] MOV RDI,R14 CALL 0x00108800 OR byte ptr [R14 + 0x80],0x4 LEA RAX,[0x12ea8d] MOV qword ptr [R14 + -0x8],RAX LEA RBP,[0x144c60] LEA R14,[0x134ff2] LEA R15,[RSP + 0x20] LEA R12,[0x13503f] LAB_0012eb33: MOV EDI,dword ptr [R13 + RBP*0x1] MOV RSI,RBX XOR EDX,EDX CALL 0x00108810 CMP EAX,-0x1 JZ 0x0012eb53 LAB_0012eb47: ADD R13,0x10 CMP R13,0x60 JNZ 0x0012eb33 JMP 0x0012ebab LAB_0012eb53: LEA RAX,[0x1199a2] MOV qword ptr [RSP + 0x10],RAX MOV qword ptr [RSP + 0x18],0x0 MOVUPS XMM0,xmmword ptr [RSP + 0x10] MOVUPS xmmword ptr [RSP],XMM0 MOV RDI,R15 MOV RSI,R14 MOV EDX,0x18b MOV ECX,0x3 XOR R8D,R8D CALL 0x0011ab10 LAB_0012eb89: MOV RDI,R15 CALL 0x00119e6a MOV EDX,0x36 MOV RDI,RAX MOV RSI,R12 CALL 0x00108720 LAB_0012eba1: MOV RDI,R15 CALL 0x0011ab7a JMP 0x0012eb47 LAB_0012ebab: ADD RSP,0x118 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
/* nglog::InstallFailureSignalHandler() */ void nglog::InstallFailureSignalHandler(void) { int iVar1; ostream *poVar2; int8 in_R9; long lVar3; LogMessage local_128 [96]; sigaction local_c8; lVar3 = 0; memset(&local_c8,0,0x98); sigemptyset(&local_c8.sa_mask); local_c8.sa_flags._0_1_ = (byte)local_c8.sa_flags | 4; local_c8.__sigaction_handler.sa_handler = (anonymous_namespace)::FailureSignalHandler; do { iVar1 = sigaction(*(int *)((long)&(anonymous_namespace)::kFailureSignals + lVar3),&local_c8, (sigaction *)0x0); if (iVar1 == -1) { ErrnoLogMessage::ErrnoLogMessage ((ErrnoLogMessage *)local_128, "/workspace/llm4binary/github/2025_star3/ng-log[P]ng-log/src/signalhandler.cc", 0x18b,3,0,in_R9,0x1199a2,0); /* try { // try from 0012eb89 to 0012eba0 has its CatchHandler @ 0012ebbd */ poVar2 = (ostream *)LogMessage::stream(local_128); std::__ostream_insert<char,std::char_traits<char>> (poVar2,"sigaction(kFailureSignal.number, &sig_action, nullptr)",0x36); ErrnoLogMessage::~ErrnoLogMessage((ErrnoLogMessage *)local_128); } lVar3 = lVar3 + 0x10; } while (lVar3 != 0x60); return; }
27,591
vector_f_sub_generic
tsotchke[P]eshkol/src/core/utils/vector.c
static void vector_f_sub_generic(VectorF* result, const VectorF* a, const VectorF* b) { assert(result != NULL); assert(a != NULL); assert(b != NULL); assert(a->dim == b->dim); assert(result->dim >= a->dim); for (size_t i = 0; i < a->dim; i++) { result->data[i] = a->data[i] - b->data[i]; } }
O3
c
vector_f_sub_generic: pushq %rax testq %rdi, %rdi je 0x4904 testq %rsi, %rsi je 0x4923 testq %rdx, %rdx je 0x4942 movq 0x10(%rsi), %rax cmpq 0x10(%rdx), %rax jne 0x4961 cmpq %rax, 0x10(%rdi) jb 0x4980 testq %rax, %rax je 0x4902 xorl %ecx, %ecx movss (%rsi,%rcx,4), %xmm0 subss (%rdx,%rcx,4), %xmm0 movss %xmm0, (%rdi,%rcx,4) incq %rcx cmpq %rcx, %rax jne 0x48eb popq %rax retq leaq 0x3c3b(%rip), %rdi # 0x8546 leaq 0x3dde(%rip), %rsi # 0x86f0 leaq 0x47c8(%rip), %rcx # 0x90e1 movl $0x13f, %edx # imm = 0x13F callq 0x1090 leaq 0x2819(%rip), %rdi # 0x7143 leaq 0x3dbf(%rip), %rsi # 0x86f0 leaq 0x47a9(%rip), %rcx # 0x90e1 movl $0x140, %edx # imm = 0x140 callq 0x1090 leaq 0x2a6c(%rip), %rdi # 0x73b5 leaq 0x3da0(%rip), %rsi # 0x86f0 leaq 0x478a(%rip), %rcx # 0x90e1 movl $0x141, %edx # imm = 0x141 callq 0x1090 leaq 0x3fe6(%rip), %rdi # 0x894e leaq 0x3d81(%rip), %rsi # 0x86f0 leaq 0x476b(%rip), %rcx # 0x90e1 movl $0x142, %edx # imm = 0x142 callq 0x1090 leaq 0x4701(%rip), %rdi # 0x9088 leaq 0x3d62(%rip), %rsi # 0x86f0 leaq 0x474c(%rip), %rcx # 0x90e1 movl $0x143, %edx # imm = 0x143 callq 0x1090
vector_f_sub_generic: push rax test rdi, rdi jz short loc_4904 test rsi, rsi jz short loc_4923 test rdx, rdx jz short loc_4942 mov rax, [rsi+10h] cmp rax, [rdx+10h] jnz loc_4961 cmp [rdi+10h], rax jb loc_4980 test rax, rax jz short loc_4902 xor ecx, ecx loc_48EB: movss xmm0, dword ptr [rsi+rcx*4] subss xmm0, dword ptr [rdx+rcx*4] movss dword ptr [rdi+rcx*4], xmm0 inc rcx cmp rax, rcx jnz short loc_48EB loc_4902: pop rax retn loc_4904: lea rdi, aResultNull; "result != NULL" lea rsi, aWorkspaceLlm4b_1; "/workspace/llm4binary/github/2025_star3"... lea rcx, aVoidVectorFSub; "void vector_f_sub_generic(VectorF *, co"... mov edx, 13Fh call ___assert_fail loc_4923: lea rdi, aArenaNull+4; "a != NULL" lea rsi, aWorkspaceLlm4b_1; "/workspace/llm4binary/github/2025_star3"... lea rcx, aVoidVectorFSub; "void vector_f_sub_generic(VectorF *, co"... mov edx, 140h call ___assert_fail loc_4942: lea rdi, aBNull; "b != NULL" lea rsi, aWorkspaceLlm4b_1; "/workspace/llm4binary/github/2025_star3"... lea rcx, aVoidVectorFSub; "void vector_f_sub_generic(VectorF *, co"... mov edx, 141h call ___assert_fail loc_4961: lea rdi, aADimBDim; "a->dim == b->dim" lea rsi, aWorkspaceLlm4b_1; "/workspace/llm4binary/github/2025_star3"... lea rcx, aVoidVectorFSub; "void vector_f_sub_generic(VectorF *, co"... mov edx, 142h call ___assert_fail loc_4980: lea rdi, aResultDimADim; "result->dim >= a->dim" lea rsi, aWorkspaceLlm4b_1; "/workspace/llm4binary/github/2025_star3"... lea rcx, aVoidVectorFSub; "void vector_f_sub_generic(VectorF *, co"... mov edx, 143h call ___assert_fail
void __spoils<rdx,rcx,r8,r9,r10,r11,xmm0,xmm4,xmm5> vector_f_sub_generic(long long a1, long long a2, long long a3) { unsigned long long v3; // rax long long i; // rcx if ( !a1 ) __assert_fail( "result != NULL", "/workspace/llm4binary/github/2025_star3/tsotchke[P]eshkol/src/core/utils/vector.c", 319LL, "void vector_f_sub_generic(VectorF *, const VectorF *, const VectorF *)"); if ( !a2 ) __assert_fail( "a != NULL", "/workspace/llm4binary/github/2025_star3/tsotchke[P]eshkol/src/core/utils/vector.c", 320LL, "void vector_f_sub_generic(VectorF *, const VectorF *, const VectorF *)"); if ( !a3 ) __assert_fail( "b != NULL", "/workspace/llm4binary/github/2025_star3/tsotchke[P]eshkol/src/core/utils/vector.c", 321LL, "void vector_f_sub_generic(VectorF *, const VectorF *, const VectorF *)"); v3 = *(_QWORD *)(a2 + 16); if ( v3 != *(_QWORD *)(a3 + 16) ) __assert_fail( "a->dim == b->dim", "/workspace/llm4binary/github/2025_star3/tsotchke[P]eshkol/src/core/utils/vector.c", 322LL, "void vector_f_sub_generic(VectorF *, const VectorF *, const VectorF *)"); if ( *(_QWORD *)(a1 + 16) < v3 ) __assert_fail( "result->dim >= a->dim", "/workspace/llm4binary/github/2025_star3/tsotchke[P]eshkol/src/core/utils/vector.c", 323LL, "void vector_f_sub_generic(VectorF *, const VectorF *, const VectorF *)"); if ( v3 ) { for ( i = 0LL; i != v3; ++i ) *(float *)(a1 + 4 * i) = *(float *)(a2 + 4 * i) - *(float *)(a3 + 4 * i); } }
vector_f_sub_generic: PUSH RAX TEST RDI,RDI JZ 0x00104904 TEST RSI,RSI JZ 0x00104923 TEST RDX,RDX JZ 0x00104942 MOV RAX,qword ptr [RSI + 0x10] CMP RAX,qword ptr [RDX + 0x10] JNZ 0x00104961 CMP qword ptr [RDI + 0x10],RAX JC 0x00104980 TEST RAX,RAX JZ 0x00104902 XOR ECX,ECX LAB_001048eb: MOVSS XMM0,dword ptr [RSI + RCX*0x4] SUBSS XMM0,dword ptr [RDX + RCX*0x4] MOVSS dword ptr [RDI + RCX*0x4],XMM0 INC RCX CMP RAX,RCX JNZ 0x001048eb LAB_00104902: POP RAX RET LAB_00104904: LEA RDI,[0x108546] LEA RSI,[0x1086f0] LEA RCX,[0x1090e1] MOV EDX,0x13f CALL 0x00101090 LAB_00104923: LEA RDI,[0x107143] LEA RSI,[0x1086f0] LEA RCX,[0x1090e1] MOV EDX,0x140 CALL 0x00101090 LAB_00104942: LEA RDI,[0x1073b5] LEA RSI,[0x1086f0] LEA RCX,[0x1090e1] MOV EDX,0x141 CALL 0x00101090 LAB_00104961: LEA RDI,[0x10894e] LEA RSI,[0x1086f0] LEA RCX,[0x1090e1] MOV EDX,0x142 CALL 0x00101090 LAB_00104980: LEA RDI,[0x109088] LEA RSI,[0x1086f0] LEA RCX,[0x1090e1] MOV EDX,0x143 CALL 0x00101090
int8 vector_f_sub_generic(long param_1,long param_2,long param_3) { ulong uVar1; int8 in_RAX; ulong uVar2; if (param_1 == 0) { /* WARNING: Subroutine does not return */ __assert_fail("result != NULL", "/workspace/llm4binary/github/2025_star3/tsotchke[P]eshkol/src/core/utils/vector.c" ,0x13f,"void vector_f_sub_generic(VectorF *, const VectorF *, const VectorF *)"); } if (param_2 == 0) { /* WARNING: Subroutine does not return */ __assert_fail("a != NULL", "/workspace/llm4binary/github/2025_star3/tsotchke[P]eshkol/src/core/utils/vector.c" ,0x140,"void vector_f_sub_generic(VectorF *, const VectorF *, const VectorF *)"); } if (param_3 == 0) { /* WARNING: Subroutine does not return */ __assert_fail("b != NULL", "/workspace/llm4binary/github/2025_star3/tsotchke[P]eshkol/src/core/utils/vector.c" ,0x141,"void vector_f_sub_generic(VectorF *, const VectorF *, const VectorF *)"); } uVar1 = *(ulong *)(param_2 + 0x10); if (uVar1 == *(ulong *)(param_3 + 0x10)) { if (uVar1 <= *(ulong *)(param_1 + 0x10)) { if (uVar1 != 0) { uVar2 = 0; do { *(float *)(param_1 + uVar2 * 4) = *(float *)(param_2 + uVar2 * 4) - *(float *)(param_3 + uVar2 * 4); uVar2 = uVar2 + 1; } while (uVar1 != uVar2); } return in_RAX; } /* WARNING: Subroutine does not return */ __assert_fail("result->dim >= a->dim", "/workspace/llm4binary/github/2025_star3/tsotchke[P]eshkol/src/core/utils/vector.c" ,0x143,"void vector_f_sub_generic(VectorF *, const VectorF *, const VectorF *)"); } /* WARNING: Subroutine does not return */ __assert_fail("a->dim == b->dim", "/workspace/llm4binary/github/2025_star3/tsotchke[P]eshkol/src/core/utils/vector.c", 0x142,"void vector_f_sub_generic(VectorF *, const VectorF *, const VectorF *)"); }
27,592
translog_write_file_header
eloqsql/storage/maria/ma_loghandler.c
static my_bool translog_write_file_header() { TRANSLOG_FILE *file; ulonglong timestamp; uchar page_buff[TRANSLOG_PAGE_SIZE], *page= page_buff; my_bool rc; DBUG_ENTER("translog_write_file_header"); /* file tag */ memcpy(page, maria_trans_file_magic, sizeof(maria_trans_file_magic)); page+= sizeof(maria_trans_file_magic); /* timestamp */ timestamp= my_hrtime().val; int8store(page, timestamp); page+= 8; /* maria version */ int4store(page, TRANSLOG_VERSION_ID); page+= 4; /* mysql version (MYSQL_VERSION_ID) */ int4store(page, log_descriptor.server_version); page+= 4; /* server ID */ int4store(page, log_descriptor.server_id); page+= 4; /* loghandler page_size */ int2store(page, TRANSLOG_PAGE_SIZE - 1); page+= 2; /* file number */ int3store(page, LSN_FILE_NO(log_descriptor.horizon)); page+= 3; lsn_store(page, LSN_IMPOSSIBLE); page+= LSN_STORE_SIZE; memset(page, TRANSLOG_FILLER, sizeof(page_buff) - (page- page_buff)); file= get_current_logfile(); rc= my_pwrite(file->handler.file, page_buff, sizeof(page_buff), 0, log_write_flags) != 0; /* Dropping the flag in such way can make false alarm: signalling than the file in not sync when it is sync, but the situation is quite rare and protections with mutexes give much more overhead to the whole engine */ file->is_sync= 0; DBUG_RETURN(rc); }
O0
c
translog_write_file_header: pushq %rbp movq %rsp, %rbp subq $0x2070, %rsp # imm = 0x2070 movq %fs:0x28, %rax movq %rax, -0x8(%rbp) leaq -0x2010(%rbp), %rax movq %rax, -0x2028(%rbp) movq -0x2028(%rbp), %rax movq 0x2a4924(%rip), %rcx # 0x2f3718 movq %rcx, (%rax) movl 0x2a4923(%rip), %ecx # 0x2f3720 movl %ecx, 0x8(%rax) movq -0x2028(%rbp), %rax addq $0xc, %rax movq %rax, -0x2028(%rbp) callq 0x11bf00 movq %rax, -0x2038(%rbp) movq -0x2038(%rbp), %rax movq %rax, -0x2020(%rbp) movq -0x2028(%rbp), %rax movq %rax, -0x2040(%rbp) movq -0x2020(%rbp), %rcx movq -0x2040(%rbp), %rax movq %rcx, (%rax) movq -0x2028(%rbp), %rax addq $0x8, %rax movq %rax, -0x2028(%rbp) movq -0x2028(%rbp), %rax movq %rax, -0x2048(%rbp) movq -0x2048(%rbp), %rax movl $0x2710, (%rax) # imm = 0x2710 movq -0x2028(%rbp), %rax addq $0x4, %rax movq %rax, -0x2028(%rbp) movq -0x2028(%rbp), %rax movq %rax, -0x2050(%rbp) movl 0x45f8b6(%rip), %ecx # 0x4ae754 movq -0x2050(%rbp), %rax movl %ecx, (%rax) movq -0x2028(%rbp), %rax addq $0x4, %rax movq %rax, -0x2028(%rbp) movq -0x2028(%rbp), %rax movq %rax, -0x2058(%rbp) movl 0x45f88b(%rip), %ecx # 0x4ae758 movq -0x2058(%rbp), %rax movl %ecx, (%rax) movq -0x2028(%rbp), %rax addq $0x4, %rax movq %rax, -0x2028(%rbp) movq -0x2028(%rbp), %rax movq %rax, -0x2060(%rbp) movq -0x2060(%rbp), %rax movw $0x1fff, (%rax) # imm = 0x1FFF movq -0x2028(%rbp), %rax addq $0x2, %rax movq %rax, -0x2028(%rbp) movq 0xc6046d(%rip), %rax # 0xcaf388 sarq $0x20, %rax movb %al, %cl movq -0x2028(%rbp), %rax movb %cl, (%rax) movq 0xc60457(%rip), %rax # 0xcaf388 sarq $0x20, %rax shrl $0x8, %eax movb %al, %cl movq -0x2028(%rbp), %rax movb %cl, 0x1(%rax) movq 0xc6043d(%rip), %rax # 0xcaf388 sarq $0x20, %rax shrl $0x10, %eax movb %al, %cl movq -0x2028(%rbp), %rax movb %cl, 0x2(%rax) movq -0x2028(%rbp), %rax addq $0x3, %rax movq %rax, -0x2028(%rbp) jmp 0x4ef72 movq -0x2028(%rbp), %rax movb $0x0, (%rax) movq -0x2028(%rbp), %rax movb $0x0, 0x1(%rax) movq -0x2028(%rbp), %rax movb $0x0, 0x2(%rax) jmp 0x4ef94 movq -0x2028(%rbp), %rax addq $0x3, %rax movq %rax, -0x2068(%rbp) movq -0x2068(%rbp), %rax movl $0x0, (%rax) jmp 0x4efb5 movq -0x2028(%rbp), %rax addq $0x7, %rax movq %rax, -0x2028(%rbp) movq -0x2028(%rbp), %rdi movq -0x2028(%rbp), %rax leaq -0x2010(%rbp), %rcx subq %rcx, %rax movl $0x2000, %edx # imm = 0x2000 subq %rax, %rdx movl $0xff, %esi callq 0x2a2f0 callq 0x52980 movq %rax, -0x2018(%rbp) movq -0x2018(%rbp), %rax movl 0x18(%rax), %edi leaq -0x2010(%rbp), %rsi movl $0x2000, %edx # imm = 0x2000 xorl %eax, %eax movl %eax, %ecx movl $0x34, %r8d callq 0x1206c0 cmpq $0x0, %rax setne %al andb $0x1, %al movzbl %al, %eax movb %al, -0x2029(%rbp) movq -0x2018(%rbp), %rax movb $0x0, 0x51(%rax) movb -0x2029(%rbp), %al movb %al, -0x2069(%rbp) movq %fs:0x28, %rax movq -0x8(%rbp), %rcx cmpq %rcx, %rax jne 0x4f06c movb -0x2069(%rbp), %al addq $0x2070, %rsp # imm = 0x2070 popq %rbp retq callq 0x2a290 nopw %cs:(%rax,%rax)
translog_write_file_header: push rbp mov rbp, rsp sub rsp, 2070h mov rax, fs:28h mov [rbp+var_8], rax lea rax, [rbp+var_2010] mov [rbp+var_2028], rax mov rax, [rbp+var_2028] mov rcx, cs:maria_trans_file_magic mov [rax], rcx mov ecx, cs:dword_2F3720 mov [rax+8], ecx mov rax, [rbp+var_2028] add rax, 0Ch mov [rbp+var_2028], rax call my_hrtime mov [rbp+var_2038], rax mov rax, [rbp+var_2038] mov [rbp+var_2020], rax mov rax, [rbp+var_2028] mov [rbp+var_2040], rax mov rcx, [rbp+var_2020] mov rax, [rbp+var_2040] mov [rax], rcx mov rax, [rbp+var_2028] add rax, 8 mov [rbp+var_2028], rax mov rax, [rbp+var_2028] mov [rbp+var_2048], rax mov rax, [rbp+var_2048] mov dword ptr [rax], 2710h mov rax, [rbp+var_2028] add rax, 4 mov [rbp+var_2028], rax mov rax, [rbp+var_2028] mov [rbp+var_2050], rax mov ecx, cs:dword_4AE754 mov rax, [rbp+var_2050] mov [rax], ecx mov rax, [rbp+var_2028] add rax, 4 mov [rbp+var_2028], rax mov rax, [rbp+var_2028] mov [rbp+var_2058], rax mov ecx, cs:dword_4AE758 mov rax, [rbp+var_2058] mov [rax], ecx mov rax, [rbp+var_2028] add rax, 4 mov [rbp+var_2028], rax mov rax, [rbp+var_2028] mov [rbp+var_2060], rax mov rax, [rbp+var_2060] mov word ptr [rax], 1FFFh mov rax, [rbp+var_2028] add rax, 2 mov [rbp+var_2028], rax mov rax, cs:qword_CAF388 sar rax, 20h mov cl, al mov rax, [rbp+var_2028] mov [rax], cl mov rax, cs:qword_CAF388 sar rax, 20h shr eax, 8 mov cl, al mov rax, [rbp+var_2028] mov [rax+1], cl mov rax, cs:qword_CAF388 sar rax, 20h shr eax, 10h mov cl, al mov rax, [rbp+var_2028] mov [rax+2], cl mov rax, [rbp+var_2028] add rax, 3 mov [rbp+var_2028], rax jmp short $+2 loc_4EF72: mov rax, [rbp+var_2028] mov byte ptr [rax], 0 mov rax, [rbp+var_2028] mov byte ptr [rax+1], 0 mov rax, [rbp+var_2028] mov byte ptr [rax+2], 0 jmp short $+2 loc_4EF94: mov rax, [rbp+var_2028] add rax, 3 mov [rbp+var_2068], rax mov rax, [rbp+var_2068] mov dword ptr [rax], 0 jmp short $+2 loc_4EFB5: mov rax, [rbp+var_2028] add rax, 7 mov [rbp+var_2028], rax mov rdi, [rbp+var_2028] mov rax, [rbp+var_2028] lea rcx, [rbp+var_2010] sub rax, rcx mov edx, 2000h sub rdx, rax mov esi, 0FFh call _memset call get_current_logfile mov [rbp+var_2018], rax mov rax, [rbp+var_2018] mov edi, [rax+18h] lea rsi, [rbp+var_2010] mov edx, 2000h xor eax, eax mov ecx, eax mov r8d, 34h ; '4' call my_pwrite cmp rax, 0 setnz al and al, 1 movzx eax, al mov [rbp+var_2029], al mov rax, [rbp+var_2018] mov byte ptr [rax+51h], 0 mov al, [rbp+var_2029] mov [rbp+var_2069], al mov rax, fs:28h mov rcx, [rbp+var_8] cmp rax, rcx jnz short loc_4F06C mov al, [rbp+var_2069] add rsp, 2070h pop rbp retn loc_4F06C: call ___stack_chk_fail
bool translog_write_file_header(long long a1, long long a2, long long a3) { long long v3; // rax long long current_logfile; // [rsp+58h] [rbp-2018h] long long v6; // [rsp+60h] [rbp-2010h] BYREF int v7; // [rsp+68h] [rbp-2008h] long long v8; // [rsp+6Ch] [rbp-2004h] int v9; // [rsp+74h] [rbp-1FFCh] int v10; // [rsp+78h] [rbp-1FF8h] int v11; // [rsp+7Ch] [rbp-1FF4h] __int16 v12; // [rsp+80h] [rbp-1FF0h] __int16 v13; // [rsp+82h] [rbp-1FEEh] char v14; // [rsp+84h] [rbp-1FECh] char v15; // [rsp+85h] [rbp-1FEBh] char v16; // [rsp+86h] [rbp-1FEAh] char v17; // [rsp+87h] [rbp-1FE9h] int v18; // [rsp+88h] [rbp-1FE8h] _BYTE v19[8164]; // [rsp+8Ch] [rbp-1FE4h] BYREF *(_QWORD *)&v19[8156] = __readfsqword(0x28u); v6 = maria_trans_file_magic; v7 = dword_2F3720; v8 = my_hrtime(a1, a2, a3); v9 = 10000; v10 = dword_4AE754; v11 = dword_4AE758; v12 = 0x1FFF; v13 = WORD2(qword_CAF388); v14 = BYTE6(qword_CAF388); v15 = 0; v16 = 0; v17 = 0; v18 = 0; memset(v19, 255LL, 0x2000 - (v19 - (_BYTE *)&v6)); current_logfile = get_current_logfile(); v3 = my_pwrite(*(unsigned int *)(current_logfile + 24), &v6, 0x2000LL, 0LL, 52LL); *(_BYTE *)(current_logfile + 81) = 0; return v3 != 0; }
translog_write_file_header: PUSH RBP MOV RBP,RSP SUB RSP,0x2070 MOV RAX,qword ptr FS:[0x28] MOV qword ptr [RBP + -0x8],RAX LEA RAX,[RBP + -0x2010] MOV qword ptr [RBP + -0x2028],RAX MOV RAX,qword ptr [RBP + -0x2028] MOV RCX,qword ptr [0x003f3718] MOV qword ptr [RAX],RCX MOV ECX,dword ptr [0x003f3720] MOV dword ptr [RAX + 0x8],ECX MOV RAX,qword ptr [RBP + -0x2028] ADD RAX,0xc MOV qword ptr [RBP + -0x2028],RAX CALL 0x0021bf00 MOV qword ptr [RBP + -0x2038],RAX MOV RAX,qword ptr [RBP + -0x2038] MOV qword ptr [RBP + -0x2020],RAX MOV RAX,qword ptr [RBP + -0x2028] MOV qword ptr [RBP + -0x2040],RAX MOV RCX,qword ptr [RBP + -0x2020] MOV RAX,qword ptr [RBP + -0x2040] MOV qword ptr [RAX],RCX MOV RAX,qword ptr [RBP + -0x2028] ADD RAX,0x8 MOV qword ptr [RBP + -0x2028],RAX MOV RAX,qword ptr [RBP + -0x2028] MOV qword ptr [RBP + -0x2048],RAX MOV RAX,qword ptr [RBP + -0x2048] MOV dword ptr [RAX],0x2710 MOV RAX,qword ptr [RBP + -0x2028] ADD RAX,0x4 MOV qword ptr [RBP + -0x2028],RAX MOV RAX,qword ptr [RBP + -0x2028] MOV qword ptr [RBP + -0x2050],RAX MOV ECX,dword ptr [0x005ae754] MOV RAX,qword ptr [RBP + -0x2050] MOV dword ptr [RAX],ECX MOV RAX,qword ptr [RBP + -0x2028] ADD RAX,0x4 MOV qword ptr [RBP + -0x2028],RAX MOV RAX,qword ptr [RBP + -0x2028] MOV qword ptr [RBP + -0x2058],RAX MOV ECX,dword ptr [0x005ae758] MOV RAX,qword ptr [RBP + -0x2058] MOV dword ptr [RAX],ECX MOV RAX,qword ptr [RBP + -0x2028] ADD RAX,0x4 MOV qword ptr [RBP + -0x2028],RAX MOV RAX,qword ptr [RBP + -0x2028] MOV qword ptr [RBP + -0x2060],RAX MOV RAX,qword ptr [RBP + -0x2060] MOV word ptr [RAX],0x1fff MOV RAX,qword ptr [RBP + -0x2028] ADD RAX,0x2 MOV qword ptr [RBP + -0x2028],RAX MOV RAX,qword ptr [0x00daf388] SAR RAX,0x20 MOV CL,AL MOV RAX,qword ptr [RBP + -0x2028] MOV byte ptr [RAX],CL MOV RAX,qword ptr [0x00daf388] SAR RAX,0x20 SHR EAX,0x8 MOV CL,AL MOV RAX,qword ptr [RBP + -0x2028] MOV byte ptr [RAX + 0x1],CL MOV RAX,qword ptr [0x00daf388] SAR RAX,0x20 SHR EAX,0x10 MOV CL,AL MOV RAX,qword ptr [RBP + -0x2028] MOV byte ptr [RAX + 0x2],CL MOV RAX,qword ptr [RBP + -0x2028] ADD RAX,0x3 MOV qword ptr [RBP + -0x2028],RAX JMP 0x0014ef72 LAB_0014ef72: MOV RAX,qword ptr [RBP + -0x2028] MOV byte ptr [RAX],0x0 MOV RAX,qword ptr [RBP + -0x2028] MOV byte ptr [RAX + 0x1],0x0 MOV RAX,qword ptr [RBP + -0x2028] MOV byte ptr [RAX + 0x2],0x0 JMP 0x0014ef94 LAB_0014ef94: MOV RAX,qword ptr [RBP + -0x2028] ADD RAX,0x3 MOV qword ptr [RBP + -0x2068],RAX MOV RAX,qword ptr [RBP + -0x2068] MOV dword ptr [RAX],0x0 JMP 0x0014efb5 LAB_0014efb5: MOV RAX,qword ptr [RBP + -0x2028] ADD RAX,0x7 MOV qword ptr [RBP + -0x2028],RAX MOV RDI,qword ptr [RBP + -0x2028] MOV RAX,qword ptr [RBP + -0x2028] LEA RCX,[RBP + -0x2010] SUB RAX,RCX MOV EDX,0x2000 SUB RDX,RAX MOV ESI,0xff CALL 0x0012a2f0 CALL 0x00152980 MOV qword ptr [RBP + -0x2018],RAX MOV RAX,qword ptr [RBP + -0x2018] MOV EDI,dword ptr [RAX + 0x18] LEA RSI,[RBP + -0x2010] MOV EDX,0x2000 XOR EAX,EAX MOV ECX,EAX MOV R8D,0x34 CALL 0x002206c0 CMP RAX,0x0 SETNZ AL AND AL,0x1 MOVZX EAX,AL MOV byte ptr [RBP + -0x2029],AL MOV RAX,qword ptr [RBP + -0x2018] MOV byte ptr [RAX + 0x51],0x0 MOV AL,byte ptr [RBP + -0x2029] MOV byte ptr [RBP + -0x2069],AL MOV RAX,qword ptr FS:[0x28] MOV RCX,qword ptr [RBP + -0x8] CMP RAX,RCX JNZ 0x0014f06c MOV AL,byte ptr [RBP + -0x2069] ADD RSP,0x2070 POP RBP RET LAB_0014f06c: CALL 0x0012a290
int8 translog_write_file_header(void) { long lVar1; long lVar2; long in_FS_OFFSET; int8 local_2018; int4 local_2010; int8 local_200c; int4 local_2004; int4 local_2000; int4 local_1ffc; int2 local_1ff8; int1 local_1ff6; int1 local_1ff5; int1 local_1ff4; int1 local_1ff3; int1 local_1ff2; int1 local_1ff1; int4 local_1ff0; int1 auStack_1fec [8156]; long local_10; local_10 = *(long *)(in_FS_OFFSET + 0x28); local_2018 = maria_trans_file_magic; local_2010 = DAT_003f3720; local_200c = my_hrtime(); local_2004 = 10000; local_2000 = DAT_005ae754; local_1ffc = DAT_005ae758; local_1ff8 = 0x1fff; local_1ff6 = (int1)((ulong)DAT_00daf388 >> 0x20); local_1ff5 = (int1)((ulong)DAT_00daf388 >> 0x28); local_1ff4 = (int1)((ulong)DAT_00daf388 >> 0x30); local_1ff3 = 0; local_1ff2 = 0; local_1ff1 = 0; local_1ff0 = 0; memset(auStack_1fec,0xff,0x2000 - ((long)auStack_1fec - (long)&local_2018)); lVar1 = get_current_logfile(); lVar2 = my_pwrite(*(int4 *)(lVar1 + 0x18),&local_2018,0x2000,0,0x34); *(int1 *)(lVar1 + 0x51) = 0; if (*(long *)(in_FS_OFFSET + 0x28) == local_10) { return CONCAT71((int7)((ulong)*(long *)(in_FS_OFFSET + 0x28) >> 8),lVar2 != 0); } /* WARNING: Subroutine does not return */ __stack_chk_fail(); }
27,593
my_init_large_pages
eloqsql/mysys/my_largepage.c
int my_init_large_pages(my_bool super_large_pages) { #ifdef _WIN32 if (!my_obtain_privilege(SE_LOCK_MEMORY_NAME)) { my_printf_error(EE_PERM_LOCK_MEMORY, "Lock Pages in memory access rights required for use with" " large-pages, see https://mariadb.com/kb/en/library/" "mariadb-memory-allocation/#huge-pages", MYF(MY_WME)); } my_large_page_size= GetLargePageMinimum(); #endif my_use_large_pages= 1; my_get_large_page_sizes(my_large_page_sizes); #ifndef HAVE_LARGE_PAGES my_printf_error(EE_OUTOFMEMORY, "No large page support on this platform", MYF(MY_WME)); #endif #ifdef HAVE_SOLARIS_LARGE_PAGES /* tell the kernel that we want to use 4/256MB page for heap storage and also for the stack. We use 4 MByte as default and if the super-large-page is set we increase it to 256 MByte. 256 MByte is for server installations with GBytes of RAM memory where the MySQL Server will have page caches and other memory regions measured in a number of GBytes. We use as big pages as possible which isn't bigger than the above desired page sizes. */ int nelem= 0; size_t max_desired_page_size= (super_large_pages ? 256 : 4) * 1024 * 1024; size_t max_page_size= my_next_large_page_size(max_desired_page_size, &nelem); if (max_page_size > 0) { struct memcntl_mha mpss; mpss.mha_cmd= MHA_MAPSIZE_BSSBRK; mpss.mha_pagesize= max_page_size; mpss.mha_flags= 0; if (memcntl(NULL, 0, MC_HAT_ADVISE, (caddr_t) &mpss, 0, 0)) { my_error(EE_MEMCNTL, MYF(ME_WARNING | ME_ERROR_LOG_ONLY), "MC_HAT_ADVISE", "MHA_MAPSIZE_BSSBRK"); } mpss.mha_cmd= MHA_MAPSIZE_STACK; if (memcntl(NULL, 0, MC_HAT_ADVISE, (caddr_t) &mpss, 0, 0)) { my_error(EE_MEMCNTL, MYF(ME_WARNING | ME_ERROR_LOG_ONLY), "MC_HAT_ADVISE", "MHA_MAPSIZE_STACK"); } } #endif /* HAVE_SOLARIS_LARGE_PAGES */ return 0; }
O3
c
my_init_large_pages: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx pushq %rax movb $0x1, 0xb6107f(%rip) # 0xc08930 leaq 0x34e4e(%rip), %rdi # 0xdc706 callq 0x29490 testq %rax, %rax je 0xa79c8 movq %rax, %rbx leaq 0x34e4f(%rip), %r14 # 0xdc71f leaq 0xb61069(%rip), %r13 # 0xc08940 xorl %r15d, %r15d movq %rbx, %rdi callq 0x294a0 testq %rax, %rax je 0xa7980 movq %rax, %r12 movl %r15d, -0x2c(%rbp) movslq %r15d, %r15 leaq 0x13(%r12), %rsi movl $0xa, %edx movq %r14, %rdi callq 0x291b0 testl %eax, %eax jne 0xa7963 addq $0x1d, %r12 movq %r12, %rdi xorl %esi, %esi movl $0xa, %edx callq 0x29070 shlq $0xa, %rax movq %rax, (%r13,%r15,8) leaq -0x1(%rax), %rcx testq %rcx, %rax je 0xa7969 movl $0x480, %edx # imm = 0x480 xorl %edi, %edi leaq 0x34dec(%rip), %rsi # 0xdc72a movq %rax, %rcx xorl %eax, %eax callq 0x9e0dd movq $0x0, (%r13,%r15,8) movq %rbx, %rdi callq 0x294a0 movq %rax, %r12 testq %rax, %rax jne 0xa78f5 jmp 0xa797c movl -0x2c(%rbp), %r15d jmp 0xa7970 movl -0x2c(%rbp), %r15d incl %r15d cmpl $0x7, %r15d jle 0xa78da jmp 0xa7980 movl -0x2c(%rbp), %r15d movq %rbx, %rdi callq 0x29470 testl %eax, %eax je 0xa79ab callq 0x29790 movl (%rax), %ecx leaq 0x34d6c(%rip), %rdx # 0xdc706 movl $0x4, %esi movl $0x4, %edi xorl %eax, %eax callq 0x9dfc3 movslq %r15d, %rsi leaq 0xb60f8b(%rip), %rdi # 0xc08940 leaq 0x529(%rip), %rcx # 0xa7ee5 movl $0x8, %edx callq 0x295c0 jmp 0xa79e7 callq 0x29790 movl (%rax), %ecx leaq 0x34d30(%rip), %rdx # 0xdc706 movl $0x4, %esi movl $0xc, %edi xorl %eax, %eax callq 0x9dfc3 xorl %eax, %eax addq $0x8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
my_init_large_pages: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx push rax mov cs:my_use_large_pages, 1 lea rdi, aSysKernelMmHug; "/sys/kernel/mm/hugepages" call _opendir test rax, rax jz loc_A79C8 mov rbx, rax lea r14, aHugepages; "hugepages-" lea r13, my_large_page_sizes xor r15d, r15d loc_A78DA: mov rdi, rbx call _readdir64 test rax, rax jz loc_A7980 mov r12, rax mov [rbp+var_2C], r15d movsxd r15, r15d loc_A78F5: lea rsi, [r12+13h] mov edx, 0Ah mov rdi, r14 call _strncmp test eax, eax jnz short loc_A7963 add r12, 1Dh mov rdi, r12 xor esi, esi mov edx, 0Ah call ___isoc23_strtoul shl rax, 0Ah mov [r13+r15*8+0], rax lea rcx, [rax-1] test rax, rcx jz short loc_A7969 mov edx, 480h xor edi, edi lea rsi, aNonPowerOf2Lar; "non-power of 2 large page size (%zu) fo"... mov rcx, rax xor eax, eax call my_printf_error mov qword ptr [r13+r15*8+0], 0 mov rdi, rbx call _readdir64 mov r12, rax test rax, rax jnz short loc_A78F5 jmp short loc_A797C loc_A7963: mov r15d, [rbp+var_2C] jmp short loc_A7970 loc_A7969: mov r15d, [rbp+var_2C] inc r15d loc_A7970: cmp r15d, 7 jle loc_A78DA jmp short loc_A7980 loc_A797C: mov r15d, [rbp+var_2C] loc_A7980: mov rdi, rbx call _closedir test eax, eax jz short loc_A79AB call ___errno_location mov ecx, [rax] lea rdx, aSysKernelMmHug; "/sys/kernel/mm/hugepages" mov esi, 4 mov edi, 4 xor eax, eax call my_error loc_A79AB: movsxd rsi, r15d lea rdi, my_large_page_sizes lea rcx, size_t_cmp mov edx, 8 call _qsort jmp short loc_A79E7 loc_A79C8: call ___errno_location mov ecx, [rax] lea rdx, aSysKernelMmHug; "/sys/kernel/mm/hugepages" mov esi, 4 mov edi, 0Ch xor eax, eax call my_error loc_A79E7: xor eax, eax add rsp, 8 pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
long long my_init_large_pages( __m128 a1, __m128 a2, __m128 a3, __m128 a4, double a5, double a6, __m128 a7, __m128 a8) { char v8; // al long long v9; // rax long long v10; // rbx int v11; // r15d long long v12; // rax long long v13; // r12 long long v14; // rax long long v15; // r8 long long v16; // r9 __m128 v17; // xmm4 __m128 v18; // xmm5 unsigned int *v19; // rax unsigned int *v20; // rax char v22; // [rsp-4h] [rbp-30h] int v23; // [rsp+0h] [rbp-2Ch] v22 = v8; my_use_large_pages = 1; v9 = opendir("/sys/kernel/mm/hugepages"); if ( v9 ) { v10 = v9; v11 = 0; do { v12 = readdir64(v10); if ( !v12 ) break; v13 = v12; v23 = v11; while ( 1 ) { if ( (unsigned int)strncmp("hugepages-", v13 + 19, 10LL) ) { v11 = v23; goto LABEL_11; } v14 = __isoc23_strtoul(v13 + 29, 0LL, 10LL) << 10; my_large_page_sizes[v11] = v14; if ( ((v14 - 1) & v14) == 0 ) break; my_printf_error( 0, (long long)"non-power of 2 large page size (%zu) found, skipping", 1152, v14, v15, v16, a1, a2, a3, a4, v17, v18, a7, a8, v22); my_large_page_sizes[v11] = 0LL; v13 = readdir64(v10); if ( !v13 ) { v11 = v23; goto LABEL_12; } } v11 = v23 + 1; LABEL_11: ; } while ( v11 <= 7 ); LABEL_12: if ( (unsigned int)closedir(v10) ) { v19 = (unsigned int *)__errno_location(v10); my_error(4u, 4LL, "/sys/kernel/mm/hugepages", *v19); } qsort(my_large_page_sizes, v11, 8LL, size_t_cmp); } else { v20 = (unsigned int *)__errno_location("/sys/kernel/mm/hugepages"); my_error(0xCu, 4LL, "/sys/kernel/mm/hugepages", *v20); } return 0LL; }
my_init_large_pages: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX PUSH RAX MOV byte ptr [0x00d08930],0x1 LEA RDI,[0x1dc706] CALL 0x00129490 TEST RAX,RAX JZ 0x001a79c8 MOV RBX,RAX LEA R14,[0x1dc71f] LEA R13,[0xd08940] XOR R15D,R15D LAB_001a78da: MOV RDI,RBX CALL 0x001294a0 TEST RAX,RAX JZ 0x001a7980 MOV R12,RAX MOV dword ptr [RBP + -0x2c],R15D MOVSXD R15,R15D LAB_001a78f5: LEA RSI,[R12 + 0x13] MOV EDX,0xa MOV RDI,R14 CALL 0x001291b0 TEST EAX,EAX JNZ 0x001a7963 ADD R12,0x1d MOV RDI,R12 XOR ESI,ESI MOV EDX,0xa CALL 0x00129070 SHL RAX,0xa MOV qword ptr [R13 + R15*0x8],RAX LEA RCX,[RAX + -0x1] TEST RAX,RCX JZ 0x001a7969 MOV EDX,0x480 XOR EDI,EDI LEA RSI,[0x1dc72a] MOV RCX,RAX XOR EAX,EAX CALL 0x0019e0dd MOV qword ptr [R13 + R15*0x8],0x0 MOV RDI,RBX CALL 0x001294a0 MOV R12,RAX TEST RAX,RAX JNZ 0x001a78f5 JMP 0x001a797c LAB_001a7963: MOV R15D,dword ptr [RBP + -0x2c] JMP 0x001a7970 LAB_001a7969: MOV R15D,dword ptr [RBP + -0x2c] INC R15D LAB_001a7970: CMP R15D,0x7 JLE 0x001a78da JMP 0x001a7980 LAB_001a797c: MOV R15D,dword ptr [RBP + -0x2c] LAB_001a7980: MOV RDI,RBX CALL 0x00129470 TEST EAX,EAX JZ 0x001a79ab CALL 0x00129790 MOV ECX,dword ptr [RAX] LEA RDX,[0x1dc706] MOV ESI,0x4 MOV EDI,0x4 XOR EAX,EAX CALL 0x0019dfc3 LAB_001a79ab: MOVSXD RSI,R15D LEA RDI,[0xd08940] LEA RCX,[0x1a7ee5] MOV EDX,0x8 CALL 0x001295c0 JMP 0x001a79e7 LAB_001a79c8: CALL 0x00129790 MOV ECX,dword ptr [RAX] LEA RDX,[0x1dc706] MOV ESI,0x4 MOV EDI,0xc XOR EAX,EAX CALL 0x0019dfc3 LAB_001a79e7: XOR EAX,EAX ADD RSP,0x8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
int8 my_init_large_pages(void) { int iVar1; DIR *__dirp; dirent64 *pdVar2; long lVar3; ulong uVar4; int *piVar5; int iVar6; my_use_large_pages = 1; __dirp = opendir("/sys/kernel/mm/hugepages"); if (__dirp == (DIR *)0x0) { piVar5 = __errno_location(); my_error(0xc,4,"/sys/kernel/mm/hugepages",*piVar5); } else { iVar6 = 0; while (pdVar2 = readdir64(__dirp), pdVar2 != (dirent64 *)0x0) { while (iVar1 = strncmp("hugepages-",pdVar2->d_name,10), iVar1 == 0) { lVar3 = __isoc23_strtoul(pdVar2->d_name + 10,0,10); uVar4 = lVar3 * 0x400; (&my_large_page_sizes)[iVar6] = uVar4; if ((uVar4 & uVar4 - 1) == 0) { iVar6 = iVar6 + 1; break; } my_printf_error(0,"non-power of 2 large page size (%zu) found, skipping",0x480,uVar4); (&my_large_page_sizes)[iVar6] = 0; pdVar2 = readdir64(__dirp); if (pdVar2 == (dirent64 *)0x0) goto LAB_001a7980; } if (7 < iVar6) break; } LAB_001a7980: iVar1 = closedir(__dirp); if (iVar1 != 0) { piVar5 = __errno_location(); my_error(4,4,"/sys/kernel/mm/hugepages",*piVar5); } qsort(&my_large_page_sizes,(long)iVar6,8,size_t_cmp); } return 0; }
27,594
R3D_GetLightSize
r3d/src/r3d_lighting.c
float R3D_GetLightSize(R3D_Light id) { r3d_get_and_check_light(light, id, 0); return light->size; }
O3
c
R3D_GetLightSize: movl %edi, %edx testl %edi, %edi je 0xbe1c5 leaq 0xf1a65(%rip), %rax # 0x1afbf0 cmpl %edx, 0x168(%rax) jbe 0xbe1c5 movq 0x128(%rax), %rsi leal -0x1(%rdx), %ecx cmpb $0x1, (%rsi,%rcx) jne 0xbe1c5 movq 0x108(%rax), %rsi cmpq %rcx, 0x110(%rax) setbe %dil testq %rsi, %rsi sete %r8b orb %dil, %r8b cmpb $0x1, %r8b jne 0xbe1e1 pushq %rbp movq %rsp, %rbp leaq 0x53c0d(%rip), %rsi # 0x111ddd movl $0x5, %edi xorl %eax, %eax callq 0xa9b51 xorps %xmm0, %xmm0 popq %rbp retq imulq 0x120(%rax), %rcx movss 0x98(%rsi,%rcx), %xmm0 retq
R3D_GetLightSize: mov edx, edi test edi, edi jz short loc_BE1C5 lea rax, R3D cmp [rax+168h], edx jbe short loc_BE1C5 mov rsi, [rax+128h] lea ecx, [rdx-1] cmp byte ptr [rsi+rcx], 1 jnz short loc_BE1C5 mov rsi, [rax+108h] cmp [rax+110h], rcx setbe dil test rsi, rsi setz r8b or r8b, dil cmp r8b, 1 jnz short loc_BE1E1 loc_BE1C5: push rbp mov rbp, rsp lea rsi, aLightIdIIsNotV; "Light [ID %i] is not valid" mov edi, 5 xor eax, eax call TraceLog xorps xmm0, xmm0 pop rbp retn loc_BE1E1: imul rcx, [rax+120h] movss xmm0, dword ptr [rsi+rcx+98h] retn
float R3D_GetLightSize(unsigned int a1) { unsigned long long v1; // rcx long long v2; // rsi if ( a1 ) { if ( *((_DWORD *)&R3D + 90) > a1 ) { v1 = a1 - 1; if ( *(_BYTE *)(*((_QWORD *)&R3D + 37) + v1) == 1 ) { v2 = *((_QWORD *)&R3D + 33); if ( *((_QWORD *)&R3D + 34) > v1 && v2 != 0 ) return *(float *)(v2 + *((_QWORD *)&R3D + 36) * v1 + 152); } } } TraceLog(5, (long long)"Light [ID %i] is not valid", a1); return 0.0; }
R3D_GetLightSize: MOV EDX,EDI TEST EDI,EDI JZ 0x001be1c5 LEA RAX,[0x2afbf0] CMP dword ptr [RAX + 0x168],EDX JBE 0x001be1c5 MOV RSI,qword ptr [RAX + 0x128] LEA ECX,[RDX + -0x1] CMP byte ptr [RSI + RCX*0x1],0x1 JNZ 0x001be1c5 MOV RSI,qword ptr [RAX + 0x108] CMP qword ptr [RAX + 0x110],RCX SETBE DIL TEST RSI,RSI SETZ R8B OR R8B,DIL CMP R8B,0x1 JNZ 0x001be1e1 LAB_001be1c5: PUSH RBP MOV RBP,RSP LEA RSI,[0x211ddd] MOV EDI,0x5 XOR EAX,EAX CALL 0x001a9b51 XORPS XMM0,XMM0 POP RBP RET LAB_001be1e1: IMUL RCX,qword ptr [RAX + 0x120] MOVSS XMM0,dword ptr [RSI + RCX*0x1 + 0x98] RET
int4 R3D_GetLightSize(uint param_1) { ulong uVar1; if (((param_1 != 0) && (param_1 < DAT_002afd58)) && (uVar1 = (ulong)(param_1 - 1), *(char *)(DAT_002afd18 + uVar1) == '\x01')) { if (DAT_002afcf8 != 0 && uVar1 < DAT_002afd00) { return *(int4 *)(DAT_002afcf8 + 0x98 + uVar1 * DAT_002afd10); } } TraceLog(5,"Light [ID %i] is not valid"); return 0; }
27,595
my_strnxfrm_simple_internal
eloqsql/strings/ctype-simple.c
size_t my_strnxfrm_simple_internal(CHARSET_INFO * cs, uchar *dst, size_t dstlen, uint *nweights, const uchar *src, size_t srclen) { const uchar *map= cs->sort_order; uchar *d0= dst; uint frmlen; if ((frmlen= (uint)MY_MIN(dstlen, *nweights)) > srclen) frmlen= (uint)srclen; if (dst != src) { const uchar *end; for (end= src + frmlen; src < end;) *dst++= map[*src++]; } else { const uchar *end; for (end= dst + frmlen; dst < end; dst++) *dst= map[(uchar) *dst]; } *nweights-= frmlen; return dst - d0; }
O3
c
my_strnxfrm_simple_internal: pushq %rbp movq %rsp, %rbp movq 0x58(%rdi), %rdi movl (%rcx), %eax cmpq %rdx, %rax cmovbel %eax, %edx cmpq %r9, %rdx cmovbel %edx, %r9d movq %rsi, %rax cmpq %r8, %rsi je 0x40bd1 testq %r9, %r9 je 0x40bf0 leaq (%r8,%r9), %rdx movq %rsi, %rax movzbl (%r8), %r10d incq %r8 movb (%rdi,%r10), %r10b movb %r10b, (%rax) incq %rax cmpq %rdx, %r8 jb 0x40bb9 jmp 0x40bf0 testq %r9, %r9 je 0x40bf0 leaq (%rsi,%r9), %rdx movq %rsi, %rax movzbl (%rax), %r8d movb (%rdi,%r8), %r8b movb %r8b, (%rax) incq %rax cmpq %rdx, %rax jb 0x40bdd subl %r9d, (%rcx) subq %rsi, %rax popq %rbp retq
my_strnxfrm_simple_internal: push rbp mov rbp, rsp mov rdi, [rdi+58h] mov eax, [rcx] cmp rax, rdx cmovbe edx, eax cmp rdx, r9 cmovbe r9d, edx mov rax, rsi cmp rsi, r8 jz short loc_40BD1 test r9, r9 jz short loc_40BF0 lea rdx, [r8+r9] mov rax, rsi loc_40BB9: movzx r10d, byte ptr [r8] inc r8 mov r10b, [rdi+r10] mov [rax], r10b inc rax cmp r8, rdx jb short loc_40BB9 jmp short loc_40BF0 loc_40BD1: test r9, r9 jz short loc_40BF0 lea rdx, [rsi+r9] mov rax, rsi loc_40BDD: movzx r8d, byte ptr [rax] mov r8b, [rdi+r8] mov [rax], r8b inc rax cmp rax, rdx jb short loc_40BDD loc_40BF0: sub [rcx], r9d sub rax, rsi pop rbp retn
_BYTE * my_strnxfrm_simple_internal( long long a1, unsigned __int8 *a2, unsigned long long a3, _DWORD *a4, unsigned __int8 *a5, unsigned long long a6) { long long v6; // rdi unsigned long long v7; // rax unsigned __int8 *v8; // rax unsigned __int8 *v9; // rdx long long v10; // r10 v6 = *(_QWORD *)(a1 + 88); v7 = (unsigned int)*a4; if ( v7 <= a3 ) a3 = (unsigned int)v7; if ( a3 <= a6 ) a6 = (unsigned int)a3; v8 = a2; if ( a2 == a5 ) { if ( a6 ) { v8 = a2; do { *v8 = *(_BYTE *)(v6 + *v8); ++v8; } while ( v8 < &a2[a6] ); } } else if ( a6 ) { v9 = &a5[a6]; v8 = a2; do { v10 = *a5++; *v8++ = *(_BYTE *)(v6 + v10); } while ( a5 < v9 ); } *a4 -= a6; return (_BYTE *)(v8 - a2); }
my_strnxfrm_simple_internal: PUSH RBP MOV RBP,RSP MOV RDI,qword ptr [RDI + 0x58] MOV EAX,dword ptr [RCX] CMP RAX,RDX CMOVBE EDX,EAX CMP RDX,R9 CMOVBE R9D,EDX MOV RAX,RSI CMP RSI,R8 JZ 0x00140bd1 TEST R9,R9 JZ 0x00140bf0 LEA RDX,[R8 + R9*0x1] MOV RAX,RSI LAB_00140bb9: MOVZX R10D,byte ptr [R8] INC R8 MOV R10B,byte ptr [RDI + R10*0x1] MOV byte ptr [RAX],R10B INC RAX CMP R8,RDX JC 0x00140bb9 JMP 0x00140bf0 LAB_00140bd1: TEST R9,R9 JZ 0x00140bf0 LEA RDX,[RSI + R9*0x1] MOV RAX,RSI LAB_00140bdd: MOVZX R8D,byte ptr [RAX] MOV R8B,byte ptr [RDI + R8*0x1] MOV byte ptr [RAX],R8B INC RAX CMP RAX,RDX JC 0x00140bdd LAB_00140bf0: SUB dword ptr [RCX],R9D SUB RAX,RSI POP RBP RET
long my_strnxfrm_simple_internal (long param_1,byte *param_2,ulong param_3,uint *param_4,byte *param_5,ulong param_6) { byte *pbVar1; byte bVar2; long lVar3; byte *pbVar4; ulong uVar5; ulong uVar6; lVar3 = *(long *)(param_1 + 0x58); uVar5 = param_3 & 0xffffffff; if (*param_4 <= param_3) { uVar5 = (ulong)*param_4; } uVar6 = param_6 & 0xffffffff; if (uVar5 <= param_6) { uVar6 = uVar5; } pbVar4 = param_2; if (param_2 == param_5) { if (uVar6 != 0) { do { *pbVar4 = *(byte *)(lVar3 + (ulong)*pbVar4); pbVar4 = pbVar4 + 1; } while (pbVar4 < param_2 + uVar6); } } else if (uVar6 != 0) { pbVar1 = param_5 + uVar6; do { bVar2 = *param_5; param_5 = param_5 + 1; *pbVar4 = *(byte *)(lVar3 + (ulong)bVar2); pbVar4 = pbVar4 + 1; } while (param_5 < pbVar1); } *param_4 = *param_4 - (int)uVar6; return (long)pbVar4 - (long)param_2; }
27,596
u32toa_radix
bluesky950520[P]quickjs/cutils.c
size_t u32toa_radix(char buf[minimum_length(33)], uint32_t n, unsigned base) { int shift; #ifdef USE_SPECIAL_RADIX_10 if (likely(base == 10)) return u32toa(buf, n); #endif if (n < base) { buf[0] = digits36[n]; buf[1] = '\0'; return 1; } shift = radix_shift[base & 63]; if (shift) { uint32_t mask = (1 << shift) - 1; size_t len = (32 - clz32(n) + shift - 1) / shift; size_t last = n & mask; char *end = buf + len; n >>= shift; *end-- = '\0'; *end-- = digits36[last]; while (n >= base) { size_t quo = n & mask; n >>= shift; *end-- = digits36[quo]; } *end = digits36[n]; return len; } else { size_t len = 2; size_t last = n % base; n /= base; uint32_t nbase = base; while (n >= nbase) { nbase *= base; len++; } char *end = buf + len; *end-- = '\0'; *end-- = digits36[last]; while (n >= base) { size_t quo = n % base; n /= base; *end-- = digits36[quo]; } *end = digits36[n]; return len; } }
O0
c
u32toa_radix: subq $0x68, %rsp movq %rdi, 0x58(%rsp) movl %esi, 0x54(%rsp) movl %edx, 0x50(%rsp) cmpl $0xa, 0x50(%rsp) sete %al xorb $-0x1, %al xorb $-0x1, %al andb $0x1, %al movzbl %al, %eax cltq cmpq $0x0, %rax je 0x1fbc2 movq 0x58(%rsp), %rdi movl 0x54(%rsp), %esi callq 0x1f710 movq %rax, 0x60(%rsp) jmp 0x1fe35 movl 0x54(%rsp), %eax cmpl 0x50(%rsp), %eax jae 0x1fbfa movl 0x54(%rsp), %eax movl %eax, %ecx leaq 0xea867(%rip), %rax # 0x10a440 movb (%rax,%rcx), %cl movq 0x58(%rsp), %rax movb %cl, (%rax) movq 0x58(%rsp), %rax movb $0x0, 0x1(%rax) movq $0x1, 0x60(%rsp) jmp 0x1fe35 movl 0x50(%rsp), %eax andl $0x3f, %eax movl %eax, %eax movl %eax, %ecx leaq 0xea864(%rip), %rax # 0x10a470 movzbl (%rax,%rcx), %eax movl %eax, 0x4c(%rsp) cmpl $0x0, 0x4c(%rsp) je 0x1fd29 movl 0x4c(%rsp), %ecx movl $0x1, %eax shll %cl, %eax subl $0x1, %eax movl %eax, 0x48(%rsp) movl 0x54(%rsp), %edi callq 0x1fe40 movl %eax, %ecx movl $0x20, %eax subl %ecx, %eax addl 0x4c(%rsp), %eax subl $0x1, %eax cltd idivl 0x4c(%rsp) cltq movq %rax, 0x40(%rsp) movl 0x54(%rsp), %eax andl 0x48(%rsp), %eax movl %eax, %eax movq %rax, 0x38(%rsp) movq 0x58(%rsp), %rax addq 0x40(%rsp), %rax movq %rax, 0x30(%rsp) movl 0x4c(%rsp), %ecx movl 0x54(%rsp), %eax shrl %cl, %eax movl %eax, 0x54(%rsp) movq 0x30(%rsp), %rax movq %rax, %rcx addq $-0x1, %rcx movq %rcx, 0x30(%rsp) movb $0x0, (%rax) movq 0x38(%rsp), %rcx leaq 0xea79e(%rip), %rax # 0x10a440 movb (%rax,%rcx), %cl movq 0x30(%rsp), %rax movq %rax, %rdx addq $-0x1, %rdx movq %rdx, 0x30(%rsp) movb %cl, (%rax) movl 0x54(%rsp), %eax cmpl 0x50(%rsp), %eax jb 0x1fd03 movl 0x54(%rsp), %eax andl 0x48(%rsp), %eax movl %eax, %eax movq %rax, 0x28(%rsp) movl 0x4c(%rsp), %ecx movl 0x54(%rsp), %eax shrl %cl, %eax movl %eax, 0x54(%rsp) movq 0x28(%rsp), %rcx leaq 0xea755(%rip), %rax # 0x10a440 movb (%rax,%rcx), %cl movq 0x30(%rsp), %rax movq %rax, %rdx addq $-0x1, %rdx movq %rdx, 0x30(%rsp) movb %cl, (%rax) jmp 0x1fcb8 movl 0x54(%rsp), %eax movl %eax, %ecx leaq 0xea730(%rip), %rax # 0x10a440 movb (%rax,%rcx), %cl movq 0x30(%rsp), %rax movb %cl, (%rax) movq 0x40(%rsp), %rax movq %rax, 0x60(%rsp) jmp 0x1fe35 movq $0x2, 0x20(%rsp) movl 0x54(%rsp), %eax xorl %edx, %edx divl 0x50(%rsp) movl %edx, %eax movq %rax, 0x18(%rsp) movl 0x50(%rsp), %ecx movl 0x54(%rsp), %eax xorl %edx, %edx divl %ecx movl %eax, 0x54(%rsp) movl 0x50(%rsp), %eax movl %eax, 0x14(%rsp) movl 0x54(%rsp), %eax cmpl 0x14(%rsp), %eax jb 0x1fd82 movl 0x50(%rsp), %eax imull 0x14(%rsp), %eax movl %eax, 0x14(%rsp) movq 0x20(%rsp), %rax addq $0x1, %rax movq %rax, 0x20(%rsp) jmp 0x1fd5b movq 0x58(%rsp), %rax addq 0x20(%rsp), %rax movq %rax, 0x8(%rsp) movq 0x8(%rsp), %rax movq %rax, %rcx addq $-0x1, %rcx movq %rcx, 0x8(%rsp) movb $0x0, (%rax) movq 0x18(%rsp), %rcx leaq 0xea68f(%rip), %rax # 0x10a440 movb (%rax,%rcx), %cl movq 0x8(%rsp), %rax movq %rax, %rdx addq $-0x1, %rdx movq %rdx, 0x8(%rsp) movb %cl, (%rax) movl 0x54(%rsp), %eax cmpl 0x50(%rsp), %eax jb 0x1fe14 movl 0x54(%rsp), %eax xorl %edx, %edx divl 0x50(%rsp) movl %edx, %eax movq %rax, (%rsp) movl 0x50(%rsp), %ecx movl 0x54(%rsp), %eax xorl %edx, %edx divl %ecx movl %eax, 0x54(%rsp) movq (%rsp), %rcx leaq 0xea644(%rip), %rax # 0x10a440 movb (%rax,%rcx), %cl movq 0x8(%rsp), %rax movq %rax, %rdx addq $-0x1, %rdx movq %rdx, 0x8(%rsp) movb %cl, (%rax) jmp 0x1fdc7 movl 0x54(%rsp), %eax movl %eax, %ecx leaq 0xea61f(%rip), %rax # 0x10a440 movb (%rax,%rcx), %cl movq 0x8(%rsp), %rax movb %cl, (%rax) movq 0x20(%rsp), %rax movq %rax, 0x60(%rsp) movq 0x60(%rsp), %rax addq $0x68, %rsp retq nop
u32toa_radix: sub rsp, 68h mov [rsp+68h+var_10], rdi mov [rsp+68h+var_14], esi mov [rsp+68h+var_18], edx cmp [rsp+68h+var_18], 0Ah setz al xor al, 0FFh xor al, 0FFh and al, 1 movzx eax, al cdqe cmp rax, 0 jz short loc_1FBC2 mov rdi, [rsp+68h+var_10] mov esi, [rsp+68h+var_14] call u32toa mov [rsp+68h+var_8], rax jmp loc_1FE35 loc_1FBC2: mov eax, [rsp+68h+var_14] cmp eax, [rsp+68h+var_18] jnb short loc_1FBFA mov eax, [rsp+68h+var_14] mov ecx, eax lea rax, digits36; "0123456789abcdefghijklmnopqrstuvwxyz" mov cl, [rax+rcx] mov rax, [rsp+68h+var_10] mov [rax], cl mov rax, [rsp+68h+var_10] mov byte ptr [rax+1], 0 mov [rsp+68h+var_8], 1 jmp loc_1FE35 loc_1FBFA: mov eax, [rsp+68h+var_18] and eax, 3Fh mov eax, eax mov ecx, eax lea rax, radix_shift movzx eax, byte ptr [rax+rcx] mov [rsp+68h+var_1C], eax cmp [rsp+68h+var_1C], 0 jz loc_1FD29 mov ecx, [rsp+68h+var_1C] mov eax, 1 shl eax, cl sub eax, 1 mov [rsp+68h+var_20], eax mov edi, [rsp+68h+var_14] call clz32 mov ecx, eax mov eax, 20h ; ' ' sub eax, ecx add eax, [rsp+68h+var_1C] sub eax, 1 cdq idiv [rsp+68h+var_1C] cdqe mov [rsp+68h+var_28], rax mov eax, [rsp+68h+var_14] and eax, [rsp+68h+var_20] mov eax, eax mov [rsp+68h+var_30], rax mov rax, [rsp+68h+var_10] add rax, [rsp+68h+var_28] mov [rsp+68h+var_38], rax mov ecx, [rsp+68h+var_1C] mov eax, [rsp+68h+var_14] shr eax, cl mov [rsp+68h+var_14], eax mov rax, [rsp+68h+var_38] mov rcx, rax add rcx, 0FFFFFFFFFFFFFFFFh mov [rsp+68h+var_38], rcx mov byte ptr [rax], 0 mov rcx, [rsp+68h+var_30] lea rax, digits36; "0123456789abcdefghijklmnopqrstuvwxyz" mov cl, [rax+rcx] mov rax, [rsp+68h+var_38] mov rdx, rax add rdx, 0FFFFFFFFFFFFFFFFh mov [rsp+68h+var_38], rdx mov [rax], cl loc_1FCB8: mov eax, [rsp+68h+var_14] cmp eax, [rsp+68h+var_18] jb short loc_1FD03 mov eax, [rsp+68h+var_14] and eax, [rsp+68h+var_20] mov eax, eax mov [rsp+68h+var_40], rax mov ecx, [rsp+68h+var_1C] mov eax, [rsp+68h+var_14] shr eax, cl mov [rsp+68h+var_14], eax mov rcx, [rsp+68h+var_40] lea rax, digits36; "0123456789abcdefghijklmnopqrstuvwxyz" mov cl, [rax+rcx] mov rax, [rsp+68h+var_38] mov rdx, rax add rdx, 0FFFFFFFFFFFFFFFFh mov [rsp+68h+var_38], rdx mov [rax], cl jmp short loc_1FCB8 loc_1FD03: mov eax, [rsp+68h+var_14] mov ecx, eax lea rax, digits36; "0123456789abcdefghijklmnopqrstuvwxyz" mov cl, [rax+rcx] mov rax, [rsp+68h+var_38] mov [rax], cl mov rax, [rsp+68h+var_28] mov [rsp+68h+var_8], rax jmp loc_1FE35 loc_1FD29: mov [rsp+68h+var_48], 2 mov eax, [rsp+68h+var_14] xor edx, edx div [rsp+68h+var_18] mov eax, edx mov [rsp+68h+var_50], rax mov ecx, [rsp+68h+var_18] mov eax, [rsp+68h+var_14] xor edx, edx div ecx mov [rsp+68h+var_14], eax mov eax, [rsp+68h+var_18] mov [rsp+68h+var_54], eax loc_1FD5B: mov eax, [rsp+68h+var_14] cmp eax, [rsp+68h+var_54] jb short loc_1FD82 mov eax, [rsp+68h+var_18] imul eax, [rsp+68h+var_54] mov [rsp+68h+var_54], eax mov rax, [rsp+68h+var_48] add rax, 1 mov [rsp+68h+var_48], rax jmp short loc_1FD5B loc_1FD82: mov rax, [rsp+68h+var_10] add rax, [rsp+68h+var_48] mov [rsp+68h+var_60], rax mov rax, [rsp+68h+var_60] mov rcx, rax add rcx, 0FFFFFFFFFFFFFFFFh mov [rsp+68h+var_60], rcx mov byte ptr [rax], 0 mov rcx, [rsp+68h+var_50] lea rax, digits36; "0123456789abcdefghijklmnopqrstuvwxyz" mov cl, [rax+rcx] mov rax, [rsp+68h+var_60] mov rdx, rax add rdx, 0FFFFFFFFFFFFFFFFh mov [rsp+68h+var_60], rdx mov [rax], cl loc_1FDC7: mov eax, [rsp+68h+var_14] cmp eax, [rsp+68h+var_18] jb short loc_1FE14 mov eax, [rsp+68h+var_14] xor edx, edx div [rsp+68h+var_18] mov eax, edx mov [rsp+68h+var_68], rax mov ecx, [rsp+68h+var_18] mov eax, [rsp+68h+var_14] xor edx, edx div ecx mov [rsp+68h+var_14], eax mov rcx, [rsp+68h+var_68] lea rax, digits36; "0123456789abcdefghijklmnopqrstuvwxyz" mov cl, [rax+rcx] mov rax, [rsp+68h+var_60] mov rdx, rax add rdx, 0FFFFFFFFFFFFFFFFh mov [rsp+68h+var_60], rdx mov [rax], cl jmp short loc_1FDC7 loc_1FE14: mov eax, [rsp+68h+var_14] mov ecx, eax lea rax, digits36; "0123456789abcdefghijklmnopqrstuvwxyz" mov cl, [rax+rcx] mov rax, [rsp+68h+var_60] mov [rax], cl mov rax, [rsp+68h+var_48] mov [rsp+68h+var_8], rax loc_1FE35: mov rax, [rsp+68h+var_8] add rsp, 68h retn
long long u32toa_radix(_BYTE *a1, unsigned int a2, unsigned int a3) { long long v3; // rcx _BYTE *v4; // rax _BYTE *v5; // rax long long v7; // [rsp+0h] [rbp-68h] _BYTE *v8; // [rsp+8h] [rbp-60h] unsigned int v9; // [rsp+14h] [rbp-54h] long long v10; // [rsp+20h] [rbp-48h] long long v11; // [rsp+28h] [rbp-40h] _BYTE *v12; // [rsp+30h] [rbp-38h] long long v13; // [rsp+40h] [rbp-28h] int v14; // [rsp+48h] [rbp-20h] int v15; // [rsp+4Ch] [rbp-1Ch] unsigned int v17; // [rsp+54h] [rbp-14h] unsigned int v18; // [rsp+54h] [rbp-14h] if ( a3 == 10 ) return u32toa(a1, a2); if ( a2 >= a3 ) { v3 = a3 & 0x3F; v15 = radix_shift[v3]; if ( radix_shift[v3] ) { v14 = (1 << v15) - 1; v13 = (int)(v15 + 32 - clz32(a2) - 1) / v15; v17 = a2 >> v15; a1[v13] = 0; v12 = &a1[v13 - 2]; a1[v13 - 1] = digits36[v14 & a2]; while ( v17 >= a3 ) { v11 = v14 & v17; v17 >>= v15; v4 = v12--; *v4 = digits36[v11]; } *v12 = digits36[v17]; return v13; } else { v10 = 2LL; v18 = a2 / a3; v9 = a3; while ( v18 >= v9 ) { v9 *= a3; ++v10; } a1[v10] = 0; v8 = &a1[v10 - 2]; a1[v10 - 1] = digits36[a2 % a3]; while ( v18 >= a3 ) { v7 = v18 % a3; v18 /= a3; v5 = v8--; *v5 = digits36[v7]; } *v8 = digits36[v18]; return v10; } } else { *a1 = digits36[a2]; a1[1] = 0; return 1LL; } }
u32toa_radix: SUB RSP,0x68 MOV qword ptr [RSP + 0x58],RDI MOV dword ptr [RSP + 0x54],ESI MOV dword ptr [RSP + 0x50],EDX CMP dword ptr [RSP + 0x50],0xa SETZ AL XOR AL,0xff XOR AL,0xff AND AL,0x1 MOVZX EAX,AL CDQE CMP RAX,0x0 JZ 0x0011fbc2 MOV RDI,qword ptr [RSP + 0x58] MOV ESI,dword ptr [RSP + 0x54] CALL 0x0011f710 MOV qword ptr [RSP + 0x60],RAX JMP 0x0011fe35 LAB_0011fbc2: MOV EAX,dword ptr [RSP + 0x54] CMP EAX,dword ptr [RSP + 0x50] JNC 0x0011fbfa MOV EAX,dword ptr [RSP + 0x54] MOV ECX,EAX LEA RAX,[0x20a440] MOV CL,byte ptr [RAX + RCX*0x1] MOV RAX,qword ptr [RSP + 0x58] MOV byte ptr [RAX],CL MOV RAX,qword ptr [RSP + 0x58] MOV byte ptr [RAX + 0x1],0x0 MOV qword ptr [RSP + 0x60],0x1 JMP 0x0011fe35 LAB_0011fbfa: MOV EAX,dword ptr [RSP + 0x50] AND EAX,0x3f MOV EAX,EAX MOV ECX,EAX LEA RAX,[0x20a470] MOVZX EAX,byte ptr [RAX + RCX*0x1] MOV dword ptr [RSP + 0x4c],EAX CMP dword ptr [RSP + 0x4c],0x0 JZ 0x0011fd29 MOV ECX,dword ptr [RSP + 0x4c] MOV EAX,0x1 SHL EAX,CL SUB EAX,0x1 MOV dword ptr [RSP + 0x48],EAX MOV EDI,dword ptr [RSP + 0x54] CALL 0x0011fe40 MOV ECX,EAX MOV EAX,0x20 SUB EAX,ECX ADD EAX,dword ptr [RSP + 0x4c] SUB EAX,0x1 CDQ IDIV dword ptr [RSP + 0x4c] CDQE MOV qword ptr [RSP + 0x40],RAX MOV EAX,dword ptr [RSP + 0x54] AND EAX,dword ptr [RSP + 0x48] MOV EAX,EAX MOV qword ptr [RSP + 0x38],RAX MOV RAX,qword ptr [RSP + 0x58] ADD RAX,qword ptr [RSP + 0x40] MOV qword ptr [RSP + 0x30],RAX MOV ECX,dword ptr [RSP + 0x4c] MOV EAX,dword ptr [RSP + 0x54] SHR EAX,CL MOV dword ptr [RSP + 0x54],EAX MOV RAX,qword ptr [RSP + 0x30] MOV RCX,RAX ADD RCX,-0x1 MOV qword ptr [RSP + 0x30],RCX MOV byte ptr [RAX],0x0 MOV RCX,qword ptr [RSP + 0x38] LEA RAX,[0x20a440] MOV CL,byte ptr [RAX + RCX*0x1] MOV RAX,qword ptr [RSP + 0x30] MOV RDX,RAX ADD RDX,-0x1 MOV qword ptr [RSP + 0x30],RDX MOV byte ptr [RAX],CL LAB_0011fcb8: MOV EAX,dword ptr [RSP + 0x54] CMP EAX,dword ptr [RSP + 0x50] JC 0x0011fd03 MOV EAX,dword ptr [RSP + 0x54] AND EAX,dword ptr [RSP + 0x48] MOV EAX,EAX MOV qword ptr [RSP + 0x28],RAX MOV ECX,dword ptr [RSP + 0x4c] MOV EAX,dword ptr [RSP + 0x54] SHR EAX,CL MOV dword ptr [RSP + 0x54],EAX MOV RCX,qword ptr [RSP + 0x28] LEA RAX,[0x20a440] MOV CL,byte ptr [RAX + RCX*0x1] MOV RAX,qword ptr [RSP + 0x30] MOV RDX,RAX ADD RDX,-0x1 MOV qword ptr [RSP + 0x30],RDX MOV byte ptr [RAX],CL JMP 0x0011fcb8 LAB_0011fd03: MOV EAX,dword ptr [RSP + 0x54] MOV ECX,EAX LEA RAX,[0x20a440] MOV CL,byte ptr [RAX + RCX*0x1] MOV RAX,qword ptr [RSP + 0x30] MOV byte ptr [RAX],CL MOV RAX,qword ptr [RSP + 0x40] MOV qword ptr [RSP + 0x60],RAX JMP 0x0011fe35 LAB_0011fd29: MOV qword ptr [RSP + 0x20],0x2 MOV EAX,dword ptr [RSP + 0x54] XOR EDX,EDX DIV dword ptr [RSP + 0x50] MOV EAX,EDX MOV qword ptr [RSP + 0x18],RAX MOV ECX,dword ptr [RSP + 0x50] MOV EAX,dword ptr [RSP + 0x54] XOR EDX,EDX DIV ECX MOV dword ptr [RSP + 0x54],EAX MOV EAX,dword ptr [RSP + 0x50] MOV dword ptr [RSP + 0x14],EAX LAB_0011fd5b: MOV EAX,dword ptr [RSP + 0x54] CMP EAX,dword ptr [RSP + 0x14] JC 0x0011fd82 MOV EAX,dword ptr [RSP + 0x50] IMUL EAX,dword ptr [RSP + 0x14] MOV dword ptr [RSP + 0x14],EAX MOV RAX,qword ptr [RSP + 0x20] ADD RAX,0x1 MOV qword ptr [RSP + 0x20],RAX JMP 0x0011fd5b LAB_0011fd82: MOV RAX,qword ptr [RSP + 0x58] ADD RAX,qword ptr [RSP + 0x20] MOV qword ptr [RSP + 0x8],RAX MOV RAX,qword ptr [RSP + 0x8] MOV RCX,RAX ADD RCX,-0x1 MOV qword ptr [RSP + 0x8],RCX MOV byte ptr [RAX],0x0 MOV RCX,qword ptr [RSP + 0x18] LEA RAX,[0x20a440] MOV CL,byte ptr [RAX + RCX*0x1] MOV RAX,qword ptr [RSP + 0x8] MOV RDX,RAX ADD RDX,-0x1 MOV qword ptr [RSP + 0x8],RDX MOV byte ptr [RAX],CL LAB_0011fdc7: MOV EAX,dword ptr [RSP + 0x54] CMP EAX,dword ptr [RSP + 0x50] JC 0x0011fe14 MOV EAX,dword ptr [RSP + 0x54] XOR EDX,EDX DIV dword ptr [RSP + 0x50] MOV EAX,EDX MOV qword ptr [RSP],RAX MOV ECX,dword ptr [RSP + 0x50] MOV EAX,dword ptr [RSP + 0x54] XOR EDX,EDX DIV ECX MOV dword ptr [RSP + 0x54],EAX MOV RCX,qword ptr [RSP] LEA RAX,[0x20a440] MOV CL,byte ptr [RAX + RCX*0x1] MOV RAX,qword ptr [RSP + 0x8] MOV RDX,RAX ADD RDX,-0x1 MOV qword ptr [RSP + 0x8],RDX MOV byte ptr [RAX],CL JMP 0x0011fdc7 LAB_0011fe14: MOV EAX,dword ptr [RSP + 0x54] MOV ECX,EAX LEA RAX,[0x20a440] MOV CL,byte ptr [RAX + RCX*0x1] MOV RAX,qword ptr [RSP + 0x8] MOV byte ptr [RAX],CL MOV RAX,qword ptr [RSP + 0x20] MOV qword ptr [RSP + 0x60],RAX LAB_0011fe35: MOV RAX,qword ptr [RSP + 0x60] ADD RSP,0x68 RET
long u32toa_radix(char *param_1,uint param_2,uint param_3) { byte bVar1; ulong uVar2; uint uVar3; int iVar4; uint uVar5; char *local_60; uint local_54; long local_48; char *local_38; uint local_14; long local_8; if (param_3 == 10) { local_8 = u32toa(param_1,param_2); } else if (param_2 < param_3) { *param_1 = "0123456789abcdefghijklmnopqrstuvwxyz"[param_2]; param_1[1] = '\0'; local_8 = 1; } else { bVar1 = radix_shift[param_3 & 0x3f]; uVar5 = (uint)bVar1; if (uVar5 == 0) { local_48 = 2; local_14 = param_2 / param_3; for (local_54 = param_3; local_54 <= local_14; local_54 = param_3 * local_54) { local_48 = local_48 + 1; } param_1 = param_1 + local_48; *param_1 = '\0'; param_1[-1] = "0123456789abcdefghijklmnopqrstuvwxyz"[(ulong)param_2 % (ulong)param_3]; local_60 = param_1 + -2; while (param_3 <= local_14) { uVar2 = (ulong)local_14; local_14 = local_14 / param_3; *local_60 = "0123456789abcdefghijklmnopqrstuvwxyz"[uVar2 % (ulong)param_3]; local_60 = local_60 + -1; } *local_60 = "0123456789abcdefghijklmnopqrstuvwxyz"[local_14]; local_8 = local_48; } else { uVar3 = (1 << (bVar1 & 0x1f)) - 1; iVar4 = clz32(param_2); local_8 = (long)((int)((uVar5 - iVar4) + 0x1f) / (int)uVar5); param_1 = param_1 + local_8; local_14 = param_2 >> (bVar1 & 0x1f); *param_1 = '\0'; param_1[-1] = "0123456789abcdefghijklmnopqrstuvwxyz"[param_2 & uVar3]; local_38 = param_1 + -2; while (param_3 <= local_14) { uVar5 = local_14 & uVar3; local_14 = local_14 >> (bVar1 & 0x1f); *local_38 = "0123456789abcdefghijklmnopqrstuvwxyz"[uVar5]; local_38 = local_38 + -1; } *local_38 = "0123456789abcdefghijklmnopqrstuvwxyz"[local_14]; } } return local_8; }
27,597
u32toa_radix
bluesky950520[P]quickjs/cutils.c
size_t u32toa_radix(char buf[minimum_length(33)], uint32_t n, unsigned base) { int shift; #ifdef USE_SPECIAL_RADIX_10 if (likely(base == 10)) return u32toa(buf, n); #endif if (n < base) { buf[0] = digits36[n]; buf[1] = '\0'; return 1; } shift = radix_shift[base & 63]; if (shift) { uint32_t mask = (1 << shift) - 1; size_t len = (32 - clz32(n) + shift - 1) / shift; size_t last = n & mask; char *end = buf + len; n >>= shift; *end-- = '\0'; *end-- = digits36[last]; while (n >= base) { size_t quo = n & mask; n >>= shift; *end-- = digits36[quo]; } *end = digits36[n]; return len; } else { size_t len = 2; size_t last = n % base; n /= base; uint32_t nbase = base; while (n >= nbase) { nbase *= base; len++; } char *end = buf + len; *end-- = '\0'; *end-- = digits36[last]; while (n >= base) { size_t quo = n % base; n /= base; *end-- = digits36[quo]; } *end = digits36[n]; return len; } }
O2
c
u32toa_radix: cmpl $0xa, %edx jne 0x16615 jmp 0x16482 movl %edx, %r8d cmpl %edx, %esi jae 0x16637 movl %esi, %eax leaq 0x6cc9b(%rip), %rcx # 0x832c0 movb (%rax,%rcx), %al movb %al, (%rdi) movb $0x0, 0x1(%rdi) pushq $0x1 popq %r9 jmp 0x16700 movl %r8d, %eax andl $0x3f, %eax leaq 0x6ccac(%rip), %rcx # 0x832f0 movzbl (%rax,%rcx), %ecx testl %ecx, %ecx je 0x166af pushq $-0x1 popq %r10 shll %cl, %r10d notl %r10d bsrl %esi, %eax xorl $0x1f, %eax negl %eax addl %ecx, %eax addl $0x1f, %eax xorl %edx, %edx divw %cx movzwl %ax, %r9d movl %r10d, %r11d andl %esi, %r11d leaq (%rdi,%r9), %rax addq $-0x2, %rax movb $0x0, 0x2(%rax) leaq 0x6cc3b(%rip), %rdx # 0x832c0 movb (%r11,%rdx), %dil movb %dil, 0x1(%rax) movl %esi, %esi shrq %cl, %rsi cmpl %r8d, %esi jb 0x166a8 movl %esi, %edi andl %r10d, %edi movb (%rdi,%rdx), %dil movb %dil, (%rax) decq %rax jmp 0x1668d movb (%rsi,%rdx), %cl movb %cl, (%rax) jmp 0x16700 movl %esi, %eax xorl %edx, %edx divl %r8d pushq $0x2 popq %r9 movl %r8d, %ecx cmpl %ecx, %eax jb 0x166ca imull %r8d, %ecx incq %r9 jmp 0x166bd movl %edx, %edx leaq (%rdi,%r9), %rcx addq $-0x2, %rcx movb $0x0, 0x2(%rcx) leaq 0x6cbe1(%rip), %rsi # 0x832c0 movb (%rdx,%rsi), %dl movb %dl, 0x1(%rcx) cmpl %r8d, %eax jb 0x166f9 xorl %edx, %edx divl %r8d movb (%rdx,%rsi), %dl movb %dl, (%rcx) decq %rcx jmp 0x166e5 movl %eax, %eax movb (%rax,%rsi), %al movb %al, (%rcx) movq %r9, %rax retq
u32toa_radix: cmp edx, 0Ah jnz short loc_16615 jmp u32toa loc_16615: mov r8d, edx cmp esi, edx jnb short loc_16637 mov eax, esi lea rcx, digits36; "0123456789abcdefghijklmnopqrstuvwxyz" mov al, [rax+rcx] mov [rdi], al mov byte ptr [rdi+1], 0 push 1 pop r9 jmp loc_16700 loc_16637: mov eax, r8d and eax, 3Fh lea rcx, radix_shift movzx ecx, byte ptr [rax+rcx] test ecx, ecx jz short loc_166AF push 0FFFFFFFFFFFFFFFFh pop r10 shl r10d, cl not r10d bsr eax, esi xor eax, 1Fh neg eax add eax, ecx add eax, 1Fh xor edx, edx div cx movzx r9d, ax mov r11d, r10d and r11d, esi lea rax, [rdi+r9] add rax, 0FFFFFFFFFFFFFFFEh mov byte ptr [rax+2], 0 lea rdx, digits36; "0123456789abcdefghijklmnopqrstuvwxyz" mov dil, [r11+rdx] mov [rax+1], dil loc_1668D: mov esi, esi shr rsi, cl cmp esi, r8d jb short loc_166A8 mov edi, esi and edi, r10d mov dil, [rdi+rdx] mov [rax], dil dec rax jmp short loc_1668D loc_166A8: mov cl, [rsi+rdx] mov [rax], cl jmp short loc_16700 loc_166AF: mov eax, esi xor edx, edx div r8d push 2 pop r9 mov ecx, r8d loc_166BD: cmp eax, ecx jb short loc_166CA imul ecx, r8d inc r9 jmp short loc_166BD loc_166CA: mov edx, edx lea rcx, [rdi+r9] add rcx, 0FFFFFFFFFFFFFFFEh mov byte ptr [rcx+2], 0 lea rsi, digits36; "0123456789abcdefghijklmnopqrstuvwxyz" mov dl, [rdx+rsi] mov [rcx+1], dl loc_166E5: cmp eax, r8d jb short loc_166F9 xor edx, edx div r8d mov dl, [rdx+rsi] mov [rcx], dl dec rcx jmp short loc_166E5 loc_166F9: mov eax, eax mov al, [rax+rsi] mov [rcx], al loc_16700: mov rax, r9 retn
long long u32toa_radix(_BYTE *a1, unsigned long long a2, unsigned int a3) { long long v5; // r9 long long v6; // rax unsigned __int16 v7; // cx unsigned int v8; // eax _BYTE *v9; // rax unsigned int v10; // eax unsigned int v11; // ecx _BYTE *v12; // rcx long long v13; // rdx if ( a3 == 10 ) return u32toa(a1, a2); if ( (unsigned int)a2 >= a3 ) { v6 = a3 & 0x3F; v7 = radix_shift[v6]; if ( radix_shift[v6] ) { _BitScanReverse(&v8, a2); v5 = (unsigned __int16)((unsigned __int16)(v7 - (v8 ^ 0x1F) + 31) / v7); v9 = &a1[v5 - 2]; v9[2] = 0; v9[1] = digits36[(unsigned int)a2 & ~(-1 << v7)]; while ( 1 ) { a2 = (unsigned long long)(unsigned int)a2 >> v7; if ( (unsigned int)a2 < a3 ) break; *v9-- = digits36[~(-1 << v7) & (unsigned int)a2]; } *v9 = digits36[a2]; } else { v10 = (unsigned int)a2 / a3; v5 = 2LL; v11 = a3; while ( v10 >= v11 ) { v11 *= a3; ++v5; } v12 = &a1[v5 - 2]; v12[2] = 0; v12[1] = digits36[(unsigned int)a2 % a3]; while ( v10 >= a3 ) { v13 = v10 % a3; v10 /= a3; *v12-- = digits36[v13]; } *v12 = digits36[v10]; } } else { *a1 = digits36[(unsigned int)a2]; a1[1] = 0; return 1LL; } return v5; }
u32toa_radix: CMP EDX,0xa JNZ 0x00116615 JMP 0x00116482 LAB_00116615: MOV R8D,EDX CMP ESI,EDX JNC 0x00116637 MOV EAX,ESI LEA RCX,[0x1832c0] MOV AL,byte ptr [RAX + RCX*0x1] MOV byte ptr [RDI],AL MOV byte ptr [RDI + 0x1],0x0 PUSH 0x1 POP R9 JMP 0x00116700 LAB_00116637: MOV EAX,R8D AND EAX,0x3f LEA RCX,[0x1832f0] MOVZX ECX,byte ptr [RAX + RCX*0x1] TEST ECX,ECX JZ 0x001166af PUSH -0x1 POP R10 SHL R10D,CL NOT R10D BSR EAX,ESI XOR EAX,0x1f NEG EAX ADD EAX,ECX ADD EAX,0x1f XOR EDX,EDX DIV CX MOVZX R9D,AX MOV R11D,R10D AND R11D,ESI LEA RAX,[RDI + R9*0x1] ADD RAX,-0x2 MOV byte ptr [RAX + 0x2],0x0 LEA RDX,[0x1832c0] MOV DIL,byte ptr [R11 + RDX*0x1] MOV byte ptr [RAX + 0x1],DIL LAB_0011668d: MOV ESI,ESI SHR RSI,CL CMP ESI,R8D JC 0x001166a8 MOV EDI,ESI AND EDI,R10D MOV DIL,byte ptr [RDI + RDX*0x1] MOV byte ptr [RAX],DIL DEC RAX JMP 0x0011668d LAB_001166a8: MOV CL,byte ptr [RSI + RDX*0x1] MOV byte ptr [RAX],CL JMP 0x00116700 LAB_001166af: MOV EAX,ESI XOR EDX,EDX DIV R8D PUSH 0x2 POP R9 MOV ECX,R8D LAB_001166bd: CMP EAX,ECX JC 0x001166ca IMUL ECX,R8D INC R9 JMP 0x001166bd LAB_001166ca: MOV EDX,EDX LEA RCX,[RDI + R9*0x1] ADD RCX,-0x2 MOV byte ptr [RCX + 0x2],0x0 LEA RSI,[0x1832c0] MOV DL,byte ptr [RDX + RSI*0x1] MOV byte ptr [RCX + 0x1],DL LAB_001166e5: CMP EAX,R8D JC 0x001166f9 XOR EDX,EDX DIV R8D MOV DL,byte ptr [RDX + RSI*0x1] MOV byte ptr [RCX],DL DEC RCX JMP 0x001166e5 LAB_001166f9: MOV EAX,EAX MOV AL,byte ptr [RAX + RSI*0x1] MOV byte ptr [RCX],AL LAB_00116700: MOV RAX,R9 RET
ulong u32toa_radix(char *param_1,ulong param_2,uint param_3) { byte bVar1; uint uVar2; ulong uVar3; ulong uVar4; char *pcVar5; ulong uVar6; uint uVar7; ulong uVar8; uint uVar9; if (param_3 == 10) { uVar4 = u32toa(); return uVar4; } uVar4 = (ulong)param_3; uVar7 = (uint)param_2; if (uVar7 < param_3) { *param_1 = "0123456789abcdefghijklmnopqrstuvwxyz"[param_2 & 0xffffffff]; param_1[1] = '\0'; uVar8 = 1; } else { bVar1 = radix_shift[param_3 & 0x3f]; if (bVar1 == 0) { uVar3 = (param_2 & 0xffffffff) / (ulong)param_3; uVar8 = 2; for (uVar6 = uVar4; (uint)uVar6 <= (uint)uVar3; uVar6 = (ulong)((uint)uVar6 * param_3)) { uVar8 = uVar8 + 1; } param_1 = param_1 + uVar8; pcVar5 = param_1 + -2; *param_1 = '\0'; param_1[-1] = "0123456789abcdefghijklmnopqrstuvwxyz"[(param_2 & 0xffffffff) % (ulong)param_3]; for (; param_3 <= (uint)uVar3; uVar3 = uVar3 / uVar4) { *pcVar5 = "0123456789abcdefghijklmnopqrstuvwxyz"[uVar3 % uVar4]; pcVar5 = pcVar5 + -1; } *pcVar5 = "0123456789abcdefghijklmnopqrstuvwxyz"[uVar3]; } else { uVar9 = ~(-1 << (bVar1 & 0x1f)); uVar2 = 0x1f; if (uVar7 != 0) { for (; uVar7 >> uVar2 == 0; uVar2 = uVar2 - 1) { } } uVar8 = (ulong)(ushort)((((uint)bVar1 - (uVar2 ^ 0x1f)) + 0x1f & 0xffff) / (uint)bVar1); param_1 = param_1 + uVar8; pcVar5 = param_1 + -2; *param_1 = '\0'; param_1[-1] = "0123456789abcdefghijklmnopqrstuvwxyz"[uVar9 & uVar7]; while( true ) { param_2 = (param_2 & 0xffffffff) >> (bVar1 & 0x3f); if ((uint)param_2 < param_3) break; *pcVar5 = "0123456789abcdefghijklmnopqrstuvwxyz"[(uint)param_2 & uVar9]; pcVar5 = pcVar5 + -1; } *pcVar5 = "0123456789abcdefghijklmnopqrstuvwxyz"[param_2]; } } return uVar8; }
27,598
u32toa_radix
bluesky950520[P]quickjs/cutils.c
size_t u32toa_radix(char buf[minimum_length(33)], uint32_t n, unsigned base) { int shift; #ifdef USE_SPECIAL_RADIX_10 if (likely(base == 10)) return u32toa(buf, n); #endif if (n < base) { buf[0] = digits36[n]; buf[1] = '\0'; return 1; } shift = radix_shift[base & 63]; if (shift) { uint32_t mask = (1 << shift) - 1; size_t len = (32 - clz32(n) + shift - 1) / shift; size_t last = n & mask; char *end = buf + len; n >>= shift; *end-- = '\0'; *end-- = digits36[last]; while (n >= base) { size_t quo = n & mask; n >>= shift; *end-- = digits36[quo]; } *end = digits36[n]; return len; } else { size_t len = 2; size_t last = n % base; n /= base; uint32_t nbase = base; while (n >= nbase) { nbase *= base; len++; } char *end = buf + len; *end-- = '\0'; *end-- = digits36[last]; while (n >= base) { size_t quo = n % base; n /= base; *end-- = digits36[quo]; } *end = digits36[n]; return len; } }
O3
c
u32toa_radix: cmpl $0xa, %edx je 0x1c568 movl %edx, %r8d cmpl %edx, %esi jae 0x1c72e movl %esi, %eax leaq 0x82c16(%rip), %rcx # 0x9f330 movb (%rax,%rcx), %al movb %al, (%rdi) movb $0x0, 0x1(%rdi) movl $0x1, %r9d jmp 0x1c7d8 movl %r8d, %eax andl $0x3f, %eax leaq 0x82c25(%rip), %rcx # 0x9f360 movzbl (%rax,%rcx), %ecx testl %ecx, %ecx je 0x1c7a7 movl $0xffffffff, %r10d # imm = 0xFFFFFFFF shll %cl, %r10d notl %r10d bsrl %esi, %eax xorl $0x1f, %eax negl %eax addl %ecx, %eax addl $0x1f, %eax xorl %edx, %edx divw %cx movzwl %ax, %r9d movl %r10d, %r11d andl %esi, %r11d leaq (%rdi,%r9), %rax addq $-0x2, %rax movb $0x0, 0x2(%rax) leaq 0x82bb2(%rip), %rdx # 0x9f330 movb (%r11,%rdx), %dil movb %dil, 0x1(%rax) shrl %cl, %esi cmpl %r8d, %esi jb 0x1c79e movl %esi, %edi andl %r10d, %edi movb (%rdi,%rdx), %dil movb %dil, (%rax) decq %rax jmp 0x1c786 movl %esi, %ecx movb (%rcx,%rdx), %cl movb %cl, (%rax) jmp 0x1c7d8 movl %esi, %eax xorl %edx, %edx divl %r8d cmpl %r8d, %eax jae 0x1c7dc movb $0x0, 0x2(%rdi) leaq 0x82b72(%rip), %rcx # 0x9f330 movb (%rdx,%rcx), %cl movb %cl, 0x1(%rdi) movl $0x2, %r9d movl %eax, %eax leaq 0x82b5d(%rip), %rcx # 0x9f330 movb (%rax,%rcx), %al movb %al, (%rdi) movq %r9, %rax retq movl $0x2, %r9d movl %r8d, %ecx imull %r8d, %ecx incq %r9 incq %rdi cmpl %ecx, %eax jae 0x1c7e5 movb $0x0, 0x2(%rdi) leaq 0x82b32(%rip), %rcx # 0x9f330 movb (%rdx,%rcx), %dl movb %dl, 0x1(%rdi) cmpl %r8d, %eax jb 0x1c7ca xorl %edx, %edx divl %r8d movb (%rdx,%rcx), %dl movb %dl, (%rdi) decq %rdi jmp 0x1c804
u32toa_radix: cmp edx, 0Ah jz u32toa mov r8d, edx cmp esi, edx jnb short loc_1C72E mov eax, esi lea rcx, digits36; "0123456789abcdefghijklmnopqrstuvwxyz" mov al, [rax+rcx] mov [rdi], al mov byte ptr [rdi+1], 0 mov r9d, 1 jmp loc_1C7D8 loc_1C72E: mov eax, r8d and eax, 3Fh lea rcx, radix_shift movzx ecx, byte ptr [rax+rcx] test ecx, ecx jz short loc_1C7A7 mov r10d, 0FFFFFFFFh shl r10d, cl not r10d bsr eax, esi xor eax, 1Fh neg eax add eax, ecx add eax, 1Fh xor edx, edx div cx movzx r9d, ax mov r11d, r10d and r11d, esi lea rax, [rdi+r9] add rax, 0FFFFFFFFFFFFFFFEh mov byte ptr [rax+2], 0 lea rdx, digits36; "0123456789abcdefghijklmnopqrstuvwxyz" mov dil, [r11+rdx] mov [rax+1], dil loc_1C786: shr esi, cl cmp esi, r8d jb short loc_1C79E mov edi, esi and edi, r10d mov dil, [rdi+rdx] mov [rax], dil dec rax jmp short loc_1C786 loc_1C79E: mov ecx, esi mov cl, [rcx+rdx] mov [rax], cl jmp short loc_1C7D8 loc_1C7A7: mov eax, esi xor edx, edx div r8d cmp eax, r8d jnb short loc_1C7DC mov byte ptr [rdi+2], 0 lea rcx, digits36; "0123456789abcdefghijklmnopqrstuvwxyz" mov cl, [rdx+rcx] mov [rdi+1], cl mov r9d, 2 loc_1C7CA: mov eax, eax lea rcx, digits36; "0123456789abcdefghijklmnopqrstuvwxyz" mov al, [rax+rcx] mov [rdi], al loc_1C7D8: mov rax, r9 retn loc_1C7DC: mov r9d, 2 mov ecx, r8d loc_1C7E5: imul ecx, r8d inc r9 inc rdi cmp eax, ecx jnb short loc_1C7E5 mov byte ptr [rdi+2], 0 lea rcx, digits36; "0123456789abcdefghijklmnopqrstuvwxyz" mov dl, [rdx+rcx] mov [rdi+1], dl loc_1C804: cmp eax, r8d jb short loc_1C7CA xor edx, edx div r8d mov dl, [rdx+rcx] mov [rdi], dl dec rdi jmp short loc_1C804
long long u32toa_radix(_BYTE *a1, unsigned int a2, unsigned int a3) { long long v4; // r9 long long v5; // rax unsigned __int16 v6; // cx unsigned int v7; // eax _BYTE *v8; // rax unsigned int v9; // eax long long v10; // rdx unsigned int v12; // ecx long long v13; // rdx if ( a3 == 10 ) return u32toa((long long)a1, a2); if ( a2 >= a3 ) { v5 = a3 & 0x3F; v6 = radix_shift[v5]; if ( radix_shift[v5] ) { _BitScanReverse(&v7, a2); v4 = (unsigned __int16)((unsigned __int16)(v6 - (v7 ^ 0x1F) + 31) / v6); v8 = &a1[v4 - 2]; v8[2] = 0; v8[1] = digits36[a2 & ~(-1 << v6)]; while ( 1 ) { a2 >>= v6; if ( a2 < a3 ) break; *v8-- = digits36[~(-1 << v6) & a2]; } *v8 = digits36[a2]; } else { v10 = a2 % a3; v9 = a2 / a3; if ( a2 / a3 >= a3 ) { v4 = 2LL; v12 = a3; do { v12 *= a3; ++v4; ++a1; } while ( v9 >= v12 ); a1[2] = 0; a1[1] = digits36[v10]; while ( v9 >= a3 ) { v13 = v9 % a3; v9 /= a3; *a1-- = digits36[v13]; } } else { a1[2] = 0; a1[1] = digits36[v10]; v4 = 2LL; } *a1 = digits36[v9]; } } else { *a1 = digits36[a2]; a1[1] = 0; return 1LL; } return v4; }
u32toa_radix: CMP EDX,0xa JZ 0x0011c568 MOV R8D,EDX CMP ESI,EDX JNC 0x0011c72e MOV EAX,ESI LEA RCX,[0x19f330] MOV AL,byte ptr [RAX + RCX*0x1] MOV byte ptr [RDI],AL MOV byte ptr [RDI + 0x1],0x0 MOV R9D,0x1 JMP 0x0011c7d8 LAB_0011c72e: MOV EAX,R8D AND EAX,0x3f LEA RCX,[0x19f360] MOVZX ECX,byte ptr [RAX + RCX*0x1] TEST ECX,ECX JZ 0x0011c7a7 MOV R10D,0xffffffff SHL R10D,CL NOT R10D BSR EAX,ESI XOR EAX,0x1f NEG EAX ADD EAX,ECX ADD EAX,0x1f XOR EDX,EDX DIV CX MOVZX R9D,AX MOV R11D,R10D AND R11D,ESI LEA RAX,[RDI + R9*0x1] ADD RAX,-0x2 MOV byte ptr [RAX + 0x2],0x0 LEA RDX,[0x19f330] MOV DIL,byte ptr [R11 + RDX*0x1] MOV byte ptr [RAX + 0x1],DIL LAB_0011c786: SHR ESI,CL CMP ESI,R8D JC 0x0011c79e MOV EDI,ESI AND EDI,R10D MOV DIL,byte ptr [RDI + RDX*0x1] MOV byte ptr [RAX],DIL DEC RAX JMP 0x0011c786 LAB_0011c79e: MOV ECX,ESI MOV CL,byte ptr [RCX + RDX*0x1] MOV byte ptr [RAX],CL JMP 0x0011c7d8 LAB_0011c7a7: MOV EAX,ESI XOR EDX,EDX DIV R8D CMP EAX,R8D JNC 0x0011c7dc MOV byte ptr [RDI + 0x2],0x0 LEA RCX,[0x19f330] MOV CL,byte ptr [RDX + RCX*0x1] MOV byte ptr [RDI + 0x1],CL MOV R9D,0x2 LAB_0011c7ca: MOV EAX,EAX LEA RCX,[0x19f330] MOV AL,byte ptr [RAX + RCX*0x1] MOV byte ptr [RDI],AL LAB_0011c7d8: MOV RAX,R9 RET LAB_0011c7dc: MOV R9D,0x2 MOV ECX,R8D LAB_0011c7e5: IMUL ECX,R8D INC R9 INC RDI CMP EAX,ECX JNC 0x0011c7e5 MOV byte ptr [RDI + 0x2],0x0 LEA RCX,[0x19f330] MOV DL,byte ptr [RDX + RCX*0x1] MOV byte ptr [RDI + 0x1],DL LAB_0011c804: CMP EAX,R8D JC 0x0011c7ca XOR EDX,EDX DIV R8D MOV DL,byte ptr [RDX + RCX*0x1] MOV byte ptr [RDI],DL DEC RDI JMP 0x0011c804
ulong u32toa_radix(byte *param_1,ulong param_2,uint param_3) { byte bVar1; long lVar2; byte *pbVar3; uint uVar4; ulong uVar5; uint uVar6; ulong uVar7; long lVar8; ulong uVar9; uint uVar10; uVar6 = (uint)param_2; if (param_3 != 10) { if (uVar6 < param_3) { *param_1 = "0123456789abcdefghijklmnopqrstuvwxyz"[param_2 & 0xffffffff]; param_1[1] = 0; uVar9 = 1; } else { bVar1 = radix_shift[param_3 & 0x3f]; if (bVar1 == 0) { uVar5 = (param_2 & 0xffffffff) / (ulong)param_3; uVar6 = (uint)uVar5; uVar7 = (param_2 & 0xffffffff) % (ulong)param_3; if (uVar6 < param_3) { param_1[2] = 0; param_1[1] = "0123456789abcdefghijklmnopqrstuvwxyz"[uVar7]; uVar9 = 2; } else { uVar9 = 2; uVar4 = param_3; do { pbVar3 = param_1; uVar4 = uVar4 * param_3; uVar9 = uVar9 + 1; param_1 = pbVar3 + 1; } while (uVar4 <= uVar6); pbVar3[3] = 0; pbVar3[2] = "0123456789abcdefghijklmnopqrstuvwxyz"[uVar7]; while( true ) { uVar6 = (uint)uVar5; if (uVar6 < param_3) break; *param_1 = "0123456789abcdefghijklmnopqrstuvwxyz"[uVar5 % (ulong)param_3]; param_1 = param_1 + -1; uVar5 = uVar5 / param_3; } } *param_1 = "0123456789abcdefghijklmnopqrstuvwxyz"[uVar6]; } else { uVar10 = ~(-1 << (bVar1 & 0x1f)); uVar4 = 0x1f; if (uVar6 != 0) { for (; uVar6 >> uVar4 == 0; uVar4 = uVar4 - 1) { } } uVar9 = (ulong)(ushort)((((uint)bVar1 - (uVar4 ^ 0x1f)) + 0x1f & 0xffff) / (uint)bVar1); param_1 = param_1 + uVar9; pbVar3 = param_1 + -2; *param_1 = 0; param_1[-1] = "0123456789abcdefghijklmnopqrstuvwxyz"[uVar10 & uVar6]; while( true ) { uVar6 = (uint)param_2 >> (bVar1 & 0x1f); param_2 = (ulong)uVar6; if (uVar6 < param_3) break; *pbVar3 = "0123456789abcdefghijklmnopqrstuvwxyz"[uVar6 & uVar10]; pbVar3 = pbVar3 + -1; } *pbVar3 = "0123456789abcdefghijklmnopqrstuvwxyz"[uVar6]; } } return uVar9; } if (uVar6 < 10) { *param_1 = (byte)param_2 | 0x30; param_1[1] = 0; return 1; } if (9999999 < uVar6) { uVar5 = (param_2 & 0xffffffff) / 10000000; uVar4 = (uint)uVar5; if (uVar6 < 100000000) { lVar2 = 1; lVar8 = 0; } else { lVar2 = 1; lVar8 = 0; do { uVar10 = (uint)uVar5; uVar4 = (uint)(uVar5 / 10); lVar8 = lVar8 * 0x100 + (ulong)(uVar10 + (int)(uVar5 / 10) * -10) + 0x30; lVar2 = lVar2 + 1; uVar5 = uVar5 / 10; } while (99 < uVar10); lVar8 = lVar8 * 0x100; } *(ulong *)param_1 = (ulong)uVar4 + lVar8 + 0x30; param_1[lVar2 + 7] = 0; uVar5 = 7; uVar6 = uVar6 + (int)((param_2 & 0xffffffff) / 10000000) * -10000000; do { uVar4 = uVar6 / 10; (param_1 + lVar2)[uVar5 - 1] = (char)uVar6 + (char)(uVar6 / 10) * -10 | 0x30; uVar5 = uVar5 - 1; uVar6 = uVar4; } while (1 < uVar5); param_1[lVar2] = (char)uVar4 + 0x30; return lVar2 + 7; } uVar5 = 1; lVar2 = 0; do { uVar6 = (uint)param_2; uVar7 = param_2 & 0xffffffff; param_2 = uVar7 / 10; lVar2 = lVar2 * 0x100 + (ulong)(uVar6 + (int)(uVar7 / 10) * -10) + 0x30; uVar5 = uVar5 + 1; } while (99 < uVar6); *(ulong *)param_1 = lVar2 * 0x100 + param_2 + 0x30; return uVar5; }
27,599
coro::detail::when_all_task<void> coro::detail::make_when_all_task<coro::task<void>, void>(coro::task<void>) (.resume)
AlayaLite/build_O3/_deps/libcoro-src/include/coro/when_all.hpp
static auto make_when_all_task(awaitable a) -> when_all_task<return_type> { if constexpr (std::is_void_v<return_type>) { co_await static_cast<awaitable&&>(a); co_return; } else { co_yield co_await static_cast<awaitable&&>(a); } }
O3
cpp
coro::detail::when_all_task<void> coro::detail::make_when_all_task<coro::task<void>, void>(coro::task<void>) (.resume): pushq %r14 pushq %rbx pushq %rax movq %rdi, %rbx cmpb $0x0, 0x30(%rdi) je 0x2c2a movq 0x20(%rbx), %rdi leaq 0x10(%rbx), %r14 addq $0x10, %rdi callq 0x3dfe movq $0x0, (%rbx) movb $0x2, 0x30(%rbx) movq 0x10(%rbx), %rax lock decq (%rax) jne 0x2c22 movq 0x8(%rax), %rdi callq *(%rdi) addq $0x8, %rsp popq %rbx popq %r14 retq movq 0x28(%rbx), %rdi movq %rdi, 0x20(%rbx) cmpq $0x0, (%rdi) je 0x2bfa movb $0x1, 0x30(%rbx) movq %rbx, 0x10(%rdi) movq 0x20(%rbx), %rdi addq $0x8, %rsp popq %rbx popq %r14 jmpq *(%rdi) movq %rax, %rdi callq 0x30ea movq %rax, %rdi callq 0x2090 movq %r14, %rdi callq 0x3da6 callq 0x2210 jmp 0x2c07 movq $0x0, (%rbx) movb $0x2, 0x30(%rbx) movq %rax, %rdi callq 0x2250
_ZN4coro6detailL18make_when_all_taskITkNS_8concepts9awaitableENS_4taskIvEEvEENS0_13when_all_taskIT0_EET__resume: push r14 push rbx push rax mov rbx, rdi cmp byte ptr [rdi+30h], 0 jz short loc_2C2A mov rdi, [rbx+20h] loc_2BFA: lea r14, [rbx+10h] add rdi, 10h call _ZN4coro6detail7promiseIvE6resultEv; coro::detail::promise<void>::result(void) loc_2C07: mov qword ptr [rbx], 0 mov byte ptr [rbx+30h], 2 mov rax, [rbx+10h] lock dec qword ptr [rax] jnz short loc_2C22 mov rdi, [rax+8] call qword ptr [rdi] loc_2C22: add rsp, 8 pop rbx pop r14 retn loc_2C2A: mov rdi, [rbx+28h] mov [rbx+20h], rdi cmp qword ptr [rdi], 0 jz short loc_2BFA mov byte ptr [rbx+30h], 1 mov [rdi+10h], rbx mov rdi, [rbx+20h] add rsp, 8 pop rbx pop r14 jmp qword ptr [rdi] mov rdi, rax call __clang_call_terminate mov rdi, rax; void * call ___cxa_begin_catch mov rdi, r14 call _ZN4coro6detail21when_all_task_promiseIvE19unhandled_exceptionEv; coro::detail::when_all_task_promise<void>::unhandled_exception(void) call ___cxa_end_catch jmp short loc_2C07 mov qword ptr [rbx], 0 mov byte ptr [rbx+30h], 2 mov rdi, rax call __Unwind_Resume
long long ZN4coro6detailL18make_when_all_taskITkNS_8concepts9awaitableENS_4taskIvEEvEENS0_13when_all_taskIT0_EET__resume( long long a1) { _QWORD *v2; // rdi long long result; // rax if ( *(_BYTE *)(a1 + 48) ) { v2 = *(_QWORD **)(a1 + 32); } else { v2 = *(_QWORD **)(a1 + 40); *(_QWORD *)(a1 + 32) = v2; if ( *v2 ) { *(_BYTE *)(a1 + 48) = 1; v2[2] = a1; return (**(long long (***)(void))(a1 + 32))(); } } coro::detail::promise<void>::result(v2 + 2); *(_QWORD *)a1 = 0LL; *(_BYTE *)(a1 + 48) = 2; result = *(_QWORD *)(a1 + 16); if ( !_InterlockedDecrement64((volatile signed long long *)result) ) return (**(long long ( ***)(_QWORD))(result + 8))(*(_QWORD *)(result + 8)); return result; }
_ZN4coro6detailL18make_when_all_taskITkNS_8concepts9awaitableENS_4taskIvEEvEENS0_13when_all_taskIT0_EET_.resume: PUSH R14 PUSH RBX PUSH RAX MOV RBX,RDI CMP byte ptr [RDI + 0x30],0x0 JZ 0x00102c2a MOV RDI,qword ptr [RBX + 0x20] LAB_00102bfa: LEA R14,[RBX + 0x10] ADD RDI,0x10 LAB_00102c02: CALL 0x00103dfe LAB_00102c07: MOV qword ptr [RBX],0x0 MOV byte ptr [RBX + 0x30],0x2 MOV RAX,qword ptr [RBX + 0x10] DEC.LOCK qword ptr [RAX] JNZ 0x00102c22 MOV RDI,qword ptr [RAX + 0x8] LAB_00102c20: CALL qword ptr [RDI] LAB_00102c22: ADD RSP,0x8 POP RBX POP R14 RET LAB_00102c2a: MOV RDI,qword ptr [RBX + 0x28] MOV qword ptr [RBX + 0x20],RDI CMP qword ptr [RDI],0x0 JZ 0x00102bfa MOV byte ptr [RBX + 0x30],0x1 MOV qword ptr [RDI + 0x10],RBX MOV RDI,qword ptr [RBX + 0x20] ADD RSP,0x8 POP RBX POP R14 JMP qword ptr [RDI]
void _ZN4coro6detailL18make_when_all_taskITkNS_8concepts9awaitableENS_4taskIvEEvEENS0_13when_all_taskIT0_EET__resume (int8 *param_1) { long *plVar1; if (*(char *)(param_1 + 6) == '\0') { plVar1 = (long *)param_1[5]; param_1[4] = plVar1; if (*plVar1 != 0) { *(int1 *)(param_1 + 6) = 1; plVar1[2] = (long)param_1; /* WARNING: Could not recover jumptable at 0x00102c4b. Too many branches */ /* WARNING: Treating indirect jump as call */ (**(code **)param_1[4])(); return; } } else { plVar1 = (long *)param_1[4]; } /* try { // try from 00102c02 to 00102c06 has its CatchHandler @ 00102c55 */ coro::detail::promise<void>::result((promise<void> *)(plVar1 + 2)); *param_1 = 0; *(int1 *)(param_1 + 6) = 2; plVar1 = (long *)param_1[2]; LOCK(); *plVar1 = *plVar1 + -1; UNLOCK(); if (*plVar1 == 0) { /* try { // try from 00102c20 to 00102c21 has its CatchHandler @ 00102c4d */ (**(code **)plVar1[1])(); } return; }