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
20,500
ma_search_first
eloqsql/storage/maria/ma_search.c
int _ma_search_first(MARIA_HA *info, MARIA_KEYDEF *keyinfo, my_off_t pos) { uchar *first_pos; MARIA_PAGE page; MARIA_SHARE *share= info->s; DBUG_ENTER("_ma_search_first"); if (pos == HA_OFFSET_ERROR) { my_errno=HA_ERR_KEY_NOT_FOUND; info->cur_row.lastpos= HA_OFFSET_ERROR; DBUG_RETURN(-1); } do { if (_ma_fetch_keypage(&page, info, keyinfo, pos, PAGECACHE_LOCK_LEFT_UNLOCKED, DFLT_INIT_HITS, info->keyread_buff, 0)) { info->cur_row.lastpos= HA_OFFSET_ERROR; DBUG_RETURN(-1); } first_pos= page.buff + share->keypage_header + page.node; } while ((pos= _ma_kpos(page.node, first_pos)) != HA_OFFSET_ERROR); if (!(*keyinfo->get_key)(&info->last_key, page.flag, page.node, &first_pos)) DBUG_RETURN(-1); /* Crashed */ info->int_keypos= first_pos; info->int_maxpos= (page.buff + page.size -1); info->int_nod_flag= page.node; info->int_keytree_version= keyinfo->version; info->last_search_keypage= info->last_keypage; info->page_changed=info->keyread_buff_used=0; info->cur_row.lastpos= _ma_row_pos_from_key(&info->last_key); info->cur_row.trid= _ma_trid_from_key(&info->last_key); DBUG_PRINT("exit",("found key at %lu", (ulong) info->cur_row.lastpos)); DBUG_RETURN(0); }
O3
c
ma_search_first: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x48, %rsp movq %rdi, %rbx cmpq $-0x1, %rdx je 0x57df6 movq %rdx, %rax movq %rsi, %r14 movq (%rbx), %r13 leaq -0x68(%rbp), %r15 movq %r15, %rdi movq %rbx, %rsi movq %r14, %rdx movq %rax, %rcx xorl %r8d, %r8d movl $0x3, %r9d pushq $0x0 pushq 0x380(%rbx) callq 0x58aca addq $0x10, %rsp testb %al, %al jne 0x57e01 movl 0x744(%r13), %esi addq -0x58(%rbp), %rsi movl -0x40(%rbp), %r12d addq %r12, %rsi movq %rsi, -0x30(%rbp) movl %r12d, %edi callq 0x56adb cmpq $-0x1, %rax jne 0x57d12 leaq 0x200(%rbx), %r15 movl -0x3c(%rbp), %esi leaq -0x30(%rbp), %rcx movq %r15, %rdi movl %r12d, %edx callq *0xe0(%r14) testl %eax, %eax je 0x57e25 movq -0x30(%rbp), %rax movq %rax, 0x3b0(%rbx) movq -0x58(%rbp), %rax movl -0x48(%rbp), %ecx addq %rcx, %rax decq %rax movq %rax, 0x3b8(%rbx) movl -0x40(%rbp), %eax movl %eax, 0x3d0(%rbx) movl 0xb8(%r14), %eax movl %eax, 0x3d4(%rbx) movq 0x440(%rbx), %rax movq %rax, 0x448(%rbx) movw $0x0, 0x684(%rbx) movq %r15, %rdi callq 0x56c40 movq %rax, 0x98(%rbx) movq %r15, %rdi callq 0x56cf8 movq %rax, %rcx xorl %eax, %eax movl $0xc0, %edx jmp 0x57e12 callq 0xa16ee movl $0x78, (%rax) movl $0xffffffff, %eax # imm = 0xFFFFFFFF movq $-0x1, %rcx movl $0x98, %edx movq %rcx, (%rbx,%rdx) addq $0x48, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq movl $0xffffffff, %eax # imm = 0xFFFFFFFF jmp 0x57e16
_ma_search_first: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx sub rsp, 48h mov rbx, rdi cmp rdx, 0FFFFFFFFFFFFFFFFh jz loc_57DF6 mov rax, rdx mov r14, rsi mov r13, [rbx] lea r15, [rbp+var_68] loc_57D12: mov rdi, r15 mov rsi, rbx mov rdx, r14 mov rcx, rax xor r8d, r8d mov r9d, 3 push 0 push qword ptr [rbx+380h] call _ma_fetch_keypage add rsp, 10h test al, al jnz loc_57E01 mov esi, [r13+744h] add rsi, [rbp+var_58] mov r12d, [rbp+var_40] add rsi, r12 mov [rbp+var_30], rsi mov edi, r12d call _ma_kpos cmp rax, 0FFFFFFFFFFFFFFFFh jnz short loc_57D12 lea r15, [rbx+200h] mov esi, [rbp+var_3C] lea rcx, [rbp+var_30] mov rdi, r15 mov edx, r12d call qword ptr [r14+0E0h] test eax, eax jz loc_57E25 mov rax, [rbp+var_30] mov [rbx+3B0h], rax mov rax, [rbp+var_58] mov ecx, [rbp+var_48] add rax, rcx dec rax mov [rbx+3B8h], rax mov eax, [rbp+var_40] mov [rbx+3D0h], eax mov eax, [r14+0B8h] mov [rbx+3D4h], eax mov rax, [rbx+440h] mov [rbx+448h], rax mov word ptr [rbx+684h], 0 mov rdi, r15 call _ma_row_pos_from_key mov [rbx+98h], rax mov rdi, r15 call _ma_trid_from_key mov rcx, rax xor eax, eax mov edx, 0C0h jmp short loc_57E12 loc_57DF6: call _my_thread_var mov dword ptr [rax], 78h ; 'x' loc_57E01: mov eax, 0FFFFFFFFh mov rcx, 0FFFFFFFFFFFFFFFFh mov edx, 98h loc_57E12: mov [rbx+rdx], rcx loc_57E16: add rsp, 48h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn loc_57E25: mov eax, 0FFFFFFFFh jmp short loc_57E16
long long ma_search_first(long long *a1, long long a2, long long a3) { long long v3; // rax long long v4; // r13 unsigned int v5; // r12d unsigned long long v6; // rcx long long result; // rax long long v8; // rdx char v9; // [rsp+8h] [rbp-68h] BYREF long long v10; // [rsp+18h] [rbp-58h] unsigned int v11; // [rsp+28h] [rbp-48h] unsigned int v12; // [rsp+30h] [rbp-40h] unsigned int v13; // [rsp+34h] [rbp-3Ch] long long v14[6]; // [rsp+40h] [rbp-30h] BYREF if ( a3 == -1 ) { *(_DWORD *)my_thread_var(a1, (const char *)a2) = 120; } else { LODWORD(v3) = a3; v4 = *a1; while ( !(unsigned __int8)ma_fetch_keypage((unsigned int)&v9, (_DWORD)a1, a2, v3, 0, 3, a1[112]) ) { v5 = v12; v14[0] = v12 + v10 + *(unsigned int *)(v4 + 1860); v3 = ma_kpos(v12, v14[0]); if ( v3 == -1 ) { if ( (*(unsigned int ( **)(long long *, _QWORD, _QWORD, long long *))(a2 + 224))(a1 + 64, v13, v5, v14) ) { a1[118] = v14[0]; a1[119] = v11 + v10 - 1; *((_DWORD *)a1 + 244) = v12; *((_DWORD *)a1 + 245) = *(_DWORD *)(a2 + 184); a1[137] = a1[136]; *((_WORD *)a1 + 834) = 0; a1[19] = ma_row_pos_from_key(a1 + 64); v6 = ma_trid_from_key((long long)(a1 + 64)); result = 0LL; v8 = 24LL; goto LABEL_9; } return 0xFFFFFFFFLL; } } } result = 0xFFFFFFFFLL; v6 = -1LL; v8 = 19LL; LABEL_9: a1[v8] = v6; return result; }
_ma_search_first: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x48 MOV RBX,RDI CMP RDX,-0x1 JZ 0x00157df6 MOV RAX,RDX MOV R14,RSI MOV R13,qword ptr [RBX] LEA R15,[RBP + -0x68] LAB_00157d12: MOV RDI,R15 MOV RSI,RBX MOV RDX,R14 MOV RCX,RAX XOR R8D,R8D MOV R9D,0x3 PUSH 0x0 PUSH qword ptr [RBX + 0x380] CALL 0x00158aca ADD RSP,0x10 TEST AL,AL JNZ 0x00157e01 MOV ESI,dword ptr [R13 + 0x744] ADD RSI,qword ptr [RBP + -0x58] MOV R12D,dword ptr [RBP + -0x40] ADD RSI,R12 MOV qword ptr [RBP + -0x30],RSI MOV EDI,R12D CALL 0x00156adb CMP RAX,-0x1 JNZ 0x00157d12 LEA R15,[RBX + 0x200] MOV ESI,dword ptr [RBP + -0x3c] LEA RCX,[RBP + -0x30] MOV RDI,R15 MOV EDX,R12D CALL qword ptr [R14 + 0xe0] TEST EAX,EAX JZ 0x00157e25 MOV RAX,qword ptr [RBP + -0x30] MOV qword ptr [RBX + 0x3b0],RAX MOV RAX,qword ptr [RBP + -0x58] MOV ECX,dword ptr [RBP + -0x48] ADD RAX,RCX DEC RAX MOV qword ptr [RBX + 0x3b8],RAX MOV EAX,dword ptr [RBP + -0x40] MOV dword ptr [RBX + 0x3d0],EAX MOV EAX,dword ptr [R14 + 0xb8] MOV dword ptr [RBX + 0x3d4],EAX MOV RAX,qword ptr [RBX + 0x440] MOV qword ptr [RBX + 0x448],RAX MOV word ptr [RBX + 0x684],0x0 MOV RDI,R15 CALL 0x00156c40 MOV qword ptr [RBX + 0x98],RAX MOV RDI,R15 CALL 0x00156cf8 MOV RCX,RAX XOR EAX,EAX MOV EDX,0xc0 JMP 0x00157e12 LAB_00157df6: CALL 0x001a16ee MOV dword ptr [RAX],0x78 LAB_00157e01: MOV EAX,0xffffffff MOV RCX,-0x1 MOV EDX,0x98 LAB_00157e12: MOV qword ptr [RBX + RDX*0x1],RCX LAB_00157e16: ADD RSP,0x48 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET LAB_00157e25: MOV EAX,0xffffffff JMP 0x00157e16
int8 _ma_search_first(long *param_1,long param_2,long param_3) { long *plVar1; uint uVar2; char cVar3; int iVar4; long lVar5; int8 uVar6; int4 *puVar7; int8 uVar8; int1 local_70 [16]; long local_60; uint local_50; uint local_48; int4 local_44; long local_38; if (param_3 == -1) { puVar7 = (int4 *)_my_thread_var(); *puVar7 = 0x78; LAB_00157e01: uVar8 = 0xffffffff; uVar6 = 0xffffffffffffffff; lVar5 = 0x98; } else { lVar5 = *param_1; do { cVar3 = _ma_fetch_keypage(local_70,param_1,param_2,param_3,0,3,param_1[0x70],0); uVar2 = local_48; if (cVar3 != '\0') goto LAB_00157e01; local_38 = (ulong)*(uint *)(lVar5 + 0x744) + local_60 + (ulong)local_48; param_3 = _ma_kpos((ulong)local_48); } while (param_3 != -1); plVar1 = param_1 + 0x40; iVar4 = (**(code **)(param_2 + 0xe0))(plVar1,local_44,uVar2,&local_38); if (iVar4 == 0) { return 0xffffffff; } param_1[0x76] = local_38; param_1[0x77] = local_60 + (ulong)local_50 + -1; *(uint *)(param_1 + 0x7a) = local_48; *(int4 *)((long)param_1 + 0x3d4) = *(int4 *)(param_2 + 0xb8); param_1[0x89] = param_1[0x88]; *(int2 *)((long)param_1 + 0x684) = 0; lVar5 = _ma_row_pos_from_key(plVar1); param_1[0x13] = lVar5; uVar6 = _ma_trid_from_key(plVar1); uVar8 = 0; lVar5 = 0xc0; } *(int8 *)((long)param_1 + lVar5) = uVar6; return uVar8; }
20,501
ggml_l2_norm_impl
ngxson[P]ggml-easy/ggml/src/ggml.c
static struct ggml_tensor * ggml_l2_norm_impl( struct ggml_context * ctx, struct ggml_tensor * a, float eps, bool inplace) { struct ggml_tensor * result = inplace ? ggml_view_tensor(ctx, a) : ggml_dup_tensor(ctx, a); ggml_set_op_params_f32(result, 0, eps); result->op = GGML_OP_L2_NORM; result->src[0] = a; return result; }
O2
c
ggml_l2_norm_impl: pushq %rbx subq $0x10, %rsp movss %xmm0, 0xc(%rsp) movq %rsi, %rbx testl %edx, %edx je 0x211d9 callq 0x1c3e0 jmp 0x211de callq 0x1d660 movss 0xc(%rsp), %xmm0 movss %xmm0, 0x54(%rax) movl $0x1a, 0x50(%rax) movq %rbx, 0x98(%rax) addq $0x10, %rsp popq %rbx retq
ggml_l2_norm_impl: push rbx sub rsp, 10h movss [rsp+18h+var_C], xmm0 mov rbx, rsi test edx, edx jz short loc_211D9 call _ggml_view_tensor jmp short loc_211DE loc_211D9: call _ggml_dup_tensor loc_211DE: movss xmm0, [rsp+18h+var_C] movss dword ptr [rax+54h], xmm0 mov dword ptr [rax+50h], 1Ah mov [rax+98h], rbx add rsp, 10h pop rbx retn
long long ggml_l2_norm_impl( long long a1, unsigned int *a2, int a3, __m128 a4, __m128 a5, __m128 a6, __m128 a7, __m128 a8, __m128 a9, __m128 a10, __m128 a11) { long long result; // rax if ( a3 ) result = ggml_view_tensor(a1, (long long)a2, a4, a5, a6, a7, a8, a9, a10, a11); else result = ggml_dup_tensor(a1, a2); *(_DWORD *)(result + 84) = a4.m128_i32[0]; *(_DWORD *)(result + 80) = 26; *(_QWORD *)(result + 152) = a2; return result; }
ggml_l2_norm_impl: PUSH RBX SUB RSP,0x10 MOVSS dword ptr [RSP + 0xc],XMM0 MOV RBX,RSI TEST EDX,EDX JZ 0x001211d9 CALL 0x0011c3e0 JMP 0x001211de LAB_001211d9: CALL 0x0011d660 LAB_001211de: MOVSS XMM0,dword ptr [RSP + 0xc] MOVSS dword ptr [RAX + 0x54],XMM0 MOV dword ptr [RAX + 0x50],0x1a MOV qword ptr [RAX + 0x98],RBX ADD RSP,0x10 POP RBX RET
void ggml_l2_norm_impl(int4 param_1,int8 param_2,int8 param_3,int param_4) { long lVar1; if (param_4 == 0) { lVar1 = ggml_dup_tensor(); } else { lVar1 = ggml_view_tensor(); } *(int4 *)(lVar1 + 0x54) = param_1; *(int4 *)(lVar1 + 0x50) = 0x1a; *(int8 *)(lVar1 + 0x98) = param_3; return; }
20,502
findPeaks::_peak_widths(std::vector<double, std::allocator<double>> const&, std::vector<unsigned long, std::allocator<unsigned long>> const&, double, std::vector<findPeaks::lpr_peak_prominence_t, std::allocator<findPeaks::lpr_peak_prominence_t>> const&)
giladroyz[P]FindPeaks/src/cpp/find_peaks.cpp
std::vector<whlr_peak_width_t> _peak_widths(const std::vector<double> &x, const std::vector<size_t> &peaks, double rel_height, const std::vector<lpr_peak_prominence_t> &prominences) { std::vector<whlr_peak_width_t> widths; size_t peak, i, i_max, i_min; double height, left_ip, right_ip; for (size_t p = 0; p < peaks.size(); p++) { whlr_peak_width_t width_data; i_min = prominences[p].left_base; i_max = prominences[p].right_base; peak = peaks[p]; height = x[peak] - prominences[p].prominence * rel_height; width_data.width_height = x[peak] - prominences[p].prominence * rel_height; //Find intersection point on left side i = peak; while (i_min < i && height < x[i]) i -= 1; left_ip = (double) i; //Interpolate if true intersection height is between samples if (x[i] < height) left_ip += (height - x[i]) / (x[i + 1] - x[i]); //Find intersection point on right side i = peak; while (i < i_max && height < x[i]) i += 1; right_ip = (double) i; //Interpolate if true intersection height is between samples if (x[i] < height) right_ip -= (height - x[i]) / (x[i - 1] - x[i]); width_data.width = right_ip - left_ip; width_data.left_ip = left_ip; width_data.right_ip = right_ip; widths.push_back(width_data); } return widths; }
O1
cpp
findPeaks::_peak_widths(std::vector<double, std::allocator<double>> const&, std::vector<unsigned long, std::allocator<unsigned long>> const&, double, std::vector<findPeaks::lpr_peak_prominence_t, std::allocator<findPeaks::lpr_peak_prominence_t>> const&): pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x28, %rsp movsd %xmm0, (%rsp) movq %rdi, %rbx xorpd %xmm0, %xmm0 movupd %xmm0, (%rdi) movq $0x0, 0x10(%rdi) movq (%rdx), %rax cmpq %rax, 0x8(%rdx) je 0x3d292 movq %rcx, %r14 movq %rdx, %r15 movq %rsi, %r12 xorl %ebp, %ebp leaq 0x8(%rsp), %r13 movq (%r14), %rsi leaq (,%rbp,2), %r8 addq %rbp, %r8 movq (%rsi,%r8,8), %rdi movq 0x10(%rsi,%r8,8), %rdx movq (%rax,%rbp,8), %rcx movq (%r12), %rax movsd (%rax,%rcx,8), %xmm0 movsd 0x8(%rsi,%r8,8), %xmm1 mulsd (%rsp), %xmm1 subsd %xmm1, %xmm0 movsd %xmm0, 0x10(%rsp) movq %rcx, %rsi cmpq %rcx, %rdi jae 0x3d187 movq %rcx, %rsi movsd (%rax,%rsi,8), %xmm1 ucomisd %xmm0, %xmm1 jbe 0x3d187 decq %rsi cmpq %rsi, %rdi jb 0x3d171 movq %rdi, %rsi movq %rsi, %xmm2 punpckldq 0x4c9c(%rip), %xmm2 # xmm2 = xmm2[0],mem[0],xmm2[1],mem[1] subpd 0x4ca4(%rip), %xmm2 # 0x41e40 movapd %xmm2, %xmm1 unpckhpd %xmm2, %xmm1 # xmm1 = xmm1[1],xmm2[1] addsd %xmm2, %xmm1 movsd (%rax,%rsi,8), %xmm2 ucomisd %xmm2, %xmm0 jbe 0x3d1cd movapd %xmm0, %xmm3 subsd %xmm2, %xmm3 movsd 0x8(%rax,%rsi,8), %xmm4 subsd %xmm2, %xmm4 divsd %xmm4, %xmm3 addsd %xmm3, %xmm1 cmpq %rdx, %rcx jae 0x3d1e8 movsd (%rax,%rcx,8), %xmm2 ucomisd %xmm0, %xmm2 jbe 0x3d1e8 incq %rcx cmpq %rcx, %rdx jne 0x3d1d2 movq %rdx, %rcx movq %rcx, %xmm3 punpckldq 0x4c3b(%rip), %xmm3 # xmm3 = xmm3[0],mem[0],xmm3[1],mem[1] subpd 0x4c43(%rip), %xmm3 # 0x41e40 movapd %xmm3, %xmm2 unpckhpd %xmm3, %xmm2 # xmm2 = xmm2[1],xmm3[1] addsd %xmm3, %xmm2 movsd (%rax,%rcx,8), %xmm3 ucomisd %xmm3, %xmm0 jbe 0x3d22a subsd %xmm3, %xmm0 movsd -0x8(%rax,%rcx,8), %xmm4 subsd %xmm3, %xmm4 divsd %xmm4, %xmm0 subsd %xmm0, %xmm2 movapd %xmm2, %xmm0 subsd %xmm1, %xmm0 movsd %xmm0, 0x8(%rsp) movsd %xmm1, 0x18(%rsp) movsd %xmm2, 0x20(%rsp) movq 0x8(%rbx), %rsi cmpq 0x10(%rbx), %rsi je 0x3d26d movupd 0x8(%rsp), %xmm0 movupd 0x18(%rsp), %xmm1 movupd %xmm1, 0x10(%rsi) movupd %xmm0, (%rsi) addq $0x20, %rsi movq %rsi, 0x8(%rbx) jmp 0x3d278 movq %rbx, %rdi movq %r13, %rdx callq 0x3f2d4 incq %rbp movq (%r15), %rax movq 0x8(%r15), %rcx subq %rax, %rcx sarq $0x3, %rcx cmpq %rcx, %rbp jb 0x3d12c movq %rbx, %rax addq $0x28, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq movq %rax, %r14 movq (%rbx), %rdi testq %rdi, %rdi je 0x3d2b4 callq 0x8470 movq %r14, %rdi callq 0x8990
_ZN9findPeaks12_peak_widthsERKSt6vectorIdSaIdEERKS0_ImSaImEEdRKS0_INS_21lpr_peak_prominence_tESaIS9_EE: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 28h movsd [rsp+58h+var_58], xmm0 mov rbx, rdi xorpd xmm0, xmm0 movupd xmmword ptr [rdi], xmm0 mov qword ptr [rdi+10h], 0 mov rax, [rdx] cmp [rdx+8], rax jz loc_3D292 mov r14, rcx mov r15, rdx mov r12, rsi xor ebp, ebp lea r13, [rsp+58h+var_50] loc_3D12C: mov rsi, [r14] lea r8, ds:0[rbp*2] add r8, rbp mov rdi, [rsi+r8*8] mov rdx, [rsi+r8*8+10h] mov rcx, [rax+rbp*8] mov rax, [r12] movsd xmm0, qword ptr [rax+rcx*8] movsd xmm1, qword ptr [rsi+r8*8+8] mulsd xmm1, [rsp+58h+var_58] subsd xmm0, xmm1 movsd qword ptr [rsp+58h+var_50+8], xmm0 mov rsi, rcx cmp rdi, rcx jnb short loc_3D187 mov rsi, rcx loc_3D171: movsd xmm1, qword ptr [rax+rsi*8] ucomisd xmm1, xmm0 jbe short loc_3D187 dec rsi cmp rdi, rsi jb short loc_3D171 mov rsi, rdi loc_3D187: movq xmm2, rsi punpckldq xmm2, cs:xmmword_41E30 subpd xmm2, cs:xmmword_41E40 movapd xmm1, xmm2 unpckhpd xmm1, xmm2 addsd xmm1, xmm2 movsd xmm2, qword ptr [rax+rsi*8] ucomisd xmm0, xmm2 jbe short loc_3D1CD movapd xmm3, xmm0 subsd xmm3, xmm2 movsd xmm4, qword ptr [rax+rsi*8+8] subsd xmm4, xmm2 divsd xmm3, xmm4 addsd xmm1, xmm3 loc_3D1CD: cmp rcx, rdx jnb short loc_3D1E8 loc_3D1D2: movsd xmm2, qword ptr [rax+rcx*8] ucomisd xmm2, xmm0 jbe short loc_3D1E8 inc rcx cmp rdx, rcx jnz short loc_3D1D2 mov rcx, rdx loc_3D1E8: movq xmm3, rcx punpckldq xmm3, cs:xmmword_41E30 subpd xmm3, cs:xmmword_41E40 movapd xmm2, xmm3 unpckhpd xmm2, xmm3 addsd xmm2, xmm3 movsd xmm3, qword ptr [rax+rcx*8] ucomisd xmm0, xmm3 jbe short loc_3D22A subsd xmm0, xmm3 movsd xmm4, qword ptr [rax+rcx*8-8] subsd xmm4, xmm3 divsd xmm0, xmm4 subsd xmm2, xmm0 loc_3D22A: movapd xmm0, xmm2 subsd xmm0, xmm1 movsd qword ptr [rsp+58h+var_50], xmm0 movsd qword ptr [rsp+58h+var_40], xmm1 movsd qword ptr [rsp+58h+var_40+8], xmm2 mov rsi, [rbx+8] cmp rsi, [rbx+10h] jz short loc_3D26D movupd xmm0, [rsp+58h+var_50] movupd xmm1, [rsp+58h+var_40] movupd xmmword ptr [rsi+10h], xmm1 movupd xmmword ptr [rsi], xmm0 add rsi, 20h ; ' ' mov [rbx+8], rsi jmp short loc_3D278 loc_3D26D: mov rdi, rbx mov rdx, r13 call _ZNSt6vectorIN9findPeaks17whlr_peak_width_tESaIS1_EE17_M_realloc_insertIJRKS1_EEEvN9__gnu_cxx17__normal_iteratorIPS1_S3_EEDpOT_; std::vector<findPeaks::whlr_peak_width_t>::_M_realloc_insert<findPeaks::whlr_peak_width_t const&>(__gnu_cxx::__normal_iterator<findPeaks::whlr_peak_width_t*,std::vector<findPeaks::whlr_peak_width_t>>,findPeaks::whlr_peak_width_t const&) loc_3D278: inc rbp mov rax, [r15] mov rcx, [r15+8] sub rcx, rax sar rcx, 3 cmp rbp, rcx jb loc_3D12C loc_3D292: mov rax, rbx add rsp, 28h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn mov r14, rax mov rdi, [rbx]; void * test rdi, rdi jz short loc_3D2B4 call __ZdlPv; operator delete(void *) loc_3D2B4: mov rdi, r14 call __Unwind_Resume
long long findPeaks::_peak_widths(long long a1, long long *a2, long long *a3, _QWORD *a4, double a5) { long long v6; // rax unsigned long long v10; // rbp unsigned long long v11; // rdi unsigned long long v12; // rdx unsigned long long v13; // rcx long long v14; // rax double v15; // xmm0_8 unsigned long long v16; // rsi __m128d v17; // xmm2 double v18; // xmm1_8 double v19; // xmm2_8 __m128d v20; // xmm3 double v21; // xmm2_8 double v22; // xmm3_8 _OWORD *v23; // rsi __int128 v24; // xmm0 __int128 v27; // [rsp+8h] [rbp-50h] BYREF double v28[8]; // [rsp+18h] [rbp-40h] *(_OWORD *)a1 = 0LL; *(_QWORD *)(a1 + 16) = 0LL; v6 = *a3; if ( a3[1] != *a3 ) { v10 = 0LL; do { v11 = *(_QWORD *)(*a4 + 24 * v10); v12 = *(_QWORD *)(*a4 + 24 * v10 + 16); v13 = *(_QWORD *)(v6 + 8 * v10); v14 = *a2; v15 = *(double *)(*a2 + 8 * v13) - *(double *)(*a4 + 24 * v10 + 8) * a5; *((double *)&v27 + 1) = v15; v16 = v13; if ( v11 < v13 ) { v16 = v13; while ( *(double *)(v14 + 8 * v16) > v15 ) { if ( v11 >= --v16 ) { v16 = v11; break; } } } v17 = _mm_sub_pd((__m128d)_mm_unpacklo_epi32((__m128i)v16, (__m128i)xmmword_41E30), (__m128d)xmmword_41E40); v18 = _mm_unpackhi_pd(v17, v17).m128d_f64[0] + v17.m128d_f64[0]; v19 = *(double *)(v14 + 8 * v16); if ( v15 > v19 ) v18 = v18 + (v15 - v19) / (*(double *)(v14 + 8 * v16 + 8) - v19); if ( v13 < v12 ) { while ( *(double *)(v14 + 8 * v13) > v15 ) { if ( v12 == ++v13 ) { v13 = v12; break; } } } v20 = _mm_sub_pd((__m128d)_mm_unpacklo_epi32((__m128i)v13, (__m128i)xmmword_41E30), (__m128d)xmmword_41E40); v21 = _mm_unpackhi_pd(v20, v20).m128d_f64[0] + v20.m128d_f64[0]; v22 = *(double *)(v14 + 8 * v13); if ( v15 > v22 ) v21 = v21 - (v15 - v22) / (*(double *)(v14 + 8 * v13 - 8) - v22); *(double *)&v27 = v21 - v18; v28[0] = v18; v28[1] = v21; v23 = *(_OWORD **)(a1 + 8); if ( v23 == *(_OWORD **)(a1 + 16) ) { std::vector<findPeaks::whlr_peak_width_t>::_M_realloc_insert<findPeaks::whlr_peak_width_t const&>(a1, v23, &v27); } else { v24 = v27; v23[1] = *(_OWORD *)v28; *v23 = v24; *(_QWORD *)(a1 + 8) = v23 + 2; } ++v10; v6 = *a3; } while ( v10 < (a3[1] - *a3) >> 3 ); } return a1; }
fp_cond_init_plateau_size: MOV qword ptr [RDI + 0x58],0x0 MOV qword ptr [RDI + 0x60],-0x1 RET
void fp_cond_init_plateau_size(long param_1) { *(int8 *)(param_1 + 0x58) = 0; *(int8 *)(param_1 + 0x60) = 0xffffffffffffffff; return; }
20,503
PAIRING_Aggregate_PK_in_G2
corpus-core[P]colibri-stateless/build_O1/_deps/blst-src/src/aggregate.c
static BLST_ERROR PAIRING_Aggregate_PK_in_G2(PAIRING *ctx, const POINTonE2_affine *PK, size_t pk_groupcheck, const POINTonE1_affine *sig, size_t sig_groupcheck, const byte *scalar, size_t nbits, const void *msg, size_t msg_len, const void *aug, size_t aug_len) { if (ctx->ctrl & AGGR_MIN_PK) return BLST_AGGR_TYPE_MISMATCH; ctx->ctrl |= AGGR_MIN_SIG; /* * Since we don't know if the signature is individual or aggregated, * the only sensible thing to do is to skip over infinite one and * count on the corresponding infinite public key to be rejected, * in case the signature is non-aggregated that is. */ if (sig != NULL && !vec_is_zero(sig, sizeof(*sig))) { POINTonE1 *S = &ctx->AggrSign.e1; POINTonE1 P[1]; FROM_AFFINE(P, sig); if (sig_groupcheck && !POINTonE1_in_G1(P)) return BLST_POINT_NOT_IN_GROUP; if (ctx->ctrl & AGGR_SIGN_SET) { if (nbits != 0 && scalar != NULL) { POINTonE1_mult_w5(P, P, scalar, nbits); POINTonE1_dadd(S, S, P, NULL); } else { POINTonE1_dadd_affine(S, S, sig); } } else { ctx->ctrl |= AGGR_SIGN_SET; if (nbits != 0 && scalar != NULL) POINTonE1_mult_w5(S, P, scalar, nbits); else vec_copy(S, P, sizeof(P)); } } if (PK != NULL) { unsigned int n; POINTonE1 H[1]; const void *DST = pairing_get_dst(ctx); /* * Reject infinite public keys. */ if (vec_is_zero(PK, sizeof(*PK))) return BLST_PK_IS_INFINITY; if (pk_groupcheck) { POINTonE2 P[1]; FROM_AFFINE(P, PK); if (!POINTonE2_in_G2(P)) return BLST_POINT_NOT_IN_GROUP; } if (ctx->ctrl & AGGR_HASH_OR_ENCODE) Hash_to_G1(H, msg, msg_len, DST, ctx->DST_len, aug, aug_len); else Encode_to_G1(H, msg, msg_len, DST, ctx->DST_len, aug, aug_len); if (nbits != 0 && scalar != NULL) POINTonE1_mult_w5(H, H, scalar, nbits); POINTonE1_from_Jacobian(H, H); n = ctx->nelems; vec_copy(ctx->Q + n, PK, sizeof(POINTonE2_affine)); vec_copy(ctx->P + n, H, sizeof(POINTonE1_affine)); if (++n == N_MAX) { if (ctx->ctrl & AGGR_GT_SET) { vec384fp12 GT; miller_loop_n(GT, ctx->Q, ctx->P, n); mul_fp12(ctx->GT, ctx->GT, GT); } else { miller_loop_n(ctx->GT, ctx->Q, ctx->P, n); ctx->ctrl |= AGGR_GT_SET; } n = 0; } ctx->nelems = n; } return BLST_SUCCESS; }
O1
c
PAIRING_Aggregate_PK_in_G2: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x2d8, %rsp # imm = 0x2D8 movq %r9, -0x30(%rbp) movq %rcx, %r12 movl (%rdi), %ecx movl $0x4, %eax testb $0x2, %cl jne 0x65b05 movq %rdx, %r13 movq %rsi, %r14 movq %rdi, %rbx orl $0x1, %ecx movl %ecx, (%rdi) testq %r12, %r12 je 0x65805 movq %r8, %r15 movl $0x60, %esi movq %r12, %rdi callq 0x74d40 testq %rax, %rax je 0x65843 testq %r14, %r14 je 0x65b03 movq 0x8(%rbx), %rax leaq 0xc78(%rbx), %r12 cmpq $0x2a, %rax cmovneq %rax, %r12 movl $0xc0, %esi movq %r14, %rdi callq 0x74d40 testq %rax, %rax je 0x658dd movl $0x6, %eax xorl %ecx, %ecx jmp 0x65aff leaq -0x300(%rbp), %rdi movl $0xc, %ecx movq %r12, %rsi rep movsq (%rsi), %es:(%rdi) movl $0x60, %esi movq %r12, %rdi callq 0x74d40 leaq 0x2b40f(%rip), %rdx # 0x90c78 leaq -0x2a0(%rbp), %rdi movq %r12, %rsi movq %rax, %rcx callq 0x746a0 testq %r15, %r15 je 0x65895 leaq -0x300(%rbp), %rdi callq 0x605a4 testq %rax, %rax je 0x65a94 leaq 0x258(%rbx), %r15 movl (%rbx), %eax testb $0x10, %al jne 0x65975 orl $0x10, %eax movl %eax, (%rbx) movq 0x10(%rbp), %rcx testq %rcx, %rcx sete %al movq -0x30(%rbp), %rdx testq %rdx, %rdx sete %sil orb %al, %sil jne 0x65aa4 leaq -0x300(%rbp), %rsi movq %r15, %rdi callq 0x5fe44 jmp 0x65805 testq %r13, %r13 je 0x65933 leaq -0x300(%rbp), %r15 movl $0xc0, %edx movq %r15, %rdi movq %r14, %rsi callq 0x22090 leaq -0x240(%rbp), %r13 movl $0xc0, %esi movq %r14, %rdi callq 0x74d40 leaq 0x2b364(%rip), %rdx # 0x90c78 movq %r13, %rdi movq %r14, %rsi movq %rax, %rcx callq 0x74720 movq %r15, %rdi callq 0x6385f testq %rax, %rax je 0x65a9b movq 0x30(%rbp), %rcx movq 0x28(%rbp), %rdx movq 0x20(%rbp), %r9 movq 0x18(%rbp), %r8 testb $0x40, (%rbx) movq 0x10(%rbx), %rax leaq -0x300(%rbp), %r15 jne 0x659ba movl $0x1, %esi movq %r15, %rdi pushq %rax pushq %r12 callq 0x6b496 addq $0x10, %rsp leaq -0xc0(%rbp), %rdi movq %r15, %rsi xorl %edx, %edx jmp 0x659df movq 0x10(%rbp), %rcx testq %rcx, %rcx sete %al movq -0x30(%rbp), %rdx testq %rdx, %rdx sete %sil orb %al, %sil jne 0x65abd leaq -0x300(%rbp), %r12 movq %r12, %rdi movq %r12, %rsi callq 0x5fe44 movq %r15, %rdi movq %r15, %rsi movq %r12, %rdx xorl %ecx, %ecx callq 0x5e732 jmp 0x65805 movl $0x2, %esi movq %r15, %rdi pushq %rax pushq %r12 callq 0x6b496 addq $0x10, %rsp leaq -0x2d0(%rbp), %rdx leaq -0xc0(%rbp), %rdi movq %r15, %rsi callq 0x600c9 movq 0x10(%rbp), %rcx testq %rcx, %rcx sete %al movq -0x30(%rbp), %rdx testq %rdx, %rdx sete %sil orb %al, %sil jne 0x65a0d leaq -0xc0(%rbp), %rdi movq %rdi, %rsi callq 0x5fe44 leaq -0xc0(%rbp), %r15 movq %r15, %rdi movq %r15, %rsi callq 0x5d998 movl 0x4(%rbx), %r12d leaq (%r12,%r12,2), %r13 movq %r13, %rax shlq $0x6, %rax leaq (%rbx,%rax), %rdi addq $0x378, %rdi # imm = 0x378 movl $0xc0, %edx movq %r14, %rsi callq 0x22090 shlq $0x5, %r13 leaq (%rbx,%r13), %rdi addq $0x978, %rdi # imm = 0x978 movl $0xc, %ecx movq %r15, %rsi rep movsq (%rsi), %es:(%rdi) leal 0x1(%r12), %eax cmpl $0x8, %eax jne 0x65af5 leaq 0x378(%rbx), %rsi leaq 0x978(%rbx), %rdx testb $0x20, (%rbx) jne 0x65ad0 leaq 0x18(%rbx), %rdi movl $0x8, %ecx callq 0x64b11 orb $0x20, (%rbx) jmp 0x65af3 movl $0x3, %eax jmp 0x65b05 xorl %ecx, %ecx movl $0x3, %eax jmp 0x65aff leaq -0x300(%rbp), %rsi movl $0x90, %edx movq %r15, %rdi callq 0x22090 jmp 0x65805 movq %r15, %rdi movq %r15, %rsi movq %r12, %rdx callq 0x5edf7 jmp 0x65805 leaq -0x300(%rbp), %r14 movl $0x8, %ecx movq %r14, %rdi callq 0x64b11 leaq 0x18(%rbx), %rdi movq %rdi, %rsi movq %r14, %rdx callq 0x63d36 xorl %eax, %eax movl %eax, 0x4(%rbx) movl $0x3, %eax movb $0x1, %cl testb %cl, %cl je 0x65b05 xorl %eax, %eax addq $0x2d8, %rsp # imm = 0x2D8 popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
PAIRING_Aggregate_PK_in_G2: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx sub rsp, 2D8h mov [rbp+var_30], r9 mov r12, rcx mov ecx, [rdi] mov eax, 4 test cl, 2 jnz loc_65B05 mov r13, rdx mov r14, rsi mov rbx, rdi or ecx, 1 mov [rdi], ecx test r12, r12 jz short loc_65805 mov r15, r8 mov esi, 60h ; '`' mov rdi, r12 call vec_is_zero_16x test rax, rax jz short loc_65843 loc_65805: test r14, r14 jz loc_65B03 mov rax, [rbx+8] lea r12, [rbx+0C78h] cmp rax, 2Ah ; '*' cmovnz r12, rax mov esi, 0C0h mov rdi, r14 call vec_is_zero_16x test rax, rax jz loc_658DD mov eax, 6 xor ecx, ecx jmp loc_65AFF loc_65843: lea rdi, [rbp+var_300] mov ecx, 0Ch mov rsi, r12 rep movsq mov esi, 60h ; '`' mov rdi, r12 call vec_is_zero_16x lea rdx, BLS12_381_Rx lea rdi, [rbp+var_2A0] mov rsi, r12 mov rcx, rax call vec_select_48 test r15, r15 jz short loc_65895 lea rdi, [rbp+var_300] call POINTonE1_in_G1 test rax, rax jz loc_65A94 loc_65895: lea r15, [rbx+258h] mov eax, [rbx] test al, 10h jnz loc_65975 or eax, 10h mov [rbx], eax mov rcx, [rbp+arg_0] test rcx, rcx setz al mov rdx, [rbp+var_30] test rdx, rdx setz sil or sil, al jnz loc_65AA4 lea rsi, [rbp+var_300] mov rdi, r15 call POINTonE1_mult_w5 jmp loc_65805 loc_658DD: test r13, r13 jz short loc_65933 lea r15, [rbp+var_300] mov edx, 0C0h mov rdi, r15 mov rsi, r14 call _memcpy lea r13, [rbp+var_240] mov esi, 0C0h mov rdi, r14 call vec_is_zero_16x lea rdx, BLS12_381_Rx mov rdi, r13 mov rsi, r14 mov rcx, rax call vec_select_96 mov rdi, r15 call POINTonE2_in_G2 test rax, rax jz loc_65A9B loc_65933: mov rcx, [rbp+arg_20] mov rdx, [rbp+arg_18] mov r9, [rbp+arg_10] mov r8, [rbp+arg_8] test byte ptr [rbx], 40h mov rax, [rbx+10h] lea r15, [rbp+var_300] jnz short loc_659BA mov esi, 1 mov rdi, r15 push rax push r12 call hash_to_field add rsp, 10h lea rdi, [rbp+var_C0] mov rsi, r15 xor edx, edx jmp short loc_659DF loc_65975: mov rcx, [rbp+arg_0] test rcx, rcx setz al mov rdx, [rbp+var_30] test rdx, rdx setz sil or sil, al jnz loc_65ABD lea r12, [rbp+var_300] mov rdi, r12 mov rsi, r12 call POINTonE1_mult_w5 mov rdi, r15 mov rsi, r15 mov rdx, r12 xor ecx, ecx call POINTonE1_dadd jmp loc_65805 loc_659BA: mov esi, 2 mov rdi, r15 push rax push r12 call hash_to_field add rsp, 10h lea rdx, [rbp+var_2D0] lea rdi, [rbp+var_C0] mov rsi, r15 loc_659DF: call map_to_g1 mov rcx, [rbp+arg_0] test rcx, rcx setz al mov rdx, [rbp+var_30] test rdx, rdx setz sil or sil, al jnz short loc_65A0D lea rdi, [rbp+var_C0] mov rsi, rdi call POINTonE1_mult_w5 loc_65A0D: lea r15, [rbp+var_C0] mov rdi, r15 mov rsi, r15 call POINTonE1_from_Jacobian mov r12d, [rbx+4] lea r13, [r12+r12*2] mov rax, r13 shl rax, 6 lea rdi, [rbx+rax] add rdi, 378h mov edx, 0C0h mov rsi, r14 call _memcpy shl r13, 5 lea rdi, [rbx+r13] add rdi, 978h mov ecx, 0Ch mov rsi, r15 rep movsq lea eax, [r12+1] cmp eax, 8 jnz loc_65AF5 lea rsi, [rbx+378h] lea rdx, [rbx+978h] test byte ptr [rbx], 20h jnz short loc_65AD0 lea rdi, [rbx+18h] mov ecx, 8 call miller_loop_n or byte ptr [rbx], 20h jmp short loc_65AF3 loc_65A94: mov eax, 3 jmp short loc_65B05 loc_65A9B: xor ecx, ecx mov eax, 3 jmp short loc_65AFF loc_65AA4: lea rsi, [rbp+var_300] mov edx, 90h mov rdi, r15 call _memcpy jmp loc_65805 loc_65ABD: mov rdi, r15 mov rsi, r15 mov rdx, r12 call POINTonE1_dadd_affine jmp loc_65805 loc_65AD0: lea r14, [rbp+var_300] mov ecx, 8 mov rdi, r14 call miller_loop_n lea rdi, [rbx+18h] mov rsi, rdi mov rdx, r14 call mul_fp12 loc_65AF3: xor eax, eax loc_65AF5: mov [rbx+4], eax mov eax, 3 mov cl, 1 loc_65AFF: test cl, cl jz short loc_65B05 loc_65B03: xor eax, eax loc_65B05: add rsp, 2D8h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
long long PAIRING_Aggregate_PK_in_G2( long long a1, long long a2, long long a3, const void *a4, long long a5, unsigned __int8 *a6, unsigned long long a7, long long a8, long long a9, long long a10, long long a11) { long long result; // rax long long v15; // r12 char v16; // cl long long is_zero_16x; // rax long long v18; // rax char *v19; // rdx long long v20; // r12 int v21; // eax long long v22; // rsi long long v23; // rdx char v24[96]; // [rsp+0h] [rbp-300h] BYREF _BYTE v25[96]; // [rsp+60h] [rbp-2A0h] BYREF _BYTE v26[384]; // [rsp+C0h] [rbp-240h] BYREF _BYTE v27[144]; // [rsp+240h] [rbp-C0h] BYREF unsigned __int8 *v28; // [rsp+2D0h] [rbp-30h] v28 = a6; result = 4LL; if ( (*(_DWORD *)a1 & 2) == 0 ) { *(_DWORD *)a1 |= 1u; if ( a4 && !vec_is_zero_16x(a4, 96LL) ) { qmemcpy(v24, a4, sizeof(v24)); is_zero_16x = vec_is_zero_16x(a4, 96LL); vec_select_48(v25, a4, &BLS12_381_Rx, is_zero_16x); if ( a5 && !POINTonE1_in_G1(v24) ) return 3LL; if ( (*(_DWORD *)a1 & 0x10) != 0 ) { if ( a7 == 0 || v28 == 0LL ) { POINTonE1_dadd_affine(a1 + 600, a1 + 600, (long long)a4); } else { POINTonE1_mult_w5((long long)v24, (long long)v24, v28, a7); POINTonE1_dadd(a1 + 600, a1 + 600, (long long)v24, 0LL); } } else { *(_DWORD *)a1 |= 0x10u; if ( a7 == 0 || v28 == 0LL ) memcpy(a1 + 600); else POINTonE1_mult_w5(a1 + 600, (long long)v24, v28, a7); } } if ( !a2 ) return 0LL; v15 = a1 + 3192; if ( *(_QWORD *)(a1 + 8) != 42LL ) v15 = *(_QWORD *)(a1 + 8); if ( vec_is_zero_16x(a2, 192LL) ) { result = 6LL; v16 = 0; } else if ( a3 && (memcpy(v24), v18 = vec_is_zero_16x(a2, 192LL), vec_select_96(v26, a2, &BLS12_381_Rx, v18), !POINTonE2_in_G2((long long)v24)) ) { v16 = 0; result = 3LL; } else { if ( (*(_BYTE *)a1 & 0x40) != 0 ) { hash_to_field((unsigned int)v24, 2, a10, a11, a8, a9, v15, *(_QWORD *)(a1 + 16)); v19 = &v24[48]; } else { hash_to_field((unsigned int)v24, 1, a10, a11, a8, a9, v15, *(_QWORD *)(a1 + 16)); v19 = 0LL; } map_to_g1((long long)v27, (long long)v24, (long long)v19); if ( a7 != 0 && v28 != 0LL ) POINTonE1_mult_w5((long long)v27, (long long)v27, v28, a7); POINTonE1_from_Jacobian((long long)v27, (long long)v27); v20 = *(unsigned int *)(a1 + 4); memcpy(a1 + 192 * v20 + 888); qmemcpy((void *)(a1 + 96 * v20 + 2424), v27, 0x60uLL); v21 = v20 + 1; if ( (_DWORD)v20 == 7 ) { v22 = a1 + 888; v23 = a1 + 2424; if ( (*(_BYTE *)a1 & 0x20) != 0 ) { miller_loop_n((long long)v24, v22, v23, 8LL); mul_fp12(a1 + 24, a1 + 24, (long long)v24); } else { miller_loop_n(a1 + 24, v22, v23, 8LL); *(_BYTE *)a1 |= 0x20u; } v21 = 0; } *(_DWORD *)(a1 + 4) = v21; result = 3LL; v16 = 1; } if ( v16 ) return 0LL; } return result; }
PAIRING_Aggregate_PK_in_G2: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x2d8 MOV qword ptr [RBP + -0x30],R9 MOV R12,RCX MOV ECX,dword ptr [RDI] MOV EAX,0x4 TEST CL,0x2 JNZ 0x00165b05 MOV R13,RDX MOV R14,RSI MOV RBX,RDI OR ECX,0x1 MOV dword ptr [RDI],ECX TEST R12,R12 JZ 0x00165805 MOV R15,R8 MOV ESI,0x60 MOV RDI,R12 CALL 0x00174d40 TEST RAX,RAX JZ 0x00165843 LAB_00165805: TEST R14,R14 JZ 0x00165b03 MOV RAX,qword ptr [RBX + 0x8] LEA R12,[RBX + 0xc78] CMP RAX,0x2a CMOVNZ R12,RAX MOV ESI,0xc0 MOV RDI,R14 CALL 0x00174d40 TEST RAX,RAX JZ 0x001658dd MOV EAX,0x6 XOR ECX,ECX JMP 0x00165aff LAB_00165843: LEA RDI,[RBP + -0x300] MOV ECX,0xc MOV RSI,R12 MOVSQ.REP RDI,RSI MOV ESI,0x60 MOV RDI,R12 CALL 0x00174d40 LEA RDX,[0x190c78] LEA RDI,[RBP + -0x2a0] MOV RSI,R12 MOV RCX,RAX CALL 0x001746a0 TEST R15,R15 JZ 0x00165895 LEA RDI,[RBP + -0x300] CALL 0x001605a4 TEST RAX,RAX JZ 0x00165a94 LAB_00165895: LEA R15,[RBX + 0x258] MOV EAX,dword ptr [RBX] TEST AL,0x10 JNZ 0x00165975 OR EAX,0x10 MOV dword ptr [RBX],EAX MOV RCX,qword ptr [RBP + 0x10] TEST RCX,RCX SETZ AL MOV RDX,qword ptr [RBP + -0x30] TEST RDX,RDX SETZ SIL OR SIL,AL JNZ 0x00165aa4 LEA RSI,[RBP + -0x300] MOV RDI,R15 CALL 0x0015fe44 JMP 0x00165805 LAB_001658dd: TEST R13,R13 JZ 0x00165933 LEA R15,[RBP + -0x300] MOV EDX,0xc0 MOV RDI,R15 MOV RSI,R14 CALL 0x00122090 LEA R13,[RBP + -0x240] MOV ESI,0xc0 MOV RDI,R14 CALL 0x00174d40 LEA RDX,[0x190c78] MOV RDI,R13 MOV RSI,R14 MOV RCX,RAX CALL 0x00174720 MOV RDI,R15 CALL 0x0016385f TEST RAX,RAX JZ 0x00165a9b LAB_00165933: MOV RCX,qword ptr [RBP + 0x30] MOV RDX,qword ptr [RBP + 0x28] MOV R9,qword ptr [RBP + 0x20] MOV R8,qword ptr [RBP + 0x18] TEST byte ptr [RBX],0x40 MOV RAX,qword ptr [RBX + 0x10] LEA R15,[RBP + -0x300] JNZ 0x001659ba MOV ESI,0x1 MOV RDI,R15 PUSH RAX PUSH R12 CALL 0x0016b496 ADD RSP,0x10 LEA RDI,[RBP + -0xc0] MOV RSI,R15 XOR EDX,EDX JMP 0x001659df LAB_00165975: MOV RCX,qword ptr [RBP + 0x10] TEST RCX,RCX SETZ AL MOV RDX,qword ptr [RBP + -0x30] TEST RDX,RDX SETZ SIL OR SIL,AL JNZ 0x00165abd LEA R12,[RBP + -0x300] MOV RDI,R12 MOV RSI,R12 CALL 0x0015fe44 MOV RDI,R15 MOV RSI,R15 MOV RDX,R12 XOR ECX,ECX CALL 0x0015e732 JMP 0x00165805 LAB_001659ba: MOV ESI,0x2 MOV RDI,R15 PUSH RAX PUSH R12 CALL 0x0016b496 ADD RSP,0x10 LEA RDX,[RBP + -0x2d0] LEA RDI,[RBP + -0xc0] MOV RSI,R15 LAB_001659df: CALL 0x001600c9 MOV RCX,qword ptr [RBP + 0x10] TEST RCX,RCX SETZ AL MOV RDX,qword ptr [RBP + -0x30] TEST RDX,RDX SETZ SIL OR SIL,AL JNZ 0x00165a0d LEA RDI,[RBP + -0xc0] MOV RSI,RDI CALL 0x0015fe44 LAB_00165a0d: LEA R15,[RBP + -0xc0] MOV RDI,R15 MOV RSI,R15 CALL 0x0015d998 MOV R12D,dword ptr [RBX + 0x4] LEA R13,[R12 + R12*0x2] MOV RAX,R13 SHL RAX,0x6 LEA RDI,[RBX + RAX*0x1] ADD RDI,0x378 MOV EDX,0xc0 MOV RSI,R14 CALL 0x00122090 SHL R13,0x5 LEA RDI,[RBX + R13*0x1] ADD RDI,0x978 MOV ECX,0xc MOV RSI,R15 MOVSQ.REP RDI,RSI LEA EAX,[R12 + 0x1] CMP EAX,0x8 JNZ 0x00165af5 LEA RSI,[RBX + 0x378] LEA RDX,[RBX + 0x978] TEST byte ptr [RBX],0x20 JNZ 0x00165ad0 LEA RDI,[RBX + 0x18] MOV ECX,0x8 CALL 0x00164b11 OR byte ptr [RBX],0x20 JMP 0x00165af3 LAB_00165a94: MOV EAX,0x3 JMP 0x00165b05 LAB_00165a9b: XOR ECX,ECX MOV EAX,0x3 JMP 0x00165aff LAB_00165aa4: LEA RSI,[RBP + -0x300] MOV EDX,0x90 MOV RDI,R15 CALL 0x00122090 JMP 0x00165805 LAB_00165abd: MOV RDI,R15 MOV RSI,R15 MOV RDX,R12 CALL 0x0015edf7 JMP 0x00165805 LAB_00165ad0: LEA R14,[RBP + -0x300] MOV ECX,0x8 MOV RDI,R14 CALL 0x00164b11 LEA RDI,[RBX + 0x18] MOV RSI,RDI MOV RDX,R14 CALL 0x00163d36 LAB_00165af3: XOR EAX,EAX LAB_00165af5: MOV dword ptr [RBX + 0x4],EAX MOV EAX,0x3 MOV CL,0x1 LAB_00165aff: TEST CL,CL JZ 0x00165b05 LAB_00165b03: XOR EAX,EAX LAB_00165b05: ADD RSP,0x2d8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
int8 PAIRING_Aggregate_PK_in_G2 (uint *param_1,void *param_2,long param_3,int8 *param_4,long param_5,long param_6, long param_7,int8 param_8,int8 param_9,int8 param_10,int8 param_11 ) { bool bVar1; uint uVar2; long lVar3; int8 uVar4; int1 *puVar5; int8 *puVar6; int8 *puVar7; uint *puVar8; byte bVar9; int8 local_308 [6]; int1 local_2d8 [48]; int1 local_2a8 [96]; int1 local_248 [384]; int8 local_c8 [18]; long local_38; bVar9 = 0; if ((*param_1 & 2) != 0) { return 4; } *param_1 = *param_1 | 1; local_38 = param_6; if ((param_4 != (int8 *)0x0) && (lVar3 = vec_is_zero_16x(param_4,0x60), lVar3 == 0)) { puVar6 = param_4; puVar7 = local_308; for (lVar3 = 0xc; lVar3 != 0; lVar3 = lVar3 + -1) { *puVar7 = *puVar6; puVar6 = puVar6 + (ulong)bVar9 * -2 + 1; puVar7 = puVar7 + (ulong)bVar9 * -2 + 1; } uVar4 = vec_is_zero_16x(param_4,0x60); vec_select_48(local_2a8,param_4,&BLS12_381_Rx,uVar4); if ((param_5 != 0) && (lVar3 = POINTonE1_in_G1(local_308), lVar3 == 0)) { return 3; } puVar8 = param_1 + 0x96; if ((*param_1 & 0x10) == 0) { *param_1 = *param_1 | 0x10; if (local_38 == 0 || param_7 == 0) { memcpy(puVar8,local_308,0x90); } else { POINTonE1_mult_w5(puVar8,local_308); } } else if (local_38 == 0 || param_7 == 0) { POINTonE1_dadd_affine(puVar8,puVar8,param_4); } else { POINTonE1_mult_w5(local_308,local_308); POINTonE1_dadd(puVar8,puVar8,local_308); } } if (param_2 == (void *)0x0) { return 0; } puVar8 = param_1 + 0x31e; if (*(uint **)(param_1 + 2) != (uint *)0x2a) { puVar8 = *(uint **)(param_1 + 2); } lVar3 = vec_is_zero_16x(param_2,0xc0); if (lVar3 == 0) { if (param_3 != 0) { memcpy(local_308,param_2,0xc0); vec_is_zero_16x(param_2,0xc0); vec_select_96(local_248,param_2,&BLS12_381_Rx); lVar3 = POINTonE2_in_G2(local_308); if (lVar3 == 0) { bVar1 = false; uVar4 = 3; goto LAB_00165aff; } } if ((*param_1 & 0x40) == 0) { hash_to_field(local_308,1,param_10,param_11,param_8,param_9,puVar8, *(int8 *)(param_1 + 4)); puVar5 = (int1 *)0x0; } else { hash_to_field(local_308,2,param_10,param_11,param_8,param_9,puVar8, *(int8 *)(param_1 + 4)); puVar5 = local_2d8; } map_to_g1(local_c8,local_308,puVar5); if (local_38 != 0 && param_7 != 0) { POINTonE1_mult_w5(local_c8,local_c8); } POINTonE1_from_Jacobian(local_c8,local_c8); uVar2 = param_1[1]; memcpy(param_1 + (ulong)uVar2 * 0x30 + 0xde,param_2,0xc0); puVar6 = local_c8; puVar8 = param_1 + (ulong)uVar2 * 0x18 + 0x25e; for (lVar3 = 0xc; lVar3 != 0; lVar3 = lVar3 + -1) { *(int8 *)puVar8 = *puVar6; puVar6 = puVar6 + (ulong)bVar9 * -2 + 1; puVar8 = puVar8 + (ulong)bVar9 * -4 + 2; } uVar2 = uVar2 + 1; if (uVar2 == 8) { if ((*param_1 & 0x20) == 0) { miller_loop_n(param_1 + 6,param_1 + 0xde,param_1 + 0x25e,8); *(byte *)param_1 = (byte)*param_1 | 0x20; } else { miller_loop_n(local_308,param_1 + 0xde,param_1 + 0x25e,8); mul_fp12(param_1 + 6,param_1 + 6,local_308); } uVar2 = 0; } param_1[1] = uVar2; uVar4 = 3; bVar1 = true; } else { uVar4 = 6; bVar1 = false; } LAB_00165aff: if (bVar1) { return 0; } return uVar4; }
20,504
stbtt__find_table
dmazzella[P]pylunasvg/lunasvg/plutovg/source/plutovg-stb-truetype.h
static stbtt_uint32 stbtt__find_table(stbtt_uint8 *data, stbtt_uint32 fontstart, const char *tag) { stbtt_int32 num_tables = ttUSHORT(data+fontstart+4); stbtt_uint32 tabledir = fontstart + 12; stbtt_int32 i; for (i=0; i < num_tables; ++i) { stbtt_uint32 loc = tabledir + 16*i; if (stbtt_tag(data+loc+0, tag)) return ttULONG(data+loc+8); } return 0; }
O1
c
stbtt__find_table: movl %esi, %eax movzwl 0x4(%rdi,%rax), %ecx rolw $0x8, %cx xorl %eax, %eax testw %cx, %cx je 0x5c1d pushq %rbx movzwl %cx, %r8d movsbl (%rdx), %ecx movl %r8d, %r8d addl $0xc, %esi movl %esi, %esi movzbl (%rdi,%rsi), %r11d movb $0x1, %r10b cmpl %ecx, %r11d jne 0x5c0a movzbl 0x1(%rdi,%rsi), %r11d movsbl 0x1(%rdx), %ebx cmpl %ebx, %r11d jne 0x5c0a movzbl 0x2(%rdi,%rsi), %r11d movsbl 0x2(%rdx), %ebx cmpl %ebx, %r11d jne 0x5c0a movzbl 0x3(%rdi,%rsi), %r11d movsbl 0x3(%rdx), %ebx cmpl %ebx, %r11d jne 0x5c0a movl 0x8(%rdi,%rsi), %r9d bswapl %r9d xorl %r10d, %r10d testb %r10b, %r10b je 0x5c19 addl $0x10, %esi decq %r8 jne 0x5bc3 jmp 0x5c1c movl %r9d, %eax popq %rbx retq
stbtt__find_table: mov eax, esi movzx ecx, word ptr [rdi+rax+4] rol cx, 8 xor eax, eax test cx, cx jz short locret_5C1D push rbx movzx r8d, cx movsx ecx, byte ptr [rdx] mov r8d, r8d add esi, 0Ch loc_5BC3: mov esi, esi movzx r11d, byte ptr [rdi+rsi] mov r10b, 1 cmp r11d, ecx jnz short loc_5C0A movzx r11d, byte ptr [rdi+rsi+1] movsx ebx, byte ptr [rdx+1] cmp r11d, ebx jnz short loc_5C0A movzx r11d, byte ptr [rdi+rsi+2] movsx ebx, byte ptr [rdx+2] cmp r11d, ebx jnz short loc_5C0A movzx r11d, byte ptr [rdi+rsi+3] movsx ebx, byte ptr [rdx+3] cmp r11d, ebx jnz short loc_5C0A mov r9d, [rdi+rsi+8] bswap r9d xor r10d, r10d loc_5C0A: test r10b, r10b jz short loc_5C19 add esi, 10h dec r8 jnz short loc_5BC3 jmp short loc_5C1C loc_5C19: mov eax, r9d loc_5C1C: pop rbx locret_5C1D: retn
long long stbtt__find_table( long long a1, unsigned int a2, char *a3, long long a4, long long a5, unsigned __int32 a6) { unsigned __int16 v6; // cx long long result; // rax long long v8; // r8 unsigned int i; // esi char v10; // r10 v6 = __ROL2__(*(_WORD *)(a1 + a2 + 4), 8); result = 0LL; if ( v6 ) { v8 = v6; for ( i = a2 + 12; ; i += 16 ) { v10 = 1; if ( *(unsigned __int8 *)(a1 + i) == *a3 && *(unsigned __int8 *)(a1 + i + 1) == a3[1] && *(unsigned __int8 *)(a1 + i + 2) == a3[2] && *(unsigned __int8 *)(a1 + i + 3) == a3[3] ) { a6 = _byteswap_ulong(*(_DWORD *)(a1 + i + 8)); v10 = 0; } if ( !v10 ) break; if ( !--v8 ) return result; } return a6; } return result; }
stbtt__find_table: MOV EAX,ESI MOVZX ECX,word ptr [RDI + RAX*0x1 + 0x4] ROL CX,0x8 XOR EAX,EAX TEST CX,CX JZ 0x00105c1d PUSH RBX MOVZX R8D,CX MOVSX ECX,byte ptr [RDX] MOV R8D,R8D ADD ESI,0xc LAB_00105bc3: MOV ESI,ESI MOVZX R11D,byte ptr [RDI + RSI*0x1] MOV R10B,0x1 CMP R11D,ECX JNZ 0x00105c0a MOVZX R11D,byte ptr [RDI + RSI*0x1 + 0x1] MOVSX EBX,byte ptr [RDX + 0x1] CMP R11D,EBX JNZ 0x00105c0a MOVZX R11D,byte ptr [RDI + RSI*0x1 + 0x2] MOVSX EBX,byte ptr [RDX + 0x2] CMP R11D,EBX JNZ 0x00105c0a MOVZX R11D,byte ptr [RDI + RSI*0x1 + 0x3] MOVSX EBX,byte ptr [RDX + 0x3] CMP R11D,EBX JNZ 0x00105c0a MOV R9D,dword ptr [RDI + RSI*0x1 + 0x8] BSWAP R9D XOR R10D,R10D LAB_00105c0a: TEST R10B,R10B JZ 0x00105c19 ADD ESI,0x10 DEC R8 JNZ 0x00105bc3 JMP 0x00105c1c LAB_00105c19: MOV EAX,R9D LAB_00105c1c: POP RBX LAB_00105c1d: RET
uint stbtt__find_table(long param_1,uint param_2,char *param_3,int8 param_4,int8 param_5 ,uint param_6) { uint uVar1; bool bVar2; ushort uVar3; ulong uVar4; ulong uVar5; uVar3 = *(ushort *)(param_1 + 4 + (ulong)param_2); uVar3 = uVar3 << 8 | uVar3 >> 8; if (uVar3 != 0) { uVar5 = (ulong)uVar3; param_2 = param_2 + 0xc; do { uVar4 = (ulong)param_2; bVar2 = true; if (((((uint)*(byte *)(param_1 + uVar4) == (int)*param_3) && ((uint)*(byte *)(param_1 + 1 + uVar4) == (int)param_3[1])) && ((uint)*(byte *)(param_1 + 2 + uVar4) == (int)param_3[2])) && ((uint)*(byte *)(param_1 + 3 + uVar4) == (int)param_3[3])) { uVar1 = *(uint *)(param_1 + 8 + uVar4); param_6 = uVar1 >> 0x18 | (uVar1 & 0xff0000) >> 8 | (uVar1 & 0xff00) << 8 | uVar1 << 0x18; bVar2 = false; } if (!bVar2) { return param_6; } param_2 = param_2 + 0x10; uVar5 = uVar5 - 1; } while (uVar5 != 0); } return 0; }
20,505
pfs_spawn_thread
eloqsql/storage/perfschema/pfs.cc
void* pfs_spawn_thread(void *arg) { PFS_spawn_thread_arg *typed_arg= (PFS_spawn_thread_arg*) arg; void *user_arg; void *(*user_start_routine)(void*); PFS_thread *pfs; /* First, attach instrumentation to this newly created pthread. */ PFS_thread_class *klass= find_thread_class(typed_arg->m_child_key); if (likely(klass != NULL)) { pfs= create_thread(klass, typed_arg->m_child_identity, 0); if (likely(pfs != NULL)) { clear_thread_account(pfs); pfs->m_parent_thread_internal_id= typed_arg->m_thread_internal_id; memcpy(pfs->m_username, typed_arg->m_username, sizeof(pfs->m_username)); pfs->m_username_length= typed_arg->m_username_length; memcpy(pfs->m_hostname, typed_arg->m_hostname, sizeof(pfs->m_hostname)); pfs->m_hostname_length= typed_arg->m_hostname_length; set_thread_account(pfs); } } else { pfs= NULL; } my_thread_set_THR_PFS(pfs); /* Secondly, free the memory allocated in spawn_thread_v1(). It is preferable to do this before invoking the user routine, to avoid memory leaks at shutdown, in case the server exits without waiting for this thread. */ user_start_routine= typed_arg->m_user_start_routine; user_arg= typed_arg->m_user_arg; my_free(typed_arg); /* Then, execute the user code for this thread. */ (*user_start_routine)(user_arg); return NULL; }
O0
cpp
pfs_spawn_thread: pushq %rbp movq %rsp, %rbp subq $0x30, %rsp movq %rdi, -0x8(%rbp) movq -0x8(%rbp), %rax movq %rax, -0x10(%rbp) movq -0x10(%rbp), %rax movl 0x290(%rax), %edi callq 0x42d50 movq %rax, -0x30(%rbp) cmpq $0x0, -0x30(%rbp) setne %al andb $0x1, %al movzbl %al, %eax cmpl $0x0, %eax je 0x4de5a movq -0x30(%rbp), %rdi movq -0x10(%rbp), %rax movq 0x298(%rax), %rsi xorl %eax, %eax movl %eax, %edx callq 0x37d00 movq %rax, -0x28(%rbp) cmpq $0x0, -0x28(%rbp) setne %al andb $0x1, %al movzbl %al, %eax cmpl $0x0, %eax je 0x4de58 movq -0x28(%rbp), %rdi callq 0x3a900 movq -0x10(%rbp), %rax movq (%rax), %rcx movq -0x28(%rbp), %rax movq %rcx, 0x858(%rax) movq -0x28(%rbp), %rdi addq $0xcdc, %rdi # imm = 0xCDC movq -0x10(%rbp), %rsi addq $0x8, %rsi movl $0x180, %edx # imm = 0x180 callq 0x26280 movq -0x10(%rbp), %rax movl 0x188(%rax), %ecx movq -0x28(%rbp), %rax movl %ecx, 0xe5c(%rax) movq -0x28(%rbp), %rdi addq $0xe60, %rdi # imm = 0xE60 movq -0x10(%rbp), %rsi addq $0x18c, %rsi # imm = 0x18C movl $0xff, %edx callq 0x26280 movq -0x10(%rbp), %rax movl 0x28c(%rax), %ecx movq -0x28(%rbp), %rax movl %ecx, 0xf60(%rax) movq -0x28(%rbp), %rdi callq 0x38070 jmp 0x4de62 movq $0x0, -0x28(%rbp) movq -0x28(%rbp), %rdi callq 0x4deb0 movq -0x10(%rbp), %rax movq 0x2a0(%rax), %rax movq %rax, -0x20(%rbp) movq -0x10(%rbp), %rax movq 0x2a8(%rax), %rax movq %rax, -0x18(%rbp) movq -0x10(%rbp), %rdi callq 0x592a0 movq -0x20(%rbp), %rax movq -0x18(%rbp), %rdi callq *%rax xorl %eax, %eax addq $0x30, %rsp popq %rbp retq nopw %cs:(%rax,%rax)
pfs_spawn_thread: push rbp mov rbp, rsp sub rsp, 30h mov [rbp+var_8], rdi mov rax, [rbp+var_8] mov [rbp+var_10], rax mov rax, [rbp+var_10] mov edi, [rax+290h]; unsigned int call _Z17find_thread_classj; find_thread_class(uint) mov [rbp+var_30], rax cmp [rbp+var_30], 0 setnz al and al, 1 movzx eax, al cmp eax, 0 jz loc_4DE5A mov rdi, [rbp+var_30] mov rax, [rbp+var_10] mov rsi, [rax+298h] xor eax, eax mov edx, eax call _Z13create_threadP16PFS_thread_classPKvy; create_thread(PFS_thread_class *,void const*,ulong long) mov [rbp+var_28], rax cmp [rbp+var_28], 0 setnz al and al, 1 movzx eax, al cmp eax, 0 jz loc_4DE58 mov rdi, [rbp+var_28]; PFS_thread * call _Z20clear_thread_accountP10PFS_thread; clear_thread_account(PFS_thread *) mov rax, [rbp+var_10] mov rcx, [rax] mov rax, [rbp+var_28] mov [rax+858h], rcx mov rdi, [rbp+var_28] add rdi, 0CDCh mov rsi, [rbp+var_10] add rsi, 8 mov edx, 180h call _memcpy mov rax, [rbp+var_10] mov ecx, [rax+188h] mov rax, [rbp+var_28] mov [rax+0E5Ch], ecx mov rdi, [rbp+var_28] add rdi, 0E60h mov rsi, [rbp+var_10] add rsi, 18Ch mov edx, 0FFh call _memcpy mov rax, [rbp+var_10] mov ecx, [rax+28Ch] mov rax, [rbp+var_28] mov [rax+0F60h], ecx mov rdi, [rbp+var_28]; PFS_thread * call _Z18set_thread_accountP10PFS_thread; set_thread_account(PFS_thread *) loc_4DE58: jmp short loc_4DE62 loc_4DE5A: mov [rbp+var_28], 0 loc_4DE62: mov rdi, [rbp+var_28]; PFS_thread * call _ZL21my_thread_set_THR_PFSP10PFS_thread; my_thread_set_THR_PFS(PFS_thread *) mov rax, [rbp+var_10] mov rax, [rax+2A0h] mov [rbp+var_20], rax mov rax, [rbp+var_10] mov rax, [rax+2A8h] mov [rbp+var_18], rax mov rdi, [rbp+var_10] call my_free mov rax, [rbp+var_20] mov rdi, [rbp+var_18] call rax xor eax, eax add rsp, 30h pop rbp retn
long long pfs_spawn_thread(long long a1) { long long thread_class; // [rsp+0h] [rbp-30h] PFS_thread *thread; // [rsp+8h] [rbp-28h] void ( *v4)(long long); // [rsp+10h] [rbp-20h] long long v5; // [rsp+18h] [rbp-18h] thread_class = find_thread_class(*(_DWORD *)(a1 + 656)); if ( thread_class ) { thread = create_thread(thread_class, *(_QWORD *)(a1 + 664), 0LL); if ( thread ) { clear_thread_account((PFS_account **)thread); *((_QWORD *)thread + 267) = *(_QWORD *)a1; memcpy((char *)thread + 3292, a1 + 8, 384LL); *((_DWORD *)thread + 919) = *(_DWORD *)(a1 + 392); memcpy((char *)thread + 3680, a1 + 396, 255LL); *((_DWORD *)thread + 984) = *(_DWORD *)(a1 + 652); set_thread_account(thread); } } else { thread = 0LL; } my_thread_set_THR_PFS(thread); v4 = *(void ( **)(long long))(a1 + 672); v5 = *(_QWORD *)(a1 + 680); my_free(a1); v4(v5); return 0LL; }
pfs_spawn_thread: PUSH RBP MOV RBP,RSP SUB RSP,0x30 MOV qword ptr [RBP + -0x8],RDI MOV RAX,qword ptr [RBP + -0x8] MOV qword ptr [RBP + -0x10],RAX MOV RAX,qword ptr [RBP + -0x10] MOV EDI,dword ptr [RAX + 0x290] CALL 0x00142d50 MOV qword ptr [RBP + -0x30],RAX CMP qword ptr [RBP + -0x30],0x0 SETNZ AL AND AL,0x1 MOVZX EAX,AL CMP EAX,0x0 JZ 0x0014de5a MOV RDI,qword ptr [RBP + -0x30] MOV RAX,qword ptr [RBP + -0x10] MOV RSI,qword ptr [RAX + 0x298] XOR EAX,EAX MOV EDX,EAX CALL 0x00137d00 MOV qword ptr [RBP + -0x28],RAX CMP qword ptr [RBP + -0x28],0x0 SETNZ AL AND AL,0x1 MOVZX EAX,AL CMP EAX,0x0 JZ 0x0014de58 MOV RDI,qword ptr [RBP + -0x28] CALL 0x0013a900 MOV RAX,qword ptr [RBP + -0x10] MOV RCX,qword ptr [RAX] MOV RAX,qword ptr [RBP + -0x28] MOV qword ptr [RAX + 0x858],RCX MOV RDI,qword ptr [RBP + -0x28] ADD RDI,0xcdc MOV RSI,qword ptr [RBP + -0x10] ADD RSI,0x8 MOV EDX,0x180 CALL 0x00126280 MOV RAX,qword ptr [RBP + -0x10] MOV ECX,dword ptr [RAX + 0x188] MOV RAX,qword ptr [RBP + -0x28] MOV dword ptr [RAX + 0xe5c],ECX MOV RDI,qword ptr [RBP + -0x28] ADD RDI,0xe60 MOV RSI,qword ptr [RBP + -0x10] ADD RSI,0x18c MOV EDX,0xff CALL 0x00126280 MOV RAX,qword ptr [RBP + -0x10] MOV ECX,dword ptr [RAX + 0x28c] MOV RAX,qword ptr [RBP + -0x28] MOV dword ptr [RAX + 0xf60],ECX MOV RDI,qword ptr [RBP + -0x28] CALL 0x00138070 LAB_0014de58: JMP 0x0014de62 LAB_0014de5a: MOV qword ptr [RBP + -0x28],0x0 LAB_0014de62: MOV RDI,qword ptr [RBP + -0x28] CALL 0x0014deb0 MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x2a0] MOV qword ptr [RBP + -0x20],RAX MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x2a8] MOV qword ptr [RBP + -0x18],RAX MOV RDI,qword ptr [RBP + -0x10] CALL 0x001592a0 MOV RAX,qword ptr [RBP + -0x20] MOV RDI,qword ptr [RBP + -0x18] CALL RAX XOR EAX,EAX ADD RSP,0x30 POP RBP RET
int8 pfs_spawn_thread(int8 *param_1) { code *pcVar1; int8 uVar2; PFS_thread_class *pPVar3; PFS_thread *local_30; pPVar3 = (PFS_thread_class *)find_thread_class(*(uint *)(param_1 + 0x52)); if (pPVar3 == (PFS_thread_class *)0x0) { local_30 = (PFS_thread *)0x0; } else { local_30 = (PFS_thread *)create_thread(pPVar3,(void *)param_1[0x53],0); if (local_30 != (PFS_thread *)0x0) { clear_thread_account(local_30); *(int8 *)(local_30 + 0x858) = *param_1; memcpy(local_30 + 0xcdc,param_1 + 1,0x180); *(int4 *)(local_30 + 0xe5c) = *(int4 *)(param_1 + 0x31); memcpy(local_30 + 0xe60,(void *)((long)param_1 + 0x18c),0xff); *(int4 *)(local_30 + 0xf60) = *(int4 *)((long)param_1 + 0x28c); set_thread_account(local_30); } } my_thread_set_THR_PFS(local_30); pcVar1 = (code *)param_1[0x54]; uVar2 = param_1[0x55]; my_free(param_1); (*pcVar1)(uVar2); return 0; }
20,506
link_to_changed_list
eloqsql/storage/maria/ma_pagecache.c
static inline void link_to_changed_list(PAGECACHE *pagecache, PAGECACHE_BLOCK_LINK *block) { unlink_changed(block); link_changed(block, &pagecache->changed_blocks[FILE_HASH(block->hash_link->file, pagecache)]); block->status|=PCBLOCK_CHANGED; pagecache->blocks_changed++; pagecache->global_blocks_changed++; }
O0
c
link_to_changed_list: pushq %rbp movq %rsp, %rbp subq $0x10, %rsp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq -0x10(%rbp), %rdi callq 0x40500 movq -0x10(%rbp), %rdi movq -0x8(%rbp), %rax movq 0x128(%rax), %rsi movq -0x10(%rbp), %rax movq 0x20(%rax), %rax movl 0x28(%rax), %eax movq -0x8(%rbp), %rcx movq 0x28(%rcx), %rcx subq $0x1, %rcx andq %rcx, %rax shlq $0x3, %rax addq %rax, %rsi callq 0x40600 movq -0x10(%rbp), %rax movzwl 0x74(%rax), %ecx orl $0x20, %ecx movw %cx, 0x74(%rax) movq -0x8(%rbp), %rax movq 0x58(%rax), %rcx addq $0x1, %rcx movq %rcx, 0x58(%rax) movq -0x8(%rbp), %rax movq 0x168(%rax), %rcx addq $0x1, %rcx movq %rcx, 0x168(%rax) addq $0x10, %rsp popq %rbp retq nopl (%rax)
link_to_changed_list: push rbp mov rbp, rsp sub rsp, 10h mov [rbp+var_8], rdi mov [rbp+var_10], rsi mov rdi, [rbp+var_10] call unlink_changed mov rdi, [rbp+var_10] mov rax, [rbp+var_8] mov rsi, [rax+128h] mov rax, [rbp+var_10] mov rax, [rax+20h] mov eax, [rax+28h] mov rcx, [rbp+var_8] mov rcx, [rcx+28h] sub rcx, 1 and rax, rcx shl rax, 3 add rsi, rax call link_changed mov rax, [rbp+var_10] movzx ecx, word ptr [rax+74h] or ecx, 20h mov [rax+74h], cx mov rax, [rbp+var_8] mov rcx, [rax+58h] add rcx, 1 mov [rax+58h], rcx mov rax, [rbp+var_8] mov rcx, [rax+168h] add rcx, 1 mov [rax+168h], rcx add rsp, 10h pop rbp retn
_QWORD * link_to_changed_list(_QWORD *a1, long long a2) { _QWORD *result; // rax unlink_changed(a2); link_changed(a2, 8 * ((a1[5] - 1LL) & *(unsigned int *)(*(_QWORD *)(a2 + 32) + 40LL)) + a1[37]); *(_WORD *)(a2 + 116) |= 0x20u; ++a1[11]; result = a1; ++a1[45]; return result; }
link_to_changed_list: PUSH RBP MOV RBP,RSP SUB RSP,0x10 MOV qword ptr [RBP + -0x8],RDI MOV qword ptr [RBP + -0x10],RSI MOV RDI,qword ptr [RBP + -0x10] CALL 0x00140500 MOV RDI,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RBP + -0x8] MOV RSI,qword ptr [RAX + 0x128] MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x20] MOV EAX,dword ptr [RAX + 0x28] MOV RCX,qword ptr [RBP + -0x8] MOV RCX,qword ptr [RCX + 0x28] SUB RCX,0x1 AND RAX,RCX SHL RAX,0x3 ADD RSI,RAX CALL 0x00140600 MOV RAX,qword ptr [RBP + -0x10] MOVZX ECX,word ptr [RAX + 0x74] OR ECX,0x20 MOV word ptr [RAX + 0x74],CX MOV RAX,qword ptr [RBP + -0x8] MOV RCX,qword ptr [RAX + 0x58] ADD RCX,0x1 MOV qword ptr [RAX + 0x58],RCX MOV RAX,qword ptr [RBP + -0x8] MOV RCX,qword ptr [RAX + 0x168] ADD RCX,0x1 MOV qword ptr [RAX + 0x168],RCX ADD RSP,0x10 POP RBP RET
void link_to_changed_list(long param_1,long param_2) { unlink_changed(param_2); link_changed(param_2,*(long *)(param_1 + 0x128) + ((ulong)*(uint *)(*(long *)(param_2 + 0x20) + 0x28) & *(long *)(param_1 + 0x28) - 1U) * 8); *(ushort *)(param_2 + 0x74) = *(ushort *)(param_2 + 0x74) | 0x20; *(long *)(param_1 + 0x58) = *(long *)(param_1 + 0x58) + 1; *(long *)(param_1 + 0x168) = *(long *)(param_1 + 0x168) + 1; return; }
20,507
ggml_compute_forward_map_unary_f32
Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml-cpu/ggml-cpu.c
static void ggml_compute_forward_map_unary_f32( const struct ggml_compute_params * params, struct ggml_tensor * dst, const ggml_unary_op_f32_t fun) { const struct ggml_tensor * src0 = dst->src[0]; if (params->ith != 0) { return; } assert(ggml_is_contiguous_1(src0)); assert(ggml_is_contiguous_1(dst)); assert(ggml_are_same_shape(src0, dst)); const int n = ggml_nrows(src0); const int nc = src0->ne[0]; for (int i = 0; i < n; i++) { fun(nc, (float *) ((char *) dst->data + i*( dst->nb[1])), (float *) ((char *) src0->data + i*(src0->nb[1]))); } }
O0
c
ggml_compute_forward_map_unary_f32: pushq %rbp movq %rsp, %rbp subq $0x30, %rsp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq %rdx, -0x18(%rbp) movq -0x10(%rbp), %rax movq 0x98(%rax), %rax movq %rax, -0x20(%rbp) movq -0x8(%rbp), %rax cmpl $0x0, (%rax) je 0x3ca21 jmp 0x3cb25 movq -0x20(%rbp), %rdi callq 0xd030 testb $0x1, %al jne 0x3ca30 jmp 0x3ca32 jmp 0x3ca51 leaq 0x381f0(%rip), %rdi # 0x74c29 leaq 0x37122(%rip), %rsi # 0x73b62 movl $0x2faf, %edx # imm = 0x2FAF leaq 0x396e0(%rip), %rcx # 0x7612c callq 0xd690 movq -0x10(%rbp), %rdi callq 0xd030 testb $0x1, %al jne 0x3ca60 jmp 0x3ca62 jmp 0x3ca81 leaq 0x381db(%rip), %rdi # 0x74c44 leaq 0x370f2(%rip), %rsi # 0x73b62 movl $0x2fb0, %edx # imm = 0x2FB0 leaq 0x396b0(%rip), %rcx # 0x7612c callq 0xd690 movq -0x20(%rbp), %rdi movq -0x10(%rbp), %rsi callq 0xe260 testb $0x1, %al jne 0x3ca94 jmp 0x3ca96 jmp 0x3cab5 leaq 0x3781d(%rip), %rdi # 0x742ba leaq 0x370be(%rip), %rsi # 0x73b62 movl $0x2fb1, %edx # imm = 0x2FB1 leaq 0x3967c(%rip), %rcx # 0x7612c callq 0xd690 movq -0x20(%rbp), %rdi callq 0xdc20 movl %eax, -0x24(%rbp) movq -0x20(%rbp), %rax movq 0x10(%rax), %rax movl %eax, -0x28(%rbp) movl $0x0, -0x2c(%rbp) movl -0x2c(%rbp), %eax cmpl -0x24(%rbp), %eax jge 0x3cb25 movq -0x18(%rbp), %rax movl -0x28(%rbp), %edi movq -0x10(%rbp), %rcx movq 0xf8(%rcx), %rsi movslq -0x2c(%rbp), %rcx movq -0x10(%rbp), %rdx imulq 0x38(%rdx), %rcx addq %rcx, %rsi movq -0x20(%rbp), %rcx movq 0xf8(%rcx), %rdx movslq -0x2c(%rbp), %rcx movq -0x20(%rbp), %r8 imulq 0x38(%r8), %rcx addq %rcx, %rdx callq *%rax movl -0x2c(%rbp), %eax addl $0x1, %eax movl %eax, -0x2c(%rbp) jmp 0x3cad3 addq $0x30, %rsp popq %rbp retq nopl (%rax,%rax)
ggml_compute_forward_map_unary_f32: push rbp mov rbp, rsp sub rsp, 30h mov [rbp+var_8], rdi mov [rbp+var_10], rsi mov [rbp+var_18], rdx mov rax, [rbp+var_10] mov rax, [rax+98h] mov [rbp+var_20], rax mov rax, [rbp+var_8] cmp dword ptr [rax], 0 jz short loc_3CA21 jmp loc_3CB25 loc_3CA21: mov rdi, [rbp+var_20] call _ggml_is_contiguous_1 test al, 1 jnz short loc_3CA30 jmp short loc_3CA32 loc_3CA30: jmp short loc_3CA51 loc_3CA32: lea rdi, aGgmlIsContiguo_3; "ggml_is_contiguous_1(src0)" lea rsi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github/2025_star3"... mov edx, 2FAFh lea rcx, aVoidGgmlComput_40; "void ggml_compute_forward_map_unary_f32"... call ___assert_fail loc_3CA51: mov rdi, [rbp+var_10] call _ggml_is_contiguous_1 test al, 1 jnz short loc_3CA60 jmp short loc_3CA62 loc_3CA60: jmp short loc_3CA81 loc_3CA62: lea rdi, aGgmlIsContiguo_4; "ggml_is_contiguous_1(dst)" lea rsi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github/2025_star3"... mov edx, 2FB0h lea rcx, aVoidGgmlComput_40; "void ggml_compute_forward_map_unary_f32"... call ___assert_fail loc_3CA81: mov rdi, [rbp+var_20] mov rsi, [rbp+var_10] call _ggml_are_same_shape test al, 1 jnz short loc_3CA94 jmp short loc_3CA96 loc_3CA94: jmp short loc_3CAB5 loc_3CA96: lea rdi, aGgmlCanRepeatS+1Fh; "ggml_are_same_shape(src0, dst)" lea rsi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github/2025_star3"... mov edx, 2FB1h lea rcx, aVoidGgmlComput_40; "void ggml_compute_forward_map_unary_f32"... call ___assert_fail loc_3CAB5: mov rdi, [rbp+var_20] call _ggml_nrows mov [rbp+var_24], eax mov rax, [rbp+var_20] mov rax, [rax+10h] mov [rbp+var_28], eax mov [rbp+var_2C], 0 loc_3CAD3: mov eax, [rbp+var_2C] cmp eax, [rbp+var_24] jge short loc_3CB25 mov rax, [rbp+var_18] mov edi, [rbp+var_28] mov rcx, [rbp+var_10] mov rsi, [rcx+0F8h] movsxd rcx, [rbp+var_2C] mov rdx, [rbp+var_10] imul rcx, [rdx+38h] add rsi, rcx mov rcx, [rbp+var_20] mov rdx, [rcx+0F8h] movsxd rcx, [rbp+var_2C] mov r8, [rbp+var_20] imul rcx, [r8+38h] add rdx, rcx call rax mov eax, [rbp+var_2C] add eax, 1 mov [rbp+var_2C], eax jmp short loc_3CAD3 loc_3CB25: add rsp, 30h pop rbp retn
unsigned long long ggml_compute_forward_map_unary_f32( _DWORD *a1, _QWORD *a2, void ( *a3)(_QWORD, _QWORD, _QWORD)) { unsigned long long result; // rax unsigned int i; // [rsp+4h] [rbp-2Ch] unsigned int v5; // [rsp+8h] [rbp-28h] int v6; // [rsp+Ch] [rbp-24h] _QWORD *v7; // [rsp+10h] [rbp-20h] v7 = (_QWORD *)a2[19]; result = (unsigned long long)a1; if ( !*a1 ) { if ( (ggml_is_contiguous_1(v7) & 1) == 0 ) __assert_fail( "ggml_is_contiguous_1(src0)", "/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml-cpu/ggml-cpu.c", 12207LL, "void ggml_compute_forward_map_unary_f32(const struct ggml_compute_params *, struct ggml_tensor *, const ggml_unary_op_f32_t)"); if ( (ggml_is_contiguous_1(a2) & 1) == 0 ) __assert_fail( "ggml_is_contiguous_1(dst)", "/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml-cpu/ggml-cpu.c", 12208LL, "void ggml_compute_forward_map_unary_f32(const struct ggml_compute_params *, struct ggml_tensor *, const ggml_unary_op_f32_t)"); if ( (ggml_are_same_shape(v7, a2) & 1) == 0 ) __assert_fail( "ggml_are_same_shape(src0, dst)", "/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml-cpu/ggml-cpu.c", 12209LL, "void ggml_compute_forward_map_unary_f32(const struct ggml_compute_params *, struct ggml_tensor *, const ggml_unary_op_f32_t)"); v6 = ggml_nrows(v7); v5 = v7[2]; for ( i = 0; ; ++i ) { result = i; if ( (int)i >= v6 ) break; a3(v5, a2[7] * (int)i + a2[31], v7[7] * (int)i + v7[31]); } } return result; }
ggml_compute_forward_map_unary_f32: PUSH RBP MOV RBP,RSP SUB RSP,0x30 MOV qword ptr [RBP + -0x8],RDI MOV qword ptr [RBP + -0x10],RSI MOV qword ptr [RBP + -0x18],RDX MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x98] MOV qword ptr [RBP + -0x20],RAX MOV RAX,qword ptr [RBP + -0x8] CMP dword ptr [RAX],0x0 JZ 0x0013ca21 JMP 0x0013cb25 LAB_0013ca21: MOV RDI,qword ptr [RBP + -0x20] CALL 0x0010d030 TEST AL,0x1 JNZ 0x0013ca30 JMP 0x0013ca32 LAB_0013ca30: JMP 0x0013ca51 LAB_0013ca32: LEA RDI,[0x174c29] LEA RSI,[0x173b62] MOV EDX,0x2faf LEA RCX,[0x17612c] CALL 0x0010d690 LAB_0013ca51: MOV RDI,qword ptr [RBP + -0x10] CALL 0x0010d030 TEST AL,0x1 JNZ 0x0013ca60 JMP 0x0013ca62 LAB_0013ca60: JMP 0x0013ca81 LAB_0013ca62: LEA RDI,[0x174c44] LEA RSI,[0x173b62] MOV EDX,0x2fb0 LEA RCX,[0x17612c] CALL 0x0010d690 LAB_0013ca81: MOV RDI,qword ptr [RBP + -0x20] MOV RSI,qword ptr [RBP + -0x10] CALL 0x0010e260 TEST AL,0x1 JNZ 0x0013ca94 JMP 0x0013ca96 LAB_0013ca94: JMP 0x0013cab5 LAB_0013ca96: LEA RDI,[0x1742ba] LEA RSI,[0x173b62] MOV EDX,0x2fb1 LEA RCX,[0x17612c] CALL 0x0010d690 LAB_0013cab5: MOV RDI,qword ptr [RBP + -0x20] CALL 0x0010dc20 MOV dword ptr [RBP + -0x24],EAX MOV RAX,qword ptr [RBP + -0x20] MOV RAX,qword ptr [RAX + 0x10] MOV dword ptr [RBP + -0x28],EAX MOV dword ptr [RBP + -0x2c],0x0 LAB_0013cad3: MOV EAX,dword ptr [RBP + -0x2c] CMP EAX,dword ptr [RBP + -0x24] JGE 0x0013cb25 MOV RAX,qword ptr [RBP + -0x18] MOV EDI,dword ptr [RBP + -0x28] MOV RCX,qword ptr [RBP + -0x10] MOV RSI,qword ptr [RCX + 0xf8] MOVSXD RCX,dword ptr [RBP + -0x2c] MOV RDX,qword ptr [RBP + -0x10] IMUL RCX,qword ptr [RDX + 0x38] ADD RSI,RCX MOV RCX,qword ptr [RBP + -0x20] MOV RDX,qword ptr [RCX + 0xf8] MOVSXD RCX,dword ptr [RBP + -0x2c] MOV R8,qword ptr [RBP + -0x20] IMUL RCX,qword ptr [R8 + 0x38] ADD RDX,RCX CALL RAX MOV EAX,dword ptr [RBP + -0x2c] ADD EAX,0x1 MOV dword ptr [RBP + -0x2c],EAX JMP 0x0013cad3 LAB_0013cb25: ADD RSP,0x30 POP RBP RET
void ggml_compute_forward_map_unary_f32(int *param_1,long param_2,code *param_3) { long lVar1; int8 uVar2; int iVar3; ulong uVar4; int local_34; lVar1 = *(long *)(param_2 + 0x98); if (*param_1 == 0) { uVar4 = ggml_is_contiguous_1(lVar1); if ((uVar4 & 1) == 0) { /* WARNING: Subroutine does not return */ __assert_fail("ggml_is_contiguous_1(src0)", "/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml-cpu/ggml-cpu.c" ,0x2faf, "void ggml_compute_forward_map_unary_f32(const struct ggml_compute_params *, struct ggml_tensor *, const ggml_unary_op_f32_t)" ); } uVar4 = ggml_is_contiguous_1(param_2); if ((uVar4 & 1) == 0) { /* WARNING: Subroutine does not return */ __assert_fail("ggml_is_contiguous_1(dst)", "/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml-cpu/ggml-cpu.c" ,0x2fb0, "void ggml_compute_forward_map_unary_f32(const struct ggml_compute_params *, struct ggml_tensor *, const ggml_unary_op_f32_t)" ); } uVar4 = ggml_are_same_shape(lVar1,param_2); if ((uVar4 & 1) == 0) { /* WARNING: Subroutine does not return */ __assert_fail("ggml_are_same_shape(src0, dst)", "/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml-cpu/ggml-cpu.c" ,0x2fb1, "void ggml_compute_forward_map_unary_f32(const struct ggml_compute_params *, struct ggml_tensor *, const ggml_unary_op_f32_t)" ); } iVar3 = ggml_nrows(lVar1); uVar2 = *(int8 *)(lVar1 + 0x10); for (local_34 = 0; local_34 < iVar3; local_34 = local_34 + 1) { (*param_3)((int)uVar2,*(long *)(param_2 + 0xf8) + (long)local_34 * *(long *)(param_2 + 0x38), *(long *)(lVar1 + 0xf8) + (long)local_34 * *(long *)(lVar1 + 0x38)); } } return; }
20,508
Item_func_neg::fix_length_and_dec_double()
eloqsql/sql/item_func.cc
void Item_func_neg::fix_length_and_dec_double() { set_handler(&type_handler_double); decimals= args[0]->decimals; // Preserve NOT_FIXED_DEC max_length= args[0]->max_length + 1; // Limit length with something reasonable uint32 mlen= type_handler()->max_display_length(this); set_if_smaller(max_length, mlen); unsigned_flag= false; }
O0
cpp
Item_func_neg::fix_length_and_dec_double(): pushq %rbp movq %rsp, %rbp subq $0x20, %rsp movq %rdi, -0x8(%rbp) movq -0x8(%rbp), %rdi movq %rdi, -0x18(%rbp) addq $0xa8, %rdi leaq 0xc941ce(%rip), %rsi # 0x15ee220 callq 0x4eeca0 movq -0x18(%rbp), %rdi movq 0x70(%rdi), %rax movq (%rax), %rax movw 0xc(%rax), %ax movw %ax, 0xc(%rdi) movq 0x70(%rdi), %rax movq (%rax), %rax movl 0x8(%rax), %eax addl $0x1, %eax movl %eax, 0x8(%rdi) movq (%rdi), %rax callq *0xa8(%rax) movq -0x18(%rbp), %rsi movq %rax, %rdi movq (%rdi), %rax callq *0x2e0(%rax) movl %eax, -0xc(%rbp) movq -0x18(%rbp), %rax movl 0x8(%rax), %eax cmpl -0xc(%rbp), %eax jbe 0x95a0ac movq -0x18(%rbp), %rax movl -0xc(%rbp), %ecx movl %ecx, 0x8(%rax) jmp 0x95a0ae movq -0x18(%rbp), %rax movb $0x0, 0xe(%rax) addq $0x20, %rsp popq %rbp retq nopl (%rax)
_ZN13Item_func_neg25fix_length_and_dec_doubleEv: push rbp mov rbp, rsp sub rsp, 20h mov [rbp+var_8], rdi mov rdi, [rbp+var_8] mov [rbp+var_18], rdi add rdi, 0A8h; this lea rsi, type_handler_double; Type_handler * call _ZN30Type_handler_hybrid_field_type11set_handlerEPK12Type_handler; Type_handler_hybrid_field_type::set_handler(Type_handler const*) mov rdi, [rbp+var_18] mov rax, [rdi+70h] mov rax, [rax] mov ax, [rax+0Ch] mov [rdi+0Ch], ax mov rax, [rdi+70h] mov rax, [rax] mov eax, [rax+8] add eax, 1 mov [rdi+8], eax mov rax, [rdi] call qword ptr [rax+0A8h] mov rsi, [rbp+var_18] mov rdi, rax mov rax, [rdi] call qword ptr [rax+2E0h] mov [rbp+var_C], eax mov rax, [rbp+var_18] mov eax, [rax+8] cmp eax, [rbp+var_C] jbe short loc_95A0AC mov rax, [rbp+var_18] mov ecx, [rbp+var_C] mov [rax+8], ecx loc_95A0AC: jmp short $+2 loc_95A0AE: mov rax, [rbp+var_18] mov byte ptr [rax+0Eh], 0 add rsp, 20h pop rbp retn
Item_func_neg * Item_func_neg::fix_length_and_dec_double(Item_func_neg *this) { long long v1; // rax Item_func_neg *result; // rax unsigned int v3; // [rsp+14h] [rbp-Ch] Type_handler_hybrid_field_type::set_handler( (Item_func_neg *)((char *)this + 168), (const Type_handler *)&type_handler_double); *((_WORD *)this + 6) = *(_WORD *)(**((_QWORD **)this + 14) + 12LL); *((_DWORD *)this + 2) = *(_DWORD *)(**((_QWORD **)this + 14) + 8LL) + 1; v1 = (*(long long ( **)(Item_func_neg *))(*(_QWORD *)this + 168LL))(this); v3 = (*(long long ( **)(long long, Item_func_neg *))(*(_QWORD *)v1 + 736LL))(v1, this); if ( *((_DWORD *)this + 2) > v3 ) *((_DWORD *)this + 2) = v3; result = this; *((_BYTE *)this + 14) = 0; return result; }
Item_func_if: PUSH RBP MOV RBP,RSP SUB RSP,0x30 MOV qword ptr [RBP + -0x8],RDI MOV qword ptr [RBP + -0x10],RSI MOV qword ptr [RBP + -0x18],RDX MOV qword ptr [RBP + -0x20],RCX MOV qword ptr [RBP + -0x28],R8 MOV RDI,qword ptr [RBP + -0x8] MOV qword ptr [RBP + -0x30],RDI MOV RSI,qword ptr [RBP + -0x10] MOV RDX,qword ptr [RBP + -0x18] MOV RCX,qword ptr [RBP + -0x20] MOV R8,qword ptr [RBP + -0x28] CALL 0x0095f570 MOV RAX,qword ptr [RBP + -0x30] LEA RCX,[0x141e6d8] ADD RCX,0x10 MOV qword ptr [RAX],RCX ADD RSP,0x30 POP RBP RET
/* Item_func_if::Item_func_if(THD*, Item*, Item*, Item*) */ void __thiscall Item_func_if::Item_func_if (Item_func_if *this,THD *param_1,Item *param_2,Item *param_3,Item *param_4) { Item_func_case_abbreviation2_switch::Item_func_case_abbreviation2_switch ((Item_func_case_abbreviation2_switch *)this,param_1,param_2,param_3,param_4); *(int ***)this = &PTR__Item_func_if_0141e6e8; return; }
20,509
OpenSubdiv::v3_6_0::Far::PatchTableBuilder::estimateLocalPointCount(OpenSubdiv::v3_6_0::Far::PatchTableBuilder::LocalPointHelper::Options const&, int) const
NVIDIA-RTX[P]OSD-Lite/opensubdiv/far/patchTableFactory.cpp
int PatchTableBuilder::estimateLocalPointCount( LocalPointHelper::Options const & options, int fvarChannel) const { if ((fvarChannel >= 0) && isFVarChannelLinear(fvarChannel)) return 0; // // Estimate the local points required for the Vertex topology in all cases // as it may be used in the estimates for face-varying channels: // int estLocalPoints = 0; if (_requiresRegularLocalPoints) { // // Either all regular patches are being converted to a non-native // basis, or boundary points are being extrapolated in the regular // basis. The latter case typically involves a small fraction of // patches and points, so we don't estimate any local points and // leave it up to incremental allocation later to account for them. // int numPointsPerPatch = PatchDescriptor( _patchBuilder->GetRegularPatchType()).GetNumControlVertices(); if (_patchBuilder->GetRegularPatchType() != _patchBuilder->GetNativePatchType()) { estLocalPoints += _numRegularPatches * numPointsPerPatch; } } if (_requiresIrregularLocalPoints) { bool oldEstimate = false; int numIrregularPatches = oldEstimate ? _refiner.GetLevel(_refiner.GetMaxLevel()).GetNumFaces() : _numIrregularPatches; // // If converting to a basis other than regular, its difficult to // predict the degree of point-sharing that may occur, and in general, // the maximal benefit is small so we don't attempt to compensate for // it here. If converting to the same basis as regular, roughly half // of the points of the patch are involved in approximating the // irregularity (and cannot be shared) so don't include the source // points that will be used in such patches. // int numPointsPerPatch = PatchDescriptor( _patchBuilder->GetIrregularPatchType()).GetNumControlVertices(); if (options.reuseSourcePoints && (_patchBuilder->GetIrregularPatchType() == _patchBuilder->GetNativePatchType())) { numPointsPerPatch /= 2; } estLocalPoints += numIrregularPatches * numPointsPerPatch; } // // Its difficult to estimate the differences in number of irregularities // between the vertex topology and a face-varying channel without more // detailed inspection. // // A much higher number of fvar-values than vertices is an indication that // the number of differences increases, and that generally lowers the // number of irregular patches due to more regular patches on face-varying // boundaries, but not always. The use of some interpolation types, e.g. // LINEAR_BOUNDARIES, combined with inf-sharp patches can increase the // number of irregularities significantly. // if ((fvarChannel >= 0) && (_refiner.GetNumLevels() > 1)) { // // We're seeing face-varying stencil table sizes about 1/4 the size of // the vertex stencil table for what seem like typical cases... // // Identify the ratio of fvar-values to vertices that typically leads // to these reductions and reduce the number of expected local points // proportionally. Use the number of fvar-values at level 1: level 0 // can be misleading as there can be many FEWER than the number of // vertices, but subsequent levels will have at least one unique // fvar-value per vertex, and later levels will have a much higher // percentage shared as a result of refinement. // int fvc = getRefinerFVarChannel(fvarChannel); if (_refiner.GetLevel(1).GetNumFVarValues(fvc) > _refiner.GetLevel(1).GetNumVertices()) { // Scale this based on ratio of fvar-values to vertices... float fvarReduction = 0.5; estLocalPoints = (int) ((float)estLocalPoints * fvarReduction); } } return estLocalPoints; }
O0
cpp
OpenSubdiv::v3_6_0::Far::PatchTableBuilder::estimateLocalPointCount(OpenSubdiv::v3_6_0::Far::PatchTableBuilder::LocalPointHelper::Options const&, int) const: pushq %rbp movq %rsp, %rbp subq $0x60, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movl %edx, -0x1c(%rbp) movq -0x10(%rbp), %rax movq %rax, -0x48(%rbp) cmpl $0x0, -0x1c(%rbp) jl 0x14b6cf movq -0x48(%rbp), %rdi movl -0x1c(%rbp), %esi callq 0xd26e0 testb $0x1, %al jne 0x14b6c3 jmp 0x14b6cf movl $0x0, -0x4(%rbp) jmp 0x14b8ba movq -0x48(%rbp), %rax movl $0x0, -0x20(%rbp) movb 0x28(%rax), %al shrb %al andb $0x1, %al movzbl %al, %eax cmpl $0x0, %eax je 0x14b74e movq -0x48(%rbp), %rax movq 0x38(%rax), %rdi callq 0xcc640 movl %eax, %esi leaq -0x28(%rbp), %rdi callq 0xd21a0 leaq -0x28(%rbp), %rdi callq 0xd7430 movw %ax, %cx movq -0x48(%rbp), %rax movswl %cx, %ecx movl %ecx, -0x24(%rbp) movq 0x38(%rax), %rdi callq 0xcc640 movl %eax, %ecx movq -0x48(%rbp), %rax movl %ecx, -0x4c(%rbp) movq 0x38(%rax), %rdi callq 0xc74c0 movl %eax, %ecx movl -0x4c(%rbp), %eax cmpl %ecx, %eax je 0x14b74c movq -0x48(%rbp), %rax movl 0x70(%rax), %eax imull -0x24(%rbp), %eax addl -0x20(%rbp), %eax movl %eax, -0x20(%rbp) jmp 0x14b74e movq -0x48(%rbp), %rax movb 0x28(%rax), %al shrb $0x2, %al andb $0x1, %al movzbl %al, %eax cmpl $0x0, %eax je 0x14b825 movb $0x0, -0x29(%rbp) testb $0x1, -0x29(%rbp) je 0x14b79b movq -0x48(%rbp), %rax movq (%rax), %rcx movq %rcx, -0x58(%rbp) movq (%rax), %rdi callq 0xcb3f0 movq -0x58(%rbp), %rdi movl %eax, %esi callq 0xc3d80 movq %rax, %rdi callq 0xd5070 movl %eax, -0x50(%rbp) jmp 0x14b7a5 movq -0x48(%rbp), %rax movl 0x74(%rax), %eax movl %eax, -0x50(%rbp) movq -0x48(%rbp), %rax movl -0x50(%rbp), %ecx movl %ecx, -0x30(%rbp) movq 0x38(%rax), %rdi callq 0xceec0 movl %eax, %esi leaq -0x38(%rbp), %rdi callq 0xd21a0 leaq -0x38(%rbp), %rdi callq 0xd7430 cwtl movl %eax, -0x34(%rbp) movq -0x18(%rbp), %rax movb (%rax), %al shrb %al andb $0x1, %al movzbl %al, %eax cmpl $0x0, %eax je 0x14b818 movq -0x48(%rbp), %rax movq 0x38(%rax), %rdi callq 0xceec0 movl %eax, %ecx movq -0x48(%rbp), %rax movl %ecx, -0x5c(%rbp) movq 0x38(%rax), %rdi callq 0xc74c0 movl %eax, %ecx movl -0x5c(%rbp), %eax cmpl %ecx, %eax jne 0x14b818 movl -0x34(%rbp), %eax movl $0x2, %ecx cltd idivl %ecx movl %eax, -0x34(%rbp) movl -0x30(%rbp), %eax imull -0x34(%rbp), %eax addl -0x20(%rbp), %eax movl %eax, -0x20(%rbp) cmpl $0x0, -0x1c(%rbp) jl 0x14b8b4 movq -0x48(%rbp), %rax movq (%rax), %rdi callq 0xc94f0 cmpl $0x1, %eax jle 0x14b8b4 movq -0x48(%rbp), %rdi movl -0x1c(%rbp), %esi callq 0xd6f00 movl %eax, %ecx movq -0x48(%rbp), %rax movl %ecx, -0x3c(%rbp) movq (%rax), %rdi movl $0x1, %esi callq 0xc3d80 movq %rax, %rdi movl -0x3c(%rbp), %esi callq 0xc6a70 movl %eax, %ecx movq -0x48(%rbp), %rax movl %ecx, -0x60(%rbp) movq (%rax), %rdi movl $0x1, %esi callq 0xc3d80 movq %rax, %rdi callq 0xc6ce0 movl %eax, %ecx movl -0x60(%rbp), %eax cmpl %ecx, %eax jle 0x14b8b2 movss 0xa2720(%rip), %xmm0 # 0x1edfbc movss %xmm0, -0x40(%rbp) cvtsi2ssl -0x20(%rbp), %xmm0 mulss -0x40(%rbp), %xmm0 cvttss2si %xmm0, %eax movl %eax, -0x20(%rbp) jmp 0x14b8b4 movl -0x20(%rbp), %eax movl %eax, -0x4(%rbp) movl -0x4(%rbp), %eax addq $0x60, %rsp popq %rbp retq nopw %cs:(%rax,%rax)
_ZNK10OpenSubdiv6v3_6_03Far17PatchTableBuilder23estimateLocalPointCountERKNS2_16LocalPointHelper7OptionsEi: push rbp mov rbp, rsp sub rsp, 60h mov [rbp+var_10], rdi mov [rbp+var_18], rsi mov [rbp+var_1C], edx mov rax, [rbp+var_10] mov [rbp+var_48], rax cmp [rbp+var_1C], 0 jl short loc_14B6CF mov rdi, [rbp+var_48]; this mov esi, [rbp+var_1C]; int call __ZNK10OpenSubdiv6v3_6_03Far17PatchTableBuilder19isFVarChannelLinearEi; OpenSubdiv::v3_6_0::Far::PatchTableBuilder::isFVarChannelLinear(int) test al, 1 jnz short loc_14B6C3 jmp short loc_14B6CF loc_14B6C3: mov [rbp+var_4], 0 jmp loc_14B8BA loc_14B6CF: mov rax, [rbp+var_48] mov [rbp+var_20], 0 mov al, [rax+28h] shr al, 1 and al, 1 movzx eax, al cmp eax, 0 jz short loc_14B74E mov rax, [rbp+var_48] mov rdi, [rax+38h]; this call __ZNK10OpenSubdiv6v3_6_03Far12PatchBuilder19GetRegularPatchTypeEv; OpenSubdiv::v3_6_0::Far::PatchBuilder::GetRegularPatchType(void) mov esi, eax; int lea rdi, [rbp+var_28]; this call __ZN10OpenSubdiv6v3_6_03Far15PatchDescriptorC2Ei; OpenSubdiv::v3_6_0::Far::PatchDescriptor::PatchDescriptor(int) lea rdi, [rbp+var_28]; this call __ZNK10OpenSubdiv6v3_6_03Far15PatchDescriptor21GetNumControlVerticesEv; OpenSubdiv::v3_6_0::Far::PatchDescriptor::GetNumControlVertices(void) mov cx, ax mov rax, [rbp+var_48] movsx ecx, cx mov [rbp+var_24], ecx mov rdi, [rax+38h]; this call __ZNK10OpenSubdiv6v3_6_03Far12PatchBuilder19GetRegularPatchTypeEv; OpenSubdiv::v3_6_0::Far::PatchBuilder::GetRegularPatchType(void) mov ecx, eax mov rax, [rbp+var_48] mov [rbp+var_4C], ecx mov rdi, [rax+38h]; this call __ZNK10OpenSubdiv6v3_6_03Far12PatchBuilder18GetNativePatchTypeEv; OpenSubdiv::v3_6_0::Far::PatchBuilder::GetNativePatchType(void) mov ecx, eax mov eax, [rbp+var_4C] cmp eax, ecx jz short loc_14B74C mov rax, [rbp+var_48] mov eax, [rax+70h] imul eax, [rbp+var_24] add eax, [rbp+var_20] mov [rbp+var_20], eax loc_14B74C: jmp short $+2 loc_14B74E: mov rax, [rbp+var_48] mov al, [rax+28h] shr al, 2 and al, 1 movzx eax, al cmp eax, 0 jz loc_14B825 mov [rbp+var_29], 0 test [rbp+var_29], 1 jz short loc_14B79B mov rax, [rbp+var_48] mov rcx, [rax] mov [rbp+var_58], rcx mov rdi, [rax]; this call __ZNK10OpenSubdiv6v3_6_03Far15TopologyRefiner11GetMaxLevelEv; OpenSubdiv::v3_6_0::Far::TopologyRefiner::GetMaxLevel(void) mov rdi, [rbp+var_58]; this mov esi, eax; int call __ZNK10OpenSubdiv6v3_6_03Far15TopologyRefiner8GetLevelEi; OpenSubdiv::v3_6_0::Far::TopologyRefiner::GetLevel(int) mov rdi, rax; this call __ZNK10OpenSubdiv6v3_6_03Far13TopologyLevel11GetNumFacesEv; OpenSubdiv::v3_6_0::Far::TopologyLevel::GetNumFaces(void) mov [rbp+var_50], eax jmp short loc_14B7A5 loc_14B79B: mov rax, [rbp+var_48] mov eax, [rax+74h] mov [rbp+var_50], eax loc_14B7A5: mov rax, [rbp+var_48] mov ecx, [rbp+var_50] mov [rbp+var_30], ecx mov rdi, [rax+38h]; this call __ZNK10OpenSubdiv6v3_6_03Far12PatchBuilder21GetIrregularPatchTypeEv; OpenSubdiv::v3_6_0::Far::PatchBuilder::GetIrregularPatchType(void) mov esi, eax; int lea rdi, [rbp+var_38]; this call __ZN10OpenSubdiv6v3_6_03Far15PatchDescriptorC2Ei; OpenSubdiv::v3_6_0::Far::PatchDescriptor::PatchDescriptor(int) lea rdi, [rbp+var_38]; this call __ZNK10OpenSubdiv6v3_6_03Far15PatchDescriptor21GetNumControlVerticesEv; OpenSubdiv::v3_6_0::Far::PatchDescriptor::GetNumControlVertices(void) cwde mov [rbp+var_34], eax mov rax, [rbp+var_18] mov al, [rax] shr al, 1 and al, 1 movzx eax, al cmp eax, 0 jz short loc_14B818 mov rax, [rbp+var_48] mov rdi, [rax+38h]; this call __ZNK10OpenSubdiv6v3_6_03Far12PatchBuilder21GetIrregularPatchTypeEv; OpenSubdiv::v3_6_0::Far::PatchBuilder::GetIrregularPatchType(void) mov ecx, eax mov rax, [rbp+var_48] mov [rbp+var_5C], ecx mov rdi, [rax+38h]; this call __ZNK10OpenSubdiv6v3_6_03Far12PatchBuilder18GetNativePatchTypeEv; OpenSubdiv::v3_6_0::Far::PatchBuilder::GetNativePatchType(void) mov ecx, eax mov eax, [rbp+var_5C] cmp eax, ecx jnz short loc_14B818 mov eax, [rbp+var_34] mov ecx, 2 cdq idiv ecx mov [rbp+var_34], eax loc_14B818: mov eax, [rbp+var_30] imul eax, [rbp+var_34] add eax, [rbp+var_20] mov [rbp+var_20], eax loc_14B825: cmp [rbp+var_1C], 0 jl loc_14B8B4 mov rax, [rbp+var_48] mov rdi, [rax]; this call __ZNK10OpenSubdiv6v3_6_03Far15TopologyRefiner12GetNumLevelsEv; OpenSubdiv::v3_6_0::Far::TopologyRefiner::GetNumLevels(void) cmp eax, 1 jle short loc_14B8B4 mov rdi, [rbp+var_48]; this mov esi, [rbp+var_1C]; int call __ZNK10OpenSubdiv6v3_6_03Far17PatchTableBuilder21getRefinerFVarChannelEi; OpenSubdiv::v3_6_0::Far::PatchTableBuilder::getRefinerFVarChannel(int) mov ecx, eax mov rax, [rbp+var_48] mov [rbp+var_3C], ecx mov rdi, [rax]; this mov esi, 1; int call __ZNK10OpenSubdiv6v3_6_03Far15TopologyRefiner8GetLevelEi; OpenSubdiv::v3_6_0::Far::TopologyRefiner::GetLevel(int) mov rdi, rax; this mov esi, [rbp+var_3C]; int call __ZNK10OpenSubdiv6v3_6_03Far13TopologyLevel16GetNumFVarValuesEi; OpenSubdiv::v3_6_0::Far::TopologyLevel::GetNumFVarValues(int) mov ecx, eax mov rax, [rbp+var_48] mov [rbp+var_60], ecx mov rdi, [rax]; this mov esi, 1; int call __ZNK10OpenSubdiv6v3_6_03Far15TopologyRefiner8GetLevelEi; OpenSubdiv::v3_6_0::Far::TopologyRefiner::GetLevel(int) mov rdi, rax; this call __ZNK10OpenSubdiv6v3_6_03Far13TopologyLevel14GetNumVerticesEv; OpenSubdiv::v3_6_0::Far::TopologyLevel::GetNumVertices(void) mov ecx, eax mov eax, [rbp+var_60] cmp eax, ecx jle short loc_14B8B2 movss xmm0, cs:dword_1EDFBC movss [rbp+var_40], xmm0 cvtsi2ss xmm0, [rbp+var_20] mulss xmm0, [rbp+var_40] cvttss2si eax, xmm0 mov [rbp+var_20], eax loc_14B8B2: jmp short $+2 loc_14B8B4: mov eax, [rbp+var_20] mov [rbp+var_4], eax loc_14B8BA: mov eax, [rbp+var_4] add rsp, 60h pop rbp retn
long long OpenSubdiv::v3_6_0::Far::PatchTableBuilder::estimateLocalPointCount( OpenSubdiv::v3_6_0::Far::PatchBuilder **this, const OpenSubdiv::v3_6_0::Far::PatchTableBuilder::LocalPointHelper::Options *a2, int a3) { int RegularPatchType; // eax int IrregularPatchType; // eax OpenSubdiv::v3_6_0::Far::TopologyLevel *Level; // rax OpenSubdiv::v3_6_0::Far::TopologyLevel *v6; // rax int NumFVarValues; // [rsp+0h] [rbp-60h] int v9; // [rsp+4h] [rbp-5Ch] int v10; // [rsp+14h] [rbp-4Ch] int RefinerFVarChannel; // [rsp+24h] [rbp-3Ch] _BYTE v12[4]; // [rsp+28h] [rbp-38h] BYREF int v13; // [rsp+2Ch] [rbp-34h] int v14; // [rsp+30h] [rbp-30h] char v15; // [rsp+37h] [rbp-29h] _BYTE v16[4]; // [rsp+38h] [rbp-28h] BYREF int NumControlVertices; // [rsp+3Ch] [rbp-24h] int v18; // [rsp+40h] [rbp-20h] int v19; // [rsp+44h] [rbp-1Ch] const OpenSubdiv::v3_6_0::Far::PatchTableBuilder::LocalPointHelper::Options *v20; // [rsp+48h] [rbp-18h] OpenSubdiv::v3_6_0::Far::PatchBuilder **v21; // [rsp+50h] [rbp-10h] v21 = this; v20 = a2; v19 = a3; if ( a3 >= 0 && (OpenSubdiv::v3_6_0::Far::PatchTableBuilder::isFVarChannelLinear( (OpenSubdiv::v3_6_0::Far::PatchTableBuilder *)this, v19) & 1) != 0 ) { return 0; } else { v18 = 0; if ( ((_BYTE)this[5] & 2) != 0 ) { RegularPatchType = OpenSubdiv::v3_6_0::Far::PatchBuilder::GetRegularPatchType(this[7]); OpenSubdiv::v3_6_0::Far::PatchDescriptor::PatchDescriptor( (OpenSubdiv::v3_6_0::Far::PatchDescriptor *)v16, RegularPatchType); NumControlVertices = (__int16)OpenSubdiv::v3_6_0::Far::PatchDescriptor::GetNumControlVertices((OpenSubdiv::v3_6_0::Far::PatchDescriptor *)v16); v10 = OpenSubdiv::v3_6_0::Far::PatchBuilder::GetRegularPatchType(this[7]); if ( v10 != (unsigned int)OpenSubdiv::v3_6_0::Far::PatchBuilder::GetNativePatchType(this[7]) ) v18 += NumControlVertices * *((_DWORD *)this + 28); } if ( ((_BYTE)this[5] & 4) != 0 ) { v15 = 0; v14 = *((_DWORD *)this + 29); IrregularPatchType = OpenSubdiv::v3_6_0::Far::PatchBuilder::GetIrregularPatchType(this[7]); OpenSubdiv::v3_6_0::Far::PatchDescriptor::PatchDescriptor( (OpenSubdiv::v3_6_0::Far::PatchDescriptor *)v12, IrregularPatchType); v13 = (__int16)OpenSubdiv::v3_6_0::Far::PatchDescriptor::GetNumControlVertices((OpenSubdiv::v3_6_0::Far::PatchDescriptor *)v12); if ( (*(_BYTE *)v20 & 2) != 0 ) { v9 = OpenSubdiv::v3_6_0::Far::PatchBuilder::GetIrregularPatchType(this[7]); if ( v9 == (unsigned int)OpenSubdiv::v3_6_0::Far::PatchBuilder::GetNativePatchType(this[7]) ) v13 /= 2; } v18 += v13 * v14; } if ( v19 >= 0 && (int)OpenSubdiv::v3_6_0::Far::TopologyRefiner::GetNumLevels(*this) > 1 ) { RefinerFVarChannel = OpenSubdiv::v3_6_0::Far::PatchTableBuilder::getRefinerFVarChannel( (OpenSubdiv::v3_6_0::Far::PatchTableBuilder *)this, v19); Level = (OpenSubdiv::v3_6_0::Far::TopologyLevel *)OpenSubdiv::v3_6_0::Far::TopologyRefiner::GetLevel(*this, 1); NumFVarValues = OpenSubdiv::v3_6_0::Far::TopologyLevel::GetNumFVarValues(Level, RefinerFVarChannel); v6 = (OpenSubdiv::v3_6_0::Far::TopologyLevel *)OpenSubdiv::v3_6_0::Far::TopologyRefiner::GetLevel(*this, 1); if ( NumFVarValues > (int)OpenSubdiv::v3_6_0::Far::TopologyLevel::GetNumVertices(v6) ) return (unsigned int)(int)(float)((float)v18 * 0.5); } return (unsigned int)v18; } }
20,510
OpenSubdiv::v3_6_0::Far::PatchTableBuilder::estimateLocalPointCount(OpenSubdiv::v3_6_0::Far::PatchTableBuilder::LocalPointHelper::Options const&, int) const
NVIDIA-RTX[P]OSD-Lite/opensubdiv/far/patchTableFactory.cpp
int PatchTableBuilder::estimateLocalPointCount( LocalPointHelper::Options const & options, int fvarChannel) const { if ((fvarChannel >= 0) && isFVarChannelLinear(fvarChannel)) return 0; // // Estimate the local points required for the Vertex topology in all cases // as it may be used in the estimates for face-varying channels: // int estLocalPoints = 0; if (_requiresRegularLocalPoints) { // // Either all regular patches are being converted to a non-native // basis, or boundary points are being extrapolated in the regular // basis. The latter case typically involves a small fraction of // patches and points, so we don't estimate any local points and // leave it up to incremental allocation later to account for them. // int numPointsPerPatch = PatchDescriptor( _patchBuilder->GetRegularPatchType()).GetNumControlVertices(); if (_patchBuilder->GetRegularPatchType() != _patchBuilder->GetNativePatchType()) { estLocalPoints += _numRegularPatches * numPointsPerPatch; } } if (_requiresIrregularLocalPoints) { bool oldEstimate = false; int numIrregularPatches = oldEstimate ? _refiner.GetLevel(_refiner.GetMaxLevel()).GetNumFaces() : _numIrregularPatches; // // If converting to a basis other than regular, its difficult to // predict the degree of point-sharing that may occur, and in general, // the maximal benefit is small so we don't attempt to compensate for // it here. If converting to the same basis as regular, roughly half // of the points of the patch are involved in approximating the // irregularity (and cannot be shared) so don't include the source // points that will be used in such patches. // int numPointsPerPatch = PatchDescriptor( _patchBuilder->GetIrregularPatchType()).GetNumControlVertices(); if (options.reuseSourcePoints && (_patchBuilder->GetIrregularPatchType() == _patchBuilder->GetNativePatchType())) { numPointsPerPatch /= 2; } estLocalPoints += numIrregularPatches * numPointsPerPatch; } // // Its difficult to estimate the differences in number of irregularities // between the vertex topology and a face-varying channel without more // detailed inspection. // // A much higher number of fvar-values than vertices is an indication that // the number of differences increases, and that generally lowers the // number of irregular patches due to more regular patches on face-varying // boundaries, but not always. The use of some interpolation types, e.g. // LINEAR_BOUNDARIES, combined with inf-sharp patches can increase the // number of irregularities significantly. // if ((fvarChannel >= 0) && (_refiner.GetNumLevels() > 1)) { // // We're seeing face-varying stencil table sizes about 1/4 the size of // the vertex stencil table for what seem like typical cases... // // Identify the ratio of fvar-values to vertices that typically leads // to these reductions and reduce the number of expected local points // proportionally. Use the number of fvar-values at level 1: level 0 // can be misleading as there can be many FEWER than the number of // vertices, but subsequent levels will have at least one unique // fvar-value per vertex, and later levels will have a much higher // percentage shared as a result of refinement. // int fvc = getRefinerFVarChannel(fvarChannel); if (_refiner.GetLevel(1).GetNumFVarValues(fvc) > _refiner.GetLevel(1).GetNumVertices()) { // Scale this based on ratio of fvar-values to vertices... float fvarReduction = 0.5; estLocalPoints = (int) ((float)estLocalPoints * fvarReduction); } } return estLocalPoints; }
O1
cpp
OpenSubdiv::v3_6_0::Far::PatchTableBuilder::estimateLocalPointCount(OpenSubdiv::v3_6_0::Far::PatchTableBuilder::LocalPointHelper::Options const&, int) const: pushq %rbp pushq %r15 pushq %r14 pushq %rbx pushq %rax movl %edx, %ebp movq %rsi, %r15 movq %rdi, %rbx testl %edx, %edx js 0x6dce2 movq %rbx, %rdi movl %ebp, %esi callq 0x3b290 xorl %r14d, %r14d testb %al, %al jne 0x6ddb6 movb 0x28(%rbx), %al xorl %r14d, %r14d testb $0x2, %al je 0x6dd1a movq 0x38(%rbx), %rcx movl 0x28(%rcx), %edx leal -0x1(%rdx), %edi movl $0xffffffff, %esi # imm = 0xFFFFFFFF cmpl $0x9, %edi ja 0x6dd0c movl %edi, %esi leaq 0x4b44b(%rip), %rdi # 0xb9154 movl (%rdi,%rsi,4), %esi imull 0x70(%rbx), %esi xorl %r14d, %r14d cmpl 0x30(%rcx), %edx cmovnel %esi, %r14d testb $0x4, %al je 0x6dd5d movq 0x38(%rbx), %rdx movl 0x2c(%rdx), %esi leal -0x1(%rsi), %ecx movl $0xffffffff, %eax # imm = 0xFFFFFFFF cmpl $0x9, %ecx ja 0x6dd3e movl %ecx, %eax leaq 0x4b419(%rip), %rcx # 0xb9154 movl (%rcx,%rax,4), %eax movl 0x74(%rbx), %ecx testb $0x2, (%r15) je 0x6dd57 cmpl 0x30(%rdx), %esi jne 0x6dd57 movl %eax, %edx shrl $0x1f, %edx addl %eax, %edx sarl %edx movl %edx, %eax imull %ecx, %eax addl %eax, %r14d testl %ebp, %ebp js 0x6ddb6 movq (%rbx), %rcx movq 0x60(%rcx), %rax movq 0x68(%rcx), %rcx subq %rax, %rcx shrq $0x3, %rcx imull $0xaaaaaaab, %ecx, %ecx # imm = 0xAAAAAAAB cmpl $0x2, %ecx jl 0x6ddb6 movl %ebp, %ecx movq 0xa8(%rbx), %rdx movl (%rdx,%rcx,4), %esi movq 0x18(%rax), %rdi callq 0x3ae80 movq (%rbx), %rcx movq 0x60(%rcx), %rcx movq 0x18(%rcx), %rcx cvtsi2ss %r14d, %xmm0 cmpl 0x8(%rcx), %eax mulss 0x481a6(%rip), %xmm0 # 0xb5f54 cvttss2si %xmm0, %eax cmovgl %eax, %r14d movl %r14d, %eax addq $0x8, %rsp popq %rbx popq %r14 popq %r15 popq %rbp retq
_ZNK10OpenSubdiv6v3_6_03Far17PatchTableBuilder23estimateLocalPointCountERKNS2_16LocalPointHelper7OptionsEi: push rbp push r15 push r14 push rbx push rax mov ebp, edx mov r15, rsi mov rbx, rdi test edx, edx js short loc_6DCE2 mov rdi, rbx; this mov esi, ebp; int call __ZNK10OpenSubdiv6v3_6_03Far17PatchTableBuilder19isFVarChannelLinearEi; OpenSubdiv::v3_6_0::Far::PatchTableBuilder::isFVarChannelLinear(int) xor r14d, r14d test al, al jnz loc_6DDB6 loc_6DCE2: mov al, [rbx+28h] xor r14d, r14d test al, 2 jz short loc_6DD1A mov rcx, [rbx+38h] mov edx, [rcx+28h] lea edi, [rdx-1] mov esi, 0FFFFFFFFh cmp edi, 9 ja short loc_6DD0C mov esi, edi lea rdi, unk_B9154 mov esi, [rdi+rsi*4] loc_6DD0C: imul esi, [rbx+70h] xor r14d, r14d cmp edx, [rcx+30h] cmovnz r14d, esi loc_6DD1A: test al, 4 jz short loc_6DD5D mov rdx, [rbx+38h] mov esi, [rdx+2Ch] lea ecx, [rsi-1] mov eax, 0FFFFFFFFh cmp ecx, 9 ja short loc_6DD3E mov eax, ecx lea rcx, unk_B9154 mov eax, [rcx+rax*4] loc_6DD3E: mov ecx, [rbx+74h] test byte ptr [r15], 2 jz short loc_6DD57 cmp esi, [rdx+30h] jnz short loc_6DD57 mov edx, eax shr edx, 1Fh add edx, eax sar edx, 1 mov eax, edx loc_6DD57: imul eax, ecx add r14d, eax loc_6DD5D: test ebp, ebp js short loc_6DDB6 mov rcx, [rbx] mov rax, [rcx+60h] mov rcx, [rcx+68h] sub rcx, rax shr rcx, 3 imul ecx, 0AAAAAAABh cmp ecx, 2 jl short loc_6DDB6 mov ecx, ebp mov rdx, [rbx+0A8h] mov esi, [rdx+rcx*4]; int mov rdi, [rax+18h]; this call __ZNK10OpenSubdiv6v3_6_03Vtr8internal5Level16getNumFVarValuesEi; OpenSubdiv::v3_6_0::Vtr::internal::Level::getNumFVarValues(int) mov rcx, [rbx] mov rcx, [rcx+60h] mov rcx, [rcx+18h] cvtsi2ss xmm0, r14d cmp eax, [rcx+8] mulss xmm0, cs:dword_B5F54 cvttss2si eax, xmm0 cmovg r14d, eax loc_6DDB6: mov eax, r14d add rsp, 8 pop rbx pop r14 pop r15 pop rbp retn
long long OpenSubdiv::v3_6_0::Far::PatchTableBuilder::estimateLocalPointCount( OpenSubdiv::v3_6_0::Far::PatchTableBuilder *this, _BYTE *a2, int a3) { int v5; // r14d char v6; // al long long v7; // rcx int v8; // edx int v9; // esi int v10; // esi long long v11; // rdx int v12; // esi int v13; // eax long long v14; // rax if ( a3 < 0 || (v5 = 0, !(unsigned __int8)OpenSubdiv::v3_6_0::Far::PatchTableBuilder::isFVarChannelLinear(this, a3)) ) { v6 = *((_BYTE *)this + 40); v5 = 0; if ( (v6 & 2) != 0 ) { v7 = *((_QWORD *)this + 7); v8 = *(_DWORD *)(v7 + 40); v9 = -1; if ( (unsigned int)(v8 - 1) <= 9 ) v9 = dword_B9154[v8 - 1]; v10 = *((_DWORD *)this + 28) * v9; v5 = 0; if ( v8 != *(_DWORD *)(v7 + 48) ) v5 = v10; } if ( (v6 & 4) != 0 ) { v11 = *((_QWORD *)this + 7); v12 = *(_DWORD *)(v11 + 44); v13 = -1; if ( (unsigned int)(v12 - 1) <= 9 ) v13 = dword_B9154[v12 - 1]; if ( (*a2 & 2) != 0 && v12 == *(_DWORD *)(v11 + 48) ) v13 /= 2; v5 += *((_DWORD *)this + 29) * v13; } if ( a3 >= 0 ) { v14 = *(_QWORD *)(*(_QWORD *)this + 96LL); if ( (int)(-1431655765 * ((unsigned long long)(*(_QWORD *)(*(_QWORD *)this + 104LL) - v14) >> 3)) >= 2 && (int)OpenSubdiv::v3_6_0::Vtr::internal::Level::getNumFVarValues( *(OpenSubdiv::v3_6_0::Vtr::internal::Level **)(v14 + 24), *(_DWORD *)(*((_QWORD *)this + 21) + 4LL * (unsigned int)a3)) > *(_DWORD *)(*(_QWORD *)(*(_QWORD *)(*(_QWORD *)this + 96LL) + 24LL) + 8LL) ) { return (unsigned int)(int)(float)((float)v5 * 0.5); } } } return (unsigned int)v5; }
estimateLocalPointCount: PUSH RBP PUSH R15 PUSH R14 PUSH RBX PUSH RAX MOV EBP,EDX MOV R15,RSI MOV RBX,RDI TEST EDX,EDX JS 0x0016dce2 MOV RDI,RBX MOV ESI,EBP CALL 0x0013b290 XOR R14D,R14D TEST AL,AL JNZ 0x0016ddb6 LAB_0016dce2: MOV AL,byte ptr [RBX + 0x28] XOR R14D,R14D TEST AL,0x2 JZ 0x0016dd1a MOV RCX,qword ptr [RBX + 0x38] MOV EDX,dword ptr [RCX + 0x28] LEA EDI,[RDX + -0x1] MOV ESI,0xffffffff CMP EDI,0x9 JA 0x0016dd0c MOV ESI,EDI LEA RDI,[0x1b9154] MOV ESI,dword ptr [RDI + RSI*0x4] LAB_0016dd0c: IMUL ESI,dword ptr [RBX + 0x70] XOR R14D,R14D CMP EDX,dword ptr [RCX + 0x30] CMOVNZ R14D,ESI LAB_0016dd1a: TEST AL,0x4 JZ 0x0016dd5d MOV RDX,qword ptr [RBX + 0x38] MOV ESI,dword ptr [RDX + 0x2c] LEA ECX,[RSI + -0x1] MOV EAX,0xffffffff CMP ECX,0x9 JA 0x0016dd3e MOV EAX,ECX LEA RCX,[0x1b9154] MOV EAX,dword ptr [RCX + RAX*0x4] LAB_0016dd3e: MOV ECX,dword ptr [RBX + 0x74] TEST byte ptr [R15],0x2 JZ 0x0016dd57 CMP ESI,dword ptr [RDX + 0x30] JNZ 0x0016dd57 MOV EDX,EAX SHR EDX,0x1f ADD EDX,EAX SAR EDX,0x1 MOV EAX,EDX LAB_0016dd57: IMUL EAX,ECX ADD R14D,EAX LAB_0016dd5d: TEST EBP,EBP JS 0x0016ddb6 MOV RCX,qword ptr [RBX] MOV RAX,qword ptr [RCX + 0x60] MOV RCX,qword ptr [RCX + 0x68] SUB RCX,RAX SHR RCX,0x3 IMUL ECX,ECX,-0x55555555 CMP ECX,0x2 JL 0x0016ddb6 MOV ECX,EBP MOV RDX,qword ptr [RBX + 0xa8] MOV ESI,dword ptr [RDX + RCX*0x4] MOV RDI,qword ptr [RAX + 0x18] CALL 0x0013ae80 MOV RCX,qword ptr [RBX] MOV RCX,qword ptr [RCX + 0x60] MOV RCX,qword ptr [RCX + 0x18] CVTSI2SS XMM0,R14D CMP EAX,dword ptr [RCX + 0x8] MULSS XMM0,dword ptr [0x001b5f54] CVTTSS2SI EAX,XMM0 CMOVG R14D,EAX LAB_0016ddb6: MOV EAX,R14D ADD RSP,0x8 POP RBX POP R14 POP R15 POP RBP RET
/* OpenSubdiv::v3_6_0::Far::PatchTableBuilder::estimateLocalPointCount(OpenSubdiv::v3_6_0::Far::PatchTableBuilder::LocalPointHelper::Options const&, int) const */ int __thiscall OpenSubdiv::v3_6_0::Far::PatchTableBuilder::estimateLocalPointCount (PatchTableBuilder *this,Options *param_1,int param_2) { uint uVar1; long lVar2; char cVar3; int iVar4; int iVar5; int iVar6; if ((-1 < param_2) && (cVar3 = isFVarChannelLinear(this,param_2), cVar3 != '\0')) { return 0; } iVar6 = 0; if (((byte)this[0x28] & 2) != 0) { iVar4 = *(int *)(*(long *)(this + 0x38) + 0x28); uVar1 = iVar4 - 1; iVar5 = -1; if (uVar1 < 10) { iVar5 = *(int *)(&DAT_001b9154 + (ulong)uVar1 * 4); } iVar6 = 0; if (iVar4 != *(int *)(*(long *)(this + 0x38) + 0x30)) { iVar6 = iVar5 * *(int *)(this + 0x70); } } if (((byte)this[0x28] & 4) != 0) { iVar4 = *(int *)(*(long *)(this + 0x38) + 0x2c); uVar1 = iVar4 - 1; iVar5 = -1; if (uVar1 < 10) { iVar5 = *(int *)(&DAT_001b9154 + (ulong)uVar1 * 4); } if ((((byte)*param_1 & 2) != 0) && (iVar4 == *(int *)(*(long *)(this + 0x38) + 0x30))) { iVar5 = iVar5 / 2; } iVar6 = iVar6 + iVar5 * *(int *)(this + 0x74); } if ((-1 < param_2) && (lVar2 = *(long *)(*(long *)this + 0x60), 1 < (int)((ulong)(*(long *)(*(long *)this + 0x68) - lVar2) >> 3) * -0x55555555)) { iVar4 = Vtr::internal::Level::getNumFVarValues (*(Level **)(lVar2 + 0x18), *(int *)(*(long *)(this + 0xa8) + (ulong)(uint)param_2 * 4)); if (*(int *)(*(long *)(*(long *)(*(long *)this + 0x60) + 0x18) + 8) < iVar4) { iVar6 = (int)((float)iVar6 * DAT_001b5f54); } } return iVar6; }
20,511
OpenSubdiv::v3_6_0::Far::PatchTableBuilder::estimateLocalPointCount(OpenSubdiv::v3_6_0::Far::PatchTableBuilder::LocalPointHelper::Options const&, int) const
NVIDIA-RTX[P]OSD-Lite/opensubdiv/far/patchTableFactory.cpp
int PatchTableBuilder::estimateLocalPointCount( LocalPointHelper::Options const & options, int fvarChannel) const { if ((fvarChannel >= 0) && isFVarChannelLinear(fvarChannel)) return 0; // // Estimate the local points required for the Vertex topology in all cases // as it may be used in the estimates for face-varying channels: // int estLocalPoints = 0; if (_requiresRegularLocalPoints) { // // Either all regular patches are being converted to a non-native // basis, or boundary points are being extrapolated in the regular // basis. The latter case typically involves a small fraction of // patches and points, so we don't estimate any local points and // leave it up to incremental allocation later to account for them. // int numPointsPerPatch = PatchDescriptor( _patchBuilder->GetRegularPatchType()).GetNumControlVertices(); if (_patchBuilder->GetRegularPatchType() != _patchBuilder->GetNativePatchType()) { estLocalPoints += _numRegularPatches * numPointsPerPatch; } } if (_requiresIrregularLocalPoints) { bool oldEstimate = false; int numIrregularPatches = oldEstimate ? _refiner.GetLevel(_refiner.GetMaxLevel()).GetNumFaces() : _numIrregularPatches; // // If converting to a basis other than regular, its difficult to // predict the degree of point-sharing that may occur, and in general, // the maximal benefit is small so we don't attempt to compensate for // it here. If converting to the same basis as regular, roughly half // of the points of the patch are involved in approximating the // irregularity (and cannot be shared) so don't include the source // points that will be used in such patches. // int numPointsPerPatch = PatchDescriptor( _patchBuilder->GetIrregularPatchType()).GetNumControlVertices(); if (options.reuseSourcePoints && (_patchBuilder->GetIrregularPatchType() == _patchBuilder->GetNativePatchType())) { numPointsPerPatch /= 2; } estLocalPoints += numIrregularPatches * numPointsPerPatch; } // // Its difficult to estimate the differences in number of irregularities // between the vertex topology and a face-varying channel without more // detailed inspection. // // A much higher number of fvar-values than vertices is an indication that // the number of differences increases, and that generally lowers the // number of irregular patches due to more regular patches on face-varying // boundaries, but not always. The use of some interpolation types, e.g. // LINEAR_BOUNDARIES, combined with inf-sharp patches can increase the // number of irregularities significantly. // if ((fvarChannel >= 0) && (_refiner.GetNumLevels() > 1)) { // // We're seeing face-varying stencil table sizes about 1/4 the size of // the vertex stencil table for what seem like typical cases... // // Identify the ratio of fvar-values to vertices that typically leads // to these reductions and reduce the number of expected local points // proportionally. Use the number of fvar-values at level 1: level 0 // can be misleading as there can be many FEWER than the number of // vertices, but subsequent levels will have at least one unique // fvar-value per vertex, and later levels will have a much higher // percentage shared as a result of refinement. // int fvc = getRefinerFVarChannel(fvarChannel); if (_refiner.GetLevel(1).GetNumFVarValues(fvc) > _refiner.GetLevel(1).GetNumVertices()) { // Scale this based on ratio of fvar-values to vertices... float fvarReduction = 0.5; estLocalPoints = (int) ((float)estLocalPoints * fvarReduction); } } return estLocalPoints; }
O2
cpp
OpenSubdiv::v3_6_0::Far::PatchTableBuilder::estimateLocalPointCount(OpenSubdiv::v3_6_0::Far::PatchTableBuilder::LocalPointHelper::Options const&, int) const: pushq %rbp pushq %r15 pushq %r14 pushq %r12 pushq %rbx movl %edx, %r14d movq %rsi, %r15 movq %rdi, %rbx testl %edx, %edx js 0x7f91e movq %rbx, %rdi movl %r14d, %esi callq 0x54270 xorl %ebp, %ebp testb %al, %al jne 0x7f9d8 movb 0x28(%rbx), %al xorl %ebp, %ebp testb $0x2, %al je 0x7f94a movq 0x38(%rbx), %rax movl 0x28(%rax), %edi callq 0x4f3b0 movq 0x38(%rbx), %rcx cwtl imull 0x70(%rbx), %eax movl 0x28(%rcx), %edx xorl %ebp, %ebp cmpl 0x30(%rcx), %edx cmovnel %eax, %ebp movb 0x28(%rbx), %al testb $0x4, %al je 0x7f981 movl 0x74(%rbx), %r12d movq 0x38(%rbx), %rax movl 0x2c(%rax), %edi callq 0x4f3b0 testb $0x2, (%r15) je 0x7f979 movq 0x38(%rbx), %rcx movl 0x2c(%rcx), %edx cmpl 0x30(%rcx), %edx jne 0x7f979 movw $0x2, %cx cwtd idivw %cx cwtl imull %eax, %r12d addl %r12d, %ebp testl %r14d, %r14d js 0x7f9d8 movq (%rbx), %rax movq 0x60(%rax), %rdi movq 0x68(%rax), %rax subq %rdi, %rax pushq $0x18 popq %rcx cqto idivq %rcx cmpl $0x2, %eax jl 0x7f9d8 movl %r14d, %eax movq 0xa8(%rbx), %rcx movl (%rcx,%rax,4), %esi addq $0x18, %rdi callq 0x503d0 movq (%rbx), %rcx movq 0x60(%rcx), %rcx movq 0x18(%rcx), %rcx cvtsi2ss %ebp, %xmm0 cmpl 0x8(%rcx), %eax mulss 0x406df(%rip), %xmm0 # 0xc00b0 cvttss2si %xmm0, %eax cmovgl %eax, %ebp movl %ebp, %eax popq %rbx popq %r12 popq %r14 popq %r15 popq %rbp retq nop
_ZNK10OpenSubdiv6v3_6_03Far17PatchTableBuilder23estimateLocalPointCountERKNS2_16LocalPointHelper7OptionsEi: push rbp push r15 push r14 push r12 push rbx mov r14d, edx mov r15, rsi mov rbx, rdi test edx, edx js short loc_7F91E mov rdi, rbx; this mov esi, r14d; int call __ZNK10OpenSubdiv6v3_6_03Far17PatchTableBuilder19isFVarChannelLinearEi; OpenSubdiv::v3_6_0::Far::PatchTableBuilder::isFVarChannelLinear(int) xor ebp, ebp test al, al jnz loc_7F9D8 loc_7F91E: mov al, [rbx+28h] xor ebp, ebp test al, 2 jz short loc_7F94A mov rax, [rbx+38h] mov edi, [rax+28h] call __ZN10OpenSubdiv6v3_6_03Far15PatchDescriptor21GetNumControlVerticesENS2_4TypeE; OpenSubdiv::v3_6_0::Far::PatchDescriptor::GetNumControlVertices(OpenSubdiv::v3_6_0::Far::PatchDescriptor::Type) mov rcx, [rbx+38h] cwde imul eax, [rbx+70h] mov edx, [rcx+28h] xor ebp, ebp cmp edx, [rcx+30h] cmovnz ebp, eax mov al, [rbx+28h] loc_7F94A: test al, 4 jz short loc_7F981 mov r12d, [rbx+74h] mov rax, [rbx+38h] mov edi, [rax+2Ch] call __ZN10OpenSubdiv6v3_6_03Far15PatchDescriptor21GetNumControlVerticesENS2_4TypeE; OpenSubdiv::v3_6_0::Far::PatchDescriptor::GetNumControlVertices(OpenSubdiv::v3_6_0::Far::PatchDescriptor::Type) test byte ptr [r15], 2 jz short loc_7F979 mov rcx, [rbx+38h] mov edx, [rcx+2Ch] cmp edx, [rcx+30h] jnz short loc_7F979 mov cx, 2 cwd idiv cx loc_7F979: cwde imul r12d, eax add ebp, r12d loc_7F981: test r14d, r14d js short loc_7F9D8 mov rax, [rbx] mov rdi, [rax+60h] mov rax, [rax+68h] sub rax, rdi push 18h pop rcx cqo idiv rcx cmp eax, 2 jl short loc_7F9D8 mov eax, r14d mov rcx, [rbx+0A8h] mov esi, [rcx+rax*4]; int add rdi, 18h; this call __ZNK10OpenSubdiv6v3_6_03Far13TopologyLevel16GetNumFVarValuesEi; OpenSubdiv::v3_6_0::Far::TopologyLevel::GetNumFVarValues(int) mov rcx, [rbx] mov rcx, [rcx+60h] mov rcx, [rcx+18h] cvtsi2ss xmm0, ebp cmp eax, [rcx+8] mulss xmm0, cs:dword_C00B0 cvttss2si eax, xmm0 cmovg ebp, eax loc_7F9D8: mov eax, ebp pop rbx pop r12 pop r14 pop r15 pop rbp retn
long long OpenSubdiv::v3_6_0::Far::PatchTableBuilder::estimateLocalPointCount( OpenSubdiv::v3_6_0::Far::PatchTableBuilder *this, _BYTE *a2, int a3) { int v5; // ebp char v6; // al int v7; // eax int v8; // r12d __int16 NumControlVertices; // ax long long v10; // rdi if ( a3 < 0 || (v5 = 0, !(unsigned __int8)OpenSubdiv::v3_6_0::Far::PatchTableBuilder::isFVarChannelLinear(this, a3)) ) { v6 = *((_BYTE *)this + 40); v5 = 0; if ( (v6 & 2) != 0 ) { v7 = *((_DWORD *)this + 28) * (__int16)OpenSubdiv::v3_6_0::Far::PatchDescriptor::GetNumControlVertices(*(unsigned int *)(*((_QWORD *)this + 7) + 40LL)); v5 = 0; if ( *(_DWORD *)(*((_QWORD *)this + 7) + 40LL) != *(_DWORD *)(*((_QWORD *)this + 7) + 48LL) ) v5 = v7; v6 = *((_BYTE *)this + 40); } if ( (v6 & 4) != 0 ) { v8 = *((_DWORD *)this + 29); NumControlVertices = OpenSubdiv::v3_6_0::Far::PatchDescriptor::GetNumControlVertices(*(unsigned int *)(*((_QWORD *)this + 7) + 44LL)); if ( (*a2 & 2) != 0 && *(_DWORD *)(*((_QWORD *)this + 7) + 44LL) == *(_DWORD *)(*((_QWORD *)this + 7) + 48LL) ) NumControlVertices /= 2; v5 += NumControlVertices * v8; } if ( a3 >= 0 ) { v10 = *(_QWORD *)(*(_QWORD *)this + 96LL); if ( (int)((*(_QWORD *)(*(_QWORD *)this + 104LL) - v10) / 24) >= 2 && (int)OpenSubdiv::v3_6_0::Far::TopologyLevel::GetNumFVarValues( (OpenSubdiv::v3_6_0::Far::TopologyLevel *)(v10 + 24), *(_DWORD *)(*((_QWORD *)this + 21) + 4LL * (unsigned int)a3)) > *(_DWORD *)(*(_QWORD *)(*(_QWORD *)(*(_QWORD *)this + 96LL) + 24LL) + 8LL) ) { return (unsigned int)(int)(float)((float)v5 * 0.5); } } } return (unsigned int)v5; }
estimateLocalPointCount: PUSH RBP PUSH R15 PUSH R14 PUSH R12 PUSH RBX MOV R14D,EDX MOV R15,RSI MOV RBX,RDI TEST EDX,EDX JS 0x0017f91e MOV RDI,RBX MOV ESI,R14D CALL 0x00154270 XOR EBP,EBP TEST AL,AL JNZ 0x0017f9d8 LAB_0017f91e: MOV AL,byte ptr [RBX + 0x28] XOR EBP,EBP TEST AL,0x2 JZ 0x0017f94a MOV RAX,qword ptr [RBX + 0x38] MOV EDI,dword ptr [RAX + 0x28] CALL 0x0014f3b0 MOV RCX,qword ptr [RBX + 0x38] CWDE IMUL EAX,dword ptr [RBX + 0x70] MOV EDX,dword ptr [RCX + 0x28] XOR EBP,EBP CMP EDX,dword ptr [RCX + 0x30] CMOVNZ EBP,EAX MOV AL,byte ptr [RBX + 0x28] LAB_0017f94a: TEST AL,0x4 JZ 0x0017f981 MOV R12D,dword ptr [RBX + 0x74] MOV RAX,qword ptr [RBX + 0x38] MOV EDI,dword ptr [RAX + 0x2c] CALL 0x0014f3b0 TEST byte ptr [R15],0x2 JZ 0x0017f979 MOV RCX,qword ptr [RBX + 0x38] MOV EDX,dword ptr [RCX + 0x2c] CMP EDX,dword ptr [RCX + 0x30] JNZ 0x0017f979 MOV CX,0x2 CWD IDIV CX LAB_0017f979: CWDE IMUL R12D,EAX ADD EBP,R12D LAB_0017f981: TEST R14D,R14D JS 0x0017f9d8 MOV RAX,qword ptr [RBX] MOV RDI,qword ptr [RAX + 0x60] MOV RAX,qword ptr [RAX + 0x68] SUB RAX,RDI PUSH 0x18 POP RCX CQO IDIV RCX CMP EAX,0x2 JL 0x0017f9d8 MOV EAX,R14D MOV RCX,qword ptr [RBX + 0xa8] MOV ESI,dword ptr [RCX + RAX*0x4] ADD RDI,0x18 CALL 0x001503d0 MOV RCX,qword ptr [RBX] MOV RCX,qword ptr [RCX + 0x60] MOV RCX,qword ptr [RCX + 0x18] CVTSI2SS XMM0,EBP CMP EAX,dword ptr [RCX + 0x8] MULSS XMM0,dword ptr [0x001c00b0] CVTTSS2SI EAX,XMM0 CMOVG EBP,EAX LAB_0017f9d8: MOV EAX,EBP POP RBX POP R12 POP R14 POP R15 POP RBP RET
/* OpenSubdiv::v3_6_0::Far::PatchTableBuilder::estimateLocalPointCount(OpenSubdiv::v3_6_0::Far::PatchTableBuilder::LocalPointHelper::Options const&, int) const */ int __thiscall OpenSubdiv::v3_6_0::Far::PatchTableBuilder::estimateLocalPointCount (PatchTableBuilder *this,Options *param_1,int param_2) { long lVar1; char cVar2; PatchTableBuilder PVar3; short sVar4; int iVar5; int iVar6; if ((-1 < param_2) && (cVar2 = isFVarChannelLinear(this,param_2), cVar2 != '\0')) { return 0; } PVar3 = this[0x28]; iVar6 = 0; if (((byte)PVar3 & 2) != 0) { sVar4 = PatchDescriptor::GetNumControlVertices(*(int4 *)(*(long *)(this + 0x38) + 0x28)); iVar6 = 0; if (*(int *)(*(long *)(this + 0x38) + 0x28) != *(int *)(*(long *)(this + 0x38) + 0x30)) { iVar6 = (int)sVar4 * *(int *)(this + 0x70); } PVar3 = this[0x28]; } if (((byte)PVar3 & 4) != 0) { iVar5 = *(int *)(this + 0x74); sVar4 = PatchDescriptor::GetNumControlVertices(*(int4 *)(*(long *)(this + 0x38) + 0x2c)); if ((((byte)*param_1 & 2) != 0) && (*(int *)(*(long *)(this + 0x38) + 0x2c) == *(int *)(*(long *)(this + 0x38) + 0x30))) { sVar4 = sVar4 / 2; } iVar6 = iVar6 + iVar5 * sVar4; } if ((-1 < param_2) && (lVar1 = *(long *)(*(long *)this + 0x60), 1 < (int)((*(long *)(*(long *)this + 0x68) - lVar1) / 0x18))) { iVar5 = TopologyLevel::GetNumFVarValues ((TopologyLevel *)(lVar1 + 0x18), *(int *)(*(long *)(this + 0xa8) + (ulong)(uint)param_2 * 4)); if (*(int *)(*(long *)(*(long *)(*(long *)this + 0x60) + 0x18) + 8) < iVar5) { iVar6 = (int)((float)iVar6 * DAT_001c00b0); } } return iVar6; }
20,512
OpenSubdiv::v3_6_0::Far::PatchTableBuilder::estimateLocalPointCount(OpenSubdiv::v3_6_0::Far::PatchTableBuilder::LocalPointHelper::Options const&, int) const
NVIDIA-RTX[P]OSD-Lite/opensubdiv/far/patchTableFactory.cpp
int PatchTableBuilder::estimateLocalPointCount( LocalPointHelper::Options const & options, int fvarChannel) const { if ((fvarChannel >= 0) && isFVarChannelLinear(fvarChannel)) return 0; // // Estimate the local points required for the Vertex topology in all cases // as it may be used in the estimates for face-varying channels: // int estLocalPoints = 0; if (_requiresRegularLocalPoints) { // // Either all regular patches are being converted to a non-native // basis, or boundary points are being extrapolated in the regular // basis. The latter case typically involves a small fraction of // patches and points, so we don't estimate any local points and // leave it up to incremental allocation later to account for them. // int numPointsPerPatch = PatchDescriptor( _patchBuilder->GetRegularPatchType()).GetNumControlVertices(); if (_patchBuilder->GetRegularPatchType() != _patchBuilder->GetNativePatchType()) { estLocalPoints += _numRegularPatches * numPointsPerPatch; } } if (_requiresIrregularLocalPoints) { bool oldEstimate = false; int numIrregularPatches = oldEstimate ? _refiner.GetLevel(_refiner.GetMaxLevel()).GetNumFaces() : _numIrregularPatches; // // If converting to a basis other than regular, its difficult to // predict the degree of point-sharing that may occur, and in general, // the maximal benefit is small so we don't attempt to compensate for // it here. If converting to the same basis as regular, roughly half // of the points of the patch are involved in approximating the // irregularity (and cannot be shared) so don't include the source // points that will be used in such patches. // int numPointsPerPatch = PatchDescriptor( _patchBuilder->GetIrregularPatchType()).GetNumControlVertices(); if (options.reuseSourcePoints && (_patchBuilder->GetIrregularPatchType() == _patchBuilder->GetNativePatchType())) { numPointsPerPatch /= 2; } estLocalPoints += numIrregularPatches * numPointsPerPatch; } // // Its difficult to estimate the differences in number of irregularities // between the vertex topology and a face-varying channel without more // detailed inspection. // // A much higher number of fvar-values than vertices is an indication that // the number of differences increases, and that generally lowers the // number of irregular patches due to more regular patches on face-varying // boundaries, but not always. The use of some interpolation types, e.g. // LINEAR_BOUNDARIES, combined with inf-sharp patches can increase the // number of irregularities significantly. // if ((fvarChannel >= 0) && (_refiner.GetNumLevels() > 1)) { // // We're seeing face-varying stencil table sizes about 1/4 the size of // the vertex stencil table for what seem like typical cases... // // Identify the ratio of fvar-values to vertices that typically leads // to these reductions and reduce the number of expected local points // proportionally. Use the number of fvar-values at level 1: level 0 // can be misleading as there can be many FEWER than the number of // vertices, but subsequent levels will have at least one unique // fvar-value per vertex, and later levels will have a much higher // percentage shared as a result of refinement. // int fvc = getRefinerFVarChannel(fvarChannel); if (_refiner.GetLevel(1).GetNumFVarValues(fvc) > _refiner.GetLevel(1).GetNumVertices()) { // Scale this based on ratio of fvar-values to vertices... float fvarReduction = 0.5; estLocalPoints = (int) ((float)estLocalPoints * fvarReduction); } } return estLocalPoints; }
O3
cpp
OpenSubdiv::v3_6_0::Far::PatchTableBuilder::estimateLocalPointCount(OpenSubdiv::v3_6_0::Far::PatchTableBuilder::LocalPointHelper::Options const&, int) const: pushq %rbp pushq %r15 pushq %r14 pushq %rbx pushq %rax movl %edx, %ebp movq %rsi, %r15 movq %rdi, %rbx testl %edx, %edx js 0x6f314 movq %rbx, %rdi movl %ebp, %esi callq 0x3b250 xorl %r14d, %r14d testb %al, %al jne 0x6f3e9 movb 0x28(%rbx), %al xorl %r14d, %r14d testb $0x2, %al je 0x6f34c movq 0x38(%rbx), %rcx movl 0x28(%rcx), %edx leal -0x1(%rdx), %edi movl $0xffffffff, %esi # imm = 0xFFFFFFFF cmpl $0x9, %edi ja 0x6f33e movl %edi, %esi leaq 0x4d559(%rip), %rdi # 0xbc894 movl (%rdi,%rsi,4), %esi imull 0x70(%rbx), %esi xorl %r14d, %r14d cmpl 0x30(%rcx), %edx cmovnel %esi, %r14d testb $0x4, %al je 0x6f390 movq 0x38(%rbx), %rdx movl 0x2c(%rdx), %esi leal -0x1(%rsi), %ecx movl $0xffffffff, %eax # imm = 0xFFFFFFFF cmpl $0x9, %ecx ja 0x6f370 movl %ecx, %eax leaq 0x4d527(%rip), %rcx # 0xbc894 movl (%rcx,%rax,4), %eax movl 0x74(%rbx), %ecx testb $0x2, (%r15) je 0x6f38a cmpl 0x30(%rdx), %esi jne 0x6f38a movl %eax, %edx shrb $0x7, %dl addb %al, %dl sarb %dl movzbl %dl, %eax imull %ecx, %eax addl %eax, %r14d testl %ebp, %ebp js 0x6f3e9 movq (%rbx), %rcx movq 0x60(%rcx), %rax movq 0x68(%rcx), %rcx subq %rax, %rcx shrq $0x3, %rcx imull $0xaaaaaaab, %ecx, %ecx # imm = 0xAAAAAAAB cmpl $0x2, %ecx jl 0x6f3e9 movl %ebp, %ecx movq 0xa8(%rbx), %rdx movl (%rdx,%rcx,4), %esi movq 0x18(%rax), %rdi callq 0x3ae50 movq (%rbx), %rcx movq 0x60(%rcx), %rcx movq 0x18(%rcx), %rcx cvtsi2ss %r14d, %xmm0 cmpl 0x8(%rcx), %eax mulss 0x4a03f(%rip), %xmm0 # 0xb9420 cvttss2si %xmm0, %eax cmovgl %eax, %r14d movl %r14d, %eax addq $0x8, %rsp popq %rbx popq %r14 popq %r15 popq %rbp retq nop
_ZNK10OpenSubdiv6v3_6_03Far17PatchTableBuilder23estimateLocalPointCountERKNS2_16LocalPointHelper7OptionsEi: push rbp push r15 push r14 push rbx push rax mov ebp, edx mov r15, rsi mov rbx, rdi test edx, edx js short loc_6F314 mov rdi, rbx; this mov esi, ebp; int call __ZNK10OpenSubdiv6v3_6_03Far17PatchTableBuilder19isFVarChannelLinearEi; OpenSubdiv::v3_6_0::Far::PatchTableBuilder::isFVarChannelLinear(int) xor r14d, r14d test al, al jnz loc_6F3E9 loc_6F314: mov al, [rbx+28h] xor r14d, r14d test al, 2 jz short loc_6F34C mov rcx, [rbx+38h] mov edx, [rcx+28h] lea edi, [rdx-1] mov esi, 0FFFFFFFFh cmp edi, 9 ja short loc_6F33E mov esi, edi lea rdi, unk_BC894 mov esi, [rdi+rsi*4] loc_6F33E: imul esi, [rbx+70h] xor r14d, r14d cmp edx, [rcx+30h] cmovnz r14d, esi loc_6F34C: test al, 4 jz short loc_6F390 mov rdx, [rbx+38h] mov esi, [rdx+2Ch] lea ecx, [rsi-1] mov eax, 0FFFFFFFFh cmp ecx, 9 ja short loc_6F370 mov eax, ecx lea rcx, unk_BC894 mov eax, [rcx+rax*4] loc_6F370: mov ecx, [rbx+74h] test byte ptr [r15], 2 jz short loc_6F38A cmp esi, [rdx+30h] jnz short loc_6F38A mov edx, eax shr dl, 7 add dl, al sar dl, 1 movzx eax, dl loc_6F38A: imul eax, ecx add r14d, eax loc_6F390: test ebp, ebp js short loc_6F3E9 mov rcx, [rbx] mov rax, [rcx+60h] mov rcx, [rcx+68h] sub rcx, rax shr rcx, 3 imul ecx, 0AAAAAAABh cmp ecx, 2 jl short loc_6F3E9 mov ecx, ebp mov rdx, [rbx+0A8h] mov esi, [rdx+rcx*4]; int mov rdi, [rax+18h]; this call __ZNK10OpenSubdiv6v3_6_03Vtr8internal5Level16getNumFVarValuesEi; OpenSubdiv::v3_6_0::Vtr::internal::Level::getNumFVarValues(int) mov rcx, [rbx] mov rcx, [rcx+60h] mov rcx, [rcx+18h] cvtsi2ss xmm0, r14d cmp eax, [rcx+8] mulss xmm0, cs:dword_B9420 cvttss2si eax, xmm0 cmovg r14d, eax loc_6F3E9: mov eax, r14d add rsp, 8 pop rbx pop r14 pop r15 pop rbp retn
long long OpenSubdiv::v3_6_0::Far::PatchTableBuilder::estimateLocalPointCount( OpenSubdiv::v3_6_0::Far::PatchTableBuilder *this, _BYTE *a2, int a3) { int v5; // r14d char v6; // al long long v7; // rcx int v8; // edx int v9; // esi int v10; // esi long long v11; // rdx int v12; // esi int v13; // eax long long v14; // rax if ( a3 < 0 || (v5 = 0, !(unsigned __int8)OpenSubdiv::v3_6_0::Far::PatchTableBuilder::isFVarChannelLinear(this, a3)) ) { v6 = *((_BYTE *)this + 40); v5 = 0; if ( (v6 & 2) != 0 ) { v7 = *((_QWORD *)this + 7); v8 = *(_DWORD *)(v7 + 40); v9 = -1; if ( (unsigned int)(v8 - 1) <= 9 ) v9 = dword_BC894[v8 - 1]; v10 = *((_DWORD *)this + 28) * v9; v5 = 0; if ( v8 != *(_DWORD *)(v7 + 48) ) v5 = v10; } if ( (v6 & 4) != 0 ) { v11 = *((_QWORD *)this + 7); v12 = *(_DWORD *)(v11 + 44); v13 = -1; if ( (unsigned int)(v12 - 1) <= 9 ) v13 = dword_BC894[v12 - 1]; if ( (*a2 & 2) != 0 && v12 == *(_DWORD *)(v11 + 48) ) v13 = (unsigned __int8)((char)v13 / 2); v5 += *((_DWORD *)this + 29) * v13; } if ( a3 >= 0 ) { v14 = *(_QWORD *)(*(_QWORD *)this + 96LL); if ( (int)(-1431655765 * ((unsigned long long)(*(_QWORD *)(*(_QWORD *)this + 104LL) - v14) >> 3)) >= 2 && (int)OpenSubdiv::v3_6_0::Vtr::internal::Level::getNumFVarValues( *(OpenSubdiv::v3_6_0::Vtr::internal::Level **)(v14 + 24), *(_DWORD *)(*((_QWORD *)this + 21) + 4LL * (unsigned int)a3)) > *(_DWORD *)(*(_QWORD *)(*(_QWORD *)(*(_QWORD *)this + 96LL) + 24LL) + 8LL) ) { return (unsigned int)(int)(float)((float)v5 * 0.5); } } } return (unsigned int)v5; }
estimateLocalPointCount: PUSH RBP PUSH R15 PUSH R14 PUSH RBX PUSH RAX MOV EBP,EDX MOV R15,RSI MOV RBX,RDI TEST EDX,EDX JS 0x0016f314 MOV RDI,RBX MOV ESI,EBP CALL 0x0013b250 XOR R14D,R14D TEST AL,AL JNZ 0x0016f3e9 LAB_0016f314: MOV AL,byte ptr [RBX + 0x28] XOR R14D,R14D TEST AL,0x2 JZ 0x0016f34c MOV RCX,qword ptr [RBX + 0x38] MOV EDX,dword ptr [RCX + 0x28] LEA EDI,[RDX + -0x1] MOV ESI,0xffffffff CMP EDI,0x9 JA 0x0016f33e MOV ESI,EDI LEA RDI,[0x1bc894] MOV ESI,dword ptr [RDI + RSI*0x4] LAB_0016f33e: IMUL ESI,dword ptr [RBX + 0x70] XOR R14D,R14D CMP EDX,dword ptr [RCX + 0x30] CMOVNZ R14D,ESI LAB_0016f34c: TEST AL,0x4 JZ 0x0016f390 MOV RDX,qword ptr [RBX + 0x38] MOV ESI,dword ptr [RDX + 0x2c] LEA ECX,[RSI + -0x1] MOV EAX,0xffffffff CMP ECX,0x9 JA 0x0016f370 MOV EAX,ECX LEA RCX,[0x1bc894] MOV EAX,dword ptr [RCX + RAX*0x4] LAB_0016f370: MOV ECX,dword ptr [RBX + 0x74] TEST byte ptr [R15],0x2 JZ 0x0016f38a CMP ESI,dword ptr [RDX + 0x30] JNZ 0x0016f38a MOV EDX,EAX SHR DL,0x7 ADD DL,AL SAR DL,0x1 MOVZX EAX,DL LAB_0016f38a: IMUL EAX,ECX ADD R14D,EAX LAB_0016f390: TEST EBP,EBP JS 0x0016f3e9 MOV RCX,qword ptr [RBX] MOV RAX,qword ptr [RCX + 0x60] MOV RCX,qword ptr [RCX + 0x68] SUB RCX,RAX SHR RCX,0x3 IMUL ECX,ECX,-0x55555555 CMP ECX,0x2 JL 0x0016f3e9 MOV ECX,EBP MOV RDX,qword ptr [RBX + 0xa8] MOV ESI,dword ptr [RDX + RCX*0x4] MOV RDI,qword ptr [RAX + 0x18] CALL 0x0013ae50 MOV RCX,qword ptr [RBX] MOV RCX,qword ptr [RCX + 0x60] MOV RCX,qword ptr [RCX + 0x18] CVTSI2SS XMM0,R14D CMP EAX,dword ptr [RCX + 0x8] MULSS XMM0,dword ptr [0x001b9420] CVTTSS2SI EAX,XMM0 CMOVG R14D,EAX LAB_0016f3e9: MOV EAX,R14D ADD RSP,0x8 POP RBX POP R14 POP R15 POP RBP RET
/* OpenSubdiv::v3_6_0::Far::PatchTableBuilder::estimateLocalPointCount(OpenSubdiv::v3_6_0::Far::PatchTableBuilder::LocalPointHelper::Options const&, int) const */ int __thiscall OpenSubdiv::v3_6_0::Far::PatchTableBuilder::estimateLocalPointCount (PatchTableBuilder *this,Options *param_1,int param_2) { uint uVar1; long lVar2; char cVar3; uint uVar4; int iVar5; int iVar6; int iVar7; if ((-1 < param_2) && (cVar3 = isFVarChannelLinear(this,param_2), cVar3 != '\0')) { return 0; } iVar7 = 0; if (((byte)this[0x28] & 2) != 0) { iVar5 = *(int *)(*(long *)(this + 0x38) + 0x28); uVar1 = iVar5 - 1; iVar6 = -1; if (uVar1 < 10) { iVar6 = *(int *)(&DAT_001bc894 + (ulong)uVar1 * 4); } iVar7 = 0; if (iVar5 != *(int *)(*(long *)(this + 0x38) + 0x30)) { iVar7 = iVar6 * *(int *)(this + 0x70); } } if (((byte)this[0x28] & 4) != 0) { iVar5 = *(int *)(*(long *)(this + 0x38) + 0x2c); uVar1 = iVar5 - 1; uVar4 = 0xffffffff; if (uVar1 < 10) { uVar4 = *(uint *)(&DAT_001bc894 + (ulong)uVar1 * 4); } if ((((byte)*param_1 & 2) != 0) && (iVar5 == *(int *)(*(long *)(this + 0x38) + 0x30))) { uVar4 = (uint)(byte)((char)uVar4 / '\x02'); } iVar7 = iVar7 + uVar4 * *(int *)(this + 0x74); } if ((-1 < param_2) && (lVar2 = *(long *)(*(long *)this + 0x60), 1 < (int)((ulong)(*(long *)(*(long *)this + 0x68) - lVar2) >> 3) * -0x55555555)) { iVar5 = Vtr::internal::Level::getNumFVarValues (*(Level **)(lVar2 + 0x18), *(int *)(*(long *)(this + 0xa8) + (ulong)(uint)param_2 * 4)); if (*(int *)(*(long *)(*(long *)(*(long *)this + 0x60) + 0x18) + 8) < iVar5) { iVar7 = (int)((float)iVar7 * DAT_001b9420); } } return iVar7; }
20,513
my_uca_charcmp
eloqsql/strings/ctype-uca.c
static int my_uca_charcmp(CHARSET_INFO *cs, my_wc_t wc1, my_wc_t wc2) { uint num_level= cs->levels_for_order; int ret; uint i; for (i= 0; i != num_level; i++) { ret= my_uca_charcmp_onelevel(cs, wc1, wc2, i); if (ret) { return ret; } } return 0; }
O3
c
my_uca_charcmp: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x58, %rsp movzbl 0xb2(%rdi), %eax testq %rax, %rax je 0xbd6c0 movq 0x60(%rdi), %r12 movl %esi, %edi movq %rsi, %r8 shrq $0x8, %r8 movl $0xffffff, %r9d # imm = 0xFFFFFF movq %r8, -0x78(%rbp) andq %r9, %r8 movl $0xff, %ecx movq %rsi, %r10 andq %rcx, %r10 movl %edx, %r11d movq %rdx, %rbx shrq $0x8, %rbx movq %rbx, -0x70(%rbp) andq %rbx, %r9 andq %rdx, %rcx movq %rcx, -0x80(%rbp) cmpq %rdx, %rsi movl $0x0, %esi setne %sil imulq $0x38, %rax, %rdx xorl %r13d, %r13d movq %rdi, -0x68(%rbp) movq %r9, -0x60(%rbp) movq %r8, -0x58(%rbp) movq %r10, -0x50(%rbp) movq %r11, -0x48(%rbp) movl %esi, -0x2c(%rbp) movq %rdx, -0x38(%rbp) movq (%r12,%r13), %rax cmpq %rdi, %rax jb 0xbd59f movq 0x10(%r12,%r13), %rcx movq (%rcx,%r8,8), %rcx testq %rcx, %rcx je 0xbd59f movq 0x8(%r12,%r13), %rdx movzbl (%rdx,%r8), %edx imull %r10d, %edx leaq (%rcx,%rdx,2), %r14 movq -0x38(%rbp), %rdx jmp 0xbd5a2 xorl %r14d, %r14d movl %esi, %ebx cmpq %r11, %rax jb 0xbd6af movq 0x10(%r12,%r13), %rax movq (%rax,%r9,8), %rax movl %esi, %ebx testq %rax, %rax je 0xbd6af movl %esi, %ebx testq %r14, %r14 je 0xbd6af movq 0x8(%r12,%r13), %rcx movzbl (%rcx,%r9), %edx imull -0x80(%rbp), %edx leaq (%rax,%rdx,2), %r15 movzwl (%r14), %eax movl $0x1, %ebx cmpw (%r15), %ax jne 0xbd6c2 movq -0x78(%rbp), %rax movzbl (%rcx,%rax), %esi movq -0x70(%rbp), %rax movzbl (%rcx,%rax), %eax cmpb %al, %sil jbe 0xbd646 movq %rax, -0x40(%rbp) leal (%rax,%rax), %edx movq %r14, %rdi movq %r15, %rsi callq 0x29570 movl -0x2c(%rbp), %esi movq -0x48(%rbp), %r11 movq -0x50(%rbp), %r10 movq -0x58(%rbp), %r8 movq -0x60(%rbp), %r9 movq -0x68(%rbp), %rdi testl %eax, %eax movq -0x38(%rbp), %rdx jne 0xbd6c2 movq -0x40(%rbp), %rax movzwl (%r14,%rax,2), %ebx jmp 0xbd6af leal (%rsi,%rsi), %edx cmpb %al, %sil jae 0xbd687 movq %rsi, -0x40(%rbp) movq %r14, %rdi movq %r15, %rsi callq 0x29570 testl %eax, %eax movq -0x68(%rbp), %rdi movq -0x60(%rbp), %r9 movq -0x58(%rbp), %r8 movq -0x50(%rbp), %r10 movq -0x48(%rbp), %r11 movl -0x2c(%rbp), %esi movq -0x38(%rbp), %rdx jne 0xbd6c2 movq -0x40(%rbp), %rax movzwl (%r15,%rax,2), %ebx jmp 0xbd6af movq %r14, %rdi movq %r15, %rsi callq 0x29890 movl %eax, %ebx movq -0x68(%rbp), %rdi movq -0x60(%rbp), %r9 movq -0x58(%rbp), %r8 movq -0x50(%rbp), %r10 movq -0x48(%rbp), %r11 movl -0x2c(%rbp), %esi movq -0x38(%rbp), %rdx testl %ebx, %ebx jne 0xbd6c2 addq $0x38, %r13 cmpq %r13, %rdx jne 0xbd570 xorl %ebx, %ebx movl %ebx, %eax addq $0x58, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
my_uca_charcmp: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx sub rsp, 58h movzx eax, byte ptr [rdi+0B2h] test rax, rax jz loc_BD6C0 mov r12, [rdi+60h] mov edi, esi mov r8, rsi shr r8, 8 mov r9d, 0FFFFFFh mov [rbp+var_78], r8 and r8, r9 mov ecx, 0FFh mov r10, rsi and r10, rcx mov r11d, edx mov rbx, rdx shr rbx, 8 mov [rbp+var_70], rbx and r9, rbx and rcx, rdx mov [rbp+var_80], rcx cmp rsi, rdx mov esi, 0 setnz sil imul rdx, rax, 38h ; '8' xor r13d, r13d mov [rbp+var_68], rdi mov [rbp+var_60], r9 mov [rbp+var_58], r8 mov [rbp+var_50], r10 mov [rbp+var_48], r11 mov [rbp+var_2C], esi mov [rbp+var_38], rdx loc_BD570: mov rax, [r12+r13] cmp rax, rdi jb short loc_BD59F mov rcx, [r12+r13+10h] mov rcx, [rcx+r8*8] test rcx, rcx jz short loc_BD59F mov rdx, [r12+r13+8] movzx edx, byte ptr [rdx+r8] imul edx, r10d lea r14, [rcx+rdx*2] mov rdx, [rbp+var_38] jmp short loc_BD5A2 loc_BD59F: xor r14d, r14d loc_BD5A2: mov ebx, esi cmp rax, r11 jb loc_BD6AF mov rax, [r12+r13+10h] mov rax, [rax+r9*8] mov ebx, esi test rax, rax jz loc_BD6AF mov ebx, esi test r14, r14 jz loc_BD6AF mov rcx, [r12+r13+8] movzx edx, byte ptr [rcx+r9] imul edx, dword ptr [rbp+var_80] lea r15, [rax+rdx*2] movzx eax, word ptr [r14] mov ebx, 1 cmp ax, [r15] jnz loc_BD6C2 mov rax, [rbp+var_78] movzx esi, byte ptr [rcx+rax] mov rax, [rbp+var_70] movzx eax, byte ptr [rcx+rax] cmp sil, al jbe short loc_BD646 mov [rbp+var_40], rax lea edx, [rax+rax] mov rdi, r14 mov rsi, r15 call _bcmp mov esi, [rbp+var_2C] mov r11, [rbp+var_48] mov r10, [rbp+var_50] mov r8, [rbp+var_58] mov r9, [rbp+var_60] mov rdi, [rbp+var_68] test eax, eax mov rdx, [rbp+var_38] jnz loc_BD6C2 mov rax, [rbp+var_40] movzx ebx, word ptr [r14+rax*2] jmp short loc_BD6AF loc_BD646: lea edx, [rsi+rsi] cmp sil, al jnb short loc_BD687 mov [rbp+var_40], rsi mov rdi, r14 mov rsi, r15 call _bcmp test eax, eax mov rdi, [rbp+var_68] mov r9, [rbp+var_60] mov r8, [rbp+var_58] mov r10, [rbp+var_50] mov r11, [rbp+var_48] mov esi, [rbp+var_2C] mov rdx, [rbp+var_38] jnz short loc_BD6C2 mov rax, [rbp+var_40] movzx ebx, word ptr [r15+rax*2] jmp short loc_BD6AF loc_BD687: mov rdi, r14 mov rsi, r15 call _memcmp mov ebx, eax mov rdi, [rbp+var_68] mov r9, [rbp+var_60] mov r8, [rbp+var_58] mov r10, [rbp+var_50] mov r11, [rbp+var_48] mov esi, [rbp+var_2C] mov rdx, [rbp+var_38] loc_BD6AF: test ebx, ebx jnz short loc_BD6C2 add r13, 38h ; '8' cmp rdx, r13 jnz loc_BD570 loc_BD6C0: xor ebx, ebx loc_BD6C2: mov eax, ebx add rsp, 58h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
long long my_uca_charcmp(long long a1, unsigned long long a2, unsigned long long a3) { long long v3; // rax long long v4; // r12 unsigned long long v5; // rdi long long v6; // r8 int v7; // r10d unsigned long long v8; // r11 long long v9; // r9 BOOL v10; // esi long long v11; // rdx long long v12; // r13 unsigned long long v13; // rax long long v14; // rcx _WORD *v15; // r14 unsigned int v16; // ebx long long v17; // rax long long v18; // rcx _WORD *v19; // r15 int v20; // esi int v21; // eax int v22; // eax long long v23; // rdx int v24; // eax int v26; // [rsp+0h] [rbp-80h] unsigned long long v27; // [rsp+8h] [rbp-78h] unsigned long long v28; // [rsp+10h] [rbp-70h] unsigned long long v29; // [rsp+18h] [rbp-68h] long long v30; // [rsp+20h] [rbp-60h] long long v31; // [rsp+28h] [rbp-58h] int v32; // [rsp+30h] [rbp-50h] unsigned long long v33; // [rsp+38h] [rbp-48h] long long v34; // [rsp+40h] [rbp-40h] long long v35; // [rsp+40h] [rbp-40h] long long v36; // [rsp+48h] [rbp-38h] BOOL v37; // [rsp+54h] [rbp-2Ch] v3 = *(unsigned __int8 *)(a1 + 178); if ( *(_BYTE *)(a1 + 178) ) { v4 = *(_QWORD *)(a1 + 96); v5 = (unsigned int)a2; v27 = a2 >> 8; v6 = (unsigned int)a2 >> 8; v7 = (unsigned __int8)a2; v8 = (unsigned int)a3; v28 = a3 >> 8; v9 = (unsigned int)a3 >> 8; v26 = (unsigned __int8)a3; v10 = a2 != a3; v11 = 56 * v3; v12 = 0LL; v29 = v5; v30 = v9; v31 = v6; v32 = v7; v33 = v8; v37 = v10; v36 = 56 * v3; while ( 1 ) { v13 = *(_QWORD *)(v4 + v12); if ( v13 >= v5 && (v14 = *(_QWORD *)(*(_QWORD *)(v4 + v12 + 16) + 8 * v6)) != 0 ) { v15 = (_WORD *)(v14 + 2LL * v7 * (unsigned int)*(unsigned __int8 *)(*(_QWORD *)(v4 + v12 + 8) + v6)); v11 = v36; } else { v15 = 0LL; } v16 = v10; if ( v13 >= v8 ) { v17 = *(_QWORD *)(*(_QWORD *)(v4 + v12 + 16) + 8 * v9); v16 = v10; if ( v17 ) { v16 = v10; if ( v15 ) { v18 = *(_QWORD *)(v4 + v12 + 8); v19 = (_WORD *)(v17 + 2LL * v26 * (unsigned int)*(unsigned __int8 *)(v18 + v9)); v16 = 1; if ( *v15 != *v19 ) return v16; v20 = *(unsigned __int8 *)(v18 + v27); v21 = *(unsigned __int8 *)(v18 + v28); if ( (unsigned __int8)v20 <= (unsigned __int8)v21 ) { v23 = (unsigned int)(2 * v20); if ( (unsigned __int8)v20 >= (unsigned __int8)v21 ) { v16 = memcmp(v15, v19, v23); v5 = v29; v9 = v30; v6 = v31; v7 = v32; v8 = v33; v10 = v37; v11 = v36; } else { v35 = *(unsigned __int8 *)(v18 + v27); v24 = bcmp(v15, v19, v23); v5 = v29; v9 = v30; v6 = v31; v7 = v32; v8 = v33; v10 = v37; v11 = v36; if ( v24 ) return v16; v16 = (unsigned __int16)v19[v35]; } } else { v34 = *(unsigned __int8 *)(v18 + v28); v22 = bcmp(v15, v19, (unsigned int)(2 * v21)); v10 = v37; v8 = v33; v7 = v32; v6 = v31; v9 = v30; v5 = v29; v11 = v36; if ( v22 ) return v16; v16 = (unsigned __int16)v15[v34]; } } } } if ( v16 ) break; v12 += 56LL; if ( v11 == v12 ) return 0; } } else { return 0; } return v16; }
my_uca_charcmp: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x58 MOVZX EAX,byte ptr [RDI + 0xb2] TEST RAX,RAX JZ 0x001bd6c0 MOV R12,qword ptr [RDI + 0x60] MOV EDI,ESI MOV R8,RSI SHR R8,0x8 MOV R9D,0xffffff MOV qword ptr [RBP + -0x78],R8 AND R8,R9 MOV ECX,0xff MOV R10,RSI AND R10,RCX MOV R11D,EDX MOV RBX,RDX SHR RBX,0x8 MOV qword ptr [RBP + -0x70],RBX AND R9,RBX AND RCX,RDX MOV qword ptr [RBP + -0x80],RCX CMP RSI,RDX MOV ESI,0x0 SETNZ SIL IMUL RDX,RAX,0x38 XOR R13D,R13D MOV qword ptr [RBP + -0x68],RDI MOV qword ptr [RBP + -0x60],R9 MOV qword ptr [RBP + -0x58],R8 MOV qword ptr [RBP + -0x50],R10 MOV qword ptr [RBP + -0x48],R11 MOV dword ptr [RBP + -0x2c],ESI MOV qword ptr [RBP + -0x38],RDX LAB_001bd570: MOV RAX,qword ptr [R12 + R13*0x1] CMP RAX,RDI JC 0x001bd59f MOV RCX,qword ptr [R12 + R13*0x1 + 0x10] MOV RCX,qword ptr [RCX + R8*0x8] TEST RCX,RCX JZ 0x001bd59f MOV RDX,qword ptr [R12 + R13*0x1 + 0x8] MOVZX EDX,byte ptr [RDX + R8*0x1] IMUL EDX,R10D LEA R14,[RCX + RDX*0x2] MOV RDX,qword ptr [RBP + -0x38] JMP 0x001bd5a2 LAB_001bd59f: XOR R14D,R14D LAB_001bd5a2: MOV EBX,ESI CMP RAX,R11 JC 0x001bd6af MOV RAX,qword ptr [R12 + R13*0x1 + 0x10] MOV RAX,qword ptr [RAX + R9*0x8] MOV EBX,ESI TEST RAX,RAX JZ 0x001bd6af MOV EBX,ESI TEST R14,R14 JZ 0x001bd6af MOV RCX,qword ptr [R12 + R13*0x1 + 0x8] MOVZX EDX,byte ptr [RCX + R9*0x1] IMUL EDX,dword ptr [RBP + -0x80] LEA R15,[RAX + RDX*0x2] MOVZX EAX,word ptr [R14] MOV EBX,0x1 CMP AX,word ptr [R15] JNZ 0x001bd6c2 MOV RAX,qword ptr [RBP + -0x78] MOVZX ESI,byte ptr [RCX + RAX*0x1] MOV RAX,qword ptr [RBP + -0x70] MOVZX EAX,byte ptr [RCX + RAX*0x1] CMP SIL,AL JBE 0x001bd646 MOV qword ptr [RBP + -0x40],RAX LEA EDX,[RAX + RAX*0x1] MOV RDI,R14 MOV RSI,R15 CALL 0x00129570 MOV ESI,dword ptr [RBP + -0x2c] MOV R11,qword ptr [RBP + -0x48] MOV R10,qword ptr [RBP + -0x50] MOV R8,qword ptr [RBP + -0x58] MOV R9,qword ptr [RBP + -0x60] MOV RDI,qword ptr [RBP + -0x68] TEST EAX,EAX MOV RDX,qword ptr [RBP + -0x38] JNZ 0x001bd6c2 MOV RAX,qword ptr [RBP + -0x40] MOVZX EBX,word ptr [R14 + RAX*0x2] JMP 0x001bd6af LAB_001bd646: LEA EDX,[RSI + RSI*0x1] CMP SIL,AL JNC 0x001bd687 MOV qword ptr [RBP + -0x40],RSI MOV RDI,R14 MOV RSI,R15 CALL 0x00129570 TEST EAX,EAX MOV RDI,qword ptr [RBP + -0x68] MOV R9,qword ptr [RBP + -0x60] MOV R8,qword ptr [RBP + -0x58] MOV R10,qword ptr [RBP + -0x50] MOV R11,qword ptr [RBP + -0x48] MOV ESI,dword ptr [RBP + -0x2c] MOV RDX,qword ptr [RBP + -0x38] JNZ 0x001bd6c2 MOV RAX,qword ptr [RBP + -0x40] MOVZX EBX,word ptr [R15 + RAX*0x2] JMP 0x001bd6af LAB_001bd687: MOV RDI,R14 MOV RSI,R15 CALL 0x00129890 MOV EBX,EAX MOV RDI,qword ptr [RBP + -0x68] MOV R9,qword ptr [RBP + -0x60] MOV R8,qword ptr [RBP + -0x58] MOV R10,qword ptr [RBP + -0x50] MOV R11,qword ptr [RBP + -0x48] MOV ESI,dword ptr [RBP + -0x2c] MOV RDX,qword ptr [RBP + -0x38] LAB_001bd6af: TEST EBX,EBX JNZ 0x001bd6c2 ADD R13,0x38 CMP RDX,R13 JNZ 0x001bd570 LAB_001bd6c0: XOR EBX,EBX LAB_001bd6c2: MOV EAX,EBX ADD RSP,0x58 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
uint my_uca_charcmp(long param_1,ulong param_2,ulong param_3) { short *__s2; byte bVar1; byte bVar2; byte bVar3; long lVar4; long lVar5; long lVar6; int iVar7; uint uVar8; ulong uVar9; ulong uVar10; long lVar11; short *__s1; uint local_88; bVar1 = *(byte *)(param_1 + 0xb2); if ((ulong)bVar1 != 0) { lVar4 = *(long *)(param_1 + 0x60); uVar9 = param_2 >> 8 & 0xffffff; uVar10 = param_3 >> 8 & 0xffffff; local_88 = (uint)param_3 & 0xff; lVar11 = 0; do { uVar8 = (uint)(param_2 != param_3); if ((*(ulong *)(lVar4 + lVar11) < (param_2 & 0xffffffff)) || (lVar5 = *(long *)(*(long *)(lVar4 + 0x10 + lVar11) + uVar9 * 8), lVar5 == 0)) { __s1 = (short *)0x0; } else { __s1 = (short *)(lVar5 + (ulong)((uint)*(byte *)(*(long *)(lVar4 + 8 + lVar11) + uVar9) * ((uint)param_2 & 0xff)) * 2); } if ((((param_3 & 0xffffffff) <= *(ulong *)(lVar4 + lVar11)) && (lVar5 = *(long *)(*(long *)(lVar4 + 0x10 + lVar11) + uVar10 * 8), lVar5 != 0)) && (__s1 != (short *)0x0)) { lVar6 = *(long *)(lVar4 + 8 + lVar11); __s2 = (short *)(lVar5 + (ulong)(*(byte *)(lVar6 + uVar10) * local_88) * 2); if (*__s1 != *__s2) { return 1; } bVar2 = *(byte *)(lVar6 + (param_2 >> 8)); bVar3 = *(byte *)(lVar6 + (param_3 >> 8)); if (bVar3 < bVar2) { iVar7 = bcmp(__s1,__s2,(ulong)((uint)bVar3 + (uint)bVar3)); if (iVar7 != 0) { return 1; } uVar8 = (uint)(ushort)__s1[bVar3]; } else if (bVar2 < bVar3) { iVar7 = bcmp(__s1,__s2,(ulong)((uint)bVar2 + (uint)bVar2)); if (iVar7 != 0) { return 1; } uVar8 = (uint)(ushort)__s2[bVar2]; } else { uVar8 = memcmp(__s1,__s2,(ulong)((uint)bVar2 + (uint)bVar2)); } } if (uVar8 != 0) { return uVar8; } lVar11 = lVar11 + 0x38; } while ((ulong)bVar1 * 0x38 != lVar11); } return 0; }
20,514
Bfree
eloqsql/strings/dtoa.c
static void Bfree(Bigint *v, Stack_alloc *alloc) { char *gptr= (char*) v; /* generic pointer */ if (gptr < alloc->begin || gptr >= alloc->end) free(gptr); else if (v->k <= Kmax) { /* Maintain free lists only for stack objects: this way we don't have to bother with freeing lists in the end of dtoa; heap should not be used normally anyway. */ v->p.next= alloc->freelist[v->k]; alloc->freelist[v->k]= v; } }
O3
c
Bfree: pushq %rbp movq %rsp, %rbp cmpq %rdi, (%rsi) ja 0x57419 cmpq %rdi, 0x10(%rsi) jbe 0x57419 movslq 0x8(%rdi), %rax cmpq $0xf, %rax jg 0x57417 movq 0x18(%rsi,%rax,8), %rcx movq %rcx, (%rdi) movq %rdi, 0x18(%rsi,%rax,8) popq %rbp retq popq %rbp jmp 0x24340
Bfree: push rbp mov rbp, rsp cmp [rsi], rdi ja short loc_57419 cmp [rsi+10h], rdi jbe short loc_57419 movsxd rax, dword ptr [rdi+8] cmp rax, 0Fh jg short loc_57417 mov rcx, [rsi+rax*8+18h] mov [rdi], rcx mov [rsi+rax*8+18h], rdi loc_57417: pop rbp retn loc_57419: pop rbp jmp _free
long long Bfree(unsigned long long a1, unsigned long long *a2) { long long result; // rax if ( *a2 > a1 || a2[2] <= a1 ) return free(a1, a2); result = *(int *)(a1 + 8); if ( result <= 15 ) { *(_QWORD *)a1 = a2[result + 3]; a2[result + 3] = a1; } return result; }
Bfree: PUSH RBP MOV RBP,RSP CMP qword ptr [RSI],RDI JA 0x00157419 CMP qword ptr [RSI + 0x10],RDI JBE 0x00157419 MOVSXD RAX,dword ptr [RDI + 0x8] CMP RAX,0xf JG 0x00157417 MOV RCX,qword ptr [RSI + RAX*0x8 + 0x18] MOV qword ptr [RDI],RCX MOV qword ptr [RSI + RAX*0x8 + 0x18],RDI LAB_00157417: POP RBP RET LAB_00157419: POP RBP JMP 0x00124340
void Bfree(ulong *param_1,ulong *param_2) { long lVar1; if (((ulong *)*param_2 <= param_1) && (param_1 < (ulong *)param_2[2])) { lVar1 = (long)(int)param_1[1]; if (lVar1 < 0x10) { *param_1 = param_2[lVar1 + 3]; param_2[lVar1 + 3] = (ulong)param_1; } return; } free(param_1); return; }
20,515
unlink_block
eloqsql/storage/maria/ma_pagecache.c
static void unlink_block(PAGECACHE *pagecache, PAGECACHE_BLOCK_LINK *block) { DBUG_ENTER("unlink_block"); DBUG_PRINT("pagecache", ("unlink %p", block)); DBUG_ASSERT(block->next_used != NULL); if (block->next_used == block) { /* The list contains only one member */ pagecache->used_last= pagecache->used_ins= NULL; } else { block->next_used->prev_used= block->prev_used; *block->prev_used= block->next_used; if (pagecache->used_last == block) pagecache->used_last= STRUCT_PTR(PAGECACHE_BLOCK_LINK, next_used, block->prev_used); if (pagecache->used_ins == block) pagecache->used_ins= STRUCT_PTR(PAGECACHE_BLOCK_LINK, next_used, block->prev_used); } block->next_used= NULL; KEYCACHE_THREAD_TRACE("unlink_block"); #if defined(PAGECACHE_DEBUG) KEYCACHE_DBUG_ASSERT(pagecache->blocks_available != 0); pagecache->blocks_available--; KEYCACHE_DBUG_PRINT("pagecache", ("unlinked block: %p (%u) status: %x #requests: %u #available: %u", block, PCBLOCK_NUMBER(pagecache, block), block->status, block->requests, pagecache->blocks_available)); PCBLOCK_INFO(block); #endif DBUG_VOID_RETURN; }
O3
c
unlink_block: movq (%rsi), %rax cmpq %rsi, %rax je 0x34fae pushq %rbp movq %rsp, %rbp movq 0x8(%rsi), %rcx movq %rcx, 0x8(%rax) movq (%rsi), %rax movq %rax, (%rcx) cmpq %rsi, 0xb8(%rdi) jne 0x34f97 movq 0x8(%rsi), %rax movq %rax, 0xb8(%rdi) cmpq %rsi, 0xc0(%rdi) jne 0x34fab movq 0x8(%rsi), %rax movq %rax, 0xc0(%rdi) popq %rbp jmp 0x34fb8 xorps %xmm0, %xmm0 movups %xmm0, 0xb8(%rdi) movq $0x0, (%rsi) retq
unlink_block: mov rax, [rsi] cmp rax, rsi jz short loc_34FAE push rbp mov rbp, rsp mov rcx, [rsi+8] mov [rax+8], rcx mov rax, [rsi] mov [rcx], rax cmp [rdi+0B8h], rsi jnz short loc_34F97 mov rax, [rsi+8] mov [rdi+0B8h], rax loc_34F97: cmp [rdi+0C0h], rsi jnz short loc_34FAB mov rax, [rsi+8] mov [rdi+0C0h], rax loc_34FAB: pop rbp jmp short loc_34FB8 loc_34FAE: xorps xmm0, xmm0 movups xmmword ptr [rdi+0B8h], xmm0 loc_34FB8: mov qword ptr [rsi], 0 retn
_QWORD * unlink_block(long long a1, _QWORD *a2) { _QWORD *result; // rax _QWORD *v3; // rcx result = (_QWORD *)*a2; if ( (_QWORD *)*a2 == a2 ) { *(_OWORD *)(a1 + 184) = 0LL; } else { v3 = (_QWORD *)a2[1]; result[1] = v3; result = (_QWORD *)*a2; *v3 = *a2; if ( *(_QWORD **)(a1 + 184) == a2 ) { result = (_QWORD *)a2[1]; *(_QWORD *)(a1 + 184) = result; } if ( *(_QWORD **)(a1 + 192) == a2 ) { result = (_QWORD *)a2[1]; *(_QWORD *)(a1 + 192) = result; } } *a2 = 0LL; return result; }
unlink_block: MOV RAX,qword ptr [RSI] CMP RAX,RSI JZ 0x00134fae 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 + 0xb8],RSI JNZ 0x00134f97 MOV RAX,qword ptr [RSI + 0x8] MOV qword ptr [RDI + 0xb8],RAX LAB_00134f97: CMP qword ptr [RDI + 0xc0],RSI JNZ 0x00134fab MOV RAX,qword ptr [RSI + 0x8] MOV qword ptr [RDI + 0xc0],RAX LAB_00134fab: POP RBP JMP 0x00134fb8 LAB_00134fae: XORPS XMM0,XMM0 MOVUPS xmmword ptr [RDI + 0xb8],XMM0 LAB_00134fb8: 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 + 0xb8) = 0; *(int8 *)(param_1 + 0xc0) = 0; } else { puVar1 = (int8 *)param_2[1]; ((int8 *)*param_2)[1] = puVar1; *puVar1 = *param_2; if (*(int8 **)(param_1 + 0xb8) == param_2) { *(int8 *)(param_1 + 0xb8) = param_2[1]; } if (*(int8 **)(param_1 + 0xc0) == param_2) { *(int8 *)(param_1 + 0xc0) = param_2[1]; } } *param_2 = 0; return; }
20,516
pack_dirname
eloqsql/mysys/mf_pack.c
void pack_dirname(char * to, const char *from) { int cwd_err; size_t d_length,length,UNINIT_VAR(buff_length); char * start; char buff[FN_REFLEN + 1]; DBUG_ENTER("pack_dirname"); (void) intern_filename(to,from); /* Change to intern name */ #ifdef FN_DEVCHAR if ((start=strrchr(to,FN_DEVCHAR)) != 0) /* Skip device part */ start++; else #endif start=to; if (!(cwd_err= my_getwd(buff,FN_REFLEN,MYF(0)))) { buff_length= strlen(buff); d_length= (size_t) (start-to); if ((start == to || (buff_length == d_length && !memcmp(buff,start,d_length))) && *start != FN_LIBCHAR && *start) { /* Put current dir before */ bchange((uchar*) to, d_length, (uchar*) buff, buff_length, strlen(to)+1); } } if ((d_length= cleanup_dirname(to,to)) != 0) { length=0; if (home_dir) { length= strlen(home_dir); if (home_dir[length-1] == FN_LIBCHAR) length--; /* Don't test last '/' */ } if (length > 1 && length < d_length) { /* test if /xx/yy -> ~/yy */ if (memcmp(to,home_dir,length) == 0 && to[length] == FN_LIBCHAR) { to[0]=FN_HOMELIB; /* Filename begins with ~ */ (void) strmov_overlapp(to+1,to+length); } } if (! cwd_err) { /* Test if cwd is ~/... */ if (length > 1 && length < buff_length) { if (memcmp(buff,home_dir,length) == 0 && buff[length] == FN_LIBCHAR) { buff[0]=FN_HOMELIB; (void) strmov_overlapp(buff+1,buff+length); } } if (is_prefix(to,buff)) { length= strlen(buff); if (to[length]) (void) strmov_overlapp(to,to+length); /* Remove everything before */ else { to[0]= FN_CURLIB; /* Put ./ instead of cwd */ to[1]= FN_LIBCHAR; to[2]= '\0'; } } } } DBUG_PRINT("exit",("to: '%s'",to)); DBUG_VOID_RETURN; }
O0
c
pack_dirname: pushq %rbp movq %rsp, %rbp subq $0x270, %rsp # imm = 0x270 movq %fs:0x28, %rax movq %rax, -0x8(%rbp) movq %rdi, -0x218(%rbp) movq %rsi, -0x220(%rbp) movq -0x240(%rbp), %rax movq %rax, -0x240(%rbp) movq -0x218(%rbp), %rdi movq -0x220(%rbp), %rsi callq 0x35da0 movq -0x218(%rbp), %rax movq %rax, -0x248(%rbp) leaq -0x210(%rbp), %rdi movl $0x200, %esi # imm = 0x200 xorl %eax, %eax movl %eax, %edx callq 0x385d0 movl %eax, -0x224(%rbp) cmpl $0x0, %eax jne 0x35b67 leaq -0x210(%rbp), %rdi callq 0x25130 movq %rax, -0x240(%rbp) movq -0x248(%rbp), %rax movq -0x218(%rbp), %rcx subq %rcx, %rax movq %rax, -0x230(%rbp) movq -0x248(%rbp), %rax cmpq -0x218(%rbp), %rax je 0x35adb movq -0x240(%rbp), %rax cmpq -0x230(%rbp), %rax jne 0x35b65 leaq -0x210(%rbp), %rdi movq -0x248(%rbp), %rsi movq -0x230(%rbp), %rdx callq 0x25140 cmpl $0x0, %eax jne 0x35b65 movq -0x248(%rbp), %rax movsbl (%rax), %eax cmpl $0x2f, %eax je 0x35b65 movq -0x248(%rbp), %rax movsbl (%rax), %eax cmpl $0x0, %eax je 0x35b65 movq -0x218(%rbp), %rax movq %rax, -0x268(%rbp) movq -0x230(%rbp), %rax movq %rax, -0x260(%rbp) leaq -0x210(%rbp), %rax movq %rax, -0x258(%rbp) movq -0x240(%rbp), %rax movq %rax, -0x250(%rbp) movq -0x218(%rbp), %rdi callq 0x25130 movq -0x268(%rbp), %rdi movq -0x260(%rbp), %rsi movq -0x258(%rbp), %rdx movq -0x250(%rbp), %rcx movq %rax, %r8 addq $0x1, %r8 callq 0x3ccb0 jmp 0x35b67 movq -0x218(%rbp), %rdi movq -0x218(%rbp), %rsi callq 0x35e90 movq %rax, -0x230(%rbp) cmpq $0x0, %rax je 0x35d6d movq $0x0, -0x238(%rbp) leaq 0x35b90b(%rip), %rax # 0x3914a8 cmpq $0x0, (%rax) je 0x35beb leaq 0x35b8fe(%rip), %rax # 0x3914a8 movq (%rax), %rdi callq 0x25130 movq %rax, -0x238(%rbp) leaq 0x35b8e8(%rip), %rax # 0x3914a8 movq (%rax), %rax movq -0x238(%rbp), %rcx subq $0x1, %rcx movsbl (%rax,%rcx), %eax cmpl $0x2f, %eax jne 0x35be9 movq -0x238(%rbp), %rax addq $-0x1, %rax movq %rax, -0x238(%rbp) jmp 0x35beb cmpq $0x1, -0x238(%rbp) jbe 0x35c68 movq -0x238(%rbp), %rax cmpq -0x230(%rbp), %rax jae 0x35c68 movq -0x218(%rbp), %rdi leaq 0x35b895(%rip), %rax # 0x3914a8 movq (%rax), %rsi movq -0x238(%rbp), %rdx callq 0x25140 cmpl $0x0, %eax jne 0x35c66 movq -0x218(%rbp), %rax movq -0x238(%rbp), %rcx movsbl (%rax,%rcx), %eax cmpl $0x2f, %eax jne 0x35c66 movq -0x218(%rbp), %rax movb $0x7e, (%rax) movq -0x218(%rbp), %rdi addq $0x1, %rdi movq -0x218(%rbp), %rsi addq -0x238(%rbp), %rsi callq 0x81670 jmp 0x35c68 cmpl $0x0, -0x224(%rbp) jne 0x35d6b cmpq $0x1, -0x238(%rbp) jbe 0x35cec movq -0x238(%rbp), %rax cmpq -0x240(%rbp), %rax jae 0x35cec leaq -0x210(%rbp), %rdi leaq 0x35b80b(%rip), %rax # 0x3914a8 movq (%rax), %rsi movq -0x238(%rbp), %rdx callq 0x25140 cmpl $0x0, %eax jne 0x35cea movq -0x238(%rbp), %rax movsbl -0x210(%rbp,%rax), %eax cmpl $0x2f, %eax jne 0x35cea movb $0x7e, -0x210(%rbp) leaq -0x210(%rbp), %rdi addq $0x1, %rdi leaq -0x210(%rbp), %rsi addq -0x238(%rbp), %rsi callq 0x81670 jmp 0x35cec movq -0x218(%rbp), %rdi leaq -0x210(%rbp), %rsi callq 0x7c530 cmpl $0x0, %eax je 0x35d69 leaq -0x210(%rbp), %rdi callq 0x25130 movq %rax, -0x238(%rbp) movq -0x218(%rbp), %rax movq -0x238(%rbp), %rcx cmpb $0x0, (%rax,%rcx) je 0x35d47 movq -0x218(%rbp), %rdi movq -0x218(%rbp), %rsi addq -0x238(%rbp), %rsi callq 0x81670 jmp 0x35d67 movq -0x218(%rbp), %rax movb $0x2e, (%rax) movq -0x218(%rbp), %rax movb $0x2f, 0x1(%rax) movq -0x218(%rbp), %rax movb $0x0, 0x2(%rax) jmp 0x35d69 jmp 0x35d6b jmp 0x35d6d jmp 0x35d6f jmp 0x35d71 jmp 0x35d73 jmp 0x35d75 movq %fs:0x28, %rax movq -0x8(%rbp), %rcx cmpq %rcx, %rax jne 0x35d90 addq $0x270, %rsp # imm = 0x270 popq %rbp retq callq 0x25330 nopw %cs:(%rax,%rax)
pack_dirname: push rbp mov rbp, rsp sub rsp, 270h mov rax, fs:28h mov [rbp+var_8], rax mov [rbp+var_218], rdi mov [rbp+var_220], rsi mov rax, [rbp+var_240] mov [rbp+var_240], rax mov rdi, [rbp+var_218] mov rsi, [rbp+var_220] call intern_filename mov rax, [rbp+var_218] mov [rbp+var_248], rax lea rdi, [rbp+var_210] mov esi, 200h xor eax, eax mov edx, eax call my_getwd mov [rbp+var_224], eax cmp eax, 0 jnz loc_35B67 lea rdi, [rbp+var_210] call _strlen mov [rbp+var_240], rax mov rax, [rbp+var_248] mov rcx, [rbp+var_218] sub rax, rcx mov [rbp+var_230], rax mov rax, [rbp+var_248] cmp rax, [rbp+var_218] jz short loc_35ADB mov rax, [rbp+var_240] cmp rax, [rbp+var_230] jnz loc_35B65 lea rdi, [rbp+var_210] mov rsi, [rbp+var_248] mov rdx, [rbp+var_230] call _memcmp cmp eax, 0 jnz loc_35B65 loc_35ADB: mov rax, [rbp+var_248] movsx eax, byte ptr [rax] cmp eax, 2Fh ; '/' jz short loc_35B65 mov rax, [rbp+var_248] movsx eax, byte ptr [rax] cmp eax, 0 jz short loc_35B65 mov rax, [rbp+var_218] mov [rbp+var_268], rax mov rax, [rbp+var_230] mov [rbp+var_260], rax lea rax, [rbp+var_210] mov [rbp+var_258], rax mov rax, [rbp+var_240] mov [rbp+var_250], rax mov rdi, [rbp+var_218] call _strlen mov rdi, [rbp+var_268] mov rsi, [rbp+var_260] mov rdx, [rbp+var_258] mov rcx, [rbp+var_250] mov r8, rax add r8, 1 call bchange loc_35B65: jmp short $+2 loc_35B67: mov rdi, [rbp+var_218] mov rsi, [rbp+var_218] call cleanup_dirname mov [rbp+var_230], rax cmp rax, 0 jz loc_35D6D mov [rbp+var_238], 0 lea rax, home_dir cmp qword ptr [rax], 0 jz short loc_35BEB lea rax, home_dir mov rdi, [rax] call _strlen mov [rbp+var_238], rax lea rax, home_dir mov rax, [rax] mov rcx, [rbp+var_238] sub rcx, 1 movsx eax, byte ptr [rax+rcx] cmp eax, 2Fh ; '/' jnz short loc_35BE9 mov rax, [rbp+var_238] add rax, 0FFFFFFFFFFFFFFFFh mov [rbp+var_238], rax loc_35BE9: jmp short $+2 loc_35BEB: cmp [rbp+var_238], 1 jbe short loc_35C68 mov rax, [rbp+var_238] cmp rax, [rbp+var_230] jnb short loc_35C68 mov rdi, [rbp+var_218] lea rax, home_dir mov rsi, [rax] mov rdx, [rbp+var_238] call _memcmp cmp eax, 0 jnz short loc_35C66 mov rax, [rbp+var_218] mov rcx, [rbp+var_238] movsx eax, byte ptr [rax+rcx] cmp eax, 2Fh ; '/' jnz short loc_35C66 mov rax, [rbp+var_218] mov byte ptr [rax], 7Eh ; '~' mov rdi, [rbp+var_218] add rdi, 1 mov rsi, [rbp+var_218] add rsi, [rbp+var_238] call strmov_overlapp loc_35C66: jmp short $+2 loc_35C68: cmp [rbp+var_224], 0 jnz loc_35D6B cmp [rbp+var_238], 1 jbe short loc_35CEC mov rax, [rbp+var_238] cmp rax, [rbp+var_240] jnb short loc_35CEC lea rdi, [rbp+var_210] lea rax, home_dir mov rsi, [rax] mov rdx, [rbp+var_238] call _memcmp cmp eax, 0 jnz short loc_35CEA mov rax, [rbp+var_238] movsx eax, [rbp+rax+var_210] cmp eax, 2Fh ; '/' jnz short loc_35CEA mov [rbp+var_210], 7Eh ; '~' lea rdi, [rbp+var_210] add rdi, 1 lea rsi, [rbp+var_210] add rsi, [rbp+var_238] call strmov_overlapp loc_35CEA: jmp short $+2 loc_35CEC: mov rdi, [rbp+var_218] lea rsi, [rbp+var_210] call is_prefix cmp eax, 0 jz short loc_35D69 lea rdi, [rbp+var_210] call _strlen mov [rbp+var_238], rax mov rax, [rbp+var_218] mov rcx, [rbp+var_238] cmp byte ptr [rax+rcx], 0 jz short loc_35D47 mov rdi, [rbp+var_218] mov rsi, [rbp+var_218] add rsi, [rbp+var_238] call strmov_overlapp jmp short loc_35D67 loc_35D47: mov rax, [rbp+var_218] mov byte ptr [rax], 2Eh ; '.' mov rax, [rbp+var_218] mov byte ptr [rax+1], 2Fh ; '/' mov rax, [rbp+var_218] mov byte ptr [rax+2], 0 loc_35D67: jmp short $+2 loc_35D69: jmp short $+2 loc_35D6B: jmp short $+2 loc_35D6D: jmp short $+2 loc_35D6F: jmp short $+2 loc_35D71: jmp short $+2 loc_35D73: jmp short $+2 loc_35D75: mov rax, fs:28h mov rcx, [rbp+var_8] cmp rax, rcx jnz short loc_35D90 add rsp, 270h pop rbp retn loc_35D90: call ___stack_chk_fail
unsigned long long pack_dirname(_BYTE *a1, long long a2) { long long v2; // rax unsigned long long v4; // [rsp+30h] [rbp-240h] unsigned long long v5; // [rsp+38h] [rbp-238h] long long v6; // [rsp+38h] [rbp-238h] long long v7; // [rsp+40h] [rbp-230h] unsigned long long v8; // [rsp+40h] [rbp-230h] int v9; // [rsp+4Ch] [rbp-224h] _BYTE *v10; // [rsp+58h] [rbp-218h] char v11; // [rsp+60h] [rbp-210h] BYREF _BYTE v12[527]; // [rsp+61h] [rbp-20Fh] BYREF *(_QWORD *)&v12[519] = __readfsqword(0x28u); v10 = a1; intern_filename(a1, a2); v9 = my_getwd(&v11, 512LL, 0LL); if ( !v9 ) { v4 = strlen(&v11); v7 = a1 - v10; if ( (a1 == v10 || v4 == v7 && !(unsigned int)memcmp(&v11, a1, v7)) && *a1 != 47 && *a1 ) { v2 = strlen(v10); bchange(v10, v7, &v11, v4, v2 + 1); } } v8 = cleanup_dirname(v10, v10); if ( v8 ) { v5 = 0LL; if ( home_dir ) { v5 = strlen(home_dir); if ( *(_BYTE *)(home_dir + v5 - 1) == 47 ) --v5; } if ( v5 > 1 && v5 < v8 && !(unsigned int)memcmp(v10, home_dir, v5) && v10[v5] == 47 ) { *v10 = 126; strmov_overlapp(v10 + 1, &v10[v5]); } if ( !v9 ) { if ( v5 > 1 && v5 < v4 && !(unsigned int)memcmp(&v11, home_dir, v5) && v12[v5 - 1] == 47 ) { v11 = 126; strmov_overlapp(v12, &v12[v5 - 1]); } if ( (unsigned int)is_prefix(v10, &v11) ) { v6 = strlen(&v11); if ( v10[v6] ) { strmov_overlapp(v10, &v10[v6]); } else { *v10 = 46; v10[1] = 47; v10[2] = 0; } } } } return __readfsqword(0x28u); }
pack_dirname: PUSH RBP MOV RBP,RSP SUB RSP,0x270 MOV RAX,qword ptr FS:[0x28] MOV qword ptr [RBP + -0x8],RAX MOV qword ptr [RBP + -0x218],RDI MOV qword ptr [RBP + -0x220],RSI MOV RAX,qword ptr [RBP + -0x240] MOV qword ptr [RBP + -0x240],RAX MOV RDI,qword ptr [RBP + -0x218] MOV RSI,qword ptr [RBP + -0x220] CALL 0x00135da0 MOV RAX,qword ptr [RBP + -0x218] MOV qword ptr [RBP + -0x248],RAX LEA RDI,[RBP + -0x210] MOV ESI,0x200 XOR EAX,EAX MOV EDX,EAX CALL 0x001385d0 MOV dword ptr [RBP + -0x224],EAX CMP EAX,0x0 JNZ 0x00135b67 LEA RDI,[RBP + -0x210] CALL 0x00125130 MOV qword ptr [RBP + -0x240],RAX MOV RAX,qword ptr [RBP + -0x248] MOV RCX,qword ptr [RBP + -0x218] SUB RAX,RCX MOV qword ptr [RBP + -0x230],RAX MOV RAX,qword ptr [RBP + -0x248] CMP RAX,qword ptr [RBP + -0x218] JZ 0x00135adb MOV RAX,qword ptr [RBP + -0x240] CMP RAX,qword ptr [RBP + -0x230] JNZ 0x00135b65 LEA RDI,[RBP + -0x210] MOV RSI,qword ptr [RBP + -0x248] MOV RDX,qword ptr [RBP + -0x230] CALL 0x00125140 CMP EAX,0x0 JNZ 0x00135b65 LAB_00135adb: MOV RAX,qword ptr [RBP + -0x248] MOVSX EAX,byte ptr [RAX] CMP EAX,0x2f JZ 0x00135b65 MOV RAX,qword ptr [RBP + -0x248] MOVSX EAX,byte ptr [RAX] CMP EAX,0x0 JZ 0x00135b65 MOV RAX,qword ptr [RBP + -0x218] MOV qword ptr [RBP + -0x268],RAX MOV RAX,qword ptr [RBP + -0x230] MOV qword ptr [RBP + -0x260],RAX LEA RAX,[RBP + -0x210] MOV qword ptr [RBP + -0x258],RAX MOV RAX,qword ptr [RBP + -0x240] MOV qword ptr [RBP + -0x250],RAX MOV RDI,qword ptr [RBP + -0x218] CALL 0x00125130 MOV RDI,qword ptr [RBP + -0x268] MOV RSI,qword ptr [RBP + -0x260] MOV RDX,qword ptr [RBP + -0x258] MOV RCX,qword ptr [RBP + -0x250] MOV R8,RAX ADD R8,0x1 CALL 0x0013ccb0 LAB_00135b65: JMP 0x00135b67 LAB_00135b67: MOV RDI,qword ptr [RBP + -0x218] MOV RSI,qword ptr [RBP + -0x218] CALL 0x00135e90 MOV qword ptr [RBP + -0x230],RAX CMP RAX,0x0 JZ 0x00135d6d MOV qword ptr [RBP + -0x238],0x0 LEA RAX,[0x4914a8] CMP qword ptr [RAX],0x0 JZ 0x00135beb LEA RAX,[0x4914a8] MOV RDI,qword ptr [RAX] CALL 0x00125130 MOV qword ptr [RBP + -0x238],RAX LEA RAX,[0x4914a8] MOV RAX,qword ptr [RAX] MOV RCX,qword ptr [RBP + -0x238] SUB RCX,0x1 MOVSX EAX,byte ptr [RAX + RCX*0x1] CMP EAX,0x2f JNZ 0x00135be9 MOV RAX,qword ptr [RBP + -0x238] ADD RAX,-0x1 MOV qword ptr [RBP + -0x238],RAX LAB_00135be9: JMP 0x00135beb LAB_00135beb: CMP qword ptr [RBP + -0x238],0x1 JBE 0x00135c68 MOV RAX,qword ptr [RBP + -0x238] CMP RAX,qword ptr [RBP + -0x230] JNC 0x00135c68 MOV RDI,qword ptr [RBP + -0x218] LEA RAX,[0x4914a8] MOV RSI,qword ptr [RAX] MOV RDX,qword ptr [RBP + -0x238] CALL 0x00125140 CMP EAX,0x0 JNZ 0x00135c66 MOV RAX,qword ptr [RBP + -0x218] MOV RCX,qword ptr [RBP + -0x238] MOVSX EAX,byte ptr [RAX + RCX*0x1] CMP EAX,0x2f JNZ 0x00135c66 MOV RAX,qword ptr [RBP + -0x218] MOV byte ptr [RAX],0x7e MOV RDI,qword ptr [RBP + -0x218] ADD RDI,0x1 MOV RSI,qword ptr [RBP + -0x218] ADD RSI,qword ptr [RBP + -0x238] CALL 0x00181670 LAB_00135c66: JMP 0x00135c68 LAB_00135c68: CMP dword ptr [RBP + -0x224],0x0 JNZ 0x00135d6b CMP qword ptr [RBP + -0x238],0x1 JBE 0x00135cec MOV RAX,qword ptr [RBP + -0x238] CMP RAX,qword ptr [RBP + -0x240] JNC 0x00135cec LEA RDI,[RBP + -0x210] LEA RAX,[0x4914a8] MOV RSI,qword ptr [RAX] MOV RDX,qword ptr [RBP + -0x238] CALL 0x00125140 CMP EAX,0x0 JNZ 0x00135cea MOV RAX,qword ptr [RBP + -0x238] MOVSX EAX,byte ptr [RBP + RAX*0x1 + -0x210] CMP EAX,0x2f JNZ 0x00135cea MOV byte ptr [RBP + -0x210],0x7e LEA RDI,[RBP + -0x210] ADD RDI,0x1 LEA RSI,[RBP + -0x210] ADD RSI,qword ptr [RBP + -0x238] CALL 0x00181670 LAB_00135cea: JMP 0x00135cec LAB_00135cec: MOV RDI,qword ptr [RBP + -0x218] LEA RSI,[RBP + -0x210] CALL 0x0017c530 CMP EAX,0x0 JZ 0x00135d69 LEA RDI,[RBP + -0x210] CALL 0x00125130 MOV qword ptr [RBP + -0x238],RAX MOV RAX,qword ptr [RBP + -0x218] MOV RCX,qword ptr [RBP + -0x238] CMP byte ptr [RAX + RCX*0x1],0x0 JZ 0x00135d47 MOV RDI,qword ptr [RBP + -0x218] MOV RSI,qword ptr [RBP + -0x218] ADD RSI,qword ptr [RBP + -0x238] CALL 0x00181670 JMP 0x00135d67 LAB_00135d47: MOV RAX,qword ptr [RBP + -0x218] MOV byte ptr [RAX],0x2e MOV RAX,qword ptr [RBP + -0x218] MOV byte ptr [RAX + 0x1],0x2f MOV RAX,qword ptr [RBP + -0x218] MOV byte ptr [RAX + 0x2],0x0 LAB_00135d67: JMP 0x00135d69 LAB_00135d69: JMP 0x00135d6b LAB_00135d6b: JMP 0x00135d6d LAB_00135d6d: JMP 0x00135d6f LAB_00135d6f: JMP 0x00135d71 LAB_00135d71: JMP 0x00135d73 LAB_00135d73: JMP 0x00135d75 LAB_00135d75: MOV RAX,qword ptr FS:[0x28] MOV RCX,qword ptr [RBP + -0x8] CMP RAX,RCX JNZ 0x00135d90 ADD RSP,0x270 POP RBP RET LAB_00135d90: CALL 0x00125330
/* WARNING: Removing unreachable block (ram,0x00135aa4) */ /* WARNING: Removing unreachable block (ram,0x00135ab8) */ void pack_dirname(char *param_1,int8 param_2) { int iVar1; int iVar2; size_t sVar3; ulong uVar4; long in_FS_OFFSET; ulong local_248; ulong local_240; char local_218 [520]; long local_10; local_10 = *(long *)(in_FS_OFFSET + 0x28); intern_filename(param_1,param_2); iVar1 = my_getwd(local_218,0x200,0); if (((iVar1 == 0) && (local_248 = strlen(local_218), *param_1 != '/')) && (*param_1 != '\0')) { sVar3 = strlen(param_1); bchange(param_1,0,local_218,local_248,sVar3 + 1); } uVar4 = cleanup_dirname(param_1,param_1); if (uVar4 != 0) { local_240 = 0; if ((home_dir != (char *)0x0) && (local_240 = strlen(home_dir), home_dir[local_240 - 1] == '/')) { local_240 = local_240 - 1; } if (((1 < local_240) && (local_240 < uVar4)) && ((iVar2 = memcmp(param_1,home_dir,local_240), iVar2 == 0 && (param_1[local_240] == '/')))) { *param_1 = '~'; strmov_overlapp(param_1 + 1,param_1 + local_240); } if (iVar1 == 0) { if ((((1 < local_240) && (local_240 < local_248)) && (iVar1 = memcmp(local_218,home_dir,local_240), iVar1 == 0)) && (local_218[local_240] == '/')) { local_218[0] = '~'; strmov_overlapp(local_218 + 1,local_218 + local_240); } iVar1 = is_prefix(param_1,local_218); if (iVar1 != 0) { sVar3 = strlen(local_218); if (param_1[sVar3] == '\0') { *param_1 = '.'; param_1[1] = '/'; param_1[2] = '\0'; } else { strmov_overlapp(param_1,param_1 + sVar3); } } } } if (*(long *)(in_FS_OFFSET + 0x28) == local_10) { return; } /* WARNING: Subroutine does not return */ __stack_chk_fail(); }
20,517
mi_nommap_pread
eloqsql/storage/myisam/mi_dynrec.c
size_t mi_nommap_pread(MI_INFO *info, uchar *Buffer, size_t Count, my_off_t offset, myf MyFlags) { return mysql_file_pread(info->dfile, Buffer, Count, offset, MyFlags); }
O3
c
mi_nommap_pread: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x58, %rsp movq %r8, -0x30(%rbp) movq %rcx, %r12 movq %rdx, %r14 movq %rsi, %r13 movl 0x1c0(%rdi), %ebx leaq 0x30f105(%rip), %rax # 0x386010 movq (%rax), %rax leaq -0x78(%rbp), %rdi movl %ebx, %esi movl $0x6, %edx callq *0x158(%rax) testq %rax, %rax jne 0x76f4d movl %ebx, %edi movq %r13, %rsi movq %r14, %rdx movq %r12, %rcx movq -0x30(%rbp), %r8 callq 0xa0660 movq %rax, %rbx movq %rbx, %rax addq $0x58, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq movq %rax, %r15 leaq 0x30f0b9(%rip), %rax # 0x386010 movq (%rax), %rax leaq 0x64c52(%rip), %rdx # 0xdbbb3 movq %r15, %rdi movq %r14, %rsi movl $0xca, %ecx callq *0x210(%rax) movl %ebx, %edi movq %r13, %rsi movq %r14, %rdx movq %r12, %rcx movq -0x30(%rbp), %r12 movq %r12, %r8 callq 0xa0660 movq %rax, %rbx xorl %esi, %esi testq %rax, %rax cmovneq %rsi, %r14 cmpq $-0x1, %rax cmovneq %rax, %rsi testb $0x6, %r12b cmovneq %r14, %rsi leaq 0x30f064(%rip), %rax # 0x386010 movq (%rax), %rax movq %r15, %rdi callq *0x218(%rax) jmp 0x76f3b
mi_nommap_pread: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx sub rsp, 58h mov [rbp+var_30], r8 mov r12, rcx mov r14, rdx mov r13, rsi mov ebx, [rdi+1C0h] lea rax, PSI_server mov rax, [rax] lea rdi, [rbp+var_78] mov esi, ebx mov edx, 6 call qword ptr [rax+158h] test rax, rax jnz short loc_76F4D mov edi, ebx mov rsi, r13 mov rdx, r14 mov rcx, r12 mov r8, [rbp+var_30] call my_pread mov rbx, rax loc_76F3B: mov rax, rbx add rsp, 58h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn loc_76F4D: mov r15, rax lea rax, PSI_server mov rax, [rax] lea rdx, aWorkspaceLlm4b_12; "/workspace/llm4binary/github2025/eloqsq"... mov rdi, r15 mov rsi, r14 mov ecx, 0CAh call qword ptr [rax+210h] mov edi, ebx mov rsi, r13 mov rdx, r14 mov rcx, r12 mov r12, [rbp+var_30] mov r8, r12 call my_pread mov rbx, rax xor esi, esi test rax, rax cmovnz r14, rsi cmp rax, 0FFFFFFFFFFFFFFFFh cmovnz rsi, rax test r12b, 6 cmovnz rsi, r14 lea rax, PSI_server mov rax, [rax] mov rdi, r15 call qword ptr [rax+218h] jmp short loc_76F3B
long long mi_nommap_pread(long long a1, long long a2, long long a3, long long a4, long long a5) { unsigned int v7; // ebx long long v8; // rax long long v9; // rbx long long v11; // r15 _BYTE v12[72]; // [rsp+8h] [rbp-78h] BYREF long long v13; // [rsp+50h] [rbp-30h] v13 = a5; v7 = *(_DWORD *)(a1 + 448); v8 = ((long long ( *)(_BYTE *, _QWORD, long long))PSI_server[43])(v12, v7, 6LL); if ( !v8 ) return my_pread(v7, a2, a3, a4, v13); v11 = v8; ((void ( *)(long long, long long, const char *, long long))PSI_server[66])( v8, a3, "/workspace/llm4binary/github2025/eloqsql/storage/myisam/mi_dynrec.c", 202LL); v9 = my_pread(v7, a2, a3, a4, v13); ((void ( *)(long long))PSI_server[67])(v11); return v9; }
mi_nommap_pread: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x58 MOV qword ptr [RBP + -0x30],R8 MOV R12,RCX MOV R14,RDX MOV R13,RSI MOV EBX,dword ptr [RDI + 0x1c0] LEA RAX,[0x486010] MOV RAX,qword ptr [RAX] LEA RDI,[RBP + -0x78] MOV ESI,EBX MOV EDX,0x6 CALL qword ptr [RAX + 0x158] TEST RAX,RAX JNZ 0x00176f4d MOV EDI,EBX MOV RSI,R13 MOV RDX,R14 MOV RCX,R12 MOV R8,qword ptr [RBP + -0x30] CALL 0x001a0660 MOV RBX,RAX LAB_00176f3b: MOV RAX,RBX ADD RSP,0x58 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET LAB_00176f4d: MOV R15,RAX LEA RAX,[0x486010] MOV RAX,qword ptr [RAX] LEA RDX,[0x1dbbb3] MOV RDI,R15 MOV RSI,R14 MOV ECX,0xca CALL qword ptr [RAX + 0x210] MOV EDI,EBX MOV RSI,R13 MOV RDX,R14 MOV RCX,R12 MOV R12,qword ptr [RBP + -0x30] MOV R8,R12 CALL 0x001a0660 MOV RBX,RAX XOR ESI,ESI TEST RAX,RAX CMOVNZ R14,RSI CMP RAX,-0x1 CMOVNZ RSI,RAX TEST R12B,0x6 CMOVNZ RSI,R14 LEA RAX,[0x486010] MOV RAX,qword ptr [RAX] MOV RDI,R15 CALL qword ptr [RAX + 0x218] JMP 0x00176f3b
long mi_nommap_pread(long param_1,int8 param_2,long param_3,int8 param_4,ulong param_5) { int4 uVar1; ulong uVar2; long lVar3; long lVar4; long lVar5; int1 local_80 [72]; ulong local_38; uVar1 = *(int4 *)(param_1 + 0x1c0); local_38 = param_5; lVar3 = (**(code **)(PSI_server + 0x158))(local_80,uVar1,6); if (lVar3 == 0) { lVar4 = my_pread(uVar1,param_2,param_3,param_4,local_38); } else { (**(code **)(PSI_server + 0x210)) (lVar3,param_3,"/workspace/llm4binary/github2025/eloqsql/storage/myisam/mi_dynrec.c", 0xca); uVar2 = local_38; lVar4 = my_pread(uVar1,param_2,param_3,param_4,local_38); if (lVar4 != 0) { param_3 = 0; } lVar5 = 0; if (lVar4 != -1) { lVar5 = lVar4; } if ((uVar2 & 6) != 0) { lVar5 = param_3; } (**(code **)(PSI_server + 0x218))(lVar3,lVar5); } return lVar4; }
20,518
my_strntoul_8bit
eloqsql/strings/ctype-simple.c
ulong my_strntoul_8bit(CHARSET_INFO *cs, const char *nptr, size_t l, int base, char **endptr, int *err) { int negative; register uint32 cutoff; register uint cutlim; register uint32 i; register const char *s; const char *save, *e; int overflow; *err= 0; /* Initialize error indicator */ s = nptr; e = nptr+l; for( ; s<e && my_isspace(cs, *s); s++); if (s==e) { goto noconv; } if (*s == '-') { negative = 1; ++s; } else if (*s == '+') { negative = 0; ++s; } else negative = 0; save = s; cutoff = ((uint32)~0L) / (uint32) base; cutlim = (uint) (((uint32)~0L) % (uint32) base); overflow = 0; i = 0; for ( ; s != e; ++s) { register uchar c= *s; if (c>='0' && c<='9') c -= '0'; else if (c>='A' && c<='Z') c = c - 'A' + 10; else if (c>='a' && c<='z') c = c - 'a' + 10; else break; if (c >= base) break; if (i > cutoff || (i == cutoff && c > cutlim)) overflow = 1; else { i *= (uint32) base; i += c; } } if (s == save) goto noconv; if (endptr != NULL) *endptr = (char *) s; if (overflow) { err[0]= ERANGE; return (~(uint32) 0); } return (negative ? -((long) i) : (long) i); noconv: err[0]= EDOM; if (endptr != NULL) *endptr = (char *) nptr; return 0L; }
O0
c
my_strntoul_8bit: pushq %rbp movq %rsp, %rbp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq %rdx, -0x20(%rbp) movl %ecx, -0x24(%rbp) movq %r8, -0x30(%rbp) movq %r9, -0x38(%rbp) movq -0x38(%rbp), %rax movl $0x0, (%rax) movq -0x18(%rbp), %rax movq %rax, -0x50(%rbp) movq -0x18(%rbp), %rax addq -0x20(%rbp), %rax movq %rax, -0x60(%rbp) movq -0x50(%rbp), %rcx xorl %eax, %eax cmpq -0x60(%rbp), %rcx movb %al, -0x66(%rbp) jae 0x2a548 movq -0x10(%rbp), %rax movq 0x40(%rax), %rax movq -0x50(%rbp), %rcx movzbl (%rcx), %ecx movzbl 0x1(%rax,%rcx), %eax andl $0x8, %eax cmpl $0x0, %eax setne %al movb %al, -0x66(%rbp) movb -0x66(%rbp), %al testb $0x1, %al jne 0x2a551 jmp 0x2a561 jmp 0x2a553 movq -0x50(%rbp), %rax addq $0x1, %rax movq %rax, -0x50(%rbp) jmp 0x2a519 movq -0x50(%rbp), %rax cmpq -0x60(%rbp), %rax jne 0x2a570 jmp 0x2a71c movq -0x50(%rbp), %rax movsbl (%rax), %eax cmpl $0x2d, %eax jne 0x2a591 movl $0x1, -0x3c(%rbp) movq -0x50(%rbp), %rax addq $0x1, %rax movq %rax, -0x50(%rbp) jmp 0x2a5bb movq -0x50(%rbp), %rax movsbl (%rax), %eax cmpl $0x2b, %eax jne 0x2a5b2 movl $0x0, -0x3c(%rbp) movq -0x50(%rbp), %rax addq $0x1, %rax movq %rax, -0x50(%rbp) jmp 0x2a5b9 movl $0x0, -0x3c(%rbp) jmp 0x2a5bb movq -0x50(%rbp), %rax movq %rax, -0x58(%rbp) movl $0xffffffff, %eax # imm = 0xFFFFFFFF xorl %edx, %edx divl -0x24(%rbp) movl %eax, -0x40(%rbp) movl $0xffffffff, %eax # imm = 0xFFFFFFFF xorl %edx, %edx divl -0x24(%rbp) movl %edx, -0x44(%rbp) movl $0x0, -0x64(%rbp) movl $0x0, -0x48(%rbp) movq -0x50(%rbp), %rax cmpq -0x60(%rbp), %rax je 0x2a6bc movq -0x50(%rbp), %rax movb (%rax), %al movb %al, -0x65(%rbp) movzbl -0x65(%rbp), %eax cmpl $0x30, %eax jl 0x2a620 movzbl -0x65(%rbp), %eax cmpl $0x39, %eax jg 0x2a620 movzbl -0x65(%rbp), %eax subl $0x30, %eax movb %al, -0x65(%rbp) jmp 0x2a668 movzbl -0x65(%rbp), %eax cmpl $0x41, %eax jl 0x2a641 movzbl -0x65(%rbp), %eax cmpl $0x5a, %eax jg 0x2a641 movzbl -0x65(%rbp), %eax subl $0x41, %eax addl $0xa, %eax movb %al, -0x65(%rbp) jmp 0x2a666 movzbl -0x65(%rbp), %eax cmpl $0x61, %eax jl 0x2a662 movzbl -0x65(%rbp), %eax cmpl $0x7a, %eax jg 0x2a662 movzbl -0x65(%rbp), %eax subl $0x61, %eax addl $0xa, %eax movb %al, -0x65(%rbp) jmp 0x2a664 jmp 0x2a6bc jmp 0x2a666 jmp 0x2a668 movzbl -0x65(%rbp), %eax cmpl -0x24(%rbp), %eax jl 0x2a673 jmp 0x2a6bc movl -0x48(%rbp), %eax cmpl -0x40(%rbp), %eax ja 0x2a68c movl -0x48(%rbp), %eax cmpl -0x40(%rbp), %eax jne 0x2a695 movzbl -0x65(%rbp), %eax cmpl -0x44(%rbp), %eax jbe 0x2a695 movl $0x1, -0x64(%rbp) jmp 0x2a6a9 movl -0x24(%rbp), %eax imull -0x48(%rbp), %eax movl %eax, -0x48(%rbp) movzbl -0x65(%rbp), %eax addl -0x48(%rbp), %eax movl %eax, -0x48(%rbp) jmp 0x2a6ab movq -0x50(%rbp), %rax addq $0x1, %rax movq %rax, -0x50(%rbp) jmp 0x2a5eb movq -0x50(%rbp), %rax cmpq -0x58(%rbp), %rax jne 0x2a6c8 jmp 0x2a71c cmpq $0x0, -0x30(%rbp) je 0x2a6da movq -0x50(%rbp), %rcx movq -0x30(%rbp), %rax movq %rcx, (%rax) cmpl $0x0, -0x64(%rbp) je 0x2a6f5 movq -0x38(%rbp), %rax movl $0x22, (%rax) movl $0xffffffff, %eax # imm = 0xFFFFFFFF movq %rax, -0x8(%rbp) jmp 0x2a740 cmpl $0x0, -0x3c(%rbp) je 0x2a70b movl -0x48(%rbp), %eax movl %eax, %ecx xorl %eax, %eax subq %rcx, %rax movq %rax, -0x70(%rbp) jmp 0x2a712 movl -0x48(%rbp), %eax movq %rax, -0x70(%rbp) movq -0x70(%rbp), %rax movq %rax, -0x8(%rbp) jmp 0x2a740 movq -0x38(%rbp), %rax movl $0x21, (%rax) cmpq $0x0, -0x30(%rbp) je 0x2a738 movq -0x18(%rbp), %rcx movq -0x30(%rbp), %rax movq %rcx, (%rax) movq $0x0, -0x8(%rbp) movq -0x8(%rbp), %rax popq %rbp retq nopw %cs:(%rax,%rax)
my_strntoul_8bit: push rbp mov rbp, rsp mov [rbp+var_10], rdi mov [rbp+var_18], rsi mov [rbp+var_20], rdx mov [rbp+var_24], ecx mov [rbp+var_30], r8 mov [rbp+var_38], r9 mov rax, [rbp+var_38] mov dword ptr [rax], 0 mov rax, [rbp+var_18] mov [rbp+var_50], rax mov rax, [rbp+var_18] add rax, [rbp+var_20] mov [rbp+var_60], rax loc_2A519: mov rcx, [rbp+var_50] xor eax, eax cmp rcx, [rbp+var_60] mov [rbp+var_66], al jnb short loc_2A548 mov rax, [rbp+var_10] mov rax, [rax+40h] mov rcx, [rbp+var_50] movzx ecx, byte ptr [rcx] movzx eax, byte ptr [rax+rcx+1] and eax, 8 cmp eax, 0 setnz al mov [rbp+var_66], al loc_2A548: mov al, [rbp+var_66] test al, 1 jnz short loc_2A551 jmp short loc_2A561 loc_2A551: jmp short $+2 loc_2A553: mov rax, [rbp+var_50] add rax, 1 mov [rbp+var_50], rax jmp short loc_2A519 loc_2A561: mov rax, [rbp+var_50] cmp rax, [rbp+var_60] jnz short loc_2A570 jmp loc_2A71C loc_2A570: mov rax, [rbp+var_50] movsx eax, byte ptr [rax] cmp eax, 2Dh ; '-' jnz short loc_2A591 mov [rbp+var_3C], 1 mov rax, [rbp+var_50] add rax, 1 mov [rbp+var_50], rax jmp short loc_2A5BB loc_2A591: mov rax, [rbp+var_50] movsx eax, byte ptr [rax] cmp eax, 2Bh ; '+' jnz short loc_2A5B2 mov [rbp+var_3C], 0 mov rax, [rbp+var_50] add rax, 1 mov [rbp+var_50], rax jmp short loc_2A5B9 loc_2A5B2: mov [rbp+var_3C], 0 loc_2A5B9: jmp short $+2 loc_2A5BB: mov rax, [rbp+var_50] mov [rbp+var_58], rax mov eax, 0FFFFFFFFh xor edx, edx div [rbp+var_24] mov [rbp+var_40], eax mov eax, 0FFFFFFFFh xor edx, edx div [rbp+var_24] mov [rbp+var_44], edx mov [rbp+var_64], 0 mov [rbp+var_48], 0 loc_2A5EB: mov rax, [rbp+var_50] cmp rax, [rbp+var_60] jz loc_2A6BC mov rax, [rbp+var_50] mov al, [rax] mov [rbp+var_65], al movzx eax, [rbp+var_65] cmp eax, 30h ; '0' jl short loc_2A620 movzx eax, [rbp+var_65] cmp eax, 39h ; '9' jg short loc_2A620 movzx eax, [rbp+var_65] sub eax, 30h ; '0' mov [rbp+var_65], al jmp short loc_2A668 loc_2A620: movzx eax, [rbp+var_65] cmp eax, 41h ; 'A' jl short loc_2A641 movzx eax, [rbp+var_65] cmp eax, 5Ah ; 'Z' jg short loc_2A641 movzx eax, [rbp+var_65] sub eax, 41h ; 'A' add eax, 0Ah mov [rbp+var_65], al jmp short loc_2A666 loc_2A641: movzx eax, [rbp+var_65] cmp eax, 61h ; 'a' jl short loc_2A662 movzx eax, [rbp+var_65] cmp eax, 7Ah ; 'z' jg short loc_2A662 movzx eax, [rbp+var_65] sub eax, 61h ; 'a' add eax, 0Ah mov [rbp+var_65], al jmp short loc_2A664 loc_2A662: jmp short loc_2A6BC loc_2A664: jmp short $+2 loc_2A666: jmp short $+2 loc_2A668: movzx eax, [rbp+var_65] cmp eax, [rbp+var_24] jl short loc_2A673 jmp short loc_2A6BC loc_2A673: mov eax, [rbp+var_48] cmp eax, [rbp+var_40] ja short loc_2A68C mov eax, [rbp+var_48] cmp eax, [rbp+var_40] jnz short loc_2A695 movzx eax, [rbp+var_65] cmp eax, [rbp+var_44] jbe short loc_2A695 loc_2A68C: mov [rbp+var_64], 1 jmp short loc_2A6A9 loc_2A695: mov eax, [rbp+var_24] imul eax, [rbp+var_48] mov [rbp+var_48], eax movzx eax, [rbp+var_65] add eax, [rbp+var_48] mov [rbp+var_48], eax loc_2A6A9: jmp short $+2 loc_2A6AB: mov rax, [rbp+var_50] add rax, 1 mov [rbp+var_50], rax jmp loc_2A5EB loc_2A6BC: mov rax, [rbp+var_50] cmp rax, [rbp+var_58] jnz short loc_2A6C8 jmp short loc_2A71C loc_2A6C8: cmp [rbp+var_30], 0 jz short loc_2A6DA mov rcx, [rbp+var_50] mov rax, [rbp+var_30] mov [rax], rcx loc_2A6DA: cmp [rbp+var_64], 0 jz short loc_2A6F5 mov rax, [rbp+var_38] mov dword ptr [rax], 22h ; '"' mov eax, 0FFFFFFFFh mov [rbp+var_8], rax jmp short loc_2A740 loc_2A6F5: cmp [rbp+var_3C], 0 jz short loc_2A70B mov eax, [rbp+var_48] mov ecx, eax xor eax, eax sub rax, rcx mov [rbp+var_70], rax jmp short loc_2A712 loc_2A70B: mov eax, [rbp+var_48] mov [rbp+var_70], rax loc_2A712: mov rax, [rbp+var_70] mov [rbp+var_8], rax jmp short loc_2A740 loc_2A71C: mov rax, [rbp+var_38] mov dword ptr [rax], 21h ; '!' cmp [rbp+var_30], 0 jz short loc_2A738 mov rcx, [rbp+var_18] mov rax, [rbp+var_30] mov [rax], rcx loc_2A738: mov [rbp+var_8], 0 loc_2A740: mov rax, [rbp+var_8] pop rbp retn
long long my_strntoul_8bit(long long a1, _BYTE *a2, long long a3, int a4, _QWORD *a5, _DWORD *a6) { bool v8; // [rsp+Ah] [rbp-66h] unsigned __int8 v9; // [rsp+Bh] [rbp-65h] unsigned __int8 v10; // [rsp+Bh] [rbp-65h] int v11; // [rsp+Ch] [rbp-64h] _BYTE *v12; // [rsp+10h] [rbp-60h] _BYTE *v13; // [rsp+18h] [rbp-58h] _BYTE *v14; // [rsp+20h] [rbp-50h] unsigned int v15; // [rsp+28h] [rbp-48h] unsigned long long v16; // [rsp+2Ch] [rbp-44h] int v17; // [rsp+34h] [rbp-3Ch] *a6 = 0; v14 = a2; v12 = &a2[a3]; while ( 1 ) { v8 = 0; if ( v14 < v12 ) v8 = (*(_BYTE *)(*(_QWORD *)(a1 + 64) + (unsigned __int8)*v14 + 1LL) & 8) != 0; if ( !v8 ) break; ++v14; } if ( v14 == v12 ) goto LABEL_37; if ( *v14 == 45 ) { v17 = 1; ++v14; } else { v17 = 0; if ( *v14 == 43 ) ++v14; } v13 = v14; v11 = 0; v15 = 0; while ( v14 != v12 ) { v9 = *v14; if ( (unsigned __int8)*v14 < 0x30u || v9 > 0x39u ) { if ( v9 < 0x41u || v9 > 0x5Au ) { if ( v9 < 0x61u || v9 > 0x7Au ) break; v10 = v9 - 97 + 10; } else { v10 = v9 - 65 + 10; } } else { v10 = v9 - 48; } if ( v10 >= a4 ) break; LODWORD(v16) = 0xFFFFFFFF % a4; HIDWORD(v16) = 0xFFFFFFFF / a4; if ( __PAIR64__(v15, v10) <= v16 ) v15 = v15 * a4 + v10; else v11 = 1; ++v14; } if ( v14 == v13 ) { LABEL_37: *a6 = 33; if ( a5 ) *a5 = a2; return 0LL; } else { if ( a5 ) *a5 = v14; if ( v11 ) { *a6 = 34; return 0xFFFFFFFFLL; } else if ( v17 ) { return -(long long)v15; } else { return v15; } } }
my_strntoul_8bit: PUSH RBP MOV RBP,RSP MOV qword ptr [RBP + -0x10],RDI MOV qword ptr [RBP + -0x18],RSI MOV qword ptr [RBP + -0x20],RDX MOV dword ptr [RBP + -0x24],ECX MOV qword ptr [RBP + -0x30],R8 MOV qword ptr [RBP + -0x38],R9 MOV RAX,qword ptr [RBP + -0x38] MOV dword ptr [RAX],0x0 MOV RAX,qword ptr [RBP + -0x18] MOV qword ptr [RBP + -0x50],RAX MOV RAX,qword ptr [RBP + -0x18] ADD RAX,qword ptr [RBP + -0x20] MOV qword ptr [RBP + -0x60],RAX LAB_0012a519: MOV RCX,qword ptr [RBP + -0x50] XOR EAX,EAX CMP RCX,qword ptr [RBP + -0x60] MOV byte ptr [RBP + -0x66],AL JNC 0x0012a548 MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x40] MOV RCX,qword ptr [RBP + -0x50] MOVZX ECX,byte ptr [RCX] MOVZX EAX,byte ptr [RAX + RCX*0x1 + 0x1] AND EAX,0x8 CMP EAX,0x0 SETNZ AL MOV byte ptr [RBP + -0x66],AL LAB_0012a548: MOV AL,byte ptr [RBP + -0x66] TEST AL,0x1 JNZ 0x0012a551 JMP 0x0012a561 LAB_0012a551: JMP 0x0012a553 LAB_0012a553: MOV RAX,qword ptr [RBP + -0x50] ADD RAX,0x1 MOV qword ptr [RBP + -0x50],RAX JMP 0x0012a519 LAB_0012a561: MOV RAX,qword ptr [RBP + -0x50] CMP RAX,qword ptr [RBP + -0x60] JNZ 0x0012a570 JMP 0x0012a71c LAB_0012a570: MOV RAX,qword ptr [RBP + -0x50] MOVSX EAX,byte ptr [RAX] CMP EAX,0x2d JNZ 0x0012a591 MOV dword ptr [RBP + -0x3c],0x1 MOV RAX,qword ptr [RBP + -0x50] ADD RAX,0x1 MOV qword ptr [RBP + -0x50],RAX JMP 0x0012a5bb LAB_0012a591: MOV RAX,qword ptr [RBP + -0x50] MOVSX EAX,byte ptr [RAX] CMP EAX,0x2b JNZ 0x0012a5b2 MOV dword ptr [RBP + -0x3c],0x0 MOV RAX,qword ptr [RBP + -0x50] ADD RAX,0x1 MOV qword ptr [RBP + -0x50],RAX JMP 0x0012a5b9 LAB_0012a5b2: MOV dword ptr [RBP + -0x3c],0x0 LAB_0012a5b9: JMP 0x0012a5bb LAB_0012a5bb: MOV RAX,qword ptr [RBP + -0x50] MOV qword ptr [RBP + -0x58],RAX MOV EAX,0xffffffff XOR EDX,EDX DIV dword ptr [RBP + -0x24] MOV dword ptr [RBP + -0x40],EAX MOV EAX,0xffffffff XOR EDX,EDX DIV dword ptr [RBP + -0x24] MOV dword ptr [RBP + -0x44],EDX MOV dword ptr [RBP + -0x64],0x0 MOV dword ptr [RBP + -0x48],0x0 LAB_0012a5eb: MOV RAX,qword ptr [RBP + -0x50] CMP RAX,qword ptr [RBP + -0x60] JZ 0x0012a6bc MOV RAX,qword ptr [RBP + -0x50] MOV AL,byte ptr [RAX] MOV byte ptr [RBP + -0x65],AL MOVZX EAX,byte ptr [RBP + -0x65] CMP EAX,0x30 JL 0x0012a620 MOVZX EAX,byte ptr [RBP + -0x65] CMP EAX,0x39 JG 0x0012a620 MOVZX EAX,byte ptr [RBP + -0x65] SUB EAX,0x30 MOV byte ptr [RBP + -0x65],AL JMP 0x0012a668 LAB_0012a620: MOVZX EAX,byte ptr [RBP + -0x65] CMP EAX,0x41 JL 0x0012a641 MOVZX EAX,byte ptr [RBP + -0x65] CMP EAX,0x5a JG 0x0012a641 MOVZX EAX,byte ptr [RBP + -0x65] SUB EAX,0x41 ADD EAX,0xa MOV byte ptr [RBP + -0x65],AL JMP 0x0012a666 LAB_0012a641: MOVZX EAX,byte ptr [RBP + -0x65] CMP EAX,0x61 JL 0x0012a662 MOVZX EAX,byte ptr [RBP + -0x65] CMP EAX,0x7a JG 0x0012a662 MOVZX EAX,byte ptr [RBP + -0x65] SUB EAX,0x61 ADD EAX,0xa MOV byte ptr [RBP + -0x65],AL JMP 0x0012a664 LAB_0012a662: JMP 0x0012a6bc LAB_0012a664: JMP 0x0012a666 LAB_0012a666: JMP 0x0012a668 LAB_0012a668: MOVZX EAX,byte ptr [RBP + -0x65] CMP EAX,dword ptr [RBP + -0x24] JL 0x0012a673 JMP 0x0012a6bc LAB_0012a673: MOV EAX,dword ptr [RBP + -0x48] CMP EAX,dword ptr [RBP + -0x40] JA 0x0012a68c MOV EAX,dword ptr [RBP + -0x48] CMP EAX,dword ptr [RBP + -0x40] JNZ 0x0012a695 MOVZX EAX,byte ptr [RBP + -0x65] CMP EAX,dword ptr [RBP + -0x44] JBE 0x0012a695 LAB_0012a68c: MOV dword ptr [RBP + -0x64],0x1 JMP 0x0012a6a9 LAB_0012a695: MOV EAX,dword ptr [RBP + -0x24] IMUL EAX,dword ptr [RBP + -0x48] MOV dword ptr [RBP + -0x48],EAX MOVZX EAX,byte ptr [RBP + -0x65] ADD EAX,dword ptr [RBP + -0x48] MOV dword ptr [RBP + -0x48],EAX LAB_0012a6a9: JMP 0x0012a6ab LAB_0012a6ab: MOV RAX,qword ptr [RBP + -0x50] ADD RAX,0x1 MOV qword ptr [RBP + -0x50],RAX JMP 0x0012a5eb LAB_0012a6bc: MOV RAX,qword ptr [RBP + -0x50] CMP RAX,qword ptr [RBP + -0x58] JNZ 0x0012a6c8 JMP 0x0012a71c LAB_0012a6c8: CMP qword ptr [RBP + -0x30],0x0 JZ 0x0012a6da MOV RCX,qword ptr [RBP + -0x50] MOV RAX,qword ptr [RBP + -0x30] MOV qword ptr [RAX],RCX LAB_0012a6da: CMP dword ptr [RBP + -0x64],0x0 JZ 0x0012a6f5 MOV RAX,qword ptr [RBP + -0x38] MOV dword ptr [RAX],0x22 MOV EAX,0xffffffff MOV qword ptr [RBP + -0x8],RAX JMP 0x0012a740 LAB_0012a6f5: CMP dword ptr [RBP + -0x3c],0x0 JZ 0x0012a70b MOV EAX,dword ptr [RBP + -0x48] MOV ECX,EAX XOR EAX,EAX SUB RAX,RCX MOV qword ptr [RBP + -0x70],RAX JMP 0x0012a712 LAB_0012a70b: MOV EAX,dword ptr [RBP + -0x48] MOV qword ptr [RBP + -0x70],RAX LAB_0012a712: MOV RAX,qword ptr [RBP + -0x70] MOV qword ptr [RBP + -0x8],RAX JMP 0x0012a740 LAB_0012a71c: MOV RAX,qword ptr [RBP + -0x38] MOV dword ptr [RAX],0x21 CMP qword ptr [RBP + -0x30],0x0 JZ 0x0012a738 MOV RCX,qword ptr [RBP + -0x18] MOV RAX,qword ptr [RBP + -0x30] MOV qword ptr [RAX],RCX LAB_0012a738: MOV qword ptr [RBP + -0x8],0x0 LAB_0012a740: MOV RAX,qword ptr [RBP + -0x8] POP RBP RET
ulong my_strntoul_8bit(long param_1,byte *param_2,long param_3,uint param_4,int8 *param_5, int4 *param_6) { bool bVar1; byte *pbVar2; uint uVar3; byte *pbVar4; bool bVar5; ulong local_78; byte local_6d; byte *local_58; uint local_50; *param_6 = 0; pbVar4 = param_2 + param_3; local_58 = param_2; while( true ) { bVar5 = false; if (local_58 < pbVar4) { bVar5 = (*(byte *)(*(long *)(param_1 + 0x40) + 1 + (ulong)*local_58) & 8) != 0; } if (!bVar5) break; local_58 = local_58 + 1; } if (local_58 != pbVar4) { if (*local_58 == 0x2d) { bVar5 = true; local_58 = local_58 + 1; } else { if (*local_58 == 0x2b) { local_58 = local_58 + 1; } bVar5 = false; } pbVar2 = local_58; uVar3 = (uint)(0xffffffff / (ulong)param_4); bVar1 = false; local_50 = 0; for (; local_58 != pbVar4; local_58 = local_58 + 1) { local_6d = *local_58; if ((local_6d < 0x30) || (0x39 < local_6d)) { if ((local_6d < 0x41) || (0x5a < local_6d)) { if ((local_6d < 0x61) || (0x7a < local_6d)) break; local_6d = local_6d + 0xa9; } else { local_6d = local_6d - 0x37; } } else { local_6d = local_6d - 0x30; } if ((int)param_4 <= (int)(uint)local_6d) break; if ((uVar3 < local_50) || ((local_50 == uVar3 && ((uint)(0xffffffff % (ulong)param_4) < (uint)local_6d)))) { bVar1 = true; } else { local_50 = (uint)local_6d + param_4 * local_50; } } if (local_58 != pbVar2) { if (param_5 != (int8 *)0x0) { *param_5 = local_58; } if (bVar1) { *param_6 = 0x22; return 0xffffffff; } if (bVar5) { local_78 = -(ulong)local_50; } else { local_78 = (ulong)local_50; } return local_78; } } *param_6 = 0x21; if (param_5 != (int8 *)0x0) { *param_5 = param_2; } return 0; }
20,519
nlohmann::json_abi_v3_11_3::detail::dtoa_impl::format_buffer(char*, int, int, int, int)
monkey531[P]llama/common/json.hpp
inline char* format_buffer(char* buf, int len, int decimal_exponent, int min_exp, int max_exp) { JSON_ASSERT(min_exp < 0); JSON_ASSERT(max_exp > 0); const int k = len; const int n = len + decimal_exponent; // v = buf * 10^(n-k) // k is the length of the buffer (number of decimal digits) // n is the position of the decimal point relative to the start of the buffer. if (k <= n && n <= max_exp) { // digits[000] // len <= max_exp + 2 std::memset(buf + k, '0', static_cast<size_t>(n) - static_cast<size_t>(k)); // Make it look like a floating-point number (#362, #378) buf[n + 0] = '.'; buf[n + 1] = '0'; return buf + (static_cast<size_t>(n) + 2); } if (0 < n && n <= max_exp) { // dig.its // len <= max_digits10 + 1 JSON_ASSERT(k > n); std::memmove(buf + (static_cast<size_t>(n) + 1), buf + n, static_cast<size_t>(k) - static_cast<size_t>(n)); buf[n] = '.'; return buf + (static_cast<size_t>(k) + 1U); } if (min_exp < n && n <= 0) { // 0.[000]digits // len <= 2 + (-min_exp - 1) + max_digits10 std::memmove(buf + (2 + static_cast<size_t>(-n)), buf, static_cast<size_t>(k)); buf[0] = '0'; buf[1] = '.'; std::memset(buf + 2, '0', static_cast<size_t>(-n)); return buf + (2U + static_cast<size_t>(-n) + static_cast<size_t>(k)); } if (k == 1) { // dE+123 // len <= 1 + 5 buf += 1; } else { // d.igitsE+123 // len <= max_digits10 + 1 + 5 std::memmove(buf + 2, buf + 1, static_cast<size_t>(k) - 1); buf[1] = '.'; buf += 1 + static_cast<size_t>(k); } *buf++ = 'e'; return append_exponent(buf, n - 1); }
O2
cpp
nlohmann::json_abi_v3_11_3::detail::dtoa_impl::format_buffer(char*, int, int, int, int): pushq %r15 pushq %r14 pushq %r12 pushq %rbx pushq %rax testl %ecx, %ecx jns 0x937b6 testl %r8d, %r8d jle 0x937d2 movq %rdi, %rbx leal (%rdx,%rsi), %r14d testl %edx, %edx sets %al cmpl %r8d, %r14d setg %dil orb %al, %dil je 0x93705 cmpl %r8d, %r14d setg %al testl %r14d, %r14d setle %dil orb %al, %dil je 0x9372e testl %r14d, %r14d setg %al cmpl %ecx, %r14d setle %cl orb %al, %cl jne 0x93772 negl %r14d leaq (%rbx,%r14), %r15 addq $0x2, %r15 movslq %esi, %r12 movq %r15, %rdi movq %rbx, %rsi movq %r12, %rdx callq 0x24ea0 movw $0x2e30, (%rbx) # imm = 0x2E30 addq $0x2, %rbx pushq $0x30 popq %rsi movq %rbx, %rdi movq %r14, %rdx callq 0x24520 addq %r12, %r15 jmp 0x93763 movslq %esi, %rax leaq (%rbx,%rax), %rdi movslq %r14d, %r14 movq %r14, %rdx subq %rax, %rdx pushq $0x30 popq %rsi callq 0x24520 leaq (%rbx,%r14), %r15 addq $0x2, %r15 movw $0x302e, -0x2(%r15) # imm = 0x302E jmp 0x93763 testl %edx, %edx jns 0x937f3 movl %r14d, %ecx leaq (%rbx,%rcx), %rax leaq (%rbx,%rcx), %r14 incq %r14 movl %esi, %r15d movq %r15, %rdx subq %rcx, %rdx movq %r14, %rdi movq %rax, %rsi callq 0x24ea0 movb $0x2e, -0x1(%r14) addq %rbx, %r15 incq %r15 movq %r15, %rax addq $0x8, %rsp popq %rbx popq %r12 popq %r14 popq %r15 retq cmpl $0x1, %esi je 0x93795 leaq 0x2(%rbx), %rdi leaq 0x1(%rbx), %rax movslq %esi, %r15 leaq -0x1(%r15), %rdx movq %rax, %rsi callq 0x24ea0 movb $0x2e, 0x1(%rbx) addq %r15, %rbx movb $0x65, 0x1(%rbx) addq $0x2, %rbx decl %r14d movq %rbx, %rdi movl %r14d, %esi addq $0x8, %rsp popq %rbx popq %r12 popq %r14 popq %r15 jmp 0x9410b leaq 0x2879a(%rip), %rdi # 0xbbf57 leaq 0x2232c(%rip), %rdx # 0xb5af0 leaq 0x2e0b0(%rip), %rcx # 0xc187b movl $0x45e3, %esi # imm = 0x45E3 jmp 0x937ec leaq 0x2877e(%rip), %rdi # 0xbbf57 leaq 0x22310(%rip), %rdx # 0xb5af0 leaq 0x2e0a0(%rip), %rcx # 0xc1887 movl $0x45e4, %esi # imm = 0x45E4 xorl %eax, %eax callq 0x24f20 leaq 0x2875d(%rip), %rdi # 0xbbf57 leaq 0x222ef(%rip), %rdx # 0xb5af0 leaq 0x2e08b(%rip), %rcx # 0xc1893 movl $0x45fe, %esi # imm = 0x45FE jmp 0x937ec
_ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl13format_bufferEPciiii: push r15 push r14 push r12 push rbx push rax test ecx, ecx jns loc_937B6 test r8d, r8d jle loc_937D2 mov rbx, rdi lea r14d, [rdx+rsi] test edx, edx sets al cmp r14d, r8d setnle dil or dil, al jz short loc_93705 cmp r14d, r8d setnle al test r14d, r14d setle dil or dil, al jz short loc_9372E test r14d, r14d setnle al cmp r14d, ecx setle cl or cl, al jnz loc_93772 neg r14d lea r15, [rbx+r14] add r15, 2 movsxd r12, esi mov rdi, r15 mov rsi, rbx mov rdx, r12 call _memmove mov word ptr [rbx], 2E30h add rbx, 2 push 30h ; '0' pop rsi mov rdi, rbx mov rdx, r14 call _memset add r15, r12 jmp short loc_93763 loc_93705: movsxd rax, esi lea rdi, [rbx+rax] movsxd r14, r14d mov rdx, r14 sub rdx, rax push 30h ; '0' pop rsi call _memset lea r15, [rbx+r14] add r15, 2 mov word ptr [r15-2], 302Eh jmp short loc_93763 loc_9372E: test edx, edx jns loc_937F3 mov ecx, r14d lea rax, [rbx+rcx] lea r14, [rbx+rcx] inc r14 mov r15d, esi mov rdx, r15 sub rdx, rcx mov rdi, r14 mov rsi, rax call _memmove mov byte ptr [r14-1], 2Eh ; '.' add r15, rbx inc r15 loc_93763: mov rax, r15 add rsp, 8 pop rbx pop r12 pop r14 pop r15 retn loc_93772: cmp esi, 1 jz short loc_93795 lea rdi, [rbx+2] lea rax, [rbx+1] movsxd r15, esi lea rdx, [r15-1] mov rsi, rax call _memmove mov byte ptr [rbx+1], 2Eh ; '.' add rbx, r15 loc_93795: mov byte ptr [rbx+1], 65h ; 'e' add rbx, 2 dec r14d mov rdi, rbx; this mov esi, r14d; char * add rsp, 8 pop rbx pop r12 pop r14 pop r15 jmp _ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl15append_exponentEPci; nlohmann::json_abi_v3_11_3::detail::dtoa_impl::append_exponent(char *,int) loc_937B6: lea rdi, aWorkspaceLlm4b_1; "/workspace/llm4binary/github/2025_star3"... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aMinExp0; "min_exp < 0" mov esi, 45E3h jmp short loc_937EC loc_937D2: lea rdi, aWorkspaceLlm4b_1; "/workspace/llm4binary/github/2025_star3"... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aMaxExp0; "max_exp > 0" mov esi, 45E4h loc_937EC: xor eax, eax call _ggml_abort loc_937F3: lea rdi, aWorkspaceLlm4b_1; "/workspace/llm4binary/github/2025_star3"... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aKN; "k > n" mov esi, 45FEh jmp short loc_937EC
char * nlohmann::json_abi_v3_11_3::detail::dtoa_impl::format_buffer( nlohmann::json_abi_v3_11_3::detail::dtoa_impl *this, char *a2, int a3, int a4, int a5) { nlohmann::json_abi_v3_11_3::detail::dtoa_impl *v5; // rbx int v6; // r14d long long v7; // r14 char *v8; // r15 long long v9; // rcx char *v10; // r14 if ( a4 >= 0 ) { ggml_abort( "/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp", 17891LL, "GGML_ASSERT(%s) failed", "min_exp < 0"); goto LABEL_16; } if ( a5 <= 0 ) { ggml_abort( "/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp", 17892LL, "GGML_ASSERT(%s) failed", "max_exp > 0"); goto LABEL_16; } v5 = this; v6 = a3 + (_DWORD)a2; if ( a3 >= 0 && a3 + (int)a2 <= a5 ) { memset((char *)this + (int)a2, 48LL, v6 - (long long)(int)a2); v8 = (char *)this + v6 + 2; *(_WORD *)((char *)this + v6) = 12334; return v8; } if ( v6 <= a5 && v6 > 0 ) { if ( a3 < 0 ) { v9 = (unsigned int)v6; v10 = (char *)this + (unsigned int)v6 + 1; memmove(v10, (char *)this + v9, (unsigned int)a2 - v9); *(v10 - 1) = 46; return (char *)this + (unsigned int)a2 + 1; } while ( 1 ) LABEL_16: ggml_abort( "/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp", 17918LL, "GGML_ASSERT(%s) failed", "k > n"); } if ( v6 <= 0 && v6 > a4 ) { v7 = (unsigned int)-v6; memmove((char *)this + v7 + 2, this, (int)a2); *(_WORD *)this = 11824; memset((char *)this + 2, 48LL, v7); return (char *)this + v7 + (int)a2 + 2; } if ( (_DWORD)a2 != 1 ) { memmove((char *)this + 2, (char *)this + 1, (int)a2 - 1LL); *((_BYTE *)this + 1) = 46; v5 = (nlohmann::json_abi_v3_11_3::detail::dtoa_impl *)((char *)this + (int)a2); } *((_BYTE *)v5 + 1) = 101; return (char *)nlohmann::json_abi_v3_11_3::detail::dtoa_impl::append_exponent( (nlohmann::json_abi_v3_11_3::detail::dtoa_impl *)((char *)v5 + 2), (char *)(unsigned int)(v6 - 1), a3); }
format_buffer: PUSH R15 PUSH R14 PUSH R12 PUSH RBX PUSH RAX TEST ECX,ECX JNS 0x001937b6 TEST R8D,R8D JLE 0x001937d2 MOV RBX,RDI LEA R14D,[RDX + RSI*0x1] TEST EDX,EDX SETS AL CMP R14D,R8D SETG DIL OR DIL,AL JZ 0x00193705 CMP R14D,R8D SETG AL TEST R14D,R14D SETLE DIL OR DIL,AL JZ 0x0019372e TEST R14D,R14D SETG AL CMP R14D,ECX SETLE CL OR CL,AL JNZ 0x00193772 NEG R14D LEA R15,[RBX + R14*0x1] ADD R15,0x2 MOVSXD R12,ESI MOV RDI,R15 MOV RSI,RBX MOV RDX,R12 CALL 0x00124ea0 MOV word ptr [RBX],0x2e30 ADD RBX,0x2 PUSH 0x30 POP RSI MOV RDI,RBX MOV RDX,R14 CALL 0x00124520 ADD R15,R12 JMP 0x00193763 LAB_00193705: MOVSXD RAX,ESI LEA RDI,[RBX + RAX*0x1] MOVSXD R14,R14D MOV RDX,R14 SUB RDX,RAX PUSH 0x30 POP RSI CALL 0x00124520 LEA R15,[RBX + R14*0x1] ADD R15,0x2 MOV word ptr [R15 + -0x2],0x302e JMP 0x00193763 LAB_0019372e: TEST EDX,EDX JNS 0x001937f3 MOV ECX,R14D LEA RAX,[RBX + RCX*0x1] LEA R14,[RBX + RCX*0x1] INC R14 MOV R15D,ESI MOV RDX,R15 SUB RDX,RCX MOV RDI,R14 MOV RSI,RAX CALL 0x00124ea0 MOV byte ptr [R14 + -0x1],0x2e ADD R15,RBX INC R15 LAB_00193763: MOV RAX,R15 ADD RSP,0x8 POP RBX POP R12 POP R14 POP R15 RET LAB_00193772: CMP ESI,0x1 JZ 0x00193795 LEA RDI,[RBX + 0x2] LEA RAX,[RBX + 0x1] MOVSXD R15,ESI LEA RDX,[R15 + -0x1] MOV RSI,RAX CALL 0x00124ea0 MOV byte ptr [RBX + 0x1],0x2e ADD RBX,R15 LAB_00193795: MOV byte ptr [RBX + 0x1],0x65 ADD RBX,0x2 DEC R14D MOV RDI,RBX MOV ESI,R14D ADD RSP,0x8 POP RBX POP R12 POP R14 POP R15 JMP 0x0019410b LAB_001937b6: LEA RDI,[0x1bbf57] LEA RDX,[0x1b5af0] LEA RCX,[0x1c187b] MOV ESI,0x45e3 JMP 0x001937ec LAB_001937d2: LEA RDI,[0x1bbf57] LEA RDX,[0x1b5af0] LEA RCX,[0x1c1887] MOV ESI,0x45e4 LAB_001937ec: XOR EAX,EAX CALL 0x00124f20 LAB_001937f3: LEA RDI,[0x1bbf57] LEA RDX,[0x1b5af0] LEA RCX,[0x1c1893] MOV ESI,0x45fe JMP 0x001937ec
/* nlohmann::json_abi_v3_11_3::detail::dtoa_impl::format_buffer(char*, int, int, int, int) */ char * nlohmann::json_abi_v3_11_3::detail::dtoa_impl::format_buffer (char *param_1,int param_2,int param_3,int param_4,int param_5) { char *pcVar1; ulong uVar2; int8 uVar3; uint uVar4; char *pcVar5; if (param_4 < 0) { if (0 < param_5) { uVar4 = param_3 + param_2; if (param_5 < (int)uVar4 || param_3 < 0) { if ((int)uVar4 < 1 || param_5 < (int)uVar4) { if ((int)uVar4 <= param_4 || 0 < (int)uVar4) { if (param_2 != 1) { memmove(param_1 + 2,param_1 + 1,(long)param_2 - 1); param_1[1] = '.'; param_1 = param_1 + param_2; } param_1[1] = 'e'; pcVar1 = (char *)append_exponent(param_1 + 2,uVar4 - 1); return pcVar1; } memmove(param_1 + (ulong)-uVar4 + 2,param_1,(long)param_2); param_1[0] = '0'; param_1[1] = '.'; memset(param_1 + 2,0x30,(ulong)-uVar4); pcVar5 = param_1 + (ulong)-uVar4 + 2 + param_2; } else { if (-1 < param_3) { pcVar1 = "k > n"; uVar3 = 0x45fe; goto LAB_001937ec; } uVar2 = (ulong)uVar4; memmove(param_1 + uVar2 + 1,param_1 + uVar2,(uint)param_2 - uVar2); param_1[uVar2] = '.'; pcVar5 = param_1 + (ulong)(uint)param_2 + 1; } } else { memset(param_1 + param_2,0x30,(long)(int)uVar4 - (long)param_2); pcVar1 = param_1 + (int)uVar4; pcVar5 = pcVar1 + 2; pcVar1[0] = '.'; pcVar1[1] = '0'; } return pcVar5; } pcVar1 = "max_exp > 0"; uVar3 = 0x45e4; } else { pcVar1 = "min_exp < 0"; uVar3 = 0x45e3; } LAB_001937ec: /* WARNING: Subroutine does not return */ ggml_abort("/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",uVar3, "GGML_ASSERT(%s) failed",pcVar1); }
20,520
sqrt_fp2
corpus-core[P]colibri-stateless/build_O3/_deps/blst-src/src/sqrt.c
static bool_t sqrt_fp2(vec384x out, const vec384x inp) { vec384x ret; vec384 aa, bb; sqr_fp(aa, inp[0]); sqr_fp(bb, inp[1]); add_fp(aa, aa, bb); /* don't pay attention to return value, final "align" will tell... */ (void)sqrt_fp(aa, aa); /* sqrt(a²+b²) */ sub_fp(bb, inp[0], aa); add_fp(aa, inp[0], aa); vec_select(aa, bb, aa, sizeof(aa), vec_is_zero(aa, sizeof(aa))); div_by_2_fp(aa, aa); /* (a ± sqrt(a²+b²))/2 */ /* if it says "no sqrt," final "align" will find right one... */ (void)recip_sqrt_fp(ret[0], aa); /* 1/sqrt((a ± sqrt(a²+b²))/2) */ div_by_2_fp(ret[1], inp[1]); mul_fp(ret[1], ret[1], ret[0]); /* b/(2*sqrt((a ± sqrt(a²+b²))/2)) */ mul_fp(ret[0], ret[0], aa); /* sqrt((a ± sqrt(a²+b²))/2) */ /* * Now see if |ret| is or can be made sqrt(|inp|)... */ return sqrt_align_fp2(out, ret, ret, inp); }
O3
c
sqrt_fp2: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0xd8, %rsp movq %rsi, %rbx movq %rdi, -0x38(%rbp) leaq 0x1e104(%rip), %r15 # 0x3fb10 leaq -0xa0(%rbp), %r13 movabsq $-0x760c000300030003, %r14 # imm = 0x89F3FFFCFFFCFFFD movq %r13, %rdi movq %r15, %rdx movq %r14, %rcx callq 0x33d20 leaq 0x30(%rbx), %rsi movq %rsi, -0x30(%rbp) leaq -0x70(%rbp), %r12 movq %r12, %rdi movq %r15, %rdx movq %r14, %rcx callq 0x33d20 movq %r13, %rdi movq %r13, %rsi movq %r12, %rdx movq %r15, %rcx callq 0x2ec40 movq %r13, %rdi movq %r13, %rsi callq 0x2192a movq %r12, %rdi movq %rbx, %rsi movq %r13, %rdx movq %r15, %rcx callq 0x2f3a0 movq %r13, %rdi movq %rbx, %rsi movq %r13, %rdx movq %r15, %rcx callq 0x2ec40 movl $0x30, %esi movq %r13, %rdi callq 0x2ff40 movq %r13, %rdi movq %r12, %rsi movq %r13, %rdx movq %rax, %rcx callq 0x2f8a0 movq %r13, %rdi movq %r13, %rsi movq %r15, %rdx callq 0x2eec0 leaq -0x100(%rbp), %r12 movq %r12, %rdi movq %r13, %rsi callq 0x2651a leaq -0xd0(%rbp), %r14 movq %r14, %rdi movq -0x30(%rbp), %rsi movq %r15, %rdx callq 0x2eec0 movq %r14, %rdi movq %r14, %rsi movq %r12, %rdx movq %r15, %rcx movabsq $-0x760c000300030003, %r14 # imm = 0x89F3FFFCFFFCFFFD movq %r14, %r8 callq 0x344a0 movq %r12, %rdi movq %r12, %rsi movq %r13, %rdx movq %r15, %rcx movq %r14, %r8 callq 0x344a0 movq -0x38(%rbp), %rdi movq %r12, %rsi movq %r12, %rdx movq %rbx, %rcx callq 0x26f2e addq $0xd8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
sqrt_fp2: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx sub rsp, 0D8h mov rbx, rsi mov [rbp+var_38], rdi lea r15, BLS12_381_P lea r13, [rbp+var_A0] mov r14, 89F3FFFCFFFCFFFDh mov rdi, r13 mov rdx, r15 mov rcx, r14 call sqr_mont_384 lea rsi, [rbx+30h] mov [rbp+var_30], rsi lea r12, [rbp+var_70] mov rdi, r12 mov rdx, r15 mov rcx, r14 call sqr_mont_384 mov rdi, r13 mov rsi, r13 mov rdx, r12 mov rcx, r15 call add_mod_384 mov rdi, r13 mov rsi, r13 call sqrt_fp mov rdi, r12 mov rsi, rbx mov rdx, r13 mov rcx, r15 call _sub_mod_384 mov rdi, r13 mov rsi, rbx mov rdx, r13 mov rcx, r15 call add_mod_384 mov esi, 30h ; '0' mov rdi, r13 call vec_is_zero_16x mov rdi, r13 mov rsi, r12 mov rdx, r13 mov rcx, rax call vec_select_48 mov rdi, r13 mov rsi, r13 mov rdx, r15 call div_by_2_mod_384 lea r12, [rbp+var_100] mov rdi, r12 mov rsi, r13 call recip_sqrt_fp lea r14, [rbp+var_D0] mov rdi, r14 mov rsi, [rbp+var_30] mov rdx, r15 call div_by_2_mod_384 mov rdi, r14 mov rsi, r14 mov rdx, r12 mov rcx, r15 mov r14, 89F3FFFCFFFCFFFDh mov r8, r14 call mul_mont_384 mov rdi, r12 mov rsi, r12 mov rdx, r13 mov rcx, r15 mov r8, r14 call mul_mont_384 mov rdi, [rbp+var_38] mov rsi, r12 mov rdx, r12 mov rcx, rbx call sqrt_align_fp2 add rsp, 0D8h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
long long sqrt_fp2(long long a1, long long a2) { long long is_zero_16x; // rax _BYTE v4[48]; // [rsp+0h] [rbp-100h] BYREF _BYTE v5[48]; // [rsp+30h] [rbp-D0h] BYREF _OWORD v6[3]; // [rsp+60h] [rbp-A0h] BYREF _BYTE v7[56]; // [rsp+90h] [rbp-70h] BYREF long long v8; // [rsp+C8h] [rbp-38h] long long v9; // [rsp+D0h] [rbp-30h] v8 = a1; sqr_mont_384(v6, a2, &BLS12_381_P, 0x89F3FFFCFFFCFFFDLL); v9 = a2 + 48; sqr_mont_384(v7, a2 + 48, &BLS12_381_P, 0x89F3FFFCFFFCFFFDLL); add_mod_384(v6, v6, v7, &BLS12_381_P); sqrt_fp(v6, (long long)v6); sub_mod_384(v7, a2, v6, &BLS12_381_P); add_mod_384(v6, a2, v6, &BLS12_381_P); is_zero_16x = vec_is_zero_16x(v6, 48LL); vec_select_48(v6, v7, v6, is_zero_16x); div_by_2_mod_384(v6, v6, &BLS12_381_P); recip_sqrt_fp(v4, v6); div_by_2_mod_384(v5, v9, &BLS12_381_P); mul_mont_384(v5, v5, v4, &BLS12_381_P, 0x89F3FFFCFFFCFFFDLL); mul_mont_384(v4, v4, v6, &BLS12_381_P, 0x89F3FFFCFFFCFFFDLL); return sqrt_align_fp2(v8, v4, v4, a2); }
sqrt_fp2: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0xd8 MOV RBX,RSI MOV qword ptr [RBP + -0x38],RDI LEA R15,[0x13fb10] LEA R13,[RBP + -0xa0] MOV R14,-0x760c000300030003 MOV RDI,R13 MOV RDX,R15 MOV RCX,R14 CALL 0x00133d20 LEA RSI,[RBX + 0x30] MOV qword ptr [RBP + -0x30],RSI LEA R12,[RBP + -0x70] MOV RDI,R12 MOV RDX,R15 MOV RCX,R14 CALL 0x00133d20 MOV RDI,R13 MOV RSI,R13 MOV RDX,R12 MOV RCX,R15 CALL 0x0012ec40 MOV RDI,R13 MOV RSI,R13 CALL 0x0012192a MOV RDI,R12 MOV RSI,RBX MOV RDX,R13 MOV RCX,R15 CALL 0x0012f3a0 MOV RDI,R13 MOV RSI,RBX MOV RDX,R13 MOV RCX,R15 CALL 0x0012ec40 MOV ESI,0x30 MOV RDI,R13 CALL 0x0012ff40 MOV RDI,R13 MOV RSI,R12 MOV RDX,R13 MOV RCX,RAX CALL 0x0012f8a0 MOV RDI,R13 MOV RSI,R13 MOV RDX,R15 CALL 0x0012eec0 LEA R12,[RBP + -0x100] MOV RDI,R12 MOV RSI,R13 CALL 0x0012651a LEA R14,[RBP + -0xd0] MOV RDI,R14 MOV RSI,qword ptr [RBP + -0x30] MOV RDX,R15 CALL 0x0012eec0 MOV RDI,R14 MOV RSI,R14 MOV RDX,R12 MOV RCX,R15 MOV R14,-0x760c000300030003 MOV R8,R14 CALL 0x001344a0 MOV RDI,R12 MOV RSI,R12 MOV RDX,R13 MOV RCX,R15 MOV R8,R14 CALL 0x001344a0 MOV RDI,qword ptr [RBP + -0x38] MOV RSI,R12 MOV RDX,R12 MOV RCX,RBX CALL 0x00126f2e ADD RSP,0xd8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
void sqrt_fp2(int8 param_1,long param_2) { int8 uVar1; int1 local_108 [48]; int1 local_d8 [48]; int1 local_a8 [48]; int1 local_78 [56]; int8 local_40; long local_38; local_40 = param_1; sqr_mont_384(local_a8,param_2,BLS12_381_P,0x89f3fffcfffcfffd); local_38 = param_2 + 0x30; sqr_mont_384(local_78,local_38,BLS12_381_P,0x89f3fffcfffcfffd); add_mod_384(local_a8,local_a8,local_78,BLS12_381_P); sqrt_fp(local_a8,local_a8); sub_mod_384(local_78,param_2,local_a8,BLS12_381_P); add_mod_384(local_a8,param_2,local_a8,BLS12_381_P); uVar1 = vec_is_zero_16x(local_a8,0x30); vec_select_48(local_a8,local_78,local_a8,uVar1); div_by_2_mod_384(local_a8,local_a8,BLS12_381_P); recip_sqrt_fp(local_108,local_a8); div_by_2_mod_384(local_d8,local_38,BLS12_381_P); mul_mont_384(local_d8,local_d8,local_108,BLS12_381_P,0x89f3fffcfffcfffd); mul_mont_384(local_108,local_108,local_a8,BLS12_381_P,0x89f3fffcfffcfffd); sqrt_align_fp2(local_40,local_108,local_108,param_2); return; }
20,521
js_create_resolving_functions
bluesky950520[P]quickjs/quickjs.c
static int js_create_resolving_functions(JSContext *ctx, JSValue *resolving_funcs, JSValue promise) { JSValue obj; JSPromiseFunctionData *s; JSPromiseFunctionDataResolved *sr; int i, ret; sr = js_malloc(ctx, sizeof(*sr)); if (!sr) return -1; sr->ref_count = 1; sr->already_resolved = FALSE; /* must be shared between the two functions */ ret = 0; for(i = 0; i < 2; i++) { obj = JS_NewObjectProtoClass(ctx, ctx->function_proto, JS_CLASS_PROMISE_RESOLVE_FUNCTION + i); if (JS_IsException(obj)) goto fail; s = js_malloc(ctx, sizeof(*s)); if (!s) { JS_FreeValue(ctx, obj); fail: if (i != 0) JS_FreeValue(ctx, resolving_funcs[0]); ret = -1; break; } sr->ref_count++; s->presolved = sr; s->promise = js_dup(promise); JS_SetOpaqueInternal(obj, s); js_function_set_properties(ctx, obj, JS_ATOM_empty_string, 1); resolving_funcs[i] = obj; } js_promise_resolve_function_free_resolved(ctx->rt, sr); return ret; }
O0
c
js_create_resolving_functions: subq $0x78, %rsp movq %rdx, 0x60(%rsp) movq %rcx, 0x68(%rsp) movq %rdi, 0x58(%rsp) movq %rsi, 0x50(%rsp) movq 0x58(%rsp), %rdi movl $0x8, %esi callq 0x27fa0 movq %rax, 0x30(%rsp) cmpq $0x0, 0x30(%rsp) jne 0x98751 movl $0xffffffff, 0x74(%rsp) # imm = 0xFFFFFFFF jmp 0x98903 movq 0x30(%rsp), %rax movl $0x1, (%rax) movq 0x30(%rsp), %rax movl $0x0, 0x4(%rax) movl $0x0, 0x28(%rsp) movl $0x0, 0x2c(%rsp) cmpl $0x2, 0x2c(%rsp) jge 0x988e8 movq 0x58(%rsp), %rdi movq 0x58(%rsp), %rax movl 0x2c(%rsp), %ecx addl $0x32, %ecx movq 0x48(%rax), %rsi movq 0x50(%rax), %rdx callq 0x30190 movq %rax, 0x18(%rsp) movq %rdx, 0x20(%rsp) movq 0x18(%rsp), %rax movq %rax, 0x40(%rsp) movq 0x20(%rsp), %rax movq %rax, 0x48(%rsp) movq 0x40(%rsp), %rdi movq 0x48(%rsp), %rsi callq 0x29fb0 cmpl $0x0, %eax je 0x987d5 jmp 0x98805 movq 0x58(%rsp), %rdi movl $0x18, %esi callq 0x27fa0 movq %rax, 0x38(%rsp) cmpq $0x0, 0x38(%rsp) jne 0x9882f movq 0x58(%rsp), %rdi movq 0x40(%rsp), %rsi movq 0x48(%rsp), %rdx callq 0x29f80 cmpl $0x0, 0x2c(%rsp) je 0x98822 movq 0x58(%rsp), %rdi movq 0x50(%rsp), %rax movq (%rax), %rsi movq 0x8(%rax), %rdx callq 0x29f80 movl $0xffffffff, 0x28(%rsp) # imm = 0xFFFFFFFF jmp 0x988e8 movq 0x30(%rsp), %rax movl (%rax), %ecx addl $0x1, %ecx movl %ecx, (%rax) movq 0x30(%rsp), %rcx movq 0x38(%rsp), %rax movq %rcx, 0x10(%rax) movq 0x38(%rsp), %rax movq %rax, (%rsp) movq 0x60(%rsp), %rdi movq 0x68(%rsp), %rsi callq 0x279c0 movq %rax, %rcx movq (%rsp), %rax movq %rcx, 0x8(%rsp) movq %rdx, 0x10(%rsp) movq 0x8(%rsp), %rcx movq %rcx, (%rax) movq 0x10(%rsp), %rcx movq %rcx, 0x8(%rax) movq 0x38(%rsp), %rdx movq 0x40(%rsp), %rdi movq 0x48(%rsp), %rsi callq 0x30c90 movq 0x58(%rsp), %rdi movq 0x40(%rsp), %rsi movq 0x48(%rsp), %rdx movl $0x2f, %ecx movl $0x1, %r8d callq 0x30cc0 movq 0x50(%rsp), %rax movslq 0x2c(%rsp), %rcx shlq $0x4, %rcx addq %rcx, %rax movq 0x40(%rsp), %rcx movq %rcx, (%rax) movq 0x48(%rsp), %rcx movq %rcx, 0x8(%rax) movl 0x2c(%rsp), %eax addl $0x1, %eax movl %eax, 0x2c(%rsp) jmp 0x98778 movq 0x58(%rsp), %rax movq 0x18(%rax), %rdi movq 0x30(%rsp), %rsi callq 0x97ea0 movl 0x28(%rsp), %eax movl %eax, 0x74(%rsp) movl 0x74(%rsp), %eax addq $0x78, %rsp retq nopl (%rax)
js_create_resolving_functions: sub rsp, 78h mov [rsp+78h+var_18], rdx mov [rsp+78h+var_10], rcx mov [rsp+78h+var_20], rdi mov [rsp+78h+var_28], rsi mov rdi, [rsp+78h+var_20] mov esi, 8 call js_malloc mov [rsp+78h+var_48], rax cmp [rsp+78h+var_48], 0 jnz short loc_98751 mov [rsp+78h+var_4], 0FFFFFFFFh jmp loc_98903 loc_98751: mov rax, [rsp+78h+var_48] mov dword ptr [rax], 1 mov rax, [rsp+78h+var_48] mov dword ptr [rax+4], 0 mov [rsp+78h+var_50], 0 mov [rsp+78h+var_4C], 0 loc_98778: cmp [rsp+78h+var_4C], 2 jge loc_988E8 mov rdi, [rsp+78h+var_20] mov rax, [rsp+78h+var_20] mov ecx, [rsp+78h+var_4C] add ecx, 32h ; '2' mov rsi, [rax+48h] mov rdx, [rax+50h] call JS_NewObjectProtoClass mov [rsp+78h+var_60], rax mov [rsp+78h+var_58], rdx mov rax, [rsp+78h+var_60] mov [rsp+78h+var_38], rax mov rax, [rsp+78h+var_58] mov [rsp+78h+var_30], rax mov rdi, [rsp+78h+var_38] mov rsi, [rsp+78h+var_30] call JS_IsException_1 cmp eax, 0 jz short loc_987D5 jmp short loc_98805 loc_987D5: mov rdi, [rsp+78h+var_20] mov esi, 18h call js_malloc mov [rsp+78h+var_40], rax cmp [rsp+78h+var_40], 0 jnz short loc_9882F mov rdi, [rsp+78h+var_20] mov rsi, [rsp+78h+var_38] mov rdx, [rsp+78h+var_30] call JS_FreeValue loc_98805: cmp [rsp+78h+var_4C], 0 jz short loc_98822 mov rdi, [rsp+78h+var_20] mov rax, [rsp+78h+var_28] mov rsi, [rax] mov rdx, [rax+8] call JS_FreeValue loc_98822: mov [rsp+78h+var_50], 0FFFFFFFFh jmp loc_988E8 loc_9882F: mov rax, [rsp+78h+var_48] mov ecx, [rax] add ecx, 1 mov [rax], ecx mov rcx, [rsp+78h+var_48] mov rax, [rsp+78h+var_40] mov [rax+10h], rcx mov rax, [rsp+78h+var_40] mov [rsp+78h+var_78], rax mov rdi, [rsp+78h+var_18] mov rsi, [rsp+78h+var_10] call js_dup mov rcx, rax mov rax, [rsp+78h+var_78] mov [rsp+78h+var_70], rcx mov [rsp+78h+var_68], rdx mov rcx, [rsp+78h+var_70] mov [rax], rcx mov rcx, [rsp+78h+var_68] mov [rax+8], rcx mov rdx, [rsp+78h+var_40] mov rdi, [rsp+78h+var_38] mov rsi, [rsp+78h+var_30] call JS_SetOpaqueInternal mov rdi, [rsp+78h+var_20] mov rsi, [rsp+78h+var_38] mov rdx, [rsp+78h+var_30] mov ecx, 2Fh ; '/' mov r8d, 1 call js_function_set_properties mov rax, [rsp+78h+var_28] movsxd rcx, [rsp+78h+var_4C] shl rcx, 4 add rax, rcx mov rcx, [rsp+78h+var_38] mov [rax], rcx mov rcx, [rsp+78h+var_30] mov [rax+8], rcx mov eax, [rsp+78h+var_4C] add eax, 1 mov [rsp+78h+var_4C], eax jmp loc_98778 loc_988E8: mov rax, [rsp+78h+var_20] mov rdi, [rax+18h] mov rsi, [rsp+78h+var_48] call js_promise_resolve_function_free_resolved mov eax, [rsp+78h+var_50] mov [rsp+78h+var_4], eax loc_98903: mov eax, [rsp+78h+var_4] add rsp, 78h retn
long long js_create_resolving_functions(long long *a1, long long *a2, _DWORD *a3, unsigned int a4) { long long v4; // rdx long long v5; // rdx long long *v6; // rax long long v8; // [rsp+18h] [rbp-60h] unsigned int v9; // [rsp+28h] [rbp-50h] int i; // [rsp+2Ch] [rbp-4Ch] int *v11; // [rsp+30h] [rbp-48h] _QWORD *v12; // [rsp+38h] [rbp-40h] long long v13; // [rsp+48h] [rbp-30h] v11 = (int *)js_malloc((long long)a1, 8LL); if ( v11 ) { *v11 = 1; v11[1] = 0; v9 = 0; for ( i = 0; i < 2; ++i ) { v8 = JS_NewObjectProtoClass((long long)a1, a1[9], a1[10], i + 50); v13 = v4; if ( JS_IsException_1(v8, v4) ) goto LABEL_8; v12 = (_QWORD *)js_malloc((long long)a1, 24LL); if ( !v12 ) { JS_FreeValue((long long)a1, v8, v13); LABEL_8: if ( i ) JS_FreeValue((long long)a1, *a2, a2[1]); v9 = -1; break; } ++*v11; v12[2] = v11; *v12 = js_dup(a3, a4); v12[1] = v5; JS_SetOpaqueInternal(v8, v13, (long long)v12); js_function_set_properties((long long)a1, v8, v13, 0x2Fu, 1u); v6 = &a2[2 * i]; *v6 = v8; v6[1] = v13; } js_promise_resolve_function_free_resolved(a1[3], v11); return v9; } else { return (unsigned int)-1; } }
js_create_resolving_functions: SUB RSP,0x78 MOV qword ptr [RSP + 0x60],RDX MOV qword ptr [RSP + 0x68],RCX MOV qword ptr [RSP + 0x58],RDI MOV qword ptr [RSP + 0x50],RSI MOV RDI,qword ptr [RSP + 0x58] MOV ESI,0x8 CALL 0x00127fa0 MOV qword ptr [RSP + 0x30],RAX CMP qword ptr [RSP + 0x30],0x0 JNZ 0x00198751 MOV dword ptr [RSP + 0x74],0xffffffff JMP 0x00198903 LAB_00198751: MOV RAX,qword ptr [RSP + 0x30] MOV dword ptr [RAX],0x1 MOV RAX,qword ptr [RSP + 0x30] MOV dword ptr [RAX + 0x4],0x0 MOV dword ptr [RSP + 0x28],0x0 MOV dword ptr [RSP + 0x2c],0x0 LAB_00198778: CMP dword ptr [RSP + 0x2c],0x2 JGE 0x001988e8 MOV RDI,qword ptr [RSP + 0x58] MOV RAX,qword ptr [RSP + 0x58] MOV ECX,dword ptr [RSP + 0x2c] ADD ECX,0x32 MOV RSI,qword ptr [RAX + 0x48] MOV RDX,qword ptr [RAX + 0x50] CALL 0x00130190 MOV qword ptr [RSP + 0x18],RAX MOV qword ptr [RSP + 0x20],RDX MOV RAX,qword ptr [RSP + 0x18] MOV qword ptr [RSP + 0x40],RAX MOV RAX,qword ptr [RSP + 0x20] MOV qword ptr [RSP + 0x48],RAX MOV RDI,qword ptr [RSP + 0x40] MOV RSI,qword ptr [RSP + 0x48] CALL 0x00129fb0 CMP EAX,0x0 JZ 0x001987d5 JMP 0x00198805 LAB_001987d5: MOV RDI,qword ptr [RSP + 0x58] MOV ESI,0x18 CALL 0x00127fa0 MOV qword ptr [RSP + 0x38],RAX CMP qword ptr [RSP + 0x38],0x0 JNZ 0x0019882f MOV RDI,qword ptr [RSP + 0x58] MOV RSI,qword ptr [RSP + 0x40] MOV RDX,qword ptr [RSP + 0x48] CALL 0x00129f80 LAB_00198805: CMP dword ptr [RSP + 0x2c],0x0 JZ 0x00198822 MOV RDI,qword ptr [RSP + 0x58] MOV RAX,qword ptr [RSP + 0x50] MOV RSI,qword ptr [RAX] MOV RDX,qword ptr [RAX + 0x8] CALL 0x00129f80 LAB_00198822: MOV dword ptr [RSP + 0x28],0xffffffff JMP 0x001988e8 LAB_0019882f: MOV RAX,qword ptr [RSP + 0x30] MOV ECX,dword ptr [RAX] ADD ECX,0x1 MOV dword ptr [RAX],ECX MOV RCX,qword ptr [RSP + 0x30] MOV RAX,qword ptr [RSP + 0x38] MOV qword ptr [RAX + 0x10],RCX MOV RAX,qword ptr [RSP + 0x38] MOV qword ptr [RSP],RAX MOV RDI,qword ptr [RSP + 0x60] MOV RSI,qword ptr [RSP + 0x68] CALL 0x001279c0 MOV RCX,RAX MOV RAX,qword ptr [RSP] MOV qword ptr [RSP + 0x8],RCX MOV qword ptr [RSP + 0x10],RDX MOV RCX,qword ptr [RSP + 0x8] MOV qword ptr [RAX],RCX MOV RCX,qword ptr [RSP + 0x10] MOV qword ptr [RAX + 0x8],RCX MOV RDX,qword ptr [RSP + 0x38] MOV RDI,qword ptr [RSP + 0x40] MOV RSI,qword ptr [RSP + 0x48] CALL 0x00130c90 MOV RDI,qword ptr [RSP + 0x58] MOV RSI,qword ptr [RSP + 0x40] MOV RDX,qword ptr [RSP + 0x48] MOV ECX,0x2f MOV R8D,0x1 CALL 0x00130cc0 MOV RAX,qword ptr [RSP + 0x50] MOVSXD RCX,dword ptr [RSP + 0x2c] SHL RCX,0x4 ADD RAX,RCX MOV RCX,qword ptr [RSP + 0x40] MOV qword ptr [RAX],RCX MOV RCX,qword ptr [RSP + 0x48] MOV qword ptr [RAX + 0x8],RCX MOV EAX,dword ptr [RSP + 0x2c] ADD EAX,0x1 MOV dword ptr [RSP + 0x2c],EAX JMP 0x00198778 LAB_001988e8: MOV RAX,qword ptr [RSP + 0x58] MOV RDI,qword ptr [RAX + 0x18] MOV RSI,qword ptr [RSP + 0x30] CALL 0x00197ea0 MOV EAX,dword ptr [RSP + 0x28] MOV dword ptr [RSP + 0x74],EAX LAB_00198903: MOV EAX,dword ptr [RSP + 0x74] ADD RSP,0x78 RET
int4 js_create_resolving_functions (long param_1,int8 *param_2,int8 param_3,int8 param_4) { int iVar1; int *piVar2; int8 uVar3; int1 (*pauVar4) [16]; int8 uVar5; int1 auVar6 [16]; int1 auVar7 [16]; int4 local_50; int local_4c; int4 local_4; piVar2 = (int *)js_malloc(param_1,8); if (piVar2 == (int *)0x0) { local_4 = 0xffffffff; } else { *piVar2 = 1; piVar2[1] = 0; local_50 = 0; for (local_4c = 0; local_4c < 2; local_4c = local_4c + 1) { auVar6 = JS_NewObjectProtoClass (param_1,*(int8 *)(param_1 + 0x48),*(int8 *)(param_1 + 0x50), local_4c + 0x32); uVar5 = auVar6._8_8_; uVar3 = auVar6._0_8_; iVar1 = JS_IsException(uVar3,uVar5); if (iVar1 != 0) { LAB_00198805: if (local_4c != 0) { JS_FreeValue(param_1,*param_2,param_2[1]); } local_50 = 0xffffffff; break; } pauVar4 = (int1 (*) [16])js_malloc(param_1,0x18); if (pauVar4 == (int1 (*) [16])0x0) { JS_FreeValue(param_1,uVar3,uVar5); goto LAB_00198805; } *piVar2 = *piVar2 + 1; *(int **)pauVar4[1] = piVar2; auVar7 = js_dup(param_3,param_4); *pauVar4 = auVar7; JS_SetOpaqueInternal(uVar3,uVar5,pauVar4); js_function_set_properties(param_1,uVar3,uVar5,0x2f,1); *(int1 (*) [16])(param_2 + (long)local_4c * 2) = auVar6; } js_promise_resolve_function_free_resolved(*(int8 *)(param_1 + 0x18),piVar2); local_4 = local_50; } return local_4; }
20,522
memcmp16
bluesky950520[P]quickjs/quickjs.c
static int memcmp16(const uint16_t *src1, const uint16_t *src2, int len) { int c, i; for(i = 0; i < len; i++) { c = src1[i] - src2[i]; if (c != 0) return c; } return 0; }
O0
c
memcmp16: movq %rdi, -0x10(%rsp) movq %rsi, -0x18(%rsp) movl %edx, -0x1c(%rsp) movl $0x0, -0x24(%rsp) movl -0x24(%rsp), %eax cmpl -0x1c(%rsp), %eax jge 0x63772 movq -0x10(%rsp), %rax movslq -0x24(%rsp), %rcx movzwl (%rax,%rcx,2), %eax movq -0x18(%rsp), %rcx movslq -0x24(%rsp), %rdx movzwl (%rcx,%rdx,2), %ecx subl %ecx, %eax movl %eax, -0x20(%rsp) cmpl $0x0, -0x20(%rsp) je 0x63763 movl -0x20(%rsp), %eax movl %eax, -0x4(%rsp) jmp 0x6377a jmp 0x63765 movl -0x24(%rsp), %eax addl $0x1, %eax movl %eax, -0x24(%rsp) jmp 0x63726 movl $0x0, -0x4(%rsp) movl -0x4(%rsp), %eax retq nop
memcmp16: mov [rsp+var_10], rdi mov [rsp+var_18], rsi mov [rsp+var_1C], edx mov [rsp+var_24], 0 loc_63726: mov eax, [rsp+var_24] cmp eax, [rsp+var_1C] jge short loc_63772 mov rax, [rsp+var_10] movsxd rcx, [rsp+var_24] movzx eax, word ptr [rax+rcx*2] mov rcx, [rsp+var_18] movsxd rdx, [rsp+var_24] movzx ecx, word ptr [rcx+rdx*2] sub eax, ecx mov [rsp+var_20], eax cmp [rsp+var_20], 0 jz short loc_63763 mov eax, [rsp+var_20] mov [rsp+var_4], eax jmp short loc_6377A loc_63763: jmp short $+2 loc_63765: mov eax, [rsp+var_24] add eax, 1 mov [rsp+var_24], eax jmp short loc_63726 loc_63772: mov [rsp+var_4], 0 loc_6377A: mov eax, [rsp+var_4] retn
long long memcmp16(long long a1, long long a2, int a3) { int i; // [rsp+0h] [rbp-24h] for ( i = 0; i < a3; ++i ) { if ( *(unsigned __int16 *)(a1 + 2LL * i) != *(unsigned __int16 *)(a2 + 2LL * i) ) return (unsigned int)(*(unsigned __int16 *)(a1 + 2LL * i) - *(unsigned __int16 *)(a2 + 2LL * i)); } return 0; }
memcmp16: MOV qword ptr [RSP + -0x10],RDI MOV qword ptr [RSP + -0x18],RSI MOV dword ptr [RSP + -0x1c],EDX MOV dword ptr [RSP + -0x24],0x0 LAB_00163726: MOV EAX,dword ptr [RSP + -0x24] CMP EAX,dword ptr [RSP + -0x1c] JGE 0x00163772 MOV RAX,qword ptr [RSP + -0x10] MOVSXD RCX,dword ptr [RSP + -0x24] MOVZX EAX,word ptr [RAX + RCX*0x2] MOV RCX,qword ptr [RSP + -0x18] MOVSXD RDX,dword ptr [RSP + -0x24] MOVZX ECX,word ptr [RCX + RDX*0x2] SUB EAX,ECX MOV dword ptr [RSP + -0x20],EAX CMP dword ptr [RSP + -0x20],0x0 JZ 0x00163763 MOV EAX,dword ptr [RSP + -0x20] MOV dword ptr [RSP + -0x4],EAX JMP 0x0016377a LAB_00163763: JMP 0x00163765 LAB_00163765: MOV EAX,dword ptr [RSP + -0x24] ADD EAX,0x1 MOV dword ptr [RSP + -0x24],EAX JMP 0x00163726 LAB_00163772: MOV dword ptr [RSP + -0x4],0x0 LAB_0016377a: MOV EAX,dword ptr [RSP + -0x4] RET
int memcmp16(long param_1,long param_2,int param_3) { int iVar1; int local_24; local_24 = 0; while( true ) { if (param_3 <= local_24) { return 0; } iVar1 = (uint)*(ushort *)(param_1 + (long)local_24 * 2) - (uint)*(ushort *)(param_2 + (long)local_24 * 2); if (iVar1 != 0) break; local_24 = local_24 + 1; } return iVar1; }
20,523
google::protobuf::compiler::CodeGeneratorResponse::Clear()
aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/compiler/plugin.pb.cc
void CodeGeneratorResponse::Clear() { // @@protoc_insertion_point(message_clear_start:google.protobuf.compiler.CodeGeneratorResponse) uint32_t cached_has_bits = 0; // Prevent compiler warnings about cached_has_bits being unused (void) cached_has_bits; _impl_.file_.Clear(); cached_has_bits = _impl_._has_bits_[0]; if (cached_has_bits & 0x00000001u) { _impl_.error_.ClearNonDefaultToEmpty(); } _impl_.supported_features_ = uint64_t{0u}; _impl_._has_bits_.Clear(); _internal_metadata_.Clear<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(); }
O3
cpp
google::protobuf::compiler::CodeGeneratorResponse::Clear(): pushq %r15 pushq %r14 pushq %r12 pushq %rbx pushq %rax movq %rdi, %rbx movslq 0x20(%rdi), %r14 testq %r14, %r14 jle 0x648d4 movq 0x28(%rbx), %r15 xorl %r12d, %r12d movq 0x8(%r15,%r12,8), %rdi incq %r12 callq 0x64116 cmpq %r12, %r14 jne 0x648bb movl $0x0, 0x20(%rbx) testb $0x1, 0x10(%rbx) je 0x648f0 movq 0x30(%rbx), %rax andq $-0x4, %rax movq $0x0, 0x8(%rax) movq (%rax), %rax movb $0x0, (%rax) movq $0x0, 0x38(%rbx) movl $0x0, 0x10(%rbx) testb $0x1, 0x8(%rbx) jne 0x64911 addq $0x8, %rsp popq %rbx popq %r12 popq %r14 popq %r15 retq addq $0x8, %rbx movq %rbx, %rdi addq $0x8, %rsp popq %rbx popq %r12 popq %r14 popq %r15 jmp 0x65378
_ZN6google8protobuf8compiler21CodeGeneratorResponse5ClearEv: push r15 push r14 push r12 push rbx push rax mov rbx, rdi movsxd r14, dword ptr [rdi+20h] test r14, r14 jle short loc_648D4 mov r15, [rbx+28h] xor r12d, r12d loc_648BB: mov rdi, [r15+r12*8+8]; this inc r12 call _ZN6google8protobuf8compiler26CodeGeneratorResponse_File5ClearEv; google::protobuf::compiler::CodeGeneratorResponse_File::Clear(void) cmp r14, r12 jnz short loc_648BB mov dword ptr [rbx+20h], 0 loc_648D4: test byte ptr [rbx+10h], 1 jz short loc_648F0 mov rax, [rbx+30h] and rax, 0FFFFFFFFFFFFFFFCh mov qword ptr [rax+8], 0 mov rax, [rax] mov byte ptr [rax], 0 loc_648F0: mov qword ptr [rbx+38h], 0 mov dword ptr [rbx+10h], 0 test byte ptr [rbx+8], 1 jnz short loc_64911 add rsp, 8 pop rbx pop r12 pop r14 pop r15 retn loc_64911: add rbx, 8 mov rdi, rbx add rsp, 8 pop rbx pop r12 pop r14 pop r15 jmp _ZN6google8protobuf8internal16InternalMetadata7DoClearINS0_15UnknownFieldSetEEEvv; google::protobuf::internal::InternalMetadata::DoClear<google::protobuf::UnknownFieldSet>(void)
_BYTE * google::protobuf::compiler::CodeGeneratorResponse::Clear( google::protobuf::compiler::CodeGeneratorResponse *this) { long long v2; // r14 long long v3; // r15 long long i; // r12 google::protobuf::compiler::CodeGeneratorResponse_File *v5; // rdi _BYTE *result; // rax unsigned long long v7; // rax v2 = *((int *)this + 8); if ( v2 > 0 ) { v3 = *((_QWORD *)this + 5); for ( i = 0LL; i != v2; ++i ) { v5 = *(google::protobuf::compiler::CodeGeneratorResponse_File **)(v3 + 8 * i + 8); result = (_BYTE *)google::protobuf::compiler::CodeGeneratorResponse_File::Clear(v5); } *((_DWORD *)this + 8) = 0; } if ( (*((_BYTE *)this + 16) & 1) != 0 ) { v7 = *((_QWORD *)this + 6) & 0xFFFFFFFFFFFFFFFCLL; *(_QWORD *)(v7 + 8) = 0LL; result = *(_BYTE **)v7; *result = 0; } *((_QWORD *)this + 7) = 0LL; *((_DWORD *)this + 4) = 0; if ( (*((_BYTE *)this + 8) & 1) != 0 ) return (_BYTE *)google::protobuf::internal::InternalMetadata::DoClear<google::protobuf::UnknownFieldSet>((char *)this + 8); return result; }
Clear: PUSH R15 PUSH R14 PUSH R12 PUSH RBX PUSH RAX MOV RBX,RDI MOVSXD R14,dword ptr [RDI + 0x20] TEST R14,R14 JLE 0x001648d4 MOV R15,qword ptr [RBX + 0x28] XOR R12D,R12D LAB_001648bb: MOV RDI,qword ptr [R15 + R12*0x8 + 0x8] INC R12 CALL 0x00164116 CMP R14,R12 JNZ 0x001648bb MOV dword ptr [RBX + 0x20],0x0 LAB_001648d4: TEST byte ptr [RBX + 0x10],0x1 JZ 0x001648f0 MOV RAX,qword ptr [RBX + 0x30] AND RAX,-0x4 MOV qword ptr [RAX + 0x8],0x0 MOV RAX,qword ptr [RAX] MOV byte ptr [RAX],0x0 LAB_001648f0: MOV qword ptr [RBX + 0x38],0x0 MOV dword ptr [RBX + 0x10],0x0 TEST byte ptr [RBX + 0x8],0x1 JNZ 0x00164911 ADD RSP,0x8 POP RBX POP R12 POP R14 POP R15 RET LAB_00164911: ADD RBX,0x8 MOV RDI,RBX ADD RSP,0x8 POP RBX POP R12 POP R14 POP R15 JMP 0x00165378
/* google::protobuf::compiler::CodeGeneratorResponse::Clear() */ void __thiscall google::protobuf::compiler::CodeGeneratorResponse::Clear(CodeGeneratorResponse *this) { long lVar1; int iVar2; long lVar3; ulong uVar4; long lVar5; iVar2 = *(int *)(this + 0x20); if (0 < (long)iVar2) { lVar3 = *(long *)(this + 0x28); lVar5 = 0; do { lVar1 = lVar5 * 8; lVar5 = lVar5 + 1; CodeGeneratorResponse_File::Clear(*(CodeGeneratorResponse_File **)(lVar3 + 8 + lVar1)); } while (iVar2 != lVar5); *(int4 *)(this + 0x20) = 0; } if (((byte)this[0x10] & 1) != 0) { uVar4 = *(ulong *)(this + 0x30); ((int8 *)(uVar4 & 0xfffffffffffffffc))[1] = 0; **(int1 **)(uVar4 & 0xfffffffffffffffc) = 0; } *(int8 *)(this + 0x38) = 0; *(int4 *)(this + 0x10) = 0; if (((byte)this[8] & 1) == 0) { return; } internal::InternalMetadata::DoClear<google::protobuf::UnknownFieldSet> ((InternalMetadata *)(this + 8)); return; }
20,524
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>::empty() const
monkey531[P]llama/common/json.hpp
bool empty() const noexcept { switch (m_data.m_type) { case value_t::null: { // null values are empty return true; } case value_t::array: { // delegate call to array_t::empty() return m_data.m_value.array->empty(); } case value_t::object: { // delegate call to object_t::empty() return m_data.m_value.object->empty(); } case value_t::string: case value_t::boolean: case value_t::number_integer: case value_t::number_unsigned: case value_t::number_float: case value_t::binary: case value_t::discarded: default: { // all other types are nonempty return false; } } }
O3
cpp
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>::empty() const: movzbl (%rdi), %eax testl %eax, %eax je 0xc865c cmpl $0x1, %eax je 0xc864d cmpl $0x2, %eax jne 0xc865f movq 0x8(%rdi), %rax movq (%rax), %rcx cmpq 0x8(%rax), %rcx sete %al retq movb $0x1, %al retq xorl %eax, %eax retq
_ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE5emptyEv: movzx eax, byte ptr [rdi] test eax, eax jz short loc_C865C cmp eax, 1 jz short loc_C864D cmp eax, 2 jnz short loc_C865F loc_C864D: mov rax, [rdi+8] mov rcx, [rax] cmp rcx, [rax+8] setz al retn loc_C865C: mov al, 1 retn loc_C865F: xor eax, eax retn
bool nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::empty( unsigned __int8 *a1) { int v1; // eax v1 = *a1; if ( !*a1 ) return 1; if ( v1 == 1 || v1 == 2 ) return **((_QWORD **)a1 + 1) == *(_QWORD *)(*((_QWORD *)a1 + 1) + 8LL); return 0; }
empty: MOVZX EAX,byte ptr [RDI] TEST EAX,EAX JZ 0x001c865c CMP EAX,0x1 JZ 0x001c864d CMP EAX,0x2 JNZ 0x001c865f LAB_001c864d: MOV RAX,qword ptr [RDI + 0x8] MOV RCX,qword ptr [RAX] CMP RCX,qword ptr [RAX + 0x8] SETZ AL RET LAB_001c865c: MOV AL,0x1 RET LAB_001c865f: XOR EAX,EAX RET
/* nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char> >, void>::empty() const */ int8 __thiscall nlohmann::json_abi_v3_11_3:: basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> ::empty(basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> *this) { basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> bVar1; long *plVar2; bVar1 = *this; if (bVar1 == (basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> )0x0) { return 1; } if ((bVar1 != (basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> )0x1) && (bVar1 != (basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> )0x2)) { return 0; } plVar2 = *(long **)(this + 8); return CONCAT71((int7)((ulong)plVar2 >> 8),*plVar2 == plVar2[1]); }
20,525
my_symlink
eloqsql/mysys/my_symlink.c
int my_symlink(const char *content, const char *linkname, myf MyFlags) { #ifndef HAVE_READLINK return 0; #else int result; DBUG_ENTER("my_symlink"); DBUG_PRINT("enter",("content: %s linkname: %s", content, linkname)); result= 0; if (symlink(content, linkname)) { result= -1; my_errno=errno; if (MyFlags & MY_WME) my_error(EE_CANT_SYMLINK, MYF(0), linkname, content, errno); } else if ((MyFlags & MY_SYNC_DIR) && my_sync_dir_by_file(linkname, MyFlags)) result= -1; DBUG_RETURN(result); #endif /* HAVE_READLINK */ }
O0
c
my_symlink: pushq %rbp movq %rsp, %rbp subq $0x40, %rsp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq %rdx, -0x18(%rbp) jmp 0x36d56 movl $0x0, -0x1c(%rbp) movq -0x8(%rbp), %rdi movq -0x10(%rbp), %rsi callq 0x24070 cmpl $0x0, %eax je 0x36dca movl $0xffffffff, -0x1c(%rbp) # imm = 0xFFFFFFFF callq 0x24040 movl (%rax), %eax movl %eax, -0x20(%rbp) callq 0x29900 movl -0x20(%rbp), %ecx movl %ecx, (%rax) movq -0x18(%rbp), %rax andq $0x10, %rax cmpq $0x0, %rax je 0x36dc8 movq -0x10(%rbp), %rax movq %rax, -0x30(%rbp) movq -0x8(%rbp), %rax movq %rax, -0x28(%rbp) callq 0x24040 movq -0x30(%rbp), %rdx movq -0x28(%rbp), %rcx movl (%rax), %r8d movl $0x19, %edi xorl %eax, %eax movl %eax, %esi movb $0x0, %al callq 0x34df0 jmp 0x36df5 movq -0x18(%rbp), %rax andq $0x8000, %rax # imm = 0x8000 cmpq $0x0, %rax je 0x36df3 movq -0x10(%rbp), %rdi movq -0x18(%rbp), %rsi callq 0x374c0 cmpl $0x0, %eax je 0x36df3 movl $0xffffffff, -0x1c(%rbp) # imm = 0xFFFFFFFF jmp 0x36df5 jmp 0x36df7 movl -0x1c(%rbp), %eax movl %eax, -0x34(%rbp) movl -0x34(%rbp), %eax addq $0x40, %rsp popq %rbp retq nopw %cs:(%rax,%rax)
my_symlink: push rbp mov rbp, rsp sub rsp, 40h mov [rbp+var_8], rdi mov [rbp+var_10], rsi mov [rbp+var_18], rdx jmp short $+2 loc_36D56: mov [rbp+var_1C], 0 mov rdi, [rbp+var_8] mov rsi, [rbp+var_10] call _symlink cmp eax, 0 jz short loc_36DCA mov [rbp+var_1C], 0FFFFFFFFh call ___errno_location mov eax, [rax] mov [rbp+var_20], eax call _my_thread_var mov ecx, [rbp+var_20] mov [rax], ecx mov rax, [rbp+var_18] and rax, 10h cmp rax, 0 jz short loc_36DC8 mov rax, [rbp+var_10] mov [rbp+var_30], rax mov rax, [rbp+var_8] mov [rbp+var_28], rax call ___errno_location mov rdx, [rbp+var_30] mov rcx, [rbp+var_28] mov r8d, [rax] mov edi, 19h xor eax, eax mov esi, eax mov al, 0 call my_error loc_36DC8: jmp short loc_36DF5 loc_36DCA: mov rax, [rbp+var_18] and rax, 8000h cmp rax, 0 jz short loc_36DF3 mov rdi, [rbp+var_10] mov rsi, [rbp+var_18] call my_sync_dir_by_file cmp eax, 0 jz short loc_36DF3 mov [rbp+var_1C], 0FFFFFFFFh loc_36DF3: jmp short $+2 loc_36DF5: jmp short $+2 loc_36DF7: mov eax, [rbp+var_1C] mov [rbp+var_34], eax mov eax, [rbp+var_34] add rsp, 40h pop rbp retn
long long my_symlink(long long a1, long long a2, long long a3) { unsigned int *v3; // rax int v5; // [rsp+20h] [rbp-20h] unsigned int v6; // [rsp+24h] [rbp-1Ch] v6 = 0; if ( (unsigned int)symlink(a1, a2) ) { v6 = -1; v5 = *(_DWORD *)__errno_location(); *(_DWORD *)my_thread_var() = v5; if ( (a3 & 0x10) != 0 ) { v3 = (unsigned int *)__errno_location(); my_error(0x19u, 0LL, a2, a1, *v3); } } else if ( (a3 & 0x8000) != 0 && (unsigned int)my_sync_dir_by_file(a2, a3) ) { return (unsigned int)-1; } return v6; }
my_symlink: PUSH RBP MOV RBP,RSP SUB RSP,0x40 MOV qword ptr [RBP + -0x8],RDI MOV qword ptr [RBP + -0x10],RSI MOV qword ptr [RBP + -0x18],RDX JMP 0x00136d56 LAB_00136d56: MOV dword ptr [RBP + -0x1c],0x0 MOV RDI,qword ptr [RBP + -0x8] MOV RSI,qword ptr [RBP + -0x10] CALL 0x00124070 CMP EAX,0x0 JZ 0x00136dca MOV dword ptr [RBP + -0x1c],0xffffffff CALL 0x00124040 MOV EAX,dword ptr [RAX] MOV dword ptr [RBP + -0x20],EAX CALL 0x00129900 MOV ECX,dword ptr [RBP + -0x20] MOV dword ptr [RAX],ECX MOV RAX,qword ptr [RBP + -0x18] AND RAX,0x10 CMP RAX,0x0 JZ 0x00136dc8 MOV RAX,qword ptr [RBP + -0x10] MOV qword ptr [RBP + -0x30],RAX MOV RAX,qword ptr [RBP + -0x8] MOV qword ptr [RBP + -0x28],RAX CALL 0x00124040 MOV RDX,qword ptr [RBP + -0x30] MOV RCX,qword ptr [RBP + -0x28] MOV R8D,dword ptr [RAX] MOV EDI,0x19 XOR EAX,EAX MOV ESI,EAX MOV AL,0x0 CALL 0x00134df0 LAB_00136dc8: JMP 0x00136df5 LAB_00136dca: MOV RAX,qword ptr [RBP + -0x18] AND RAX,0x8000 CMP RAX,0x0 JZ 0x00136df3 MOV RDI,qword ptr [RBP + -0x10] MOV RSI,qword ptr [RBP + -0x18] CALL 0x001374c0 CMP EAX,0x0 JZ 0x00136df3 MOV dword ptr [RBP + -0x1c],0xffffffff LAB_00136df3: JMP 0x00136df5 LAB_00136df5: JMP 0x00136df7 LAB_00136df7: MOV EAX,dword ptr [RBP + -0x1c] MOV dword ptr [RBP + -0x34],EAX MOV EAX,dword ptr [RBP + -0x34] ADD RSP,0x40 POP RBP RET
int4 my_symlink(char *param_1,char *param_2,ulong param_3) { int iVar1; int *piVar2; int4 local_24; local_24 = 0; iVar1 = symlink(param_1,param_2); if (iVar1 == 0) { if (((param_3 & 0x8000) != 0) && (iVar1 = my_sync_dir_by_file(param_2,param_3), iVar1 != 0)) { local_24 = 0xffffffff; } } else { local_24 = 0xffffffff; piVar2 = __errno_location(); iVar1 = *piVar2; piVar2 = (int *)_my_thread_var(); *piVar2 = iVar1; if ((param_3 & 0x10) != 0) { piVar2 = __errno_location(); my_error(0x19,0,param_2,param_1,*piVar2); } } return local_24; }
20,526
my_strxfrm_pad_desc_and_reverse_nopad
eloqsql/strings/ctype-simple.c
size_t my_strxfrm_pad_desc_and_reverse_nopad(CHARSET_INFO *cs, uchar *str, uchar *frmend, uchar *strend, uint nweights, uint flags, uint level) { if (nweights && frmend < strend && (flags & MY_STRXFRM_PAD_WITH_SPACE)) { uint fill_length= MY_MIN((uint) (strend - frmend), nweights * cs->mbminlen); memset(frmend, 0x00, fill_length); frmend+= fill_length; } my_strxfrm_desc_and_reverse(str, frmend, flags, level); if ((flags & MY_STRXFRM_PAD_TO_MAXLEN) && frmend < strend) { size_t fill_length= strend - frmend; memset(frmend, 0x00, fill_length); frmend= strend; } return frmend - str; }
O0
c
my_strxfrm_pad_desc_and_reverse_nopad: pushq %rbp movq %rsp, %rbp subq $0x40, %rsp movl 0x10(%rbp), %eax movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq %rdx, -0x18(%rbp) movq %rcx, -0x20(%rbp) movl %r8d, -0x24(%rbp) movl %r9d, -0x28(%rbp) cmpl $0x0, -0x24(%rbp) je 0xa1c32 movq -0x18(%rbp), %rax cmpq -0x20(%rbp), %rax jae 0xa1c32 movl -0x28(%rbp), %eax andl $0x40, %eax cmpl $0x0, %eax je 0xa1c32 movq -0x20(%rbp), %rax movq -0x18(%rbp), %rcx subq %rcx, %rax movl -0x24(%rbp), %ecx movq -0x8(%rbp), %rdx imull 0x98(%rdx), %ecx cmpl %ecx, %eax jae 0xa1bfb movq -0x20(%rbp), %rax movq -0x18(%rbp), %rcx subq %rcx, %rax movl %eax, -0x3c(%rbp) jmp 0xa1c0c movl -0x24(%rbp), %eax movq -0x8(%rbp), %rcx imull 0x98(%rcx), %eax movl %eax, -0x3c(%rbp) movl -0x3c(%rbp), %eax movl %eax, -0x2c(%rbp) movq -0x18(%rbp), %rdi movl -0x2c(%rbp), %eax movl %eax, %edx xorl %esi, %esi callq 0x281c0 movl -0x2c(%rbp), %ecx movq -0x18(%rbp), %rax movl %ecx, %ecx addq %rcx, %rax movq %rax, -0x18(%rbp) movq -0x10(%rbp), %rdi movq -0x18(%rbp), %rsi movl -0x28(%rbp), %edx movl 0x10(%rbp), %ecx callq 0xa4e30 movl -0x28(%rbp), %eax andl $0x80, %eax cmpl $0x0, %eax je 0xa1c82 movq -0x18(%rbp), %rax cmpq -0x20(%rbp), %rax jae 0xa1c82 movq -0x20(%rbp), %rax movq -0x18(%rbp), %rcx subq %rcx, %rax movq %rax, -0x38(%rbp) movq -0x18(%rbp), %rdi movq -0x38(%rbp), %rdx xorl %esi, %esi callq 0x281c0 movq -0x20(%rbp), %rax movq %rax, -0x18(%rbp) movq -0x18(%rbp), %rax movq -0x10(%rbp), %rcx subq %rcx, %rax addq $0x40, %rsp popq %rbp retq nopw %cs:(%rax,%rax)
my_strxfrm_pad_desc_and_reverse_nopad: push rbp mov rbp, rsp sub rsp, 40h mov eax, [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_24], r8d mov [rbp+var_28], r9d cmp [rbp+var_24], 0 jz short loc_A1C32 mov rax, [rbp+var_18] cmp rax, [rbp+var_20] jnb short loc_A1C32 mov eax, [rbp+var_28] and eax, 40h cmp eax, 0 jz short loc_A1C32 mov rax, [rbp+var_20] mov rcx, [rbp+var_18] sub rax, rcx mov ecx, [rbp+var_24] mov rdx, [rbp+var_8] imul ecx, [rdx+98h] cmp eax, ecx jnb short loc_A1BFB mov rax, [rbp+var_20] mov rcx, [rbp+var_18] sub rax, rcx mov [rbp+var_3C], eax jmp short loc_A1C0C loc_A1BFB: mov eax, [rbp+var_24] mov rcx, [rbp+var_8] imul eax, [rcx+98h] mov [rbp+var_3C], eax loc_A1C0C: mov eax, [rbp+var_3C] mov [rbp+var_2C], eax mov rdi, [rbp+var_18] mov eax, [rbp+var_2C] mov edx, eax xor esi, esi call _memset mov ecx, [rbp+var_2C] mov rax, [rbp+var_18] mov ecx, ecx add rax, rcx mov [rbp+var_18], rax loc_A1C32: mov rdi, [rbp+var_10] mov rsi, [rbp+var_18] mov edx, [rbp+var_28] mov ecx, [rbp+arg_0] call my_strxfrm_desc_and_reverse mov eax, [rbp+var_28] and eax, 80h cmp eax, 0 jz short loc_A1C82 mov rax, [rbp+var_18] cmp rax, [rbp+var_20] jnb short loc_A1C82 mov rax, [rbp+var_20] mov rcx, [rbp+var_18] sub rax, rcx mov [rbp+var_38], rax mov rdi, [rbp+var_18] mov rdx, [rbp+var_38] xor esi, esi call _memset mov rax, [rbp+var_20] mov [rbp+var_18], rax loc_A1C82: mov rax, [rbp+var_18] mov rcx, [rbp+var_10] sub rax, rcx add rsp, 40h pop rbp retn
long long my_strxfrm_pad_desc_and_reverse_nopad( long long a1, long long a2, unsigned long long a3, unsigned long long a4, int a5, unsigned int a6, unsigned int a7) { unsigned int v8; // [rsp+4h] [rbp-3Ch] unsigned long long v11; // [rsp+28h] [rbp-18h] v11 = a3; if ( a5 && a3 < a4 && (a6 & 0x40) != 0 ) { if ( (int)a4 - (int)a3 >= (unsigned int)(*(_DWORD *)(a1 + 152) * a5) ) v8 = *(_DWORD *)(a1 + 152) * a5; else v8 = a4 - a3; memset(a3, 0LL, v8); v11 += v8; } my_strxfrm_desc_and_reverse(a2, v11, a6, a7); if ( (a6 & 0x80) != 0 && v11 < a4 ) { memset(v11, 0LL, a4 - v11); v11 = a4; } return v11 - a2; }
my_strxfrm_pad_desc_and_reverse_nopad: PUSH RBP MOV RBP,RSP SUB RSP,0x40 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 qword ptr [RBP + -0x20],RCX MOV dword ptr [RBP + -0x24],R8D MOV dword ptr [RBP + -0x28],R9D CMP dword ptr [RBP + -0x24],0x0 JZ 0x001a1c32 MOV RAX,qword ptr [RBP + -0x18] CMP RAX,qword ptr [RBP + -0x20] JNC 0x001a1c32 MOV EAX,dword ptr [RBP + -0x28] AND EAX,0x40 CMP EAX,0x0 JZ 0x001a1c32 MOV RAX,qword ptr [RBP + -0x20] MOV RCX,qword ptr [RBP + -0x18] SUB RAX,RCX MOV ECX,dword ptr [RBP + -0x24] MOV RDX,qword ptr [RBP + -0x8] IMUL ECX,dword ptr [RDX + 0x98] CMP EAX,ECX JNC 0x001a1bfb MOV RAX,qword ptr [RBP + -0x20] MOV RCX,qword ptr [RBP + -0x18] SUB RAX,RCX MOV dword ptr [RBP + -0x3c],EAX JMP 0x001a1c0c LAB_001a1bfb: MOV EAX,dword ptr [RBP + -0x24] MOV RCX,qword ptr [RBP + -0x8] IMUL EAX,dword ptr [RCX + 0x98] MOV dword ptr [RBP + -0x3c],EAX LAB_001a1c0c: MOV EAX,dword ptr [RBP + -0x3c] MOV dword ptr [RBP + -0x2c],EAX MOV RDI,qword ptr [RBP + -0x18] MOV EAX,dword ptr [RBP + -0x2c] MOV EDX,EAX XOR ESI,ESI CALL 0x001281c0 MOV ECX,dword ptr [RBP + -0x2c] MOV RAX,qword ptr [RBP + -0x18] MOV ECX,ECX ADD RAX,RCX MOV qword ptr [RBP + -0x18],RAX LAB_001a1c32: MOV RDI,qword ptr [RBP + -0x10] MOV RSI,qword ptr [RBP + -0x18] MOV EDX,dword ptr [RBP + -0x28] MOV ECX,dword ptr [RBP + 0x10] CALL 0x001a4e30 MOV EAX,dword ptr [RBP + -0x28] AND EAX,0x80 CMP EAX,0x0 JZ 0x001a1c82 MOV RAX,qword ptr [RBP + -0x18] CMP RAX,qword ptr [RBP + -0x20] JNC 0x001a1c82 MOV RAX,qword ptr [RBP + -0x20] MOV RCX,qword ptr [RBP + -0x18] SUB RAX,RCX MOV qword ptr [RBP + -0x38],RAX MOV RDI,qword ptr [RBP + -0x18] MOV RDX,qword ptr [RBP + -0x38] XOR ESI,ESI CALL 0x001281c0 MOV RAX,qword ptr [RBP + -0x20] MOV qword ptr [RBP + -0x18],RAX LAB_001a1c82: MOV RAX,qword ptr [RBP + -0x18] MOV RCX,qword ptr [RBP + -0x10] SUB RAX,RCX ADD RSP,0x40 POP RBP RET
long my_strxfrm_pad_desc_and_reverse_nopad (long param_1,long param_2,void *param_3,void *param_4,int param_5,uint param_6, int4 param_7) { int4 local_44; int8 local_20; local_20 = param_3; if (((param_5 != 0) && (param_3 < param_4)) && ((param_6 & 0x40) != 0)) { if ((uint)((int)param_4 - (int)param_3) < (uint)(param_5 * *(int *)(param_1 + 0x98))) { local_44 = (int)param_4 - (int)param_3; } else { local_44 = param_5 * *(int *)(param_1 + 0x98); } memset(param_3,0,(ulong)local_44); local_20 = (void *)((long)param_3 + (ulong)local_44); } my_strxfrm_desc_and_reverse(param_2,local_20,param_6,param_7); if (((param_6 & 0x80) != 0) && (local_20 < param_4)) { memset(local_20,0,(long)param_4 - (long)local_20); local_20 = param_4; } return (long)local_20 - param_2; }
20,527
translog_filename_by_fileno
eloqsql/storage/maria/ma_loghandler.c
char *translog_filename_by_fileno(uint32 file_no, char *path) { char buff[11], *end; uint length; DBUG_ENTER("translog_filename_by_fileno"); DBUG_ASSERT(file_no <= 0xfffffff); /* log_descriptor.directory is already formated */ end= strxmov(path, log_descriptor.directory, "aria_log.0000000", NullS); length= (uint) (int10_to_str(file_no, buff, 10) - buff); strmov(end - length +1, buff); DBUG_PRINT("info", ("Path: '%s' path: %p", path, path)); DBUG_RETURN(path); }
O0
c
translog_filename_by_fileno: pushq %rbp movq %rsp, %rbp subq $0x40, %rsp movq %fs:0x28, %rax movq %rax, -0x8(%rbp) movl %edi, -0x18(%rbp) movq %rsi, -0x20(%rbp) jmp 0x89ace movq -0x20(%rbp), %rdi leaq 0x3fe947(%rip), %rsi # 0x488420 addq $0x28, %rsi leaq 0xd39ce(%rip), %rdx # 0x15d4b2 xorl %eax, %eax movl %eax, %ecx movb $0x0, %al callq 0x159fc0 movq %rax, -0x28(%rbp) movl -0x18(%rbp), %eax movl %eax, %edi leaq -0x13(%rbp), %rsi movl $0xa, %edx callq 0x156570 leaq -0x13(%rbp), %rcx subq %rcx, %rax movl %eax, -0x2c(%rbp) movq -0x28(%rbp), %rdi movl -0x2c(%rbp), %eax movl %eax, %ecx xorl %eax, %eax subq %rcx, %rax addq %rax, %rdi addq $0x1, %rdi leaq -0x13(%rbp), %rsi callq 0x2a720 jmp 0x89b30 jmp 0x89b32 movq -0x20(%rbp), %rax movq %rax, -0x38(%rbp) movq %fs:0x28, %rax movq -0x8(%rbp), %rcx cmpq %rcx, %rax jne 0x89b56 movq -0x38(%rbp), %rax addq $0x40, %rsp popq %rbp retq callq 0x2a250 nopl (%rax,%rax)
translog_filename_by_fileno: push rbp mov rbp, rsp sub rsp, 40h mov rax, fs:28h mov [rbp+var_8], rax mov [rbp+var_18], edi mov [rbp+var_20], rsi jmp short $+2 loc_89ACE: mov rdi, [rbp+var_20] lea rsi, log_descriptor add rsi, 28h ; '(' lea rdx, aAriaLog0000000; "aria_log.0000000" xor eax, eax mov ecx, eax mov al, 0 call strxmov mov [rbp+var_28], rax mov eax, [rbp+var_18] mov edi, eax lea rsi, [rbp+var_13] mov edx, 0Ah call int10_to_str lea rcx, [rbp+var_13] sub rax, rcx mov [rbp+var_2C], eax mov rdi, [rbp+var_28] mov eax, [rbp+var_2C] mov ecx, eax xor eax, eax sub rax, rcx add rdi, rax add rdi, 1 lea rsi, [rbp+var_13] call _stpcpy jmp short $+2 loc_89B30: jmp short $+2 loc_89B32: mov rax, [rbp+var_20] mov [rbp+var_38], rax mov rax, fs:28h mov rcx, [rbp+var_8] cmp rax, rcx jnz short loc_89B56 mov rax, [rbp+var_38] add rsp, 40h pop rbp retn loc_89B56: call ___stack_chk_fail
long long translog_filename_by_fileno(unsigned int a1, long long a2, long long a3, long long a4, int a5, int a6) { unsigned int v7; // [rsp+14h] [rbp-2Ch] long long v8; // [rsp+18h] [rbp-28h] _BYTE v9[11]; // [rsp+2Dh] [rbp-13h] BYREF unsigned long long v10; // [rsp+38h] [rbp-8h] long long savedregs; // [rsp+40h] [rbp+0h] BYREF v10 = __readfsqword(0x28u); v8 = strxmov(a2, (unsigned int)(&log_descriptor + 5), (unsigned int)"aria_log.0000000", 0, a5, a6); v7 = int10_to_str(a1, v9, 10LL) - ((unsigned int)&savedregs - 19); stpcpy(v8 - v7 + 1, v9); return a2; }
translog_filename_by_fileno: PUSH RBP MOV RBP,RSP SUB RSP,0x40 MOV RAX,qword ptr FS:[0x28] MOV qword ptr [RBP + -0x8],RAX MOV dword ptr [RBP + -0x18],EDI MOV qword ptr [RBP + -0x20],RSI JMP 0x00189ace LAB_00189ace: MOV RDI,qword ptr [RBP + -0x20] LEA RSI,[0x588420] ADD RSI,0x28 LEA RDX,[0x25d4b2] XOR EAX,EAX MOV ECX,EAX MOV AL,0x0 CALL 0x00259fc0 MOV qword ptr [RBP + -0x28],RAX MOV EAX,dword ptr [RBP + -0x18] MOV EDI,EAX LEA RSI,[RBP + -0x13] MOV EDX,0xa CALL 0x00256570 LEA RCX,[RBP + -0x13] SUB RAX,RCX MOV dword ptr [RBP + -0x2c],EAX MOV RDI,qword ptr [RBP + -0x28] MOV EAX,dword ptr [RBP + -0x2c] MOV ECX,EAX XOR EAX,EAX SUB RAX,RCX ADD RDI,RAX ADD RDI,0x1 LEA RSI,[RBP + -0x13] CALL 0x0012a720 JMP 0x00189b30 LAB_00189b30: JMP 0x00189b32 LAB_00189b32: MOV RAX,qword ptr [RBP + -0x20] MOV qword ptr [RBP + -0x38],RAX MOV RAX,qword ptr FS:[0x28] MOV RCX,qword ptr [RBP + -0x8] CMP RAX,RCX JNZ 0x00189b56 MOV RAX,qword ptr [RBP + -0x38] ADD RSP,0x40 POP RBP RET LAB_00189b56: CALL 0x0012a250
int8 translog_filename_by_fileno(int4 param_1,int8 param_2) { int iVar1; long lVar2; long in_FS_OFFSET; char local_1b [11]; long local_10; local_10 = *(long *)(in_FS_OFFSET + 0x28); lVar2 = strxmov(param_2,&DAT_00588448,"aria_log.0000000",0); iVar1 = int10_to_str(param_1,local_1b,10); stpcpy((char *)((lVar2 - (ulong)(uint)(iVar1 - (int)local_1b)) + 1),local_1b); if (*(long *)(in_FS_OFFSET + 0x28) == local_10) { return param_2; } /* WARNING: Subroutine does not return */ __stack_chk_fail(); }
20,528
find_timer_by_id
bluesky950520[P]quickjs/quickjs-libc.c
static JSOSTimer *find_timer_by_id(JSThreadState *ts, int timer_id) { struct list_head *el; if (timer_id <= 0) return NULL; list_for_each(el, &ts->os_timers) { JSOSTimer *th = list_entry(el, JSOSTimer, link); if (th->timer_id == timer_id) return th; } return NULL; }
O0
c
find_timer_by_id: movq %rdi, -0x10(%rsp) movl %esi, -0x14(%rsp) cmpl $0x0, -0x14(%rsp) jg 0x1ce7b movq $0x0, -0x8(%rsp) jmp 0x1cee0 movq -0x10(%rsp), %rax movq 0x28(%rax), %rax movq %rax, -0x20(%rsp) movq -0x20(%rsp), %rax movq -0x10(%rsp), %rcx addq $0x20, %rcx cmpq %rcx, %rax je 0x1ced7 movq -0x20(%rsp), %rax movq %rax, -0x28(%rsp) movq -0x28(%rsp), %rax movq 0x10(%rax), %rax movslq -0x14(%rsp), %rcx cmpq %rcx, %rax jne 0x1cec5 movq -0x28(%rsp), %rax movq %rax, -0x8(%rsp) jmp 0x1cee0 jmp 0x1cec7 movq -0x20(%rsp), %rax movq 0x8(%rax), %rax movq %rax, -0x20(%rsp) jmp 0x1ce89 movq $0x0, -0x8(%rsp) movq -0x8(%rsp), %rax retq nopw %cs:(%rax,%rax)
find_timer_by_id: mov [rsp+var_10], rdi mov [rsp+var_14], esi cmp [rsp+var_14], 0 jg short loc_1CE7B mov [rsp+var_8], 0 jmp short loc_1CEE0 loc_1CE7B: mov rax, [rsp+var_10] mov rax, [rax+28h] mov [rsp+var_20], rax loc_1CE89: mov rax, [rsp+var_20] mov rcx, [rsp+var_10] add rcx, 20h ; ' ' cmp rax, rcx jz short loc_1CED7 mov rax, [rsp+var_20] mov [rsp+var_28], rax mov rax, [rsp+var_28] mov rax, [rax+10h] movsxd rcx, [rsp+var_14] cmp rax, rcx jnz short loc_1CEC5 mov rax, [rsp+var_28] mov [rsp+var_8], rax jmp short loc_1CEE0 loc_1CEC5: jmp short $+2 loc_1CEC7: mov rax, [rsp+var_20] mov rax, [rax+8] mov [rsp+var_20], rax jmp short loc_1CE89 loc_1CED7: mov [rsp+var_8], 0 loc_1CEE0: mov rax, [rsp+var_8] retn
long long find_timer_by_id(long long a1, int a2) { long long i; // [rsp+8h] [rbp-20h] if ( a2 <= 0 ) return 0LL; for ( i = *(_QWORD *)(a1 + 40); i != a1 + 32; i = *(_QWORD *)(i + 8) ) { if ( *(_QWORD *)(i + 16) == a2 ) return i; } return 0LL; }
find_timer_by_id: MOV qword ptr [RSP + -0x10],RDI MOV dword ptr [RSP + -0x14],ESI CMP dword ptr [RSP + -0x14],0x0 JG 0x0011ce7b MOV qword ptr [RSP + -0x8],0x0 JMP 0x0011cee0 LAB_0011ce7b: MOV RAX,qword ptr [RSP + -0x10] MOV RAX,qword ptr [RAX + 0x28] MOV qword ptr [RSP + -0x20],RAX LAB_0011ce89: MOV RAX,qword ptr [RSP + -0x20] MOV RCX,qword ptr [RSP + -0x10] ADD RCX,0x20 CMP RAX,RCX JZ 0x0011ced7 MOV RAX,qword ptr [RSP + -0x20] MOV qword ptr [RSP + -0x28],RAX MOV RAX,qword ptr [RSP + -0x28] MOV RAX,qword ptr [RAX + 0x10] MOVSXD RCX,dword ptr [RSP + -0x14] CMP RAX,RCX JNZ 0x0011cec5 MOV RAX,qword ptr [RSP + -0x28] MOV qword ptr [RSP + -0x8],RAX JMP 0x0011cee0 LAB_0011cec5: JMP 0x0011cec7 LAB_0011cec7: MOV RAX,qword ptr [RSP + -0x20] MOV RAX,qword ptr [RAX + 0x8] MOV qword ptr [RSP + -0x20],RAX JMP 0x0011ce89 LAB_0011ced7: MOV qword ptr [RSP + -0x8],0x0 LAB_0011cee0: MOV RAX,qword ptr [RSP + -0x8] RET
long find_timer_by_id(long param_1,int param_2) { long local_20; if (0 < param_2) { for (local_20 = *(long *)(param_1 + 0x28); local_20 != param_1 + 0x20; local_20 = *(long *)(local_20 + 8)) { if (*(long *)(local_20 + 0x10) == (long)param_2) { return local_20; } } } return 0; }
20,529
common_batch_add(llama_batch&, int, int, std::vector<int, std::allocator<int>> const&, bool)
monkey531[P]llama/common/common.cpp
void common_batch_add( struct llama_batch & batch, llama_token id, llama_pos pos, const std::vector<llama_seq_id> & seq_ids, bool logits) { GGML_ASSERT(batch.seq_id[batch.n_tokens] && "llama_batch size exceeded"); batch.token [batch.n_tokens] = id; batch.pos [batch.n_tokens] = pos; batch.n_seq_id[batch.n_tokens] = seq_ids.size(); for (size_t i = 0; i < seq_ids.size(); ++i) { batch.seq_id[batch.n_tokens][i] = seq_ids[i]; } batch.logits [batch.n_tokens] = logits; batch.n_tokens++; }
O1
cpp
common_batch_add(llama_batch&, int, int, std::vector<int, std::allocator<int>> const&, bool): pushq %rax movq 0x28(%rdi), %rax movslq (%rdi), %r9 cmpq $0x0, (%rax,%r9,8) je 0x761cc movq 0x8(%rdi), %r10 movl %esi, (%r10,%r9,4) movq 0x18(%rdi), %rsi movslq (%rdi), %r9 movl %edx, (%rsi,%r9,4) movq (%rcx), %rdx movq 0x8(%rcx), %rsi movq %rsi, %rcx subq %rdx, %rcx sarq $0x2, %rcx movq 0x20(%rdi), %r9 movslq (%rdi), %r10 movl %ecx, (%r9,%r10,4) cmpq %rdx, %rsi je 0x761bd cmpq $0x1, %rcx adcq $0x0, %rcx xorl %esi, %esi movl (%rdx,%rsi,4), %r9d movslq (%rdi), %r10 movq (%rax,%r10,8), %r10 movl %r9d, (%r10,%rsi,4) incq %rsi cmpq %rsi, %rcx jne 0x761a6 movq 0x30(%rdi), %rax movslq (%rdi), %rcx movb %r8b, (%rax,%rcx) incl (%rdi) popq %rax retq leaq 0x7bc0e(%rip), %rdi # 0xf1de1 leaq 0x730c7(%rip), %rdx # 0xe92a1 leaq 0x7c244(%rip), %rcx # 0xf2425 movl $0x655, %esi # imm = 0x655 xorl %eax, %eax callq 0x1bed0
_Z16common_batch_addR11llama_batchiiRKSt6vectorIiSaIiEEb: push rax mov rax, [rdi+28h] movsxd r9, dword ptr [rdi] cmp qword ptr [rax+r9*8], 0 jz short loc_761CC mov r10, [rdi+8] mov [r10+r9*4], esi mov rsi, [rdi+18h] movsxd r9, dword ptr [rdi] mov [rsi+r9*4], edx mov rdx, [rcx] mov rsi, [rcx+8] mov rcx, rsi sub rcx, rdx sar rcx, 2 mov r9, [rdi+20h] movsxd r10, dword ptr [rdi] mov [r9+r10*4], ecx cmp rsi, rdx jz short loc_761BD cmp rcx, 1 adc rcx, 0 xor esi, esi loc_761A6: mov r9d, [rdx+rsi*4] movsxd r10, dword ptr [rdi] mov r10, [rax+r10*8] mov [r10+rsi*4], r9d inc rsi cmp rcx, rsi jnz short loc_761A6 loc_761BD: mov rax, [rdi+30h] movsxd rcx, dword ptr [rdi] mov [rax+rcx], r8b inc dword ptr [rdi] pop rax retn loc_761CC: lea rdi, aWorkspaceLlm4b_2; "/workspace/llm4binary/github/2025_star3"... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aBatchSeqIdBatc; "batch.seq_id[batch.n_tokens] && \"llama"... mov esi, 655h xor eax, eax call _ggml_abort
long long common_batch_add(int *a1, int a2, int a3, long long *a4, char a5) { long long v5; // rax long long v6; // rax long long v7; // r9 long long v8; // rdx long long v9; // rsi long long v10; // rcx long long v11; // rcx long long v12; // rsi long long v14; // [rsp-8h] [rbp-8h] v14 = v5; v6 = *((_QWORD *)a1 + 5); v7 = *a1; if ( *(_QWORD *)(v6 + 8 * v7) ) { *(_DWORD *)(*((_QWORD *)a1 + 1) + 4 * v7) = a2; *(_DWORD *)(*((_QWORD *)a1 + 3) + 4LL * *a1) = a3; v8 = *a4; v9 = a4[1]; v10 = (v9 - *a4) >> 2; *(_DWORD *)(*((_QWORD *)a1 + 4) + 4LL * *a1) = v10; if ( v9 != v8 ) { v11 = (v10 == 0) + v10; v12 = 0LL; do { *(_DWORD *)(*(_QWORD *)(v6 + 8LL * *a1) + 4 * v12) = *(_DWORD *)(v8 + 4 * v12); ++v12; } while ( v11 != v12 ); } *(_BYTE *)(*((_QWORD *)a1 + 6) + (*a1)++) = a5; return v14; } else { ggml_abort( "/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/common.cpp", 1621LL, "GGML_ASSERT(%s) failed", "batch.seq_id[batch.n_tokens] && \"llama_batch size exceeded\""); return common_lcp(); } }
common_batch_add: PUSH RAX MOV RAX,qword ptr [RDI + 0x28] MOVSXD R9,dword ptr [RDI] CMP qword ptr [RAX + R9*0x8],0x0 JZ 0x001761cc MOV R10,qword ptr [RDI + 0x8] MOV dword ptr [R10 + R9*0x4],ESI MOV RSI,qword ptr [RDI + 0x18] MOVSXD R9,dword ptr [RDI] MOV dword ptr [RSI + R9*0x4],EDX MOV RDX,qword ptr [RCX] MOV RSI,qword ptr [RCX + 0x8] MOV RCX,RSI SUB RCX,RDX SAR RCX,0x2 MOV R9,qword ptr [RDI + 0x20] MOVSXD R10,dword ptr [RDI] MOV dword ptr [R9 + R10*0x4],ECX CMP RSI,RDX JZ 0x001761bd CMP RCX,0x1 ADC RCX,0x0 XOR ESI,ESI LAB_001761a6: MOV R9D,dword ptr [RDX + RSI*0x4] MOVSXD R10,dword ptr [RDI] MOV R10,qword ptr [RAX + R10*0x8] MOV dword ptr [R10 + RSI*0x4],R9D INC RSI CMP RCX,RSI JNZ 0x001761a6 LAB_001761bd: MOV RAX,qword ptr [RDI + 0x30] MOVSXD RCX,dword ptr [RDI] MOV byte ptr [RAX + RCX*0x1],R8B INC dword ptr [RDI] POP RAX RET LAB_001761cc: LEA RDI,[0x1f1de1] LEA RDX,[0x1e92a1] LEA RCX,[0x1f2425] MOV ESI,0x655 XOR EAX,EAX CALL 0x0011bed0
/* common_batch_add(llama_batch&, int, int, std::vector<int, std::allocator<int> > const&, bool) */ int8 common_batch_add(llama_batch *param_1,int param_2,int param_3,vector *param_4,bool param_5) { long lVar1; long lVar2; int8 in_RAX; long lVar3; long lVar4; lVar1 = *(long *)(param_1 + 0x28); if (*(long *)(lVar1 + (long)*(int *)param_1 * 8) != 0) { *(int *)(*(long *)(param_1 + 8) + (long)*(int *)param_1 * 4) = param_2; *(int *)(*(long *)(param_1 + 0x18) + (long)*(int *)param_1 * 4) = param_3; lVar2 = *(long *)param_4; lVar4 = *(long *)(param_4 + 8); lVar3 = lVar4 - lVar2 >> 2; *(int *)(*(long *)(param_1 + 0x20) + (long)*(int *)param_1 * 4) = (int)lVar3; if (lVar4 != lVar2) { lVar4 = 0; do { *(int4 *)(*(long *)(lVar1 + (long)*(int *)param_1 * 8) + lVar4 * 4) = *(int4 *)(lVar2 + lVar4 * 4); lVar4 = lVar4 + 1; } while (lVar3 + (ulong)(lVar3 == 0) != lVar4); } *(bool *)(*(long *)(param_1 + 0x30) + (long)*(int *)param_1) = param_5; *(int *)param_1 = *(int *)param_1 + 1; return in_RAX; } /* WARNING: Subroutine does not return */ ggml_abort("/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/common.cpp",0x655, "GGML_ASSERT(%s) failed", "batch.seq_id[batch.n_tokens] && \"llama_batch size exceeded\""); }
20,530
POINTonE2_Uncompress_Z
corpus-core[P]colibri-stateless/build_O3/_deps/blst-src/src/e2.c
static BLST_ERROR POINTonE2_Uncompress_Z(POINTonE2_affine *out, const unsigned char in[96]) { unsigned char in0 = in[0]; limb_t sgn0_pty; if ((in0 & 0x80) == 0) /* compressed bit */ return BLST_BAD_ENCODING; if (in0 & 0x40) { /* infinity bit */ if (byte_is_zero(in0 & 0x3f) & bytes_are_zero(in+1, 95)) { vec_zero(out, sizeof(*out)); return BLST_SUCCESS; } else { return BLST_BAD_ENCODING; } } sgn0_pty = POINTonE2_Uncompress_BE(out, in); if (sgn0_pty > 3) return (BLST_ERROR)(0 - sgn0_pty); /* POINT_NOT_ON_CURVE */ sgn0_pty >>= 1; /* skip over parity bit */ sgn0_pty ^= (in0 & 0x20) >> 5; cneg_fp2(out->Y, out->Y, sgn0_pty); return BLST_SUCCESS; }
O3
c
POINTonE2_Uncompress_Z: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0xf8, %rsp movzbl (%rsi), %r14d movl $0x1, %r12d testb %r14b, %r14b jns 0x5cbfc movq %rdi, %rbx testb $0x40, %r14b jne 0x5cbad leaq -0xb8(%rbp), %r15 movl $0x2f, %eax xorl %ecx, %ecx movq %rsi, %rdx shlq $0x8, %rcx movzbl (%rdx), %edi incq %rdx orq %rdi, %rcx movq %rax, %rdi andq $-0x8, %rdi movq %rcx, -0xb8(%rbp,%rdi) addq $-0x1, %rax jb 0x5c9ae addq $0x30, %rsi movl $0x2f, %eax xorl %ecx, %ecx shlq $0x8, %rcx movzbl (%rsi), %edx incq %rsi orq %rdx, %rcx movq %rax, %rdx andq $-0x8, %rdx movq %rcx, -0xe8(%rbp,%rdx) addq $-0x1, %rax jb 0x5c9db andb $0x1f, -0x89(%rbp) leaq 0x302fd(%rip), %rdx # 0x8cd08 leaq 0x3028e(%rip), %rcx # 0x8cca0 leaq -0x120(%rbp), %r12 movq %r12, %rdi movq %r15, %rsi callq 0x6f640 movl $0x30, %edx movq %r12, %rdi movq %r15, %rsi callq 0x70980 movq $-0x1, %r12 testq %rax, %rax je 0x5cbf9 leaq 0x302bd(%rip), %rdx # 0x8cd08 leaq 0x3024e(%rip), %rcx # 0x8cca0 leaq -0x120(%rbp), %r13 leaq -0xe8(%rbp), %r15 movq %r13, %rdi movq %r15, %rsi callq 0x6f640 movl $0x30, %edx movq %r13, %rdi movq %r15, %rsi callq 0x70980 testq %rax, %rax je 0x5cbf9 movabsq $-0x760c000300030003, %r15 # imm = 0x89F3FFFCFFFCFFFD leaq 0x3048b(%rip), %rdx # 0x8cf20 leaq 0x30204(%rip), %r13 # 0x8cca0 leaq -0xe8(%rbp), %r12 movq %r12, %rdi movq %r12, %rsi movq %r13, %rcx movq %r15, %r8 callq 0x74ea0 leaq -0xb8(%rbp), %rdi movq %rdi, %rsi leaq 0x3045b(%rip), %rdx # 0x8cf20 movq %r13, %rcx movq %r15, %r8 callq 0x74ea0 leaq -0x88(%rbp), %r15 movq %r15, %rdi movq %r12, %rsi movq %r13, %rdx movabsq $-0x760c000300030003, %rcx # imm = 0x89F3FFFCFFFCFFFD callq 0x73ce0 movq %r15, %rdi movq %r15, %rsi movq %r12, %rdx movabsq $-0x760c000300030003, %r12 # imm = 0x89F3FFFCFFFCFFFD movq %r13, %rcx movq %r12, %r8 callq 0x73ba0 leaq 0x310ac(%rip), %rdx # 0x8dbc0 movq %r15, %rdi movq %r15, %rsi movq %r13, %rcx callq 0x6f720 movq %r15, %rdi movq %r15, %rsi callq 0x623c2 testq %rax, %rax je 0x5cbf2 leaq -0xe8(%rbp), %rsi movl $0xc0, %edx movq %rbx, %rdi callq 0x22090 leaq 0x60(%rbx), %r15 leaq 0x3014b(%rip), %rsi # 0x8cca0 movq %r15, %rdi movq %r12, %rdx callq 0x74d60 movq %rax, %r12 cmpq $0x4, %rax jae 0x5cbf9 shrq %r12 shrl $0x5, %r14d andl $0x1, %r14d xorq %r12, %r14 leaq 0x3011e(%rip), %r12 # 0x8cca0 movq %r15, %rdi movq %r15, %rsi movq %r14, %rdx movq %r12, %rcx callq 0x6fcc0 addq $0x90, %rbx movq %rbx, %rdi movq %rbx, %rsi movq %r14, %rdx movq %r12, %rcx callq 0x6fcc0 jmp 0x5cbed andl $0x3f, %r14d decq %r14 shrq $0x3f, %r14 movl $0x1, %ecx xorl %eax, %eax orb (%rsi,%rcx), %al incq %rcx cmpq $0x60, %rcx jne 0x5cbbf movzbl %al, %eax decq %rax shrq $0x3f, %rax testq %r14, %rax je 0x5cbfc xorl %eax, %eax movq $0x0, (%rbx,%rax,8) incq %rax cmpq $0x18, %rax jne 0x5cbdc xorl %r12d, %r12d jmp 0x5cbfc movq $-0x2, %r12 negl %r12d movl %r12d, %eax addq $0xf8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
POINTonE2_Uncompress_Z: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx sub rsp, 0F8h movzx r14d, byte ptr [rsi] mov r12d, 1 test r14b, r14b jns loc_5CBFC mov rbx, rdi test r14b, 40h jnz loc_5CBAD lea r15, [rbp+var_B8] mov eax, 2Fh ; '/' xor ecx, ecx mov rdx, rsi loc_5C9AE: shl rcx, 8 movzx edi, byte ptr [rdx] inc rdx or rcx, rdi mov rdi, rax and rdi, 0FFFFFFFFFFFFFFF8h mov [rbp+rdi+var_B8], rcx add rax, 0FFFFFFFFFFFFFFFFh jb short loc_5C9AE add rsi, 30h ; '0' mov eax, 2Fh ; '/' xor ecx, ecx loc_5C9DB: shl rcx, 8 movzx edx, byte ptr [rsi] inc rsi or rcx, rdx mov rdx, rax and rdx, 0FFFFFFFFFFFFFFF8h mov [rbp+rdx+var_E8], rcx add rax, 0FFFFFFFFFFFFFFFFh jb short loc_5C9DB and [rbp+var_89], 1Fh lea rdx, unk_8CD08 lea rcx, BLS12_381_P lea r12, [rbp+var_120] mov rdi, r12 mov rsi, r15 call add_mod_384 mov edx, 30h ; '0' mov rdi, r12 mov rsi, r15 call vec_is_equal_16x mov r12, 0FFFFFFFFFFFFFFFFh test rax, rax jz loc_5CBF9 lea rdx, unk_8CD08 lea rcx, BLS12_381_P lea r13, [rbp+var_120] lea r15, [rbp+var_E8] mov rdi, r13 mov rsi, r15 call add_mod_384 mov edx, 30h ; '0' mov rdi, r13 mov rsi, r15 call vec_is_equal_16x test rax, rax jz loc_5CBF9 mov r15, 89F3FFFCFFFCFFFDh lea rdx, BLS12_381_RR lea r13, BLS12_381_P lea r12, [rbp+var_E8] mov rdi, r12 mov rsi, r12 mov rcx, r13 mov r8, r15 call mul_mont_384 lea rdi, [rbp+var_B8] mov rsi, rdi lea rdx, BLS12_381_RR mov rcx, r13 mov r8, r15 call mul_mont_384 lea r15, [rbp+var_88] mov rdi, r15 mov rsi, r12 mov rdx, r13 mov rcx, 89F3FFFCFFFCFFFDh call sqr_mont_384x mov rdi, r15 mov rsi, r15 mov rdx, r12 mov r12, 89F3FFFCFFFCFFFDh mov rcx, r13 mov r8, r12 call mul_mont_384x lea rdx, B_E2 mov rdi, r15 mov rsi, r15 mov rcx, r13 call add_mod_384x mov rdi, r15 mov rsi, r15 call sqrt_fp2 test rax, rax jz loc_5CBF2 lea rsi, [rbp+var_E8] mov edx, 0C0h mov rdi, rbx call _memcpy lea r15, [rbx+60h] lea rsi, BLS12_381_P mov rdi, r15 mov rdx, r12 call sgn0_pty_mont_384x mov r12, rax cmp rax, 4 jnb loc_5CBF9 shr r12, 1 shr r14d, 5 and r14d, 1 xor r14, r12 lea r12, BLS12_381_P mov rdi, r15 mov rsi, r15 mov rdx, r14 mov rcx, r12 call cneg_mod_384 add rbx, 90h mov rdi, rbx mov rsi, rbx mov rdx, r14 mov rcx, r12 call cneg_mod_384 jmp short loc_5CBED loc_5CBAD: and r14d, 3Fh dec r14 shr r14, 3Fh mov ecx, 1 xor eax, eax loc_5CBBF: or al, [rsi+rcx] inc rcx cmp rcx, 60h ; '`' jnz short loc_5CBBF movzx eax, al dec rax shr rax, 3Fh test rax, r14 jz short loc_5CBFC xor eax, eax loc_5CBDC: mov qword ptr [rbx+rax*8], 0 inc rax cmp rax, 18h jnz short loc_5CBDC loc_5CBED: xor r12d, r12d jmp short loc_5CBFC loc_5CBF2: mov r12, 0FFFFFFFFFFFFFFFEh loc_5CBF9: neg r12d loc_5CBFC: mov eax, r12d add rsp, 0F8h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
long long POINTonE2_Uncompress_Z(long long a1, unsigned __int8 *a2) { unsigned int v2; // r14d unsigned int v3; // r12d long long v5; // rax long long v6; // rcx unsigned __int8 *v7; // rdx long long v8; // rdi bool v9; // cf unsigned __int8 *v10; // rsi long long v11; // rax long long v12; // rcx long long v13; // rdx int v14; // r12d unsigned long long v15; // rax unsigned long long v16; // r14 unsigned long long v17; // r14 long long v18; // rcx unsigned __int8 v19; // al long long i; // rax _BYTE v22[56]; // [rsp+0h] [rbp-120h] BYREF _QWORD v23[6]; // [rsp+38h] [rbp-E8h] BYREF _QWORD v24[5]; // [rsp+68h] [rbp-B8h] BYREF char v25; // [rsp+97h] [rbp-89h] _BYTE v26[136]; // [rsp+98h] [rbp-88h] BYREF v2 = *a2; v3 = 1; if ( (v2 & 0x80u) != 0 ) { if ( (v2 & 0x40) == 0 ) { v5 = 47LL; v6 = 0LL; v7 = a2; do { v8 = *v7++; v6 = v8 | (v6 << 8); *(_QWORD *)((char *)v24 + (v5 & 0xFFFFFFFFFFFFFFF8LL)) = v6; v9 = v5-- != 0; } while ( v9 ); v10 = a2 + 48; v11 = 47LL; v12 = 0LL; do { v13 = *v10++; v12 = v13 | (v12 << 8); *(_QWORD *)((char *)v23 + (v11 & 0xFFFFFFFFFFFFFFF8LL)) = v12; v9 = v11-- != 0; } while ( v9 ); v25 &= 0x1Fu; add_mod_384(v22, v24, &unk_8CD08, &BLS12_381_P); v14 = -1; if ( vec_is_equal_16x(v22, v24, 48LL) ) { add_mod_384(v22, v23, &unk_8CD08, &BLS12_381_P); if ( vec_is_equal_16x(v22, v23, 48LL) ) { mul_mont_384(v23, v23, &BLS12_381_RR, &BLS12_381_P, 0x89F3FFFCFFFCFFFDLL); mul_mont_384(v24, v24, &BLS12_381_RR, &BLS12_381_P, 0x89F3FFFCFFFCFFFDLL); sqr_mont_384x(v26, v23, &BLS12_381_P, 0x89F3FFFCFFFCFFFDLL); mul_mont_384x(v26, v26, v23, &BLS12_381_P, 0x89F3FFFCFFFCFFFDLL); add_mod_384x(v26, v26, &B_E2, &BLS12_381_P); if ( sqrt_fp2(v26, v26) ) { memcpy(a1); v15 = sgn0_pty_mont_384x(a1 + 96, &BLS12_381_P, 0x89F3FFFCFFFCFFFDLL); v14 = v15; if ( v15 < 4 ) { v16 = (v15 >> 1) ^ (v2 >> 5) & 1; cneg_mod_384(a1 + 96, a1 + 96, v16, &BLS12_381_P); cneg_mod_384(a1 + 144, a1 + 144, v16, &BLS12_381_P); return 0; } } else { v14 = -2; } } } return (unsigned int)-v14; } v17 = ((unsigned long long)(v2 & 0x3F) - 1) >> 63; v18 = 1LL; v19 = 0; do v19 |= a2[v18++]; while ( v18 != 96 ); if ( (v17 & (((unsigned long long)v19 - 1) >> 63)) != 0 ) { for ( i = 0LL; i != 24; ++i ) *(_QWORD *)(a1 + 8 * i) = 0LL; return 0; } } return v3; }
POINTonE2_Uncompress_Z: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0xf8 MOVZX R14D,byte ptr [RSI] MOV R12D,0x1 TEST R14B,R14B JNS 0x0015cbfc MOV RBX,RDI TEST R14B,0x40 JNZ 0x0015cbad LEA R15,[RBP + -0xb8] MOV EAX,0x2f XOR ECX,ECX MOV RDX,RSI LAB_0015c9ae: SHL RCX,0x8 MOVZX EDI,byte ptr [RDX] INC RDX OR RCX,RDI MOV RDI,RAX AND RDI,-0x8 MOV qword ptr [RBP + RDI*0x1 + -0xb8],RCX ADD RAX,-0x1 JC 0x0015c9ae ADD RSI,0x30 MOV EAX,0x2f XOR ECX,ECX LAB_0015c9db: SHL RCX,0x8 MOVZX EDX,byte ptr [RSI] INC RSI OR RCX,RDX MOV RDX,RAX AND RDX,-0x8 MOV qword ptr [RBP + RDX*0x1 + -0xe8],RCX ADD RAX,-0x1 JC 0x0015c9db AND byte ptr [RBP + -0x89],0x1f LEA RDX,[0x18cd08] LEA RCX,[0x18cca0] LEA R12,[RBP + -0x120] MOV RDI,R12 MOV RSI,R15 CALL 0x0016f640 MOV EDX,0x30 MOV RDI,R12 MOV RSI,R15 CALL 0x00170980 MOV R12,-0x1 TEST RAX,RAX JZ 0x0015cbf9 LEA RDX,[0x18cd08] LEA RCX,[0x18cca0] LEA R13,[RBP + -0x120] LEA R15,[RBP + -0xe8] MOV RDI,R13 MOV RSI,R15 CALL 0x0016f640 MOV EDX,0x30 MOV RDI,R13 MOV RSI,R15 CALL 0x00170980 TEST RAX,RAX JZ 0x0015cbf9 MOV R15,-0x760c000300030003 LEA RDX,[0x18cf20] LEA R13,[0x18cca0] LEA R12,[RBP + -0xe8] MOV RDI,R12 MOV RSI,R12 MOV RCX,R13 MOV R8,R15 CALL 0x00174ea0 LEA RDI,[RBP + -0xb8] MOV RSI,RDI LEA RDX,[0x18cf20] MOV RCX,R13 MOV R8,R15 CALL 0x00174ea0 LEA R15,[RBP + -0x88] MOV RDI,R15 MOV RSI,R12 MOV RDX,R13 MOV RCX,-0x760c000300030003 CALL 0x00173ce0 MOV RDI,R15 MOV RSI,R15 MOV RDX,R12 MOV R12,-0x760c000300030003 MOV RCX,R13 MOV R8,R12 CALL 0x00173ba0 LEA RDX,[0x18dbc0] MOV RDI,R15 MOV RSI,R15 MOV RCX,R13 CALL 0x0016f720 MOV RDI,R15 MOV RSI,R15 CALL 0x001623c2 TEST RAX,RAX JZ 0x0015cbf2 LEA RSI,[RBP + -0xe8] MOV EDX,0xc0 MOV RDI,RBX CALL 0x00122090 LEA R15,[RBX + 0x60] LEA RSI,[0x18cca0] MOV RDI,R15 MOV RDX,R12 CALL 0x00174d60 MOV R12,RAX CMP RAX,0x4 JNC 0x0015cbf9 SHR R12,0x1 SHR R14D,0x5 AND R14D,0x1 XOR R14,R12 LEA R12,[0x18cca0] MOV RDI,R15 MOV RSI,R15 MOV RDX,R14 MOV RCX,R12 CALL 0x0016fcc0 ADD RBX,0x90 MOV RDI,RBX MOV RSI,RBX MOV RDX,R14 MOV RCX,R12 CALL 0x0016fcc0 JMP 0x0015cbed LAB_0015cbad: AND R14D,0x3f DEC R14 SHR R14,0x3f MOV ECX,0x1 XOR EAX,EAX LAB_0015cbbf: OR AL,byte ptr [RSI + RCX*0x1] INC RCX CMP RCX,0x60 JNZ 0x0015cbbf MOVZX EAX,AL DEC RAX SHR RAX,0x3f TEST RAX,R14 JZ 0x0015cbfc XOR EAX,EAX LAB_0015cbdc: MOV qword ptr [RBX + RAX*0x8],0x0 INC RAX CMP RAX,0x18 JNZ 0x0015cbdc LAB_0015cbed: XOR R12D,R12D JMP 0x0015cbfc LAB_0015cbf2: MOV R12,-0x2 LAB_0015cbf9: NEG R12D LAB_0015cbfc: MOV EAX,R12D ADD RSP,0xf8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
int POINTonE2_Uncompress_Z(void *param_1,byte *param_2) { byte bVar1; byte bVar2; ulong uVar3; long lVar4; ulong uVar5; byte *pbVar6; int iVar7; bool bVar8; int1 local_128 [56]; ulong local_f0 [6]; ulong local_c0 [5]; byte local_91; int1 local_90 [96]; bVar1 = *param_2; if (-1 < (char)bVar1) { return 1; } if ((bVar1 & 0x40) == 0) { uVar3 = 0x2f; uVar5 = 0; pbVar6 = param_2; do { bVar2 = *pbVar6; pbVar6 = pbVar6 + 1; uVar5 = uVar5 << 8 | (ulong)bVar2; *(ulong *)((long)local_c0 + (uVar3 & 0xfffffffffffffff8)) = uVar5; bVar8 = uVar3 != 0; uVar3 = uVar3 - 1; } while (bVar8); param_2 = param_2 + 0x30; uVar3 = 0x2f; uVar5 = 0; do { bVar2 = *param_2; param_2 = param_2 + 1; uVar5 = uVar5 << 8 | (ulong)bVar2; *(ulong *)((long)local_f0 + (uVar3 & 0xfffffffffffffff8)) = uVar5; bVar8 = uVar3 != 0; uVar3 = uVar3 - 1; } while (bVar8); local_91 = local_91 & 0x1f; add_mod_384(local_128,local_c0,&DAT_0018cd08,BLS12_381_P); lVar4 = vec_is_equal_16x(local_128,local_c0,0x30); uVar3 = 0xffffffffffffffff; if (lVar4 != 0) { add_mod_384(local_128,local_f0,&DAT_0018cd08,BLS12_381_P); lVar4 = vec_is_equal_16x(local_128,local_f0,0x30); if (lVar4 != 0) { mul_mont_384(local_f0,local_f0,BLS12_381_RR,BLS12_381_P,0x89f3fffcfffcfffd); mul_mont_384(local_c0,local_c0,BLS12_381_RR,BLS12_381_P,0x89f3fffcfffcfffd); sqr_mont_384x(local_90,local_f0,BLS12_381_P,0x89f3fffcfffcfffd); mul_mont_384x(local_90,local_90,local_f0,BLS12_381_P,0x89f3fffcfffcfffd); add_mod_384x(local_90,local_90,B_E2,BLS12_381_P); lVar4 = sqrt_fp2(local_90,local_90); if (lVar4 == 0) { uVar3 = 0xfffffffffffffffe; } else { memcpy(param_1,local_f0,0xc0); lVar4 = (long)param_1 + 0x60; uVar3 = sgn0_pty_mont_384x(lVar4,BLS12_381_P,0x89f3fffcfffcfffd); if (uVar3 < 4) { uVar3 = (ulong)(bVar1 >> 5 & 1) ^ uVar3 >> 1; cneg_mod_384(lVar4,lVar4,uVar3,BLS12_381_P); cneg_mod_384((long)param_1 + 0x90,(long)param_1 + 0x90,uVar3,BLS12_381_P); goto LAB_0015cbed; } } } } iVar7 = -(int)uVar3; } else { lVar4 = 1; bVar2 = 0; do { bVar2 = bVar2 | param_2[lVar4]; lVar4 = lVar4 + 1; } while (lVar4 != 0x60); if (-1 < (long)((ulong)bVar2 - 1 & (ulong)(bVar1 & 0x3f) - 1)) { return 1; } lVar4 = 0; do { *(int8 *)((long)param_1 + lVar4 * 8) = 0; lVar4 = lVar4 + 1; } while (lVar4 != 0x18); LAB_0015cbed: iVar7 = 0; } return iVar7; }
20,531
my_numchars_mb
eloqsql/strings/ctype-mb.c
size_t my_numchars_mb(CHARSET_INFO *cs __attribute__((unused)), const char *pos, const char *end) { register size_t count= 0; while (pos < end) { uint mb_len; pos+= (mb_len= my_ismbchar(cs,pos,end)) ? mb_len : 1; count++; } return count; }
O0
c
my_numchars_mb: pushq %rbp movq %rsp, %rbp subq $0x30, %rsp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq %rdx, -0x18(%rbp) movq $0x0, -0x20(%rbp) movq -0x10(%rbp), %rax cmpq -0x18(%rbp), %rax jae 0x4660f movq -0x8(%rbp), %rdi movq -0x10(%rbp), %rsi movq -0x18(%rbp), %rdx callq 0x45ad0 movl %eax, -0x24(%rbp) cmpl $0x0, %eax je 0x465e7 movl -0x24(%rbp), %eax movl %eax, -0x28(%rbp) jmp 0x465f1 movl $0x1, %eax movl %eax, -0x28(%rbp) jmp 0x465f1 movl -0x28(%rbp), %ecx movq -0x10(%rbp), %rax movl %ecx, %ecx addq %rcx, %rax movq %rax, -0x10(%rbp) movq -0x20(%rbp), %rax addq $0x1, %rax movq %rax, -0x20(%rbp) jmp 0x465bc movq -0x20(%rbp), %rax addq $0x30, %rsp popq %rbp retq nopl (%rax)
my_numchars_mb: push rbp mov rbp, rsp sub rsp, 30h mov [rbp+var_8], rdi mov [rbp+var_10], rsi mov [rbp+var_18], rdx mov [rbp+var_20], 0 loc_465BC: mov rax, [rbp+var_10] cmp rax, [rbp+var_18] jnb short loc_4660F mov rdi, [rbp+var_8] mov rsi, [rbp+var_10] mov rdx, [rbp+var_18] call my_ismbchar_0 mov [rbp+var_24], eax cmp eax, 0 jz short loc_465E7 mov eax, [rbp+var_24] mov [rbp+var_28], eax jmp short loc_465F1 loc_465E7: mov eax, 1 mov [rbp+var_28], eax jmp short $+2 loc_465F1: mov ecx, [rbp+var_28] mov rax, [rbp+var_10] mov ecx, ecx add rax, rcx mov [rbp+var_10], rax mov rax, [rbp+var_20] add rax, 1 mov [rbp+var_20], rax jmp short loc_465BC loc_4660F: mov rax, [rbp+var_20] add rsp, 30h pop rbp retn
long long my_numchars_mb(long long a1, unsigned long long a2, unsigned long long a3) { unsigned int v4; // [rsp+8h] [rbp-28h] unsigned int v5; // [rsp+Ch] [rbp-24h] long long v6; // [rsp+10h] [rbp-20h] v6 = 0LL; while ( a2 < a3 ) { v5 = my_ismbchar_0(a1, a2, a3); if ( v5 ) v4 = v5; else v4 = 1; a2 += v4; ++v6; } return v6; }
my_numchars_mb: PUSH RBP MOV RBP,RSP SUB RSP,0x30 MOV qword ptr [RBP + -0x8],RDI MOV qword ptr [RBP + -0x10],RSI MOV qword ptr [RBP + -0x18],RDX MOV qword ptr [RBP + -0x20],0x0 LAB_001465bc: MOV RAX,qword ptr [RBP + -0x10] CMP RAX,qword ptr [RBP + -0x18] JNC 0x0014660f MOV RDI,qword ptr [RBP + -0x8] MOV RSI,qword ptr [RBP + -0x10] MOV RDX,qword ptr [RBP + -0x18] CALL 0x00145ad0 MOV dword ptr [RBP + -0x24],EAX CMP EAX,0x0 JZ 0x001465e7 MOV EAX,dword ptr [RBP + -0x24] MOV dword ptr [RBP + -0x28],EAX JMP 0x001465f1 LAB_001465e7: MOV EAX,0x1 MOV dword ptr [RBP + -0x28],EAX JMP 0x001465f1 LAB_001465f1: MOV ECX,dword ptr [RBP + -0x28] MOV RAX,qword ptr [RBP + -0x10] MOV ECX,ECX ADD RAX,RCX MOV qword ptr [RBP + -0x10],RAX MOV RAX,qword ptr [RBP + -0x20] ADD RAX,0x1 MOV qword ptr [RBP + -0x20],RAX JMP 0x001465bc LAB_0014660f: MOV RAX,qword ptr [RBP + -0x20] ADD RSP,0x30 POP RBP RET
long my_numchars_mb(int8 param_1,ulong param_2,ulong param_3) { int4 local_30; int8 local_28; int8 local_18; local_28 = 0; for (local_18 = param_2; local_18 < param_3; local_18 = local_18 + local_30) { local_30 = my_ismbchar(param_1,local_18,param_3); if (local_30 == 0) { local_30 = 1; } local_28 = local_28 + 1; } return local_28; }
20,532
google::protobuf::Message::SetCachedSize(int) const
aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/message.cc
void Message::SetCachedSize(int /* size */) const { GOOGLE_LOG(FATAL) << "Message class \"" << GetDescriptor()->full_name() << "\" implements neither SetCachedSize() nor ByteSize(). " "Must implement one or the other."; }
O3
cpp
google::protobuf::Message::SetCachedSize(int) const: pushq %r14 pushq %rbx subq $0x48, %rsp movq %rdi, %rbx leaq 0x438dd(%rip), %rdx # 0xbb564 leaq 0x10(%rsp), %r14 movq %r14, %rdi movl $0x3, %esi movl $0xb9, %ecx callq 0x169ca leaq 0x43a77(%rip), %rsi # 0xbb71c movq %r14, %rdi callq 0x164c8 movq %rax, %r14 movq (%rbx), %rax movq %rbx, %rdi callq *0x80(%rax) movq 0x8(%rax), %rsi addq $0x20, %rsi movq %r14, %rdi callq 0x164da leaq 0x43a59(%rip), %rsi # 0xbb72c movq %rax, %rdi callq 0x164c8 leaq 0xf(%rsp), %rdi movq %rax, %rsi callq 0x165a2 leaq 0x10(%rsp), %rdi callq 0x169e8 addq $0x48, %rsp popq %rbx popq %r14 retq jmp 0x77cfc movq %rax, %rbx leaq 0x10(%rsp), %rdi callq 0x169e8 movq %rbx, %rdi callq 0xf570 nop
_ZNK6google8protobuf7Message13SetCachedSizeEi: push r14 push rbx sub rsp, 48h mov rbx, rdi lea rdx, aWorkspaceLlm4b_13; "/workspace/llm4binary/github2025/aimrt_"... lea r14, [rsp+58h+var_48] mov rdi, r14 mov esi, 3 mov ecx, 0B9h call _ZN6google8protobuf8internal10LogMessageC2ENS0_8LogLevelEPKci; google::protobuf::internal::LogMessage::LogMessage(google::protobuf::LogLevel,char const*,int) lea rsi, aMessageClass; "Message class \"" mov rdi, r14 call _ZN6google8protobuf8internal10LogMessagelsEPKc; google::protobuf::internal::LogMessage::operator<<(char const*) mov r14, rax mov rax, [rbx] mov rdi, rbx call qword ptr [rax+80h] mov rsi, [rax+8] add rsi, 20h ; ' ' mov rdi, r14 call _ZN6google8protobuf8internal10LogMessagelsERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; google::protobuf::internal::LogMessage::operator<<(std::string const&) lea rsi, aImplementsNeit; "\" implements neither SetCachedSize() n"... mov rdi, rax call _ZN6google8protobuf8internal10LogMessagelsEPKc; google::protobuf::internal::LogMessage::operator<<(char const*) lea rdi, [rsp+58h+var_49] mov rsi, rax call _ZN6google8protobuf8internal11LogFinisheraSERNS1_10LogMessageE; google::protobuf::internal::LogFinisher::operator=(google::protobuf::internal::LogMessage &) lea rdi, [rsp+58h+var_48]; this call _ZN6google8protobuf8internal10LogMessageD2Ev; google::protobuf::internal::LogMessage::~LogMessage() add rsp, 48h pop rbx pop r14 retn jmp short $+2 loc_77CFC: mov rbx, rax lea rdi, [rsp+arg_8]; this call _ZN6google8protobuf8internal10LogMessageD2Ev; google::protobuf::internal::LogMessage::~LogMessage() mov rdi, rbx call __Unwind_Resume
void google::protobuf::Message::SetCachedSize(google::protobuf::Message *this) { long long v1; // r14 long long v2; // rax long long v3; // rax google::protobuf::internal::LogMessage *v4; // rax char v5; // [rsp+Fh] [rbp-49h] BYREF _BYTE v6[72]; // [rsp+10h] [rbp-48h] BYREF google::protobuf::internal::LogMessage::LogMessage( (long long)v6, 3, (long long)"/workspace/llm4binary/github2025/aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/message.cc", 185); v1 = google::protobuf::internal::LogMessage::operator<<((long long)v6, (long long)"Message class \""); v2 = (*(long long ( **)(google::protobuf::Message *))(*(_QWORD *)this + 128LL))(this); v3 = google::protobuf::internal::LogMessage::operator<<(v1, *(_QWORD *)(v2 + 8) + 32LL); v4 = (google::protobuf::internal::LogMessage *)google::protobuf::internal::LogMessage::operator<<( v3, (long long)"\" implements neither SetCachedSize() nor ByteSize(). Must " "implement one or the other."); google::protobuf::internal::LogFinisher::operator=((long long)&v5, v4); google::protobuf::internal::LogMessage::~LogMessage((google::protobuf::internal::LogMessage *)v6); }
SetCachedSize: PUSH R14 PUSH RBX SUB RSP,0x48 MOV RBX,RDI LEA RDX,[0x1bb564] LEA R14,[RSP + 0x10] MOV RDI,R14 MOV ESI,0x3 MOV ECX,0xb9 CALL 0x001169ca LAB_00177c9e: LEA RSI,[0x1bb71c] MOV RDI,R14 CALL 0x001164c8 MOV R14,RAX MOV RAX,qword ptr [RBX] MOV RDI,RBX CALL qword ptr [RAX + 0x80] MOV RSI,qword ptr [RAX + 0x8] ADD RSI,0x20 MOV RDI,R14 CALL 0x001164da LEA RSI,[0x1bb72c] MOV RDI,RAX CALL 0x001164c8 LAB_00177cdb: LEA RDI,[RSP + 0xf] MOV RSI,RAX CALL 0x001165a2 LAB_00177ce8: LEA RDI,[RSP + 0x10] CALL 0x001169e8 ADD RSP,0x48 POP RBX POP R14 RET
/* google::protobuf::Message::SetCachedSize(int) const */ void google::protobuf::Message::SetCachedSize(int param_1) { LogMessage *pLVar1; long lVar2; int4 in_register_0000003c; LogFinisher local_49; LogMessage local_48 [56]; internal::LogMessage::LogMessage (local_48,3, "/workspace/llm4binary/github2025/aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/message.cc" ,0xb9); /* try { // try from 00177c9e to 00177cda has its CatchHandler @ 00177cfc */ pLVar1 = (LogMessage *)internal::LogMessage::operator<<(local_48,"Message class \""); lVar2 = (**(code **)(*(long *)CONCAT44(in_register_0000003c,param_1) + 0x80)) ((long *)CONCAT44(in_register_0000003c,param_1)); pLVar1 = (LogMessage *) internal::LogMessage::operator<<(pLVar1,(string *)(*(long *)(lVar2 + 8) + 0x20)); pLVar1 = (LogMessage *) internal::LogMessage::operator<< (pLVar1, "\" implements neither SetCachedSize() nor ByteSize(). Must implement one or the other." ); /* try { // try from 00177cdb to 00177ce7 has its CatchHandler @ 00177cfa */ internal::LogFinisher::operator=(&local_49,pLVar1); internal::LogMessage::~LogMessage(local_48); return; }
20,533
ma_bitmap_unlock
eloqsql/storage/maria/ma_bitmap.c
void _ma_bitmap_unlock(MARIA_SHARE *share) { MARIA_FILE_BITMAP *bitmap= &share->bitmap; uint send_signal; DBUG_ENTER("_ma_bitmap_unlock"); if (!share->now_transactional) DBUG_VOID_RETURN; DBUG_ASSERT(bitmap->flush_all_requested > 0 && bitmap->non_flushable == 1); mysql_mutex_lock(&bitmap->bitmap_lock); bitmap->non_flushable= 0; _ma_bitmap_unpin_all(share); send_signal= bitmap->waiting_for_non_flushable; if (!--bitmap->flush_all_requested) send_signal|= bitmap->waiting_for_flush_all_requested; mysql_mutex_unlock(&bitmap->bitmap_lock); if (send_signal) mysql_cond_broadcast(&bitmap->bitmap_cond); DBUG_VOID_RETURN; }
O3
c
ma_bitmap_unlock: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %rbx pushq %rax cmpb $0x0, 0x7e7(%rdi) je 0x3fd45 movq %rdi, %rbx leaq 0xa98(%rdi), %r14 cmpq $0x0, 0xad8(%rdi) jne 0x3fd50 movq %r14, %rdi callq 0x29220 movl $0x0, 0xa48(%rbx) movq %rbx, %rdi callq 0x3fd8d movl 0xa4c(%rbx), %r15d decl 0xa40(%rbx) jne 0x3fd07 orl 0xa44(%rbx), %r15d movq 0xad8(%rbx), %rdi testq %rdi, %rdi jne 0x3fd69 movq %r14, %rdi callq 0x291e0 testl %r15d, %r15d je 0x3fd45 movq 0xb10(%rbx), %rdi addq $0xae0, %rbx # imm = 0xAE0 testq %rdi, %rdi jne 0x3fd7b movq %rbx, %rdi addq $0x8, %rsp popq %rbx popq %r14 popq %r15 popq %rbp jmp 0x296f0 addq $0x8, %rsp popq %rbx popq %r14 popq %r15 popq %rbp retq leaq 0x997b6(%rip), %rsi # 0xd950d movq %r14, %rdi movl $0x279, %edx # imm = 0x279 callq 0x2eb8f jmp 0x3fcdf leaq 0x3462a0(%rip), %rax # 0x386010 movq (%rax), %rax callq *0x160(%rax) jmp 0x3fd13 leaq 0x34628e(%rip), %rax # 0x386010 movq (%rax), %rax callq *0x178(%rax) jmp 0x3fd33
_ma_bitmap_unlock: push rbp mov rbp, rsp push r15 push r14 push rbx push rax cmp byte ptr [rdi+7E7h], 0 jz loc_3FD45 mov rbx, rdi lea r14, [rdi+0A98h] cmp qword ptr [rdi+0AD8h], 0 jnz short loc_3FD50 mov rdi, r14 call _pthread_mutex_lock loc_3FCDF: mov dword ptr [rbx+0A48h], 0 mov rdi, rbx call _ma_bitmap_unpin_all mov r15d, [rbx+0A4Ch] dec dword ptr [rbx+0A40h] jnz short loc_3FD07 or r15d, [rbx+0A44h] loc_3FD07: mov rdi, [rbx+0AD8h] test rdi, rdi jnz short loc_3FD69 loc_3FD13: mov rdi, r14 call _pthread_mutex_unlock test r15d, r15d jz short loc_3FD45 mov rdi, [rbx+0B10h] add rbx, 0AE0h test rdi, rdi jnz short loc_3FD7B loc_3FD33: mov rdi, rbx add rsp, 8 pop rbx pop r14 pop r15 pop rbp jmp _pthread_cond_broadcast loc_3FD45: add rsp, 8 pop rbx pop r14 pop r15 pop rbp retn loc_3FD50: lea rsi, aWorkspaceLlm4b_2; "/workspace/llm4binary/github2025/eloqsq"... mov rdi, r14 mov edx, 279h call psi_mutex_lock jmp loc_3FCDF loc_3FD69: lea rax, PSI_server mov rax, [rax] call qword ptr [rax+160h] jmp short loc_3FD13 loc_3FD7B: lea rax, PSI_server mov rax, [rax] call qword ptr [rax+178h] jmp short loc_3FD33
long long ma_bitmap_unlock(long long a1) { long long v2; // r14 int v3; // r15d long long v5; // rdi long long result; // rax long long v7; // rdi long long v8; // rbx if ( *(_BYTE *)(a1 + 2023) ) { v2 = a1 + 2712; if ( *(_QWORD *)(a1 + 2776) ) psi_mutex_lock(a1 + 2712, (long long)"/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_bitmap.c", 0x279u); else pthread_mutex_lock(a1 + 2712); *(_DWORD *)(a1 + 2632) = 0; ma_bitmap_unpin_all(a1); v3 = *(_DWORD *)(a1 + 2636); if ( (*(_DWORD *)(a1 + 2624))-- == 1 ) v3 |= *(_DWORD *)(a1 + 2628); v5 = *(_QWORD *)(a1 + 2776); if ( v5 ) ((void ( *)(long long))PSI_server[44])(v5); result = pthread_mutex_unlock(v2); if ( v3 ) { v7 = *(_QWORD *)(a1 + 2832); v8 = a1 + 2784; if ( v7 ) ((void ( *)(long long))PSI_server[47])(v7); return pthread_cond_broadcast(v8); } } return result; }
_ma_bitmap_unlock: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH RBX PUSH RAX CMP byte ptr [RDI + 0x7e7],0x0 JZ 0x0013fd45 MOV RBX,RDI LEA R14,[RDI + 0xa98] CMP qword ptr [RDI + 0xad8],0x0 JNZ 0x0013fd50 MOV RDI,R14 CALL 0x00129220 LAB_0013fcdf: MOV dword ptr [RBX + 0xa48],0x0 MOV RDI,RBX CALL 0x0013fd8d MOV R15D,dword ptr [RBX + 0xa4c] DEC dword ptr [RBX + 0xa40] JNZ 0x0013fd07 OR R15D,dword ptr [RBX + 0xa44] LAB_0013fd07: MOV RDI,qword ptr [RBX + 0xad8] TEST RDI,RDI JNZ 0x0013fd69 LAB_0013fd13: MOV RDI,R14 CALL 0x001291e0 TEST R15D,R15D JZ 0x0013fd45 MOV RDI,qword ptr [RBX + 0xb10] ADD RBX,0xae0 TEST RDI,RDI JNZ 0x0013fd7b LAB_0013fd33: MOV RDI,RBX ADD RSP,0x8 POP RBX POP R14 POP R15 POP RBP JMP 0x001296f0 LAB_0013fd45: ADD RSP,0x8 POP RBX POP R14 POP R15 POP RBP RET LAB_0013fd50: LEA RSI,[0x1d950d] MOV RDI,R14 MOV EDX,0x279 CALL 0x0012eb8f JMP 0x0013fcdf LAB_0013fd69: LEA RAX,[0x486010] MOV RAX,qword ptr [RAX] CALL qword ptr [RAX + 0x160] JMP 0x0013fd13 LAB_0013fd7b: LEA RAX,[0x486010] MOV RAX,qword ptr [RAX] CALL qword ptr [RAX + 0x178] JMP 0x0013fd33
void _ma_bitmap_unlock(long param_1) { pthread_mutex_t *__mutex; int *piVar1; uint uVar2; if (*(char *)(param_1 + 0x7e7) != '\0') { __mutex = (pthread_mutex_t *)(param_1 + 0xa98); if (*(long *)(param_1 + 0xad8) == 0) { pthread_mutex_lock(__mutex); } else { psi_mutex_lock(__mutex,"/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_bitmap.c", 0x279); } *(int4 *)(param_1 + 0xa48) = 0; _ma_bitmap_unpin_all(param_1); uVar2 = *(uint *)(param_1 + 0xa4c); piVar1 = (int *)(param_1 + 0xa40); *piVar1 = *piVar1 + -1; if (*piVar1 == 0) { uVar2 = uVar2 | *(uint *)(param_1 + 0xa44); } if (*(long *)(param_1 + 0xad8) != 0) { (**(code **)(PSI_server + 0x160))(); } pthread_mutex_unlock(__mutex); if (uVar2 != 0) { if (*(long *)(param_1 + 0xb10) != 0) { (**(code **)(PSI_server + 0x178))(); } pthread_cond_broadcast((pthread_cond_t *)(param_1 + 0xae0)); return; } } return; }
20,534
get_charset_number_internal
eloqsql/mysys/charset.c
static uint get_charset_number_internal(const char *charset_name, uint cs_flags) { CHARSET_INFO **cs; for (cs= all_charsets; cs < all_charsets + array_elements(all_charsets); cs++) { if ( cs[0] && cs[0]->cs_name.str && (cs[0]->state & cs_flags) && !my_strcasecmp(&my_charset_latin1, cs[0]->cs_name.str, charset_name)) return cs[0]->number; } return 0; }
O3
c
get_charset_number_internal: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx pushq %rax movl %esi, %ebx movq %rdi, %r14 movq $-0x8, %r12 leaq 0x358767(%rip), %r13 # 0x3a62c0 leaq 0x308200(%rip), %r15 # 0x355d60 movq 0x8(%r13,%r12), %rax testq %rax, %rax je 0x4db8c movq 0x10(%rax), %rsi testq %rsi, %rsi je 0x4db8c testl %ebx, 0xc(%rax) je 0x4db8c movq 0xc0(%r15), %rax movq %r15, %rdi movq %r14, %rdx callq *0x40(%rax) testl %eax, %eax je 0x4dbaa addq $0x8, %r12 cmpq $0x3ff8, %r12 # imm = 0x3FF8 jb 0x4db60 xorl %eax, %eax addq $0x8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq movq 0x8(%r13,%r12), %rax movl (%rax), %eax jmp 0x4db9b
get_charset_number_internal: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx push rax mov ebx, esi mov r14, rdi mov r12, 0FFFFFFFFFFFFFFF8h lea r13, all_charsets lea r15, my_charset_latin1 loc_4DB60: mov rax, [r13+r12+8] test rax, rax jz short loc_4DB8C mov rsi, [rax+10h] test rsi, rsi jz short loc_4DB8C test [rax+0Ch], ebx jz short loc_4DB8C mov rax, [r15+0C0h] mov rdi, r15 mov rdx, r14 call qword ptr [rax+40h] test eax, eax jz short loc_4DBAA loc_4DB8C: add r12, 8 cmp r12, 3FF8h jb short loc_4DB60 xor eax, eax loc_4DB9B: add rsp, 8 pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn loc_4DBAA: mov rax, [r13+r12+8] mov eax, [rax] jmp short loc_4DB9B
long long get_charset_number_internal(long long a1, int a2) { long long v3; // r12 long long v4; // rax long long v5; // rsi v3 = 0x1FFFFFFFFFFFFFFFLL; while ( 1 ) { v4 = all_charsets[v3 + 1]; if ( v4 ) { v5 = *(_QWORD *)(v4 + 16); if ( v5 ) { if ( (a2 & *(_DWORD *)(v4 + 12)) != 0 && !(*(unsigned int ( **)(void *, long long, long long))(*((_QWORD *)&my_charset_latin1 + 24) + 64LL))( &my_charset_latin1, v5, a1) ) { break; } } } if ( (unsigned long long)++v3 >= 2047 ) return 0LL; } return *(unsigned int *)all_charsets[v3 + 1]; }
get_charset_number_internal: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX PUSH RAX MOV EBX,ESI MOV R14,RDI MOV R12,-0x8 LEA R13,[0x4a62c0] LEA R15,[0x455d60] LAB_0014db60: MOV RAX,qword ptr [R13 + R12*0x1 + 0x8] TEST RAX,RAX JZ 0x0014db8c MOV RSI,qword ptr [RAX + 0x10] TEST RSI,RSI JZ 0x0014db8c TEST dword ptr [RAX + 0xc],EBX JZ 0x0014db8c MOV RAX,qword ptr [R15 + 0xc0] MOV RDI,R15 MOV RDX,R14 CALL qword ptr [RAX + 0x40] TEST EAX,EAX JZ 0x0014dbaa LAB_0014db8c: ADD R12,0x8 CMP R12,0x3ff8 JC 0x0014db60 XOR EAX,EAX LAB_0014db9b: ADD RSP,0x8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET LAB_0014dbaa: MOV RAX,qword ptr [R13 + R12*0x1 + 0x8] MOV EAX,dword ptr [RAX] JMP 0x0014db9b
int4 get_charset_number_internal(int8 param_1,uint param_2) { long lVar1; int iVar2; ulong uVar3; uVar3 = 0xfffffffffffffff8; while ((((lVar1 = *(long *)((long)&DAT_004a62c8 + uVar3), lVar1 == 0 || (*(long *)(lVar1 + 0x10) == 0)) || ((*(uint *)(lVar1 + 0xc) & param_2) == 0)) || (iVar2 = (**(code **)(PTR_my_collation_8bit_simple_ci_handler_00455e20 + 0x40)) (&my_charset_latin1,*(long *)(lVar1 + 0x10),param_1), iVar2 != 0))) { uVar3 = uVar3 + 8; if (0x3ff7 < uVar3) { return 0; } } return **(int4 **)((long)&DAT_004a62c8 + uVar3); }
20,535
my_mb_wc_eucjpms
eloqsql/strings/ctype-eucjpms.c
static int my_mb_wc_eucjpms(CHARSET_INFO *cs __attribute__((unused)), my_wc_t *pwc, const uchar *s, const uchar *e) { int hi; if (s >= e) return MY_CS_TOOSMALL; if ((hi= s[0]) < 0x80) /* ASCII code set: [00..7F] -> [U+0000..U+007F] */ { *pwc= hi; return 1; } if (hi >= 0xA1 && hi <= 0xFE) /* JIS X 0208 code set: [A1..FE][A1..FE] */ { if (s + 2 > e) return MY_CS_TOOSMALL2; return (*pwc= jisx0208_eucjpms_to_unicode[(hi << 8) + s[1]]) ? 2 : (s[1] < 0xA1 || s[1] > 0xFE) ? MY_CS_ILSEQ : -2; } /* JIS-X-0201 HALF WIDTH KATAKANA: [8E][A1..DF] -> [U+FF61..U+FF9F] */ if (hi == 0x8E) { if (s + 2 > e) return MY_CS_TOOSMALL2; if (s[1] < 0xA1 || s[1] > 0xDF) return MY_CS_ILSEQ; *pwc= 0xFEC0 + s[1]; /* 0xFFC0 = 0xFF61 - 0xA1 */ return 2; } if (hi == 0x8F) /* JIS X 0212 code set: [8F][A1..FE][A1..FE] */ { if (s + 3 > e) return MY_CS_TOOSMALL3; return (*pwc= jisx0212_eucjpms_to_unicode[(((int) s[1]) << 8) + s[2]]) ? 3 : (s[1] < 0xA1 || s[1] > 0xFE || s[2] < 0xA1 || s[2] > 0xFE) ? MY_CS_ILSEQ : -3; } return MY_CS_ILSEQ; }
O0
c
my_mb_wc_eucjpms: pushq %rbp movq %rsp, %rbp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq %rdx, -0x20(%rbp) movq %rcx, -0x28(%rbp) movq -0x20(%rbp), %rax cmpq -0x28(%rbp), %rax jb 0xded6a movl $0xffffff9b, -0x4(%rbp) # imm = 0xFFFFFF9B jmp 0xdef86 movq -0x20(%rbp), %rax movzbl (%rax), %eax movl %eax, -0x2c(%rbp) cmpl $0x80, %eax jge 0xded92 movslq -0x2c(%rbp), %rcx movq -0x18(%rbp), %rax movq %rcx, (%rax) movl $0x1, -0x4(%rbp) jmp 0xdef86 cmpl $0xa1, -0x2c(%rbp) jl 0xdee41 cmpl $0xfe, -0x2c(%rbp) jg 0xdee41 movq -0x20(%rbp), %rax addq $0x2, %rax cmpq -0x28(%rbp), %rax jbe 0xdedc6 movl $0xffffff9a, -0x4(%rbp) # imm = 0xFFFFFF9A jmp 0xdef86 movl -0x2c(%rbp), %eax shll $0x8, %eax movq -0x20(%rbp), %rcx movzbl 0x1(%rcx), %ecx addl %ecx, %eax movslq %eax, %rcx leaq 0x1c2cc0(%rip), %rax # 0x2a1aa0 movzwl (%rax,%rcx,2), %eax movq -0x18(%rbp), %rcx movq %rax, (%rcx) cmpq $0x0, %rax je 0xdedfb movl $0x2, %eax movl %eax, -0x30(%rbp) jmp 0xdee36 movq -0x20(%rbp), %rax movzbl 0x1(%rax), %ecx movb $0x1, %al cmpl $0xa1, %ecx movb %al, -0x31(%rbp) jl 0xdee23 movq -0x20(%rbp), %rax movzbl 0x1(%rax), %eax cmpl $0xfe, %eax setg %al movb %al, -0x31(%rbp) movb -0x31(%rbp), %dl movl $0xfffffffe, %eax # imm = 0xFFFFFFFE xorl %ecx, %ecx testb $0x1, %dl cmovnel %ecx, %eax movl %eax, -0x30(%rbp) movl -0x30(%rbp), %eax movl %eax, -0x4(%rbp) jmp 0xdef86 cmpl $0x8e, -0x2c(%rbp) jne 0xdeeb1 movq -0x20(%rbp), %rax addq $0x2, %rax cmpq -0x28(%rbp), %rax jbe 0xdee64 movl $0xffffff9a, -0x4(%rbp) # imm = 0xFFFFFF9A jmp 0xdef86 movq -0x20(%rbp), %rax movzbl 0x1(%rax), %eax cmpl $0xa1, %eax jl 0xdee82 movq -0x20(%rbp), %rax movzbl 0x1(%rax), %eax cmpl $0xdf, %eax jle 0xdee8e movl $0x0, -0x4(%rbp) jmp 0xdef86 movq -0x20(%rbp), %rax movzbl 0x1(%rax), %eax addl $0xfec0, %eax # imm = 0xFEC0 movslq %eax, %rcx movq -0x18(%rbp), %rax movq %rcx, (%rax) movl $0x2, -0x4(%rbp) jmp 0xdef86 cmpl $0x8f, -0x2c(%rbp) jne 0xdef7f movq -0x20(%rbp), %rax addq $0x3, %rax cmpq -0x28(%rbp), %rax jbe 0xdeed8 movl $0xffffff99, -0x4(%rbp) # imm = 0xFFFFFF99 jmp 0xdef86 movq -0x20(%rbp), %rax movzbl 0x1(%rax), %eax shll $0x8, %eax movq -0x20(%rbp), %rcx movzbl 0x2(%rcx), %ecx addl %ecx, %eax movslq %eax, %rcx leaq 0x1e2ba9(%rip), %rax # 0x2c1aa0 movzwl (%rax,%rcx,2), %eax movq -0x18(%rbp), %rcx movq %rax, (%rcx) cmpq $0x0, %rax je 0xdef12 movl $0x3, %eax movl %eax, -0x38(%rbp) jmp 0xdef77 movq -0x20(%rbp), %rax movzbl 0x1(%rax), %ecx movb $0x1, %al cmpl $0xa1, %ecx movb %al, -0x39(%rbp) jl 0xdef64 movq -0x20(%rbp), %rax movzbl 0x1(%rax), %ecx movb $0x1, %al cmpl $0xfe, %ecx movb %al, -0x39(%rbp) jg 0xdef64 movq -0x20(%rbp), %rax movzbl 0x2(%rax), %ecx movb $0x1, %al cmpl $0xa1, %ecx movb %al, -0x39(%rbp) jl 0xdef64 movq -0x20(%rbp), %rax movzbl 0x2(%rax), %eax cmpl $0xfe, %eax setg %al movb %al, -0x39(%rbp) movb -0x39(%rbp), %dl movl $0xfffffffd, %eax # imm = 0xFFFFFFFD xorl %ecx, %ecx testb $0x1, %dl cmovnel %ecx, %eax movl %eax, -0x38(%rbp) movl -0x38(%rbp), %eax movl %eax, -0x4(%rbp) jmp 0xdef86 movl $0x0, -0x4(%rbp) movl -0x4(%rbp), %eax popq %rbp retq nopl (%rax,%rax)
my_mb_wc_eucjpms: push rbp mov rbp, rsp mov [rbp+var_10], rdi mov [rbp+var_18], rsi mov [rbp+var_20], rdx mov [rbp+var_28], rcx mov rax, [rbp+var_20] cmp rax, [rbp+var_28] jb short loc_DED6A mov [rbp+var_4], 0FFFFFF9Bh jmp loc_DEF86 loc_DED6A: mov rax, [rbp+var_20] movzx eax, byte ptr [rax] mov [rbp+var_2C], eax cmp eax, 80h jge short loc_DED92 movsxd rcx, [rbp+var_2C] mov rax, [rbp+var_18] mov [rax], rcx mov [rbp+var_4], 1 jmp loc_DEF86 loc_DED92: cmp [rbp+var_2C], 0A1h jl loc_DEE41 cmp [rbp+var_2C], 0FEh jg loc_DEE41 mov rax, [rbp+var_20] add rax, 2 cmp rax, [rbp+var_28] jbe short loc_DEDC6 mov [rbp+var_4], 0FFFFFF9Ah jmp loc_DEF86 loc_DEDC6: mov eax, [rbp+var_2C] shl eax, 8 mov rcx, [rbp+var_20] movzx ecx, byte ptr [rcx+1] add eax, ecx movsxd rcx, eax lea rax, jisx0208_eucjpms_to_unicode movzx eax, word ptr [rax+rcx*2] mov rcx, [rbp+var_18] mov [rcx], rax cmp rax, 0 jz short loc_DEDFB mov eax, 2 mov [rbp+var_30], eax jmp short loc_DEE36 loc_DEDFB: mov rax, [rbp+var_20] movzx ecx, byte ptr [rax+1] mov al, 1 cmp ecx, 0A1h mov [rbp+var_31], al jl short loc_DEE23 mov rax, [rbp+var_20] movzx eax, byte ptr [rax+1] cmp eax, 0FEh setnle al mov [rbp+var_31], al loc_DEE23: mov dl, [rbp+var_31] mov eax, 0FFFFFFFEh xor ecx, ecx test dl, 1 cmovnz eax, ecx mov [rbp+var_30], eax loc_DEE36: mov eax, [rbp+var_30] mov [rbp+var_4], eax jmp loc_DEF86 loc_DEE41: cmp [rbp+var_2C], 8Eh jnz short loc_DEEB1 mov rax, [rbp+var_20] add rax, 2 cmp rax, [rbp+var_28] jbe short loc_DEE64 mov [rbp+var_4], 0FFFFFF9Ah jmp loc_DEF86 loc_DEE64: mov rax, [rbp+var_20] movzx eax, byte ptr [rax+1] cmp eax, 0A1h jl short loc_DEE82 mov rax, [rbp+var_20] movzx eax, byte ptr [rax+1] cmp eax, 0DFh jle short loc_DEE8E loc_DEE82: mov [rbp+var_4], 0 jmp loc_DEF86 loc_DEE8E: mov rax, [rbp+var_20] movzx eax, byte ptr [rax+1] add eax, 0FEC0h movsxd rcx, eax mov rax, [rbp+var_18] mov [rax], rcx mov [rbp+var_4], 2 jmp loc_DEF86 loc_DEEB1: cmp [rbp+var_2C], 8Fh jnz loc_DEF7F mov rax, [rbp+var_20] add rax, 3 cmp rax, [rbp+var_28] jbe short loc_DEED8 mov [rbp+var_4], 0FFFFFF99h jmp loc_DEF86 loc_DEED8: mov rax, [rbp+var_20] movzx eax, byte ptr [rax+1] shl eax, 8 mov rcx, [rbp+var_20] movzx ecx, byte ptr [rcx+2] add eax, ecx movsxd rcx, eax lea rax, jisx0212_eucjpms_to_unicode movzx eax, word ptr [rax+rcx*2] mov rcx, [rbp+var_18] mov [rcx], rax cmp rax, 0 jz short loc_DEF12 mov eax, 3 mov [rbp+var_38], eax jmp short loc_DEF77 loc_DEF12: mov rax, [rbp+var_20] movzx ecx, byte ptr [rax+1] mov al, 1 cmp ecx, 0A1h mov [rbp+var_39], al jl short loc_DEF64 mov rax, [rbp+var_20] movzx ecx, byte ptr [rax+1] mov al, 1 cmp ecx, 0FEh mov [rbp+var_39], al jg short loc_DEF64 mov rax, [rbp+var_20] movzx ecx, byte ptr [rax+2] mov al, 1 cmp ecx, 0A1h mov [rbp+var_39], al jl short loc_DEF64 mov rax, [rbp+var_20] movzx eax, byte ptr [rax+2] cmp eax, 0FEh setnle al mov [rbp+var_39], al loc_DEF64: mov dl, [rbp+var_39] mov eax, 0FFFFFFFDh xor ecx, ecx test dl, 1 cmovnz eax, ecx mov [rbp+var_38], eax loc_DEF77: mov eax, [rbp+var_38] mov [rbp+var_4], eax jmp short loc_DEF86 loc_DEF7F: mov [rbp+var_4], 0 loc_DEF86: mov eax, [rbp+var_4] pop rbp retn
long long my_mb_wc_eucjpms(long long a1, _QWORD *a2, unsigned __int8 *a3, unsigned long long a4) { long long v4; // rax unsigned int v5; // eax long long v6; // rax unsigned int v7; // eax bool v9; // [rsp+1h] [rbp-39h] bool v11; // [rsp+9h] [rbp-31h] unsigned int v13; // [rsp+Eh] [rbp-2Ch] if ( (unsigned long long)a3 < a4 ) { v13 = *a3; if ( v13 >= 0x80 ) { if ( *a3 < 0xA1u || *a3 == 255 ) { if ( v13 == 142 ) { if ( (unsigned long long)(a3 + 2) <= a4 ) { if ( a3[1] >= 0xA1u && a3[1] <= 0xDFu ) { *a2 = a3[1] + 65216; return 2; } else { return 0; } } else { return (unsigned int)-102; } } else if ( v13 == 143 ) { if ( (unsigned long long)(a3 + 3) <= a4 ) { v6 = jisx0212_eucjpms_to_unicode[256 * a3[1] + a3[2]]; *a2 = v6; if ( v6 ) { return 3; } else { v9 = 1; if ( a3[1] >= 0xA1u ) { v9 = 1; if ( a3[1] != 255 ) { v9 = 1; if ( a3[2] >= 0xA1u ) v9 = a3[2] == 255; } } v7 = -3; if ( v9 ) v7 = 0; return v7; } } else { return (unsigned int)-103; } } else { return 0; } } else if ( (unsigned long long)(a3 + 2) <= a4 ) { v4 = jisx0208_eucjpms_to_unicode[a3[1] + (v13 << 8)]; *a2 = v4; if ( v4 ) { return 2; } else { v11 = 1; if ( a3[1] >= 0xA1u ) v11 = a3[1] == 255; v5 = -2; if ( v11 ) v5 = 0; return v5; } } else { return (unsigned int)-102; } } else { *a2 = *a3; return 1; } } else { return (unsigned int)-101; } }
my_mb_wc_eucjpms: PUSH RBP MOV RBP,RSP MOV qword ptr [RBP + -0x10],RDI MOV qword ptr [RBP + -0x18],RSI MOV qword ptr [RBP + -0x20],RDX MOV qword ptr [RBP + -0x28],RCX MOV RAX,qword ptr [RBP + -0x20] CMP RAX,qword ptr [RBP + -0x28] JC 0x001ded6a MOV dword ptr [RBP + -0x4],0xffffff9b JMP 0x001def86 LAB_001ded6a: MOV RAX,qword ptr [RBP + -0x20] MOVZX EAX,byte ptr [RAX] MOV dword ptr [RBP + -0x2c],EAX CMP EAX,0x80 JGE 0x001ded92 MOVSXD RCX,dword ptr [RBP + -0x2c] MOV RAX,qword ptr [RBP + -0x18] MOV qword ptr [RAX],RCX MOV dword ptr [RBP + -0x4],0x1 JMP 0x001def86 LAB_001ded92: CMP dword ptr [RBP + -0x2c],0xa1 JL 0x001dee41 CMP dword ptr [RBP + -0x2c],0xfe JG 0x001dee41 MOV RAX,qword ptr [RBP + -0x20] ADD RAX,0x2 CMP RAX,qword ptr [RBP + -0x28] JBE 0x001dedc6 MOV dword ptr [RBP + -0x4],0xffffff9a JMP 0x001def86 LAB_001dedc6: MOV EAX,dword ptr [RBP + -0x2c] SHL EAX,0x8 MOV RCX,qword ptr [RBP + -0x20] MOVZX ECX,byte ptr [RCX + 0x1] ADD EAX,ECX MOVSXD RCX,EAX LEA RAX,[0x3a1aa0] MOVZX EAX,word ptr [RAX + RCX*0x2] MOV RCX,qword ptr [RBP + -0x18] MOV qword ptr [RCX],RAX CMP RAX,0x0 JZ 0x001dedfb MOV EAX,0x2 MOV dword ptr [RBP + -0x30],EAX JMP 0x001dee36 LAB_001dedfb: MOV RAX,qword ptr [RBP + -0x20] MOVZX ECX,byte ptr [RAX + 0x1] MOV AL,0x1 CMP ECX,0xa1 MOV byte ptr [RBP + -0x31],AL JL 0x001dee23 MOV RAX,qword ptr [RBP + -0x20] MOVZX EAX,byte ptr [RAX + 0x1] CMP EAX,0xfe SETG AL MOV byte ptr [RBP + -0x31],AL LAB_001dee23: MOV DL,byte ptr [RBP + -0x31] MOV EAX,0xfffffffe XOR ECX,ECX TEST DL,0x1 CMOVNZ EAX,ECX MOV dword ptr [RBP + -0x30],EAX LAB_001dee36: MOV EAX,dword ptr [RBP + -0x30] MOV dword ptr [RBP + -0x4],EAX JMP 0x001def86 LAB_001dee41: CMP dword ptr [RBP + -0x2c],0x8e JNZ 0x001deeb1 MOV RAX,qword ptr [RBP + -0x20] ADD RAX,0x2 CMP RAX,qword ptr [RBP + -0x28] JBE 0x001dee64 MOV dword ptr [RBP + -0x4],0xffffff9a JMP 0x001def86 LAB_001dee64: MOV RAX,qword ptr [RBP + -0x20] MOVZX EAX,byte ptr [RAX + 0x1] CMP EAX,0xa1 JL 0x001dee82 MOV RAX,qword ptr [RBP + -0x20] MOVZX EAX,byte ptr [RAX + 0x1] CMP EAX,0xdf JLE 0x001dee8e LAB_001dee82: MOV dword ptr [RBP + -0x4],0x0 JMP 0x001def86 LAB_001dee8e: MOV RAX,qword ptr [RBP + -0x20] MOVZX EAX,byte ptr [RAX + 0x1] ADD EAX,0xfec0 MOVSXD RCX,EAX MOV RAX,qword ptr [RBP + -0x18] MOV qword ptr [RAX],RCX MOV dword ptr [RBP + -0x4],0x2 JMP 0x001def86 LAB_001deeb1: CMP dword ptr [RBP + -0x2c],0x8f JNZ 0x001def7f MOV RAX,qword ptr [RBP + -0x20] ADD RAX,0x3 CMP RAX,qword ptr [RBP + -0x28] JBE 0x001deed8 MOV dword ptr [RBP + -0x4],0xffffff99 JMP 0x001def86 LAB_001deed8: MOV RAX,qword ptr [RBP + -0x20] MOVZX EAX,byte ptr [RAX + 0x1] SHL EAX,0x8 MOV RCX,qword ptr [RBP + -0x20] MOVZX ECX,byte ptr [RCX + 0x2] ADD EAX,ECX MOVSXD RCX,EAX LEA RAX,[0x3c1aa0] MOVZX EAX,word ptr [RAX + RCX*0x2] MOV RCX,qword ptr [RBP + -0x18] MOV qword ptr [RCX],RAX CMP RAX,0x0 JZ 0x001def12 MOV EAX,0x3 MOV dword ptr [RBP + -0x38],EAX JMP 0x001def77 LAB_001def12: MOV RAX,qword ptr [RBP + -0x20] MOVZX ECX,byte ptr [RAX + 0x1] MOV AL,0x1 CMP ECX,0xa1 MOV byte ptr [RBP + -0x39],AL JL 0x001def64 MOV RAX,qword ptr [RBP + -0x20] MOVZX ECX,byte ptr [RAX + 0x1] MOV AL,0x1 CMP ECX,0xfe MOV byte ptr [RBP + -0x39],AL JG 0x001def64 MOV RAX,qword ptr [RBP + -0x20] MOVZX ECX,byte ptr [RAX + 0x2] MOV AL,0x1 CMP ECX,0xa1 MOV byte ptr [RBP + -0x39],AL JL 0x001def64 MOV RAX,qword ptr [RBP + -0x20] MOVZX EAX,byte ptr [RAX + 0x2] CMP EAX,0xfe SETG AL MOV byte ptr [RBP + -0x39],AL LAB_001def64: MOV DL,byte ptr [RBP + -0x39] MOV EAX,0xfffffffd XOR ECX,ECX TEST DL,0x1 CMOVNZ EAX,ECX MOV dword ptr [RBP + -0x38],EAX LAB_001def77: MOV EAX,dword ptr [RBP + -0x38] MOV dword ptr [RBP + -0x4],EAX JMP 0x001def86 LAB_001def7f: MOV dword ptr [RBP + -0x4],0x0 LAB_001def86: MOV EAX,dword ptr [RBP + -0x4] POP RBP RET
int4 my_mb_wc_eucjpms(int8 param_1,ulong *param_2,byte *param_3,byte *param_4) { ushort uVar1; bool bVar2; uint uVar3; int4 local_40; int4 local_38; int4 local_c; if (param_3 < param_4) { uVar3 = (uint)*param_3; if (uVar3 < 0x80) { *param_2 = (long)(int)uVar3; local_c = 1; } else if ((uVar3 < 0xa1) || (0xfe < uVar3)) { if (uVar3 == 0x8e) { if (param_4 < param_3 + 2) { local_c = 0xffffff9a; } else if ((param_3[1] < 0xa1) || (0xdf < param_3[1])) { local_c = 0; } else { *param_2 = (long)(int)(param_3[1] + 0xfec0); local_c = 2; } } else if (uVar3 == 0x8f) { if (param_4 < param_3 + 3) { local_c = 0xffffff99; } else { uVar1 = *(ushort *) (&jisx0212_eucjpms_to_unicode + (long)(int)((uint)param_3[1] * 0x100 + (uint)param_3[2]) * 2); *param_2 = (ulong)uVar1; if ((ulong)uVar1 == 0) { bVar2 = true; if (((0xa0 < param_3[1]) && (bVar2 = true, param_3[1] != 0xff)) && (bVar2 = true, 0xa0 < param_3[2])) { bVar2 = 0xfe < param_3[2]; } local_40 = 0xfffffffd; if (bVar2) { local_40 = 0; } } else { local_40 = 3; } local_c = local_40; } } else { local_c = 0; } } else if (param_4 < param_3 + 2) { local_c = 0xffffff9a; } else { uVar1 = *(ushort *) (jisx0208_eucjpms_to_unicode + (long)(int)(uVar3 * 0x100 + (uint)param_3[1]) * 2); *param_2 = (ulong)uVar1; if ((ulong)uVar1 == 0) { bVar2 = true; if (0xa0 < param_3[1]) { bVar2 = 0xfe < param_3[1]; } local_38 = 0xfffffffe; if (bVar2) { local_38 = 0; } } else { local_38 = 2; } local_c = local_38; } } else { local_c = 0xffffff9b; } return local_c; }
20,536
max_decimal
eloqsql/strings/decimal.c
void max_decimal(decimal_digits_t precision, decimal_digits_t frac, decimal_t *to) { decimal_digits_t intpart; dec1 *buf= to->buf; DBUG_ASSERT(precision && precision >= frac); to->sign= 0; if ((intpart= to->intg= (precision - frac))) { int firstdigits= intpart % DIG_PER_DEC1; if (firstdigits) *buf++= powers10[firstdigits] - 1; /* get 9 99 999 ... */ for(intpart/= DIG_PER_DEC1; intpart; intpart--) *buf++= DIG_MAX; } if ((to->frac= frac)) { int lastdigits= frac % DIG_PER_DEC1; for(frac/= DIG_PER_DEC1; frac; frac--) *buf++= DIG_MAX; if (lastdigits) *buf= frac_max[lastdigits - 1]; } }
O3
c
max_decimal: pushq %rbp movq %rsp, %rbp movl %esi, %ecx movq 0x10(%rdx), %rax movb $0x0, 0xc(%rdx) subl %esi, %edi movl %edi, (%rdx) testw %di, %di je 0x420aa movzwl %di, %r9d imull $0xe38f, %r9d, %r8d # imm = 0xE38F shrl $0x13, %r8d leal (%r8,%r8,8), %r10d subw %r10w, %r9w je 0x42094 movzwl %r9w, %r9d leaq 0x765fa(%rip), %r10 # 0xb8680 movl (%r10,%r9,4), %r9d decl %r9d movl %r9d, (%rax) addq $0x4, %rax cmpw $0x9, %di jb 0x420aa movl $0x3b9ac9ff, (%rax) # imm = 0x3B9AC9FF addq $0x4, %rax decw %r8w jne 0x4209a movl %esi, 0x4(%rdx) testw %cx, %cx je 0x420f7 movl %esi, %edx imulq $0x1c71c71d, %rdx, %rdx # imm = 0x1C71C71D shrq $0x20, %rdx leal (%rdx,%rdx,8), %edx subl %edx, %esi cmpw $0x9, %cx jb 0x420e5 movzwl %cx, %ecx imull $0xe38f, %ecx, %ecx # imm = 0xE38F shrl $0x13, %ecx movl $0x3b9ac9ff, (%rax) # imm = 0x3B9AC9FF addq $0x4, %rax decw %cx jne 0x420d6 testl %esi, %esi je 0x420f7 decl %esi leaq 0x81d6e(%rip), %rcx # 0xc3e60 movl (%rcx,%rsi,4), %ecx movl %ecx, (%rax) popq %rbp retq
max_decimal: push rbp mov rbp, rsp mov ecx, esi mov rax, [rdx+10h] mov byte ptr [rdx+0Ch], 0 sub edi, esi mov [rdx], edi test di, di jz short loc_420AA movzx r9d, di imul r8d, r9d, 0E38Fh shr r8d, 13h lea r10d, [r8+r8*8] sub r9w, r10w jz short loc_42094 movzx r9d, r9w lea r10, _ZL8powers10; powers10 mov r9d, [r10+r9*4] dec r9d mov [rax], r9d add rax, 4 loc_42094: cmp di, 9 jb short loc_420AA loc_4209A: mov dword ptr [rax], 3B9AC9FFh add rax, 4 dec r8w jnz short loc_4209A loc_420AA: mov [rdx+4], esi test cx, cx jz short loc_420F7 mov edx, esi imul rdx, 1C71C71Dh shr rdx, 20h lea edx, [rdx+rdx*8] sub esi, edx cmp cx, 9 jb short loc_420E5 movzx ecx, cx imul ecx, 0E38Fh shr ecx, 13h loc_420D6: mov dword ptr [rax], 3B9AC9FFh add rax, 4 dec cx jnz short loc_420D6 loc_420E5: test esi, esi jz short loc_420F7 dec esi lea rcx, _ZL8frac_max; frac_max mov ecx, [rcx+rsi*4] mov [rax], ecx loc_420F7: pop rbp retn
_DWORD * max_decimal(int a1, unsigned int a2, long long a3) { unsigned __int16 v3; // cx _DWORD *result; // rax int v5; // edi __int16 v6; // r8 int v7; // esi __int16 v8; // cx v3 = a2; result = *(_DWORD **)(a3 + 16); *(_BYTE *)(a3 + 12) = 0; v5 = a1 - a2; *(_DWORD *)a3 = v5; if ( (_WORD)v5 ) { v6 = (unsigned __int16)v5 / 9u; if ( (unsigned __int16)v5 % 9u ) *result++ = powers10[(unsigned __int16)v5 % 9u] - 1; if ( (unsigned __int16)v5 >= 9u ) { do { *result++ = 999999999; --v6; } while ( v6 ); } } *(_DWORD *)(a3 + 4) = a2; if ( (_WORD)a2 ) { v7 = a2 - 9 * ((477218589 * (unsigned long long)a2) >> 32); if ( v3 >= 9u ) { v8 = v3 / 9u; do { *result++ = 999999999; --v8; } while ( v8 ); } if ( v7 ) *result = frac_max[v7 - 1]; } return result; }
max_decimal: PUSH RBP MOV RBP,RSP MOV ECX,ESI MOV RAX,qword ptr [RDX + 0x10] MOV byte ptr [RDX + 0xc],0x0 SUB EDI,ESI MOV dword ptr [RDX],EDI TEST DI,DI JZ 0x001420aa MOVZX R9D,DI IMUL R8D,R9D,0xe38f SHR R8D,0x13 LEA R10D,[R8 + R8*0x8] SUB R9W,R10W JZ 0x00142094 MOVZX R9D,R9W LEA R10,[0x1b8680] MOV R9D,dword ptr [R10 + R9*0x4] DEC R9D MOV dword ptr [RAX],R9D ADD RAX,0x4 LAB_00142094: CMP DI,0x9 JC 0x001420aa LAB_0014209a: MOV dword ptr [RAX],0x3b9ac9ff ADD RAX,0x4 DEC R8W JNZ 0x0014209a LAB_001420aa: MOV dword ptr [RDX + 0x4],ESI TEST CX,CX JZ 0x001420f7 MOV EDX,ESI IMUL RDX,RDX,0x1c71c71d SHR RDX,0x20 LEA EDX,[RDX + RDX*0x8] SUB ESI,EDX CMP CX,0x9 JC 0x001420e5 MOVZX ECX,CX IMUL ECX,ECX,0xe38f SHR ECX,0x13 LAB_001420d6: MOV dword ptr [RAX],0x3b9ac9ff ADD RAX,0x4 DEC CX JNZ 0x001420d6 LAB_001420e5: TEST ESI,ESI JZ 0x001420f7 DEC ESI LEA RCX,[0x1c3e60] MOV ECX,dword ptr [RCX + RSI*0x4] MOV dword ptr [RAX],ECX LAB_001420f7: POP RBP RET
void max_decimal(int param_1,uint param_2,uint *param_3) { int *piVar1; int iVar2; uint uVar3; ushort uVar4; ushort uVar5; piVar1 = *(int **)(param_3 + 4); *(int1 *)(param_3 + 3) = 0; uVar3 = param_1 - param_2; *param_3 = uVar3; uVar4 = (ushort)uVar3; if (uVar4 != 0) { uVar3 = (uVar3 & 0xffff) / 9; uVar5 = uVar4 + (short)uVar3 * -9; if (uVar5 != 0) { *piVar1 = (&powers10)[uVar5] + -1; piVar1 = piVar1 + 1; } if (8 < uVar4) { do { *piVar1 = 999999999; piVar1 = piVar1 + 1; uVar4 = (short)uVar3 - 1; uVar3 = (uint)uVar4; } while (uVar4 != 0); } } param_3[1] = param_2; if ((ushort)param_2 != 0) { iVar2 = param_2 + (int)((ulong)param_2 * 0x1c71c71d >> 0x20) * -9; if (8 < (ushort)param_2) { uVar3 = (param_2 & 0xffff) / 9; do { *piVar1 = 999999999; piVar1 = piVar1 + 1; uVar4 = (short)uVar3 - 1; uVar3 = (uint)uVar4; } while (uVar4 != 0); } if (iVar2 != 0) { *piVar1 = *(int *)(frac_max + (ulong)(iVar2 - 1) * 4); } } return; }
20,537
FloatOptional_greater_than_equals_with_undefined_Test::~FloatOptional_greater_than_equals_with_undefined_Test()
yoga-mod/tests/FloatOptionalTest.cpp
TEST(FloatOptional, greater_than_equals_with_undefined) { ASSERT_TRUE(empty >= empty); ASSERT_FALSE(empty >= zero); ASSERT_FALSE(empty >= one); ASSERT_FALSE(empty >= positive); ASSERT_FALSE(empty >= negative); ASSERT_FALSE(zero >= empty); ASSERT_FALSE(one >= empty); ASSERT_FALSE(positive >= empty); ASSERT_FALSE(negative >= empty); }
O3
cpp
FloatOptional_greater_than_equals_with_undefined_Test::~FloatOptional_greater_than_equals_with_undefined_Test(): pushq %rbp movq %rsp, %rbp pushq %rbx pushq %rax movq %rdi, %rbx callq 0x381548 movl $0x10, %esi movq %rbx, %rdi addq $0x8, %rsp popq %rbx popq %rbp jmp 0x32440 nop
_ZN53FloatOptional_greater_than_equals_with_undefined_TestD0Ev: push rbp mov rbp, rsp push rbx push rax mov rbx, rdi call _ZN7testing4TestD2Ev; testing::Test::~Test() mov esi, 10h; unsigned __int64 mov rdi, rbx; void * add rsp, 8 pop rbx pop rbp jmp __ZdlPvm; operator delete(void *,ulong)
void FloatOptional_greater_than_equals_with_undefined_Test::~FloatOptional_greater_than_equals_with_undefined_Test( FloatOptional_greater_than_equals_with_undefined_Test *this) { testing::Test::~Test(this); operator delete(this, 0x10uLL); }
~FloatOptional_greater_than_equals_with_undefined_Test: PUSH RBP MOV RBP,RSP PUSH RBX PUSH RAX MOV RBX,RDI CALL 0x00481548 MOV ESI,0x10 MOV RDI,RBX ADD RSP,0x8 POP RBX POP RBP JMP 0x00132440
/* FloatOptional_greater_than_equals_with_int_Test::~FloatOptional_greater_than_equals_with_int_Test() */ void __thiscall FloatOptional_greater_than_equals_with_int_Test:: ~FloatOptional_greater_than_equals_with_int_Test (FloatOptional_greater_than_equals_with_int_Test *this) { testing::Test::~Test((Test *)this); operator_delete(this,0x10); return; }
20,538
mi_write_blob_record
eloqsql/storage/myisam/mi_dynrec.c
int _mi_write_blob_record(MI_INFO *info, const uchar *record) { uchar *rec_buff; int error; ulong reclength,reclength2,extra; extra= (ALIGN_SIZE(MI_MAX_DYN_BLOCK_HEADER)+MI_SPLIT_LENGTH+ MI_DYN_DELETE_BLOCK_HEADER+1); reclength= (info->s->base.pack_reclength + _mi_calc_total_blob_length(info,record)+ extra); if (!(rec_buff=(uchar*) my_alloca(reclength))) { my_errno= HA_ERR_OUT_OF_MEM; /* purecov: inspected */ return(-1); } reclength2= _mi_rec_pack(info,rec_buff+ALIGN_SIZE(MI_MAX_DYN_BLOCK_HEADER), record); DBUG_PRINT("info",("reclength: %lu reclength2: %lu", reclength, reclength2)); DBUG_ASSERT(reclength2 <= reclength); error=write_dynamic_record(info,rec_buff+ALIGN_SIZE(MI_MAX_DYN_BLOCK_HEADER), reclength2); my_afree(rec_buff); return(error); }
O0
c
mi_write_blob_record: pushq %rbp movq %rsp, %rbp subq $0x50, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq $0x5d, -0x40(%rbp) movq -0x10(%rbp), %rax movq (%rax), %rax movq 0x148(%rax), %rax movq %rax, -0x48(%rbp) movq -0x10(%rbp), %rdi movq -0x18(%rbp), %rsi callq 0x31d00 movq %rax, %rcx movq -0x48(%rbp), %rax addq %rcx, %rax addq -0x40(%rbp), %rax movq %rax, -0x30(%rbp) movq -0x30(%rbp), %rsi xorl %edi, %edi xorl %eax, %eax movl %eax, %edx callq 0x806c0 movq %rax, -0x20(%rbp) cmpq $0x0, %rax jne 0x31ca6 callq 0x82e30 movl $0x80, (%rax) movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF jmp 0x31cee movq -0x10(%rbp), %rdi movq -0x20(%rbp), %rsi addq $0x18, %rsi movq -0x18(%rbp), %rdx callq 0x30d70 movl %eax, %eax movq %rax, -0x38(%rbp) jmp 0x31cc3 jmp 0x31cc5 jmp 0x31cc7 movq -0x10(%rbp), %rdi movq -0x20(%rbp), %rsi addq $0x18, %rsi movq -0x38(%rbp), %rdx callq 0x312c0 movl %eax, -0x24(%rbp) movq -0x20(%rbp), %rdi callq 0x80a40 movl -0x24(%rbp), %eax movl %eax, -0x4(%rbp) movl -0x4(%rbp), %eax addq $0x50, %rsp popq %rbp retq nopw (%rax,%rax)
_mi_write_blob_record: push rbp mov rbp, rsp sub rsp, 50h mov [rbp+var_10], rdi mov [rbp+var_18], rsi mov [rbp+var_40], 5Dh ; ']' mov rax, [rbp+var_10] mov rax, [rax] mov rax, [rax+148h] mov [rbp+var_48], rax mov rdi, [rbp+var_10] mov rsi, [rbp+var_18] call _mi_calc_total_blob_length mov rcx, rax mov rax, [rbp+var_48] add rax, rcx add rax, [rbp+var_40] mov [rbp+var_30], rax mov rsi, [rbp+var_30] xor edi, edi xor eax, eax mov edx, eax call my_malloc mov [rbp+var_20], rax cmp rax, 0 jnz short loc_31CA6 call _my_thread_var mov dword ptr [rax], 80h mov [rbp+var_4], 0FFFFFFFFh jmp short loc_31CEE loc_31CA6: mov rdi, [rbp+var_10] mov rsi, [rbp+var_20] add rsi, 18h mov rdx, [rbp+var_18] call _mi_rec_pack mov eax, eax mov [rbp+var_38], rax jmp short $+2 loc_31CC3: jmp short $+2 loc_31CC5: jmp short $+2 loc_31CC7: mov rdi, [rbp+var_10] mov rsi, [rbp+var_20] add rsi, 18h mov rdx, [rbp+var_38] call write_dynamic_record mov [rbp+var_24], eax mov rdi, [rbp+var_20] call my_free mov eax, [rbp+var_24] mov [rbp+var_4], eax loc_31CEE: mov eax, [rbp+var_4] add rsp, 50h pop rbp retn
long long mi_write_blob_record(_DWORD *a1, _BYTE *a2) { const char *v2; // rsi long long v4; // [rsp+8h] [rbp-48h] long long v5; // [rsp+18h] [rbp-38h] unsigned int v6; // [rsp+2Ch] [rbp-24h] long long v7; // [rsp+30h] [rbp-20h] v4 = *(_QWORD *)(*(_QWORD *)a1 + 328LL); v2 = (const char *)(mi_calc_total_blob_length(a1, a2) + v4 + 93); v7 = my_malloc(0LL, v2, 0LL); if ( v7 ) { v5 = (unsigned int)mi_rec_pack(a1, (_BYTE *)(v7 + 24), a2); v6 = write_dynamic_record(a1, (const char *)(v7 + 24), v5); my_free(v7); return v6; } else { *(_DWORD *)my_thread_var(0LL, v2) = 128; return (unsigned int)-1; } }
_mi_write_blob_record: PUSH RBP MOV RBP,RSP SUB RSP,0x50 MOV qword ptr [RBP + -0x10],RDI MOV qword ptr [RBP + -0x18],RSI MOV qword ptr [RBP + -0x40],0x5d MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX] MOV RAX,qword ptr [RAX + 0x148] MOV qword ptr [RBP + -0x48],RAX MOV RDI,qword ptr [RBP + -0x10] MOV RSI,qword ptr [RBP + -0x18] CALL 0x00131d00 MOV RCX,RAX MOV RAX,qword ptr [RBP + -0x48] ADD RAX,RCX ADD RAX,qword ptr [RBP + -0x40] MOV qword ptr [RBP + -0x30],RAX MOV RSI,qword ptr [RBP + -0x30] XOR EDI,EDI XOR EAX,EAX MOV EDX,EAX CALL 0x001806c0 MOV qword ptr [RBP + -0x20],RAX CMP RAX,0x0 JNZ 0x00131ca6 CALL 0x00182e30 MOV dword ptr [RAX],0x80 MOV dword ptr [RBP + -0x4],0xffffffff JMP 0x00131cee LAB_00131ca6: MOV RDI,qword ptr [RBP + -0x10] MOV RSI,qword ptr [RBP + -0x20] ADD RSI,0x18 MOV RDX,qword ptr [RBP + -0x18] CALL 0x00130d70 MOV EAX,EAX MOV qword ptr [RBP + -0x38],RAX JMP 0x00131cc3 LAB_00131cc3: JMP 0x00131cc5 LAB_00131cc5: JMP 0x00131cc7 LAB_00131cc7: MOV RDI,qword ptr [RBP + -0x10] MOV RSI,qword ptr [RBP + -0x20] ADD RSI,0x18 MOV RDX,qword ptr [RBP + -0x38] CALL 0x001312c0 MOV dword ptr [RBP + -0x24],EAX MOV RDI,qword ptr [RBP + -0x20] CALL 0x00180a40 MOV EAX,dword ptr [RBP + -0x24] MOV dword ptr [RBP + -0x4],EAX LAB_00131cee: MOV EAX,dword ptr [RBP + -0x4] ADD RSP,0x50 POP RBP RET
int4 _mi_write_blob_record(long *param_1,int8 param_2) { int4 uVar1; long lVar2; long lVar3; int4 *puVar4; int4 local_c; lVar3 = *(long *)(*param_1 + 0x148); lVar2 = _mi_calc_total_blob_length(param_1,param_2); lVar3 = my_malloc(0,lVar3 + lVar2 + 0x5d,0); if (lVar3 == 0) { puVar4 = (int4 *)_my_thread_var(); *puVar4 = 0x80; local_c = 0xffffffff; } else { uVar1 = _mi_rec_pack(param_1,lVar3 + 0x18,param_2); local_c = write_dynamic_record(param_1,lVar3 + 0x18,uVar1); my_free(lVar3); } return local_c; }
20,539
evmone::ExecutionState::ExecutionState()
corpus-core[P]colibri-stateless/build_O3/_deps/evmone_external-src/lib/evmone/execution_state.hpp
ExecutionState() noexcept = default;
O3
cpp
evmone::ExecutionState::ExecutionState(): pushq %r15 pushq %r14 pushq %r12 pushq %rbx pushq %rax movq %rdi, %rbx addq $0x8, %rdi xorps %xmm0, %xmm0 movups %xmm0, (%rbx) xorl %r12d, %r12d movq %r12, 0x10(%rbx) movq $0x1000, 0x18(%rbx) # imm = 0x1000 callq 0x2f02c movq %r12, 0x20(%rbx) leaq 0x7c230(%rip), %rax # 0xab1d0 movq %rax, 0x28(%rbx) leaq 0x58(%rbx), %rax xorps %xmm0, %xmm0 movups %xmm0, 0x30(%rbx) movl %r12d, 0x40(%rbx) movq %rax, 0x48(%rbx) movq %r12, 0x50(%rbx) movb %r12b, 0x58(%rbx) movb %r12b, 0xb0(%rbx) leaq 0xb8(%rbx), %r14 movb %r12b, 0x1f0(%rbx) movl $0x20, %edi movl $0x8000, %esi # imm = 0x8000 callq 0x21180 movq %rax, %r15 xorps %xmm0, %xmm0 movups %xmm0, 0x68(%rbx) movl %r12d, 0x78(%rbx) movups %xmm0, 0x80(%rbx) movl $0x100, %edx # imm = 0x100 movq %r14, %rdi xorl %esi, %esi callq 0x21120 xorps %xmm0, %xmm0 movups %xmm0, 0x1f8(%rbx) movups %xmm0, 0x208(%rbx) movq %r15, 0x218(%rbx) addq $0x8, %rsp popq %rbx popq %r12 popq %r14 popq %r15 retq nop
_ZN6evmone14ExecutionStateC2Ev: push r15 push r14 push r12 push rbx push rax mov rbx, rdi add rdi, 8; this xorps xmm0, xmm0 movups xmmword ptr [rbx], xmm0 xor r12d, r12d mov [rbx+10h], r12 mov qword ptr [rbx+18h], 1000h call _ZN6evmone6Memory17allocate_capacityEv; evmone::Memory::allocate_capacity(void) mov [rbx+20h], r12 lea rax, off_AB1D0 mov [rbx+28h], rax lea rax, [rbx+58h] xorps xmm0, xmm0 movups xmmword ptr [rbx+30h], xmm0 mov [rbx+40h], r12d mov [rbx+48h], rax mov [rbx+50h], r12 mov [rbx+58h], r12b mov [rbx+0B0h], r12b lea r14, [rbx+0B8h] mov [rbx+1F0h], r12b mov edi, 20h ; ' ' mov esi, 8000h call _aligned_alloc mov r15, rax xorps xmm0, xmm0 movups xmmword ptr [rbx+68h], xmm0 mov [rbx+78h], r12d movups xmmword ptr [rbx+80h], xmm0 mov edx, 100h mov rdi, r14 xor esi, esi call _memset xorps xmm0, xmm0 movups xmmword ptr [rbx+1F8h], xmm0 movups xmmword ptr [rbx+208h], xmm0 mov [rbx+218h], r15 add rsp, 8 pop rbx pop r12 pop r14 pop r15 retn
long long evmone::ExecutionState::ExecutionState(evmone::ExecutionState *this) { long long v1; // r15 long long result; // rax *(_OWORD *)this = 0LL; *((_QWORD *)this + 2) = 0LL; *((_QWORD *)this + 3) = 4096LL; evmone::Memory::allocate_capacity((evmone::ExecutionState *)((char *)this + 8)); *((_QWORD *)this + 4) = 0LL; *((_QWORD *)this + 5) = off_AB1D0; *((_OWORD *)this + 3) = 0LL; *((_DWORD *)this + 16) = 0; *((_QWORD *)this + 9) = (char *)this + 88; *((_QWORD *)this + 10) = 0LL; *((_BYTE *)this + 88) = 0; *((_BYTE *)this + 176) = 0; *((_BYTE *)this + 496) = 0; v1 = aligned_alloc(32LL, 0x8000LL); *(_OWORD *)((char *)this + 104) = 0LL; *((_DWORD *)this + 30) = 0; *((_OWORD *)this + 8) = 0LL; result = memset((char *)this + 184, 0LL, 256LL); *(_OWORD *)((char *)this + 504) = 0LL; *(_OWORD *)((char *)this + 520) = 0LL; *((_QWORD *)this + 67) = v1; return result; }
ExecutionState: PUSH R15 PUSH R14 PUSH R12 PUSH RBX PUSH RAX MOV RBX,RDI ADD RDI,0x8 XORPS XMM0,XMM0 MOVUPS xmmword ptr [RBX],XMM0 XOR R12D,R12D MOV qword ptr [RBX + 0x10],R12 MOV qword ptr [RBX + 0x18],0x1000 CALL 0x0012f02c MOV qword ptr [RBX + 0x20],R12 LEA RAX,[0x1ab1d0] MOV qword ptr [RBX + 0x28],RAX LEA RAX,[RBX + 0x58] XORPS XMM0,XMM0 MOVUPS xmmword ptr [RBX + 0x30],XMM0 MOV dword ptr [RBX + 0x40],R12D MOV qword ptr [RBX + 0x48],RAX MOV qword ptr [RBX + 0x50],R12 MOV byte ptr [RBX + 0x58],R12B MOV byte ptr [RBX + 0xb0],R12B LEA R14,[RBX + 0xb8] MOV byte ptr [RBX + 0x1f0],R12B MOV EDI,0x20 MOV ESI,0x8000 CALL 0x00121180 MOV R15,RAX XORPS XMM0,XMM0 MOVUPS xmmword ptr [RBX + 0x68],XMM0 MOV dword ptr [RBX + 0x78],R12D MOVUPS xmmword ptr [RBX + 0x80],XMM0 MOV EDX,0x100 MOV RDI,R14 XOR ESI,ESI CALL 0x00121120 XORPS XMM0,XMM0 MOVUPS xmmword ptr [RBX + 0x1f8],XMM0 MOVUPS xmmword ptr [RBX + 0x208],XMM0 MOV qword ptr [RBX + 0x218],R15 ADD RSP,0x8 POP RBX POP R12 POP R14 POP R15 RET
/* evmone::ExecutionState::ExecutionState() */ void __thiscall evmone::ExecutionState::ExecutionState(ExecutionState *this) { int8 uVar1; *(int8 *)this = 0; *(int8 *)(this + 8) = 0; *(int8 *)(this + 0x10) = 0; *(int8 *)(this + 0x18) = 0x1000; Memory::allocate_capacity((Memory *)(this + 8)); *(int8 *)(this + 0x20) = 0; *(int ***)(this + 0x28) = &PTR__HostInterface_001ab1d0; *(int8 *)(this + 0x30) = 0; *(int8 *)(this + 0x38) = 0; *(int4 *)(this + 0x40) = 0; *(ExecutionState **)(this + 0x48) = this + 0x58; *(int8 *)(this + 0x50) = 0; this[0x58] = (ExecutionState)0x0; this[0xb0] = (ExecutionState)0x0; this[0x1f0] = (ExecutionState)0x0; uVar1 = aligned_alloc(0x20); *(int8 *)(this + 0x68) = 0; *(int8 *)(this + 0x70) = 0; *(int4 *)(this + 0x78) = 0; *(int8 *)(this + 0x80) = 0; *(int8 *)(this + 0x88) = 0; memset(this + 0xb8,0,0x100); *(int8 *)(this + 0x1f8) = 0; *(int8 *)(this + 0x200) = 0; *(int8 *)(this + 0x208) = 0; *(int8 *)(this + 0x210) = 0; *(int8 *)(this + 0x218) = uVar1; return; }
20,540
PycString::isEqual(PycRef<PycObject>) const
Pyarmor-Static-Unpack-1shot/pyc_string.cpp
bool PycString::isEqual(PycRef<PycObject> obj) const { if (type() != obj.type()) return false; PycRef<PycString> strObj = obj.cast<PycString>(); return isEqual(strObj->m_value); }
O0
cpp
PycString::isEqual(PycRef<PycObject>) const: pushq %rbp movq %rsp, %rbp subq $0x60, %rsp movq %rsi, -0x38(%rbp) movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq -0x10(%rbp), %rdi movq %rdi, -0x40(%rbp) callq 0xc340 movq -0x38(%rbp), %rdi movl %eax, -0x30(%rbp) callq 0x3d790 movl %eax, %ecx movl -0x30(%rbp), %eax cmpl %ecx, %eax je 0x5cf1c movb $0x0, -0x1(%rbp) jmp 0x5cf7c movq -0x38(%rbp), %rsi leaq -0x20(%rbp), %rdi movq %rdi, -0x50(%rbp) callq 0xc9b0 movq -0x50(%rbp), %rdi callq 0xc460 movq %rax, -0x48(%rbp) jmp 0x5cf3c movq -0x40(%rbp), %rdi movq -0x48(%rbp), %rsi addq $0x10, %rsi callq 0x3be30 movb %al, -0x51(%rbp) jmp 0x5cf52 movb -0x51(%rbp), %al andb $0x1, %al movb %al, -0x1(%rbp) leaq -0x20(%rbp), %rdi callq 0xc4a0 jmp 0x5cf7c movq %rax, %rcx movl %edx, %eax movq %rcx, -0x28(%rbp) movl %eax, -0x2c(%rbp) leaq -0x20(%rbp), %rdi callq 0xc4a0 jmp 0x5cf87 movb -0x1(%rbp), %al andb $0x1, %al addq $0x60, %rsp popq %rbp retq movq -0x28(%rbp), %rdi callq 0x8550
_ZNK9PycString7isEqualE6PycRefI9PycObjectE: push rbp mov rbp, rsp sub rsp, 60h mov [rbp+var_38], rsi mov [rbp+var_10], rdi mov [rbp+var_18], rsi mov rdi, [rbp+var_10]; this mov [rbp+var_40], rdi call _ZNK9PycObject4typeEv; PycObject::type(void) mov rdi, [rbp+var_38] mov [rbp+var_30], eax call _ZNK6PycRefI9PycObjectE4typeEv; PycRef<PycObject>::type(void) mov ecx, eax mov eax, [rbp+var_30] cmp eax, ecx jz short loc_5CF1C mov [rbp+var_1], 0 jmp short loc_5CF7C loc_5CF1C: mov rsi, [rbp+var_38] lea rdi, [rbp+var_20] mov [rbp+var_50], rdi call _ZNK6PycRefI9PycObjectE4castI9PycStringEES_IT_Ev; PycRef<PycObject>::cast<PycString>(void) mov rdi, [rbp+var_50] call _ZNK6PycRefI9PycStringEptEv; PycRef<PycString>::operator->(void) mov [rbp+var_48], rax jmp short $+2 loc_5CF3C: mov rdi, [rbp+var_40] mov rsi, [rbp+var_48] add rsi, 10h call _ZNK9PycString7isEqualERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; PycString::isEqual(std::string const&) mov [rbp+var_51], al jmp short $+2 loc_5CF52: mov al, [rbp+var_51] and al, 1 mov [rbp+var_1], al lea rdi, [rbp+var_20] call _ZN6PycRefI9PycStringED2Ev; PycRef<PycString>::~PycRef() jmp short loc_5CF7C mov rcx, rax mov eax, edx mov [rbp+var_28], rcx mov [rbp+var_2C], eax lea rdi, [rbp+var_20] call _ZN6PycRefI9PycStringED2Ev; PycRef<PycString>::~PycRef() jmp short loc_5CF87 loc_5CF7C: mov al, [rbp+var_1] and al, 1 add rsp, 60h pop rbp retn loc_5CF87: mov rdi, [rbp+var_28] call __Unwind_Resume
char PycString::isEqual(PycObject *a1, PycObject *a2) { long long v3; // [rsp+18h] [rbp-48h] int v4; // [rsp+30h] [rbp-30h] PycObject *v5[3]; // [rsp+40h] [rbp-20h] BYREF char v6; // [rsp+5Fh] [rbp-1h] v5[2] = a1; v5[1] = a2; v4 = PycObject::type(a1); if ( v4 == (unsigned int)PycRef<PycObject>::type((PycObject **)a2) ) { PycRef<PycObject>::cast<PycString>((long long)v5, (const void **)a2); v3 = PycRef<PycString>::operator->((long long)v5); v6 = PycString::isEqual((long long)a1, v3 + 16) & 1; PycRef<PycString>::~PycRef(v5); } else { v6 = 0; } return v6 & 1; }
isEqual: PUSH RBP MOV RBP,RSP SUB RSP,0x60 MOV qword ptr [RBP + -0x38],RSI MOV qword ptr [RBP + -0x10],RDI MOV qword ptr [RBP + -0x18],RSI MOV RDI,qword ptr [RBP + -0x10] MOV qword ptr [RBP + -0x40],RDI CALL 0x0010c340 MOV RDI,qword ptr [RBP + -0x38] MOV dword ptr [RBP + -0x30],EAX CALL 0x0013d790 MOV ECX,EAX MOV EAX,dword ptr [RBP + -0x30] CMP EAX,ECX JZ 0x0015cf1c MOV byte ptr [RBP + -0x1],0x0 JMP 0x0015cf7c LAB_0015cf1c: MOV RSI,qword ptr [RBP + -0x38] LEA RDI,[RBP + -0x20] MOV qword ptr [RBP + -0x50],RDI CALL 0x0010c9b0 MOV RDI,qword ptr [RBP + -0x50] LAB_0015cf31: CALL 0x0010c460 MOV qword ptr [RBP + -0x48],RAX JMP 0x0015cf3c LAB_0015cf3c: MOV RDI,qword ptr [RBP + -0x40] MOV RSI,qword ptr [RBP + -0x48] ADD RSI,0x10 CALL 0x0013be30 LAB_0015cf4d: MOV byte ptr [RBP + -0x51],AL JMP 0x0015cf52 LAB_0015cf52: MOV AL,byte ptr [RBP + -0x51] AND AL,0x1 MOV byte ptr [RBP + -0x1],AL LEA RDI,[RBP + -0x20] CALL 0x0010c4a0 JMP 0x0015cf7c LAB_0015cf7c: MOV AL,byte ptr [RBP + -0x1] AND AL,0x1 ADD RSP,0x60 POP RBP RET
/* PycString::isEqual(PycRef<PycObject>) const */ ulong __thiscall PycString::isEqual(PycString *this,PycRef<PycObject> *param_2) { uint uVar1; uint uVar2; long lVar3; ulong uVar4; PycRef<PycString> local_28 [8]; PycRef<PycObject> *local_20; PycString *local_18; byte local_9; local_20 = param_2; local_18 = this; uVar1 = PycObject::type((PycObject *)this); uVar2 = PycRef<PycObject>::type(param_2); uVar4 = (ulong)uVar1; if (uVar1 == uVar2) { PycRef<PycObject>::cast<PycString>(); /* try { // try from 0015cf31 to 0015cf4c has its CatchHandler @ 0015cf65 */ lVar3 = PycRef<PycString>::operator->(local_28); local_9 = isEqual(this,(string *)(lVar3 + 0x10)); local_9 = local_9 & 1; uVar4 = PycRef<PycString>::~PycRef(local_28); } else { local_9 = 0; } return CONCAT71((int7)(uVar4 >> 8),local_9) & 0xffffffffffffff01; }
20,541
psi_prlock_rdlock
eloqsql/mysys/my_thr_init.c
ATTRIBUTE_COLD int psi_prlock_rdlock(mysql_prlock_t *that, const char *file, uint line) { PSI_rwlock_locker_state state; PSI_rwlock_locker *locker= PSI_RWLOCK_CALL(start_rwlock_rdwait) (&state, that->m_psi, PSI_RWLOCK_READLOCK, file, line); int result= rw_pr_rdlock(&that->m_prlock); if (locker) PSI_RWLOCK_CALL(end_rwlock_rdwait)(locker, result); return result; }
O3
c
psi_prlock_rdlock: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %rbx subq $0x38, %rsp movl %edx, %r8d movq %rsi, %rcx movq %rdi, %r14 leaq 0x2c8fe9(%rip), %r15 # 0x2ed810 movq (%r15), %rax movq 0x68(%rdi), %rsi leaq -0x48(%rbp), %rdi xorl %edx, %edx callq *0x1a0(%rax) movq %rax, %rbx movq %r14, %rdi callq 0x26007 movl %eax, %r14d testq %rbx, %rbx je 0x2485c movq (%r15), %rax movq %rbx, %rdi movl %r14d, %esi callq *0x1a8(%rax) movl %r14d, %eax addq $0x38, %rsp popq %rbx popq %r14 popq %r15 popq %rbp retq
psi_prlock_rdlock: push rbp mov rbp, rsp push r15 push r14 push rbx sub rsp, 38h mov r8d, edx mov rcx, rsi mov r14, rdi lea r15, PSI_server mov rax, [r15] mov rsi, [rdi+68h] lea rdi, [rbp+var_48] xor edx, edx call qword ptr [rax+1A0h] mov rbx, rax mov rdi, r14 call rw_pr_rdlock mov r14d, eax test rbx, rbx jz short loc_2485C mov rax, [r15] mov rdi, rbx mov esi, r14d call qword ptr [rax+1A8h] loc_2485C: mov eax, r14d add rsp, 38h pop rbx pop r14 pop r15 pop rbp retn
long long psi_prlock_rdlock(long long a1, long long a2, unsigned int a3) { long long v3; // rbx unsigned int v4; // r14d _BYTE v6[72]; // [rsp+8h] [rbp-48h] BYREF v3 = (*((long long ( **)(_BYTE *, _QWORD, _QWORD, long long, _QWORD))PSI_server[0] + 52))( v6, *(_QWORD *)(a1 + 104), 0LL, a2, a3); v4 = rw_pr_rdlock(a1); if ( v3 ) (*((void ( **)(long long, _QWORD))PSI_server[0] + 53))(v3, v4); return v4; }
psi_prlock_rdlock: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH RBX SUB RSP,0x38 MOV R8D,EDX MOV RCX,RSI MOV R14,RDI LEA R15,[0x3ed810] MOV RAX,qword ptr [R15] MOV RSI,qword ptr [RDI + 0x68] LEA RDI,[RBP + -0x48] XOR EDX,EDX CALL qword ptr [RAX + 0x1a0] MOV RBX,RAX MOV RDI,R14 CALL 0x00126007 MOV R14D,EAX TEST RBX,RBX JZ 0x0012485c MOV RAX,qword ptr [R15] MOV RDI,RBX MOV ESI,R14D CALL qword ptr [RAX + 0x1a8] LAB_0012485c: MOV EAX,R14D ADD RSP,0x38 POP RBX POP R14 POP R15 POP RBP RET
int4 psi_prlock_rdlock(long param_1,int8 param_2,int4 param_3) { int4 uVar1; long lVar2; int1 local_50 [48]; lVar2 = (**(code **)(PSI_server + 0x1a0)) (local_50,*(int8 *)(param_1 + 0x68),0,param_2,param_3); uVar1 = rw_pr_rdlock(param_1); if (lVar2 != 0) { (**(code **)(PSI_server + 0x1a8))(lVar2,uVar1); } return uVar1; }
20,542
JS_SetUncatchableError
bluesky950520[P]quickjs/quickjs.c
void JS_SetUncatchableError(JSContext *ctx, JSValue val, BOOL flag) { JSObject *p; if (JS_VALUE_GET_TAG(val) != JS_TAG_OBJECT) return; p = JS_VALUE_GET_OBJ(val); if (p->class_id == JS_CLASS_ERROR) p->is_uncatchable_error = flag; }
O1
c
JS_SetUncatchableError: movq %rsi, -0x8(%rsp) cmpl $-0x1, %edx jne 0x26931 movq -0x8(%rsp), %rax cmpw $0x3, 0x6(%rax) jne 0x26931 movb 0x5(%rax), %dl shlb $0x5, %cl andb $0x20, %cl andb $-0x21, %dl orb %cl, %dl movb %dl, 0x5(%rax) retq
JS_SetUncatchableError: mov [rsp+var_8], rsi cmp edx, 0FFFFFFFFh jnz short locret_26931 mov rax, [rsp+var_8] cmp word ptr [rax+6], 3 jnz short locret_26931 mov dl, [rax+5] shl cl, 5 and cl, 20h and dl, 0DFh or dl, cl mov [rax+5], dl locret_26931: retn
long long JS_SetUncatchableError(long long a1, long long a2, int a3, char a4) { long long result; // rax if ( a3 == -1 ) { result = a2; if ( *(_WORD *)(a2 + 6) == 3 ) *(_BYTE *)(a2 + 5) = (32 * a4) & 0x20 | *(_BYTE *)(a2 + 5) & 0xDF; } return result; }
JS_SetUncatchableError: MOV qword ptr [RSP + -0x8],RSI CMP EDX,-0x1 JNZ 0x00126931 MOV RAX,qword ptr [RSP + -0x8] CMP word ptr [RAX + 0x6],0x3 JNZ 0x00126931 MOV DL,byte ptr [RAX + 0x5] SHL CL,0x5 AND CL,0x20 AND DL,0xdf OR DL,CL MOV byte ptr [RAX + 0x5],DL LAB_00126931: RET
void JS_SetUncatchableError(int8 param_1,long param_2,int param_3,byte param_4) { if ((param_3 == -1) && (*(short *)(param_2 + 6) == 3)) { *(byte *)(param_2 + 5) = *(byte *)(param_2 + 5) & 0xdf | (param_4 & 1) << 5; } return; }
20,543
JS_SetUncatchableError
bluesky950520[P]quickjs/quickjs.c
void JS_SetUncatchableError(JSContext *ctx, JSValue val, BOOL flag) { JSObject *p; if (JS_VALUE_GET_TAG(val) != JS_TAG_OBJECT) return; p = JS_VALUE_GET_OBJ(val); if (p->class_id == JS_CLASS_ERROR) p->is_uncatchable_error = flag; }
O3
c
JS_SetUncatchableError: cmpl $-0x1, %edx jne 0x27047 cmpw $0x3, 0x6(%rsi) jne 0x27047 movb 0x5(%rsi), %al shlb $0x5, %cl andb $0x20, %cl andb $-0x21, %al orb %cl, %al movb %al, 0x5(%rsi) retq
JS_SetUncatchableError: cmp edx, 0FFFFFFFFh jnz short locret_27047 cmp word ptr [rsi+6], 3 jnz short locret_27047 mov al, [rsi+5] shl cl, 5 and cl, 20h and al, 0DFh or al, cl mov [rsi+5], al locret_27047: retn
char JS_SetUncatchableError(long long a1, long long a2, int a3, char a4) { char result; // al if ( a3 == -1 && *(_WORD *)(a2 + 6) == 3 ) { result = (32 * a4) & 0x20 | *(_BYTE *)(a2 + 5) & 0xDF; *(_BYTE *)(a2 + 5) = result; } return result; }
JS_SetUncatchableError: CMP EDX,-0x1 JNZ 0x00127047 CMP word ptr [RSI + 0x6],0x3 JNZ 0x00127047 MOV AL,byte ptr [RSI + 0x5] SHL CL,0x5 AND CL,0x20 AND AL,0xdf OR AL,CL MOV byte ptr [RSI + 0x5],AL LAB_00127047: RET
void JS_SetUncatchableError(int8 param_1,long param_2,int param_3,byte param_4) { if ((param_3 == -1) && (*(short *)(param_2 + 6) == 3)) { *(byte *)(param_2 + 5) = *(byte *)(param_2 + 5) & 0xdf | (param_4 & 1) << 5; } return; }
20,544
svc_service_services_init
navaro[P]qoraal-tictactoe/build_O3/_deps/qoraal-src/src/svc/svc_services.c
int32_t svc_service_services_init (SVC_SERVICE_T * list) { SVC_SERVICE_T* pservice ; DBG_ASSERT_SVC_SERVICES(list, "svc_service_services_init unexpected!") ; os_mutex_init (&_svc_service_mutex) ; stack_init (&_svc_service_handlers) ; _svc_service_list = list ; for (_cfg_service_cnt=0; ; ) { pservice = &_svc_service_list[_cfg_service_cnt] ; if (pservice->service == SVC_SERVICES_INVALID) { break ; } _cfg_service_cnt++ ; if (pservice->ctrl) { if (pservice->ctrl(SVC_SERVICE_CTRL_INIT, _cfg_service_cnt-1) != EOK) { pservice->status = SVC_SERVICE_STATUS_DISABLED ; } } } return EOK ; }
O3
c
svc_service_services_init: pushq %rbp movq %rsp, %rbp pushq %rbx pushq %rax movq %rdi, %rbx testq %rdi, %rdi jne 0x16a8d leaq 0x1b1d2(%rip), %rdi # 0x31c58 xorl %eax, %eax callq 0x1433a leaq 0x280a4(%rip), %rdi # 0x3eb38 callq 0x14ef0 movq $0x0, 0x2a31c(%rip) # 0x40dc0 movq %rbx, 0x2a305(%rip) # 0x40db0 movl $0x0, 0x2a303(%rip) # 0x40db8 cmpl $0x0, 0x5c(%rbx) je 0x16b00 xorl %esi, %esi xorl %eax, %eax incl %eax movl %eax, 0x2a2f1(%rip) # 0x40db8 movq 0x40(%rbx), %rax testq %rax, %rax je 0x16ae2 movl $0x3e9, %edi # imm = 0x3E9 callq *%rax testl %eax, %eax je 0x16ae2 movl $0xffffffff, 0x54(%rbx) # imm = 0xFFFFFFFF movq 0x2a2c7(%rip), %rax # 0x40db0 movl 0x2a2c9(%rip), %esi # 0x40db8 imulq $0x70, %rsi, %rcx leaq (%rax,%rcx), %rbx cmpl $0x0, 0x5c(%rax,%rcx) movl %esi, %eax jne 0x16abf xorl %eax, %eax addq $0x8, %rsp popq %rbx popq %rbp retq
svc_service_services_init: push rbp mov rbp, rsp push rbx push rax mov rbx, rdi test rdi, rdi jnz short loc_16A8D lea rdi, aSvcServiceServ; "svc_service_services_init unexpected!" xor eax, eax call debug_assert loc_16A8D: lea rdi, _svc_service_mutex call os_mutex_init mov cs:_svc_service_handlers, 0 mov cs:_svc_service_list, rbx mov cs:_cfg_service_cnt, 0 cmp dword ptr [rbx+5Ch], 0 jz short loc_16B00 xor esi, esi xor eax, eax loc_16ABF: inc eax mov cs:_cfg_service_cnt, eax mov rax, [rbx+40h] test rax, rax jz short loc_16AE2 mov edi, 3E9h call rax test eax, eax jz short loc_16AE2 mov dword ptr [rbx+54h], 0FFFFFFFFh loc_16AE2: mov rax, cs:_svc_service_list mov esi, cs:_cfg_service_cnt imul rcx, rsi, 70h ; 'p' lea rbx, [rax+rcx] cmp dword ptr [rax+rcx+5Ch], 0 mov eax, esi jnz short loc_16ABF loc_16B00: xor eax, eax add rsp, 8 pop rbx pop rbp retn
long long svc_service_services_init( long long a1, long long a2, long long a3, long long a4, long long a5, long long a6, __m128 a7, __m128 a8, __m128 a9, __m128 a10, __m128 a11, __m128 a12, __m128 a13, __m128 a14) { char v14; // al long long v15; // rbx long long v16; // rsi int v17; // eax unsigned int ( *v18)(long long, long long); // rax v15 = a1; if ( !a1 ) debug_assert((long long)aSvcServiceServ, a2, a3, a4, a5, a6, a7, a8, a9, a10, a11, a12, a13, a14, v14); os_mutex_init(&svc_service_mutex); svc_service_handlers = 0LL; svc_service_list = a1; cfg_service_cnt = 0; if ( *(_DWORD *)(a1 + 92) ) { v16 = 0LL; v17 = 0; do { cfg_service_cnt = v17 + 1; v18 = *(unsigned int ( **)(long long, long long))(v15 + 64); if ( v18 && v18(1001LL, v16) ) *(_DWORD *)(v15 + 84) = -1; v16 = (unsigned int)cfg_service_cnt; v15 = svc_service_list + 112LL * (unsigned int)cfg_service_cnt; v17 = cfg_service_cnt; } while ( *(_DWORD *)(v15 + 92) ); } return 0LL; }
svc_service_services_init: PUSH RBP MOV RBP,RSP PUSH RBX PUSH RAX MOV RBX,RDI TEST RDI,RDI JNZ 0x00116a8d LEA RDI,[0x131c58] XOR EAX,EAX CALL 0x0011433a LAB_00116a8d: LEA RDI,[0x13eb38] CALL 0x00114ef0 MOV qword ptr [0x00140dc0],0x0 MOV qword ptr [0x00140db0],RBX MOV dword ptr [0x00140db8],0x0 CMP dword ptr [RBX + 0x5c],0x0 JZ 0x00116b00 XOR ESI,ESI XOR EAX,EAX LAB_00116abf: INC EAX MOV dword ptr [0x00140db8],EAX MOV RAX,qword ptr [RBX + 0x40] TEST RAX,RAX JZ 0x00116ae2 MOV EDI,0x3e9 CALL RAX TEST EAX,EAX JZ 0x00116ae2 MOV dword ptr [RBX + 0x54],0xffffffff LAB_00116ae2: MOV RAX,qword ptr [0x00140db0] MOV ESI,dword ptr [0x00140db8] IMUL RCX,RSI,0x70 LEA RBX,[RAX + RCX*0x1] CMP dword ptr [RAX + RCX*0x1 + 0x5c],0x0 MOV EAX,ESI JNZ 0x00116abf LAB_00116b00: XOR EAX,EAX ADD RSP,0x8 POP RBX POP RBP RET
int8 svc_service_services_init(long param_1) { int iVar1; ulong uVar2; if (param_1 == 0) { debug_assert(s_svc_service_services_init_unexpe_00131c58); } os_mutex_init(&_svc_service_mutex); _svc_service_handlers = 0; _cfg_service_cnt = 0; _svc_service_list = param_1; if (*(int *)(param_1 + 0x5c) != 0) { uVar2 = 0; do { _cfg_service_cnt = (int)uVar2 + 1; if (*(code **)(param_1 + 0x40) != (code *)0x0) { iVar1 = (**(code **)(param_1 + 0x40))(0x3e9,uVar2); if (iVar1 != 0) { *(int4 *)(param_1 + 0x54) = 0xffffffff; } } uVar2 = (ulong)_cfg_service_cnt; param_1 = _svc_service_list + uVar2 * 0x70; } while (*(int *)(_svc_service_list + 0x5c + uVar2 * 0x70) != 0); } return 0; }
20,545
LefDefParser::lefwLayerRoutingMinimumcutConnections(char const*)
Efficient-TDP/thirdparty/Limbo/limbo/thirdparty/lefdef/5.8/lef/lef/lefwWriter.cpp
int lefwLayerRoutingMinimumcutConnections(const char *direction) { if (!lefwFile) return LEFW_UNINITIALIZED; if (!lefwIsRoutingMinCut || lefwIsRoutingMinCutDist) return LEFW_BAD_ORDER; // lefwLayerRoutingMinimumcut has not being called or // lefwLayerRoutingMinimumcutConnections has already called if (lefwWriteEncrypt) encPrint(lefwFile, (char*) "\n %s ", direction); else fprintf(lefwFile, "\n %s ", direction); lefwLines++; prtSemiColon = 1; lefwIsRoutingMinCutDist = 1; if (lefwIsRoutingMinCutLen) // both distance & length within has defined lefwIsRoutingMinCut = 0; return LEFW_OK; }
O0
cpp
LefDefParser::lefwLayerRoutingMinimumcutConnections(char const*): subq $0x18, %rsp movq %rdi, 0x8(%rsp) leaq 0xa8cf0(%rip), %rax # 0xc5250 cmpq $0x0, (%rax) jne 0x1c573 movl $0x1, 0x14(%rsp) jmp 0x1c62a leaq 0xa8f9e(%rip), %rax # 0xc5518 cmpl $0x0, (%rax) je 0x1c58b leaq 0xa8f96(%rip), %rax # 0xc551c cmpl $0x0, (%rax) je 0x1c598 movl $0x2, 0x14(%rsp) jmp 0x1c62a cmpl $0x0, 0xa8f9d(%rip) # 0xc553c je 0x1c5c0 leaq 0xa8ca8(%rip), %rax # 0xc5250 movq (%rax), %rdi movq 0x8(%rsp), %rdx leaq 0x76778(%rip), %rsi # 0x92d2f movb $0x0, %al callq 0x8bf50 jmp 0x1c5dd leaq 0xa8c89(%rip), %rax # 0xc5250 movq (%rax), %rdi movq 0x8(%rsp), %rdx leaq 0x76759(%rip), %rsi # 0x92d2f movb $0x0, %al callq 0x2370 leaq 0xa8eb8(%rip), %rax # 0xc549c movl (%rax), %ecx addl $0x1, %ecx leaq 0xa8eac(%rip), %rax # 0xc549c movl %ecx, (%rax) movl $0x1, 0xa8f48(%rip) # 0xc5544 leaq 0xa8f19(%rip), %rax # 0xc551c movl $0x1, (%rax) leaq 0xa8f10(%rip), %rax # 0xc5520 cmpl $0x0, (%rax) je 0x1c622 leaq 0xa8efc(%rip), %rax # 0xc5518 movl $0x0, (%rax) movl $0x0, 0x14(%rsp) movl 0x14(%rsp), %eax addq $0x18, %rsp retq nopw %cs:(%rax,%rax)
_ZN12LefDefParser37lefwLayerRoutingMinimumcutConnectionsEPKc: sub rsp, 18h mov [rsp+18h+var_10], rdi lea rax, _ZN12LefDefParser8lefwFileE; LefDefParser::lefwFile cmp qword ptr [rax], 0 jnz short loc_1C573 mov [rsp+18h+var_4], 1 jmp loc_1C62A loc_1C573: lea rax, _ZN12LefDefParser19lefwIsRoutingMinCutE; LefDefParser::lefwIsRoutingMinCut cmp dword ptr [rax], 0 jz short loc_1C58B lea rax, _ZN12LefDefParser23lefwIsRoutingMinCutDistE; LefDefParser::lefwIsRoutingMinCutDist cmp dword ptr [rax], 0 jz short loc_1C598 loc_1C58B: mov [rsp+18h+var_4], 2 jmp loc_1C62A loc_1C598: cmp cs:_ZN12LefDefParserL16lefwWriteEncryptE, 0; LefDefParser::lefwWriteEncrypt jz short loc_1C5C0 lea rax, _ZN12LefDefParser8lefwFileE; LefDefParser::lefwFile mov rdi, [rax] mov rdx, [rsp+18h+var_10] lea rsi, aS; "\n %s " mov al, 0 call _ZN12LefDefParser8encPrintEP8_IO_FILEPcz; LefDefParser::encPrint(_IO_FILE *,char *,...) jmp short loc_1C5DD loc_1C5C0: lea rax, _ZN12LefDefParser8lefwFileE; LefDefParser::lefwFile mov rdi, [rax] mov rdx, [rsp+18h+var_10] lea rsi, aS; "\n %s " mov al, 0 call _fprintf loc_1C5DD: lea rax, _ZN12LefDefParser9lefwLinesE; LefDefParser::lefwLines mov ecx, [rax] add ecx, 1 lea rax, _ZN12LefDefParser9lefwLinesE; LefDefParser::lefwLines mov [rax], ecx mov cs:_ZN12LefDefParserL12prtSemiColonE, 1; LefDefParser::prtSemiColon lea rax, _ZN12LefDefParser23lefwIsRoutingMinCutDistE; LefDefParser::lefwIsRoutingMinCutDist mov dword ptr [rax], 1 lea rax, _ZN12LefDefParser22lefwIsRoutingMinCutLenE; LefDefParser::lefwIsRoutingMinCutLen cmp dword ptr [rax], 0 jz short loc_1C622 lea rax, _ZN12LefDefParser19lefwIsRoutingMinCutE; LefDefParser::lefwIsRoutingMinCut mov dword ptr [rax], 0 loc_1C622: mov [rsp+18h+var_4], 0 loc_1C62A: mov eax, [rsp+18h+var_4] add rsp, 18h retn
long long LefDefParser::lefwLayerRoutingMinimumcutConnections( LefDefParser *this, const char *a2, long long a3, int a4, int a5, int a6) { if ( *(_QWORD *)&LefDefParser::lefwFile ) { if ( LefDefParser::lefwIsRoutingMinCut && !LefDefParser::lefwIsRoutingMinCutDist ) { if ( LefDefParser::lefwWriteEncrypt ) LefDefParser::encPrint(LefDefParser::lefwFile, (unsigned int)"\n %s ", (_DWORD)this, a4, a5, a6); else fprintf(*(_QWORD *)&LefDefParser::lefwFile, "\n %s ", (const char *)this); ++LefDefParser::lefwLines; LefDefParser::prtSemiColon = 1; LefDefParser::lefwIsRoutingMinCutDist = 1; if ( LefDefParser::lefwIsRoutingMinCutLen ) LefDefParser::lefwIsRoutingMinCut = 0; return 0; } else { return 2; } } else { return 1; } }
lefwLayerRoutingMinimumcutConnections: SUB RSP,0x18 MOV qword ptr [RSP + 0x8],RDI LEA RAX,[0x1c5250] CMP qword ptr [RAX],0x0 JNZ 0x0011c573 MOV dword ptr [RSP + 0x14],0x1 JMP 0x0011c62a LAB_0011c573: LEA RAX,[0x1c5518] CMP dword ptr [RAX],0x0 JZ 0x0011c58b LEA RAX,[0x1c551c] CMP dword ptr [RAX],0x0 JZ 0x0011c598 LAB_0011c58b: MOV dword ptr [RSP + 0x14],0x2 JMP 0x0011c62a LAB_0011c598: CMP dword ptr [0x001c553c],0x0 JZ 0x0011c5c0 LEA RAX,[0x1c5250] MOV RDI,qword ptr [RAX] MOV RDX,qword ptr [RSP + 0x8] LEA RSI,[0x192d2f] MOV AL,0x0 CALL 0x0018bf50 JMP 0x0011c5dd LAB_0011c5c0: LEA RAX,[0x1c5250] MOV RDI,qword ptr [RAX] MOV RDX,qword ptr [RSP + 0x8] LEA RSI,[0x192d2f] MOV AL,0x0 CALL 0x00102370 LAB_0011c5dd: LEA RAX,[0x1c549c] MOV ECX,dword ptr [RAX] ADD ECX,0x1 LEA RAX,[0x1c549c] MOV dword ptr [RAX],ECX MOV dword ptr [0x001c5544],0x1 LEA RAX,[0x1c551c] MOV dword ptr [RAX],0x1 LEA RAX,[0x1c5520] CMP dword ptr [RAX],0x0 JZ 0x0011c622 LEA RAX,[0x1c5518] MOV dword ptr [RAX],0x0 LAB_0011c622: MOV dword ptr [RSP + 0x14],0x0 LAB_0011c62a: MOV EAX,dword ptr [RSP + 0x14] ADD RSP,0x18 RET
/* LefDefParser::lefwLayerRoutingMinimumcutConnections(char const*) */ int4 LefDefParser::lefwLayerRoutingMinimumcutConnections(char *param_1) { int4 local_4; if (lefwFile == (_IO_FILE *)0x0) { local_4 = 1; } else if ((lefwIsRoutingMinCut == 0) || (lefwIsRoutingMinCutDist != 0)) { local_4 = 2; } else { if (lefwWriteEncrypt == 0) { fprintf(lefwFile,"\n %s ",param_1); } else { encPrint(lefwFile,"\n %s ",param_1); } lefwLines = lefwLines + 1; prtSemiColon = 1; lefwIsRoutingMinCutDist = 1; if (lefwIsRoutingMinCutLen != 0) { lefwIsRoutingMinCut = 0; } local_4 = 0; } return local_4; }
20,546
qh_point_add
aimrt_mujoco_sim/_deps/qhull-src/src/libqhull_r/poly2_r.c
void qh_point_add(qhT *qh, setT *set, pointT *point, void *elem) { int id, size; SETreturnsize_(set, size); if ((id= qh_pointid(qh, point)) < 0) qh_fprintf(qh, qh->ferr, 7067, "qhull internal warning (point_add): unknown point %p id %d\n", point, id); else if (id >= size) { qh_fprintf(qh, qh->ferr, 6160, "qhull internal error (point_add): point p%d is out of bounds(%d)\n", id, size); qh_errexit(qh, qh_ERRqhull, NULL, NULL); }else SETelem_(set, id)= elem; }
O0
c
qh_point_add: subq $0x28, %rsp movq %rdi, 0x20(%rsp) movq %rsi, 0x18(%rsp) movq %rdx, 0x10(%rsp) movq %rcx, 0x8(%rsp) movq 0x18(%rsp), %rax movq 0x18(%rsp), %rcx movslq (%rcx), %rcx movl 0x8(%rax,%rcx,8), %eax movl %eax, (%rsp) cmpl $0x0, %eax je 0x4d261c movl (%rsp), %eax addl $-0x1, %eax movl %eax, (%rsp) jmp 0x4d2626 movq 0x18(%rsp), %rax movl (%rax), %eax movl %eax, (%rsp) movq 0x20(%rsp), %rdi movq 0x10(%rsp), %rsi callq 0x4f86d0 movl %eax, 0x4(%rsp) cmpl $0x0, %eax jge 0x4d266e movq 0x20(%rsp), %rdi movq 0x20(%rsp), %rax movq 0x978(%rax), %rsi movq 0x10(%rsp), %r8 movl 0x4(%rsp), %r9d movl $0x1b9b, %edx # imm = 0x1B9B leaq 0x6c85e(%rip), %rcx # 0x53eec3 movb $0x0, %al callq 0x4fdcb0 jmp 0x4d26d2 movl 0x4(%rsp), %eax cmpl (%rsp), %eax jl 0x4d26bc movq 0x20(%rsp), %rdi movq 0x20(%rsp), %rax movq 0x978(%rax), %rsi movl 0x4(%rsp), %r8d movl (%rsp), %r9d movl $0x1810, %edx # imm = 0x1810 leaq 0x6c862(%rip), %rcx # 0x53eeff movb $0x0, %al callq 0x4fdcb0 movq 0x20(%rsp), %rdi movl $0x5, %esi xorl %eax, %eax movl %eax, %ecx movq %rcx, %rdx callq 0x50ccd0 jmp 0x4d26d0 movq 0x8(%rsp), %rdx movq 0x18(%rsp), %rax movslq 0x4(%rsp), %rcx movq %rdx, 0x8(%rax,%rcx,8) jmp 0x4d26d2 addq $0x28, %rsp retq nopw (%rax,%rax)
qh_point_add: sub rsp, 28h mov [rsp+28h+var_8], rdi mov [rsp+28h+var_10], rsi mov [rsp+28h+var_18], rdx mov [rsp+28h+var_20], rcx mov rax, [rsp+28h+var_10] mov rcx, [rsp+28h+var_10] movsxd rcx, dword ptr [rcx] mov eax, [rax+rcx*8+8] mov [rsp+28h+var_28], eax cmp eax, 0 jz short loc_4D261C mov eax, [rsp+28h+var_28] add eax, 0FFFFFFFFh mov [rsp+28h+var_28], eax jmp short loc_4D2626 loc_4D261C: mov rax, [rsp+28h+var_10] mov eax, [rax] mov [rsp+28h+var_28], eax loc_4D2626: mov rdi, [rsp+28h+var_8] mov rsi, [rsp+28h+var_18] call qh_pointid mov [rsp+28h+var_24], eax cmp eax, 0 jge short loc_4D266E mov rdi, [rsp+28h+var_8] mov rax, [rsp+28h+var_8] mov rsi, [rax+978h] mov r8, [rsp+28h+var_18] mov r9d, [rsp+28h+var_24] mov edx, 1B9Bh lea rcx, aQhullInternalW; "qhull internal warning (point_add): unk"... mov al, 0 call qh_fprintf jmp short loc_4D26D2 loc_4D266E: mov eax, [rsp+28h+var_24] cmp eax, [rsp+28h+var_28] jl short loc_4D26BC mov rdi, [rsp+28h+var_8] mov rax, [rsp+28h+var_8] mov rsi, [rax+978h] mov r8d, [rsp+28h+var_24] mov r9d, [rsp+28h+var_28] mov edx, 1810h lea rcx, aQhullInternalE_80; "qhull internal error (point_add): point"... mov al, 0 call qh_fprintf mov rdi, [rsp+28h+var_8] mov esi, 5 xor eax, eax mov ecx, eax mov rdx, rcx call qh_errexit jmp short loc_4D26D0 loc_4D26BC: mov rdx, [rsp+28h+var_20] mov rax, [rsp+28h+var_10] movsxd rcx, [rsp+28h+var_24] mov [rax+rcx*8+8], rdx loc_4D26D0: jmp short $+2 loc_4D26D2: add rsp, 28h retn
long long qh_point_add(long long a1, int *a2, long long a3, long long a4) { long long result; // rax int v5; // [rsp+0h] [rbp-28h] int v6; // [rsp+0h] [rbp-28h] int v7; // [rsp+4h] [rbp-24h] int v9; // [rsp+10h] [rbp-18h] v9 = a3; v5 = a2[2 * *a2 + 2]; if ( v5 ) v6 = v5 - 1; else v6 = *a2; v7 = qh_pointid(a1, a3); if ( v7 < 0 ) return qh_fprintf( a1, *(_QWORD *)(a1 + 2424), 7067, (unsigned int)"qhull internal warning (point_add): unknown point %p id %d\n", v9, v7); if ( v7 >= v6 ) { qh_fprintf( a1, *(_QWORD *)(a1 + 2424), 6160, (unsigned int)"qhull internal error (point_add): point p%d is out of bounds(%d)\n", v7, v6); qh_errexit(a1, 5LL, 0LL); } result = (long long)a2; *(_QWORD *)&a2[2 * v7 + 2] = a4; return result; }
operator!=: SUB RSP,0x18 MOV qword ptr [RSP + 0x10],RDI MOV qword ptr [RSP + 0x8],RSI MOV RDI,qword ptr [RSP + 0x10] CALL 0x004bccf0 MOV RAX,qword ptr [RAX] MOV qword ptr [RSP],RAX MOV RDI,qword ptr [RSP + 0x8] CALL 0x004bccf0 MOV RCX,RAX MOV RAX,qword ptr [RSP] CMP RAX,qword ptr [RCX] SETNZ AL AND AL,0x1 ADD RSP,0x18 RET
/* bool __gnu_cxx::TEMPNAMEPLACEHOLDERVALUE(__gnu_cxx::__normal_iterator<mjCMesh**, std::vector<mjCMesh*, std::allocator<mjCMesh*> > > const&, __gnu_cxx::__normal_iterator<mjCMesh**, std::vector<mjCMesh*, std::allocator<mjCMesh*> > > const&) */ bool __gnu_cxx::operator!=(__normal_iterator *param_1,__normal_iterator *param_2) { long lVar1; long *plVar2; plVar2 = (long *)__normal_iterator<mjCMesh**,std::vector<mjCMesh*,std::allocator<mjCMesh*>>>::base ((__normal_iterator<mjCMesh**,std::vector<mjCMesh*,std::allocator<mjCMesh*>>> *)param_1); lVar1 = *plVar2; plVar2 = (long *)__normal_iterator<mjCMesh**,std::vector<mjCMesh*,std::allocator<mjCMesh*>>>::base ((__normal_iterator<mjCMesh**,std::vector<mjCMesh*,std::allocator<mjCMesh*>>> *)param_2); return lVar1 != *plVar2; }
20,547
ma_tls_write
eloqsql/libmariadb/libmariadb/secure/openssl.c
ssize_t ma_tls_write(MARIADB_TLS *ctls, const uchar* buffer, size_t length) { int rc; MARIADB_PVIO *pvio= ctls->pvio; while ((rc= SSL_write((SSL *)ctls->ssl, (void *)buffer, (int)length)) <= 0) { int error= SSL_get_error((SSL *)ctls->ssl, rc); if (error != SSL_ERROR_WANT_WRITE) break; if (pvio->methods->wait_io_or_timeout(pvio, TRUE, pvio->mysql->options.write_timeout) < 1) break; } if (rc <= 0) { MYSQL *mysql= SSL_get_app_data(ctls->ssl); ma_tls_set_error(mysql); } return rc; }
O3
c
ma_tls_write: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx pushq %rax movq %rdx, %rbx movq %rsi, %r12 movq %rdi, %r15 movq 0x8(%rdi), %r13 movq 0x10(%r15), %rdi movq %r12, %rsi movl %ebx, %edx callq 0x13830 movl %eax, %r14d testl %eax, %eax jg 0x288bf movq 0x10(%r15), %rdi movl %r14d, %esi callq 0x13050 cmpl $0x3, %eax jne 0x288ac movq 0x40(%r13), %rax movq 0x48(%r13), %rcx movl 0x398(%rax), %edx movq %r13, %rdi movl $0x1, %esi callq *0x30(%rcx) testl %eax, %eax jg 0x28869 movq 0x10(%r15), %rdi xorl %esi, %esi callq 0x13160 movq %rax, %rdi callq 0x285bc movslq %r14d, %rax addq $0x8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
ma_tls_write: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx push rax mov rbx, rdx mov r12, rsi mov r15, rdi mov r13, [rdi+8] loc_28869: mov rdi, [r15+10h] mov rsi, r12 mov edx, ebx call _SSL_write mov r14d, eax test eax, eax jg short loc_288BF mov rdi, [r15+10h] mov esi, r14d call _SSL_get_error cmp eax, 3 jnz short loc_288AC mov rax, [r13+40h] mov rcx, [r13+48h] mov edx, [rax+398h] mov rdi, r13 mov esi, 1 call qword ptr [rcx+30h] test eax, eax jg short loc_28869 loc_288AC: mov rdi, [r15+10h] xor esi, esi call _SSL_get_ex_data mov rdi, rax call ma_tls_set_error loc_288BF: movsxd rax, r14d add rsp, 8 pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
long long ma_tls_write(long long a1, long long a2, unsigned int a3) { long long v4; // r13 int v5; // eax int v6; // r14d long long *v7; // rax v4 = *(_QWORD *)(a1 + 8); while ( 1 ) { v5 = SSL_write(*(_QWORD *)(a1 + 16), a2, a3); v6 = v5; if ( v5 > 0 ) break; if ( (unsigned int)SSL_get_error(*(_QWORD *)(a1 + 16), (unsigned int)v5) != 3 || (*(int ( **)(long long, long long, _QWORD))(*(_QWORD *)(v4 + 72) + 48LL))( v4, 1LL, *(unsigned int *)(*(_QWORD *)(v4 + 64) + 920LL)) <= 0 ) { v7 = (long long *)SSL_get_ex_data(*(_QWORD *)(a1 + 16), 0LL); ma_tls_set_error(v7); return v6; } } return v6; }
ma_tls_write: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX PUSH RAX MOV RBX,RDX MOV R12,RSI MOV R15,RDI MOV R13,qword ptr [RDI + 0x8] LAB_00128869: MOV RDI,qword ptr [R15 + 0x10] MOV RSI,R12 MOV EDX,EBX CALL 0x00113830 MOV R14D,EAX TEST EAX,EAX JG 0x001288bf MOV RDI,qword ptr [R15 + 0x10] MOV ESI,R14D CALL 0x00113050 CMP EAX,0x3 JNZ 0x001288ac MOV RAX,qword ptr [R13 + 0x40] MOV RCX,qword ptr [R13 + 0x48] MOV EDX,dword ptr [RAX + 0x398] MOV RDI,R13 MOV ESI,0x1 CALL qword ptr [RCX + 0x30] TEST EAX,EAX JG 0x00128869 LAB_001288ac: MOV RDI,qword ptr [R15 + 0x10] XOR ESI,ESI CALL 0x00113160 MOV RDI,RAX CALL 0x001285bc LAB_001288bf: MOVSXD RAX,R14D ADD RSP,0x8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
long ma_tls_write(long param_1,void *param_2,int param_3) { long lVar1; int ret_code; int iVar2; void *pvVar3; lVar1 = *(long *)(param_1 + 8); do { ret_code = SSL_write(*(SSL **)(param_1 + 0x10),param_2,param_3); if (0 < ret_code) goto LAB_001288bf; iVar2 = SSL_get_error(*(SSL **)(param_1 + 0x10),ret_code); if (iVar2 != 3) break; iVar2 = (**(code **)(*(long *)(lVar1 + 0x48) + 0x30)) (lVar1,1,*(int4 *)(*(long *)(lVar1 + 0x40) + 0x398)); } while (0 < iVar2); pvVar3 = SSL_get_ex_data(*(SSL **)(param_1 + 0x10),0); ma_tls_set_error(pvVar3); LAB_001288bf: return (long)ret_code; }
20,548
mujoco::plugin::sdf::Bowl::Gradient(double*, double const*) const
aimrt_mujoco_sim/_deps/mujoco-src/plugin/sdf/bowl.cc
void Bowl::Gradient(mjtNum grad[3], const mjtNum point[3]) const { // mjtNum q[2] = { mju_norm(point, 2), point[2] }; // if (height*q[0] < width*q[1]) { // mjtNum qdiff[2] = { q[0] - width, q[1] - height }; // mjtNum qdiffnorm = mju_norm(qdiff, 2); // mjtNum grad_qdiff[3] = {qdiff[0] * point[0] / q[0], // qdiff[0] * point[1] / q[0], // qdiff[1]}; // grad[0] = - grad_qdiff[0] / qdiffnorm; // grad[1] = - grad_qdiff[1] / qdiffnorm; // grad[2] = - grad_qdiff[2] / qdiffnorm; // } else { // mjtNum pnorm = mju_norm3(point); // mjtNum grad_dist = (pnorm - radius) / mju_abs(pnorm - radius); // grad[0] = - grad_dist * point[0] / pnorm; // grad[1] = - grad_dist * point[1] / pnorm; // grad[2] = - grad_dist * point[2] / pnorm; // } mjtNum eps = 1e-8; mjtNum dist0 = distance(point, attribute); mjtNum pointX[3] = {point[0]+eps, point[1], point[2]}; mjtNum distX = distance(pointX, attribute); mjtNum pointY[3] = {point[0], point[1]+eps, point[2]}; mjtNum distY = distance(pointY, attribute); mjtNum pointZ[3] = {point[0], point[1], point[2]+eps}; mjtNum distZ = distance(pointZ, attribute); grad[0] = (distX - dist0) / eps; grad[1] = (distY - dist0) / eps; grad[2] = (distZ - dist0) / eps; }
O3
cpp
mujoco::plugin::sdf::Bowl::Gradient(double*, double const*) const: pushq %r15 pushq %r14 pushq %rbx subq $0x90, %rsp movq %rdx, %r15 movq %rsi, %rbx movq %rdi, %r14 movq %rdx, %rdi movq %r14, %rsi callq 0xd5fa vmovaps %xmm0, 0x20(%rsp) vmovsd 0x3cee0(%rip), %xmm0 # 0x4a5e0 vaddsd (%r15), %xmm0, %xmm0 leaq 0x70(%rsp), %rdi vmovsd %xmm0, (%rdi) vmovups 0x8(%r15), %xmm0 vmovups %xmm0, 0x8(%rdi) movq %r14, %rsi callq 0xd5fa vmovsd (%r15), %xmm1 leaq 0x50(%rsp), %rdi vmovsd %xmm1, (%rdi) vmovsd 0x3cea9(%rip), %xmm1 # 0x4a5e0 vaddsd 0x8(%r15), %xmm1, %xmm1 vmovaps %xmm0, 0x10(%rsp) vmovsd %xmm1, 0x8(%rdi) vmovsd 0x10(%r15), %xmm0 vmovsd %xmm0, 0x10(%rdi) movq %r14, %rsi callq 0xd5fa vmovaps %xmm0, (%rsp) vmovups (%r15), %xmm0 leaq 0x30(%rsp), %rdi vmovaps %xmm0, (%rdi) vmovsd 0x3ce6a(%rip), %xmm0 # 0x4a5e0 vaddsd 0x10(%r15), %xmm0, %xmm0 vmovsd %xmm0, 0x10(%rdi) movq %r14, %rsi callq 0xd5fa vmovapd 0x10(%rsp), %xmm1 vunpcklpd (%rsp), %xmm1, %xmm1 # xmm1 = xmm1[0],mem[0] vmovapd 0x20(%rsp), %xmm3 vmovddup %xmm3, %xmm2 # xmm2 = xmm3[0,0] vsubpd %xmm2, %xmm1, %xmm1 vmovddup 0x3ce36(%rip), %xmm2 # xmm2 = mem[0,0] vdivpd %xmm2, %xmm1, %xmm1 vmovupd %xmm1, (%rbx) vsubsd %xmm3, %xmm0, %xmm0 vdivsd 0x3ce22(%rip), %xmm0, %xmm0 # 0x4a5e0 vmovsd %xmm0, 0x10(%rbx) addq $0x90, %rsp popq %rbx popq %r14 popq %r15 retq
_ZNK6mujoco6plugin3sdf4Bowl8GradientEPdPKd: push r15 push r14 push rbx sub rsp, 90h mov r15, rdx mov rbx, rsi mov r14, rdi mov rdi, rdx; this mov rsi, r14; double * call _ZN6mujoco6plugin3sdf12_GLOBAL__N_18distanceEPKdS4__0; mujoco::plugin::sdf::`anonymous namespace'::distance(double const*,double const*) vmovaps [rsp+0A8h+var_88], xmm0 vmovsd xmm0, cs:qword_4A5E0 vaddsd xmm0, xmm0, qword ptr [r15] lea rdi, [rsp+0A8h+var_38]; this vmovsd qword ptr [rdi], xmm0 vmovups xmm0, xmmword ptr [r15+8] vmovups xmmword ptr [rdi+8], xmm0 mov rsi, r14; double * call _ZN6mujoco6plugin3sdf12_GLOBAL__N_18distanceEPKdS4__0; mujoco::plugin::sdf::`anonymous namespace'::distance(double const*,double const*) vmovsd xmm1, qword ptr [r15] lea rdi, [rsp+0A8h+var_58]; this vmovsd qword ptr [rdi], xmm1 vmovsd xmm1, cs:qword_4A5E0 vaddsd xmm1, xmm1, qword ptr [r15+8] vmovaps [rsp+0A8h+var_98], xmm0 vmovsd qword ptr [rdi+8], xmm1 vmovsd xmm0, qword ptr [r15+10h] vmovsd qword ptr [rdi+10h], xmm0 mov rsi, r14; double * call _ZN6mujoco6plugin3sdf12_GLOBAL__N_18distanceEPKdS4__0; mujoco::plugin::sdf::`anonymous namespace'::distance(double const*,double const*) vmovaps [rsp+0A8h+var_A8], xmm0 vmovups xmm0, xmmword ptr [r15] lea rdi, [rsp+0A8h+var_78]; this vmovaps xmmword ptr [rdi], xmm0 vmovsd xmm0, cs:qword_4A5E0 vaddsd xmm0, xmm0, qword ptr [r15+10h] vmovsd qword ptr [rdi+10h], xmm0 mov rsi, r14; double * call _ZN6mujoco6plugin3sdf12_GLOBAL__N_18distanceEPKdS4__0; mujoco::plugin::sdf::`anonymous namespace'::distance(double const*,double const*) vmovapd xmm1, [rsp+0A8h+var_98] vunpcklpd xmm1, xmm1, [rsp+0A8h+var_A8] vmovapd xmm3, [rsp+0A8h+var_88] vmovddup xmm2, xmm3 vsubpd xmm1, xmm1, xmm2 vmovddup xmm2, cs:qword_4A5E0 vdivpd xmm1, xmm1, xmm2 vmovupd xmmword ptr [rbx], xmm1 vsubsd xmm0, xmm0, xmm3 vdivsd xmm0, xmm0, cs:qword_4A5E0 vmovsd qword ptr [rbx+10h], xmm0 add rsp, 90h pop rbx pop r14 pop r15 retn
void mujoco::plugin::sdf::Bowl::Gradient( mujoco::plugin::sdf::Bowl *this, double *a2, mujoco::plugin::sdf::_anonymous_namespace_ *a3) { const double *v11; // rdx const double *v18; // rdx const double *v24; // rdx _BYTE v38[32]; // [rsp+30h] [rbp-78h] BYREF _BYTE v39[32]; // [rsp+50h] [rbp-58h] BYREF _BYTE v40[56]; // [rsp+70h] [rbp-38h] BYREF _R15 = a3; _RBX = a2; _XMM0 = mujoco::plugin::sdf::`anonymous namespace'::distance(a3, (const double *)this, (const double *)a3); __asm { vmovaps [rsp+0A8h+var_88], xmm0 vmovsd xmm0, cs:qword_4A5E0 vaddsd xmm0, xmm0, qword ptr [r15] } _RDI = v40; __asm { vmovsd qword ptr [rdi], xmm0 vmovups xmm0, xmmword ptr [r15+8] vmovups xmmword ptr [rdi+8], xmm0 } _XMM0 = mujoco::plugin::sdf::`anonymous namespace'::distance( (mujoco::plugin::sdf::_anonymous_namespace_ *)v40, (const double *)this, v11); __asm { vmovsd xmm1, qword ptr [r15] } _RDI = v39; __asm { vmovsd qword ptr [rdi], xmm1 vmovsd xmm1, cs:qword_4A5E0 vaddsd xmm1, xmm1, qword ptr [r15+8] vmovaps [rsp+0A8h+var_98], xmm0 vmovsd qword ptr [rdi+8], xmm1 vmovsd xmm0, qword ptr [r15+10h] vmovsd qword ptr [rdi+10h], xmm0 } _XMM0 = mujoco::plugin::sdf::`anonymous namespace'::distance( (mujoco::plugin::sdf::_anonymous_namespace_ *)v39, (const double *)this, v18); __asm { vmovaps [rsp+0A8h+var_A8], xmm0 vmovups xmm0, xmmword ptr [r15] } _RDI = v38; __asm { vmovaps xmmword ptr [rdi], xmm0 vmovsd xmm0, cs:qword_4A5E0 vaddsd xmm0, xmm0, qword ptr [r15+10h] vmovsd qword ptr [rdi+10h], xmm0 } _XMM0 = mujoco::plugin::sdf::`anonymous namespace'::distance( (mujoco::plugin::sdf::_anonymous_namespace_ *)v38, (const double *)this, v24); __asm { vmovapd xmm1, [rsp+0A8h+var_98] vunpcklpd xmm1, xmm1, [rsp+0A8h+var_A8] vmovapd xmm3, [rsp+0A8h+var_88] vmovddup xmm2, xmm3 vsubpd xmm1, xmm1, xmm2 vmovddup xmm2, cs:qword_4A5E0 vdivpd xmm1, xmm1, xmm2 vmovupd xmmword ptr [rbx], xmm1 vsubsd xmm0, xmm0, xmm3 vdivsd xmm0, xmm0, cs:qword_4A5E0 vmovsd qword ptr [rbx+10h], xmm0 } }
Gradient: PUSH R15 PUSH R14 PUSH RBX SUB RSP,0x90 MOV R15,RDX MOV RBX,RSI MOV R14,RDI MOV RDI,RDX MOV RSI,R14 CALL 0x0010d5fa VMOVAPS xmmword ptr [RSP + 0x20],XMM0 VMOVSD XMM0,qword ptr [0x0014a5e0] VADDSD XMM0,XMM0,qword ptr [R15] LEA RDI,[RSP + 0x70] VMOVSD qword ptr [RDI],XMM0 VMOVUPS XMM0,xmmword ptr [R15 + 0x8] VMOVUPS xmmword ptr [RDI + 0x8],XMM0 MOV RSI,R14 CALL 0x0010d5fa VMOVSD XMM1,qword ptr [R15] LEA RDI,[RSP + 0x50] VMOVSD qword ptr [RDI],XMM1 VMOVSD XMM1,qword ptr [0x0014a5e0] VADDSD XMM1,XMM1,qword ptr [R15 + 0x8] VMOVAPS xmmword ptr [RSP + 0x10],XMM0 VMOVSD qword ptr [RDI + 0x8],XMM1 VMOVSD XMM0,qword ptr [R15 + 0x10] VMOVSD qword ptr [RDI + 0x10],XMM0 MOV RSI,R14 CALL 0x0010d5fa VMOVAPS xmmword ptr [RSP],XMM0 VMOVUPS XMM0,xmmword ptr [R15] LEA RDI,[RSP + 0x30] VMOVAPS xmmword ptr [RDI],XMM0 VMOVSD XMM0,qword ptr [0x0014a5e0] VADDSD XMM0,XMM0,qword ptr [R15 + 0x10] VMOVSD qword ptr [RDI + 0x10],XMM0 MOV RSI,R14 CALL 0x0010d5fa VMOVAPD XMM1,xmmword ptr [RSP + 0x10] VUNPCKLPD XMM1,XMM1,xmmword ptr [RSP] VMOVAPD XMM3,xmmword ptr [RSP + 0x20] VMOVDDUP XMM2,XMM3 VSUBPD XMM1,XMM1,XMM2 VMOVDDUP XMM2,qword ptr [0x0014a5e0] VDIVPD XMM1,XMM1,XMM2 VMOVUPD xmmword ptr [RBX],XMM1 VSUBSD XMM0,XMM0,XMM3 VDIVSD XMM0,XMM0,qword ptr [0x0014a5e0] VMOVSD qword ptr [RBX + 0x10],XMM0 ADD RSP,0x90 POP RBX POP R14 POP R15 RET
/* mujoco::plugin::sdf::Bowl::Gradient(double*, double const*) const */ void __thiscall mujoco::plugin::sdf::Bowl::Gradient(Bowl *this,double *param_1,double *param_2) { int1 auVar1 [16]; int1 auVar2 [16]; double dVar3; int8 uVar4; int8 uVar5; double dVar6; int8 extraout_XMM0_Qb; int8 extraout_XMM0_Qb_00; int1 auVar7 [16]; int1 auVar8 [16]; double local_78; double dStack_70; double local_68; double local_58; double local_50; double local_48; double local_38; double local_30; double dStack_28; dVar3 = (double)(anonymous_namespace)::distance(param_2,(double *)this); local_38 = DAT_0014a5e0 + *param_2; local_30 = param_2[1]; dStack_28 = param_2[2]; uVar4 = (anonymous_namespace)::distance(&local_38,(double *)this); local_58 = *param_2; local_50 = DAT_0014a5e0 + param_2[1]; local_48 = param_2[2]; uVar5 = (anonymous_namespace)::distance(&local_58,(double *)this); local_78 = *param_2; dStack_70 = param_2[1]; local_68 = DAT_0014a5e0 + param_2[2]; dVar6 = (double)(anonymous_namespace)::distance(&local_78,(double *)this); auVar2._8_8_ = extraout_XMM0_Qb; auVar2._0_8_ = uVar4; auVar1._8_8_ = extraout_XMM0_Qb_00; auVar1._0_8_ = uVar5; auVar1 = vunpcklpd_avx(auVar2,auVar1); auVar7._8_8_ = dVar3; auVar7._0_8_ = dVar3; auVar1 = vsubpd_avx(auVar1,auVar7); auVar8._8_8_ = DAT_0014a5e0; auVar8._0_8_ = DAT_0014a5e0; auVar1 = vdivpd_avx(auVar1,auVar8); *(int1 (*) [16])param_1 = auVar1; param_1[2] = (dVar6 - dVar3) / DAT_0014a5e0; return; }
20,549
void OpenSubdiv::v3_6_0::Sdc::Scheme<(OpenSubdiv::v3_6_0::Sdc::SchemeType)2>::assignSmoothLimitTangentMasks<OpenSubdiv::v3_6_0::Far::LoopLimits<float>::LimitVertex, OpenSubdiv::v3_6_0::Far::LoopLimits<float>::LimitMask>(OpenSubdiv::v3_6_0::Far::LoopLimits<float>::LimitVertex const&, OpenSubdiv::v3_6_0::Far::LoopLimits<float>::LimitMask&, OpenSubdiv::v3_6_0::Far::LoopLimits<float>::LimitMask&) const
NVIDIA-RTX[P]OSD-Lite/opensubdiv/far/../sdc/loopScheme.h
inline void Scheme<SCHEME_LOOP>::assignSmoothLimitTangentMasks(VERTEX const& vertex, MASK& tan1Mask, MASK& tan2Mask) const { typedef typename MASK::Weight Weight; int valence = vertex.GetNumFaces(); tan1Mask.SetNumVertexWeights(1); tan1Mask.SetNumEdgeWeights(valence); tan1Mask.SetNumFaceWeights(0); tan1Mask.SetFaceWeightsForFaceCenters(false); tan2Mask.SetNumVertexWeights(1); tan2Mask.SetNumEdgeWeights(valence); tan2Mask.SetNumFaceWeights(0); tan2Mask.SetFaceWeightsForFaceCenters(false); tan1Mask.VertexWeight(0) = 0.0f; tan2Mask.VertexWeight(0) = 0.0f; if (valence == 6) { static Weight const Root3by2 = (Weight)(0.5 * 1.73205080756887729352); tan1Mask.EdgeWeight(0) = 1.0f; tan1Mask.EdgeWeight(1) = 0.5f; tan1Mask.EdgeWeight(2) = -0.5f; tan1Mask.EdgeWeight(3) = -1.0f; tan1Mask.EdgeWeight(4) = -0.5f; tan1Mask.EdgeWeight(5) = 0.5f; tan2Mask.EdgeWeight(0) = 0.0f; tan2Mask.EdgeWeight(1) = Root3by2; tan2Mask.EdgeWeight(2) = Root3by2; tan2Mask.EdgeWeight(3) = 0.0f; tan2Mask.EdgeWeight(4) = -Root3by2; tan2Mask.EdgeWeight(5) = -Root3by2; } else { double alpha = 2.0f * std::numbers::pi / valence; for (int i = 0; i < valence; ++i) { double alphaI = alpha * i; tan1Mask.EdgeWeight(i) = (Weight) std::cos(alphaI); tan2Mask.EdgeWeight(i) = (Weight) std::sin(alphaI); } } }
O2
c
void OpenSubdiv::v3_6_0::Sdc::Scheme<(OpenSubdiv::v3_6_0::Sdc::SchemeType)2>::assignSmoothLimitTangentMasks<OpenSubdiv::v3_6_0::Far::LoopLimits<float>::LimitVertex, OpenSubdiv::v3_6_0::Far::LoopLimits<float>::LimitMask>(OpenSubdiv::v3_6_0::Far::LoopLimits<float>::LimitVertex const&, OpenSubdiv::v3_6_0::Far::LoopLimits<float>::LimitMask&, OpenSubdiv::v3_6_0::Far::LoopLimits<float>::LimitMask&) const: pushq %r15 pushq %r14 pushq %r12 pushq %rbx subq $0x18, %rsp movq %rcx, %rbx movl (%rsi), %r15d movl %r15d, 0x8(%rdx) movl %r15d, 0x8(%rcx) movq (%rdx), %rcx andl $0x0, (%rcx) movq (%rbx), %rax andl $0x0, (%rax) cmpl $0x6, %r15d jne 0x6cb95 movaps 0x53580(%rip), %xmm0 # 0xc00e0 movups %xmm0, 0x4(%rcx) movsd 0x53584(%rip), %xmm0 # 0xc00f0 movsd %xmm0, 0x14(%rcx) movaps 0x53588(%rip), %xmm0 # 0xc0100 movups %xmm0, 0x4(%rax) movsd 0x5358c(%rip), %xmm0 # 0xc0110 movsd %xmm0, 0x14(%rax) addq $0x18, %rsp popq %rbx popq %r12 popq %r14 popq %r15 retq movq %rdx, %r14 cvtsi2sd %r15d, %xmm0 movsd 0x51953(%rip), %xmm1 # 0xbe4f8 divsd %xmm0, %xmm1 movsd %xmm1, 0x8(%rsp) xorl %r12d, %r12d testl %r15d, %r15d cmovlel %r12d, %r15d cmpq %r12, %r15 je 0x6cb89 cvtsi2sd %r12d, %xmm0 mulsd 0x8(%rsp), %xmm0 movsd %xmm0, 0x10(%rsp) callq 0x557b0 cvtsd2ss %xmm0, %xmm0 movq (%r14), %rax movss %xmm0, 0x4(%rax,%r12,4) movsd 0x10(%rsp), %xmm0 callq 0x4f860 cvtsd2ss %xmm0, %xmm0 movq (%rbx), %rax movss %xmm0, 0x4(%rax,%r12,4) incq %r12 jmp 0x6cbb9
_ZNK10OpenSubdiv6v3_6_03Sdc6SchemeILNS1_10SchemeTypeE2EE29assignSmoothLimitTangentMasksINS0_3Far10LoopLimitsIfE11LimitVertexENS8_9LimitMaskEEEvRKT_RT0_SF_: push r15 push r14 push r12 push rbx sub rsp, 18h mov rbx, rcx mov r15d, [rsi] mov [rdx+8], r15d mov [rcx+8], r15d mov rcx, [rdx] and dword ptr [rcx], 0 mov rax, [rbx] and dword ptr [rax], 0 cmp r15d, 6 jnz short loc_6CB95 movaps xmm0, cs:xmmword_C00E0 movups xmmword ptr [rcx+4], xmm0 movsd xmm0, cs:qword_C00F0 movsd qword ptr [rcx+14h], xmm0 movaps xmm0, cs:xmmword_C0100 movups xmmword ptr [rax+4], xmm0 movsd xmm0, cs:qword_C0110 movsd qword ptr [rax+14h], xmm0 loc_6CB89: add rsp, 18h pop rbx pop r12 pop r14 pop r15 retn loc_6CB95: mov r14, rdx cvtsi2sd xmm0, r15d movsd xmm1, cs:qword_BE4F8 divsd xmm1, xmm0 movsd [rsp+38h+var_30], xmm1 xor r12d, r12d test r15d, r15d cmovle r15d, r12d loc_6CBB9: cmp r15, r12 jz short loc_6CB89 cvtsi2sd xmm0, r12d mulsd xmm0, [rsp+38h+var_30] movsd [rsp+38h+var_28], xmm0 call _cos cvtsd2ss xmm0, xmm0 mov rax, [r14] movss dword ptr [rax+r12*4+4], xmm0 movsd xmm0, [rsp+38h+var_28] call _sin cvtsd2ss xmm0, xmm0 mov rax, [rbx] movss dword ptr [rax+r12*4+4], xmm0 inc r12 jmp short loc_6CBB9
_DWORD * OpenSubdiv::v3_6_0::Sdc::Scheme<(OpenSubdiv::v3_6_0::Sdc::SchemeType)2>::assignSmoothLimitTangentMasks<OpenSubdiv::v3_6_0::Far::LoopLimits<float>::LimitVertex,OpenSubdiv::v3_6_0::Far::LoopLimits<float>::LimitMask>( long long a1, unsigned int *a2, long long a3, long long a4) { long long v5; // r15 _DWORD *v6; // rcx _DWORD *result; // rax long long v9; // r12 float v10; // xmm0_4 float v11; // xmm0_4 double v12; // [rsp+8h] [rbp-30h] v5 = *a2; *(_DWORD *)(a3 + 8) = v5; *(_DWORD *)(a4 + 8) = v5; v6 = *(_DWORD **)a3; **(_DWORD **)a3 = 0; result = *(_DWORD **)a4; **(_DWORD **)a4 = 0; if ( (_DWORD)v5 == 6 ) { *(_OWORD *)(v6 + 1) = xmmword_C00E0; *(_QWORD *)(v6 + 5) = 0x3F000000BF000000LL; *(_OWORD *)(result + 1) = xmmword_C0100; *(_QWORD *)(result + 5) = 0xBF5DB3D7BF5DB3D7LL; } else { v12 = 6.283185307179586 / (double)(int)v5; v9 = 0LL; if ( (int)v5 <= 0 ) v5 = 0LL; while ( v5 != v9 ) { v10 = cos((double)(int)v9 * v12); *(float *)(*(_QWORD *)a3 + 4 * v9 + 4) = v10; v11 = sin((double)(int)v9 * v12); result = *(_DWORD **)a4; *(float *)(*(_QWORD *)a4 + 4 * v9++ + 4) = v11; } } return result; }
assignSmoothLimitTangentMasks<OpenSubdiv::v3_6_0::Far::LoopLimits<float>::LimitVertex,OpenSubdiv::v3_6_0::Far::LoopLimits<float>::LimitMask>: PUSH R15 PUSH R14 PUSH R12 PUSH RBX SUB RSP,0x18 MOV RBX,RCX MOV R15D,dword ptr [RSI] MOV dword ptr [RDX + 0x8],R15D MOV dword ptr [RCX + 0x8],R15D MOV RCX,qword ptr [RDX] AND dword ptr [RCX],0x0 MOV RAX,qword ptr [RBX] AND dword ptr [RAX],0x0 CMP R15D,0x6 JNZ 0x0016cb95 MOVAPS XMM0,xmmword ptr [0x001c00e0] MOVUPS xmmword ptr [RCX + 0x4],XMM0 MOVSD XMM0,qword ptr [0x001c00f0] MOVSD qword ptr [RCX + 0x14],XMM0 MOVAPS XMM0,xmmword ptr [0x001c0100] MOVUPS xmmword ptr [RAX + 0x4],XMM0 MOVSD XMM0,qword ptr [0x001c0110] MOVSD qword ptr [RAX + 0x14],XMM0 LAB_0016cb89: ADD RSP,0x18 POP RBX POP R12 POP R14 POP R15 RET LAB_0016cb95: MOV R14,RDX CVTSI2SD XMM0,R15D MOVSD XMM1,qword ptr [0x001be4f8] DIVSD XMM1,XMM0 MOVSD qword ptr [RSP + 0x8],XMM1 XOR R12D,R12D TEST R15D,R15D CMOVLE R15D,R12D LAB_0016cbb9: CMP R15,R12 JZ 0x0016cb89 CVTSI2SD XMM0,R12D MULSD XMM0,qword ptr [RSP + 0x8] MOVSD qword ptr [RSP + 0x10],XMM0 CALL 0x001557b0 CVTSD2SS XMM0,XMM0 MOV RAX,qword ptr [R14] MOVSS dword ptr [RAX + R12*0x4 + 0x4],XMM0 MOVSD XMM0,qword ptr [RSP + 0x10] CALL 0x0014f860 CVTSD2SS XMM0,XMM0 MOV RAX,qword ptr [RBX] MOVSS dword ptr [RAX + R12*0x4 + 0x4],XMM0 INC R12 JMP 0x0016cbb9
/* WARNING: Globals starting with '_' overlap smaller symbols at the same address */ /* void OpenSubdiv::v3_6_0::Sdc::Scheme<(OpenSubdiv::v3_6_0::Sdc::SchemeType)2>::assignSmoothLimitTangentMasks<OpenSubdiv::v3_6_0::Far::LoopLimits<float>::LimitVertex, OpenSubdiv::v3_6_0::Far::LoopLimits<float>::LimitMask>(OpenSubdiv::v3_6_0::Far::LoopLimits<float>::LimitVertex const&, OpenSubdiv::v3_6_0::Far::LoopLimits<float>::LimitMask&, OpenSubdiv::v3_6_0::Far::LoopLimits<float>::LimitMask&) const */ void __thiscall OpenSubdiv::v3_6_0::Sdc::Scheme<(OpenSubdiv::v3_6_0::Sdc::SchemeType)2>:: assignSmoothLimitTangentMasks<OpenSubdiv::v3_6_0::Far::LoopLimits<float>::LimitVertex,OpenSubdiv::v3_6_0::Far::LoopLimits<float>::LimitMask> (Scheme<(OpenSubdiv::v3_6_0::Sdc::SchemeType)2> *this,LimitVertex *param_1, LimitMask *param_2,LimitMask *param_3) { uint uVar1; int4 *puVar2; int4 *puVar3; double dVar4; double dVar5; int8 uVar6; ulong uVar7; ulong uVar8; double dVar9; uVar1 = *(uint *)param_1; *(uint *)(param_2 + 8) = uVar1; *(uint *)(param_3 + 8) = uVar1; puVar2 = *(int4 **)param_2; *puVar2 = 0; puVar3 = *(int4 **)param_3; *puVar3 = 0; uVar6 = _UNK_001c00e8; if (uVar1 == 6) { *(int8 *)(puVar2 + 1) = _DAT_001c00e0; *(int8 *)(puVar2 + 3) = uVar6; *(int8 *)(puVar2 + 5) = DAT_001c00f0; uVar6 = _UNK_001c0108; *(int8 *)(puVar3 + 1) = _DAT_001c0100; *(int8 *)(puVar3 + 3) = uVar6; *(int8 *)(puVar3 + 5) = DAT_001c0110; } else { dVar9 = DAT_001be4f8 / (double)(int)uVar1; uVar7 = 0; uVar8 = (ulong)uVar1; if ((int)uVar1 < 1) { uVar8 = uVar7; } for (; uVar8 != uVar7; uVar7 = uVar7 + 1) { dVar4 = (double)(int)uVar7 * dVar9; dVar5 = cos(dVar4); *(float *)(*(long *)param_2 + 4 + uVar7 * 4) = (float)dVar5; dVar4 = sin(dVar4); *(float *)(*(long *)param_3 + 4 + uVar7 * 4) = (float)dVar4; } } return; }
20,550
TinyDecoder::init_params(ggml_allocr*, ggml_context*)
7CodeWizard[P]stablediffusion/tae.hpp
void init_params(ggml_allocr* alloc, ggml_context* ctx) { conv_input_w = ggml_new_tensor_4d(ctx, GGML_TYPE_F16, 3, 3, z_channels, channels); conv_input_b = ggml_new_tensor_1d(ctx, GGML_TYPE_F32, channels); conv_1_w = ggml_new_tensor_4d(ctx, GGML_TYPE_F16, 3, 3, channels, channels); conv_2_w = ggml_new_tensor_4d(ctx, GGML_TYPE_F16, 3, 3, channels, channels); conv_3_w = ggml_new_tensor_4d(ctx, GGML_TYPE_F16, 3, 3, channels, channels); conv_final_w = ggml_new_tensor_4d(ctx, GGML_TYPE_F16, 3, 3, channels, output_channels); conv_final_b = ggml_new_tensor_1d(ctx, GGML_TYPE_F32, output_channels); for (int i = 0; i < num_blocks; i++) { input_blocks[i].init_params(ctx); middle_blocks[i].init_params(ctx); output_blocks[i].init_params(ctx); } final_block.init_params(ctx); }
O0
cpp
TinyDecoder::init_params(ggml_allocr*, ggml_context*): subq $0x28, %rsp movq %rdi, 0x20(%rsp) movq %rsi, 0x18(%rsp) movq %rdx, 0x10(%rsp) movq 0x20(%rsp), %rax movq %rax, (%rsp) movq 0x10(%rsp), %rdi movslq (%rax), %r8 movslq 0x4(%rax), %r9 movl $0x1, %esi movl $0x3, %ecx movq %rcx, %rdx callq 0x11c960 movq %rax, %rcx movq (%rsp), %rax movq %rcx, 0x10(%rax) movq 0x10(%rsp), %rdi movslq 0x4(%rax), %rdx xorl %esi, %esi callq 0x11c880 movq %rax, %rcx movq (%rsp), %rax movq %rcx, 0x18(%rax) movq 0x10(%rsp), %rdi movslq 0x4(%rax), %r8 movslq 0x4(%rax), %r9 movl $0x1, %esi movl $0x3, %ecx movq %rcx, %rdx callq 0x11c960 movq %rax, %rcx movq (%rsp), %rax movq %rcx, 0xe0(%rax) movq 0x10(%rsp), %rdi movslq 0x4(%rax), %r8 movslq 0x4(%rax), %r9 movl $0x1, %esi movl $0x3, %ecx movq %rcx, %rdx callq 0x11c960 movq %rax, %rcx movq (%rsp), %rax movq %rcx, 0x1a8(%rax) movq 0x10(%rsp), %rdi movslq 0x4(%rax), %r8 movslq 0x4(%rax), %r9 movl $0x1, %esi movl $0x3, %ecx movq %rcx, %rdx callq 0x11c960 movq %rax, %rcx movq (%rsp), %rax movq %rcx, 0x270(%rax) movq 0x10(%rsp), %rdi movslq 0x4(%rax), %r8 movslq 0x8(%rax), %r9 movl $0x1, %esi movl $0x3, %ecx movq %rcx, %rdx callq 0x11c960 movq %rax, %rcx movq (%rsp), %rax movq %rcx, 0x2b8(%rax) movq 0x10(%rsp), %rdi movslq 0x8(%rax), %rdx xorl %esi, %esi callq 0x11c880 movq %rax, %rcx movq (%rsp), %rax movq %rcx, 0x2c0(%rax) movl $0x0, 0xc(%rsp) movq (%rsp), %rcx movl 0xc(%rsp), %eax cmpl 0xc(%rcx), %eax jge 0x6bd24 movq (%rsp), %rdi addq $0x20, %rdi movslq 0xc(%rsp), %rax shlq $0x6, %rax addq %rax, %rdi movq 0x10(%rsp), %rsi callq 0x6bf10 movq (%rsp), %rdi addq $0xe8, %rdi movslq 0xc(%rsp), %rax shlq $0x6, %rax addq %rax, %rdi movq 0x10(%rsp), %rsi callq 0x6bf10 movq (%rsp), %rdi addq $0x1b0, %rdi # imm = 0x1B0 movslq 0xc(%rsp), %rax shlq $0x6, %rax addq %rax, %rdi movq 0x10(%rsp), %rsi callq 0x6bf10 movl 0xc(%rsp), %eax addl $0x1, %eax movl %eax, 0xc(%rsp) jmp 0x6bcaa movq (%rsp), %rdi addq $0x278, %rdi # imm = 0x278 movq 0x10(%rsp), %rsi callq 0x6bf10 addq $0x28, %rsp retq nop
_ZN11TinyDecoder11init_paramsEP11ggml_allocrP12ggml_context: sub rsp, 28h mov [rsp+28h+var_8], rdi mov [rsp+28h+var_10], rsi mov [rsp+28h+var_18], rdx mov rax, [rsp+28h+var_8] mov [rsp+28h+var_28], rax mov rdi, [rsp+28h+var_18] movsxd r8, dword ptr [rax] movsxd r9, dword ptr [rax+4] mov esi, 1 mov ecx, 3 mov rdx, rcx call ggml_new_tensor_4d mov rcx, rax mov rax, [rsp+28h+var_28] mov [rax+10h], rcx mov rdi, [rsp+28h+var_18] movsxd rdx, dword ptr [rax+4] xor esi, esi call ggml_new_tensor_1d mov rcx, rax mov rax, [rsp+28h+var_28] mov [rax+18h], rcx mov rdi, [rsp+28h+var_18] movsxd r8, dword ptr [rax+4] movsxd r9, dword ptr [rax+4] mov esi, 1 mov ecx, 3 mov rdx, rcx call ggml_new_tensor_4d mov rcx, rax mov rax, [rsp+28h+var_28] mov [rax+0E0h], rcx mov rdi, [rsp+28h+var_18] movsxd r8, dword ptr [rax+4] movsxd r9, dword ptr [rax+4] mov esi, 1 mov ecx, 3 mov rdx, rcx call ggml_new_tensor_4d mov rcx, rax mov rax, [rsp+28h+var_28] mov [rax+1A8h], rcx mov rdi, [rsp+28h+var_18] movsxd r8, dword ptr [rax+4] movsxd r9, dword ptr [rax+4] mov esi, 1 mov ecx, 3 mov rdx, rcx call ggml_new_tensor_4d mov rcx, rax mov rax, [rsp+28h+var_28] mov [rax+270h], rcx mov rdi, [rsp+28h+var_18] movsxd r8, dword ptr [rax+4] movsxd r9, dword ptr [rax+8] mov esi, 1 mov ecx, 3 mov rdx, rcx call ggml_new_tensor_4d mov rcx, rax mov rax, [rsp+28h+var_28] mov [rax+2B8h], rcx mov rdi, [rsp+28h+var_18] movsxd rdx, dword ptr [rax+8] xor esi, esi call ggml_new_tensor_1d mov rcx, rax mov rax, [rsp+28h+var_28] mov [rax+2C0h], rcx mov [rsp+28h+var_1C], 0 loc_6BCAA: mov rcx, [rsp+28h+var_28] mov eax, [rsp+28h+var_1C] cmp eax, [rcx+0Ch] jge short loc_6BD24 mov rdi, [rsp+28h+var_28] add rdi, 20h ; ' ' movsxd rax, [rsp+28h+var_1C] shl rax, 6 add rdi, rax mov rsi, [rsp+28h+var_18] call _ZN8TAEBlock11init_paramsEP12ggml_context; TAEBlock::init_params(ggml_context *) mov rdi, [rsp+28h+var_28] add rdi, 0E8h movsxd rax, [rsp+28h+var_1C] shl rax, 6 add rdi, rax mov rsi, [rsp+28h+var_18] call _ZN8TAEBlock11init_paramsEP12ggml_context; TAEBlock::init_params(ggml_context *) mov rdi, [rsp+28h+var_28] add rdi, 1B0h movsxd rax, [rsp+28h+var_1C] shl rax, 6 add rdi, rax mov rsi, [rsp+28h+var_18] call _ZN8TAEBlock11init_paramsEP12ggml_context; TAEBlock::init_params(ggml_context *) mov eax, [rsp+28h+var_1C] add eax, 1 mov [rsp+28h+var_1C], eax jmp short loc_6BCAA loc_6BD24: mov rdi, [rsp+28h+var_28] add rdi, 278h mov rsi, [rsp+28h+var_18] call _ZN8TAEBlock11init_paramsEP12ggml_context; TAEBlock::init_params(ggml_context *) add rsp, 28h retn
long long TinyDecoder::init_params(int *a1, long long a2, long long a3) { int i; // [rsp+Ch] [rbp-1Ch] *((_QWORD *)a1 + 2) = ggml_new_tensor_4d(a3, 1LL, 3LL, 3LL, *a1, a1[1]); *((_QWORD *)a1 + 3) = ggml_new_tensor_1d(a3, 0LL, a1[1]); *((_QWORD *)a1 + 28) = ggml_new_tensor_4d(a3, 1LL, 3LL, 3LL, a1[1], a1[1]); *((_QWORD *)a1 + 53) = ggml_new_tensor_4d(a3, 1LL, 3LL, 3LL, a1[1], a1[1]); *((_QWORD *)a1 + 78) = ggml_new_tensor_4d(a3, 1LL, 3LL, 3LL, a1[1], a1[1]); *((_QWORD *)a1 + 87) = ggml_new_tensor_4d(a3, 1LL, 3LL, 3LL, a1[1], a1[2]); *((_QWORD *)a1 + 88) = ggml_new_tensor_1d(a3, 0LL, a1[2]); for ( i = 0; i < a1[3]; ++i ) { TAEBlock::init_params(&a1[16 * (long long)i + 8], a3); TAEBlock::init_params(&a1[16 * (long long)i + 58], a3); TAEBlock::init_params(&a1[16 * (long long)i + 108], a3); } return TAEBlock::init_params(a1 + 158, a3); }
init_params: SUB RSP,0x28 MOV qword ptr [RSP + 0x20],RDI MOV qword ptr [RSP + 0x18],RSI MOV qword ptr [RSP + 0x10],RDX MOV RAX,qword ptr [RSP + 0x20] MOV qword ptr [RSP],RAX MOV RDI,qword ptr [RSP + 0x10] MOVSXD R8,dword ptr [RAX] MOVSXD R9,dword ptr [RAX + 0x4] MOV ESI,0x1 MOV ECX,0x3 MOV RDX,RCX CALL 0x0021c960 MOV RCX,RAX MOV RAX,qword ptr [RSP] MOV qword ptr [RAX + 0x10],RCX MOV RDI,qword ptr [RSP + 0x10] MOVSXD RDX,dword ptr [RAX + 0x4] XOR ESI,ESI CALL 0x0021c880 MOV RCX,RAX MOV RAX,qword ptr [RSP] MOV qword ptr [RAX + 0x18],RCX MOV RDI,qword ptr [RSP + 0x10] MOVSXD R8,dword ptr [RAX + 0x4] MOVSXD R9,dword ptr [RAX + 0x4] MOV ESI,0x1 MOV ECX,0x3 MOV RDX,RCX CALL 0x0021c960 MOV RCX,RAX MOV RAX,qword ptr [RSP] MOV qword ptr [RAX + 0xe0],RCX MOV RDI,qword ptr [RSP + 0x10] MOVSXD R8,dword ptr [RAX + 0x4] MOVSXD R9,dword ptr [RAX + 0x4] MOV ESI,0x1 MOV ECX,0x3 MOV RDX,RCX CALL 0x0021c960 MOV RCX,RAX MOV RAX,qword ptr [RSP] MOV qword ptr [RAX + 0x1a8],RCX MOV RDI,qword ptr [RSP + 0x10] MOVSXD R8,dword ptr [RAX + 0x4] MOVSXD R9,dword ptr [RAX + 0x4] MOV ESI,0x1 MOV ECX,0x3 MOV RDX,RCX CALL 0x0021c960 MOV RCX,RAX MOV RAX,qword ptr [RSP] MOV qword ptr [RAX + 0x270],RCX MOV RDI,qword ptr [RSP + 0x10] MOVSXD R8,dword ptr [RAX + 0x4] MOVSXD R9,dword ptr [RAX + 0x8] MOV ESI,0x1 MOV ECX,0x3 MOV RDX,RCX CALL 0x0021c960 MOV RCX,RAX MOV RAX,qword ptr [RSP] MOV qword ptr [RAX + 0x2b8],RCX MOV RDI,qword ptr [RSP + 0x10] MOVSXD RDX,dword ptr [RAX + 0x8] XOR ESI,ESI CALL 0x0021c880 MOV RCX,RAX MOV RAX,qword ptr [RSP] MOV qword ptr [RAX + 0x2c0],RCX MOV dword ptr [RSP + 0xc],0x0 LAB_0016bcaa: MOV RCX,qword ptr [RSP] MOV EAX,dword ptr [RSP + 0xc] CMP EAX,dword ptr [RCX + 0xc] JGE 0x0016bd24 MOV RDI,qword ptr [RSP] ADD RDI,0x20 MOVSXD RAX,dword ptr [RSP + 0xc] SHL RAX,0x6 ADD RDI,RAX MOV RSI,qword ptr [RSP + 0x10] CALL 0x0016bf10 MOV RDI,qword ptr [RSP] ADD RDI,0xe8 MOVSXD RAX,dword ptr [RSP + 0xc] SHL RAX,0x6 ADD RDI,RAX MOV RSI,qword ptr [RSP + 0x10] CALL 0x0016bf10 MOV RDI,qword ptr [RSP] ADD RDI,0x1b0 MOVSXD RAX,dword ptr [RSP + 0xc] SHL RAX,0x6 ADD RDI,RAX MOV RSI,qword ptr [RSP + 0x10] CALL 0x0016bf10 MOV EAX,dword ptr [RSP + 0xc] ADD EAX,0x1 MOV dword ptr [RSP + 0xc],EAX JMP 0x0016bcaa LAB_0016bd24: MOV RDI,qword ptr [RSP] ADD RDI,0x278 MOV RSI,qword ptr [RSP + 0x10] CALL 0x0016bf10 ADD RSP,0x28 RET
/* TinyDecoder::init_params(ggml_allocr*, ggml_context*) */ void __thiscall TinyDecoder::init_params(TinyDecoder *this,ggml_allocr *param_1,ggml_context *param_2) { int8 uVar1; int local_1c; uVar1 = ggml_new_tensor_4d(param_2,1,3,3,(long)*(int *)this,(long)*(int *)(this + 4)); *(int8 *)(this + 0x10) = uVar1; uVar1 = ggml_new_tensor_1d(param_2,0,(long)*(int *)(this + 4)); *(int8 *)(this + 0x18) = uVar1; uVar1 = ggml_new_tensor_4d(param_2,1,3,3,(long)*(int *)(this + 4),(long)*(int *)(this + 4)); *(int8 *)(this + 0xe0) = uVar1; uVar1 = ggml_new_tensor_4d(param_2,1,3,3,(long)*(int *)(this + 4),(long)*(int *)(this + 4)); *(int8 *)(this + 0x1a8) = uVar1; uVar1 = ggml_new_tensor_4d(param_2,1,3,3,(long)*(int *)(this + 4),(long)*(int *)(this + 4)); *(int8 *)(this + 0x270) = uVar1; uVar1 = ggml_new_tensor_4d(param_2,1,3,3,(long)*(int *)(this + 4),(long)*(int *)(this + 8)); *(int8 *)(this + 0x2b8) = uVar1; uVar1 = ggml_new_tensor_1d(param_2,0,(long)*(int *)(this + 8)); *(int8 *)(this + 0x2c0) = uVar1; for (local_1c = 0; local_1c < *(int *)(this + 0xc); local_1c = local_1c + 1) { TAEBlock::init_params((TAEBlock *)(this + (long)local_1c * 0x40 + 0x20),param_2); TAEBlock::init_params((TAEBlock *)(this + (long)local_1c * 0x40 + 0xe8),param_2); TAEBlock::init_params((TAEBlock *)(this + (long)local_1c * 0x40 + 0x1b0),param_2); } TAEBlock::init_params((TAEBlock *)(this + 0x278),param_2); return; }
20,551
TinyDecoder::init_params(ggml_allocr*, ggml_context*)
7CodeWizard[P]stablediffusion/tae.hpp
void init_params(ggml_allocr* alloc, ggml_context* ctx) { conv_input_w = ggml_new_tensor_4d(ctx, GGML_TYPE_F16, 3, 3, z_channels, channels); conv_input_b = ggml_new_tensor_1d(ctx, GGML_TYPE_F32, channels); conv_1_w = ggml_new_tensor_4d(ctx, GGML_TYPE_F16, 3, 3, channels, channels); conv_2_w = ggml_new_tensor_4d(ctx, GGML_TYPE_F16, 3, 3, channels, channels); conv_3_w = ggml_new_tensor_4d(ctx, GGML_TYPE_F16, 3, 3, channels, channels); conv_final_w = ggml_new_tensor_4d(ctx, GGML_TYPE_F16, 3, 3, channels, output_channels); conv_final_b = ggml_new_tensor_1d(ctx, GGML_TYPE_F32, output_channels); for (int i = 0; i < num_blocks; i++) { input_blocks[i].init_params(ctx); middle_blocks[i].init_params(ctx); output_blocks[i].init_params(ctx); } final_block.init_params(ctx); }
O1
cpp
TinyDecoder::init_params(ggml_allocr*, ggml_context*): pushq %r15 pushq %r14 pushq %r12 pushq %rbx pushq %rax movq %rdx, %rbx movq %rdi, %r14 movslq (%rdi), %r8 movslq 0x4(%rdi), %r9 movl $0x3, %edx movl $0x3, %ecx movq %rbx, %rdi movl $0x1, %esi callq 0x8eca5 movq %rax, 0x10(%r14) movslq 0x4(%r14), %rdx movq %rbx, %rdi xorl %esi, %esi callq 0x8ec3c movq %rax, 0x18(%r14) movslq 0x4(%r14), %r8 movl $0x3, %edx movl $0x3, %ecx movq %rbx, %rdi movl $0x1, %esi movq %r8, %r9 callq 0x8eca5 movq %rax, 0xe0(%r14) movslq 0x4(%r14), %r8 movl $0x3, %edx movl $0x3, %ecx movq %rbx, %rdi movl $0x1, %esi movq %r8, %r9 callq 0x8eca5 movq %rax, 0x1a8(%r14) movslq 0x4(%r14), %r8 movl $0x3, %edx movl $0x3, %ecx movq %rbx, %rdi movl $0x1, %esi movq %r8, %r9 callq 0x8eca5 movq %rax, 0x270(%r14) movslq 0x4(%r14), %r8 movslq 0x8(%r14), %r9 movl $0x3, %edx movl $0x3, %ecx movq %rbx, %rdi movl $0x1, %esi callq 0x8eca5 movq %rax, 0x2b8(%r14) movslq 0x8(%r14), %rdx movq %rbx, %rdi xorl %esi, %esi callq 0x8ec3c movq %rax, 0x2c0(%r14) cmpl $0x0, 0xc(%r14) jle 0x49ce2 leaq 0x1b0(%r14), %r15 xorl %r12d, %r12d leaq -0x190(%r15), %rdi movq %rbx, %rsi callq 0x49e4c leaq -0xc8(%r15), %rdi movq %rbx, %rsi callq 0x49e4c movq %r15, %rdi movq %rbx, %rsi callq 0x49e4c incq %r12 movslq 0xc(%r14), %rax addq $0x40, %r15 cmpq %rax, %r12 jl 0x49ca9 addq $0x278, %r14 # imm = 0x278 movq %r14, %rdi movq %rbx, %rsi addq $0x8, %rsp popq %rbx popq %r12 popq %r14 popq %r15 jmp 0x49e4c nop
_ZN11TinyDecoder11init_paramsEP11ggml_allocrP12ggml_context: push r15 push r14 push r12 push rbx push rax mov rbx, rdx mov r14, rdi movsxd r8, dword ptr [rdi] movsxd r9, dword ptr [rdi+4] mov edx, 3 mov ecx, 3 mov rdi, rbx mov esi, 1 call ggml_new_tensor_4d mov [r14+10h], rax movsxd rdx, dword ptr [r14+4] mov rdi, rbx xor esi, esi call ggml_new_tensor_1d mov [r14+18h], rax movsxd r8, dword ptr [r14+4] mov edx, 3 mov ecx, 3 mov rdi, rbx mov esi, 1 mov r9, r8 call ggml_new_tensor_4d mov [r14+0E0h], rax movsxd r8, dword ptr [r14+4] mov edx, 3 mov ecx, 3 mov rdi, rbx mov esi, 1 mov r9, r8 call ggml_new_tensor_4d mov [r14+1A8h], rax movsxd r8, dword ptr [r14+4] mov edx, 3 mov ecx, 3 mov rdi, rbx mov esi, 1 mov r9, r8 call ggml_new_tensor_4d mov [r14+270h], rax movsxd r8, dword ptr [r14+4] movsxd r9, dword ptr [r14+8] mov edx, 3 mov ecx, 3 mov rdi, rbx mov esi, 1 call ggml_new_tensor_4d mov [r14+2B8h], rax movsxd rdx, dword ptr [r14+8] mov rdi, rbx xor esi, esi call ggml_new_tensor_1d mov [r14+2C0h], rax cmp dword ptr [r14+0Ch], 0 jle short loc_49CE2 lea r15, [r14+1B0h] xor r12d, r12d loc_49CA9: lea rdi, [r15-190h] mov rsi, rbx call _ZN8TAEBlock11init_paramsEP12ggml_context; TAEBlock::init_params(ggml_context *) lea rdi, [r15-0C8h] mov rsi, rbx call _ZN8TAEBlock11init_paramsEP12ggml_context; TAEBlock::init_params(ggml_context *) mov rdi, r15 mov rsi, rbx call _ZN8TAEBlock11init_paramsEP12ggml_context; TAEBlock::init_params(ggml_context *) inc r12 movsxd rax, dword ptr [r14+0Ch] add r15, 40h ; '@' cmp r12, rax jl short loc_49CA9 loc_49CE2: add r14, 278h mov rdi, r14 mov rsi, rbx add rsp, 8 pop rbx pop r12 pop r14 pop r15 jmp _ZN8TAEBlock11init_paramsEP12ggml_context; TAEBlock::init_params(ggml_context *)
long long TinyDecoder::init_params(int *a1, long long a2, long long a3) { int *v4; // r15 long long v5; // r12 *((_QWORD *)a1 + 2) = ggml_new_tensor_4d(a3, 1LL, 3LL, 3LL, *a1, a1[1]); *((_QWORD *)a1 + 3) = ggml_new_tensor_1d(a3, 0LL, a1[1]); *((_QWORD *)a1 + 28) = ggml_new_tensor_4d(a3, 1LL, 3LL, 3LL, a1[1], a1[1]); *((_QWORD *)a1 + 53) = ggml_new_tensor_4d(a3, 1LL, 3LL, 3LL, a1[1], a1[1]); *((_QWORD *)a1 + 78) = ggml_new_tensor_4d(a3, 1LL, 3LL, 3LL, a1[1], a1[1]); *((_QWORD *)a1 + 87) = ggml_new_tensor_4d(a3, 1LL, 3LL, 3LL, a1[1], a1[2]); *((_QWORD *)a1 + 88) = ggml_new_tensor_1d(a3, 0LL, a1[2]); if ( a1[3] > 0 ) { v4 = a1 + 108; v5 = 0LL; do { TAEBlock::init_params(v4 - 100, a3); TAEBlock::init_params(v4 - 50, a3); TAEBlock::init_params(v4, a3); ++v5; v4 += 16; } while ( v5 < a1[3] ); } return TAEBlock::init_params(a1 + 158, a3); }
20,552
TinyDecoder::init_params(ggml_allocr*, ggml_context*)
7CodeWizard[P]stablediffusion/tae.hpp
void init_params(ggml_allocr* alloc, ggml_context* ctx) { conv_input_w = ggml_new_tensor_4d(ctx, GGML_TYPE_F16, 3, 3, z_channels, channels); conv_input_b = ggml_new_tensor_1d(ctx, GGML_TYPE_F32, channels); conv_1_w = ggml_new_tensor_4d(ctx, GGML_TYPE_F16, 3, 3, channels, channels); conv_2_w = ggml_new_tensor_4d(ctx, GGML_TYPE_F16, 3, 3, channels, channels); conv_3_w = ggml_new_tensor_4d(ctx, GGML_TYPE_F16, 3, 3, channels, channels); conv_final_w = ggml_new_tensor_4d(ctx, GGML_TYPE_F16, 3, 3, channels, output_channels); conv_final_b = ggml_new_tensor_1d(ctx, GGML_TYPE_F32, output_channels); for (int i = 0; i < num_blocks; i++) { input_blocks[i].init_params(ctx); middle_blocks[i].init_params(ctx); output_blocks[i].init_params(ctx); } final_block.init_params(ctx); }
O2
cpp
TinyDecoder::init_params(ggml_allocr*, ggml_context*): pushq %rbp pushq %r15 pushq %r14 pushq %r12 pushq %rbx movq %rdx, %rbx movq %rdi, %r14 movslq (%rdi), %r8 movslq 0x4(%rdi), %r9 pushq $0x1 popq %rbp pushq $0x3 popq %r15 movq %rdx, %rdi movl %ebp, %esi movq %r15, %rdx movq %r15, %rcx callq 0x68667 movq %rax, 0x10(%r14) movslq 0x4(%r14), %rdx xorl %r12d, %r12d movq %rbx, %rdi xorl %esi, %esi callq 0x68616 movq %rax, 0x18(%r14) movslq 0x4(%r14), %r8 movq %rbx, %rdi movl %ebp, %esi movq %r15, %rdx movq %r15, %rcx movq %r8, %r9 callq 0x68667 movq %rax, 0xe0(%r14) movslq 0x4(%r14), %r8 movq %rbx, %rdi movl %ebp, %esi movq %r15, %rdx movq %r15, %rcx movq %r8, %r9 callq 0x68667 movq %rax, 0x1a8(%r14) movslq 0x4(%r14), %r8 movq %rbx, %rdi movl %ebp, %esi movq %r15, %rdx movq %r15, %rcx movq %r8, %r9 callq 0x68667 movq %rax, 0x270(%r14) movslq 0x4(%r14), %r8 movslq 0x8(%r14), %r9 movq %rbx, %rdi movl %ebp, %esi movq %r15, %rdx movq %r15, %rcx callq 0x68667 movq %rax, 0x2b8(%r14) movslq 0x8(%r14), %rdx movq %rbx, %rdi xorl %esi, %esi callq 0x68616 movq %rax, 0x2c0(%r14) leaq 0x1b0(%r14), %r15 movslq 0xc(%r14), %rax cmpq %rax, %r12 jge 0x2f1c1 leaq -0x190(%r15), %rdi movq %rbx, %rsi callq 0x2f304 leaq -0xc8(%r15), %rdi movq %rbx, %rsi callq 0x2f304 movq %r15, %rdi movq %rbx, %rsi callq 0x2f304 incq %r12 addq $0x40, %r15 jmp 0x2f186 addq $0x278, %r14 # imm = 0x278 movq %r14, %rdi movq %rbx, %rsi popq %rbx popq %r12 popq %r14 popq %r15 popq %rbp jmp 0x2f304 nop
_ZN11TinyDecoder11init_paramsEP11ggml_allocrP12ggml_context: push rbp push r15 push r14 push r12 push rbx mov rbx, rdx mov r14, rdi movsxd r8, dword ptr [rdi] movsxd r9, dword ptr [rdi+4] push 1 pop rbp push 3 pop r15 mov rdi, rdx mov esi, ebp mov rdx, r15 mov rcx, r15 call ggml_new_tensor_4d mov [r14+10h], rax movsxd rdx, dword ptr [r14+4] xor r12d, r12d mov rdi, rbx xor esi, esi call ggml_new_tensor_1d mov [r14+18h], rax movsxd r8, dword ptr [r14+4] mov rdi, rbx mov esi, ebp mov rdx, r15 mov rcx, r15 mov r9, r8 call ggml_new_tensor_4d mov [r14+0E0h], rax movsxd r8, dword ptr [r14+4] mov rdi, rbx mov esi, ebp mov rdx, r15 mov rcx, r15 mov r9, r8 call ggml_new_tensor_4d mov [r14+1A8h], rax movsxd r8, dword ptr [r14+4] mov rdi, rbx mov esi, ebp mov rdx, r15 mov rcx, r15 mov r9, r8 call ggml_new_tensor_4d mov [r14+270h], rax movsxd r8, dword ptr [r14+4] movsxd r9, dword ptr [r14+8] mov rdi, rbx mov esi, ebp mov rdx, r15 mov rcx, r15 call ggml_new_tensor_4d mov [r14+2B8h], rax movsxd rdx, dword ptr [r14+8] mov rdi, rbx xor esi, esi call ggml_new_tensor_1d mov [r14+2C0h], rax lea r15, [r14+1B0h] loc_2F186: movsxd rax, dword ptr [r14+0Ch] cmp r12, rax jge short loc_2F1C1 lea rdi, [r15-190h] mov rsi, rbx call _ZN8TAEBlock11init_paramsEP12ggml_context; TAEBlock::init_params(ggml_context *) lea rdi, [r15-0C8h] mov rsi, rbx call _ZN8TAEBlock11init_paramsEP12ggml_context; TAEBlock::init_params(ggml_context *) mov rdi, r15 mov rsi, rbx call _ZN8TAEBlock11init_paramsEP12ggml_context; TAEBlock::init_params(ggml_context *) inc r12 add r15, 40h ; '@' jmp short loc_2F186 loc_2F1C1: add r14, 278h mov rdi, r14 mov rsi, rbx pop rbx pop r12 pop r14 pop r15 pop rbp jmp _ZN8TAEBlock11init_paramsEP12ggml_context; TAEBlock::init_params(ggml_context *)
long long TinyDecoder::init_params(int *a1, long long a2, long long a3) { long long v4; // r12 int *v5; // r15 *((_QWORD *)a1 + 2) = ggml_new_tensor_4d(a3, 1LL, 3LL, 3LL, *a1, a1[1]); v4 = 0LL; *((_QWORD *)a1 + 3) = ggml_new_tensor_1d(a3, 0LL, a1[1]); *((_QWORD *)a1 + 28) = ggml_new_tensor_4d(a3, 1LL, 3LL, 3LL, a1[1], a1[1]); *((_QWORD *)a1 + 53) = ggml_new_tensor_4d(a3, 1LL, 3LL, 3LL, a1[1], a1[1]); *((_QWORD *)a1 + 78) = ggml_new_tensor_4d(a3, 1LL, 3LL, 3LL, a1[1], a1[1]); *((_QWORD *)a1 + 87) = ggml_new_tensor_4d(a3, 1LL, 3LL, 3LL, a1[1], a1[2]); *((_QWORD *)a1 + 88) = ggml_new_tensor_1d(a3, 0LL, a1[2]); v5 = a1 + 108; while ( v4 < a1[3] ) { TAEBlock::init_params(v5 - 100, a3); TAEBlock::init_params(v5 - 50, a3); TAEBlock::init_params(v5, a3); ++v4; v5 += 16; } return TAEBlock::init_params(a1 + 158, a3); }
init_params: PUSH RBP PUSH R15 PUSH R14 PUSH R12 PUSH RBX MOV RBX,RDX MOV R14,RDI MOVSXD R8,dword ptr [RDI] MOVSXD R9,dword ptr [RDI + 0x4] PUSH 0x1 POP RBP PUSH 0x3 POP R15 MOV RDI,RDX MOV ESI,EBP MOV RDX,R15 MOV RCX,R15 CALL 0x00168667 MOV qword ptr [R14 + 0x10],RAX MOVSXD RDX,dword ptr [R14 + 0x4] XOR R12D,R12D MOV RDI,RBX XOR ESI,ESI CALL 0x00168616 MOV qword ptr [R14 + 0x18],RAX MOVSXD R8,dword ptr [R14 + 0x4] MOV RDI,RBX MOV ESI,EBP MOV RDX,R15 MOV RCX,R15 MOV R9,R8 CALL 0x00168667 MOV qword ptr [R14 + 0xe0],RAX MOVSXD R8,dword ptr [R14 + 0x4] MOV RDI,RBX MOV ESI,EBP MOV RDX,R15 MOV RCX,R15 MOV R9,R8 CALL 0x00168667 MOV qword ptr [R14 + 0x1a8],RAX MOVSXD R8,dword ptr [R14 + 0x4] MOV RDI,RBX MOV ESI,EBP MOV RDX,R15 MOV RCX,R15 MOV R9,R8 CALL 0x00168667 MOV qword ptr [R14 + 0x270],RAX MOVSXD R8,dword ptr [R14 + 0x4] MOVSXD R9,dword ptr [R14 + 0x8] MOV RDI,RBX MOV ESI,EBP MOV RDX,R15 MOV RCX,R15 CALL 0x00168667 MOV qword ptr [R14 + 0x2b8],RAX MOVSXD RDX,dword ptr [R14 + 0x8] MOV RDI,RBX XOR ESI,ESI CALL 0x00168616 MOV qword ptr [R14 + 0x2c0],RAX LEA R15,[R14 + 0x1b0] LAB_0012f186: MOVSXD RAX,dword ptr [R14 + 0xc] CMP R12,RAX JGE 0x0012f1c1 LEA RDI,[R15 + -0x190] MOV RSI,RBX CALL 0x0012f304 LEA RDI,[R15 + -0xc8] MOV RSI,RBX CALL 0x0012f304 MOV RDI,R15 MOV RSI,RBX CALL 0x0012f304 INC R12 ADD R15,0x40 JMP 0x0012f186 LAB_0012f1c1: ADD R14,0x278 MOV RDI,R14 MOV RSI,RBX POP RBX POP R12 POP R14 POP R15 POP RBP JMP 0x0012f304
/* TinyDecoder::init_params(ggml_allocr*, ggml_context*) */ void __thiscall TinyDecoder::init_params(TinyDecoder *this,ggml_allocr *param_1,ggml_context *param_2) { int8 uVar1; long lVar2; TinyDecoder *this_00; uVar1 = ggml_new_tensor_4d(param_2,1,3,3,(long)*(int *)this,(long)*(int *)(this + 4)); *(int8 *)(this + 0x10) = uVar1; uVar1 = ggml_new_tensor_1d(param_2,0,(long)*(int *)(this + 4)); *(int8 *)(this + 0x18) = uVar1; uVar1 = ggml_new_tensor_4d(param_2,1,3,3,(long)*(int *)(this + 4),(long)*(int *)(this + 4)); *(int8 *)(this + 0xe0) = uVar1; uVar1 = ggml_new_tensor_4d(param_2,1,3,3,(long)*(int *)(this + 4),(long)*(int *)(this + 4)); *(int8 *)(this + 0x1a8) = uVar1; uVar1 = ggml_new_tensor_4d(param_2,1,3,3,(long)*(int *)(this + 4),(long)*(int *)(this + 4)); *(int8 *)(this + 0x270) = uVar1; uVar1 = ggml_new_tensor_4d(param_2,1,3,3,(long)*(int *)(this + 4),(long)*(int *)(this + 8)); *(int8 *)(this + 0x2b8) = uVar1; uVar1 = ggml_new_tensor_1d(param_2,0,(long)*(int *)(this + 8)); *(int8 *)(this + 0x2c0) = uVar1; this_00 = this + 0x1b0; for (lVar2 = 0; lVar2 < *(int *)(this + 0xc); lVar2 = lVar2 + 1) { TAEBlock::init_params((TAEBlock *)this_00 + -400,param_2); TAEBlock::init_params((TAEBlock *)this_00 + -200,param_2); TAEBlock::init_params((TAEBlock *)this_00,param_2); this_00 = (TinyDecoder *)((TAEBlock *)this_00 + 0x40); } TAEBlock::init_params((TAEBlock *)(this + 0x278),param_2); return; }
20,553
uf_varchar1
eloqsql/storage/myisam/mi_packrec.c
static void uf_varchar1(MI_COLUMNDEF *rec, MI_BIT_BUFF *bit_buff, uchar *to, uchar *end __attribute__((unused))) { if (get_bit(bit_buff)) to[0]= 0; /* Zero lengths */ else { ulong length=get_bits(bit_buff,rec->space_length_bits); *to= (uchar) length; decode_bytes(rec,bit_buff,to+1,to+1+length); } }
O3
c
uf_varchar1: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx pushq %rax movq %rdx, %rbx movq %rsi, %r14 movq %rdi, %r15 movl 0x4(%rsi), %eax testl %eax, %eax je 0x853d6 movl (%r14), %r13d decl %eax movl %eax, 0x4(%r14) btl %eax, %r13d jae 0x853f3 movb $0x0, (%rbx) addq $0x8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq movq %r14, %rdi callq 0x83d5d movl $0x1f, 0x4(%r14) movl (%r14), %r13d movl $0x1f, %eax testl %r13d, %r13d js 0x853c4 movl 0x1c(%r15), %r12d movl %eax, %ecx subl %r12d, %ecx jae 0x85438 subl %eax, %r12d movl %eax, %eax leaq 0x5d506(%rip), %rcx # 0xe2910 andl (%rcx,%rax,4), %r13d movl %r12d, %ecx shll %cl, %r13d movq %r14, %rdi callq 0x83d5d movl $0x20, %eax subl %r12d, %eax movl %eax, 0x4(%r14) movl (%r14), %eax negl %r12d movl %r12d, %ecx shrl %cl, %eax addl %eax, %r13d jmp 0x8544e movl %ecx, 0x4(%r14) shrl %cl, %r13d movl 0x1c(%r15), %eax leaq 0x5d4c6(%rip), %rcx # 0xe2910 andl (%rcx,%rax,4), %r13d movl %r13d, %eax movb %r13b, (%rbx) leaq (%rbx,%rax), %rcx incq %rcx incq %rbx movq %r15, %rdi movq %r14, %rsi movq %rbx, %rdx addq $0x8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp jmp 0x8464e
uf_varchar1_0: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx push rax mov rbx, rdx mov r14, rsi mov r15, rdi mov eax, [rsi+4] test eax, eax jz short loc_853D6 mov r13d, [r14] dec eax mov [r14+4], eax bt r13d, eax jnb short loc_853F3 loc_853C4: mov byte ptr [rbx], 0 add rsp, 8 pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn loc_853D6: mov rdi, r14 call fill_buffer_0 mov dword ptr [r14+4], 1Fh mov r13d, [r14] mov eax, 1Fh test r13d, r13d js short loc_853C4 loc_853F3: mov r12d, [r15+1Ch] mov ecx, eax sub ecx, r12d jnb short loc_85438 sub r12d, eax mov eax, eax lea rcx, mask_0 and r13d, [rcx+rax*4] mov ecx, r12d shl r13d, cl mov rdi, r14 call fill_buffer_0 mov eax, 20h ; ' ' sub eax, r12d mov [r14+4], eax mov eax, [r14] neg r12d mov ecx, r12d shr eax, cl add r13d, eax jmp short loc_8544E loc_85438: mov [r14+4], ecx shr r13d, cl mov eax, [r15+1Ch] lea rcx, mask_0 and r13d, [rcx+rax*4] loc_8544E: mov eax, r13d mov [rbx], r13b lea rcx, [rbx+rax] inc rcx inc rbx mov rdi, r15 mov rsi, r14 mov rdx, rbx add rsp, 8 pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp jmp decode_bytes_0
long long uf_varchar1_0(long long a1, unsigned int *a2, _BYTE *a3) { unsigned int v4; // eax unsigned int v5; // r13d long long result; // rax unsigned int v7; // r12d unsigned int v8; // ecx int v9; // r12d int v10; // r13d unsigned int v11; // r13d v4 = a2[1]; if ( v4 ) { v5 = *a2; result = v4 - 1; a2[1] = result; if ( _bittest((const int *)&v5, result) ) { LABEL_3: *a3 = 0; return result; } } else { fill_buffer_0((long long)a2); a2[1] = 31; v5 = *a2; result = 31LL; if ( (*a2 & 0x80000000) != 0 ) goto LABEL_3; } v7 = *(_DWORD *)(a1 + 28); v8 = result - v7; if ( (unsigned int)result >= v7 ) { a2[1] = v8; v11 = mask_0[*(unsigned int *)(a1 + 28)] & (v5 >> v8); } else { v9 = v7 - result; v10 = (mask_0[(unsigned int)result] & v5) << v9; fill_buffer_0((long long)a2); a2[1] = 32 - v9; v11 = (*a2 >> -(char)v9) + v10; } *a3 = v11; return (long long)decode_bytes_0(a1, (long long)a2, a3 + 1, &a3[v11 + 1]); }
uf_varchar1: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX PUSH RAX MOV RBX,RDX MOV R14,RSI MOV R15,RDI MOV EAX,dword ptr [RSI + 0x4] TEST EAX,EAX JZ 0x001853d6 MOV R13D,dword ptr [R14] DEC EAX MOV dword ptr [R14 + 0x4],EAX BT R13D,EAX JNC 0x001853f3 LAB_001853c4: MOV byte ptr [RBX],0x0 ADD RSP,0x8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET LAB_001853d6: MOV RDI,R14 CALL 0x00183d5d MOV dword ptr [R14 + 0x4],0x1f MOV R13D,dword ptr [R14] MOV EAX,0x1f TEST R13D,R13D JS 0x001853c4 LAB_001853f3: MOV R12D,dword ptr [R15 + 0x1c] MOV ECX,EAX SUB ECX,R12D JNC 0x00185438 SUB R12D,EAX MOV EAX,EAX LEA RCX,[0x1e2910] AND R13D,dword ptr [RCX + RAX*0x4] MOV ECX,R12D SHL R13D,CL MOV RDI,R14 CALL 0x00183d5d MOV EAX,0x20 SUB EAX,R12D MOV dword ptr [R14 + 0x4],EAX MOV EAX,dword ptr [R14] NEG R12D MOV ECX,R12D SHR EAX,CL ADD R13D,EAX JMP 0x0018544e LAB_00185438: MOV dword ptr [R14 + 0x4],ECX SHR R13D,CL MOV EAX,dword ptr [R15 + 0x1c] LEA RCX,[0x1e2910] AND R13D,dword ptr [RCX + RAX*0x4] LAB_0018544e: MOV EAX,R13D MOV byte ptr [RBX],R13B LEA RCX,[RBX + RAX*0x1] INC RCX INC RBX MOV RDI,R15 MOV RSI,R14 MOV RDX,RBX ADD RSP,0x8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP JMP 0x0018464e
void uf_varchar1(long param_1,uint *param_2,int1 *param_3) { uint uVar1; uint uVar2; uint uVar3; byte bVar4; uint uVar5; if (param_2[1] == 0) { fill_buffer(param_2); param_2[1] = 0x1f; uVar5 = *param_2; uVar3 = 0x1f; if (-1 < (int)uVar5) goto LAB_001853f3; } else { uVar5 = *param_2; uVar3 = param_2[1] - 1; param_2[1] = uVar3; if ((uVar5 >> (uVar3 & 0x1f) & 1) == 0) { LAB_001853f3: uVar1 = *(uint *)(param_1 + 0x1c); if (uVar3 < uVar1) { uVar2 = (&mask)[uVar3]; bVar4 = (byte)(uVar1 - uVar3); fill_buffer(param_2); param_2[1] = 0x20 - (uVar1 - uVar3); uVar5 = ((uVar5 & uVar2) << (bVar4 & 0x1f)) + (*param_2 >> (-bVar4 & 0x1f)); } else { param_2[1] = uVar3 - uVar1; uVar5 = uVar5 >> ((byte)(uVar3 - uVar1) & 0x1f) & (&mask)[*(uint *)(param_1 + 0x1c)]; } *param_3 = (char)uVar5; decode_bytes(param_1,param_2,param_3 + 1,param_3 + (ulong)uVar5 + 1); return; } } *param_3 = 0; return; }
20,554
js_setlike_get_size
bluesky950520[P]quickjs/quickjs.c
static int js_setlike_get_size(JSContext *ctx, JSValue setlike, int64_t *pout) { JSMapState *s; JSValue v; double d; s = JS_GetOpaque(setlike, JS_CLASS_SET); if (s) { *pout = s->record_count; } else { v = JS_GetProperty(ctx, setlike, JS_ATOM_size); if (JS_IsException(v)) return -1; if (JS_IsUndefined(v)) { JS_ThrowTypeError(ctx, ".size is undefined"); return -1; } if (JS_ToFloat64Free(ctx, &d, v) < 0) return -1; if (isnan(d)) { JS_ThrowTypeError(ctx, ".size is not a number"); return -1; } *pout = d; } return 0; }
O1
c
js_setlike_get_size: pushq %rbp pushq %r14 pushq %rbx subq $0x10, %rsp movq %rcx, %rbx movq %rdi, %r14 movq %rsi, 0x8(%rsp) cmpl $-0x1, %edx jne 0x51e13 movq 0x8(%rsp), %rax cmpw $0x24, 0x6(%rax) jne 0x51e13 movq 0x30(%rax), %rax jmp 0x51e15 xorl %eax, %eax testq %rax, %rax je 0x51e2d movl 0x18(%rax), %eax movq %rax, (%rbx) xorl %ebp, %ebp movl %ebp, %eax addq $0x10, %rsp popq %rbx popq %r14 popq %rbp retq movq %r14, %rdi movl $0x31, %ecx movq %rsi, %r8 movq %rdx, %r9 pushq $0x0 pushq $0x0 callq 0x22fa3 addq $0x10, %rsp movq %rdx, %rcx movl $0xffffffff, %ebp # imm = 0xFFFFFFFF cmpl $0x6, %ecx je 0x51e22 cmpl $0x3, %ecx jne 0x51e6d leaq 0x4e3cd(%rip), %rsi # 0xa022e movq %r14, %rdi xorl %eax, %eax callq 0x22567 jmp 0x51e22 cmpl $0x2, %ecx ja 0x51e7e cvtsi2sd %eax, %xmm0 movsd %xmm0, 0x8(%rsp) jmp 0x51e9e cmpl $0x7, %ecx jne 0x51e8a movq %rax, 0x8(%rsp) jmp 0x51e9e leaq 0x8(%rsp), %rsi movq %r14, %rdi movq %rax, %rdx callq 0x3df2f testl %eax, %eax js 0x51e22 movsd 0x8(%rsp), %xmm0 ucomisd %xmm0, %xmm0 jp 0x51eb4 cvttsd2si %xmm0, %rax jmp 0x51e1d leaq 0x4e386(%rip), %rsi # 0xa0241 jmp 0x51e61
js_setlike_get_size: push rbp push r14 push rbx sub rsp, 10h mov rbx, rcx mov r14, rdi mov [rsp+28h+var_20], rsi cmp edx, 0FFFFFFFFh jnz short loc_51E13 mov rax, [rsp+28h+var_20] cmp word ptr [rax+6], 24h ; '$' jnz short loc_51E13 mov rax, [rax+30h] jmp short loc_51E15 loc_51E13: xor eax, eax loc_51E15: test rax, rax jz short loc_51E2D mov eax, [rax+18h] loc_51E1D: mov [rbx], rax xor ebp, ebp loc_51E22: mov eax, ebp add rsp, 10h pop rbx pop r14 pop rbp retn loc_51E2D: mov rdi, r14 mov ecx, 31h ; '1' mov r8, rsi mov r9, rdx push 0 push 0 call JS_GetPropertyInternal2 add rsp, 10h mov rcx, rdx mov ebp, 0FFFFFFFFh cmp ecx, 6 jz short loc_51E22 cmp ecx, 3 jnz short loc_51E6D lea rsi, aSizeIsUndefine; ".size is undefined" loc_51E61: mov rdi, r14 xor eax, eax call JS_ThrowTypeError jmp short loc_51E22 loc_51E6D: cmp ecx, 2 ja short loc_51E7E cvtsi2sd xmm0, eax movsd [rsp+28h+var_20], xmm0 jmp short loc_51E9E loc_51E7E: cmp ecx, 7 jnz short loc_51E8A mov [rsp+28h+var_20], rax jmp short loc_51E9E loc_51E8A: lea rsi, [rsp+28h+var_20] mov rdi, r14 mov rdx, rax call __JS_ToFloat64Free test eax, eax js short loc_51E22 loc_51E9E: movsd xmm0, [rsp+28h+var_20] ucomisd xmm0, xmm0 jp short loc_51EB4 cvttsd2si rax, xmm0 jmp loc_51E1D loc_51EB4: lea rsi, aSizeIsNotANumb; ".size is not a number" jmp short loc_51E61
long long js_setlike_get_size( long long a1, long long a2, long long a3, _QWORD *a4, __m128 a5, __m128 a6, __m128 a7, __m128 a8, double a9, double a10, __m128 a11, __m128 a12) { long long v13; // rax long long v14; // rax unsigned int v15; // ebp unsigned long long PropertyInternal2; // rax long long v18; // rdx long long v19; // r8 long long v20; // r9 __m128 v21; // xmm4 __m128 v22; // xmm5 char v23; // [rsp+0h] [rbp-28h] double v24[4]; // [rsp+8h] [rbp-20h] BYREF v24[0] = *(double *)&a2; if ( (_DWORD)a3 == -1 && *(_WORD *)(*(_QWORD *)&v24[0] + 6LL) == 36 ) v13 = *(_QWORD *)(*(_QWORD *)&v24[0] + 48LL); else v13 = 0LL; if ( v13 ) { v14 = *(unsigned int *)(v13 + 24); } else { PropertyInternal2 = JS_GetPropertyInternal2(a1, a2, a3, 0x31u, a2, a3, 0LL, 0); v15 = -1; if ( (_DWORD)v18 == 6 ) return v15; if ( (_DWORD)v18 == 3 ) { JS_ThrowTypeError(a1, (long long)".size is undefined", v18, v18, v19, v20, a5, a6, a7, a8, v21, v22, a11, a12, v23); return v15; } if ( (unsigned int)v18 > 2 ) { if ( (_DWORD)v18 == 7 ) { v24[0] = *(double *)&PropertyInternal2; } else if ( (int)_JS_ToFloat64Free(a1, (long long *)v24, PropertyInternal2, v18) < 0 ) { return v15; } } else { v24[0] = (double)(int)PropertyInternal2; } v14 = (unsigned int)(int)v24[0]; } *a4 = v14; return 0; }
js_setlike_get_size: PUSH RBP PUSH R14 PUSH RBX SUB RSP,0x10 MOV RBX,RCX MOV R14,RDI MOV qword ptr [RSP + 0x8],RSI CMP EDX,-0x1 JNZ 0x00151e13 MOV RAX,qword ptr [RSP + 0x8] CMP word ptr [RAX + 0x6],0x24 JNZ 0x00151e13 MOV RAX,qword ptr [RAX + 0x30] JMP 0x00151e15 LAB_00151e13: XOR EAX,EAX LAB_00151e15: TEST RAX,RAX JZ 0x00151e2d MOV EAX,dword ptr [RAX + 0x18] LAB_00151e1d: MOV qword ptr [RBX],RAX XOR EBP,EBP LAB_00151e22: MOV EAX,EBP ADD RSP,0x10 POP RBX POP R14 POP RBP RET LAB_00151e2d: MOV RDI,R14 MOV ECX,0x31 MOV R8,RSI MOV R9,RDX PUSH 0x0 PUSH 0x0 CALL 0x00122fa3 ADD RSP,0x10 MOV RCX,RDX MOV EBP,0xffffffff CMP ECX,0x6 JZ 0x00151e22 CMP ECX,0x3 JNZ 0x00151e6d LEA RSI,[0x1a022e] LAB_00151e61: MOV RDI,R14 XOR EAX,EAX CALL 0x00122567 JMP 0x00151e22 LAB_00151e6d: CMP ECX,0x2 JA 0x00151e7e CVTSI2SD XMM0,EAX MOVSD qword ptr [RSP + 0x8],XMM0 JMP 0x00151e9e LAB_00151e7e: CMP ECX,0x7 JNZ 0x00151e8a MOV qword ptr [RSP + 0x8],RAX JMP 0x00151e9e LAB_00151e8a: LEA RSI,[RSP + 0x8] MOV RDI,R14 MOV RDX,RAX CALL 0x0013df2f TEST EAX,EAX JS 0x00151e22 LAB_00151e9e: MOVSD XMM0,qword ptr [RSP + 0x8] UCOMISD XMM0,XMM0 JP 0x00151eb4 CVTTSD2SI RAX,XMM0 JMP 0x00151e1d LAB_00151eb4: LEA RSI,[0x1a0241] JMP 0x00151e61
int8 js_setlike_get_size(int8 param_1,double param_2,int8 param_3,ulong *param_4) { double dVar1; int iVar2; long lVar3; ulong uVar4; uint uVar5; int8 uVar6; char *pcVar7; int1 auVar8 [12]; double local_20; if (((int)param_3 == -1) && (*(short *)((long)param_2 + 6) == 0x24)) { lVar3 = *(long *)((long)param_2 + 0x30); } else { lVar3 = 0; } if (lVar3 == 0) { local_20 = param_2; auVar8 = JS_GetPropertyInternal2(param_1,param_2,param_3,0x31,param_2,param_3,0,0); uVar5 = auVar8._8_4_; uVar6 = 0xffffffff; if (uVar5 == 6) { return 0xffffffff; } if (uVar5 == 3) { pcVar7 = ".size is int"; } else { if (uVar5 < 3) { dVar1 = (double)auVar8._0_4_; } else { dVar1 = auVar8._0_8_; if ((uVar5 != 7) && (iVar2 = __JS_ToFloat64Free(param_1,&local_20,auVar8._0_8_), dVar1 = local_20, iVar2 < 0) ) { return 0xffffffff; } } local_20 = dVar1; if (!NAN(local_20)) { uVar4 = (ulong)local_20; goto LAB_00151e1d; } pcVar7 = ".size is not a number"; } JS_ThrowTypeError(param_1,pcVar7); } else { uVar4 = (ulong)*(uint *)(lVar3 + 0x18); LAB_00151e1d: *param_4 = uVar4; uVar6 = 0; } return uVar6; }
20,555
js_setlike_get_size
bluesky950520[P]quickjs/quickjs.c
static int js_setlike_get_size(JSContext *ctx, JSValue setlike, int64_t *pout) { JSMapState *s; JSValue v; double d; s = JS_GetOpaque(setlike, JS_CLASS_SET); if (s) { *pout = s->record_count; } else { v = JS_GetProperty(ctx, setlike, JS_ATOM_size); if (JS_IsException(v)) return -1; if (JS_IsUndefined(v)) { JS_ThrowTypeError(ctx, ".size is undefined"); return -1; } if (JS_ToFloat64Free(ctx, &d, v) < 0) return -1; if (isnan(d)) { JS_ThrowTypeError(ctx, ".size is not a number"); return -1; } *pout = d; } return 0; }
O2
c
js_setlike_get_size: pushq %rbp pushq %r14 pushq %rbx subq $0x10, %rsp movq %rcx, %rbx movq %rdi, %r14 cmpl $-0x1, %edx jne 0x46463 cmpw $0x24, 0x6(%rsi) jne 0x46463 movq 0x30(%rsi), %rax testq %rax, %rax je 0x46463 movl 0x18(%rax), %eax jmp 0x464b6 pushq $0x31 popq %rcx movq %r14, %rdi callq 0x1b043 movq %rdx, %rcx pushq $-0x1 popq %rbp cmpl $0x6, %ecx je 0x464bb cmpl $0x3, %ecx jne 0x46491 leaq 0x40ce3(%rip), %rsi # 0x87168 movq %r14, %rdi xorl %eax, %eax callq 0x1c64d jmp 0x464bb leaq 0x8(%rsp), %rsi movq %r14, %rdi movq %rax, %rdx callq 0x21288 testl %eax, %eax js 0x464bb movsd 0x8(%rsp), %xmm0 ucomisd %xmm0, %xmm0 jp 0x464c6 cvttsd2si %xmm0, %rax movq %rax, (%rbx) xorl %ebp, %ebp movl %ebp, %eax addq $0x10, %rsp popq %rbx popq %r14 popq %rbp retq leaq 0x40cae(%rip), %rsi # 0x8717b jmp 0x46485
js_setlike_get_size: push rbp push r14 push rbx sub rsp, 10h mov rbx, rcx mov r14, rdi cmp edx, 0FFFFFFFFh jnz short loc_46463 cmp word ptr [rsi+6], 24h ; '$' jnz short loc_46463 mov rax, [rsi+30h] test rax, rax jz short loc_46463 mov eax, [rax+18h] jmp short loc_464B6 loc_46463: push 31h ; '1' pop rcx mov rdi, r14 call JS_GetProperty mov rcx, rdx push 0FFFFFFFFFFFFFFFFh pop rbp cmp ecx, 6 jz short loc_464BB cmp ecx, 3 jnz short loc_46491 lea rsi, aSizeIsUndefine; ".size is undefined" loc_46485: mov rdi, r14 xor eax, eax call JS_ThrowTypeError jmp short loc_464BB loc_46491: lea rsi, [rsp+28h+var_20] mov rdi, r14 mov rdx, rax call JS_ToFloat64Free test eax, eax js short loc_464BB movsd xmm0, [rsp+28h+var_20] ucomisd xmm0, xmm0 jp short loc_464C6 cvttsd2si rax, xmm0 loc_464B6: mov [rbx], rax xor ebp, ebp loc_464BB: mov eax, ebp add rsp, 10h pop rbx pop r14 pop rbp retn loc_464C6: lea rsi, aSizeIsNotANumb; ".size is not a number" jmp short loc_46485
long long js_setlike_get_size( const char *a1, long long a2, int a3, _QWORD *a4, __m128 a5, __m128 a6, __m128 a7, __m128 a8, double a9, double a10, __m128 a11, __m128 a12) { long long v13; // rax long long v14; // rax long long Property; // rax long long v16; // rdx long long v17; // r8 long long v18; // r9 __m128 v19; // xmm4 __m128 v20; // xmm5 unsigned int v21; // ebp char v23; // [rsp+0h] [rbp-28h] double v24[4]; // [rsp+8h] [rbp-20h] BYREF if ( a3 == -1 && *(_WORD *)(a2 + 6) == 36 ) { v13 = *(_QWORD *)(a2 + 48); if ( v13 ) { v14 = *(unsigned int *)(v13 + 24); LABEL_10: *a4 = v14; return 0; } } Property = JS_GetProperty((int)a1, a2, a3, 49); v21 = -1; if ( (_DWORD)v16 != 6 ) { if ( (_DWORD)v16 == 3 ) { JS_ThrowTypeError( (long long)a1, (long long)".size is undefined", v16, v16, v17, v18, a5, a6, a7, a8, v19, v20, a11, a12, v23); } else if ( (int)JS_ToFloat64Free(a1, v24, Property, v16) >= 0 ) { v14 = (unsigned int)(int)v24[0]; goto LABEL_10; } } return v21; }
js_setlike_get_size: PUSH RBP PUSH R14 PUSH RBX SUB RSP,0x10 MOV RBX,RCX MOV R14,RDI CMP EDX,-0x1 JNZ 0x00146463 CMP word ptr [RSI + 0x6],0x24 JNZ 0x00146463 MOV RAX,qword ptr [RSI + 0x30] TEST RAX,RAX JZ 0x00146463 MOV EAX,dword ptr [RAX + 0x18] JMP 0x001464b6 LAB_00146463: PUSH 0x31 POP RCX MOV RDI,R14 CALL 0x0011b043 MOV RCX,RDX PUSH -0x1 POP RBP CMP ECX,0x6 JZ 0x001464bb CMP ECX,0x3 JNZ 0x00146491 LEA RSI,[0x187168] LAB_00146485: MOV RDI,R14 XOR EAX,EAX CALL 0x0011c64d JMP 0x001464bb LAB_00146491: LEA RSI,[RSP + 0x8] MOV RDI,R14 MOV RDX,RAX CALL 0x00121288 TEST EAX,EAX JS 0x001464bb MOVSD XMM0,qword ptr [RSP + 0x8] UCOMISD XMM0,XMM0 JP 0x001464c6 CVTTSD2SI RAX,XMM0 LAB_001464b6: MOV qword ptr [RBX],RAX XOR EBP,EBP LAB_001464bb: MOV EAX,EBP ADD RSP,0x10 POP RBX POP R14 POP RBP RET LAB_001464c6: LEA RSI,[0x18717b] JMP 0x00146485
int4 js_setlike_get_size(int8 param_1,long param_2,int8 param_3,ulong *param_4) { int iVar1; ulong uVar2; int4 uVar3; char *pcVar4; int1 auVar5 [12]; double local_20; if ((((int)param_3 == -1) && (*(short *)(param_2 + 6) == 0x24)) && (*(long *)(param_2 + 0x30) != 0)) { uVar2 = (ulong)*(uint *)(*(long *)(param_2 + 0x30) + 0x18); LAB_001464b6: *param_4 = uVar2; uVar3 = 0; } else { auVar5 = JS_GetProperty(param_1,param_2,param_3,0x31); uVar3 = 0xffffffff; if (auVar5._8_4_ == 6) { return 0xffffffff; } if (auVar5._8_4_ == 3) { pcVar4 = ".size is int"; } else { iVar1 = JS_ToFloat64Free(param_1,&local_20,auVar5._0_8_); if (iVar1 < 0) { return 0xffffffff; } if (!NAN(local_20)) { uVar2 = (ulong)local_20; goto LAB_001464b6; } pcVar4 = ".size is not a number"; } JS_ThrowTypeError(param_1,pcVar4); } return uVar3; }
20,556
js_reflect_get
bluesky950520[P]quickjs/quickjs.c
static JSValue js_reflect_get(JSContext *ctx, JSValue this_val, int argc, JSValue *argv) { JSValue obj, prop, receiver; JSAtom atom; JSValue ret; obj = argv[0]; prop = argv[1]; if (JS_VALUE_GET_TAG(obj) != JS_TAG_OBJECT) return JS_ThrowTypeErrorNotAnObject(ctx); if (argc > 2) receiver = argv[2]; else receiver = obj; atom = JS_ValueToAtom(ctx, prop); if (unlikely(atom == JS_ATOM_NULL)) return JS_EXCEPTION; ret = JS_GetPropertyInternal(ctx, obj, atom, receiver, FALSE); JS_FreeAtom(ctx, atom); return ret; }
O1
c
js_reflect_get: pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx pushq %rax movq %rdi, %rbx movq 0x8(%r8), %r14 cmpl $-0x1, %r14d jne 0x1295a movq (%r8), %r15 movq 0x10(%r8), %rsi movq 0x18(%r8), %rdx movq %r15, %r12 movq %r14, %r13 cmpl $0x3, %ecx jl 0x1290e movq 0x20(%r8), %r12 movq 0x28(%r8), %r13 movq %rbx, %rdi callq 0x24093 testl %eax, %eax je 0x1298c movl %eax, %ebp movq %rbx, %rdi movq %r15, %rsi movq %r14, %rdx movl %eax, %ecx movq %r12, %r8 movq %r13, %r9 pushq $0x0 pushq $0x0 callq 0x22fa3 popq %rcx popq %rsi movq %rax, %r15 movq %rdx, %r14 movq %rbx, %rdi movl %ebp, %esi callq 0x207d8 movabsq $-0x100000000, %rax # imm = 0xFFFFFFFF00000000 andq %r15, %rax movl %r15d, %r15d jmp 0x12974 leaq 0x8c6c4(%rip), %rsi # 0x9f025 xorl %r15d, %r15d movq %rbx, %rdi xorl %eax, %eax callq 0x22567 pushq $0x6 popq %r14 xorl %eax, %eax orq %rax, %r15 movq %r15, %rax movq %r14, %rdx addq $0x8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq pushq $0x6 popq %r14 xorl %r15d, %r15d jmp 0x12972
js_reflect_get: push rbp push r15 push r14 push r13 push r12 push rbx push rax mov rbx, rdi mov r14, [r8+8] cmp r14d, 0FFFFFFFFh jnz short loc_1295A mov r15, [r8] mov rsi, [r8+10h] mov rdx, [r8+18h] mov r12, r15 mov r13, r14 cmp ecx, 3 jl short loc_1290E mov r12, [r8+20h] mov r13, [r8+28h] loc_1290E: mov rdi, rbx call JS_ValueToAtom test eax, eax jz short loc_1298C mov ebp, eax mov rdi, rbx mov rsi, r15 mov rdx, r14 mov ecx, eax mov r8, r12 mov r9, r13 push 0 push 0 call JS_GetPropertyInternal2 pop rcx pop rsi mov r15, rax mov r14, rdx mov rdi, rbx mov esi, ebp call JS_FreeAtom mov rax, 0FFFFFFFF00000000h and rax, r15 mov r15d, r15d jmp short loc_12974 loc_1295A: lea rsi, aOperandPrototy+20h; "not an object" xor r15d, r15d mov rdi, rbx xor eax, eax call JS_ThrowTypeError push 6 pop r14 loc_12972: xor eax, eax loc_12974: or r15, rax mov rax, r15 mov rdx, r14 add rsp, 8 pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn loc_1298C: push 6 pop r14 xor r15d, r15d jmp short loc_12972
unsigned long long js_reflect_get(long long a1, long long a2, int a3, int a4, long long *a5, int a6) { long long v6; // r15 long long v7; // r12 long long v8; // r13 unsigned int v9; // eax unsigned int v10; // ebp unsigned long long v11; // rax long long PropertyInternal2; // r15 if ( (unsigned int)a5[1] != -1 ) { PropertyInternal2 = 0LL; JS_ThrowTypeError(a1, (unsigned int)"not an object", a3, a4, (_DWORD)a5, a6); LABEL_7: v11 = 0LL; return v11 | PropertyInternal2; } v6 = *a5; v7 = *a5; LODWORD(v8) = -1; if ( a4 >= 3 ) { v7 = a5[4]; v8 = a5[5]; } v9 = JS_ValueToAtom(a1, a5[2], a5[3]); if ( !v9 ) { PropertyInternal2 = 0LL; goto LABEL_7; } v10 = v9; PropertyInternal2 = JS_GetPropertyInternal2(a1, v6, -1, v9, v7, v8, 0LL, 0); JS_FreeAtom(a1, v10); v11 = PropertyInternal2 & 0xFFFFFFFF00000000LL; PropertyInternal2 = (unsigned int)PropertyInternal2; return v11 | PropertyInternal2; }
js_reflect_get: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX PUSH RAX MOV RBX,RDI MOV R14,qword ptr [R8 + 0x8] CMP R14D,-0x1 JNZ 0x0011295a MOV R15,qword ptr [R8] MOV RSI,qword ptr [R8 + 0x10] MOV RDX,qword ptr [R8 + 0x18] MOV R12,R15 MOV R13,R14 CMP ECX,0x3 JL 0x0011290e MOV R12,qword ptr [R8 + 0x20] MOV R13,qword ptr [R8 + 0x28] LAB_0011290e: MOV RDI,RBX CALL 0x00124093 TEST EAX,EAX JZ 0x0011298c MOV EBP,EAX MOV RDI,RBX MOV RSI,R15 MOV RDX,R14 MOV ECX,EAX MOV R8,R12 MOV R9,R13 PUSH 0x0 PUSH 0x0 CALL 0x00122fa3 POP RCX POP RSI MOV R15,RAX MOV R14,RDX MOV RDI,RBX MOV ESI,EBP CALL 0x001207d8 MOV RAX,-0x100000000 AND RAX,R15 MOV R15D,R15D JMP 0x00112974 LAB_0011295a: LEA RSI,[0x19f025] XOR R15D,R15D MOV RDI,RBX XOR EAX,EAX CALL 0x00122567 PUSH 0x6 POP R14 LAB_00112972: XOR EAX,EAX LAB_00112974: OR R15,RAX MOV RAX,R15 MOV RDX,R14 ADD RSP,0x8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET LAB_0011298c: PUSH 0x6 POP R14 XOR R15D,R15D JMP 0x00112972
int1 [16] js_reflect_get(int8 param_1,int8 param_2,int8 param_3,int param_4, int8 *param_5) { int8 uVar1; int iVar2; ulong uVar3; int8 uVar4; int8 uVar5; int8 uVar6; ulong uVar7; int1 auVar8 [16]; int8 uVar9; uVar6 = param_5[1]; if ((int)uVar6 == -1) { uVar1 = *param_5; uVar4 = uVar1; uVar5 = uVar6; if (2 < param_4) { uVar4 = param_5[4]; uVar5 = param_5[5]; } iVar2 = JS_ValueToAtom(param_1,param_5[2],param_5[3]); if (iVar2 != 0) { uVar9 = 0; auVar8 = JS_GetPropertyInternal2(param_1,uVar1,uVar6,iVar2,uVar4,uVar5,0,0); uVar6 = auVar8._8_8_; JS_FreeAtom(param_1,iVar2,uVar6,uVar9); uVar3 = auVar8._0_8_ & 0xffffffff00000000; uVar7 = auVar8._0_8_ & 0xffffffff; goto LAB_00112974; } } else { JS_ThrowTypeError(param_1,"not an object"); } uVar6 = 6; uVar7 = 0; uVar3 = 0; LAB_00112974: auVar8._8_8_ = uVar6; auVar8._0_8_ = uVar7 | uVar3; return auVar8; }
20,557
js_reflect_get
bluesky950520[P]quickjs/quickjs.c
static JSValue js_reflect_get(JSContext *ctx, JSValue this_val, int argc, JSValue *argv) { JSValue obj, prop, receiver; JSAtom atom; JSValue ret; obj = argv[0]; prop = argv[1]; if (JS_VALUE_GET_TAG(obj) != JS_TAG_OBJECT) return JS_ThrowTypeErrorNotAnObject(ctx); if (argc > 2) receiver = argv[2]; else receiver = obj; atom = JS_ValueToAtom(ctx, prop); if (unlikely(atom == JS_ATOM_NULL)) return JS_EXCEPTION; ret = JS_GetPropertyInternal(ctx, obj, atom, receiver, FALSE); JS_FreeAtom(ctx, atom); return ret; }
O2
c
js_reflect_get: pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx pushq %rax movq %rdi, %rbx movq 0x8(%r8), %r14 cmpl $-0x1, %r14d jne 0x6a1fd movq (%r8), %r15 movq 0x10(%r8), %rsi movq 0x18(%r8), %rdx movq %r15, %r12 movq %r14, %r13 cmpl $0x3, %ecx jl 0x6a1b3 movq 0x20(%r8), %r12 movq 0x28(%r8), %r13 movq %rbx, %rdi callq 0x1e0bc testl %eax, %eax je 0x6a205 movl %eax, %ebp andl $0x0, (%rsp) movq %rbx, %rdi movq %r15, %rsi movq %r14, %rdx movl %eax, %ecx movq %r12, %r8 movq %r13, %r9 callq 0x3963b movq %rax, %r15 movq %rdx, %r14 movq %rbx, %rdi movl %ebp, %esi callq 0x1a995 movabsq $-0x100000000, %rcx # imm = 0xFFFFFFFF00000000 andq %r15, %rcx movl %r15d, %eax jmp 0x6a20d movq %rbx, %rdi callq 0x1d5e1 pushq $0x6 popq %r14 xorl %eax, %eax xorl %ecx, %ecx orq %rcx, %rax movq %r14, %rdx addq $0x8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
js_reflect_get: push rbp push r15 push r14 push r13 push r12 push rbx push rax mov rbx, rdi mov r14, [r8+8] cmp r14d, 0FFFFFFFFh jnz short loc_6A1FD mov r15, [r8] mov rsi, [r8+10h] mov rdx, [r8+18h] mov r12, r15 mov r13, r14 cmp ecx, 3 jl short loc_6A1B3 mov r12, [r8+20h] mov r13, [r8+28h] loc_6A1B3: mov rdi, rbx call JS_ValueToAtom test eax, eax jz short loc_6A205 mov ebp, eax and [rsp+38h+var_38], 0 mov rdi, rbx mov rsi, r15 mov rdx, r14 mov ecx, eax mov r8, r12 mov r9, r13 call JS_GetPropertyInternal mov r15, rax mov r14, rdx mov rdi, rbx mov esi, ebp call JS_FreeAtom mov rcx, 0FFFFFFFF00000000h and rcx, r15 mov eax, r15d jmp short loc_6A20D loc_6A1FD: mov rdi, rbx call JS_ThrowTypeErrorNotAnObject loc_6A205: push 6 pop r14 xor eax, eax xor ecx, ecx loc_6A20D: or rax, rcx mov rdx, r14 add rsp, 8 pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
unsigned long long js_reflect_get( long long a1, long long a2, long long a3, long long a4, long long *a5, long long a6, __m128 a7, __m128 a8, __m128 a9, __m128 a10, __m128 a11, __m128 a12, __m128 a13, __m128 a14) { char v14; // al long long v15; // r14 long long v16; // r15 long long v17; // r12 long long v18; // r13 int v19; // eax int v20; // ebp unsigned long long PropertyInternal; // r15 unsigned long long v22; // rcx long long v23; // rax v15 = a5[1]; if ( (_DWORD)v15 != -1 ) { JS_ThrowTypeErrorNotAnObject(a1, a7, a8, a9, a10, a11, a12, a13, a14, a2, a3, a4, (long long)a5, a6, v14); LABEL_7: v23 = 0LL; v22 = 0LL; return v22 | v23; } v16 = *a5; v17 = *a5; v18 = a5[1]; if ( (int)a4 >= 3 ) { v17 = a5[4]; v18 = a5[5]; } v19 = JS_ValueToAtom(a1, a5[2], a5[3]); if ( !v19 ) goto LABEL_7; v20 = v19; PropertyInternal = JS_GetPropertyInternal(a1, v16, v15, v19, v17, v18, 0); JS_FreeAtom(a1, v20); v22 = PropertyInternal & 0xFFFFFFFF00000000LL; v23 = (unsigned int)PropertyInternal; return v22 | v23; }
js_reflect_get: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX PUSH RAX MOV RBX,RDI MOV R14,qword ptr [R8 + 0x8] CMP R14D,-0x1 JNZ 0x0016a1fd MOV R15,qword ptr [R8] MOV RSI,qword ptr [R8 + 0x10] MOV RDX,qword ptr [R8 + 0x18] MOV R12,R15 MOV R13,R14 CMP ECX,0x3 JL 0x0016a1b3 MOV R12,qword ptr [R8 + 0x20] MOV R13,qword ptr [R8 + 0x28] LAB_0016a1b3: MOV RDI,RBX CALL 0x0011e0bc TEST EAX,EAX JZ 0x0016a205 MOV EBP,EAX AND dword ptr [RSP],0x0 MOV RDI,RBX MOV RSI,R15 MOV RDX,R14 MOV ECX,EAX MOV R8,R12 MOV R9,R13 CALL 0x0013963b MOV R15,RAX MOV R14,RDX MOV RDI,RBX MOV ESI,EBP CALL 0x0011a995 MOV RCX,-0x100000000 AND RCX,R15 MOV EAX,R15D JMP 0x0016a20d LAB_0016a1fd: MOV RDI,RBX CALL 0x0011d5e1 LAB_0016a205: PUSH 0x6 POP R14 XOR EAX,EAX XOR ECX,ECX LAB_0016a20d: OR RAX,RCX MOV RDX,R14 ADD RSP,0x8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
int1 [16] js_reflect_get(int8 param_1,int8 param_2,int8 param_3,int param_4, int8 *param_5) { int8 uVar1; int iVar2; int8 in_RAX; uint uVar4; ulong uVar3; ulong uVar5; int8 uVar6; int8 uVar7; int8 uVar8; int1 auVar9 [16]; uVar4 = (uint)((ulong)in_RAX >> 0x20); uVar8 = param_5[1]; if ((int)uVar8 == -1) { uVar1 = *param_5; uVar6 = uVar1; uVar7 = uVar8; if (2 < param_4) { uVar6 = param_5[4]; uVar7 = param_5[5]; } iVar2 = JS_ValueToAtom(param_1,param_5[2],param_5[3]); if (iVar2 != 0) { auVar9 = JS_GetPropertyInternal(param_1,uVar1,uVar8,iVar2,uVar6,uVar7,(ulong)uVar4 << 0x20); uVar8 = auVar9._8_8_; JS_FreeAtom(param_1,iVar2); uVar5 = auVar9._0_8_ & 0xffffffff00000000; uVar3 = auVar9._0_8_ & 0xffffffff; goto LAB_0016a20d; } } else { JS_ThrowTypeErrorNotAnObject(param_1); } uVar8 = 6; uVar3 = 0; uVar5 = 0; LAB_0016a20d: auVar9._0_8_ = uVar3 | uVar5; auVar9._8_8_ = uVar8; return auVar9; }
20,558
ma_test_if_changed
eloqsql/storage/maria/ma_locking.c
int _ma_test_if_changed(register MARIA_HA *info) { #ifdef MARIA_EXTERNAL_LOCKING MARIA_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_pagecache_blocks(share->pagecache, &share->kfile, 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 maria_is_changed */ return 1; } #endif return (!(info->update & HA_STATE_AKTIV) || (info->update & (HA_STATE_WRITTEN | HA_STATE_DELETED | HA_STATE_KEY_CHANGED))); }
O3
c
ma_test_if_changed: pushq %rbp movq %rsp, %rbp movl $0x8e, %ecx andl 0x624(%rdi), %ecx xorl %eax, %eax cmpl $0x2, %ecx setne %al popq %rbp retq
_ma_test_if_changed: push rbp mov rbp, rsp mov ecx, 8Eh and ecx, [rdi+624h] xor eax, eax cmp ecx, 2 setnz al pop rbp retn
_BOOL8 ma_test_if_changed(long long a1) { return (*(_DWORD *)(a1 + 1572) & 0x8E) != 2; }
_ma_test_if_changed: PUSH RBP MOV RBP,RSP MOV ECX,0x8e AND ECX,dword ptr [RDI + 0x624] XOR EAX,EAX CMP ECX,0x2 SETNZ AL POP RBP RET
bool _ma_test_if_changed(long param_1) { return (*(uint *)(param_1 + 0x624) & 0x8e) != 2; }
20,559
tailoring_append
eloqsql/strings/ctype.c
static int tailoring_append(MY_XML_PARSER *st, const char *fmt, size_t len, const char *attr) { struct my_cs_file_info *i= (struct my_cs_file_info *) st->user_data; size_t newlen= i->tailoring_length + len + 64; /* 64 for format */ if (MY_XML_OK == my_charset_file_tailoring_realloc(i, newlen)) { char *dst= i->tailoring + i->tailoring_length; sprintf(dst, fmt, (int) len, attr); i->tailoring_length+= strlen(dst); return MY_XML_OK; } return MY_XML_ERROR; }
O0
c
tailoring_append: pushq %rbp movq %rsp, %rbp subq $0x40, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq %rdx, -0x20(%rbp) movq %rcx, -0x28(%rbp) movq -0x10(%rbp), %rax movq 0x140(%rax), %rax movq %rax, -0x30(%rbp) movq -0x30(%rbp), %rax movq 0x690(%rax), %rax addq -0x20(%rbp), %rax addq $0x40, %rax movq %rax, -0x38(%rbp) movq -0x30(%rbp), %rdi movq -0x38(%rbp), %rsi callq 0x748e0 movl %eax, %ecx xorl %eax, %eax cmpl %ecx, %eax jne 0x748cd movq -0x30(%rbp), %rax movq 0x688(%rax), %rax movq -0x30(%rbp), %rcx addq 0x690(%rcx), %rax movq %rax, -0x40(%rbp) movq -0x40(%rbp), %rdi movq -0x18(%rbp), %rsi movq -0x20(%rbp), %rax movl %eax, %edx movq -0x28(%rbp), %rcx movb $0x0, %al callq 0x240b0 movq -0x40(%rbp), %rdi callq 0x24120 movq %rax, %rcx movq -0x30(%rbp), %rax addq 0x690(%rax), %rcx movq %rcx, 0x690(%rax) movl $0x0, -0x4(%rbp) jmp 0x748d4 movl $0x1, -0x4(%rbp) movl -0x4(%rbp), %eax addq $0x40, %rsp popq %rbp retq nopl (%rax)
tailoring_append: push rbp mov rbp, rsp sub rsp, 40h mov [rbp+var_10], rdi mov [rbp+var_18], rsi mov [rbp+var_20], rdx mov [rbp+var_28], rcx mov rax, [rbp+var_10] mov rax, [rax+140h] mov [rbp+var_30], rax mov rax, [rbp+var_30] mov rax, [rax+690h] add rax, [rbp+var_20] add rax, 40h ; '@' mov [rbp+var_38], rax mov rdi, [rbp+var_30] mov rsi, [rbp+var_38] call my_charset_file_tailoring_realloc mov ecx, eax xor eax, eax cmp eax, ecx jnz short loc_748CD mov rax, [rbp+var_30] mov rax, [rax+688h] mov rcx, [rbp+var_30] add rax, [rcx+690h] mov [rbp+var_40], rax mov rdi, [rbp+var_40] mov rsi, [rbp+var_18] mov rax, [rbp+var_20] mov edx, eax mov rcx, [rbp+var_28] mov al, 0 call _sprintf mov rdi, [rbp+var_40] call _strlen mov rcx, rax mov rax, [rbp+var_30] add rcx, [rax+690h] mov [rax+690h], rcx mov [rbp+var_4], 0 jmp short loc_748D4 loc_748CD: mov [rbp+var_4], 1 loc_748D4: mov eax, [rbp+var_4] add rsp, 40h pop rbp retn
long long tailoring_append(long long a1, const char *a2, long long a3, long long a4) { long long v5; // [rsp+0h] [rbp-40h] long long v6; // [rsp+10h] [rbp-30h] unsigned int v8; // [rsp+20h] [rbp-20h] v8 = a3; v6 = *(_QWORD *)(a1 + 320); if ( (unsigned int)my_charset_file_tailoring_realloc(v6, a3 + *(_QWORD *)(v6 + 1680) + 64) ) { return 1; } else { v5 = *(_QWORD *)(v6 + 1680) + *(_QWORD *)(v6 + 1672); sprintf(v5, a2, v8, a4); *(_QWORD *)(v6 + 1680) += strlen(v5); return 0; } }
tailoring_append: PUSH RBP MOV RBP,RSP SUB RSP,0x40 MOV qword ptr [RBP + -0x10],RDI MOV qword ptr [RBP + -0x18],RSI MOV qword ptr [RBP + -0x20],RDX MOV qword ptr [RBP + -0x28],RCX MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x140] MOV qword ptr [RBP + -0x30],RAX MOV RAX,qword ptr [RBP + -0x30] MOV RAX,qword ptr [RAX + 0x690] ADD RAX,qword ptr [RBP + -0x20] ADD RAX,0x40 MOV qword ptr [RBP + -0x38],RAX MOV RDI,qword ptr [RBP + -0x30] MOV RSI,qword ptr [RBP + -0x38] CALL 0x001748e0 MOV ECX,EAX XOR EAX,EAX CMP EAX,ECX JNZ 0x001748cd MOV RAX,qword ptr [RBP + -0x30] MOV RAX,qword ptr [RAX + 0x688] MOV RCX,qword ptr [RBP + -0x30] ADD RAX,qword ptr [RCX + 0x690] MOV qword ptr [RBP + -0x40],RAX MOV RDI,qword ptr [RBP + -0x40] MOV RSI,qword ptr [RBP + -0x18] MOV RAX,qword ptr [RBP + -0x20] MOV EDX,EAX MOV RCX,qword ptr [RBP + -0x28] MOV AL,0x0 CALL 0x001240b0 MOV RDI,qword ptr [RBP + -0x40] CALL 0x00124120 MOV RCX,RAX MOV RAX,qword ptr [RBP + -0x30] ADD RCX,qword ptr [RAX + 0x690] MOV qword ptr [RAX + 0x690],RCX MOV dword ptr [RBP + -0x4],0x0 JMP 0x001748d4 LAB_001748cd: MOV dword ptr [RBP + -0x4],0x1 LAB_001748d4: MOV EAX,dword ptr [RBP + -0x4] ADD RSP,0x40 POP RBP RET
bool tailoring_append(long param_1,char *param_2,ulong param_3,int8 param_4) { long lVar1; int iVar2; char *__s; size_t sVar3; lVar1 = *(long *)(param_1 + 0x140); iVar2 = my_charset_file_tailoring_realloc(lVar1,*(long *)(lVar1 + 0x690) + param_3 + 0x40); if (iVar2 == 0) { __s = (char *)(*(long *)(lVar1 + 0x688) + *(long *)(lVar1 + 0x690)); sprintf(__s,param_2,param_3 & 0xffffffff,param_4); sVar3 = strlen(__s); *(size_t *)(lVar1 + 0x690) = sVar3 + *(long *)(lVar1 + 0x690); } return iVar2 != 0; }
20,560
bool google::protobuf::internal::WireFormatLite::ReadGroup<google::protobuf::Message>(int, google::protobuf::io::CodedInputStream*, google::protobuf::Message*)
aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/wire_format_lite.h
inline bool WireFormatLite::ReadGroup(int field_number, io::CodedInputStream* input, MessageType* value) { if (!input->IncrementRecursionDepth()) return false; if (!value->MergePartialFromCodedStream(input)) return false; input->UnsafeDecrementRecursionDepth(); // Make sure the last thing read was an end tag for this group. if (!input->LastTagWas(MakeTag(field_number, WIRETYPE_END_GROUP))) { return false; } return true; }
O0
c
bool google::protobuf::internal::WireFormatLite::ReadGroup<google::protobuf::Message>(int, google::protobuf::io::CodedInputStream*, google::protobuf::Message*): subq $0x28, %rsp movl %edi, 0x20(%rsp) movq %rsi, 0x18(%rsp) movq %rdx, 0x10(%rsp) movq 0x18(%rsp), %rdi callq 0x1ab8b0 testb $0x1, %al jne 0x201ff7 movb $0x0, 0x27(%rsp) jmp 0x20204f movq 0x10(%rsp), %rdi movq 0x18(%rsp), %rsi callq 0x173bc0 testb $0x1, %al jne 0x202011 movb $0x0, 0x27(%rsp) jmp 0x20204f movq 0x18(%rsp), %rdi callq 0x20af30 movq 0x18(%rsp), %rax movq %rax, 0x8(%rsp) movl 0x20(%rsp), %edi movl $0x4, %esi callq 0x158f30 movq 0x8(%rsp), %rdi movl %eax, %esi callq 0x1ab900 testb $0x1, %al jne 0x20204a movb $0x0, 0x27(%rsp) jmp 0x20204f movb $0x1, 0x27(%rsp) movb 0x27(%rsp), %al andb $0x1, %al addq $0x28, %rsp retq nopw (%rax,%rax)
_ZN6google8protobuf8internal14WireFormatLite9ReadGroupINS0_7MessageEEEbiPNS0_2io16CodedInputStreamEPT_: sub rsp, 28h mov [rsp+28h+var_8], edi mov [rsp+28h+var_10], rsi mov [rsp+28h+var_18], rdx mov rdi, [rsp+28h+var_10]; this call _ZN6google8protobuf2io16CodedInputStream23IncrementRecursionDepthEv; google::protobuf::io::CodedInputStream::IncrementRecursionDepth(void) test al, 1 jnz short loc_201FF7 mov [rsp+28h+var_1], 0 jmp short loc_20204F loc_201FF7: mov rdi, [rsp+28h+var_18]; this mov rsi, [rsp+28h+var_10]; google::protobuf::io::CodedInputStream * call _ZN6google8protobuf11MessageLite27MergePartialFromCodedStreamEPNS0_2io16CodedInputStreamE; google::protobuf::MessageLite::MergePartialFromCodedStream(google::protobuf::io::CodedInputStream *) test al, 1 jnz short loc_202011 mov [rsp+28h+var_1], 0 jmp short loc_20204F loc_202011: mov rdi, [rsp+28h+var_10]; this call _ZN6google8protobuf2io16CodedInputStream29UnsafeDecrementRecursionDepthEv; google::protobuf::io::CodedInputStream::UnsafeDecrementRecursionDepth(void) mov rax, [rsp+28h+var_10] mov [rsp+28h+var_20], rax mov edi, [rsp+28h+var_8] mov esi, 4 call _ZN6google8protobuf8internal14WireFormatLite7MakeTagEiNS2_8WireTypeE; google::protobuf::internal::WireFormatLite::MakeTag(int,google::protobuf::internal::WireFormatLite::WireType) mov rdi, [rsp+28h+var_20]; this mov esi, eax; unsigned int call _ZN6google8protobuf2io16CodedInputStream10LastTagWasEj; google::protobuf::io::CodedInputStream::LastTagWas(uint) test al, 1 jnz short loc_20204A mov [rsp+28h+var_1], 0 jmp short loc_20204F loc_20204A: mov [rsp+28h+var_1], 1 loc_20204F: mov al, [rsp+28h+var_1] and al, 1 add rsp, 28h retn
bool google::protobuf::internal::WireFormatLite::ReadGroup<google::protobuf::Message>( int a1, google::protobuf::io::CodedInputStream *a2, google::protobuf::MessageLite *a3) { int Tag; // eax if ( google::protobuf::io::CodedInputStream::IncrementRecursionDepth(a2) ) { if ( (google::protobuf::MessageLite::MergePartialFromCodedStream(a3, a2) & 1) != 0 ) { google::protobuf::io::CodedInputStream::UnsafeDecrementRecursionDepth(a2); Tag = google::protobuf::internal::WireFormatLite::MakeTag(a1, 4); return google::protobuf::io::CodedInputStream::LastTagWas(a2, Tag); } else { return 0; } } else { return 0; } }
__destroy<char*>: MOV qword ptr [RSP + -0x8],RDI MOV qword ptr [RSP + -0x10],RSI RET
/* void std::_Destroy_aux<true>::__destroy<char*>(char*, char*) */ void std::_Destroy_aux<true>::__destroy<char*>(char *param_1,char *param_2) { return; }
20,561
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>::operator[](std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>)
monkey531[P]llama/common/json.hpp
reference operator[](typename object_t::key_type key) { // implicitly convert null value to an empty object if (is_null()) { m_data.m_type = value_t::object; m_data.m_value.object = create<object_t>(); assert_invariant(); } // operator[] only works for objects if (JSON_HEDLEY_LIKELY(is_object())) { auto result = m_data.m_value.object->emplace(std::move(key), nullptr); return set_parent(result.first->second); } JSON_THROW(type_error::create(305, detail::concat("cannot use operator[] with a string argument with ", type_name()), this)); }
O3
cpp
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>::operator[](std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>): pushq %rbp pushq %r15 pushq %r14 pushq %rbx subq $0x28, %rsp movq %rsi, %rbx movq %rdi, %r14 movb (%rdi), %al testb %al, %al jne 0xab300 movb $0x1, (%r14) movl $0x20, %edi callq 0x1a8b0 xorps %xmm0, %xmm0 movups %xmm0, (%rax) movq $0x0, 0x10(%rax) movq %rax, 0x8(%r14) movq %r14, %rdi movl $0x1, %esi callq 0x586c0 movb (%r14), %al cmpb $0x1, %al jne 0xab369 movq 0x8(%r14), %r14 movq %rsp, %r15 movb $0x0, (%r15) movq $0x0, 0x8(%r15) movq %r15, %rdi movl $0x1, %esi callq 0x586c0 movq %r15, %rdi movl $0x1, %esi callq 0x586c0 movq %r14, %rdi movq %rbx, %rsi movq %r15, %rdx callq 0x5f25a movq %rax, %rbx movq %rsp, %r14 movq %r14, %rdi xorl %esi, %esi callq 0x586c0 movq %r14, %rdi callq 0x5dbae addq $0x20, %rbx movq %rbx, %rax addq $0x28, %rsp popq %rbx popq %r14 popq %r15 popq %rbp retq movl $0x20, %edi callq 0x1a450 movq %rax, %rbx movq %r14, %rdi callq 0x5ebd0 leaq 0x20(%rsp), %rdx movq %rax, (%rdx) leaq 0x45bd7(%rip), %rsi # 0xf0f64 movq %rsp, %rdi callq 0xab415 movb $0x1, %bpl movq %rsp, %rdx movq %rbx, %rdi movl $0x131, %esi # imm = 0x131 movq %r14, %rcx callq 0x5e978 xorl %ebp, %ebp leaq 0x7eba4(%rip), %rsi # 0x129f58 leaq -0x5057d(%rip), %rdx # 0x5ae3e movq %rbx, %rdi callq 0x1af40 movq %rax, %r14 movq %rsp, %rbx movq %rbx, %rdi xorl %esi, %esi callq 0x586c0 movq %rbx, %rdi callq 0x5dbae jmp 0xab40d movq %rax, %r14 leaq 0x10(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0xab3fb movq 0x10(%rsp), %rsi incq %rsi callq 0x1a8d0 testb %bpl, %bpl jne 0xab405 jmp 0xab40d movq %rax, %r14 movq %rbx, %rdi callq 0x1a680 movq %r14, %rdi callq 0x1afc0
_ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEixES9_: push rbp; char push r15; int push r14; __int64 push rbx; int sub rsp, 28h mov rbx, rsi mov r14, rdi mov al, [rdi] test al, al jnz short loc_AB300 mov byte ptr [r14], 1 mov edi, 20h ; ' '; unsigned __int64 call __Znwm; operator new(ulong) xorps xmm0, xmm0 movups xmmword ptr [rax], xmm0 mov qword ptr [rax+10h], 0 mov [r14+8], rax mov rdi, r14 mov esi, 1 call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::assert_invariant(bool) mov al, [r14] loc_AB300: cmp al, 1 jnz short loc_AB369 mov r14, [r14+8] mov r15, rsp mov byte ptr [r15], 0 mov qword ptr [r15+8], 0 mov rdi, r15 mov esi, 1 call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::assert_invariant(bool) mov rdi, r15 mov esi, 1 call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::assert_invariant(bool) mov rdi, r14 mov rsi, rbx mov rdx, r15 call _ZN8nlohmann16json_abi_v3_11_311ordered_mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEENS0_10basic_jsonIS1_St6vectorS7_blmdSaNS0_14adl_serializerES9_IhSaIhEEvEESt4lessIvESaISt4pairIKS7_SD_EEE7emplaceERSH_OSD_; nlohmann::json_abi_v3_11_3::ordered_map<std::string,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>,std::less<void>,std::allocator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>>::emplace(std::string const&,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>&&) mov rbx, rax mov r14, rsp mov rdi, r14 xor esi, esi call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::assert_invariant(bool) mov rdi, r14 call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE4dataD2Ev; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::data::~data() add rbx, 20h ; ' ' mov rax, rbx add rsp, 28h pop rbx pop r14 pop r15 pop rbp retn loc_AB369: mov edi, 20h ; ' '; thrown_size call ___cxa_allocate_exception mov rbx, rax mov rdi, r14 call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE9type_nameEv; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::type_name(void) lea rdx, [rsp+48h+var_28] mov [rdx], rax lea rsi, aCannotUseOpera_0; "cannot use operator[] with a string arg"... mov rdi, rsp call _ZN8nlohmann16json_abi_v3_11_36detail6concatINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEJRA51_KcPS9_EEET_DpOT0_; nlohmann::json_abi_v3_11_3::detail::concat<std::string,char const(&)[51],char const*>(char const(&)[51],char const* &&) mov bpl, 1 mov rdx, rsp mov rdi, rbx; this mov esi, 131h; int mov rcx, r14 call _ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIPNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SJ_ xor ebp, ebp lea rsi, _ZTIN8nlohmann16json_abi_v3_11_36detail10type_errorE; lptinfo lea rdx, _ZN8nlohmann16json_abi_v3_11_36detail9exceptionD2Ev; void (*)(void *) mov rdi, rbx; void * call ___cxa_throw mov r14, rax mov rbx, rsp mov rdi, rbx xor esi, esi call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::assert_invariant(bool) mov rdi, rbx call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE4dataD2Ev; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::data::~data() jmp short loc_AB40D mov r14, rax lea rax, [rsp+48h+var_38] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_AB3FB mov rsi, [rsp+48h+var_38] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_AB3FB: test bpl, bpl jnz short loc_AB405 jmp short loc_AB40D mov r14, rax loc_AB405: mov rdi, rbx; void * call ___cxa_free_exception loc_AB40D: mov rdi, r14 call __Unwind_Resume
long long nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::operator[]( long long a1, long long *a2) { char v2; // al long long v3; // rax _QWORD *v4; // r14 long long v5; // rbx nlohmann::json_abi_v3_11_3::detail::exception *exception; // rbx _QWORD v8[9]; // [rsp+0h] [rbp-48h] BYREF v2 = *(_BYTE *)a1; if ( !*(_BYTE *)a1 ) { *(_BYTE *)a1 = 1; v3 = operator new(0x20uLL); *(_OWORD *)v3 = 0LL; *(_QWORD *)(v3 + 16) = 0LL; *(_QWORD *)(a1 + 8) = v3; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::assert_invariant((char *)a1); v2 = *(_BYTE *)a1; } if ( v2 != 1 ) { exception = (nlohmann::json_abi_v3_11_3::detail::exception *)__cxa_allocate_exception(0x20uLL); v8[4] = nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::type_name((unsigned __int8 *)a1); nlohmann::json_abi_v3_11_3::detail::concat<std::string,char const(&)[51],char const*>( v8, "cannot use operator[] with a string argument with "); ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIPNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SJ_( exception, 305, v8); __cxa_throw( exception, (struct type_info *)&`typeinfo for'nlohmann::json_abi_v3_11_3::detail::type_error, (void (*)(void *))nlohmann::json_abi_v3_11_3::detail::exception::~exception); } v4 = *(_QWORD **)(a1 + 8); LOBYTE(v8[0]) = 0; v8[1] = 0LL; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::assert_invariant((char *)v8); nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::assert_invariant((char *)v8); v5 = nlohmann::json_abi_v3_11_3::ordered_map<std::string,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,std::less<void>,std::allocator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>>>::emplace( v4, a2, (long long)v8); nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::assert_invariant((char *)v8); 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(v8); return v5 + 32; }
operator[]: PUSH RBP PUSH R15 PUSH R14 PUSH RBX SUB RSP,0x28 MOV RBX,RSI MOV R14,RDI MOV AL,byte ptr [RDI] TEST AL,AL JNZ 0x001ab300 MOV byte ptr [R14],0x1 MOV EDI,0x20 CALL 0x0011a8b0 XORPS XMM0,XMM0 MOVUPS xmmword ptr [RAX],XMM0 MOV qword ptr [RAX + 0x10],0x0 MOV qword ptr [R14 + 0x8],RAX MOV RDI,R14 MOV ESI,0x1 CALL 0x001586c0 MOV AL,byte ptr [R14] LAB_001ab300: CMP AL,0x1 JNZ 0x001ab369 MOV R14,qword ptr [R14 + 0x8] MOV R15,RSP MOV byte ptr [R15],0x0 MOV qword ptr [R15 + 0x8],0x0 MOV RDI,R15 MOV ESI,0x1 CALL 0x001586c0 MOV RDI,R15 MOV ESI,0x1 CALL 0x001586c0 LAB_001ab331: MOV RDI,R14 MOV RSI,RBX MOV RDX,R15 CALL 0x0015f25a LAB_001ab33f: MOV RBX,RAX MOV R14,RSP MOV RDI,R14 XOR ESI,ESI CALL 0x001586c0 MOV RDI,R14 CALL 0x0015dbae ADD RBX,0x20 MOV RAX,RBX ADD RSP,0x28 POP RBX POP R14 POP R15 POP RBP RET LAB_001ab369: MOV EDI,0x20 CALL 0x0011a450 MOV RBX,RAX MOV RDI,R14 CALL 0x0015ebd0 LEA RDX,[RSP + 0x20] MOV qword ptr [RDX],RAX LAB_001ab386: LEA RSI,[0x1f0f64] MOV RDI,RSP CALL 0x001ab415 MOV BPL,0x1 LAB_001ab398: MOV RDX,RSP MOV RDI,RBX MOV ESI,0x131 MOV RCX,R14 CALL 0x0015e978 XOR EBP,EBP LEA RSI,[0x229f58] LEA RDX,[0x15ae3e] MOV RDI,RBX CALL 0x0011af40
/* nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char> >, void>::operator[](std::__cxx11::string) */ long __thiscall nlohmann::json_abi_v3_11_3:: basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> ::operator[](basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> *this,string *param_2) { ordered_map<std::__cxx11::string,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,std::less<void>,std::allocator<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>> *this_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> bVar1; int8 *puVar2; long lVar3; int8 uVar4; bool bVar5; basic_json local_48 [8]; int8 local_40; char *local_28; bVar1 = *this; if (bVar1 == (basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> )0x0) { *this = (basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> )0x1; puVar2 = (int8 *)operator_new(0x20); *puVar2 = 0; puVar2[1] = 0; puVar2[2] = 0; *(int8 **)(this + 8) = puVar2; assert_invariant(SUB81(this,0)); bVar1 = *this; } if (bVar1 == (basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> )0x1) { this_00 = *(ordered_map<std::__cxx11::string,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,std::less<void>,std::allocator<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>> **)(this + 8); local_48[0] = (basic_json)0x0; local_40 = 0; bVar5 = SUB81(local_48,0); assert_invariant(bVar5); assert_invariant(bVar5); /* try { // try from 001ab331 to 001ab33e has its CatchHandler @ 001ab3c3 */ lVar3 = ordered_map<std::__cxx11::string,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,std::less<void>,std::allocator<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>> ::emplace(this_00,param_2,local_48); assert_invariant(bVar5); data::~data((data *)local_48); return lVar3 + 0x20; } uVar4 = __cxa_allocate_exception(0x20); local_28 = (char *)type_name(this); /* try { // try from 001ab386 to 001ab394 has its CatchHandler @ 001ab402 */ detail::concat<std::__cxx11::string,char_const(&)[51],char_const*> ((detail *)local_48,"cannot use operator[] with a string argument with ",&local_28); /* try { // try from 001ab398 to 001ab3c2 has its CatchHandler @ 001ab3dd */ _ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIPNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SJ_ (uVar4,0x131,local_48,this); /* WARNING: Subroutine does not return */ __cxa_throw(uVar4,&detail::type_error::typeinfo,detail::exception::~exception); }
20,562
google::protobuf::compiler::cpp::FileGenerator::GenerateProtoHeader(google::protobuf::io::Printer*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&)
aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/compiler/cpp/file.cc
void FileGenerator::GenerateProtoHeader(io::Printer* printer, const std::string& info_path) { Formatter format(printer, variables_); if (!options_.proto_h) { return; } GenerateTopHeaderGuard(printer, false); if (!options_.opensource_runtime) { format( "#ifdef SWIG\n" "#error \"Do not SWIG-wrap protobufs.\"\n" "#endif // SWIG\n" "\n"); } if (IsBootstrapProto(options_, file_)) { format("// IWYU pragma: private, include \"$1$.proto.h\"\n\n", StripProto(file_->name())); } GenerateLibraryIncludes(printer); for (int i = 0; i < file_->public_dependency_count(); i++) { const FileDescriptor* dep = file_->public_dependency(i); format("#include \"$1$.proto.h\"\n", StripProto(dep->name())); } format("// @@protoc_insertion_point(includes)\n"); GenerateMetadataPragma(printer, info_path); GenerateHeader(printer); GenerateBottomHeaderGuard(printer, false); }
O0
cpp
google::protobuf::compiler::cpp::FileGenerator::GenerateProtoHeader(google::protobuf::io::Printer*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&): subq $0xe8, %rsp movq %rdi, 0xe0(%rsp) movq %rsi, 0xd8(%rsp) movq %rdx, 0xd0(%rsp) movq 0xe0(%rsp), %rdx movq %rdx, 0x28(%rsp) movq 0xd8(%rsp), %rsi addq $0x290, %rdx # imm = 0x290 leaq 0x98(%rsp), %rdi callq 0xdf0d0 movq 0x28(%rsp), %rax testb $0x1, 0x105(%rax) jne 0xd6eb6 movl $0x1, 0x94(%rsp) jmp 0xd70e7 movq 0x28(%rsp), %rdi movq 0xd8(%rsp), %rsi xorl %edx, %edx callq 0xd7120 jmp 0xd6ecc movq 0x28(%rsp), %rax testb $0x1, 0x10a(%rax) jne 0xd6f0b leaq 0x2e1d09(%rip), %rsi # 0x3b8bea leaq 0x98(%rsp), %rdi callq 0x5ae90 jmp 0xd6ef0 jmp 0xd6f0b movq %rax, %rcx movl %edx, %eax movq %rcx, 0x88(%rsp) movl %eax, 0x84(%rsp) jmp 0xd70fc movq 0x28(%rsp), %rax movq %rax, %rdi addq $0x38, %rdi movq 0x30(%rax), %rsi callq 0x56be0 movb %al, 0x27(%rsp) jmp 0xd6f26 movb 0x27(%rsp), %al testb $0x1, %al jne 0xd6f30 jmp 0xd6fa0 movq 0x28(%rsp), %rax movq 0x30(%rax), %rdi callq 0x28990 movq %rax, 0x18(%rsp) jmp 0xd6f45 movq 0x18(%rsp), %rsi leaq 0x60(%rsp), %rdi callq 0x53710 jmp 0xd6f56 leaq 0x2e1cd0(%rip), %rsi # 0x3b8c2d leaq 0x98(%rsp), %rdi leaq 0x60(%rsp), %rdx callq 0x5b1d0 jmp 0xd6f71 leaq 0x60(%rsp), %rdi callq 0x21cc8 jmp 0xd6fa0 movq %rax, %rcx movl %edx, %eax movq %rcx, 0x88(%rsp) movl %eax, 0x84(%rsp) leaq 0x60(%rsp), %rdi callq 0x21cc8 jmp 0xd70fc movq 0x28(%rsp), %rdi movq 0xd8(%rsp), %rsi callq 0xd7240 jmp 0xd6fb4 movl $0x0, 0x5c(%rsp) movq 0x28(%rsp), %rax movl 0x5c(%rsp), %ecx movl %ecx, 0x10(%rsp) movq 0x30(%rax), %rdi callq 0xbf480 movl %eax, 0x14(%rsp) jmp 0xd6fd8 movl 0x10(%rsp), %eax movl 0x14(%rsp), %ecx cmpl %ecx, %eax jge 0xd7080 movq 0x28(%rsp), %rax movq 0x30(%rax), %rdi movl 0x5c(%rsp), %esi callq 0xbf490 movq %rax, 0x8(%rsp) jmp 0xd7001 movq 0x8(%rsp), %rax movq %rax, 0x50(%rsp) movq 0x50(%rsp), %rdi callq 0x28990 movq %rax, (%rsp) jmp 0xd701b movq (%rsp), %rsi leaq 0x30(%rsp), %rdi callq 0x53710 jmp 0xd702b leaq 0x2e1c2c(%rip), %rsi # 0x3b8c5e leaq 0x98(%rsp), %rdi leaq 0x30(%rsp), %rdx callq 0x5b1d0 jmp 0xd7046 leaq 0x30(%rsp), %rdi callq 0x21cc8 movl 0x5c(%rsp), %eax addl $0x1, %eax movl %eax, 0x5c(%rsp) jmp 0xd6fbc movq %rax, %rcx movl %edx, %eax movq %rcx, 0x88(%rsp) movl %eax, 0x84(%rsp) leaq 0x30(%rsp), %rdi callq 0x21cc8 jmp 0xd70fc leaq 0x2e1bef(%rip), %rsi # 0x3b8c76 leaq 0x98(%rsp), %rdi callq 0x5ae90 jmp 0xd7096 movq 0x28(%rsp), %rdi movq 0xd8(%rsp), %rsi movq 0xd0(%rsp), %rdx callq 0xd8e70 jmp 0xd70b2 movq 0x28(%rsp), %rdi movq 0xd8(%rsp), %rsi callq 0xd57f0 jmp 0xd70c6 movq 0x28(%rsp), %rdi movq 0xd8(%rsp), %rsi xorl %edx, %edx callq 0xd9120 jmp 0xd70dc movl $0x0, 0x94(%rsp) leaq 0x98(%rsp), %rdi callq 0xdf130 addq $0xe8, %rsp retq leaq 0x98(%rsp), %rdi callq 0xdf130 movq 0x88(%rsp), %rdi callq 0x21700 nopw %cs:(%rax,%rax)
_ZN6google8protobuf8compiler3cpp13FileGenerator19GenerateProtoHeaderEPNS0_2io7PrinterERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE: sub rsp, 0E8h mov [rsp+0E8h+var_8], rdi mov [rsp+0E8h+var_10], rsi mov [rsp+0E8h+var_18], rdx mov rdx, [rsp+0E8h+var_8] mov [rsp+0E8h+var_C0], rdx mov rsi, [rsp+0E8h+var_10] add rdx, 290h lea rdi, [rsp+0E8h+var_50] call _ZN6google8protobuf8compiler3cpp9FormatterC2EPNS0_2io7PrinterERKSt3mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESD_St4lessISD_ESaISt4pairIKSD_SD_EEE; google::protobuf::compiler::cpp::Formatter::Formatter(google::protobuf::io::Printer *,std::map<std::string,std::string> const&) mov rax, [rsp+0E8h+var_C0] test byte ptr [rax+105h], 1 jnz short loc_D6EB6 mov [rsp+0E8h+var_54], 1 jmp loc_D70E7 loc_D6EB6: mov rdi, [rsp+0E8h+var_C0]; this mov rsi, [rsp+0E8h+var_10]; google::protobuf::io::Printer * xor edx, edx; bool call _ZN6google8protobuf8compiler3cpp13FileGenerator22GenerateTopHeaderGuardEPNS0_2io7PrinterEb; google::protobuf::compiler::cpp::FileGenerator::GenerateTopHeaderGuard(google::protobuf::io::Printer *,bool) jmp short $+2 loc_D6ECC: mov rax, [rsp+0E8h+var_C0] test byte ptr [rax+10Ah], 1 jnz short loc_D6F0B lea rsi, aIfdefSwigError; "#ifdef SWIG\n#error \"Do not SWIG-wrap "... lea rdi, [rsp+0E8h+var_50] call _ZNK6google8protobuf8compiler3cpp9FormatterclIJEEEvPKcDpRKT_ jmp short $+2 loc_D6EF0: jmp short loc_D6F0B mov rcx, rax mov eax, edx mov [rsp+arg_80], rcx mov [rsp+arg_7C], eax jmp loc_D70FC loc_D6F0B: mov rax, [rsp+0E8h+var_C0] mov rdi, rax add rdi, 38h ; '8'; this mov rsi, [rax+30h]; google::protobuf::compiler::cpp::Options * call _ZN6google8protobuf8compiler3cpp16IsBootstrapProtoERKNS2_7OptionsEPKNS0_14FileDescriptorE; google::protobuf::compiler::cpp::IsBootstrapProto(google::protobuf::compiler::cpp::Options const&,google::protobuf::FileDescriptor const*) mov [rsp+0E8h+var_C1], al jmp short $+2 loc_D6F26: mov al, [rsp+0E8h+var_C1] test al, 1 jnz short loc_D6F30 jmp short loc_D6FA0 loc_D6F30: mov rax, [rsp+0E8h+var_C0] mov rdi, [rax+30h] call _ZNK6google8protobuf14FileDescriptor4nameB5cxx11Ev; google::protobuf::FileDescriptor::name(void) mov [rsp+0E8h+var_D0], rax jmp short $+2 loc_D6F45: mov rsi, [rsp+0E8h+var_D0] lea rdi, [rsp+0E8h+var_88] call _ZN6google8protobuf8compiler3cpp10StripProtoERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; google::protobuf::compiler::cpp::StripProto(std::string const&) jmp short $+2 loc_D6F56: lea rsi, aIwyuPragmaPriv; "// IWYU pragma: private, include \"$1$."... lea rdi, [rsp+0E8h+var_50] lea rdx, [rsp+0E8h+var_88] call _ZNK6google8protobuf8compiler3cpp9FormatterclIJNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEEEvPKcDpRKT_; google::protobuf::compiler::cpp::Formatter::operator()<std::string>(char const*,std::string const&) jmp short $+2 loc_D6F71: lea rdi, [rsp+0E8h+var_88]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string() jmp short loc_D6FA0 mov rcx, rax mov eax, edx mov [rsp+arg_80], rcx mov [rsp+arg_7C], eax lea rdi, [rsp+arg_58]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string() jmp loc_D70FC loc_D6FA0: mov rdi, [rsp+0E8h+var_C0]; this mov rsi, [rsp+0E8h+var_10]; google::protobuf::io::Printer * call _ZN6google8protobuf8compiler3cpp13FileGenerator23GenerateLibraryIncludesEPNS0_2io7PrinterE; google::protobuf::compiler::cpp::FileGenerator::GenerateLibraryIncludes(google::protobuf::io::Printer *) jmp short $+2 loc_D6FB4: mov [rsp+0E8h+var_8C], 0 loc_D6FBC: mov rax, [rsp+0E8h+var_C0] mov ecx, [rsp+0E8h+var_8C] mov [rsp+0E8h+var_D8], ecx mov rdi, [rax+30h]; this call _ZNK6google8protobuf14FileDescriptor23public_dependency_countEv; google::protobuf::FileDescriptor::public_dependency_count(void) mov [rsp+0E8h+var_D4], eax jmp short $+2 loc_D6FD8: mov eax, [rsp+0E8h+var_D8] mov ecx, [rsp+0E8h+var_D4] cmp eax, ecx jge loc_D7080 mov rax, [rsp+0E8h+var_C0] mov rdi, [rax+30h]; this mov esi, [rsp+0E8h+var_8C]; int call _ZNK6google8protobuf14FileDescriptor17public_dependencyEi; google::protobuf::FileDescriptor::public_dependency(int) mov [rsp+0E8h+var_E0], rax jmp short $+2 loc_D7001: mov rax, [rsp+0E8h+var_E0] mov [rsp+0E8h+var_98], rax mov rdi, [rsp+0E8h+var_98] call _ZNK6google8protobuf14FileDescriptor4nameB5cxx11Ev; google::protobuf::FileDescriptor::name(void) mov [rsp+0E8h+var_E8], rax jmp short $+2 loc_D701B: mov rsi, [rsp+0E8h+var_E8] lea rdi, [rsp+0E8h+var_B8] call _ZN6google8protobuf8compiler3cpp10StripProtoERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; google::protobuf::compiler::cpp::StripProto(std::string const&) jmp short $+2 loc_D702B: lea rsi, aInclude1ProtoH; "#include \"$1$.proto.h\"\n" lea rdi, [rsp+0E8h+var_50] lea rdx, [rsp+0E8h+var_B8] call _ZNK6google8protobuf8compiler3cpp9FormatterclIJNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEEEvPKcDpRKT_; google::protobuf::compiler::cpp::Formatter::operator()<std::string>(char const*,std::string const&) jmp short $+2 loc_D7046: lea rdi, [rsp+0E8h+var_B8]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string() mov eax, [rsp+0E8h+var_8C] add eax, 1 mov [rsp+0E8h+var_8C], eax jmp loc_D6FBC mov rcx, rax mov eax, edx mov [rsp+arg_80], rcx mov [rsp+arg_7C], eax lea rdi, [rsp+arg_28]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string() jmp short loc_D70FC loc_D7080: lea rsi, aProtocInsertio_8; "// @@protoc_insertion_point(includes)\n" lea rdi, [rsp+0E8h+var_50] call _ZNK6google8protobuf8compiler3cpp9FormatterclIJEEEvPKcDpRKT_ jmp short $+2 loc_D7096: mov rdi, [rsp+0E8h+var_C0] mov rsi, [rsp+0E8h+var_10] mov rdx, [rsp+0E8h+var_18] call _ZN6google8protobuf8compiler3cpp13FileGenerator22GenerateMetadataPragmaEPNS0_2io7PrinterERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; google::protobuf::compiler::cpp::FileGenerator::GenerateMetadataPragma(google::protobuf::io::Printer *,std::string const&) jmp short $+2 loc_D70B2: mov rdi, [rsp+0E8h+var_C0]; this mov rsi, [rsp+0E8h+var_10]; google::protobuf::io::Printer * call _ZN6google8protobuf8compiler3cpp13FileGenerator14GenerateHeaderEPNS0_2io7PrinterE; google::protobuf::compiler::cpp::FileGenerator::GenerateHeader(google::protobuf::io::Printer *) jmp short $+2 loc_D70C6: mov rdi, [rsp+0E8h+var_C0]; this mov rsi, [rsp+0E8h+var_10]; google::protobuf::io::Printer * xor edx, edx; bool call _ZN6google8protobuf8compiler3cpp13FileGenerator25GenerateBottomHeaderGuardEPNS0_2io7PrinterEb; google::protobuf::compiler::cpp::FileGenerator::GenerateBottomHeaderGuard(google::protobuf::io::Printer *,bool) jmp short $+2 loc_D70DC: mov [rsp+0E8h+var_54], 0 loc_D70E7: lea rdi, [rsp+0E8h+var_50]; this call _ZN6google8protobuf8compiler3cpp9FormatterD2Ev; google::protobuf::compiler::cpp::Formatter::~Formatter() add rsp, 0E8h retn loc_D70FC: lea rdi, [rsp+arg_90]; this call _ZN6google8protobuf8compiler3cpp9FormatterD2Ev; google::protobuf::compiler::cpp::Formatter::~Formatter() mov rdi, [rsp+arg_80] call __Unwind_Resume
void google::protobuf::compiler::cpp::FileGenerator::GenerateProtoHeader( long long a1, google::protobuf::io::Printer *a2, long long a3) { const google::protobuf::FileDescriptor *v3; // rdx int v4; // ecx int v5; // r8d int v6; // r9d int v7; // edx int v8; // ecx int v9; // r8d int v10; // r9d int v11; // ecx int v12; // r8d int v13; // r9d long long v14; // [rsp+0h] [rbp-E8h] long long v15; // [rsp+8h] [rbp-E0h] int v16; // [rsp+10h] [rbp-D8h] long long v17; // [rsp+18h] [rbp-D0h] _BYTE v18[32]; // [rsp+30h] [rbp-B8h] BYREF long long v19; // [rsp+50h] [rbp-98h] int i; // [rsp+5Ch] [rbp-8Ch] _BYTE v21[52]; // [rsp+60h] [rbp-88h] BYREF int v22; // [rsp+94h] [rbp-54h] _QWORD v23[7]; // [rsp+98h] [rbp-50h] BYREF long long v24; // [rsp+D0h] [rbp-18h] google::protobuf::io::Printer *v25; // [rsp+D8h] [rbp-10h] long long v26; // [rsp+E0h] [rbp-8h] v26 = a1; v25 = a2; v24 = a3; google::protobuf::compiler::cpp::Formatter::Formatter(v23, a2, a1 + 656); if ( (*(_BYTE *)(a1 + 261) & 1) != 0 ) { google::protobuf::compiler::cpp::FileGenerator::GenerateTopHeaderGuard( (google::protobuf::compiler::cpp::FileGenerator *)a1, v25, 0); if ( (*(_BYTE *)(a1 + 266) & 1) == 0 ) google::protobuf::compiler::cpp::Formatter::operator()<>( (unsigned int)v23, (unsigned int)"#ifdef SWIG\n#error \"Do not SWIG-wrap protobufs.\"\n#endif // SWIG\n\n", (_DWORD)v3, v4, v5, v6); if ( (google::protobuf::compiler::cpp::IsBootstrapProto( (google::protobuf::compiler::cpp *)(a1 + 56), *(const google::protobuf::compiler::cpp::Options **)(a1 + 48), v3) & 1) != 0 ) { v17 = google::protobuf::FileDescriptor::name[abi:cxx11](*(_QWORD *)(a1 + 48)); google::protobuf::compiler::cpp::StripProto((long long)v21, v17); google::protobuf::compiler::cpp::Formatter::operator()<std::string>( v23, (long long)"// IWYU pragma: private, include \"$1$.proto.h\"\n\n", (long long)v21); std::string::~string(v21); } google::protobuf::compiler::cpp::FileGenerator::GenerateLibraryIncludes( (google::protobuf::compiler::cpp::FileGenerator *)a1, v25); for ( i = 0; ; ++i ) { v16 = i; v8 = google::protobuf::FileDescriptor::public_dependency_count(*(google::protobuf::FileDescriptor **)(a1 + 48)); if ( v16 >= v8 ) break; v15 = google::protobuf::FileDescriptor::public_dependency(*(google::protobuf::FileDescriptor **)(a1 + 48), i); v19 = v15; v14 = google::protobuf::FileDescriptor::name[abi:cxx11](v15); google::protobuf::compiler::cpp::StripProto((long long)v18, v14); google::protobuf::compiler::cpp::Formatter::operator()<std::string>( v23, (long long)"#include \"$1$.proto.h\"\n", (long long)v18); std::string::~string(v18); } google::protobuf::compiler::cpp::Formatter::operator()<>( (unsigned int)v23, (unsigned int)"// @@protoc_insertion_point(includes)\n", v7, v8, v9, v10); google::protobuf::compiler::cpp::FileGenerator::GenerateMetadataPragma( a1, (_DWORD)v25, v24, v11, v12, v13, v14, v15, v16, v17); google::protobuf::compiler::cpp::FileGenerator::GenerateHeader( (google::protobuf::compiler::cpp::FileGenerator *)a1, v25); google::protobuf::compiler::cpp::FileGenerator::GenerateBottomHeaderGuard( (google::protobuf::compiler::cpp::FileGenerator *)a1, v25, 0); v22 = 0; } else { v22 = 1; } google::protobuf::compiler::cpp::Formatter::~Formatter((google::protobuf::compiler::cpp::Formatter *)v23); }
GenerateProtoHeader: SUB RSP,0xe8 MOV qword ptr [RSP + 0xe0],RDI MOV qword ptr [RSP + 0xd8],RSI MOV qword ptr [RSP + 0xd0],RDX MOV RDX,qword ptr [RSP + 0xe0] MOV qword ptr [RSP + 0x28],RDX MOV RSI,qword ptr [RSP + 0xd8] ADD RDX,0x290 LEA RDI,[RSP + 0x98] CALL 0x001df0d0 MOV RAX,qword ptr [RSP + 0x28] TEST byte ptr [RAX + 0x105],0x1 JNZ 0x001d6eb6 MOV dword ptr [RSP + 0x94],0x1 JMP 0x001d70e7 LAB_001d6eb6: MOV RDI,qword ptr [RSP + 0x28] MOV RSI,qword ptr [RSP + 0xd8] LAB_001d6ec3: XOR EDX,EDX CALL 0x001d7120 JMP 0x001d6ecc LAB_001d6ecc: MOV RAX,qword ptr [RSP + 0x28] TEST byte ptr [RAX + 0x10a],0x1 JNZ 0x001d6f0b LEA RSI,[0x4b8bea] LEA RDI,[RSP + 0x98] CALL 0x0015ae90 JMP 0x001d6ef0 LAB_001d6ef0: JMP 0x001d6f0b LAB_001d6f0b: MOV RAX,qword ptr [RSP + 0x28] MOV RDI,RAX ADD RDI,0x38 MOV RSI,qword ptr [RAX + 0x30] CALL 0x00156be0 MOV byte ptr [RSP + 0x27],AL JMP 0x001d6f26 LAB_001d6f26: MOV AL,byte ptr [RSP + 0x27] TEST AL,0x1 JNZ 0x001d6f30 JMP 0x001d6fa0 LAB_001d6f30: MOV RAX,qword ptr [RSP + 0x28] MOV RDI,qword ptr [RAX + 0x30] CALL 0x00128990 MOV qword ptr [RSP + 0x18],RAX JMP 0x001d6f45 LAB_001d6f45: MOV RSI,qword ptr [RSP + 0x18] LEA RDI,[RSP + 0x60] CALL 0x00153710 JMP 0x001d6f56 LAB_001d6f56: LEA RSI,[0x4b8c2d] LEA RDI,[RSP + 0x98] LEA RDX,[RSP + 0x60] CALL 0x0015b1d0 JMP 0x001d6f71 LAB_001d6f71: LEA RDI,[RSP + 0x60] CALL 0x00121cc8 JMP 0x001d6fa0 LAB_001d6fa0: MOV RDI,qword ptr [RSP + 0x28] MOV RSI,qword ptr [RSP + 0xd8] LAB_001d6fad: CALL 0x001d7240 JMP 0x001d6fb4 LAB_001d6fb4: MOV dword ptr [RSP + 0x5c],0x0 LAB_001d6fbc: MOV RAX,qword ptr [RSP + 0x28] MOV ECX,dword ptr [RSP + 0x5c] MOV dword ptr [RSP + 0x10],ECX MOV RDI,qword ptr [RAX + 0x30] CALL 0x001bf480 MOV dword ptr [RSP + 0x14],EAX JMP 0x001d6fd8 LAB_001d6fd8: MOV EAX,dword ptr [RSP + 0x10] MOV ECX,dword ptr [RSP + 0x14] CMP EAX,ECX JGE 0x001d7080 MOV RAX,qword ptr [RSP + 0x28] MOV RDI,qword ptr [RAX + 0x30] MOV ESI,dword ptr [RSP + 0x5c] CALL 0x001bf490 MOV qword ptr [RSP + 0x8],RAX JMP 0x001d7001 LAB_001d7001: MOV RAX,qword ptr [RSP + 0x8] MOV qword ptr [RSP + 0x50],RAX MOV RDI,qword ptr [RSP + 0x50] CALL 0x00128990 MOV qword ptr [RSP],RAX JMP 0x001d701b LAB_001d701b: MOV RSI,qword ptr [RSP] LEA RDI,[RSP + 0x30] CALL 0x00153710 JMP 0x001d702b LAB_001d702b: LEA RSI,[0x4b8c5e] LEA RDI,[RSP + 0x98] LEA RDX,[RSP + 0x30] CALL 0x0015b1d0 JMP 0x001d7046 LAB_001d7046: LEA RDI,[RSP + 0x30] CALL 0x00121cc8 MOV EAX,dword ptr [RSP + 0x5c] ADD EAX,0x1 MOV dword ptr [RSP + 0x5c],EAX JMP 0x001d6fbc LAB_001d7080: LEA RSI,[0x4b8c76] LEA RDI,[RSP + 0x98] CALL 0x0015ae90 JMP 0x001d7096 LAB_001d7096: MOV RDI,qword ptr [RSP + 0x28] MOV RSI,qword ptr [RSP + 0xd8] MOV RDX,qword ptr [RSP + 0xd0] CALL 0x001d8e70 JMP 0x001d70b2 LAB_001d70b2: MOV RDI,qword ptr [RSP + 0x28] MOV RSI,qword ptr [RSP + 0xd8] CALL 0x001d57f0 JMP 0x001d70c6 LAB_001d70c6: MOV RDI,qword ptr [RSP + 0x28] MOV RSI,qword ptr [RSP + 0xd8] XOR EDX,EDX CALL 0x001d9120 LAB_001d70da: JMP 0x001d70dc LAB_001d70dc: MOV dword ptr [RSP + 0x94],0x0 LAB_001d70e7: LEA RDI,[RSP + 0x98] CALL 0x001df130 ADD RSP,0xe8 RET
/* google::protobuf::compiler::cpp::FileGenerator::GenerateProtoHeader(google::protobuf::io::Printer*, std::__cxx11::string const&) */ void __thiscall google::protobuf::compiler::cpp::FileGenerator::GenerateProtoHeader (FileGenerator *this,Printer *param_1,string *param_2) { int iVar1; byte bVar2; int iVar3; string *psVar4; cpp local_b8 [32]; FileDescriptor *local_98; int local_8c; cpp local_88 [52]; int4 local_54; Formatter local_50 [56]; string *local_18; Printer *local_10; FileGenerator *local_8; local_18 = param_2; local_10 = param_1; local_8 = this; Formatter::Formatter(local_50,param_1,(map *)(this + 0x290)); if (((byte)this[0x105] & 1) == 0) { local_54 = 1; } else { /* try { // try from 001d6ec3 to 001d6f53 has its CatchHandler @ 001d6ef2 */ GenerateTopHeaderGuard(this,local_10,false); if (((byte)this[0x10a] & 1) == 0) { Formatter::operator()<> (local_50,"#ifdef SWIG\n#error \"Do not SWIG-wrap protobufs.\"\n#endif // SWIG\n\n" ); } bVar2 = IsBootstrapProto((Options *)(this + 0x38),*(FileDescriptor **)(this + 0x30)); if ((bVar2 & 1) != 0) { psVar4 = (string *)FileDescriptor::name_abi_cxx11_(*(FileDescriptor **)(this + 0x30)); StripProto(local_88,psVar4); /* try { // try from 001d6f56 to 001d6f6e has its CatchHandler @ 001d6f7d */ Formatter::operator() (local_50,"// IWYU pragma: private, include \"$1$.proto.h\"\n\n",(string *)local_88) ; std::__cxx11::string::~string((string *)local_88); } /* try { // try from 001d6fad to 001d7028 has its CatchHandler @ 001d6ef2 */ GenerateLibraryIncludes(this,local_10); for (local_8c = 0; iVar1 = local_8c, iVar3 = FileDescriptor::public_dependency_count(*(FileDescriptor **)(this + 0x30)), iVar1 < iVar3; local_8c = local_8c + 1) { local_98 = (FileDescriptor *) FileDescriptor::public_dependency(*(FileDescriptor **)(this + 0x30),local_8c); psVar4 = (string *)FileDescriptor::name_abi_cxx11_(local_98); StripProto(local_b8,psVar4); /* try { // try from 001d702b to 001d7043 has its CatchHandler @ 001d7060 */ Formatter::operator()(local_50,"#include \"$1$.proto.h\"\n",(string *)local_b8); std::__cxx11::string::~string((string *)local_b8); } /* try { // try from 001d7080 to 001d70d9 has its CatchHandler @ 001d6ef2 */ Formatter::operator()<>(local_50,"// @@protoc_insertion_point(includes)\n"); GenerateMetadataPragma(this,local_10,local_18); GenerateHeader(this,local_10); GenerateBottomHeaderGuard(this,local_10,false); local_54 = 0; } Formatter::~Formatter(local_50); return; }
20,563
parse_device_list(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&)
llama.cpp/common/arg.cpp
static std::vector<ggml_backend_dev_t> parse_device_list(const std::string & value) { std::vector<ggml_backend_dev_t> devices; auto dev_names = string_split<std::string>(value, ','); if (dev_names.empty()) { throw std::invalid_argument("no devices specified"); } if (dev_names.size() == 1 && dev_names[0] == "none") { devices.push_back(nullptr); } else { for (const auto & device : dev_names) { auto * dev = ggml_backend_dev_by_name(device.c_str()); if (!dev || ggml_backend_dev_type(dev) != GGML_BACKEND_DEVICE_TYPE_GPU) { throw std::invalid_argument(string_format("invalid device: %s", device.c_str())); } devices.push_back(dev); } devices.push_back(nullptr); } return devices; }
O3
cpp
parse_device_list(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&): pushq %rbp pushq %r15 pushq %r14 pushq %r12 pushq %rbx subq $0x40, %rsp movq %rdi, %rbx xorps %xmm0, %xmm0 movups %xmm0, (%rdi) movq $0x0, 0x10(%rdi) leaq 0x8(%rsp), %r15 movq %r15, %rdi movl $0x2c, %edx callq 0x5bfea movq (%r15), %r14 movq 0x8(%r15), %r12 cmpq %r12, %r14 je 0x60887 movq %r12, %rax subq %r14, %rax cmpq $0x20, %rax jne 0x607a7 leaq 0xb4846(%rip), %rsi # 0x114fd3 movq %r14, %rdi callq 0x20f60 testl %eax, %eax je 0x60824 movq 0x8(%rsp), %r14 movq 0x10(%rsp), %r12 cmpq %r12, %r14 je 0x607f9 movq %rsp, %r15 movq (%r14), %rdi callq 0x20390 movq %rax, (%rsp) testq %rax, %rax je 0x6083a movq %rax, %rdi callq 0x20990 cmpl $0x1, %eax jne 0x6083a movq 0x8(%rbx), %rsi cmpq 0x10(%rbx), %rsi je 0x607e5 movq (%rsp), %rax movq %rax, (%rsi) addq $0x8, 0x8(%rbx) jmp 0x607f0 movq %rbx, %rdi movq %r15, %rdx callq 0x8d558 addq $0x20, %r14 cmpq %r12, %r14 jne 0x607af leaq 0x20(%rsp), %rsi movq $0x0, (%rsi) movq %rbx, %rdi callq 0x8d400 leaq 0x8(%rsp), %rdi callq 0x2714c addq $0x40, %rsp popq %rbx popq %r12 popq %r14 popq %r15 popq %rbp retq leaq 0x20(%rsp), %rsi movq $0x0, (%rsi) movq %rbx, %rdi callq 0x8d400 jmp 0x6080d movl $0x10, %edi callq 0x20650 movq %rax, %r15 movq (%r14), %rdx leaq 0xbb499(%rip), %rsi # 0x11bcea leaq 0x20(%rsp), %rdi xorl %eax, %eax callq 0xf63ab movb $0x1, %bpl leaq 0x20(%rsp), %rsi movq %r15, %rdi callq 0x209b0 xorl %ebp, %ebp movq 0x1026a2(%rip), %rsi # 0x162f18 movq 0x10268b(%rip), %rdx # 0x162f08 movq %r15, %rdi callq 0x20a60 jmp 0x608b9 movl $0x10, %edi callq 0x20650 movq %rax, %r15 leaq 0xbb43a(%rip), %rsi # 0x11bcd5 movq %rax, %rdi callq 0x202a0 movq 0x10266e(%rip), %rsi # 0x162f18 movq 0x102657(%rip), %rdx # 0x162f08 movq %r15, %rdi callq 0x20a60 jmp 0x608f3 jmp 0x608f3 jmp 0x608e6 jmp 0x608f3 movq %rax, %r14 leaq 0x30(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0x608df movq 0x30(%rsp), %rsi incq %rsi callq 0x20180 testb %bpl, %bpl jne 0x608e9 jmp 0x608f6 movq %rax, %r14 movq %r15, %rdi callq 0x20f00 jmp 0x608f6 movq %rax, %r14 leaq 0x8(%rsp), %rdi callq 0x2714c movq (%rbx), %rdi testq %rdi, %rdi je 0x60914 movq 0x10(%rbx), %rsi subq %rdi, %rsi callq 0x20180 movq %r14, %rdi callq 0x20b00
_ZL17parse_device_listRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE: push rbp push r15 push r14 push r12 push rbx sub rsp, 40h mov rbx, rdi xorps xmm0, xmm0 movups xmmword ptr [rdi], xmm0 mov qword ptr [rdi+10h], 0 lea r15, [rsp+68h+var_60] mov rdi, r15; int mov edx, 2Ch ; ','; int call _ZL12string_splitINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEESt6vectorIT_SaIS7_EERKS5_c; string_split<std::string>(std::string const&,char) mov r14, [r15] mov r12, [r15+8] cmp r14, r12 jz loc_60887 mov rax, r12 sub rax, r14 cmp rax, 20h ; ' ' jnz short loc_607A7 lea rsi, aNone; "none" mov rdi, r14 call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE7compareEPKc; std::string::compare(char const*) test eax, eax jz loc_60824 mov r14, qword ptr [rsp+68h+var_60] mov r12, [rsp+68h+var_58] loc_607A7: cmp r14, r12 jz short loc_607F9 mov r15, rsp loc_607AF: mov rdi, [r14] call _ggml_backend_dev_by_name mov [rsp+68h+var_68], rax test rax, rax jz short loc_6083A mov rdi, rax call _ggml_backend_dev_type cmp eax, 1 jnz short loc_6083A mov rsi, [rbx+8] cmp rsi, [rbx+10h] jz short loc_607E5 mov rax, [rsp+68h+var_68] mov [rsi], rax add qword ptr [rbx+8], 8 jmp short loc_607F0 loc_607E5: mov rdi, rbx mov rdx, r15 call _ZNSt6vectorIP19ggml_backend_deviceSaIS1_EE17_M_realloc_insertIJRKS1_EEEvN9__gnu_cxx17__normal_iteratorIPS1_S3_EEDpOT_; std::vector<ggml_backend_device *>::_M_realloc_insert<ggml_backend_device * const&>(__gnu_cxx::__normal_iterator<ggml_backend_device **,std::vector<ggml_backend_device *>>,ggml_backend_device * const&) loc_607F0: add r14, 20h ; ' ' cmp r14, r12 jnz short loc_607AF loc_607F9: lea rsi, [rsp+68h+var_48] mov qword ptr [rsi], 0 mov rdi, rbx call _ZNSt6vectorIP19ggml_backend_deviceSaIS1_EE12emplace_backIJS1_EEERS1_DpOT_; std::vector<ggml_backend_device *>::emplace_back<ggml_backend_device *>(ggml_backend_device * &&) loc_6080D: lea rdi, [rsp+68h+var_60] call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EED2Ev; std::vector<std::string>::~vector() add rsp, 40h pop rbx pop r12 pop r14 pop r15 pop rbp retn loc_60824: lea rsi, [rsp+68h+var_48] mov qword ptr [rsi], 0 mov rdi, rbx call _ZNSt6vectorIP19ggml_backend_deviceSaIS1_EE12emplace_backIJS1_EEERS1_DpOT_; std::vector<ggml_backend_device *>::emplace_back<ggml_backend_device *>(ggml_backend_device * &&) jmp short loc_6080D loc_6083A: mov edi, 10h; thrown_size call ___cxa_allocate_exception mov r15, rax mov rdx, [r14] lea rsi, aInvalidDeviceS; "invalid device: %s" lea rdi, [rsp+68h+var_48] xor eax, eax call _Z13string_formatB5cxx11PKcz; string_format(char const*,...) mov bpl, 1 lea rsi, [rsp+68h+var_48] mov rdi, r15 call __ZNSt16invalid_argumentC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; std::invalid_argument::invalid_argument(std::string const&) xor ebp, ebp mov rsi, cs:lptinfo; lptinfo mov rdx, cs:_ZNSt16invalid_argumentD1Ev_ptr; void (*)(void *) mov rdi, r15; void * call ___cxa_throw jmp short loc_608B9 loc_60887: mov edi, 10h; thrown_size call ___cxa_allocate_exception mov r15, rax lea rsi, aNoDevicesSpeci; "no devices specified" mov rdi, rax; this call __ZNSt16invalid_argumentC1EPKc; std::invalid_argument::invalid_argument(char const*) mov rsi, cs:lptinfo; lptinfo mov rdx, cs:_ZNSt16invalid_argumentD1Ev_ptr; void (*)(void *) mov rdi, r15; void * call ___cxa_throw loc_608B9: jmp short loc_608F3 jmp short loc_608F3 jmp short loc_608E6 jmp short loc_608F3 mov r14, rax lea rax, [rsp+68h+var_38] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_608DF mov rsi, [rsp+68h+var_38] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_608DF: test bpl, bpl jnz short loc_608E9 jmp short loc_608F6 loc_608E6: mov r14, rax loc_608E9: mov rdi, r15; void * call ___cxa_free_exception jmp short loc_608F6 loc_608F3: mov r14, rax loc_608F6: lea rdi, [rsp+68h+var_60] call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EED2Ev; std::vector<std::string>::~vector() mov rdi, [rbx]; void * test rdi, rdi jz short loc_60914 mov rsi, [rbx+10h] sub rsi, rdi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_60914: mov rdi, r14 call __Unwind_Resume
void parse_device_list(long long a1, long long a2) { _QWORD *v2; // r14 _QWORD *v3; // r12 long long v4; // rax long long *v5; // rsi void *v6; // r15 int v7; // ecx int v8; // r8d int v9; // r9d std::invalid_argument *exception; // r15 long long v11; // [rsp+0h] [rbp-68h] BYREF int v12[2]; // [rsp+8h] [rbp-60h] BYREF _QWORD *v13; // [rsp+10h] [rbp-58h] _QWORD v14[2]; // [rsp+20h] [rbp-48h] BYREF *(_OWORD *)a1 = 0LL; *(_QWORD *)(a1 + 16) = 0LL; string_split<std::string>((long long)v12, a2, 0x2Cu); v2 = *(_QWORD **)v12; v3 = v13; if ( *(_QWORD **)v12 == v13 ) { exception = (std::invalid_argument *)__cxa_allocate_exception(0x10uLL); std::invalid_argument::invalid_argument(exception, "no devices specified"); __cxa_throw( exception, (struct type_info *)&`typeinfo for'std::invalid_argument, (void (*)(void *))&std::invalid_argument::~invalid_argument); } if ( (_QWORD *)((char *)v13 - *(_QWORD *)v12) == &qword_20 ) { if ( !(unsigned int)std::string::compare(*(_QWORD *)v12, "none") ) { v14[0] = 0LL; std::vector<ggml_backend_device *>::emplace_back<ggml_backend_device *>(a1, v14); goto LABEL_13; } v2 = *(_QWORD **)v12; v3 = v13; } for ( ; v2 != v3; v2 += 4 ) { v4 = ggml_backend_dev_by_name(*v2); v11 = v4; if ( !v4 || (unsigned int)ggml_backend_dev_type(v4) != 1 ) { v6 = __cxa_allocate_exception(0x10uLL); string_format[abi:cxx11]((unsigned int)v14, (unsigned int)"invalid device: %s", *v2, v7, v8, v9); std::invalid_argument::invalid_argument(v6, v14); __cxa_throw( v6, (struct type_info *)&`typeinfo for'std::invalid_argument, (void (*)(void *))&std::invalid_argument::~invalid_argument); } v5 = *(long long **)(a1 + 8); if ( v5 == *(long long **)(a1 + 16) ) { std::vector<ggml_backend_device *>::_M_realloc_insert<ggml_backend_device * const&>(a1, v5, &v11); } else { *v5 = v11; *(_QWORD *)(a1 + 8) += 8LL; } } v14[0] = 0LL; std::vector<ggml_backend_device *>::emplace_back<ggml_backend_device *>(a1, v14); LABEL_13: std::vector<std::string>::~vector((long long)v12); }
parse_device_list: PUSH RBP PUSH R15 PUSH R14 PUSH R12 PUSH RBX SUB RSP,0x40 MOV RBX,RDI XORPS XMM0,XMM0 MOVUPS xmmword ptr [RDI],XMM0 MOV qword ptr [RDI + 0x10],0x0 LEA R15,[RSP + 0x8] MOV RDI,R15 MOV EDX,0x2c CALL 0x0015bfea MOV R14,qword ptr [R15] MOV R12,qword ptr [R15 + 0x8] CMP R14,R12 JZ 0x00160887 MOV RAX,R12 SUB RAX,R14 CMP RAX,0x20 JNZ 0x001607a7 LEA RSI,[0x214fd3] MOV RDI,R14 CALL 0x00120f60 TEST EAX,EAX JZ 0x00160824 MOV R14,qword ptr [RSP + 0x8] MOV R12,qword ptr [RSP + 0x10] LAB_001607a7: CMP R14,R12 JZ 0x001607f9 MOV R15,RSP LAB_001607af: MOV RDI,qword ptr [R14] LAB_001607b2: CALL 0x00120390 MOV qword ptr [RSP],RAX TEST RAX,RAX JZ 0x0016083a MOV RDI,RAX CALL 0x00120990 CMP EAX,0x1 JNZ 0x0016083a MOV RSI,qword ptr [RBX + 0x8] CMP RSI,qword ptr [RBX + 0x10] JZ 0x001607e5 MOV RAX,qword ptr [RSP] MOV qword ptr [RSI],RAX ADD qword ptr [RBX + 0x8],0x8 JMP 0x001607f0 LAB_001607e5: MOV RDI,RBX MOV RDX,R15 CALL 0x0018d558 LAB_001607f0: ADD R14,0x20 CMP R14,R12 JNZ 0x001607af LAB_001607f9: LEA RSI,[RSP + 0x20] MOV qword ptr [RSI],0x0 LAB_00160805: MOV RDI,RBX CALL 0x0018d400 LAB_0016080d: LEA RDI,[RSP + 0x8] CALL 0x0012714c ADD RSP,0x40 POP RBX POP R12 POP R14 POP R15 POP RBP RET LAB_00160824: LEA RSI,[RSP + 0x20] MOV qword ptr [RSI],0x0 LAB_00160830: MOV RDI,RBX CALL 0x0018d400 LAB_00160838: JMP 0x0016080d LAB_0016083a: MOV EDI,0x10 CALL 0x00120650 MOV R15,RAX MOV RDX,qword ptr [R14] LAB_0016084a: LEA RSI,[0x21bcea] LEA RDI,[RSP + 0x20] XOR EAX,EAX CALL 0x001f63ab MOV BPL,0x1 LAB_00160860: LEA RSI,[RSP + 0x20] MOV RDI,R15 CALL 0x001209b0 XOR EBP,EBP MOV RSI,qword ptr [0x00262f18] MOV RDX,qword ptr [0x00262f08] MOV RDI,R15 CALL 0x00120a60 LAB_00160887: MOV EDI,0x10 CALL 0x00120650 MOV R15,RAX LAB_00160894: LEA RSI,[0x21bcd5] MOV RDI,RAX CALL 0x001202a0 LAB_001608a3: MOV RSI,qword ptr [0x00262f18] MOV RDX,qword ptr [0x00262f08] MOV RDI,R15 CALL 0x00120a60
/* parse_device_list(std::__cxx11::string const&) */ void parse_device_list(string *param_1) { long *plVar1; char *pcVar2; int iVar3; invalid_argument *piVar4; char in_SIL; char *pcVar5; long local_68; char *local_60; char *local_58; ggml_backend_device *local_48 [4]; *(int8 *)param_1 = 0; *(int8 *)(param_1 + 8) = 0; *(int8 *)(param_1 + 0x10) = 0; string_split<std::__cxx11::string>((string *)&local_60,in_SIL); if (local_60 == local_58) { piVar4 = (invalid_argument *)__cxa_allocate_exception(0x10); /* try { // try from 00160894 to 001608a2 has its CatchHandler @ 001608bd */ std::invalid_argument::invalid_argument(piVar4,"no devices specified"); /* try { // try from 001608a3 to 001608b8 has its CatchHandler @ 001608bb */ /* WARNING: Subroutine does not return */ __cxa_throw(piVar4,PTR_typeinfo_00262f18,PTR__invalid_argument_00262f08); } pcVar2 = local_60; pcVar5 = local_58; if (((long)local_58 - (long)local_60 == 0x20) && (iVar3 = std::__cxx11::string::compare(local_60), pcVar2 = local_60, pcVar5 = local_58, iVar3 == 0)) { local_48[0] = (ggml_backend_device *)0x0; /* try { // try from 00160830 to 00160837 has its CatchHandler @ 001608b9 */ std::vector<ggml_backend_device*,std::allocator<ggml_backend_device*>>:: emplace_back<ggml_backend_device*> ((vector<ggml_backend_device*,std::allocator<ggml_backend_device*>> *)param_1,local_48 ); } else { for (; pcVar2 != pcVar5; pcVar2 = pcVar2 + 0x20) { /* try { // try from 001607b2 to 001607ef has its CatchHandler @ 001608f3 */ local_68 = ggml_backend_dev_by_name(*(int8 *)pcVar2); if ((local_68 == 0) || (iVar3 = ggml_backend_dev_type(local_68), iVar3 != 1)) { piVar4 = (invalid_argument *)__cxa_allocate_exception(0x10); /* try { // try from 0016084a to 0016085c has its CatchHandler @ 001608e6 */ string_format_abi_cxx11_((char *)local_48,"invalid device: %s",*(int8 *)pcVar2); /* try { // try from 00160860 to 00160884 has its CatchHandler @ 001608c1 */ std::invalid_argument::invalid_argument(piVar4,(string *)local_48); /* WARNING: Subroutine does not return */ __cxa_throw(piVar4,PTR_typeinfo_00262f18,PTR__invalid_argument_00262f08); } plVar1 = *(long **)(param_1 + 8); if (plVar1 == *(long **)(param_1 + 0x10)) { std::vector<ggml_backend_device*,std::allocator<ggml_backend_device*>>:: _M_realloc_insert<ggml_backend_device*const&> ((vector<ggml_backend_device*,std::allocator<ggml_backend_device*>> *)param_1, plVar1,&local_68); } else { *plVar1 = local_68; *(long *)(param_1 + 8) = *(long *)(param_1 + 8) + 8; } } local_48[0] = (ggml_backend_device *)0x0; /* try { // try from 00160805 to 0016080c has its CatchHandler @ 001608bf */ std::vector<ggml_backend_device*,std::allocator<ggml_backend_device*>>:: emplace_back<ggml_backend_device*> ((vector<ggml_backend_device*,std::allocator<ggml_backend_device*>> *)param_1,local_48 ); } std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::~vector ((vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *)&local_60); return; }
20,564
get_simple_key_cache_statistics
eloqsql/mysys/mf_keycache.c
static void get_simple_key_cache_statistics(SIMPLE_KEY_CACHE_CB *keycache, uint partition_no __attribute__((unused)), KEY_CACHE_STATISTICS *keycache_stats) { DBUG_ENTER("simple_get_key_cache_statistics"); keycache_stats->mem_size= (longlong) keycache->key_cache_mem_size; keycache_stats->block_size= (longlong) keycache->key_cache_block_size; keycache_stats->blocks_used= keycache->blocks_used; keycache_stats->blocks_unused= keycache->blocks_unused; keycache_stats->blocks_changed= keycache->global_blocks_changed; keycache_stats->blocks_warm= keycache->warm_blocks; keycache_stats->read_requests= keycache->global_cache_r_requests; keycache_stats->reads= keycache->global_cache_read; keycache_stats->write_requests= keycache->global_cache_w_requests; keycache_stats->writes= keycache->global_cache_write; DBUG_VOID_RETURN; }
O0
c
get_simple_key_cache_statistics: pushq %rbp movq %rsp, %rbp movq %rdi, -0x8(%rbp) movl %esi, -0xc(%rbp) movq %rdx, -0x18(%rbp) movq -0x8(%rbp), %rax movq 0x8(%rax), %rcx movq -0x18(%rbp), %rax movq %rcx, (%rax) movq -0x8(%rbp), %rax movl 0x18(%rax), %eax movl %eax, %ecx movq -0x18(%rbp), %rax movq %rcx, 0x8(%rax) movq -0x8(%rbp), %rax movq 0x50(%rax), %rcx movq -0x18(%rbp), %rax movq %rcx, 0x10(%rax) movq -0x8(%rbp), %rax movq 0x58(%rax), %rcx movq -0x18(%rbp), %rax movq %rcx, 0x18(%rax) movq -0x8(%rbp), %rax movq 0x138(%rax), %rcx movq -0x18(%rbp), %rax movq %rcx, 0x20(%rax) movq -0x8(%rbp), %rax movq 0x68(%rax), %rcx movq -0x18(%rbp), %rax movq %rcx, 0x28(%rax) movq -0x8(%rbp), %rax movq 0x150(%rax), %rcx movq -0x18(%rbp), %rax movq %rcx, 0x30(%rax) movq -0x8(%rbp), %rax movq 0x158(%rax), %rcx movq -0x18(%rbp), %rax movq %rcx, 0x38(%rax) movq -0x8(%rbp), %rax movq 0x140(%rax), %rcx movq -0x18(%rbp), %rax movq %rcx, 0x40(%rax) movq -0x8(%rbp), %rax movq 0x148(%rax), %rcx movq -0x18(%rbp), %rax movq %rcx, 0x48(%rax) jmp 0xe8600 popq %rbp retq nopw %cs:(%rax,%rax)
get_simple_key_cache_statistics: push rbp mov rbp, rsp mov [rbp+var_8], rdi mov [rbp+var_C], esi mov [rbp+var_18], rdx mov rax, [rbp+var_8] mov rcx, [rax+8] mov rax, [rbp+var_18] mov [rax], rcx mov rax, [rbp+var_8] mov eax, [rax+18h] mov ecx, eax mov rax, [rbp+var_18] mov [rax+8], rcx mov rax, [rbp+var_8] mov rcx, [rax+50h] mov rax, [rbp+var_18] mov [rax+10h], rcx mov rax, [rbp+var_8] mov rcx, [rax+58h] mov rax, [rbp+var_18] mov [rax+18h], rcx mov rax, [rbp+var_8] mov rcx, [rax+138h] mov rax, [rbp+var_18] mov [rax+20h], rcx mov rax, [rbp+var_8] mov rcx, [rax+68h] mov rax, [rbp+var_18] mov [rax+28h], rcx mov rax, [rbp+var_8] mov rcx, [rax+150h] mov rax, [rbp+var_18] mov [rax+30h], rcx mov rax, [rbp+var_8] mov rcx, [rax+158h] mov rax, [rbp+var_18] mov [rax+38h], rcx mov rax, [rbp+var_8] mov rcx, [rax+140h] mov rax, [rbp+var_18] mov [rax+40h], rcx mov rax, [rbp+var_8] mov rcx, [rax+148h] mov rax, [rbp+var_18] mov [rax+48h], rcx jmp short $+2 loc_E8600: pop rbp retn
_QWORD * get_simple_key_cache_statistics(long long a1, long long a2, _QWORD *a3) { _QWORD *result; // rax *a3 = *(_QWORD *)(a1 + 8); a3[1] = *(unsigned int *)(a1 + 24); a3[2] = *(_QWORD *)(a1 + 80); a3[3] = *(_QWORD *)(a1 + 88); a3[4] = *(_QWORD *)(a1 + 312); a3[5] = *(_QWORD *)(a1 + 104); a3[6] = *(_QWORD *)(a1 + 336); a3[7] = *(_QWORD *)(a1 + 344); a3[8] = *(_QWORD *)(a1 + 320); result = a3; a3[9] = *(_QWORD *)(a1 + 328); return result; }
get_simple_key_cache_statistics: PUSH RBP MOV RBP,RSP MOV qword ptr [RBP + -0x8],RDI MOV dword ptr [RBP + -0xc],ESI MOV qword ptr [RBP + -0x18],RDX MOV RAX,qword ptr [RBP + -0x8] MOV RCX,qword ptr [RAX + 0x8] MOV RAX,qword ptr [RBP + -0x18] MOV qword ptr [RAX],RCX MOV RAX,qword ptr [RBP + -0x8] MOV EAX,dword ptr [RAX + 0x18] MOV ECX,EAX MOV RAX,qword ptr [RBP + -0x18] MOV qword ptr [RAX + 0x8],RCX MOV RAX,qword ptr [RBP + -0x8] MOV RCX,qword ptr [RAX + 0x50] MOV RAX,qword ptr [RBP + -0x18] MOV qword ptr [RAX + 0x10],RCX MOV RAX,qword ptr [RBP + -0x8] MOV RCX,qword ptr [RAX + 0x58] MOV RAX,qword ptr [RBP + -0x18] MOV qword ptr [RAX + 0x18],RCX MOV RAX,qword ptr [RBP + -0x8] MOV RCX,qword ptr [RAX + 0x138] MOV RAX,qword ptr [RBP + -0x18] MOV qword ptr [RAX + 0x20],RCX MOV RAX,qword ptr [RBP + -0x8] MOV RCX,qword ptr [RAX + 0x68] MOV RAX,qword ptr [RBP + -0x18] MOV qword ptr [RAX + 0x28],RCX MOV RAX,qword ptr [RBP + -0x8] MOV RCX,qword ptr [RAX + 0x150] MOV RAX,qword ptr [RBP + -0x18] MOV qword ptr [RAX + 0x30],RCX MOV RAX,qword ptr [RBP + -0x8] MOV RCX,qword ptr [RAX + 0x158] MOV RAX,qword ptr [RBP + -0x18] MOV qword ptr [RAX + 0x38],RCX MOV RAX,qword ptr [RBP + -0x8] MOV RCX,qword ptr [RAX + 0x140] MOV RAX,qword ptr [RBP + -0x18] MOV qword ptr [RAX + 0x40],RCX MOV RAX,qword ptr [RBP + -0x8] MOV RCX,qword ptr [RAX + 0x148] MOV RAX,qword ptr [RBP + -0x18] MOV qword ptr [RAX + 0x48],RCX JMP 0x001e8600 LAB_001e8600: POP RBP RET
void get_simple_key_cache_statistics(long param_1,int8 param_2,int8 *param_3) { *param_3 = *(int8 *)(param_1 + 8); param_3[1] = (ulong)*(uint *)(param_1 + 0x18); param_3[2] = *(int8 *)(param_1 + 0x50); param_3[3] = *(int8 *)(param_1 + 0x58); param_3[4] = *(int8 *)(param_1 + 0x138); param_3[5] = *(int8 *)(param_1 + 0x68); param_3[6] = *(int8 *)(param_1 + 0x150); param_3[7] = *(int8 *)(param_1 + 0x158); param_3[8] = *(int8 *)(param_1 + 0x140); param_3[9] = *(int8 *)(param_1 + 0x148); return; }
20,565
intx::internal::udivrem_by2(unsigned long*, int, intx::uint<128u>)
corpus-core[P]colibri-stateless/build_O0/_deps/intx-src/include/intx/intx.hpp
inline uint128 udivrem_by2(uint64_t u[], int len, uint128 d) noexcept { INTX_REQUIRE(len >= 3); const auto reciprocal = reciprocal_3by2(d); auto rem = uint128{u[len - 2], u[len - 1]}; // Set the 2 top words as remainder. u[len - 1] = u[len - 2] = 0; // Reset these words being a part of the result quotient. auto it = &u[len - 3]; do { std::tie(*it, rem) = udivrem_3by2(rem[1], rem[0], *it, d, reciprocal); } while (it-- != &u[0]); return rem; }
O0
cpp
intx::internal::udivrem_by2(unsigned long*, int, intx::uint<128u>): pushq %rbp movq %rsp, %rbp subq $0xb0, %rsp movq %rdx, -0x20(%rbp) movq %rcx, -0x18(%rbp) movq %rdi, -0x28(%rbp) movl %esi, -0x2c(%rbp) cmpl $0x3, -0x2c(%rbp) jl 0x626d2 jmp 0x626f1 leaq 0x7d140(%rip), %rdi # 0xdf819 leaq 0x7cfc8(%rip), %rsi # 0xdf6a8 movl $0x65c, %edx # imm = 0x65C leaq 0x7d0ee(%rip), %rcx # 0xdf7da callq 0x23120 movq -0x20(%rbp), %rax movq %rax, -0x48(%rbp) movq -0x18(%rbp), %rax movq %rax, -0x40(%rbp) movq -0x48(%rbp), %rdi movq -0x40(%rbp), %rsi callq 0x636f0 movq %rax, -0x38(%rbp) movq -0x28(%rbp), %rax movl -0x2c(%rbp), %ecx subl $0x2, %ecx movslq %ecx, %rcx movq (%rax,%rcx,8), %rsi movq -0x28(%rbp), %rax movl -0x2c(%rbp), %ecx subl $0x1, %ecx movslq %ecx, %rcx movq (%rax,%rcx,8), %rdx leaq -0x10(%rbp), %rdi callq 0x61770 movq -0x28(%rbp), %rax movl -0x2c(%rbp), %ecx subl $0x2, %ecx movslq %ecx, %rcx movq $0x0, (%rax,%rcx,8) movq -0x28(%rbp), %rax movl -0x2c(%rbp), %ecx subl $0x1, %ecx movslq %ecx, %rcx movq $0x0, (%rax,%rcx,8) movq -0x28(%rbp), %rax movl -0x2c(%rbp), %ecx subl $0x3, %ecx movslq %ecx, %rcx shlq $0x3, %rcx addq %rcx, %rax movq %rax, -0x50(%rbp) leaq -0x10(%rbp), %rdi movl $0x1, %esi callq 0x617a0 movq (%rax), %rax movq %rax, -0xa0(%rbp) leaq -0x10(%rbp), %rdi xorl %eax, %eax movl %eax, %esi callq 0x617a0 movq -0xa0(%rbp), %rsi movq (%rax), %rdx movq -0x50(%rbp), %rax movq (%rax), %rcx movq -0x20(%rbp), %rax movq %rax, -0x88(%rbp) movq -0x18(%rbp), %rax movq %rax, -0x80(%rbp) movq -0x38(%rbp), %rax movq -0x88(%rbp), %r8 movq -0x80(%rbp), %r9 leaq -0x78(%rbp), %rdi movq %rax, (%rsp) callq 0x638e0 leaq -0x60(%rbp), %rdi leaq -0x78(%rbp), %rsi callq 0x63c20 movq -0x50(%rbp), %rsi leaq -0x98(%rbp), %rdi leaq -0x10(%rbp), %rdx callq 0x63c60 leaq -0x98(%rbp), %rdi leaq -0x60(%rbp), %rsi callq 0x63ca0 movq -0x50(%rbp), %rax movq %rax, %rcx addq $-0x8, %rcx movq %rcx, -0x50(%rbp) movq -0x28(%rbp), %rcx cmpq %rcx, %rax jne 0x6277f movq -0x10(%rbp), %rax movq -0x8(%rbp), %rdx addq $0xb0, %rsp popq %rbp retq nopw %cs:(%rax,%rax) nopl (%rax)
_ZN4intx8internal11udivrem_by2EPmiNS_4uintILj128EEE: push rbp mov rbp, rsp sub rsp, 0B0h mov [rbp+var_20], rdx mov [rbp+var_18], rcx mov [rbp+var_28], rdi mov [rbp+var_2C], esi cmp [rbp+var_2C], 3 jl short loc_626D2 jmp short loc_626F1 loc_626D2: lea rdi, aDlen3+1; "len >= 3" lea rsi, aWorkspaceLlm4b_3; "/workspace/llm4binary/github/2025_star3"... mov edx, 65Ch lea rcx, aUint128IntxInt; "uint128 intx::internal::udivrem_by2(uin"... call ___assert_fail loc_626F1: mov rax, [rbp+var_20] mov [rbp+var_48], rax mov rax, [rbp+var_18] mov [rbp+var_40], rax mov rdi, [rbp+var_48] mov rsi, [rbp+var_40] call _ZN4intx15reciprocal_3by2ENS_4uintILj128EEE; intx::reciprocal_3by2(intx::uint<128u>) mov [rbp+var_38], rax mov rax, [rbp+var_28] mov ecx, [rbp+var_2C] sub ecx, 2 movsxd rcx, ecx mov rsi, [rax+rcx*8] mov rax, [rbp+var_28] mov ecx, [rbp+var_2C] sub ecx, 1 movsxd rcx, ecx mov rdx, [rax+rcx*8] lea rdi, [rbp+var_10] call _ZN4intx4uintILj128EEC2Emm; intx::uint<128u>::uint(ulong,ulong) mov rax, [rbp+var_28] mov ecx, [rbp+var_2C] sub ecx, 2 movsxd rcx, ecx mov qword ptr [rax+rcx*8], 0 mov rax, [rbp+var_28] mov ecx, [rbp+var_2C] sub ecx, 1 movsxd rcx, ecx mov qword ptr [rax+rcx*8], 0 mov rax, [rbp+var_28] mov ecx, [rbp+var_2C] sub ecx, 3 movsxd rcx, ecx shl rcx, 3 add rax, rcx mov [rbp+var_50], rax loc_6277F: lea rdi, [rbp+var_10] mov esi, 1 call _ZN4intx4uintILj128EEixEm; intx::uint<128u>::operator[](ulong) mov rax, [rax] mov qword ptr [rbp+var_A0], rax lea rdi, [rbp+var_10] xor eax, eax mov esi, eax call _ZN4intx4uintILj128EEixEm; intx::uint<128u>::operator[](ulong) mov rsi, qword ptr [rbp+var_A0]; int mov rdx, [rax]; int mov rax, [rbp+var_50] mov rcx, [rax]; int mov rax, [rbp+var_20] mov qword ptr [rbp+var_88], rax mov rax, [rbp+var_18] mov qword ptr [rbp+var_80], rax mov rax, [rbp+var_38] mov r8, qword ptr [rbp+var_88]; int mov r9, qword ptr [rbp+var_80]; int lea rdi, [rbp+var_78]; int mov [rsp+0B0h+var_B0], rax; intx * call _ZN4intx12udivrem_3by2EmmmNS_4uintILj128EEEm; intx::udivrem_3by2(ulong,ulong,ulong,intx::uint<128u>,ulong) lea rdi, [rbp+var_60] lea rsi, [rbp+var_78] call _ZN4intx10div_resultImNS_4uintILj128EEEEcvSt5tupleIJRmRS2_EEEv; intx::div_result<ulong,intx::uint<128u>>::operator std::tuple<ulong &,intx::uint<128u>&>(void) mov rsi, [rbp+var_50] lea rdi, [rbp+var_98] lea rdx, [rbp+var_10] call _ZSt3tieIJmN4intx4uintILj128EEEEESt5tupleIJDpRT_EES6_; std::tie<ulong,intx::uint<128u>>(ulong,intx::uint<128u> &) lea rdi, [rbp+var_98] lea rsi, [rbp+var_60] call _ZNSt5tupleIJRmRN4intx4uintILj128EEEEEaSEOS5_; std::tuple<ulong &,intx::uint<128u> &>::operator=(std::tuple<ulong &,intx::uint<128u> &>&&) mov rax, [rbp+var_50] mov rcx, rax add rcx, 0FFFFFFFFFFFFFFF8h mov [rbp+var_50], rcx mov rcx, [rbp+var_28] cmp rax, rcx jnz loc_6277F mov rax, [rbp+var_10] mov rdx, [rbp+var_8] add rsp, 0B0h pop rbp retn
long long intx::internal::udivrem_by2(long long *a1, int a2, long long a3, long long a4) { long long v4; // rdx long long v5; // rcx long long *v6; // rax int v8[2]; // [rsp+10h] [rbp-A0h] _BYTE v9[16]; // [rsp+18h] [rbp-98h] BYREF int v10[2]; // [rsp+28h] [rbp-88h] int v11[2]; // [rsp+30h] [rbp-80h] int v12[6]; // [rsp+38h] [rbp-78h] BYREF _BYTE v13[16]; // [rsp+50h] [rbp-60h] BYREF long long *v14; // [rsp+60h] [rbp-50h] long long v15; // [rsp+68h] [rbp-48h] long long v16; // [rsp+70h] [rbp-40h] intx *v17; // [rsp+78h] [rbp-38h] int v18; // [rsp+84h] [rbp-2Ch] long long *v19; // [rsp+88h] [rbp-28h] long long v20; // [rsp+90h] [rbp-20h] long long v21; // [rsp+98h] [rbp-18h] long long v22; // [rsp+A0h] [rbp-10h] BYREF v20 = a3; v21 = a4; v19 = a1; v18 = a2; if ( a2 < 3 ) __assert_fail( "len >= 3", "/workspace/llm4binary/github/2025_star3/corpus-core[P]colibri-stateless/build_O0/_deps/intx-src/include/intx/intx.hpp", 1628LL, "uint128 intx::internal::udivrem_by2(uint64_t *, int, uint128)"); v15 = v20; v16 = v21; v17 = (intx *)intx::reciprocal_3by2(v20, v21); intx::uint<128u>::uint(&v22, v19[v18 - 2], v19[v18 - 1]); v19[v18 - 2] = 0LL; v19[v18 - 1] = 0LL; v14 = &v19[v18 - 3]; do { *(_QWORD *)v8 = *(_QWORD *)intx::uint<128u>::operator[]((long long)&v22, 1LL); v4 = *(_QWORD *)intx::uint<128u>::operator[]((long long)&v22, 0LL); v5 = *v14; *(_QWORD *)v10 = v20; *(_QWORD *)v11 = v21; intx::udivrem_3by2((int)v12, v8[0], v4, v5, v20, v21, v17); intx::div_result<unsigned long,intx::uint<128u>>::operator std::tuple<unsigned long &,intx::uint<128u>&>(v13, v12); std::tie<unsigned long,intx::uint<128u>>(v9, v14, &v22); std::tuple<unsigned long &,intx::uint<128u> &>::operator=(v9, v13); v6 = v14--; } while ( v6 != v19 ); return v22; }
udivrem_by2: PUSH RBP MOV RBP,RSP SUB RSP,0xb0 MOV qword ptr [RBP + -0x20],RDX MOV qword ptr [RBP + -0x18],RCX MOV qword ptr [RBP + -0x28],RDI MOV dword ptr [RBP + -0x2c],ESI CMP dword ptr [RBP + -0x2c],0x3 JL 0x001626d2 JMP 0x001626f1 LAB_001626d2: LEA RDI,[0x1df819] LEA RSI,[0x1df6a8] MOV EDX,0x65c LEA RCX,[0x1df7da] CALL 0x00123120 LAB_001626f1: MOV RAX,qword ptr [RBP + -0x20] MOV qword ptr [RBP + -0x48],RAX MOV RAX,qword ptr [RBP + -0x18] MOV qword ptr [RBP + -0x40],RAX MOV RDI,qword ptr [RBP + -0x48] MOV RSI,qword ptr [RBP + -0x40] CALL 0x001636f0 MOV qword ptr [RBP + -0x38],RAX MOV RAX,qword ptr [RBP + -0x28] MOV ECX,dword ptr [RBP + -0x2c] SUB ECX,0x2 MOVSXD RCX,ECX MOV RSI,qword ptr [RAX + RCX*0x8] MOV RAX,qword ptr [RBP + -0x28] MOV ECX,dword ptr [RBP + -0x2c] SUB ECX,0x1 MOVSXD RCX,ECX MOV RDX,qword ptr [RAX + RCX*0x8] LEA RDI,[RBP + -0x10] CALL 0x00161770 MOV RAX,qword ptr [RBP + -0x28] MOV ECX,dword ptr [RBP + -0x2c] SUB ECX,0x2 MOVSXD RCX,ECX MOV qword ptr [RAX + RCX*0x8],0x0 MOV RAX,qword ptr [RBP + -0x28] MOV ECX,dword ptr [RBP + -0x2c] SUB ECX,0x1 MOVSXD RCX,ECX MOV qword ptr [RAX + RCX*0x8],0x0 MOV RAX,qword ptr [RBP + -0x28] MOV ECX,dword ptr [RBP + -0x2c] SUB ECX,0x3 MOVSXD RCX,ECX SHL RCX,0x3 ADD RAX,RCX MOV qword ptr [RBP + -0x50],RAX LAB_0016277f: LEA RDI,[RBP + -0x10] MOV ESI,0x1 CALL 0x001617a0 MOV RAX,qword ptr [RAX] MOV qword ptr [RBP + -0xa0],RAX LEA RDI,[RBP + -0x10] XOR EAX,EAX MOV ESI,EAX CALL 0x001617a0 MOV RSI,qword ptr [RBP + -0xa0] MOV RDX,qword ptr [RAX] MOV RAX,qword ptr [RBP + -0x50] MOV RCX,qword ptr [RAX] MOV RAX,qword ptr [RBP + -0x20] MOV qword ptr [RBP + -0x88],RAX MOV RAX,qword ptr [RBP + -0x18] MOV qword ptr [RBP + -0x80],RAX MOV RAX,qword ptr [RBP + -0x38] MOV R8,qword ptr [RBP + -0x88] MOV R9,qword ptr [RBP + -0x80] LEA RDI,[RBP + -0x78] MOV qword ptr [RSP],RAX CALL 0x001638e0 LEA RDI,[RBP + -0x60] LEA RSI,[RBP + -0x78] CALL 0x00163c20 MOV RSI,qword ptr [RBP + -0x50] LEA RDI,[RBP + -0x98] LEA RDX,[RBP + -0x10] CALL 0x00163c60 LEA RDI,[RBP + -0x98] LEA RSI,[RBP + -0x60] CALL 0x00163ca0 MOV RAX,qword ptr [RBP + -0x50] MOV RCX,RAX ADD RCX,-0x8 MOV qword ptr [RBP + -0x50],RCX MOV RCX,qword ptr [RBP + -0x28] CMP RAX,RCX JNZ 0x0016277f MOV RAX,qword ptr [RBP + -0x10] MOV RDX,qword ptr [RBP + -0x8] ADD RSP,0xb0 POP RBP RET
/* intx::internal::udivrem_by2(unsigned long*, int, intx::uint<128u>) */ int1 [16] __thiscall intx::internal::udivrem_by2(internal *this,int param_2,intx *param_3,int8 param_4) { int8 uVar1; int8 *puVar2; bool bVar3; int1 auVar4 [16]; tuple<unsigned_long&,intx::uint<128u>&> local_a0 [16]; intx *local_90; int8 local_88; int1 local_80 [24]; div_result local_68 [16]; internal *local_58; intx *local_50; int8 local_48; int8 local_40; int local_34; internal *local_30; intx *local_28; int8 local_20; uint<128u> local_18 [16]; int1 auVar5 [15]; int8 uVar6; local_34 = param_2; local_30 = this; local_28 = param_3; local_20 = param_4; if (2 < param_2) { local_50 = param_3; local_48 = param_4; local_40 = reciprocal_3by2(param_3,param_4); uint<128u>::uint(local_18,*(ulong *)(local_30 + (long)(local_34 + -2) * 8), *(ulong *)(local_30 + (long)(local_34 + -1) * 8)); *(int8 *)(local_30 + (long)(local_34 + -2) * 8) = 0; *(int8 *)(local_30 + (long)(local_34 + -1) * 8) = 0; local_58 = local_30 + (long)(local_34 + -3) * 8; do { puVar2 = (int8 *)uint<128u>::operator[](local_18,1); uVar1 = *puVar2; puVar2 = (int8 *)uint<128u>::operator[](local_18,0); local_90 = local_28; local_88 = local_20; udivrem_3by2(local_80,uVar1,*puVar2,*(int8 *)local_58,local_28,local_20,local_40); div_result::operator_cast_to_tuple(local_68); std::tie<unsigned_long,intx::uint<128u>>((ulong *)local_a0,(uint *)local_58); std::tuple<unsigned_long&,intx::uint<128u>&>::operator=(local_a0,(tuple *)local_68); bVar3 = local_58 != local_30; local_58 = local_58 + -8; } while (bVar3); auVar4[0] = local_18[0]; auVar5[1] = local_18[1]; auVar5[2] = local_18[2]; auVar5[3] = local_18[3]; auVar5[4] = local_18[4]; auVar5[5] = local_18[5]; auVar5[6] = local_18[6]; auVar5[7] = local_18[7]; register0x00000010 = local_18[8]; register0x00000011 = local_18[9]; register0x00000012 = local_18[10]; register0x00000013 = local_18[0xb]; register0x00000014 = local_18[0xc]; register0x00000015 = local_18[0xd]; register0x00000016 = local_18[0xe]; register0x00000017 = local_18[0xf]; return auVar4; } /* WARNING: Subroutine does not return */ __assert_fail("len >= 3", "/workspace/llm4binary/github/2025_star3/corpus-core[P]colibri-stateless/build_O0/_deps/intx-src/include/intx/intx.hpp" ,0x65c,"uint128 intx::internal::udivrem_by2(uint64_t *, int, uint128)"); }
20,566
close_var_refs
bluesky950520[P]quickjs/quickjs.c
static void close_var_refs(JSRuntime *rt, JSStackFrame *sf) { struct list_head *el, *el1; JSVarRef *var_ref; int var_idx; list_for_each_safe(el, el1, &sf->var_ref_list) { var_ref = list_entry(el, JSVarRef, header.link); var_idx = var_ref->var_idx; if (var_ref->is_arg) var_ref->value = js_dup(sf->arg_buf[var_idx]); else var_ref->value = js_dup(sf->var_buf[var_idx]); var_ref->pvalue = &var_ref->value; /* the reference is no longer to a local variable */ var_ref->is_detached = TRUE; add_gc_object(rt, &var_ref->header, JS_GC_OBJ_TYPE_VAR_REF); } }
O0
c
close_var_refs: subq $0x68, %rsp movq %rdi, 0x60(%rsp) movq %rsi, 0x58(%rsp) movq 0x58(%rsp), %rax movq 0x30(%rax), %rax movq %rax, 0x50(%rsp) movq 0x50(%rsp), %rax movq 0x8(%rax), %rax movq %rax, 0x48(%rsp) movq 0x50(%rsp), %rax movq 0x58(%rsp), %rcx addq $0x28, %rcx cmpq %rcx, %rax je 0x62720 movq 0x50(%rsp), %rax addq $-0x8, %rax movq %rax, 0x40(%rsp) movq 0x40(%rsp), %rax movzwl 0x6(%rax), %eax movl %eax, 0x3c(%rsp) movq 0x40(%rsp), %rax movb 0x5(%rax), %al shrb %al andb $0x1, %al cmpb $0x0, %al je 0x6267d movq 0x40(%rsp), %rax movq %rax, 0x10(%rsp) movq 0x58(%rsp), %rax movq 0x18(%rax), %rax movslq 0x3c(%rsp), %rcx shlq $0x4, %rcx addq %rcx, %rax movq (%rax), %rdi movq 0x8(%rax), %rsi callq 0x279c0 movq %rax, %rcx movq 0x10(%rsp), %rax movq %rcx, 0x28(%rsp) movq %rdx, 0x30(%rsp) movq 0x28(%rsp), %rcx movq %rcx, 0x20(%rax) movq 0x30(%rsp), %rcx movq %rcx, 0x28(%rax) jmp 0x626cc movq 0x40(%rsp), %rax movq %rax, 0x8(%rsp) movq 0x58(%rsp), %rax movq 0x20(%rax), %rax movslq 0x3c(%rsp), %rcx shlq $0x4, %rcx addq %rcx, %rax movq (%rax), %rdi movq 0x8(%rax), %rsi callq 0x279c0 movq %rax, %rcx movq 0x8(%rsp), %rax movq %rcx, 0x18(%rsp) movq %rdx, 0x20(%rsp) movq 0x18(%rsp), %rcx movq %rcx, 0x20(%rax) movq 0x20(%rsp), %rcx movq %rcx, 0x28(%rax) movq 0x40(%rsp), %rcx addq $0x20, %rcx movq 0x40(%rsp), %rax movq %rcx, 0x18(%rax) movq 0x40(%rsp), %rax movb 0x5(%rax), %cl andb $-0x2, %cl orb $0x1, %cl movb %cl, 0x5(%rax) movq 0x60(%rsp), %rdi movq 0x40(%rsp), %rsi movl $0x3, %edx callq 0x2a3c0 movq 0x48(%rsp), %rax movq %rax, 0x50(%rsp) movq 0x50(%rsp), %rax movq 0x8(%rax), %rax movq %rax, 0x48(%rsp) jmp 0x625ea addq $0x68, %rsp retq nopw %cs:(%rax,%rax)
close_var_refs: sub rsp, 68h mov [rsp+68h+var_8], rdi mov [rsp+68h+var_10], rsi mov rax, [rsp+68h+var_10] mov rax, [rax+30h] mov [rsp+68h+var_18], rax mov rax, [rsp+68h+var_18] mov rax, [rax+8] mov [rsp+68h+var_20], rax loc_625EA: mov rax, [rsp+68h+var_18] mov rcx, [rsp+68h+var_10] add rcx, 28h ; '(' cmp rax, rcx jz loc_62720 mov rax, [rsp+68h+var_18] add rax, 0FFFFFFFFFFFFFFF8h mov [rsp+68h+var_28], rax mov rax, [rsp+68h+var_28] movzx eax, word ptr [rax+6] mov [rsp+68h+var_2C], eax mov rax, [rsp+68h+var_28] mov al, [rax+5] shr al, 1 and al, 1 cmp al, 0 jz short loc_6267D mov rax, [rsp+68h+var_28] mov [rsp+68h+var_58], rax mov rax, [rsp+68h+var_10] mov rax, [rax+18h] movsxd rcx, [rsp+68h+var_2C] shl rcx, 4 add rax, rcx mov rdi, [rax] mov rsi, [rax+8] call js_dup mov rcx, rax mov rax, [rsp+68h+var_58] mov [rsp+68h+var_40], rcx mov [rsp+68h+var_38], rdx mov rcx, [rsp+68h+var_40] mov [rax+20h], rcx mov rcx, [rsp+68h+var_38] mov [rax+28h], rcx jmp short loc_626CC loc_6267D: mov rax, [rsp+68h+var_28] mov [rsp+68h+var_60], rax mov rax, [rsp+68h+var_10] mov rax, [rax+20h] movsxd rcx, [rsp+68h+var_2C] shl rcx, 4 add rax, rcx mov rdi, [rax] mov rsi, [rax+8] call js_dup mov rcx, rax mov rax, [rsp+68h+var_60] mov [rsp+68h+var_50], rcx mov [rsp+68h+var_48], rdx mov rcx, [rsp+68h+var_50] mov [rax+20h], rcx mov rcx, [rsp+68h+var_48] mov [rax+28h], rcx loc_626CC: mov rcx, [rsp+68h+var_28] add rcx, 20h ; ' ' mov rax, [rsp+68h+var_28] mov [rax+18h], rcx mov rax, [rsp+68h+var_28] mov cl, [rax+5] and cl, 0FEh or cl, 1 mov [rax+5], cl mov rdi, [rsp+68h+var_8] mov rsi, [rsp+68h+var_28] mov edx, 3 call add_gc_object mov rax, [rsp+68h+var_20] mov [rsp+68h+var_18], rax mov rax, [rsp+68h+var_18] mov rax, [rax+8] mov [rsp+68h+var_20], rax jmp loc_625EA loc_62720: add rsp, 68h retn
_QWORD * close_var_refs(long long a1, _QWORD *a2) { _QWORD *result; // rax long long v3; // rax long long v4; // rdx long long v5; // [rsp+40h] [rbp-28h] _QWORD *i; // [rsp+48h] [rbp-20h] _QWORD *v7; // [rsp+50h] [rbp-18h] v7 = (_QWORD *)a2[6]; for ( i = (_QWORD *)v7[1]; ; i = (_QWORD *)i[1] ) { result = v7; if ( v7 == a2 + 5 ) break; v5 = (long long)(v7 - 1); if ( (*((_BYTE *)v7 - 3) & 2) != 0 ) v3 = 16LL * *((unsigned __int16 *)v7 - 1) + a2[3]; else v3 = 16LL * *((unsigned __int16 *)v7 - 1) + a2[4]; *(_QWORD *)(v5 + 32) = js_dup(*(_DWORD **)v3, *(_QWORD *)(v3 + 8)); *(_QWORD *)(v5 + 40) = v4; *(_QWORD *)(v5 + 24) = v5 + 32; *(_BYTE *)(v5 + 5) = *(_BYTE *)(v5 + 5) & 0xFE | 1; add_gc_object(a1, v5, 3); v7 = i; } return result; }
close_var_refs: SUB RSP,0x68 MOV qword ptr [RSP + 0x60],RDI MOV qword ptr [RSP + 0x58],RSI MOV RAX,qword ptr [RSP + 0x58] MOV RAX,qword ptr [RAX + 0x30] MOV qword ptr [RSP + 0x50],RAX MOV RAX,qword ptr [RSP + 0x50] MOV RAX,qword ptr [RAX + 0x8] MOV qword ptr [RSP + 0x48],RAX LAB_001625ea: MOV RAX,qword ptr [RSP + 0x50] MOV RCX,qword ptr [RSP + 0x58] ADD RCX,0x28 CMP RAX,RCX JZ 0x00162720 MOV RAX,qword ptr [RSP + 0x50] ADD RAX,-0x8 MOV qword ptr [RSP + 0x40],RAX MOV RAX,qword ptr [RSP + 0x40] MOVZX EAX,word ptr [RAX + 0x6] MOV dword ptr [RSP + 0x3c],EAX MOV RAX,qword ptr [RSP + 0x40] MOV AL,byte ptr [RAX + 0x5] SHR AL,0x1 AND AL,0x1 CMP AL,0x0 JZ 0x0016267d MOV RAX,qword ptr [RSP + 0x40] MOV qword ptr [RSP + 0x10],RAX MOV RAX,qword ptr [RSP + 0x58] MOV RAX,qword ptr [RAX + 0x18] MOVSXD RCX,dword ptr [RSP + 0x3c] SHL RCX,0x4 ADD RAX,RCX MOV RDI,qword ptr [RAX] MOV RSI,qword ptr [RAX + 0x8] CALL 0x001279c0 MOV RCX,RAX MOV RAX,qword ptr [RSP + 0x10] MOV qword ptr [RSP + 0x28],RCX MOV qword ptr [RSP + 0x30],RDX MOV RCX,qword ptr [RSP + 0x28] MOV qword ptr [RAX + 0x20],RCX MOV RCX,qword ptr [RSP + 0x30] MOV qword ptr [RAX + 0x28],RCX JMP 0x001626cc LAB_0016267d: MOV RAX,qword ptr [RSP + 0x40] MOV qword ptr [RSP + 0x8],RAX MOV RAX,qword ptr [RSP + 0x58] MOV RAX,qword ptr [RAX + 0x20] MOVSXD RCX,dword ptr [RSP + 0x3c] SHL RCX,0x4 ADD RAX,RCX MOV RDI,qword ptr [RAX] MOV RSI,qword ptr [RAX + 0x8] CALL 0x001279c0 MOV RCX,RAX MOV RAX,qword ptr [RSP + 0x8] MOV qword ptr [RSP + 0x18],RCX MOV qword ptr [RSP + 0x20],RDX MOV RCX,qword ptr [RSP + 0x18] MOV qword ptr [RAX + 0x20],RCX MOV RCX,qword ptr [RSP + 0x20] MOV qword ptr [RAX + 0x28],RCX LAB_001626cc: MOV RCX,qword ptr [RSP + 0x40] ADD RCX,0x20 MOV RAX,qword ptr [RSP + 0x40] MOV qword ptr [RAX + 0x18],RCX MOV RAX,qword ptr [RSP + 0x40] MOV CL,byte ptr [RAX + 0x5] AND CL,0xfe OR CL,0x1 MOV byte ptr [RAX + 0x5],CL MOV RDI,qword ptr [RSP + 0x60] MOV RSI,qword ptr [RSP + 0x40] MOV EDX,0x3 CALL 0x0012a3c0 MOV RAX,qword ptr [RSP + 0x48] MOV qword ptr [RSP + 0x50],RAX MOV RAX,qword ptr [RSP + 0x50] MOV RAX,qword ptr [RAX + 0x8] MOV qword ptr [RSP + 0x48],RAX JMP 0x001625ea LAB_00162720: ADD RSP,0x68 RET
void close_var_refs(int8 param_1,long param_2) { int8 *puVar1; int1 auVar2 [16]; long local_20; long local_18; local_18 = *(long *)(param_2 + 0x30); local_20 = *(long *)(local_18 + 8); while (local_18 != param_2 + 0x28) { if ((*(byte *)(local_18 + -3) >> 1 & 1) == 0) { puVar1 = (int8 *) (*(long *)(param_2 + 0x20) + (long)(int)(uint)*(ushort *)(local_18 + -2) * 0x10); auVar2 = js_dup(*puVar1,puVar1[1]); *(int1 (*) [16])(local_18 + 0x18) = auVar2; } else { puVar1 = (int8 *) (*(long *)(param_2 + 0x18) + (long)(int)(uint)*(ushort *)(local_18 + -2) * 0x10); auVar2 = js_dup(*puVar1,puVar1[1]); *(int1 (*) [16])(local_18 + 0x18) = auVar2; } *(long *)(local_18 + 0x10) = local_18 + 0x18; *(byte *)(local_18 + -3) = *(byte *)(local_18 + -3) & 0xfe | 1; add_gc_object(param_1,local_18 + -8,3); local_18 = local_20; local_20 = *(long *)(local_20 + 8); } return; }
20,567
close_var_refs
bluesky950520[P]quickjs/quickjs.c
static void close_var_refs(JSRuntime *rt, JSStackFrame *sf) { struct list_head *el, *el1; JSVarRef *var_ref; int var_idx; list_for_each_safe(el, el1, &sf->var_ref_list) { var_ref = list_entry(el, JSVarRef, header.link); var_idx = var_ref->var_idx; if (var_ref->is_arg) var_ref->value = js_dup(sf->arg_buf[var_idx]); else var_ref->value = js_dup(sf->var_buf[var_idx]); var_ref->pvalue = &var_ref->value; /* the reference is no longer to a local variable */ var_ref->is_detached = TRUE; add_gc_object(rt, &var_ref->header, JS_GC_OBJ_TYPE_VAR_REF); } }
O2
c
close_var_refs: leaq 0x28(%rsi), %rax movq 0x30(%rsi), %rcx addq $0x98, %rdi cmpq %rax, %rcx je 0x37f0d movq 0x8(%rcx), %rdx movzwl -0x2(%rcx), %r9d testb $0x2, -0x3(%rcx) jne 0x37ec5 movq 0x20(%rsi), %r10 shll $0x4, %r9d movq (%r10,%r9), %r8 movq 0x8(%r10,%r9), %r9 cmpl $-0x9, %r9d jae 0x37edc jmp 0x37edf movq 0x18(%rsi), %r10 shll $0x4, %r9d movq (%r10,%r9), %r8 movq 0x8(%r10,%r9), %r9 cmpl $-0xa, %r9d jbe 0x37edf incl (%r8) leaq 0x18(%rcx), %r10 movq %r8, 0x18(%rcx) movq %r9, 0x20(%rcx) movq %r10, 0x10(%rcx) orb $0x1, -0x3(%rcx) movb $0x3, -0x4(%rcx) movq (%rdi), %r8 movq %rcx, 0x8(%r8) movq %r8, (%rcx) movq %rdi, 0x8(%rcx) movq %rcx, (%rdi) movq %rdx, %rcx jmp 0x37e98 retq
close_var_refs: lea rax, [rsi+28h] mov rcx, [rsi+30h] add rdi, 98h loc_37E98: cmp rcx, rax jz short locret_37F0D mov rdx, [rcx+8] movzx r9d, word ptr [rcx-2] test byte ptr [rcx-3], 2 jnz short loc_37EC5 mov r10, [rsi+20h] shl r9d, 4 mov r8, [r10+r9] mov r9, [r10+r9+8] cmp r9d, 0FFFFFFF7h jnb short loc_37EDC jmp short loc_37EDF loc_37EC5: mov r10, [rsi+18h] shl r9d, 4 mov r8, [r10+r9] mov r9, [r10+r9+8] cmp r9d, 0FFFFFFF6h jbe short loc_37EDF loc_37EDC: inc dword ptr [r8] loc_37EDF: lea r10, [rcx+18h] mov [rcx+18h], r8 mov [rcx+20h], r9 mov [rcx+10h], r10 or byte ptr [rcx-3], 1 mov byte ptr [rcx-4], 3 mov r8, [rdi] mov [r8+8], rcx mov [rcx], r8 mov [rcx+8], rdi mov [rdi], rcx mov rcx, rdx jmp short loc_37E98 locret_37F0D: retn
_QWORD * close_var_refs(long long a1, _QWORD *a2) { _QWORD *result; // rax _QWORD *v3; // rcx long long *v4; // rdi _QWORD *v5; // rdx int v6; // r9d long long v7; // r10 long long v8; // r9 _DWORD *v9; // r8 long long v10; // r9 long long v11; // r10 long long v12; // r9 long long v13; // r8 result = a2 + 5; v3 = (_QWORD *)a2[6]; v4 = (long long *)(a1 + 152); while ( v3 != result ) { v5 = (_QWORD *)v3[1]; v6 = *((unsigned __int16 *)v3 - 1); if ( (*((_BYTE *)v3 - 3) & 2) != 0 ) { v11 = a2[3]; v12 = (unsigned int)(16 * v6); v9 = *(_DWORD **)(v11 + v12); v10 = *(_QWORD *)(v11 + v12 + 8); if ( (unsigned int)v10 <= 0xFFFFFFF6 ) goto LABEL_8; LABEL_7: ++*v9; goto LABEL_8; } v7 = a2[4]; v8 = (unsigned int)(16 * v6); v9 = *(_DWORD **)(v7 + v8); v10 = *(_QWORD *)(v7 + v8 + 8); if ( (unsigned int)v10 >= 0xFFFFFFF7 ) goto LABEL_7; LABEL_8: v3[3] = v9; v3[4] = v10; v3[2] = v3 + 3; *((_BYTE *)v3 - 3) |= 1u; *((_BYTE *)v3 - 4) = 3; v13 = *v4; *(_QWORD *)(v13 + 8) = v3; *v3 = v13; v3[1] = v4; *v4 = (long long)v3; v3 = v5; } return result; }
close_var_refs: LEA RAX,[RSI + 0x28] MOV RCX,qword ptr [RSI + 0x30] ADD RDI,0x98 LAB_00137e98: CMP RCX,RAX JZ 0x00137f0d MOV RDX,qword ptr [RCX + 0x8] MOVZX R9D,word ptr [RCX + -0x2] TEST byte ptr [RCX + -0x3],0x2 JNZ 0x00137ec5 MOV R10,qword ptr [RSI + 0x20] SHL R9D,0x4 MOV R8,qword ptr [R10 + R9*0x1] MOV R9,qword ptr [R10 + R9*0x1 + 0x8] CMP R9D,-0x9 JNC 0x00137edc JMP 0x00137edf LAB_00137ec5: MOV R10,qword ptr [RSI + 0x18] SHL R9D,0x4 MOV R8,qword ptr [R10 + R9*0x1] MOV R9,qword ptr [R10 + R9*0x1 + 0x8] CMP R9D,-0xa JBE 0x00137edf LAB_00137edc: INC dword ptr [R8] LAB_00137edf: LEA R10,[RCX + 0x18] MOV qword ptr [RCX + 0x18],R8 MOV qword ptr [RCX + 0x20],R9 MOV qword ptr [RCX + 0x10],R10 OR byte ptr [RCX + -0x3],0x1 MOV byte ptr [RCX + -0x4],0x3 MOV R8,qword ptr [RDI] MOV qword ptr [R8 + 0x8],RCX MOV qword ptr [RCX],R8 MOV qword ptr [RCX + 0x8],RDI MOV qword ptr [RDI],RCX MOV RCX,RDX JMP 0x00137e98 LAB_00137f0d: RET
void close_var_refs(long param_1,long param_2) { long *plVar1; int *piVar2; long *plVar3; long *plVar4; uint uVar5; long lVar6; plVar4 = (long *)(param_1 + 0x98); plVar3 = *(long **)(param_2 + 0x30); while (plVar3 != (long *)(param_2 + 0x28)) { plVar1 = (long *)plVar3[1]; if ((*plVar3 & 0x20000000000) == 0) { lVar6 = (ulong)*(ushort *)((long)plVar3 + -2) * 0x10; piVar2 = *(int **)(*(long *)(param_2 + 0x20) + lVar6); lVar6 = *(long *)(*(long *)(param_2 + 0x20) + 8 + lVar6); uVar5 = (uint)lVar6; } else { lVar6 = (ulong)*(ushort *)((long)plVar3 + -2) * 0x10; piVar2 = *(int **)(*(long *)(param_2 + 0x18) + lVar6); lVar6 = *(long *)(*(long *)(param_2 + 0x18) + 8 + lVar6); uVar5 = (uint)lVar6; } if (0xfffffff6 < uVar5) { *piVar2 = *piVar2 + 1; } plVar3[3] = (long)piVar2; plVar3[4] = lVar6; plVar3[2] = (long)(plVar3 + 3); *(byte *)((long)plVar3 + -3) = *(byte *)((long)plVar3 + -3) | 1; *(int1 *)((long)plVar3 + -4) = 3; lVar6 = *plVar4; *(long **)(lVar6 + 8) = plVar3; *plVar3 = lVar6; plVar3[1] = (long)plVar4; *plVar4 = (long)plVar3; plVar3 = plVar1; } return; }
20,568
nlohmann::json_abi_v3_11_3::detail::serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>::serializer(std::shared_ptr<nlohmann::json_abi_v3_11_3::detail::output_adapter_protocol<char>>, char, nlohmann::json_abi_v3_11_3::detail::error_handler_t)
hkr04[P]cpp-mcp/common/json.hpp
serializer(output_adapter_t<char> s, const char ichar, error_handler_t error_handler_ = error_handler_t::strict) : o(std::move(s)) , loc(std::localeconv()) , thousands_sep(loc->thousands_sep == nullptr ? '\0' : std::char_traits<char>::to_char_type(* (loc->thousands_sep))) , decimal_point(loc->decimal_point == nullptr ? '\0' : std::char_traits<char>::to_char_type(* (loc->decimal_point))) , indent_char(ichar) , indent_string(512, indent_char) , error_handler(error_handler_) {}
O1
cpp
nlohmann::json_abi_v3_11_3::detail::serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>::serializer(std::shared_ptr<nlohmann::json_abi_v3_11_3::detail::output_adapter_protocol<char>>, char, nlohmann::json_abi_v3_11_3::detail::error_handler_t): pushq %rbp pushq %r15 pushq %r14 pushq %rbx pushq %rax movl %ecx, %ebp movl %edx, %r14d movq %rdi, %rbx xorl %r15d, %r15d movq %r15, 0x8(%rdi) movups (%rsi), %xmm0 movq %r15, 0x8(%rsi) movups %xmm0, (%rdi) movq %r15, (%rsi) xorps %xmm0, %xmm0 movups %xmm0, 0x40(%rdi) movups %xmm0, 0x30(%rdi) movups %xmm0, 0x20(%rdi) movups %xmm0, 0x10(%rdi) callq 0x8a30 movq %rax, 0x50(%rbx) movq 0x8(%rax), %rcx testq %rcx, %rcx je 0xd8cf movb (%rcx), %r15b movb %r15b, 0x58(%rbx) movq (%rax), %rax testq %rax, %rax je 0xd8df movb (%rax), %al jmp 0xd8e1 xorl %eax, %eax movb %al, 0x59(%rbx) leaq 0x5a(%rbx), %rdi movl $0x200, %edx # imm = 0x200 xorl %esi, %esi callq 0x82e0 movb %r14b, 0x25a(%rbx) leaq 0x260(%rbx), %rdi leaq 0x270(%rbx), %rax movq %rax, 0x260(%rbx) movsbl %r14b, %edx movl $0x200, %esi # imm = 0x200 callq 0x8660 movl %ebp, 0x280(%rbx) addq $0x8, %rsp popq %rbx popq %r14 popq %r15 popq %rbp retq movq %rax, %r14 movq 0x8(%rbx), %rdi testq %rdi, %rdi je 0xd940 callq 0xb9de movq %r14, %rdi callq 0x8960
_ZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEC2ESt10shared_ptrINS1_23output_adapter_protocolIcEEEcNS1_15error_handler_tE: push rbp push r15 push r14 push rbx push rax mov ebp, ecx mov r14d, edx mov rbx, rdi xor r15d, r15d mov [rdi+8], r15 movups xmm0, xmmword ptr [rsi] mov [rsi+8], r15 movups xmmword ptr [rdi], xmm0 mov [rsi], r15 xorps xmm0, xmm0 movups xmmword ptr [rdi+40h], xmm0 movups xmmword ptr [rdi+30h], xmm0 movups xmmword ptr [rdi+20h], xmm0 movups xmmword ptr [rdi+10h], xmm0 call _localeconv mov [rbx+50h], rax mov rcx, [rax+8] test rcx, rcx jz short loc_D8CF mov r15b, [rcx] loc_D8CF: mov [rbx+58h], r15b mov rax, [rax] test rax, rax jz short loc_D8DF mov al, [rax] jmp short loc_D8E1 loc_D8DF: xor eax, eax loc_D8E1: mov [rbx+59h], al lea rdi, [rbx+5Ah] mov edx, 200h xor esi, esi call _memset mov [rbx+25Ah], r14b lea rdi, [rbx+260h] lea rax, [rbx+270h] mov [rbx+260h], rax movsx edx, r14b mov esi, 200h call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructEmc; std::string::_M_construct(ulong,char) mov [rbx+280h], ebp add rsp, 8 pop rbx pop r14 pop r15 pop rbp retn mov r14, rax mov rdi, [rbx+8] test rdi, rdi jz short loc_D940 call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void) loc_D940: mov rdi, r14 call __Unwind_Resume
long long nlohmann::json_abi_v3_11_3::detail::serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>::serializer( long long a1, __int128 *a2, char a3, int a4) { char v6; // r15 __int128 v7; // xmm0 long long v8; // rax char *v9; // rcx char *v10; // rax char v11; // al long long result; // rax v6 = 0; *(_QWORD *)(a1 + 8) = 0LL; v7 = *a2; *((_QWORD *)a2 + 1) = 0LL; *(_OWORD *)a1 = v7; *(_QWORD *)a2 = 0LL; *(_OWORD *)(a1 + 64) = 0LL; *(_OWORD *)(a1 + 48) = 0LL; *(_OWORD *)(a1 + 32) = 0LL; *(_OWORD *)(a1 + 16) = 0LL; v8 = localeconv(a1); *(_QWORD *)(a1 + 80) = v8; v9 = *(char **)(v8 + 8); if ( v9 ) v6 = *v9; *(_BYTE *)(a1 + 88) = v6; v10 = *(char **)v8; if ( v10 ) v11 = *v10; else v11 = 0; *(_BYTE *)(a1 + 89) = v11; memset(a1 + 90, 0LL, 512LL); *(_BYTE *)(a1 + 602) = a3; *(_QWORD *)(a1 + 608) = a1 + 624; result = std::string::_M_construct(a1 + 608, 512LL, (unsigned int)a3); *(_DWORD *)(a1 + 640) = a4; return result; }
serializer: PUSH RBP PUSH R15 PUSH R14 PUSH RBX PUSH RAX MOV EBP,ECX MOV R14D,EDX MOV RBX,RDI XOR R15D,R15D MOV qword ptr [RDI + 0x8],R15 MOVUPS XMM0,xmmword ptr [RSI] MOV qword ptr [RSI + 0x8],R15 MOVUPS xmmword ptr [RDI],XMM0 MOV qword ptr [RSI],R15 XORPS XMM0,XMM0 MOVUPS xmmword ptr [RDI + 0x40],XMM0 MOVUPS xmmword ptr [RDI + 0x30],XMM0 MOVUPS xmmword ptr [RDI + 0x20],XMM0 MOVUPS xmmword ptr [RDI + 0x10],XMM0 CALL 0x00108a30 MOV qword ptr [RBX + 0x50],RAX MOV RCX,qword ptr [RAX + 0x8] TEST RCX,RCX JZ 0x0010d8cf MOV R15B,byte ptr [RCX] LAB_0010d8cf: MOV byte ptr [RBX + 0x58],R15B MOV RAX,qword ptr [RAX] TEST RAX,RAX JZ 0x0010d8df MOV AL,byte ptr [RAX] JMP 0x0010d8e1 LAB_0010d8df: XOR EAX,EAX LAB_0010d8e1: MOV byte ptr [RBX + 0x59],AL LEA RDI,[RBX + 0x5a] MOV EDX,0x200 XOR ESI,ESI CALL 0x001082e0 MOV byte ptr [RBX + 0x25a],R14B LEA RDI,[RBX + 0x260] LEA RAX,[RBX + 0x270] MOV qword ptr [RBX + 0x260],RAX LAB_0010d910: MOVSX EDX,R14B MOV ESI,0x200 CALL 0x00108660 LAB_0010d91e: MOV dword ptr [RBX + 0x280],EBP ADD RSP,0x8 POP RBX POP R14 POP R15 POP RBP RET
/* nlohmann::json_abi_v3_11_3::detail::serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char> >, void> >::serializer(std::shared_ptr<nlohmann::json_abi_v3_11_3::detail::output_adapter_protocol<char> >, char, nlohmann::json_abi_v3_11_3::detail::error_handler_t) */ void __thiscall nlohmann::json_abi_v3_11_3::detail:: serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>> ::serializer(serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>> *this,int8 *param_2, serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>> param_3,int4 param_4) { int8 uVar1; serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>> sVar2; lconv *plVar3; sVar2 = (serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>> )0x0; *(int8 *)(this + 8) = 0; uVar1 = param_2[1]; param_2[1] = 0; *(int8 *)this = *param_2; *(int8 *)(this + 8) = uVar1; *param_2 = 0; *(int8 *)(this + 0x40) = 0; *(int8 *)(this + 0x48) = 0; *(int8 *)(this + 0x30) = 0; *(int8 *)(this + 0x38) = 0; *(int8 *)(this + 0x20) = 0; *(int8 *)(this + 0x28) = 0; *(int8 *)(this + 0x10) = 0; *(int8 *)(this + 0x18) = 0; plVar3 = localeconv(); *(lconv **)(this + 0x50) = plVar3; if ((serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>> *)plVar3->thousands_sep != (serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>> *)0x0) { sVar2 = *(serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>> *)plVar3->thousands_sep; } this[0x58] = sVar2; if ((serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>> *)plVar3->decimal_point == (serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>> *)0x0) { sVar2 = (serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>> )0x0; } else { sVar2 = *(serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>> *)plVar3->decimal_point; } this[0x59] = sVar2; memset(this + 0x5a,0,0x200); this[0x25a] = param_3; *(serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>> **)(this + 0x260) = this + 0x270; /* try { // try from 0010d910 to 0010d91d has its CatchHandler @ 0010d92f */ std::__cxx11::string::_M_construct((ulong)(this + 0x260),'\0'); *(int4 *)(this + 0x280) = param_4; return; }
20,569
minja::Parser::unterminated(minja::TemplateToken const&) const
monkey531[P]llama/common/minja.hpp
std::runtime_error unterminated(const TemplateToken & token) const { return std::runtime_error("Unterminated " + TemplateToken::typeToString(token.type) + error_location_suffix(*template_str, token.location.pos)); }
O3
cpp
minja::Parser::unterminated(minja::TemplateToken const&) const: pushq %r15 pushq %r14 pushq %r12 pushq %rbx subq $0x88, %rsp movq %rdx, %r14 movq %rsi, %r15 movq %rdi, %rbx movl 0x8(%rdx), %esi leaq 0x68(%rsp), %r12 movq %r12, %rdi callq 0x7d206 leaq 0x3f5b1(%rip), %rcx # 0xbbcb5 movl $0xd, %r8d movq %r12, %rdi xorl %esi, %esi xorl %edx, %edx callq 0x19760 leaq 0x38(%rsp), %r12 movq %r12, -0x10(%r12) movq (%rax), %rdx movq %rax, %rcx addq $0x10, %rcx cmpq %rcx, %rdx je 0x7c73e movq %rdx, 0x28(%rsp) movq (%rcx), %rdx movq %rdx, 0x38(%rsp) jmp 0x7c746 movups (%rcx), %xmm0 movups %xmm0, (%r12) movq 0x8(%rax), %rdx movq %rdx, 0x30(%rsp) movq %rcx, (%rax) movq $0x0, 0x8(%rax) movb $0x0, 0x10(%rax) movq (%r15), %rsi movq 0x20(%r14), %rdx leaq 0x48(%rsp), %rdi callq 0x5c4a0 movq 0x28(%rsp), %rcx movq 0x30(%rsp), %r8 movq 0x50(%rsp), %rdx leaq (%rdx,%r8), %rax movl $0xf, %edi cmpq %r12, %rcx je 0x7c791 movq 0x38(%rsp), %rdi movq 0x48(%rsp), %rsi cmpq %rdi, %rax jbe 0x7c7b4 leaq 0x58(%rsp), %r9 movl $0xf, %edi cmpq %r9, %rsi je 0x7c7af movq 0x58(%rsp), %rdi cmpq %rdi, %rax jbe 0x7c7c0 leaq 0x28(%rsp), %rdi callq 0x191d0 jmp 0x7c7ce leaq 0x48(%rsp), %rdi xorl %esi, %esi xorl %edx, %edx callq 0x19760 leaq 0x18(%rsp), %rdx movq %rdx, -0x10(%rdx) movq (%rax), %rsi leaq 0x10(%rax), %rcx cmpq %rcx, %rsi je 0x7c7f2 movq %rsi, 0x8(%rsp) movq (%rcx), %rdx movq %rdx, 0x18(%rsp) jmp 0x7c7f8 movups (%rcx), %xmm0 movups %xmm0, (%rdx) movq %rax, %rdx addq $0x8, %rdx movq 0x8(%rax), %rsi movq %rsi, 0x10(%rsp) movq %rcx, (%rax) movq $0x0, (%rdx) movb $0x0, (%rcx) leaq 0x8(%rsp), %rsi movq %rbx, %rdi callq 0x19ac0 leaq 0x18(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0x7c83d movq 0x18(%rsp), %rsi incq %rsi callq 0x196b0 leaq 0x58(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0x7c858 movq 0x58(%rsp), %rsi incq %rsi callq 0x196b0 movq 0x28(%rsp), %rdi cmpq %r12, %rdi je 0x7c86f movq 0x38(%rsp), %rsi incq %rsi callq 0x196b0 leaq 0x78(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0x7c88a movq 0x78(%rsp), %rsi incq %rsi callq 0x196b0 movq %rbx, %rax addq $0x88, %rsp popq %rbx popq %r12 popq %r14 popq %r15 retq movq %rax, %rbx leaq 0x18(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0x7c8bf movq 0x18(%rsp), %rsi incq %rsi callq 0x196b0 jmp 0x7c8bf movq %rax, %rbx leaq 0x58(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0x7c8df movq 0x58(%rsp), %rsi incq %rsi callq 0x196b0 jmp 0x7c8df movq %rax, %rbx movq 0x28(%rsp), %rdi cmpq %r12, %rdi je 0x7c8fb movq 0x38(%rsp), %rsi incq %rsi callq 0x196b0 jmp 0x7c8fb movq %rax, %rbx leaq 0x78(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0x7c916 movq 0x78(%rsp), %rsi incq %rsi callq 0x196b0 movq %rbx, %rdi callq 0x19be0
_ZNK5minja6Parser12unterminatedERKNS_13TemplateTokenE: push r15; int push r14; int push r12; int push rbx; int sub rsp, 88h mov r14, rdx mov r15, rsi mov rbx, rdi mov esi, [rdx+8] lea r12, [rsp+0A8h+var_40] mov rdi, r12 call _ZN5minja13TemplateToken12typeToStringB5cxx11ENS0_4TypeE; minja::TemplateToken::typeToString(minja::TemplateToken::Type) lea rcx, aUnterminated; "Unterminated " mov r8d, 0Dh mov rdi, r12 xor esi, esi xor edx, edx call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE7replaceEmmPKcm; std::string::replace(ulong,ulong,char const*,ulong) lea r12, [rsp+0A8h+var_70] mov [r12-10h], r12 mov rdx, [rax] mov rcx, rax add rcx, 10h; int cmp rdx, rcx jz short loc_7C73E mov [rsp+0A8h+var_80], rdx mov rdx, [rcx] mov [rsp+0A8h+var_70], rdx jmp short loc_7C746 loc_7C73E: movups xmm0, xmmword ptr [rcx] movups xmmword ptr [r12], xmm0 loc_7C746: mov rdx, [rax+8] mov qword ptr [rsp+0A8h+var_78], rdx; int mov [rax], rcx mov qword ptr [rax+8], 0 mov byte ptr [rax+10h], 0 mov rsi, [r15]; int mov rdx, [r14+20h]; int lea rdi, [rsp+0A8h+var_60]; int call _ZN5minjaL21error_location_suffixERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEm; minja::error_location_suffix(std::string const&,ulong) mov rcx, [rsp+0A8h+var_80] mov r8, qword ptr [rsp+0A8h+var_78] mov rdx, [rsp+0A8h+var_58] lea rax, [rdx+r8] mov edi, 0Fh cmp rcx, r12 jz short loc_7C791 mov rdi, [rsp+0A8h+var_70] loc_7C791: mov rsi, qword ptr [rsp+0A8h+var_60] cmp rax, rdi jbe short loc_7C7B4 lea r9, [rsp+0A8h+var_50] mov edi, 0Fh cmp rsi, r9 jz short loc_7C7AF mov rdi, [rsp+0A8h+var_50] loc_7C7AF: cmp rax, rdi jbe short loc_7C7C0 loc_7C7B4: lea rdi, [rsp+0A8h+var_80] call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9_M_appendEPKcm; std::string::_M_append(char const*,ulong) jmp short loc_7C7CE loc_7C7C0: lea rdi, [rsp+0A8h+var_60] xor esi, esi xor edx, edx call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE7replaceEmmPKcm; std::string::replace(ulong,ulong,char const*,ulong) loc_7C7CE: lea rdx, [rsp+0A8h+var_90] mov [rdx-10h], rdx mov rsi, [rax] lea rcx, [rax+10h] cmp rsi, rcx jz short loc_7C7F2 mov [rsp+0A8h+var_A0], rsi mov rdx, [rcx] mov [rsp+0A8h+var_90], rdx jmp short loc_7C7F8 loc_7C7F2: movups xmm0, xmmword ptr [rcx] movups xmmword ptr [rdx], xmm0 loc_7C7F8: mov rdx, rax add rdx, 8 mov rsi, [rax+8] mov [rsp+0A8h+var_98], rsi mov [rax], rcx mov qword ptr [rdx], 0 mov byte ptr [rcx], 0 lea rsi, [rsp+0A8h+var_A0] mov rdi, rbx call __ZNSt13runtime_errorC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; std::runtime_error::runtime_error(std::string const&) lea rax, [rsp+0A8h+var_90] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_7C83D mov rsi, [rsp+0A8h+var_90] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_7C83D: lea rax, [rsp+0A8h+var_50] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_7C858 mov rsi, [rsp+0A8h+var_50] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_7C858: mov rdi, [rsp+0A8h+var_80]; void * cmp rdi, r12 jz short loc_7C86F mov rsi, [rsp+0A8h+var_70] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_7C86F: lea rax, [rsp+0A8h+var_30] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_7C88A mov rsi, [rsp+0A8h+var_30] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_7C88A: mov rax, rbx add rsp, 88h pop rbx pop r12 pop r14 pop r15 retn mov rbx, rax lea rax, [rsp+arg_10] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_7C8BF mov rsi, [rsp+arg_10] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) jmp short loc_7C8BF mov rbx, rax loc_7C8BF: lea rax, [rsp+arg_50] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_7C8DF mov rsi, [rsp+arg_50] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) jmp short loc_7C8DF mov rbx, rax loc_7C8DF: mov rdi, [rsp+arg_20]; void * cmp rdi, r12 jz short loc_7C8FB mov rsi, [rsp+arg_30] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) jmp short loc_7C8FB mov rbx, rax loc_7C8FB: lea rax, [rsp+arg_70] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_7C916 mov rsi, [rsp+arg_70] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_7C916: mov rdi, rbx call __Unwind_Resume
minja::Parser * minja::Parser::unterminated(minja::Parser *this, const minja::TemplateToken *a2, long long a3) { long long v5; // rax __int128 *v6; // rcx unsigned long long v7; // rax unsigned long long v8; // rdi unsigned long long v9; // rdi void **v10; // rax __int128 *v11; // rcx void *v13[2]; // [rsp+8h] [rbp-A0h] BYREF __int128 v14; // [rsp+18h] [rbp-90h] BYREF void *v15; // [rsp+28h] [rbp-80h] BYREF int v16[2]; // [rsp+30h] [rbp-78h] __int128 v17; // [rsp+38h] [rbp-70h] BYREF int v18[2]; // [rsp+48h] [rbp-60h] BYREF long long v19; // [rsp+50h] [rbp-58h] _QWORD v20[2]; // [rsp+58h] [rbp-50h] BYREF void *v21[2]; // [rsp+68h] [rbp-40h] BYREF long long v22; // [rsp+78h] [rbp-30h] BYREF minja::TemplateToken::typeToString[abi:cxx11](v21, *(unsigned int *)(a3 + 8)); v5 = std::string::replace(v21, 0LL, 0LL); v15 = &v17; v6 = (__int128 *)(v5 + 16); if ( *(_QWORD *)v5 == v5 + 16 ) { v17 = *v6; } else { v15 = *(void **)v5; *(_QWORD *)&v17 = *(_QWORD *)v6; } *(_QWORD *)v16 = *(_QWORD *)(v5 + 8); *(_QWORD *)v5 = v6; *(_QWORD *)(v5 + 8) = 0LL; *(_BYTE *)(v5 + 16) = 0; minja::error_location_suffix((long long)v18, *(_QWORD *)a2, *(_QWORD *)(a3 + 32)); v7 = v19 + *(_QWORD *)v16; v8 = 15LL; if ( v15 != &v17 ) v8 = v17; if ( v7 <= v8 ) goto LABEL_10; v9 = 15LL; if ( *(_QWORD **)v18 != v20 ) v9 = v20[0]; if ( v7 <= v9 ) v10 = (void **)std::string::replace(v18, 0LL, 0LL); else LABEL_10: v10 = (void **)std::string::_M_append(&v15, *(_QWORD *)v18, v19); v13[0] = &v14; v11 = (__int128 *)(v10 + 2); if ( *v10 == v10 + 2 ) { v14 = *v11; } else { v13[0] = *v10; *(_QWORD *)&v14 = *(_QWORD *)v11; } v13[1] = v10[1]; *v10 = v11; v10[1] = 0LL; *(_BYTE *)v11 = 0; std::runtime_error::runtime_error(this, v13); if ( v13[0] != &v14 ) operator delete(v13[0], v14 + 1); if ( *(_QWORD **)v18 != v20 ) operator delete(*(void **)v18, v20[0] + 1LL); if ( v15 != &v17 ) operator delete(v15, v17 + 1); if ( v21[0] != &v22 ) operator delete(v21[0], v22 + 1); return this; }
unterminated: PUSH R15 PUSH R14 PUSH R12 PUSH RBX SUB RSP,0x88 MOV R14,RDX MOV R15,RSI MOV RBX,RDI MOV ESI,dword ptr [RDX + 0x8] LEA R12,[RSP + 0x68] MOV RDI,R12 CALL 0x0017d206 LAB_0017c6fd: LEA RCX,[0x1bbcb5] MOV R8D,0xd MOV RDI,R12 XOR ESI,ESI XOR EDX,EDX CALL 0x00119760 LEA R12,[RSP + 0x38] MOV qword ptr [R12 + -0x10],R12 MOV RDX,qword ptr [RAX] MOV RCX,RAX ADD RCX,0x10 CMP RDX,RCX JZ 0x0017c73e MOV qword ptr [RSP + 0x28],RDX MOV RDX,qword ptr [RCX] MOV qword ptr [RSP + 0x38],RDX JMP 0x0017c746 LAB_0017c73e: MOVUPS XMM0,xmmword ptr [RCX] MOVUPS xmmword ptr [R12],XMM0 LAB_0017c746: MOV RDX,qword ptr [RAX + 0x8] MOV qword ptr [RSP + 0x30],RDX MOV qword ptr [RAX],RCX MOV qword ptr [RAX + 0x8],0x0 MOV byte ptr [RAX + 0x10],0x0 MOV RSI,qword ptr [R15] MOV RDX,qword ptr [R14 + 0x20] LAB_0017c765: LEA RDI,[RSP + 0x48] CALL 0x0015c4a0 MOV RCX,qword ptr [RSP + 0x28] MOV R8,qword ptr [RSP + 0x30] MOV RDX,qword ptr [RSP + 0x50] LEA RAX,[RDX + R8*0x1] MOV EDI,0xf CMP RCX,R12 JZ 0x0017c791 MOV RDI,qword ptr [RSP + 0x38] LAB_0017c791: MOV RSI,qword ptr [RSP + 0x48] CMP RAX,RDI JBE 0x0017c7b4 LEA R9,[RSP + 0x58] MOV EDI,0xf CMP RSI,R9 JZ 0x0017c7af MOV RDI,qword ptr [RSP + 0x58] LAB_0017c7af: CMP RAX,RDI JBE 0x0017c7c0 LAB_0017c7b4: LEA RDI,[RSP + 0x28] CALL 0x001191d0 JMP 0x0017c7ce LAB_0017c7c0: LEA RDI,[RSP + 0x48] XOR ESI,ESI XOR EDX,EDX CALL 0x00119760 LAB_0017c7ce: LEA RDX,[RSP + 0x18] MOV qword ptr [RDX + -0x10],RDX MOV RSI,qword ptr [RAX] LEA RCX,[RAX + 0x10] CMP RSI,RCX JZ 0x0017c7f2 MOV qword ptr [RSP + 0x8],RSI MOV RDX,qword ptr [RCX] MOV qword ptr [RSP + 0x18],RDX JMP 0x0017c7f8 LAB_0017c7f2: MOVUPS XMM0,xmmword ptr [RCX] MOVUPS xmmword ptr [RDX],XMM0 LAB_0017c7f8: MOV RDX,RAX ADD RDX,0x8 MOV RSI,qword ptr [RAX + 0x8] MOV qword ptr [RSP + 0x10],RSI MOV qword ptr [RAX],RCX MOV qword ptr [RDX],0x0 MOV byte ptr [RCX],0x0 LAB_0017c815: LEA RSI,[RSP + 0x8] MOV RDI,RBX CALL 0x00119ac0 LAB_0017c822: LEA RAX,[RSP + 0x18] MOV RDI,qword ptr [RAX + -0x10] CMP RDI,RAX JZ 0x0017c83d MOV RSI,qword ptr [RSP + 0x18] INC RSI CALL 0x001196b0 LAB_0017c83d: LEA RAX,[RSP + 0x58] MOV RDI,qword ptr [RAX + -0x10] CMP RDI,RAX JZ 0x0017c858 MOV RSI,qword ptr [RSP + 0x58] INC RSI CALL 0x001196b0 LAB_0017c858: MOV RDI,qword ptr [RSP + 0x28] CMP RDI,R12 JZ 0x0017c86f MOV RSI,qword ptr [RSP + 0x38] INC RSI CALL 0x001196b0 LAB_0017c86f: LEA RAX,[RSP + 0x78] MOV RDI,qword ptr [RAX + -0x10] CMP RDI,RAX JZ 0x0017c88a MOV RSI,qword ptr [RSP + 0x78] INC RSI CALL 0x001196b0 LAB_0017c88a: MOV RAX,RBX ADD RSP,0x88 POP RBX POP R12 POP R14 POP R15 RET
/* minja::Parser::unterminated(minja::TemplateToken const&) const */ TemplateToken * minja::Parser::unterminated(TemplateToken *param_1) { long *plVar1; int8 *puVar2; ulong *puVar3; long in_RDX; int8 *in_RSI; ulong uVar4; long *local_a0; int8 local_98; long local_90; int8 uStack_88; ulong *local_80; long local_78; ulong local_70; long lStack_68; ulong *local_60; long local_58; ulong local_50 [2]; long *local_40 [2]; long local_30 [2]; TemplateToken::typeToString_abi_cxx11_((TemplateToken *)local_40); /* try { // try from 0017c6fd to 0017c715 has its CatchHandler @ 0017c8f8 */ plVar1 = (long *)std::__cxx11::string::replace((ulong)local_40,0,(char *)0x0,0x1bbcb5); puVar3 = (ulong *)(plVar1 + 2); if ((ulong *)*plVar1 == puVar3) { local_70 = *puVar3; lStack_68 = plVar1[3]; local_80 = &local_70; } else { local_70 = *puVar3; local_80 = (ulong *)*plVar1; } local_78 = plVar1[1]; *plVar1 = (long)puVar3; plVar1[1] = 0; *(int1 *)(plVar1 + 2) = 0; /* try { // try from 0017c765 to 0017c76e has its CatchHandler @ 0017c8dc */ error_location_suffix((minja *)&local_60,(string *)*in_RSI,*(ulong *)(in_RDX + 0x20)); uVar4 = 0xf; if (local_80 != &local_70) { uVar4 = local_70; } if (uVar4 < (ulong)(local_58 + local_78)) { uVar4 = 0xf; if (local_60 != local_50) { uVar4 = local_50[0]; } if ((ulong)(local_58 + local_78) <= uVar4) { puVar2 = (int8 *) std::__cxx11::string::replace((ulong)&local_60,0,(char *)0x0,(ulong)local_80); goto LAB_0017c7ce; } } /* try { // try from 0017c7b4 to 0017c7cd has its CatchHandler @ 0017c8bc */ puVar2 = (int8 *)std::__cxx11::string::_M_append((char *)&local_80,(ulong)local_60); LAB_0017c7ce: local_a0 = &local_90; plVar1 = puVar2 + 2; if ((long *)*puVar2 == plVar1) { local_90 = *plVar1; uStack_88 = puVar2[3]; } else { local_90 = *plVar1; local_a0 = (long *)*puVar2; } local_98 = puVar2[1]; *puVar2 = plVar1; puVar2[1] = 0; *(int1 *)plVar1 = 0; /* try { // try from 0017c815 to 0017c821 has its CatchHandler @ 0017c89c */ std::runtime_error::runtime_error((runtime_error *)param_1,(string *)&local_a0); if (local_a0 != &local_90) { operator_delete(local_a0,local_90 + 1); } if (local_60 != local_50) { operator_delete(local_60,local_50[0] + 1); } if (local_80 != &local_70) { operator_delete(local_80,local_70 + 1); } if (local_40[0] != local_30) { operator_delete(local_40[0],local_30[0] + 1); } return param_1; }
20,570
Load_log_event::write_data_header()
eloqsql/sql/log_event_server.cc
bool Load_log_event::write_data_header() { char buf[LOAD_HEADER_LEN]; int4store(buf + L_THREAD_ID_OFFSET, slave_proxy_id); int4store(buf + L_EXEC_TIME_OFFSET, exec_time); int4store(buf + L_SKIP_LINES_OFFSET, skip_lines); buf[L_TBL_LEN_OFFSET] = (char)table_name_len; buf[L_DB_LEN_OFFSET] = (char)db_len; int4store(buf + L_NUM_FIELDS_OFFSET, num_fields); return write_data(buf, LOAD_HEADER_LEN) != 0; }
O0
cpp
Load_log_event::write_data_header(): pushq %rbp movq %rsp, %rbp subq $0x60, %rsp movq %fs:0x28, %rax movq %rax, -0x8(%rbp) movq %rdi, -0x28(%rbp) movq -0x28(%rbp), %rax movq %rax, -0x50(%rbp) movq -0x50(%rbp), %rax leaq -0x20(%rbp), %rcx movq %rcx, -0x30(%rbp) movq 0x78(%rax), %rax movl %eax, %ecx movq -0x30(%rbp), %rax movl %ecx, (%rax) jmp 0xa1b39b movq -0x50(%rbp), %rax leaq -0x20(%rbp), %rcx addq $0x4, %rcx movq %rcx, -0x38(%rbp) movq 0x30(%rax), %rax movl %eax, %ecx movq -0x38(%rbp), %rax movl %ecx, (%rax) jmp 0xa1b3b9 movq -0x50(%rbp), %rax leaq -0x20(%rbp), %rcx addq $0x8, %rcx movq %rcx, -0x40(%rbp) movl 0xc0(%rax), %ecx movq -0x40(%rbp), %rax movl %ecx, (%rax) movq -0x50(%rbp), %rax movl 0x80(%rax), %ecx movb %cl, -0x14(%rbp) movl 0x84(%rax), %eax movb %al, -0x13(%rbp) movq -0x50(%rbp), %rax leaq -0x20(%rbp), %rcx addq $0xe, %rcx movq %rcx, -0x48(%rbp) movl 0x8c(%rax), %ecx movq -0x48(%rbp), %rax movl %ecx, (%rax) movq -0x50(%rbp), %rdi leaq -0x20(%rbp), %rsi movl $0x12, %edx callq 0xa2d030 movb %al, -0x51(%rbp) movq %fs:0x28, %rax movq -0x8(%rbp), %rcx cmpq %rcx, %rax jne 0xa1b439 movb -0x51(%rbp), %al andb $0x1, %al addq $0x60, %rsp popq %rbp retq callq 0x433650 nop
_ZN14Load_log_event17write_data_headerEv: push rbp mov rbp, rsp sub rsp, 60h mov rax, fs:28h mov [rbp+var_8], rax mov [rbp+var_28], rdi mov rax, [rbp+var_28] mov [rbp+var_50], rax mov rax, [rbp+var_50] lea rcx, [rbp+var_20] mov [rbp+var_30], rcx mov rax, [rax+78h] mov ecx, eax mov rax, [rbp+var_30] mov [rax], ecx jmp short $+2 loc_A1B39B: mov rax, [rbp+var_50] lea rcx, [rbp+var_20] add rcx, 4 mov [rbp+var_38], rcx mov rax, [rax+30h] mov ecx, eax mov rax, [rbp+var_38] mov [rax], ecx jmp short $+2 loc_A1B3B9: mov rax, [rbp+var_50] lea rcx, [rbp+var_20] add rcx, 8 mov [rbp+var_40], rcx mov ecx, [rax+0C0h] mov rax, [rbp+var_40] mov [rax], ecx mov rax, [rbp+var_50] mov ecx, [rax+80h] mov [rbp+var_14], cl mov eax, [rax+84h] mov [rbp+var_13], al mov rax, [rbp+var_50] lea rcx, [rbp+var_20] add rcx, 0Eh mov [rbp+var_48], rcx mov ecx, [rax+8Ch] mov rax, [rbp+var_48] mov [rax], ecx mov rdi, [rbp+var_50]; this lea rsi, [rbp+var_20]; char * mov edx, 12h; unsigned __int64 call _ZN9Log_event10write_dataEPKcm; Log_event::write_data(char const*,ulong) mov [rbp+var_51], al mov rax, fs:28h mov rcx, [rbp+var_8] cmp rax, rcx jnz short loc_A1B439 mov al, [rbp+var_51] and al, 1 add rsp, 60h pop rbp retn loc_A1B439: call ___stack_chk_fail
char Load_log_event::write_data_header(Load_log_event *this) { _DWORD v2[3]; // [rsp+40h] [rbp-20h] BYREF char v3; // [rsp+4Ch] [rbp-14h] char v4; // [rsp+4Dh] [rbp-13h] int v5; // [rsp+4Eh] [rbp-12h] unsigned long long v6; // [rsp+58h] [rbp-8h] v6 = __readfsqword(0x28u); v2[0] = *((_QWORD *)this + 15); v2[1] = *((_QWORD *)this + 6); v2[2] = *((_DWORD *)this + 48); v3 = *((_DWORD *)this + 32); v4 = *((_DWORD *)this + 33); v5 = *((_DWORD *)this + 35); return Log_event::write_data(this, (const char *)v2, 0x12uLL) & 1; }
set_cmp_func_datetime: PUSH RBP MOV RBP,RSP SUB RSP,0x50 MOV qword ptr [RBP + -0x8],RDI MOV qword ptr [RBP + -0x10],RSI MOV RDI,qword ptr [RBP + -0x8] MOV qword ptr [RBP + -0x18],RDI LEA RAX,[0x15a4ca0] MOV qword ptr [RDI + 0x18],RAX CALL 0x00a2f2e0 MOV RDI,qword ptr [RBP + -0x18] MOV DL,AL LEA RCX,[0xa1b440] LEA RAX,[0xa1b520] TEST DL,DL CMOVNZ RAX,RCX MOV qword ptr [RDI + 0x20],RAX MOV qword ptr [RDI + 0x28],0x0 MOV RAX,qword ptr [RBP + -0x10] MOV qword ptr [RBP + -0x48],RAX MOV RAX,qword ptr [RDI] MOV qword ptr [RBP + -0x40],RAX MOV RAX,RDI ADD RAX,0x50 MOV qword ptr [RBP + -0x38],RAX CALL 0x0074b390 MOV RSI,qword ptr [RBP + -0x48] MOV RDX,qword ptr [RBP + -0x40] MOV RCX,qword ptr [RBP + -0x38] MOV RDI,qword ptr [RBP + -0x18] MOV R8,RAX CALL 0x00a1b010 MOV RDI,qword ptr [RBP + -0x18] MOV qword ptr [RDI],RAX MOV RAX,qword ptr [RBP + -0x10] MOV qword ptr [RBP + -0x30],RAX MOV RAX,qword ptr [RDI + 0x8] MOV qword ptr [RBP + -0x28],RAX MOV RAX,RDI ADD RAX,0x58 MOV qword ptr [RBP + -0x20],RAX CALL 0x0074b390 MOV RSI,qword ptr [RBP + -0x30] MOV RDX,qword ptr [RBP + -0x28] MOV RCX,qword ptr [RBP + -0x20] MOV RDI,qword ptr [RBP + -0x18] MOV R8,RAX CALL 0x00a1b010 MOV RCX,RAX MOV RAX,qword ptr [RBP + -0x18] MOV qword ptr [RAX + 0x8],RCX XOR EAX,EAX AND AL,0x1 ADD RSP,0x50 POP RBP RET
/* Arg_comparator::set_cmp_func_datetime(THD*) */ int8 __thiscall Arg_comparator::set_cmp_func_datetime(Arg_comparator *this,THD *param_1) { Item **ppIVar1; char cVar2; code *pcVar3; Type_handler *pTVar4; int8 uVar5; *(int4 **)(this + 0x18) = &my_charset_latin1; cVar2 = is_owner_equal_func(this); pcVar3 = compare_datetime; if (cVar2 != '\0') { pcVar3 = compare_e_datetime; } *(code **)(this + 0x20) = pcVar3; *(int8 *)(this + 0x28) = 0; ppIVar1 = *(Item ***)this; pTVar4 = (Type_handler *)compare_type_handler(this); uVar5 = cache_converted_constant(this,param_1,ppIVar1,(Item **)(this + 0x50),pTVar4); *(int8 *)this = uVar5; ppIVar1 = *(Item ***)(this + 8); pTVar4 = (Type_handler *)compare_type_handler(this); uVar5 = cache_converted_constant(this,param_1,ppIVar1,(Item **)(this + 0x58),pTVar4); *(int8 *)(this + 8) = uVar5; return 0; }
20,571
minja::ArgumentsValue::has_named(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&)
monkey531[P]llama/common/minja.hpp
MacroNode(const Location & location, std::shared_ptr<VariableExpr> && n, Expression::Parameters && p, std::shared_ptr<TemplateNode> && b) : TemplateNode(location), name(std::move(n)), params(std::move(p)), body(std::move(b)) { for (size_t i = 0; i < params.size(); ++i) { const auto & name = params[i].first; if (!name.empty()) { named_param_positions[name] = i; } } }
O3
cpp
minja::ArgumentsValue::has_named(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&): pushq %rbp pushq %r15 pushq %r14 pushq %r12 pushq %rbx movq 0x18(%rdi), %r15 movq 0x20(%rdi), %r12 cmpq %r12, %r15 je 0xb446d movq (%rsi), %rbx movq 0x8(%rsi), %r14 cmpq %r14, 0x8(%r15) jne 0xb4464 movb $0x1, %bpl testq %r14, %r14 je 0xb446f movq (%r15), %rdi movq %rbx, %rsi movq %r14, %rdx callq 0x1a920 testl %eax, %eax je 0xb446f addq $0x70, %r15 cmpq %r12, %r15 jne 0xb4444 xorl %ebp, %ebp movl %ebp, %eax popq %rbx popq %r12 popq %r14 popq %r15 popq %rbp retq
_ZN5minja14ArgumentsValue9has_namedERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE: push rbp push r15 push r14 push r12 push rbx mov r15, [rdi+18h] mov r12, [rdi+20h] cmp r15, r12 jz short loc_B446D mov rbx, [rsi] mov r14, [rsi+8] loc_B4444: cmp [r15+8], r14 jnz short loc_B4464 mov bpl, 1 test r14, r14 jz short loc_B446F mov rdi, [r15] mov rsi, rbx mov rdx, r14 call _bcmp test eax, eax jz short loc_B446F loc_B4464: add r15, 70h ; 'p' cmp r15, r12 jnz short loc_B4444 loc_B446D: xor ebp, ebp loc_B446F: mov eax, ebp pop rbx pop r12 pop r14 pop r15 pop rbp retn
long long minja::ArgumentsValue::has_named(long long a1, long long *a2) { unsigned int v2; // ebp _QWORD *v3; // r15 _QWORD *v4; // r12 long long v5; // rbx long long v6; // r14 v3 = *(_QWORD **)(a1 + 24); v4 = *(_QWORD **)(a1 + 32); if ( v3 == v4 ) { return 0; } else { v5 = *a2; v6 = a2[1]; while ( 1 ) { if ( v3[1] == v6 ) { LOBYTE(v2) = 1; if ( !v6 || !(unsigned int)bcmp(*v3, v5) ) break; } v3 += 14; if ( v3 == v4 ) return 0; } } return v2; }
has_named: PUSH RBP PUSH R15 PUSH R14 PUSH R12 PUSH RBX MOV R15,qword ptr [RDI + 0x18] MOV R12,qword ptr [RDI + 0x20] CMP R15,R12 JZ 0x001b446d MOV RBX,qword ptr [RSI] MOV R14,qword ptr [RSI + 0x8] LAB_001b4444: CMP qword ptr [R15 + 0x8],R14 JNZ 0x001b4464 MOV BPL,0x1 TEST R14,R14 JZ 0x001b446f MOV RDI,qword ptr [R15] MOV RSI,RBX MOV RDX,R14 CALL 0x0011a920 TEST EAX,EAX JZ 0x001b446f LAB_001b4464: ADD R15,0x70 CMP R15,R12 JNZ 0x001b4444 LAB_001b446d: XOR EBP,EBP LAB_001b446f: MOV EAX,EBP POP RBX POP R12 POP R14 POP R15 POP RBP RET
/* minja::ArgumentsValue::has_named(std::__cxx11::string const&) */ ulong __thiscall minja::ArgumentsValue::has_named(ArgumentsValue *this,string *param_1) { int8 *puVar1; void *__s2; size_t __n; int iVar2; ulong unaff_RBP; int8 *puVar3; puVar3 = *(int8 **)(this + 0x18); puVar1 = *(int8 **)(this + 0x20); if (puVar3 != puVar1) { __s2 = *(void **)param_1; __n = *(size_t *)(param_1 + 8); do { if (puVar3[1] == __n) { unaff_RBP = CONCAT71((int7)(unaff_RBP >> 8),1); if (__n == 0) goto LAB_001b446f; iVar2 = bcmp((void *)*puVar3,__s2,__n); if (iVar2 == 0) goto LAB_001b446f; } puVar3 = puVar3 + 0xe; } while (puVar3 != puVar1); } unaff_RBP = 0; LAB_001b446f: return unaff_RBP & 0xffffffff; }
20,572
ggml_set_zero
ngxson[P]ggml-easy/ggml/src/ggml.c
struct ggml_tensor * ggml_set_zero(struct ggml_tensor * tensor) { if (ggml_is_empty(tensor)) { return tensor; } if (tensor->buffer) { ggml_backend_tensor_memset(tensor, 0, 0, ggml_nbytes(tensor)); } else { GGML_ASSERT(tensor->data); memset(tensor->data, 0, ggml_nbytes(tensor)); } return tensor; }
O2
c
ggml_set_zero: pushq %r14 pushq %rbx pushq %rax movq %rdi, %rbx callq 0x1c0b0 testb %al, %al jne 0x27754 cmpq $0x0, 0x8(%rbx) je 0x27733 movq %rbx, %rdi callq 0x1c2d0 movq %rbx, %rdi xorl %esi, %esi xorl %edx, %edx movq %rax, %rcx callq 0x1e2e0 jmp 0x27754 movq 0xf8(%rbx), %r14 testq %r14, %r14 je 0x2775f movq %rbx, %rdi callq 0x1c2d0 movq %r14, %rdi xorl %esi, %esi movq %rax, %rdx callq 0x1cc30 movq %rbx, %rax addq $0x8, %rsp popq %rbx popq %r14 retq leaq 0x23e1d(%rip), %rdi # 0x4b583 leaq 0x23e61(%rip), %rdx # 0x4b5ce leaq 0x2504a(%rip), %rcx # 0x4c7be movl $0x17b5, %esi # imm = 0x17B5 xorl %eax, %eax callq 0x1e770
ggml_set_zero: push r14 push rbx push rax mov rbx, rdi call _ggml_is_empty test al, al jnz short loc_27754 cmp qword ptr [rbx+8], 0 jz short loc_27733 mov rdi, rbx call _ggml_nbytes mov rdi, rbx xor esi, esi xor edx, edx mov rcx, rax call _ggml_backend_tensor_memset jmp short loc_27754 loc_27733: mov r14, [rbx+0F8h] test r14, r14 jz short loc_2775F mov rdi, rbx call _ggml_nbytes mov rdi, r14 xor esi, esi mov rdx, rax call _memset loc_27754: mov rax, rbx add rsp, 8 pop rbx pop r14 retn loc_2775F: lea rdi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aTensorData; "tensor->data" mov esi, 17B5h xor eax, eax call _ggml_abort
long long ggml_set_zero( long long a1, __m128 a2, __m128 a3, __m128 a4, __m128 a5, double a6, double a7, __m128 a8, __m128 a9) { char v9; // al long long v10; // r8 long long v11; // r9 __m128 v12; // xmm4 __m128 v13; // xmm5 unsigned long long v14; // rax long long v15; // r14 unsigned long long v16; // rax char v18; // [rsp-8h] [rbp-18h] v18 = v9; if ( !ggml_is_empty(a1) ) { if ( *(_QWORD *)(a1 + 8) ) { v14 = ggml_nbytes((unsigned int *)a1); ggml_backend_tensor_memset(a1, 0LL, 0LL, v14); } else { v15 = *(_QWORD *)(a1 + 248); if ( !v15 ) ggml_abort( "/workspace/llm4binary/github/2025_star3/ngxson[P]ggml-easy/ggml/src/ggml.c", 6069, (long long)"GGML_ASSERT(%s) failed", (long long)"tensor->data", v10, v11, a2, a3, a4, a5, v12, v13, a8, a9, v18); v16 = ggml_nbytes((unsigned int *)a1); memset(v15, 0LL, v16); } } return a1; }
ggml_set_zero: PUSH R14 PUSH RBX PUSH RAX MOV RBX,RDI CALL 0x0011c0b0 TEST AL,AL JNZ 0x00127754 CMP qword ptr [RBX + 0x8],0x0 JZ 0x00127733 MOV RDI,RBX CALL 0x0011c2d0 MOV RDI,RBX XOR ESI,ESI XOR EDX,EDX MOV RCX,RAX CALL 0x0011e2e0 JMP 0x00127754 LAB_00127733: MOV R14,qword ptr [RBX + 0xf8] TEST R14,R14 JZ 0x0012775f MOV RDI,RBX CALL 0x0011c2d0 MOV RDI,R14 XOR ESI,ESI MOV RDX,RAX CALL 0x0011cc30 LAB_00127754: MOV RAX,RBX ADD RSP,0x8 POP RBX POP R14 RET LAB_0012775f: LEA RDI,[0x14b583] LEA RDX,[0x14b5ce] LEA RCX,[0x14c7be] MOV ESI,0x17b5 XOR EAX,EAX CALL 0x0011e770
long ggml_set_zero(long param_1) { void *__s; char cVar1; int8 uVar2; size_t __n; cVar1 = ggml_is_empty(); if (cVar1 == '\0') { if (*(long *)(param_1 + 8) == 0) { __s = *(void **)(param_1 + 0xf8); if (__s == (void *)0x0) { /* WARNING: Subroutine does not return */ ggml_abort("/workspace/llm4binary/github/2025_star3/ngxson[P]ggml-easy/ggml/src/ggml.c", 0x17b5,"GGML_ASSERT(%s) failed","tensor->data"); } __n = ggml_nbytes(param_1); memset(__s,0,__n); } else { uVar2 = ggml_nbytes(param_1); ggml_backend_tensor_memset(param_1,0,0,uVar2); } } return param_1; }
20,573
ggml_set_zero
ngxson[P]ggml-easy/ggml/src/ggml.c
struct ggml_tensor * ggml_set_zero(struct ggml_tensor * tensor) { if (ggml_is_empty(tensor)) { return tensor; } if (tensor->buffer) { ggml_backend_tensor_memset(tensor, 0, 0, ggml_nbytes(tensor)); } else { GGML_ASSERT(tensor->data); memset(tensor->data, 0, ggml_nbytes(tensor)); } return tensor; }
O3
c
ggml_set_zero: pushq %r14 pushq %rbx pushq %rax movq %rdi, %rbx cmpq $0x0, 0x10(%rdi) je 0x22443 movl $0x3, %eax cmpq $0x6, %rax je 0x22402 leaq 0x1(%rax), %rcx cmpq $0x0, (%rbx,%rax,8) movq %rcx, %rax jne 0x223e4 addq $-0x4, %rcx cmpq $0x3, %rcx jb 0x22443 cmpq $0x0, 0x8(%rbx) je 0x22422 movq %rbx, %rdi callq 0x161c0 movq %rbx, %rdi xorl %esi, %esi xorl %edx, %edx movq %rax, %rcx callq 0x17920 jmp 0x22443 movq 0xf8(%rbx), %r14 testq %r14, %r14 je 0x2244e movq %rbx, %rdi callq 0x161c0 movq %r14, %rdi xorl %esi, %esi movq %rax, %rdx callq 0x168e0 movq %rbx, %rax addq $0x8, %rsp popq %rbx popq %r14 retq leaq 0x281be(%rip), %rdi # 0x4a613 leaq 0x28202(%rip), %rdx # 0x4a65e leaq 0x293eb(%rip), %rcx # 0x4b84e movl $0x17b5, %esi # imm = 0x17B5 xorl %eax, %eax callq 0x17c60
ggml_set_zero: push r14 push rbx push rax mov rbx, rdi cmp qword ptr [rdi+10h], 0 jz short loc_22443 mov eax, 3 loc_223E4: cmp rax, 6 jz short loc_22402 lea rcx, [rax+1] cmp qword ptr [rbx+rax*8], 0 mov rax, rcx jnz short loc_223E4 add rcx, 0FFFFFFFFFFFFFFFCh cmp rcx, 3 jb short loc_22443 loc_22402: cmp qword ptr [rbx+8], 0 jz short loc_22422 mov rdi, rbx call _ggml_nbytes mov rdi, rbx xor esi, esi xor edx, edx mov rcx, rax call _ggml_backend_tensor_memset jmp short loc_22443 loc_22422: mov r14, [rbx+0F8h] test r14, r14 jz short loc_2244E mov rdi, rbx call _ggml_nbytes mov rdi, r14 xor esi, esi mov rdx, rax call _memset loc_22443: mov rax, rbx add rsp, 8 pop rbx pop r14 retn loc_2244E: lea rdi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aTensorData; "tensor->data" mov esi, 17B5h xor eax, eax call _ggml_abort
long long ggml_set_zero(long long a1, long long a2, long long a3, long long a4, int a5, int a6) { long long v6; // rax long long v7; // rcx unsigned long long v9; // rax long long v10; // r14 unsigned long long v11; // rax if ( *(_QWORD *)(a1 + 16) ) { v6 = 3LL; while ( v6 != 6 ) { v7 = v6 + 1; if ( *(_QWORD *)(a1 + 8 * v6++) == 0LL ) { if ( (unsigned long long)(v7 - 4) < 3 ) return a1; break; } } if ( *(_QWORD *)(a1 + 8) ) { v9 = ggml_nbytes((unsigned int *)a1); ggml_backend_tensor_memset(a1, 0LL, 0LL, v9); } else { v10 = *(_QWORD *)(a1 + 248); if ( !v10 ) ggml_abort( (unsigned int)"/workspace/llm4binary/github/2025_star3/ngxson[P]ggml-easy/ggml/src/ggml.c", 6069, (unsigned int)"GGML_ASSERT(%s) failed", (unsigned int)"tensor->data", a5, a6); v11 = ggml_nbytes((unsigned int *)a1); memset(v10, 0LL, v11); } } return a1; }
ggml_set_zero: PUSH R14 PUSH RBX PUSH RAX MOV RBX,RDI CMP qword ptr [RDI + 0x10],0x0 JZ 0x00122443 MOV EAX,0x3 LAB_001223e4: CMP RAX,0x6 JZ 0x00122402 LEA RCX,[RAX + 0x1] CMP qword ptr [RBX + RAX*0x8],0x0 MOV RAX,RCX JNZ 0x001223e4 ADD RCX,-0x4 CMP RCX,0x3 JC 0x00122443 LAB_00122402: CMP qword ptr [RBX + 0x8],0x0 JZ 0x00122422 MOV RDI,RBX CALL 0x001161c0 MOV RDI,RBX XOR ESI,ESI XOR EDX,EDX MOV RCX,RAX CALL 0x00117920 JMP 0x00122443 LAB_00122422: MOV R14,qword ptr [RBX + 0xf8] TEST R14,R14 JZ 0x0012244e MOV RDI,RBX CALL 0x001161c0 MOV RDI,R14 XOR ESI,ESI MOV RDX,RAX CALL 0x001168e0 LAB_00122443: MOV RAX,RBX ADD RSP,0x8 POP RBX POP R14 RET LAB_0012244e: LEA RDI,[0x14a613] LEA RDX,[0x14a65e] LEA RCX,[0x14b84e] MOV ESI,0x17b5 XOR EAX,EAX CALL 0x00117c60
long ggml_set_zero(long param_1) { void *__s; long lVar1; long lVar2; int8 uVar3; size_t __n; if (*(long *)(param_1 + 0x10) != 0) { lVar1 = 3; do { lVar2 = lVar1; if (lVar2 == 6) goto LAB_00122402; lVar1 = lVar2 + 1; } while (*(long *)(param_1 + lVar2 * 8) != 0); if (2 < lVar2 - 3U) { LAB_00122402: if (*(long *)(param_1 + 8) == 0) { __s = *(void **)(param_1 + 0xf8); if (__s == (void *)0x0) { /* WARNING: Subroutine does not return */ ggml_abort("/workspace/llm4binary/github/2025_star3/ngxson[P]ggml-easy/ggml/src/ggml.c", 0x17b5,"GGML_ASSERT(%s) failed","tensor->data"); } __n = ggml_nbytes(param_1); memset(__s,0,__n); } else { uVar3 = ggml_nbytes(param_1); ggml_backend_tensor_memset(param_1,0,0,uVar3); } } } return param_1; }
20,574
get_block
corpus-core[P]colibri-stateless/src/chains/eth/proofer/beacon.c
static c4_status_t get_block(proofer_ctx_t* ctx, beacon_head_t* b, ssz_ob_t* block) { bytes_t block_data; char path[200]; buffer_t buffer = stack_buffer(path); bool has_hash = b && !bytes_all_zero(bytes(b->root, 32)); uint32_t ttl = 6; // 6s for head-requests if (!b || (b->slot == 0 && !has_hash)) buffer_add_chars(&buffer, "eth/v2/beacon/blocks/head"); else if (has_hash) { bprintf(&buffer, "eth/v2/beacon/blocks/0x%x", bytes(b->root, 32)); ttl = DEFAULT_TTL; } else bprintf(&buffer, "eth/v2/beacon/blocks/%l", b->slot); TRY_ASYNC(c4_send_beacon_ssz(ctx, path, NULL, eth_ssz_type_for_fork(ETH_SSZ_SIGNED_BEACON_BLOCK_CONTAINER, C4_FORK_DENEB), ttl, block)); *block = ssz_get(block, "message"); return C4_SUCCESS; }
O1
c
get_block: pushq %rbp pushq %r15 pushq %r14 pushq %rbx subq $0xf8, %rsp movq %rdx, %rbx movq %rsi, %r15 movq %rdi, %r14 movl $0x0, (%rsp) leaq 0x30(%rsp), %rax movq %rax, 0x8(%rsp) movl $0xffffff38, 0x10(%rsp) # imm = 0xFFFFFF38 testq %rsi, %rsi je 0x98b7 leaq 0x8(%r15), %rsi movl $0x20, %edi xorl %edx, %edx callq 0x12ad9 xorb $0x1, %al jmp 0x98b9 xorl %eax, %eax testq %r15, %r15 je 0x98fa movq (%r15), %rdx testq %rdx, %rdx setne %cl orb %al, %cl testb $0x1, %cl je 0x98fa testb %al, %al je 0x996f addq $0x8, %r15 leaq 0x33ffe(%rip), %rsi # 0x3d8df movq %rsp, %rdi movl $0x20, %edx movq %r15, %rcx xorl %eax, %eax callq 0x13095 movl $0x15180, %ebp # imm = 0x15180 jmp 0x990e leaq 0x33fc4(%rip), %rsi # 0x3d8c5 movq %rsp, %rdi callq 0x12cc5 movl $0x6, %ebp movl $0x1, %edi movl $0x4, %esi callq 0x115dc leaq 0x30(%rsp), %rsi movq %r14, %rdi xorl %edx, %edx movq %rax, %rcx movl %ebp, %r8d movq %rbx, %r9 callq 0x9f13 testl %eax, %eax jne 0x9961 leaq 0x33f6d(%rip), %rdx # 0x3d8ad leaq 0x18(%rsp), %r14 movq %r14, %rdi movq %rbx, %rsi callq 0x14ddd movq 0x10(%r14), %rax movq %rax, 0x10(%rbx) movups (%r14), %xmm0 movups %xmm0, (%rbx) xorl %eax, %eax addq $0xf8, %rsp popq %rbx popq %r14 popq %r15 popq %rbp retq leaq 0x33f83(%rip), %rsi # 0x3d8f9 movq %rsp, %rdi xorl %eax, %eax callq 0x13095 jmp 0x9909
get_block: push rbp push r15 push r14 push rbx sub rsp, 0F8h mov rbx, rdx mov r15, rsi mov r14, rdi mov [rsp+118h+var_118], 0 lea rax, [rsp+118h+var_E8] mov [rsp+118h+var_110], rax mov [rsp+118h+var_108], 0FFFFFF38h test rsi, rsi jz short loc_98B7 lea rsi, [r15+8] mov edi, 20h ; ' ' xor edx, edx call bytes_all_equal xor al, 1 jmp short loc_98B9 loc_98B7: xor eax, eax loc_98B9: test r15, r15 jz short loc_98FA mov rdx, [r15] test rdx, rdx setnz cl or cl, al test cl, 1 jz short loc_98FA test al, al jz loc_996F add r15, 8 lea rsi, aEthV2BeaconBlo; "eth/v2/beacon/blocks/0x%x" mov rdi, rsp mov edx, 20h ; ' ' mov rcx, r15 xor eax, eax call bprintf mov ebp, 15180h jmp short loc_990E loc_98FA: lea rsi, aEthV2BeaconBlo_0; "eth/v2/beacon/blocks/head" mov rdi, rsp call buffer_add_chars loc_9909: mov ebp, 6 loc_990E: mov edi, 1 mov esi, 4 call eth_ssz_type_for_fork lea rsi, [rsp+118h+var_E8] mov rdi, r14 xor edx, edx mov rcx, rax mov r8d, ebp mov r9, rbx call c4_send_beacon_ssz test eax, eax jnz short loc_9961 lea rdx, aMessage; "message" lea r14, [rsp+118h+var_100] mov rdi, r14 mov rsi, rbx call ssz_get mov rax, [r14+10h] mov [rbx+10h], rax movups xmm0, xmmword ptr [r14] movups xmmword ptr [rbx], xmm0 xor eax, eax loc_9961: add rsp, 0F8h pop rbx pop r14 pop r15 pop rbp retn loc_996F: lea rsi, aEthV2BeaconBlo_1; "eth/v2/beacon/blocks/%l" mov rdi, rsp xor eax, eax call bprintf jmp short loc_9909
long long get_block(long long a1, long long *a2, long long a3, long long a4, int a5, int a6) { long long v6; // rbx char v7; // al unsigned int v8; // ebp long long v9; // rax long long result; // rax long long v11; // [rsp+0h] [rbp-118h] BYREF _BYTE *v12; // [rsp+8h] [rbp-110h] long long v13; // [rsp+10h] [rbp-108h] __int128 v14; // [rsp+18h] [rbp-100h] BYREF long long v15; // [rsp+28h] [rbp-F0h] _BYTE v16[232]; // [rsp+30h] [rbp-E8h] BYREF v6 = a3; LODWORD(v11) = 0; v12 = v16; LODWORD(v13) = -200; if ( a2 ) v7 = bytes_all_equal(32LL, a2 + 1, 0LL) ^ 1; else v7 = 0; if ( a2 && (a3 = *a2, v7 & 1 | (*a2 != 0)) ) { if ( v7 ) { bprintf((unsigned int)&v11, (unsigned int)"eth/v2/beacon/blocks/0x%x", 32, (_BYTE)a2 + 8, a5, a6, v11, v12, v13); v8 = 86400; goto LABEL_10; } bprintf((unsigned int)&v11, (unsigned int)"eth/v2/beacon/blocks/%l", a3, *a2 != 0, a5, a6, v11, v12, v13); } else { buffer_add_chars(&v11, "eth/v2/beacon/blocks/head", a3); } v8 = 6; LABEL_10: v9 = eth_ssz_type_for_fork(1LL, 4LL); result = c4_send_beacon_ssz(a1, v16, 0LL, v9, v8, v6); if ( !(_DWORD)result ) { ssz_get(&v14, v6, "message"); *(_QWORD *)(v6 + 16) = v15; *(_OWORD *)v6 = v14; return 0LL; } return result; }
get_block: PUSH RBP PUSH R15 PUSH R14 PUSH RBX SUB RSP,0xf8 MOV RBX,RDX MOV R15,RSI MOV R14,RDI MOV dword ptr [RSP],0x0 LEA RAX,[RSP + 0x30] MOV qword ptr [RSP + 0x8],RAX MOV dword ptr [RSP + 0x10],0xffffff38 TEST RSI,RSI JZ 0x001098b7 LEA RSI,[R15 + 0x8] MOV EDI,0x20 XOR EDX,EDX CALL 0x00112ad9 XOR AL,0x1 JMP 0x001098b9 LAB_001098b7: XOR EAX,EAX LAB_001098b9: TEST R15,R15 JZ 0x001098fa MOV RDX,qword ptr [R15] TEST RDX,RDX SETNZ CL OR CL,AL TEST CL,0x1 JZ 0x001098fa TEST AL,AL JZ 0x0010996f ADD R15,0x8 LEA RSI,[0x13d8df] MOV RDI,RSP MOV EDX,0x20 MOV RCX,R15 XOR EAX,EAX CALL 0x00113095 MOV EBP,0x15180 JMP 0x0010990e LAB_001098fa: LEA RSI,[0x13d8c5] MOV RDI,RSP CALL 0x00112cc5 LAB_00109909: MOV EBP,0x6 LAB_0010990e: MOV EDI,0x1 MOV ESI,0x4 CALL 0x001115dc LEA RSI,[RSP + 0x30] MOV RDI,R14 XOR EDX,EDX MOV RCX,RAX MOV R8D,EBP MOV R9,RBX CALL 0x00109f13 TEST EAX,EAX JNZ 0x00109961 LEA RDX,[0x13d8ad] LEA R14,[RSP + 0x18] MOV RDI,R14 MOV RSI,RBX CALL 0x00114ddd MOV RAX,qword ptr [R14 + 0x10] MOV qword ptr [RBX + 0x10],RAX MOVUPS XMM0,xmmword ptr [R14] MOVUPS xmmword ptr [RBX],XMM0 XOR EAX,EAX LAB_00109961: ADD RSP,0xf8 POP RBX POP R14 POP R15 POP RBP RET LAB_0010996f: LEA RSI,[0x13d8f9] MOV RDI,RSP XOR EAX,EAX CALL 0x00113095 JMP 0x00109909
int8 get_block(int8 param_1,long *param_2,int8 *param_3) { byte bVar1; int8 uVar2; int4 uVar3; int4 local_118 [2]; int1 *local_110; int4 local_108; int8 local_100; int8 uStack_f8; int8 local_f0; int1 local_e8 [200]; local_118[0] = 0; local_110 = local_e8; local_108 = 0xffffff38; if (param_2 == (long *)0x0) { LAB_001098fa: buffer_add_chars(local_118,"eth/v2/beacon/blocks/head"); } else { bVar1 = bytes_all_equal(0x20,param_2 + 1,0); if (*param_2 == 0 && ((bVar1 ^ 1) & 1) == 0) goto LAB_001098fa; if ((bVar1 ^ 1) != 0) { bprintf(local_118,"eth/v2/beacon/blocks/0x%x",0x20,param_2 + 1); uVar3 = 0x15180; goto LAB_0010990e; } bprintf(local_118,"eth/v2/beacon/blocks/%l"); } uVar3 = 6; LAB_0010990e: uVar2 = eth_ssz_type_for_fork(1,4); uVar2 = c4_send_beacon_ssz(param_1,local_e8,0,uVar2,uVar3,param_3); if ((int)uVar2 == 0) { ssz_get(&local_100,param_3,"message"); param_3[2] = local_f0; *param_3 = local_100; param_3[1] = uStack_f8; uVar2 = 0; } return uVar2; }
20,575
get_block
corpus-core[P]colibri-stateless/src/chains/eth/proofer/beacon.c
static c4_status_t get_block(proofer_ctx_t* ctx, beacon_head_t* b, ssz_ob_t* block) { bytes_t block_data; char path[200]; buffer_t buffer = stack_buffer(path); bool has_hash = b && !bytes_all_zero(bytes(b->root, 32)); uint32_t ttl = 6; // 6s for head-requests if (!b || (b->slot == 0 && !has_hash)) buffer_add_chars(&buffer, "eth/v2/beacon/blocks/head"); else if (has_hash) { bprintf(&buffer, "eth/v2/beacon/blocks/0x%x", bytes(b->root, 32)); ttl = DEFAULT_TTL; } else bprintf(&buffer, "eth/v2/beacon/blocks/%l", b->slot); TRY_ASYNC(c4_send_beacon_ssz(ctx, path, NULL, eth_ssz_type_for_fork(ETH_SSZ_SIGNED_BEACON_BLOCK_CONTAINER, C4_FORK_DENEB), ttl, block)); *block = ssz_get(block, "message"); return C4_SUCCESS; }
O3
c
get_block: pushq %rbp pushq %r15 pushq %r14 pushq %r12 pushq %rbx subq $0x100, %rsp # imm = 0x100 movq %rdx, %rbx movq %rdi, %r14 movl $0x0, (%rsp) leaq 0x30(%rsp), %rax movq %rax, 0x8(%rsp) movl $0xffffff38, 0x10(%rsp) # imm = 0xFFFFFF38 testq %rsi, %rsi je 0x9799 movq %rsi, %r12 leaq 0x8(%rsi), %r15 movl $0x20, %edi movq %r15, %rsi xorl %edx, %edx callq 0x127d9 movq (%r12), %rdx testq %rdx, %rdx sete %cl andb %al, %cl cmpb $0x1, %cl jne 0x9812 leaq 0x34125(%rip), %rsi # 0x3d8c5 movq %rsp, %rdi callq 0x129cf movl $0x6, %ebp movl $0x1, %edi movl $0x4, %esi callq 0x11334 leaq 0x30(%rsp), %rsi movq %r14, %rdi xorl %edx, %edx movq %rax, %rcx movl %ebp, %r8d movq %rbx, %r9 callq 0x9dc3 movl %eax, %ebp testl %eax, %eax jne 0x9800 leaq 0x340cc(%rip), %rdx # 0x3d8ad leaq 0x18(%rsp), %r14 movq %r14, %rdi movq %rbx, %rsi callq 0x14885 movq 0x10(%r14), %rax movq %rax, 0x10(%rbx) movups (%r14), %xmm0 movups %xmm0, (%rbx) movl %ebp, %eax addq $0x100, %rsp # imm = 0x100 popq %rbx popq %r12 popq %r14 popq %r15 popq %rbp retq testb $0x1, %al je 0x982c leaq 0x340dc(%rip), %rsi # 0x3d8f9 movq %rsp, %rdi xorl %eax, %eax callq 0x12da8 jmp 0x97a8 leaq 0x340ac(%rip), %rsi # 0x3d8df movq %rsp, %rdi movl $0x20, %edx movq %r15, %rcx xorl %eax, %eax callq 0x12da8 movl $0x15180, %ebp # imm = 0x15180 jmp 0x97ad
get_block: push rbp push r15 push r14 push r12 push rbx sub rsp, 100h mov rbx, rdx mov r14, rdi mov [rsp+128h+var_128], 0 lea rax, [rsp+128h+var_F8] mov [rsp+128h+var_120], rax mov [rsp+128h+var_118], 0FFFFFF38h test rsi, rsi jz short loc_9799 mov r12, rsi lea r15, [rsi+8] mov edi, 20h ; ' ' mov rsi, r15 xor edx, edx call bytes_all_equal mov rdx, [r12] test rdx, rdx setz cl and cl, al cmp cl, 1 jnz short loc_9812 loc_9799: lea rsi, aEthV2BeaconBlo; "eth/v2/beacon/blocks/head" mov rdi, rsp call buffer_add_chars loc_97A8: mov ebp, 6 loc_97AD: mov edi, 1 mov esi, 4 call eth_ssz_type_for_fork lea rsi, [rsp+128h+var_F8] mov rdi, r14 xor edx, edx mov rcx, rax mov r8d, ebp mov r9, rbx call c4_send_beacon_ssz mov ebp, eax test eax, eax jnz short loc_9800 lea rdx, aMessage; "message" lea r14, [rsp+128h+var_110] mov rdi, r14 mov rsi, rbx call ssz_get mov rax, [r14+10h] mov [rbx+10h], rax movups xmm0, xmmword ptr [r14] movups xmmword ptr [rbx], xmm0 loc_9800: mov eax, ebp add rsp, 100h pop rbx pop r12 pop r14 pop r15 pop rbp retn loc_9812: test al, 1 jz short loc_982C lea rsi, aEthV2BeaconBlo_0; "eth/v2/beacon/blocks/%l" mov rdi, rsp xor eax, eax call bprintf jmp loc_97A8 loc_982C: lea rsi, aEthV2BeaconBlo_1; "eth/v2/beacon/blocks/0x%x" mov rdi, rsp mov edx, 20h ; ' ' mov rcx, r15 xor eax, eax call bprintf mov ebp, offset loc_15180 jmp loc_97AD
long long get_block(long long a1, long long *a2, long long a3) { long long v3; // rbx char v4; // al int v5; // r8d int v6; // r9d int v7; // ecx void *v8; // rbp long long v9; // rax unsigned int v10; // ebp long long v12; // [rsp+0h] [rbp-128h] BYREF _BYTE *v13; // [rsp+8h] [rbp-120h] long long v14; // [rsp+10h] [rbp-118h] __int128 v15; // [rsp+18h] [rbp-110h] BYREF long long v16; // [rsp+28h] [rbp-100h] _BYTE v17[248]; // [rsp+30h] [rbp-F8h] BYREF v3 = a3; LODWORD(v12) = 0; v13 = v17; LODWORD(v14) = -200; if ( !a2 || (v4 = bytes_all_equal(32LL, a2 + 1, 0LL), a3 = *a2, LOBYTE(v7) = v4 & (*a2 == 0), (_BYTE)v7 == 1) ) { buffer_add_chars(&v12, "eth/v2/beacon/blocks/head", a3); LABEL_4: LODWORD(v8) = 6; goto LABEL_5; } if ( (v4 & 1) != 0 ) { bprintf((unsigned int)&v12, (unsigned int)"eth/v2/beacon/blocks/%l", a3, v7, v5, v6, v12, v13, v14); goto LABEL_4; } bprintf((unsigned int)&v12, (unsigned int)"eth/v2/beacon/blocks/0x%x", 32, (_DWORD)a2 + 8, v5, v6, v12, v13, v14); v8 = &loc_15180; LABEL_5: v9 = eth_ssz_type_for_fork(1LL, 4LL); v10 = c4_send_beacon_ssz(a1, v17, 0LL, v9, (unsigned int)v8, v3); if ( !v10 ) { ssz_get(&v15, v3, "message"); *(_QWORD *)(v3 + 16) = v16; *(_OWORD *)v3 = v15; } return v10; }
get_block: PUSH RBP PUSH R15 PUSH R14 PUSH R12 PUSH RBX SUB RSP,0x100 MOV RBX,RDX MOV R14,RDI MOV dword ptr [RSP],0x0 LEA RAX,[RSP + 0x30] MOV qword ptr [RSP + 0x8],RAX MOV dword ptr [RSP + 0x10],0xffffff38 TEST RSI,RSI JZ 0x00109799 MOV R12,RSI LEA R15,[RSI + 0x8] MOV EDI,0x20 MOV RSI,R15 XOR EDX,EDX CALL 0x001127d9 MOV RDX,qword ptr [R12] TEST RDX,RDX SETZ CL AND CL,AL CMP CL,0x1 JNZ 0x00109812 LAB_00109799: LEA RSI,[0x13d8c5] MOV RDI,RSP CALL 0x001129cf LAB_001097a8: MOV EBP,0x6 LAB_001097ad: MOV EDI,0x1 MOV ESI,0x4 CALL 0x00111334 LEA RSI,[RSP + 0x30] MOV RDI,R14 XOR EDX,EDX MOV RCX,RAX MOV R8D,EBP MOV R9,RBX CALL 0x00109dc3 MOV EBP,EAX TEST EAX,EAX JNZ 0x00109800 LEA RDX,[0x13d8ad] LEA R14,[RSP + 0x18] MOV RDI,R14 MOV RSI,RBX CALL 0x00114885 MOV RAX,qword ptr [R14 + 0x10] MOV qword ptr [RBX + 0x10],RAX MOVUPS XMM0,xmmword ptr [R14] MOVUPS xmmword ptr [RBX],XMM0 LAB_00109800: MOV EAX,EBP ADD RSP,0x100 POP RBX POP R12 POP R14 POP R15 POP RBP RET LAB_00109812: TEST AL,0x1 JZ 0x0010982c LEA RSI,[0x13d8f9] MOV RDI,RSP XOR EAX,EAX CALL 0x00112da8 JMP 0x001097a8 LAB_0010982c: LEA RSI,[0x13d8df] MOV RDI,RSP MOV EDX,0x20 MOV RCX,R15 XOR EAX,EAX CALL 0x00112da8 MOV EBP,0x15180 JMP 0x001097ad
int get_block(int8 param_1,long *param_2,int8 *param_3) { byte bVar1; int iVar2; int8 uVar3; int4 uVar4; int4 local_128 [2]; int1 *local_120; int4 local_118; int8 local_110; int8 uStack_108; int8 local_100; int1 local_f8 [208]; local_128[0] = 0; local_120 = local_f8; local_118 = 0xffffff38; if (param_2 == (long *)0x0) { LAB_00109799: buffer_add_chars(local_128,"eth/v2/beacon/blocks/head"); } else { bVar1 = bytes_all_equal(0x20,param_2 + 1,0); if ((*param_2 == 0 & bVar1) == 1) goto LAB_00109799; if ((bVar1 & 1) == 0) { bprintf(local_128,"eth/v2/beacon/blocks/0x%x",0x20,param_2 + 1); uVar4 = 0x15180; goto LAB_001097ad; } bprintf(local_128,"eth/v2/beacon/blocks/%l"); } uVar4 = 6; LAB_001097ad: uVar3 = eth_ssz_type_for_fork(1,4); iVar2 = c4_send_beacon_ssz(param_1,local_f8,0,uVar3,uVar4,param_3); if (iVar2 == 0) { ssz_get(&local_110,param_3,"message"); param_3[2] = local_100; *param_3 = local_110; param_3[1] = uStack_108; } return iVar2; }
20,576
QuaternionMultiply
csit-sgu[P]mit-game-2025_1/Libraries/raylib/src/raymath.h
RMAPI Quaternion QuaternionMultiply(Quaternion q1, Quaternion q2) { Quaternion result = { 0 }; float qax = q1.x, qay = q1.y, qaz = q1.z, qaw = q1.w; float qbx = q2.x, qby = q2.y, qbz = q2.z, qbw = q2.w; result.x = qax*qbw + qaw*qbx + qay*qbz - qaz*qby; result.y = qay*qbw + qaw*qby + qaz*qbx - qax*qbz; result.z = qaz*qbw + qaw*qbz + qax*qby - qay*qbx; result.w = qaw*qbw - qax*qbx - qay*qby - qaz*qbz; return result; }
O2
c
QuaternionMultiply: movaps %xmm0, %xmm4 movaps 0x5bc60(%rip), %xmm5 # 0xb5140 movaps %xmm1, %xmm0 xorps %xmm5, %xmm0 movaps %xmm2, %xmm6 shufps $0x10, %xmm1, %xmm6 # xmm6 = xmm6[0,0],xmm1[1,0] movaps %xmm1, %xmm7 shufps $0x25, %xmm6, %xmm7 # xmm7 = xmm7[1,1],xmm6[2,0] xorps %xmm4, %xmm5 movaps %xmm5, %xmm8 movlhps %xmm3, %xmm8 # xmm8 = xmm8[0],xmm3[0] movaps %xmm2, %xmm6 shufps $0x24, %xmm8, %xmm6 # xmm6 = xmm6[0,1],xmm8[2,0] mulps %xmm7, %xmm6 movaps %xmm4, %xmm7 movlhps %xmm1, %xmm7 # xmm7 = xmm7[0],xmm1[0] shufps $0x10, %xmm4, %xmm1 # xmm1 = xmm1[0,0],xmm4[1,0] shufps $0x40, %xmm5, %xmm0 # xmm0 = xmm0[0,0],xmm5[0,1] shufps $0x55, %xmm2, %xmm5 # xmm5 = xmm5[1,1],xmm2[1,1] movaps %xmm3, %xmm8 unpcklps %xmm2, %xmm8 # xmm8 = xmm8[0],xmm2[0],xmm8[1],xmm2[1] shufps $0xd4, %xmm2, %xmm4 # xmm4 = xmm4[0,1],xmm2[1,3] shufps $0x1, %xmm3, %xmm2 # xmm2 = xmm2[1,0],xmm3[0,0] shufps $0x55, %xmm3, %xmm3 # xmm3 = xmm3[1,1,1,1] mulps %xmm7, %xmm3 addps %xmm6, %xmm3 shufps $0x22, %xmm5, %xmm1 # xmm1 = xmm1[2,0],xmm5[2,0] shufps $0x84, %xmm4, %xmm8 # xmm8 = xmm8[0,1],xmm4[0,2] mulps %xmm1, %xmm8 addps %xmm3, %xmm8 shufps $0x78, %xmm0, %xmm0 # xmm0 = xmm0[0,2,3,1] shufps $0xd8, %xmm2, %xmm2 # xmm2 = xmm2[0,2,1,3] mulps %xmm2, %xmm0 addps %xmm8, %xmm0 movaps %xmm0, %xmm1 unpckhpd %xmm0, %xmm1 # xmm1 = xmm1[1],xmm0[1] retq
QuaternionMultiply: movaps xmm4, xmm0 movaps xmm5, cs:xmmword_B5140 movaps xmm0, xmm1 xorps xmm0, xmm5 movaps xmm6, xmm2 shufps xmm6, xmm1, 10h movaps xmm7, xmm1 shufps xmm7, xmm6, 25h ; '%' xorps xmm5, xmm4 movaps xmm8, xmm5 movlhps xmm8, xmm3 movaps xmm6, xmm2 shufps xmm6, xmm8, 24h ; '$' mulps xmm6, xmm7 movaps xmm7, xmm4 movlhps xmm7, xmm1 shufps xmm1, xmm4, 10h shufps xmm0, xmm5, 40h ; '@' shufps xmm5, xmm2, 55h ; 'U' movaps xmm8, xmm3 unpcklps xmm8, xmm2 shufps xmm4, xmm2, 0D4h shufps xmm2, xmm3, 1 shufps xmm3, xmm3, 55h ; 'U' mulps xmm3, xmm7 addps xmm3, xmm6 shufps xmm1, xmm5, 22h ; '"' shufps xmm8, xmm4, 84h mulps xmm8, xmm1 addps xmm8, xmm3 shufps xmm0, xmm0, 78h ; 'x' shufps xmm2, xmm2, 0D8h mulps xmm0, xmm2 addps xmm0, xmm8 movaps xmm1, xmm0 unpckhpd xmm1, xmm0 retn
__m128 QuaternionMultiply(__m128 a1, __m128 a2, __m128 a3, __m128 a4) { __m128 v5; // xmm0 __m128 v6; // xmm5 __m128 v7; // xmm6 __m128 v8; // xmm7 __m128 v9; // xmm1 __m128 v10; // xmm0 __m128 v11; // xmm5 __m128 v12; // xmm8 __m128 v13; // xmm4 __m128 v14; // xmm2 v5 = _mm_xor_ps(a2, (__m128)xmmword_B5140); v6 = _mm_xor_ps((__m128)xmmword_B5140, a1); v7 = _mm_mul_ps(_mm_shuffle_ps(a3, _mm_movelh_ps(v6, a4), 36), _mm_shuffle_ps(a2, _mm_shuffle_ps(a3, a2, 16), 37)); v8 = _mm_movelh_ps(a1, a2); v9 = _mm_shuffle_ps(a2, a1, 16); v10 = _mm_shuffle_ps(v5, v6, 64); v11 = _mm_shuffle_ps(v6, a3, 85); v12 = _mm_unpacklo_ps(a4, a3); v13 = _mm_shuffle_ps(a1, a3, 212); v14 = _mm_shuffle_ps(a3, a4, 1); return _mm_add_ps( _mm_mul_ps(_mm_shuffle_ps(v10, v10, 120), _mm_shuffle_ps(v14, v14, 216)), _mm_add_ps( _mm_mul_ps(_mm_shuffle_ps(v12, v13, 132), _mm_shuffle_ps(v9, v11, 34)), _mm_add_ps(_mm_mul_ps(_mm_shuffle_ps(a4, a4, 85), v8), v7))); }
QuaternionMultiply: MOVAPS XMM4,XMM0 MOVAPS XMM5,xmmword ptr [0x001b5140] MOVAPS XMM0,XMM1 XORPS XMM0,XMM5 MOVAPS XMM6,XMM2 SHUFPS XMM6,XMM1,0x10 MOVAPS XMM7,XMM1 SHUFPS XMM7,XMM6,0x25 XORPS XMM5,XMM4 MOVAPS XMM8,XMM5 MOVLHPS XMM8,XMM3 MOVAPS XMM6,XMM2 SHUFPS XMM6,XMM8,0x24 MULPS XMM6,XMM7 MOVAPS XMM7,XMM4 MOVLHPS XMM7,XMM1 SHUFPS XMM1,XMM4,0x10 SHUFPS XMM0,XMM5,0x40 SHUFPS XMM5,XMM2,0x55 MOVAPS XMM8,XMM3 UNPCKLPS XMM8,XMM2 SHUFPS XMM4,XMM2,0xd4 SHUFPS XMM2,XMM3,0x1 SHUFPS XMM3,XMM3,0x55 MULPS XMM3,XMM7 ADDPS XMM3,XMM6 SHUFPS XMM1,XMM5,0x22 SHUFPS XMM8,XMM4,0x84 MULPS XMM8,XMM1 ADDPS XMM8,XMM3 SHUFPS XMM0,XMM0,0x78 SHUFPS XMM2,XMM2,0xd8 MULPS XMM0,XMM2 ADDPS XMM0,XMM8 MOVAPS XMM1,XMM0 UNPCKHPD XMM1,XMM0 RET
/* WARNING: Globals starting with '_' overlap smaller symbols at the same address */ int8 QuaternionMultiply(int8 param_1,int8 param_2,int8 param_3,int8 param_4) { float fVar1; float fVar2; float fVar3; float fVar4; fVar4 = (float)((ulong)param_4 >> 0x20); fVar3 = (float)((ulong)param_3 >> 0x20); fVar1 = (float)((ulong)param_1 >> 0x20); fVar2 = (float)((ulong)param_2 >> 0x20); return CONCAT44((float)(_DAT_001b5140 ^ (uint)(float)param_1) * (float)param_4 + (float)param_3 * (float)param_2 + fVar4 * fVar1 + fVar3 * fVar2, (float)((uint)(float)param_2 ^ _DAT_001b5140) * fVar3 + (float)param_4 * fVar1 + fVar4 * (float)param_1 + (float)param_3 * fVar2); }
20,577
QuaternionMultiply
csit-sgu[P]mit-game-2025_1/Libraries/raylib/src/raymath.h
RMAPI Quaternion QuaternionMultiply(Quaternion q1, Quaternion q2) { Quaternion result = { 0 }; float qax = q1.x, qay = q1.y, qaz = q1.z, qaw = q1.w; float qbx = q2.x, qby = q2.y, qbz = q2.z, qbw = q2.w; result.x = qax*qbw + qaw*qbx + qay*qbz - qaz*qby; result.y = qay*qbw + qaw*qby + qaz*qbx - qax*qbz; result.z = qaz*qbw + qaw*qbz + qax*qby - qay*qbx; result.w = qaw*qbw - qax*qbx - qay*qby - qaz*qbz; return result; }
O3
c
QuaternionMultiply: movaps %xmm0, %xmm4 movaps 0x65caf(%rip), %xmm5 # 0xcf150 movaps %xmm1, %xmm0 xorps %xmm5, %xmm0 movaps %xmm2, %xmm6 shufps $0x10, %xmm1, %xmm6 # xmm6 = xmm6[0,0],xmm1[1,0] movaps %xmm1, %xmm7 shufps $0x25, %xmm6, %xmm7 # xmm7 = xmm7[1,1],xmm6[2,0] xorps %xmm4, %xmm5 movaps %xmm5, %xmm8 movlhps %xmm3, %xmm8 # xmm8 = xmm8[0],xmm3[0] movaps %xmm2, %xmm6 shufps $0x24, %xmm8, %xmm6 # xmm6 = xmm6[0,1],xmm8[2,0] mulps %xmm7, %xmm6 movaps %xmm4, %xmm7 movlhps %xmm1, %xmm7 # xmm7 = xmm7[0],xmm1[0] shufps $0x10, %xmm4, %xmm1 # xmm1 = xmm1[0,0],xmm4[1,0] shufps $0x40, %xmm5, %xmm0 # xmm0 = xmm0[0,0],xmm5[0,1] shufps $0x55, %xmm2, %xmm5 # xmm5 = xmm5[1,1],xmm2[1,1] movaps %xmm3, %xmm8 unpcklps %xmm2, %xmm8 # xmm8 = xmm8[0],xmm2[0],xmm8[1],xmm2[1] shufps $0xd4, %xmm2, %xmm4 # xmm4 = xmm4[0,1],xmm2[1,3] shufps $0x1, %xmm3, %xmm2 # xmm2 = xmm2[1,0],xmm3[0,0] shufps $0x55, %xmm3, %xmm3 # xmm3 = xmm3[1,1,1,1] mulps %xmm7, %xmm3 addps %xmm6, %xmm3 shufps $0x22, %xmm5, %xmm1 # xmm1 = xmm1[2,0],xmm5[2,0] shufps $0x84, %xmm4, %xmm8 # xmm8 = xmm8[0,1],xmm4[0,2] mulps %xmm1, %xmm8 addps %xmm3, %xmm8 shufps $0x78, %xmm0, %xmm0 # xmm0 = xmm0[0,2,3,1] shufps $0xd8, %xmm2, %xmm2 # xmm2 = xmm2[0,2,1,3] mulps %xmm2, %xmm0 addps %xmm8, %xmm0 movaps %xmm0, %xmm1 unpckhpd %xmm0, %xmm1 # xmm1 = xmm1[1],xmm0[1] retq
QuaternionMultiply: movaps xmm4, xmm0 movaps xmm5, cs:xmmword_CF150 movaps xmm0, xmm1 xorps xmm0, xmm5 movaps xmm6, xmm2 shufps xmm6, xmm1, 10h movaps xmm7, xmm1 shufps xmm7, xmm6, 25h ; '%' xorps xmm5, xmm4 movaps xmm8, xmm5 movlhps xmm8, xmm3 movaps xmm6, xmm2 shufps xmm6, xmm8, 24h ; '$' mulps xmm6, xmm7 movaps xmm7, xmm4 movlhps xmm7, xmm1 shufps xmm1, xmm4, 10h shufps xmm0, xmm5, 40h ; '@' shufps xmm5, xmm2, 55h ; 'U' movaps xmm8, xmm3 unpcklps xmm8, xmm2 shufps xmm4, xmm2, 0D4h shufps xmm2, xmm3, 1 shufps xmm3, xmm3, 55h ; 'U' mulps xmm3, xmm7 addps xmm3, xmm6 shufps xmm1, xmm5, 22h ; '"' shufps xmm8, xmm4, 84h mulps xmm8, xmm1 addps xmm8, xmm3 shufps xmm0, xmm0, 78h ; 'x' shufps xmm2, xmm2, 0D8h mulps xmm0, xmm2 addps xmm0, xmm8 movaps xmm1, xmm0 unpckhpd xmm1, xmm0 retn
__m128 QuaternionMultiply(__m128 a1, __m128 a2, __m128 a3, __m128 a4) { __m128 v5; // xmm0 __m128 v6; // xmm5 __m128 v7; // xmm6 __m128 v8; // xmm7 __m128 v9; // xmm1 __m128 v10; // xmm0 __m128 v11; // xmm5 __m128 v12; // xmm8 __m128 v13; // xmm4 __m128 v14; // xmm2 v5 = _mm_xor_ps(a2, (__m128)xmmword_CF150); v6 = _mm_xor_ps((__m128)xmmword_CF150, a1); v7 = _mm_mul_ps(_mm_shuffle_ps(a3, _mm_movelh_ps(v6, a4), 36), _mm_shuffle_ps(a2, _mm_shuffle_ps(a3, a2, 16), 37)); v8 = _mm_movelh_ps(a1, a2); v9 = _mm_shuffle_ps(a2, a1, 16); v10 = _mm_shuffle_ps(v5, v6, 64); v11 = _mm_shuffle_ps(v6, a3, 85); v12 = _mm_unpacklo_ps(a4, a3); v13 = _mm_shuffle_ps(a1, a3, 212); v14 = _mm_shuffle_ps(a3, a4, 1); return _mm_add_ps( _mm_mul_ps(_mm_shuffle_ps(v10, v10, 120), _mm_shuffle_ps(v14, v14, 216)), _mm_add_ps( _mm_mul_ps(_mm_shuffle_ps(v12, v13, 132), _mm_shuffle_ps(v9, v11, 34)), _mm_add_ps(_mm_mul_ps(_mm_shuffle_ps(a4, a4, 85), v8), v7))); }
QuaternionMultiply: MOVAPS XMM4,XMM0 MOVAPS XMM5,xmmword ptr [0x001cf150] MOVAPS XMM0,XMM1 XORPS XMM0,XMM5 MOVAPS XMM6,XMM2 SHUFPS XMM6,XMM1,0x10 MOVAPS XMM7,XMM1 SHUFPS XMM7,XMM6,0x25 XORPS XMM5,XMM4 MOVAPS XMM8,XMM5 MOVLHPS XMM8,XMM3 MOVAPS XMM6,XMM2 SHUFPS XMM6,XMM8,0x24 MULPS XMM6,XMM7 MOVAPS XMM7,XMM4 MOVLHPS XMM7,XMM1 SHUFPS XMM1,XMM4,0x10 SHUFPS XMM0,XMM5,0x40 SHUFPS XMM5,XMM2,0x55 MOVAPS XMM8,XMM3 UNPCKLPS XMM8,XMM2 SHUFPS XMM4,XMM2,0xd4 SHUFPS XMM2,XMM3,0x1 SHUFPS XMM3,XMM3,0x55 MULPS XMM3,XMM7 ADDPS XMM3,XMM6 SHUFPS XMM1,XMM5,0x22 SHUFPS XMM8,XMM4,0x84 MULPS XMM8,XMM1 ADDPS XMM8,XMM3 SHUFPS XMM0,XMM0,0x78 SHUFPS XMM2,XMM2,0xd8 MULPS XMM0,XMM2 ADDPS XMM0,XMM8 MOVAPS XMM1,XMM0 UNPCKHPD XMM1,XMM0 RET
/* WARNING: Globals starting with '_' overlap smaller symbols at the same address */ int8 QuaternionMultiply(int8 param_1,int8 param_2,int8 param_3,int8 param_4) { float fVar1; float fVar2; float fVar3; float fVar4; fVar4 = (float)((ulong)param_4 >> 0x20); fVar3 = (float)((ulong)param_3 >> 0x20); fVar1 = (float)((ulong)param_1 >> 0x20); fVar2 = (float)((ulong)param_2 >> 0x20); return CONCAT44((float)(_DAT_001cf150 ^ (uint)(float)param_1) * (float)param_4 + (float)param_3 * (float)param_2 + fVar4 * fVar1 + fVar3 * fVar2, (float)((uint)(float)param_2 ^ _DAT_001cf150) * fVar3 + (float)param_4 * fVar1 + fVar4 * (float)param_1 + (float)param_3 * fVar2); }
20,578
std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> nlohmann::json_abi_v3_11_3::detail::concat<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, char const (&) [29], char const*>(char const (&) [29], char const*&&)
11AgReS1SoR11[P]Graph/Common/FiguresStorage/src/json.hpp
inline OutStringType concat(Args && ... args) { OutStringType str; str.reserve(concat_length(args...)); concat_into(str, std::forward<Args>(args)...); return str; }
O1
cpp
std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> nlohmann::json_abi_v3_11_3::detail::concat<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, char const (&) [29], char const*>(char const (&) [29], char const*&&): pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x18, %rsp movq %r9, %r13 movq %r8, %r14 movq %rcx, %r12 movq %rsi, %rbp movq %rdi, %rbx leaq 0x10(%rdi), %rax movq %rax, (%rsp) movq %rax, (%rdi) movq $0x0, 0x8(%rdi) movb $0x0, 0x10(%rdi) movq 0x8(%rsi), %r15 movq %rdx, 0x10(%rsp) movq %rdx, %rdi callq 0x113f0 addq %rax, %r15 addq 0x8(%r12), %r15 movq %r14, 0x8(%rsp) movq %r14, %rdi callq 0x113f0 addq %rax, %r15 addq 0x8(%r13), %r15 movq 0x50(%rsp), %rax addq 0x8(%rax), %r15 movq %rbx, %rdi movq %r15, %rsi callq 0x11e40 movq (%rbp), %rsi movq 0x8(%rbp), %rdx movq %rbx, %rdi callq 0x112a0 movq %rbx, %rdi movq 0x10(%rsp), %rsi callq 0x12140 movq (%r12), %rsi movq 0x8(%r12), %rdx movq %rbx, %rdi callq 0x112a0 movq %rbx, %rdi movq 0x8(%rsp), %rsi callq 0x12140 movq (%r13), %rsi movq 0x8(%r13), %rdx movq %rbx, %rdi callq 0x112a0 movq 0x50(%rsp), %rax movq (%rax), %rsi movq 0x8(%rax), %rdx movq %rbx, %rdi callq 0x112a0 movq %rbx, %rax addq $0x18, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq movq %rax, %r14 movq (%rbx), %rdi cmpq (%rsp), %rdi je 0x1f850 movq (%rsp), %rax movq (%rax), %rsi incq %rsi callq 0x119b0 movq %r14, %rdi callq 0x12010
_ZN8nlohmann16json_abi_v3_11_36detail6concatINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEJS8_RA12_KcS8_RA3_S9_S8_RKS8_EEET_DpOT0_: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 18h mov r13, r9 mov r14, r8 mov r12, rcx mov rbp, rsi mov rbx, rdi lea rax, [rdi+10h] mov [rsp+48h+var_48], rax mov [rdi], rax mov qword ptr [rdi+8], 0 mov byte ptr [rdi+10h], 0 mov r15, [rsi+8] mov [rsp+48h+var_38], rdx mov rdi, rdx call _strlen add r15, rax add r15, [r12+8] mov [rsp+48h+var_40], r14 mov rdi, r14 call _strlen add r15, rax add r15, [r13+8] mov rax, [rsp+48h+arg_0] add r15, [rax+8] mov rdi, rbx mov rsi, r15 call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE7reserveEm; std::string::reserve(ulong) mov rsi, [rbp+0] mov rdx, [rbp+8] mov rdi, rbx call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9_M_appendEPKcm; std::string::_M_append(char const*,ulong) mov rdi, rbx mov rsi, [rsp+48h+var_38] call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendEPKc; std::string::append(char const*) mov rsi, [r12] mov rdx, [r12+8] mov rdi, rbx call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9_M_appendEPKcm; std::string::_M_append(char const*,ulong) mov rdi, rbx mov rsi, [rsp+48h+var_40] call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendEPKc; std::string::append(char const*) mov rsi, [r13+0] mov rdx, [r13+8] mov rdi, rbx call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9_M_appendEPKcm; std::string::_M_append(char const*,ulong) mov rax, [rsp+48h+arg_0] mov rsi, [rax] mov rdx, [rax+8] mov rdi, rbx call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9_M_appendEPKcm; std::string::_M_append(char const*,ulong) mov rax, rbx add rsp, 18h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn mov r14, rax mov rdi, [rbx]; void * cmp rdi, [rsp+0] jz short loc_1F850 mov rax, [rsp+0] mov rsi, [rax] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_1F850: mov rdi, r14 call __Unwind_Resume
long long nlohmann::json_abi_v3_11_3::detail::concat<std::string,std::string,char const(&)[12],std::string,char const(&)[3],std::string,std::string const&>( long long a1, _QWORD *a2, long long a3, _QWORD *a4, long long a5, _QWORD *a6, _QWORD *a7) { long long v10; // r15 long long v11; // r15 long long v12; // rax *(_QWORD *)a1 = a1 + 16; *(_QWORD *)(a1 + 8) = 0LL; *(_BYTE *)(a1 + 16) = 0; v10 = a2[1]; v11 = a4[1] + strlen(a3) + v10; v12 = strlen(a5); std::string::reserve(a1, a7[1] + a6[1] + v12 + v11); std::string::_M_append(a1, *a2, a2[1]); std::string::append(a1, a3); std::string::_M_append(a1, *a4, a4[1]); std::string::append(a1, a5); std::string::_M_append(a1, *a6, a6[1]); std::string::_M_append(a1, *a7, a7[1]); return a1; }
concat<std::__cxx11::string,std::__cxx11::string,char_const(&)[12],std::__cxx11::string,char_const(&)[3],std::__cxx11::string,std::__cxx11::string_const&>: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x18 MOV R13,R9 MOV R14,R8 MOV R12,RCX MOV RBP,RSI MOV RBX,RDI LEA RAX,[RDI + 0x10] MOV qword ptr [RSP],RAX MOV qword ptr [RDI],RAX MOV qword ptr [RDI + 0x8],0x0 MOV byte ptr [RDI + 0x10],0x0 MOV R15,qword ptr [RSI + 0x8] MOV qword ptr [RSP + 0x10],RDX MOV RDI,RDX CALL 0x001113f0 ADD R15,RAX ADD R15,qword ptr [R12 + 0x8] MOV qword ptr [RSP + 0x8],R14 MOV RDI,R14 CALL 0x001113f0 ADD R15,RAX ADD R15,qword ptr [R13 + 0x8] MOV RAX,qword ptr [RSP + 0x50] ADD R15,qword ptr [RAX + 0x8] LAB_0011f7b9: MOV RDI,RBX MOV RSI,R15 CALL 0x00111e40 MOV RSI,qword ptr [RBP] MOV RDX,qword ptr [RBP + 0x8] MOV RDI,RBX CALL 0x001112a0 MOV RDI,RBX MOV RSI,qword ptr [RSP + 0x10] CALL 0x00112140 MOV RSI,qword ptr [R12] MOV RDX,qword ptr [R12 + 0x8] MOV RDI,RBX CALL 0x001112a0 MOV RDI,RBX MOV RSI,qword ptr [RSP + 0x8] CALL 0x00112140 MOV RSI,qword ptr [R13] MOV RDX,qword ptr [R13 + 0x8] MOV RDI,RBX CALL 0x001112a0 MOV RAX,qword ptr [RSP + 0x50] MOV RSI,qword ptr [RAX] MOV RDX,qword ptr [RAX + 0x8] MOV RDI,RBX CALL 0x001112a0 LAB_0011f823: MOV RAX,RBX ADD RSP,0x18 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
/* std::__cxx11::string nlohmann::json_abi_v3_11_3::detail::concat<std::__cxx11::string, std::__cxx11::string, char const (&) [12], std::__cxx11::string, char const (&) [3], std::__cxx11::string, std::__cxx11::string const&>(std::__cxx11::string&&, char const (&) [12], std::__cxx11::string&&, char const (&) [3], std::__cxx11::string&&, std::__cxx11::string const&) */ detail * __thiscall nlohmann::json_abi_v3_11_3::detail:: concat<std::__cxx11::string,std::__cxx11::string,char_const(&)[12],std::__cxx11::string,char_const(&)[3],std::__cxx11::string,std::__cxx11::string_const&> (detail *this,string *param_1,char *param_2,string *param_3,char *param_4,string *param_5, string *param_6) { *(detail **)this = this + 0x10; *(int8 *)(this + 8) = 0; this[0x10] = (detail)0x0; strlen(param_2); strlen(param_4); /* try { // try from 0011f7b9 to 0011f822 has its CatchHandler @ 0011f835 */ std::__cxx11::string::reserve((ulong)this); std::__cxx11::string::_M_append((char *)this,*(ulong *)param_1); std::__cxx11::string::append((char *)this); std::__cxx11::string::_M_append((char *)this,*(ulong *)param_3); std::__cxx11::string::append((char *)this); std::__cxx11::string::_M_append((char *)this,*(ulong *)param_5); std::__cxx11::string::_M_append((char *)this,*(ulong *)param_6); return this; }
20,579
std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> nlohmann::json_abi_v3_11_3::detail::concat<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, char const (&) [29], char const*>(char const (&) [29], char const*&&)
11AgReS1SoR11[P]Graph/Common/FiguresStorage/src/json.hpp
inline OutStringType concat(Args && ... args) { OutStringType str; str.reserve(concat_length(args...)); concat_into(str, std::forward<Args>(args)...); return str; }
O2
cpp
std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> nlohmann::json_abi_v3_11_3::detail::concat<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, char const (&) [29], char const*>(char const (&) [29], char const*&&): pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx pushq %rax movq %r9, %r14 movq %r8, %r15 movq %rcx, %r12 movq %rdx, %r13 movq %rsi, %rbp movq %rdi, %rbx movq 0x40(%rsp), %r9 leaq 0x10(%rdi), %rax movq %rax, (%rdi) andq $0x0, 0x8(%rdi) movb $0x0, 0x10(%rdi) movq %rsi, %rdi movq %rdx, %rsi movq %rcx, %rdx movq %r8, %rcx movq %r14, %r8 callq 0x1d790 movq %rbx, %rdi movq %rax, %rsi callq 0x1d9c0 movq 0x40(%rsp), %rax movq %rax, (%rsp) movq %rbx, %rdi movq %rbp, %rsi movq %r13, %rdx movq %r12, %rcx movq %r15, %r8 movq %r14, %r9 callq 0x1d320 movq %rbx, %rax addq $0x8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq movq %rax, %r14 movq %rbx, %rdi callq 0x1c6f0 movq %r14, %rdi callq 0x1dcb0 nop
_ZN8nlohmann16json_abi_v3_11_36detail6concatINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEJS8_RA12_KcS8_RA3_S9_S8_RKS8_EEET_DpOT0_: push rbp push r15 push r14 push r13 push r12 push rbx push rax mov r14, r9 mov r15, r8 mov r12, rcx mov r13, rdx mov rbp, rsi mov rbx, rdi mov r9, [rsp+38h+arg_0] lea rax, [rdi+10h] mov [rdi], rax and qword ptr [rdi+8], 0 mov byte ptr [rdi+10h], 0 mov rdi, rsi mov rsi, rdx mov rdx, rcx mov rcx, r8 mov r8, r14 call __ZN8nlohmann16json_abi_v3_11_36detail13concat_lengthINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEJA12_cS8_A3_cS8_S8_EEEmRKT_DpRKT0_; nlohmann::json_abi_v3_11_3::detail::concat_length<std::string,char [12],std::string,char [3],std::string,std::string>(std::string const&,char [12],std::string,char [3],std::string,std::string const&) mov rdi, rbx mov rsi, rax call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE7reserveEm; std::string::reserve(ulong) mov rax, [rsp+38h+arg_0] mov [rsp+38h+var_38], rax mov rdi, rbx mov rsi, rbp mov rdx, r13 mov rcx, r12 mov r8, r15 mov r9, r14 call __ZN8nlohmann16json_abi_v3_11_36detail11concat_intoINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES8_JRA12_KcS8_RA3_S9_S8_RKS8_ETnNSt9enable_ifIXsr24detect_string_can_appendIT_T0_EE5valueEiE4typeELi0EEEvRSH_OSI_DpOT1_ mov rax, rbx add rsp, 8 pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn mov r14, rax mov rdi, rbx call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() mov rdi, r14 call __Unwind_Resume
long long nlohmann::json_abi_v3_11_3::detail::concat<std::string,std::string,char const(&)[12],std::string,char const(&)[3],std::string,std::string const&>( long long a1, long long a2, long long a3, long long a4, long long a5, long long a6, long long a7) { long long v7; // rax int v8; // r14d int v9; // r15d int v10; // r12d int v11; // r13d long long v12; // rax v8 = a6; v9 = a5; v10 = a4; v11 = a3; *(_QWORD *)a1 = a1 + 16; *(_QWORD *)(a1 + 8) = 0LL; *(_BYTE *)(a1 + 16) = 0; v12 = nlohmann::json_abi_v3_11_3::detail::concat_length<std::string,char [12],std::string,char [3],std::string,std::string>( a2, a3, a4, a5, a6, a7, v7); std::string::reserve(a1, v12); _ZN8nlohmann16json_abi_v3_11_36detail11concat_intoINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES8_JRA12_KcS8_RA3_S9_S8_RKS8_ETnNSt9enable_ifIXsr24detect_string_can_appendIT_T0_EE5valueEiE4typeELi0EEEvRSH_OSI_DpOT1_( a1, a2, v11, v10, v9, v8, a7); return a1; }
concat<std::__cxx11::string,std::__cxx11::string,char_const(&)[12],std::__cxx11::string,char_const(&)[3],std::__cxx11::string,std::__cxx11::string_const&>: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX PUSH RAX MOV R14,R9 MOV R15,R8 MOV R12,RCX MOV R13,RDX MOV RBP,RSI MOV RBX,RDI MOV R9,qword ptr [RSP + 0x40] LEA RAX,[RDI + 0x10] MOV qword ptr [RDI],RAX AND qword ptr [RDI + 0x8],0x0 MOV byte ptr [RDI + 0x10],0x0 LAB_001290e1: MOV RDI,RSI MOV RSI,RDX MOV RDX,RCX MOV RCX,R8 MOV R8,R14 CALL 0x0011d790 MOV RDI,RBX MOV RSI,RAX CALL 0x0011d9c0 MOV RAX,qword ptr [RSP + 0x40] MOV qword ptr [RSP],RAX MOV RDI,RBX MOV RSI,RBP MOV RDX,R13 MOV RCX,R12 MOV R8,R15 MOV R9,R14 CALL 0x0011d320 LAB_00129120: MOV RAX,RBX ADD RSP,0x8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
/* std::__cxx11::string nlohmann::json_abi_v3_11_3::detail::concat<std::__cxx11::string, std::__cxx11::string, char const (&) [12], std::__cxx11::string, char const (&) [3], std::__cxx11::string, std::__cxx11::string const&>(std::__cxx11::string&&, char const (&) [12], std::__cxx11::string&&, char const (&) [3], std::__cxx11::string&&, std::__cxx11::string const&) */ detail * __thiscall nlohmann::json_abi_v3_11_3::detail:: concat<std::__cxx11::string,std::__cxx11::string,char_const(&)[12],std::__cxx11::string,char_const(&)[3],std::__cxx11::string,std::__cxx11::string_const&> (detail *this,string *param_1,char *param_2,string *param_3,char *param_4,string *param_5, string *param_6) { *(detail **)this = this + 0x10; *(int8 *)(this + 8) = 0; this[0x10] = (detail)0x0; /* try { // try from 001290e1 to 0012911f has its CatchHandler @ 00129132 */ concat_length<std::__cxx11::string,char[12],std::__cxx11::string,char[3],std::__cxx11::string,std::__cxx11::string> (param_1,param_2,param_3,param_4,param_5,param_6); std::__cxx11::string::reserve((ulong)this); _ZN8nlohmann16json_abi_v3_11_36detail11concat_intoINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES8_JRA12_KcS8_RA3_S9_S8_RKS8_ETnNSt9enable_ifIXsr24detect_string_can_appendIT_T0_EE5valueEiE4typeELi0EEEvRSH_OSI_DpOT1_ (this,param_1,param_2,param_3,param_4,param_5,param_6); return this; }
20,580
std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> nlohmann::json_abi_v3_11_3::detail::concat<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, char const (&) [29], char const*>(char const (&) [29], char const*&&)
11AgReS1SoR11[P]Graph/Common/FiguresStorage/src/json.hpp
inline OutStringType concat(Args && ... args) { OutStringType str; str.reserve(concat_length(args...)); concat_into(str, std::forward<Args>(args)...); return str; }
O3
cpp
std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> nlohmann::json_abi_v3_11_3::detail::concat<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, char const (&) [29], char const*>(char const (&) [29], char const*&&): pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx pushq %rax movq %r8, %r14 movq %rcx, %r15 movq %rdx, %r12 movq %rsi, %r13 movq %rdi, %rbx leaq 0x10(%rdi), %rax movq %rax, (%rsp) movq %rax, (%rdi) movq $0x0, 0x8(%rdi) movb $0x0, 0x10(%rdi) movq (%rsi), %rdi callq 0x113f0 movq %rax, %rbp movq %r12, %rdi callq 0x113f0 movq 0x8(%r15), %rcx addq %rbp, %rax leaq (%rcx,%rax), %rsi incq %rsi movq %rbx, %rdi callq 0x11e10 movq (%r13), %rsi movq %rbx, %rdi callq 0x12100 movq %rbx, %rdi movq %r12, %rsi callq 0x12100 movq (%r15), %rsi movq 0x8(%r15), %rdx movq %rbx, %rdi callq 0x112a0 movsbl (%r14), %esi movq %rbx, %rdi callq 0x11830 movq %rbx, %rax addq $0x8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq movq %rax, %r14 movq (%rbx), %rdi cmpq (%rsp), %rdi je 0x1f813 movq (%rsp), %rax movq (%rax), %rsi incq %rsi callq 0x119a0 movq %r14, %rdi callq 0x11fe0 nop
_ZN8nlohmann16json_abi_v3_11_36detail6concatINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEJPKcRA15_S9_S8_cEEET_DpOT0_: push rbp push r15 push r14 push r13 push r12 push rbx push rax mov r14, r8 mov r15, rcx mov r12, rdx mov r13, rsi mov rbx, rdi lea rax, [rdi+10h] mov [rsp+38h+var_38], rax mov [rdi], rax mov qword ptr [rdi+8], 0 mov byte ptr [rdi+10h], 0 mov rdi, [rsi] call _strlen mov rbp, rax mov rdi, r12 call _strlen mov rcx, [r15+8] add rax, rbp lea rsi, [rcx+rax] inc rsi mov rdi, rbx call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE7reserveEm; std::string::reserve(ulong) mov rsi, [r13+0] mov rdi, rbx call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendEPKc; std::string::append(char const*) mov rdi, rbx mov rsi, r12 call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendEPKc; std::string::append(char const*) mov rsi, [r15] mov rdx, [r15+8] mov rdi, rbx call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9_M_appendEPKcm; std::string::_M_append(char const*,ulong) movsx esi, byte ptr [r14] mov rdi, rbx call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9push_backEc; std::string::push_back(char) mov rax, rbx add rsp, 8 pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn mov r14, rax mov rdi, [rbx]; void * cmp rdi, [rsp+0] jz short loc_1F813 mov rax, [rsp+0] mov rsi, [rax] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_1F813: mov rdi, r14 call __Unwind_Resume
long long nlohmann::json_abi_v3_11_3::detail::concat<std::string,char const*,char const(&)[15],std::string,char>( long long a1, _QWORD *a2, long long a3, _QWORD *a4, char *a5) { long long v8; // rbp long long v9; // rax *(_QWORD *)a1 = a1 + 16; *(_QWORD *)(a1 + 8) = 0LL; *(_BYTE *)(a1 + 16) = 0; v8 = strlen(*a2); v9 = strlen(a3); std::string::reserve(a1, a4[1] + v8 + v9 + 1); std::string::append(a1, *a2); std::string::append(a1, a3); std::string::_M_append(a1, *a4, a4[1]); std::string::push_back(a1, (unsigned int)*a5); return a1; }
concat<std::__cxx11::string,char_const*,char_const(&)[15],std::__cxx11::string,char>: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX PUSH RAX MOV R14,R8 MOV R15,RCX MOV R12,RDX MOV R13,RSI MOV RBX,RDI LEA RAX,[RDI + 0x10] MOV qword ptr [RSP],RAX MOV qword ptr [RDI],RAX MOV qword ptr [RDI + 0x8],0x0 MOV byte ptr [RDI + 0x10],0x0 MOV RDI,qword ptr [RSI] CALL 0x001113f0 MOV RBP,RAX MOV RDI,R12 CALL 0x001113f0 MOV RCX,qword ptr [R15 + 0x8] ADD RAX,RBP LEA RSI,[RCX + RAX*0x1] INC RSI LAB_0011f7ac: MOV RDI,RBX CALL 0x00111e10 MOV RSI,qword ptr [R13] MOV RDI,RBX CALL 0x00112100 MOV RDI,RBX MOV RSI,R12 CALL 0x00112100 MOV RSI,qword ptr [R15] MOV RDX,qword ptr [R15 + 0x8] MOV RDI,RBX CALL 0x001112a0 MOVSX ESI,byte ptr [R14] MOV RDI,RBX CALL 0x00111830 LAB_0011f7e6: MOV RAX,RBX ADD RSP,0x8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
/* std::__cxx11::string nlohmann::json_abi_v3_11_3::detail::concat<std::__cxx11::string, char const*, char const (&) [15], std::__cxx11::string, char>(char const*&&, char const (&) [15], std::__cxx11::string&&, char&&) */ char ** nlohmann::json_abi_v3_11_3::detail:: concat<std::__cxx11::string,char_const*,char_const(&)[15],std::__cxx11::string,char> (char **param_1,char *param_2,string *param_3,char *param_4) { *param_1 = (char *)(param_1 + 2); param_1[1] = (char *)0x0; *(int1 *)(param_1 + 2) = 0; strlen(*(char **)param_2); strlen((char *)param_3); /* try { // try from 0011f7ac to 0011f7e5 has its CatchHandler @ 0011f7f8 */ std::__cxx11::string::reserve((ulong)param_1); std::__cxx11::string::append((char *)param_1); std::__cxx11::string::append((char *)param_1); std::__cxx11::string::_M_append((char *)param_1,*(ulong *)param_4); std::__cxx11::string::push_back((char)param_1); return param_1; }
20,581
google::protobuf::OneofOptions::_InternalSerialize(unsigned char*, google::protobuf::io::EpsCopyOutputStream*) const
aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/descriptor.pb.cc
uint8_t* OneofOptions::_InternalSerialize( uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const { // @@protoc_insertion_point(serialize_to_array_start:google.protobuf.OneofOptions) uint32_t cached_has_bits = 0; (void) cached_has_bits; // repeated .google.protobuf.UninterpretedOption uninterpreted_option = 999; for (unsigned i = 0, n = static_cast<unsigned>(this->_internal_uninterpreted_option_size()); i < n; i++) { const auto& repfield = this->_internal_uninterpreted_option(i); target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite:: InternalWriteMessage(999, repfield, repfield.GetCachedSize(), target, stream); } // Extension range [1000, 536870912) target = _impl_._extensions_._InternalSerialize( internal_default_instance(), 1000, 536870912, target, stream); if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) { target = ::_pbi::WireFormat::InternalSerializeUnknownFieldsToArray( _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance), target, stream); } // @@protoc_insertion_point(serialize_to_array_end:google.protobuf.OneofOptions) return target; }
O3
cpp
google::protobuf::OneofOptions::_InternalSerialize(unsigned char*, google::protobuf::io::EpsCopyOutputStream*) const: pushq %rbp pushq %r15 pushq %r14 pushq %rbx pushq %rax movq %rdx, %rbx movq %rsi, %rax movq %rdi, %r14 movl 0x30(%rdi), %ebp testl %ebp, %ebp je 0x536d7 xorl %r15d, %r15d movq 0x38(%r14), %rcx movslq %r15d, %r15 movq 0x8(%rcx,%r15,8), %rsi movl 0x14(%rsi), %edx movl $0x3e7, %edi # imm = 0x3E7 movq %rax, %rcx movq %rbx, %r8 callq 0xaa5b6 incl %r15d cmpl %r15d, %ebp jne 0x536b0 cmpw $0x0, 0x1a(%r14) je 0x536ff leaq 0x10(%r14), %rdi leaq 0xaf1d6(%rip), %rsi # 0x1028c0 movl $0x3e8, %edx # imm = 0x3E8 movl $0x20000000, %ecx # imm = 0x20000000 movq %rax, %r8 movq %rbx, %r9 callq 0x97a6e movq 0x8(%r14), %rdi testb $0x1, %dil jne 0x53714 addq $0x8, %rsp popq %rbx popq %r14 popq %r15 popq %rbp retq andq $-0x4, %rdi addq $0x8, %rdi movq %rax, %rsi movq %rbx, %rdx addq $0x8, %rsp popq %rbx popq %r14 popq %r15 popq %rbp jmp 0x88e52 nop
_ZNK6google8protobuf12OneofOptions18_InternalSerializeEPhPNS0_2io19EpsCopyOutputStreamE: push rbp push r15 push r14 push rbx push rax mov rbx, rdx mov rax, rsi mov r14, rdi mov ebp, [rdi+30h] test ebp, ebp jz short loc_536D7 xor r15d, r15d loc_536B0: mov rcx, [r14+38h] movsxd r15, r15d mov rsi, [rcx+r15*8+8]; int mov edx, [rsi+14h]; google::protobuf::MessageLite * mov edi, (offset elf_gnu_hash_bucket+17h); this mov rcx, rax; int mov r8, rbx; unsigned __int8 * call _ZN6google8protobuf8internal14WireFormatLite20InternalWriteMessageEiRKNS0_11MessageLiteEiPhPNS0_2io19EpsCopyOutputStreamE; google::protobuf::internal::WireFormatLite::InternalWriteMessage(int,google::protobuf::MessageLite const&,int,uchar *,google::protobuf::io::EpsCopyOutputStream *) inc r15d cmp ebp, r15d jnz short loc_536B0 loc_536D7: cmp word ptr [r14+1Ah], 0 jz short loc_536FF lea rdi, [r14+10h]; this lea rsi, _ZN6google8protobuf31_OneofOptions_default_instance_E; google::protobuf::MessageLite * mov edx, 3E8h; int mov ecx, 20000000h; int mov r8, rax; unsigned __int8 * mov r9, rbx; google::protobuf::io::EpsCopyOutputStream * call _ZNK6google8protobuf8internal12ExtensionSet22_InternalSerializeImplEPKNS0_11MessageLiteEiiPhPNS0_2io19EpsCopyOutputStreamE; google::protobuf::internal::ExtensionSet::_InternalSerializeImpl(google::protobuf::MessageLite const*,int,int,uchar *,google::protobuf::io::EpsCopyOutputStream *) loc_536FF: mov rdi, [r14+8] test dil, 1 jnz short loc_53714 add rsp, 8 pop rbx pop r14 pop r15 pop rbp retn loc_53714: and rdi, 0FFFFFFFFFFFFFFFCh add rdi, 8; this mov rsi, rax; google::protobuf::UnknownFieldSet * mov rdx, rbx; unsigned __int8 * add rsp, 8 pop rbx pop r14 pop r15 pop rbp jmp _ZN6google8protobuf8internal10WireFormat37InternalSerializeUnknownFieldsToArrayERKNS0_15UnknownFieldSetEPhPNS0_2io19EpsCopyOutputStreamE; google::protobuf::internal::WireFormat::InternalSerializeUnknownFieldsToArray(google::protobuf::UnknownFieldSet const&,uchar *,google::protobuf::io::EpsCopyOutputStream *)
unsigned __int8 * google::protobuf::OneofOptions::_InternalSerialize( google::protobuf::OneofOptions *this, unsigned __int8 *a2, google::protobuf::io::EpsCopyOutputStream *a3, google::protobuf::io::EpsCopyOutputStream *a4, long long a5, google::protobuf::io::EpsCopyOutputStream *a6) { unsigned __int8 *result; // rax int v8; // ebp int i; // r15d long long v10; // rsi long long v11; // rdi result = a2; v8 = *((_DWORD *)this + 12); if ( v8 ) { for ( i = 0; i != v8; ++i ) { v10 = *(_QWORD *)(*((_QWORD *)this + 7) + 8LL * i + 8); result = (unsigned __int8 *)google::protobuf::internal::WireFormatLite::InternalWriteMessage( (google::protobuf::internal::WireFormatLite *)((char *)&elf_gnu_hash_bucket[5] + 3), v10, (const google::protobuf::MessageLite *)*(unsigned int *)(v10 + 20), (int)result, (unsigned __int8 *)a3, a6); } } if ( *((_WORD *)this + 13) ) result = (unsigned __int8 *)google::protobuf::internal::ExtensionSet::_InternalSerializeImpl( (google::protobuf::OneofOptions *)((char *)this + 16), (const google::protobuf::MessageLite *)&google::protobuf::_OneofOptions_default_instance_, 1000, 0x20000000, result, a3); v11 = *((_QWORD *)this + 1); if ( (v11 & 1) != 0 ) return (unsigned __int8 *)google::protobuf::internal::WireFormat::InternalSerializeUnknownFieldsToArray( (google::protobuf::internal::WireFormat *)((v11 & 0xFFFFFFFFFFFFFFFCLL) + 8), (const google::protobuf::UnknownFieldSet *)result, (unsigned __int8 *)a3, a4); return result; }
_InternalSerialize: PUSH RBP PUSH R15 PUSH R14 PUSH RBX PUSH RAX MOV RBX,RDX MOV RAX,RSI MOV R14,RDI MOV EBP,dword ptr [RDI + 0x30] TEST EBP,EBP JZ 0x001536d7 XOR R15D,R15D LAB_001536b0: MOV RCX,qword ptr [R14 + 0x38] MOVSXD R15,R15D MOV RSI,qword ptr [RCX + R15*0x8 + 0x8] MOV EDX,dword ptr [RSI + 0x14] MOV EDI,0x3e7 MOV RCX,RAX MOV R8,RBX CALL 0x001aa5b6 INC R15D CMP EBP,R15D JNZ 0x001536b0 LAB_001536d7: CMP word ptr [R14 + 0x1a],0x0 JZ 0x001536ff LEA RDI,[R14 + 0x10] LEA RSI,[0x2028c0] MOV EDX,0x3e8 MOV ECX,0x20000000 MOV R8,RAX MOV R9,RBX CALL 0x00197a6e LAB_001536ff: MOV RDI,qword ptr [R14 + 0x8] TEST DIL,0x1 JNZ 0x00153714 ADD RSP,0x8 POP RBX POP R14 POP R15 POP RBP RET LAB_00153714: AND RDI,-0x4 ADD RDI,0x8 MOV RSI,RAX MOV RDX,RBX ADD RSP,0x8 POP RBX POP R14 POP R15 POP RBP JMP 0x00188e52
/* google::protobuf::OneofOptions::_InternalSerialize(unsigned char*, google::protobuf::io::EpsCopyOutputStream*) const */ void __thiscall google::protobuf::OneofOptions::_InternalSerialize (OneofOptions *this,uchar *param_1,EpsCopyOutputStream *param_2) { int iVar1; MessageLite *pMVar2; int iVar3; iVar1 = *(int *)(this + 0x30); if (iVar1 != 0) { iVar3 = 0; do { pMVar2 = *(MessageLite **)(*(long *)(this + 0x38) + 8 + (long)iVar3 * 8); param_1 = (uchar *)internal::WireFormatLite::InternalWriteMessage (999,pMVar2,*(int *)(pMVar2 + 0x14),param_1,param_2); iVar3 = iVar3 + 1; } while (iVar1 != iVar3); } if (*(short *)(this + 0x1a) != 0) { param_1 = (uchar *)internal::ExtensionSet::_InternalSerializeImpl ((ExtensionSet *)(this + 0x10), (MessageLite *)_OneofOptions_default_instance_,1000,0x20000000, param_1,param_2); } if ((*(ulong *)(this + 8) & 1) == 0) { return; } internal::WireFormat::InternalSerializeUnknownFieldsToArray ((UnknownFieldSet *)((*(ulong *)(this + 8) & 0xfffffffffffffffc) + 8),param_1,param_2); return; }
20,582
google::protobuf::MethodDescriptorProto::MethodDescriptorProto(google::protobuf::MethodDescriptorProto const&)
aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/descriptor.pb.cc
MethodDescriptorProto::MethodDescriptorProto(const MethodDescriptorProto& from) : ::PROTOBUF_NAMESPACE_ID::Message() { MethodDescriptorProto* const _this = this; (void)_this; new (&_impl_) Impl_{ decltype(_impl_._has_bits_){from._impl_._has_bits_} , /*decltype(_impl_._cached_size_)*/{} , decltype(_impl_.name_){} , decltype(_impl_.input_type_){} , decltype(_impl_.output_type_){} , decltype(_impl_.options_){nullptr} , decltype(_impl_.client_streaming_){} , decltype(_impl_.server_streaming_){}}; _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_); _impl_.name_.InitDefault(); #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING _impl_.name_.Set("", GetArenaForAllocation()); #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING if (from._internal_has_name()) { _this->_impl_.name_.Set(from._internal_name(), _this->GetArenaForAllocation()); } _impl_.input_type_.InitDefault(); #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING _impl_.input_type_.Set("", GetArenaForAllocation()); #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING if (from._internal_has_input_type()) { _this->_impl_.input_type_.Set(from._internal_input_type(), _this->GetArenaForAllocation()); } _impl_.output_type_.InitDefault(); #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING _impl_.output_type_.Set("", GetArenaForAllocation()); #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING if (from._internal_has_output_type()) { _this->_impl_.output_type_.Set(from._internal_output_type(), _this->GetArenaForAllocation()); } if (from._internal_has_options()) { _this->_impl_.options_ = new ::PROTOBUF_NAMESPACE_ID::MethodOptions(*from._impl_.options_); } ::memcpy(&_impl_.client_streaming_, &from._impl_.client_streaming_, static_cast<size_t>(reinterpret_cast<char*>(&_impl_.server_streaming_) - reinterpret_cast<char*>(&_impl_.client_streaming_)) + sizeof(_impl_.server_streaming_)); // @@protoc_insertion_point(copy_constructor:google.protobuf.MethodDescriptorProto) }
O0
cpp
google::protobuf::MethodDescriptorProto::MethodDescriptorProto(google::protobuf::MethodDescriptorProto const&): subq $0x118, %rsp # imm = 0x118 movq %rdi, 0xc8(%rsp) movq %rsi, 0xc0(%rsp) movq 0xc8(%rsp), %rdi movq %rdi, 0x98(%rsp) callq 0xd3f60 movq 0x98(%rsp), %rax leaq 0x1bd975(%rip), %rcx # 0x278490 addq $0x10, %rcx movq %rcx, (%rax) movq %rax, 0xb8(%rsp) movq %rax, %rdi addq $0x10, %rdi movq %rdi, 0x90(%rsp) movq 0xc0(%rsp), %rcx movl 0x10(%rcx), %ecx movl %ecx, 0x10(%rax) addq $0x4, %rdi movq %rdi, 0x88(%rsp) xorl %esi, %esi movl $0x4, %edx callq 0x13200 movq 0x88(%rsp), %rdi callq 0xd3ff0 movq 0x90(%rsp), %rdi addq $0x8, %rdi xorl %esi, %esi movl $0x8, %edx callq 0x13200 movq 0x90(%rsp), %rdi addq $0x10, %rdi xorl %esi, %esi movl $0x8, %edx callq 0x13200 movq 0x90(%rsp), %rdi addq $0x18, %rdi xorl %esi, %esi movl $0x8, %edx callq 0x13200 movq 0x98(%rsp), %rcx movq $0x0, 0x30(%rcx) movb $0x0, 0x38(%rcx) movb $0x0, 0x39(%rcx) addq $0x8, %rcx movq 0xc0(%rsp), %rax addq $0x8, %rax movq %rcx, 0xd8(%rsp) movq %rax, 0xd0(%rsp) movq 0xd8(%rsp), %rax movq %rax, 0xa0(%rsp) movq 0xd0(%rsp), %rax movq %rax, 0xe0(%rsp) movq 0xe0(%rsp), %rax movq %rax, 0x110(%rsp) movq 0x110(%rsp), %rax movq (%rax), %rax andq $0x1, %rax cmpq $0x0, %rax setne %al movb %al, 0xab(%rsp) movb 0xab(%rsp), %al testb $0x1, %al jne 0xbac49 jmp 0xbacfe movq 0xd0(%rsp), %rax movq %rax, 0xf0(%rsp) movq $0x0, 0xe8(%rsp) movq 0xf0(%rsp), %rax movq %rax, 0x80(%rsp) movq %rax, 0x100(%rsp) movq 0x100(%rsp), %rax movq %rax, 0x108(%rsp) movq 0x108(%rsp), %rax movq (%rax), %rax andq $0x1, %rax cmpq $0x0, %rax je 0xbacbd movq 0x80(%rsp), %rdi callq 0x9cd40 addq $0x8, %rax movq %rax, 0xf8(%rsp) jmp 0xbacdb movq 0xe8(%rsp), %rax callq *%rax movq %rax, 0x78(%rsp) jmp 0xbacce movq 0x78(%rsp), %rax movq %rax, 0xf8(%rsp) movq 0xf8(%rsp), %rax movq %rax, 0x70(%rsp) movq 0x70(%rsp), %rsi movq 0xa0(%rsp), %rdi callq 0xe0920 jmp 0xbacfc jmp 0xbacfe jmp 0xbad00 movq 0x98(%rsp), %rdi addq $0x18, %rdi callq 0xd4b40 jmp 0xbad13 movq 0xc0(%rsp), %rdi callq 0xd8d60 movb %al, 0x6f(%rsp) jmp 0xbad26 movb 0x6f(%rsp), %al testb $0x1, %al jne 0xbad30 jmp 0xbad9a movq 0xb8(%rsp), %rax addq $0x18, %rax movq %rax, 0x58(%rsp) movq 0xc0(%rsp), %rdi callq 0x88f00 movq %rax, 0x60(%rsp) jmp 0xbad55 movq 0xb8(%rsp), %rdi callq 0x80180 movq %rax, 0x50(%rsp) jmp 0xbad69 movq 0x50(%rsp), %rdx movq 0x60(%rsp), %rsi movq 0x58(%rsp), %rdi callq 0x183680 jmp 0xbad7f jmp 0xbad9a movq %rax, %rcx movl %edx, %eax movq %rcx, 0xb0(%rsp) movl %eax, 0xac(%rsp) jmp 0xbaf5b movq 0x98(%rsp), %rdi addq $0x20, %rdi callq 0xd4b40 jmp 0xbadad movq 0xc0(%rsp), %rdi callq 0xd8da0 movb %al, 0x4f(%rsp) jmp 0xbadc0 movb 0x4f(%rsp), %al testb $0x1, %al jne 0xbadca jmp 0xbae1b movq 0xb8(%rsp), %rax addq $0x20, %rax movq %rax, 0x38(%rsp) movq 0xc0(%rsp), %rdi callq 0x89180 movq %rax, 0x40(%rsp) jmp 0xbadef movq 0xb8(%rsp), %rdi callq 0x80180 movq %rax, 0x30(%rsp) jmp 0xbae03 movq 0x30(%rsp), %rdx movq 0x40(%rsp), %rsi movq 0x38(%rsp), %rdi callq 0x183680 jmp 0xbae19 jmp 0xbae1b movq 0x98(%rsp), %rdi addq $0x28, %rdi callq 0xd4b40 jmp 0xbae2e movq 0xc0(%rsp), %rdi callq 0xd8de0 movb %al, 0x2f(%rsp) jmp 0xbae41 movb 0x2f(%rsp), %al testb $0x1, %al jne 0xbae4b jmp 0xbae9c movq 0xb8(%rsp), %rax addq $0x28, %rax movq %rax, 0x18(%rsp) movq 0xc0(%rsp), %rdi callq 0x891b0 movq %rax, 0x20(%rsp) jmp 0xbae70 movq 0xb8(%rsp), %rdi callq 0x80180 movq %rax, 0x10(%rsp) jmp 0xbae84 movq 0x10(%rsp), %rdx movq 0x20(%rsp), %rsi movq 0x18(%rsp), %rdi callq 0x183680 jmp 0xbae9a jmp 0xbae9c movq 0xc0(%rsp), %rdi callq 0x88f30 movb %al, 0xf(%rsp) jmp 0xbaeaf movb 0xf(%rsp), %al testb $0x1, %al jne 0xbaeb9 jmp 0xbaf11 movl $0x50, %edi callq 0x13450 movq %rax, (%rsp) jmp 0xbaec9 movq (%rsp), %rdi movq 0xc0(%rsp), %rax movq 0x30(%rax), %rsi callq 0xc7380 jmp 0xbaee0 movq (%rsp), %rcx movq 0xb8(%rsp), %rax movq %rcx, 0x30(%rax) jmp 0xbaf11 movq (%rsp), %rdi movq %rax, %rcx movl %edx, %eax movq %rcx, 0xb0(%rsp) movl %eax, 0xac(%rsp) callq 0x13400 jmp 0xbaf5b movq 0x98(%rsp), %rax movq %rax, %rdi addq $0x10, %rdi addq $0x28, %rdi movq 0xc0(%rsp), %rsi addq $0x10, %rsi addq $0x28, %rsi movq %rax, %rdx addq $0x10, %rdx addq $0x29, %rdx addq $0x10, %rax addq $0x28, %rax subq %rax, %rdx addq $0x1, %rdx callq 0x13390 addq $0x118, %rsp # imm = 0x118 retq movq 0x98(%rsp), %rdi callq 0xd3f50 movq 0xb0(%rsp), %rdi callq 0x13750 nopw %cs:(%rax,%rax)
_ZN6google8protobuf21MethodDescriptorProtoC2ERKS1_: sub rsp, 118h mov [rsp+118h+var_50], rdi mov [rsp+118h+var_58], rsi mov rdi, [rsp+118h+var_50]; this mov [rsp+118h+var_80], rdi call _ZN6google8protobuf7MessageC2Ev; google::protobuf::Message::Message(void) mov rax, [rsp+118h+var_80] lea rcx, _ZTVN6google8protobuf21MethodDescriptorProtoE; `vtable for'google::protobuf::MethodDescriptorProto add rcx, 10h mov [rax], rcx mov [rsp+118h+var_60], rax mov rdi, rax add rdi, 10h mov [rsp+118h+var_88], rdi mov rcx, [rsp+118h+var_58] mov ecx, [rcx+10h] mov [rax+10h], ecx add rdi, 4 mov [rsp+118h+var_90], rdi xor esi, esi mov edx, 4 call _memset mov rdi, [rsp+118h+var_90]; this call _ZN6google8protobuf8internal10CachedSizeC2Ev; google::protobuf::internal::CachedSize::CachedSize(void) mov rdi, [rsp+118h+var_88] add rdi, 8 xor esi, esi mov edx, 8 call _memset mov rdi, [rsp+118h+var_88] add rdi, 10h xor esi, esi mov edx, 8 call _memset mov rdi, [rsp+118h+var_88] add rdi, 18h xor esi, esi mov edx, 8 call _memset mov rcx, [rsp+118h+var_80] mov qword ptr [rcx+30h], 0 mov byte ptr [rcx+38h], 0 mov byte ptr [rcx+39h], 0 add rcx, 8 mov rax, [rsp+118h+var_58] add rax, 8 mov [rsp+118h+var_40], rcx mov [rsp+118h+var_48], rax mov rax, [rsp+118h+var_40] mov [rsp+118h+var_78], rax mov rax, [rsp+118h+var_48] mov [rsp+118h+var_38], rax mov rax, [rsp+118h+var_38] mov [rsp+118h+var_8], rax mov rax, [rsp+118h+var_8] mov rax, [rax] and rax, 1 cmp rax, 0 setnz al mov [rsp+118h+var_6D], al mov al, [rsp+118h+var_6D] test al, 1 jnz short loc_BAC49 jmp loc_BACFE loc_BAC49: mov rax, [rsp+118h+var_48] mov [rsp+118h+var_28], rax mov [rsp+118h+var_30], 0 mov rax, [rsp+118h+var_28] mov [rsp+118h+var_98], rax mov [rsp+118h+var_18], rax mov rax, [rsp+118h+var_18] mov [rsp+118h+var_10], rax mov rax, [rsp+118h+var_10] mov rax, [rax] and rax, 1 cmp rax, 0 jz short loc_BACBD mov rdi, [rsp+118h+var_98] call _ZNK6google8protobuf8internal16InternalMetadata8PtrValueINS2_9ContainerINS0_15UnknownFieldSetEEEEEPT_v; google::protobuf::internal::InternalMetadata::PtrValue<google::protobuf::internal::InternalMetadata::Container<google::protobuf::UnknownFieldSet>>(void) add rax, 8 mov [rsp+118h+var_20], rax jmp short loc_BACDB loc_BACBD: mov rax, [rsp+118h+var_30] call rax mov [rsp+118h+var_A0], rax jmp short $+2 loc_BACCE: mov rax, [rsp+118h+var_A0] mov [rsp+118h+var_20], rax loc_BACDB: mov rax, [rsp+118h+var_20] mov qword ptr [rsp+118h+var_A8], rax mov rsi, qword ptr [rsp+118h+var_A8]; int mov rdi, [rsp+118h+var_78]; void * call _ZN6google8protobuf8internal16InternalMetadata11DoMergeFromINS0_15UnknownFieldSetEEEvRKT_; google::protobuf::internal::InternalMetadata::DoMergeFrom<google::protobuf::UnknownFieldSet>(google::protobuf::UnknownFieldSet const&) jmp short $+2 loc_BACFC: jmp short $+2 loc_BACFE: jmp short $+2 loc_BAD00: mov rdi, [rsp+118h+var_80] add rdi, 18h; this call _ZN6google8protobuf8internal14ArenaStringPtr11InitDefaultEv; google::protobuf::internal::ArenaStringPtr::InitDefault(void) jmp short $+2 loc_BAD13: mov rdi, [rsp+118h+var_58]; this call _ZNK6google8protobuf21MethodDescriptorProto18_internal_has_nameEv; google::protobuf::MethodDescriptorProto::_internal_has_name(void) mov [rsp+118h+var_A9], al jmp short $+2 loc_BAD26: mov al, [rsp+118h+var_A9] test al, 1 jnz short loc_BAD30 jmp short loc_BAD9A loc_BAD30: mov rax, [rsp+118h+var_60] add rax, 18h mov qword ptr [rsp+118h+var_C0], rax mov rdi, [rsp+118h+var_58] call _ZNK6google8protobuf21MethodDescriptorProto14_internal_nameB5cxx11Ev; google::protobuf::MethodDescriptorProto::_internal_name(void) mov qword ptr [rsp+118h+var_B8], rax jmp short $+2 loc_BAD55: mov rdi, [rsp+118h+var_60]; this call _ZNK6google8protobuf11MessageLite21GetArenaForAllocationEv; google::protobuf::MessageLite::GetArenaForAllocation(void) mov qword ptr [rsp+118h+var_C8], rax jmp short $+2 loc_BAD69: mov rdx, qword ptr [rsp+118h+var_C8]; int mov rsi, qword ptr [rsp+118h+var_B8]; int mov rdi, qword ptr [rsp+118h+var_C0]; int call _ZN6google8protobuf8internal14ArenaStringPtr3SetERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEPNS0_5ArenaE; google::protobuf::internal::ArenaStringPtr::Set(std::string const&,google::protobuf::Arena *) jmp short $+2 loc_BAD7F: jmp short loc_BAD9A mov rcx, rax mov eax, edx mov [rsp+arg_A8], rcx mov [rsp+arg_A4], eax jmp loc_BAF5B loc_BAD9A: mov rdi, [rsp+118h+var_80] add rdi, 20h ; ' '; this call _ZN6google8protobuf8internal14ArenaStringPtr11InitDefaultEv; google::protobuf::internal::ArenaStringPtr::InitDefault(void) jmp short $+2 loc_BADAD: mov rdi, [rsp+118h+var_58]; this call _ZNK6google8protobuf21MethodDescriptorProto24_internal_has_input_typeEv; google::protobuf::MethodDescriptorProto::_internal_has_input_type(void) mov [rsp+118h+var_C9], al jmp short $+2 loc_BADC0: mov al, [rsp+118h+var_C9] test al, 1 jnz short loc_BADCA jmp short loc_BAE1B loc_BADCA: mov rax, [rsp+118h+var_60] add rax, 20h ; ' ' mov qword ptr [rsp+118h+var_E0], rax mov rdi, [rsp+118h+var_58] call _ZNK6google8protobuf21MethodDescriptorProto20_internal_input_typeB5cxx11Ev; google::protobuf::MethodDescriptorProto::_internal_input_type(void) mov qword ptr [rsp+118h+var_D8], rax jmp short $+2 loc_BADEF: mov rdi, [rsp+118h+var_60]; this call _ZNK6google8protobuf11MessageLite21GetArenaForAllocationEv; google::protobuf::MessageLite::GetArenaForAllocation(void) mov qword ptr [rsp+118h+var_E8], rax jmp short $+2 loc_BAE03: mov rdx, qword ptr [rsp+118h+var_E8]; int mov rsi, qword ptr [rsp+118h+var_D8]; int mov rdi, qword ptr [rsp+118h+var_E0]; int call _ZN6google8protobuf8internal14ArenaStringPtr3SetERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEPNS0_5ArenaE; google::protobuf::internal::ArenaStringPtr::Set(std::string const&,google::protobuf::Arena *) jmp short $+2 loc_BAE19: jmp short $+2 loc_BAE1B: mov rdi, [rsp+118h+var_80] add rdi, 28h ; '('; this call _ZN6google8protobuf8internal14ArenaStringPtr11InitDefaultEv; google::protobuf::internal::ArenaStringPtr::InitDefault(void) jmp short $+2 loc_BAE2E: mov rdi, [rsp+118h+var_58]; this call _ZNK6google8protobuf21MethodDescriptorProto25_internal_has_output_typeEv; google::protobuf::MethodDescriptorProto::_internal_has_output_type(void) mov [rsp+118h+var_E9], al jmp short $+2 loc_BAE41: mov al, [rsp+118h+var_E9] test al, 1 jnz short loc_BAE4B jmp short loc_BAE9C loc_BAE4B: mov rax, [rsp+118h+var_60] add rax, 28h ; '(' mov qword ptr [rsp+118h+var_100], rax mov rdi, [rsp+118h+var_58] call _ZNK6google8protobuf21MethodDescriptorProto21_internal_output_typeB5cxx11Ev; google::protobuf::MethodDescriptorProto::_internal_output_type(void) mov qword ptr [rsp+118h+var_F8], rax jmp short $+2 loc_BAE70: mov rdi, [rsp+118h+var_60]; this call _ZNK6google8protobuf11MessageLite21GetArenaForAllocationEv; google::protobuf::MessageLite::GetArenaForAllocation(void) mov qword ptr [rsp+118h+var_108], rax jmp short $+2 loc_BAE84: mov rdx, qword ptr [rsp+118h+var_108]; int mov rsi, qword ptr [rsp+118h+var_F8]; int mov rdi, qword ptr [rsp+118h+var_100]; int call _ZN6google8protobuf8internal14ArenaStringPtr3SetERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEPNS0_5ArenaE; google::protobuf::internal::ArenaStringPtr::Set(std::string const&,google::protobuf::Arena *) jmp short $+2 loc_BAE9A: jmp short $+2 loc_BAE9C: mov rdi, [rsp+118h+var_58]; this call _ZNK6google8protobuf21MethodDescriptorProto21_internal_has_optionsEv; google::protobuf::MethodDescriptorProto::_internal_has_options(void) mov [rsp+118h+var_109], al jmp short $+2 loc_BAEAF: mov al, [rsp+118h+var_109] test al, 1 jnz short loc_BAEB9 jmp short loc_BAF11 loc_BAEB9: mov edi, 50h ; 'P'; unsigned __int64 call __Znwm; operator new(ulong) mov [rsp+118h+var_118], rax jmp short $+2 loc_BAEC9: mov rdi, [rsp+118h+var_118]; this mov rax, [rsp+118h+var_58] mov rsi, [rax+30h]; google::protobuf::MethodOptions * call _ZN6google8protobuf13MethodOptionsC2ERKS1_; google::protobuf::MethodOptions::MethodOptions(google::protobuf::MethodOptions const&) jmp short $+2 loc_BAEE0: mov rcx, [rsp+118h+var_118] mov rax, [rsp+118h+var_60] mov [rax+30h], rcx jmp short loc_BAF11 mov rdi, [rsp+0]; void * mov rcx, rax mov eax, edx mov [rsp+arg_A8], rcx mov [rsp+arg_A4], eax call __ZdlPv; operator delete(void *) jmp short loc_BAF5B loc_BAF11: mov rax, [rsp+118h+var_80] mov rdi, rax add rdi, 10h add rdi, 28h ; '(' mov rsi, [rsp+118h+var_58] add rsi, 10h add rsi, 28h ; '(' mov rdx, rax add rdx, 10h add rdx, 29h ; ')' add rax, 10h add rax, 28h ; '(' sub rdx, rax add rdx, 1 call _memcpy add rsp, 118h retn loc_BAF5B: mov rdi, [rsp+arg_90]; this call _ZN6google8protobuf7MessageD2Ev; google::protobuf::Message::~Message() mov rdi, [rsp+arg_A8] call __Unwind_Resume
long long google::protobuf::MethodDescriptorProto::MethodDescriptorProto( google::protobuf::MethodDescriptorProto *this, const google::protobuf::MethodDescriptorProto *a2) { google::protobuf::MethodOptions *v3; // [rsp+0h] [rbp-118h] int v4; // [rsp+10h] [rbp-108h] int v5; // [rsp+20h] [rbp-F8h] int v6; // [rsp+30h] [rbp-E8h] int v7; // [rsp+40h] [rbp-D8h] int ArenaForAllocation; // [rsp+50h] [rbp-C8h] int v9; // [rsp+60h] [rbp-B8h] unsigned long long v10; // [rsp+F8h] [rbp-20h] google::protobuf::Message::Message(this); *(_QWORD *)this = &`vtable for'google::protobuf::MethodDescriptorProto + 2; *((_DWORD *)this + 4) = *((_DWORD *)a2 + 4); memset((char *)this + 20, 0LL, 4LL); google::protobuf::internal::CachedSize::CachedSize((google::protobuf::MethodDescriptorProto *)((char *)this + 20)); memset((char *)this + 24, 0LL, 8LL); memset((char *)this + 32, 0LL, 8LL); memset((char *)this + 40, 0LL, 8LL); *((_QWORD *)this + 6) = 0LL; *((_BYTE *)this + 56) = 0; *((_BYTE *)this + 57) = 0; if ( (*((_QWORD *)a2 + 1) & 1LL) != 0 ) { v10 = google::protobuf::internal::InternalMetadata::PtrValue<google::protobuf::internal::InternalMetadata::Container<google::protobuf::UnknownFieldSet>>((_QWORD *)a2 + 1) + 8; google::protobuf::internal::InternalMetadata::DoMergeFrom<google::protobuf::UnknownFieldSet>((char *)this + 8, v10); } google::protobuf::internal::ArenaStringPtr::InitDefault((google::protobuf::MethodDescriptorProto *)((char *)this + 24)); if ( (google::protobuf::MethodDescriptorProto::_internal_has_name(a2) & 1) != 0 ) { v9 = google::protobuf::MethodDescriptorProto::_internal_name[abi:cxx11]((long long)a2); ArenaForAllocation = google::protobuf::MessageLite::GetArenaForAllocation(this); google::protobuf::internal::ArenaStringPtr::Set((_DWORD)this + 24, v9, ArenaForAllocation); } google::protobuf::internal::ArenaStringPtr::InitDefault((google::protobuf::MethodDescriptorProto *)((char *)this + 32)); if ( (google::protobuf::MethodDescriptorProto::_internal_has_input_type(a2) & 1) != 0 ) { v7 = google::protobuf::MethodDescriptorProto::_internal_input_type[abi:cxx11]((long long)a2); v6 = google::protobuf::MessageLite::GetArenaForAllocation(this); google::protobuf::internal::ArenaStringPtr::Set((_DWORD)this + 32, v7, v6); } google::protobuf::internal::ArenaStringPtr::InitDefault((google::protobuf::MethodDescriptorProto *)((char *)this + 40)); if ( (google::protobuf::MethodDescriptorProto::_internal_has_output_type(a2) & 1) != 0 ) { v5 = google::protobuf::MethodDescriptorProto::_internal_output_type[abi:cxx11]((long long)a2); v4 = google::protobuf::MessageLite::GetArenaForAllocation(this); google::protobuf::internal::ArenaStringPtr::Set((_DWORD)this + 40, v5, v4); } if ( google::protobuf::MethodDescriptorProto::_internal_has_options(a2) ) { v3 = (google::protobuf::MethodOptions *)operator new(0x50uLL); google::protobuf::MethodOptions::MethodOptions(v3, *((const google::protobuf::MethodOptions **)a2 + 6)); *((_QWORD *)this + 6) = v3; } return memcpy((char *)this + 56, (char *)a2 + 56, 2LL); }
MethodDescriptorProto: SUB RSP,0x118 MOV qword ptr [RSP + 0xc8],RDI MOV qword ptr [RSP + 0xc0],RSI MOV RDI,qword ptr [RSP + 0xc8] MOV qword ptr [RSP + 0x98],RDI CALL 0x001d3f60 MOV RAX,qword ptr [RSP + 0x98] LEA RCX,[0x378490] ADD RCX,0x10 MOV qword ptr [RAX],RCX MOV qword ptr [RSP + 0xb8],RAX MOV RDI,RAX ADD RDI,0x10 MOV qword ptr [RSP + 0x90],RDI MOV RCX,qword ptr [RSP + 0xc0] MOV ECX,dword ptr [RCX + 0x10] MOV dword ptr [RAX + 0x10],ECX ADD RDI,0x4 MOV qword ptr [RSP + 0x88],RDI XOR ESI,ESI MOV EDX,0x4 CALL 0x00113200 MOV RDI,qword ptr [RSP + 0x88] CALL 0x001d3ff0 MOV RDI,qword ptr [RSP + 0x90] ADD RDI,0x8 XOR ESI,ESI MOV EDX,0x8 CALL 0x00113200 MOV RDI,qword ptr [RSP + 0x90] ADD RDI,0x10 XOR ESI,ESI MOV EDX,0x8 CALL 0x00113200 MOV RDI,qword ptr [RSP + 0x90] ADD RDI,0x18 XOR ESI,ESI MOV EDX,0x8 CALL 0x00113200 MOV RCX,qword ptr [RSP + 0x98] MOV qword ptr [RCX + 0x30],0x0 MOV byte ptr [RCX + 0x38],0x0 MOV byte ptr [RCX + 0x39],0x0 ADD RCX,0x8 MOV RAX,qword ptr [RSP + 0xc0] ADD RAX,0x8 MOV qword ptr [RSP + 0xd8],RCX MOV qword ptr [RSP + 0xd0],RAX MOV RAX,qword ptr [RSP + 0xd8] MOV qword ptr [RSP + 0xa0],RAX MOV RAX,qword ptr [RSP + 0xd0] MOV qword ptr [RSP + 0xe0],RAX MOV RAX,qword ptr [RSP + 0xe0] MOV qword ptr [RSP + 0x110],RAX MOV RAX,qword ptr [RSP + 0x110] MOV RAX,qword ptr [RAX] AND RAX,0x1 CMP RAX,0x0 SETNZ AL MOV byte ptr [RSP + 0xab],AL MOV AL,byte ptr [RSP + 0xab] TEST AL,0x1 JNZ 0x001bac49 JMP 0x001bacfe LAB_001bac49: MOV RAX,qword ptr [RSP + 0xd0] MOV qword ptr [RSP + 0xf0],RAX MOV qword ptr [RSP + 0xe8],0x0 MOV RAX,qword ptr [RSP + 0xf0] MOV qword ptr [RSP + 0x80],RAX MOV qword ptr [RSP + 0x100],RAX MOV RAX,qword ptr [RSP + 0x100] MOV qword ptr [RSP + 0x108],RAX MOV RAX,qword ptr [RSP + 0x108] MOV RAX,qword ptr [RAX] AND RAX,0x1 CMP RAX,0x0 JZ 0x001bacbd MOV RDI,qword ptr [RSP + 0x80] CALL 0x0019cd40 ADD RAX,0x8 MOV qword ptr [RSP + 0xf8],RAX JMP 0x001bacdb LAB_001bacbd: MOV RAX,qword ptr [RSP + 0xe8] LAB_001bacc5: CALL RAX MOV qword ptr [RSP + 0x78],RAX JMP 0x001bacce LAB_001bacce: MOV RAX,qword ptr [RSP + 0x78] MOV qword ptr [RSP + 0xf8],RAX LAB_001bacdb: MOV RAX,qword ptr [RSP + 0xf8] MOV qword ptr [RSP + 0x70],RAX MOV RSI,qword ptr [RSP + 0x70] MOV RDI,qword ptr [RSP + 0xa0] CALL 0x001e0920 JMP 0x001bacfc LAB_001bacfc: JMP 0x001bacfe LAB_001bacfe: JMP 0x001bad00 LAB_001bad00: MOV RDI,qword ptr [RSP + 0x98] ADD RDI,0x18 CALL 0x001d4b40 JMP 0x001bad13 LAB_001bad13: MOV RDI,qword ptr [RSP + 0xc0] CALL 0x001d8d60 MOV byte ptr [RSP + 0x6f],AL JMP 0x001bad26 LAB_001bad26: MOV AL,byte ptr [RSP + 0x6f] TEST AL,0x1 JNZ 0x001bad30 JMP 0x001bad9a LAB_001bad30: MOV RAX,qword ptr [RSP + 0xb8] ADD RAX,0x18 MOV qword ptr [RSP + 0x58],RAX MOV RDI,qword ptr [RSP + 0xc0] CALL 0x00188f00 MOV qword ptr [RSP + 0x60],RAX JMP 0x001bad55 LAB_001bad55: MOV RDI,qword ptr [RSP + 0xb8] CALL 0x00180180 MOV qword ptr [RSP + 0x50],RAX JMP 0x001bad69 LAB_001bad69: MOV RDX,qword ptr [RSP + 0x50] MOV RSI,qword ptr [RSP + 0x60] MOV RDI,qword ptr [RSP + 0x58] CALL 0x00283680 JMP 0x001bad7f LAB_001bad7f: JMP 0x001bad9a LAB_001bad9a: MOV RDI,qword ptr [RSP + 0x98] ADD RDI,0x20 CALL 0x001d4b40 JMP 0x001badad LAB_001badad: MOV RDI,qword ptr [RSP + 0xc0] CALL 0x001d8da0 MOV byte ptr [RSP + 0x4f],AL JMP 0x001badc0 LAB_001badc0: MOV AL,byte ptr [RSP + 0x4f] TEST AL,0x1 JNZ 0x001badca JMP 0x001bae1b LAB_001badca: MOV RAX,qword ptr [RSP + 0xb8] ADD RAX,0x20 MOV qword ptr [RSP + 0x38],RAX MOV RDI,qword ptr [RSP + 0xc0] CALL 0x00189180 MOV qword ptr [RSP + 0x40],RAX JMP 0x001badef LAB_001badef: MOV RDI,qword ptr [RSP + 0xb8] CALL 0x00180180 MOV qword ptr [RSP + 0x30],RAX JMP 0x001bae03 LAB_001bae03: MOV RDX,qword ptr [RSP + 0x30] MOV RSI,qword ptr [RSP + 0x40] MOV RDI,qword ptr [RSP + 0x38] CALL 0x00283680 JMP 0x001bae19 LAB_001bae19: JMP 0x001bae1b LAB_001bae1b: MOV RDI,qword ptr [RSP + 0x98] ADD RDI,0x28 CALL 0x001d4b40 JMP 0x001bae2e LAB_001bae2e: MOV RDI,qword ptr [RSP + 0xc0] CALL 0x001d8de0 MOV byte ptr [RSP + 0x2f],AL JMP 0x001bae41 LAB_001bae41: MOV AL,byte ptr [RSP + 0x2f] TEST AL,0x1 JNZ 0x001bae4b JMP 0x001bae9c LAB_001bae4b: MOV RAX,qword ptr [RSP + 0xb8] ADD RAX,0x28 MOV qword ptr [RSP + 0x18],RAX MOV RDI,qword ptr [RSP + 0xc0] CALL 0x001891b0 MOV qword ptr [RSP + 0x20],RAX JMP 0x001bae70 LAB_001bae70: MOV RDI,qword ptr [RSP + 0xb8] CALL 0x00180180 MOV qword ptr [RSP + 0x10],RAX JMP 0x001bae84 LAB_001bae84: MOV RDX,qword ptr [RSP + 0x10] MOV RSI,qword ptr [RSP + 0x20] MOV RDI,qword ptr [RSP + 0x18] CALL 0x00283680 JMP 0x001bae9a LAB_001bae9a: JMP 0x001bae9c LAB_001bae9c: MOV RDI,qword ptr [RSP + 0xc0] CALL 0x00188f30 MOV byte ptr [RSP + 0xf],AL JMP 0x001baeaf LAB_001baeaf: MOV AL,byte ptr [RSP + 0xf] TEST AL,0x1 JNZ 0x001baeb9 JMP 0x001baf11 LAB_001baeb9: MOV EDI,0x50 CALL 0x00113450 MOV qword ptr [RSP],RAX JMP 0x001baec9 LAB_001baec9: MOV RDI,qword ptr [RSP] MOV RAX,qword ptr [RSP + 0xc0] MOV RSI,qword ptr [RAX + 0x30] LAB_001baed9: CALL 0x001c7380 LAB_001baede: JMP 0x001baee0 LAB_001baee0: MOV RCX,qword ptr [RSP] MOV RAX,qword ptr [RSP + 0xb8] MOV qword ptr [RAX + 0x30],RCX JMP 0x001baf11 LAB_001baf11: MOV RAX,qword ptr [RSP + 0x98] MOV RDI,RAX ADD RDI,0x10 ADD RDI,0x28 MOV RSI,qword ptr [RSP + 0xc0] ADD RSI,0x10 ADD RSI,0x28 MOV RDX,RAX ADD RDX,0x10 ADD RDX,0x29 ADD RAX,0x10 ADD RAX,0x28 SUB RDX,RAX ADD RDX,0x1 CALL 0x00113390 ADD RSP,0x118 RET
/* google::protobuf::MethodDescriptorProto::MethodDescriptorProto(google::protobuf::MethodDescriptorProto const&) */ void __thiscall google::protobuf::MethodDescriptorProto::MethodDescriptorProto (MethodDescriptorProto *this,MethodDescriptorProto *param_1) { byte bVar1; InternalMetadata *this_00; string *psVar2; Arena *pAVar3; MethodOptions *this_01; UnknownFieldSet *local_20; Message::Message((Message *)this); *(int ***)this = &PTR__MethodDescriptorProto_003784a0; *(int4 *)(this + 0x10) = *(int4 *)(param_1 + 0x10); memset((CachedSize *)(this + 0x14),0,4); internal::CachedSize::CachedSize((CachedSize *)(this + 0x14)); memset(this + 0x18,0,8); memset(this + 0x20,0,8); memset(this + 0x28,0,8); *(int8 *)(this + 0x30) = 0; this[0x38] = (MethodDescriptorProto)0x0; this[0x39] = (MethodDescriptorProto)0x0; this_00 = (InternalMetadata *)(param_1 + 8); if ((*(ulong *)this_00 & 1) != 0) { if ((*(ulong *)this_00 & 1) == 0) { /* try { // try from 001bacc5 to 001baec2 has its CatchHandler @ 001bad81 */ local_20 = (UnknownFieldSet *)(*(code *)0x0)(); } else { local_20 = (UnknownFieldSet *) internal::InternalMetadata:: PtrValue<google::protobuf::internal::InternalMetadata::Container<google::protobuf::UnknownFieldSet>> (this_00); local_20 = (UnknownFieldSet *)((Container *)local_20 + 8); } internal::InternalMetadata::DoMergeFrom<google::protobuf::UnknownFieldSet> ((InternalMetadata *)(this + 8),local_20); } internal::ArenaStringPtr::InitDefault((ArenaStringPtr *)(this + 0x18)); bVar1 = _internal_has_name(param_1); if ((bVar1 & 1) != 0) { psVar2 = (string *)_internal_name_abi_cxx11_(param_1); pAVar3 = (Arena *)MessageLite::GetArenaForAllocation((MessageLite *)this); internal::ArenaStringPtr::Set((ArenaStringPtr *)(this + 0x18),psVar2,pAVar3); } internal::ArenaStringPtr::InitDefault((ArenaStringPtr *)(this + 0x20)); bVar1 = _internal_has_input_type(param_1); if ((bVar1 & 1) != 0) { psVar2 = (string *)_internal_input_type_abi_cxx11_(param_1); pAVar3 = (Arena *)MessageLite::GetArenaForAllocation((MessageLite *)this); internal::ArenaStringPtr::Set((ArenaStringPtr *)(this + 0x20),psVar2,pAVar3); } internal::ArenaStringPtr::InitDefault((ArenaStringPtr *)(this + 0x28)); bVar1 = _internal_has_output_type(param_1); if ((bVar1 & 1) != 0) { psVar2 = (string *)_internal_output_type_abi_cxx11_(param_1); pAVar3 = (Arena *)MessageLite::GetArenaForAllocation((MessageLite *)this); internal::ArenaStringPtr::Set((ArenaStringPtr *)(this + 0x28),psVar2,pAVar3); } bVar1 = _internal_has_options(param_1); if ((bVar1 & 1) != 0) { this_01 = (MethodOptions *)operator_new(0x50); /* try { // try from 001baed9 to 001baedd has its CatchHandler @ 001baef2 */ MethodOptions::MethodOptions(this_01,*(MethodOptions **)(param_1 + 0x30)); *(MethodOptions **)(this + 0x30) = this_01; } memcpy(this + 0x38,param_1 + 0x38,2); return; }
20,583
malloc_debug
seiftnesse[P]memoryallocator/src/custom_alloc_debug.c
void *_malloc_debug(size_t size, const char *file, int line) { HEAP_LOG("Debug malloc: size=%zu, file=%s, line=%d\n", size, file ? file : "unknown", line); void *ptr = _malloc(size); if (ptr && !is_small_allocation(ptr) && track_allocations) { segment_t *s = PtrToSegment(ptr); s->allocation_file = file; s->allocation_line = line; HEAP_LOG("Debug info recorded for allocation: %p, id=%u\n", ptr, s->allocation_id); } return ptr; }
O3
c
malloc_debug: pushq %r15 pushq %r14 pushq %rbx movl %edx, %ebx movq %rsi, %r14 callq 0x334f movq %rax, %r15 testq %rax, %rax je 0x42e5 movq %r15, %rdi callq 0x39f3 testl %eax, %eax jne 0x42e5 cmpl $0x0, 0x4104ea0(%rip) # 0x4109174 je 0x42e5 movq %r15, %rdi callq 0x3bbc movq %r14, 0x18(%rax) movl %ebx, 0x20(%rax) movq %r15, %rax popq %rbx popq %r14 popq %r15 retq
_malloc_debug: push r15 push r14 push rbx mov ebx, edx mov r14, rsi call _malloc mov r15, rax test rax, rax jz short loc_42E5 mov rdi, r15 call is_small_allocation test eax, eax jnz short loc_42E5 cmp cs:track_allocations, 0 jz short loc_42E5 mov rdi, r15 call PtrToSegment mov [rax+18h], r14 mov [rax+20h], ebx loc_42E5: mov rax, r15 pop rbx pop r14 pop r15 retn
long long malloc_debug(unsigned long long a1, long long a2, int a3) { unsigned long long v4; // rax long long v5; // r15 unsigned long long v6; // rax v4 = malloc(a1); v5 = v4; if ( v4 && !(unsigned int)is_small_allocation(v4) && track_allocations ) { v6 = PtrToSegment(v5); *(_QWORD *)(v6 + 24) = a2; *(_DWORD *)(v6 + 32) = a3; } return v5; }
_malloc_debug: PUSH R15 PUSH R14 PUSH RBX MOV EBX,EDX MOV R14,RSI CALL 0x0010334f MOV R15,RAX TEST RAX,RAX JZ 0x001042e5 MOV RDI,R15 CALL 0x001039f3 TEST EAX,EAX JNZ 0x001042e5 CMP dword ptr [0x04209174],0x0 JZ 0x001042e5 MOV RDI,R15 CALL 0x00103bbc MOV qword ptr [RAX + 0x18],R14 MOV dword ptr [RAX + 0x20],EBX LAB_001042e5: MOV RAX,R15 POP RBX POP R14 POP R15 RET
void * _malloc_debug(size_t param_1,int8 param_2,int4 param_3) { int iVar1; void *pvVar2; long lVar3; pvVar2 = _malloc(param_1); if (pvVar2 != (void *)0x0) { iVar1 = is_small_allocation(pvVar2); if ((iVar1 == 0) && (track_allocations != 0)) { lVar3 = PtrToSegment(pvVar2); *(int8 *)(lVar3 + 0x18) = param_2; *(int4 *)(lVar3 + 0x20) = param_3; } } return pvVar2; }
20,584
main
eloqsql/storage/maria/unittest/ma_pagecache_single.c
int main(int argc __attribute__((unused)), char **argv __attribute__((unused))) { pthread_t tid; pthread_attr_t thr_attr; int *param, error; size_t pagen; File tmp_file; MY_INIT(argv[0]); #ifndef DBUG_OFF #if defined(_WIN32) default_dbug_option= "d:t:i:O,\\test_pagecache_single.trace"; #else default_dbug_option= "d:t:i:o,/tmp/test_pagecache_single.trace"; #endif if (argc > 1) { DBUG_SET(default_dbug_option); DBUG_SET_INITIAL(default_dbug_option); } #endif { DBUG_ENTER("main"); DBUG_PRINT("info", ("Main thread: %s\n", my_thread_name())); plan(18); SKIP_BIG_TESTS(18) { char *test_dirname= create_tmpdir(argv[0]); fn_format(file1_name, base_file1_name, test_dirname, "", MYF(0)); fn_format(file2_name, base_file2_name, test_dirname, "", MYF(0)); if ((tmp_file= my_open(file2_name, O_CREAT | O_TRUNC | O_RDWR, MYF(MY_WME))) < 0) exit(1); if ((file1.file= my_open(file1_name, O_CREAT | O_TRUNC | O_RDWR, MYF(0))) == -1) { fprintf(stderr, "Got error during file1 creation from open() (errno: %d)\n", errno); exit(1); } pagecache_file_set_null_hooks(&file1); my_close(tmp_file, MYF(0)); my_delete(file2_name, MYF(0)); DBUG_PRINT("info", ("file1: %d", file1.file)); if (my_chmod(file1_name, 0777, MYF(MY_WME))) exit(1); my_pwrite(file1.file, (const uchar*)"test file", 9, 0, MYF(MY_WME)); if ((error= pthread_cond_init(&COND_thread_count, NULL))) { fprintf(stderr, "Got error: %d from pthread_cond_init (errno: %d)\n", error, errno); exit(1); } if ((error= pthread_mutex_init(&LOCK_thread_count, MY_MUTEX_INIT_FAST))) { fprintf(stderr, "Got error: %d from pthread_cond_init (errno: %d)\n", error, errno); exit(1); } if ((error= pthread_attr_init(&thr_attr))) { fprintf(stderr,"Got error: %d from pthread_attr_init (errno: %d)\n", error,errno); exit(1); } if ((error= pthread_attr_setdetachstate(&thr_attr, PTHREAD_CREATE_DETACHED))) { fprintf(stderr, "Got error: %d from pthread_attr_setdetachstate (errno: %d)\n", error,errno); exit(1); } #ifdef HAVE_THR_SETCONCURRENCY thr_setconcurrency(2); #endif if ((pagen= init_pagecache(&pagecache, PCACHE_SIZE, 0, 0, TEST_PAGE_SIZE, 0, MYF(MY_WME))) == 0) { fprintf(stderr,"Got error: init_pagecache() (errno: %d)\n", errno); exit(1); } DBUG_PRINT("info", ("Page cache %zd pages", pagen)); pthread_mutex_lock(&LOCK_thread_count); param=(int*) malloc(sizeof(int)); *param= 1; if ((error= pthread_create(&tid, &thr_attr, test_thread, (void*) param))) { fprintf(stderr,"Got error: %d from pthread_create (errno: %d)\n", error,errno); exit(1); } thread_count++; DBUG_PRINT("info", ("Thread started")); pthread_mutex_unlock(&LOCK_thread_count); pthread_attr_destroy(&thr_attr); pthread_mutex_lock(&LOCK_thread_count); while (thread_count) { if ((error= pthread_cond_wait(&COND_thread_count,&LOCK_thread_count))) fprintf(stderr,"Got error: %d from pthread_cond_wait\n",error); } pthread_mutex_unlock(&LOCK_thread_count); DBUG_PRINT("info", ("thread ended")); end_pagecache(&pagecache, 1); DBUG_PRINT("info", ("Page cache ended")); if (my_close(file1.file, MYF(MY_WME))) exit(1); my_delete(file1_name, MYF(0)); rmdir(test_dirname); } /* SKIP_BIG_TESTS */ DBUG_PRINT("info", ("file1 (%d) closed", file1.file)); DBUG_PRINT("info", ("Program end")); my_end(0); } return exit_status(); }
O3
c
main: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r12 pushq %rbx subq $0x220, %rsp # imm = 0x220 movq %rsi, %rbx movq %fs:0x28, %rax movq %rax, -0x28(%rbp) movq (%rsi), %rax leaq 0xbd89a5(%rip), %rcx # 0xc0a050 movq %rax, (%rcx) callq 0xa026c movl $0x12, %edi callq 0x920e7 leaq 0x3560d4(%rip), %rax # 0x387798 cmpl $0x0, (%rax) je 0x316e1 leaq 0xa8f45(%rip), %rsi # 0xda615 movl $0x12, %edi xorl %eax, %eax callq 0x924ad jmp 0x319cf movq (%rbx), %rsi leaq 0xafa0e(%rip), %rcx # 0xe10f9 leaq -0x230(%rbp), %rbx movq %rbx, %rdi movq %rcx, %rdx movl $0x3, %r8d callq 0x95900 movq %rbx, %rdi callq 0x29350 cmpq $0x3, %rax jb 0x31727 cmpb $0x2d, -0x2(%rax,%rbx) jne 0x31727 cmpb $0x74, -0x1(%rax,%rbx) jne 0x31727 movb $0x0, -0x232(%rbp,%rax) leaq 0x3cd402(%rip), %rbx # 0x3feb30 leaq 0xa904a(%rip), %rsi # 0xda77f leaq -0x230(%rbp), %rdx movq %rbx, %rdi xorl %ecx, %ecx xorl %eax, %eax callq 0xd815c movq %rbx, %rdi movl $0x1ff, %esi # imm = 0x1FF xorl %edx, %edx callq 0xa10c0 leaq 0x3ccf72(%rip), %rdi # 0x3fe6d0 leaq 0xa901f(%rip), %rsi # 0xda784 leaq 0xaf98d(%rip), %r14 # 0xe10f9 movq %rbx, %rdx movq %r14, %rcx xorl %r8d, %r8d callq 0x95900 leaq 0x3cd14f(%rip), %r15 # 0x3fe8d0 leaq 0xa9013(%rip), %rsi # 0xda79b movq %r15, %rdi movq %rbx, %rdx movq %r14, %rcx xorl %r8d, %r8d callq 0x95900 movl $0x10, %edx movq %r15, %rdi movl $0x242, %esi # imm = 0x242 callq 0xa130c testl %eax, %eax js 0x31ac8 movl %eax, %ebx leaq 0x3ccf14(%rip), %rdi # 0x3fe6d0 movl $0x242, %esi # imm = 0x242 xorl %edx, %edx callq 0xa130c movl %eax, 0x3ccec2(%rip) # 0x3fe690 cmpl $-0x1, %eax je 0x31a1f leaq 0x3ccea2(%rip), %rdi # 0x3fe680 callq 0x35a53 movl %ebx, %edi xorl %esi, %esi callq 0xa14b1 leaq 0x3cd0dd(%rip), %rdi # 0x3fe8d0 xorl %esi, %esi callq 0x9ee8c leaq 0x3ccecf(%rip), %rdi # 0x3fe6d0 movl $0x10, %edx movl $0x1ff, %esi # imm = 0x1FF callq 0xa7154 testl %eax, %eax jne 0x31ac8 movl 0x3cce72(%rip), %edi # 0x3fe690 leaq 0xa8e32(%rip), %rsi # 0xda657 movl $0x9, %edx movl $0x10, %r8d xorl %ecx, %ecx callq 0xa171a leaq 0x3cd292(%rip), %rdi # 0x3fead0 xorl %esi, %esi callq 0x29380 testl %eax, %eax jne 0x319ff leaq 0x3cd2ac(%rip), %rdi # 0x3feb00 leaq 0xbd9485(%rip), %rsi # 0xc0ace0 callq 0x29340 testl %eax, %eax jne 0x319ff leaq -0x230(%rbp), %rdi callq 0x29140 testl %eax, %eax jne 0x31a39 leaq -0x230(%rbp), %rdi movl $0x1, %esi callq 0x29660 testl %eax, %eax jne 0x31a56 movq $0x10, (%rsp) leaq 0x3ccbbc(%rip), %rdi # 0x3fe460 movl $0x5000000, %esi # imm = 0x5000000 xorl %edx, %edx xorl %ecx, %ecx movl $0x2000, %r8d # imm = 0x2000 xorl %r9d, %r9d callq 0x31d34 testq %rax, %rax je 0x31a73 leaq 0x3cd235(%rip), %rdi # 0x3feb00 callq 0x29220 movl $0x4, %edi callq 0x29710 movl $0x1, (%rax) leaq 0x1eb(%rip), %rdx # 0x31ad2 leaq -0x238(%rbp), %rdi leaq -0x230(%rbp), %rsi movq %rax, %rcx callq 0x298e0 testl %eax, %eax jne 0x31a9c incl 0x3cd21d(%rip) # 0x3feb28 leaq 0x3cd1ee(%rip), %rbx # 0x3feb00 movq %rbx, %rdi callq 0x291e0 leaq -0x230(%rbp), %rdi callq 0x295a0 movq %rbx, %rdi callq 0x29220 cmpl $0x0, 0x3cd1f3(%rip) # 0x3feb28 je 0x31980 leaq 0x3cd192(%rip), %rbx # 0x3fead0 leaq 0x3cd1bb(%rip), %r14 # 0x3feb00 movq 0x354664(%rip), %r12 # 0x385fb0 leaq 0xa8e06(%rip), %r15 # 0xda759 movq %rbx, %rdi movq %r14, %rsi callq 0x29430 testl %eax, %eax je 0x31977 movq (%r12), %rdi movl $0x1, %esi movq %r15, %rdx movl %eax, %ecx xorl %eax, %eax callq 0x29200 cmpl $0x0, 0x3cd1aa(%rip) # 0x3feb28 jne 0x31953 leaq 0x3cd179(%rip), %rdi # 0x3feb00 callq 0x291e0 leaq 0x3ccacd(%rip), %rdi # 0x3fe460 movl $0x1, %esi callq 0x324af movl 0x3ccced(%rip), %edi # 0x3fe690 movl $0x10, %esi callq 0xa14b1 testl %eax, %eax jne 0x31ac8 leaq 0x3ccd14(%rip), %rdi # 0x3fe6d0 xorl %esi, %esi callq 0x9ee8c leaq 0x3cd166(%rip), %rdi # 0x3feb30 callq 0x29370 xorl %edi, %edi callq 0xa0407 callq 0x926d7 movq %fs:0x28, %rcx cmpq -0x28(%rbp), %rcx jne 0x319fa addq $0x220, %rsp # imm = 0x220 popq %rbx popq %r12 popq %r14 popq %r15 popq %rbp retq callq 0x29270 movl %eax, %ebx movq 0x3545a8(%rip), %rax # 0x385fb0 movq (%rax), %r14 callq 0x297b0 movl (%rax), %r8d leaq 0xa8c47(%rip), %rdx # 0xda661 jmp 0x31ab7 movq 0x35458a(%rip), %rax # 0x385fb0 movq (%rax), %rbx callq 0x297b0 movl (%rax), %ecx leaq 0xa8be7(%rip), %rdx # 0xda61e jmp 0x31a8b movl %eax, %ebx movq 0x35456e(%rip), %rax # 0x385fb0 movq (%rax), %r14 callq 0x297b0 movl (%rax), %r8d leaq 0xa8c3f(%rip), %rdx # 0xda693 jmp 0x31ab7 movl %eax, %ebx movq 0x354551(%rip), %rax # 0x385fb0 movq (%rax), %r14 callq 0x297b0 movl (%rax), %r8d leaq 0xa8c54(%rip), %rdx # 0xda6c5 jmp 0x31ab7 movq 0x354536(%rip), %rax # 0x385fb0 movq (%rax), %rbx callq 0x297b0 movl (%rax), %ecx leaq 0xa8c76(%rip), %rdx # 0xda701 movq %rbx, %rdi movl $0x1, %esi xorl %eax, %eax callq 0x29200 jmp 0x31ac8 movl %eax, %ebx movq 0x35450b(%rip), %rax # 0x385fb0 movq (%rax), %r14 callq 0x297b0 movl (%rax), %r8d leaq 0xa8c73(%rip), %rdx # 0xda72a movq %r14, %rdi movl $0x1, %esi movl %ebx, %ecx xorl %eax, %eax callq 0x29200 movl $0x1, %edi callq 0x29540
main: push rbp mov rbp, rsp push r15 push r14 push r12 push rbx sub rsp, 220h mov rbx, rsi mov rax, fs:28h mov [rbp+var_28], rax mov rax, [rsi] lea rcx, my_progname mov [rcx], rax call my_init mov edi, 12h call plan lea rax, skip_big_tests cmp dword ptr [rax], 0 jz short loc_316E1 lea rsi, aBigTest; "big test" mov edi, 12h xor eax, eax call skip jmp loc_319CF loc_316E1: mov rsi, [rbx] lea rcx, asc_E10F5+4; "" lea rbx, [rbp+var_230] mov rdi, rbx mov rdx, rcx mov r8d, 3 call fn_format mov rdi, rbx call _strlen cmp rax, 3 jb short loc_31727 cmp byte ptr [rax+rbx-2], 2Dh ; '-' jnz short loc_31727 cmp byte ptr [rax+rbx-1], 74h ; 't' jnz short loc_31727 mov [rbp+rax+var_232], 0 loc_31727: lea rbx, create_tmpdir_test_dirname lea rsi, aTmp; "TMP-" lea rdx, [rbp+var_230] mov rdi, rbx xor ecx, ecx xor eax, eax call strxmov mov rdi, rbx mov esi, 1FFh xor edx, edx call my_mkdir lea rdi, file1_name lea rsi, aPageCacheTestF; "page_cache_test_file_1" lea r14, asc_E10F5+4; "" mov rdx, rbx mov rcx, r14 xor r8d, r8d call fn_format lea r15, file2_name lea rsi, aPageCacheTestF_0; "page_cache_test_file_2" mov rdi, r15 mov rdx, rbx mov rcx, r14 xor r8d, r8d call fn_format mov edx, 10h mov rdi, r15 mov esi, 242h call my_open test eax, eax js loc_31AC8 mov ebx, eax lea rdi, file1_name mov esi, 242h xor edx, edx call my_open mov cs:dword_3FE690, eax cmp eax, 0FFFFFFFFh jz loc_31A1F lea rdi, file1 call pagecache_file_set_null_hooks mov edi, ebx xor esi, esi call my_close lea rdi, file2_name xor esi, esi call my_delete lea rdi, file1_name mov edx, 10h mov esi, 1FFh call my_chmod test eax, eax jnz loc_31AC8 mov edi, cs:dword_3FE690 lea rsi, aTestFile; "test file" mov edx, 9 mov r8d, 10h xor ecx, ecx call my_pwrite lea rdi, COND_thread_count xor esi, esi call _pthread_cond_init test eax, eax jnz loc_319FF lea rdi, LOCK_thread_count lea rsi, my_fast_mutexattr call _pthread_mutex_init test eax, eax jnz loc_319FF lea rdi, [rbp+var_230] call _pthread_attr_init test eax, eax jnz loc_31A39 lea rdi, [rbp+var_230] mov esi, 1 call _pthread_attr_setdetachstate test eax, eax jnz loc_31A56 mov [rsp+240h+var_240], 10h lea rdi, pagecache mov esi, 5000000h xor edx, edx xor ecx, ecx mov r8d, 2000h xor r9d, r9d call init_pagecache test rax, rax jz loc_31A73 lea rdi, LOCK_thread_count call _pthread_mutex_lock mov edi, 4 call _malloc mov dword ptr [rax], 1 lea rdx, test_thread lea rdi, [rbp+var_238] lea rsi, [rbp+var_230] mov rcx, rax call _pthread_create test eax, eax jnz loc_31A9C inc cs:thread_count lea rbx, LOCK_thread_count mov rdi, rbx call _pthread_mutex_unlock lea rdi, [rbp+var_230] call _pthread_attr_destroy mov rdi, rbx call _pthread_mutex_lock cmp cs:thread_count, 0 jz short loc_31980 lea rbx, COND_thread_count lea r14, LOCK_thread_count mov r12, cs:stderr_ptr lea r15, aGotErrorDFromP; "Got error: %d from pthread_cond_wait\n" loc_31953: mov rdi, rbx mov rsi, r14 call _pthread_cond_wait test eax, eax jz short loc_31977 mov rdi, [r12] mov esi, 1 mov rdx, r15 mov ecx, eax xor eax, eax call ___fprintf_chk loc_31977: cmp cs:thread_count, 0 jnz short loc_31953 loc_31980: lea rdi, LOCK_thread_count call _pthread_mutex_unlock lea rdi, pagecache mov esi, 1 call end_pagecache mov edi, cs:dword_3FE690 mov esi, 10h call my_close test eax, eax jnz loc_31AC8 lea rdi, file1_name xor esi, esi call my_delete lea rdi, create_tmpdir_test_dirname call _rmdir loc_319CF: xor edi, edi call my_end call exit_status mov rcx, fs:28h cmp rcx, [rbp+var_28] jnz short loc_319FA add rsp, 220h pop rbx pop r12 pop r14 pop r15 pop rbp retn loc_319FA: call ___stack_chk_fail loc_319FF: mov ebx, eax mov rax, cs:stderr_ptr mov r14, [rax] call ___errno_location mov r8d, [rax] lea rdx, aGotErrorDFromP_0; "Got error: %d from pthread_cond_init (e"... jmp loc_31AB7 loc_31A1F: mov rax, cs:stderr_ptr mov rbx, [rax] call ___errno_location mov ecx, [rax] lea rdx, aGotErrorDuring_2; "Got error during file1 creation from op"... jmp short loc_31A8B loc_31A39: mov ebx, eax mov rax, cs:stderr_ptr mov r14, [rax] call ___errno_location mov r8d, [rax] lea rdx, aGotErrorDFromP_1; "Got error: %d from pthread_attr_init (e"... jmp short loc_31AB7 loc_31A56: mov ebx, eax mov rax, cs:stderr_ptr mov r14, [rax] call ___errno_location mov r8d, [rax] lea rdx, aGotErrorDFromP_2; "Got error: %d from pthread_attr_setdeta"... jmp short loc_31AB7 loc_31A73: mov rax, cs:stderr_ptr mov rbx, [rax] call ___errno_location mov ecx, [rax] lea rdx, aGotErrorInitPa; "Got error: init_pagecache() (errno: %d)"... loc_31A8B: mov rdi, rbx mov esi, 1 xor eax, eax call ___fprintf_chk jmp short loc_31AC8 loc_31A9C: mov ebx, eax mov rax, cs:stderr_ptr mov r14, [rax] call ___errno_location mov r8d, [rax] lea rdx, aGotErrorDFromP_3; "Got error: %d from pthread_create (errn"... loc_31AB7: mov rdi, r14 mov esi, 1 mov ecx, ebx xor eax, eax call ___fprintf_chk loc_31AC8: mov edi, 1 call _exit
int main(int argc, const char **argv, const char **envp) { int v3; // edx int v4; // ecx int v5; // r8d int v6; // r9d unsigned long long v7; // rax int v8; // r8d int v9; // r9d int v10; // eax unsigned int v11; // ebx void *v12; // rdi unsigned int v13; // eax unsigned int v14; // eax unsigned int v15; // eax _DWORD *v16; // rax unsigned int v17; // eax int v18; // eax unsigned int v20; // ebx long long v21; // r14 long long v22; // r8 long long v23; // rbx long long v24; // rcx unsigned int v25; // ebx long long v26; // r14 long long v27; // r8 unsigned int v28; // ebx long long v29; // r14 long long v30; // r8 long long v31; // rbx long long v32; // rcx unsigned int v33; // ebx long long v34; // r14 long long v35; // r8 _BYTE v36[8]; // [rsp+8h] [rbp-238h] BYREF _BYTE v37[520]; // [rsp+10h] [rbp-230h] BYREF unsigned long long v38; // [rsp+218h] [rbp-28h] v38 = __readfsqword(0x28u); my_progname = *argv; my_init(argc, argv, envp); plan(18LL); if ( !skip_big_tests ) { fn_format(v37, *argv, "", "", 3LL); v7 = strlen(v37); if ( v7 >= 3 && v37[v7 - 2] == 45 && v37[v7 - 1] == 116 ) v36[v7 + 6] = 0; strxmov((unsigned int)&create_tmpdir_test_dirname, (unsigned int)"TMP-", (unsigned int)v37, 0, v8, v9); my_mkdir(&create_tmpdir_test_dirname, 511LL, 0LL); fn_format(&file1_name, "page_cache_test_file_1", &create_tmpdir_test_dirname, "", 0LL); fn_format(&file2_name, "page_cache_test_file_2", &create_tmpdir_test_dirname, "", 0LL); v10 = my_open(&file2_name, 578LL, 16LL); if ( v10 >= 0 ) { v11 = v10; dword_3FE690 = my_open(&file1_name, 578LL, 0LL); if ( dword_3FE690 == -1 ) { v23 = stderr; v24 = *(unsigned int *)__errno_location(&file1_name); __fprintf_chk(v23, 1LL, "Got error during file1 creation from open() (errno: %d)\n", v24); } else { pagecache_file_set_null_hooks(&file1); my_close(v11, 0LL); my_delete(&file2_name, 0LL); if ( !(unsigned int)my_chmod(&file1_name, 511LL, 16LL) ) { my_pwrite((unsigned int)dword_3FE690, "test file", 9LL, 0LL, 16LL); v12 = &COND_thread_count; v13 = pthread_cond_init(&COND_thread_count, 0LL); if ( v13 || (v12 = &LOCK_thread_count, (v13 = pthread_mutex_init(&LOCK_thread_count, &my_fast_mutexattr)) != 0) ) { v20 = v13; v21 = stderr; v22 = *(unsigned int *)__errno_location(v12); __fprintf_chk(v21, 1LL, "Got error: %d from pthread_cond_init (errno: %d)\n", v20, v22); } else { v14 = pthread_attr_init(v37); if ( v14 ) { v25 = v14; v26 = stderr; v27 = *(unsigned int *)__errno_location(v37); __fprintf_chk(v26, 1LL, "Got error: %d from pthread_attr_init (errno: %d)\n", v25, v27); } else { v15 = pthread_attr_setdetachstate(v37, 1LL); if ( v15 ) { v28 = v15; v29 = stderr; v30 = *(unsigned int *)__errno_location(v37); __fprintf_chk(v29, 1LL, "Got error: %d from pthread_attr_setdetachstate (errno: %d)\n", v28, v30); } else if ( init_pagecache((unsigned int)&pagecache, 83886080, 0, 0, 0x2000, 0, 16LL) ) { pthread_mutex_lock(&LOCK_thread_count); v16 = (_DWORD *)malloc(4LL); *v16 = 1; v17 = pthread_create(v36, v37, test_thread, v16); if ( v17 ) { v33 = v17; v34 = stderr; v35 = *(unsigned int *)__errno_location(v36); __fprintf_chk(v34, 1LL, "Got error: %d from pthread_create (errno: %d)\n", v33, v35); } else { ++thread_count; pthread_mutex_unlock(&LOCK_thread_count); pthread_attr_destroy(v37); pthread_mutex_lock(&LOCK_thread_count); while ( thread_count ) { v18 = pthread_cond_wait(&COND_thread_count, &LOCK_thread_count); if ( v18 ) __fprintf_chk(stderr, 1LL, "Got error: %d from pthread_cond_wait\n", v18); } pthread_mutex_unlock(&LOCK_thread_count); end_pagecache(&pagecache, 1LL); if ( !(unsigned int)my_close((unsigned int)dword_3FE690, 16LL) ) { my_delete(&file1_name, 0LL); rmdir(&create_tmpdir_test_dirname); goto LABEL_22; } } } else { v31 = stderr; v32 = *(unsigned int *)__errno_location(&pagecache); __fprintf_chk(v31, 1LL, "Got error: init_pagecache() (errno: %d)\n", v32); } } } } } } exit(1LL); } skip(18, (unsigned int)"big test", v3, v4, v5, v6); LABEL_22: my_end(0LL); return exit_status(); }
main: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R12 PUSH RBX SUB RSP,0x220 MOV RBX,RSI MOV RAX,qword ptr FS:[0x28] MOV qword ptr [RBP + -0x28],RAX MOV RAX,qword ptr [RSI] LEA RCX,[0xd0a050] MOV qword ptr [RCX],RAX CALL 0x001a026c MOV EDI,0x12 CALL 0x001920e7 LEA RAX,[0x487798] CMP dword ptr [RAX],0x0 JZ 0x001316e1 LEA RSI,[0x1da615] MOV EDI,0x12 XOR EAX,EAX CALL 0x001924ad JMP 0x001319cf LAB_001316e1: MOV RSI,qword ptr [RBX] LEA RCX,[0x1e10f9] LEA RBX,[RBP + -0x230] MOV RDI,RBX MOV RDX,RCX MOV R8D,0x3 CALL 0x00195900 MOV RDI,RBX CALL 0x00129350 CMP RAX,0x3 JC 0x00131727 CMP byte ptr [RAX + RBX*0x1 + -0x2],0x2d JNZ 0x00131727 CMP byte ptr [RAX + RBX*0x1 + -0x1],0x74 JNZ 0x00131727 MOV byte ptr [RBP + RAX*0x1 + -0x232],0x0 LAB_00131727: LEA RBX,[0x4feb30] LEA RSI,[0x1da77f] LEA RDX,[RBP + -0x230] MOV RDI,RBX XOR ECX,ECX XOR EAX,EAX CALL 0x001d815c MOV RDI,RBX MOV ESI,0x1ff XOR EDX,EDX CALL 0x001a10c0 LEA RDI,[0x4fe6d0] LEA RSI,[0x1da784] LEA R14,[0x1e10f9] MOV RDX,RBX MOV RCX,R14 XOR R8D,R8D CALL 0x00195900 LEA R15,[0x4fe8d0] LEA RSI,[0x1da79b] MOV RDI,R15 MOV RDX,RBX MOV RCX,R14 XOR R8D,R8D CALL 0x00195900 MOV EDX,0x10 MOV RDI,R15 MOV ESI,0x242 CALL 0x001a130c TEST EAX,EAX JS 0x00131ac8 MOV EBX,EAX LEA RDI,[0x4fe6d0] MOV ESI,0x242 XOR EDX,EDX CALL 0x001a130c MOV dword ptr [0x004fe690],EAX CMP EAX,-0x1 JZ 0x00131a1f LEA RDI,[0x4fe680] CALL 0x00135a53 MOV EDI,EBX XOR ESI,ESI CALL 0x001a14b1 LEA RDI,[0x4fe8d0] XOR ESI,ESI CALL 0x0019ee8c LEA RDI,[0x4fe6d0] MOV EDX,0x10 MOV ESI,0x1ff CALL 0x001a7154 TEST EAX,EAX JNZ 0x00131ac8 MOV EDI,dword ptr [0x004fe690] LEA RSI,[0x1da657] MOV EDX,0x9 MOV R8D,0x10 XOR ECX,ECX CALL 0x001a171a LEA RDI,[0x4fead0] XOR ESI,ESI CALL 0x00129380 TEST EAX,EAX JNZ 0x001319ff LEA RDI,[0x4feb00] LEA RSI,[0xd0ace0] CALL 0x00129340 TEST EAX,EAX JNZ 0x001319ff LEA RDI,[RBP + -0x230] CALL 0x00129140 TEST EAX,EAX JNZ 0x00131a39 LEA RDI,[RBP + -0x230] MOV ESI,0x1 CALL 0x00129660 TEST EAX,EAX JNZ 0x00131a56 MOV qword ptr [RSP],0x10 LEA RDI,[0x4fe460] MOV ESI,0x5000000 XOR EDX,EDX XOR ECX,ECX MOV R8D,0x2000 XOR R9D,R9D CALL 0x00131d34 TEST RAX,RAX JZ 0x00131a73 LEA RDI,[0x4feb00] CALL 0x00129220 MOV EDI,0x4 CALL 0x00129710 MOV dword ptr [RAX],0x1 LEA RDX,[0x131ad2] LEA RDI,[RBP + -0x238] LEA RSI,[RBP + -0x230] MOV RCX,RAX CALL 0x001298e0 TEST EAX,EAX JNZ 0x00131a9c INC dword ptr [0x004feb28] LEA RBX,[0x4feb00] MOV RDI,RBX CALL 0x001291e0 LEA RDI,[RBP + -0x230] CALL 0x001295a0 MOV RDI,RBX CALL 0x00129220 CMP dword ptr [0x004feb28],0x0 JZ 0x00131980 LEA RBX,[0x4fead0] LEA R14,[0x4feb00] MOV R12,qword ptr [0x00485fb0] LEA R15,[0x1da759] LAB_00131953: MOV RDI,RBX MOV RSI,R14 CALL 0x00129430 TEST EAX,EAX JZ 0x00131977 MOV RDI,qword ptr [R12] MOV ESI,0x1 MOV RDX,R15 MOV ECX,EAX XOR EAX,EAX CALL 0x00129200 LAB_00131977: CMP dword ptr [0x004feb28],0x0 JNZ 0x00131953 LAB_00131980: LEA RDI,[0x4feb00] CALL 0x001291e0 LEA RDI,[0x4fe460] MOV ESI,0x1 CALL 0x001324af MOV EDI,dword ptr [0x004fe690] MOV ESI,0x10 CALL 0x001a14b1 TEST EAX,EAX JNZ 0x00131ac8 LEA RDI,[0x4fe6d0] XOR ESI,ESI CALL 0x0019ee8c LEA RDI,[0x4feb30] CALL 0x00129370 LAB_001319cf: XOR EDI,EDI CALL 0x001a0407 CALL 0x001926d7 MOV RCX,qword ptr FS:[0x28] CMP RCX,qword ptr [RBP + -0x28] JNZ 0x001319fa ADD RSP,0x220 POP RBX POP R12 POP R14 POP R15 POP RBP RET LAB_001319fa: CALL 0x00129270 LAB_001319ff: MOV EBX,EAX MOV RAX,qword ptr [0x00485fb0] MOV R14,qword ptr [RAX] CALL 0x001297b0 MOV R8D,dword ptr [RAX] LEA RDX,[0x1da661] JMP 0x00131ab7 LAB_00131a1f: MOV RAX,qword ptr [0x00485fb0] MOV RBX,qword ptr [RAX] CALL 0x001297b0 MOV ECX,dword ptr [RAX] LEA RDX,[0x1da61e] JMP 0x00131a8b LAB_00131a39: MOV EBX,EAX MOV RAX,qword ptr [0x00485fb0] MOV R14,qword ptr [RAX] CALL 0x001297b0 MOV R8D,dword ptr [RAX] LEA RDX,[0x1da693] JMP 0x00131ab7 LAB_00131a56: MOV EBX,EAX MOV RAX,qword ptr [0x00485fb0] MOV R14,qword ptr [RAX] CALL 0x001297b0 MOV R8D,dword ptr [RAX] LEA RDX,[0x1da6c5] JMP 0x00131ab7 LAB_00131a73: MOV RAX,qword ptr [0x00485fb0] MOV RBX,qword ptr [RAX] CALL 0x001297b0 MOV ECX,dword ptr [RAX] LEA RDX,[0x1da701] LAB_00131a8b: MOV RDI,RBX MOV ESI,0x1 XOR EAX,EAX CALL 0x00129200 JMP 0x00131ac8 LAB_00131a9c: MOV EBX,EAX MOV RAX,qword ptr [0x00485fb0] MOV R14,qword ptr [RAX] CALL 0x001297b0 MOV R8D,dword ptr [RAX] LEA RDX,[0x1da72a] LAB_00131ab7: MOV RDI,R14 MOV ESI,0x1 MOV ECX,EBX XOR EAX,EAX CALL 0x00129200 LAB_00131ac8: MOV EDI,0x1 CALL 0x00129540
void main(int8 param_1,int8 *param_2) { int *puVar1; int iVar2; size_t sVar3; long lVar4; int4 *__arg; int *piVar5; char *pcVar6; int8 uVar7; int iVar8; long in_FS_OFFSET; int8 local_240; pthread_attr_t local_238 [9]; long local_30; local_30 = *(long *)(in_FS_OFFSET + 0x28); my_progname = *param_2; my_init(); plan(0x12); if (skip_big_tests != 0) { skip(0x12,"big test"); LAB_001319cf: my_end(0); exit_status(); if (*(long *)(in_FS_OFFSET + 0x28) != local_30) { /* WARNING: Subroutine does not return */ __stack_chk_fail(); } return; } fn_format(local_238,*param_2,&DAT_001e10f9,&DAT_001e10f9,3); sVar3 = strlen(local_238[0].__size); if (((2 < sVar3) && (local_238[0].__size[sVar3 - 2] == '-')) && (local_238[0].__size[sVar3 - 1] == 't')) { local_238[0].__size[sVar3 - 2] = '\0'; } strxmov(create_tmpdir_test_dirname,&DAT_001da77f,local_238,0); my_mkdir(create_tmpdir_test_dirname,0x1ff,0); fn_format(file1_name,"page_cache_test_file_1",create_tmpdir_test_dirname,&DAT_001e10f9,0); fn_format(file2_name,"page_cache_test_file_2",create_tmpdir_test_dirname,&DAT_001e10f9,0); iVar2 = my_open(file2_name,0x242,0x10); if (iVar2 < 0) goto LAB_00131ac8; DAT_004fe690 = my_open(file1_name,0x242,0); if (DAT_004fe690 == -1) { uVar7 = *(int8 *)PTR_stderr_00485fb0; piVar5 = __errno_location(); iVar2 = *piVar5; pcVar6 = "Got error during file1 creation from open() (errno: %d)\n"; LAB_00131a8b: __fprintf_chk(uVar7,1,pcVar6,iVar2); } else { pagecache_file_set_null_hooks(&file1); my_close(iVar2,0); my_delete(file2_name,0); iVar2 = my_chmod(file1_name,0x1ff,0x10); if (iVar2 != 0) goto LAB_00131ac8; my_pwrite(DAT_004fe690,"test file",9,0,0x10); iVar2 = pthread_cond_init((pthread_cond_t *)COND_thread_count,(pthread_condattr_t *)0x0); if ((iVar2 == 0) && (iVar2 = pthread_mutex_init((pthread_mutex_t *)LOCK_thread_count, (pthread_mutexattr_t *)&my_fast_mutexattr), iVar2 == 0)) { iVar2 = pthread_attr_init(local_238); if (iVar2 == 0) { iVar2 = pthread_attr_setdetachstate(local_238,1); if (iVar2 == 0) { lVar4 = init_pagecache(pagecache,0x5000000,0,0,0x2000,0,0x10); if (lVar4 == 0) { uVar7 = *(int8 *)PTR_stderr_00485fb0; piVar5 = __errno_location(); iVar2 = *piVar5; pcVar6 = "Got error: init_pagecache() (errno: %d)\n"; goto LAB_00131a8b; } pthread_mutex_lock((pthread_mutex_t *)LOCK_thread_count); __arg = (int4 *)malloc(4); *__arg = 1; iVar2 = pthread_create(&local_240,local_238,test_thread,__arg); if (iVar2 == 0) { thread_count = thread_count + 1; pthread_mutex_unlock((pthread_mutex_t *)LOCK_thread_count); pthread_attr_destroy(local_238); pthread_mutex_lock((pthread_mutex_t *)LOCK_thread_count); puVar1 = PTR_stderr_00485fb0; while (thread_count != 0) { iVar2 = pthread_cond_wait((pthread_cond_t *)COND_thread_count, (pthread_mutex_t *)LOCK_thread_count); if (iVar2 != 0) { __fprintf_chk(*(int8 *)puVar1,1,"Got error: %d from pthread_cond_wait\n",iVar2 ); } } pthread_mutex_unlock((pthread_mutex_t *)LOCK_thread_count); end_pagecache(pagecache,1); iVar2 = my_close(DAT_004fe690,0x10); if (iVar2 == 0) { my_delete(file1_name,0); rmdir(create_tmpdir_test_dirname); goto LAB_001319cf; } goto LAB_00131ac8; } uVar7 = *(int8 *)PTR_stderr_00485fb0; piVar5 = __errno_location(); iVar8 = *piVar5; pcVar6 = "Got error: %d from pthread_create (errno: %d)\n"; } else { uVar7 = *(int8 *)PTR_stderr_00485fb0; piVar5 = __errno_location(); iVar8 = *piVar5; pcVar6 = "Got error: %d from pthread_attr_setdetachstate (errno: %d)\n"; } } else { uVar7 = *(int8 *)PTR_stderr_00485fb0; piVar5 = __errno_location(); iVar8 = *piVar5; pcVar6 = "Got error: %d from pthread_attr_init (errno: %d)\n"; } } else { uVar7 = *(int8 *)PTR_stderr_00485fb0; piVar5 = __errno_location(); iVar8 = *piVar5; pcVar6 = "Got error: %d from pthread_cond_init (errno: %d)\n"; } __fprintf_chk(uVar7,1,pcVar6,iVar2,iVar8); } LAB_00131ac8: /* WARNING: Subroutine does not return */ exit(1); }
20,585
my_lengthsp_utf16le
eloqsql/strings/ctype-ucs2.c
static size_t my_lengthsp_utf16le(CHARSET_INFO *cs __attribute__((unused)), const char *ptr, size_t length) { const char *end= ptr + length; while (end > ptr + 1 && uint2korr(end - 2) == ' ') end-= 2; return (size_t) (end - ptr); }
O0
c
my_lengthsp_utf16le: pushq %rbp movq %rsp, %rbp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq %rdx, -0x18(%rbp) movq -0x10(%rbp), %rax addq -0x18(%rbp), %rax movq %rax, -0x20(%rbp) movq -0x20(%rbp), %rcx movq -0x10(%rbp), %rdx addq $0x1, %rdx xorl %eax, %eax cmpq %rdx, %rcx movb %al, -0x21(%rbp) jbe 0x5e3a3 movq -0x20(%rbp), %rax movzwl -0x2(%rax), %eax cmpl $0x20, %eax sete %al movb %al, -0x21(%rbp) movb -0x21(%rbp), %al testb $0x1, %al jne 0x5e3ac jmp 0x5e3ba movq -0x20(%rbp), %rax addq $-0x2, %rax movq %rax, -0x20(%rbp) jmp 0x5e37c movq -0x20(%rbp), %rax movq -0x10(%rbp), %rcx subq %rcx, %rax popq %rbp retq nopw (%rax,%rax)
my_lengthsp_utf16le: push rbp mov rbp, rsp mov [rbp+var_8], rdi mov [rbp+var_10], rsi mov [rbp+var_18], rdx mov rax, [rbp+var_10] add rax, [rbp+var_18] mov [rbp+var_20], rax loc_5E37C: mov rcx, [rbp+var_20] mov rdx, [rbp+var_10] add rdx, 1 xor eax, eax cmp rcx, rdx mov [rbp+var_21], al jbe short loc_5E3A3 mov rax, [rbp+var_20] movzx eax, word ptr [rax-2] cmp eax, 20h ; ' ' setz al mov [rbp+var_21], al loc_5E3A3: mov al, [rbp+var_21] test al, 1 jnz short loc_5E3AC jmp short loc_5E3BA loc_5E3AC: mov rax, [rbp+var_20] add rax, 0FFFFFFFFFFFFFFFEh mov [rbp+var_20], rax jmp short loc_5E37C loc_5E3BA: mov rax, [rbp+var_20] mov rcx, [rbp+var_10] sub rax, rcx pop rbp retn
long long my_lengthsp_utf16le(long long a1, long long a2, long long a3) { bool v4; // [rsp+1h] [rbp-21h] unsigned long long i; // [rsp+2h] [rbp-20h] for ( i = a3 + a2; ; i -= 2LL ) { v4 = 0; if ( i > a2 + 1 ) v4 = *(unsigned __int16 *)(i - 2) == 32; if ( !v4 ) break; } return i - a2; }
my_lengthsp_utf16le: PUSH RBP MOV RBP,RSP MOV qword ptr [RBP + -0x8],RDI MOV qword ptr [RBP + -0x10],RSI MOV qword ptr [RBP + -0x18],RDX MOV RAX,qword ptr [RBP + -0x10] ADD RAX,qword ptr [RBP + -0x18] MOV qword ptr [RBP + -0x20],RAX LAB_0015e37c: MOV RCX,qword ptr [RBP + -0x20] MOV RDX,qword ptr [RBP + -0x10] ADD RDX,0x1 XOR EAX,EAX CMP RCX,RDX MOV byte ptr [RBP + -0x21],AL JBE 0x0015e3a3 MOV RAX,qword ptr [RBP + -0x20] MOVZX EAX,word ptr [RAX + -0x2] CMP EAX,0x20 SETZ AL MOV byte ptr [RBP + -0x21],AL LAB_0015e3a3: MOV AL,byte ptr [RBP + -0x21] TEST AL,0x1 JNZ 0x0015e3ac JMP 0x0015e3ba LAB_0015e3ac: MOV RAX,qword ptr [RBP + -0x20] ADD RAX,-0x2 MOV qword ptr [RBP + -0x20],RAX JMP 0x0015e37c LAB_0015e3ba: MOV RAX,qword ptr [RBP + -0x20] MOV RCX,qword ptr [RBP + -0x10] SUB RAX,RCX POP RBP RET
long my_lengthsp_utf16le(int8 param_1,long param_2,long param_3) { bool bVar1; int8 local_28; local_28 = param_2 + param_3; while( true ) { bVar1 = false; if (param_2 + 1U < local_28) { bVar1 = *(short *)(local_28 - 2) == 0x20; } if (!bVar1) break; local_28 = local_28 - 2; } return local_28 - param_2; }
20,586
key_cache_write
eloqsql/mysys/mf_keycache.c
int key_cache_write(KEY_CACHE *keycache, File file, void *file_extra, my_off_t filepos, int level, uchar *buff, uint length, uint block_length, int force_write) { if (keycache->can_be_used) return keycache->interface_funcs->write(keycache->keycache_cb, file, file_extra, filepos, level, buff, length, block_length, force_write); /* We can't use mutex here as the key cache may not be initialized */ if (my_pwrite(file, buff, length, filepos, MYF(MY_NABP | MY_WAIT_IF_FULL))) return 1; return 0; }
O3
c
key_cache_write: cmpb $0x0, 0x49(%rdi) je 0x986e6 movq 0x8(%rdi), %rax movq 0x10(%rdi), %rdi movq 0x28(%rdi), %r11 movq %rax, %rdi jmpq *%r11 pushq %rbp movq %rsp, %rbp movl 0x10(%rbp), %edx movl $0x24, %r8d movl %esi, %edi movq %r9, %rsi callq 0xa07ee xorl %ecx, %ecx testq %rax, %rax setne %cl movl %ecx, %eax popq %rbp retq
key_cache_write: cmp byte ptr [rdi+49h], 0 jz short loc_986E6 mov rax, [rdi+8] mov rdi, [rdi+10h] mov r11, [rdi+28h] mov rdi, rax jmp r11 loc_986E6: push rbp mov rbp, rsp mov edx, [rbp+10h] mov r8d, 24h ; '$' mov edi, esi mov rsi, r9 call my_pwrite xor ecx, ecx test rax, rax setnz cl mov eax, ecx pop rbp retn
long long key_cache_write( long long a1, unsigned int a2, long long a3, long long a4, long long a5, long long a6, unsigned int a7) { if ( *(_BYTE *)(a1 + 73) ) return (*(long long ( **)(_QWORD))(*(_QWORD *)(a1 + 16) + 40LL))(*(_QWORD *)(a1 + 8)); else return my_pwrite(a2, a6, a7, a4, 36LL) != 0; }
key_cache_write: CMP byte ptr [RDI + 0x49],0x0 JZ 0x001986e6 MOV RAX,qword ptr [RDI + 0x8] MOV RDI,qword ptr [RDI + 0x10] MOV R11,qword ptr [RDI + 0x28] MOV RDI,RAX JMP R11 LAB_001986e6: PUSH RBP MOV RBP,RSP MOV EDX,dword ptr [RBP + 0x10] MOV R8D,0x24 MOV EDI,ESI MOV RSI,R9 CALL 0x001a07ee XOR ECX,ECX TEST RAX,RAX SETNZ CL MOV EAX,ECX POP RBP RET
ulong key_cache_write(long param_1,int4 param_2,int8 param_3,int8 param_4, int8 param_5,int8 param_6,int4 param_7) { ulong uVar1; long lVar2; if (*(char *)(param_1 + 0x49) != '\0') { /* WARNING: Could not recover jumptable at 0x001986e3. Too many branches */ /* WARNING: Treating indirect jump as call */ uVar1 = (**(code **)(*(long *)(param_1 + 0x10) + 0x28))(*(int8 *)(param_1 + 8)); return uVar1; } lVar2 = my_pwrite(param_2,param_6,param_7,param_4,0x24); return (ulong)(lVar2 != 0); }
20,587
cmp
eloqsql/strings/dtoa.c
static int cmp(Bigint *a, Bigint *b) { ULong *xa, *xa0, *xb, *xb0; int i, j; i= a->wds; j= b->wds; if (i-= j) return i; xa0= a->p.x; xa= xa0 + j; xb0= b->p.x; xb= xb0 + j; for (;;) { if (*--xa != *--xb) return *xa < *xb ? -1 : 1; if (xa <= xa0) break; } return 0; }
O0
c
cmp: pushq %rbp movq %rsp, %rbp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq -0x10(%rbp), %rax movl 0x14(%rax), %eax movl %eax, -0x3c(%rbp) movq -0x18(%rbp), %rax movl 0x14(%rax), %eax movl %eax, -0x40(%rbp) movl -0x40(%rbp), %ecx movl -0x3c(%rbp), %eax subl %ecx, %eax movl %eax, -0x3c(%rbp) cmpl $0x0, %eax je 0x8107b movl -0x3c(%rbp), %eax movl %eax, -0x4(%rbp) jmp 0x81112 movq -0x10(%rbp), %rax movq (%rax), %rax movq %rax, -0x28(%rbp) movq -0x28(%rbp), %rax movslq -0x40(%rbp), %rcx shlq $0x2, %rcx addq %rcx, %rax movq %rax, -0x20(%rbp) movq -0x18(%rbp), %rax movq (%rax), %rax movq %rax, -0x38(%rbp) movq -0x38(%rbp), %rax movslq -0x40(%rbp), %rcx shlq $0x2, %rcx addq %rcx, %rax movq %rax, -0x30(%rbp) movq -0x20(%rbp), %rax movq %rax, %rcx addq $-0x4, %rcx movq %rcx, -0x20(%rbp) movl -0x4(%rax), %eax movq -0x30(%rbp), %rcx movq %rcx, %rdx addq $-0x4, %rdx movq %rdx, -0x30(%rbp) cmpl -0x4(%rcx), %eax je 0x810fd movq -0x20(%rbp), %rax movl (%rax), %edx movq -0x30(%rbp), %rax movl (%rax), %esi movl $0x1, %eax movl $0xffffffff, %ecx # imm = 0xFFFFFFFF cmpl %esi, %edx cmovbl %ecx, %eax movl %eax, -0x4(%rbp) jmp 0x81112 movq -0x20(%rbp), %rax cmpq -0x28(%rbp), %rax ja 0x81109 jmp 0x8110b jmp 0x810b7 movl $0x0, -0x4(%rbp) movl -0x4(%rbp), %eax popq %rbp retq nopw (%rax,%rax)
cmp: push rbp mov rbp, rsp mov [rbp+var_10], rdi mov [rbp+var_18], rsi mov rax, [rbp+var_10] mov eax, [rax+14h] mov [rbp+var_3C], eax mov rax, [rbp+var_18] mov eax, [rax+14h] mov [rbp+var_40], eax mov ecx, [rbp+var_40] mov eax, [rbp+var_3C] sub eax, ecx mov [rbp+var_3C], eax cmp eax, 0 jz short loc_8107B mov eax, [rbp+var_3C] mov [rbp+var_4], eax jmp loc_81112 loc_8107B: mov rax, [rbp+var_10] mov rax, [rax] mov [rbp+var_28], rax mov rax, [rbp+var_28] movsxd rcx, [rbp+var_40] shl rcx, 2 add rax, rcx mov [rbp+var_20], rax mov rax, [rbp+var_18] mov rax, [rax] mov [rbp+var_38], rax mov rax, [rbp+var_38] movsxd rcx, [rbp+var_40] shl rcx, 2 add rax, rcx mov [rbp+var_30], rax loc_810B7: mov rax, [rbp+var_20] mov rcx, rax add rcx, 0FFFFFFFFFFFFFFFCh mov [rbp+var_20], rcx mov eax, [rax-4] mov rcx, [rbp+var_30] mov rdx, rcx add rdx, 0FFFFFFFFFFFFFFFCh mov [rbp+var_30], rdx cmp eax, [rcx-4] jz short loc_810FD mov rax, [rbp+var_20] mov edx, [rax] mov rax, [rbp+var_30] mov esi, [rax] mov eax, 1 mov ecx, 0FFFFFFFFh cmp edx, esi cmovb eax, ecx mov [rbp+var_4], eax jmp short loc_81112 loc_810FD: mov rax, [rbp+var_20] cmp rax, [rbp+var_28] ja short loc_81109 jmp short loc_8110B loc_81109: jmp short loc_810B7 loc_8110B: mov [rbp+var_4], 0 loc_81112: mov eax, [rbp+var_4] pop rbp retn
long long cmp(long long a1, long long a2) { _DWORD *v2; // rax _DWORD *v3; // rcx unsigned int v4; // eax int v6; // [rsp+0h] [rbp-40h] _DWORD *v7; // [rsp+10h] [rbp-30h] _DWORD *v8; // [rsp+20h] [rbp-20h] v6 = *(_DWORD *)(a2 + 20); if ( *(_DWORD *)(a1 + 20) == v6 ) { v8 = (_DWORD *)(4LL * v6 + *(_QWORD *)a1); v7 = (_DWORD *)(4LL * v6 + *(_QWORD *)a2); while ( 1 ) { v2 = v8--; v3 = v7--; if ( *(v2 - 1) != *(v3 - 1) ) break; if ( (unsigned long long)v8 <= *(_QWORD *)a1 ) return 0; } v4 = 1; if ( *v8 < *v7 ) return (unsigned int)-1; return v4; } else { return (unsigned int)(*(_DWORD *)(a1 + 20) - v6); } }
cmp: PUSH RBP MOV RBP,RSP MOV qword ptr [RBP + -0x10],RDI MOV qword ptr [RBP + -0x18],RSI MOV RAX,qword ptr [RBP + -0x10] MOV EAX,dword ptr [RAX + 0x14] MOV dword ptr [RBP + -0x3c],EAX MOV RAX,qword ptr [RBP + -0x18] MOV EAX,dword ptr [RAX + 0x14] MOV dword ptr [RBP + -0x40],EAX MOV ECX,dword ptr [RBP + -0x40] MOV EAX,dword ptr [RBP + -0x3c] SUB EAX,ECX MOV dword ptr [RBP + -0x3c],EAX CMP EAX,0x0 JZ 0x0018107b MOV EAX,dword ptr [RBP + -0x3c] MOV dword ptr [RBP + -0x4],EAX JMP 0x00181112 LAB_0018107b: MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX] MOV qword ptr [RBP + -0x28],RAX MOV RAX,qword ptr [RBP + -0x28] MOVSXD RCX,dword ptr [RBP + -0x40] SHL RCX,0x2 ADD RAX,RCX MOV qword ptr [RBP + -0x20],RAX MOV RAX,qword ptr [RBP + -0x18] MOV RAX,qword ptr [RAX] MOV qword ptr [RBP + -0x38],RAX MOV RAX,qword ptr [RBP + -0x38] MOVSXD RCX,dword ptr [RBP + -0x40] SHL RCX,0x2 ADD RAX,RCX MOV qword ptr [RBP + -0x30],RAX LAB_001810b7: MOV RAX,qword ptr [RBP + -0x20] MOV RCX,RAX ADD RCX,-0x4 MOV qword ptr [RBP + -0x20],RCX MOV EAX,dword ptr [RAX + -0x4] MOV RCX,qword ptr [RBP + -0x30] MOV RDX,RCX ADD RDX,-0x4 MOV qword ptr [RBP + -0x30],RDX CMP EAX,dword ptr [RCX + -0x4] JZ 0x001810fd MOV RAX,qword ptr [RBP + -0x20] MOV EDX,dword ptr [RAX] MOV RAX,qword ptr [RBP + -0x30] MOV ESI,dword ptr [RAX] MOV EAX,0x1 MOV ECX,0xffffffff CMP EDX,ESI CMOVC EAX,ECX MOV dword ptr [RBP + -0x4],EAX JMP 0x00181112 LAB_001810fd: MOV RAX,qword ptr [RBP + -0x20] CMP RAX,qword ptr [RBP + -0x28] JA 0x00181109 JMP 0x0018110b LAB_00181109: JMP 0x001810b7 LAB_0018110b: MOV dword ptr [RBP + -0x4],0x0 LAB_00181112: MOV EAX,dword ptr [RBP + -0x4] POP RBP RET
int cmp(void *param_1,void *param_2) { int iVar1; uint *puVar2; uint *local_38; uint *local_28; int local_c; iVar1 = *(int *)((long)param_2 + 0x14); local_c = *(int *)((long)param_1 + 0x14) - iVar1; if (local_c == 0) { /* WARNING: Load size is inaccurate */ /* WARNING: Load size is inaccurate */ local_38 = (uint *)(*param_2 + (long)iVar1 * 4); local_28 = *param_1 + iVar1; do { puVar2 = local_28 + -1; if (local_28[-1] != local_38[-1]) { if (local_38[-1] <= *puVar2) { return 1; } return -1; } local_38 = local_38 + -1; local_28 = puVar2; } while (*param_1 < puVar2); local_c = 0; } return local_c; }
20,588
js_proxy_set
bluesky950520[P]quickjs/quickjs.c
static int js_proxy_set(JSContext *ctx, JSValue obj, JSAtom atom, JSValue value, JSValue receiver, int flags) { JSProxyData *s; JSValue method, ret1, atom_val; int ret, res; JSValue args[4]; s = get_proxy_method(ctx, &method, obj, JS_ATOM_set); if (!s) return -1; if (JS_IsUndefined(method)) { return JS_SetPropertyInternal2(ctx, s->target, atom, js_dup(value), receiver, flags, NULL); } atom_val = JS_AtomToValue(ctx, atom); if (JS_IsException(atom_val)) { JS_FreeValue(ctx, method); return -1; } args[0] = s->target; args[1] = atom_val; args[2] = value; args[3] = receiver; ret1 = JS_CallFree(ctx, method, s->handler, 4, args); JS_FreeValue(ctx, atom_val); if (JS_IsException(ret1)) return -1; ret = JS_ToBoolFree(ctx, ret1); if (ret) { JSPropertyDescriptor desc; res = JS_GetOwnPropertyInternal(ctx, &desc, JS_VALUE_GET_OBJ(s->target), atom); if (res < 0) return -1; if (res) { if ((desc.flags & (JS_PROP_GETSET | JS_PROP_CONFIGURABLE | JS_PROP_WRITABLE)) == 0) { if (!js_same_value(ctx, desc.value, value)) { goto fail; } } else if ((desc.flags & (JS_PROP_GETSET | JS_PROP_CONFIGURABLE)) == JS_PROP_GETSET && JS_IsUndefined(desc.setter)) { fail: js_free_desc(ctx, &desc); JS_ThrowTypeError(ctx, "proxy: inconsistent set"); return -1; } js_free_desc(ctx, &desc); } } else { if ((flags & JS_PROP_THROW) || ((flags & JS_PROP_THROW_STRICT) && is_strict_mode(ctx))) { JS_ThrowTypeError(ctx, "proxy: cannot set property"); return -1; } } return ret; }
O0
c
js_proxy_set: subq $0x188, %rsp # imm = 0x188 movl 0x1a0(%rsp), %eax leaq 0x190(%rsp), %rax movq %rax, 0x40(%rsp) movq %rsi, 0x170(%rsp) movq %rdx, 0x178(%rsp) movq %r8, 0x160(%rsp) movq %r9, 0x168(%rsp) movq %rdi, 0x158(%rsp) movl %ecx, 0x154(%rsp) movq 0x158(%rsp), %rdi movq 0x170(%rsp), %rdx movq 0x178(%rsp), %rcx leaq 0x138(%rsp), %rsi movl $0x43, %r8d callq 0x5edb0 movq %rax, 0x148(%rsp) cmpq $0x0, 0x148(%rsp) jne 0x89c78 movl $0xffffffff, 0x184(%rsp) # imm = 0xFFFFFFFF jmp 0x8a0b6 movq 0x138(%rsp), %rdi movq 0x140(%rsp), %rsi callq 0x2cfa0 cmpl $0x0, %eax je 0x89d48 movq 0x158(%rsp), %rax movq %rax, 0x28(%rsp) movq 0x148(%rsp), %rax movq %rax, 0x38(%rsp) movl 0x154(%rsp), %eax movl %eax, 0x34(%rsp) movq 0x160(%rsp), %rdi movq 0x168(%rsp), %rsi callq 0x20410 movq 0x28(%rsp), %rdi movl 0x34(%rsp), %ecx movq 0x40(%rsp), %r10 movq %rax, %rsi movq %rdx, %rax movq 0x38(%rsp), %rdx movq %rsi, 0xc0(%rsp) movq %rax, 0xc8(%rsp) movl 0x1a0(%rsp), %eax movq (%rdx), %rsi movq 0x8(%rdx), %rdx movq 0xc0(%rsp), %r8 movq 0xc8(%rsp), %r9 xorl %r11d, %r11d movq (%r10), %r11 movq %r11, (%rsp) movq 0x8(%r10), %r10 movq %r10, 0x8(%rsp) movl %eax, 0x10(%rsp) movq $0x0, 0x18(%rsp) callq 0x30cc0 movl %eax, 0x184(%rsp) jmp 0x8a0b6 movq 0x158(%rsp), %rdi movl 0x154(%rsp), %esi callq 0x27b70 movq %rax, 0xb0(%rsp) movq %rdx, 0xb8(%rsp) movq 0xb0(%rsp), %rax movq %rax, 0x118(%rsp) movq 0xb8(%rsp), %rax movq %rax, 0x120(%rsp) movq 0x118(%rsp), %rdi movq 0x120(%rsp), %rsi callq 0x22a00 cmpl $0x0, %eax je 0x89dd3 movq 0x158(%rsp), %rdi movq 0x138(%rsp), %rsi movq 0x140(%rsp), %rdx callq 0x229d0 movl $0xffffffff, 0x184(%rsp) # imm = 0xFFFFFFFF jmp 0x8a0b6 movq 0x40(%rsp), %rax movq 0x148(%rsp), %rcx movq (%rcx), %rdx movq %rdx, 0xd0(%rsp) movq 0x8(%rcx), %rcx movq %rcx, 0xd8(%rsp) movq 0x118(%rsp), %rcx movq %rcx, 0xe0(%rsp) movq 0x120(%rsp), %rcx movq %rcx, 0xe8(%rsp) movq 0x160(%rsp), %rcx movq %rcx, 0xf0(%rsp) movq 0x168(%rsp), %rcx movq %rcx, 0xf8(%rsp) movq (%rax), %rcx movq %rcx, 0x100(%rsp) movq 0x8(%rax), %rax movq %rax, 0x108(%rsp) movq 0x158(%rsp), %rdi movq 0x148(%rsp), %r8 leaq 0xd0(%rsp), %rax movq 0x138(%rsp), %rsi movq 0x140(%rsp), %rdx movq 0x10(%r8), %rcx movq 0x18(%r8), %r8 movl $0x4, %r9d movq %rax, (%rsp) callq 0x2cfc0 movq %rax, 0xa0(%rsp) movq %rdx, 0xa8(%rsp) movq 0xa0(%rsp), %rax movq %rax, 0x128(%rsp) movq 0xa8(%rsp), %rax movq %rax, 0x130(%rsp) movq 0x158(%rsp), %rdi movq 0x118(%rsp), %rsi movq 0x120(%rsp), %rdx callq 0x229d0 movq 0x128(%rsp), %rdi movq 0x130(%rsp), %rsi callq 0x22a00 cmpl $0x0, %eax je 0x89f04 movl $0xffffffff, 0x184(%rsp) # imm = 0xFFFFFFFF jmp 0x8a0b6 movq 0x158(%rsp), %rdi movq 0x128(%rsp), %rsi movq 0x130(%rsp), %rdx callq 0x2d070 movl %eax, 0x114(%rsp) cmpl $0x0, 0x114(%rsp) je 0x8a045 movq 0x158(%rsp), %rdi movq 0x148(%rsp), %rax movq (%rax), %rdx movl 0x154(%rsp), %ecx leaq 0x68(%rsp), %rsi callq 0x2ef00 movl %eax, 0x110(%rsp) cmpl $0x0, 0x110(%rsp) jge 0x89f7b movl $0xffffffff, 0x184(%rsp) # imm = 0xFFFFFFFF jmp 0x8a0b6 cmpl $0x0, 0x110(%rsp) je 0x8a043 movl 0x68(%rsp), %eax andl $0x13, %eax cmpl $0x0, %eax jne 0x89fc5 movq 0x158(%rsp), %rdi movq 0x70(%rsp), %rsi movq 0x78(%rsp), %rdx movq 0x160(%rsp), %rcx movq 0x168(%rsp), %r8 callq 0x34850 cmpl $0x0, %eax jne 0x89fc3 jmp 0x89fed jmp 0x8a031 movl 0x68(%rsp), %eax andl $0x11, %eax cmpl $0x10, %eax jne 0x8a02f movq 0x90(%rsp), %rdi movq 0x98(%rsp), %rsi callq 0x2cfa0 cmpl $0x0, %eax je 0x8a02f jmp 0x89fed movq 0x158(%rsp), %rdi leaq 0x68(%rsp), %rsi callq 0x5f740 movq 0x158(%rsp), %rdi leaq 0x83a3f(%rip), %rsi # 0x10da4d movb $0x0, %al callq 0x2c040 movq %rax, 0x58(%rsp) movq %rdx, 0x60(%rsp) movl $0xffffffff, 0x184(%rsp) # imm = 0xFFFFFFFF jmp 0x8a0b6 jmp 0x8a031 movq 0x158(%rsp), %rdi leaq 0x68(%rsp), %rsi callq 0x5f740 jmp 0x8a0a8 movl 0x1a0(%rsp), %eax andl $0x4000, %eax # imm = 0x4000 cmpl $0x0, %eax jne 0x8a079 movl 0x1a0(%rsp), %eax andl $0x8000, %eax # imm = 0x8000 cmpl $0x0, %eax je 0x8a0a6 movq 0x158(%rsp), %rdi callq 0x36c80 cmpl $0x0, %eax je 0x8a0a6 movq 0x158(%rsp), %rdi leaq 0x839dd(%rip), %rsi # 0x10da65 movb $0x0, %al callq 0x2c040 movq %rax, 0x48(%rsp) movq %rdx, 0x50(%rsp) movl $0xffffffff, 0x184(%rsp) # imm = 0xFFFFFFFF jmp 0x8a0b6 jmp 0x8a0a8 movl 0x114(%rsp), %eax movl %eax, 0x184(%rsp) movl 0x184(%rsp), %eax addq $0x188, %rsp # imm = 0x188 retq nopw %cs:(%rax,%rax)
js_proxy_set: sub rsp, 188h mov eax, [rsp+188h+arg_10] lea rax, [rsp+188h+arg_0] mov [rsp+188h+var_148], rax mov [rsp+188h+var_18], rsi mov [rsp+188h+var_10], rdx mov [rsp+188h+var_28], r8 mov [rsp+188h+var_20], r9 mov [rsp+188h+var_30], rdi mov [rsp+188h+var_34], ecx mov rdi, [rsp+188h+var_30] mov rdx, [rsp+188h+var_18] mov rcx, [rsp+188h+var_10] lea rsi, [rsp+188h+var_50] mov r8d, 43h ; 'C' call get_proxy_method mov [rsp+188h+var_40], rax cmp [rsp+188h+var_40], 0 jnz short loc_89C78 mov [rsp+188h+var_4], 0FFFFFFFFh jmp loc_8A0B6 loc_89C78: mov rdi, [rsp+188h+var_50] mov rsi, [rsp+188h+var_48] call JS_IsUndefined_0 cmp eax, 0 jz loc_89D48 mov rax, [rsp+188h+var_30] mov [rsp+188h+var_160], rax mov rax, [rsp+188h+var_40] mov [rsp+188h+var_150], rax mov eax, [rsp+188h+var_34] mov [rsp+188h+var_154], eax mov rdi, [rsp+188h+var_28] mov rsi, [rsp+188h+var_20] call js_dup mov rdi, [rsp+188h+var_160] mov ecx, [rsp+188h+var_154] mov r10, [rsp+188h+var_148] mov rsi, rax mov rax, rdx mov rdx, [rsp+188h+var_150] mov [rsp+188h+var_C8], rsi mov [rsp+188h+var_C0], rax mov eax, [rsp+188h+arg_10] mov rsi, [rdx] mov rdx, [rdx+8] mov r8, [rsp+188h+var_C8] mov r9, [rsp+188h+var_C0] xor r11d, r11d mov r11, [r10] mov [rsp+188h+var_188], r11 mov r10, [r10+8] mov [rsp+188h+var_180], r10 mov [rsp+188h+var_178], eax mov [rsp+188h+var_170], 0 call JS_SetPropertyInternal2 mov [rsp+188h+var_4], eax jmp loc_8A0B6 loc_89D48: mov rdi, [rsp+188h+var_30] mov esi, [rsp+188h+var_34] call JS_AtomToValue mov [rsp+188h+var_D8], rax mov [rsp+188h+var_D0], rdx mov rax, [rsp+188h+var_D8] mov [rsp+188h+var_70], rax mov rax, [rsp+188h+var_D0] mov [rsp+188h+var_68], rax mov rdi, [rsp+188h+var_70] mov rsi, [rsp+188h+var_68] call JS_IsException_1 cmp eax, 0 jz short loc_89DD3 mov rdi, [rsp+188h+var_30] mov rsi, [rsp+188h+var_50] mov rdx, [rsp+188h+var_48] call JS_FreeValue mov [rsp+188h+var_4], 0FFFFFFFFh jmp loc_8A0B6 loc_89DD3: mov rax, [rsp+188h+var_148] mov rcx, [rsp+188h+var_40] mov rdx, [rcx] mov [rsp+188h+var_B8], rdx mov rcx, [rcx+8] mov [rsp+188h+var_B0], rcx mov rcx, [rsp+188h+var_70] mov [rsp+188h+var_A8], rcx mov rcx, [rsp+188h+var_68] mov [rsp+188h+var_A0], rcx mov rcx, [rsp+188h+var_28] mov [rsp+188h+var_98], rcx mov rcx, [rsp+188h+var_20] mov [rsp+188h+var_90], rcx mov rcx, [rax] mov [rsp+188h+var_88], rcx mov rax, [rax+8] mov [rsp+188h+var_80], rax mov rdi, [rsp+188h+var_30] mov r8, [rsp+188h+var_40] lea rax, [rsp+188h+var_B8] mov rsi, [rsp+188h+var_50] mov rdx, [rsp+188h+var_48] mov rcx, [r8+10h] mov r8, [r8+18h] mov r9d, 4 mov [rsp+188h+var_188], rax call JS_CallFree mov [rsp+188h+var_E8], rax mov [rsp+188h+var_E0], rdx mov rax, [rsp+188h+var_E8] mov [rsp+188h+var_60], rax mov rax, [rsp+188h+var_E0] mov [rsp+188h+var_58], rax mov rdi, [rsp+188h+var_30] mov rsi, [rsp+188h+var_70] mov rdx, [rsp+188h+var_68] call JS_FreeValue mov rdi, [rsp+188h+var_60] mov rsi, [rsp+188h+var_58] call JS_IsException_1 cmp eax, 0 jz short loc_89F04 mov [rsp+188h+var_4], 0FFFFFFFFh jmp loc_8A0B6 loc_89F04: mov rdi, [rsp+188h+var_30] mov rsi, [rsp+188h+var_60] mov rdx, [rsp+188h+var_58] call JS_ToBoolFree mov [rsp+188h+var_74], eax cmp [rsp+188h+var_74], 0 jz loc_8A045 mov rdi, [rsp+188h+var_30] mov rax, [rsp+188h+var_40] mov rdx, [rax] mov ecx, [rsp+188h+var_34] lea rsi, [rsp+188h+var_120] call JS_GetOwnPropertyInternal mov [rsp+188h+var_78], eax cmp [rsp+188h+var_78], 0 jge short loc_89F7B mov [rsp+188h+var_4], 0FFFFFFFFh jmp loc_8A0B6 loc_89F7B: cmp [rsp+188h+var_78], 0 jz loc_8A043 mov eax, [rsp+188h+var_120] and eax, 13h cmp eax, 0 jnz short loc_89FC5 mov rdi, [rsp+188h+var_30] mov rsi, [rsp+188h+var_118] mov rdx, [rsp+188h+var_110] mov rcx, [rsp+188h+var_28] mov r8, [rsp+188h+var_20] call js_same_value cmp eax, 0 jnz short loc_89FC3 jmp short loc_89FED loc_89FC3: jmp short loc_8A031 loc_89FC5: mov eax, [rsp+188h+var_120] and eax, 11h cmp eax, 10h jnz short loc_8A02F mov rdi, [rsp+188h+var_F8] mov rsi, [rsp+188h+var_F0] call JS_IsUndefined_0 cmp eax, 0 jz short loc_8A02F jmp short $+2 loc_89FED: mov rdi, [rsp+188h+var_30] lea rsi, [rsp+188h+var_120] call js_free_desc mov rdi, [rsp+188h+var_30] lea rsi, aProxyInconsist_7; "proxy: inconsistent set" mov al, 0 call JS_ThrowTypeError mov [rsp+188h+var_130], rax mov [rsp+188h+var_128], rdx mov [rsp+188h+var_4], 0FFFFFFFFh jmp loc_8A0B6 loc_8A02F: jmp short $+2 loc_8A031: mov rdi, [rsp+188h+var_30] lea rsi, [rsp+188h+var_120] call js_free_desc loc_8A043: jmp short loc_8A0A8 loc_8A045: mov eax, [rsp+188h+arg_10] and eax, 4000h cmp eax, 0 jnz short loc_8A079 mov eax, [rsp+188h+arg_10] and eax, 8000h cmp eax, 0 jz short loc_8A0A6 mov rdi, [rsp+188h+var_30] call is_strict_mode cmp eax, 0 jz short loc_8A0A6 loc_8A079: mov rdi, [rsp+188h+var_30] lea rsi, aProxyCannotSet; "proxy: cannot set property" mov al, 0 call JS_ThrowTypeError mov [rsp+188h+var_140], rax mov [rsp+188h+var_138], rdx mov [rsp+188h+var_4], 0FFFFFFFFh jmp short loc_8A0B6 loc_8A0A6: jmp short $+2 loc_8A0A8: mov eax, [rsp+188h+var_74] mov [rsp+188h+var_4], eax loc_8A0B6: mov eax, [rsp+188h+var_4] add rsp, 188h retn
long long js_proxy_set( long long a1, long long a2, long long a3, unsigned int a4, _DWORD *a5, long long a6, __m128 a7, __m128 a8, __m128 a9, __m128 a10, double a11, double a12, __m128 a13, __m128 a14, long long a15, long long a16, unsigned int a17) { long long v17; // rdx long long v18; // rdx long long v19; // rdx long long v20; // rdx long long v21; // rcx long long v22; // r8 long long v23; // r9 __m128 v24; // xmm4 __m128 v25; // xmm5 long long v26; // rdx long long v27; // rcx long long v28; // r8 long long v29; // r9 __m128 v30; // xmm4 __m128 v31; // xmm5 char v33; // [rsp+0h] [rbp-188h] long long v34; // [rsp+28h] [rbp-160h] unsigned int v35; // [rsp+34h] [rbp-154h] long long *v36; // [rsp+38h] [rbp-150h] long long v37[2]; // [rsp+68h] [rbp-120h] BYREF long long v38; // [rsp+78h] [rbp-110h] long long v39; // [rsp+90h] [rbp-F8h] long long v40; // [rsp+98h] [rbp-F0h] long long v41; // [rsp+A0h] [rbp-E8h] long long v42; // [rsp+A8h] [rbp-E0h] long long v43; // [rsp+B0h] [rbp-D8h] long long v44; // [rsp+B8h] [rbp-D0h] _DWORD *v45; // [rsp+C0h] [rbp-C8h] _QWORD v46[8]; // [rsp+D0h] [rbp-B8h] BYREF int OwnPropertyInternal; // [rsp+110h] [rbp-78h] unsigned int v48; // [rsp+114h] [rbp-74h] long long v49; // [rsp+118h] [rbp-70h] long long v50; // [rsp+120h] [rbp-68h] long long v51; // [rsp+128h] [rbp-60h] long long v52; // [rsp+130h] [rbp-58h] long long v53; // [rsp+138h] [rbp-50h] BYREF long long v54; // [rsp+140h] [rbp-48h] long long *proxy_method; // [rsp+148h] [rbp-40h] unsigned int v56; // [rsp+154h] [rbp-34h] long long v57; // [rsp+158h] [rbp-30h] _DWORD *v58; // [rsp+160h] [rbp-28h] long long v59; // [rsp+168h] [rbp-20h] long long v60; // [rsp+170h] [rbp-18h] long long v61; // [rsp+178h] [rbp-10h] v60 = a2; v61 = a3; v58 = a5; v59 = a6; v57 = a1; v56 = a4; proxy_method = (long long *)get_proxy_method(a1, &v53, a2, a3, 67); if ( proxy_method ) { if ( JS_IsUndefined_0(v53, v54) ) { v34 = v57; v36 = proxy_method; v35 = v56; v45 = js_dup(v58, v59); return (unsigned int)JS_SetPropertyInternal2( v34, (_DWORD *)*v36, v36[1], v35, (long long)v45, v17, a15, a16, a17, 0LL); } v43 = JS_AtomToValue(v57, v56); v44 = v18; v49 = v43; v50 = v18; if ( JS_IsException_1(v43, v18) ) { JS_FreeValue(v57, v53, v54); return (unsigned int)-1; } v46[0] = *proxy_method; v46[1] = proxy_method[1]; v46[2] = v49; v46[3] = v50; v46[4] = v58; v46[5] = v59; v46[6] = a15; v46[7] = a16; v41 = JS_CallFree(v57, v53, v54, proxy_method[2], proxy_method[3], 4, (long long)v46); v42 = v19; v51 = v41; v52 = v19; JS_FreeValue(v57, v49, v50); if ( JS_IsException_1(v51, v52) ) return (unsigned int)-1; v48 = JS_ToBoolFree(v57, v51, v52); if ( v48 ) { OwnPropertyInternal = JS_GetOwnPropertyInternal(v57, (long long)v37, *proxy_method, v56); if ( OwnPropertyInternal < 0 ) return (unsigned int)-1; if ( OwnPropertyInternal ) { if ( (v37[0] & 0x13) != 0 ) { if ( (v37[0] & 0x11) != 0x10 || !JS_IsUndefined_0(v39, v40) ) goto LABEL_19; } else if ( (unsigned int)js_same_value(v57, (_DWORD *)v37[1], v38, v58, v59) ) { LABEL_19: js_free_desc(v57, v37); return v48; } js_free_desc(v57, v37); JS_ThrowTypeError( v57, (long long)"proxy: inconsistent set", v26, v27, v28, v29, a7, a8, a9, a10, v30, v31, a13, a14, v33); return (unsigned int)-1; } } else if ( (a17 & 0x4000) != 0 || (a17 & 0x8000) != 0 && is_strict_mode(v57) ) { JS_ThrowTypeError( v57, (long long)"proxy: cannot set property", v20, v21, v22, v23, a7, a8, a9, a10, v24, v25, a13, a14, v33); return (unsigned int)-1; } return v48; } return (unsigned int)-1; }
js_proxy_set: SUB RSP,0x188 MOV EAX,dword ptr [RSP + 0x1a0] LEA RAX,[RSP + 0x190] MOV qword ptr [RSP + 0x40],RAX MOV qword ptr [RSP + 0x170],RSI MOV qword ptr [RSP + 0x178],RDX MOV qword ptr [RSP + 0x160],R8 MOV qword ptr [RSP + 0x168],R9 MOV qword ptr [RSP + 0x158],RDI MOV dword ptr [RSP + 0x154],ECX MOV RDI,qword ptr [RSP + 0x158] MOV RDX,qword ptr [RSP + 0x170] MOV RCX,qword ptr [RSP + 0x178] LEA RSI,[RSP + 0x138] MOV R8D,0x43 CALL 0x0015edb0 MOV qword ptr [RSP + 0x148],RAX CMP qword ptr [RSP + 0x148],0x0 JNZ 0x00189c78 MOV dword ptr [RSP + 0x184],0xffffffff JMP 0x0018a0b6 LAB_00189c78: MOV RDI,qword ptr [RSP + 0x138] MOV RSI,qword ptr [RSP + 0x140] CALL 0x0012cfa0 CMP EAX,0x0 JZ 0x00189d48 MOV RAX,qword ptr [RSP + 0x158] MOV qword ptr [RSP + 0x28],RAX MOV RAX,qword ptr [RSP + 0x148] MOV qword ptr [RSP + 0x38],RAX MOV EAX,dword ptr [RSP + 0x154] MOV dword ptr [RSP + 0x34],EAX MOV RDI,qword ptr [RSP + 0x160] MOV RSI,qword ptr [RSP + 0x168] CALL 0x00120410 MOV RDI,qword ptr [RSP + 0x28] MOV ECX,dword ptr [RSP + 0x34] MOV R10,qword ptr [RSP + 0x40] MOV RSI,RAX MOV RAX,RDX MOV RDX,qword ptr [RSP + 0x38] MOV qword ptr [RSP + 0xc0],RSI MOV qword ptr [RSP + 0xc8],RAX MOV EAX,dword ptr [RSP + 0x1a0] MOV RSI,qword ptr [RDX] MOV RDX,qword ptr [RDX + 0x8] MOV R8,qword ptr [RSP + 0xc0] MOV R9,qword ptr [RSP + 0xc8] XOR R11D,R11D MOV R11,qword ptr [R10] MOV qword ptr [RSP],R11 MOV R10,qword ptr [R10 + 0x8] MOV qword ptr [RSP + 0x8],R10 MOV dword ptr [RSP + 0x10],EAX MOV qword ptr [RSP + 0x18],0x0 CALL 0x00130cc0 MOV dword ptr [RSP + 0x184],EAX JMP 0x0018a0b6 LAB_00189d48: MOV RDI,qword ptr [RSP + 0x158] MOV ESI,dword ptr [RSP + 0x154] CALL 0x00127b70 MOV qword ptr [RSP + 0xb0],RAX MOV qword ptr [RSP + 0xb8],RDX MOV RAX,qword ptr [RSP + 0xb0] MOV qword ptr [RSP + 0x118],RAX MOV RAX,qword ptr [RSP + 0xb8] MOV qword ptr [RSP + 0x120],RAX MOV RDI,qword ptr [RSP + 0x118] MOV RSI,qword ptr [RSP + 0x120] CALL 0x00122a00 CMP EAX,0x0 JZ 0x00189dd3 MOV RDI,qword ptr [RSP + 0x158] MOV RSI,qword ptr [RSP + 0x138] MOV RDX,qword ptr [RSP + 0x140] CALL 0x001229d0 MOV dword ptr [RSP + 0x184],0xffffffff JMP 0x0018a0b6 LAB_00189dd3: MOV RAX,qword ptr [RSP + 0x40] MOV RCX,qword ptr [RSP + 0x148] MOV RDX,qword ptr [RCX] MOV qword ptr [RSP + 0xd0],RDX MOV RCX,qword ptr [RCX + 0x8] MOV qword ptr [RSP + 0xd8],RCX MOV RCX,qword ptr [RSP + 0x118] MOV qword ptr [RSP + 0xe0],RCX MOV RCX,qword ptr [RSP + 0x120] MOV qword ptr [RSP + 0xe8],RCX MOV RCX,qword ptr [RSP + 0x160] MOV qword ptr [RSP + 0xf0],RCX MOV RCX,qword ptr [RSP + 0x168] MOV qword ptr [RSP + 0xf8],RCX MOV RCX,qword ptr [RAX] MOV qword ptr [RSP + 0x100],RCX MOV RAX,qword ptr [RAX + 0x8] MOV qword ptr [RSP + 0x108],RAX MOV RDI,qword ptr [RSP + 0x158] MOV R8,qword ptr [RSP + 0x148] LEA RAX,[RSP + 0xd0] MOV RSI,qword ptr [RSP + 0x138] MOV RDX,qword ptr [RSP + 0x140] MOV RCX,qword ptr [R8 + 0x10] MOV R8,qword ptr [R8 + 0x18] MOV R9D,0x4 MOV qword ptr [RSP],RAX CALL 0x0012cfc0 MOV qword ptr [RSP + 0xa0],RAX MOV qword ptr [RSP + 0xa8],RDX MOV RAX,qword ptr [RSP + 0xa0] MOV qword ptr [RSP + 0x128],RAX MOV RAX,qword ptr [RSP + 0xa8] MOV qword ptr [RSP + 0x130],RAX MOV RDI,qword ptr [RSP + 0x158] MOV RSI,qword ptr [RSP + 0x118] MOV RDX,qword ptr [RSP + 0x120] CALL 0x001229d0 MOV RDI,qword ptr [RSP + 0x128] MOV RSI,qword ptr [RSP + 0x130] CALL 0x00122a00 CMP EAX,0x0 JZ 0x00189f04 MOV dword ptr [RSP + 0x184],0xffffffff JMP 0x0018a0b6 LAB_00189f04: MOV RDI,qword ptr [RSP + 0x158] MOV RSI,qword ptr [RSP + 0x128] MOV RDX,qword ptr [RSP + 0x130] CALL 0x0012d070 MOV dword ptr [RSP + 0x114],EAX CMP dword ptr [RSP + 0x114],0x0 JZ 0x0018a045 MOV RDI,qword ptr [RSP + 0x158] MOV RAX,qword ptr [RSP + 0x148] MOV RDX,qword ptr [RAX] MOV ECX,dword ptr [RSP + 0x154] LEA RSI,[RSP + 0x68] CALL 0x0012ef00 MOV dword ptr [RSP + 0x110],EAX CMP dword ptr [RSP + 0x110],0x0 JGE 0x00189f7b MOV dword ptr [RSP + 0x184],0xffffffff JMP 0x0018a0b6 LAB_00189f7b: CMP dword ptr [RSP + 0x110],0x0 JZ 0x0018a043 MOV EAX,dword ptr [RSP + 0x68] AND EAX,0x13 CMP EAX,0x0 JNZ 0x00189fc5 MOV RDI,qword ptr [RSP + 0x158] MOV RSI,qword ptr [RSP + 0x70] MOV RDX,qword ptr [RSP + 0x78] MOV RCX,qword ptr [RSP + 0x160] MOV R8,qword ptr [RSP + 0x168] CALL 0x00134850 CMP EAX,0x0 JNZ 0x00189fc3 JMP 0x00189fed LAB_00189fc3: JMP 0x0018a031 LAB_00189fc5: MOV EAX,dword ptr [RSP + 0x68] AND EAX,0x11 CMP EAX,0x10 JNZ 0x0018a02f MOV RDI,qword ptr [RSP + 0x90] MOV RSI,qword ptr [RSP + 0x98] CALL 0x0012cfa0 CMP EAX,0x0 JZ 0x0018a02f JMP 0x00189fed LAB_00189fed: MOV RDI,qword ptr [RSP + 0x158] LEA RSI,[RSP + 0x68] CALL 0x0015f740 MOV RDI,qword ptr [RSP + 0x158] LEA RSI,[0x20da4d] MOV AL,0x0 CALL 0x0012c040 MOV qword ptr [RSP + 0x58],RAX MOV qword ptr [RSP + 0x60],RDX MOV dword ptr [RSP + 0x184],0xffffffff JMP 0x0018a0b6 LAB_0018a02f: JMP 0x0018a031 LAB_0018a031: MOV RDI,qword ptr [RSP + 0x158] LEA RSI,[RSP + 0x68] CALL 0x0015f740 LAB_0018a043: JMP 0x0018a0a8 LAB_0018a045: MOV EAX,dword ptr [RSP + 0x1a0] AND EAX,0x4000 CMP EAX,0x0 JNZ 0x0018a079 MOV EAX,dword ptr [RSP + 0x1a0] AND EAX,0x8000 CMP EAX,0x0 JZ 0x0018a0a6 MOV RDI,qword ptr [RSP + 0x158] CALL 0x00136c80 CMP EAX,0x0 JZ 0x0018a0a6 LAB_0018a079: MOV RDI,qword ptr [RSP + 0x158] LEA RSI,[0x20da65] MOV AL,0x0 CALL 0x0012c040 MOV qword ptr [RSP + 0x48],RAX MOV qword ptr [RSP + 0x50],RDX MOV dword ptr [RSP + 0x184],0xffffffff JMP 0x0018a0b6 LAB_0018a0a6: JMP 0x0018a0a8 LAB_0018a0a8: MOV EAX,dword ptr [RSP + 0x114] MOV dword ptr [RSP + 0x184],EAX LAB_0018a0b6: MOV EAX,dword ptr [RSP + 0x184] ADD RSP,0x188 RET
int js_proxy_set(int8 param_1,int8 param_2,int8 param_3,int4 param_4, int8 param_5,int8 param_6,int8 param_7,int8 param_8, uint param_9) { int8 *puVar1; int4 uVar2; int8 uVar3; int iVar4; uint local_120 [2]; int8 local_118; int8 local_110; int8 local_f8; int8 local_f0; int1 local_e8 [16]; int1 local_d8 [16]; int1 local_c8 [16]; int8 local_b8; int8 local_b0; int1 local_a8 [16]; int8 local_98; int8 local_90; int8 local_88; int8 local_80; int local_78; int local_74; int1 local_70 [16]; int1 local_60 [16]; int8 local_50; int8 local_48; int8 *local_40; int4 local_34; int8 local_30; int8 local_28; int8 local_20; int8 local_18; int8 local_10; local_34 = param_4; local_30 = param_1; local_28 = param_5; local_20 = param_6; local_18 = param_2; local_10 = param_3; local_40 = (int8 *)get_proxy_method(param_1,&local_50,param_2,param_3,0x43); if (local_40 == (int8 *)0x0) { return -1; } iVar4 = JS_IsUndefined(local_50,local_48); uVar3 = local_30; uVar2 = local_34; puVar1 = local_40; if (iVar4 != 0) { local_c8 = js_dup(local_28,local_20); iVar4 = JS_SetPropertyInternal2 (uVar3,*puVar1,puVar1[1],uVar2,local_c8._0_8_,local_c8._8_8_,param_7,param_8, param_9,0); return iVar4; } local_d8 = JS_AtomToValue(local_30,local_34); local_70 = local_d8; iVar4 = JS_IsException(local_d8._0_8_,local_d8._8_8_); if (iVar4 != 0) { JS_FreeValue(local_30,local_50,local_48); return -1; } local_b8 = *local_40; local_b0 = local_40[1]; local_98 = local_28; local_90 = local_20; local_88 = param_7; local_80 = param_8; local_a8 = local_70; local_e8 = JS_CallFree(local_30,local_50,local_48,local_40[2],local_40[3],4,&local_b8); local_60 = local_e8; JS_FreeValue(local_30,local_70._0_8_,local_70._8_8_); iVar4 = JS_IsException(local_60._0_8_,local_60._8_8_); if (iVar4 != 0) { return -1; } local_74 = JS_ToBoolFree(local_30,local_60._0_8_,local_60._8_8_); if (local_74 == 0) { if ((param_9 & 0x4000) != 0) { LAB_0018a079: JS_ThrowTypeError(local_30,"proxy: cannot set property"); return -1; } if ((param_9 & 0x8000) != 0) { iVar4 = is_strict_mode(local_30); if (iVar4 != 0) goto LAB_0018a079; } } else { local_78 = JS_GetOwnPropertyInternal(local_30,local_120,*local_40,local_34); if (local_78 < 0) { return -1; } if (local_78 != 0) { if ((local_120[0] & 0x13) == 0) { iVar4 = js_same_value(local_30,local_118,local_110,local_28,local_20); if (iVar4 == 0) { LAB_00189fed: js_free_desc(local_30,local_120); JS_ThrowTypeError(local_30,"proxy: inconsistent set"); return -1; } } else if ((local_120[0] & 0x11) == 0x10) { iVar4 = JS_IsUndefined(local_f8,local_f0); if (iVar4 != 0) goto LAB_00189fed; } js_free_desc(local_30,local_120); } } return local_74; }
20,589
js_proxy_set
bluesky950520[P]quickjs/quickjs.c
static int js_proxy_set(JSContext *ctx, JSValue obj, JSAtom atom, JSValue value, JSValue receiver, int flags) { JSProxyData *s; JSValue method, ret1, atom_val; int ret, res; JSValue args[4]; s = get_proxy_method(ctx, &method, obj, JS_ATOM_set); if (!s) return -1; if (JS_IsUndefined(method)) { return JS_SetPropertyInternal2(ctx, s->target, atom, js_dup(value), receiver, flags, NULL); } atom_val = JS_AtomToValue(ctx, atom); if (JS_IsException(atom_val)) { JS_FreeValue(ctx, method); return -1; } args[0] = s->target; args[1] = atom_val; args[2] = value; args[3] = receiver; ret1 = JS_CallFree(ctx, method, s->handler, 4, args); JS_FreeValue(ctx, atom_val); if (JS_IsException(ret1)) return -1; ret = JS_ToBoolFree(ctx, ret1); if (ret) { JSPropertyDescriptor desc; res = JS_GetOwnPropertyInternal(ctx, &desc, JS_VALUE_GET_OBJ(s->target), atom); if (res < 0) return -1; if (res) { if ((desc.flags & (JS_PROP_GETSET | JS_PROP_CONFIGURABLE | JS_PROP_WRITABLE)) == 0) { if (!js_same_value(ctx, desc.value, value)) { goto fail; } } else if ((desc.flags & (JS_PROP_GETSET | JS_PROP_CONFIGURABLE)) == JS_PROP_GETSET && JS_IsUndefined(desc.setter)) { fail: js_free_desc(ctx, &desc); JS_ThrowTypeError(ctx, "proxy: inconsistent set"); return -1; } js_free_desc(ctx, &desc); } } else { if ((flags & JS_PROP_THROW) || ((flags & JS_PROP_THROW_STRICT) && is_strict_mode(ctx))) { JS_ThrowTypeError(ctx, "proxy: cannot set property"); return -1; } } return ret; }
O1
c
js_proxy_set: pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0xc8, %rsp movq %r9, %r14 movq %r8, %r15 movl %ecx, %r12d movq %rdx, %rcx movq %rsi, %rdx movq %rdi, %rbx leaq 0x38(%rsp), %rsi movl $0x43, %r8d callq 0x3c7cc movl $0xffffffff, %ebp # imm = 0xFFFFFFFF testq %rax, %rax je 0x4e823 movq %rax, %r13 movl 0x110(%rsp), %ecx leaq 0x100(%rsp), %rdi movq 0x40(%rsp), %rbp cmpl $0x3, %ebp jne 0x4e6d2 movq %r15, 0x80(%rsp) cmpl $-0x9, %r14d jb 0x4e6a0 movq 0x80(%rsp), %rax incl (%rax) movq (%r13), %rsi movq 0x8(%r13), %rdx movups (%rdi), %xmm0 movups %xmm0, (%rsp) movl %ecx, 0x10(%rsp) movq $0x0, 0x18(%rsp) movq %rbx, %rdi movl %r12d, %ecx movq %r15, %r8 movq %r14, %r9 callq 0x23774 jmp 0x4e825 movq %r14, 0x20(%rsp) movq %rbx, %rdi movl %r12d, %esi xorl %edx, %edx callq 0x1fb46 movq %rdx, %r14 cmpl $0x6, %r14d jne 0x4e703 movq 0x38(%rsp), %rsi movq 0x18(%rbx), %rdi movq %rbp, %rdx callq 0x1ccb2 jmp 0x4e81e movups (%r13), %xmm0 leaq 0x80(%rsp), %rdx movaps %xmm0, (%rdx) movq %rax, 0x10(%rdx) movq %r14, 0x18(%rdx) movq %r15, 0x20(%rdx) movq 0x20(%rsp), %rcx movq %rcx, 0x28(%rdx) leaq 0x100(%rsp), %rcx movups (%rcx), %xmm0 movaps %xmm0, 0x30(%rdx) movq %rax, 0x30(%rsp) movq 0x38(%rsp), %rsi movq 0x10(%r13), %rcx movq 0x18(%r13), %r8 movq %rdx, (%rsp) movq %rbx, %rdi movq %rbp, %rdx movl $0x4, %r9d callq 0x22089 movq %rax, 0x28(%rsp) movq %rdx, %rbp movq 0x18(%rbx), %rdi movq 0x30(%rsp), %rsi movq %r14, %rdx callq 0x1ccb2 cmpl $0x6, %ebp je 0x4e81e movq %rbx, %rdi movq 0x28(%rsp), %rsi movq %rbp, %rdx callq 0x220f9 movl %eax, %ebp testl %eax, %eax je 0x4e7e5 movq (%r13), %rdx leaq 0x48(%rsp), %rsi movq %rbx, %rdi movl %r12d, %ecx callq 0x22fc5 testl %eax, %eax js 0x4e81e je 0x4e823 movl 0x48(%rsp), %eax testb $0x13, %al je 0x4e837 andl $0x11, %eax cmpl $0x10, %eax jne 0x4e859 cmpl $0x3, 0x78(%rsp) jne 0x4e859 leaq 0x48(%rsp), %rsi movq %rbx, %rdi callq 0x3ccaf leaq 0x5026e(%rip), %rsi # 0x9ea51 jmp 0x4e814 movl 0x110(%rsp), %eax btl $0xe, %eax jb 0x4e80d testw %ax, %ax jns 0x4e823 movq 0x18(%rbx), %rax movq 0x108(%rax), %rax testq %rax, %rax je 0x4e823 cmpl $0x0, 0x40(%rax) jns 0x4e823 leaq 0x50255(%rip), %rsi # 0x9ea69 movq %rbx, %rdi xorl %eax, %eax callq 0x21953 movl $0xffffffff, %ebp # imm = 0xFFFFFFFF movl %ebp, %eax addq $0xc8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq movq 0x50(%rsp), %rsi movq 0x58(%rsp), %rdx movq %rbx, %rdi movq %r15, %rcx movq 0x20(%rsp), %r8 callq 0x2584d testl %eax, %eax je 0x4e7cf leaq 0x48(%rsp), %rsi movq %rbx, %rdi callq 0x3ccaf jmp 0x4e823
js_proxy_set: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 0C8h mov r14, r9 mov r15, r8 mov r12d, ecx mov rcx, rdx mov rdx, rsi mov rbx, rdi lea rsi, [rsp+0F8h+var_C0] mov r8d, 43h ; 'C' call get_proxy_method mov ebp, 0FFFFFFFFh test rax, rax jz loc_4E823 mov r13, rax mov ecx, [rsp+0F8h+arg_10] lea rdi, [rsp+0F8h+arg_0] mov rbp, [rsp+0F8h+var_B8] cmp ebp, 3 jnz short loc_4E6D2 mov [rsp+0F8h+var_78], r15 cmp r14d, 0FFFFFFF7h jb short loc_4E6A0 mov rax, [rsp+0F8h+var_78] inc dword ptr [rax] loc_4E6A0: mov rsi, [r13+0] mov rdx, [r13+8] movups xmm0, xmmword ptr [rdi] movups [rsp+0F8h+var_F8], xmm0 mov [rsp+0F8h+var_E8], ecx mov [rsp+0F8h+var_E0], 0 mov rdi, rbx mov ecx, r12d mov r8, r15 mov r9, r14 call JS_SetPropertyInternal2 jmp loc_4E825 loc_4E6D2: mov [rsp+0F8h+var_D8], r14 mov rdi, rbx mov esi, r12d xor edx, edx call __JS_AtomToValue mov r14, rdx cmp r14d, 6 jnz short loc_4E703 mov rsi, [rsp+0F8h+var_C0] mov rdi, [rbx+18h] mov rdx, rbp call JS_FreeValueRT jmp loc_4E81E loc_4E703: movups xmm0, xmmword ptr [r13+0] lea rdx, [rsp+0F8h+var_78] movaps xmmword ptr [rdx], xmm0 mov [rdx+10h], rax mov [rdx+18h], r14 mov [rdx+20h], r15 mov rcx, [rsp+0F8h+var_D8] mov [rdx+28h], rcx lea rcx, [rsp+0F8h+arg_0] movups xmm0, xmmword ptr [rcx] movaps xmmword ptr [rdx+30h], xmm0 mov [rsp+0F8h+var_C8], rax mov rsi, [rsp+0F8h+var_C0] mov rcx, [r13+10h] mov r8, [r13+18h] mov qword ptr [rsp+0F8h+var_F8], rdx mov rdi, rbx mov rdx, rbp mov r9d, 4 call JS_CallFree mov [rsp+0F8h+var_D0], rax mov rbp, rdx mov rdi, [rbx+18h] mov rsi, [rsp+0F8h+var_C8] mov rdx, r14 call JS_FreeValueRT cmp ebp, 6 jz loc_4E81E mov rdi, rbx mov rsi, [rsp+0F8h+var_D0] mov rdx, rbp call JS_ToBoolFree mov ebp, eax test eax, eax jz short loc_4E7E5 mov rdx, [r13+0] lea rsi, [rsp+0F8h+var_B0] mov rdi, rbx mov ecx, r12d call JS_GetOwnPropertyInternal test eax, eax js short loc_4E81E jz short loc_4E823 mov eax, [rsp+0F8h+var_B0] test al, 13h jz short loc_4E837 and eax, 11h cmp eax, 10h jnz loc_4E859 cmp [rsp+0F8h+var_80], 3 jnz loc_4E859 loc_4E7CF: lea rsi, [rsp+0F8h+var_B0] mov rdi, rbx call js_free_desc lea rsi, aProxyInconsist_7; "proxy: inconsistent set" jmp short loc_4E814 loc_4E7E5: mov eax, [rsp+0F8h+arg_10] bt eax, 0Eh jb short loc_4E80D test ax, ax jns short loc_4E823 mov rax, [rbx+18h] mov rax, [rax+108h] test rax, rax jz short loc_4E823 cmp dword ptr [rax+40h], 0 jns short loc_4E823 loc_4E80D: lea rsi, aProxyCannotSet; "proxy: cannot set property" loc_4E814: mov rdi, rbx xor eax, eax call JS_ThrowTypeError loc_4E81E: mov ebp, 0FFFFFFFFh loc_4E823: mov eax, ebp loc_4E825: add rsp, 0C8h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn loc_4E837: mov rsi, [rsp+0F8h+var_A8] mov rdx, [rsp+0F8h+var_A0] mov rdi, rbx mov rcx, r15 mov r8, [rsp+0F8h+var_D8] call js_same_value test eax, eax jz loc_4E7CF loc_4E859: lea rsi, [rsp+0F8h+var_B0] mov rdi, rbx call js_free_desc jmp short loc_4E823
long long js_proxy_set( long long a1, long long a2, long long a3, unsigned int a4, _DWORD *a5, long long a6, __m128 a7, __m128 a8, __m128 a9, __m128 a10, __m128 a11, __m128 a12, __m128 a13, __m128 a14, __m128 a15, unsigned int a16) { long long *proxy_method; // rax double v20; // xmm4_8 double v21; // xmm5_8 unsigned int v22; // ebp long long *v23; // r13 long long v24; // rbp long long v26; // rax long long v27; // rdx long long v28; // r14 long long v29; // rdx long long v30; // rbp long long v31; // rdx long long v32; // rcx long long v33; // r8 long long v34; // r9 __m128 v35; // xmm4 __m128 v36; // xmm5 int OwnPropertyInternal; // eax const char *v38; // rsi long long v39; // rax char v40; // [rsp+0h] [rbp-F8h] long long v41; // [rsp+20h] [rbp-D8h] long long v42; // [rsp+28h] [rbp-D0h] _DWORD *v43; // [rsp+30h] [rbp-C8h] _DWORD *v44; // [rsp+38h] [rbp-C0h] BYREF long long v45; // [rsp+40h] [rbp-B8h] int v46; // [rsp+48h] [rbp-B0h] BYREF _DWORD *v47; // [rsp+50h] [rbp-A8h] long long v48; // [rsp+58h] [rbp-A0h] int v49; // [rsp+78h] [rbp-80h] __int128 v50; // [rsp+80h] [rbp-78h] BYREF long long v51; // [rsp+90h] [rbp-68h] long long v52; // [rsp+98h] [rbp-60h] _DWORD *v53; // [rsp+A0h] [rbp-58h] long long v54; // [rsp+A8h] [rbp-50h] __m128 v55; // [rsp+B0h] [rbp-48h] proxy_method = (long long *)get_proxy_method( a1, (unsigned long long *)&v44, a2, a3, 67LL, a6, a7, a8, a9, a10, a11, a12, a13, a14); v22 = -1; if ( !proxy_method ) return v22; v23 = proxy_method; v24 = v45; if ( (_DWORD)v45 != 3 ) { v41 = a6; v26 = _JS_AtomToValue(a1, a4, 0); v28 = v27; if ( (_DWORD)v27 == 6 ) { JS_FreeValueRT(*(_QWORD *)(a1 + 24), v44, v24); return (unsigned int)-1; } v50 = *(_OWORD *)v23; v51 = v26; v52 = v27; v53 = a5; v54 = v41; v55 = a15; v43 = (_DWORD *)v26; v42 = JS_CallFree(a1, v44, v24, v23[2], v23[3], 4, (long long)&v50); v30 = v29; JS_FreeValueRT(*(_QWORD *)(a1 + 24), v43, v28); if ( (_DWORD)v30 == 6 ) return (unsigned int)-1; v22 = JS_ToBoolFree(a1, v42, v30); if ( !v22 ) { if ( (a16 & 0x4000) == 0 ) { if ( (a16 & 0x8000u) == 0 ) return v22; v39 = *(_QWORD *)(*(_QWORD *)(a1 + 24) + 264LL); if ( !v39 || *(int *)(v39 + 64) >= 0 ) return v22; } v38 = "proxy: cannot set property"; goto LABEL_21; } OwnPropertyInternal = JS_GetOwnPropertyInternal(a1, (long long)&v46, *v23, a4); if ( OwnPropertyInternal < 0 ) return (unsigned int)-1; if ( !OwnPropertyInternal ) return v22; if ( (v46 & 0x13) != 0 ) { if ( (v46 & 0x11) == 0x10 && v49 == 3 ) goto LABEL_15; } else if ( !(unsigned int)js_same_value(a1, v47, v48, a5, v41) ) { LABEL_15: js_free_desc(a1, (long long)&v46); v38 = "proxy: inconsistent set"; LABEL_21: JS_ThrowTypeError(a1, (long long)v38, v31, v32, v33, v34, a15, a8, a9, a10, v35, v36, a13, a14, v40); return (unsigned int)-1; } js_free_desc(a1, (long long)&v46); return v22; } *(_QWORD *)&v50 = a5; if ( (unsigned int)a6 >= 0xFFFFFFF7 ) ++*(_DWORD *)v50; return JS_SetPropertyInternal2( a1, *proxy_method, proxy_method[1], a4, a5, a6, a15, a8, a9, a10, v20, v21, a13, a14, a15.m128_i64[0], a15.m128_i32[2], a16, 0LL); }
js_proxy_set: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0xc8 MOV R14,R9 MOV R15,R8 MOV R12D,ECX MOV RCX,RDX MOV RDX,RSI MOV RBX,RDI LEA RSI,[RSP + 0x38] MOV R8D,0x43 CALL 0x0013c7cc MOV EBP,0xffffffff TEST RAX,RAX JZ 0x0014e823 MOV R13,RAX MOV ECX,dword ptr [RSP + 0x110] LEA RDI,[RSP + 0x100] MOV RBP,qword ptr [RSP + 0x40] CMP EBP,0x3 JNZ 0x0014e6d2 MOV qword ptr [RSP + 0x80],R15 CMP R14D,-0x9 JC 0x0014e6a0 MOV RAX,qword ptr [RSP + 0x80] INC dword ptr [RAX] LAB_0014e6a0: MOV RSI,qword ptr [R13] MOV RDX,qword ptr [R13 + 0x8] MOVUPS XMM0,xmmword ptr [RDI] MOVUPS xmmword ptr [RSP],XMM0 MOV dword ptr [RSP + 0x10],ECX MOV qword ptr [RSP + 0x18],0x0 MOV RDI,RBX MOV ECX,R12D MOV R8,R15 MOV R9,R14 CALL 0x00123774 JMP 0x0014e825 LAB_0014e6d2: MOV qword ptr [RSP + 0x20],R14 MOV RDI,RBX MOV ESI,R12D XOR EDX,EDX CALL 0x0011fb46 MOV R14,RDX CMP R14D,0x6 JNZ 0x0014e703 MOV RSI,qword ptr [RSP + 0x38] MOV RDI,qword ptr [RBX + 0x18] MOV RDX,RBP CALL 0x0011ccb2 JMP 0x0014e81e LAB_0014e703: MOVUPS XMM0,xmmword ptr [R13] LEA RDX,[RSP + 0x80] MOVAPS xmmword ptr [RDX],XMM0 MOV qword ptr [RDX + 0x10],RAX MOV qword ptr [RDX + 0x18],R14 MOV qword ptr [RDX + 0x20],R15 MOV RCX,qword ptr [RSP + 0x20] MOV qword ptr [RDX + 0x28],RCX LEA RCX,[RSP + 0x100] MOVUPS XMM0,xmmword ptr [RCX] MOVAPS xmmword ptr [RDX + 0x30],XMM0 MOV qword ptr [RSP + 0x30],RAX MOV RSI,qword ptr [RSP + 0x38] MOV RCX,qword ptr [R13 + 0x10] MOV R8,qword ptr [R13 + 0x18] MOV qword ptr [RSP],RDX MOV RDI,RBX MOV RDX,RBP MOV R9D,0x4 CALL 0x00122089 MOV qword ptr [RSP + 0x28],RAX MOV RBP,RDX MOV RDI,qword ptr [RBX + 0x18] MOV RSI,qword ptr [RSP + 0x30] MOV RDX,R14 CALL 0x0011ccb2 CMP EBP,0x6 JZ 0x0014e81e MOV RDI,RBX MOV RSI,qword ptr [RSP + 0x28] MOV RDX,RBP CALL 0x001220f9 MOV EBP,EAX TEST EAX,EAX JZ 0x0014e7e5 MOV RDX,qword ptr [R13] LEA RSI,[RSP + 0x48] MOV RDI,RBX MOV ECX,R12D CALL 0x00122fc5 TEST EAX,EAX JS 0x0014e81e JZ 0x0014e823 MOV EAX,dword ptr [RSP + 0x48] TEST AL,0x13 JZ 0x0014e837 AND EAX,0x11 CMP EAX,0x10 JNZ 0x0014e859 CMP dword ptr [RSP + 0x78],0x3 JNZ 0x0014e859 LAB_0014e7cf: LEA RSI,[RSP + 0x48] MOV RDI,RBX CALL 0x0013ccaf LEA RSI,[0x19ea51] JMP 0x0014e814 LAB_0014e7e5: MOV EAX,dword ptr [RSP + 0x110] BT EAX,0xe JC 0x0014e80d TEST AX,AX JNS 0x0014e823 MOV RAX,qword ptr [RBX + 0x18] MOV RAX,qword ptr [RAX + 0x108] TEST RAX,RAX JZ 0x0014e823 CMP dword ptr [RAX + 0x40],0x0 JNS 0x0014e823 LAB_0014e80d: LEA RSI,[0x19ea69] LAB_0014e814: MOV RDI,RBX XOR EAX,EAX CALL 0x00121953 LAB_0014e81e: MOV EBP,0xffffffff LAB_0014e823: MOV EAX,EBP LAB_0014e825: ADD RSP,0xc8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET LAB_0014e837: MOV RSI,qword ptr [RSP + 0x50] MOV RDX,qword ptr [RSP + 0x58] MOV RDI,RBX MOV RCX,R15 MOV R8,qword ptr [RSP + 0x20] CALL 0x0012584d TEST EAX,EAX JZ 0x0014e7cf LAB_0014e859: LEA RSI,[RSP + 0x48] MOV RDI,RBX CALL 0x0013ccaf JMP 0x0014e823
ulong js_proxy_set(long param_1,int8 param_2,int8 param_3,int4 param_4, int *param_5,int8 param_6,int8 param_7,int4 param_8,uint param_9 ) { long lVar1; uint uVar2; int iVar3; int8 *puVar4; ulong uVar5; int8 uVar6; int8 uVar7; char *pcVar8; int1 auVar9 [16]; int8 local_c0; int8 local_b8; uint local_b0 [2]; int8 local_a8; int8 local_a0; int local_80; int *local_78; int8 uStack_70; int1 local_68 [16]; int *local_58; int8 local_50; int4 local_48; int4 uStack_40; puVar4 = (int8 *)get_proxy_method(param_1,&local_c0,param_2,param_3,0x43); if (puVar4 == (int8 *)0x0) { return 0xffffffff; } if ((int)local_b8 == 3) { if (0xfffffff6 < (uint)param_6) { *param_5 = *param_5 + 1; } local_78 = param_5; uVar5 = JS_SetPropertyInternal2 (param_1,*puVar4,puVar4[1],param_4,param_5,param_6,param_7,param_8,param_9,0); return uVar5; } local_68 = __JS_AtomToValue(param_1,param_4,0); uVar7 = local_68._8_8_; uVar6 = local_68._0_8_; if (local_68._8_4_ == 6) { JS_FreeValueRT(*(int8 *)(param_1 + 0x18),local_c0,local_b8); } else { local_78 = (int *)*puVar4; uStack_70 = puVar4[1]; local_48 = (int4)param_7; uStack_40 = param_8; local_58 = param_5; local_50 = param_6; auVar9 = JS_CallFree(param_1,local_c0,local_b8,puVar4[2],puVar4[3],4,&local_78); JS_FreeValueRT(*(int8 *)(param_1 + 0x18),uVar6,uVar7); if (auVar9._8_4_ != 6) { uVar2 = JS_ToBoolFree(param_1,auVar9._0_8_,auVar9._8_8_); uVar5 = (ulong)uVar2; if (uVar2 == 0) { if ((param_9 >> 0xe & 1) == 0) { if (-1 < (short)param_9) { return uVar5; } lVar1 = *(long *)(*(long *)(param_1 + 0x18) + 0x108); if (lVar1 == 0) { return uVar5; } if (-1 < *(int *)(lVar1 + 0x40)) { return uVar5; } } pcVar8 = "proxy: cannot set property"; } else { iVar3 = JS_GetOwnPropertyInternal(param_1,local_b0,*puVar4,param_4); if (iVar3 < 0) { return 0xffffffff; } if (iVar3 == 0) { return uVar5; } if ((local_b0[0] & 0x13) == 0) { iVar3 = js_same_value(param_1,local_a8,local_a0,param_5,param_6); if (iVar3 != 0) goto LAB_0014e859; } else if (((local_b0[0] & 0x11) != 0x10) || (local_80 != 3)) { LAB_0014e859: js_free_desc(param_1,local_b0); return uVar5; } js_free_desc(param_1,local_b0); pcVar8 = "proxy: inconsistent set"; } JS_ThrowTypeError(param_1,pcVar8); } } return 0xffffffff; }
20,590
codegen_generate_cond
tsotchke[P]eshkol/src/backend/codegen/conditionals.c
bool codegen_generate_cond(CodegenContext* context, const AstNode* node) { assert(context != NULL); assert(node != NULL); assert(node->type == AST_COND); // Get output file FILE* output = codegen_context_get_output(context); // Generate code fprintf(output, "({"); // Generate clauses for (size_t i = 0; i < node->as.cond.clause_count; i++) { AstNode* clause = node->as.cond.clauses[i]; // Check if this is an else clause if (clause->type == AST_SEQUENCE && clause->as.sequence.expr_count == 2 && clause->as.sequence.exprs[0]->type == AST_IDENTIFIER && strcmp(clause->as.sequence.exprs[0]->as.identifier.name, "else") == 0) { // Generate else clause fprintf(output, " "); if (!codegen_generate_expression(context, clause->as.sequence.exprs[1])) { return false; } fprintf(output, ";"); } else { // Generate if clause fprintf(output, " if ("); // Generate condition if (!codegen_generate_expression(context, clause->as.sequence.exprs[0])) { return false; } // Generate body fprintf(output, ") { "); if (!codegen_generate_expression(context, clause->as.sequence.exprs[1])) { return false; } fprintf(output, "; }"); // Add else if for next clause if (i < node->as.cond.clause_count - 1) { fprintf(output, " else"); } } } // Close cond fprintf(output, " })"); return true; }
O0
c
codegen_generate_cond: pushq %rbp movq %rsp, %rbp subq $0x30, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) cmpq $0x0, -0x10(%rbp) je 0x1bf39 jmp 0x1bf58 leaq 0xae5b(%rip), %rdi # 0x26d9b leaq 0x120c0(%rip), %rsi # 0x2e007 movl $0x37, %edx leaq 0x1214e(%rip), %rcx # 0x2e0a1 callq 0x2160 cmpq $0x0, -0x18(%rbp) je 0x1bf61 jmp 0x1bf80 leaq 0xcae2(%rip), %rdi # 0x28a4a leaq 0x12098(%rip), %rsi # 0x2e007 movl $0x38, %edx leaq 0x12126(%rip), %rcx # 0x2e0a1 callq 0x2160 movq -0x18(%rbp), %rax cmpl $0x12, (%rax) jne 0x1bf8b jmp 0x1bfaa leaq 0x1214e(%rip), %rdi # 0x2e0e0 leaq 0x1206e(%rip), %rsi # 0x2e007 movl $0x39, %edx leaq 0x120fc(%rip), %rcx # 0x2e0a1 callq 0x2160 movq -0x10(%rbp), %rdi callq 0x11730 movq %rax, -0x20(%rbp) movq -0x20(%rbp), %rdi leaq 0x12135(%rip), %rsi # 0x2e0f7 movb $0x0, %al callq 0x21d0 movq $0x0, -0x28(%rbp) movq -0x28(%rbp), %rax movq -0x18(%rbp), %rcx cmpq 0x50(%rcx), %rax jae 0x1c13c movq -0x18(%rbp), %rax movq 0x48(%rax), %rax movq -0x28(%rbp), %rcx movq (%rax,%rcx,8), %rax movq %rax, -0x30(%rbp) movq -0x30(%rbp), %rax cmpl $0x1a, (%rax) jne 0x1c08a movq -0x30(%rbp), %rax cmpq $0x2, 0x50(%rax) jne 0x1c08a movq -0x30(%rbp), %rax movq 0x48(%rax), %rax movq (%rax), %rax cmpl $0x6, (%rax) jne 0x1c08a movq -0x30(%rbp), %rax movq 0x48(%rax), %rax movq (%rax), %rax movq 0x48(%rax), %rdi leaq 0x120d0(%rip), %rsi # 0x2e105 callq 0x21c0 cmpl $0x0, %eax jne 0x1c08a movq -0x20(%rbp), %rdi leaq 0x12680(%rip), %rsi # 0x2e6ca movb $0x0, %al callq 0x21d0 movq -0x10(%rbp), %rdi movq -0x30(%rbp), %rax movq 0x48(%rax), %rax movq 0x8(%rax), %rsi callq 0x18cf0 testb $0x1, %al jne 0x1c073 movb $0x0, -0x1(%rbp) jmp 0x1c152 movq -0x20(%rbp), %rdi leaq 0xeee8(%rip), %rsi # 0x2af66 movb $0x0, %al callq 0x21d0 jmp 0x1c129 movq -0x20(%rbp), %rdi leaq 0x12065(%rip), %rsi # 0x2e0fa movb $0x0, %al callq 0x21d0 movq -0x10(%rbp), %rdi movq -0x30(%rbp), %rax movq 0x48(%rax), %rax movq (%rax), %rsi callq 0x18cf0 testb $0x1, %al jne 0x1c0bd movb $0x0, -0x1(%rbp) jmp 0x1c152 movq -0x20(%rbp), %rdi leaq 0x111d9(%rip), %rsi # 0x2d2a1 movb $0x0, %al callq 0x21d0 movq -0x10(%rbp), %rdi movq -0x30(%rbp), %rax movq 0x48(%rax), %rax movq 0x8(%rax), %rsi callq 0x18cf0 testb $0x1, %al jne 0x1c0ee movb $0x0, -0x1(%rbp) jmp 0x1c152 movq -0x20(%rbp), %rdi leaq 0x12007(%rip), %rsi # 0x2e100 movb $0x0, %al callq 0x21d0 movq -0x28(%rbp), %rax movq -0x18(%rbp), %rcx movq 0x50(%rcx), %rcx subq $0x1, %rcx cmpq %rcx, %rax jae 0x1c127 movq -0x20(%rbp), %rdi leaq 0x11fe4(%rip), %rsi # 0x2e104 movb $0x0, %al callq 0x21d0 jmp 0x1c129 jmp 0x1c12b movq -0x28(%rbp), %rax addq $0x1, %rax movq %rax, -0x28(%rbp) jmp 0x1bfd1 movq -0x20(%rbp), %rdi leaq 0x11cd7(%rip), %rsi # 0x2de1e movb $0x0, %al callq 0x21d0 movb $0x1, -0x1(%rbp) movb -0x1(%rbp), %al andb $0x1, %al addq $0x30, %rsp popq %rbp retq nopl (%rax)
codegen_generate_cond: push rbp mov rbp, rsp sub rsp, 30h mov [rbp+var_10], rdi mov [rbp+var_18], rsi cmp [rbp+var_10], 0 jz short loc_1BF39 jmp short loc_1BF58 loc_1BF39: lea rdi, aContextNull; "context != NULL" lea rsi, aWorkspaceLlm4b_19; "/workspace/llm4binary/github/2025_star3"... mov edx, 37h ; '7' lea rcx, aBoolCodegenGen_17; "_Bool codegen_generate_cond(CodegenCont"... call ___assert_fail loc_1BF58: cmp [rbp+var_18], 0 jz short loc_1BF61 jmp short loc_1BF80 loc_1BF61: lea rdi, aNodeNull; "node != NULL" lea rsi, aWorkspaceLlm4b_19; "/workspace/llm4binary/github/2025_star3"... mov edx, 38h ; '8' lea rcx, aBoolCodegenGen_17; "_Bool codegen_generate_cond(CodegenCont"... call ___assert_fail loc_1BF80: mov rax, [rbp+var_18] cmp dword ptr [rax], 12h jnz short loc_1BF8B jmp short loc_1BFAA loc_1BF8B: lea rdi, aNodeTypeAstCon; "node->type == AST_COND" lea rsi, aWorkspaceLlm4b_19; "/workspace/llm4binary/github/2025_star3"... mov edx, 39h ; '9' lea rcx, aBoolCodegenGen_17; "_Bool codegen_generate_cond(CodegenCont"... call ___assert_fail loc_1BFAA: mov rdi, [rbp+var_10] call codegen_context_get_output mov [rbp+var_20], rax mov rdi, [rbp+var_20] lea rsi, asc_2E0F7; "({" mov al, 0 call _fprintf mov [rbp+var_28], 0 loc_1BFD1: mov rax, [rbp+var_28] mov rcx, [rbp+var_18] cmp rax, [rcx+50h] jnb loc_1C13C mov rax, [rbp+var_18] mov rax, [rax+48h] mov rcx, [rbp+var_28] mov rax, [rax+rcx*8] mov [rbp+var_30], rax mov rax, [rbp+var_30] cmp dword ptr [rax], 1Ah jnz loc_1C08A mov rax, [rbp+var_30] cmp qword ptr [rax+50h], 2 jnz short loc_1C08A mov rax, [rbp+var_30] mov rax, [rax+48h] mov rax, [rax] cmp dword ptr [rax], 6 jnz short loc_1C08A mov rax, [rbp+var_30] mov rax, [rax+48h] mov rax, [rax] mov rdi, [rax+48h] lea rsi, aElse_3+1; "else" call _strcmp cmp eax, 0 jnz short loc_1C08A mov rdi, [rbp+var_20] lea rsi, asc_2E6C3+7; " " mov al, 0 call _fprintf mov rdi, [rbp+var_10] mov rax, [rbp+var_30] mov rax, [rax+48h] mov rsi, [rax+8] call codegen_generate_expression test al, 1 jnz short loc_1C073 mov [rbp+var_1], 0 jmp loc_1C152 loc_1C073: mov rdi, [rbp+var_20] lea rsi, aSNull+9; ";" mov al, 0 call _fprintf jmp loc_1C129 loc_1C08A: mov rdi, [rbp+var_20] lea rsi, aIf_1; " if (" mov al, 0 call _fprintf mov rdi, [rbp+var_10] mov rax, [rbp+var_30] mov rax, [rax+48h] mov rsi, [rax] call codegen_generate_expression test al, 1 jnz short loc_1C0BD mov [rbp+var_1], 0 jmp loc_1C152 loc_1C0BD: mov rdi, [rbp+var_20] lea rsi, aIfCalleeNullUi+31h; ") { " mov al, 0 call _fprintf mov rdi, [rbp+var_10] mov rax, [rbp+var_30] mov rax, [rax+48h] mov rsi, [rax+8] call codegen_generate_expression test al, 1 jnz short loc_1C0EE mov [rbp+var_1], 0 jmp short loc_1C152 loc_1C0EE: mov rdi, [rbp+var_20] lea rsi, asc_2E100; "; }" mov al, 0 call _fprintf mov rax, [rbp+var_28] mov rcx, [rbp+var_18] mov rcx, [rcx+50h] sub rcx, 1 cmp rax, rcx jnb short loc_1C127 mov rdi, [rbp+var_20] lea rsi, aElse_3; " else" mov al, 0 call _fprintf loc_1C127: jmp short $+2 loc_1C129: jmp short $+2 loc_1C12B: mov rax, [rbp+var_28] add rax, 1 mov [rbp+var_28], rax jmp loc_1BFD1 loc_1C13C: mov rdi, [rbp+var_20] lea rsi, aVectorFGetComp_0+4Fh; " })" mov al, 0 call _fprintf mov [rbp+var_1], 1 loc_1C152: mov al, [rbp+var_1] and al, 1 add rsp, 30h pop rbp retn
char codegen_generate_cond(long long a1, long long a2) { long long v3; // [rsp+0h] [rbp-30h] unsigned long long i; // [rsp+8h] [rbp-28h] long long output; // [rsp+10h] [rbp-20h] if ( !a1 ) __assert_fail( "context != NULL", "/workspace/llm4binary/github/2025_star3/tsotchke[P]eshkol/src/backend/codegen/conditionals.c", 55LL, "_Bool codegen_generate_cond(CodegenContext *, const AstNode *)"); if ( !a2 ) __assert_fail( "node != NULL", "/workspace/llm4binary/github/2025_star3/tsotchke[P]eshkol/src/backend/codegen/conditionals.c", 56LL, "_Bool codegen_generate_cond(CodegenContext *, const AstNode *)"); if ( *(_DWORD *)a2 != 18 ) __assert_fail( "node->type == AST_COND", "/workspace/llm4binary/github/2025_star3/tsotchke[P]eshkol/src/backend/codegen/conditionals.c", 57LL, "_Bool codegen_generate_cond(CodegenContext *, const AstNode *)"); output = codegen_context_get_output(a1); fprintf(output, "({"); for ( i = 0LL; i < *(_QWORD *)(a2 + 80); ++i ) { v3 = *(_QWORD *)(*(_QWORD *)(a2 + 72) + 8 * i); if ( *(_DWORD *)v3 == 26 && *(_QWORD *)(v3 + 80) == 2LL && ***(_DWORD ***)(v3 + 72) == 6 && !(unsigned int)strcmp(*(_QWORD *)(**(_QWORD **)(v3 + 72) + 72LL), "else") ) { fprintf(output, " "); if ( (codegen_generate_expression(a1, *(_DWORD **)(*(_QWORD *)(v3 + 72) + 8LL)) & 1) == 0 ) return 0; fprintf(output, ";"); } else { fprintf(output, " if ("); if ( (codegen_generate_expression(a1, **(_DWORD ***)(v3 + 72)) & 1) == 0 ) return 0; fprintf(output, ") { "); if ( (codegen_generate_expression(a1, *(_DWORD **)(*(_QWORD *)(v3 + 72) + 8LL)) & 1) == 0 ) return 0; fprintf(output, "; }"); if ( i < *(_QWORD *)(a2 + 80) - 1LL ) fprintf(output, " else"); } } fprintf(output, " })"); return 1; }
codegen_generate_cond: PUSH RBP MOV RBP,RSP SUB RSP,0x30 MOV qword ptr [RBP + -0x10],RDI MOV qword ptr [RBP + -0x18],RSI CMP qword ptr [RBP + -0x10],0x0 JZ 0x0011bf39 JMP 0x0011bf58 LAB_0011bf39: LEA RDI,[0x126d9b] LEA RSI,[0x12e007] MOV EDX,0x37 LEA RCX,[0x12e0a1] CALL 0x00102160 LAB_0011bf58: CMP qword ptr [RBP + -0x18],0x0 JZ 0x0011bf61 JMP 0x0011bf80 LAB_0011bf61: LEA RDI,[0x128a4a] LEA RSI,[0x12e007] MOV EDX,0x38 LEA RCX,[0x12e0a1] CALL 0x00102160 LAB_0011bf80: MOV RAX,qword ptr [RBP + -0x18] CMP dword ptr [RAX],0x12 JNZ 0x0011bf8b JMP 0x0011bfaa LAB_0011bf8b: LEA RDI,[0x12e0e0] LEA RSI,[0x12e007] MOV EDX,0x39 LEA RCX,[0x12e0a1] CALL 0x00102160 LAB_0011bfaa: MOV RDI,qword ptr [RBP + -0x10] CALL 0x00111730 MOV qword ptr [RBP + -0x20],RAX MOV RDI,qword ptr [RBP + -0x20] LEA RSI,[0x12e0f7] MOV AL,0x0 CALL 0x001021d0 MOV qword ptr [RBP + -0x28],0x0 LAB_0011bfd1: MOV RAX,qword ptr [RBP + -0x28] MOV RCX,qword ptr [RBP + -0x18] CMP RAX,qword ptr [RCX + 0x50] JNC 0x0011c13c MOV RAX,qword ptr [RBP + -0x18] MOV RAX,qword ptr [RAX + 0x48] MOV RCX,qword ptr [RBP + -0x28] MOV RAX,qword ptr [RAX + RCX*0x8] MOV qword ptr [RBP + -0x30],RAX MOV RAX,qword ptr [RBP + -0x30] CMP dword ptr [RAX],0x1a JNZ 0x0011c08a MOV RAX,qword ptr [RBP + -0x30] CMP qword ptr [RAX + 0x50],0x2 JNZ 0x0011c08a MOV RAX,qword ptr [RBP + -0x30] MOV RAX,qword ptr [RAX + 0x48] MOV RAX,qword ptr [RAX] CMP dword ptr [RAX],0x6 JNZ 0x0011c08a MOV RAX,qword ptr [RBP + -0x30] MOV RAX,qword ptr [RAX + 0x48] MOV RAX,qword ptr [RAX] MOV RDI,qword ptr [RAX + 0x48] LEA RSI,[0x12e105] CALL 0x001021c0 CMP EAX,0x0 JNZ 0x0011c08a MOV RDI,qword ptr [RBP + -0x20] LEA RSI,[0x12e6ca] MOV AL,0x0 CALL 0x001021d0 MOV RDI,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RBP + -0x30] MOV RAX,qword ptr [RAX + 0x48] MOV RSI,qword ptr [RAX + 0x8] CALL 0x00118cf0 TEST AL,0x1 JNZ 0x0011c073 MOV byte ptr [RBP + -0x1],0x0 JMP 0x0011c152 LAB_0011c073: MOV RDI,qword ptr [RBP + -0x20] LEA RSI,[0x12af66] MOV AL,0x0 CALL 0x001021d0 JMP 0x0011c129 LAB_0011c08a: MOV RDI,qword ptr [RBP + -0x20] LEA RSI,[0x12e0fa] MOV AL,0x0 CALL 0x001021d0 MOV RDI,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RBP + -0x30] MOV RAX,qword ptr [RAX + 0x48] MOV RSI,qword ptr [RAX] CALL 0x00118cf0 TEST AL,0x1 JNZ 0x0011c0bd MOV byte ptr [RBP + -0x1],0x0 JMP 0x0011c152 LAB_0011c0bd: MOV RDI,qword ptr [RBP + -0x20] LEA RSI,[0x12d2a1] MOV AL,0x0 CALL 0x001021d0 MOV RDI,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RBP + -0x30] MOV RAX,qword ptr [RAX + 0x48] MOV RSI,qword ptr [RAX + 0x8] CALL 0x00118cf0 TEST AL,0x1 JNZ 0x0011c0ee MOV byte ptr [RBP + -0x1],0x0 JMP 0x0011c152 LAB_0011c0ee: MOV RDI,qword ptr [RBP + -0x20] LEA RSI,[0x12e100] MOV AL,0x0 CALL 0x001021d0 MOV RAX,qword ptr [RBP + -0x28] MOV RCX,qword ptr [RBP + -0x18] MOV RCX,qword ptr [RCX + 0x50] SUB RCX,0x1 CMP RAX,RCX JNC 0x0011c127 MOV RDI,qword ptr [RBP + -0x20] LEA RSI,[0x12e104] MOV AL,0x0 CALL 0x001021d0 LAB_0011c127: JMP 0x0011c129 LAB_0011c129: JMP 0x0011c12b LAB_0011c12b: MOV RAX,qword ptr [RBP + -0x28] ADD RAX,0x1 MOV qword ptr [RBP + -0x28],RAX JMP 0x0011bfd1 LAB_0011c13c: MOV RDI,qword ptr [RBP + -0x20] LEA RSI,[0x12de1e] MOV AL,0x0 CALL 0x001021d0 MOV byte ptr [RBP + -0x1],0x1 LAB_0011c152: MOV AL,byte ptr [RBP + -0x1] AND AL,0x1 ADD RSP,0x30 POP RBP RET
int1 codegen_generate_cond(long param_1,int *param_2) { int *piVar1; int iVar2; FILE *__stream; ulong uVar3; ulong local_30; if (param_1 == 0) { /* WARNING: Subroutine does not return */ __assert_fail("context != NULL", "/workspace/llm4binary/github/2025_star3/tsotchke[P]eshkol/src/backend/codegen/conditionals.c" ,0x37,"_Bool codegen_generate_cond(CodegenContext *, const AstNode *)"); } if (param_2 == (int *)0x0) { /* WARNING: Subroutine does not return */ __assert_fail("node != NULL", "/workspace/llm4binary/github/2025_star3/tsotchke[P]eshkol/src/backend/codegen/conditionals.c" ,0x38,"_Bool codegen_generate_cond(CodegenContext *, const AstNode *)"); } if (*param_2 != 0x12) { /* WARNING: Subroutine does not return */ __assert_fail("node->type == AST_COND", "/workspace/llm4binary/github/2025_star3/tsotchke[P]eshkol/src/backend/codegen/conditionals.c" ,0x39,"_Bool codegen_generate_cond(CodegenContext *, const AstNode *)"); } __stream = (FILE *)codegen_context_get_output(param_1); fprintf(__stream,"({"); local_30 = 0; do { if (*(ulong *)(param_2 + 0x14) <= local_30) { fprintf(__stream," })"); return 1; } piVar1 = *(int **)(*(long *)(param_2 + 0x12) + local_30 * 8); if ((((*piVar1 == 0x1a) && (*(long *)(piVar1 + 0x14) == 2)) && (*(int *)**(int8 **)(piVar1 + 0x12) == 6)) && (iVar2 = strcmp(*(char **)(**(long **)(piVar1 + 0x12) + 0x48),"else"), iVar2 == 0)) { fprintf(__stream," "); uVar3 = codegen_generate_expression(param_1,*(int8 *)(*(long *)(piVar1 + 0x12) + 8)); if ((uVar3 & 1) == 0) { return 0; } fprintf(__stream,";"); } else { fprintf(__stream," if ("); uVar3 = codegen_generate_expression(param_1,**(int8 **)(piVar1 + 0x12)); if ((uVar3 & 1) == 0) { return 0; } fprintf(__stream,") { "); uVar3 = codegen_generate_expression(param_1,*(int8 *)(*(long *)(piVar1 + 0x12) + 8)); if ((uVar3 & 1) == 0) { return 0; } fprintf(__stream,"; }"); if (local_30 < *(long *)(param_2 + 0x14) - 1U) { fprintf(__stream," else"); } } local_30 = local_30 + 1; } while( true ); }
20,591
setup_key_functions
eloqsql/storage/myisam/mi_open.c
static void setup_key_functions(register MI_KEYDEF *keyinfo) { if (keyinfo->key_alg == HA_KEY_ALG_RTREE) { #ifdef HAVE_RTREE_KEYS keyinfo->ck_insert = rtree_insert; keyinfo->ck_delete = rtree_delete; #else DBUG_ASSERT(0); /* mi_open should check it never happens */ #endif } else { keyinfo->ck_insert = _mi_ck_write; keyinfo->ck_delete = _mi_ck_delete; } if (keyinfo->flag & HA_BINARY_PACK_KEY) { /* Simple prefix compression */ keyinfo->bin_search=_mi_seq_search; keyinfo->get_key=_mi_get_binary_pack_key; keyinfo->pack_key=_mi_calc_bin_pack_key_length; keyinfo->store_key=_mi_store_bin_pack_key; } else if (keyinfo->flag & HA_VAR_LENGTH_KEY) { keyinfo->get_key= _mi_get_pack_key; if (keyinfo->seg[0].flag & HA_PACK_KEY) { /* Prefix compression */ /* _mi_prefix_search() compares end-space against ASCII blank (' '). It cannot be used for character sets, that do not encode the blank character like ASCII does. UCS2 is an example. All character sets with a fixed width > 1 or a mimimum width > 1 cannot represent blank like ASCII does. In these cases we have to use _mi_seq_search() for the search. */ if (!keyinfo->seg->charset || use_strnxfrm(keyinfo->seg->charset) || (keyinfo->seg->flag & HA_NULL_PART) || (keyinfo->seg->charset->mbminlen > 1)) keyinfo->bin_search=_mi_seq_search; else keyinfo->bin_search=_mi_prefix_search; keyinfo->pack_key=_mi_calc_var_pack_key_length; keyinfo->store_key=_mi_store_var_pack_key; } else { keyinfo->bin_search=_mi_seq_search; keyinfo->pack_key=_mi_calc_var_key_length; /* Variable length key */ keyinfo->store_key=_mi_store_static_key; } } else { keyinfo->bin_search=_mi_bin_search; keyinfo->get_key=_mi_get_static_key; keyinfo->pack_key=_mi_calc_static_key_length; keyinfo->store_key=_mi_store_static_key; } return; }
O0
c
setup_key_functions: pushq %rbp movq %rsp, %rbp movq %rdi, -0x8(%rbp) movq -0x8(%rbp), %rax movzbl 0xc(%rax), %eax cmpl $0x2, %eax jne 0xb7905 movq -0x8(%rbp), %rax leaq 0x12fe0(%rip), %rcx # 0xca8d0 movq %rcx, 0x60(%rax) movq -0x8(%rbp), %rax leaq 0x133a1(%rip), %rcx # 0xcaca0 movq %rcx, 0x68(%rax) jmp 0xb7923 movq -0x8(%rbp), %rax leaq 0xf630(%rip), %rcx # 0xc6f40 movq %rcx, 0x60(%rax) movq -0x8(%rbp), %rax leaq -0x1275f(%rip), %rcx # 0xa51c0 movq %rcx, 0x68(%rax) movq -0x8(%rbp), %rax movzwl 0xa(%rax), %eax andl $0x20, %eax cmpl $0x0, %eax je 0xb7974 movq -0x8(%rbp), %rax leaq 0x8f72(%rip), %rcx # 0xc08b0 movq %rcx, 0x40(%rax) movq -0x8(%rbp), %rax leaq 0xae63(%rip), %rcx # 0xc27b0 movq %rcx, 0x48(%rax) movq -0x8(%rbp), %rax leaq 0xcc54(%rip), %rcx # 0xc45b0 movq %rcx, 0x50(%rax) movq -0x8(%rbp), %rax leaq 0xd425(%rip), %rcx # 0xc4d90 movq %rcx, 0x58(%rax) jmp 0xb7aa8 movq -0x8(%rbp), %rax movzwl 0xa(%rax), %eax andl $0x8, %eax cmpl $0x0, %eax je 0xb7a6a movq -0x8(%rbp), %rax leaq 0xa7fd(%rip), %rcx # 0xc2190 movq %rcx, 0x48(%rax) movq -0x8(%rbp), %rax movq 0x28(%rax), %rax movzwl 0x12(%rax), %eax andl $0x2, %eax cmpl $0x0, %eax je 0xb7a3b movq -0x8(%rbp), %rax movq 0x28(%rax), %rax cmpq $0x0, (%rax) je 0xb79fb movq -0x8(%rbp), %rax movq 0x28(%rax), %rax movq (%rax), %rax movl 0xc(%rax), %eax andl $0x40, %eax cmpl $0x0, %eax jne 0xb79fb movq -0x8(%rbp), %rax movq 0x28(%rax), %rax movzwl 0x12(%rax), %eax andl $0x10, %eax cmpl $0x0, %eax jne 0xb79fb movq -0x8(%rbp), %rax movq 0x28(%rax), %rax movq (%rax), %rax cmpl $0x1, 0x98(%rax) jbe 0xb7a0c movq -0x8(%rbp), %rax leaq 0x8eaa(%rip), %rcx # 0xc08b0 movq %rcx, 0x40(%rax) jmp 0xb7a1b movq -0x8(%rbp), %rax leaq 0x9139(%rip), %rcx # 0xc0b50 movq %rcx, 0x40(%rax) movq -0x8(%rbp), %rax leaq 0xc06a(%rip), %rcx # 0xc3a90 movq %rcx, 0x50(%rax) movq -0x8(%rbp), %rax leaq 0xceeb(%rip), %rcx # 0xc4920 movq %rcx, 0x58(%rax) jmp 0xb7a68 movq -0x8(%rbp), %rax leaq 0x8e6a(%rip), %rcx # 0xc08b0 movq %rcx, 0x40(%rax) movq -0x8(%rbp), %rax leaq 0xbfeb(%rip), %rcx # 0xc3a40 movq %rcx, 0x50(%rax) movq -0x8(%rbp), %rax leaq 0xce7c(%rip), %rcx # 0xc48e0 movq %rcx, 0x58(%rax) jmp 0xb7aa6 movq -0x8(%rbp), %rax leaq 0x8c7b(%rip), %rcx # 0xc06f0 movq %rcx, 0x40(%rax) movq -0x8(%rbp), %rax leaq 0xa6ac(%rip), %rcx # 0xc2130 movq %rcx, 0x48(%rax) movq -0x8(%rbp), %rax leaq 0xbf6d(%rip), %rcx # 0xc3a00 movq %rcx, 0x50(%rax) movq -0x8(%rbp), %rax leaq 0xce3e(%rip), %rcx # 0xc48e0 movq %rcx, 0x58(%rax) jmp 0xb7aa8 popq %rbp retq nopw (%rax,%rax)
setup_key_functions_0: push rbp mov rbp, rsp mov [rbp+var_8], rdi mov rax, [rbp+var_8] movzx eax, byte ptr [rax+0Ch] cmp eax, 2 jnz short loc_B7905 mov rax, [rbp+var_8] lea rcx, rtree_insert mov [rax+60h], rcx mov rax, [rbp+var_8] lea rcx, rtree_delete mov [rax+68h], rcx jmp short loc_B7923 loc_B7905: mov rax, [rbp+var_8] lea rcx, _mi_ck_write mov [rax+60h], rcx mov rax, [rbp+var_8] lea rcx, _mi_ck_delete mov [rax+68h], rcx loc_B7923: mov rax, [rbp+var_8] movzx eax, word ptr [rax+0Ah] and eax, 20h cmp eax, 0 jz short loc_B7974 mov rax, [rbp+var_8] lea rcx, _mi_seq_search mov [rax+40h], rcx mov rax, [rbp+var_8] lea rcx, _mi_get_binary_pack_key mov [rax+48h], rcx mov rax, [rbp+var_8] lea rcx, _mi_calc_bin_pack_key_length mov [rax+50h], rcx mov rax, [rbp+var_8] lea rcx, _mi_store_bin_pack_key mov [rax+58h], rcx jmp loc_B7AA8 loc_B7974: mov rax, [rbp+var_8] movzx eax, word ptr [rax+0Ah] and eax, 8 cmp eax, 0 jz loc_B7A6A mov rax, [rbp+var_8] lea rcx, _mi_get_pack_key mov [rax+48h], rcx mov rax, [rbp+var_8] mov rax, [rax+28h] movzx eax, word ptr [rax+12h] and eax, 2 cmp eax, 0 jz loc_B7A3B mov rax, [rbp+var_8] mov rax, [rax+28h] cmp qword ptr [rax], 0 jz short loc_B79FB mov rax, [rbp+var_8] mov rax, [rax+28h] mov rax, [rax] mov eax, [rax+0Ch] and eax, 40h cmp eax, 0 jnz short loc_B79FB mov rax, [rbp+var_8] mov rax, [rax+28h] movzx eax, word ptr [rax+12h] and eax, 10h cmp eax, 0 jnz short loc_B79FB mov rax, [rbp+var_8] mov rax, [rax+28h] mov rax, [rax] cmp dword ptr [rax+98h], 1 jbe short loc_B7A0C loc_B79FB: mov rax, [rbp+var_8] lea rcx, _mi_seq_search mov [rax+40h], rcx jmp short loc_B7A1B loc_B7A0C: mov rax, [rbp+var_8] lea rcx, _mi_prefix_search mov [rax+40h], rcx loc_B7A1B: mov rax, [rbp+var_8] lea rcx, _mi_calc_var_pack_key_length mov [rax+50h], rcx mov rax, [rbp+var_8] lea rcx, _mi_store_var_pack_key mov [rax+58h], rcx jmp short loc_B7A68 loc_B7A3B: mov rax, [rbp+var_8] lea rcx, _mi_seq_search mov [rax+40h], rcx mov rax, [rbp+var_8] lea rcx, _mi_calc_var_key_length mov [rax+50h], rcx mov rax, [rbp+var_8] lea rcx, _mi_store_static_key mov [rax+58h], rcx loc_B7A68: jmp short loc_B7AA6 loc_B7A6A: mov rax, [rbp+var_8] lea rcx, _mi_bin_search mov [rax+40h], rcx mov rax, [rbp+var_8] lea rcx, _mi_get_static_key mov [rax+48h], rcx mov rax, [rbp+var_8] lea rcx, _mi_calc_static_key_length mov [rax+50h], rcx mov rax, [rbp+var_8] lea rcx, _mi_store_static_key mov [rax+58h], rcx loc_B7AA6: jmp short $+2 loc_B7AA8: pop rbp retn
long long setup_key_functions_0(long long a1) { long long result; // rax if ( *(_BYTE *)(a1 + 12) == 2 ) { *(_QWORD *)(a1 + 96) = rtree_insert; *(_QWORD *)(a1 + 104) = rtree_delete; } else { *(_QWORD *)(a1 + 96) = mi_ck_write; *(_QWORD *)(a1 + 104) = mi_ck_delete; } if ( (*(_WORD *)(a1 + 10) & 0x20) != 0 ) { *(_QWORD *)(a1 + 64) = mi_seq_search; *(_QWORD *)(a1 + 72) = mi_get_binary_pack_key; *(_QWORD *)(a1 + 80) = mi_calc_bin_pack_key_length; result = a1; *(_QWORD *)(a1 + 88) = mi_store_bin_pack_key; } else if ( (*(_WORD *)(a1 + 10) & 8) != 0 ) { *(_QWORD *)(a1 + 72) = mi_get_pack_key; if ( (*(_WORD *)(*(_QWORD *)(a1 + 40) + 18LL) & 2) != 0 ) { if ( !**(_QWORD **)(a1 + 40) || (*(_DWORD *)(**(_QWORD **)(a1 + 40) + 12LL) & 0x40) != 0 || (*(_WORD *)(*(_QWORD *)(a1 + 40) + 18LL) & 0x10) != 0 || *(_DWORD *)(**(_QWORD **)(a1 + 40) + 152LL) > 1u ) { *(_QWORD *)(a1 + 64) = mi_seq_search; } else { *(_QWORD *)(a1 + 64) = mi_prefix_search; } *(_QWORD *)(a1 + 80) = mi_calc_var_pack_key_length; result = a1; *(_QWORD *)(a1 + 88) = mi_store_var_pack_key; } else { *(_QWORD *)(a1 + 64) = mi_seq_search; *(_QWORD *)(a1 + 80) = mi_calc_var_key_length; result = a1; *(_QWORD *)(a1 + 88) = mi_store_static_key; } } else { *(_QWORD *)(a1 + 64) = mi_bin_search; *(_QWORD *)(a1 + 72) = mi_get_static_key; *(_QWORD *)(a1 + 80) = mi_calc_static_key_length; result = a1; *(_QWORD *)(a1 + 88) = mi_store_static_key; } return result; }
setup_key_functions: PUSH RBP MOV RBP,RSP MOV qword ptr [RBP + -0x8],RDI MOV RAX,qword ptr [RBP + -0x8] MOVZX EAX,byte ptr [RAX + 0xc] CMP EAX,0x2 JNZ 0x001b7905 MOV RAX,qword ptr [RBP + -0x8] LEA RCX,[0x1ca8d0] MOV qword ptr [RAX + 0x60],RCX MOV RAX,qword ptr [RBP + -0x8] LEA RCX,[0x1caca0] MOV qword ptr [RAX + 0x68],RCX JMP 0x001b7923 LAB_001b7905: MOV RAX,qword ptr [RBP + -0x8] LEA RCX,[0x1c6f40] MOV qword ptr [RAX + 0x60],RCX MOV RAX,qword ptr [RBP + -0x8] LEA RCX,[0x1a51c0] MOV qword ptr [RAX + 0x68],RCX LAB_001b7923: MOV RAX,qword ptr [RBP + -0x8] MOVZX EAX,word ptr [RAX + 0xa] AND EAX,0x20 CMP EAX,0x0 JZ 0x001b7974 MOV RAX,qword ptr [RBP + -0x8] LEA RCX,[0x1c08b0] MOV qword ptr [RAX + 0x40],RCX MOV RAX,qword ptr [RBP + -0x8] LEA RCX,[0x1c27b0] MOV qword ptr [RAX + 0x48],RCX MOV RAX,qword ptr [RBP + -0x8] LEA RCX,[0x1c45b0] MOV qword ptr [RAX + 0x50],RCX MOV RAX,qword ptr [RBP + -0x8] LEA RCX,[0x1c4d90] MOV qword ptr [RAX + 0x58],RCX JMP 0x001b7aa8 LAB_001b7974: MOV RAX,qword ptr [RBP + -0x8] MOVZX EAX,word ptr [RAX + 0xa] AND EAX,0x8 CMP EAX,0x0 JZ 0x001b7a6a MOV RAX,qword ptr [RBP + -0x8] LEA RCX,[0x1c2190] MOV qword ptr [RAX + 0x48],RCX MOV RAX,qword ptr [RBP + -0x8] MOV RAX,qword ptr [RAX + 0x28] MOVZX EAX,word ptr [RAX + 0x12] AND EAX,0x2 CMP EAX,0x0 JZ 0x001b7a3b MOV RAX,qword ptr [RBP + -0x8] MOV RAX,qword ptr [RAX + 0x28] CMP qword ptr [RAX],0x0 JZ 0x001b79fb MOV RAX,qword ptr [RBP + -0x8] MOV RAX,qword ptr [RAX + 0x28] MOV RAX,qword ptr [RAX] MOV EAX,dword ptr [RAX + 0xc] AND EAX,0x40 CMP EAX,0x0 JNZ 0x001b79fb MOV RAX,qword ptr [RBP + -0x8] MOV RAX,qword ptr [RAX + 0x28] MOVZX EAX,word ptr [RAX + 0x12] AND EAX,0x10 CMP EAX,0x0 JNZ 0x001b79fb MOV RAX,qword ptr [RBP + -0x8] MOV RAX,qword ptr [RAX + 0x28] MOV RAX,qword ptr [RAX] CMP dword ptr [RAX + 0x98],0x1 JBE 0x001b7a0c LAB_001b79fb: MOV RAX,qword ptr [RBP + -0x8] LEA RCX,[0x1c08b0] MOV qword ptr [RAX + 0x40],RCX JMP 0x001b7a1b LAB_001b7a0c: MOV RAX,qword ptr [RBP + -0x8] LEA RCX,[0x1c0b50] MOV qword ptr [RAX + 0x40],RCX LAB_001b7a1b: MOV RAX,qword ptr [RBP + -0x8] LEA RCX,[0x1c3a90] MOV qword ptr [RAX + 0x50],RCX MOV RAX,qword ptr [RBP + -0x8] LEA RCX,[0x1c4920] MOV qword ptr [RAX + 0x58],RCX JMP 0x001b7a68 LAB_001b7a3b: MOV RAX,qword ptr [RBP + -0x8] LEA RCX,[0x1c08b0] MOV qword ptr [RAX + 0x40],RCX MOV RAX,qword ptr [RBP + -0x8] LEA RCX,[0x1c3a40] MOV qword ptr [RAX + 0x50],RCX MOV RAX,qword ptr [RBP + -0x8] LEA RCX,[0x1c48e0] MOV qword ptr [RAX + 0x58],RCX LAB_001b7a68: JMP 0x001b7aa6 LAB_001b7a6a: MOV RAX,qword ptr [RBP + -0x8] LEA RCX,[0x1c06f0] MOV qword ptr [RAX + 0x40],RCX MOV RAX,qword ptr [RBP + -0x8] LEA RCX,[0x1c2130] MOV qword ptr [RAX + 0x48],RCX MOV RAX,qword ptr [RBP + -0x8] LEA RCX,[0x1c3a00] MOV qword ptr [RAX + 0x50],RCX MOV RAX,qword ptr [RBP + -0x8] LEA RCX,[0x1c48e0] MOV qword ptr [RAX + 0x58],RCX LAB_001b7aa6: JMP 0x001b7aa8 LAB_001b7aa8: POP RBP RET
void setup_key_functions(long param_1) { if (*(char *)(param_1 + 0xc) == '\x02') { *(code **)(param_1 + 0x60) = rtree_insert; *(code **)(param_1 + 0x68) = rtree_delete; } else { *(code **)(param_1 + 0x60) = _mi_ck_write; *(code **)(param_1 + 0x68) = _mi_ck_delete; } if ((*(ushort *)(param_1 + 10) & 0x20) == 0) { if ((*(ushort *)(param_1 + 10) & 8) == 0) { *(code **)(param_1 + 0x40) = _mi_bin_search; *(code **)(param_1 + 0x48) = _mi_get_static_key; *(code **)(param_1 + 0x50) = _mi_calc_static_key_length; *(code **)(param_1 + 0x58) = _mi_store_static_key; } else { *(code **)(param_1 + 0x48) = _mi_get_pack_key; if ((*(ushort *)(*(long *)(param_1 + 0x28) + 0x12) & 2) == 0) { *(code **)(param_1 + 0x40) = _mi_seq_search; *(code **)(param_1 + 0x50) = _mi_calc_var_key_length; *(code **)(param_1 + 0x58) = _mi_store_static_key; } else { if ((((**(long **)(param_1 + 0x28) == 0) || ((*(uint *)(**(long **)(param_1 + 0x28) + 0xc) & 0x40) != 0)) || ((*(ushort *)(*(long *)(param_1 + 0x28) + 0x12) & 0x10) != 0)) || (1 < *(uint *)(**(long **)(param_1 + 0x28) + 0x98))) { *(code **)(param_1 + 0x40) = _mi_seq_search; } else { *(code **)(param_1 + 0x40) = _mi_prefix_search; } *(code **)(param_1 + 0x50) = _mi_calc_var_pack_key_length; *(code **)(param_1 + 0x58) = _mi_store_var_pack_key; } } } else { *(code **)(param_1 + 0x40) = _mi_seq_search; *(code **)(param_1 + 0x48) = _mi_get_binary_pack_key; *(code **)(param_1 + 0x50) = _mi_calc_bin_pack_key_length; *(code **)(param_1 + 0x58) = _mi_store_bin_pack_key; } return; }
20,592
svc_tasks_init_waitable_task
qoraal-tictactoe/build_O0/_deps/qoraal-src/src/svc/svc_tasks.c
int32_t svc_tasks_init_waitable_task (SVC_WAITABLE_TASKS_T* task) { svc_tasks_init_task(&task->task) ; task->event = 0 ; p_event_t event ; int32_t res = os_event_create (&event) ; if (res == EOK) { task->event = event ; task->task.flags = SVC_TASKS_FLAGS_WAITABLE ; } return res ; }
O0
c
svc_tasks_init_waitable_task: pushq %rbp movq %rsp, %rbp subq $0x20, %rsp movq %rdi, -0x8(%rbp) movq -0x8(%rbp), %rdi callq 0x22800 movq -0x8(%rbp), %rax movq $0x0, 0x28(%rax) leaq -0x10(%rbp), %rdi callq 0x1d370 movl %eax, -0x14(%rbp) cmpl $0x0, -0x14(%rbp) jne 0x22877 movq -0x10(%rbp), %rcx movq -0x8(%rbp), %rax movq %rcx, 0x28(%rax) movq -0x8(%rbp), %rax movb $0x1, 0x12(%rax) movl -0x14(%rbp), %eax addq $0x20, %rsp popq %rbp retq
svc_tasks_init_waitable_task: push rbp mov rbp, rsp sub rsp, 20h mov [rbp+var_8], rdi mov rdi, [rbp+var_8] call svc_tasks_init_task mov rax, [rbp+var_8] mov qword ptr [rax+28h], 0 lea rdi, [rbp+var_10] call os_event_create mov [rbp+var_14], eax cmp [rbp+var_14], 0 jnz short loc_22877 mov rcx, [rbp+var_10] mov rax, [rbp+var_8] mov [rax+28h], rcx mov rax, [rbp+var_8] mov byte ptr [rax+12h], 1 loc_22877: mov eax, [rbp+var_14] add rsp, 20h pop rbp retn
long long svc_tasks_init_waitable_task(long long a1) { unsigned int v2; // [rsp+Ch] [rbp-14h] long long v3; // [rsp+10h] [rbp-10h] BYREF long long v4; // [rsp+18h] [rbp-8h] v4 = a1; svc_tasks_init_task((_BYTE *)a1); *(_QWORD *)(a1 + 40) = 0LL; v2 = os_event_create(&v3); if ( !v2 ) { *(_QWORD *)(v4 + 40) = v3; *(_BYTE *)(v4 + 18) = 1; } return v2; }
svc_tasks_init_waitable_task: PUSH RBP MOV RBP,RSP SUB RSP,0x20 MOV qword ptr [RBP + -0x8],RDI MOV RDI,qword ptr [RBP + -0x8] CALL 0x00122800 MOV RAX,qword ptr [RBP + -0x8] MOV qword ptr [RAX + 0x28],0x0 LEA RDI,[RBP + -0x10] CALL 0x0011d370 MOV dword ptr [RBP + -0x14],EAX CMP dword ptr [RBP + -0x14],0x0 JNZ 0x00122877 MOV RCX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RBP + -0x8] MOV qword ptr [RAX + 0x28],RCX MOV RAX,qword ptr [RBP + -0x8] MOV byte ptr [RAX + 0x12],0x1 LAB_00122877: MOV EAX,dword ptr [RBP + -0x14] ADD RSP,0x20 POP RBP RET
int svc_tasks_init_waitable_task(long param_1) { int iVar1; int8 local_18; long local_10; local_10 = param_1; svc_tasks_init_task(param_1); *(int8 *)(local_10 + 0x28) = 0; iVar1 = os_event_create(&local_18); if (iVar1 == 0) { *(int8 *)(local_10 + 0x28) = local_18; *(int1 *)(local_10 + 0x12) = 1; } return iVar1; }
20,593
js_iterator_proto_set_toStringTag
bluesky950520[P]quickjs/quickjs.c
static JSValue js_iterator_proto_set_toStringTag(JSContext *ctx, JSValue this_val, JSValue val) { int res; if (check_iterator(ctx, this_val) < 0) return JS_EXCEPTION; if (js_same_value(ctx, this_val, ctx->class_proto[JS_CLASS_ITERATOR])) return JS_ThrowTypeError(ctx, "Cannot assign to read only property"); res = JS_GetOwnProperty(ctx, NULL, this_val, JS_ATOM_Symbol_toStringTag); if (res < 0) return JS_EXCEPTION; if (res) { if (JS_SetProperty(ctx, this_val, JS_ATOM_Symbol_toStringTag, js_dup(val)) < 0) return JS_EXCEPTION; } else { if (JS_DefinePropertyValue(ctx, this_val, JS_ATOM_Symbol_toStringTag, js_dup(val), JS_PROP_C_W_E) < 0) return JS_EXCEPTION; } return JS_UNDEFINED; }
O1
c
js_iterator_proto_set_toStringTag: pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x38, %rsp movq %rdx, %r13 movq %rdi, %r15 cmpl $-0x1, %r13d jne 0x77159 movq %r8, %rbx movq %rcx, %r14 movq %rsi, %rbp movq 0x40(%r15), %rax movq 0x270(%rax), %rcx movq 0x278(%rax), %r8 movq %r15, %rdi movq %r13, %rdx callq 0x2a4bd testl %eax, %eax je 0x77184 leaq 0x2ed23(%rip), %rsi # 0xa5e7a jmp 0x77160 leaq 0x2c13d(%rip), %rsi # 0xa329d movq %r15, %rdi xorl %eax, %eax callq 0x265c3 movl $0x6, %r12d xorl %eax, %eax movq %r12, %rdx addq $0x38, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq movq %r15, %rdi xorl %esi, %esi movq %rbp, %rdx movq %r13, %rcx movl $0xda, %r8d callq 0x27c0c movl $0x6, %r12d testl %eax, %eax js 0x77170 je 0x771f6 movq %r14, 0x28(%rsp) cmpl $-0x9, %ebx jb 0x771b7 movq 0x28(%rsp), %rax incl (%rax) movq %rbp, 0x28(%rsp) movq %r13, 0x30(%rsp) movups 0x28(%rsp), %xmm0 movups %xmm0, (%rsp) movq $0x0, 0x18(%rsp) movl $0x4000, 0x10(%rsp) # imm = 0x4000 movq %r15, %rdi movq %rbp, %rsi movq %r13, %rdx movl $0xda, %ecx movq %r14, %r8 movq %rbx, %r9 callq 0x283e4 jmp 0x77227 movq %r14, 0x28(%rsp) cmpl $-0x9, %ebx jb 0x77207 movq 0x28(%rsp), %rax incl (%rax) movl $0x7, (%rsp) movq %r15, %rdi movq %rbp, %rsi movq %r13, %rdx movl $0xda, %ecx movq %r14, %r8 movq %rbx, %r9 callq 0x2ab17 testl %eax, %eax js 0x77170 movl $0x3, %r12d jmp 0x77170
js_iterator_proto_set_toStringTag: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 38h mov r13, rdx mov r15, rdi cmp r13d, 0FFFFFFFFh jnz short loc_77159 mov rbx, r8 mov r14, rcx mov rbp, rsi mov rax, [r15+40h] mov rcx, [rax+270h] mov r8, [rax+278h] mov rdi, r15 mov rdx, r13 call js_same_value test eax, eax jz short loc_77184 lea rsi, aCannotAssignTo; "Cannot assign to read only property" jmp short loc_77160 loc_77159: lea rsi, aOperandPrototy+20h; "not an object" loc_77160: mov rdi, r15 xor eax, eax call JS_ThrowTypeError mov r12d, 6 loc_77170: xor eax, eax mov rdx, r12 add rsp, 38h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn loc_77184: mov rdi, r15 xor esi, esi mov rdx, rbp mov rcx, r13 mov r8d, 0DAh call JS_GetOwnProperty mov r12d, 6 test eax, eax js short loc_77170 jz short loc_771F6 mov qword ptr [rsp+68h+var_40], r14 cmp ebx, 0FFFFFFF7h jb short loc_771B7 mov rax, qword ptr [rsp+68h+var_40] inc dword ptr [rax] loc_771B7: mov qword ptr [rsp+68h+var_40], rbp mov qword ptr [rsp+68h+var_40+8], r13 movups xmm0, [rsp+68h+var_40] movups [rsp+68h+var_68], xmm0 mov [rsp+68h+var_50], 0 mov [rsp+68h+var_58], 4000h mov rdi, r15 mov rsi, rbp mov rdx, r13 mov ecx, 0DAh mov r8, r14 mov r9, rbx call JS_SetPropertyInternal2 jmp short loc_77227 loc_771F6: mov qword ptr [rsp+68h+var_40], r14 cmp ebx, 0FFFFFFF7h jb short loc_77207 mov rax, qword ptr [rsp+68h+var_40] inc dword ptr [rax] loc_77207: mov dword ptr [rsp+68h+var_68], 7 mov rdi, r15 mov rsi, rbp mov rdx, r13 mov ecx, 0DAh mov r8, r14 mov r9, rbx call JS_DefinePropertyValue loc_77227: test eax, eax js loc_77170 mov r12d, 3 jmp loc_77170
long long js_iterator_proto_set_toStringTag( long long a1, _DWORD *a2, unsigned long long a3, _DWORD *a4, long long a5, long long a6, __m128 a7, __m128 a8, __m128 a9, __m128 a10, __m128 a11, __m128 a12, __m128 a13, __m128 a14) { char *v17; // rsi int OwnProperty; // eax __m128 v20; // xmm4 __m128 v21; // xmm5 char v22; // [rsp+0h] [rbp-68h] __m128 v23; // [rsp+28h] [rbp-40h] if ( (_DWORD)a3 != -1 ) { v17 = "not an object"; goto LABEL_5; } if ( (unsigned int)js_same_value( a1, a2, a3, *(_DWORD **)(*(_QWORD *)(a1 + 64) + 624LL), *(_QWORD *)(*(_QWORD *)(a1 + 64) + 632LL)) ) { v17 = "Cannot assign to read only property"; LABEL_5: JS_ThrowTypeError(a1, (long long)v17, a3, (long long)a4, a5, a6, a7, a8, a9, a10, a11, a12, a13, a14, v22); return 0LL; } OwnProperty = JS_GetOwnProperty(a1, 0LL, (long long)a2, a3, 218LL, a6, a7, a8, a9, a10, a11, a12, a13, a14); if ( OwnProperty >= 0 ) { if ( OwnProperty ) { if ( (unsigned int)a5 >= 0xFFFFFFF7 ) ++*a4; v23.m128_u64[0] = (unsigned long long)a2; v23.m128_u64[1] = a3; JS_SetPropertyInternal2( a1, (long long)a2, a3, 0xDAu, a4, a5, v23, a8, a9, a10, *(double *)v20.m128_u64, *(double *)v21.m128_u64, a13, a14, (long long)a2, a3, 0x4000u, 0LL); } else { if ( (unsigned int)a5 >= 0xFFFFFFF7 ) ++*a4; JS_DefinePropertyValue( a1, (unsigned long long)a2, a3, 218LL, a4, a5, *(double *)a7.m128_u64, a8, a9, a10, v20, v21, a13, a14, 7); } } return 0LL; }
js_iterator_proto_set_toStringTag: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x38 MOV R13,RDX MOV R15,RDI CMP R13D,-0x1 JNZ 0x00177159 MOV RBX,R8 MOV R14,RCX MOV RBP,RSI MOV RAX,qword ptr [R15 + 0x40] MOV RCX,qword ptr [RAX + 0x270] MOV R8,qword ptr [RAX + 0x278] MOV RDI,R15 MOV RDX,R13 CALL 0x0012a4bd TEST EAX,EAX JZ 0x00177184 LEA RSI,[0x1a5e7a] JMP 0x00177160 LAB_00177159: LEA RSI,[0x1a329d] LAB_00177160: MOV RDI,R15 XOR EAX,EAX CALL 0x001265c3 MOV R12D,0x6 LAB_00177170: XOR EAX,EAX MOV RDX,R12 ADD RSP,0x38 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET LAB_00177184: MOV RDI,R15 XOR ESI,ESI MOV RDX,RBP MOV RCX,R13 MOV R8D,0xda CALL 0x00127c0c MOV R12D,0x6 TEST EAX,EAX JS 0x00177170 JZ 0x001771f6 MOV qword ptr [RSP + 0x28],R14 CMP EBX,-0x9 JC 0x001771b7 MOV RAX,qword ptr [RSP + 0x28] INC dword ptr [RAX] LAB_001771b7: MOV qword ptr [RSP + 0x28],RBP MOV qword ptr [RSP + 0x30],R13 MOVUPS XMM0,xmmword ptr [RSP + 0x28] MOVUPS xmmword ptr [RSP],XMM0 MOV qword ptr [RSP + 0x18],0x0 MOV dword ptr [RSP + 0x10],0x4000 MOV RDI,R15 MOV RSI,RBP MOV RDX,R13 MOV ECX,0xda MOV R8,R14 MOV R9,RBX CALL 0x001283e4 JMP 0x00177227 LAB_001771f6: MOV qword ptr [RSP + 0x28],R14 CMP EBX,-0x9 JC 0x00177207 MOV RAX,qword ptr [RSP + 0x28] INC dword ptr [RAX] LAB_00177207: MOV dword ptr [RSP],0x7 MOV RDI,R15 MOV RSI,RBP MOV RDX,R13 MOV ECX,0xda MOV R8,R14 MOV R9,RBX CALL 0x0012ab17 LAB_00177227: TEST EAX,EAX JS 0x00177170 MOV R12D,0x3 JMP 0x00177170
int1 [16] js_iterator_proto_set_toStringTag (long param_1,int8 param_2,int8 param_3,int *param_4,int8 param_5) { int1 auVar1 [16]; int iVar2; char *pcVar3; ulong uVar4; int4 local_40; if ((int)param_3 == -1) { iVar2 = js_same_value(param_1,param_2,param_3,*(int8 *)(*(long *)(param_1 + 0x40) + 0x270) ,*(int8 *)(*(long *)(param_1 + 0x40) + 0x278)); if (iVar2 == 0) { iVar2 = JS_GetOwnProperty(param_1,0,param_2,param_3,0xda); uVar4 = 6; if (-1 < iVar2) { if (iVar2 == 0) { if (0xfffffff6 < (uint)param_5) { *param_4 = *param_4 + 1; } iVar2 = JS_DefinePropertyValue(param_1,param_2,param_3,0xda,param_4,param_5,7); } else { if (0xfffffff6 < (uint)param_5) { *param_4 = *param_4 + 1; } local_40 = (int4)param_2; iVar2 = JS_SetPropertyInternal2 (param_1,param_2,param_3,0xda,param_4,param_5,local_40,0xffffffff,0x4000 ,0); } if (-1 < iVar2) { uVar4 = 3; } } goto LAB_00177170; } pcVar3 = "Cannot assign to read only property"; } else { pcVar3 = "not an object"; } JS_ThrowTypeError(param_1,pcVar3); uVar4 = 6; LAB_00177170: auVar1._8_8_ = 0; auVar1._0_8_ = uVar4; return auVar1 << 0x40; }
20,594
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> const& nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>::at<char const (&) [5], 0>(char const (&) [5]) const
llama.cpp/common/json.hpp
const_reference at(KeyType && key) const { // at only works for objects if (JSON_HEDLEY_UNLIKELY(!is_object())) { JSON_THROW(type_error::create(304, detail::concat("cannot use at() with ", type_name()), this)); } auto it = m_data.m_value.object->find(std::forward<KeyType>(key)); if (it == m_data.m_value.object->end()) { JSON_THROW(out_of_range::create(403, detail::concat("key '", string_t(std::forward<KeyType>(key)), "' not found"), this)); } return it->second; }
O3
cpp
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> const& nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>::at<char const (&) [5], 0>(char const (&) [5]) const: pushq %rbp pushq %r15 pushq %r14 pushq %r12 pushq %rbx subq $0x40, %rsp movq %rdi, %r14 cmpb $0x1, (%rdi) jne 0x66ef5 movq %rsi, %r15 movq 0x8(%r14), %r12 movq (%r12), %rbx movq 0x8(%r12), %rax cmpq %rax, %rbx je 0x66edf movq %rbx, %rdi movq %r15, %rsi callq 0x1cad0 testl %eax, %eax je 0x66ed4 addq $0x30, %rbx movq 0x8(%r12), %rax cmpq %rax, %rbx jne 0x66eb5 jmp 0x66ed7 movq %rbx, %rax movq 0x8(%r14), %rcx movq 0x8(%rcx), %rbx cmpq %rbx, %rax je 0x66f53 addq $0x20, %rax addq $0x40, %rsp popq %rbx popq %r12 popq %r14 popq %r15 popq %rbp retq movl $0x20, %edi callq 0x1c460 movq %rax, %rbx movq %r14, %rdi callq 0x30fda movq %rsp, %rdx movq %rax, (%rdx) leaq 0x64f19(%rip), %rsi # 0xcbe30 leaq 0x20(%rsp), %rdi callq 0x73b07 movb $0x1, %bpl leaq 0x20(%rsp), %rdx movq %rbx, %rdi movl $0x130, %esi # imm = 0x130 movq %r14, %rcx callq 0x72d1c xorl %ebp, %ebp leaq 0x96f9e(%rip), %rsi # 0xfdee0 leaq -0x39743(%rip), %rdx # 0x2d806 movq %rbx, %rdi callq 0x1c7b0 jmp 0x66fcc movl $0x20, %edi callq 0x1c460 movq %rax, %rbx leaq 0x10(%rsp), %r12 movq %r12, -0x10(%r12) movq %r15, %rdi callq 0x1c490 leaq (%rax,%r15), %rdx movq %rsp, %rdi movq %r15, %rsi callq 0x3fe82 leaq 0x6508b(%rip), %rsi # 0xcc013 leaq 0x6508a(%rip), %rcx # 0xcc019 leaq 0x20(%rsp), %rdi movq %rsp, %rdx callq 0x763c5 movb $0x1, %bpl leaq 0x20(%rsp), %rdx movq %rbx, %rdi movl $0x193, %esi # imm = 0x193 movq %r14, %rcx callq 0x87c24 xorl %ebp, %ebp leaq 0x96ea3(%rip), %rsi # 0xfde60 leaq -0x397be(%rip), %rdx # 0x2d806 movq %rbx, %rdi callq 0x1c7b0 movq %rax, %r14 leaq 0x30(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0x66fea movq 0x30(%rsp), %rsi incq %rsi callq 0x1c110 movq (%rsp), %rdi cmpq %r12, %rdi je 0x67035 movq 0x10(%rsp), %rsi jmp 0x6702d movq %rax, %r14 movq (%rsp), %rdi cmpq %r12, %rdi je 0x6703f movq 0x10(%rsp), %rsi incq %rsi callq 0x1c110 jmp 0x6703f jmp 0x6703c movq %rax, %r14 leaq 0x30(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0x67035 movq 0x30(%rsp), %rsi incq %rsi callq 0x1c110 testb %bpl, %bpl jne 0x6703f jmp 0x67047 movq %rax, %r14 movq %rbx, %rdi callq 0x1caa0 movq %r14, %rdi callq 0x1c7d0 nop
_ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE2atIRA5_KcTnNSt9enable_ifIXsr6detail32is_usable_as_basic_json_key_typeISD_T_EE5valueEiE4typeELi0EEERKSD_OSJ_: push rbp; void * push r15; int push r14; __int64 push r12; int push rbx; void * sub rsp, 40h mov r14, rdi cmp byte ptr [rdi], 1 jnz short loc_66EF5 mov r15, rsi mov r12, [r14+8] mov rbx, [r12] mov rax, [r12+8] cmp rbx, rax jz short loc_66EDF loc_66EB5: mov rdi, rbx mov rsi, r15 call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE7compareEPKc; std::string::compare(char const*) test eax, eax jz short loc_66ED4 add rbx, 30h ; '0' mov rax, [r12+8] cmp rbx, rax jnz short loc_66EB5 jmp short loc_66ED7 loc_66ED4: mov rax, rbx loc_66ED7: mov rcx, [r14+8] mov rbx, [rcx+8] loc_66EDF: cmp rax, rbx jz short loc_66F53 add rax, 20h ; ' ' add rsp, 40h pop rbx pop r12 pop r14 pop r15 pop rbp retn loc_66EF5: mov edi, 20h ; ' '; thrown_size call ___cxa_allocate_exception mov rbx, rax mov rdi, r14 call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE9type_nameEv; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::type_name(void) mov rdx, rsp mov [rdx], rax lea rsi, aCannotUseAtWit; "cannot use at() with " lea rdi, [rsp+68h+var_48] call _ZN8nlohmann16json_abi_v3_11_36detail6concatINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEJRA22_KcPS9_EEET_DpOT0_; nlohmann::json_abi_v3_11_3::detail::concat<std::string,char const(&)[22],char const*>(char const(&)[22],char const* &&) mov bpl, 1 lea rdx, [rsp+68h+var_48] mov rdi, rbx; this mov esi, 130h; int mov rcx, r14 call _ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIPKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SK_ xor ebp, ebp lea rsi, _ZTIN8nlohmann16json_abi_v3_11_36detail10type_errorE; lptinfo lea rdx, _ZN8nlohmann16json_abi_v3_11_36detail9exceptionD2Ev; void (*)(void *) mov rdi, rbx; void * call ___cxa_throw jmp short loc_66FCC loc_66F53: mov edi, 20h ; ' '; thrown_size call ___cxa_allocate_exception mov rbx, rax lea r12, [rsp+68h+var_58] mov [r12-10h], r12 mov rdi, r15 call _strlen lea rdx, [rax+r15] mov rdi, rsp mov rsi, r15 call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIPKcEEvT_S8_St20forward_iterator_tag; std::string::_M_construct<char const*>(char const*,char const*,std::forward_iterator_tag) lea rsi, aKey; "key '" lea rcx, aNotFound; "' not found" lea rdi, [rsp+68h+var_48] mov rdx, rsp call _ZN8nlohmann16json_abi_v3_11_36detail6concatINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEJRA6_KcS8_RA12_S9_EEET_DpOT0_; nlohmann::json_abi_v3_11_3::detail::concat<std::string,char const(&)[6],std::string,char const(&)[12]>(char const(&)[6],std::string,char const(&)[12] &&) mov bpl, 1 lea rdx, [rsp+68h+var_48] mov rdi, rbx; this mov esi, 193h; int mov rcx, r14 call _ZN8nlohmann16json_abi_v3_11_36detail12out_of_range6createIPKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SK_ xor ebp, ebp lea rsi, _ZTIN8nlohmann16json_abi_v3_11_36detail12out_of_rangeE; lptinfo lea rdx, _ZN8nlohmann16json_abi_v3_11_36detail9exceptionD2Ev; void (*)(void *) mov rdi, rbx; void * call ___cxa_throw loc_66FCC: mov r14, rax lea rax, [rsp+68h+var_38] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_66FEA mov rsi, [rsp+68h+var_38] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_66FEA: mov rdi, [rsp+68h+var_68] cmp rdi, r12 jz short loc_67035 mov rsi, [rsp+68h+var_58] jmp short loc_6702D mov r14, rax mov rdi, [rsp+68h+var_68]; void * cmp rdi, r12 jz short loc_6703F mov rsi, [rsp+68h+var_58] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) jmp short loc_6703F jmp short loc_6703C mov r14, rax lea rax, [rsp+68h+var_38] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_67035 mov rsi, [rsp+68h+var_38] loc_6702D: inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_67035: test bpl, bpl jnz short loc_6703F jmp short loc_67047 loc_6703C: mov r14, rax loc_6703F: mov rdi, rbx; void * call ___cxa_free_exception loc_67047: mov rdi, r14 call __Unwind_Resume
_ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE2atIRA5_KcTnNSt9enable_ifIXsr6detail32is_usable_as_basic_json_key_typeISD_T_EE5valueEiE4typeELi0EEERKSD_OSJ_: PUSH RBP PUSH R15 PUSH R14 PUSH R12 PUSH RBX SUB RSP,0x40 MOV R14,RDI CMP byte ptr [RDI],0x1 JNZ 0x00166ef5 MOV R15,RSI MOV R12,qword ptr [R14 + 0x8] MOV RBX,qword ptr [R12] MOV RAX,qword ptr [R12 + 0x8] CMP RBX,RAX JZ 0x00166edf LAB_00166eb5: MOV RDI,RBX MOV RSI,R15 CALL 0x0011cad0 TEST EAX,EAX JZ 0x00166ed4 ADD RBX,0x30 MOV RAX,qword ptr [R12 + 0x8] CMP RBX,RAX JNZ 0x00166eb5 JMP 0x00166ed7 LAB_00166ed4: MOV RAX,RBX LAB_00166ed7: MOV RCX,qword ptr [R14 + 0x8] MOV RBX,qword ptr [RCX + 0x8] LAB_00166edf: CMP RAX,RBX JZ 0x00166f53 ADD RAX,0x20 ADD RSP,0x40 POP RBX POP R12 POP R14 POP R15 POP RBP RET LAB_00166ef5: MOV EDI,0x20 CALL 0x0011c460 MOV RBX,RAX MOV RDI,R14 CALL 0x00130fda MOV RDX,RSP MOV qword ptr [RDX],RAX LAB_00166f10: LEA RSI,[0x1cbe30] LEA RDI,[RSP + 0x20] CALL 0x00173b07 MOV BPL,0x1 LAB_00166f24: LEA RDX,[RSP + 0x20] MOV RDI,RBX MOV ESI,0x130 MOV RCX,R14 CALL 0x00172d1c XOR EBP,EBP LEA RSI,[0x1fdee0] LEA RDX,[0x12d806] MOV RDI,RBX CALL 0x0011c7b0 LAB_00166f53: MOV EDI,0x20 CALL 0x0011c460 MOV RBX,RAX LEA R12,[RSP + 0x10] MOV qword ptr [R12 + -0x10],R12 MOV RDI,R15 CALL 0x0011c490 LEA RDX,[RAX + R15*0x1] LAB_00166f76: MOV RDI,RSP MOV RSI,R15 CALL 0x0013fe82 LAB_00166f81: LEA RSI,[0x1cc013] LEA RCX,[0x1cc019] LEA RDI,[RSP + 0x20] MOV RDX,RSP CALL 0x001763c5 MOV BPL,0x1 LAB_00166f9f: LEA RDX,[RSP + 0x20] MOV RDI,RBX MOV ESI,0x193 MOV RCX,R14 CALL 0x00187c24 XOR EBP,EBP LEA RSI,[0x1fde60] LEA RDX,[0x12d806] MOV RDI,RBX CALL 0x0011c7b0
char * _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE2atIRA5_KcTnNSt9enable_ifIXsr6detail32is_usable_as_basic_json_key_typeISD_T_EE5valueEiE4typeELi0EEERKSD_OSJ_ (basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> *param_1,char *param_2) { long *plVar1; int iVar2; char *pcVar3; int8 uVar4; size_t sVar5; char *pcVar6; char *local_68 [2]; char local_58 [16]; detail local_48 [32]; if (*param_1 != (basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> )0x1) { uVar4 = __cxa_allocate_exception(0x20); local_68[0] = (char *)nlohmann::json_abi_v3_11_3:: basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> ::type_name(param_1); /* try { // try from 00166f10 to 00166f20 has its CatchHandler @ 0016703c */ nlohmann::json_abi_v3_11_3::detail::concat<std::__cxx11::string,char_const(&)[22],char_const*> (local_48,"cannot use at() with ",local_68); /* try { // try from 00166f24 to 00166f50 has its CatchHandler @ 00167017 */ _ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIPKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SK_ (uVar4,0x130,local_48,param_1); /* WARNING: Subroutine does not return */ __cxa_throw(uVar4,&nlohmann::json_abi_v3_11_3::detail::type_error::typeinfo, nlohmann::json_abi_v3_11_3::detail::exception::~exception); } plVar1 = *(long **)(param_1 + 8); pcVar6 = (char *)*plVar1; pcVar3 = (char *)plVar1[1]; if (pcVar6 != pcVar3) { do { pcVar3 = pcVar6; iVar2 = std::__cxx11::string::compare(pcVar3); if (iVar2 == 0) break; pcVar6 = pcVar3 + 0x30; pcVar3 = (char *)plVar1[1]; } while (pcVar6 != pcVar3); pcVar6 = *(char **)(*(long *)(param_1 + 8) + 8); } if (pcVar3 == pcVar6) { uVar4 = __cxa_allocate_exception(0x20); local_68[0] = local_58; sVar5 = strlen(param_2); /* try { // try from 00166f76 to 00166f80 has its CatchHandler @ 00167015 */ std::__cxx11::string::_M_construct<char_const*>(local_68,param_2,param_2 + sVar5); /* try { // try from 00166f81 to 00166f9b has its CatchHandler @ 00166ffa */ nlohmann::json_abi_v3_11_3::detail:: concat<std::__cxx11::string,char_const(&)[6],std::__cxx11::string,char_const(&)[12]> (local_48,"key \'",(string *)local_68,"\' not found"); /* try { // try from 00166f9f to 00166fcb has its CatchHandler @ 00166fcc */ _ZN8nlohmann16json_abi_v3_11_36detail12out_of_range6createIPKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SK_ (uVar4,0x193,local_48,param_1); /* WARNING: Subroutine does not return */ __cxa_throw(uVar4,&nlohmann::json_abi_v3_11_3::detail::out_of_range::typeinfo, nlohmann::json_abi_v3_11_3::detail::exception::~exception); } return pcVar3 + 0x20; }
20,595
CLI::Option::_validate(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>&, int) const
MikePodsytnik[P]TCRtrie/build_O3/_deps/cli11-src/include/CLI/impl/Option_inl.hpp
CLI11_INLINE std::string Option::_validate(std::string &result, int index) const { std::string err_msg; if(result.empty() && expected_min_ == 0) { // an empty with nothing expected is allowed return err_msg; } for(const auto &vali : validators_) { auto v = vali.get_application_index(); if(v == -1 || v == index) { try { err_msg = vali(result); } catch(const ValidationError &err) { err_msg = err.what(); } if(!err_msg.empty()) break; } } return err_msg; }
O3
cpp
CLI::Option::_validate(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>&, int) const: pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x38, %rsp movl %ecx, %ebp movq %rdx, %r14 movq %rdi, %rbx leaq 0x10(%rdi), %rax movq %rax, 0x10(%rsp) movq %rax, (%rdi) movq $0x0, 0x8(%rdi) movb $0x0, 0x10(%rdi) cmpq $0x0, 0x8(%rdx) jne 0x13f1a cmpl $0x0, 0x170(%rsi) je 0x13fbf movq 0x178(%rsi), %r15 movq 0x180(%rsi), %r13 cmpq %r13, %r15 je 0x13fbf leaq 0x18(%rsp), %r12 movl 0x60(%r15), %eax cmpl $-0x1, %eax setne %cl cmpl %ebp, %eax setne %al testb %al, %cl jne 0x13f85 movq %r12, %rdi movq %r15, %rsi movq %r14, %rdx callq 0x14b92 movq %rbx, %rdi movq %r12, %rsi callq 0x7510 movq 0x18(%rsp), %rdi leaq 0x28(%rsp), %rax cmpq %rax, %rdi je 0x13f7e movq 0x28(%rsp), %rsi incq %rsi callq 0x7430 cmpq $0x0, 0x8(%rbx) jne 0x13fbf addq $0x68, %r15 cmpq %r13, %r15 jne 0x13f36 jmp 0x13fbf movq %rax, 0x8(%rsp) cmpl $0x1, %edx jne 0x13fe2 movq 0x8(%rsp), %rdi callq 0x7180 movq (%rax), %rcx movq %rax, %rdi callq *0x10(%rcx) movq %rbx, %rdi movq %rax, %rsi callq 0x7590 callq 0x76d0 jmp 0x13f7e movq %rbx, %rax addq $0x38, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq movq %rax, 0x8(%rsp) jmp 0x13fe2 movq %rax, 0x8(%rsp) callq 0x76d0 movq (%rbx), %rdi cmpq 0x10(%rsp), %rdi je 0x13ffc movq 0x10(%rsp), %rax movq (%rax), %rsi incq %rsi callq 0x7430 movq 0x8(%rsp), %rdi callq 0x7780 movq %rax, %rdi callq 0xc95c
_ZNK3CLI6Option9_validateERNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEi: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 38h mov ebp, ecx mov r14, rdx mov rbx, rdi lea rax, [rdi+10h] mov [rsp+68h+var_58], rax mov [rdi], rax mov qword ptr [rdi+8], 0 mov byte ptr [rdi+10h], 0 cmp qword ptr [rdx+8], 0 jnz short loc_13F1A cmp dword ptr [rsi+170h], 0 jz loc_13FBF loc_13F1A: mov r15, [rsi+178h] mov r13, [rsi+180h] cmp r15, r13 jz loc_13FBF lea r12, [rsp+68h+var_50] loc_13F36: mov eax, [r15+60h] cmp eax, 0FFFFFFFFh setnz cl cmp eax, ebp setnz al test cl, al jnz short loc_13F85 mov rdi, r12 mov rsi, r15 mov rdx, r14 call _ZNK3CLI9ValidatorclERNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; CLI::Validator::operator()(std::string &) mov rdi, rbx mov rsi, r12 call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEaSEOS4_; std::string::operator=(std::string&&) mov rdi, [rsp+68h+var_50]; void * lea rax, [rsp+68h+var_40] cmp rdi, rax jz short loc_13F7E mov rsi, [rsp+68h+var_40] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_13F7E: cmp qword ptr [rbx+8], 0 jnz short loc_13FBF loc_13F85: add r15, 68h ; 'h' cmp r15, r13 jnz short loc_13F36 jmp short loc_13FBF mov [rsp+68h+var_60], rax cmp edx, 1 jnz short loc_13FE2 mov rdi, [rsp+68h+var_60]; void * call ___cxa_begin_catch mov rcx, [rax] mov rdi, rax call qword ptr [rcx+10h] mov rdi, rbx mov rsi, rax call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEaSEPKc; std::string::operator=(char const*) call ___cxa_end_catch jmp short loc_13F7E loc_13FBF: mov rax, rbx add rsp, 38h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn mov [rsp+68h+var_60], rax jmp short loc_13FE2 mov [rsp+68h+var_60], rax call ___cxa_end_catch loc_13FE2: mov rdi, [rbx]; void * cmp rdi, [rsp+68h+var_58] jz short loc_13FFC mov rax, [rsp+68h+var_58] mov rsi, [rax] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_13FFC: mov rdi, [rsp+68h+var_60] call __Unwind_Resume mov rdi, rax call __clang_call_terminate
long long CLI::Option::_validate(long long a1, long long a2, long long a3, int a4) { long long v6; // r15 long long i; // r13 void *v9[2]; // [rsp+18h] [rbp-50h] BYREF long long v10; // [rsp+28h] [rbp-40h] BYREF *(_QWORD *)a1 = a1 + 16; *(_QWORD *)(a1 + 8) = 0LL; *(_BYTE *)(a1 + 16) = 0; if ( *(_QWORD *)(a3 + 8) || *(_DWORD *)(a2 + 368) ) { v6 = *(_QWORD *)(a2 + 376); for ( i = *(_QWORD *)(a2 + 384); v6 != i; v6 += 104LL ) { if ( *(_DWORD *)(v6 + 96) == a4 || *(_DWORD *)(v6 + 96) == -1 ) { CLI::Validator::operator()(v9, v6, a3); std::string::operator=(a1, v9); if ( v9[0] != &v10 ) operator delete(v9[0], v10 + 1); if ( *(_QWORD *)(a1 + 8) ) break; } } } return a1; }
_validate: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x38 MOV EBP,ECX MOV R14,RDX MOV RBX,RDI LEA RAX,[RDI + 0x10] MOV qword ptr [RSP + 0x10],RAX MOV qword ptr [RDI],RAX MOV qword ptr [RDI + 0x8],0x0 MOV byte ptr [RDI + 0x10],0x0 CMP qword ptr [RDX + 0x8],0x0 JNZ 0x00113f1a CMP dword ptr [RSI + 0x170],0x0 JZ 0x00113fbf LAB_00113f1a: MOV R15,qword ptr [RSI + 0x178] MOV R13,qword ptr [RSI + 0x180] CMP R15,R13 JZ 0x00113fbf LEA R12,[RSP + 0x18] LAB_00113f36: MOV EAX,dword ptr [R15 + 0x60] CMP EAX,-0x1 SETNZ CL CMP EAX,EBP SETNZ AL TEST CL,AL JNZ 0x00113f85 LAB_00113f49: MOV RDI,R12 MOV RSI,R15 MOV RDX,R14 CALL 0x00114b92 LAB_00113f57: MOV RDI,RBX MOV RSI,R12 CALL 0x00107510 MOV RDI,qword ptr [RSP + 0x18] LEA RAX,[RSP + 0x28] CMP RDI,RAX JZ 0x00113f7e MOV RSI,qword ptr [RSP + 0x28] INC RSI CALL 0x00107430 LAB_00113f7e: CMP qword ptr [RBX + 0x8],0x0 JNZ 0x00113fbf LAB_00113f85: ADD R15,0x68 CMP R15,R13 JNZ 0x00113f36 JMP 0x00113fbf LAB_00113fbf: MOV RAX,RBX ADD RSP,0x38 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
/* CLI::Option::_validate(std::__cxx11::string&, int) const */ string * CLI::Option::_validate(string *param_1,int param_2) { string *psVar1; int in_ECX; long in_RDX; int4 in_register_00000034; long lVar2; string *psVar3; long *local_50 [2]; long local_40 [2]; lVar2 = CONCAT44(in_register_00000034,param_2); *(string **)param_1 = param_1 + 0x10; *(int8 *)(param_1 + 8) = 0; param_1[0x10] = (string)0x0; if ((*(long *)(in_RDX + 8) != 0) || (*(int *)(lVar2 + 0x170) != 0)) { psVar3 = *(string **)(lVar2 + 0x178); psVar1 = *(string **)(lVar2 + 0x180); if (psVar3 != psVar1) { do { if (*(int *)(psVar3 + 0x60) == -1 || *(int *)(psVar3 + 0x60) == in_ECX) { /* try { // try from 00113f49 to 00113f56 has its CatchHandler @ 00113f90 */ Validator::operator()((Validator *)local_50,psVar3); std::__cxx11::string::operator=(param_1,(string *)local_50); if (local_50[0] != local_40) { operator_delete(local_50[0],local_40[0] + 1); } if (*(long *)(param_1 + 8) != 0) { return param_1; } } psVar3 = psVar3 + 0x68; } while (psVar3 != psVar1); } } return param_1; }
20,596
b2d
eloqsql/strings/dtoa.c
static double b2d(Bigint *a, int *e) { ULong *xa, *xa0, w, y, z; int k; U d; #define d0 word0(&d) #define d1 word1(&d) xa0= a->p.x; xa= xa0 + a->wds; y= *--xa; k= hi0bits(y); *e= 32 - k; if (k < Ebits) { d0= Exp_1 | y >> (Ebits - k); w= xa > xa0 ? *--xa : 0; d1= y << ((32-Ebits) + k) | w >> (Ebits - k); goto ret_d; } z= xa > xa0 ? *--xa : 0; if (k-= Ebits) { d0= Exp_1 | y << k | z >> (32 - k); y= xa > xa0 ? *--xa : 0; d1= z << k | y >> (32 - k); } else { d0= Exp_1 | y; d1= z; } ret_d: #undef d0 #undef d1 return dval(&d); }
O3
c
b2d: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx pushq %rax movq %rdx, %r15 movq %rdi, %r14 movslq %esi, %rax leaq (%rdi,%rax,4), %r13 leaq (%rdi,%rax,4), %r12 addq $-0x4, %r12 movl (%r12), %ebx movl %ebx, %edi callq 0x489be movl $0x20, %ecx subl %eax, %ecx movl %ecx, (%r15) cmpl $0xa, %eax ja 0x48a8c movl $0xb, %edx subl %eax, %edx movl %ebx, %esi movl %edx, %ecx shrl %cl, %esi xorl %edi, %edi cmpq %r14, %r12 jbe 0x48a7f movl -0x8(%r13), %edi leal 0x15(%rax), %ecx shll %cl, %ebx movl %edx, %ecx shrl %cl, %edi orl %ebx, %edi jmp 0x48ad3 xorl %edi, %edi cmpq %r14, %r12 jbe 0x48a9e movl -0x8(%r13), %edi addq $-0x8, %r13 movq %r13, %r12 movl %eax, %edx addl $-0xb, %edx je 0x48ad1 movl %edx, %ecx shll %cl, %ebx movl $0x2b, %esi subl %eax, %esi movl %edi, %eax movl %esi, %ecx shrl %cl, %eax xorl %r8d, %r8d cmpq %r14, %r12 jbe 0x48ac3 movl -0x4(%r12), %r8d movl %edx, %ecx shll %cl, %edi movl %esi, %ecx shrl %cl, %r8d orl %eax, %ebx orl %r8d, %edi movl %ebx, %esi orl $0x3ff00000, %esi # imm = 0x3FF00000 shlq $0x20, %rsi movl %edi, %eax orq %rsi, %rax movq %rax, %xmm0 addq $0x8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq nop
b2d: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx push rax mov r15, rdx mov r14, rdi movsxd rax, esi lea r13, [rdi+rax*4] lea r12, [rdi+rax*4] add r12, 0FFFFFFFFFFFFFFFCh mov ebx, [r12] mov edi, ebx call hi0bits mov ecx, 20h ; ' ' sub ecx, eax mov [r15], ecx cmp eax, 0Ah ja short loc_48A8C mov edx, 0Bh sub edx, eax mov esi, ebx mov ecx, edx shr esi, cl xor edi, edi cmp r12, r14 jbe short loc_48A7F mov edi, [r13-8] loc_48A7F: lea ecx, [rax+15h] shl ebx, cl mov ecx, edx shr edi, cl or edi, ebx jmp short loc_48AD3 loc_48A8C: xor edi, edi cmp r12, r14 jbe short loc_48A9E mov edi, [r13-8] add r13, 0FFFFFFFFFFFFFFF8h mov r12, r13 loc_48A9E: mov edx, eax add edx, 0FFFFFFF5h jz short loc_48AD1 mov ecx, edx shl ebx, cl mov esi, 2Bh ; '+' sub esi, eax mov eax, edi mov ecx, esi shr eax, cl xor r8d, r8d cmp r12, r14 jbe short loc_48AC3 mov r8d, [r12-4] loc_48AC3: mov ecx, edx shl edi, cl mov ecx, esi shr r8d, cl or ebx, eax or edi, r8d loc_48AD1: mov esi, ebx loc_48AD3: or esi, 3FF00000h shl rsi, 20h mov eax, edi or rax, rsi movq xmm0, rax add rsp, 8 pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
double b2d(unsigned long long a1, int a2, _DWORD *a3) { unsigned long long v5; // r13 unsigned long long v6; // r12 unsigned int v7; // ebx unsigned int v8; // eax unsigned int v9; // esi unsigned int v10; // edi unsigned int v11; // edi char v12; // dl unsigned int v13; // ebx char v14; // si unsigned int v15; // eax unsigned int v16; // r8d double result; // xmm0_8 v5 = a1 + 4LL * a2; v6 = v5 - 4; v7 = *(_DWORD *)(v5 - 4); v8 = hi0bits(v7); *a3 = 32 - v8; if ( v8 > 0xA ) { v11 = 0; if ( v6 > a1 ) { v11 = *(_DWORD *)(v5 - 8); v6 = v5 - 8; } v12 = v8 - 11; if ( v8 != 11 ) { v13 = v7 << v12; v14 = 43 - v8; v15 = v11 >> (43 - v8); v16 = 0; if ( v6 > a1 ) v16 = *(_DWORD *)(v6 - 4); v7 = v15 | v13; v11 = (v16 >> v14) | (v11 << v12); } v9 = v7; } else { v9 = v7 >> (11 - v8); v10 = 0; if ( v6 > a1 ) v10 = *(_DWORD *)(v5 - 8); v11 = (v7 << (v8 + 21)) | (v10 >> (11 - v8)); } *(_QWORD *)&result = ((unsigned long long)(v9 | 0x3FF00000) << 32) | v11; return result; }
b2d: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX PUSH RAX MOV R15,RDX MOV R14,RDI MOVSXD RAX,ESI LEA R13,[RDI + RAX*0x4] LEA R12,[RDI + RAX*0x4] ADD R12,-0x4 MOV EBX,dword ptr [R12] MOV EDI,EBX CALL 0x001489be MOV ECX,0x20 SUB ECX,EAX MOV dword ptr [R15],ECX CMP EAX,0xa JA 0x00148a8c MOV EDX,0xb SUB EDX,EAX MOV ESI,EBX MOV ECX,EDX SHR ESI,CL XOR EDI,EDI CMP R12,R14 JBE 0x00148a7f MOV EDI,dword ptr [R13 + -0x8] LAB_00148a7f: LEA ECX,[RAX + 0x15] SHL EBX,CL MOV ECX,EDX SHR EDI,CL OR EDI,EBX JMP 0x00148ad3 LAB_00148a8c: XOR EDI,EDI CMP R12,R14 JBE 0x00148a9e MOV EDI,dword ptr [R13 + -0x8] ADD R13,-0x8 MOV R12,R13 LAB_00148a9e: MOV EDX,EAX ADD EDX,-0xb JZ 0x00148ad1 MOV ECX,EDX SHL EBX,CL MOV ESI,0x2b SUB ESI,EAX MOV EAX,EDI MOV ECX,ESI SHR EAX,CL XOR R8D,R8D CMP R12,R14 JBE 0x00148ac3 MOV R8D,dword ptr [R12 + -0x4] LAB_00148ac3: MOV ECX,EDX SHL EDI,CL MOV ECX,ESI SHR R8D,CL OR EBX,EAX OR EDI,R8D LAB_00148ad1: MOV ESI,EBX LAB_00148ad3: OR ESI,0x3ff00000 SHL RSI,0x20 MOV EAX,EDI OR RAX,RSI MOVQ XMM0,RAX ADD RSP,0x8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
ulong b2d(uint *param_1,int param_2,int *param_3) { char cVar1; uint uVar2; long lVar3; byte bVar4; uint uVar5; uint uVar6; uint *puVar7; lVar3 = (long)param_2; puVar7 = param_1 + lVar3 + -1; uVar5 = *puVar7; uVar2 = hi0bits(uVar5); *param_3 = 0x20 - uVar2; cVar1 = (char)uVar2; if (uVar2 < 0xb) { uVar2 = 0; if (param_1 < puVar7) { uVar2 = param_1[lVar3 + -2]; } uVar6 = uVar2 >> (0xbU - cVar1 & 0x1f) | uVar5 << (cVar1 + 0x15U & 0x1f); uVar5 = uVar5 >> (0xbU - cVar1 & 0x1f); } else { uVar6 = 0; if (param_1 < puVar7) { uVar6 = param_1[lVar3 + -2]; puVar7 = param_1 + lVar3 + -2; } if (uVar2 - 0xb != 0) { bVar4 = (byte)(uVar2 - 0xb); uVar2 = 0; if (param_1 < puVar7) { uVar2 = puVar7[-1]; } uVar5 = uVar5 << (bVar4 & 0x1f) | uVar6 >> (0x2bU - cVar1 & 0x1f); uVar6 = uVar6 << (bVar4 & 0x1f) | uVar2 >> (0x2bU - cVar1 & 0x1f); } } return CONCAT44(uVar5,uVar6) | 0x3ff0000000000000; }
20,597
unlock_io_cache
eloqsql/mysys/mf_iocache.c
static void unlock_io_cache(IO_CACHE *cache) { IO_CACHE_SHARE *cshare= cache->share; DBUG_ENTER("unlock_io_cache"); DBUG_PRINT("io_cache_share", ("%s: %p pos: %lu running: %u", (cache == cshare->source_cache) ? "writer" : "reader", cache, (ulong) cshare->pos_in_file, cshare->total_threads)); cshare->running_threads= cshare->total_threads; mysql_cond_broadcast(&cshare->cond); mysql_mutex_unlock(&cshare->mutex); DBUG_VOID_RETURN; }
O3
c
unlock_io_cache: pushq %rbp movq %rsp, %rbp pushq %r14 pushq %rbx movq %rdi, %rbx movl 0xdc(%rdi), %eax movl %eax, 0xd8(%rdi) leaq 0x48(%rdi), %r14 movq 0x78(%rdi), %rdi testq %rdi, %rdi jne 0x9c07f movq %r14, %rdi callq 0x2a6e0 movq 0x40(%rbx), %rdi testq %rdi, %rdi jne 0x9c091 movq %rbx, %rdi popq %rbx popq %r14 popq %rbp jmp 0x2a1c0 leaq 0x2f4e52(%rip), %rax # 0x390ed8 movq (%rax), %rax callq *0x178(%rax) jmp 0x9c062 leaq 0x2f4e40(%rip), %rax # 0x390ed8 movq (%rax), %rax callq *0x160(%rax) jmp 0x9c073 nop
unlock_io_cache: push rbp mov rbp, rsp push r14 push rbx mov rbx, rdi mov eax, [rdi+0DCh] mov [rdi+0D8h], eax lea r14, [rdi+48h] mov rdi, [rdi+78h] test rdi, rdi jnz short loc_9C07F loc_9C062: mov rdi, r14 call _pthread_cond_broadcast mov rdi, [rbx+40h] test rdi, rdi jnz short loc_9C091 loc_9C073: mov rdi, rbx pop rbx pop r14 pop rbp jmp _pthread_mutex_unlock loc_9C07F: lea rax, PSI_server mov rax, [rax] call qword ptr [rax+178h] jmp short loc_9C062 loc_9C091: lea rax, PSI_server mov rax, [rax] call qword ptr [rax+160h] jmp short loc_9C073
long long unlock_io_cache(long long a1) { *(_DWORD *)(a1 + 216) = *(_DWORD *)(a1 + 220); if ( *(_QWORD *)(a1 + 120) ) PSI_server[47](); pthread_cond_broadcast(a1 + 72); if ( *(_QWORD *)(a1 + 64) ) PSI_server[44](); return pthread_mutex_unlock(a1); }
unlock_io_cache: PUSH RBP MOV RBP,RSP PUSH R14 PUSH RBX MOV RBX,RDI MOV EAX,dword ptr [RDI + 0xdc] MOV dword ptr [RDI + 0xd8],EAX LEA R14,[RDI + 0x48] MOV RDI,qword ptr [RDI + 0x78] TEST RDI,RDI JNZ 0x0019c07f LAB_0019c062: MOV RDI,R14 CALL 0x0012a6e0 MOV RDI,qword ptr [RBX + 0x40] TEST RDI,RDI JNZ 0x0019c091 LAB_0019c073: MOV RDI,RBX POP RBX POP R14 POP RBP JMP 0x0012a1c0 LAB_0019c07f: LEA RAX,[0x490ed8] MOV RAX,qword ptr [RAX] CALL qword ptr [RAX + 0x178] JMP 0x0019c062 LAB_0019c091: LEA RAX,[0x490ed8] MOV RAX,qword ptr [RAX] CALL qword ptr [RAX + 0x160] JMP 0x0019c073
void unlock_io_cache(pthread_mutex_t *param_1) { *(int4 *)((long)param_1 + 0xd8) = *(int4 *)((long)param_1 + 0xdc); if (param_1[3].__align != 0) { (**(code **)(PSI_server + 0x178))(); } pthread_cond_broadcast((pthread_cond_t *)((long)param_1 + 0x48)); if (*(long *)((long)param_1 + 0x40) != 0) { (**(code **)(PSI_server + 0x160))(); } pthread_mutex_unlock(param_1); return; }
20,598
my_coll_parser_scan_shift
eloqsql/strings/ctype-uca.c
static int my_coll_parser_scan_shift(MY_COLL_RULE_PARSER *p) { if (my_coll_parser_curr(p)->term == MY_COLL_LEXEM_SHIFT) { my_coll_rule_shift_at_level(&p->rule, my_coll_parser_curr(p)->diff); return my_coll_parser_scan(p); } return 0; }
O3
c
my_coll_parser_scan_shift: xorl %eax, %eax cmpl $0x1, (%rdi) jne 0x767b6 movl 0x20(%rdi), %eax decl %eax cmpl $0x3, %eax ja 0x76789 leaq 0x1a8378(%rip), %rcx # 0x21eab0 movslq (%rcx,%rax,4), %rax addq %rcx, %rax jmpq *%rax incl 0xd0(%rdi) movl $0x0, 0xdc(%rdi) movq $0x0, 0xd4(%rdi) jmp 0x76789 incl 0xd8(%rdi) movl $0x0, 0xdc(%rdi) jmp 0x76789 incl 0xdc(%rdi) jmp 0x76789 incl 0xd4(%rdi) movq $0x0, 0xd8(%rdi) pushq %rbp movq %rsp, %rbp leaq 0x28(%rdi), %rax movq 0x48(%rdi), %rcx movq %rcx, 0x20(%rdi) movups 0x28(%rdi), %xmm0 movups 0x38(%rdi), %xmm1 movups %xmm1, 0x10(%rdi) movups %xmm0, (%rdi) movq %rax, %rdi callq 0x76483 movl $0x1, %eax popq %rbp retq
my_coll_parser_scan_shift: xor eax, eax cmp dword ptr [rdi], 1 jnz locret_767B6 mov eax, [rdi+20h] dec eax; switch 4 cases cmp eax, 3 ja short def_7673F; jumptable 000000000007673F default case lea rcx, jpt_7673F movsxd rax, ds:(jpt_7673F - 21EAB0h)[rcx+rax*4] add rax, rcx jmp rax; switch jump loc_76741: inc dword ptr [rdi+0D0h]; jumptable 000000000007673F case 1 mov dword ptr [rdi+0DCh], 0 mov qword ptr [rdi+0D4h], 0 jmp short def_7673F; jumptable 000000000007673F default case loc_7675E: inc dword ptr [rdi+0D8h]; jumptable 000000000007673F case 3 mov dword ptr [rdi+0DCh], 0 jmp short def_7673F; jumptable 000000000007673F default case loc_76770: inc dword ptr [rdi+0DCh]; jumptable 000000000007673F case 4 jmp short def_7673F; jumptable 000000000007673F default case loc_76778: inc dword ptr [rdi+0D4h]; jumptable 000000000007673F case 2 mov qword ptr [rdi+0D8h], 0 def_7673F: push rbp; jumptable 000000000007673F default case mov rbp, rsp lea rax, [rdi+28h] mov rcx, [rdi+48h] mov [rdi+20h], rcx movups xmm0, xmmword ptr [rdi+28h] movups xmm1, xmmword ptr [rdi+38h] movups xmmword ptr [rdi+10h], xmm1 movups xmmword ptr [rdi], xmm0 mov rdi, rax call my_coll_lexem_next mov eax, 1 pop rbp locret_767B6: retn
long long my_coll_parser_scan_shift(long long a1) { long long result; // rax __int128 v2; // xmm0 result = 0LL; if ( *(_DWORD *)a1 == 1 ) { switch ( *(_DWORD *)(a1 + 32) ) { case 1: ++*(_DWORD *)(a1 + 208); *(_DWORD *)(a1 + 220) = 0; *(_QWORD *)(a1 + 212) = 0LL; break; case 2: ++*(_DWORD *)(a1 + 212); *(_QWORD *)(a1 + 216) = 0LL; break; case 3: ++*(_DWORD *)(a1 + 216); *(_DWORD *)(a1 + 220) = 0; break; case 4: ++*(_DWORD *)(a1 + 220); break; default: break; } *(_QWORD *)(a1 + 32) = *(_QWORD *)(a1 + 72); v2 = *(_OWORD *)(a1 + 40); *(_OWORD *)(a1 + 16) = *(_OWORD *)(a1 + 56); *(_OWORD *)a1 = v2; my_coll_lexem_next(a1 + 40); return 1LL; } return result; }
my_coll_parser_scan_shift: XOR EAX,EAX CMP dword ptr [RDI],0x1 JNZ 0x001767b6 MOV EAX,dword ptr [RDI + 0x20] DEC EAX CMP EAX,0x3 JA 0x00176789 LEA RCX,[0x31eab0] MOVSXD RAX,dword ptr [RCX + RAX*0x4] ADD RAX,RCX switchD: JMP RAX caseD_1: INC dword ptr [RDI + 0xd0] MOV dword ptr [RDI + 0xdc],0x0 MOV qword ptr [RDI + 0xd4],0x0 JMP 0x00176789 caseD_3: INC dword ptr [RDI + 0xd8] MOV dword ptr [RDI + 0xdc],0x0 JMP 0x00176789 caseD_4: INC dword ptr [RDI + 0xdc] JMP 0x00176789 caseD_2: INC dword ptr [RDI + 0xd4] MOV qword ptr [RDI + 0xd8],0x0 default: PUSH RBP MOV RBP,RSP LEA RAX,[RDI + 0x28] MOV RCX,qword ptr [RDI + 0x48] MOV qword ptr [RDI + 0x20],RCX MOVUPS XMM0,xmmword ptr [RDI + 0x28] MOVUPS XMM1,xmmword ptr [RDI + 0x38] MOVUPS xmmword ptr [RDI + 0x10],XMM1 MOVUPS xmmword ptr [RDI],XMM0 MOV RDI,RAX CALL 0x00176483 MOV EAX,0x1 POP RBP LAB_001767b6: RET
int8 my_coll_parser_scan_shift(int *param_1) { int8 uVar1; uVar1 = 0; if (*param_1 == 1) { switch(param_1[8]) { case 1: param_1[0x34] = param_1[0x34] + 1; param_1[0x37] = 0; param_1[0x35] = 0; param_1[0x36] = 0; break; case 2: param_1[0x35] = param_1[0x35] + 1; param_1[0x36] = 0; param_1[0x37] = 0; break; case 3: param_1[0x36] = param_1[0x36] + 1; param_1[0x37] = 0; break; case 4: param_1[0x37] = param_1[0x37] + 1; } *(int8 *)(param_1 + 8) = *(int8 *)(param_1 + 0x12); param_1[4] = param_1[0xe]; param_1[5] = param_1[0xf]; param_1[6] = param_1[0x10]; param_1[7] = param_1[0x11]; *param_1 = param_1[10]; param_1[1] = param_1[0xb]; param_1[2] = param_1[0xc]; param_1[3] = param_1[0xd]; my_coll_lexem_next(param_1 + 10); uVar1 = 1; } return uVar1; }
20,599
my_strxfrm_pad_nweights_unicode
eloqsql/strings/ctype-utf8.c
size_t my_strxfrm_pad_nweights_unicode(uchar *str, uchar *strend, size_t nweights) { uchar *str0; DBUG_ASSERT(str && str <= strend); for (str0= str; str < strend && nweights; nweights--) { *str++= 0x00; if (str < strend) *str++= 0x20; } return str - str0; }
O3
c
my_strxfrm_pad_nweights_unicode: cmpq %rsi, %rdi setae %al testq %rdx, %rdx sete %cl orb %al, %cl movq %rdi, %rax jne 0xcaea5 pushq %rbp movq %rsp, %rbp decq %rdx movq %rdi, %rcx leaq 0x1(%rcx), %rax movb $0x0, (%rcx) cmpq %rsi, %rax jae 0xcae8f movb $0x20, 0x1(%rcx) addq $0x2, %rcx movq %rcx, %rax addq $-0x1, %rdx setb %r8b cmpq %rsi, %rax jae 0xcaea4 movq %rax, %rcx testb %r8b, %r8b jne 0xcae78 popq %rbp subq %rdi, %rax retq
my_strxfrm_pad_nweights_unicode: cmp rdi, rsi setnb al test rdx, rdx setz cl or cl, al mov rax, rdi jnz short loc_CAEA5 push rbp mov rbp, rsp dec rdx mov rcx, rdi loc_CAE78: lea rax, [rcx+1] mov byte ptr [rcx], 0 cmp rax, rsi jnb short loc_CAE8F mov byte ptr [rcx+1], 20h ; ' ' add rcx, 2 mov rax, rcx loc_CAE8F: add rdx, 0FFFFFFFFFFFFFFFFh setb r8b cmp rax, rsi jnb short loc_CAEA4 mov rcx, rax test r8b, r8b jnz short loc_CAE78 loc_CAEA4: pop rbp loc_CAEA5: sub rax, rdi retn
long long my_strxfrm_pad_nweights_unicode(_BYTE *a1, unsigned long long a2, long long a3) { _BYTE *v3; // rax long long v4; // rdx _BYTE *v5; // rcx bool v6; // cf v3 = a1; if ( (unsigned long long)a1 < a2 && a3 != 0 ) { v4 = a3 - 1; v5 = a1; do { v3 = v5 + 1; *v5 = 0; if ( (unsigned long long)(v5 + 1) < a2 ) { v5[1] = 32; v3 = v5 + 2; } v6 = v4-- != 0; if ( (unsigned long long)v3 >= a2 ) break; v5 = v3; } while ( v6 ); } return v3 - a1; }
my_strxfrm_pad_nweights_unicode: CMP RDI,RSI SETNC AL TEST RDX,RDX SETZ CL OR CL,AL MOV RAX,RDI JNZ 0x001caea5 PUSH RBP MOV RBP,RSP DEC RDX MOV RCX,RDI LAB_001cae78: LEA RAX,[RCX + 0x1] MOV byte ptr [RCX],0x0 CMP RAX,RSI JNC 0x001cae8f MOV byte ptr [RCX + 0x1],0x20 ADD RCX,0x2 MOV RAX,RCX LAB_001cae8f: ADD RDX,-0x1 SETC R8B CMP RAX,RSI JNC 0x001caea4 MOV RCX,RAX TEST R8B,R8B JNZ 0x001cae78 LAB_001caea4: POP RBP LAB_001caea5: SUB RAX,RDI RET
long my_strxfrm_pad_nweights_unicode(int1 *param_1,int1 *param_2,long param_3) { int1 *puVar1; int1 *puVar2; bool bVar3; puVar2 = param_1; if (param_3 != 0 && param_1 < param_2) { param_3 = param_3 + -1; puVar1 = param_1; do { puVar2 = puVar1 + 1; *puVar1 = 0; if (puVar2 < param_2) { puVar1[1] = 0x20; puVar2 = puVar1 + 2; } bVar3 = param_3 != 0; param_3 = param_3 + -1; } while ((puVar2 < param_2) && (puVar1 = puVar2, bVar3)); } return (long)puVar2 - (long)param_1; }