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
6,000
YogaTest_dirtied_Test::~YogaTest_dirtied_Test()
yoga-mod/tests/YGDirtiedTest.cpp
TEST(YogaTest, dirtied) { YGNodeRef root = YGNodeNew(); YGNodeStyleSetAlignItems(root, YGAlignFlexStart); YGNodeStyleSetWidth(root, 100); YGNodeStyleSetHeight(root, 100); YGNodeCalculateLayout(root, YGUndefined, YGUndefined, YGDirectionLTR); int dirtiedCount = 0; YGNodeSetContext(root, &dirtiedCount); YGNodeSetDirtiedFunc(root, _dirtied); ASSERT_EQ(0, dirtiedCount); // `_dirtied` MUST be called in case of explicit dirtying. static_cast<yoga::Node*>(root)->setDirty(true); ASSERT_EQ(1, dirtiedCount); // `_dirtied` MUST be called ONCE. static_cast<yoga::Node*>(root)->setDirty(true); ASSERT_EQ(1, dirtiedCount); }
O0
cpp
YogaTest_dirtied_Test::~YogaTest_dirtied_Test(): pushq %rbp movq %rsp, %rbp subq $0x10, %rsp movq %rdi, -0x8(%rbp) movq -0x8(%rbp), %rdi movq %rdi, -0x10(%rbp) callq 0xf4b70 movq -0x10(%rbp), %rdi movl $0x10, %esi callq 0x354d0 addq $0x10, %rsp popq %rbp retq nopl (%rax)
_ZN21YogaTest_dirtied_TestD0Ev: 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 _ZN21YogaTest_dirtied_TestD2Ev; YogaTest_dirtied_Test::~YogaTest_dirtied_Test() mov rdi, [rbp+var_10]; void * mov esi, 10h; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) add rsp, 10h pop rbp retn
void YogaTest_dirtied_Test::~YogaTest_dirtied_Test(YogaTest_dirtied_Test *this) { YogaTest_dirtied_Test::~YogaTest_dirtied_Test(this); operator delete(this, 0x10uLL); }
~YogaTest_dirtied_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 0x001f4b70 MOV RDI,qword ptr [RBP + -0x10] MOV ESI,0x10 CALL 0x001354d0 ADD RSP,0x10 POP RBP RET
/* YogaTest_dirtied_Test::~YogaTest_dirtied_Test() */ void __thiscall YogaTest_dirtied_Test::~YogaTest_dirtied_Test(YogaTest_dirtied_Test *this) { ~YogaTest_dirtied_Test(this); operator_delete(this,0x10); return; }
6,001
llama_adapter_cvec::apply_to(ggml_context*, ggml_tensor*, int) const
monkey531[P]llama/src/llama-adapter.cpp
struct ggml_tensor * llama_adapter_cvec::tensor_for(int il) const { if (il < 0 || il < layer_start || il > layer_end || (size_t) il >= tensors.size()) { return nullptr; } return tensors[il]; }
O3
cpp
llama_adapter_cvec::apply_to(ggml_context*, ggml_tensor*, int) const: testl %ecx, %ecx js 0x92bd8 cmpl %ecx, (%rdi) jg 0x92bd8 cmpl %ecx, 0x4(%rdi) jl 0x92bd8 movl %ecx, %eax movq 0x38(%rdi), %rcx movq 0x40(%rdi), %rdi subq %rcx, %rdi sarq $0x3, %rdi cmpq %rax, %rdi jbe 0x92bd8 movq (%rcx,%rax,8), %rax testq %rax, %rax je 0x92bd8 movq %rsi, %rdi movq %rdx, %rsi movq %rax, %rdx jmp 0x65e00 movq %rdx, %rax retq
_ZNK18llama_adapter_cvec8apply_toEP12ggml_contextP11ggml_tensori: test ecx, ecx js short loc_92BD8 cmp [rdi], ecx jg short loc_92BD8 cmp [rdi+4], ecx jl short loc_92BD8 mov eax, ecx mov rcx, [rdi+38h] mov rdi, [rdi+40h] sub rdi, rcx sar rdi, 3 cmp rdi, rax jbe short loc_92BD8 mov rax, [rcx+rax*8] test rax, rax jz short loc_92BD8 mov rdi, rsi mov rsi, rdx mov rdx, rax jmp _ggml_add loc_92BD8: mov rax, rdx retn
long long llama_adapter_cvec::apply_to(long long a1, long long a2, long long a3, int a4, float a5) { unsigned long long v5; // rax long long v6; // rcx long long v7; // rax if ( a4 >= 0 && *(_DWORD *)a1 <= a4 && *(_DWORD *)(a1 + 4) >= a4 && (v5 = (unsigned int)a4, v6 = *(_QWORD *)(a1 + 56), (*(_QWORD *)(a1 + 64) - v6) >> 3 > v5) && (v7 = *(_QWORD *)(v6 + 8 * v5)) != 0 ) { return ggml_add(a2, a3, v7, a5); } else { return a3; } }
apply_to: TEST ECX,ECX JS 0x00192bd8 CMP dword ptr [RDI],ECX JG 0x00192bd8 CMP dword ptr [RDI + 0x4],ECX JL 0x00192bd8 MOV EAX,ECX MOV RCX,qword ptr [RDI + 0x38] MOV RDI,qword ptr [RDI + 0x40] SUB RDI,RCX SAR RDI,0x3 CMP RDI,RAX JBE 0x00192bd8 MOV RAX,qword ptr [RCX + RAX*0x8] TEST RAX,RAX JZ 0x00192bd8 MOV RDI,RSI MOV RSI,RDX MOV RDX,RAX JMP 0x00165e00 LAB_00192bd8: MOV RAX,RDX RET
/* llama_adapter_cvec::apply_to(ggml_context*, ggml_tensor*, int) const */ ggml_tensor * __thiscall llama_adapter_cvec::apply_to (llama_adapter_cvec *this,ggml_context *param_1,ggml_tensor *param_2,int param_3) { long lVar1; ggml_tensor *pgVar2; if (((-1 < param_3) && (*(int *)this <= param_3)) && (param_3 <= *(int *)(this + 4))) { if (((ulong)(uint)param_3 < (ulong)(*(long *)(this + 0x40) - *(long *)(this + 0x38) >> 3)) && (lVar1 = *(long *)(*(long *)(this + 0x38) + (ulong)(uint)param_3 * 8), lVar1 != 0)) { pgVar2 = (ggml_tensor *)ggml_add(param_1,param_2,lVar1); return pgVar2; } } return param_2; }
6,002
my_strnxfrm_latin1_de
eloqsql/strings/ctype-latin1.c
static size_t my_strnxfrm_latin1_de(CHARSET_INFO *cs, uchar *dst, size_t dstlen, uint nweights, const uchar* src, size_t srclen, uint flags) { uchar *de= dst + dstlen; const uchar *se= src + srclen; uchar *d0= dst; for ( ; src < se && dst < de && nweights; src++, nweights--) { uchar chr= combo1map[*src]; *dst++= chr; if ((chr= combo2map[*src]) && dst < de && nweights > 1) { *dst++= chr; nweights--; } } return my_strxfrm_pad_desc_and_reverse(cs, d0, dst, de, nweights, flags, 0); }
O0
c
my_strnxfrm_latin1_de: pushq %rbp movq %rsp, %rbp subq $0x60, %rsp movl 0x10(%rbp), %eax movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq %rdx, -0x18(%rbp) movl %ecx, -0x1c(%rbp) movq %r8, -0x28(%rbp) movq %r9, -0x30(%rbp) movq -0x10(%rbp), %rax addq -0x18(%rbp), %rax movq %rax, -0x38(%rbp) movq -0x28(%rbp), %rax addq -0x30(%rbp), %rax movq %rax, -0x40(%rbp) movq -0x10(%rbp), %rax movq %rax, -0x48(%rbp) movq -0x28(%rbp), %rcx xorl %eax, %eax cmpq -0x40(%rbp), %rcx movb %al, -0x4a(%rbp) jae 0x3edfa movq -0x10(%rbp), %rcx xorl %eax, %eax cmpq -0x38(%rbp), %rcx movb %al, -0x4a(%rbp) jae 0x3edfa cmpl $0x0, -0x1c(%rbp) setne %al movb %al, -0x4a(%rbp) movb -0x4a(%rbp), %al testb $0x1, %al jne 0x3ee06 jmp 0x3ee97 movq -0x28(%rbp), %rax movzbl (%rax), %eax movl %eax, %ecx leaq 0xfe9fa(%rip), %rax # 0x13d810 movb (%rax,%rcx), %al movb %al, -0x49(%rbp) movb -0x49(%rbp), %cl movq -0x10(%rbp), %rax movq %rax, %rdx addq $0x1, %rdx movq %rdx, -0x10(%rbp) movb %cl, (%rax) movq -0x28(%rbp), %rax movzbl (%rax), %eax movl %eax, %ecx leaq 0xfead0(%rip), %rax # 0x13d910 movb (%rax,%rcx), %al movb %al, -0x49(%rbp) movzbl %al, %eax cmpl $0x0, %eax je 0x3ee7b movq -0x10(%rbp), %rax cmpq -0x38(%rbp), %rax jae 0x3ee7b cmpl $0x1, -0x1c(%rbp) jbe 0x3ee7b movb -0x49(%rbp), %cl movq -0x10(%rbp), %rax movq %rax, %rdx addq $0x1, %rdx movq %rdx, -0x10(%rbp) movb %cl, (%rax) movl -0x1c(%rbp), %eax addl $-0x1, %eax movl %eax, -0x1c(%rbp) jmp 0x3ee7d movq -0x28(%rbp), %rax addq $0x1, %rax movq %rax, -0x28(%rbp) movl -0x1c(%rbp), %eax addl $-0x1, %eax movl %eax, -0x1c(%rbp) jmp 0x3edd2 movq -0x8(%rbp), %rdi movq -0x48(%rbp), %rsi movq -0x10(%rbp), %rdx movq -0x38(%rbp), %rcx movl -0x1c(%rbp), %r8d movl 0x10(%rbp), %r9d xorl %eax, %eax movl $0x0, (%rsp) callq 0x41ea0 addq $0x60, %rsp popq %rbp retq nopw %cs:(%rax,%rax) nopl (%rax)
my_strnxfrm_latin1_de: push rbp mov rbp, rsp sub rsp, 60h mov eax, [rbp+arg_0] mov [rbp+var_8], rdi mov [rbp+var_10], rsi mov [rbp+var_18], rdx mov [rbp+var_1C], ecx mov [rbp+var_28], r8 mov [rbp+var_30], r9 mov rax, [rbp+var_10] add rax, [rbp+var_18] mov [rbp+var_38], rax mov rax, [rbp+var_28] add rax, [rbp+var_30] mov [rbp+var_40], rax mov rax, [rbp+var_10] mov [rbp+var_48], rax loc_3EDD2: mov rcx, [rbp+var_28] xor eax, eax cmp rcx, [rbp+var_40] mov [rbp+var_4A], al jnb short loc_3EDFA mov rcx, [rbp+var_10] xor eax, eax cmp rcx, [rbp+var_38] mov [rbp+var_4A], al jnb short loc_3EDFA cmp [rbp+var_1C], 0 setnz al mov [rbp+var_4A], al loc_3EDFA: mov al, [rbp+var_4A] test al, 1 jnz short loc_3EE06 jmp loc_3EE97 loc_3EE06: mov rax, [rbp+var_28] movzx eax, byte ptr [rax] mov ecx, eax lea rax, combo1map mov al, [rax+rcx] mov [rbp+var_49], al mov cl, [rbp+var_49] mov rax, [rbp+var_10] mov rdx, rax add rdx, 1 mov [rbp+var_10], rdx mov [rax], cl mov rax, [rbp+var_28] movzx eax, byte ptr [rax] mov ecx, eax lea rax, combo2map mov al, [rax+rcx] mov [rbp+var_49], al movzx eax, al cmp eax, 0 jz short loc_3EE7B mov rax, [rbp+var_10] cmp rax, [rbp+var_38] jnb short loc_3EE7B cmp [rbp+var_1C], 1 jbe short loc_3EE7B mov cl, [rbp+var_49] mov rax, [rbp+var_10] mov rdx, rax add rdx, 1 mov [rbp+var_10], rdx mov [rax], cl mov eax, [rbp+var_1C] add eax, 0FFFFFFFFh mov [rbp+var_1C], eax loc_3EE7B: jmp short $+2 loc_3EE7D: mov rax, [rbp+var_28] add rax, 1 mov [rbp+var_28], rax mov eax, [rbp+var_1C] add eax, 0FFFFFFFFh mov [rbp+var_1C], eax jmp loc_3EDD2 loc_3EE97: mov rdi, [rbp+var_8] mov rsi, [rbp+var_48] mov rdx, [rbp+var_10] mov rcx, [rbp+var_38] mov r8d, [rbp+var_1C] mov r9d, [rbp+arg_0] xor eax, eax mov [rsp+60h+var_60], 0 call my_strxfrm_pad_desc_and_reverse add rsp, 60h pop rbp retn
long long my_strnxfrm_latin1_de( int a1, unsigned __int8 *a2, long long a3, unsigned int a4, unsigned __int8 *a5, long long a6, int a7) { unsigned __int8 *v7; // rax unsigned __int8 *v8; // rax bool v10; // [rsp+16h] [rbp-4Ah] unsigned __int8 v11; // [rsp+17h] [rbp-49h] unsigned long long v12; // [rsp+28h] [rbp-38h] unsigned __int8 *v13; // [rsp+38h] [rbp-28h] unsigned __int8 *v15; // [rsp+50h] [rbp-10h] v15 = a2; v13 = a5; v12 = (unsigned long long)&a2[a3]; while ( 1 ) { v10 = 0; if ( v13 < &a5[a6] ) { v10 = 0; if ( (unsigned long long)v15 < v12 ) v10 = a4 != 0; } if ( !v10 ) break; v7 = v15++; *v7 = combo1map[*v13]; v11 = combo2map[*v13]; if ( v11 && (unsigned long long)v15 < v12 && a4 > 1 ) { v8 = v15++; *v8 = v11; --a4; } ++v13; --a4; } return my_strxfrm_pad_desc_and_reverse(a1, (_DWORD)a2, (_DWORD)v15, v12, a4, a7, 0); }
my_strnxfrm_latin1_de: PUSH RBP MOV RBP,RSP SUB RSP,0x60 MOV EAX,dword ptr [RBP + 0x10] MOV qword ptr [RBP + -0x8],RDI MOV qword ptr [RBP + -0x10],RSI MOV qword ptr [RBP + -0x18],RDX MOV dword ptr [RBP + -0x1c],ECX MOV qword ptr [RBP + -0x28],R8 MOV qword ptr [RBP + -0x30],R9 MOV RAX,qword ptr [RBP + -0x10] ADD RAX,qword ptr [RBP + -0x18] MOV qword ptr [RBP + -0x38],RAX MOV RAX,qword ptr [RBP + -0x28] ADD RAX,qword ptr [RBP + -0x30] MOV qword ptr [RBP + -0x40],RAX MOV RAX,qword ptr [RBP + -0x10] MOV qword ptr [RBP + -0x48],RAX LAB_0013edd2: MOV RCX,qword ptr [RBP + -0x28] XOR EAX,EAX CMP RCX,qword ptr [RBP + -0x40] MOV byte ptr [RBP + -0x4a],AL JNC 0x0013edfa MOV RCX,qword ptr [RBP + -0x10] XOR EAX,EAX CMP RCX,qword ptr [RBP + -0x38] MOV byte ptr [RBP + -0x4a],AL JNC 0x0013edfa CMP dword ptr [RBP + -0x1c],0x0 SETNZ AL MOV byte ptr [RBP + -0x4a],AL LAB_0013edfa: MOV AL,byte ptr [RBP + -0x4a] TEST AL,0x1 JNZ 0x0013ee06 JMP 0x0013ee97 LAB_0013ee06: MOV RAX,qword ptr [RBP + -0x28] MOVZX EAX,byte ptr [RAX] MOV ECX,EAX LEA RAX,[0x23d810] MOV AL,byte ptr [RAX + RCX*0x1] MOV byte ptr [RBP + -0x49],AL MOV CL,byte ptr [RBP + -0x49] MOV RAX,qword ptr [RBP + -0x10] MOV RDX,RAX ADD RDX,0x1 MOV qword ptr [RBP + -0x10],RDX MOV byte ptr [RAX],CL MOV RAX,qword ptr [RBP + -0x28] MOVZX EAX,byte ptr [RAX] MOV ECX,EAX LEA RAX,[0x23d910] MOV AL,byte ptr [RAX + RCX*0x1] MOV byte ptr [RBP + -0x49],AL MOVZX EAX,AL CMP EAX,0x0 JZ 0x0013ee7b MOV RAX,qword ptr [RBP + -0x10] CMP RAX,qword ptr [RBP + -0x38] JNC 0x0013ee7b CMP dword ptr [RBP + -0x1c],0x1 JBE 0x0013ee7b MOV CL,byte ptr [RBP + -0x49] MOV RAX,qword ptr [RBP + -0x10] MOV RDX,RAX ADD RDX,0x1 MOV qword ptr [RBP + -0x10],RDX MOV byte ptr [RAX],CL MOV EAX,dword ptr [RBP + -0x1c] ADD EAX,-0x1 MOV dword ptr [RBP + -0x1c],EAX LAB_0013ee7b: JMP 0x0013ee7d LAB_0013ee7d: MOV RAX,qword ptr [RBP + -0x28] ADD RAX,0x1 MOV qword ptr [RBP + -0x28],RAX MOV EAX,dword ptr [RBP + -0x1c] ADD EAX,-0x1 MOV dword ptr [RBP + -0x1c],EAX JMP 0x0013edd2 LAB_0013ee97: MOV RDI,qword ptr [RBP + -0x8] MOV RSI,qword ptr [RBP + -0x48] MOV RDX,qword ptr [RBP + -0x10] MOV RCX,qword ptr [RBP + -0x38] MOV R8D,dword ptr [RBP + -0x1c] MOV R9D,dword ptr [RBP + 0x10] XOR EAX,EAX MOV dword ptr [RSP],0x0 CALL 0x00141ea0 ADD RSP,0x60 POP RBP RET
void my_strnxfrm_latin1_de (int8 param_1,char *param_2,long param_3,uint param_4,byte *param_5, long param_6,int4 param_7) { char *pcVar1; char *pcVar2; bool bVar3; byte *local_30; uint local_24; char *local_18; pcVar1 = param_2 + param_3; local_30 = param_5; local_24 = param_4; local_18 = param_2; while( true ) { bVar3 = false; if ((local_30 < param_5 + param_6) && (bVar3 = false, local_18 < pcVar1)) { bVar3 = local_24 != 0; } if (!bVar3) break; pcVar2 = local_18 + 1; *local_18 = combo1map[*local_30]; if (((combo2map[*local_30] != '\0') && (pcVar2 < pcVar1)) && (1 < local_24)) { *pcVar2 = combo2map[*local_30]; local_24 = local_24 - 1; pcVar2 = local_18 + 2; } local_18 = pcVar2; local_30 = local_30 + 1; local_24 = local_24 - 1; } my_strxfrm_pad_desc_and_reverse(param_1,param_2,local_18,pcVar1,local_24,param_7,0); return; }
6,003
exchange_one_int128
bluesky950520[P]quickjs/cutils.c
static void exchange_one_int128(void *a, void *b, size_t size) { uint64_t *ap = (uint64_t *)a; uint64_t *bp = (uint64_t *)b; uint64_t t = ap[0]; uint64_t u = ap[1]; ap[0] = bp[0]; ap[1] = bp[1]; bp[0] = t; bp[1] = u; }
O1
c
exchange_one_int128: movq (%rsi), %rax movups (%rdi), %xmm0 movq %rax, (%rdi) movq 0x8(%rsi), %rax movq %rax, 0x8(%rdi) movups %xmm0, (%rsi) retq
exchange_one_int128: mov rax, [rsi] movups xmm0, xmmword ptr [rdi] mov [rdi], rax mov rax, [rsi+8] mov [rdi+8], rax movups xmmword ptr [rsi], xmm0 retn
long long exchange_one_int128(__int128 *a1, _QWORD *a2) { __int128 v2; // xmm0 long long result; // rax v2 = *a1; *(_QWORD *)a1 = *a2; result = a2[1]; *((_QWORD *)a1 + 1) = result; *(_OWORD *)a2 = v2; return result; }
exchange_one_int128: MOV RAX,qword ptr [RSI] MOVUPS XMM0,xmmword ptr [RDI] MOV qword ptr [RDI],RAX MOV RAX,qword ptr [RSI + 0x8] MOV qword ptr [RDI + 0x8],RAX MOVUPS xmmword ptr [RSI],XMM0 RET
void exchange_one_int128(int8 *param_1,int8 *param_2) { int8 uVar1; int8 uVar2; uVar1 = *param_1; uVar2 = param_1[1]; *param_1 = *param_2; param_1[1] = param_2[1]; *param_2 = uVar1; param_2[1] = uVar2; return; }
6,004
exchange_one_int128
bluesky950520[P]quickjs/cutils.c
static void exchange_one_int128(void *a, void *b, size_t size) { uint64_t *ap = (uint64_t *)a; uint64_t *bp = (uint64_t *)b; uint64_t t = ap[0]; uint64_t u = ap[1]; ap[0] = bp[0]; ap[1] = bp[1]; bp[0] = t; bp[1] = u; }
O3
c
exchange_one_int128: movq (%rsi), %rax movups (%rdi), %xmm0 movq %rax, (%rdi) movq 0x8(%rsi), %rax movq %rax, 0x8(%rdi) movups %xmm0, (%rsi) retq
exchange_one_int128: mov rax, [rsi] movups xmm0, xmmword ptr [rdi] mov [rdi], rax mov rax, [rsi+8] mov [rdi+8], rax movups xmmword ptr [rsi], xmm0 retn
long long exchange_one_int128(__int128 *a1, _QWORD *a2) { __int128 v2; // xmm0 long long result; // rax v2 = *a1; *(_QWORD *)a1 = *a2; result = a2[1]; *((_QWORD *)a1 + 1) = result; *(_OWORD *)a2 = v2; return result; }
exchange_one_int128: MOV RAX,qword ptr [RSI] MOVUPS XMM0,xmmword ptr [RDI] MOV qword ptr [RDI],RAX MOV RAX,qword ptr [RSI + 0x8] MOV qword ptr [RDI + 0x8],RAX MOVUPS xmmword ptr [RSI],XMM0 RET
void exchange_one_int128(int8 *param_1,int8 *param_2) { int8 uVar1; int8 uVar2; uVar1 = *param_1; uVar2 = param_1[1]; *param_1 = *param_2; param_1[1] = param_2[1]; *param_2 = uVar1; param_2[1] = uVar2; return; }
6,005
get_bin_log_name
eloqsql/client/mysqldump.c
static int get_bin_log_name(MYSQL *mysql_con, char* buff_log_name, uint buff_len) { MYSQL_RES *res; MYSQL_ROW row; if (mysql_query(mysql_con, "SHOW MASTER STATUS") || !(res= mysql_store_result(mysql))) return 1; if (!(row= mysql_fetch_row(res))) { mysql_free_result(res); return 1; } /* Only one row is returned, and the first column is the name of the active log. */ strmake(buff_log_name, row[0], buff_len - 1); mysql_free_result(res); return 0; }
O0
c
get_bin_log_name: pushq %rbp movq %rsp, %rbp subq $0x30, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movl %edx, -0x1c(%rbp) movq -0x10(%rbp), %rdi leaq 0xa086d(%rip), %rsi # 0xdb91b callq 0x4fe70 cmpl $0x0, %eax jne 0x3b0ce movq 0x3c6409(%rip), %rdi # 0x4014c8 callq 0x514c0 movq %rax, -0x28(%rbp) cmpq $0x0, %rax jne 0x3b0d7 movl $0x1, -0x4(%rbp) jmp 0x3b126 movq -0x28(%rbp), %rdi callq 0x51800 movq %rax, -0x30(%rbp) cmpq $0x0, %rax jne 0x3b0fc movq -0x28(%rbp), %rdi callq 0x48d00 movl $0x1, -0x4(%rbp) jmp 0x3b126 movq -0x18(%rbp), %rdi movq -0x30(%rbp), %rax movq (%rax), %rsi movl -0x1c(%rbp), %eax subl $0x1, %eax movl %eax, %eax movl %eax, %edx callq 0xd5860 movq -0x28(%rbp), %rdi callq 0x48d00 movl $0x0, -0x4(%rbp) movl -0x4(%rbp), %eax addq $0x30, %rsp popq %rbp retq nop
get_bin_log_name: push rbp mov rbp, rsp sub rsp, 30h mov [rbp+var_10], rdi mov [rbp+var_18], rsi mov [rbp+var_1C], edx mov rdi, [rbp+var_10] lea rsi, aShowMasterStat; "SHOW MASTER STATUS" call mysql_query cmp eax, 0 jnz short loc_3B0CE mov rdi, cs:mysql call mysql_store_result mov [rbp+var_28], rax cmp rax, 0 jnz short loc_3B0D7 loc_3B0CE: mov [rbp+var_4], 1 jmp short loc_3B126 loc_3B0D7: mov rdi, [rbp+var_28] call mysql_fetch_row mov [rbp+var_30], rax cmp rax, 0 jnz short loc_3B0FC mov rdi, [rbp+var_28] call mysql_free_result mov [rbp+var_4], 1 jmp short loc_3B126 loc_3B0FC: mov rdi, [rbp+var_18] mov rax, [rbp+var_30] mov rsi, [rax] mov eax, [rbp+var_1C] sub eax, 1 mov eax, eax mov edx, eax call strmake mov rdi, [rbp+var_28] call mysql_free_result mov [rbp+var_4], 0 loc_3B126: mov eax, [rbp+var_4] add rsp, 30h pop rbp retn
long long get_bin_log_name(long long a1, long long a2, int a3) { _QWORD *row; // [rsp+0h] [rbp-30h] long long v5; // [rsp+8h] [rbp-28h] if ( !(unsigned int)mysql_query(a1, "SHOW MASTER STATUS") && (v5 = mysql_store_result(mysql)) != 0 ) { row = (_QWORD *)mysql_fetch_row(v5); if ( row ) { strmake(a2, *row, (unsigned int)(a3 - 1)); mysql_free_result(v5); return 0; } else { mysql_free_result(v5); return 1; } } else { return 1; } }
get_bin_log_name: PUSH RBP MOV RBP,RSP SUB RSP,0x30 MOV qword ptr [RBP + -0x10],RDI MOV qword ptr [RBP + -0x18],RSI MOV dword ptr [RBP + -0x1c],EDX MOV RDI,qword ptr [RBP + -0x10] LEA RSI,[0x1db91b] CALL 0x0014fe70 CMP EAX,0x0 JNZ 0x0013b0ce MOV RDI,qword ptr [0x005014c8] CALL 0x001514c0 MOV qword ptr [RBP + -0x28],RAX CMP RAX,0x0 JNZ 0x0013b0d7 LAB_0013b0ce: MOV dword ptr [RBP + -0x4],0x1 JMP 0x0013b126 LAB_0013b0d7: MOV RDI,qword ptr [RBP + -0x28] CALL 0x00151800 MOV qword ptr [RBP + -0x30],RAX CMP RAX,0x0 JNZ 0x0013b0fc MOV RDI,qword ptr [RBP + -0x28] CALL 0x00148d00 MOV dword ptr [RBP + -0x4],0x1 JMP 0x0013b126 LAB_0013b0fc: MOV RDI,qword ptr [RBP + -0x18] MOV RAX,qword ptr [RBP + -0x30] MOV RSI,qword ptr [RAX] MOV EAX,dword ptr [RBP + -0x1c] SUB EAX,0x1 MOV EAX,EAX MOV EDX,EAX CALL 0x001d5860 MOV RDI,qword ptr [RBP + -0x28] CALL 0x00148d00 MOV dword ptr [RBP + -0x4],0x0 LAB_0013b126: MOV EAX,dword ptr [RBP + -0x4] ADD RSP,0x30 POP RBP RET
int4 get_bin_log_name(int8 param_1,int8 param_2,int param_3) { int iVar1; long lVar2; int8 *puVar3; iVar1 = mysql_query(param_1,"SHOW MASTER STATUS"); if ((iVar1 == 0) && (lVar2 = mysql_store_result(mysql), lVar2 != 0)) { puVar3 = (int8 *)mysql_fetch_row(lVar2); if (puVar3 == (int8 *)0x0) { mysql_free_result(lVar2); return 1; } strmake(param_2,*puVar3,param_3 + -1); mysql_free_result(lVar2); return 0; } return 1; }
6,006
ggml_get_rows
monkey531[P]llama/ggml/src/ggml.c
struct ggml_tensor * ggml_get_rows( struct ggml_context * ctx, struct ggml_tensor * a, struct ggml_tensor * b) { GGML_ASSERT(a->ne[2] == b->ne[1]); GGML_ASSERT(b->ne[3] == 1); GGML_ASSERT(b->type == GGML_TYPE_I32); // TODO: implement non F32 return enum ggml_type type = GGML_TYPE_F32; if (a->type == GGML_TYPE_I32) { type = a->type; } struct ggml_tensor * result = ggml_new_tensor_4d(ctx, type, a->ne[0], b->ne[0], b->ne[1], b->ne[2]); result->op = GGML_OP_GET_ROWS; result->src[0] = a; result->src[1] = b; return result; }
O1
c
ggml_get_rows: pushq %r14 pushq %rbx subq $0x28, %rsp movq 0x18(%rdx), %rax cmpq %rax, 0x20(%rsi) jne 0x1c36f movq %rdx, %rbx cmpq $0x1, 0x28(%rdx) jne 0x1c38b cmpl $0x1a, (%rbx) jne 0x1c3a7 movq %rsi, %r14 movl (%rsi), %esi xorl %ecx, %ecx cmpl $0x1a, %esi cmovnel %ecx, %esi movq 0x10(%r14), %rdx movq 0x10(%rbx), %r8 movq 0x20(%rbx), %r9 movq %rsp, %rcx movq %rdx, (%rcx) movq %r8, 0x8(%rcx) movq %rax, 0x10(%rcx) movq %r9, 0x18(%rcx) movl $0x4, %edx xorl %r8d, %r8d xorl %r9d, %r9d callq 0x19c80 movl $0x25, 0x50(%rax) movq %r14, 0x98(%rax) movq %rbx, 0xa0(%rax) addq $0x28, %rsp popq %rbx popq %r14 retq leaq 0x2e299(%rip), %rdi # 0x4a60f leaq 0x2e2dc(%rip), %rdx # 0x4a659 leaq 0x2e7c3(%rip), %rcx # 0x4ab47 movl $0xcd2, %esi # imm = 0xCD2 jmp 0x1c3c1 leaq 0x2e27d(%rip), %rdi # 0x4a60f leaq 0x2e2c0(%rip), %rdx # 0x4a659 leaq 0x2e50c(%rip), %rcx # 0x4a8ac movl $0xcd3, %esi # imm = 0xCD3 jmp 0x1c3c1 leaq 0x2e261(%rip), %rdi # 0x4a60f leaq 0x2e2a4(%rip), %rdx # 0x4a659 leaq 0x2e7ca(%rip), %rcx # 0x4ab86 movl $0xcd4, %esi # imm = 0xCD4 xorl %eax, %eax callq 0x17c70
ggml_get_rows: push r14 push rbx sub rsp, 28h mov rax, [rdx+18h] cmp [rsi+20h], rax jnz short loc_1C36F mov rbx, rdx cmp qword ptr [rdx+28h], 1 jnz short loc_1C38B cmp dword ptr [rbx], 1Ah jnz loc_1C3A7 mov r14, rsi mov esi, [rsi] xor ecx, ecx cmp esi, 1Ah cmovnz esi, ecx mov rdx, [r14+10h] mov r8, [rbx+10h] mov r9, [rbx+20h] mov rcx, rsp mov [rcx], rdx mov [rcx+8], r8 mov [rcx+10h], rax mov [rcx+18h], r9 mov edx, 4 xor r8d, r8d xor r9d, r9d call ggml_new_tensor_impl mov dword ptr [rax+50h], 25h ; '%' mov [rax+98h], r14 mov [rax+0A0h], rbx add rsp, 28h pop rbx pop r14 retn loc_1C36F: lea rdi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aANe2BNe1; "a->ne[2] == b->ne[1]" mov esi, 0CD2h jmp short loc_1C3C1 loc_1C38B: lea rdi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aBNe31; "b->ne[3] == 1" mov esi, 0CD3h jmp short loc_1C3C1 loc_1C3A7: lea rdi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aGgmlIsMatrixAG+2Ah; "b->type == GGML_TYPE_I32" mov esi, 0CD4h loc_1C3C1: xor eax, eax call _ggml_abort
long long ggml_get_rows(long long a1, long long a2, long long a3, long long a4, int a5, int a6) { long long v6; // rax unsigned int v9; // esi long long v10; // r8 long long v11; // r9 long long result; // rax char *v13; // rcx int v14; // esi _QWORD v15[7]; // [rsp+0h] [rbp-38h] BYREF v6 = *(_QWORD *)(a3 + 24); if ( *(_QWORD *)(a2 + 32) != v6 ) { v13 = "a->ne[2] == b->ne[1]"; v14 = 3282; goto LABEL_10; } if ( *(_QWORD *)(a3 + 40) != 1LL ) { v13 = "b->ne[3] == 1"; v14 = 3283; goto LABEL_10; } if ( *(_DWORD *)a3 != 26 ) { v13 = "b->type == GGML_TYPE_I32"; v14 = 3284; LABEL_10: ggml_abort( (unsigned int)"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/ggml/src/ggml.c", v14, (unsigned int)"GGML_ASSERT(%s) failed", (_DWORD)v13, a5, a6); } v9 = *(_DWORD *)a2; if ( v9 != 26 ) v9 = 0; v10 = *(_QWORD *)(a3 + 16); v11 = *(_QWORD *)(a3 + 32); v15[0] = *(_QWORD *)(a2 + 16); v15[1] = v10; v15[2] = v6; v15[3] = v11; result = ggml_new_tensor_impl(a1, v9, 4, v15, 0LL, 0LL); *(_DWORD *)(result + 80) = 37; *(_QWORD *)(result + 152) = a2; *(_QWORD *)(result + 160) = a3; return result; }
ggml_get_rows: PUSH R14 PUSH RBX SUB RSP,0x28 MOV RAX,qword ptr [RDX + 0x18] CMP qword ptr [RSI + 0x20],RAX JNZ 0x0011c36f MOV RBX,RDX CMP qword ptr [RDX + 0x28],0x1 JNZ 0x0011c38b CMP dword ptr [RBX],0x1a JNZ 0x0011c3a7 MOV R14,RSI MOV ESI,dword ptr [RSI] XOR ECX,ECX CMP ESI,0x1a CMOVNZ ESI,ECX MOV RDX,qword ptr [R14 + 0x10] MOV R8,qword ptr [RBX + 0x10] MOV R9,qword ptr [RBX + 0x20] MOV RCX,RSP MOV qword ptr [RCX],RDX MOV qword ptr [RCX + 0x8],R8 MOV qword ptr [RCX + 0x10],RAX MOV qword ptr [RCX + 0x18],R9 MOV EDX,0x4 XOR R8D,R8D XOR R9D,R9D CALL 0x00119c80 MOV dword ptr [RAX + 0x50],0x25 MOV qword ptr [RAX + 0x98],R14 MOV qword ptr [RAX + 0xa0],RBX ADD RSP,0x28 POP RBX POP R14 RET LAB_0011c36f: LEA RDI,[0x14a60f] LEA RDX,[0x14a659] LEA RCX,[0x14ab47] MOV ESI,0xcd2 JMP 0x0011c3c1 LAB_0011c38b: LEA RDI,[0x14a60f] LEA RDX,[0x14a659] LEA RCX,[0x14a8ac] MOV ESI,0xcd3 JMP 0x0011c3c1 LAB_0011c3a7: LEA RDI,[0x14a60f] LEA RDX,[0x14a659] LEA RCX,[0x14ab86] MOV ESI,0xcd4 LAB_0011c3c1: XOR EAX,EAX CALL 0x00117c70
void ggml_get_rows(int8 param_1,int *param_2,int *param_3) { int iVar1; long lVar2; char *pcVar3; int8 uVar4; int8 local_38; int8 local_30; long local_28; int8 local_20; local_28 = *(long *)(param_3 + 6); if (*(long *)(param_2 + 8) == local_28) { if (*(long *)(param_3 + 10) == 1) { if (*param_3 == 0x1a) { iVar1 = *param_2; if (*param_2 != 0x1a) { iVar1 = 0; } local_38 = *(int8 *)(param_2 + 4); local_30 = *(int8 *)(param_3 + 4); local_20 = *(int8 *)(param_3 + 8); lVar2 = ggml_new_tensor_impl(param_1,iVar1,4,&local_38,0,0); *(int4 *)(lVar2 + 0x50) = 0x25; *(int **)(lVar2 + 0x98) = param_2; *(int **)(lVar2 + 0xa0) = param_3; return; } pcVar3 = "b->type == GGML_TYPE_I32"; uVar4 = 0xcd4; } else { pcVar3 = "b->ne[3] == 1"; uVar4 = 0xcd3; } } else { pcVar3 = "a->ne[2] == b->ne[1]"; uVar4 = 0xcd2; } /* WARNING: Subroutine does not return */ ggml_abort("/workspace/llm4binary/github/2025_star3/monkey531[P]llama/ggml/src/ggml.c",uVar4, "GGML_ASSERT(%s) failed",pcVar3); }
6,007
ggml_get_rows
monkey531[P]llama/ggml/src/ggml.c
struct ggml_tensor * ggml_get_rows( struct ggml_context * ctx, struct ggml_tensor * a, struct ggml_tensor * b) { GGML_ASSERT(a->ne[2] == b->ne[1]); GGML_ASSERT(b->ne[3] == 1); GGML_ASSERT(b->type == GGML_TYPE_I32); // TODO: implement non F32 return enum ggml_type type = GGML_TYPE_F32; if (a->type == GGML_TYPE_I32) { type = a->type; } struct ggml_tensor * result = ggml_new_tensor_4d(ctx, type, a->ne[0], b->ne[0], b->ne[1], b->ne[2]); result->op = GGML_OP_GET_ROWS; result->src[0] = a; result->src[1] = b; return result; }
O2
c
ggml_get_rows: pushq %r14 pushq %rbx pushq %rax movq 0x20(%rsi), %r8 cmpq 0x18(%rdx), %r8 jne 0x221cc movq %rdx, %rbx cmpq $0x1, 0x28(%rdx) jne 0x221e8 cmpl $0x1a, (%rbx) jne 0x22204 movq %rsi, %r14 movl (%rsi), %eax xorl %esi, %esi cmpl $0x1a, %eax cmovel %eax, %esi movq 0x10(%r14), %rdx movq 0x10(%rbx), %rcx movq 0x20(%rbx), %r9 callq 0x1eda0 movl $0x25, 0x50(%rax) movq %r14, 0x98(%rax) movq %rbx, 0xa0(%rax) addq $0x8, %rsp popq %rbx popq %r14 retq leaq 0x293b0(%rip), %rdi # 0x4b583 leaq 0x293f3(%rip), %rdx # 0x4b5cd leaq 0x298da(%rip), %rcx # 0x4babb movl $0xcd2, %esi # imm = 0xCD2 jmp 0x2221e leaq 0x29394(%rip), %rdi # 0x4b583 leaq 0x293d7(%rip), %rdx # 0x4b5cd leaq 0x29623(%rip), %rcx # 0x4b820 movl $0xcd3, %esi # imm = 0xCD3 jmp 0x2221e leaq 0x29378(%rip), %rdi # 0x4b583 leaq 0x293bb(%rip), %rdx # 0x4b5cd leaq 0x298e1(%rip), %rcx # 0x4bafa movl $0xcd4, %esi # imm = 0xCD4 xorl %eax, %eax callq 0x1e760
ggml_get_rows: push r14 push rbx push rax mov r8, [rsi+20h] cmp r8, [rdx+18h] jnz short loc_221CC mov rbx, rdx cmp qword ptr [rdx+28h], 1 jnz short loc_221E8 cmp dword ptr [rbx], 1Ah jnz short loc_22204 mov r14, rsi mov eax, [rsi] xor esi, esi cmp eax, 1Ah cmovz esi, eax mov rdx, [r14+10h] mov rcx, [rbx+10h] mov r9, [rbx+20h] call _ggml_new_tensor_4d mov dword ptr [rax+50h], 25h ; '%' mov [rax+98h], r14 mov [rax+0A0h], rbx add rsp, 8 pop rbx pop r14 retn loc_221CC: lea rdi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aANe2BNe1; "a->ne[2] == b->ne[1]" mov esi, 0CD2h jmp short loc_2221E loc_221E8: lea rdi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aBNe31; "b->ne[3] == 1" mov esi, 0CD3h jmp short loc_2221E loc_22204: lea rdi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aGgmlIsMatrixAG+2Ah; "b->type == GGML_TYPE_I32" mov esi, 0CD4h loc_2221E: xor eax, eax call _ggml_abort
long long ggml_get_rows( long long a1, int *a2, long long a3, __m128 a4, __m128 a5, __m128 a6, __m128 a7, __m128 a8, __m128 a9, __m128 a10, __m128 a11, long long a12, long long a13, long long a14) { char v14; // al long long v15; // r8 int v18; // eax long long v19; // rsi long long result; // rax char *v21; // rcx int v22; // esi v15 = *((_QWORD *)a2 + 4); if ( v15 != *(_QWORD *)(a3 + 24) ) { v21 = "a->ne[2] == b->ne[1]"; v22 = 3282; goto LABEL_10; } if ( *(_QWORD *)(a3 + 40) != 1LL ) { v21 = "b->ne[3] == 1"; v22 = 3283; goto LABEL_10; } if ( *(_DWORD *)a3 != 26 ) { v21 = "b->type == GGML_TYPE_I32"; v22 = 3284; LABEL_10: ggml_abort( "/workspace/llm4binary/github/2025_star3/monkey531[P]llama/ggml/src/ggml.c", v22, (long long)"GGML_ASSERT(%s) failed", (long long)v21, v15, a14, a4, a5, a6, a7, a8, a9, a10, a11, v14); } v18 = *a2; v19 = 0LL; if ( v18 == 26 ) v19 = 26LL; result = ggml_new_tensor_4d(a1, v19, *((_QWORD *)a2 + 2), *(_QWORD *)(a3 + 16), v15, *(_QWORD *)(a3 + 32)); *(_DWORD *)(result + 80) = 37; *(_QWORD *)(result + 152) = a2; *(_QWORD *)(result + 160) = a3; return result; }
ggml_get_rows: PUSH R14 PUSH RBX PUSH RAX MOV R8,qword ptr [RSI + 0x20] CMP R8,qword ptr [RDX + 0x18] JNZ 0x001221cc MOV RBX,RDX CMP qword ptr [RDX + 0x28],0x1 JNZ 0x001221e8 CMP dword ptr [RBX],0x1a JNZ 0x00122204 MOV R14,RSI MOV EAX,dword ptr [RSI] XOR ESI,ESI CMP EAX,0x1a CMOVZ ESI,EAX MOV RDX,qword ptr [R14 + 0x10] MOV RCX,qword ptr [RBX + 0x10] MOV R9,qword ptr [RBX + 0x20] CALL 0x0011eda0 MOV dword ptr [RAX + 0x50],0x25 MOV qword ptr [RAX + 0x98],R14 MOV qword ptr [RAX + 0xa0],RBX ADD RSP,0x8 POP RBX POP R14 RET LAB_001221cc: LEA RDI,[0x14b583] LEA RDX,[0x14b5cd] LEA RCX,[0x14babb] MOV ESI,0xcd2 JMP 0x0012221e LAB_001221e8: LEA RDI,[0x14b583] LEA RDX,[0x14b5cd] LEA RCX,[0x14b820] MOV ESI,0xcd3 JMP 0x0012221e LAB_00122204: LEA RDI,[0x14b583] LEA RDX,[0x14b5cd] LEA RCX,[0x14bafa] MOV ESI,0xcd4 LAB_0012221e: XOR EAX,EAX CALL 0x0011e760
void ggml_get_rows(int8 param_1,int *param_2,int *param_3) { long lVar1; char *pcVar2; int8 uVar3; if (*(long *)(param_2 + 8) == *(long *)(param_3 + 6)) { if (*(long *)(param_3 + 10) == 1) { if (*param_3 == 0x1a) { uVar3 = 0; if (*param_2 == 0x1a) { uVar3 = 0x1a; } lVar1 = ggml_new_tensor_4d(param_1,uVar3,*(int8 *)(param_2 + 4), *(int8 *)(param_3 + 4),*(long *)(param_2 + 8), *(int8 *)(param_3 + 8)); *(int4 *)(lVar1 + 0x50) = 0x25; *(int **)(lVar1 + 0x98) = param_2; *(int **)(lVar1 + 0xa0) = param_3; return; } pcVar2 = "b->type == GGML_TYPE_I32"; uVar3 = 0xcd4; } else { pcVar2 = "b->ne[3] == 1"; uVar3 = 0xcd3; } } else { pcVar2 = "a->ne[2] == b->ne[1]"; uVar3 = 0xcd2; } /* WARNING: Subroutine does not return */ ggml_abort("/workspace/llm4binary/github/2025_star3/monkey531[P]llama/ggml/src/ggml.c",uVar3, "GGML_ASSERT(%s) failed",pcVar2); }
6,008
do_all_tests()
eloqsql/storage/perfschema/unittest/pfs_instr_class-t.cc
void do_all_tests() { test_no_registration(); test_mutex_registration(); test_rwlock_registration(); test_cond_registration(); test_thread_registration(); test_file_registration(); test_socket_registration(); test_table_registration(); test_memory_registration(); test_instruments_reset(); }
O0
cpp
do_all_tests(): pushq %rbp movq %rsp, %rbp callq 0x29c60 callq 0x2a4a0 callq 0x2a830 callq 0x2ab20 callq 0x2ae10 callq 0x2b100 callq 0x2b3f0 callq 0x2b780 callq 0x2b790 callq 0x2bb20 popq %rbp retq nopl (%rax,%rax)
_Z12do_all_testsv: push rbp mov rbp, rsp call _Z20test_no_registrationv; test_no_registration(void) call _Z23test_mutex_registrationv; test_mutex_registration(void) call _Z24test_rwlock_registrationv; test_rwlock_registration(void) call _Z22test_cond_registrationv; test_cond_registration(void) call _Z24test_thread_registrationv; test_thread_registration(void) call _Z22test_file_registrationv; test_file_registration(void) call _Z24test_socket_registrationv; test_socket_registration(void) call _Z23test_table_registrationv; test_table_registration(void) call _Z24test_memory_registrationv; test_memory_registration(void) call _Z22test_instruments_resetv; test_instruments_reset(void) pop rbp retn
long long do_all_tests(void) { test_no_registration(); test_mutex_registration(); test_rwlock_registration(); test_cond_registration(); test_thread_registration(); test_file_registration(); test_socket_registration(); test_table_registration(); test_memory_registration(); return test_instruments_reset(); }
do_all_tests: PUSH RBP MOV RBP,RSP CALL 0x00129c60 CALL 0x0012a4a0 CALL 0x0012a830 CALL 0x0012ab20 CALL 0x0012ae10 CALL 0x0012b100 CALL 0x0012b3f0 CALL 0x0012b780 CALL 0x0012b790 CALL 0x0012bb20 POP RBP RET
/* WARNING: Unknown calling convention -- yet parameter storage is locked */ /* do_all_tests() */ void do_all_tests(void) { test_no_registration(); test_mutex_registration(); test_rwlock_registration(); test_cond_registration(); test_thread_registration(); test_file_registration(); test_socket_registration(); test_table_registration(); test_memory_registration(); test_instruments_reset(); return; }
6,009
do_all_tests()
eloqsql/storage/perfschema/unittest/pfs_instr_class-t.cc
void do_all_tests() { test_no_registration(); test_mutex_registration(); test_rwlock_registration(); test_cond_registration(); test_thread_registration(); test_file_registration(); test_socket_registration(); test_table_registration(); test_memory_registration(); test_instruments_reset(); }
O3
cpp
do_all_tests(): pushq %rbp movq %rsp, %rbp callq 0x2cd92 callq 0x2d40a callq 0x2d716 callq 0x2d98f callq 0x2dc14 callq 0x2de89 callq 0x2e0fe callq 0x2e400 popq %rbp jmp 0x2e6fc
_Z12do_all_testsv: push rbp mov rbp, rsp call _Z20test_no_registrationv; test_no_registration(void) call _Z23test_mutex_registrationv; test_mutex_registration(void) call _Z24test_rwlock_registrationv; test_rwlock_registration(void) call _Z22test_cond_registrationv; test_cond_registration(void) call _Z24test_thread_registrationv; test_thread_registration(void) call _Z22test_file_registrationv; test_file_registration(void) call _Z24test_socket_registrationv; test_socket_registration(void) call _Z24test_memory_registrationv; test_memory_registration(void) pop rbp jmp _Z22test_instruments_resetv; test_instruments_reset(void)
long long do_all_tests(void) { test_no_registration(); test_mutex_registration(); test_rwlock_registration(); test_cond_registration(); test_thread_registration(); test_file_registration(); test_socket_registration(); test_memory_registration(); return test_instruments_reset(); }
do_all_tests: PUSH RBP MOV RBP,RSP CALL 0x0012cd92 CALL 0x0012d40a CALL 0x0012d716 CALL 0x0012d98f CALL 0x0012dc14 CALL 0x0012de89 CALL 0x0012e0fe CALL 0x0012e400 POP RBP JMP 0x0012e6fc
/* WARNING: Unknown calling convention -- yet parameter storage is locked */ /* do_all_tests() */ void do_all_tests(void) { test_no_registration(); test_mutex_registration(); test_rwlock_registration(); test_cond_registration(); test_thread_registration(); test_file_registration(); test_socket_registration(); test_memory_registration(); test_instruments_reset(); return; }
6,010
inline_mysql_file_seek
eloqsql/include/mysql/psi/mysql_file.h
static inline my_off_t inline_mysql_file_seek( #ifdef HAVE_PSI_FILE_INTERFACE const char *src_file, uint src_line, #endif File file, my_off_t pos, int whence, myf flags) { my_off_t result; #ifdef HAVE_PSI_FILE_INTERFACE struct PSI_file_locker *locker; PSI_file_locker_state state; locker= PSI_FILE_CALL(get_thread_file_descriptor_locker)(&state, file, PSI_FILE_SEEK); if (psi_likely(locker != NULL)) { PSI_FILE_CALL(start_file_wait)(locker, (size_t) 0, src_file, src_line); result= my_seek(file, pos, whence, flags); PSI_FILE_CALL(end_file_wait)(locker, (size_t) 0); return result; } #endif result= my_seek(file, pos, whence, flags); return result; }
O3
c
inline_mysql_file_seek: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %rbx subq $0x58, %rsp movl %esi, %ebx movl %edi, %r14d leaq 0x3289f7(%rip), %rax # 0x393a58 movq (%rax), %rax leaq -0x68(%rbp), %rdi movl $0x8, %edx callq *0x158(%rax) testq %rax, %rax jne 0x6b093 movl %ebx, %edi xorl %esi, %esi movl $0x2, %edx xorl %ecx, %ecx callq 0xab33c addq $0x58, %rsp popq %rbx popq %r14 popq %r15 popq %rbp retq leaq -0x20(%rbp), %r15 movq %rax, %rdi movl %r14d, %esi movl %ebx, %edx movq %r15, %rcx callq 0x2db2e movq (%r15), %rax jmp 0x6b088
inline_mysql_file_seek: push rbp mov rbp, rsp push r15 push r14 push rbx sub rsp, 58h mov ebx, esi mov r14d, edi lea rax, PSI_server mov rax, [rax] lea rdi, [rbp+var_68] mov edx, 8 call qword ptr [rax+158h] test rax, rax jnz short loc_6B093 mov edi, ebx xor esi, esi mov edx, 2 xor ecx, ecx call my_seek loc_6B088: add rsp, 58h pop rbx pop r14 pop r15 pop rbp retn loc_6B093: lea r15, [rbp+var_20] mov rdi, rax mov esi, r14d mov edx, ebx mov rcx, r15 call inline_mysql_file_seek_cold_1 mov rax, [r15] jmp short loc_6B088
long long inline_mysql_file_seek(unsigned int a1, long long a2) { long long v2; // rax _BYTE v4[72]; // [rsp+8h] [rbp-68h] BYREF _QWORD v5[4]; // [rsp+50h] [rbp-20h] BYREF v2 = ((long long ( *)(_BYTE *, long long, long long))PSI_server[43])(v4, a2, 8LL); if ( !v2 ) return my_seek((unsigned int)a2, 0LL, 2LL, 0LL); inline_mysql_file_seek_cold_1(v2, a1, a2, v5); return v5[0]; }
inline_mysql_file_seek: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH RBX SUB RSP,0x58 MOV EBX,ESI MOV R14D,EDI LEA RAX,[0x493a58] MOV RAX,qword ptr [RAX] LEA RDI,[RBP + -0x68] MOV EDX,0x8 CALL qword ptr [RAX + 0x158] TEST RAX,RAX JNZ 0x0016b093 MOV EDI,EBX XOR ESI,ESI MOV EDX,0x2 XOR ECX,ECX CALL 0x001ab33c LAB_0016b088: ADD RSP,0x58 POP RBX POP R14 POP R15 POP RBP RET LAB_0016b093: LEA R15,[RBP + -0x20] MOV RDI,RAX MOV ESI,R14D MOV EDX,EBX MOV RCX,R15 CALL 0x0012db2e MOV RAX,qword ptr [R15] JMP 0x0016b088
int8 inline_mysql_file_seek(int4 param_1,ulong param_2) { long lVar1; int1 local_70 [72]; int8 local_28; lVar1 = (**(code **)(PSI_server + 0x158))(local_70,param_2,8); if (lVar1 == 0) { local_28 = my_seek(param_2 & 0xffffffff,0,2,0); } else { inline_mysql_file_seek_cold_1(lVar1,param_1,param_2 & 0xffffffff,&local_28); } return local_28; }
6,011
check_longlong
eloqsql/strings/my_vsnprintf.c
static const char *check_longlong(const char *fmt, uint *have_longlong) { *have_longlong= 0; if (*fmt == 'l') { fmt++; if (*fmt != 'l') *have_longlong= (sizeof(long) == sizeof(longlong)); else { fmt++; *have_longlong= 1; } } else if (*fmt == 'z') { fmt++; *have_longlong= (sizeof(size_t) == sizeof(longlong)); } else if (*fmt == 'p') *have_longlong= (sizeof(void *) == sizeof(longlong)); return fmt; }
O0
c
check_longlong: pushq %rbp movq %rsp, %rbp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq -0x10(%rbp), %rax movl $0x0, (%rax) movq -0x8(%rbp), %rax movsbl (%rax), %eax cmpl $0x6c, %eax jne 0xacd3e movq -0x8(%rbp), %rax addq $0x1, %rax movq %rax, -0x8(%rbp) movq -0x8(%rbp), %rax movsbl (%rax), %eax cmpl $0x6c, %eax je 0xacd26 movq -0x10(%rbp), %rax movl $0x1, (%rax) jmp 0xacd3c movq -0x8(%rbp), %rax addq $0x1, %rax movq %rax, -0x8(%rbp) movq -0x10(%rbp), %rax movl $0x1, (%rax) jmp 0xacd7c movq -0x8(%rbp), %rax movsbl (%rax), %eax cmpl $0x7a, %eax jne 0xacd62 movq -0x8(%rbp), %rax addq $0x1, %rax movq %rax, -0x8(%rbp) movq -0x10(%rbp), %rax movl $0x1, (%rax) jmp 0xacd7a movq -0x8(%rbp), %rax movsbl (%rax), %eax cmpl $0x70, %eax jne 0xacd78 movq -0x10(%rbp), %rax movl $0x1, (%rax) jmp 0xacd7a jmp 0xacd7c movq -0x8(%rbp), %rax popq %rbp retq nopw %cs:(%rax,%rax)
check_longlong: push rbp mov rbp, rsp mov [rbp+var_8], rdi mov [rbp+var_10], rsi mov rax, [rbp+var_10] mov dword ptr [rax], 0 mov rax, [rbp+var_8] movsx eax, byte ptr [rax] cmp eax, 6Ch ; 'l' jnz short loc_ACD3E mov rax, [rbp+var_8] add rax, 1 mov [rbp+var_8], rax mov rax, [rbp+var_8] movsx eax, byte ptr [rax] cmp eax, 6Ch ; 'l' jz short loc_ACD26 mov rax, [rbp+var_10] mov dword ptr [rax], 1 jmp short loc_ACD3C loc_ACD26: mov rax, [rbp+var_8] add rax, 1 mov [rbp+var_8], rax mov rax, [rbp+var_10] mov dword ptr [rax], 1 loc_ACD3C: jmp short loc_ACD7C loc_ACD3E: mov rax, [rbp+var_8] movsx eax, byte ptr [rax] cmp eax, 7Ah ; 'z' jnz short loc_ACD62 mov rax, [rbp+var_8] add rax, 1 mov [rbp+var_8], rax mov rax, [rbp+var_10] mov dword ptr [rax], 1 jmp short loc_ACD7A loc_ACD62: mov rax, [rbp+var_8] movsx eax, byte ptr [rax] cmp eax, 70h ; 'p' jnz short loc_ACD78 mov rax, [rbp+var_10] mov dword ptr [rax], 1 loc_ACD78: jmp short $+2 loc_ACD7A: jmp short $+2 loc_ACD7C: mov rax, [rbp+var_8] pop rbp retn
_BYTE * check_longlong(_BYTE *a1, _DWORD *a2) { _BYTE *v3; // [rsp+8h] [rbp-8h] v3 = a1; *a2 = 0; switch ( *a1 ) { case 'l': v3 = a1 + 1; if ( a1[1] == 108 ) v3 = a1 + 2; *a2 = 1; break; case 'z': v3 = a1 + 1; *a2 = 1; break; case 'p': *a2 = 1; break; } return v3; }
check_longlong: PUSH RBP MOV RBP,RSP MOV qword ptr [RBP + -0x8],RDI MOV qword ptr [RBP + -0x10],RSI MOV RAX,qword ptr [RBP + -0x10] MOV dword ptr [RAX],0x0 MOV RAX,qword ptr [RBP + -0x8] MOVSX EAX,byte ptr [RAX] CMP EAX,0x6c JNZ 0x001acd3e MOV RAX,qword ptr [RBP + -0x8] ADD RAX,0x1 MOV qword ptr [RBP + -0x8],RAX MOV RAX,qword ptr [RBP + -0x8] MOVSX EAX,byte ptr [RAX] CMP EAX,0x6c JZ 0x001acd26 MOV RAX,qword ptr [RBP + -0x10] MOV dword ptr [RAX],0x1 JMP 0x001acd3c LAB_001acd26: MOV RAX,qword ptr [RBP + -0x8] ADD RAX,0x1 MOV qword ptr [RBP + -0x8],RAX MOV RAX,qword ptr [RBP + -0x10] MOV dword ptr [RAX],0x1 LAB_001acd3c: JMP 0x001acd7c LAB_001acd3e: MOV RAX,qword ptr [RBP + -0x8] MOVSX EAX,byte ptr [RAX] CMP EAX,0x7a JNZ 0x001acd62 MOV RAX,qword ptr [RBP + -0x8] ADD RAX,0x1 MOV qword ptr [RBP + -0x8],RAX MOV RAX,qword ptr [RBP + -0x10] MOV dword ptr [RAX],0x1 JMP 0x001acd7a LAB_001acd62: MOV RAX,qword ptr [RBP + -0x8] MOVSX EAX,byte ptr [RAX] CMP EAX,0x70 JNZ 0x001acd78 MOV RAX,qword ptr [RBP + -0x10] MOV dword ptr [RAX],0x1 LAB_001acd78: JMP 0x001acd7a LAB_001acd7a: JMP 0x001acd7c LAB_001acd7c: MOV RAX,qword ptr [RBP + -0x8] POP RBP RET
char * check_longlong(char *param_1,int4 *param_2) { char *local_10; *param_2 = 0; if (*param_1 == 'l') { local_10 = param_1 + 1; if (*local_10 == 'l') { local_10 = param_1 + 2; *param_2 = 1; } else { *param_2 = 1; } } else if (*param_1 == 'z') { local_10 = param_1 + 1; *param_2 = 1; } else { local_10 = param_1; if (*param_1 == 'p') { *param_2 = 1; } } return local_10; }
6,012
neg_fp6
corpus-core[P]colibri-stateless/build_O3/_deps/blst-src/src/fp12_tower.c
static void neg_fp6(vec384fp6 ret, const vec384fp6 a) { neg_fp2(ret[0], a[0]); neg_fp2(ret[1], a[1]); neg_fp2(ret[2], a[2]); }
O3
c
neg_fp6: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %rbx pushq %rax movq %rsi, %rbx movq %rdi, %r15 leaq 0x18118(%rip), %r14 # 0x3fb10 movl $0x1, %edx movq %r14, %rcx callq 0x2f2c0 leaq 0x30(%r15), %rdi leaq 0x30(%rbx), %rsi movl $0x1, %edx movq %r14, %rcx callq 0x2f2c0 leaq 0x60(%r15), %rdi leaq 0x60(%rbx), %rsi movl $0x1, %edx movq %r14, %rcx callq 0x2f2c0 movl $0x90, %esi leaq (%r15,%rsi), %rdi addq %rbx, %rsi movl $0x1, %edx movq %r14, %rcx callq 0x2f2c0 movl $0xc0, %esi leaq (%r15,%rsi), %rdi addq %rbx, %rsi movl $0x1, %edx movq %r14, %rcx callq 0x2f2c0 movl $0xf0, %eax addq %rax, %r15 addq %rax, %rbx movl $0x1, %edx movq %r15, %rdi movq %rbx, %rsi movq %r14, %rcx addq $0x8, %rsp popq %rbx popq %r14 popq %r15 popq %rbp jmp 0x2f2c0
neg_fp6: push rbp mov rbp, rsp push r15 push r14 push rbx push rax mov rbx, rsi mov r15, rdi lea r14, BLS12_381_P mov edx, 1 mov rcx, r14 call cneg_mod_384 lea rdi, [r15+30h] lea rsi, [rbx+30h] mov edx, 1 mov rcx, r14 call cneg_mod_384 lea rdi, [r15+60h] lea rsi, [rbx+60h] mov edx, 1 mov rcx, r14 call cneg_mod_384 mov esi, 90h lea rdi, [r15+rsi] add rsi, rbx mov edx, 1 mov rcx, r14 call cneg_mod_384 mov esi, 0C0h lea rdi, [r15+rsi] add rsi, rbx mov edx, 1 mov rcx, r14 call cneg_mod_384 mov eax, 0F0h add r15, rax add rbx, rax mov edx, 1 mov rdi, r15 mov rsi, rbx mov rcx, r14 add rsp, 8 pop rbx pop r14 pop r15 pop rbp jmp cneg_mod_384
long long neg_fp6(long long a1, long long a2) { cneg_mod_384(a1, a2, 1LL, &BLS12_381_P); cneg_mod_384(a1 + 48, a2 + 48, 1LL, &BLS12_381_P); cneg_mod_384(a1 + 96, a2 + 96, 1LL, &BLS12_381_P); cneg_mod_384(a1 + 144, a2 + 144, 1LL, &BLS12_381_P); cneg_mod_384(a1 + 192, a2 + 192, 1LL, &BLS12_381_P); return cneg_mod_384(a1 + 240, a2 + 240, 1LL, &BLS12_381_P); }
neg_fp6: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH RBX PUSH RAX MOV RBX,RSI MOV R15,RDI LEA R14,[0x13fb10] MOV EDX,0x1 MOV RCX,R14 CALL 0x0012f2c0 LEA RDI,[R15 + 0x30] LEA RSI,[RBX + 0x30] MOV EDX,0x1 MOV RCX,R14 CALL 0x0012f2c0 LEA RDI,[R15 + 0x60] LEA RSI,[RBX + 0x60] MOV EDX,0x1 MOV RCX,R14 CALL 0x0012f2c0 MOV ESI,0x90 LEA RDI,[R15 + RSI*0x1] ADD RSI,RBX MOV EDX,0x1 MOV RCX,R14 CALL 0x0012f2c0 MOV ESI,0xc0 LEA RDI,[R15 + RSI*0x1] ADD RSI,RBX MOV EDX,0x1 MOV RCX,R14 CALL 0x0012f2c0 MOV EAX,0xf0 ADD R15,RAX ADD RBX,RAX MOV EDX,0x1 MOV RDI,R15 MOV RSI,RBX MOV RCX,R14 ADD RSP,0x8 POP RBX POP R14 POP R15 POP RBP JMP 0x0012f2c0
void neg_fp6(long param_1,long param_2) { cneg_mod_384(param_1,param_2,1,BLS12_381_P); cneg_mod_384(param_1 + 0x30,param_2 + 0x30,1,BLS12_381_P); cneg_mod_384(param_1 + 0x60,param_2 + 0x60,1,BLS12_381_P); cneg_mod_384(param_1 + 0x90,param_2 + 0x90,1,BLS12_381_P); cneg_mod_384(param_1 + 0xc0,param_2 + 0xc0,1,BLS12_381_P); cneg_mod_384(param_1 + 0xf0,param_2 + 0xf0,1,BLS12_381_P); return; }
6,013
skip_trailing_space
eloqsql/strings/strings_def.h
static inline const uchar *skip_trailing_space(const uchar *ptr,size_t len) { const uchar *end= ptr + len; if (len > 20) { const uchar *end_words= (const uchar *)(intptr) (((ulonglong)(intptr)end) / SIZEOF_INT * SIZEOF_INT); const uchar *start_words= (const uchar *)(intptr) ((((ulonglong)(intptr)ptr) + SIZEOF_INT - 1) / SIZEOF_INT * SIZEOF_INT); DBUG_ASSERT(((ulonglong)(intptr)ptr) >= SIZEOF_INT); if (end_words > ptr) { while (end > end_words && end[-1] == 0x20) end--; if (end[-1] == 0x20 && start_words < end_words) while (end > start_words && ((unsigned *)end)[-1] == SPACE_INT) end -= SIZEOF_INT; } } while (end > ptr && end[-1] == 0x20) end--; return (end); }
O0
c
skip_trailing_space: pushq %rbp movq %rsp, %rbp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq -0x8(%rbp), %rax addq -0x10(%rbp), %rax movq %rax, -0x18(%rbp) cmpq $0x14, -0x10(%rbp) jbe 0x4571a movq -0x18(%rbp), %rax shrq $0x2, %rax shlq $0x2, %rax movq %rax, -0x20(%rbp) movq -0x8(%rbp), %rax addq $0x4, %rax subq $0x1, %rax shrq $0x2, %rax shlq $0x2, %rax movq %rax, -0x28(%rbp) jmp 0x4567d movq -0x20(%rbp), %rax cmpq -0x8(%rbp), %rax jbe 0x45718 jmp 0x4568d movq -0x18(%rbp), %rcx xorl %eax, %eax cmpq -0x20(%rbp), %rcx movb %al, -0x29(%rbp) jbe 0x456ad movq -0x18(%rbp), %rax movzbl -0x1(%rax), %eax cmpl $0x20, %eax sete %al movb %al, -0x29(%rbp) movb -0x29(%rbp), %al testb $0x1, %al jne 0x456b6 jmp 0x456c4 movq -0x18(%rbp), %rax addq $-0x1, %rax movq %rax, -0x18(%rbp) jmp 0x4568d movq -0x18(%rbp), %rax movzbl -0x1(%rax), %eax cmpl $0x20, %eax jne 0x45716 movq -0x28(%rbp), %rax cmpq -0x20(%rbp), %rax jae 0x45716 jmp 0x456dd movq -0x18(%rbp), %rcx xorl %eax, %eax cmpq -0x28(%rbp), %rcx movb %al, -0x2a(%rbp) jbe 0x456fd movq -0x18(%rbp), %rax cmpl $0x20202020, -0x4(%rax) # imm = 0x20202020 sete %al movb %al, -0x2a(%rbp) movb -0x2a(%rbp), %al testb $0x1, %al jne 0x45706 jmp 0x45714 movq -0x18(%rbp), %rax addq $-0x4, %rax movq %rax, -0x18(%rbp) jmp 0x456dd jmp 0x45716 jmp 0x45718 jmp 0x4571a jmp 0x4571c movq -0x18(%rbp), %rcx xorl %eax, %eax cmpq -0x8(%rbp), %rcx movb %al, -0x2b(%rbp) jbe 0x4573c movq -0x18(%rbp), %rax movzbl -0x1(%rax), %eax cmpl $0x20, %eax sete %al movb %al, -0x2b(%rbp) movb -0x2b(%rbp), %al testb $0x1, %al jne 0x45745 jmp 0x45753 movq -0x18(%rbp), %rax addq $-0x1, %rax movq %rax, -0x18(%rbp) jmp 0x4571c movq -0x18(%rbp), %rax popq %rbp retq nopl (%rax)
skip_trailing_space_0: push rbp mov rbp, rsp mov [rbp+var_8], rdi mov [rbp+var_10], rsi mov rax, [rbp+var_8] add rax, [rbp+var_10] mov [rbp+var_18], rax cmp [rbp+var_10], 14h jbe loc_4571A mov rax, [rbp+var_18] shr rax, 2 shl rax, 2 mov [rbp+var_20], rax mov rax, [rbp+var_8] add rax, 4 sub rax, 1 shr rax, 2 shl rax, 2 mov [rbp+var_28], rax jmp short $+2 loc_4567D: mov rax, [rbp+var_20] cmp rax, [rbp+var_8] jbe loc_45718 jmp short $+2 loc_4568D: mov rcx, [rbp+var_18] xor eax, eax cmp rcx, [rbp+var_20] mov [rbp+var_29], al jbe short loc_456AD mov rax, [rbp+var_18] movzx eax, byte ptr [rax-1] cmp eax, 20h ; ' ' setz al mov [rbp+var_29], al loc_456AD: mov al, [rbp+var_29] test al, 1 jnz short loc_456B6 jmp short loc_456C4 loc_456B6: mov rax, [rbp+var_18] add rax, 0FFFFFFFFFFFFFFFFh mov [rbp+var_18], rax jmp short loc_4568D loc_456C4: mov rax, [rbp+var_18] movzx eax, byte ptr [rax-1] cmp eax, 20h ; ' ' jnz short loc_45716 mov rax, [rbp+var_28] cmp rax, [rbp+var_20] jnb short loc_45716 jmp short $+2 loc_456DD: mov rcx, [rbp+var_18] xor eax, eax cmp rcx, [rbp+var_28] mov [rbp+var_2A], al jbe short loc_456FD mov rax, [rbp+var_18] cmp dword ptr [rax-4], 20202020h setz al mov [rbp+var_2A], al loc_456FD: mov al, [rbp+var_2A] test al, 1 jnz short loc_45706 jmp short loc_45714 loc_45706: mov rax, [rbp+var_18] add rax, 0FFFFFFFFFFFFFFFCh mov [rbp+var_18], rax jmp short loc_456DD loc_45714: jmp short $+2 loc_45716: jmp short $+2 loc_45718: jmp short $+2 loc_4571A: jmp short $+2 loc_4571C: mov rcx, [rbp+var_18] xor eax, eax cmp rcx, [rbp+var_8] mov [rbp+var_2B], al jbe short loc_4573C mov rax, [rbp+var_18] movzx eax, byte ptr [rax-1] cmp eax, 20h ; ' ' setz al mov [rbp+var_2B], al loc_4573C: mov al, [rbp+var_2B] test al, 1 jnz short loc_45745 jmp short loc_45753 loc_45745: mov rax, [rbp+var_18] add rax, 0FFFFFFFFFFFFFFFFh mov [rbp+var_18], rax jmp short loc_4571C loc_45753: mov rax, [rbp+var_18] pop rbp retn
unsigned long long skip_trailing_space_0(unsigned long long a1, unsigned long long a2) { bool v3; // [rsp+1h] [rbp-2Bh] bool v4; // [rsp+2h] [rbp-2Ah] bool v5; // [rsp+3h] [rbp-29h] unsigned long long v6; // [rsp+4h] [rbp-28h] unsigned long long v7; // [rsp+Ch] [rbp-20h] unsigned long long v8; // [rsp+14h] [rbp-18h] v8 = a2 + a1; if ( a2 > 0x14 ) { v7 = 4 * (v8 >> 2); v6 = 4 * ((a1 + 3) >> 2); if ( v7 > a1 ) { while ( 1 ) { v5 = 0; if ( v8 > v7 ) v5 = *(_BYTE *)(v8 - 1) == 32; if ( !v5 ) break; --v8; } if ( *(_BYTE *)(v8 - 1) == 32 && v6 < v7 ) { while ( 1 ) { v4 = 0; if ( v8 > v6 ) v4 = *(_DWORD *)(v8 - 4) == 538976288; if ( !v4 ) break; v8 -= 4LL; } } } } while ( 1 ) { v3 = 0; if ( v8 > a1 ) v3 = *(_BYTE *)(v8 - 1) == 32; if ( !v3 ) break; --v8; } return v8; }
skip_trailing_space: PUSH RBP MOV RBP,RSP MOV qword ptr [RBP + -0x8],RDI MOV qword ptr [RBP + -0x10],RSI MOV RAX,qword ptr [RBP + -0x8] ADD RAX,qword ptr [RBP + -0x10] MOV qword ptr [RBP + -0x18],RAX CMP qword ptr [RBP + -0x10],0x14 JBE 0x0014571a MOV RAX,qword ptr [RBP + -0x18] SHR RAX,0x2 SHL RAX,0x2 MOV qword ptr [RBP + -0x20],RAX MOV RAX,qword ptr [RBP + -0x8] ADD RAX,0x4 SUB RAX,0x1 SHR RAX,0x2 SHL RAX,0x2 MOV qword ptr [RBP + -0x28],RAX JMP 0x0014567d LAB_0014567d: MOV RAX,qword ptr [RBP + -0x20] CMP RAX,qword ptr [RBP + -0x8] JBE 0x00145718 JMP 0x0014568d LAB_0014568d: MOV RCX,qword ptr [RBP + -0x18] XOR EAX,EAX CMP RCX,qword ptr [RBP + -0x20] MOV byte ptr [RBP + -0x29],AL JBE 0x001456ad MOV RAX,qword ptr [RBP + -0x18] MOVZX EAX,byte ptr [RAX + -0x1] CMP EAX,0x20 SETZ AL MOV byte ptr [RBP + -0x29],AL LAB_001456ad: MOV AL,byte ptr [RBP + -0x29] TEST AL,0x1 JNZ 0x001456b6 JMP 0x001456c4 LAB_001456b6: MOV RAX,qword ptr [RBP + -0x18] ADD RAX,-0x1 MOV qword ptr [RBP + -0x18],RAX JMP 0x0014568d LAB_001456c4: MOV RAX,qword ptr [RBP + -0x18] MOVZX EAX,byte ptr [RAX + -0x1] CMP EAX,0x20 JNZ 0x00145716 MOV RAX,qword ptr [RBP + -0x28] CMP RAX,qword ptr [RBP + -0x20] JNC 0x00145716 JMP 0x001456dd LAB_001456dd: MOV RCX,qword ptr [RBP + -0x18] XOR EAX,EAX CMP RCX,qword ptr [RBP + -0x28] MOV byte ptr [RBP + -0x2a],AL JBE 0x001456fd MOV RAX,qword ptr [RBP + -0x18] CMP dword ptr [RAX + -0x4],0x20202020 SETZ AL MOV byte ptr [RBP + -0x2a],AL LAB_001456fd: MOV AL,byte ptr [RBP + -0x2a] TEST AL,0x1 JNZ 0x00145706 JMP 0x00145714 LAB_00145706: MOV RAX,qword ptr [RBP + -0x18] ADD RAX,-0x4 MOV qword ptr [RBP + -0x18],RAX JMP 0x001456dd LAB_00145714: JMP 0x00145716 LAB_00145716: JMP 0x00145718 LAB_00145718: JMP 0x0014571a LAB_0014571a: JMP 0x0014571c LAB_0014571c: MOV RCX,qword ptr [RBP + -0x18] XOR EAX,EAX CMP RCX,qword ptr [RBP + -0x8] MOV byte ptr [RBP + -0x2b],AL JBE 0x0014573c MOV RAX,qword ptr [RBP + -0x18] MOVZX EAX,byte ptr [RAX + -0x1] CMP EAX,0x20 SETZ AL MOV byte ptr [RBP + -0x2b],AL LAB_0014573c: MOV AL,byte ptr [RBP + -0x2b] TEST AL,0x1 JNZ 0x00145745 JMP 0x00145753 LAB_00145745: MOV RAX,qword ptr [RBP + -0x18] ADD RAX,-0x1 MOV qword ptr [RBP + -0x18],RAX JMP 0x0014571c LAB_00145753: MOV RAX,qword ptr [RBP + -0x18] POP RBP RET
ulong skip_trailing_space(ulong param_1,ulong param_2) { ulong uVar1; ulong uVar2; bool bVar3; ulong local_20; local_20 = param_1 + param_2; if (0x14 < param_2) { uVar1 = local_20 & 0xfffffffffffffffc; uVar2 = param_1 + 3 & 0xfffffffffffffffc; if (param_1 < uVar1) { while( true ) { bVar3 = false; if (uVar1 < local_20) { bVar3 = *(char *)(local_20 - 1) == ' '; } if (!bVar3) break; local_20 = local_20 - 1; } if ((*(char *)(local_20 - 1) == ' ') && (uVar2 < uVar1)) { while( true ) { bVar3 = false; if (uVar2 < local_20) { bVar3 = *(int *)(local_20 - 4) == 0x20202020; } if (!bVar3) break; local_20 = local_20 - 4; } } } } while( true ) { bVar3 = false; if (param_1 < local_20) { bVar3 = *(char *)(local_20 - 1) == ' '; } if (!bVar3) break; local_20 = local_20 - 1; } return local_20; }
6,014
common_arg::set_env(char const*)
monkey531[P]llama/common/arg.cpp
common_arg & common_arg::set_env(const char * env) { help = help + "\n(env: " + env + ")"; this->env = env; return *this; }
O1
cpp
common_arg::set_env(char const*): pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x68, %rsp movq %rsi, %r14 movq %rdi, %rbx leaq 0x18(%rsp), %r12 movq %r12, -0x10(%r12) movq 0x90(%rdi), %rsi movq 0x98(%rdi), %rdx addq %rsi, %rdx leaq 0x8(%rsp), %r15 movq %r15, %rdi callq 0x210f0 leaq 0xc6325(%rip), %rsi # 0xe7950 movq %r15, %rdi callq 0x1b070 leaq 0x8(%rsp), %rdi movq %r14, %rsi callq 0x1b070 leaq 0x38(%rsp), %r13 movq %r13, -0x10(%r13) movq (%rax), %rdx movq %rax, %rcx addq $0x10, %rcx cmpq %rcx, %rdx je 0x21667 movq %rdx, 0x28(%rsp) movq (%rcx), %rdx movq %rdx, 0x38(%rsp) jmp 0x2166f movups (%rcx), %xmm0 movups %xmm0, (%r13) movq 0x8(%rax), %rdx leaq 0x28(%rsp), %rdi movq %rdx, 0x8(%rdi) movq %rcx, (%rax) movq $0x0, 0x8(%rax) movb $0x0, 0x10(%rax) leaq 0xd3ea1(%rip), %rsi # 0xf5533 callq 0x1b070 leaq 0x90(%rbx), %rdi leaq 0x58(%rsp), %rbp movq %rbp, -0x10(%rbp) movq (%rax), %rdx movq %rax, %rcx addq $0x10, %rcx cmpq %rcx, %rdx je 0x216c5 movq %rdx, 0x48(%rsp) movq (%rcx), %rdx movq %rdx, 0x58(%rsp) jmp 0x216cc movups (%rcx), %xmm0 movups %xmm0, (%rbp) movq 0x8(%rax), %rdx leaq 0x48(%rsp), %r15 movq %rdx, 0x8(%r15) movq %rcx, (%rax) movq $0x0, 0x8(%rax) movb $0x0, 0x10(%rax) movq %r15, %rsi callq 0x1aa50 movq (%r15), %rdi cmpq %rbp, %rdi je 0x21705 movq 0x58(%rsp), %rsi incq %rsi callq 0x1a890 movq 0x28(%rsp), %rdi cmpq %r13, %rdi je 0x2171c movq 0x38(%rsp), %rsi incq %rsi callq 0x1a890 movq 0x8(%rsp), %rdi cmpq %r12, %rdi je 0x21733 movq 0x18(%rsp), %rsi incq %rsi callq 0x1a890 movq %r14, 0x88(%rbx) movq %rbx, %rax addq $0x68, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq movq %rax, %rbx movq 0x28(%rsp), %rdi cmpq %r13, %rdi je 0x2176d movq 0x38(%rsp), %rsi incq %rsi callq 0x1a890 jmp 0x2176d jmp 0x2176a movq %rax, %rbx movq 0x8(%rsp), %rdi cmpq %r12, %rdi je 0x21784 movq 0x18(%rsp), %rsi incq %rsi callq 0x1a890 movq %rbx, %rdi callq 0x1af20
_ZN10common_arg7set_envEPKc: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 68h mov r14, rsi mov rbx, rdi lea r12, [rsp+98h+var_80] mov [r12-10h], r12 mov rsi, [rdi+90h] mov rdx, [rdi+98h] add rdx, rsi lea r15, [rsp+98h+var_90] mov rdi, r15 call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIPcEEvT_S7_St20forward_iterator_tag; std::string::_M_construct<char *>(char *,char *,std::forward_iterator_tag) lea rsi, aEnv; "\n(env: " mov rdi, r15 call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendEPKc; std::string::append(char const*) lea rdi, [rsp+98h+var_90] mov rsi, r14 call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendEPKc; std::string::append(char const*) lea r13, [rsp+98h+var_60] mov [r13-10h], r13 mov rdx, [rax] mov rcx, rax add rcx, 10h cmp rdx, rcx jz short loc_21667 mov [rsp+98h+var_70], rdx mov rdx, [rcx] mov [rsp+98h+var_60], rdx jmp short loc_2166F loc_21667: movups xmm0, xmmword ptr [rcx] movups xmmword ptr [r13+0], xmm0 loc_2166F: mov rdx, [rax+8] lea rdi, [rsp+98h+var_70] mov [rdi+8], rdx mov [rax], rcx mov qword ptr [rax+8], 0 mov byte ptr [rax+10h], 0 lea rsi, a09401910201912+51h; ")" call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendEPKc; std::string::append(char const*) lea rdi, [rbx+90h] lea rbp, [rsp+98h+var_40] mov [rbp-10h], rbp mov rdx, [rax] mov rcx, rax add rcx, 10h cmp rdx, rcx jz short loc_216C5 mov [rsp+98h+var_50], rdx mov rdx, [rcx] mov [rsp+98h+var_40], rdx jmp short loc_216CC loc_216C5: movups xmm0, xmmword ptr [rcx] movups xmmword ptr [rbp+0], xmm0 loc_216CC: mov rdx, [rax+8] lea r15, [rsp+98h+var_50] mov [r15+8], rdx mov [rax], rcx mov qword ptr [rax+8], 0 mov byte ptr [rax+10h], 0 mov rsi, r15 call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEaSEOS4_; std::string::operator=(std::string&&) mov rdi, [r15]; void * cmp rdi, rbp jz short loc_21705 mov rsi, [rsp+98h+var_40] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_21705: mov rdi, [rsp+98h+var_70]; void * cmp rdi, r13 jz short loc_2171C mov rsi, [rsp+98h+var_60] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_2171C: mov rdi, [rsp+98h+var_90]; void * cmp rdi, r12 jz short loc_21733 mov rsi, [rsp+98h+var_80] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_21733: mov [rbx+88h], r14 mov rax, rbx add rsp, 68h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn mov rbx, rax mov rdi, [rsp+arg_20]; void * cmp rdi, r13 jz short loc_2176D mov rsi, [rsp+arg_30] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) jmp short loc_2176D jmp short $+2 loc_2176A: mov rbx, rax loc_2176D: mov rdi, [rsp+arg_0]; void * cmp rdi, r12 jz short loc_21784 mov rsi, [rsp+arg_10] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_21784: mov rdi, rbx call __Unwind_Resume
common_arg * common_arg::set_env(common_arg *this, const char *a2) { long long v2; // rax __int128 *v3; // rcx long long v4; // rax _OWORD *v5; // rcx void *v7[2]; // [rsp+8h] [rbp-90h] BYREF _QWORD v8[2]; // [rsp+18h] [rbp-80h] BYREF void *v9[2]; // [rsp+28h] [rbp-70h] BYREF __int128 v10; // [rsp+38h] [rbp-60h] BYREF void *v11[2]; // [rsp+48h] [rbp-50h] BYREF _OWORD v12[4]; // [rsp+58h] [rbp-40h] BYREF v7[0] = v8; std::string::_M_construct<char *>(v7, *((_BYTE **)this + 18), *((_QWORD *)this + 18) + *((_QWORD *)this + 19)); std::string::append(v7, "\n(env: "); v2 = std::string::append(v7, a2); v9[0] = &v10; v3 = (__int128 *)(v2 + 16); if ( *(_QWORD *)v2 == v2 + 16 ) { v10 = *v3; } else { v9[0] = *(void **)v2; *(_QWORD *)&v10 = *(_QWORD *)v3; } v9[1] = *(void **)(v2 + 8); *(_QWORD *)v2 = v3; *(_QWORD *)(v2 + 8) = 0LL; *(_BYTE *)(v2 + 16) = 0; v4 = std::string::append(v9, ")"); v11[0] = v12; v5 = (_OWORD *)(v4 + 16); if ( *(_QWORD *)v4 == v4 + 16 ) { v12[0] = *v5; } else { v11[0] = *(void **)v4; *(_QWORD *)&v12[0] = *(_QWORD *)v5; } v11[1] = *(void **)(v4 + 8); *(_QWORD *)v4 = v5; *(_QWORD *)(v4 + 8) = 0LL; *(_BYTE *)(v4 + 16) = 0; std::string::operator=((char *)this + 144, v11); if ( v11[0] != v12 ) operator delete(v11[0], *(_QWORD *)&v12[0] + 1LL); if ( v9[0] != &v10 ) operator delete(v9[0], v10 + 1); if ( v7[0] != v8 ) operator delete(v7[0], v8[0] + 1LL); *((_QWORD *)this + 17) = a2; return this; }
set_env: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x68 MOV R14,RSI MOV RBX,RDI LEA R12,[RSP + 0x18] MOV qword ptr [R12 + -0x10],R12 MOV RSI,qword ptr [RDI + 0x90] MOV RDX,qword ptr [RDI + 0x98] ADD RDX,RSI LEA R15,[RSP + 0x8] MOV RDI,R15 CALL 0x001210f0 LAB_00121624: LEA RSI,[0x1e7950] MOV RDI,R15 CALL 0x0011b070 LAB_00121633: LEA RDI,[RSP + 0x8] MOV RSI,R14 CALL 0x0011b070 LEA R13,[RSP + 0x38] MOV qword ptr [R13 + -0x10],R13 MOV RDX,qword ptr [RAX] MOV RCX,RAX ADD RCX,0x10 CMP RDX,RCX JZ 0x00121667 MOV qword ptr [RSP + 0x28],RDX MOV RDX,qword ptr [RCX] MOV qword ptr [RSP + 0x38],RDX JMP 0x0012166f LAB_00121667: MOVUPS XMM0,xmmword ptr [RCX] MOVUPS xmmword ptr [R13],XMM0 LAB_0012166f: MOV RDX,qword ptr [RAX + 0x8] LEA RDI,[RSP + 0x28] MOV qword ptr [RDI + 0x8],RDX MOV qword ptr [RAX],RCX MOV qword ptr [RAX + 0x8],0x0 MOV byte ptr [RAX + 0x10],0x0 LAB_0012168b: LEA RSI,[0x1f5533] CALL 0x0011b070 LAB_00121697: LEA RDI,[RBX + 0x90] LEA RBP,[RSP + 0x58] MOV qword ptr [RBP + -0x10],RBP MOV RDX,qword ptr [RAX] MOV RCX,RAX ADD RCX,0x10 CMP RDX,RCX JZ 0x001216c5 MOV qword ptr [RSP + 0x48],RDX MOV RDX,qword ptr [RCX] MOV qword ptr [RSP + 0x58],RDX JMP 0x001216cc LAB_001216c5: MOVUPS XMM0,xmmword ptr [RCX] MOVUPS xmmword ptr [RBP],XMM0 LAB_001216cc: MOV RDX,qword ptr [RAX + 0x8] LEA R15,[RSP + 0x48] MOV qword ptr [R15 + 0x8],RDX MOV qword ptr [RAX],RCX MOV qword ptr [RAX + 0x8],0x0 MOV byte ptr [RAX + 0x10],0x0 MOV RSI,R15 CALL 0x0011aa50 MOV RDI,qword ptr [R15] CMP RDI,RBP JZ 0x00121705 MOV RSI,qword ptr [RSP + 0x58] INC RSI CALL 0x0011a890 LAB_00121705: MOV RDI,qword ptr [RSP + 0x28] CMP RDI,R13 JZ 0x0012171c MOV RSI,qword ptr [RSP + 0x38] INC RSI CALL 0x0011a890 LAB_0012171c: MOV RDI,qword ptr [RSP + 0x8] CMP RDI,R12 JZ 0x00121733 MOV RSI,qword ptr [RSP + 0x18] INC RSI CALL 0x0011a890 LAB_00121733: MOV qword ptr [RBX + 0x88],R14 MOV RAX,RBX ADD RSP,0x68 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
/* common_arg::set_env(char const*) */ common_arg * __thiscall common_arg::set_env(common_arg *this,char *param_1) { long *plVar1; long *plVar2; long *local_90 [2]; long local_80 [2]; long *local_70; long local_68; long local_60; long lStack_58; long *local_50; long local_48; long local_40; long lStack_38; local_90[0] = local_80; std::__cxx11::string::_M_construct<char*> (local_90,*(long *)(this + 0x90),*(long *)(this + 0x98) + *(long *)(this + 0x90)); /* try { // try from 00121624 to 00121632 has its CatchHandler @ 0012176a */ std::__cxx11::string::append((char *)local_90); /* try { // try from 00121633 to 0012163f has its CatchHandler @ 00121768 */ plVar1 = (long *)std::__cxx11::string::append((char *)local_90); plVar2 = plVar1 + 2; if ((long *)*plVar1 == plVar2) { local_60 = *plVar2; lStack_58 = plVar1[3]; local_70 = &local_60; } else { local_60 = *plVar2; local_70 = (long *)*plVar1; } local_68 = plVar1[1]; *plVar1 = (long)plVar2; plVar1[1] = 0; *(int1 *)(plVar1 + 2) = 0; /* try { // try from 0012168b to 00121696 has its CatchHandler @ 0012174c */ plVar1 = (long *)std::__cxx11::string::append((char *)&local_70); plVar2 = plVar1 + 2; if ((long *)*plVar1 == plVar2) { local_40 = *plVar2; lStack_38 = plVar1[3]; local_50 = &local_40; } else { local_40 = *plVar2; local_50 = (long *)*plVar1; } local_48 = plVar1[1]; *plVar1 = (long)plVar2; plVar1[1] = 0; *(int1 *)(plVar1 + 2) = 0; std::__cxx11::string::operator=((string *)(this + 0x90),(string *)&local_50); if (local_50 != &local_40) { operator_delete(local_50,local_40 + 1); } if (local_70 != &local_60) { operator_delete(local_70,local_60 + 1); } if (local_90[0] != local_80) { operator_delete(local_90[0],local_80[0] + 1); } *(char **)(this + 0x88) = param_1; return this; }
6,015
my_readlink
eloqsql/mysys/my_symlink.c
int my_readlink(char *to, const char *filename, myf MyFlags) { #ifndef HAVE_READLINK strmov(to,filename); return 1; #else int result=0; int length; DBUG_ENTER("my_readlink"); if ((length=readlink(filename, to, FN_REFLEN-1)) < 0) { /* Don't give an error if this wasn't a symlink */ if ((my_errno=errno) == EINVAL) { result= 1; strmov(to,filename); } else { if (MyFlags & MY_WME) my_error(EE_CANT_READLINK, MYF(0), filename, errno); result= -1; } } else to[length]=0; DBUG_PRINT("exit" ,("result: %d", result)); DBUG_RETURN(result); #endif /* HAVE_READLINK */ }
O3
c
my_readlink: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx pushq %rax movq %rdx, %r15 movq %rsi, %rbx movq %rdi, %r14 movl $0x1ff, %edx # imm = 0x1FF movq %rsi, %rdi movq %r14, %rsi callq 0x24340 testl %eax, %eax js 0x3113a andl $0x7fffffff, %eax # imm = 0x7FFFFFFF movb $0x0, (%r14,%rax) xorl %r14d, %r14d jmp 0x31187 callq 0x24060 movq %rax, %r12 movl (%rax), %r13d callq 0x2a19e movl %r13d, (%rax) cmpl $0x16, %r13d jne 0x31166 movq %r14, %rdi movq %rbx, %rsi callq 0x242a0 movl $0x1, %r14d jmp 0x31187 movl $0xffffffff, %r14d # imm = 0xFFFFFFFF testb $0x10, %r15b je 0x31187 movl (%r12), %ecx movl $0x18, %edi xorl %esi, %esi movq %rbx, %rdx xorl %eax, %eax callq 0x2fcb7 movl %r14d, %eax addq $0x8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
my_readlink: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx push rax mov r15, rdx mov rbx, rsi mov r14, rdi mov edx, 1FFh mov rdi, rsi mov rsi, r14 call _readlink test eax, eax js short loc_3113A and eax, 7FFFFFFFh mov byte ptr [r14+rax], 0 xor r14d, r14d jmp short loc_31187 loc_3113A: call ___errno_location mov r12, rax mov r13d, [rax] call _my_thread_var mov [rax], r13d cmp r13d, 16h jnz short loc_31166 mov rdi, r14 mov rsi, rbx call _strcpy mov r14d, 1 jmp short loc_31187 loc_31166: mov r14d, 0FFFFFFFFh test r15b, 10h jz short loc_31187 mov ecx, [r12] mov edi, 18h xor esi, esi mov rdx, rbx xor eax, eax call my_error loc_31187: mov eax, r14d add rsp, 8 pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
long long my_readlink(long long a1, long long a2, char a3) { int v4; // eax unsigned int v5; // r14d unsigned int *v6; // r12 unsigned int v7; // r13d v4 = readlink(a2, a1, 511LL); if ( v4 < 0 ) { v6 = (unsigned int *)__errno_location(a2); v7 = *v6; *(_DWORD *)my_thread_var() = v7; if ( v7 == 22 ) { strcpy(a1, a2); return 1; } else { v5 = -1; if ( (a3 & 0x10) != 0 ) my_error(0x18u, 0, a2, *v6); } } else { *(_BYTE *)(a1 + (v4 & 0x7FFFFFFF)) = 0; return 0; } return v5; }
my_readlink: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX PUSH RAX MOV R15,RDX MOV RBX,RSI MOV R14,RDI MOV EDX,0x1ff MOV RDI,RSI MOV RSI,R14 CALL 0x00124340 TEST EAX,EAX JS 0x0013113a AND EAX,0x7fffffff MOV byte ptr [R14 + RAX*0x1],0x0 XOR R14D,R14D JMP 0x00131187 LAB_0013113a: CALL 0x00124060 MOV R12,RAX MOV R13D,dword ptr [RAX] CALL 0x0012a19e MOV dword ptr [RAX],R13D CMP R13D,0x16 JNZ 0x00131166 MOV RDI,R14 MOV RSI,RBX CALL 0x001242a0 MOV R14D,0x1 JMP 0x00131187 LAB_00131166: MOV R14D,0xffffffff TEST R15B,0x10 JZ 0x00131187 MOV ECX,dword ptr [R12] MOV EDI,0x18 XOR ESI,ESI MOV RDX,RBX XOR EAX,EAX CALL 0x0012fcb7 LAB_00131187: MOV EAX,R14D ADD RSP,0x8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
int8 my_readlink(char *param_1,char *param_2,ulong param_3) { int iVar1; ssize_t sVar2; int *piVar3; int *piVar4; int8 uVar5; sVar2 = readlink(param_2,param_1,0x1ff); if ((int)(uint)sVar2 < 0) { piVar3 = __errno_location(); iVar1 = *piVar3; piVar4 = (int *)_my_thread_var(); *piVar4 = iVar1; if (iVar1 == 0x16) { strcpy(param_1,param_2); uVar5 = 1; } else { uVar5 = 0xffffffff; if ((param_3 & 0x10) != 0) { my_error(0x18,0,param_2,*piVar3); } } } else { param_1[(uint)sVar2 & 0x7fffffff] = '\0'; uVar5 = 0; } return uVar5; }
6,016
testing::internal::CmpHelperSTRNE(char const*, char const*, char const*, char const*)
giladroyz[P]FindPeaks/build_O1/_deps/googletest-src/googletest/src/gtest.cc
AssertionResult CmpHelperSTRNE(const char* s1_expression, const char* s2_expression, const char* s1, const char* s2) { if (!String::CStringEquals(s1, s2)) { return AssertionSuccess(); } else { return AssertionFailure() << "Expected: (" << s1_expression << ") != (" << s2_expression << "), actual: \"" << s1 << "\" vs \"" << s2 << "\""; } }
O1
cpp
testing::internal::CmpHelperSTRNE(char const*, char const*, char const*, char const*): pushq %r14 pushq %rbx subq $0x38, %rsp movq %rdi, %rbx movq %rsi, 0x30(%rsp) movq %rdx, 0x28(%rsp) movq %rcx, 0x20(%rsp) movq %r8, 0x18(%rsp) testq %r8, %r8 sete %al testq %rcx, %rcx je 0x1e88d testq %r8, %r8 je 0x1e946 movq %rcx, %rdi movq %r8, %rsi callq 0x87a0 testl %eax, %eax sete %al testb %al, %al je 0x1e946 leaq 0x10(%rsp), %r14 movb $0x0, -0x8(%r14) movq $0x0, (%r14) leaq 0x21d1c(%rip), %rsi # 0x405c9 leaq 0x8(%rsp), %rdi callq 0xe620 leaq 0x30(%rsp), %rsi movq %rax, %rdi callq 0xe69e leaq 0x24402(%rip), %rsi # 0x42ccd movq %rax, %rdi callq 0x335a2 leaq 0x28(%rsp), %rsi movq %rax, %rdi callq 0xe69e leaq 0x24404(%rip), %rsi # 0x42ceb movq %rax, %rdi callq 0x33cbc leaq 0x20(%rsp), %rsi movq %rax, %rdi callq 0xe69e leaq 0x243d1(%rip), %rsi # 0x42cd4 movq %rax, %rdi callq 0x335a2 leaq 0x18(%rsp), %rsi movq %rax, %rdi callq 0xe69e leaq 0x24dcc(%rip), %rsi # 0x436eb movq %rax, %rdi callq 0x33620 movq %rbx, %rdi movq %rax, %rsi callq 0xefc4 movq 0x10(%rsp), %rsi testq %rsi, %rsi je 0x1e951 movq %r14, %rdi callq 0xde4a jmp 0x1e951 movb $0x1, (%rbx) movq $0x0, 0x8(%rbx) movq %rbx, %rax addq $0x38, %rsp popq %rbx popq %r14 retq movq %rax, %rbx movq 0x10(%rsp), %rsi testq %rsi, %rsi je 0x1e971 movq %r14, %rdi callq 0xde4a movq %rbx, %rdi callq 0x8990
_ZN7testing8internal14CmpHelperSTRNEEPKcS2_S2_S2_: push r14 push rbx sub rsp, 38h mov rbx, rdi mov [rsp+48h+var_18], rsi mov [rsp+48h+var_20], rdx mov [rsp+48h+var_28], rcx mov [rsp+48h+var_30], r8 test r8, r8 setz al test rcx, rcx jz short loc_1E88D test r8, r8 jz loc_1E946 mov rdi, rcx mov rsi, r8 call _strcmp test eax, eax setz al loc_1E88D: test al, al jz loc_1E946 lea r14, [rsp+48h+var_38] mov byte ptr [r14-8], 0 mov qword ptr [r14], 0 lea rsi, aExpected; "Expected: (" lea rdi, [rsp+48h+var_40]; this call _ZN7testing15AssertionResultlsIA12_cEERS0_RKT_; testing::AssertionResult::operator<<<char [12]>(char [12] const&) lea rsi, [rsp+48h+var_18] mov rdi, rax; this call _ZN7testing15AssertionResultlsIPKcEERS0_RKT_; testing::AssertionResult::operator<<<char const*>(char const* const&) lea rsi, asc_42CCD; ") != (" mov rdi, rax; this call _ZN7testing15AssertionResultlsIA7_cEERS0_RKT_; testing::AssertionResult::operator<<<char [7]>(char [7] const&) lea rsi, [rsp+48h+var_20] mov rdi, rax; this call _ZN7testing15AssertionResultlsIPKcEERS0_RKT_; testing::AssertionResult::operator<<<char const*>(char const* const&) lea rsi, aIgnoringCaseAc+10h; "), actual: \"" mov rdi, rax; this call _ZN7testing15AssertionResultlsIA13_cEERS0_RKT_; testing::AssertionResult::operator<<<char [13]>(char [13] const&) lea rsi, [rsp+48h+var_28] mov rdi, rax; this call _ZN7testing15AssertionResultlsIPKcEERS0_RKT_; testing::AssertionResult::operator<<<char const*>(char const* const&) lea rsi, aVs_0; "\" vs \"" mov rdi, rax; this call _ZN7testing15AssertionResultlsIA7_cEERS0_RKT_; testing::AssertionResult::operator<<<char [7]>(char [7] const&) lea rsi, [rsp+48h+var_30] mov rdi, rax; this call _ZN7testing15AssertionResultlsIPKcEERS0_RKT_; testing::AssertionResult::operator<<<char const*>(char const* const&) lea rsi, aMessage+0Fh; "\"" mov rdi, rax; this call _ZN7testing15AssertionResultlsIA2_cEERS0_RKT_; testing::AssertionResult::operator<<<char [2]>(char [2] const&) mov rdi, rbx mov rsi, rax call _ZN7testing15AssertionResultC2ERKS0_; testing::AssertionResult::AssertionResult(testing::AssertionResult const&) mov rsi, [rsp+48h+var_38] test rsi, rsi jz short loc_1E951 mov rdi, r14 call _ZNKSt14default_deleteINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEclEPS5_; std::default_delete<std::string>::operator()(std::string*) jmp short loc_1E951 loc_1E946: mov byte ptr [rbx], 1 mov qword ptr [rbx+8], 0 loc_1E951: mov rax, rbx add rsp, 38h pop rbx pop r14 retn mov rbx, rax mov rsi, [rsp+arg_8] test rsi, rsi jz short loc_1E971 mov rdi, r14 call _ZNKSt14default_deleteINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEclEPS5_; std::default_delete<std::string>::operator()(std::string*) loc_1E971: mov rdi, rbx call __Unwind_Resume
testing::internal * testing::internal::CmpHelperSTRNE( testing::internal *this, const char *a2, const char *a3, const char *a4, const char *a5) { bool v5; // al testing::AssertionResult *v6; // rax testing::AssertionResult *v7; // rax testing::AssertionResult *v8; // rax testing::AssertionResult *v9; // rax testing::AssertionResult *v10; // rax testing::AssertionResult *v11; // rax testing::AssertionResult *v12; // rax testing::AssertionResult *v13; // rax const testing::AssertionResult *v14; // rax long long v16; // [rsp+0h] [rbp-48h] long long v17; // [rsp+0h] [rbp-48h] long long v18; // [rsp+0h] [rbp-48h] long long v19; // [rsp+0h] [rbp-48h] _BYTE v20[8]; // [rsp+8h] [rbp-40h] BYREF long long v21; // [rsp+10h] [rbp-38h] BYREF const char *v22; // [rsp+18h] [rbp-30h] BYREF const char *v23; // [rsp+20h] [rbp-28h] BYREF const char *v24; // [rsp+28h] [rbp-20h] BYREF const char *v25; // [rsp+30h] [rbp-18h] BYREF v25 = a2; v24 = a3; v23 = a4; v22 = a5; v5 = a5 == 0LL; if ( a4 ) { if ( !a5 ) { LABEL_7: *(_BYTE *)this = 1; *((_QWORD *)this + 1) = 0LL; return this; } v5 = (unsigned int)strcmp(a4, a5) == 0; } if ( !v5 ) goto LABEL_7; v20[0] = 0; v21 = 0LL; v6 = testing::AssertionResult::operator<<<char [12]>((testing::AssertionResult *)v20, (long long)"Expected: ("); v7 = testing::AssertionResult::operator<<<char const*>(v6, &v25); v8 = (testing::AssertionResult *)testing::AssertionResult::operator<<<char [7]>(v7, v16); v9 = testing::AssertionResult::operator<<<char const*>(v8, &v24); v10 = (testing::AssertionResult *)testing::AssertionResult::operator<<<char [13]>(v9, v17); v11 = testing::AssertionResult::operator<<<char const*>(v10, &v23); v12 = (testing::AssertionResult *)testing::AssertionResult::operator<<<char [7]>(v11, v18); v13 = testing::AssertionResult::operator<<<char const*>(v12, &v22); v14 = (const testing::AssertionResult *)testing::AssertionResult::operator<<<char [2]>(v13, v19); testing::AssertionResult::AssertionResult(this, v14); if ( v21 ) std::default_delete<std::string>::operator()((long long)&v21, v21); return this; }
CmpHelperSTRNE: PUSH R14 PUSH RBX SUB RSP,0x38 MOV RBX,RDI MOV qword ptr [RSP + 0x30],RSI MOV qword ptr [RSP + 0x28],RDX MOV qword ptr [RSP + 0x20],RCX MOV qword ptr [RSP + 0x18],R8 TEST R8,R8 SETZ AL TEST RCX,RCX JZ 0x0011e88d TEST R8,R8 JZ 0x0011e946 MOV RDI,RCX MOV RSI,R8 CALL 0x001087a0 TEST EAX,EAX SETZ AL LAB_0011e88d: TEST AL,AL JZ 0x0011e946 LEA R14,[RSP + 0x10] MOV byte ptr [R14 + -0x8],0x0 MOV qword ptr [R14],0x0 LAB_0011e8a6: LEA RSI,[0x1405c9] LEA RDI,[RSP + 0x8] CALL 0x0010e620 LEA RSI,[RSP + 0x30] MOV RDI,RAX CALL 0x0010e69e LEA RSI,[0x142ccd] MOV RDI,RAX CALL 0x001335a2 LEA RSI,[RSP + 0x28] MOV RDI,RAX CALL 0x0010e69e LEA RSI,[0x142ceb] MOV RDI,RAX CALL 0x00133cbc LEA RSI,[RSP + 0x20] MOV RDI,RAX CALL 0x0010e69e LEA RSI,[0x142cd4] MOV RDI,RAX CALL 0x001335a2 LEA RSI,[RSP + 0x18] MOV RDI,RAX CALL 0x0010e69e LEA RSI,[0x1436eb] MOV RDI,RAX CALL 0x00133620 MOV RDI,RBX MOV RSI,RAX CALL 0x0010efc4 LAB_0011e932: MOV RSI,qword ptr [RSP + 0x10] TEST RSI,RSI JZ 0x0011e951 MOV RDI,R14 CALL 0x0010de4a JMP 0x0011e951 LAB_0011e946: MOV byte ptr [RBX],0x1 MOV qword ptr [RBX + 0x8],0x0 LAB_0011e951: MOV RAX,RBX ADD RSP,0x38 POP RBX POP R14 RET
/* testing::internal::CmpHelperSTRNE(char const*, char const*, char const*, char const*) */ internal * __thiscall testing::internal::CmpHelperSTRNE (internal *this,char *param_1,char *param_2,char *param_3,char *param_4) { int iVar1; AssertionResult *pAVar2; bool bVar3; AssertionResult local_40 [8]; string *local_38; char *local_30; char *local_28; char *local_20; char *local_18; bVar3 = param_4 == (char *)0x0; local_30 = param_4; local_28 = param_3; local_20 = param_2; local_18 = param_1; if (param_3 != (char *)0x0) { if (param_4 == (char *)0x0) goto LAB_0011e946; iVar1 = strcmp(param_3,param_4); bVar3 = iVar1 == 0; } if (bVar3) { local_40[0] = (AssertionResult)0x0; local_38 = (string *)0x0; /* try { // try from 0011e8a6 to 0011e931 has its CatchHandler @ 0011e95c */ pAVar2 = (AssertionResult *)AssertionResult::operator<<(local_40,"Expected: ("); pAVar2 = AssertionResult::operator<<(pAVar2,&local_18); pAVar2 = AssertionResult::operator<<(pAVar2,") != ("); pAVar2 = AssertionResult::operator<<(pAVar2,&local_20); pAVar2 = AssertionResult::operator<<(pAVar2,"), actual: \""); pAVar2 = AssertionResult::operator<<(pAVar2,&local_28); pAVar2 = AssertionResult::operator<<(pAVar2,"\" vs \""); pAVar2 = AssertionResult::operator<<(pAVar2,&local_30); pAVar2 = AssertionResult::operator<<(pAVar2,"\""); AssertionResult::AssertionResult((AssertionResult *)this,pAVar2); if (local_38 == (string *)0x0) { return this; } std::default_delete<std::__cxx11::string>::operator() ((default_delete<std::__cxx11::string> *)&local_38,local_38); return this; } LAB_0011e946: *this = (internal)0x1; *(int8 *)(this + 8) = 0; return this; }
6,017
mysql_fetch_row_cont
eloqsql/libmariadb/libmariadb/mariadb_async.c
int STDCALL mysql_fetch_row_cont(MYSQL_ROW *ret, MYSQL_RES *result, int ready_status) { MK_ASYNC_CONT_BODY( result->handle, NULL, r_ptr) }
O3
c
mysql_fetch_row_cont: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %rbx pushq %rax movq %rsi, %r14 movq %rdi, %rbx movq 0x78(%rsi), %rax movq 0x480(%rax), %rcx movq 0x28(%rcx), %r15 cmpb $0x0, 0x15(%r15) je 0x49f78 movb $0x1, 0x14(%r15) movl %edx, 0x4(%r15) leaq 0x38(%r15), %rdi callq 0x4e777 movb $0x0, 0x14(%r15) testl %eax, %eax jle 0x49fdf movl (%r15), %r15d jmp 0x4a054 movl $0x7de, 0x90(%rax) # imm = 0x7DE movl $0x297, %edi # imm = 0x297 addq 0x78(%r14), %rdi leaq 0x2e3a2e(%rip), %rax # 0x32d9c0 movq (%rax), %rsi movl $0x5, %edx callq 0x35110 movq 0x78(%r14), %rax xorl %r15d, %r15d movb %r15b, 0x29c(%rax) movl $0x97, %edi addq 0x78(%r14), %rdi leaq 0x2e3a13(%rip), %rax # 0x32d9d0 movq 0x70(%rax), %rsi movl $0x1ff, %edx # imm = 0x1FF callq 0x35110 movq 0x78(%r14), %rax movb %r15b, 0x296(%rax) movq $0x0, (%rbx) jmp 0x4a054 movb $0x0, 0x15(%r15) js 0x49fec movq 0x8(%r15), %r15 jmp 0x4a04e movq 0x78(%r14), %rax movl $0x7d8, 0x90(%rax) # imm = 0x7D8 movl $0x297, %edi # imm = 0x297 addq 0x78(%r14), %rdi leaq 0x2e39b6(%rip), %rax # 0x32d9c0 movq (%rax), %rsi movl $0x5, %edx callq 0x35110 movq 0x78(%r14), %rax xorl %r15d, %r15d movb %r15b, 0x29c(%rax) movl $0x97, %edi addq 0x78(%r14), %rdi leaq 0x2e399b(%rip), %rax # 0x32d9d0 movq 0x40(%rax), %rsi movl $0x1ff, %edx # imm = 0x1FF callq 0x35110 movq 0x78(%r14), %rax movb %r15b, 0x296(%rax) movq %r15, (%rbx) xorl %r15d, %r15d movl %r15d, %eax addq $0x8, %rsp popq %rbx popq %r14 popq %r15 popq %rbp retq
mysql_fetch_row_cont: push rbp mov rbp, rsp push r15 push r14 push rbx push rax mov r14, rsi mov rbx, rdi mov rax, [rsi+78h] mov rcx, [rax+480h] mov r15, [rcx+28h] cmp byte ptr [r15+15h], 0 jz short loc_49F78 mov byte ptr [r15+14h], 1 mov [r15+4], edx lea rdi, [r15+38h] call my_context_continue mov byte ptr [r15+14h], 0 test eax, eax jle short loc_49FDF mov r15d, [r15] jmp loc_4A054 loc_49F78: mov dword ptr [rax+90h], 7DEh mov edi, 297h add rdi, [r14+78h] lea rax, SQLSTATE_UNKNOWN mov rsi, [rax] mov edx, 5 call _strncpy mov rax, [r14+78h] xor r15d, r15d mov [rax+29Ch], r15b mov edi, 97h add rdi, [r14+78h] lea rax, client_errors mov rsi, [rax+70h] mov edx, 1FFh call _strncpy mov rax, [r14+78h] mov [rax+296h], r15b mov qword ptr [rbx], 0 jmp short loc_4A054 loc_49FDF: mov byte ptr [r15+15h], 0 js short loc_49FEC mov r15, [r15+8] jmp short loc_4A04E loc_49FEC: mov rax, [r14+78h] mov dword ptr [rax+90h], 7D8h mov edi, 297h add rdi, [r14+78h] lea rax, SQLSTATE_UNKNOWN mov rsi, [rax] mov edx, 5 call _strncpy mov rax, [r14+78h] xor r15d, r15d mov [rax+29Ch], r15b mov edi, 97h add rdi, [r14+78h] lea rax, client_errors mov rsi, [rax+40h] mov edx, 1FFh call _strncpy mov rax, [r14+78h] mov [rax+296h], r15b loc_4A04E: mov [rbx], r15 xor r15d, r15d loc_4A054: mov eax, r15d add rsp, 8 pop rbx pop r14 pop r15 pop rbp retn
long long mysql_fetch_row_cont(_QWORD *a1, long long a2, unsigned int a3) { long long v3; // rax unsigned int *v4; // r15 int v5; // eax unsigned int v6; // r15d long long v7; // r15 v3 = *(_QWORD *)(a2 + 120); v4 = *(unsigned int **)(*(_QWORD *)(v3 + 1152) + 40LL); if ( *((_BYTE *)v4 + 21) ) { *((_BYTE *)v4 + 20) = 1; v4[1] = a3; v5 = my_context_continue(v4 + 14); *((_BYTE *)v4 + 20) = 0; if ( v5 <= 0 ) { *((_BYTE *)v4 + 21) = 0; if ( v5 < 0 ) { *(_DWORD *)(*(_QWORD *)(a2 + 120) + 144LL) = 2008; strncpy(*(_QWORD *)(a2 + 120) + 663LL, SQLSTATE_UNKNOWN, 5LL); v7 = 0LL; *(_BYTE *)(*(_QWORD *)(a2 + 120) + 668LL) = 0; strncpy(*(_QWORD *)(a2 + 120) + 151LL, client_errors[8], 511LL); *(_BYTE *)(*(_QWORD *)(a2 + 120) + 662LL) = 0; } else { v7 = *((_QWORD *)v4 + 1); } *a1 = v7; return 0; } else { return *v4; } } else { *(_DWORD *)(v3 + 144) = 2014; strncpy(*(_QWORD *)(a2 + 120) + 663LL, SQLSTATE_UNKNOWN, 5LL); v6 = 0; *(_BYTE *)(*(_QWORD *)(a2 + 120) + 668LL) = 0; strncpy(*(_QWORD *)(a2 + 120) + 151LL, client_errors[14], 511LL); *(_BYTE *)(*(_QWORD *)(a2 + 120) + 662LL) = 0; *a1 = 0LL; } return v6; }
mysql_fetch_row_cont: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH RBX PUSH RAX MOV R14,RSI MOV RBX,RDI MOV RAX,qword ptr [RSI + 0x78] MOV RCX,qword ptr [RAX + 0x480] MOV R15,qword ptr [RCX + 0x28] CMP byte ptr [R15 + 0x15],0x0 JZ 0x00149f78 MOV byte ptr [R15 + 0x14],0x1 MOV dword ptr [R15 + 0x4],EDX LEA RDI,[R15 + 0x38] CALL 0x0014e777 MOV byte ptr [R15 + 0x14],0x0 TEST EAX,EAX JLE 0x00149fdf MOV R15D,dword ptr [R15] JMP 0x0014a054 LAB_00149f78: MOV dword ptr [RAX + 0x90],0x7de MOV EDI,0x297 ADD RDI,qword ptr [R14 + 0x78] LEA RAX,[0x42d9c0] MOV RSI,qword ptr [RAX] MOV EDX,0x5 CALL 0x00135110 MOV RAX,qword ptr [R14 + 0x78] XOR R15D,R15D MOV byte ptr [RAX + 0x29c],R15B MOV EDI,0x97 ADD RDI,qword ptr [R14 + 0x78] LEA RAX,[0x42d9d0] MOV RSI,qword ptr [RAX + 0x70] MOV EDX,0x1ff CALL 0x00135110 MOV RAX,qword ptr [R14 + 0x78] MOV byte ptr [RAX + 0x296],R15B MOV qword ptr [RBX],0x0 JMP 0x0014a054 LAB_00149fdf: MOV byte ptr [R15 + 0x15],0x0 JS 0x00149fec MOV R15,qword ptr [R15 + 0x8] JMP 0x0014a04e LAB_00149fec: MOV RAX,qword ptr [R14 + 0x78] MOV dword ptr [RAX + 0x90],0x7d8 MOV EDI,0x297 ADD RDI,qword ptr [R14 + 0x78] LEA RAX,[0x42d9c0] MOV RSI,qword ptr [RAX] MOV EDX,0x5 CALL 0x00135110 MOV RAX,qword ptr [R14 + 0x78] XOR R15D,R15D MOV byte ptr [RAX + 0x29c],R15B MOV EDI,0x97 ADD RDI,qword ptr [R14 + 0x78] LEA RAX,[0x42d9d0] MOV RSI,qword ptr [RAX + 0x40] MOV EDX,0x1ff CALL 0x00135110 MOV RAX,qword ptr [R14 + 0x78] MOV byte ptr [RAX + 0x296],R15B LAB_0014a04e: MOV qword ptr [RBX],R15 XOR R15D,R15D LAB_0014a054: MOV EAX,R15D ADD RSP,0x8 POP RBX POP R14 POP R15 POP RBP RET
int4 mysql_fetch_row_cont(int8 *param_1,long param_2,int4 param_3) { int4 *puVar1; int iVar2; int4 uVar3; int8 uVar4; puVar1 = *(int4 **)(*(long *)(*(long *)(param_2 + 0x78) + 0x480) + 0x28); if (*(char *)((long)puVar1 + 0x15) == '\0') { *(int4 *)(*(long *)(param_2 + 0x78) + 0x90) = 0x7de; strncpy((char *)(*(long *)(param_2 + 0x78) + 0x297),SQLSTATE_UNKNOWN,5); uVar3 = 0; *(int1 *)(*(long *)(param_2 + 0x78) + 0x29c) = 0; strncpy((char *)(*(long *)(param_2 + 0x78) + 0x97), PTR_s_Commands_out_of_sync__you_can_t_r_0042da40,0x1ff); *(int1 *)(*(long *)(param_2 + 0x78) + 0x296) = 0; *param_1 = 0; } else { *(int1 *)(puVar1 + 5) = 1; puVar1[1] = param_3; iVar2 = my_context_continue(puVar1 + 0xe); *(int1 *)(puVar1 + 5) = 0; if (iVar2 < 1) { *(int1 *)((long)puVar1 + 0x15) = 0; if (iVar2 < 0) { *(int4 *)(*(long *)(param_2 + 0x78) + 0x90) = 0x7d8; strncpy((char *)(*(long *)(param_2 + 0x78) + 0x297),SQLSTATE_UNKNOWN,5); uVar4 = 0; *(int1 *)(*(long *)(param_2 + 0x78) + 0x29c) = 0; strncpy((char *)(*(long *)(param_2 + 0x78) + 0x97),PTR_s_Client_run_out_of_memory_0042da10, 0x1ff); *(int1 *)(*(long *)(param_2 + 0x78) + 0x296) = 0; } else { uVar4 = *(int8 *)(puVar1 + 2); } *param_1 = uVar4; uVar3 = 0; } else { uVar3 = *puVar1; } } return uVar3; }
6,018
my_hash_update
eloqsql/mysys/hash.c
my_bool my_hash_update(HASH *hash, uchar *record, uchar *old_key, size_t old_key_length) { uint new_index, new_pos_index, org_index, records, idx; size_t length, empty, blength; my_hash_value_type hash_nr; HASH_LINK org_link,*data,*previous,*pos; uchar *new_key; DBUG_ENTER("my_hash_update"); new_key= (uchar*) my_hash_key(hash, record, &length, 1); hash_nr= hash->hash_function(hash->charset, new_key, length); if (HASH_UNIQUE & hash->flags) { HASH_SEARCH_STATE state; uchar *found; if ((found= my_hash_first_from_hash_value(hash, hash_nr, new_key, length, &state))) { do { if (found != record) DBUG_RETURN(1); /* Duplicate entry */ } while ((found= my_hash_next(hash, new_key, length, &state))); } } data=dynamic_element(&hash->array,0,HASH_LINK*); blength=hash->blength; records=hash->records; /* Search after record with key */ idx= my_hash_mask(hash->hash_function(hash->charset, old_key, (old_key_length ? old_key_length : hash->key_length)), blength, records); org_index= idx; new_index= my_hash_mask(hash_nr, blength, records); previous=0; for (;;) { if ((pos= data+idx)->data == record) break; previous=pos; if ((idx=pos->next) == NO_RECORD) DBUG_RETURN(1); /* Not found in links */ } if (org_index == new_index) { data[idx].hash_nr= hash_nr; /* Hash number may have changed */ DBUG_RETURN(0); /* Record is in right position */ } org_link= *pos; empty=idx; /* Relink record from current chain */ if (!previous) { if (pos->next != NO_RECORD) { empty=pos->next; *pos= data[pos->next]; } } else previous->next=pos->next; /* unlink pos */ /* Move data to correct position */ if (new_index == empty) { /* At this point record is unlinked from the old chain, thus it holds random position. By the chance this position is equal to position for the first element in the new chain. That means updated record is the only record in the new chain. */ if (empty != idx) { /* Record was moved while unlinking it from the old chain. Copy data to a new position. */ data[empty]= org_link; } data[empty].next= NO_RECORD; data[empty].hash_nr= hash_nr; DBUG_RETURN(0); } pos=data+new_index; new_pos_index= my_hash_rec_mask(pos, blength, records); if (new_index != new_pos_index) { /* Other record in wrong position */ data[empty]= *pos; movelink(data,new_index,new_pos_index, (uint) empty); org_link.next=NO_RECORD; data[new_index]= org_link; data[new_index].hash_nr= hash_nr; } else { /* Link in chain at right position */ org_link.next=data[new_index].next; data[empty]=org_link; data[empty].hash_nr= hash_nr; data[new_index].next= (uint) empty; } DBUG_RETURN(0); }
O0
c
my_hash_update: pushq %rbp movq %rsp, %rbp subq $0xc0, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq %rdx, -0x20(%rbp) movq %rcx, -0x28(%rbp) movq -0x10(%rbp), %rdi movq -0x18(%rbp), %rsi leaq -0x48(%rbp), %rdx movl $0x1, %ecx callq 0xadab0 movq %rax, -0x90(%rbp) movq -0x10(%rbp), %rax movq 0x58(%rax), %rax movq -0x10(%rbp), %rcx movq 0x68(%rcx), %rdi movq -0x90(%rbp), %rsi movq -0x48(%rbp), %rdx callq *%rax movl %eax, -0x5c(%rbp) movq -0x10(%rbp), %rax movl 0x20(%rax), %eax andl $0x1, %eax cmpl $0x0, %eax je 0xae03a movq -0x10(%rbp), %rdi movl -0x5c(%rbp), %esi movq -0x90(%rbp), %rdx movq -0x48(%rbp), %rcx leaq -0x94(%rbp), %r8 callq 0xad290 movq %rax, -0xa0(%rbp) cmpq $0x0, %rax je 0xae038 jmp 0xadff4 movq -0xa0(%rbp), %rax cmpq -0x18(%rbp), %rax je 0xae00c jmp 0xae003 movb $0x1, -0x1(%rbp) jmp 0xae352 jmp 0xae00e movq -0x10(%rbp), %rdi movq -0x90(%rbp), %rsi movq -0x48(%rbp), %rdx leaq -0x94(%rbp), %rcx callq 0xad4b0 movq %rax, -0xa0(%rbp) cmpq $0x0, %rax jne 0xadff4 jmp 0xae038 jmp 0xae03a movq -0x10(%rbp), %rax movq 0x28(%rax), %rax movq %rax, -0x78(%rbp) movq -0x10(%rbp), %rax movq 0x10(%rax), %rax movq %rax, -0x58(%rbp) movq -0x10(%rbp), %rax movq 0x18(%rax), %rax movl %eax, -0x38(%rbp) movq -0x10(%rbp), %rax movq 0x58(%rax), %rax movq %rax, -0xb8(%rbp) movq -0x10(%rbp), %rax movq 0x68(%rax), %rax movq %rax, -0xb0(%rbp) movq -0x20(%rbp), %rax movq %rax, -0xa8(%rbp) cmpq $0x0, -0x28(%rbp) je 0xae09a movq -0x28(%rbp), %rax movq %rax, -0xc0(%rbp) jmp 0xae0a9 movq -0x10(%rbp), %rax movq 0x8(%rax), %rax movq %rax, -0xc0(%rbp) movq -0xb8(%rbp), %rax movq -0xa8(%rbp), %rsi movq -0xb0(%rbp), %rdi movq -0xc0(%rbp), %rdx callq *%rax movl %eax, %edi movq -0x58(%rbp), %rsi movl -0x38(%rbp), %eax movl %eax, %edx callq 0xad390 movl %eax, -0x3c(%rbp) movl -0x3c(%rbp), %eax movl %eax, -0x34(%rbp) movl -0x5c(%rbp), %edi movq -0x58(%rbp), %rsi movl -0x38(%rbp), %eax movl %eax, %edx callq 0xad390 movl %eax, -0x2c(%rbp) movq $0x0, -0x80(%rbp) movq -0x78(%rbp), %rax movl -0x3c(%rbp), %ecx shlq $0x4, %rcx addq %rcx, %rax movq %rax, -0x88(%rbp) movq 0x8(%rax), %rax cmpq -0x18(%rbp), %rax jne 0xae11d jmp 0xae146 movq -0x88(%rbp), %rax movq %rax, -0x80(%rbp) movq -0x88(%rbp), %rax movl (%rax), %eax movl %eax, -0x3c(%rbp) cmpl $-0x1, %eax jne 0xae144 jmp 0xae13b movb $0x1, -0x1(%rbp) jmp 0xae352 jmp 0xae0fc movl -0x34(%rbp), %eax cmpl -0x2c(%rbp), %eax jne 0xae16b movl -0x5c(%rbp), %ecx movq -0x78(%rbp), %rax movl -0x3c(%rbp), %edx shlq $0x4, %rdx addq %rdx, %rax movl %ecx, 0x4(%rax) movb $0x0, -0x1(%rbp) jmp 0xae352 movq -0x88(%rbp), %rax movq (%rax), %rcx movq %rcx, -0x70(%rbp) movq 0x8(%rax), %rax movq %rax, -0x68(%rbp) movl -0x3c(%rbp), %eax movq %rax, -0x50(%rbp) cmpq $0x0, -0x80(%rbp) jne 0xae1d3 movq -0x88(%rbp), %rax cmpl $-0x1, (%rax) je 0xae1d1 movq -0x88(%rbp), %rax movl (%rax), %eax movq %rax, -0x50(%rbp) movq -0x88(%rbp), %rax movq -0x78(%rbp), %rcx movq -0x88(%rbp), %rdx movl (%rdx), %edx shlq $0x4, %rdx addq %rdx, %rcx movq (%rcx), %rdx movq %rdx, (%rax) movq 0x8(%rcx), %rcx movq %rcx, 0x8(%rax) jmp 0xae1e2 movq -0x88(%rbp), %rax movl (%rax), %ecx movq -0x80(%rbp), %rax movl %ecx, (%rax) movl -0x2c(%rbp), %eax cmpq -0x50(%rbp), %rax jne 0xae248 movq -0x50(%rbp), %rax movl -0x3c(%rbp), %ecx cmpq %rcx, %rax je 0xae215 movq -0x78(%rbp), %rax movq -0x50(%rbp), %rcx shlq $0x4, %rcx addq %rcx, %rax movq -0x70(%rbp), %rcx movq %rcx, (%rax) movq -0x68(%rbp), %rcx movq %rcx, 0x8(%rax) movq -0x78(%rbp), %rax movq -0x50(%rbp), %rcx shlq $0x4, %rcx addq %rcx, %rax movl $0xffffffff, (%rax) # imm = 0xFFFFFFFF movl -0x5c(%rbp), %ecx movq -0x78(%rbp), %rax movq -0x50(%rbp), %rdx shlq $0x4, %rdx addq %rdx, %rax movl %ecx, 0x4(%rax) movb $0x0, -0x1(%rbp) jmp 0xae352 movq -0x78(%rbp), %rax movl -0x2c(%rbp), %ecx shlq $0x4, %rcx addq %rcx, %rax movq %rax, -0x88(%rbp) movq -0x88(%rbp), %rdi movq -0x58(%rbp), %rsi movl -0x38(%rbp), %eax movl %eax, %edx callq 0xad480 movl %eax, -0x30(%rbp) movl -0x2c(%rbp), %eax cmpl -0x30(%rbp), %eax je 0xae2f0 movq -0x78(%rbp), %rax movq -0x50(%rbp), %rcx shlq $0x4, %rcx addq %rcx, %rax movq -0x88(%rbp), %rcx movq (%rcx), %rdx movq %rdx, (%rax) movq 0x8(%rcx), %rcx movq %rcx, 0x8(%rax) movq -0x78(%rbp), %rdi movl -0x2c(%rbp), %esi movl -0x30(%rbp), %edx movq -0x50(%rbp), %rax movl %eax, %ecx callq 0xadb20 movl $0xffffffff, -0x70(%rbp) # imm = 0xFFFFFFFF movq -0x78(%rbp), %rax movl -0x2c(%rbp), %ecx shlq $0x4, %rcx addq %rcx, %rax movq -0x70(%rbp), %rcx movq %rcx, (%rax) movq -0x68(%rbp), %rcx movq %rcx, 0x8(%rax) movl -0x5c(%rbp), %ecx movq -0x78(%rbp), %rax movl -0x2c(%rbp), %edx shlq $0x4, %rdx addq %rdx, %rax movl %ecx, 0x4(%rax) jmp 0xae34c movq -0x78(%rbp), %rax movl -0x2c(%rbp), %ecx shlq $0x4, %rcx addq %rcx, %rax movl (%rax), %eax movl %eax, -0x70(%rbp) movq -0x78(%rbp), %rax movq -0x50(%rbp), %rcx shlq $0x4, %rcx addq %rcx, %rax movq -0x70(%rbp), %rcx movq %rcx, (%rax) movq -0x68(%rbp), %rcx movq %rcx, 0x8(%rax) movl -0x5c(%rbp), %ecx movq -0x78(%rbp), %rax movq -0x50(%rbp), %rdx shlq $0x4, %rdx addq %rdx, %rax movl %ecx, 0x4(%rax) movq -0x50(%rbp), %rax movl %eax, %ecx movq -0x78(%rbp), %rax movl -0x2c(%rbp), %edx shlq $0x4, %rdx addq %rdx, %rax movl %ecx, (%rax) jmp 0xae34e movb $0x0, -0x1(%rbp) movb -0x1(%rbp), %al addq $0xc0, %rsp popq %rbp retq nop
my_hash_update: push rbp mov rbp, rsp sub rsp, 0C0h mov [rbp+var_10], rdi mov [rbp+var_18], rsi mov [rbp+var_20], rdx mov [rbp+var_28], rcx mov rdi, [rbp+var_10] mov rsi, [rbp+var_18] lea rdx, [rbp+var_48] mov ecx, 1 call my_hash_key mov [rbp+var_90], rax mov rax, [rbp+var_10] mov rax, [rax+58h] mov rcx, [rbp+var_10] mov rdi, [rcx+68h] mov rsi, [rbp+var_90] mov rdx, [rbp+var_48] call rax mov [rbp+var_5C], eax mov rax, [rbp+var_10] mov eax, [rax+20h] and eax, 1 cmp eax, 0 jz short loc_AE03A mov rdi, [rbp+var_10] mov esi, [rbp+var_5C] mov rdx, [rbp+var_90] mov rcx, [rbp+var_48] lea r8, [rbp+var_94] call my_hash_first_from_hash_value mov [rbp+var_A0], rax cmp rax, 0 jz short loc_AE038 jmp short $+2 loc_ADFF4: mov rax, [rbp+var_A0] cmp rax, [rbp+var_18] jz short loc_AE00C jmp short $+2 loc_AE003: mov [rbp+var_1], 1 jmp loc_AE352 loc_AE00C: jmp short $+2 loc_AE00E: mov rdi, [rbp+var_10] mov rsi, [rbp+var_90] mov rdx, [rbp+var_48] lea rcx, [rbp+var_94] call my_hash_next mov [rbp+var_A0], rax cmp rax, 0 jnz short loc_ADFF4 jmp short $+2 loc_AE038: jmp short $+2 loc_AE03A: mov rax, [rbp+var_10] mov rax, [rax+28h] mov [rbp+var_78], rax mov rax, [rbp+var_10] mov rax, [rax+10h] mov [rbp+var_58], rax mov rax, [rbp+var_10] mov rax, [rax+18h] mov [rbp+var_38], eax mov rax, [rbp+var_10] mov rax, [rax+58h] mov [rbp+var_B8], rax mov rax, [rbp+var_10] mov rax, [rax+68h] mov [rbp+var_B0], rax mov rax, [rbp+var_20] mov [rbp+var_A8], rax cmp [rbp+var_28], 0 jz short loc_AE09A mov rax, [rbp+var_28] mov [rbp+var_C0], rax jmp short loc_AE0A9 loc_AE09A: mov rax, [rbp+var_10] mov rax, [rax+8] mov [rbp+var_C0], rax loc_AE0A9: mov rax, [rbp+var_B8] mov rsi, [rbp+var_A8] mov rdi, [rbp+var_B0] mov rdx, [rbp+var_C0] call rax mov edi, eax mov rsi, [rbp+var_58] mov eax, [rbp+var_38] mov edx, eax call my_hash_mask mov [rbp+var_3C], eax mov eax, [rbp+var_3C] mov [rbp+var_34], eax mov edi, [rbp+var_5C] mov rsi, [rbp+var_58] mov eax, [rbp+var_38] mov edx, eax call my_hash_mask mov [rbp+var_2C], eax mov [rbp+var_80], 0 loc_AE0FC: mov rax, [rbp+var_78] mov ecx, [rbp+var_3C] shl rcx, 4 add rax, rcx mov [rbp+var_88], rax mov rax, [rax+8] cmp rax, [rbp+var_18] jnz short loc_AE11D jmp short loc_AE146 loc_AE11D: mov rax, [rbp+var_88] mov [rbp+var_80], rax mov rax, [rbp+var_88] mov eax, [rax] mov [rbp+var_3C], eax cmp eax, 0FFFFFFFFh jnz short loc_AE144 jmp short $+2 loc_AE13B: mov [rbp+var_1], 1 jmp loc_AE352 loc_AE144: jmp short loc_AE0FC loc_AE146: mov eax, [rbp+var_34] cmp eax, [rbp+var_2C] jnz short loc_AE16B mov ecx, [rbp+var_5C] mov rax, [rbp+var_78] mov edx, [rbp+var_3C] shl rdx, 4 add rax, rdx mov [rax+4], ecx mov [rbp+var_1], 0 jmp loc_AE352 loc_AE16B: mov rax, [rbp+var_88] mov rcx, [rax] mov [rbp+var_70], rcx mov rax, [rax+8] mov [rbp+var_68], rax mov eax, [rbp+var_3C] mov [rbp+var_50], rax cmp [rbp+var_80], 0 jnz short loc_AE1D3 mov rax, [rbp+var_88] cmp dword ptr [rax], 0FFFFFFFFh jz short loc_AE1D1 mov rax, [rbp+var_88] mov eax, [rax] mov [rbp+var_50], rax mov rax, [rbp+var_88] mov rcx, [rbp+var_78] mov rdx, [rbp+var_88] mov edx, [rdx] shl rdx, 4 add rcx, rdx mov rdx, [rcx] mov [rax], rdx mov rcx, [rcx+8] mov [rax+8], rcx loc_AE1D1: jmp short loc_AE1E2 loc_AE1D3: mov rax, [rbp+var_88] mov ecx, [rax] mov rax, [rbp+var_80] mov [rax], ecx loc_AE1E2: mov eax, [rbp+var_2C] cmp rax, [rbp+var_50] jnz short loc_AE248 mov rax, [rbp+var_50] mov ecx, [rbp+var_3C] cmp rax, rcx jz short loc_AE215 mov rax, [rbp+var_78] mov rcx, [rbp+var_50] shl rcx, 4 add rax, rcx mov rcx, [rbp+var_70] mov [rax], rcx mov rcx, [rbp+var_68] mov [rax+8], rcx loc_AE215: mov rax, [rbp+var_78] mov rcx, [rbp+var_50] shl rcx, 4 add rax, rcx mov dword ptr [rax], 0FFFFFFFFh mov ecx, [rbp+var_5C] mov rax, [rbp+var_78] mov rdx, [rbp+var_50] shl rdx, 4 add rax, rdx mov [rax+4], ecx mov [rbp+var_1], 0 jmp loc_AE352 loc_AE248: mov rax, [rbp+var_78] mov ecx, [rbp+var_2C] shl rcx, 4 add rax, rcx mov [rbp+var_88], rax mov rdi, [rbp+var_88] mov rsi, [rbp+var_58] mov eax, [rbp+var_38] mov edx, eax call my_hash_rec_mask mov [rbp+var_30], eax mov eax, [rbp+var_2C] cmp eax, [rbp+var_30] jz short loc_AE2F0 mov rax, [rbp+var_78] mov rcx, [rbp+var_50] shl rcx, 4 add rax, rcx mov rcx, [rbp+var_88] mov rdx, [rcx] mov [rax], rdx mov rcx, [rcx+8] mov [rax+8], rcx mov rdi, [rbp+var_78] mov esi, [rbp+var_2C] mov edx, [rbp+var_30] mov rax, [rbp+var_50] mov ecx, eax call movelink mov dword ptr [rbp+var_70], 0FFFFFFFFh mov rax, [rbp+var_78] mov ecx, [rbp+var_2C] shl rcx, 4 add rax, rcx mov rcx, [rbp+var_70] mov [rax], rcx mov rcx, [rbp+var_68] mov [rax+8], rcx mov ecx, [rbp+var_5C] mov rax, [rbp+var_78] mov edx, [rbp+var_2C] shl rdx, 4 add rax, rdx mov [rax+4], ecx jmp short loc_AE34C loc_AE2F0: mov rax, [rbp+var_78] mov ecx, [rbp+var_2C] shl rcx, 4 add rax, rcx mov eax, [rax] mov dword ptr [rbp+var_70], eax mov rax, [rbp+var_78] mov rcx, [rbp+var_50] shl rcx, 4 add rax, rcx mov rcx, [rbp+var_70] mov [rax], rcx mov rcx, [rbp+var_68] mov [rax+8], rcx mov ecx, [rbp+var_5C] mov rax, [rbp+var_78] mov rdx, [rbp+var_50] shl rdx, 4 add rax, rdx mov [rax+4], ecx mov rax, [rbp+var_50] mov ecx, eax mov rax, [rbp+var_78] mov edx, [rbp+var_2C] shl rdx, 4 add rax, rdx mov [rax], ecx loc_AE34C: jmp short $+2 loc_AE34E: mov [rbp+var_1], 0 loc_AE352: mov al, [rbp+var_1] add rsp, 0C0h pop rbp retn
char my_hash_update(_QWORD *a1, long long a2, long long a3, long long a4) { unsigned int v4; // eax unsigned int *v5; // rax _QWORD *v6; // rcx _QWORD *v7; // rax _QWORD *v8; // rax unsigned int *v9; // rcx _QWORD *v10; // rax _QWORD *v11; // rax long long ( *v13)(long long, long long, long long); // [rsp+8h] [rbp-B8h] long long v14; // [rsp+10h] [rbp-B0h] long long v15; // [rsp+20h] [rbp-A0h] unsigned int v16; // [rsp+2Ch] [rbp-94h] BYREF long long v17; // [rsp+30h] [rbp-90h] unsigned int *v18; // [rsp+38h] [rbp-88h] _DWORD *v19; // [rsp+40h] [rbp-80h] long long v20; // [rsp+48h] [rbp-78h] long long v21; // [rsp+50h] [rbp-70h] long long v22; // [rsp+58h] [rbp-68h] unsigned int v23; // [rsp+64h] [rbp-5Ch] unsigned long long v24; // [rsp+68h] [rbp-58h] long long v25; // [rsp+70h] [rbp-50h] long long v26; // [rsp+78h] [rbp-48h] BYREF unsigned int v27; // [rsp+84h] [rbp-3Ch] unsigned int v28; // [rsp+88h] [rbp-38h] unsigned int v29; // [rsp+8Ch] [rbp-34h] unsigned int v30; // [rsp+90h] [rbp-30h] unsigned int v31; // [rsp+94h] [rbp-2Ch] long long v32; // [rsp+98h] [rbp-28h] long long v33; // [rsp+A0h] [rbp-20h] long long v34; // [rsp+A8h] [rbp-18h] _QWORD *v35; // [rsp+B0h] [rbp-10h] v35 = a1; v34 = a2; v33 = a3; v32 = a4; v17 = my_hash_key((long long)a1, a2, &v26, 1); v23 = ((long long ( *)(_QWORD, long long, long long))v35[11])(v35[13], v17, v26); if ( (v35[4] & 1) != 0 && (v15 = my_hash_first_from_hash_value(v35, v23, v17, v26, &v16)) != 0 ) { while ( v15 == v34 ) { v15 = my_hash_next((long long)v35, v17, v26, &v16); if ( !v15 ) goto LABEL_6; } return 1; } else { LABEL_6: v20 = v35[5]; v24 = v35[2]; v28 = v35[3]; v13 = (long long ( *)(long long, long long, long long))v35[11]; v14 = v35[13]; if ( v32 ) v4 = v13(v14, v33, v32); else v4 = v13(v14, v33, v35[1]); v27 = my_hash_mask(v4, v24, v28); v29 = v27; v31 = my_hash_mask(v23, v24, v28); v19 = 0LL; while ( 1 ) { v18 = (unsigned int *)(16LL * v27 + v20); if ( *((_QWORD *)v18 + 1) == v34 ) break; v19 = v18; v27 = *v18; if ( v27 == -1 ) return 1; } if ( v29 == v31 ) { *(_DWORD *)(16LL * v27 + v20 + 4) = v23; return 0; } else { v21 = *(_QWORD *)v18; v22 = *((_QWORD *)v18 + 1); v25 = v27; if ( v19 ) { *v19 = *v18; } else if ( *v18 != -1 ) { v25 = *v18; v5 = v18; v6 = (_QWORD *)(16LL * *v18 + v20); *(_QWORD *)v18 = *v6; *((_QWORD *)v5 + 1) = v6[1]; } if ( v31 == v25 ) { if ( v25 != v27 ) { v7 = (_QWORD *)(16 * v25 + v20); *v7 = v21; v7[1] = v22; } *(_DWORD *)(16 * v25 + v20) = -1; *(_DWORD *)(16 * v25 + v20 + 4) = v23; return 0; } else { v18 = (unsigned int *)(16LL * v31 + v20); v30 = my_hash_rec_mask((long long)v18, v24, v28); if ( v31 == v30 ) { LODWORD(v21) = *(_DWORD *)(16LL * v31 + v20); v11 = (_QWORD *)(16 * v25 + v20); *v11 = v21; v11[1] = v22; *(_DWORD *)(16 * v25 + v20 + 4) = v23; *(_DWORD *)(16LL * v31 + v20) = v25; } else { v8 = (_QWORD *)(16 * v25 + v20); v9 = v18; *v8 = *(_QWORD *)v18; v8[1] = *((_QWORD *)v9 + 1); movelink(v20, v31, v30, v25); LODWORD(v21) = -1; v10 = (_QWORD *)(16LL * v31 + v20); *v10 = v21; v10[1] = v22; *(_DWORD *)(16LL * v31 + v20 + 4) = v23; } return 0; } } } }
my_hash_update: PUSH RBP MOV RBP,RSP SUB RSP,0xc0 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 RDI,qword ptr [RBP + -0x10] MOV RSI,qword ptr [RBP + -0x18] LEA RDX,[RBP + -0x48] MOV ECX,0x1 CALL 0x001adab0 MOV qword ptr [RBP + -0x90],RAX MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x58] MOV RCX,qword ptr [RBP + -0x10] MOV RDI,qword ptr [RCX + 0x68] MOV RSI,qword ptr [RBP + -0x90] MOV RDX,qword ptr [RBP + -0x48] CALL RAX MOV dword ptr [RBP + -0x5c],EAX MOV RAX,qword ptr [RBP + -0x10] MOV EAX,dword ptr [RAX + 0x20] AND EAX,0x1 CMP EAX,0x0 JZ 0x001ae03a MOV RDI,qword ptr [RBP + -0x10] MOV ESI,dword ptr [RBP + -0x5c] MOV RDX,qword ptr [RBP + -0x90] MOV RCX,qword ptr [RBP + -0x48] LEA R8,[RBP + -0x94] CALL 0x001ad290 MOV qword ptr [RBP + -0xa0],RAX CMP RAX,0x0 JZ 0x001ae038 JMP 0x001adff4 LAB_001adff4: MOV RAX,qword ptr [RBP + -0xa0] CMP RAX,qword ptr [RBP + -0x18] JZ 0x001ae00c JMP 0x001ae003 LAB_001ae003: MOV byte ptr [RBP + -0x1],0x1 JMP 0x001ae352 LAB_001ae00c: JMP 0x001ae00e LAB_001ae00e: MOV RDI,qword ptr [RBP + -0x10] MOV RSI,qword ptr [RBP + -0x90] MOV RDX,qword ptr [RBP + -0x48] LEA RCX,[RBP + -0x94] CALL 0x001ad4b0 MOV qword ptr [RBP + -0xa0],RAX CMP RAX,0x0 JNZ 0x001adff4 JMP 0x001ae038 LAB_001ae038: JMP 0x001ae03a LAB_001ae03a: MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x28] MOV qword ptr [RBP + -0x78],RAX MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x10] MOV qword ptr [RBP + -0x58],RAX MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x18] MOV dword ptr [RBP + -0x38],EAX MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x58] MOV qword ptr [RBP + -0xb8],RAX MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x68] MOV qword ptr [RBP + -0xb0],RAX MOV RAX,qword ptr [RBP + -0x20] MOV qword ptr [RBP + -0xa8],RAX CMP qword ptr [RBP + -0x28],0x0 JZ 0x001ae09a MOV RAX,qword ptr [RBP + -0x28] MOV qword ptr [RBP + -0xc0],RAX JMP 0x001ae0a9 LAB_001ae09a: MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x8] MOV qword ptr [RBP + -0xc0],RAX LAB_001ae0a9: MOV RAX,qword ptr [RBP + -0xb8] MOV RSI,qword ptr [RBP + -0xa8] MOV RDI,qword ptr [RBP + -0xb0] MOV RDX,qword ptr [RBP + -0xc0] CALL RAX MOV EDI,EAX MOV RSI,qword ptr [RBP + -0x58] MOV EAX,dword ptr [RBP + -0x38] MOV EDX,EAX CALL 0x001ad390 MOV dword ptr [RBP + -0x3c],EAX MOV EAX,dword ptr [RBP + -0x3c] MOV dword ptr [RBP + -0x34],EAX MOV EDI,dword ptr [RBP + -0x5c] MOV RSI,qword ptr [RBP + -0x58] MOV EAX,dword ptr [RBP + -0x38] MOV EDX,EAX CALL 0x001ad390 MOV dword ptr [RBP + -0x2c],EAX MOV qword ptr [RBP + -0x80],0x0 LAB_001ae0fc: MOV RAX,qword ptr [RBP + -0x78] MOV ECX,dword ptr [RBP + -0x3c] SHL RCX,0x4 ADD RAX,RCX MOV qword ptr [RBP + -0x88],RAX MOV RAX,qword ptr [RAX + 0x8] CMP RAX,qword ptr [RBP + -0x18] JNZ 0x001ae11d JMP 0x001ae146 LAB_001ae11d: MOV RAX,qword ptr [RBP + -0x88] MOV qword ptr [RBP + -0x80],RAX MOV RAX,qword ptr [RBP + -0x88] MOV EAX,dword ptr [RAX] MOV dword ptr [RBP + -0x3c],EAX CMP EAX,-0x1 JNZ 0x001ae144 JMP 0x001ae13b LAB_001ae13b: MOV byte ptr [RBP + -0x1],0x1 JMP 0x001ae352 LAB_001ae144: JMP 0x001ae0fc LAB_001ae146: MOV EAX,dword ptr [RBP + -0x34] CMP EAX,dword ptr [RBP + -0x2c] JNZ 0x001ae16b MOV ECX,dword ptr [RBP + -0x5c] MOV RAX,qword ptr [RBP + -0x78] MOV EDX,dword ptr [RBP + -0x3c] SHL RDX,0x4 ADD RAX,RDX MOV dword ptr [RAX + 0x4],ECX MOV byte ptr [RBP + -0x1],0x0 JMP 0x001ae352 LAB_001ae16b: MOV RAX,qword ptr [RBP + -0x88] MOV RCX,qword ptr [RAX] MOV qword ptr [RBP + -0x70],RCX MOV RAX,qword ptr [RAX + 0x8] MOV qword ptr [RBP + -0x68],RAX MOV EAX,dword ptr [RBP + -0x3c] MOV qword ptr [RBP + -0x50],RAX CMP qword ptr [RBP + -0x80],0x0 JNZ 0x001ae1d3 MOV RAX,qword ptr [RBP + -0x88] CMP dword ptr [RAX],-0x1 JZ 0x001ae1d1 MOV RAX,qword ptr [RBP + -0x88] MOV EAX,dword ptr [RAX] MOV qword ptr [RBP + -0x50],RAX MOV RAX,qword ptr [RBP + -0x88] MOV RCX,qword ptr [RBP + -0x78] MOV RDX,qword ptr [RBP + -0x88] MOV EDX,dword ptr [RDX] SHL RDX,0x4 ADD RCX,RDX MOV RDX,qword ptr [RCX] MOV qword ptr [RAX],RDX MOV RCX,qword ptr [RCX + 0x8] MOV qword ptr [RAX + 0x8],RCX LAB_001ae1d1: JMP 0x001ae1e2 LAB_001ae1d3: MOV RAX,qword ptr [RBP + -0x88] MOV ECX,dword ptr [RAX] MOV RAX,qword ptr [RBP + -0x80] MOV dword ptr [RAX],ECX LAB_001ae1e2: MOV EAX,dword ptr [RBP + -0x2c] CMP RAX,qword ptr [RBP + -0x50] JNZ 0x001ae248 MOV RAX,qword ptr [RBP + -0x50] MOV ECX,dword ptr [RBP + -0x3c] CMP RAX,RCX JZ 0x001ae215 MOV RAX,qword ptr [RBP + -0x78] MOV RCX,qword ptr [RBP + -0x50] SHL RCX,0x4 ADD RAX,RCX MOV RCX,qword ptr [RBP + -0x70] MOV qword ptr [RAX],RCX MOV RCX,qword ptr [RBP + -0x68] MOV qword ptr [RAX + 0x8],RCX LAB_001ae215: MOV RAX,qword ptr [RBP + -0x78] MOV RCX,qword ptr [RBP + -0x50] SHL RCX,0x4 ADD RAX,RCX MOV dword ptr [RAX],0xffffffff MOV ECX,dword ptr [RBP + -0x5c] MOV RAX,qword ptr [RBP + -0x78] MOV RDX,qword ptr [RBP + -0x50] SHL RDX,0x4 ADD RAX,RDX MOV dword ptr [RAX + 0x4],ECX MOV byte ptr [RBP + -0x1],0x0 JMP 0x001ae352 LAB_001ae248: MOV RAX,qword ptr [RBP + -0x78] MOV ECX,dword ptr [RBP + -0x2c] SHL RCX,0x4 ADD RAX,RCX MOV qword ptr [RBP + -0x88],RAX MOV RDI,qword ptr [RBP + -0x88] MOV RSI,qword ptr [RBP + -0x58] MOV EAX,dword ptr [RBP + -0x38] MOV EDX,EAX CALL 0x001ad480 MOV dword ptr [RBP + -0x30],EAX MOV EAX,dword ptr [RBP + -0x2c] CMP EAX,dword ptr [RBP + -0x30] JZ 0x001ae2f0 MOV RAX,qword ptr [RBP + -0x78] MOV RCX,qword ptr [RBP + -0x50] SHL RCX,0x4 ADD RAX,RCX MOV RCX,qword ptr [RBP + -0x88] MOV RDX,qword ptr [RCX] MOV qword ptr [RAX],RDX MOV RCX,qword ptr [RCX + 0x8] MOV qword ptr [RAX + 0x8],RCX MOV RDI,qword ptr [RBP + -0x78] MOV ESI,dword ptr [RBP + -0x2c] MOV EDX,dword ptr [RBP + -0x30] MOV RAX,qword ptr [RBP + -0x50] MOV ECX,EAX CALL 0x001adb20 MOV dword ptr [RBP + -0x70],0xffffffff MOV RAX,qword ptr [RBP + -0x78] MOV ECX,dword ptr [RBP + -0x2c] SHL RCX,0x4 ADD RAX,RCX MOV RCX,qword ptr [RBP + -0x70] MOV qword ptr [RAX],RCX MOV RCX,qword ptr [RBP + -0x68] MOV qword ptr [RAX + 0x8],RCX MOV ECX,dword ptr [RBP + -0x5c] MOV RAX,qword ptr [RBP + -0x78] MOV EDX,dword ptr [RBP + -0x2c] SHL RDX,0x4 ADD RAX,RDX MOV dword ptr [RAX + 0x4],ECX JMP 0x001ae34c LAB_001ae2f0: MOV RAX,qword ptr [RBP + -0x78] MOV ECX,dword ptr [RBP + -0x2c] SHL RCX,0x4 ADD RAX,RCX MOV EAX,dword ptr [RAX] MOV dword ptr [RBP + -0x70],EAX MOV RAX,qword ptr [RBP + -0x78] MOV RCX,qword ptr [RBP + -0x50] SHL RCX,0x4 ADD RAX,RCX MOV RCX,qword ptr [RBP + -0x70] MOV qword ptr [RAX],RCX MOV RCX,qword ptr [RBP + -0x68] MOV qword ptr [RAX + 0x8],RCX MOV ECX,dword ptr [RBP + -0x5c] MOV RAX,qword ptr [RBP + -0x78] MOV RDX,qword ptr [RBP + -0x50] SHL RDX,0x4 ADD RAX,RDX MOV dword ptr [RAX + 0x4],ECX MOV RAX,qword ptr [RBP + -0x50] MOV ECX,EAX MOV RAX,qword ptr [RBP + -0x78] MOV EDX,dword ptr [RBP + -0x2c] SHL RDX,0x4 ADD RAX,RDX MOV dword ptr [RAX],ECX LAB_001ae34c: JMP 0x001ae34e LAB_001ae34e: MOV byte ptr [RBP + -0x1],0x0 LAB_001ae352: MOV AL,byte ptr [RBP + -0x1] ADD RSP,0xc0 POP RBP RET
int1 my_hash_update(long param_1,long param_2,int8 param_3,long param_4) { int4 uVar1; long lVar2; uint *puVar3; int8 *puVar4; long local_c8; int1 local_9c [4]; int8 local_98; int8 *local_90; uint *local_88; long local_80; int8 local_78; int8 local_70; int4 local_64; int8 local_60; ulong local_58; int8 local_50; uint local_44; int4 local_40; uint local_3c; uint local_38; uint local_34; long local_30; int8 local_28; long local_20; long local_18; local_30 = param_4; local_28 = param_3; local_20 = param_2; local_18 = param_1; local_98 = my_hash_key(param_1,param_2,&local_50,1); local_64 = (**(code **)(local_18 + 0x58))(*(int8 *)(local_18 + 0x68),local_98,local_50); if ((*(uint *)(local_18 + 0x20) & 1) != 0) { lVar2 = my_hash_first_from_hash_value(local_18,local_64,local_98,local_50,local_9c); while (lVar2 != 0) { if (lVar2 != local_20) { return 1; } lVar2 = my_hash_next(local_18,local_98,local_50,local_9c); } } local_80 = *(long *)(local_18 + 0x28); local_60 = *(int8 *)(local_18 + 0x10); local_40 = (int4)*(int8 *)(local_18 + 0x18); if (local_30 == 0) { local_c8 = *(long *)(local_18 + 8); } else { local_c8 = local_30; } uVar1 = (**(code **)(local_18 + 0x58))(*(int8 *)(local_18 + 0x68),local_28,local_c8); local_44 = my_hash_mask(uVar1,local_60,local_40); local_3c = local_44; local_34 = my_hash_mask(local_64,local_60,local_40); local_88 = (uint *)0x0; while (puVar3 = (uint *)(local_80 + (ulong)local_44 * 0x10), *(long *)(puVar3 + 2) != local_20) { local_44 = *puVar3; local_88 = puVar3; if (local_44 == 0xffffffff) { return 1; } } if (local_3c == local_34) { *(int4 *)(local_80 + (ulong)local_44 * 0x10 + 4) = local_64; return 0; } local_78 = *(int8 *)puVar3; local_70 = *(int8 *)(puVar3 + 2); local_58 = (ulong)local_44; if (local_88 == (uint *)0x0) { if (*puVar3 != 0xffffffff) { local_58 = (ulong)*puVar3; puVar4 = (int8 *)(local_80 + (ulong)*puVar3 * 0x10); *(int8 *)puVar3 = *puVar4; *(int8 *)(puVar3 + 2) = puVar4[1]; } } else { *local_88 = *puVar3; } if (local_34 == local_58) { if (local_58 != local_44) { puVar4 = (int8 *)(local_80 + local_58 * 0x10); *puVar4 = local_78; puVar4[1] = local_70; } *(int4 *)(local_80 + local_58 * 0x10) = 0xffffffff; *(int4 *)(local_80 + local_58 * 0x10 + 4) = local_64; return 0; } local_90 = (int8 *)(local_80 + (ulong)local_34 * 0x10); local_38 = my_hash_rec_mask(local_90,local_60,local_40); if (local_34 == local_38) { local_78 = CONCAT44(local_78._4_4_,*(int4 *)(local_80 + (ulong)local_34 * 0x10)); puVar4 = (int8 *)(local_80 + local_58 * 0x10); *puVar4 = local_78; puVar4[1] = local_70; *(int4 *)(local_80 + local_58 * 0x10 + 4) = local_64; *(int *)(local_80 + (ulong)local_34 * 0x10) = (int)local_58; } else { puVar4 = (int8 *)(local_80 + local_58 * 0x10); *puVar4 = *local_90; puVar4[1] = local_90[1]; movelink(local_80,local_34,local_38,local_58 & 0xffffffff); local_78 = CONCAT44(local_78._4_4_,0xffffffff); puVar4 = (int8 *)(local_80 + (ulong)local_34 * 0x10); *puVar4 = local_78; puVar4[1] = local_70; *(int4 *)(local_80 + (ulong)local_34 * 0x10 + 4) = local_64; } return 0; }
6,019
MasterCommandHandler::handleStopCommand()
666mxvbee[P]BattleShip/lib/Commands/MasterCommandHandler.cpp
void MasterCommandHandler::handleStopCommand() { std::string res = settings_.stopGame(); if (res == "ok") { std::cout << "Master: Game stopped.\n"; } else { std::cout << "Master: " << res << "\n"; } saveSettingsToFile("../game_data/settings.txt", settings_); }
O0
cpp
MasterCommandHandler::handleStopCommand(): pushq %rbp movq %rsp, %rbp subq $0x90, %rsp movq %rdi, -0x8(%rbp) movq -0x8(%rbp), %rax movq %rax, -0x70(%rbp) movq (%rax), %rsi leaq -0x28(%rbp), %rdi movq %rdi, -0x68(%rbp) callq 0xa500 movq -0x68(%rbp), %rdi leaq 0x2cb3(%rip), %rsi # 0x40285 callq 0xb230 movb %al, -0x5a(%rbp) jmp 0x3d5dc movb -0x5a(%rbp), %al testb $0x1, %al jne 0x3d5e5 jmp 0x3d60d movq 0x209a4(%rip), %rdi # 0x5df90 leaq 0x43d6(%rip), %rsi # 0x419c9 callq 0x7380 jmp 0x3d5fa jmp 0x3d64d movq %rax, %rcx movl %edx, %eax movq %rcx, -0x30(%rbp) movl %eax, -0x34(%rbp) jmp 0x3d6d8 movq 0x2097c(%rip), %rdi # 0x5df90 leaq 0x43c5(%rip), %rsi # 0x419e0 callq 0x7380 movq %rax, -0x78(%rbp) jmp 0x3d626 movq -0x78(%rbp), %rdi leaq -0x28(%rbp), %rsi callq 0x7350 movq %rax, -0x80(%rbp) jmp 0x3d639 movq -0x80(%rbp), %rdi leaq 0x4339(%rip), %rsi # 0x4197d callq 0x7380 jmp 0x3d64b jmp 0x3d64d leaq -0x59(%rbp), %rdi movq %rdi, -0x88(%rbp) callq 0x7650 movq -0x88(%rbp), %rdx leaq 0x3fd6(%rip), %rsi # 0x41641 leaq -0x58(%rbp), %rdi callq 0xb110 jmp 0x3d676 movq -0x70(%rbp), %rax movq (%rax), %rsi leaq -0x58(%rbp), %rdi callq 0x3dfb0 jmp 0x3d688 leaq -0x58(%rbp), %rdi callq 0x7e50 leaq -0x59(%rbp), %rdi callq 0x73d0 leaq -0x28(%rbp), %rdi callq 0x7e50 addq $0x90, %rsp popq %rbp retq movq %rax, %rcx movl %edx, %eax movq %rcx, -0x30(%rbp) movl %eax, -0x34(%rbp) jmp 0x3d6cf movq %rax, %rcx movl %edx, %eax movq %rcx, -0x30(%rbp) movl %eax, -0x34(%rbp) leaq -0x58(%rbp), %rdi callq 0x7e50 leaq -0x59(%rbp), %rdi callq 0x73d0 leaq -0x28(%rbp), %rdi callq 0x7e50 movq -0x30(%rbp), %rdi callq 0x7640 nopw (%rax,%rax)
_ZN20MasterCommandHandler17handleStopCommandEv: push rbp mov rbp, rsp sub rsp, 90h mov [rbp+var_8], rdi mov rax, [rbp+var_8] mov [rbp+var_70], rax mov rsi, [rax] lea rdi, [rbp+var_28] mov [rbp+var_68], rdi call _ZN8Settings8stopGameB5cxx11Ev; Settings::stopGame(void) mov rdi, [rbp+var_68] lea rsi, aOk; "ok" call _ZSteqIcSt11char_traitsIcESaIcEEbRKNSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_; std::operator==<char>(std::string const&,char const*) mov [rbp+var_5A], al jmp short $+2 loc_3D5DC: mov al, [rbp+var_5A] test al, 1 jnz short loc_3D5E5 jmp short loc_3D60D loc_3D5E5: mov rdi, cs:_ZSt4cout_ptr lea rsi, aMasterGameStop; "Master: Game stopped.\n" call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*) jmp short $+2 loc_3D5FA: jmp short loc_3D64D mov rcx, rax mov eax, edx mov [rbp+var_30], rcx mov [rbp+var_34], eax jmp loc_3D6D8 loc_3D60D: mov rdi, cs:_ZSt4cout_ptr lea rsi, aMaster_0; "Master: " call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*) mov [rbp+var_78], rax jmp short $+2 loc_3D626: mov rdi, [rbp+var_78] lea rsi, [rbp+var_28] call __ZStlsIcSt11char_traitsIcESaIcEERSt13basic_ostreamIT_T0_ES7_RKNSt7__cxx1112basic_stringIS4_S5_T1_EE; std::operator<<<char>(std::ostream &,std::string const&) mov [rbp+var_80], rax jmp short $+2 loc_3D639: mov rdi, [rbp+var_80] lea rsi, aMasterSlaveShi+28h; "\n" call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*) jmp short $+2 loc_3D64B: jmp short $+2 loc_3D64D: lea rdi, [rbp+var_59] mov [rbp+var_88], rdi call __ZNSaIcEC1Ev; std::allocator<char>::allocator(void) mov rdx, [rbp+var_88] lea rsi, aGameDataSettin; "../game_data/settings.txt" lea rdi, [rbp+var_58] call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&) jmp short $+2 loc_3D676: mov rax, [rbp+var_70] mov rsi, [rax] lea rdi, [rbp+var_58] call _Z18saveSettingsToFileRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERK8Settings; saveSettingsToFile(std::string const&,Settings const&) jmp short $+2 loc_3D688: lea rdi, [rbp+var_58] call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() lea rdi, [rbp+var_59] call __ZNSaIcED1Ev; std::allocator<char>::~allocator() lea rdi, [rbp+var_28] call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() add rsp, 90h pop rbp retn mov rcx, rax mov eax, edx mov [rbp+var_30], rcx mov [rbp+var_34], eax jmp short loc_3D6CF mov rcx, rax mov eax, edx mov [rbp+var_30], rcx mov [rbp+var_34], eax lea rdi, [rbp+var_58] call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() loc_3D6CF: lea rdi, [rbp+var_59] call __ZNSaIcED1Ev; std::allocator<char>::~allocator() loc_3D6D8: lea rdi, [rbp+var_28] call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() mov rdi, [rbp+var_30] call __Unwind_Resume
long long MasterCommandHandler::handleStopCommand(MasterCommandHandler *this) { long long v2; // [rsp+10h] [rbp-80h] long long v3; // [rsp+18h] [rbp-78h] char v4; // [rsp+37h] [rbp-59h] BYREF _QWORD v5[4]; // [rsp+38h] [rbp-58h] BYREF _BYTE v6[32]; // [rsp+68h] [rbp-28h] BYREF MasterCommandHandler *v7; // [rsp+88h] [rbp-8h] v7 = this; Settings::stopGame[abi:cxx11]((long long)v6, *(_QWORD *)this); if ( std::operator==<char>((long long)v6, (long long)"ok") ) { std::operator<<<std::char_traits<char>>(&std::cout, "Master: Game stopped.\n"); } else { v3 = std::operator<<<std::char_traits<char>>(&std::cout, "Master: "); v2 = std::operator<<<char>(v3, v6); std::operator<<<std::char_traits<char>>(v2, "\n"); } std::allocator<char>::allocator(); std::string::basic_string<std::allocator<char>>(v5, (long long)"../game_data/settings.txt", (long long)&v4); saveSettingsToFile(v5, *(_QWORD *)this); std::string::~string((long long)v5); std::allocator<char>::~allocator(&v4); return std::string::~string((long long)v6); }
handleStopCommand: PUSH RBP MOV RBP,RSP SUB RSP,0x90 MOV qword ptr [RBP + -0x8],RDI MOV RAX,qword ptr [RBP + -0x8] MOV qword ptr [RBP + -0x70],RAX MOV RSI,qword ptr [RAX] LEA RDI,[RBP + -0x28] MOV qword ptr [RBP + -0x68],RDI CALL 0x0010a500 MOV RDI,qword ptr [RBP + -0x68] LAB_0013d5cb: LEA RSI,[0x140285] CALL 0x0010b230 MOV byte ptr [RBP + -0x5a],AL JMP 0x0013d5dc LAB_0013d5dc: MOV AL,byte ptr [RBP + -0x5a] TEST AL,0x1 JNZ 0x0013d5e5 JMP 0x0013d60d LAB_0013d5e5: MOV RDI,qword ptr [0x0015df90] LEA RSI,[0x1419c9] CALL 0x00107380 JMP 0x0013d5fa LAB_0013d5fa: JMP 0x0013d64d LAB_0013d60d: MOV RDI,qword ptr [0x0015df90] LEA RSI,[0x1419e0] CALL 0x00107380 MOV qword ptr [RBP + -0x78],RAX JMP 0x0013d626 LAB_0013d626: MOV RDI,qword ptr [RBP + -0x78] LEA RSI,[RBP + -0x28] CALL 0x00107350 MOV qword ptr [RBP + -0x80],RAX JMP 0x0013d639 LAB_0013d639: MOV RDI,qword ptr [RBP + -0x80] LEA RSI,[0x14197d] CALL 0x00107380 JMP 0x0013d64b LAB_0013d64b: JMP 0x0013d64d LAB_0013d64d: LEA RDI,[RBP + -0x59] MOV qword ptr [RBP + -0x88],RDI CALL 0x00107650 MOV RDX,qword ptr [RBP + -0x88] LAB_0013d664: LEA RSI,[0x141641] LEA RDI,[RBP + -0x58] CALL 0x0010b110 JMP 0x0013d676 LAB_0013d676: MOV RAX,qword ptr [RBP + -0x70] MOV RSI,qword ptr [RAX] LAB_0013d67d: LEA RDI,[RBP + -0x58] CALL 0x0013dfb0 LAB_0013d686: JMP 0x0013d688 LAB_0013d688: LEA RDI,[RBP + -0x58] CALL 0x00107e50 LEA RDI,[RBP + -0x59] CALL 0x001073d0 LEA RDI,[RBP + -0x28] CALL 0x00107e50 ADD RSP,0x90 POP RBP RET
/* MasterCommandHandler::handleStopCommand() */ void __thiscall MasterCommandHandler::handleStopCommand(MasterCommandHandler *this) { bool bVar1; ostream *poVar2; allocator local_61; string local_60 [48]; string local_30 [32]; MasterCommandHandler *local_10; local_10 = this; Settings::stopGame_abi_cxx11_(); /* try { // try from 0013d5cb to 0013d648 has its CatchHandler @ 0013d5fc */ bVar1 = std::operator==(local_30,"ok"); if (bVar1) { std::operator<<((ostream *)PTR_cout_0015df90,"Master: Game stopped.\n"); } else { poVar2 = std::operator<<((ostream *)PTR_cout_0015df90,"Master: "); poVar2 = std::operator<<(poVar2,local_30); std::operator<<(poVar2,"\n"); } std::allocator<char>::allocator(); /* try { // try from 0013d664 to 0013d673 has its CatchHandler @ 0013d6ac */ std::__cxx11::string::string<std::allocator<char>>(local_60,"../game_data/settings.txt",&local_61) ; /* try { // try from 0013d67d to 0013d685 has its CatchHandler @ 0013d6ba */ saveSettingsToFile(local_60,*(Settings **)this); std::__cxx11::string::~string(local_60); std::allocator<char>::~allocator((allocator<char> *)&local_61); std::__cxx11::string::~string(local_30); return; }
6,020
MasterCommandHandler::handleStopCommand()
666mxvbee[P]BattleShip/lib/Commands/MasterCommandHandler.cpp
void MasterCommandHandler::handleStopCommand() { std::string res = settings_.stopGame(); if (res == "ok") { std::cout << "Master: Game stopped.\n"; } else { std::cout << "Master: " << res << "\n"; } saveSettingsToFile("../game_data/settings.txt", settings_); }
O2
cpp
MasterCommandHandler::handleStopCommand(): pushq %r14 pushq %rbx subq $0x48, %rsp movq %rdi, %rbx movq (%rdi), %rsi leaq 0x28(%rsp), %r14 movq %r14, %rdi callq 0x64f8 leaq 0x1962(%rip), %rsi # 0x17205 movq %r14, %rdi callq 0x6a6d testb %al, %al je 0x158bf leaq 0x3091(%rip), %rsi # 0x18947 movq 0xf6db(%rip), %rdi # 0x24f98 jmp 0x158e9 movq 0xf6d2(%rip), %rdi # 0x24f98 leaq 0x3091(%rip), %rsi # 0x1895e callq 0x5360 leaq 0x28(%rsp), %rsi movq %rax, %rdi callq 0x5330 movq %rax, %rdi leaq 0x3012(%rip), %rsi # 0x188fb callq 0x5360 leaq 0x2cca(%rip), %rsi # 0x185bf leaq 0x8(%rsp), %rdi leaq 0x7(%rsp), %rdx callq 0x6a32 movq (%rbx), %rsi leaq 0x8(%rsp), %rdi callq 0x15c10 leaq 0x8(%rsp), %rdi callq 0x5ac8 leaq 0x28(%rsp), %rdi callq 0x5ac8 addq $0x48, %rsp popq %rbx popq %r14 retq movq %rax, %rbx leaq 0x8(%rsp), %rdi callq 0x5ac8 jmp 0x15941 jmp 0x1593e movq %rax, %rbx leaq 0x28(%rsp), %rdi callq 0x5ac8 movq %rbx, %rdi callq 0x55b0 nop
_ZN20MasterCommandHandler17handleStopCommandEv: push r14 push rbx sub rsp, 48h mov rbx, rdi mov rsi, [rdi] lea r14, [rsp+58h+var_30] mov rdi, r14 call _ZN8Settings8stopGameB5cxx11Ev; Settings::stopGame(void) lea rsi, aOk; "ok" mov rdi, r14 call _ZSteqIcSt11char_traitsIcESaIcEEbRKNSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_; std::operator==<char>(std::string const&,char const*) test al, al jz short loc_158BF lea rsi, aMasterGameStop; "Master: Game stopped.\n" mov rdi, cs:_ZSt4cout_ptr jmp short loc_158E9 loc_158BF: mov rdi, cs:_ZSt4cout_ptr lea rsi, aMaster_0; "Master: " call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*) lea rsi, [rsp+58h+var_30] mov rdi, rax call __ZStlsIcSt11char_traitsIcESaIcEERSt13basic_ostreamIT_T0_ES7_RKNSt7__cxx1112basic_stringIS4_S5_T1_EE; std::operator<<<char>(std::ostream &,std::string const&) mov rdi, rax lea rsi, aMasterSlaveShi+28h; "\n" loc_158E9: call __ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc; std::operator<<<std::char_traits<char>>(std::ostream &,char const*) lea rsi, aGameDataSettin; "../game_data/settings.txt" lea rdi, [rsp+58h+var_50] lea rdx, [rsp+58h+var_51] call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&) mov rsi, [rbx] lea rdi, [rsp+58h+var_50] call _Z18saveSettingsToFileRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERK8Settings; saveSettingsToFile(std::string const&,Settings const&) lea rdi, [rsp+58h+var_50] call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() lea rdi, [rsp+58h+var_30] call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() add rsp, 48h pop rbx pop r14 retn mov rbx, rax lea rdi, [rsp+arg_0] call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() jmp short loc_15941 jmp short $+2 loc_1593E: mov rbx, rax loc_15941: lea rdi, [rsp+arg_20] call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() mov rdi, rbx call __Unwind_Resume
long long MasterCommandHandler::handleStopCommand(std::mutex **this) { char *v2; // rsi void *v3; // rdi long long v4; // rax int v5; // edx int v6; // ecx int v7; // r8d int v8; // r9d long long result; // rax _QWORD v10[4]; // [rsp+8h] [rbp-50h] BYREF _BYTE v11[48]; // [rsp+28h] [rbp-30h] BYREF Settings::stopGame[abi:cxx11]((long long)v11, *this); if ( std::operator==<char>((long long)v11) ) { v2 = "Master: Game stopped.\n"; v3 = &std::cout; } else { v4 = std::operator<<<std::char_traits<char>>(&std::cout, "Master: "); v3 = (void *)std::operator<<<char>(v4, v11); v2 = "\n"; } std::operator<<<std::char_traits<char>>(v3, v2); std::string::basic_string<std::allocator<char>>(v10, "../game_data/settings.txt"); result = saveSettingsToFile((unsigned int)v10, (unsigned int)*this, v5, v6, v7, v8); std::string::~string(); std::string::~string(); return result; }
handleStopCommand: PUSH R14 PUSH RBX SUB RSP,0x48 MOV RBX,RDI MOV RSI,qword ptr [RDI] LEA R14,[RSP + 0x28] MOV RDI,R14 CALL 0x001064f8 LEA RSI,[0x117205] MOV RDI,R14 CALL 0x00106a6d TEST AL,AL JZ 0x001158bf LEA RSI,[0x118947] MOV RDI,qword ptr [0x00124f98] JMP 0x001158e9 LAB_001158bf: MOV RDI,qword ptr [0x00124f98] LEA RSI,[0x11895e] CALL 0x00105360 LEA RSI,[RSP + 0x28] MOV RDI,RAX CALL 0x00105330 MOV RDI,RAX LEA RSI,[0x1188fb] LAB_001158e9: CALL 0x00105360 LAB_001158ee: LEA RSI,[0x1185bf] LEA RDI,[RSP + 0x8] LEA RDX,[RSP + 0x7] CALL 0x00106a32 MOV RSI,qword ptr [RBX] LAB_00115907: LEA RDI,[RSP + 0x8] CALL 0x00115c10 LAB_00115911: LEA RDI,[RSP + 0x8] CALL 0x00105ac8 LEA RDI,[RSP + 0x28] CALL 0x00105ac8 ADD RSP,0x48 POP RBX POP R14 RET
/* MasterCommandHandler::handleStopCommand() */ void __thiscall MasterCommandHandler::handleStopCommand(MasterCommandHandler *this) { bool bVar1; ostream *poVar2; char *pcVar3; allocator local_51; string local_50 [32]; string local_30 [32]; Settings::stopGame_abi_cxx11_(); bVar1 = std::operator==(local_30,"ok"); if (bVar1) { pcVar3 = "Master: Game stopped.\n"; poVar2 = (ostream *)PTR_cout_00124f98; } else { /* try { // try from 001158bf to 001158ed has its CatchHandler @ 0011593e */ poVar2 = std::operator<<((ostream *)PTR_cout_00124f98,"Master: "); poVar2 = std::operator<<(poVar2,local_30); pcVar3 = "\n"; } std::operator<<(poVar2,pcVar3); /* try { // try from 001158ee to 00115903 has its CatchHandler @ 0011593c */ std::__cxx11::string::string<std::allocator<char>>(local_50,"../game_data/settings.txt",&local_51) ; /* try { // try from 00115907 to 00115910 has its CatchHandler @ 0011592d */ saveSettingsToFile(local_50,*(Settings **)this); std::__cxx11::string::~string(local_50); std::__cxx11::string::~string(local_30); return; }
6,021
MasterCommandHandler::handleStopCommand()
666mxvbee[P]BattleShip/lib/Commands/MasterCommandHandler.cpp
void MasterCommandHandler::handleStopCommand() { std::string res = settings_.stopGame(); if (res == "ok") { std::cout << "Master: Game stopped.\n"; } else { std::cout << "Master: " << res << "\n"; } saveSettingsToFile("../game_data/settings.txt", settings_); }
O3
cpp
MasterCommandHandler::handleStopCommand(): pushq %r14 pushq %rbx subq $0x48, %rsp movq %rdi, %rbx movq (%rdi), %rsi leaq 0x28(%rsp), %r14 movq %r14, %rdi callq 0x6c2c leaq 0x20c2(%rip), %rsi # 0x1a205 movq %r14, %rdi callq 0x7410 testl %eax, %eax je 0x1818e movq 0xce4a(%rip), %rdi # 0x24fa0 leaq 0x381e(%rip), %rsi # 0x1b97b movl $0x8, %edx callq 0x5420 movq 0x28(%rsp), %rsi movq 0x30(%rsp), %rdx movq 0xce28(%rip), %rdi # 0x24fa0 callq 0x5420 movq %rax, %rdi movl $0x1, %edx leaq 0x378c(%rip), %rsi # 0x1b918 jmp 0x181a1 movl $0x16, %edx leaq 0x37ca(%rip), %rsi # 0x1b964 movq 0xcdff(%rip), %rdi # 0x24fa0 callq 0x5420 leaq 0x18(%rsp), %r14 movq %r14, -0x10(%r14) leaq 0x3426(%rip), %rsi # 0x1b5dc leaq 0x3438(%rip), %rdx # 0x1b5f5 leaq 0x8(%rsp), %rdi callq 0x5fea movq (%rbx), %rsi leaq 0x8(%rsp), %rdi callq 0x1857c movq 0x8(%rsp), %rdi cmpq %r14, %rdi je 0x181eb movq 0x18(%rsp), %rsi incq %rsi callq 0x53a0 leaq 0x38(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0x18206 movq 0x38(%rsp), %rsi incq %rsi callq 0x53a0 addq $0x48, %rsp popq %rbx popq %r14 retq movq %rax, %rbx movq 0x8(%rsp), %rdi cmpq %r14, %rdi je 0x1822f movq 0x18(%rsp), %rsi incq %rsi callq 0x53a0 jmp 0x1822f jmp 0x1822c movq %rax, %rbx leaq 0x38(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0x1824a movq 0x38(%rsp), %rsi incq %rsi callq 0x53a0 movq %rbx, %rdi callq 0x5600
_ZN20MasterCommandHandler17handleStopCommandEv: push r14 push rbx sub rsp, 48h mov rbx, rdi mov rsi, [rdi] lea r14, [rsp+58h+var_30] mov rdi, r14 call _ZN8Settings8stopGameB5cxx11Ev; Settings::stopGame(void) lea rsi, aOk; "ok" mov rdi, r14 call _ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE7compareEPKc; std::string::compare(char const*) test eax, eax jz short loc_1818E mov rdi, cs:_ZSt4cout_ptr lea rsi, aMaster_0; "Master: " mov edx, 8 call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long) mov rsi, [rsp+58h+var_30] mov rdx, [rsp+58h+var_28] mov rdi, cs:_ZSt4cout_ptr call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long) mov rdi, rax mov edx, 1 lea rsi, aMasterSlaveShi+28h; "\n" jmp short loc_181A1 loc_1818E: mov edx, 16h lea rsi, aMasterGameStop; "Master: Game stopped.\n" mov rdi, cs:_ZSt4cout_ptr loc_181A1: call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long) lea r14, [rsp+58h+var_40] mov [r14-10h], r14 lea rsi, aGameDataSettin; "../game_data/settings.txt" lea rdx, aGameDataSettin+19h; "" lea rdi, [rsp+58h+var_50] 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 rsi, [rbx] lea rdi, [rsp+58h+var_50] call _Z18saveSettingsToFileRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERK8Settings; saveSettingsToFile(std::string const&,Settings const&) mov rdi, [rsp+58h+var_50]; void * cmp rdi, r14 jz short loc_181EB mov rsi, [rsp+58h+var_40] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_181EB: lea rax, [rsp+58h+var_20] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_18206 mov rsi, [rsp+58h+var_20] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_18206: add rsp, 48h pop rbx pop r14 retn mov rbx, rax mov rdi, [rsp+arg_0]; void * cmp rdi, r14 jz short loc_1822F mov rsi, [rsp+arg_10] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) jmp short loc_1822F jmp short $+2 loc_1822C: mov rbx, rax loc_1822F: lea rax, [rsp+arg_30] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_1824A mov rsi, [rsp+arg_30] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_1824A: mov rdi, rbx call __Unwind_Resume
void MasterCommandHandler::handleStopCommand(MasterCommandHandler *this) { _QWORD *v2; // rdi long long v3; // rdx char *v4; // rsi void *v5[2]; // [rsp+8h] [rbp-50h] BYREF _QWORD v6[2]; // [rsp+18h] [rbp-40h] BYREF void *v7[2]; // [rsp+28h] [rbp-30h] BYREF long long v8; // [rsp+38h] [rbp-20h] BYREF Settings::stopGame[abi:cxx11](v7, *(_QWORD *)this); if ( !(unsigned int)std::string::compare(v7, (long long)"ok") ) { v3 = 22LL; v4 = "Master: Game stopped.\n"; v2 = &std::cout; } else { std::__ostream_insert<char,std::char_traits<char>>(&std::cout, "Master: ", 8LL); v2 = (_QWORD *)std::__ostream_insert<char,std::char_traits<char>>(&std::cout, v7[0], v7[1]); v3 = 1LL; v4 = "\n"; } std::__ostream_insert<char,std::char_traits<char>>(v2, v4, v3); v5[0] = v6; std::string::_M_construct<char const*>((long long)v5, "../game_data/settings.txt", (long long)""); saveSettingsToFile(v5, *(_QWORD *)this); if ( v5[0] != v6 ) operator delete(v5[0], v6[0] + 1LL); if ( v7[0] != &v8 ) operator delete(v7[0], v8 + 1); }
handleStopCommand: PUSH R14 PUSH RBX SUB RSP,0x48 MOV RBX,RDI MOV RSI,qword ptr [RDI] LEA R14,[RSP + 0x28] MOV RDI,R14 CALL 0x00106c2c LEA RSI,[0x11a205] MOV RDI,R14 CALL 0x00107410 TEST EAX,EAX JZ 0x0011818e LAB_0011814f: MOV RDI,qword ptr [0x00124fa0] LEA RSI,[0x11b97b] MOV EDX,0x8 CALL 0x00105420 MOV RSI,qword ptr [RSP + 0x28] MOV RDX,qword ptr [RSP + 0x30] MOV RDI,qword ptr [0x00124fa0] CALL 0x00105420 MOV RDI,RAX MOV EDX,0x1 LEA RSI,[0x11b918] JMP 0x001181a1 LAB_0011818e: MOV EDX,0x16 LEA RSI,[0x11b964] MOV RDI,qword ptr [0x00124fa0] LAB_001181a1: CALL 0x00105420 LEA R14,[RSP + 0x18] MOV qword ptr [R14 + -0x10],R14 LAB_001181af: LEA RSI,[0x11b5dc] LEA RDX,[0x11b5f5] LEA RDI,[RSP + 0x8] CALL 0x00105fea MOV RSI,qword ptr [RBX] LAB_001181ca: LEA RDI,[RSP + 0x8] CALL 0x0011857c LAB_001181d4: MOV RDI,qword ptr [RSP + 0x8] CMP RDI,R14 JZ 0x001181eb MOV RSI,qword ptr [RSP + 0x18] INC RSI CALL 0x001053a0 LAB_001181eb: LEA RAX,[RSP + 0x38] MOV RDI,qword ptr [RAX + -0x10] CMP RDI,RAX JZ 0x00118206 MOV RSI,qword ptr [RSP + 0x38] INC RSI CALL 0x001053a0 LAB_00118206: ADD RSP,0x48 POP RBX POP R14 RET
/* MasterCommandHandler::handleStopCommand() */ void __thiscall MasterCommandHandler::handleStopCommand(MasterCommandHandler *this) { int iVar1; ostream *poVar2; long lVar3; char *pcVar4; long *local_50 [2]; long local_40 [2]; long *local_30; long local_28; long local_20 [2]; Settings::stopGame_abi_cxx11_(); iVar1 = std::__cxx11::string::compare((string *)&local_30,"ok"); if (iVar1 == 0) { lVar3 = 0x16; pcVar4 = "Master: Game stopped.\n"; poVar2 = (ostream *)PTR_cout_00124fa0; } else { /* try { // try from 0011814f to 001181a5 has its CatchHandler @ 0011822c */ std::__ostream_insert<char,std::char_traits<char>>((ostream *)PTR_cout_00124fa0,"Master: ",8); poVar2 = std::__ostream_insert<char,std::char_traits<char>> ((ostream *)PTR_cout_00124fa0,(char *)local_30,local_28); lVar3 = 1; pcVar4 = "\n"; } std::__ostream_insert<char,std::char_traits<char>>(poVar2,pcVar4,lVar3); /* try { // try from 001181af to 001181c6 has its CatchHandler @ 0011822a */ local_50[0] = local_40; std::__cxx11::string::_M_construct<char_const*>(local_50,"../game_data/settings.txt",""); /* try { // try from 001181ca to 001181d3 has its CatchHandler @ 0011820e */ saveSettingsToFile((string *)local_50,*(Settings **)this); if (local_50[0] != local_40) { operator_delete(local_50[0],local_40[0] + 1); } if (local_30 != local_20) { operator_delete(local_30,local_20[0] + 1); } return; }
6,022
insert_events_transactions_history_long(PFS_events_transactions*)
eloqsql/storage/perfschema/pfs_events_transactions.cc
void insert_events_transactions_history_long(PFS_events_transactions *transaction) { if (unlikely(events_transactions_history_long_size == 0)) return ; assert(events_transactions_history_long_array != NULL); uint index= PFS_atomic::add_u32(&events_transactions_history_long_index.m_u32, 1); index= index % events_transactions_history_long_size; if (index == 0) events_transactions_history_long_full= true; /* See related comment in insert_events_transactions_history. */ copy_events_transactions(&events_transactions_history_long_array[index], transaction); }
O0
cpp
insert_events_transactions_history_long(PFS_events_transactions*): pushq %rbp movq %rsp, %rbp subq $0x10, %rsp movq %rdi, -0x8(%rbp) cmpq $0x0, 0x3d6f0c(%rip) # 0x40bd00 sete %al andb $0x1, %al movzbl %al, %eax cmpl $0x0, %eax je 0x34e03 jmp 0x34e54 leaq 0x3d7036(%rip), %rdi # 0x40be40 movl $0x1, %esi callq 0x2d580 movl %eax, -0xc(%rbp) movl -0xc(%rbp), %eax xorl %ecx, %ecx movl %ecx, %edx divq 0x3d6edb(%rip) # 0x40bd00 movl %edx, %eax movl %eax, -0xc(%rbp) cmpl $0x0, -0xc(%rbp) jne 0x34e37 movb $0x1, 0x3d6fc9(%rip) # 0x40be00 movq 0x3d7042(%rip), %rdi # 0x40be80 movl -0xc(%rbp), %eax imulq $0x140, %rax, %rax # imm = 0x140 addq %rax, %rdi movq -0x8(%rbp), %rsi callq 0x34db0 addq $0x10, %rsp popq %rbp retq nopw (%rax,%rax)
_Z39insert_events_transactions_history_longP23PFS_events_transactions: push rbp mov rbp, rsp sub rsp, 10h mov [rbp+var_8], rdi cmp cs:events_transactions_history_long_size, 0 setz al and al, 1 movzx eax, al cmp eax, 0 jz short loc_34E03 jmp short loc_34E54 loc_34E03: lea rdi, events_transactions_history_long_index; this mov esi, (offset dword_0+1); unsigned int * call _ZN10PFS_atomic7add_u32EPjj; PFS_atomic::add_u32(uint *,uint) mov [rbp+var_C], eax mov eax, [rbp+var_C] xor ecx, ecx mov edx, ecx div cs:events_transactions_history_long_size mov eax, edx mov [rbp+var_C], eax cmp [rbp+var_C], 0 jnz short loc_34E37 mov cs:events_transactions_history_long_full, 1 loc_34E37: mov rdi, cs:events_transactions_history_long_array mov eax, [rbp+var_C] imul rax, 140h add rdi, rax mov rsi, [rbp+var_8] call _ZL24copy_events_transactionsP23PFS_events_transactionsPKS_; copy_events_transactions(PFS_events_transactions *,PFS_events_transactions const*) loc_34E54: add rsp, 10h pop rbp retn
long long insert_events_transactions_history_long(PFS_events_transactions *a1) { long long result; // rax unsigned int v2; // [rsp+4h] [rbp-Ch] result = events_transactions_history_long_size == 0; if ( events_transactions_history_long_size ) { v2 = (unsigned int)PFS_atomic::add_u32( (PFS_atomic *)&events_transactions_history_long_index, (unsigned int *)((char *)&dword_0 + 1)) % events_transactions_history_long_size; if ( !v2 ) events_transactions_history_long_full = 1; return copy_events_transactions( (PFS_events_transactions *)(320LL * v2 + events_transactions_history_long_array), a1); } return result; }
insert_events_transactions_history_long: PUSH RBP MOV RBP,RSP SUB RSP,0x10 MOV qword ptr [RBP + -0x8],RDI CMP qword ptr [0x0050bd00],0x0 SETZ AL AND AL,0x1 MOVZX EAX,AL CMP EAX,0x0 JZ 0x00134e03 JMP 0x00134e54 LAB_00134e03: LEA RDI,[0x50be40] MOV ESI,0x1 CALL 0x0012d580 MOV dword ptr [RBP + -0xc],EAX MOV EAX,dword ptr [RBP + -0xc] XOR ECX,ECX MOV EDX,ECX DIV qword ptr [0x0050bd00] MOV EAX,EDX MOV dword ptr [RBP + -0xc],EAX CMP dword ptr [RBP + -0xc],0x0 JNZ 0x00134e37 MOV byte ptr [0x0050be00],0x1 LAB_00134e37: MOV RDI,qword ptr [0x0050be80] MOV EAX,dword ptr [RBP + -0xc] IMUL RAX,RAX,0x140 ADD RDI,RAX MOV RSI,qword ptr [RBP + -0x8] CALL 0x00134db0 LAB_00134e54: ADD RSP,0x10 POP RBP RET
/* insert_events_transactions_history_long(PFS_events_transactions*) */ void insert_events_transactions_history_long(PFS_events_transactions *param_1) { uint uVar1; if (events_transactions_history_long_size != 0) { uVar1 = PFS_atomic::add_u32((uint *)events_transactions_history_long_index,1); if ((int)((ulong)uVar1 % events_transactions_history_long_size) == 0) { events_transactions_history_long_full = 1; } copy_events_transactions ((PFS_events_transactions *) (events_transactions_history_long_array + ((ulong)uVar1 % events_transactions_history_long_size & 0xffffffff) * 0x140),param_1) ; } return; }
6,023
my_uca_context_weight_find
eloqsql/strings/ctype-uca.c
static inline const MY_CONTRACTION * my_uca_context_weight_find(my_uca_scanner *scanner, my_wc_t *wc, size_t max_char_length) { const MY_CONTRACTION *cnt; DBUG_ASSERT(scanner->level->contractions.nitems); /* If we have scanned a character which can have previous context, and there were some more characters already before, then reconstruct codepoint of the previous character from "page" and "code" into w[1], and verify that {wc[1], wc[0]} together form a real previous context pair. Note, we support only 2-character long sequences with previous context at the moment. CLDR does not have longer sequences. */ if (my_uca_can_be_previous_context_tail(&scanner->level->contractions, wc[0]) && scanner->wbeg != nochar && /* if not the very first character */ my_uca_can_be_previous_context_head(&scanner->level->contractions, (wc[1]= ((scanner->page << 8) + scanner->code))) && (cnt= my_uca_previous_context_find(scanner, wc[1], wc[0]))) { scanner->page= scanner->code= 0; /* Clear for the next character */ return cnt; } else if (my_uca_can_be_contraction_head(&scanner->level->contractions, wc[0])) { /* Check if w[0] starts a contraction */ if ((cnt= my_uca_scanner_contraction_find(scanner, wc, max_char_length))) return cnt; } return NULL; }
O0
c
my_uca_context_weight_find: pushq %rbp movq %rsp, %rbp subq $0x30, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq %rdx, -0x20(%rbp) jmp 0xaf846 movq -0x10(%rbp), %rax movq 0x18(%rax), %rdi addq $0x18, %rdi movq -0x18(%rbp), %rax movq (%rax), %rsi callq 0xaf9f0 movsbl %al, %eax cmpl $0x0, %eax je 0xaf8f1 movq -0x10(%rbp), %rax leaq 0x169dcb(%rip), %rcx # 0x219640 cmpq %rcx, (%rax) je 0xaf8f1 movq -0x10(%rbp), %rax movq 0x18(%rax), %rdi addq $0x18, %rdi movq -0x10(%rbp), %rax movl 0x24(%rax), %eax shll $0x8, %eax movq -0x10(%rbp), %rcx addl 0x28(%rcx), %eax movslq %eax, %rsi movq -0x18(%rbp), %rax movq %rsi, 0x8(%rax) callq 0xafa20 movsbl %al, %eax cmpl $0x0, %eax je 0xaf8f1 movq -0x10(%rbp), %rdi movq -0x18(%rbp), %rax movq 0x8(%rax), %rsi movq -0x18(%rbp), %rax movq (%rax), %rdx callq 0xafa50 movq %rax, -0x28(%rbp) cmpq $0x0, %rax je 0xaf8f1 movq -0x10(%rbp), %rax movl $0x0, 0x28(%rax) movq -0x10(%rbp), %rax movl $0x0, 0x24(%rax) movq -0x28(%rbp), %rax movq %rax, -0x8(%rbp) jmp 0xaf93e movq -0x10(%rbp), %rax movq 0x18(%rax), %rdi addq $0x18, %rdi movq -0x18(%rbp), %rax movq (%rax), %rsi callq 0xa6e60 cmpb $0x0, %al je 0xaf934 movq -0x10(%rbp), %rdi movq -0x18(%rbp), %rsi movq -0x20(%rbp), %rdx callq 0xafb00 movq %rax, -0x28(%rbp) cmpq $0x0, %rax je 0xaf932 movq -0x28(%rbp), %rax movq %rax, -0x8(%rbp) jmp 0xaf93e jmp 0xaf934 jmp 0xaf936 movq $0x0, -0x8(%rbp) movq -0x8(%rbp), %rax addq $0x30, %rsp popq %rbp retq nopl (%rax,%rax)
my_uca_context_weight_find: push rbp mov rbp, rsp sub rsp, 30h mov [rbp+var_10], rdi mov [rbp+var_18], rsi mov [rbp+var_20], rdx jmp short $+2 loc_AF846: mov rax, [rbp+var_10] mov rdi, [rax+18h] add rdi, 18h mov rax, [rbp+var_18] mov rsi, [rax] call my_uca_can_be_previous_context_tail movsx eax, al cmp eax, 0 jz loc_AF8F1 mov rax, [rbp+var_10] lea rcx, nochar cmp [rax], rcx jz short loc_AF8F1 mov rax, [rbp+var_10] mov rdi, [rax+18h] add rdi, 18h mov rax, [rbp+var_10] mov eax, [rax+24h] shl eax, 8 mov rcx, [rbp+var_10] add eax, [rcx+28h] movsxd rsi, eax mov rax, [rbp+var_18] mov [rax+8], rsi call my_uca_can_be_previous_context_head movsx eax, al cmp eax, 0 jz short loc_AF8F1 mov rdi, [rbp+var_10] mov rax, [rbp+var_18] mov rsi, [rax+8] mov rax, [rbp+var_18] mov rdx, [rax] call my_uca_previous_context_find mov [rbp+var_28], rax cmp rax, 0 jz short loc_AF8F1 mov rax, [rbp+var_10] mov dword ptr [rax+28h], 0 mov rax, [rbp+var_10] mov dword ptr [rax+24h], 0 mov rax, [rbp+var_28] mov [rbp+var_8], rax jmp short loc_AF93E loc_AF8F1: mov rax, [rbp+var_10] mov rdi, [rax+18h] add rdi, 18h mov rax, [rbp+var_18] mov rsi, [rax] call my_uca_can_be_contraction_head cmp al, 0 jz short loc_AF934 mov rdi, [rbp+var_10] mov rsi, [rbp+var_18] mov rdx, [rbp+var_20] call my_uca_scanner_contraction_find mov [rbp+var_28], rax cmp rax, 0 jz short loc_AF932 mov rax, [rbp+var_28] mov [rbp+var_8], rax jmp short loc_AF93E loc_AF932: jmp short $+2 loc_AF934: jmp short $+2 loc_AF936: mov [rbp+var_8], 0 loc_AF93E: mov rax, [rbp+var_8] add rsp, 30h pop rbp retn
long long my_uca_context_weight_find(long long a1, _QWORD *a2, long long a3) { long long v3; // rdi long long v5; // [rsp+8h] [rbp-28h] long long v6; // [rsp+8h] [rbp-28h] if ( (unsigned __int8)my_uca_can_be_previous_context_tail(*(_QWORD *)(a1 + 24) + 24LL, *a2) && *(_UNKNOWN **)a1 != &nochar && (v3 = *(_QWORD *)(a1 + 24) + 24LL, a2[1] = *(_DWORD *)(a1 + 40) + (*(_DWORD *)(a1 + 36) << 8), (unsigned __int8)my_uca_can_be_previous_context_head(v3)) && (v5 = my_uca_previous_context_find(a1, a2[1], *a2)) != 0 ) { *(_DWORD *)(a1 + 40) = 0; *(_DWORD *)(a1 + 36) = 0; return v5; } else if ( (unsigned __int8)my_uca_can_be_contraction_head(*(_QWORD *)(a1 + 24) + 24LL, *a2) && (v6 = my_uca_scanner_contraction_find(a1, a2, a3)) != 0 ) { return v6; } else { return 0LL; } }
my_uca_context_weight_find: PUSH RBP MOV RBP,RSP SUB RSP,0x30 MOV qword ptr [RBP + -0x10],RDI MOV qword ptr [RBP + -0x18],RSI MOV qword ptr [RBP + -0x20],RDX JMP 0x001af846 LAB_001af846: MOV RAX,qword ptr [RBP + -0x10] MOV RDI,qword ptr [RAX + 0x18] ADD RDI,0x18 MOV RAX,qword ptr [RBP + -0x18] MOV RSI,qword ptr [RAX] CALL 0x001af9f0 MOVSX EAX,AL CMP EAX,0x0 JZ 0x001af8f1 MOV RAX,qword ptr [RBP + -0x10] LEA RCX,[0x319640] CMP qword ptr [RAX],RCX JZ 0x001af8f1 MOV RAX,qword ptr [RBP + -0x10] MOV RDI,qword ptr [RAX + 0x18] ADD RDI,0x18 MOV RAX,qword ptr [RBP + -0x10] MOV EAX,dword ptr [RAX + 0x24] SHL EAX,0x8 MOV RCX,qword ptr [RBP + -0x10] ADD EAX,dword ptr [RCX + 0x28] MOVSXD RSI,EAX MOV RAX,qword ptr [RBP + -0x18] MOV qword ptr [RAX + 0x8],RSI CALL 0x001afa20 MOVSX EAX,AL CMP EAX,0x0 JZ 0x001af8f1 MOV RDI,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RBP + -0x18] MOV RSI,qword ptr [RAX + 0x8] MOV RAX,qword ptr [RBP + -0x18] MOV RDX,qword ptr [RAX] CALL 0x001afa50 MOV qword ptr [RBP + -0x28],RAX CMP RAX,0x0 JZ 0x001af8f1 MOV RAX,qword ptr [RBP + -0x10] MOV dword ptr [RAX + 0x28],0x0 MOV RAX,qword ptr [RBP + -0x10] MOV dword ptr [RAX + 0x24],0x0 MOV RAX,qword ptr [RBP + -0x28] MOV qword ptr [RBP + -0x8],RAX JMP 0x001af93e LAB_001af8f1: MOV RAX,qword ptr [RBP + -0x10] MOV RDI,qword ptr [RAX + 0x18] ADD RDI,0x18 MOV RAX,qword ptr [RBP + -0x18] MOV RSI,qword ptr [RAX] CALL 0x001a6e60 CMP AL,0x0 JZ 0x001af934 MOV RDI,qword ptr [RBP + -0x10] MOV RSI,qword ptr [RBP + -0x18] MOV RDX,qword ptr [RBP + -0x20] CALL 0x001afb00 MOV qword ptr [RBP + -0x28],RAX CMP RAX,0x0 JZ 0x001af932 MOV RAX,qword ptr [RBP + -0x28] MOV qword ptr [RBP + -0x8],RAX JMP 0x001af93e LAB_001af932: JMP 0x001af934 LAB_001af934: JMP 0x001af936 LAB_001af936: MOV qword ptr [RBP + -0x8],0x0 LAB_001af93e: MOV RAX,qword ptr [RBP + -0x8] ADD RSP,0x30 POP RBP RET
long my_uca_context_weight_find(int8 *param_1,int8 *param_2,int8 param_3) { char cVar1; long lVar2; long local_10; cVar1 = my_uca_can_be_previous_context_tail(param_1[3] + 0x18,*param_2); if ((cVar1 != '\0') && ((int4 *)*param_1 != &nochar)) { lVar2 = param_1[3]; param_2[1] = (long)(*(int *)((long)param_1 + 0x24) * 0x100 + *(int *)(param_1 + 5)); cVar1 = my_uca_can_be_previous_context_head(lVar2 + 0x18); if ((cVar1 != '\0') && (lVar2 = my_uca_previous_context_find(param_1,param_2[1],*param_2), lVar2 != 0)) { *(int4 *)(param_1 + 5) = 0; *(int4 *)((long)param_1 + 0x24) = 0; return lVar2; } } cVar1 = my_uca_can_be_contraction_head(param_1[3] + 0x18,*param_2); if ((cVar1 == '\0') || (local_10 = my_uca_scanner_contraction_find(param_1,param_2,param_3), local_10 == 0)) { local_10 = 0; } return local_10; }
6,024
OpenSubdiv::v3_6_0::Vtr::internal::Refinement::printParentToChildMapping() const
NVIDIA-RTX[P]OSD-Lite/opensubdiv/vtr/refinement.cpp
void Refinement::printParentToChildMapping() const { printf("Parent-to-child component mapping:\n"); for (Index pFace = 0; pFace < _parent->getNumFaces(); ++pFace) { printf(" Face %d:\n", pFace); printf(" Child vert: %d\n", _faceChildVertIndex[pFace]); printf(" Child faces: "); ConstIndexArray childFaces = getFaceChildFaces(pFace); for (int i = 0; i < childFaces.size(); ++i) { printf(" %d", childFaces[i]); } printf("\n"); printf(" Child edges: "); ConstIndexArray childEdges = getFaceChildEdges(pFace); for (int i = 0; i < childEdges.size(); ++i) { printf(" %d", childEdges[i]); } printf("\n"); } for (Index pEdge = 0; pEdge < _parent->getNumEdges(); ++pEdge) { printf(" Edge %d:\n", pEdge); printf(" Child vert: %d\n", _edgeChildVertIndex[pEdge]); ConstIndexArray childEdges = getEdgeChildEdges(pEdge); printf(" Child edges: %d %d\n", childEdges[0], childEdges[1]); } for (Index pVert = 0; pVert < _parent->getNumVertices(); ++pVert) { printf(" Vert %d:\n", pVert); printf(" Child vert: %d\n", _vertChildVertIndex[pVert]); } }
O0
cpp
OpenSubdiv::v3_6_0::Vtr::internal::Refinement::printParentToChildMapping() const: pushq %rbp movq %rsp, %rbp subq $0xc0, %rsp movq %rdi, -0x8(%rbp) movq -0x8(%rbp), %rax movq %rax, -0x90(%rbp) leaq 0xece26(%rip), %rdi # 0x1ebd97 movb $0x0, %al callq 0xc34f0 movl $0x0, -0xc(%rbp) movq -0x90(%rbp), %rax movl -0xc(%rbp), %ecx movl %ecx, -0x94(%rbp) movq 0x8(%rax), %rdi callq 0xc3430 movl %eax, %ecx movl -0x94(%rbp), %eax cmpl %ecx, %eax jge 0xff121 movl -0xc(%rbp), %esi leaq 0xece09(%rip), %rdi # 0x1ebdbb xorl %eax, %eax movb %al, -0x95(%rbp) callq 0xc34f0 movq -0x90(%rbp), %rdi addq $0xa8, %rdi movslq -0xc(%rbp), %rsi callq 0xd09b0 movq %rax, %rcx movb -0x95(%rbp), %al movl (%rcx), %esi leaq 0xecddf(%rip), %rdi # 0x1ebdc7 callq 0xc34f0 movb -0x95(%rbp), %al leaq 0xecde2(%rip), %rdi # 0x1ebddc callq 0xc34f0 movq -0x90(%rbp), %rdi movl -0xc(%rbp), %esi callq 0xd27d0 movl %edx, -0x28(%rbp) movq %rax, -0x30(%rbp) movq -0x30(%rbp), %rax movq %rax, -0x20(%rbp) movl -0x28(%rbp), %eax movl %eax, -0x18(%rbp) movl $0x0, -0x34(%rbp) movl -0x34(%rbp), %eax movl %eax, -0x9c(%rbp) leaq -0x20(%rbp), %rdi callq 0xcc250 movl %eax, %ecx movl -0x9c(%rbp), %eax cmpl %ecx, %eax jge 0xff06f movl -0x34(%rbp), %esi leaq -0x20(%rbp), %rdi callq 0xcabf0 movl (%rax), %esi leaq 0xfc332(%rip), %rdi # 0x1fb38f movb $0x0, %al callq 0xc34f0 movl -0x34(%rbp), %eax addl $0x1, %eax movl %eax, -0x34(%rbp) jmp 0xff02a leaq 0xeb21d(%rip), %rdi # 0x1ea293 xorl %eax, %eax movb %al, -0x9d(%rbp) callq 0xc34f0 movb -0x9d(%rbp), %al leaq 0xecd5e(%rip), %rdi # 0x1ebdee callq 0xc34f0 movq -0x90(%rbp), %rdi movl -0xc(%rbp), %esi callq 0xc7170 movl %edx, -0x50(%rbp) movq %rax, -0x58(%rbp) movq -0x58(%rbp), %rax movq %rax, -0x48(%rbp) movl -0x50(%rbp), %eax movl %eax, -0x40(%rbp) movl $0x0, -0x5c(%rbp) movl -0x5c(%rbp), %eax movl %eax, -0xa4(%rbp) leaq -0x48(%rbp), %rdi callq 0xcc250 movl %eax, %ecx movl -0xa4(%rbp), %eax cmpl %ecx, %eax jge 0xff105 movl -0x5c(%rbp), %esi leaq -0x48(%rbp), %rdi callq 0xcabf0 movl (%rax), %esi leaq 0xfc29c(%rip), %rdi # 0x1fb38f movb $0x0, %al callq 0xc34f0 movl -0x5c(%rbp), %eax addl $0x1, %eax movl %eax, -0x5c(%rbp) jmp 0xff0c0 leaq 0xeb187(%rip), %rdi # 0x1ea293 movb $0x0, %al callq 0xc34f0 movl -0xc(%rbp), %eax addl $0x1, %eax movl %eax, -0xc(%rbp) jmp 0xfef7f movl $0x0, -0x60(%rbp) movq -0x90(%rbp), %rax movl -0x60(%rbp), %ecx movl %ecx, -0xa8(%rbp) movq 0x8(%rax), %rdi callq 0xca130 movl %eax, %ecx movl -0xa8(%rbp), %eax cmpl %ecx, %eax jge 0xff1ff movl -0x60(%rbp), %esi leaq 0xecca5(%rip), %rdi # 0x1ebe00 xorl %eax, %eax movb %al, -0xad(%rbp) callq 0xc34f0 movq -0x90(%rbp), %rdi addq $0xd8, %rdi movslq -0x60(%rbp), %rsi callq 0xd09b0 movq %rax, %rcx movb -0xad(%rbp), %al movl (%rcx), %esi leaq 0xecc36(%rip), %rdi # 0x1ebdc7 callq 0xc34f0 movq -0x90(%rbp), %rdi movl -0x60(%rbp), %esi callq 0xcf7d0 movl %edx, -0x78(%rbp) movq %rax, -0x80(%rbp) movq -0x80(%rbp), %rax movq %rax, -0x70(%rbp) movl -0x78(%rbp), %eax movl %eax, -0x68(%rbp) leaq -0x70(%rbp), %rdi xorl %esi, %esi callq 0xcabf0 movl (%rax), %eax movl %eax, -0xac(%rbp) leaq -0x70(%rbp), %rdi movl $0x1, %esi callq 0xcabf0 movl -0xac(%rbp), %esi movl (%rax), %edx leaq 0xecc22(%rip), %rdi # 0x1ebe0c movb $0x0, %al callq 0xc34f0 movl -0x60(%rbp), %eax addl $0x1, %eax movl %eax, -0x60(%rbp) jmp 0xff128 movl $0x0, -0x84(%rbp) movq -0x90(%rbp), %rax movl -0x84(%rbp), %ecx movl %ecx, -0xb4(%rbp) movq 0x8(%rax), %rdi callq 0xc8fe0 movl %eax, %ecx movl -0xb4(%rbp), %eax cmpl %ecx, %eax jge 0xff280 movl -0x84(%rbp), %esi leaq 0xecbe6(%rip), %rdi # 0x1ebe24 movb $0x0, %al callq 0xc34f0 movq -0x90(%rbp), %rdi addq $0xf0, %rdi movslq -0x84(%rbp), %rsi callq 0xd09b0 movl (%rax), %esi leaq 0xecb5f(%rip), %rdi # 0x1ebdc7 movb $0x0, %al callq 0xc34f0 movl -0x84(%rbp), %eax addl $0x1, %eax movl %eax, -0x84(%rbp) jmp 0xff209 addq $0xc0, %rsp popq %rbp retq nopl (%rax)
_ZNK10OpenSubdiv6v3_6_03Vtr8internal10Refinement25printParentToChildMappingEv: push rbp mov rbp, rsp sub rsp, 0C0h mov [rbp+var_8], rdi mov rax, [rbp+var_8] mov [rbp+var_90], rax lea rdi, aParentToChildC; "Parent-to-child component mapping:\n" mov al, 0 call _printf mov [rbp+var_C], 0 loc_FEF7F: mov rax, [rbp+var_90] mov ecx, [rbp+var_C] mov [rbp+var_94], ecx mov rdi, [rax+8]; this call __ZNK10OpenSubdiv6v3_6_03Vtr8internal5Level11getNumFacesEv; OpenSubdiv::v3_6_0::Vtr::internal::Level::getNumFaces(void) mov ecx, eax mov eax, [rbp+var_94] cmp eax, ecx jge loc_FF121 mov esi, [rbp+var_C] lea rdi, aFaceD; " Face %d:\n" xor eax, eax mov [rbp+var_95], al call _printf mov rdi, [rbp+var_90] add rdi, 0A8h movsxd rsi, [rbp+var_C] call __ZNKSt6vectorIiSaIiEEixEm; std::vector<int>::operator[](ulong) mov rcx, rax mov al, [rbp+var_95] mov esi, [rcx] lea rdi, aChildVertD; " Child vert: %d\n" call _printf mov al, [rbp+var_95] lea rdi, aChildFaces; " Child faces: " call _printf mov rdi, [rbp+var_90]; this mov esi, [rbp+var_C]; int call __ZNK10OpenSubdiv6v3_6_03Vtr8internal10Refinement17getFaceChildFacesEi; OpenSubdiv::v3_6_0::Vtr::internal::Refinement::getFaceChildFaces(int) mov [rbp+var_28], edx mov [rbp+var_30], rax mov rax, [rbp+var_30] mov [rbp+var_20], rax mov eax, [rbp+var_28] mov [rbp+var_18], eax mov [rbp+var_34], 0 loc_FF02A: mov eax, [rbp+var_34] mov [rbp+var_9C], eax lea rdi, [rbp+var_20] call __ZNK10OpenSubdiv6v3_6_03Vtr10ConstArrayIiE4sizeEv; OpenSubdiv::v3_6_0::Vtr::ConstArray<int>::size(void) mov ecx, eax mov eax, [rbp+var_9C] cmp eax, ecx jge short loc_FF06F mov esi, [rbp+var_34] lea rdi, [rbp+var_20] call __ZNK10OpenSubdiv6v3_6_03Vtr10ConstArrayIiEixEi; OpenSubdiv::v3_6_0::Vtr::ConstArray<int>::operator[](int) mov esi, [rax] lea rdi, aInnerRateSD+19h; " %d" mov al, 0 call _printf mov eax, [rbp+var_34] add eax, 1 mov [rbp+var_34], eax jmp short loc_FF02A loc_FF06F: lea rdi, aErrorValueMism+4Dh; "\n" xor eax, eax mov [rbp+var_9D], al call _printf mov al, [rbp+var_9D] lea rdi, aChildEdges; " Child edges: " call _printf mov rdi, [rbp+var_90]; this mov esi, [rbp+var_C]; int call __ZNK10OpenSubdiv6v3_6_03Vtr8internal10Refinement17getFaceChildEdgesEi; OpenSubdiv::v3_6_0::Vtr::internal::Refinement::getFaceChildEdges(int) mov [rbp+var_50], edx mov [rbp+var_58], rax mov rax, [rbp+var_58] mov [rbp+var_48], rax mov eax, [rbp+var_50] mov [rbp+var_40], eax mov [rbp+var_5C], 0 loc_FF0C0: mov eax, [rbp+var_5C] mov [rbp+var_A4], eax lea rdi, [rbp+var_48] call __ZNK10OpenSubdiv6v3_6_03Vtr10ConstArrayIiE4sizeEv; OpenSubdiv::v3_6_0::Vtr::ConstArray<int>::size(void) mov ecx, eax mov eax, [rbp+var_A4] cmp eax, ecx jge short loc_FF105 mov esi, [rbp+var_5C] lea rdi, [rbp+var_48] call __ZNK10OpenSubdiv6v3_6_03Vtr10ConstArrayIiEixEi; OpenSubdiv::v3_6_0::Vtr::ConstArray<int>::operator[](int) mov esi, [rax] lea rdi, aInnerRateSD+19h; " %d" mov al, 0 call _printf mov eax, [rbp+var_5C] add eax, 1 mov [rbp+var_5C], eax jmp short loc_FF0C0 loc_FF105: lea rdi, aErrorValueMism+4Dh; "\n" mov al, 0 call _printf mov eax, [rbp+var_C] add eax, 1 mov [rbp+var_C], eax jmp loc_FEF7F loc_FF121: mov [rbp+var_60], 0 loc_FF128: mov rax, [rbp+var_90] mov ecx, [rbp+var_60] mov [rbp+var_A8], ecx mov rdi, [rax+8]; this call __ZNK10OpenSubdiv6v3_6_03Vtr8internal5Level11getNumEdgesEv; OpenSubdiv::v3_6_0::Vtr::internal::Level::getNumEdges(void) mov ecx, eax mov eax, [rbp+var_A8] cmp eax, ecx jge loc_FF1FF mov esi, [rbp+var_60] lea rdi, aEdgeD; " Edge %d:\n" xor eax, eax mov [rbp+var_AD], al call _printf mov rdi, [rbp+var_90] add rdi, 0D8h movsxd rsi, [rbp+var_60] call __ZNKSt6vectorIiSaIiEEixEm; std::vector<int>::operator[](ulong) mov rcx, rax mov al, [rbp+var_AD] mov esi, [rcx] lea rdi, aChildVertD; " Child vert: %d\n" call _printf mov rdi, [rbp+var_90]; this mov esi, [rbp+var_60]; int call __ZNK10OpenSubdiv6v3_6_03Vtr8internal10Refinement17getEdgeChildEdgesEi; OpenSubdiv::v3_6_0::Vtr::internal::Refinement::getEdgeChildEdges(int) mov [rbp+var_78], edx mov [rbp+var_80], rax mov rax, [rbp+var_80] mov [rbp+var_70], rax mov eax, [rbp+var_78] mov [rbp+var_68], eax lea rdi, [rbp+var_70] xor esi, esi call __ZNK10OpenSubdiv6v3_6_03Vtr10ConstArrayIiEixEi; OpenSubdiv::v3_6_0::Vtr::ConstArray<int>::operator[](int) mov eax, [rax] mov [rbp+var_AC], eax lea rdi, [rbp+var_70] mov esi, 1 call __ZNK10OpenSubdiv6v3_6_03Vtr10ConstArrayIiEixEi; OpenSubdiv::v3_6_0::Vtr::ConstArray<int>::operator[](int) mov esi, [rbp+var_AC] mov edx, [rax] lea rdi, aChildEdgesDD; " Child edges: %d %d\n" mov al, 0 call _printf mov eax, [rbp+var_60] add eax, 1 mov [rbp+var_60], eax jmp loc_FF128 loc_FF1FF: mov [rbp+var_84], 0 loc_FF209: mov rax, [rbp+var_90] mov ecx, [rbp+var_84] mov [rbp+var_B4], ecx mov rdi, [rax+8]; this call __ZNK10OpenSubdiv6v3_6_03Vtr8internal5Level14getNumVerticesEv; OpenSubdiv::v3_6_0::Vtr::internal::Level::getNumVertices(void) mov ecx, eax mov eax, [rbp+var_B4] cmp eax, ecx jge short loc_FF280 mov esi, [rbp+var_84] lea rdi, aVertD; " Vert %d:\n" mov al, 0 call _printf mov rdi, [rbp+var_90] add rdi, 0F0h movsxd rsi, [rbp+var_84] call __ZNKSt6vectorIiSaIiEEixEm; std::vector<int>::operator[](ulong) mov esi, [rax] lea rdi, aChildVertD; " Child vert: %d\n" mov al, 0 call _printf mov eax, [rbp+var_84] add eax, 1 mov [rbp+var_84], eax jmp short loc_FF209 loc_FF280: add rsp, 0C0h pop rbp retn
long long OpenSubdiv::v3_6_0::Vtr::internal::Refinement::printParentToChildMapping( OpenSubdiv::v3_6_0::Vtr::internal::Level **this) { _DWORD *v1; // rax long long FaceChildFaces; // rax int v3; // edx _DWORD *v4; // rax long long FaceChildEdges; // rax int v6; // edx _DWORD *v7; // rax _DWORD *v8; // rax int v9; // edx _DWORD *v10; // rax int NumVertices; // ecx long long result; // rax _DWORD *v13; // rax int v14; // [rsp+14h] [rbp-ACh] int v15; // [rsp+18h] [rbp-A8h] int v16; // [rsp+24h] [rbp-9Ch] int v17; // [rsp+2Ch] [rbp-94h] unsigned int n; // [rsp+3Ch] [rbp-84h] long long EdgeChildEdges; // [rsp+50h] [rbp-70h] BYREF int v20; // [rsp+58h] [rbp-68h] int m; // [rsp+60h] [rbp-60h] int k; // [rsp+64h] [rbp-5Ch] long long v23; // [rsp+68h] [rbp-58h] int v24; // [rsp+70h] [rbp-50h] long long v25; // [rsp+78h] [rbp-48h] BYREF int v26; // [rsp+80h] [rbp-40h] unsigned int j; // [rsp+8Ch] [rbp-34h] long long v28; // [rsp+90h] [rbp-30h] int v29; // [rsp+98h] [rbp-28h] long long v30; // [rsp+A0h] [rbp-20h] BYREF int v31; // [rsp+A8h] [rbp-18h] int i; // [rsp+B4h] [rbp-Ch] OpenSubdiv::v3_6_0::Vtr::internal::Level **v33; // [rsp+B8h] [rbp-8h] v33 = this; printf("Parent-to-child component mapping:\n"); for ( i = 0; ; ++i ) { v17 = i; if ( v17 >= (int)OpenSubdiv::v3_6_0::Vtr::internal::Level::getNumFaces(this[1]) ) break; printf(" Face %d:\n", i); v1 = (_DWORD *)std::vector<int>::operator[](this + 21, i); printf(" Child vert: %d\n", *v1); printf(" Child faces: "); FaceChildFaces = OpenSubdiv::v3_6_0::Vtr::internal::Refinement::getFaceChildFaces( (OpenSubdiv::v3_6_0::Vtr::internal::Refinement *)this, i); v29 = v3; v28 = FaceChildFaces; v30 = FaceChildFaces; v31 = v3; for ( j = 0; ; ++j ) { v16 = j; if ( v16 >= (int)OpenSubdiv::v3_6_0::Vtr::ConstArray<int>::size(&v30) ) break; v4 = (_DWORD *)OpenSubdiv::v3_6_0::Vtr::ConstArray<int>::operator[](&v30, j); printf(" %d", *v4); } printf("\n"); printf(" Child edges: "); FaceChildEdges = OpenSubdiv::v3_6_0::Vtr::internal::Refinement::getFaceChildEdges( (OpenSubdiv::v3_6_0::Vtr::internal::Refinement *)this, i); v24 = v6; v23 = FaceChildEdges; v25 = FaceChildEdges; v26 = v6; for ( k = 0; k < (int)OpenSubdiv::v3_6_0::Vtr::ConstArray<int>::size(&v25); ++k ) { v7 = (_DWORD *)OpenSubdiv::v3_6_0::Vtr::ConstArray<int>::operator[](&v25, (unsigned int)k); printf(" %d", *v7); } printf("\n"); } for ( m = 0; ; ++m ) { v15 = m; if ( v15 >= (int)OpenSubdiv::v3_6_0::Vtr::internal::Level::getNumEdges(this[1]) ) break; printf(" Edge %d:\n", m); v8 = (_DWORD *)std::vector<int>::operator[](this + 27, m); printf(" Child vert: %d\n", *v8); EdgeChildEdges = OpenSubdiv::v3_6_0::Vtr::internal::Refinement::getEdgeChildEdges( (OpenSubdiv::v3_6_0::Vtr::internal::Refinement *)this, m); v20 = v9; v14 = *(_DWORD *)OpenSubdiv::v3_6_0::Vtr::ConstArray<int>::operator[](&EdgeChildEdges, 0LL); v10 = (_DWORD *)OpenSubdiv::v3_6_0::Vtr::ConstArray<int>::operator[](&EdgeChildEdges, 1LL); printf(" Child edges: %d %d\n", v14, *v10); } for ( n = 0; ; ++n ) { NumVertices = OpenSubdiv::v3_6_0::Vtr::internal::Level::getNumVertices(this[1]); result = n; if ( (int)n >= NumVertices ) break; printf(" Vert %d:\n", n); v13 = (_DWORD *)std::vector<int>::operator[](this + 30, (int)n); printf(" Child vert: %d\n", *v13); } return result; }
printParentToChildMapping: PUSH RBP MOV RBP,RSP SUB RSP,0xc0 MOV qword ptr [RBP + -0x8],RDI MOV RAX,qword ptr [RBP + -0x8] MOV qword ptr [RBP + -0x90],RAX LEA RDI,[0x2ebd97] MOV AL,0x0 CALL 0x001c34f0 MOV dword ptr [RBP + -0xc],0x0 LAB_001fef7f: MOV RAX,qword ptr [RBP + -0x90] MOV ECX,dword ptr [RBP + -0xc] MOV dword ptr [RBP + -0x94],ECX MOV RDI,qword ptr [RAX + 0x8] CALL 0x001c3430 MOV ECX,EAX MOV EAX,dword ptr [RBP + -0x94] CMP EAX,ECX JGE 0x001ff121 MOV ESI,dword ptr [RBP + -0xc] LEA RDI,[0x2ebdbb] XOR EAX,EAX MOV byte ptr [RBP + -0x95],AL CALL 0x001c34f0 MOV RDI,qword ptr [RBP + -0x90] ADD RDI,0xa8 MOVSXD RSI,dword ptr [RBP + -0xc] CALL 0x001d09b0 MOV RCX,RAX MOV AL,byte ptr [RBP + -0x95] MOV ESI,dword ptr [RCX] LEA RDI,[0x2ebdc7] CALL 0x001c34f0 MOV AL,byte ptr [RBP + -0x95] LEA RDI,[0x2ebddc] CALL 0x001c34f0 MOV RDI,qword ptr [RBP + -0x90] MOV ESI,dword ptr [RBP + -0xc] CALL 0x001d27d0 MOV dword ptr [RBP + -0x28],EDX MOV qword ptr [RBP + -0x30],RAX MOV RAX,qword ptr [RBP + -0x30] MOV qword ptr [RBP + -0x20],RAX MOV EAX,dword ptr [RBP + -0x28] MOV dword ptr [RBP + -0x18],EAX MOV dword ptr [RBP + -0x34],0x0 LAB_001ff02a: MOV EAX,dword ptr [RBP + -0x34] MOV dword ptr [RBP + -0x9c],EAX LEA RDI,[RBP + -0x20] CALL 0x001cc250 MOV ECX,EAX MOV EAX,dword ptr [RBP + -0x9c] CMP EAX,ECX JGE 0x001ff06f MOV ESI,dword ptr [RBP + -0x34] LEA RDI,[RBP + -0x20] CALL 0x001cabf0 MOV ESI,dword ptr [RAX] LEA RDI,[0x2fb38f] MOV AL,0x0 CALL 0x001c34f0 MOV EAX,dword ptr [RBP + -0x34] ADD EAX,0x1 MOV dword ptr [RBP + -0x34],EAX JMP 0x001ff02a LAB_001ff06f: LEA RDI,[0x2ea293] XOR EAX,EAX MOV byte ptr [RBP + -0x9d],AL CALL 0x001c34f0 MOV AL,byte ptr [RBP + -0x9d] LEA RDI,[0x2ebdee] CALL 0x001c34f0 MOV RDI,qword ptr [RBP + -0x90] MOV ESI,dword ptr [RBP + -0xc] CALL 0x001c7170 MOV dword ptr [RBP + -0x50],EDX MOV qword ptr [RBP + -0x58],RAX MOV RAX,qword ptr [RBP + -0x58] MOV qword ptr [RBP + -0x48],RAX MOV EAX,dword ptr [RBP + -0x50] MOV dword ptr [RBP + -0x40],EAX MOV dword ptr [RBP + -0x5c],0x0 LAB_001ff0c0: MOV EAX,dword ptr [RBP + -0x5c] MOV dword ptr [RBP + -0xa4],EAX LEA RDI,[RBP + -0x48] CALL 0x001cc250 MOV ECX,EAX MOV EAX,dword ptr [RBP + -0xa4] CMP EAX,ECX JGE 0x001ff105 MOV ESI,dword ptr [RBP + -0x5c] LEA RDI,[RBP + -0x48] CALL 0x001cabf0 MOV ESI,dword ptr [RAX] LEA RDI,[0x2fb38f] MOV AL,0x0 CALL 0x001c34f0 MOV EAX,dword ptr [RBP + -0x5c] ADD EAX,0x1 MOV dword ptr [RBP + -0x5c],EAX JMP 0x001ff0c0 LAB_001ff105: LEA RDI,[0x2ea293] MOV AL,0x0 CALL 0x001c34f0 MOV EAX,dword ptr [RBP + -0xc] ADD EAX,0x1 MOV dword ptr [RBP + -0xc],EAX JMP 0x001fef7f LAB_001ff121: MOV dword ptr [RBP + -0x60],0x0 LAB_001ff128: MOV RAX,qword ptr [RBP + -0x90] MOV ECX,dword ptr [RBP + -0x60] MOV dword ptr [RBP + -0xa8],ECX MOV RDI,qword ptr [RAX + 0x8] CALL 0x001ca130 MOV ECX,EAX MOV EAX,dword ptr [RBP + -0xa8] CMP EAX,ECX JGE 0x001ff1ff MOV ESI,dword ptr [RBP + -0x60] LEA RDI,[0x2ebe00] XOR EAX,EAX MOV byte ptr [RBP + -0xad],AL CALL 0x001c34f0 MOV RDI,qword ptr [RBP + -0x90] ADD RDI,0xd8 MOVSXD RSI,dword ptr [RBP + -0x60] CALL 0x001d09b0 MOV RCX,RAX MOV AL,byte ptr [RBP + -0xad] MOV ESI,dword ptr [RCX] LEA RDI,[0x2ebdc7] CALL 0x001c34f0 MOV RDI,qword ptr [RBP + -0x90] MOV ESI,dword ptr [RBP + -0x60] CALL 0x001cf7d0 MOV dword ptr [RBP + -0x78],EDX MOV qword ptr [RBP + -0x80],RAX MOV RAX,qword ptr [RBP + -0x80] MOV qword ptr [RBP + -0x70],RAX MOV EAX,dword ptr [RBP + -0x78] MOV dword ptr [RBP + -0x68],EAX LEA RDI,[RBP + -0x70] XOR ESI,ESI CALL 0x001cabf0 MOV EAX,dword ptr [RAX] MOV dword ptr [RBP + -0xac],EAX LEA RDI,[RBP + -0x70] MOV ESI,0x1 CALL 0x001cabf0 MOV ESI,dword ptr [RBP + -0xac] MOV EDX,dword ptr [RAX] LEA RDI,[0x2ebe0c] MOV AL,0x0 CALL 0x001c34f0 MOV EAX,dword ptr [RBP + -0x60] ADD EAX,0x1 MOV dword ptr [RBP + -0x60],EAX JMP 0x001ff128 LAB_001ff1ff: MOV dword ptr [RBP + -0x84],0x0 LAB_001ff209: MOV RAX,qword ptr [RBP + -0x90] MOV ECX,dword ptr [RBP + -0x84] MOV dword ptr [RBP + -0xb4],ECX MOV RDI,qword ptr [RAX + 0x8] CALL 0x001c8fe0 MOV ECX,EAX MOV EAX,dword ptr [RBP + -0xb4] CMP EAX,ECX JGE 0x001ff280 MOV ESI,dword ptr [RBP + -0x84] LEA RDI,[0x2ebe24] MOV AL,0x0 CALL 0x001c34f0 MOV RDI,qword ptr [RBP + -0x90] ADD RDI,0xf0 MOVSXD RSI,dword ptr [RBP + -0x84] CALL 0x001d09b0 MOV ESI,dword ptr [RAX] LEA RDI,[0x2ebdc7] MOV AL,0x0 CALL 0x001c34f0 MOV EAX,dword ptr [RBP + -0x84] ADD EAX,0x1 MOV dword ptr [RBP + -0x84],EAX JMP 0x001ff209 LAB_001ff280: ADD RSP,0xc0 POP RBP RET
/* OpenSubdiv::v3_6_0::Vtr::internal::Refinement::printParentToChildMapping() const */ void __thiscall OpenSubdiv::v3_6_0::Vtr::internal::Refinement::printParentToChildMapping(Refinement *this) { uint uVar1; int iVar2; int iVar3; uint *puVar4; int1 auVar5 [12]; uint local_8c; int1 local_78 [12]; uint local_68; int local_64; int1 local_60 [12]; int1 local_50 [12]; int local_3c; int1 local_38 [12]; int1 local_28 [12]; uint local_14; Refinement *local_10; local_10 = this; printf("Parent-to-child component mapping:\n"); local_14 = 0; while( true ) { uVar1 = local_14; iVar2 = Level::getNumFaces(*(Level **)(this + 8)); if (iVar2 <= (int)uVar1) break; printf(" Face %d:\n",(ulong)local_14); puVar4 = (uint *)std::vector<int,std::allocator<int>>::operator[] ((vector<int,std::allocator<int>> *)(this + 0xa8),(long)(int)local_14 ); printf(" Child vert: %d\n",(ulong)*puVar4); printf(" Child faces: "); auVar5 = getFaceChildFaces(this,local_14); local_3c = 0; local_38 = auVar5; local_28 = auVar5; while( true ) { iVar2 = local_3c; iVar3 = ConstArray<int>::size((ConstArray<int> *)local_28); if (iVar3 <= iVar2) break; puVar4 = (uint *)ConstArray<int>::operator[]((ConstArray<int> *)local_28,local_3c); printf(" %d",(ulong)*puVar4); local_3c = local_3c + 1; } printf("\n"); printf(" Child edges: "); auVar5 = getFaceChildEdges(this,local_14); local_64 = 0; local_60 = auVar5; local_50 = auVar5; while( true ) { iVar2 = local_64; iVar3 = ConstArray<int>::size((ConstArray<int> *)local_50); if (iVar3 <= iVar2) break; puVar4 = (uint *)ConstArray<int>::operator[]((ConstArray<int> *)local_50,local_64); printf(" %d",(ulong)*puVar4); local_64 = local_64 + 1; } printf("\n"); local_14 = local_14 + 1; } local_68 = 0; while( true ) { uVar1 = local_68; iVar2 = Level::getNumEdges(*(Level **)(this + 8)); if (iVar2 <= (int)uVar1) break; printf(" Edge %d:\n",(ulong)local_68); puVar4 = (uint *)std::vector<int,std::allocator<int>>::operator[] ((vector<int,std::allocator<int>> *)(this + 0xd8),(long)(int)local_68 ); printf(" Child vert: %d\n",(ulong)*puVar4); auVar5 = getEdgeChildEdges(this,local_68); local_78 = auVar5; puVar4 = (uint *)ConstArray<int>::operator[]((ConstArray<int> *)local_78,0); uVar1 = *puVar4; puVar4 = (uint *)ConstArray<int>::operator[]((ConstArray<int> *)local_78,1); printf(" Child edges: %d %d\n",(ulong)uVar1,(ulong)*puVar4); local_68 = local_68 + 1; } local_8c = 0; while( true ) { iVar2 = Level::getNumVertices(*(Level **)(this + 8)); if (iVar2 <= (int)local_8c) break; printf(" Vert %d:\n",(ulong)local_8c); puVar4 = (uint *)std::vector<int,std::allocator<int>>::operator[] ((vector<int,std::allocator<int>> *)(this + 0xf0),(long)(int)local_8c ); printf(" Child vert: %d\n",(ulong)*puVar4); local_8c = local_8c + 1; } return; }
6,025
OpenSubdiv::v3_6_0::Vtr::internal::Refinement::printParentToChildMapping() const
NVIDIA-RTX[P]OSD-Lite/opensubdiv/vtr/refinement.cpp
void Refinement::printParentToChildMapping() const { printf("Parent-to-child component mapping:\n"); for (Index pFace = 0; pFace < _parent->getNumFaces(); ++pFace) { printf(" Face %d:\n", pFace); printf(" Child vert: %d\n", _faceChildVertIndex[pFace]); printf(" Child faces: "); ConstIndexArray childFaces = getFaceChildFaces(pFace); for (int i = 0; i < childFaces.size(); ++i) { printf(" %d", childFaces[i]); } printf("\n"); printf(" Child edges: "); ConstIndexArray childEdges = getFaceChildEdges(pFace); for (int i = 0; i < childEdges.size(); ++i) { printf(" %d", childEdges[i]); } printf("\n"); } for (Index pEdge = 0; pEdge < _parent->getNumEdges(); ++pEdge) { printf(" Edge %d:\n", pEdge); printf(" Child vert: %d\n", _edgeChildVertIndex[pEdge]); ConstIndexArray childEdges = getEdgeChildEdges(pEdge); printf(" Child edges: %d %d\n", childEdges[0], childEdges[1]); } for (Index pVert = 0; pVert < _parent->getNumVertices(); ++pVert) { printf(" Vert %d:\n", pVert); printf(" Child vert: %d\n", _vertChildVertIndex[pVert]); } }
O1
cpp
OpenSubdiv::v3_6_0::Vtr::internal::Refinement::printParentToChildMapping() const: pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx pushq %rax movq %rdi, %rbx leaq 0x6abd2(%rip), %rdi # 0xb3eb7 callq 0x3b430 movq 0x8(%rbx), %rax cmpl $0x0, (%rax) jle 0x493ee leaq 0x69cc7(%rip), %r13 # 0xb2fc5 xorl %r14d, %r14d leaq 0x6a9da(%rip), %rdi # 0xb3ce2 movl %r14d, %esi xorl %eax, %eax callq 0x38100 movq 0xa8(%rbx), %rax movl (%rax,%r14,4), %esi leaq 0x6a9ca(%rip), %rdi # 0xb3cee xorl %eax, %eax callq 0x38100 leaq 0x6a9d1(%rip), %rdi # 0xb3d03 xorl %eax, %eax callq 0x38100 leaq (%r14,%r14), %rax movq %rax, (%rsp) movq 0x58(%rbx), %rax movslq (%rax,%r14,8), %r12 testq %r12, %r12 jle 0x49379 movq (%rsp), %rcx movslq 0x4(%rax,%rcx,4), %rbp shlq $0x2, %rbp addq 0x78(%rbx), %rbp xorl %r15d, %r15d movl (%rbp,%r15,4), %esi movq %r13, %rdi xorl %eax, %eax callq 0x38100 incq %r15 cmpq %r15, %r12 jne 0x49362 movl $0xa, %edi callq 0x3af50 leaq 0x6a98b(%rip), %rdi # 0xb3d15 xorl %eax, %eax callq 0x38100 movq 0x68(%rbx), %rax movq (%rsp), %rcx movslq (%rax,%rcx,4), %r15 testq %r15, %r15 jle 0x493d1 leaq 0x1(,%r14,2), %rcx movslq (%rax,%rcx,4), %r12 shlq $0x2, %r12 addq 0x90(%rbx), %r12 xorl %ebp, %ebp movl (%r12,%rbp,4), %esi movq %r13, %rdi xorl %eax, %eax callq 0x38100 incq %rbp cmpq %rbp, %r15 jne 0x493bb movl $0xa, %edi callq 0x3af50 incq %r14 movq 0x8(%rbx), %rax movslq (%rax), %rax cmpq %rax, %r14 jl 0x49301 movq 0x8(%rbx), %rax cmpl $0x0, 0x4(%rax) jle 0x4945c leaq 0x6a928(%rip), %r14 # 0xb3d27 leaq 0x6a8e8(%rip), %r15 # 0xb3cee leaq 0x6a926(%rip), %r12 # 0xb3d33 xorl %r13d, %r13d movq %r14, %rdi movl %r13d, %esi xorl %eax, %eax callq 0x38100 movq 0xd8(%rbx), %rax movl (%rax,%r13,4), %esi movq %r15, %rdi xorl %eax, %eax callq 0x38100 movq 0xc0(%rbx), %rax movl (%rax,%r13,8), %esi movl 0x4(%rax,%r13,8), %edx movq %r12, %rdi xorl %eax, %eax callq 0x38100 incq %r13 movq 0x8(%rbx), %rax movslq 0x4(%rax), %rax cmpq %rax, %r13 jl 0x49410 movq 0x8(%rbx), %rax cmpl $0x0, 0x8(%rax) jle 0x494a9 leaq 0x6a8de(%rip), %r14 # 0xb3d4b leaq 0x6a87a(%rip), %r15 # 0xb3cee xorl %r12d, %r12d movq %r14, %rdi movl %r12d, %esi xorl %eax, %eax callq 0x38100 movq 0xf0(%rbx), %rax movl (%rax,%r12,4), %esi movq %r15, %rdi xorl %eax, %eax callq 0x38100 incq %r12 movq 0x8(%rbx), %rax movslq 0x8(%rax), %rax cmpq %rax, %r12 jl 0x49477 addq $0x8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
_ZNK10OpenSubdiv6v3_6_03Vtr8internal10Refinement25printParentToChildMappingEv: push rbp push r15 push r14 push r13 push r12 push rbx push rax mov rbx, rdi lea rdi, aParentToChildC; "Parent-to-child component mapping:" call _puts mov rax, [rbx+8] cmp dword ptr [rax], 0 jle loc_493EE lea r13, aNonmanifoldD+0Fh; " %d" xor r14d, r14d loc_49301: lea rdi, aFaceD; " Face %d:\n" mov esi, r14d xor eax, eax call _printf mov rax, [rbx+0A8h] mov esi, [rax+r14*4] lea rdi, aChildVertD; " Child vert: %d\n" xor eax, eax call _printf lea rdi, aChildFaces; " Child faces: " xor eax, eax call _printf lea rax, [r14+r14] mov [rsp+38h+var_38], rax mov rax, [rbx+58h] movsxd r12, dword ptr [rax+r14*8] test r12, r12 jle short loc_49379 mov rcx, [rsp+38h+var_38] movsxd rbp, dword ptr [rax+rcx*4+4] shl rbp, 2 add rbp, [rbx+78h] xor r15d, r15d loc_49362: mov esi, [rbp+r15*4+0] mov rdi, r13 xor eax, eax call _printf inc r15 cmp r12, r15 jnz short loc_49362 loc_49379: mov edi, 0Ah call _putchar lea rdi, aChildEdges; " Child edges: " xor eax, eax call _printf mov rax, [rbx+68h] mov rcx, [rsp+38h+var_38] movsxd r15, dword ptr [rax+rcx*4] test r15, r15 jle short loc_493D1 lea rcx, ds:1[r14*2] movsxd r12, dword ptr [rax+rcx*4] shl r12, 2 add r12, [rbx+90h] xor ebp, ebp loc_493BB: mov esi, [r12+rbp*4] mov rdi, r13 xor eax, eax call _printf inc rbp cmp r15, rbp jnz short loc_493BB loc_493D1: mov edi, 0Ah call _putchar inc r14 mov rax, [rbx+8] movsxd rax, dword ptr [rax] cmp r14, rax jl loc_49301 loc_493EE: mov rax, [rbx+8] cmp dword ptr [rax+4], 0 jle short loc_4945C lea r14, aEdgeD; " Edge %d:\n" lea r15, aChildVertD; " Child vert: %d\n" lea r12, aChildEdgesDD; " Child edges: %d %d\n" xor r13d, r13d loc_49410: mov rdi, r14 mov esi, r13d xor eax, eax call _printf mov rax, [rbx+0D8h] mov esi, [rax+r13*4] mov rdi, r15 xor eax, eax call _printf mov rax, [rbx+0C0h] mov esi, [rax+r13*8] mov edx, [rax+r13*8+4] mov rdi, r12 xor eax, eax call _printf inc r13 mov rax, [rbx+8] movsxd rax, dword ptr [rax+4] cmp r13, rax jl short loc_49410 loc_4945C: mov rax, [rbx+8] cmp dword ptr [rax+8], 0 jle short loc_494A9 lea r14, aVertD; " Vert %d:\n" lea r15, aChildVertD; " Child vert: %d\n" xor r12d, r12d loc_49477: mov rdi, r14 mov esi, r12d xor eax, eax call _printf mov rax, [rbx+0F0h] mov esi, [rax+r12*4] mov rdi, r15 xor eax, eax call _printf inc r12 mov rax, [rbx+8] movsxd rax, dword ptr [rax+8] cmp r12, rax jl short loc_49477 loc_494A9: add rsp, 8 pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
long long OpenSubdiv::v3_6_0::Vtr::internal::Refinement::printParentToChildMapping( OpenSubdiv::v3_6_0::Vtr::internal::Refinement *this) { long long v1; // r14 long long v2; // rax long long v3; // r12 long long v4; // rbp long long i; // r15 long long v6; // rax long long v7; // r15 long long v8; // r12 long long j; // rbp long long v10; // r13 long long result; // rax long long v12; // r12 puts("Parent-to-child component mapping:"); if ( **((int **)this + 1) > 0 ) { v1 = 0LL; do { printf(" Face %d:\n", v1); printf(" Child vert: %d\n", *(_DWORD *)(*((_QWORD *)this + 21) + 4 * v1)); printf(" Child faces: "); v2 = *((_QWORD *)this + 11); v3 = *(int *)(v2 + 8 * v1); if ( v3 > 0 ) { v4 = *((_QWORD *)this + 15) + 4LL * *(int *)(v2 + 8 * v1 + 4); for ( i = 0LL; i != v3; ++i ) printf(" %d", *(_DWORD *)(v4 + 4 * i)); } putchar(10LL); printf(" Child edges: "); v6 = *((_QWORD *)this + 13); v7 = *(int *)(v6 + 8 * v1); if ( v7 > 0 ) { v8 = *((_QWORD *)this + 18) + 4LL * *(int *)(v6 + 4 * (2 * v1 + 1)); for ( j = 0LL; j != v7; ++j ) printf(" %d", *(_DWORD *)(v8 + 4 * j)); } putchar(10LL); ++v1; } while ( v1 < **((int **)this + 1) ); } if ( *(int *)(*((_QWORD *)this + 1) + 4LL) > 0 ) { v10 = 0LL; do { printf(" Edge %d:\n", v10); printf(" Child vert: %d\n", *(_DWORD *)(*((_QWORD *)this + 27) + 4 * v10)); printf( " Child edges: %d %d\n", *(_DWORD *)(*((_QWORD *)this + 24) + 8 * v10), *(_DWORD *)(*((_QWORD *)this + 24) + 8 * v10 + 4)); ++v10; } while ( v10 < *(int *)(*((_QWORD *)this + 1) + 4LL) ); } result = *((_QWORD *)this + 1); if ( *(int *)(result + 8) > 0 ) { v12 = 0LL; do { printf(" Vert %d:\n", v12); printf(" Child vert: %d\n", *(_DWORD *)(*((_QWORD *)this + 30) + 4 * v12++)); result = *(int *)(*((_QWORD *)this + 1) + 8LL); } while ( v12 < result ); } return result; }
printParentToChildMapping: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX PUSH RAX MOV RBX,RDI LEA RDI,[0x1b3eb7] CALL 0x0013b430 MOV RAX,qword ptr [RBX + 0x8] CMP dword ptr [RAX],0x0 JLE 0x001493ee LEA R13,[0x1b2fc5] XOR R14D,R14D LAB_00149301: LEA RDI,[0x1b3ce2] MOV ESI,R14D XOR EAX,EAX CALL 0x00138100 MOV RAX,qword ptr [RBX + 0xa8] MOV ESI,dword ptr [RAX + R14*0x4] LEA RDI,[0x1b3cee] XOR EAX,EAX CALL 0x00138100 LEA RDI,[0x1b3d03] XOR EAX,EAX CALL 0x00138100 LEA RAX,[R14 + R14*0x1] MOV qword ptr [RSP],RAX MOV RAX,qword ptr [RBX + 0x58] MOVSXD R12,dword ptr [RAX + R14*0x8] TEST R12,R12 JLE 0x00149379 MOV RCX,qword ptr [RSP] MOVSXD RBP,dword ptr [RAX + RCX*0x4 + 0x4] SHL RBP,0x2 ADD RBP,qword ptr [RBX + 0x78] XOR R15D,R15D LAB_00149362: MOV ESI,dword ptr [RBP + R15*0x4] MOV RDI,R13 XOR EAX,EAX CALL 0x00138100 INC R15 CMP R12,R15 JNZ 0x00149362 LAB_00149379: MOV EDI,0xa CALL 0x0013af50 LEA RDI,[0x1b3d15] XOR EAX,EAX CALL 0x00138100 MOV RAX,qword ptr [RBX + 0x68] MOV RCX,qword ptr [RSP] MOVSXD R15,dword ptr [RAX + RCX*0x4] TEST R15,R15 JLE 0x001493d1 LEA RCX,[0x1 + R14*0x2] MOVSXD R12,dword ptr [RAX + RCX*0x4] SHL R12,0x2 ADD R12,qword ptr [RBX + 0x90] XOR EBP,EBP LAB_001493bb: MOV ESI,dword ptr [R12 + RBP*0x4] MOV RDI,R13 XOR EAX,EAX CALL 0x00138100 INC RBP CMP R15,RBP JNZ 0x001493bb LAB_001493d1: MOV EDI,0xa CALL 0x0013af50 INC R14 MOV RAX,qword ptr [RBX + 0x8] MOVSXD RAX,dword ptr [RAX] CMP R14,RAX JL 0x00149301 LAB_001493ee: MOV RAX,qword ptr [RBX + 0x8] CMP dword ptr [RAX + 0x4],0x0 JLE 0x0014945c LEA R14,[0x1b3d27] LEA R15,[0x1b3cee] LEA R12,[0x1b3d33] XOR R13D,R13D LAB_00149410: MOV RDI,R14 MOV ESI,R13D XOR EAX,EAX CALL 0x00138100 MOV RAX,qword ptr [RBX + 0xd8] MOV ESI,dword ptr [RAX + R13*0x4] MOV RDI,R15 XOR EAX,EAX CALL 0x00138100 MOV RAX,qword ptr [RBX + 0xc0] MOV ESI,dword ptr [RAX + R13*0x8] MOV EDX,dword ptr [RAX + R13*0x8 + 0x4] MOV RDI,R12 XOR EAX,EAX CALL 0x00138100 INC R13 MOV RAX,qword ptr [RBX + 0x8] MOVSXD RAX,dword ptr [RAX + 0x4] CMP R13,RAX JL 0x00149410 LAB_0014945c: MOV RAX,qword ptr [RBX + 0x8] CMP dword ptr [RAX + 0x8],0x0 JLE 0x001494a9 LEA R14,[0x1b3d4b] LEA R15,[0x1b3cee] XOR R12D,R12D LAB_00149477: MOV RDI,R14 MOV ESI,R12D XOR EAX,EAX CALL 0x00138100 MOV RAX,qword ptr [RBX + 0xf0] MOV ESI,dword ptr [RAX + R12*0x4] MOV RDI,R15 XOR EAX,EAX CALL 0x00138100 INC R12 MOV RAX,qword ptr [RBX + 0x8] MOVSXD RAX,dword ptr [RAX + 0x8] CMP R12,RAX JL 0x00149477 LAB_001494a9: ADD RSP,0x8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
/* OpenSubdiv::v3_6_0::Vtr::internal::Refinement::printParentToChildMapping() const */ void __thiscall OpenSubdiv::v3_6_0::Vtr::internal::Refinement::printParentToChildMapping(Refinement *this) { int iVar1; long lVar2; long lVar3; ulong uVar4; long lVar5; puts("Parent-to-child component mapping:"); if (0 < **(int **)(this + 8)) { uVar4 = 0; do { printf(" Face %d:\n",uVar4 & 0xffffffff); printf(" Child vert: %d\n",(ulong)*(uint *)(*(long *)(this + 0xa8) + uVar4 * 4)); printf(" Child faces: "); lVar3 = (long)*(int *)(*(long *)(this + 0x58) + uVar4 * 8); if (0 < lVar3) { iVar1 = *(int *)(*(long *)(this + 0x58) + 4 + uVar4 * 8); lVar2 = *(long *)(this + 0x78); lVar5 = 0; do { printf(" %d",(ulong)*(uint *)((long)iVar1 * 4 + lVar2 + lVar5 * 4)); lVar5 = lVar5 + 1; } while (lVar3 != lVar5); } putchar(10); printf(" Child edges: "); lVar3 = (long)*(int *)(*(long *)(this + 0x68) + uVar4 * 8); if (0 < lVar3) { iVar1 = *(int *)(*(long *)(this + 0x68) + (uVar4 * 2 + 1) * 4); lVar2 = *(long *)(this + 0x90); lVar5 = 0; do { printf(" %d",(ulong)*(uint *)((long)iVar1 * 4 + lVar2 + lVar5 * 4)); lVar5 = lVar5 + 1; } while (lVar3 != lVar5); } putchar(10); uVar4 = uVar4 + 1; } while ((long)uVar4 < (long)**(int **)(this + 8)); } if (0 < *(int *)(*(long *)(this + 8) + 4)) { uVar4 = 0; do { printf(" Edge %d:\n",uVar4 & 0xffffffff); printf(" Child vert: %d\n",(ulong)*(uint *)(*(long *)(this + 0xd8) + uVar4 * 4)); printf(" Child edges: %d %d\n",(ulong)*(uint *)(*(long *)(this + 0xc0) + uVar4 * 8), (ulong)*(uint *)(*(long *)(this + 0xc0) + 4 + uVar4 * 8)); uVar4 = uVar4 + 1; } while ((long)uVar4 < (long)*(int *)(*(long *)(this + 8) + 4)); } if (0 < *(int *)(*(long *)(this + 8) + 8)) { uVar4 = 0; do { printf(" Vert %d:\n",uVar4 & 0xffffffff); printf(" Child vert: %d\n",(ulong)*(uint *)(*(long *)(this + 0xf0) + uVar4 * 4)); uVar4 = uVar4 + 1; } while ((long)uVar4 < (long)*(int *)(*(long *)(this + 8) + 8)); } return; }
6,026
OpenSubdiv::v3_6_0::Vtr::internal::Refinement::printParentToChildMapping() const
NVIDIA-RTX[P]OSD-Lite/opensubdiv/vtr/refinement.cpp
void Refinement::printParentToChildMapping() const { printf("Parent-to-child component mapping:\n"); for (Index pFace = 0; pFace < _parent->getNumFaces(); ++pFace) { printf(" Face %d:\n", pFace); printf(" Child vert: %d\n", _faceChildVertIndex[pFace]); printf(" Child faces: "); ConstIndexArray childFaces = getFaceChildFaces(pFace); for (int i = 0; i < childFaces.size(); ++i) { printf(" %d", childFaces[i]); } printf("\n"); printf(" Child edges: "); ConstIndexArray childEdges = getFaceChildEdges(pFace); for (int i = 0; i < childEdges.size(); ++i) { printf(" %d", childEdges[i]); } printf("\n"); } for (Index pEdge = 0; pEdge < _parent->getNumEdges(); ++pEdge) { printf(" Edge %d:\n", pEdge); printf(" Child vert: %d\n", _edgeChildVertIndex[pEdge]); ConstIndexArray childEdges = getEdgeChildEdges(pEdge); printf(" Child edges: %d %d\n", childEdges[0], childEdges[1]); } for (Index pVert = 0; pVert < _parent->getNumVertices(); ++pVert) { printf(" Vert %d:\n", pVert); printf(" Child vert: %d\n", _vertChildVertIndex[pVert]); } }
O2
cpp
OpenSubdiv::v3_6_0::Vtr::internal::Refinement::printParentToChildMapping() const: pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx pushq %rax movq %rdi, %rbx leaq 0x5cee4(%rip), %rdi # 0xbdeb7 callq 0x544b0 leaq 0x5bfe6(%rip), %r14 # 0xbcfc5 xorl %r15d, %r15d movq 0x8(%rbx), %rax movslq (%rax), %rcx cmpq %rcx, %r15 jge 0x610bc leaq 0x5cce9(%rip), %rdi # 0xbdce2 movl %r15d, %esi xorl %eax, %eax callq 0x4f1b0 movq 0xa8(%rbx), %rax movl (%rax,%r15,4), %esi leaq 0x5ccd9(%rip), %rdi # 0xbdcee xorl %eax, %eax callq 0x4f1b0 leaq 0x5cce0(%rip), %rdi # 0xbdd03 xorl %eax, %eax callq 0x4f1b0 movq %rbx, %rdi movl %r15d, %esi callq 0x542c0 movq %rax, %r12 movl %edx, %r13d testl %edx, %edx movl $0x0, %eax cmovlel %eax, %r13d xorl %ebp, %ebp cmpq %rbp, %r13 je 0x61060 movl (%r12,%rbp,4), %esi movq %r14, %rdi xorl %eax, %eax callq 0x4f1b0 incq %rbp jmp 0x61048 pushq $0xa popq %rdi callq 0x53d40 leaq 0x5cca6(%rip), %rdi # 0xbdd15 xorl %eax, %eax callq 0x4f1b0 movq %rbx, %rdi movl %r15d, %esi callq 0x50610 movq %rax, %r12 movl %edx, %r13d testl %edx, %edx movl $0x0, %eax cmovlel %eax, %r13d xorl %ebp, %ebp cmpq %rbp, %r13 je 0x610ac movl (%r12,%rbp,4), %esi movq %r14, %rdi xorl %eax, %eax callq 0x4f1b0 incq %rbp jmp 0x61094 pushq $0xa popq %rdi callq 0x53d40 incq %r15 jmp 0x60fe2 leaq 0x5cc64(%rip), %r14 # 0xbdd27 leaq 0x5cc24(%rip), %r15 # 0xbdcee leaq 0x5cc62(%rip), %r12 # 0xbdd33 xorl %r13d, %r13d movslq 0x4(%rax), %rcx cmpq %rcx, %r13 jge 0x61122 movq %r14, %rdi movl %r13d, %esi xorl %eax, %eax callq 0x4f1b0 movq 0xd8(%rbx), %rax movl (%rax,%r13,4), %esi movq %r15, %rdi xorl %eax, %eax callq 0x4f1b0 movq 0xc0(%rbx), %rax movl (%rax,%r13,8), %esi movl 0x4(%rax,%r13,8), %edx movq %r12, %rdi xorl %eax, %eax callq 0x4f1b0 incq %r13 movq 0x8(%rbx), %rax jmp 0x610d4 leaq 0x5cc22(%rip), %r14 # 0xbdd4b leaq 0x5cbbe(%rip), %r15 # 0xbdcee xorl %r12d, %r12d movslq 0x8(%rax), %rax cmpq %rax, %r12 jge 0x61167 movq %r14, %rdi movl %r12d, %esi xorl %eax, %eax callq 0x4f1b0 movq 0xf0(%rbx), %rax movl (%rax,%r12,4), %esi movq %r15, %rdi xorl %eax, %eax callq 0x4f1b0 incq %r12 movq 0x8(%rbx), %rax jmp 0x61133 addq $0x8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
_ZNK10OpenSubdiv6v3_6_03Vtr8internal10Refinement25printParentToChildMappingEv: push rbp push r15 push r14 push r13 push r12 push rbx push rax mov rbx, rdi lea rdi, aParentToChildC; "Parent-to-child component mapping:" call _puts lea r14, aNonmanifoldD+0Fh; " %d" xor r15d, r15d loc_60FE2: mov rax, [rbx+8] movsxd rcx, dword ptr [rax] cmp r15, rcx jge loc_610BC lea rdi, aFaceD; " Face %d:\n" mov esi, r15d xor eax, eax call _printf mov rax, [rbx+0A8h] mov esi, [rax+r15*4] lea rdi, aChildVertD; " Child vert: %d\n" xor eax, eax call _printf lea rdi, aChildFaces; " Child faces: " xor eax, eax call _printf mov rdi, rbx; this mov esi, r15d; int call __ZNK10OpenSubdiv6v3_6_03Vtr8internal10Refinement17getFaceChildFacesEi; OpenSubdiv::v3_6_0::Vtr::internal::Refinement::getFaceChildFaces(int) mov r12, rax mov r13d, edx test edx, edx mov eax, 0 cmovle r13d, eax xor ebp, ebp loc_61048: cmp r13, rbp jz short loc_61060 mov esi, [r12+rbp*4] mov rdi, r14 xor eax, eax call _printf inc rbp jmp short loc_61048 loc_61060: push 0Ah pop rdi call _putchar lea rdi, aChildEdges; " Child edges: " xor eax, eax call _printf mov rdi, rbx; this mov esi, r15d; int call __ZNK10OpenSubdiv6v3_6_03Vtr8internal10Refinement17getFaceChildEdgesEi; OpenSubdiv::v3_6_0::Vtr::internal::Refinement::getFaceChildEdges(int) mov r12, rax mov r13d, edx test edx, edx mov eax, 0 cmovle r13d, eax xor ebp, ebp loc_61094: cmp r13, rbp jz short loc_610AC mov esi, [r12+rbp*4] mov rdi, r14 xor eax, eax call _printf inc rbp jmp short loc_61094 loc_610AC: push 0Ah pop rdi call _putchar inc r15 jmp loc_60FE2 loc_610BC: lea r14, aEdgeD; " Edge %d:\n" lea r15, aChildVertD; " Child vert: %d\n" lea r12, aChildEdgesDD; " Child edges: %d %d\n" xor r13d, r13d loc_610D4: movsxd rcx, dword ptr [rax+4] cmp r13, rcx jge short loc_61122 mov rdi, r14 mov esi, r13d xor eax, eax call _printf mov rax, [rbx+0D8h] mov esi, [rax+r13*4] mov rdi, r15 xor eax, eax call _printf mov rax, [rbx+0C0h] mov esi, [rax+r13*8] mov edx, [rax+r13*8+4] mov rdi, r12 xor eax, eax call _printf inc r13 mov rax, [rbx+8] jmp short loc_610D4 loc_61122: lea r14, aVertD; " Vert %d:\n" lea r15, aChildVertD; " Child vert: %d\n" xor r12d, r12d loc_61133: movsxd rax, dword ptr [rax+8] cmp r12, rax jge short loc_61167 mov rdi, r14 mov esi, r12d xor eax, eax call _printf mov rax, [rbx+0F0h] mov esi, [rax+r12*4] mov rdi, r15 xor eax, eax call _printf inc r12 mov rax, [rbx+8] jmp short loc_61133 loc_61167: add rsp, 8 pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
long long OpenSubdiv::v3_6_0::Vtr::internal::Refinement::printParentToChildMapping( OpenSubdiv::v3_6_0::Vtr::internal::Refinement *this) { long long i; // r15 int *v2; // rax long long FaceChildFaces; // r12 int v4; // edx long long v5; // r13 long long j; // rbp long long FaceChildEdges; // r12 int v8; // edx long long v9; // r13 long long k; // rbp long long m; // r13 long long n; // r12 long long result; // rax puts("Parent-to-child component mapping:"); for ( i = 0LL; ; ++i ) { v2 = (int *)*((_QWORD *)this + 1); if ( i >= *v2 ) break; printf(" Face %d:\n", i); printf(" Child vert: %d\n", *(_DWORD *)(*((_QWORD *)this + 21) + 4 * i)); printf(" Child faces: "); FaceChildFaces = OpenSubdiv::v3_6_0::Vtr::internal::Refinement::getFaceChildFaces(this, i); v5 = (unsigned int)v4; if ( v4 <= 0 ) v5 = 0LL; for ( j = 0LL; v5 != j; ++j ) printf(" %d", *(_DWORD *)(FaceChildFaces + 4 * j)); putchar(10LL); printf(" Child edges: "); FaceChildEdges = OpenSubdiv::v3_6_0::Vtr::internal::Refinement::getFaceChildEdges(this, i); v9 = (unsigned int)v8; if ( v8 <= 0 ) v9 = 0LL; for ( k = 0LL; v9 != k; ++k ) printf(" %d", *(_DWORD *)(FaceChildEdges + 4 * k)); putchar(10LL); } for ( m = 0LL; m < v2[1]; ++m ) { printf(" Edge %d:\n", m); printf(" Child vert: %d\n", *(_DWORD *)(*((_QWORD *)this + 27) + 4 * m)); printf( " Child edges: %d %d\n", *(_DWORD *)(*((_QWORD *)this + 24) + 8 * m), *(_DWORD *)(*((_QWORD *)this + 24) + 8 * m + 4)); v2 = (int *)*((_QWORD *)this + 1); } for ( n = 0LL; ; ++n ) { result = v2[2]; if ( n >= result ) break; printf(" Vert %d:\n", n); printf(" Child vert: %d\n", *(_DWORD *)(*((_QWORD *)this + 30) + 4 * n)); v2 = (int *)*((_QWORD *)this + 1); } return result; }
printParentToChildMapping: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX PUSH RAX MOV RBX,RDI LEA RDI,[0x1bdeb7] CALL 0x001544b0 LEA R14,[0x1bcfc5] XOR R15D,R15D LAB_00160fe2: MOV RAX,qword ptr [RBX + 0x8] MOVSXD RCX,dword ptr [RAX] CMP R15,RCX JGE 0x001610bc LEA RDI,[0x1bdce2] MOV ESI,R15D XOR EAX,EAX CALL 0x0014f1b0 MOV RAX,qword ptr [RBX + 0xa8] MOV ESI,dword ptr [RAX + R15*0x4] LEA RDI,[0x1bdcee] XOR EAX,EAX CALL 0x0014f1b0 LEA RDI,[0x1bdd03] XOR EAX,EAX CALL 0x0014f1b0 MOV RDI,RBX MOV ESI,R15D CALL 0x001542c0 MOV R12,RAX MOV R13D,EDX TEST EDX,EDX MOV EAX,0x0 CMOVLE R13D,EAX XOR EBP,EBP LAB_00161048: CMP R13,RBP JZ 0x00161060 MOV ESI,dword ptr [R12 + RBP*0x4] MOV RDI,R14 XOR EAX,EAX CALL 0x0014f1b0 INC RBP JMP 0x00161048 LAB_00161060: PUSH 0xa POP RDI CALL 0x00153d40 LEA RDI,[0x1bdd15] XOR EAX,EAX CALL 0x0014f1b0 MOV RDI,RBX MOV ESI,R15D CALL 0x00150610 MOV R12,RAX MOV R13D,EDX TEST EDX,EDX MOV EAX,0x0 CMOVLE R13D,EAX XOR EBP,EBP LAB_00161094: CMP R13,RBP JZ 0x001610ac MOV ESI,dword ptr [R12 + RBP*0x4] MOV RDI,R14 XOR EAX,EAX CALL 0x0014f1b0 INC RBP JMP 0x00161094 LAB_001610ac: PUSH 0xa POP RDI CALL 0x00153d40 INC R15 JMP 0x00160fe2 LAB_001610bc: LEA R14,[0x1bdd27] LEA R15,[0x1bdcee] LEA R12,[0x1bdd33] XOR R13D,R13D LAB_001610d4: MOVSXD RCX,dword ptr [RAX + 0x4] CMP R13,RCX JGE 0x00161122 MOV RDI,R14 MOV ESI,R13D XOR EAX,EAX CALL 0x0014f1b0 MOV RAX,qword ptr [RBX + 0xd8] MOV ESI,dword ptr [RAX + R13*0x4] MOV RDI,R15 XOR EAX,EAX CALL 0x0014f1b0 MOV RAX,qword ptr [RBX + 0xc0] MOV ESI,dword ptr [RAX + R13*0x8] MOV EDX,dword ptr [RAX + R13*0x8 + 0x4] MOV RDI,R12 XOR EAX,EAX CALL 0x0014f1b0 INC R13 MOV RAX,qword ptr [RBX + 0x8] JMP 0x001610d4 LAB_00161122: LEA R14,[0x1bdd4b] LEA R15,[0x1bdcee] XOR R12D,R12D LAB_00161133: MOVSXD RAX,dword ptr [RAX + 0x8] CMP R12,RAX JGE 0x00161167 MOV RDI,R14 MOV ESI,R12D XOR EAX,EAX CALL 0x0014f1b0 MOV RAX,qword ptr [RBX + 0xf0] MOV ESI,dword ptr [RAX + R12*0x4] MOV RDI,R15 XOR EAX,EAX CALL 0x0014f1b0 INC R12 MOV RAX,qword ptr [RBX + 0x8] JMP 0x00161133 LAB_00161167: ADD RSP,0x8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
/* OpenSubdiv::v3_6_0::Vtr::internal::Refinement::printParentToChildMapping() const */ void __thiscall OpenSubdiv::v3_6_0::Vtr::internal::Refinement::printParentToChildMapping(Refinement *this) { int *piVar1; ulong uVar2; ulong uVar3; ulong uVar4; int1 auVar5 [12]; puts("Parent-to-child component mapping:"); uVar4 = 0; while( true ) { piVar1 = *(int **)(this + 8); if ((long)*piVar1 <= (long)uVar4) break; printf(" Face %d:\n",uVar4 & 0xffffffff); printf(" Child vert: %d\n",(ulong)*(uint *)(*(long *)(this + 0xa8) + uVar4 * 4)); printf(" Child faces: "); auVar5 = getFaceChildFaces(this,(int)uVar4); uVar3 = (ulong)auVar5._8_4_; if ((int)auVar5._8_4_ < 1) { uVar3 = 0; } for (uVar2 = 0; uVar3 != uVar2; uVar2 = uVar2 + 1) { printf(" %d",(ulong)*(uint *)(auVar5._0_8_ + uVar2 * 4)); } putchar(10); printf(" Child edges: "); auVar5 = getFaceChildEdges(this,(int)uVar4); uVar3 = (ulong)auVar5._8_4_; if ((int)auVar5._8_4_ < 1) { uVar3 = 0; } for (uVar2 = 0; uVar3 != uVar2; uVar2 = uVar2 + 1) { printf(" %d",(ulong)*(uint *)(auVar5._0_8_ + uVar2 * 4)); } putchar(10); uVar4 = uVar4 + 1; } for (uVar4 = 0; (long)uVar4 < (long)piVar1[1]; uVar4 = uVar4 + 1) { printf(" Edge %d:\n",uVar4 & 0xffffffff); printf(" Child vert: %d\n",(ulong)*(uint *)(*(long *)(this + 0xd8) + uVar4 * 4)); printf(" Child edges: %d %d\n",(ulong)*(uint *)(*(long *)(this + 0xc0) + uVar4 * 8), (ulong)*(uint *)(*(long *)(this + 0xc0) + 4 + uVar4 * 8)); piVar1 = *(int **)(this + 8); } for (uVar4 = 0; (long)uVar4 < (long)piVar1[2]; uVar4 = uVar4 + 1) { printf(" Vert %d:\n",uVar4 & 0xffffffff); printf(" Child vert: %d\n",(ulong)*(uint *)(*(long *)(this + 0xf0) + uVar4 * 4)); piVar1 = *(int **)(this + 8); } return; }
6,027
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_array()
llama.cpp/common/json.hpp
bool end_array() { bool keep = true; if (ref_stack.back()) { keep = callback(static_cast<int>(ref_stack.size()) - 1, parse_event_t::array_end, *ref_stack.back()); if (keep) { ref_stack.back()->set_parents(); } else { // discard array *ref_stack.back() = discarded; } } JSON_ASSERT(!ref_stack.empty()); JSON_ASSERT(!keep_stack.empty()); ref_stack.pop_back(); keep_stack.pop_back(); // remove discarded value if (!keep && !ref_stack.empty() && ref_stack.back()->is_array()) { ref_stack.back()->m_data.m_value.array->pop_back(); } 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_array(): pushq %rbp pushq %r14 pushq %rbx subq $0x20, %rsp movq %rdi, %rbx movq 0x10(%rdi), %rax movq -0x8(%rax), %rcx movb $0x1, %bpl testq %rcx, %rcx je 0x889f1 subq 0x8(%rbx), %rax shrq $0x3, %rax decl %eax movl %eax, 0xc(%rsp) movb $0x3, 0xb(%rsp) cmpq $0x0, 0x90(%rbx) je 0x88ab9 leaq 0x80(%rbx), %rdi leaq 0xc(%rsp), %rsi leaq 0xb(%rsp), %rdx callq *0x98(%rbx) testb %al, %al jne 0x889f1 leaq 0xa8(%rbx), %rsi leaq 0x10(%rsp), %r14 movq %r14, %rdi callq 0x8944c movq 0x10(%rbx), %rax movq -0x8(%rax), %rdi movq %r14, %rsi callq 0x8736a xorl %ebp, %ebp movq %r14, %rdi xorl %esi, %esi callq 0x851fe movq %r14, %rdi callq 0x89918 movq 0x8(%rbx), %rcx movq 0x10(%rbx), %rax cmpq %rax, %rcx je 0x88a7c 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 0x88a98 leaq -0x8(%rax), %rdi movq %rdi, 0x10(%rbx) subl $0x1, %esi movl %esi, 0x38(%rbx) jae 0x88a3b movl $0x3f, 0x38(%rbx) addq $-0x8, %rdx movq %rdx, 0x30(%rbx) cmpq %rdi, %rcx sete %cl orb %cl, %bpl jne 0x88a71 movq -0x10(%rax), %rax cmpb $0x2, (%rax) jne 0x88a71 movq 0x8(%rax), %rax movq 0x8(%rax), %rbx addq $-0x10, %rbx movq %rbx, 0x8(%rax) movq %rbx, %rdi xorl %esi, %esi callq 0x851fe movq %rbx, %rdi callq 0x89918 movb $0x1, %al addq $0x20, %rsp popq %rbx popq %r14 popq %rbp retq leaq 0x92af5(%rip), %rdi # 0x11b578 leaq 0x92b29(%rip), %rdx # 0x11b5b3 leaq 0x93ada(%rip), %rcx # 0x11c56b movl $0x1bf5, %esi # imm = 0x1BF5 jmp 0x88ab2 leaq 0x92ad9(%rip), %rdi # 0x11b578 leaq 0x92b0d(%rip), %rdx # 0x11b5b3 leaq 0x93a38(%rip), %rcx # 0x11c4e5 movl $0x1bf6, %esi # imm = 0x1BF6 xorl %eax, %eax callq 0x21e70 callq 0x222a0
_ZN8nlohmann16json_abi_v3_11_36detail28json_sax_dom_callback_parserINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE9end_arrayEv: push rbp push r14 push rbx sub rsp, 20h mov rbx, rdi mov rax, [rdi+10h] mov rcx, [rax-8] mov bpl, 1 test rcx, rcx jz short loc_889F1 sub rax, [rbx+8] shr rax, 3 dec eax mov [rsp+38h+var_2C], eax mov [rsp+38h+var_2D], 3 cmp qword ptr [rbx+90h], 0 jz loc_88AB9 lea rdi, [rbx+80h] lea rsi, [rsp+38h+var_2C] lea rdx, [rsp+38h+var_2D] call qword ptr [rbx+98h] test al, al jnz short loc_889F1 lea rsi, [rbx+0A8h] lea r14, [rsp+38h+var_28] 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>) xor ebp, ebp 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_889F1: mov rcx, [rbx+8] mov rax, [rbx+10h] cmp rcx, rax jz short loc_88A7C 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 short loc_88A98 lea rdi, [rax-8] mov [rbx+10h], rdi sub esi, 1 mov [rbx+38h], esi jnb short loc_88A3B mov dword ptr [rbx+38h], 3Fh ; '?' add rdx, 0FFFFFFFFFFFFFFF8h mov [rbx+30h], rdx loc_88A3B: cmp rcx, rdi setz cl or bpl, cl jnz short loc_88A71 mov rax, [rax-10h] cmp byte ptr [rax], 2 jnz short loc_88A71 mov rax, [rax+8] mov rbx, [rax+8] add rbx, 0FFFFFFFFFFFFFFF0h mov [rax+8], rbx mov rdi, rbx xor esi, esi call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::assert_invariant(bool) mov rdi, rbx call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE4dataD2Ev; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::data::~data() loc_88A71: mov al, 1 add rsp, 20h pop rbx pop r14 pop rbp retn loc_88A7C: lea rdi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github2025/llama."... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aRefStackEmpty; "!ref_stack.empty()" mov esi, 1BF5h jmp short loc_88AB2 loc_88A98: lea rdi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github2025/llama."... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aKeepStackEmpty; "!keep_stack.empty()" mov esi, 1BF6h loc_88AB2: xor eax, eax call _ggml_abort loc_88AB9: 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_array( long long a1) { long long v1; // rax char v2; // bp long long v3; // rcx long long v4; // rax long long v5; // rdx int v6; // esi long long v7; // rax long long v8; // rax char *v9; // rbx char v11; // [rsp+Bh] [rbp-2Dh] BYREF int v12; // [rsp+Ch] [rbp-2Ch] BYREF char v13[40]; // [rsp+10h] [rbp-28h] BYREF v1 = *(_QWORD *)(a1 + 16); v2 = 1; if ( *(_QWORD *)(v1 - 8) ) { v12 = ((unsigned long long)(v1 - *(_QWORD *)(a1 + 8)) >> 3) - 1; v11 = 3; if ( !*(_QWORD *)(a1 + 144) ) goto LABEL_15; if ( !(*(unsigned __int8 ( **)(long long, int *, char *))(a1 + 152))(a1 + 128, &v12, &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>::basic_json( v13, 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)v13); v2 = 0; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::assert_invariant(v13); 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(v13); } } v3 = *(_QWORD *)(a1 + 8); v4 = *(_QWORD *)(a1 + 16); if ( v3 == v4 ) { ggml_abort( "/workspace/llm4binary/github2025/llama.cpp/common/json.hpp", 7157LL, "GGML_ASSERT(%s) failed", "!ref_stack.empty()"); goto LABEL_15; } v5 = *(_QWORD *)(a1 + 48); v6 = *(_DWORD *)(a1 + 56); if ( *(_QWORD *)(a1 + 32) == v5 && v6 == 0 ) { ggml_abort( "/workspace/llm4binary/github2025/llama.cpp/common/json.hpp", 7158LL, "GGML_ASSERT(%s) failed", "!keep_stack.empty()"); LABEL_15: std::__throw_bad_function_call(); } *(_QWORD *)(a1 + 16) = v4 - 8; *(_DWORD *)(a1 + 56) = v6 - 1; if ( !v6 ) { *(_DWORD *)(a1 + 56) = 63; *(_QWORD *)(a1 + 48) = v5 - 8; } if ( !((v3 == v4 - 8) | (unsigned __int8)v2) ) { v7 = *(_QWORD *)(v4 - 16); if ( *(_BYTE *)v7 == 2 ) { v8 = *(_QWORD *)(v7 + 8); v9 = (char *)(*(_QWORD *)(v8 + 8) - 16LL); *(_QWORD *)(v8 + 8) = 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>::assert_invariant(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>::data::~data(v9); } } return 1; }
end_array: PUSH RBP PUSH R14 PUSH RBX SUB RSP,0x20 MOV RBX,RDI MOV RAX,qword ptr [RDI + 0x10] MOV RCX,qword ptr [RAX + -0x8] MOV BPL,0x1 TEST RCX,RCX JZ 0x001889f1 SUB RAX,qword ptr [RBX + 0x8] SHR RAX,0x3 DEC EAX MOV dword ptr [RSP + 0xc],EAX MOV byte ptr [RSP + 0xb],0x3 CMP qword ptr [RBX + 0x90],0x0 JZ 0x00188ab9 LEA RDI,[RBX + 0x80] LEA RSI,[RSP + 0xc] LEA RDX,[RSP + 0xb] CALL qword ptr [RBX + 0x98] TEST AL,AL JNZ 0x001889f1 LEA RSI,[RBX + 0xa8] LEA R14,[RSP + 0x10] MOV RDI,R14 CALL 0x0018944c MOV RAX,qword ptr [RBX + 0x10] MOV RDI,qword ptr [RAX + -0x8] MOV RSI,R14 CALL 0x0018736a XOR EBP,EBP MOV RDI,R14 XOR ESI,ESI CALL 0x001851fe MOV RDI,R14 CALL 0x00189918 LAB_001889f1: MOV RCX,qword ptr [RBX + 0x8] MOV RAX,qword ptr [RBX + 0x10] CMP RCX,RAX JZ 0x00188a7c 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 0x00188a98 LEA RDI,[RAX + -0x8] MOV qword ptr [RBX + 0x10],RDI SUB ESI,0x1 MOV dword ptr [RBX + 0x38],ESI JNC 0x00188a3b MOV dword ptr [RBX + 0x38],0x3f ADD RDX,-0x8 MOV qword ptr [RBX + 0x30],RDX LAB_00188a3b: CMP RCX,RDI SETZ CL OR BPL,CL JNZ 0x00188a71 MOV RAX,qword ptr [RAX + -0x10] CMP byte ptr [RAX],0x2 JNZ 0x00188a71 MOV RAX,qword ptr [RAX + 0x8] MOV RBX,qword ptr [RAX + 0x8] ADD RBX,-0x10 MOV qword ptr [RAX + 0x8],RBX MOV RDI,RBX XOR ESI,ESI CALL 0x001851fe MOV RDI,RBX CALL 0x00189918 LAB_00188a71: MOV AL,0x1 ADD RSP,0x20 POP RBX POP R14 POP RBP RET LAB_00188a7c: LEA RDI,[0x21b578] LEA RDX,[0x21b5b3] LEA RCX,[0x21c56b] MOV ESI,0x1bf5 JMP 0x00188ab2 LAB_00188a98: LEA RDI,[0x21b578] LEA RDX,[0x21b5b3] LEA RCX,[0x21c4e5] MOV ESI,0x1bf6 LAB_00188ab2: XOR EAX,EAX CALL 0x00121e70 LAB_00188ab9: CALL 0x001222a0
/* 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_array() */ 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_array(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; byte bVar3; char cVar4; char *pcVar5; data *this_00; int8 uVar6; int1 local_2d; int local_2c; basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,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_28 [16]; bVar3 = 1; if (*(long *)(*(long *)(this + 0x10) + -8) != 0) { local_2c = (int)((ulong)(*(long *)(this + 0x10) - *(long *)(this + 8)) >> 3) + -1; local_2d = 3; if (*(long *)(this + 0x90) == 0) { /* WARNING: Subroutine does not return */ std::__throw_bad_function_call(); } cVar4 = (**(code **)(this + 0x98))(this + 0x80,&local_2c,&local_2d); if (cVar4 == '\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_28,(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_28); bVar3 = 0; basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> ::assert_invariant(SUB81(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> ::data::~data((data *)local_28); } } lVar2 = *(long *)(this + 0x10); if (*(long *)(this + 8) == lVar2) { pcVar5 = "!ref_stack.empty()"; uVar6 = 0x1bf5; } 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 ((!(bool)(bVar3 | *(long *)(this + 8) == lVar2 + -8)) && (**(char **)(lVar2 + -0x10) == '\x02')) { lVar2 = *(long *)(*(char **)(lVar2 + -0x10) + 8); this_00 = (data *)(*(long *)(lVar2 + 8) + -0x10); *(data **)(lVar2 + 8) = 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> ::assert_invariant(SUB81(this_00,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(this_00); } return 1; } pcVar5 = "!keep_stack.empty()"; uVar6 = 0x1bf6; } /* WARNING: Subroutine does not return */ ggml_abort("/workspace/llm4binary/github2025/llama.cpp/common/json.hpp",uVar6, "GGML_ASSERT(%s) failed",pcVar5); }
6,028
common_tokenize(llama_vocab const*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, bool, bool)
monkey531[P]llama/common/common.cpp
std::vector<llama_token> common_tokenize( const struct llama_vocab * vocab, const std::string & text, bool add_special, bool parse_special) { // upper limit for the number of tokens int n_tokens = text.length() + 2 * add_special; std::vector<llama_token> result(n_tokens); n_tokens = llama_tokenize(vocab, text.data(), text.length(), result.data(), result.size(), add_special, parse_special); if (n_tokens < 0) { result.resize(-n_tokens); int check = llama_tokenize(vocab, text.data(), text.length(), result.data(), result.size(), add_special, parse_special); GGML_ASSERT(check == -n_tokens); } else { result.resize(n_tokens); } return result; }
O0
cpp
common_tokenize(llama_vocab const*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, bool, bool): subq $0xb8, %rsp movq %rdi, 0x68(%rsp) movb %r8b, %al movq %rdi, %r8 movq %r8, 0x60(%rsp) movq %rdi, 0xb0(%rsp) movq %rsi, 0xa8(%rsp) movq %rdx, 0xa0(%rsp) andb $0x1, %cl movb %cl, 0x9f(%rsp) andb $0x1, %al movb %al, 0x9e(%rsp) movq 0xa0(%rsp), %rdi callq 0x5cae0 movzbl 0x9f(%rsp), %edx andl $0x1, %edx movl %eax, %ecx movl %ecx, %eax movl %edx, %ecx leal (%rax,%rcx,2), %eax movl %eax, 0x98(%rsp) movb $0x0, 0x97(%rsp) movslq 0x98(%rsp), %rax movq %rax, 0x70(%rsp) leaq 0x96(%rsp), %rdi movq %rdi, 0x78(%rsp) callq 0x68840 movq 0x68(%rsp), %rdi movq 0x70(%rsp), %rsi movq 0x78(%rsp), %rdx callq 0x102770 jmp 0xfabd7 leaq 0x96(%rsp), %rdi callq 0x6d320 movq 0xa8(%rsp), %rax movq %rax, 0x38(%rsp) movq 0xa0(%rsp), %rdi callq 0x5c4b0 movq %rax, 0x40(%rsp) movq 0xa0(%rsp), %rdi callq 0x5cae0 movq 0x68(%rsp), %rdi movl %eax, 0x4c(%rsp) callq 0x6e1e0 movq 0x68(%rsp), %rdi movq %rax, 0x50(%rsp) callq 0x6d0d0 movq 0x38(%rsp), %rdi movq 0x40(%rsp), %rsi movl 0x4c(%rsp), %edx movq 0x50(%rsp), %rcx movl %eax, %r8d movzbl 0x9f(%rsp), %r9d movzbl 0x9e(%rsp), %r10d andl $0x1, %r10d movq %rsp, %rax movl %r10d, (%rax) andl $0x1, %r9d callq 0x5d790 movl %eax, 0x5c(%rsp) jmp 0xfac6e movl 0x5c(%rsp), %eax movl %eax, 0x98(%rsp) cmpl $0x0, 0x98(%rsp) jge 0xfadb0 movq 0x68(%rsp), %rdi movl 0x98(%rsp), %eax negl %eax movslq %eax, %rsi callq 0x1027f0 jmp 0xfac9f movq 0xa8(%rsp), %rax movq %rax, 0x10(%rsp) movq 0xa0(%rsp), %rdi callq 0x5c4b0 movq %rax, 0x18(%rsp) movq 0xa0(%rsp), %rdi callq 0x5cae0 movq 0x68(%rsp), %rdi movl %eax, 0x24(%rsp) callq 0x6e1e0 movq 0x68(%rsp), %rdi movq %rax, 0x28(%rsp) callq 0x6d0d0 movq 0x10(%rsp), %rdi movq 0x18(%rsp), %rsi movl 0x24(%rsp), %edx movq 0x28(%rsp), %rcx movl %eax, %r8d movzbl 0x9f(%rsp), %r9d movzbl 0x9e(%rsp), %r10d andl $0x1, %r10d movq %rsp, %rax movl %r10d, (%rax) andl $0x1, %r9d callq 0x5d790 movl %eax, 0x34(%rsp) jmp 0xfad29 movl 0x34(%rsp), %eax movl %eax, 0x80(%rsp) movl 0x80(%rsp), %eax xorl %ecx, %ecx subl 0x98(%rsp), %ecx cmpl %ecx, %eax je 0xfadae leaq 0x11dcb6(%rip), %rdi # 0x218a05 leaq 0x1145ff(%rip), %rdx # 0x20f355 leaq 0x11e328(%rip), %rcx # 0x219085 xorl %eax, %eax movl $0x6b8, %esi # imm = 0x6B8 callq 0x5d050 jmp 0xfad6b movq %rax, %rcx movl %edx, %eax movq %rcx, 0x88(%rsp) movl %eax, 0x84(%rsp) leaq 0x96(%rsp), %rdi callq 0x6d320 jmp 0xfadef movq 0x68(%rsp), %rdi movq %rax, %rcx movl %edx, %eax movq %rcx, 0x88(%rsp) movl %eax, 0x84(%rsp) callq 0x66f50 jmp 0xfadef jmp 0xfadc6 movq 0x68(%rsp), %rdi movslq 0x98(%rsp), %rsi callq 0x1027f0 jmp 0xfadc4 jmp 0xfadc6 movb $0x1, 0x97(%rsp) testb $0x1, 0x97(%rsp) jne 0xfade2 movq 0x68(%rsp), %rdi callq 0x66f50 movq 0x60(%rsp), %rax addq $0xb8, %rsp retq movq 0x88(%rsp), %rdi callq 0x5ccd0 nopl (%rax)
_Z15common_tokenizePK11llama_vocabRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEbb: sub rsp, 0B8h mov [rsp+0B8h+var_50], rdi mov al, r8b mov r8, rdi mov [rsp+0B8h+var_58], r8 mov [rsp+0B8h+var_8], rdi mov [rsp+0B8h+var_10], rsi mov [rsp+0B8h+var_18], rdx and cl, 1 mov [rsp+0B8h+var_19], cl and al, 1 mov [rsp+0B8h+var_1A], al mov rdi, [rsp+0B8h+var_18] call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6lengthEv; std::string::length(void) movzx edx, [rsp+0B8h+var_19] and edx, 1 mov ecx, eax mov eax, ecx mov ecx, edx lea eax, [rax+rcx*2] mov [rsp+0B8h+var_20], eax mov [rsp+0B8h+var_21], 0 movsxd rax, [rsp+0B8h+var_20] mov [rsp+0B8h+var_48], rax lea rdi, [rsp+0B8h+var_22] mov [rsp+0B8h+var_40], rdi call _ZNSaIiEC2Ev; std::allocator<int>::allocator(void) mov rdi, [rsp+0B8h+var_50] mov rsi, [rsp+0B8h+var_48] mov rdx, [rsp+0B8h+var_40] call _ZNSt6vectorIiSaIiEEC2EmRKS0_; std::vector<int>::vector(ulong,std::allocator<int> const&) jmp short $+2 loc_FABD7: lea rdi, [rsp+0B8h+var_22] call _ZNSaIiED2Ev; std::allocator<int>::~allocator() mov rax, [rsp+0B8h+var_10] mov [rsp+0B8h+var_80], rax mov rdi, [rsp+0B8h+var_18] call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4dataEv; std::string::data(void) mov [rsp+0B8h+var_78], rax mov rdi, [rsp+0B8h+var_18] call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6lengthEv; std::string::length(void) mov rdi, [rsp+0B8h+var_50] mov [rsp+0B8h+var_6C], eax call _ZNSt6vectorIiSaIiEE4dataEv; std::vector<int>::data(void) mov rdi, [rsp+0B8h+var_50] mov [rsp+0B8h+var_68], rax call _ZNKSt6vectorIiSaIiEE4sizeEv; std::vector<int>::size(void) mov rdi, [rsp+0B8h+var_80] mov rsi, [rsp+0B8h+var_78] mov edx, [rsp+0B8h+var_6C] mov rcx, [rsp+0B8h+var_68] mov r8d, eax movzx r9d, [rsp+0B8h+var_19] movzx r10d, [rsp+0B8h+var_1A] and r10d, 1 mov rax, rsp mov [rax], r10d and r9d, 1 call _llama_tokenize mov [rsp+0B8h+var_5C], eax jmp short $+2 loc_FAC6E: mov eax, [rsp+0B8h+var_5C] mov [rsp+0B8h+var_20], eax cmp [rsp+0B8h+var_20], 0 jge loc_FADB0 mov rdi, [rsp+0B8h+var_50] mov eax, [rsp+0B8h+var_20] neg eax movsxd rsi, eax call _ZNSt6vectorIiSaIiEE6resizeEm; std::vector<int>::resize(ulong) jmp short $+2 loc_FAC9F: mov rax, [rsp+0B8h+var_10] mov [rsp+0B8h+var_A8], rax mov rdi, [rsp+0B8h+var_18] call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4dataEv; std::string::data(void) mov [rsp+0B8h+var_A0], rax mov rdi, [rsp+0B8h+var_18] call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6lengthEv; std::string::length(void) mov rdi, [rsp+0B8h+var_50] mov [rsp+0B8h+var_94], eax call _ZNSt6vectorIiSaIiEE4dataEv; std::vector<int>::data(void) mov rdi, [rsp+0B8h+var_50] mov [rsp+0B8h+var_90], rax call _ZNKSt6vectorIiSaIiEE4sizeEv; std::vector<int>::size(void) mov rdi, [rsp+0B8h+var_A8] mov rsi, [rsp+0B8h+var_A0] mov edx, [rsp+0B8h+var_94] mov rcx, [rsp+0B8h+var_90] mov r8d, eax movzx r9d, [rsp+0B8h+var_19] movzx r10d, [rsp+0B8h+var_1A] and r10d, 1 mov rax, rsp mov [rax], r10d and r9d, 1 call _llama_tokenize mov [rsp+0B8h+var_84], eax jmp short $+2 loc_FAD29: mov eax, [rsp+0B8h+var_84] mov [rsp+0B8h+var_38], eax mov eax, [rsp+0B8h+var_38] xor ecx, ecx sub ecx, [rsp+0B8h+var_20] cmp eax, ecx jz short loc_FADAE lea rdi, aWorkspaceLlm4b_4; "/workspace/llm4binary/github/2025_star3"... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aCheckNTokens; "check == -n_tokens" xor eax, eax mov esi, 6B8h call _ggml_abort jmp short $+2 loc_FAD6B: mov rcx, rax mov eax, edx mov [rsp+0B8h+var_30], rcx mov [rsp+0B8h+var_34], eax lea rdi, [rsp+0B8h+var_22] call _ZNSaIiED2Ev; std::allocator<int>::~allocator() jmp short loc_FADEF mov rdi, [rsp+0B8h+var_50] mov rcx, rax mov eax, edx mov [rsp+0B8h+var_30], rcx mov [rsp+0B8h+var_34], eax call _ZNSt6vectorIiSaIiEED2Ev; std::vector<int>::~vector() jmp short loc_FADEF loc_FADAE: jmp short loc_FADC6 loc_FADB0: mov rdi, [rsp+0B8h+var_50] movsxd rsi, [rsp+0B8h+var_20] call _ZNSt6vectorIiSaIiEE6resizeEm; std::vector<int>::resize(ulong) jmp short $+2 loc_FADC4: jmp short $+2 loc_FADC6: mov [rsp+0B8h+var_21], 1 test [rsp+0B8h+var_21], 1 jnz short loc_FADE2 mov rdi, [rsp+0B8h+var_50] call _ZNSt6vectorIiSaIiEED2Ev; std::vector<int>::~vector() loc_FADE2: mov rax, [rsp+0B8h+var_58] add rsp, 0B8h retn loc_FADEF: mov rdi, [rsp+0B8h+var_30] call __Unwind_Resume
_QWORD * common_tokenize(_QWORD *a1, long long a2, long long a3, char a4, char a5) { int v5; // ecx int v6; // r8d int v7; // r9d unsigned int v8; // eax unsigned int v9; // eax long long v11; // [rsp+10h] [rbp-A8h] long long v12; // [rsp+18h] [rbp-A0h] unsigned int v13; // [rsp+24h] [rbp-94h] long long v14; // [rsp+28h] [rbp-90h] long long v15; // [rsp+38h] [rbp-80h] long long v16; // [rsp+40h] [rbp-78h] unsigned int v17; // [rsp+4Ch] [rbp-6Ch] long long v18; // [rsp+50h] [rbp-68h] int v19; // [rsp+70h] [rbp-48h] int v20; // [rsp+80h] [rbp-38h] long long v21; // [rsp+88h] [rbp-30h] _BYTE v22[2]; // [rsp+96h] [rbp-22h] BYREF int v23; // [rsp+98h] [rbp-20h] char v24; // [rsp+9Eh] [rbp-1Ah] char v25; // [rsp+9Fh] [rbp-19h] long long v26; // [rsp+A0h] [rbp-18h] long long v27; // [rsp+A8h] [rbp-10h] _QWORD *v28; // [rsp+B0h] [rbp-8h] v28 = a1; v27 = a2; v26 = a3; v25 = a4 & 1; v24 = a5 & 1; v23 = std::string::length(a3) + 2 * (a4 & 1); v22[1] = 0; v19 = v23; std::allocator<int>::allocator((long long)v22); std::vector<int>::vector((_DWORD)a1, v19, (unsigned int)v22, v5, v6, v7); std::allocator<int>::~allocator((long long)v22); v15 = v27; v16 = std::string::data(v26); v17 = std::string::length(v26); v18 = std::vector<int>::data(a1); v8 = std::vector<int>::size(a1); v23 = llama_tokenize(v15, v16, v17, v18, v8, v25 & 1, v24 & 1); if ( v23 >= 0 ) { std::vector<int>::resize(a1, v23); } else { std::vector<int>::resize(a1, -v23); v11 = v27; v12 = std::string::data(v26); v13 = std::string::length(v26); v14 = std::vector<int>::data(a1); v9 = std::vector<int>::size(a1); v20 = llama_tokenize(v11, v12, v13, v14, v9, v25 & 1, v24 & 1); if ( v20 != -v23 ) { v21 = ggml_abort( "/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/common.cpp", 1720LL, "GGML_ASSERT(%s) failed", "check == -n_tokens"); std::allocator<int>::~allocator((long long)v22); _Unwind_Resume(v21); } } return a1; }
common_tokenize: SUB RSP,0xb8 MOV qword ptr [RSP + 0x68],RDI MOV AL,R8B MOV R8,RDI MOV qword ptr [RSP + 0x60],R8 MOV qword ptr [RSP + 0xb0],RDI MOV qword ptr [RSP + 0xa8],RSI MOV qword ptr [RSP + 0xa0],RDX AND CL,0x1 MOV byte ptr [RSP + 0x9f],CL AND AL,0x1 MOV byte ptr [RSP + 0x9e],AL MOV RDI,qword ptr [RSP + 0xa0] CALL 0x0015cae0 MOVZX EDX,byte ptr [RSP + 0x9f] AND EDX,0x1 MOV ECX,EAX MOV EAX,ECX MOV ECX,EDX LEA EAX,[RAX + RCX*0x2] MOV dword ptr [RSP + 0x98],EAX MOV byte ptr [RSP + 0x97],0x0 MOVSXD RAX,dword ptr [RSP + 0x98] MOV qword ptr [RSP + 0x70],RAX LEA RDI,[RSP + 0x96] MOV qword ptr [RSP + 0x78],RDI CALL 0x00168840 MOV RDI,qword ptr [RSP + 0x68] MOV RSI,qword ptr [RSP + 0x70] MOV RDX,qword ptr [RSP + 0x78] LAB_001fabd0: CALL 0x00202770 JMP 0x001fabd7 LAB_001fabd7: LEA RDI,[RSP + 0x96] CALL 0x0016d320 MOV RAX,qword ptr [RSP + 0xa8] MOV qword ptr [RSP + 0x38],RAX MOV RDI,qword ptr [RSP + 0xa0] CALL 0x0015c4b0 MOV qword ptr [RSP + 0x40],RAX MOV RDI,qword ptr [RSP + 0xa0] CALL 0x0015cae0 MOV RDI,qword ptr [RSP + 0x68] MOV dword ptr [RSP + 0x4c],EAX CALL 0x0016e1e0 MOV RDI,qword ptr [RSP + 0x68] MOV qword ptr [RSP + 0x50],RAX CALL 0x0016d0d0 MOV RDI,qword ptr [RSP + 0x38] MOV RSI,qword ptr [RSP + 0x40] MOV EDX,dword ptr [RSP + 0x4c] MOV RCX,qword ptr [RSP + 0x50] MOV R8D,EAX MOVZX R9D,byte ptr [RSP + 0x9f] MOVZX R10D,byte ptr [RSP + 0x9e] LAB_001fac55: AND R10D,0x1 MOV RAX,RSP MOV dword ptr [RAX],R10D AND R9D,0x1 CALL 0x0015d790 MOV dword ptr [RSP + 0x5c],EAX JMP 0x001fac6e LAB_001fac6e: MOV EAX,dword ptr [RSP + 0x5c] MOV dword ptr [RSP + 0x98],EAX CMP dword ptr [RSP + 0x98],0x0 JGE 0x001fadb0 MOV RDI,qword ptr [RSP + 0x68] MOV EAX,dword ptr [RSP + 0x98] NEG EAX MOVSXD RSI,EAX CALL 0x002027f0 JMP 0x001fac9f LAB_001fac9f: MOV RAX,qword ptr [RSP + 0xa8] MOV qword ptr [RSP + 0x10],RAX MOV RDI,qword ptr [RSP + 0xa0] CALL 0x0015c4b0 MOV qword ptr [RSP + 0x18],RAX MOV RDI,qword ptr [RSP + 0xa0] CALL 0x0015cae0 MOV RDI,qword ptr [RSP + 0x68] MOV dword ptr [RSP + 0x24],EAX CALL 0x0016e1e0 MOV RDI,qword ptr [RSP + 0x68] MOV qword ptr [RSP + 0x28],RAX CALL 0x0016d0d0 MOV RDI,qword ptr [RSP + 0x10] MOV RSI,qword ptr [RSP + 0x18] MOV EDX,dword ptr [RSP + 0x24] MOV RCX,qword ptr [RSP + 0x28] MOV R8D,EAX MOVZX R9D,byte ptr [RSP + 0x9f] MOVZX R10D,byte ptr [RSP + 0x9e] AND R10D,0x1 MOV RAX,RSP MOV dword ptr [RAX],R10D AND R9D,0x1 CALL 0x0015d790 MOV dword ptr [RSP + 0x34],EAX JMP 0x001fad29 LAB_001fad29: MOV EAX,dword ptr [RSP + 0x34] MOV dword ptr [RSP + 0x80],EAX MOV EAX,dword ptr [RSP + 0x80] XOR ECX,ECX SUB ECX,dword ptr [RSP + 0x98] CMP EAX,ECX JZ 0x001fadae LEA RDI,[0x318a05] LEA RDX,[0x30f355] LEA RCX,[0x319085] XOR EAX,EAX MOV ESI,0x6b8 CALL 0x0015d050 JMP 0x001fad6b LAB_001fad6b: MOV RCX,RAX MOV EAX,EDX MOV qword ptr [RSP + 0x88],RCX MOV dword ptr [RSP + 0x84],EAX LEA RDI,[RSP + 0x96] CALL 0x0016d320 JMP 0x001fadef LAB_001fadae: JMP 0x001fadc6 LAB_001fadb0: MOV RDI,qword ptr [RSP + 0x68] MOVSXD RSI,dword ptr [RSP + 0x98] CALL 0x002027f0 LAB_001fadc2: JMP 0x001fadc4 LAB_001fadc4: JMP 0x001fadc6 LAB_001fadc6: MOV byte ptr [RSP + 0x97],0x1 TEST byte ptr [RSP + 0x97],0x1 JNZ 0x001fade2 MOV RDI,qword ptr [RSP + 0x68] CALL 0x00166f50 LAB_001fade2: MOV RAX,qword ptr [RSP + 0x60] ADD RSP,0xb8 RET LAB_001fadef: MOV RDI,qword ptr [RSP + 0x88] CALL 0x0015ccd0
/* WARNING: Removing unreachable block (ram,0x001fadd8) */ /* common_tokenize(llama_vocab const*, std::__cxx11::string const&, bool, bool) */ llama_vocab * common_tokenize(llama_vocab *param_1,string *param_2,bool param_3,bool param_4) { string *psVar1; int4 uVar2; int4 uVar3; int iVar4; ulong uVar5; int8 uVar6; int8 uVar7; int7 in_register_00000011; byte in_R8B; allocator<int> local_22; int1 local_21; int local_20; byte local_1a; byte local_19; int8 local_18; string *local_10; llama_vocab *local_8; local_18 = CONCAT71(in_register_00000011,param_3); local_1a = in_R8B & 1; local_19 = param_4; local_10 = param_2; local_8 = param_1; local_20 = std::__cxx11::string::length(); local_20 = local_20 + (local_19 & 1) * 2; local_21 = 0; uVar5 = (ulong)local_20; std::allocator<int>::allocator(&local_22); /* try { // try from 001fabd0 to 001fabd4 has its CatchHandler @ 001fad6b */ std::vector<int,std::allocator<int>>::vector ((vector<int,std::allocator<int>> *)param_1,uVar5,(allocator *)&local_22); std::allocator<int>::~allocator(&local_22); psVar1 = local_10; uVar6 = std::__cxx11::string::data(); uVar2 = std::__cxx11::string::length(); uVar7 = std::vector<int,std::allocator<int>>::data((vector<int,std::allocator<int>> *)param_1); uVar3 = std::vector<int,std::allocator<int>>::size((vector<int,std::allocator<int>> *)param_1); /* try { // try from 001fac55 to 001fadc1 has its CatchHandler @ 001fad8e */ local_20 = llama_tokenize(psVar1,uVar6,uVar2,uVar7,uVar3,local_19 & 1,local_1a & 1); if (local_20 < 0) { std::vector<int,std::allocator<int>>::resize ((vector<int,std::allocator<int>> *)param_1,(long)-local_20); psVar1 = local_10; uVar6 = std::__cxx11::string::data(); uVar2 = std::__cxx11::string::length(); uVar7 = std::vector<int,std::allocator<int>>::data((vector<int,std::allocator<int>> *)param_1); uVar3 = std::vector<int,std::allocator<int>>::size((vector<int,std::allocator<int>> *)param_1); iVar4 = llama_tokenize(psVar1,uVar6,uVar2,uVar7,uVar3,local_19 & 1,local_1a & 1); if (iVar4 != -local_20) { uVar6 = ggml_abort("/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/common.cpp" ,0x6b8,"GGML_ASSERT(%s) failed","check == -n_tokens"); /* catch() { ... } // from try @ 001fabd0 with catch @ 001fad6b */ std::allocator<int>::~allocator(&local_22); /* WARNING: Subroutine does not return */ _Unwind_Resume(uVar6); } } else { std::vector<int,std::allocator<int>>::resize ((vector<int,std::allocator<int>> *)param_1,(long)local_20); } return param_1; }
6,029
common_tokenize(llama_vocab const*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, bool, bool)
monkey531[P]llama/common/common.cpp
std::vector<llama_token> common_tokenize( const struct llama_vocab * vocab, const std::string & text, bool add_special, bool parse_special) { // upper limit for the number of tokens int n_tokens = text.length() + 2 * add_special; std::vector<llama_token> result(n_tokens); n_tokens = llama_tokenize(vocab, text.data(), text.length(), result.data(), result.size(), add_special, parse_special); if (n_tokens < 0) { result.resize(-n_tokens); int check = llama_tokenize(vocab, text.data(), text.length(), result.data(), result.size(), add_special, parse_special); GGML_ASSERT(check == -n_tokens); } else { result.resize(n_tokens); } return result; }
O2
cpp
common_tokenize(llama_vocab const*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, bool, bool): pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x18, %rsp movl %r8d, %ebp movl %ecx, %r14d movq %rdx, %r12 movq %rsi, %r15 movq %rdi, %rbx leal (%r14,%r14), %eax addl 0x8(%rdx), %eax movslq %eax, %rsi leaq 0x17(%rsp), %rdx callq 0x5c29c movq (%r12), %rsi movl 0x8(%r12), %edx movq (%rbx), %rcx movq 0x8(%rbx), %r8 subq %rcx, %r8 shrq $0x2, %r8 movl %ebp, (%rsp) movq %r15, %rdi movl %r14d, %r9d callq 0x25320 movl %eax, %r13d testl %eax, %eax js 0x59bd6 movl %r13d, %esi movq %rbx, %rdi callq 0x5c2ee jmp 0x59c13 negl %r13d movq %rbx, %rdi movq %r13, %rsi callq 0x5c2ee movq (%r12), %rsi movl 0x8(%r12), %edx movq (%rbx), %rcx movq 0x8(%rbx), %r8 subq %rcx, %r8 shrq $0x2, %r8 movzbl %bpl, %eax movl %eax, (%rsp) movzbl %r14b, %r9d movq %r15, %rdi callq 0x25320 cmpl %r13d, %eax jne 0x59c25 movq %rbx, %rax addq $0x18, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq leaq 0x5c401(%rip), %rdi # 0xb602d leaq 0x537c1(%rip), %rdx # 0xad3f4 leaq 0x5ca70(%rip), %rcx # 0xb66aa movl $0x6b8, %esi # imm = 0x6B8 xorl %eax, %eax callq 0x25150 jmp 0x59c48 movq %rax, %r14 movq %rbx, %rdi callq 0x29d1a movq %r14, %rdi callq 0x25250
_Z15common_tokenizePK11llama_vocabRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEbb: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 18h mov ebp, r8d mov r14d, ecx mov r12, rdx mov r15, rsi mov rbx, rdi lea eax, [r14+r14] add eax, [rdx+8] movsxd rsi, eax lea rdx, [rsp+48h+var_31] call _ZNSt6vectorIiSaIiEEC2EmRKS0_; std::vector<int>::vector(ulong,std::allocator<int> const&) mov rsi, [r12] mov edx, [r12+8] mov rcx, [rbx] mov r8, [rbx+8] sub r8, rcx shr r8, 2 mov [rsp+48h+var_48], ebp mov rdi, r15 mov r9d, r14d call _llama_tokenize mov r13d, eax test eax, eax js short loc_59BD6 mov esi, r13d mov rdi, rbx call _ZNSt6vectorIiSaIiEE6resizeEm; std::vector<int>::resize(ulong) jmp short loc_59C13 loc_59BD6: neg r13d mov rdi, rbx mov rsi, r13 call _ZNSt6vectorIiSaIiEE6resizeEm; std::vector<int>::resize(ulong) mov rsi, [r12] mov edx, [r12+8] mov rcx, [rbx] mov r8, [rbx+8] sub r8, rcx shr r8, 2 movzx eax, bpl mov [rsp+48h+var_48], eax movzx r9d, r14b mov rdi, r15 call _llama_tokenize cmp eax, r13d jnz short loc_59C25 loc_59C13: mov rax, rbx add rsp, 18h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn loc_59C25: lea rdi, aWorkspaceLlm4b_4; "/workspace/llm4binary/github/2025_star3"... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aCheckNTokens; "check == -n_tokens" mov esi, 6B8h xor eax, eax call _ggml_abort jmp short $+2 loc_59C48: mov r14, rax mov rdi, rbx call _ZNSt12_Vector_baseIiSaIiEED2Ev; std::_Vector_base<int>::~_Vector_base() mov rdi, r14 call __Unwind_Resume
_QWORD * common_tokenize(_QWORD *a1, long long a2, _QWORD *a3, unsigned int a4, int a5) { int v8; // eax int v9; // r13d long long v11; // rax _BYTE v12[49]; // [rsp+17h] [rbp-31h] BYREF std::vector<int>::vector(a1, (int)(*((_DWORD *)a3 + 2) + 2 * a4), v12); v8 = llama_tokenize(a2, *a3, *((unsigned int *)a3 + 2), *a1, (a1[1] - *a1) >> 2, a4, a5); if ( v8 < 0 ) { v9 = -v8; std::vector<int>::resize(a1, (unsigned int)-v8); if ( (unsigned int)llama_tokenize( a2, *a3, *((unsigned int *)a3 + 2), *a1, (a1[1] - *a1) >> 2, (unsigned __int8)a4, (unsigned __int8)a5) != v9 ) { v11 = ggml_abort( "/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/common.cpp", 1720LL, "GGML_ASSERT(%s) failed", "check == -n_tokens"); std::_Vector_base<int>::~_Vector_base(a1); _Unwind_Resume(v11); } } else { std::vector<int>::resize(a1, (unsigned int)v8); } return a1; }
common_tokenize: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x18 MOV EBP,R8D MOV R14D,ECX MOV R12,RDX MOV R15,RSI MOV RBX,RDI LEA EAX,[R14 + R14*0x1] ADD EAX,dword ptr [RDX + 0x8] MOVSXD RSI,EAX LEA RDX,[RSP + 0x17] CALL 0x0015c29c MOV RSI,qword ptr [R12] MOV EDX,dword ptr [R12 + 0x8] MOV RCX,qword ptr [RBX] MOV R8,qword ptr [RBX + 0x8] SUB R8,RCX SHR R8,0x2 LAB_00159bb4: MOV dword ptr [RSP],EBP MOV RDI,R15 MOV R9D,R14D CALL 0x00125320 MOV R13D,EAX TEST EAX,EAX JS 0x00159bd6 MOV ESI,R13D MOV RDI,RBX CALL 0x0015c2ee JMP 0x00159c13 LAB_00159bd6: NEG R13D MOV RDI,RBX MOV RSI,R13 CALL 0x0015c2ee MOV RSI,qword ptr [R12] MOV EDX,dword ptr [R12 + 0x8] MOV RCX,qword ptr [RBX] MOV R8,qword ptr [RBX + 0x8] SUB R8,RCX SHR R8,0x2 LAB_00159bfb: MOVZX EAX,BPL MOV dword ptr [RSP],EAX MOVZX R9D,R14B MOV RDI,R15 CALL 0x00125320 CMP EAX,R13D JNZ 0x00159c25 LAB_00159c13: MOV RAX,RBX ADD RSP,0x18 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET LAB_00159c25: LEA RDI,[0x1b602d] LEA RDX,[0x1ad3f4] LEA RCX,[0x1b66aa] MOV ESI,0x6b8 XOR EAX,EAX CALL 0x00125150
/* common_tokenize(llama_vocab const*, std::__cxx11::string const&, bool, bool) */ llama_vocab * common_tokenize(llama_vocab *param_1,string *param_2,bool param_3,bool param_4) { uint uVar1; uint uVar2; int7 in_register_00000009; int7 in_register_00000011; int8 *puVar3; uint in_R8D; allocator local_31; puVar3 = (int8 *)CONCAT71(in_register_00000011,param_3); std::vector<int,std::allocator<int>>::vector ((vector<int,std::allocator<int>> *)param_1, (long)((int)CONCAT71(in_register_00000009,param_4) * 2 + *(int *)(puVar3 + 1)), &local_31); /* try { // try from 00159bb4 to 00159be3 has its CatchHandler @ 00159c48 */ uVar1 = llama_tokenize(param_2,*puVar3,*(int4 *)(puVar3 + 1),*(long *)param_1, (ulong)(*(long *)(param_1 + 8) - *(long *)param_1) >> 2, CONCAT71(in_register_00000009,param_4) & 0xffffffff,in_R8D); if ((int)uVar1 < 0) { std::vector<int,std::allocator<int>>::resize ((vector<int,std::allocator<int>> *)param_1,(ulong)-uVar1); /* try { // try from 00159bfb to 00159c45 has its CatchHandler @ 00159c46 */ uVar2 = llama_tokenize(param_2,*puVar3,*(int4 *)(puVar3 + 1),*(long *)param_1, (ulong)(*(long *)(param_1 + 8) - *(long *)param_1) >> 2,param_4, in_R8D & 0xff); if (uVar2 != -uVar1) { /* WARNING: Subroutine does not return */ ggml_abort("/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/common.cpp",0x6b8 ,"GGML_ASSERT(%s) failed","check == -n_tokens"); } } else { std::vector<int,std::allocator<int>>::resize ((vector<int,std::allocator<int>> *)param_1,(ulong)uVar1); } return param_1; }
6,030
evmone::instr::core::extcodecopy(evmone::StackTop, long, evmone::ExecutionState&)
corpus-core[P]colibri-stateless/build_O0/_deps/evmone_external-src/lib/evmone/instructions.hpp
inline Result extcodecopy(StackTop stack, int64_t gas_left, ExecutionState& state) noexcept { const auto addr = intx::be::trunc<evmc::address>(stack.pop()); const auto& mem_index = stack.pop(); const auto& input_index = stack.pop(); const auto& size = stack.pop(); if (!check_memory(gas_left, state.memory, mem_index, size)) return {EVMC_OUT_OF_GAS, gas_left}; const auto s = static_cast<size_t>(size); if (const auto cost = copy_cost(s); (gas_left -= cost) < 0) return {EVMC_OUT_OF_GAS, gas_left}; if (state.rev >= EVMC_BERLIN && state.host.access_account(addr) == EVMC_ACCESS_COLD) { if ((gas_left -= instr::additional_cold_account_access_cost) < 0) return {EVMC_OUT_OF_GAS, gas_left}; } if (s > 0) { const auto src = (max_buffer_size < input_index) ? max_buffer_size : static_cast<size_t>(input_index); const auto dst = static_cast<size_t>(mem_index); const auto num_bytes_copied = state.host.copy_code(addr, src, &state.memory[dst], s); if (const auto num_bytes_to_clear = s - num_bytes_copied; num_bytes_to_clear > 0) std::memset(&state.memory[dst + num_bytes_copied], 0, num_bytes_to_clear); } return {EVMC_SUCCESS, gas_left}; }
O0
cpp
evmone::instr::core::extcodecopy(evmone::StackTop, long, evmone::ExecutionState&): pushq %rbp movq %rsp, %rbp subq $0xa0, %rsp movq %rdi, -0x18(%rbp) movq %rsi, -0x20(%rbp) movq %rdx, -0x28(%rbp) leaq -0x18(%rbp), %rdi callq 0x611b0 movq %rax, %rsi leaq -0x3c(%rbp), %rdi callq 0x68cf0 leaq -0x18(%rbp), %rdi callq 0x611b0 movq %rax, -0x48(%rbp) leaq -0x18(%rbp), %rdi callq 0x611b0 movq %rax, -0x50(%rbp) leaq -0x18(%rbp), %rdi callq 0x611b0 movq %rax, -0x58(%rbp) movq -0x28(%rbp), %rsi addq $0x8, %rsi movq -0x48(%rbp), %rdx movq -0x58(%rbp), %rcx leaq -0x20(%rbp), %rdi callq 0x68460 testb $0x1, %al jne 0x696b4 movl $0x3, -0x10(%rbp) movq -0x20(%rbp), %rax movq %rax, -0x8(%rbp) jmp 0x69835 movq -0x58(%rbp), %rdi callq 0x68550 movq %rax, -0x60(%rbp) movq -0x60(%rbp), %rdi callq 0x692b0 movq %rax, -0x68(%rbp) movq -0x68(%rbp), %rcx movq -0x20(%rbp), %rax subq %rcx, %rax movq %rax, -0x20(%rbp) cmpq $0x0, %rax jge 0x696f7 movl $0x3, -0x10(%rbp) movq -0x20(%rbp), %rax movq %rax, -0x8(%rbp) jmp 0x69835 movq -0x28(%rbp), %rax cmpl $0x8, 0x40(%rax) jl 0x69741 movq -0x28(%rbp), %rdi addq $0x28, %rdi leaq -0x3c(%rbp), %rsi callq 0x3b8e0 cmpl $0x0, %eax jne 0x69741 movq -0x20(%rbp), %rax subq $0x9c4, %rax # imm = 0x9C4 movq %rax, -0x20(%rbp) cmpq $0x0, %rax jge 0x6973f movl $0x3, -0x10(%rbp) movq -0x20(%rbp), %rax movq %rax, -0x8(%rbp) jmp 0x69835 jmp 0x69741 cmpq $0x0, -0x60(%rbp) jbe 0x69826 movq -0x50(%rbp), %rsi leaq 0x758a9(%rip), %rdi # 0xdf000 callq 0x69850 testb $0x1, %al jne 0x69762 jmp 0x69770 movl $0xffffffff, %eax # imm = 0xFFFFFFFF movq %rax, -0x90(%rbp) jmp 0x69780 movq -0x50(%rbp), %rdi callq 0x68550 movq %rax, -0x90(%rbp) movq -0x90(%rbp), %rax movq %rax, -0x70(%rbp) movq -0x48(%rbp), %rdi callq 0x68550 movq %rax, -0x78(%rbp) movq -0x28(%rbp), %rax addq $0x28, %rax movq %rax, -0xa0(%rbp) movq -0x70(%rbp), %rax movq %rax, -0x98(%rbp) movq -0x28(%rbp), %rdi addq $0x8, %rdi movq -0x78(%rbp), %rsi callq 0x60120 movq -0xa0(%rbp), %rdi movq -0x98(%rbp), %rdx movq %rax, %rcx movq -0x60(%rbp), %r8 leaq -0x3c(%rbp), %rsi callq 0x3b6b0 movq %rax, -0x80(%rbp) movq -0x60(%rbp), %rax subq -0x80(%rbp), %rax movq %rax, -0x88(%rbp) cmpq $0x0, -0x88(%rbp) jbe 0x69824 movq -0x28(%rbp), %rdi addq $0x8, %rdi movq -0x78(%rbp), %rsi addq -0x80(%rbp), %rsi callq 0x60120 movq %rax, %rdi movq -0x88(%rbp), %rdx xorl %esi, %esi callq 0x231c0 jmp 0x69826 movl $0x0, -0x10(%rbp) movq -0x20(%rbp), %rax movq %rax, -0x8(%rbp) movl -0x10(%rbp), %eax movq -0x8(%rbp), %rdx addq $0xa0, %rsp popq %rbp retq nopw %cs:(%rax,%rax) nop
_ZN6evmone5instr4core11extcodecopyENS_8StackTopElRNS_14ExecutionStateE: push rbp mov rbp, rsp sub rsp, 0A0h mov [rbp+var_18], rdi mov [rbp+var_20], rsi mov [rbp+var_28], rdx lea rdi, [rbp+var_18]; this call _ZN6evmone8StackTop3popEv; evmone::StackTop::pop(void) mov rsi, rax lea rdi, [rbp+var_3C] call _ZN4intx2be5truncIN4evmc7addressELj256EEET_RKNS_4uintIXT0_EEE; intx::be::trunc<evmc::address,256u>(intx::uint<256u> const&) lea rdi, [rbp+var_18]; this call _ZN6evmone8StackTop3popEv; evmone::StackTop::pop(void) mov [rbp+var_48], rax lea rdi, [rbp+var_18]; this call _ZN6evmone8StackTop3popEv; evmone::StackTop::pop(void) mov [rbp+var_50], rax lea rdi, [rbp+var_18]; this call _ZN6evmone8StackTop3popEv; evmone::StackTop::pop(void) mov [rbp+var_58], rax mov rsi, [rbp+var_28] add rsi, 8; unsigned __int64 mov rdx, [rbp+var_48] mov rcx, [rbp+var_58] lea rdi, [rbp+var_20] call _ZN6evmone12check_memoryERlRNS_6MemoryERKN4intx4uintILj256EEES7_; evmone::check_memory(long &,evmone::Memory &,intx::uint<256u> const&,intx::uint<256u> const&) test al, 1 jnz short loc_696B4 mov [rbp+var_10], 3 mov rax, [rbp+var_20] mov [rbp+var_8], rax jmp loc_69835 loc_696B4: mov rdi, [rbp+var_58] call _ZNK4intx4uintILj256EEcvT_ImvEEv; intx::uint<256u>::operator ulong<ulong,void>(void) mov [rbp+var_60], rax mov rdi, [rbp+var_60]; this call _ZN6evmone9copy_costEm; evmone::copy_cost(ulong) mov [rbp+var_68], rax mov rcx, [rbp+var_68] mov rax, [rbp+var_20] sub rax, rcx mov [rbp+var_20], rax cmp rax, 0 jge short loc_696F7 mov [rbp+var_10], 3 mov rax, [rbp+var_20] mov [rbp+var_8], rax jmp loc_69835 loc_696F7: mov rax, [rbp+var_28] cmp dword ptr [rax+40h], 8 jl short loc_69741 mov rdi, [rbp+var_28] add rdi, 28h ; '(' lea rsi, [rbp+var_3C] call _ZN4evmc11HostContext14access_accountERKNS_7addressE; evmc::HostContext::access_account(evmc::address const&) cmp eax, 0 jnz short loc_69741 mov rax, [rbp+var_20] sub rax, 9C4h mov [rbp+var_20], rax cmp rax, 0 jge short loc_6973F mov [rbp+var_10], 3 mov rax, [rbp+var_20] mov [rbp+var_8], rax jmp loc_69835 loc_6973F: jmp short $+2 loc_69741: cmp [rbp+var_60], 0 jbe loc_69826 mov rsi, [rbp+var_50] lea rdi, _ZN6evmoneL15max_buffer_sizeE; evmone::max_buffer_size call _ZN4intxltILj256EjvEEbRKT0_RKNS_4uintIXT_EEE; intx::operator<<256u,uint,void>(uint const&,intx::uint<256u> const&) test al, 1 jnz short loc_69762 jmp short loc_69770 loc_69762: mov eax, 0FFFFFFFFh mov [rbp+var_90], rax jmp short loc_69780 loc_69770: mov rdi, [rbp+var_50] call _ZNK4intx4uintILj256EEcvT_ImvEEv; intx::uint<256u>::operator ulong<ulong,void>(void) mov [rbp+var_90], rax loc_69780: mov rax, [rbp+var_90] mov [rbp+var_70], rax mov rdi, [rbp+var_48] call _ZNK4intx4uintILj256EEcvT_ImvEEv; intx::uint<256u>::operator ulong<ulong,void>(void) mov [rbp+var_78], rax mov rax, [rbp+var_28] add rax, 28h ; '(' mov [rbp+var_A0], rax mov rax, [rbp+var_70] mov [rbp+var_98], rax mov rdi, [rbp+var_28] add rdi, 8 mov rsi, [rbp+var_78] call _ZN6evmone6MemoryixEm; evmone::Memory::operator[](ulong) mov rdi, [rbp+var_A0] mov rdx, [rbp+var_98] mov rcx, rax mov r8, [rbp+var_60] lea rsi, [rbp+var_3C] call _ZNK4evmc11HostContext9copy_codeERKNS_7addressEmPhm; evmc::HostContext::copy_code(evmc::address const&,ulong,uchar *,ulong) mov [rbp+var_80], rax mov rax, [rbp+var_60] sub rax, [rbp+var_80] mov [rbp+var_88], rax cmp [rbp+var_88], 0 jbe short loc_69824 mov rdi, [rbp+var_28] add rdi, 8 mov rsi, [rbp+var_78] add rsi, [rbp+var_80] call _ZN6evmone6MemoryixEm; evmone::Memory::operator[](ulong) mov rdi, rax mov rdx, [rbp+var_88] xor esi, esi call _memset loc_69824: jmp short $+2 loc_69826: mov [rbp+var_10], 0 mov rax, [rbp+var_20] mov [rbp+var_8], rax loc_69835: mov eax, [rbp+var_10] mov rdx, [rbp+var_8] add rsp, 0A0h pop rbp retn
long long evmone::instr::core::extcodecopy(long long a1, long long a2, long long a3) { long long v3; // rax unsigned long long v4; // rcx long long v5; // rax long long v7; // [rsp+0h] [rbp-A0h] long long v8; // [rsp+20h] [rbp-80h] long long v9; // [rsp+28h] [rbp-78h] evmone *v10; // [rsp+40h] [rbp-60h] long long v11; // [rsp+48h] [rbp-58h] long long v12; // [rsp+50h] [rbp-50h] long long v13; // [rsp+58h] [rbp-48h] _BYTE v14[20]; // [rsp+64h] [rbp-3Ch] BYREF long long v15; // [rsp+78h] [rbp-28h] long long v16; // [rsp+80h] [rbp-20h] BYREF long long v17; // [rsp+88h] [rbp-18h] BYREF unsigned int v18; // [rsp+90h] [rbp-10h] long long v19; // [rsp+98h] [rbp-8h] v17 = a1; v16 = a2; v15 = a3; v3 = evmone::StackTop::pop((evmone::StackTop *)&v17); intx::be::trunc<evmc::address,256u>((long long)v14, v3); v13 = evmone::StackTop::pop((evmone::StackTop *)&v17); v12 = evmone::StackTop::pop((evmone::StackTop *)&v17); v11 = evmone::StackTop::pop((evmone::StackTop *)&v17); if ( (evmone::check_memory((long long)&v16, v15 + 8, v13, v11) & 1) != 0 ) { v10 = (evmone *)intx::uint<256u>::operator unsigned long<unsigned long,void>(v11); v4 = evmone::copy_cost(v10); v16 -= v4; if ( v16 >= 0 ) { if ( *(int *)(v15 + 64) < 8 || (unsigned int)evmc::HostContext::access_account(v15 + 40) || (v16 -= 2500LL, v16 >= 0) ) { if ( v10 ) { if ( (intx::operator<<256u,unsigned int,void>(&evmone::max_buffer_size, v12) & 1) == 0 ) intx::uint<256u>::operator unsigned long<unsigned long,void>(v12); v9 = intx::uint<256u>::operator unsigned long<unsigned long,void>(v13); v7 = v15 + 40; evmone::Memory::operator[](v15 + 8, v9); v8 = evmc::HostContext::copy_code(v7); if ( v10 != (evmone *)v8 ) { v5 = evmone::Memory::operator[](v15 + 8, v8 + v9); memset(v5, 0LL, (char *)v10 - v8); } } v18 = 0; v19 = v16; } else { v18 = 3; v19 = v16; } } else { v18 = 3; v19 = v16; } } else { v18 = 3; v19 = v16; } return v18; }
extcodecopy: PUSH RBP MOV RBP,RSP SUB RSP,0xa0 MOV qword ptr [RBP + -0x18],RDI MOV qword ptr [RBP + -0x20],RSI MOV qword ptr [RBP + -0x28],RDX LEA RDI,[RBP + -0x18] CALL 0x001611b0 MOV RSI,RAX LEA RDI,[RBP + -0x3c] CALL 0x00168cf0 LEA RDI,[RBP + -0x18] CALL 0x001611b0 MOV qword ptr [RBP + -0x48],RAX LEA RDI,[RBP + -0x18] CALL 0x001611b0 MOV qword ptr [RBP + -0x50],RAX LEA RDI,[RBP + -0x18] CALL 0x001611b0 MOV qword ptr [RBP + -0x58],RAX MOV RSI,qword ptr [RBP + -0x28] ADD RSI,0x8 MOV RDX,qword ptr [RBP + -0x48] MOV RCX,qword ptr [RBP + -0x58] LEA RDI,[RBP + -0x20] CALL 0x00168460 TEST AL,0x1 JNZ 0x001696b4 MOV dword ptr [RBP + -0x10],0x3 MOV RAX,qword ptr [RBP + -0x20] MOV qword ptr [RBP + -0x8],RAX JMP 0x00169835 LAB_001696b4: MOV RDI,qword ptr [RBP + -0x58] CALL 0x00168550 MOV qword ptr [RBP + -0x60],RAX MOV RDI,qword ptr [RBP + -0x60] CALL 0x001692b0 MOV qword ptr [RBP + -0x68],RAX MOV RCX,qword ptr [RBP + -0x68] MOV RAX,qword ptr [RBP + -0x20] SUB RAX,RCX MOV qword ptr [RBP + -0x20],RAX CMP RAX,0x0 JGE 0x001696f7 MOV dword ptr [RBP + -0x10],0x3 MOV RAX,qword ptr [RBP + -0x20] MOV qword ptr [RBP + -0x8],RAX JMP 0x00169835 LAB_001696f7: MOV RAX,qword ptr [RBP + -0x28] CMP dword ptr [RAX + 0x40],0x8 JL 0x00169741 MOV RDI,qword ptr [RBP + -0x28] ADD RDI,0x28 LEA RSI,[RBP + -0x3c] CALL 0x0013b8e0 CMP EAX,0x0 JNZ 0x00169741 MOV RAX,qword ptr [RBP + -0x20] SUB RAX,0x9c4 MOV qword ptr [RBP + -0x20],RAX CMP RAX,0x0 JGE 0x0016973f MOV dword ptr [RBP + -0x10],0x3 MOV RAX,qword ptr [RBP + -0x20] MOV qword ptr [RBP + -0x8],RAX JMP 0x00169835 LAB_0016973f: JMP 0x00169741 LAB_00169741: CMP qword ptr [RBP + -0x60],0x0 JBE 0x00169826 MOV RSI,qword ptr [RBP + -0x50] LEA RDI,[0x1df000] CALL 0x00169850 TEST AL,0x1 JNZ 0x00169762 JMP 0x00169770 LAB_00169762: MOV EAX,0xffffffff MOV qword ptr [RBP + -0x90],RAX JMP 0x00169780 LAB_00169770: MOV RDI,qword ptr [RBP + -0x50] CALL 0x00168550 MOV qword ptr [RBP + -0x90],RAX LAB_00169780: MOV RAX,qword ptr [RBP + -0x90] MOV qword ptr [RBP + -0x70],RAX MOV RDI,qword ptr [RBP + -0x48] CALL 0x00168550 MOV qword ptr [RBP + -0x78],RAX MOV RAX,qword ptr [RBP + -0x28] ADD RAX,0x28 MOV qword ptr [RBP + -0xa0],RAX MOV RAX,qword ptr [RBP + -0x70] MOV qword ptr [RBP + -0x98],RAX MOV RDI,qword ptr [RBP + -0x28] ADD RDI,0x8 MOV RSI,qword ptr [RBP + -0x78] CALL 0x00160120 MOV RDI,qword ptr [RBP + -0xa0] MOV RDX,qword ptr [RBP + -0x98] MOV RCX,RAX MOV R8,qword ptr [RBP + -0x60] LEA RSI,[RBP + -0x3c] CALL 0x0013b6b0 MOV qword ptr [RBP + -0x80],RAX MOV RAX,qword ptr [RBP + -0x60] SUB RAX,qword ptr [RBP + -0x80] MOV qword ptr [RBP + -0x88],RAX CMP qword ptr [RBP + -0x88],0x0 JBE 0x00169824 MOV RDI,qword ptr [RBP + -0x28] ADD RDI,0x8 MOV RSI,qword ptr [RBP + -0x78] ADD RSI,qword ptr [RBP + -0x80] CALL 0x00160120 MOV RDI,RAX MOV RDX,qword ptr [RBP + -0x88] XOR ESI,ESI CALL 0x001231c0 LAB_00169824: JMP 0x00169826 LAB_00169826: MOV dword ptr [RBP + -0x10],0x0 MOV RAX,qword ptr [RBP + -0x20] MOV qword ptr [RBP + -0x8],RAX LAB_00169835: MOV EAX,dword ptr [RBP + -0x10] MOV RDX,qword ptr [RBP + -0x8] ADD RSP,0xa0 POP RBP RET
/* evmone::instr::core::extcodecopy(evmone::StackTop, long, evmone::ExecutionState&) */ int1 [16] evmone::instr::core::extcodecopy(int8 param_1,long param_2,long param_3) { bool bVar1; int iVar2; uint *puVar3; uint *this; uint *this_00; ulong uVar4; long lVar5; ulong uVar6; HostContext *this_01; uchar *puVar7; void *__s; int1 auVar8 [16]; ulong local_98; be local_44 [20]; long local_30; long local_28; int8 local_20; uint local_18; long local_10; local_30 = param_3; local_28 = param_2; local_20 = param_1; puVar3 = (uint *)StackTop::pop((StackTop *)&local_20); intx::be::trunc<evmc::address,256u>(local_44,puVar3); puVar3 = (uint *)StackTop::pop((StackTop *)&local_20); this = (uint *)StackTop::pop((StackTop *)&local_20); this_00 = (uint *)StackTop::pop((StackTop *)&local_20); uVar4 = check_memory(&local_28,(Memory *)(local_30 + 8),puVar3,this_00); if ((uVar4 & 1) == 0) { local_18 = 3; local_10 = local_28; } else { uVar4 = intx::uint::operator_cast_to_unsigned_long(this_00); lVar5 = copy_cost(uVar4); local_28 = local_28 - lVar5; if (local_28 < 0) { local_18 = 3; local_10 = local_28; } else if (((*(int *)(local_30 + 0x40) < 8) || (iVar2 = evmc::HostContext::access_account ((HostContext *)(local_30 + 0x28),(address *)local_44), iVar2 != 0)) || (local_28 = local_28 + -0x9c4, -1 < local_28)) { if (uVar4 != 0) { bVar1 = intx::operator<(&max_buffer_size,this); if (bVar1) { local_98 = 0xffffffff; } else { local_98 = intx::uint::operator_cast_to_unsigned_long(this); } uVar6 = intx::uint::operator_cast_to_unsigned_long(puVar3); this_01 = (HostContext *)(local_30 + 0x28); puVar7 = (uchar *)Memory::operator[]((Memory *)(local_30 + 8),uVar6); lVar5 = evmc::HostContext::copy_code(this_01,(address *)local_44,local_98,puVar7,uVar4); if (uVar4 - lVar5 != 0) { __s = (void *)Memory::operator[]((Memory *)(local_30 + 8),uVar6 + lVar5); memset(__s,0,uVar4 - lVar5); } } local_18 = 0; local_10 = local_28; } else { local_18 = 3; local_10 = local_28; } } auVar8._4_4_ = 0; auVar8._0_4_ = local_18; auVar8._8_8_ = local_10; return auVar8; }
6,031
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; }
O0
c
psi_mutex_lock: pushq %rbp movq %rsp, %rbp subq $0x60, %rsp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movl %edx, -0x14(%rbp) leaq 0x1abe7e(%rip), %rax # 0x1dd8b8 movq (%rax), %rax movq 0x190(%rax), %rax movq -0x8(%rbp), %rcx movq 0x40(%rcx), %rsi movq -0x10(%rbp), %rcx movl -0x14(%rbp), %r8d leaq -0x48(%rbp), %rdi xorl %edx, %edx callq *%rax movq %rax, -0x50(%rbp) movq -0x8(%rbp), %rdi callq 0x243f0 movl %eax, -0x54(%rbp) cmpq $0x0, -0x50(%rbp) je 0x31a8d leaq 0x1abe3e(%rip), %rax # 0x1dd8b8 movq (%rax), %rax movq 0x198(%rax), %rax movq -0x50(%rbp), %rdi movl -0x54(%rbp), %esi callq *%rax movl -0x54(%rbp), %eax addq $0x60, %rsp popq %rbp retq nopw %cs:(%rax,%rax)
psi_mutex_lock: push rbp mov rbp, rsp sub rsp, 60h mov [rbp+var_8], rdi mov [rbp+var_10], rsi mov [rbp+var_14], edx lea rax, PSI_server mov rax, [rax] mov rax, [rax+190h] mov rcx, [rbp+var_8] mov rsi, [rcx+40h] mov rcx, [rbp+var_10] mov r8d, [rbp+var_14] lea rdi, [rbp+var_48] xor edx, edx call rax mov [rbp+var_50], rax mov rdi, [rbp+var_8] call _pthread_mutex_lock mov [rbp+var_54], eax cmp [rbp+var_50], 0 jz short loc_31A8D lea rax, PSI_server mov rax, [rax] mov rax, [rax+198h] mov rdi, [rbp+var_50] mov esi, [rbp+var_54] call rax loc_31A8D: mov eax, [rbp+var_54] add rsp, 60h pop rbp retn
long long psi_mutex_lock(long long a1, long long a2, unsigned int a3) { unsigned int v4; // [rsp+Ch] [rbp-54h] long long v5; // [rsp+10h] [rbp-50h] _BYTE v6[52]; // [rsp+18h] [rbp-48h] BYREF unsigned int v7; // [rsp+4Ch] [rbp-14h] long long v8; // [rsp+50h] [rbp-10h] long long v9; // [rsp+58h] [rbp-8h] v9 = a1; v8 = a2; v7 = a3; v5 = (*((long long ( **)(_BYTE *, _QWORD, _QWORD, long long, _QWORD))PSI_server[0] + 50))( v6, *(_QWORD *)(a1 + 64), 0LL, a2, a3); v4 = pthread_mutex_lock(v9); if ( v5 ) (*((void ( **)(long long, _QWORD))PSI_server[0] + 51))(v5, v4); return v4; }
psi_mutex_lock: PUSH RBP MOV RBP,RSP SUB RSP,0x60 MOV qword ptr [RBP + -0x8],RDI MOV qword ptr [RBP + -0x10],RSI MOV dword ptr [RBP + -0x14],EDX LEA RAX,[0x2dd8b8] MOV RAX,qword ptr [RAX] MOV RAX,qword ptr [RAX + 0x190] MOV RCX,qword ptr [RBP + -0x8] MOV RSI,qword ptr [RCX + 0x40] MOV RCX,qword ptr [RBP + -0x10] MOV R8D,dword ptr [RBP + -0x14] LEA RDI,[RBP + -0x48] XOR EDX,EDX CALL RAX MOV qword ptr [RBP + -0x50],RAX MOV RDI,qword ptr [RBP + -0x8] CALL 0x001243f0 MOV dword ptr [RBP + -0x54],EAX CMP qword ptr [RBP + -0x50],0x0 JZ 0x00131a8d LEA RAX,[0x2dd8b8] MOV RAX,qword ptr [RAX] MOV RAX,qword ptr [RAX + 0x198] MOV RDI,qword ptr [RBP + -0x50] MOV ESI,dword ptr [RBP + -0x54] CALL RAX LAB_00131a8d: MOV EAX,dword ptr [RBP + -0x54] ADD RSP,0x60 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 [52]; int4 local_1c; int8 local_18; pthread_mutex_t *local_10; local_1c = param_3; local_18 = param_2; local_10 = param_1; lVar2 = (**(code **)(PSI_server + 400)) (local_50,*(int8 *)((long)param_1 + 0x40),0,param_2,param_3); iVar1 = pthread_mutex_lock(local_10); if (lVar2 != 0) { (**(code **)(PSI_server + 0x198))(lVar2,iVar1); } return iVar1; }
6,032
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 0x2d51a9(%rip), %r15 # 0x2f98b8 movq (%r15), %rax movq 0x40(%rdi), %rsi leaq -0x48(%rbp), %rdi xorl %edx, %edx callq *0x190(%rax) movq %rax, %rbx movq %r14, %rdi callq 0x24430 movl %eax, %r14d testq %rbx, %rbx je 0x24744 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_24744 mov rax, [r15] mov rdi, rbx mov esi, r14d call qword ptr [rax+198h] loc_24744: 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[0] + 50))( v6, *(_QWORD *)(a1 + 64), 0LL, a2, a3); v4 = pthread_mutex_lock(a1); if ( v3 ) (*((void ( **)(long long, _QWORD))PSI_server[0] + 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,[0x3f98b8] 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 0x00124430 MOV R14D,EAX TEST RBX,RBX JZ 0x00124744 MOV RAX,qword ptr [R15] MOV RDI,RBX MOV ESI,R14D CALL qword ptr [RAX + 0x198] LAB_00124744: 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; }
6,033
LefDefParser::lefiGeometries::clearPolyItems()
Efficient-TDP/thirdparty/Limbo/limbo/thirdparty/lefdef/5.8/lef/lef/lefiMisc.cpp
void lefiGeometries::clearPolyItems() { lefFree((char*) (items_)); lefFree((char*) (itemType_)); if (x_) { lefFree((double*) (x_)); lefFree((double*) (y_)); } numPoints_ = 0; pointsAllocated_ = 0; numItems_ = 0; }
O0
cpp
LefDefParser::lefiGeometries::clearPolyItems(): subq $0x18, %rsp movq %rdi, 0x10(%rsp) movq 0x10(%rsp), %rax movq %rax, 0x8(%rsp) movq 0x10(%rax), %rdi callq 0x52810 movq 0x8(%rsp), %rax movq 0x8(%rax), %rdi callq 0x52810 movq 0x8(%rsp), %rax cmpq $0x0, 0x20(%rax) je 0xfa22 movq 0x8(%rsp), %rax movq 0x20(%rax), %rdi callq 0x52810 movq 0x8(%rsp), %rax movq 0x28(%rax), %rdi callq 0x52810 movq 0x8(%rsp), %rax movl $0x0, 0x18(%rax) movl $0x0, 0x1c(%rax) movl $0x0, (%rax) addq $0x18, %rsp retq
_ZN12LefDefParser14lefiGeometries14clearPolyItemsEv: sub rsp, 18h mov [rsp+18h+var_8], rdi mov rax, [rsp+18h+var_8] mov [rsp+18h+var_10], rax mov rdi, [rax+10h]; this call _ZN12LefDefParser7lefFreeEPv; LefDefParser::lefFree(void *) mov rax, [rsp+18h+var_10] mov rdi, [rax+8]; this call _ZN12LefDefParser7lefFreeEPv; LefDefParser::lefFree(void *) mov rax, [rsp+18h+var_10] cmp qword ptr [rax+20h], 0 jz short loc_FA22 mov rax, [rsp+18h+var_10] mov rdi, [rax+20h]; this call _ZN12LefDefParser7lefFreeEPv; LefDefParser::lefFree(void *) mov rax, [rsp+18h+var_10] mov rdi, [rax+28h]; this call _ZN12LefDefParser7lefFreeEPv; LefDefParser::lefFree(void *) loc_FA22: mov rax, [rsp+18h+var_10] mov dword ptr [rax+18h], 0 mov dword ptr [rax+1Ch], 0 mov dword ptr [rax], 0 add rsp, 18h retn
LefDefParser ** LefDefParser::lefiGeometries::clearPolyItems(LefDefParser **this, void *a2) { LefDefParser **result; // rax LefDefParser::lefFree(this[2], a2); LefDefParser::lefFree(this[1], a2); if ( this[4] ) { LefDefParser::lefFree(this[4], a2); LefDefParser::lefFree(this[5], a2); } result = this; *((_DWORD *)this + 6) = 0; *((_DWORD *)this + 7) = 0; *(_DWORD *)this = 0; return result; }
clearPolyItems: SUB RSP,0x18 MOV qword ptr [RSP + 0x10],RDI MOV RAX,qword ptr [RSP + 0x10] MOV qword ptr [RSP + 0x8],RAX MOV RDI,qword ptr [RAX + 0x10] CALL 0x00152810 MOV RAX,qword ptr [RSP + 0x8] MOV RDI,qword ptr [RAX + 0x8] CALL 0x00152810 MOV RAX,qword ptr [RSP + 0x8] CMP qword ptr [RAX + 0x20],0x0 JZ 0x0010fa22 MOV RAX,qword ptr [RSP + 0x8] MOV RDI,qword ptr [RAX + 0x20] CALL 0x00152810 MOV RAX,qword ptr [RSP + 0x8] MOV RDI,qword ptr [RAX + 0x28] CALL 0x00152810 LAB_0010fa22: MOV RAX,qword ptr [RSP + 0x8] MOV dword ptr [RAX + 0x18],0x0 MOV dword ptr [RAX + 0x1c],0x0 MOV dword ptr [RAX],0x0 ADD RSP,0x18 RET
/* LefDefParser::lefiGeometries::clearPolyItems() */ void __thiscall LefDefParser::lefiGeometries::clearPolyItems(lefiGeometries *this) { lefFree(*(void **)(this + 0x10)); lefFree(*(void **)(this + 8)); if (*(long *)(this + 0x20) != 0) { lefFree(*(void **)(this + 0x20)); lefFree(*(void **)(this + 0x28)); } *(int4 *)(this + 0x18) = 0; *(int4 *)(this + 0x1c) = 0; *(int4 *)this = 0; return; }
6,034
ggml_compute_forward_ssm_scan
Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml-cpu/ggml-cpu.c
static void ggml_compute_forward_ssm_scan( const struct ggml_compute_params * params, struct ggml_tensor * dst) { switch (dst->src[0]->type) { case GGML_TYPE_F32: { ggml_compute_forward_ssm_scan_f32(params, dst); } break; default: { GGML_ABORT("fatal error"); } } }
O0
c
ggml_compute_forward_ssm_scan: pushq %rbp movq %rsp, %rbp subq $0x10, %rsp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq -0x10(%rbp), %rax movq 0x98(%rax), %rax movl (%rax), %eax testl %eax, %eax jne 0x190c2 jmp 0x190b3 movq -0x8(%rbp), %rdi movq -0x10(%rbp), %rsi callq 0x37f20 jmp 0x190dc leaq 0x5aa99(%rip), %rdi # 0x73b62 movl $0x2cd0, %esi # imm = 0x2CD0 leaq 0x5ace8(%rip), %rdx # 0x73dbd movb $0x0, %al callq 0xe270 addq $0x10, %rsp popq %rbp retq nopw %cs:(%rax,%rax)
ggml_compute_forward_ssm_scan: push rbp mov rbp, rsp sub rsp, 10h mov [rbp+var_8], rdi mov [rbp+var_10], rsi mov rax, [rbp+var_10] mov rax, [rax+98h] mov eax, [rax] test eax, eax jnz short loc_190C2 jmp short $+2 loc_190B3: mov rdi, [rbp+var_8] mov rsi, [rbp+var_10] call ggml_compute_forward_ssm_scan_f32 jmp short loc_190DC loc_190C2: lea rdi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github/2025_star3"... mov esi, 2CD0h lea rdx, aFatalError; "fatal error" mov al, 0 call _ggml_abort loc_190DC: add rsp, 10h pop rbp retn
double ggml_compute_forward_ssm_scan(long long a1, long long a2) { double result; // xmm0_8 if ( **(_DWORD **)(a2 + 152) ) return ggml_abort( "/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml-cpu/ggml-cpu.c", 11472LL, "fatal error"); ggml_compute_forward_ssm_scan_f32(a1, a2); return result; }
ggml_compute_forward_ssm_scan: PUSH RBP MOV RBP,RSP SUB RSP,0x10 MOV qword ptr [RBP + -0x8],RDI MOV qword ptr [RBP + -0x10],RSI MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x98] MOV EAX,dword ptr [RAX] TEST EAX,EAX JNZ 0x001190c2 JMP 0x001190b3 LAB_001190b3: MOV RDI,qword ptr [RBP + -0x8] MOV RSI,qword ptr [RBP + -0x10] CALL 0x00137f20 JMP 0x001190dc LAB_001190c2: LEA RDI,[0x173b62] MOV ESI,0x2cd0 LEA RDX,[0x173dbd] MOV AL,0x0 CALL 0x0010e270 LAB_001190dc: ADD RSP,0x10 POP RBP RET
void ggml_compute_forward_ssm_scan(int8 param_1,long param_2) { if (**(int **)(param_2 + 0x98) == 0) { ggml_compute_forward_ssm_scan_f32(param_1,param_2); } else { ggml_abort("/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml-cpu/ggml-cpu.c" ,0x2cd0,"fatal error"); } return; }
6,035
test_bug4026
eloqsql/tests/mysql_client_test.c
static void test_bug4026() { MYSQL_STMT *stmt; MYSQL_BIND my_bind[2]; MYSQL_TIME time_in, time_out; MYSQL_TIME datetime_in, datetime_out; const char *stmt_text; int rc; myheader("test_bug4026"); /* Check that microseconds are inserted and selected successfully */ /* Create a statement handle and prepare it with select */ stmt= mysql_stmt_init(mysql); stmt_text= "SELECT ?, ?"; rc= mysql_stmt_prepare(stmt, stmt_text, strlen(stmt_text)); check_execute(stmt, rc); /* Bind input buffers */ bzero((char*) my_bind, sizeof(my_bind)); bzero((char*) &time_in, sizeof(time_in)); bzero((char*) &time_out, sizeof(time_out)); bzero((char*) &datetime_in, sizeof(datetime_in)); bzero((char*) &datetime_out, sizeof(datetime_out)); my_bind[0].buffer_type= MYSQL_TYPE_TIME; my_bind[0].buffer= (void *) &time_in; my_bind[1].buffer_type= MYSQL_TYPE_DATETIME; my_bind[1].buffer= (void *) &datetime_in; time_in.hour= 23; time_in.minute= 59; time_in.second= 59; time_in.second_part= 123456; /* This is not necessary, just to make DIE_UNLESS below work: this field is filled in when time is received from server */ time_in.time_type= MYSQL_TIMESTAMP_TIME; datetime_in= time_in; datetime_in.year= 2003; datetime_in.month= 12; datetime_in.day= 31; datetime_in.time_type= MYSQL_TIMESTAMP_DATETIME; mysql_stmt_bind_param(stmt, my_bind); /* Execute the select statement */ rc= mysql_stmt_execute(stmt); check_execute(stmt, rc); my_bind[0].buffer= (void *) &time_out; my_bind[1].buffer= (void *) &datetime_out; mysql_stmt_bind_result(stmt, my_bind); rc= mysql_stmt_fetch(stmt); DIE_UNLESS(rc == 0); if (!opt_silent) { printf("%d:%d:%d.%lu\n", time_out.hour, time_out.minute, time_out.second, time_out.second_part); printf("%d-%d-%d %d:%d:%d.%lu\n", datetime_out.year, datetime_out.month, datetime_out.day, datetime_out.hour, datetime_out.minute, datetime_out.second, datetime_out.second_part); } DIE_UNLESS(memcmp(&time_in, &time_out, sizeof(time_in)) == 0); DIE_UNLESS(memcmp(&datetime_in, &datetime_out, sizeof(datetime_in)) == 0); mysql_stmt_close(stmt); }
O3
c
test_bug4026: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %rbx subq $0x198, %rsp # imm = 0x198 cmpb $0x1, 0x3ba5de(%rip) # 0x41a4c1 jg 0x5ff64 movq 0x3400d4(%rip), %rbx # 0x39ffc0 movq (%rbx), %rdi leaq 0x7f5ce(%rip), %rdx # 0xdf4c4 movl $0x1, %esi xorl %eax, %eax callq 0x39240 movq (%rbx), %rdi movl 0x3ba801(%rip), %ecx # 0x41a70c leal 0x1(%rcx), %eax movl %eax, 0x3ba7f8(%rip) # 0x41a70c movl 0x3ba7ed(%rip), %r8d # 0x41a708 movl 0x3ba5ca(%rip), %r9d # 0x41a4ec subq $0x8, %rsp leaq 0x7fefd(%rip), %r10 # 0xdfe2a leaq 0x80898(%rip), %rdx # 0xe07cc movl $0x1, %esi xorl %eax, %eax pushq %r10 callq 0x39240 addq $0x10, %rsp movq (%rbx), %rdi leaq 0x7f5ac(%rip), %rdx # 0xdf4fc movl $0x1, %esi xorl %eax, %eax callq 0x39240 movq (%rbx), %rdi callq 0x394b0 movq 0x3ba55d(%rip), %rdi # 0x41a4c8 callq 0x9191c movq %rax, %rbx leaq 0x8b1a7(%rip), %rsi # 0xeb121 movl $0xb, %edx movq %rax, %rdi callq 0x3b4a1 testl %eax, %eax jne 0x60162 leaq -0x1b0(%rbp), %r14 xorl %r15d, %r15d movl $0xe0, %edx movq %r14, %rdi xorl %esi, %esi callq 0x392e0 xorps %xmm0, %xmm0 leaq -0xd0(%rbp), %rax movaps %xmm0, (%rax) movaps %xmm0, 0x10(%rax) movq %r15, 0x20(%rax) movaps %xmm0, -0x70(%rbp) movaps %xmm0, -0x60(%rbp) movq %r15, -0x50(%rbp) movaps %xmm0, -0x40(%rbp) movaps %xmm0, -0x30(%rbp) movq %r15, -0x20(%rbp) movl $0xb, 0x60(%r14) movq %rax, 0x10(%r14) movl $0xc, 0xd0(%r14) leaq -0xa0(%rbp), %rcx movq %rcx, 0x80(%r14) movl $0x17, 0xc(%rax) movabsq $0x3b0000003b, %rdx # imm = 0x3B0000003B movq %rdx, 0x10(%rax) movq $0x1e240, 0x18(%rax) # imm = 0x1E240 movl $0x2, 0x24(%rax) movq (%rax), %rdx movq %rdx, (%rcx) movl 0x8(%rax), %edx movl %edx, 0x8(%rcx) movl 0xc(%rax), %edx movl %edx, 0xc(%rcx) movq 0x10(%rax), %rdx movq %rdx, 0x10(%rcx) movq 0x18(%rax), %rdx movq %rdx, 0x18(%rcx) movq 0x20(%rax), %rax movq %rax, 0x20(%rcx) movabsq $0xc000007d3, %rax # imm = 0xC000007D3 movq %rax, (%rcx) movl $0x1f, 0x8(%rcx) movl $0x1, 0x24(%rcx) movq %rbx, %rdi movq %r14, %rsi callq 0x90d4e movq %rbx, %rdi callq 0x3b510 testl %eax, %eax jne 0x60182 leaq -0x70(%rbp), %rax leaq -0x1b0(%rbp), %rsi movq %rax, 0x10(%rsi) leaq -0x40(%rbp), %rax movq %rax, 0x80(%rsi) movq %rbx, %rdi callq 0x91084 movq %rbx, %rdi callq 0x3b573 testl %eax, %eax jne 0x601a2 cmpb $0x0, 0x3ba40a(%rip) # 0x41a4c1 jne 0x60112 movl -0x64(%rbp), %edx movl -0x60(%rbp), %ecx movl -0x5c(%rbp), %r8d movq -0x58(%rbp), %r9 leaq 0x8b068(%rip), %rsi # 0xeb136 movl $0x1, %edi xorl %eax, %eax callq 0x39a60 movl -0x40(%rbp), %edx movl -0x3c(%rbp), %ecx movl -0x38(%rbp), %r8d movl -0x34(%rbp), %r9d movl -0x30(%rbp), %r10d movl -0x2c(%rbp), %r11d subq $0x8, %rsp leaq 0x8b032(%rip), %rsi # 0xeb12d movl $0x1, %edi xorl %eax, %eax pushq -0x28(%rbp) pushq %r11 pushq %r10 callq 0x39a60 addq $0x20, %rsp leaq -0xd0(%rbp), %rdi leaq -0x70(%rbp), %rsi movl $0x28, %edx callq 0x396c0 testl %eax, %eax jne 0x601ba leaq -0xa0(%rbp), %rdi leaq -0x40(%rbp), %rsi movl $0x28, %edx callq 0x396c0 testl %eax, %eax jne 0x601d2 movq %rbx, %rdi callq 0x3b639 addq $0x198, %rsp # imm = 0x198 popq %rbx popq %r14 popq %r15 popq %rbp retq movq %rbx, %rdi callq 0x3bbbe leaq 0x7ec3b(%rip), %rdi # 0xdedac leaq 0x8a7ef(%rip), %rdx # 0xea967 movl $0x2ad8, %esi # imm = 0x2AD8 callq 0x3bb30 movq %rbx, %rdi callq 0x3bbbe leaq 0x7ec1b(%rip), %rdi # 0xdedac leaq 0x8a7cf(%rip), %rdx # 0xea967 movl $0x2afa, %esi # imm = 0x2AFA callq 0x3bb30 leaq 0x7ec03(%rip), %rdi # 0xdedac leaq 0x8a7b7(%rip), %rdx # 0xea967 movl $0x2b02, %esi # imm = 0x2B02 callq 0x3bb30 leaq 0x7ebeb(%rip), %rdi # 0xdedac leaq 0x8af7c(%rip), %rdx # 0xeb144 movl $0x2b0c, %esi # imm = 0x2B0C callq 0x3bb30 leaq 0x7ebd3(%rip), %rdi # 0xdedac leaq 0x8af96(%rip), %rdx # 0xeb176 movl $0x2b0d, %esi # imm = 0x2B0D callq 0x3bb30
test_bug4026: push rbp mov rbp, rsp push r15 push r14 push rbx sub rsp, 198h cmp cs:opt_silent, 1 jg short loc_5FF64 mov rbx, cs:stdout_ptr mov rdi, [rbx] lea rdx, asc_DF4C4; "\n\n###################################"... mov esi, 1 xor eax, eax call ___fprintf_chk mov rdi, [rbx] mov ecx, cs:test_count lea eax, [rcx+1] mov cs:test_count, eax mov r8d, cs:iter_count mov r9d, cs:opt_count sub rsp, 8 lea r10, aTestBug4026; "test_bug4026" lea rdx, aUOfUUS; "%u of (%u/%u): %s" mov esi, 1 xor eax, eax push r10 call ___fprintf_chk add rsp, 10h mov rdi, [rbx] lea rdx, asc_DF4FC; " \n###################################"... mov esi, 1 xor eax, eax call ___fprintf_chk mov rdi, [rbx] call _fflush loc_5FF64: mov rdi, cs:mysql call mysql_stmt_init mov rbx, rax lea rsi, aSelect_0; "SELECT ?, ?" mov edx, 0Bh mov rdi, rax call wrap_mysql_stmt_prepare test eax, eax jnz loc_60162 lea r14, [rbp+var_1B0] xor r15d, r15d mov edx, 0E0h mov rdi, r14 xor esi, esi call _memset xorps xmm0, xmm0 lea rax, [rbp+var_D0] movaps xmmword ptr [rax], xmm0 movaps xmmword ptr [rax+10h], xmm0 mov [rax+20h], r15 movaps [rbp+var_70], xmm0 movaps [rbp+var_60], xmm0 mov [rbp+var_50], r15 movaps [rbp+var_40], xmm0 movaps [rbp+var_30], xmm0 mov [rbp+var_20], r15 mov dword ptr [r14+60h], 0Bh mov [r14+10h], rax mov dword ptr [r14+0D0h], 0Ch lea rcx, [rbp+var_A0] mov [r14+80h], rcx mov dword ptr [rax+0Ch], 17h mov rdx, 3B0000003Bh mov [rax+10h], rdx mov qword ptr [rax+18h], offset stru_1E240 mov dword ptr [rax+24h], 2 mov rdx, [rax] mov [rcx], rdx mov edx, [rax+8] mov [rcx+8], edx mov edx, [rax+0Ch] mov [rcx+0Ch], edx mov rdx, [rax+10h] mov [rcx+10h], rdx mov rdx, [rax+18h] mov [rcx+18h], rdx mov rax, [rax+20h] mov [rcx+20h], rax mov rax, 0C000007D3h mov [rcx], rax mov dword ptr [rcx+8], 1Fh mov dword ptr [rcx+24h], 1 mov rdi, rbx mov rsi, r14 call mysql_stmt_bind_param mov rdi, rbx call wrap_mysql_stmt_execute test eax, eax jnz loc_60182 lea rax, [rbp+var_70] lea rsi, [rbp+var_1B0] mov [rsi+10h], rax lea rax, [rbp+var_40] mov [rsi+80h], rax mov rdi, rbx call mysql_stmt_bind_result mov rdi, rbx call wrap_mysql_stmt_fetch test eax, eax jnz loc_601A2 cmp cs:opt_silent, 0 jnz short loc_60112 mov edx, dword ptr [rbp+var_70+0Ch] mov ecx, dword ptr [rbp+var_60] mov r8d, dword ptr [rbp+var_60+4] mov r9, qword ptr [rbp+var_60+8] lea rsi, aDDDDDDLu+9; "%d:%d:%d.%lu\n" mov edi, 1 xor eax, eax call ___printf_chk mov edx, dword ptr [rbp+var_40] mov ecx, dword ptr [rbp+var_40+4] mov r8d, dword ptr [rbp+var_40+8] mov r9d, dword ptr [rbp+var_40+0Ch] mov r10d, dword ptr [rbp+var_30] mov r11d, dword ptr [rbp+var_30+4] sub rsp, 8 lea rsi, aDDDDDDLu; "%d-%d-%d %d:%d:%d.%lu\n" mov edi, 1 xor eax, eax push qword ptr [rbp+var_30+8] push r11 push r10 call ___printf_chk add rsp, 20h loc_60112: lea rdi, [rbp+var_D0] lea rsi, [rbp+var_70] mov edx, 28h ; '(' call _bcmp test eax, eax jnz loc_601BA lea rdi, [rbp+var_A0] lea rsi, [rbp+var_40] mov edx, 28h ; '(' call _bcmp test eax, eax jnz loc_601D2 mov rdi, rbx call wrap_mysql_stmt_close add rsp, 198h pop rbx pop r14 pop r15 pop rbp retn loc_60162: mov rdi, rbx call print_st_error lea rdi, aWorkspaceLlm4b_3; "/workspace/llm4binary/github2025/eloqsq"... lea rdx, aRcMysqlDataTru+1Eh; "rc == 0" mov esi, 2AD8h call die loc_60182: mov rdi, rbx call print_st_error lea rdi, aWorkspaceLlm4b_3; "/workspace/llm4binary/github2025/eloqsq"... lea rdx, aRcMysqlDataTru+1Eh; "rc == 0" mov esi, 2AFAh call die loc_601A2: lea rdi, aWorkspaceLlm4b_3; "/workspace/llm4binary/github2025/eloqsq"... lea rdx, aRcMysqlDataTru+1Eh; "rc == 0" mov esi, 2B02h call die loc_601BA: lea rdi, aWorkspaceLlm4b_3; "/workspace/llm4binary/github2025/eloqsq"... lea rdx, aMemcmpTimeInTi; "memcmp(&time_in, &time_out, sizeof(time"... mov esi, 2B0Ch call die loc_601D2: lea rdi, aWorkspaceLlm4b_3; "/workspace/llm4binary/github2025/eloqsq"... lea rdx, aMemcmpDatetime; "memcmp(&datetime_in, &datetime_out, siz"... mov esi, 2B0Dh call die
char test_bug4026() { int v0; // ecx long long v1; // rbx long long v2; // rdx long long v3; // rcx _BYTE v5[16]; // [rsp+0h] [rbp-1B0h] BYREF __int128 *v6; // [rsp+10h] [rbp-1A0h] int v7; // [rsp+60h] [rbp-150h] long long *v8; // [rsp+80h] [rbp-130h] int v9; // [rsp+D0h] [rbp-E0h] __int128 v10; // [rsp+E0h] [rbp-D0h] BYREF long long v11; // [rsp+F0h] [rbp-C0h] Elf64_Rela *v12; // [rsp+F8h] [rbp-B8h] int v13; // [rsp+100h] [rbp-B0h] int v14; // [rsp+104h] [rbp-ACh] long long v15; // [rsp+110h] [rbp-A0h] BYREF int v16; // [rsp+118h] [rbp-98h] int v17; // [rsp+11Ch] [rbp-94h] long long v18; // [rsp+120h] [rbp-90h] Elf64_Rela *v19; // [rsp+128h] [rbp-88h] int v20; // [rsp+130h] [rbp-80h] int v21; // [rsp+134h] [rbp-7Ch] __int128 v22; // [rsp+140h] [rbp-70h] BYREF __int128 v23; // [rsp+150h] [rbp-60h] long long v24; // [rsp+160h] [rbp-50h] __int128 v25; // [rsp+170h] [rbp-40h] BYREF __int128 v26; // [rsp+180h] [rbp-30h] long long v27; // [rsp+190h] [rbp-20h] if ( opt_silent <= 1 ) { __fprintf_chk(stdout, 1LL, "\n\n#####################################\n"); v0 = test_count++; __fprintf_chk(stdout, 1LL, "%u of (%u/%u): %s", v0, iter_count, opt_count, "test_bug4026"); __fprintf_chk(stdout, 1LL, " \n#####################################\n"); fflush(stdout); } v1 = mysql_stmt_init(mysql); if ( (unsigned int)wrap_mysql_stmt_prepare(v1, (long long)"SELECT ?, ?", 11LL) ) { print_st_error(v1); die("/workspace/llm4binary/github2025/eloqsql/tests/mysql_client_test.c", 10968, "rc == 0"); } memset(v5, 0LL, 224LL); v10 = 0LL; v13 = 0; v22 = 0LL; v23 = 0LL; v24 = 0LL; v25 = 0LL; v26 = 0LL; v27 = 0LL; v7 = 11; v6 = &v10; v9 = 12; v8 = &v15; HIDWORD(v10) = 23; v11 = 0x3B0000003BLL; v12 = &stru_1E240; v14 = 2; v17 = 23; v18 = 0x3B0000003BLL; v19 = &stru_1E240; v20 = 0; v15 = 0xC000007D3LL; v16 = 31; v21 = 1; mysql_stmt_bind_param(v1, v5); if ( (unsigned int)wrap_mysql_stmt_execute(v1) ) { print_st_error(v1); die("/workspace/llm4binary/github2025/eloqsql/tests/mysql_client_test.c", 11002, "rc == 0"); } v6 = &v22; v8 = (long long *)&v25; mysql_stmt_bind_result(v1, v5, v2, v3); if ( (unsigned int)wrap_mysql_stmt_fetch(v1) ) die("/workspace/llm4binary/github2025/eloqsql/tests/mysql_client_test.c", 11010, "rc == 0"); if ( !opt_silent ) { __printf_chk(1LL, "%d:%d:%d.%lu\n", HIDWORD(v22), (_DWORD)v23, DWORD1(v23), *((_QWORD *)&v23 + 1)); __printf_chk( 1LL, "%d-%d-%d %d:%d:%d.%lu\n", (_DWORD)v25, DWORD1(v25), DWORD2(v25), HIDWORD(v25), (_DWORD)v26, DWORD1(v26), *((_QWORD *)&v26 + 1)); } if ( (unsigned int)bcmp(&v10, &v22, 40LL) ) die( "/workspace/llm4binary/github2025/eloqsql/tests/mysql_client_test.c", 11020, "memcmp(&time_in, &time_out, sizeof(time_in)) == 0"); if ( (unsigned int)bcmp(&v15, &v25, 40LL) ) die( "/workspace/llm4binary/github2025/eloqsql/tests/mysql_client_test.c", 11021, "memcmp(&datetime_in, &datetime_out, sizeof(datetime_in)) == 0"); return wrap_mysql_stmt_close(v1); }
test_bug4026: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH RBX SUB RSP,0x198 CMP byte ptr [0x0051a4c1],0x1 JG 0x0015ff64 MOV RBX,qword ptr [0x0049ffc0] MOV RDI,qword ptr [RBX] LEA RDX,[0x1df4c4] MOV ESI,0x1 XOR EAX,EAX CALL 0x00139240 MOV RDI,qword ptr [RBX] MOV ECX,dword ptr [0x0051a70c] LEA EAX,[RCX + 0x1] MOV dword ptr [0x0051a70c],EAX MOV R8D,dword ptr [0x0051a708] MOV R9D,dword ptr [0x0051a4ec] SUB RSP,0x8 LEA R10,[0x1dfe2a] LEA RDX,[0x1e07cc] MOV ESI,0x1 XOR EAX,EAX PUSH R10 CALL 0x00139240 ADD RSP,0x10 MOV RDI,qword ptr [RBX] LEA RDX,[0x1df4fc] MOV ESI,0x1 XOR EAX,EAX CALL 0x00139240 MOV RDI,qword ptr [RBX] CALL 0x001394b0 LAB_0015ff64: MOV RDI,qword ptr [0x0051a4c8] CALL 0x0019191c MOV RBX,RAX LEA RSI,[0x1eb121] MOV EDX,0xb MOV RDI,RAX CALL 0x0013b4a1 TEST EAX,EAX JNZ 0x00160162 LEA R14,[RBP + -0x1b0] XOR R15D,R15D MOV EDX,0xe0 MOV RDI,R14 XOR ESI,ESI CALL 0x001392e0 XORPS XMM0,XMM0 LEA RAX,[RBP + -0xd0] MOVAPS xmmword ptr [RAX],XMM0 MOVAPS xmmword ptr [RAX + 0x10],XMM0 MOV qword ptr [RAX + 0x20],R15 MOVAPS xmmword ptr [RBP + -0x70],XMM0 MOVAPS xmmword ptr [RBP + -0x60],XMM0 MOV qword ptr [RBP + -0x50],R15 MOVAPS xmmword ptr [RBP + -0x40],XMM0 MOVAPS xmmword ptr [RBP + -0x30],XMM0 MOV qword ptr [RBP + -0x20],R15 MOV dword ptr [R14 + 0x60],0xb MOV qword ptr [R14 + 0x10],RAX MOV dword ptr [R14 + 0xd0],0xc LEA RCX,[RBP + -0xa0] MOV qword ptr [R14 + 0x80],RCX MOV dword ptr [RAX + 0xc],0x17 MOV RDX,0x3b0000003b MOV qword ptr [RAX + 0x10],RDX MOV qword ptr [RAX + 0x18],0x1e240 MOV dword ptr [RAX + 0x24],0x2 MOV RDX,qword ptr [RAX] MOV qword ptr [RCX],RDX MOV EDX,dword ptr [RAX + 0x8] MOV dword ptr [RCX + 0x8],EDX MOV EDX,dword ptr [RAX + 0xc] MOV dword ptr [RCX + 0xc],EDX MOV RDX,qword ptr [RAX + 0x10] MOV qword ptr [RCX + 0x10],RDX MOV RDX,qword ptr [RAX + 0x18] MOV qword ptr [RCX + 0x18],RDX MOV RAX,qword ptr [RAX + 0x20] MOV qword ptr [RCX + 0x20],RAX MOV RAX,0xc000007d3 MOV qword ptr [RCX],RAX MOV dword ptr [RCX + 0x8],0x1f MOV dword ptr [RCX + 0x24],0x1 MOV RDI,RBX MOV RSI,R14 CALL 0x00190d4e MOV RDI,RBX CALL 0x0013b510 TEST EAX,EAX JNZ 0x00160182 LEA RAX,[RBP + -0x70] LEA RSI,[RBP + -0x1b0] MOV qword ptr [RSI + 0x10],RAX LEA RAX,[RBP + -0x40] MOV qword ptr [RSI + 0x80],RAX MOV RDI,RBX CALL 0x00191084 MOV RDI,RBX CALL 0x0013b573 TEST EAX,EAX JNZ 0x001601a2 CMP byte ptr [0x0051a4c1],0x0 JNZ 0x00160112 MOV EDX,dword ptr [RBP + -0x64] MOV ECX,dword ptr [RBP + -0x60] MOV R8D,dword ptr [RBP + -0x5c] MOV R9,qword ptr [RBP + -0x58] LEA RSI,[0x1eb136] MOV EDI,0x1 XOR EAX,EAX CALL 0x00139a60 MOV EDX,dword ptr [RBP + -0x40] MOV ECX,dword ptr [RBP + -0x3c] MOV R8D,dword ptr [RBP + -0x38] MOV R9D,dword ptr [RBP + -0x34] MOV R10D,dword ptr [RBP + -0x30] MOV R11D,dword ptr [RBP + -0x2c] SUB RSP,0x8 LEA RSI,[0x1eb12d] MOV EDI,0x1 XOR EAX,EAX PUSH qword ptr [RBP + -0x28] PUSH R11 PUSH R10 CALL 0x00139a60 ADD RSP,0x20 LAB_00160112: LEA RDI,[RBP + -0xd0] LEA RSI,[RBP + -0x70] MOV EDX,0x28 CALL 0x001396c0 TEST EAX,EAX JNZ 0x001601ba LEA RDI,[RBP + -0xa0] LEA RSI,[RBP + -0x40] MOV EDX,0x28 CALL 0x001396c0 TEST EAX,EAX JNZ 0x001601d2 MOV RDI,RBX CALL 0x0013b639 ADD RSP,0x198 POP RBX POP R14 POP R15 POP RBP RET LAB_00160162: MOV RDI,RBX CALL 0x0013bbbe LEA RDI,[0x1dedac] LEA RDX,[0x1ea967] MOV ESI,0x2ad8 CALL 0x0013bb30 LAB_00160182: MOV RDI,RBX CALL 0x0013bbbe LEA RDI,[0x1dedac] LEA RDX,[0x1ea967] MOV ESI,0x2afa CALL 0x0013bb30 LAB_001601a2: LEA RDI,[0x1dedac] LEA RDX,[0x1ea967] MOV ESI,0x2b02 CALL 0x0013bb30 LAB_001601ba: LEA RDI,[0x1dedac] LEA RDX,[0x1eb144] MOV ESI,0x2b0c CALL 0x0013bb30 LAB_001601d2: LEA RDI,[0x1dedac] LEA RDX,[0x1eb176] MOV ESI,0x2b0d CALL 0x0013bb30
void test_bug4026(void) { int *puVar1; int iVar2; int8 uVar3; int1 local_1b8 [16]; int8 *local_1a8; int4 local_158; int8 *local_138; int4 local_e8; int8 local_d8; int8 uStack_d0; int8 local_c8; int8 uStack_c0; int8 local_b8; int8 local_a8; int4 local_a0; int4 local_9c; int8 local_98; int8 local_90; int8 local_88; int8 local_78; int8 uStack_70; int8 local_68; int8 uStack_60; int8 local_58; int8 local_48; int8 uStack_40; ulong local_38; int8 uStack_30; int8 local_28; puVar1 = PTR_stdout_0049ffc0; if (opt_silent < '\x02') { __fprintf_chk(*(int8 *)PTR_stdout_0049ffc0,1,"\n\n#####################################\n" ); iVar2 = test_count; test_count = test_count + 1; __fprintf_chk(*(int8 *)puVar1,1,"%u of (%u/%u): %s",iVar2,iter_count,opt_count, "test_bug4026"); __fprintf_chk(*(int8 *)puVar1,1," \n#####################################\n"); fflush(*(FILE **)puVar1); } uVar3 = mysql_stmt_init(mysql); iVar2 = wrap_mysql_stmt_prepare(uVar3,"SELECT ?, ?",0xb); if (iVar2 != 0) { print_st_error(uVar3); /* WARNING: Subroutine does not return */ die("/workspace/llm4binary/github2025/eloqsql/tests/mysql_client_test.c",0x2ad8,"rc == 0"); } memset(local_1b8,0,0xe0); local_1a8 = &local_d8; local_d8 = 0; local_78 = 0; uStack_70 = 0; local_68 = 0; uStack_60 = 0; local_58 = 0; local_48 = 0; uStack_40 = 0; local_38 = 0; uStack_30 = 0; local_28 = 0; local_158 = 0xb; local_e8 = 0xc; local_138 = &local_a8; uStack_d0 = 0x1700000000; local_c8 = 0x3b0000003b; uStack_c0 = 0x1e240; local_b8 = 0x200000000; local_9c = 0x17; local_98 = 0x3b0000003b; local_90 = 0x1e240; local_a8 = 0xc000007d3; local_a0 = 0x1f; local_88 = 0x100000000; mysql_stmt_bind_param(uVar3,local_1b8); iVar2 = wrap_mysql_stmt_execute(uVar3); if (iVar2 != 0) { print_st_error(uVar3); /* WARNING: Subroutine does not return */ die("/workspace/llm4binary/github2025/eloqsql/tests/mysql_client_test.c",0x2afa,"rc == 0"); } local_1a8 = &local_78; local_138 = &local_48; mysql_stmt_bind_result(uVar3); iVar2 = wrap_mysql_stmt_fetch(uVar3); if (iVar2 == 0) { if (opt_silent == '\0') { __printf_chk(1,"%d:%d:%d.%lu\n",uStack_70._4_4_,local_68 & 0xffffffff,local_68._4_4_,uStack_60 ); __printf_chk(1,"%d-%d-%d %d:%d:%d.%lu\n",local_48 & 0xffffffff,local_48._4_4_, uStack_40 & 0xffffffff,uStack_40._4_4_,local_38 & 0xffffffff,local_38 >> 0x20, uStack_30); } iVar2 = bcmp(&local_d8,&local_78,0x28); if (iVar2 == 0) { iVar2 = bcmp(&local_a8,&local_48,0x28); if (iVar2 == 0) { wrap_mysql_stmt_close(uVar3); return; } /* WARNING: Subroutine does not return */ die("/workspace/llm4binary/github2025/eloqsql/tests/mysql_client_test.c",0x2b0d, "memcmp(&datetime_in, &datetime_out, sizeof(datetime_in)) == 0"); } /* WARNING: Subroutine does not return */ die("/workspace/llm4binary/github2025/eloqsql/tests/mysql_client_test.c",0x2b0c, "memcmp(&time_in, &time_out, sizeof(time_in)) == 0"); } /* WARNING: Subroutine does not return */ die("/workspace/llm4binary/github2025/eloqsql/tests/mysql_client_test.c",0x2b02,"rc == 0"); }
6,036
nlohmann::json_abi_v3_11_3::detail::json_sax_dom_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() { JSON_ASSERT(!ref_stack.empty()); JSON_ASSERT(ref_stack.back()->is_object()); ref_stack.back()->set_parents(); ref_stack.pop_back(); return true; }
O1
cpp
nlohmann::json_abi_v3_11_3::detail::json_sax_dom_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 %rax movq 0x10(%rdi), %rax cmpq %rax, 0x8(%rdi) je 0x65b6a movq -0x8(%rax), %rcx cmpb $0x1, (%rcx) jne 0x65b86 addq $-0x8, %rax movq %rax, 0x10(%rdi) movb $0x1, %al popq %rcx retq leaq 0x8d748(%rip), %rdi # 0xf32b9 leaq 0x87a13(%rip), %rdx # 0xed58b leaq 0x8e725(%rip), %rcx # 0xf42a4 movl $0x1aeb, %esi # imm = 0x1AEB jmp 0x65ba0 leaq 0x8d72c(%rip), %rdi # 0xf32b9 leaq 0x879f7(%rip), %rdx # 0xed58b leaq 0x8e6b7(%rip), %rcx # 0xf4252 movl $0x1aec, %esi # imm = 0x1AEC xorl %eax, %eax callq 0x1bf20 nop
_ZN8nlohmann16json_abi_v3_11_36detail19json_sax_dom_parserINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE10end_objectEv: push rax mov rax, [rdi+10h] cmp [rdi+8], rax jz short loc_65B6A mov rcx, [rax-8] cmp byte ptr [rcx], 1 jnz short loc_65B86 add rax, 0FFFFFFFFFFFFFFF8h mov [rdi+10h], rax mov al, 1 pop rcx retn loc_65B6A: lea rdi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github/2025_star3"... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aRefStackEmpty; "!ref_stack.empty()" mov esi, 1AEBh jmp short loc_65BA0 loc_65B86: lea rdi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github/2025_star3"... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aRefStackBackIs+20h; "ref_stack.back()->is_object()" mov esi, 1AECh loc_65BA0: xor eax, eax call _ggml_abort nop
char nlohmann::json_abi_v3_11_3::detail::json_sax_dom_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 v3; // rsi v1 = *(_QWORD *)(a1 + 16); if ( *(_QWORD *)(a1 + 8) == v1 ) { v3 = 6891LL; ggml_abort( "/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp", 6891LL, "GGML_ASSERT(%s) failed", "!ref_stack.empty()"); } else { if ( **(_BYTE **)(v1 - 8) == 1 ) { *(_QWORD *)(a1 + 16) = v1 - 8; return 1; } v3 = 6892LL; ggml_abort( "/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp", 6892LL, "GGML_ASSERT(%s) failed", "ref_stack.back()->is_object()"); } return nlohmann::json_abi_v3_11_3::detail::json_sax_dom_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>>::key( "/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp", v3); }
end_object: PUSH RAX MOV RAX,qword ptr [RDI + 0x10] CMP qword ptr [RDI + 0x8],RAX JZ 0x00165b6a MOV RCX,qword ptr [RAX + -0x8] CMP byte ptr [RCX],0x1 JNZ 0x00165b86 ADD RAX,-0x8 MOV qword ptr [RDI + 0x10],RAX MOV AL,0x1 POP RCX RET LAB_00165b6a: LEA RDI,[0x1f32b9] LEA RDX,[0x1ed58b] LEA RCX,[0x1f42a4] MOV ESI,0x1aeb JMP 0x00165ba0 LAB_00165b86: LEA RDI,[0x1f32b9] LEA RDX,[0x1ed58b] LEA RCX,[0x1f4252] MOV ESI,0x1aec LAB_00165ba0: XOR EAX,EAX CALL 0x0011bf20
/* nlohmann::json_abi_v3_11_3::detail::json_sax_dom_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_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_parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>> *this) { long lVar1; char *pcVar2; int8 uVar3; lVar1 = *(long *)(this + 0x10); if (*(long *)(this + 8) == lVar1) { pcVar2 = "!ref_stack.empty()"; uVar3 = 0x1aeb; } else { if (**(char **)(lVar1 + -8) == '\x01') { *(long *)(this + 0x10) = lVar1 + -8; return CONCAT71((int7)((ulong)(lVar1 + -8) >> 8),1); } pcVar2 = "ref_stack.back()->is_object()"; uVar3 = 0x1aec; } /* WARNING: Subroutine does not return */ ggml_abort("/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",uVar3, "GGML_ASSERT(%s) failed",pcVar2); }
6,037
my_casefold_mb
eloqsql/strings/ctype-mb.c
static size_t my_casefold_mb(CHARSET_INFO *cs, const char *src, size_t srclen, char *dst, size_t dstlen __attribute__((unused)), const uchar *map, size_t is_upper) { const char *srcend= src + srclen; char *dst0= dst; DBUG_ASSERT(cs->mbmaxlen == 2); while (src < srcend) { size_t mblen= my_ismbchar(cs, src, srcend); if (mblen) { MY_UNICASE_CHARACTER *ch; if ((ch= get_case_info_for_ch(cs, (uchar) src[0], (uchar) src[1]))) { int code= is_upper ? ch->toupper : ch->tolower; src+= 2; if (code > 0xFF) *dst++= code >> 8; *dst++= code & 0xFF; } else { *dst++= *src++; *dst++= *src++; } } else { *dst++= (char) map[(uchar) *src++]; } } return (size_t) (dst - dst0); }
O0
c
my_casefold_mb: pushq %rbp movq %rsp, %rbp subq $0x60, %rsp movq 0x10(%rbp), %rax movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq %rdx, -0x18(%rbp) movq %rcx, -0x20(%rbp) movq %r8, -0x28(%rbp) movq %r9, -0x30(%rbp) movq -0x10(%rbp), %rax addq -0x18(%rbp), %rax movq %rax, -0x38(%rbp) movq -0x20(%rbp), %rax movq %rax, -0x40(%rbp) jmp 0x117cca jmp 0x117ccc movq -0x10(%rbp), %rax cmpq -0x38(%rbp), %rax jae 0x117e00 movq -0x8(%rbp), %rdi movq -0x10(%rbp), %rsi movq -0x38(%rbp), %rdx callq 0x117b30 movl %eax, %eax movq %rax, -0x48(%rbp) cmpq $0x0, -0x48(%rbp) je 0x117dd1 movq -0x8(%rbp), %rdi movq -0x10(%rbp), %rax movzbl (%rax), %esi movq -0x10(%rbp), %rax movzbl 0x1(%rax), %edx callq 0x11a810 movq %rax, -0x50(%rbp) cmpq $0x0, %rax je 0x117d8b cmpq $0x0, 0x10(%rbp) je 0x117d30 movq -0x50(%rbp), %rax movl (%rax), %eax movl %eax, -0x58(%rbp) jmp 0x117d3a movq -0x50(%rbp), %rax movl 0x4(%rax), %eax movl %eax, -0x58(%rbp) movl -0x58(%rbp), %eax movl %eax, -0x54(%rbp) movq -0x10(%rbp), %rax addq $0x2, %rax movq %rax, -0x10(%rbp) cmpl $0xff, -0x54(%rbp) jle 0x117d6e movl -0x54(%rbp), %eax sarl $0x8, %eax movb %al, %cl movq -0x20(%rbp), %rax movq %rax, %rdx addq $0x1, %rdx movq %rdx, -0x20(%rbp) movb %cl, (%rax) movl -0x54(%rbp), %eax andl $0xff, %eax movb %al, %cl movq -0x20(%rbp), %rax movq %rax, %rdx addq $0x1, %rdx movq %rdx, -0x20(%rbp) movb %cl, (%rax) jmp 0x117dcf movq -0x10(%rbp), %rax movq %rax, %rcx addq $0x1, %rcx movq %rcx, -0x10(%rbp) movb (%rax), %cl movq -0x20(%rbp), %rax movq %rax, %rdx addq $0x1, %rdx movq %rdx, -0x20(%rbp) movb %cl, (%rax) movq -0x10(%rbp), %rax movq %rax, %rcx addq $0x1, %rcx movq %rcx, -0x10(%rbp) movb (%rax), %cl movq -0x20(%rbp), %rax movq %rax, %rdx addq $0x1, %rdx movq %rdx, -0x20(%rbp) movb %cl, (%rax) jmp 0x117dfb movq -0x30(%rbp), %rax movq -0x10(%rbp), %rcx movq %rcx, %rdx addq $0x1, %rdx movq %rdx, -0x10(%rbp) movzbl (%rcx), %ecx movb (%rax,%rcx), %cl movq -0x20(%rbp), %rax movq %rax, %rdx addq $0x1, %rdx movq %rdx, -0x20(%rbp) movb %cl, (%rax) jmp 0x117ccc movq -0x20(%rbp), %rax movq -0x40(%rbp), %rcx subq %rcx, %rax addq $0x60, %rsp popq %rbp retq nopw %cs:(%rax,%rax)
my_casefold_mb: push rbp mov rbp, rsp sub rsp, 60h mov rax, [rbp+arg_0] 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 [rbp+var_30], r9 mov rax, [rbp+var_10] add rax, [rbp+var_18] mov [rbp+var_38], rax mov rax, [rbp+var_20] mov [rbp+var_40], rax jmp short $+2 loc_117CCA: jmp short $+2 loc_117CCC: mov rax, [rbp+var_10] cmp rax, [rbp+var_38] jnb loc_117E00 mov rdi, [rbp+var_8] mov rsi, [rbp+var_10] mov rdx, [rbp+var_38] call my_ismbchar_0 mov eax, eax mov [rbp+var_48], rax cmp [rbp+var_48], 0 jz loc_117DD1 mov rdi, [rbp+var_8] mov rax, [rbp+var_10] movzx esi, byte ptr [rax] mov rax, [rbp+var_10] movzx edx, byte ptr [rax+1] call get_case_info_for_ch mov [rbp+var_50], rax cmp rax, 0 jz short loc_117D8B cmp [rbp+arg_0], 0 jz short loc_117D30 mov rax, [rbp+var_50] mov eax, [rax] mov [rbp+var_58], eax jmp short loc_117D3A loc_117D30: mov rax, [rbp+var_50] mov eax, [rax+4] mov [rbp+var_58], eax loc_117D3A: mov eax, [rbp+var_58] mov [rbp+var_54], eax mov rax, [rbp+var_10] add rax, 2 mov [rbp+var_10], rax cmp [rbp+var_54], 0FFh jle short loc_117D6E mov eax, [rbp+var_54] sar eax, 8 mov cl, al mov rax, [rbp+var_20] mov rdx, rax add rdx, 1 mov [rbp+var_20], rdx mov [rax], cl loc_117D6E: mov eax, [rbp+var_54] and eax, 0FFh mov cl, al mov rax, [rbp+var_20] mov rdx, rax add rdx, 1 mov [rbp+var_20], rdx mov [rax], cl jmp short loc_117DCF loc_117D8B: mov rax, [rbp+var_10] mov rcx, rax add rcx, 1 mov [rbp+var_10], rcx mov cl, [rax] mov rax, [rbp+var_20] mov rdx, rax add rdx, 1 mov [rbp+var_20], rdx mov [rax], cl mov rax, [rbp+var_10] mov rcx, rax add rcx, 1 mov [rbp+var_10], rcx mov cl, [rax] mov rax, [rbp+var_20] mov rdx, rax add rdx, 1 mov [rbp+var_20], rdx mov [rax], cl loc_117DCF: jmp short loc_117DFB loc_117DD1: mov rax, [rbp+var_30] mov rcx, [rbp+var_10] mov rdx, rcx add rdx, 1 mov [rbp+var_10], rdx movzx ecx, byte ptr [rcx] mov cl, [rax+rcx] mov rax, [rbp+var_20] mov rdx, rax add rdx, 1 mov [rbp+var_20], rdx mov [rax], cl loc_117DFB: jmp loc_117CCC loc_117E00: mov rax, [rbp+var_20] mov rcx, [rbp+var_40] sub rax, rcx add rsp, 60h pop rbp retn
_BYTE * my_casefold_mb( long long a1, unsigned __int8 *a2, long long a3, unsigned __int8 *a4, long long a5, long long a6, long long a7) { unsigned __int8 *v7; // rax unsigned __int8 *v8; // rax char *v9; // rax char v10; // cl _BYTE *v11; // rax unsigned __int8 *v12; // rcx unsigned __int8 *v13; // rax int v15; // [rsp+8h] [rbp-58h] int *case_info_for_ch; // [rsp+10h] [rbp-50h] unsigned long long v18; // [rsp+28h] [rbp-38h] unsigned __int8 *v20; // [rsp+40h] [rbp-20h] unsigned __int8 *v21; // [rsp+50h] [rbp-10h] v21 = a2; v20 = a4; v18 = (unsigned long long)&a2[a3]; while ( (unsigned long long)v21 < v18 ) { if ( (unsigned int)my_ismbchar_0(a1, (long long)v21, v18) ) { case_info_for_ch = (int *)get_case_info_for_ch(a1, *v21, v21[1]); if ( case_info_for_ch ) { if ( a7 ) v15 = *case_info_for_ch; else v15 = case_info_for_ch[1]; v21 += 2; if ( v15 > 255 ) { v7 = v20++; *v7 = BYTE1(v15); } v8 = v20++; *v8 = v15; } else { *v20 = *v21; v9 = (char *)(v21 + 1); v21 += 2; v10 = *v9; v11 = v20 + 1; v20 += 2; *v11 = v10; } } else { v12 = v21++; v13 = v20++; *v13 = *(_BYTE *)(a6 + *v12); } } return (_BYTE *)(v20 - a4); }
6,038
my_casefold_mb
eloqsql/strings/ctype-mb.c
static size_t my_casefold_mb(CHARSET_INFO *cs, const char *src, size_t srclen, char *dst, size_t dstlen __attribute__((unused)), const uchar *map, size_t is_upper) { const char *srcend= src + srclen; char *dst0= dst; DBUG_ASSERT(cs->mbmaxlen == 2); while (src < srcend) { size_t mblen= my_ismbchar(cs, src, srcend); if (mblen) { MY_UNICASE_CHARACTER *ch; if ((ch= get_case_info_for_ch(cs, (uchar) src[0], (uchar) src[1]))) { int code= is_upper ? ch->toupper : ch->tolower; src+= 2; if (code > 0xFF) *dst++= code >> 8; *dst++= code & 0xFF; } else { *dst++= *src++; *dst++= *src++; } } else { *dst++= (char) map[(uchar) *src++]; } } return (size_t) (dst - dst0); }
O3
c
my_casefold_mb: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x18, %rsp movq %rcx, %rbx movq %rcx, -0x30(%rbp) testq %rdx, %rdx jle 0xb3ffb movq %r8, %r14 movq %rdx, %r15 movq %rsi, %r12 movq %rdi, %r13 addq %rsi, %r15 xorl %eax, %eax testq %r9, %r9 sete %al shll $0x2, %eax movq %rax, -0x38(%rbp) movq -0x30(%rbp), %rbx movq 0xb8(%r13), %rax movq %r13, %rdi movq %r12, %rsi movq %r15, %rdx callq *0xc0(%rax) cmpl $0x2, %eax jge 0xb3f9b movzbl (%r12), %eax incq %r12 movb (%r14,%rax), %al movb %al, (%rbx) incq %rbx jmp 0xb3ff2 movb (%r12), %al movq 0x78(%r13), %rcx testq %rcx, %rcx je 0xb3fe0 movzbl %al, %edx movq 0x8(%rcx), %rcx movq (%rcx,%rdx,8), %rcx testq %rcx, %rcx je 0xb3fe0 movzbl 0x1(%r12), %eax leaq (%rax,%rax,2), %rax leaq (%rcx,%rax,4), %rax movq -0x38(%rbp), %rcx movl (%rcx,%rax), %eax cmpl $0x100, %eax # imm = 0x100 jl 0xb3fd9 movb %ah, (%rbx) incq %rbx movb %al, (%rbx) incq %rbx jmp 0xb3fee movb %al, (%rbx) movb 0x1(%r12), %al movb %al, 0x1(%rbx) addq $0x2, %rbx addq $0x2, %r12 cmpq %r15, %r12 jb 0xb3f6d subq -0x30(%rbp), %rbx movq %rbx, %rax addq $0x18, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
my_casefold_mb: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx sub rsp, 18h mov rbx, rcx mov [rbp+var_30], rcx test rdx, rdx jle loc_B3FFB mov r14, r8 mov r15, rdx mov r12, rsi mov r13, rdi add r15, rsi xor eax, eax test r9, r9 setz al shl eax, 2 mov [rbp+var_38], rax mov rbx, [rbp+var_30] loc_B3F6D: mov rax, [r13+0B8h] mov rdi, r13 mov rsi, r12 mov rdx, r15 call qword ptr [rax+0C0h] cmp eax, 2 jge short loc_B3F9B movzx eax, byte ptr [r12] inc r12 mov al, [r14+rax] mov [rbx], al inc rbx jmp short loc_B3FF2 loc_B3F9B: mov al, [r12] mov rcx, [r13+78h] test rcx, rcx jz short loc_B3FE0 movzx edx, al mov rcx, [rcx+8] mov rcx, [rcx+rdx*8] test rcx, rcx jz short loc_B3FE0 movzx eax, byte ptr [r12+1] lea rax, [rax+rax*2] lea rax, [rcx+rax*4] mov rcx, [rbp+var_38] mov eax, [rcx+rax] cmp eax, 100h jl short loc_B3FD9 mov [rbx], ah inc rbx loc_B3FD9: mov [rbx], al inc rbx jmp short loc_B3FEE loc_B3FE0: mov [rbx], al mov al, [r12+1] mov [rbx+1], al add rbx, 2 loc_B3FEE: add r12, 2 loc_B3FF2: cmp r12, r15 jb loc_B3F6D loc_B3FFB: sub rbx, [rbp+var_30] mov rax, rbx add rsp, 18h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
_BYTE * my_casefold_mb( long long a1, unsigned __int8 *a2, long long a3, unsigned __int8 *a4, long long a5, long long a6) { unsigned __int8 *v6; // rbx unsigned __int8 *v8; // r12 unsigned long long v9; // r15 long long v10; // rax unsigned __int8 v11; // al long long v12; // rcx long long v13; // rcx int v14; // eax long long v16; // [rsp+8h] [rbp-38h] v6 = a4; if ( a3 > 0 ) { v8 = a2; v9 = (unsigned long long)&a2[a3]; v16 = 4 * (unsigned int)(a6 == 0); v6 = a4; do { if ( (*(int ( **)(long long, unsigned __int8 *, unsigned long long))(*(_QWORD *)(a1 + 184) + 192LL))( a1, v8, v9) >= 2 ) { v11 = *v8; v12 = *(_QWORD *)(a1 + 120); if ( v12 && (v13 = *(_QWORD *)(*(_QWORD *)(v12 + 8) + 8LL * v11)) != 0 ) { v14 = *(_DWORD *)(v16 + v13 + 12LL * v8[1]); if ( v14 >= 256 ) *v6++ = BYTE1(v14); *v6++ = v14; } else { *v6 = v11; v6[1] = v8[1]; v6 += 2; } v8 += 2; } else { v10 = *v8++; *v6++ = *(_BYTE *)(a5 + v10); } } while ( (unsigned long long)v8 < v9 ); } return (_BYTE *)(v6 - a4); }
my_casefold_mb: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x18 MOV RBX,RCX MOV qword ptr [RBP + -0x30],RCX TEST RDX,RDX JLE 0x001b3ffb MOV R14,R8 MOV R15,RDX MOV R12,RSI MOV R13,RDI ADD R15,RSI XOR EAX,EAX TEST R9,R9 SETZ AL SHL EAX,0x2 MOV qword ptr [RBP + -0x38],RAX MOV RBX,qword ptr [RBP + -0x30] LAB_001b3f6d: MOV RAX,qword ptr [R13 + 0xb8] MOV RDI,R13 MOV RSI,R12 MOV RDX,R15 CALL qword ptr [RAX + 0xc0] CMP EAX,0x2 JGE 0x001b3f9b MOVZX EAX,byte ptr [R12] INC R12 MOV AL,byte ptr [R14 + RAX*0x1] MOV byte ptr [RBX],AL INC RBX JMP 0x001b3ff2 LAB_001b3f9b: MOV AL,byte ptr [R12] MOV RCX,qword ptr [R13 + 0x78] TEST RCX,RCX JZ 0x001b3fe0 MOVZX EDX,AL MOV RCX,qword ptr [RCX + 0x8] MOV RCX,qword ptr [RCX + RDX*0x8] TEST RCX,RCX JZ 0x001b3fe0 MOVZX EAX,byte ptr [R12 + 0x1] LEA RAX,[RAX + RAX*0x2] LEA RAX,[RCX + RAX*0x4] MOV RCX,qword ptr [RBP + -0x38] MOV EAX,dword ptr [RCX + RAX*0x1] CMP EAX,0x100 JL 0x001b3fd9 MOV byte ptr [RBX],AH INC RBX LAB_001b3fd9: MOV byte ptr [RBX],AL INC RBX JMP 0x001b3fee LAB_001b3fe0: MOV byte ptr [RBX],AL MOV AL,byte ptr [R12 + 0x1] MOV byte ptr [RBX + 0x1],AL ADD RBX,0x2 LAB_001b3fee: ADD R12,0x2 LAB_001b3ff2: CMP R12,R15 JC 0x001b3f6d LAB_001b3ffb: SUB RBX,qword ptr [RBP + -0x30] MOV RAX,RBX ADD RSP,0x18 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
long my_casefold_mb(long param_1,byte *param_2,long param_3,byte *param_4,long param_5,long param_6) { byte bVar1; long lVar2; int iVar3; byte *pbVar4; byte *pbVar5; pbVar4 = param_4; if (0 < param_3) { pbVar5 = param_2 + param_3; do { iVar3 = (**(code **)(*(long *)(param_1 + 0xb8) + 0xc0))(param_1,param_2,pbVar5); if (iVar3 < 2) { bVar1 = *param_2; param_2 = param_2 + 1; *pbVar4 = *(byte *)(param_5 + (ulong)bVar1); pbVar4 = pbVar4 + 1; } else { if ((*(long *)(param_1 + 0x78) == 0) || (lVar2 = *(long *)(*(long *)(*(long *)(param_1 + 0x78) + 8) + (ulong)*param_2 * 8), lVar2 == 0)) { *pbVar4 = *param_2; pbVar4[1] = param_2[1]; pbVar4 = pbVar4 + 2; } else { iVar3 = *(int *)((ulong)(param_6 == 0) * 4 + lVar2 + (ulong)param_2[1] * 0xc); if (0xff < iVar3) { *pbVar4 = (byte)((uint)iVar3 >> 8); pbVar4 = pbVar4 + 1; } *pbVar4 = (byte)iVar3; pbVar4 = pbVar4 + 1; } param_2 = param_2 + 2; } } while (param_2 < pbVar5); } return (long)pbVar4 - (long)param_4; }
6,039
ankerl::nanobench::Result::add(std::chrono::duration<long, std::ratio<1l, 1000000000l>>, unsigned long, ankerl::nanobench::detail::PerformanceCounters const&)
BadAccessGuards/build_O3/_deps/nanobench-src/src/include/nanobench.h
void Result::add(Clock::duration totalElapsed, uint64_t iters, detail::PerformanceCounters const& pc) { using detail::d; using detail::u; double const dIters = d(iters); mNameToMeasurements[u(Result::Measure::iterations)].push_back(dIters); mNameToMeasurements[u(Result::Measure::elapsed)].push_back(d(totalElapsed) / dIters); if (pc.has().pageFaults) { mNameToMeasurements[u(Result::Measure::pagefaults)].push_back(d(pc.val().pageFaults) / dIters); } if (pc.has().cpuCycles) { mNameToMeasurements[u(Result::Measure::cpucycles)].push_back(d(pc.val().cpuCycles) / dIters); } if (pc.has().contextSwitches) { mNameToMeasurements[u(Result::Measure::contextswitches)].push_back(d(pc.val().contextSwitches) / dIters); } if (pc.has().instructions) { mNameToMeasurements[u(Result::Measure::instructions)].push_back(d(pc.val().instructions) / dIters); } if (pc.has().branchInstructions) { double branchInstructions = 0.0; // correcting branches: remove branch introduced by the while (...) loop for each iteration. if (pc.val().branchInstructions > iters + 1U) { branchInstructions = d(pc.val().branchInstructions - (iters + 1U)); } mNameToMeasurements[u(Result::Measure::branchinstructions)].push_back(branchInstructions / dIters); if (pc.has().branchMisses) { // correcting branch misses double branchMisses = d(pc.val().branchMisses); if (branchMisses > branchInstructions) { // can't have branch misses when there were branches... branchMisses = branchInstructions; } // assuming at least one missed branch for the loop branchMisses -= 1.0; if (branchMisses < 1.0) { branchMisses = 1.0; } mNameToMeasurements[u(Result::Measure::branchmisses)].push_back(branchMisses / dIters); } } }
O3
c
ankerl::nanobench::Result::add(std::chrono::duration<long, std::ratio<1l, 1000000000l>>, unsigned long, ankerl::nanobench::detail::PerformanceCounters const&): pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x20, %rsp movq %rcx, %r14 movq %rdx, %r15 movq %rsi, %r12 movq %rdi, %rbx movq %rdx, %xmm1 punpckldq 0xa872(%rip), %xmm1 # xmm1 = xmm1[0],mem[0],xmm1[1],mem[1] subpd 0xa87a(%rip), %xmm1 # 0x153e0 movapd %xmm1, %xmm0 unpckhpd %xmm1, %xmm0 # xmm0 = xmm0[1],xmm1[1] addsd %xmm1, %xmm0 movsd %xmm0, 0x8(%rsp) movq 0x118(%rdi), %rdi movq 0x20(%rdi), %rsi cmpq 0x28(%rdi), %rsi je 0xab97 movsd %xmm0, (%rsi) addq $0x8, %rsi movq %rsi, 0x20(%rdi) jmp 0xabb5 addq $0x18, %rdi leaq 0x8(%rsp), %r13 movq %r13, %rdx callq 0x12ada movq 0x118(%rbx), %rdi movsd (%r13), %xmm0 xorps %xmm1, %xmm1 cvtsi2sd %r12, %xmm1 divsd 0xa87b(%rip), %xmm1 # 0x15440 divsd %xmm0, %xmm1 movsd %xmm1, (%rsp) movq 0x8(%rdi), %rsi cmpq 0x10(%rdi), %rsi je 0xabe6 movsd %xmm1, (%rsi) addq $0x8, %rsi movq %rsi, 0x8(%rdi) jmp 0xabee movq %rsp, %rdx callq 0x12bfe cmpb $0x1, 0x38(%r14) jne 0xac4c movsd 0x8(%r14), %xmm1 unpcklps 0xa7ce(%rip), %xmm1 # xmm1 = xmm1[0],mem[0],xmm1[1],mem[1] movq 0x118(%rbx), %rdi subpd 0xa7cf(%rip), %xmm1 # 0x153e0 movapd %xmm1, %xmm0 unpckhpd %xmm1, %xmm0 # xmm0 = xmm0[1],xmm1[1] addsd %xmm1, %xmm0 divsd 0x8(%rsp), %xmm0 movsd %xmm0, (%rsp) movq 0x38(%rdi), %rsi cmpq 0x40(%rdi), %rsi je 0xac40 movsd %xmm0, (%rsi) addq $0x8, %rsi movq %rsi, 0x38(%rdi) jmp 0xac4c addq $0x30, %rdi movq %rsp, %rdx callq 0x12bfe cmpb $0x1, 0x39(%r14) jne 0xacaa movsd 0x10(%r14), %xmm1 unpcklps 0xa770(%rip), %xmm1 # xmm1 = xmm1[0],mem[0],xmm1[1],mem[1] movq 0x118(%rbx), %rdi subpd 0xa771(%rip), %xmm1 # 0x153e0 movapd %xmm1, %xmm0 unpckhpd %xmm1, %xmm0 # xmm0 = xmm0[1],xmm1[1] addsd %xmm1, %xmm0 divsd 0x8(%rsp), %xmm0 movsd %xmm0, (%rsp) movq 0x50(%rdi), %rsi cmpq 0x58(%rdi), %rsi je 0xac9e movsd %xmm0, (%rsi) addq $0x8, %rsi movq %rsi, 0x50(%rdi) jmp 0xacaa addq $0x48, %rdi movq %rsp, %rdx callq 0x12bfe cmpb $0x1, 0x3a(%r14) jne 0xad08 movsd 0x18(%r14), %xmm1 unpcklps 0xa712(%rip), %xmm1 # xmm1 = xmm1[0],mem[0],xmm1[1],mem[1] movq 0x118(%rbx), %rdi subpd 0xa713(%rip), %xmm1 # 0x153e0 movapd %xmm1, %xmm0 unpckhpd %xmm1, %xmm0 # xmm0 = xmm0[1],xmm1[1] addsd %xmm1, %xmm0 divsd 0x8(%rsp), %xmm0 movsd %xmm0, (%rsp) movq 0x68(%rdi), %rsi cmpq 0x70(%rdi), %rsi je 0xacfc movsd %xmm0, (%rsi) addq $0x8, %rsi movq %rsi, 0x68(%rdi) jmp 0xad08 addq $0x60, %rdi movq %rsp, %rdx callq 0x12bfe cmpb $0x1, 0x3b(%r14) jne 0xad6f movsd 0x20(%r14), %xmm1 unpcklps 0xa6b4(%rip), %xmm1 # xmm1 = xmm1[0],mem[0],xmm1[1],mem[1] movq 0x118(%rbx), %rdi subpd 0xa6b5(%rip), %xmm1 # 0x153e0 movapd %xmm1, %xmm0 unpckhpd %xmm1, %xmm0 # xmm0 = xmm0[1],xmm1[1] addsd %xmm1, %xmm0 divsd 0x8(%rsp), %xmm0 movsd %xmm0, (%rsp) movq 0x80(%rdi), %rsi cmpq 0x88(%rdi), %rsi je 0xad63 movsd %xmm0, (%rsi) addq $0x8, %rsi movq %rsi, 0x80(%rdi) jmp 0xad6f addq $0x78, %rdi movq %rsp, %rdx callq 0x12bfe cmpb $0x1, 0x3c(%r14) jne 0xae81 movq 0x28(%r14), %rax incq %r15 subq %r15, %rax ja 0xad8c xorpd %xmm2, %xmm2 jmp 0xadad movq %rax, %xmm0 punpckldq 0xa637(%rip), %xmm0 # xmm0 = xmm0[0],mem[0],xmm0[1],mem[1] subpd 0xa63f(%rip), %xmm0 # 0x153e0 movapd %xmm0, %xmm2 unpckhpd %xmm0, %xmm2 # xmm2 = xmm2[1],xmm0[1] addsd %xmm0, %xmm2 movq 0x118(%rbx), %rdi movapd %xmm2, %xmm0 divsd 0x8(%rsp), %xmm0 movsd %xmm0, (%rsp) movq 0x98(%rdi), %rsi cmpq 0xa0(%rdi), %rsi je 0xade4 movsd %xmm0, (%rsi) addq $0x8, %rsi movq %rsi, 0x98(%rdi) jmp 0xadff addq $0x90, %rdi movq %rsp, %rdx movapd %xmm2, 0x10(%rsp) callq 0x12bfe movapd 0x10(%rsp), %xmm2 cmpb $0x1, 0x3d(%r14) jne 0xae81 movsd 0x30(%r14), %xmm0 unpcklps 0xa5bd(%rip), %xmm0 # xmm0 = xmm0[0],mem[0],xmm0[1],mem[1] subpd 0xa5c5(%rip), %xmm0 # 0x153e0 movapd %xmm0, %xmm1 unpckhpd %xmm0, %xmm1 # xmm1 = xmm1[1],xmm0[1] addsd %xmm0, %xmm1 minsd %xmm1, %xmm2 addsd 0xa61d(%rip), %xmm2 # 0x15450 movsd 0xa61d(%rip), %xmm0 # 0x15458 maxsd %xmm2, %xmm0 movq 0x118(%rbx), %rdi divsd 0x8(%rsp), %xmm0 movsd %xmm0, (%rsp) movq 0xb0(%rdi), %rsi cmpq 0xb8(%rdi), %rsi je 0xae72 movsd %xmm0, (%rsi) addq $0x8, %rsi movq %rsi, 0xb0(%rdi) jmp 0xae81 addq $0xa8, %rdi movq %rsp, %rdx callq 0x12bfe addq $0x20, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 retq nop
_ZN6ankerl9nanobench6Result3addENSt6chrono8durationIlSt5ratioILl1ELl1000000000EEEEmRKNS0_6detail19PerformanceCountersE: push r15 push r14 push r13 push r12 push rbx sub rsp, 20h mov r14, rcx mov r15, rdx mov r12, rsi mov rbx, rdi movq xmm1, rdx punpckldq xmm1, cs:xmmword_153D0 subpd xmm1, cs:xmmword_153E0 movapd xmm0, xmm1 unpckhpd xmm0, xmm1 addsd xmm0, xmm1 movsd [rsp+48h+var_40], xmm0 mov rdi, [rdi+118h] mov rsi, [rdi+20h] cmp rsi, [rdi+28h] jz short loc_AB97 movsd qword ptr [rsi], xmm0 add rsi, 8 mov [rdi+20h], rsi jmp short loc_ABB5 loc_AB97: add rdi, 18h lea r13, [rsp+48h+var_40] mov rdx, r13 call _ZNSt6vectorIdSaIdEE17_M_realloc_insertIJRKdEEEvN9__gnu_cxx17__normal_iteratorIPdS1_EEDpOT_; std::vector<double>::_M_realloc_insert<double const&>(__gnu_cxx::__normal_iterator<double *,std::vector<double>>,double const&) mov rdi, [rbx+118h] movsd xmm0, qword ptr [r13+0] loc_ABB5: xorps xmm1, xmm1 cvtsi2sd xmm1, r12 divsd xmm1, cs:qword_15440 divsd xmm1, xmm0 movsd [rsp+48h+var_48], xmm1 mov rsi, [rdi+8] cmp rsi, [rdi+10h] jz short loc_ABE6 movsd qword ptr [rsi], xmm1 add rsi, 8 mov [rdi+8], rsi jmp short loc_ABEE loc_ABE6: mov rdx, rsp call _ZNSt6vectorIdSaIdEE17_M_realloc_insertIJdEEEvN9__gnu_cxx17__normal_iteratorIPdS1_EEDpOT_; std::vector<double>::_M_realloc_insert<double>(__gnu_cxx::__normal_iterator<double *,std::vector<double>>,double &&) loc_ABEE: cmp byte ptr [r14+38h], 1 jnz short loc_AC4C movsd xmm1, qword ptr [r14+8] unpcklps xmm1, cs:xmmword_153D0 mov rdi, [rbx+118h] subpd xmm1, cs:xmmword_153E0 movapd xmm0, xmm1 unpckhpd xmm0, xmm1 addsd xmm0, xmm1 divsd xmm0, [rsp+48h+var_40] movsd [rsp+48h+var_48], xmm0 mov rsi, [rdi+38h] cmp rsi, [rdi+40h] jz short loc_AC40 movsd qword ptr [rsi], xmm0 add rsi, 8 mov [rdi+38h], rsi jmp short loc_AC4C loc_AC40: add rdi, 30h ; '0' mov rdx, rsp call _ZNSt6vectorIdSaIdEE17_M_realloc_insertIJdEEEvN9__gnu_cxx17__normal_iteratorIPdS1_EEDpOT_; std::vector<double>::_M_realloc_insert<double>(__gnu_cxx::__normal_iterator<double *,std::vector<double>>,double &&) loc_AC4C: cmp byte ptr [r14+39h], 1 jnz short loc_ACAA movsd xmm1, qword ptr [r14+10h] unpcklps xmm1, cs:xmmword_153D0 mov rdi, [rbx+118h] subpd xmm1, cs:xmmword_153E0 movapd xmm0, xmm1 unpckhpd xmm0, xmm1 addsd xmm0, xmm1 divsd xmm0, [rsp+48h+var_40] movsd [rsp+48h+var_48], xmm0 mov rsi, [rdi+50h] cmp rsi, [rdi+58h] jz short loc_AC9E movsd qword ptr [rsi], xmm0 add rsi, 8 mov [rdi+50h], rsi jmp short loc_ACAA loc_AC9E: add rdi, 48h ; 'H' mov rdx, rsp call _ZNSt6vectorIdSaIdEE17_M_realloc_insertIJdEEEvN9__gnu_cxx17__normal_iteratorIPdS1_EEDpOT_; std::vector<double>::_M_realloc_insert<double>(__gnu_cxx::__normal_iterator<double *,std::vector<double>>,double &&) loc_ACAA: cmp byte ptr [r14+3Ah], 1 jnz short loc_AD08 movsd xmm1, qword ptr [r14+18h] unpcklps xmm1, cs:xmmword_153D0 mov rdi, [rbx+118h] subpd xmm1, cs:xmmword_153E0 movapd xmm0, xmm1 unpckhpd xmm0, xmm1 addsd xmm0, xmm1 divsd xmm0, [rsp+48h+var_40] movsd [rsp+48h+var_48], xmm0 mov rsi, [rdi+68h] cmp rsi, [rdi+70h] jz short loc_ACFC movsd qword ptr [rsi], xmm0 add rsi, 8 mov [rdi+68h], rsi jmp short loc_AD08 loc_ACFC: add rdi, 60h ; '`' mov rdx, rsp call _ZNSt6vectorIdSaIdEE17_M_realloc_insertIJdEEEvN9__gnu_cxx17__normal_iteratorIPdS1_EEDpOT_; std::vector<double>::_M_realloc_insert<double>(__gnu_cxx::__normal_iterator<double *,std::vector<double>>,double &&) loc_AD08: cmp byte ptr [r14+3Bh], 1 jnz short loc_AD6F movsd xmm1, qword ptr [r14+20h] unpcklps xmm1, cs:xmmword_153D0 mov rdi, [rbx+118h] subpd xmm1, cs:xmmword_153E0 movapd xmm0, xmm1 unpckhpd xmm0, xmm1 addsd xmm0, xmm1 divsd xmm0, [rsp+48h+var_40] movsd [rsp+48h+var_48], xmm0 mov rsi, [rdi+80h] cmp rsi, [rdi+88h] jz short loc_AD63 movsd qword ptr [rsi], xmm0 add rsi, 8 mov [rdi+80h], rsi jmp short loc_AD6F loc_AD63: add rdi, 78h ; 'x' mov rdx, rsp call _ZNSt6vectorIdSaIdEE17_M_realloc_insertIJdEEEvN9__gnu_cxx17__normal_iteratorIPdS1_EEDpOT_; std::vector<double>::_M_realloc_insert<double>(__gnu_cxx::__normal_iterator<double *,std::vector<double>>,double &&) loc_AD6F: cmp byte ptr [r14+3Ch], 1 jnz loc_AE81 mov rax, [r14+28h] inc r15 sub rax, r15 ja short loc_AD8C xorpd xmm2, xmm2 jmp short loc_ADAD loc_AD8C: movq xmm0, rax punpckldq xmm0, cs:xmmword_153D0 subpd xmm0, cs:xmmword_153E0 movapd xmm2, xmm0 unpckhpd xmm2, xmm0 addsd xmm2, xmm0 loc_ADAD: mov rdi, [rbx+118h] movapd xmm0, xmm2 divsd xmm0, [rsp+48h+var_40] movsd [rsp+48h+var_48], xmm0 mov rsi, [rdi+98h] cmp rsi, [rdi+0A0h] jz short loc_ADE4 movsd qword ptr [rsi], xmm0 add rsi, 8 mov [rdi+98h], rsi jmp short loc_ADFF loc_ADE4: add rdi, 90h mov rdx, rsp movapd [rsp+48h+var_38], xmm2 call _ZNSt6vectorIdSaIdEE17_M_realloc_insertIJdEEEvN9__gnu_cxx17__normal_iteratorIPdS1_EEDpOT_; std::vector<double>::_M_realloc_insert<double>(__gnu_cxx::__normal_iterator<double *,std::vector<double>>,double &&) movapd xmm2, [rsp+48h+var_38] loc_ADFF: cmp byte ptr [r14+3Dh], 1 jnz short loc_AE81 movsd xmm0, qword ptr [r14+30h] unpcklps xmm0, cs:xmmword_153D0 subpd xmm0, cs:xmmword_153E0 movapd xmm1, xmm0 unpckhpd xmm1, xmm0 addsd xmm1, xmm0 minsd xmm2, xmm1 addsd xmm2, cs:qword_15450 movsd xmm0, cs:qword_15458 maxsd xmm0, xmm2 mov rdi, [rbx+118h] divsd xmm0, [rsp+48h+var_40] movsd [rsp+48h+var_48], xmm0 mov rsi, [rdi+0B0h] cmp rsi, [rdi+0B8h] jz short loc_AE72 movsd qword ptr [rsi], xmm0 add rsi, 8 mov [rdi+0B0h], rsi jmp short loc_AE81 loc_AE72: add rdi, 0A8h mov rdx, rsp call _ZNSt6vectorIdSaIdEE17_M_realloc_insertIJdEEEvN9__gnu_cxx17__normal_iteratorIPdS1_EEDpOT_; std::vector<double>::_M_realloc_insert<double>(__gnu_cxx::__normal_iterator<double *,std::vector<double>>,double &&) loc_AE81: add rsp, 20h pop rbx pop r12 pop r13 pop r14 pop r15 retn
void ankerl::nanobench::Result::add(long long a1, int a2, unsigned long long a3, long long a4) { __m128d v8; // xmm1 double v9; // xmm0_8 _QWORD *v10; // rdi double *v11; // rsi double *v12; // rsi long long v13; // rdi __m128d v14; // xmm1 double v15; // xmm0_8 double *v16; // rsi long long v17; // rdi __m128d v18; // xmm1 double v19; // xmm0_8 double *v20; // rsi long long v21; // rdi __m128d v22; // xmm1 double v23; // xmm0_8 double *v24; // rsi long long v25; // rdi __m128d v26; // xmm1 double v27; // xmm0_8 double *v28; // rsi unsigned long long v29; // rax unsigned long long v30; // r15 bool v31; // cc unsigned long long v32; // rax __m128d v33; // xmm2 __m128d v34; // xmm0 long long v35; // rdi double *v36; // rsi __m128d v37; // xmm0 long long v38; // rdi double v39; // xmm0_8 double *v40; // rsi double v41; // [rsp+0h] [rbp-48h] BYREF double v42; // [rsp+8h] [rbp-40h] BYREF __m128d v43; // [rsp+10h] [rbp-38h] v8 = _mm_sub_pd((__m128d)_mm_unpacklo_epi32((__m128i)a3, (__m128i)xmmword_153D0), (__m128d)xmmword_153E0); v9 = _mm_unpackhi_pd(v8, v8).m128d_f64[0] + v8.m128d_f64[0]; v42 = v9; v10 = *(_QWORD **)(a1 + 280); v11 = (double *)v10[4]; if ( v11 == (double *)v10[5] ) { std::vector<double>::_M_realloc_insert<double const&>(v10 + 3, v11, &v42); v10 = *(_QWORD **)(a1 + 280); v9 = v42; } else { *v11 = v9; v10[4] = v11 + 1; } v41 = (double)a2 / 1000000000.0 / v9; v12 = (double *)v10[1]; if ( v12 == (double *)v10[2] ) { std::vector<double>::_M_realloc_insert<double>(v10, v12, &v41); } else { *v12 = (double)a2 / 1000000000.0 / v9; v10[1] = v12 + 1; } if ( *(_BYTE *)(a4 + 56) == 1 ) { v13 = *(_QWORD *)(a1 + 280); v14 = _mm_sub_pd( (__m128d)_mm_unpacklo_ps((__m128)*(unsigned long long *)(a4 + 8), (__m128)xmmword_153D0), (__m128d)xmmword_153E0); v15 = (_mm_unpackhi_pd(v14, v14).m128d_f64[0] + v14.m128d_f64[0]) / v42; v41 = v15; v16 = *(double **)(v13 + 56); if ( v16 == *(double **)(v13 + 64) ) { std::vector<double>::_M_realloc_insert<double>(v13 + 48, v16, &v41); } else { *v16 = v15; *(_QWORD *)(v13 + 56) = v16 + 1; } } if ( *(_BYTE *)(a4 + 57) == 1 ) { v17 = *(_QWORD *)(a1 + 280); v18 = _mm_sub_pd( (__m128d)_mm_unpacklo_ps((__m128)*(unsigned long long *)(a4 + 16), (__m128)xmmword_153D0), (__m128d)xmmword_153E0); v19 = (_mm_unpackhi_pd(v18, v18).m128d_f64[0] + v18.m128d_f64[0]) / v42; v41 = v19; v20 = *(double **)(v17 + 80); if ( v20 == *(double **)(v17 + 88) ) { std::vector<double>::_M_realloc_insert<double>(v17 + 72, v20, &v41); } else { *v20 = v19; *(_QWORD *)(v17 + 80) = v20 + 1; } } if ( *(_BYTE *)(a4 + 58) == 1 ) { v21 = *(_QWORD *)(a1 + 280); v22 = _mm_sub_pd( (__m128d)_mm_unpacklo_ps((__m128)*(unsigned long long *)(a4 + 24), (__m128)xmmword_153D0), (__m128d)xmmword_153E0); v23 = (_mm_unpackhi_pd(v22, v22).m128d_f64[0] + v22.m128d_f64[0]) / v42; v41 = v23; v24 = *(double **)(v21 + 104); if ( v24 == *(double **)(v21 + 112) ) { std::vector<double>::_M_realloc_insert<double>(v21 + 96, v24, &v41); } else { *v24 = v23; *(_QWORD *)(v21 + 104) = v24 + 1; } } if ( *(_BYTE *)(a4 + 59) == 1 ) { v25 = *(_QWORD *)(a1 + 280); v26 = _mm_sub_pd( (__m128d)_mm_unpacklo_ps((__m128)*(unsigned long long *)(a4 + 32), (__m128)xmmword_153D0), (__m128d)xmmword_153E0); v27 = (_mm_unpackhi_pd(v26, v26).m128d_f64[0] + v26.m128d_f64[0]) / v42; v41 = v27; v28 = *(double **)(v25 + 128); if ( v28 == *(double **)(v25 + 136) ) { std::vector<double>::_M_realloc_insert<double>(v25 + 120, v28, &v41); } else { *v28 = v27; *(_QWORD *)(v25 + 128) = v28 + 1; } } if ( *(_BYTE *)(a4 + 60) == 1 ) { v29 = *(_QWORD *)(a4 + 40); v30 = a3 + 1; v31 = v29 <= v30; v32 = v29 - v30; if ( v31 ) { v33 = 0LL; } else { v34 = _mm_sub_pd((__m128d)_mm_unpacklo_epi32((__m128i)v32, (__m128i)xmmword_153D0), (__m128d)xmmword_153E0); v33 = _mm_unpackhi_pd(v34, v34); v33.m128d_f64[0] = v33.m128d_f64[0] + v34.m128d_f64[0]; } v35 = *(_QWORD *)(a1 + 280); v41 = v33.m128d_f64[0] / v42; v36 = *(double **)(v35 + 152); if ( v36 == *(double **)(v35 + 160) ) { v43 = v33; std::vector<double>::_M_realloc_insert<double>(v35 + 144, v36, &v41); v33.m128d_f64[0] = v43.m128d_f64[0]; } else { *v36 = v33.m128d_f64[0] / v42; *(_QWORD *)(v35 + 152) = v36 + 1; } if ( *(_BYTE *)(a4 + 61) == 1 ) { v37 = _mm_sub_pd( (__m128d)_mm_unpacklo_ps((__m128)*(unsigned long long *)(a4 + 48), (__m128)xmmword_153D0), (__m128d)xmmword_153E0); v38 = *(_QWORD *)(a1 + 280); v39 = fmax(1.0, fmin(v33.m128d_f64[0], _mm_unpackhi_pd(v37, v37).m128d_f64[0] + v37.m128d_f64[0]) + -1.0) / v42; v41 = v39; v40 = *(double **)(v38 + 176); if ( v40 == *(double **)(v38 + 184) ) { std::vector<double>::_M_realloc_insert<double>(v38 + 168, v40, &v41); } else { *v40 = v39; *(_QWORD *)(v38 + 176) = v40 + 1; } } } }
add: PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x20 MOV R14,RCX MOV R15,RDX MOV R12,RSI MOV RBX,RDI MOVQ XMM1,RDX PUNPCKLDQ XMM1,xmmword ptr [0x001153d0] SUBPD XMM1,xmmword ptr [0x001153e0] MOVAPD XMM0,XMM1 UNPCKHPD XMM0,XMM1 ADDSD XMM0,XMM1 MOVSD qword ptr [RSP + 0x8],XMM0 MOV RDI,qword ptr [RDI + 0x118] MOV RSI,qword ptr [RDI + 0x20] CMP RSI,qword ptr [RDI + 0x28] JZ 0x0010ab97 MOVSD qword ptr [RSI],XMM0 ADD RSI,0x8 MOV qword ptr [RDI + 0x20],RSI JMP 0x0010abb5 LAB_0010ab97: ADD RDI,0x18 LEA R13,[RSP + 0x8] MOV RDX,R13 CALL 0x00112ada MOV RDI,qword ptr [RBX + 0x118] MOVSD XMM0,qword ptr [R13] LAB_0010abb5: XORPS XMM1,XMM1 CVTSI2SD XMM1,R12 DIVSD XMM1,qword ptr [0x00115440] DIVSD XMM1,XMM0 MOVSD qword ptr [RSP],XMM1 MOV RSI,qword ptr [RDI + 0x8] CMP RSI,qword ptr [RDI + 0x10] JZ 0x0010abe6 MOVSD qword ptr [RSI],XMM1 ADD RSI,0x8 MOV qword ptr [RDI + 0x8],RSI JMP 0x0010abee LAB_0010abe6: MOV RDX,RSP CALL 0x00112bfe LAB_0010abee: CMP byte ptr [R14 + 0x38],0x1 JNZ 0x0010ac4c MOVSD XMM1,qword ptr [R14 + 0x8] UNPCKLPS XMM1,xmmword ptr [0x001153d0] MOV RDI,qword ptr [RBX + 0x118] SUBPD XMM1,xmmword ptr [0x001153e0] MOVAPD XMM0,XMM1 UNPCKHPD XMM0,XMM1 ADDSD XMM0,XMM1 DIVSD XMM0,qword ptr [RSP + 0x8] MOVSD qword ptr [RSP],XMM0 MOV RSI,qword ptr [RDI + 0x38] CMP RSI,qword ptr [RDI + 0x40] JZ 0x0010ac40 MOVSD qword ptr [RSI],XMM0 ADD RSI,0x8 MOV qword ptr [RDI + 0x38],RSI JMP 0x0010ac4c LAB_0010ac40: ADD RDI,0x30 MOV RDX,RSP CALL 0x00112bfe LAB_0010ac4c: CMP byte ptr [R14 + 0x39],0x1 JNZ 0x0010acaa MOVSD XMM1,qword ptr [R14 + 0x10] UNPCKLPS XMM1,xmmword ptr [0x001153d0] MOV RDI,qword ptr [RBX + 0x118] SUBPD XMM1,xmmword ptr [0x001153e0] MOVAPD XMM0,XMM1 UNPCKHPD XMM0,XMM1 ADDSD XMM0,XMM1 DIVSD XMM0,qword ptr [RSP + 0x8] MOVSD qword ptr [RSP],XMM0 MOV RSI,qword ptr [RDI + 0x50] CMP RSI,qword ptr [RDI + 0x58] JZ 0x0010ac9e MOVSD qword ptr [RSI],XMM0 ADD RSI,0x8 MOV qword ptr [RDI + 0x50],RSI JMP 0x0010acaa LAB_0010ac9e: ADD RDI,0x48 MOV RDX,RSP CALL 0x00112bfe LAB_0010acaa: CMP byte ptr [R14 + 0x3a],0x1 JNZ 0x0010ad08 MOVSD XMM1,qword ptr [R14 + 0x18] UNPCKLPS XMM1,xmmword ptr [0x001153d0] MOV RDI,qword ptr [RBX + 0x118] SUBPD XMM1,xmmword ptr [0x001153e0] MOVAPD XMM0,XMM1 UNPCKHPD XMM0,XMM1 ADDSD XMM0,XMM1 DIVSD XMM0,qword ptr [RSP + 0x8] MOVSD qword ptr [RSP],XMM0 MOV RSI,qword ptr [RDI + 0x68] CMP RSI,qword ptr [RDI + 0x70] JZ 0x0010acfc MOVSD qword ptr [RSI],XMM0 ADD RSI,0x8 MOV qword ptr [RDI + 0x68],RSI JMP 0x0010ad08 LAB_0010acfc: ADD RDI,0x60 MOV RDX,RSP CALL 0x00112bfe LAB_0010ad08: CMP byte ptr [R14 + 0x3b],0x1 JNZ 0x0010ad6f MOVSD XMM1,qword ptr [R14 + 0x20] UNPCKLPS XMM1,xmmword ptr [0x001153d0] MOV RDI,qword ptr [RBX + 0x118] SUBPD XMM1,xmmword ptr [0x001153e0] MOVAPD XMM0,XMM1 UNPCKHPD XMM0,XMM1 ADDSD XMM0,XMM1 DIVSD XMM0,qword ptr [RSP + 0x8] MOVSD qword ptr [RSP],XMM0 MOV RSI,qword ptr [RDI + 0x80] CMP RSI,qword ptr [RDI + 0x88] JZ 0x0010ad63 MOVSD qword ptr [RSI],XMM0 ADD RSI,0x8 MOV qword ptr [RDI + 0x80],RSI JMP 0x0010ad6f LAB_0010ad63: ADD RDI,0x78 MOV RDX,RSP CALL 0x00112bfe LAB_0010ad6f: CMP byte ptr [R14 + 0x3c],0x1 JNZ 0x0010ae81 MOV RAX,qword ptr [R14 + 0x28] INC R15 SUB RAX,R15 JA 0x0010ad8c XORPD XMM2,XMM2 JMP 0x0010adad LAB_0010ad8c: MOVQ XMM0,RAX PUNPCKLDQ XMM0,xmmword ptr [0x001153d0] SUBPD XMM0,xmmword ptr [0x001153e0] MOVAPD XMM2,XMM0 UNPCKHPD XMM2,XMM0 ADDSD XMM2,XMM0 LAB_0010adad: MOV RDI,qword ptr [RBX + 0x118] MOVAPD XMM0,XMM2 DIVSD XMM0,qword ptr [RSP + 0x8] MOVSD qword ptr [RSP],XMM0 MOV RSI,qword ptr [RDI + 0x98] CMP RSI,qword ptr [RDI + 0xa0] JZ 0x0010ade4 MOVSD qword ptr [RSI],XMM0 ADD RSI,0x8 MOV qword ptr [RDI + 0x98],RSI JMP 0x0010adff LAB_0010ade4: ADD RDI,0x90 MOV RDX,RSP MOVAPD xmmword ptr [RSP + 0x10],XMM2 CALL 0x00112bfe MOVAPD XMM2,xmmword ptr [RSP + 0x10] LAB_0010adff: CMP byte ptr [R14 + 0x3d],0x1 JNZ 0x0010ae81 MOVSD XMM0,qword ptr [R14 + 0x30] UNPCKLPS XMM0,xmmword ptr [0x001153d0] SUBPD XMM0,xmmword ptr [0x001153e0] MOVAPD XMM1,XMM0 UNPCKHPD XMM1,XMM0 ADDSD XMM1,XMM0 MINSD XMM2,XMM1 ADDSD XMM2,qword ptr [0x00115450] MOVSD XMM0,qword ptr [0x00115458] MAXSD XMM0,XMM2 MOV RDI,qword ptr [RBX + 0x118] DIVSD XMM0,qword ptr [RSP + 0x8] MOVSD qword ptr [RSP],XMM0 MOV RSI,qword ptr [RDI + 0xb0] CMP RSI,qword ptr [RDI + 0xb8] JZ 0x0010ae72 MOVSD qword ptr [RSI],XMM0 ADD RSI,0x8 MOV qword ptr [RDI + 0xb0],RSI JMP 0x0010ae81 LAB_0010ae72: ADD RDI,0xa8 MOV RDX,RSP CALL 0x00112bfe LAB_0010ae81: ADD RSP,0x20 POP RBX POP R12 POP R13 POP R14 POP R15 RET
/* WARNING: Globals starting with '_' overlap smaller symbols at the same address */ /* ankerl::nanobench::Result::add(std::chrono::duration<long, std::ratio<1l, 1000000000l> >, unsigned long, ankerl::nanobench::detail::PerformanceCounters const&) */ void __thiscall ankerl::nanobench::Result::add(Result *this,long param_2,long param_3,long param_4) { double *pdVar1; long lVar2; vector<double,std::allocator<double>> *pvVar3; int1 auVar4 [16]; int1 auVar5 [16]; int1 auVar6 [16]; int1 auVar7 [16]; int1 auVar8 [16]; int1 auVar9 [16]; int1 auVar10 [16]; double dVar11; double dVar12; double local_48; double local_40; double local_38; double dStack_30; auVar6._8_4_ = (int)((ulong)param_3 >> 0x20); auVar6._0_8_ = param_3; auVar6._12_4_ = DAT_001153d0._4_4_; local_40 = (auVar6._8_8_ - _UNK_001153e8) + ((double)CONCAT44((int4)DAT_001153d0,(int)param_3) - _DAT_001153e0); pvVar3 = *(vector<double,std::allocator<double>> **)(this + 0x118); pdVar1 = *(double **)(pvVar3 + 0x20); if (pdVar1 == *(double **)(pvVar3 + 0x28)) { std::vector<double,std::allocator<double>>::_M_realloc_insert<double_const&> (pvVar3 + 0x18,pdVar1,&local_40); pvVar3 = *(vector<double,std::allocator<double>> **)(this + 0x118); } else { *pdVar1 = local_40; *(double **)(pvVar3 + 0x20) = pdVar1 + 1; } local_48 = ((double)param_2 / _DAT_00115440) / local_40; pdVar1 = *(double **)(pvVar3 + 8); if (pdVar1 == *(double **)(pvVar3 + 0x10)) { std::vector<double,std::allocator<double>>::_M_realloc_insert<double>(pvVar3,pdVar1,&local_48); } else { *pdVar1 = local_48; *(double **)(pvVar3 + 8) = pdVar1 + 1; } if (*(char *)(param_4 + 0x38) == '\x01') { auVar7._0_8_ = (double)CONCAT44((int4)DAT_001153d0,(int)*(int8 *)(param_4 + 8)); auVar7._8_4_ = (int)((ulong)*(int8 *)(param_4 + 8) >> 0x20); auVar7._12_4_ = DAT_001153d0._4_4_; lVar2 = *(long *)(this + 0x118); local_48 = ((auVar7._8_8_ - _UNK_001153e8) + (auVar7._0_8_ - _DAT_001153e0)) / local_40; pdVar1 = *(double **)(lVar2 + 0x38); if (pdVar1 == *(double **)(lVar2 + 0x40)) { std::vector<double,std::allocator<double>>::_M_realloc_insert<double> ((vector<double,std::allocator<double>> *)(lVar2 + 0x30),pdVar1,&local_48); } else { *pdVar1 = local_48; *(double **)(lVar2 + 0x38) = pdVar1 + 1; } } if (*(char *)(param_4 + 0x39) == '\x01') { auVar8._0_8_ = (double)CONCAT44((int4)DAT_001153d0,(int)*(int8 *)(param_4 + 0x10)); auVar8._8_4_ = (int)((ulong)*(int8 *)(param_4 + 0x10) >> 0x20); auVar8._12_4_ = DAT_001153d0._4_4_; lVar2 = *(long *)(this + 0x118); local_48 = ((auVar8._8_8_ - _UNK_001153e8) + (auVar8._0_8_ - _DAT_001153e0)) / local_40; pdVar1 = *(double **)(lVar2 + 0x50); if (pdVar1 == *(double **)(lVar2 + 0x58)) { std::vector<double,std::allocator<double>>::_M_realloc_insert<double> ((vector<double,std::allocator<double>> *)(lVar2 + 0x48),pdVar1,&local_48); } else { *pdVar1 = local_48; *(double **)(lVar2 + 0x50) = pdVar1 + 1; } } if (*(char *)(param_4 + 0x3a) == '\x01') { auVar9._0_8_ = (double)CONCAT44((int4)DAT_001153d0,(int)*(int8 *)(param_4 + 0x18)); auVar9._8_4_ = (int)((ulong)*(int8 *)(param_4 + 0x18) >> 0x20); auVar9._12_4_ = DAT_001153d0._4_4_; lVar2 = *(long *)(this + 0x118); local_48 = ((auVar9._8_8_ - _UNK_001153e8) + (auVar9._0_8_ - _DAT_001153e0)) / local_40; pdVar1 = *(double **)(lVar2 + 0x68); if (pdVar1 == *(double **)(lVar2 + 0x70)) { std::vector<double,std::allocator<double>>::_M_realloc_insert<double> ((vector<double,std::allocator<double>> *)(lVar2 + 0x60),pdVar1,&local_48); } else { *pdVar1 = local_48; *(double **)(lVar2 + 0x68) = pdVar1 + 1; } } if (*(char *)(param_4 + 0x3b) == '\x01') { auVar10._0_8_ = (double)CONCAT44((int4)DAT_001153d0,(int)*(int8 *)(param_4 + 0x20)); auVar10._8_4_ = (int)((ulong)*(int8 *)(param_4 + 0x20) >> 0x20); auVar10._12_4_ = DAT_001153d0._4_4_; lVar2 = *(long *)(this + 0x118); local_48 = ((auVar10._8_8_ - _UNK_001153e8) + (auVar10._0_8_ - _DAT_001153e0)) / local_40; pdVar1 = *(double **)(lVar2 + 0x80); if (pdVar1 == *(double **)(lVar2 + 0x88)) { std::vector<double,std::allocator<double>>::_M_realloc_insert<double> ((vector<double,std::allocator<double>> *)(lVar2 + 0x78),pdVar1,&local_48); } else { *pdVar1 = local_48; *(double **)(lVar2 + 0x80) = pdVar1 + 1; } } if (*(char *)(param_4 + 0x3c) == '\x01') { lVar2 = *(ulong *)(param_4 + 0x28) - (param_3 + 1U); if (*(ulong *)(param_4 + 0x28) < param_3 + 1U || lVar2 == 0) { dVar11 = 0.0; dVar12 = 0.0; } else { auVar4._8_4_ = (int)((ulong)lVar2 >> 0x20); auVar4._0_8_ = lVar2; auVar4._12_4_ = DAT_001153d0._4_4_; dVar12 = auVar4._8_8_ - _UNK_001153e8; dVar11 = dVar12 + ((double)CONCAT44((int4)DAT_001153d0,(int)lVar2) - _DAT_001153e0); } lVar2 = *(long *)(this + 0x118); local_48 = dVar11 / local_40; pdVar1 = *(double **)(lVar2 + 0x98); if (pdVar1 == *(double **)(lVar2 + 0xa0)) { local_38 = dVar11; dStack_30 = dVar12; std::vector<double,std::allocator<double>>::_M_realloc_insert<double> ((vector<double,std::allocator<double>> *)(lVar2 + 0x90),pdVar1,&local_48); dVar11 = local_38; } else { *pdVar1 = local_48; *(double **)(lVar2 + 0x98) = pdVar1 + 1; } if (*(char *)(param_4 + 0x3d) == '\x01') { auVar5._0_8_ = (double)CONCAT44((int4)DAT_001153d0,(int)*(int8 *)(param_4 + 0x30)) ; auVar5._8_4_ = (int)((ulong)*(int8 *)(param_4 + 0x30) >> 0x20); auVar5._12_4_ = DAT_001153d0._4_4_; dVar12 = (auVar5._8_8_ - _UNK_001153e8) + (auVar5._0_8_ - _DAT_001153e0); if (dVar12 <= dVar11) { dVar11 = dVar12; } local_48 = DAT_00115458; if (DAT_00115458 <= dVar11 + DAT_00115450) { local_48 = dVar11 + DAT_00115450; } lVar2 = *(long *)(this + 0x118); local_48 = local_48 / local_40; pdVar1 = *(double **)(lVar2 + 0xb0); if (pdVar1 == *(double **)(lVar2 + 0xb8)) { std::vector<double,std::allocator<double>>::_M_realloc_insert<double> ((vector<double,std::allocator<double>> *)(lVar2 + 0xa8),pdVar1,&local_48); } else { *pdVar1 = local_48; *(double **)(lVar2 + 0xb0) = pdVar1 + 1; } } } return; }
6,040
int fmt::v10::detail::get_dynamic_spec<fmt::v10::detail::width_checker, fmt::v10::basic_format_arg<fmt::v10::basic_format_context<fmt::v10::appender, char>>>(fmt::v10::basic_format_arg<fmt::v10::basic_format_context<fmt::v10::appender, char>>)
aimrt_mujoco_sim/_deps/fmt-src/include/fmt/format.h
FMT_CONSTEXPR auto get_dynamic_spec(FormatArg arg) -> int { unsigned long long value = visit_format_arg(Handler(), arg); if (value > to_unsigned(max_value<int>())) throw_format_error("number is too big"); return static_cast<int>(value); }
O3
c
int fmt::v10::detail::get_dynamic_spec<fmt::v10::detail::width_checker, fmt::v10::basic_format_arg<fmt::v10::basic_format_context<fmt::v10::appender, char>>>(fmt::v10::basic_format_arg<fmt::v10::basic_format_context<fmt::v10::appender, char>>): pushq %rax movl 0x20(%rsp), %ecx decl %ecx cmpl $0xe, %ecx ja 0xa3eed leaq 0x10(%rsp), %rax leaq 0x1865a3(%rip), %rdx # 0x22a450 movslq (%rdx,%rcx,4), %rcx addq %rdx, %rcx jmpq *%rcx movslq (%rax), %rax testq %rax, %rax jns 0xa3eeb jmp 0xa3ed4 cmpq $0x0, 0x8(%rax) js 0xa3ed4 movq (%rax), %rax jmp 0xa3ee2 movq (%rax), %rax testq %rax, %rax jns 0xa3ee2 leaq 0x18698e(%rip), %rdi # 0x22a869 callq 0x990e4 movl (%rax), %eax movq %rax, %rcx shrq $0x1f, %rcx jne 0xa3ef9 popq %rcx retq leaq 0x186984(%rip), %rdi # 0x22a878 callq 0x990e4 leaq 0x18680b(%rip), %rdi # 0x22a70b callq 0x990e4
_ZN3fmt3v106detail16get_dynamic_specINS1_13width_checkerENS0_16basic_format_argINS0_20basic_format_contextINS0_8appenderEcEEEEEEiT0_: push rax mov ecx, [rsp+8+arg_10] dec ecx; switch 15 cases cmp ecx, 0Eh ja short def_A3EB4; jumptable 00000000000A3EB4 default case, cases 7-15 lea rax, [rsp+8+arg_0] lea rdx, jpt_A3EB4 movsxd rcx, ds:(jpt_A3EB4 - 22A450h)[rdx+rcx*4] add rcx, rdx jmp rcx; switch jump loc_A3EB6: movsxd rax, dword ptr [rax]; jumptable 00000000000A3EB4 case 1 test rax, rax jns short loc_A3EEB jmp short loc_A3ED4 loc_A3EC0: cmp qword ptr [rax+8], 0; jumptable 00000000000A3EB4 case 5 js short loc_A3ED4 loc_A3EC7: mov rax, [rax]; jumptable 00000000000A3EB4 cases 4,6 jmp short loc_A3EE2 loc_A3ECC: mov rax, [rax]; jumptable 00000000000A3EB4 case 3 test rax, rax jns short loc_A3EE2 loc_A3ED4: lea rdi, aNegativeWidth; "negative width" call _ZN3fmt3v106detail18throw_format_errorEPKc; fmt::v10::detail::throw_format_error(char const*) loc_A3EE0: mov eax, [rax]; jumptable 00000000000A3EB4 case 2 loc_A3EE2: mov rcx, rax shr rcx, 1Fh jnz short loc_A3EF9 loc_A3EEB: pop rcx retn def_A3EB4: lea rdi, aWidthIsNotInte; jumptable 00000000000A3EB4 default case, cases 7-15 call _ZN3fmt3v106detail18throw_format_errorEPKc; fmt::v10::detail::throw_format_error(char const*) loc_A3EF9: lea rdi, aNumberIsTooBig; "number is too big" call _ZN3fmt3v106detail18throw_format_errorEPKc; fmt::v10::detail::throw_format_error(char const*)
unsigned long long fmt::v10::detail::get_dynamic_spec<fmt::v10::detail::width_checker,fmt::v10::basic_format_arg<fmt::v10::basic_format_context<fmt::v10::appender,char>>>( long long a1, const char *a2, long long a3, long long a4, long long a5, long long a6, long long a7, long long a8, int a9) { unsigned long long result; // rax switch ( a9 ) { case 1: result = (int)a7; if ( (int)a7 < 0LL ) goto LABEL_7; return result; case 2: result = (unsigned int)a7; goto LABEL_9; case 3: result = a7; if ( a7 < 0 ) goto LABEL_7; goto LABEL_9; case 4: case 6: goto LABEL_5; case 5: if ( a8 < 0 ) LABEL_7: fmt::v10::detail::throw_format_error((fmt::v10::detail *)"negative width", a2); LABEL_5: result = a7; LABEL_9: if ( result >> 31 ) fmt::v10::detail::throw_format_error((fmt::v10::detail *)"number is too big", a2); return result; default: fmt::v10::detail::throw_format_error((fmt::v10::detail *)"width is not integer", a2); } }
get_dynamic_spec<fmt::v10::detail::width_checker,fmt::v10::basic_format_arg<fmt::v10::basic_format_context<fmt::v10::appender,char>>>: PUSH RAX MOV ECX,dword ptr [RSP + 0x20] DEC ECX CMP ECX,0xe JA 0x001a3eed LEA RAX,[RSP + 0x10] LEA RDX,[0x32a450] MOVSXD RCX,dword ptr [RDX + RCX*0x4] ADD RCX,RDX switchD: JMP RCX caseD_1: MOVSXD RAX,dword ptr [RAX] TEST RAX,RAX JNS 0x001a3eeb JMP 0x001a3ed4 caseD_5: CMP qword ptr [RAX + 0x8],0x0 JS 0x001a3ed4 caseD_4: MOV RAX,qword ptr [RAX] JMP 0x001a3ee2 caseD_3: MOV RAX,qword ptr [RAX] TEST RAX,RAX JNS 0x001a3ee2 LAB_001a3ed4: LEA RDI,[0x32a869] CALL 0x001990e4 caseD_2: MOV EAX,dword ptr [RAX] LAB_001a3ee2: MOV RCX,RAX SHR RCX,0x1f JNZ 0x001a3ef9 LAB_001a3eeb: POP RCX RET caseD_7: LEA RDI,[0x32a878] CALL 0x001990e4 LAB_001a3ef9: LEA RDI,[0x32a70b] CALL 0x001990e4
/* int fmt::v10::detail::get_dynamic_spec<fmt::v10::detail::width_checker, fmt::v10::basic_format_arg<fmt::v10::basic_format_context<fmt::v10::appender, char> > >(fmt::v10::basic_format_arg<fmt::v10::basic_format_context<fmt::v10::appender, char> >) */ int fmt::v10::detail:: get_dynamic_spec<fmt::v10::detail::width_checker,fmt::v10::basic_format_arg<fmt::v10::basic_format_context<fmt::v10::appender,char>>> (void) { int iStack0000000000000008; long in_stack_00000010; int4 in_stack_00000018; switch(in_stack_00000018) { case 1: _iStack0000000000000008 = (ulong)iStack0000000000000008; if ((long)_iStack0000000000000008 < 0) { LAB_001a3ed4: /* WARNING: Subroutine does not return */ throw_format_error("negative width"); } goto LAB_001a3eeb; case 2: _iStack0000000000000008 = _iStack0000000000000008 & 0xffffffff; break; case 3: if ((long)_iStack0000000000000008 < 0) goto LAB_001a3ed4; break; case 5: if (in_stack_00000010 < 0) goto LAB_001a3ed4; case 4: case 6: break; default: /* WARNING: Subroutine does not return */ throw_format_error("width is not integer"); } if (_iStack0000000000000008 >> 0x1f != 0) { /* WARNING: Subroutine does not return */ throw_format_error("number is too big"); } LAB_001a3eeb: return (int)_iStack0000000000000008; }
6,041
ma_pvio_register_callback
eloqsql/libmariadb/libmariadb/ma_pvio.c
int ma_pvio_register_callback(my_bool register_callback, void (*callback_function)(int mode, MYSQL *mysql, const uchar *buffer, size_t length)) { LIST *list; if (!callback_function) return 1; /* plugin will unregister in it's deinit function */ if (register_callback) { list= (LIST *)malloc(sizeof(LIST)); list->data= (void *)callback_function; pvio_callback= list_add(pvio_callback, list); } else /* unregister callback function */ { LIST *p= pvio_callback; while (p) { if (p->data == callback_function) { list_delete(pvio_callback, p); break; } p= p->next; } } return 0; }
O0
c
ma_pvio_register_callback: pushq %rbp movq %rsp, %rbp subq $0x20, %rsp movb %dil, %al movb %al, -0x5(%rbp) movq %rsi, -0x10(%rbp) cmpq $0x0, -0x10(%rbp) jne 0x25525 movl $0x1, -0x4(%rbp) jmp 0x255b6 cmpb $0x0, -0x5(%rbp) je 0x25567 movl $0x18, %edi callq 0x135b0 movq %rax, -0x18(%rbp) movq -0x10(%rbp), %rcx movq -0x18(%rbp), %rax movq %rcx, 0x10(%rax) leaq 0x3c06c(%rip), %rax # 0x615b8 movq (%rax), %rdi movq -0x18(%rbp), %rsi callq 0x240d0 movq %rax, %rcx leaq 0x3c056(%rip), %rax # 0x615b8 movq %rcx, (%rax) jmp 0x255af leaq 0x3c04a(%rip), %rax # 0x615b8 movq (%rax), %rax movq %rax, -0x20(%rbp) cmpq $0x0, -0x20(%rbp) je 0x255ad movq -0x20(%rbp), %rax movq 0x10(%rax), %rax cmpq -0x10(%rbp), %rax jne 0x2559f leaq 0x3c027(%rip), %rax # 0x615b8 movq (%rax), %rdi movq -0x20(%rbp), %rsi callq 0x24140 jmp 0x255ad movq -0x20(%rbp), %rax movq 0x8(%rax), %rax movq %rax, -0x20(%rbp) jmp 0x25575 jmp 0x255af movl $0x0, -0x4(%rbp) movl -0x4(%rbp), %eax addq $0x20, %rsp popq %rbp retq nop
ma_pvio_register_callback: push rbp mov rbp, rsp sub rsp, 20h mov al, dil mov [rbp+var_5], al mov [rbp+var_10], rsi cmp [rbp+var_10], 0 jnz short loc_25525 mov [rbp+var_4], 1 jmp loc_255B6 loc_25525: cmp [rbp+var_5], 0 jz short loc_25567 mov edi, 18h call _malloc mov [rbp+var_18], rax mov rcx, [rbp+var_10] mov rax, [rbp+var_18] mov [rax+10h], rcx lea rax, pvio_callback mov rdi, [rax] mov rsi, [rbp+var_18] call list_add mov rcx, rax lea rax, pvio_callback mov [rax], rcx jmp short loc_255AF loc_25567: lea rax, pvio_callback mov rax, [rax] mov [rbp+var_20], rax loc_25575: cmp [rbp+var_20], 0 jz short loc_255AD mov rax, [rbp+var_20] mov rax, [rax+10h] cmp rax, [rbp+var_10] jnz short loc_2559F lea rax, pvio_callback mov rdi, [rax] mov rsi, [rbp+var_20] call list_delete jmp short loc_255AD loc_2559F: mov rax, [rbp+var_20] mov rax, [rax+8] mov [rbp+var_20], rax jmp short loc_25575 loc_255AD: jmp short $+2 loc_255AF: mov [rbp+var_4], 0 loc_255B6: mov eax, [rbp+var_4] add rsp, 20h pop rbp retn
long long ma_pvio_register_callback(char a1, long long a2) { _QWORD *i; // [rsp+0h] [rbp-20h] _QWORD *v4; // [rsp+8h] [rbp-18h] if ( a2 ) { if ( a1 ) { v4 = (_QWORD *)malloc(24LL); v4[2] = a2; pvio_callback = (long long)list_add(pvio_callback, v4); } else { for ( i = (_QWORD *)pvio_callback; i; i = (_QWORD *)i[1] ) { if ( i[2] == a2 ) { list_delete(pvio_callback, i); break; } } } return 0; } else { return 1; } }
ma_pvio_register_callback: PUSH RBP MOV RBP,RSP SUB RSP,0x20 MOV AL,DIL MOV byte ptr [RBP + -0x5],AL MOV qword ptr [RBP + -0x10],RSI CMP qword ptr [RBP + -0x10],0x0 JNZ 0x00125525 MOV dword ptr [RBP + -0x4],0x1 JMP 0x001255b6 LAB_00125525: CMP byte ptr [RBP + -0x5],0x0 JZ 0x00125567 MOV EDI,0x18 CALL 0x001135b0 MOV qword ptr [RBP + -0x18],RAX MOV RCX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RBP + -0x18] MOV qword ptr [RAX + 0x10],RCX LEA RAX,[0x1615b8] MOV RDI,qword ptr [RAX] MOV RSI,qword ptr [RBP + -0x18] CALL 0x001240d0 MOV RCX,RAX LEA RAX,[0x1615b8] MOV qword ptr [RAX],RCX JMP 0x001255af LAB_00125567: LEA RAX,[0x1615b8] MOV RAX,qword ptr [RAX] MOV qword ptr [RBP + -0x20],RAX LAB_00125575: CMP qword ptr [RBP + -0x20],0x0 JZ 0x001255ad MOV RAX,qword ptr [RBP + -0x20] MOV RAX,qword ptr [RAX + 0x10] CMP RAX,qword ptr [RBP + -0x10] JNZ 0x0012559f LEA RAX,[0x1615b8] MOV RDI,qword ptr [RAX] MOV RSI,qword ptr [RBP + -0x20] CALL 0x00124140 JMP 0x001255ad LAB_0012559f: MOV RAX,qword ptr [RBP + -0x20] MOV RAX,qword ptr [RAX + 0x8] MOV qword ptr [RBP + -0x20],RAX JMP 0x00125575 LAB_001255ad: JMP 0x001255af LAB_001255af: MOV dword ptr [RBP + -0x4],0x0 LAB_001255b6: MOV EAX,dword ptr [RBP + -0x4] ADD RSP,0x20 POP RBP RET
int4 ma_pvio_register_callback(char param_1,long param_2) { void *pvVar1; int8 local_28; int4 local_c; if (param_2 == 0) { local_c = 1; } else { if (param_1 == '\0') { for (local_28 = pvio_callback; local_28 != 0; local_28 = *(long *)(local_28 + 8)) { if (*(long *)(local_28 + 0x10) == param_2) { list_delete(pvio_callback,local_28); break; } } } else { pvVar1 = malloc(0x18); *(long *)((long)pvVar1 + 0x10) = param_2; pvio_callback = list_add(pvio_callback,pvVar1); } local_c = 0; } return local_c; }
6,042
tree_walk_left_root_right
eloqsql/mysys/tree.c
static int tree_walk_left_root_right(TREE *tree, TREE_ELEMENT *element, tree_walk_action action, void *argument) { int error; if (element->left) /* Not null_element */ { if ((error=tree_walk_left_root_right(tree,element->left,action, argument)) == 0 && (error=(*action)(ELEMENT_KEY(tree,element), (element_count) element->count, argument)) == 0) error=tree_walk_left_root_right(tree,element->right,action,argument); return error; } return 0; }
O3
c
tree_walk_left_root_right: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx pushq %rax movq %rsi, %r12 movq (%rsi), %rsi xorl %eax, %eax testq %rsi, %rsi je 0xa6299 movq %rcx, %r14 movq %rdx, %r15 movq %rdi, %r13 movl $0x7fffffff, %ebx # imm = 0x7FFFFFFF movq %r13, %rdi movq %r15, %rdx movq %r14, %rcx callq 0xa6227 testl %eax, %eax jne 0xa6299 movl 0x208(%r13), %edi testq %rdi, %rdi je 0xa6273 addq %r12, %rdi jmp 0xa6278 movq 0x18(%r12), %rdi movl 0x10(%r12), %esi andl %ebx, %esi movq %r14, %rdx callq *%r15 testl %eax, %eax jne 0xa6299 movq 0x8(%r12), %r12 movq (%r12), %rsi testq %rsi, %rsi jne 0xa6250 xorl %eax, %eax addq $0x8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
tree_walk_left_root_right: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx push rax mov r12, rsi mov rsi, [rsi] xor eax, eax test rsi, rsi jz short loc_A6299 mov r14, rcx mov r15, rdx mov r13, rdi mov ebx, 7FFFFFFFh loc_A6250: mov rdi, r13 mov rdx, r15 mov rcx, r14 call tree_walk_left_root_right test eax, eax jnz short loc_A6299 mov edi, [r13+208h] test rdi, rdi jz short loc_A6273 add rdi, r12 jmp short loc_A6278 loc_A6273: mov rdi, [r12+18h] loc_A6278: mov esi, [r12+10h] and esi, ebx mov rdx, r14 call r15 test eax, eax jnz short loc_A6299 mov r12, [r12+8] mov rsi, [r12] test rsi, rsi jnz short loc_A6250 xor eax, eax loc_A6299: add rsp, 8 pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
long long tree_walk_left_root_right( long long a1, long long *a2, long long ( *a3)(long long *, long long, long long), long long a4) { long long *v4; // r12 long long v5; // rsi long long result; // rax long long *v10; // rdi v4 = a2; v5 = *a2; result = 0LL; if ( v5 ) { while ( 1 ) { result = tree_walk_left_root_right(a1, v5, a3, a4); if ( (_DWORD)result ) break; v10 = *(_DWORD *)(a1 + 520) ? (long long *)((char *)v4 + *(unsigned int *)(a1 + 520)) : (long long *)v4[3]; result = a3(v10, v4[2] & 0x7FFFFFFF, a4); if ( (_DWORD)result ) break; v4 = (long long *)v4[1]; v5 = *v4; if ( !*v4 ) return 0LL; } } return result; }
tree_walk_left_root_right: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX PUSH RAX MOV R12,RSI MOV RSI,qword ptr [RSI] XOR EAX,EAX TEST RSI,RSI JZ 0x001a6299 MOV R14,RCX MOV R15,RDX MOV R13,RDI MOV EBX,0x7fffffff LAB_001a6250: MOV RDI,R13 MOV RDX,R15 MOV RCX,R14 CALL 0x001a6227 TEST EAX,EAX JNZ 0x001a6299 MOV EDI,dword ptr [R13 + 0x208] TEST RDI,RDI JZ 0x001a6273 ADD RDI,R12 JMP 0x001a6278 LAB_001a6273: MOV RDI,qword ptr [R12 + 0x18] LAB_001a6278: MOV ESI,dword ptr [R12 + 0x10] AND ESI,EBX MOV RDX,R14 CALL R15 TEST EAX,EAX JNZ 0x001a6299 MOV R12,qword ptr [R12 + 0x8] MOV RSI,qword ptr [R12] TEST RSI,RSI JNZ 0x001a6250 XOR EAX,EAX LAB_001a6299: ADD RSP,0x8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
int8 tree_walk_left_root_right(long param_1,long *param_2,code *param_3,int8 param_4) { int8 uVar1; long lVar2; lVar2 = *param_2; while( true ) { if (lVar2 == 0) { return 0; } uVar1 = tree_walk_left_root_right(param_1,lVar2,param_3,param_4); if ((int)uVar1 != 0) break; if ((ulong)*(uint *)(param_1 + 0x208) == 0) { lVar2 = param_2[3]; } else { lVar2 = (ulong)*(uint *)(param_1 + 0x208) + (long)param_2; } uVar1 = (*param_3)(lVar2,*(uint *)(param_2 + 2) & 0x7fffffff,param_4); if ((int)uVar1 != 0) { return uVar1; } param_2 = (long *)param_2[1]; lVar2 = *param_2; } return uVar1; }
6,043
glfwGetMouseButton
untodesu[P]riteg/build_O1/_deps/glfw-src/src/input.c
GLFWAPI int glfwGetMouseButton(GLFWwindow* handle, int button) { _GLFWwindow* window = (_GLFWwindow*) handle; assert(window != NULL); _GLFW_REQUIRE_INIT_OR_RETURN(GLFW_RELEASE); if (button < GLFW_MOUSE_BUTTON_1 || button > GLFW_MOUSE_BUTTON_LAST) { _glfwInputError(GLFW_INVALID_ENUM, "Invalid mouse button %i", button); return GLFW_RELEASE; } if (window->mouseButtons[button] == _GLFW_STICK) { // Sticky mode: release mouse button now window->mouseButtons[button] = GLFW_RELEASE; return GLFW_PRESS; } return (int) window->mouseButtons[button]; }
O1
c
glfwGetMouseButton: pushq %rbx testq %rdi, %rdi je 0x19f0f leaq 0x8a778(%rip), %rax # 0xa4638 cmpl $0x0, (%rax) je 0x19ee3 movl %esi, %edx cmpl $0x8, %esi jb 0x19ef5 leaq 0x64ec1(%rip), %rsi # 0x7ed94 xorl %ebx, %ebx movl $0x10003, %edi # imm = 0x10003 xorl %eax, %eax callq 0x19081 jmp 0x19f0b xorl %ebx, %ebx movl $0x10001, %edi # imm = 0x10001 xorl %esi, %esi xorl %eax, %eax callq 0x19081 jmp 0x19f0b movl %edx, %eax movsbl 0x78(%rdi,%rax), %ebx cmpl $0x3, %ebx jne 0x19f0b movb $0x0, 0x78(%rdi,%rax) movl $0x1, %ebx movl %ebx, %eax popq %rbx retq leaq 0x496e8(%rip), %rdi # 0x635fe leaq 0x64d03(%rip), %rsi # 0x7ec20 leaq 0x64e46(%rip), %rcx # 0x7ed6a movl $0x28d, %edx # imm = 0x28D callq 0xc540
glfwGetMouseButton: push rbx test rdi, rdi jz short loc_19F0F lea rax, _glfw cmp dword ptr [rax], 0 jz short loc_19EE3 mov edx, esi cmp esi, 8 jb short loc_19EF5 lea rsi, aInvalidMouseBu; "Invalid mouse button %i" xor ebx, ebx mov edi, offset loc_10003 xor eax, eax call _glfwInputError jmp short loc_19F0B loc_19EE3: xor ebx, ebx mov edi, 10001h xor esi, esi xor eax, eax call _glfwInputError jmp short loc_19F0B loc_19EF5: mov eax, edx movsx ebx, byte ptr [rdi+rax+78h] cmp ebx, 3 jnz short loc_19F0B mov byte ptr [rdi+rax+78h], 0 mov ebx, 1 loc_19F0B: mov eax, ebx pop rbx retn loc_19F0F: lea rdi, aWindowNull; "window != NULL" lea rsi, aWorkspaceLlm4b_12; "/workspace/llm4binary/github/2025_star3"... lea rcx, aIntGlfwgetmous; "int glfwGetMouseButton(GLFWwindow *, in"... mov edx, 28Dh call ___assert_fail
long long glfwGetMouseButton(long long a1, unsigned int a2) { unsigned int v2; // ebx if ( !a1 ) __assert_fail( "window != NULL", "/workspace/llm4binary/github/2025_star3/untodesu[P]riteg/build_O1/_deps/glfw-src/src/input.c", 653LL, "int glfwGetMouseButton(GLFWwindow *, int)"); if ( glfw[0] ) { if ( a2 < 8 ) { v2 = *(char *)(a1 + a2 + 120); if ( v2 == 3 ) { *(_BYTE *)(a1 + a2 + 120) = 0; return 1; } } else { v2 = 0; glfwInputError((unsigned int)&loc_10003, (long long)"Invalid mouse button %i", a2); } } else { v2 = 0; glfwInputError(0x10001u, 0LL); } return v2; }
glfwGetMouseButton: PUSH RBX TEST RDI,RDI JZ 0x00119f0f LEA RAX,[0x1a4638] CMP dword ptr [RAX],0x0 JZ 0x00119ee3 MOV EDX,ESI CMP ESI,0x8 JC 0x00119ef5 LEA RSI,[0x17ed94] XOR EBX,EBX MOV EDI,0x10003 XOR EAX,EAX CALL 0x00119081 JMP 0x00119f0b LAB_00119ee3: XOR EBX,EBX MOV EDI,0x10001 XOR ESI,ESI XOR EAX,EAX CALL 0x00119081 JMP 0x00119f0b LAB_00119ef5: MOV EAX,EDX MOVSX EBX,byte ptr [RDI + RAX*0x1 + 0x78] CMP EBX,0x3 JNZ 0x00119f0b MOV byte ptr [RDI + RAX*0x1 + 0x78],0x0 MOV EBX,0x1 LAB_00119f0b: MOV EAX,EBX POP RBX RET LAB_00119f0f: LEA RDI,[0x1635fe] LEA RSI,[0x17ec20] LEA RCX,[0x17ed6a] MOV EDX,0x28d CALL 0x0010c540
int glfwGetMouseButton(long param_1,uint param_2) { int iVar1; if (param_1 != 0) { if (_glfw == 0) { iVar1 = 0; _glfwInputError(0x10001,0); } else if (param_2 < 8) { iVar1 = (int)*(char *)(param_1 + 0x78 + (ulong)param_2); if (iVar1 == 3) { *(int1 *)(param_1 + 0x78 + (ulong)param_2) = 0; iVar1 = 1; } } else { iVar1 = 0; _glfwInputError(0x10003,"Invalid mouse button %i"); } return iVar1; } /* WARNING: Subroutine does not return */ __assert_fail("window != NULL", "/workspace/llm4binary/github/2025_star3/untodesu[P]riteg/build_O1/_deps/glfw-src/src/input.c" ,0x28d,"int glfwGetMouseButton(GLFWwindow *, int)"); }
6,044
minja::Value::pop(minja::Value const&)
monkey531[P]llama/common/minja.hpp
Value pop(const Value& index) { if (is_array()) { if (array_->empty()) throw std::runtime_error("pop from empty list"); if (index.is_null()) { auto ret = array_->back(); array_->pop_back(); return ret; } else if (!index.is_number_integer()) { throw std::runtime_error("pop index must be an integer: " + index.dump()); } else { auto i = index.get<int>(); if (i < 0 || i >= static_cast<int>(array_->size())) throw std::runtime_error("pop index out of range: " + index.dump()); auto it = array_->begin() + (i < 0 ? array_->size() + i : i); auto ret = *it; array_->erase(it); return ret; } } else if (is_object()) { if (!index.is_hashable()) throw std::runtime_error("Unashable type: " + index.dump()); auto it = object_->find(index.primitive_); if (it == object_->end()) throw std::runtime_error("Key not found: " + index.dump()); auto ret = it->second; object_->erase(it); return ret; } else { throw std::runtime_error("Value is not an array or object: " + dump()); } }
O1
cpp
minja::Value::pop(minja::Value const&): pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x48, %rsp movq %rdx, %rbx movq %rsi, %r15 movq %rdi, %r13 movq 0x10(%rsi), %rax testq %rax, %rax je 0x781c7 movq 0x8(%rax), %rsi cmpq %rsi, (%rax) je 0x782d2 cmpq $0x0, 0x20(%rbx) movb 0x40(%rbx), %al jne 0x7822c cmpq $0x0, 0x10(%rbx) jne 0x7822c testb %al, %al jne 0x7822c cmpq $0x0, 0x30(%rbx) jne 0x7822c addq $-0x50, %rsi movq %r13, %rdi callq 0x72f12 movq 0x10(%r15), %rdi movq 0x8(%rdi), %rsi addq $-0x50, %rsi movq %rsi, 0x8(%rdi) callq 0x71eba jmp 0x782c0 movq 0x20(%r15), %r14 testq %r14, %r14 je 0x78364 movq %r13, 0x40(%rsp) cmpq $0x0, 0x10(%rbx) jne 0x783c4 cmpq $0x0, 0x20(%rbx) jne 0x783c4 cmpq $0x0, 0x30(%rbx) jne 0x783c4 movq (%r14), %r13 movq 0x8(%r14), %r12 cmpq %r12, %r13 je 0x7828f leaq 0x40(%rbx), %rbp movq %r13, %rdi movq %rbp, %rsi callq 0x4e0ec testb %al, %al jne 0x7828c addq $0x60, %r13 movq 0x8(%r14), %r12 cmpq %r12, %r13 jne 0x7820e jmp 0x7828f addb $-0x5, %al cmpb $0x2, %al jae 0x78481 movq %rbx, %rdi callq 0x75e5e testl %eax, %eax js 0x78304 movq 0x10(%r15), %rcx movq (%rcx), %r12 movq 0x8(%rcx), %rcx subq %r12, %rcx shrq $0x4, %rcx imull $0xcccccccd, %ecx, %ecx # imm = 0xCCCCCCCD cmpl %ecx, %eax jge 0x78304 movl %eax, %eax leaq (%rax,%rax,4), %rax shlq $0x4, %rax addq %rax, %r12 movq %r13, %rdi movq %r12, %rsi callq 0x72f12 movq 0x10(%r15), %rdi movq %r12, %rsi callq 0x797a2 jmp 0x782c0 movq %r13, %r12 movq 0x20(%r15), %rax cmpq 0x8(%rax), %r12 je 0x78424 leaq 0x10(%r12), %rsi movq 0x40(%rsp), %r13 movq %r13, %rdi callq 0x72f12 movq 0x20(%r15), %rdi leaq 0x60(%r12), %rdx movq %r12, %rsi callq 0x7981a movq %r13, %rax addq $0x48, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq movl $0x10, %edi callq 0x19370 movq %rax, %r14 leaq 0x4665e(%rip), %rsi # 0xbe944 movq %rax, %rdi callq 0x19270 movq 0x76cf3(%rip), %rsi # 0xeefe8 movq 0x76c6c(%rip), %rdx # 0xeef68 movq %r14, %rdi callq 0x19b70 movl $0x10, %edi callq 0x19370 movq %rax, %r14 movq %rsp, %rdi movq %rbx, %rsi movl $0xffffffff, %edx # imm = 0xFFFFFFFF xorl %ecx, %ecx callq 0x6c964 leaq 0x4664d(%rip), %rsi # 0xbe977 leaq 0x20(%rsp), %rdi movq %rsp, %rdx callq 0x3779b movb $0x1, %bpl leaq 0x20(%rsp), %rsi movq %r14, %rdi callq 0x19ac0 xorl %ebp, %ebp movq 0x76c98(%rip), %rsi # 0xeefe8 movq 0x76c11(%rip), %rdx # 0xeef68 movq %r14, %rdi callq 0x19b70 jmp 0x784dc movl $0x10, %edi callq 0x19370 movq %rax, %r14 movq %rsp, %rdi movq %r15, %rsi movl $0xffffffff, %edx # imm = 0xFFFFFFFF xorl %ecx, %ecx callq 0x6c964 leaq 0x462b8(%rip), %rsi # 0xbe642 leaq 0x20(%rsp), %rdi movq %rsp, %rdx callq 0x3779b movb $0x1, %bpl leaq 0x20(%rsp), %rsi movq %r14, %rdi callq 0x19ac0 xorl %ebp, %ebp movq 0x76c38(%rip), %rsi # 0xeefe8 movq 0x76bb1(%rip), %rdx # 0xeef68 movq %r14, %rdi callq 0x19b70 jmp 0x784dc movl $0x10, %edi callq 0x19370 movq %rax, %r14 movq %rsp, %rdi movq %rbx, %rsi movl $0xffffffff, %edx # imm = 0xFFFFFFFF xorl %ecx, %ecx callq 0x6c964 leaq 0x4610c(%rip), %rsi # 0xbe4f6 leaq 0x20(%rsp), %rdi movq %rsp, %rdx callq 0x3779b movb $0x1, %bpl leaq 0x20(%rsp), %rsi movq %r14, %rdi callq 0x19ac0 xorl %ebp, %ebp movq 0x76bd8(%rip), %rsi # 0xeefe8 movq 0x76b51(%rip), %rdx # 0xeef68 movq %r14, %rdi callq 0x19b70 jmp 0x784dc movl $0x10, %edi callq 0x19370 movq %rax, %r14 movq %rsp, %rdi movq %rbx, %rsi movl $0xffffffff, %edx # imm = 0xFFFFFFFF xorl %ecx, %ecx callq 0x6c964 leaq 0x46546(%rip), %rsi # 0xbe990 leaq 0x20(%rsp), %rdi movq %rsp, %rdx callq 0x3779b movb $0x1, %bpl leaq 0x20(%rsp), %rsi movq %r14, %rdi callq 0x19ac0 xorl %ebp, %ebp movq 0x76b78(%rip), %rsi # 0xeefe8 movq 0x76af1(%rip), %rdx # 0xeef68 movq %r14, %rdi callq 0x19b70 jmp 0x784dc movl $0x10, %edi callq 0x19370 movq %rax, %r14 movq %rsp, %rdi movq %rbx, %rsi movl $0xffffffff, %edx # imm = 0xFFFFFFFF xorl %ecx, %ecx callq 0x6c964 leaq 0x464b1(%rip), %rsi # 0xbe958 leaq 0x20(%rsp), %rdi movq %rsp, %rdx callq 0x3779b movb $0x1, %bpl leaq 0x20(%rsp), %rsi movq %r14, %rdi callq 0x19ac0 xorl %ebp, %ebp movq 0x76b1b(%rip), %rsi # 0xeefe8 movq 0x76a94(%rip), %rdx # 0xeef68 movq %r14, %rdi callq 0x19b70 jmp 0x784ec jmp 0x7850c jmp 0x784ec jmp 0x7850c jmp 0x784ec jmp 0x7850c jmp 0x784ec jmp 0x7850c movq %rax, %rbx leaq 0x30(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0x78512 movq 0x30(%rsp), %rsi incq %rsi callq 0x196b0 jmp 0x78512 movq %rax, %rbx movb $0x1, %bpl leaq 0x10(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0x7853f movq 0x10(%rsp), %rsi incq %rsi callq 0x196b0 jmp 0x7853f jmp 0x78539 jmp 0x78539 jmp 0x78539 jmp 0x78539 jmp 0x78553 movq %rax, %rbx movb $0x1, %bpl testb %bpl, %bpl jne 0x78549 jmp 0x7855e movq %rax, %rbx movq %r14, %rdi callq 0x19510 jmp 0x7855e movq %rax, %rbx movq %r13, %rdi callq 0x6c670 movq %rbx, %rdi callq 0x19be0
_ZN5minja5Value3popERKS0_: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 48h mov rbx, rdx mov r15, rsi mov r13, rdi mov rax, [rsi+10h] test rax, rax jz short loc_781C7 mov rsi, [rax+8] cmp [rax], rsi jz loc_782D2 cmp qword ptr [rbx+20h], 0 mov al, [rbx+40h] jnz loc_7822C cmp qword ptr [rbx+10h], 0 jnz loc_7822C test al, al jnz loc_7822C cmp qword ptr [rbx+30h], 0 jnz loc_7822C add rsi, 0FFFFFFFFFFFFFFB0h; minja::Value * mov rdi, r13; this call _ZN5minja5ValueC2ERKS0_; minja::Value::Value(minja::Value const&) mov rdi, [r15+10h] mov rsi, [rdi+8] add rsi, 0FFFFFFFFFFFFFFB0h mov [rdi+8], rsi call _ZN9__gnu_cxx13new_allocatorIN5minja5ValueEE7destroyIS2_EEvPT_; __gnu_cxx::new_allocator<minja::Value>::destroy<minja::Value>(minja::Value *) jmp loc_782C0 loc_781C7: mov r14, [r15+20h] test r14, r14 jz loc_78364 mov [rsp+78h+var_38], r13 cmp qword ptr [rbx+10h], 0 jnz loc_783C4 cmp qword ptr [rbx+20h], 0 jnz loc_783C4 cmp qword ptr [rbx+30h], 0 jnz loc_783C4 mov r13, [r14] mov r12, [r14+8] cmp r13, r12 jz loc_7828F lea rbp, [rbx+40h] loc_7820E: mov rdi, r13 mov rsi, rbp call _ZN8nlohmann16json_abi_v3_11_3eqERKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEESF_; nlohmann::json_abi_v3_11_3::operator==(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const&,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const&) test al, al jnz short loc_7828C add r13, 60h ; '`' mov r12, [r14+8] cmp r13, r12 jnz short loc_7820E jmp short loc_7828F loc_7822C: add al, 0FBh cmp al, 2 jnb loc_78481 mov rdi, rbx call _ZNK5minja5Value3getIiEET_v; minja::Value::get<int>(void) test eax, eax js loc_78304 mov rcx, [r15+10h] mov r12, [rcx] mov rcx, [rcx+8] sub rcx, r12 shr rcx, 4 imul ecx, 0CCCCCCCDh cmp eax, ecx jge loc_78304 mov eax, eax lea rax, [rax+rax*4] shl rax, 4 add r12, rax mov rdi, r13; this mov rsi, r12; minja::Value * call _ZN5minja5ValueC2ERKS0_; minja::Value::Value(minja::Value const&) mov rdi, [r15+10h] mov rsi, r12 call _ZNSt6vectorIN5minja5ValueESaIS1_EE8_M_eraseEN9__gnu_cxx17__normal_iteratorIPS1_S3_EE; std::vector<minja::Value>::_M_erase(__gnu_cxx::__normal_iterator<minja::Value*,std::vector<minja::Value>>) jmp short loc_782C0 loc_7828C: mov r12, r13 loc_7828F: mov rax, [r15+20h] cmp r12, [rax+8] jz loc_78424 lea rsi, [r12+10h]; minja::Value * mov r13, [rsp+78h+var_38] mov rdi, r13; this call _ZN5minja5ValueC2ERKS0_; minja::Value::Value(minja::Value const&) mov rdi, [r15+20h] lea rdx, [r12+60h] mov rsi, r12 call _ZN8nlohmann16json_abi_v3_11_311ordered_mapINS0_10basic_jsonIS1_St6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEEN5minja5ValueESt4lessISD_ESaISt4pairIKSD_SF_EEE5eraseEN9__gnu_cxx17__normal_iteratorIPSK_S3_ISK_SL_EEESR_; nlohmann::json_abi_v3_11_3::ordered_map<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>,minja::Value,std::less<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>,std::allocator<std::pair<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const,minja::Value>>>::erase(__gnu_cxx::__normal_iterator<std::pair<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const,minja::Value>*,std::vector<std::pair<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const,minja::Value>>>,__gnu_cxx::__normal_iterator<std::pair<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const,minja::Value>*,std::vector<std::pair<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const,minja::Value>>>) loc_782C0: mov rax, r13 add rsp, 48h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn loc_782D2: mov edi, 10h; thrown_size call ___cxa_allocate_exception mov r14, rax lea rsi, aPopFromEmptyLi; "pop from empty list" mov rdi, rax; this call __ZNSt13runtime_errorC1EPKc; std::runtime_error::runtime_error(char const*) mov rsi, cs:lptinfo; lptinfo mov rdx, cs:_ZTISt19_Sp_make_shared_tag; void (*)(void *) mov rdi, r14; void * call ___cxa_throw loc_78304: mov edi, 10h; thrown_size call ___cxa_allocate_exception mov r14, rax mov rdi, rsp mov rsi, rbx mov edx, 0FFFFFFFFh xor ecx, ecx call _ZNK5minja5Value4dumpB5cxx11Eib; minja::Value::dump(int,bool) lea rsi, aPopIndexOutOfR; "pop index out of range: " lea rdi, [rsp+78h+var_58] mov rdx, rsp call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_OS8_; std::operator+<char>(char const*,std::string&&) mov bpl, 1 lea rsi, [rsp+78h+var_58] mov rdi, r14 call __ZNSt13runtime_errorC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; std::runtime_error::runtime_error(std::string const&) xor ebp, ebp mov rsi, cs:lptinfo; lptinfo mov rdx, cs:_ZTISt19_Sp_make_shared_tag; void (*)(void *) mov rdi, r14; void * call ___cxa_throw jmp loc_784DC loc_78364: mov edi, 10h; thrown_size call ___cxa_allocate_exception mov r14, rax mov rdi, rsp mov rsi, r15 mov edx, 0FFFFFFFFh xor ecx, ecx call _ZNK5minja5Value4dumpB5cxx11Eib; minja::Value::dump(int,bool) lea rsi, aValueIsNotAnAr_0; "Value is not an array or object: " lea rdi, [rsp+78h+var_58] mov rdx, rsp call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_OS8_; std::operator+<char>(char const*,std::string&&) mov bpl, 1 lea rsi, [rsp+78h+var_58] mov rdi, r14 call __ZNSt13runtime_errorC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; std::runtime_error::runtime_error(std::string const&) xor ebp, ebp mov rsi, cs:lptinfo; lptinfo mov rdx, cs:_ZTISt19_Sp_make_shared_tag; void (*)(void *) mov rdi, r14; void * call ___cxa_throw jmp loc_784DC loc_783C4: mov edi, 10h; thrown_size call ___cxa_allocate_exception mov r14, rax mov rdi, rsp mov rsi, rbx mov edx, 0FFFFFFFFh xor ecx, ecx call _ZNK5minja5Value4dumpB5cxx11Eib; minja::Value::dump(int,bool) lea rsi, aUnashableType; "Unashable type: " lea rdi, [rsp+78h+var_58] mov rdx, rsp call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_OS8_; std::operator+<char>(char const*,std::string&&) mov bpl, 1 lea rsi, [rsp+78h+var_58] mov rdi, r14 call __ZNSt13runtime_errorC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; std::runtime_error::runtime_error(std::string const&) xor ebp, ebp mov rsi, cs:lptinfo; lptinfo mov rdx, cs:_ZTISt19_Sp_make_shared_tag; void (*)(void *) mov rdi, r14; void * call ___cxa_throw jmp loc_784DC loc_78424: mov edi, 10h; thrown_size call ___cxa_allocate_exception mov r14, rax mov rdi, rsp mov rsi, rbx mov edx, 0FFFFFFFFh xor ecx, ecx call _ZNK5minja5Value4dumpB5cxx11Eib; minja::Value::dump(int,bool) lea rsi, aKeyNotFound_0; "Key not found: " lea rdi, [rsp+78h+var_58] mov rdx, rsp call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_OS8_; std::operator+<char>(char const*,std::string&&) mov bpl, 1 lea rsi, [rsp+78h+var_58] mov rdi, r14 call __ZNSt13runtime_errorC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; std::runtime_error::runtime_error(std::string const&) xor ebp, ebp mov rsi, cs:lptinfo; lptinfo mov rdx, cs:_ZTISt19_Sp_make_shared_tag; void (*)(void *) mov rdi, r14; void * call ___cxa_throw jmp short loc_784DC loc_78481: mov edi, 10h; thrown_size call ___cxa_allocate_exception mov r14, rax mov rdi, rsp mov rsi, rbx mov edx, 0FFFFFFFFh xor ecx, ecx call _ZNK5minja5Value4dumpB5cxx11Eib; minja::Value::dump(int,bool) lea rsi, aPopIndexMustBe; "pop index must be an integer: " lea rdi, [rsp+78h+var_58] mov rdx, rsp call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_OS8_; std::operator+<char>(char const*,std::string&&) mov bpl, 1 lea rsi, [rsp+78h+var_58] mov rdi, r14 call __ZNSt13runtime_errorC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; std::runtime_error::runtime_error(std::string const&) xor ebp, ebp mov rsi, cs:lptinfo; lptinfo mov rdx, cs:_ZTISt19_Sp_make_shared_tag; void (*)(void *) mov rdi, r14; void * call ___cxa_throw loc_784DC: jmp short loc_784EC jmp short loc_7850C jmp short loc_784EC jmp short loc_7850C jmp short loc_784EC jmp short loc_7850C jmp short loc_784EC jmp short loc_7850C loc_784EC: mov rbx, rax lea rax, [rsp+78h+var_48] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_78512 mov rsi, [rsp+78h+var_48] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) jmp short loc_78512 loc_7850C: mov rbx, rax mov bpl, 1 loc_78512: lea rax, [rsp+78h+var_68] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_7853F mov rsi, [rsp+78h+var_68] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) jmp short loc_7853F jmp short loc_78539 jmp short loc_78539 jmp short loc_78539 jmp short loc_78539 jmp short loc_78553 loc_78539: mov rbx, rax mov bpl, 1 loc_7853F: test bpl, bpl jnz short loc_78549 jmp short loc_7855E mov rbx, rax loc_78549: mov rdi, r14; void * call ___cxa_free_exception jmp short loc_7855E loc_78553: mov rbx, rax mov rdi, r13; this call _ZN5minja5ValueD2Ev; minja::Value::~Value() loc_7855E: mov rdi, rbx call __Unwind_Resume
minja::Value * minja::Value::pop(minja::Value *this, const minja::Value *a2, long long a3, __m128d a4) { minja::Value *v6; // r13 _QWORD *v7; // rax long long v8; // rsi char v9; // al long long v10; // rdi long long v11; // rsi unsigned __int8 **v12; // r14 unsigned __int8 *v13; // r13 unsigned __int8 *v14; // r12 int v15; // eax _QWORD *v16; // rcx const minja::Value *v17; // r12 std::runtime_error *exception; // r14 void *v20; // r14 void *v21; // r14 void *v22; // r14 void *v23; // r14 void *v24; // r14 _BYTE v25[16]; // [rsp+0h] [rbp-78h] BYREF _BYTE v26[16]; // [rsp+20h] [rbp-58h] BYREF minja::Value *v27; // [rsp+40h] [rbp-38h] v6 = this; v7 = (_QWORD *)*((_QWORD *)a2 + 2); if ( v7 ) { v8 = v7[1]; if ( *v7 == v8 ) { exception = (std::runtime_error *)__cxa_allocate_exception(0x10uLL); std::runtime_error::runtime_error(exception, "pop from empty list"); __cxa_throw( exception, (struct type_info *)&`typeinfo for'std::runtime_error, (void (*)(void *))&std::runtime_error::~runtime_error); } v9 = *(_BYTE *)(a3 + 64); if ( *(_QWORD *)(a3 + 32) || *(_QWORD *)(a3 + 16) || v9 || *(_QWORD *)(a3 + 48) ) { if ( (unsigned __int8)(v9 - 5) >= 2u ) { v24 = __cxa_allocate_exception(0x10uLL); minja::Value::dump[abi:cxx11]((long long)v25, a3, 0xFFFFFFFF, 0); std::operator+<char>((long long)v26, (long long)"pop index must be an integer: ", (long long)v25); std::runtime_error::runtime_error(v24, v26); __cxa_throw( v24, (struct type_info *)&`typeinfo for'std::runtime_error, (void (*)(void *))&std::runtime_error::~runtime_error); } v15 = minja::Value::get<int>(a3); if ( v15 < 0 || (v16 = (_QWORD *)*((_QWORD *)a2 + 2), v15 >= (int)(-858993459 * ((v16[1] - *v16) >> 4))) ) { v20 = __cxa_allocate_exception(0x10uLL); minja::Value::dump[abi:cxx11]((long long)v25, a3, 0xFFFFFFFF, 0); std::operator+<char>((long long)v26, (long long)"pop index out of range: ", (long long)v25); std::runtime_error::runtime_error(v20, v26); __cxa_throw( v20, (struct type_info *)&`typeinfo for'std::runtime_error, (void (*)(void *))&std::runtime_error::~runtime_error); } v17 = (const minja::Value *)(80LL * (unsigned int)v15 + *v16); minja::Value::Value(this, v17); std::vector<minja::Value>::_M_erase(*((_QWORD *)a2 + 2), v17); } else { minja::Value::Value(this, (const minja::Value *)(v8 - 80)); v10 = *((_QWORD *)a2 + 2); v11 = *(_QWORD *)(v10 + 8) - 80LL; *(_QWORD *)(v10 + 8) = v11; __gnu_cxx::new_allocator<minja::Value>::destroy<minja::Value>(v10, v11); } } else { v12 = (unsigned __int8 **)*((_QWORD *)a2 + 4); if ( !v12 ) { v21 = __cxa_allocate_exception(0x10uLL); minja::Value::dump[abi:cxx11]((long long)v25, (long long)a2, 0xFFFFFFFF, 0); std::operator+<char>((long long)v26, (long long)"Value is not an array or object: ", (long long)v25); std::runtime_error::runtime_error(v21, v26); __cxa_throw( v21, (struct type_info *)&`typeinfo for'std::runtime_error, (void (*)(void *))&std::runtime_error::~runtime_error); } v27 = this; if ( *(_QWORD *)(a3 + 16) || *(_QWORD *)(a3 + 32) || *(_QWORD *)(a3 + 48) ) { v22 = __cxa_allocate_exception(0x10uLL); minja::Value::dump[abi:cxx11]((long long)v25, a3, 0xFFFFFFFF, 0); std::operator+<char>((long long)v26, (long long)"Unashable type: ", (long long)v25); std::runtime_error::runtime_error(v22, v26); __cxa_throw( v22, (struct type_info *)&`typeinfo for'std::runtime_error, (void (*)(void *))&std::runtime_error::~runtime_error); } v13 = *v12; v14 = v12[1]; if ( *v12 != v14 ) { while ( !(unsigned __int8)nlohmann::json_abi_v3_11_3::operator==(v13, (unsigned __int8 *)(a3 + 64), a4) ) { v13 += 96; v14 = v12[1]; if ( v13 == v14 ) goto LABEL_21; } v14 = v13; } LABEL_21: if ( v14 == *(unsigned __int8 **)(*((_QWORD *)a2 + 4) + 8LL) ) { v23 = __cxa_allocate_exception(0x10uLL); minja::Value::dump[abi:cxx11]((long long)v25, a3, 0xFFFFFFFF, 0); std::operator+<char>((long long)v26, (long long)"Key not found: ", (long long)v25); std::runtime_error::runtime_error(v23, v26); __cxa_throw( v23, (struct type_info *)&`typeinfo for'std::runtime_error, (void (*)(void *))&std::runtime_error::~runtime_error); } v6 = v27; minja::Value::Value(v27, (const minja::Value *)(v14 + 16)); nlohmann::json_abi_v3_11_3::ordered_map<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,minja::Value,std::less<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>,std::allocator<std::pair<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void> const,minja::Value>>>::erase( *((_QWORD *)a2 + 4), v14, v14 + 96); } return v6; }
pop: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x48 MOV RBX,RDX MOV R15,RSI MOV R13,RDI MOV RAX,qword ptr [RSI + 0x10] TEST RAX,RAX JZ 0x001781c7 MOV RSI,qword ptr [RAX + 0x8] CMP qword ptr [RAX],RSI JZ 0x001782d2 CMP qword ptr [RBX + 0x20],0x0 MOV AL,byte ptr [RBX + 0x40] JNZ 0x0017822c CMP qword ptr [RBX + 0x10],0x0 JNZ 0x0017822c TEST AL,AL JNZ 0x0017822c CMP qword ptr [RBX + 0x30],0x0 JNZ 0x0017822c ADD RSI,-0x50 MOV RDI,R13 CALL 0x00172f12 MOV RDI,qword ptr [R15 + 0x10] MOV RSI,qword ptr [RDI + 0x8] ADD RSI,-0x50 MOV qword ptr [RDI + 0x8],RSI CALL 0x00171eba JMP 0x001782c0 LAB_001781c7: MOV R14,qword ptr [R15 + 0x20] TEST R14,R14 JZ 0x00178364 MOV qword ptr [RSP + 0x40],R13 CMP qword ptr [RBX + 0x10],0x0 JNZ 0x001783c4 CMP qword ptr [RBX + 0x20],0x0 JNZ 0x001783c4 CMP qword ptr [RBX + 0x30],0x0 JNZ 0x001783c4 MOV R13,qword ptr [R14] MOV R12,qword ptr [R14 + 0x8] CMP R13,R12 JZ 0x0017828f LEA RBP,[RBX + 0x40] LAB_0017820e: MOV RDI,R13 MOV RSI,RBP CALL 0x0014e0ec TEST AL,AL JNZ 0x0017828c ADD R13,0x60 MOV R12,qword ptr [R14 + 0x8] CMP R13,R12 JNZ 0x0017820e JMP 0x0017828f LAB_0017822c: ADD AL,0xfb CMP AL,0x2 JNC 0x00178481 MOV RDI,RBX CALL 0x00175e5e TEST EAX,EAX JS 0x00178304 MOV RCX,qword ptr [R15 + 0x10] MOV R12,qword ptr [RCX] MOV RCX,qword ptr [RCX + 0x8] SUB RCX,R12 SHR RCX,0x4 IMUL ECX,ECX,-0x33333333 CMP EAX,ECX JGE 0x00178304 MOV EAX,EAX LEA RAX,[RAX + RAX*0x4] SHL RAX,0x4 ADD R12,RAX MOV RDI,R13 MOV RSI,R12 CALL 0x00172f12 MOV RDI,qword ptr [R15 + 0x10] LAB_00178282: MOV RSI,R12 CALL 0x001797a2 LAB_0017828a: JMP 0x001782c0 LAB_0017828c: MOV R12,R13 LAB_0017828f: MOV RAX,qword ptr [R15 + 0x20] CMP R12,qword ptr [RAX + 0x8] JZ 0x00178424 LEA RSI,[R12 + 0x10] MOV R13,qword ptr [RSP + 0x40] MOV RDI,R13 CALL 0x00172f12 MOV RDI,qword ptr [R15 + 0x20] LEA RDX,[R12 + 0x60] LAB_001782b8: MOV RSI,R12 CALL 0x0017981a LAB_001782c0: MOV RAX,R13 ADD RSP,0x48 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET LAB_001782d2: MOV EDI,0x10 CALL 0x00119370 MOV R14,RAX LAB_001782df: LEA RSI,[0x1be944] MOV RDI,RAX CALL 0x00119270 LAB_001782ee: MOV RSI,qword ptr [0x001eefe8] MOV RDX,qword ptr [0x001eef68] MOV RDI,R14 CALL 0x00119b70 LAB_00178304: MOV EDI,0x10 CALL 0x00119370 MOV R14,RAX LAB_00178311: MOV RDI,RSP MOV RSI,RBX MOV EDX,0xffffffff XOR ECX,ECX CALL 0x0016c964 LAB_00178323: LEA RSI,[0x1be977] LEA RDI,[RSP + 0x20] MOV RDX,RSP CALL 0x0013779b MOV BPL,0x1 LAB_0017833a: LEA RSI,[RSP + 0x20] MOV RDI,R14 CALL 0x00119ac0 XOR EBP,EBP MOV RSI,qword ptr [0x001eefe8] MOV RDX,qword ptr [0x001eef68] MOV RDI,R14 CALL 0x00119b70 LAB_00178364: MOV EDI,0x10 CALL 0x00119370 MOV R14,RAX LAB_00178371: MOV RDI,RSP MOV RSI,R15 MOV EDX,0xffffffff XOR ECX,ECX CALL 0x0016c964 LAB_00178383: LEA RSI,[0x1be642] LEA RDI,[RSP + 0x20] MOV RDX,RSP CALL 0x0013779b MOV BPL,0x1 LAB_0017839a: LEA RSI,[RSP + 0x20] MOV RDI,R14 CALL 0x00119ac0 XOR EBP,EBP MOV RSI,qword ptr [0x001eefe8] MOV RDX,qword ptr [0x001eef68] MOV RDI,R14 CALL 0x00119b70 LAB_001783c4: MOV EDI,0x10 CALL 0x00119370 MOV R14,RAX LAB_001783d1: MOV RDI,RSP MOV RSI,RBX MOV EDX,0xffffffff XOR ECX,ECX CALL 0x0016c964 LAB_001783e3: LEA RSI,[0x1be4f6] LEA RDI,[RSP + 0x20] MOV RDX,RSP CALL 0x0013779b MOV BPL,0x1 LAB_001783fa: LEA RSI,[RSP + 0x20] MOV RDI,R14 CALL 0x00119ac0 XOR EBP,EBP MOV RSI,qword ptr [0x001eefe8] MOV RDX,qword ptr [0x001eef68] MOV RDI,R14 CALL 0x00119b70 LAB_00178424: MOV EDI,0x10 CALL 0x00119370 MOV R14,RAX LAB_00178431: MOV RDI,RSP MOV RSI,RBX MOV EDX,0xffffffff XOR ECX,ECX CALL 0x0016c964 LAB_00178443: LEA RSI,[0x1be990] LEA RDI,[RSP + 0x20] MOV RDX,RSP CALL 0x0013779b MOV BPL,0x1 LAB_0017845a: LEA RSI,[RSP + 0x20] MOV RDI,R14 CALL 0x00119ac0 XOR EBP,EBP MOV RSI,qword ptr [0x001eefe8] MOV RDX,qword ptr [0x001eef68] MOV RDI,R14 CALL 0x00119b70 LAB_00178481: MOV EDI,0x10 CALL 0x00119370 MOV R14,RAX LAB_0017848e: MOV RDI,RSP MOV RSI,RBX MOV EDX,0xffffffff XOR ECX,ECX CALL 0x0016c964 LAB_001784a0: LEA RSI,[0x1be958] LEA RDI,[RSP + 0x20] MOV RDX,RSP CALL 0x0013779b MOV BPL,0x1 LAB_001784b7: LEA RSI,[RSP + 0x20] MOV RDI,R14 CALL 0x00119ac0 XOR EBP,EBP MOV RSI,qword ptr [0x001eefe8] MOV RDX,qword ptr [0x001eef68] MOV RDI,R14 CALL 0x00119b70
/* minja::Value::pop(minja::Value const&) */ Value * minja::Value::pop(Value *param_1) { long *plVar1; new_allocator<minja::Value> *this; long lVar2; char cVar3; uint uVar4; runtime_error *prVar5; int iVar6; Value *in_RDX; bool bVar7; long in_RSI; int iVar8; Value *pVVar9; basic_json *pbVar10; basic_json *pbVar11; int1 auStack_78 [32]; string local_58 [32]; Value *local_38; plVar1 = *(long **)(in_RSI + 0x10); bVar7 = SUB81(in_RDX,0); iVar8 = (int)auStack_78; if (plVar1 == (long *)0x0) { plVar1 = *(long **)(in_RSI + 0x20); if (plVar1 == (long *)0x0) { prVar5 = (runtime_error *)__cxa_allocate_exception(0x10); /* try { // try from 00178371 to 00178382 has its CatchHandler @ 00178535 */ dump_abi_cxx11_(iVar8,SUB81(in_RSI,0)); /* try { // try from 00178383 to 00178396 has its CatchHandler @ 001784ea */ std::operator+((char *)local_58,(string *)"Value is not an array or object: "); /* try { // try from 0017839a to 001783be has its CatchHandler @ 001784e8 */ std::runtime_error::runtime_error(prVar5,local_58); /* WARNING: Subroutine does not return */ __cxa_throw(prVar5,PTR_typeinfo_001eefe8,PTR__runtime_error_001eef68); } local_38 = param_1; if (((*(long *)(in_RDX + 0x10) != 0) || (*(long *)(in_RDX + 0x20) != 0)) || (*(long *)(in_RDX + 0x30) != 0)) { prVar5 = (runtime_error *)__cxa_allocate_exception(0x10); /* try { // try from 001783d1 to 001783e2 has its CatchHandler @ 00178533 */ dump_abi_cxx11_(iVar8,bVar7); /* try { // try from 001783e3 to 001783f6 has its CatchHandler @ 001784e6 */ std::operator+((char *)local_58,(string *)"Unashable type: "); /* try { // try from 001783fa to 0017841e has its CatchHandler @ 001784e4 */ std::runtime_error::runtime_error(prVar5,local_58); /* WARNING: Subroutine does not return */ __cxa_throw(prVar5,PTR_typeinfo_001eefe8,PTR__runtime_error_001eef68); } pbVar10 = (basic_json *)plVar1[1]; if ((basic_json *)*plVar1 != pbVar10) { pbVar11 = (basic_json *)*plVar1; do { pbVar10 = pbVar11; cVar3 = nlohmann::json_abi_v3_11_3::operator==(pbVar10,(basic_json *)(in_RDX + 0x40)); if (cVar3 != '\0') break; pbVar11 = pbVar10 + 0x60; pbVar10 = (basic_json *)plVar1[1]; } while (pbVar11 != pbVar10); } param_1 = local_38; if (pbVar10 == *(basic_json **)(*(long *)(in_RSI + 0x20) + 8)) { prVar5 = (runtime_error *)__cxa_allocate_exception(0x10); /* try { // try from 00178431 to 00178442 has its CatchHandler @ 00178531 */ dump_abi_cxx11_(iVar8,bVar7); /* try { // try from 00178443 to 00178456 has its CatchHandler @ 001784e2 */ std::operator+((char *)local_58,(string *)"Key not found: "); /* try { // try from 0017845a to 0017847e has its CatchHandler @ 001784e0 */ std::runtime_error::runtime_error(prVar5,local_58); /* WARNING: Subroutine does not return */ __cxa_throw(prVar5,PTR_typeinfo_001eefe8,PTR__runtime_error_001eef68); } Value(local_38,(Value *)(pbVar10 + 0x10)); /* try { // try from 001782b8 to 001782bf has its CatchHandler @ 00178553 */ nlohmann::json_abi_v3_11_3:: ordered_map<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,minja::Value,std::less<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>,std::allocator<std::pair<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const,minja::Value>>> ::erase(*(ordered_map<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,minja::Value,std::less<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>,std::allocator<std::pair<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const,minja::Value>>> **)(in_RSI + 0x20),pbVar10,pbVar10 + 0x60); } else { if (*plVar1 == plVar1[1]) { prVar5 = (runtime_error *)__cxa_allocate_exception(0x10); /* try { // try from 001782df to 001782ed has its CatchHandler @ 00178546 */ std::runtime_error::runtime_error(prVar5,"pop from empty list"); /* WARNING: Subroutine does not return */ __cxa_throw(prVar5,PTR_typeinfo_001eefe8,PTR__runtime_error_001eef68); } if (((*(long *)(in_RDX + 0x20) == 0) && (*(long *)(in_RDX + 0x10) == 0)) && ((in_RDX[0x40] == (Value)0x0 && (*(long *)(in_RDX + 0x30) == 0)))) { Value(param_1,(Value *)(plVar1[1] + -0x50)); this = *(new_allocator<minja::Value> **)(in_RSI + 0x10); lVar2 = *(long *)(this + 8); *(Value **)(this + 8) = (Value *)(lVar2 + -0x50); __gnu_cxx::new_allocator<minja::Value>::destroy<minja::Value>(this,(Value *)(lVar2 + -0x50)); } else { if (1 < (byte)((char)in_RDX[0x40] - 5U)) { prVar5 = (runtime_error *)__cxa_allocate_exception(0x10); /* try { // try from 0017848e to 0017849f has its CatchHandler @ 0017852f */ dump_abi_cxx11_(iVar8,bVar7); /* try { // try from 001784a0 to 001784b3 has its CatchHandler @ 001784de */ std::operator+((char *)local_58,(string *)"pop index must be an integer: "); /* try { // try from 001784b7 to 001784db has its CatchHandler @ 001784dc */ std::runtime_error::runtime_error(prVar5,local_58); /* WARNING: Subroutine does not return */ __cxa_throw(prVar5,PTR_typeinfo_001eefe8,PTR__runtime_error_001eef68); } uVar4 = get<int>(in_RDX); if (((int)uVar4 < 0) || (lVar2 = **(long **)(in_RSI + 0x10), iVar6 = (int)((ulong)((*(long **)(in_RSI + 0x10))[1] - lVar2) >> 4), SBORROW4(uVar4,iVar6 * -0x33333333) == (int)(uVar4 + iVar6 * 0x33333333) < 0)) { prVar5 = (runtime_error *)__cxa_allocate_exception(0x10); /* try { // try from 00178311 to 00178322 has its CatchHandler @ 00178539 */ dump_abi_cxx11_(iVar8,bVar7); /* try { // try from 00178323 to 00178336 has its CatchHandler @ 0017850c */ std::operator+((char *)local_58,(string *)"pop index out of range: "); /* try { // try from 0017833a to 0017835e has its CatchHandler @ 001784ec */ std::runtime_error::runtime_error(prVar5,local_58); /* WARNING: Subroutine does not return */ __cxa_throw(prVar5,PTR_typeinfo_001eefe8,PTR__runtime_error_001eef68); } pVVar9 = (Value *)(lVar2 + (ulong)uVar4 * 0x50); Value(param_1,pVVar9); /* try { // try from 00178282 to 00178289 has its CatchHandler @ 00178537 */ std::vector<minja::Value,std::allocator<minja::Value>>::_M_erase (*(vector<minja::Value,std::allocator<minja::Value>> **)(in_RSI + 0x10),pVVar9); } } return param_1; }
6,045
minja::Value::pop(minja::Value const&)
monkey531[P]llama/common/minja.hpp
Value pop(const Value& index) { if (is_array()) { if (array_->empty()) throw std::runtime_error("pop from empty list"); if (index.is_null()) { auto ret = array_->back(); array_->pop_back(); return ret; } else if (!index.is_number_integer()) { throw std::runtime_error("pop index must be an integer: " + index.dump()); } else { auto i = index.get<int>(); if (i < 0 || i >= static_cast<int>(array_->size())) throw std::runtime_error("pop index out of range: " + index.dump()); auto it = array_->begin() + (i < 0 ? array_->size() + i : i); auto ret = *it; array_->erase(it); return ret; } } else if (is_object()) { if (!index.is_hashable()) throw std::runtime_error("Unashable type: " + index.dump()); auto it = object_->find(index.primitive_); if (it == object_->end()) throw std::runtime_error("Key not found: " + index.dump()); auto ret = it->second; object_->erase(it); return ret; } else { throw std::runtime_error("Value is not an array or object: " + dump()); } }
O2
cpp
minja::Value::pop(minja::Value const&): pushq %rbp pushq %r15 pushq %r14 pushq %r12 pushq %rbx subq $0x40, %rsp movq %rdx, %rbx movq %rsi, %r15 movq %rdi, %r14 movq 0x10(%rsi), %rax testq %rax, %rax je 0x68d89 movq (%rax), %rcx cmpq 0x8(%rax), %rcx je 0x68e44 movq %rbx, %rdi callq 0x60344 testb %al, %al je 0x68ddf movq 0x10(%r15), %rax movq 0x8(%rax), %rsi addq $-0x50, %rsi movq %r14, %rdi callq 0x649a0 movq 0x10(%r15), %rdi callq 0x69dde jmp 0x68e34 cmpq $0x0, 0x20(%r15) je 0x68ed0 movq %rbx, %rdi callq 0x5feb6 testb %al, %al je 0x68f2c movq 0x20(%r15), %rdi leaq 0x40(%rbx), %rsi callq 0x67468 movq %rax, %r12 movq 0x20(%r15), %rax cmpq 0x8(%rax), %r12 je 0x68f88 movq %r12, %rsi addq $0x10, %rsi movq %r14, %rdi callq 0x649a0 movq 0x20(%r15), %rdi movq %r12, %rsi callq 0x69df8 jmp 0x68e34 movb 0x40(%rbx), %al addb $-0x5, %al cmpb $0x2, %al jae 0x68fe1 movq %rbx, %rdi callq 0x673b2 testl %eax, %eax js 0x68e74 movl %eax, %ecx movq 0x10(%r15), %rax movq (%rax), %r12 movq 0x8(%rax), %rax subq %r12, %rax pushq $0x50 popq %rsi cqto idivq %rsi cmpl %eax, %ecx jge 0x68e74 movl %ecx, %eax imulq $0x50, %rax, %rax addq %rax, %r12 movq %r14, %rdi movq %r12, %rsi callq 0x649a0 movq 0x10(%r15), %rdi movq %r12, %rsi callq 0x69df2 movq %r14, %rax addq $0x40, %rsp popq %rbx popq %r12 popq %r14 popq %r15 popq %rbp retq pushq $0x10 popq %rdi callq 0x213a0 movq %rax, %r14 leaq 0x34b2e(%rip), %rsi # 0x9d984 movq %rax, %rdi callq 0x21280 movq 0x73183(%rip), %rsi # 0xdbfe8 movq 0x730fc(%rip), %rdx # 0xdbf68 movq %r14, %rdi callq 0x21b70 pushq $0x10 popq %rdi callq 0x213a0 movq %rax, %r14 movq %rsp, %rdi pushq $-0x1 popq %rdx movq %rbx, %rsi xorl %ecx, %ecx callq 0x5fec6 leaq 0x34b21(%rip), %rsi # 0x9d9b7 leaq 0x20(%rsp), %rdi movq %rsp, %rdx callq 0x368bc movb $0x1, %bpl leaq 0x20(%rsp), %rsi movq %r14, %rdi callq 0x21ae0 xorl %ebp, %ebp movq 0x7312c(%rip), %rsi # 0xdbfe8 movq 0x730a5(%rip), %rdx # 0xdbf68 movq %r14, %rdi callq 0x21b70 jmp 0x69038 pushq $0x10 popq %rdi callq 0x213a0 movq %rax, %r14 movq %rsp, %rdi pushq $-0x1 popq %rdx movq %r15, %rsi xorl %ecx, %ecx callq 0x5fec6 leaq 0x34790(%rip), %rsi # 0x9d682 leaq 0x20(%rsp), %rdi movq %rsp, %rdx callq 0x368bc movb $0x1, %bpl leaq 0x20(%rsp), %rsi movq %r14, %rdi callq 0x21ae0 xorl %ebp, %ebp movq 0x730d0(%rip), %rsi # 0xdbfe8 movq 0x73049(%rip), %rdx # 0xdbf68 movq %r14, %rdi callq 0x21b70 jmp 0x69038 pushq $0x10 popq %rdi callq 0x213a0 movq %rax, %r14 movq %rsp, %rdi pushq $-0x1 popq %rdx movq %rbx, %rsi xorl %ecx, %ecx callq 0x5fec6 leaq 0x345e8(%rip), %rsi # 0x9d536 leaq 0x20(%rsp), %rdi movq %rsp, %rdx callq 0x368bc movb $0x1, %bpl leaq 0x20(%rsp), %rsi movq %r14, %rdi callq 0x21ae0 xorl %ebp, %ebp movq 0x73074(%rip), %rsi # 0xdbfe8 movq 0x72fed(%rip), %rdx # 0xdbf68 movq %r14, %rdi callq 0x21b70 jmp 0x69038 pushq $0x10 popq %rdi callq 0x213a0 movq %rax, %r14 movq %rsp, %rdi pushq $-0x1 popq %rdx movq %rbx, %rsi xorl %ecx, %ecx callq 0x5fec6 leaq 0x34a26(%rip), %rsi # 0x9d9d0 leaq 0x20(%rsp), %rdi movq %rsp, %rdx callq 0x368bc movb $0x1, %bpl leaq 0x20(%rsp), %rsi movq %r14, %rdi callq 0x21ae0 xorl %ebp, %ebp movq 0x73018(%rip), %rsi # 0xdbfe8 movq 0x72f91(%rip), %rdx # 0xdbf68 movq %r14, %rdi callq 0x21b70 jmp 0x69038 pushq $0x10 popq %rdi callq 0x213a0 movq %rax, %r14 movq %rsp, %rdi pushq $-0x1 popq %rdx movq %rbx, %rsi xorl %ecx, %ecx callq 0x5fec6 leaq 0x34995(%rip), %rsi # 0x9d998 leaq 0x20(%rsp), %rdi movq %rsp, %rdx callq 0x368bc movb $0x1, %bpl leaq 0x20(%rsp), %rsi movq %r14, %rdi callq 0x21ae0 xorl %ebp, %ebp movq 0x72fbf(%rip), %rsi # 0xdbfe8 movq 0x72f38(%rip), %rdx # 0xdbf68 movq %r14, %rdi callq 0x21b70 jmp 0x69048 jmp 0x69057 jmp 0x69048 jmp 0x69057 jmp 0x69048 jmp 0x69057 jmp 0x69048 jmp 0x69057 movq %rax, %rbx leaq 0x20(%rsp), %rdi callq 0x21dc8 jmp 0x6905d movq %rax, %rbx movb $0x1, %bpl movq %rsp, %rdi callq 0x21dc8 testb %bpl, %bpl jne 0x6907b jmp 0x69090 jmp 0x69078 jmp 0x69078 jmp 0x69078 jmp 0x69078 jmp 0x69085 jmp 0x69078 movq %rax, %rbx movq %r14, %rdi callq 0x21530 jmp 0x69090 movq %rax, %rbx movq %r14, %rdi callq 0x5fcd8 movq %rbx, %rdi callq 0x21be0
_ZN5minja5Value3popERKS0_: push rbp push r15 push r14 push r12 push rbx sub rsp, 40h mov rbx, rdx mov r15, rsi mov r14, rdi mov rax, [rsi+10h] test rax, rax jz short loc_68D89 mov rcx, [rax] cmp rcx, [rax+8] jz loc_68E44 mov rdi, rbx; this call _ZNK5minja5Value7is_nullEv; minja::Value::is_null(void) test al, al jz short loc_68DDF mov rax, [r15+10h] mov rsi, [rax+8] add rsi, 0FFFFFFFFFFFFFFB0h; minja::Value * mov rdi, r14; this call _ZN5minja5ValueC2ERKS0_; minja::Value::Value(minja::Value const&) mov rdi, [r15+10h] call _ZNSt6vectorIN5minja5ValueESaIS1_EE8pop_backEv; std::vector<minja::Value>::pop_back(void) jmp loc_68E34 loc_68D89: cmp qword ptr [r15+20h], 0 jz loc_68ED0 mov rdi, rbx; this call _ZNK5minja5Value12is_primitiveEv; minja::Value::is_primitive(void) test al, al jz loc_68F2C mov rdi, [r15+20h] lea rsi, [rbx+40h] call _ZN8nlohmann16json_abi_v3_11_311ordered_mapINS0_10basic_jsonIS1_St6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEEN5minja5ValueESt4lessISD_ESaISt4pairIKSD_SF_EEE4findERSJ_; nlohmann::json_abi_v3_11_3::ordered_map<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>,minja::Value,std::less<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>,std::allocator<std::pair<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const,minja::Value>>>::find(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::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 r12, rax mov rax, [r15+20h] cmp r12, [rax+8] jz loc_68F88 mov rsi, r12 add rsi, 10h; minja::Value * mov rdi, r14; this call _ZN5minja5ValueC2ERKS0_; minja::Value::Value(minja::Value const&) mov rdi, [r15+20h] mov rsi, r12 call _ZN8nlohmann16json_abi_v3_11_311ordered_mapINS0_10basic_jsonIS1_St6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEEN5minja5ValueESt4lessISD_ESaISt4pairIKSD_SF_EEE5eraseEN9__gnu_cxx17__normal_iteratorIPSK_S3_ISK_SL_EEE; nlohmann::json_abi_v3_11_3::ordered_map<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>,minja::Value,std::less<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>,std::allocator<std::pair<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const,minja::Value>>>::erase(__gnu_cxx::__normal_iterator<std::pair<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const,minja::Value>*,std::vector<std::pair<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const,minja::Value>>>) jmp short loc_68E34 loc_68DDF: mov al, [rbx+40h] add al, 0FBh cmp al, 2 jnb loc_68FE1 mov rdi, rbx call _ZNK5minja5Value3getIiEET_v; minja::Value::get<int>(void) test eax, eax js short loc_68E74 mov ecx, eax mov rax, [r15+10h] mov r12, [rax] mov rax, [rax+8] sub rax, r12 push 50h ; 'P' pop rsi cqo idiv rsi cmp ecx, eax jge short loc_68E74 mov eax, ecx imul rax, 50h ; 'P' add r12, rax mov rdi, r14; this mov rsi, r12; minja::Value * call _ZN5minja5ValueC2ERKS0_; minja::Value::Value(minja::Value const&) mov rdi, [r15+10h] mov rsi, r12 call _ZNSt6vectorIN5minja5ValueESaIS1_EE5eraseEN9__gnu_cxx17__normal_iteratorIPKS1_S3_EE; std::vector<minja::Value>::erase(__gnu_cxx::__normal_iterator<minja::Value const*,std::vector<minja::Value>>) loc_68E34: mov rax, r14 add rsp, 40h pop rbx pop r12 pop r14 pop r15 pop rbp retn loc_68E44: push 10h pop rdi; thrown_size call ___cxa_allocate_exception mov r14, rax lea rsi, aPopFromEmptyLi; "pop from empty list" mov rdi, rax; this call __ZNSt13runtime_errorC1EPKc; std::runtime_error::runtime_error(char const*) mov rsi, cs:lptinfo; lptinfo mov rdx, cs:_ZNSt13runtime_errorD1Ev_ptr; void (*)(void *) mov rdi, r14; void * call ___cxa_throw loc_68E74: push 10h pop rdi; thrown_size call ___cxa_allocate_exception mov r14, rax mov rdi, rsp push 0FFFFFFFFFFFFFFFFh pop rdx mov rsi, rbx xor ecx, ecx call _ZNK5minja5Value4dumpB5cxx11Eib; minja::Value::dump(int,bool) lea rsi, aPopIndexOutOfR; "pop index out of range: " lea rdi, [rsp+68h+var_48] mov rdx, rsp call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_OS8_; std::operator+<char>(char const*,std::string&&) mov bpl, 1 lea rsi, [rsp+68h+var_48] mov rdi, r14 call __ZNSt13runtime_errorC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; std::runtime_error::runtime_error(std::string const&) xor ebp, ebp mov rsi, cs:lptinfo; lptinfo mov rdx, cs:_ZNSt13runtime_errorD1Ev_ptr; void (*)(void *) mov rdi, r14; void * call ___cxa_throw jmp loc_69038 loc_68ED0: push 10h pop rdi; thrown_size call ___cxa_allocate_exception mov r14, rax mov rdi, rsp push 0FFFFFFFFFFFFFFFFh pop rdx mov rsi, r15 xor ecx, ecx call _ZNK5minja5Value4dumpB5cxx11Eib; minja::Value::dump(int,bool) lea rsi, aValueIsNotAnAr_0; "Value is not an array or object: " lea rdi, [rsp+68h+var_48] mov rdx, rsp call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_OS8_; std::operator+<char>(char const*,std::string&&) mov bpl, 1 lea rsi, [rsp+68h+var_48] mov rdi, r14 call __ZNSt13runtime_errorC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; std::runtime_error::runtime_error(std::string const&) xor ebp, ebp mov rsi, cs:lptinfo; lptinfo mov rdx, cs:_ZNSt13runtime_errorD1Ev_ptr; void (*)(void *) mov rdi, r14; void * call ___cxa_throw jmp loc_69038 loc_68F2C: push 10h pop rdi; thrown_size call ___cxa_allocate_exception mov r14, rax mov rdi, rsp push 0FFFFFFFFFFFFFFFFh pop rdx mov rsi, rbx xor ecx, ecx call _ZNK5minja5Value4dumpB5cxx11Eib; minja::Value::dump(int,bool) lea rsi, aUnashableType; "Unashable type: " lea rdi, [rsp+68h+var_48] mov rdx, rsp call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_OS8_; std::operator+<char>(char const*,std::string&&) mov bpl, 1 lea rsi, [rsp+68h+var_48] mov rdi, r14 call __ZNSt13runtime_errorC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; std::runtime_error::runtime_error(std::string const&) xor ebp, ebp mov rsi, cs:lptinfo; lptinfo mov rdx, cs:_ZNSt13runtime_errorD1Ev_ptr; void (*)(void *) mov rdi, r14; void * call ___cxa_throw jmp loc_69038 loc_68F88: push 10h pop rdi; thrown_size call ___cxa_allocate_exception mov r14, rax mov rdi, rsp push 0FFFFFFFFFFFFFFFFh pop rdx mov rsi, rbx xor ecx, ecx call _ZNK5minja5Value4dumpB5cxx11Eib; minja::Value::dump(int,bool) lea rsi, aKeyNotFound_0; "Key not found: " lea rdi, [rsp+68h+var_48] mov rdx, rsp call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_OS8_; std::operator+<char>(char const*,std::string&&) mov bpl, 1 lea rsi, [rsp+68h+var_48] mov rdi, r14 call __ZNSt13runtime_errorC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; std::runtime_error::runtime_error(std::string const&) xor ebp, ebp mov rsi, cs:lptinfo; lptinfo mov rdx, cs:_ZNSt13runtime_errorD1Ev_ptr; void (*)(void *) mov rdi, r14; void * call ___cxa_throw jmp short loc_69038 loc_68FE1: push 10h pop rdi; thrown_size call ___cxa_allocate_exception mov r14, rax mov rdi, rsp push 0FFFFFFFFFFFFFFFFh pop rdx mov rsi, rbx xor ecx, ecx call _ZNK5minja5Value4dumpB5cxx11Eib; minja::Value::dump(int,bool) lea rsi, aPopIndexMustBe; "pop index must be an integer: " lea rdi, [rsp+68h+var_48] mov rdx, rsp call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_OS8_; std::operator+<char>(char const*,std::string&&) mov bpl, 1 lea rsi, [rsp+68h+var_48] mov rdi, r14 call __ZNSt13runtime_errorC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; std::runtime_error::runtime_error(std::string const&) xor ebp, ebp mov rsi, cs:lptinfo; lptinfo mov rdx, cs:_ZNSt13runtime_errorD1Ev_ptr; void (*)(void *) mov rdi, r14; void * call ___cxa_throw loc_69038: jmp short loc_69048 jmp short loc_69057 jmp short loc_69048 jmp short loc_69057 jmp short loc_69048 jmp short loc_69057 jmp short loc_69048 jmp short loc_69057 loc_69048: mov rbx, rax lea rdi, [rsp+68h+var_48]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() jmp short loc_6905D loc_69057: mov rbx, rax mov bpl, 1 loc_6905D: mov rdi, rsp; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() test bpl, bpl jnz short loc_6907B jmp short loc_69090 jmp short loc_69078 jmp short loc_69078 jmp short loc_69078 jmp short loc_69078 jmp short loc_69085 jmp short $+2 loc_69078: mov rbx, rax loc_6907B: mov rdi, r14; void * call ___cxa_free_exception jmp short loc_69090 loc_69085: mov rbx, rax mov rdi, r14; this call _ZN5minja5ValueD2Ev; minja::Value::~Value() loc_69090: mov rdi, rbx call __Unwind_Resume
minja::Value * minja::Value::pop(minja::Value *this, const minja::Value *a2, unsigned __int8 *a3, __m128d a4) { _QWORD *v5; // rax unsigned __int8 *v6; // r12 int v7; // eax int v8; // ecx _QWORD *v9; // rax const minja::Value *v10; // r12 std::runtime_error *exception; // r14 void *v13; // r14 void *v14; // r14 void *v15; // r14 void *v16; // r14 void *v17; // r14 _BYTE v18[32]; // [rsp+0h] [rbp-68h] BYREF _BYTE v19[72]; // [rsp+20h] [rbp-48h] BYREF v5 = (_QWORD *)*((_QWORD *)a2 + 2); if ( v5 ) { if ( *v5 == v5[1] ) { exception = (std::runtime_error *)__cxa_allocate_exception(0x10uLL); std::runtime_error::runtime_error(exception, "pop from empty list"); __cxa_throw( exception, (struct type_info *)&`typeinfo for'std::runtime_error, (void (*)(void *))&std::runtime_error::~runtime_error); } if ( minja::Value::is_null((minja::Value *)a3) ) { minja::Value::Value(this, (const minja::Value *)(*(_QWORD *)(*((_QWORD *)a2 + 2) + 8LL) - 80LL)); std::vector<minja::Value>::pop_back(*((_QWORD *)a2 + 2)); } else { if ( (unsigned __int8)(a3[64] - 5) >= 2u ) { v17 = __cxa_allocate_exception(0x10uLL); minja::Value::dump[abi:cxx11]((long long)v18, (long long)a3, 0xFFFFFFFF, 0); std::operator+<char>((long long)v19, (long long)"pop index must be an integer: ", (long long)v18); std::runtime_error::runtime_error(v17, v19); __cxa_throw( v17, (struct type_info *)&`typeinfo for'std::runtime_error, (void (*)(void *))&std::runtime_error::~runtime_error); } v7 = minja::Value::get<int>((minja::Value *)a3); if ( v7 < 0 || (v8 = v7, v9 = (_QWORD *)*((_QWORD *)a2 + 2), v8 >= (int)((v9[1] - *v9) / 80LL)) ) { v13 = __cxa_allocate_exception(0x10uLL); minja::Value::dump[abi:cxx11]((long long)v18, (long long)a3, 0xFFFFFFFF, 0); std::operator+<char>((long long)v19, (long long)"pop index out of range: ", (long long)v18); std::runtime_error::runtime_error(v13, v19); __cxa_throw( v13, (struct type_info *)&`typeinfo for'std::runtime_error, (void (*)(void *))&std::runtime_error::~runtime_error); } v10 = (const minja::Value *)(80LL * (unsigned int)v8 + *v9); minja::Value::Value(this, v10); std::vector<minja::Value>::erase(*((_QWORD *)a2 + 2), v10); } } else { if ( !*((_QWORD *)a2 + 4) ) { v14 = __cxa_allocate_exception(0x10uLL); minja::Value::dump[abi:cxx11]((long long)v18, (long long)a2, 0xFFFFFFFF, 0); std::operator+<char>((long long)v19, (long long)"Value is not an array or object: ", (long long)v18); std::runtime_error::runtime_error(v14, v19); __cxa_throw( v14, (struct type_info *)&`typeinfo for'std::runtime_error, (void (*)(void *))&std::runtime_error::~runtime_error); } if ( !minja::Value::is_primitive((minja::Value *)a3) ) { v15 = __cxa_allocate_exception(0x10uLL); minja::Value::dump[abi:cxx11]((long long)v18, (long long)a3, 0xFFFFFFFF, 0); std::operator+<char>((long long)v19, (long long)"Unashable type: ", (long long)v18); std::runtime_error::runtime_error(v15, v19); __cxa_throw( v15, (struct type_info *)&`typeinfo for'std::runtime_error, (void (*)(void *))&std::runtime_error::~runtime_error); } v6 = nlohmann::json_abi_v3_11_3::ordered_map<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,minja::Value,std::less<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>,std::allocator<std::pair<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void> const,minja::Value>>>::find( *((unsigned __int8 ***)a2 + 4), a3 + 64, a4); if ( v6 == *(unsigned __int8 **)(*((_QWORD *)a2 + 4) + 8LL) ) { v16 = __cxa_allocate_exception(0x10uLL); minja::Value::dump[abi:cxx11]((long long)v18, (long long)a3, 0xFFFFFFFF, 0); std::operator+<char>((long long)v19, (long long)"Key not found: ", (long long)v18); std::runtime_error::runtime_error(v16, v19); __cxa_throw( v16, (struct type_info *)&`typeinfo for'std::runtime_error, (void (*)(void *))&std::runtime_error::~runtime_error); } minja::Value::Value(this, (const minja::Value *)(v6 + 16)); nlohmann::json_abi_v3_11_3::ordered_map<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,minja::Value,std::less<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>,std::allocator<std::pair<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void> const,minja::Value>>>::erase( *((_QWORD *)a2 + 4), v6); } return this; }
pop: PUSH RBP PUSH R15 PUSH R14 PUSH R12 PUSH RBX SUB RSP,0x40 MOV RBX,RDX MOV R15,RSI MOV R14,RDI MOV RAX,qword ptr [RSI + 0x10] TEST RAX,RAX JZ 0x00168d89 MOV RCX,qword ptr [RAX] CMP RCX,qword ptr [RAX + 0x8] JZ 0x00168e44 MOV RDI,RBX CALL 0x00160344 TEST AL,AL JZ 0x00168ddf MOV RAX,qword ptr [R15 + 0x10] MOV RSI,qword ptr [RAX + 0x8] ADD RSI,-0x50 MOV RDI,R14 CALL 0x001649a0 MOV RDI,qword ptr [R15 + 0x10] CALL 0x00169dde JMP 0x00168e34 LAB_00168d89: CMP qword ptr [R15 + 0x20],0x0 JZ 0x00168ed0 MOV RDI,RBX CALL 0x0015feb6 TEST AL,AL JZ 0x00168f2c MOV RDI,qword ptr [R15 + 0x20] LEA RSI,[RBX + 0x40] CALL 0x00167468 MOV R12,RAX MOV RAX,qword ptr [R15 + 0x20] CMP R12,qword ptr [RAX + 0x8] JZ 0x00168f88 MOV RSI,R12 ADD RSI,0x10 MOV RDI,R14 CALL 0x001649a0 MOV RDI,qword ptr [R15 + 0x20] LAB_00168dd5: MOV RSI,R12 CALL 0x00169df8 LAB_00168ddd: JMP 0x00168e34 LAB_00168ddf: MOV AL,byte ptr [RBX + 0x40] ADD AL,0xfb CMP AL,0x2 JNC 0x00168fe1 MOV RDI,RBX CALL 0x001673b2 TEST EAX,EAX JS 0x00168e74 MOV ECX,EAX MOV RAX,qword ptr [R15 + 0x10] MOV R12,qword ptr [RAX] MOV RAX,qword ptr [RAX + 0x8] SUB RAX,R12 PUSH 0x50 POP RSI CQO IDIV RSI CMP ECX,EAX JGE 0x00168e74 MOV EAX,ECX IMUL RAX,RAX,0x50 ADD R12,RAX MOV RDI,R14 MOV RSI,R12 CALL 0x001649a0 MOV RDI,qword ptr [R15 + 0x10] LAB_00168e2c: MOV RSI,R12 CALL 0x00169df2 LAB_00168e34: MOV RAX,R14 ADD RSP,0x40 POP RBX POP R12 POP R14 POP R15 POP RBP RET LAB_00168e44: PUSH 0x10 POP RDI CALL 0x001213a0 MOV R14,RAX LAB_00168e4f: LEA RSI,[0x19d984] MOV RDI,RAX CALL 0x00121280 LAB_00168e5e: MOV RSI,qword ptr [0x001dbfe8] MOV RDX,qword ptr [0x001dbf68] MOV RDI,R14 CALL 0x00121b70 LAB_00168e74: PUSH 0x10 POP RDI CALL 0x001213a0 MOV R14,RAX LAB_00168e7f: MOV RDI,RSP PUSH -0x1 POP RDX MOV RSI,RBX XOR ECX,ECX CALL 0x0015fec6 LAB_00168e8f: LEA RSI,[0x19d9b7] LEA RDI,[RSP + 0x20] MOV RDX,RSP CALL 0x001368bc MOV BPL,0x1 LAB_00168ea6: LEA RSI,[RSP + 0x20] MOV RDI,R14 CALL 0x00121ae0 XOR EBP,EBP MOV RSI,qword ptr [0x001dbfe8] MOV RDX,qword ptr [0x001dbf68] MOV RDI,R14 CALL 0x00121b70 LAB_00168ed0: PUSH 0x10 POP RDI CALL 0x001213a0 MOV R14,RAX LAB_00168edb: MOV RDI,RSP PUSH -0x1 POP RDX MOV RSI,R15 XOR ECX,ECX CALL 0x0015fec6 LAB_00168eeb: LEA RSI,[0x19d682] LEA RDI,[RSP + 0x20] MOV RDX,RSP CALL 0x001368bc MOV BPL,0x1 LAB_00168f02: LEA RSI,[RSP + 0x20] MOV RDI,R14 CALL 0x00121ae0 XOR EBP,EBP MOV RSI,qword ptr [0x001dbfe8] MOV RDX,qword ptr [0x001dbf68] MOV RDI,R14 CALL 0x00121b70 LAB_00168f2c: PUSH 0x10 POP RDI CALL 0x001213a0 MOV R14,RAX LAB_00168f37: MOV RDI,RSP PUSH -0x1 POP RDX MOV RSI,RBX XOR ECX,ECX CALL 0x0015fec6 LAB_00168f47: LEA RSI,[0x19d536] LEA RDI,[RSP + 0x20] MOV RDX,RSP CALL 0x001368bc MOV BPL,0x1 LAB_00168f5e: LEA RSI,[RSP + 0x20] MOV RDI,R14 CALL 0x00121ae0 XOR EBP,EBP MOV RSI,qword ptr [0x001dbfe8] MOV RDX,qword ptr [0x001dbf68] MOV RDI,R14 CALL 0x00121b70 LAB_00168f88: PUSH 0x10 POP RDI CALL 0x001213a0 MOV R14,RAX LAB_00168f93: MOV RDI,RSP PUSH -0x1 POP RDX MOV RSI,RBX XOR ECX,ECX CALL 0x0015fec6 LAB_00168fa3: LEA RSI,[0x19d9d0] LEA RDI,[RSP + 0x20] MOV RDX,RSP CALL 0x001368bc MOV BPL,0x1 LAB_00168fba: LEA RSI,[RSP + 0x20] MOV RDI,R14 CALL 0x00121ae0 XOR EBP,EBP MOV RSI,qword ptr [0x001dbfe8] MOV RDX,qword ptr [0x001dbf68] MOV RDI,R14 CALL 0x00121b70 LAB_00168fe1: PUSH 0x10 POP RDI CALL 0x001213a0 MOV R14,RAX LAB_00168fec: MOV RDI,RSP PUSH -0x1 POP RDX MOV RSI,RBX XOR ECX,ECX CALL 0x0015fec6 LAB_00168ffc: LEA RSI,[0x19d998] LEA RDI,[RSP + 0x20] MOV RDX,RSP CALL 0x001368bc MOV BPL,0x1 LAB_00169013: LEA RSI,[RSP + 0x20] MOV RDI,R14 CALL 0x00121ae0 XOR EBP,EBP MOV RSI,qword ptr [0x001dbfe8] MOV RDX,qword ptr [0x001dbf68] MOV RDI,R14 CALL 0x00121b70
/* minja::Value::pop(minja::Value const&) */ Value * minja::Value::pop(Value *param_1) { long *plVar1; char cVar2; uint uVar3; long lVar4; runtime_error *prVar5; Value *in_RDX; bool bVar6; long in_RSI; int iVar7; Value *pVVar8; int1 auStack_68 [32]; string local_48 [32]; plVar1 = *(long **)(in_RSI + 0x10); bVar6 = SUB81(in_RDX,0); iVar7 = (int)auStack_68; if (plVar1 == (long *)0x0) { if (*(long *)(in_RSI + 0x20) == 0) { prVar5 = (runtime_error *)__cxa_allocate_exception(0x10); /* try { // try from 00168edb to 00168eea has its CatchHandler @ 00169072 */ dump_abi_cxx11_(iVar7,SUB81(in_RSI,0)); /* try { // try from 00168eeb to 00168efe has its CatchHandler @ 00169046 */ std::operator+((char *)local_48,(string *)"Value is not an array or object: "); /* try { // try from 00168f02 to 00168f26 has its CatchHandler @ 00169044 */ std::runtime_error::runtime_error(prVar5,local_48); /* WARNING: Subroutine does not return */ __cxa_throw(prVar5,PTR_typeinfo_001dbfe8,PTR__runtime_error_001dbf68); } cVar2 = is_primitive(in_RDX); if (cVar2 == '\0') { prVar5 = (runtime_error *)__cxa_allocate_exception(0x10); /* try { // try from 00168f37 to 00168f46 has its CatchHandler @ 00169070 */ dump_abi_cxx11_(iVar7,bVar6); /* try { // try from 00168f47 to 00168f5a has its CatchHandler @ 00169042 */ std::operator+((char *)local_48,(string *)"Unashable type: "); /* try { // try from 00168f5e to 00168f82 has its CatchHandler @ 00169040 */ std::runtime_error::runtime_error(prVar5,local_48); /* WARNING: Subroutine does not return */ __cxa_throw(prVar5,PTR_typeinfo_001dbfe8,PTR__runtime_error_001dbf68); } lVar4 = nlohmann::json_abi_v3_11_3:: ordered_map<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,minja::Value,std::less<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>,std::allocator<std::pair<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const,minja::Value>>> ::find(*(ordered_map<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,minja::Value,std::less<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>,std::allocator<std::pair<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const,minja::Value>>> **)(in_RSI + 0x20),in_RDX + 0x40); if (lVar4 == *(long *)(*(long *)(in_RSI + 0x20) + 8)) { prVar5 = (runtime_error *)__cxa_allocate_exception(0x10); /* try { // try from 00168f93 to 00168fa2 has its CatchHandler @ 0016906e */ dump_abi_cxx11_(iVar7,bVar6); /* try { // try from 00168fa3 to 00168fb6 has its CatchHandler @ 0016903e */ std::operator+((char *)local_48,(string *)"Key not found: "); /* try { // try from 00168fba to 00168fde has its CatchHandler @ 0016903c */ std::runtime_error::runtime_error(prVar5,local_48); /* WARNING: Subroutine does not return */ __cxa_throw(prVar5,PTR_typeinfo_001dbfe8,PTR__runtime_error_001dbf68); } Value(param_1,(Value *)(lVar4 + 0x10)); /* try { // try from 00168dd5 to 00168ddc has its CatchHandler @ 00169085 */ nlohmann::json_abi_v3_11_3:: ordered_map<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,minja::Value,std::less<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>,std::allocator<std::pair<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const,minja::Value>>> ::erase(*(ordered_map<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,minja::Value,std::less<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>,std::allocator<std::pair<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const,minja::Value>>> **)(in_RSI + 0x20),lVar4); } else { if (*plVar1 == plVar1[1]) { prVar5 = (runtime_error *)__cxa_allocate_exception(0x10); /* try { // try from 00168e4f to 00168e5d has its CatchHandler @ 00169078 */ std::runtime_error::runtime_error(prVar5,"pop from empty list"); /* WARNING: Subroutine does not return */ __cxa_throw(prVar5,PTR_typeinfo_001dbfe8,PTR__runtime_error_001dbf68); } cVar2 = is_null(in_RDX); if (cVar2 == '\0') { if (1 < (byte)((char)in_RDX[0x40] - 5U)) { prVar5 = (runtime_error *)__cxa_allocate_exception(0x10); /* try { // try from 00168fec to 00168ffb has its CatchHandler @ 0016906c */ dump_abi_cxx11_(iVar7,bVar6); /* try { // try from 00168ffc to 0016900f has its CatchHandler @ 0016903a */ std::operator+((char *)local_48,(string *)"pop index must be an integer: "); /* try { // try from 00169013 to 00169037 has its CatchHandler @ 00169038 */ std::runtime_error::runtime_error(prVar5,local_48); /* WARNING: Subroutine does not return */ __cxa_throw(prVar5,PTR_typeinfo_001dbfe8,PTR__runtime_error_001dbf68); } uVar3 = get<int>(in_RDX); if ((-1 < (int)uVar3) && (lVar4 = **(long **)(in_RSI + 0x10), (int)uVar3 < (int)(((*(long **)(in_RSI + 0x10))[1] - lVar4) / 0x50))) { pVVar8 = (Value *)(lVar4 + (ulong)uVar3 * 0x50); Value(param_1,pVVar8); /* try { // try from 00168e2c to 00168e33 has its CatchHandler @ 00169074 */ std::vector<minja::Value,std::allocator<minja::Value>>::erase (*(vector<minja::Value,std::allocator<minja::Value>> **)(in_RSI + 0x10),pVVar8); return param_1; } prVar5 = (runtime_error *)__cxa_allocate_exception(0x10); /* try { // try from 00168e7f to 00168e8e has its CatchHandler @ 00169076 */ dump_abi_cxx11_(iVar7,bVar6); /* try { // try from 00168e8f to 00168ea2 has its CatchHandler @ 00169057 */ std::operator+((char *)local_48,(string *)"pop index out of range: "); /* try { // try from 00168ea6 to 00168eca has its CatchHandler @ 00169048 */ std::runtime_error::runtime_error(prVar5,local_48); /* WARNING: Subroutine does not return */ __cxa_throw(prVar5,PTR_typeinfo_001dbfe8,PTR__runtime_error_001dbf68); } Value(param_1,(Value *)(*(long *)(*(long *)(in_RSI + 0x10) + 8) + -0x50)); std::vector<minja::Value,std::allocator<minja::Value>>::pop_back (*(vector<minja::Value,std::allocator<minja::Value>> **)(in_RSI + 0x10)); } return param_1; }
6,046
minja::Value::pop(minja::Value const&)
monkey531[P]llama/common/minja.hpp
Value pop(const Value& index) { if (is_array()) { if (array_->empty()) throw std::runtime_error("pop from empty list"); if (index.is_null()) { auto ret = array_->back(); array_->pop_back(); return ret; } else if (!index.is_number_integer()) { throw std::runtime_error("pop index must be an integer: " + index.dump()); } else { auto i = index.get<int>(); if (i < 0 || i >= static_cast<int>(array_->size())) throw std::runtime_error("pop index out of range: " + index.dump()); auto it = array_->begin() + (i < 0 ? array_->size() + i : i); auto ret = *it; array_->erase(it); return ret; } } else if (is_object()) { if (!index.is_hashable()) throw std::runtime_error("Unashable type: " + index.dump()); auto it = object_->find(index.primitive_); if (it == object_->end()) throw std::runtime_error("Key not found: " + index.dump()); auto ret = it->second; object_->erase(it); return ret; } else { throw std::runtime_error("Value is not an array or object: " + dump()); } }
O3
cpp
minja::Value::pop(minja::Value const&): pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x48, %rsp movq %rdx, %rbx movq %rsi, %r15 movq %rdi, %rbp movq 0x10(%rsi), %rax testq %rax, %rax je 0x76359 movq 0x8(%rax), %rsi cmpq %rsi, (%rax) je 0x76467 cmpq $0x0, 0x20(%rbx) movb 0x40(%rbx), %al jne 0x763be cmpq $0x0, 0x10(%rbx) jne 0x763be testb %al, %al jne 0x763be cmpq $0x0, 0x30(%rbx) jne 0x763be addq $-0x50, %rsi movq %rbp, %rdi callq 0x71110 movq 0x10(%r15), %rdi movq 0x8(%rdi), %rsi addq $-0x50, %rsi movq %rsi, 0x8(%rdi) callq 0x70060 jmp 0x76455 movq 0x20(%r15), %r14 testq %r14, %r14 je 0x764f9 cmpq $0x0, 0x10(%rbx) jne 0x76559 cmpq $0x0, 0x20(%rbx) jne 0x76559 cmpq $0x0, 0x30(%rbx) jne 0x76559 movq (%r14), %r13 movq 0x8(%r14), %r12 cmpq %r12, %r13 je 0x7642e movq %rbp, 0x40(%rsp) leaq 0x40(%rbx), %rbp movq %r13, %rdi movq %rbp, %rsi callq 0x4d1d4 testb %al, %al jne 0x7641e addq $0x60, %r13 movq 0x8(%r14), %r12 cmpq %r12, %r13 jne 0x763a0 jmp 0x76421 addb $-0x5, %al cmpb $0x2, %al jae 0x76616 movq %rbx, %rdi callq 0x7410a testl %eax, %eax js 0x76499 movq 0x10(%r15), %rcx movq (%rcx), %r12 movq 0x8(%rcx), %rcx subq %r12, %rcx shrq $0x4, %rcx imull $0xcccccccd, %ecx, %ecx # imm = 0xCCCCCCCD cmpl %ecx, %eax jge 0x76499 movl %eax, %eax leaq (%rax,%rax,4), %rax shlq $0x4, %rax addq %rax, %r12 movq %rbp, %rdi movq %r12, %rsi callq 0x71110 movq 0x10(%r15), %rdi movq %r12, %rsi callq 0x779e6 jmp 0x76455 movq %r13, %r12 movq 0x20(%r15), %rax movq 0x8(%rax), %r13 movq 0x40(%rsp), %rbp cmpq %r13, %r12 je 0x765b9 leaq 0x10(%r12), %rsi movq %rbp, %rdi callq 0x71110 movq 0x20(%r15), %rdi leaq 0x60(%r12), %rdx movq %r12, %rsi callq 0x77a62 movq %rbp, %rax addq $0x48, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq movl $0x10, %edi callq 0x19370 movq %rax, %r14 leaq 0x454b9(%rip), %rsi # 0xbb934 movq %rax, %rdi callq 0x19270 movq 0x75b5e(%rip), %rsi # 0xebfe8 movq 0x75ad7(%rip), %rdx # 0xebf68 movq %r14, %rdi callq 0x19b70 movl $0x10, %edi callq 0x19370 movq %rax, %r14 movq %rsp, %rdi movq %rbx, %rsi movl $0xffffffff, %edx # imm = 0xFFFFFFFF xorl %ecx, %ecx callq 0x6ac06 leaq 0x454a8(%rip), %rsi # 0xbb967 leaq 0x20(%rsp), %rdi movq %rsp, %rdx callq 0x36a3b movb $0x1, %bpl leaq 0x20(%rsp), %rsi movq %r14, %rdi callq 0x19ac0 xorl %ebp, %ebp movq 0x75b03(%rip), %rsi # 0xebfe8 movq 0x75a7c(%rip), %rdx # 0xebf68 movq %r14, %rdi callq 0x19b70 jmp 0x76671 movl $0x10, %edi callq 0x19370 movq %rax, %r14 movq %rsp, %rdi movq %r15, %rsi movl $0xffffffff, %edx # imm = 0xFFFFFFFF xorl %ecx, %ecx callq 0x6ac06 leaq 0x45113(%rip), %rsi # 0xbb632 leaq 0x20(%rsp), %rdi movq %rsp, %rdx callq 0x36a3b movb $0x1, %bpl leaq 0x20(%rsp), %rsi movq %r14, %rdi callq 0x19ac0 xorl %ebp, %ebp movq 0x75aa3(%rip), %rsi # 0xebfe8 movq 0x75a1c(%rip), %rdx # 0xebf68 movq %r14, %rdi callq 0x19b70 jmp 0x76671 movl $0x10, %edi callq 0x19370 movq %rax, %r14 movq %rsp, %rdi movq %rbx, %rsi movl $0xffffffff, %edx # imm = 0xFFFFFFFF xorl %ecx, %ecx callq 0x6ac06 leaq 0x44f67(%rip), %rsi # 0xbb4e6 leaq 0x20(%rsp), %rdi movq %rsp, %rdx callq 0x36a3b movb $0x1, %bpl leaq 0x20(%rsp), %rsi movq %r14, %rdi callq 0x19ac0 xorl %ebp, %ebp movq 0x75a43(%rip), %rsi # 0xebfe8 movq 0x759bc(%rip), %rdx # 0xebf68 movq %r14, %rdi callq 0x19b70 jmp 0x76671 movl $0x10, %edi callq 0x19370 movq %rax, %r14 movq %rsp, %rdi movq %rbx, %rsi movl $0xffffffff, %edx # imm = 0xFFFFFFFF xorl %ecx, %ecx callq 0x6ac06 leaq 0x453a1(%rip), %rsi # 0xbb980 leaq 0x20(%rsp), %rdi movq %rsp, %rdx callq 0x36a3b movb $0x1, %bpl leaq 0x20(%rsp), %rsi movq %r14, %rdi callq 0x19ac0 xorl %ebp, %ebp movq 0x759e3(%rip), %rsi # 0xebfe8 movq 0x7595c(%rip), %rdx # 0xebf68 movq %r14, %rdi callq 0x19b70 jmp 0x76671 movl $0x10, %edi callq 0x19370 movq %rax, %r14 movq %rsp, %rdi movq %rbx, %rsi movl $0xffffffff, %edx # imm = 0xFFFFFFFF xorl %ecx, %ecx callq 0x6ac06 leaq 0x4530c(%rip), %rsi # 0xbb948 leaq 0x20(%rsp), %rdi movq %rsp, %rdx callq 0x36a3b movb $0x1, %bpl leaq 0x20(%rsp), %rsi movq %r14, %rdi callq 0x19ac0 xorl %ebp, %ebp movq 0x75986(%rip), %rsi # 0xebfe8 movq 0x758ff(%rip), %rdx # 0xebf68 movq %r14, %rdi callq 0x19b70 jmp 0x76681 jmp 0x766c1 jmp 0x76681 jmp 0x766c1 jmp 0x76681 jmp 0x766c1 jmp 0x76681 jmp 0x766c1 movq %rax, %rbx leaq 0x30(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0x7669f movq 0x30(%rsp), %rsi incq %rsi callq 0x196b0 leaq 0x10(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0x766ba movq 0x10(%rsp), %rsi incq %rsi callq 0x196b0 testb %bpl, %bpl jne 0x766f0 jmp 0x76705 movq %rax, %rbx leaq 0x10(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0x766f0 movq 0x10(%rsp), %rsi incq %rsi callq 0x196b0 jmp 0x766f0 jmp 0x766ed jmp 0x766ed jmp 0x766ed jmp 0x766ed jmp 0x766fa jmp 0x766ed movq %rax, %rbx movq %r14, %rdi callq 0x19510 jmp 0x76705 movq %rax, %rbx movq %rbp, %rdi callq 0x6a8e4 movq %rbx, %rdi callq 0x19be0 nop
_ZN5minja5Value3popERKS0_: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 48h mov rbx, rdx mov r15, rsi mov rbp, rdi mov rax, [rsi+10h] test rax, rax jz short loc_76359 mov rsi, [rax+8] cmp [rax], rsi jz loc_76467 cmp qword ptr [rbx+20h], 0 mov al, [rbx+40h] jnz loc_763BE cmp qword ptr [rbx+10h], 0 jnz loc_763BE test al, al jnz loc_763BE cmp qword ptr [rbx+30h], 0 jnz loc_763BE add rsi, 0FFFFFFFFFFFFFFB0h; minja::Value * mov rdi, rbp; this call _ZN5minja5ValueC2ERKS0_; minja::Value::Value(minja::Value const&) mov rdi, [r15+10h] mov rsi, [rdi+8] add rsi, 0FFFFFFFFFFFFFFB0h mov [rdi+8], rsi call _ZN9__gnu_cxx13new_allocatorIN5minja5ValueEE7destroyIS2_EEvPT_; __gnu_cxx::new_allocator<minja::Value>::destroy<minja::Value>(minja::Value *) jmp loc_76455 loc_76359: mov r14, [r15+20h] test r14, r14 jz loc_764F9 cmp qword ptr [rbx+10h], 0 jnz loc_76559 cmp qword ptr [rbx+20h], 0 jnz loc_76559 cmp qword ptr [rbx+30h], 0 jnz loc_76559 mov r13, [r14] mov r12, [r14+8] cmp r13, r12 jz loc_7642E mov [rsp+78h+var_38], rbp lea rbp, [rbx+40h] loc_763A0: mov rdi, r13 mov rsi, rbp call _ZN8nlohmann16json_abi_v3_11_3eqERKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEESF_; nlohmann::json_abi_v3_11_3::operator==(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const&,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const&) test al, al jnz short loc_7641E add r13, 60h ; '`' mov r12, [r14+8] cmp r13, r12 jnz short loc_763A0 jmp short loc_76421 loc_763BE: add al, 0FBh cmp al, 2 jnb loc_76616 mov rdi, rbx call _ZNK5minja5Value3getIiEET_v; minja::Value::get<int>(void) test eax, eax js loc_76499 mov rcx, [r15+10h] mov r12, [rcx] mov rcx, [rcx+8] sub rcx, r12 shr rcx, 4 imul ecx, 0CCCCCCCDh cmp eax, ecx jge loc_76499 mov eax, eax lea rax, [rax+rax*4] shl rax, 4 add r12, rax mov rdi, rbp; this mov rsi, r12; minja::Value * call _ZN5minja5ValueC2ERKS0_; minja::Value::Value(minja::Value const&) mov rdi, [r15+10h] mov rsi, r12 call _ZNSt6vectorIN5minja5ValueESaIS1_EE8_M_eraseEN9__gnu_cxx17__normal_iteratorIPS1_S3_EE; std::vector<minja::Value>::_M_erase(__gnu_cxx::__normal_iterator<minja::Value*,std::vector<minja::Value>>) jmp short loc_76455 loc_7641E: mov r12, r13 loc_76421: mov rax, [r15+20h] mov r13, [rax+8] mov rbp, [rsp+78h+var_38] loc_7642E: cmp r12, r13 jz loc_765B9 lea rsi, [r12+10h]; minja::Value * mov rdi, rbp; this call _ZN5minja5ValueC2ERKS0_; minja::Value::Value(minja::Value const&) mov rdi, [r15+20h] lea rdx, [r12+60h] mov rsi, r12 call _ZN8nlohmann16json_abi_v3_11_311ordered_mapINS0_10basic_jsonIS1_St6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEEN5minja5ValueESt4lessISD_ESaISt4pairIKSD_SF_EEE5eraseEN9__gnu_cxx17__normal_iteratorIPSK_S3_ISK_SL_EEESR_; nlohmann::json_abi_v3_11_3::ordered_map<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>,minja::Value,std::less<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>,std::allocator<std::pair<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const,minja::Value>>>::erase(__gnu_cxx::__normal_iterator<std::pair<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const,minja::Value>*,std::vector<std::pair<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const,minja::Value>>>,__gnu_cxx::__normal_iterator<std::pair<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const,minja::Value>*,std::vector<std::pair<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const,minja::Value>>>) loc_76455: mov rax, rbp add rsp, 48h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn loc_76467: mov edi, 10h; thrown_size call ___cxa_allocate_exception mov r14, rax lea rsi, aPopFromEmptyLi; "pop from empty list" mov rdi, rax; this call __ZNSt13runtime_errorC1EPKc; std::runtime_error::runtime_error(char const*) mov rsi, cs:lptinfo; lptinfo mov rdx, cs:_ZTISt19_Sp_make_shared_tag; void (*)(void *) mov rdi, r14; void * call ___cxa_throw loc_76499: mov edi, 10h; thrown_size call ___cxa_allocate_exception mov r14, rax mov rdi, rsp mov rsi, rbx mov edx, 0FFFFFFFFh xor ecx, ecx call _ZNK5minja5Value4dumpB5cxx11Eib; minja::Value::dump(int,bool) lea rsi, aPopIndexOutOfR; "pop index out of range: " lea rdi, [rsp+78h+var_58] mov rdx, rsp call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_OS8_; std::operator+<char>(char const*,std::string&&) mov bpl, 1 lea rsi, [rsp+78h+var_58] mov rdi, r14 call __ZNSt13runtime_errorC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; std::runtime_error::runtime_error(std::string const&) xor ebp, ebp mov rsi, cs:lptinfo; lptinfo mov rdx, cs:_ZTISt19_Sp_make_shared_tag; void (*)(void *) mov rdi, r14; void * call ___cxa_throw jmp loc_76671 loc_764F9: mov edi, 10h; thrown_size call ___cxa_allocate_exception mov r14, rax mov rdi, rsp mov rsi, r15 mov edx, 0FFFFFFFFh xor ecx, ecx call _ZNK5minja5Value4dumpB5cxx11Eib; minja::Value::dump(int,bool) lea rsi, aValueIsNotAnAr_0; "Value is not an array or object: " lea rdi, [rsp+78h+var_58] mov rdx, rsp call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_OS8_; std::operator+<char>(char const*,std::string&&) mov bpl, 1 lea rsi, [rsp+78h+var_58] mov rdi, r14 call __ZNSt13runtime_errorC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; std::runtime_error::runtime_error(std::string const&) xor ebp, ebp mov rsi, cs:lptinfo; lptinfo mov rdx, cs:_ZTISt19_Sp_make_shared_tag; void (*)(void *) mov rdi, r14; void * call ___cxa_throw jmp loc_76671 loc_76559: mov edi, 10h; thrown_size call ___cxa_allocate_exception mov r14, rax mov rdi, rsp mov rsi, rbx mov edx, 0FFFFFFFFh xor ecx, ecx call _ZNK5minja5Value4dumpB5cxx11Eib; minja::Value::dump(int,bool) lea rsi, aUnashableType; "Unashable type: " lea rdi, [rsp+78h+var_58] mov rdx, rsp call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_OS8_; std::operator+<char>(char const*,std::string&&) mov bpl, 1 lea rsi, [rsp+78h+var_58] mov rdi, r14 call __ZNSt13runtime_errorC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; std::runtime_error::runtime_error(std::string const&) xor ebp, ebp mov rsi, cs:lptinfo; lptinfo mov rdx, cs:_ZTISt19_Sp_make_shared_tag; void (*)(void *) mov rdi, r14; void * call ___cxa_throw jmp loc_76671 loc_765B9: mov edi, 10h; thrown_size call ___cxa_allocate_exception mov r14, rax mov rdi, rsp mov rsi, rbx mov edx, 0FFFFFFFFh xor ecx, ecx call _ZNK5minja5Value4dumpB5cxx11Eib; minja::Value::dump(int,bool) lea rsi, aKeyNotFound_0; "Key not found: " lea rdi, [rsp+78h+var_58] mov rdx, rsp call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_OS8_; std::operator+<char>(char const*,std::string&&) mov bpl, 1 lea rsi, [rsp+78h+var_58] mov rdi, r14 call __ZNSt13runtime_errorC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; std::runtime_error::runtime_error(std::string const&) xor ebp, ebp mov rsi, cs:lptinfo; lptinfo mov rdx, cs:_ZTISt19_Sp_make_shared_tag; void (*)(void *) mov rdi, r14; void * call ___cxa_throw jmp short loc_76671 loc_76616: mov edi, 10h; thrown_size call ___cxa_allocate_exception mov r14, rax mov rdi, rsp mov rsi, rbx mov edx, 0FFFFFFFFh xor ecx, ecx call _ZNK5minja5Value4dumpB5cxx11Eib; minja::Value::dump(int,bool) lea rsi, aPopIndexMustBe; "pop index must be an integer: " lea rdi, [rsp+78h+var_58] mov rdx, rsp call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_OS8_; std::operator+<char>(char const*,std::string&&) mov bpl, 1 lea rsi, [rsp+78h+var_58] mov rdi, r14 call __ZNSt13runtime_errorC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; std::runtime_error::runtime_error(std::string const&) xor ebp, ebp mov rsi, cs:lptinfo; lptinfo mov rdx, cs:_ZTISt19_Sp_make_shared_tag; void (*)(void *) mov rdi, r14; void * call ___cxa_throw loc_76671: jmp short loc_76681 jmp short loc_766C1 jmp short loc_76681 jmp short loc_766C1 jmp short loc_76681 jmp short loc_766C1 jmp short loc_76681 jmp short loc_766C1 loc_76681: mov rbx, rax lea rax, [rsp+78h+var_48] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_7669F mov rsi, [rsp+78h+var_48] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_7669F: lea rax, [rsp+78h+var_68] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_766BA mov rsi, [rsp+78h+var_68] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_766BA: test bpl, bpl jnz short loc_766F0 jmp short loc_76705 loc_766C1: mov rbx, rax lea rax, [rsp+78h+var_68] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_766F0 mov rsi, [rsp+78h+var_68] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) jmp short loc_766F0 jmp short loc_766ED jmp short loc_766ED jmp short loc_766ED jmp short loc_766ED jmp short loc_766FA jmp short $+2 loc_766ED: mov rbx, rax loc_766F0: mov rdi, r14; void * call ___cxa_free_exception jmp short loc_76705 loc_766FA: mov rbx, rax mov rdi, rbp; this call _ZN5minja5ValueD2Ev; minja::Value::~Value() loc_76705: mov rdi, rbx call __Unwind_Resume
minja::Value * minja::Value::pop(minja::Value *this, const minja::Value *a2, long long a3, __m128d a4) { minja::Value *v6; // rbp _QWORD *v7; // rax long long v8; // rsi char v9; // al long long v10; // rdi long long v11; // rsi unsigned __int8 **v12; // r14 unsigned __int8 *v13; // r13 unsigned __int8 *v14; // r12 int v15; // eax _QWORD *v16; // rcx const minja::Value *v17; // r12 std::runtime_error *exception; // r14 void *v20; // r14 void *v21; // r14 void *v22; // r14 void *v23; // r14 void *v24; // r14 _BYTE v25[16]; // [rsp+0h] [rbp-78h] BYREF _BYTE v26[16]; // [rsp+20h] [rbp-58h] BYREF minja::Value *v27; // [rsp+40h] [rbp-38h] v6 = this; v7 = (_QWORD *)*((_QWORD *)a2 + 2); if ( v7 ) { v8 = v7[1]; if ( *v7 == v8 ) { exception = (std::runtime_error *)__cxa_allocate_exception(0x10uLL); std::runtime_error::runtime_error(exception, "pop from empty list"); __cxa_throw( exception, (struct type_info *)&`typeinfo for'std::runtime_error, (void (*)(void *))&std::runtime_error::~runtime_error); } v9 = *(_BYTE *)(a3 + 64); if ( *(_QWORD *)(a3 + 32) || *(_QWORD *)(a3 + 16) || v9 || *(_QWORD *)(a3 + 48) ) { if ( (unsigned __int8)(v9 - 5) >= 2u ) { v24 = __cxa_allocate_exception(0x10uLL); minja::Value::dump[abi:cxx11]((long long)v25, a3, 0xFFFFFFFF, 0); std::operator+<char>((long long)v26, (long long)"pop index must be an integer: ", (long long)v25); std::runtime_error::runtime_error(v24, v26); __cxa_throw( v24, (struct type_info *)&`typeinfo for'std::runtime_error, (void (*)(void *))&std::runtime_error::~runtime_error); } v15 = minja::Value::get<int>(a3); if ( v15 < 0 || (v16 = (_QWORD *)*((_QWORD *)a2 + 2), v15 >= (int)(-858993459 * ((v16[1] - *v16) >> 4))) ) { v20 = __cxa_allocate_exception(0x10uLL); minja::Value::dump[abi:cxx11]((long long)v25, a3, 0xFFFFFFFF, 0); std::operator+<char>((long long)v26, (long long)"pop index out of range: ", (long long)v25); std::runtime_error::runtime_error(v20, v26); __cxa_throw( v20, (struct type_info *)&`typeinfo for'std::runtime_error, (void (*)(void *))&std::runtime_error::~runtime_error); } v17 = (const minja::Value *)(80LL * (unsigned int)v15 + *v16); minja::Value::Value(this, v17); std::vector<minja::Value>::_M_erase(*((_QWORD *)a2 + 2), v17); } else { minja::Value::Value(this, (const minja::Value *)(v8 - 80)); v10 = *((_QWORD *)a2 + 2); v11 = *(_QWORD *)(v10 + 8) - 80LL; *(_QWORD *)(v10 + 8) = v11; __gnu_cxx::new_allocator<minja::Value>::destroy<minja::Value>(v10, v11); } } else { v12 = (unsigned __int8 **)*((_QWORD *)a2 + 4); if ( !v12 ) { v21 = __cxa_allocate_exception(0x10uLL); minja::Value::dump[abi:cxx11]((long long)v25, (long long)a2, 0xFFFFFFFF, 0); std::operator+<char>((long long)v26, (long long)"Value is not an array or object: ", (long long)v25); std::runtime_error::runtime_error(v21, v26); __cxa_throw( v21, (struct type_info *)&`typeinfo for'std::runtime_error, (void (*)(void *))&std::runtime_error::~runtime_error); } if ( *(_QWORD *)(a3 + 16) || *(_QWORD *)(a3 + 32) || *(_QWORD *)(a3 + 48) ) { v22 = __cxa_allocate_exception(0x10uLL); minja::Value::dump[abi:cxx11]((long long)v25, a3, 0xFFFFFFFF, 0); std::operator+<char>((long long)v26, (long long)"Unashable type: ", (long long)v25); std::runtime_error::runtime_error(v22, v26); __cxa_throw( v22, (struct type_info *)&`typeinfo for'std::runtime_error, (void (*)(void *))&std::runtime_error::~runtime_error); } v13 = *v12; v14 = v12[1]; if ( *v12 != v14 ) { v27 = this; while ( !(unsigned __int8)nlohmann::json_abi_v3_11_3::operator==(v13, (unsigned __int8 *)(a3 + 64), a4) ) { v13 += 96; v14 = v12[1]; if ( v13 == v14 ) goto LABEL_22; } v14 = v13; LABEL_22: v13 = *(unsigned __int8 **)(*((_QWORD *)a2 + 4) + 8LL); v6 = v27; } if ( v14 == v13 ) { v23 = __cxa_allocate_exception(0x10uLL); minja::Value::dump[abi:cxx11]((long long)v25, a3, 0xFFFFFFFF, 0); std::operator+<char>((long long)v26, (long long)"Key not found: ", (long long)v25); std::runtime_error::runtime_error(v23, v26); __cxa_throw( v23, (struct type_info *)&`typeinfo for'std::runtime_error, (void (*)(void *))&std::runtime_error::~runtime_error); } minja::Value::Value(v6, (const minja::Value *)(v14 + 16)); nlohmann::json_abi_v3_11_3::ordered_map<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,minja::Value,std::less<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>,std::allocator<std::pair<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void> const,minja::Value>>>::erase( *((_QWORD *)a2 + 4), v14, v14 + 96); } return v6; }
pop: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x48 MOV RBX,RDX MOV R15,RSI MOV RBP,RDI MOV RAX,qword ptr [RSI + 0x10] TEST RAX,RAX JZ 0x00176359 MOV RSI,qword ptr [RAX + 0x8] CMP qword ptr [RAX],RSI JZ 0x00176467 CMP qword ptr [RBX + 0x20],0x0 MOV AL,byte ptr [RBX + 0x40] JNZ 0x001763be CMP qword ptr [RBX + 0x10],0x0 JNZ 0x001763be TEST AL,AL JNZ 0x001763be CMP qword ptr [RBX + 0x30],0x0 JNZ 0x001763be ADD RSI,-0x50 MOV RDI,RBP CALL 0x00171110 MOV RDI,qword ptr [R15 + 0x10] MOV RSI,qword ptr [RDI + 0x8] ADD RSI,-0x50 MOV qword ptr [RDI + 0x8],RSI CALL 0x00170060 JMP 0x00176455 LAB_00176359: MOV R14,qword ptr [R15 + 0x20] TEST R14,R14 JZ 0x001764f9 CMP qword ptr [RBX + 0x10],0x0 JNZ 0x00176559 CMP qword ptr [RBX + 0x20],0x0 JNZ 0x00176559 CMP qword ptr [RBX + 0x30],0x0 JNZ 0x00176559 MOV R13,qword ptr [R14] MOV R12,qword ptr [R14 + 0x8] CMP R13,R12 JZ 0x0017642e MOV qword ptr [RSP + 0x40],RBP LEA RBP,[RBX + 0x40] LAB_001763a0: MOV RDI,R13 MOV RSI,RBP CALL 0x0014d1d4 TEST AL,AL JNZ 0x0017641e ADD R13,0x60 MOV R12,qword ptr [R14 + 0x8] CMP R13,R12 JNZ 0x001763a0 JMP 0x00176421 LAB_001763be: ADD AL,0xfb CMP AL,0x2 JNC 0x00176616 MOV RDI,RBX CALL 0x0017410a TEST EAX,EAX JS 0x00176499 MOV RCX,qword ptr [R15 + 0x10] MOV R12,qword ptr [RCX] MOV RCX,qword ptr [RCX + 0x8] SUB RCX,R12 SHR RCX,0x4 IMUL ECX,ECX,-0x33333333 CMP EAX,ECX JGE 0x00176499 MOV EAX,EAX LEA RAX,[RAX + RAX*0x4] SHL RAX,0x4 ADD R12,RAX MOV RDI,RBP MOV RSI,R12 CALL 0x00171110 MOV RDI,qword ptr [R15 + 0x10] LAB_00176414: MOV RSI,R12 CALL 0x001779e6 LAB_0017641c: JMP 0x00176455 LAB_0017641e: MOV R12,R13 LAB_00176421: MOV RAX,qword ptr [R15 + 0x20] MOV R13,qword ptr [RAX + 0x8] MOV RBP,qword ptr [RSP + 0x40] LAB_0017642e: CMP R12,R13 JZ 0x001765b9 LEA RSI,[R12 + 0x10] MOV RDI,RBP CALL 0x00171110 MOV RDI,qword ptr [R15 + 0x20] LEA RDX,[R12 + 0x60] LAB_0017644d: MOV RSI,R12 CALL 0x00177a62 LAB_00176455: MOV RAX,RBP ADD RSP,0x48 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET LAB_00176467: MOV EDI,0x10 CALL 0x00119370 MOV R14,RAX LAB_00176474: LEA RSI,[0x1bb934] MOV RDI,RAX CALL 0x00119270 LAB_00176483: MOV RSI,qword ptr [0x001ebfe8] MOV RDX,qword ptr [0x001ebf68] MOV RDI,R14 CALL 0x00119b70 LAB_00176499: MOV EDI,0x10 CALL 0x00119370 MOV R14,RAX LAB_001764a6: MOV RDI,RSP MOV RSI,RBX MOV EDX,0xffffffff XOR ECX,ECX CALL 0x0016ac06 LAB_001764b8: LEA RSI,[0x1bb967] LEA RDI,[RSP + 0x20] MOV RDX,RSP CALL 0x00136a3b MOV BPL,0x1 LAB_001764cf: LEA RSI,[RSP + 0x20] MOV RDI,R14 CALL 0x00119ac0 XOR EBP,EBP MOV RSI,qword ptr [0x001ebfe8] MOV RDX,qword ptr [0x001ebf68] MOV RDI,R14 CALL 0x00119b70 LAB_001764f9: MOV EDI,0x10 CALL 0x00119370 MOV R14,RAX LAB_00176506: MOV RDI,RSP MOV RSI,R15 MOV EDX,0xffffffff XOR ECX,ECX CALL 0x0016ac06 LAB_00176518: LEA RSI,[0x1bb632] LEA RDI,[RSP + 0x20] MOV RDX,RSP CALL 0x00136a3b MOV BPL,0x1 LAB_0017652f: LEA RSI,[RSP + 0x20] MOV RDI,R14 CALL 0x00119ac0 XOR EBP,EBP MOV RSI,qword ptr [0x001ebfe8] MOV RDX,qword ptr [0x001ebf68] MOV RDI,R14 CALL 0x00119b70 LAB_00176559: MOV EDI,0x10 CALL 0x00119370 MOV R14,RAX LAB_00176566: MOV RDI,RSP MOV RSI,RBX MOV EDX,0xffffffff XOR ECX,ECX CALL 0x0016ac06 LAB_00176578: LEA RSI,[0x1bb4e6] LEA RDI,[RSP + 0x20] MOV RDX,RSP CALL 0x00136a3b MOV BPL,0x1 LAB_0017658f: LEA RSI,[RSP + 0x20] MOV RDI,R14 CALL 0x00119ac0 XOR EBP,EBP MOV RSI,qword ptr [0x001ebfe8] MOV RDX,qword ptr [0x001ebf68] MOV RDI,R14 CALL 0x00119b70 LAB_001765b9: MOV EDI,0x10 CALL 0x00119370 MOV R14,RAX LAB_001765c6: MOV RDI,RSP MOV RSI,RBX MOV EDX,0xffffffff XOR ECX,ECX CALL 0x0016ac06 LAB_001765d8: LEA RSI,[0x1bb980] LEA RDI,[RSP + 0x20] MOV RDX,RSP CALL 0x00136a3b MOV BPL,0x1 LAB_001765ef: LEA RSI,[RSP + 0x20] MOV RDI,R14 CALL 0x00119ac0 XOR EBP,EBP MOV RSI,qword ptr [0x001ebfe8] MOV RDX,qword ptr [0x001ebf68] MOV RDI,R14 CALL 0x00119b70 LAB_00176616: MOV EDI,0x10 CALL 0x00119370 MOV R14,RAX LAB_00176623: MOV RDI,RSP MOV RSI,RBX MOV EDX,0xffffffff XOR ECX,ECX CALL 0x0016ac06 LAB_00176635: LEA RSI,[0x1bb948] LEA RDI,[RSP + 0x20] MOV RDX,RSP CALL 0x00136a3b MOV BPL,0x1 LAB_0017664c: LEA RSI,[RSP + 0x20] MOV RDI,R14 CALL 0x00119ac0 XOR EBP,EBP MOV RSI,qword ptr [0x001ebfe8] MOV RDX,qword ptr [0x001ebf68] MOV RDI,R14 CALL 0x00119b70
/* minja::Value::pop(minja::Value const&) */ Value * minja::Value::pop(Value *param_1) { long *plVar1; new_allocator<minja::Value> *this; long lVar2; char cVar3; uint uVar4; runtime_error *prVar5; int iVar6; Value *in_RDX; bool bVar7; long in_RSI; int iVar8; Value *pVVar9; basic_json *pbVar10; basic_json *pbVar11; int1 auStack_78 [32]; string local_58 [32]; Value *local_38; plVar1 = *(long **)(in_RSI + 0x10); bVar7 = SUB81(in_RDX,0); iVar8 = (int)auStack_78; if (plVar1 == (long *)0x0) { plVar1 = *(long **)(in_RSI + 0x20); if (plVar1 == (long *)0x0) { prVar5 = (runtime_error *)__cxa_allocate_exception(0x10); /* try { // try from 00176506 to 00176517 has its CatchHandler @ 001766e7 */ dump_abi_cxx11_(iVar8,SUB81(in_RSI,0)); /* try { // try from 00176518 to 0017652b has its CatchHandler @ 0017667f */ std::operator+((char *)local_58,(string *)"Value is not an array or object: "); /* try { // try from 0017652f to 00176553 has its CatchHandler @ 0017667d */ std::runtime_error::runtime_error(prVar5,local_58); /* WARNING: Subroutine does not return */ __cxa_throw(prVar5,PTR_typeinfo_001ebfe8,PTR__runtime_error_001ebf68); } if (((*(long *)(in_RDX + 0x10) != 0) || (*(long *)(in_RDX + 0x20) != 0)) || (*(long *)(in_RDX + 0x30) != 0)) { prVar5 = (runtime_error *)__cxa_allocate_exception(0x10); /* try { // try from 00176566 to 00176577 has its CatchHandler @ 001766e5 */ dump_abi_cxx11_(iVar8,bVar7); /* try { // try from 00176578 to 0017658b has its CatchHandler @ 0017667b */ std::operator+((char *)local_58,(string *)"Unashable type: "); /* try { // try from 0017658f to 001765b3 has its CatchHandler @ 00176679 */ std::runtime_error::runtime_error(prVar5,local_58); /* WARNING: Subroutine does not return */ __cxa_throw(prVar5,PTR_typeinfo_001ebfe8,PTR__runtime_error_001ebf68); } pbVar11 = (basic_json *)*plVar1; pbVar10 = (basic_json *)plVar1[1]; if (pbVar11 != pbVar10) { local_38 = param_1; do { pbVar10 = pbVar11; cVar3 = nlohmann::json_abi_v3_11_3::operator==(pbVar10,(basic_json *)(in_RDX + 0x40)); if (cVar3 != '\0') break; pbVar11 = pbVar10 + 0x60; pbVar10 = (basic_json *)plVar1[1]; } while (pbVar11 != pbVar10); pbVar11 = *(basic_json **)(*(long *)(in_RSI + 0x20) + 8); param_1 = local_38; } if (pbVar10 == pbVar11) { prVar5 = (runtime_error *)__cxa_allocate_exception(0x10); /* try { // try from 001765c6 to 001765d7 has its CatchHandler @ 001766e3 */ dump_abi_cxx11_(iVar8,bVar7); /* try { // try from 001765d8 to 001765eb has its CatchHandler @ 00176677 */ std::operator+((char *)local_58,(string *)"Key not found: "); /* try { // try from 001765ef to 00176613 has its CatchHandler @ 00176675 */ std::runtime_error::runtime_error(prVar5,local_58); /* WARNING: Subroutine does not return */ __cxa_throw(prVar5,PTR_typeinfo_001ebfe8,PTR__runtime_error_001ebf68); } Value(param_1,(Value *)(pbVar10 + 0x10)); /* try { // try from 0017644d to 00176454 has its CatchHandler @ 001766fa */ nlohmann::json_abi_v3_11_3:: ordered_map<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,minja::Value,std::less<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>,std::allocator<std::pair<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const,minja::Value>>> ::erase(*(ordered_map<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,minja::Value,std::less<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>,std::allocator<std::pair<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const,minja::Value>>> **)(in_RSI + 0x20),pbVar10,pbVar10 + 0x60); } else { if (*plVar1 == plVar1[1]) { prVar5 = (runtime_error *)__cxa_allocate_exception(0x10); /* try { // try from 00176474 to 00176482 has its CatchHandler @ 001766ed */ std::runtime_error::runtime_error(prVar5,"pop from empty list"); /* WARNING: Subroutine does not return */ __cxa_throw(prVar5,PTR_typeinfo_001ebfe8,PTR__runtime_error_001ebf68); } if (((*(long *)(in_RDX + 0x20) == 0) && (*(long *)(in_RDX + 0x10) == 0)) && ((in_RDX[0x40] == (Value)0x0 && (*(long *)(in_RDX + 0x30) == 0)))) { Value(param_1,(Value *)(plVar1[1] + -0x50)); this = *(new_allocator<minja::Value> **)(in_RSI + 0x10); lVar2 = *(long *)(this + 8); *(Value **)(this + 8) = (Value *)(lVar2 + -0x50); __gnu_cxx::new_allocator<minja::Value>::destroy<minja::Value>(this,(Value *)(lVar2 + -0x50)); } else { if (1 < (byte)((char)in_RDX[0x40] - 5U)) { prVar5 = (runtime_error *)__cxa_allocate_exception(0x10); /* try { // try from 00176623 to 00176634 has its CatchHandler @ 001766e1 */ dump_abi_cxx11_(iVar8,bVar7); /* try { // try from 00176635 to 00176648 has its CatchHandler @ 00176673 */ std::operator+((char *)local_58,(string *)"pop index must be an integer: "); /* try { // try from 0017664c to 00176670 has its CatchHandler @ 00176671 */ std::runtime_error::runtime_error(prVar5,local_58); /* WARNING: Subroutine does not return */ __cxa_throw(prVar5,PTR_typeinfo_001ebfe8,PTR__runtime_error_001ebf68); } uVar4 = get<int>(in_RDX); if (((int)uVar4 < 0) || (lVar2 = **(long **)(in_RSI + 0x10), iVar6 = (int)((ulong)((*(long **)(in_RSI + 0x10))[1] - lVar2) >> 4), SBORROW4(uVar4,iVar6 * -0x33333333) == (int)(uVar4 + iVar6 * 0x33333333) < 0)) { prVar5 = (runtime_error *)__cxa_allocate_exception(0x10); /* try { // try from 001764a6 to 001764b7 has its CatchHandler @ 001766eb */ dump_abi_cxx11_(iVar8,bVar7); /* try { // try from 001764b8 to 001764cb has its CatchHandler @ 001766c1 */ std::operator+((char *)local_58,(string *)"pop index out of range: "); /* try { // try from 001764cf to 001764f3 has its CatchHandler @ 00176681 */ std::runtime_error::runtime_error(prVar5,local_58); /* WARNING: Subroutine does not return */ __cxa_throw(prVar5,PTR_typeinfo_001ebfe8,PTR__runtime_error_001ebf68); } pVVar9 = (Value *)(lVar2 + (ulong)uVar4 * 0x50); Value(param_1,pVVar9); /* try { // try from 00176414 to 0017641b has its CatchHandler @ 001766e9 */ std::vector<minja::Value,std::allocator<minja::Value>>::_M_erase (*(vector<minja::Value,std::allocator<minja::Value>> **)(in_RSI + 0x10),pVVar9); } } return param_1; }
6,047
ggml_backend_alloc_buffer
ngxson[P]ggml-easy/ggml/src/ggml-backend.cpp
ggml_backend_buffer_t ggml_backend_alloc_buffer(ggml_backend_t backend, size_t size) { return ggml_backend_buft_alloc_buffer(ggml_backend_get_default_buffer_type(backend), size); }
O1
cpp
ggml_backend_alloc_buffer: pushq %r14 pushq %rbx pushq %rax movq %rsi, %r14 movq 0x70(%rdi), %rdi callq *0x30(%rdi) movq %rax, %rbx testq %r14, %r14 je 0x253e8 movq 0x8(%rbx), %rax movq %rbx, %rdi movq %r14, %rsi addq $0x8, %rsp popq %rbx popq %r14 jmpq *%rax movl $0x68, %edi callq 0x17030 xorps %xmm0, %xmm0 movaps %xmm0, (%rax) movaps %xmm0, 0x10(%rax) movaps %xmm0, 0x20(%rax) movaps %xmm0, 0x30(%rax) movq $0x0, 0x40(%rax) movq %rbx, 0x48(%rax) movaps %xmm0, 0x50(%rax) movl $0x0, 0x60(%rax) addq $0x8, %rsp popq %rbx popq %r14 retq
ggml_backend_alloc_buffer: push r14 push rbx push rax mov r14, rsi mov rdi, [rdi+70h] call qword ptr [rdi+30h] mov rbx, rax test r14, r14 jz short loc_253E8 mov rax, [rbx+8] mov rdi, rbx mov rsi, r14 add rsp, 8 pop rbx pop r14 jmp rax loc_253E8: mov edi, 68h ; 'h'; unsigned __int64 call __Znwm; operator new(ulong) xorps xmm0, xmm0 movaps xmmword ptr [rax], xmm0 movaps xmmword ptr [rax+10h], xmm0 movaps xmmword ptr [rax+20h], xmm0 movaps xmmword ptr [rax+30h], xmm0 mov qword ptr [rax+40h], 0 mov [rax+48h], rbx movaps xmmword ptr [rax+50h], xmm0 mov dword ptr [rax+60h], 0 add rsp, 8 pop rbx pop r14 retn
long long ggml_backend_alloc_buffer(long long a1, long long a2) { long long v2; // rax long long v3; // rbx long long result; // rax v2 = (*(long long ( **)(_QWORD))(*(_QWORD *)(a1 + 112) + 48LL))(*(_QWORD *)(a1 + 112)); v3 = v2; if ( a2 ) return (*(long long ( **)(long long, long long))(v2 + 8))(v2, a2); result = operator new(0x68uLL); *(_OWORD *)result = 0LL; *(_OWORD *)(result + 16) = 0LL; *(_OWORD *)(result + 32) = 0LL; *(_OWORD *)(result + 48) = 0LL; *(_QWORD *)(result + 64) = 0LL; *(_QWORD *)(result + 72) = v3; *(_OWORD *)(result + 80) = 0LL; *(_DWORD *)(result + 96) = 0; return result; }
ggml_backend_alloc_buffer: PUSH R14 PUSH RBX PUSH RAX MOV R14,RSI MOV RDI,qword ptr [RDI + 0x70] CALL qword ptr [RDI + 0x30] MOV RBX,RAX TEST R14,R14 JZ 0x001253e8 MOV RAX,qword ptr [RBX + 0x8] MOV RDI,RBX MOV RSI,R14 ADD RSP,0x8 POP RBX POP R14 JMP RAX LAB_001253e8: MOV EDI,0x68 CALL 0x00117030 XORPS XMM0,XMM0 MOVAPS xmmword ptr [RAX],XMM0 MOVAPS xmmword ptr [RAX + 0x10],XMM0 MOVAPS xmmword ptr [RAX + 0x20],XMM0 MOVAPS xmmword ptr [RAX + 0x30],XMM0 MOV qword ptr [RAX + 0x40],0x0 MOV qword ptr [RAX + 0x48],RBX MOVAPS xmmword ptr [RAX + 0x50],XMM0 MOV dword ptr [RAX + 0x60],0x0 ADD RSP,0x8 POP RBX POP R14 RET
void ggml_backend_alloc_buffer(long param_1,long param_2) { long lVar1; int8 *puVar2; lVar1 = (**(code **)(*(long *)(param_1 + 0x70) + 0x30))(); if (param_2 != 0) { /* WARNING: Could not recover jumptable at 0x001253e6. Too many branches */ /* WARNING: Treating indirect jump as call */ (**(code **)(lVar1 + 8))(lVar1,param_2); return; } puVar2 = (int8 *)operator_new(0x68); *puVar2 = 0; puVar2[1] = 0; puVar2[2] = 0; puVar2[3] = 0; puVar2[4] = 0; puVar2[5] = 0; puVar2[6] = 0; puVar2[7] = 0; puVar2[8] = 0; puVar2[9] = lVar1; puVar2[10] = 0; puVar2[0xb] = 0; *(int4 *)(puVar2 + 0xc) = 0; return; }
6,048
my_charset_loader_init_mysys
eloqsql/mysys/charset.c
void my_charset_loader_init_mysys(MY_CHARSET_LOADER *loader) { loader->error[0]= '\0'; loader->once_alloc= my_once_alloc_c; loader->malloc= my_malloc_c; loader->realloc= my_realloc_c; loader->free= my_free; loader->reporter= my_charset_error_reporter; loader->add_collation= add_collation; }
O0
c
my_charset_loader_init_mysys: pushq %rbp movq %rsp, %rbp movq %rdi, -0x8(%rbp) movq -0x8(%rbp), %rax movb $0x0, (%rax) movq -0x8(%rbp), %rax leaq 0x66(%rip), %rcx # 0x7c2a0 movq %rcx, 0x80(%rax) movq -0x8(%rbp), %rax leaq 0x74(%rip), %rcx # 0x7c2c0 movq %rcx, 0x88(%rax) movq -0x8(%rbp), %rax leaq 0x92(%rip), %rcx # 0x7c2f0 movq %rcx, 0x90(%rax) movq -0x8(%rbp), %rax leaq 0xf020(%rip), %rcx # 0x8b290 movq %rcx, 0x98(%rax) leaq 0x1cda62(%rip), %rax # 0x249ce0 movq (%rax), %rcx movq -0x8(%rbp), %rax movq %rcx, 0xa0(%rax) movq -0x8(%rbp), %rax leaq 0x99(%rip), %rcx # 0x7c330 movq %rcx, 0xa8(%rax) popq %rbp retq
my_charset_loader_init_mysys: push rbp mov rbp, rsp mov [rbp+var_8], rdi mov rax, [rbp+var_8] mov byte ptr [rax], 0 mov rax, [rbp+var_8] lea rcx, my_once_alloc_c mov [rax+80h], rcx mov rax, [rbp+var_8] lea rcx, my_malloc_c mov [rax+88h], rcx mov rax, [rbp+var_8] lea rcx, my_realloc_c mov [rax+90h], rcx mov rax, [rbp+var_8] lea rcx, my_free mov [rax+98h], rcx lea rax, my_charset_error_reporter mov rcx, [rax] mov rax, [rbp+var_8] mov [rax+0A0h], rcx mov rax, [rbp+var_8] lea rcx, add_collation mov [rax+0A8h], rcx pop rbp retn
long long my_charset_loader_init_mysys(long long a1) { long long result; // rax *(_BYTE *)a1 = 0; *(_QWORD *)(a1 + 128) = my_once_alloc_c; *(_QWORD *)(a1 + 136) = my_malloc_c; *(_QWORD *)(a1 + 144) = my_realloc_c; *(_QWORD *)(a1 + 152) = my_free; *(_QWORD *)(a1 + 160) = my_charset_error_reporter; result = a1; *(_QWORD *)(a1 + 168) = add_collation; return result; }
my_charset_loader_init_mysys: PUSH RBP MOV RBP,RSP MOV qword ptr [RBP + -0x8],RDI MOV RAX,qword ptr [RBP + -0x8] MOV byte ptr [RAX],0x0 MOV RAX,qword ptr [RBP + -0x8] LEA RCX,[0x17c2a0] MOV qword ptr [RAX + 0x80],RCX MOV RAX,qword ptr [RBP + -0x8] LEA RCX,[0x17c2c0] MOV qword ptr [RAX + 0x88],RCX MOV RAX,qword ptr [RBP + -0x8] LEA RCX,[0x17c2f0] MOV qword ptr [RAX + 0x90],RCX MOV RAX,qword ptr [RBP + -0x8] LEA RCX,[0x18b290] MOV qword ptr [RAX + 0x98],RCX LEA RAX,[0x349ce0] MOV RCX,qword ptr [RAX] MOV RAX,qword ptr [RBP + -0x8] MOV qword ptr [RAX + 0xa0],RCX MOV RAX,qword ptr [RBP + -0x8] LEA RCX,[0x17c330] MOV qword ptr [RAX + 0xa8],RCX POP RBP RET
void my_charset_loader_init_mysys(int1 *param_1) { *param_1 = 0; *(code **)(param_1 + 0x80) = my_once_alloc_c; *(code **)(param_1 + 0x88) = my_malloc_c; *(code **)(param_1 + 0x90) = my_realloc_c; *(code **)(param_1 + 0x98) = my_free; *(int **)(param_1 + 0xa0) = my_charset_error_reporter; *(code **)(param_1 + 0xa8) = add_collation; return; }
6,049
ggml_cpu_init
Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml-cpu/ggml-cpu.c
void ggml_cpu_init(void) { // needed to initialize f16 tables { struct ggml_init_params params = { 0, NULL, false }; struct ggml_context * ctx = ggml_init(params); ggml_free(ctx); } ggml_critical_section_start(); static bool is_first_call = true; if (is_first_call) { // initialize GELU, Quick GELU, SILU and EXP F32 tables { const uint64_t t_start = ggml_time_us(); UNUSED(t_start); for (int i = 0; i < (1 << 16); ++i) { union { uint16_t u16; ggml_fp16_t fp16; } u = {i}; float f = GGML_FP16_TO_FP32(u.fp16); ggml_table_gelu_f16[i] = GGML_FP32_TO_FP16(ggml_gelu_f32(f)); ggml_table_gelu_quick_f16[i] = GGML_FP32_TO_FP16(ggml_gelu_quick_f32(f)); } const uint64_t t_end = ggml_time_us(); UNUSED(t_end); GGML_PRINT_DEBUG("%s: GELU, Quick GELU, SILU and EXP tables initialized in %f ms\n", __func__, (t_end - t_start)/1000.0); } #if defined(__ARM_ARCH) ggml_init_arm_arch_features(); #endif is_first_call = false; } ggml_critical_section_end(); }
O0
c
ggml_cpu_init: pushq %rbp movq %rsp, %rbp subq $0xb0, %rsp leaq -0x18(%rbp), %rdi xorl %esi, %esi movl $0x18, %edx callq 0xd560 leaq -0x18(%rbp), %rax movq (%rax), %rcx movq %rcx, (%rsp) movq 0x8(%rax), %rcx movq %rcx, 0x8(%rsp) movq 0x10(%rax), %rax movq %rax, 0x10(%rsp) callq 0xd9f0 movq %rax, -0x20(%rbp) movq -0x20(%rbp), %rdi callq 0xd180 callq 0xe390 testb $0x1, 0x79242(%rip) # 0x8ab88 je 0x11a2e callq 0xe3b0 movq %rax, -0x28(%rbp) movl $0x0, -0x2c(%rbp) cmpl $0x10000, -0x2c(%rbp) # imm = 0x10000 jge 0x11a1e movw -0x2c(%rbp), %ax movw %ax, -0x2e(%rbp) movzwl -0x2e(%rbp), %edi callq 0xfab0 vmovss %xmm0, -0x34(%rbp) vmovss -0x34(%rbp), %xmm0 callq 0x11f40 vmovaps %xmm0, %xmm1 vxorps %xmm0, %xmm0, %xmm0 vmovaps %xmm0, -0x90(%rbp) vblendps $0x1, %xmm1, %xmm0, %xmm0 # xmm0 = xmm1[0],xmm0[1,2,3] vmovaps %xmm0, -0x50(%rbp) vmovaps -0x50(%rbp), %xmm0 vcvtps2ph $0x0, %xmm0, %xmm0 vpextrw $0x0, %xmm0, -0x36(%rbp) movw -0x36(%rbp), %dx movslq -0x2c(%rbp), %rcx leaq 0x7d2fb(%rip), %rax # 0x8ecc0 movw %dx, (%rax,%rcx,2) vmovss -0x34(%rbp), %xmm0 callq 0x11fc0 vmovaps %xmm0, %xmm1 vmovaps -0x90(%rbp), %xmm0 vblendps $0x1, %xmm1, %xmm0, %xmm0 # xmm0 = xmm1[0],xmm0[1,2,3] vmovaps %xmm0, -0x70(%rbp) vmovaps -0x70(%rbp), %xmm0 vcvtps2ph $0x0, %xmm0, %xmm0 vmovd %xmm0, %eax movw %ax, -0x52(%rbp) movw -0x52(%rbp), %dx movslq -0x2c(%rbp), %rcx leaq 0x9d2b4(%rip), %rax # 0xaecc0 movw %dx, (%rax,%rcx,2) movl -0x2c(%rbp), %eax addl $0x1, %eax movl %eax, -0x2c(%rbp) jmp 0x1195c callq 0xe3b0 movq %rax, -0x78(%rbp) movb $0x0, 0x7915a(%rip) # 0x8ab88 callq 0xe1d0 addq $0xb0, %rsp popq %rbp retq nopl (%rax)
ggml_cpu_init: push rbp mov rbp, rsp sub rsp, 0B0h lea rdi, [rbp+var_18] xor esi, esi mov edx, 18h call _memset lea rax, [rbp+var_18] mov rcx, [rax] mov [rsp+0B0h+var_B0], rcx mov rcx, [rax+8] mov [rsp+0B0h+var_A8], rcx mov rax, [rax+10h] mov [rsp+0B0h+var_A0], rax call _ggml_init mov [rbp+var_20], rax mov rdi, [rbp+var_20] call _ggml_free call _ggml_critical_section_start test cs:ggml_cpu_init_is_first_call, 1 jz loc_11A2E call _ggml_time_us mov [rbp+var_28], rax mov [rbp+var_2C], 0 loc_1195C: cmp [rbp+var_2C], 10000h jge loc_11A1E mov ax, word ptr [rbp+var_2C] mov [rbp+var_2E], ax movzx edi, [rbp+var_2E] call ggml_lookup_fp16_to_fp32 vmovss [rbp+var_34], xmm0 vmovss xmm0, [rbp+var_34] call ggml_gelu_f32 vmovaps xmm1, xmm0 vxorps xmm0, xmm0, xmm0 vmovaps [rbp+var_90], xmm0 vblendps xmm0, xmm0, xmm1, 1 vmovaps [rbp+var_50], xmm0 vmovaps xmm0, [rbp+var_50] vcvtps2ph xmm0, xmm0, 0 vpextrw [rbp+var_36], xmm0, 0 mov dx, [rbp+var_36] movsxd rcx, [rbp+var_2C] lea rax, ggml_table_gelu_f16 mov [rax+rcx*2], dx vmovss xmm0, [rbp+var_34] call ggml_gelu_quick_f32 vmovaps xmm1, xmm0 vmovaps xmm0, [rbp+var_90] vblendps xmm0, xmm0, xmm1, 1 vmovaps [rbp+var_70], xmm0 vmovaps xmm0, [rbp+var_70] vcvtps2ph xmm0, xmm0, 0 vmovd eax, xmm0 mov [rbp+var_52], ax mov dx, [rbp+var_52] movsxd rcx, [rbp+var_2C] lea rax, ggml_table_gelu_quick_f16 mov [rax+rcx*2], dx mov eax, [rbp+var_2C] add eax, 1 mov [rbp+var_2C], eax jmp loc_1195C loc_11A1E: call _ggml_time_us mov [rbp+var_78], rax mov cs:ggml_cpu_init_is_first_call, 0 loc_11A2E: call _ggml_critical_section_end add rsp, 0B0h pop rbp retn
long long ggml_cpu_init() { long long v0; // rdx __int16 v19; // [rsp+7Ah] [rbp-36h] int i; // [rsp+84h] [rbp-2Ch] long long v22; // [rsp+90h] [rbp-20h] _BYTE v23[24]; // [rsp+98h] [rbp-18h] BYREF memset(v23, 0LL, sizeof(v23)); v22 = ggml_init(v23, 0LL, v0); ggml_free(v22); ggml_critical_section_start(); if ( (ggml_cpu_init_is_first_call & 1) != 0 ) { ggml_time_us(); for ( i = 0; i < 0x10000; ++i ) { _XMM0 = ggml_lookup_fp16_to_fp32(i); __asm { vmovss [rbp+var_34], xmm0 vmovss xmm0, [rbp+var_34] } *(double *)&_XMM0 = ggml_gelu_f32(*(double *)&_XMM0); __asm { vmovaps xmm1, xmm0 vxorps xmm0, xmm0, xmm0 vmovaps [rbp+var_90], xmm0 vblendps xmm0, xmm0, xmm1, 1 vmovaps [rbp+var_50], xmm0 vmovaps xmm0, [rbp+var_50] vcvtps2ph xmm0, xmm0, 0 vpextrw [rbp+var_36], xmm0, 0 } ggml_table_gelu_f16[i] = v19; __asm { vmovss xmm0, [rbp+var_34] } *(double *)&_XMM0 = ggml_gelu_quick_f32(*(double *)&_XMM0); __asm { vmovaps xmm1, xmm0 vmovaps xmm0, [rbp+var_90] vblendps xmm0, xmm0, xmm1, 1 vmovaps [rbp+var_70], xmm0 vmovaps xmm0, [rbp+var_70] vcvtps2ph xmm0, xmm0, 0 vmovd eax, xmm0 } ggml_table_gelu_quick_f16[i] = _EAX; } ggml_time_us(); ggml_cpu_init_is_first_call = 0; } return ggml_critical_section_end(); }
ggml_cpu_init: PUSH RBP MOV RBP,RSP SUB RSP,0xb0 LEA RDI,[RBP + -0x18] XOR ESI,ESI MOV EDX,0x18 CALL 0x0010d560 LEA RAX,[RBP + -0x18] 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 0x0010d9f0 MOV qword ptr [RBP + -0x20],RAX MOV RDI,qword ptr [RBP + -0x20] CALL 0x0010d180 CALL 0x0010e390 TEST byte ptr [0x0018ab88],0x1 JZ 0x00111a2e CALL 0x0010e3b0 MOV qword ptr [RBP + -0x28],RAX MOV dword ptr [RBP + -0x2c],0x0 LAB_0011195c: CMP dword ptr [RBP + -0x2c],0x10000 JGE 0x00111a1e MOV AX,word ptr [RBP + -0x2c] MOV word ptr [RBP + -0x2e],AX MOVZX EDI,word ptr [RBP + -0x2e] CALL 0x0010fab0 VMOVSS dword ptr [RBP + -0x34],XMM0 VMOVSS XMM0,dword ptr [RBP + -0x34] CALL 0x00111f40 VMOVAPS XMM1,XMM0 VXORPS XMM0,XMM0,XMM0 VMOVAPS xmmword ptr [RBP + -0x90],XMM0 VBLENDPS XMM0,XMM0,XMM1,0x1 VMOVAPS xmmword ptr [RBP + -0x50],XMM0 VMOVAPS XMM0,xmmword ptr [RBP + -0x50] VCVTPS2PH XMM0,XMM0,0x0 VPEXTRW word ptr [RBP + -0x36],XMM0,0x0 MOV DX,word ptr [RBP + -0x36] MOVSXD RCX,dword ptr [RBP + -0x2c] LEA RAX,[0x18ecc0] MOV word ptr [RAX + RCX*0x2],DX VMOVSS XMM0,dword ptr [RBP + -0x34] CALL 0x00111fc0 VMOVAPS XMM1,XMM0 VMOVAPS XMM0,xmmword ptr [RBP + -0x90] VBLENDPS XMM0,XMM0,XMM1,0x1 VMOVAPS xmmword ptr [RBP + -0x70],XMM0 VMOVAPS XMM0,xmmword ptr [RBP + -0x70] VCVTPS2PH XMM0,XMM0,0x0 VMOVD EAX,XMM0 MOV word ptr [RBP + -0x52],AX MOV DX,word ptr [RBP + -0x52] MOVSXD RCX,dword ptr [RBP + -0x2c] LEA RAX,[0x1aecc0] MOV word ptr [RAX + RCX*0x2],DX MOV EAX,dword ptr [RBP + -0x2c] ADD EAX,0x1 MOV dword ptr [RBP + -0x2c],EAX JMP 0x0011195c LAB_00111a1e: CALL 0x0010e3b0 MOV qword ptr [RBP + -0x78],RAX MOV byte ptr [0x0018ab88],0x0 LAB_00111a2e: CALL 0x0010e1d0 ADD RSP,0xb0 POP RBP RET
void ggml_cpu_init(void) { int8 uVar1; int4 uVar2; int1 auVar3 [16]; int1 auVar4 [64]; int1 auVar5 [64]; int2 local_3e; int local_34; int1 local_20 [24]; int1 extraout_var [56]; int1 extraout_var_00 [56]; memset(local_20,0,0x18); uVar1 = ggml_init(); ggml_free(uVar1); ggml_critical_section_start(); if ((ggml_cpu_init_is_first_call & 1) != 0) { ggml_time_us(); for (local_34 = 0; local_34 < 0x10000; local_34 = local_34 + 1) { uVar2 = ggml_lookup_fp16_to_fp32((int2)local_34); auVar4._0_8_ = ggml_gelu_f32(uVar2); auVar4._8_56_ = extraout_var; auVar3 = vblendps_avx(ZEXT816(0) << 0x40,auVar4._0_16_,1); auVar3 = vcvtps2ph_f16c(auVar3,0); vpextrw_avx(auVar3,0); *(int2 *)(ggml_table_gelu_f16 + (long)local_34 * 2) = local_3e; auVar5._0_8_ = ggml_gelu_quick_f32(uVar2); auVar5._8_56_ = extraout_var_00; auVar3 = vblendps_avx(ZEXT816(0) << 0x40,auVar5._0_16_,1); auVar3 = vcvtps2ph_f16c(auVar3,0); *(short *)(ggml_table_gelu_quick_f16 + (long)local_34 * 2) = auVar3._0_2_; } ggml_time_us(); ggml_cpu_init_is_first_call = 0; } ggml_critical_section_end(); return; }
6,050
ggml_cpu_init
Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml-cpu/ggml-cpu.c
void ggml_cpu_init(void) { // needed to initialize f16 tables { struct ggml_init_params params = { 0, NULL, false }; struct ggml_context * ctx = ggml_init(params); ggml_free(ctx); } ggml_critical_section_start(); static bool is_first_call = true; if (is_first_call) { // initialize GELU, Quick GELU, SILU and EXP F32 tables { const uint64_t t_start = ggml_time_us(); UNUSED(t_start); for (int i = 0; i < (1 << 16); ++i) { union { uint16_t u16; ggml_fp16_t fp16; } u = {i}; float f = GGML_FP16_TO_FP32(u.fp16); ggml_table_gelu_f16[i] = GGML_FP32_TO_FP16(ggml_gelu_f32(f)); ggml_table_gelu_quick_f16[i] = GGML_FP32_TO_FP16(ggml_gelu_quick_f32(f)); } const uint64_t t_end = ggml_time_us(); UNUSED(t_end); GGML_PRINT_DEBUG("%s: GELU, Quick GELU, SILU and EXP tables initialized in %f ms\n", __func__, (t_end - t_start)/1000.0); } #if defined(__ARM_ARCH) ggml_init_arm_arch_features(); #endif is_first_call = false; } ggml_critical_section_end(); }
O3
c
ggml_cpu_init: pushq %r15 pushq %r14 pushq %r12 pushq %rbx subq $0x38, %rsp vxorps %xmm0, %xmm0, %xmm0 vmovaps %xmm0, 0x20(%rsp) movq $0x0, 0x30(%rsp) movq 0x30(%rsp), %rax movq %rax, 0x10(%rsp) vmovdqa 0x20(%rsp), %xmm0 vmovdqu %xmm0, (%rsp) callq 0x85c0 movq %rax, %rdi callq 0x8100 callq 0x8a40 cmpb $0x0, 0x42187(%rip) # 0x4d760 jne 0xb6a9 callq 0x8a60 xorl %ebx, %ebx movq 0x3d97b(%rip), %r14 # 0x48f68 leaq 0x4217c(%rip), %r15 # 0x4d770 leaq 0x62175(%rip), %r12 # 0x6d770 vmovss (%r14,%rbx,2), %xmm3 vmovss %xmm3, 0x18(%rsp) vmulss 0x2aac5(%rip), %xmm3, %xmm0 # 0x360d4 vmovss %xmm0, 0x1c(%rsp) vmulss 0x2aabb(%rip), %xmm3, %xmm0 # 0x360d8 vmulss 0x2aab7(%rip), %xmm3, %xmm1 # 0x360dc vmovss 0x2aab3(%rip), %xmm2 # 0x360e0 vfmadd213ss %xmm2, %xmm3, %xmm1 # xmm1 = (xmm3 * xmm1) + xmm2 vmulss %xmm1, %xmm0, %xmm0 callq 0x88f0 vaddss 0x2aa9d(%rip), %xmm0, %xmm0 # 0x360e0 vmulss 0x1c(%rsp), %xmm0, %xmm0 vcvtps2ph $0x0, %xmm0, %xmm0 vpextrw $0x0, %xmm0, (%rbx,%r15) vmovss 0x18(%rsp), %xmm0 vmulss 0x2aa80(%rip), %xmm0, %xmm0 # 0x360e4 callq 0x8980 vmovss 0x2aa6f(%rip), %xmm1 # 0x360e0 vaddss %xmm1, %xmm0, %xmm0 vdivss %xmm0, %xmm1, %xmm0 vmulss 0x18(%rsp), %xmm0, %xmm0 vcvtps2ph $0x0, %xmm0, %xmm0 vpextrw $0x0, %xmm0, (%rbx,%r12) addq $0x2, %rbx cmpq $0x20000, %rbx # imm = 0x20000 jne 0xb5fb callq 0x8a60 movb $0x1, 0x420b7(%rip) # 0x4d760 addq $0x38, %rsp popq %rbx popq %r12 popq %r14 popq %r15 jmp 0x8960
ggml_cpu_init: push r15 push r14 push r12 push rbx sub rsp, 38h vxorps xmm0, xmm0, xmm0 vmovaps [rsp+58h+var_38], xmm0 mov [rsp+58h+var_28], 0 mov rax, [rsp+58h+var_28] mov [rsp+58h+var_48], rax vmovdqa xmm0, [rsp+58h+var_38] vmovdqu [rsp+58h+var_58], xmm0 call _ggml_init mov rdi, rax call _ggml_free call _ggml_critical_section_start cmp cs:ggml_cpu_init_is_first_call, 0 jnz loc_B6A9 call _ggml_time_us xor ebx, ebx mov r14, cs:ggml_table_f32_f16_ptr lea r15, ggml_table_gelu_f16 lea r12, ggml_table_gelu_quick_f16 loc_B5FB: vmovss xmm3, dword ptr [r14+rbx*2] vmovss [rsp+58h+var_40], xmm3 vmulss xmm0, xmm3, cs:dword_360D4 vmovss [rsp+58h+var_3C], xmm0 vmulss xmm0, xmm3, cs:dword_360D8 vmulss xmm1, xmm3, cs:dword_360DC vmovss xmm2, cs:dword_360E0 vfmadd213ss xmm1, xmm3, xmm2 vmulss xmm0, xmm0, xmm1 call _tanhf vaddss xmm0, xmm0, cs:dword_360E0 vmulss xmm0, xmm0, [rsp+58h+var_3C] vcvtps2ph xmm0, xmm0, 0 vpextrw word ptr [rbx+r15], xmm0, 0 vmovss xmm0, [rsp+58h+var_40] vmulss xmm0, xmm0, cs:dword_360E4 call _expf vmovss xmm1, cs:dword_360E0 vaddss xmm0, xmm0, xmm1 vdivss xmm0, xmm1, xmm0 vmulss xmm0, xmm0, [rsp+58h+var_40] vcvtps2ph xmm0, xmm0, 0 vpextrw word ptr [rbx+r12], xmm0, 0 add rbx, 2 cmp rbx, 20000h jnz loc_B5FB call _ggml_time_us mov cs:ggml_cpu_init_is_first_call, 1 loc_B6A9: add rsp, 38h pop rbx pop r12 pop r14 pop r15 jmp _ggml_critical_section_end
long long ggml_cpu_init(long long a1, long long a2, long long a3, __m128 _XMM0) { long long v6; // rax __asm { vxorps xmm0, xmm0, xmm0 vmovaps [rsp+58h+var_38], xmm0 vmovdqa xmm0, [rsp+58h+var_38] vmovdqu [rsp+58h+var_58], xmm0 } v6 = ggml_init(a1, a2, a3); ggml_free(v6); ggml_critical_section_start(); if ( !ggml_cpu_init_is_first_call ) { ggml_time_us(); _RBX = 0LL; _R14 = &ggml_table_f32_f16; _R15 = &ggml_table_gelu_f16; _R12 = &ggml_table_gelu_quick_f16; do { __asm { vmovss xmm3, dword ptr [r14+rbx*2] vmovss [rsp+58h+var_40], xmm3 vmulss xmm0, xmm3, cs:dword_360D4 vmovss [rsp+58h+var_3C], xmm0 vmulss xmm0, xmm3, cs:dword_360D8 vmulss xmm1, xmm3, cs:dword_360DC vmovss xmm2, cs:dword_360E0 vfmadd213ss xmm1, xmm3, xmm2 vmulss xmm0, xmm0, xmm1 } *(double *)&_XMM0 = tanhf(*(double *)&_XMM0); __asm { vaddss xmm0, xmm0, cs:dword_360E0 vmulss xmm0, xmm0, [rsp+58h+var_3C] vcvtps2ph xmm0, xmm0, 0 vpextrw word ptr [rbx+r15], xmm0, 0 vmovss xmm0, [rsp+58h+var_40] vmulss xmm0, xmm0, cs:dword_360E4 } *(double *)&_XMM0 = expf(*(double *)&_XMM0); __asm { vmovss xmm1, cs:dword_360E0 vaddss xmm0, xmm0, xmm1 vdivss xmm0, xmm1, xmm0 vmulss xmm0, xmm0, [rsp+58h+var_40] vcvtps2ph xmm0, xmm0, 0 vpextrw word ptr [rbx+r12], xmm0, 0 } _RBX += 2LL; } while ( _RBX != 0x20000 ); ggml_time_us(); ggml_cpu_init_is_first_call = 1; } return ggml_critical_section_end(); }
ggml_cpu_init: PUSH R15 PUSH R14 PUSH R12 PUSH RBX SUB RSP,0x38 VXORPS XMM0,XMM0,XMM0 VMOVAPS xmmword ptr [RSP + 0x20],XMM0 MOV qword ptr [RSP + 0x30],0x0 MOV RAX,qword ptr [RSP + 0x30] MOV qword ptr [RSP + 0x10],RAX VMOVDQA XMM0,xmmword ptr [RSP + 0x20] VMOVDQU xmmword ptr [RSP],XMM0 CALL 0x001085c0 MOV RDI,RAX CALL 0x00108100 CALL 0x00108a40 CMP byte ptr [0x0014d760],0x0 JNZ 0x0010b6a9 CALL 0x00108a60 XOR EBX,EBX MOV R14,qword ptr [0x00148f68] LEA R15,[0x14d770] LEA R12,[0x16d770] LAB_0010b5fb: VMOVSS XMM3,dword ptr [R14 + RBX*0x2] VMOVSS dword ptr [RSP + 0x18],XMM3 VMULSS XMM0,XMM3,dword ptr [0x001360d4] VMOVSS dword ptr [RSP + 0x1c],XMM0 VMULSS XMM0,XMM3,dword ptr [0x001360d8] VMULSS XMM1,XMM3,dword ptr [0x001360dc] VMOVSS XMM2,dword ptr [0x001360e0] VFMADD213SS XMM1,XMM3,XMM2 VMULSS XMM0,XMM0,XMM1 CALL 0x001088f0 VADDSS XMM0,XMM0,dword ptr [0x001360e0] VMULSS XMM0,XMM0,dword ptr [RSP + 0x1c] VCVTPS2PH XMM0,XMM0,0x0 VPEXTRW word ptr [RBX + R15*0x1],XMM0,0x0 VMOVSS XMM0,dword ptr [RSP + 0x18] VMULSS XMM0,XMM0,dword ptr [0x001360e4] CALL 0x00108980 VMOVSS XMM1,dword ptr [0x001360e0] VADDSS XMM0,XMM0,XMM1 VDIVSS XMM0,XMM1,XMM0 VMULSS XMM0,XMM0,dword ptr [RSP + 0x18] VCVTPS2PH XMM0,XMM0,0x0 VPEXTRW word ptr [RBX + R12*0x1],XMM0,0x0 ADD RBX,0x2 CMP RBX,0x20000 JNZ 0x0010b5fb CALL 0x00108a60 MOV byte ptr [0x0014d760],0x1 LAB_0010b6a9: ADD RSP,0x38 POP RBX POP R12 POP R14 POP R15 JMP 0x00108960
void ggml_cpu_init(void) { float fVar1; int *puVar2; int8 uVar3; long lVar4; float fVar5; float fVar6; int1 auVar7 [16]; uVar3 = ggml_init(); ggml_free(uVar3); ggml_critical_section_start(); if (ggml_cpu_init_is_first_call == '\0') { ggml_time_us(); puVar2 = PTR_ggml_table_f32_f16_00148f68; lVar4 = 0; do { fVar1 = *(float *)(puVar2 + lVar4 * 2); fVar6 = fVar1 * DAT_001360d4; auVar7 = vfmadd213ss_fma(ZEXT416((uint)(fVar1 * DAT_001360dc)),ZEXT416((uint)fVar1), ZEXT416((uint)DAT_001360e0)); fVar5 = tanhf(fVar1 * DAT_001360d8 * auVar7._0_4_); auVar7 = vcvtps2ph_f16c(ZEXT416((uint)((fVar5 + DAT_001360e0) * fVar6)),0); vpextrw_avx(auVar7,0); fVar6 = expf(fVar1 * DAT_001360e4); auVar7 = vcvtps2ph_f16c(ZEXT416((uint)((DAT_001360e0 / (fVar6 + DAT_001360e0)) * fVar1)),0); vpextrw_avx(auVar7,0); lVar4 = lVar4 + 2; } while (lVar4 != 0x20000); ggml_time_us(); ggml_cpu_init_is_first_call = '\x01'; } ggml_critical_section_end(); return; }
6,051
CLI::ValidationError::ValidationError(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>)
MikePodsytnik[P]TCRtrie/build_O2/_deps/cli11-src/include/CLI/Error.hpp
explicit ValidationError(std::string name, std::string msg) : ValidationError(name + ": " + msg) {}
O2
cpp
CLI::ValidationError::ValidationError(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>): pushq %r15 pushq %r14 pushq %rbx subq $0x40, %rsp movq %rdx, %r14 movq %rdi, %rbx leaq 0x1a3e1(%rip), %rdx # 0x29c1f leaq 0x20(%rsp), %r15 movq %r15, %rdi callq 0x105fb movq %rsp, %rdi movq %r15, %rsi movq %r14, %rdx callq 0xa194 movq %rsp, %rsi movq %rbx, %rdi callq 0x213fc movq %rsp, %rdi callq 0x7860 leaq 0x20(%rsp), %rdi callq 0x7860 addq $0x40, %rsp popq %rbx popq %r14 popq %r15 retq movq %rax, %rbx movq %rsp, %rdi callq 0x7860 jmp 0xf890 movq %rax, %rbx leaq 0x20(%rsp), %rdi callq 0x7860 movq %rbx, %rdi callq 0x7770
_ZN3CLI15ValidationErrorC2ENSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES6_: push r15 push r14 push rbx sub rsp, 40h mov r14, rdx mov rbx, rdi lea rdx, aOnlyPartiallyS+19h; ": " lea r15, [rsp+58h+var_38] mov rdi, r15 call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EERKS8_PKS5_; std::operator+<char>(std::string const&,char const*) mov rdi, rsp mov rsi, r15 mov rdx, r14 call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEOS8_RKS8_; std::operator+<char>(std::string&&,std::string const&) mov rsi, rsp mov rdi, rbx call _ZN3CLI15ValidationErrorC2ENSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; CLI::ValidationError::ValidationError(std::string) mov rdi, rsp; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() lea rdi, [rsp+58h+var_38]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() add rsp, 40h pop rbx pop r14 pop r15 retn mov rbx, rax mov rdi, rsp; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() jmp short loc_F890 mov rbx, rax loc_F890: lea rdi, [rsp+arg_18]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() mov rdi, rbx call __Unwind_Resume
void CLI::ValidationError::ValidationError(int a1, long long a2, long long a3) { int v4; // edx int v5; // ecx int v6; // r8d int v7; // r9d _BYTE v8[32]; // [rsp+0h] [rbp-58h] BYREF _BYTE v9[56]; // [rsp+20h] [rbp-38h] BYREF std::operator+<char>(v9, a2, ": "); std::operator+<char>((long long)v8, (long long)v9, a3); CLI::ValidationError::ValidationError(a1, (unsigned int)v8, v4, v5, v6, v7); std::string::~string(v8); std::string::~string(v9); }
ValidationError: PUSH R15 PUSH R14 PUSH RBX SUB RSP,0x40 MOV R14,RDX MOV RBX,RDI LEA RDX,[0x129c1f] LEA R15,[RSP + 0x20] MOV RDI,R15 CALL 0x001105fb LAB_0010f84b: MOV RDI,RSP MOV RSI,R15 MOV RDX,R14 CALL 0x0010a194 LAB_0010f859: MOV RSI,RSP MOV RDI,RBX CALL 0x001213fc LAB_0010f864: MOV RDI,RSP CALL 0x00107860 LEA RDI,[RSP + 0x20] CALL 0x00107860 ADD RSP,0x40 POP RBX POP R14 POP R15 RET
/* CLI::ValidationError::ValidationError(std::__cxx11::string, std::__cxx11::string) */ void __thiscall CLI::ValidationError::ValidationError(ValidationError *this,char *param_2) { string asStack_58 [32]; string local_38 [32]; std::operator+(local_38,param_2); /* try { // try from 0010f84b to 0010f858 has its CatchHandler @ 0010f88d */ std::operator+(asStack_58,local_38); /* try { // try from 0010f859 to 0010f863 has its CatchHandler @ 0010f880 */ ValidationError(this,asStack_58); std::__cxx11::string::~string(asStack_58); std::__cxx11::string::~string(local_38); return; }
6,052
google::protobuf::compiler::cpp::HasRepeatedFields(google::protobuf::Descriptor const*)
aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/compiler/cpp/helpers.cc
static bool HasRepeatedFields(const Descriptor* descriptor) { for (int i = 0; i < descriptor->field_count(); ++i) { if (descriptor->field(i)->label() == FieldDescriptor::LABEL_REPEATED) { return true; } } for (int i = 0; i < descriptor->nested_type_count(); ++i) { if (HasRepeatedFields(descriptor->nested_type(i))) return true; } return false; }
O0
cpp
google::protobuf::compiler::cpp::HasRepeatedFields(google::protobuf::Descriptor const*): subq $0x28, %rsp movq %rdi, 0x18(%rsp) movl $0x0, 0x14(%rsp) movl 0x14(%rsp), %eax movl %eax, 0xc(%rsp) movq 0x18(%rsp), %rdi callq 0x3ca80 movl %eax, %ecx movl 0xc(%rsp), %eax cmpl %ecx, %eax jge 0x551fe movq 0x18(%rsp), %rdi movl 0x14(%rsp), %esi callq 0x3ca90 movq %rax, %rdi callq 0x3cbf0 cmpl $0x3, %eax jne 0x551ef movb $0x1, 0x27(%rsp) jmp 0x55259 jmp 0x551f1 movl 0x14(%rsp), %eax addl $0x1, %eax movl %eax, 0x14(%rsp) jmp 0x551b1 movl $0x0, 0x10(%rsp) movl 0x10(%rsp), %eax movl %eax, 0x8(%rsp) movq 0x18(%rsp), %rdi callq 0x3cb40 movl %eax, %ecx movl 0x8(%rsp), %eax cmpl %ecx, %eax jge 0x55254 movq 0x18(%rsp), %rdi movl 0x10(%rsp), %esi callq 0x3cb50 movq %rax, %rdi callq 0x551a0 testb $0x1, %al jne 0x5523e jmp 0x55245 movb $0x1, 0x27(%rsp) jmp 0x55259 jmp 0x55247 movl 0x10(%rsp), %eax addl $0x1, %eax movl %eax, 0x10(%rsp) jmp 0x55206 movb $0x0, 0x27(%rsp) movb 0x27(%rsp), %al andb $0x1, %al addq $0x28, %rsp retq nopw %cs:(%rax,%rax)
_ZN6google8protobuf8compiler3cppL17HasRepeatedFieldsEPKNS0_10DescriptorE: sub rsp, 28h mov [rsp+28h+var_10], rdi mov dword ptr [rsp+28h+var_18+4], 0 loc_551B1: mov eax, dword ptr [rsp+28h+var_18+4] mov [rsp+28h+var_1C], eax mov rdi, [rsp+28h+var_10]; this call _ZNK6google8protobuf10Descriptor11field_countEv; google::protobuf::Descriptor::field_count(void) mov ecx, eax mov eax, [rsp+28h+var_1C] cmp eax, ecx jge short loc_551FE mov rdi, [rsp+28h+var_10]; this mov esi, dword ptr [rsp+28h+var_18+4]; int call _ZNK6google8protobuf10Descriptor5fieldEi; google::protobuf::Descriptor::field(int) mov rdi, rax; this call _ZNK6google8protobuf15FieldDescriptor5labelEv; google::protobuf::FieldDescriptor::label(void) cmp eax, 3 jnz short loc_551EF mov [rsp+28h+var_1], 1 jmp short loc_55259 loc_551EF: jmp short $+2 loc_551F1: mov eax, dword ptr [rsp+28h+var_18+4] add eax, 1 mov dword ptr [rsp+28h+var_18+4], eax jmp short loc_551B1 loc_551FE: mov dword ptr [rsp+28h+var_18], 0 loc_55206: mov eax, dword ptr [rsp+28h+var_18] mov [rsp+28h+var_20], eax mov rdi, [rsp+28h+var_10]; this call _ZNK6google8protobuf10Descriptor17nested_type_countEv; google::protobuf::Descriptor::nested_type_count(void) mov ecx, eax mov eax, [rsp+28h+var_20] cmp eax, ecx jge short loc_55254 mov rdi, [rsp+28h+var_10]; this mov esi, dword ptr [rsp+28h+var_18]; google::protobuf::Descriptor * call _ZNK6google8protobuf10Descriptor11nested_typeEi; google::protobuf::Descriptor::nested_type(int) mov rdi, rax; this call _ZN6google8protobuf8compiler3cppL17HasRepeatedFieldsEPKNS0_10DescriptorE; google::protobuf::compiler::cpp::HasRepeatedFields(google::protobuf::Descriptor const*) test al, 1 jnz short loc_5523E jmp short loc_55245 loc_5523E: mov [rsp+28h+var_1], 1 jmp short loc_55259 loc_55245: jmp short $+2 loc_55247: mov eax, dword ptr [rsp+28h+var_18] add eax, 1 mov dword ptr [rsp+28h+var_18], eax jmp short loc_55206 loc_55254: mov [rsp+28h+var_1], 0 loc_55259: mov al, [rsp+28h+var_1] and al, 1 add rsp, 28h retn
char google::protobuf::compiler::cpp::HasRepeatedFields( google::protobuf::compiler::cpp *this, const google::protobuf::Descriptor *a2) { google::protobuf::FieldDescriptor *v2; // rax google::protobuf::compiler::cpp *v3; // rax int j; // [rsp+10h] [rbp-18h] int i; // [rsp+14h] [rbp-14h] for ( i = 0; i < (int)google::protobuf::Descriptor::field_count(this); ++i ) { v2 = (google::protobuf::FieldDescriptor *)google::protobuf::Descriptor::field(this, i); if ( (unsigned int)google::protobuf::FieldDescriptor::label(v2) == 3 ) return 1; } for ( j = 0; j < (int)google::protobuf::Descriptor::nested_type_count(this); ++j ) { v3 = (google::protobuf::compiler::cpp *)google::protobuf::Descriptor::nested_type(this, j); if ( (google::protobuf::compiler::cpp::HasRepeatedFields(v3, (const google::protobuf::Descriptor *)(unsigned int)j) & 1) != 0 ) return 1; } return 0; }
HasRepeatedFields: SUB RSP,0x28 MOV qword ptr [RSP + 0x18],RDI MOV dword ptr [RSP + 0x14],0x0 LAB_001551b1: MOV EAX,dword ptr [RSP + 0x14] MOV dword ptr [RSP + 0xc],EAX MOV RDI,qword ptr [RSP + 0x18] CALL 0x0013ca80 MOV ECX,EAX MOV EAX,dword ptr [RSP + 0xc] CMP EAX,ECX JGE 0x001551fe MOV RDI,qword ptr [RSP + 0x18] MOV ESI,dword ptr [RSP + 0x14] CALL 0x0013ca90 MOV RDI,RAX CALL 0x0013cbf0 CMP EAX,0x3 JNZ 0x001551ef MOV byte ptr [RSP + 0x27],0x1 JMP 0x00155259 LAB_001551ef: JMP 0x001551f1 LAB_001551f1: MOV EAX,dword ptr [RSP + 0x14] ADD EAX,0x1 MOV dword ptr [RSP + 0x14],EAX JMP 0x001551b1 LAB_001551fe: MOV dword ptr [RSP + 0x10],0x0 LAB_00155206: MOV EAX,dword ptr [RSP + 0x10] MOV dword ptr [RSP + 0x8],EAX MOV RDI,qword ptr [RSP + 0x18] CALL 0x0013cb40 MOV ECX,EAX MOV EAX,dword ptr [RSP + 0x8] CMP EAX,ECX JGE 0x00155254 MOV RDI,qword ptr [RSP + 0x18] MOV ESI,dword ptr [RSP + 0x10] CALL 0x0013cb50 MOV RDI,RAX CALL 0x001551a0 TEST AL,0x1 JNZ 0x0015523e JMP 0x00155245 LAB_0015523e: MOV byte ptr [RSP + 0x27],0x1 JMP 0x00155259 LAB_00155245: JMP 0x00155247 LAB_00155247: MOV EAX,dword ptr [RSP + 0x10] ADD EAX,0x1 MOV dword ptr [RSP + 0x10],EAX JMP 0x00155206 LAB_00155254: MOV byte ptr [RSP + 0x27],0x0 LAB_00155259: MOV AL,byte ptr [RSP + 0x27] AND AL,0x1 ADD RSP,0x28 RET
/* google::protobuf::compiler::cpp::HasRepeatedFields(google::protobuf::Descriptor const*) */ int1 google::protobuf::compiler::cpp::HasRepeatedFields(Descriptor *param_1) { int iVar1; FieldDescriptor *this; Descriptor *pDVar2; ulong uVar3; int local_18; int local_14; local_14 = 0; while( true ) { iVar1 = Descriptor::field_count(param_1); if (iVar1 <= local_14) { local_18 = 0; while( true ) { iVar1 = Descriptor::nested_type_count(param_1); if (iVar1 <= local_18) { return 0; } pDVar2 = (Descriptor *)Descriptor::nested_type(param_1,local_18); uVar3 = HasRepeatedFields(pDVar2); if ((uVar3 & 1) != 0) break; local_18 = local_18 + 1; } return 1; } this = (FieldDescriptor *)Descriptor::field(param_1,local_14); iVar1 = FieldDescriptor::label(this); if (iVar1 == 3) break; local_14 = local_14 + 1; } return 1; }
6,053
blst_fp12_finalverify
corpus-core[P]colibri-stateless/build_O3/_deps/blst-src/src/aggregate.c
int blst_fp12_finalverify(const vec384fp12 GT1, const vec384fp12 GT2) { vec384fp12 GT; vec_copy(GT, GT1, sizeof(GT)); conjugate_fp12(GT); mul_fp12(GT, GT, GT2); final_exp(GT, GT); /* return GT==1 */ return (int)(vec_is_equal(GT[0][0], BLS12_381_Rx.p2, sizeof(GT[0][0])) & vec_is_zero(GT[0][1], sizeof(GT) - sizeof(GT[0][0]))); }
O3
c
blst_fp12_finalverify: pushq %rbp movq %rsp, %rbp pushq %r14 pushq %rbx subq $0x240, %rsp # imm = 0x240 movq %rsi, %r14 movq %rdi, %rsi leaq -0x250(%rbp), %rbx movl $0x240, %edx # imm = 0x240 movq %rbx, %rdi callq 0x5060 leaq -0x130(%rbp), %rdi movq %rdi, %rsi callq 0x279e1 movq %rbx, %rdi movq %rbx, %rsi movq %r14, %rdx callq 0x1ee00 movq %rbx, %rdi movq %rbx, %rsi callq 0x20356 leaq 0x1e669(%rip), %rsi # 0x3fb48 movl $0x60, %edx movq %rbx, %rdi callq 0x2ff80 movq %rax, %rbx leaq -0x1f0(%rbp), %rdi movl $0x1e0, %esi # imm = 0x1E0 callq 0x2ff40 andl %ebx, %eax addq $0x240, %rsp # imm = 0x240 popq %rbx popq %r14 popq %rbp retq
blst_fp12_finalverify: push rbp mov rbp, rsp push r14 push rbx sub rsp, 240h mov r14, rsi mov rsi, rdi lea rbx, [rbp+var_250] mov edx, 240h mov rdi, rbx call _memcpy lea rdi, [rbp+var_130] mov rsi, rdi call neg_fp6 mov rdi, rbx mov rsi, rbx mov rdx, r14 call mul_fp12 mov rdi, rbx mov rsi, rbx call final_exp lea rsi, BLS12_381_Rx mov edx, 60h ; '`' mov rdi, rbx call vec_is_equal_16x mov rbx, rax lea rdi, [rbp+var_1F0] mov esi, 1E0h call vec_is_zero_16x and eax, ebx add rsp, 240h pop rbx pop r14 pop rbp retn
long long blst_fp12_finalverify(long long a1, long long a2) { int is_equal_16x; // ebx _BYTE v4[96]; // [rsp+0h] [rbp-250h] BYREF _BYTE v5[192]; // [rsp+60h] [rbp-1F0h] BYREF _BYTE v6[304]; // [rsp+120h] [rbp-130h] BYREF memcpy(v4, a1, 576LL); neg_fp6(v6, v6); mul_fp12((long long)v4, (long long)v4, a2); final_exp((long long)v4, (long long)v4); is_equal_16x = vec_is_equal_16x(v4, &BLS12_381_Rx, 96LL); return is_equal_16x & (unsigned int)vec_is_zero_16x(v5, 480LL); }
blst_fp12_finalverify: PUSH RBP MOV RBP,RSP PUSH R14 PUSH RBX SUB RSP,0x240 MOV R14,RSI MOV RSI,RDI LEA RBX,[RBP + -0x250] MOV EDX,0x240 MOV RDI,RBX CALL 0x00105060 LEA RDI,[RBP + -0x130] MOV RSI,RDI CALL 0x001279e1 MOV RDI,RBX MOV RSI,RBX MOV RDX,R14 CALL 0x0011ee00 MOV RDI,RBX MOV RSI,RBX CALL 0x00120356 LEA RSI,[0x13fb48] MOV EDX,0x60 MOV RDI,RBX CALL 0x0012ff80 MOV RBX,RAX LEA RDI,[RBP + -0x1f0] MOV ESI,0x1e0 CALL 0x0012ff40 AND EAX,EBX ADD RSP,0x240 POP RBX POP R14 POP RBP RET
uint blst_fp12_finalverify(void *param_1,int8 param_2) { uint uVar1; uint uVar2; int1 local_258 [96]; int1 local_1f8 [192]; int1 local_138 [288]; memcpy(local_258,param_1,0x240); neg_fp6(local_138,local_138); mul_fp12(local_258,local_258,param_2); final_exp(local_258,local_258); uVar1 = vec_is_equal_16x(local_258,&BLS12_381_Rx,0x60); uVar2 = vec_is_zero_16x(local_1f8,0x1e0); return uVar2 & uVar1; }
6,054
Appender::getLogLevelString(LogLevel)
SylCore-WoTLK/src/common/Logging/Appender.cpp
char const* Appender::getLogLevelString(LogLevel level) { switch (level) { case LOG_LEVEL_FATAL: return "FATAL"; case LOG_LEVEL_ERROR: return "ERROR"; case LOG_LEVEL_WARN: return "WARN"; case LOG_LEVEL_INFO: return "INFO"; case LOG_LEVEL_DEBUG: return "DEBUG"; case LOG_LEVEL_TRACE: return "TRACE"; default: return "DISABLED"; } }
O3
cpp
Appender::getLogLevelString(LogLevel): decb %dil cmpb $0x5, %dil ja 0xb2c5b movzbl %dil, %eax leaq 0xb4dca(%rip), %rcx # 0x167a20 movq (%rcx,%rax,8), %rax retq leaq 0x5cc58(%rip), %rax # 0x10f8ba retq nop
_ZN8Appender17getLogLevelStringE8LogLevel: dec dil cmp dil, 5 ja short loc_B2C5B movzx eax, dil lea rcx, off_167A20; "FATAL" mov rax, [rcx+rax*8] retn loc_B2C5B: lea rax, aLogLevelDisabl+0Ah; "DISABLED" retn
char * Appender::getLogLevelString(char a1) { unsigned __int8 v1; // di v1 = a1 - 1; if ( v1 > 5u ) return "DISABLED"; else return (char *)*(&off_167A20 + v1); }
getLogLevelString: DEC DIL CMP DIL,0x5 JA 0x001b2c5b MOVZX EAX,DIL LEA RCX,[0x267a20] MOV RAX,qword ptr [RCX + RAX*0x8] RET LAB_001b2c5b: LEA RAX,[0x20f8ba] RET
/* Appender::getLogLevelString(LogLevel) */ char * Appender::getLogLevelString(char param_1) { if ((byte)(param_1 - 1U) < 6) { return (&PTR_s_FATAL_00267a20)[(byte)(param_1 - 1U)]; } return "DISABLED"; }
6,055
mi_test_if_changed
eloqsql/storage/myisam/mi_locking.c
int _mi_test_if_changed(register MI_INFO *info) { MYISAM_SHARE *share=info->s; if (share->state.process != share->last_process || share->state.unique != info->last_unique || share->state.update_count != info->last_loop) { /* Keyfile has changed */ DBUG_PRINT("info",("index file changed")); if (share->state.process != share->this_process) (void) flush_key_blocks(share->key_cache, share->kfile, &share->dirty_part_map, FLUSH_RELEASE); share->last_process=share->state.process; info->last_unique= share->state.unique; info->last_loop= share->state.update_count; info->update|= HA_STATE_WRITTEN; /* Must use file on next */ info->data_changed= 1; /* For mi_is_changed */ return 1; } return (!(info->update & HA_STATE_AKTIV) || (info->update & (HA_STATE_WRITTEN | HA_STATE_DELETED | HA_STATE_KEY_CHANGED))); }
O3
c
mi_test_if_changed: pushq %rbp movq %rsp, %rbp pushq %r14 pushq %rbx movq %rdi, %rbx movq (%rdi), %r14 movq 0x68(%r14), %rax cmpq 0x308(%r14), %rax jne 0x7c667 movq 0x70(%r14), %rcx cmpq 0x158(%rbx), %rcx jne 0x7c667 movq 0x78(%r14), %rcx cmpq 0x168(%rbx), %rcx jne 0x7c667 movl $0x8e, %ecx andl 0x1d0(%rbx), %ecx xorl %eax, %eax cmpl $0x2, %ecx setne %al jmp 0x7c6c6 cmpq 0x300(%r14), %rax je 0x7c693 movq 0x278(%r14), %rdi movl 0x350(%r14), %esi leaq 0x280(%r14), %rdx movl $0x1, %ecx callq 0x98709 movq 0x68(%r14), %rax movq %rax, 0x308(%r14) movq 0x70(%r14), %rax movq %rax, 0x158(%rbx) movq 0x78(%r14), %rax movq %rax, 0x168(%rbx) orb $0x4, 0x1d0(%rbx) movl $0x1, 0x1fc(%rbx) movl $0x1, %eax popq %rbx popq %r14 popq %rbp retq
_mi_test_if_changed: push rbp mov rbp, rsp push r14 push rbx mov rbx, rdi mov r14, [rdi] mov rax, [r14+68h] cmp rax, [r14+308h] jnz short loc_7C667 mov rcx, [r14+70h] cmp rcx, [rbx+158h] jnz short loc_7C667 mov rcx, [r14+78h] cmp rcx, [rbx+168h] jnz short loc_7C667 mov ecx, 8Eh and ecx, [rbx+1D0h] xor eax, eax cmp ecx, 2 setnz al jmp short loc_7C6C6 loc_7C667: cmp rax, [r14+300h] jz short loc_7C693 mov rdi, [r14+278h] mov esi, [r14+350h] lea rdx, [r14+280h] mov ecx, 1 call flush_key_blocks mov rax, [r14+68h] loc_7C693: mov [r14+308h], rax mov rax, [r14+70h] mov [rbx+158h], rax mov rax, [r14+78h] mov [rbx+168h], rax or byte ptr [rbx+1D0h], 4 mov dword ptr [rbx+1FCh], 1 mov eax, 1 loc_7C6C6: pop rbx pop r14 pop rbp retn
_BOOL8 mi_test_if_changed(long long *a1) { long long v1; // r14 long long v2; // rax v1 = *a1; v2 = *(_QWORD *)(*a1 + 104); if ( v2 == *(_QWORD *)(*a1 + 776) && *(_QWORD *)(v1 + 112) == a1[43] && *(_QWORD *)(v1 + 120) == a1[45] ) return (a1[58] & 0x8E) != 2; if ( v2 != *(_QWORD *)(v1 + 768) ) { flush_key_blocks(*(_QWORD *)(v1 + 632), *(unsigned int *)(v1 + 848), v1 + 640, 1LL); v2 = *(_QWORD *)(v1 + 104); } *(_QWORD *)(v1 + 776) = v2; a1[43] = *(_QWORD *)(v1 + 112); a1[45] = *(_QWORD *)(v1 + 120); *((_BYTE *)a1 + 464) |= 4u; *((_DWORD *)a1 + 127) = 1; return 1LL; }
_mi_test_if_changed: PUSH RBP MOV RBP,RSP PUSH R14 PUSH RBX MOV RBX,RDI MOV R14,qword ptr [RDI] MOV RAX,qword ptr [R14 + 0x68] CMP RAX,qword ptr [R14 + 0x308] JNZ 0x0017c667 MOV RCX,qword ptr [R14 + 0x70] CMP RCX,qword ptr [RBX + 0x158] JNZ 0x0017c667 MOV RCX,qword ptr [R14 + 0x78] CMP RCX,qword ptr [RBX + 0x168] JNZ 0x0017c667 MOV ECX,0x8e AND ECX,dword ptr [RBX + 0x1d0] XOR EAX,EAX CMP ECX,0x2 SETNZ AL JMP 0x0017c6c6 LAB_0017c667: CMP RAX,qword ptr [R14 + 0x300] JZ 0x0017c693 MOV RDI,qword ptr [R14 + 0x278] MOV ESI,dword ptr [R14 + 0x350] LEA RDX,[R14 + 0x280] MOV ECX,0x1 CALL 0x00198709 MOV RAX,qword ptr [R14 + 0x68] LAB_0017c693: MOV qword ptr [R14 + 0x308],RAX MOV RAX,qword ptr [R14 + 0x70] MOV qword ptr [RBX + 0x158],RAX MOV RAX,qword ptr [R14 + 0x78] MOV qword ptr [RBX + 0x168],RAX OR byte ptr [RBX + 0x1d0],0x4 MOV dword ptr [RBX + 0x1fc],0x1 MOV EAX,0x1 LAB_0017c6c6: POP RBX POP R14 POP RBP RET
bool _mi_test_if_changed(long *param_1) { long lVar1; long lVar2; bool bVar3; lVar1 = *param_1; lVar2 = *(long *)(lVar1 + 0x68); if (((lVar2 == *(long *)(lVar1 + 0x308)) && (*(long *)(lVar1 + 0x70) == param_1[0x2b])) && (*(long *)(lVar1 + 0x78) == param_1[0x2d])) { bVar3 = (*(uint *)(param_1 + 0x3a) & 0x8e) != 2; } else { if (lVar2 != *(long *)(lVar1 + 0x300)) { flush_key_blocks(*(int8 *)(lVar1 + 0x278),*(int4 *)(lVar1 + 0x350),lVar1 + 0x280,1 ); lVar2 = *(long *)(lVar1 + 0x68); } *(long *)(lVar1 + 0x308) = lVar2; param_1[0x2b] = *(long *)(lVar1 + 0x70); param_1[0x2d] = *(long *)(lVar1 + 0x78); *(byte *)(param_1 + 0x3a) = *(byte *)(param_1 + 0x3a) | 4; *(int4 *)((long)param_1 + 0x1fc) = 1; bVar3 = true; } return bVar3; }
6,056
cli::group::match_exclusive(cli::match_state&) const
msxemulator/build_O0/_deps/picotool-src/cli.h
match_type match_exclusive(match_state& ms) const { vector<match_state> matches(elements.size(), ms); vector<match_type> types(elements.size(), match_type::no_match); int elements_with_errors = 0; int elements_with_no_match = 0; int error_at = -1; int error_match_count = -1; for (size_t i=0;i<elements.size();i++) { match_type t; matches[i].apply_settings_from(); do { t = elements[i]->match(matches[i]); assert(t != match_type::not_yet); if (t != match_type::no_match) { types[i] = t; } } while (t == match_type::match); matches[i].save_settings_into(); if (types[i] == match_type::match) { ms = matches[i]; return match_type::match; } else if (types[i] == match_type::error) { if (matches[i].match_count > error_match_count) { error_match_count = matches[i].match_count; error_at = i; } elements_with_errors++; } else if (types[i] == match_type::no_match) { elements_with_no_match++; } } if (elements_with_no_match && (!elements_with_errors || no_match_beats_error())) { return match_type::no_match; } if (elements_with_errors) { ms = matches[error_at]; ms.apply_settings_from(); // todo perhaps want to apply the previous settings instead? return match_type::error; } else { // back out any modified settings ms.apply_settings_from(); return match_type::no_match; } }
O0
c
cli::group::match_exclusive(cli::match_state&) const: subq $0xd8, %rsp movq %rdi, 0xc8(%rsp) movq %rsi, 0xc0(%rsp) movq 0xc8(%rsp), %rdi movq %rdi, 0x30(%rsp) addq $0xe0, %rdi callq 0x7b750 movq %rax, 0x38(%rsp) movq 0xc0(%rsp), %rax movq %rax, 0x40(%rsp) leaq 0xa7(%rsp), %rdi movq %rdi, 0x48(%rsp) callq 0x7fe40 movq 0x38(%rsp), %rsi movq 0x40(%rsp), %rdx movq 0x48(%rsp), %rcx leaq 0xa8(%rsp), %rdi callq 0x7fe50 jmp 0x7c502 leaq 0xa7(%rsp), %rdi callq 0x7fed0 movq 0x30(%rsp), %rdi addq $0xe0, %rdi callq 0x7b750 movq %rax, 0x20(%rsp) movl $0x3, 0x74(%rsp) leaq 0x73(%rsp), %rdi movq %rdi, 0x28(%rsp) callq 0x7fee0 movq 0x20(%rsp), %rsi movq 0x28(%rsp), %rcx leaq 0x78(%rsp), %rdi leaq 0x74(%rsp), %rdx callq 0x7fef0 jmp 0x7c557 leaq 0x73(%rsp), %rdi callq 0x7ff70 movl $0x0, 0x6c(%rsp) movl $0x0, 0x68(%rsp) movl $0xffffffff, 0x64(%rsp) # imm = 0xFFFFFFFF movl $0xffffffff, 0x60(%rsp) # imm = 0xFFFFFFFF movq $0x0, 0x58(%rsp) movq 0x30(%rsp), %rdi movq 0x58(%rsp), %rax movq %rax, 0x18(%rsp) addq $0xe0, %rdi callq 0x7b750 movq %rax, %rcx movq 0x18(%rsp), %rax cmpq %rcx, %rax jae 0x7c7cd movq 0x58(%rsp), %rsi leaq 0xa8(%rsp), %rdi callq 0x7ff80 movq %rax, %rdi callq 0x7c9e0 jmp 0x7c5d2 jmp 0x7c5d4 movq 0x30(%rsp), %rdi addq $0xe0, %rdi movq 0x58(%rsp), %rsi callq 0x7ca00 movq %rax, %rdi callq 0x7c8c0 movq %rax, 0x8(%rsp) movq 0x58(%rsp), %rsi leaq 0xa8(%rsp), %rdi callq 0x7ff80 movq 0x8(%rsp), %rdi movq %rax, %rsi movq (%rdi), %rax movq 0x10(%rax), %rax callq *%rax movl %eax, 0x14(%rsp) jmp 0x7c620 movl 0x14(%rsp), %eax movl %eax, 0x54(%rsp) cmpl $0x3, 0x54(%rsp) je 0x7c6be movl 0x54(%rsp), %eax movl %eax, 0x4(%rsp) movq 0x58(%rsp), %rsi leaq 0x78(%rsp), %rdi callq 0x7ffa0 movl 0x4(%rsp), %ecx movl %ecx, (%rax) jmp 0x7c6be movq %rax, %rcx movl %edx, %eax movq %rcx, 0x98(%rsp) movl %eax, 0x94(%rsp) leaq 0xa7(%rsp), %rdi callq 0x7fed0 jmp 0x7c8ae movq %rax, %rcx movl %edx, %eax movq %rcx, 0x98(%rsp) movl %eax, 0x94(%rsp) leaq 0x73(%rsp), %rdi callq 0x7ff70 jmp 0x7c8a1 movq %rax, %rcx movl %edx, %eax movq %rcx, 0x98(%rsp) movl %eax, 0x94(%rsp) leaq 0x78(%rsp), %rdi callq 0x7ffe0 jmp 0x7c8a1 jmp 0x7c6c0 cmpl $0x1, 0x54(%rsp) je 0x7c5d4 movq 0x58(%rsp), %rsi leaq 0xa8(%rsp), %rdi callq 0x7ff80 movq %rax, %rdi callq 0x7ca20 jmp 0x7c6e7 movq 0x58(%rsp), %rsi leaq 0x78(%rsp), %rdi callq 0x7ffa0 cmpl $0x1, (%rax) jne 0x7c737 movq 0x58(%rsp), %rsi leaq 0xa8(%rsp), %rdi callq 0x7ff80 movq %rax, %rsi movq 0xc0(%rsp), %rdi callq 0x7ca40 jmp 0x7c71f movl $0x1, 0xd4(%rsp) movl $0x1, 0x50(%rsp) jmp 0x7c87b movq 0x58(%rsp), %rsi leaq 0x78(%rsp), %rdi callq 0x7ffa0 cmpl $0x2, (%rax) jne 0x7c795 movq 0x58(%rsp), %rsi leaq 0xa8(%rsp), %rdi callq 0x7ff80 movl 0x38(%rax), %eax cmpl 0x60(%rsp), %eax jle 0x7c788 movq 0x58(%rsp), %rsi leaq 0xa8(%rsp), %rdi callq 0x7ff80 movl 0x38(%rax), %eax movl %eax, 0x60(%rsp) movq 0x58(%rsp), %rax movl %eax, 0x64(%rsp) movl 0x6c(%rsp), %eax addl $0x1, %eax movl %eax, 0x6c(%rsp) jmp 0x7c7b6 movq 0x58(%rsp), %rsi leaq 0x78(%rsp), %rdi callq 0x7ffa0 cmpl $0x3, (%rax) jne 0x7c7b4 movl 0x68(%rsp), %eax addl $0x1, %eax movl %eax, 0x68(%rsp) jmp 0x7c7b6 jmp 0x7c7b8 jmp 0x7c7ba movq 0x58(%rsp), %rax addq $0x1, %rax movq %rax, 0x58(%rsp) jmp 0x7c58a cmpl $0x0, 0x68(%rsp) je 0x7c80a cmpl $0x0, 0x6c(%rsp) je 0x7c7f5 movq 0x30(%rsp), %rdi callq 0x7ffc0 movb %al, 0x3(%rsp) jmp 0x7c7eb movb 0x3(%rsp), %al testb $0x1, %al jne 0x7c7f5 jmp 0x7c80a movl $0x3, 0xd4(%rsp) movl $0x1, 0x50(%rsp) jmp 0x7c87b cmpl $0x0, 0x6c(%rsp) je 0x7c859 movslq 0x64(%rsp), %rsi leaq 0xa8(%rsp), %rdi callq 0x7ff80 movq %rax, %rsi movq 0xc0(%rsp), %rdi callq 0x7ca40 jmp 0x7c835 movq 0xc0(%rsp), %rdi callq 0x7c9e0 jmp 0x7c844 movl $0x2, 0xd4(%rsp) movl $0x1, 0x50(%rsp) jmp 0x7c87b movq 0xc0(%rsp), %rdi callq 0x7c9e0 jmp 0x7c868 movl $0x3, 0xd4(%rsp) movl $0x1, 0x50(%rsp) leaq 0x78(%rsp), %rdi callq 0x7ffe0 leaq 0xa8(%rsp), %rdi callq 0x80040 movl 0xd4(%rsp), %eax addq $0xd8, %rsp retq leaq 0xa8(%rsp), %rdi callq 0x80040 movq 0x98(%rsp), %rdi callq 0xf9e0 nopl (%rax,%rax)
_ZNK3cli5group15match_exclusiveERNS_11match_stateE: sub rsp, 0D8h mov [rsp+0D8h+var_10], rdi mov [rsp+0D8h+var_18], rsi mov rdi, [rsp+0D8h+var_10] mov [rsp+0D8h+var_A8], rdi add rdi, 0E0h call _ZNKSt6vectorISt10shared_ptrIN3cli9matchableEESaIS3_EE4sizeEv; std::vector<std::shared_ptr<cli::matchable>>::size(void) mov [rsp+0D8h+var_A0], rax mov rax, [rsp+0D8h+var_18] mov [rsp+0D8h+var_98], rax lea rdi, [rsp+0D8h+var_31] mov [rsp+0D8h+var_90], rdi call _ZNSaIN3cli11match_stateEEC2Ev; std::allocator<cli::match_state>::allocator(void) mov rsi, [rsp+0D8h+var_A0] mov rdx, [rsp+0D8h+var_98] mov rcx, [rsp+0D8h+var_90] lea rdi, [rsp+0D8h+var_30] call _ZNSt6vectorIN3cli11match_stateESaIS1_EEC2EmRKS1_RKS2_; std::vector<cli::match_state>::vector(ulong,cli::match_state const&,std::allocator<cli::match_state> const&) jmp short $+2 loc_7C502: lea rdi, [rsp+0D8h+var_31] call _ZNSaIN3cli11match_stateEED2Ev; std::allocator<cli::match_state>::~allocator() mov rdi, [rsp+0D8h+var_A8] add rdi, 0E0h call _ZNKSt6vectorISt10shared_ptrIN3cli9matchableEESaIS3_EE4sizeEv; std::vector<std::shared_ptr<cli::matchable>>::size(void) mov [rsp+0D8h+var_B8], rax mov [rsp+0D8h+var_64], 3 lea rdi, [rsp+0D8h+var_65] mov [rsp+0D8h+var_B0], rdi call _ZNSaIN3cli10match_typeEEC2Ev; std::allocator<cli::match_type>::allocator(void) mov rsi, [rsp+0D8h+var_B8] mov rcx, [rsp+0D8h+var_B0] lea rdi, [rsp+0D8h+var_60] lea rdx, [rsp+0D8h+var_64] call _ZNSt6vectorIN3cli10match_typeESaIS1_EEC2EmRKS1_RKS2_; std::vector<cli::match_type>::vector(ulong,cli::match_type const&,std::allocator<cli::match_type> const&) jmp short $+2 loc_7C557: lea rdi, [rsp+0D8h+var_65] call _ZNSaIN3cli10match_typeEED2Ev; std::allocator<cli::match_type>::~allocator() mov [rsp+0D8h+var_6C], 0 mov [rsp+0D8h+var_70], 0 mov [rsp+0D8h+var_74], 0FFFFFFFFh mov [rsp+0D8h+var_78], 0FFFFFFFFh mov [rsp+0D8h+var_80], 0 loc_7C58A: mov rdi, [rsp+0D8h+var_A8] mov rax, [rsp+0D8h+var_80] mov [rsp+0D8h+var_C0], rax add rdi, 0E0h call _ZNKSt6vectorISt10shared_ptrIN3cli9matchableEESaIS3_EE4sizeEv; std::vector<std::shared_ptr<cli::matchable>>::size(void) mov rcx, rax mov rax, [rsp+0D8h+var_C0] cmp rax, rcx jnb loc_7C7CD mov rsi, [rsp+0D8h+var_80] lea rdi, [rsp+0D8h+var_30] call _ZNSt6vectorIN3cli11match_stateESaIS1_EEixEm; std::vector<cli::match_state>::operator[](ulong) mov rdi, rax; this call _ZN3cli11match_state19apply_settings_fromEv; cli::match_state::apply_settings_from(void) jmp short $+2 loc_7C5D2: jmp short $+2 loc_7C5D4: mov rdi, [rsp+0D8h+var_A8] add rdi, 0E0h mov rsi, [rsp+0D8h+var_80] call _ZNKSt6vectorISt10shared_ptrIN3cli9matchableEESaIS3_EEixEm; std::vector<std::shared_ptr<cli::matchable>>::operator[](ulong) mov rdi, rax call _ZNKSt19__shared_ptr_accessIN3cli9matchableELN9__gnu_cxx12_Lock_policyE2ELb0ELb0EEptEv; std::__shared_ptr_access<cli::matchable,(__gnu_cxx::_Lock_policy)2,false,false>::operator->(void) mov [rsp+0D8h+var_D0], rax mov rsi, [rsp+0D8h+var_80] lea rdi, [rsp+0D8h+var_30] call _ZNSt6vectorIN3cli11match_stateESaIS1_EEixEm; std::vector<cli::match_state>::operator[](ulong) mov rdi, [rsp+0D8h+var_D0] mov rsi, rax mov rax, [rdi] mov rax, [rax+10h] call rax mov [rsp+0D8h+var_C4], eax jmp short $+2 loc_7C620: mov eax, [rsp+0D8h+var_C4] mov [rsp+0D8h+var_84], eax cmp [rsp+0D8h+var_84], 3 jz loc_7C6BE mov eax, [rsp+0D8h+var_84] mov [rsp+0D8h+var_D4], eax mov rsi, [rsp+0D8h+var_80] lea rdi, [rsp+0D8h+var_60] call _ZNSt6vectorIN3cli10match_typeESaIS1_EEixEm; std::vector<cli::match_type>::operator[](ulong) mov ecx, [rsp+0D8h+var_D4] mov [rax], ecx jmp short loc_7C6BE mov rcx, rax mov eax, edx mov [rsp+arg_90], rcx mov [rsp+arg_8C], eax lea rdi, [rsp+arg_9F] call _ZNSaIN3cli11match_stateEED2Ev; std::allocator<cli::match_state>::~allocator() jmp loc_7C8AE mov rcx, rax mov eax, edx mov [rsp+arg_90], rcx mov [rsp+arg_8C], eax lea rdi, [rsp+arg_6B] call _ZNSaIN3cli10match_typeEED2Ev; std::allocator<cli::match_type>::~allocator() jmp loc_7C8A1 mov rcx, rax mov eax, edx mov [rsp+arg_90], rcx mov [rsp+arg_8C], eax lea rdi, [rsp+arg_70] call _ZNSt6vectorIN3cli10match_typeESaIS1_EED2Ev; std::vector<cli::match_type>::~vector() jmp loc_7C8A1 loc_7C6BE: jmp short $+2 loc_7C6C0: cmp [rsp+0D8h+var_84], 1 jz loc_7C5D4 mov rsi, [rsp+0D8h+var_80] lea rdi, [rsp+0D8h+var_30] call _ZNSt6vectorIN3cli11match_stateESaIS1_EEixEm; std::vector<cli::match_state>::operator[](ulong) mov rdi, rax; this call _ZN3cli11match_state18save_settings_intoEv; cli::match_state::save_settings_into(void) jmp short $+2 loc_7C6E7: mov rsi, [rsp+0D8h+var_80] lea rdi, [rsp+0D8h+var_60] call _ZNSt6vectorIN3cli10match_typeESaIS1_EEixEm; std::vector<cli::match_type>::operator[](ulong) cmp dword ptr [rax], 1 jnz short loc_7C737 mov rsi, [rsp+0D8h+var_80] lea rdi, [rsp+0D8h+var_30] call _ZNSt6vectorIN3cli11match_stateESaIS1_EEixEm; std::vector<cli::match_state>::operator[](ulong) mov rsi, rax mov rdi, [rsp+0D8h+var_18] call _ZN3cli11match_stateaSERKS0_; cli::match_state::operator=(cli::match_state const&) jmp short $+2 loc_7C71F: mov [rsp+0D8h+var_4], 1 mov [rsp+0D8h+var_88], 1 jmp loc_7C87B loc_7C737: mov rsi, [rsp+0D8h+var_80] lea rdi, [rsp+0D8h+var_60] call _ZNSt6vectorIN3cli10match_typeESaIS1_EEixEm; std::vector<cli::match_type>::operator[](ulong) cmp dword ptr [rax], 2 jnz short loc_7C795 mov rsi, [rsp+0D8h+var_80] lea rdi, [rsp+0D8h+var_30] call _ZNSt6vectorIN3cli11match_stateESaIS1_EEixEm; std::vector<cli::match_state>::operator[](ulong) mov eax, [rax+38h] cmp eax, [rsp+0D8h+var_78] jle short loc_7C788 mov rsi, [rsp+0D8h+var_80] lea rdi, [rsp+0D8h+var_30] call _ZNSt6vectorIN3cli11match_stateESaIS1_EEixEm; std::vector<cli::match_state>::operator[](ulong) mov eax, [rax+38h] mov [rsp+0D8h+var_78], eax mov rax, [rsp+0D8h+var_80] mov [rsp+0D8h+var_74], eax loc_7C788: mov eax, [rsp+0D8h+var_6C] add eax, 1 mov [rsp+0D8h+var_6C], eax jmp short loc_7C7B6 loc_7C795: mov rsi, [rsp+0D8h+var_80] lea rdi, [rsp+0D8h+var_60] call _ZNSt6vectorIN3cli10match_typeESaIS1_EEixEm; std::vector<cli::match_type>::operator[](ulong) cmp dword ptr [rax], 3 jnz short loc_7C7B4 mov eax, [rsp+0D8h+var_70] add eax, 1 mov [rsp+0D8h+var_70], eax loc_7C7B4: jmp short $+2 loc_7C7B6: jmp short $+2 loc_7C7B8: jmp short $+2 loc_7C7BA: mov rax, [rsp+0D8h+var_80] add rax, 1 mov [rsp+0D8h+var_80], rax jmp loc_7C58A loc_7C7CD: cmp [rsp+0D8h+var_70], 0 jz short loc_7C80A cmp [rsp+0D8h+var_6C], 0 jz short loc_7C7F5 mov rdi, [rsp+0D8h+var_A8]; this call _ZNK3cli5group20no_match_beats_errorEv; cli::group::no_match_beats_error(void) mov [rsp+0D8h+var_D5], al jmp short $+2 loc_7C7EB: mov al, [rsp+0D8h+var_D5] test al, 1 jnz short loc_7C7F5 jmp short loc_7C80A loc_7C7F5: mov [rsp+0D8h+var_4], 3 mov [rsp+0D8h+var_88], 1 jmp short loc_7C87B loc_7C80A: cmp [rsp+0D8h+var_6C], 0 jz short loc_7C859 movsxd rsi, [rsp+0D8h+var_74] lea rdi, [rsp+0D8h+var_30] call _ZNSt6vectorIN3cli11match_stateESaIS1_EEixEm; std::vector<cli::match_state>::operator[](ulong) mov rsi, rax mov rdi, [rsp+0D8h+var_18] call _ZN3cli11match_stateaSERKS0_; cli::match_state::operator=(cli::match_state const&) jmp short $+2 loc_7C835: mov rdi, [rsp+0D8h+var_18]; this call _ZN3cli11match_state19apply_settings_fromEv; cli::match_state::apply_settings_from(void) jmp short $+2 loc_7C844: mov [rsp+0D8h+var_4], 2 mov [rsp+0D8h+var_88], 1 jmp short loc_7C87B loc_7C859: mov rdi, [rsp+0D8h+var_18]; this call _ZN3cli11match_state19apply_settings_fromEv; cli::match_state::apply_settings_from(void) jmp short $+2 loc_7C868: mov [rsp+0D8h+var_4], 3 mov [rsp+0D8h+var_88], 1 loc_7C87B: lea rdi, [rsp+0D8h+var_60] call _ZNSt6vectorIN3cli10match_typeESaIS1_EED2Ev; std::vector<cli::match_type>::~vector() lea rdi, [rsp+0D8h+var_30] call _ZNSt6vectorIN3cli11match_stateESaIS1_EED2Ev; std::vector<cli::match_state>::~vector() mov eax, [rsp+0D8h+var_4] add rsp, 0D8h retn loc_7C8A1: lea rdi, [rsp+arg_A0] call _ZNSt6vectorIN3cli11match_stateESaIS1_EED2Ev; std::vector<cli::match_state>::~vector() loc_7C8AE: mov rdi, [rsp+arg_90] call __Unwind_Resume
long long cli::group::match_exclusive(cli::group *this, cli::match_state *a2) { int v2; // r8d int v3; // r9d int v4; // r8d int v5; // r9d cli::match_state *v6; // rax long long v7; // rax long long v8; // rax cli::match_state *v9; // rax long long v10; // rax long long v11; // rax long long v13; // [rsp+8h] [rbp-D0h] int v14; // [rsp+20h] [rbp-B8h] int v15; // [rsp+38h] [rbp-A0h] int v16; // [rsp+54h] [rbp-84h] unsigned long long i; // [rsp+58h] [rbp-80h] int v18; // [rsp+60h] [rbp-78h] int v19; // [rsp+64h] [rbp-74h] int v20; // [rsp+68h] [rbp-70h] int v21; // [rsp+6Ch] [rbp-6Ch] char v22; // [rsp+73h] [rbp-65h] BYREF int v23; // [rsp+74h] [rbp-64h] BYREF _BYTE v24[47]; // [rsp+78h] [rbp-60h] BYREF char v25; // [rsp+A7h] [rbp-31h] BYREF _BYTE v26[24]; // [rsp+A8h] [rbp-30h] BYREF cli::match_state *v27; // [rsp+C0h] [rbp-18h] cli::group *v28; // [rsp+C8h] [rbp-10h] unsigned int v29; // [rsp+D4h] [rbp-4h] v28 = this; v27 = a2; v15 = std::vector<std::shared_ptr<cli::matchable>>::size((_QWORD *)this + 28); std::allocator<cli::match_state>::allocator(); std::vector<cli::match_state>::vector((unsigned int)v26, v15, (_DWORD)a2, (unsigned int)&v25, v2, v3); std::allocator<cli::match_state>::~allocator(&v25); v14 = std::vector<std::shared_ptr<cli::matchable>>::size((_QWORD *)this + 28); v23 = 3; std::allocator<cli::match_type>::allocator(); std::vector<cli::match_type>::vector((unsigned int)v24, v14, (unsigned int)&v23, (unsigned int)&v22, v4, v5); std::allocator<cli::match_type>::~allocator(&v22); v21 = 0; v20 = 0; v19 = -1; v18 = -1; for ( i = 0LL; i < std::vector<std::shared_ptr<cli::matchable>>::size((_QWORD *)this + 28); ++i ) { v6 = (cli::match_state *)std::vector<cli::match_state>::operator[](v26, i); cli::match_state::apply_settings_from(v6); do { v7 = std::vector<std::shared_ptr<cli::matchable>>::operator[]((char *)this + 224, i); v13 = std::__shared_ptr_access<cli::matchable,(__gnu_cxx::_Lock_policy)2,false,false>::operator->(v7); v8 = std::vector<cli::match_state>::operator[](v26, i); v16 = (*(long long ( **)(long long, long long))(*(_QWORD *)v13 + 16LL))(v13, v8); if ( v16 != 3 ) *(_DWORD *)std::vector<cli::match_type>::operator[](v24, i) = v16; } while ( v16 == 1 ); v9 = (cli::match_state *)std::vector<cli::match_state>::operator[](v26, i); cli::match_state::save_settings_into(v9); if ( *(_DWORD *)std::vector<cli::match_type>::operator[](v24, i) == 1 ) { v10 = std::vector<cli::match_state>::operator[](v26, i); cli::match_state::operator=(v27, v10); v29 = 1; goto LABEL_23; } if ( *(_DWORD *)std::vector<cli::match_type>::operator[](v24, i) == 2 ) { if ( *(_DWORD *)(std::vector<cli::match_state>::operator[](v26, i) + 56) > v18 ) { v18 = *(_DWORD *)(std::vector<cli::match_state>::operator[](v26, i) + 56); v19 = i; } ++v21; } else if ( *(_DWORD *)std::vector<cli::match_type>::operator[](v24, i) == 3 ) { ++v20; } } if ( v20 && (!v21 || (cli::group::no_match_beats_error(this) & 1) != 0) ) { v29 = 3; } else if ( v21 ) { v11 = std::vector<cli::match_state>::operator[](v26, v19); cli::match_state::operator=(v27, v11); cli::match_state::apply_settings_from(v27); v29 = 2; } else { cli::match_state::apply_settings_from(v27); v29 = 3; } LABEL_23: std::vector<cli::match_type>::~vector(v24); std::vector<cli::match_state>::~vector(v26); return v29; }
match_exclusive: SUB RSP,0xd8 MOV qword ptr [RSP + 0xc8],RDI MOV qword ptr [RSP + 0xc0],RSI MOV RDI,qword ptr [RSP + 0xc8] MOV qword ptr [RSP + 0x30],RDI ADD RDI,0xe0 CALL 0x0017b750 MOV qword ptr [RSP + 0x38],RAX MOV RAX,qword ptr [RSP + 0xc0] MOV qword ptr [RSP + 0x40],RAX LEA RDI,[RSP + 0xa7] MOV qword ptr [RSP + 0x48],RDI CALL 0x0017fe40 MOV RSI,qword ptr [RSP + 0x38] MOV RDX,qword ptr [RSP + 0x40] MOV RCX,qword ptr [RSP + 0x48] LAB_0017c4f3: LEA RDI,[RSP + 0xa8] CALL 0x0017fe50 JMP 0x0017c502 LAB_0017c502: LEA RDI,[RSP + 0xa7] CALL 0x0017fed0 MOV RDI,qword ptr [RSP + 0x30] ADD RDI,0xe0 CALL 0x0017b750 MOV qword ptr [RSP + 0x20],RAX MOV dword ptr [RSP + 0x74],0x3 LEA RDI,[RSP + 0x73] MOV qword ptr [RSP + 0x28],RDI CALL 0x0017fee0 MOV RSI,qword ptr [RSP + 0x20] MOV RCX,qword ptr [RSP + 0x28] LAB_0017c546: LEA RDI,[RSP + 0x78] LEA RDX,[RSP + 0x74] CALL 0x0017fef0 JMP 0x0017c557 LAB_0017c557: LEA RDI,[RSP + 0x73] CALL 0x0017ff70 MOV dword ptr [RSP + 0x6c],0x0 MOV dword ptr [RSP + 0x68],0x0 MOV dword ptr [RSP + 0x64],0xffffffff MOV dword ptr [RSP + 0x60],0xffffffff MOV qword ptr [RSP + 0x58],0x0 LAB_0017c58a: MOV RDI,qword ptr [RSP + 0x30] MOV RAX,qword ptr [RSP + 0x58] MOV qword ptr [RSP + 0x18],RAX ADD RDI,0xe0 CALL 0x0017b750 MOV RCX,RAX MOV RAX,qword ptr [RSP + 0x18] CMP RAX,RCX JNC 0x0017c7cd MOV RSI,qword ptr [RSP + 0x58] LEA RDI,[RSP + 0xa8] CALL 0x0017ff80 MOV RDI,RAX LAB_0017c5cb: CALL 0x0017c9e0 JMP 0x0017c5d2 LAB_0017c5d2: JMP 0x0017c5d4 LAB_0017c5d4: MOV RDI,qword ptr [RSP + 0x30] ADD RDI,0xe0 MOV RSI,qword ptr [RSP + 0x58] CALL 0x0017ca00 MOV RDI,RAX CALL 0x0017c8c0 MOV qword ptr [RSP + 0x8],RAX MOV RSI,qword ptr [RSP + 0x58] LEA RDI,[RSP + 0xa8] CALL 0x0017ff80 MOV RDI,qword ptr [RSP + 0x8] MOV RSI,RAX MOV RAX,qword ptr [RDI] MOV RAX,qword ptr [RAX + 0x10] CALL RAX MOV dword ptr [RSP + 0x14],EAX JMP 0x0017c620 LAB_0017c620: MOV EAX,dword ptr [RSP + 0x14] MOV dword ptr [RSP + 0x54],EAX CMP dword ptr [RSP + 0x54],0x3 JZ 0x0017c6be MOV EAX,dword ptr [RSP + 0x54] MOV dword ptr [RSP + 0x4],EAX MOV RSI,qword ptr [RSP + 0x58] LEA RDI,[RSP + 0x78] CALL 0x0017ffa0 MOV ECX,dword ptr [RSP + 0x4] MOV dword ptr [RAX],ECX JMP 0x0017c6be LAB_0017c6be: JMP 0x0017c6c0 LAB_0017c6c0: CMP dword ptr [RSP + 0x54],0x1 JZ 0x0017c5d4 MOV RSI,qword ptr [RSP + 0x58] LEA RDI,[RSP + 0xa8] CALL 0x0017ff80 MOV RDI,RAX CALL 0x0017ca20 JMP 0x0017c6e7 LAB_0017c6e7: MOV RSI,qword ptr [RSP + 0x58] LEA RDI,[RSP + 0x78] CALL 0x0017ffa0 CMP dword ptr [RAX],0x1 JNZ 0x0017c737 MOV RSI,qword ptr [RSP + 0x58] LEA RDI,[RSP + 0xa8] CALL 0x0017ff80 MOV RSI,RAX MOV RDI,qword ptr [RSP + 0xc0] CALL 0x0017ca40 JMP 0x0017c71f LAB_0017c71f: MOV dword ptr [RSP + 0xd4],0x1 MOV dword ptr [RSP + 0x50],0x1 JMP 0x0017c87b LAB_0017c737: MOV RSI,qword ptr [RSP + 0x58] LEA RDI,[RSP + 0x78] CALL 0x0017ffa0 CMP dword ptr [RAX],0x2 JNZ 0x0017c795 MOV RSI,qword ptr [RSP + 0x58] LEA RDI,[RSP + 0xa8] CALL 0x0017ff80 MOV EAX,dword ptr [RAX + 0x38] CMP EAX,dword ptr [RSP + 0x60] JLE 0x0017c788 MOV RSI,qword ptr [RSP + 0x58] LEA RDI,[RSP + 0xa8] CALL 0x0017ff80 MOV EAX,dword ptr [RAX + 0x38] MOV dword ptr [RSP + 0x60],EAX MOV RAX,qword ptr [RSP + 0x58] MOV dword ptr [RSP + 0x64],EAX LAB_0017c788: MOV EAX,dword ptr [RSP + 0x6c] ADD EAX,0x1 MOV dword ptr [RSP + 0x6c],EAX JMP 0x0017c7b6 LAB_0017c795: MOV RSI,qword ptr [RSP + 0x58] LEA RDI,[RSP + 0x78] CALL 0x0017ffa0 CMP dword ptr [RAX],0x3 JNZ 0x0017c7b4 MOV EAX,dword ptr [RSP + 0x68] ADD EAX,0x1 MOV dword ptr [RSP + 0x68],EAX LAB_0017c7b4: JMP 0x0017c7b6 LAB_0017c7b6: JMP 0x0017c7b8 LAB_0017c7b8: JMP 0x0017c7ba LAB_0017c7ba: MOV RAX,qword ptr [RSP + 0x58] ADD RAX,0x1 MOV qword ptr [RSP + 0x58],RAX JMP 0x0017c58a LAB_0017c7cd: CMP dword ptr [RSP + 0x68],0x0 JZ 0x0017c80a CMP dword ptr [RSP + 0x6c],0x0 JZ 0x0017c7f5 MOV RDI,qword ptr [RSP + 0x30] CALL 0x0017ffc0 MOV byte ptr [RSP + 0x3],AL JMP 0x0017c7eb LAB_0017c7eb: MOV AL,byte ptr [RSP + 0x3] TEST AL,0x1 JNZ 0x0017c7f5 JMP 0x0017c80a LAB_0017c7f5: MOV dword ptr [RSP + 0xd4],0x3 MOV dword ptr [RSP + 0x50],0x1 JMP 0x0017c87b LAB_0017c80a: CMP dword ptr [RSP + 0x6c],0x0 JZ 0x0017c859 MOVSXD RSI,dword ptr [RSP + 0x64] LEA RDI,[RSP + 0xa8] CALL 0x0017ff80 MOV RSI,RAX MOV RDI,qword ptr [RSP + 0xc0] CALL 0x0017ca40 JMP 0x0017c835 LAB_0017c835: MOV RDI,qword ptr [RSP + 0xc0] CALL 0x0017c9e0 JMP 0x0017c844 LAB_0017c844: MOV dword ptr [RSP + 0xd4],0x2 MOV dword ptr [RSP + 0x50],0x1 JMP 0x0017c87b LAB_0017c859: MOV RDI,qword ptr [RSP + 0xc0] CALL 0x0017c9e0 LAB_0017c866: JMP 0x0017c868 LAB_0017c868: MOV dword ptr [RSP + 0xd4],0x3 MOV dword ptr [RSP + 0x50],0x1 LAB_0017c87b: LEA RDI,[RSP + 0x78] CALL 0x0017ffe0 LEA RDI,[RSP + 0xa8] CALL 0x00180040 MOV EAX,dword ptr [RSP + 0xd4] ADD RSP,0xd8 RET
/* cli::group::match_exclusive(cli::match_state&) const */ int4 __thiscall cli::group::match_exclusive(group *this,match_state *param_1) { byte bVar1; int iVar2; ulong uVar3; match_state *pmVar4; __shared_ptr_access<cli::matchable,(__gnu_cxx::_Lock_policy)2,false,false> *this_00; long *plVar5; int8 uVar6; int *piVar7; long lVar8; ulong local_80; int local_78; int local_74; int local_70; int local_6c; allocator<cli::match_type> local_65; int4 local_64; vector<cli::match_type,std::allocator<cli::match_type>> local_60 [47]; allocator<cli::match_state> local_31; vector<cli::match_state,std::allocator<cli::match_state>> local_30 [24]; match_state *local_18; group *local_10; int4 local_4; local_18 = param_1; local_10 = this; uVar3 = std:: vector<std::shared_ptr<cli::matchable>,std::allocator<std::shared_ptr<cli::matchable>>>:: size((vector<std::shared_ptr<cli::matchable>,std::allocator<std::shared_ptr<cli::matchable>>> *)(this + 0xe0)); pmVar4 = local_18; std::allocator<cli::match_state>::allocator(&local_31); /* try { // try from 0017c4f3 to 0017c4ff has its CatchHandler @ 0017c652 */ std::vector<cli::match_state,std::allocator<cli::match_state>>::vector (local_30,uVar3,pmVar4,(allocator *)&local_31); std::allocator<cli::match_state>::~allocator(&local_31); uVar3 = std:: vector<std::shared_ptr<cli::matchable>,std::allocator<std::shared_ptr<cli::matchable>>>:: size((vector<std::shared_ptr<cli::matchable>,std::allocator<std::shared_ptr<cli::matchable>>> *)(this + 0xe0)); local_64 = 3; std::allocator<cli::match_type>::allocator(&local_65); /* try { // try from 0017c546 to 0017c554 has its CatchHandler @ 0017c678 */ std::vector<cli::match_type,std::allocator<cli::match_type>>::vector (local_60,uVar3,(match_type *)&local_64,(allocator *)&local_65); std::allocator<cli::match_type>::~allocator(&local_65); local_6c = 0; local_70 = 0; local_74 = -1; local_78 = -1; local_80 = 0; do { uVar3 = std:: vector<std::shared_ptr<cli::matchable>,std::allocator<std::shared_ptr<cli::matchable>>> ::size((vector<std::shared_ptr<cli::matchable>,std::allocator<std::shared_ptr<cli::matchable>>> *)(this + 0xe0)); if (uVar3 <= local_80) { if ((local_70 == 0) || ((local_6c != 0 && (bVar1 = no_match_beats_error(this), (bVar1 & 1) == 0)))) { if (local_6c == 0) { match_state::apply_settings_from(local_18); local_4 = 3; } else { pmVar4 = (match_state *) std::vector<cli::match_state,std::allocator<cli::match_state>>::operator[] (local_30,(long)local_74); match_state::operator=(local_18,pmVar4); match_state::apply_settings_from(local_18); local_4 = 2; } } else { local_4 = 3; } LAB_0017c87b: std::vector<cli::match_type,std::allocator<cli::match_type>>::~vector(local_60); std::vector<cli::match_state,std::allocator<cli::match_state>>::~vector(local_30); return local_4; } pmVar4 = (match_state *) std::vector<cli::match_state,std::allocator<cli::match_state>>::operator[] (local_30,local_80); /* try { // try from 0017c5cb to 0017c865 has its CatchHandler @ 0017c69b */ match_state::apply_settings_from(pmVar4); do { this_00 = (__shared_ptr_access<cli::matchable,(__gnu_cxx::_Lock_policy)2,false,false> *) std:: vector<std::shared_ptr<cli::matchable>,std::allocator<std::shared_ptr<cli::matchable>>> ::operator[]((vector<std::shared_ptr<cli::matchable>,std::allocator<std::shared_ptr<cli::matchable>>> *)(this + 0xe0),local_80); plVar5 = (long *)std:: __shared_ptr_access<cli::matchable,(__gnu_cxx::_Lock_policy)2,false,false>:: operator->(this_00); uVar6 = std::vector<cli::match_state,std::allocator<cli::match_state>>::operator[] (local_30,local_80); iVar2 = (**(code **)(*plVar5 + 0x10))(plVar5,uVar6); if (iVar2 != 3) { piVar7 = (int *)std::vector<cli::match_type,std::allocator<cli::match_type>>::operator[] (local_60,local_80); *piVar7 = iVar2; } } while (iVar2 == 1); pmVar4 = (match_state *) std::vector<cli::match_state,std::allocator<cli::match_state>>::operator[] (local_30,local_80); match_state::save_settings_into(pmVar4); piVar7 = (int *)std::vector<cli::match_type,std::allocator<cli::match_type>>::operator[] (local_60,local_80); if (*piVar7 == 1) { pmVar4 = (match_state *) std::vector<cli::match_state,std::allocator<cli::match_state>>::operator[] (local_30,local_80); match_state::operator=(local_18,pmVar4); local_4 = 1; goto LAB_0017c87b; } piVar7 = (int *)std::vector<cli::match_type,std::allocator<cli::match_type>>::operator[] (local_60,local_80); if (*piVar7 == 2) { lVar8 = std::vector<cli::match_state,std::allocator<cli::match_state>>::operator[] (local_30,local_80); if (local_78 < *(int *)(lVar8 + 0x38)) { lVar8 = std::vector<cli::match_state,std::allocator<cli::match_state>>::operator[] (local_30,local_80); local_78 = *(int *)(lVar8 + 0x38); local_74 = (int)local_80; } local_6c = local_6c + 1; } else { piVar7 = (int *)std::vector<cli::match_type,std::allocator<cli::match_type>>::operator[] (local_60,local_80); if (*piVar7 == 3) { local_70 = local_70 + 1; } } local_80 = local_80 + 1; } while( true ); }
6,057
string_repeat(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, unsigned long)
monkey531[P]llama/common/common.cpp
std::string string_repeat(const std::string & str, size_t n) { if (n == 0) { return ""; } std::string result; result.reserve(str.length() * n); for (size_t i = 0; i < n; ++i) { result += str; } return result; }
O2
cpp
string_repeat(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, unsigned long): pushq %r15 pushq %r14 pushq %rbx subq $0x10, %rsp movq %rdi, %rbx testq %rdx, %rdx je 0x53879 movq %rdx, %r14 movq %rsi, %r15 leaq 0x10(%rbx), %rax movq %rax, (%rbx) andq $0x0, 0x8(%rbx) movb $0x0, 0x10(%rbx) movq 0x8(%rsi), %rsi imulq %rdx, %rsi movq %rbx, %rdi callq 0x23d90 subq $0x1, %r14 jb 0x5388d movq %rbx, %rdi movq %r15, %rsi callq 0x24140 jmp 0x53866 leaq 0x5b269(%rip), %rsi # 0xaeae9 leaq 0xf(%rsp), %rdx movq %rbx, %rdi callq 0x26f76 movq %rbx, %rax addq $0x10, %rsp popq %rbx popq %r14 popq %r15 retq jmp 0x5389c movq %rax, %r14 movq %rbx, %rdi callq 0x241d8 movq %r14, %rdi callq 0x23fa0
_Z13string_repeatRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEm: push r15 push r14 push rbx sub rsp, 10h mov rbx, rdi test rdx, rdx jz short loc_53879 mov r14, rdx mov r15, rsi lea rax, [rbx+10h] mov [rbx], rax and qword ptr [rbx+8], 0 mov byte ptr [rbx+10h], 0 mov rsi, [rsi+8] imul rsi, rdx mov rdi, rbx call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE7reserveEm; std::string::reserve(ulong) loc_53866: sub r14, 1 jb short loc_5388D mov rdi, rbx mov rsi, r15 call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendERKS4_; std::string::append(std::string const&) jmp short loc_53866 loc_53879: lea rsi, aErrorWhileHand_0+34h; "" lea rdx, [rsp+28h+var_19] mov rdi, rbx call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&) loc_5388D: mov rax, rbx add rsp, 10h pop rbx pop r14 pop r15 retn jmp short $+2 loc_5389C: mov r14, rax mov rdi, rbx; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() mov rdi, r14 call __Unwind_Resume
long long string_repeat(long long a1, long long a2, long long a3) { long long v3; // r14 if ( a3 ) { v3 = a3; *(_QWORD *)a1 = a1 + 16; *(_QWORD *)(a1 + 8) = 0LL; *(_BYTE *)(a1 + 16) = 0; std::string::reserve(a1, a3 * *(_QWORD *)(a2 + 8)); while ( v3-- != 0 ) std::string::append(a1, a2); } else { std::string::basic_string<std::allocator<char>>((_QWORD *)a1, (long long)""); } return a1; }
string_repeat: PUSH R15 PUSH R14 PUSH RBX SUB RSP,0x10 MOV RBX,RDI TEST RDX,RDX JZ 0x00153879 MOV R14,RDX MOV R15,RSI LEA RAX,[RBX + 0x10] MOV qword ptr [RBX],RAX AND qword ptr [RBX + 0x8],0x0 MOV byte ptr [RBX + 0x10],0x0 MOV RSI,qword ptr [RSI + 0x8] IMUL RSI,RDX LAB_0015385e: MOV RDI,RBX CALL 0x00123d90 LAB_00153866: SUB R14,0x1 JC 0x0015388d LAB_0015386c: MOV RDI,RBX MOV RSI,R15 CALL 0x00124140 LAB_00153877: JMP 0x00153866 LAB_00153879: LEA RSI,[0x1aeae9] LEA RDX,[RSP + 0xf] MOV RDI,RBX CALL 0x00126f76 LAB_0015388d: MOV RAX,RBX ADD RSP,0x10 POP RBX POP R14 POP R15 RET
/* string_repeat(std::__cxx11::string const&, unsigned long) */ string * string_repeat(string *param_1,ulong param_2) { long in_RDX; bool bVar1; allocator local_19; if (in_RDX == 0) { std::__cxx11::string::string<std::allocator<char>>(param_1,"",&local_19); } else { *(string **)param_1 = param_1 + 0x10; *(int8 *)(param_1 + 8) = 0; param_1[0x10] = (string)0x0; /* try { // try from 0015385e to 00153865 has its CatchHandler @ 0015389a */ std::__cxx11::string::reserve((ulong)param_1); while (bVar1 = in_RDX != 0, in_RDX = in_RDX + -1, bVar1) { /* try { // try from 0015386c to 00153876 has its CatchHandler @ 0015389c */ std::__cxx11::string::append(param_1); } } return param_1; }
6,058
delete_tails
eloqsql/storage/maria/ma_blockrec.c
static my_bool delete_tails(MARIA_HA *info, MARIA_RECORD_POS *tails) { my_bool res= 0; DBUG_ENTER("delete_tails"); for (; *tails; tails++) { if (delete_head_or_tail(info, ma_recordpos_to_page(*tails), ma_recordpos_to_dir_entry(*tails), 0, 1)) res= 1; } DBUG_RETURN(res); }
O0
c
delete_tails: pushq %rbp movq %rsp, %rbp subq $0x30, %rsp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movb $0x0, -0x11(%rbp) movq -0x10(%rbp), %rax cmpq $0x0, (%rax) je 0x58bd1 movq -0x8(%rbp), %rax movq %rax, -0x28(%rbp) movq -0x10(%rbp), %rax movq (%rax), %rdi callq 0x57f00 movq %rax, -0x20(%rbp) movq -0x10(%rbp), %rax movq (%rax), %rdi callq 0x57f20 movq -0x28(%rbp), %rdi movq -0x20(%rbp), %rsi movl %eax, %edx xorl %ecx, %ecx movl $0x1, %r8d callq 0x57b60 cmpb $0x0, %al je 0x58bc1 movb $0x1, -0x11(%rbp) jmp 0x58bc3 movq -0x10(%rbp), %rax addq $0x8, %rax movq %rax, -0x10(%rbp) jmp 0x58b74 jmp 0x58bd3 movb -0x11(%rbp), %al movb %al, -0x29(%rbp) movb -0x29(%rbp), %al addq $0x30, %rsp popq %rbp retq nopw %cs:(%rax,%rax)
delete_tails: push rbp mov rbp, rsp sub rsp, 30h mov [rbp+var_8], rdi mov [rbp+var_10], rsi mov [rbp+var_11], 0 loc_58B74: mov rax, [rbp+var_10] cmp qword ptr [rax], 0 jz short loc_58BD1 mov rax, [rbp+var_8] mov [rbp+var_28], rax mov rax, [rbp+var_10] mov rdi, [rax] call ma_recordpos_to_page mov [rbp+var_20], rax mov rax, [rbp+var_10] mov rdi, [rax] call ma_recordpos_to_dir_entry mov rdi, [rbp+var_28] mov rsi, [rbp+var_20] mov edx, eax xor ecx, ecx mov r8d, 1 call delete_head_or_tail cmp al, 0 jz short loc_58BC1 mov [rbp+var_11], 1 loc_58BC1: jmp short $+2 loc_58BC3: mov rax, [rbp+var_10] add rax, 8 mov [rbp+var_10], rax jmp short loc_58B74 loc_58BD1: jmp short $+2 loc_58BD3: mov al, [rbp+var_11] mov [rbp+var_29], al mov al, [rbp+var_29] add rsp, 30h pop rbp retn
char delete_tails(long long *a1, unsigned long long *a2) { unsigned int v2; // eax unsigned long long v4; // [rsp+10h] [rbp-20h] char v5; // [rsp+1Fh] [rbp-11h] v5 = 0; while ( *a2 ) { v4 = ma_recordpos_to_page(*a2); v2 = ma_recordpos_to_dir_entry(*a2); if ( delete_head_or_tail(a1, v4, v2, 0, 1) ) v5 = 1; ++a2; } return v5; }
delete_tails: PUSH RBP MOV RBP,RSP SUB RSP,0x30 MOV qword ptr [RBP + -0x8],RDI MOV qword ptr [RBP + -0x10],RSI MOV byte ptr [RBP + -0x11],0x0 LAB_00158b74: MOV RAX,qword ptr [RBP + -0x10] CMP qword ptr [RAX],0x0 JZ 0x00158bd1 MOV RAX,qword ptr [RBP + -0x8] MOV qword ptr [RBP + -0x28],RAX MOV RAX,qword ptr [RBP + -0x10] MOV RDI,qword ptr [RAX] CALL 0x00157f00 MOV qword ptr [RBP + -0x20],RAX MOV RAX,qword ptr [RBP + -0x10] MOV RDI,qword ptr [RAX] CALL 0x00157f20 MOV RDI,qword ptr [RBP + -0x28] MOV RSI,qword ptr [RBP + -0x20] MOV EDX,EAX XOR ECX,ECX MOV R8D,0x1 CALL 0x00157b60 CMP AL,0x0 JZ 0x00158bc1 MOV byte ptr [RBP + -0x11],0x1 LAB_00158bc1: JMP 0x00158bc3 LAB_00158bc3: MOV RAX,qword ptr [RBP + -0x10] ADD RAX,0x8 MOV qword ptr [RBP + -0x10],RAX JMP 0x00158b74 LAB_00158bd1: JMP 0x00158bd3 LAB_00158bd3: MOV AL,byte ptr [RBP + -0x11] MOV byte ptr [RBP + -0x29],AL MOV AL,byte ptr [RBP + -0x29] ADD RSP,0x30 POP RBP RET
int1 delete_tails(int8 param_1,long *param_2) { char cVar1; int4 uVar2; int8 uVar3; int1 local_19; long *local_18; local_19 = 0; for (local_18 = param_2; *local_18 != 0; local_18 = local_18 + 1) { uVar3 = ma_recordpos_to_page(*local_18); uVar2 = ma_recordpos_to_dir_entry(*local_18); cVar1 = delete_head_or_tail(param_1,uVar3,uVar2,0,1); if (cVar1 != '\0') { local_19 = 1; } } return local_19; }
6,059
my_uca_coll_init_utf8mb3
eloqsql/strings/ctype-uca.c
static my_bool my_uca_coll_init_utf8mb3(struct charset_info_st *cs, MY_CHARSET_LOADER *loader) { if (my_coll_init_uca(cs, loader)) return TRUE; if (my_uca_collation_can_optimize_no_contractions(cs)) my_uca_handler_map(cs, &my_uca_package_utf8mb3, &my_uca_package_no_contractions_utf8mb3); return FALSE; }
O0
c
my_uca_coll_init_utf8mb3: pushq %rbp movq %rsp, %rbp subq $0x20, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq -0x10(%rbp), %rdi movq -0x18(%rbp), %rsi callq 0x7fcd0 cmpb $0x0, %al je 0x81167 movb $0x1, -0x1(%rbp) jmp 0x8118f movq -0x10(%rbp), %rdi callq 0x8bcc0 cmpb $0x0, %al je 0x8118b movq -0x10(%rbp), %rdi leaq 0x286ff1(%rip), %rsi # 0x308170 leaq 0x28700a(%rip), %rdx # 0x308190 callq 0x8bd20 movb $0x0, -0x1(%rbp) movb -0x1(%rbp), %al addq $0x20, %rsp popq %rbp retq nopl (%rax,%rax)
my_uca_coll_init_utf8mb3: push rbp mov rbp, rsp sub rsp, 20h mov [rbp+var_10], rdi mov [rbp+var_18], rsi mov rdi, [rbp+var_10] mov rsi, [rbp+var_18] call my_coll_init_uca cmp al, 0 jz short loc_81167 mov [rbp+var_1], 1 jmp short loc_8118F loc_81167: mov rdi, [rbp+var_10] call my_uca_collation_can_optimize_no_contractions cmp al, 0 jz short loc_8118B mov rdi, [rbp+var_10] lea rsi, my_uca_package_utf8mb3 lea rdx, my_uca_package_no_contractions_utf8mb3 call my_uca_handler_map loc_8118B: mov [rbp+var_1], 0 loc_8118F: mov al, [rbp+var_1] add rsp, 20h pop rbp retn
char my_uca_coll_init_utf8mb3(long long a1, long long a2) { if ( (unsigned __int8)my_coll_init_uca(a1, a2) ) return 1; if ( (unsigned __int8)my_uca_collation_can_optimize_no_contractions(a1) ) my_uca_handler_map(a1, my_uca_package_utf8mb3, my_uca_package_no_contractions_utf8mb3); return 0; }
my_uca_coll_init_utf8mb3: PUSH RBP MOV RBP,RSP SUB RSP,0x20 MOV qword ptr [RBP + -0x10],RDI MOV qword ptr [RBP + -0x18],RSI MOV RDI,qword ptr [RBP + -0x10] MOV RSI,qword ptr [RBP + -0x18] CALL 0x0017fcd0 CMP AL,0x0 JZ 0x00181167 MOV byte ptr [RBP + -0x1],0x1 JMP 0x0018118f LAB_00181167: MOV RDI,qword ptr [RBP + -0x10] CALL 0x0018bcc0 CMP AL,0x0 JZ 0x0018118b MOV RDI,qword ptr [RBP + -0x10] LEA RSI,[0x408170] LEA RDX,[0x408190] CALL 0x0018bd20 LAB_0018118b: MOV byte ptr [RBP + -0x1],0x0 LAB_0018118f: MOV AL,byte ptr [RBP + -0x1] ADD RSP,0x20 POP RBP RET
int1 my_uca_coll_init_utf8mb3(int8 param_1,int8 param_2) { char cVar1; int1 local_9; cVar1 = my_coll_init_uca(param_1,param_2); if (cVar1 == '\0') { cVar1 = my_uca_collation_can_optimize_no_contractions(param_1); if (cVar1 != '\0') { my_uca_handler_map(param_1,my_uca_package_utf8mb3,my_uca_package_no_contractions_utf8mb3); } local_9 = 0; } else { local_9 = 1; } return local_9; }
6,060
hi0bits
eloqsql/strings/dtoa.c
static int hi0bits(register ULong x) { register int k= 0; if (!(x & 0xffff0000)) { k= 16; x<<= 16; } if (!(x & 0xff000000)) { k+= 8; x<<= 8; } if (!(x & 0xf0000000)) { k+= 4; x<<= 4; } if (!(x & 0xc0000000)) { k+= 2; x<<= 2; } if (!(x & 0x80000000)) { k++; if (!(x & 0x40000000)) return 32; } return k; }
O3
c
hi0bits: pushq %rbp movq %rsp, %rbp movl %edi, %eax shll $0x10, %eax xorl %ecx, %ecx cmpl $0x10000, %edi # imm = 0x10000 setb %cl cmovael %edi, %eax shll $0x4, %ecx movl %eax, %edx shll $0x8, %edx cmpl $0x1000000, %eax # imm = 0x1000000 cmovael %eax, %edx leal 0x8(%rcx), %eax cmovael %ecx, %eax movl %edx, %ecx shll $0x4, %ecx cmpl $0x10000000, %edx # imm = 0x10000000 cmovael %edx, %ecx leal 0x4(%rax), %edx cmovael %eax, %edx leal (,%rcx,4), %esi movl $0x40000000, %eax # imm = 0x40000000 cmpl %eax, %ecx cmovael %ecx, %esi leal 0x2(%rdx), %ecx cmovael %edx, %ecx leal 0x1(%rcx), %edx cmpl %eax, %esi movl $0x20, %eax cmovael %edx, %eax testl %esi, %esi cmovsl %ecx, %eax popq %rbp retq
hi0bits: push rbp mov rbp, rsp mov eax, edi shl eax, 10h xor ecx, ecx cmp edi, offset stru_10000 setb cl cmovnb eax, edi shl ecx, 4 mov edx, eax shl edx, 8 cmp eax, 1000000h cmovnb edx, eax lea eax, [rcx+8] cmovnb eax, ecx mov ecx, edx shl ecx, 4 cmp edx, 10000000h cmovnb ecx, edx lea edx, [rax+4] cmovnb edx, eax lea esi, ds:0[rcx*4] mov eax, 40000000h cmp ecx, eax cmovnb esi, ecx lea ecx, [rdx+2] cmovnb ecx, edx lea edx, [rcx+1] cmp esi, eax mov eax, 20h ; ' ' cmovnb eax, edx test esi, esi cmovs eax, ecx pop rbp retn
long long hi0bits(unsigned int a1) { unsigned int v1; // eax unsigned int v2; // edx bool v3; // cf int v4; // eax unsigned int v5; // ecx bool v6; // cf int v7; // edx int v8; // esi bool v9; // cf unsigned int v10; // ecx long long result; // rax v1 = a1 << 16; if ( a1 >= (unsigned int)&stru_10000 ) v1 = a1; v2 = v1 << 8; v3 = v1 < 0x1000000; if ( v1 >= 0x1000000 ) v2 = v1; v4 = 16 * (a1 < (unsigned int)&stru_10000) + 8; if ( !v3 ) v4 = 16 * (a1 < (unsigned int)&stru_10000); v5 = 16 * v2; v6 = v2 < 0x10000000; if ( v2 >= 0x10000000 ) v5 = v2; v7 = v4 + 4; if ( !v6 ) v7 = v4; v8 = 4 * v5; v9 = v5 < 0x40000000; if ( v5 >= 0x40000000 ) v8 = v5; v10 = v7 + 2; if ( !v9 ) v10 = v7; result = 32LL; if ( (unsigned int)v8 >= 0x40000000 ) result = v10 + 1; if ( v8 < 0 ) return v10; return result; }
hi0bits: PUSH RBP MOV RBP,RSP MOV EAX,EDI SHL EAX,0x10 XOR ECX,ECX CMP EDI,0x10000 SETC CL CMOVNC EAX,EDI SHL ECX,0x4 MOV EDX,EAX SHL EDX,0x8 CMP EAX,0x1000000 CMOVNC EDX,EAX LEA EAX,[RCX + 0x8] CMOVNC EAX,ECX MOV ECX,EDX SHL ECX,0x4 CMP EDX,0x10000000 CMOVNC ECX,EDX LEA EDX,[RAX + 0x4] CMOVNC EDX,EAX LEA ESI,[RCX*0x4] MOV EAX,0x40000000 CMP ECX,EAX CMOVNC ESI,ECX LEA ECX,[RDX + 0x2] CMOVNC ECX,EDX LEA EDX,[RCX + 0x1] CMP ESI,EAX MOV EAX,0x20 CMOVNC EAX,EDX TEST ESI,ESI CMOVS EAX,ECX POP RBP RET
int hi0bits(uint param_1) { uint uVar1; uint uVar2; int iVar3; int iVar4; uVar2 = param_1 << 0x10; if (param_1 >= 0x10000) { uVar2 = param_1; } iVar4 = (uint)(param_1 < 0x10000) * 0x10; uVar1 = uVar2 << 8; if (0xffffff < uVar2) { uVar1 = uVar2; } iVar3 = iVar4 + 8; if (0xffffff < uVar2) { iVar3 = iVar4; } uVar2 = uVar1 << 4; if (0xfffffff < uVar1) { uVar2 = uVar1; } iVar4 = iVar3 + 4; if (0xfffffff < uVar1) { iVar4 = iVar3; } uVar1 = uVar2 * 4; if (0x3fffffff < uVar2) { uVar1 = uVar2; } iVar3 = iVar4 + 2; if (0x3fffffff < uVar2) { iVar3 = iVar4; } iVar4 = 0x20; if (0x3fffffff < uVar1) { iVar4 = iVar3 + 1; } if ((int)uVar1 < 0) { iVar4 = iVar3; } return iVar4; }
6,061
bool fmt::v10::detail::dragonbox::check_divisibility_and_divide_by_pow10<2>(unsigned int&)
aimrt_mujoco_sim/_deps/fmt-src/include/fmt/format-inl.h
auto check_divisibility_and_divide_by_pow10(uint32_t& n) noexcept -> bool { // The numbers below are chosen such that: // 1. floor(n/d) = floor(nm / 2^k) where d=10 or d=100, // 2. nm mod 2^k < m if and only if n is divisible by d, // where m is magic_number, k is shift_amount // and d is divisor. // // Item 1 is a common technique of replacing division by a constant with // multiplication, see e.g. "Division by Invariant Integers Using // Multiplication" by Granlund and Montgomery (1994). magic_number (m) is set // to ceil(2^k/d) for large enough k. // The idea for item 2 originates from Schubfach. constexpr auto info = div_small_pow10_infos[N - 1]; FMT_ASSERT(n <= info.divisor * 10, "n is too large"); constexpr uint32_t magic_number = (1u << info.shift_amount) / info.divisor + 1; n *= magic_number; const uint32_t comparison_mask = (1u << info.shift_amount) - 1; bool result = (n & comparison_mask) < magic_number; n >>= info.shift_amount; return result; }
O0
c
bool fmt::v10::detail::dragonbox::check_divisibility_and_divide_by_pow10<2>(unsigned int&): subq $0x28, %rsp movq %rdi, 0x20(%rsp) movq 0x32cee8(%rip), %rax # 0x3dd1a8 movq %rax, 0x18(%rsp) movq 0x20(%rsp), %rax cmpl $0x3e8, (%rax) # imm = 0x3E8 setbe %al andb $0x1, %al movb %al, 0x17(%rsp) leaq 0x17(%rsp), %rdi leaq 0x32d5c0(%rip), %rsi # 0x3dd8a5 callq 0xa06f0 movl $0x290, 0x10(%rsp) # imm = 0x290 movq 0x20(%rsp), %rax imull $0x290, (%rax), %ecx # imm = 0x290 movl %ecx, (%rax) movl $0xffff, 0xc(%rsp) # imm = 0xFFFF movq 0x20(%rsp), %rax movl (%rax), %eax andl $0xffff, %eax # imm = 0xFFFF cmpl $0x290, %eax # imm = 0x290 setb %al andb $0x1, %al movb %al, 0xb(%rsp) movq 0x20(%rsp), %rax movl (%rax), %ecx shrl $0x10, %ecx movl %ecx, (%rax) movb 0xb(%rsp), %al andb $0x1, %al addq $0x28, %rsp retq nopl (%rax,%rax)
_ZN3fmt3v106detail9dragonbox38check_divisibility_and_divide_by_pow10ILi2EEEbRj: sub rsp, 28h mov [rsp+28h+var_8], rdi mov rax, cs:qword_3DD1A8 mov [rsp+28h+var_10], rax mov rax, [rsp+28h+var_8] cmp dword ptr [rax], 3E8h setbe al and al, 1 mov [rsp+28h+var_11], al lea rdi, [rsp+28h+var_11] lea rsi, aNIsTooLarge; "n is too large" call _ZN3fmt3v106detail13ignore_unusedIJbA15_cEEEvDpRKT_; fmt::v10::detail::ignore_unused<bool,char [15]>(bool,char [15] const&) mov [rsp+28h+var_18], 290h mov rax, [rsp+28h+var_8] imul ecx, [rax], 290h mov [rax], ecx mov [rsp+28h+var_1C], 0FFFFh mov rax, [rsp+28h+var_8] mov eax, [rax] and eax, 0FFFFh cmp eax, 290h setb al and al, 1 mov [rsp+28h+var_1D], al mov rax, [rsp+28h+var_8] mov ecx, [rax] shr ecx, 10h mov [rax], ecx mov al, [rsp+28h+var_1D] and al, 1 add rsp, 28h retn
bool fmt::v10::detail::dragonbox::check_divisibility_and_divide_by_pow10<2>(_DWORD *a1) { bool v2; // [rsp+Bh] [rbp-1Dh] fmt::v10::detail::ignore_unused<bool,char [15]>(); *a1 *= 656; v2 = (unsigned __int16)*a1 < 0x290u; *a1 >>= 16; return v2; }
check_divisibility_and_divide_by_pow10<2>: SUB RSP,0x28 MOV qword ptr [RSP + 0x20],RDI MOV RAX,qword ptr [0x004dd1a8] MOV qword ptr [RSP + 0x18],RAX MOV RAX,qword ptr [RSP + 0x20] CMP dword ptr [RAX],0x3e8 SETBE AL AND AL,0x1 MOV byte ptr [RSP + 0x17],AL LEA RDI,[RSP + 0x17] LEA RSI,[0x4dd8a5] CALL 0x001a06f0 MOV dword ptr [RSP + 0x10],0x290 MOV RAX,qword ptr [RSP + 0x20] IMUL ECX,dword ptr [RAX],0x290 MOV dword ptr [RAX],ECX MOV dword ptr [RSP + 0xc],0xffff MOV RAX,qword ptr [RSP + 0x20] MOV EAX,dword ptr [RAX] AND EAX,0xffff CMP EAX,0x290 SETC AL AND AL,0x1 MOV byte ptr [RSP + 0xb],AL MOV RAX,qword ptr [RSP + 0x20] MOV ECX,dword ptr [RAX] SHR ECX,0x10 MOV dword ptr [RAX],ECX MOV AL,byte ptr [RSP + 0xb] AND AL,0x1 ADD RSP,0x28 RET
/* bool fmt::v10::detail::dragonbox::check_divisibility_and_divide_by_pow10<2>(unsigned int&) */ bool fmt::v10::detail::dragonbox::check_divisibility_and_divide_by_pow10<2>(uint *param_1) { uint uVar1; bool local_11; int8 local_10; uint *local_8; local_10 = DAT_004dd1a8; local_11 = *param_1 < 0x3e9; local_8 = param_1; ignore_unused<bool,char[15]>(&local_11,"n is too large"); *local_8 = *local_8 * 0x290; uVar1 = *local_8; *local_8 = *local_8 >> 0x10; return (uVar1 & 0xffff) < 0x290; }
6,062
Item_window_func::is_frame_prohibited() const
eloqsql/sql/item_windowfunc.h
bool is_frame_prohibited() const { switch (window_func()->sum_func()) { case Item_sum::ROW_NUMBER_FUNC: case Item_sum::RANK_FUNC: case Item_sum::DENSE_RANK_FUNC: case Item_sum::PERCENT_RANK_FUNC: case Item_sum::CUME_DIST_FUNC: case Item_sum::NTILE_FUNC: case Item_sum::PERCENTILE_CONT_FUNC: case Item_sum::PERCENTILE_DISC_FUNC: return true; default: return false; } }
O0
c
Item_window_func::is_frame_prohibited() const: pushq %rbp movq %rsp, %rbp subq $0x20, %rsp movq %rdi, -0x10(%rbp) movq -0x10(%rbp), %rdi callq 0xc17ab0 movq %rax, %rdi movq (%rdi), %rax movq 0x628(%rax), %rax callq *%rax movl %eax, %ecx movl %ecx, %eax addl $-0xd, %eax movl %ecx, -0x14(%rbp) subl $0x6, %eax jb 0xc17cd2 jmp 0xc17cc5 movl -0x14(%rbp), %eax addl $-0x18, %eax subl $0x1, %eax ja 0xc17cd8 jmp 0xc17cd2 movb $0x1, -0x1(%rbp) jmp 0xc17cdc movb $0x0, -0x1(%rbp) movb -0x1(%rbp), %al andb $0x1, %al addq $0x20, %rsp popq %rbp retq nopw (%rax,%rax)
_ZNK16Item_window_func19is_frame_prohibitedEv: push rbp mov rbp, rsp sub rsp, 20h mov [rbp+var_10], rdi mov rdi, [rbp+var_10]; this call _ZNK16Item_window_func11window_funcEv; Item_window_func::window_func(void) mov rdi, rax mov rax, [rdi] mov rax, [rax+628h] call rax mov ecx, eax mov eax, ecx add eax, 0FFFFFFF3h mov [rbp+var_14], ecx sub eax, 6 jb short loc_C17CD2 jmp short $+2 loc_C17CC5: mov eax, [rbp+var_14] add eax, 0FFFFFFE8h sub eax, 1 ja short loc_C17CD8 jmp short $+2 loc_C17CD2: mov [rbp+var_1], 1 jmp short loc_C17CDC loc_C17CD8: mov [rbp+var_1], 0 loc_C17CDC: mov al, [rbp+var_1] and al, 1 add rsp, 20h pop rbp retn
bool Item_window_func::is_frame_prohibited(Item_window_func *this) { long long v1; // rax int v3; // [rsp+Ch] [rbp-14h] v1 = Item_window_func::window_func(this); v3 = (*(long long ( **)(long long))(*(_QWORD *)v1 + 1576LL))(v1); return (unsigned int)(v3 - 13) < 6 || (unsigned int)(v3 - 24) <= 1; }
is_with_table: PUSH RBP MOV RBP,RSP MOV qword ptr [RBP + -0x8],RDI MOV RCX,qword ptr [RBP + -0x8] MOV qword ptr [RBP + -0x18],RCX XOR EAX,EAX CMP qword ptr [RCX + 0x128],0x0 MOV byte ptr [RBP + -0x9],AL JZ 0x00c17cc8 MOV RAX,qword ptr [RBP + -0x18] MOV RAX,qword ptr [RAX + 0x128] CMP qword ptr [RAX + 0x788],0x0 SETNZ AL MOV byte ptr [RBP + -0x9],AL LAB_00c17cc8: MOV AL,byte ptr [RBP + -0x9] AND AL,0x1 POP RBP RET
/* TABLE_LIST::is_with_table() */ int8 __thiscall TABLE_LIST::is_with_table(TABLE_LIST *this) { int7 uVar1; bool local_11; uVar1 = 0; local_11 = false; if (*(long *)(this + 0x128) != 0) { local_11 = *(long *)(*(long *)(this + 0x128) + 0x788) != 0; uVar1 = (int7)((ulong)*(long *)(this + 0x128) >> 8); } return CONCAT71(uVar1,local_11); }
6,063
ggml_compute_fp32_to_fp16
monkey531[P]llama/ggml/src/ggml-impl.h
static inline ggml_fp16_t ggml_compute_fp32_to_fp16(float f) { #if (defined(__STDC_VERSION__) && (__STDC_VERSION__ >= 199901L) || defined(__GNUC__) && !defined(__STRICT_ANSI__)) && (!defined(__cplusplus) || __cplusplus >= 201703L) const float scale_to_inf = 0x1.0p+112f; const float scale_to_zero = 0x1.0p-110f; #else const float scale_to_inf = fp32_from_bits(UINT32_C(0x77800000)); const float scale_to_zero = fp32_from_bits(UINT32_C(0x08800000)); #endif float base = (fabsf(f) * scale_to_inf) * scale_to_zero; const uint32_t w = fp32_to_bits(f); const uint32_t shl1_w = w + w; const uint32_t sign = w & UINT32_C(0x80000000); uint32_t bias = shl1_w & UINT32_C(0xFF000000); if (bias < UINT32_C(0x71000000)) { bias = UINT32_C(0x71000000); } base = fp32_from_bits((bias >> 1) + UINT32_C(0x07800000)) + base; const uint32_t bits = fp32_to_bits(base); const uint32_t exp_bits = (bits >> 13) & UINT32_C(0x00007C00); const uint32_t mantissa_bits = bits & UINT32_C(0x00000FFF); const uint32_t nonsign = exp_bits + mantissa_bits; return (sign >> 16) | (shl1_w > UINT32_C(0xFF000000) ? UINT16_C(0x7E00) : nonsign); }
O0
c
ggml_compute_fp32_to_fp16: subq $0x38, %rsp movss %xmm0, 0x34(%rsp) movss 0x45f8a(%rip), %xmm0 # 0xb441c movss %xmm0, 0x30(%rsp) movss 0x45f78(%rip), %xmm0 # 0xb4418 movss %xmm0, 0x2c(%rsp) movss 0x34(%rsp), %xmm0 movaps 0x45b7d(%rip), %xmm1 # 0xb4030 pand %xmm1, %xmm0 movss 0x45f5d(%rip), %xmm1 # 0xb441c mulss %xmm1, %xmm0 movss 0x45f4d(%rip), %xmm1 # 0xb4418 mulss %xmm1, %xmm0 movss %xmm0, 0x28(%rsp) movss 0x34(%rsp), %xmm0 callq 0x8a610 movl %eax, 0x24(%rsp) movl 0x24(%rsp), %eax addl 0x24(%rsp), %eax movl %eax, 0x20(%rsp) movl 0x24(%rsp), %eax andl $0x80000000, %eax # imm = 0x80000000 movl %eax, 0x1c(%rsp) movl 0x20(%rsp), %eax andl $0xff000000, %eax # imm = 0xFF000000 movl %eax, 0x18(%rsp) cmpl $0x71000000, 0x18(%rsp) # imm = 0x71000000 jae 0x6e51c movl $0x71000000, 0x18(%rsp) # imm = 0x71000000 movl 0x18(%rsp), %edi shrl %edi addl $0x7800000, %edi # imm = 0x7800000 callq 0x8a630 addss 0x28(%rsp), %xmm0 movss %xmm0, 0x28(%rsp) movss 0x28(%rsp), %xmm0 callq 0x8a610 movl %eax, 0x14(%rsp) movl 0x14(%rsp), %eax shrl $0xd, %eax andl $0x7c00, %eax # imm = 0x7C00 movl %eax, 0x10(%rsp) movl 0x14(%rsp), %eax andl $0xfff, %eax # imm = 0xFFF movl %eax, 0xc(%rsp) movl 0x10(%rsp), %eax addl 0xc(%rsp), %eax movl %eax, 0x8(%rsp) movl 0x1c(%rsp), %eax shrl $0x10, %eax movl %eax, 0x4(%rsp) cmpl $0xff000000, 0x20(%rsp) # imm = 0xFF000000 jbe 0x6e590 movl $0x7e00, %eax # imm = 0x7E00 movl %eax, (%rsp) jmp 0x6e597 movl 0x8(%rsp), %eax movl %eax, (%rsp) movl 0x4(%rsp), %eax movl (%rsp), %ecx orl %ecx, %eax addq $0x38, %rsp retq nopw %cs:(%rax,%rax)
ggml_compute_fp32_to_fp16_0: sub rsp, 38h movss [rsp+38h+var_4], xmm0 movss xmm0, cs:dword_B441C movss [rsp+38h+var_8], xmm0 movss xmm0, cs:dword_B4418 movss [rsp+38h+var_C], xmm0 movss xmm0, [rsp+38h+var_4] movaps xmm1, cs:xmmword_B4030 pand xmm0, xmm1 movss xmm1, cs:dword_B441C mulss xmm0, xmm1 movss xmm1, cs:dword_B4418 mulss xmm0, xmm1 movss [rsp+38h+var_10], xmm0 movss xmm0, [rsp+38h+var_4] call fp32_to_bits_0 mov [rsp+38h+var_14], eax mov eax, [rsp+38h+var_14] add eax, [rsp+38h+var_14] mov [rsp+38h+var_18], eax mov eax, [rsp+38h+var_14] and eax, 80000000h mov [rsp+38h+var_1C], eax mov eax, [rsp+38h+var_18] and eax, 0FF000000h mov [rsp+38h+var_20], eax cmp [rsp+38h+var_20], 71000000h jnb short loc_6E51C mov [rsp+38h+var_20], 71000000h loc_6E51C: mov edi, [rsp+38h+var_20] shr edi, 1 add edi, 7800000h call fp32_from_bits_0 addss xmm0, [rsp+38h+var_10] movss [rsp+38h+var_10], xmm0 movss xmm0, [rsp+38h+var_10] call fp32_to_bits_0 mov [rsp+38h+var_24], eax mov eax, [rsp+38h+var_24] shr eax, 0Dh and eax, 7C00h mov [rsp+38h+var_28], eax mov eax, [rsp+38h+var_24] and eax, 0FFFh mov [rsp+38h+var_2C], eax mov eax, [rsp+38h+var_28] add eax, [rsp+38h+var_2C] mov [rsp+38h+var_30], eax mov eax, [rsp+38h+var_1C] shr eax, 10h mov [rsp+38h+var_34], eax cmp [rsp+38h+var_18], 0FF000000h jbe short loc_6E590 mov eax, 7E00h mov [rsp+38h+var_38], eax jmp short loc_6E597 loc_6E590: mov eax, [rsp+38h+var_30] mov [rsp+38h+var_38], eax loc_6E597: mov eax, [rsp+38h+var_34] mov ecx, [rsp+38h+var_38] or eax, ecx add rsp, 38h retn
long long ggml_compute_fp32_to_fp16_0(float a1) { int v2; // [rsp+0h] [rbp-38h] unsigned int v3; // [rsp+14h] [rbp-24h] unsigned int v4; // [rsp+18h] [rbp-20h] int v5; // [rsp+24h] [rbp-14h] float v6; // [rsp+28h] [rbp-10h] float v7; // [rsp+28h] [rbp-10h] v6 = (float)(*(float *)_mm_and_si128((__m128i)LODWORD(a1), (__m128i)xmmword_B4030).m128i_i32 * 5.1922969e33) * 7.7037198e-34; v5 = fp32_to_bits_0(a1); v4 = (2 * v5) & 0xFF000000; if ( v4 < 0x71000000 ) v4 = 1895825408; v7 = fp32_from_bits_0((v4 >> 1) + 125829120) + v6; v3 = fp32_to_bits_0(v7); if ( (unsigned int)(2 * v5) <= 0xFF000000 ) v2 = (v3 & 0xFFF) + ((v3 >> 13) & 0x7C00); else v2 = 32256; return v2 | ((v5 & 0x80000000) >> 16); }
ggml_compute_fp32_to_fp16: SUB RSP,0x38 MOVSS dword ptr [RSP + 0x34],XMM0 MOVSS XMM0,dword ptr [0x001b441c] MOVSS dword ptr [RSP + 0x30],XMM0 MOVSS XMM0,dword ptr [0x001b4418] MOVSS dword ptr [RSP + 0x2c],XMM0 MOVSS XMM0,dword ptr [RSP + 0x34] MOVAPS XMM1,xmmword ptr [0x001b4030] PAND XMM0,XMM1 MOVSS XMM1,dword ptr [0x001b441c] MULSS XMM0,XMM1 MOVSS XMM1,dword ptr [0x001b4418] MULSS XMM0,XMM1 MOVSS dword ptr [RSP + 0x28],XMM0 MOVSS XMM0,dword ptr [RSP + 0x34] CALL 0x0018a610 MOV dword ptr [RSP + 0x24],EAX MOV EAX,dword ptr [RSP + 0x24] ADD EAX,dword ptr [RSP + 0x24] MOV dword ptr [RSP + 0x20],EAX MOV EAX,dword ptr [RSP + 0x24] AND EAX,0x80000000 MOV dword ptr [RSP + 0x1c],EAX MOV EAX,dword ptr [RSP + 0x20] AND EAX,0xff000000 MOV dword ptr [RSP + 0x18],EAX CMP dword ptr [RSP + 0x18],0x71000000 JNC 0x0016e51c MOV dword ptr [RSP + 0x18],0x71000000 LAB_0016e51c: MOV EDI,dword ptr [RSP + 0x18] SHR EDI,0x1 ADD EDI,0x7800000 CALL 0x0018a630 ADDSS XMM0,dword ptr [RSP + 0x28] MOVSS dword ptr [RSP + 0x28],XMM0 MOVSS XMM0,dword ptr [RSP + 0x28] CALL 0x0018a610 MOV dword ptr [RSP + 0x14],EAX MOV EAX,dword ptr [RSP + 0x14] SHR EAX,0xd AND EAX,0x7c00 MOV dword ptr [RSP + 0x10],EAX MOV EAX,dword ptr [RSP + 0x14] AND EAX,0xfff MOV dword ptr [RSP + 0xc],EAX MOV EAX,dword ptr [RSP + 0x10] ADD EAX,dword ptr [RSP + 0xc] MOV dword ptr [RSP + 0x8],EAX MOV EAX,dword ptr [RSP + 0x1c] SHR EAX,0x10 MOV dword ptr [RSP + 0x4],EAX CMP dword ptr [RSP + 0x20],0xff000000 JBE 0x0016e590 MOV EAX,0x7e00 MOV dword ptr [RSP],EAX JMP 0x0016e597 LAB_0016e590: MOV EAX,dword ptr [RSP + 0x8] MOV dword ptr [RSP],EAX LAB_0016e597: MOV EAX,dword ptr [RSP + 0x4] MOV ECX,dword ptr [RSP] OR EAX,ECX ADD RSP,0x38 RET
/* WARNING: Globals starting with '_' overlap smaller symbols at the same address */ uint ggml_compute_fp32_to_fp16(void) { uint uVar1; uint uVar2; uint local_38; uint local_20; uVar1 = fp32_to_bits(); local_20 = uVar1 * 2 & 0xff000000; if (local_20 < 0x71000000) { local_20 = 0x71000000; } fp32_from_bits((local_20 >> 1) + 0x7800000); uVar2 = fp32_to_bits(); local_38 = (uVar2 >> 0xd & 0x7c00) + (uVar2 & 0xfff); if (0xff000000 < uVar1 * 2) { local_38 = 0x7e00; } return (uVar1 & 0x80000000) >> 0x10 | local_38; }
6,064
ma_get_status
eloqsql/storage/maria/ma_state.c
my_bool _ma_get_status(void* param, my_bool concurrent_insert) { MARIA_HA *info=(MARIA_HA*) param; DBUG_ENTER("_ma_get_status"); DBUG_PRINT("info",("key_file: %ld data_file: %ld concurrent_insert: %d", (long) info->s->state.state.key_file_length, (long) info->s->state.state.data_file_length, concurrent_insert)); #ifndef DBUG_OFF if (info->state->key_file_length > info->s->state.state.key_file_length || info->state->data_file_length > info->s->state.state.data_file_length) DBUG_PRINT("warning",("old info: key_file: %ld data_file: %ld", (long) info->state->key_file_length, (long) info->state->data_file_length)); #endif info->state_save= info->s->state.state; info->state= &info->state_save; info->state->changed= 0; info->append_insert_at_end= concurrent_insert; DBUG_RETURN(0); }
O0
c
ma_get_status: pushq %rbp movq %rsp, %rbp subq $0x20, %rsp movb %sil, %al movq %rdi, -0x8(%rbp) movb %al, -0x9(%rbp) movq -0x8(%rbp), %rax movq %rax, -0x18(%rbp) jmp 0x3684c movq -0x18(%rbp), %rdi addq $0x28, %rdi movq -0x18(%rbp), %rax movq (%rax), %rsi addq $0x18, %rsi movl $0x38, %edx callq 0x2a090 movq -0x18(%rbp), %rcx addq $0x28, %rcx movq -0x18(%rbp), %rax movq %rcx, 0x20(%rax) movq -0x18(%rbp), %rax movq 0x20(%rax), %rax movb 0x34(%rax), %cl andb $-0x2, %cl orb $0x0, %cl movb %cl, 0x34(%rax) movb -0x9(%rbp), %cl movq -0x18(%rbp), %rax movb %cl, 0x681(%rax) jmp 0x3689c xorl %eax, %eax addq $0x20, %rsp popq %rbp retq nopw %cs:(%rax,%rax)
_ma_get_status: push rbp mov rbp, rsp sub rsp, 20h mov al, sil mov [rbp+var_8], rdi mov [rbp+var_9], al mov rax, [rbp+var_8] mov [rbp+var_18], rax jmp short $+2 loc_3684C: mov rdi, [rbp+var_18] add rdi, 28h ; '(' mov rax, [rbp+var_18] mov rsi, [rax] add rsi, 18h mov edx, 38h ; '8' call _memcpy mov rcx, [rbp+var_18] add rcx, 28h ; '(' mov rax, [rbp+var_18] mov [rax+20h], rcx mov rax, [rbp+var_18] mov rax, [rax+20h] mov cl, [rax+34h] and cl, 0FEh or cl, 0 mov [rax+34h], cl mov cl, [rbp+var_9] mov rax, [rbp+var_18] mov [rax+681h], cl jmp short $+2 loc_3689C: xor eax, eax add rsp, 20h pop rbp retn
long long ma_get_status(long long a1, char a2) { memcpy(a1 + 40, *(_QWORD *)a1 + 24LL, 56LL); *(_QWORD *)(a1 + 32) = a1 + 40; *(_BYTE *)(*(_QWORD *)(a1 + 32) + 52LL) &= ~1u; *(_BYTE *)(a1 + 1665) = a2; return 0LL; }
_ma_get_status: PUSH RBP MOV RBP,RSP SUB RSP,0x20 MOV AL,SIL MOV qword ptr [RBP + -0x8],RDI MOV byte ptr [RBP + -0x9],AL MOV RAX,qword ptr [RBP + -0x8] MOV qword ptr [RBP + -0x18],RAX JMP 0x0013684c LAB_0013684c: MOV RDI,qword ptr [RBP + -0x18] ADD RDI,0x28 MOV RAX,qword ptr [RBP + -0x18] MOV RSI,qword ptr [RAX] ADD RSI,0x18 MOV EDX,0x38 CALL 0x0012a090 MOV RCX,qword ptr [RBP + -0x18] ADD RCX,0x28 MOV RAX,qword ptr [RBP + -0x18] MOV qword ptr [RAX + 0x20],RCX MOV RAX,qword ptr [RBP + -0x18] MOV RAX,qword ptr [RAX + 0x20] MOV CL,byte ptr [RAX + 0x34] AND CL,0xfe OR CL,0x0 MOV byte ptr [RAX + 0x34],CL MOV CL,byte ptr [RBP + -0x9] MOV RAX,qword ptr [RBP + -0x18] MOV byte ptr [RAX + 0x681],CL JMP 0x0013689c LAB_0013689c: XOR EAX,EAX ADD RSP,0x20 POP RBP RET
int8 _ma_get_status(long *param_1,int1 param_2) { memcpy(param_1 + 5,(void *)(*param_1 + 0x18),0x38); param_1[4] = (long)(param_1 + 5); *(byte *)(param_1[4] + 0x34) = *(byte *)(param_1[4] + 0x34) & 0xfe; *(int1 *)((long)param_1 + 0x681) = param_2; return 0; }
6,065
strxnmov
eloqsql/strings/strxnmov.c
char *strxnmov(char *dst, size_t len, const char *src, ...) { va_list pvar; char *end_of_dst=dst+len; va_start(pvar,src); while (src != NullS) { do { if (dst == end_of_dst) goto end; } while ((*dst++ = *src++)); dst--; src = va_arg(pvar, char *); } end: *dst=0; va_end(pvar); return dst; }
O0
c
strxnmov: pushq %rbp movq %rsp, %rbp subq $0x90, %rsp testb %al, %al je 0xcab1b movaps %xmm0, -0xc0(%rbp) movaps %xmm1, -0xb0(%rbp) movaps %xmm2, -0xa0(%rbp) movaps %xmm3, -0x90(%rbp) movaps %xmm4, -0x80(%rbp) movaps %xmm5, -0x70(%rbp) movaps %xmm6, -0x60(%rbp) movaps %xmm7, -0x50(%rbp) movq %r9, -0xc8(%rbp) movq %r8, -0xd0(%rbp) movq %rcx, -0xd8(%rbp) movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq %rdx, -0x18(%rbp) movq -0x8(%rbp), %rax addq -0x10(%rbp), %rax movq %rax, -0x38(%rbp) leaq -0x30(%rbp), %rax leaq -0xf0(%rbp), %rcx movq %rcx, 0x10(%rax) leaq 0x10(%rbp), %rcx movq %rcx, 0x8(%rax) movl $0x30, 0x4(%rax) movl $0x18, (%rax) cmpq $0x0, -0x18(%rbp) je 0xcac27 jmp 0xcab79 movq -0x8(%rbp), %rax cmpq -0x38(%rbp), %rax jne 0xcab88 jmp 0xcac29 jmp 0xcab8a movq -0x18(%rbp), %rax movq %rax, %rcx addq $0x1, %rcx movq %rcx, -0x18(%rbp) movb (%rax), %al movq -0x8(%rbp), %rcx movq %rcx, %rdx addq $0x1, %rdx movq %rdx, -0x8(%rbp) movb %al, (%rcx) cmpb $0x0, %al jne 0xcab79 movq -0x8(%rbp), %rax addq $-0x1, %rax movq %rax, -0x8(%rbp) leaq -0x30(%rbp), %rax movq %rax, -0x100(%rbp) movl -0x30(%rbp), %eax movl %eax, -0xf4(%rbp) cmpl $0x28, %eax ja 0xcabf7 movq -0x100(%rbp), %rcx movl -0xf4(%rbp), %edx movslq %edx, %rax addq 0x10(%rcx), %rax addl $0x8, %edx movl %edx, (%rcx) movq %rax, -0x108(%rbp) jmp 0xcac14 movq -0x100(%rbp), %rcx movq 0x8(%rcx), %rax movq %rax, %rdx addq $0x8, %rdx movq %rdx, 0x8(%rcx) movq %rax, -0x108(%rbp) movq -0x108(%rbp), %rax movq (%rax), %rax movq %rax, -0x18(%rbp) jmp 0xcab6c jmp 0xcac29 movq -0x8(%rbp), %rax movb $0x0, (%rax) movq -0x8(%rbp), %rax addq $0x90, %rsp popq %rbp retq nopl (%rax)
strxnmov: push rbp mov rbp, rsp sub rsp, 90h test al, al jz short loc_CAB1B movaps [rbp+var_C0], xmm0 movaps [rbp+var_B0], xmm1 movaps [rbp+var_A0], xmm2 movaps [rbp+var_90], xmm3 movaps [rbp+var_80], xmm4 movaps [rbp+var_70], xmm5 movaps [rbp+var_60], xmm6 movaps [rbp+var_50], xmm7 loc_CAB1B: mov [rbp+var_C8], r9 mov [rbp+var_D0], r8 mov [rbp+var_D8], rcx mov [rbp+var_8], rdi mov [rbp+var_10], rsi mov [rbp+var_18], rdx mov rax, [rbp+var_8] add rax, [rbp+var_10] mov [rbp+var_38], rax lea rax, [rbp+var_30] lea rcx, [rbp+var_F0] mov [rax+10h], rcx lea rcx, [rbp+arg_0] mov [rax+8], rcx mov dword ptr [rax+4], 30h ; '0' mov dword ptr [rax], 18h loc_CAB6C: cmp [rbp+var_18], 0 jz loc_CAC27 jmp short $+2 loc_CAB79: mov rax, [rbp+var_8] cmp rax, [rbp+var_38] jnz short loc_CAB88 jmp loc_CAC29 loc_CAB88: jmp short $+2 loc_CAB8A: mov rax, [rbp+var_18] mov rcx, rax add rcx, 1 mov [rbp+var_18], rcx mov al, [rax] mov rcx, [rbp+var_8] mov rdx, rcx add rdx, 1 mov [rbp+var_8], rdx mov [rcx], al cmp al, 0 jnz short loc_CAB79 mov rax, [rbp+var_8] add rax, 0FFFFFFFFFFFFFFFFh mov [rbp+var_8], rax lea rax, [rbp+var_30] mov [rbp+var_100], rax mov eax, [rbp+var_30] mov [rbp+var_F4], eax cmp eax, 28h ; '(' ja short loc_CABF7 mov rcx, [rbp+var_100] mov edx, [rbp+var_F4] movsxd rax, edx add rax, [rcx+10h] add edx, 8 mov [rcx], edx mov [rbp+var_108], rax jmp short loc_CAC14 loc_CABF7: mov rcx, [rbp+var_100] mov rax, [rcx+8] mov rdx, rax add rdx, 8 mov [rcx+8], rdx mov [rbp+var_108], rax loc_CAC14: mov rax, [rbp+var_108] mov rax, [rax] mov [rbp+var_18], rax jmp loc_CAB6C loc_CAC27: jmp short $+2 loc_CAC29: mov rax, [rbp+var_8] mov byte ptr [rax], 0 mov rax, [rbp+var_8] add rsp, 90h pop rbp retn
_BYTE * strxnmov( _BYTE *a1, long long a2, _BYTE *a3, long long a4, long long a5, long long a6, __m128 a7, __m128 a8, __m128 a9, __m128 a10, __m128 a11, __m128 a12, __m128 a13, __m128 a14, char a15) { _BYTE *v15; // rax _BYTE *v16; // rcx char *v17; // rax char v19; // [rsp+18h] [rbp-F0h] BYREF long long v20; // [rsp+30h] [rbp-D8h] long long v21; // [rsp+38h] [rbp-D0h] long long v22; // [rsp+40h] [rbp-C8h] __m128 v23; // [rsp+48h] [rbp-C0h] __m128 v24; // [rsp+58h] [rbp-B0h] __m128 v25; // [rsp+68h] [rbp-A0h] __m128 v26; // [rsp+78h] [rbp-90h] __m128 v27; // [rsp+88h] [rbp-80h] __m128 v28; // [rsp+98h] [rbp-70h] __m128 v29; // [rsp+A8h] [rbp-60h] __m128 v30; // [rsp+B8h] [rbp-50h] _BYTE *v31; // [rsp+D0h] [rbp-38h] int v32; // [rsp+D8h] [rbp-30h] int v33; // [rsp+DCh] [rbp-2Ch] char *v34; // [rsp+E0h] [rbp-28h] char *v35; // [rsp+E8h] [rbp-20h] _BYTE *v36; // [rsp+F0h] [rbp-18h] long long v37; // [rsp+F8h] [rbp-10h] _BYTE *v38; // [rsp+100h] [rbp-8h] v23 = a7; v24 = a8; v25 = a9; v26 = a10; v27 = a11; v28 = a12; v29 = a13; v30 = a14; v22 = a6; v21 = a5; v20 = a4; v38 = a1; v37 = a2; v36 = a3; v31 = &a1[a2]; v35 = &v19; v34 = &a15; v33 = 48; v32 = 24; LABEL_2: if ( v36 ) { while ( v38 != v31 ) { v15 = v36++; LOBYTE(v15) = *v15; v16 = v38++; *v16 = (_BYTE)v15; if ( !(_BYTE)v15 ) { --v38; if ( (unsigned int)v32 > 0x28 ) { v17 = v34; v34 += 8; } else { v17 = &v35[v32]; v32 += 8; } v36 = *(_BYTE **)v17; goto LABEL_2; } } } *v38 = 0; return v38; }
strxnmov: PUSH RBP MOV RBP,RSP SUB RSP,0x90 TEST AL,AL JZ 0x001cab1b MOVAPS xmmword ptr [RBP + -0xc0],XMM0 MOVAPS xmmword ptr [RBP + -0xb0],XMM1 MOVAPS xmmword ptr [RBP + -0xa0],XMM2 MOVAPS xmmword ptr [RBP + -0x90],XMM3 MOVAPS xmmword ptr [RBP + -0x80],XMM4 MOVAPS xmmword ptr [RBP + -0x70],XMM5 MOVAPS xmmword ptr [RBP + -0x60],XMM6 MOVAPS xmmword ptr [RBP + -0x50],XMM7 LAB_001cab1b: MOV qword ptr [RBP + -0xc8],R9 MOV qword ptr [RBP + -0xd0],R8 MOV qword ptr [RBP + -0xd8],RCX MOV qword ptr [RBP + -0x8],RDI MOV qword ptr [RBP + -0x10],RSI MOV qword ptr [RBP + -0x18],RDX MOV RAX,qword ptr [RBP + -0x8] ADD RAX,qword ptr [RBP + -0x10] MOV qword ptr [RBP + -0x38],RAX LEA RAX,[RBP + -0x30] LEA RCX,[RBP + -0xf0] MOV qword ptr [RAX + 0x10],RCX LEA RCX,[RBP + 0x10] MOV qword ptr [RAX + 0x8],RCX MOV dword ptr [RAX + 0x4],0x30 MOV dword ptr [RAX],0x18 LAB_001cab6c: CMP qword ptr [RBP + -0x18],0x0 JZ 0x001cac27 JMP 0x001cab79 LAB_001cab79: MOV RAX,qword ptr [RBP + -0x8] CMP RAX,qword ptr [RBP + -0x38] JNZ 0x001cab88 JMP 0x001cac29 LAB_001cab88: JMP 0x001cab8a LAB_001cab8a: MOV RAX,qword ptr [RBP + -0x18] MOV RCX,RAX ADD RCX,0x1 MOV qword ptr [RBP + -0x18],RCX MOV AL,byte ptr [RAX] MOV RCX,qword ptr [RBP + -0x8] MOV RDX,RCX ADD RDX,0x1 MOV qword ptr [RBP + -0x8],RDX MOV byte ptr [RCX],AL CMP AL,0x0 JNZ 0x001cab79 MOV RAX,qword ptr [RBP + -0x8] ADD RAX,-0x1 MOV qword ptr [RBP + -0x8],RAX LEA RAX,[RBP + -0x30] MOV qword ptr [RBP + -0x100],RAX MOV EAX,dword ptr [RBP + -0x30] MOV dword ptr [RBP + -0xf4],EAX CMP EAX,0x28 JA 0x001cabf7 MOV RCX,qword ptr [RBP + -0x100] MOV EDX,dword ptr [RBP + -0xf4] MOVSXD RAX,EDX ADD RAX,qword ptr [RCX + 0x10] ADD EDX,0x8 MOV dword ptr [RCX],EDX MOV qword ptr [RBP + -0x108],RAX JMP 0x001cac14 LAB_001cabf7: MOV RCX,qword ptr [RBP + -0x100] MOV RAX,qword ptr [RCX + 0x8] MOV RDX,RAX ADD RDX,0x8 MOV qword ptr [RCX + 0x8],RDX MOV qword ptr [RBP + -0x108],RAX LAB_001cac14: MOV RAX,qword ptr [RBP + -0x108] MOV RAX,qword ptr [RAX] MOV qword ptr [RBP + -0x18],RAX JMP 0x001cab6c LAB_001cac27: JMP 0x001cac29 LAB_001cac29: MOV RAX,qword ptr [RBP + -0x8] MOV byte ptr [RAX],0x0 MOV RAX,qword ptr [RBP + -0x8] ADD RSP,0x90 POP RBP RET
/* WARNING: Restarted to delay deadcode elimination for space: stack */ char * strxnmov(char *param_1,long param_2,char *param_3) { char cVar1; char *pcVar2; int8 *local_110; int8 local_f8 [24]; uint local_38; int8 *local_30; char *local_20; char *local_10; local_30 = (int8 *)&stack0x00000008; local_38 = 0x18; local_20 = param_3; local_10 = param_1; while (pcVar2 = local_10, local_20 != (char *)0x0) { do { local_10 = pcVar2; if (local_10 == param_1 + param_2) goto LAB_001cac29; cVar1 = *local_20; *local_10 = cVar1; local_20 = local_20 + 1; pcVar2 = local_10 + 1; } while (cVar1 != '\0'); if (local_38 < 0x29) { local_110 = (int8 *)((long)local_f8 + (long)(int)local_38); local_38 = local_38 + 8; } else { local_110 = local_30; local_30 = local_30 + 1; } local_20 = (char *)*local_110; } LAB_001cac29: *local_10 = '\0'; return local_10; }
6,066
mi_keydef_read
eloqsql/storage/myisam/mi_open.c
uchar *mi_keydef_read(uchar *ptr, MI_KEYDEF *keydef) { keydef->keysegs = (uint) *ptr++; keydef->key_alg = *ptr++; /* Rtree or Btree */ keydef->flag = mi_uint2korr(ptr); ptr +=2; keydef->block_length = mi_uint2korr(ptr); ptr +=2; keydef->keylength = mi_uint2korr(ptr); ptr +=2; keydef->minlength = mi_uint2korr(ptr); ptr +=2; keydef->maxlength = mi_uint2korr(ptr); ptr +=2; keydef->block_size_index= keydef->block_length/MI_MIN_KEY_BLOCK_LENGTH-1; keydef->underflow_block_length=keydef->block_length/3; keydef->version = 0; /* Not saved */ keydef->parser = &ft_default_parser; keydef->ftkey_nr = 0; return ptr; }
O0
c
mi_keydef_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) movzbl (%rax), %eax movw %ax, %cx movq -0x10(%rbp), %rax movw %cx, 0x8(%rax) movq -0x8(%rbp), %rax movq %rax, %rcx addq $0x1, %rcx movq %rcx, -0x8(%rbp) movb (%rax), %cl movq -0x10(%rbp), %rax movb %cl, 0xc(%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, 0xa(%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, 0xe(%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, 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 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, 0x16(%rax) movq -0x8(%rbp), %rax addq $0x2, %rax movq %rax, -0x8(%rbp) movq -0x10(%rbp), %rax movzwl 0xe(%rax), %eax movl $0x400, %ecx # imm = 0x400 cltd idivl %ecx subl $0x1, %eax movw %ax, %cx movq -0x10(%rbp), %rax movw %cx, 0x18(%rax) movq -0x10(%rbp), %rax movzwl 0xe(%rax), %eax movl $0x3, %ecx cltd idivl %ecx movw %ax, %cx movq -0x10(%rbp), %rax movw %cx, 0x10(%rax) movq -0x10(%rbp), %rax movl $0x0, 0x1c(%rax) movq -0x10(%rbp), %rax leaq 0x20920b(%rip), %rcx # 0x2bf300 movq %rcx, 0x38(%rax) movq -0x10(%rbp), %rax movl $0x0, 0x20(%rax) movq -0x8(%rbp), %rax popq %rbp retq nopw (%rax,%rax)
mi_keydef_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 movzx eax, byte ptr [rax] mov cx, ax mov rax, [rbp+var_10] mov [rax+8], 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+0Ch], 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+0Ah], 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+0Eh], 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+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 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+16h], cx mov rax, [rbp+var_8] add rax, 2 mov [rbp+var_8], rax mov rax, [rbp+var_10] movzx eax, word ptr [rax+0Eh] mov ecx, 400h cdq idiv ecx sub eax, 1 mov cx, ax mov rax, [rbp+var_10] mov [rax+18h], cx mov rax, [rbp+var_10] movzx eax, word ptr [rax+0Eh] mov ecx, 3 cdq idiv ecx mov cx, ax mov rax, [rbp+var_10] mov [rax+10h], cx mov rax, [rbp+var_10] mov dword ptr [rax+1Ch], 0 mov rax, [rbp+var_10] lea rcx, ft_default_parser mov [rax+38h], rcx mov rax, [rbp+var_10] mov dword ptr [rax+20h], 0 mov rax, [rbp+var_8] pop rbp retn
unsigned __int8 * mi_keydef_read(unsigned __int8 *a1, long long a2) { *(_WORD *)(a2 + 8) = *a1; *(_BYTE *)(a2 + 12) = a1[1]; *(_WORD *)(a2 + 10) = _byteswap_ushort(*((_WORD *)a1 + 1)); *(_WORD *)(a2 + 14) = _byteswap_ushort(*((_WORD *)a1 + 2)); *(_WORD *)(a2 + 18) = _byteswap_ushort(*((_WORD *)a1 + 3)); *(_WORD *)(a2 + 20) = _byteswap_ushort(*((_WORD *)a1 + 4)); *(_WORD *)(a2 + 22) = _byteswap_ushort(*((_WORD *)a1 + 5)); *(_WORD *)(a2 + 24) = *(unsigned __int16 *)(a2 + 14) / 1024 - 1; *(_WORD *)(a2 + 16) = *(unsigned __int16 *)(a2 + 14) / 3; *(_DWORD *)(a2 + 28) = 0; *(_QWORD *)(a2 + 56) = &ft_default_parser; *(_DWORD *)(a2 + 32) = 0; return a1 + 12; }
mi_keydef_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 MOVZX EAX,byte ptr [RAX] MOV CX,AX MOV RAX,qword ptr [RBP + -0x10] MOV word ptr [RAX + 0x8],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 + 0xc],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 + 0xa],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 + 0xe],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 + 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 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 + 0x16],CX MOV RAX,qword ptr [RBP + -0x8] ADD RAX,0x2 MOV qword ptr [RBP + -0x8],RAX MOV RAX,qword ptr [RBP + -0x10] MOVZX EAX,word ptr [RAX + 0xe] MOV ECX,0x400 CDQ IDIV ECX SUB EAX,0x1 MOV CX,AX MOV RAX,qword ptr [RBP + -0x10] MOV word ptr [RAX + 0x18],CX MOV RAX,qword ptr [RBP + -0x10] MOVZX EAX,word ptr [RAX + 0xe] MOV ECX,0x3 CDQ IDIV ECX 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 + 0x1c],0x0 MOV RAX,qword ptr [RBP + -0x10] LEA RCX,[0x3bf300] MOV qword ptr [RAX + 0x38],RCX MOV RAX,qword ptr [RBP + -0x10] MOV dword ptr [RAX + 0x20],0x0 MOV RAX,qword ptr [RBP + -0x8] POP RBP RET
int1 [16] mi_keydef_read(byte *param_1,long param_2) { int1 auVar1 [16]; *(ushort *)(param_2 + 8) = (ushort)*param_1; *(byte *)(param_2 + 0xc) = param_1[1]; *(ushort *)(param_2 + 10) = CONCAT11(param_1[2],param_1[3]); *(ushort *)(param_2 + 0xe) = CONCAT11(param_1[4],param_1[5]); *(ushort *)(param_2 + 0x12) = CONCAT11(param_1[6],param_1[7]); *(ushort *)(param_2 + 0x14) = CONCAT11(param_1[8],param_1[9]); *(ushort *)(param_2 + 0x16) = CONCAT11(param_1[10],param_1[0xb]); auVar1._0_8_ = param_1 + 0xc; *(ushort *)(param_2 + 0x18) = *(ushort *)(param_2 + 0xe) / 0x400 - 1; *(ushort *)(param_2 + 0x10) = *(ushort *)(param_2 + 0xe) / 3; *(int4 *)(param_2 + 0x1c) = 0; *(int1 **)(param_2 + 0x38) = ft_default_parser; *(int4 *)(param_2 + 0x20) = 0; auVar1._8_8_ = (ulong)*(ushort *)(param_2 + 0xe) % 3; return auVar1; }
6,067
mi_keydef_read
eloqsql/storage/myisam/mi_open.c
uchar *mi_keydef_read(uchar *ptr, MI_KEYDEF *keydef) { keydef->keysegs = (uint) *ptr++; keydef->key_alg = *ptr++; /* Rtree or Btree */ keydef->flag = mi_uint2korr(ptr); ptr +=2; keydef->block_length = mi_uint2korr(ptr); ptr +=2; keydef->keylength = mi_uint2korr(ptr); ptr +=2; keydef->minlength = mi_uint2korr(ptr); ptr +=2; keydef->maxlength = mi_uint2korr(ptr); ptr +=2; keydef->block_size_index= keydef->block_length/MI_MIN_KEY_BLOCK_LENGTH-1; keydef->underflow_block_length=keydef->block_length/3; keydef->version = 0; /* Not saved */ keydef->parser = &ft_default_parser; keydef->ftkey_nr = 0; return ptr; }
O3
c
mi_keydef_read: pushq %rbp movq %rsp, %rbp movzbl (%rdi), %eax movw %ax, 0x8(%rsi) movb 0x1(%rdi), %al movb %al, 0xc(%rsi) movzwl 0x2(%rdi), %eax rolw $0x8, %ax movw %ax, 0xa(%rsi) movzbl 0x5(%rdi), %eax movzbl 0x4(%rdi), %ecx movl %ecx, %edx shll $0x8, %edx orl %eax, %edx movw %dx, 0xe(%rsi) movzwl 0x6(%rdi), %eax rolw $0x8, %ax movw %ax, 0x12(%rsi) movzwl 0x8(%rdi), %eax rolw $0x8, %ax movw %ax, 0x14(%rsi) movzwl 0xa(%rdi), %eax rolw $0x8, %ax movw %ax, 0x16(%rsi) leaq 0xc(%rdi), %rax shrl $0x2, %ecx decl %ecx movw %cx, 0x18(%rsi) imull $0xaaab, %edx, %ecx # imm = 0xAAAB shrl $0x11, %ecx movw %cx, 0x10(%rsi) movq $0x0, 0x1c(%rsi) leaq 0x305cec(%rip), %rcx # 0x385300 movq %rcx, 0x38(%rsi) popq %rbp retq
mi_keydef_read: push rbp mov rbp, rsp movzx eax, byte ptr [rdi] mov [rsi+8], ax mov al, [rdi+1] mov [rsi+0Ch], al movzx eax, word ptr [rdi+2] rol ax, 8 mov [rsi+0Ah], ax movzx eax, byte ptr [rdi+5] movzx ecx, byte ptr [rdi+4] mov edx, ecx shl edx, 8 or edx, eax mov [rsi+0Eh], dx movzx eax, word ptr [rdi+6] rol ax, 8 mov [rsi+12h], ax movzx eax, word ptr [rdi+8] rol ax, 8 mov [rsi+14h], ax movzx eax, word ptr [rdi+0Ah] rol ax, 8 mov [rsi+16h], ax lea rax, [rdi+0Ch] shr ecx, 2 dec ecx mov [rsi+18h], cx imul ecx, edx, 0AAABh shr ecx, 11h mov [rsi+10h], cx mov qword ptr [rsi+1Ch], 0 lea rcx, ft_default_parser mov [rsi+38h], rcx pop rbp retn
unsigned __int8 * mi_keydef_read(unsigned __int8 *a1, long long a2) { unsigned int v2; // ecx unsigned __int16 v3; // dx unsigned __int8 *result; // rax *(_WORD *)(a2 + 8) = *a1; *(_BYTE *)(a2 + 12) = a1[1]; *(_WORD *)(a2 + 10) = __ROL2__(*((_WORD *)a1 + 1), 8); v2 = a1[4]; v3 = _byteswap_ushort(*((_WORD *)a1 + 2)); *(_WORD *)(a2 + 14) = v3; *(_WORD *)(a2 + 18) = __ROL2__(*((_WORD *)a1 + 3), 8); *(_WORD *)(a2 + 20) = __ROL2__(*((_WORD *)a1 + 4), 8); *(_WORD *)(a2 + 22) = __ROL2__(*((_WORD *)a1 + 5), 8); result = a1 + 12; *(_WORD *)(a2 + 24) = (v2 >> 2) - 1; *(_WORD *)(a2 + 16) = v3 / 3u; *(_QWORD *)(a2 + 28) = 0LL; *(_QWORD *)(a2 + 56) = &ft_default_parser; return result; }
mi_keydef_read: PUSH RBP MOV RBP,RSP MOVZX EAX,byte ptr [RDI] MOV word ptr [RSI + 0x8],AX MOV AL,byte ptr [RDI + 0x1] MOV byte ptr [RSI + 0xc],AL MOVZX EAX,word ptr [RDI + 0x2] ROL AX,0x8 MOV word ptr [RSI + 0xa],AX MOVZX EAX,byte ptr [RDI + 0x5] MOVZX ECX,byte ptr [RDI + 0x4] MOV EDX,ECX SHL EDX,0x8 OR EDX,EAX MOV word ptr [RSI + 0xe],DX MOVZX EAX,word ptr [RDI + 0x6] ROL AX,0x8 MOV word ptr [RSI + 0x12],AX MOVZX EAX,word ptr [RDI + 0x8] ROL AX,0x8 MOV word ptr [RSI + 0x14],AX MOVZX EAX,word ptr [RDI + 0xa] ROL AX,0x8 MOV word ptr [RSI + 0x16],AX LEA RAX,[RDI + 0xc] SHR ECX,0x2 DEC ECX MOV word ptr [RSI + 0x18],CX IMUL ECX,EDX,0xaaab SHR ECX,0x11 MOV word ptr [RSI + 0x10],CX MOV qword ptr [RSI + 0x1c],0x0 LEA RCX,[0x485300] MOV qword ptr [RSI + 0x38],RCX POP RBP RET
byte * mi_keydef_read(byte *param_1,long param_2) { byte bVar1; ushort uVar2; *(ushort *)(param_2 + 8) = (ushort)*param_1; *(byte *)(param_2 + 0xc) = param_1[1]; *(ushort *)(param_2 + 10) = *(ushort *)(param_1 + 2) << 8 | *(ushort *)(param_1 + 2) >> 8; bVar1 = param_1[4]; uVar2 = CONCAT11(bVar1,param_1[5]); *(ushort *)(param_2 + 0xe) = uVar2; *(ushort *)(param_2 + 0x12) = *(ushort *)(param_1 + 6) << 8 | *(ushort *)(param_1 + 6) >> 8; *(ushort *)(param_2 + 0x14) = *(ushort *)(param_1 + 8) << 8 | *(ushort *)(param_1 + 8) >> 8; *(ushort *)(param_2 + 0x16) = *(ushort *)(param_1 + 10) << 8 | *(ushort *)(param_1 + 10) >> 8; *(ushort *)(param_2 + 0x18) = (bVar1 >> 2) - 1; *(ushort *)(param_2 + 0x10) = uVar2 / 3; *(int8 *)(param_2 + 0x1c) = 0; *(int1 **)(param_2 + 0x38) = ft_default_parser; return param_1 + 0xc; }
6,068
nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>::operator->() const
llama.cpp/common/./json.hpp
pointer operator->() const { JSON_ASSERT(m_object != nullptr); switch (m_object->m_data.m_type) { case value_t::object: { JSON_ASSERT(m_it.object_iterator != m_object->m_data.m_value.object->end()); return &(m_it.object_iterator->second); } case value_t::array: { JSON_ASSERT(m_it.array_iterator != m_object->m_data.m_value.array->end()); return &*m_it.array_iterator; } case value_t::null: case value_t::string: case value_t::boolean: case value_t::number_integer: case value_t::number_unsigned: case value_t::number_float: case value_t::binary: case value_t::discarded: default: { if (JSON_HEDLEY_LIKELY(m_it.primitive_iterator.is_begin())) { return m_object; } JSON_THROW(invalid_iterator::create(214, "cannot get value", m_object)); } } }
O3
cpp
nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>::operator->() const: pushq %rbp pushq %r15 pushq %r14 pushq %rbx subq $0x28, %rsp movq %rdi, %r14 movq (%rdi), %rax movzbl (%rax), %ecx cmpl $0x2, %ecx je 0x2fdc7 cmpl $0x1, %ecx jne 0x2fdcd movq 0x8(%r14), %rax addq $0x20, %rax jmp 0x2fdd4 movq 0x10(%r14), %rax jmp 0x2fdd4 cmpq $0x0, 0x18(%r14) jne 0x2fddf addq $0x28, %rsp popq %rbx popq %r14 popq %r15 popq %rbp retq movl $0x20, %edi callq 0x1c460 movq %rax, %rbx leaq 0x18(%rsp), %r15 movq %r15, -0x10(%r15) leaq 0x97091(%rip), %rsi # 0xc6e8d leaq 0x9709a(%rip), %rdx # 0xc6e9d leaq 0x8(%rsp), %rdi callq 0x3fe82 movq (%r14), %rcx movb $0x1, %bpl leaq 0x8(%rsp), %rdx movq %rbx, %rdi movl $0xd6, %esi callq 0x30b7c xorl %ebp, %ebp leaq 0xce072(%rip), %rsi # 0xfdea0 leaq -0x262f(%rip), %rdx # 0x2d806 movq %rbx, %rdi callq 0x1c7b0 movq %rax, %r14 movq 0x8(%rsp), %rdi cmpq %r15, %rdi je 0x2fe57 movq 0x18(%rsp), %rsi incq %rsi callq 0x1c110 testb %bpl, %bpl jne 0x2fe61 jmp 0x2fe69 movq %rax, %r14 movq %rbx, %rdi callq 0x1caa0 movq %r14, %rdi callq 0x1c7d0 nop
_ZNK8nlohmann16json_abi_v3_11_36detail9iter_implINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEptEv: push rbp; void * push r15; int push r14; __int64 push rbx; int sub rsp, 28h mov r14, rdi mov rax, [rdi] movzx ecx, byte ptr [rax] cmp ecx, 2 jz short loc_2FDC7 cmp ecx, 1 jnz short loc_2FDCD mov rax, [r14+8] add rax, 20h ; ' ' jmp short loc_2FDD4 loc_2FDC7: mov rax, [r14+10h] jmp short loc_2FDD4 loc_2FDCD: cmp qword ptr [r14+18h], 0 jnz short loc_2FDDF loc_2FDD4: add rsp, 28h pop rbx pop r14 pop r15 pop rbp retn loc_2FDDF: mov edi, 20h ; ' '; thrown_size call ___cxa_allocate_exception mov rbx, rax lea r15, [rsp+48h+var_30] mov [r15-10h], r15 lea rsi, aCannotGetValue; "cannot get value" lea rdx, aCannotGetValue+10h; "" lea rdi, [rsp+48h+var_40] 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 rcx, [r14] mov bpl, 1 lea rdx, [rsp+48h+var_40] mov rdi, rbx; this mov esi, 0D6h; int call _ZN8nlohmann16json_abi_v3_11_36detail16invalid_iterator6createIPNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SJ_ xor ebp, ebp lea rsi, _ZTIN8nlohmann16json_abi_v3_11_36detail16invalid_iteratorE; lptinfo lea rdx, _ZN8nlohmann16json_abi_v3_11_36detail9exceptionD2Ev; void (*)(void *) mov rdi, rbx; void * call ___cxa_throw mov r14, rax mov rdi, [rsp+48h+var_40]; void * cmp rdi, r15 jz short loc_2FE57 mov rsi, [rsp+48h+var_30] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_2FE57: test bpl, bpl jnz short loc_2FE61 jmp short loc_2FE69 mov r14, rax loc_2FE61: mov rdi, rbx; void * call ___cxa_free_exception loc_2FE69: mov rdi, r14 call __Unwind_Resume
operator->: PUSH RBP PUSH R15 PUSH R14 PUSH RBX SUB RSP,0x28 MOV R14,RDI MOV RAX,qword ptr [RDI] MOVZX ECX,byte ptr [RAX] CMP ECX,0x2 JZ 0x0012fdc7 CMP ECX,0x1 JNZ 0x0012fdcd MOV RAX,qword ptr [R14 + 0x8] ADD RAX,0x20 JMP 0x0012fdd4 LAB_0012fdc7: MOV RAX,qword ptr [R14 + 0x10] JMP 0x0012fdd4 LAB_0012fdcd: CMP qword ptr [R14 + 0x18],0x0 JNZ 0x0012fddf LAB_0012fdd4: ADD RSP,0x28 POP RBX POP R14 POP R15 POP RBP RET LAB_0012fddf: MOV EDI,0x20 CALL 0x0011c460 MOV RBX,RAX LEA R15,[RSP + 0x18] MOV qword ptr [R15 + -0x10],R15 LAB_0012fdf5: LEA RSI,[0x1c6e8d] LEA RDX,[0x1c6e9d] LEA RDI,[RSP + 0x8] CALL 0x0013fe82 MOV RCX,qword ptr [R14] MOV BPL,0x1 LAB_0012fe13: LEA RDX,[RSP + 0x8] MOV RDI,RBX MOV ESI,0xd6 CALL 0x00130b7c XOR EBP,EBP LEA RSI,[0x1fdea0] LEA RDX,[0x12d806] MOV RDI,RBX CALL 0x0011c7b0
/* 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> >::TEMPNAMEPLACEHOLDERVALUE() const */ char * __thiscall 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>> ::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>> *this) { char *pcVar1; int8 uVar2; int1 *local_40 [2]; int1 local_30 [16]; pcVar1 = *(char **)this; if (*pcVar1 == '\x02') { pcVar1 = *(char **)(this + 0x10); } else if (*pcVar1 == '\x01') { pcVar1 = (char *)(*(long *)(this + 8) + 0x20); } else if (*(long *)(this + 0x18) != 0) { uVar2 = __cxa_allocate_exception(0x20); local_40[0] = local_30; /* try { // try from 0012fdf5 to 0012fe0c has its CatchHandler @ 0012fe5e */ std::__cxx11::string::_M_construct<char_const*>(local_40,"cannot get value",""); /* try { // try from 0012fe13 to 0012fe3c has its CatchHandler @ 0012fe3d */ _ZN8nlohmann16json_abi_v3_11_36detail16invalid_iterator6createIPNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SJ_ (uVar2,0xd6,local_40,*(int8 *)this); /* WARNING: Subroutine does not return */ __cxa_throw(uVar2,&invalid_iterator::typeinfo,exception::~exception); } return pcVar1; }
6,069
minja::Parser::consumeToken(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, minja::SpaceHandling)
monkey531[P]llama/common/minja.hpp
std::string consumeToken(const std::string & token, SpaceHandling space_handling = SpaceHandling::Strip) { auto start = it; consumeSpaces(space_handling); if (std::distance(it, end) >= (int64_t) token.size() && std::string(it, it + token.size()) == token) { it += token.size(); return token; } it = start; return ""; }
O3
cpp
minja::Parser::consumeToken(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, minja::SpaceHandling): pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x28, %rsp movq %rdx, %r14 movq %rsi, %r15 movq %rdi, %rbx movq 0x20(%rsi), %r13 movq %rsi, %rdi movl %ecx, %esi callq 0x84996 movq 0x18(%r15), %rax movq 0x20(%r15), %rsi subq %rsi, %rax movq 0x8(%r14), %rdx cmpq %rdx, %rax jl 0x84130 addq %rsi, %rdx leaq 0x18(%rsp), %rax movq %rax, -0x10(%rax) leaq 0x8(%rsp), %r12 movq %r12, %rdi callq 0x70792 movq 0x8(%r12), %rdx cmpq 0x8(%r14), %rdx jne 0x840e6 movq 0x8(%rsp), %r12 testq %rdx, %rdx je 0x840ef movq (%r14), %rsi movq %r12, %rdi callq 0x1a930 testl %eax, %eax sete %bpl jmp 0x840f2 movq 0x8(%rsp), %r12 xorl %ebp, %ebp jmp 0x840f2 movb $0x1, %bpl leaq 0x18(%rsp), %rax cmpq %rax, %r12 je 0x8410c movq 0x18(%rsp), %rsi incq %rsi movq %r12, %rdi callq 0x1a8f0 testb %bpl, %bpl je 0x84130 movq 0x8(%r14), %rdx addq %rdx, 0x20(%r15) leaq 0x10(%rbx), %rax movq %rax, (%rbx) movq (%r14), %rsi addq %rsi, %rdx movq %rbx, %rdi callq 0x21da0 jmp 0x8414d movq %r13, 0x20(%r15) leaq 0x10(%rbx), %rax movq %rax, (%rbx) leaq 0x680fa(%rip), %rdx # 0xec23c movq %rbx, %rdi movq %rdx, %rsi callq 0x22338 movq %rbx, %rax addq $0x28, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
_ZN5minja6Parser12consumeTokenERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEENS_13SpaceHandlingE: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 28h mov r14, rdx mov r15, rsi mov rbx, rdi mov r13, [rsi+20h] mov rdi, rsi mov esi, ecx call _ZN5minja6Parser13consumeSpacesENS_13SpaceHandlingE; minja::Parser::consumeSpaces(minja::SpaceHandling) mov rax, [r15+18h] mov rsi, [r15+20h] sub rax, rsi mov rdx, [r14+8] cmp rax, rdx jl loc_84130 add rdx, rsi lea rax, [rsp+58h+var_40] mov [rax-10h], rax lea r12, [rsp+58h+var_50] mov rdi, r12 call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIN9__gnu_cxx17__normal_iteratorIPKcS4_EEEEvT_SB_St20forward_iterator_tag; std::string::_M_construct<__gnu_cxx::__normal_iterator<char const*,std::string>>(__gnu_cxx::__normal_iterator<char const*,std::string>,__gnu_cxx::__normal_iterator<char const*,std::string>,std::forward_iterator_tag) mov rdx, [r12+8] cmp rdx, [r14+8] jnz short loc_840E6 mov r12, [rsp+58h+var_50] test rdx, rdx jz short loc_840EF mov rsi, [r14] mov rdi, r12 call _bcmp test eax, eax setz bpl jmp short loc_840F2 loc_840E6: mov r12, [rsp+58h+var_50] xor ebp, ebp jmp short loc_840F2 loc_840EF: mov bpl, 1 loc_840F2: lea rax, [rsp+58h+var_40] cmp r12, rax jz short loc_8410C mov rsi, [rsp+58h+var_40] inc rsi; unsigned __int64 mov rdi, r12; void * call __ZdlPvm; operator delete(void *,ulong) loc_8410C: test bpl, bpl jz short loc_84130 mov rdx, [r14+8] add [r15+20h], rdx lea rax, [rbx+10h] mov [rbx], rax mov rsi, [r14] add rdx, rsi mov rdi, rbx call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIPcEEvT_S7_St20forward_iterator_tag; std::string::_M_construct<char *>(char *,char *,std::forward_iterator_tag) jmp short loc_8414D loc_84130: mov [r15+20h], r13 lea rax, [rbx+10h] mov [rbx], rax lea rdx, aErrorWhileHand_0+34h; "" mov rdi, rbx mov rsi, rdx call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIPKcEEvT_S8_St20forward_iterator_tag; std::string::_M_construct<char const*>(char const*,char const*,std::forward_iterator_tag) loc_8414D: mov rax, rbx add rsp, 28h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
_QWORD * minja::Parser::consumeToken(_QWORD *a1, long long a2, _BYTE **a3, unsigned int a4) { long long v6; // r13 _BYTE *v7; // rsi _BYTE *v8; // rdx _QWORD *v9; // r12 bool v10; // bp _BYTE *v11; // rdx void *v13; // [rsp+8h] [rbp-50h] BYREF _BYTE *v14; // [rsp+10h] [rbp-48h] _QWORD v15[8]; // [rsp+18h] [rbp-40h] BYREF v6 = *(_QWORD *)(a2 + 32); minja::Parser::consumeSpaces(a2, a4); v7 = *(_BYTE **)(a2 + 32); v8 = a3[1]; if ( *(_QWORD *)(a2 + 24) - (_QWORD)v7 < (long long)v8 ) goto LABEL_11; v13 = v15; std::string::_M_construct<__gnu_cxx::__normal_iterator<char const*,std::string>>( (long long)&v13, v7, (long long)&v8[(_QWORD)v7]); if ( v14 == a3[1] ) { v9 = v13; v10 = !v14 || (unsigned int)bcmp(v13, *a3) == 0; } else { v9 = v13; v10 = 0; } if ( v9 != v15 ) operator delete(v9, v15[0] + 1LL); if ( v10 ) { v11 = a3[1]; *(_QWORD *)(a2 + 32) += v11; *a1 = a1 + 2; std::string::_M_construct<char *>((long long)a1, *a3, (long long)&v11[(_QWORD)*a3]); } else { LABEL_11: *(_QWORD *)(a2 + 32) = v6; *a1 = a1 + 2; std::string::_M_construct<char const*>((long long)a1, "", (long long)""); } return a1; }
consumeToken: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x28 MOV R14,RDX MOV R15,RSI MOV RBX,RDI MOV R13,qword ptr [RSI + 0x20] MOV RDI,RSI MOV ESI,ECX CALL 0x00184996 MOV RAX,qword ptr [R15 + 0x18] MOV RSI,qword ptr [R15 + 0x20] SUB RAX,RSI MOV RDX,qword ptr [R14 + 0x8] CMP RAX,RDX JL 0x00184130 ADD RDX,RSI LEA RAX,[RSP + 0x18] MOV qword ptr [RAX + -0x10],RAX LEA R12,[RSP + 0x8] MOV RDI,R12 CALL 0x00170792 MOV RDX,qword ptr [R12 + 0x8] CMP RDX,qword ptr [R14 + 0x8] JNZ 0x001840e6 MOV R12,qword ptr [RSP + 0x8] TEST RDX,RDX JZ 0x001840ef MOV RSI,qword ptr [R14] MOV RDI,R12 CALL 0x0011a930 TEST EAX,EAX SETZ BPL JMP 0x001840f2 LAB_001840e6: MOV R12,qword ptr [RSP + 0x8] XOR EBP,EBP JMP 0x001840f2 LAB_001840ef: MOV BPL,0x1 LAB_001840f2: LEA RAX,[RSP + 0x18] CMP R12,RAX JZ 0x0018410c MOV RSI,qword ptr [RSP + 0x18] INC RSI MOV RDI,R12 CALL 0x0011a8f0 LAB_0018410c: TEST BPL,BPL JZ 0x00184130 MOV RDX,qword ptr [R14 + 0x8] ADD qword ptr [R15 + 0x20],RDX LEA RAX,[RBX + 0x10] MOV qword ptr [RBX],RAX MOV RSI,qword ptr [R14] ADD RDX,RSI MOV RDI,RBX CALL 0x00121da0 JMP 0x0018414d LAB_00184130: MOV qword ptr [R15 + 0x20],R13 LEA RAX,[RBX + 0x10] MOV qword ptr [RBX],RAX LEA RDX,[0x1ec23c] MOV RDI,RBX MOV RSI,RDX CALL 0x00122338 LAB_0018414d: MOV RAX,RBX ADD RSP,0x28 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
/* minja::Parser::consumeToken(std::__cxx11::string const&, minja::SpaceHandling) */ long * minja::Parser::consumeToken(long *param_1,Parser *param_2,long *param_3,int4 param_4) { int8 uVar1; long lVar2; long *plVar3; int iVar4; bool bVar5; long *local_50; size_t local_48; long local_40 [2]; uVar1 = *(int8 *)(param_2 + 0x20); consumeSpaces(param_2,param_4); lVar2 = *(long *)(param_2 + 0x20); if (param_3[1] <= *(long *)(param_2 + 0x18) - lVar2) { local_50 = local_40; std::__cxx11::string:: _M_construct<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>> (&local_50,lVar2,param_3[1] + lVar2); plVar3 = local_50; if (local_48 == param_3[1]) { if (local_48 == 0) { bVar5 = true; } else { iVar4 = bcmp(local_50,(void *)*param_3,local_48); bVar5 = iVar4 == 0; } } else { bVar5 = false; } if (plVar3 != local_40) { operator_delete(plVar3,local_40[0] + 1); } if (bVar5) { lVar2 = param_3[1]; *(long *)(param_2 + 0x20) = *(long *)(param_2 + 0x20) + lVar2; *param_1 = (long)(param_1 + 2); std::__cxx11::string::_M_construct<char*>(param_1,*param_3,lVar2 + *param_3); return param_1; } } *(int8 *)(param_2 + 0x20) = uVar1; *param_1 = (long)(param_1 + 2); std::__cxx11::string::_M_construct<char_const*>(param_1,""); return param_1; }
6,070
my_register_filename
eloqsql/mysys/my_open.c
File my_register_filename(File fd, const char *FileName, enum file_type type_of_file, uint error_message_number, myf MyFlags) { DBUG_ENTER("my_register_filename"); if ((int) fd >= MY_FILE_MIN) { my_atomic_add32_explicit(&my_file_opened, 1, MY_MEMORY_ORDER_RELAXED); if ((uint) fd >= my_file_limit || (MyFlags & MY_NO_REGISTER)) DBUG_RETURN(fd); my_file_info[fd].name = my_strdup(key_memory_my_file_info, FileName, MyFlags); statistic_increment(my_file_total_opened,&THR_LOCK_open); my_file_info[fd].type = type_of_file; DBUG_PRINT("exit",("fd: %d",fd)); DBUG_RETURN(fd); } my_errno= errno; DBUG_PRINT("error",("Got error %d on open", my_errno)); if (MyFlags & (MY_FFNF | MY_FAE | MY_WME)) { if (my_errno == EMFILE) error_message_number= EE_OUT_OF_FILERESOURCES; my_error(error_message_number, MYF(ME_BELL | (MyFlags & (ME_NOTE | ME_ERROR_LOG))), FileName, my_errno); } DBUG_RETURN(-1); }
O3
c
my_register_filename: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx pushq %rax movq %r8, %r14 movq %rsi, %r15 testl %edi, %edi js 0x618b5 movl %edi, %ebx leaq 0x3aa3bd(%rip), %rax # 0x40bc14 lock incl (%rax) testl $0x2004, %r14d # imm = 0x2004 jne 0x61904 leaq 0x2daa82(%rip), %rax # 0x33c2f0 cmpl %ebx, (%rax) jbe 0x61904 movl %edx, %r13d leaq 0x3aa8c4(%rip), %rax # 0x40c144 movl (%rax), %edi movq %r15, %rsi movq %r14, %rdx callq 0x61494 leaq 0x2daa64(%rip), %rcx # 0x33c2f8 movq (%rcx), %rdx movl %ebx, %esi shlq $0x4, %rsi movq %rax, (%rdx,%rsi) leaq 0x3aa358(%rip), %rax # 0x40bc00 incq (%rax) movq (%rcx), %rax movl %r13d, 0x8(%rax,%rsi) jmp 0x61904 movl %ecx, %r12d callq 0x36a10 movl (%rax), %ebx callq 0x62622 movl %ebx, (%rax) movl $0xffffffff, %ebx # imm = 0xFFFFFFFF testb $0x19, %r14b je 0x61904 callq 0x62622 cmpl $0x18, (%rax) movl $0x17, %eax cmovel %eax, %r12d andl $0x440, %r14d # imm = 0x440 orq $0x4, %r14 callq 0x62622 movl (%rax), %ecx movl %r12d, %edi movq %r14, %rsi movq %r15, %rdx xorl %eax, %eax callq 0x5da6b movl %ebx, %eax addq $0x8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
my_register_filename: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx push rax mov r14, r8 mov r15, rsi test edi, edi js short loc_618B5 mov ebx, edi lea rax, my_file_opened lock inc dword ptr [rax] test r14d, 2004h jnz loc_61904 lea rax, my_file_limit cmp [rax], ebx jbe loc_61904 mov r13d, edx lea rax, key_memory_my_file_info mov edi, [rax] mov rsi, r15 mov rdx, r14 call my_strdup lea rcx, my_file_info mov rdx, [rcx] mov esi, ebx shl rsi, 4 mov [rdx+rsi], rax lea rax, my_file_total_opened inc qword ptr [rax] mov rax, [rcx] mov [rax+rsi+8], r13d jmp short loc_61904 loc_618B5: mov r12d, ecx call ___errno_location mov ebx, [rax] call _my_thread_var mov [rax], ebx mov ebx, 0FFFFFFFFh test r14b, 19h jz short loc_61904 call _my_thread_var cmp dword ptr [rax], 18h mov eax, 17h cmovz r12d, eax and r14d, 440h or r14, 4 call _my_thread_var mov ecx, [rax] mov edi, r12d mov rsi, r14 mov rdx, r15 xor eax, eax call my_error loc_61904: mov eax, ebx add rsp, 8 pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
long long my_register_filename(long long a1, long long a2, int a3, unsigned int a4, __int16 a5) { unsigned int v6; // ebx long long v8; // rax long long v9; // rsi int v11; // ebx unsigned int *v12; // rax if ( (int)a1 < 0 ) { v11 = *(_DWORD *)__errno_location(a1); *(_DWORD *)my_thread_var(a1) = v11; v6 = -1; if ( (a5 & 0x19) != 0 ) { if ( *(_DWORD *)my_thread_var(a1) == 24 ) a4 = 23; v12 = (unsigned int *)my_thread_var(a1); my_error(a4, a5 & 0x440 | 4LL, a2, *v12); } } else { v6 = a1; _InterlockedIncrement(my_file_opened); if ( (a5 & 0x2004) == 0 && my_file_limit > (unsigned int)a1 ) { v8 = my_strdup(key_memory_my_file_info, a2, a5); v9 = 16LL * (unsigned int)a1; *(_QWORD *)((char *)my_file_info + v9) = v8; ++my_file_total_opened; *(_DWORD *)((char *)my_file_info + v9 + 8) = a3; } } return v6; }
my_register_filename: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX PUSH RAX MOV R14,R8 MOV R15,RSI TEST EDI,EDI JS 0x001618b5 MOV EBX,EDI LEA RAX,[0x50bc14] INC.LOCK dword ptr [RAX] TEST R14D,0x2004 JNZ 0x00161904 LEA RAX,[0x43c2f0] CMP dword ptr [RAX],EBX JBE 0x00161904 MOV R13D,EDX LEA RAX,[0x50c144] MOV EDI,dword ptr [RAX] MOV RSI,R15 MOV RDX,R14 CALL 0x00161494 LEA RCX,[0x43c2f8] MOV RDX,qword ptr [RCX] MOV ESI,EBX SHL RSI,0x4 MOV qword ptr [RDX + RSI*0x1],RAX LEA RAX,[0x50bc00] INC qword ptr [RAX] MOV RAX,qword ptr [RCX] MOV dword ptr [RAX + RSI*0x1 + 0x8],R13D JMP 0x00161904 LAB_001618b5: MOV R12D,ECX CALL 0x00136a10 MOV EBX,dword ptr [RAX] CALL 0x00162622 MOV dword ptr [RAX],EBX MOV EBX,0xffffffff TEST R14B,0x19 JZ 0x00161904 CALL 0x00162622 CMP dword ptr [RAX],0x18 MOV EAX,0x17 CMOVZ R12D,EAX AND R14D,0x440 OR R14,0x4 CALL 0x00162622 MOV ECX,dword ptr [RAX] MOV EDI,R12D MOV RSI,R14 MOV RDX,R15 XOR EAX,EAX CALL 0x0015da6b LAB_00161904: MOV EAX,EBX ADD RSP,0x8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
uint my_register_filename (uint param_1,int8 param_2,int4 param_3,int4 param_4,ulong param_5) { int iVar1; int8 uVar2; int *piVar3; int4 *puVar4; if ((int)param_1 < 0) { piVar3 = __errno_location(); iVar1 = *piVar3; piVar3 = (int *)_my_thread_var(); *piVar3 = iVar1; param_1 = 0xffffffff; if ((param_5 & 0x19) != 0) { piVar3 = (int *)_my_thread_var(); if (*piVar3 == 0x18) { param_4 = 0x17; } puVar4 = (int4 *)_my_thread_var(); my_error(param_4,(uint)param_5 & 0x440 | 4,param_2,*puVar4); } } else { LOCK(); my_file_opened = my_file_opened + 1; UNLOCK(); if (((param_5 & 0x2004) == 0) && (param_1 < my_file_limit)) { uVar2 = my_strdup(key_memory_my_file_info,param_2,param_5); *(int8 *)(my_file_info + (ulong)param_1 * 0x10) = uVar2; my_file_total_opened = my_file_total_opened + 1; *(int4 *)(my_file_info + (ulong)param_1 * 0x10 + 8) = param_3; } } return param_1; }
6,071
check_mb_utf8mb3_valid
eloqsql/libmariadb/libmariadb/ma_charset.c
static unsigned int check_mb_utf8mb3_valid(const char *start, const char *end) { unsigned int len = check_mb_utf8mb3_sequence(start, end); return (len > 1)? len:0; }
O3
c
check_mb_utf8mb3_valid: pushq %rbp movq %rsp, %rbp cmpq %rsi, %rdi jae 0x2fd55 movb (%rdi), %al cmpb $-0x3e, %al jae 0x2fd59 xorl %eax, %eax popq %rbp retq cmpb $-0x21, %al ja 0x2fd73 leaq 0x2(%rdi), %rax cmpq %rsi, %rax ja 0x2fd55 movl $0x2, %eax cmpb $-0x40, 0x1(%rdi) jge 0x2fd55 jmp 0x2fd57 cmpb $-0x10, %al setae %cl leaq 0x3(%rdi), %rdx cmpq %rsi, %rdx seta %dl orb %cl, %dl jne 0x2fd55 movb 0x1(%rdi), %cl cmpb $-0x41, %cl jg 0x2fd55 cmpb $-0x41, 0x2(%rdi) jg 0x2fd55 cmpb $-0x20, %al setne %al cmpb $-0x60, %cl setae %cl orb %al, %cl movl $0x3, %eax je 0x2fd55 jmp 0x2fd57
check_mb_utf8mb3_valid: push rbp mov rbp, rsp cmp rdi, rsi jnb short loc_2FD55 mov al, [rdi] cmp al, 0C2h jnb short loc_2FD59 loc_2FD55: xor eax, eax loc_2FD57: pop rbp retn loc_2FD59: cmp al, 0DFh ja short loc_2FD73 lea rax, [rdi+2] cmp rax, rsi ja short loc_2FD55 mov eax, 2 cmp byte ptr [rdi+1], 0C0h jge short loc_2FD55 jmp short loc_2FD57 loc_2FD73: cmp al, 0F0h setnb cl lea rdx, [rdi+3] cmp rdx, rsi setnbe dl or dl, cl jnz short loc_2FD55 mov cl, [rdi+1] cmp cl, 0BFh jg short loc_2FD55 cmp byte ptr [rdi+2], 0BFh jg short loc_2FD55 cmp al, 0E0h setnz al cmp cl, 0A0h setnb cl or cl, al mov eax, 3 jz short loc_2FD55 jmp short loc_2FD57
long long check_mb_utf8mb3_valid(unsigned __int8 *a1, unsigned long long a2) { unsigned __int8 v2; // al long long result; // rax char v4; // cl bool v5; // cl if ( (unsigned long long)a1 >= a2 ) return 0LL; v2 = *a1; if ( *a1 < 0xC2u ) return 0LL; if ( v2 <= 0xDFu ) { if ( (unsigned long long)(a1 + 2) <= a2 ) { result = 2LL; if ( (char)a1[1] < -64 ) return result; } return 0LL; } if ( v2 >= 0xF0u || (unsigned long long)(a1 + 3) > a2 ) return 0LL; v4 = a1[1]; if ( v4 > -65 ) return 0LL; if ( (char)a1[2] > -65 ) return 0LL; v5 = v2 != 0xE0 || (unsigned __int8)v4 >= 0xA0u; result = 3LL; if ( !v5 ) return 0LL; return result; }
check_mb_utf8mb3_valid: PUSH RBP MOV RBP,RSP CMP RDI,RSI JNC 0x0012fd55 MOV AL,byte ptr [RDI] CMP AL,0xc2 JNC 0x0012fd59 LAB_0012fd55: XOR EAX,EAX LAB_0012fd57: POP RBP RET LAB_0012fd59: CMP AL,0xdf JA 0x0012fd73 LEA RAX,[RDI + 0x2] CMP RAX,RSI JA 0x0012fd55 MOV EAX,0x2 CMP byte ptr [RDI + 0x1],0xc0 JGE 0x0012fd55 JMP 0x0012fd57 LAB_0012fd73: CMP AL,0xf0 SETNC CL LEA RDX,[RDI + 0x3] CMP RDX,RSI SETA DL OR DL,CL JNZ 0x0012fd55 MOV CL,byte ptr [RDI + 0x1] CMP CL,0xbf JG 0x0012fd55 CMP byte ptr [RDI + 0x2],0xbf JG 0x0012fd55 CMP AL,0xe0 SETNZ AL CMP CL,0xa0 SETNC CL OR CL,AL MOV EAX,0x3 JZ 0x0012fd55 JMP 0x0012fd57
int8 check_mb_utf8mb3_valid(byte *param_1,byte *param_2) { byte bVar1; if ((param_1 < param_2) && (bVar1 = *param_1, 0xc1 < bVar1)) { if (bVar1 < 0xe0) { if ((param_1 + 2 <= param_2) && ((char)param_1[1] < -0x40)) { return 2; } } else if ((((param_1 + 3 <= param_2 && bVar1 < 0xf0) && ((char)param_1[1] < -0x40)) && ((char)param_1[2] < -0x40)) && (0x9f < param_1[1] || bVar1 != 0xe0)) { return 3; } } return 0; }
6,072
table_mapping::get_table(unsigned long long)
eloqsql/sql/rpl_tblmap.cc
TABLE* table_mapping::get_table(ulonglong table_id) { DBUG_ENTER("table_mapping::get_table(ulong)"); DBUG_PRINT("enter", ("table_id: %llu", table_id)); entry *e= find_entry(table_id); if (e) { DBUG_PRINT("info", ("tid %llu -> table %p (%s)", table_id, e->table, MAYBE_TABLE_NAME(e->table))); DBUG_RETURN(e->table); } DBUG_PRINT("info", ("tid %llu is not mapped!", table_id)); DBUG_RETURN(NULL); }
O0
cpp
table_mapping::get_table(unsigned long long): pushq %rbp movq %rsp, %rbp subq $0x30, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq -0x10(%rbp), %rax movq %rax, -0x28(%rbp) jmp 0x4114a movq -0x28(%rbp), %rdi movq -0x18(%rbp), %rsi callq 0x65970 movq %rax, -0x20(%rbp) cmpq $0x0, -0x20(%rbp) je 0x41176 jmp 0x41164 jmp 0x41166 jmp 0x41168 movq -0x20(%rbp), %rax movq 0x8(%rax), %rax movq %rax, -0x8(%rbp) jmp 0x41184 jmp 0x41178 jmp 0x4117a jmp 0x4117c movq $0x0, -0x8(%rbp) movq -0x8(%rbp), %rax addq $0x30, %rsp popq %rbp retq nop
_ZN13table_mapping9get_tableEy: push rbp mov rbp, rsp sub rsp, 30h mov [rbp+var_10], rdi mov [rbp+var_18], rsi mov rax, [rbp+var_10] mov [rbp+var_28], rax jmp short $+2 loc_4114A: mov rdi, [rbp+var_28]; this mov rsi, [rbp+var_18]; unsigned __int64 call _ZN13table_mapping10find_entryEy; table_mapping::find_entry(ulong long) mov [rbp+var_20], rax cmp [rbp+var_20], 0 jz short loc_41176 jmp short $+2 loc_41164: jmp short $+2 loc_41166: jmp short $+2 loc_41168: mov rax, [rbp+var_20] mov rax, [rax+8] mov [rbp+var_8], rax jmp short loc_41184 loc_41176: jmp short $+2 loc_41178: jmp short $+2 loc_4117A: jmp short $+2 loc_4117C: mov [rbp+var_8], 0 loc_41184: mov rax, [rbp+var_8] add rsp, 30h pop rbp retn
long long table_mapping::get_table(table_mapping *this, unsigned long long a2) { long long entry; // [rsp+10h] [rbp-20h] entry = table_mapping::find_entry(this, a2); if ( entry ) return *(_QWORD *)(entry + 8); else return 0LL; }
get_table: PUSH RBP MOV RBP,RSP SUB RSP,0x30 MOV qword ptr [RBP + -0x10],RDI MOV qword ptr [RBP + -0x18],RSI MOV RAX,qword ptr [RBP + -0x10] MOV qword ptr [RBP + -0x28],RAX JMP 0x0014114a LAB_0014114a: MOV RDI,qword ptr [RBP + -0x28] MOV RSI,qword ptr [RBP + -0x18] CALL 0x00165970 MOV qword ptr [RBP + -0x20],RAX CMP qword ptr [RBP + -0x20],0x0 JZ 0x00141176 JMP 0x00141164 LAB_00141164: JMP 0x00141166 LAB_00141166: JMP 0x00141168 LAB_00141168: MOV RAX,qword ptr [RBP + -0x20] MOV RAX,qword ptr [RAX + 0x8] MOV qword ptr [RBP + -0x8],RAX JMP 0x00141184 LAB_00141176: JMP 0x00141178 LAB_00141178: JMP 0x0014117a LAB_0014117a: JMP 0x0014117c LAB_0014117c: MOV qword ptr [RBP + -0x8],0x0 LAB_00141184: MOV RAX,qword ptr [RBP + -0x8] ADD RSP,0x30 POP RBP RET
/* table_mapping::get_table(unsigned long long) */ int8 __thiscall table_mapping::get_table(table_mapping *this,ulonglong param_1) { long lVar1; int8 local_10; lVar1 = find_entry(this,param_1); if (lVar1 == 0) { local_10 = 0; } else { local_10 = *(int8 *)(lVar1 + 8); } return local_10; }
6,073
table_mapping::get_table(unsigned long long)
eloqsql/sql/rpl_tblmap.cc
TABLE* table_mapping::get_table(ulonglong table_id) { DBUG_ENTER("table_mapping::get_table(ulong)"); DBUG_PRINT("enter", ("table_id: %llu", table_id)); entry *e= find_entry(table_id); if (e) { DBUG_PRINT("info", ("tid %llu -> table %p (%s)", table_id, e->table, MAYBE_TABLE_NAME(e->table))); DBUG_RETURN(e->table); } DBUG_PRINT("info", ("tid %llu is not mapped!", table_id)); DBUG_RETURN(NULL); }
O3
cpp
table_mapping::get_table(unsigned long long): pushq %rbp movq %rsp, %rbp subq $0x10, %rsp leaq -0x8(%rbp), %rax movq %rsi, (%rax) addq $0x48, %rdi movl $0x8, %edx movq %rax, %rsi callq 0x7a106 testq %rax, %rax je 0x41f1b movq 0x8(%rax), %rax jmp 0x41f1d xorl %eax, %eax addq $0x10, %rsp popq %rbp retq nop
_ZN13table_mapping9get_tableEy: push rbp mov rbp, rsp sub rsp, 10h lea rax, [rbp+var_8] mov [rax], rsi add rdi, 48h ; 'H' mov edx, 8 mov rsi, rax call my_hash_search test rax, rax jz short loc_41F1B mov rax, [rax+8] jmp short loc_41F1D loc_41F1B: xor eax, eax loc_41F1D: add rsp, 10h pop rbp retn
long long table_mapping::get_table(table_mapping *this, long long a2) { long long v2; // rax long long v4; // [rsp+8h] [rbp-8h] BYREF v4 = a2; v2 = my_hash_search((char *)this + 72, &v4, 8LL); if ( v2 ) return *(_QWORD *)(v2 + 8); else return 0LL; }
get_table: PUSH RBP MOV RBP,RSP SUB RSP,0x10 LEA RAX,[RBP + -0x8] MOV qword ptr [RAX],RSI ADD RDI,0x48 MOV EDX,0x8 MOV RSI,RAX CALL 0x0017a106 TEST RAX,RAX JZ 0x00141f1b MOV RAX,qword ptr [RAX + 0x8] JMP 0x00141f1d LAB_00141f1b: XOR EAX,EAX LAB_00141f1d: ADD RSP,0x10 POP RBP RET
/* table_mapping::get_table(unsigned long long) */ int8 __thiscall table_mapping::get_table(table_mapping *this,ulonglong param_1) { long lVar1; int8 uVar2; ulonglong local_10; local_10 = param_1; lVar1 = my_hash_search(this + 0x48,&local_10,8); if (lVar1 == 0) { uVar2 = 0; } else { uVar2 = *(int8 *)(lVar1 + 8); } return uVar2; }
6,074
get_dynamic
eloqsql/mysys/array.c
void get_dynamic(DYNAMIC_ARRAY *array, void *element, uint idx) { if (idx >= array->elements) { DBUG_PRINT("warning",("To big array idx: %d, array size is %d", idx,array->elements)); bzero(element,array->size_of_element); return; } memcpy(element,array->buffer+idx*array->size_of_element, (size_t) array->size_of_element); }
O3
c
get_dynamic: pushq %rbp movq %rsp, %rbp cmpl %edx, 0x8(%rdi) jbe 0x2ba02 movl 0x14(%rdi), %eax imull %eax, %edx addq (%rdi), %rdx movq %rsi, %rdi movq %rdx, %rsi movq %rax, %rdx popq %rbp jmp 0x24220 movl 0x14(%rdi), %edx movq %rsi, %rdi xorl %esi, %esi popq %rbp jmp 0x24160
get_dynamic: push rbp mov rbp, rsp cmp [rdi+8], edx jbe short loc_2BA02 mov eax, [rdi+14h] imul edx, eax add rdx, [rdi] mov rdi, rsi mov rsi, rdx mov rdx, rax pop rbp jmp _memcpy loc_2BA02: mov edx, [rdi+14h] mov rdi, rsi xor esi, esi pop rbp jmp _memset
long long get_dynamic(long long a1, long long a2, unsigned int a3) { if ( *(_DWORD *)(a1 + 8) <= a3 ) return memset(a2, 0LL, *(unsigned int *)(a1 + 20)); else return memcpy(a2, *(_QWORD *)a1 + *(_DWORD *)(a1 + 20) * a3, *(unsigned int *)(a1 + 20)); }
get_dynamic: PUSH RBP MOV RBP,RSP CMP dword ptr [RDI + 0x8],EDX JBE 0x0012ba02 MOV EAX,dword ptr [RDI + 0x14] IMUL EDX,EAX ADD RDX,qword ptr [RDI] MOV RDI,RSI MOV RSI,RDX MOV RDX,RAX POP RBP JMP 0x00124220 LAB_0012ba02: MOV EDX,dword ptr [RDI + 0x14] MOV RDI,RSI XOR ESI,ESI POP RBP JMP 0x00124160
void get_dynamic(long *param_1,void *param_2,uint param_3) { if (param_3 < *(uint *)(param_1 + 1)) { memcpy(param_2,(void *)((ulong)(param_3 * *(uint *)((long)param_1 + 0x14)) + *param_1), (ulong)*(uint *)((long)param_1 + 0x14)); return; } memset(param_2,0,(ulong)*(uint *)((long)param_1 + 0x14)); return; }
6,075
unlink_block
eloqsql/mysys/mf_keycache.c
static void unlink_block(SIMPLE_KEY_CACHE_CB *keycache, BLOCK_LINK *block) { DBUG_ASSERT((block->status & ~BLOCK_CHANGED) == (BLOCK_READ | BLOCK_IN_USE)); DBUG_ASSERT(block->hash_link); /*backptr to block NULL from free_block()*/ DBUG_ASSERT(!block->requests); DBUG_ASSERT(block->prev_changed && *block->prev_changed == block); DBUG_ASSERT(block->next_used && block->prev_used && (block->next_used->prev_used == &block->next_used) && (*block->prev_used == block)); if (block->next_used == block) /* The list contains only one member */ keycache->used_last= keycache->used_ins= NULL; else { block->next_used->prev_used= block->prev_used; *block->prev_used= block->next_used; if (keycache->used_last == block) keycache->used_last= STRUCT_PTR(BLOCK_LINK, next_used, block->prev_used); if (keycache->used_ins == block) keycache->used_ins=STRUCT_PTR(BLOCK_LINK, next_used, block->prev_used); } block->next_used= NULL; #ifdef DBUG_ASSERT_EXISTS /* This makes it easier to see it's not in a chain during debugging. And some DBUG_ASSERT() rely on it. */ block->prev_used= NULL; #endif KEYCACHE_THREAD_TRACE("unlink_block"); #if defined(KEYCACHE_DEBUG) KEYCACHE_DBUG_ASSERT(keycache->blocks_available != 0); keycache->blocks_available--; KEYCACHE_DBUG_PRINT("unlink_block", ("unlinked block %u status=%x #requests=%u #available=%u", BLOCK_NUMBER(block), block->status, block->requests, keycache->blocks_available)); #endif }
O3
c
unlink_block: movq (%rsi), %rax cmpq %rsi, %rax je 0x99a2d pushq %rbp movq %rsp, %rbp movq 0x8(%rsi), %rcx movq %rcx, 0x8(%rax) movq (%rsi), %rax movq %rax, (%rcx) cmpq %rsi, 0xb0(%rdi) jne 0x99a16 movq 0x8(%rsi), %rax movq %rax, 0xb0(%rdi) cmpq %rsi, 0xb8(%rdi) jne 0x99a2a movq 0x8(%rsi), %rax movq %rax, 0xb8(%rdi) popq %rbp jmp 0x99a37 xorps %xmm0, %xmm0 movups %xmm0, 0xb0(%rdi) movq $0x0, (%rsi) retq
unlink_block_0: mov rax, [rsi] cmp rax, rsi jz short loc_99A2D push rbp mov rbp, rsp mov rcx, [rsi+8] mov [rax+8], rcx mov rax, [rsi] mov [rcx], rax cmp [rdi+0B0h], rsi jnz short loc_99A16 mov rax, [rsi+8] mov [rdi+0B0h], rax loc_99A16: cmp [rdi+0B8h], rsi jnz short loc_99A2A mov rax, [rsi+8] mov [rdi+0B8h], rax loc_99A2A: pop rbp jmp short loc_99A37 loc_99A2D: xorps xmm0, xmm0 movups xmmword ptr [rdi+0B0h], xmm0 loc_99A37: mov qword ptr [rsi], 0 retn
_QWORD * unlink_block_0(long long a1, _QWORD *a2) { _QWORD *result; // rax _QWORD *v3; // rcx result = (_QWORD *)*a2; if ( (_QWORD *)*a2 == a2 ) { *(_OWORD *)(a1 + 176) = 0LL; } else { v3 = (_QWORD *)a2[1]; result[1] = v3; result = (_QWORD *)*a2; *v3 = *a2; if ( *(_QWORD **)(a1 + 176) == a2 ) { result = (_QWORD *)a2[1]; *(_QWORD *)(a1 + 176) = result; } if ( *(_QWORD **)(a1 + 184) == a2 ) { result = (_QWORD *)a2[1]; *(_QWORD *)(a1 + 184) = result; } } *a2 = 0LL; return result; }
unlink_block: MOV RAX,qword ptr [RSI] CMP RAX,RSI JZ 0x00199a2d PUSH RBP MOV RBP,RSP MOV RCX,qword ptr [RSI + 0x8] MOV qword ptr [RAX + 0x8],RCX MOV RAX,qword ptr [RSI] MOV qword ptr [RCX],RAX CMP qword ptr [RDI + 0xb0],RSI JNZ 0x00199a16 MOV RAX,qword ptr [RSI + 0x8] MOV qword ptr [RDI + 0xb0],RAX LAB_00199a16: CMP qword ptr [RDI + 0xb8],RSI JNZ 0x00199a2a MOV RAX,qword ptr [RSI + 0x8] MOV qword ptr [RDI + 0xb8],RAX LAB_00199a2a: POP RBP JMP 0x00199a37 LAB_00199a2d: XORPS XMM0,XMM0 MOVUPS xmmword ptr [RDI + 0xb0],XMM0 LAB_00199a37: MOV qword ptr [RSI],0x0 RET
void unlink_block(long param_1,int8 *param_2) { int8 *puVar1; if ((int8 *)*param_2 == param_2) { *(int8 *)(param_1 + 0xb0) = 0; *(int8 *)(param_1 + 0xb8) = 0; } else { puVar1 = (int8 *)param_2[1]; ((int8 *)*param_2)[1] = puVar1; *puVar1 = *param_2; if (*(int8 **)(param_1 + 0xb0) == param_2) { *(int8 *)(param_1 + 0xb0) = param_2[1]; } if (*(int8 **)(param_1 + 0xb8) == param_2) { *(int8 *)(param_1 + 0xb8) = param_2[1]; } } *param_2 = 0; return; }
6,076
encodeURI_hex
bluesky950520[P]quickjs/quickjs.c
static int encodeURI_hex(StringBuffer *b, int c) { uint8_t buf[6]; int n = 0; const char *hex = "0123456789ABCDEF"; buf[n++] = '%'; if (c >= 256) { buf[n++] = 'u'; buf[n++] = hex[(c >> 12) & 15]; buf[n++] = hex[(c >> 8) & 15]; } buf[n++] = hex[(c >> 4) & 15]; buf[n++] = hex[(c >> 0) & 15]; return string_buffer_write8(b, buf, n); }
O3
c
encodeURI_hex: pushq %rax movb $0x25, 0x2(%rsp) movl $0x1, %edx cmpl $0x100, %esi # imm = 0x100 jl 0x7bc1a movb $0x75, 0x3(%rsp) movl %esi, %eax shrl $0xc, %eax andl $0xf, %eax leaq 0x27b88(%rip), %rcx # 0xa3787 movb (%rax,%rcx), %al movb %al, 0x4(%rsp) movl %esi, %eax shrl $0x8, %eax andl $0xf, %eax movb (%rax,%rcx), %al movb %al, 0x5(%rsp) movl $0x4, %edx movl %esi, %eax shrl $0x4, %eax andl $0xf, %eax leaq 0x27b5e(%rip), %rcx # 0xa3787 movb (%rax,%rcx), %al movl %edx, %r8d movb %al, 0x2(%rsp,%r8) andl $0xf, %esi movb (%rsi,%rcx), %al orl $0x2, %edx movb %al, 0x3(%rsp,%r8) leaq 0x2(%rsp), %rsi callq 0x42ef0 popq %rax retq
encodeURI_hex: push rax mov [rsp+8+var_6], 25h ; '%' mov edx, 1 cmp esi, 100h jl short loc_7BC1A mov [rsp+8+var_5], 75h ; 'u' mov eax, esi shr eax, 0Ch and eax, 0Fh lea rcx, a0123456789abcd; "0123456789ABCDEF" mov al, [rax+rcx] mov [rsp+8+var_4], al mov eax, esi shr eax, 8 and eax, 0Fh mov al, [rax+rcx] mov [rsp+8+var_3], al mov edx, 4 loc_7BC1A: mov eax, esi shr eax, 4 and eax, 0Fh lea rcx, a0123456789abcd; "0123456789ABCDEF" mov al, [rax+rcx] mov r8d, edx mov [rsp+r8+8+var_6], al and esi, 0Fh mov al, [rsi+rcx] or edx, 2 mov [rsp+r8+8+var_5], al lea rsi, [rsp+8+var_6] call string_buffer_write8 pop rax retn
long long encodeURI_hex(long long a1, int a2) { long long v2; // rax unsigned int v3; // edx long long v5; // [rsp-2h] [rbp-8h] BYREF v5 = v2; BYTE2(v5) = 37; v3 = 1; if ( a2 >= 256 ) { BYTE3(v5) = 117; BYTE4(v5) = a0123456789abcd[(unsigned __int16)a2 >> 12]; BYTE5(v5) = a0123456789abcd[((unsigned int)a2 >> 8) & 0xF]; v3 = 4; } *((_BYTE *)&v5 + v3 + 2) = a0123456789abcd[(unsigned __int8)a2 >> 4]; *((_BYTE *)&v5 + v3 + 3) = a0123456789abcd[a2 & 0xF]; string_buffer_write8(a1, (long long)&v5 + 2, v3 | 2); return v5; }
encodeURI_hex: PUSH RAX MOV byte ptr [RSP + 0x2],0x25 MOV EDX,0x1 CMP ESI,0x100 JL 0x0017bc1a MOV byte ptr [RSP + 0x3],0x75 MOV EAX,ESI SHR EAX,0xc AND EAX,0xf LEA RCX,[0x1a3787] MOV AL,byte ptr [RAX + RCX*0x1] MOV byte ptr [RSP + 0x4],AL MOV EAX,ESI SHR EAX,0x8 AND EAX,0xf MOV AL,byte ptr [RAX + RCX*0x1] MOV byte ptr [RSP + 0x5],AL MOV EDX,0x4 LAB_0017bc1a: MOV EAX,ESI SHR EAX,0x4 AND EAX,0xf LEA RCX,[0x1a3787] MOV AL,byte ptr [RAX + RCX*0x1] MOV R8D,EDX MOV byte ptr [RSP + R8*0x1 + 0x2],AL AND ESI,0xf MOV AL,byte ptr [RSI + RCX*0x1] OR EDX,0x2 MOV byte ptr [RSP + R8*0x1 + 0x3],AL LEA RSI,[RSP + 0x2] CALL 0x00142ef0 POP RAX RET
int8 encodeURI_hex(int8 param_1,uint param_2) { int8 in_RAX; uint uVar1; int8 uStack_8; uStack_8._3_5_ = (int5)((ulong)in_RAX >> 0x18); uStack_8._0_3_ = CONCAT12(0x25,(short)in_RAX); uVar1 = 1; if (0xff < (int)param_2) { uStack_8._6_2_ = (int2)((ulong)in_RAX >> 0x30); uStack_8._0_6_ = CONCAT15("0123456789ABCDEF"[param_2 >> 8 & 0xf], CONCAT14("0123456789ABCDEF"[param_2 >> 0xc & 0xf], CONCAT13(0x75,(int3)uStack_8))); uVar1 = 4; } *(char *)((long)&uStack_8 + (ulong)uVar1 + 2) = "0123456789ABCDEF"[param_2 >> 4 & 0xf]; *(char *)((long)&uStack_8 + (ulong)uVar1 + 3) = "0123456789ABCDEF"[param_2 & 0xf]; string_buffer_write8(param_1,(long)&uStack_8 + 2,uVar1 | 2); return uStack_8; }
6,077
my_printf_error
eloqsql/mysys/my_error.c
void my_printf_error(uint error, const char *format, myf MyFlags, ...) { va_list args; char ebuff[ERRMSGSIZE]; DBUG_ENTER("my_printf_error"); DBUG_PRINT("my", ("nr: %d MyFlags: %lu errno: %d format: %s", error, MyFlags, errno, format)); va_start(args,MyFlags); (void) my_vsnprintf_ex(&my_charset_utf8mb3_general_ci, ebuff, sizeof(ebuff), format, args); va_end(args); (*error_handler_hook)(error, ebuff, MyFlags); DBUG_VOID_RETURN; }
O3
c
my_printf_error: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %rbx subq $0x2d8, %rsp # imm = 0x2D8 movq %rdx, %rbx movq %rsi, %r10 movl %edi, %r14d leaq -0x2f0(%rbp), %rdx movq %rcx, 0x18(%rdx) movq %r8, 0x20(%rdx) movq %r9, 0x28(%rdx) testb %al, %al je 0xa5db5 movaps %xmm0, -0x2c0(%rbp) movaps %xmm1, -0x2b0(%rbp) movaps %xmm2, -0x2a0(%rbp) movaps %xmm3, -0x290(%rbp) movaps %xmm4, -0x280(%rbp) movaps %xmm5, -0x270(%rbp) movaps %xmm6, -0x260(%rbp) movaps %xmm7, -0x250(%rbp) movq %fs:0x28, %rax movq %rax, -0x20(%rbp) movabsq $0x3000000018, %rax # imm = 0x3000000018 leaq -0x240(%rbp), %r8 movq %rax, (%r8) leaq 0x10(%rbp), %rax movq %rax, 0x8(%r8) movq %rdx, 0x10(%r8) leaq 0x360cc7(%rip), %rdi # 0x406ab0 leaq -0x220(%rbp), %r15 movl $0x200, %edx # imm = 0x200 movq %r15, %rsi movq %r10, %rcx callq 0xe09a0 leaq 0x2ed739(%rip), %rax # 0x393540 movl %r14d, %edi movq %r15, %rsi movq %rbx, %rdx callq *(%rax) movq %fs:0x28, %rax cmpq -0x20(%rbp), %rax jne 0xa5e2f addq $0x2d8, %rsp # imm = 0x2D8 popq %rbx popq %r14 popq %r15 popq %rbp retq callq 0x2a250
my_printf_error: push rbp mov rbp, rsp push r15 push r14 push rbx sub rsp, 2D8h mov rbx, rdx mov r10, rsi mov r14d, edi lea rdx, [rbp+var_2F0] mov [rdx+18h], rcx mov [rdx+20h], r8 mov [rdx+28h], r9 test al, al jz short loc_A5DB5 movaps [rbp+var_2C0], xmm0 movaps [rbp+var_2B0], xmm1 movaps [rbp+var_2A0], xmm2 movaps [rbp+var_290], xmm3 movaps [rbp+var_280], xmm4 movaps [rbp+var_270], xmm5 movaps [rbp+var_260], xmm6 movaps [rbp+var_250], xmm7 loc_A5DB5: mov rax, fs:28h mov [rbp+var_20], rax mov rax, 3000000018h lea r8, [rbp+var_240] mov [r8], rax lea rax, [rbp+arg_0] mov [r8+8], rax mov [r8+10h], rdx lea rdi, my_charset_utf8mb3_general_ci lea r15, [rbp+var_220] mov edx, 200h mov rsi, r15 mov rcx, r10 call my_vsnprintf_ex lea rax, error_handler_hook mov edi, r14d mov rsi, r15 mov rdx, rbx call qword ptr [rax] mov rax, fs:28h cmp rax, [rbp+var_20] jnz short loc_A5E2F add rsp, 2D8h pop rbx pop r14 pop r15 pop rbp retn loc_A5E2F: call ___stack_chk_fail
unsigned long long my_printf_error( _DWORD a1, long long a2, _DWORD a3, long long a4, long long a5, long long a6, __m128 a7, __m128 a8, __m128 a9, __m128 a10, __m128 a11, __m128 a12, __m128 a13, __m128 a14, char a15) { char v16; // [rsp+0h] [rbp-2F0h] BYREF long long v17; // [rsp+18h] [rbp-2D8h] long long v18; // [rsp+20h] [rbp-2D0h] long long v19; // [rsp+28h] [rbp-2C8h] __m128 v20; // [rsp+30h] [rbp-2C0h] __m128 v21; // [rsp+40h] [rbp-2B0h] __m128 v22; // [rsp+50h] [rbp-2A0h] __m128 v23; // [rsp+60h] [rbp-290h] __m128 v24; // [rsp+70h] [rbp-280h] __m128 v25; // [rsp+80h] [rbp-270h] __m128 v26; // [rsp+90h] [rbp-260h] __m128 v27; // [rsp+A0h] [rbp-250h] _QWORD v28[4]; // [rsp+B0h] [rbp-240h] BYREF _BYTE v29[512]; // [rsp+D0h] [rbp-220h] BYREF unsigned long long v30; // [rsp+2D0h] [rbp-20h] v20 = a7; v21 = a8; v22 = a9; v23 = a10; v24 = a11; v25 = a12; v26 = a13; v27 = a14; v17 = a4; v18 = a5; v19 = a6; v30 = __readfsqword(0x28u); v28[0] = 0x3000000018LL; v28[1] = &a15; v28[2] = &v16; my_vsnprintf_ex(&my_charset_utf8mb3_general_ci, v29, 512LL, a2, v28); error_handler_hook(); return __readfsqword(0x28u); }
my_printf_error: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH RBX SUB RSP,0x2d8 MOV RBX,RDX MOV R10,RSI MOV R14D,EDI LEA RDX,[RBP + -0x2f0] MOV qword ptr [RDX + 0x18],RCX MOV qword ptr [RDX + 0x20],R8 MOV qword ptr [RDX + 0x28],R9 TEST AL,AL JZ 0x001a5db5 MOVAPS xmmword ptr [RBP + -0x2c0],XMM0 MOVAPS xmmword ptr [RBP + -0x2b0],XMM1 MOVAPS xmmword ptr [RBP + -0x2a0],XMM2 MOVAPS xmmword ptr [RBP + -0x290],XMM3 MOVAPS xmmword ptr [RBP + -0x280],XMM4 MOVAPS xmmword ptr [RBP + -0x270],XMM5 MOVAPS xmmword ptr [RBP + -0x260],XMM6 MOVAPS xmmword ptr [RBP + -0x250],XMM7 LAB_001a5db5: MOV RAX,qword ptr FS:[0x28] MOV qword ptr [RBP + -0x20],RAX MOV RAX,0x3000000018 LEA R8,[RBP + -0x240] MOV qword ptr [R8],RAX LEA RAX,[RBP + 0x10] MOV qword ptr [R8 + 0x8],RAX MOV qword ptr [R8 + 0x10],RDX LEA RDI,[0x506ab0] LEA R15,[RBP + -0x220] MOV EDX,0x200 MOV RSI,R15 MOV RCX,R10 CALL 0x001e09a0 LEA RAX,[0x493540] MOV EDI,R14D MOV RSI,R15 MOV RDX,RBX CALL qword ptr [RAX] MOV RAX,qword ptr FS:[0x28] CMP RAX,qword ptr [RBP + -0x20] JNZ 0x001a5e2f ADD RSP,0x2d8 POP RBX POP R14 POP R15 POP RBP RET LAB_001a5e2f: CALL 0x0012a250
void my_printf_error(int8 param_1,int8 param_2,int8 param_3,int8 param_4, int8 param_5,int8 param_6,int8 param_7,int8 param_8, int4 param_9,int8 param_10,int8 param_11,int8 param_12, int8 param_13,int8 param_14) { char in_AL; long in_FS_OFFSET; int1 local_2f8 [24]; int8 local_2e0; int8 local_2d8; int8 local_2d0; int8 local_2c8; int8 local_2b8; int8 local_2a8; int8 local_298; int8 local_288; int8 local_278; int8 local_268; int8 local_258; int8 local_248; int1 *local_240; int1 *local_238; int1 local_228 [512]; long local_28; local_238 = local_2f8; if (in_AL != '\0') { local_2c8 = param_1; local_2b8 = param_2; local_2a8 = param_3; local_298 = param_4; local_288 = param_5; local_278 = param_6; local_268 = param_7; local_258 = param_8; } local_28 = *(long *)(in_FS_OFFSET + 0x28); local_248 = 0x3000000018; local_240 = &stack0x00000008; local_2e0 = param_12; local_2d8 = param_13; local_2d0 = param_14; my_vsnprintf_ex(my_charset_utf8mb3_general_ci,local_228,0x200,param_10); (*(code *)error_handler_hook)(param_9,local_228,param_11); if (*(long *)(in_FS_OFFSET + 0x28) == local_28) { return; } /* WARNING: Subroutine does not return */ __stack_chk_fail(); }
6,078
nlohmann::json_abi_v3_11_3::detail::iteration_proxy<nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> const>>::end() const
monkey531[P]llama/common/./json.hpp
iteration_proxy_value<IteratorType> end() const noexcept { return iteration_proxy_value<IteratorType>(container->end()); }
O1
cpp
nlohmann::json_abi_v3_11_3::detail::iteration_proxy<nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> const>>::end() const: pushq %rbx subq $0x20, %rsp movq %rdi, %rbx movabsq $-0x8000000000000000, %rdx # imm = 0x8000000000000000 movq (%rsi), %rax movq %rax, (%rsp) xorps %xmm0, %xmm0 movups %xmm0, 0x8(%rsp) movq %rdx, 0x18(%rsp) movzbl (%rax), %ecx cmpl $0x2, %ecx je 0x9689a cmpl $0x1, %ecx jne 0x968a5 movq $0x0, 0x8(%rsp) jmp 0x968aa movq $0x0, 0x10(%rsp) jmp 0x968aa movq %rdx, 0x18(%rsp) cmpl $0x2, %ecx je 0x968c3 cmpl $0x1, %ecx jne 0x968d2 movq 0x8(%rax), %rax movq 0x8(%rax), %rax movq %rax, 0x8(%rsp) jmp 0x968db movq 0x8(%rax), %rax movq 0x8(%rax), %rax movq %rax, 0x10(%rsp) jmp 0x968db movq $0x1, 0x18(%rsp) movq %rsp, %rsi movq %rbx, %rdi xorl %edx, %edx callq 0x79a8a movq %rbx, %rax addq $0x20, %rsp popq %rbx retq nop
_ZNK8nlohmann16json_abi_v3_11_36detail15iteration_proxyINS1_9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEEEEE3endEv: push rbx sub rsp, 20h mov rbx, rdi mov rdx, 8000000000000000h mov rax, [rsi] mov [rsp+28h+var_28], rax xorps xmm0, xmm0 movups [rsp+28h+var_20], xmm0 mov [rsp+28h+var_10], rdx movzx ecx, byte ptr [rax] cmp ecx, 2 jz short loc_9689A cmp ecx, 1 jnz short loc_968A5 mov qword ptr [rsp+28h+var_20], 0 jmp short loc_968AA loc_9689A: mov qword ptr [rsp+28h+var_20+8], 0 jmp short loc_968AA loc_968A5: mov [rsp+28h+var_10], rdx loc_968AA: cmp ecx, 2 jz short loc_968C3 cmp ecx, 1 jnz short loc_968D2 mov rax, [rax+8] mov rax, [rax+8] mov qword ptr [rsp+28h+var_20], rax jmp short loc_968DB loc_968C3: mov rax, [rax+8] mov rax, [rax+8] mov qword ptr [rsp+28h+var_20+8], rax jmp short loc_968DB loc_968D2: mov [rsp+28h+var_10], 1 loc_968DB: mov rsi, rsp mov rdi, rbx xor edx, edx call _ZN8nlohmann16json_abi_v3_11_36detail21iteration_proxy_valueINS1_9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEEEEEC2ESI_m; nlohmann::json_abi_v3_11_3::detail::iteration_proxy_value<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>>::iteration_proxy_value(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>,ulong) mov rax, rbx add rsp, 20h pop rbx retn
long long nlohmann::json_abi_v3_11_3::detail::iteration_proxy<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>>::end( long long a1, unsigned __int8 **a2) { unsigned __int8 *v2; // rax int v3; // ecx unsigned __int8 *v5; // [rsp+0h] [rbp-28h] BYREF __int128 v6; // [rsp+8h] [rbp-20h] long long v7; // [rsp+18h] [rbp-10h] v2 = *a2; v5 = v2; v6 = 0LL; v7 = 0x8000000000000000LL; v3 = *v2; if ( v3 == 2 ) { *((_QWORD *)&v6 + 1) = 0LL; } else if ( v3 == 1 ) { *(_QWORD *)&v6 = 0LL; } else { v7 = 0x8000000000000000LL; } if ( v3 == 2 ) { *((_QWORD *)&v6 + 1) = *(_QWORD *)(*((_QWORD *)v2 + 1) + 8LL); } else if ( v3 == 1 ) { *(_QWORD *)&v6 = *(_QWORD *)(*((_QWORD *)v2 + 1) + 8LL); } else { v7 = 1LL; } nlohmann::json_abi_v3_11_3::detail::iteration_proxy_value<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>>::iteration_proxy_value( a1, (__int128 *)&v5, 0LL); return a1; }
end: PUSH RBX SUB RSP,0x20 MOV RBX,RDI MOV RDX,-0x8000000000000000 MOV RAX,qword ptr [RSI] MOV qword ptr [RSP],RAX XORPS XMM0,XMM0 MOVUPS xmmword ptr [RSP + 0x8],XMM0 MOV qword ptr [RSP + 0x18],RDX MOVZX ECX,byte ptr [RAX] CMP ECX,0x2 JZ 0x0019689a CMP ECX,0x1 JNZ 0x001968a5 MOV qword ptr [RSP + 0x8],0x0 JMP 0x001968aa LAB_0019689a: MOV qword ptr [RSP + 0x10],0x0 JMP 0x001968aa LAB_001968a5: MOV qword ptr [RSP + 0x18],RDX LAB_001968aa: CMP ECX,0x2 JZ 0x001968c3 CMP ECX,0x1 JNZ 0x001968d2 MOV RAX,qword ptr [RAX + 0x8] MOV RAX,qword ptr [RAX + 0x8] MOV qword ptr [RSP + 0x8],RAX JMP 0x001968db LAB_001968c3: MOV RAX,qword ptr [RAX + 0x8] MOV RAX,qword ptr [RAX + 0x8] MOV qword ptr [RSP + 0x10],RAX JMP 0x001968db LAB_001968d2: MOV qword ptr [RSP + 0x18],0x1 LAB_001968db: MOV RSI,RSP MOV RDI,RBX XOR EDX,EDX CALL 0x00179a8a MOV RAX,RBX ADD RSP,0x20 POP RBX RET
/* nlohmann::json_abi_v3_11_3::detail::iteration_proxy<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> >::end() const */ void nlohmann::json_abi_v3_11_3::detail:: iteration_proxy<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>> ::end(void) { iteration_proxy_value<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>> ::iteration_proxy_value(); return; }
6,079
LefDefParser::lefwLayerRoutingDiagMinEdgeLength(double)
Efficient-TDP/thirdparty/Limbo/limbo/thirdparty/lefdef/5.8/lef/lef/lefwWriter.cpp
int lefwLayerRoutingDiagMinEdgeLength(double diagLength) { if (!lefwFile) return LEFW_UNINITIALIZED; if (lefwState != LEFW_LAYERROUTING_START && lefwState != LEFW_LAYERROUTING) return LEFW_BAD_ORDER; if (!lefwIsRouting) return LEFW_BAD_DATA; // only routing calls this func if (prtSemiColon) { // the previous statement hasn't written the ; yet if (lefwWriteEncrypt) encPrint(lefwFile, (char*) ";\n"); else fprintf(lefwFile, ";\n"); prtSemiColon = 0; } // this routine should call only once per layer routing // it is required for SE only, other is optional if (lefwWriteEncrypt) encPrint(lefwFile, (char*) " DIAGMINEDGELENGTH %.11g ;\n", diagLength); else fprintf(lefwFile, " DIAGMINEDGELENGTH %.11g ;\n", diagLength); lefwLines++; return LEFW_OK; }
O0
cpp
LefDefParser::lefwLayerRoutingDiagMinEdgeLength(double): subq $0x18, %rsp movsd %xmm0, 0x8(%rsp) leaq 0xa940f(%rip), %rax # 0xc5250 cmpq $0x0, (%rax) jne 0x1be54 movl $0x1, 0x14(%rsp) jmp 0x1bf44 leaq 0xa9645(%rip), %rax # 0xc54a0 cmpl $0x7, (%rax) je 0x1be79 leaq 0xa9639(%rip), %rax # 0xc54a0 cmpl $0x1f, (%rax) je 0x1be79 movl $0x2, 0x14(%rsp) jmp 0x1bf44 leaq 0xa9694(%rip), %rax # 0xc5514 cmpl $0x0, (%rax) jne 0x1be92 movl $0x3, 0x14(%rsp) jmp 0x1bf44 cmpl $0x0, 0xa96ab(%rip) # 0xc5544 je 0x1bee0 cmpl $0x0, 0xa969a(%rip) # 0xc553c je 0x1bebe leaq 0xa93a5(%rip), %rax # 0xc5250 movq (%rax), %rdi leaq 0x76964(%rip), %rsi # 0x92819 movb $0x0, %al callq 0x8bf50 jmp 0x1bed6 leaq 0xa938b(%rip), %rax # 0xc5250 movq (%rax), %rdi leaq 0x7694a(%rip), %rsi # 0x92819 movb $0x0, %al callq 0x2370 movl $0x0, 0xa9664(%rip) # 0xc5544 cmpl $0x0, 0xa9655(%rip) # 0xc553c je 0x1bf09 leaq 0xa9360(%rip), %rax # 0xc5250 movq (%rax), %rdi movsd 0x8(%rsp), %xmm0 leaq 0x76da5(%rip), %rsi # 0x92ca5 movb $0x1, %al callq 0x8bf50 jmp 0x1bf27 leaq 0xa9340(%rip), %rax # 0xc5250 movq (%rax), %rdi movsd 0x8(%rsp), %xmm0 leaq 0x76d85(%rip), %rsi # 0x92ca5 movb $0x1, %al callq 0x2370 leaq 0xa956e(%rip), %rax # 0xc549c movl (%rax), %ecx addl $0x1, %ecx leaq 0xa9562(%rip), %rax # 0xc549c movl %ecx, (%rax) movl $0x0, 0x14(%rsp) movl 0x14(%rsp), %eax addq $0x18, %rsp retq nopl (%rax)
_ZN12LefDefParser33lefwLayerRoutingDiagMinEdgeLengthEd: sub rsp, 18h movsd [rsp+18h+var_10], xmm0 lea rax, _ZN12LefDefParser8lefwFileE; LefDefParser::lefwFile cmp qword ptr [rax], 0 jnz short loc_1BE54 mov [rsp+18h+var_4], 1 jmp loc_1BF44 loc_1BE54: lea rax, _ZN12LefDefParser9lefwStateE; LefDefParser::lefwState cmp dword ptr [rax], 7 jz short loc_1BE79 lea rax, _ZN12LefDefParser9lefwStateE; LefDefParser::lefwState cmp dword ptr [rax], 1Fh jz short loc_1BE79 mov [rsp+18h+var_4], 2 jmp loc_1BF44 loc_1BE79: lea rax, _ZN12LefDefParser13lefwIsRoutingE; LefDefParser::lefwIsRouting cmp dword ptr [rax], 0 jnz short loc_1BE92 mov [rsp+18h+var_4], 3 jmp loc_1BF44 loc_1BE92: cmp cs:_ZN12LefDefParserL12prtSemiColonE, 0; LefDefParser::prtSemiColon jz short loc_1BEE0 cmp cs:_ZN12LefDefParserL16lefwWriteEncryptE, 0; LefDefParser::lefwWriteEncrypt jz short loc_1BEBE lea rax, _ZN12LefDefParser8lefwFileE; LefDefParser::lefwFile mov rdi, [rax] lea rsi, aDividercharS+11h; ";\n" mov al, 0 call _ZN12LefDefParser8encPrintEP8_IO_FILEPcz; LefDefParser::encPrint(_IO_FILE *,char *,...) jmp short loc_1BED6 loc_1BEBE: lea rax, _ZN12LefDefParser8lefwFileE; LefDefParser::lefwFile mov rdi, [rax] lea rsi, aDividercharS+11h; ";\n" mov al, 0 call _fprintf loc_1BED6: mov cs:_ZN12LefDefParserL12prtSemiColonE, 0; LefDefParser::prtSemiColon loc_1BEE0: cmp cs:_ZN12LefDefParserL16lefwWriteEncryptE, 0; LefDefParser::lefwWriteEncrypt jz short loc_1BF09 lea rax, _ZN12LefDefParser8lefwFileE; LefDefParser::lefwFile mov rdi, [rax] movsd xmm0, [rsp+18h+var_10] lea rsi, aDiagminedgelen_0; " DIAGMINEDGELENGTH %.11g ;\n" mov al, 1 call _ZN12LefDefParser8encPrintEP8_IO_FILEPcz; LefDefParser::encPrint(_IO_FILE *,char *,...) jmp short loc_1BF27 loc_1BF09: lea rax, _ZN12LefDefParser8lefwFileE; LefDefParser::lefwFile mov rdi, [rax] movsd xmm0, [rsp+18h+var_10] lea rsi, aDiagminedgelen_0; " DIAGMINEDGELENGTH %.11g ;\n" mov al, 1 call _fprintf loc_1BF27: lea rax, _ZN12LefDefParser9lefwLinesE; LefDefParser::lefwLines mov ecx, [rax] add ecx, 1 lea rax, _ZN12LefDefParser9lefwLinesE; LefDefParser::lefwLines mov [rax], ecx mov [rsp+18h+var_4], 0 loc_1BF44: mov eax, [rsp+18h+var_4] add rsp, 18h retn
long long LefDefParser::lefwLayerRoutingDiagMinEdgeLength( LefDefParser *this, double a2, long long a3, int a4, int a5, int a6, int a7) { if ( *(_QWORD *)&LefDefParser::lefwFile ) { if ( LefDefParser::lefwState == 7 || LefDefParser::lefwState == 31 ) { if ( LefDefParser::lefwIsRouting ) { if ( LefDefParser::prtSemiColon ) { if ( LefDefParser::lefwWriteEncrypt ) LefDefParser::encPrint(LefDefParser::lefwFile, (unsigned int)";\n", a4, a5, a6, a7); else fprintf(*(_QWORD *)&LefDefParser::lefwFile, ";\n"); LefDefParser::prtSemiColon = 0; } if ( LefDefParser::lefwWriteEncrypt ) LefDefParser::encPrint(LefDefParser::lefwFile, (unsigned int)" DIAGMINEDGELENGTH %.11g ;\n", a4, a5, a6, a7); else fprintf(*(_QWORD *)&LefDefParser::lefwFile, " DIAGMINEDGELENGTH %.11g ;\n", a2); ++LefDefParser::lefwLines; return 0; } else { return 3; } } else { return 2; } } else { return 1; } }
lefwLayerRoutingDiagMinEdgeLength: SUB RSP,0x18 MOVSD qword ptr [RSP + 0x8],XMM0 LEA RAX,[0x1c5250] CMP qword ptr [RAX],0x0 JNZ 0x0011be54 MOV dword ptr [RSP + 0x14],0x1 JMP 0x0011bf44 LAB_0011be54: LEA RAX,[0x1c54a0] CMP dword ptr [RAX],0x7 JZ 0x0011be79 LEA RAX,[0x1c54a0] CMP dword ptr [RAX],0x1f JZ 0x0011be79 MOV dword ptr [RSP + 0x14],0x2 JMP 0x0011bf44 LAB_0011be79: LEA RAX,[0x1c5514] CMP dword ptr [RAX],0x0 JNZ 0x0011be92 MOV dword ptr [RSP + 0x14],0x3 JMP 0x0011bf44 LAB_0011be92: CMP dword ptr [0x001c5544],0x0 JZ 0x0011bee0 CMP dword ptr [0x001c553c],0x0 JZ 0x0011bebe LEA RAX,[0x1c5250] MOV RDI,qword ptr [RAX] LEA RSI,[0x192819] MOV AL,0x0 CALL 0x0018bf50 JMP 0x0011bed6 LAB_0011bebe: LEA RAX,[0x1c5250] MOV RDI,qword ptr [RAX] LEA RSI,[0x192819] MOV AL,0x0 CALL 0x00102370 LAB_0011bed6: MOV dword ptr [0x001c5544],0x0 LAB_0011bee0: CMP dword ptr [0x001c553c],0x0 JZ 0x0011bf09 LEA RAX,[0x1c5250] MOV RDI,qword ptr [RAX] MOVSD XMM0,qword ptr [RSP + 0x8] LEA RSI,[0x192ca5] MOV AL,0x1 CALL 0x0018bf50 JMP 0x0011bf27 LAB_0011bf09: LEA RAX,[0x1c5250] MOV RDI,qword ptr [RAX] MOVSD XMM0,qword ptr [RSP + 0x8] LEA RSI,[0x192ca5] MOV AL,0x1 CALL 0x00102370 LAB_0011bf27: LEA RAX,[0x1c549c] MOV ECX,dword ptr [RAX] ADD ECX,0x1 LEA RAX,[0x1c549c] MOV dword ptr [RAX],ECX MOV dword ptr [RSP + 0x14],0x0 LAB_0011bf44: MOV EAX,dword ptr [RSP + 0x14] ADD RSP,0x18 RET
/* LefDefParser::lefwLayerRoutingDiagMinEdgeLength(double) */ int4 LefDefParser::lefwLayerRoutingDiagMinEdgeLength(double param_1) { int4 local_4; if (lefwFile == (_IO_FILE *)0x0) { local_4 = 1; } else if ((lefwState == 7) || (lefwState == 0x1f)) { if (lefwIsRouting == 0) { local_4 = 3; } else { if (prtSemiColon != 0) { if (lefwWriteEncrypt == 0) { fprintf(lefwFile,";\n"); } else { encPrint(lefwFile,";\n"); } prtSemiColon = 0; } if (lefwWriteEncrypt == 0) { fprintf(lefwFile," DIAGMINEDGELENGTH %.11g ;\n",param_1); } else { encPrint(lefwFile," DIAGMINEDGELENGTH %.11g ;\n",param_1); } lefwLines = lefwLines + 1; local_4 = 0; } } else { local_4 = 2; } return local_4; }
6,080
LefDefParser::lefwLayerRoutingDiagMinEdgeLength(double)
Efficient-TDP/thirdparty/Limbo/limbo/thirdparty/lefdef/5.8/lef/lef/lefwWriter.cpp
int lefwLayerRoutingDiagMinEdgeLength(double diagLength) { if (!lefwFile) return LEFW_UNINITIALIZED; if (lefwState != LEFW_LAYERROUTING_START && lefwState != LEFW_LAYERROUTING) return LEFW_BAD_ORDER; if (!lefwIsRouting) return LEFW_BAD_DATA; // only routing calls this func if (prtSemiColon) { // the previous statement hasn't written the ; yet if (lefwWriteEncrypt) encPrint(lefwFile, (char*) ";\n"); else fprintf(lefwFile, ";\n"); prtSemiColon = 0; } // this routine should call only once per layer routing // it is required for SE only, other is optional if (lefwWriteEncrypt) encPrint(lefwFile, (char*) " DIAGMINEDGELENGTH %.11g ;\n", diagLength); else fprintf(lefwFile, " DIAGMINEDGELENGTH %.11g ;\n", diagLength); lefwLines++; return LEFW_OK; }
O3
cpp
LefDefParser::lefwLayerRoutingDiagMinEdgeLength(double): pushq %rbx subq $0x10, %rsp leaq 0x7a5a9(%rip), %rbx # 0x8d0f0 movq (%rbx), %rcx testq %rcx, %rcx je 0x12ba2 leaq 0x7a7ea(%rip), %rax # 0x8d340 movl (%rax), %edx cmpl $0x1f, %edx je 0x12b6b movl $0x2, %eax cmpl $0x7, %edx jne 0x12c08 leaq 0x7a842(%rip), %rax # 0x8d3b4 cmpl $0x0, (%rax) je 0x12ba9 cmpb $0x1, 0x7a866(%rip) # 0x8d3e4 jne 0x12bd3 movsd %xmm0, 0x8(%rsp) cmpb $0x1, 0x7a84f(%rip) # 0x8d3dc jne 0x12bb0 leaq 0x47c6b(%rip), %rsi # 0x5a801 movq %rcx, %rdi xorl %eax, %eax callq 0x55afd jmp 0x12bc6 movl $0x1, %eax jmp 0x12c08 movl $0x3, %eax jmp 0x12c08 leaq 0x47c4a(%rip), %rdi # 0x5a801 movl $0x2, %esi movl $0x1, %edx callq 0x23d0 movb $0x0, 0x7a817(%rip) # 0x8d3e4 movsd 0x8(%rsp), %xmm0 movq (%rbx), %rdi cmpb $0x1, 0x7a7ff(%rip) # 0x8d3dc jne 0x12bef leaq 0x480a7(%rip), %rsi # 0x5ac8d movb $0x1, %al callq 0x55afd jmp 0x12bfd leaq 0x48097(%rip), %rsi # 0x5ac8d movb $0x1, %al callq 0x22e0 leaq 0x7a738(%rip), %rax # 0x8d33c incl (%rax) xorl %eax, %eax addq $0x10, %rsp popq %rbx retq
_ZN12LefDefParser33lefwLayerRoutingDiagMinEdgeLengthEd: push rbx sub rsp, 10h lea rbx, _ZN12LefDefParser8lefwFileE; LefDefParser::lefwFile mov rcx, [rbx] test rcx, rcx jz short loc_12BA2 lea rax, _ZN12LefDefParser9lefwStateE; LefDefParser::lefwState mov edx, [rax] cmp edx, 1Fh jz short loc_12B6B mov eax, 2 cmp edx, 7 jnz loc_12C08 loc_12B6B: lea rax, _ZN12LefDefParser13lefwIsRoutingE; LefDefParser::lefwIsRouting cmp dword ptr [rax], 0 jz short loc_12BA9 cmp cs:_ZN12LefDefParserL12prtSemiColonE, 1; LefDefParser::prtSemiColon jnz short loc_12BD3 movsd [rsp+18h+var_10], xmm0 cmp cs:_ZN12LefDefParserL16lefwWriteEncryptE, 1; LefDefParser::lefwWriteEncrypt jnz short loc_12BB0 lea rsi, aDividercharS+11h; ";\n" mov rdi, rcx xor eax, eax call _ZN12LefDefParser8encPrintEP8_IO_FILEPcz; LefDefParser::encPrint(_IO_FILE *,char *,...) jmp short loc_12BC6 loc_12BA2: mov eax, 1 jmp short loc_12C08 loc_12BA9: mov eax, 3 jmp short loc_12C08 loc_12BB0: lea rdi, aDividercharS+11h; ";\n" mov esi, 2 mov edx, 1 call _fwrite loc_12BC6: mov cs:_ZN12LefDefParserL12prtSemiColonE, 0; LefDefParser::prtSemiColon movsd xmm0, [rsp+18h+var_10] loc_12BD3: mov rdi, [rbx] cmp cs:_ZN12LefDefParserL16lefwWriteEncryptE, 1; LefDefParser::lefwWriteEncrypt jnz short loc_12BEF lea rsi, aDiagminedgelen_0; " DIAGMINEDGELENGTH %.11g ;\n" mov al, 1 call _ZN12LefDefParser8encPrintEP8_IO_FILEPcz; LefDefParser::encPrint(_IO_FILE *,char *,...) jmp short loc_12BFD loc_12BEF: lea rsi, aDiagminedgelen_0; " DIAGMINEDGELENGTH %.11g ;\n" mov al, 1 call _fprintf loc_12BFD: lea rax, _ZN12LefDefParser9lefwLinesE; LefDefParser::lefwLines inc dword ptr [rax] xor eax, eax loc_12C08: add rsp, 10h pop rbx retn
long long LefDefParser::lefwLayerRoutingDiagMinEdgeLength( LefDefParser *this, double a2, long long a3, long long a4, long long a5, int a6, int a7) { int v7; // ecx unsigned int v8; // edx long long result; // rax v7 = LefDefParser::lefwFile; if ( !*(_QWORD *)&LefDefParser::lefwFile ) return 1LL; v8 = LefDefParser::lefwState; if ( LefDefParser::lefwState == 31 || (result = 2LL, LefDefParser::lefwState == 7) ) { if ( LefDefParser::lefwIsRouting ) { if ( LefDefParser::prtSemiColon == 1 ) { if ( LefDefParser::lefwWriteEncrypt == 1 ) LefDefParser::encPrint( LefDefParser::lefwFile, (unsigned int)";\n", LefDefParser::lefwState, LefDefParser::lefwFile, a6, a7); else fwrite(";\n", 2LL, 1LL, *(_QWORD *)&LefDefParser::lefwFile); LefDefParser::prtSemiColon = 0; } if ( LefDefParser::lefwWriteEncrypt == 1 ) LefDefParser::encPrint(LefDefParser::lefwFile, (unsigned int)" DIAGMINEDGELENGTH %.11g ;\n", v8, v7, a6, a7); else fprintf(*(_QWORD *)&LefDefParser::lefwFile, " DIAGMINEDGELENGTH %.11g ;\n", a2); ++LefDefParser::lefwLines; return 0LL; } else { return 3LL; } } return result; }
lefwLayerRoutingDiagMinEdgeLength: PUSH RBX SUB RSP,0x10 LEA RBX,[0x18d0f0] MOV RCX,qword ptr [RBX] TEST RCX,RCX JZ 0x00112ba2 LEA RAX,[0x18d340] MOV EDX,dword ptr [RAX] CMP EDX,0x1f JZ 0x00112b6b MOV EAX,0x2 CMP EDX,0x7 JNZ 0x00112c08 LAB_00112b6b: LEA RAX,[0x18d3b4] CMP dword ptr [RAX],0x0 JZ 0x00112ba9 CMP byte ptr [0x0018d3e4],0x1 JNZ 0x00112bd3 MOVSD qword ptr [RSP + 0x8],XMM0 CMP byte ptr [0x0018d3dc],0x1 JNZ 0x00112bb0 LEA RSI,[0x15a801] MOV RDI,RCX XOR EAX,EAX CALL 0x00155afd JMP 0x00112bc6 LAB_00112ba2: MOV EAX,0x1 JMP 0x00112c08 LAB_00112ba9: MOV EAX,0x3 JMP 0x00112c08 LAB_00112bb0: LEA RDI,[0x15a801] MOV ESI,0x2 MOV EDX,0x1 CALL 0x001023d0 LAB_00112bc6: MOV byte ptr [0x0018d3e4],0x0 MOVSD XMM0,qword ptr [RSP + 0x8] LAB_00112bd3: MOV RDI,qword ptr [RBX] CMP byte ptr [0x0018d3dc],0x1 JNZ 0x00112bef LEA RSI,[0x15ac8d] MOV AL,0x1 CALL 0x00155afd JMP 0x00112bfd LAB_00112bef: LEA RSI,[0x15ac8d] MOV AL,0x1 CALL 0x001022e0 LAB_00112bfd: LEA RAX,[0x18d33c] INC dword ptr [RAX] XOR EAX,EAX LAB_00112c08: ADD RSP,0x10 POP RBX RET
/* LefDefParser::lefwLayerRoutingDiagMinEdgeLength(double) */ int8 LefDefParser::lefwLayerRoutingDiagMinEdgeLength(double param_1) { int8 uVar1; if (lefwFile == (_IO_FILE *)0x0) { uVar1 = 1; } else if ((lefwState == 0x1f) || (uVar1 = 2, lefwState == 7)) { if (lefwIsRouting == 0) { uVar1 = 3; } else { if (prtSemiColon == '\x01') { if (lefwWriteEncrypt == '\x01') { encPrint(lefwFile,";\n"); } else { fwrite(";\n",2,1,lefwFile); } prtSemiColon = '\0'; } if (lefwWriteEncrypt == '\x01') { encPrint(lefwFile," DIAGMINEDGELENGTH %.11g ;\n"); } else { fprintf(lefwFile," DIAGMINEDGELENGTH %.11g ;\n",param_1); } lefwLines = lefwLines + 1; uVar1 = 0; } } return uVar1; }
6,081
ma_log_rt_split
eloqsql/storage/maria/ma_rt_split.c
static my_bool _ma_log_rt_split(MARIA_PAGE *page, const uchar *key_with_nod_flag, uint full_length, const uchar *log_internal_copy, uint log_internal_copy_length, const uchar *log_key_copy, uint length_diff) { MARIA_HA *info= page->info; MARIA_SHARE *share= info->s; LSN lsn; uchar log_data[FILEID_STORE_SIZE + PAGE_STORE_SIZE + 1 + 2 + 1 + 2 + 2 + 7], *log_pos; LEX_CUSTRING log_array[TRANSLOG_INTERNAL_PARTS + 6]; uint translog_parts, extra_length= 0; my_off_t page_pos; DBUG_ENTER("_ma_log_rt_split"); DBUG_PRINT("enter", ("page: %p", page)); DBUG_ASSERT(share->now_transactional); page_pos= page->pos / share->block_size; page_store(log_data + FILEID_STORE_SIZE, page_pos); log_pos= log_data+ FILEID_STORE_SIZE + PAGE_STORE_SIZE; log_pos[0]= KEY_OP_DEL_SUFFIX; log_pos++; DBUG_ASSERT((int)length_diff > 0); int2store(log_pos, length_diff); log_pos+= 2; log_pos[0]= KEY_OP_MULTI_COPY; log_pos++; int2store(log_pos, full_length); log_pos+= 2; int2store(log_pos, log_internal_copy_length); log_pos+= 2; log_array[TRANSLOG_INTERNAL_PARTS + 0].str= log_data; log_array[TRANSLOG_INTERNAL_PARTS + 0].length= sizeof(log_data) - 7; log_array[TRANSLOG_INTERNAL_PARTS + 1].str= log_internal_copy; log_array[TRANSLOG_INTERNAL_PARTS + 1].length= log_internal_copy_length; translog_parts= 2; if (log_key_copy != NULL) /* need to store key into record */ { log_array[TRANSLOG_INTERNAL_PARTS + 2].str= log_key_copy; log_array[TRANSLOG_INTERNAL_PARTS + 2].length= 1 + 2 + 1 + 2; log_array[TRANSLOG_INTERNAL_PARTS + 3].str= key_with_nod_flag; log_array[TRANSLOG_INTERNAL_PARTS + 3].length= full_length; extra_length= 1 + 2 + 1 + 2 + full_length; translog_parts+= 2; } _ma_log_key_changes(page, log_array + TRANSLOG_INTERNAL_PARTS + translog_parts, log_pos, &extra_length, &translog_parts); /* Remember new page length for future log entires for same page */ page->org_size= page->size; if (translog_write_record(&lsn, LOGREC_REDO_INDEX, info->trn, info, (translog_size_t) ((log_pos - log_data) + log_internal_copy_length + extra_length), TRANSLOG_INTERNAL_PARTS + translog_parts, log_array, log_data, NULL)) DBUG_RETURN(1); DBUG_RETURN(0); }
O0
c
ma_log_rt_split: pushq %rbp movq %rsp, %rbp subq $0x150, %rsp # imm = 0x150 movl 0x10(%rbp), %eax movq %fs:0x28, %rax movq %rax, -0x8(%rbp) movq %rdi, -0x30(%rbp) movq %rsi, -0x38(%rbp) movl %edx, -0x3c(%rbp) movq %rcx, -0x48(%rbp) movl %r8d, -0x4c(%rbp) movq %r9, -0x58(%rbp) movq -0x30(%rbp), %rax movq (%rax), %rax movq %rax, -0x60(%rbp) movq -0x60(%rbp), %rax movq (%rax), %rax movq %rax, -0x68(%rbp) movl $0x0, -0x108(%rbp) jmp 0x86d74 jmp 0x86d76 jmp 0x86d78 movq -0x30(%rbp), %rax movq 0x18(%rax), %rax movq -0x68(%rbp), %rcx movl 0x7bc(%rcx), %ecx xorl %edx, %edx divq %rcx movq %rax, -0x110(%rbp) leaq -0x20(%rbp), %rax addq $0x2, %rax movq %rax, -0x118(%rbp) movq -0x110(%rbp), %rax movl %eax, %ecx movq -0x118(%rbp), %rax movl %ecx, (%rax) movq -0x110(%rbp), %rax shrq $0x20, %rax movb %al, %cl movq -0x118(%rbp), %rax movb %cl, 0x4(%rax) leaq -0x20(%rbp), %rax addq $0x2, %rax addq $0x5, %rax movq %rax, -0x78(%rbp) movq -0x78(%rbp), %rax movb $0x7, (%rax) movq -0x78(%rbp), %rax addq $0x1, %rax movq %rax, -0x78(%rbp) jmp 0x86df3 jmp 0x86df5 movq -0x78(%rbp), %rax movq %rax, -0x120(%rbp) movl 0x10(%rbp), %eax movw %ax, %cx movq -0x120(%rbp), %rax movw %cx, (%rax) movq -0x78(%rbp), %rax addq $0x2, %rax movq %rax, -0x78(%rbp) movq -0x78(%rbp), %rax movb $0x9, (%rax) movq -0x78(%rbp), %rax addq $0x1, %rax movq %rax, -0x78(%rbp) movq -0x78(%rbp), %rax movq %rax, -0x128(%rbp) movl -0x3c(%rbp), %eax movw %ax, %cx movq -0x128(%rbp), %rax movw %cx, (%rax) movq -0x78(%rbp), %rax addq $0x2, %rax movq %rax, -0x78(%rbp) movq -0x78(%rbp), %rax movq %rax, -0x130(%rbp) movl -0x4c(%rbp), %eax movw %ax, %cx movq -0x130(%rbp), %rax movw %cx, (%rax) movq -0x78(%rbp), %rax addq $0x2, %rax movq %rax, -0x78(%rbp) leaq -0x20(%rbp), %rax movq %rax, -0xe0(%rbp) movq $0xf, -0xd8(%rbp) movq -0x48(%rbp), %rax movq %rax, -0xd0(%rbp) movl -0x4c(%rbp), %eax movq %rax, -0xc8(%rbp) movl $0x2, -0x104(%rbp) cmpq $0x0, -0x58(%rbp) je 0x86eff movq -0x58(%rbp), %rax movq %rax, -0xc0(%rbp) movq $0x6, -0xb8(%rbp) movq -0x38(%rbp), %rax movq %rax, -0xb0(%rbp) movl -0x3c(%rbp), %eax movq %rax, -0xa8(%rbp) movl -0x3c(%rbp), %eax addl $0x6, %eax movl %eax, -0x108(%rbp) movl -0x104(%rbp), %eax addl $0x2, %eax movl %eax, -0x104(%rbp) movq -0x30(%rbp), %rax movl 0x20(%rax), %ecx movq -0x30(%rbp), %rax movl %ecx, 0x24(%rax) movq -0x60(%rbp), %rax movq 0x8(%rax), %rdx movq -0x60(%rbp), %rcx movq -0x78(%rbp), %rax leaq -0x20(%rbp), %rsi subq %rsi, %rax movl -0x4c(%rbp), %esi addq %rsi, %rax movl -0x108(%rbp), %esi addq %rsi, %rax movl %eax, %r8d movl -0x104(%rbp), %r9d addl $0x2, %r9d leaq -0x100(%rbp), %r10 leaq -0x20(%rbp), %rax leaq -0x70(%rbp), %rdi movl $0xc, %esi xorl %r11d, %r11d movq %r10, (%rsp) movq %rax, 0x8(%rsp) movq $0x0, 0x10(%rsp) callq 0x8e280 cmpb $0x0, %al je 0x86f7b jmp 0x86f75 movb $0x1, -0x21(%rbp) jmp 0x86f81 jmp 0x86f7d movb $0x0, -0x21(%rbp) movb -0x21(%rbp), %al movb %al, -0x131(%rbp) movq %fs:0x28, %rax movq -0x8(%rbp), %rcx cmpq %rcx, %rax jne 0x86fab movb -0x131(%rbp), %al addq $0x150, %rsp # imm = 0x150 popq %rbp retq callq 0x2a250
_ma_log_rt_split: push rbp mov rbp, rsp sub rsp, 150h mov eax, [rbp+arg_0] mov rax, fs:28h mov [rbp+var_8], rax mov [rbp+var_30], rdi mov [rbp+var_38], rsi mov [rbp+var_3C], edx mov [rbp+var_48], rcx mov [rbp+var_4C], r8d mov [rbp+var_58], r9 mov rax, [rbp+var_30] mov rax, [rax] mov [rbp+var_60], rax mov rax, [rbp+var_60] mov rax, [rax] mov [rbp+var_68], rax mov [rbp+var_108], 0 jmp short $+2 loc_86D74: jmp short $+2 loc_86D76: jmp short $+2 loc_86D78: mov rax, [rbp+var_30] mov rax, [rax+18h] mov rcx, [rbp+var_68] mov ecx, [rcx+7BCh] xor edx, edx div rcx mov [rbp+var_110], rax lea rax, [rbp+var_20] add rax, 2 mov [rbp+var_118], rax mov rax, [rbp+var_110] mov ecx, eax mov rax, [rbp+var_118] mov [rax], ecx mov rax, [rbp+var_110] shr rax, 20h mov cl, al mov rax, [rbp+var_118] mov [rax+4], cl lea rax, [rbp+var_20] add rax, 2 add rax, 5 mov [rbp+var_78], rax mov rax, [rbp+var_78] mov byte ptr [rax], 7 mov rax, [rbp+var_78] add rax, 1 mov [rbp+var_78], rax jmp short $+2 loc_86DF3: jmp short $+2 loc_86DF5: mov rax, [rbp+var_78] mov [rbp+var_120], rax mov eax, [rbp+arg_0] mov cx, ax mov rax, [rbp+var_120] mov [rax], cx mov rax, [rbp+var_78] add rax, 2 mov [rbp+var_78], rax mov rax, [rbp+var_78] mov byte ptr [rax], 9 mov rax, [rbp+var_78] add rax, 1 mov [rbp+var_78], rax mov rax, [rbp+var_78] mov [rbp+var_128], rax mov eax, [rbp+var_3C] mov cx, ax mov rax, [rbp+var_128] mov [rax], cx mov rax, [rbp+var_78] add rax, 2 mov [rbp+var_78], rax mov rax, [rbp+var_78] mov [rbp+var_130], rax mov eax, [rbp+var_4C] mov cx, ax mov rax, [rbp+var_130] mov [rax], cx mov rax, [rbp+var_78] add rax, 2 mov [rbp+var_78], rax lea rax, [rbp+var_20] mov [rbp+var_E0], rax mov [rbp+var_D8], 0Fh mov rax, [rbp+var_48] mov [rbp+var_D0], rax mov eax, [rbp+var_4C] mov [rbp+var_C8], rax mov [rbp+var_104], 2 cmp [rbp+var_58], 0 jz short loc_86EFF mov rax, [rbp+var_58] mov [rbp+var_C0], rax mov [rbp+var_B8], 6 mov rax, [rbp+var_38] mov [rbp+var_B0], rax mov eax, [rbp+var_3C] mov [rbp+var_A8], rax mov eax, [rbp+var_3C] add eax, 6 mov [rbp+var_108], eax mov eax, [rbp+var_104] add eax, 2 mov [rbp+var_104], eax loc_86EFF: mov rax, [rbp+var_30] mov ecx, [rax+20h] mov rax, [rbp+var_30] mov [rax+24h], ecx mov rax, [rbp+var_60] mov rdx, [rax+8] mov rcx, [rbp+var_60] mov rax, [rbp+var_78] lea rsi, [rbp+var_20] sub rax, rsi mov esi, [rbp+var_4C] add rax, rsi mov esi, [rbp+var_108] add rax, rsi mov r8d, eax mov r9d, [rbp+var_104] add r9d, 2 lea r10, [rbp+var_100] lea rax, [rbp+var_20] lea rdi, [rbp+var_70] mov esi, 0Ch xor r11d, r11d mov [rsp+150h+var_150], r10 mov [rsp+150h+var_148], rax mov [rsp+150h+var_140], 0 call translog_write_record cmp al, 0 jz short loc_86F7B jmp short $+2 loc_86F75: mov [rbp+var_21], 1 jmp short loc_86F81 loc_86F7B: jmp short $+2 loc_86F7D: mov [rbp+var_21], 0 loc_86F81: mov al, [rbp+var_21] mov [rbp+var_131], al mov rax, fs:28h mov rcx, [rbp+var_8] cmp rax, rcx jnz short loc_86FAB mov al, [rbp+var_131] add rsp, 150h pop rbp retn loc_86FAB: call ___stack_chk_fail
bool ma_log_rt_split( _QWORD *a1, long long a2, unsigned int a3, long long a4, unsigned int a5, long long a6, __int16 a7) { unsigned long long v8; // [rsp+40h] [rbp-110h] unsigned int v9; // [rsp+48h] [rbp-108h] int v10; // [rsp+4Ch] [rbp-104h] _BYTE v11[32]; // [rsp+50h] [rbp-100h] BYREF _BYTE *v12; // [rsp+70h] [rbp-E0h] long long v13; // [rsp+78h] [rbp-D8h] long long v14; // [rsp+80h] [rbp-D0h] long long v15; // [rsp+88h] [rbp-C8h] long long v16; // [rsp+90h] [rbp-C0h] long long v17; // [rsp+98h] [rbp-B8h] long long v18; // [rsp+A0h] [rbp-B0h] long long v19; // [rsp+A8h] [rbp-A8h] _BYTE *v20; // [rsp+D8h] [rbp-78h] char v21; // [rsp+E0h] [rbp-70h] BYREF long long v22; // [rsp+E8h] [rbp-68h] long long *v23; // [rsp+F0h] [rbp-60h] long long v24; // [rsp+F8h] [rbp-58h] unsigned int v25; // [rsp+104h] [rbp-4Ch] long long v26; // [rsp+108h] [rbp-48h] unsigned int v27; // [rsp+114h] [rbp-3Ch] long long v28; // [rsp+118h] [rbp-38h] _QWORD *v29; // [rsp+120h] [rbp-30h] _BYTE v30[2]; // [rsp+130h] [rbp-20h] BYREF int v31; // [rsp+132h] [rbp-1Eh] char v32; // [rsp+136h] [rbp-1Ah] char v33; // [rsp+137h] [rbp-19h] __int16 v34; // [rsp+138h] [rbp-18h] char v35; // [rsp+13Ah] [rbp-16h] __int16 v36; // [rsp+13Bh] [rbp-15h] __int16 v37; // [rsp+13Dh] [rbp-13h] _BYTE v38[17]; // [rsp+13Fh] [rbp-11h] BYREF long long savedregs; // [rsp+150h] [rbp+0h] BYREF *(_QWORD *)&v38[9] = __readfsqword(0x28u); v29 = a1; v28 = a2; v27 = a3; v26 = a4; v25 = a5; v24 = a6; v23 = (long long *)*a1; v22 = *v23; v9 = 0; v8 = a1[3] / (unsigned long long)*(unsigned int *)(v22 + 1980); v31 = v8; v32 = BYTE4(v8); v33 = 7; v34 = a7; v35 = 9; v36 = a3; v37 = a5; v20 = v38; v12 = v30; v13 = 15LL; v14 = a4; v15 = a5; v10 = 2; if ( a6 ) { v16 = v24; v17 = 6LL; v18 = v28; v19 = v27; v9 = v27 + 6; v10 = 4; } *((_DWORD *)v29 + 9) = *((_DWORD *)v29 + 8); return (unsigned __int8)translog_write_record( (unsigned int)&v21, 12, v23[1], (_DWORD)v23, v9 + v25 + (_DWORD)v20 - ((unsigned int)&savedregs - 32), v10 + 2, (long long)v11, (long long)v30, 0LL) != 0; }
_ma_log_rt_split: PUSH RBP MOV RBP,RSP SUB RSP,0x150 MOV EAX,dword ptr [RBP + 0x10] MOV RAX,qword ptr FS:[0x28] MOV qword ptr [RBP + -0x8],RAX MOV qword ptr [RBP + -0x30],RDI MOV qword ptr [RBP + -0x38],RSI MOV dword ptr [RBP + -0x3c],EDX MOV qword ptr [RBP + -0x48],RCX MOV dword ptr [RBP + -0x4c],R8D MOV qword ptr [RBP + -0x58],R9 MOV RAX,qword ptr [RBP + -0x30] MOV RAX,qword ptr [RAX] MOV qword ptr [RBP + -0x60],RAX MOV RAX,qword ptr [RBP + -0x60] MOV RAX,qword ptr [RAX] MOV qword ptr [RBP + -0x68],RAX MOV dword ptr [RBP + -0x108],0x0 JMP 0x00186d74 LAB_00186d74: JMP 0x00186d76 LAB_00186d76: JMP 0x00186d78 LAB_00186d78: MOV RAX,qword ptr [RBP + -0x30] MOV RAX,qword ptr [RAX + 0x18] MOV RCX,qword ptr [RBP + -0x68] MOV ECX,dword ptr [RCX + 0x7bc] XOR EDX,EDX DIV RCX MOV qword ptr [RBP + -0x110],RAX LEA RAX,[RBP + -0x20] ADD RAX,0x2 MOV qword ptr [RBP + -0x118],RAX MOV RAX,qword ptr [RBP + -0x110] MOV ECX,EAX MOV RAX,qword ptr [RBP + -0x118] MOV dword ptr [RAX],ECX MOV RAX,qword ptr [RBP + -0x110] SHR RAX,0x20 MOV CL,AL MOV RAX,qword ptr [RBP + -0x118] MOV byte ptr [RAX + 0x4],CL LEA RAX,[RBP + -0x20] ADD RAX,0x2 ADD RAX,0x5 MOV qword ptr [RBP + -0x78],RAX MOV RAX,qword ptr [RBP + -0x78] MOV byte ptr [RAX],0x7 MOV RAX,qword ptr [RBP + -0x78] ADD RAX,0x1 MOV qword ptr [RBP + -0x78],RAX JMP 0x00186df3 LAB_00186df3: JMP 0x00186df5 LAB_00186df5: MOV RAX,qword ptr [RBP + -0x78] MOV qword ptr [RBP + -0x120],RAX MOV EAX,dword ptr [RBP + 0x10] MOV CX,AX MOV RAX,qword ptr [RBP + -0x120] MOV word ptr [RAX],CX MOV RAX,qword ptr [RBP + -0x78] ADD RAX,0x2 MOV qword ptr [RBP + -0x78],RAX MOV RAX,qword ptr [RBP + -0x78] MOV byte ptr [RAX],0x9 MOV RAX,qword ptr [RBP + -0x78] ADD RAX,0x1 MOV qword ptr [RBP + -0x78],RAX MOV RAX,qword ptr [RBP + -0x78] MOV qword ptr [RBP + -0x128],RAX MOV EAX,dword ptr [RBP + -0x3c] MOV CX,AX MOV RAX,qword ptr [RBP + -0x128] MOV word ptr [RAX],CX MOV RAX,qword ptr [RBP + -0x78] ADD RAX,0x2 MOV qword ptr [RBP + -0x78],RAX MOV RAX,qword ptr [RBP + -0x78] MOV qword ptr [RBP + -0x130],RAX MOV EAX,dword ptr [RBP + -0x4c] MOV CX,AX MOV RAX,qword ptr [RBP + -0x130] MOV word ptr [RAX],CX MOV RAX,qword ptr [RBP + -0x78] ADD RAX,0x2 MOV qword ptr [RBP + -0x78],RAX LEA RAX,[RBP + -0x20] MOV qword ptr [RBP + -0xe0],RAX MOV qword ptr [RBP + -0xd8],0xf MOV RAX,qword ptr [RBP + -0x48] MOV qword ptr [RBP + -0xd0],RAX MOV EAX,dword ptr [RBP + -0x4c] MOV qword ptr [RBP + -0xc8],RAX MOV dword ptr [RBP + -0x104],0x2 CMP qword ptr [RBP + -0x58],0x0 JZ 0x00186eff MOV RAX,qword ptr [RBP + -0x58] MOV qword ptr [RBP + -0xc0],RAX MOV qword ptr [RBP + -0xb8],0x6 MOV RAX,qword ptr [RBP + -0x38] MOV qword ptr [RBP + -0xb0],RAX MOV EAX,dword ptr [RBP + -0x3c] MOV qword ptr [RBP + -0xa8],RAX MOV EAX,dword ptr [RBP + -0x3c] ADD EAX,0x6 MOV dword ptr [RBP + -0x108],EAX MOV EAX,dword ptr [RBP + -0x104] ADD EAX,0x2 MOV dword ptr [RBP + -0x104],EAX LAB_00186eff: MOV RAX,qword ptr [RBP + -0x30] MOV ECX,dword ptr [RAX + 0x20] MOV RAX,qword ptr [RBP + -0x30] MOV dword ptr [RAX + 0x24],ECX MOV RAX,qword ptr [RBP + -0x60] MOV RDX,qword ptr [RAX + 0x8] MOV RCX,qword ptr [RBP + -0x60] MOV RAX,qword ptr [RBP + -0x78] LEA RSI,[RBP + -0x20] SUB RAX,RSI MOV ESI,dword ptr [RBP + -0x4c] ADD RAX,RSI MOV ESI,dword ptr [RBP + -0x108] ADD RAX,RSI MOV R8D,EAX MOV R9D,dword ptr [RBP + -0x104] ADD R9D,0x2 LEA R10,[RBP + -0x100] LEA RAX,[RBP + -0x20] LEA RDI,[RBP + -0x70] MOV ESI,0xc XOR R11D,R11D MOV qword ptr [RSP],R10 MOV qword ptr [RSP + 0x8],RAX MOV qword ptr [RSP + 0x10],0x0 CALL 0x0018e280 CMP AL,0x0 JZ 0x00186f7b JMP 0x00186f75 LAB_00186f75: MOV byte ptr [RBP + -0x21],0x1 JMP 0x00186f81 LAB_00186f7b: JMP 0x00186f7d LAB_00186f7d: MOV byte ptr [RBP + -0x21],0x0 LAB_00186f81: MOV AL,byte ptr [RBP + -0x21] MOV byte ptr [RBP + -0x131],AL MOV RAX,qword ptr FS:[0x28] MOV RCX,qword ptr [RBP + -0x8] CMP RAX,RCX JNZ 0x00186fab MOV AL,byte ptr [RBP + -0x131] ADD RSP,0x150 POP RBP RET LAB_00186fab: CALL 0x0012a250
int8 _ma_log_rt_split(long *param_1,int8 param_2,uint param_3,int8 param_4,uint param_5, long param_6,int2 param_7) { char cVar1; ulong uVar2; long in_FS_OFFSET; int local_110; int local_10c; int1 local_108 [32]; int1 *local_e8; int8 local_e0; int8 local_d8; ulong local_d0; long local_c8; int8 local_c0; int8 local_b8; ulong local_b0; int1 *local_80; int1 local_78 [8]; long local_70; long *local_68; long local_60; uint local_54; int8 local_50; uint local_44; int8 local_40; long *local_38; int1 local_29; int1 local_28 [2]; int4 local_26; int1 local_22; int1 local_21; int2 local_20; int1 local_1e; int2 local_1d; int2 local_1b; int1 auStack_19 [9]; long local_10; local_10 = *(long *)(in_FS_OFFSET + 0x28); local_68 = (long *)*param_1; local_70 = *local_68; local_110 = 0; uVar2 = (ulong)param_1[3] / (ulong)*(uint *)(local_70 + 0x7bc); local_26 = (int4)uVar2; local_22 = (int1)(uVar2 >> 0x20); local_21 = 7; local_20 = param_7; local_1e = 9; local_1d = (int2)param_3; local_1b = (int2)param_5; local_80 = auStack_19; local_e8 = local_28; local_e0 = 0xf; local_d0 = (ulong)param_5; local_10c = 2; if (param_6 != 0) { local_c0 = 6; local_b0 = (ulong)param_3; local_110 = param_3 + 6; local_10c = 4; local_c8 = param_6; local_b8 = param_2; } *(int *)((long)param_1 + 0x24) = (int)param_1[4]; local_d8 = param_4; local_60 = param_6; local_54 = param_5; local_50 = param_4; local_44 = param_3; local_40 = param_2; local_38 = param_1; cVar1 = translog_write_record (local_78,0xc,local_68[1],local_68, ((int)local_80 - (int)local_28) + param_5 + local_110,local_10c + 2,local_108, local_28,0); local_29 = cVar1 != '\0'; if (*(long *)(in_FS_OFFSET + 0x28) == local_10) { return CONCAT71((int7)((ulong)*(long *)(in_FS_OFFSET + 0x28) >> 8),local_29); } /* WARNING: Subroutine does not return */ __stack_chk_fail(); }
6,082
gguf_get_val_i8
ngxson[P]ggml-easy/ggml/src/gguf.cpp
int8_t gguf_get_val_i8(const struct gguf_context * ctx, int64_t key_id) { GGML_ASSERT(key_id >= 0 && key_id < gguf_get_n_kv(ctx)); GGML_ASSERT(ctx->kv[key_id].get_ne() == 1); return ctx->kv[key_id].get_val<int8_t>(); }
O2
cpp
gguf_get_val_i8: pushq %r14 pushq %rbx pushq %rax testq %rsi, %rsi js 0x3f5d2 movq %rdi, %rbx movq 0x8(%rdi), %rdi movq 0x10(%rbx), %rax subq %rdi, %rax pushq $0x58 popq %rcx cqto idivq %rcx cmpq %rsi, %rax jle 0x3f5d2 imulq $0x58, %rsi, %r14 addq %r14, %rdi callq 0x1c880 cmpq $0x1, %rax jne 0x3f5ee addq 0x8(%rbx), %r14 movq %r14, %rdi xorl %esi, %esi callq 0x1d1b0 movb (%rax), %al addq $0x8, %rsp popq %rbx popq %r14 retq leaq 0x1b33c(%rip), %rdi # 0x5a915 leaq 0xbfee(%rip), %rdx # 0x4b5ce leaq 0x1b7ba(%rip), %rcx # 0x5ada1 movl $0x329, %esi # imm = 0x329 jmp 0x3f608 leaq 0x1b320(%rip), %rdi # 0x5a915 leaq 0xbfd2(%rip), %rdx # 0x4b5ce leaq 0x1b86d(%rip), %rcx # 0x5ae70 movl $0x32a, %esi # imm = 0x32A xorl %eax, %eax callq 0x1e770
gguf_get_val_i8: push r14 push rbx push rax test rsi, rsi js short loc_3F5D2 mov rbx, rdi mov rdi, [rdi+8] mov rax, [rbx+10h] sub rax, rdi push 58h ; 'X' pop rcx cqo idiv rcx cmp rax, rsi jle short loc_3F5D2 imul r14, rsi, 58h ; 'X' add rdi, r14; this call __ZNK7gguf_kv6get_neEv; gguf_kv::get_ne(void) cmp rax, 1 jnz short loc_3F5EE add r14, [rbx+8] mov rdi, r14 xor esi, esi call __ZNK7gguf_kv7get_valIaEERKT_m; gguf_kv::get_val<signed char>(ulong) mov al, [rax] add rsp, 8 pop rbx pop r14 retn loc_3F5D2: lea rdi, aWorkspaceLlm4b_5; "/workspace/llm4binary/github/2025_star3"... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aKeyId0KeyIdGgu; "key_id >= 0 && key_id < gguf_get_n_kv(c"... mov esi, 329h jmp short loc_3F608 loc_3F5EE: lea rdi, aWorkspaceLlm4b_5; "/workspace/llm4binary/github/2025_star3"... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aCtxKvKeyIdGetN; "ctx->kv[key_id].get_ne() == 1" mov esi, 32Ah loc_3F608: xor eax, eax call _ggml_abort
char gguf_get_val_i8( long long a1, long long a2, __m128 a3, __m128 a4, __m128 a5, __m128 a6, __m128 a7, __m128 a8, __m128 a9, __m128 a10, long long a11, long long a12, long long a13, long long a14) { char v14; // al long long v16; // rdi const char *v18; // rcx int v19; // esi char v20; // [rsp-8h] [rbp-18h] v20 = v14; if ( a2 < 0 || (v16 = *(_QWORD *)(a1 + 8), (*(_QWORD *)(a1 + 16) - v16) / 88 <= a2) ) { v18 = "key_id >= 0 && key_id < gguf_get_n_kv(ctx)"; v19 = 809; goto LABEL_7; } if ( gguf_kv::get_ne((gguf_kv *)(88 * a2 + v16)) != 1 ) { v18 = "ctx->kv[key_id].get_ne() == 1"; v19 = 810; LABEL_7: ggml_abort( "/workspace/llm4binary/github/2025_star3/ngxson[P]ggml-easy/ggml/src/gguf.cpp", v19, (long long)"GGML_ASSERT(%s) failed", (long long)v18, a13, a14, a3, a4, a5, a6, a7, a8, a9, a10, v20); } return *(_BYTE *)gguf_kv::get_val<signed char>(*(_QWORD *)(a1 + 8) + 88 * a2, 0LL); }
gguf_get_val_i8: PUSH R14 PUSH RBX PUSH RAX TEST RSI,RSI JS 0x0013f5d2 MOV RBX,RDI MOV RDI,qword ptr [RDI + 0x8] MOV RAX,qword ptr [RBX + 0x10] SUB RAX,RDI PUSH 0x58 POP RCX CQO IDIV RCX CMP RAX,RSI JLE 0x0013f5d2 IMUL R14,RSI,0x58 ADD RDI,R14 CALL 0x0011c880 CMP RAX,0x1 JNZ 0x0013f5ee ADD R14,qword ptr [RBX + 0x8] MOV RDI,R14 XOR ESI,ESI CALL 0x0011d1b0 MOV AL,byte ptr [RAX] ADD RSP,0x8 POP RBX POP R14 RET LAB_0013f5d2: LEA RDI,[0x15a915] LEA RDX,[0x14b5ce] LEA RCX,[0x15ada1] MOV ESI,0x329 JMP 0x0013f608 LAB_0013f5ee: LEA RDI,[0x15a915] LEA RDX,[0x14b5ce] LEA RCX,[0x15ae70] MOV ESI,0x32a LAB_0013f608: XOR EAX,EAX CALL 0x0011e770
signed gguf_get_val_i8(long param_1,long param_2) { long lVar1; signed *psVar2; char *pcVar3; int8 uVar4; if (-1 < param_2) { if (param_2 < (*(long *)(param_1 + 0x10) - *(long *)(param_1 + 8)) / 0x58) { lVar1 = gguf_kv::get_ne((gguf_kv *)(*(long *)(param_1 + 8) + param_2 * 0x58)); if (lVar1 == 1) { psVar2 = gguf_kv::get_val<signed_char> ((gguf_kv *)(param_2 * 0x58 + *(long *)(param_1 + 8)),0); return *psVar2; } pcVar3 = "ctx->kv[key_id].get_ne() == 1"; uVar4 = 0x32a; goto LAB_0013f608; } } pcVar3 = "key_id >= 0 && key_id < gguf_get_n_kv(ctx)"; uVar4 = 0x329; LAB_0013f608: /* WARNING: Subroutine does not return */ ggml_abort("/workspace/llm4binary/github/2025_star3/ngxson[P]ggml-easy/ggml/src/gguf.cpp",uVar4, "GGML_ASSERT(%s) failed",pcVar3); }
6,083
is_let
bluesky950520[P]quickjs/quickjs.c
static int is_let(JSParseState *s, int decl_mask) { int res = FALSE; if (token_is_pseudo_keyword(s, JS_ATOM_let)) { JSParsePos pos; js_parse_get_pos(s, &pos); for (;;) { if (next_token(s)) { res = -1; break; } if (s->token.val == '[') { /* let [ is a syntax restriction: it never introduces an ExpressionStatement */ res = TRUE; break; } if (s->token.val == '{' || (s->token.val == TOK_IDENT && !s->token.u.ident.is_reserved) || s->token.val == TOK_LET || s->token.val == TOK_YIELD || s->token.val == TOK_AWAIT) { /* Check for possible ASI if not scanning for Declaration */ /* XXX: should also check that `{` introduces a BindingPattern, but Firefox does not and rejects eval("let=1;let\n{if(1)2;}") */ if (s->last_line_num == s->token.line_num || (decl_mask & DECL_MASK_OTHER)) { res = TRUE; break; } break; } break; } if (js_parse_seek_token(s, &pos)) { res = -1; } } return res; }
O1
c
is_let: xorl %eax, %eax cmpl $-0x7d, 0x20(%rdi) jne 0x6da29 pushq %rbp pushq %r15 pushq %r14 pushq %r12 pushq %rbx subq $0x30, %rsp movq %rdi, %rbx cmpl $0x27, 0x38(%rdi) jne 0x6da1d cmpl $0x0, 0x3c(%rbx) jne 0x6da1d movl %esi, %ebp movsd 0x8(%rbx), %xmm0 movaps %xmm0, 0x20(%rsp) movsd 0x24(%rbx), %xmm0 movaps %xmm0, 0x10(%rsp) movq 0x30(%rbx), %r14 movups 0x80(%rbx), %xmm0 movaps %xmm0, (%rsp) movl 0x58(%rbx), %r15d movq %rbx, %rdi callq 0x5d1cf movaps (%rsp), %xmm2 movaps 0x10(%rsp), %xmm1 movaps 0x20(%rsp), %xmm0 movl $0xffffffff, %r12d # imm = 0xFFFFFFFF testl %eax, %eax jne 0x6d9f3 movl 0x20(%rbx), %ecx cmpl $0x5a, %ecx jg 0x6d9d3 leal 0x2f(%rcx), %eax cmpl $0x7, %eax ja 0x6d9b4 movl $0xc1, %edx btl %eax, %edx jb 0x6d9dd cmpl $-0x7d, %ecx jne 0x6d9ce cmpl $0x0, 0x40(%rbx) je 0x6d9dd cmpl $0x7, %eax ja 0x6d9ce movl $0xc1, %ecx btl %eax, %ecx jb 0x6d9dd xorl %r12d, %r12d jmp 0x6d9f3 cmpl $0x5b, %ecx je 0x6da2a cmpl $0x7b, %ecx jne 0x6d9ce movl 0x8(%rbx), %eax cmpl 0x24(%rbx), %eax sete %al andl $0x4, %ebp shrl $0x2, %ebp orb %al, %bpl movzbl %bpl, %r12d movlps %xmm0, 0x24(%rbx) movlps %xmm1, 0x10(%rbx) movq %r14, 0x70(%rbx) movups %xmm2, 0x80(%rbx) movl %r15d, 0x58(%rbx) movq %rbx, %rdi callq 0x5d1cf movl %eax, %ecx xorl %eax, %eax negl %ecx sbbl %eax, %eax orl %r12d, %eax addq $0x30, %rsp popq %rbx popq %r12 popq %r14 popq %r15 popq %rbp retq movl $0x1, %r12d jmp 0x6d9f3
is_let: xor eax, eax cmp dword ptr [rdi+20h], 0FFFFFF83h jnz locret_6DA29 push rbp push r15 push r14 push r12 push rbx sub rsp, 30h mov rbx, rdi cmp dword ptr [rdi+38h], 27h ; ''' jnz loc_6DA1D cmp dword ptr [rbx+3Ch], 0 jnz loc_6DA1D mov ebp, esi movsd xmm0, qword ptr [rbx+8] movaps [rsp+58h+var_38], xmm0 movsd xmm0, qword ptr [rbx+24h] movaps [rsp+58h+var_48], xmm0 mov r14, [rbx+30h] movups xmm0, xmmword ptr [rbx+80h] movaps [rsp+58h+var_58], xmm0 mov r15d, [rbx+58h] mov rdi, rbx call next_token movaps xmm2, [rsp+58h+var_58] movaps xmm1, [rsp+58h+var_48] movaps xmm0, [rsp+58h+var_38] mov r12d, 0FFFFFFFFh test eax, eax jnz short loc_6D9F3 mov ecx, [rbx+20h] cmp ecx, 5Ah ; 'Z' jg short loc_6D9D3 lea eax, [rcx+2Fh] cmp eax, 7 ja short loc_6D9B4 mov edx, 0C1h bt edx, eax jb short loc_6D9DD loc_6D9B4: cmp ecx, 0FFFFFF83h jnz short loc_6D9CE cmp dword ptr [rbx+40h], 0 jz short loc_6D9DD cmp eax, 7 ja short loc_6D9CE mov ecx, 0C1h bt ecx, eax jb short loc_6D9DD loc_6D9CE: xor r12d, r12d jmp short loc_6D9F3 loc_6D9D3: cmp ecx, 5Bh ; '[' jz short loc_6DA2A cmp ecx, 7Bh ; '{' jnz short loc_6D9CE loc_6D9DD: mov eax, [rbx+8] cmp eax, [rbx+24h] setz al and ebp, 4 shr ebp, 2 or bpl, al movzx r12d, bpl loc_6D9F3: movlps qword ptr [rbx+24h], xmm0 movlps qword ptr [rbx+10h], xmm1 mov [rbx+70h], r14 movups xmmword ptr [rbx+80h], xmm2 mov [rbx+58h], r15d mov rdi, rbx call next_token mov ecx, eax xor eax, eax neg ecx sbb eax, eax or eax, r12d loc_6DA1D: add rsp, 30h pop rbx pop r12 pop r14 pop r15 pop rbp locret_6DA29: retn loc_6DA2A: mov r12d, 1 jmp short loc_6D9F3
long long is_let( long long a1, long long a2, long long a3, long long a4, long long a5, long long a6, double a7, __m128 a8, __m128 a9, __m128 a10, __m128 a11, __m128 a12, __m128 a13, __m128 a14) { long long result; // rax long long v15; // r14 int v16; // r15d long long v17; // rdx long long v18; // rcx long long v19; // r8 long long v20; // r9 __m128 v21; // xmm4 __m128 v22; // xmm5 int v23; // r12d unsigned int v24; // eax __m128 v25; // [rsp+0h] [rbp-58h] __m128 v26; // [rsp+10h] [rbp-48h] __m128 v27; // [rsp+20h] [rbp-38h] result = 0LL; if ( *(_DWORD *)(a1 + 32) == -125 && *(_DWORD *)(a1 + 56) == 39 && !*(_DWORD *)(a1 + 60) ) { v27 = (__m128)*(unsigned long long *)(a1 + 8); v26 = (__m128)*(unsigned long long *)(a1 + 36); v15 = *(_QWORD *)(a1 + 48); v25 = *(__m128 *)(a1 + 128); v16 = *(_DWORD *)(a1 + 88); v23 = -1; if ( (unsigned int)next_token(a1, v25, a8, a9, a10, a11, a12, a13, a14, a2, a3, a4, a5, a6) ) { LABEL_16: _mm_storel_ps((double *)(a1 + 36), v27); _mm_storel_ps((double *)(a1 + 16), v26); *(_QWORD *)(a1 + 112) = v15; *(__m128 *)(a1 + 128) = v25; *(_DWORD *)(a1 + 88) = v16; return v23 | (unsigned int)-((unsigned int)next_token( a1, v27, v26, v25, a10, v21, v22, a13, a14, a2, v17, v18, v19, v20) != 0); } v18 = *(unsigned int *)(a1 + 32); if ( (int)v18 > 90 ) { if ( (_DWORD)v18 == 91 ) { v23 = 1; goto LABEL_16; } if ( (_DWORD)v18 != 123 ) goto LABEL_12; } else { v24 = v18 + 47; if ( (unsigned int)(v18 + 47) > 7 || (v17 = 193LL, !_bittest((const int *)&v17, v24)) ) { if ( (_DWORD)v18 != -125 || *(_DWORD *)(a1 + 64) && (v24 > 7 || (v18 = 193LL, !_bittest((const int *)&v18, v24))) ) { LABEL_12: v23 = 0; goto LABEL_16; } } } v23 = (*(_DWORD *)(a1 + 8) == *(_DWORD *)(a1 + 36)) | ((unsigned __int8)(a2 & 4) >> 2); goto LABEL_16; } return result; }
is_let: XOR EAX,EAX CMP dword ptr [RDI + 0x20],-0x7d JNZ 0x0016da29 PUSH RBP PUSH R15 PUSH R14 PUSH R12 PUSH RBX SUB RSP,0x30 MOV RBX,RDI CMP dword ptr [RDI + 0x38],0x27 JNZ 0x0016da1d CMP dword ptr [RBX + 0x3c],0x0 JNZ 0x0016da1d MOV EBP,ESI MOVSD XMM0,qword ptr [RBX + 0x8] MOVAPS xmmword ptr [RSP + 0x20],XMM0 MOVSD XMM0,qword ptr [RBX + 0x24] MOVAPS xmmword ptr [RSP + 0x10],XMM0 MOV R14,qword ptr [RBX + 0x30] MOVUPS XMM0,xmmword ptr [RBX + 0x80] MOVAPS xmmword ptr [RSP],XMM0 MOV R15D,dword ptr [RBX + 0x58] MOV RDI,RBX CALL 0x0015d1cf MOVAPS XMM2,xmmword ptr [RSP] MOVAPS XMM1,xmmword ptr [RSP + 0x10] MOVAPS XMM0,xmmword ptr [RSP + 0x20] MOV R12D,0xffffffff TEST EAX,EAX JNZ 0x0016d9f3 MOV ECX,dword ptr [RBX + 0x20] CMP ECX,0x5a JG 0x0016d9d3 LEA EAX,[RCX + 0x2f] CMP EAX,0x7 JA 0x0016d9b4 MOV EDX,0xc1 BT EDX,EAX JC 0x0016d9dd LAB_0016d9b4: CMP ECX,-0x7d JNZ 0x0016d9ce CMP dword ptr [RBX + 0x40],0x0 JZ 0x0016d9dd CMP EAX,0x7 JA 0x0016d9ce MOV ECX,0xc1 BT ECX,EAX JC 0x0016d9dd LAB_0016d9ce: XOR R12D,R12D JMP 0x0016d9f3 LAB_0016d9d3: CMP ECX,0x5b JZ 0x0016da2a CMP ECX,0x7b JNZ 0x0016d9ce LAB_0016d9dd: MOV EAX,dword ptr [RBX + 0x8] CMP EAX,dword ptr [RBX + 0x24] SETZ AL AND EBP,0x4 SHR EBP,0x2 OR BPL,AL MOVZX R12D,BPL LAB_0016d9f3: MOVLPS qword ptr [RBX + 0x24],XMM0 MOVLPS qword ptr [RBX + 0x10],XMM1 MOV qword ptr [RBX + 0x70],R14 MOVUPS xmmword ptr [RBX + 0x80],XMM2 MOV dword ptr [RBX + 0x58],R15D MOV RDI,RBX CALL 0x0015d1cf MOV ECX,EAX XOR EAX,EAX NEG ECX SBB EAX,EAX OR EAX,R12D LAB_0016da1d: ADD RSP,0x30 POP RBX POP R12 POP R14 POP R15 POP RBP LAB_0016da29: RET LAB_0016da2a: MOV R12D,0x1 JMP 0x0016d9f3
uint is_let(long param_1,uint param_2) { int8 uVar1; int8 uVar2; int4 uVar3; int8 uVar4; int4 uVar5; int4 uVar6; int4 uVar7; int4 uVar8; int iVar9; uint uVar10; int4 local_48; int4 uStack_44; int4 local_38; int4 uStack_34; if (*(int *)(param_1 + 0x20) != -0x7d) { return 0; } if (*(int *)(param_1 + 0x38) != 0x27) { return 0; } if (*(int *)(param_1 + 0x3c) != 0) { return 0; } uVar1 = *(int8 *)(param_1 + 8); uVar2 = *(int8 *)(param_1 + 0x24); uVar4 = *(int8 *)(param_1 + 0x30); uVar5 = *(int4 *)(param_1 + 0x80); uVar6 = *(int4 *)(param_1 + 0x84); uVar7 = *(int4 *)(param_1 + 0x88); uVar8 = *(int4 *)(param_1 + 0x8c); uVar3 = *(int4 *)(param_1 + 0x58); iVar9 = next_token(param_1); local_48 = (int4)uVar2; uStack_44 = (int4)((ulong)uVar2 >> 0x20); local_38 = (int4)uVar1; uStack_34 = (int4)((ulong)uVar1 >> 0x20); uVar10 = 0xffffffff; if (iVar9 != 0) goto LAB_0016d9f3; iVar9 = *(int *)(param_1 + 0x20); if (iVar9 < 0x5b) { uVar10 = iVar9 + 0x2f; if (((uVar10 < 8) && ((0xc1U >> (uVar10 & 0x1f) & 1) != 0)) || ((iVar9 == -0x7d && ((*(int *)(param_1 + 0x40) == 0 || ((uVar10 < 8 && ((0xc1U >> (uVar10 & 0x1f) & 1) != 0))))) ))) { LAB_0016d9dd: uVar10 = (uint)(byte)((byte)((param_2 & 4) >> 2) | *(int *)(param_1 + 8) == *(int *)(param_1 + 0x24)); goto LAB_0016d9f3; } } else { if (iVar9 == 0x5b) { uVar10 = 1; goto LAB_0016d9f3; } if (iVar9 == 0x7b) goto LAB_0016d9dd; } uVar10 = 0; LAB_0016d9f3: *(int4 *)(param_1 + 0x24) = local_38; *(int4 *)(param_1 + 0x28) = uStack_34; *(int4 *)(param_1 + 0x10) = local_48; *(int4 *)(param_1 + 0x14) = uStack_44; *(int8 *)(param_1 + 0x70) = uVar4; *(int4 *)(param_1 + 0x80) = uVar5; *(int4 *)(param_1 + 0x84) = uVar6; *(int4 *)(param_1 + 0x88) = uVar7; *(int4 *)(param_1 + 0x8c) = uVar8; *(int4 *)(param_1 + 0x58) = uVar3; iVar9 = next_token(param_1); return -(uint)(iVar9 != 0) | uVar10; }
6,084
ft_nlq_read_next
eloqsql/storage/myisam/ft_nlq_search.c
int ft_nlq_read_next(FT_INFO *handler, char *record) { MI_INFO *info= (MI_INFO *) handler->info; if (++handler->curdoc >= handler->ndocs) { --handler->curdoc; return HA_ERR_END_OF_FILE; } info->update&= (HA_STATE_CHANGED | HA_STATE_ROW_CHANGED); info->lastpos=handler->doc[handler->curdoc].dpos; if (!(*info->read_record)(info,info->lastpos,(uchar*) record)) { info->update|= HA_STATE_AKTIV; /* Record is read */ return 0; } return my_errno; }
O0
c
ft_nlq_read_next: pushq %rbp movq %rsp, %rbp subq $0x20, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq -0x10(%rbp), %rax movq 0x8(%rax), %rax movq %rax, -0x20(%rbp) movq -0x10(%rbp), %rcx movl 0x14(%rcx), %eax addl $0x1, %eax movl %eax, 0x14(%rcx) movq -0x10(%rbp), %rcx cmpl 0x10(%rcx), %eax jl 0xa2efb movq -0x10(%rbp), %rax movl 0x14(%rax), %ecx addl $-0x1, %ecx movl %ecx, 0x14(%rax) movl $0x89, -0x4(%rbp) jmp 0xa2f81 movq -0x20(%rbp), %rax movl 0x1d0(%rax), %ecx andl $0x401, %ecx # imm = 0x401 movl %ecx, 0x1d0(%rax) movq -0x10(%rbp), %rax addq $0x18, %rax movq -0x10(%rbp), %rcx movslq 0x14(%rcx), %rcx shlq $0x4, %rcx addq %rcx, %rax movq (%rax), %rcx movq -0x20(%rbp), %rax movq %rcx, 0x170(%rax) movq -0x20(%rbp), %rax movq 0x140(%rax), %rax movq -0x20(%rbp), %rdi movq -0x20(%rbp), %rcx movq 0x170(%rcx), %rsi movq -0x18(%rbp), %rdx callq *%rax cmpl $0x0, %eax jne 0xa2f77 movq -0x20(%rbp), %rax movl 0x1d0(%rax), %ecx orl $0x2, %ecx movl %ecx, 0x1d0(%rax) movl $0x0, -0x4(%rbp) jmp 0xa2f81 callq 0xf7a70 movl (%rax), %eax movl %eax, -0x4(%rbp) movl -0x4(%rbp), %eax addq $0x20, %rsp popq %rbp retq nopw (%rax,%rax)
ft_nlq_read_next: push rbp mov rbp, rsp sub rsp, 20h mov [rbp+var_10], rdi mov [rbp+var_18], rsi mov rax, [rbp+var_10] mov rax, [rax+8] mov [rbp+var_20], rax mov rcx, [rbp+var_10] mov eax, [rcx+14h] add eax, 1 mov [rcx+14h], eax mov rcx, [rbp+var_10] cmp eax, [rcx+10h] jl short loc_A2EFB mov rax, [rbp+var_10] mov ecx, [rax+14h] add ecx, 0FFFFFFFFh mov [rax+14h], ecx mov [rbp+var_4], 89h jmp loc_A2F81 loc_A2EFB: mov rax, [rbp+var_20] mov ecx, [rax+1D0h] and ecx, 401h mov [rax+1D0h], ecx mov rax, [rbp+var_10] add rax, 18h mov rcx, [rbp+var_10] movsxd rcx, dword ptr [rcx+14h] shl rcx, 4 add rax, rcx mov rcx, [rax] mov rax, [rbp+var_20] mov [rax+170h], rcx mov rax, [rbp+var_20] mov rax, [rax+140h] mov rdi, [rbp+var_20] mov rcx, [rbp+var_20] mov rsi, [rcx+170h] mov rdx, [rbp+var_18] call rax cmp eax, 0 jnz short loc_A2F77 mov rax, [rbp+var_20] mov ecx, [rax+1D0h] or ecx, 2 mov [rax+1D0h], ecx mov [rbp+var_4], 0 jmp short loc_A2F81 loc_A2F77: call _my_thread_var mov eax, [rax] mov [rbp+var_4], eax loc_A2F81: mov eax, [rbp+var_4] add rsp, 20h pop rbp retn
long long ft_nlq_read_next(long long a1, long long a2) { int v2; // eax const char *v3; // rsi long long v5; // [rsp+0h] [rbp-20h] v5 = *(_QWORD *)(a1 + 8); v2 = *(_DWORD *)(a1 + 20) + 1; *(_DWORD *)(a1 + 20) = v2; if ( v2 < *(_DWORD *)(a1 + 16) ) { *(_DWORD *)(v5 + 464) &= 0x401u; *(_QWORD *)(v5 + 368) = *(_QWORD *)(16LL * *(int *)(a1 + 20) + a1 + 24); v3 = *(const char **)(v5 + 368); if ( (*(unsigned int ( **)(long long, const char *, long long))(v5 + 320))(v5, v3, a2) ) { return *(unsigned int *)my_thread_var(v5, v3); } else { *(_DWORD *)(v5 + 464) |= 2u; return 0; } } else { --*(_DWORD *)(a1 + 20); return 137; } }
ft_nlq_read_next: PUSH RBP MOV RBP,RSP SUB RSP,0x20 MOV qword ptr [RBP + -0x10],RDI MOV qword ptr [RBP + -0x18],RSI MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x8] MOV qword ptr [RBP + -0x20],RAX MOV RCX,qword ptr [RBP + -0x10] MOV EAX,dword ptr [RCX + 0x14] ADD EAX,0x1 MOV dword ptr [RCX + 0x14],EAX MOV RCX,qword ptr [RBP + -0x10] CMP EAX,dword ptr [RCX + 0x10] JL 0x001a2efb MOV RAX,qword ptr [RBP + -0x10] MOV ECX,dword ptr [RAX + 0x14] ADD ECX,-0x1 MOV dword ptr [RAX + 0x14],ECX MOV dword ptr [RBP + -0x4],0x89 JMP 0x001a2f81 LAB_001a2efb: MOV RAX,qword ptr [RBP + -0x20] MOV ECX,dword ptr [RAX + 0x1d0] AND ECX,0x401 MOV dword ptr [RAX + 0x1d0],ECX MOV RAX,qword ptr [RBP + -0x10] ADD RAX,0x18 MOV RCX,qword ptr [RBP + -0x10] MOVSXD RCX,dword ptr [RCX + 0x14] SHL RCX,0x4 ADD RAX,RCX MOV RCX,qword ptr [RAX] MOV RAX,qword ptr [RBP + -0x20] MOV qword ptr [RAX + 0x170],RCX MOV RAX,qword ptr [RBP + -0x20] MOV RAX,qword ptr [RAX + 0x140] MOV RDI,qword ptr [RBP + -0x20] MOV RCX,qword ptr [RBP + -0x20] MOV RSI,qword ptr [RCX + 0x170] MOV RDX,qword ptr [RBP + -0x18] CALL RAX CMP EAX,0x0 JNZ 0x001a2f77 MOV RAX,qword ptr [RBP + -0x20] MOV ECX,dword ptr [RAX + 0x1d0] OR ECX,0x2 MOV dword ptr [RAX + 0x1d0],ECX MOV dword ptr [RBP + -0x4],0x0 JMP 0x001a2f81 LAB_001a2f77: CALL 0x001f7a70 MOV EAX,dword ptr [RAX] MOV dword ptr [RBP + -0x4],EAX LAB_001a2f81: MOV EAX,dword ptr [RBP + -0x4] ADD RSP,0x20 POP RBP RET
int4 ft_nlq_read_next(long param_1,int8 param_2) { long lVar1; int iVar2; int4 *puVar3; int4 local_c; lVar1 = *(long *)(param_1 + 8); iVar2 = *(int *)(param_1 + 0x14) + 1; *(int *)(param_1 + 0x14) = iVar2; if (iVar2 < *(int *)(param_1 + 0x10)) { *(uint *)(lVar1 + 0x1d0) = *(uint *)(lVar1 + 0x1d0) & 0x401; *(int8 *)(lVar1 + 0x170) = *(int8 *)(param_1 + 0x18 + (long)*(int *)(param_1 + 0x14) * 0x10); iVar2 = (**(code **)(lVar1 + 0x140))(lVar1,*(int8 *)(lVar1 + 0x170),param_2); if (iVar2 == 0) { *(uint *)(lVar1 + 0x1d0) = *(uint *)(lVar1 + 0x1d0) | 2; local_c = 0; } else { puVar3 = (int4 *)_my_thread_var(); local_c = *puVar3; } } else { *(int *)(param_1 + 0x14) = *(int *)(param_1 + 0x14) + -1; local_c = 0x89; } return local_c; }
6,085
ma_scramble_41
eloqsql/libmariadb/libmariadb/ma_password.c
void ma_scramble_41(const unsigned char *buffer, const char *scramble, const char *password) { _MA_SHA1_CTX context; unsigned char sha1[SHA1_MAX_LENGTH]; unsigned char sha2[SHA1_MAX_LENGTH]; /* Phase 1: hash password */ ma_SHA1Init(&context); ma_SHA1Update(&context, (unsigned char *)password, strlen((char *)password)); ma_SHA1Final(sha1, &context); /* Phase 2: hash sha1 */ ma_SHA1Init(&context); ma_SHA1Update(&context, (unsigned char*)sha1, SHA1_MAX_LENGTH); ma_SHA1Final(sha2, &context); /* Phase 3: hash scramble + sha2 */ ma_SHA1Init(&context); ma_SHA1Update(&context, (unsigned char *)scramble, SCRAMBLE_LENGTH); ma_SHA1Update(&context, (unsigned char*)sha2, SHA1_MAX_LENGTH); ma_SHA1Final((unsigned char *)buffer, &context); /* let's crypt buffer now */ my_crypt((uchar *)buffer, (const unsigned char *)buffer, (const unsigned char *)sha1, SHA1_MAX_LENGTH); }
O0
c
ma_scramble_41: pushq %rbp movq %rsp, %rbp subq $0xe0, %rsp movq %fs:0x28, %rax movq %rax, -0x8(%rbp) movq %rdi, -0xa8(%rbp) movq %rsi, -0xb0(%rbp) movq %rdx, -0xb8(%rbp) leaq -0x64(%rbp), %rdi movq %rdi, -0xd0(%rbp) callq 0x6d8b0 movq -0xb8(%rbp), %rdi movq %rdi, -0xe0(%rbp) callq 0x36400 movq -0xe0(%rbp), %rsi movq -0xd0(%rbp), %rdi movq %rax, %rdx callq 0x6d910 movq -0xd0(%rbp), %rsi leaq -0x80(%rbp), %rdi movq %rdi, -0xc8(%rbp) callq 0x6f680 movq -0xd0(%rbp), %rdi callq 0x6d8b0 movq -0xd0(%rbp), %rdi movq -0xc8(%rbp), %rsi movl $0x14, %edx movq %rdx, -0xc0(%rbp) callq 0x6d910 movq -0xd0(%rbp), %rsi leaq -0xa0(%rbp), %rdi movq %rdi, -0xd8(%rbp) callq 0x6f680 movq -0xd0(%rbp), %rdi callq 0x6d8b0 movq -0xd0(%rbp), %rdi movq -0xc0(%rbp), %rdx movq -0xb0(%rbp), %rsi callq 0x6d910 movq -0xd8(%rbp), %rsi movq -0xd0(%rbp), %rdi movq -0xc0(%rbp), %rdx callq 0x6d910 movq -0xd0(%rbp), %rsi movq -0xa8(%rbp), %rdi callq 0x6f680 movq -0xc8(%rbp), %rdx movq -0xc0(%rbp), %rcx movq -0xa8(%rbp), %rsi movq %rsi, %rdi callq 0x6d310 movq %fs:0x28, %rax movq -0x8(%rbp), %rcx cmpq %rcx, %rax jne 0x6d4cd addq $0xe0, %rsp popq %rbp retq callq 0x362a0 nopw %cs:(%rax,%rax)
ma_scramble_41: push rbp mov rbp, rsp sub rsp, 0E0h mov rax, fs:28h mov [rbp+var_8], rax mov [rbp+var_A8], rdi mov [rbp+var_B0], rsi mov [rbp+var_B8], rdx lea rdi, [rbp+var_64] mov [rbp+var_D0], rdi call ma_SHA1Init mov rdi, [rbp+var_B8] mov [rbp+var_E0], rdi call _strlen mov rsi, [rbp+var_E0] mov rdi, [rbp+var_D0] mov rdx, rax call ma_SHA1Update mov rsi, [rbp+var_D0] lea rdi, [rbp+var_80] mov [rbp+var_C8], rdi call ma_SHA1Final mov rdi, [rbp+var_D0] call ma_SHA1Init mov rdi, [rbp+var_D0] mov rsi, [rbp+var_C8] mov edx, 14h mov [rbp+var_C0], rdx call ma_SHA1Update mov rsi, [rbp+var_D0] lea rdi, [rbp+var_A0] mov [rbp+var_D8], rdi call ma_SHA1Final mov rdi, [rbp+var_D0] call ma_SHA1Init mov rdi, [rbp+var_D0] mov rdx, [rbp+var_C0] mov rsi, [rbp+var_B0] call ma_SHA1Update mov rsi, [rbp+var_D8] mov rdi, [rbp+var_D0] mov rdx, [rbp+var_C0] call ma_SHA1Update mov rsi, [rbp+var_D0] mov rdi, [rbp+var_A8] call ma_SHA1Final mov rdx, [rbp+var_C8] mov rcx, [rbp+var_C0] mov rsi, [rbp+var_A8] mov rdi, rsi call my_crypt_0 mov rax, fs:28h mov rcx, [rbp+var_8] cmp rax, rcx jnz short loc_6D4CD add rsp, 0E0h pop rbp retn loc_6D4CD: call ___stack_chk_fail
unsigned long long ma_scramble_41(_BYTE *a1, long long a2, long long a3) { long long v3; // rax _BYTE v6[32]; // [rsp+40h] [rbp-A0h] BYREF _BYTE v7[28]; // [rsp+60h] [rbp-80h] BYREF _BYTE v8[92]; // [rsp+7Ch] [rbp-64h] BYREF unsigned long long v9; // [rsp+D8h] [rbp-8h] v9 = __readfsqword(0x28u); ((void (*)(void))ma_SHA1Init)(); v3 = strlen(a3); ma_SHA1Update(v8, a3, v3); ma_SHA1Final(v7, v8); ma_SHA1Init(v8); ma_SHA1Update(v8, v7, 20LL); ma_SHA1Final(v6, v8); ma_SHA1Init(v8); ma_SHA1Update(v8, a2, 20LL); ma_SHA1Update(v8, v6, 20LL); ma_SHA1Final(a1, v8); my_crypt_0(a1, a1, v7, 20LL); return __readfsqword(0x28u); }
ma_scramble_41: PUSH RBP MOV RBP,RSP SUB RSP,0xe0 MOV RAX,qword ptr FS:[0x28] MOV qword ptr [RBP + -0x8],RAX MOV qword ptr [RBP + -0xa8],RDI MOV qword ptr [RBP + -0xb0],RSI MOV qword ptr [RBP + -0xb8],RDX LEA RDI,[RBP + -0x64] MOV qword ptr [RBP + -0xd0],RDI CALL 0x0016d8b0 MOV RDI,qword ptr [RBP + -0xb8] MOV qword ptr [RBP + -0xe0],RDI CALL 0x00136400 MOV RSI,qword ptr [RBP + -0xe0] MOV RDI,qword ptr [RBP + -0xd0] MOV RDX,RAX CALL 0x0016d910 MOV RSI,qword ptr [RBP + -0xd0] LEA RDI,[RBP + -0x80] MOV qword ptr [RBP + -0xc8],RDI CALL 0x0016f680 MOV RDI,qword ptr [RBP + -0xd0] CALL 0x0016d8b0 MOV RDI,qword ptr [RBP + -0xd0] MOV RSI,qword ptr [RBP + -0xc8] MOV EDX,0x14 MOV qword ptr [RBP + -0xc0],RDX CALL 0x0016d910 MOV RSI,qword ptr [RBP + -0xd0] LEA RDI,[RBP + -0xa0] MOV qword ptr [RBP + -0xd8],RDI CALL 0x0016f680 MOV RDI,qword ptr [RBP + -0xd0] CALL 0x0016d8b0 MOV RDI,qword ptr [RBP + -0xd0] MOV RDX,qword ptr [RBP + -0xc0] MOV RSI,qword ptr [RBP + -0xb0] CALL 0x0016d910 MOV RSI,qword ptr [RBP + -0xd8] MOV RDI,qword ptr [RBP + -0xd0] MOV RDX,qword ptr [RBP + -0xc0] CALL 0x0016d910 MOV RSI,qword ptr [RBP + -0xd0] MOV RDI,qword ptr [RBP + -0xa8] CALL 0x0016f680 MOV RDX,qword ptr [RBP + -0xc8] MOV RCX,qword ptr [RBP + -0xc0] MOV RSI,qword ptr [RBP + -0xa8] MOV RDI,RSI CALL 0x0016d310 MOV RAX,qword ptr FS:[0x28] MOV RCX,qword ptr [RBP + -0x8] CMP RAX,RCX JNZ 0x0016d4cd ADD RSP,0xe0 POP RBP RET LAB_0016d4cd: CALL 0x001362a0
void ma_scramble_41(int8 param_1,int8 param_2,char *param_3) { size_t sVar1; long in_FS_OFFSET; int1 local_a8 [32]; int1 local_88 [28]; int1 local_6c [92]; long local_10; local_10 = *(long *)(in_FS_OFFSET + 0x28); ma_SHA1Init(); sVar1 = strlen(param_3); ma_SHA1Update(local_6c,param_3,sVar1); ma_SHA1Final(local_88,local_6c); ma_SHA1Init(local_6c); ma_SHA1Update(local_6c,local_88); ma_SHA1Final(local_a8,local_6c); ma_SHA1Init(local_6c); ma_SHA1Update(local_6c,param_2,0x14); ma_SHA1Update(local_6c,local_a8,0x14); ma_SHA1Final(param_1,local_6c); my_crypt(param_1,param_1,local_88,0x14); if (*(long *)(in_FS_OFFSET + 0x28) == local_10) { return; } /* WARNING: Subroutine does not return */ __stack_chk_fail(); }
6,086
my_uuid
eloqsql/mysys/my_uuid.c
void my_uuid(uchar *to) { ulonglong tv; uint32 time_low; uint16 time_mid, time_hi_and_version; DBUG_ASSERT(my_uuid_inited); mysql_mutex_lock(&LOCK_uuid_generator); tv= my_interval_timer()/100 + interval_timer_offset + nanoseq; if (likely(tv > uuid_time)) { /* Current time is ahead of last timestamp, as it should be. If we "borrowed time", give it back, just as long as we stay ahead of the previous timestamp. */ if (nanoseq) { ulong delta; DBUG_ASSERT((tv > uuid_time) && (nanoseq > 0)); /* -1 so we won't make tv= uuid_time for nanoseq >= (tv - uuid_time) */ delta= MY_MIN(nanoseq, (ulong)(tv - uuid_time -1)); tv-= delta; nanoseq-= delta; } } else { if (unlikely(tv == uuid_time)) { /* For low-res system clocks. If several requests for UUIDs end up on the same tick, we add a nano-second to make them different. ( current_timestamp + nanoseq * calls_in_this_period ) may end up > next_timestamp; this is OK. Nonetheless, we'll try to unwind nanoseq when we get a chance to. If nanoseq overflows, we'll start over with a new numberspace (so the if() below is needed so we can avoid the ++tv and thus match the follow-up if() if nanoseq overflows!). */ if (likely(++nanoseq)) ++tv; } if (unlikely(tv <= uuid_time)) { /* If the admin changes the system clock (or due to Daylight Saving Time), the system clock may be turned *back* so we go through a period once more for which we already gave out UUIDs. To avoid duplicate UUIDs despite potentially identical times, we make a new random component. We also come here if the nanoseq "borrowing" overflows. In either case, we throw away any nanoseq borrowing since it's irrelevant in the new numberspace. */ set_clock_seq(); tv= my_interval_timer()/100 + interval_timer_offset; nanoseq= 0; DBUG_PRINT("uuid",("making new numberspace")); } } uuid_time=tv; mysql_mutex_unlock(&LOCK_uuid_generator); time_low= (uint32) (tv & 0xFFFFFFFF); time_mid= (uint16) ((tv >> 32) & 0xFFFF); time_hi_and_version= (uint16) ((tv >> 48) | UUID_VERSION); /* Note, that the standard does NOT specify byte ordering in multi-byte fields. it's implementation defined (but must be the same for all fields). We use big-endian, so we can use memcmp() to compare UUIDs and for straightforward UUID to string conversion. */ mi_int4store(to, time_low); mi_int2store(to+4, time_mid); mi_int2store(to+6, time_hi_and_version); bmove(to+8, uuid_suffix, sizeof(uuid_suffix)); }
O3
c
my_uuid: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %rbx pushq %rax movq %rdi, %rbx cmpq $0x0, 0xb66f67(%rip) # 0xc14bd0 jne 0xadd54 leaq 0xb66f1a(%rip), %rdi # 0xc14b90 callq 0x2a1f0 callq 0xa5744 shrq $0x2, %rax movabsq $0x28f5c28f5c28f5c3, %r15 # imm = 0x28F5C28F5C28F5C3 mulq %r15 movq %rdx, %r14 shrq $0x2, %r14 addq 0xb66ec1(%rip), %r14 # 0xc14b60 movl 0xb66ec3(%rip), %eax # 0xc14b68 addq %rax, %r14 movq 0xb66f29(%rip), %rcx # 0xc14bd8 cmpq %rcx, %r14 jbe 0xadd5e testq %rax, %rax je 0xadcd5 notq %rcx addq %r14, %rcx cmpq %rax, %rcx cmovaeq %rax, %rcx subq %rcx, %r14 subl %ecx, %eax movl %eax, 0xb66e93(%rip) # 0xc14b68 movq %r14, 0xb66efc(%rip) # 0xc14bd8 movq 0xb66eed(%rip), %rdi # 0xc14bd0 testq %rdi, %rdi jne 0xadd8f leaq 0xb66e9d(%rip), %rdi # 0xc14b90 callq 0x2a1c0 movq %r14, %rax shrq $0x20, %rax movq %r14, %rcx shrq $0x30, %rcx movl %r14d, %edx rolw $0x8, %dx movw %dx, 0x2(%rbx) movl %r14d, %edx shrl $0x10, %edx movb %dl, 0x1(%rbx) movl %r14d, %edx shrl $0x18, %edx movb %dl, (%rbx) movb %al, 0x5(%rbx) movq %r14, %rax shrq $0x28, %rax movb %al, 0x4(%rbx) movb %cl, 0x7(%rbx) shrq $0x38, %r14 orb $0x10, %r14b movb %r14b, 0x6(%rbx) movq 0xb66e0b(%rip), %rax # 0xc14b50 movq %rax, 0x8(%rbx) addq $0x8, %rsp popq %rbx popq %r14 popq %r15 popq %rbp retq callq 0x31049 jmp 0xadc7b je 0xadda4 cmpq %rcx, %r14 ja 0xadcd5 callq 0xade80 callq 0xa5744 shrq $0x2, %rax mulq %r15 movq %rdx, %r14 shrq $0x2, %r14 addq 0xb66dd8(%rip), %r14 # 0xc14b60 xorl %eax, %eax jmp 0xadccf leaq 0x2e3142(%rip), %rax # 0x390ed8 movq (%rax), %rax callq *0x160(%rax) jmp 0xadcec xorl %edx, %edx incl %eax movl %eax, 0xb66dba(%rip) # 0xc14b68 setne %dl addq %rdx, %r14 jmp 0xadd60
my_uuid: push rbp mov rbp, rsp push r15 push r14 push rbx push rax mov rbx, rdi cmp cs:qword_C14BD0, 0 jnz loc_ADD54 lea rdi, LOCK_uuid_generator call _pthread_mutex_lock loc_ADC7B: call my_interval_timer shr rax, 2 mov r15, 28F5C28F5C28F5C3h mul r15 mov r14, rdx shr r14, 2 add r14, cs:interval_timer_offset mov eax, cs:nanoseq add r14, rax mov rcx, cs:uuid_time cmp r14, rcx jbe loc_ADD5E test rax, rax jz short loc_ADCD5 not rcx add rcx, r14 cmp rcx, rax cmovnb rcx, rax sub r14, rcx sub eax, ecx loc_ADCCF: mov cs:nanoseq, eax loc_ADCD5: mov cs:uuid_time, r14 mov rdi, cs:qword_C14BD0 test rdi, rdi jnz loc_ADD8F loc_ADCEC: lea rdi, LOCK_uuid_generator call _pthread_mutex_unlock mov rax, r14 shr rax, 20h mov rcx, r14 shr rcx, 30h mov edx, r14d rol dx, 8 mov [rbx+2], dx mov edx, r14d shr edx, 10h mov [rbx+1], dl mov edx, r14d shr edx, 18h mov [rbx], dl mov [rbx+5], al mov rax, r14 shr rax, 28h mov [rbx+4], al mov [rbx+7], cl shr r14, 38h or r14b, 10h mov [rbx+6], r14b mov rax, cs:uuid_suffix mov [rbx+8], rax add rsp, 8 pop rbx pop r14 pop r15 pop rbp retn loc_ADD54: call my_uuid_cold_1 jmp loc_ADC7B loc_ADD5E: jz short loc_ADDA4 loc_ADD60: cmp r14, rcx ja loc_ADCD5 call set_clock_seq call my_interval_timer shr rax, 2 mul r15 mov r14, rdx shr r14, 2 add r14, cs:interval_timer_offset xor eax, eax jmp loc_ADCCF loc_ADD8F: lea rax, PSI_server mov rax, [rax] call qword ptr [rax+160h] jmp loc_ADCEC loc_ADDA4: xor edx, edx inc eax mov cs:nanoseq, eax setnz dl add r14, rdx jmp short loc_ADD60
long long my_uuid(_WORD *a1) { _WORD *v1; // rbx unsigned long long v2; // r14 int v3; // eax unsigned long long v4; // r14 unsigned long long v5; // rcx int v6; // eax long long result; // rax v1 = a1; if ( qword_C14BD0 ) { my_uuid_cold_1(a1); } else { a1 = &LOCK_uuid_generator; pthread_mutex_lock(&LOCK_uuid_generator); } v2 = interval_timer_offset + my_interval_timer() / 0x64uLL; v3 = nanoseq; v4 = (unsigned int)nanoseq + v2; if ( v4 > uuid_time ) { if ( !nanoseq ) goto LABEL_9; v5 = v4 + ~uuid_time; if ( v5 >= (unsigned int)nanoseq ) v5 = (unsigned int)nanoseq; v4 -= v5; v6 = nanoseq - v5; goto LABEL_8; } if ( v4 == uuid_time ) { ++nanoseq; v4 += v3 != -1; } if ( v4 <= uuid_time ) { set_clock_seq(a1); v4 = interval_timer_offset + my_interval_timer() / 0x64uLL; v6 = 0; LABEL_8: nanoseq = v6; } LABEL_9: uuid_time = v4; if ( qword_C14BD0 ) ((void ( *)(long long))PSI_server[44])(qword_C14BD0); pthread_mutex_unlock(&LOCK_uuid_generator); v1[1] = __ROL2__(v4, 8); *((_BYTE *)v1 + 1) = BYTE2(v4); *(_BYTE *)v1 = BYTE3(v4); *((_BYTE *)v1 + 5) = BYTE4(v4); *((_BYTE *)v1 + 4) = BYTE5(v4); *((_BYTE *)v1 + 7) = BYTE6(v4); *((_BYTE *)v1 + 6) = HIBYTE(v4) | 0x10; result = uuid_suffix; *((_QWORD *)v1 + 1) = uuid_suffix; return result; }
my_uuid: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH RBX PUSH RAX MOV RBX,RDI CMP qword ptr [0x00d14bd0],0x0 JNZ 0x001add54 LEA RDI,[0xd14b90] CALL 0x0012a1f0 LAB_001adc7b: CALL 0x001a5744 SHR RAX,0x2 MOV R15,0x28f5c28f5c28f5c3 MUL R15 MOV R14,RDX SHR R14,0x2 ADD R14,qword ptr [0x00d14b60] MOV EAX,dword ptr [0x00d14b68] ADD R14,RAX MOV RCX,qword ptr [0x00d14bd8] CMP R14,RCX JBE 0x001add5e TEST RAX,RAX JZ 0x001adcd5 NOT RCX ADD RCX,R14 CMP RCX,RAX CMOVNC RCX,RAX SUB R14,RCX SUB EAX,ECX LAB_001adccf: MOV dword ptr [0x00d14b68],EAX LAB_001adcd5: MOV qword ptr [0x00d14bd8],R14 MOV RDI,qword ptr [0x00d14bd0] TEST RDI,RDI JNZ 0x001add8f LAB_001adcec: LEA RDI,[0xd14b90] CALL 0x0012a1c0 MOV RAX,R14 SHR RAX,0x20 MOV RCX,R14 SHR RCX,0x30 MOV EDX,R14D ROL DX,0x8 MOV word ptr [RBX + 0x2],DX MOV EDX,R14D SHR EDX,0x10 MOV byte ptr [RBX + 0x1],DL MOV EDX,R14D SHR EDX,0x18 MOV byte ptr [RBX],DL MOV byte ptr [RBX + 0x5],AL MOV RAX,R14 SHR RAX,0x28 MOV byte ptr [RBX + 0x4],AL MOV byte ptr [RBX + 0x7],CL SHR R14,0x38 OR R14B,0x10 MOV byte ptr [RBX + 0x6],R14B MOV RAX,qword ptr [0x00d14b50] MOV qword ptr [RBX + 0x8],RAX ADD RSP,0x8 POP RBX POP R14 POP R15 POP RBP RET LAB_001add54: CALL 0x00131049 JMP 0x001adc7b LAB_001add5e: JZ 0x001adda4 LAB_001add60: CMP R14,RCX JA 0x001adcd5 CALL 0x001ade80 CALL 0x001a5744 SHR RAX,0x2 MUL R15 MOV R14,RDX SHR R14,0x2 ADD R14,qword ptr [0x00d14b60] XOR EAX,EAX JMP 0x001adccf LAB_001add8f: LEA RAX,[0x490ed8] MOV RAX,qword ptr [RAX] CALL qword ptr [RAX + 0x160] JMP 0x001adcec LAB_001adda4: XOR EDX,EDX INC EAX MOV dword ptr [0x00d14b68],EAX SETNZ DL ADD R14,RDX JMP 0x001add60
void my_uuid(int1 *param_1) { ulong uVar1; ulong uVar2; ulong uVar3; if (LOCK_uuid_generator._64_8_ == 0) { pthread_mutex_lock((pthread_mutex_t *)LOCK_uuid_generator); } else { my_uuid_cold_1(); } uVar1 = my_interval_timer(); uVar2 = (ulong)nanoseq; uVar1 = uVar1 / 100 + interval_timer_offset + uVar2; if (uuid_time < uVar1) { if (uVar2 != 0) { uVar3 = ~uuid_time + uVar1; if (uVar2 <= ~uuid_time + uVar1) { uVar3 = uVar2; } uVar1 = uVar1 - uVar3; nanoseq = nanoseq - (int)uVar3; } } else { if (uVar1 == uuid_time) { nanoseq = nanoseq + 1; uVar1 = uVar1 + (nanoseq != 0); } if (uVar1 <= uuid_time) { set_clock_seq(); uVar1 = my_interval_timer(); uVar1 = uVar1 / 100 + interval_timer_offset; nanoseq = 0; } } uuid_time = uVar1; if (LOCK_uuid_generator._64_8_ != 0) { (**(code **)(PSI_server + 0x160))(); } pthread_mutex_unlock((pthread_mutex_t *)LOCK_uuid_generator); *(ushort *)(param_1 + 2) = (ushort)uVar1 << 8 | (ushort)uVar1 >> 8; param_1[1] = (char)(uVar1 >> 0x10); *param_1 = (char)(uVar1 >> 0x18); param_1[5] = (char)(uVar1 >> 0x20); param_1[4] = (char)(uVar1 >> 0x28); param_1[7] = (char)(uVar1 >> 0x30); param_1[6] = (byte)(uVar1 >> 0x38) | 0x10; *(int8 *)(param_1 + 8) = uuid_suffix; return; }
6,087
google::protobuf::util::converter::DefaultValueObjectWriter::DefaultValueObjectWriter(google::protobuf::util::TypeResolver*, google::protobuf::Type const&, google::protobuf::util::converter::ObjectWriter*)
aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/util/internal/default_value_objectwriter.cc
DefaultValueObjectWriter::DefaultValueObjectWriter( TypeResolver* type_resolver, const google::protobuf::Type& type, ObjectWriter* ow) : typeinfo_(TypeInfo::NewTypeInfo(type_resolver)), own_typeinfo_(true), type_(type), current_(nullptr), root_(nullptr), suppress_empty_list_(false), preserve_proto_field_names_(false), use_ints_for_enums_(false), ow_(ow) {}
O0
cpp
google::protobuf::util::converter::DefaultValueObjectWriter::DefaultValueObjectWriter(google::protobuf::util::TypeResolver*, google::protobuf::Type const&, google::protobuf::util::converter::ObjectWriter*): subq $0x58, %rsp movq %rdi, 0x50(%rsp) movq %rsi, 0x48(%rsp) movq %rdx, 0x40(%rsp) movq %rcx, 0x38(%rsp) movq 0x50(%rsp), %rdi movq %rdi, 0x10(%rsp) callq 0x441290 movq 0x10(%rsp), %rax leaq 0x1bebed(%rip), %rcx # 0x74bdd0 movq %rcx, (%rax) addq $0x10, %rax movq %rax, 0x18(%rsp) movq 0x48(%rsp), %rdi callq 0x5b9590 movq %rax, 0x20(%rsp) jmp 0x58d200 movq 0x10(%rsp), %rdi movq 0x18(%rsp), %rax movq 0x20(%rsp), %rcx movq %rcx, (%rax) movb $0x1, 0x18(%rdi) movq 0x40(%rsp), %rax movq %rax, 0x20(%rdi) addq $0x28, %rdi movq %rdi, (%rsp) callq 0x1a46c0 movq 0x10(%rsp), %rdi movq $0x0, 0x40(%rdi) addq $0x48, %rdi movq %rdi, 0x8(%rsp) xorl %eax, %eax movl %eax, %esi callq 0x591e00 movq 0x10(%rsp), %rdi addq $0x50, %rdi callq 0x591e40 jmp 0x58d25b movq 0x10(%rsp), %rdi movb $0x0, 0xa0(%rdi) movb $0x0, 0xa1(%rdi) movb $0x0, 0xa2(%rdi) addq $0xa8, %rdi callq 0x591e70 movq 0x10(%rsp), %rax movq 0x38(%rsp), %rcx movq %rcx, 0xc8(%rax) addq $0x58, %rsp retq movq %rax, %rcx movl %edx, %eax movq %rcx, 0x30(%rsp) movl %eax, 0x2c(%rsp) jmp 0x58d2c8 movq 0x8(%rsp), %rdi movq %rax, %rcx movl %edx, %eax movq %rcx, 0x30(%rsp) movl %eax, 0x2c(%rsp) callq 0x591eb0 movq (%rsp), %rdi callq 0x18d5f0 movq 0x10(%rsp), %rdi callq 0x4412e0 movq 0x30(%rsp), %rdi callq 0x198ce0 nopl (%rax)
_ZN6google8protobuf4util9converter24DefaultValueObjectWriterC2EPNS1_12TypeResolverERKNS0_4TypeEPNS2_12ObjectWriterE: sub rsp, 58h mov [rsp+58h+var_8], rdi mov [rsp+58h+var_10], rsi mov [rsp+58h+var_18], rdx mov [rsp+58h+var_20], rcx mov rdi, [rsp+58h+var_8]; this mov [rsp+58h+var_48], rdi call _ZN6google8protobuf4util9converter12ObjectWriterC2Ev; google::protobuf::util::converter::ObjectWriter::ObjectWriter(void) mov rax, [rsp+58h+var_48] lea rcx, off_74BDD0 mov [rax], rcx add rax, 10h mov [rsp+58h+var_40], rax mov rdi, [rsp+58h+var_10]; this call _ZN6google8protobuf4util9converter8TypeInfo11NewTypeInfoEPNS1_12TypeResolverE; google::protobuf::util::converter::TypeInfo::NewTypeInfo(google::protobuf::util::TypeResolver *) mov [rsp+58h+var_38], rax jmp short $+2 loc_58D200: mov rdi, [rsp+58h+var_48] mov rax, [rsp+58h+var_40] mov rcx, [rsp+58h+var_38] mov [rax], rcx mov byte ptr [rdi+18h], 1 mov rax, [rsp+58h+var_18] mov [rdi+20h], rax add rdi, 28h ; '(' mov [rsp+58h+var_58], rdi call __ZNSt6vectorISt10unique_ptrINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt14default_deleteIS6_EESaIS9_EEC2Ev; std::vector<std::unique_ptr<std::string>>::vector(void) mov rdi, [rsp+58h+var_48] mov qword ptr [rdi+40h], 0 add rdi, 48h ; 'H' mov [rsp+58h+var_50], rdi xor eax, eax mov esi, eax call _ZNSt10unique_ptrIN6google8protobuf4util9converter24DefaultValueObjectWriter4NodeESt14default_deleteIS5_EEC2IS7_vEEDn; std::unique_ptr<google::protobuf::util::converter::DefaultValueObjectWriter::Node>::unique_ptr<std::default_delete<google::protobuf::util::converter::DefaultValueObjectWriter::Node>,void>(decltype(nullptr)) mov rdi, [rsp+58h+var_48] add rdi, 50h ; 'P' call _ZNSt5stackIPN6google8protobuf4util9converter24DefaultValueObjectWriter4NodeESt5dequeIS6_SaIS6_EEEC2IS9_vEEv; std::stack<google::protobuf::util::converter::DefaultValueObjectWriter::Node *>::stack<std::deque<google::protobuf::util::converter::DefaultValueObjectWriter::Node *>,void>(void) jmp short $+2 loc_58D25B: mov rdi, [rsp+58h+var_48] mov byte ptr [rdi+0A0h], 0 mov byte ptr [rdi+0A1h], 0 mov byte ptr [rdi+0A2h], 0 add rdi, 0A8h call _ZNSt8functionIFbRKSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS6_EEPKN6google8protobuf5FieldEEEC2Ev; std::function<bool ()(std::vector<std::string> const&,google::protobuf::Field const*)>::function(void) mov rax, [rsp+58h+var_48] mov rcx, [rsp+58h+var_20] mov [rax+0C8h], rcx add rsp, 58h retn mov rcx, rax mov eax, edx mov [rsp+arg_28], rcx mov [rsp+arg_24], eax jmp short loc_58D2C8 mov rdi, [rsp+arg_0] mov rcx, rax mov eax, edx mov [rsp+arg_28], rcx mov [rsp+arg_24], eax call _ZNSt10unique_ptrIN6google8protobuf4util9converter24DefaultValueObjectWriter4NodeESt14default_deleteIS5_EED2Ev; std::unique_ptr<google::protobuf::util::converter::DefaultValueObjectWriter::Node>::~unique_ptr() mov rdi, [rsp+0] call __ZNSt6vectorISt10unique_ptrINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt14default_deleteIS6_EESaIS9_EED2Ev; std::vector<std::unique_ptr<std::string>>::~vector() loc_58D2C8: mov rdi, [rsp+arg_8]; this call _ZN6google8protobuf4util9converter12ObjectWriterD2Ev; google::protobuf::util::converter::ObjectWriter::~ObjectWriter() mov rdi, [rsp+arg_28] call __Unwind_Resume
google::protobuf::util::converter::DefaultValueObjectWriter * google::protobuf::util::converter::DefaultValueObjectWriter::DefaultValueObjectWriter( google::protobuf::util::converter::DefaultValueObjectWriter *this, google::protobuf::util::TypeResolver *a2, const google::protobuf::Type *a3, google::protobuf::util::converter::ObjectWriter *a4) { google::protobuf::util::converter::DefaultValueObjectWriter *result; // rax google::protobuf::util::converter::ObjectWriter::ObjectWriter(this); *(_QWORD *)this = off_74BDD0; *((_QWORD *)this + 2) = google::protobuf::util::converter::TypeInfo::NewTypeInfo(a2, a2); *((_BYTE *)this + 24) = 1; *((_QWORD *)this + 4) = a3; std::vector<std::unique_ptr<std::string>>::vector((char *)this + 40); *((_QWORD *)this + 8) = 0LL; std::unique_ptr<google::protobuf::util::converter::DefaultValueObjectWriter::Node>::unique_ptr<std::default_delete<google::protobuf::util::converter::DefaultValueObjectWriter::Node>,void>( (char *)this + 72, 0LL); std::stack<google::protobuf::util::converter::DefaultValueObjectWriter::Node *>::stack<std::deque<google::protobuf::util::converter::DefaultValueObjectWriter::Node *>,void>((char *)this + 80); *((_BYTE *)this + 160) = 0; *((_BYTE *)this + 161) = 0; *((_BYTE *)this + 162) = 0; std::function<bool ()(std::vector<std::string> const&,google::protobuf::Field const*)>::function((char *)this + 168); result = this; *((_QWORD *)this + 25) = a4; return result; }
_M_get_node: PUSH RAX MOV qword ptr [RSP],RDI MOV RDI,qword ptr [RSP] CALL 0x0058ae60 MOV RDI,RAX MOV ESI,0x1 CALL 0x0058d220 POP RCX RET
/* std::_Rb_tree<int, std::pair<int const, google::protobuf::internal::ExtensionSet::Extension>, std::_Select1st<std::pair<int const, google::protobuf::internal::ExtensionSet::Extension> >, std::less<int>, std::allocator<std::pair<int const, google::protobuf::internal::ExtensionSet::Extension> > >::_M_get_node() */ void __thiscall std:: _Rb_tree<int,std::pair<int_const,google::protobuf::internal::ExtensionSet::Extension>,std::_Select1st<std::pair<int_const,google::protobuf::internal::ExtensionSet::Extension>>,std::less<int>,std::allocator<std::pair<int_const,google::protobuf::internal::ExtensionSet::Extension>>> ::_M_get_node(_Rb_tree<int,std::pair<int_const,google::protobuf::internal::ExtensionSet::Extension>,std::_Select1st<std::pair<int_const,google::protobuf::internal::ExtensionSet::Extension>>,std::less<int>,std::allocator<std::pair<int_const,google::protobuf::internal::ExtensionSet::Extension>>> *this) { allocator *paVar1; paVar1 = (allocator *)_M_get_Node_allocator(this); allocator_traits<std::allocator<std::_Rb_tree_node<std::pair<int_const,google::protobuf::internal::ExtensionSet::Extension>>>> ::allocate(paVar1,1); return; }
6,088
js_async_generator_resolve_or_reject
bluesky950520[P]quickjs/quickjs.c
static void js_async_generator_resolve_or_reject(JSContext *ctx, JSAsyncGeneratorData *s, JSValue result, int is_reject) { JSAsyncGeneratorRequest *next; JSValue ret; next = list_entry(s->queue.next, JSAsyncGeneratorRequest, link); list_del(&next->link); ret = JS_Call(ctx, next->resolving_funcs[is_reject], JS_UNDEFINED, 1, &result); JS_FreeValue(ctx, ret); JS_FreeValue(ctx, next->result); JS_FreeValue(ctx, next->promise); JS_FreeValue(ctx, next->resolving_funcs[0]); JS_FreeValue(ctx, next->resolving_funcs[1]); js_free(ctx, next); }
O3
c
js_async_generator_resolve_or_reject: pushq %r14 pushq %rbx subq $0x48, %rsp movq %rsi, %rbx movq %rdi, %r14 leaq 0x38(%rsp), %rax movq %rdx, (%rax) movq %rcx, 0x8(%rax) movq (%rsi), %rcx movq 0x8(%rsi), %rdx movq %rdx, 0x8(%rcx) movq %rcx, (%rdx) xorps %xmm0, %xmm0 movups %xmm0, (%rsi) movl %r8d, %ecx shlq $0x4, %rcx movq 0x38(%rsi,%rcx), %rsi movq 0x40(%rbx,%rcx), %rdx movl $0x0, 0x28(%rsp) movq $0x3, 0x30(%rsp) movups 0x28(%rsp), %xmm0 movups %xmm0, (%rsp) movq %rax, 0x10(%rsp) movl $0x2, 0x18(%rsp) movl $0x3, %r8d xorl %ecx, %ecx movl $0x1, %r9d callq 0x27eca movq 0x18(%r14), %rdi cmpl $-0x9, %edx jb 0x581ce movl (%rax), %ecx leal -0x1(%rcx), %esi movl %esi, (%rax) cmpl $0x1, %ecx jg 0x581ce movq %rax, %rsi callq 0x20d90 movq 0x18(%r14), %rdi movq 0x20(%rbx), %rdx cmpl $-0x9, %edx jb 0x581f0 movq 0x18(%rbx), %rsi movl (%rsi), %eax leal -0x1(%rax), %ecx movl %ecx, (%rsi) cmpl $0x1, %eax jg 0x581f0 callq 0x20d90 movq 0x18(%r14), %rdi movq 0x30(%rbx), %rdx cmpl $-0x9, %edx jb 0x58212 movq 0x28(%rbx), %rsi movl (%rsi), %eax leal -0x1(%rax), %ecx movl %ecx, (%rsi) cmpl $0x1, %eax jg 0x58212 callq 0x20d90 movq 0x18(%r14), %rdi movq 0x40(%rbx), %rdx cmpl $-0x9, %edx jb 0x58234 movq 0x38(%rbx), %rsi movl (%rsi), %eax leal -0x1(%rax), %ecx movl %ecx, (%rsi) cmpl $0x1, %eax jg 0x58234 callq 0x20d90 movq 0x18(%r14), %rdi movq 0x50(%rbx), %rdx cmpl $-0x9, %edx jb 0x58252 movq 0x48(%rbx), %rsi movl (%rsi), %eax leal -0x1(%rax), %ecx movl %ecx, (%rsi) cmpl $0x1, %eax jg 0x58252 callq 0x20d90 movq %r14, %rdi movq %rbx, %rsi callq 0x1c845 addq $0x48, %rsp popq %rbx popq %r14 retq
js_async_generator_resolve_or_reject: push r14 push rbx sub rsp, 48h mov rbx, rsi mov r14, rdi lea rax, [rsp+58h+var_20] mov [rax], rdx mov [rax+8], rcx mov rcx, [rsi] mov rdx, [rsi+8] mov [rcx+8], rdx mov [rdx], rcx xorps xmm0, xmm0 movups xmmword ptr [rsi], xmm0 mov ecx, r8d shl rcx, 4 mov rsi, [rsi+rcx+38h] mov rdx, [rbx+rcx+40h] mov dword ptr [rsp+58h+var_30], 0 mov qword ptr [rsp+58h+var_30+8], 3 movups xmm0, [rsp+58h+var_30] movups [rsp+58h+var_58], xmm0 mov [rsp+58h+var_48], rax mov [rsp+58h+var_40], 2 mov r8d, 3 xor ecx, ecx mov r9d, 1 call JS_CallInternal mov rdi, [r14+18h] cmp edx, 0FFFFFFF7h jb short loc_581CE mov ecx, [rax] lea esi, [rcx-1] mov [rax], esi cmp ecx, 1 jg short loc_581CE mov rsi, rax call js_free_value_rt mov rdi, [r14+18h] loc_581CE: mov rdx, [rbx+20h] cmp edx, 0FFFFFFF7h jb short loc_581F0 mov rsi, [rbx+18h] mov eax, [rsi] lea ecx, [rax-1] mov [rsi], ecx cmp eax, 1 jg short loc_581F0 call js_free_value_rt mov rdi, [r14+18h] loc_581F0: mov rdx, [rbx+30h] cmp edx, 0FFFFFFF7h jb short loc_58212 mov rsi, [rbx+28h] mov eax, [rsi] lea ecx, [rax-1] mov [rsi], ecx cmp eax, 1 jg short loc_58212 call js_free_value_rt mov rdi, [r14+18h] loc_58212: mov rdx, [rbx+40h] cmp edx, 0FFFFFFF7h jb short loc_58234 mov rsi, [rbx+38h] mov eax, [rsi] lea ecx, [rax-1] mov [rsi], ecx cmp eax, 1 jg short loc_58234 call js_free_value_rt mov rdi, [r14+18h] loc_58234: mov rdx, [rbx+50h] cmp edx, 0FFFFFFF7h jb short loc_58252 mov rsi, [rbx+48h] mov eax, [rsi] lea ecx, [rax-1] mov [rsi], ecx cmp eax, 1 jg short loc_58252 call js_free_value_rt loc_58252: mov rdi, r14 mov rsi, rbx call js_free add rsp, 48h pop rbx pop r14 retn
long long js_async_generator_resolve_or_reject( long long a1, long long *a2, long long a3, long long a4, unsigned int a5, double a6, __m128 a7, __m128 a8, __m128 a9, __m128 a10, __m128 a11, __m128 a12, __m128 a13) { long long v15; // rcx _QWORD *v16; // rdx _QWORD *v17; // rax long long v18; // rdx long long v19; // r8 long long v20; // r9 long long v21; // rdi long long v22; // rcx long long v23; // rdx _QWORD *v24; // rsi int v25; // eax long long v26; // rcx long long v27; // rdx _QWORD *v28; // rsi int v29; // eax long long v30; // rcx long long v31; // rdx _QWORD *v32; // rsi int v33; // eax long long v34; // rcx long long v35; // rdx _QWORD *v36; // rsi int v37; // eax long long v38; // rcx __m128i v40; // [rsp+28h] [rbp-30h] _QWORD v41[4]; // [rsp+38h] [rbp-20h] BYREF v41[0] = a3; v41[1] = a4; v15 = *a2; v16 = (_QWORD *)a2[1]; *(_QWORD *)(v15 + 8) = v16; *v16 = v15; *(_OWORD *)a2 = 0LL; v40.m128i_i32[0] = 0; v40.m128i_i64[1] = 3LL; v17 = (_QWORD *)JS_CallInternal( a1, a2[2 * a5 + 7], a2[2 * a5 + 8], 0LL, 3LL, 1LL, v40, a7, a8, a9, a10, a11, a12, a13, v40.m128i_i8[0], 3, (long long)v41, 2u); v21 = *(_QWORD *)(a1 + 24); if ( (unsigned int)v18 >= 0xFFFFFFF7 ) { v22 = *(unsigned int *)v17; *(_DWORD *)v17 = v22 - 1; if ( (int)v22 <= 1 ) { js_free_value_rt(v21, v17, v18, v22, v19, v20); v21 = *(_QWORD *)(a1 + 24); } } v23 = a2[4]; if ( (unsigned int)v23 >= 0xFFFFFFF7 ) { v24 = (_QWORD *)a2[3]; v25 = *(_DWORD *)v24; v26 = (unsigned int)(*(_DWORD *)v24 - 1); *(_DWORD *)v24 = v26; if ( v25 <= 1 ) { js_free_value_rt(v21, v24, v23, v26, v19, v20); v21 = *(_QWORD *)(a1 + 24); } } v27 = a2[6]; if ( (unsigned int)v27 >= 0xFFFFFFF7 ) { v28 = (_QWORD *)a2[5]; v29 = *(_DWORD *)v28; v30 = (unsigned int)(*(_DWORD *)v28 - 1); *(_DWORD *)v28 = v30; if ( v29 <= 1 ) { js_free_value_rt(v21, v28, v27, v30, v19, v20); v21 = *(_QWORD *)(a1 + 24); } } v31 = a2[8]; if ( (unsigned int)v31 >= 0xFFFFFFF7 ) { v32 = (_QWORD *)a2[7]; v33 = *(_DWORD *)v32; v34 = (unsigned int)(*(_DWORD *)v32 - 1); *(_DWORD *)v32 = v34; if ( v33 <= 1 ) { js_free_value_rt(v21, v32, v31, v34, v19, v20); v21 = *(_QWORD *)(a1 + 24); } } v35 = a2[10]; if ( (unsigned int)v35 >= 0xFFFFFFF7 ) { v36 = (_QWORD *)a2[9]; v37 = *(_DWORD *)v36; v38 = (unsigned int)(*(_DWORD *)v36 - 1); *(_DWORD *)v36 = v38; if ( v37 <= 1 ) js_free_value_rt(v21, v36, v35, v38, v19, v20); } return js_free(a1, (long long)a2); }
js_async_generator_resolve_or_reject: PUSH R14 PUSH RBX SUB RSP,0x48 MOV RBX,RSI MOV R14,RDI LEA RAX,[RSP + 0x38] MOV qword ptr [RAX],RDX MOV qword ptr [RAX + 0x8],RCX MOV RCX,qword ptr [RSI] MOV RDX,qword ptr [RSI + 0x8] MOV qword ptr [RCX + 0x8],RDX MOV qword ptr [RDX],RCX XORPS XMM0,XMM0 MOVUPS xmmword ptr [RSI],XMM0 MOV ECX,R8D SHL RCX,0x4 MOV RSI,qword ptr [RSI + RCX*0x1 + 0x38] MOV RDX,qword ptr [RBX + RCX*0x1 + 0x40] MOV dword ptr [RSP + 0x28],0x0 MOV qword ptr [RSP + 0x30],0x3 MOVUPS XMM0,xmmword ptr [RSP + 0x28] MOVUPS xmmword ptr [RSP],XMM0 MOV qword ptr [RSP + 0x10],RAX MOV dword ptr [RSP + 0x18],0x2 MOV R8D,0x3 XOR ECX,ECX MOV R9D,0x1 CALL 0x00127eca MOV RDI,qword ptr [R14 + 0x18] CMP EDX,-0x9 JC 0x001581ce MOV ECX,dword ptr [RAX] LEA ESI,[RCX + -0x1] MOV dword ptr [RAX],ESI CMP ECX,0x1 JG 0x001581ce MOV RSI,RAX CALL 0x00120d90 MOV RDI,qword ptr [R14 + 0x18] LAB_001581ce: MOV RDX,qword ptr [RBX + 0x20] CMP EDX,-0x9 JC 0x001581f0 MOV RSI,qword ptr [RBX + 0x18] MOV EAX,dword ptr [RSI] LEA ECX,[RAX + -0x1] MOV dword ptr [RSI],ECX CMP EAX,0x1 JG 0x001581f0 CALL 0x00120d90 MOV RDI,qword ptr [R14 + 0x18] LAB_001581f0: MOV RDX,qword ptr [RBX + 0x30] CMP EDX,-0x9 JC 0x00158212 MOV RSI,qword ptr [RBX + 0x28] MOV EAX,dword ptr [RSI] LEA ECX,[RAX + -0x1] MOV dword ptr [RSI],ECX CMP EAX,0x1 JG 0x00158212 CALL 0x00120d90 MOV RDI,qword ptr [R14 + 0x18] LAB_00158212: MOV RDX,qword ptr [RBX + 0x40] CMP EDX,-0x9 JC 0x00158234 MOV RSI,qword ptr [RBX + 0x38] MOV EAX,dword ptr [RSI] LEA ECX,[RAX + -0x1] MOV dword ptr [RSI],ECX CMP EAX,0x1 JG 0x00158234 CALL 0x00120d90 MOV RDI,qword ptr [R14 + 0x18] LAB_00158234: MOV RDX,qword ptr [RBX + 0x50] CMP EDX,-0x9 JC 0x00158252 MOV RSI,qword ptr [RBX + 0x48] MOV EAX,dword ptr [RSI] LEA ECX,[RAX + -0x1] MOV dword ptr [RSI],ECX CMP EAX,0x1 JG 0x00158252 CALL 0x00120d90 LAB_00158252: MOV RDI,R14 MOV RSI,RBX CALL 0x0011c845 ADD RSP,0x48 POP RBX POP R14 RET
void js_async_generator_resolve_or_reject (long param_1,long *param_2,int8 param_3,int8 param_4,ulong param_5) { int iVar1; long lVar2; long *plVar3; int *piVar4; int8 uVar5; int1 auVar6 [12]; int8 local_20; int8 local_18; lVar2 = *param_2; plVar3 = (long *)param_2[1]; *(long **)(lVar2 + 8) = plVar3; *plVar3 = lVar2; *param_2 = 0; param_2[1] = 0; local_20 = param_3; local_18 = param_4; auVar6 = JS_CallInternal(param_1,param_2[(param_5 & 0xffffffff) * 2 + 7], param_2[(param_5 & 0xffffffff) * 2 + 8],0,3,1,0,3,&local_20,2); piVar4 = auVar6._0_8_; uVar5 = *(int8 *)(param_1 + 0x18); if (0xfffffff6 < auVar6._8_4_) { iVar1 = *piVar4; *piVar4 = iVar1 + -1; if (iVar1 < 2) { js_free_value_rt(uVar5,piVar4); uVar5 = *(int8 *)(param_1 + 0x18); } } if (0xfffffff6 < (uint)param_2[4]) { iVar1 = *(int *)param_2[3]; *(int *)param_2[3] = iVar1 + -1; if (iVar1 < 2) { js_free_value_rt(uVar5); uVar5 = *(int8 *)(param_1 + 0x18); } } if (0xfffffff6 < (uint)param_2[6]) { iVar1 = *(int *)param_2[5]; *(int *)param_2[5] = iVar1 + -1; if (iVar1 < 2) { js_free_value_rt(uVar5); uVar5 = *(int8 *)(param_1 + 0x18); } } if (0xfffffff6 < (uint)param_2[8]) { iVar1 = *(int *)param_2[7]; *(int *)param_2[7] = iVar1 + -1; if (iVar1 < 2) { js_free_value_rt(uVar5); uVar5 = *(int8 *)(param_1 + 0x18); } } if (0xfffffff6 < (uint)param_2[10]) { iVar1 = *(int *)param_2[9]; *(int *)param_2[9] = iVar1 + -1; if (iVar1 < 2) { js_free_value_rt(uVar5); } } js_free(param_1,param_2); return; }
6,089
get_defaults_options
eloqsql/mysys/my_default.c
int get_defaults_options(char **argv) { static char file_buffer[FN_REFLEN]; static char extra_file_buffer[FN_REFLEN]; char **orig_argv= argv; argv++; /* Skip program name */ my_defaults_file= my_defaults_group_suffix= my_defaults_extra_file= 0; my_no_defaults= my_print_defaults= FALSE; if (*argv && !strcmp(*argv, "--no-defaults")) { my_no_defaults= 1; argv++; } else for(; *argv; argv++) { if (!my_defaults_file && is_prefix(*argv, "--defaults-file=")) my_defaults_file= *argv + sizeof("--defaults-file=")-1; else if (!my_defaults_extra_file && is_prefix(*argv, "--defaults-extra-file=")) my_defaults_extra_file= *argv + sizeof("--defaults-extra-file=")-1; else if (!my_defaults_group_suffix && is_prefix(*argv, "--defaults-group-suffix=")) my_defaults_group_suffix= *argv + sizeof("--defaults-group-suffix=")-1; else break; } if (*argv && !strcmp(*argv, "--print-defaults")) { my_print_defaults= 1; my_defaults_mark_files= FALSE; argv++; } if (! my_defaults_group_suffix) my_defaults_group_suffix= getenv("MYSQL_GROUP_SUFFIX"); if (my_defaults_extra_file && my_defaults_extra_file != extra_file_buffer) { my_realpath(extra_file_buffer, my_defaults_extra_file, MYF(0)); my_defaults_extra_file= extra_file_buffer; } if (my_defaults_file && my_defaults_file != file_buffer) { my_realpath(file_buffer, my_defaults_file, MYF(0)); my_defaults_file= file_buffer; } return (int)(argv - orig_argv); }
O0
c
get_defaults_options: pushq %rbp movq %rsp, %rbp subq $0x10, %rsp movq %rdi, -0x8(%rbp) movq -0x8(%rbp), %rax movq %rax, -0x10(%rbp) movq -0x8(%rbp), %rax addq $0x8, %rax movq %rax, -0x8(%rbp) leaq 0x3be6c1(%rip), %rax # 0x441608 movq $0x0, (%rax) leaq 0x3be6ab(%rip), %rax # 0x441600 movq $0x0, (%rax) leaq 0x3be695(%rip), %rax # 0x4415f8 movq $0x0, (%rax) leaq 0x3be681(%rip), %rax # 0x4415f2 movb $0x0, (%rax) leaq 0x3be676(%rip), %rax # 0x4415f1 movb $0x0, (%rax) movq -0x8(%rbp), %rax cmpq $0x0, (%rax) je 0x82fbb movq -0x8(%rbp), %rax movq (%rax), %rdi leaq 0x7b590(%rip), %rsi # 0xfe526 callq 0x2a570 cmpl $0x0, %eax jne 0x82fbb leaq 0x3be64a(%rip), %rax # 0x4415f1 movb $0x1, (%rax) movq -0x8(%rbp), %rax addq $0x8, %rax movq %rax, -0x8(%rbp) jmp 0x830a9 jmp 0x82fbd movq -0x8(%rbp), %rax cmpq $0x0, (%rax) je 0x830a7 leaq 0x3be626(%rip), %rax # 0x4415f8 cmpq $0x0, (%rax) jne 0x8300e movq -0x8(%rbp), %rax movq (%rax), %rdi leaq 0x7b54e(%rip), %rsi # 0xfe534 callq 0xf2cd0 cmpl $0x0, %eax je 0x8300e movq -0x8(%rbp), %rax movq (%rax), %rcx addq $0x11, %rcx addq $-0x1, %rcx leaq 0x3be5f2(%rip), %rax # 0x4415f8 movq %rcx, (%rax) jmp 0x83094 leaq 0x3be5f3(%rip), %rax # 0x441608 cmpq $0x0, (%rax) jne 0x8304e movq -0x8(%rbp), %rax movq (%rax), %rdi leaq 0x7b51c(%rip), %rsi # 0xfe545 callq 0xf2cd0 cmpl $0x0, %eax je 0x8304e movq -0x8(%rbp), %rax movq (%rax), %rcx addq $0x17, %rcx addq $-0x1, %rcx leaq 0x3be5bf(%rip), %rax # 0x441608 movq %rcx, (%rax) jmp 0x83092 leaq 0x3be5ab(%rip), %rax # 0x441600 cmpq $0x0, (%rax) jne 0x8308e movq -0x8(%rbp), %rax movq (%rax), %rdi leaq 0x7b4f3(%rip), %rsi # 0xfe55c callq 0xf2cd0 cmpl $0x0, %eax je 0x8308e movq -0x8(%rbp), %rax movq (%rax), %rcx addq $0x19, %rcx addq $-0x1, %rcx leaq 0x3be577(%rip), %rax # 0x441600 movq %rcx, (%rax) jmp 0x83090 jmp 0x830a7 jmp 0x83092 jmp 0x83094 jmp 0x83096 movq -0x8(%rbp), %rax addq $0x8, %rax movq %rax, -0x8(%rbp) jmp 0x82fbd jmp 0x830a9 movq -0x8(%rbp), %rax cmpq $0x0, (%rax) je 0x830eb movq -0x8(%rbp), %rax movq (%rax), %rdi leaq 0x7b4b4(%rip), %rsi # 0xfe575 callq 0x2a570 cmpl $0x0, %eax jne 0x830eb leaq 0x3be520(%rip), %rax # 0x4415f2 movb $0x1, (%rax) leaq 0x3be514(%rip), %rax # 0x4415f0 movb $0x0, (%rax) movq -0x8(%rbp), %rax addq $0x8, %rax movq %rax, -0x8(%rbp) leaq 0x3be50e(%rip), %rax # 0x441600 cmpq $0x0, (%rax) jne 0x83111 leaq 0x7b487(%rip), %rdi # 0xfe586 callq 0x2a4f0 movq %rax, %rcx leaq 0x3be4f2(%rip), %rax # 0x441600 movq %rcx, (%rax) leaq 0x3be4f0(%rip), %rax # 0x441608 cmpq $0x0, (%rax) je 0x8315c leaq 0x3be6eb(%rip), %rcx # 0x441810 leaq 0x3be4dc(%rip), %rax # 0x441608 cmpq %rcx, (%rax) je 0x8315c leaq 0x3be4d0(%rip), %rax # 0x441608 movq (%rax), %rsi leaq 0x3be6ce(%rip), %rdi # 0x441810 xorl %eax, %eax movl %eax, %edx callq 0xa1e10 leaq 0x3be4b6(%rip), %rax # 0x441608 leaq 0x3be6b7(%rip), %rcx # 0x441810 movq %rcx, (%rax) leaq 0x3be495(%rip), %rax # 0x4415f8 cmpq $0x0, (%rax) je 0x831a7 leaq 0x3be4a0(%rip), %rcx # 0x441610 leaq 0x3be481(%rip), %rax # 0x4415f8 cmpq %rcx, (%rax) je 0x831a7 leaq 0x3be475(%rip), %rax # 0x4415f8 movq (%rax), %rsi leaq 0x3be483(%rip), %rdi # 0x441610 xorl %eax, %eax movl %eax, %edx callq 0xa1e10 leaq 0x3be45b(%rip), %rax # 0x4415f8 leaq 0x3be46c(%rip), %rcx # 0x441610 movq %rcx, (%rax) movq -0x8(%rbp), %rax movq -0x10(%rbp), %rcx subq %rcx, %rax sarq $0x3, %rax addq $0x10, %rsp popq %rbp retq nopl (%rax)
get_defaults_options: push rbp mov rbp, rsp sub rsp, 10h mov [rbp+var_8], rdi mov rax, [rbp+var_8] mov [rbp+var_10], rax mov rax, [rbp+var_8] add rax, 8 mov [rbp+var_8], rax lea rax, my_defaults_extra_file mov qword ptr [rax], 0 lea rax, my_defaults_group_suffix mov qword ptr [rax], 0 lea rax, my_defaults_file mov qword ptr [rax], 0 lea rax, my_print_defaults mov byte ptr [rax], 0 lea rax, my_no_defaults mov byte ptr [rax], 0 mov rax, [rbp+var_8] cmp qword ptr [rax], 0 jz short loc_82FBB mov rax, [rbp+var_8] mov rdi, [rax] lea rsi, aNoDefaults; "--no-defaults" call _strcmp cmp eax, 0 jnz short loc_82FBB lea rax, my_no_defaults mov byte ptr [rax], 1 mov rax, [rbp+var_8] add rax, 8 mov [rbp+var_8], rax jmp loc_830A9 loc_82FBB: jmp short $+2 loc_82FBD: mov rax, [rbp+var_8] cmp qword ptr [rax], 0 jz loc_830A7 lea rax, my_defaults_file cmp qword ptr [rax], 0 jnz short loc_8300E mov rax, [rbp+var_8] mov rdi, [rax] lea rsi, aDefaultsFile; "--defaults-file=" call is_prefix cmp eax, 0 jz short loc_8300E mov rax, [rbp+var_8] mov rcx, [rax] add rcx, 11h add rcx, 0FFFFFFFFFFFFFFFFh lea rax, my_defaults_file mov [rax], rcx jmp loc_83094 loc_8300E: lea rax, my_defaults_extra_file cmp qword ptr [rax], 0 jnz short loc_8304E mov rax, [rbp+var_8] mov rdi, [rax] lea rsi, aDefaultsExtraF; "--defaults-extra-file=" call is_prefix cmp eax, 0 jz short loc_8304E mov rax, [rbp+var_8] mov rcx, [rax] add rcx, 17h add rcx, 0FFFFFFFFFFFFFFFFh lea rax, my_defaults_extra_file mov [rax], rcx jmp short loc_83092 loc_8304E: lea rax, my_defaults_group_suffix cmp qword ptr [rax], 0 jnz short loc_8308E mov rax, [rbp+var_8] mov rdi, [rax] lea rsi, aDefaultsGroupS; "--defaults-group-suffix=" call is_prefix cmp eax, 0 jz short loc_8308E mov rax, [rbp+var_8] mov rcx, [rax] add rcx, 19h add rcx, 0FFFFFFFFFFFFFFFFh lea rax, my_defaults_group_suffix mov [rax], rcx jmp short loc_83090 loc_8308E: jmp short loc_830A7 loc_83090: jmp short $+2 loc_83092: jmp short $+2 loc_83094: jmp short $+2 loc_83096: mov rax, [rbp+var_8] add rax, 8 mov [rbp+var_8], rax jmp loc_82FBD loc_830A7: jmp short $+2 loc_830A9: mov rax, [rbp+var_8] cmp qword ptr [rax], 0 jz short loc_830EB mov rax, [rbp+var_8] mov rdi, [rax] lea rsi, aPrintDefaults; "--print-defaults" call _strcmp cmp eax, 0 jnz short loc_830EB lea rax, my_print_defaults mov byte ptr [rax], 1 lea rax, my_defaults_mark_files mov byte ptr [rax], 0 mov rax, [rbp+var_8] add rax, 8 mov [rbp+var_8], rax loc_830EB: lea rax, my_defaults_group_suffix cmp qword ptr [rax], 0 jnz short loc_83111 lea rdi, aMysqlGroupSuff; "MYSQL_GROUP_SUFFIX" call _getenv mov rcx, rax lea rax, my_defaults_group_suffix mov [rax], rcx loc_83111: lea rax, my_defaults_extra_file cmp qword ptr [rax], 0 jz short loc_8315C lea rcx, get_defaults_options_extra_file_buffer lea rax, my_defaults_extra_file cmp [rax], rcx jz short loc_8315C lea rax, my_defaults_extra_file mov rsi, [rax] lea rdi, get_defaults_options_extra_file_buffer xor eax, eax mov edx, eax call my_realpath lea rax, my_defaults_extra_file lea rcx, get_defaults_options_extra_file_buffer mov [rax], rcx loc_8315C: lea rax, my_defaults_file cmp qword ptr [rax], 0 jz short loc_831A7 lea rcx, get_defaults_options_file_buffer lea rax, my_defaults_file cmp [rax], rcx jz short loc_831A7 lea rax, my_defaults_file mov rsi, [rax] lea rdi, get_defaults_options_file_buffer xor eax, eax mov edx, eax call my_realpath lea rax, my_defaults_file lea rcx, get_defaults_options_file_buffer mov [rax], rcx loc_831A7: mov rax, [rbp+var_8] mov rcx, [rbp+var_10] sub rax, rcx sar rax, 3 add rsp, 10h pop rbp retn
long long get_defaults_options(long long a1) { _QWORD *v2; // [rsp+8h] [rbp-8h] v2 = (_QWORD *)(a1 + 8); my_defaults_extra_file = 0LL; my_defaults_group_suffix = 0LL; my_defaults_file = 0LL; my_print_defaults = 0; my_no_defaults = 0; if ( *(_QWORD *)(a1 + 8) && !(unsigned int)strcmp(*v2, "--no-defaults") ) { my_no_defaults = 1; v2 = (_QWORD *)(a1 + 16); } else { while ( *v2 ) { if ( my_defaults_file || !(unsigned int)is_prefix(*v2, "--defaults-file=") ) { if ( my_defaults_extra_file || !(unsigned int)is_prefix(*v2, "--defaults-extra-file=") ) { if ( my_defaults_group_suffix || !(unsigned int)is_prefix(*v2, "--defaults-group-suffix=") ) break; my_defaults_group_suffix = *v2 + 24LL; } else { my_defaults_extra_file = *v2 + 22LL; } } else { my_defaults_file = *v2 + 16LL; } ++v2; } } if ( *v2 && !(unsigned int)strcmp(*v2, "--print-defaults") ) { my_print_defaults = 1; my_defaults_mark_files = 0; ++v2; } if ( !my_defaults_group_suffix ) my_defaults_group_suffix = getenv("MYSQL_GROUP_SUFFIX"); if ( my_defaults_extra_file && (_UNKNOWN *)my_defaults_extra_file != &get_defaults_options_extra_file_buffer ) { my_realpath(&get_defaults_options_extra_file_buffer, my_defaults_extra_file, 0LL); my_defaults_extra_file = &get_defaults_options_extra_file_buffer; } if ( my_defaults_file && (_UNKNOWN *)my_defaults_file != &get_defaults_options_file_buffer ) { my_realpath(&get_defaults_options_file_buffer, my_defaults_file, 0LL); my_defaults_file = &get_defaults_options_file_buffer; } return ((long long)v2 - a1) >> 3; }
get_defaults_options: PUSH RBP MOV RBP,RSP SUB RSP,0x10 MOV qword ptr [RBP + -0x8],RDI MOV RAX,qword ptr [RBP + -0x8] MOV qword ptr [RBP + -0x10],RAX MOV RAX,qword ptr [RBP + -0x8] ADD RAX,0x8 MOV qword ptr [RBP + -0x8],RAX LEA RAX,[0x541608] MOV qword ptr [RAX],0x0 LEA RAX,[0x541600] MOV qword ptr [RAX],0x0 LEA RAX,[0x5415f8] MOV qword ptr [RAX],0x0 LEA RAX,[0x5415f2] MOV byte ptr [RAX],0x0 LEA RAX,[0x5415f1] MOV byte ptr [RAX],0x0 MOV RAX,qword ptr [RBP + -0x8] CMP qword ptr [RAX],0x0 JZ 0x00182fbb MOV RAX,qword ptr [RBP + -0x8] MOV RDI,qword ptr [RAX] LEA RSI,[0x1fe526] CALL 0x0012a570 CMP EAX,0x0 JNZ 0x00182fbb LEA RAX,[0x5415f1] MOV byte ptr [RAX],0x1 MOV RAX,qword ptr [RBP + -0x8] ADD RAX,0x8 MOV qword ptr [RBP + -0x8],RAX JMP 0x001830a9 LAB_00182fbb: JMP 0x00182fbd LAB_00182fbd: MOV RAX,qword ptr [RBP + -0x8] CMP qword ptr [RAX],0x0 JZ 0x001830a7 LEA RAX,[0x5415f8] CMP qword ptr [RAX],0x0 JNZ 0x0018300e MOV RAX,qword ptr [RBP + -0x8] MOV RDI,qword ptr [RAX] LEA RSI,[0x1fe534] CALL 0x001f2cd0 CMP EAX,0x0 JZ 0x0018300e MOV RAX,qword ptr [RBP + -0x8] MOV RCX,qword ptr [RAX] ADD RCX,0x11 ADD RCX,-0x1 LEA RAX,[0x5415f8] MOV qword ptr [RAX],RCX JMP 0x00183094 LAB_0018300e: LEA RAX,[0x541608] CMP qword ptr [RAX],0x0 JNZ 0x0018304e MOV RAX,qword ptr [RBP + -0x8] MOV RDI,qword ptr [RAX] LEA RSI,[0x1fe545] CALL 0x001f2cd0 CMP EAX,0x0 JZ 0x0018304e MOV RAX,qword ptr [RBP + -0x8] MOV RCX,qword ptr [RAX] ADD RCX,0x17 ADD RCX,-0x1 LEA RAX,[0x541608] MOV qword ptr [RAX],RCX JMP 0x00183092 LAB_0018304e: LEA RAX,[0x541600] CMP qword ptr [RAX],0x0 JNZ 0x0018308e MOV RAX,qword ptr [RBP + -0x8] MOV RDI,qword ptr [RAX] LEA RSI,[0x1fe55c] CALL 0x001f2cd0 CMP EAX,0x0 JZ 0x0018308e MOV RAX,qword ptr [RBP + -0x8] MOV RCX,qword ptr [RAX] ADD RCX,0x19 ADD RCX,-0x1 LEA RAX,[0x541600] MOV qword ptr [RAX],RCX JMP 0x00183090 LAB_0018308e: JMP 0x001830a7 LAB_00183090: JMP 0x00183092 LAB_00183092: JMP 0x00183094 LAB_00183094: JMP 0x00183096 LAB_00183096: MOV RAX,qword ptr [RBP + -0x8] ADD RAX,0x8 MOV qword ptr [RBP + -0x8],RAX JMP 0x00182fbd LAB_001830a7: JMP 0x001830a9 LAB_001830a9: MOV RAX,qword ptr [RBP + -0x8] CMP qword ptr [RAX],0x0 JZ 0x001830eb MOV RAX,qword ptr [RBP + -0x8] MOV RDI,qword ptr [RAX] LEA RSI,[0x1fe575] CALL 0x0012a570 CMP EAX,0x0 JNZ 0x001830eb LEA RAX,[0x5415f2] MOV byte ptr [RAX],0x1 LEA RAX,[0x5415f0] MOV byte ptr [RAX],0x0 MOV RAX,qword ptr [RBP + -0x8] ADD RAX,0x8 MOV qword ptr [RBP + -0x8],RAX LAB_001830eb: LEA RAX,[0x541600] CMP qword ptr [RAX],0x0 JNZ 0x00183111 LEA RDI,[0x1fe586] CALL 0x0012a4f0 MOV RCX,RAX LEA RAX,[0x541600] MOV qword ptr [RAX],RCX LAB_00183111: LEA RAX,[0x541608] CMP qword ptr [RAX],0x0 JZ 0x0018315c LEA RCX,[0x541810] LEA RAX,[0x541608] CMP qword ptr [RAX],RCX JZ 0x0018315c LEA RAX,[0x541608] MOV RSI,qword ptr [RAX] LEA RDI,[0x541810] XOR EAX,EAX MOV EDX,EAX CALL 0x001a1e10 LEA RAX,[0x541608] LEA RCX,[0x541810] MOV qword ptr [RAX],RCX LAB_0018315c: LEA RAX,[0x5415f8] CMP qword ptr [RAX],0x0 JZ 0x001831a7 LEA RCX,[0x541610] LEA RAX,[0x5415f8] CMP qword ptr [RAX],RCX JZ 0x001831a7 LEA RAX,[0x5415f8] MOV RSI,qword ptr [RAX] LEA RDI,[0x541610] XOR EAX,EAX MOV EDX,EAX CALL 0x001a1e10 LEA RAX,[0x5415f8] LEA RCX,[0x541610] MOV qword ptr [RAX],RCX LAB_001831a7: MOV RAX,qword ptr [RBP + -0x8] MOV RCX,qword ptr [RBP + -0x10] SUB RAX,RCX SAR RAX,0x3 ADD RSP,0x10 POP RBP RET
long get_defaults_options(long param_1) { int iVar1; long *local_10; local_10 = (long *)(param_1 + 8); my_defaults_extra_file = (int1 *)0x0; my_defaults_group_suffix = (char *)0x0; my_defaults_file = (int1 *)0x0; my_print_defaults = 0; my_no_defaults = 0; if ((*local_10 == 0) || (iVar1 = strcmp((char *)*local_10,"--no-defaults"), iVar1 != 0)) { for (; *local_10 != 0; local_10 = local_10 + 1) { if ((my_defaults_file == (int1 *)0x0) && (iVar1 = is_prefix(*local_10,"--defaults-file="), iVar1 != 0)) { my_defaults_file = (int1 *)(*local_10 + 0x10); } else if ((my_defaults_extra_file == (int1 *)0x0) && (iVar1 = is_prefix(*local_10,"--defaults-extra-file="), iVar1 != 0)) { my_defaults_extra_file = (int1 *)(*local_10 + 0x16); } else { if ((my_defaults_group_suffix != (char *)0x0) || (iVar1 = is_prefix(*local_10,"--defaults-group-suffix="), iVar1 == 0)) break; my_defaults_group_suffix = (char *)(*local_10 + 0x18); } } } else { my_no_defaults = 1; local_10 = (long *)(param_1 + 0x10); } if ((*local_10 != 0) && (iVar1 = strcmp((char *)*local_10,"--print-defaults"), iVar1 == 0)) { my_print_defaults = 1; my_defaults_mark_files = 0; local_10 = local_10 + 1; } if (my_defaults_group_suffix == (char *)0x0) { my_defaults_group_suffix = getenv("MYSQL_GROUP_SUFFIX"); } if ((my_defaults_extra_file != (int1 *)0x0) && (my_defaults_extra_file != get_defaults_options_extra_file_buffer)) { my_realpath(get_defaults_options_extra_file_buffer,my_defaults_extra_file,0); my_defaults_extra_file = get_defaults_options_extra_file_buffer; } if ((my_defaults_file != (int1 *)0x0) && (my_defaults_file != get_defaults_options_file_buffer)) { my_realpath(get_defaults_options_file_buffer,my_defaults_file,0); my_defaults_file = get_defaults_options_file_buffer; } return (long)local_10 - param_1 >> 3; }
6,090
testing::TestResult::GetTestPartResult(int) const
giladroyz[P]FindPeaks/build_O1/_deps/googletest-src/googletest/src/gtest.cc
const TestPartResult& TestResult::GetTestPartResult(int i) const { if (i < 0 || i >= total_part_count()) internal::posix::Abort(); return test_part_results_.at(static_cast<size_t>(i)); }
O1
cpp
testing::TestResult::GetTestPartResult(int) const: pushq %rax testl %esi, %esi js 0x1fc35 movq 0x38(%rdi), %rax movq 0x40(%rdi), %rcx subq %rax, %rcx shrq $0x4, %rcx imull $0xb6db6db7, %ecx, %ecx # imm = 0xB6DB6DB7 cmpl %esi, %ecx jle 0x1fc35 movl %esi, %esi movq 0x40(%rdi), %rcx subq %rax, %rcx sarq $0x4, %rcx movabsq $0x6db6db6db6db6db7, %rdx # imm = 0x6DB6DB6DB6DB6DB7 imulq %rcx, %rdx cmpq %rsi, %rdx jbe 0x1fc3a imulq $0x70, %rsi, %rcx addq %rcx, %rax popq %rcx retq callq 0x326af leaq 0x24aba(%rip), %rdi # 0x446fb xorl %eax, %eax callq 0x8860
_ZNK7testing10TestResult17GetTestPartResultEi: push rax test esi, esi js short loc_1FC35 mov rax, [rdi+38h] mov rcx, [rdi+40h] sub rcx, rax shr rcx, 4 imul ecx, 0B6DB6DB7h cmp ecx, esi jle short loc_1FC35 mov esi, esi mov rcx, [rdi+40h] sub rcx, rax sar rcx, 4 mov rdx, 6DB6DB6DB6DB6DB7h imul rdx, rcx cmp rdx, rsi jbe short loc_1FC3A imul rcx, rsi, 70h ; 'p' add rax, rcx pop rcx retn loc_1FC35: call _ZN7testing8internal5posix5AbortEv; testing::internal::posix::Abort(void) loc_1FC3A: lea rdi, aVectorMRangeCh; "vector::_M_range_check: __n (which is %"... xor eax, eax call __ZSt24__throw_out_of_range_fmtPKcz; std::__throw_out_of_range_fmt(char const*,...)
long long testing::TestResult::GetTestPartResult(testing::TestResult *this, int a2) { long long v2; // rax unsigned long long v3; // rdx if ( a2 < 0 || (v2 = *((_QWORD *)this + 7), (int)(-1227133513 * ((unsigned long long)(*((_QWORD *)this + 8) - v2) >> 4)) <= a2) ) { testing::internal::posix::Abort(this); } v3 = 0x6DB6DB6DB6DB6DB7LL * ((*((_QWORD *)this + 8) - v2) >> 4); if ( v3 <= (unsigned int)a2 ) std::__throw_out_of_range_fmt( "vector::_M_range_check: __n (which is %zu) >= this->size() (which is %zu)", (unsigned int)a2, v3); return 112LL * (unsigned int)a2 + v2; }
GetTestPartResult: PUSH RAX TEST ESI,ESI JS 0x0011fc35 MOV RAX,qword ptr [RDI + 0x38] MOV RCX,qword ptr [RDI + 0x40] SUB RCX,RAX SHR RCX,0x4 IMUL ECX,ECX,-0x49249249 CMP ECX,ESI JLE 0x0011fc35 MOV ESI,ESI MOV RCX,qword ptr [RDI + 0x40] SUB RCX,RAX SAR RCX,0x4 MOV RDX,0x6db6db6db6db6db7 IMUL RDX,RCX CMP RDX,RSI JBE 0x0011fc3a IMUL RCX,RSI,0x70 ADD RAX,RCX POP RCX RET LAB_0011fc35: CALL 0x001326af LAB_0011fc3a: LEA RDI,[0x1446fb] XOR EAX,EAX CALL 0x00108860
/* testing::TestResult::GetTestPartResult(int) const */ ulong __thiscall testing::TestResult::GetTestPartResult(TestResult *this,int param_1) { long lVar1; ulong uVar2; ulong uVar3; char *pcVar4; if ((param_1 < 0) || (lVar1 = *(long *)(this + 0x38), (int)((ulong)(*(long *)(this + 0x40) - lVar1) >> 4) * -0x49249249 <= param_1)) { internal::posix::Abort(); } else { uVar3 = (ulong)(uint)param_1; uVar2 = (*(long *)(this + 0x40) - lVar1 >> 4) * 0x6db6db6db6db6db7; if (uVar3 <= uVar2 && uVar2 - uVar3 != 0) { return lVar1 + uVar3 * 0x70; } } pcVar4 = "vector::_M_range_check: __n (which is %zu) >= this->size() (which is %zu)"; std::__throw_out_of_range_fmt ("vector::_M_range_check: __n (which is %zu) >= this->size() (which is %zu)"); return (ulong)(uint)((int)((ulong)(*(long *)(pcVar4 + 0x40) - *(long *)(pcVar4 + 0x38)) >> 4) * -0x49249249); }
6,091
wait_for_flush
eloqsql/storage/maria/ma_pagecache.c
static void wait_for_flush(PAGECACHE *pagecache __attribute__((unused)), PAGECACHE_BLOCK_LINK *block __attribute__((unused))) { struct st_my_thread_var *thread= my_thread_var; DBUG_ENTER("wait_for_flush"); wqueue_add_to_queue(&block->wqueue[COND_FOR_SAVED], thread); do { DBUG_PRINT("wait", ("suspend thread %s %ld", thread->name, (ulong) thread->id)); pagecache_pthread_cond_wait(&thread->suspend, &pagecache->cache_lock); } while(thread->next); DBUG_VOID_RETURN; }
O3
c
wait_for_flush: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r12 pushq %rbx movq %rsi, %r15 movq %rdi, %rbx callq 0xa29fe movq %rax, %r14 addq $0x50, %r15 movq %r15, %rdi movq %rax, %rsi callq 0xa75ab movq %r14, %r15 addq $0x8, %r15 addq $0xc8, %rbx leaq 0xa4b69(%rip), %r12 # 0xda88b cmpq $0x0, 0x38(%r14) jne 0x35d40 movq %r15, %rdi movq %rbx, %rsi callq 0x29430 cmpq $0x0, 0x88(%r14) jne 0x35d22 jmp 0x35d55 movq %r15, %rdi movq %rbx, %rsi movq %r12, %rdx movl $0x665, %ecx # imm = 0x665 callq 0x2eea0 jmp 0x35d34 popq %rbx popq %r12 popq %r14 popq %r15 popq %rbp retq
wait_for_flush: push rbp mov rbp, rsp push r15 push r14 push r12 push rbx mov r15, rsi mov rbx, rdi call _my_thread_var mov r14, rax add r15, 50h ; 'P' mov rdi, r15 mov rsi, rax call wqueue_add_to_queue mov r15, r14 add r15, 8 add rbx, 0C8h lea r12, aWorkspaceLlm4b_25; "/workspace/llm4binary/github2025/eloqsq"... loc_35D22: cmp qword ptr [r14+38h], 0 jnz short loc_35D40 mov rdi, r15 mov rsi, rbx call _pthread_cond_wait loc_35D34: cmp qword ptr [r14+88h], 0 jnz short loc_35D22 jmp short loc_35D55 loc_35D40: mov rdi, r15 mov rsi, rbx mov rdx, r12 mov ecx, 665h call psi_cond_wait jmp short loc_35D34 loc_35D55: pop rbx pop r12 pop r14 pop r15 pop rbp retn
long long wait_for_flush(long long a1, long long a2, long long a3, long long a4, long long a5) { long long v5; // r14 long long v6; // rbx long long result; // rax v5 = my_thread_var(a1, a2, a3, a4, a5); wqueue_add_to_queue(a2 + 80, v5); v6 = a1 + 200; do { if ( *(_QWORD *)(v5 + 56) ) result = psi_cond_wait( v5 + 8, v6, (long long)"/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_pagecache.c", 0x665u); else result = pthread_cond_wait(v5 + 8, v6); } while ( *(_QWORD *)(v5 + 136) ); return result; }
wait_for_flush: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R12 PUSH RBX MOV R15,RSI MOV RBX,RDI CALL 0x001a29fe MOV R14,RAX ADD R15,0x50 MOV RDI,R15 MOV RSI,RAX CALL 0x001a75ab MOV R15,R14 ADD R15,0x8 ADD RBX,0xc8 LEA R12,[0x1da88b] LAB_00135d22: CMP qword ptr [R14 + 0x38],0x0 JNZ 0x00135d40 MOV RDI,R15 MOV RSI,RBX CALL 0x00129430 LAB_00135d34: CMP qword ptr [R14 + 0x88],0x0 JNZ 0x00135d22 JMP 0x00135d55 LAB_00135d40: MOV RDI,R15 MOV RSI,RBX MOV RDX,R12 MOV ECX,0x665 CALL 0x0012eea0 JMP 0x00135d34 LAB_00135d55: POP RBX POP R12 POP R14 POP R15 POP RBP RET
void wait_for_flush(long param_1,long param_2) { long lVar1; lVar1 = _my_thread_var(); wqueue_add_to_queue(param_2 + 0x50,lVar1); do { if (*(long *)(lVar1 + 0x38) == 0) { pthread_cond_wait((pthread_cond_t *)(lVar1 + 8),(pthread_mutex_t *)(param_1 + 200)); } else { psi_cond_wait((pthread_cond_t *)(lVar1 + 8),(pthread_mutex_t *)(param_1 + 200), "/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_pagecache.c",0x665); } } while (*(long *)(lVar1 + 0x88) != 0); return; }
6,092
my_coll_parser_scan_shift_sequence
eloqsql/strings/ctype-uca.c
static int my_coll_parser_scan_shift_sequence(MY_COLL_RULE_PARSER *p) { MY_COLL_RULE before_extend; memset(&p->rule.curr, 0, sizeof(p->rule.curr)); /* Scan single shift character or contraction */ if (!my_coll_parser_scan_character_list(p, p->rule.curr, MY_UCA_MAX_CONTRACTION, "Contraction")) return 0; before_extend= p->rule; /* Remember the part before "/" */ /* Append the part after "/" as expansion */ if (my_coll_parser_curr(p)->term == MY_COLL_LEXEM_EXTEND) { my_coll_parser_scan(p); if (!my_coll_parser_scan_character_list(p, p->rule.base, MY_UCA_MAX_EXPANSION, "Expansion")) return 0; } else if (my_coll_parser_curr(p)->term == MY_COLL_LEXEM_CONTEXT) { /* We support 2-character long context sequences only: one character is the previous context, plus the current character. It's OK as Unicode's CLDR does not have longer examples. */ my_coll_parser_scan(p); p->rule.with_context= TRUE; if (!my_coll_parser_scan_character_list(p, p->rule.curr + 1, 1, "context")) return 0; } /* Add rule to the rule list */ if (my_coll_rules_add(p->rules, &p->rule)) return 0; p->rule= before_extend; /* Restore to the state before "/" */ return 1; }
O0
c
my_coll_parser_scan_shift_sequence: pushq %rbp movq %rsp, %rbp subq $0xb0, %rsp movq %rdi, -0x10(%rbp) movq -0x10(%rbp), %rdi addq $0x50, %rdi addq $0x50, %rdi xorl %esi, %esi movl $0x30, %edx callq 0x362e0 movq -0x10(%rbp), %rdi movq -0x10(%rbp), %rsi addq $0x50, %rsi addq $0x50, %rsi movl $0x6, %edx leaq 0x31960(%rip), %rcx # 0xd2203 callq 0xa0e90 cmpl $0x0, %eax jne 0xa08b9 movl $0x0, -0x4(%rbp) jmp 0xa09b8 movq -0x10(%rbp), %rsi addq $0x50, %rsi leaq -0xb0(%rbp), %rdi movl $0xa0, %edx callq 0x360b0 movq -0x10(%rbp), %rdi callq 0x9fed0 cmpl $0x8, (%rax) jne 0xa0919 movq -0x10(%rbp), %rdi callq 0xa06b0 movq -0x10(%rbp), %rdi movq -0x10(%rbp), %rsi addq $0x50, %rsi movl $0xa, %edx leaq 0x31727(%rip), %rcx # 0xd2028 callq 0xa0e90 cmpl $0x0, %eax jne 0xa0917 movl $0x0, -0x4(%rbp) jmp 0xa09b8 jmp 0xa0972 movq -0x10(%rbp), %rdi callq 0x9fed0 cmpl $0x9, (%rax) jne 0xa0970 movq -0x10(%rbp), %rdi callq 0xa06b0 movq -0x10(%rbp), %rax movb $0x1, 0xe8(%rax) movq -0x10(%rbp), %rdi movq -0x10(%rbp), %rsi addq $0x50, %rsi addq $0x50, %rsi addq $0x8, %rsi movl $0x1, %edx leaq 0x321e9(%rip), %rcx # 0xd2b44 callq 0xa0e90 cmpl $0x0, %eax jne 0xa096e movl $0x0, -0x4(%rbp) jmp 0xa09b8 jmp 0xa0970 jmp 0xa0972 movq -0x10(%rbp), %rax movq 0xf0(%rax), %rdi movq -0x10(%rbp), %rsi addq $0x50, %rsi callq 0xa11e0 cmpl $0x0, %eax je 0xa0998 movl $0x0, -0x4(%rbp) jmp 0xa09b8 movq -0x10(%rbp), %rdi addq $0x50, %rdi leaq -0xb0(%rbp), %rsi movl $0xa0, %edx callq 0x360b0 movl $0x1, -0x4(%rbp) movl -0x4(%rbp), %eax addq $0xb0, %rsp popq %rbp retq nopw %cs:(%rax,%rax)
my_coll_parser_scan_shift_sequence: push rbp mov rbp, rsp sub rsp, 0B0h mov [rbp+var_10], rdi mov rdi, [rbp+var_10] add rdi, 50h ; 'P' add rdi, 50h ; 'P' xor esi, esi mov edx, 30h ; '0' call _memset mov rdi, [rbp+var_10] mov rsi, [rbp+var_10] add rsi, 50h ; 'P' add rsi, 50h ; 'P' mov edx, 6 lea rcx, aContraction; "Contraction" call my_coll_parser_scan_character_list cmp eax, 0 jnz short loc_A08B9 mov [rbp+var_4], 0 jmp loc_A09B8 loc_A08B9: mov rsi, [rbp+var_10] add rsi, 50h ; 'P' lea rdi, [rbp+var_B0] mov edx, 0A0h call _memcpy mov rdi, [rbp+var_10] call my_coll_parser_curr cmp dword ptr [rax], 8 jnz short loc_A0919 mov rdi, [rbp+var_10] call my_coll_parser_scan mov rdi, [rbp+var_10] mov rsi, [rbp+var_10] add rsi, 50h ; 'P' mov edx, 0Ah lea rcx, aExpansion; "Expansion" call my_coll_parser_scan_character_list cmp eax, 0 jnz short loc_A0917 mov [rbp+var_4], 0 jmp loc_A09B8 loc_A0917: jmp short loc_A0972 loc_A0919: mov rdi, [rbp+var_10] call my_coll_parser_curr cmp dword ptr [rax], 9 jnz short loc_A0970 mov rdi, [rbp+var_10] call my_coll_parser_scan mov rax, [rbp+var_10] mov byte ptr [rax+0E8h], 1 mov rdi, [rbp+var_10] mov rsi, [rbp+var_10] add rsi, 50h ; 'P' add rsi, 50h ; 'P' add rsi, 8 mov edx, 1 lea rcx, aCharsetsCharse_52+23h; "context" call my_coll_parser_scan_character_list cmp eax, 0 jnz short loc_A096E mov [rbp+var_4], 0 jmp short loc_A09B8 loc_A096E: jmp short $+2 loc_A0970: jmp short $+2 loc_A0972: mov rax, [rbp+var_10] mov rdi, [rax+0F0h] mov rsi, [rbp+var_10] add rsi, 50h ; 'P' call my_coll_rules_add cmp eax, 0 jz short loc_A0998 mov [rbp+var_4], 0 jmp short loc_A09B8 loc_A0998: mov rdi, [rbp+var_10] add rdi, 50h ; 'P' lea rsi, [rbp+var_B0] mov edx, 0A0h call _memcpy mov [rbp+var_4], 1 loc_A09B8: mov eax, [rbp+var_4] add rsp, 0B0h pop rbp retn
long long my_coll_parser_scan_shift_sequence(long long a1) { _BYTE v2[160]; // [rsp+0h] [rbp-B0h] BYREF long long v3; // [rsp+A0h] [rbp-10h] v3 = a1; memset(a1 + 160, 0LL, 48LL); if ( (unsigned int)my_coll_parser_scan_character_list(v3, v3 + 160, 6LL, "Contraction") ) { memcpy(v2, v3 + 80, sizeof(v2)); if ( *(_DWORD *)my_coll_parser_curr(v3) == 8 ) { my_coll_parser_scan(v3); if ( !(unsigned int)my_coll_parser_scan_character_list(v3, v3 + 80, 10LL, "Expansion") ) return 0; } else if ( *(_DWORD *)my_coll_parser_curr(v3) == 9 ) { my_coll_parser_scan(v3); *(_BYTE *)(v3 + 232) = 1; if ( !(unsigned int)my_coll_parser_scan_character_list(v3, v3 + 168, 1LL, "context") ) return 0; } if ( (unsigned int)my_coll_rules_add(*(_QWORD *)(v3 + 240), v3 + 80) ) { return 0; } else { memcpy(v3 + 80, v2, 160LL); return 1; } } else { return 0; } }
my_coll_parser_scan_shift_sequence: PUSH RBP MOV RBP,RSP SUB RSP,0xb0 MOV qword ptr [RBP + -0x10],RDI MOV RDI,qword ptr [RBP + -0x10] ADD RDI,0x50 ADD RDI,0x50 XOR ESI,ESI MOV EDX,0x30 CALL 0x001362e0 MOV RDI,qword ptr [RBP + -0x10] MOV RSI,qword ptr [RBP + -0x10] ADD RSI,0x50 ADD RSI,0x50 MOV EDX,0x6 LEA RCX,[0x1d2203] CALL 0x001a0e90 CMP EAX,0x0 JNZ 0x001a08b9 MOV dword ptr [RBP + -0x4],0x0 JMP 0x001a09b8 LAB_001a08b9: MOV RSI,qword ptr [RBP + -0x10] ADD RSI,0x50 LEA RDI,[RBP + -0xb0] MOV EDX,0xa0 CALL 0x001360b0 MOV RDI,qword ptr [RBP + -0x10] CALL 0x0019fed0 CMP dword ptr [RAX],0x8 JNZ 0x001a0919 MOV RDI,qword ptr [RBP + -0x10] CALL 0x001a06b0 MOV RDI,qword ptr [RBP + -0x10] MOV RSI,qword ptr [RBP + -0x10] ADD RSI,0x50 MOV EDX,0xa LEA RCX,[0x1d2028] CALL 0x001a0e90 CMP EAX,0x0 JNZ 0x001a0917 MOV dword ptr [RBP + -0x4],0x0 JMP 0x001a09b8 LAB_001a0917: JMP 0x001a0972 LAB_001a0919: MOV RDI,qword ptr [RBP + -0x10] CALL 0x0019fed0 CMP dword ptr [RAX],0x9 JNZ 0x001a0970 MOV RDI,qword ptr [RBP + -0x10] CALL 0x001a06b0 MOV RAX,qword ptr [RBP + -0x10] MOV byte ptr [RAX + 0xe8],0x1 MOV RDI,qword ptr [RBP + -0x10] MOV RSI,qword ptr [RBP + -0x10] ADD RSI,0x50 ADD RSI,0x50 ADD RSI,0x8 MOV EDX,0x1 LEA RCX,[0x1d2b44] CALL 0x001a0e90 CMP EAX,0x0 JNZ 0x001a096e MOV dword ptr [RBP + -0x4],0x0 JMP 0x001a09b8 LAB_001a096e: JMP 0x001a0970 LAB_001a0970: JMP 0x001a0972 LAB_001a0972: MOV RAX,qword ptr [RBP + -0x10] MOV RDI,qword ptr [RAX + 0xf0] MOV RSI,qword ptr [RBP + -0x10] ADD RSI,0x50 CALL 0x001a11e0 CMP EAX,0x0 JZ 0x001a0998 MOV dword ptr [RBP + -0x4],0x0 JMP 0x001a09b8 LAB_001a0998: MOV RDI,qword ptr [RBP + -0x10] ADD RDI,0x50 LEA RSI,[RBP + -0xb0] MOV EDX,0xa0 CALL 0x001360b0 MOV dword ptr [RBP + -0x4],0x1 LAB_001a09b8: MOV EAX,dword ptr [RBP + -0x4] ADD RSP,0xb0 POP RBP RET
int4 my_coll_parser_scan_shift_sequence(long param_1) { int iVar1; int *piVar2; int1 local_b8 [160]; long local_18; int4 local_c; local_18 = param_1; memset((void *)(param_1 + 0xa0),0,0x30); iVar1 = my_coll_parser_scan_character_list(local_18,local_18 + 0xa0,6,"Contraction"); if (iVar1 == 0) { local_c = 0; } else { memcpy(local_b8,(void *)(local_18 + 0x50),0xa0); piVar2 = (int *)my_coll_parser_curr(local_18); if (*piVar2 == 8) { my_coll_parser_scan(local_18); iVar1 = my_coll_parser_scan_character_list(local_18,local_18 + 0x50,10,"Expansion"); if (iVar1 == 0) { return 0; } } else { piVar2 = (int *)my_coll_parser_curr(local_18); if (*piVar2 == 9) { my_coll_parser_scan(local_18); *(int1 *)(local_18 + 0xe8) = 1; iVar1 = my_coll_parser_scan_character_list(local_18,local_18 + 0xa8,1,"context"); if (iVar1 == 0) { return 0; } } } iVar1 = my_coll_rules_add(*(int8 *)(local_18 + 0xf0),local_18 + 0x50); if (iVar1 == 0) { memcpy((void *)(local_18 + 0x50),local_b8,0xa0); local_c = 1; } else { local_c = 0; } } return local_c; }
6,093
blst_precompute_lines
corpus-core[P]colibri-stateless/build_O3/_deps/blst-src/src/pairing.c
void blst_precompute_lines(vec384fp6 Qlines[68], const POINTonE2_affine *Q) { precompute_lines(Qlines, Q); }
O3
c
blst_precompute_lines: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %rbx subq $0x128, %rsp # imm = 0x128 movq %rsi, %rbx movq %rdi, %r14 leaq -0x140(%rbp), %r15 movl $0xc0, %edx movq %r15, %rdi callq 0x22090 leaq -0x80(%rbp), %rdi leaq 0x2bd69(%rip), %rsi # 0x8ccd8 movl $0xc, %ecx rep movsq (%rsi), %es:(%rdi) movq %r14, %rdi movq %r15, %rsi movq %r15, %rdx callq 0x688e8 leaq 0x120(%r14), %rdi movl $0x2, %ecx movq %r15, %rsi movq %rbx, %rdx callq 0x68fad leaq 0x480(%r14), %rdi movl $0x3, %ecx movq %r15, %rsi movq %rbx, %rdx callq 0x68fad leaq 0x900(%r14), %rdi movl $0x9, %ecx movq %r15, %rsi movq %rbx, %rdx callq 0x68fad leaq 0x1440(%r14), %rdi movl $0x20, %ecx movq %r15, %rsi movq %rbx, %rdx callq 0x68fad addq $0x3960, %r14 # imm = 0x3960 movl $0x10, %ecx movq %r14, %rdi movq %r15, %rsi movq %rbx, %rdx callq 0x68fad addq $0x128, %rsp # imm = 0x128 popq %rbx popq %r14 popq %r15 popq %rbp retq
blst_precompute_lines: push rbp mov rbp, rsp push r15 push r14 push rbx sub rsp, 128h mov rbx, rsi mov r14, rdi lea r15, [rbp+var_140] mov edx, 0C0h mov rdi, r15 call _memcpy lea rdi, [rbp+var_80] lea rsi, BLS12_381_Rx mov ecx, 0Ch rep movsq mov rdi, r14 mov rsi, r15 mov rdx, r15 call line_dbl lea rdi, [r14+120h] mov ecx, 2 mov rsi, r15 mov rdx, rbx call pre_add_n_dbl lea rdi, [r14+480h] mov ecx, 3 mov rsi, r15 mov rdx, rbx call pre_add_n_dbl lea rdi, [r14+900h] mov ecx, 9 mov rsi, r15 mov rdx, rbx call pre_add_n_dbl lea rdi, [r14+1440h] mov ecx, 20h ; ' ' mov rsi, r15 mov rdx, rbx call pre_add_n_dbl add r14, 3960h mov ecx, 10h mov rdi, r14 mov rsi, r15 mov rdx, rbx call pre_add_n_dbl add rsp, 128h pop rbx pop r14 pop r15 pop rbp retn
long long blst_precompute_lines(long long a1, long long a2) { _BYTE v3[192]; // [rsp+0h] [rbp-140h] BYREF _BYTE v4[96]; // [rsp+C0h] [rbp-80h] BYREF memcpy(v3); qmemcpy(v4, &BLS12_381_Rx, sizeof(v4)); line_dbl(a1, v3, v3); pre_add_n_dbl(a1 + 288, v3, a2, 2LL); pre_add_n_dbl(a1 + 1152, v3, a2, 3LL); pre_add_n_dbl(a1 + 2304, v3, a2, 9LL); pre_add_n_dbl(a1 + 5184, v3, a2, 32LL); return pre_add_n_dbl(a1 + 14688, v3, a2, 16LL); }
blst_precompute_lines: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH RBX SUB RSP,0x128 MOV RBX,RSI MOV R14,RDI LEA R15,[RBP + -0x140] MOV EDX,0xc0 MOV RDI,R15 CALL 0x00122090 LEA RDI,[RBP + -0x80] LEA RSI,[0x18ccd8] MOV ECX,0xc MOVSQ.REP RDI,RSI MOV RDI,R14 MOV RSI,R15 MOV RDX,R15 CALL 0x001688e8 LEA RDI,[R14 + 0x120] MOV ECX,0x2 MOV RSI,R15 MOV RDX,RBX CALL 0x00168fad LEA RDI,[R14 + 0x480] MOV ECX,0x3 MOV RSI,R15 MOV RDX,RBX CALL 0x00168fad LEA RDI,[R14 + 0x900] MOV ECX,0x9 MOV RSI,R15 MOV RDX,RBX CALL 0x00168fad LEA RDI,[R14 + 0x1440] MOV ECX,0x20 MOV RSI,R15 MOV RDX,RBX CALL 0x00168fad ADD R14,0x3960 MOV ECX,0x10 MOV RDI,R14 MOV RSI,R15 MOV RDX,RBX CALL 0x00168fad ADD RSP,0x128 POP RBX POP R14 POP R15 POP RBP RET
void blst_precompute_lines(long param_1,void *param_2) { long lVar1; int8 *puVar2; int8 *puVar3; byte bVar4; int1 local_148 [192]; int8 local_88 [13]; bVar4 = 0; memcpy(local_148,param_2,0xc0); puVar2 = &BLS12_381_Rx; puVar3 = local_88; for (lVar1 = 0xc; lVar1 != 0; lVar1 = lVar1 + -1) { *puVar3 = *puVar2; puVar2 = puVar2 + (ulong)bVar4 * -2 + 1; puVar3 = puVar3 + (ulong)bVar4 * -2 + 1; } line_dbl(param_1,local_148,local_148); pre_add_n_dbl(param_1 + 0x120,local_148,param_2,2); pre_add_n_dbl(param_1 + 0x480,local_148,param_2,3); pre_add_n_dbl(param_1 + 0x900,local_148,param_2,9); pre_add_n_dbl(param_1 + 0x1440,local_148,param_2,0x20); pre_add_n_dbl(param_1 + 0x3960,local_148,param_2,0x10); return; }
6,094
my_lengthsp_8bit
eloqsql/strings/ctype-simple.c
size_t my_lengthsp_8bit(CHARSET_INFO *cs __attribute__((unused)), const char *ptr, size_t length) { const char *end; end= (const char *) skip_trailing_space((const uchar *)ptr, length); return (size_t) (end-ptr); }
O3
c
my_lengthsp_8bit: pushq %rbp movq %rsp, %rbp leaq (%rsi,%rdx), %rdi cmpq $0x15, %rdx jb 0x4bd6b movq %rdi, %rdx andq $-0x4, %rdx cmpq %rsi, %rdx jbe 0x4bd6b leaq 0x3(%rsi), %rax andq $-0x4, %rax movq %rdi, %rcx movb -0x1(%rdi), %r8b cmpq %rdx, %rdi jbe 0x4bd8c leaq -0x1(%rcx), %rdi cmpb $0x20, %r8b je 0x4bd53 jmp 0x4bd6e movq %rdi, %rcx movq %rcx, %rdx subq %rsi, %rdx movq %rdx, %rax cmpq %rsi, %rcx jbe 0x4bd8a cmpb $0x20, -0x1(%rcx) leaq -0x1(%rcx), %rcx leaq -0x1(%rax), %rdx je 0x4bd74 popq %rbp retq cmpb $0x20, %r8b setne %dil cmpq %rdx, %rax setae %dl orb %dil, %dl jne 0x4bd6e movq %rcx, %rdx movq %rdx, %rcx cmpq %rax, %rdx jbe 0x4bd6e leaq -0x4(%rcx), %rdx cmpl $0x20202020, -0x4(%rcx) # imm = 0x20202020 je 0x4bda2 jmp 0x4bd6e
my_lengthsp_8bit: push rbp mov rbp, rsp lea rdi, [rsi+rdx] cmp rdx, 15h jb short loc_4BD6B mov rdx, rdi and rdx, 0FFFFFFFFFFFFFFFCh cmp rdx, rsi jbe short loc_4BD6B lea rax, [rsi+3] and rax, 0FFFFFFFFFFFFFFFCh loc_4BD53: mov rcx, rdi mov r8b, [rdi-1] cmp rdi, rdx jbe short loc_4BD8C lea rdi, [rcx-1] cmp r8b, 20h ; ' ' jz short loc_4BD53 jmp short loc_4BD6E loc_4BD6B: mov rcx, rdi loc_4BD6E: mov rdx, rcx sub rdx, rsi loc_4BD74: mov rax, rdx cmp rcx, rsi jbe short loc_4BD8A cmp byte ptr [rcx-1], 20h ; ' ' lea rcx, [rcx-1] lea rdx, [rax-1] jz short loc_4BD74 loc_4BD8A: pop rbp retn loc_4BD8C: cmp r8b, 20h ; ' ' setnz dil cmp rax, rdx setnb dl or dl, dil jnz short loc_4BD6E mov rdx, rcx loc_4BDA2: mov rcx, rdx cmp rdx, rax jbe short loc_4BD6E lea rdx, [rcx-4] cmp dword ptr [rcx-4], 20202020h jz short loc_4BDA2 jmp short loc_4BD6E
unsigned long long my_lengthsp_8bit(long long a1, unsigned long long a2, unsigned long long a3) { unsigned long long v3; // rdi unsigned long long v4; // rdx unsigned long long v5; // rax unsigned long long v6; // rcx char v7; // r8 unsigned long long v8; // rdx unsigned long long result; // rax bool v10; // zf unsigned long long v11; // rdx v3 = a2 + a3; if ( a3 < 0x15 || (v4 = v3 & 0xFFFFFFFFFFFFFFFCLL, (v3 & 0xFFFFFFFFFFFFFFFCLL) <= a2) ) { v6 = v3; } else { v5 = (a2 + 3) & 0xFFFFFFFFFFFFFFFCLL; while ( 1 ) { v6 = v3; v7 = *(_BYTE *)(v3 - 1); if ( v3 <= v4 ) break; --v3; if ( v7 != 32 ) goto LABEL_8; } if ( v7 == 32 && v5 < v4 ) { v11 = v3; do { v6 = v11; if ( v11 <= v5 ) break; v11 -= 4LL; } while ( *(_DWORD *)(v6 - 4) == 538976288 ); } } LABEL_8: v8 = v6 - a2; do { result = v8; if ( v6 <= a2 ) break; v10 = *(_BYTE *)--v6 == 32; --v8; } while ( v10 ); return result; }
my_lengthsp_8bit: PUSH RBP MOV RBP,RSP LEA RDI,[RSI + RDX*0x1] CMP RDX,0x15 JC 0x0014bd6b MOV RDX,RDI AND RDX,-0x4 CMP RDX,RSI JBE 0x0014bd6b LEA RAX,[RSI + 0x3] AND RAX,-0x4 LAB_0014bd53: MOV RCX,RDI MOV R8B,byte ptr [RDI + -0x1] CMP RDI,RDX JBE 0x0014bd8c LEA RDI,[RCX + -0x1] CMP R8B,0x20 JZ 0x0014bd53 JMP 0x0014bd6e LAB_0014bd6b: MOV RCX,RDI LAB_0014bd6e: MOV RDX,RCX SUB RDX,RSI LAB_0014bd74: MOV RAX,RDX CMP RCX,RSI JBE 0x0014bd8a CMP byte ptr [RCX + -0x1],0x20 LEA RCX,[RCX + -0x1] LEA RDX,[RAX + -0x1] JZ 0x0014bd74 LAB_0014bd8a: POP RBP RET LAB_0014bd8c: CMP R8B,0x20 SETNZ DIL CMP RAX,RDX SETNC DL OR DL,DIL JNZ 0x0014bd6e MOV RDX,RCX LAB_0014bda2: MOV RCX,RDX CMP RDX,RAX JBE 0x0014bd6e LEA RDX,[RCX + -0x4] CMP dword ptr [RCX + -0x4],0x20202020 JZ 0x0014bda2 JMP 0x0014bd6e
void my_lengthsp_8bit(int8 param_1,ulong param_2,ulong param_3) { char *pcVar1; ulong uVar2; ulong uVar3; ulong uVar4; ulong uVar5; uVar4 = param_2 + param_3; if ((0x14 < param_3) && (uVar5 = uVar4 & 0xfffffffffffffffc, param_2 < uVar5)) { uVar3 = param_2 + 3 & 0xfffffffffffffffc; uVar2 = uVar4; do { uVar4 = uVar2; if (uVar4 <= uVar5) { uVar2 = uVar4; if (uVar3 < uVar5 && *(char *)(uVar4 - 1) == ' ') goto LAB_0014bda2; break; } uVar2 = uVar4 - 1; } while (*(char *)(uVar4 - 1) == ' '); } goto LAB_0014bd74; while (uVar2 = uVar4 - 4, *(int *)(uVar4 - 4) == 0x20202020) { LAB_0014bda2: uVar4 = uVar2; if (uVar4 <= uVar3) break; } LAB_0014bd74: do { if (uVar4 <= param_2) { return; } pcVar1 = (char *)(uVar4 - 1); uVar4 = uVar4 - 1; } while (*pcVar1 == ' '); return; }
6,095
ma_hashtbl_init
eloqsql/libmariadb/libmariadb/ma_hashtbl.c
my_bool _ma_hashtbl_init(MA_HASHTBL *hash,uint size,uint key_offset,uint key_length, hash_get_key get_key, void (*free_element)(void*),uint flags CALLER_INFO_PROTO) { hash->records=0; if (ma_init_dynamic_array_ci(&hash->array,sizeof(MA_HASHTBL_LINK),size,0)) { hash->free=0; /* Allow call to hash_free */ return(TRUE); } hash->key_offset=key_offset; hash->key_length=key_length; hash->blength=1; hash->current_record= NO_RECORD; /* For the future */ hash->get_key=get_key; hash->free=free_element; hash->flags=flags; if (flags & MA_HASHTBL_CASE_INSENSITIVE) hash->calc_hashnr=calc_hashnr_caseup; else hash->calc_hashnr=calc_hashnr; return(0); }
O3
c
ma_hashtbl_init: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx pushq %rax movq %r9, %r14 movq %r8, %r15 movl %ecx, %r12d movl %edx, %r13d movl %esi, %edx movq %rdi, %rbx movl $0x0, 0x8(%rdi) addq $0x18, %rdi movl $0x10, %esi xorl %ecx, %ecx callq 0x19a28 testb %al, %al je 0x1a71e movq $0x0, 0x38(%rbx) movb $0x1, %al jmp 0x1a75b movl 0x10(%rbp), %eax movl %r13d, (%rbx) movl %r12d, 0x4(%rbx) movabsq $-0xffffffff, %rcx # imm = 0xFFFFFFFF00000001 movq %rcx, 0xc(%rbx) movq %r15, 0x30(%rbx) movq %r14, 0x38(%rbx) movl %eax, 0x14(%rbx) testb $0x1, %al jne 0x1a74e leaq 0x80(%rip), %rax # 0x1a7cc jmp 0x1a755 leaq 0x15(%rip), %rax # 0x1a76a movq %rax, 0x40(%rbx) xorl %eax, %eax addq $0x8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
_ma_hashtbl_init: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx push rax mov r14, r9 mov r15, r8 mov r12d, ecx mov r13d, edx mov edx, esi mov rbx, rdi mov dword ptr [rdi+8], 0 add rdi, 18h mov esi, 10h xor ecx, ecx call ma_init_dynamic_array test al, al jz short loc_1A71E mov qword ptr [rbx+38h], 0 mov al, 1 jmp short loc_1A75B loc_1A71E: mov eax, [rbp+arg_0] mov [rbx], r13d mov [rbx+4], r12d mov rcx, 0FFFFFFFF00000001h mov [rbx+0Ch], rcx mov [rbx+30h], r15 mov [rbx+38h], r14 mov [rbx+14h], eax test al, 1 jnz short loc_1A74E lea rax, calc_hashnr jmp short loc_1A755 loc_1A74E: lea rax, calc_hashnr_caseup loc_1A755: mov [rbx+40h], rax xor eax, eax loc_1A75B: add rsp, 8 pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
char ma_hashtbl_init(long long a1, unsigned int a2, int a3, int a4, long long a5, long long a6, int a7) { long long ( *v12)(); // rax *(_DWORD *)(a1 + 8) = 0; if ( (unsigned __int8)ma_init_dynamic_array(a1 + 24, 0x10u, a2, 0) ) { *(_QWORD *)(a1 + 56) = 0LL; return 1; } else { *(_DWORD *)a1 = a3; *(_DWORD *)(a1 + 4) = a4; *(_QWORD *)(a1 + 12) = 0xFFFFFFFF00000001LL; *(_QWORD *)(a1 + 48) = a5; *(_QWORD *)(a1 + 56) = a6; *(_DWORD *)(a1 + 20) = a7; if ( (a7 & 1) != 0 ) v12 = calc_hashnr_caseup; else v12 = calc_hashnr; *(_QWORD *)(a1 + 64) = v12; return 0; } }
_ma_hashtbl_init: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX PUSH RAX MOV R14,R9 MOV R15,R8 MOV R12D,ECX MOV R13D,EDX MOV EDX,ESI MOV RBX,RDI MOV dword ptr [RDI + 0x8],0x0 ADD RDI,0x18 MOV ESI,0x10 XOR ECX,ECX CALL 0x00119a28 TEST AL,AL JZ 0x0011a71e MOV qword ptr [RBX + 0x38],0x0 MOV AL,0x1 JMP 0x0011a75b LAB_0011a71e: MOV EAX,dword ptr [RBP + 0x10] MOV dword ptr [RBX],R13D MOV dword ptr [RBX + 0x4],R12D MOV RCX,-0xffffffff MOV qword ptr [RBX + 0xc],RCX MOV qword ptr [RBX + 0x30],R15 MOV qword ptr [RBX + 0x38],R14 MOV dword ptr [RBX + 0x14],EAX TEST AL,0x1 JNZ 0x0011a74e LEA RAX,[0x11a7cc] JMP 0x0011a755 LAB_0011a74e: LEA RAX,[0x11a76a] LAB_0011a755: MOV qword ptr [RBX + 0x40],RAX XOR EAX,EAX LAB_0011a75b: ADD RSP,0x8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
int8 _ma_hashtbl_init(int4 *param_1,int4 param_2,int4 param_3,int4 param_4, int8 param_5,int8 param_6,uint param_7) { char cVar1; int8 uVar2; code *pcVar3; param_1[2] = 0; cVar1 = ma_init_dynamic_array(param_1 + 6,0x10,param_2,0); if (cVar1 == '\0') { *param_1 = param_3; param_1[1] = param_4; *(int8 *)(param_1 + 3) = 0xffffffff00000001; *(int8 *)(param_1 + 0xc) = param_5; *(int8 *)(param_1 + 0xe) = param_6; param_1[5] = param_7; if ((param_7 & 1) == 0) { pcVar3 = calc_hashnr; } else { pcVar3 = calc_hashnr_caseup; } *(code **)(param_1 + 0x10) = pcVar3; uVar2 = 0; } else { *(int8 *)(param_1 + 0xe) = 0; uVar2 = 1; } return uVar2; }
6,096
list_delete
eloqsql/libmariadb/libmariadb/ma_list.c
LIST *list_delete(LIST *root, LIST *element) { if (element->prev) element->prev->next=element->next; else root=element->next; if (element->next) element->next->prev=element->prev; return root; }
O3
c
list_delete: pushq %rbp movq %rsp, %rbp movq (%rsi), %rdx movq 0x8(%rsi), %rcx movq %rcx, %rax testq %rdx, %rdx je 0x1fc3e movq %rcx, 0x8(%rdx) movq %rdi, %rax testq %rcx, %rcx je 0x1fc49 movq (%rsi), %rdx movq %rdx, (%rcx) popq %rbp retq
list_delete: push rbp mov rbp, rsp mov rdx, [rsi] mov rcx, [rsi+8] mov rax, rcx test rdx, rdx jz short loc_1FC3E mov [rdx+8], rcx mov rax, rdi loc_1FC3E: test rcx, rcx jz short loc_1FC49 mov rdx, [rsi] mov [rcx], rdx loc_1FC49: pop rbp retn
_QWORD * list_delete(_QWORD *a1, _QWORD *a2) { _QWORD *v2; // rcx _QWORD *result; // rax v2 = (_QWORD *)a2[1]; result = v2; if ( *a2 ) { *(_QWORD *)(*a2 + 8LL) = v2; result = a1; } if ( v2 ) *v2 = *a2; return result; }
list_delete: PUSH RBP MOV RBP,RSP MOV RDX,qword ptr [RSI] MOV RCX,qword ptr [RSI + 0x8] MOV RAX,RCX TEST RDX,RDX JZ 0x0011fc3e MOV qword ptr [RDX + 0x8],RCX MOV RAX,RDI LAB_0011fc3e: TEST RCX,RCX JZ 0x0011fc49 MOV RDX,qword ptr [RSI] MOV qword ptr [RCX],RDX LAB_0011fc49: POP RBP RET
long * list_delete(long *param_1,long *param_2) { long *plVar1; long *plVar2; plVar1 = (long *)param_2[1]; plVar2 = plVar1; if (*param_2 != 0) { *(long **)(*param_2 + 8) = plVar1; plVar2 = param_1; } if (plVar1 != (long *)0x0) { *plVar1 = *param_2; } return plVar2; }
6,097
check_mb_gb18030_valid
eloqsql/libmariadb/libmariadb/ma_charset.c
static unsigned int check_mb_gb18030_valid(const char * start, const char * end) { if (end - start <= 1 || !is_gb18030_odd(start[0])) { return 0; } if (is_gb18030_even_2(start[1])) { return 2; } else if (end - start > 3 && is_gb18030_even_4(start[1]) && is_gb18030_odd(start[2]) && is_gb18030_even_4(start[3])) { return 4; } return 0; }
O0
c
check_mb_gb18030_valid: pushq %rbp movq %rsp, %rbp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq -0x18(%rbp), %rax movq -0x10(%rbp), %rcx subq %rcx, %rax cmpq $0x1, %rax jle 0x43b6b movq -0x10(%rbp), %rax movzbl (%rax), %ecx movl $0x81, %eax cmpl %ecx, %eax jg 0x43b6b movq -0x10(%rbp), %rax movzbl (%rax), %eax cmpl $0xfe, %eax jle 0x43b77 movl $0x0, -0x4(%rbp) jmp 0x43c3d movq -0x10(%rbp), %rax movzbl 0x1(%rax), %ecx movl $0x40, %eax cmpl %ecx, %eax jg 0x43b95 movq -0x10(%rbp), %rax movzbl 0x1(%rax), %eax cmpl $0x7e, %eax jle 0x43bb5 movq -0x10(%rbp), %rax movzbl 0x1(%rax), %ecx movl $0x80, %eax cmpl %ecx, %eax jg 0x43bbe movq -0x10(%rbp), %rax movzbl 0x1(%rax), %eax cmpl $0xfe, %eax jg 0x43bbe movl $0x2, -0x4(%rbp) jmp 0x43c3d movq -0x18(%rbp), %rax movq -0x10(%rbp), %rcx subq %rcx, %rax cmpq $0x3, %rax jle 0x43c34 movq -0x10(%rbp), %rax movzbl 0x1(%rax), %ecx movl $0x30, %eax cmpl %ecx, %eax jg 0x43c34 movq -0x10(%rbp), %rax movzbl 0x1(%rax), %eax cmpl $0x39, %eax jg 0x43c34 movq -0x10(%rbp), %rax movzbl 0x2(%rax), %ecx movl $0x81, %eax cmpl %ecx, %eax jg 0x43c34 movq -0x10(%rbp), %rax movzbl 0x2(%rax), %eax cmpl $0xfe, %eax jg 0x43c34 movq -0x10(%rbp), %rax movzbl 0x3(%rax), %ecx movl $0x30, %eax cmpl %ecx, %eax jg 0x43c34 movq -0x10(%rbp), %rax movzbl 0x3(%rax), %eax cmpl $0x39, %eax jg 0x43c34 movl $0x4, -0x4(%rbp) jmp 0x43c3d jmp 0x43c36 movl $0x0, -0x4(%rbp) movl -0x4(%rbp), %eax popq %rbp retq nopw %cs:(%rax,%rax)
check_mb_gb18030_valid: push rbp mov rbp, rsp mov [rbp+var_10], rdi mov [rbp+var_18], rsi mov rax, [rbp+var_18] mov rcx, [rbp+var_10] sub rax, rcx cmp rax, 1 jle short loc_43B6B mov rax, [rbp+var_10] movzx ecx, byte ptr [rax] mov eax, 81h cmp eax, ecx jg short loc_43B6B mov rax, [rbp+var_10] movzx eax, byte ptr [rax] cmp eax, 0FEh jle short loc_43B77 loc_43B6B: mov [rbp+var_4], 0 jmp loc_43C3D loc_43B77: mov rax, [rbp+var_10] movzx ecx, byte ptr [rax+1] mov eax, 40h ; '@' cmp eax, ecx jg short loc_43B95 mov rax, [rbp+var_10] movzx eax, byte ptr [rax+1] cmp eax, 7Eh ; '~' jle short loc_43BB5 loc_43B95: mov rax, [rbp+var_10] movzx ecx, byte ptr [rax+1] mov eax, 80h cmp eax, ecx jg short loc_43BBE mov rax, [rbp+var_10] movzx eax, byte ptr [rax+1] cmp eax, 0FEh jg short loc_43BBE loc_43BB5: mov [rbp+var_4], 2 jmp short loc_43C3D loc_43BBE: mov rax, [rbp+var_18] mov rcx, [rbp+var_10] sub rax, rcx cmp rax, 3 jle short loc_43C34 mov rax, [rbp+var_10] movzx ecx, byte ptr [rax+1] mov eax, 30h ; '0' cmp eax, ecx jg short loc_43C34 mov rax, [rbp+var_10] movzx eax, byte ptr [rax+1] cmp eax, 39h ; '9' jg short loc_43C34 mov rax, [rbp+var_10] movzx ecx, byte ptr [rax+2] mov eax, 81h cmp eax, ecx jg short loc_43C34 mov rax, [rbp+var_10] movzx eax, byte ptr [rax+2] cmp eax, 0FEh jg short loc_43C34 mov rax, [rbp+var_10] movzx ecx, byte ptr [rax+3] mov eax, 30h ; '0' cmp eax, ecx jg short loc_43C34 mov rax, [rbp+var_10] movzx eax, byte ptr [rax+3] cmp eax, 39h ; '9' jg short loc_43C34 mov [rbp+var_4], 4 jmp short loc_43C3D loc_43C34: jmp short $+2 loc_43C36: mov [rbp+var_4], 0 loc_43C3D: mov eax, [rbp+var_4] pop rbp retn
long long check_mb_gb18030_valid(unsigned __int8 *a1, long long a2) { if ( a2 - (long long)a1 <= 1 || *a1 < 0x81u || *a1 == 255 ) { return 0; } else if ( (a1[1] < 0x40u || a1[1] > 0x7Eu) && (a1[1] < 0x80u || a1[1] == 255) ) { if ( a2 - (long long)a1 <= 3 || a1[1] < 0x30u || a1[1] > 0x39u || a1[2] < 0x81u || a1[2] == 255 || a1[3] < 0x30u || a1[3] > 0x39u ) { return 0; } else { return 4; } } else { return 2; } }
check_mb_gb18030_valid: PUSH RBP MOV RBP,RSP MOV qword ptr [RBP + -0x10],RDI MOV qword ptr [RBP + -0x18],RSI MOV RAX,qword ptr [RBP + -0x18] MOV RCX,qword ptr [RBP + -0x10] SUB RAX,RCX CMP RAX,0x1 JLE 0x00143b6b MOV RAX,qword ptr [RBP + -0x10] MOVZX ECX,byte ptr [RAX] MOV EAX,0x81 CMP EAX,ECX JG 0x00143b6b MOV RAX,qword ptr [RBP + -0x10] MOVZX EAX,byte ptr [RAX] CMP EAX,0xfe JLE 0x00143b77 LAB_00143b6b: MOV dword ptr [RBP + -0x4],0x0 JMP 0x00143c3d LAB_00143b77: MOV RAX,qword ptr [RBP + -0x10] MOVZX ECX,byte ptr [RAX + 0x1] MOV EAX,0x40 CMP EAX,ECX JG 0x00143b95 MOV RAX,qword ptr [RBP + -0x10] MOVZX EAX,byte ptr [RAX + 0x1] CMP EAX,0x7e JLE 0x00143bb5 LAB_00143b95: MOV RAX,qword ptr [RBP + -0x10] MOVZX ECX,byte ptr [RAX + 0x1] MOV EAX,0x80 CMP EAX,ECX JG 0x00143bbe MOV RAX,qword ptr [RBP + -0x10] MOVZX EAX,byte ptr [RAX + 0x1] CMP EAX,0xfe JG 0x00143bbe LAB_00143bb5: MOV dword ptr [RBP + -0x4],0x2 JMP 0x00143c3d LAB_00143bbe: MOV RAX,qword ptr [RBP + -0x18] MOV RCX,qword ptr [RBP + -0x10] SUB RAX,RCX CMP RAX,0x3 JLE 0x00143c34 MOV RAX,qword ptr [RBP + -0x10] MOVZX ECX,byte ptr [RAX + 0x1] MOV EAX,0x30 CMP EAX,ECX JG 0x00143c34 MOV RAX,qword ptr [RBP + -0x10] MOVZX EAX,byte ptr [RAX + 0x1] CMP EAX,0x39 JG 0x00143c34 MOV RAX,qword ptr [RBP + -0x10] MOVZX ECX,byte ptr [RAX + 0x2] MOV EAX,0x81 CMP EAX,ECX JG 0x00143c34 MOV RAX,qword ptr [RBP + -0x10] MOVZX EAX,byte ptr [RAX + 0x2] CMP EAX,0xfe JG 0x00143c34 MOV RAX,qword ptr [RBP + -0x10] MOVZX ECX,byte ptr [RAX + 0x3] MOV EAX,0x30 CMP EAX,ECX JG 0x00143c34 MOV RAX,qword ptr [RBP + -0x10] MOVZX EAX,byte ptr [RAX + 0x3] CMP EAX,0x39 JG 0x00143c34 MOV dword ptr [RBP + -0x4],0x4 JMP 0x00143c3d LAB_00143c34: JMP 0x00143c36 LAB_00143c36: MOV dword ptr [RBP + -0x4],0x0 LAB_00143c3d: MOV EAX,dword ptr [RBP + -0x4] POP RBP RET
int4 check_mb_gb18030_valid(byte *param_1,long param_2) { int4 local_c; if (((param_2 - (long)param_1 < 2) || (*param_1 < 0x81)) || (*param_1 == 0xff)) { local_c = 0; } else if (((param_1[1] < 0x40) || (0x7e < param_1[1])) && ((param_1[1] < 0x80 || (param_1[1] == 0xff)))) { if (((param_2 - (long)param_1 < 4) || (param_1[1] < 0x30)) || ((0x39 < param_1[1] || ((((param_1[2] < 0x81 || (0xfe < param_1[2])) || (param_1[3] < 0x30)) || (0x39 < param_1[3]) ))))) { local_c = 0; } else { local_c = 4; } } else { local_c = 2; } return local_c; }
6,098
ma_flush_pending_blocks
eloqsql/storage/maria/ma_check.c
int _ma_flush_pending_blocks(MARIA_SORT_PARAM *sort_param) { uint nod_flag,length; my_off_t filepos; MA_SORT_KEY_BLOCKS *key_block; MARIA_SORT_INFO *sort_info= sort_param->sort_info; myf myf_rw=sort_info->param->myf_rw; MARIA_HA *info=sort_info->info; MARIA_KEYDEF *keyinfo=sort_param->keyinfo; MARIA_PINNED_PAGE tmp_page_link, *page_link= &tmp_page_link; DBUG_ENTER("_ma_flush_pending_blocks"); filepos= HA_OFFSET_ERROR; /* if empty file */ nod_flag=0; for (key_block=sort_info->key_block ; key_block->inited ; key_block++) { key_block->inited=0; length= _ma_get_page_used(info->s, key_block->buff); if (nod_flag) _ma_kpointer(info,key_block->end_pos,filepos); bzero(key_block->buff+length, keyinfo->block_length-length); if ((filepos= _ma_new(info, DFLT_INIT_HITS, &page_link)) == HA_OFFSET_ERROR) goto err; /* If we read the page from the key cache, we have to write it back */ if (page_link->changed) { MARIA_PAGE page; pop_dynamic(&info->pinned_pages); _ma_page_setup(&page, info, keyinfo, filepos, key_block->buff); if (_ma_write_keypage(&page, PAGECACHE_LOCK_WRITE_UNLOCK, DFLT_INIT_HITS)) goto err; } else { if (write_page(info->s, info->s->kfile.file, key_block->buff, keyinfo->block_length, filepos, myf_rw)) goto err; } DBUG_DUMP("buff",key_block->buff,length); nod_flag=1; } info->s->state.key_root[sort_param->key]=filepos; /* Last is root for tree */ _ma_fast_unlock_key_del(info); DBUG_RETURN(0); err: _ma_fast_unlock_key_del(info); DBUG_RETURN(1); }
O0
c
ma_flush_pending_blocks: pushq %rbp movq %rsp, %rbp subq $0xa0, %rsp movq %rdi, -0x10(%rbp) movq -0x10(%rbp), %rax movq 0x380(%rax), %rax movq %rax, -0x30(%rbp) movq -0x30(%rbp), %rax movq 0x90(%rax), %rax movq 0x20998(%rax), %rax movq %rax, -0x38(%rbp) movq -0x30(%rbp), %rax movq 0x80(%rax), %rax movq %rax, -0x40(%rbp) movq -0x10(%rbp), %rax movq 0x378(%rax), %rax movq %rax, -0x48(%rbp) leaq -0x60(%rbp), %rax movq %rax, -0x68(%rbp) movq $-0x1, -0x20(%rbp) movl $0x0, -0x14(%rbp) movq -0x30(%rbp), %rax movq 0xa0(%rax), %rax movq %rax, -0x28(%rbp) movq -0x28(%rbp), %rax cmpl $0x0, 0x934(%rax) je 0x8a413 movq -0x28(%rbp), %rax movl $0x0, 0x934(%rax) movq -0x28(%rbp), %rax movq (%rax), %rax movq -0x40(%rbp), %rcx movq (%rcx), %rcx movl 0x744(%rcx), %ecx movzbl -0x1(%rax,%rcx), %eax movzwl %ax, %eax movq -0x28(%rbp), %rcx movq (%rcx), %rcx movq -0x40(%rbp), %rdx movq (%rdx), %rdx movl 0x744(%rdx), %edx movzbl -0x2(%rcx,%rdx), %ecx movzwl %cx, %ecx shll $0x8, %ecx orl %ecx, %eax movzwl %ax, %eax movl %eax, -0x18(%rbp) cmpl $0x0, -0x14(%rbp) je 0x8a315 movq -0x40(%rbp), %rdi movq -0x28(%rbp), %rax movq 0x8(%rax), %rsi movq -0x20(%rbp), %rdx callq 0x40910 movq -0x28(%rbp), %rax movq (%rax), %rdi movl -0x18(%rbp), %eax addq %rax, %rdi movq -0x48(%rbp), %rax movzwl 0xa6(%rax), %eax subl -0x18(%rbp), %eax movl %eax, %eax movl %eax, %edx xorl %esi, %esi callq 0x2c300 movq -0x40(%rbp), %rdi movl $0x3, %esi leaq -0x68(%rbp), %rdx callq 0x45190 movq %rax, -0x20(%rbp) cmpq $-0x1, %rax jne 0x8a35c jmp 0x8a445 movq -0x68(%rbp), %rax cmpb $0x0, 0x10(%rax) je 0x8a3b6 movq -0x40(%rbp), %rdi addq $0x2e8, %rdi # imm = 0x2E8 callq 0x105050 movq -0x40(%rbp), %rsi movq -0x48(%rbp), %rdx movq -0x20(%rbp), %rcx movq -0x28(%rbp), %rax movq (%rax), %r8 leaq -0xa0(%rbp), %rdi callq 0x448a0 leaq -0xa0(%rbp), %rdi movl $0x6, %esi movl $0x3, %edx callq 0x44bc0 cmpb $0x0, %al je 0x8a3b4 jmp 0x8a445 jmp 0x8a3f5 movq -0x40(%rbp), %rax movq (%rax), %rdi movq -0x40(%rbp), %rax movq (%rax), %rax movl 0x760(%rax), %esi movq -0x28(%rbp), %rax movq (%rax), %rdx movq -0x48(%rbp), %rax movzwl 0xa6(%rax), %ecx movq -0x20(%rbp), %r8 movq -0x38(%rbp), %rax movl %eax, %r9d callq 0x8a470 cmpl $0x0, %eax je 0x8a3f3 jmp 0x8a445 jmp 0x8a3f5 jmp 0x8a3f7 jmp 0x8a3f9 movl $0x1, -0x14(%rbp) movq -0x28(%rbp), %rax addq $0x938, %rax # imm = 0x938 movq %rax, -0x28(%rbp) jmp 0x8a298 movq -0x20(%rbp), %rdx movq -0x40(%rbp), %rax movq (%rax), %rax movq 0x118(%rax), %rax movq -0x10(%rbp), %rcx movl 0x640(%rcx), %ecx movq %rdx, (%rax,%rcx,8) movq -0x40(%rbp), %rdi callq 0x8a510 movl $0x0, -0x4(%rbp) jmp 0x8a455 movq -0x40(%rbp), %rdi callq 0x8a510 movl $0x1, -0x4(%rbp) movl -0x4(%rbp), %eax addq $0xa0, %rsp popq %rbp retq nopw %cs:(%rax,%rax)
_ma_flush_pending_blocks: push rbp mov rbp, rsp sub rsp, 0A0h mov [rbp+var_10], rdi mov rax, [rbp+var_10] mov rax, [rax+380h] mov [rbp+var_30], rax mov rax, [rbp+var_30] mov rax, [rax+90h] mov rax, qword ptr ds:stru_20998.r_offset[rax] mov [rbp+var_38], rax mov rax, [rbp+var_30] mov rax, [rax+80h] mov [rbp+var_40], rax mov rax, [rbp+var_10] mov rax, [rax+378h] mov [rbp+var_48], rax lea rax, [rbp+var_60] mov [rbp+var_68], rax mov [rbp+var_20], 0FFFFFFFFFFFFFFFFh mov [rbp+var_14], 0 mov rax, [rbp+var_30] mov rax, [rax+0A0h] mov [rbp+var_28], rax loc_8A298: mov rax, [rbp+var_28] cmp dword ptr [rax+934h], 0 jz loc_8A413 mov rax, [rbp+var_28] mov dword ptr [rax+934h], 0 mov rax, [rbp+var_28] mov rax, [rax] mov rcx, [rbp+var_40] mov rcx, [rcx] mov ecx, [rcx+744h] movzx eax, byte ptr [rax+rcx-1] movzx eax, ax mov rcx, [rbp+var_28] mov rcx, [rcx] mov rdx, [rbp+var_40] mov rdx, [rdx] mov edx, [rdx+744h] movzx ecx, byte ptr [rcx+rdx-2] movzx ecx, cx shl ecx, 8 or eax, ecx movzx eax, ax mov [rbp+var_18], eax cmp [rbp+var_14], 0 jz short loc_8A315 mov rdi, [rbp+var_40] mov rax, [rbp+var_28] mov rsi, [rax+8] mov rdx, [rbp+var_20] call _ma_kpointer loc_8A315: mov rax, [rbp+var_28] mov rdi, [rax] mov eax, [rbp+var_18] add rdi, rax mov rax, [rbp+var_48] movzx eax, word ptr [rax+0A6h] sub eax, [rbp+var_18] mov eax, eax mov edx, eax xor esi, esi call _memset mov rdi, [rbp+var_40] mov esi, 3 lea rdx, [rbp+var_68] call _ma_new mov [rbp+var_20], rax cmp rax, 0FFFFFFFFFFFFFFFFh jnz short loc_8A35C jmp loc_8A445 loc_8A35C: mov rax, [rbp+var_68] cmp byte ptr [rax+10h], 0 jz short loc_8A3B6 mov rdi, [rbp+var_40] add rdi, 2E8h call pop_dynamic mov rsi, [rbp+var_40] mov rdx, [rbp+var_48] mov rcx, [rbp+var_20] mov rax, [rbp+var_28] mov r8, [rax] lea rdi, [rbp+var_A0] call _ma_page_setup lea rdi, [rbp+var_A0] mov esi, 6 mov edx, 3 call _ma_write_keypage cmp al, 0 jz short loc_8A3B4 jmp loc_8A445 loc_8A3B4: jmp short loc_8A3F5 loc_8A3B6: mov rax, [rbp+var_40] mov rdi, [rax] mov rax, [rbp+var_40] mov rax, [rax] mov esi, [rax+760h] mov rax, [rbp+var_28] mov rdx, [rax] mov rax, [rbp+var_48] movzx ecx, word ptr [rax+0A6h] mov r8, [rbp+var_20] mov rax, [rbp+var_38] mov r9d, eax call write_page cmp eax, 0 jz short loc_8A3F3 jmp short loc_8A445 loc_8A3F3: jmp short $+2 loc_8A3F5: jmp short $+2 loc_8A3F7: jmp short $+2 loc_8A3F9: mov [rbp+var_14], 1 mov rax, [rbp+var_28] add rax, 938h mov [rbp+var_28], rax jmp loc_8A298 loc_8A413: mov rdx, [rbp+var_20] mov rax, [rbp+var_40] mov rax, [rax] mov rax, [rax+118h] mov rcx, [rbp+var_10] mov ecx, [rcx+640h] mov [rax+rcx*8], rdx mov rdi, [rbp+var_40] call _ma_fast_unlock_key_del_2 mov [rbp+var_4], 0 jmp short loc_8A455 loc_8A445: mov rdi, [rbp+var_40] call _ma_fast_unlock_key_del_2 mov [rbp+var_4], 1 loc_8A455: mov eax, [rbp+var_4] add rsp, 0A0h pop rbp retn
long long ma_flush_pending_blocks(long long a1) { long long *v2[7]; // [rsp+0h] [rbp-A0h] BYREF char *v3; // [rsp+38h] [rbp-68h] BYREF char v4; // [rsp+40h] [rbp-60h] BYREF long long v5; // [rsp+58h] [rbp-48h] long long *v6; // [rsp+60h] [rbp-40h] long long v7; // [rsp+68h] [rbp-38h] _QWORD *v8; // [rsp+70h] [rbp-30h] _QWORD *i; // [rsp+78h] [rbp-28h] long long v10; // [rsp+80h] [rbp-20h] unsigned int v11; // [rsp+88h] [rbp-18h] int v12; // [rsp+8Ch] [rbp-14h] long long v13; // [rsp+90h] [rbp-10h] v13 = a1; v8 = *(_QWORD **)(a1 + 896); v7 = *(unsigned long long *)((char *)&stru_20998.r_offset + v8[18]); v6 = (long long *)v8[16]; v5 = *(_QWORD *)(a1 + 888); v3 = &v4; v10 = -1LL; v12 = 0; for ( i = (_QWORD *)v8[20]; ; i += 295 ) { if ( !*((_DWORD *)i + 589) ) { *(_QWORD *)(*(_QWORD *)(*v6 + 280) + 8LL * *(unsigned int *)(v13 + 1600)) = v10; ma_fast_unlock_key_del_2(v6); return 0; } *((_DWORD *)i + 589) = 0; v11 = _byteswap_ushort(*(_WORD *)(*i + *(unsigned int *)(*v6 + 1860) - 2LL)); if ( v12 ) ma_kpointer((long long)v6, (_BYTE *)i[1], v10); memset(v11 + *i, 0LL, *(unsigned __int16 *)(v5 + 166) - v11); v10 = ma_new(v6, 3, (long long *)&v3); if ( v10 == -1 ) break; if ( v3[16] ) { pop_dynamic(v6 + 93); ma_page_setup((long long)v2, v6, v5, v10, *i); if ( ma_write_keypage(v2, 6, 3) ) break; } else if ( (unsigned int)write_page( *v6, *(unsigned int *)(*v6 + 1888), *i, *(unsigned __int16 *)(v5 + 166), v10, (unsigned int)v7) ) { break; } v12 = 1; } ma_fast_unlock_key_del_2(v6); return 1; }
_ma_flush_pending_blocks: PUSH RBP MOV RBP,RSP SUB RSP,0xa0 MOV qword ptr [RBP + -0x10],RDI MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x380] MOV qword ptr [RBP + -0x30],RAX MOV RAX,qword ptr [RBP + -0x30] MOV RAX,qword ptr [RAX + 0x90] MOV RAX,qword ptr [RAX + 0x20998] MOV qword ptr [RBP + -0x38],RAX MOV RAX,qword ptr [RBP + -0x30] MOV RAX,qword ptr [RAX + 0x80] MOV qword ptr [RBP + -0x40],RAX MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x378] MOV qword ptr [RBP + -0x48],RAX LEA RAX,[RBP + -0x60] MOV qword ptr [RBP + -0x68],RAX MOV qword ptr [RBP + -0x20],-0x1 MOV dword ptr [RBP + -0x14],0x0 MOV RAX,qword ptr [RBP + -0x30] MOV RAX,qword ptr [RAX + 0xa0] MOV qword ptr [RBP + -0x28],RAX LAB_0018a298: MOV RAX,qword ptr [RBP + -0x28] CMP dword ptr [RAX + 0x934],0x0 JZ 0x0018a413 MOV RAX,qword ptr [RBP + -0x28] MOV dword ptr [RAX + 0x934],0x0 MOV RAX,qword ptr [RBP + -0x28] MOV RAX,qword ptr [RAX] MOV RCX,qword ptr [RBP + -0x40] MOV RCX,qword ptr [RCX] MOV ECX,dword ptr [RCX + 0x744] MOVZX EAX,byte ptr [RAX + RCX*0x1 + -0x1] MOVZX EAX,AX MOV RCX,qword ptr [RBP + -0x28] MOV RCX,qword ptr [RCX] MOV RDX,qword ptr [RBP + -0x40] MOV RDX,qword ptr [RDX] MOV EDX,dword ptr [RDX + 0x744] MOVZX ECX,byte ptr [RCX + RDX*0x1 + -0x2] MOVZX ECX,CX SHL ECX,0x8 OR EAX,ECX MOVZX EAX,AX MOV dword ptr [RBP + -0x18],EAX CMP dword ptr [RBP + -0x14],0x0 JZ 0x0018a315 MOV RDI,qword ptr [RBP + -0x40] MOV RAX,qword ptr [RBP + -0x28] MOV RSI,qword ptr [RAX + 0x8] MOV RDX,qword ptr [RBP + -0x20] CALL 0x00140910 LAB_0018a315: MOV RAX,qword ptr [RBP + -0x28] MOV RDI,qword ptr [RAX] MOV EAX,dword ptr [RBP + -0x18] ADD RDI,RAX MOV RAX,qword ptr [RBP + -0x48] MOVZX EAX,word ptr [RAX + 0xa6] SUB EAX,dword ptr [RBP + -0x18] MOV EAX,EAX MOV EDX,EAX XOR ESI,ESI CALL 0x0012c300 MOV RDI,qword ptr [RBP + -0x40] MOV ESI,0x3 LEA RDX,[RBP + -0x68] CALL 0x00145190 MOV qword ptr [RBP + -0x20],RAX CMP RAX,-0x1 JNZ 0x0018a35c JMP 0x0018a445 LAB_0018a35c: MOV RAX,qword ptr [RBP + -0x68] CMP byte ptr [RAX + 0x10],0x0 JZ 0x0018a3b6 MOV RDI,qword ptr [RBP + -0x40] ADD RDI,0x2e8 CALL 0x00205050 MOV RSI,qword ptr [RBP + -0x40] MOV RDX,qword ptr [RBP + -0x48] MOV RCX,qword ptr [RBP + -0x20] MOV RAX,qword ptr [RBP + -0x28] MOV R8,qword ptr [RAX] LEA RDI,[RBP + -0xa0] CALL 0x001448a0 LEA RDI,[RBP + -0xa0] MOV ESI,0x6 MOV EDX,0x3 CALL 0x00144bc0 CMP AL,0x0 JZ 0x0018a3b4 JMP 0x0018a445 LAB_0018a3b4: JMP 0x0018a3f5 LAB_0018a3b6: MOV RAX,qword ptr [RBP + -0x40] MOV RDI,qword ptr [RAX] MOV RAX,qword ptr [RBP + -0x40] MOV RAX,qword ptr [RAX] MOV ESI,dword ptr [RAX + 0x760] MOV RAX,qword ptr [RBP + -0x28] MOV RDX,qword ptr [RAX] MOV RAX,qword ptr [RBP + -0x48] MOVZX ECX,word ptr [RAX + 0xa6] MOV R8,qword ptr [RBP + -0x20] MOV RAX,qword ptr [RBP + -0x38] MOV R9D,EAX CALL 0x0018a470 CMP EAX,0x0 JZ 0x0018a3f3 JMP 0x0018a445 LAB_0018a3f3: JMP 0x0018a3f5 LAB_0018a3f5: JMP 0x0018a3f7 LAB_0018a3f7: JMP 0x0018a3f9 LAB_0018a3f9: MOV dword ptr [RBP + -0x14],0x1 MOV RAX,qword ptr [RBP + -0x28] ADD RAX,0x938 MOV qword ptr [RBP + -0x28],RAX JMP 0x0018a298 LAB_0018a413: MOV RDX,qword ptr [RBP + -0x20] MOV RAX,qword ptr [RBP + -0x40] MOV RAX,qword ptr [RAX] MOV RAX,qword ptr [RAX + 0x118] MOV RCX,qword ptr [RBP + -0x10] MOV ECX,dword ptr [RCX + 0x640] MOV qword ptr [RAX + RCX*0x8],RDX MOV RDI,qword ptr [RBP + -0x40] CALL 0x0018a510 MOV dword ptr [RBP + -0x4],0x0 JMP 0x0018a455 LAB_0018a445: MOV RDI,qword ptr [RBP + -0x40] CALL 0x0018a510 MOV dword ptr [RBP + -0x4],0x1 LAB_0018a455: MOV EAX,dword ptr [RBP + -0x4] ADD RSP,0xa0 POP RBP RET
int4 _ma_flush_pending_blocks(long param_1) { char cVar1; int iVar2; int1 local_a8 [56]; int1 *local_70; int1 local_68 [24]; long local_50; long *local_48; ulong local_40; long local_38; long *local_30; long local_28; uint local_20; int local_1c; long local_18; local_38 = *(long *)(param_1 + 0x380); local_40 = *(ulong *)(*(long *)(local_38 + 0x90) + 0x20998); local_48 = *(long **)(local_38 + 0x80); local_50 = *(long *)(param_1 + 0x378); local_70 = local_68; local_28 = -1; local_1c = 0; local_30 = *(long **)(local_38 + 0xa0); local_18 = param_1; while( true ) { if (*(int *)((long)local_30 + 0x934) == 0) { *(long *)(*(long *)(*local_48 + 0x118) + (ulong)*(uint *)(local_18 + 0x640) * 8) = local_28; _ma_fast_unlock_key_del(local_48); return 0; } *(int4 *)((long)local_30 + 0x934) = 0; local_20 = (uint)CONCAT11(*(int1 *)(*local_30 + -2 + (ulong)*(uint *)(*local_48 + 0x744)), *(int1 *)(*local_30 + -1 + (ulong)*(uint *)(*local_48 + 0x744))) ; if (local_1c != 0) { _ma_kpointer(local_48,local_30[1],local_28); } memset((void *)(*local_30 + (ulong)local_20),0,(ulong)(*(ushort *)(local_50 + 0xa6) - local_20)) ; local_28 = _ma_new(local_48,3,&local_70); if (local_28 == -1) break; if (local_70[0x10] == '\0') { iVar2 = write_page(*local_48,*(int4 *)(*local_48 + 0x760),*local_30, *(int2 *)(local_50 + 0xa6),local_28,local_40 & 0xffffffff); if (iVar2 != 0) break; } else { pop_dynamic(local_48 + 0x5d); _ma_page_setup(local_a8,local_48,local_50,local_28,*local_30); cVar1 = _ma_write_keypage(local_a8,6,3); if (cVar1 != '\0') break; } local_1c = 1; local_30 = local_30 + 0x127; } _ma_fast_unlock_key_del(local_48); return 1; }
6,099
free_block
eloqsql/mysys/mf_keycache.c
static void free_block(SIMPLE_KEY_CACHE_CB *keycache, BLOCK_LINK *block) { KEYCACHE_THREAD_TRACE("free block"); KEYCACHE_DBUG_PRINT("free_block", ("block %u to be freed, hash_link %p status: %u", BLOCK_NUMBER(block), block->hash_link, block->status)); /* Assert that the block is not free already. And that it is in a clean state. Note that the block might just be assigned to a hash_link and not yet read (BLOCK_READ may not be set here). In this case a reader is registered in the hash_link and free_block() will wait for it below. */ DBUG_ASSERT((block->status & BLOCK_IN_USE) && !(block->status & (BLOCK_IN_EVICTION | BLOCK_IN_SWITCH | BLOCK_REASSIGNED | BLOCK_IN_FLUSH | BLOCK_CHANGED | BLOCK_FOR_UPDATE))); /* Assert that the block is in a file_blocks chain. */ DBUG_ASSERT(block->prev_changed && *block->prev_changed == block); /* Assert that the block is not in the LRU ring. */ DBUG_ASSERT(!block->next_used && !block->prev_used); /* IMHO the below condition (if()) makes no sense. I can't see how it could be possible that free_block() is entered with a NULL hash_link pointer. The only place where it can become NULL is in free_block() (or before its first use ever, but for those blocks free_block() is not called). I don't remove the conditional as it cannot harm, but place an DBUG_ASSERT to confirm my hypothesis. Eventually the condition (if()) can be removed. */ DBUG_ASSERT(block->hash_link && block->hash_link->block == block); if (block->hash_link) { /* While waiting for readers to finish, new readers might request the block. But since we set block->status|= BLOCK_REASSIGNED, they will wait on block->wqueue[COND_FOR_SAVED]. They must be signalled later. */ block->status|= BLOCK_REASSIGNED; wait_for_readers(keycache, block); /* The block must not have been freed by another thread. Repeat some checks. An additional requirement is that it must be read now (BLOCK_READ). */ DBUG_ASSERT(block->hash_link && block->hash_link->block == block); DBUG_ASSERT((block->status & (BLOCK_READ | BLOCK_IN_USE | BLOCK_REASSIGNED)) && !(block->status & (BLOCK_IN_EVICTION | BLOCK_IN_SWITCH | BLOCK_IN_FLUSH | BLOCK_CHANGED | BLOCK_FOR_UPDATE))); DBUG_ASSERT(block->prev_changed && *block->prev_changed == block); DBUG_ASSERT(!block->prev_used); /* Unset BLOCK_REASSIGNED again. If we hand the block to an evicting thread (through unreg_request() below), other threads must not see this flag. They could become confused. */ block->status&= ~BLOCK_REASSIGNED; /* Do not release the hash_link until the block is off all lists. At least not if we hand it over for eviction in unreg_request(). */ } /* Unregister the block request and link the block into the LRU ring. This enables eviction for the block. If the LRU ring was empty and threads are waiting for a block, then the block wil be handed over for eviction immediately. Otherwise we will unlink it from the LRU ring again, without releasing the lock in between. So decrementing the request counter and updating statistics are the only relevant operation in this case. Assert that there are no other requests registered. */ DBUG_ASSERT(block->requests == 1); unreg_request(keycache, block, 0); /* Note that even without releasing the cache lock it is possible that the block is immediately selected for eviction by link_block() and thus not added to the LRU ring. In this case we must not touch the block any more. */ if (block->status & BLOCK_IN_EVICTION) return; /* Error blocks are not put into the LRU ring. */ if (!(block->status & BLOCK_ERROR)) { /* Here the block must be in the LRU ring. Unlink it again. */ DBUG_ASSERT(block->next_used && block->prev_used && *block->prev_used == block); unlink_block(keycache, block); } if (block->temperature == BLOCK_WARM) keycache->warm_blocks--; block->temperature= BLOCK_COLD; /* Remove from file_blocks hash. */ unlink_changed(block); /* Remove reference to block from hash table. */ unlink_hash(keycache, block->hash_link); block->hash_link= NULL; block->status= 0; block->length= 0; block->offset= keycache->key_cache_block_size; KEYCACHE_THREAD_TRACE("free block"); KEYCACHE_DBUG_PRINT("free_block", ("block is freed")); /* Enforced by unlink_changed(), but just to be sure. */ DBUG_ASSERT(!block->next_changed && !block->prev_changed); /* Enforced by unlink_block(): not in LRU ring nor in free_block_list. */ DBUG_ASSERT(!block->next_used && !block->prev_used); /* Insert the free block in the free list. */ block->next_used= keycache->free_block_list; keycache->free_block_list= block; /* Keep track of the number of currently unused blocks. */ keycache->blocks_unused++; /* All pending requests for this page must be resubmitted. */ release_whole_queue(&block->wqueue[COND_FOR_SAVED]); }
O3
c
free_block: pushq %rbp movq %rsp, %rbp pushq %r14 pushq %rbx movq %rsi, %rbx movq %rdi, %r14 cmpq $0x0, 0x20(%rsi) je 0x9a0f3 orb $0x8, 0x50(%rbx) movq %r14, %rdi movq %rbx, %rsi callq 0x9a94b andb $-0x9, 0x50(%rbx) movq %r14, %rdi movq %rbx, %rsi xorl %edx, %edx callq 0x99fc4 movl 0x50(%rbx), %eax testb %al, %al js 0x9a13e testb $0x1, %al jne 0x9a116 movq %r14, %rdi movq %rbx, %rsi callq 0x9a9d4 cmpl $0x1, 0x54(%rbx) jne 0x9a120 decq 0x68(%r14) movl $0x0, 0x54(%rbx) movq 0x10(%rbx), %rcx movq 0x18(%rbx), %rax testq %rcx, %rcx je 0x9a143 movq %rax, 0x18(%rcx) movq 0x10(%rbx), %rcx jmp 0x9a145 popq %rbx popq %r14 popq %rbp retq xorl %ecx, %ecx movq %rcx, (%rax) movq 0x20(%rbx), %rsi movq %r14, %rdi callq 0x9a6e9 xorl %eax, %eax movq %rax, 0x20(%rbx) movq %rax, 0x4c(%rbx) movl 0x18(%r14), %eax movl %eax, 0x48(%rbx) movq 0x98(%r14), %rax movq %rax, (%rbx) movq %rbx, 0x98(%r14) incq 0x58(%r14) addq $0x30, %rbx movq %rbx, %rdi popq %rbx popq %r14 popq %rbp jmp 0x9a8d1
free_block_0: push rbp mov rbp, rsp push r14 push rbx mov rbx, rsi mov r14, rdi cmp qword ptr [rsi+20h], 0 jz short loc_9A0F3 or byte ptr [rbx+50h], 8 mov rdi, r14 mov rsi, rbx call wait_for_readers_0 and byte ptr [rbx+50h], 0F7h loc_9A0F3: mov rdi, r14 mov rsi, rbx xor edx, edx call unreg_request_0 mov eax, [rbx+50h] test al, al js short loc_9A13E test al, 1 jnz short loc_9A116 mov rdi, r14 mov rsi, rbx call unlink_block_0 loc_9A116: cmp dword ptr [rbx+54h], 1 jnz short loc_9A120 dec qword ptr [r14+68h] loc_9A120: mov dword ptr [rbx+54h], 0 mov rcx, [rbx+10h] mov rax, [rbx+18h] test rcx, rcx jz short loc_9A143 mov [rcx+18h], rax mov rcx, [rbx+10h] jmp short loc_9A145 loc_9A13E: pop rbx pop r14 pop rbp retn loc_9A143: xor ecx, ecx loc_9A145: mov [rax], rcx mov rsi, [rbx+20h] mov rdi, r14 call unlink_hash_0 xor eax, eax mov [rbx+20h], rax mov [rbx+4Ch], rax mov eax, [r14+18h] mov [rbx+48h], eax mov rax, [r14+98h] mov [rbx], rax mov [r14+98h], rbx inc qword ptr [r14+58h] add rbx, 30h ; '0' mov rdi, rbx pop rbx pop r14 pop rbp jmp release_whole_queue
long long free_block_0(long long a1, long long a2) { long long v2; // rdx long long result; // rax long long v4; // rcx _QWORD *v5; // rax long long v6; // rcx if ( *(_QWORD *)(a2 + 32) ) { *(_BYTE *)(a2 + 80) |= 8u; wait_for_readers_0(a1, a2); *(_BYTE *)(a2 + 80) &= ~8u; } unreg_request_0((_QWORD *)a1, a2, 0LL); result = *(unsigned int *)(a2 + 80); if ( (result & 0x80u) == 0LL ) { if ( (result & 1) == 0 ) unlink_block_0(a1, a2, v2); if ( *(_DWORD *)(a2 + 84) == 1 ) --*(_QWORD *)(a1 + 104); *(_DWORD *)(a2 + 84) = 0; v4 = *(_QWORD *)(a2 + 16); v5 = *(_QWORD **)(a2 + 24); if ( v4 ) { *(_QWORD *)(v4 + 24) = v5; v6 = *(_QWORD *)(a2 + 16); } else { v6 = 0LL; } *v5 = v6; unlink_hash_0(a1, *(_QWORD *)(a2 + 32)); *(_QWORD *)(a2 + 32) = 0LL; *(_QWORD *)(a2 + 76) = 0LL; *(_DWORD *)(a2 + 72) = *(_DWORD *)(a1 + 24); *(_QWORD *)a2 = *(_QWORD *)(a1 + 152); *(_QWORD *)(a1 + 152) = a2; ++*(_QWORD *)(a1 + 88); return release_whole_queue(a2 + 48); } return result; }
free_block: PUSH RBP MOV RBP,RSP PUSH R14 PUSH RBX MOV RBX,RSI MOV R14,RDI CMP qword ptr [RSI + 0x20],0x0 JZ 0x0019a0f3 OR byte ptr [RBX + 0x50],0x8 MOV RDI,R14 MOV RSI,RBX CALL 0x0019a94b AND byte ptr [RBX + 0x50],0xf7 LAB_0019a0f3: MOV RDI,R14 MOV RSI,RBX XOR EDX,EDX CALL 0x00199fc4 MOV EAX,dword ptr [RBX + 0x50] TEST AL,AL JS 0x0019a13e TEST AL,0x1 JNZ 0x0019a116 MOV RDI,R14 MOV RSI,RBX CALL 0x0019a9d4 LAB_0019a116: CMP dword ptr [RBX + 0x54],0x1 JNZ 0x0019a120 DEC qword ptr [R14 + 0x68] LAB_0019a120: MOV dword ptr [RBX + 0x54],0x0 MOV RCX,qword ptr [RBX + 0x10] MOV RAX,qword ptr [RBX + 0x18] TEST RCX,RCX JZ 0x0019a143 MOV qword ptr [RCX + 0x18],RAX MOV RCX,qword ptr [RBX + 0x10] JMP 0x0019a145 LAB_0019a13e: POP RBX POP R14 POP RBP RET LAB_0019a143: XOR ECX,ECX LAB_0019a145: MOV qword ptr [RAX],RCX MOV RSI,qword ptr [RBX + 0x20] MOV RDI,R14 CALL 0x0019a6e9 XOR EAX,EAX MOV qword ptr [RBX + 0x20],RAX MOV qword ptr [RBX + 0x4c],RAX MOV EAX,dword ptr [R14 + 0x18] MOV dword ptr [RBX + 0x48],EAX MOV RAX,qword ptr [R14 + 0x98] MOV qword ptr [RBX],RAX MOV qword ptr [R14 + 0x98],RBX INC qword ptr [R14 + 0x58] ADD RBX,0x30 MOV RDI,RBX POP RBX POP R14 POP RBP JMP 0x0019a8d1
void free_block(long param_1,int8 *param_2) { int8 *puVar1; int8 uVar2; if (param_2[4] != 0) { *(byte *)(param_2 + 10) = *(byte *)(param_2 + 10) | 8; wait_for_readers(param_1,param_2); *(byte *)(param_2 + 10) = *(byte *)(param_2 + 10) & 0xf7; } unreg_request(param_1,param_2,0); if (-1 < (char)*(uint *)(param_2 + 10)) { if ((*(uint *)(param_2 + 10) & 1) == 0) { unlink_block(param_1,param_2); } if (*(int *)((long)param_2 + 0x54) == 1) { *(long *)(param_1 + 0x68) = *(long *)(param_1 + 0x68) + -1; } *(int4 *)((long)param_2 + 0x54) = 0; puVar1 = (int8 *)param_2[3]; if (param_2[2] == 0) { uVar2 = 0; } else { *(int8 **)(param_2[2] + 0x18) = puVar1; uVar2 = param_2[2]; } *puVar1 = uVar2; unlink_hash(param_1,param_2[4]); param_2[4] = 0; *(int8 *)((long)param_2 + 0x4c) = 0; *(int4 *)(param_2 + 9) = *(int4 *)(param_1 + 0x18); *param_2 = *(int8 *)(param_1 + 0x98); *(int8 **)(param_1 + 0x98) = param_2; *(long *)(param_1 + 0x58) = *(long *)(param_1 + 0x58) + 1; release_whole_queue(param_2 + 6); return; } return; }